liveplayer-element.min.js 1.3 MB

1
  1. !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("global/window"),require("global/document")):"function"==typeof define&&define.amd?define(["global/window","global/document"],t):(e=e||self,e.videojs=t(e.window,e.document))}(this,function(e,t){function n(e){var t,r="info",i=function(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];t("log",r,n)};return t=bt(e,i),i.createLogger=function(t){return n(e+": "+t)},i.levels={all:"debug|log|warn|error",off:"",debug:"debug|log|warn|error",info:"log|warn|error",warn:"warn|error",error:"error",DEFAULT:r},i.level=function(e){if("string"==typeof e){if(!i.levels.hasOwnProperty(e))throw new Error('"'+e+'" in not a valid log level');r=e}return r},i.history=function(){return _t?[].concat(_t):[]},i.history.filter=function(e){return(_t||[]).filter(function(t){return new RegExp(".*"+e+".*").test(t[0])})},i.history.clear=function(){_t&&(_t.length=0)},i.history.disable=function(){null!==_t&&(_t.length=0,_t=null)},i.history.enable=function(){null===_t&&(_t=[])},i.error=function(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return t("error",r,n)},i.warn=function(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return t("warn",r,n)},i.debug=function(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return t("debug",r,n)},i}function r(e,t){kt(e).forEach(function(n){return t(e[n],n)})}function i(e,t,n){return void 0===n&&(n=0),kt(e).reduce(function(n,r){return t(n,e[r],r)},n)}function a(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return Object.assign?Object.assign.apply(Object,[e].concat(n)):(n.forEach(function(t){t&&r(t,function(t,n){e[n]=t})}),e)}function o(e){return!!e&&"object"==typeof e}function s(e){return o(e)&&"[object Object]"===wt.call(e)&&e.constructor===Object}function u(t,n){if(!t||!n)return"";if("function"==typeof e.getComputedStyle){var r=e.getComputedStyle(t);return r?r.getPropertyValue(n)||r[n]:""}return""}function l(e){return"string"==typeof e&&/\S/.test(e)}function c(e){if(/\s/.test(e))throw new Error("class has illegal whitespace characters")}function d(e){return new RegExp("(^|\\s)"+e+"($|\\s)")}function f(){return t===e.document}function h(e){return o(e)&&1===e.nodeType}function p(){try{return e.parent!==e.self}catch(e){return!0}}function m(e){return function(n,r){if(!l(n))return t[e](null);l(r)&&(r=t.querySelector(r));var i=h(r)?r:t;return i[e]&&i[e](n)}}function v(e,n,r,i){void 0===e&&(e="div"),void 0===n&&(n={}),void 0===r&&(r={});var a=t.createElement(e);return Object.getOwnPropertyNames(n).forEach(function(e){var t=n[e];-1!==e.indexOf("aria-")||"role"===e||"type"===e?(Tt.warn("Setting attributes in the second argument of createEl()\nhas been deprecated. Use the third argument instead.\ncreateEl(type, properties, attributes). Attempting to set "+e+" to "+t+"."),a.setAttribute(e,t)):"textContent"===e?g(a,t):a[e]=t}),Object.getOwnPropertyNames(r).forEach(function(e){a.setAttribute(e,r[e])}),i&&M(a,i),a}function g(e,t){return void 0===e.textContent?e.innerText=t:e.textContent=t,e}function y(e,t){t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}function _(e,t){return c(t),e.classList?e.classList.contains(t):d(t).test(e.className)}function b(e,t){return e?(e.classList?e.classList.add(t):_(e,t)||(e.className=(e.className+" "+t).trim()),e):e}function T(e,t){return e?(e.classList?e.classList.remove(t):(c(t),e.className=e.className.split(/\s+/).filter(function(e){return e!==t}).join(" ")),e):e}function S(e,t,n){var r=_(e,t);return"function"==typeof n&&(n=n(e,t)),"boolean"!=typeof n&&(n=!r),n===r?e:(n?b(e,t):T(e,t),e)}function w(e,t){Object.getOwnPropertyNames(t).forEach(function(n){var r=t[n];null===r||void 0===r||!1===r?e.removeAttribute(n):e.setAttribute(n,!0===r?"":r)})}function k(e){var t={};if(e&&e.attributes&&e.attributes.length>0)for(var n=e.attributes,r=n.length-1;r>=0;r--){var i=n[r].name,a=n[r].value;"boolean"!=typeof e[i]&&-1===",autoplay,stretch,fluent,controls,playsinline,loop,muted,default,defaultMuted,".indexOf(","+i+",")||(a=null!==a),t[i]=a}return t}function E(e,t){return e.getAttribute(t)}function A(e,t,n){e.setAttribute(t,n)}function C(e,t){e.removeAttribute(t)}function L(){t.body.focus(),t.onselectstart=function(){return!1}}function x(){t.onselectstart=function(){return!0}}function j(e){if(e&&e.getBoundingClientRect&&e.parentNode){var t=e.getBoundingClientRect(),n={};return["bottom","height","left","right","top","width"].forEach(function(e){void 0!==t[e]&&(n[e]=t[e])}),n.height||(n.height=parseFloat(u(e,"height"))),n.width||(n.width=parseFloat(u(e,"width"))),n}}function O(n){var r;if(n.getBoundingClientRect&&n.parentNode&&(r=n.getBoundingClientRect()),!r)return{left:0,top:0};var i=t.documentElement,a=t.body,o=i.clientLeft||a.clientLeft||0,s=e.pageXOffset||a.scrollLeft,u=r.left+s-o,l=i.clientTop||a.clientTop||0,c=e.pageYOffset||a.scrollTop,d=r.top+c-l;return{left:Math.round(u),top:Math.round(d)}}function I(e,t){var n={},r=O(e),i=e.offsetWidth,a=e.offsetHeight,o=r.top,s=r.left,u=t.pageY,l=t.pageX;return t.changedTouches&&(l=t.changedTouches[0].pageX,u=t.changedTouches[0].pageY),n.y=Math.max(0,Math.min(1,(o-u+a)/a)),n.x=Math.max(0,Math.min(1,(l-s)/i)),n}function P(e){return o(e)&&3===e.nodeType}function R(e){for(;e.firstChild;)e.removeChild(e.firstChild);return e}function D(e){return"function"==typeof e&&(e=e()),(Array.isArray(e)?e:[e]).map(function(e){return"function"==typeof e&&(e=e()),h(e)||P(e)?e:"string"==typeof e&&/\S/.test(e)?t.createTextNode(e):void 0}).filter(function(e){return e})}function M(e,t){return D(t).forEach(function(t){return e.appendChild(t)}),e}function U(e,t){return M(R(e),t)}function B(e){return void 0===e.button&&void 0===e.buttons||0===e.button&&void 0===e.buttons||"mouseup"===e.type&&0===e.button&&0===e.buttons||0===e.button&&1===e.buttons}function N(){return xt++}function F(e,t){if(Lt.has(e)){var n=Lt.get(e);0===n.handlers[t].length&&(delete n.handlers[t],e.removeEventListener?e.removeEventListener(t,n.dispatcher,!1):e.detachEvent&&e.detachEvent("on"+t,n.dispatcher)),Object.getOwnPropertyNames(n.handlers).length<=0&&(delete n.handlers,delete n.dispatcher,delete n.disabled),0===Object.getOwnPropertyNames(n).length&&Lt.delete(e)}}function V(e,t,n,r){n.forEach(function(n){e(t,n,r)})}function q(n){function r(){return!0}function i(){return!1}if(!n||!n.isPropagationStopped){var a=n||e.event;n={};for(var o in a)"layerX"!==o&&"layerY"!==o&&"keyLocation"!==o&&"webkitMovementX"!==o&&"webkitMovementY"!==o&&("returnValue"===o&&a.preventDefault||(n[o]=a[o]));if(n.target||(n.target=n.srcElement||t),n.relatedTarget||(n.relatedTarget=n.fromElement===n.target?n.toElement:n.fromElement),n.preventDefault=function(){a.preventDefault&&a.preventDefault(),n.returnValue=!1,a.returnValue=!1,n.defaultPrevented=!0},n.defaultPrevented=!1,n.stopPropagation=function(){a.stopPropagation&&a.stopPropagation(),n.cancelBubble=!0,a.cancelBubble=!0,n.isPropagationStopped=r},n.isPropagationStopped=i,n.stopImmediatePropagation=function(){a.stopImmediatePropagation&&a.stopImmediatePropagation(),n.isImmediatePropagationStopped=r,n.stopPropagation()},n.isImmediatePropagationStopped=i,null!==n.clientX&&void 0!==n.clientX){var s=t.documentElement,u=t.body;n.pageX=n.clientX+(s&&s.scrollLeft||u&&u.scrollLeft||0)-(s&&s.clientLeft||u&&u.clientLeft||0),n.pageY=n.clientY+(s&&s.scrollTop||u&&u.scrollTop||0)-(s&&s.clientTop||u&&u.clientTop||0)}n.which=n.charCode||n.keyCode,null!==n.button&&void 0!==n.button&&(n.button=1&n.button?0:4&n.button?1:2&n.button?2:0)}return n}function G(e,t,n){if(Array.isArray(t))return V(G,e,t,n);Lt.has(e)||Lt.set(e,{});var r=Lt.get(e);if(r.handlers||(r.handlers={}),r.handlers[t]||(r.handlers[t]=[]),n.guid||(n.guid=N()),r.handlers[t].push(n),r.dispatcher||(r.disabled=!1,r.dispatcher=function(t,n){if(!r.disabled){t=q(t);var i=r.handlers[t.type];if(i)for(var a=i.slice(0),o=0,s=a.length;o<s&&!t.isImmediatePropagationStopped();o++)try{a[o].call(e,t,n)}catch(e){Tt.error(e)}}}),1===r.handlers[t].length)if(e.addEventListener){var i=!1;jt&&It.indexOf(t)>-1&&(i={passive:!0}),e.addEventListener(t,r.dispatcher,i)}else e.attachEvent&&e.attachEvent("on"+t,r.dispatcher)}function H(e,t,n){if(Lt.has(e)){var r=Lt.get(e);if(r.handlers){if(Array.isArray(t))return V(H,e,t,n);var i=function(e,t){r.handlers[t]=[],F(e,t)};if(void 0!==t){var a=r.handlers[t];if(a){if(!n)return void i(e,t);if(n.guid)for(var o=0;o<a.length;o++)a[o].guid===n.guid&&a.splice(o--,1);F(e,t)}}else for(var s in r.handlers)Object.prototype.hasOwnProperty.call(r.handlers||{},s)&&i(e,s)}}}function z(e,t,n){var r=Lt.has(e)?Lt.get(e):{},i=e.parentNode||e.ownerDocument;if("string"==typeof t?t={type:t,target:e}:t.target||(t.target=e),t=q(t),r.dispatcher&&r.dispatcher.call(e,t,n),i&&!t.isPropagationStopped()&&!0===t.bubbles)z.call(null,i,t,n);else if(!i&&!t.defaultPrevented&&t.target&&t.target[t.type]){Lt.has(t.target)||Lt.set(t.target,{});var a=Lt.get(t.target);t.target[t.type]&&(a.disabled=!0,"function"==typeof t.target[t.type]&&t.target[t.type](),a.disabled=!1)}return!t.defaultPrevented}function W(e,t,n){if(Array.isArray(t))return V(W,e,t,n);var r=function r(){H(e,t,r),n.apply(this,arguments)};r.guid=n.guid=n.guid||N(),G(e,t,r)}function $(e,t,n){var r=function r(){H(e,t,r),n.apply(this,arguments)};r.guid=n.guid=n.guid||N(),G(e,t,r)}function Y(t,n){n&&(Ot=n),e.setTimeout(Dt,t)}function K(t,n){void 0===n&&(n={});var r=n,i=r.eventBusKey;if(i){if(!t[i].nodeName)throw new Error('The eventBusKey "'+i+'" does not refer to an element.');t.eventBusEl_=t[i]}else t.eventBusEl_=v("span",{className:"vjs-event-bus"});return a(t,Qt),t.eventedCallbacks&&t.eventedCallbacks.forEach(function(e){e()}),t.on("dispose",function(){t.off(),e.setTimeout(function(){t.eventBusEl_=null},0)}),t}function X(e,t){return a(e,Zt),e.state=a({},e.state,t),"function"==typeof e.handleStateChanged&&Ht(e)&&e.on("statechanged",e.handleStateChanged),e}function J(){for(var e={},t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return n.forEach(function(t){t&&r(t,function(t,n){if(!s(t))return void(e[n]=t);s(e[n])||(e[n]={}),e[n]=J(e[n],t)})}),e}function Q(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function Z(e,t){return(Z=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ee(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(e){return!1}}function te(e,t,n){return te=ee()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var i=Function.bind.apply(e,r),a=new i;return n&&Z(a,n.prototype),a},te.apply(null,arguments)}function ne(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function re(e,t,n){if("number"!=typeof t||t<0||t>n)throw new Error("Failed to execute '"+e+"' on 'TimeRanges': The index provided ("+t+") is non-numeric or out of bounds (0-"+n+").")}function ie(e,t,n,r){return re(e,r,n.length-1),n[r][t]}function ae(e){return void 0===e||0===e.length?{length:0,start:function(){throw new Error("This TimeRanges object is empty")},end:function(){throw new Error("This TimeRanges object is empty")}}:{length:e.length,start:ie.bind(null,"start",0,e),end:ie.bind(null,"end",1,e)}}function oe(e,t){return Array.isArray(e)?ae(e):void 0===e||void 0===t?ae():ae([[e,t]])}function se(e,t){var n,r,i=0;if(!t)return 0;e&&e.length||(e=oe(0,0));for(var a=0;a<e.length;a++)n=e.start(a),r=e.end(a),r>t&&(r=t),i+=r-n;return i/t}function ue(e){if(e instanceof ue)return e;"number"==typeof e?this.code=e:"string"==typeof e?this.message=e:o(e)&&("number"==typeof e.code&&(this.code=e.code),a(this,e)),this.message||(this.message=ue.defaultMessages[this.code]||"")}function le(e,t){var n,r=null;try{n=JSON.parse(e,t)}catch(e){r=e}return[r,n]}function ce(e){return void 0!==e&&null!==e&&"function"==typeof e.then}function de(e){ce(e)&&e.then(null,function(e){})}function fe(e,t){return t={exports:{}},e(t,t.exports),t.exports}function he(e){var t=ur.call(e);return"[object Function]"===t||"function"==typeof e&&"[object RegExp]"!==t||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)}function pe(){for(var e={},t=0;t<arguments.length;t++){var n=arguments[t];for(var r in n)Bi.call(n,r)&&(e[r]=n[r])}return e}function me(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}function ve(e,t,n){var r=e;return sr(t)?(n=t,"string"==typeof e&&(r={uri:e})):r=Ui(t,{uri:e}),r.callback=n,r}function ge(e,t,n){return t=ve(e,t,n),ye(t)}function ye(e){function t(){4===s.readyState&&setTimeout(i,0)}function n(){var e=void 0;if(e=s.response?s.response:s.responseText||_e(s),v)try{e=JSON.parse(e)}catch(e){}return e}function r(e){return clearTimeout(c),e instanceof Error||(e=new Error(""+(e||"Unknown XMLHttpRequest Error"))),e.statusCode=0,o(e,g)}function i(){if(!l){var t;clearTimeout(c),t=e.useXDR&&void 0===s.status?200:1223===s.status?204:s.status;var r=g,i=null;return 0!==t?(r={body:n(),statusCode:t,method:f,headers:{},url:d,rawRequest:s},s.getAllResponseHeaders&&(r.headers=Mi(s.getAllResponseHeaders()))):i=new Error("Internal XMLHttpRequest Error"),o(i,r,r.body)}}if(void 0===e.callback)throw new Error("callback argument missing");var a=!1,o=function(t,n,r){a||(a=!0,e.callback(t,n,r))},s=e.xhr||null;s||(s=e.cors||e.useXDR?new ge.XDomainRequest:new ge.XMLHttpRequest);var u,l,c,d=s.url=e.uri||e.url,f=s.method=e.method||"GET",h=e.body||e.data,p=s.headers=e.headers||{},m=!!e.sync,v=!1,g={body:void 0,headers:{},statusCode:0,method:f,url:d,rawRequest:s};if("json"in e&&!1!==e.json&&(v=!0,p.accept||p.Accept||(p.Accept="application/json"),"GET"!==f&&"HEAD"!==f&&(p["content-type"]||p["Content-Type"]||(p["Content-Type"]="application/json"),h=JSON.stringify(!0===e.json?h:e.json))),s.onreadystatechange=t,s.onload=i,s.onerror=r,s.onprogress=function(){},s.onabort=function(){l=!0},s.ontimeout=r,s.open(f,d,!m,e.username,e.password),m||(s.withCredentials=!!e.withCredentials),!m&&e.timeout>0&&(c=setTimeout(function(){if(!l){l=!0,s.abort("timeout");var e=new Error("XMLHttpRequest timeout");e.code="ETIMEDOUT",r(e)}},e.timeout)),s.setRequestHeader)for(u in p)p.hasOwnProperty(u)&&s.setRequestHeader(u,p[u]);else if(e.headers&&!me(e.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in e&&(s.responseType=e.responseType),"beforeSend"in e&&"function"==typeof e.beforeSend&&e.beforeSend(s),s.send(h||null),s}function _e(e){if("document"===e.responseType)return e.responseXML;var t=e.responseXML&&"parsererror"===e.responseXML.documentElement.nodeName;return""!==e.responseType||t?null:e.responseXML}function be(){}function Te(e,t){this.name="ParsingError",this.code=e.code,this.message=t||e.message}function Se(e){function t(e,t,n,r){return 3600*(0|e)+60*(0|t)+(0|n)+(0|r)/1e3}var n=e.match(/^(\d+):(\d{2})(:\d{2})?\.(\d{3})/);return n?n[3]?t(n[1],n[2],n[3].replace(":",""),n[4]):n[1]>59?t(n[1],n[2],0,n[4]):t(0,n[1],n[2],n[4]):null}function we(){this.values=Ji(null)}function ke(e,t,n,r){var i=r?e.split(r):[e];for(var a in i)if("string"==typeof i[a]){var o=i[a].split(n);if(2===o.length){var s=o[0],u=o[1];t(s,u)}}}function Ee(e,t,n){function r(){var t=Se(e);if(null===t)throw new Te(Te.Errors.BadTimeStamp,"Malformed timestamp: "+a);return e=e.replace(/^[^\sa-zA-Z-]+/,""),t}function i(){e=e.replace(/^\s+/,"")}var a=e;if(i(),t.startTime=r(),i(),"--\x3e"!==e.substr(0,3))throw new Te(Te.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '--\x3e'): "+a);e=e.substr(3),i(),t.endTime=r(),i(),function(e,t){var r=new we;ke(e,function(e,t){switch(e){case"region":for(var i=n.length-1;i>=0;i--)if(n[i].id===t){r.set(e,n[i].region);break}break;case"vertical":r.alt(e,t,["rl","lr"]);break;case"line":var a=t.split(","),o=a[0];r.integer(e,o),r.percent(e,o)&&r.set("snapToLines",!1),r.alt(e,o,["auto"]),2===a.length&&r.alt("lineAlign",a[1],["start","middle","end"]);break;case"position":a=t.split(","),r.percent(e,a[0]),2===a.length&&r.alt("positionAlign",a[1],["start","middle","end"]);break;case"size":r.percent(e,t);break;case"align":r.alt(e,t,["start","middle","end","left","right"])}},/:/,/\s/),t.region=r.get("region",null),t.vertical=r.get("vertical",""),t.line=r.get("line","auto"),t.lineAlign=r.get("lineAlign","start"),t.snapToLines=r.get("snapToLines",!0),t.size=r.get("size",100),t.align=r.get("align","middle"),t.position=r.get("position",{start:0,left:0,middle:50,end:100,right:100},t.align),t.positionAlign=r.get("positionAlign",{start:"start",left:"start",middle:"middle",end:"end",right:"end"},t.align)}(e,t)}function Ae(e,t){function n(e){return Qi[e]}for(var r,i=e.document.createElement("div"),a=i,o=[];null!==(r=function(){if(!t)return null;var e=t.match(/^([^<]*)(<[^>]*>?)?/);return function(e){return t=t.substr(e.length),e}(e[1]?e[1]:e[2])}());)if("<"!==r[0])a.appendChild(e.document.createTextNode(function(e){for(;l=e.match(/&(amp|lt|gt|lrm|rlm|nbsp);/);)e=e.replace(l[0],n);return e}(r)));else{if("/"===r[1]){o.length&&o[o.length-1]===r.substr(2).replace(">","")&&(o.pop(),a=a.parentNode);continue}var s,u=Se(r.substr(1,r.length-2));if(u){s=e.document.createProcessingInstruction("timestamp",u),a.appendChild(s);continue}var l=r.match(/^<([^.\s\/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!l)continue;if(!(s=function(t,n){var r=Zi[t];if(!r)return null;var i=e.document.createElement(r);i.localName=r;var a=ea[t];return a&&n&&(i[a]=n.trim()),i}(l[1],l[3])))continue;if(!function(e,t){return!ta[t.localName]||ta[t.localName]===e.localName}(a,s))continue;l[2]&&(s.className=l[2].substr(1).replace("."," ")),o.push(l[1]),a.appendChild(s),a=s}return i}function Ce(e){for(var t=0;t<na.length;t++){var n=na[t];if(e>=n[0]&&e<=n[1])return!0}return!1}function Le(e){function t(e,t){for(var n=t.childNodes.length-1;n>=0;n--)e.push(t.childNodes[n])}function n(e){if(!e||!e.length)return null;var r=e.pop(),i=r.textContent||r.innerText;if(i){var a=i.match(/^.*(\n|\r)/);return a?(e.length=0,a[0]):i}return"ruby"===r.tagName?n(e):r.childNodes?(t(e,r),n(e)):void 0}var r,i=[],a="";if(!e||!e.childNodes)return"ltr";for(t(i,e);a=n(i);)for(var o=0;o<a.length;o++)if(r=a.charCodeAt(o),Ce(r))return"rtl";return"ltr"}function xe(e){if("number"==typeof e.line&&(e.snapToLines||e.line>=0&&e.line<=100))return e.line;if(!e.track||!e.track.textTrackList||!e.track.textTrackList.mediaElement)return-1;for(var t=e.track,n=t.textTrackList,r=0,i=0;i<n.length&&n[i]!==t;i++)"showing"===n[i].mode&&r++;return-1*++r}function je(){}function Oe(e,t,n){je.call(this),this.cue=t,this.cueDiv=Ae(e,t.text);var r={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(r,this.cueDiv),this.div=e.document.createElement("div"),r={direction:Le(this.cueDiv),writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext",textAlign:"middle"===t.align?"center":t.align,font:n.font,whiteSpace:"pre-line",position:"absolute"},this.applyStyles(r),this.div.appendChild(this.cueDiv);var i=0;switch(t.positionAlign){case"start":i=t.position;break;case"middle":i=t.position-t.size/2;break;case"end":i=t.position-t.size}""===t.vertical?this.applyStyles({left:this.formatStyle(i,"%"),width:this.formatStyle(t.size,"%")}):this.applyStyles({top:this.formatStyle(i,"%"),height:this.formatStyle(t.size,"%")}),this.move=function(e){this.applyStyles({top:this.formatStyle(e.top,"px"),bottom:this.formatStyle(e.bottom,"px"),left:this.formatStyle(e.left,"px"),right:this.formatStyle(e.right,"px"),height:this.formatStyle(e.height,"px"),width:this.formatStyle(e.width,"px")})}}function Ie(e){var t,n,r,i;if(e.div){n=e.div.offsetHeight,r=e.div.offsetWidth,i=e.div.offsetTop;var a=(a=e.div.childNodes)&&(a=a[0])&&a.getClientRects&&a.getClientRects();e=e.div.getBoundingClientRect(),t=a?Math.max(a[0]&&a[0].height||0,e.height/a.length):0}this.left=e.left,this.right=e.right,this.top=e.top||i,this.height=e.height||n,this.bottom=e.bottom||i+(e.height||n),this.width=e.width||r,this.lineHeight=void 0!==t?t:e.lineHeight}function Pe(e,t,n,r){var i=new Ie(t),a=t.cue,o=xe(a),s=[];if(a.snapToLines){var u;switch(a.vertical){case"":s=["+y","-y"],u="height";break;case"rl":s=["+x","-x"],u="width";break;case"lr":s=["-x","+x"],u="width"}var l=i.lineHeight,c=l*Math.round(o),d=n[u]+l,f=s[0];Math.abs(c)>d&&(c=c<0?-1:1,c*=Math.ceil(d/l)*l),o<0&&(c+=""===a.vertical?n.height:n.width,s=s.reverse()),i.move(f,c)}else{var h=i.lineHeight/n.height*100;switch(a.lineAlign){case"middle":o-=h/2;break;case"end":o-=h}switch(a.vertical){case"":t.applyStyles({top:t.formatStyle(o,"%")});break;case"rl":t.applyStyles({left:t.formatStyle(o,"%")});break;case"lr":t.applyStyles({right:t.formatStyle(o,"%")})}s=["+y","-x","+x","-y"],i=new Ie(t)}var p=function(e,t){for(var i,a=new Ie(e),o=1,s=0;s<t.length;s++){for(;e.overlapsOppositeAxis(n,t[s])||e.within(n)&&e.overlapsAny(r);)e.move(t[s]);if(e.within(n))return e;var u=e.intersectPercentage(n);o>u&&(i=new Ie(e),o=u),e=new Ie(a)}return i||a}(i,s);t.move(p.toCSSCompatValues(n))}function Re(){}function De(e){return"string"==typeof e&&!!aa[e.toLowerCase()]&&e.toLowerCase()}function Me(e){return"string"==typeof e&&!!oa[e.toLowerCase()]&&e.toLowerCase()}function Ue(e,t,n){this.hasBeenReset=!1;var r="",i=!1,a=e,o=t,s=n,u=null,l="",c=!0,d="auto",f="start",h=50,p="middle",m=50,v="middle";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return r},set:function(e){r=""+e}},pauseOnExit:{enumerable:!0,get:function(){return i},set:function(e){i=!!e}},startTime:{enumerable:!0,get:function(){return a},set:function(e){if("number"!=typeof e)throw new TypeError("Start time must be set to a number.");a=e,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return o},set:function(e){if("number"!=typeof e)throw new TypeError("End time must be set to a number.");o=e,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return s},set:function(e){s=""+e,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return u},set:function(e){u=e,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return l},set:function(e){var t=De(e);if(!1===t)throw new SyntaxError("An invalid or illegal string was specified.");l=t,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return c},set:function(e){c=!!e,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return d},set:function(e){if("number"!=typeof e&&e!==ia)throw new SyntaxError("An invalid number or illegal string was specified.");d=e,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return f},set:function(e){var t=Me(e);if(!t)throw new SyntaxError("An invalid or illegal string was specified.");f=t,this.hasBeenReset=!0}},position:{enumerable:!0,get:function(){return h},set:function(e){if(e<0||e>100)throw new Error("Position must be between 0 and 100.");h=e,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return p},set:function(e){var t=Me(e);if(!t)throw new SyntaxError("An invalid or illegal string was specified.");p=t,this.hasBeenReset=!0}},size:{enumerable:!0,get:function(){return m},set:function(e){if(e<0||e>100)throw new Error("Size must be between 0 and 100.");m=e,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return v},set:function(e){var t=Me(e);if(!t)throw new SyntaxError("An invalid or illegal string was specified.");v=t,this.hasBeenReset=!0}}}),this.displayState=void 0}function Be(e){return"string"==typeof e&&!!ua[e.toLowerCase()]&&e.toLowerCase()}function Ne(e){return"number"==typeof e&&e>=0&&e<=100}function Fe(){var e=100,t=3,n=0,r=100,i=0,a=100,o="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return e},set:function(t){if(!Ne(t))throw new Error("Width must be between 0 and 100.");e=t}},lines:{enumerable:!0,get:function(){return t},set:function(e){if("number"!=typeof e)throw new TypeError("Lines must be set to a number.");t=e}},regionAnchorY:{enumerable:!0,get:function(){return r},set:function(e){if(!Ne(e))throw new Error("RegionAnchorX must be between 0 and 100.");r=e}},regionAnchorX:{enumerable:!0,get:function(){return n},set:function(e){if(!Ne(e))throw new Error("RegionAnchorY must be between 0 and 100.");n=e}},viewportAnchorY:{enumerable:!0,get:function(){return a},set:function(e){if(!Ne(e))throw new Error("ViewportAnchorY must be between 0 and 100.");a=e}},viewportAnchorX:{enumerable:!0,get:function(){return i},set:function(e){if(!Ne(e))throw new Error("ViewportAnchorX must be between 0 and 100.");i=e}},scroll:{enumerable:!0,get:function(){return o},set:function(e){var t=Be(e);if(!1===t)throw new SyntaxError("An invalid or illegal string was specified.");o=t}}})}function Ve(e,t,n,r,i){void 0===i&&(i={});var a=e.textTracks();i.kind=t,n&&(i.label=n),r&&(i.language=r),i.tech=e;var o=new Xi.text.TrackClass(i);return a.addTrack(o),o}function qe(e,t){fa[e]=fa[e]||[],fa[e].push(t)}function Ge(e,t,n){e.setTimeout(function(){return Qe(t,fa[t.type],n,e)},1)}function He(e,t){e.forEach(function(e){return e.setTech&&e.setTech(t)})}function ze(e,t,n){return e.reduceRight(Ye(n),t[n]())}function We(e,t,n,r){return t[n](e.reduce(Ye(n),r))}function $e(e,t,n,r){void 0===r&&(r=null);var i="call"+tn(n),a=e.reduce(Ye(i),r),o=a===pa,s=o?null:t[n](a);return Ke(e,n,s,o),s}function Ye(e){return function(t,n){return t===pa?pa:n[e]?n[e](t):t}}function Ke(e,t,n,r){for(var i=e.length-1;i>=0;i--){var a=e[i];a[t]&&a[t](r,n)}}function Xe(e){ha[e.id()]=null}function Je(e,t){var n=ha[e.id()],r=null;if(void 0===n||null===n)return r=t(e),ha[e.id()]=[[t,r]],r;for(var i=0;i<n.length;i++){var a=n[i],o=a[0],s=a[1];o===t&&(r=s)}return null===r&&(r=t(e),n.push([t,r])),r}function Qe(e,t,n,r,i,o){void 0===e&&(e={}),void 0===t&&(t=[]),void 0===i&&(i=[]),void 0===o&&(o=!1);var s=t,u=s[0],l=s.slice(1);if("string"==typeof u)Qe(e,fa[u],n,r,i,o);else if(u){var c=Je(r,u);if(!c.setSource)return i.push(c),Qe(e,l,n,r,i,o);c.setSource(a({},e),function(t,a){if(t)return Qe(e,l,n,r,i,o);i.push(c),Qe(a,e.type===a.type?l:fa[a.type],n,r,i,o)})}else l.length?Qe(e,l,n,r,i,o):o?n(e,i):Qe(e,fa["*"],n,r,i,!0)}function Ze(e){if(!e.type){var t=_a(e.src);t&&(e.type=t)}return e}function et(e,t){var n;if(4===e.length)n=e[1]+e[1]+e[2]+e[2]+e[3]+e[3];else{if(7!==e.length)throw new Error("Invalid color code provided, "+e+"; must be formatted as e.g. #f0e or #f604e2.");n=e.slice(1)}return"rgba("+parseInt(n.slice(0,2),16)+","+parseInt(n.slice(2,4),16)+","+parseInt(n.slice(4,6),16)+","+t+")"}function tt(e,t,n){try{e.style[t]=n}catch(e){return}}function nt(e){Pa=e}function rt(){Pa=Ia}function it(e,t){return void 0===t&&(t=e),Pa(e,t)}function at(e,t){if(t&&(e=t(e)),e&&"none"!==e)return e}function ot(e,t){return at(e.options[e.options.selectedIndex].value,t)}function st(e,t,n){if(t)for(var r=0;r<e.options.length;r++)if(at(e.options[r].value,n)===t){e.selectedIndex=r;break}}function ut(e,t,n){var r=ut.getPlayer(e);if(r)return t&&Tt.warn('Player "'+e+'" is already initialised. Options will not be applied.'),n&&r.ready(n),r;var i="string"==typeof e?Et("#"+ys(e)):e;if(!h(i))throw new TypeError("The element or ID supplied is not valid. (videojs)");i.ownerDocument.defaultView&&i.ownerDocument.body.contains(i)||Tt.warn("The element supplied is not included in the DOM"),t=t||{},ut.hooks("beforesetup").forEach(function(e){var n=e(i,J(t));if(!o(n)||Array.isArray(n))return void Tt.error("please return an object in beforesetup hooks");t=J(t,n)});var a=rn.getComponent("Player");return r=new a(i,t,n),ut.hooks("setup").forEach(function(e){return e(r)}),r}function lt(){return lt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lt.apply(this,arguments)}function ct(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function dt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ft(t){for(var n=e.atob(t),r=new Uint8Array(n.length),i=0;i<n.length;i++)r[i]=n.charCodeAt(i);return r}function ht(e){return e.subarray(0,e.byteLength-e[e.byteLength-1])}function pt(e,t){return function(n){var r=this;if(!t)return new Mh(e);if(Mh&&!n){var i=t.toString().replace(/^function.+?{/,"").slice(0,-1),a=mt(i);return this[Ih]=new Mh(a),vt(this[Ih],a),this[Ih]}var o={postMessage:function(e){r.onmessage&&setTimeout(function(){r.onmessage({data:e,target:o})})}};t.call(o),this.postMessage=function(e){setTimeout(function(){o.onmessage({data:e,target:r})})},this.isThisThread=!0}}function mt(e){try{return Dh.createObjectURL(new Blob([e],{type:Ph}))}catch(n){var t=new Rh;return t.append(e),Dh.createObjectURL(t.getBlob(type))}}function vt(e,t){if(e&&t){var n=e.terminate;e.objURL=t,e.terminate=function(){e.objURL&&Dh.revokeObjectURL(e.objURL),n.call(e)}}}function gt(){}e=e&&e.hasOwnProperty("default")?e.default:e,t=t&&t.hasOwnProperty("default")?t.default:t;var yt="7.6.3",_t=[],bt=function(t,n){return function(r,i,a){var o=n.levels[i],s=new RegExp("^("+o+")$");if("log"!==r&&a.unshift(r.toUpperCase()+":"),a.unshift(t+":"),_t&&_t.push([].concat(a)),e.console){var u=e.console[r];u||"debug"!==r||(u=e.console.info||e.console.log),u&&o&&s.test(r)&&u[Array.isArray(a)?"apply":"call"](e.console,a)}}},Tt=n("VIDEOJS"),St=Tt.createLogger,wt=Object.prototype.toString,kt=function(e){return o(e)?Object.keys(e):[]},Et=m("querySelector"),At=m("querySelectorAll"),Ct=Object.freeze({isReal:f,isEl:h,isInFrame:p,createEl:v,textContent:g,prependTo:y,hasClass:_,addClass:b,removeClass:T,toggleClass:S,setAttributes:w,getAttributes:k,getAttribute:E,setAttribute:A,removeAttribute:C,blockTextSelection:L,unblockTextSelection:x,getBoundingClientRect:j,findPosition:O,getPointerPosition:I,isTextNode:P,emptyEl:R,normalizeContent:D,appendContent:M,insertContent:U,isSingleLeftClick:B,$:Et,$$:At}),Lt=new WeakMap,xt=1,jt=!1;!function(){try{var t=Object.defineProperty({},"passive",{get:function(){jt=!0}});e.addEventListener("test",null,t),e.removeEventListener("test",null,t)}catch(e){}}();var Ot,It=["touchstart","touchmove"],Pt=Object.freeze({fixEvent:q,on:G,off:H,trigger:z,one:W,any:$}),Rt=!1,Dt=function(){if(f()&&!1!==Ot.options.autoSetup){var e=Array.prototype.slice.call(t.getElementsByTagName("video")),n=Array.prototype.slice.call(t.getElementsByTagName("audio")),r=Array.prototype.slice.call(t.getElementsByTagName("video-js")),i=e.concat(n,r);if(i&&i.length>0)for(var a=0,o=i.length;a<o;a++){var s=i[a];if(!s||!s.getAttribute){Y(1);break}if(void 0===s.player){var u=s.getAttribute("data-setup");null!==u&&Ot(s)}}else Rt||Y(1)}};f()&&"complete"===t.readyState?Rt=!0:W(e,"load",function(){Rt=!0});var Mt=function(e){var n=t.createElement("style");return n.className=e,n},Ut=function(e,t){e.styleSheet?e.styleSheet.cssText=t:e.textContent=t},Bt=30,Nt=function(e,t,n){t.guid||(t.guid=N());var r=t.bind(e);return r.guid=n?n+"_"+t.guid:t.guid,r},Ft=function(t,n){var r=e.performance.now();return function(){var i=e.performance.now();i-r>=n&&(t.apply(void 0,arguments),r=i)}},Vt=function(t,n,r,i){void 0===i&&(i=e);var a,o=function(){i.clearTimeout(a),a=null},s=function(){var e=this,o=arguments,s=function(){a=null,s=null,r||t.apply(e,o)};!a&&r&&t.apply(e,o),i.clearTimeout(a),a=i.setTimeout(s,n)};return s.cancel=o,s},qt=function(){};qt.prototype.allowedEvents_={},qt.prototype.on=function(e,t){var n=this.addEventListener;this.addEventListener=function(){},G(this,e,t),this.addEventListener=n},qt.prototype.addEventListener=qt.prototype.on,qt.prototype.off=function(e,t){H(this,e,t)},qt.prototype.removeEventListener=qt.prototype.off,qt.prototype.one=function(e,t){var n=this.addEventListener;this.addEventListener=function(){},W(this,e,t),this.addEventListener=n},qt.prototype.any=function(e,t){var n=this.addEventListener;this.addEventListener=function(){},$(this,e,t),this.addEventListener=n},qt.prototype.trigger=function(e){var t=e.type||e;"string"==typeof e&&(e={type:t}),e=q(e),this.allowedEvents_[t]&&this["on"+t]&&this["on"+t](e),z(this,e)},qt.prototype.dispatchEvent=qt.prototype.trigger;var Gt;qt.prototype.queueTrigger=function(t){var n=this;Gt||(Gt=new Map);var r=t.type||t,i=Gt.get(this);i||(i=new Map,Gt.set(this,i));var a=i.get(r);i.delete(r),e.clearTimeout(a);var o=e.setTimeout(function(){0===i.size&&(i=null,Gt.delete(n)),n.trigger(t)},0);i.set(r,o)};var Ht=function(e){return e instanceof qt||!!e.eventBusEl_&&["on","one","off","trigger"].every(function(t){return"function"==typeof e[t]})},zt=function(e,t){Ht(e)?t():(e.eventedCallbacks||(e.eventedCallbacks=[]),e.eventedCallbacks.push(t))},Wt=function(e){return"string"==typeof e&&/\S/.test(e)||Array.isArray(e)&&!!e.length},$t=function(e){if(!e.nodeName&&!Ht(e))throw new Error("Invalid target; must be a DOM node or evented object.")},Yt=function(e){if(!Wt(e))throw new Error("Invalid event type; must be a non-empty string or array.")},Kt=function(e){if("function"!=typeof e)throw new Error("Invalid listener; must be a function.")},Xt=function(e,t){var n,r,i,a=t.length<3||t[0]===e||t[0]===e.eventBusEl_;return a?(n=e.eventBusEl_,t.length>=3&&t.shift(),r=t[0],i=t[1]):(n=t[0],r=t[1],i=t[2]),$t(n),Yt(r),Kt(i),i=Nt(e,i),{isTargetingSelf:a,target:n,type:r,listener:i}},Jt=function(e,t,n,r){$t(e),e.nodeName?Pt[t](e,n,r):e[t](n,r)},Qt={on:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Xt(this,n),a=i.isTargetingSelf,o=i.target,s=i.type,u=i.listener;if(Jt(o,"on",s,u),!a){var l=function(){return e.off(o,s,u)};l.guid=u.guid;var c=function(){return e.off("dispose",l)};c.guid=u.guid,Jt(this,"on","dispose",l),Jt(o,"on","dispose",c)}},one:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Xt(this,n),a=i.isTargetingSelf,o=i.target,s=i.type,u=i.listener;if(a)Jt(o,"one",s,u);else{var l=function t(){e.off(o,s,t);for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];u.apply(null,r)};l.guid=u.guid,Jt(o,"one",s,l)}},any:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Xt(this,n),a=i.isTargetingSelf,o=i.target,s=i.type,u=i.listener;if(a)Jt(o,"any",s,u);else{var l=function t(){e.off(o,s,t);for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];u.apply(null,r)};l.guid=u.guid,Jt(o,"any",s,l)}},off:function(e,t,n){if(!e||Wt(e))H(this.eventBusEl_,e,t);else{var r=e,i=t;$t(r),Yt(i),Kt(n),n=Nt(this,n),this.off("dispose",n),r.nodeName?(H(r,i,n),H(r,"dispose",n)):Ht(r)&&(r.off(i,n),r.off("dispose",n))}},trigger:function(e,t){return z(this.eventBusEl_,e,t)}},Zt={state:{},setState:function(e){var t=this;"function"==typeof e&&(e=e());var n;return r(e,function(e,r){t.state[r]!==e&&(n=n||{},n[r]={from:t.state[r],to:e}),t.state[r]=e}),n&&Ht(this)&&this.trigger({changes:n,type:"statechanged"}),n}},en=function(e){return"string"!=typeof e?e:e.replace(/./,function(e){return e.toLowerCase()})},tn=function(e){return"string"!=typeof e?e:e.replace(/./,function(e){return e.toUpperCase()})},nn=function(e,t){return tn(e)===tn(t)},rn=function(){function t(e,t,n){if(!e&&this.play?this.player_=e=this:this.player_=e,this.parentComponent_=null,this.options_=J({},this.options_),t=this.options_=J(this.options_,t),this.id_=t.id||t.el&&t.el.id,!this.id_){var r=e&&e.id&&e.id()||"no_player";this.id_=r+"_component_"+N()}this.name_=t.name||null,t.el?this.el_=t.el:!1!==t.createEl&&(this.el_=this.createEl()),!1!==t.evented&&K(this,{eventBusKey:this.el_?"el_":null}),X(this,this.constructor.defaultState),this.children_=[],this.childIndex_={},this.childNameIndex_={},this.setTimeoutIds_=new Set,this.setIntervalIds_=new Set,this.rafIds_=new Set,this.clearingTimersOnDispose_=!1,!1!==t.initChildren&&this.initChildren(),this.ready(n),!1!==t.reportTouchActivity&&this.enableTouchActivity()}var n=t.prototype;return n.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.children_)for(var e=this.children_.length-1;e>=0;e--)this.children_[e].dispose&&this.children_[e].dispose();this.children_=null,this.childIndex_=null,this.childNameIndex_=null,this.parentComponent_=null,this.el_&&(this.el_.parentNode&&this.el_.parentNode.removeChild(this.el_),Lt.has(this.el_)&&Lt.delete(this.el_),this.el_=null),this.player_=null},n.player=function(){return this.player_},n.options=function(e){return e?(this.options_=J(this.options_,e),this.options_):this.options_},n.el=function(){return this.el_},n.createEl=function(e,t,n){return v(e,t,n)},n.localize=function(e,t,n){void 0===n&&(n=e);var r=this.player_.language&&this.player_.language(),i=this.player_.languages&&this.player_.languages(),a=i&&i[r],o=r&&r.split("-")[0],s=i&&i[o],u=n;return a&&a[e]?u=a[e]:s&&s[e]&&(u=s[e]),t&&(u=u.replace(/\{(\d+)\}/g,function(e,n){var r=t[n-1],i=r;return void 0===r&&(i=e),i})),u},n.contentEl=function(){return this.contentEl_||this.el_},n.id=function(){return this.id_},n.name=function(){return this.name_},n.children=function(){return this.children_},n.getChildById=function(e){return this.childIndex_[e]},n.getChild=function(e){if(e)return this.childNameIndex_[e]},n.addChild=function(e,n,r){void 0===n&&(n={}),void 0===r&&(r=this.children_.length);var i,a;if("string"==typeof e){a=tn(e);var o=n.componentClass||a;n.name=a;var s=t.getComponent(o);if(!s)throw new Error("Component "+o+" does not exist");if("function"!=typeof s)return null;i=new s(this.player_||this,n)}else i=e;if(i.parentComponent_&&i.parentComponent_.removeChild(i),this.children_.splice(r,0,i),i.parentComponent_=this,"function"==typeof i.id&&(this.childIndex_[i.id()]=i),a=a||i.name&&tn(i.name()),a&&(this.childNameIndex_[a]=i,this.childNameIndex_[en(a)]=i),"function"==typeof i.el&&i.el()){var u=this.contentEl().children,l=u[r]||null;this.contentEl().insertBefore(i.el(),l)}return i},n.removeChild=function(e){if("string"==typeof e&&(e=this.getChild(e)),e&&this.children_){for(var t=!1,n=this.children_.length-1;n>=0;n--)if(this.children_[n]===e){t=!0,this.children_.splice(n,1);break}if(t){e.parentComponent_=null,this.childIndex_[e.id()]=null,this.childNameIndex_[tn(e.name())]=null,this.childNameIndex_[en(e.name())]=null;var r=e.el();r&&r.parentNode===this.contentEl()&&this.contentEl().removeChild(e.el())}}},n.initChildren=function(){var e=this,n=this.options_.children;if(n){var r,i=this.options_,a=function(t){var n=t.name,r=t.opts;if(void 0!==i[n]&&(r=i[n]),!1!==r){!0===r&&(r={}),r.playerOptions=e.options_.playerOptions;var a=e.addChild(n,r);a&&(e[n]=a)}},o=t.getComponent("Tech");r=Array.isArray(n)?n:Object.keys(n),r.concat(Object.keys(this.options_).filter(function(e){return!r.some(function(t){return"string"==typeof t?e===t:e===t.name})})).map(function(t){var r,i;return"string"==typeof t?(r=t,i=n[r]||e.options_[r]||{}):(r=t.name,i=t),{name:r,opts:i}}).filter(function(e){var n=t.getComponent(e.opts.componentClass||tn(e.name));return n&&!o.isTech(n)}).forEach(a)}},n.buildCSSClass=function(){return""},n.ready=function(e,t){if(void 0===t&&(t=!1),e)return this.isReady_?void(t?e.call(this):this.setTimeout(e,1)):(this.readyQueue_=this.readyQueue_||[],void this.readyQueue_.push(e))},n.triggerReady=function(){this.isReady_=!0,this.setTimeout(function(){var e=this.readyQueue_;this.readyQueue_=[],e&&e.length>0&&e.forEach(function(e){e.call(this)},this),this.trigger("ready")},1)},n.$=function(e,t){return Et(e,t||this.contentEl())},n.$$=function(e,t){return At(e,t||this.contentEl())},n.hasClass=function(e){return _(this.el_,e)},n.addClass=function(e){b(this.el_,e)},n.removeClass=function(e){T(this.el_,e)},n.toggleClass=function(e,t){S(this.el_,e,t)},n.show=function(){this.removeClass("vjs-hidden")},n.hide=function(){this.addClass("vjs-hidden")},n.lockShowing=function(){this.addClass("vjs-lock-showing")},n.unlockShowing=function(){this.removeClass("vjs-lock-showing")},n.getAttribute=function(e){return E(this.el_,e)},n.setAttribute=function(e,t){A(this.el_,e,t)},n.removeAttribute=function(e){C(this.el_,e)},n.width=function(e,t){return this.dimension("width",e,t)},n.height=function(e,t){return this.dimension("height",e,t)},n.dimensions=function(e,t){this.width(e,!0),this.height(t)},n.dimension=function(e,t,n){if(void 0!==t)return null!==t&&t===t||(t=0),-1!==(""+t).indexOf("%")||-1!==(""+t).indexOf("px")?this.el_.style[e]=t:this.el_.style[e]="auto"===t?"":t+"px",void(n||this.trigger("componentresize"));if(!this.el_)return 0;var r=this.el_.style[e],i=r.indexOf("px");return-1!==i?parseInt(r.slice(0,i),10):parseInt(this.el_["offset"+tn(e)],10)},n.currentDimension=function(e){var t=0;if("width"!==e&&"height"!==e)throw new Error("currentDimension only accepts width or height value");if(t=u(this.el_,e),0===(t=parseFloat(t))||isNaN(t)){var n="offset"+tn(e);t=this.el_[n]}return t},n.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},n.currentWidth=function(){return this.currentDimension("width")},n.currentHeight=function(){return this.currentDimension("height")},n.focus=function(){this.el_.focus()},n.blur=function(){this.el_.blur()},n.handleKeyDown=function(e){this.player_&&(e.stopPropagation(),this.player_.handleKeyDown(e))},n.handleKeyPress=function(e){this.handleKeyDown(e)},n.emitTapEvents=function(){var t,n=0,r=null;this.on("touchstart",function(i){1===i.touches.length&&(r={pageX:i.touches[0].pageX,pageY:i.touches[0].pageY},n=e.performance.now(),t=!0)}),this.on("touchmove",function(e){if(e.touches.length>1)t=!1;else if(r){var n=e.touches[0].pageX-r.pageX,i=e.touches[0].pageY-r.pageY,a=Math.sqrt(n*n+i*i);a>10&&(t=!1)}});var i=function(){t=!1};this.on("touchleave",i),this.on("touchcancel",i),this.on("touchend",function(i){r=null,!0===t&&e.performance.now()-n<200&&(i.preventDefault(),this.trigger("tap"))})},n.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var e,t=Nt(this.player(),this.player().reportUserActivity);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)}},n.setTimeout=function(t,n){var r,i=this;return t=Nt(this,t),this.clearTimersOnDispose_(),r=e.setTimeout(function(){i.setTimeoutIds_.has(r)&&i.setTimeoutIds_.delete(r),t()},n),this.setTimeoutIds_.add(r),r},n.clearTimeout=function(t){return this.setTimeoutIds_.has(t)&&(this.setTimeoutIds_.delete(t),e.clearTimeout(t)),t},n.setInterval=function(t,n){t=Nt(this,t),this.clearTimersOnDispose_();var r=e.setInterval(t,n);return this.setIntervalIds_.add(r),r},n.clearInterval=function(t){return this.setIntervalIds_.has(t)&&(this.setIntervalIds_.delete(t),e.clearInterval(t)),t},n.requestAnimationFrame=function(t){var n=this;if(!this.supportsRaf_)return this.setTimeout(t,1e3/60);this.clearTimersOnDispose_();var r;return t=Nt(this,t),r=e.requestAnimationFrame(function(){n.rafIds_.has(r)&&n.rafIds_.delete(r),t()}),this.rafIds_.add(r),r},n.cancelAnimationFrame=function(t){return this.supportsRaf_?(this.rafIds_.has(t)&&(this.rafIds_.delete(t),e.cancelAnimationFrame(t)),t):this.clearTimeout(t)},n.clearTimersOnDispose_=function(){var e=this;this.clearingTimersOnDispose_||(this.clearingTimersOnDispose_=!0,this.one("dispose",function(){[["rafIds_","cancelAnimationFrame"],["setTimeoutIds_","clearTimeout"],["setIntervalIds_","clearInterval"]].forEach(function(t){var n=t[0],r=t[1];e[n].forEach(e[r],e)}),e.clearingTimersOnDispose_=!1}))},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"),i=r&&r.isTech(n),a=t===n||t.prototype.isPrototypeOf(n.prototype);if(i||!a){var o;throw o=i?"techs must be registered using Tech.registerTech()":"must be a Component subclass",new Error('Illegal component, "'+e+'"; '+o+".")}e=tn(e),t.components_||(t.components_={});var s=t.getComponent("Player");if("Player"===e&&s&&s.players){var u=s.players,l=Object.keys(u);if(u&&l.length>0&&l.map(function(e){return u[e]}).every(Boolean))throw new Error("Can not register Player component after player has been created.")}return t.components_[e]=n,t.components_[en(e)]=n,n},t.getComponent=function(e){if(e&&t.components_)return t.components_[e]},t}();rn.prototype.supportsRaf_="function"==typeof e.requestAnimationFrame&&"function"==typeof e.cancelAnimationFrame,rn.registerComponent("Component",rn);for(var an,on=e.navigator&&e.navigator.userAgent||"",sn=/AppleWebKit\/([\d.]+)/i.exec(on),un=sn?parseFloat(sn.pop()):null,ln=/iPad/i.test(on),cn=/iPhone/i.test(on)&&!ln,dn=/iPod/i.test(on),fn=cn||ln||dn,hn=function(){var e=on.match(/OS (\d+)_/i);return e&&e[1]?e[1]:null}(),pn=/Android/i.test(on),mn=function(){var e=on.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!e)return null;var t=e[1]&&parseFloat(e[1]),n=e[2]&&parseFloat(e[2]);return t&&n?parseFloat(e[1]+"."+e[2]):t||null}(),vn=pn&&mn<5&&un<537,gn=/Firefox/i.test(on),yn=/Edge/i.test(on),_n=!yn&&(/Chrome/i.test(on)||/CriOS/i.test(on)),bn=function(){var e=on.match(/(Chrome|CriOS)\/(\d+)/);return e&&e[2]?parseFloat(e[2]):null}(),Tn=function(){var e=/MSIE\s(\d+)\.\d/.exec(on),t=e&&parseFloat(e[1]);return!t&&/Trident\/7.0/i.test(on)&&/rv:11.0/.test(on)&&(t=11),t}(),Sn=/Safari/i.test(on)&&!_n&&!pn&&!yn,wn=(Sn||fn)&&!_n,kn=/Windows/i.test(on),En=(f()&&("ontouchstart"in e||e.navigator.maxTouchPoints||e.DocumentTouch&&e.document instanceof e.DocumentTouch)),An=Object.freeze({IS_IPAD:ln,IS_IPHONE:cn,IS_IPOD:dn,IS_IOS:fn,IOS_VERSION:hn,IS_ANDROID:pn,ANDROID_VERSION:mn,IS_NATIVE_ANDROID:vn,IS_FIREFOX:gn,IS_EDGE:yn,IS_CHROME:_n,CHROME_VERSION:bn,IE_VERSION:Tn,IS_SAFARI:Sn,IS_ANY_SAFARI:wn,IS_WINDOWS:kn,TOUCH_ENABLED:En}),Cn={prefixed:!0},Ln=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror","fullscreen"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror","-webkit-full-screen"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror","-moz-full-screen"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError","-ms-fullscreen"]],xn=Ln[0],jn=0;jn<Ln.length;jn++)if(Ln[jn][1]in t){an=Ln[jn];break}if(an){for(var On=0;On<an.length;On++)Cn[xn[On]]=an[On];Cn.prefixed=an[0]!==xn[0]}ue.prototype.code=0,ue.prototype.message="",ue.prototype.status=null,ue.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],ue.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 In=0;In<ue.errorTypes.length;In++)ue[ue.errorTypes[In]]=In,ue.prototype[ue.errorTypes[In]]=In;var Pn=le,Rn=function(e){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce(function(t,n,r){return e[n]&&(t[n]=e[n]),t},{cues:e.cues&&Array.prototype.map.call(e.cues,function(e){return{startTime:e.startTime,endTime:e.endTime,text:e.text,id:e.id}})})},Dn=function(e){var t=e.$$("track"),n=Array.prototype.map.call(t,function(e){return e.track});return Array.prototype.map.call(t,function(e){var t=Rn(e.track);return e.src&&(t.src=e.src),t}).concat(Array.prototype.filter.call(e.textTracks(),function(e){return-1===n.indexOf(e)}).map(Rn))},Mn=function(e,t){return e.forEach(function(e){var n=t.addRemoteTextTrack(e).track;!e.src&&e.cues&&e.cues.forEach(function(e){return n.addCue(e)})}),t.textTracks()},Un={textTracksToJson:Dn,jsonToTextTracks:Mn,trackToJson_:Rn},Bn=fe(function(e,t){function n(e){if(e&&"object"==typeof e){var t=e.which||e.keyCode||e.charCode;t&&(e=t)}if("number"==typeof e)return o[e];var n=String(e),a=r[n.toLowerCase()];if(a)return a;var a=i[n.toLowerCase()];return a||(1===n.length?n.charCodeAt(0):void 0)}n.isEventKey=function(e,t){if(e&&"object"==typeof e){var n=e.which||e.keyCode||e.charCode;if(null===n||void 0===n)return!1;if("string"==typeof t){var a=r[t.toLowerCase()];if(a)return a===n;var a=i[t.toLowerCase()];if(a)return a===n}else if("number"==typeof t)return t===n;return!1}},t=e.exports=n;var r=t.code=t.codes={backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,"pause/break":19,"caps lock":20,esc:27,space:32,"page up":33,"page down":34,end:35,home:36,left:37,up:38,right:39,down:40,insert:45,delete:46,command:91,"left command":91,"right command":93,"numpad *":106,"numpad +":107,"numpad -":109,"numpad .":110,"numpad /":111,"num lock":144,"scroll lock":145,"my computer":182,"my calculator":183,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222},i=t.aliases={windows:91,"⇧":16,"⌥":18,"⌃":17,"⌘":91,ctl:17,control:17,option:18,pause:19,break:19,caps:20,return:13,escape:27,spc:32,spacebar:32,pgup:33,pgdn:34,ins:45,del:46,cmd:91};for(a=97;a<123;a++)r[String.fromCharCode(a)]=a-32;for(var a=48;a<58;a++)r[a-48]=a;for(a=1;a<13;a++)r["f"+a]=a+111;for(a=0;a<10;a++)r["numpad "+a]=a+96;var o=t.names=t.title={};for(a in r)o[r[a]]=a;for(var s in i)r[s]=i[s]}),Nn=(Bn.code,Bn.codes,Bn.aliases,Bn.names,Bn.title,"vjs-modal-dialog"),Fn=function(n){function r(e,t){var r;return r=n.call(this,e,t)||this,r.opened_=r.hasBeenOpened_=r.hasBeenFilled_=!1,r.closeable(!r.options_.uncloseable),r.content(r.options_.content),r.contentEl_=v("div",{className:Nn+"-content"},{role:"document"}),r.descEl_=v("p",{className:Nn+"-description vjs-control-text",id:r.el().getAttribute("aria-describedby")}),g(r.descEl_,r.description()),r.el_.appendChild(r.descEl_),r.el_.appendChild(r.contentEl_),r}Q(r,n);var i=r.prototype;return i.createEl=function(){return n.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":this.id()+"_description","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},i.dispose=function(){this.contentEl_=null,this.descEl_=null,this.previouslyActiveEl_=null,n.prototype.dispose.call(this)},i.buildCSSClass=function(){return Nn+" vjs-hidden "+n.prototype.buildCSSClass.call(this)},i.label=function(){return this.localize(this.options_.label||"Modal Window")},i.description=function(){var e=this.options_.description||this.localize("This is a modal window.");return this.closeable()&&(e+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),e},i.open=function(){if(!this.opened_){var e=this.player();this.trigger("beforemodalopen"),this.opened_=!0,(this.options_.fillAlways||!this.hasBeenOpened_&&!this.hasBeenFilled_)&&this.fill(),this.wasPlaying_=!e.paused(),this.options_.pauseOnOpen&&this.wasPlaying_&&e.pause(),this.on("keydown",this.handleKeyDown),this.hadControls_=e.controls(),e.controls(!1),this.show(),this.conditionalFocus_(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.hasBeenOpened_=!0}},i.opened=function(e){return"boolean"==typeof e&&this[e?"open":"close"](),this.opened_},i.close=function(){if(this.opened_){var e=this.player();this.trigger("beforemodalclose"),this.opened_=!1,this.wasPlaying_&&this.options_.pauseOnOpen&&e.play(),this.off("keydown",this.handleKeyDown),this.hadControls_&&e.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.conditionalBlur_(),this.options_.temporary&&this.dispose()}},i.closeable=function(e){if("boolean"==typeof e){var t=this.closeable_=!!e,n=this.getChild("closeButton");if(t&&!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)}!t&&n&&(this.off(n,"close",this.close),this.removeChild(n),n.dispose())}return this.closeable_},i.fill=function(){this.fillWith(this.content())},i.fillWith=function(e){var t=this.contentEl(),n=t.parentNode,r=t.nextSibling;this.trigger("beforemodalfill"),this.hasBeenFilled_=!0,n.removeChild(t),this.empty(),U(t,e),this.trigger("modalfill"),r?n.insertBefore(t,r):n.appendChild(t);var i=this.getChild("closeButton");i&&n.appendChild(i.el_)},i.empty=function(){this.trigger("beforemodalempty"),R(this.contentEl()),this.trigger("modalempty")},i.content=function(e){return void 0!==e&&(this.content_=e),this.content_},i.conditionalFocus_=function(){var e=t.activeElement,n=this.player_.el_;this.previouslyActiveEl_=null,(n.contains(e)||n===e)&&(this.previouslyActiveEl_=e,this.focus())},i.conditionalBlur_=function(){this.previouslyActiveEl_&&(this.previouslyActiveEl_.focus(),this.previouslyActiveEl_=null)},i.handleKeyDown=function(e){if(e.stopPropagation(),Bn.isEventKey(e,"Escape")&&this.closeable())return e.preventDefault(),void this.close();if(Bn.isEventKey(e,"Tab")){for(var n,r=this.focusableEls_(),i=this.el_.querySelector(":focus"),a=0;a<r.length;a++)if(i===r[a]){n=a;break}t.activeElement===this.el_&&(n=0),e.shiftKey&&0===n?(r[r.length-1].focus(),e.preventDefault()):e.shiftKey||n!==r.length-1||(r[0].focus(),e.preventDefault())}},i.focusableEls_=function(){var t=this.el_.querySelectorAll("*");return Array.prototype.filter.call(t,function(t){return(t instanceof e.HTMLAnchorElement||t instanceof e.HTMLAreaElement)&&t.hasAttribute("href")||(t instanceof e.HTMLInputElement||t instanceof e.HTMLSelectElement||t instanceof e.HTMLTextAreaElement||t instanceof e.HTMLButtonElement)&&!t.hasAttribute("disabled")||t instanceof e.HTMLIFrameElement||t instanceof e.HTMLObjectElement||t instanceof e.HTMLEmbedElement||t.hasAttribute("tabindex")&&-1!==t.getAttribute("tabindex")||t.hasAttribute("contenteditable")})},r}(rn);Fn.prototype.options_={pauseOnOpen:!0,temporary:!0},rn.registerComponent("ModalDialog",Fn);var Vn=function(e){function t(t){var n;void 0===t&&(t=[]),n=e.call(this)||this,n.tracks_=[],Object.defineProperty(ne(n),"length",{get:function(){return this.tracks_.length}});for(var r=0;r<t.length;r++)n.addTrack(t[r]);return n}Q(t,e);var n=t.prototype;return n.addTrack=function(e){var t=this.tracks_.length;""+t in this||Object.defineProperty(this,t,{get:function(){return this.tracks_[t]}}),-1===this.tracks_.indexOf(e)&&(this.tracks_.push(e),this.trigger({track:e,type:"addtrack",target:this}))},n.removeTrack=function(e){for(var t,n=0,r=this.length;n<r;n++)if(this[n]===e){t=this[n],t.off&&t.off(),this.tracks_.splice(n,1);break}t&&this.trigger({track:t,type:"removetrack",target:this})},n.getTrackById=function(e){for(var t=null,n=0,r=this.length;n<r;n++){var i=this[n];if(i.id===e){t=i;break}}return t},t}(qt);Vn.prototype.allowedEvents_={change:"change",addtrack:"addtrack",removetrack:"removetrack"};for(var qn in Vn.prototype.allowedEvents_)Vn.prototype["on"+qn]=null;var Gn,Hn=function(e,t){for(var n=0;n<e.length;n++)Object.keys(e[n]).length&&t.id!==e[n].id&&(e[n].enabled=!1)},zn=function(e){function t(t){var n;void 0===t&&(t=[]);for(var r=t.length-1;r>=0;r--)if(t[r].enabled){Hn(t,t[r]);break}return n=e.call(this,t)||this,n.changing_=!1,n}Q(t,e);var n=t.prototype;return n.addTrack=function(t){var n=this;t.enabled&&Hn(this,t),e.prototype.addTrack.call(this,t),t.addEventListener&&(t.enabledChange_=function(){n.changing_||(n.changing_=!0,Hn(n,t),n.changing_=!1,n.trigger("change"))},t.addEventListener("enabledchange",t.enabledChange_))},n.removeTrack=function(t){e.prototype.removeTrack.call(this,t),t.removeEventListener&&t.enabledChange_&&(t.removeEventListener("enabledchange",t.enabledChange_),t.enabledChange_=null)},t}(Vn),Wn=function(e,t){for(var n=0;n<e.length;n++)Object.keys(e[n]).length&&t.id!==e[n].id&&(e[n].selected=!1)},$n=function(e){function t(t){var n;void 0===t&&(t=[]);for(var r=t.length-1;r>=0;r--)if(t[r].selected){Wn(t,t[r]);break}return n=e.call(this,t)||this,n.changing_=!1,Object.defineProperty(ne(n),"selectedIndex",{get:function(){for(var e=0;e<this.length;e++)if(this[e].selected)return e;return-1},set:function(){}}),n}Q(t,e);var n=t.prototype;return n.addTrack=function(t){var n=this;t.selected&&Wn(this,t),e.prototype.addTrack.call(this,t),t.addEventListener&&(t.selectedChange_=function(){n.changing_||(n.changing_=!0,Wn(n,t),n.changing_=!1,n.trigger("change"))},t.addEventListener("selectedchange",t.selectedChange_))},n.removeTrack=function(t){e.prototype.removeTrack.call(this,t),t.removeEventListener&&t.selectedChange_&&(t.removeEventListener("selectedchange",t.selectedChange_),t.selectedChange_=null)},t}(Vn),Yn=function(e){function t(){return e.apply(this,arguments)||this}Q(t,e);var n=t.prototype;return n.addTrack=function(t){var n=this;e.prototype.addTrack.call(this,t),this.queueChange_||(this.queueChange_=function(){return n.queueTrigger("change")}),this.triggerSelectedlanguagechange||(this.triggerSelectedlanguagechange_=function(){return n.trigger("selectedlanguagechange")}),t.addEventListener("modechange",this.queueChange_),-1===["metadata","chapters"].indexOf(t.kind)&&t.addEventListener("modechange",this.triggerSelectedlanguagechange_)},n.removeTrack=function(t){e.prototype.removeTrack.call(this,t),t.removeEventListener&&(this.queueChange_&&t.removeEventListener("modechange",this.queueChange_),this.selectedlanguagechange_&&t.removeEventListener("modechange",this.triggerSelectedlanguagechange_))},t}(Vn),Kn=function(){function e(e){void 0===e&&(e=[]),this.trackElements_=[],Object.defineProperty(this,"length",{get:function(){return this.trackElements_.length}});for(var t=0,n=e.length;t<n;t++)this.addTrackElement_(e[t])}var t=e.prototype;return t.addTrackElement_=function(e){var t=this.trackElements_.length;""+t in this||Object.defineProperty(this,t,{get:function(){return this.trackElements_[t]}}),-1===this.trackElements_.indexOf(e)&&this.trackElements_.push(e)},t.getTrackElementByTrack_=function(e){for(var t,n=0,r=this.trackElements_.length;n<r;n++)if(e===this.trackElements_[n].track){t=this.trackElements_[n];break}return t},t.removeTrackElement_=function(e){for(var t=0,n=this.trackElements_.length;t<n;t++)if(e===this.trackElements_[t]){this.trackElements_[t].track&&"function"==typeof this.trackElements_[t].track.off&&this.trackElements_[t].track.off(),"function"==typeof this.trackElements_[t].off&&this.trackElements_[t].off(),this.trackElements_.splice(t,1);break}},e}(),Xn=function(){function e(t){e.prototype.setCues_.call(this,t),Object.defineProperty(this,"length",{get:function(){return this.length_}})}var t=e.prototype;return t.setCues_=function(e){var t=this.length||0,n=0,r=e.length;this.cues_=e,this.length_=e.length;var i=function(e){""+e in this||Object.defineProperty(this,""+e,{get:function(){return this.cues_[e]}})};if(t<r)for(n=t;n<r;n++)i.call(this,n)},t.getCueById=function(e){for(var t=null,n=0,r=this.length;n<r;n++){var i=this[n];if(i.id===e){t=i;break}}return t},e}(),Jn={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Qn={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Zn={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},er={disabled:"disabled",hidden:"hidden",showing:"showing"},tr=function(e){function t(t){var n;void 0===t&&(t={}),n=e.call(this)||this;var r={id:t.id||"vjs_track_"+N(),kind:t.kind||"",label:t.label||"",language:t.language||""};for(var i in r)!function(e){Object.defineProperty(ne(n),e,{get:function(){return r[e]},set:function(){}})}(i);return n}return Q(t,e),t}(qt),nr=function(n){var r=["protocol","hostname","port","pathname","search","hash","host"],i=t.createElement("a");i.href=n;var a,o=""===i.host&&"file:"!==i.protocol;o&&(a=t.createElement("div"),a.innerHTML='<a href="'+n+'"></a>',i=a.firstChild,a.setAttribute("style","display:none; position:absolute;"),t.body.appendChild(a));for(var s={},u=0;u<r.length;u++)s[r[u]]=i[r[u]];return"http:"===s.protocol&&(s.host=s.host.replace(/:80$/,"")),"https:"===s.protocol&&(s.host=s.host.replace(/:443$/,"")),s.protocol||(s.protocol=e.location.protocol),o&&t.body.removeChild(a),s},rr=function(e){if(!e.match(/^https?:\/\//)){var n=t.createElement("div");n.innerHTML='<a href="'+e+'">x</a>',e=n.firstChild.href}return e},ir=function(e){if("string"==typeof e){var t=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/,n=t.exec(e);if(n)return n.pop().toLowerCase()}return""},ar=function(t){var n=e.location,r=nr(t);return(":"===r.protocol?n.protocol:r.protocol)+r.host!==n.protocol+n.host},or=Object.freeze({parseUrl:nr,getAbsoluteURL:rr,getFileExtension:ir,isCrossOrigin:ar}),sr=he,ur=Object.prototype.toString,lr=Array.prototype.slice,cr=Object.prototype.toString,dr=function(e){var t=this;if("function"!=typeof t||"[object Function]"!==cr.call(t))throw new TypeError("Function.prototype.bind called on incompatible "+t);for(var n,r=lr.call(arguments,1),i=function(){if(this instanceof n){var i=t.apply(this,r.concat(lr.call(arguments)));return Object(i)===i?i:this}return t.apply(e,r.concat(lr.call(arguments)))},a=Math.max(0,t.length-r.length),o=[],s=0;s<a;s++)o.push("$"+s);if(n=Function("binder","return function ("+o.join(",")+"){ return binder.apply(this,arguments); }")(i),t.prototype){var u=function(){};u.prototype=t.prototype,n.prototype=new u,u.prototype=null}return n},fr=Function.prototype.bind||dr,hr=Object.prototype.toString,pr=function(e){var t=hr.call(e),n="[object Arguments]"===t;return n||(n="[object Array]"!==t&&null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Function]"===hr.call(e.callee)),n};if(!Object.keys){var mr=Object.prototype.hasOwnProperty,vr=Object.prototype.toString,gr=pr,yr=Object.prototype.propertyIsEnumerable,_r=!yr.call({toString:null},"toString"),br=yr.call(function(){},"prototype"),Tr=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],Sr=function(e){var t=e.constructor;return t&&t.prototype===e},wr={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},kr=function(){if("undefined"==typeof window)return!1;for(var e in window)try{if(!wr["$"+e]&&mr.call(window,e)&&null!==window[e]&&"object"==typeof window[e])try{Sr(window[e])}catch(e){return!0}}catch(e){return!0}return!1}(),Er=function(e){if("undefined"==typeof window||!kr)return Sr(e);try{return Sr(e)}catch(e){return!1}};Gn=function(e){var t=null!==e&&"object"==typeof e,n="[object Function]"===vr.call(e),r=gr(e),i=t&&"[object String]"===vr.call(e),a=[];if(!t&&!n&&!r)throw new TypeError("Object.keys called on a non-object");var o=br&&n;if(i&&e.length>0&&!mr.call(e,0))for(var s=0;s<e.length;++s)a.push(String(s));if(r&&e.length>0)for(var u=0;u<e.length;++u)a.push(String(u));else for(var l in e)o&&"prototype"===l||!mr.call(e,l)||a.push(String(l));if(_r)for(var c=Er(e),d=0;d<Tr.length;++d)c&&"constructor"===Tr[d]||!mr.call(e,Tr[d])||a.push(Tr[d]);return a}}var Ar=Gn,Cr=Array.prototype.slice,Lr=Object.keys,xr=Lr?function(e){return Lr(e)}:Ar,jr=Object.keys;xr.shim=function(){return Object.keys?function(){var e=Object.keys(arguments);return e&&e.length===arguments.length}(1,2)||(Object.keys=function(e){return jr(pr(e)?Cr.call(e):e)}):Object.keys=xr,Object.keys||xr};var Or=xr,Ir="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),Pr=Object.prototype.toString,Rr=Array.prototype.concat,Dr=Object.defineProperty,Mr=function(e){return"function"==typeof e&&"[object Function]"===Pr.call(e)},Ur=Dr&&function(){var e={};try{Dr(e,"x",{enumerable:!1,value:e});for(var t in e)return!1;return e.x===e}catch(e){return!1}}(),Br=function(e,t,n,r){(!(t in e)||Mr(r)&&r())&&(Ur?Dr(e,t,{configurable:!0,enumerable:!1,value:n,writable:!0}):e[t]=n)},Nr=function(e,t){var n=arguments.length>2?arguments[2]:{},r=Or(t);Ir&&(r=Rr.call(r,Object.getOwnPropertySymbols(t)));for(var i=0;i<r.length;i+=1)Br(e,r[i],t[r[i]],n[r[i]])};Nr.supportsDescriptors=!!Ur;var Fr=Nr,Vr=Object.getOwnPropertyDescriptor?function(){return Object.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new TypeError},qr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,Gr=Object.getPrototypeOf||function(e){return e.__proto__},Hr="undefined"==typeof Uint8Array?void 0:Gr(Uint8Array),zr={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":qr?Gr([][Symbol.iterator]()):void 0,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":void 0,"$ %AsyncFunction%":void 0,"$ %AsyncFunctionPrototype%":void 0,"$ %AsyncGenerator%":void 0,"$ %AsyncGeneratorFunction%":void 0,"$ %AsyncGeneratorPrototype%":void 0,"$ %AsyncIteratorPrototype%":void 0,"$ %Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?void 0:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?void 0:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":Error,"$ %ErrorPrototype%":Error.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?void 0:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?void 0:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":void 0,"$ %GeneratorFunction%":void 0,"$ %GeneratorPrototype%":void 0,"$ %Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?void 0:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?void 0:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?void 0:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":isNaN,"$ %IteratorPrototype%":qr?Gr(Gr([][Symbol.iterator]())):void 0,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?void 0:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&qr?Gr((new Map)[Symbol.iterator]()):void 0,"$ %MapPrototype%":"undefined"==typeof Map?void 0:Map.prototype,"$ %Math%":Math,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":Object,"$ %ObjectPrototype%":Object.prototype,"$ %ObjProto_toString%":Object.prototype.toString,"$ %ObjProto_valueOf%":Object.prototype.valueOf,"$ %parseFloat%":parseFloat,"$ %parseInt%":parseInt,"$ %Promise%":"undefined"==typeof Promise?void 0:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?void 0:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?void 0:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?void 0:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?void 0:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?void 0:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?void 0:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&qr?Gr((new Set)[Symbol.iterator]()):void 0,"$ %SetPrototype%":"undefined"==typeof Set?void 0:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":qr?Gr(""[Symbol.iterator]()):void 0,"$ %StringPrototype%":String.prototype,"$ %Symbol%":qr?Symbol:void 0,"$ %SymbolPrototype%":qr?Symbol.prototype:void 0,"$ %SyntaxError%":SyntaxError,"$ %SyntaxErrorPrototype%":SyntaxError.prototype,"$ %ThrowTypeError%":Vr,"$ %TypedArray%":Hr,"$ %TypedArrayPrototype%":Hr?Hr.prototype:void 0,"$ %TypeError%":TypeError,"$ %TypeErrorPrototype%":TypeError.prototype,"$ %Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"$ %Uint8ArrayPrototype%":"undefined"==typeof Uint8Array?void 0:Uint8Array.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?void 0:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?void 0:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?void 0:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?void 0:WeakSet.prototype},Wr=function(e,t){if(arguments.length>1&&"boolean"!=typeof t)throw new TypeError('"allowMissing" argument must be a boolean');var n="$ "+e;if(!(n in zr))throw new SyntaxError("intrinsic "+e+" does not exist!");if(void 0===zr[n]&&!t)throw new TypeError("intrinsic "+e+" exists, but is not available. Please file an issue!");return zr[n]},$r=fr.call(Function.call,Object.prototype.hasOwnProperty),Yr=Wr("%TypeError%"),Kr=Wr("%SyntaxError%"),Xr={"Property Descriptor":function(e,t){if("Object"!==e.Type(t))return!1;var n={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var r in t)if($r(t,r)&&!n[r])return!1;var i=$r(t,"[[Value]]"),a=$r(t,"[[Get]]")||$r(t,"[[Set]]");if(i&&a)throw new Yr("Property Descriptors may not be both accessor and data descriptors");return!0}},Jr=function(e,t,n,r){var i=Xr[t];if("function"!=typeof i)throw new Kr("unknown record type: "+t);if(!i(e,r))throw new Yr(n+" must be a "+t);console.log(i(e,r),r)},Qr=Number.isNaN||function(e){return e!==e},Zr=Number.isNaN||function(e){return e!==e},ei=Number.isFinite||function(e){return"number"==typeof e&&!Zr(e)&&e!==1/0&&e!==-1/0},ti=function(e){return e>=0?1:-1},ni=function(e,t){var n=e%t;return Math.floor(n>=0?n:n+t)},ri=Function.prototype.toString,ii=/^\s*class\b/,ai=function(e){try{var t=ri.call(e);return ii.test(t)}catch(e){return!1}},oi=function(e){try{return!ai(e)&&(ri.call(e),!0)}catch(e){return!1}},si=Object.prototype.toString,ui="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,li=function(e){if(!e)return!1;if("function"!=typeof e&&"object"!=typeof e)return!1;if("function"==typeof e&&!e.prototype)return!0;if(ui)return oi(e);if(ai(e))return!1;var t=si.call(e);return"[object Function]"===t||"[object GeneratorFunction]"===t},ci=function(e){return null===e||"function"!=typeof e&&"object"!=typeof e},di=Object.prototype.toString,fi={"[[DefaultValue]]":function(e){var t;if((t=arguments.length>1?arguments[1]:"[object Date]"===di.call(e)?String:Number)===String||t===Number){var n,r,i=t===String?["toString","valueOf"]:["valueOf","toString"];for(r=0;r<i.length;++r)if(li(e[i[r]])&&(n=e[i[r]](),ci(n)))return n;throw new TypeError("No default value")}throw new TypeError("invalid [[DefaultValue]] hint supplied")}},hi=function(e){return ci(e)?e:arguments.length>1?fi["[[DefaultValue]]"](e,arguments[1]):fi["[[DefaultValue]]"](e)},pi=Wr("%Object%"),mi=Wr("%TypeError%"),vi=Wr("%String%"),gi={ToPrimitive:hi,ToBoolean:function(e){return!!e},ToNumber:function(e){return+e},ToInteger:function(e){var t=this.ToNumber(e);return Qr(t)?0:0!==t&&ei(t)?ti(t)*Math.floor(Math.abs(t)):t},ToInt32:function(e){return this.ToNumber(e)>>0},ToUint32:function(e){return this.ToNumber(e)>>>0},ToUint16:function(e){var t=this.ToNumber(e);if(Qr(t)||0===t||!ei(t))return 0;var n=ti(t)*Math.floor(Math.abs(t));return ni(n,65536)},ToString:function(e){return vi(e)},ToObject:function(e){return this.CheckObjectCoercible(e),pi(e)},CheckObjectCoercible:function(e,t){if(null==e)throw new mi(t||"Cannot call method on "+e);return e},IsCallable:li,SameValue:function(e,t){return e===t?0!==e||1/e==1/t:Qr(e)&&Qr(t)},Type:function(e){return null===e?"Null":void 0===e?"Undefined":"function"==typeof e||"object"==typeof e?"Object":"number"==typeof e?"Number":"boolean"==typeof e?"Boolean":"string"==typeof e?"String":void 0},IsPropertyDescriptor:function(e){if("Object"!==this.Type(e))return!1;var t={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var n in e)if($r(e,n)&&!t[n])return!1;var r=$r(e,"[[Value]]"),i=$r(e,"[[Get]]")||$r(e,"[[Set]]");if(r&&i)throw new mi("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(e){return void 0!==e&&(Jr(this,"Property Descriptor","Desc",e),!(!$r(e,"[[Get]]")&&!$r(e,"[[Set]]")))},IsDataDescriptor:function(e){return void 0!==e&&(Jr(this,"Property Descriptor","Desc",e),!(!$r(e,"[[Value]]")&&!$r(e,"[[Writable]]")))},IsGenericDescriptor:function(e){return void 0!==e&&(Jr(this,"Property Descriptor","Desc",e),!this.IsAccessorDescriptor(e)&&!this.IsDataDescriptor(e))},FromPropertyDescriptor:function(e){if(void 0===e)return e;if(Jr(this,"Property Descriptor","Desc",e),this.IsDataDescriptor(e))return{value:e["[[Value]]"],writable:!!e["[[Writable]]"],enumerable:!!e["[[Enumerable]]"],configurable:!!e["[[Configurable]]"]};if(this.IsAccessorDescriptor(e))return{get:e["[[Get]]"],set:e["[[Set]]"],enumerable:!!e["[[Enumerable]]"],configurable:!!e["[[Configurable]]"]};throw new mi("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(e){if("Object"!==this.Type(e))throw new mi("ToPropertyDescriptor requires an object");var t={};if($r(e,"enumerable")&&(t["[[Enumerable]]"]=this.ToBoolean(e.enumerable)),$r(e,"configurable")&&(t["[[Configurable]]"]=this.ToBoolean(e.configurable)),$r(e,"value")&&(t["[[Value]]"]=e.value),$r(e,"writable")&&(t["[[Writable]]"]=this.ToBoolean(e.writable)),$r(e,"get")){var n=e.get;if(void 0!==n&&!this.IsCallable(n))throw new TypeError("getter must be a function");t["[[Get]]"]=n}if($r(e,"set")){var r=e.set;if(void 0!==r&&!this.IsCallable(r))throw new mi("setter must be a function");t["[[Set]]"]=r}if(($r(t,"[[Get]]")||$r(t,"[[Set]]"))&&($r(t,"[[Value]]")||$r(t,"[[Writable]]")))throw new mi("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return t}},yi=gi,_i=fr.call(Function.call,String.prototype.replace),bi=/^[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+/,Ti=/[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+$/,Si=function(){var e=yi.ToString(yi.CheckObjectCoercible(this));return _i(_i(e,bi,""),Ti,"")},wi="​",ki=function(){return String.prototype.trim&&wi.trim()===wi?String.prototype.trim:Si},Ei=function(){var e=ki();return Fr(String.prototype,{trim:e},{trim:function(){return String.prototype.trim!==e}}),e},Ai=fr.call(Function.call,ki());Fr(Ai,{getPolyfill:ki,implementation:Si,shim:Ei});var Ci=Ai,Li=Object.prototype.toString,xi=Object.prototype.hasOwnProperty,ji=function(e,t,n){for(var r=0,i=e.length;r<i;r++)xi.call(e,r)&&(null==n?t(e[r],r,e):t.call(n,e[r],r,e))},Oi=function(e,t,n){for(var r=0,i=e.length;r<i;r++)null==n?t(e.charAt(r),r,e):t.call(n,e.charAt(r),r,e)},Ii=function(e,t,n){for(var r in e)xi.call(e,r)&&(null==n?t(e[r],r,e):t.call(n,e[r],r,e))},Pi=function(e,t,n){if(!li(t))throw new TypeError("iterator must be a function");var r;arguments.length>=3&&(r=n),"[object Array]"===Li.call(e)?ji(e,t,r):"string"==typeof e?Oi(e,t,r):Ii(e,t,r)},Ri=Pi,Di=function(e){return"[object Array]"===Object.prototype.toString.call(e)},Mi=function(e){if(!e)return{};var t={};return Ri(Ci(e).split("\n"),function(e){var n=e.indexOf(":"),r=Ci(e.slice(0,n)).toLowerCase(),i=Ci(e.slice(n+1));void 0===t[r]?t[r]=i:Di(t[r])?t[r].push(i):t[r]=[t[r],i]}),t},Ui=pe,Bi=Object.prototype.hasOwnProperty,Ni=ge;ge.XMLHttpRequest=e.XMLHttpRequest||be,ge.XDomainRequest="withCredentials"in new ge.XMLHttpRequest?ge.XMLHttpRequest:e.XDomainRequest,function(e,t){for(var n=0;n<e.length;n++)!function(e){ge["delete"===e?"del":e]=function(t,n,r){return n=ve(t,n,r),n.method=e.toUpperCase(),ye(n)}}(e[n])}(["get","put","post","patch","head","delete"]);var Fi=function(t,n){var r=new e.WebVTT.Parser(e,e.vttjs,e.WebVTT.StringDecoder()),i=[];r.oncue=function(e){n.addCue(e)},r.onparsingerror=function(e){i.push(e)},r.onflush=function(){n.trigger({type:"loadeddata",target:n})},r.parse(t),i.length>0&&(e.console&&e.console.groupCollapsed&&e.console.groupCollapsed("Text Track parsing errors for "+n.src),i.forEach(function(e){return Tt.error(e)}),e.console&&e.console.groupEnd&&e.console.groupEnd()),r.flush()},Vi=function(t,n){var r={uri:t},i=ar(t);i&&(r.cors=i),Ni(r,Nt(this,function(t,r,i){if(t)return Tt.error(t,r);n.loaded_=!0,"function"!=typeof e.WebVTT?n.tech_&&n.tech_.any(["vttjsloaded","vttjserror"],function(e){return"vttjserror"===e.type?void Tt.error("vttjs failed to load, stopping trying to process "+n.src):Fi(i,n)}):Fi(i,n)}))},qi=function(t){function n(e){var n;if(void 0===e&&(e={}),!e.tech)throw new Error("A tech was not provided.");var r=J(e,{kind:Zn[e.kind]||"subtitles",language:e.language||e.srclang||""}),i=er[r.mode]||"disabled",a=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(i="hidden"),n=t.call(this,r)||this,n.tech_=r.tech,n.cues_=[],n.activeCues_=[];var o=new Xn(n.cues_),s=new Xn(n.activeCues_),u=!1,l=Nt(ne(n),function(){this.activeCues=this.activeCues,u&&(this.trigger("cuechange"),u=!1)});return"disabled"!==i&&n.tech_.ready(function(){n.tech_.on("timeupdate",l)},!0),Object.defineProperties(ne(n),{default:{get:function(){return a},set:function(){}},mode:{get:function(){return i},set:function(e){var t=this;er[e]&&(i=e,"disabled"!==i?this.tech_.ready(function(){t.tech_.on("timeupdate",l)},!0):this.tech_.off("timeupdate",l),this.trigger("modechange"))}},cues:{get:function(){return this.loaded_?o:null},set:function(){}},activeCues:{get:function(){if(!this.loaded_)return null;if(0===this.cues.length)return s;for(var e=this.tech_.currentTime(),t=[],n=0,r=this.cues.length;n<r;n++){var i=this.cues[n];i.startTime<=e&&i.endTime>=e?t.push(i):i.startTime===i.endTime&&i.startTime<=e&&i.startTime+.5>=e&&t.push(i)}if(u=!1,t.length!==this.activeCues_.length)u=!0;else for(var a=0;a<t.length;a++)-1===this.activeCues_.indexOf(t[a])&&(u=!0);return this.activeCues_=t,s.setCues_(this.activeCues_),s},set:function(){}}}),r.src?(n.src=r.src,Vi(r.src,ne(n))):n.loaded_=!0,n}Q(n,t);var r=n.prototype;return r.addCue=function(t){var n=t;if(e.vttjs&&!(t instanceof e.vttjs.VTTCue)){n=new e.vttjs.VTTCue(t.startTime,t.endTime,t.text);for(var r in t)r in n||(n[r]=t[r]);n.id=t.id,n.originalCue_=t}for(var i=this.tech_.textTracks(),a=0;a<i.length;a++)i[a]!==this&&i[a].removeCue(n);this.cues_.push(n),this.cues.setCues_(this.cues_)},r.removeCue=function(e){for(var t=this.cues_.length;t--;){var n=this.cues_[t];if(n===e||n.originalCue_&&n.originalCue_===e){this.cues_.splice(t,1),this.cues.setCues_(this.cues_);break}}},n}(tr);qi.prototype.allowedEvents_={cuechange:"cuechange"};var Gi=function(e){function t(t){var n;void 0===t&&(t={});var r=J(t,{kind:Qn[t.kind]||""});n=e.call(this,r)||this;var i=!1;return Object.defineProperty(ne(n),"enabled",{get:function(){return i},set:function(e){"boolean"==typeof e&&e!==i&&(i=e,this.trigger("enabledchange"))}}),r.enabled&&(n.enabled=r.enabled),n.loaded_=!0,n}return Q(t,e),t}(tr),Hi=function(e){function t(t){var n;void 0===t&&(t={});var r=J(t,{kind:Jn[t.kind]||""});n=e.call(this,r)||this;var i=!1;return Object.defineProperty(ne(n),"selected",{get:function(){return i},set:function(e){"boolean"==typeof e&&e!==i&&(i=e,this.trigger("selectedchange"))}}),r.selected&&(n.selected=r.selected),n}return Q(t,e),t}(tr),zi=0,Wi=2,$i=function(e){function t(t){var n;void 0===t&&(t={}),n=e.call(this)||this;var r,i=new qi(t);return n.kind=i.kind,n.src=i.src,n.srclang=i.language,n.label=i.label,n.default=i.default,Object.defineProperties(ne(n),{readyState:{get:function(){return r}},track:{get:function(){return i}}}),r=zi,i.addEventListener("loadeddata",function(){r=Wi,n.trigger({type:"load",target:ne(n)})}),n}return Q(t,e),t}(qt);$i.prototype.allowedEvents_={load:"load"},$i.NONE=zi,$i.LOADING=1,$i.LOADED=Wi,$i.ERROR=3;var Yi={audio:{ListClass:zn,TrackClass:Gi,capitalName:"Audio"},video:{ListClass:$n,TrackClass:Hi,capitalName:"Video"},text:{ListClass:Yn,TrackClass:qi,capitalName:"Text"}};Object.keys(Yi).forEach(function(e){Yi[e].getterName=e+"Tracks",Yi[e].privateName=e+"Tracks_"});var Ki={remoteText:{ListClass:Yn,TrackClass:qi,capitalName:"RemoteText",getterName:"remoteTextTracks",privateName:"remoteTextTracks_"},remoteTextEl:{ListClass:Kn,TrackClass:$i,capitalName:"RemoteTextTrackEls",getterName:"remoteTextTrackEls",privateName:"remoteTextTrackEls_"}},Xi=J(Yi,Ki);Ki.names=Object.keys(Ki),Yi.names=Object.keys(Yi),Xi.names=[].concat(Ki.names).concat(Yi.names);var Ji=Object.create||function(){function e(){}return function(t){if(1!==arguments.length)throw new Error("Object.create shim only accepts one parameter.");return e.prototype=t,new e}}();Te.prototype=Ji(Error.prototype),Te.prototype.constructor=Te,Te.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}},we.prototype={set:function(e,t){this.get(e)||""===t||(this.values[e]=t)},get:function(e,t,n){return n?this.has(e)?this.values[e]:t[n]:this.has(e)?this.values[e]:t},has:function(e){return e in this.values},alt:function(e,t,n){for(var r=0;r<n.length;++r)if(t===n[r]){this.set(e,t);break}},integer:function(e,t){/^-?\d+$/.test(t)&&this.set(e,parseInt(t,10))},percent:function(e,t){return!!(t.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(t=parseFloat(t))>=0&&t<=100)&&(this.set(e,t),!0)}};var Qi={"&amp;":"&","&lt;":"<","&gt;":">","&lrm;":"‎","&rlm;":"‏","&nbsp;":" "},Zi={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},ea={v:"title",lang:"lang"},ta={rt:"ruby"},na=[[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]];je.prototype.applyStyles=function(e,t){t=t||this.div;for(var n in e)e.hasOwnProperty(n)&&(t.style[n]=e[n])},je.prototype.formatStyle=function(e,t){return 0===e?0:e+t},Oe.prototype=Ji(je.prototype),Oe.prototype.constructor=Oe,Ie.prototype.move=function(e,t){switch(t=void 0!==t?t:this.lineHeight,e){case"+x":this.left+=t,this.right+=t;break;case"-x":this.left-=t,this.right-=t;break;case"+y":this.top+=t,this.bottom+=t;break;case"-y":this.top-=t,this.bottom-=t}},Ie.prototype.overlaps=function(e){return this.left<e.right&&this.right>e.left&&this.top<e.bottom&&this.bottom>e.top},Ie.prototype.overlapsAny=function(e){for(var t=0;t<e.length;t++)if(this.overlaps(e[t]))return!0;return!1},Ie.prototype.within=function(e){return this.top>=e.top&&this.bottom<=e.bottom&&this.left>=e.left&&this.right<=e.right},Ie.prototype.overlapsOppositeAxis=function(e,t){switch(t){case"+x":return this.left<e.left;case"-x":return this.right>e.right;case"+y":return this.top<e.top;case"-y":return this.bottom>e.bottom}},Ie.prototype.intersectPercentage=function(e){return Math.max(0,Math.min(this.right,e.right)-Math.max(this.left,e.left))*Math.max(0,Math.min(this.bottom,e.bottom)-Math.max(this.top,e.top))/(this.height*this.width)},Ie.prototype.toCSSCompatValues=function(e){return{top:this.top-e.top,bottom:e.bottom-this.bottom,left:this.left-e.left,right:e.right-this.right,height:this.height,width:this.width}},Ie.getSimpleBoxPosition=function(e){var t=e.div?e.div.offsetHeight:e.tagName?e.offsetHeight:0,n=e.div?e.div.offsetWidth:e.tagName?e.offsetWidth:0,r=e.div?e.div.offsetTop:e.tagName?e.offsetTop:0;return e=e.div?e.div.getBoundingClientRect():e.tagName?e.getBoundingClientRect():e,{left:e.left,right:e.right,top:e.top||r,height:e.height||t,bottom:e.bottom||r+(e.height||t),width:e.width||n}},Re.StringDecoder=function(){return{decode:function(e){if(!e)return"";if("string"!=typeof e)throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(e))}}},Re.convertCueToDOMTree=function(e,t){return e&&t?Ae(e,t):null},Re.processCues=function(e,t,n){if(!e||!t||!n)return null;for(;n.firstChild;)n.removeChild(n.firstChild);var r=e.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(e){for(var t=0;t<e.length;t++)if(e[t].hasBeenReset||!e[t].displayState)return!0;return!1}(t)){var i=[],a=Ie.getSimpleBoxPosition(r),o=Math.round(.05*a.height*100)/100,s={font:o+"px sans-serif"};!function(){for(var n,o,u=0;u<t.length;u++)o=t[u],n=new Oe(e,o,s),r.appendChild(n.div),Pe(e,n,a,i),o.displayState=n.div,i.push(Ie.getSimpleBoxPosition(n))}()}else for(var u=0;u<t.length;u++)r.appendChild(t[u].displayState)},Re.Parser=function(e,t,n){n||(n=t,t={}),t||(t={}),this.window=e,this.vttjs=t,this.state="INITIAL",this.buffer="",this.decoder=n||new TextDecoder("utf8"),this.regionList=[]},Re.Parser.prototype={reportOrThrowError:function(e){if(!(e instanceof Te))throw e;this.onparsingerror&&this.onparsingerror(e)},parse:function(e){function t(){for(var e=i.buffer,t=0;t<e.length&&"\r"!==e[t]&&"\n"!==e[t];)++t;var n=e.substr(0,t);return"\r"===e[t]&&++t,"\n"===e[t]&&++t,i.buffer=e.substr(t),n}function n(e){var t=new we;if(ke(e,function(e,n){switch(e){case"id":t.set(e,n);break;case"width":t.percent(e,n);break;case"lines":t.integer(e,n);break;case"regionanchor":case"viewportanchor":var r=n.split(",");if(2!==r.length)break;var i=new we;if(i.percent("x",r[0]),i.percent("y",r[1]),!i.has("x")||!i.has("y"))break;t.set(e+"X",i.get("x")),t.set(e+"Y",i.get("y"));break;case"scroll":t.alt(e,n,["up"])}},/=/,/\s/),t.has("id")){var n=new(i.vttjs.VTTRegion||i.window.VTTRegion);n.width=t.get("width",100),n.lines=t.get("lines",3),n.regionAnchorX=t.get("regionanchorX",0),n.regionAnchorY=t.get("regionanchorY",100),n.viewportAnchorX=t.get("viewportanchorX",0),n.viewportAnchorY=t.get("viewportanchorY",100),n.scroll=t.get("scroll",""),i.onregion&&i.onregion(n),i.regionList.push({id:t.get("id"),region:n})}}function r(e){var t=new we;ke(e,function(e,n){switch(e){case"MPEGT":t.integer(e+"S",n);break;case"LOCA":t.set(e+"L",Se(n))}},/[^\d]:/,/,/),i.ontimestampmap&&i.ontimestampmap({MPEGTS:t.get("MPEGTS"),LOCAL:t.get("LOCAL")})}var i=this;e&&(i.buffer+=i.decoder.decode(e,{stream:!0}));try{var a;if("INITIAL"===i.state){if(!/\r\n|\n/.test(i.buffer))return this;a=t();var o=a.match(/^WEBVTT([ \t].*)?$/);if(!o||!o[0])throw new Te(Te.Errors.BadSignature);i.state="HEADER"}for(var s=!1;i.buffer;){if(!/\r\n|\n/.test(i.buffer))return this;switch(s?s=!1:a=t(),i.state){case"HEADER":/:/.test(a)?function(e){e.match(/X-TIMESTAMP-MAP/)?ke(e,function(e,t){switch(e){case"X-TIMESTAMP-MAP":r(t)}},/=/):ke(e,function(e,t){switch(e){case"Region":n(t)}},/:/)}(a):a||(i.state="ID");continue;case"NOTE":a||(i.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(a)){i.state="NOTE";break}if(!a)continue;if(i.cue=new(i.vttjs.VTTCue||i.window.VTTCue)(0,0,""),i.state="CUE",-1===a.indexOf("--\x3e")){i.cue.id=a;continue}case"CUE":try{Ee(a,i.cue,i.regionList)}catch(e){i.reportOrThrowError(e),i.cue=null,i.state="BADCUE";continue}i.state="CUETEXT";continue;case"CUETEXT":var u=-1!==a.indexOf("--\x3e");if(!a||u&&(s=!0)){i.oncue&&i.oncue(i.cue),i.cue=null,i.state="ID";continue}i.cue.text&&(i.cue.text+="\n"),i.cue.text+=a;continue;case"BADCUE":a||(i.state="ID");continue}}}catch(e){i.reportOrThrowError(e),"CUETEXT"===i.state&&i.cue&&i.oncue&&i.oncue(i.cue),i.cue=null,i.state="INITIAL"===i.state?"BADWEBVTT":"BADCUE"}return this},flush:function(){var e=this;try{if(e.buffer+=e.decoder.decode(),(e.cue||"HEADER"===e.state)&&(e.buffer+="\n\n",e.parse()),"INITIAL"===e.state)throw new Te(Te.Errors.BadSignature)}catch(t){e.reportOrThrowError(t)}return e.onflush&&e.onflush(),this}};var ra=Re,ia="auto",aa={"":1,lr:1,rl:1},oa={start:1,middle:1,end:1,left:1,right:1};Ue.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)};var sa=Ue,ua={"":!0,up:!0},la=Fe,ca=fe(function(t){var n=t.exports={WebVTT:ra,VTTCue:sa,VTTRegion:la};e.vttjs=n,e.WebVTT=n.WebVTT;var r=n.VTTCue,i=n.VTTRegion,a=e.VTTCue,o=e.VTTRegion;n.shim=function(){e.VTTCue=r,e.VTTRegion=i},n.restore=function(){e.VTTCue=a,e.VTTRegion=o},e.VTTCue||n.shim()}),da=(ca.WebVTT,ca.VTTCue,ca.VTTRegion,function(n){function r(e,t){var r;return void 0===e&&(e={}),void 0===t&&(t=function(){}),e.reportTouchActivity=!1,r=n.call(this,null,e,t)||this,r.hasStarted_=!1,r.on("playing",function(){this.hasStarted_=!0}),r.on("loadstart",function(){this.hasStarted_=!1}),Xi.names.forEach(function(t){var n=Xi[t];e&&e[n.getterName]&&(r[n.privateName]=e[n.getterName])}),r.featuresProgressEvents||r.manualProgressOn(),r.featuresTimeupdateEvents||r.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach(function(t){!1===e["native"+t+"Tracks"]&&(r["featuresNative"+t+"Tracks"]=!1)}),!1===e.nativeCaptions||!1===e.nativeTextTracks?r.featuresNativeTextTracks=!1:!0!==e.nativeCaptions&&!0!==e.nativeTextTracks||(r.featuresNativeTextTracks=!0),r.featuresNativeTextTracks||r.emulateTextTracks(),r.autoRemoteTextTracks_=new Xi.text.ListClass,r.initTrackListeners(),e.nativeControlsForTouch||r.emitTapEvents(),r.constructor&&(r.name_=r.constructor.name||"Unknown Tech"),r}Q(r,n);var i=r.prototype;return i.triggerSourceset=function(e){var t=this;this.isReady_||this.one("ready",function(){return t.setTimeout(function(){return t.triggerSourceset(e)},1)}),this.trigger({src:e,type:"sourceset"})},i.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},i.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},i.trackProgress=function(e){this.stopTrackingProgress(),this.progressInterval=this.setInterval(Nt(this,function(){var e=this.bufferedPercent();this.bufferedPercent_!==e&&this.trigger("progress"),this.bufferedPercent_=e,1===e&&this.stopTrackingProgress()}),500)},i.onDurationChange=function(e){this.duration_=this.duration()},i.buffered=function(){return oe(0,0)},i.bufferedPercent=function(){return se(this.buffered(),this.duration_)},i.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},i.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},i.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},i.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval(function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},250)},i.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},i.dispose=function(){this.clearTracks(Yi.names),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),n.prototype.dispose.call(this)},i.clearTracks=function(e){var t=this;e=[].concat(e),e.forEach(function(e){for(var n=t[e+"Tracks"]()||[],r=n.length;r--;){var i=n[r];"text"===e&&t.removeRemoteTextTrack(i),n.removeTrack(i)}})},i.cleanupAutoTextTracks=function(){for(var e=this.autoRemoteTextTracks_||[],t=e.length;t--;){var n=e[t];this.removeRemoteTextTrack(n)}},i.reset=function(){},i.error=function(e){return void 0!==e&&(this.error_=new ue(e),this.trigger("error")),this.error_},i.played=function(){return this.hasStarted_?oe(0,0):oe()},i.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},i.initTrackListeners=function(){var e=this;Yi.names.forEach(function(t){var n=Yi[t],r=function(){e.trigger(t+"trackchange")},i=e[n.getterName]();i.addEventListener("removetrack",r),i.addEventListener("addtrack",r),e.on("dispose",function(){i.removeEventListener("removetrack",r),i.removeEventListener("addtrack",r)})})},i.addWebVttScript_=function(){var n=this;if(!e.WebVTT)if(t.body.contains(this.el())){if(!this.options_["vtt.js"]&&s(ca)&&Object.keys(ca).length>0)return void this.trigger("vttjsloaded");var r=t.createElement("script");r.src=this.options_["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.14.1/vtt.min.js",r.onload=function(){n.trigger("vttjsloaded")},r.onerror=function(){n.trigger("vttjserror")},this.on("dispose",function(){r.onload=null,r.onerror=null}),e.WebVTT=!0,this.el().parentNode.appendChild(r)}else this.ready(this.addWebVttScript_)},i.emulateTextTracks=function(){var e=this,t=this.textTracks(),n=this.remoteTextTracks(),r=function(e){return t.addTrack(e.track)},i=function(e){return t.removeTrack(e.track)};n.on("addtrack",r),n.on("removetrack",i),this.addWebVttScript_();var a=function(){return e.trigger("texttrackchange")},o=function(){a();for(var e=0;e<t.length;e++){var n=t[e];n.removeEventListener("cuechange",a),"showing"===n.mode&&n.addEventListener("cuechange",a)}};o(),t.addEventListener("change",o),t.addEventListener("addtrack",o),t.addEventListener("removetrack",o),this.on("dispose",function(){n.off("addtrack",r),n.off("removetrack",i),t.removeEventListener("change",o),t.removeEventListener("addtrack",o),t.removeEventListener("removetrack",o);for(var e=0;e<t.length;e++)t[e].removeEventListener("cuechange",a)})},i.addTextTrack=function(e,t,n){if(!e)throw new Error("TextTrack kind is required but was not provided");return Ve(this,e,t,n)},i.createRemoteTextTrack=function(e){var t=J(e,{tech:this});return new Ki.remoteTextEl.TrackClass(t)},i.addRemoteTextTrack=function(e,t){var n=this;void 0===e&&(e={});var r=this.createRemoteTextTrack(e);return!0!==t&&!1!==t&&(Tt.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),t=!0),this.remoteTextTrackEls().addTrackElement_(r),this.remoteTextTracks().addTrack(r.track),!0!==t&&this.ready(function(){return n.autoRemoteTextTracks_.addTrack(r.track)}),r},i.removeRemoteTextTrack=function(e){var t=this.remoteTextTrackEls().getTrackElementByTrack_(e);this.remoteTextTrackEls().removeTrackElement_(t),this.remoteTextTracks().removeTrack(e),this.autoRemoteTextTracks_.removeTrack(e)},i.getVideoPlaybackQuality=function(){return{}},i.requestPictureInPicture=function(){var t=this.options_.Promise||e.Promise;if(t)return t.reject()},i.setPoster=function(){},i.playsinline=function(){},i.setPlaysinline=function(){},i.overrideNativeAudioTracks=function(){},i.overrideNativeVideoTracks=function(){},i.canPlayType=function(){return""},r.canPlayType=function(){return""},r.canPlaySource=function(e,t){return r.canPlayType(e.type)},r.isTech=function(e){return e.prototype instanceof r||e instanceof r||e===r},r.registerTech=function(e,t){if(r.techs_||(r.techs_={}),!r.isTech(t))throw new Error("Tech "+e+" must be a Tech");if(!r.canPlayType)throw new Error("Techs must have a static canPlayType method on them");if(!r.canPlaySource)throw new Error("Techs must have a static canPlaySource method on them");return e=tn(e),r.techs_[e]=t,r.techs_[en(e)]=t,"Tech"!==e&&r.defaultTechOrder_.push(e),t},r.getTech=function(t){if(t)return r.techs_&&r.techs_[t]?r.techs_[t]:(t=tn(t),e&&e.videojs&&e.videojs[t]?(Tt.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),e.videojs[t]):void 0)},r}(rn));Xi.names.forEach(function(e){var t=Xi[e];da.prototype[t.getterName]=function(){return this[t.privateName]=this[t.privateName]||new t.ListClass,this[t.privateName]}}),da.prototype.featuresVolumeControl=!0,da.prototype.featuresMuteControl=!0,da.prototype.featuresFullscreenResize=!1,da.prototype.featuresPlaybackRate=!1,da.prototype.featuresProgressEvents=!1,da.prototype.featuresSourceset=!1,da.prototype.featuresTimeupdateEvents=!1,da.prototype.featuresNativeTextTracks=!1,da.withSourceHandlers=function(e){e.registerSourceHandler=function(t,n){var r=e.sourceHandlers;r||(r=e.sourceHandlers=[]),void 0===n&&(n=r.length),r.splice(n,0,t)},e.canPlayType=function(t){for(var n,r=e.sourceHandlers||[],i=0;i<r.length;i++)if(n=r[i].canPlayType(t))return n;return""},e.selectSourceHandler=function(t,n){for(var r=e.sourceHandlers||[],i=0;i<r.length;i++)if(r[i].canHandleSource(t,n))return r[i];return null},e.canPlaySource=function(t,n){var r=e.selectSourceHandler(t,n);return r?r.canHandleSource(t,n):""},["seekable","seeking","duration"].forEach(function(e){var t=this[e];"function"==typeof t&&(this[e]=function(){return this.sourceHandler_&&this.sourceHandler_[e]?this.sourceHandler_[e].apply(this.sourceHandler_,arguments):t.apply(this,arguments)})},e.prototype),e.prototype.setSource=function(t){var n=e.selectSourceHandler(t,this.options_);n||(e.nativeSourceHandler?n=e.nativeSourceHandler:Tt.error("No source handler found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),n!==e.nativeSourceHandler&&(this.currentSource_=t),this.sourceHandler_=n.handleSource(t,this,this.options_),this.one("dispose",this.disposeSourceHandler)},e.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)}},rn.registerComponent("Tech",da),da.registerTech("Tech",da),da.defaultTechOrder_=[];var fa={},ha={},pa={},ma={buffered:1,currentTime:1,duration:1,seekable:1,played:1,paused:1,volume:1},va={setCurrentTime:1,setVolume:1},ga={play:1,pause:1},ya={opus:"video/ogg",ogv:"video/ogg",mp4:"video/mp4",mov:"video/mp4",m4v:"video/mp4",mkv:"video/x-matroska",m4a:"audio/mp4",mp3:"audio/mpeg",aac:"audio/aac",oga:"audio/ogg",m3u8:"application/x-mpegURL",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",png:"image/png",svg:"image/svg+xml",webp:"image/webp"},_a=function(e){void 0===e&&(e="");var t=ir(e);return ya[t.toLowerCase()]||""},ba=function(e,t){if(!t)return"";if(e.cache_.source.src===t&&e.cache_.source.type)return e.cache_.source.type;var n=e.cache_.sources.filter(function(e){return e.src===t});if(n.length)return n[0].type;for(var r=e.$$("source"),i=0;i<r.length;i++){var a=r[i];if(a.type&&a.src&&a.src===t)return a.type}return _a(t)},Ta=function e(t){if(Array.isArray(t)){var n=[];t.forEach(function(t){t=e(t),Array.isArray(t)?n=n.concat(t):o(t)&&n.push(t)}),t=n}else t="string"==typeof t&&t.trim()?[Ze({src:t})]:o(t)&&"string"==typeof t.src&&t.src&&t.src.trim()?[Ze(t)]:[];return t},Sa=function(e){function t(t,n,r){var i,a=J({createEl:!1},n);if(i=e.call(this,t,a,r)||this,n.playerOptions.sources&&0!==n.playerOptions.sources.length)t.src(n.playerOptions.sources);else for(var o=0,s=n.playerOptions.techOrder;o<s.length;o++){var u=tn(s[o]),l=da.getTech(u);if(u||(l=rn.getComponent(u)),l&&l.isSupported()){t.loadTech_(u);break}}return i}return Q(t,e),t}(rn);rn.registerComponent("MediaLoader",Sa);var wa=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.emitTapEvents(),r.enable(),r}Q(t,e);var n=t.prototype;return n.createEl=function(t,n,r){void 0===t&&(t="div"),void 0===n&&(n={}),void 0===r&&(r={}),n=a({innerHTML:'<span aria-hidden="true" class="vjs-icon-placeholder"></span>',className:this.buildCSSClass(),tabIndex:0},n),"button"===t&&Tt.error("Creating a ClickableComponent with an HTML element of "+t+" is not supported; use a Button instead."),r=a({role:"button"},r),this.tabIndex_=n.tabIndex;var i=e.prototype.createEl.call(this,t,n,r);return this.createControlTextEl(i),i},n.dispose=function(){this.controlTextEl_=null,e.prototype.dispose.call(this)},n.createControlTextEl=function(e){return this.controlTextEl_=v("span",{className:"vjs-control-text"},{"aria-live":"polite"}),e&&e.appendChild(this.controlTextEl_),this.controlText(this.controlText_,e),this.controlTextEl_},n.controlText=function(e,t){if(void 0===t&&(t=this.el()),void 0===e)return this.controlText_||"Need Text";var n=this.localize(e);this.controlText_=e,g(this.controlTextEl_,n),this.nonIconControl||t.setAttribute("title",n)},n.buildCSSClass=function(){return"vjs-control vjs-button "+e.prototype.buildCSSClass.call(this)},n.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("keydown",this.handleKeyDown))},n.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("mouseover",this.handleMouseOver),this.off("mouseout",this.handleMouseOut),this.off(["tap","click"],this.handleClick),this.off("keydown",this.handleKeyDown)},n.handleClick=function(e){},n.handleKeyDown=function(t){Bn.isEventKey(t,"Space")||Bn.isEventKey(t,"Enter")?(t.preventDefault(),t.stopPropagation(),this.trigger("click")):e.prototype.handleKeyDown.call(this,t)},t}(rn);rn.registerComponent("ClickableComponent",wa);var ka=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.update(),t.on("posterchange",Nt(ne(r),r.update)),r}Q(t,e);var n=t.prototype;return n.dispose=function(){this.player().off("posterchange",this.update),e.prototype.dispose.call(this)},n.createEl=function(){return v("div",{className:"vjs-poster",tabIndex:-1})},n.update=function(e){var t=this.player().poster();this.setSrc(t),t?this.show():this.hide()},n.setSrc=function(e){var t="";e&&(t='url("'+e+'")'),this.el_.style.backgroundImage=t},n.handleClick=function(e){this.player_.controls()&&(this.player_.tech(!0)&&this.player_.tech(!0).focus(),this.player_.paused()?de(this.player_.play()):this.player_.pause())},t}(wa);rn.registerComponent("PosterImage",ka);var Ea={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'},Aa=function(t){function n(n,r,i){var a;a=t.call(this,n,r,i)||this;var o=Nt(ne(a),a.updateDisplay);return n.on("loadstart",Nt(ne(a),a.toggleDisplay)),n.on("texttrackchange",o),n.on("loadedmetadata",Nt(ne(a),a.preselectTrack)),n.ready(Nt(ne(a),function(){if(n.tech_&&n.tech_.featuresNativeTextTracks)return void this.hide();n.on("fullscreenchange",o),n.on("playerresize",o),e.addEventListener("orientationchange",o),n.on("dispose",function(){return e.removeEventListener("orientationchange",o)});for(var t=this.options_.playerOptions.tracks||[],r=0;r<t.length;r++)this.player_.addRemoteTextTrack(t[r],!0);this.preselectTrack()})),a}Q(n,t);var r=n.prototype;return r.preselectTrack=function(){for(var e,t,n,r={captions:1,subtitles:1},i=this.player_.textTracks(),a=this.player_.cache_.selectedLanguage,o=0;o<i.length;o++){var s=i[o];a&&a.enabled&&a.language&&a.language===s.language&&s.kind in r?s.kind===a.kind?n=s:n||(n=s):a&&!a.enabled?(n=null,e=null,t=null):s.default&&("descriptions"!==s.kind||e?s.kind in r&&!t&&(t=s):e=s)}n?n.mode="showing":t?t.mode="showing":e&&(e.mode="showing")},r.toggleDisplay=function(){this.player_.tech_&&this.player_.tech_.featuresNativeTextTracks?this.hide():this.show()},r.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},r.clearDisplay=function(){"function"==typeof e.WebVTT&&e.WebVTT.processCues(e,[],this.el_)},r.updateDisplay=function(){var e=this.player_.textTracks(),t=this.options_.allowMultipleShowingTracks;if(this.clearDisplay(),t){for(var n=[],r=0;r<e.length;++r){var i=e[r];"showing"===i.mode&&n.push(i)}return void this.updateForTrack(n)}for(var a=null,o=null,s=e.length;s--;){var u=e[s];"showing"===u.mode&&("descriptions"===u.kind?a=u:o=u)}o?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(o)):a&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(a))},r.updateDisplayState=function(t){for(var n=this.player_.textTrackSettings.getValues(),r=t.activeCues,i=r.length;i--;){var a=r[i];if(a){var o=a.displayState;if(n.color&&(o.firstChild.style.color=n.color),n.textOpacity&&tt(o.firstChild,"color",et(n.color||"#fff",n.textOpacity)),n.backgroundColor&&(o.firstChild.style.backgroundColor=n.backgroundColor),n.backgroundOpacity&&tt(o.firstChild,"backgroundColor",et(n.backgroundColor||"#000",n.backgroundOpacity)),n.windowColor&&(n.windowOpacity?tt(o,"backgroundColor",et(n.windowColor,n.windowOpacity)):o.style.backgroundColor=n.windowColor),n.edgeStyle&&("dropshadow"===n.edgeStyle?o.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px #222":"raised"===n.edgeStyle?o.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px #222":"depressed"===n.edgeStyle?o.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px #222":"uniform"===n.edgeStyle&&(o.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px #222")),n.fontPercent&&1!==n.fontPercent){var s=e.parseFloat(o.style.fontSize);o.style.fontSize=s*n.fontPercent+"px",o.style.height="auto",o.style.top="auto",o.style.bottom="2px"}n.fontFamily&&"default"!==n.fontFamily&&("small-caps"===n.fontFamily?o.firstChild.style.fontVariant="small-caps":o.firstChild.style.fontFamily=Ea[n.fontFamily])}}},r.updateForTrack=function(t){if(Array.isArray(t)||(t=[t]),"function"==typeof e.WebVTT&&!t.every(function(e){return!e.activeCues})){for(var n=[],r=0;r<t.length;++r)for(var i=t[r],a=0;a<i.activeCues.length;++a)n.push(i.activeCues[a]);e.WebVTT.processCues(e,n,this.el_);for(var o=0;o<t.length;++o){for(var s=t[o],u=0;u<s.activeCues.length;++u){var l=s.activeCues[u].displayState;b(l,"vjs-text-track-cue"),b(l,"vjs-text-track-cue-"+(s.language?s.language:o))}this.player_.textTrackSettings&&this.updateDisplayState(s)}}},n}(rn);rn.registerComponent("TextTrackDisplay",Aa);var Ca=function(e){function t(){return e.apply(this,arguments)||this}return Q(t,e),t.prototype.createEl=function(){var t=this.player_.isAudio(),n=this.localize(t?"Audio Player":"Video Player"),r=v("span",{className:"vjs-control-text",innerHTML:this.localize("{1} is loading.",[n])}),i=e.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"});return i.appendChild(r),i},t}(rn);rn.registerComponent("LoadingSpinner",Ca);var La=function(e){function t(){return e.apply(this,arguments)||this}Q(t,e);var n=t.prototype;return n.createEl=function(e,t,n){void 0===t&&(t={}),void 0===n&&(n={}),e="button",t=a({innerHTML:'<span aria-hidden="true" class="vjs-icon-placeholder"></span>',className:this.buildCSSClass()},t),n=a({type:"button"},n);var r=rn.prototype.createEl.call(this,e,t,n);return this.createControlTextEl(r),r},n.addChild=function(e,t){void 0===t&&(t={});var n=this.constructor.name;return Tt.warn("Adding an actionable (user controllable) child to a Button ("+n+") is not supported; use a ClickableComponent instead."),rn.prototype.addChild.call(this,e,t)},n.enable=function(){e.prototype.enable.call(this),this.el_.removeAttribute("disabled")},n.disable=function(){e.prototype.disable.call(this),this.el_.setAttribute("disabled","disabled")},n.handleKeyDown=function(t){if(Bn.isEventKey(t,"Space")||Bn.isEventKey(t,"Enter"))return void t.stopPropagation();e.prototype.handleKeyDown.call(this,t)},t}(wa);rn.registerComponent("Button",La);var xa=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.mouseused_=!1,r.on("mousedown",r.handleMouseDown),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-big-play-button"},n.handleClick=function(e){var t=this.player_.play();if(this.mouseused_&&e.clientX&&e.clientY)return de(t),void(this.player_.tech(!0)&&this.player_.tech(!0).focus());var n=this.player_.getChild("controlBar"),r=n&&n.getChild("playToggle");if(!r)return void this.player_.tech(!0).focus();var i=function(){return r.focus()};ce(t)?t.then(i,function(){}):this.setTimeout(i,1)},n.handleKeyDown=function(t){this.mouseused_=!1,e.prototype.handleKeyDown.call(this,t)},n.handleMouseDown=function(e){this.mouseused_=!0},t}(La);xa.prototype.controlText_="Play Video",rn.registerComponent("BigPlayButton",xa);var ja=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.controlText(n&&n.controlText||r.localize("Close")),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-close-button "+e.prototype.buildCSSClass.call(this)},n.handleClick=function(e){this.trigger({type:"close",bubbles:!1})},n.handleKeyDown=function(t){Bn.isEventKey(t,"Esc")?(t.preventDefault(),t.stopPropagation(),this.trigger("click")):e.prototype.handleKeyDown.call(this,t)},t}(La);rn.registerComponent("CloseButton",ja);var Oa=function(e){function t(t,n){var r;return void 0===n&&(n={}),r=e.call(this,t,n)||this,n.replay=void 0===n.replay||n.replay,r.on(t,"play",r.handlePlay),r.on(t,"pause",r.handlePause),n.replay&&r.on(t,"ended",r.handleEnded),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-play-control "+e.prototype.buildCSSClass.call(this)},n.handleClick=function(e){this.player_.paused()?this.player_.play():this.player_.pause()},n.handleSeeked=function(e){this.removeClass("vjs-ended"),this.player_.paused()?this.handlePause(e):this.handlePlay(e)},n.handlePlay=function(e){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.controlText("Pause")},n.handlePause=function(e){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.controlText("Play")},n.handleEnded=function(e){this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.controlText("Replay"),this.one(this.player_,"seeked",this.handleSeeked)},t}(La);Oa.prototype.controlText_="Play",rn.registerComponent("PlayToggle",Oa);var Ia=function(e,t){e=e<0?0:e;var n=Math.floor(e%60),r=Math.floor(e/60%60),i=Math.floor(e/3600),a=Math.floor(t/60%60),o=Math.floor(t/3600);return(isNaN(e)||e===1/0)&&(i=r=n="-"),i=i>0||o>0?i+":":"",r=((i||a>=10)&&r<10?"0"+r:r)+":",n=n<10?"0"+n:n,i+r+n},Pa=Ia,Ra=function(e){function n(t,n){var r;return r=e.call(this,t,n)||this,r.throttledUpdateContent=Ft(Nt(ne(r),r.updateContent),Bt),r.on(t,"timeupdate",r.throttledUpdateContent),r}Q(n,e);var r=n.prototype;return r.createEl=function(){var t=this.buildCSSClass(),n=e.prototype.createEl.call(this,"div",{className:t+" vjs-time-control vjs-control",innerHTML:'<span class="vjs-control-text" role="presentation">'+this.localize(this.labelText_)+" </span>"});return this.contentEl_=v("span",{className:t+"-display"},{"aria-live":"off",role:"presentation"}),this.updateTextNode_(),n.appendChild(this.contentEl_),n},r.dispose=function(){this.contentEl_=null,this.textNode_=null,e.prototype.dispose.call(this)},r.updateTextNode_=function(){if(this.contentEl_){for(;this.contentEl_.firstChild;)this.contentEl_.removeChild(this.contentEl_.firstChild);this.textNode_=t.createTextNode(this.formattedTime_||this.formatTime_(0)),this.contentEl_.appendChild(this.textNode_)}},r.formatTime_=function(e){return it(e)},r.updateFormattedTime_=function(e){var t=this.formatTime_(e);t!==this.formattedTime_&&(this.formattedTime_=t,this.requestAnimationFrame(this.updateTextNode_))},r.updateContent=function(e){},n}(rn);Ra.prototype.labelText_="Time",Ra.prototype.controlText_="Time",rn.registerComponent("TimeDisplay",Ra);var Da=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.on(t,"ended",r.handleEnded),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-current-time"},n.updateContent=function(e){var t=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();this.updateFormattedTime_(t)},n.handleEnded=function(e){this.player_.duration()&&this.updateFormattedTime_(this.player_.duration())},t}(Ra);Da.prototype.labelText_="Current Time",Da.prototype.controlText_="Current Time",rn.registerComponent("CurrentTimeDisplay",Da);var Ma=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.on(t,"durationchange",r.updateContent),r.on(t,"loadstart",r.updateContent),r.on(t,"loadedmetadata",r.throttledUpdateContent),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-duration"},n.updateContent=function(e){var t=this.player_.duration();this.duration_!==t&&(this.duration_=t,this.updateFormattedTime_(t))},t}(Ra);Ma.prototype.labelText_="Duration",Ma.prototype.controlText_="Duration",rn.registerComponent("DurationDisplay",Ma);var Ua=function(e){function t(){return e.apply(this,arguments)||this}return Q(t,e),t.prototype.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"<div><span>/</span></div>"},{"aria-hidden":!0})},t}(rn);rn.registerComponent("TimeDivider",Ua);var Ba=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.on(t,"durationchange",r.throttledUpdateContent),r.on(t,"ended",r.handleEnded),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-remaining-time"},n.createEl=function(){var t=e.prototype.createEl.call(this);return t.insertBefore(v("span",{},{"aria-hidden":!0},"-"),this.contentEl_),t},n.updateContent=function(e){"number"==typeof this.player_.duration()&&(this.player_.remainingTimeDisplay?this.updateFormattedTime_(this.player_.remainingTimeDisplay()):this.updateFormattedTime_(this.player_.remainingTime()))},n.handleEnded=function(e){this.player_.duration()&&this.updateFormattedTime_(0)},t}(Ra);Ba.prototype.labelText_="Remaining Time",Ba.prototype.controlText_="Remaining Time",rn.registerComponent("RemainingTimeDisplay",Ba);var Na=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.updateShowing(),r.on(r.player(),"durationchange",r.updateShowing),r}Q(t,e);var n=t.prototype;return n.createEl=function(){var t=e.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.contentEl_=v("div",{className:"vjs-live-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Stream Type")+" </span>"+this.localize("LIVE")},{"aria-live":"off"}),t.appendChild(this.contentEl_),t},n.dispose=function(){this.contentEl_=null,e.prototype.dispose.call(this)},n.updateShowing=function(e){this.player().duration()===1/0?this.show():this.hide()},t}(rn);rn.registerComponent("LiveDisplay",Na);var Fa=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.updateLiveEdgeStatus(),r.player_.liveTracker&&r.on(r.player_.liveTracker,"liveedgechange",r.updateLiveEdgeStatus),r}Q(t,e);var n=t.prototype;return n.createEl=function(){var t=e.prototype.createEl.call(this,"button",{className:"vjs-seek-to-live-control vjs-control"});return this.textEl_=v("span",{className:"vjs-seek-to-live-text",innerHTML:this.localize("LIVE")},{"aria-hidden":"true"}),t.appendChild(this.textEl_),t},n.updateLiveEdgeStatus=function(e){!this.player_.liveTracker||this.player_.liveTracker.atLiveEdge()?(this.setAttribute("aria-disabled",!0),this.addClass("vjs-at-live-edge"),this.controlText("Seek to live, currently playing live")):(this.setAttribute("aria-disabled",!1),this.removeClass("vjs-at-live-edge"),this.controlText("Seek to live, currently behind live"))},n.handleClick=function(){this.player_.liveTracker.seekToLiveEdge()},n.dispose=function(){this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatus),this.textEl_=null,e.prototype.dispose.call(this)},t}(La);Fa.prototype.controlText_="Seek to live, currently playing live",rn.registerComponent("SeekToLive",Fa);var Va=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.bar=r.getChild(r.options_.barName),r.vertical(!!r.options_.vertical),r.enable(),r}Q(t,e);var n=t.prototype;return n.enabled=function(){return this.enabled_},n.enable=function(){this.enabled()||(this.on("mousedown",this.handleMouseDown),this.on("touchstart",this.handleMouseDown),this.on("keydown",this.handleKeyDown),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)},n.disable=function(){if(this.enabled()){var e=this.bar.el_.ownerDocument;this.off("mousedown",this.handleMouseDown),this.off("touchstart",this.handleMouseDown),this.off("keydown",this.handleKeyDown),this.off("click",this.handleClick),this.off(this.player_,"controlsvisible",this.update),this.off(e,"mousemove",this.handleMouseMove),this.off(e,"mouseup",this.handleMouseUp),this.off(e,"touchmove",this.handleMouseMove),this.off(e,"touchend",this.handleMouseUp),this.removeAttribute("tabindex"),this.addClass("disabled"),this.playerEvent&&this.off(this.player_,this.playerEvent,this.update),this.enabled_=!1}},n.createEl=function(t,n,r){return void 0===n&&(n={}),void 0===r&&(r={}),n.className=n.className+" vjs-slider",n=a({tabIndex:0},n),r=a({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},r),e.prototype.createEl.call(this,t,n,r)},n.handleMouseDown=function(e){var t=this.bar.el_.ownerDocument;"mousedown"===e.type&&e.preventDefault(),"touchstart"!==e.type||_n||e.preventDefault(),L(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(t,"mousemove",this.handleMouseMove),this.on(t,"mouseup",this.handleMouseUp),this.on(t,"touchmove",this.handleMouseMove),this.on(t,"touchend",this.handleMouseUp),this.handleMouseMove(e)},n.handleMouseMove=function(e){},n.handleMouseUp=function(){var e=this.bar.el_.ownerDocument;x(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(e,"mousemove",this.handleMouseMove),this.off(e,"mouseup",this.handleMouseUp),this.off(e,"touchmove",this.handleMouseMove),this.off(e,"touchend",this.handleMouseUp),this.update()},n.update=function(){if(this.el_){var e=this.getPercent(),t=this.bar;if(t){("number"!=typeof e||e!==e||e<0||e===1/0)&&(e=0);var n=(100*e).toFixed(2)+"%",r=t.el().style,i=this.vertical()?"height":"width";return r[i]!==n&&(r[i]=n),e}}},n.calculateDistance=function(e){var t=I(this.el_,e);return this.vertical()?t.y:t.x},n.handleKeyDown=function(t){Bn.isEventKey(t,"Left")||Bn.isEventKey(t,"Down")?(t.preventDefault(),t.stopPropagation(),this.stepBack()):Bn.isEventKey(t,"Right")||Bn.isEventKey(t,"Up")?(t.preventDefault(),t.stopPropagation(),this.stepForward()):e.prototype.handleKeyDown.call(this,t)},n.handleClick=function(e){e.stopPropagation(),e.preventDefault()},n.vertical=function(e){if(void 0===e)return this.vertical_||!1;this.vertical_=!!e,this.vertical_?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal")},t}(rn);rn.registerComponent("Slider",Va);var qa=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.partEls_=[],r.on(t,"progress",r.update),r}Q(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-load-progress",innerHTML:'<span class="vjs-control-text"><span>'+this.localize("Loaded")+'</span>: <span class="vjs-control-text-loaded-percentage">0%</span></span>'})},n.dispose=function(){this.partEls_=null,e.prototype.dispose.call(this)},n.update=function(e){var t=this.player_.liveTracker,n=this.player_.buffered(),r=t&&t.isLive()?t.seekableEnd():this.player_.duration(),i=this.player_.bufferedEnd(),a=this.partEls_,o=this.$(".vjs-control-text-loaded-percentage"),s=function(e,t,n){var r=e/t||0;return r=100*(r>=1?1:r),n&&(r=r.toFixed(2)),r+"%"};this.el_.style.width=s(i,r),g(o,s(i,r,!0));for(var u=0;u<n.length;u++){var l=n.start(u),c=n.end(u),d=a[u];d||(d=this.el_.appendChild(v()),a[u]=d),d.style.left=s(l,i),d.style.width=s(c-l,i)}for(var f=a.length;f>n.length;f--)this.el_.removeChild(a[f-1]);a.length=n.length},t}(rn);rn.registerComponent("LoadProgressBar",qa);var Ga=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.update=Ft(Nt(ne(r),r.update),Bt),r}Q(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-time-tooltip"},{"aria-hidden":"true"})},n.update=function(e,t,n){var r=j(this.el_),i=j(this.player_.el()),a=e.width*t;if(i&&r){var o=e.left-i.left+a,s=e.width-a+(i.right-e.right),u=r.width/2;o<u?u+=u-o:s<u&&(u=s),u<0?u=0:u>r.width&&(u=r.width),this.el_.style.right="-"+u+"px",this.write(n)}},n.write=function(e){g(this.el_,e)},n.updateTime=function(e,t,n,r){var i=this;this.rafId_&&this.cancelAnimationFrame(this.rafId_),this.rafId_=this.requestAnimationFrame(function(){var a,o=i.player_.duration();if(i.player_.liveTracker&&i.player_.liveTracker.isLive()){var s=i.player_.liveTracker.liveWindow(),u=s-t*s;a=(u<1?"":"-")+it(u,s)}else a=it(n,o);i.update(e,t,a),r&&r()})},t}(rn);rn.registerComponent("TimeTooltip",Ga);var Ha=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.update=Ft(Nt(ne(r),r.update),Bt),r}Q(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"},{"aria-hidden":"true"})},n.update=function(e,t){var n=this.getChild("timeTooltip");if(n){var r=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();n.updateTime(e,t,r)}},t}(rn);Ha.prototype.options_={children:[]},fn||pn||Ha.prototype.options_.children.push("timeTooltip"),rn.registerComponent("PlayProgressBar",Ha);var za=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.update=Ft(Nt(ne(r),r.update),Bt),r}Q(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},n.update=function(e,t){var n=this,r=t*this.player_.duration();this.getChild("timeTooltip").updateTime(e,t,r,function(){n.el_.style.left=e.width*t+"px"})},t}(rn);za.prototype.options_={children:["timeTooltip"]},rn.registerComponent("MouseTimeDisplay",za);var Wa=function(e){function n(t,n){var r;return r=e.call(this,t,n)||this,r.setEventHandlers_(),r}Q(n,e);var r=n.prototype;return r.setEventHandlers_=function(){this.update=Ft(Nt(this,this.update),30),this.on(this.player_,"timeupdate",this.update),this.on(this.player_,"ended",this.handleEnded),this.on(this.player_,"durationchange",this.update),this.player_.liveTracker&&this.on(this.player_.liveTracker,"liveedgechange",this.update),this.updateInterval=null,this.on(this.player_,["playing"],this.enableInterval_),this.on(this.player_,["ended","pause","waiting"],this.disableInterval_),"hidden"in t&&"visibilityState"in t&&this.on(t,"visibilitychange",this.toggleVisibility_)},r.toggleVisibility_=function(e){t.hidden?this.disableInterval_(e):(this.enableInterval_(),this.requestAnimationFrame(this.update))},r.enableInterval_=function(){var e=this;this.clearInterval(this.updateInterval),this.updateInterval=this.setInterval(function(){e.requestAnimationFrame(e.update)},30)},r.disableInterval_=function(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&"ended"!==e.type||this.clearInterval(this.updateInterval)},r.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})},r.update_=function(e,t){var n=this.player_.liveTracker,r=this.player_.duration();n&&n.isLive()&&(r=this.player_.liveTracker.liveCurrentTime()),this.el_.setAttribute("aria-valuenow",(100*t).toFixed(2)),this.el_.setAttribute("aria-valuetext",this.localize("progress bar timing: currentTime={1} duration={2}",[it(e,r),it(r,r)],"{1} of {2}")),this.bar&&this.bar.update(j(this.el_),t)},r.update=function(t){if(null!==this.el().offsetParent){var n=e.prototype.update.call(this);return this.update_(this.getCurrentTime_(),n),n}},r.getCurrentTime_=function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()},r.handleEnded=function(e){this.update_(this.player_.duration(),1)},r.getPercent=function(){var e,t=this.getCurrentTime_(),n=this.player_.liveTracker;return n&&n.isLive()?(e=(t-n.seekableStart())/n.liveWindow(),n.atLiveEdge()&&(e=1)):e=t/this.player_.duration(),e>=1?1:e||0},r.handleMouseDown=function(t){B(t)&&(t.stopPropagation(),this.player_.scrubbing(!0),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),e.prototype.handleMouseDown.call(this,t))},r.handleMouseMove=function(e){if(B(e)){var t,n=this.calculateDistance(e),r=this.player_.liveTracker;if(r&&r.isLive()){var i=r.seekableStart(),a=r.liveCurrentTime();if(t=i+n*r.liveWindow(),t>=a&&(t=a),t<=i&&(t=i+.1),t===1/0)return}else(t=n*this.player_.duration())===this.player_.duration()&&(t-=.1);this.player_.currentTime(t)}},r.enable=function(){e.prototype.enable.call(this);var t=this.getChild("mouseTimeDisplay");t&&t.show()},r.disable=function(){e.prototype.disable.call(this);var t=this.getChild("mouseTimeDisplay");t&&t.hide()},r.handleMouseUp=function(t){e.prototype.handleMouseUp.call(this,t),t&&t.stopPropagation(),this.player_.scrubbing(!1),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0}),this.videoWasPlaying&&de(this.player_.play())},r.stepForward=function(){this.player_.currentTime(this.player_.currentTime()+5)},r.stepBack=function(){this.player_.currentTime(this.player_.currentTime()-5)},r.handleAction=function(e){this.player_.paused()?this.player_.play():this.player_.pause()},r.handleKeyDown=function(t){if(Bn.isEventKey(t,"Space")||Bn.isEventKey(t,"Enter"))t.preventDefault(),t.stopPropagation(),this.handleAction(t);else if(Bn.isEventKey(t,"Home"))t.preventDefault(),t.stopPropagation(),this.player_.currentTime(0);else if(Bn.isEventKey(t,"End"))t.preventDefault(),t.stopPropagation(),this.player_.currentTime(this.player_.duration());else if(/^[0-9]$/.test(Bn(t))){t.preventDefault(),t.stopPropagation();var n=10*(Bn.codes[Bn(t)]-Bn.codes[0])/100;this.player_.currentTime(this.player_.duration()*n)}else Bn.isEventKey(t,"PgDn")?(t.preventDefault(),t.stopPropagation(),this.player_.currentTime(this.player_.currentTime()-60)):Bn.isEventKey(t,"PgUp")?(t.preventDefault(),t.stopPropagation(),this.player_.currentTime(this.player_.currentTime()+60)):e.prototype.handleKeyDown.call(this,t)},n}(Va);Wa.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"},fn||pn||Wa.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),rn.registerComponent("SeekBar",Wa);var $a=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.handleMouseMove=Ft(Nt(ne(r),r.handleMouseMove),Bt),r.throttledHandleMouseSeek=Ft(Nt(ne(r),r.handleMouseSeek),Bt),r.enable(),r}Q(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},n.handleMouseMove=function(e){var t=this.getChild("seekBar");if(t){var n=t.getChild("mouseTimeDisplay"),r=t.el(),i=j(r),a=I(r,e).x;a>1?a=1:a<0&&(a=0),n&&n.update(i,a)}},n.handleMouseSeek=function(e){var t=this.getChild("seekBar");t&&t.handleMouseMove(e)},n.enabled=function(){return this.enabled_},n.disable=function(){this.children().forEach(function(e){return e.disable&&e.disable()}),this.enabled()&&(this.off(["mousedown","touchstart"],this.handleMouseDown),this.off(this.el_,"mousemove",this.handleMouseMove),this.handleMouseUp(),this.addClass("disabled"),this.enabled_=!1)},n.enable=function(){this.children().forEach(function(e){return e.enable&&e.enable()}),this.enabled()||(this.on(["mousedown","touchstart"],this.handleMouseDown),this.on(this.el_,"mousemove",this.handleMouseMove),this.removeClass("disabled"),this.enabled_=!0)},n.handleMouseDown=function(e){var t=this.el_.ownerDocument,n=this.getChild("seekBar");n&&n.handleMouseDown(e),this.on(t,"mousemove",this.throttledHandleMouseSeek),this.on(t,"touchmove",this.throttledHandleMouseSeek),this.on(t,"mouseup",this.handleMouseUp),this.on(t,"touchend",this.handleMouseUp)},n.handleMouseUp=function(e){var t=this.el_.ownerDocument,n=this.getChild("seekBar");n&&n.handleMouseUp(e),this.off(t,"mousemove",this.throttledHandleMouseSeek),this.off(t,"touchmove",this.throttledHandleMouseSeek),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchend",this.handleMouseUp)},t}(rn);$a.prototype.options_={children:["seekBar"]},rn.registerComponent("ProgressControl",$a);var Ya=function(e){function n(n,r){var i;return i=e.call(this,n,r)||this,i.on(n,["enterpictureinpicture","leavepictureinpicture"],i.handlePictureInPictureChange),t.pictureInPictureEnabled||i.disable(),i}Q(n,e);var r=n.prototype;return r.buildCSSClass=function(){return"vjs-picture-in-picture-control "+e.prototype.buildCSSClass.call(this)},r.handlePictureInPictureChange=function(e){this.player_.isInPictureInPicture()?this.controlText("Exit Picture-in-Picture"):this.controlText("Picture-in-Picture")},r.handleClick=function(e){this.player_.isInPictureInPicture()?this.player_.exitPictureInPicture():this.player_.requestPictureInPicture()},n}(La);Ya.prototype.controlText_="Picture-in-Picture",rn.registerComponent("PictureInPictureToggle",Ya);var Ka=function(e){function n(n,r){var i;return i=e.call(this,n,r)||this,i.on(n,"fullscreenchange",i.handleFullscreenChange),!1===t[n.fsApi_.fullscreenEnabled]&&i.disable(),i}Q(n,e);var r=n.prototype;return r.buildCSSClass=function(){return"vjs-fullscreen-control "+e.prototype.buildCSSClass.call(this)},r.handleFullscreenChange=function(e){this.player_.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},r.handleClick=function(e){this.player_.isFullscreen()?this.player_.exitFullscreen():this.player_.requestFullscreen()},n}(La);Ka.prototype.controlText_="Fullscreen",rn.registerComponent("FullscreenToggle",Ka);var Xa=function(e,t){t.tech_&&!t.tech_.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(t,"loadstart",function(){t.tech_.featuresVolumeControl?e.removeClass("vjs-hidden"):e.addClass("vjs-hidden")})},Ja=function(e){function t(){return e.apply(this,arguments)||this}return Q(t,e),t.prototype.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-volume-level",innerHTML:'<span class="vjs-control-text"></span>'})},t}(rn);rn.registerComponent("VolumeLevel",Ja);var Qa=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.on("slideractive",r.updateLastVolume_),r.on(t,"volumechange",r.updateARIAAttributes),t.ready(function(){return r.updateARIAAttributes()}),r}Q(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":this.localize("Volume Level"),"aria-live":"polite"})},n.handleMouseDown=function(t){B(t)&&e.prototype.handleMouseDown.call(this,t)},n.handleMouseMove=function(e){B(e)&&(this.checkMuted(),this.player_.volume(this.calculateDistance(e)))},n.checkMuted=function(){this.player_.muted()&&this.player_.muted(!1)},n.getPercent=function(){return this.player_.muted()?0:this.player_.volume()},n.stepForward=function(){this.checkMuted(),this.player_.volume(this.player_.volume()+.1)},n.stepBack=function(){this.checkMuted(),this.player_.volume(this.player_.volume()-.1)},n.updateARIAAttributes=function(e){var t=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",t),this.el_.setAttribute("aria-valuetext",t+"%")},n.volumeAsPercentage_=function(){return Math.round(100*this.player_.volume())},n.updateLastVolume_=function(){var e=this,t=this.player_.volume();this.one("sliderinactive",function(){0===e.player_.volume()&&e.player_.lastVolume_(t)})},t}(Va);Qa.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"},Qa.prototype.playerEvent="volumechange",rn.registerComponent("VolumeBar",Qa);var Za=function(e){function t(t,n){var r;return void 0===n&&(n={}),n.vertical=n.vertical||!1,(void 0===n.volumeBar||s(n.volumeBar))&&(n.volumeBar=n.volumeBar||{},n.volumeBar.vertical=n.vertical),r=e.call(this,t,n)||this,Xa(ne(r),t),r.throttledHandleMouseMove=Ft(Nt(ne(r),r.handleMouseMove),Bt),r.on("mousedown",r.handleMouseDown),r.on("touchstart",r.handleMouseDown),r.on(r.volumeBar,["focus","slideractive"],function(){r.volumeBar.addClass("vjs-slider-active"),r.addClass("vjs-slider-active"),r.trigger("slideractive")}),r.on(r.volumeBar,["blur","sliderinactive"],function(){r.volumeBar.removeClass("vjs-slider-active"),r.removeClass("vjs-slider-active"),r.trigger("sliderinactive")}),r}Q(t,e);var n=t.prototype;return n.createEl=function(){var t="vjs-volume-horizontal";return this.options_.vertical&&(t="vjs-volume-vertical"),e.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control "+t})},n.handleMouseDown=function(e){var t=this.el_.ownerDocument;this.on(t,"mousemove",this.throttledHandleMouseMove),this.on(t,"touchmove",this.throttledHandleMouseMove),this.on(t,"mouseup",this.handleMouseUp),this.on(t,"touchend",this.handleMouseUp)},n.handleMouseUp=function(e){var t=this.el_.ownerDocument;this.off(t,"mousemove",this.throttledHandleMouseMove),this.off(t,"touchmove",this.throttledHandleMouseMove),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchend",this.handleMouseUp)},n.handleMouseMove=function(e){this.volumeBar.handleMouseMove(e)},t}(rn);Za.prototype.options_={children:["volumeBar"]},rn.registerComponent("VolumeControl",Za);var eo=function(e,t){t.tech_&&!t.tech_.featuresMuteControl&&e.addClass("vjs-hidden"),e.on(t,"loadstart",function(){t.tech_.featuresMuteControl?e.removeClass("vjs-hidden"):e.addClass("vjs-hidden")})},to=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,eo(ne(r),t),r.on(t,["loadstart","volumechange"],r.update),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-mute-control "+e.prototype.buildCSSClass.call(this)},n.handleClick=function(e){var t=this.player_.volume(),n=this.player_.lastVolume_();if(0===t){var r=n<.1?.1:n;this.player_.volume(r),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())},n.update=function(e){this.updateIcon_(),this.updateControlText_()},n.updateIcon_=function(){var e=this.player_.volume(),t=3;fn&&this.player_.tech_&&this.player_.tech_.el_&&this.player_.muted(this.player_.tech_.el_.muted),0===e||this.player_.muted()?t=0:e<.33?t=1:e<.67&&(t=2);for(var n=0;n<4;n++)T(this.el_,"vjs-vol-"+n);b(this.el_,"vjs-vol-"+t)},n.updateControlText_=function(){var e=this.player_.muted()||0===this.player_.volume(),t=e?"Unmute":"Mute";this.controlText()!==t&&this.controlText(t)},t}(La);to.prototype.controlText_="Mute",rn.registerComponent("MuteToggle",to);var no=function(e){function n(t,n){var r;return void 0===n&&(n={}),void 0!==n.inline?n.inline=n.inline:n.inline=!0,(void 0===n.volumeControl||s(n.volumeControl))&&(n.volumeControl=n.volumeControl||{},n.volumeControl.vertical=!n.inline),r=e.call(this,t,n)||this,r.on(t,["loadstart"],r.volumePanelState_),r.on(r.muteToggle,"keyup",r.handleKeyPress),r.on(r.volumeControl,"keyup",r.handleVolumeControlKeyUp),r.on("keydown",r.handleKeyPress),r.on("mouseover",r.handleMouseOver),r.on("mouseout",r.handleMouseOut),r.on(r.volumeControl,["slideractive"],r.sliderActive_),r.on(r.volumeControl,["sliderinactive"],r.sliderInactive_),r}Q(n,e);var r=n.prototype;return r.sliderActive_=function(){this.addClass("vjs-slider-active")},r.sliderInactive_=function(){this.removeClass("vjs-slider-active")},r.volumePanelState_=function(){this.volumeControl.hasClass("vjs-hidden")&&this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-hidden"),this.volumeControl.hasClass("vjs-hidden")&&!this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-mute-toggle-only")},r.createEl=function(){var t="vjs-volume-panel-horizontal";return this.options_.inline||(t="vjs-volume-panel-vertical"),e.prototype.createEl.call(this,"div",{className:"vjs-volume-panel vjs-control "+t})},r.dispose=function(){this.handleMouseOut(),e.prototype.dispose.call(this)},r.handleVolumeControlKeyUp=function(e){Bn.isEventKey(e,"Esc")&&this.muteToggle.focus()},r.handleMouseOver=function(e){this.addClass("vjs-hover"),G(t,"keyup",Nt(this,this.handleKeyPress))},r.handleMouseOut=function(e){this.removeClass("vjs-hover"),H(t,"keyup",Nt(this,this.handleKeyPress))},r.handleKeyPress=function(e){Bn.isEventKey(e,"Esc")&&this.handleMouseOut()},n}(rn);no.prototype.options_={children:["muteToggle","volumeControl"]},rn.registerComponent("VolumePanel",no);var ro=function(e){function n(t,n){var r;return r=e.call(this,t,n)||this,n&&(r.menuButton_=n.menuButton),r.focusedChild_=-1,r.on("keydown",r.handleKeyDown),r.boundHandleBlur_=Nt(ne(r),r.handleBlur),r.boundHandleTapClick_=Nt(ne(r),r.handleTapClick),r}Q(n,e);var r=n.prototype;return r.addEventListenerForItem=function(e){e instanceof rn&&(this.on(e,"blur",this.boundHandleBlur_),this.on(e,["tap","click"],this.boundHandleTapClick_))},r.removeEventListenerForItem=function(e){e instanceof rn&&(this.off(e,"blur",this.boundHandleBlur_),this.off(e,["tap","click"],this.boundHandleTapClick_))},r.removeChild=function(t){"string"==typeof t&&(t=this.getChild(t)),this.removeEventListenerForItem(t),e.prototype.removeChild.call(this,t)},r.addItem=function(e){var t=this.addChild(e);t&&this.addEventListenerForItem(t)},r.createEl=function(){var t=this.options_.contentElType||"ul";this.contentEl_=v(t,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");var n=e.prototype.createEl.call(this,"div",{append:this.contentEl_,className:"vjs-menu"});return n.appendChild(this.contentEl_),G(n,"click",function(e){e.preventDefault(),e.stopImmediatePropagation()}),n},r.dispose=function(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,e.prototype.dispose.call(this)},r.handleBlur=function(e){var n=e.relatedTarget||t.activeElement;if(!this.children().some(function(e){return e.el()===n})){var r=this.menuButton_;r&&r.buttonPressed_&&n!==r.el().firstChild&&r.unpressButton()}},r.handleTapClick=function(e){if(this.menuButton_){this.menuButton_.unpressButton();var t=this.children();if(!Array.isArray(t))return;var n=t.filter(function(t){return t.el()===e.target})[0];if(!n)return;"CaptionSettingsMenuItem"!==n.name()&&this.menuButton_.focus()}},r.handleKeyDown=function(e){Bn.isEventKey(e,"Left")||Bn.isEventKey(e,"Down")?(e.preventDefault(),e.stopPropagation(),this.stepForward()):(Bn.isEventKey(e,"Right")||Bn.isEventKey(e,"Up"))&&(e.preventDefault(),e.stopPropagation(),this.stepBack())},r.stepForward=function(){var e=0;void 0!==this.focusedChild_&&(e=this.focusedChild_+1),this.focus(e)},r.stepBack=function(){var e=0;void 0!==this.focusedChild_&&(e=this.focusedChild_-1),this.focus(e)},r.focus=function(e){void 0===e&&(e=0);var t=this.children().slice();t.length&&t[0].className&&/vjs-menu-title/.test(t[0].className)&&t.shift(),t.length>0&&(e<0?e=0:e>=t.length&&(e=t.length-1),this.focusedChild_=e,t[e].el_.focus())},n}(rn);rn.registerComponent("Menu",ro);var io=function(e){function n(n,r){var i;void 0===r&&(r={}),i=e.call(this,n,r)||this,i.menuButton_=new La(n,r),i.menuButton_.controlText(i.controlText_),i.menuButton_.el_.setAttribute("aria-haspopup","true");var a=La.prototype.buildCSSClass();return i.menuButton_.el_.className=i.buildCSSClass()+" "+a,i.menuButton_.removeClass("vjs-control"),i.addChild(i.menuButton_),i.update(),i.enabled_=!0,i.on(i.menuButton_,"tap",i.handleClick),i.on(i.menuButton_,"click",i.handleClick),i.on(i.menuButton_,"keydown",i.handleKeyDown),i.on(i.menuButton_,"mouseenter",function(){i.addClass("vjs-hover"),i.menu.show(),G(t,"keyup",Nt(ne(i),i.handleMenuKeyUp))}),i.on("mouseleave",i.handleMouseLeave),i.on("keydown",i.handleSubmenuKeyDown),i}Q(n,e);var r=n.prototype;return r.update=function(){var e=this.createMenu();this.menu&&(this.menu.dispose(),this.removeChild(this.menu)),this.menu=e,this.addChild(e),this.buttonPressed_=!1,this.menuButton_.el_.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.hideThreshold_?this.hide():this.show()},r.createMenu=function(){var e=new ro(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var t=v("li",{className:"vjs-menu-title",innerHTML:tn(this.options_.title),tabIndex:-1});this.hideThreshold_+=1;var n=new rn(this.player_,{el:t});e.addItem(n)}if(this.items=this.createItems(),this.items)for(var r=0;r<this.items.length;r++)e.addItem(this.items[r]);return e},r.createItems=function(){},r.createEl=function(){return e.prototype.createEl.call(this,"div",{className:this.buildWrapperCSSClass()},{})},r.buildWrapperCSSClass=function(){var t="vjs-menu-button";return!0===this.options_.inline?t+="-inline":t+="-popup","vjs-menu-button "+t+" "+La.prototype.buildCSSClass()+" "+e.prototype.buildCSSClass.call(this)},r.buildCSSClass=function(){var t="vjs-menu-button";return!0===this.options_.inline?t+="-inline":t+="-popup","vjs-menu-button "+t+" "+e.prototype.buildCSSClass.call(this)},r.controlText=function(e,t){return void 0===t&&(t=this.menuButton_.el()),this.menuButton_.controlText(e,t)},r.dispose=function(){this.handleMouseLeave(),e.prototype.dispose.call(this)},r.handleClick=function(e){this.buttonPressed_?this.unpressButton():this.pressButton()},r.handleMouseLeave=function(e){this.removeClass("vjs-hover"),H(t,"keyup",Nt(this,this.handleMenuKeyUp))},r.focus=function(){this.menuButton_.focus()},r.blur=function(){this.menuButton_.blur()},r.handleKeyDown=function(e){Bn.isEventKey(e,"Esc")||Bn.isEventKey(e,"Tab")?(this.buttonPressed_&&this.unpressButton(),Bn.isEventKey(e,"Tab")||(e.preventDefault(),this.menuButton_.focus())):(Bn.isEventKey(e,"Up")||Bn.isEventKey(e,"Down"))&&(this.buttonPressed_||(e.preventDefault(),this.pressButton()))},r.handleMenuKeyUp=function(e){(Bn.isEventKey(e,"Esc")||Bn.isEventKey(e,"Tab"))&&this.removeClass("vjs-hover")},r.handleSubmenuKeyPress=function(e){this.handleSubmenuKeyDown(e)},r.handleSubmenuKeyDown=function(e){(Bn.isEventKey(e,"Esc")||Bn.isEventKey(e,"Tab"))&&(this.buttonPressed_&&this.unpressButton(),Bn.isEventKey(e,"Tab")||(e.preventDefault(),this.menuButton_.focus()))},r.pressButton=function(){if(this.enabled_){if(this.buttonPressed_=!0,this.menu.show(),this.menu.lockShowing(),this.menuButton_.el_.setAttribute("aria-expanded","true"),fn&&p())return;this.menu.focus()}},r.unpressButton=function(){this.enabled_&&(this.buttonPressed_=!1,this.menu.unlockShowing(),this.menu.hide(),this.menuButton_.el_.setAttribute("aria-expanded","false"))},r.disable=function(){this.unpressButton(),this.enabled_=!1,this.addClass("vjs-disabled"),this.menuButton_.disable()},r.enable=function(){this.enabled_=!0,this.removeClass("vjs-disabled"),this.menuButton_.enable()},n}(rn);rn.registerComponent("MenuButton",io);var ao=function(e){function t(t,n){var r,i=n.tracks;if(r=e.call(this,t,n)||this,r.items.length<=1&&r.hide(),!i)return ne(r);var a=Nt(ne(r),r.update);return i.addEventListener("removetrack",a),i.addEventListener("addtrack",a),r.player_.on("ready",a),r.player_.on("dispose",function(){i.removeEventListener("removetrack",a),i.removeEventListener("addtrack",a)}),r}return Q(t,e),t}(io);rn.registerComponent("TrackButton",ao);var oo=["Tab","Esc","Up","Down","Right","Left"],so=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.selectable=n.selectable,r.isSelected_=n.selected||!1,r.multiSelectable=n.multiSelectable,r.selected(r.isSelected_),r.selectable?r.multiSelectable?r.el_.setAttribute("role","menuitemcheckbox"):r.el_.setAttribute("role","menuitemradio"):r.el_.setAttribute("role","menuitem"),r}Q(t,e);var n=t.prototype;return n.createEl=function(t,n,r){return this.nonIconControl=!0,e.prototype.createEl.call(this,"li",a({className:"vjs-menu-item",innerHTML:'<span class="vjs-menu-item-text">'+this.localize(this.options_.label)+"</span>",tabIndex:-1},n),r)},n.handleKeyDown=function(t){oo.some(function(e){return Bn.isEventKey(t,e)})||e.prototype.handleKeyDown.call(this,t)},n.handleClick=function(e){this.selected(!0)},n.selected=function(e){this.selectable&&(e?(this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(", selected"),this.isSelected_=!0):(this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText(""),this.isSelected_=!1))},t}(wa);rn.registerComponent("MenuItem",so);var uo=function(n){function r(r,i){var a,o=i.track,s=r.textTracks();i.label=o.label||o.language||"Unknown",i.selected="showing"===o.mode,a=n.call(this,r,i)||this,a.track=o,a.kinds=(i.kinds||[i.kind||a.track.kind]).filter(Boolean);var u=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];a.handleTracksChange.apply(ne(a),t)},l=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];a.handleSelectedLanguageChange.apply(ne(a),t)};if(r.on(["loadstart","texttrackchange"],u),s.addEventListener("change",u),s.addEventListener("selectedlanguagechange",l),a.on("dispose",function(){r.off(["loadstart","texttrackchange"],u),s.removeEventListener("change",u),s.removeEventListener("selectedlanguagechange",l)}),void 0===s.onchange){var c;a.on(["tap","click"],function(){if("object"!=typeof e.Event)try{c=new e.Event("change")}catch(e){}c||(c=t.createEvent("Event"),c.initEvent("change",!0,!0)),s.dispatchEvent(c)})}return a.handleTracksChange(),a}Q(r,n);var i=r.prototype;return i.handleClick=function(e){var t=this.track,r=this.player_.textTracks();if(n.prototype.handleClick.call(this,e),r)for(var i=0;i<r.length;i++){var a=r[i];-1!==this.kinds.indexOf(a.kind)&&(a===t?"showing"!==a.mode&&(a.mode="showing"):"disabled"!==a.mode&&(a.mode="disabled"))}},i.handleTracksChange=function(e){var t="showing"===this.track.mode;t!==this.isSelected_&&this.selected(t)},i.handleSelectedLanguageChange=function(e){if("showing"===this.track.mode){var t=this.player_.cache_.selectedLanguage;if(t&&t.enabled&&t.language===this.track.language&&t.kind!==this.track.kind)return;this.player_.cache_.selectedLanguage={enabled:!0,language:this.track.language,kind:this.track.kind}}},i.dispose=function(){this.track=null,n.prototype.dispose.call(this)},r}(so);rn.registerComponent("TextTrackMenuItem",uo);var lo=function(e){function t(t,n){return n.track={player:t,kind:n.kind,kinds:n.kinds,default:!1,mode:"disabled"},n.kinds||(n.kinds=[n.kind]),n.label?n.track.label=n.label:n.track.label=n.kinds.join(" and ")+" off",n.selectable=!0,n.multiSelectable=!1,e.call(this,t,n)||this}Q(t,e);var n=t.prototype;return n.handleTracksChange=function(e){for(var t=this.player().textTracks(),n=!0,r=0,i=t.length;r<i;r++){var a=t[r];if(this.options_.kinds.indexOf(a.kind)>-1&&"showing"===a.mode){n=!1;break}}n!==this.isSelected_&&this.selected(n)},n.handleSelectedLanguageChange=function(e){for(var t=this.player().textTracks(),n=!0,r=0,i=t.length;r<i;r++){var a=t[r];if(["captions","descriptions","subtitles"].indexOf(a.kind)>-1&&"showing"===a.mode){n=!1;break}}n&&(this.player_.cache_.selectedLanguage={enabled:!1})},t}(uo);rn.registerComponent("OffTextTrackMenuItem",lo);var co=function(e){function t(t,n){return void 0===n&&(n={}),n.tracks=t.textTracks(),e.call(this,t,n)||this}return Q(t,e),t.prototype.createItems=function(e,t){void 0===e&&(e=[]),void 0===t&&(t=uo);var n;this.label_&&(n=this.label_+" off"),e.push(new lo(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 i=0;i<r.length;i++){var a=r[i];if(this.kinds_.indexOf(a.kind)>-1){var o=new t(this.player_,{track:a,kinds:this.kinds_,kind:this.kind_,selectable:!0,multiSelectable:!1});o.addClass("vjs-"+a.kind+"-menu-item"),e.push(o)}}return e},t}(ao);rn.registerComponent("TextTrackButton",co);var fo=function(e){function t(t,n){var r,i=n.track,a=n.cue,o=t.currentTime();return n.selectable=!0,n.multiSelectable=!1,n.label=a.text,n.selected=a.startTime<=o&&o<a.endTime,r=e.call(this,t,n)||this,r.track=i,r.cue=a,i.addEventListener("cuechange",Nt(ne(r),r.update)),r}Q(t,e);var n=t.prototype;return n.handleClick=function(t){e.prototype.handleClick.call(this),this.player_.currentTime(this.cue.startTime),this.update(this.cue.startTime)},n.update=function(e){var t=this.cue,n=this.player_.currentTime();this.selected(t.startTime<=n&&n<t.endTime)},t}(so);rn.registerComponent("ChaptersTrackMenuItem",fo);var ho=function(e){function t(t,n,r){return e.call(this,t,n,r)||this}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-chapters-button "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-chapters-button "+e.prototype.buildWrapperCSSClass.call(this)},n.update=function(t){this.track_&&(!t||"addtrack"!==t.type&&"removetrack"!==t.type)||this.setTrack(this.findChaptersTrack()),e.prototype.update.call(this)},n.setTrack=function(e){if(this.track_!==e){if(this.updateHandler_||(this.updateHandler_=this.update.bind(this)),this.track_){var t=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);t&&t.removeEventListener("load",this.updateHandler_),this.track_=null}if(this.track_=e,this.track_){this.track_.mode="hidden";var n=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);n&&n.addEventListener("load",this.updateHandler_)}}},n.findChaptersTrack=function(){for(var e=this.player_.textTracks()||[],t=e.length-1;t>=0;t--){var n=e[t];if(n.kind===this.kind_)return n}},n.getMenuCaption=function(){return this.track_&&this.track_.label?this.track_.label:this.localize(tn(this.kind_))},n.createMenu=function(){return this.options_.title=this.getMenuCaption(),e.prototype.createMenu.call(this)},n.createItems=function(){var e=[];if(!this.track_)return e;var t=this.track_.cues;if(!t)return e;for(var n=0,r=t.length;n<r;n++){var i=t[n],a=new fo(this.player_,{track:this.track_,cue:i});e.push(a)}return e},t}(co);ho.prototype.kind_="chapters",ho.prototype.controlText_="Chapters",rn.registerComponent("ChaptersButton",ho);var po=function(e){function t(t,n,r){var i;i=e.call(this,t,n,r)||this;var a=t.textTracks(),o=Nt(ne(i),i.handleTracksChange);return a.addEventListener("change",o),i.on("dispose",function(){a.removeEventListener("change",o)}),i}Q(t,e);var n=t.prototype;return n.handleTracksChange=function(e){for(var t=this.player().textTracks(),n=!1,r=0,i=t.length;r<i;r++){var a=t[r];if(a.kind!==this.kind_&&"showing"===a.mode){n=!0;break}}n?this.disable():this.enable()},n.buildCSSClass=function(){return"vjs-descriptions-button "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-descriptions-button "+e.prototype.buildWrapperCSSClass.call(this)},t}(co);po.prototype.kind_="descriptions",po.prototype.controlText_="Descriptions",rn.registerComponent("DescriptionsButton",po);var mo=function(e){function t(t,n,r){return e.call(this,t,n,r)||this}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-subtitles-button "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-subtitles-button "+e.prototype.buildWrapperCSSClass.call(this)},t}(co);mo.prototype.kind_="subtitles",mo.prototype.controlText_="Subtitles",rn.registerComponent("SubtitlesButton",mo);var vo=function(e){function t(t,n){var r;return n.track={player:t,kind:n.kind,label:n.kind+" settings",selectable:!1,default:!1,mode:"disabled"},n.selectable=!1,n.name="CaptionSettingsMenuItem",r=e.call(this,t,n)||this,r.addClass("vjs-texttrack-settings"),r.controlText(", opens "+n.kind+" settings dialog"),r}return Q(t,e),t.prototype.handleClick=function(e){this.player().getChild("textTrackSettings").open()},t}(uo);rn.registerComponent("CaptionSettingsMenuItem",vo);var go=function(e){function t(t,n,r){return e.call(this,t,n,r)||this}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-captions-button "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-captions-button "+e.prototype.buildWrapperCSSClass.call(this)},n.createItems=function(){var t=[];return this.player().tech_&&this.player().tech_.featuresNativeTextTracks||!this.player().getChild("textTrackSettings")||(t.push(new vo(this.player_,{kind:this.kind_})),this.hideThreshold_+=1),e.prototype.createItems.call(this,t)},t}(co);go.prototype.kind_="captions",go.prototype.controlText_="Captions",rn.registerComponent("CaptionsButton",go);var yo=function(e){function t(){return e.apply(this,arguments)||this}return Q(t,e),t.prototype.createEl=function(t,n,r){var i='<span class="vjs-menu-item-text">'+this.localize(this.options_.label);return"captions"===this.options_.track.kind&&(i+='\n <span aria-hidden="true" class="vjs-icon-placeholder"></span>\n <span class="vjs-control-text"> '+this.localize("Captions")+"</span>\n "),i+="</span>",e.prototype.createEl.call(this,t,a({innerHTML:i},n),r)},t}(uo);rn.registerComponent("SubsCapsMenuItem",yo);var _o=function(e){function t(t,n){var r;return void 0===n&&(n={}),r=e.call(this,t,n)||this,r.label_="subtitles",["en","en-us","en-ca","fr-ca"].indexOf(r.player_.language_)>-1&&(r.label_="captions"),r.menuButton_.controlText(tn(r.label_)),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-subs-caps-button "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-subs-caps-button "+e.prototype.buildWrapperCSSClass.call(this)},n.createItems=function(){var t=[];return this.player().tech_&&this.player().tech_.featuresNativeTextTracks||!this.player().getChild("textTrackSettings")||(t.push(new vo(this.player_,{kind:this.label_})),this.hideThreshold_+=1),t=e.prototype.createItems.call(this,t,yo)},t}(co);_o.prototype.kinds_=["captions","subtitles"],_o.prototype.controlText_="Subtitles",rn.registerComponent("SubsCapsButton",_o);var bo=function(e){function t(t,n){var r,i=n.track,a=t.audioTracks();n.label=i.label||i.language||"Unknown",n.selected=i.enabled,r=e.call(this,t,n)||this,r.track=i,r.addClass("vjs-"+i.kind+"-menu-item");var o=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];r.handleTracksChange.apply(ne(r),t)};return a.addEventListener("change",o),r.on("dispose",function(){a.removeEventListener("change",o)}),r}Q(t,e);var n=t.prototype;return n.createEl=function(t,n,r){var i='<span class="vjs-menu-item-text">'+this.localize(this.options_.label);return"main-desc"===this.options_.track.kind&&(i+='\n <span aria-hidden="true" class="vjs-icon-placeholder"></span>\n <span class="vjs-control-text"> '+this.localize("Descriptions")+"</span>\n "),i+="</span>",e.prototype.createEl.call(this,t,a({innerHTML:i},n),r)},n.handleClick=function(t){var n=this.player_.audioTracks();e.prototype.handleClick.call(this,t);for(var r=0;r<n.length;r++){var i=n[r];i.enabled=i===this.track}},n.handleTracksChange=function(e){this.selected(this.track.enabled)},t}(so);rn.registerComponent("AudioTrackMenuItem",bo);var To=function(e){function t(t,n){return void 0===n&&(n={}),n.tracks=t.audioTracks(),e.call(this,t,n)||this}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-audio-button "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-audio-button "+e.prototype.buildWrapperCSSClass.call(this)},n.createItems=function(e){void 0===e&&(e=[]),this.hideThreshold_=1;for(var t=this.player_.audioTracks(),n=0;n<t.length;n++){var r=t[n];e.push(new bo(this.player_,{track:r,selectable:!0,multiSelectable:!1}))}return e},t}(ao);To.prototype.controlText_="Audio Track",rn.registerComponent("AudioTrackButton",To);var So=function(e){function t(t,n){var r,i=n.rate,a=parseFloat(i,10);return n.label=i,n.selected=1===a,n.selectable=!0,n.multiSelectable=!1,r=e.call(this,t,n)||this,r.label=i,r.rate=a,r.on(t,"ratechange",r.update),r}Q(t,e);var n=t.prototype;return n.handleClick=function(t){e.prototype.handleClick.call(this),this.player().playbackRate(this.rate)},n.update=function(e){this.selected(this.player().playbackRate()===this.rate)},t}(so);So.prototype.contentElType="button",rn.registerComponent("PlaybackRateMenuItem",So);var wo=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.updateVisibility(),r.updateLabel(),r.on(t,"loadstart",r.updateVisibility),r.on(t,"ratechange",r.updateLabel),r}Q(t,e);var n=t.prototype;return n.createEl=function(){var t=e.prototype.createEl.call(this);return this.labelEl_=v("div",{className:"vjs-playback-rate-value",innerHTML:"1x"}),t.appendChild(this.labelEl_),t},n.dispose=function(){this.labelEl_=null,e.prototype.dispose.call(this)},n.buildCSSClass=function(){return"vjs-playback-rate "+e.prototype.buildCSSClass.call(this)},n.buildWrapperCSSClass=function(){return"vjs-playback-rate "+e.prototype.buildWrapperCSSClass.call(this)},n.createMenu=function(){var e=new ro(this.player()),t=this.playbackRates();if(t)for(var n=t.length-1;n>=0;n--)e.addChild(new So(this.player(),{rate:t[n]+"x"}));return e},n.updateARIAAttributes=function(){this.el().setAttribute("aria-valuenow",this.player().playbackRate())},n.handleClick=function(e){for(var t=this.player().playbackRate(),n=this.playbackRates(),r=n[0],i=0;i<n.length;i++)if(n[i]>t){r=n[i];break}this.player().playbackRate(r)},n.playbackRates=function(){return this.options_.playbackRates||this.options_.playerOptions&&this.options_.playerOptions.playbackRates},n.playbackRateSupported=function(){return this.player().tech_&&this.player().tech_.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0},n.updateVisibility=function(e){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")},n.updateLabel=function(e){this.playbackRateSupported()&&(this.labelEl_.innerHTML=this.player().playbackRate()+"x")},t}(io);wo.prototype.controlText_="Playback Rate",rn.registerComponent("PlaybackRateMenuButton",wo);var ko=function(e){function t(){return e.apply(this,arguments)||this}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-spacer "+e.prototype.buildCSSClass.call(this)},n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},t}(rn);rn.registerComponent("Spacer",ko);var Eo=function(e){function t(){return e.apply(this,arguments)||this}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-custom-control-spacer "+e.prototype.buildCSSClass.call(this)},n.createEl=function(){var t=e.prototype.createEl.call(this,{className:this.buildCSSClass()});return t.innerHTML=" ",t},t}(ko);rn.registerComponent("CustomControlSpacer",Eo);var Ao=function(e){function t(){return e.apply(this,arguments)||this}return Q(t,e),t.prototype.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"})},t}(rn);Ao.prototype.options_={children:["playToggle","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","seekToLive","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","fullscreenToggle"]},"exitPictureInPicture"in t&&Ao.prototype.options_.children.splice(Ao.prototype.options_.children.length-1,0,"pictureInPictureToggle"),rn.registerComponent("ControlBar",Ao);var Co=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,r.on(t,"error",r.open),r}Q(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-error-display "+e.prototype.buildCSSClass.call(this)},n.content=function(){var e=this.player().error();return e?this.localize(e.message):""},t}(Fn);Co.prototype.options_=J(Fn.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),rn.registerComponent("ErrorDisplay",Co);var Lo=["#000","Black"],xo=["#00F","Blue"],jo=["#0FF","Cyan"],Oo=["#0F0","Green"],Io=["#F0F","Magenta"],Po=["#F00","Red"],Ro=["#FFF","White"],Do=["#FF0","Yellow"],Mo=["1","Opaque"],Uo=["0.5","Semi-Transparent"],Bo=["0","Transparent"],No={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Lo,Ro,Po,Oo,xo,Do,Io,jo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[Mo,Uo,Bo]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[Ro,Lo,Po,Oo,xo,Do,Io,jo]},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(e){return"1.00"===e?null:Number(e)}},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Transparency",options:[Mo,Uo]},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:[Bo,Uo,Mo]}};No.windowColor.options=No.backgroundColor.options;var Fo=function(t){function n(e,n){var i;return n.temporary=!1,i=t.call(this,e,n)||this,i.updateDisplay=Nt(ne(i),i.updateDisplay),i.fill(),i.hasBeenOpened_=i.hasBeenFilled_=!0,i.endDialog=v("p",{className:"vjs-control-text",textContent:i.localize("End of dialog window.")}),i.el().appendChild(i.endDialog),i.setDefaults(),void 0===n.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()}),r(No,function(e){i.on(i.$(e.selector),"change",i.updateDisplay)}),i.options_.persistTextTrackSettings&&i.restoreSettings(),i}Q(n,t);var a=n.prototype;return a.dispose=function(){this.endDialog=null,t.prototype.dispose.call(this)},a.createElSelect_=function(e,t,n){var r=this;void 0===t&&(t=""),void 0===n&&(n="label");var i=No[e],a=i.id.replace("%s",this.id_),o=[t,a].join(" ").trim();return["<"+n+' id="'+a+'" class="'+("label"===n?"vjs-label":"")+'">',this.localize(i.label),"</"+n+">",'<select aria-labelledby="'+o+'">'].concat(i.options.map(function(e){var t=a+"-"+e[1].replace(/\W+/g,"");return['<option id="'+t+'" value="'+e[0]+'" ','aria-labelledby="'+o+" "+t+'">',r.localize(e[1]),"</option>"].join("")})).concat("</select>").join("")},a.createElFgColor_=function(){var e="captions-text-legend-"+this.id_;return['<fieldset class="vjs-fg-color vjs-track-setting">','<legend id="'+e+'">',this.localize("Text"),"</legend>",this.createElSelect_("color",e),'<span class="vjs-text-opacity vjs-opacity">',this.createElSelect_("textOpacity",e),"</span>","</fieldset>"].join("")},a.createElBgColor_=function(){var e="captions-background-"+this.id_;return['<fieldset class="vjs-bg-color vjs-track-setting">','<legend id="'+e+'">',this.localize("Background"),"</legend>",this.createElSelect_("backgroundColor",e),'<span class="vjs-bg-opacity vjs-opacity">',this.createElSelect_("backgroundOpacity",e),"</span>","</fieldset>"].join("")},a.createElWinColor_=function(){var e="captions-window-"+this.id_;return['<fieldset class="vjs-window-color vjs-track-setting">','<legend id="'+e+'">',this.localize("Window"),"</legend>",this.createElSelect_("windowColor",e),'<span class="vjs-window-opacity vjs-opacity">',this.createElSelect_("windowOpacity",e),"</span>","</fieldset>"].join("")},a.createElColors_=function(){return v("div",{className:"vjs-track-settings-colors",innerHTML:[this.createElFgColor_(),this.createElBgColor_(),this.createElWinColor_()].join("")})},a.createElFont_=function(){return v("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("")})},a.createElControls_=function(){var e=this.localize("restore all settings to the default values");return v("div",{className:"vjs-track-settings-controls",innerHTML:['<button type="button" class="vjs-default-button" title="'+e+'">',this.localize("Reset"),'<span class="vjs-control-text"> '+e+"</span>","</button>",'<button type="button" class="vjs-done-button">'+this.localize("Done")+"</button>"].join("")})},a.content=function(){return[this.createElColors_(),this.createElFont_(),this.createElControls_()]},a.label=function(){return this.localize("Caption Settings Dialog")},a.description=function(){return this.localize("Beginning of dialog window. Escape will cancel and close the window.")},a.buildCSSClass=function(){return t.prototype.buildCSSClass.call(this)+" vjs-text-track-settings"},a.getValues=function(){var e=this;return i(No,function(t,n,r){var i=ot(e.$(n.selector),n.parser);return void 0!==i&&(t[r]=i),t},{})},a.setValues=function(e){var t=this;r(No,function(n,r){st(t.$(n.selector),e[r],n.parser)})},a.setDefaults=function(){var e=this;r(No,function(t){var n=t.hasOwnProperty("default")?t.default:0;e.$(t.selector).selectedIndex=n})},a.restoreSettings=function(){var t;try{t=JSON.parse(e.localStorage.getItem("vjs-text-track-settings"))}catch(e){Tt.warn(e)}t&&this.setValues(t)},a.saveSettings=function(){if(this.options_.persistTextTrackSettings){var t=this.getValues();try{Object.keys(t).length?e.localStorage.setItem("vjs-text-track-settings",JSON.stringify(t)):e.localStorage.removeItem("vjs-text-track-settings")}catch(e){Tt.warn(e)}}},a.updateDisplay=function(){var e=this.player_.getChild("textTrackDisplay");e&&e.updateDisplay()},a.conditionalBlur_=function(){this.previouslyActiveEl_=null;var e=this.player_.controlBar,t=e&&e.subsCapsButton,n=e&&e.captionsButton;t?t.focus():n&&n.focus()},n}(Fn);rn.registerComponent("TextTrackSettings",Fo);var Vo=function(t){function n(n,r){var i,a=r.ResizeObserver||e.ResizeObserver;null===r.ResizeObserver&&(a=!1);var o=J({createEl:!a,reportTouchActivity:!1},r);return i=t.call(this,n,o)||this,i.ResizeObserver=r.ResizeObserver||e.ResizeObserver,i.loadListener_=null,i.resizeObserver_=null,i.debouncedHandler_=Vt(function(){i.resizeHandler()},100,!1,ne(i)),a?(i.resizeObserver_=new i.ResizeObserver(i.debouncedHandler_),i.resizeObserver_.observe(n.el())):(i.loadListener_=function(){if(i.el_&&i.el_.contentWindow){var e=i.debouncedHandler_,t=i.unloadListener_=function(){H(this,"resize",e),H(this,"unload",t),t=null};G(i.el_.contentWindow,"unload",t),G(i.el_.contentWindow,"resize",e)}},i.one("load",i.loadListener_)),i}Q(n,t);var r=n.prototype;return r.createEl=function(){return t.prototype.createEl.call(this,"iframe",{className:"vjs-resize-manager",tabIndex:-1},{"aria-hidden":"true"})},r.resizeHandler=function(){this.player_&&this.player_.trigger&&this.player_.trigger("playerresize")},r.dispose=function(){this.debouncedHandler_&&this.debouncedHandler_.cancel(),this.resizeObserver_&&(this.player_.el()&&this.resizeObserver_.unobserve(this.player_.el()),this.resizeObserver_.disconnect()),this.loadListener_&&this.off("load",this.loadListener_),this.el_&&this.el_.contentWindow&&this.unloadListener_&&this.unloadListener_.call(this.el_.contentWindow),this.ResizeObserver=null,this.resizeObserver=null,this.debouncedHandler_=null,this.loadListener_=null,t.prototype.dispose.call(this)},n}(rn);rn.registerComponent("ResizeManager",Vo);var qo=function(e){function n(n,r){var i,a=J({createEl:!1},r);return i=e.call(this,n,a)||this,i.reset_(),i.on(i.player_,"durationchange",i.handleDurationchange),Tn&&"hidden"in t&&"visibilityState"in t&&i.on(t,"visibilitychange",i.handleVisibilityChange),i}Q(n,e);var r=n.prototype;return r.handleVisibilityChange=function(){this.player_.duration()===1/0&&(t.hidden?this.stopTracking():this.startTracking())},r.isBehind_=function(){if(!this.timeupdateSeen_)return!1;var e=this.liveCurrentTime(),t=this.player_.currentTime(),n=this.seekableIncrement_,r=2*n+.07;return e!==1/0&&e-r>=t},r.trackLive_=function(){this.pastSeekEnd_=this.pastSeekEnd_;var e=this.player_.seekable();if(e&&e.length){var t=this.seekableEnd();t!==this.lastSeekEnd_&&(this.lastSeekEnd_&&(this.seekableIncrement_=Math.abs(t-this.lastSeekEnd_)),this.pastSeekEnd_=0,this.lastSeekEnd_=t,this.trigger("seekableendchange")),this.pastSeekEnd_=this.pastSeekEnd()+.03,this.isBehind_()!==this.behindLiveEdge()&&(this.behindLiveEdge_=this.isBehind_(),this.trigger("liveedgechange"))}},r.handleDurationchange=function(){this.player_.duration()===1/0?this.startTracking():this.stopTracking()},r.startTracking=function(){var e=this;this.isTracking()||(this.timeupdateSeen_||(this.timeupdateSeen_=this.player_.hasStarted()),this.trackingInterval_=this.setInterval(this.trackLive_,30),this.trackLive_(),this.on(this.player_,"play",this.trackLive_),this.on(this.player_,"pause",this.trackLive_),this.timeupdateSeen_||(this.one(this.player_,"play",this.handlePlay),this.handleTimeupdate=function(){e.timeupdateSeen_=!0,e.handleTimeupdate=null},this.one(this.player_,"timeupdate",this.handleTimeupdate)))},r.handlePlay=function(){this.one(this.player_,"timeupdate",this.seekToLiveEdge)},r.reset_=function(){this.pastSeekEnd_=0,this.lastSeekEnd_=null,this.behindLiveEdge_=null,this.timeupdateSeen_=!1,this.clearInterval(this.trackingInterval_),this.trackingInterval_=null,this.seekableIncrement_=12,this.off(this.player_,"play",this.trackLive_),this.off(this.player_,"pause",this.trackLive_),this.off(this.player_,"play",this.handlePlay),this.off(this.player_,"timeupdate",this.seekToLiveEdge),this.handleTimeupdate&&(this.off(this.player_,"timeupdate",this.handleTimeupdate),this.handleTimeupdate=null)},r.stopTracking=function(){this.isTracking()&&this.reset_()},r.seekableEnd=function(){for(var e=this.player_.seekable(),t=[],n=e?e.length:0;n--;)t.push(e.end(n));return t.length?t.sort()[t.length-1]:1/0},r.seekableStart=function(){for(var e=this.player_.seekable(),t=[],n=e?e.length:0;n--;)t.push(e.start(n));return t.length?t.sort()[0]:0},r.liveWindow=function(){var e=this.liveCurrentTime();return e===1/0?1/0:e-this.seekableStart()},r.isLive=function(){return this.isTracking()},r.atLiveEdge=function(){return!this.behindLiveEdge()},r.liveCurrentTime=function(){return this.pastSeekEnd()+this.seekableEnd()},r.pastSeekEnd=function(){return this.pastSeekEnd_},r.behindLiveEdge=function(){return this.behindLiveEdge_},r.isTracking=function(){return"number"==typeof this.trackingInterval_},r.seekToLiveEdge=function(){this.atLiveEdge()||(this.player_.currentTime(this.liveCurrentTime()),this.player_.paused()&&this.player_.play())},r.dispose=function(){this.stopTracking(),e.prototype.dispose.call(this)},n}(rn);rn.registerComponent("LiveTracker",qo);var Go=function(e){var t=e.el();if(t.hasAttribute("src"))return e.triggerSourceset(t.src),!0;var n=e.$$("source"),r=[],i="";if(!n.length)return!1;for(var a=0;a<n.length;a++){var o=n[a].src;o&&-1===r.indexOf(o)&&r.push(o)}return!!r.length&&(1===r.length&&(i=r[0]),e.triggerSourceset(i),!0)},Ho=Object.defineProperty({},"innerHTML",{get:function(){return this.cloneNode(!0).innerHTML},set:function(n){var r=t.createElement(this.nodeName.toLowerCase());r.innerHTML=n;for(var i=t.createDocumentFragment();r.childNodes.length;)i.appendChild(r.childNodes[0]);return this.innerText="",e.Element.prototype.appendChild.call(this,i),this.innerHTML}}),zo=function(e,t){for(var n={},r=0;r<e.length&&!((n=Object.getOwnPropertyDescriptor(e[r],t))&&n.set&&n.get);r++);return n.enumerable=!0,n.configurable=!0,n},Wo=function(t){return zo([t.el(),e.HTMLMediaElement.prototype,e.Element.prototype,Ho],"innerHTML")},$o=function(e){var t=e.el();if(!t.resetSourceWatch_){var n={},r=Wo(e),i=function(n){return function(){for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];var o=n.apply(t,i);return Go(e),o}};["append","appendChild","insertAdjacentHTML"].forEach(function(e){t[e]&&(n[e]=t[e],t[e]=i(n[e]))}),Object.defineProperty(t,"innerHTML",J(r,{set:i(r.set)})),t.resetSourceWatch_=function(){t.resetSourceWatch_=null,Object.keys(n).forEach(function(e){t[e]=n[e]}),Object.defineProperty(t,"innerHTML",r)},e.one("sourceset",t.resetSourceWatch_)}},Yo=Object.defineProperty({},"src",{get:function(){return this.hasAttribute("src")?rr(e.Element.prototype.getAttribute.call(this,"src")):""},set:function(t){return e.Element.prototype.setAttribute.call(this,"src",t),t}}),Ko=function(t){return zo([t.el(),e.HTMLMediaElement.prototype,Yo],"src")},Xo=function(e){if(e.featuresSourceset){var t=e.el();if(!t.resetSourceset_){var n=Ko(e),r=t.setAttribute,i=t.load;Object.defineProperty(t,"src",J(n,{set:function(r){var i=n.set.call(t,r);return e.triggerSourceset(t.src),i}})),t.setAttribute=function(n,i){var a=r.call(t,n,i);return/src/i.test(n)&&e.triggerSourceset(t.src),a},t.load=function(){var n=i.call(t);return Go(e)||(e.triggerSourceset(""),$o(e)),n},t.currentSrc?e.triggerSourceset(t.currentSrc):Go(e)||$o(e),t.resetSourceset_=function(){t.resetSourceset_=null,t.load=i,t.setAttribute=r,Object.defineProperty(t,"src",n),t.resetSourceWatch_&&t.resetSourceWatch_()}}}},Jo=function(n){function r(e,t){var r;r=n.call(this,e,t)||this;var i=e.source,a=!1;if(i&&(r.el_.currentSrc!==i.src||e.tag&&3===e.tag.initNetworkState_)?r.setSource(i):r.handleLateInit_(r.el_),e.enableSourceset&&r.setupSourcesetHandling_(),r.el_.hasChildNodes()){for(var o=r.el_.childNodes,s=o.length,u=[];s--;){var l=o[s];"track"===l.nodeName.toLowerCase()&&(r.featuresNativeTextTracks?(r.remoteTextTrackEls().addTrackElement_(l),r.remoteTextTracks().addTrack(l.track),r.textTracks().addTrack(l.track),a||r.el_.hasAttribute("crossorigin")||!ar(l.src)||(a=!0)):u.push(l))}for(var c=0;c<u.length;c++)r.el_.removeChild(u[c])}return r.proxyNativeTracks_(),r.featuresNativeTextTracks&&a&&Tt.warn("Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.\nThis may prevent text tracks from loading."),r.restoreMetadataTracksInIOSNativePlayer_(),(En||cn||vn)&&!0===e.nativeControlsForTouch&&r.setControls(!0),r.proxyWebkitFullscreen_(),r.triggerReady(),r}Q(r,n);var i=r.prototype;return i.dispose=function(){this.el_&&this.el_.resetSourceset_&&this.el_.resetSourceset_(),r.disposeMediaElement(this.el_),this.options_=null,n.prototype.dispose.call(this)},i.setupSourcesetHandling_=function(){Xo(this)},i.restoreMetadataTracksInIOSNativePlayer_=function(){var e,t=this.textTracks(),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 i=e[r];"disabled"===i.track.mode&&i.track.mode!==i.storedMode&&(i.track.mode=i.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)})},i.overrideNative_=function(e,t){var n=this;if(t===this["featuresNative"+e+"Tracks"]){var r=e.toLowerCase();this[r+"TracksListeners_"]&&Object.keys(this[r+"TracksListeners_"]).forEach(function(e){n.el()[r+"Tracks"].removeEventListener(e,n[r+"TracksListeners_"][e])}),this["featuresNative"+e+"Tracks"]=!t,this[r+"TracksListeners_"]=null,this.proxyNativeTracksForType_(r)}},i.overrideNativeAudioTracks=function(e){this.overrideNative_("Audio",e)},i.overrideNativeVideoTracks=function(e){this.overrideNative_("Video",e)},i.proxyNativeTracksForType_=function(e){var t=this,n=Yi[e],r=this.el()[n.getterName],i=this[n.getterName]();if(this["featuresNative"+n.capitalName+"Tracks"]&&r&&r.addEventListener){var a={change:function(e){i.trigger({type:"change",target:i,currentTarget:i,srcElement:i})},addtrack:function(e){i.addTrack(e.track)},removetrack:function(e){i.removeTrack(e.track)}},o=function(){for(var e=[],t=0;t<i.length;t++){for(var n=!1,a=0;a<r.length;a++)if(r[a]===i[t]){n=!0;break}n||e.push(i[t])}for(;e.length;)i.removeTrack(e.shift())};this[n.getterName+"Listeners_"]=a,Object.keys(a).forEach(function(e){var n=a[e];r.addEventListener(e,n),t.on("dispose",function(t){return r.removeEventListener(e,n)})}),this.on("loadstart",o),this.on("dispose",function(e){return t.off("loadstart",o)})}},i.proxyNativeTracks_=function(){var e=this;Yi.names.forEach(function(t){e.proxyNativeTracksForType_(t)})},i.createEl=function(){var e=this.options_.tag;if(!e||!this.options_.playerElIngest&&!this.movingMediaElementInDOM){if(e){var n=e.cloneNode(!0);e.parentNode&&e.parentNode.insertBefore(n,e),r.disposeMediaElement(e),e=n}else{e=t.createElement("video");var i=this.options_.tag&&k(this.options_.tag),o=J({},i);En&&!0===this.options_.nativeControlsForTouch||delete o.controls,w(e,a(o,{id:this.options_.techId,class:"vjs-tech"}))}e.playerId=this.options_.playerId}void 0!==this.options_.preload&&A(e,"preload",this.options_.preload);for(var s=["loop","muted","playsinline","autoplay","stretch","fluent"],u=0;u<s.length;u++){var l=s[u],c=this.options_[l];void 0!==c&&(c?A(e,l,l):C(e,l),e[l]=c)}return e},i.handleLateInit_=function(e){if(0!==e.networkState&&3!==e.networkState){if(0===e.readyState){var t=!1,n=function(){t=!0};this.on("loadstart",n);var r=function(){t||this.trigger("loadstart")};return this.on("loadedmetadata",r),void this.ready(function(){this.off("loadstart",n),this.off("loadedmetadata",r),t||this.trigger("loadstart")})}var i=["loadstart"];i.push("loadedmetadata"),e.readyState>=2&&i.push("loadeddata"),e.readyState>=3&&i.push("canplay"),e.readyState>=4&&i.push("canplaythrough"),this.ready(function(){i.forEach(function(e){this.trigger(e)},this)})}},i.setCurrentTime=function(e){try{this.el_.currentTime=e}catch(e){Tt(e,"Video is not ready. (Video.js)")}},i.duration=function(){var e=this;if(this.el_.duration===1/0&&pn&&_n&&0===this.el_.currentTime){var t=function t(){e.el_.currentTime>0&&(e.el_.duration===1/0&&e.trigger("durationchange"),e.off("timeupdate",t))};return this.on("timeupdate",t),NaN}return this.el_.duration||NaN},i.width=function(){return this.el_.offsetWidth},i.height=function(){return this.el_.offsetHeight},i.proxyWebkitFullscreen_=function(){var e=this;if("webkitDisplayingFullscreen"in this.el_){var t=function(){this.trigger("fullscreenchange",{isFullscreen:!1})},n=function(){"webkitPresentationMode"in this.el_&&"picture-in-picture"!==this.el_.webkitPresentationMode&&(this.one("webkitendfullscreen",t),this.trigger("fullscreenchange",{isFullscreen:!0}))};this.on("webkitbeginfullscreen",n),this.on("dispose",function(){e.off("webkitbeginfullscreen",n),e.off("webkitendfullscreen",t)})}},i.supportsFullScreen=function(){if("function"==typeof this.el_.webkitEnterFullScreen){var t=e.navigator&&e.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},i.enterFullScreen=function(){var e=this.el_;e.paused&&e.networkState<=e.HAVE_METADATA?(this.el_.play(),this.setTimeout(function(){e.pause(),e.webkitEnterFullScreen()},0)):e.webkitEnterFullScreen()},i.exitFullScreen=function(){this.el_.webkitExitFullScreen()},i.requestPictureInPicture=function(){return this.el_.requestPictureInPicture()},i.src=function(e){if(void 0===e)return this.el_.src;this.setSrc(e)},i.reset=function(){r.resetMediaElement(this.el_)},i.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc},i.setControls=function(e){this.el_.controls=!!e},i.addTextTrack=function(e,t,r){return this.featuresNativeTextTracks?this.el_.addTextTrack(e,t,r):n.prototype.addTextTrack.call(this,e,t,r)},i.createRemoteTextTrack=function(e){if(!this.featuresNativeTextTracks)return n.prototype.createRemoteTextTrack.call(this,e);var r=t.createElement("track");return e.kind&&(r.kind=e.kind),e.label&&(r.label=e.label),(e.language||e.srclang)&&(r.srclang=e.language||e.srclang),e.default&&(r.default=e.default),e.id&&(r.id=e.id),e.src&&(r.src=e.src),r},i.addRemoteTextTrack=function(e,t){var r=n.prototype.addRemoteTextTrack.call(this,e,t);return this.featuresNativeTextTracks&&this.el().appendChild(r),r},i.removeRemoteTextTrack=function(e){if(n.prototype.removeRemoteTextTrack.call(this,e),this.featuresNativeTextTracks)for(var t=this.$$("track"),r=t.length;r--;)e!==t[r]&&e!==t[r].track||this.el().removeChild(t[r])},i.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),e.performance&&"function"==typeof e.performance.now?t.creationTime=e.performance.now():e.performance&&e.performance.timing&&"number"==typeof e.performance.timing.navigationStart&&(t.creationTime=e.Date.now()-e.performance.timing.navigationStart),t},r}(da);if(f()){Jo.TEST_VID=t.createElement("video");var Qo=t.createElement("track");Qo.kind="captions",Qo.srclang="en",Qo.label="English",Jo.TEST_VID.appendChild(Qo)}Jo.isSupported=function(){try{Jo.TEST_VID.volume=.5}catch(e){return!1}return!(!Jo.TEST_VID||!Jo.TEST_VID.canPlayType)},Jo.canPlayType=function(e){return Jo.TEST_VID.canPlayType(e)},Jo.canPlaySource=function(e,t){return Jo.canPlayType(e.type)},Jo.canControlVolume=function(){try{var e=Jo.TEST_VID.volume;return Jo.TEST_VID.volume=e/2+.1,e!==Jo.TEST_VID.volume}catch(e){return!1}},Jo.canMuteVolume=function(){try{var e=Jo.TEST_VID.muted;return Jo.TEST_VID.muted=!e,Jo.TEST_VID.muted?A(Jo.TEST_VID,"muted","muted"):C(Jo.TEST_VID,"muted"),e!==Jo.TEST_VID.muted}catch(e){return!1}},Jo.canControlPlaybackRate=function(){if(pn&&_n&&bn<58)return!1;try{var e=Jo.TEST_VID.playbackRate;return Jo.TEST_VID.playbackRate=e/2+.1,e!==Jo.TEST_VID.playbackRate}catch(e){return!1}},Jo.canOverrideAttributes=function(){try{var e=function(){};Object.defineProperty(t.createElement("video"),"src",{get:e,set:e}),Object.defineProperty(t.createElement("audio"),"src",{get:e,set:e}),Object.defineProperty(t.createElement("video"),"innerHTML",{get:e,set:e}),Object.defineProperty(t.createElement("audio"),"innerHTML",{get:e,set:e})}catch(e){return!1}return!0},Jo.supportsNativeTextTracks=function(){return wn||fn&&_n},Jo.supportsNativeVideoTracks=function(){return!(!Jo.TEST_VID||!Jo.TEST_VID.videoTracks)},Jo.supportsNativeAudioTracks=function(){return!(!Jo.TEST_VID||!Jo.TEST_VID.audioTracks)},Jo.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"],Jo.prototype.featuresVolumeControl=Jo.canControlVolume(),Jo.prototype.featuresMuteControl=Jo.canMuteVolume(),Jo.prototype.featuresPlaybackRate=Jo.canControlPlaybackRate(),Jo.prototype.featuresSourceset=Jo.canOverrideAttributes(),Jo.prototype.movingMediaElementInDOM=!fn,Jo.prototype.featuresFullscreenResize=!0,Jo.prototype.featuresProgressEvents=!0,Jo.prototype.featuresTimeupdateEvents=!0,Jo.prototype.featuresNativeTextTracks=Jo.supportsNativeTextTracks(),Jo.prototype.featuresNativeVideoTracks=Jo.supportsNativeVideoTracks(),Jo.prototype.featuresNativeAudioTracks=Jo.supportsNativeAudioTracks();var Zo=Jo.TEST_VID&&Jo.TEST_VID.constructor.prototype.canPlayType,es=/^application\/(?:x-|vnd\.apple\.)mpegurl/i;Jo.patchCanPlayType=function(){mn>=4&&!gn&&!_n&&(Jo.TEST_VID.constructor.prototype.canPlayType=function(e){return e&&es.test(e)?"maybe":Zo.call(this,e)})},Jo.unpatchCanPlayType=function(){var e=Jo.TEST_VID.constructor.prototype.canPlayType;return Jo.TEST_VID.constructor.prototype.canPlayType=Zo,e},Jo.patchCanPlayType(),Jo.disposeMediaElement=function(e){if(e){for(e.parentNode&&e.parentNode.removeChild(e);e.hasChildNodes();)e.removeChild(e.firstChild);e.removeAttribute("src"),"function"==typeof e.load&&function(){try{e.load()}catch(e){}}()}},Jo.resetMediaElement=function(e){if(e){for(var t=e.querySelectorAll("source"),n=t.length;n--;)e.removeChild(t[n]);e.removeAttribute("src"),"function"==typeof e.load&&function(){try{e.load()}catch(e){}}()}},["muted","defaultMuted","autoplay","stretch","fluent","controls","loop","playsinline"].forEach(function(e){Jo.prototype[e]=function(){return this.el_[e]||this.el_.hasAttribute(e)}}),["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(e){Jo.prototype["set"+tn(e)]=function(t){this.el_[e]=t,t?this.el_.setAttribute(e,e):this.el_.removeAttribute(e)}}),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","defaultPlaybackRate","played","networkState","readyState","videoWidth","videoHeight"].forEach(function(e){Jo.prototype[e]=function(){return this.el_[e]}}),["volume","src","poster","preload","playbackRate","defaultPlaybackRate"].forEach(function(e){Jo.prototype["set"+tn(e)]=function(t){this.el_[e]=t}}),["pause","load","play"].forEach(function(e){Jo.prototype[e]=function(){return this.el_[e]()}}),da.withSourceHandlers(Jo),Jo.nativeSourceHandler={},Jo.nativeSourceHandler.canPlayType=function(e){try{return Jo.TEST_VID.canPlayType(e)}catch(e){return""}},Jo.nativeSourceHandler.canHandleSource=function(e,t){if(e.type)return Jo.nativeSourceHandler.canPlayType(e.type);if(e.src){var n=ir(e.src);return Jo.nativeSourceHandler.canPlayType("video/"+n)}return""},Jo.nativeSourceHandler.handleSource=function(e,t,n){t.setSrc(e.src)},Jo.nativeSourceHandler.dispose=function(){},Jo.registerSourceHandler(Jo.nativeSourceHandler),da.registerTech("Html5",Jo);var ts=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","resize","volumechange","texttrackchange"],ns={canplay:"CanPlay",canplaythrough:"CanPlayThrough",playing:"Playing",seeked:"Seeked"},rs=["tiny","xsmall","small","medium","large","xlarge","huge"],is={};rs.forEach(function(e){var t="x"===e.charAt(0)?"x-"+e.substring(1):e;is[e]="vjs-layout-"+t});var as={tiny:210,xsmall:320,small:425,medium:768,large:1440,xlarge:2560,huge:1/0},os=function(n){function r(e,t,i){var o;if(e.id=e.id||t.id||"vjs_video_"+N(),t=a(r.getTagSettings(e),t),t.initChildren=!1,t.createEl=!1,t.evented=!1,t.reportTouchActivity=!1,!t.language)if("function"==typeof e.closest){var s=e.closest("[lang]");s&&s.getAttribute&&(t.language=s.getAttribute("lang"))}else for(var u=e;u&&1===u.nodeType;){if(k(u).hasOwnProperty("lang")){t.language=u.getAttribute("lang");break}u=u.parentNode}if(o=n.call(this,null,t,i)||this,o.boundDocumentFullscreenChange_=Nt(ne(o),o.documentFullscreenChange_),o.boundFullWindowOnEscKey_=Nt(ne(o),o.fullWindowOnEscKey),o.log=St(o.id_),o.fsApi_=Cn,o.isPosterFromTech_=!1,o.queuedCallbacks_=[],o.isReady_=!1,o.hasStarted_=!1,o.userActive_=!1,!o.options_||!o.options_.techOrder||!o.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(o.tag=e,o.tagAttributes=e&&k(e),o.language(o.options_.language),t.languages){var l={};Object.getOwnPropertyNames(t.languages).forEach(function(e){l[e.toLowerCase()]=t.languages[e]}),o.languages_=l}else o.languages_=r.prototype.options_.languages;o.resetCache_(),o.poster_=t.poster||"",o.controls_=!!t.controls,e.controls=!1,e.removeAttribute("controls"),o.changingSrc_=!1,o.playCallbacks_=[],o.playTerminatedQueue_=[],e.hasAttribute("autoplay")?o.autoplay(!0):o.autoplay(o.options_.autoplay),t.plugins&&Object.keys(t.plugins).forEach(function(e){if("function"!=typeof o[e])throw new Error('plugin "'+e+'" does not exist')}),o.scrubbing_=!1,o.el_=o.createEl(),K(ne(o),{eventBusKey:"el_"}),o.fluid_&&o.on("playerreset",o.updateStyleEl_);var c=J(o.options_);t.plugins&&Object.keys(t.plugins).forEach(function(e){o[e](t.plugins[e])}),o.options_.playerOptions=c,o.middleware_=[],o.initChildren(),o.isAudio("audio"===e.nodeName.toLowerCase()),o.controls()?o.addClass("vjs-controls-enabled"):o.addClass("vjs-controls-disabled"),o.el_.setAttribute("role","region"),o.isAudio()?o.el_.setAttribute("aria-label",o.localize("Audio Player")):o.el_.setAttribute("aria-label",o.localize("Video Player")),o.isAudio()&&o.addClass("vjs-audio"),o.flexNotSupported_()&&o.addClass("vjs-no-flex"),En&&o.addClass("vjs-touch-enabled"),fn||o.addClass("vjs-workinghover"),r.players[o.id_]=ne(o);var d=yt.split(".")[0];return o.addClass("vjs-v"+d),o.userActive(!0),o.reportUserActivity(),o.one("play",o.listenForUserActivity_),o.on("stageclick",o.handleStageClick_),o.on("keydown",o.handleKeyDown),o.breakpoints(o.options_.breakpoints),o.responsive(o.options_.responsive),o}Q(r,n);var i=r.prototype;return i.dispose=function(){var e=this;this.trigger("dispose"),this.off("dispose"),H(t,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),H(t,"keydown",this.boundFullWindowOnEscKey_),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),r.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.isPosterFromTech_=!1,this.poster_=""),this.playerElIngest_&&(this.playerElIngest_=null),this.tag&&(this.tag=null),Xe(this),Xi.names.forEach(function(t){var n=Xi[t],r=e[n.getterName]();r&&r.off&&r.off()}),n.prototype.dispose.call(this)},i.createEl=function(){var r,i=this.tag,a=this.playerElIngest_=i.parentNode&&i.parentNode.hasAttribute&&i.parentNode.hasAttribute("data-vjs-player"),o="video-js"===this.tag.tagName.toLowerCase();a?r=this.el_=i.parentNode:o||(r=this.el_=n.prototype.createEl.call(this,"div"));var s=k(i);if(o){for(r=this.el_=i,i=this.tag=t.createElement("video");r.children.length;)i.appendChild(r.firstChild);_(r,"video-js")||b(r,"video-js"),r.appendChild(i),a=this.playerElIngest_=r,Object.keys(r).forEach(function(e){i[e]=r[e]})}if(i.setAttribute("tabindex","-1"),s.tabindex="-1",(Tn||_n&&kn)&&(i.setAttribute("role","application"),s.role="application"),i.removeAttribute("width"),i.removeAttribute("height"),"width"in s&&delete s.width,"height"in s&&delete s.height,Object.getOwnPropertyNames(s).forEach(function(e){o&&"class"===e||r.setAttribute(e,s[e]),o&&i.setAttribute(e,s[e])}),i.playerId=i.id,i.id+="_html5_api",i.className="vjs-tech",i.player=r.player=this,this.addClass("vjs-paused"),!0!==e.VIDEOJS_NO_DYNAMIC_STYLE){this.styleEl_=Mt("vjs-styles-dimensions");var u=Et(".vjs-styles-defaults"),l=Et("head");l.insertBefore(this.styleEl_,u?u.nextSibling:l.firstChild)}this.fill_=!1,this.fluid_=!1,this.width(this.options_.width),this.height(this.options_.height),this.fill(this.options_.fill),this.fluid(this.options_.fluid),this.aspectRatio(this.options_.aspectRatio);for(var c=i.getElementsByTagName("a"),d=0;d<c.length;d++){var f=c.item(d);b(f,"vjs-hidden"),f.setAttribute("hidden","hidden")}return i.initNetworkState_=i.networkState,i.parentNode&&!a&&i.parentNode.insertBefore(r,i),y(i,r),this.children_.unshift(i),this.el_.setAttribute("lang",this.language_),this.el_=r,r},i.width=function(e){return this.dimension("width",e)},i.height=function(e){return this.dimension("height",e)},i.dimension=function(e,t){var n=e+"_";if(void 0===t)return this[n]||0;if(""===t)return this[n]=void 0,void this.updateStyleEl_();var r=parseFloat(t);if(isNaN(r))return void Tt.error('Improper value "'+t+'" supplied for for '+e);this[n]=r,this.updateStyleEl_()},i.fluid=function(e){if(void 0===e)return!!this.fluid_;this.fluid_=!!e,Ht(this)&&this.off("playerreset",this.updateStyleEl_),e?(this.addClass("vjs-fluid"),this.fill(!1),zt(function(){this.on("playerreset",this.updateStyleEl_)})):this.removeClass("vjs-fluid"),this.updateStyleEl_()},i.fill=function(e){if(void 0===e)return!!this.fill_;this.fill_=!!e,e?(this.addClass("vjs-fill"),this.fluid(!1)):this.removeClass("vjs-fill")},i.aspectRatio=function(e){if(void 0===e)return this.aspectRatio_;if(!/^\d+\:\d+$/.test(e))throw new Error("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.aspectRatio_=e,this.fluid(!0),this.updateStyleEl_()},i.updateStyleEl_=function(){if(!0===e.VIDEOJS_NO_DYNAMIC_STYLE){var t="number"==typeof this.width_?this.width_:this.options_.width,n="number"==typeof this.height_?this.height_:this.options_.height,r=this.tech_&&this.tech_.el();return void(r&&(t>=0&&(r.width=t),n>=0&&(r.height=n)))}var i,a,o,s;o=void 0!==this.aspectRatio_&&"auto"!==this.aspectRatio_?this.aspectRatio_:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9";var u=o.split(":"),l=u[1]/u[0];i=void 0!==this.width_?this.width_:void 0!==this.height_?this.height_/l:this.videoWidth()||300,a=void 0!==this.height_?this.height_:i*l,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),Ut(this.styleEl_,"\n ."+s+" {\n width: "+i+"px;\n height: "+a+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*l+"%;\n }\n ")},i.loadTech_=function(e,t){var n=this;this.tech_&&this.unloadTech_();var r=tn(e),i=e.charAt(0).toLowerCase()+e.slice(1);"Html5"!==r&&this.tag&&(da.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=r,this.isReady_=!1;var o="string"!=typeof this.autoplay()&&this.autoplay(),s={source:t,autoplay:o,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+i+"_api",playsinline:this.options_.playsinline,stretch:this.options_.stretch,fluent:this.options_.fluent,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"],canOverridePoster:!!this.options_.techCanOverridePoster,enableSourceset:this.options_.enableSourceset,Promise:this.options_.Promise};Xi.names.forEach(function(e){var t=Xi[e];s[t.getterName]=n[t.privateName]}),a(s,this.options_[r]),a(s,this.options_[i]),a(s,this.options_[e.toLowerCase()]),this.tag&&(s.tag=this.tag),t&&t.src===this.cache_.src&&this.cache_.currentTime>0&&(s.startTime=this.cache_.currentTime);var u=da.getTech(e);if(!u)throw new Error("No Tech named '"+r+"' exists! '"+r+"' should be registered using videojs.registerTech()'");this.tech_=new u(s),this.tech_.ready(Nt(this,this.handleTechReady_),!0),Un.jsonToTextTracks(this.textTracksJson_||[],this.tech_),ts.forEach(function(e){n.on(n.tech_,e,n["handleTech"+tn(e)+"_"])}),Object.keys(ns).forEach(function(e){n.on(n.tech_,e,function(t){if(0===n.tech_.playbackRate()&&n.tech_.seeking())return void n.queuedCallbacks_.push({callback:n["handleTech"+ns[e]+"_"].bind(n),event:t});n["handleTech"+ns[e]+"_"](t)})}),this.on(this.tech_,"loadstart",this.handleTechLoadStart_),this.on(this.tech_,"sourceset",this.handleTechSourceset_),this.on(this.tech_,"waiting",this.handleTechWaiting_),this.on(this.tech_,"ended",this.handleTechEnded_),this.on(this.tech_,"seeking",this.handleTechSeeking_),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_,"fullscreentoggle",this.handleTechFullscreenToggle_),this.on(this.tech_,"enterpictureinpicture",this.handleTechEnterPictureInPicture_),this.on(this.tech_,"leavepictureinpicture",this.handleTechLeavePictureInPicture_),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.on(this.tech_,"ratechange",this.handleTechRateChange_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode===this.el()||"Html5"===r&&this.tag||y(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)},i.unloadTech_=function(){var e=this;Xi.names.forEach(function(t){var n=Xi[t];e[n.privateName]=e[n.getterName]()}),this.textTracksJson_=Un.textTracksToJson(this.tech_),this.isReady_=!1,this.tech_.dispose(),this.tech_=!1,this.isPosterFromTech_&&(this.poster_="",this.trigger("posterchange")),this.isPosterFromTech_=!1},i.tech=function(e){return void 0===e&&Tt.warn("Using the tech directly can be dangerous. I hope you know what you're doing.\nSee https://github.com/videojs/video.js/issues/2617 for more info.\n"),this.tech_},i.addTechControlsListeners_=function(){this.removeTechControlsListeners_(),this.on(this.tech_,"mouseup",this.handleTechClick_),this.on(this.tech_,"dblclick",this.handleTechDoubleClick_),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_)},i.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_,"mouseup",this.handleTechClick_),this.off(this.tech_,"dblclick",this.handleTechDoubleClick_)},i.handleTechReady_=function(){this.triggerReady(),this.cache_.volume&&this.techCall_("setVolume",this.cache_.volume),this.handleTechPosterChange_(),this.handleTechDurationChange_()},i.handleTechLoadStart_=function(){this.removeClass("vjs-ended"),this.seekingTimer&&(clearTimeout(this.seekingTimer),this.seekingTimer=0),this.removeClass("vjs-seeking"),this.error(null),this.handleTechDurationChange_(),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay")),this.manualAutoplay_(this.autoplay())},i.manualAutoplay_=function(e){var t=this;if(this.tech_&&"string"==typeof e){var n,r=function(){var e=t.muted();t.muted(!0);var n=function(){t.muted(e)};t.playTerminatedQueue_.push(n);var r=t.play();if(ce(r))return r.catch(n)};if("any"===e&&!0!==this.muted()?(n=this.play(),ce(n)&&(n=n.catch(r))):n="muted"===e&&!0!==this.muted()?r():this.play(),ce(n))return n.then(function(){t.trigger({type:"autoplay-success",autoplay:e})}).catch(function(n){t.trigger({type:"autoplay-failure",autoplay:e})})}},i.updateSourceCaches_=function(e){void 0===e&&(e="");var t=e,n="";"string"!=typeof t&&(t=e.src,n=e.type),this.cache_.source=this.cache_.source||{},this.cache_.sources=this.cache_.sources||[],t&&!n&&(n=ba(this,t)),this.cache_.source=J({},e,{src:t,type:n});for(var r=this.cache_.sources.filter(function(e){return e.src&&e.src===t}),i=[],a=this.$$("source"),o=[],s=0;s<a.length;s++){var u=k(a[s]);i.push(u),u.src&&u.src===t&&o.push(u.src)}o.length&&!r.length?this.cache_.sources=i:r.length||(this.cache_.sources=[this.cache_.source]),this.cache_.src=t},i.handleTechSourceset_=function(e){var t=this;if(!this.changingSrc_){var n=function(e){return t.updateSourceCaches_(e)},r=this.currentSource().src,i=e.src;r&&!/^blob:/.test(r)&&/^blob:/.test(i)&&(!this.lastSource_||this.lastSource_.tech!==i&&this.lastSource_.player!==r)&&(n=function(){}),n(i),e.src||this.tech_.any(["sourceset","loadstart"],function(e){if("sourceset"!==e.type){var n=t.techGet("currentSrc");t.lastSource_.tech=n,t.updateSourceCaches_(n)}})}this.lastSource_={player:this.currentSource().src,tech:e.src},this.trigger({src:e.src,type:"sourceset"})},i.hasStarted=function(e){if(void 0===e)return this.hasStarted_;e!==this.hasStarted_&&(this.hasStarted_=e,this.hasStarted_?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started"))},i.handleTechPlay_=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},i.handleTechRateChange_=function(){this.tech_.playbackRate()>0&&0===this.cache_.lastPlaybackRate&&(this.queuedCallbacks_.forEach(function(e){return e.callback(e.event)}),this.queuedCallbacks_=[]),this.cache_.lastPlaybackRate=this.tech_.playbackRate(),this.trigger("ratechange")},i.waitingTimer=0,i.seekingTimer=0,i.handleTechWaiting_=function(){var e=this;this.waitingTimer&&clearTimeout(this.waitingTimer),this.waitingTimer=setTimeout(function(){e.addClass("vjs-waiting")},1e3),this.trigger("waiting");var t=this.currentTime(),n=function n(){e.waitingTimer&&(clearTimeout(e.waitingTimer),e.waitingTimer=0),t!==e.currentTime()&&(e.removeClass("vjs-waiting"),e.off("timeupdate",n))};this.on("timeupdate",n)},i.handleTechCanPlay_=function(){this.waitingTimer&&(clearTimeout(this.waitingTimer),this.waitingTimer=0),this.removeClass("vjs-waiting"),this.trigger("canplay")},i.handleTechCanPlayThrough_=function(){this.waitingTimer&&(clearTimeout(this.waitingTimer),this.waitingTimer=0),this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},i.handleTechPlaying_=function(){this.waitingTimer&&(clearTimeout(this.waitingTimer),this.waitingTimer=0),this.removeClass("vjs-waiting"),this.trigger("playing")},i.handleTechSeeking_=function(){var e=this;this.seekingTimer&&clearTimeout(this.seekingTimer),this.seekingTimer=setTimeout(function(){e.addClass("vjs-seeking")},1e3),this.trigger("seeking")},i.handleTechSeeked_=function(){this.seekingTimer&&(clearTimeout(this.seekingTimer),this.seekingTimer=0),this.removeClass("vjs-seeking"),this.removeClass("vjs-ended"),this.trigger("seeked")},i.handleTechFirstPlay_=function(){this.options_.starttime&&(Tt.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")},i.handleTechPause_=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},i.handleTechEnded_=function(){this.addClass("vjs-ended"),this.options_.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},i.handleTechDurationChange_=function(){this.duration(this.techGet_("duration"))},i.handleTechClick_=function(e){B(e)&&this.controls_&&this.paused()},i.handleTechDoubleClick_=function(e){this.controls_&&(Array.prototype.some.call(this.$$(".vjs-control-bar, .vjs-modal-dialog"),function(t){return t.contains(e.target)})||void 0!==this.options_&&void 0!==this.options_.userActions&&void 0!==this.options_.userActions.doubleClick&&!1===this.options_.userActions.doubleClick||(void 0!==this.options_&&void 0!==this.options_.userActions&&"function"==typeof this.options_.userActions.doubleClick?this.options_.userActions.doubleClick.call(this,e):this.isFullscreen()?this.exitFullscreen():this.requestFullscreen()))},i.handleTechTap_=function(){this.userActive(!this.userActive())},i.handleTechTouchStart_=function(){this.userWasActive=this.userActive()},i.handleTechTouchMove_=function(){this.userWasActive&&this.reportUserActivity()},i.handleTechTouchEnd_=function(e){e.preventDefault()},i.handleStageClick_=function(){this.reportUserActivity()},i.toggleFullscreenClass_=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},i.documentFullscreenChange_=function(e){var n=this.el(),r=t[this.fsApi_.fullscreenElement]===n;!r&&n.matches?r=n.matches(":"+this.fsApi_.fullscreen):!r&&n.msMatchesSelector&&(r=n.msMatchesSelector(":"+this.fsApi_.fullscreen)),this.isFullscreen(r),!1===this.isFullscreen()&&H(t,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),this.fsApi_.prefixed&&this.trigger("fullscreenchange")},i.handleTechFullscreenChange_=function(e,t){t&&this.isFullscreen(t.isFullscreen),this.trigger("fullscreenchange")},i.handleTechFullscreenToggle_=function(e,t){this.isFullscreen()?this.exitFullscreen():this.requestFullscreen()},i.togglePictureInPictureClass_=function(){this.isInPictureInPicture()?this.addClass("vjs-picture-in-picture"):this.removeClass("vjs-picture-in-picture")},i.handleTechEnterPictureInPicture_=function(e){this.isInPictureInPicture(!0)},i.handleTechLeavePictureInPicture_=function(e){this.isInPictureInPicture(!1)},i.handleTechError_=function(){var e=this.tech_.error();this.error(e)},i.handleTechTextData_=function(){var e=null;arguments.length>1&&(e=arguments[1]),this.trigger("textdata",e)},i.getCache=function(){return this.cache_},i.resetCache_=function(){this.cache_={currentTime:0,inactivityTimeout:this.options_.inactivityTimeout,duration:NaN,lastVolume:1,lastPlaybackRate:this.defaultPlaybackRate(),media:null,src:"",source:{},sources:[],volume:1}},i.techCall_=function(e,t){this.ready(function(){if(e in va)return We(this.middleware_,this.tech_,e,t);if(e in ga)return $e(this.middleware_,this.tech_,e,t);try{this.tech_&&this.tech_[e](t)}catch(e){throw Tt(e),e}},!0)},i.techGet_=function(e){if(this.tech_&&this.tech_.isReady_){if(e in ma)return ze(this.middleware_,this.tech_,e);if(e in ga)return $e(this.middleware_,this.tech_,e);try{return this.tech_[e]()}catch(t){if(void 0===this.tech_[e])throw Tt("Video.js: "+e+" method not defined for "+this.techName_+" playback technology.",t),t;if("TypeError"===t.name)throw Tt("Video.js: "+e+" unavailable on "+this.techName_+" playback technology element.",t),this.tech_.isReady_=!1,t;throw Tt(t),t}}},i.play=function(){var t=this,n=this.options_.Promise||e.Promise;return n?new n(function(e){t.play_(e)}):this.play_()},i.play_=function(e){var t=this;void 0===e&&(e=de),this.playCallbacks_.push(e);var n=Boolean(!this.changingSrc_&&(this.src()||this.currentSrc()));if(this.waitToPlay_&&(this.off(["ready","loadstart"],this.waitToPlay_),this.waitToPlay_=null),!this.isReady_||!n)return this.waitToPlay_=function(e){t.play_()},this.one(["ready","loadstart"],this.waitToPlay_),void(n||!wn&&!fn||this.load());var r=this.techGet_("play");null===r?this.runPlayTerminatedQueue_():this.runPlayCallbacks_(r)},i.runPlayTerminatedQueue_=function(){var e=this.playTerminatedQueue_.slice(0);this.playTerminatedQueue_=[],e.forEach(function(e){e()})},i.runPlayCallbacks_=function(e){var t=this.playCallbacks_.slice(0);this.playCallbacks_=[],this.playTerminatedQueue_=[],t.forEach(function(t){t(e)})},i.pause=function(){this.techCall_("pause")},i.paused=function(){return!1!==this.techGet_("paused")},i.played=function(){return this.techGet_("played")||oe(0,0)},i.scrubbing=function(e){if(void 0===e)return this.scrubbing_;this.scrubbing_=!!e,e?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing")},i.currentTime=function(e){return void 0!==e?(e<0&&(e=0),void this.techCall_("setCurrentTime",e)):(this.cache_.currentTime=this.techGet_("currentTime")||0,this.cache_.currentTime)},i.duration=function(e){if(void 0===e)return void 0!==this.cache_.duration?this.cache_.duration:NaN;e=parseFloat(e),e<0&&(e=1/0),e!==this.cache_.duration&&(this.cache_.duration=e,e===1/0?(this.addClass("vjs-live"),this.options_.liveui&&this.player_.liveTracker&&this.addClass("vjs-liveui")):(this.removeClass("vjs-live"),this.removeClass("vjs-liveui")),isNaN(e)||this.trigger("durationchange"))},i.remainingTime=function(){return this.duration()-this.currentTime()},i.remainingTimeDisplay=function(){return Math.floor(this.duration())-Math.floor(this.currentTime())},i.buffered=function(){var e=this.techGet_("buffered");return e&&e.length||(e=oe(0,0)),e},i.bufferedPercent=function(){return se(this.buffered(),this.duration())},i.bufferedEnd=function(){var e=this.buffered(),t=this.duration(),n=e.end(e.length-1);return n>t&&(n=t),n},i.volume=function(e){var t;return void 0!==e?(t=Math.max(0,Math.min(1,parseFloat(e))),this.cache_.volume=t,this.techCall_("setVolume",t),void(t>0&&this.lastVolume_(t))):(t=parseFloat(this.techGet_("volume")),isNaN(t)?1:t)},i.muted=function(e){return void 0!==e?void this.techCall_("setMuted",e):this.techGet_("muted")||!1},i.defaultMuted=function(e){return void 0!==e?this.techCall_("setDefaultMuted",e):this.techGet_("defaultMuted")||!1},i.lastVolume_=function(e){return void 0!==e&&0!==e?void(this.cache_.lastVolume=e):this.cache_.lastVolume},i.supportsFullScreen=function(){return this.techGet_("supportsFullScreen")||!1},i.isFullscreen=function(e){return void 0!==e?(this.isFullscreen_=!!e,void this.toggleFullscreenClass_()):!!this.isFullscreen_},i.requestFullscreen=function(e){var n;this.isFullscreen(!0),this.fsApi_.requestFullscreen?(G(t,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),this.fsApi_.prefixed||(n=this.options_.fullscreen&&this.options_.fullscreen.options||{},void 0!==e&&(n=e)),de(this.el_[this.fsApi_.requestFullscreen](n))):this.tech_.supportsFullScreen()?this.techCall_("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange"))},i.exitFullscreen=function(){this.isFullscreen(!1),this.fsApi_.requestFullscreen?(t.fullscreenElement||t.webkitFullscreenElement||t.mozFullScreenElement||t.msFullscreenElement)&&de(t[this.fsApi_.exitFullscreen]()):this.tech_.supportsFullScreen()?this.techCall_("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange"))},i.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=t.documentElement.style.overflow,G(t,"keydown",this.boundFullWindowOnEscKey_),t.documentElement.style.overflow="hidden",b(t.body,"vjs-full-window"),this.trigger("enterFullWindow")},i.fullWindowOnEscKey=function(e){Bn.isEventKey(e,"Esc")&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},i.exitFullWindow=function(){this.isFullWindow=!1,H(t,"keydown",this.boundFullWindowOnEscKey_),t.documentElement.style.overflow=this.docOrigOverflow,T(t.body,"vjs-full-window"),this.trigger("exitFullWindow")},i.isInPictureInPicture=function(e){return void 0!==e?(this.isInPictureInPicture_=!!e,void this.togglePictureInPictureClass_()):!!this.isInPictureInPicture_},i.requestPictureInPicture=function(){if("pictureInPictureEnabled"in t)return this.techGet_("requestPictureInPicture")},i.exitPictureInPicture=function(){if("pictureInPictureEnabled"in t)return t.exitPictureInPicture()},i.handleKeyDown=function(e){var t=this.options_.userActions;t&&t.hotkeys&&(function(e){var t=e.tagName.toLowerCase();if(e.isContentEditable)return!0;var n=["button","checkbox","hidden","radio","reset","submit"];return"input"===t?-1===n.indexOf(e.type):-1!==["textarea"].indexOf(t)}(this.el_.ownerDocument.activeElement)||("function"==typeof t.hotkeys?t.hotkeys.call(this,e):this.handleHotkeys(e)))},i.handleHotkeys=function(e){var n=this.options_.userActions?this.options_.userActions.hotkeys:{},r=n.fullscreenKey,i=void 0===r?function(e){return Bn.isEventKey(e,"f")}:r,a=n.muteKey,o=void 0===a?function(e){return Bn.isEventKey(e,"m")}:a,s=n.playPauseKey,u=void 0===s?function(e){return Bn.isEventKey(e,"k")||Bn.isEventKey(e,"Space")}:s;if(i.call(this,e)){e.preventDefault(),e.stopPropagation();var l=rn.getComponent("FullscreenToggle");!1!==t[this.fsApi_.fullscreenEnabled]&&l.prototype.handleClick.call(this,e)}else if(o.call(this,e)){e.preventDefault(),e.stopPropagation();var c=rn.getComponent("MuteToggle");c.prototype.handleClick.call(this,e)}else if(u.call(this,e)){e.preventDefault(),e.stopPropagation();var d=rn.getComponent("PlayToggle");d.prototype.handleClick.call(this,e)}},i.canPlayType=function(e){for(var t,n=0,r=this.options_.techOrder;n<r.length;n++){var i=r[n],a=da.getTech(i);if(a||(a=rn.getComponent(i)),a){if(a.isSupported()&&(t=a.canPlayType(e)))return t}else Tt.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.')}return""},i.selectSource=function(e){var t=this,n=this.options_.techOrder.map(function(e){return[e,da.getTech(e)]}).filter(function(e){var t=e[0],n=e[1];return n?n.isSupported():(Tt.error('The "'+t+'" tech is undefined. Skipped browser support check for that tech.'),!1)}),r=function(e,t,n){var r;return e.some(function(e){return t.some(function(t){if(r=n(e,t))return!0})}),r},i=function(e,n){var r=e[0];if(e[1].canPlaySource(n,t.options_[r.toLowerCase()]))return{source:n,tech:r}};return(this.options_.sourceOrder?r(e,n,function(e){return function(t,n){return e(n,t)}}(i)):r(n,e,i))||!1},i.src=function(e){var t=this;if(void 0===e)return this.cache_.src||"";var n=Ta(e);if(!n.length)return void this.setTimeout(function(){this.error({code:4,message:this.localize(this.options_.notSupportedMessage)})},0);this.changingSrc_=!0,this.cache_.sources=n,this.updateSourceCaches_(n[0]),Ge(this,n[0],function(e,r){if(t.middleware_=r,t.cache_.sources=n,t.updateSourceCaches_(e),t.src_(e))return n.length>1?t.src(n.slice(1)):(t.changingSrc_=!1,t.setTimeout(function(){this.error({code:4,message:this.localize(this.options_.notSupportedMessage)})},0),void t.triggerReady());He(r,t.tech_)})},i.src_=function(e){var t=this,n=this.selectSource([e]);return!n||(nn(n.tech,this.techName_)?(this.ready(function(){this.tech_.constructor.prototype.hasOwnProperty("setSource")?this.techCall_("setSource",e):this.techCall_("src",e.src),this.changingSrc_=!1},!0),!1):(this.changingSrc_=!0,this.loadTech_(n.tech,n.source),this.tech_.ready(function(){t.changingSrc_=!1}),!1))},i.load=function(){this.techCall_("load")},i.reset=function(){var t=this,n=this.options_.Promise||e.Promise;this.paused()||!n?this.doReset_():de(this.play().then(function(){return t.doReset_()}))},i.doReset_=function(){this.tech_&&this.tech_.clearTracks("text"),this.resetCache_(),this.poster(""),this.loadTech_(this.options_.techOrder[0],null),this.techCall_("reset"),this.resetControlBarUI_(),Ht(this)&&this.trigger("playerreset")},i.resetControlBarUI_=function(){this.resetProgressBar_(),this.resetPlaybackRate_(),this.resetVolumeBar_()},i.resetProgressBar_=function(){this.currentTime(0);var e=this.controlBar,t=e.durationDisplay,n=e.remainingTimeDisplay;t&&t.updateContent(),n&&n.updateContent()},i.resetPlaybackRate_=function(){this.playbackRate(this.defaultPlaybackRate()),this.handleTechRateChange_()},i.resetVolumeBar_=function(){this.volume(1),this.trigger("volumechange")},i.currentSources=function(){var e=this.currentSource(),t=[];return 0!==Object.keys(e).length&&t.push(e),this.cache_.sources||t},i.currentSource=function(){return this.cache_.source||{}},i.currentSrc=function(){return this.currentSource()&&this.currentSource().src||""},i.currentType=function(){return this.currentSource()&&this.currentSource().type||""},i.preload=function(e){return void 0!==e?(this.techCall_("setPreload",e),void(this.options_.preload=e)):this.techGet_("preload")},i.autoplay=function(e){if(void 0===e)return this.options_.autoplay||!1;var t;"string"==typeof e&&/(any|play|muted)/.test(e)?(this.options_.autoplay=e,this.manualAutoplay_(e),t=!1):this.options_.autoplay=!!e,t=void 0===t?this.options_.autoplay:t,this.tech_&&this.techCall_("setAutoplay",t)},i.playsinline=function(e){return void 0!==e?(this.techCall_("setPlaysinline",e),this.options_.playsinline=e,this):this.techGet_("playsinline")},i.loop=function(e){return void 0!==e?(this.techCall_("setLoop",e),void(this.options_.loop=e)):this.techGet_("loop")},i.stretch=function(e){return void 0!==e?(this.techCall_("setStretch",e),void(this.options_.stretch=e)):this.techGet_("stretch")},i.fluent=function(e){return void 0!=e?(this.techCall_("setFluent",e),this.options_.fluent=e,this):this.techGet_("fluent")},i.poster=function(e){if(void 0===e)return this.poster_;e||(e=""),e!==this.poster_&&(this.poster_=e,this.techCall_("setPoster",e),this.isPosterFromTech_=!1,this.trigger("posterchange"))},i.handleTechPosterChange_=function(){if((!this.poster_||this.options_.techCanOverridePoster)&&this.tech_&&this.tech_.poster){var e=this.tech_.poster()||"";e!==this.poster_&&(this.poster_=e,this.isPosterFromTech_=!0,this.trigger("posterchange"))}},i.controls=function(e){if(void 0===e)return!!this.controls_;e=!!e,this.controls_!==e&&(this.controls_=e,this.usingNativeControls()&&this.techCall_("setControls",e),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_()))},i.usingNativeControls=function(e){if(void 0===e)return!!this.usingNativeControls_;e=!!e,this.usingNativeControls_!==e&&(this.usingNativeControls_=e,this.usingNativeControls_?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols")))},i.error=function(e){if(void 0===e)return this.error_||null;if(this.options_.suppressNotSupportedError&&e&&e.message&&e.message===this.localize(this.options_.notSupportedMessage)){var t=function(){this.error(e)};return this.options_.suppressNotSupportedError=!1,this.any(["click","touchstart"],t),void this.one("loadstart",function(){this.off(["click","touchstart"],t)})}if(null===e)return this.error_=e,this.removeClass("vjs-error"),void(this.errorDisplay&&this.errorDisplay.close());this.error_=new ue(e),this.addClass("vjs-error"),Tt.error("(CODE:"+this.error_.code+" "+ue.errorTypes[this.error_.code]+")",this.error_.message,this.error_),this.trigger("error")},i.reportUserActivity=function(e){this.userActivity_=!0},i.userActive=function(e){if(void 0===e)return this.userActive_;if((e=!!e)!==this.userActive_){if(this.userActive_=e,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(e){e.stopPropagation(),e.preventDefault()}),this.userActivity_=!1,this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive")}},i.listenForUserActivity_=function(){var e,t,n,r=Nt(this,this.reportUserActivity),i=function(e){e.screenX===t&&e.screenY===n||(t=e.screenX,n=e.screenY,r())},a=function(){r(),this.clearInterval(e),e=this.setInterval(r,250)},o=function(t){r(),this.clearInterval(e)};this.on("mousedown",a),this.on("mousemove",i),this.on("mouseup",o);var s=this.getChild("controlBar");!s||fn||pn||(s.on("mouseenter",function(e){this.player().cache_.inactivityTimeout=this.player().options_.inactivityTimeout,this.player().options_.inactivityTimeout=0}),s.on("mouseleave",function(e){this.player().options_.inactivityTimeout=this.player().cache_.inactivityTimeout})),this.on("keydown",r),this.on("keyup",r);var u;this.setInterval(function(){if(this.userActivity_){this.userActivity_=!1,this.userActive(!0),this.clearTimeout(u);var e=this.options_.inactivityTimeout;e<=0||(u=this.setTimeout(function(){this.userActivity_||this.userActive(!1)},e))}},250)},i.playbackRate=function(e){return void 0!==e?void this.techCall_("setPlaybackRate",e):this.tech_&&this.tech_.featuresPlaybackRate?this.cache_.lastPlaybackRate||this.techGet_("playbackRate"):1},i.defaultPlaybackRate=function(e){return void 0!==e?this.techCall_("setDefaultPlaybackRate",e):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("defaultPlaybackRate"):1},i.isAudio=function(e){return void 0!==e?void(this.isAudio_=!!e):!!this.isAudio_},i.addTextTrack=function(e,t,n){if(this.tech_)return this.tech_.addTextTrack(e,t,n)},i.addRemoteTextTrack=function(e,t){if(this.tech_)return this.tech_.addRemoteTextTrack(e,t)},i.removeRemoteTextTrack=function(e){void 0===e&&(e={});var t=e,n=t.track;if(n||(n=e),this.tech_)return this.tech_.removeRemoteTextTrack(n)},i.getVideoPlaybackQuality=function(){return this.techGet_("getVideoPlaybackQuality")},i.videoWidth=function(){return this.tech_&&this.tech_.videoWidth&&this.tech_.videoWidth()||0},i.videoHeight=function(){return this.tech_&&this.tech_.videoHeight&&this.tech_.videoHeight()||0},i.language=function(e){if(void 0===e)return this.language_;this.language_=String(e).toLowerCase()},i.languages=function(){return J(r.prototype.options_.languages,this.languages_)},i.toJSON=function(){var e=J(this.options_),t=e.tracks;e.tracks=[];for(var n=0;n<t.length;n++){var r=t[n];r=J(r),r.player=void 0,e.tracks[n]=r}return e},i.createModal=function(e,t){var n=this;t=t||{},t.content=e||"";var r=new Fn(this,t);return this.addChild(r),r.on("dispose",function(){n.removeChild(r)}),r.open(),r},i.updateCurrentBreakpoint_=function(){if(this.responsive())for(var e=this.currentBreakpoint(),t=this.currentWidth(),n=0;n<rs.length;n++){var r=rs[n],i=this.breakpoints_[r];if(t<=i){if(e===r)return;e&&this.removeClass(is[e]),this.addClass(is[r]),this.breakpoint_=r;break}}},i.removeCurrentBreakpoint_=function(){var e=this.currentBreakpointClass();this.breakpoint_="",e&&this.removeClass(e)},i.breakpoints=function(e){return void 0===e?a(this.breakpoints_):(this.breakpoint_="",this.breakpoints_=a({},as,e),this.updateCurrentBreakpoint_(),a(this.breakpoints_))},i.responsive=function(e){return void 0===e?this.responsive_:(e=Boolean(e),e!==this.responsive_?(this.responsive_=e,e?(this.on("playerresize",this.updateCurrentBreakpoint_),this.updateCurrentBreakpoint_()):(this.off("playerresize",this.updateCurrentBreakpoint_),this.removeCurrentBreakpoint_()),e):void 0)},i.currentBreakpoint=function(){return this.breakpoint_},i.currentBreakpointClass=function(){return is[this.breakpoint_]||""},i.loadMedia=function(e,t){var n=this;if(e&&"object"==typeof e){this.reset(),this.cache_.media=J(e);var r=this.cache_.media,i=r.artwork,a=r.poster,o=r.src,s=r.textTracks;!i&&a&&(this.cache_.media.artwork=[{src:a,type:_a(a)}]),o&&this.src(o),a&&this.poster(a),Array.isArray(s)&&s.forEach(function(e){return n.addRemoteTextTrack(e,!1)}),this.ready(t)}},i.getMedia=function(){if(!this.cache_.media){var e=this.poster(),t=this.currentSources(),n=Array.prototype.map.call(this.remoteTextTracks(),function(e){return{kind:e.kind,label:e.label,language:e.language,src:e.src}}),r={src:t,textTracks:n};return e&&(r.poster=e,r.artwork=[{src:r.poster,type:_a(r.poster)}]),r}return J(this.cache_.media)},r.getTagSettings=function(e){var t={sources:[],tracks:[]},n=k(e),r=n["data-setup"];if(_(e,"vjs-fill")&&(n.fill=!0),_(e,"vjs-fluid")&&(n.fluid=!0),null!==r){var i=Pn(r||"{}"),o=i[0],s=i[1];o&&Tt.error(o),a(n,s)}if(a(t,n),e.hasChildNodes())for(var u=e.childNodes,l=0,c=u.length;l<c;l++){var d=u[l],f=d.nodeName.toLowerCase();"source"===f?t.sources.push(k(d)):"track"===f&&t.tracks.push(k(d))}return t},i.flexNotSupported_=function(){var e=t.createElement("i");return!("flexBasis"in e.style||"webkitFlexBasis"in e.style||"mozFlexBasis"in e.style||"msFlexBasis"in e.style||"msFlexOrder"in e.style)},r}(rn);Xi.names.forEach(function(e){var t=Xi[e];os.prototype[t.getterName]=function(){return this.tech_?this.tech_[t.getterName]():(this[t.privateName]=this[t.privateName]||new t.ListClass,this[t.privateName])}}),os.players={};var ss=e.navigator;os.prototype.options_={techOrder:da.defaultTechOrder_,html5:{},flash:{},inactivityTimeout:2e3,playbackRates:[],liveui:!1,children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","liveTracker","controlBar","errorDisplay","textTrackSettings","resizeManager"],language:ss&&(ss.languages&&ss.languages[0]||ss.userLanguage||ss.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreen:{options:{navigationUI:"hide"}},breakpoints:{},responsive:!1},["ended","seeking","seekable","networkState","readyState"].forEach(function(e){os.prototype[e]=function(){return this.techGet_(e)}}),ts.forEach(function(e){os.prototype["handleTech"+tn(e)+"_"]=function(){return this.trigger(e)}}),rn.registerComponent("Player",os);var us={},ls=function(e){return us.hasOwnProperty(e)},cs=function(e){return ls(e)?us[e]:void 0},ds=function(e,t){e.activePlugins_=e.activePlugins_||{},e.activePlugins_[t]=!0},fs=function(e,t,n){var r=(n?"before":"")+"pluginsetup";e.trigger(r,t),e.trigger(r+":"+t.name,t)},hs=function(e,t){var n=function(){fs(this,{name:e,plugin:t,instance:null},!0);var n=t.apply(this,arguments);return ds(this,e),fs(this,{name:e,plugin:t,instance:n}),n};return Object.keys(t).forEach(function(e){n[e]=t[e]}),n},ps=function(e,t){return t.prototype.name=e,function(){fs(this,{name:e,plugin:t,instance:null},!0);for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];var a=te(t,[this].concat(r));return this[e]=function(){return a},fs(this,a.getEventHash()),a}},ms=function(){function e(t){if(this.constructor===e)throw new Error("Plugin must be sub-classed; not directly instantiated.");this.player=t,K(this),delete this.trigger,X(this,this.constructor.defaultState),ds(t,this.name),this.dispose=Nt(this,this.dispose),t.on("dispose",this.dispose)}var t=e.prototype;return t.version=function(){return this.constructor.VERSION},t.getEventHash=function(e){return void 0===e&&(e={}),e.name=this.name,e.plugin=this.constructor,e.instance=this,e},t.trigger=function(e,t){return void 0===t&&(t={}),z(this.eventBusEl_,e,this.getEventHash(t))},t.handleStateChanged=function(e){},t.dispose=function(){var e=this.name,t=this.player;this.trigger("dispose"),this.off(),t.off("dispose",this.dispose),t.activePlugins_[e]=!1,this.player=this.state=null,t[e]=ps(e,us[e])},e.isBasic=function(t){var n="string"==typeof t?cs(t):t;return"function"==typeof n&&!e.prototype.isPrototypeOf(n.prototype)},e.registerPlugin=function(t,n){if("string"!=typeof t)throw new Error('Illegal plugin name, "'+t+'", must be a string, was '+typeof t+".");if(ls(t))Tt.warn('A plugin named "'+t+'" already exists. You may want to avoid re-registering plugins!');else if(os.prototype.hasOwnProperty(t))throw new Error('Illegal plugin name, "'+t+'", cannot share a name with an existing player method!');if("function"!=typeof n)throw new Error('Illegal plugin for "'+t+'", must be a function, was '+typeof n+".");return us[t]=n,"plugin"!==t&&(e.isBasic(n)?os.prototype[t]=hs(t,n):os.prototype[t]=ps(t,n)),n},e.deregisterPlugin=function(e){if("plugin"===e)throw new Error("Cannot de-register base plugin.");ls(e)&&(delete us[e],delete os.prototype[e])},e.getPlugins=function(e){void 0===e&&(e=Object.keys(us));var t;return e.forEach(function(e){var n=cs(e);n&&(t=t||{},t[e]=n)}),t},e.getPluginVersion=function(e){var t=cs(e);return t&&t.VERSION||""},e}();ms.getPlugin=cs,ms.BASE_PLUGIN_NAME="plugin",ms.registerPlugin("plugin",ms),os.prototype.usingPlugin=function(e){return!!this.activePlugins_&&!0===this.activePlugins_[e]},os.prototype.hasPlugin=function(e){return!!ls(e)};var vs=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(e.super_=t)},gs=function(e,t){void 0===t&&(t={});var n=function(){e.apply(this,arguments)},r={};"object"==typeof t?(t.constructor!==Object.prototype.constructor&&(n=t.constructor),r=t):"function"==typeof t&&(n=t),vs(n,e);for(var i in r)r.hasOwnProperty(i)&&(n.prototype[i]=r[i]);return n},ys=function(e){return 0===e.indexOf("#")?e.slice(1):e};if(ut.hooks_={},ut.hooks=function(e,t){return ut.hooks_[e]=ut.hooks_[e]||[],t&&(ut.hooks_[e]=ut.hooks_[e].concat(t)),ut.hooks_[e]},ut.hook=function(e,t){ut.hooks(e,t)},ut.hookOnce=function(e,t){ut.hooks(e,[].concat(t).map(function(t){return function n(){return ut.removeHook(e,n),t.apply(void 0,arguments)}}))},ut.removeHook=function(e,t){var n=ut.hooks(e).indexOf(t);return!(n<=-1||(ut.hooks_[e]=ut.hooks_[e].slice(),ut.hooks_[e].splice(n,1),0))},!0!==e.VIDEOJS_NO_DYNAMIC_STYLE&&f()){var _s=Et(".vjs-styles-defaults");if(!_s){_s=Mt("vjs-styles-defaults");var bs=Et("head");bs&&bs.insertBefore(_s,bs.firstChild),Ut(_s,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n ")}}Y(1,ut),ut.VERSION=yt,ut.options=os.prototype.options_,ut.getPlayers=function(){return os.players},ut.getPlayer=function(e){var t,n=os.players;if("string"==typeof e){var r=ys(e),i=n[r];if(i)return i;t=Et("#"+r)}else t=e;if(h(t)){var a=t,o=a.player,s=a.playerId;if(o||n[s])return o||n[s]}},ut.getAllPlayers=function(){return Object.keys(os.players).map(function(e){return os.players[e]}).filter(Boolean)},ut.players=os.players,ut.getComponent=rn.getComponent,ut.registerComponent=function(e,t){da.isTech(t)&&Tt.warn("The "+e+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),rn.registerComponent.call(rn,e,t)},ut.getTech=da.getTech,ut.registerTech=da.registerTech,ut.use=qe,Object.defineProperty(ut,"middleware",{value:{},writeable:!1,enumerable:!0}),Object.defineProperty(ut.middleware,"TERMINATOR",{value:pa,writeable:!1,enumerable:!0}),ut.browser=An,ut.TOUCH_ENABLED=En,ut.extend=gs,ut.mergeOptions=J,ut.bind=Nt,ut.registerPlugin=ms.registerPlugin,ut.deregisterPlugin=ms.deregisterPlugin,ut.plugin=function(e,t){return Tt.warn("videojs.plugin() is deprecated; use videojs.registerPlugin() instead"),ms.registerPlugin(e,t)},ut.getPlugins=ms.getPlugins,ut.getPlugin=ms.getPlugin,ut.getPluginVersion=ms.getPluginVersion,ut.addLanguage=function(e,t){var n;return e=(""+e).toLowerCase(),ut.options.languages=J(ut.options.languages,(n={},n[e]=t,n)),ut.options.languages[e]},ut.log=Tt,ut.createLogger=St,ut.createTimeRange=ut.createTimeRanges=oe,ut.formatTime=it,ut.setFormatTime=nt,ut.resetFormatTime=rt,ut.parseUrl=nr,ut.isCrossOrigin=ar,ut.EventTarget=qt,ut.on=G,ut.one=W,ut.off=H,ut.trigger=z,ut.xhr=Ni,ut.TextTrack=qi,ut.AudioTrack=Gi,ut.VideoTrack=Hi,["isEl","isTextNode","createEl","hasClass","addClass","removeClass","toggleClass","setAttributes","getAttributes","emptyEl","appendContent","insertContent"].forEach(function(e){ut[e]=function(){return Tt.warn("videojs."+e+"() is deprecated; use videojs.dom."+e+"() instead"),Ct[e].apply(null,arguments)}}),ut.computedStyle=u,ut.dom=Ct,ut.url=or;var Ts,Ss,ws,ks,Es,As=fe(function(e,t){!function(t){var n=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/?#]*)?((?:[^\/\?#]*\/)*.*?)??(;.*?)?(\?.*?)?(#.*?)?$/,r=/^([^\/?#]*)(.*)$/,i=/(?:\/|^)\.(?=\/)/g,a=/(?:\/|^)\.\.\/(?!\.\.\/).*?(?=\/)/g,o={buildAbsoluteURL:function(e,t,n){if(n=n||{},e=e.trim(),!(t=t.trim())){if(!n.alwaysNormalize)return e;var i=o.parseURL(e);if(!i)throw new Error("Error trying to parse base URL.");return i.path=o.normalizePath(i.path),o.buildURLFromParts(i)}var a=o.parseURL(t);if(!a)throw new Error("Error trying to parse relative URL.");if(a.scheme)return n.alwaysNormalize?(a.path=o.normalizePath(a.path),o.buildURLFromParts(a)):t;var s=o.parseURL(e);if(!s)throw new Error("Error trying to parse base URL.");if(!s.netLoc&&s.path&&"/"!==s.path[0]){var u=r.exec(s.path);s.netLoc=u[1],s.path=u[2]}s.netLoc&&!s.path&&(s.path="/");var l={scheme:s.scheme,netLoc:a.netLoc,path:null,params:a.params,query:a.query,fragment:a.fragment};if(!a.netLoc&&(l.netLoc=s.netLoc,"/"!==a.path[0]))if(a.path){var c=s.path,d=c.substring(0,c.lastIndexOf("/")+1)+a.path;l.path=o.normalizePath(d)}else l.path=s.path,a.params||(l.params=s.params,a.query||(l.query=s.query));return null===l.path&&(l.path=n.alwaysNormalize?o.normalizePath(a.path):a.path),o.buildURLFromParts(l)},parseURL:function(e){var t=n.exec(e);return t?{scheme:t[1]||"",netLoc:t[2]||"",path:t[3]||"",params:t[4]||"",query:t[5]||"",fragment:t[6]||""}:null},normalizePath:function(e){for(e=e.split("").reverse().join("").replace(i,"");e.length!==(e=e.replace(a,"")).length;);return e.split("").reverse().join("")},buildURLFromParts:function(e){return e.scheme+e.netLoc+e.path+e.params+e.query+e.fragment}};e.exports=o}()}),Cs=function(){function e(){this.listeners={}}var t=e.prototype;return t.on=function(e,t){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push(t)},t.off=function(e,t){if(!this.listeners[e])return!1;var n=this.listeners[e].indexOf(t);return this.listeners[e].splice(n,1),n>-1},t.trigger=function(e){var t,n,r,i=this.listeners[e];if(i)if(2===arguments.length)for(n=i.length,t=0;t<n;++t)i[t].call(this,arguments[1]);else for(r=Array.prototype.slice.call(arguments,1),n=i.length,t=0;t<n;++t)i[t].apply(this,r)},t.dispose=function(){this.listeners={}},t.pipe=function(e){this.on("data",function(t){e.push(t)})},e}(),Ls=function(e){function t(){var t;return t=e.call(this)||this,t.buffer="",t}return ct(t,e),t.prototype.push=function(e){var t;for(this.buffer+=e,t=this.buffer.indexOf("\n");t>-1;t=this.buffer.indexOf("\n"))this.trigger("data",this.buffer.substring(0,t)),this.buffer=this.buffer.substring(t+1)},t}(Cs),xs=function(){return new RegExp('(?:^|,)((?:[^=]*)=(?:"[^"]*"|[^,]*))')},js=function(e){for(var t,n=e.split(xs()),r={},i=n.length;i--;)""!==n[i]&&(t=/([^=]*)=(.*)/.exec(n[i]).slice(1),t[0]=t[0].replace(/^\s+|\s+$/g,""),t[1]=t[1].replace(/^\s+|\s+$/g,""),t[1]=t[1].replace(/^['"](.*)['"]$/g,"$1"),r[t[0]]=t[1]);return r},Os=function(e){function t(){var t;return t=e.call(this)||this,t.customParsers=[],t.tagMappers=[],t}ct(t,e);var n=t.prototype;return n.push=function(e){var t,n,r=this;if(e=e.trim(),0!==e.length){if("#"!==e[0])return void this.trigger("data",{type:"uri",uri:e});this.tagMappers.reduce(function(t,n){var r=n(e);return r===e?t:t.concat([r])},[e]).forEach(function(e){for(var i=0;i<r.customParsers.length;i++)if(r.customParsers[i].call(r,e))return;if(0!==e.indexOf("#EXT"))return void r.trigger("data",{type:"comment",text:e.slice(1)});if(e=e.replace("\r",""),t=/^#EXTM3U/.exec(e))return void r.trigger("data",{type:"tag",tagType:"m3u"});if(t=/^#EXTINF:?([0-9\.]*)?,?(.*)?$/.exec(e))return n={type:"tag",tagType:"inf"},t[1]&&(n.duration=parseFloat(t[1])),t[2]&&(n.title=t[2]),void r.trigger("data",n);if(t=/^#EXT-X-TARGETDURATION:?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"targetduration"},t[1]&&(n.duration=parseInt(t[1],10)),void r.trigger("data",n);if(t=/^#ZEN-TOTAL-DURATION:?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"totalduration"},t[1]&&(n.duration=parseInt(t[1],10)),void r.trigger("data",n);if(t=/^#EXT-X-VERSION:?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"version"},t[1]&&(n.version=parseInt(t[1],10)),void r.trigger("data",n);if(t=/^#EXT-X-MEDIA-SEQUENCE:?(\-?[0-9.]*)?/.exec(e))return n={type:"tag",tagType:"media-sequence"},t[1]&&(n.number=parseInt(t[1],10)),void r.trigger("data",n);if(t=/^#EXT-X-DISCONTINUITY-SEQUENCE:?(\-?[0-9.]*)?/.exec(e))return n={type:"tag",tagType:"discontinuity-sequence"},t[1]&&(n.number=parseInt(t[1],10)),void r.trigger("data",n);if(t=/^#EXT-X-PLAYLIST-TYPE:?(.*)?$/.exec(e))return n={type:"tag",tagType:"playlist-type"},t[1]&&(n.playlistType=t[1]),void r.trigger("data",n);if(t=/^#EXT-X-BYTERANGE:?([0-9.]*)?@?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"byterange"},t[1]&&(n.length=parseInt(t[1],10)),t[2]&&(n.offset=parseInt(t[2],10)),void r.trigger("data",n);if(t=/^#EXT-X-ALLOW-CACHE:?(YES|NO)?/.exec(e))return n={type:"tag",tagType:"allow-cache"},t[1]&&(n.allowed=!/NO/.test(t[1])),void r.trigger("data",n);if(t=/^#EXT-X-MAP:?(.*)$/.exec(e)){if(n={type:"tag",tagType:"map"},t[1]){var a=js(t[1]);if(a.URI&&(n.uri=a.URI),a.BYTERANGE){var o=a.BYTERANGE.split("@"),s=o[0],u=o[1];n.byterange={},s&&(n.byterange.length=parseInt(s,10)),u&&(n.byterange.offset=parseInt(u,10))}}return void r.trigger("data",n)}if(t=/^#EXT-X-STREAM-INF:?(.*)$/.exec(e)){if(n={type:"tag",tagType:"stream-inf"},t[1]){if(n.attributes=js(t[1]),n.attributes.RESOLUTION){var l=n.attributes.RESOLUTION.split("x"),c={};l[0]&&(c.width=parseInt(l[0],10)),l[1]&&(c.height=parseInt(l[1],10)),n.attributes.RESOLUTION=c}n.attributes.BANDWIDTH&&(n.attributes.BANDWIDTH=parseInt(n.attributes.BANDWIDTH,10)),n.attributes["PROGRAM-ID"]&&(n.attributes["PROGRAM-ID"]=parseInt(n.attributes["PROGRAM-ID"],10))}return void r.trigger("data",n)}return(t=/^#EXT-X-MEDIA:?(.*)$/.exec(e))?(n={type:"tag",tagType:"media"},t[1]&&(n.attributes=js(t[1])),void r.trigger("data",n)):(t=/^#EXT-X-ENDLIST/.exec(e))?void r.trigger("data",{type:"tag",tagType:"endlist"}):(t=/^#EXT-X-DISCONTINUITY/.exec(e))?void r.trigger("data",{type:"tag",tagType:"discontinuity"}):(t=/^#EXT-X-PROGRAM-DATE-TIME:?(.*)$/.exec(e))?(n={type:"tag",tagType:"program-date-time"},t[1]&&(n.dateTimeString=t[1],n.dateTimeObject=new Date(t[1])),void r.trigger("data",n)):(t=/^#EXT-X-KEY:?(.*)$/.exec(e))?(n={type:"tag",tagType:"key"},t[1]&&(n.attributes=js(t[1]),n.attributes.IV&&("0x"===n.attributes.IV.substring(0,2).toLowerCase()&&(n.attributes.IV=n.attributes.IV.substring(2)),n.attributes.IV=n.attributes.IV.match(/.{8}/g),n.attributes.IV[0]=parseInt(n.attributes.IV[0],16),n.attributes.IV[1]=parseInt(n.attributes.IV[1],16),n.attributes.IV[2]=parseInt(n.attributes.IV[2],16),n.attributes.IV[3]=parseInt(n.attributes.IV[3],16),n.attributes.IV=new Uint32Array(n.attributes.IV))),void r.trigger("data",n)):(t=/^#EXT-X-START:?(.*)$/.exec(e))?(n={type:"tag",tagType:"start"},t[1]&&(n.attributes=js(t[1]),n.attributes["TIME-OFFSET"]=parseFloat(n.attributes["TIME-OFFSET"]),n.attributes.PRECISE=/YES/.test(n.attributes.PRECISE)),void r.trigger("data",n)):(t=/^#EXT-X-CUE-OUT-CONT:?(.*)?$/.exec(e))?(n={type:"tag",tagType:"cue-out-cont"},t[1]?n.data=t[1]:n.data="",void r.trigger("data",n)):(t=/^#EXT-X-CUE-OUT:?(.*)?$/.exec(e))?(n={type:"tag",tagType:"cue-out"},t[1]?n.data=t[1]:n.data="",void r.trigger("data",n)):(t=/^#EXT-X-CUE-IN:?(.*)?$/.exec(e))?(n={type:"tag",tagType:"cue-in"},t[1]?n.data=t[1]:n.data="",void r.trigger("data",n)):void r.trigger("data",{type:"tag",data:e.slice(4)})})}},n.addParser=function(e){var t=this,n=e.expression,r=e.customType,i=e.dataParser,a=e.segment;"function"!=typeof i&&(i=function(e){return e}),this.customParsers.push(function(e){if(n.exec(e))return t.trigger("data",{type:"custom",data:i(e),customType:r,segment:a}),!0})},n.addTagMapper=function(e){var t=e.expression,n=e.map,r=function(e){return t.test(e)?n(e):e};this.tagMappers.push(r)},t}(Cs),Is=function(e){function t(){var t;t=e.call(this)||this,t.lineStream=new Ls,t.parseStream=new Os,t.lineStream.pipe(t.parseStream);var n,r,i=dt(dt(t)),a=[],o={},s=function(){},u={AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},l=0;return t.manifest={allowCache:!0,discontinuityStarts:[],segments:[]},t.parseStream.on("data",function(e){var t,c;({tag:function(){(({"allow-cache":function(){this.manifest.allowCache=e.allowed,"allowed"in e||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange:function(){var t={};"length"in e&&(o.byterange=t,t.length=e.length,"offset"in e||(this.trigger("info",{message:"defaulting offset to zero"}),e.offset=0)),"offset"in e&&(o.byterange=t,t.offset=e.offset)},endlist:function(){this.manifest.endList=!0},inf:function(){"mediaSequence"in this.manifest||(this.manifest.mediaSequence=0,this.trigger("info",{message:"defaulting media sequence to zero"})),"discontinuitySequence"in this.manifest||(this.manifest.discontinuitySequence=0,this.trigger("info",{message:"defaulting discontinuity sequence to zero"})),e.duration>0&&(o.duration=e.duration),0===e.duration&&(o.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=a},key:function(){return e.attributes?"NONE"===e.attributes.METHOD?void(r=null):e.attributes.URI?(e.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),r={method:e.attributes.METHOD||"AES-128",uri:e.attributes.URI},void(void 0!==e.attributes.IV&&(r.iv=e.attributes.IV))):void this.trigger("warn",{message:"ignoring key declaration without URI"}):void this.trigger("warn",{message:"ignoring key declaration without attribute list"})},"media-sequence":function(){if(!isFinite(e.number))return void this.trigger("warn",{message:"ignoring invalid media sequence: "+e.number});this.manifest.mediaSequence=e.number},"discontinuity-sequence":function(){if(!isFinite(e.number))return void this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+e.number});this.manifest.discontinuitySequence=e.number,l=e.number},"playlist-type":function(){if(!/VOD|EVENT/.test(e.playlistType))return void this.trigger("warn",{message:"ignoring unknown playlist type: "+e.playlist});this.manifest.playlistType=e.playlistType},map:function(){n={},e.uri&&(n.uri=e.uri),e.byterange&&(n.byterange=e.byterange)},"stream-inf":function(){if(this.manifest.playlists=a,this.manifest.mediaGroups=this.manifest.mediaGroups||u,!e.attributes)return void this.trigger("warn",{message:"ignoring empty stream-inf attributes"});o.attributes||(o.attributes={}),lt(o.attributes,e.attributes)},media:function(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||u,!(e.attributes&&e.attributes.TYPE&&e.attributes["GROUP-ID"]&&e.attributes.NAME))return void this.trigger("warn",{message:"ignoring incomplete or missing media group"});var n=this.manifest.mediaGroups[e.attributes.TYPE];n[e.attributes["GROUP-ID"]]=n[e.attributes["GROUP-ID"]]||{},t=n[e.attributes["GROUP-ID"]],c={default:/yes/i.test(e.attributes.DEFAULT)},c.default?c.autoselect=!0:c.autoselect=/yes/i.test(e.attributes.AUTOSELECT),e.attributes.LANGUAGE&&(c.language=e.attributes.LANGUAGE),e.attributes.URI&&(c.uri=e.attributes.URI),e.attributes["INSTREAM-ID"]&&(c.instreamId=e.attributes["INSTREAM-ID"]),e.attributes.CHARACTERISTICS&&(c.characteristics=e.attributes.CHARACTERISTICS),e.attributes.FORCED&&(c.forced=/yes/i.test(e.attributes.FORCED)),t[e.attributes.NAME]=c},discontinuity:function(){l+=1,o.discontinuity=!0,this.manifest.discontinuityStarts.push(a.length)},"program-date-time":function(){void 0===this.manifest.dateTimeString&&(this.manifest.dateTimeString=e.dateTimeString,this.manifest.dateTimeObject=e.dateTimeObject),o.dateTimeString=e.dateTimeString,o.dateTimeObject=e.dateTimeObject},targetduration:function(){if(!isFinite(e.duration)||e.duration<0)return void this.trigger("warn",{message:"ignoring invalid target duration: "+e.duration});this.manifest.targetDuration=e.duration},totalduration:function(){if(!isFinite(e.duration)||e.duration<0)return void this.trigger("warn",{message:"ignoring invalid total duration: "+e.duration});this.manifest.totalDuration=e.duration},start:function(){if(!e.attributes||isNaN(e.attributes["TIME-OFFSET"]))return void this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"});this.manifest.start={timeOffset:e.attributes["TIME-OFFSET"],precise:e.attributes.PRECISE}},"cue-out":function(){o.cueOut=e.data},"cue-out-cont":function(){o.cueOutCont=e.data},"cue-in":function(){o.cueIn=e.data}})[e.tagType]||s).call(i)},uri:function(){o.uri=e.uri,a.push(o),!this.manifest.targetDuration||"duration"in o||(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),o.duration=this.manifest.targetDuration),r&&(o.key=r),o.timeline=l,n&&(o.map=n),o={}},comment:function(){},custom:function(){e.segment?(o.custom=o.custom||{},o.custom[e.customType]=e.data):(this.manifest.custom=this.manifest.custom||{},this.manifest.custom[e.customType]=e.data)}})[e.type].call(i)}),t}ct(t,e);var n=t.prototype;return n.push=function(e){this.lineStream.push(e)},n.end=function(){this.lineStream.push("\n")},n.addParser=function(e){this.parseStream.addParser(e)},n.addTagMapper=function(e){this.parseStream.addTagMapper(e)},t}(Cs),Ps=function(e){return!!e&&"object"==typeof e},Rs=function e(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return n.reduce(function(t,n){return Object.keys(n).forEach(function(r){Array.isArray(t[r])&&Array.isArray(n[r])?t[r]=t[r].concat(n[r]):Ps(t[r])&&Ps(n[r])?t[r]=e(t[r],n[r]):t[r]=n[r]}),t},{})},Ds=function(e){return Object.keys(e).map(function(t){return e[t]})},Ms=function(e,t){for(var n=[],r=e;r<t;r++)n.push(r);return n},Us=function(e){return e.reduce(function(e,t){return e.concat(t)},[])},Bs=function(e){if(!e.length)return[];for(var t=[],n=0;n<e.length;n++)t.push(e[n]);return t},Ns=function(e,t){return e.reduce(function(e,n,r){return n[t]&&e.push(r),e},[])},Fs={INVALID_NUMBER_OF_PERIOD:"INVALID_NUMBER_OF_PERIOD",DASH_EMPTY_MANIFEST:"DASH_EMPTY_MANIFEST",DASH_INVALID_XML:"DASH_INVALID_XML",NO_BASE_URL:"NO_BASE_URL",MISSING_SEGMENT_INFORMATION:"MISSING_SEGMENT_INFORMATION",SEGMENT_TIME_UNSPECIFIED:"SEGMENT_TIME_UNSPECIFIED",UNSUPPORTED_UTC_TIMING_SCHEME:"UNSUPPORTED_UTC_TIMING_SCHEME"},Vs=function(e,t){return t={exports:{}},function(e,t){!function(t){var n=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/?#]*)?((?:[^\/\?#]*\/)*.*?)??(;.*?)?(\?.*?)?(#.*?)?$/,r=/^([^\/?#]*)(.*)$/,i=/(?:\/|^)\.(?=\/)/g,a=/(?:\/|^)\.\.\/(?!\.\.\/).*?(?=\/)/g,o={buildAbsoluteURL:function(e,t,n){if(n=n||{},e=e.trim(),!(t=t.trim())){if(!n.alwaysNormalize)return e;var i=o.parseURL(e);if(!i)throw new Error("Error trying to parse base URL.");return i.path=o.normalizePath(i.path),o.buildURLFromParts(i)}var a=o.parseURL(t);if(!a)throw new Error("Error trying to parse relative URL.");if(a.scheme)return n.alwaysNormalize?(a.path=o.normalizePath(a.path),o.buildURLFromParts(a)):t;var s=o.parseURL(e);if(!s)throw new Error("Error trying to parse base URL.");if(!s.netLoc&&s.path&&"/"!==s.path[0]){var u=r.exec(s.path);s.netLoc=u[1],s.path=u[2]}s.netLoc&&!s.path&&(s.path="/");var l={scheme:s.scheme,netLoc:a.netLoc,path:null,params:a.params,query:a.query,fragment:a.fragment};if(!a.netLoc&&(l.netLoc=s.netLoc,"/"!==a.path[0]))if(a.path){var c=s.path,d=c.substring(0,c.lastIndexOf("/")+1)+a.path;l.path=o.normalizePath(d)}else l.path=s.path,a.params||(l.params=s.params,a.query||(l.query=s.query));return null===l.path&&(l.path=n.alwaysNormalize?o.normalizePath(a.path):a.path),o.buildURLFromParts(l)},parseURL:function(e){var t=n.exec(e);return t?{scheme:t[1]||"",netLoc:t[2]||"",path:t[3]||"",params:t[4]||"",query:t[5]||"",fragment:t[6]||""}:null},normalizePath:function(e){for(e=e.split("").reverse().join("").replace(i,"");e.length!==(e=e.replace(a,"")).length;);return e.split("").reverse().join("")},buildURLFromParts:function(e){return e.scheme+e.netLoc+e.path+e.params+e.query+e.fragment}};e.exports=o}()}(t,t.exports),t.exports}(),qs=function(t,n){return/^[a-z]+:/i.test(n)?n:(/\/\//i.test(t)||(t=Vs.buildAbsoluteURL(e.location.href,t)),Vs.buildAbsoluteURL(t,n))},Gs=function(e){var t=e.baseUrl,n=void 0===t?"":t,r=e.source,i=void 0===r?"":r,a=e.range,o=void 0===a?"":a,s=e.indexRange,u=void 0===s?"":s,l={uri:i,resolvedUri:qs(n||"",i)};if(o||u){var c=o||u,d=c.split("-"),f=parseInt(d[0],10),h=parseInt(d[1],10);l.byterange={length:h-f+1,offset:f}}return l},Hs=function(e){var t=e.offset+e.length-1;return e.offset+"-"+t},zs={static:function(e){var t=e.duration,n=e.timescale,r=void 0===n?1:n,i=e.sourceDuration;return{start:0,end:Math.ceil(i/(t/r))}},dynamic:function(e){var t=e.NOW,n=e.clientOffset,r=e.availabilityStartTime,i=e.timescale,a=void 0===i?1:i,o=e.duration,s=e.start,u=void 0===s?0:s,l=e.minimumUpdatePeriod,c=void 0===l?0:l,d=e.timeShiftBufferDepth,f=void 0===d?1/0:d,h=(t+n)/1e3,p=r+u,m=h+c,v=m-p,g=Math.ceil(v*a/o),y=Math.floor((h-p-f)*a/o),_=Math.floor((h-p)*a/o);return{start:Math.max(0,y),end:Math.min(g,_)}}},Ws=function(e){return function(t,n){var r=e.duration,i=e.timescale,a=void 0===i?1:i,o=e.periodIndex,s=e.startNumber;return{number:(void 0===s?1:s)+t,duration:r/a,timeline:o,time:n*r}}},$s=function(e){var t=e.type,n=void 0===t?"static":t,r=e.duration,i=e.timescale,a=void 0===i?1:i,o=e.sourceDuration,s=zs[n](e),u=s.start,l=s.end,c=Ms(u,l).map(Ws(e));if("static"===n){var d=c.length-1;c[d].duration=o-r/a*d}return c},Ys=function(e){var t=e.baseUrl,n=e.initialization,r=void 0===n?{}:n,i=e.sourceDuration,a=e.timescale,o=void 0===a?1:a,s=e.indexRange,u=void 0===s?"":s,l=e.duration;if(!t)throw new Error(Fs.NO_BASE_URL);var c=Gs({baseUrl:t,source:r.sourceURL,range:r.range}),d=Gs({baseUrl:t,source:t,indexRange:u});if(d.map=c,l){var f=$s(e);f.length&&(d.duration=f[0].duration,d.timeline=f[0].timeline)}else i&&(d.duration=i/o,d.timeline=0);return d.number=0,[d]},Ks=function(e,t,n){for(var r=e.sidx.map?e.sidx.map:null,i=e.sidx.duration,a=e.timeline||0,o=e.sidx.byterange,s=o.offset+o.length,u=t.timescale,l=t.references.filter(function(e){return 1!==e.referenceType}),c=[],d=s+t.firstOffset,f=0;f<l.length;f++){var h=t.references[f],p=h.referencedSize,m=h.subsegmentDuration,v=d+p-1,g=d+"-"+v,y={baseUrl:n,timescale:u,timeline:a,periodIndex:a,duration:m,sourceDuration:i,indexRange:g},_=Ys(y)[0];r&&(_.map=r),c.push(_),d+=p}return e.segments=c,e},Xs=function(e){return Ds(e.reduce(function(e,t){var n=t.attributes.id+(t.attributes.lang||"");if(e[n]){var r;t.segments[0]&&(t.segments[0].discontinuity=!0),(r=e[n].segments).push.apply(r,t.segments),t.attributes.contentProtection&&(e[n].attributes.contentProtection=t.attributes.contentProtection)}else e[n]=t;return e},{})).map(function(e){return e.discontinuityStarts=Ns(e.segments,"discontinuity"),e})},Js=function(e,t){if(void 0===t&&(t={}),!Object.keys(t).length)return e;for(var n in e){var r=e[n];if(r.sidx){var i=r.sidx.uri+"-"+Hs(r.sidx.byterange),a=t[i]&&t[i].sidx;r.sidx&&a&&Ks(r,a,r.sidx.resolvedUri)}}return e},Qs=function(e){var t,n=e.attributes,r=e.segments,i=e.sidx,a={attributes:(t={NAME:n.id,BANDWIDTH:n.bandwidth,CODECS:n.codecs},t["PROGRAM-ID"]=1,t),uri:"",endList:"static"===(n.type||"static"),timeline:n.periodIndex,resolvedUri:"",targetDuration:n.duration,segments:r,mediaSequence:r.length?r[0].number:1};return n.contentProtection&&(a.contentProtection=n.contentProtection),i&&(a.sidx=i),a},Zs=function(e){var t,n=e.attributes,r=e.segments;return void 0===r&&(r=[{uri:n.baseUrl,timeline:n.periodIndex,resolvedUri:n.baseUrl||"",duration:n.sourceDuration,number:0}],n.duration=n.sourceDuration),{attributes:(t={NAME:n.id,BANDWIDTH:n.bandwidth},t["PROGRAM-ID"]=1,t),uri:"",endList:"static"===(n.type||"static"),timeline:n.periodIndex,resolvedUri:n.baseUrl||"",targetDuration:n.duration,segments:r,mediaSequence:r.length?r[0].number:1}},eu=function(e,t){void 0===t&&(t={});var n,r=e.reduce(function(e,r){var i=r.attributes.role&&r.attributes.role.value||"",a=r.attributes.lang||"",o="main";if(a){var s=i?" ("+i+")":"";o=""+r.attributes.lang+s}return e[o]&&e[o].playlists[0].attributes.BANDWIDTH>r.attributes.bandwidth?e:(e[o]={language:a,autoselect:!0,default:"main"===i,playlists:Js([Qs(r)],t),uri:""},void 0===n&&"main"===i&&(n=r,n.default=!0),e)},{});return n||(r[Object.keys(r)[0]].default=!0),r},tu=function(e,t){return void 0===t&&(t={}),e.reduce(function(e,n){var r=n.attributes.lang||"text";return e[r]?e:(e[r]={language:r,default:!1,autoselect:!1,playlists:Js([Zs(n)],t),uri:""},e)},{})},nu=function(e){var t,n=e.attributes,r=e.segments,i=e.sidx,a={attributes:(t={NAME:n.id,AUDIO:"audio",SUBTITLES:"subs",RESOLUTION:{width:n.width,height:n.height},CODECS:n.codecs,BANDWIDTH:n.bandwidth},t["PROGRAM-ID"]=1,t),uri:"",endList:"static"===(n.type||"static"),timeline:n.periodIndex,resolvedUri:"",targetDuration:n.duration,segments:r,mediaSequence:r.length?r[0].number:1};return n.contentProtection&&(a.contentProtection=n.contentProtection),i&&(a.sidx=i),a},ru=function(e,t){var n;if(void 0===t&&(t={}),!e.length)return{};var r=e[0].attributes,i=r.sourceDuration,a=r.minimumUpdatePeriod,o=void 0===a?0:a,s=function(e){var t=e.attributes;return"video/mp4"===t.mimeType||"video"===t.contentType},u=function(e){var t=e.attributes;return"audio/mp4"===t.mimeType||"audio"===t.contentType},l=function(e){var t=e.attributes;return"text/vtt"===t.mimeType||"text"===t.contentType},c=Xs(e.filter(s)).map(nu),d=Xs(e.filter(u)),f=e.filter(l),h={allowCache:!0,discontinuityStarts:[],segments:[],endList:!0,mediaGroups:(n={AUDIO:{},VIDEO:{}},n["CLOSED-CAPTIONS"]={},n.SUBTITLES={},n),uri:"",duration:i,playlists:Js(c,t),minimumUpdatePeriod:1e3*o};return d.length&&(h.mediaGroups.AUDIO.audio=eu(d,t)),f.length&&(h.mediaGroups.SUBTITLES.subs=tu(f,t)),h},iu=function(e,t,n){var r=e.NOW,i=e.clientOffset,a=e.availabilityStartTime,o=e.timescale,s=void 0===o?1:o,u=e.start,l=void 0===u?0:u,c=e.minimumUpdatePeriod,d=void 0===c?0:c,f=(r+i)/1e3,h=a+l,p=f+d,m=p-h;return Math.ceil((m*s-t)/n)},au=function(e,t){for(var n=e.type,r=void 0===n?"static":n,i=e.minimumUpdatePeriod,a=void 0===i?0:i,o=e.media,s=void 0===o?"":o,u=e.sourceDuration,l=e.timescale,c=void 0===l?1:l,d=e.startNumber,f=void 0===d?1:d,h=e.periodIndex,p=[],m=-1,v=0;v<t.length;v++){var g=t[v],y=g.d,_=g.r||0,b=g.t||0;m<0&&(m=b),b&&b>m&&(m=b);var T=void 0;if(_<0){var S=v+1;T=S===t.length?"dynamic"===r&&a>0&&s.indexOf("$Number$")>0?iu(e,m,y):(u*c-m)/y:(t[S].t-m)/y}else T=_+1;for(var w=f+p.length+T,k=f+p.length;k<w;)p.push({number:k,duration:y/c,time:m,timeline:h}),m+=y,k++}return p},ou=/\$([A-z]*)(?:(%0)([0-9]+)d)?\$/g,su=function(e){return function(t,n,r,i){if("$$"===t)return"$";if(void 0===e[n])return t;var a=""+e[n];return"RepresentationID"===n?a:(i=r?parseInt(i,10):1,a.length>=i?a:""+new Array(i-a.length+1).join("0")+a)}},uu=function(e,t){return e.replace(ou,su(t))},lu=function(e,t){return e.duration||t?e.duration?$s(e):au(e,t):[{number:e.startNumber||1,duration:e.sourceDuration,time:0,timeline:e.periodIndex}]},cu=function(e,t){var n={RepresentationID:e.id,Bandwidth:e.bandwidth||0},r=e.initialization,i=void 0===r?{sourceURL:"",range:""}:r,a=Gs({baseUrl:e.baseUrl,source:uu(i.sourceURL,n),range:i.range});return lu(e,t).map(function(t){n.Number=t.number,n.Time=t.time;var r=uu(e.media||"",n);return{uri:r,timeline:t.timeline,duration:t.duration,resolvedUri:qs(e.baseUrl||"",r),map:a,number:t.number}})},du=function(e,t){var n=e.baseUrl,r=e.initialization,i=void 0===r?{}:r,a=Gs({baseUrl:n,source:i.sourceURL,range:i.range}),o=Gs({baseUrl:n,source:t.media,range:t.mediaRange});return o.map=a,o},fu=function(e,t){var n=e.duration,r=e.segmentUrls,i=void 0===r?[]:r;if(!n&&!t||n&&t)throw new Error(Fs.SEGMENT_TIME_UNSPECIFIED);var a,o=i.map(function(t){return du(e,t)});return n&&(a=$s(e)),t&&(a=au(e,t)),a.map(function(e,t){if(o[t]){var n=o[t];return n.timeline=e.timeline,n.duration=e.duration,n.number=e.number,n}}).filter(function(e){return e})},hu=function(e){var t,n,r=e.attributes,i=e.segmentInfo;i.template?(n=cu,t=Rs(r,i.template)):i.base?(n=Ys,t=Rs(r,i.base)):i.list&&(n=fu,t=Rs(r,i.list));var a={attributes:r};if(!n)return a;var o=n(t,i.timeline);if(t.duration){var s=t,u=s.duration,l=s.timescale,c=void 0===l?1:l;t.duration=u/c}else o.length?t.duration=o.reduce(function(e,t){return Math.max(e,Math.ceil(t.duration))},0):t.duration=0;return a.attributes=t,a.segments=o,i.base&&t.indexRange&&(a.sidx=o[0],a.segments=[]),a},pu=function(e){return e.map(hu)},mu=function(e,t){return Bs(e.childNodes).filter(function(e){return e.tagName===t})},vu=function(e){return e.textContent.trim()},gu=function(e){var t=/P(?:(\d*)Y)?(?:(\d*)M)?(?:(\d*)D)?(?:T(?:(\d*)H)?(?:(\d*)M)?(?:([\d.]*)S)?)?/,n=t.exec(e);if(!n)return 0;var r=n.slice(1),i=r[0],a=r[1],o=r[2],s=r[3],u=r[4],l=r[5];return 31536e3*parseFloat(i||0)+2592e3*parseFloat(a||0)+86400*parseFloat(o||0)+3600*parseFloat(s||0)+60*parseFloat(u||0)+parseFloat(l||0)},yu=function(e){return/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(e)&&(e+="Z"),Date.parse(e)},_u={mediaPresentationDuration:function(e){return gu(e)},availabilityStartTime:function(e){return yu(e)/1e3},minimumUpdatePeriod:function(e){return gu(e)},timeShiftBufferDepth:function(e){return gu(e)},start:function(e){return gu(e)},width:function(e){return parseInt(e,10)},height:function(e){return parseInt(e,10)},bandwidth:function(e){return parseInt(e,10)},startNumber:function(e){return parseInt(e,10)},timescale:function(e){return parseInt(e,10)},duration:function(e){var t=parseInt(e,10);return isNaN(t)?gu(e):t},d:function(e){return parseInt(e,10)},t:function(e){return parseInt(e,10)},r:function(e){return parseInt(e,10)},DEFAULT:function(e){return e}},bu=function(e){return e&&e.attributes?Bs(e.attributes).reduce(function(e,t){var n=_u[t.name]||_u.DEFAULT;return e[t.name]=n(t.value),e},{}):{}},Tu={"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime"},Su=function(e,t){return t.length?Us(e.map(function(e){return t.map(function(t){return qs(e,vu(t))})})):e},wu=function(e){var t=mu(e,"SegmentTemplate")[0],n=mu(e,"SegmentList")[0],r=n&&mu(n,"SegmentURL").map(function(e){return Rs({tag:"SegmentURL"},bu(e))}),i=mu(e,"SegmentBase")[0],a=n||t,o=a&&mu(a,"SegmentTimeline")[0],s=n||i||t,u=s&&mu(s,"Initialization")[0],l=t&&bu(t);l&&u?l.initialization=u&&bu(u):l&&l.initialization&&(l.initialization={sourceURL:l.initialization});var c={template:l,timeline:o&&mu(o,"S").map(function(e){return bu(e)}),list:n&&Rs(bu(n),{segmentUrls:r,initialization:bu(u)}),base:i&&Rs(bu(i),{initialization:bu(u)})};return Object.keys(c).forEach(function(e){c[e]||delete c[e]}),c},ku=function(e,t,n){return function(r){var i=mu(r,"BaseURL"),a=Su(t,i),o=Rs(e,bu(r)),s=wu(r);return a.map(function(e){return{segmentInfo:Rs(n,s),attributes:Rs(o,{baseUrl:e})}})}},Eu=function(e){return e.reduce(function(e,t){var n=bu(t),r=Tu[n.schemeIdUri];if(r){e[r]={attributes:n};var i=mu(t,"cenc:pssh")[0];if(i){var a=vu(i),o=a&&ft(a);e[r].pssh=o}}return e},{})},Au=function(e,t,n){return function(r){var i=bu(r),a=Su(t,mu(r,"BaseURL")),o=mu(r,"Role")[0],s={role:bu(o)},u=Rs(e,i,s),l=Eu(mu(r,"ContentProtection"));Object.keys(l).length&&(u=Rs(u,{contentProtection:l}));var c=wu(r),d=mu(r,"Representation"),f=Rs(n,c);return Us(d.map(ku(u,a,f)))}},Cu=function(t,n){return function(r,i){var a=Su(n,mu(r,"BaseURL")),o=bu(r),s=parseInt(o.id,10),u=e.isNaN(s)?i:s,l=Rs(t,{periodIndex:u}),c=mu(r,"AdaptationSet"),d=wu(r);return Us(c.map(Au(l,a,d)))}},Lu=function(e,t){void 0===t&&(t={});var n=t,r=n.manifestUri,i=void 0===r?"":r,a=n.NOW,o=void 0===a?Date.now():a,s=n.clientOffset,u=void 0===s?0:s,l=mu(e,"Period");if(!l.length)throw new Error(Fs.INVALID_NUMBER_OF_PERIOD);var c=bu(e),d=Su([i],mu(e,"BaseURL"));return c.sourceDuration=c.mediaPresentationDuration||0,c.NOW=o,c.clientOffset=u,Us(l.map(Cu(c,d)))},xu=function(t){if(""===t)throw new Error(Fs.DASH_EMPTY_MANIFEST);var n=new e.DOMParser,r=n.parseFromString(t,"application/xml"),i=r&&"MPD"===r.documentElement.tagName?r.documentElement:null;if(!i||i&&i.getElementsByTagName("parsererror").length>0)throw new Error(Fs.DASH_INVALID_XML);return i},ju=function(e){var t=mu(e,"UTCTiming")[0];if(!t)return null;var n=bu(t);switch(n.schemeIdUri){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":n.method="HEAD";break;case"urn:mpeg:dash:utc:http-xsdate:2014":case"urn:mpeg:dash:utc:http-iso:2014":case"urn:mpeg:dash:utc:http-xsdate:2012":case"urn:mpeg:dash:utc:http-iso:2012":n.method="GET";break;case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":n.method="DIRECT",n.value=Date.parse(n.value);break;case"urn:mpeg:dash:utc:http-ntp:2014":case"urn:mpeg:dash:utc:ntp:2014":case"urn:mpeg:dash:utc:sntp:2014":default:throw new Error(Fs.UNSUPPORTED_UTC_TIMING_SCHEME)}return n},Ou=function(e,t){return void 0===t&&(t={}),ru(pu(Lu(xu(e),t)),t.sidxMapping)},Iu=function(e){return ju(xu(e))},Pu=function(e){return e>>>0},Ru={toUnsigned:Pu},Du=Ru.toUnsigned;Ts=function(e,t){var n,r,i,a,o,s=[];if(!t.length)return null;for(n=0;n<e.byteLength;)r=Du(e[n]<<24|e[n+1]<<16|e[n+2]<<8|e[n+3]),i=Ss(e.subarray(n+4,n+8)),a=r>1?n+r:e.byteLength,i===t[0]&&(1===t.length?s.push(e.subarray(n+8,a)):(o=Ts(e.subarray(n+8,a),t.slice(1)),o.length&&(s=s.concat(o)))),n=a;return s},Ss=function(e){var t="";return t+=String.fromCharCode(e[0]),t+=String.fromCharCode(e[1]),t+=String.fromCharCode(e[2]),t+=String.fromCharCode(e[3])},ws=function(e){var t={};return Ts(e,["moov","trak"]).reduce(function(e,t){var n,r,i,a,o;return(n=Ts(t,["tkhd"])[0])?(r=n[0],i=0===r?12:20,a=Du(n[i]<<24|n[i+1]<<16|n[i+2]<<8|n[i+3]),(o=Ts(t,["mdia","mdhd"])[0])?(r=o[0],i=0===r?12:20,e[a]=Du(o[i]<<24|o[i+1]<<16|o[i+2]<<8|o[i+3]),e):null):null},t)},ks=function(e,t){var n,r,i;return n=Ts(t,["moof","traf"]),r=[].concat.apply([],n.map(function(t){return Ts(t,["tfhd"]).map(function(n){var r,i,a;return r=Du(n[4]<<24|n[5]<<16|n[6]<<8|n[7]),i=e[r]||9e4,a=Ts(t,["tfdt"]).map(function(e){var t,n;return t=e[0],n=Du(e[4]<<24|e[5]<<16|e[6]<<8|e[7]),1===t&&(n*=Math.pow(2,32),n+=Du(e[8]<<24|e[9]<<16|e[10]<<8|e[11])),n})[0],(a=a||1/0)/i})})),i=Math.min.apply(null,r),isFinite(i)?i:0},Es=function(e){var t=Ts(e,["moov","trak"]),n=[];return t.forEach(function(e){var t=Ts(e,["mdia","hdlr"]),r=Ts(e,["tkhd"]);t.forEach(function(e,t){var i,a,o,s=Ss(e.subarray(8,12)),u=r[t];"vide"===s&&(i=new DataView(u.buffer,u.byteOffset,u.byteLength),a=i.getUint8(0),o=0===a?i.getUint32(12):i.getUint32(20),n.push(o))})}),n};var Mu,Uu,Bu={findBox:Ts,parseType:Ss,timescale:ws,startTime:ks,videoTrackIds:Es},Nu=Bu.parseType,Fu=function(e){return new Date(1e3*e-20828448e5)},Vu=function(e){return{isLeading:(12&e[0])>>>2,dependsOn:3&e[0],isDependedOn:(192&e[1])>>>6,hasRedundancy:(48&e[1])>>>4,paddingValue:(14&e[1])>>>1,isNonSyncSample:1&e[1],degradationPriority:e[2]<<8|e[3]}},qu=function(e){var t,n,r=new DataView(e.buffer,e.byteOffset,e.byteLength),i=[];for(t=0;t+4<e.length;t+=n)if(n=r.getUint32(t),t+=4,n<=0)i.push("<span style='color:red;'>MALFORMED DATA</span>");else switch(31&e[t]){case 1:i.push("slice_layer_without_partitioning_rbsp");break;case 5:i.push("slice_layer_without_partitioning_rbsp_idr");break;case 6:i.push("sei_rbsp");break;case 7:i.push("seq_parameter_set_rbsp");break;case 8:i.push("pic_parameter_set_rbsp");break;case 9:i.push("access_unit_delimiter_rbsp");break;default:i.push("UNKNOWN NAL - "+e[t]&31)}return i},Gu={avc1:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{dataReferenceIndex:t.getUint16(6),width:t.getUint16(24),height:t.getUint16(26),horizresolution:t.getUint16(28)+t.getUint16(30)/16,vertresolution:t.getUint16(32)+t.getUint16(34)/16,frameCount:t.getUint16(40),depth:t.getUint16(74),config:Mu(e.subarray(78,e.byteLength))}},avcC:function(e){var t,n,r,i,a=new DataView(e.buffer,e.byteOffset,e.byteLength),o={configurationVersion:e[0],avcProfileIndication:e[1],profileCompatibility:e[2],avcLevelIndication:e[3],lengthSizeMinusOne:3&e[4],sps:[],pps:[]},s=31&e[5];for(r=6,i=0;i<s;i++)n=a.getUint16(r),r+=2,o.sps.push(new Uint8Array(e.subarray(r,r+n))),r+=n;for(t=e[r],r++,i=0;i<t;i++)n=a.getUint16(r),r+=2,o.pps.push(new Uint8Array(e.subarray(r,r+n))),r+=n;return o},btrt:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{bufferSizeDB:t.getUint32(0),maxBitrate:t.getUint32(4),avgBitrate:t.getUint32(8)}},esds:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),esId:e[6]<<8|e[7],streamPriority:31&e[8],decoderConfig:{objectProfileIndication:e[11],streamType:e[12]>>>2&63,bufferSize:e[13]<<16|e[14]<<8|e[15],maxBitrate:e[16]<<24|e[17]<<16|e[18]<<8|e[19],avgBitrate:e[20]<<24|e[21]<<16|e[22]<<8|e[23],decoderConfigDescriptor:{tag:e[24],length:e[25],audioObjectType:e[26]>>>3&31,samplingFrequencyIndex:(7&e[26])<<1|e[27]>>>7&1,channelConfiguration:e[27]>>>3&15}}}},ftyp:function(e){for(var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n={majorBrand:Nu(e.subarray(0,4)),minorVersion:t.getUint32(4),compatibleBrands:[]},r=8;r<e.byteLength;)n.compatibleBrands.push(Nu(e.subarray(r,r+4))),r+=4;return n},dinf:function(e){return{boxes:Mu(e)}},dref:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),dataReferences:Mu(e.subarray(8))}},hdlr:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n={version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4)),handlerType:Nu(e.subarray(8,12)),name:""},r=8;for(r=24;r<e.byteLength;r++){if(0===e[r]){r++;break}n.name+=String.fromCharCode(e[r])}return n.name=decodeURIComponent(escape(n.name)),n},mdat:function(e){return{byteLength:e.byteLength,nals:qu(e)}},mdhd:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r=4,i={version:n.getUint8(0),flags:new Uint8Array(e.subarray(1,4)),language:""};return 1===i.version?(r+=4,i.creationTime=Fu(n.getUint32(r)),r+=8,i.modificationTime=Fu(n.getUint32(r)),r+=4,i.timescale=n.getUint32(r),r+=8,i.duration=n.getUint32(r)):(i.creationTime=Fu(n.getUint32(r)),r+=4,i.modificationTime=Fu(n.getUint32(r)),r+=4,i.timescale=n.getUint32(r),r+=4,i.duration=n.getUint32(r)),r+=4,t=n.getUint16(r),i.language+=String.fromCharCode(96+(t>>10)),i.language+=String.fromCharCode(96+((992&t)>>5)),i.language+=String.fromCharCode(96+(31&t)),i},mdia:function(e){return{boxes:Mu(e)}},mfhd:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),sequenceNumber:e[4]<<24|e[5]<<16|e[6]<<8|e[7]}},minf:function(e){return{boxes:Mu(e)}},mp4a:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n={dataReferenceIndex:t.getUint16(6),channelcount:t.getUint16(16),samplesize:t.getUint16(18),samplerate:t.getUint16(24)+t.getUint16(26)/65536};return e.byteLength>28&&(n.streamDescriptor=Mu(e.subarray(28))[0]),n},moof:function(e){return{boxes:Mu(e)}},moov:function(e){return{boxes:Mu(e)}},mvex:function(e){return{boxes:Mu(e)}},mvhd:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n=4,r={version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4))};return 1===r.version?(n+=4,r.creationTime=Fu(t.getUint32(n)),n+=8,r.modificationTime=Fu(t.getUint32(n)),n+=4,r.timescale=t.getUint32(n),n+=8,r.duration=t.getUint32(n)):(r.creationTime=Fu(t.getUint32(n)),n+=4,r.modificationTime=Fu(t.getUint32(n)),n+=4,r.timescale=t.getUint32(n),n+=4,r.duration=t.getUint32(n)),n+=4,r.rate=t.getUint16(n)+t.getUint16(n+2)/16,n+=4,r.volume=t.getUint8(n)+t.getUint8(n+1)/8,n+=2,n+=2,n+=8,r.matrix=new Uint32Array(e.subarray(n,n+36)),n+=36,n+=24,r.nextTrackId=t.getUint32(n),r},pdin:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4)),rate:t.getUint32(4),initialDelay:t.getUint32(8)}},sdtp:function(e){var t,n={version:e[0],flags:new Uint8Array(e.subarray(1,4)),samples:[]};for(t=4;t<e.byteLength;t++)n.samples.push({dependsOn:(48&e[t])>>4,isDependedOn:(12&e[t])>>2,hasRedundancy:3&e[t]});return n},sidx:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),references:[],referenceId:n.getUint32(4),timescale:n.getUint32(8),earliestPresentationTime:n.getUint32(12),firstOffset:n.getUint32(16)},i=n.getUint16(22);for(t=24;i;t+=12,i--)r.references.push({referenceType:(128&e[t])>>>7,referencedSize:2147483647&n.getUint32(t),subsegmentDuration:n.getUint32(t+4),startsWithSap:!!(128&e[t+8]),sapType:(112&e[t+8])>>>4,sapDeltaTime:268435455&n.getUint32(t+8)});return r},smhd:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),balance:e[4]+e[5]/256}},stbl:function(e){return{boxes:Mu(e)}},stco:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),chunkOffsets:[]},i=n.getUint32(4);for(t=8;i;t+=4,i--)r.chunkOffsets.push(n.getUint32(t));return r},stsc:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r=n.getUint32(4),i={version:e[0],flags:new Uint8Array(e.subarray(1,4)),sampleToChunks:[]};for(t=8;r;t+=12,r--)i.sampleToChunks.push({firstChunk:n.getUint32(t),samplesPerChunk:n.getUint32(t+4),sampleDescriptionIndex:n.getUint32(t+8)});return i},stsd:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),sampleDescriptions:Mu(e.subarray(8))}},stsz:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),sampleSize:n.getUint32(4),entries:[]};for(t=12;t<e.byteLength;t+=4)r.entries.push(n.getUint32(t));return r},stts:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),timeToSamples:[]},i=n.getUint32(4);for(t=8;i;t+=8,i--)r.timeToSamples.push({sampleCount:n.getUint32(t),sampleDelta:n.getUint32(t+4)});return r},styp:function(e){return Gu.ftyp(e)},tfdt:function(e){var t={version:e[0],flags:new Uint8Array(e.subarray(1,4)),baseMediaDecodeTime:e[4]<<24|e[5]<<16|e[6]<<8|e[7]};return 1===t.version&&(t.baseMediaDecodeTime*=Math.pow(2,32),t.baseMediaDecodeTime+=e[8]<<24|e[9]<<16|e[10]<<8|e[11]),t},tfhd:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),trackId:n.getUint32(4)},i=1&r.flags[2],a=2&r.flags[2],o=8&r.flags[2],s=16&r.flags[2],u=32&r.flags[2],l=65536&r.flags[0],c=131072&r.flags[0];return t=8,i&&(t+=4,r.baseDataOffset=n.getUint32(12),t+=4),a&&(r.sampleDescriptionIndex=n.getUint32(t),t+=4),o&&(r.defaultSampleDuration=n.getUint32(t),t+=4),s&&(r.defaultSampleSize=n.getUint32(t),t+=4),u&&(r.defaultSampleFlags=n.getUint32(t)),l&&(r.durationIsEmpty=!0),!i&&c&&(r.baseDataOffsetIsMoof=!0),r},tkhd:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n=4,r={version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4))};return 1===r.version?(n+=4,r.creationTime=Fu(t.getUint32(n)),n+=8,r.modificationTime=Fu(t.getUint32(n)),n+=4,r.trackId=t.getUint32(n),n+=4,n+=8,r.duration=t.getUint32(n)):(r.creationTime=Fu(t.getUint32(n)),n+=4,r.modificationTime=Fu(t.getUint32(n)),n+=4,r.trackId=t.getUint32(n),n+=4,n+=4,r.duration=t.getUint32(n)),n+=4,n+=8,r.layer=t.getUint16(n),n+=2,r.alternateGroup=t.getUint16(n),n+=2,r.volume=t.getUint8(n)+t.getUint8(n+1)/8,n+=2,n+=2,r.matrix=new Uint32Array(e.subarray(n,n+36)),n+=36,r.width=t.getUint16(n)+t.getUint16(n+2)/16,n+=4,r.height=t.getUint16(n)+t.getUint16(n+2)/16,r},traf:function(e){return{boxes:Mu(e)}},trak:function(e){return{boxes:Mu(e)}},trex:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),trackId:t.getUint32(4),defaultSampleDescriptionIndex:t.getUint32(8),defaultSampleDuration:t.getUint32(12),defaultSampleSize:t.getUint32(16),sampleDependsOn:3&e[20],sampleIsDependedOn:(192&e[21])>>6,sampleHasRedundancy:(48&e[21])>>4,samplePaddingValue:(14&e[21])>>1,sampleIsDifferenceSample:!!(1&e[21]),sampleDegradationPriority:t.getUint16(22)}},trun:function(e){var t,n={version:e[0],flags:new Uint8Array(e.subarray(1,4)),samples:[]},r=new DataView(e.buffer,e.byteOffset,e.byteLength),i=1&n.flags[2],a=4&n.flags[2],o=1&n.flags[1],s=2&n.flags[1],u=4&n.flags[1],l=8&n.flags[1],c=r.getUint32(4),d=8;for(i&&(n.dataOffset=r.getInt32(d),d+=4),a&&c&&(t={flags:Vu(e.subarray(d,d+4))},d+=4,o&&(t.duration=r.getUint32(d),d+=4),s&&(t.size=r.getUint32(d),d+=4),l&&(t.compositionTimeOffset=r.getUint32(d),d+=4),n.samples.push(t),c--);c--;)t={},o&&(t.duration=r.getUint32(d),d+=4),s&&(t.size=r.getUint32(d),d+=4),u&&(t.flags=Vu(e.subarray(d,d+4)),d+=4),l&&(t.compositionTimeOffset=r.getUint32(d),d+=4),n.samples.push(t);return n},"url ":function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4))}},vmhd:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),graphicsmode:t.getUint16(4),opcolor:new Uint16Array([t.getUint16(6),t.getUint16(8),t.getUint16(10)])}}};Mu=function(e){for(var t,n,r,i,a,o=0,s=[],u=new ArrayBuffer(e.length),l=new Uint8Array(u),c=0;c<e.length;++c)l[c]=e[c];for(t=new DataView(u);o<e.byteLength;)n=t.getUint32(o),r=Nu(e.subarray(o+4,o+8)),i=n>1?o+n:e.byteLength,a=(Gu[r]||function(e){return{data:e}})(e.subarray(o+8,i)),a.size=n,a.type=r,s.push(a),o=i;return s},Uu=function(e,t){var n;return t=t||0,n=new Array(2*t+1).join(" "),e.map(function(e,r){return n+e.type+"\n"+Object.keys(e).filter(function(e){return"type"!==e&&"boxes"!==e}).map(function(t){var r=n+" "+t+": ",i=e[t];if(i instanceof Uint8Array||i instanceof Uint32Array){var a=Array.prototype.slice.call(new Uint8Array(i.buffer,i.byteOffset,i.byteLength)).map(function(e){return" "+("00"+e.toString(16)).slice(-2)}).join("").match(/.{1,24}/g);return a?1===a.length?r+"<"+a.join("").slice(1)+">":r+"<\n"+a.map(function(e){return n+" "+e}).join("\n")+"\n"+n+" >":r+"<>"}return r+JSON.stringify(i,null,2).split("\n").map(function(e,t){return 0===t?e:n+" "+e}).join("\n")}).join("\n")+(e.boxes?"\n"+Uu(e.boxes,t+1):"")}).join("\n")};var Hu,zu,Wu,$u,Yu,Ku,Xu,Ju,Qu,Zu,el,tl,nl,rl,il,al,ol,sl,ul,ll,cl,dl,fl,hl,pl,ml,vl,gl,yl,_l,bl,Tl,Sl,wl,kl,El,Al={inspect:Mu,textify:Uu,parseTfdt:Gu.tfdt,parseHdlr:Gu.hdlr,parseTfhd:Gu.tfhd,parseTrun:Gu.trun,parseSidx:Gu.sidx},Cl=Math.pow(2,32)-1;!function(){var e;if(fl={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],sdtp:[],smhd:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],styp:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[]},"undefined"!=typeof Uint8Array){for(e in fl)fl.hasOwnProperty(e)&&(fl[e]=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)]);hl=new Uint8Array(["i".charCodeAt(0),"s".charCodeAt(0),"o".charCodeAt(0),"m".charCodeAt(0)]),ml=new Uint8Array(["a".charCodeAt(0),"v".charCodeAt(0),"c".charCodeAt(0),"1".charCodeAt(0)]),pl=new Uint8Array([0,0,0,1]),vl=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),gl=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),yl={video:vl,audio:gl},Tl=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),bl=new Uint8Array([0,0,0,0,0,0,0,0]),Sl=new Uint8Array([0,0,0,0,0,0,0,0]),wl=Sl,kl=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),El=Sl,_l=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}}(),Hu=function(e){var t,n,r,i=[],a=0;for(t=1;t<arguments.length;t++)i.push(arguments[t]);for(t=i.length;t--;)a+=i[t].byteLength;for(n=new Uint8Array(a+8),r=new DataView(n.buffer,n.byteOffset,n.byteLength),r.setUint32(0,n.byteLength),n.set(e,4),t=0,a=8;t<i.length;t++)n.set(i[t],a),a+=i[t].byteLength;return n},zu=function(){return Hu(fl.dinf,Hu(fl.dref,Tl))},Wu=function(e){return Hu(fl.esds,new Uint8Array([0,0,0,0,3,25,0,0,0,4,17,64,21,0,6,0,0,0,218,192,0,0,218,192,5,2,e.audioobjecttype<<3|e.samplingfrequencyindex>>>1,e.samplingfrequencyindex<<7|e.channelcount<<3,6,1,2]))},$u=function(){return Hu(fl.ftyp,hl,pl,hl,ml)},al=function(e){return Hu(fl.hdlr,yl[e])},Yu=function(e){return Hu(fl.mdat,e)},il=function(e){var t=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,e.duration>>>24&255,e.duration>>>16&255,e.duration>>>8&255,255&e.duration,85,196,0,0]);return e.samplerate&&(t[12]=e.samplerate>>>24&255,t[13]=e.samplerate>>>16&255,t[14]=e.samplerate>>>8&255,t[15]=255&e.samplerate),Hu(fl.mdhd,t)},rl=function(e){return Hu(fl.mdia,il(e),al(e.type),Xu(e))},Ku=function(e){return Hu(fl.mfhd,new Uint8Array([0,0,0,0,(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e]))},Xu=function(e){return Hu(fl.minf,"video"===e.type?Hu(fl.vmhd,_l):Hu(fl.smhd,bl),zu(),sl(e))},Ju=function(e,t){for(var n=[],r=t.length;r--;)n[r]=ll(t[r]);return Hu.apply(null,[fl.moof,Ku(e)].concat(n))},Qu=function(e){for(var t=e.length,n=[];t--;)n[t]=tl(e[t]);return Hu.apply(null,[fl.moov,el(4294967295)].concat(n).concat(Zu(e)))},Zu=function(e){for(var t=e.length,n=[];t--;)n[t]=cl(e[t]);return Hu.apply(null,[fl.mvex].concat(n))},el=function(e){var t=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return Hu(fl.mvhd,t)},ol=function(e){var t,n,r=e.samples||[],i=new Uint8Array(4+r.length);for(n=0;n<r.length;n++)t=r[n].flags,i[n+4]=t.dependsOn<<4|t.isDependedOn<<2|t.hasRedundancy;return Hu(fl.sdtp,i)},sl=function(e){return Hu(fl.stbl,ul(e),Hu(fl.stts,El),Hu(fl.stsc,wl),Hu(fl.stsz,kl),Hu(fl.stco,Sl))},function(){var e,t;ul=function(n){return Hu(fl.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),"video"===n.type?e(n):t(n))},e=function(e){var t,n=e.sps||[],r=e.pps||[],i=[],a=[];for(t=0;t<n.length;t++)i.push((65280&n[t].byteLength)>>>8),i.push(255&n[t].byteLength),i=i.concat(Array.prototype.slice.call(n[t]));for(t=0;t<r.length;t++)a.push((65280&r[t].byteLength)>>>8),a.push(255&r[t].byteLength),a=a.concat(Array.prototype.slice.call(r[t]));return Hu(fl.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,(65280&e.width)>>8,255&e.width,(65280&e.height)>>8,255&e.height,0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),Hu(fl.avcC,new Uint8Array([1,e.profileIdc,e.profileCompatibility,e.levelIdc,255].concat([n.length]).concat(i).concat([r.length]).concat(a))),Hu(fl.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])))},t=function(e){return Hu(fl.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(65280&e.channelcount)>>8,255&e.channelcount,(65280&e.samplesize)>>8,255&e.samplesize,0,0,0,0,(65280&e.samplerate)>>8,255&e.samplerate,0,0]),Wu(e))}}(),nl=function(e){var t=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(4278190080&e.id)>>24,(16711680&e.id)>>16,(65280&e.id)>>8,255&e.id,0,0,0,0,(4278190080&e.duration)>>24,(16711680&e.duration)>>16,(65280&e.duration)>>8,255&e.duration,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,(65280&e.width)>>8,255&e.width,0,0,(65280&e.height)>>8,255&e.height,0,0]);return Hu(fl.tkhd,t)},ll=function(e){var t,n,r,i,a,o,s;return t=Hu(fl.tfhd,new Uint8Array([0,0,0,58,(4278190080&e.id)>>24,(16711680&e.id)>>16,(65280&e.id)>>8,255&e.id,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),o=Math.floor(e.baseMediaDecodeTime/(Cl+1)),s=Math.floor(e.baseMediaDecodeTime%(Cl+1)),n=Hu(fl.tfdt,new Uint8Array([1,0,0,0,o>>>24&255,o>>>16&255,o>>>8&255,255&o,s>>>24&255,s>>>16&255,s>>>8&255,255&s])),a=92,"audio"===e.type?(r=dl(e,a),Hu(fl.traf,t,n,r)):(i=ol(e),r=dl(e,i.length+a),Hu(fl.traf,t,n,r,i))},tl=function(e){return e.duration=e.duration||4294967295,Hu(fl.trak,nl(e),rl(e))},cl=function(e){var t=new Uint8Array([0,0,0,0,(4278190080&e.id)>>24,(16711680&e.id)>>16,(65280&e.id)>>8,255&e.id,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return"video"!==e.type&&(t[t.length-1]=0),Hu(fl.trex,t)},function(){var e,t,n;n=function(e,t){var n=0,r=0,i=0,a=0;return e.length&&(void 0!==e[0].duration&&(n=1),void 0!==e[0].size&&(r=2),void 0!==e[0].flags&&(i=4),void 0!==e[0].compositionTimeOffset&&(a=8)),[0,0,n|r|i|a,1,(4278190080&e.length)>>>24,(16711680&e.length)>>>16,(65280&e.length)>>>8,255&e.length,(4278190080&t)>>>24,(16711680&t)>>>16,(65280&t)>>>8,255&t]},t=function(e,t){var r,i,a,o;for(i=e.samples||[],t+=20+16*i.length,r=n(i,t),o=0;o<i.length;o++)a=i[o],r=r.concat([(4278190080&a.duration)>>>24,(16711680&a.duration)>>>16,(65280&a.duration)>>>8,255&a.duration,(4278190080&a.size)>>>24,(16711680&a.size)>>>16,(65280&a.size)>>>8,255&a.size,a.flags.isLeading<<2|a.flags.dependsOn,a.flags.isDependedOn<<6|a.flags.hasRedundancy<<4|a.flags.paddingValue<<1|a.flags.isNonSyncSample,61440&a.flags.degradationPriority,15&a.flags.degradationPriority,(4278190080&a.compositionTimeOffset)>>>24,(16711680&a.compositionTimeOffset)>>>16,(65280&a.compositionTimeOffset)>>>8,255&a.compositionTimeOffset]);return Hu(fl.trun,new Uint8Array(r))},e=function(e,t){var r,i,a,o;for(i=e.samples||[],t+=20+8*i.length,r=n(i,t),o=0;o<i.length;o++)a=i[o],r=r.concat([(4278190080&a.duration)>>>24,(16711680&a.duration)>>>16,(65280&a.duration)>>>8,255&a.duration,(4278190080&a.size)>>>24,(16711680&a.size)>>>16,(65280&a.size)>>>8,255&a.size]);return Hu(fl.trun,new Uint8Array(r))},dl=function(n,r){return"audio"===n.type?e(n,r):t(n,r)}}();var Ll={ftyp:$u,mdat:Yu,moof:Ju,moov:Qu,initSegment:function(e){var t,n=$u(),r=Qu(e);return t=new Uint8Array(n.byteLength+r.byteLength),t.set(n),t.set(r,n.byteLength),t}},xl=function(){this.init=function(){var e={};this.on=function(t,n){e[t]||(e[t]=[]),e[t]=e[t].concat(n)},this.off=function(t,n){var r;return!!e[t]&&(r=e[t].indexOf(n),e[t]=e[t].slice(),e[t].splice(r,1),r>-1)},this.trigger=function(t){var n,r,i,a;if(n=e[t])if(2===arguments.length)for(i=n.length,r=0;r<i;++r)n[r].call(this,arguments[1]);else{for(a=[],r=arguments.length,r=1;r<arguments.length;++r)a.push(arguments[r]);for(i=n.length,r=0;r<i;++r)n[r].apply(this,a)}},this.dispose=function(){e={}}}};xl.prototype.pipe=function(e){return this.on("data",function(t){e.push(t)}),this.on("done",function(t){e.flush(t)}),e},xl.prototype.push=function(e){this.trigger("data",e)},xl.prototype.flush=function(e){this.trigger("done",e)};var jl,Ol,Il,Pl,Rl,Dl,Ml=xl,Ul=function(e){var t,n,r=[],i=[];for(r.byteLength=0,t=0;t<e.length;t++)n=e[t],"access_unit_delimiter_rbsp"===n.nalUnitType?(r.length&&(r.duration=n.dts-r.dts,i.push(r)),r=[n],r.byteLength=n.data.byteLength,r.pts=n.pts,r.dts=n.dts):("slice_layer_without_partitioning_rbsp_idr"===n.nalUnitType&&(r.keyFrame=!0),r.duration=n.dts-r.dts,r.byteLength+=n.data.byteLength,r.push(n));return i.length&&(!r.duration||r.duration<=0)&&(r.duration=i[i.length-1].duration),i.push(r),i},Bl=function(e){var t,n,r=[],i=[];for(r.byteLength=0,r.nalCount=0,r.duration=0,r.pts=e[0].pts,r.dts=e[0].dts,i.byteLength=0,i.nalCount=0,i.duration=0,i.pts=e[0].pts,i.dts=e[0].dts,t=0;t<e.length;t++)n=e[t],n.keyFrame?(r.length&&(i.push(r),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.duration+=r.duration),r=[n],r.nalCount=n.length,r.byteLength=n.byteLength,r.pts=n.pts,r.dts=n.dts,r.duration=n.duration):(r.duration+=n.duration,r.nalCount+=n.length,r.byteLength+=n.byteLength,r.push(n));return i.length&&r.duration<=0&&(r.duration=i[i.length-1].duration),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.duration+=r.duration,i.push(r),i},Nl=function(e){var t;return!e[0][0].keyFrame&&e.length>1&&(t=e.shift(),e.byteLength-=t.byteLength,e.nalCount-=t.nalCount,e[0][0].dts=t.dts,e[0][0].pts=t.pts,e[0][0].duration+=t.duration),e},Fl=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}}},Vl=function(e,t){var n=Fl();return n.dataOffset=t,n.compositionTimeOffset=e.pts-e.dts,n.duration=e.duration,n.size=4*e.length,n.size+=e.byteLength,e.keyFrame&&(n.flags.dependsOn=2,n.flags.isNonSyncSample=0),n},ql=function(e,t){var n,r,i,a,o,s=t||0,u=[];for(n=0;n<e.length;n++)for(a=e[n],r=0;r<a.length;r++)o=a[r],i=Vl(o,s),s+=i.size,u.push(i);return u},Gl=function(e){var t,n,r,i,a,o,s=0,u=e.byteLength,l=e.nalCount,c=u+4*l,d=new Uint8Array(c),f=new DataView(d.buffer);for(t=0;t<e.length;t++)for(i=e[t],n=0;n<i.length;n++)for(a=i[n],r=0;r<a.length;r++)o=a[r],f.setUint32(s,o.data.byteLength),s+=4,d.set(o.data,s),s+=o.data.byteLength;return d},Hl={groupNalsIntoFrames:Ul,groupFramesIntoGops:Bl,extendFirstKeyFrame:Nl,generateSampleTable:ql,concatenateNalData:Gl},zl=[33,16,5,32,164,27],Wl=[33,65,108,84,1,2,4,8,168,2,4,8,17,191,252],$l=function(e){for(var t=[];e--;)t.push(0);return t},Yl={96e3:[zl,[227,64],$l(154),[56]],88200:[zl,[231],$l(170),[56]],64e3:[zl,[248,192],$l(240),[56]],48e3:[zl,[255,192],$l(268),[55,148,128],$l(54),[112]],44100:[zl,[255,192],$l(268),[55,163,128],$l(84),[112]],32e3:[zl,[255,192],$l(268),[55,234],$l(226),[112]],24e3:[zl,[255,192],$l(268),[55,255,128],$l(268),[111,112],$l(126),[224]],16e3:[zl,[255,192],$l(268),[55,255,128],$l(268),[111,255],$l(269),[223,108],$l(195),[1,192]],12e3:[Wl,$l(268),[3,127,248],$l(268),[6,255,240],$l(268),[13,255,224],$l(268),[27,253,128],$l(259),[56]],11025:[Wl,$l(268),[3,127,248],$l(268),[6,255,240],$l(268),[13,255,224],$l(268),[27,255,192],$l(268),[55,175,128],$l(108),[112]],8e3:[Wl,$l(268),[3,121,16],$l(47),[7]]},Kl=function(e){return Object.keys(e).reduce(function(t,n){return t[n]=new Uint8Array(e[n].reduce(function(e,t){return e.concat(t)},[])),t},{})}(Yl);jl=function(e){return 9e4*e},Ol=function(e,t){return e*t},Il=function(e){return e/9e4},Pl=function(e,t){return e/t},Rl=function(e,t){return jl(Pl(e,t))},Dl=function(e,t){return Ol(Il(e),t)};var Xl={secondsToVideoTs:jl,secondsToAudioTs:Ol,videoTsToSeconds:Il,audioTsToSeconds:Pl,audioTsToVideoTs:Rl,videoTsToAudioTs:Dl},Jl=function(e){var t,n,r=0;for(t=0;t<e.length;t++)n=e[t],r+=n.data.byteLength;return r},Ql=function(e,t,n,r){var i,a,o,s=0,u=0,l=0,c=0;if(t.length&&(i=Xl.audioTsToVideoTs(e.baseMediaDecodeTime,e.samplerate),s=Math.ceil(9e4/(e.samplerate/1024)),n&&r&&(u=i-Math.max(n,r),l=Math.floor(u/s),c=l*s),!(l<1||c>45e3))){for(a=Kl[e.samplerate],a||(a=t[0].data),o=0;o<l;o++)t.splice(o,0,{data:a});e.baseMediaDecodeTime-=Math.floor(Xl.videoTsToAudioTs(c,e.samplerate))}},Zl=function(e,t,n){return t.minSegmentDts>=n?e:(t.minSegmentDts=1/0,e.filter(function(e){return e.dts>=n&&(t.minSegmentDts=Math.min(t.minSegmentDts,e.dts),t.minSegmentPts=t.minSegmentDts,!0)}))},ec=function(e){var t,n,r=[];for(t=0;t<e.length;t++)n=e[t],r.push({size:n.data.byteLength,duration:1024});return r},tc=function(e){var t,n,r=0,i=new Uint8Array(Jl(e));for(t=0;t<e.length;t++)n=e[t],i.set(n.data,r),r+=n.data.byteLength;return i},nc={prefixWithSilence:Ql,trimAdtsFramesByEarliestDts:Zl,generateSampleTable:ec,concatenateFrameData:tc},rc=function(e,t){"number"==typeof t.pts&&(void 0===e.timelineStartInfo.pts&&(e.timelineStartInfo.pts=t.pts),void 0===e.minSegmentPts?e.minSegmentPts=t.pts:e.minSegmentPts=Math.min(e.minSegmentPts,t.pts),void 0===e.maxSegmentPts?e.maxSegmentPts=t.pts:e.maxSegmentPts=Math.max(e.maxSegmentPts,t.pts)),"number"==typeof t.dts&&(void 0===e.timelineStartInfo.dts&&(e.timelineStartInfo.dts=t.dts),void 0===e.minSegmentDts?e.minSegmentDts=t.dts:e.minSegmentDts=Math.min(e.minSegmentDts,t.dts),void 0===e.maxSegmentDts?e.maxSegmentDts=t.dts:e.maxSegmentDts=Math.max(e.maxSegmentDts,t.dts))},ic=function(e){delete e.minSegmentDts,delete e.maxSegmentDts,delete e.minSegmentPts,delete e.maxSegmentPts},ac=function(e,t){var n,r,i=e.minSegmentDts;return t||(i-=e.timelineStartInfo.dts),n=e.timelineStartInfo.baseMediaDecodeTime,n+=i,n=Math.max(0,n),"audio"===e.type&&(r=e.samplerate/9e4,n*=r,n=Math.floor(n)),n},oc={clearDtsInfo:ic,calculateTrackBaseMediaDecodeTime:ac,collectDtsInfo:rc},sc=function(e){for(var t=0,n={payloadType:-1,payloadSize:0},r=0,i=0;t<e.byteLength&&128!==e[t];){for(;255===e[t];)r+=255,t++;for(r+=e[t++];255===e[t];)i+=255,t++;if(i+=e[t++],!n.payload&&4===r){n.payloadType=r,n.payloadSize=i,n.payload=e.subarray(t,t+i);break}t+=i,r=0,i=0}return n},uc=function(e){return 181!==e.payload[0]?null:49!=(e.payload[1]<<8|e.payload[2])?null:"GA94"!==String.fromCharCode(e.payload[3],e.payload[4],e.payload[5],e.payload[6])?null:3!==e.payload[7]?null:e.payload.subarray(8,e.payload.length-1)},lc=function(e,t){var n,r,i,a,o=[];if(!(64&t[0]))return o;for(r=31&t[0],n=0;n<r;n++)i=3*n,a={type:3&t[i+2],pts:e},4&t[i+2]&&(a.ccData=t[i+3]<<8|t[i+4],o.push(a));return o},cc=function(e){for(var t,n,r=e.byteLength,i=[],a=1;a<r-2;)0===e[a]&&0===e[a+1]&&3===e[a+2]?(i.push(a+2),a+=2):a++;if(0===i.length)return e;t=r-i.length,n=new Uint8Array(t);var o=0;for(a=0;a<t;o++,a++)o===i[0]&&(o++,i.shift()),n[a]=e[o];return n},dc={parseSei:sc,parseUserData:uc,parseCaptionPackets:lc,discardEmulationPreventionBytes:cc,USER_DATA_REGISTERED_ITU_T_T35:4},fc=function e(){e.prototype.init.call(this),this.captionPackets_=[],this.ccStreams_=[new gc(0,0),new gc(0,1),new gc(1,0),new gc(1,1)],this.reset(),this.ccStreams_.forEach(function(e){e.on("data",this.trigger.bind(this,"data")),e.on("done",this.trigger.bind(this,"done"))},this)};fc.prototype=new Ml,fc.prototype.push=function(e){var t,n,r;if("sei_rbsp"===e.nalUnitType&&(t=dc.parseSei(e.escapedRBSP),t.payloadType===dc.USER_DATA_REGISTERED_ITU_T_T35&&(n=dc.parseUserData(t)))){if(e.dts<this.latestDts_)return void(this.ignoreNextEqualDts_=!0);if(e.dts===this.latestDts_&&this.ignoreNextEqualDts_)return void(--this.numSameDts_||(this.ignoreNextEqualDts_=!1));r=dc.parseCaptionPackets(e.pts,n),this.captionPackets_=this.captionPackets_.concat(r),this.latestDts_!==e.dts&&(this.numSameDts_=0),this.numSameDts_++,this.latestDts_=e.dts}},fc.prototype.flush=function(){if(!this.captionPackets_.length)return void this.ccStreams_.forEach(function(e){e.flush()},this);this.captionPackets_.forEach(function(e,t){e.presortIndex=t}),this.captionPackets_.sort(function(e,t){return e.pts===t.pts?e.presortIndex-t.presortIndex:e.pts-t.pts}),this.captionPackets_.forEach(function(e){e.type<2&&this.dispatchCea608Packet(e)},this),this.captionPackets_.length=0,this.ccStreams_.forEach(function(e){e.flush()},this)},fc.prototype.reset=function(){this.latestDts_=null,this.ignoreNextEqualDts_=!1,this.numSameDts_=0,this.activeCea608Channel_=[null,null],this.ccStreams_.forEach(function(e){e.reset()})},fc.prototype.dispatchCea608Packet=function(e){this.setsTextOrXDSActive(e)?this.activeCea608Channel_[e.type]=null:this.setsChannel1Active(e)?this.activeCea608Channel_[e.type]=0:this.setsChannel2Active(e)&&(this.activeCea608Channel_[e.type]=1),null!==this.activeCea608Channel_[e.type]&&this.ccStreams_[(e.type<<1)+this.activeCea608Channel_[e.type]].push(e)},fc.prototype.setsChannel1Active=function(e){return 4096==(30720&e.ccData)},fc.prototype.setsChannel2Active=function(e){return 6144==(30720&e.ccData)},fc.prototype.setsTextOrXDSActive=function(e){return 256==(28928&e.ccData)||4138==(30974&e.ccData)||6186==(30974&e.ccData)};var hc={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,304:174,305:176,306:189,307:191,308:8482,309:162,310:163,311:9834,312:224,313:160,314:232,315:226,316:234,317:238,318:244,319:251,544:193,545:201,546:211,547:218,548:220,549:252,550:8216,551:161,552:42,553:39,554:8212,555:169,556:8480,557:8226,558:8220,559:8221,560:192,561:194,562:199,563:200,564:202,565:203,566:235,567:206,568:207,569:239,570:212,571:217,572:249,573:219,574:171,575:187,800:195,801:227,802:205,803:204,804:236,805:210,806:242,807:213,808:245,809:123,810:125,811:92,812:94,813:95,814:124,815:126,816:196,817:228,818:214,819:246,820:223,821:165,822:164,823:9474,824:197,825:229,826:216,827:248,828:9484,829:9488,830:9492,831:9496},pc=function(e){return null===e?"":(e=hc[e]||e,String.fromCharCode(e))},mc=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],vc=function(){for(var e=[],t=15;t--;)e.push("");return e},gc=function e(t,n){e.prototype.init.call(this),this.field_=t||0,this.dataChannel_=n||0,this.name_="CC"+(1+(this.field_<<1|this.dataChannel_)),this.setConstants(),this.reset(),this.push=function(e){var t,n,r,i,a;if((t=32639&e.ccData)===this.lastControlCode_)return void(this.lastControlCode_=null);if(4096==(61440&t)?this.lastControlCode_=t:t!==this.PADDING_&&(this.lastControlCode_=null),r=t>>>8,i=255&t,t!==this.PADDING_)if(t===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(t===this.END_OF_CAPTION_)this.mode_="popOn",this.clearFormatting(e.pts),this.flushDisplayed(e.pts),n=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=n,this.startPts_=e.pts;else if(t===this.ROLL_UP_2_ROWS_)this.rollUpRows_=2,this.setRollUp(e.pts);else if(t===this.ROLL_UP_3_ROWS_)this.rollUpRows_=3,this.setRollUp(e.pts);else if(t===this.ROLL_UP_4_ROWS_)this.rollUpRows_=4,this.setRollUp(e.pts);else if(t===this.CARRIAGE_RETURN_)this.clearFormatting(e.pts),this.flushDisplayed(e.pts),this.shiftRowsUp_(),this.startPts_=e.pts;else if(t===this.BACKSPACE_)"popOn"===this.mode_?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[this.row_]=this.displayed_[this.row_].slice(0,-1);else if(t===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(e.pts),this.displayed_=vc();else if(t===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=vc();else if(t===this.RESUME_DIRECT_CAPTIONING_)"paintOn"!==this.mode_&&(this.flushDisplayed(e.pts),this.displayed_=vc()),this.mode_="paintOn",this.startPts_=e.pts;else if(this.isSpecialCharacter(r,i))r=(3&r)<<8,a=pc(r|i),this[this.mode_](e.pts,a),this.column_++;else if(this.isExtCharacter(r,i))"popOn"===this.mode_?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[this.row_]=this.displayed_[this.row_].slice(0,-1),r=(3&r)<<8,a=pc(r|i),this[this.mode_](e.pts,a),this.column_++;else if(this.isMidRowCode(r,i))this.clearFormatting(e.pts),this[this.mode_](e.pts," "),this.column_++,14==(14&i)&&this.addFormatting(e.pts,["i"]),1==(1&i)&&this.addFormatting(e.pts,["u"]);else if(this.isOffsetControlCode(r,i))this.column_+=3&i;else if(this.isPAC(r,i)){var o=mc.indexOf(7968&t);"rollUp"===this.mode_&&(o-this.rollUpRows_+1<0&&(o=this.rollUpRows_-1),this.setRollUp(e.pts,o)),o!==this.row_&&(this.clearFormatting(e.pts),this.row_=o),1&i&&-1===this.formatting_.indexOf("u")&&this.addFormatting(e.pts,["u"]),16==(16&t)&&(this.column_=4*((14&t)>>1)),this.isColorPAC(i)&&14==(14&i)&&this.addFormatting(e.pts,["i"])}else this.isNormalChar(r)&&(0===i&&(i=null),a=pc(r),a+=pc(i),this[this.mode_](e.pts,a),this.column_+=a.length)}};gc.prototype=new Ml,gc.prototype.flushDisplayed=function(e){var t=this.displayed_.map(function(e){try{return e.trim()}catch(e){return console.error("Skipping malformed caption."),""}}).join("\n").replace(/^\n+|\n+$/g,"");t.length&&this.trigger("data",{startPts:this.startPts_,endPts:e,text:t,stream:this.name_})},gc.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=vc(),this.nonDisplayed_=vc(),this.lastControlCode_=null,this.column_=0,this.row_=14,this.rollUpRows_=2,this.formatting_=[]},gc.prototype.setConstants=function(){0===this.dataChannel_?(this.BASE_=16,this.EXT_=17,this.CONTROL_=(20|this.field_)<<8,this.OFFSET_=23):1===this.dataChannel_&&(this.BASE_=24,this.EXT_=25,this.CONTROL_=(28|this.field_)<<8,this.OFFSET_=31),this.PADDING_=0,this.RESUME_CAPTION_LOADING_=32|this.CONTROL_,this.END_OF_CAPTION_=47|this.CONTROL_,this.ROLL_UP_2_ROWS_=37|this.CONTROL_,this.ROLL_UP_3_ROWS_=38|this.CONTROL_,this.ROLL_UP_4_ROWS_=39|this.CONTROL_,this.CARRIAGE_RETURN_=45|this.CONTROL_,this.RESUME_DIRECT_CAPTIONING_=41|this.CONTROL_,this.BACKSPACE_=33|this.CONTROL_,this.ERASE_DISPLAYED_MEMORY_=44|this.CONTROL_,this.ERASE_NON_DISPLAYED_MEMORY_=46|this.CONTROL_},gc.prototype.isSpecialCharacter=function(e,t){return e===this.EXT_&&t>=48&&t<=63},gc.prototype.isExtCharacter=function(e,t){return(e===this.EXT_+1||e===this.EXT_+2)&&t>=32&&t<=63},gc.prototype.isMidRowCode=function(e,t){return e===this.EXT_&&t>=32&&t<=47},gc.prototype.isOffsetControlCode=function(e,t){return e===this.OFFSET_&&t>=33&&t<=35},gc.prototype.isPAC=function(e,t){return e>=this.BASE_&&e<this.BASE_+8&&t>=64&&t<=127},gc.prototype.isColorPAC=function(e){return e>=64&&e<=79||e>=96&&e<=127},gc.prototype.isNormalChar=function(e){return e>=32&&e<=127},gc.prototype.setRollUp=function(e,t){if("rollUp"!==this.mode_&&(this.row_=14,this.mode_="rollUp",this.flushDisplayed(e),this.nonDisplayed_=vc(),this.displayed_=vc()),void 0!==t&&t!==this.row_)for(var n=0;n<this.rollUpRows_;n++)this.displayed_[t-n]=this.displayed_[this.row_-n],this.displayed_[this.row_-n]="";void 0===t&&(t=this.row_),this.topRow_=t-this.rollUpRows_+1},gc.prototype.addFormatting=function(e,t){this.formatting_=this.formatting_.concat(t);var n=t.reduce(function(e,t){return e+"<"+t+">"},"");this[this.mode_](e,n)},gc.prototype.clearFormatting=function(e){if(this.formatting_.length){var t=this.formatting_.reverse().reduce(function(e,t){return e+"</"+t+">"},"");this.formatting_=[],this[this.mode_](e,t)}},gc.prototype.popOn=function(e,t){var n=this.nonDisplayed_[this.row_];n+=t,this.nonDisplayed_[this.row_]=n},gc.prototype.rollUp=function(e,t){var n=this.displayed_[this.row_];n+=t,this.displayed_[this.row_]=n},gc.prototype.shiftRowsUp_=function(){var e;for(e=0;e<this.topRow_;e++)this.displayed_[e]="";for(e=this.row_+1;e<15;e++)this.displayed_[e]="";for(e=this.topRow_;e<this.row_;e++)this.displayed_[e]=this.displayed_[e+1];this.displayed_[this.row_]=""},gc.prototype.paintOn=function(e,t){var n=this.displayed_[this.row_];n+=t,this.displayed_[this.row_]=n};var yc={CaptionStream:fc,Cea608Stream:gc},_c={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21},bc=function(e,t){var n=1;for(e>t&&(n=-1);Math.abs(t-e)>4294967296;)e+=8589934592*n;return e},Tc=function e(t){var n,r;e.prototype.init.call(this),this.type_=t,this.push=function(e){e.type===this.type_&&(void 0===r&&(r=e.dts),e.dts=bc(e.dts,r),e.pts=bc(e.pts,r),n=e.dts,this.trigger("data",e))},this.flush=function(){r=n,this.trigger("done")},this.discontinuity=function(){r=void 0,n=void 0}};Tc.prototype=new Ml;var Sc,wc={TimestampRolloverStream:Tc,handleRollover:bc},kc=function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i},Ec=function(e,t,n){return decodeURIComponent(kc(e,t,n))},Ac=function(e,t,n){return unescape(kc(e,t,n))},Cc=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},Lc={TXXX:function(e){var t;if(3===e.data[0]){for(t=1;t<e.data.length;t++)if(0===e.data[t]){e.description=Ec(e.data,1,t),e.value=Ec(e.data,t+1,e.data.length).replace(/\0*$/,"");break}e.data=e.value}},WXXX:function(e){var t;if(3===e.data[0])for(t=1;t<e.data.length;t++)if(0===e.data[t]){e.description=Ec(e.data,1,t),e.url=Ec(e.data,t+1,e.data.length);break}},PRIV:function(e){var t;for(t=0;t<e.data.length;t++)if(0===e.data[t]){e.owner=Ac(e.data,0,t);break}e.privateData=e.data.subarray(t+1),e.data=e.privateData}};Sc=function(e){var t,n={debug:!(!e||!e.debug),descriptor:e&&e.descriptor},r=0,i=[],a=0;if(Sc.prototype.init.call(this),this.dispatchType=_c.METADATA_STREAM_TYPE.toString(16),n.descriptor)for(t=0;t<n.descriptor.length;t++)this.dispatchType+=("00"+n.descriptor[t].toString(16)).slice(-2);this.push=function(e){var t,o,s,u,l,c;if("timed-metadata"===e.type){if(e.dataAlignmentIndicator&&(a=0,i.length=0),0===i.length&&(e.data.length<10||e.data[0]!=="I".charCodeAt(0)||e.data[1]!=="D".charCodeAt(0)||e.data[2]!=="3".charCodeAt(0)))return void(n.debug&&console.log("Skipping unrecognized metadata packet"));if(i.push(e),a+=e.data.byteLength,1===i.length&&(r=Cc(e.data.subarray(6,10)),r+=10),!(a<r)){for(t={data:new Uint8Array(r),frames:[],pts:i[0].pts,dts:i[0].dts},l=0;l<r;)t.data.set(i[0].data.subarray(0,r-l),l),l+=i[0].data.byteLength,a-=i[0].data.byteLength,i.shift();o=10,64&t.data[5]&&(o+=4,o+=Cc(t.data.subarray(10,14)),r-=Cc(t.data.subarray(16,20)));do{if((s=Cc(t.data.subarray(o+4,o+8)))<1)return console.log("Malformed ID3 frame encountered. Skipping metadata parsing.");if(c=String.fromCharCode(t.data[o],t.data[o+1],t.data[o+2],t.data[o+3]),u={id:c,data:t.data.subarray(o+10,o+s+10)},u.key=u.id,Lc[u.id]&&(Lc[u.id](u),"com.apple.streaming.transportStreamTimestamp"===u.owner)){var d=u.data,f=(1&d[3])<<30|d[4]<<22|d[5]<<14|d[6]<<6|d[7]>>>2;f*=4,f+=3&d[7],u.timeStamp=f,void 0===t.pts&&void 0===t.dts&&(t.pts=u.timeStamp,t.dts=u.timeStamp),this.trigger("timestamp",u)}t.frames.push(u),o+=10,o+=s}while(o<r);this.trigger("data",t)}}}},Sc.prototype=new Ml;var xc,jc,Oc,Ic=Sc,Pc=wc.TimestampRolloverStream;xc=function(){var e=new Uint8Array(188),t=0;xc.prototype.init.call(this),this.push=function(n){var r,i=0,a=188;for(t?(r=new Uint8Array(n.byteLength+t),r.set(e.subarray(0,t)),r.set(n,t),t=0):r=n;a<r.byteLength;)71!==r[i]||71!==r[a]?(i++,a++):(this.trigger("data",r.subarray(i,a)),i+=188,a+=188);i<r.byteLength&&(e.set(r.subarray(i),0),t=r.byteLength-i)},this.flush=function(){188===t&&71===e[0]&&(this.trigger("data",e),t=0),this.trigger("done")}},xc.prototype=new Ml,jc=function(){var e,t,n,r;jc.prototype.init.call(this),r=this,this.packetsWaitingForPmt=[],this.programMapTable=void 0,e=function(e,r){var i=0;r.payloadUnitStartIndicator&&(i+=e[i]+1),"pat"===r.type?t(e.subarray(i),r):n(e.subarray(i),r)},t=function(e,t){t.section_number=e[7],t.last_section_number=e[8],r.pmtPid=(31&e[10])<<8|e[11],t.pmtPid=r.pmtPid},n=function(e,t){var n,i,a,o;if(1&e[5]){for(r.programMapTable={video:null,audio:null,"timed-metadata":{}},n=(15&e[1])<<8|e[2],i=3+n-4,a=(15&e[10])<<8|e[11],o=12+a;o<i;){var s=e[o],u=(31&e[o+1])<<8|e[o+2];s===_c.H264_STREAM_TYPE&&null===r.programMapTable.video?r.programMapTable.video=u:s===_c.ADTS_STREAM_TYPE&&null===r.programMapTable.audio?r.programMapTable.audio=u:s===_c.METADATA_STREAM_TYPE&&(r.programMapTable["timed-metadata"][u]=s),o+=5+((15&e[o+3])<<8|e[o+4])}t.programMapTable=r.programMapTable}},this.push=function(t){var n={},r=4;if(n.payloadUnitStartIndicator=!!(64&t[1]),n.pid=31&t[1],n.pid<<=8,n.pid|=t[2],(48&t[3])>>>4>1&&(r+=t[r]+1),0===n.pid)n.type="pat",e(t.subarray(r),n),this.trigger("data",n);else if(n.pid===this.pmtPid)for(n.type="pmt",e(t.subarray(r),n),this.trigger("data",n);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else void 0===this.programMapTable?this.packetsWaitingForPmt.push([t,r,n]):this.processPes_(t,r,n)},this.processPes_=function(e,t,n){n.pid===this.programMapTable.video?n.streamType=_c.H264_STREAM_TYPE:n.pid===this.programMapTable.audio?n.streamType=_c.ADTS_STREAM_TYPE:n.streamType=this.programMapTable["timed-metadata"][n.pid],n.type="pes",n.data=e.subarray(t),this.trigger("data",n)}},jc.prototype=new Ml,jc.STREAM_TYPES={h264:27,adts:15},Oc=function(){var e=this,t={data:[],size:0},n={data:[],size:0},r={data:[],size:0},i=function(e,t){var n;t.packetLength=6+(e[4]<<8|e[5]),t.dataAlignmentIndicator=0!=(4&e[6]),n=e[7],192&n&&(t.pts=(14&e[9])<<27|(255&e[10])<<20|(254&e[11])<<12|(255&e[12])<<5|(254&e[13])>>>3,t.pts*=4,t.pts+=(6&e[13])>>>1,t.dts=t.pts,64&n&&(t.dts=(14&e[14])<<27|(255&e[15])<<20|(254&e[16])<<12|(255&e[17])<<5|(254&e[18])>>>3,t.dts*=4,t.dts+=(6&e[18])>>>1)),t.data=e.subarray(9+e[8])},a=function(t,n,r){var a,o=new Uint8Array(t.size),s={type:n},u=0,l=0,c=!1;if(t.data.length&&!(t.size<9)){for(s.trackId=t.data[0].pid,u=0;u<t.data.length;u++)a=t.data[u],o.set(a.data,l),l+=a.data.byteLength;i(o,s),c="video"===n||s.packetLength<=t.size,(r||c)&&(t.size=0,t.data.length=0),c&&e.trigger("data",s)}};Oc.prototype.init.call(this),this.push=function(i){({pat:function(){},pes:function(){var e,o;switch(i.streamType){case _c.H264_STREAM_TYPE:case _c.H264_STREAM_TYPE:e=t,o="video";break;case _c.ADTS_STREAM_TYPE:e=n,o="audio";break;case _c.METADATA_STREAM_TYPE:e=r,o="timed-metadata";break;default:return}i.payloadUnitStartIndicator&&a(e,o,!0),e.data.push(i),e.size+=i.data.byteLength},pmt:function(){var t={type:"metadata",tracks:[]},n=i.programMapTable;null!==n.video&&t.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+n.video,codec:"avc",type:"video"}),null!==n.audio&&t.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+n.audio,codec:"adts",type:"audio"}),e.trigger("data",t)}})[i.type]()},this.flush=function(){a(t,"video"),a(n,"audio"),a(r,"timed-metadata"),this.trigger("done")}},Oc.prototype=new Ml;var Rc={PAT_PID:0,MP2T_PACKET_LENGTH:188,TransportPacketStream:xc,TransportParseStream:jc,ElementaryStream:Oc,TimestampRolloverStream:Pc,CaptionStream:yc.CaptionStream,Cea608Stream:yc.Cea608Stream,MetadataStream:Ic};for(var Dc in _c)_c.hasOwnProperty(Dc)&&(Rc[Dc]=_c[Dc]);var Mc,Uc=Rc,Bc=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];Mc=function(){var e;Mc.prototype.init.call(this),this.push=function(t){var n,r,i,a,o,s,u=0,l=0;if("audio"===t.type)for(e?(a=e,e=new Uint8Array(a.byteLength+t.data.byteLength),e.set(a),e.set(t.data,a.byteLength)):e=t.data;u+5<e.length;)if(255===e[u]&&240==(246&e[u+1])){if(r=2*(1&~e[u+1]),n=(3&e[u+3])<<11|e[u+4]<<3|(224&e[u+5])>>5,o=1024*(1+(3&e[u+6])),s=9e4*o/Bc[(60&e[u+2])>>>2],i=u+n,e.byteLength<i)return;if(this.trigger("data",{pts:t.pts+l*s,dts:t.dts+l*s,sampleCount:o,audioobjecttype:1+(e[u+2]>>>6&3),channelcount:(1&e[u+2])<<2|(192&e[u+3])>>>6,samplerate:Bc[(60&e[u+2])>>>2],samplingfrequencyindex:(60&e[u+2])>>>2,samplesize:16,data:e.subarray(u+7+r,i)}),e.byteLength===i)return void(e=void 0);l++,e=e.subarray(i)}else u++},this.flush=function(){this.trigger("done")}},Mc.prototype=new Ml;var Nc,Fc=Mc;Nc=function(e){var t=e.byteLength,n=0,r=0;this.length=function(){return 8*t},this.bitsAvailable=function(){return 8*t+r},this.loadWord=function(){var i=e.byteLength-t,a=new Uint8Array(4),o=Math.min(4,t);if(0===o)throw new Error("no bytes available");a.set(e.subarray(i,i+o)),n=new DataView(a.buffer).getUint32(0),r=8*o,t-=o},this.skipBits=function(e){var i;r>e?(n<<=e,r-=e):(e-=r,i=Math.floor(e/8),e-=8*i,t-=i,this.loadWord(),n<<=e,r-=e)},this.readBits=function(e){var i=Math.min(r,e),a=n>>>32-i;return r-=i,r>0?n<<=i:t>0&&this.loadWord(),i=e-i,i>0?a<<i|this.readBits(i):a},this.skipLeadingZeros=function(){var e;for(e=0;e<r;++e)if(0!=(n&2147483648>>>e))return n<<=e,r-=e,e;return this.loadWord(),e+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var e=this.skipLeadingZeros();return this.readBits(e+1)-1},this.readExpGolomb=function(){var e=this.readUnsignedExpGolomb();return 1&e?1+e>>>1:-1*(e>>>1)},this.readBoolean=function(){return 1===this.readBits(1)},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()};var Vc,qc,Gc,Hc=Nc;qc=function(){var e,t,n=0;qc.prototype.init.call(this),this.push=function(r){var i;for(t?(i=new Uint8Array(t.byteLength+r.data.byteLength),i.set(t),i.set(r.data,t.byteLength),t=i):t=r.data;n<t.byteLength-3;n++)if(1===t[n+2]){e=n+5;break}for(;e<t.byteLength;)switch(t[e]){case 0:if(0!==t[e-1]){e+=2;break}if(0!==t[e-2]){e++;break}n+3!==e-2&&this.trigger("data",t.subarray(n+3,e-2));do{e++}while(1!==t[e]&&e<t.length);n=e-2,e+=3;break;case 1:if(0!==t[e-1]||0!==t[e-2]){e+=3;break}this.trigger("data",t.subarray(n+3,e-2)),n=e-2,e+=3;break;default:e+=3}t=t.subarray(n),e-=n,n=0},this.flush=function(){t&&t.byteLength>3&&this.trigger("data",t.subarray(n+3)),t=null,n=0,this.trigger("done")}},qc.prototype=new Ml,Gc={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},Vc=function(){var e,t,n,r,i,a,o,s=new qc;Vc.prototype.init.call(this),e=this,this.push=function(e){"video"===e.type&&(t=e.trackId,n=e.pts,r=e.dts,s.push(e))},s.on("data",function(o){var s={trackId:t,pts:n,dts:r,data:o};switch(31&o[0]){case 5:s.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:s.nalUnitType="sei_rbsp",s.escapedRBSP=i(o.subarray(1));break;case 7:s.nalUnitType="seq_parameter_set_rbsp",s.escapedRBSP=i(o.subarray(1)),s.config=a(s.escapedRBSP);break;case 8:s.nalUnitType="pic_parameter_set_rbsp";break;case 9:s.nalUnitType="access_unit_delimiter_rbsp"}e.trigger("data",s)}),s.on("done",function(){e.trigger("done")}),this.flush=function(){s.flush()},o=function(e,t){var n,r,i=8,a=8;for(n=0;n<e;n++)0!==a&&(r=t.readExpGolomb(),a=(i+r+256)%256),i=0===a?i:a},i=function(e){for(var t,n,r=e.byteLength,i=[],a=1;a<r-2;)0===e[a]&&0===e[a+1]&&3===e[a+2]?(i.push(a+2),a+=2):a++;if(0===i.length)return e;t=r-i.length,n=new Uint8Array(t);var o=0;for(a=0;a<t;o++,a++)o===i[0]&&(o++,i.shift()),n[a]=e[o];return n},a=function(e){var t,n,r,i,a,s,u,l,c,d,f,h,p,m=0,v=0,g=0,y=0,_=1;if(t=new Hc(e),n=t.readUnsignedByte(),i=t.readUnsignedByte(),r=t.readUnsignedByte(),t.skipUnsignedExpGolomb(),Gc[n]&&(a=t.readUnsignedExpGolomb(),3===a&&t.skipBits(1),t.skipUnsignedExpGolomb(),t.skipUnsignedExpGolomb(),t.skipBits(1),t.readBoolean()))for(f=3!==a?8:12,p=0;p<f;p++)t.readBoolean()&&(p<6?o(16,t):o(64,t));if(t.skipUnsignedExpGolomb(),0===(s=t.readUnsignedExpGolomb()))t.readUnsignedExpGolomb();else if(1===s)for(t.skipBits(1),t.skipExpGolomb(),t.skipExpGolomb(),u=t.readUnsignedExpGolomb(),p=0;p<u;p++)t.skipExpGolomb();if(t.skipUnsignedExpGolomb(),t.skipBits(1),l=t.readUnsignedExpGolomb(),c=t.readUnsignedExpGolomb(),d=t.readBits(1),0===d&&t.skipBits(1),t.skipBits(1),t.readBoolean()&&(m=t.readUnsignedExpGolomb(),v=t.readUnsignedExpGolomb(),g=t.readUnsignedExpGolomb(),y=t.readUnsignedExpGolomb()),t.readBoolean()&&t.readBoolean()){switch(t.readUnsignedByte()){case 1:h=[1,1];break;case 2:h=[12,11];break;case 3:h=[10,11];break;case 4:h=[16,11];break;case 5:h=[40,33];break;case 6:h=[24,11];break;case 7:h=[20,11];break;case 8:h=[32,11];break;case 9:h=[80,33];break;case 10:h=[18,11];break;case 11:h=[15,11];break;case 12:h=[64,33];break;case 13:h=[160,99];break;case 14:h=[4,3];break;case 15:h=[3,2];break;case 16:h=[2,1];break;case 255:h=[t.readUnsignedByte()<<8|t.readUnsignedByte(),t.readUnsignedByte()<<8|t.readUnsignedByte()]}h&&(_=h[0]/h[1])}return{profileIdc:n,levelIdc:r,profileCompatibility:i,width:Math.ceil((16*(l+1)-2*m-2*v)*_),height:(2-d)*(c+1)*16-2*g-2*y}}},Vc.prototype=new Ml;var zc,Wc={H264Stream:Vc,NalByteStream:qc},$c=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],Yc=function(e){return e[0]==="I".charCodeAt(0)&&e[1]==="D".charCodeAt(0)&&e[2]==="3".charCodeAt(0)},Kc=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},Xc=function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i},Jc=function(e,t,n){return unescape(Xc(e,t,n))},Qc=function(e,t){var n=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9];return(16&e[t+5])>>4?n+20:n+10},Zc=function(e,t){var n=(224&e[t+5])>>5,r=e[t+4]<<3;return 6144&e[t+3]|r|n},ed=function(e,t){return e[t]==="I".charCodeAt(0)&&e[t+1]==="D".charCodeAt(0)&&e[t+2]==="3".charCodeAt(0)?"timed-metadata":!0&e[t]&&240==(240&e[t+1])?"audio":null},td=function(e){for(var t=0;t+5<e.length;){if(255===e[t]&&240==(246&e[t+1]))return $c[(60&e[t+2])>>>2];t++}return null},nd=function(e){var t,n,r;t=10,64&e[5]&&(t+=4,t+=Kc(e.subarray(10,14)));do{if((n=Kc(e.subarray(t+4,t+8)))<1)return null;if("PRIV"===String.fromCharCode(e[t],e[t+1],e[t+2],e[t+3])){r=e.subarray(t+10,t+n+10);for(var i=0;i<r.byteLength;i++)if(0===r[i]){var a=Jc(r,0,i);if("com.apple.streaming.transportStreamTimestamp"===a){var o=r.subarray(i+1),s=(1&o[3])<<30|o[4]<<22|o[5]<<14|o[6]<<6|o[7]>>>2;return s*=4,s+=3&o[7]}break}}t+=10,t+=n}while(t<e.byteLength);return null},rd={isLikelyAacData:Yc,parseId3TagSize:Qc,parseAdtsSize:Zc,parseType:ed,parseSampleRate:td,parseAacTimestamp:nd};zc=function(){var e=new Uint8Array,t=0;zc.prototype.init.call(this),this.setTimestamp=function(e){t=e},this.push=function(n){var r,i,a,o,s=0,u=0;for(e.length?(o=e.length,e=new Uint8Array(n.byteLength+o),e.set(e.subarray(0,o)),e.set(n,o)):e=n;e.length-u>=3;)if(e[u]!=="I".charCodeAt(0)||e[u+1]!=="D".charCodeAt(0)||e[u+2]!=="3".charCodeAt(0))if(255!=(255&e[u])||240!=(240&e[u+1]))u++;else{if(e.length-u<7)break;if(s=rd.parseAdtsSize(e,u),u+s>e.length)break;a={type:"audio",data:e.subarray(u,u+s),pts:t,dts:t},this.trigger("data",a),u+=s}else{if(e.length-u<10)break;if(s=rd.parseId3TagSize(e,u),u+s>e.length)break;i={type:"timed-metadata",data:e.subarray(u,u+s)},this.trigger("data",i),u+=s}r=e.length-u,e=r>0?e.subarray(u):new Uint8Array}},zc.prototype=new Ml;var id,ad,od,sd,ud=zc,ld=Wc.H264Stream,cd=rd.isLikelyAacData,dd=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],fd=["width","height","profileIdc","levelIdc","profileCompatibility"],hd=function(e,t){var n;if(e.length!==t.length)return!1;for(n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0},pd=function(e,t,n,r,i,a){return{start:{dts:e,pts:e+(n-t)},end:{dts:e+(r-t),pts:e+(i-n)},prependedContentDuration:a,baseMediaDecodeTime:e}};ad=function(e,t){var n=[],r=0,i=0,a=0,o=1/0;t=t||{},ad.prototype.init.call(this),this.push=function(t){oc.collectDtsInfo(e,t),e&&dd.forEach(function(n){e[n]=t[n]}),n.push(t)},this.setEarliestDts=function(t){i=t-e.timelineStartInfo.baseMediaDecodeTime},this.setVideoBaseMediaDecodeTime=function(e){o=e},this.setAudioAppendStart=function(e){a=e},this.flush=function(){var s,u,l,c;if(0===n.length)return void this.trigger("done","AudioSegmentStream");s=nc.trimAdtsFramesByEarliestDts(n,e,i),e.baseMediaDecodeTime=oc.calculateTrackBaseMediaDecodeTime(e,t.keepOriginalTimestamps),nc.prefixWithSilence(e,s,a,o),e.samples=nc.generateSampleTable(s),l=Ll.mdat(nc.concatenateFrameData(s)),n=[],u=Ll.moof(r,[e]),c=new Uint8Array(u.byteLength+l.byteLength),r++,c.set(u),c.set(l,u.byteLength),oc.clearDtsInfo(e),this.trigger("data",{track:e,boxes:c}),this.trigger("done","AudioSegmentStream")}},ad.prototype=new Ml,id=function(e,t){var n,r,i=0,a=[],o=[];t=t||{},id.prototype.init.call(this),delete e.minPTS,this.gopCache_=[],this.push=function(t){oc.collectDtsInfo(e,t),"seq_parameter_set_rbsp"!==t.nalUnitType||n||(n=t.config,e.sps=[t.data],fd.forEach(function(t){e[t]=n[t]},this)),"pic_parameter_set_rbsp"!==t.nalUnitType||r||(r=t.data,e.pps=[t.data]),a.push(t)},this.flush=function(){for(var n,r,s,u,l,c,d,f,h=0;a.length&&"access_unit_delimiter_rbsp"!==a[0].nalUnitType;)a.shift();if(0===a.length)return this.resetStream_(),void this.trigger("done","VideoSegmentStream");if(n=Hl.groupNalsIntoFrames(a),s=Hl.groupFramesIntoGops(n),s[0][0].keyFrame||(r=this.getGopForFusion_(a[0],e),r?(h=r.duration,s.unshift(r),s.byteLength+=r.byteLength,s.nalCount+=r.nalCount,s.pts=r.pts,s.dts=r.dts,s.duration+=r.duration):s=Hl.extendFirstKeyFrame(s)),o.length){var p;if(!(p=t.alignGopsAtEnd?this.alignGopsAtEnd_(s):this.alignGopsAtStart_(s)))return this.gopCache_.unshift({gop:s.pop(),pps:e.pps,sps:e.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),a=[],this.resetStream_(),void this.trigger("done","VideoSegmentStream");oc.clearDtsInfo(e),s=p}oc.collectDtsInfo(e,s),e.samples=Hl.generateSampleTable(s),l=Ll.mdat(Hl.concatenateNalData(s)),e.baseMediaDecodeTime=oc.calculateTrackBaseMediaDecodeTime(e,t.keepOriginalTimestamps),this.trigger("processedGopsInfo",s.map(function(e){return{pts:e.pts,dts:e.dts,byteLength:e.byteLength}})),d=s[0],f=s[s.length-1],this.trigger("segmentTimingInfo",pd(e.baseMediaDecodeTime,d.dts,d.pts,f.dts+f.duration,f.pts+f.duration,h)),this.gopCache_.unshift({gop:s.pop(),pps:e.pps,sps:e.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),a=[],this.trigger("baseMediaDecodeTime",e.baseMediaDecodeTime),this.trigger("timelineStartInfo",e.timelineStartInfo),u=Ll.moof(i,[e]),c=new Uint8Array(u.byteLength+l.byteLength),i++,c.set(u),c.set(l,u.byteLength),this.trigger("data",{track:e,boxes:c}),this.resetStream_(),this.trigger("done","VideoSegmentStream")},this.resetStream_=function(){oc.clearDtsInfo(e),n=void 0,r=void 0},this.getGopForFusion_=function(t){var n,r,i,a,o,s=1/0;for(o=0;o<this.gopCache_.length;o++)a=this.gopCache_[o],i=a.gop,e.pps&&hd(e.pps[0],a.pps[0])&&e.sps&&hd(e.sps[0],a.sps[0])&&(i.dts<e.timelineStartInfo.dts||(n=t.dts-i.dts-i.duration)>=-1e4&&n<=45e3&&(!r||s>n)&&(r=a,s=n));return r?r.gop:null},this.alignGopsAtStart_=function(e){var t,n,r,i,a,s,u,l;for(a=e.byteLength,s=e.nalCount,u=e.duration,t=n=0;t<o.length&&n<e.length&&(r=o[t],i=e[n],r.pts!==i.pts);)i.pts>r.pts?t++:(n++,a-=i.byteLength,s-=i.nalCount,u-=i.duration);return 0===n?e:n===e.length?null:(l=e.slice(n),l.byteLength=a,l.duration=u,l.nalCount=s,l.pts=l[0].pts,l.dts=l[0].dts,l)},this.alignGopsAtEnd_=function(e){var t,n,r,i,a,s;for(t=o.length-1,n=e.length-1,a=null,s=!1;t>=0&&n>=0;){if(r=o[t],i=e[n],r.pts===i.pts){s=!0;break}r.pts>i.pts?t--:(t===o.length-1&&(a=n),n--)}if(!s&&null===a)return null;var u;if(0===(u=s?n:a))return e;var l=e.slice(u),c=l.reduce(function(e,t){return e.byteLength+=t.byteLength,e.duration+=t.duration,e.nalCount+=t.nalCount,e},{byteLength:0,duration:0,nalCount:0});return l.byteLength=c.byteLength,l.duration=c.duration,l.nalCount=c.nalCount,l.pts=l[0].pts,l.dts=l[0].dts,l},this.alignGopsWith=function(e){o=e}},id.prototype=new Ml,sd=function(e,t){this.numberOfTracks=0,this.metadataStream=t,e=e||{},void 0!==e.remux?this.remuxTracks=!!e.remux:this.remuxTracks=!0,"boolean"==typeof e.keepOriginalTimestamps&&(this.keepOriginalTimestamps=e.keepOriginalTimestamps),this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,sd.prototype.init.call(this),this.push=function(e){return e.text?this.pendingCaptions.push(e):e.frames?this.pendingMetadata.push(e):(this.pendingTracks.push(e.track),this.pendingBoxes.push(e.boxes),this.pendingBytes+=e.boxes.byteLength,"video"===e.track.type&&(this.videoTrack=e.track),void("audio"===e.track.type&&(this.audioTrack=e.track)))}},sd.prototype=new Ml,sd.prototype.flush=function(e){var t,n,r,i,a=0,o={captions:[],captionStreams:{},metadata:[],info:{}},s=0;if(this.pendingTracks.length<this.numberOfTracks){if("VideoSegmentStream"!==e&&"AudioSegmentStream"!==e)return;if(this.remuxTracks)return;if(0===this.pendingTracks.length)return void(++this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0))}for(this.videoTrack?(s=this.videoTrack.timelineStartInfo.pts,fd.forEach(function(e){o.info[e]=this.videoTrack[e]},this)):this.audioTrack&&(s=this.audioTrack.timelineStartInfo.pts,dd.forEach(function(e){o.info[e]=this.audioTrack[e]},this)),1===this.pendingTracks.length?o.type=this.pendingTracks[0].type:o.type="combined",this.emittedTracks+=this.pendingTracks.length,r=Ll.initSegment(this.pendingTracks),o.initSegment=new Uint8Array(r.byteLength),o.initSegment.set(r),o.data=new Uint8Array(this.pendingBytes),i=0;i<this.pendingBoxes.length;i++)o.data.set(this.pendingBoxes[i],a),a+=this.pendingBoxes[i].byteLength;for(i=0;i<this.pendingCaptions.length;i++)t=this.pendingCaptions[i],t.startTime=t.startPts,this.keepOriginalTimestamps||(t.startTime-=s),t.startTime/=9e4,t.endTime=t.endPts,this.keepOriginalTimestamps||(t.endTime-=s),t.endTime/=9e4,o.captionStreams[t.stream]=!0,o.captions.push(t);for(i=0;i<this.pendingMetadata.length;i++)n=this.pendingMetadata[i],n.cueTime=n.pts,this.keepOriginalTimestamps||(n.cueTime-=s),n.cueTime/=9e4,o.metadata.push(n);o.metadata.dispatchType=this.metadataStream.dispatchType,this.pendingTracks.length=0,this.videoTrack=null,this.pendingBoxes.length=0,this.pendingCaptions.length=0,this.pendingBytes=0,this.pendingMetadata.length=0,this.trigger("data",o),this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},od=function(e){var t,n,r=this,i=!0;od.prototype.init.call(this),e=e||{},this.baseMediaDecodeTime=e.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var t={};this.transmuxPipeline_=t,t.type="aac",t.metadataStream=new Uc.MetadataStream,t.aacStream=new ud,t.audioTimestampRolloverStream=new Uc.TimestampRolloverStream("audio"),t.timedMetadataTimestampRolloverStream=new Uc.TimestampRolloverStream("timed-metadata"),t.adtsStream=new Fc,t.coalesceStream=new sd(e,t.metadataStream),t.headOfPipeline=t.aacStream,t.aacStream.pipe(t.audioTimestampRolloverStream).pipe(t.adtsStream),t.aacStream.pipe(t.timedMetadataTimestampRolloverStream).pipe(t.metadataStream).pipe(t.coalesceStream),t.metadataStream.on("timestamp",function(e){t.aacStream.setTimestamp(e.timeStamp)}),t.aacStream.on("data",function(i){"timed-metadata"!==i.type||t.audioSegmentStream||(n=n||{timelineStartInfo:{baseMediaDecodeTime:r.baseMediaDecodeTime},codec:"adts",type:"audio"},t.coalesceStream.numberOfTracks++,t.audioSegmentStream=new ad(n,e),t.adtsStream.pipe(t.audioSegmentStream).pipe(t.coalesceStream))}),t.coalesceStream.on("data",this.trigger.bind(this,"data")),t.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setupTsPipeline=function(){var i={};this.transmuxPipeline_=i,i.type="ts",i.metadataStream=new Uc.MetadataStream,i.packetStream=new Uc.TransportPacketStream,i.parseStream=new Uc.TransportParseStream,i.elementaryStream=new Uc.ElementaryStream,i.videoTimestampRolloverStream=new Uc.TimestampRolloverStream("video"),i.audioTimestampRolloverStream=new Uc.TimestampRolloverStream("audio"),i.timedMetadataTimestampRolloverStream=new Uc.TimestampRolloverStream("timed-metadata"),i.adtsStream=new Fc,i.h264Stream=new ld,i.captionStream=new Uc.CaptionStream,i.coalesceStream=new sd(e,i.metadataStream),i.headOfPipeline=i.packetStream,i.packetStream.pipe(i.parseStream).pipe(i.elementaryStream),i.elementaryStream.pipe(i.videoTimestampRolloverStream).pipe(i.h264Stream),i.elementaryStream.pipe(i.audioTimestampRolloverStream).pipe(i.adtsStream),i.elementaryStream.pipe(i.timedMetadataTimestampRolloverStream).pipe(i.metadataStream).pipe(i.coalesceStream),i.h264Stream.pipe(i.captionStream).pipe(i.coalesceStream),i.elementaryStream.on("data",function(a){var o;if("metadata"===a.type){for(o=a.tracks.length;o--;)t||"video"!==a.tracks[o].type?n||"audio"!==a.tracks[o].type||(n=a.tracks[o],n.timelineStartInfo.baseMediaDecodeTime=r.baseMediaDecodeTime):(t=a.tracks[o],t.timelineStartInfo.baseMediaDecodeTime=r.baseMediaDecodeTime);t&&!i.videoSegmentStream&&(i.coalesceStream.numberOfTracks++,i.videoSegmentStream=new id(t,e),i.videoSegmentStream.on("timelineStartInfo",function(e){n&&(n.timelineStartInfo=e,i.audioSegmentStream.setEarliestDts(e.dts))}),i.videoSegmentStream.on("processedGopsInfo",r.trigger.bind(r,"gopInfo")),i.videoSegmentStream.on("segmentTimingInfo",r.trigger.bind(r,"videoSegmentTimingInfo")),i.videoSegmentStream.on("baseMediaDecodeTime",function(e){n&&i.audioSegmentStream.setVideoBaseMediaDecodeTime(e)}),i.h264Stream.pipe(i.videoSegmentStream).pipe(i.coalesceStream)),n&&!i.audioSegmentStream&&(i.coalesceStream.numberOfTracks++,i.audioSegmentStream=new ad(n,e),i.adtsStream.pipe(i.audioSegmentStream).pipe(i.coalesceStream))}}),i.coalesceStream.on("data",this.trigger.bind(this,"data")),i.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setBaseMediaDecodeTime=function(r){var i=this.transmuxPipeline_;e.keepOriginalTimestamps||(this.baseMediaDecodeTime=r),n&&(n.timelineStartInfo.dts=void 0,n.timelineStartInfo.pts=void 0,oc.clearDtsInfo(n),e.keepOriginalTimestamps||(n.timelineStartInfo.baseMediaDecodeTime=r),i.audioTimestampRolloverStream&&i.audioTimestampRolloverStream.discontinuity()),t&&(i.videoSegmentStream&&(i.videoSegmentStream.gopCache_=[],i.videoTimestampRolloverStream.discontinuity()),t.timelineStartInfo.dts=void 0,t.timelineStartInfo.pts=void 0,oc.clearDtsInfo(t),i.captionStream.reset(),e.keepOriginalTimestamps||(t.timelineStartInfo.baseMediaDecodeTime=r)),i.timedMetadataTimestampRolloverStream&&i.timedMetadataTimestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(e){n&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(e)},this.alignGopsWith=function(e){t&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(e)},this.push=function(e){if(i){var t=cd(e);t&&"aac"!==this.transmuxPipeline_.type?this.setupAacPipeline():t||"ts"===this.transmuxPipeline_.type||this.setupTsPipeline(),i=!1}this.transmuxPipeline_.headOfPipeline.push(e)},this.flush=function(){i=!0,this.transmuxPipeline_.headOfPipeline.flush()},this.resetCaptions=function(){this.transmuxPipeline_.captionStream&&this.transmuxPipeline_.captionStream.reset()}},od.prototype=new Ml;var md={Transmuxer:od,VideoSegmentStream:id,AudioSegmentStream:ad,AUDIO_PROPERTIES:dd,VIDEO_PROPERTIES:fd,generateVideoSegmentTimingInfo:pd},vd=dc.discardEmulationPreventionBytes,gd=yc.CaptionStream,yd=function(e,t){for(var n=e,r=0;r<t.length;r++){var i=t[r];if(n<i.size)return i;n-=i.size}return null},_d=function(e,t,n){var r,i,a,o,s=new DataView(e.buffer,e.byteOffset,e.byteLength),u=[];for(i=0;i+4<e.length;i+=a)if(a=s.getUint32(i),i+=4,!(a<=0))switch(31&e[i]){case 6:var l=e.subarray(i+1,i+1+a),c=yd(i,t);r={nalUnitType:"sei_rbsp",size:a,data:l,escapedRBSP:vd(l),trackId:n},c?(r.pts=c.pts,r.dts=c.dts,o=c):(r.pts=o.pts,r.dts=o.dts),u.push(r)}return u},bd=function(e,t,n){var r=t,i=n.defaultSampleDuration||0,a=n.defaultSampleSize||0,o=n.trackId,s=[];return e.forEach(function(e){var t=Al.parseTrun(e),n=t.samples;n.forEach(function(e){void 0===e.duration&&(e.duration=i),void 0===e.size&&(e.size=a),e.trackId=o,e.dts=r,void 0===e.compositionTimeOffset&&(e.compositionTimeOffset=0),e.pts=r+e.compositionTimeOffset,r+=e.duration}),s=s.concat(n)}),s},Td=function(e,t){var n=Bu.findBox(e,["moof","traf"]),r=Bu.findBox(e,["mdat"]),i={},a=[];return r.forEach(function(e,t){var r=n[t];a.push({mdat:e,traf:r})}),a.forEach(function(e){var n,r,a=e.mdat,o=e.traf,s=Bu.findBox(o,["tfhd"]),u=Al.parseTfhd(s[0]),l=u.trackId,c=Bu.findBox(o,["tfdt"]),d=c.length>0?Al.parseTfdt(c[0]).baseMediaDecodeTime:0,f=Bu.findBox(o,["trun"]);t===l&&f.length>0&&(n=bd(f,d,u),r=_d(a,n,l),i[l]||(i[l]=[]),i[l]=i[l].concat(r))}),i},Sd=function(e,t,n){var r;return t?(r=Td(e,t),{seiNals:r[t],timescale:n}):null},wd=function(){var e,t,n,r,i,a=!1;this.isInitialized=function(){return a},this.init=function(){e=new gd,a=!0,e.on("data",function(e){e.startTime=e.startPts/r,e.endTime=e.endPts/r,i.captions.push(e),i.captionStreams[e.stream]=!0})},this.isNewInit=function(e,t){return!(e&&0===e.length||t&&"object"==typeof t&&0===Object.keys(t).length||n===e[0]&&r===t[n])},this.parse=function(e,a,o){var s;if(!this.isInitialized())return null;if(!a||!o)return null;if(this.isNewInit(a,o))n=a[0],r=o[n];else if(!n||!r)return t.push(e),null;for(;t.length>0;){var u=t.shift();this.parse(u,a,o)}return null!==(s=Sd(e,n,r))&&s.seiNals?(this.pushNals(s.seiNals),this.flushStream(),i):null},this.pushNals=function(t){if(!this.isInitialized()||!t||0===t.length)return null;t.forEach(function(t){e.push(t)})},this.flushStream=function(){if(!this.isInitialized())return null;e.flush()},this.clearParsedCaptions=function(){i.captions=[],i.captionStreams={}},this.resetCaptionStream=function(){if(!this.isInitialized())return null;e.reset()},this.clearAllCaptions=function(){this.clearParsedCaptions(),this.resetCaptionStream()},this.reset=function(){t=[],n=null,r=null,i?this.clearParsedCaptions():i={captions:[],captionStreams:{}},this.resetCaptionStream()},this.reset()},kd=wd,Ed={generator:Ll,probe:Bu,Transmuxer:md.Transmuxer,AudioSegmentStream:md.AudioSegmentStream,VideoSegmentStream:md.VideoSegmentStream,CaptionParser:kd},Ad=Ed.CaptionParser,Cd=function(e){var t=31&e[1];return t<<=8,t|=e[2]},Ld=function(e){return!!(64&e[1])},xd=function(e){var t=0;return(48&e[3])>>>4>1&&(t+=e[4]+1),t},jd=function(e,t){var n=Cd(e);return 0===n?"pat":n===t?"pmt":t?"pes":null},Od=function(e){var t=Ld(e),n=4+xd(e);return t&&(n+=e[n]+1),(31&e[n+10])<<8|e[n+11]},Id=function(e){var t={},n=Ld(e),r=4+xd(e);if(n&&(r+=e[r]+1),1&e[r+5]){var i,a,o;i=(15&e[r+1])<<8|e[r+2],a=3+i-4,o=(15&e[r+10])<<8|e[r+11];for(var s=12+o;s<a;){var u=r+s;t[(31&e[u+1])<<8|e[u+2]]=e[u],s+=5+((15&e[u+3])<<8|e[u+4])}return t}},Pd=function(e,t){switch(t[Cd(e)]){case _c.H264_STREAM_TYPE:return"video";case _c.ADTS_STREAM_TYPE:return"audio";case _c.METADATA_STREAM_TYPE:return"timed-metadata";default:return null}},Rd=function(e){if(!Ld(e))return null;var t=4+xd(e);if(t>=e.byteLength)return null;var n,r=null;return n=e[t+7],192&n&&(r={},r.pts=(14&e[t+9])<<27|(255&e[t+10])<<20|(254&e[t+11])<<12|(255&e[t+12])<<5|(254&e[t+13])>>>3,r.pts*=4,r.pts+=(6&e[t+13])>>>1,r.dts=r.pts,64&n&&(r.dts=(14&e[t+14])<<27|(255&e[t+15])<<20|(254&e[t+16])<<12|(255&e[t+17])<<5|(254&e[t+18])>>>3,r.dts*=4,r.dts+=(6&e[t+18])>>>1)),r},Dd=function(e){switch(e){case 5:return"slice_layer_without_partitioning_rbsp_idr";case 6:return"sei_rbsp";case 7:return"seq_parameter_set_rbsp";case 8:return"pic_parameter_set_rbsp";case 9:return"access_unit_delimiter_rbsp";default:return null}},Md=function(e){for(var t,n=4+xd(e),r=e.subarray(n),i=0,a=0,o=!1;a<r.byteLength-3;a++)if(1===r[a+2]){i=a+5;break}for(;i<r.byteLength;)switch(r[i]){case 0:if(0!==r[i-1]){i+=2;break}if(0!==r[i-2]){i++;break}a+3!==i-2&&"slice_layer_without_partitioning_rbsp_idr"===(t=Dd(31&r[a+3]))&&(o=!0);do{i++}while(1!==r[i]&&i<r.length);a=i-2,i+=3;break;case 1:if(0!==r[i-1]||0!==r[i-2]){i+=3;break}t=Dd(31&r[a+3]),"slice_layer_without_partitioning_rbsp_idr"===t&&(o=!0),a=i-2,i+=3;break;default:i+=3}return r=r.subarray(a),i-=a,a=0,r&&r.byteLength>3&&"slice_layer_without_partitioning_rbsp_idr"===(t=Dd(31&r[a+3]))&&(o=!0),o},Ud={parseType:jd,parsePat:Od,parsePmt:Id,parsePayloadUnitStartIndicator:Ld,parsePesType:Pd,parsePesTime:Rd,videoPacketContainsKeyFrame:Md},Bd=wc.handleRollover,Nd={};Nd.ts=Ud,Nd.aac=rd;var Fd=function(e,t){for(var n,r=0,i=188;i<e.byteLength;)if(71!==e[r]||71!==e[i])r++,i++;else{switch(n=e.subarray(r,i),Nd.ts.parseType(n,t.pid)){case"pat":t.pid||(t.pid=Nd.ts.parsePat(n));break;case"pmt":t.table||(t.table=Nd.ts.parsePmt(n))}if(t.pid&&t.table)return;r+=188,i+=188}},Vd=function(e,t,n){for(var r,i,a,o,s=0,u=188,l=!1;u<=e.byteLength;)if(71!==e[s]||71!==e[u]&&u!==e.byteLength)s++,u++;else{switch(r=e.subarray(s,u),Nd.ts.parseType(r,t.pid)){case"pes":i=Nd.ts.parsePesType(r,t.table),a=Nd.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(o=Nd.ts.parsePesTime(r))&&(o.type="audio",n.audio.push(o),l=!0)}if(l)break;s+=188,u+=188}for(u=e.byteLength,s=u-188,l=!1;s>=0;)if(71!==e[s]||71!==e[u]&&u!==e.byteLength)s--,u--;else{switch(r=e.subarray(s,u),Nd.ts.parseType(r,t.pid)){case"pes":i=Nd.ts.parsePesType(r,t.table),a=Nd.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(o=Nd.ts.parsePesTime(r))&&(o.type="audio",n.audio.push(o),l=!0)}if(l)break;s-=188,u-=188}},qd=function(e,t,n){for(var r,i,a,o,s,u,l,c=0,d=188,f=!1,h={data:[],size:0};d<e.byteLength;)if(71!==e[c]||71!==e[d])c++,d++;else{switch(r=e.subarray(c,d),Nd.ts.parseType(r,t.pid)){case"pes":if(i=Nd.ts.parsePesType(r,t.table),a=Nd.ts.parsePayloadUnitStartIndicator(r),"video"===i&&(a&&!f&&(o=Nd.ts.parsePesTime(r))&&(o.type="video",n.video.push(o),f=!0),!n.firstKeyFrame)){if(a&&0!==h.size){for(s=new Uint8Array(h.size),u=0;h.data.length;)l=h.data.shift(),s.set(l,u),u+=l.byteLength;if(Nd.ts.videoPacketContainsKeyFrame(s)){var p=Nd.ts.parsePesTime(s);p?(n.firstKeyFrame=p,n.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}h.size=0}h.data.push(r),h.size+=r.byteLength}}if(f&&n.firstKeyFrame)break;c+=188,d+=188}for(d=e.byteLength,c=d-188,f=!1;c>=0;)if(71!==e[c]||71!==e[d])c--,d--;else{switch(r=e.subarray(c,d),Nd.ts.parseType(r,t.pid)){case"pes":i=Nd.ts.parsePesType(r,t.table),a=Nd.ts.parsePayloadUnitStartIndicator(r),"video"===i&&a&&(o=Nd.ts.parsePesTime(r))&&(o.type="video",n.video.push(o),f=!0)}if(f)break;c-=188,d-=188}},Gd=function(e,t){if(e.audio&&e.audio.length){var n=t;void 0===n&&(n=e.audio[0].dts),e.audio.forEach(function(e){e.dts=Bd(e.dts,n),e.pts=Bd(e.pts,n),e.dtsTime=e.dts/9e4,e.ptsTime=e.pts/9e4})}if(e.video&&e.video.length){var r=t;if(void 0===r&&(r=e.video[0].dts),e.video.forEach(function(e){e.dts=Bd(e.dts,r),e.pts=Bd(e.pts,r),e.dtsTime=e.dts/9e4,e.ptsTime=e.pts/9e4}),e.firstKeyFrame){var i=e.firstKeyFrame;i.dts=Bd(i.dts,r),i.pts=Bd(i.pts,r),i.dtsTime=i.dts/9e4,i.ptsTime=i.dts/9e4}}},Hd=function(e){for(var t,n=!1,r=0,i=null,a=null,o=0,s=0;e.length-s>=3;){switch(Nd.aac.parseType(e,s)){case"timed-metadata":if(e.length-s<10){n=!0;break}if((o=Nd.aac.parseId3TagSize(e,s))>e.length){n=!0;break}null===a&&(t=e.subarray(s,s+o),a=Nd.aac.parseAacTimestamp(t)),s+=o;break;case"audio":if(e.length-s<7){n=!0;break}if((o=Nd.aac.parseAdtsSize(e,s))>e.length){n=!0;break}null===i&&(t=e.subarray(s,s+o),i=Nd.aac.parseSampleRate(t)),r++,s+=o;break;default:s++}if(n)return null}if(null===i||null===a)return null;var u=9e4/i;return{audio:[{type:"audio",dts:a,pts:a},{type:"audio",dts:a+1024*r*u,pts:a+1024*r*u}]}},zd=function(e){var t={pid:null,table:null},n={};Fd(e,t);for(var r in t.table)if(t.table.hasOwnProperty(r)){var i=t.table[r];switch(i){case _c.H264_STREAM_TYPE:n.video=[],qd(e,t,n),0===n.video.length&&delete n.video;break;case _c.ADTS_STREAM_TYPE:n.audio=[],Vd(e,t,n),0===n.audio.length&&delete n.audio}}return n},Wd=function(e,t){var n;return(n=Nd.aac.isLikelyAacData(e)?Hd(e):zd(e))&&(n.audio||n.video)?(Gd(n,t),n):null},$d={inspect:Wd,parseAudioPes_:Vd},Yd=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},Kd=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),Xd=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)},Jd=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t},Qd=function(){var e=[[[],[],[],[],[]],[[],[],[],[],[]]],t=e[0],n=e[1],r=t[4],i=n[4],a=void 0,o=void 0,s=void 0,u=[],l=[],c=void 0,d=void 0,f=void 0,h=void 0,p=void 0,m=void 0;for(a=0;a<256;a++)l[(u[a]=a<<1^283*(a>>7))^a]=a;for(o=s=0;!r[o];o^=c||1,s=l[s]||1)for(h=s^s<<1^s<<2^s<<3^s<<4,h=h>>8^255&h^99,r[o]=h,i[h]=o,f=u[d=u[c=u[o]]],m=16843009*f^65537*d^257*c^16843008*o,p=257*u[h]^16843008*h,a=0;a<4;a++)t[a][o]=p=p<<24^p>>>8,n[a][h]=m=m<<24^m>>>8;for(a=0;a<5;a++)t[a]=t[a].slice(0),n[a]=n[a].slice(0);return e},Zd=null,ef=function(){function e(t){Yd(this,e),Zd||(Zd=Qd()),this._tables=[[Zd[0][0].slice(),Zd[0][1].slice(),Zd[0][2].slice(),Zd[0][3].slice(),Zd[0][4].slice()],[Zd[1][0].slice(),Zd[1][1].slice(),Zd[1][2].slice(),Zd[1][3].slice(),Zd[1][4].slice()]];var n=void 0,r=void 0,i=void 0,a=void 0,o=void 0,s=this._tables[0][4],u=this._tables[1],l=t.length,c=1;if(4!==l&&6!==l&&8!==l)throw new Error("Invalid aes key size");for(a=t.slice(0),o=[],this._key=[a,o],n=l;n<4*l+28;n++)i=a[n-1],(n%l==0||8===l&&n%l==4)&&(i=s[i>>>24]<<24^s[i>>16&255]<<16^s[i>>8&255]<<8^s[255&i],n%l==0&&(i=i<<8^i>>>24^c<<24,c=c<<1^283*(c>>7))),a[n]=a[n-l]^i;for(r=0;n;r++,n--)i=a[3&r?n:n-4],o[r]=n<=4||r<4?i:u[0][s[i>>>24]]^u[1][s[i>>16&255]]^u[2][s[i>>8&255]]^u[3][s[255&i]]}return e.prototype.decrypt=function(e,t,n,r,i,a){var o=this._key[1],s=e^o[0],u=r^o[1],l=n^o[2],c=t^o[3],d=void 0,f=void 0,h=void 0,p=o.length/4-2,m=void 0,v=4,g=this._tables[1],y=g[0],_=g[1],b=g[2],T=g[3],S=g[4];for(m=0;m<p;m++)d=y[s>>>24]^_[u>>16&255]^b[l>>8&255]^T[255&c]^o[v],f=y[u>>>24]^_[l>>16&255]^b[c>>8&255]^T[255&s]^o[v+1],h=y[l>>>24]^_[c>>16&255]^b[s>>8&255]^T[255&u]^o[v+2],c=y[c>>>24]^_[s>>16&255]^b[u>>8&255]^T[255&l]^o[v+3],v+=4,s=d,u=f,l=h;for(m=0;m<4;m++)i[(3&-m)+a]=S[s>>>24]<<24^S[u>>16&255]<<16^S[l>>8&255]<<8^S[255&c]^o[v++],d=s,s=u,u=l,l=c,c=d},e}(),tf=function(){function e(){Yd(this,e),this.listeners={}}return e.prototype.on=function(e,t){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push(t)},e.prototype.off=function(e,t){if(!this.listeners[e])return!1;var n=this.listeners[e].indexOf(t);return this.listeners[e].splice(n,1),n>-1},e.prototype.trigger=function(e){var t=this.listeners[e];if(t)if(2===arguments.length)for(var n=t.length,r=0;r<n;++r)t[r].call(this,arguments[1]);else for(var i=Array.prototype.slice.call(arguments,1),a=t.length,o=0;o<a;++o)t[o].apply(this,i)},e.prototype.dispose=function(){this.listeners={}},e.prototype.pipe=function(e){this.on("data",function(t){e.push(t)})},e}(),nf=function(e){function t(){Yd(this,t);var n=Jd(this,e.call(this,tf));return n.jobs=[],n.delay=1,n.timeout_=null,n}return Xd(t,e),t.prototype.processJob_=function(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null},t.prototype.push=function(e){this.jobs.push(e),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))},t}(tf),rf=function(e){return e<<24|(65280&e)<<8|(16711680&e)>>8|e>>>24},af=function(e,t,n){var r=new Int32Array(e.buffer,e.byteOffset,e.byteLength>>2),i=new ef(Array.prototype.slice.call(t)),a=new Uint8Array(e.byteLength),o=new Int32Array(a.buffer),s=void 0,u=void 0,l=void 0,c=void 0,d=void 0,f=void 0,h=void 0,p=void 0,m=void 0;for(s=n[0],u=n[1],l=n[2],c=n[3],m=0;m<r.length;m+=4)d=rf(r[m]),f=rf(r[m+1]),h=rf(r[m+2]),p=rf(r[m+3]),i.decrypt(d,f,h,p,o,m),o[m]=rf(o[m]^s),o[m+1]=rf(o[m+1]^u),o[m+2]=rf(o[m+2]^l),o[m+3]=rf(o[m+3]^c),s=d,u=f,l=h,c=p;return a},of=function(){function e(t,n,r,i){Yd(this,e);var a=e.STEP,o=new Int32Array(t.buffer),s=new Uint8Array(t.byteLength),u=0;for(this.asyncStream_=new nf,this.asyncStream_.push(this.decryptChunk_(o.subarray(u,u+a),n,r,s)),u=a;u<o.length;u+=a)r=new Uint32Array([rf(o[u-4]),rf(o[u-3]),rf(o[u-2]),rf(o[u-1])]),this.asyncStream_.push(this.decryptChunk_(o.subarray(u,u+a),n,r,s));this.asyncStream_.push(function(){i(null,ht(s))})}return e.prototype.decryptChunk_=function(e,t,n,r){return function(){var i=af(e,t,n);r.set(i,e.byteOffset)}},Kd(e,null,[{key:"STEP",get:function(){return 32e3}}]),e}(),sf=function(t,n){return/^[a-z]+:/i.test(n)?n:(/\/\//i.test(t)||(t=As.buildAbsoluteURL(e.location.href,t)),As.buildAbsoluteURL(t,n))},uf=function(e,t,n){return e&&n.responseURL&&t!==n.responseURL?n.responseURL:t},lf=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},cf=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),df=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},ff=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)},hf=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t},pf=function(){function e(e,t){var n=[],r=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(r=(o=s.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){i=!0,a=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw a}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),mf=ut.mergeOptions,vf=ut.EventTarget,gf=ut.log,yf=function(e,t){["AUDIO","SUBTITLES"].forEach(function(n){for(var r in e.mediaGroups[n])for(var i in e.mediaGroups[n][r]){var a=e.mediaGroups[n][r][i];t(a,n,r,i)}})},_f=function(e,t,n){var r=t.slice();n=n||0;for(var i=Math.min(e.length,t.length+n),a=n;a<i;a++)r[a-n]=mf(e[a],r[a-n]);return r},bf=function(e,t){e.resolvedUri||(e.resolvedUri=sf(t,e.uri)),e.key&&!e.key.resolvedUri&&(e.key.resolvedUri=sf(t,e.key.uri)),e.map&&!e.map.resolvedUri&&(e.map.resolvedUri=sf(t,e.map.uri))},Tf=function(e,t){var n=mf(e,{}),r=n.playlists[t.uri];if(!r)return null;if(r.segments&&t.segments&&r.segments.length===t.segments.length&&r.endList===t.endList&&r.mediaSequence===t.mediaSequence)return null;var i=mf(r,t);r.segments&&(i.segments=_f(r.segments,t.segments,t.mediaSequence-r.mediaSequence)),i.segments.forEach(function(e){bf(e,i.resolvedUri)});for(var a=0;a<n.playlists.length;a++)n.playlists[a].uri===t.uri&&(n.playlists[a]=i);return n.playlists[t.uri]=i,n},Sf=function(e){for(var t=e.playlists.length;t--;){var n=e.playlists[t];e.playlists[n.uri]=n,n.resolvedUri=sf(e.uri,n.uri),n.id=t,n.attributes||(n.attributes={},gf.warn("Invalid playlist STREAM-INF detected. Missing BANDWIDTH attribute."))}},wf=function(e){yf(e,function(t){t.uri&&(t.resolvedUri=sf(e.uri,t.uri))})},kf=function(e,t){var n=e.segments[e.segments.length-1];return t&&n&&n.duration?1e3*n.duration:500*(e.targetDuration||10)},Ef=function(t){function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};lf(this,n);var i=hf(this,(n.__proto__||Object.getPrototypeOf(n)).call(this)),a=r.withCredentials,o=void 0!==a&&a,s=r.handleManifestRedirects,u=void 0!==s&&s;i.srcUrl=e,i.hls_=t,i.withCredentials=o,i.handleManifestRedirects=u;var l=t.options_;if(i.customTagParsers=l&&l.customTagParsers||[],i.customTagMappers=l&&l.customTagMappers||[],!i.srcUrl)throw new Error("A non-empty playlist URL is required");return i.state="HAVE_NOTHING",i.on("mediaupdatetimeout",function(){"HAVE_METADATA"===i.state&&(i.state="HAVE_CURRENT_METADATA",i.request=i.hls_.xhr({uri:sf(i.master.uri,i.media().uri),withCredentials:i.withCredentials},function(e,t){if(i.request)return e?i.playlistRequestError(i.request,i.media().uri,"HAVE_METADATA"):void i.haveMetadata(i.request,i.media().uri)}))}),i}return ff(n,t),cf(n,[{key:"playlistRequestError",value:function(e,t,n){this.request=null,n&&(this.state=n),this.error={playlist:this.master.playlists[t],status:e.status,message:"HLS playlist request error at URL: "+t+".",responseText:e.responseText,code:e.status>=500?4:2},this.trigger("error")}},{key:"haveMetadata",value:function(t,n){var r=this;this.request=null,this.state="HAVE_METADATA";var i=new Is;this.customTagParsers.forEach(function(e){return i.addParser(e)}),this.customTagMappers.forEach(function(e){return i.addTagMapper(e)}),i.push(t.responseText),i.end(),i.manifest.uri=n,i.manifest.attributes=i.manifest.attributes||{};var a=Tf(this.master,i.manifest);this.targetDuration=i.manifest.targetDuration,a?(this.master=a,this.media_=this.master.playlists[i.manifest.uri]):this.trigger("playlistunchanged"),this.media().endList||(e.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=e.setTimeout(function(){r.trigger("mediaupdatetimeout")},kf(this.media(),!!a))),this.trigger("loadedplaylist")}},{key:"dispose",value:function(){this.stopRequest(),e.clearTimeout(this.mediaUpdateTimeout),e.clearTimeout(this.finalRenditionTimeout)}},{key:"stopRequest",value:function(){if(this.request){var e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}},{key:"media",value:function(t,n){var r=this;if(!t)return this.media_;if("HAVE_NOTHING"===this.state)throw new Error("Cannot switch media playlist from "+this.state);if("string"==typeof t){if(!this.master.playlists[t])throw new Error("Unknown playlist URI: "+t);t=this.master.playlists[t]}if(e.clearTimeout(this.finalRenditionTimeout),n){var i=t.targetDuration/2*1e3||5e3;return void(this.finalRenditionTimeout=e.setTimeout(this.media.bind(this,t,!1),i))}var a=this.state,o=!this.media_||t.uri!==this.media_.uri;if(this.master.playlists[t.uri].endList)return this.request&&(this.request.onreadystatechange=null,this.request.abort(),this.request=null),this.state="HAVE_METADATA",this.media_=t,void(o&&(this.trigger("mediachanging"),this.trigger("mediachange")));if(o){if(this.state="SWITCHING_MEDIA",this.request){if(t.resolvedUri===this.request.url)return;this.request.onreadystatechange=null,this.request.abort(),this.request=null}this.media_&&this.trigger("mediachanging"),this.request=this.hls_.xhr({uri:t.resolvedUri,withCredentials:this.withCredentials},function(e,n){if(r.request){if(t.resolvedUri=uf(r.handleManifestRedirects,t.resolvedUri,n),e)return r.playlistRequestError(r.request,t.uri,a);r.haveMetadata(n,t.uri),"HAVE_MASTER"===a?r.trigger("loadedmetadata"):r.trigger("mediachange")}})}}},{key:"pause",value:function(){this.stopRequest(),e.clearTimeout(this.mediaUpdateTimeout),"HAVE_NOTHING"===this.state&&(this.started=!1),"SWITCHING_MEDIA"===this.state?this.media_?this.state="HAVE_METADATA":this.state="HAVE_MASTER":"HAVE_CURRENT_METADATA"===this.state&&(this.state="HAVE_METADATA")}},{key:"load",value:function(t){var n=this;e.clearTimeout(this.mediaUpdateTimeout);var r=this.media();if(t){var i=r?r.targetDuration/2*1e3:5e3;return void(this.mediaUpdateTimeout=e.setTimeout(function(){return n.load()},i))}if(!this.started)return void this.start();r&&!r.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist")}},{key:"start",value:function(){var t=this;this.started=!0,this.request=this.hls_.xhr({uri:this.srcUrl,withCredentials:this.withCredentials},function(n,r){if(t.request){if(t.request=null,n)return t.error={status:r.status,message:"HLS playlist request error at URL: "+t.srcUrl+".",responseText:r.responseText,code:2},"HAVE_NOTHING"===t.state&&(t.started=!1),t.trigger("error");var i=new Is;return t.customTagParsers.forEach(function(e){return i.addParser(e)}),t.customTagMappers.forEach(function(e){return i.addTagMapper(e)}),i.push(r.responseText),i.end(),t.state="HAVE_MASTER",t.srcUrl=uf(t.handleManifestRedirects,t.srcUrl,r),i.manifest.uri=t.srcUrl,i.manifest.playlists?(t.master=i.manifest,Sf(t.master),wf(t.master),t.trigger("loadedplaylist"),void(t.request||t.media(i.manifest.playlists[0]))):(t.master={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:e.location.href,playlists:[{uri:t.srcUrl,id:0,resolvedUri:t.srcUrl,attributes:{}}]},t.master.playlists[t.srcUrl]=t.master.playlists[0],t.haveMetadata(r,t.srcUrl),t.trigger("loadedmetadata"))}})}}]),n}(vf),Af=ut.createTimeRange,Cf=function(e,t){var n=0,r=t-e.mediaSequence,i=e.segments[r];if(i){if(void 0!==i.start)return{result:i.start,precise:!0};if(void 0!==i.end)return{result:i.end-i.duration,precise:!0}}for(;r--;){if(i=e.segments[r],void 0!==i.end)return{result:n+i.end,precise:!0};if(n+=i.duration,void 0!==i.start)return{result:n+i.start,precise:!0}}return{result:n,precise:!1}},Lf=function(e,t){for(var n=0,r=void 0,i=t-e.mediaSequence;i<e.segments.length;i++){if(r=e.segments[i],void 0!==r.start)return{result:r.start-n,precise:!0};if(n+=r.duration,void 0!==r.end)return{result:r.end-n,precise:!0}}return{result:-1,precise:!1}},xf=function(e,t,n){var r=void 0,i=void 0;return void 0===t&&(t=e.mediaSequence+e.segments.length),t<e.mediaSequence?0:(r=Cf(e,t),r.precise?r.result:(i=Lf(e,t),i.precise?i.result:r.result+n))},jf=function(t,n,r){if(!t)return 0;if("number"!=typeof r&&(r=0),void 0===n){if(t.totalDuration)return t.totalDuration;if(!t.endList)return e.Infinity}return xf(t,n,r)},Of=function(e,t,n){var r=0;if(t>n){var i=[n,t];t=i[0],n=i[1]}if(t<0){for(var a=t;a<Math.min(0,n);a++)r+=e.targetDuration;t=0}for(var o=t;o<n;o++)r+=e.segments[o].duration;return r},If=function(e){if(!e.segments.length)return 0;for(var t=e.segments.length-1,n=e.segments[t].duration||e.targetDuration,r=n+2*e.targetDuration;t--&&!((n+=e.segments[t].duration)>=r););return Math.max(0,t)},Pf=function(e,t,n){if(!e||!e.segments)return null;if(e.endList)return jf(e);if(null===t)return null;t=t||0;var r=n?If(e):e.segments.length;return xf(e,e.mediaSequence+r,t)},Rf=function(e,t){var n=t||0,r=Pf(e,t,!0);return null===r?Af():Af(n,r)},Df=function(e){return e-Math.floor(e)==0},Mf=function(e,t){if(Df(t))return t+.1*e;for(var n=t.toString().split(".")[1].length,r=1;r<=n;r++){var i=Math.pow(10,r),a=t*i;if(Df(a)||r===n)return(a+e)/i}},Uf=Mf.bind(null,1),Bf=Mf.bind(null,-1),Nf=function(e,t,n,r){var i=void 0,a=void 0,o=e.segments.length,s=t-r;if(s<0){if(n>0)for(i=n-1;i>=0;i--)if(a=e.segments[i],(s+=Bf(a.duration))>0)return{mediaIndex:i,startTime:r-Of(e,n,i)};return{mediaIndex:0,startTime:t}}if(n<0){for(i=n;i<0;i++)if((s-=e.targetDuration)<0)return{mediaIndex:0,startTime:t};n=0}for(i=n;i<o;i++)if(a=e.segments[i],(s-=Uf(a.duration))<0)return{mediaIndex:i,startTime:r+Of(e,n,i)};return{mediaIndex:o-1,startTime:t}},Ff=function(e){return e.excludeUntil&&e.excludeUntil>Date.now()},Vf=function(e){return e.excludeUntil&&e.excludeUntil===1/0},qf=function(e){var t=Ff(e);return!e.disabled&&!t},Gf=function(e){return e.disabled},Hf=function(e){for(var t=0;t<e.segments.length;t++)if(e.segments[t].key)return!0;return!1},zf=function(e){for(var t=0;t<e.segments.length;t++)if(e.segments[t].map)return!0;return!1},Wf=function(e,t){return t.attributes&&t.attributes[e]},$f=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;return Wf("BANDWIDTH",n)?(e*n.attributes.BANDWIDTH-8*r)/t:NaN},Yf=function(e,t){if(1===e.playlists.length)return!0;var n=t.attributes.BANDWIDTH||Number.MAX_VALUE;return 0===e.playlists.filter(function(e){return!!qf(e)&&(e.attributes.BANDWIDTH||0)<n}).length},Kf={duration:jf,seekable:Rf,safeLiveIndex:If,getMediaInfoForTime:Nf,isEnabled:qf,isDisabled:Gf,isBlacklisted:Ff,isIncompatible:Vf,playlistEnd:Pf,isAes:Hf,isFmp4:zf,hasAttribute:Wf,estimateSegmentRequestTime:$f,isLowestEnabledRendition:Yf},Xf=ut.xhr,Jf=ut.mergeOptions,Qf=function(){return function e(t,n){t=Jf({timeout:45e3},t);var r=e.beforeRequest||ut.Hls.xhr.beforeRequest;if(r&&"function"==typeof r){var i=r(t);i&&(t=i)}var a=Xf(t,function(e,t){var r=a.response;!e&&r&&(a.responseTime=Date.now(),a.roundTripTime=a.responseTime-a.requestTime,a.bytesReceived=r.byteLength||r.length,a.bandwidth||(a.bandwidth=Math.floor(a.bytesReceived/a.roundTripTime*8*1e3))),t.headers&&(a.responseHeaders=t.headers),e&&"ETIMEDOUT"===e.code&&(a.timedout=!0),e||a.aborted||200===t.statusCode||206===t.statusCode||0===t.statusCode||(e=new Error("XHR Failed with a response of: "+(a&&(r||a.responseText)))),n(e,a)}),o=a.abort;return a.abort=function(){return a.aborted=!0,o.apply(a,arguments)},a.uri=t.uri,a.requestTime=Date.now(),a}},Zf=function(e){var t=void 0;return t=e.offset+e.length-1,"bytes="+e.offset+"-"+t},eh=function(e){var t={};return e.byterange&&(t.Range=Zf(e.byterange)),t},th=function(e,t){return e.start(t)+"-"+e.end(t)},nh=function(e,t){var n=e.toString(16);return"00".substring(0,2-n.length)+n+(t%2?" ":"")},rh=function(e){return e>=32&&e<126?String.fromCharCode(e):"."},ih=function(e){var t={};return Object.keys(e).forEach(function(n){var r=e[n];ArrayBuffer.isView(r)?t[n]={bytes:r.buffer,byteOffset:r.byteOffset,byteLength:r.byteLength}:t[n]=r}),t},ah=function(e){var t=e.byterange||{length:1/0,offset:0};return[t.length,t.offset,e.resolvedUri].join(",")},oh=function(e){return e.resolvedUri},sh=function(e){for(var t=Array.prototype.slice.call(e),n="",r=void 0,i=void 0,a=0;a<t.length/16;a++)r=t.slice(16*a,16*a+16).map(nh).join(""),i=t.slice(16*a,16*a+16).map(rh).join(""),n+=r+" "+i+"\n";return n},uh=function(e){var t=e.bytes;return sh(t)},lh=function(e){var t="",n=void 0;for(n=0;n<e.length;n++)t+=th(e,n)+" ";return t},ch=Object.freeze({createTransferableMessage:ih,initSegmentId:ah,segmentKeyId:oh,hexDump:sh,tagDump:uh,textRanges:lh}),dh=function(e,t){if(!t.dateTimeObject)return null;var n=t.videoTimingInfo.transmuxerPrependedSeconds,r=t.videoTimingInfo.transmuxedPresentationStart,i=r+n,a=e-i;return new Date(t.dateTimeObject.getTime()+1e3*a)},fh=function(e){return e.transmuxedPresentationEnd-e.transmuxedPresentationStart-e.transmuxerPrependedSeconds},hh=function(e,t){var n=void 0;try{n=new Date(e)}catch(e){return null}if(!t||!t.segments||0===t.segments.length)return null;var r=t.segments[0];if(n<r.dateTimeObject)return null;for(var i=0;i<t.segments.length-1&&(r=t.segments[i],!(n<t.segments[i+1].dateTimeObject));i++);var a=t.segments[t.segments.length-1],o=a.dateTimeObject,s=a.videoTimingInfo?fh(a.videoTimingInfo):a.duration+.25*a.duration;return n>new Date(o.getTime()+1e3*s)?null:(n>o&&(r=a),{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:Kf.duration(t,t.mediaSequence+t.segments.indexOf(r)),type:r.videoTimingInfo?"accurate":"estimate"})},ph=function(e,t){if(!t||!t.segments||0===t.segments.length)return null;for(var n=0,r=void 0,i=0;i<t.segments.length&&(r=t.segments[i],n=r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationEnd:n+r.duration,!(e<=n));i++);var a=t.segments[t.segments.length-1];if(a.videoTimingInfo&&a.videoTimingInfo.transmuxedPresentationEnd<e)return null;if(e>n){if(e>n+.25*a.duration)return null;r=a}return{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:n-r.duration,type:r.videoTimingInfo?"accurate":"estimate"}},mh=function(e,t){var n=void 0,r=void 0;try{n=new Date(e),r=new Date(t)}catch(e){}var i=n.getTime();return(r.getTime()-i)/1e3},vh=function(e){if(!e.segments||0===e.segments.length)return!1;for(var t=0;t<e.segments.length;t++)if(!e.segments[t].dateTimeObject)return!1;return!0},gh=function(e){var t=e.playlist,n=e.time,r=void 0===n?void 0:n,i=e.callback;if(!i)throw new Error("getProgramTime: callback must be provided");if(!t||void 0===r)return i({message:"getProgramTime: playlist and time must be provided"});var a=ph(r,t);if(!a)return i({message:"valid programTime was not found"});if("estimate"===a.type)return i({message:"Accurate programTime could not be determined. Please seek to e.seekTime and try again",seekTime:a.estimatedStart});var o={mediaSeconds:r},s=dh(r,a.segment);return s&&(o.programDateTime=s.toISOString()),i(null,o)},yh=function e(t){var n=t.programTime,r=t.playlist,i=t.retryCount,a=void 0===i?2:i,o=t.seekTo,s=t.pauseAfterSeek,u=void 0===s||s,l=t.tech,c=t.callback;if(!c)throw new Error("seekToProgramTime: callback must be provided");if(void 0===n||!r||!o)return c({message:"seekToProgramTime: programTime, seekTo and playlist must be provided"});if(!r.endList&&!l.hasStarted_)return c({message:"player must be playing a live stream to start buffering"});if(!vh(r))return c({message:"programDateTime tags must be provided in the manifest "+r.resolvedUri});var d=hh(n,r);if(!d)return c({message:n+" was not found in the stream"});var f=d.segment,h=mh(f.dateTimeObject,n);if("estimate"===d.type)return 0===a?c({message:n+" is not buffered yet. Try again"}):(o(d.estimatedStart+h),void l.one("seeked",function(){e({programTime:n,playlist:r,retryCount:a-1,seekTo:o,pauseAfterSeek:u,tech:l,callback:c})}));var p=f.start+h,m=function(){return c(null,l.currentTime())};l.one("seeked",m),u&&l.pause(),o(p)},_h=function(e,t){var n=[],r=void 0;if(e&&e.length)for(r=0;r<e.length;r++)t(e.start(r),e.end(r))&&n.push([e.start(r),e.end(r)]);return ut.createTimeRanges(n)},bh=function(e,t){return _h(e,function(e,n){return e-1/30<=t&&n+1/30>=t})},Th=function(e,t){return _h(e,function(e){return e-1/30>=t})},Sh=function(e){if(e.length<2)return ut.createTimeRanges();for(var t=[],n=1;n<e.length;n++){var r=e.end(n-1),i=e.start(n);t.push([r,i])}return ut.createTimeRanges(t)},wh=function(e){var t=[];if(!e||!e.length)return"";for(var n=0;n<e.length;n++)t.push(e.start(n)+" => "+e.end(n));return t.join(", ")},kh=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return((e.length?e.end(e.length-1):0)-t)/n},Eh=function(e){for(var t=[],n=0;n<e.length;n++)t.push({start:e.start(n),end:e.end(n)});return t},Ah=function(e,t,n){var r=t.player_;if(n.captions&&n.captions.length){e.inbandTextTracks_||(e.inbandTextTracks_={});for(var i in n.captionStreams)if(!e.inbandTextTracks_[i]){r.tech_.trigger({type:"usage",name:"hls-608"});var a=r.textTracks().getTrackById(i);e.inbandTextTracks_[i]=a||r.addRemoteTextTrack({kind:"captions",id:i,label:i},!1).track}}n.metadata&&n.metadata.length&&!e.metadataTrack_&&(e.metadataTrack_=r.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,e.metadataTrack_.inBandMetadataTrackDispatchType=n.metadata.dispatchType)},Ch=function(e,t,n){var r=void 0,i=void 0;if(n&&n.cues)for(r=n.cues.length;r--;)i=n.cues[r],i.startTime<=t&&i.endTime>=e&&n.removeCue(i)},Lh=function(e){Object.defineProperties(e.frame,{id:{get:function(){return ut.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),e.value.key}},value:{get:function(){return ut.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),e.value.data}},privateData:{get:function(){return ut.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),e.value.data}}})},xh=function(e){return isNaN(e)||Math.abs(e)===1/0?Number.MAX_VALUE:e},jh=function(t,n,r){var i=e.WebKitDataCue||e.VTTCue;if(n&&n.forEach(function(e){var t=e.stream;this.inbandTextTracks_[t].addCue(new i(e.startTime+this.timestampOffset,e.endTime+this.timestampOffset,e.text))},t),r){var a=xh(t.mediaSource_.duration);if(r.forEach(function(t){var n=t.cueTime+this.timestampOffset;!("number"!=typeof n||e.isNaN(n)||n<0)&&n<1/0&&t.frames.forEach(function(e){var t=new i(n,n,e.value||e.url||e.data||"");t.frame=e,t.value=e,Lh(t),this.metadataTrack_.addCue(t)},this)},t),t.metadataTrack_&&t.metadataTrack_.cues&&t.metadataTrack_.cues.length){for(var o=t.metadataTrack_.cues,s=[],u=0;u<o.length;u++)o[u]&&s.push(o[u]);var l=s.reduce(function(e,t){var n=e[t.startTime]||[];return n.push(t),e[t.startTime]=n,e},{}),c=Object.keys(l).sort(function(e,t){return Number(e)-Number(t)});c.forEach(function(e,t){var n=l[e],r=Number(c[t+1])||a;n.forEach(function(e){e.endTime=r})})}}},Oh="undefined"!=typeof window?window:{},Ih="undefined"==typeof Symbol?"__target":Symbol(),Ph="application/javascript",Rh=Oh.BlobBuilder||Oh.WebKitBlobBuilder||Oh.MozBlobBuilder||Oh.MSBlobBuilder,Dh=Oh.URL||Oh.webkitURL||Dh&&Dh.msURL,Mh=Oh.Worker;if(Mh){var Uh,Bh=mt("self.onmessage = function () {}"),Nh=new Uint8Array(1);try{Uh=new Mh(Bh),Uh.postMessage(Nh,[Nh.buffer])}catch(e){Mh=null}finally{Dh.revokeObjectURL(Bh),Uh&&Uh.terminate()}}var Fh=new pt("./transmuxer-worker.worker.js",function(e,t){var n=this;!function(){var e,t,r,i,a,o,s,u,l,c,d,f,h,p,m,v,g,y,_,b,T,S,w,k,E,A,C,L,x,j,O,I,P,R,D,M,U=Math.pow(2,32)-1;!function(){var e;if(w={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],sdtp:[],smhd:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],styp:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[]},"undefined"!=typeof Uint8Array){for(e in w)w.hasOwnProperty(e)&&(w[e]=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)]);k=new Uint8Array(["i".charCodeAt(0),"s".charCodeAt(0),"o".charCodeAt(0),"m".charCodeAt(0)]),A=new Uint8Array(["a".charCodeAt(0),"v".charCodeAt(0),"c".charCodeAt(0),"1".charCodeAt(0)]),E=new Uint8Array([0,0,0,1]),C=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),L=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),x={video:C,audio:L},I=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),O=new Uint8Array([0,0,0,0,0,0,0,0]),P=new Uint8Array([0,0,0,0,0,0,0,0]),R=P,D=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),M=P,j=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}}(),e=function(e){var t,n,r,i=[],a=0;for(t=1;t<arguments.length;t++)i.push(arguments[t]);for(t=i.length;t--;)a+=i[t].byteLength;for(n=new Uint8Array(a+8),r=new DataView(n.buffer,n.byteOffset,n.byteLength),r.setUint32(0,n.byteLength),n.set(e,4),t=0,a=8;t<i.length;t++)n.set(i[t],a),a+=i[t].byteLength;return n},t=function(){return e(w.dinf,e(w.dref,I))},r=function(t){return e(w.esds,new Uint8Array([0,0,0,0,3,25,0,0,0,4,17,64,21,0,6,0,0,0,218,192,0,0,218,192,5,2,t.audioobjecttype<<3|t.samplingfrequencyindex>>>1,t.samplingfrequencyindex<<7|t.channelcount<<3,6,1,2]))},i=function(){return e(w.ftyp,k,E,k,A)},v=function(t){return e(w.hdlr,x[t])},a=function(t){return e(w.mdat,t)},m=function(t){var n=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,t.duration>>>24&255,t.duration>>>16&255,t.duration>>>8&255,255&t.duration,85,196,0,0]);return t.samplerate&&(n[12]=t.samplerate>>>24&255,n[13]=t.samplerate>>>16&255,n[14]=t.samplerate>>>8&255,n[15]=255&t.samplerate),e(w.mdhd,n)},p=function(t){return e(w.mdia,m(t),v(t.type),s(t))},o=function(t){return e(w.mfhd,new Uint8Array([0,0,0,0,(4278190080&t)>>24,(16711680&t)>>16,(65280&t)>>8,255&t]))},s=function(n){return e(w.minf,"video"===n.type?e(w.vmhd,j):e(w.smhd,O),t(),y(n))},u=function(t,n){for(var r=[],i=n.length;i--;)r[i]=b(n[i]);return e.apply(null,[w.moof,o(t)].concat(r))},l=function(t){for(var n=t.length,r=[];n--;)r[n]=f(t[n]);return e.apply(null,[w.moov,d(4294967295)].concat(r).concat(c(t)))},c=function(t){for(var n=t.length,r=[];n--;)r[n]=T(t[n]);return e.apply(null,[w.mvex].concat(r))},d=function(t){var n=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(4278190080&t)>>24,(16711680&t)>>16,(65280&t)>>8,255&t,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return e(w.mvhd,n)},g=function(t){var n,r,i=t.samples||[],a=new Uint8Array(4+i.length);for(r=0;r<i.length;r++)n=i[r].flags,a[r+4]=n.dependsOn<<4|n.isDependedOn<<2|n.hasRedundancy;return e(w.sdtp,a)},y=function(t){return e(w.stbl,_(t),e(w.stts,M),e(w.stsc,R),e(w.stsz,D),e(w.stco,P))},function(){var t,n;_=function(r){return e(w.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),"video"===r.type?t(r):n(r))},t=function(t){var n,r=t.sps||[],i=t.pps||[],a=[],o=[];for(n=0;n<r.length;n++)a.push((65280&r[n].byteLength)>>>8),a.push(255&r[n].byteLength),a=a.concat(Array.prototype.slice.call(r[n]));for(n=0;n<i.length;n++)o.push((65280&i[n].byteLength)>>>8),o.push(255&i[n].byteLength),o=o.concat(Array.prototype.slice.call(i[n]));return e(w.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,(65280&t.width)>>8,255&t.width,(65280&t.height)>>8,255&t.height,0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),e(w.avcC,new Uint8Array([1,t.profileIdc,t.profileCompatibility,t.levelIdc,255].concat([r.length]).concat(a).concat([i.length]).concat(o))),e(w.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])))},n=function(t){return e(w.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(65280&t.channelcount)>>8,255&t.channelcount,(65280&t.samplesize)>>8,255&t.samplesize,0,0,0,0,(65280&t.samplerate)>>8,255&t.samplerate,0,0]),r(t))}}(),h=function(t){var n=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(4278190080&t.id)>>24,(16711680&t.id)>>16,(65280&t.id)>>8,255&t.id,0,0,0,0,(4278190080&t.duration)>>24,(16711680&t.duration)>>16,(65280&t.duration)>>8,255&t.duration,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,(65280&t.width)>>8,255&t.width,0,0,(65280&t.height)>>8,255&t.height,0,0]);return e(w.tkhd,n)},b=function(t){var n,r,i,a,o,s,u;return n=e(w.tfhd,new Uint8Array([0,0,0,58,(4278190080&t.id)>>24,(16711680&t.id)>>16,(65280&t.id)>>8,255&t.id,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),s=Math.floor(t.baseMediaDecodeTime/(U+1)),u=Math.floor(t.baseMediaDecodeTime%(U+1)),r=e(w.tfdt,new Uint8Array([1,0,0,0,s>>>24&255,s>>>16&255,s>>>8&255,255&s,u>>>24&255,u>>>16&255,u>>>8&255,255&u])),o=92,"audio"===t.type?(i=S(t,o),e(w.traf,n,r,i)):(a=g(t),i=S(t,a.length+o),e(w.traf,n,r,i,a))},f=function(t){return t.duration=t.duration||4294967295,e(w.trak,h(t),p(t))},T=function(t){var n=new Uint8Array([0,0,0,0,(4278190080&t.id)>>24,(16711680&t.id)>>16,(65280&t.id)>>8,255&t.id,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return"video"!==t.type&&(n[n.length-1]=0),e(w.trex,n)},function(){var t,n,r;r=function(e,t){var n=0,r=0,i=0,a=0;return e.length&&(void 0!==e[0].duration&&(n=1),void 0!==e[0].size&&(r=2),void 0!==e[0].flags&&(i=4),void 0!==e[0].compositionTimeOffset&&(a=8)),[0,0,n|r|i|a,1,(4278190080&e.length)>>>24,(16711680&e.length)>>>16,(65280&e.length)>>>8,255&e.length,(4278190080&t)>>>24,(16711680&t)>>>16,(65280&t)>>>8,255&t]},n=function(t,n){var i,a,o,s;for(a=t.samples||[],n+=20+16*a.length,i=r(a,n),s=0;s<a.length;s++)o=a[s],i=i.concat([(4278190080&o.duration)>>>24,(16711680&o.duration)>>>16,(65280&o.duration)>>>8,255&o.duration,(4278190080&o.size)>>>24,(16711680&o.size)>>>16,(65280&o.size)>>>8,255&o.size,o.flags.isLeading<<2|o.flags.dependsOn,o.flags.isDependedOn<<6|o.flags.hasRedundancy<<4|o.flags.paddingValue<<1|o.flags.isNonSyncSample,61440&o.flags.degradationPriority,15&o.flags.degradationPriority,(4278190080&o.compositionTimeOffset)>>>24,(16711680&o.compositionTimeOffset)>>>16,(65280&o.compositionTimeOffset)>>>8,255&o.compositionTimeOffset]);return e(w.trun,new Uint8Array(i))},t=function(t,n){var i,a,o,s;for(a=t.samples||[],n+=20+8*a.length,i=r(a,n),s=0;s<a.length;s++)o=a[s],i=i.concat([(4278190080&o.duration)>>>24,(16711680&o.duration)>>>16,(65280&o.duration)>>>8,255&o.duration,(4278190080&o.size)>>>24,(16711680&o.size)>>>16,(65280&o.size)>>>8,255&o.size]);return e(w.trun,new Uint8Array(i))},S=function(e,r){return"audio"===e.type?t(e,r):n(e,r)}}();var B,N,F,V,q,G={ftyp:i,mdat:a,moof:u,moov:l,initSegment:function(e){var t,n=i(),r=l(e);return t=new Uint8Array(n.byteLength+r.byteLength),t.set(n),t.set(r,n.byteLength),t}},H=function(e){return e>>>0},z={toUnsigned:H},W=z.toUnsigned;B=function(e,t){var n,r,i,a,o,s=[];if(!t.length)return null;for(n=0;n<e.byteLength;)r=W(e[n]<<24|e[n+1]<<16|e[n+2]<<8|e[n+3]),i=N(e.subarray(n+4,n+8)),a=r>1?n+r:e.byteLength,i===t[0]&&(1===t.length?s.push(e.subarray(n+8,a)):(o=B(e.subarray(n+8,a),t.slice(1)),o.length&&(s=s.concat(o)))),n=a;return s},N=function(e){var t="";return t+=String.fromCharCode(e[0]),t+=String.fromCharCode(e[1]),t+=String.fromCharCode(e[2]),t+=String.fromCharCode(e[3])},F=function(e){var t={};return B(e,["moov","trak"]).reduce(function(e,t){var n,r,i,a,o;return(n=B(t,["tkhd"])[0])?(r=n[0],i=0===r?12:20,a=W(n[i]<<24|n[i+1]<<16|n[i+2]<<8|n[i+3]),(o=B(t,["mdia","mdhd"])[0])?(r=o[0],i=0===r?12:20,e[a]=W(o[i]<<24|o[i+1]<<16|o[i+2]<<8|o[i+3]),e):null):null},t)},V=function(e,t){var n,r,i;return n=B(t,["moof","traf"]),r=[].concat.apply([],n.map(function(t){return B(t,["tfhd"]).map(function(n){var r,i,a;return r=W(n[4]<<24|n[5]<<16|n[6]<<8|n[7]),i=e[r]||9e4,a=B(t,["tfdt"]).map(function(e){var t,n;return t=e[0],n=W(e[4]<<24|e[5]<<16|e[6]<<8|e[7]),1===t&&(n*=Math.pow(2,32),n+=W(e[8]<<24|e[9]<<16|e[10]<<8|e[11])),n})[0],(a=a||1/0)/i})})),i=Math.min.apply(null,r),isFinite(i)?i:0},q=function(e){var t=B(e,["moov","trak"]),n=[];return t.forEach(function(e){var t=B(e,["mdia","hdlr"]),r=B(e,["tkhd"]);t.forEach(function(e,t){var i,a,o,s=N(e.subarray(8,12)),u=r[t];"vide"===s&&(i=new DataView(u.buffer,u.byteOffset,u.byteLength),a=i.getUint8(0),o=0===a?i.getUint32(12):i.getUint32(20),n.push(o))})}),n};var $={findBox:B,parseType:N,timescale:F,startTime:V,videoTrackIds:q},Y=function(){this.init=function(){var e={};this.on=function(t,n){e[t]||(e[t]=[]),e[t]=e[t].concat(n)},this.off=function(t,n){var r;return!!e[t]&&(r=e[t].indexOf(n),e[t]=e[t].slice(),e[t].splice(r,1),r>-1)},this.trigger=function(t){var n,r,i,a;if(n=e[t])if(2===arguments.length)for(i=n.length,r=0;r<i;++r)n[r].call(this,arguments[1]);else{for(a=[],r=arguments.length,r=1;r<arguments.length;++r)a.push(arguments[r]);for(i=n.length,r=0;r<i;++r)n[r].apply(this,a)}},this.dispose=function(){e={}}}};Y.prototype.pipe=function(e){return this.on("data",function(t){e.push(t)}),this.on("done",function(t){e.flush(t)}),e},Y.prototype.push=function(e){this.trigger("data",e)},Y.prototype.flush=function(e){this.trigger("done",e)};var K,X,J,Q,Z,ee,te=Y,ne=function(e){var t,n,r=[],i=[];for(r.byteLength=0,t=0;t<e.length;t++)n=e[t],"access_unit_delimiter_rbsp"===n.nalUnitType?(r.length&&(r.duration=n.dts-r.dts,i.push(r)),r=[n],r.byteLength=n.data.byteLength,r.pts=n.pts,r.dts=n.dts):("slice_layer_without_partitioning_rbsp_idr"===n.nalUnitType&&(r.keyFrame=!0),r.duration=n.dts-r.dts,r.byteLength+=n.data.byteLength,r.push(n));return i.length&&(!r.duration||r.duration<=0)&&(r.duration=i[i.length-1].duration),i.push(r),i},re=function(e){var t,n,r=[],i=[];for(r.byteLength=0,r.nalCount=0,r.duration=0,r.pts=e[0].pts,r.dts=e[0].dts,i.byteLength=0,i.nalCount=0,i.duration=0,i.pts=e[0].pts,i.dts=e[0].dts,t=0;t<e.length;t++)n=e[t],n.keyFrame?(r.length&&(i.push(r),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.duration+=r.duration),r=[n],r.nalCount=n.length,r.byteLength=n.byteLength,r.pts=n.pts,r.dts=n.dts,r.duration=n.duration):(r.duration+=n.duration,r.nalCount+=n.length,r.byteLength+=n.byteLength,r.push(n));return i.length&&r.duration<=0&&(r.duration=i[i.length-1].duration),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.duration+=r.duration,i.push(r),i},ie=function(e){var t;return!e[0][0].keyFrame&&e.length>1&&(t=e.shift(),e.byteLength-=t.byteLength,e.nalCount-=t.nalCount,e[0][0].dts=t.dts,e[0][0].pts=t.pts,e[0][0].duration+=t.duration),e},ae=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}}},oe=function(e,t){var n=ae();return n.dataOffset=t,n.compositionTimeOffset=e.pts-e.dts,n.duration=e.duration,n.size=4*e.length,n.size+=e.byteLength,e.keyFrame&&(n.flags.dependsOn=2,n.flags.isNonSyncSample=0),n},se=function(e,t){var n,r,i,a,o,s=t||0,u=[];for(n=0;n<e.length;n++)for(a=e[n],r=0;r<a.length;r++)o=a[r],i=oe(o,s),s+=i.size,u.push(i);return u},ue=function(e){var t,n,r,i,a,o,s=0,u=e.byteLength,l=e.nalCount,c=u+4*l,d=new Uint8Array(c),f=new DataView(d.buffer);for(t=0;t<e.length;t++)for(i=e[t],n=0;n<i.length;n++)for(a=i[n],r=0;r<a.length;r++)o=a[r],f.setUint32(s,o.data.byteLength),s+=4,d.set(o.data,s),s+=o.data.byteLength;return d},le={groupNalsIntoFrames:ne,groupFramesIntoGops:re,extendFirstKeyFrame:ie,generateSampleTable:se,concatenateNalData:ue},ce=[33,16,5,32,164,27],de=[33,65,108,84,1,2,4,8,168,2,4,8,17,191,252],fe=function(e){for(var t=[];e--;)t.push(0);return t},he={96e3:[ce,[227,64],fe(154),[56]],88200:[ce,[231],fe(170),[56]],64e3:[ce,[248,192],fe(240),[56]],48e3:[ce,[255,192],fe(268),[55,148,128],fe(54),[112]],44100:[ce,[255,192],fe(268),[55,163,128],fe(84),[112]],32e3:[ce,[255,192],fe(268),[55,234],fe(226),[112]],24e3:[ce,[255,192],fe(268),[55,255,128],fe(268),[111,112],fe(126),[224]],16e3:[ce,[255,192],fe(268),[55,255,128],fe(268),[111,255],fe(269),[223,108],fe(195),[1,192]],12e3:[de,fe(268),[3,127,248],fe(268),[6,255,240],fe(268),[13,255,224],fe(268),[27,253,128],fe(259),[56]],11025:[de,fe(268),[3,127,248],fe(268),[6,255,240],fe(268),[13,255,224],fe(268),[27,255,192],fe(268),[55,175,128],fe(108),[112]],8e3:[de,fe(268),[3,121,16],fe(47),[7]]},pe=function(e){return Object.keys(e).reduce(function(t,n){return t[n]=new Uint8Array(e[n].reduce(function(e,t){return e.concat(t)},[])),t},{})}(he);K=function(e){return 9e4*e},X=function(e,t){return e*t},J=function(e){return e/9e4},Q=function(e,t){return e/t},Z=function(e,t){return K(Q(e,t))},ee=function(e,t){return X(J(e),t)};var me={secondsToVideoTs:K,secondsToAudioTs:X,videoTsToSeconds:J,audioTsToSeconds:Q,audioTsToVideoTs:Z,videoTsToAudioTs:ee},ve=function(e){var t,n,r=0;for(t=0;t<e.length;t++)n=e[t],r+=n.data.byteLength;return r},ge=function(e,t,n,r){var i,a,o,s=0,u=0,l=0,c=0;if(t.length&&(i=me.audioTsToVideoTs(e.baseMediaDecodeTime,e.samplerate),s=Math.ceil(9e4/(e.samplerate/1024)),n&&r&&(u=i-Math.max(n,r),l=Math.floor(u/s),c=l*s),!(l<1||c>45e3))){for(a=pe[e.samplerate],a||(a=t[0].data),o=0;o<l;o++)t.splice(o,0,{data:a});e.baseMediaDecodeTime-=Math.floor(me.videoTsToAudioTs(c,e.samplerate))}},ye=function(e,t,n){return t.minSegmentDts>=n?e:(t.minSegmentDts=1/0,e.filter(function(e){return e.dts>=n&&(t.minSegmentDts=Math.min(t.minSegmentDts,e.dts),t.minSegmentPts=t.minSegmentDts,!0)}))},_e=function(e){var t,n,r=[];for(t=0;t<e.length;t++)n=e[t],r.push({size:n.data.byteLength,duration:1024});return r},be=function(e){var t,n,r=0,i=new Uint8Array(ve(e));for(t=0;t<e.length;t++)n=e[t],i.set(n.data,r),r+=n.data.byteLength;return i},Te={prefixWithSilence:ge,trimAdtsFramesByEarliestDts:ye,generateSampleTable:_e,concatenateFrameData:be},Se=function(e,t){"number"==typeof t.pts&&(void 0===e.timelineStartInfo.pts&&(e.timelineStartInfo.pts=t.pts),void 0===e.minSegmentPts?e.minSegmentPts=t.pts:e.minSegmentPts=Math.min(e.minSegmentPts,t.pts),void 0===e.maxSegmentPts?e.maxSegmentPts=t.pts:e.maxSegmentPts=Math.max(e.maxSegmentPts,t.pts)),"number"==typeof t.dts&&(void 0===e.timelineStartInfo.dts&&(e.timelineStartInfo.dts=t.dts),void 0===e.minSegmentDts?e.minSegmentDts=t.dts:e.minSegmentDts=Math.min(e.minSegmentDts,t.dts),void 0===e.maxSegmentDts?e.maxSegmentDts=t.dts:e.maxSegmentDts=Math.max(e.maxSegmentDts,t.dts))},we=function(e){delete e.minSegmentDts,delete e.maxSegmentDts,delete e.minSegmentPts,delete e.maxSegmentPts},ke=function(e,t){var n,r,i=e.minSegmentDts;return t||(i-=e.timelineStartInfo.dts),n=e.timelineStartInfo.baseMediaDecodeTime,n+=i,n=Math.max(0,n),"audio"===e.type&&(r=e.samplerate/9e4,n*=r,n=Math.floor(n)),n},Ee={clearDtsInfo:we,calculateTrackBaseMediaDecodeTime:ke,collectDtsInfo:Se},Ae=function(e){for(var t=0,n={payloadType:-1,payloadSize:0},r=0,i=0;t<e.byteLength&&128!==e[t];){for(;255===e[t];)r+=255,t++;for(r+=e[t++];255===e[t];)i+=255,t++;if(i+=e[t++],!n.payload&&4===r){n.payloadType=r,n.payloadSize=i,n.payload=e.subarray(t,t+i);break}t+=i,r=0,i=0}return n},Ce=function(e){return 181!==e.payload[0]?null:49!=(e.payload[1]<<8|e.payload[2])?null:"GA94"!==String.fromCharCode(e.payload[3],e.payload[4],e.payload[5],e.payload[6])?null:3!==e.payload[7]?null:e.payload.subarray(8,e.payload.length-1)},Le=function(e,t){var n,r,i,a,o=[];if(!(64&t[0]))return o;for(r=31&t[0],n=0;n<r;n++)i=3*n,a={type:3&t[i+2],pts:e},4&t[i+2]&&(a.ccData=t[i+3]<<8|t[i+4],o.push(a));return o},xe=function(e){for(var t,n,r=e.byteLength,i=[],a=1;a<r-2;)0===e[a]&&0===e[a+1]&&3===e[a+2]?(i.push(a+2),a+=2):a++;if(0===i.length)return e;t=r-i.length,n=new Uint8Array(t);var o=0;for(a=0;a<t;o++,a++)o===i[0]&&(o++,i.shift()),n[a]=e[o];return n},je={parseSei:Ae,parseUserData:Ce,parseCaptionPackets:Le,discardEmulationPreventionBytes:xe,USER_DATA_REGISTERED_ITU_T_T35:4},Oe=function e(){e.prototype.init.call(this),this.captionPackets_=[],this.ccStreams_=[new Me(0,0),new Me(0,1),new Me(1,0),new Me(1,1)],this.reset(),this.ccStreams_.forEach(function(e){e.on("data",this.trigger.bind(this,"data")),e.on("done",this.trigger.bind(this,"done"))},this)};Oe.prototype=new te,Oe.prototype.push=function(e){var t,n,r;if("sei_rbsp"===e.nalUnitType&&(t=je.parseSei(e.escapedRBSP),t.payloadType===je.USER_DATA_REGISTERED_ITU_T_T35&&(n=je.parseUserData(t)))){if(e.dts<this.latestDts_)return void(this.ignoreNextEqualDts_=!0);if(e.dts===this.latestDts_&&this.ignoreNextEqualDts_)return void(--this.numSameDts_||(this.ignoreNextEqualDts_=!1));r=je.parseCaptionPackets(e.pts,n),this.captionPackets_=this.captionPackets_.concat(r),this.latestDts_!==e.dts&&(this.numSameDts_=0),this.numSameDts_++,this.latestDts_=e.dts}},Oe.prototype.flush=function(){if(!this.captionPackets_.length)return void this.ccStreams_.forEach(function(e){e.flush()},this);this.captionPackets_.forEach(function(e,t){e.presortIndex=t}),this.captionPackets_.sort(function(e,t){return e.pts===t.pts?e.presortIndex-t.presortIndex:e.pts-t.pts}),this.captionPackets_.forEach(function(e){e.type<2&&this.dispatchCea608Packet(e)},this),this.captionPackets_.length=0,this.ccStreams_.forEach(function(e){e.flush()},this)},Oe.prototype.reset=function(){this.latestDts_=null,this.ignoreNextEqualDts_=!1,this.numSameDts_=0,this.activeCea608Channel_=[null,null],this.ccStreams_.forEach(function(e){e.reset()})},Oe.prototype.dispatchCea608Packet=function(e){this.setsTextOrXDSActive(e)?this.activeCea608Channel_[e.type]=null:this.setsChannel1Active(e)?this.activeCea608Channel_[e.type]=0:this.setsChannel2Active(e)&&(this.activeCea608Channel_[e.type]=1),null!==this.activeCea608Channel_[e.type]&&this.ccStreams_[(e.type<<1)+this.activeCea608Channel_[e.type]].push(e)},Oe.prototype.setsChannel1Active=function(e){return 4096==(30720&e.ccData)},Oe.prototype.setsChannel2Active=function(e){return 6144==(30720&e.ccData)},Oe.prototype.setsTextOrXDSActive=function(e){return 256==(28928&e.ccData)||4138==(30974&e.ccData)||6186==(30974&e.ccData)};var Ie={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,304:174,305:176,306:189,307:191,308:8482,309:162,310:163,311:9834,312:224,313:160,314:232,315:226,316:234,317:238,318:244,319:251,544:193,545:201,546:211,547:218,548:220,549:252,550:8216,551:161,552:42,553:39,554:8212,555:169,556:8480,557:8226,558:8220,559:8221,560:192,561:194,562:199,563:200,564:202,565:203,566:235,567:206,568:207,569:239,570:212,571:217,572:249,573:219,574:171,575:187,800:195,801:227,802:205,803:204,804:236,805:210,806:242,807:213,808:245,809:123,810:125,811:92,812:94,813:95,814:124,815:126,816:196,817:228,818:214,819:246,820:223,821:165,822:164,823:9474,824:197,825:229,826:216,827:248,828:9484,829:9488,830:9492,831:9496},Pe=function(e){return null===e?"":(e=Ie[e]||e,String.fromCharCode(e))},Re=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],De=function(){for(var e=[],t=15;t--;)e.push("");return e},Me=function e(t,n){e.prototype.init.call(this),this.field_=t||0,this.dataChannel_=n||0,this.name_="CC"+(1+(this.field_<<1|this.dataChannel_)),this.setConstants(),this.reset(),this.push=function(e){var t,n,r,i,a;if((t=32639&e.ccData)===this.lastControlCode_)return void(this.lastControlCode_=null);if(4096==(61440&t)?this.lastControlCode_=t:t!==this.PADDING_&&(this.lastControlCode_=null),r=t>>>8,i=255&t,t!==this.PADDING_)if(t===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(t===this.END_OF_CAPTION_)this.mode_="popOn",this.clearFormatting(e.pts),this.flushDisplayed(e.pts),n=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=n,this.startPts_=e.pts;else if(t===this.ROLL_UP_2_ROWS_)this.rollUpRows_=2,this.setRollUp(e.pts);else if(t===this.ROLL_UP_3_ROWS_)this.rollUpRows_=3,this.setRollUp(e.pts);else if(t===this.ROLL_UP_4_ROWS_)this.rollUpRows_=4,this.setRollUp(e.pts);else if(t===this.CARRIAGE_RETURN_)this.clearFormatting(e.pts),this.flushDisplayed(e.pts),this.shiftRowsUp_(),this.startPts_=e.pts;else if(t===this.BACKSPACE_)"popOn"===this.mode_?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[this.row_]=this.displayed_[this.row_].slice(0,-1);else if(t===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(e.pts),this.displayed_=De();else if(t===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=De();else if(t===this.RESUME_DIRECT_CAPTIONING_)"paintOn"!==this.mode_&&(this.flushDisplayed(e.pts),this.displayed_=De()),this.mode_="paintOn",this.startPts_=e.pts;else if(this.isSpecialCharacter(r,i))r=(3&r)<<8,a=Pe(r|i),this[this.mode_](e.pts,a),this.column_++;else if(this.isExtCharacter(r,i))"popOn"===this.mode_?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[this.row_]=this.displayed_[this.row_].slice(0,-1),r=(3&r)<<8,a=Pe(r|i),this[this.mode_](e.pts,a),this.column_++;else if(this.isMidRowCode(r,i))this.clearFormatting(e.pts),this[this.mode_](e.pts," "),this.column_++,14==(14&i)&&this.addFormatting(e.pts,["i"]),1==(1&i)&&this.addFormatting(e.pts,["u"]);else if(this.isOffsetControlCode(r,i))this.column_+=3&i;else if(this.isPAC(r,i)){var o=Re.indexOf(7968&t);"rollUp"===this.mode_&&(o-this.rollUpRows_+1<0&&(o=this.rollUpRows_-1),this.setRollUp(e.pts,o)),o!==this.row_&&(this.clearFormatting(e.pts),this.row_=o),1&i&&-1===this.formatting_.indexOf("u")&&this.addFormatting(e.pts,["u"]),16==(16&t)&&(this.column_=4*((14&t)>>1)),this.isColorPAC(i)&&14==(14&i)&&this.addFormatting(e.pts,["i"])}else this.isNormalChar(r)&&(0===i&&(i=null),a=Pe(r),a+=Pe(i),this[this.mode_](e.pts,a),this.column_+=a.length)}};Me.prototype=new te,Me.prototype.flushDisplayed=function(e){var t=this.displayed_.map(function(e){try{return e.trim()}catch(e){return console.error("Skipping malformed caption."),""}}).join("\n").replace(/^\n+|\n+$/g,"");t.length&&this.trigger("data",{startPts:this.startPts_,endPts:e,text:t,stream:this.name_})},Me.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=De(),this.nonDisplayed_=De(),this.lastControlCode_=null,this.column_=0,this.row_=14,this.rollUpRows_=2,this.formatting_=[]},Me.prototype.setConstants=function(){0===this.dataChannel_?(this.BASE_=16,this.EXT_=17,this.CONTROL_=(20|this.field_)<<8,this.OFFSET_=23):1===this.dataChannel_&&(this.BASE_=24,this.EXT_=25,this.CONTROL_=(28|this.field_)<<8,this.OFFSET_=31),this.PADDING_=0,this.RESUME_CAPTION_LOADING_=32|this.CONTROL_,this.END_OF_CAPTION_=47|this.CONTROL_,this.ROLL_UP_2_ROWS_=37|this.CONTROL_,this.ROLL_UP_3_ROWS_=38|this.CONTROL_,this.ROLL_UP_4_ROWS_=39|this.CONTROL_,this.CARRIAGE_RETURN_=45|this.CONTROL_,this.RESUME_DIRECT_CAPTIONING_=41|this.CONTROL_,this.BACKSPACE_=33|this.CONTROL_,this.ERASE_DISPLAYED_MEMORY_=44|this.CONTROL_,this.ERASE_NON_DISPLAYED_MEMORY_=46|this.CONTROL_},Me.prototype.isSpecialCharacter=function(e,t){return e===this.EXT_&&t>=48&&t<=63},Me.prototype.isExtCharacter=function(e,t){return(e===this.EXT_+1||e===this.EXT_+2)&&t>=32&&t<=63},Me.prototype.isMidRowCode=function(e,t){return e===this.EXT_&&t>=32&&t<=47},Me.prototype.isOffsetControlCode=function(e,t){return e===this.OFFSET_&&t>=33&&t<=35},Me.prototype.isPAC=function(e,t){return e>=this.BASE_&&e<this.BASE_+8&&t>=64&&t<=127},Me.prototype.isColorPAC=function(e){return e>=64&&e<=79||e>=96&&e<=127},Me.prototype.isNormalChar=function(e){return e>=32&&e<=127},Me.prototype.setRollUp=function(e,t){if("rollUp"!==this.mode_&&(this.row_=14,this.mode_="rollUp",this.flushDisplayed(e),this.nonDisplayed_=De(),this.displayed_=De()),void 0!==t&&t!==this.row_)for(var n=0;n<this.rollUpRows_;n++)this.displayed_[t-n]=this.displayed_[this.row_-n],this.displayed_[this.row_-n]="";void 0===t&&(t=this.row_),this.topRow_=t-this.rollUpRows_+1},Me.prototype.addFormatting=function(e,t){this.formatting_=this.formatting_.concat(t);var n=t.reduce(function(e,t){return e+"<"+t+">"},"");this[this.mode_](e,n)},Me.prototype.clearFormatting=function(e){if(this.formatting_.length){var t=this.formatting_.reverse().reduce(function(e,t){return e+"</"+t+">"},"");this.formatting_=[],this[this.mode_](e,t)}},Me.prototype.popOn=function(e,t){var n=this.nonDisplayed_[this.row_];n+=t,this.nonDisplayed_[this.row_]=n},Me.prototype.rollUp=function(e,t){var n=this.displayed_[this.row_];n+=t,this.displayed_[this.row_]=n},Me.prototype.shiftRowsUp_=function(){var e;for(e=0;e<this.topRow_;e++)this.displayed_[e]="";for(e=this.row_+1;e<15;e++)this.displayed_[e]="";for(e=this.topRow_;e<this.row_;e++)this.displayed_[e]=this.displayed_[e+1];this.displayed_[this.row_]=""},Me.prototype.paintOn=function(e,t){var n=this.displayed_[this.row_];n+=t,this.displayed_[this.row_]=n};var Ue={CaptionStream:Oe,Cea608Stream:Me},Be={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21},Ne=function(e,t){var n=1;for(e>t&&(n=-1);Math.abs(t-e)>4294967296;)e+=8589934592*n;return e},Fe=function e(t){var n,r;e.prototype.init.call(this),this.type_=t,this.push=function(e){e.type===this.type_&&(void 0===r&&(r=e.dts),e.dts=Ne(e.dts,r),e.pts=Ne(e.pts,r),n=e.dts,this.trigger("data",e))},this.flush=function(){r=n,this.trigger("done")},this.discontinuity=function(){r=void 0,n=void 0}};Fe.prototype=new te;var Ve,qe={TimestampRolloverStream:Fe,handleRollover:Ne},Ge=function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i},He=function(e,t,n){return decodeURIComponent(Ge(e,t,n))},ze=function(e,t,n){return unescape(Ge(e,t,n))},We=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},$e={TXXX:function(e){var t;if(3===e.data[0]){for(t=1;t<e.data.length;t++)if(0===e.data[t]){e.description=He(e.data,1,t),e.value=He(e.data,t+1,e.data.length).replace(/\0*$/,"");break}e.data=e.value}},WXXX:function(e){var t;if(3===e.data[0])for(t=1;t<e.data.length;t++)if(0===e.data[t]){e.description=He(e.data,1,t),e.url=He(e.data,t+1,e.data.length);break}},PRIV:function(e){var t;for(t=0;t<e.data.length;t++)if(0===e.data[t]){e.owner=ze(e.data,0,t);break}e.privateData=e.data.subarray(t+1),e.data=e.privateData}};Ve=function(e){var t,n={debug:!(!e||!e.debug),descriptor:e&&e.descriptor},r=0,i=[],a=0;if(Ve.prototype.init.call(this),this.dispatchType=Be.METADATA_STREAM_TYPE.toString(16),n.descriptor)for(t=0;t<n.descriptor.length;t++)this.dispatchType+=("00"+n.descriptor[t].toString(16)).slice(-2);this.push=function(e){var t,o,s,u,l,c;if("timed-metadata"===e.type){if(e.dataAlignmentIndicator&&(a=0,i.length=0),0===i.length&&(e.data.length<10||e.data[0]!=="I".charCodeAt(0)||e.data[1]!=="D".charCodeAt(0)||e.data[2]!=="3".charCodeAt(0)))return void(n.debug&&console.log("Skipping unrecognized metadata packet"));if(i.push(e),a+=e.data.byteLength,1===i.length&&(r=We(e.data.subarray(6,10)),r+=10),!(a<r)){for(t={data:new Uint8Array(r),frames:[],pts:i[0].pts,dts:i[0].dts},l=0;l<r;)t.data.set(i[0].data.subarray(0,r-l),l),l+=i[0].data.byteLength,a-=i[0].data.byteLength,i.shift();o=10,64&t.data[5]&&(o+=4,o+=We(t.data.subarray(10,14)),r-=We(t.data.subarray(16,20)));do{if((s=We(t.data.subarray(o+4,o+8)))<1)return console.log("Malformed ID3 frame encountered. Skipping metadata parsing.");if(c=String.fromCharCode(t.data[o],t.data[o+1],t.data[o+2],t.data[o+3]),u={id:c,data:t.data.subarray(o+10,o+s+10)},u.key=u.id,$e[u.id]&&($e[u.id](u),"com.apple.streaming.transportStreamTimestamp"===u.owner)){var d=u.data,f=(1&d[3])<<30|d[4]<<22|d[5]<<14|d[6]<<6|d[7]>>>2;f*=4,f+=3&d[7],u.timeStamp=f,void 0===t.pts&&void 0===t.dts&&(t.pts=u.timeStamp,t.dts=u.timeStamp),this.trigger("timestamp",u)}t.frames.push(u),o+=10,o+=s}while(o<r);this.trigger("data",t)}}}},Ve.prototype=new te;var Ye,Ke,Xe,Je=Ve,Qe=qe.TimestampRolloverStream;Ye=function(){var e=new Uint8Array(188),t=0;Ye.prototype.init.call(this),this.push=function(n){var r,i=0,a=188;for(t?(r=new Uint8Array(n.byteLength+t),r.set(e.subarray(0,t)),r.set(n,t),t=0):r=n;a<r.byteLength;)71!==r[i]||71!==r[a]?(i++,a++):(this.trigger("data",r.subarray(i,a)),i+=188,a+=188);i<r.byteLength&&(e.set(r.subarray(i),0),t=r.byteLength-i)},this.flush=function(){188===t&&71===e[0]&&(this.trigger("data",e),t=0),this.trigger("done")}},Ye.prototype=new te,Ke=function(){var e,t,n,r;Ke.prototype.init.call(this),r=this,this.packetsWaitingForPmt=[],this.programMapTable=void 0,e=function(e,r){var i=0;r.payloadUnitStartIndicator&&(i+=e[i]+1),"pat"===r.type?t(e.subarray(i),r):n(e.subarray(i),r)},t=function(e,t){t.section_number=e[7],t.last_section_number=e[8],r.pmtPid=(31&e[10])<<8|e[11],t.pmtPid=r.pmtPid},n=function(e,t){var n,i,a,o;if(1&e[5]){for(r.programMapTable={video:null,audio:null,"timed-metadata":{}},n=(15&e[1])<<8|e[2],i=3+n-4,a=(15&e[10])<<8|e[11],o=12+a;o<i;){var s=e[o],u=(31&e[o+1])<<8|e[o+2];s===Be.H264_STREAM_TYPE&&null===r.programMapTable.video?r.programMapTable.video=u:s===Be.ADTS_STREAM_TYPE&&null===r.programMapTable.audio?r.programMapTable.audio=u:s===Be.METADATA_STREAM_TYPE&&(r.programMapTable["timed-metadata"][u]=s),o+=5+((15&e[o+3])<<8|e[o+4])}t.programMapTable=r.programMapTable}},this.push=function(t){var n={},r=4;if(n.payloadUnitStartIndicator=!!(64&t[1]),n.pid=31&t[1],n.pid<<=8,n.pid|=t[2],(48&t[3])>>>4>1&&(r+=t[r]+1),0===n.pid)n.type="pat",e(t.subarray(r),n),this.trigger("data",n);else if(n.pid===this.pmtPid)for(n.type="pmt",e(t.subarray(r),n),this.trigger("data",n);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else void 0===this.programMapTable?this.packetsWaitingForPmt.push([t,r,n]):this.processPes_(t,r,n)},this.processPes_=function(e,t,n){n.pid===this.programMapTable.video?n.streamType=Be.H264_STREAM_TYPE:n.pid===this.programMapTable.audio?n.streamType=Be.ADTS_STREAM_TYPE:n.streamType=this.programMapTable["timed-metadata"][n.pid],n.type="pes",n.data=e.subarray(t),this.trigger("data",n)}},Ke.prototype=new te,Ke.STREAM_TYPES={h264:27,adts:15},Xe=function(){var e=this,t={data:[],size:0},n={data:[],size:0},r={data:[],size:0},i=function(e,t){var n;t.packetLength=6+(e[4]<<8|e[5]),t.dataAlignmentIndicator=0!=(4&e[6]),n=e[7],192&n&&(t.pts=(14&e[9])<<27|(255&e[10])<<20|(254&e[11])<<12|(255&e[12])<<5|(254&e[13])>>>3,t.pts*=4,t.pts+=(6&e[13])>>>1,t.dts=t.pts,64&n&&(t.dts=(14&e[14])<<27|(255&e[15])<<20|(254&e[16])<<12|(255&e[17])<<5|(254&e[18])>>>3,t.dts*=4,t.dts+=(6&e[18])>>>1)),t.data=e.subarray(9+e[8])},a=function(t,n,r){var a,o=new Uint8Array(t.size),s={type:n},u=0,l=0,c=!1;if(t.data.length&&!(t.size<9)){for(s.trackId=t.data[0].pid,u=0;u<t.data.length;u++)a=t.data[u],o.set(a.data,l),l+=a.data.byteLength;i(o,s),c="video"===n||s.packetLength<=t.size,(r||c)&&(t.size=0,t.data.length=0),c&&e.trigger("data",s)}};Xe.prototype.init.call(this),this.push=function(i){({pat:function(){},pes:function(){var e,o;switch(i.streamType){case Be.H264_STREAM_TYPE:case Be.H264_STREAM_TYPE:e=t,o="video";break;case Be.ADTS_STREAM_TYPE:e=n,o="audio";break;case Be.METADATA_STREAM_TYPE:e=r,o="timed-metadata";break;default:return}i.payloadUnitStartIndicator&&a(e,o,!0),e.data.push(i),e.size+=i.data.byteLength},pmt:function(){var t={type:"metadata",tracks:[]},n=i.programMapTable;null!==n.video&&t.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+n.video,codec:"avc",type:"video"}),null!==n.audio&&t.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+n.audio,codec:"adts",type:"audio"}),e.trigger("data",t)}})[i.type]()},this.flush=function(){a(t,"video"),a(n,"audio"),a(r,"timed-metadata"),this.trigger("done")}},Xe.prototype=new te;var Ze={PAT_PID:0,MP2T_PACKET_LENGTH:188,TransportPacketStream:Ye,TransportParseStream:Ke,ElementaryStream:Xe,TimestampRolloverStream:Qe,CaptionStream:Ue.CaptionStream,Cea608Stream:Ue.Cea608Stream,MetadataStream:Je};for(var et in Be)Be.hasOwnProperty(et)&&(Ze[et]=Be[et]);var tt,nt=Ze,rt=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];tt=function(){var e;tt.prototype.init.call(this),this.push=function(t){var n,r,i,a,o,s,u=0,l=0;if("audio"===t.type)for(e?(a=e,e=new Uint8Array(a.byteLength+t.data.byteLength),e.set(a),e.set(t.data,a.byteLength)):e=t.data;u+5<e.length;)if(255===e[u]&&240==(246&e[u+1])){if(r=2*(1&~e[u+1]),n=(3&e[u+3])<<11|e[u+4]<<3|(224&e[u+5])>>5,o=1024*(1+(3&e[u+6])),s=9e4*o/rt[(60&e[u+2])>>>2],i=u+n,e.byteLength<i)return;if(this.trigger("data",{pts:t.pts+l*s,dts:t.dts+l*s,sampleCount:o,audioobjecttype:1+(e[u+2]>>>6&3),channelcount:(1&e[u+2])<<2|(192&e[u+3])>>>6,samplerate:rt[(60&e[u+2])>>>2],samplingfrequencyindex:(60&e[u+2])>>>2,samplesize:16,data:e.subarray(u+7+r,i)}),e.byteLength===i)return void(e=void 0);l++,e=e.subarray(i)}else u++},this.flush=function(){this.trigger("done")}},tt.prototype=new te;var it,at=tt;it=function(e){var t=e.byteLength,n=0,r=0;this.length=function(){return 8*t},this.bitsAvailable=function(){return 8*t+r},this.loadWord=function(){var i=e.byteLength-t,a=new Uint8Array(4),o=Math.min(4,t);if(0===o)throw new Error("no bytes available");a.set(e.subarray(i,i+o)),n=new DataView(a.buffer).getUint32(0),r=8*o,t-=o},this.skipBits=function(e){var i;r>e?(n<<=e,r-=e):(e-=r,i=Math.floor(e/8),e-=8*i,t-=i,this.loadWord(),n<<=e,r-=e)},this.readBits=function(e){var i=Math.min(r,e),a=n>>>32-i;return r-=i,r>0?n<<=i:t>0&&this.loadWord(),i=e-i,i>0?a<<i|this.readBits(i):a},this.skipLeadingZeros=function(){var e;for(e=0;e<r;++e)if(0!=(n&2147483648>>>e))return n<<=e,r-=e,e;return this.loadWord(),e+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var e=this.skipLeadingZeros();return this.readBits(e+1)-1},this.readExpGolomb=function(){var e=this.readUnsignedExpGolomb();return 1&e?1+e>>>1:-1*(e>>>1)},this.readBoolean=function(){return 1===this.readBits(1)},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()};var ot,st,ut,lt=it;st=function(){var e,t,n=0;st.prototype.init.call(this),this.push=function(r){var i;for(t?(i=new Uint8Array(t.byteLength+r.data.byteLength),i.set(t),i.set(r.data,t.byteLength),t=i):t=r.data;n<t.byteLength-3;n++)if(1===t[n+2]){e=n+5;break}for(;e<t.byteLength;)switch(t[e]){case 0:if(0!==t[e-1]){e+=2;break}if(0!==t[e-2]){e++;break}n+3!==e-2&&this.trigger("data",t.subarray(n+3,e-2));do{e++}while(1!==t[e]&&e<t.length);n=e-2,e+=3;break;case 1:if(0!==t[e-1]||0!==t[e-2]){e+=3;break}this.trigger("data",t.subarray(n+3,e-2)),n=e-2,e+=3;break;default:e+=3}t=t.subarray(n),e-=n,n=0},this.flush=function(){t&&t.byteLength>3&&this.trigger("data",t.subarray(n+3)),t=null,n=0,this.trigger("done")}},st.prototype=new te,ut={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},ot=function(){var e,t,n,r,i,a,o,s=new st;ot.prototype.init.call(this),e=this,this.push=function(e){"video"===e.type&&(t=e.trackId,n=e.pts,r=e.dts,s.push(e))},s.on("data",function(o){var s={trackId:t,pts:n,dts:r,data:o};switch(31&o[0]){case 5:s.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:s.nalUnitType="sei_rbsp",s.escapedRBSP=i(o.subarray(1));break;case 7:s.nalUnitType="seq_parameter_set_rbsp",s.escapedRBSP=i(o.subarray(1)),s.config=a(s.escapedRBSP);break;case 8:s.nalUnitType="pic_parameter_set_rbsp";break;case 9:s.nalUnitType="access_unit_delimiter_rbsp"}e.trigger("data",s)}),s.on("done",function(){e.trigger("done")}),this.flush=function(){s.flush()},o=function(e,t){var n,r,i=8,a=8;for(n=0;n<e;n++)0!==a&&(r=t.readExpGolomb(),a=(i+r+256)%256),i=0===a?i:a},i=function(e){for(var t,n,r=e.byteLength,i=[],a=1;a<r-2;)0===e[a]&&0===e[a+1]&&3===e[a+2]?(i.push(a+2),a+=2):a++;if(0===i.length)return e;t=r-i.length,n=new Uint8Array(t);var o=0;for(a=0;a<t;o++,a++)o===i[0]&&(o++,i.shift()),n[a]=e[o];return n},a=function(e){var t,n,r,i,a,s,u,l,c,d,f,h,p,m=0,v=0,g=0,y=0,_=1;if(t=new lt(e),n=t.readUnsignedByte(),i=t.readUnsignedByte(),r=t.readUnsignedByte(),t.skipUnsignedExpGolomb(),ut[n]&&(a=t.readUnsignedExpGolomb(),3===a&&t.skipBits(1),t.skipUnsignedExpGolomb(),t.skipUnsignedExpGolomb(),t.skipBits(1),t.readBoolean()))for(f=3!==a?8:12,p=0;p<f;p++)t.readBoolean()&&(p<6?o(16,t):o(64,t));if(t.skipUnsignedExpGolomb(),0===(s=t.readUnsignedExpGolomb()))t.readUnsignedExpGolomb();else if(1===s)for(t.skipBits(1),t.skipExpGolomb(),t.skipExpGolomb(),u=t.readUnsignedExpGolomb(),p=0;p<u;p++)t.skipExpGolomb();if(t.skipUnsignedExpGolomb(),t.skipBits(1),l=t.readUnsignedExpGolomb(),c=t.readUnsignedExpGolomb(),d=t.readBits(1),0===d&&t.skipBits(1),t.skipBits(1),t.readBoolean()&&(m=t.readUnsignedExpGolomb(),v=t.readUnsignedExpGolomb(),g=t.readUnsignedExpGolomb(),y=t.readUnsignedExpGolomb()),t.readBoolean()&&t.readBoolean()){switch(t.readUnsignedByte()){case 1:h=[1,1];break;case 2:h=[12,11];break;case 3:h=[10,11];break;case 4:h=[16,11];break;case 5:h=[40,33];break;case 6:h=[24,11];break;case 7:h=[20,11];break;case 8:h=[32,11];break;case 9:h=[80,33];break;case 10:h=[18,11];break;case 11:h=[15,11];break;case 12:h=[64,33];break;case 13:h=[160,99];break;case 14:h=[4,3];break;case 15:h=[3,2];break;case 16:h=[2,1];break;case 255:h=[t.readUnsignedByte()<<8|t.readUnsignedByte(),t.readUnsignedByte()<<8|t.readUnsignedByte()]}h&&(_=h[0]/h[1])}return{profileIdc:n,levelIdc:r,profileCompatibility:i,width:Math.ceil((16*(l+1)-2*m-2*v)*_),height:(2-d)*(c+1)*16-2*g-2*y}}},ot.prototype=new te;var ct,dt={H264Stream:ot,NalByteStream:st},ft=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],ht=function(e){return e[0]==="I".charCodeAt(0)&&e[1]==="D".charCodeAt(0)&&e[2]==="3".charCodeAt(0)},pt=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},mt=function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i},vt=function(e,t,n){return unescape(mt(e,t,n))},gt=function(e,t){var n=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9];return(16&e[t+5])>>4?n+20:n+10},yt=function(e,t){var n=(224&e[t+5])>>5,r=e[t+4]<<3;return 6144&e[t+3]|r|n},_t=function(e,t){return e[t]==="I".charCodeAt(0)&&e[t+1]==="D".charCodeAt(0)&&e[t+2]==="3".charCodeAt(0)?"timed-metadata":!0&e[t]&&240==(240&e[t+1])?"audio":null},bt=function(e){for(var t=0;t+5<e.length;){if(255===e[t]&&240==(246&e[t+1]))return ft[(60&e[t+2])>>>2];t++}return null},Tt=function(e){var t,n,r;t=10,64&e[5]&&(t+=4,t+=pt(e.subarray(10,14)));do{if((n=pt(e.subarray(t+4,t+8)))<1)return null;if("PRIV"===String.fromCharCode(e[t],e[t+1],e[t+2],e[t+3])){r=e.subarray(t+10,t+n+10);for(var i=0;i<r.byteLength;i++)if(0===r[i]){var a=vt(r,0,i);if("com.apple.streaming.transportStreamTimestamp"===a){var o=r.subarray(i+1),s=(1&o[3])<<30|o[4]<<22|o[5]<<14|o[6]<<6|o[7]>>>2;return s*=4,s+=3&o[7]}break}}t+=10,t+=n}while(t<e.byteLength);return null},St={isLikelyAacData:ht,parseId3TagSize:gt,parseAdtsSize:yt,parseType:_t,parseSampleRate:bt,parseAacTimestamp:Tt};ct=function(){var e=new Uint8Array,t=0;ct.prototype.init.call(this),this.setTimestamp=function(e){t=e},this.push=function(n){var r,i,a,o,s=0,u=0;for(e.length?(o=e.length,e=new Uint8Array(n.byteLength+o),e.set(e.subarray(0,o)),e.set(n,o)):e=n;e.length-u>=3;)if(e[u]!=="I".charCodeAt(0)||e[u+1]!=="D".charCodeAt(0)||e[u+2]!=="3".charCodeAt(0))if(255!=(255&e[u])||240!=(240&e[u+1]))u++;else{if(e.length-u<7)break;if(s=St.parseAdtsSize(e,u),u+s>e.length)break;a={type:"audio",data:e.subarray(u,u+s),pts:t,dts:t},this.trigger("data",a),u+=s}else{if(e.length-u<10)break;if(s=St.parseId3TagSize(e,u),u+s>e.length)break;i={type:"timed-metadata",data:e.subarray(u,u+s)},this.trigger("data",i),u+=s}r=e.length-u,e=r>0?e.subarray(u):new Uint8Array}},ct.prototype=new te;var wt,kt,Et,At,Ct=ct,Lt=dt.H264Stream,xt=St.isLikelyAacData,jt=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],Ot=["width","height","profileIdc","levelIdc","profileCompatibility"],It=function(e,t){var n;if(e.length!==t.length)return!1;for(n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0},Pt=function(e,t,n,r,i,a){return{start:{dts:e,pts:e+(n-t)},end:{dts:e+(r-t),pts:e+(i-n)},prependedContentDuration:a,baseMediaDecodeTime:e}};kt=function(e,t){var n=[],r=0,i=0,a=0,o=1/0;t=t||{},kt.prototype.init.call(this),this.push=function(t){Ee.collectDtsInfo(e,t),e&&jt.forEach(function(n){e[n]=t[n]}),n.push(t)},this.setEarliestDts=function(t){i=t-e.timelineStartInfo.baseMediaDecodeTime},this.setVideoBaseMediaDecodeTime=function(e){o=e},this.setAudioAppendStart=function(e){a=e},this.flush=function(){var s,u,l,c;if(0===n.length)return void this.trigger("done","AudioSegmentStream");s=Te.trimAdtsFramesByEarliestDts(n,e,i),e.baseMediaDecodeTime=Ee.calculateTrackBaseMediaDecodeTime(e,t.keepOriginalTimestamps),Te.prefixWithSilence(e,s,a,o),e.samples=Te.generateSampleTable(s),l=G.mdat(Te.concatenateFrameData(s)),n=[],u=G.moof(r,[e]),c=new Uint8Array(u.byteLength+l.byteLength),r++,c.set(u),c.set(l,u.byteLength),Ee.clearDtsInfo(e),this.trigger("data",{track:e,boxes:c}),this.trigger("done","AudioSegmentStream")}},kt.prototype=new te,wt=function(e,t){var n,r,i=0,a=[],o=[];t=t||{},wt.prototype.init.call(this),delete e.minPTS,this.gopCache_=[],this.push=function(t){Ee.collectDtsInfo(e,t),"seq_parameter_set_rbsp"!==t.nalUnitType||n||(n=t.config,e.sps=[t.data],Ot.forEach(function(t){e[t]=n[t]},this)),"pic_parameter_set_rbsp"!==t.nalUnitType||r||(r=t.data,e.pps=[t.data]),a.push(t)},this.flush=function(){for(var n,r,s,u,l,c,d,f,h=0;a.length&&"access_unit_delimiter_rbsp"!==a[0].nalUnitType;)a.shift();if(0===a.length)return this.resetStream_(),void this.trigger("done","VideoSegmentStream");if(n=le.groupNalsIntoFrames(a),s=le.groupFramesIntoGops(n),s[0][0].keyFrame||(r=this.getGopForFusion_(a[0],e),r?(h=r.duration,s.unshift(r),s.byteLength+=r.byteLength,s.nalCount+=r.nalCount,s.pts=r.pts,s.dts=r.dts,s.duration+=r.duration):s=le.extendFirstKeyFrame(s)),o.length){var p;if(!(p=t.alignGopsAtEnd?this.alignGopsAtEnd_(s):this.alignGopsAtStart_(s)))return this.gopCache_.unshift({gop:s.pop(),pps:e.pps,sps:e.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),a=[],this.resetStream_(),void this.trigger("done","VideoSegmentStream");Ee.clearDtsInfo(e),s=p}Ee.collectDtsInfo(e,s),e.samples=le.generateSampleTable(s),l=G.mdat(le.concatenateNalData(s)),e.baseMediaDecodeTime=Ee.calculateTrackBaseMediaDecodeTime(e,t.keepOriginalTimestamps),this.trigger("processedGopsInfo",s.map(function(e){return{pts:e.pts,dts:e.dts,byteLength:e.byteLength}})),d=s[0],f=s[s.length-1],this.trigger("segmentTimingInfo",Pt(e.baseMediaDecodeTime,d.dts,d.pts,f.dts+f.duration,f.pts+f.duration,h)),this.gopCache_.unshift({gop:s.pop(),pps:e.pps,sps:e.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),a=[],this.trigger("baseMediaDecodeTime",e.baseMediaDecodeTime),this.trigger("timelineStartInfo",e.timelineStartInfo),u=G.moof(i,[e]),c=new Uint8Array(u.byteLength+l.byteLength),i++,c.set(u),c.set(l,u.byteLength),this.trigger("data",{track:e,boxes:c}),this.resetStream_(),this.trigger("done","VideoSegmentStream")},this.resetStream_=function(){Ee.clearDtsInfo(e),n=void 0,r=void 0},this.getGopForFusion_=function(t){var n,r,i,a,o,s=1/0;for(o=0;o<this.gopCache_.length;o++)a=this.gopCache_[o],i=a.gop,e.pps&&It(e.pps[0],a.pps[0])&&e.sps&&It(e.sps[0],a.sps[0])&&(i.dts<e.timelineStartInfo.dts||(n=t.dts-i.dts-i.duration)>=-1e4&&n<=45e3&&(!r||s>n)&&(r=a,s=n));return r?r.gop:null},this.alignGopsAtStart_=function(e){var t,n,r,i,a,s,u,l;for(a=e.byteLength,s=e.nalCount,u=e.duration,t=n=0;t<o.length&&n<e.length&&(r=o[t],i=e[n],r.pts!==i.pts);)i.pts>r.pts?t++:(n++,a-=i.byteLength,s-=i.nalCount,u-=i.duration);return 0===n?e:n===e.length?null:(l=e.slice(n),l.byteLength=a,l.duration=u,l.nalCount=s,l.pts=l[0].pts,l.dts=l[0].dts,l)},this.alignGopsAtEnd_=function(e){var t,n,r,i,a,s;for(t=o.length-1,n=e.length-1,a=null,s=!1;t>=0&&n>=0;){if(r=o[t],i=e[n],r.pts===i.pts){s=!0;break}r.pts>i.pts?t--:(t===o.length-1&&(a=n),n--)}if(!s&&null===a)return null;var u;if(0===(u=s?n:a))return e;var l=e.slice(u),c=l.reduce(function(e,t){return e.byteLength+=t.byteLength,e.duration+=t.duration,e.nalCount+=t.nalCount,e},{byteLength:0,duration:0,nalCount:0});return l.byteLength=c.byteLength,l.duration=c.duration,l.nalCount=c.nalCount,l.pts=l[0].pts,l.dts=l[0].dts,l},this.alignGopsWith=function(e){o=e}},wt.prototype=new te,At=function(e,t){this.numberOfTracks=0,this.metadataStream=t,e=e||{},void 0!==e.remux?this.remuxTracks=!!e.remux:this.remuxTracks=!0,"boolean"==typeof e.keepOriginalTimestamps&&(this.keepOriginalTimestamps=e.keepOriginalTimestamps),this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,At.prototype.init.call(this),this.push=function(e){return e.text?this.pendingCaptions.push(e):e.frames?this.pendingMetadata.push(e):(this.pendingTracks.push(e.track),this.pendingBoxes.push(e.boxes),this.pendingBytes+=e.boxes.byteLength,"video"===e.track.type&&(this.videoTrack=e.track),void("audio"===e.track.type&&(this.audioTrack=e.track)))}},At.prototype=new te,At.prototype.flush=function(e){var t,n,r,i,a=0,o={captions:[],captionStreams:{},metadata:[],info:{}},s=0;if(this.pendingTracks.length<this.numberOfTracks){if("VideoSegmentStream"!==e&&"AudioSegmentStream"!==e)return;if(this.remuxTracks)return;if(0===this.pendingTracks.length)return void(++this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0))}for(this.videoTrack?(s=this.videoTrack.timelineStartInfo.pts,Ot.forEach(function(e){o.info[e]=this.videoTrack[e]},this)):this.audioTrack&&(s=this.audioTrack.timelineStartInfo.pts,jt.forEach(function(e){o.info[e]=this.audioTrack[e]},this)),1===this.pendingTracks.length?o.type=this.pendingTracks[0].type:o.type="combined",this.emittedTracks+=this.pendingTracks.length,r=G.initSegment(this.pendingTracks),o.initSegment=new Uint8Array(r.byteLength),o.initSegment.set(r),o.data=new Uint8Array(this.pendingBytes),i=0;i<this.pendingBoxes.length;i++)o.data.set(this.pendingBoxes[i],a),a+=this.pendingBoxes[i].byteLength;for(i=0;i<this.pendingCaptions.length;i++)t=this.pendingCaptions[i],t.startTime=t.startPts,this.keepOriginalTimestamps||(t.startTime-=s),t.startTime/=9e4,t.endTime=t.endPts,this.keepOriginalTimestamps||(t.endTime-=s),t.endTime/=9e4,o.captionStreams[t.stream]=!0,o.captions.push(t);for(i=0;i<this.pendingMetadata.length;i++)n=this.pendingMetadata[i],n.cueTime=n.pts,this.keepOriginalTimestamps||(n.cueTime-=s),n.cueTime/=9e4,o.metadata.push(n);o.metadata.dispatchType=this.metadataStream.dispatchType,this.pendingTracks.length=0,this.videoTrack=null,this.pendingBoxes.length=0,this.pendingCaptions.length=0,this.pendingBytes=0,this.pendingMetadata.length=0,this.trigger("data",o),this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},Et=function(e){var t,n,r=this,i=!0;Et.prototype.init.call(this),e=e||{},this.baseMediaDecodeTime=e.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var t={};this.transmuxPipeline_=t,t.type="aac",t.metadataStream=new nt.MetadataStream,t.aacStream=new Ct,t.audioTimestampRolloverStream=new nt.TimestampRolloverStream("audio"),t.timedMetadataTimestampRolloverStream=new nt.TimestampRolloverStream("timed-metadata"),t.adtsStream=new at,t.coalesceStream=new At(e,t.metadataStream),t.headOfPipeline=t.aacStream,t.aacStream.pipe(t.audioTimestampRolloverStream).pipe(t.adtsStream),t.aacStream.pipe(t.timedMetadataTimestampRolloverStream).pipe(t.metadataStream).pipe(t.coalesceStream),t.metadataStream.on("timestamp",function(e){t.aacStream.setTimestamp(e.timeStamp)}),t.aacStream.on("data",function(i){"timed-metadata"!==i.type||t.audioSegmentStream||(n=n||{timelineStartInfo:{baseMediaDecodeTime:r.baseMediaDecodeTime},codec:"adts",type:"audio"},t.coalesceStream.numberOfTracks++,t.audioSegmentStream=new kt(n,e),t.adtsStream.pipe(t.audioSegmentStream).pipe(t.coalesceStream))}),t.coalesceStream.on("data",this.trigger.bind(this,"data")),t.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setupTsPipeline=function(){var i={};this.transmuxPipeline_=i,i.type="ts",i.metadataStream=new nt.MetadataStream,i.packetStream=new nt.TransportPacketStream,i.parseStream=new nt.TransportParseStream,i.elementaryStream=new nt.ElementaryStream,i.videoTimestampRolloverStream=new nt.TimestampRolloverStream("video"),i.audioTimestampRolloverStream=new nt.TimestampRolloverStream("audio"),i.timedMetadataTimestampRolloverStream=new nt.TimestampRolloverStream("timed-metadata"),i.adtsStream=new at,i.h264Stream=new Lt,i.captionStream=new nt.CaptionStream,i.coalesceStream=new At(e,i.metadataStream),i.headOfPipeline=i.packetStream,i.packetStream.pipe(i.parseStream).pipe(i.elementaryStream),i.elementaryStream.pipe(i.videoTimestampRolloverStream).pipe(i.h264Stream),i.elementaryStream.pipe(i.audioTimestampRolloverStream).pipe(i.adtsStream),i.elementaryStream.pipe(i.timedMetadataTimestampRolloverStream).pipe(i.metadataStream).pipe(i.coalesceStream),i.h264Stream.pipe(i.captionStream).pipe(i.coalesceStream),i.elementaryStream.on("data",function(a){var o;if("metadata"===a.type){for(o=a.tracks.length;o--;)t||"video"!==a.tracks[o].type?n||"audio"!==a.tracks[o].type||(n=a.tracks[o],n.timelineStartInfo.baseMediaDecodeTime=r.baseMediaDecodeTime):(t=a.tracks[o],t.timelineStartInfo.baseMediaDecodeTime=r.baseMediaDecodeTime);t&&!i.videoSegmentStream&&(i.coalesceStream.numberOfTracks++,i.videoSegmentStream=new wt(t,e),i.videoSegmentStream.on("timelineStartInfo",function(e){n&&(n.timelineStartInfo=e,i.audioSegmentStream.setEarliestDts(e.dts))}),i.videoSegmentStream.on("processedGopsInfo",r.trigger.bind(r,"gopInfo")),i.videoSegmentStream.on("segmentTimingInfo",r.trigger.bind(r,"videoSegmentTimingInfo")),i.videoSegmentStream.on("baseMediaDecodeTime",function(e){n&&i.audioSegmentStream.setVideoBaseMediaDecodeTime(e)}),i.h264Stream.pipe(i.videoSegmentStream).pipe(i.coalesceStream)),n&&!i.audioSegmentStream&&(i.coalesceStream.numberOfTracks++,i.audioSegmentStream=new kt(n,e),i.adtsStream.pipe(i.audioSegmentStream).pipe(i.coalesceStream))}}),i.coalesceStream.on("data",this.trigger.bind(this,"data")),i.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setBaseMediaDecodeTime=function(r){var i=this.transmuxPipeline_;e.keepOriginalTimestamps||(this.baseMediaDecodeTime=r),n&&(n.timelineStartInfo.dts=void 0,n.timelineStartInfo.pts=void 0,Ee.clearDtsInfo(n),e.keepOriginalTimestamps||(n.timelineStartInfo.baseMediaDecodeTime=r),i.audioTimestampRolloverStream&&i.audioTimestampRolloverStream.discontinuity()),t&&(i.videoSegmentStream&&(i.videoSegmentStream.gopCache_=[],i.videoTimestampRolloverStream.discontinuity()),t.timelineStartInfo.dts=void 0,t.timelineStartInfo.pts=void 0,Ee.clearDtsInfo(t),i.captionStream.reset(),e.keepOriginalTimestamps||(t.timelineStartInfo.baseMediaDecodeTime=r)),i.timedMetadataTimestampRolloverStream&&i.timedMetadataTimestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(e){n&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(e)},this.alignGopsWith=function(e){t&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(e)},this.push=function(e){if(i){var t=xt(e);t&&"aac"!==this.transmuxPipeline_.type?this.setupAacPipeline():t||"ts"===this.transmuxPipeline_.type||this.setupTsPipeline(),i=!1}this.transmuxPipeline_.headOfPipeline.push(e)},this.flush=function(){i=!0,this.transmuxPipeline_.headOfPipeline.flush()},this.resetCaptions=function(){this.transmuxPipeline_.captionStream&&this.transmuxPipeline_.captionStream.reset()}},Et.prototype=new te;var Rt,Dt,Mt={Transmuxer:Et,VideoSegmentStream:wt,AudioSegmentStream:kt,AUDIO_PROPERTIES:jt,VIDEO_PROPERTIES:Ot,generateVideoSegmentTimingInfo:Pt},Ut=$.parseType,Bt=function(e){return new Date(1e3*e-20828448e5)},Nt=function(e){return{isLeading:(12&e[0])>>>2,dependsOn:3&e[0],isDependedOn:(192&e[1])>>>6,hasRedundancy:(48&e[1])>>>4,paddingValue:(14&e[1])>>>1,isNonSyncSample:1&e[1],degradationPriority:e[2]<<8|e[3]}},Ft=function(e){var t,n,r=new DataView(e.buffer,e.byteOffset,e.byteLength),i=[];for(t=0;t+4<e.length;t+=n)if(n=r.getUint32(t),t+=4,n<=0)i.push("<span style='color:red;'>MALFORMED DATA</span>");else switch(31&e[t]){case 1:i.push("slice_layer_without_partitioning_rbsp");break;case 5:i.push("slice_layer_without_partitioning_rbsp_idr");break;case 6:i.push("sei_rbsp");break;case 7:i.push("seq_parameter_set_rbsp");break;case 8:i.push("pic_parameter_set_rbsp");break;case 9:i.push("access_unit_delimiter_rbsp");break;default:i.push("UNKNOWN NAL - "+e[t]&31)}return i},Vt={avc1:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{dataReferenceIndex:t.getUint16(6),width:t.getUint16(24),height:t.getUint16(26),horizresolution:t.getUint16(28)+t.getUint16(30)/16,vertresolution:t.getUint16(32)+t.getUint16(34)/16,frameCount:t.getUint16(40),depth:t.getUint16(74),config:Rt(e.subarray(78,e.byteLength))}},avcC:function(e){var t,n,r,i,a=new DataView(e.buffer,e.byteOffset,e.byteLength),o={configurationVersion:e[0],avcProfileIndication:e[1],profileCompatibility:e[2],avcLevelIndication:e[3],lengthSizeMinusOne:3&e[4],sps:[],pps:[]},s=31&e[5];for(r=6,i=0;i<s;i++)n=a.getUint16(r),r+=2,o.sps.push(new Uint8Array(e.subarray(r,r+n))),r+=n;for(t=e[r],r++,i=0;i<t;i++)n=a.getUint16(r),r+=2,o.pps.push(new Uint8Array(e.subarray(r,r+n))),r+=n;return o},btrt:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{bufferSizeDB:t.getUint32(0),maxBitrate:t.getUint32(4),avgBitrate:t.getUint32(8)}},esds:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),esId:e[6]<<8|e[7],streamPriority:31&e[8],decoderConfig:{objectProfileIndication:e[11],streamType:e[12]>>>2&63,bufferSize:e[13]<<16|e[14]<<8|e[15],maxBitrate:e[16]<<24|e[17]<<16|e[18]<<8|e[19],avgBitrate:e[20]<<24|e[21]<<16|e[22]<<8|e[23],decoderConfigDescriptor:{tag:e[24],length:e[25],audioObjectType:e[26]>>>3&31,samplingFrequencyIndex:(7&e[26])<<1|e[27]>>>7&1,channelConfiguration:e[27]>>>3&15}}}},ftyp:function(e){for(var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n={majorBrand:Ut(e.subarray(0,4)),minorVersion:t.getUint32(4),compatibleBrands:[]},r=8;r<e.byteLength;)n.compatibleBrands.push(Ut(e.subarray(r,r+4))),r+=4;return n},dinf:function(e){return{boxes:Rt(e)}},dref:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),dataReferences:Rt(e.subarray(8))}},hdlr:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n={version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4)),handlerType:Ut(e.subarray(8,12)),name:""},r=8;for(r=24;r<e.byteLength;r++){if(0===e[r]){r++;break}n.name+=String.fromCharCode(e[r])}return n.name=decodeURIComponent(escape(n.name)),n},mdat:function(e){return{byteLength:e.byteLength,nals:Ft(e)}},mdhd:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r=4,i={version:n.getUint8(0),flags:new Uint8Array(e.subarray(1,4)),language:""};return 1===i.version?(r+=4,i.creationTime=Bt(n.getUint32(r)),r+=8,i.modificationTime=Bt(n.getUint32(r)),r+=4,i.timescale=n.getUint32(r),r+=8,i.duration=n.getUint32(r)):(i.creationTime=Bt(n.getUint32(r)),r+=4,i.modificationTime=Bt(n.getUint32(r)),r+=4,i.timescale=n.getUint32(r),r+=4,i.duration=n.getUint32(r)),r+=4,t=n.getUint16(r),i.language+=String.fromCharCode(96+(t>>10)),i.language+=String.fromCharCode(96+((992&t)>>5)),i.language+=String.fromCharCode(96+(31&t)),i},mdia:function(e){return{boxes:Rt(e)}},mfhd:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),sequenceNumber:e[4]<<24|e[5]<<16|e[6]<<8|e[7]}},minf:function(e){return{boxes:Rt(e)}},mp4a:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n={dataReferenceIndex:t.getUint16(6),channelcount:t.getUint16(16),samplesize:t.getUint16(18),samplerate:t.getUint16(24)+t.getUint16(26)/65536};return e.byteLength>28&&(n.streamDescriptor=Rt(e.subarray(28))[0]),n},moof:function(e){return{boxes:Rt(e)}},moov:function(e){return{boxes:Rt(e)}},mvex:function(e){return{boxes:Rt(e)}},mvhd:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n=4,r={version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4))};return 1===r.version?(n+=4,r.creationTime=Bt(t.getUint32(n)),n+=8,r.modificationTime=Bt(t.getUint32(n)),n+=4,r.timescale=t.getUint32(n),n+=8,r.duration=t.getUint32(n)):(r.creationTime=Bt(t.getUint32(n)),n+=4,r.modificationTime=Bt(t.getUint32(n)),n+=4,r.timescale=t.getUint32(n),n+=4,r.duration=t.getUint32(n)),n+=4,r.rate=t.getUint16(n)+t.getUint16(n+2)/16,n+=4,r.volume=t.getUint8(n)+t.getUint8(n+1)/8,n+=2,n+=2,n+=8,r.matrix=new Uint32Array(e.subarray(n,n+36)),n+=36,n+=24,r.nextTrackId=t.getUint32(n),r},pdin:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4)),rate:t.getUint32(4),initialDelay:t.getUint32(8)}},sdtp:function(e){var t,n={version:e[0],flags:new Uint8Array(e.subarray(1,4)),samples:[]};for(t=4;t<e.byteLength;t++)n.samples.push({dependsOn:(48&e[t])>>4,isDependedOn:(12&e[t])>>2,hasRedundancy:3&e[t]});return n},sidx:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),references:[],referenceId:n.getUint32(4),timescale:n.getUint32(8),earliestPresentationTime:n.getUint32(12),firstOffset:n.getUint32(16)},i=n.getUint16(22);for(t=24;i;t+=12,i--)r.references.push({referenceType:(128&e[t])>>>7,referencedSize:2147483647&n.getUint32(t),subsegmentDuration:n.getUint32(t+4),startsWithSap:!!(128&e[t+8]),sapType:(112&e[t+8])>>>4,sapDeltaTime:268435455&n.getUint32(t+8)});return r},smhd:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),balance:e[4]+e[5]/256}},stbl:function(e){return{boxes:Rt(e)}},stco:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),chunkOffsets:[]},i=n.getUint32(4);for(t=8;i;t+=4,i--)r.chunkOffsets.push(n.getUint32(t));return r},stsc:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r=n.getUint32(4),i={version:e[0],flags:new Uint8Array(e.subarray(1,4)),sampleToChunks:[]};for(t=8;r;t+=12,r--)i.sampleToChunks.push({firstChunk:n.getUint32(t),samplesPerChunk:n.getUint32(t+4),sampleDescriptionIndex:n.getUint32(t+8)});return i},stsd:function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),sampleDescriptions:Rt(e.subarray(8))}},stsz:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),sampleSize:n.getUint32(4),entries:[]};for(t=12;t<e.byteLength;t+=4)r.entries.push(n.getUint32(t));return r},stts:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),timeToSamples:[]},i=n.getUint32(4);for(t=8;i;t+=8,i--)r.timeToSamples.push({sampleCount:n.getUint32(t),sampleDelta:n.getUint32(t+4)});return r},styp:function(e){return Vt.ftyp(e)},tfdt:function(e){var t={version:e[0],flags:new Uint8Array(e.subarray(1,4)),baseMediaDecodeTime:e[4]<<24|e[5]<<16|e[6]<<8|e[7]};return 1===t.version&&(t.baseMediaDecodeTime*=Math.pow(2,32),t.baseMediaDecodeTime+=e[8]<<24|e[9]<<16|e[10]<<8|e[11]),t},tfhd:function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),trackId:n.getUint32(4)},i=1&r.flags[2],a=2&r.flags[2],o=8&r.flags[2],s=16&r.flags[2],u=32&r.flags[2],l=65536&r.flags[0],c=131072&r.flags[0];return t=8,i&&(t+=4,r.baseDataOffset=n.getUint32(12),t+=4),a&&(r.sampleDescriptionIndex=n.getUint32(t),t+=4),o&&(r.defaultSampleDuration=n.getUint32(t),t+=4),s&&(r.defaultSampleSize=n.getUint32(t),t+=4),u&&(r.defaultSampleFlags=n.getUint32(t)),l&&(r.durationIsEmpty=!0),!i&&c&&(r.baseDataOffsetIsMoof=!0),r},tkhd:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n=4,r={version:t.getUint8(0),flags:new Uint8Array(e.subarray(1,4))};return 1===r.version?(n+=4,r.creationTime=Bt(t.getUint32(n)),n+=8,r.modificationTime=Bt(t.getUint32(n)),n+=4,r.trackId=t.getUint32(n),n+=4,n+=8,r.duration=t.getUint32(n)):(r.creationTime=Bt(t.getUint32(n)),n+=4,r.modificationTime=Bt(t.getUint32(n)),n+=4,r.trackId=t.getUint32(n),n+=4,n+=4,r.duration=t.getUint32(n)),n+=4,n+=8,r.layer=t.getUint16(n),n+=2,r.alternateGroup=t.getUint16(n),n+=2,r.volume=t.getUint8(n)+t.getUint8(n+1)/8,n+=2,n+=2,r.matrix=new Uint32Array(e.subarray(n,n+36)),n+=36,r.width=t.getUint16(n)+t.getUint16(n+2)/16,n+=4,r.height=t.getUint16(n)+t.getUint16(n+2)/16,r},traf:function(e){return{boxes:Rt(e)}},trak:function(e){return{boxes:Rt(e)}},trex:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),trackId:t.getUint32(4),defaultSampleDescriptionIndex:t.getUint32(8),defaultSampleDuration:t.getUint32(12),defaultSampleSize:t.getUint32(16),sampleDependsOn:3&e[20],sampleIsDependedOn:(192&e[21])>>6,sampleHasRedundancy:(48&e[21])>>4,samplePaddingValue:(14&e[21])>>1,sampleIsDifferenceSample:!!(1&e[21]),sampleDegradationPriority:t.getUint16(22)}},trun:function(e){var t,n={version:e[0],flags:new Uint8Array(e.subarray(1,4)),samples:[]},r=new DataView(e.buffer,e.byteOffset,e.byteLength),i=1&n.flags[2],a=4&n.flags[2],o=1&n.flags[1],s=2&n.flags[1],u=4&n.flags[1],l=8&n.flags[1],c=r.getUint32(4),d=8;for(i&&(n.dataOffset=r.getInt32(d),d+=4),a&&c&&(t={flags:Nt(e.subarray(d,d+4))},d+=4,o&&(t.duration=r.getUint32(d),d+=4),s&&(t.size=r.getUint32(d),d+=4),l&&(t.compositionTimeOffset=r.getUint32(d),d+=4),n.samples.push(t),c--);c--;)t={},o&&(t.duration=r.getUint32(d),d+=4),s&&(t.size=r.getUint32(d),d+=4),u&&(t.flags=Nt(e.subarray(d,d+4)),d+=4),l&&(t.compositionTimeOffset=r.getUint32(d),d+=4),n.samples.push(t);return n},"url ":function(e){return{version:e[0],flags:new Uint8Array(e.subarray(1,4))}},vmhd:function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);return{version:e[0],flags:new Uint8Array(e.subarray(1,4)),graphicsmode:t.getUint16(4),opcolor:new Uint16Array([t.getUint16(6),t.getUint16(8),t.getUint16(10)])}}};Rt=function(e){for(var t,n,r,i,a,o=0,s=[],u=new ArrayBuffer(e.length),l=new Uint8Array(u),c=0;c<e.length;++c)l[c]=e[c];for(t=new DataView(u);o<e.byteLength;)n=t.getUint32(o),r=Ut(e.subarray(o+4,o+8)),i=n>1?o+n:e.byteLength,a=(Vt[r]||function(e){return{data:e}})(e.subarray(o+8,i)),a.size=n,a.type=r,s.push(a),o=i;return s},Dt=function(e,t){var n;return t=t||0,n=new Array(2*t+1).join(" "),e.map(function(e,r){return n+e.type+"\n"+Object.keys(e).filter(function(e){return"type"!==e&&"boxes"!==e}).map(function(t){var r=n+" "+t+": ",i=e[t];if(i instanceof Uint8Array||i instanceof Uint32Array){var a=Array.prototype.slice.call(new Uint8Array(i.buffer,i.byteOffset,i.byteLength)).map(function(e){return" "+("00"+e.toString(16)).slice(-2)}).join("").match(/.{1,24}/g);return a?1===a.length?r+"<"+a.join("").slice(1)+">":r+"<\n"+a.map(function(e){return n+" "+e}).join("\n")+"\n"+n+" >":r+"<>"}return r+JSON.stringify(i,null,2).split("\n").map(function(e,t){return 0===t?e:n+" "+e}).join("\n")}).join("\n")+(e.boxes?"\n"+Dt(e.boxes,t+1):"")}).join("\n")};var qt={inspect:Rt,textify:Dt,parseTfdt:Vt.tfdt,parseHdlr:Vt.hdlr,parseTfhd:Vt.tfhd,parseTrun:Vt.trun,parseSidx:Vt.sidx},Gt=je.discardEmulationPreventionBytes,Ht=Ue.CaptionStream,zt=function(e,t){for(var n=e,r=0;r<t.length;r++){var i=t[r];if(n<i.size)return i;n-=i.size}return null},Wt=function(e,t,n){var r,i,a,o,s=new DataView(e.buffer,e.byteOffset,e.byteLength),u=[];for(i=0;i+4<e.length;i+=a)if(a=s.getUint32(i),i+=4,!(a<=0))switch(31&e[i]){case 6:var l=e.subarray(i+1,i+1+a),c=zt(i,t);r={nalUnitType:"sei_rbsp",size:a,data:l,escapedRBSP:Gt(l),trackId:n},c?(r.pts=c.pts,r.dts=c.dts,o=c):(r.pts=o.pts,r.dts=o.dts),u.push(r)}return u},$t=function(e,t,n){var r=t,i=n.defaultSampleDuration||0,a=n.defaultSampleSize||0,o=n.trackId,s=[];return e.forEach(function(e){var t=qt.parseTrun(e),n=t.samples;n.forEach(function(e){void 0===e.duration&&(e.duration=i),void 0===e.size&&(e.size=a),e.trackId=o,e.dts=r,void 0===e.compositionTimeOffset&&(e.compositionTimeOffset=0),e.pts=r+e.compositionTimeOffset,r+=e.duration}),s=s.concat(n)}),s},Yt=function(e,t){var n=$.findBox(e,["moof","traf"]),r=$.findBox(e,["mdat"]),i={},a=[];return r.forEach(function(e,t){var r=n[t];a.push({mdat:e,traf:r})}),a.forEach(function(e){var n,r,a=e.mdat,o=e.traf,s=$.findBox(o,["tfhd"]),u=qt.parseTfhd(s[0]),l=u.trackId,c=$.findBox(o,["tfdt"]),d=c.length>0?qt.parseTfdt(c[0]).baseMediaDecodeTime:0,f=$.findBox(o,["trun"]);t===l&&f.length>0&&(n=$t(f,d,u),r=Wt(a,n,l),i[l]||(i[l]=[]),i[l]=i[l].concat(r))}),i},Kt=function(e,t,n){var r;return t?(r=Yt(e,t),{seiNals:r[t],timescale:n}):null},Xt=function(){var e,t,n,r,i,a=!1;this.isInitialized=function(){return a},this.init=function(){e=new Ht,a=!0,e.on("data",function(e){e.startTime=e.startPts/r,e.endTime=e.endPts/r,i.captions.push(e),i.captionStreams[e.stream]=!0})},this.isNewInit=function(e,t){return!(e&&0===e.length||t&&"object"==typeof t&&0===Object.keys(t).length||n===e[0]&&r===t[n])},this.parse=function(e,a,o){var s;if(!this.isInitialized())return null;if(!a||!o)return null;if(this.isNewInit(a,o))n=a[0],r=o[n];else if(!n||!r)return t.push(e),null;for(;t.length>0;){var u=t.shift();this.parse(u,a,o)}return null!==(s=Kt(e,n,r))&&s.seiNals?(this.pushNals(s.seiNals),this.flushStream(),i):null},this.pushNals=function(t){if(!this.isInitialized()||!t||0===t.length)return null;t.forEach(function(t){e.push(t)})},this.flushStream=function(){if(!this.isInitialized())return null;e.flush()},this.clearParsedCaptions=function(){i.captions=[],i.captionStreams={}},this.resetCaptionStream=function(){if(!this.isInitialized())return null;e.reset()},this.clearAllCaptions=function(){this.clearParsedCaptions(),this.resetCaptionStream()},this.reset=function(){t=[],n=null,r=null,i?this.clearParsedCaptions():i={captions:[],captionStreams:{}},this.resetCaptionStream()},this.reset()},Jt=Xt,Qt={generator:G,probe:$,Transmuxer:Mt.Transmuxer,AudioSegmentStream:Mt.AudioSegmentStream,VideoSegmentStream:Mt.VideoSegmentStream,CaptionParser:Jt},Zt=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},en=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),tn=function(e,t){t.on("data",function(t){var n=t.initSegment;t.initSegment={data:n.buffer,byteOffset:n.byteOffset,byteLength:n.byteLength};var r=t.data;t.data=r.buffer,e.postMessage({action:"data",segment:t,byteOffset:r.byteOffset,byteLength:r.byteLength},[t.data])}),t.captionStream&&t.captionStream.on("data",function(t){e.postMessage({action:"caption",data:t})}),t.on("done",function(t){e.postMessage({action:"done"})}),t.on("gopInfo",function(t){e.postMessage({action:"gopInfo",gopInfo:t})}),t.on("videoSegmentTimingInfo",function(t){e.postMessage({action:"videoSegmentTimingInfo",videoSegmentTimingInfo:t})})},nn=function(){function e(t,n){Zt(this,e),this.options=n||{},this.self=t,this.init()}return en(e,[{key:"init",value:function(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new Qt.Transmuxer(this.options),tn(this.self,this.transmuxer)}},{key:"push",value:function(e){var t=new Uint8Array(e.data,e.byteOffset,e.byteLength);this.transmuxer.push(t)}},{key:"reset",value:function(){this.init()}},{key:"setTimestampOffset",value:function(e){var t=e.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(9e4*t))}},{key:"setAudioAppendStart",value:function(e){this.transmuxer.setAudioAppendStart(Math.ceil(9e4*e.appendStart))}},{key:"flush",value:function(e){this.transmuxer.flush()}},{key:"resetCaptions",value:function(){this.transmuxer.resetCaptions()}},{key:"alignGopsWith",value:function(e){this.transmuxer.alignGopsWith(e.gopsToAlignWith.slice())}}]),e}();new function(e){e.onmessage=function(t){if("init"===t.data.action&&t.data.options)return void(this.messageHandlers=new nn(e,t.data.options));this.messageHandlers||(this.messageHandlers=new nn(e)),t.data&&t.data.action&&"init"!==t.data.action&&this.messageHandlers[t.data.action]&&this.messageHandlers[t.data.action](t.data)}}(n)}()}),Vh={videoCodec:"avc1",videoObjectTypeIndicator:".4d400d",audioProfile:"2"},qh=function(e){return e.map(function(e){return e.replace(/avc1\.(\d+)\.(\d+)/i,function(e,t,n){return"avc1."+("00"+Number(t).toString(16)).slice(-2)+"00"+("00"+Number(n).toString(16)).slice(-2)})})},Gh=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t={codecCount:0},n=void 0;return t.codecCount=e.split(",").length,t.codecCount=t.codecCount||2,n=/(^|\s|,)+(avc[13])([^ ,]*)/i.exec(e),n&&(t.videoCodec=n[2],t.videoObjectTypeIndicator=n[3]),t.audioProfile=/(^|\s|,)+mp4a.[0-9A-Fa-f]+\.([0-9A-Fa-f]+)/i.exec(e),t.audioProfile=t.audioProfile&&t.audioProfile[2],t},Hh=function(e){return e.replace(/avc1\.(\d+)\.(\d+)/i,function(e){return qh([e])[0]})},zh=function(e,t,n){return e+"/"+t+'; codecs="'+n.filter(function(e){return!!e}).join(", ")+'"'},Wh=function(e){return e.segments&&e.segments.length&&e.segments[0].map?"mp4":"mp2t"},$h=function(e){var t=e.attributes||{};return t.CODECS?Gh(t.CODECS):Vh},Yh=function(e,t){if(!e.mediaGroups.AUDIO||!t)return null;var n=e.mediaGroups.AUDIO[t];if(!n)return null;for(var r in n){var i=n[r];if(i.default&&i.playlists)return Gh(i.playlists[0].attributes.CODECS).audioProfile}return null},Kh=function(e,t){var n=Wh(t),r=$h(t),i=t.attributes||{},a=!0,o=!1;if(!t)return[];if(e.mediaGroups.AUDIO&&i.AUDIO){var s=e.mediaGroups.AUDIO[i.AUDIO];if(s){o=!0,a=!1;for(var u in s)if(!s[u].uri&&!s[u].playlists){a=!0;break}}}o&&!r.audioProfile&&(a||(r.audioProfile=Yh(e,i.AUDIO)),r.audioProfile||(ut.log.warn("Multiple audio tracks present but no audio codec string is specified. Attempting to use the default audio codec (mp4a.40.2)"),r.audioProfile=Vh.audioProfile));var l={};r.videoCodec&&(l.video=""+r.videoCodec+r.videoObjectTypeIndicator),r.audioProfile&&(l.audio="mp4a.40."+r.audioProfile);var c=zh("audio",n,[l.audio]),d=zh("video",n,[l.video]),f=zh("video",n,[l.video,l.audio]);return o?!a&&l.video?[d,c]:a||l.video?[f,c]:[c,c]:l.video?[f]:[c]},Xh=function(e){var t={type:"",parameters:{}},n=e.trim().split(";");return t.type=n.shift().trim(),n.forEach(function(e){var n=e.trim().split("=");if(n.length>1){var r=n[0].replace(/"/g,"").trim(),i=n[1].replace(/"/g,"").trim();t.parameters[r]=i}}),t},Jh=function(e){return/mp4a\.\d+.\d+/i.test(e)},Qh=function(e){return/avc1\.[\da-f]+/i.test(e)},Zh=function(e,t,n){if(void 0===t||null===t||!e.length)return[];var r=Math.ceil(9e4*(t-n+3)),i=void 0;for(i=0;i<e.length&&!(e[i].pts>r);i++);return e.slice(i)},ep=function(e,t,n){if(!t.length)return e;if(n)return t.slice();var r=t[0].pts,i=0;for(i;i<e.length&&!(e[i].pts>=r);i++);return e.slice(0,i).concat(t)},tp=function(e,t,n,r){for(var i=Math.ceil(9e4*(t-r)),a=Math.ceil(9e4*(n-r)),o=e.slice(),s=e.length;s--&&!(e[s].pts<=a););if(-1===s)return o;for(var u=s+1;u--&&!(e[u].pts<=i););return u=Math.max(u,0),o.splice(u,s-u+1),o},np=function(e,t,n){var r=null,i=null,a=0,o=[],s=[];if(!e&&!t)return ut.createTimeRange();if(!e)return t.buffered;if(!t)return e.buffered;if(n)return e.buffered;if(0===e.buffered.length&&0===t.buffered.length)return ut.createTimeRange();for(var u=e.buffered,l=t.buffered,c=u.length;c--;)o.push({time:u.start(c),type:"start"}),o.push({time:u.end(c),type:"end"});for(c=l.length;c--;)o.push({time:l.start(c),type:"start"}),o.push({time:l.end(c),type:"end"});for(o.sort(function(e,t){return e.time-t.time}),c=0;c<o.length;c++)"start"===o[c].type?2==++a&&(r=o[c].time):"end"===o[c].type&&1==--a&&(i=o[c].time),null!==r&&null!==i&&(s.push([r,i]),r=null,i=null);return ut.createTimeRanges(s)},rp=function(e,t){var n=e.addSourceBuffer(t),r=Object.create(null);r.updating=!1,r.realBuffer_=n;for(var i in n)!function(e){"function"==typeof n[e]?r[e]=function(){return n[e].apply(n,arguments)}:void 0===r[e]&&Object.defineProperty(r,e,{get:function(){return n[e]},set:function(t){return n[e]=t}})}(i);return r},ip=function(e){function t(e,n){lf(this,t);var r=hf(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,ut.EventTarget));r.timestampOffset_=0,r.pendingBuffers_=[],r.bufferUpdating_=!1,r.mediaSource_=e,r.codecs_=n,r.audioCodec_=null,r.videoCodec_=null,r.audioDisabled_=!1,r.appendAudioInitSegment_=!0,r.gopBuffer_=[],r.timeMapping_=0,r.safeAppend_=ut.browser.IE_VERSION>=11;var i={remux:!1,alignGopsAtEnd:r.safeAppend_};return r.codecs_.forEach(function(e){Jh(e)?r.audioCodec_=e:Qh(e)&&(r.videoCodec_=e)}),r.transmuxer_=new Fh,r.transmuxer_.postMessage({action:"init",options:i}),r.transmuxer_.onmessage=function(e){return"data"===e.data.action?r.data_(e):"done"===e.data.action?r.done_(e):"gopInfo"===e.data.action?r.appendGopInfo_(e):"videoSegmentTimingInfo"===e.data.action?r.videoSegmentTimingInfo_(e.data.videoSegmentTimingInfo):void 0},Object.defineProperty(r,"timestampOffset",{get:function(){return this.timestampOffset_},set:function(e){"number"==typeof e&&e>=0&&(this.timestampOffset_=e,this.appendAudioInitSegment_=!0,this.gopBuffer_.length=0,this.timeMapping_=0,this.transmuxer_.postMessage({action:"setTimestampOffset",timestampOffset:e}))}}),Object.defineProperty(r,"appendWindowStart",{get:function(){return(this.videoBuffer_||this.audioBuffer_).appendWindowStart},set:function(e){this.videoBuffer_&&(this.videoBuffer_.appendWindowStart=e),this.audioBuffer_&&(this.audioBuffer_.appendWindowStart=e)}}),Object.defineProperty(r,"updating",{get:function(){return!!(this.bufferUpdating_||!this.audioDisabled_&&this.audioBuffer_&&this.audioBuffer_.updating||this.videoBuffer_&&this.videoBuffer_.updating)}}),Object.defineProperty(r,"buffered",{get:function(){return np(this.videoBuffer_,this.audioBuffer_,this.audioDisabled_)}}),r}return ff(t,e),cf(t,[{key:"data_",value:function(e){var t=e.data.segment;t.data=new Uint8Array(t.data,e.data.byteOffset,e.data.byteLength),t.initSegment=new Uint8Array(t.initSegment.data,t.initSegment.byteOffset,t.initSegment.byteLength),Ah(this,this.mediaSource_,t),this.pendingBuffers_.push(t)}},{key:"done_",value:function(e){if("closed"===this.mediaSource_.readyState)return void(this.pendingBuffers_.length=0);this.processPendingSegments_()}},{key:"videoSegmentTimingInfo_",value:function(e){var t={start:{decode:e.start.dts/9e4,presentation:e.start.pts/9e4},end:{decode:e.end.dts/9e4,presentation:e.end.pts/9e4},baseMediaDecodeTime:e.baseMediaDecodeTime/9e4};e.prependedContentDuration&&(t.prependedContentDuration=e.prependedContentDuration/9e4),this.trigger({type:"videoSegmentTimingInfo",videoSegmentTimingInfo:t})}},{key:"createRealSourceBuffers_",value:function(){var e=this,t=["audio","video"];t.forEach(function(n){if(e[n+"Codec_"]&&!e[n+"Buffer_"]){var r=null;if(e.mediaSource_[n+"Buffer_"])r=e.mediaSource_[n+"Buffer_"],r.updating=!1;else{var i=n+"Codec_",a=n+'/mp4;codecs="'+e[i]+'"';r=rp(e.mediaSource_.nativeMediaSource_,a),e.mediaSource_[n+"Buffer_"]=r}e[n+"Buffer_"]=r,["update","updatestart","updateend"].forEach(function(i){r.addEventListener(i,function(){if("audio"!==n||!e.audioDisabled_)return"updateend"===i&&(e[n+"Buffer_"].updating=!1),t.every(function(t){return!("audio"!==t||!e.audioDisabled_)||n===t||!e[t+"Buffer_"]||!e[t+"Buffer_"].updating})?e.trigger(i):void 0})})}})}},{key:"appendBuffer",value:function(e){if(this.bufferUpdating_=!0,this.audioBuffer_&&this.audioBuffer_.buffered.length){var t=this.audioBuffer_.buffered;this.transmuxer_.postMessage({action:"setAudioAppendStart",appendStart:t.end(t.length-1)})}this.videoBuffer_&&this.transmuxer_.postMessage({action:"alignGopsWith",gopsToAlignWith:Zh(this.gopBuffer_,this.mediaSource_.player_?this.mediaSource_.player_.currentTime():null,this.timeMapping_)}),this.transmuxer_.postMessage({action:"push",data:e.buffer,byteOffset:e.byteOffset,byteLength:e.byteLength},[e.buffer]),this.transmuxer_.postMessage({action:"flush"})}},{key:"appendGopInfo_",value:function(e){this.gopBuffer_=ep(this.gopBuffer_,e.data.gopInfo,this.safeAppend_)}},{key:"remove",value:function(e,t){if(this.videoBuffer_&&(this.videoBuffer_.updating=!0,this.videoBuffer_.remove(e,t),this.gopBuffer_=tp(this.gopBuffer_,e,t,this.timeMapping_)),!this.audioDisabled_&&this.audioBuffer_&&(this.audioBuffer_.updating=!0,this.audioBuffer_.remove(e,t)),Ch(e,t,this.metadataTrack_),this.inbandTextTracks_)for(var n in this.inbandTextTracks_)Ch(e,t,this.inbandTextTracks_[n])}},{key:"processPendingSegments_",value:function(){var e={video:{segments:[],bytes:0},audio:{segments:[],bytes:0},captions:[],metadata:[]};e=this.pendingBuffers_.reduce(function(e,t){var n=t.type,r=t.data,i=t.initSegment;return e[n].segments.push(r),e[n].bytes+=r.byteLength,e[n].initSegment=i,t.captions&&(e.captions=e.captions.concat(t.captions)),t.info&&(e[n].info=t.info),t.metadata&&(e.metadata=e.metadata.concat(t.metadata)),e},e),this.videoBuffer_||this.audioBuffer_||(0===e.video.bytes&&(this.videoCodec_=null),0===e.audio.bytes&&(this.audioCodec_=null),this.createRealSourceBuffers_()),e.audio.info&&this.mediaSource_.trigger({type:"audioinfo",info:e.audio.info}),e.video.info&&this.mediaSource_.trigger({type:"videoinfo",info:e.video.info}),this.appendAudioInitSegment_&&(!this.audioDisabled_&&this.audioBuffer_&&(e.audio.segments.unshift(e.audio.initSegment),e.audio.bytes+=e.audio.initSegment.byteLength),this.appendAudioInitSegment_=!1);var t=!1;this.videoBuffer_&&e.video.bytes?(e.video.segments.unshift(e.video.initSegment),e.video.bytes+=e.video.initSegment.byteLength,this.concatAndAppendSegments_(e.video,this.videoBuffer_)):!this.videoBuffer_||!this.audioDisabled_&&this.audioBuffer_||(t=!0),jh(this,e.captions,e.metadata),!this.audioDisabled_&&this.audioBuffer_&&this.concatAndAppendSegments_(e.audio,this.audioBuffer_),this.pendingBuffers_.length=0,t&&this.trigger("updateend"),this.bufferUpdating_=!1}},{key:"concatAndAppendSegments_",value:function(e,t){var n=0,r=void 0;if(e.bytes){r=new Uint8Array(e.bytes),e.segments.forEach(function(e){r.set(e,n),n+=e.byteLength});try{t.updating=!0,t.appendBuffer(r)}catch(e){this.mediaSource_.player_&&this.mediaSource_.player_.error({code:-3,type:"APPEND_BUFFER_ERR",message:e.message,originalError:e})}}}},{key:"abort",value:function(){this.videoBuffer_&&this.videoBuffer_.abort(),!this.audioDisabled_&&this.audioBuffer_&&this.audioBuffer_.abort(),this.transmuxer_&&this.transmuxer_.postMessage({action:"reset"}),this.pendingBuffers_.length=0,this.bufferUpdating_=!1}}]),t}(ut.EventTarget),ap=function(n){function r(){lf(this,r);var n=hf(this,(r.__proto__||Object.getPrototypeOf(r)).call(this)),i=void 0;n.nativeMediaSource_=new e.MediaSource;for(i in n.nativeMediaSource_)i in r.prototype||"function"!=typeof n.nativeMediaSource_[i]||(n[i]=n.nativeMediaSource_[i].bind(n.nativeMediaSource_));return n.duration_=NaN,Object.defineProperty(n,"duration",{get:function(){return this.duration_===1/0?this.duration_:this.nativeMediaSource_.duration},set:function(e){if(this.duration_=e,e!==1/0)return void(this.nativeMediaSource_.duration=e)}}),Object.defineProperty(n,"seekable",{get:function(){return this.duration_===1/0?ut.createTimeRanges([[0,this.nativeMediaSource_.duration]]):this.nativeMediaSource_.seekable}}),Object.defineProperty(n,"readyState",{get:function(){return this.nativeMediaSource_.readyState}}),Object.defineProperty(n,"activeSourceBuffers",{get:function(){return this.activeSourceBuffers_}}),n.sourceBuffers=[],n.activeSourceBuffers_=[],n.updateActiveSourceBuffers_=function(){if(n.activeSourceBuffers_.length=0,1===n.sourceBuffers.length){var e=n.sourceBuffers[0];return e.appendAudioInitSegment_=!0,e.audioDisabled_=!e.audioCodec_,void n.activeSourceBuffers_.push(e)}for(var t=!1,r=!0,i=0;i<n.player_.audioTracks().length;i++){var a=n.player_.audioTracks()[i];if(a.enabled&&"main"!==a.kind){t=!0,r=!1;break}}n.sourceBuffers.forEach(function(e,i){if(e.appendAudioInitSegment_=!0,e.videoCodec_&&e.audioCodec_)e.audioDisabled_=t;else if(e.videoCodec_&&!e.audioCodec_)e.audioDisabled_=!0,r=!1;else if(!e.videoCodec_&&e.audioCodec_&&(e.audioDisabled_=i?r:!r,e.audioDisabled_))return;n.activeSourceBuffers_.push(e)})},n.onPlayerMediachange_=function(){n.sourceBuffers.forEach(function(e){e.appendAudioInitSegment_=!0})},n.onHlsReset_=function(){n.sourceBuffers.forEach(function(e){e.transmuxer_&&e.transmuxer_.postMessage({action:"resetCaptions"})})},n.onHlsSegmentTimeMapping_=function(e){n.sourceBuffers.forEach(function(t){return t.timeMapping_=e.mapping})},["sourceopen","sourceclose","sourceended"].forEach(function(e){this.nativeMediaSource_.addEventListener(e,this.trigger.bind(this))},n),n.on("sourceopen",function(e){var r=t.querySelector('[src="'+n.url_+'"]');r&&(n.player_=ut(r.parentNode),n.player_&&(n.player_.tech_.on("hls-reset",n.onHlsReset_),n.player_.tech_.on("hls-segment-time-mapping",n.onHlsSegmentTimeMapping_),n.player_.audioTracks&&n.player_.audioTracks()&&(n.player_.audioTracks().on("change",n.updateActiveSourceBuffers_),n.player_.audioTracks().on("addtrack",n.updateActiveSourceBuffers_),n.player_.audioTracks().on("removetrack",n.updateActiveSourceBuffers_)),n.player_.on("mediachange",n.onPlayerMediachange_)))}),n.on("sourceended",function(e){for(var t=xh(n.duration),r=0;r<n.sourceBuffers.length;r++){var i=n.sourceBuffers[r],a=i.metadataTrack_&&i.metadataTrack_.cues;a&&a.length&&(a[a.length-1].endTime=t)}}),n.on("sourceclose",function(e){this.sourceBuffers.forEach(function(e){e.transmuxer_&&e.transmuxer_.terminate()}),this.sourceBuffers.length=0,this.player_&&(this.player_.audioTracks&&this.player_.audioTracks()&&(this.player_.audioTracks().off("change",this.updateActiveSourceBuffers_),this.player_.audioTracks().off("addtrack",this.updateActiveSourceBuffers_),this.player_.audioTracks().off("removetrack",this.updateActiveSourceBuffers_)),this.player_.el_&&this.player_.off("mediachange",this.onPlayerMediachange_),this.player_.tech_&&this.player_.tech_.el_&&(this.player_.tech_.off("hls-reset",this.onHlsReset_),this.player_.tech_.off("hls-segment-time-mapping",this.onHlsSegmentTimeMapping_)))}),n}return ff(r,n),cf(r,[{key:"addSeekableRange_",value:function(e,t){var n=void 0;if(this.duration!==1/0)throw n=new Error("MediaSource.addSeekableRange() can only be invoked when the duration is Infinity"),n.name="InvalidStateError",n.code=11,n;(t>this.nativeMediaSource_.duration||isNaN(this.nativeMediaSource_.duration))&&(this.nativeMediaSource_.duration=t)}},{key:"addSourceBuffer",value:function(e){var t=void 0,n=Xh(e);if(/^(video|audio)\/mp2t$/i.test(n.type)){var r=[];n.parameters&&n.parameters.codecs&&(r=n.parameters.codecs.split(","),r=qh(r),r=r.filter(function(e){return Jh(e)||Qh(e)})),0===r.length&&(r=["avc1.4d400d","mp4a.40.2"]),t=new ip(this,r),0!==this.sourceBuffers.length&&(this.sourceBuffers[0].createRealSourceBuffers_(),t.createRealSourceBuffers_(),this.sourceBuffers[0].audioDisabled_=!0)}else t=this.nativeMediaSource_.addSourceBuffer(e);return this.sourceBuffers.push(t),t}}]),r}(ut.EventTarget),op=0;ut.mediaSources={};var sp=function(e,t){var n=ut.mediaSources[e];if(!n)throw new Error("Media Source not found (Video.js)");n.trigger({type:"sourceopen",swfId:t})},up=function(){return!!e.MediaSource&&!!e.MediaSource.isTypeSupported&&e.MediaSource.isTypeSupported('video/mp4;codecs="avc1.4d400d,mp4a.40.2"')},lp=function(){if(this.MediaSource={open:sp,supportsNativeMediaSources:up},up())return new ap;throw new Error("Cannot use create a virtual MediaSource for this video")};lp.open=sp,lp.supportsNativeMediaSources=up;var cp={createObjectURL:function(t){var n=void 0;return t instanceof ap?(n=e.URL.createObjectURL(t.nativeMediaSource_),t.url_=n,n):t instanceof ap?(n="blob:vjs-media-source/"+op,op++,ut.mediaSources[n]=t,n):(n=e.URL.createObjectURL(t),t.url_=n,n)}};ut.MediaSource=lp,ut.URL=cp;var dp=ut.EventTarget,fp=ut.mergeOptions,hp=function(e,t){for(var n=void 0,r=fp(e,{duration:t.duration,minimumUpdatePeriod:t.minimumUpdatePeriod}),i=0;i<t.playlists.length;i++){var a=Tf(r,t.playlists[i]);a?r=a:n=!0}return yf(t,function(e,t,i,a){if(e.playlists&&e.playlists.length){var o=e.playlists[0].uri,s=Tf(r,e.playlists[0]);s&&(r=s,r.mediaGroups[t][i][a].playlists[0]=r.playlists[o],n=!1)}}),n?null:r},pp=function(e){var t=e.byterange.offset+e.byterange.length-1;return e.uri+"-"+e.byterange.offset+"-"+t},mp=function(e,t){return(Boolean(!e.map&&!t.map)||Boolean(e.map&&t.map&&e.map.byterange.offset===t.map.byterange.offset&&e.map.byterange.length===t.map.byterange.length))&&e.uri===t.uri&&e.byterange.offset===t.byterange.offset&&e.byterange.length===t.byterange.length},vp=function(e,t){var n={};for(var r in e){var i=e[r],a=i.sidx;if(a){var o=pp(a);if(!t[o])break;var s=t[o].sidxInfo;mp(s,a)&&(n[o]=t[o])}}return n},gp=function(e,t,n,r){var i=Ou(e,{manifestUri:t,clientOffset:n}),a=vp(i.playlists,r),o=a;return yf(i,function(e,t,n,i){if(e.playlists&&e.playlists.length){var a=e.playlists;o=fp(o,vp(a,r))}}),o},yp=function(e,t,n,r,i){var a={uri:uf(r.handleManifestRedirects,e.resolvedUri),byterange:e.byterange,playlist:t};return n(ut.mergeOptions(a,{responseType:"arraybuffer",headers:eh(a)}),i)},_p=function(t){function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments[3];lf(this,n);var a=hf(this,(n.__proto__||Object.getPrototypeOf(n)).call(this)),o=r.withCredentials,s=void 0!==o&&o,u=r.handleManifestRedirects,l=void 0!==u&&u;if(a.hls_=t,a.withCredentials=s,a.handleManifestRedirects=l,!e)throw new Error("A non-empty playlist URL or playlist is required");return a.on("minimumUpdatePeriod",function(){a.refreshXml_()}),a.on("mediaupdatetimeout",function(){a.refreshMedia_(a.media().uri)}),a.state="HAVE_NOTHING",a.loadedPlaylists_={},"string"==typeof e?(a.srcUrl=e,a.sidxMapping_={},hf(a)):(a.setupChildLoader(i,e),a)}return ff(n,t),cf(n,[{key:"setupChildLoader",value:function(e,t){this.masterPlaylistLoader_=e,this.childPlaylist_=t}},{key:"dispose",value:function(){this.stopRequest(),this.loadedPlaylists_={},e.clearTimeout(this.minimumUpdatePeriodTimeout_),e.clearTimeout(this.mediaRequest_),e.clearTimeout(this.mediaUpdateTimeout)}},{key:"hasPendingRequest",value:function(){return this.request||this.mediaRequest_}},{key:"stopRequest",value:function(){if(this.request){var e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}},{key:"sidxRequestFinished_",value:function(e,t,n,r){var i=this;return function(a,o){if(i.request){if(i.request=null,a)return i.error={status:o.status,message:"DASH playlist request error at URL: "+e.uri,response:o.response,code:2},n&&(i.state=n),i.trigger("error"),r(t,null);var s=new Uint8Array(o.response),u=Al.parseSidx(s.subarray(8));return r(t,u)}}}},{key:"media",value:function(t){var n=this;if(!t)return this.media_;if("HAVE_NOTHING"===this.state)throw new Error("Cannot switch media playlist from "+this.state);var r=this.state;if("string"==typeof t){if(!this.master.playlists[t])throw new Error("Unknown playlist URI: "+t);t=this.master.playlists[t]}var i=!this.media_||t.uri!==this.media_.uri;if(i&&this.loadedPlaylists_[t.uri]&&this.loadedPlaylists_[t.uri].endList)return this.state="HAVE_METADATA",this.media_=t,void(i&&(this.trigger("mediachanging"),this.trigger("mediachange")));if(i){if(this.media_&&this.trigger("mediachanging"),!t.sidx)return void(this.mediaRequest_=e.setTimeout(this.haveMetadata.bind(this,{startingState:r,playlist:t}),0));var a=void 0,o=void 0;this.masterPlaylistLoader_?(a=this.masterPlaylistLoader_.master,o=this.masterPlaylistLoader_.sidxMapping_):(a=this.master,o=this.sidxMapping_);var s=pp(t.sidx);o[s]={sidxInfo:t.sidx},this.request=yp(t.sidx,t,this.hls_.xhr,{handleManifestRedirects:this.handleManifestRedirects},this.sidxRequestFinished_(t,a,r,function(e,i){if(!e||!i)throw new Error("failed to request sidx");o[s].sidx=i,n.haveMetadata({startingState:r,playlist:e.playlists[t.uri]})}))}}},{key:"haveMetadata",value:function(e){var t=e.startingState,n=e.playlist;this.state="HAVE_METADATA",this.loadedPlaylists_[n.uri]=n,this.mediaRequest_=null,this.refreshMedia_(n.uri),"HAVE_MASTER"===t?this.trigger("loadedmetadata"):this.trigger("mediachange")}},{key:"pause",value:function(){this.stopRequest(),e.clearTimeout(this.mediaUpdateTimeout),e.clearTimeout(this.minimumUpdatePeriodTimeout_),"HAVE_NOTHING"===this.state&&(this.started=!1)}},{key:"load",value:function(t){var n=this;e.clearTimeout(this.mediaUpdateTimeout),e.clearTimeout(this.minimumUpdatePeriodTimeout_);var r=this.media();if(t){var i=r?r.targetDuration/2*1e3:5e3;return void(this.mediaUpdateTimeout=e.setTimeout(function(){return n.load()},i))}if(!this.started)return void this.start();this.trigger("loadedplaylist")}},{key:"parseMasterXml",value:function(){var e=Ou(this.masterXml_,{manifestUri:this.srcUrl,clientOffset:this.clientOffset_,sidxMapping:this.sidxMapping_});e.uri=this.srcUrl;for(var t=0;t<e.playlists.length;t++){var n="placeholder-uri-"+t;e.playlists[t].uri=n,e.playlists[n]=e.playlists[t]}return yf(e,function(t,n,r,i){if(t.playlists&&t.playlists.length){var a="placeholder-uri-"+n+"-"+r+"-"+i;t.playlists[0].uri=a,e.playlists[a]=t.playlists[0]}}),Sf(e),wf(e),e}},{key:"start",value:function(){var t=this;if(this.started=!0,this.masterPlaylistLoader_)return void(this.mediaRequest_=e.setTimeout(this.haveMaster_.bind(this),0));this.request=this.hls_.xhr({uri:this.srcUrl,withCredentials:this.withCredentials},function(e,n){if(t.request){if(t.request=null,e)return t.error={status:n.status,message:"DASH playlist request error at URL: "+t.srcUrl,responseText:n.responseText,code:2},"HAVE_NOTHING"===t.state&&(t.started=!1),t.trigger("error");t.masterXml_=n.responseText,n.responseHeaders&&n.responseHeaders.date?t.masterLoaded_=Date.parse(n.responseHeaders.date):t.masterLoaded_=Date.now(),t.srcUrl=uf(t.handleManifestRedirects,t.srcUrl,n),t.syncClientServerClock_(t.onClientServerClockSync_.bind(t))}})}},{key:"syncClientServerClock_",value:function(e){var t=this,n=Iu(this.masterXml_);return null===n?(this.clientOffset_=this.masterLoaded_-Date.now(),e()):"DIRECT"===n.method?(this.clientOffset_=n.value-Date.now(),e()):void(this.request=this.hls_.xhr({uri:sf(this.srcUrl,n.value),method:n.method,withCredentials:this.withCredentials},function(r,i){if(t.request){if(r)return t.clientOffset_=t.masterLoaded_-Date.now(),e();var a=void 0;a="HEAD"===n.method?i.responseHeaders&&i.responseHeaders.date?Date.parse(i.responseHeaders.date):t.masterLoaded_:Date.parse(i.responseText),t.clientOffset_=a-Date.now(),e()}}))}},{key:"haveMaster_",value:function(){this.state="HAVE_MASTER",this.mediaRequest_=null,this.masterPlaylistLoader_?this.media_||this.media(this.childPlaylist_):(this.master=this.parseMasterXml(),this.trigger("loadedplaylist"))}},{key:"onClientServerClockSync_",value:function(){var t=this;this.haveMaster_(),this.hasPendingRequest()||this.media_||this.media(this.master.playlists[0]),this.master&&this.master.minimumUpdatePeriod&&(this.minimumUpdatePeriodTimeout_=e.setTimeout(function(){t.trigger("minimumUpdatePeriod")},this.master.minimumUpdatePeriod))}},{key:"refreshXml_",value:function(){var t=this;this.request=this.hls_.xhr({uri:this.srcUrl,withCredentials:this.withCredentials},function(n,r){if(t.request){if(t.request=null,n)return t.error={status:r.status,message:"DASH playlist request error at URL: "+t.srcUrl,responseText:r.responseText,code:2},"HAVE_NOTHING"===t.state&&(t.started=!1),t.trigger("error");t.masterXml_=r.responseText,t.sidxMapping_=gp(t.masterXml_,t.srcUrl,t.clientOffset_,t.sidxMapping_);var i=t.parseMasterXml(),a=hp(t.master,i);if(a){var o=pp(t.media().sidx);if(t.sidxMapping_[o])t.master=a;else{var s=t.media();t.request=yp(s.sidx,s,t.hls_.xhr,{handleManifestRedirects:t.handleManifestRedirects},t.sidxRequestFinished_(s,i,t.state,function(n,r){if(!n||!r)throw new Error("failed to request sidx on minimumUpdatePeriod");t.sidxMapping_[o].sidx=r,t.minimumUpdatePeriodTimeout_=e.setTimeout(function(){t.trigger("minimumUpdatePeriod")},t.master.minimumUpdatePeriod),t.refreshMedia_(t.media().uri)}))}}t.minimumUpdatePeriodTimeout_=e.setTimeout(function(){t.trigger("minimumUpdatePeriod")},t.master.minimumUpdatePeriod)}})}},{key:"refreshMedia_",value:function(t){var n=this;if(!t)throw new Error("refreshMedia_ must take a media uri");var r=void 0,i=void 0;this.masterPlaylistLoader_?(r=this.masterPlaylistLoader_.master,i=this.masterPlaylistLoader_.parseMasterXml()):(r=this.master,i=this.parseMasterXml());var a=hp(r,i);a?(this.masterPlaylistLoader_?this.masterPlaylistLoader_.master=a:this.master=a,this.media_=a.playlists[t]):(this.media_=i.playlists[t],this.trigger("playlistunchanged")),this.media().endList||(this.mediaUpdateTimeout=e.setTimeout(function(){n.trigger("mediaupdatetimeout")},kf(this.media(),!!a))),this.trigger("loadedplaylist")}}]),n}(dp),bp=function(e){return ut.log.debug?ut.log.debug.bind(ut,"VHS:",e+" >"):function(){}},Tp=function(){function e(t,n,r,i){lf(this,e),this.callbacks_=[],this.pendingCallback_=null,this.timestampOffset_=0,this.mediaSource=t,this.processedAppend_=!1,this.type_=r,this.mimeType_=n,this.logger_=bp("SourceUpdater["+r+"]["+n+"]"),"closed"===t.readyState?t.addEventListener("sourceopen",this.createSourceBuffer_.bind(this,n,i)):this.createSourceBuffer_(n,i)}return cf(e,[{key:"createSourceBuffer_",value:function(e,t){var n=this;if(this.sourceBuffer_=this.mediaSource.addSourceBuffer(e),this.logger_("created SourceBuffer"),t&&(t.trigger("sourcebufferadded"),this.mediaSource.sourceBuffers.length<2))return void t.on("sourcebufferadded",function(){n.start_()});this.start_()}},{key:"start_",value:function(){var e=this;this.started_=!0,this.onUpdateendCallback_=function(){var t=e.pendingCallback_;e.pendingCallback_=null,e.sourceBuffer_.removing=!1,e.logger_("buffered ["+wh(e.buffered())+"]"),t&&t(),e.runCallback_()},this.sourceBuffer_.addEventListener("updateend",this.onUpdateendCallback_),this.runCallback_()}},{key:"abort",value:function(e){var t=this;this.processedAppend_&&this.queueCallback_(function(){t.sourceBuffer_.abort()},e)}},{key:"appendBuffer",value:function(e,t){var n=this;this.processedAppend_=!0,this.queueCallback_(function(){e.videoSegmentTimingInfoCallback&&n.sourceBuffer_.addEventListener("videoSegmentTimingInfo",e.videoSegmentTimingInfoCallback),n.sourceBuffer_.appendBuffer(e.bytes)},function(){e.videoSegmentTimingInfoCallback&&n.sourceBuffer_.removeEventListener("videoSegmentTimingInfo",e.videoSegmentTimingInfoCallback),t()})}},{key:"buffered",value:function(){return this.sourceBuffer_?this.sourceBuffer_.buffered:ut.createTimeRanges()}},{key:"remove",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:gt;this.processedAppend_&&this.queueCallback_(function(){n.logger_("remove ["+e+" => "+t+"]"),n.sourceBuffer_.removing=!0,n.sourceBuffer_.remove(e,t)},r)}},{key:"updating",value:function(){return!this.sourceBuffer_||this.sourceBuffer_.updating||!!this.pendingCallback_&&this.pendingCallback_!==gt}},{key:"timestampOffset",value:function(e){var t=this;return void 0!==e&&(this.queueCallback_(function(){t.sourceBuffer_.timestampOffset=e,t.runCallback_()}),this.timestampOffset_=e),this.timestampOffset_}},{key:"queueCallback_",value:function(e,t){this.callbacks_.push([e.bind(this),t]),this.runCallback_()}},{key:"runCallback_",value:function(){var e=void 0;!this.updating()&&this.callbacks_.length&&this.started_&&(e=this.callbacks_.shift(),this.pendingCallback_=e[1],e[0]())}},{key:"dispose",value:function(){var e=this,t=function t(){e.sourceBuffer_&&"open"===e.mediaSource.readyState&&e.sourceBuffer_.abort(),e.sourceBuffer_.removeEventListener("updateend",t)};this.sourceBuffer_.removeEventListener("updateend",this.onUpdateendCallback_),this.sourceBuffer_.removing?this.sourceBuffer_.addEventListener("updateend",t):t()}}]),e}(),Sp={GOAL_BUFFER_LENGTH:30,MAX_GOAL_BUFFER_LENGTH:60,GOAL_BUFFER_LENGTH_RATE:1,INITIAL_BANDWIDTH:4194304,BANDWIDTH_VARIANCE:1.2,BUFFER_LOW_WATER_LINE:0,MAX_BUFFER_LOW_WATER_LINE:30,BUFFER_LOW_WATER_LINE_RATE:1},wp={FAILURE:2,TIMEOUT:-101,ABORTED:-102},kp=function(e){e.forEach(function(e){e.abort()})},Ep=function(e){return{bandwidth:e.bandwidth,bytesReceived:e.bytesReceived||0,roundTripTime:e.roundTripTime||0}},Ap=function(e){var t=e.target,n=Date.now()-t.requestTime,r={bandwidth:1/0,bytesReceived:0,roundTripTime:n||0};return r.bytesReceived=e.loaded,r.bandwidth=Math.floor(r.bytesReceived/r.roundTripTime*8*1e3),r},Cp=function(e,t){return t.timedout?{status:t.status,message:"HLS request timed-out at URL: "+t.uri,code:wp.TIMEOUT,xhr:t}:t.aborted?{status:t.status,message:"HLS request aborted at URL: "+t.uri,code:wp.ABORTED,xhr:t}:e?{status:t.status,message:"HLS request errored at URL: "+t.uri,code:wp.FAILURE,xhr:t}:null},Lp=function(e,t){return function(n,r){var i=r.response,a=Cp(n,r);if(a)return t(a,e);if(16!==i.byteLength)return t({status:r.status,message:"Invalid HLS key at URL: "+r.uri,code:wp.FAILURE,xhr:r},e);var o=new DataView(i);return e.key.bytes=new Uint32Array([o.getUint32(0),o.getUint32(4),o.getUint32(8),o.getUint32(12)]),t(null,e)}},xp=function(e,t,n){return function(r,i){var a=i.response,o=Cp(r,i);return o?n(o,e):0===a.byteLength?n({status:i.status,message:"Empty HLS segment content at URL: "+i.uri,code:wp.FAILURE,xhr:i},e):(e.map.bytes=new Uint8Array(i.response),t&&!t.isInitialized()&&t.init(),e.map.timescales=Bu.timescale(e.map.bytes),e.map.videoTrackIds=Bu.videoTrackIds(e.map.bytes),n(null,e))}},jp=function(e,t,n){return function(r,i){var a=i.response,o=Cp(r,i),s=void 0;return o?n(o,e):0===a.byteLength?n({status:i.status,message:"Empty HLS segment content at URL: "+i.uri,code:wp.FAILURE,xhr:i},e):(e.stats=Ep(i),e.key?e.encryptedBytes=new Uint8Array(i.response):e.bytes=new Uint8Array(i.response),t&&e.map&&e.map.bytes&&(t.isInitialized()||t.init(),(s=t.parse(e.bytes,e.map.videoTrackIds,e.map.timescales))&&s.captions&&(e.captionStreams=s.captionStreams,e.fmp4Captions=s.captions)),n(null,e))}},Op=function(e,t,n){var r=function r(i){if(i.data.source===t.requestId){e.removeEventListener("message",r);var a=i.data.decrypted;return t.bytes=new Uint8Array(a.bytes,a.byteOffset,a.byteLength),n(null,t)}};e.addEventListener("message",r);var i=void 0;i=t.key.bytes.slice?t.key.bytes.slice():new Uint32Array(Array.prototype.slice.call(t.key.bytes)),e.postMessage(ih({source:t.requestId,encrypted:t.encryptedBytes,key:i,iv:t.key.iv}),[t.encryptedBytes.buffer,i.buffer])},Ip=function(e,t,n){var r=0,i=!1;return function(a,o){if(!i)return a?(i=!0,kp(e),n(a,o)):(r+=1,r===e.length?(o.endOfAllRequests=Date.now(),o.encryptedBytes?Op(t,o,n):n(null,o)):void 0)}},Pp=function(e,t){return function(n){return e.stats=ut.mergeOptions(e.stats,Ap(n)),!e.stats.firstBytesReceivedAt&&e.stats.bytesReceived&&(e.stats.firstBytesReceivedAt=Date.now()),t(n,e)}},Rp=function(e,t,n,r,i,a,o){var s=[],u=Ip(s,n,o);if(i.key&&!i.key.bytes){var l=ut.mergeOptions(t,{uri:i.key.resolvedUri,responseType:"arraybuffer"}),c=Lp(i,u),d=e(l,c);s.push(d)}if(i.map&&!i.map.bytes){var f=ut.mergeOptions(t,{uri:i.map.resolvedUri,responseType:"arraybuffer",headers:eh(i.map)}),h=xp(i,r,u),p=e(f,h);s.push(p)}var m=ut.mergeOptions(t,{uri:i.resolvedUri,responseType:"arraybuffer",headers:eh(i)}),v=jp(i,r,u),g=e(m,v);return g.addEventListener("progress",Pp(i,a)),s.push(g),function(){return kp(s)}},Dp=function(t,n){var r=void 0;return t?(r=e.getComputedStyle(t),r?r[n]:""):""},Mp=function(e,t){var n=e.slice();e.sort(function(e,r){var i=t(e,r);return 0===i?n.indexOf(e)-n.indexOf(r):i})},Up=function(t,n){var r=void 0,i=void 0;return t.attributes.BANDWIDTH&&(r=t.attributes.BANDWIDTH),r=r||e.Number.MAX_VALUE,n.attributes.BANDWIDTH&&(i=n.attributes.BANDWIDTH),i=i||e.Number.MAX_VALUE,r-i},Bp=function(t,n){var r=void 0,i=void 0;return t.attributes.RESOLUTION&&t.attributes.RESOLUTION.width&&(r=t.attributes.RESOLUTION.width),r=r||e.Number.MAX_VALUE,n.attributes.RESOLUTION&&n.attributes.RESOLUTION.width&&(i=n.attributes.RESOLUTION.width),i=i||e.Number.MAX_VALUE,r===i&&t.attributes.BANDWIDTH&&n.attributes.BANDWIDTH?t.attributes.BANDWIDTH-n.attributes.BANDWIDTH:r-i},Np=function(t,n,r,i,a){var o=t.playlists.map(function(t){var n=void 0,r=void 0,i=void 0;return n=t.attributes.RESOLUTION&&t.attributes.RESOLUTION.width,r=t.attributes.RESOLUTION&&t.attributes.RESOLUTION.height,i=t.attributes.BANDWIDTH,i=i||e.Number.MAX_VALUE,{bandwidth:i,width:n,height:r,playlist:t}});Mp(o,function(e,t){return e.bandwidth-t.bandwidth}),o=o.filter(function(e){return!Kf.isIncompatible(e.playlist)});var s=o.filter(function(e){return Kf.isEnabled(e.playlist)});s.length||(s=o.filter(function(e){return!Kf.isDisabled(e.playlist)}));var u=s.filter(function(e){return e.bandwidth*Sp.BANDWIDTH_VARIANCE<n}),l=u[u.length-1],c=u.filter(function(e){return e.bandwidth===l.bandwidth})[0];if(!1===a){var d=c||s[0]||o[0];return d?d.playlist:null}var f=u.filter(function(e){return e.width&&e.height});Mp(f,function(e,t){return e.width-t.width});var h=f.filter(function(e){return e.width===r&&e.height===i});l=h[h.length-1];var p=h.filter(function(e){return e.bandwidth===l.bandwidth})[0],m=void 0,v=void 0,g=void 0;p||(m=f.filter(function(e){return e.width>r||e.height>i}),v=m.filter(function(e){return e.width===m[0].width&&e.height===m[0].height}),l=v[v.length-1],g=v.filter(function(e){return e.bandwidth===l.bandwidth})[0]);var y=g||p||c||s[0]||o[0];return y?y.playlist:null},Fp=function(){return Np(this.playlists.master,this.systemBandwidth,parseInt(Dp(this.tech_.el(),"width"),10),parseInt(Dp(this.tech_.el(),"height"),10),this.limitRenditionByPlayerDimensions)},Vp=function(e){var t=e.master,n=e.currentTime,r=e.bandwidth,i=e.duration,a=e.segmentDuration,o=e.timeUntilRebuffer,s=e.currentTimeline,u=e.syncController,l=t.playlists.filter(function(e){return!Kf.isIncompatible(e)}),c=l.filter(Kf.isEnabled);c.length||(c=l.filter(function(e){return!Kf.isDisabled(e)}));var d=c.filter(Kf.hasAttribute.bind(null,"BANDWIDTH")),f=d.map(function(e){var t=u.getSyncPoint(e,i,s,n),l=t?1:2;return{playlist:e,rebufferingImpact:Kf.estimateSegmentRequestTime(a,r,e)*l-o}}),h=f.filter(function(e){return e.rebufferingImpact<=0});return Mp(h,function(e,t){return Up(t.playlist,e.playlist)}),h.length?h[0]:(Mp(f,function(e,t){return e.rebufferingImpact-t.rebufferingImpact}),f[0]||null)},qp=function(){var e=this.playlists.master.playlists.filter(Kf.isEnabled);return Mp(e,function(e,t){return Up(e,t)}),e.filter(function(e){return Gh(e.attributes.CODECS).videoCodec})[0]||null},Gp=function(e,t,n){for(var r in n)if(!e[r]){t.trigger({type:"usage",name:"hls-608"});var i=t.textTracks().getTrackById(r);e[r]=i||t.addRemoteTextTrack({kind:"captions",id:r,label:r},!1).track}},Hp=function(e){var t=e.inbandTextTracks,n=e.captionArray,r=e.timestampOffset;if(n){var i=window.WebKitDataCue||window.VTTCue;n.forEach(function(e){var n=e.stream,a=e.startTime,o=e.endTime;t[n]&&(a+=r,o+=r,t[n].addCue(new i(a,o,e.text)))})}},zp=function(e,t,n){if(!e||!t)return!1;var r=e.segments,i=n===r.length;return e.endList&&"open"===t.readyState&&i},Wp=function(e){return"number"==typeof e&&isFinite(e)},$p=function(e,t,n){return"main"===e&&t&&n?n.containsAudio||n.containsVideo?t.containsVideo&&!n.containsVideo?"Only audio found in segment when we expected video. We can't switch to audio only from a stream that had video. To get rid of this message, please add codec information to the manifest.":!t.containsVideo&&n.containsVideo?"Video found in segment when we expected only audio. We can't switch to a stream with video from an audio only stream. To get rid of this message, please add codec information to the manifest.":null:"Neither audio nor video found in segment.":null},Yp=function(e,t,n){var r=void 0;return r=e.length&&e.start(0)>0&&e.start(0)<t?e.start(0):t-30,Math.min(r,t-n)},Kp=function(e){var t=e.segment,n=t.start,r=t.end,i=e.playlist,a=i.mediaSequence,o=i.id,s=i.segments,u=void 0===s?[]:s,l=e.mediaIndex,c=e.timeline;return["appending ["+l+"] of ["+a+", "+(a+u.length)+"] from playlist ["+o+"]","["+n+" => "+r+"] in timeline ["+c+"]"].join(" ")},Xp=function(t){function n(e){lf(this,n);var t=hf(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));if(!e)throw new TypeError("Initialization settings are required");if("function"!=typeof e.currentTime)throw new TypeError("No currentTime getter specified");if(!e.mediaSource)throw new TypeError("No MediaSource specified");return t.bandwidth=e.bandwidth,t.throughput={rate:0,count:0},t.roundTrip=NaN,t.resetStats_(),t.mediaIndex=null,t.hasPlayed_=e.hasPlayed,t.currentTime_=e.currentTime,t.seekable_=e.seekable,t.seeking_=e.seeking,t.duration_=e.duration,t.mediaSource_=e.mediaSource,t.hls_=e.hls,t.loaderType_=e.loaderType,t.startingMedia_=void 0,t.segmentMetadataTrack_=e.segmentMetadataTrack,t.goalBufferLength_=e.goalBufferLength,t.sourceType_=e.sourceType,t.inbandTextTracks_=e.inbandTextTracks,t.state_="INIT",t.checkBufferTimeout_=null,t.error_=void 0,t.currentTimeline_=-1,t.pendingSegment_=null,t.mimeType_=null,t.sourceUpdater_=null,t.xhrOptions_=null,t.activeInitSegmentId_=null,t.initSegments_={},t.cacheEncryptionKeys_=e.cacheEncryptionKeys,t.keyCache_={},"main"===t.loaderType_?t.captionParser_=new Ad:t.captionParser_=null,t.decrypter_=e.decrypter,t.syncController_=e.syncController,t.syncPoint_={segmentIndex:0,time:0},t.syncController_.on("syncinfoupdate",function(){return t.trigger("syncinfoupdate")}),t.mediaSource_.addEventListener("sourceopen",function(){return t.ended_=!1}),t.fetchAtBuffer_=!1,t.logger_=bp("SegmentLoader["+t.loaderType_+"]"),Object.defineProperty(t,"state",{get:function(){return this.state_},set:function(e){e!==this.state_&&(this.logger_(this.state_+" -> "+e),this.state_=e)}}),t}return ff(n,t),cf(n,[{key:"resetStats_",value:function(){this.mediaBytesTransferred=0,this.mediaRequests=0,this.mediaRequestsAborted=0,this.mediaRequestsTimedout=0,this.mediaRequestsErrored=0,this.mediaTransferDuration=0,this.mediaSecondsLoaded=0}},{key:"dispose",value:function(){this.state="DISPOSED",this.pause(),this.abort_(),this.sourceUpdater_&&this.sourceUpdater_.dispose(),this.resetStats_(),this.captionParser_&&this.captionParser_.reset()}},{key:"abort",value:function(){if("WAITING"!==this.state)return void(this.pendingSegment_&&(this.pendingSegment_=null));this.abort_(),this.state="READY",this.paused()||this.monitorBuffer_()}},{key:"abort_",value:function(){this.pendingSegment_&&this.pendingSegment_.abortRequests(),this.pendingSegment_=null}},{key:"error",value:function(e){return void 0!==e&&(this.error_=e),this.pendingSegment_=null,this.error_}},{key:"endOfStream",value:function(){this.ended_=!0,this.pause(),this.trigger("ended")}},{key:"buffered_",value:function(){return this.sourceUpdater_?this.sourceUpdater_.buffered():ut.createTimeRanges()}},{key:"initSegment",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!e)return null;var n=ah(e),r=this.initSegments_[n];return t&&!r&&e.bytes&&(this.initSegments_[n]=r={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:e.bytes,timescales:e.timescales,videoTrackIds:e.videoTrackIds}),r||e}},{key:"segmentKey",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!e)return null;var n=oh(e),r=this.keyCache_[n];this.cacheEncryptionKeys_&&t&&!r&&e.bytes&&(this.keyCache_[n]=r={resolvedUri:e.resolvedUri,bytes:e.bytes});var i={resolvedUri:(r||e).resolvedUri};return r&&(i.bytes=r.bytes),i}},{key:"couldBeginLoading_",value:function(){return this.playlist_&&(this.sourceUpdater_||this.mimeType_&&"INIT"===this.state)&&!this.paused()}},{key:"load",value:function(){if(this.monitorBuffer_(),this.playlist_){if(this.syncController_.setDateTimeMapping(this.playlist_),"INIT"===this.state&&this.couldBeginLoading_())return this.init_();!this.couldBeginLoading_()||"READY"!==this.state&&"INIT"!==this.state||(this.state="READY")}}},{key:"init_",value:function(){return this.state="READY",this.sourceUpdater_=new Tp(this.mediaSource_,this.mimeType_,this.loaderType_,this.sourceBufferEmitter_),this.resetEverything(),this.monitorBuffer_()}},{key:"playlist",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e){var n=this.playlist_,r=this.pendingSegment_;this.playlist_=e,this.xhrOptions_=t,this.hasPlayed_()||(e.syncInfo={mediaSequence:e.mediaSequence,time:0});var i=null;if(n&&(n.id?i=n.id:n.uri&&(i=n.uri)),this.logger_("playlist update ["+i+" => "+(e.id||e.uri)+"]"),this.trigger("syncinfoupdate"),"INIT"===this.state&&this.couldBeginLoading_())return this.init_();if(!n||n.uri!==e.uri)return void(null!==this.mediaIndex&&this.resyncLoader());var a=e.mediaSequence-n.mediaSequence;this.logger_("live window shift ["+a+"]"),null!==this.mediaIndex&&(this.mediaIndex-=a),r&&(r.mediaIndex-=a,r.mediaIndex>=0&&(r.segment=e.segments[r.mediaIndex])),this.syncController_.saveExpiredSegmentInfo(n,e)}}},{key:"pause",value:function(){this.checkBufferTimeout_&&(e.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=null)}},{key:"paused",value:function(){return null===this.checkBufferTimeout_}},{key:"mimeType",value:function(e,t){this.mimeType_||(this.mimeType_=e,this.sourceBufferEmitter_=t,"INIT"===this.state&&this.couldBeginLoading_()&&this.init_())}},{key:"resetEverything",value:function(e){this.ended_=!1,this.resetLoader(),this.remove(0,this.duration_(),e),this.captionParser_&&this.captionParser_.clearAllCaptions(),this.trigger("reseteverything")}},{key:"resetLoader",value:function(){this.fetchAtBuffer_=!1,this.resyncLoader()}},{key:"resyncLoader",value:function(){this.mediaIndex=null,this.syncPoint_=null,this.abort()}},{key:"remove",value:function(e,t,n){if(this.sourceUpdater_&&this.sourceUpdater_.remove(e,t,n),Ch(e,t,this.segmentMetadataTrack_),this.inbandTextTracks_)for(var r in this.inbandTextTracks_)Ch(e,t,this.inbandTextTracks_[r])}},{key:"monitorBuffer_",value:function(){this.checkBufferTimeout_&&e.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=e.setTimeout(this.monitorBufferTick_.bind(this),1)}},{key:"monitorBufferTick_",value:function(){"READY"===this.state&&this.fillBuffer_(),this.checkBufferTimeout_&&e.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=e.setTimeout(this.monitorBufferTick_.bind(this),500)}},{key:"fillBuffer_",value:function(){if(!this.sourceUpdater_.updating()){this.syncPoint_||(this.syncPoint_=this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_()));var e=this.checkBuffer_(this.buffered_(),this.playlist_,this.mediaIndex,this.hasPlayed_(),this.currentTime_(),this.syncPoint_);if(e)return this.isEndOfStream_(e.mediaIndex)?void this.endOfStream():void((e.mediaIndex!==this.playlist_.segments.length-1||"ended"!==this.mediaSource_.readyState||this.seeking_())&&(e.timeline!==this.currentTimeline_&&(this.syncController_.reset(),e.timestampOffset=e.startOfSegment,this.captionParser_&&this.captionParser_.clearAllCaptions()),this.loadSegment_(e)))}}},{key:"isEndOfStream_",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.playlist_;return zp(t,this.mediaSource_,e)&&!this.sourceUpdater_.updating()}},{key:"checkBuffer_",value:function(e,t,n,r,i,a){var o=0,s=void 0;e.length&&(o=e.end(e.length-1));var u=Math.max(0,o-i);if(!t.segments.length)return null;if(u>=this.goalBufferLength_())return null;if(!r&&u>=1)return null;if(null===a)return n=this.getSyncSegmentCandidate_(t),this.generateSegmentInfo_(t,n,null,!0);if(null!==n){var l=t.segments[n];return s=l&&l.end?l.end:o,this.generateSegmentInfo_(t,n+1,s,!1)}if(this.fetchAtBuffer_){var c=Kf.getMediaInfoForTime(t,o,a.segmentIndex,a.time);n=c.mediaIndex,s=c.startTime}else{var d=Kf.getMediaInfoForTime(t,i,a.segmentIndex,a.time);n=d.mediaIndex,s=d.startTime}return this.generateSegmentInfo_(t,n,s,!1)}},{key:"getSyncSegmentCandidate_",value:function(e){var t=this;if(-1===this.currentTimeline_)return 0;var n=e.segments.map(function(e,t){return{timeline:e.timeline,segmentIndex:t}}).filter(function(e){return e.timeline===t.currentTimeline_});return n.length?n[Math.min(n.length-1,1)].segmentIndex:Math.max(e.segments.length-1,0)}},{key:"generateSegmentInfo_",value:function(e,t,n,r){if(t<0||t>=e.segments.length)return null;var i=e.segments[t];return{requestId:"segment-loader-"+Math.random(),uri:i.resolvedUri,mediaIndex:t,isSyncRequest:r,startOfSegment:n,playlist:e,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:i.timeline,duration:i.duration,segment:i}}},{key:"abortRequestEarly_",value:function(e){if(this.hls_.tech_.paused()||!this.xhrOptions_.timeout||!this.playlist_.attributes.BANDWIDTH)return!1;if(Date.now()-(e.firstBytesReceivedAt||Date.now())<1e3)return!1;var t=this.currentTime_(),n=e.bandwidth,r=this.pendingSegment_.duration,i=Kf.estimateSegmentRequestTime(r,n,this.playlist_,e.bytesReceived),a=kh(this.buffered_(),t,this.hls_.tech_.playbackRate())-1;if(i<=a)return!1;var o=Vp({master:this.hls_.playlists.master,currentTime:t,bandwidth:n,duration:this.duration_(),segmentDuration:r,timeUntilRebuffer:a,currentTimeline:this.currentTimeline_,syncController:this.syncController_});if(o){var s=i-a,u=s-o.rebufferingImpact,l=.5;return a<=1/30&&(l=1),!(!o.playlist||o.playlist.uri===this.playlist_.uri||u<l)&&(this.bandwidth=o.playlist.attributes.BANDWIDTH*Sp.BANDWIDTH_VARIANCE+1,this.abort(),this.trigger("earlyabort"),!0)}}},{key:"handleProgress_",value:function(e,t){this.pendingSegment_&&t.requestId===this.pendingSegment_.requestId&&!this.abortRequestEarly_(t.stats)&&this.trigger("progress")}},{key:"loadSegment_",value:function(e){this.state="WAITING",this.pendingSegment_=e,this.trimBackBuffer_(e),e.abortRequests=Rp(this.hls_.xhr,this.xhrOptions_,this.decrypter_,this.captionParser_,this.createSimplifiedSegmentObj_(e),this.handleProgress_.bind(this),this.segmentRequestFinished_.bind(this))}},{key:"trimBackBuffer_",value:function(e){var t=Yp(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);t>0&&this.remove(0,t)}},{key:"createSimplifiedSegmentObj_",value:function(e){var t=e.segment,n={resolvedUri:t.resolvedUri,byterange:t.byterange,requestId:e.requestId};if(t.key){var r=t.key.iv||new Uint32Array([0,0,0,e.mediaIndex+e.playlist.mediaSequence]);n.key=this.segmentKey(t.key),n.key.iv=r}return t.map&&(n.map=this.initSegment(t.map)),n}},{key:"segmentRequestFinished_",value:function(e,t){if(this.mediaRequests+=1,t.stats&&(this.mediaBytesTransferred+=t.stats.bytesReceived,this.mediaTransferDuration+=t.stats.roundTripTime),!this.pendingSegment_)return void(this.mediaRequestsAborted+=1);if(t.requestId===this.pendingSegment_.requestId){if(e)return this.pendingSegment_=null,this.state="READY",e.code===wp.ABORTED?void(this.mediaRequestsAborted+=1):(this.pause(),e.code===wp.TIMEOUT?(this.mediaRequestsTimedout+=1,this.bandwidth=1,this.roundTrip=NaN,void this.trigger("bandwidthupdate")):(this.mediaRequestsErrored+=1,this.error(e),void this.trigger("error")));this.bandwidth=t.stats.bandwidth,this.roundTrip=t.stats.roundTripTime,t.map&&(t.map=this.initSegment(t.map,!0)),t.key&&this.segmentKey(t.key,!0),this.processSegmentResponse_(t)}}},{key:"processSegmentResponse_",value:function(e){var t=this.pendingSegment_;t.bytes=e.bytes,e.map&&(t.segment.map.bytes=e.map.bytes),t.endOfAllRequests=e.endOfAllRequests,e.fmp4Captions&&(Gp(this.inbandTextTracks_,this.hls_.tech_,e.captionStreams),Hp({inbandTextTracks:this.inbandTextTracks_,captionArray:e.fmp4Captions,timestampOffset:0}),this.captionParser_&&this.captionParser_.clearParsedCaptions()),this.handleSegment_()}},{key:"handleSegment_",value:function(){var e=this;if(!this.pendingSegment_)return void(this.state="READY");var t=this.pendingSegment_,n=t.segment,r=this.syncController_.probeSegmentInfo(t);void 0===this.startingMedia_&&r&&(r.containsAudio||r.containsVideo)&&(this.startingMedia_={containsAudio:r.containsAudio,containsVideo:r.containsVideo});var i=$p(this.loaderType_,this.startingMedia_,r);if(i)return this.error({message:i,blacklistDuration:1/0}),void this.trigger("error");if(t.isSyncRequest)return this.trigger("syncinfoupdate"),this.pendingSegment_=null,void(this.state="READY");null!==t.timestampOffset&&t.timestampOffset!==this.sourceUpdater_.timestampOffset()&&(this.sourceUpdater_.timestampOffset(t.timestampOffset),this.trigger("timestampoffset"));var a=this.syncController_.mappingForTimeline(t.timeline);if(null!==a&&this.trigger({type:"segmenttimemapping",mapping:a}),this.state="APPENDING",n.map){var o=ah(n.map);if(!this.activeInitSegmentId_||this.activeInitSegmentId_!==o){var s=this.initSegment(n.map);this.sourceUpdater_.appendBuffer({bytes:s.bytes},function(){e.activeInitSegmentId_=o})}}t.byteLength=t.bytes.byteLength,"number"==typeof n.start&&"number"==typeof n.end?this.mediaSecondsLoaded+=n.end-n.start:this.mediaSecondsLoaded+=n.duration,this.logger_(Kp(t)),this.sourceUpdater_.appendBuffer({bytes:t.bytes,videoSegmentTimingInfoCallback:this.handleVideoSegmentTimingInfo_.bind(this,t.requestId)},this.handleUpdateEnd_.bind(this))}},{key:"handleVideoSegmentTimingInfo_",value:function(e,t){if(this.pendingSegment_&&e===this.pendingSegment_.requestId){var n=this.pendingSegment_.segment;n.videoTimingInfo||(n.videoTimingInfo={}),n.videoTimingInfo.transmuxerPrependedSeconds=t.videoSegmentTimingInfo.prependedContentDuration||0,n.videoTimingInfo.transmuxedPresentationStart=t.videoSegmentTimingInfo.start.presentation,n.videoTimingInfo.transmuxedPresentationEnd=t.videoSegmentTimingInfo.end.presentation,n.videoTimingInfo.baseMediaDecodeTime=t.videoSegmentTimingInfo.baseMediaDecodeTime}}},{key:"handleUpdateEnd_",value:function(){if(!this.pendingSegment_)return this.state="READY",void(this.paused()||this.monitorBuffer_());var e=this.pendingSegment_,t=e.segment,n=null!==this.mediaIndex;if(this.pendingSegment_=null,this.recordThroughput_(e),this.addSegmentMetadataCue_(e),this.state="READY",this.mediaIndex=e.mediaIndex,this.fetchAtBuffer_=!0,this.currentTimeline_=e.timeline,this.trigger("syncinfoupdate"),t.end&&this.currentTime_()-t.end>3*e.playlist.targetDuration)return void this.resetEverything();n&&this.trigger("bandwidthupdate"),this.trigger("progress"),this.isEndOfStream_(e.mediaIndex+1,e.playlist)&&this.endOfStream(),this.paused()||this.monitorBuffer_()}},{key:"recordThroughput_",value:function(e){var t=this.throughput.rate,n=Date.now()-e.endOfAllRequests+1,r=Math.floor(e.byteLength/n*8*1e3);this.throughput.rate+=(r-t)/++this.throughput.count}},{key:"addSegmentMetadataCue_",value:function(t){if(this.segmentMetadataTrack_){var n=t.segment,r=n.start,i=n.end;if(Wp(r)&&Wp(i)){Ch(r,i,this.segmentMetadataTrack_);var a=e.WebKitDataCue||e.VTTCue,o={custom:n.custom,dateTimeObject:n.dateTimeObject,dateTimeString:n.dateTimeString,bandwidth:t.playlist.attributes.BANDWIDTH,resolution:t.playlist.attributes.RESOLUTION,codecs:t.playlist.attributes.CODECS,byteLength:t.byteLength,uri:t.uri,timeline:t.timeline,playlist:t.playlist.uri,start:r,end:i},s=JSON.stringify(o),u=new a(r,i,s);u.value=o,this.segmentMetadataTrack_.addCue(u)}}}}]),n}(ut.EventTarget),Jp=function(e){return decodeURIComponent(escape(String.fromCharCode.apply(null,e)))},Qp=new Uint8Array("\n\n".split("").map(function(e){return e.charCodeAt(0)})),Zp=function(t){function n(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};lf(this,n);var r=hf(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,t));return r.mediaSource_=null,r.subtitlesTrack_=null,r}return ff(n,t),cf(n,[{key:"buffered_",value:function(){if(!this.subtitlesTrack_||!this.subtitlesTrack_.cues.length)return ut.createTimeRanges();var e=this.subtitlesTrack_.cues,t=e[0].startTime,n=e[e.length-1].startTime;return ut.createTimeRanges([[t,n]])}},{key:"initSegment",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!e)return null;var n=ah(e),r=this.initSegments_[n];if(t&&!r&&e.bytes){var i=Qp.byteLength+e.bytes.byteLength,a=new Uint8Array(i);a.set(e.bytes),a.set(Qp,e.bytes.byteLength),this.initSegments_[n]=r={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:a}}return r||e}},{key:"couldBeginLoading_",value:function(){return this.playlist_&&this.subtitlesTrack_&&!this.paused()}},{key:"init_",value:function(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()}},{key:"track",value:function(e){return void 0===e?this.subtitlesTrack_:(this.subtitlesTrack_=e,"INIT"===this.state&&this.couldBeginLoading_()&&this.init_(),this.subtitlesTrack_)}},{key:"remove",value:function(e,t){Ch(e,t,this.subtitlesTrack_)}},{key:"fillBuffer_",value:function(){var e=this;this.syncPoint_||(this.syncPoint_=this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_()));var t=this.checkBuffer_(this.buffered_(),this.playlist_,this.mediaIndex,this.hasPlayed_(),this.currentTime_(),this.syncPoint_);if(t=this.skipEmptySegments_(t)){if(null===this.syncController_.timestampOffsetForTimeline(t.timeline)){var n=function(){e.state="READY",e.paused()||e.monitorBuffer_()};return this.syncController_.one("timestampoffset",n),void(this.state="WAITING_ON_TIMELINE")}this.loadSegment_(t)}}},{key:"skipEmptySegments_",value:function(e){for(;e&&e.segment.empty;)e=this.generateSegmentInfo_(e.playlist,e.mediaIndex+1,e.startOfSegment+e.duration,e.isSyncRequest);return e}},{key:"handleSegment_",value:function(){var t=this;if(!this.pendingSegment_||!this.subtitlesTrack_)return void(this.state="READY");this.state="APPENDING";var n=this.pendingSegment_,r=n.segment;if("function"!=typeof e.WebVTT&&this.subtitlesTrack_&&this.subtitlesTrack_.tech_){var i=void 0,a=function(){t.subtitlesTrack_.tech_.off("vttjsloaded",i),t.error({message:"Error loading vtt.js"}),t.state="READY",t.pause(),t.trigger("error")};return i=function(){t.subtitlesTrack_.tech_.off("vttjserror",a),t.handleSegment_()},this.state="WAITING_ON_VTTJS",this.subtitlesTrack_.tech_.one("vttjsloaded",i),void this.subtitlesTrack_.tech_.one("vttjserror",a)}r.requested=!0;try{this.parseVTTCues_(n)}catch(e){return this.error({message:e.message}),this.state="READY",this.pause(),this.trigger("error")}if(this.updateTimeMapping_(n,this.syncController_.timelines[n.timeline],this.playlist_),n.isSyncRequest)return this.trigger("syncinfoupdate"),this.pendingSegment_=null,void(this.state="READY");n.byteLength=n.bytes.byteLength,this.mediaSecondsLoaded+=r.duration,n.cues.length&&this.remove(n.cues[0].endTime,n.cues[n.cues.length-1].endTime),n.cues.forEach(function(e){t.subtitlesTrack_.addCue(e)}),this.handleUpdateEnd_()}},{key:"parseVTTCues_",value:function(t){var n=void 0,r=!1;"function"==typeof e.TextDecoder?n=new e.TextDecoder("utf8"):(n=e.WebVTT.StringDecoder(),r=!0);var i=new e.WebVTT.Parser(e,e.vttjs,n);if(t.cues=[],t.timestampmap={MPEGTS:0,LOCAL:0},i.oncue=t.cues.push.bind(t.cues),i.ontimestampmap=function(e){return t.timestampmap=e},i.onparsingerror=function(e){ut.log.warn("Error encountered when parsing cues: "+e.message)},t.segment.map){var a=t.segment.map.bytes;r&&(a=Jp(a)),i.parse(a)}var o=t.bytes;r&&(o=Jp(o)),i.parse(o),i.flush()}},{key:"updateTimeMapping_",value:function(e,t,n){var r=e.segment;if(t){if(!e.cues.length)return void(r.empty=!0);var i=e.timestampmap,a=i.MPEGTS/9e4-i.LOCAL+t.mapping;if(e.cues.forEach(function(e){e.startTime+=a,e.endTime+=a}),!n.syncInfo){var o=e.cues[0].startTime,s=e.cues[e.cues.length-1].startTime;n.syncInfo={mediaSequence:n.mediaSequence+e.mediaIndex,time:Math.min(o,s-r.duration)}}}}}]),n}(Xp),em=function(e,t){for(var n=e.cues,r=0;r<n.length;r++){var i=n[r];if(t>=i.adStartTime&&t<=i.adEndTime)return i}return null},tm=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(t.segments)for(var i=r,a=void 0,o=0;o<t.segments.length;o++){var s=t.segments[o];if(a||(a=em(n,i+s.duration/2)),a){if("cueIn"in s){a.endTime=i,a.adEndTime=i,i+=s.duration,a=null;continue}if(i<a.endTime){i+=s.duration;continue}a.endTime+=s.duration}else if("cueOut"in s&&(a=new e.VTTCue(i,i+s.duration,s.cueOut),a.adStartTime=i,a.adEndTime=i+parseFloat(s.cueOut),n.addCue(a)),"cueOutCont"in s){var u=void 0,l=void 0,c=s.cueOutCont.split("/").map(parseFloat),d=pf(c,2);u=d[0],l=d[1],a=new e.VTTCue(i,i+s.duration,""),a.adStartTime=i-u,a.adEndTime=a.adStartTime+l,n.addCue(a)}i+=s.duration}},nm=$d.inspect,rm=[{name:"VOD",run:function(e,t,n,r,i){return n!==1/0?{time:0,segmentIndex:0}:null}},{name:"ProgramDateTime",run:function(e,t,n,r,i){if(!e.datetimeToDisplayTime)return null;var a=t.segments||[],o=null,s=null;i=i||0;for(var u=0;u<a.length;u++){var l=a[u];if(l.dateTimeObject){var c=l.dateTimeObject.getTime()/1e3,d=c+e.datetimeToDisplayTime,f=Math.abs(i-d);if(null!==s&&(0===f||s<f))break;s=f,o={time:d,segmentIndex:u}}}return o}},{name:"Segment",run:function(e,t,n,r,i){var a=t.segments||[],o=null,s=null;i=i||0;for(var u=0;u<a.length;u++){var l=a[u];if(l.timeline===r&&void 0!==l.start){var c=Math.abs(i-l.start);if(null!==s&&s<c)break;(!o||null===s||s>=c)&&(s=c,o={time:l.start,segmentIndex:u})}}return o}},{name:"Discontinuity",run:function(e,t,n,r,i){var a=null;if(i=i||0,t.discontinuityStarts&&t.discontinuityStarts.length)for(var o=null,s=0;s<t.discontinuityStarts.length;s++){var u=t.discontinuityStarts[s],l=t.discontinuitySequence+s+1,c=e.discontinuities[l];if(c){var d=Math.abs(i-c.time);if(null!==o&&o<d)break;(!a||null===o||o>=d)&&(o=d,a={time:c.time,segmentIndex:u})}}return a}},{name:"Playlist",run:function(e,t,n,r,i){return t.syncInfo?{time:t.syncInfo.time,segmentIndex:t.syncInfo.mediaSequence-t.mediaSequence}:null}}],im=function(e){function t(){lf(this,t);var e=hf(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return e.inspectCache_=void 0,e.timelines=[],e.discontinuities=[],e.datetimeToDisplayTime=null,e.logger_=bp("SyncController"),e}return ff(t,e),cf(t,[{key:"getSyncPoint",value:function(e,t,n,r){var i=this.runStrategies_(e,t,n,r);return i.length?this.selectSyncPoint_(i,{key:"time",value:r}):null}},{key:"getExpiredTime",value:function(e,t){if(!e||!e.segments)return null;var n=this.runStrategies_(e,t,e.discontinuitySequence,0);if(!n.length)return null;var r=this.selectSyncPoint_(n,{key:"segmentIndex",value:0});return r.segmentIndex>0&&(r.time*=-1),Math.abs(r.time+Of(e,r.segmentIndex,0))}},{key:"runStrategies_",value:function(e,t,n,r){for(var i=[],a=0;a<rm.length;a++){var o=rm[a],s=o.run(this,e,t,n,r);s&&(s.strategy=o.name,i.push({strategy:o.name,syncPoint:s}))}return i}},{key:"selectSyncPoint_",value:function(e,t){for(var n=e[0].syncPoint,r=Math.abs(e[0].syncPoint[t.key]-t.value),i=e[0].strategy,a=1;a<e.length;a++){var o=Math.abs(e[a].syncPoint[t.key]-t.value);o<r&&(r=o,n=e[a].syncPoint,i=e[a].strategy)}return this.logger_("syncPoint for ["+t.key+": "+t.value+"] chosen with strategy ["+i+"]: [time:"+n.time+", segmentIndex:"+n.segmentIndex+"]"),n}},{key:"saveExpiredSegmentInfo",value:function(e,t){for(var n=t.mediaSequence-e.mediaSequence,r=n-1;r>=0;r--){var i=e.segments[r];if(i&&void 0!==i.start){t.syncInfo={mediaSequence:e.mediaSequence+r,time:i.start},this.logger_("playlist refresh sync: [time:"+t.syncInfo.time+", mediaSequence: "+t.syncInfo.mediaSequence+"]"),this.trigger("syncinfoupdate");break}}}},{key:"setDateTimeMapping",value:function(e){if(!this.datetimeToDisplayTime&&e.segments&&e.segments.length&&e.segments[0].dateTimeObject){var t=e.segments[0].dateTimeObject.getTime()/1e3;this.datetimeToDisplayTime=-t}}},{key:"reset",value:function(){this.inspectCache_=void 0}},{key:"probeSegmentInfo",value:function(e){var t=e.segment,n=e.playlist,r=void 0;return r=t.map?this.probeMp4Segment_(e):this.probeTsSegment_(e),r&&this.calculateSegmentTimeMapping_(e,r)&&(this.saveDiscontinuitySyncInfo_(e),n.syncInfo||(n.syncInfo={mediaSequence:n.mediaSequence+e.mediaIndex,time:t.start})),r}},{key:"probeMp4Segment_",value:function(e){var t=e.segment,n=Bu.timescale(t.map.bytes),r=Bu.startTime(n,e.bytes);return null!==e.timestampOffset&&(e.timestampOffset-=r),{start:r,end:r+t.duration}}},{key:"probeTsSegment_",value:function(e){var t=nm(e.bytes,this.inspectCache_),n=void 0,r=void 0;return t?(t.video&&2===t.video.length?(this.inspectCache_=t.video[1].dts,n=t.video[0].dtsTime,r=t.video[1].dtsTime):t.audio&&2===t.audio.length&&(this.inspectCache_=t.audio[1].dts,n=t.audio[0].dtsTime,r=t.audio[1].dtsTime),{start:n,end:r,containsVideo:t.video&&2===t.video.length,containsAudio:t.audio&&2===t.audio.length}):null}},{key:"timestampOffsetForTimeline",value:function(e){return void 0===this.timelines[e]?null:this.timelines[e].time}},{key:"mappingForTimeline",value:function(e){return void 0===this.timelines[e]?null:this.timelines[e].mapping}},{key:"calculateSegmentTimeMapping_",value:function(e,t){var n=e.segment,r=this.timelines[e.timeline];if(null!==e.timestampOffset)r={time:e.startOfSegment,mapping:e.startOfSegment-t.start},this.timelines[e.timeline]=r,this.trigger("timestampoffset"),this.logger_("time mapping for timeline "+e.timeline+": [time: "+r.time+"] [mapping: "+r.mapping+"]"),n.start=e.startOfSegment,n.end=t.end+r.mapping;else{if(!r)return!1;n.start=t.start+r.mapping,n.end=t.end+r.mapping}return!0}},{key:"saveDiscontinuitySyncInfo_",value:function(e){var t=e.playlist,n=e.segment;if(n.discontinuity)this.discontinuities[n.timeline]={time:n.start,accuracy:0};else if(t.discontinuityStarts&&t.discontinuityStarts.length)for(var r=0;r<t.discontinuityStarts.length;r++){var i=t.discontinuityStarts[r],a=t.discontinuitySequence+r+1,o=i-e.mediaIndex,s=Math.abs(o);if(!this.discontinuities[a]||this.discontinuities[a].accuracy>s){var u=void 0;u=o<0?n.start-Of(t,e.mediaIndex,i):n.end+Of(t,e.mediaIndex+1,i),this.discontinuities[a]={time:u,accuracy:s}}}}}]),t}(ut.EventTarget),am=new pt("./decrypter-worker.worker.js",function(e,t){var n=this;!function(){function e(e){return e.subarray(0,e.byteLength-e[e.byteLength-1])}var t=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)},a=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t},o=function(){var e=[[[],[],[],[],[]],[[],[],[],[],[]]],t=e[0],n=e[1],r=t[4],i=n[4],a=void 0,o=void 0,s=void 0,u=[],l=[],c=void 0,d=void 0,f=void 0,h=void 0,p=void 0,m=void 0;for(a=0;a<256;a++)l[(u[a]=a<<1^283*(a>>7))^a]=a;for(o=s=0;!r[o];o^=c||1,s=l[s]||1)for(h=s^s<<1^s<<2^s<<3^s<<4,h=h>>8^255&h^99,r[o]=h,i[h]=o,f=u[d=u[c=u[o]]],m=16843009*f^65537*d^257*c^16843008*o,p=257*u[h]^16843008*h,a=0;a<4;a++)t[a][o]=p=p<<24^p>>>8,n[a][h]=m=m<<24^m>>>8;for(a=0;a<5;a++)t[a]=t[a].slice(0),n[a]=n[a].slice(0);return e},s=null,u=function(){function e(n){t(this,e),s||(s=o()),this._tables=[[s[0][0].slice(),s[0][1].slice(),s[0][2].slice(),s[0][3].slice(),s[0][4].slice()],[s[1][0].slice(),s[1][1].slice(),s[1][2].slice(),s[1][3].slice(),s[1][4].slice()]];var r=void 0,i=void 0,a=void 0,u=void 0,l=void 0,c=this._tables[0][4],d=this._tables[1],f=n.length,h=1;if(4!==f&&6!==f&&8!==f)throw new Error("Invalid aes key size");for(u=n.slice(0),l=[],this._key=[u,l],r=f;r<4*f+28;r++)a=u[r-1],(r%f==0||8===f&&r%f==4)&&(a=c[a>>>24]<<24^c[a>>16&255]<<16^c[a>>8&255]<<8^c[255&a],r%f==0&&(a=a<<8^a>>>24^h<<24,h=h<<1^283*(h>>7))),u[r]=u[r-f]^a;for(i=0;r;i++,r--)a=u[3&i?r:r-4],l[i]=r<=4||i<4?a:d[0][c[a>>>24]]^d[1][c[a>>16&255]]^d[2][c[a>>8&255]]^d[3][c[255&a]]}return e.prototype.decrypt=function(e,t,n,r,i,a){var o=this._key[1],s=e^o[0],u=r^o[1],l=n^o[2],c=t^o[3],d=void 0,f=void 0,h=void 0,p=o.length/4-2,m=void 0,v=4,g=this._tables[1],y=g[0],_=g[1],b=g[2],T=g[3],S=g[4];for(m=0;m<p;m++)d=y[s>>>24]^_[u>>16&255]^b[l>>8&255]^T[255&c]^o[v],f=y[u>>>24]^_[l>>16&255]^b[c>>8&255]^T[255&s]^o[v+1],h=y[l>>>24]^_[c>>16&255]^b[s>>8&255]^T[255&u]^o[v+2],c=y[c>>>24]^_[s>>16&255]^b[u>>8&255]^T[255&l]^o[v+3],v+=4,s=d,u=f,l=h;for(m=0;m<4;m++)i[(3&-m)+a]=S[s>>>24]<<24^S[u>>16&255]<<16^S[l>>8&255]<<8^S[255&c]^o[v++],d=s,s=u,u=l,l=c,c=d},e}(),l=function(){function e(){t(this,e),this.listeners={}}return e.prototype.on=function(e,t){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push(t)},e.prototype.off=function(e,t){if(!this.listeners[e])return!1;var n=this.listeners[e].indexOf(t);return this.listeners[e].splice(n,1),n>-1},e.prototype.trigger=function(e){var t=this.listeners[e];if(t)if(2===arguments.length)for(var n=t.length,r=0;r<n;++r)t[r].call(this,arguments[1]);else for(var i=Array.prototype.slice.call(arguments,1),a=t.length,o=0;o<a;++o)t[o].apply(this,i)},e.prototype.dispose=function(){this.listeners={}},e.prototype.pipe=function(e){this.on("data",function(t){e.push(t)})},e}(),c=function(e){function n(){t(this,n);var r=a(this,e.call(this,l));return r.jobs=[],r.delay=1,r.timeout_=null,r}return i(n,e),n.prototype.processJob_=function(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null},n.prototype.push=function(e){this.jobs.push(e),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))},n}(l),d=function(e){return e<<24|(65280&e)<<8|(16711680&e)>>8|e>>>24},f=function(e,t,n){var r=new Int32Array(e.buffer,e.byteOffset,e.byteLength>>2),i=new u(Array.prototype.slice.call(t)),a=new Uint8Array(e.byteLength),o=new Int32Array(a.buffer),s=void 0,l=void 0,c=void 0,f=void 0,h=void 0,p=void 0,m=void 0,v=void 0,g=void 0;for(s=n[0],l=n[1],c=n[2],f=n[3],g=0;g<r.length;g+=4)h=d(r[g]),p=d(r[g+1]),m=d(r[g+2]),v=d(r[g+3]),i.decrypt(h,p,m,v,o,g),o[g]=d(o[g]^s),o[g+1]=d(o[g+1]^l),o[g+2]=d(o[g+2]^c),o[g+3]=d(o[g+3]^f),s=h,l=p,c=m,f=v;return a},h=function(){function n(r,i,a,o){t(this,n);var s=n.STEP,u=new Int32Array(r.buffer),l=new Uint8Array(r.byteLength),f=0;for(this.asyncStream_=new c,this.asyncStream_.push(this.decryptChunk_(u.subarray(f,f+s),i,a,l)),f=s;f<u.length;f+=s)a=new Uint32Array([d(u[f-4]),d(u[f-3]),d(u[f-2]),d(u[f-1])]),this.asyncStream_.push(this.decryptChunk_(u.subarray(f,f+s),i,a,l));this.asyncStream_.push(function(){o(null,e(l))})}return n.prototype.decryptChunk_=function(e,t,n,r){return function(){var i=f(e,t,n);r.set(i,e.byteOffset)}},r(n,null,[{key:"STEP",get:function(){return 32e3}}]),n}(),p=function(e){var t={};return Object.keys(e).forEach(function(n){var r=e[n];ArrayBuffer.isView(r)?t[n]={bytes:r.buffer,byteOffset:r.byteOffset,byteLength:r.byteLength}:t[n]=r}),t};new function(e){e.onmessage=function(t){var n=t.data,r=new Uint8Array(n.encrypted.bytes,n.encrypted.byteOffset,n.encrypted.byteLength),i=new Uint32Array(n.key.bytes,n.key.byteOffset,n.key.byteLength/4),a=new Uint32Array(n.iv.bytes,n.iv.byteOffset,n.iv.byteLength/4);new h(r,i,a,function(t,r){e.postMessage(p({source:n.source,decrypted:r}),[r.buffer])})}}(n)}()}),om=function(e){var t=e.default?"main":"alternative";return e.characteristics&&e.characteristics.indexOf("public.accessibility.describes-video")>=0&&(t="main-desc"),t},sm=function(e,t){e.abort(),e.pause(),t&&t.activePlaylistLoader&&(t.activePlaylistLoader.pause(),t.activePlaylistLoader=null)},um=function(e,t){t.activePlaylistLoader=e,e.load()},lm=function(e,t){return function(){var n=t.segmentLoaders,r=n[e],i=n.main,a=t.mediaTypes[e],o=a.activeTrack(),s=a.activeGroup(o),u=a.activePlaylistLoader;if(sm(r,a),s){if(!s.playlistLoader)return void(u&&i.resetEverything());r.resyncLoader(),um(s.playlistLoader,a)}}},cm=function(e,t){return function(){var n=t.segmentLoaders,r=n[e],i=n.main,a=t.mediaTypes[e],o=a.activeTrack(),s=a.activeGroup(o),u=a.activePlaylistLoader;if(sm(r,a),s){if(!s.playlistLoader)return void i.resetEverything();if(u===s.playlistLoader)return void um(s.playlistLoader,a);r.track&&r.track(o),r.resetEverything(),um(s.playlistLoader,a)}}},dm={AUDIO:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e],i=t.blacklistCurrentPlaylist;sm(n,r);var a=r.activeTrack(),o=r.activeGroup(),s=(o.filter(function(e){return e.default})[0]||o[0]).id,u=r.tracks[s];if(a===u)return void i({message:"Problem encountered loading the default audio track."});ut.log.warn("Problem encountered loading the alternate audio track.Switching back to default.");for(var l in r.tracks)r.tracks[l].enabled=r.tracks[l]===u;r.onTrackChanged()}},SUBTITLES:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e];ut.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track."),sm(n,r);var i=r.activeTrack();i&&(i.mode="disabled"),r.onTrackChanged()}}},fm={AUDIO:function(e,t,n){if(t){var r=n.tech,i=n.requestOptions,a=n.segmentLoaders[e];t.on("loadedmetadata",function(){var e=t.media();a.playlist(e,i),(!r.paused()||e.endList&&"none"!==r.preload())&&a.load()}),t.on("loadedplaylist",function(){a.playlist(t.media(),i),r.paused()||a.load()}),t.on("error",dm[e](e,n))}},SUBTITLES:function(e,t,n){var r=n.tech,i=n.requestOptions,a=n.segmentLoaders[e],o=n.mediaTypes[e];t.on("loadedmetadata",function(){var e=t.media();a.playlist(e,i),a.track(o.activeTrack()),(!r.paused()||e.endList&&"none"!==r.preload())&&a.load()}),t.on("loadedplaylist",function(){a.playlist(t.media(),i),r.paused()||a.load()}),t.on("error",dm[e](e,n))}},hm={AUDIO:function(e,t){var n=t.hls,r=t.sourceType,i=t.segmentLoaders[e],a=t.requestOptions,o=t.master.mediaGroups,s=t.mediaTypes[e],u=s.groups,l=s.tracks,c=t.masterPlaylistLoader;o[e]&&0!==Object.keys(o[e]).length||(o[e]={main:{default:{default:!0}}});for(var d in o[e]){u[d]||(u[d]=[]);for(var f in o[e][d]){var h=o[e][d][f],p=void 0;if(p=h.resolvedUri?new Ef(h.resolvedUri,n,a):h.playlists&&"dash"===r?new _p(h.playlists[0],n,a,c):null,h=ut.mergeOptions({id:f,playlistLoader:p},h),fm[e](e,h.playlistLoader,t),u[d].push(h),void 0===l[f]){var m=new ut.AudioTrack({id:f,kind:om(h),enabled:!1,language:h.language,default:h.default,label:f});l[f]=m}}}i.on("error",dm[e](e,t))},SUBTITLES:function(e,t){var n=t.tech,r=t.hls,i=t.sourceType,a=t.segmentLoaders[e],o=t.requestOptions,s=t.master.mediaGroups,u=t.mediaTypes[e],l=u.groups,c=u.tracks,d=t.masterPlaylistLoader;for(var f in s[e]){l[f]||(l[f]=[]);for(var h in s[e][f])if(!s[e][f][h].forced){var p=s[e][f][h],m=void 0;if("hls"===i?m=new Ef(p.resolvedUri,r,o):"dash"===i&&(m=new _p(p.playlists[0],r,o,d)),p=ut.mergeOptions({id:h,playlistLoader:m},p),fm[e](e,p.playlistLoader,t),l[f].push(p),void 0===c[h]){var v=n.addRemoteTextTrack({id:h,kind:"subtitles",default:p.default&&p.autoselect,language:p.language,label:h},!1).track;c[h]=v}}}a.on("error",dm[e](e,t))},"CLOSED-CAPTIONS":function(e,t){var n=t.tech,r=t.master.mediaGroups,i=t.mediaTypes[e],a=i.groups,o=i.tracks;for(var s in r[e]){a[s]||(a[s]=[]);for(var u in r[e][s]){var l=r[e][s][u];if(l.instreamId.match(/CC\d/)&&(a[s].push(ut.mergeOptions({id:u},l)),void 0===o[u])){var c=n.addRemoteTextTrack({id:l.instreamId,kind:"captions",default:l.default&&l.autoselect,language:l.language,label:u},!1).track;o[u]=c}}}}},pm=function(e,t){return function(n){var r=t.masterPlaylistLoader,i=t.mediaTypes[e].groups,a=r.media();if(!a)return null;var o=null;return a.attributes[e]&&(o=i[a.attributes[e]]),o=o||i.main,void 0===n?o:null===n?null:o.filter(function(e){return e.id===n.id})[0]||null}},mm={AUDIO:function(e,t){return function(){var n=t.mediaTypes[e].tracks;for(var r in n)if(n[r].enabled)return n[r];return null}},SUBTITLES:function(e,t){return function(){var n=t.mediaTypes[e].tracks;for(var r in n)if("showing"===n[r].mode)return n[r];return null}}},vm=function(e){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(function(t){hm[t](t,e)});var t=e.mediaTypes,n=e.masterPlaylistLoader,r=e.tech,i=e.hls;["AUDIO","SUBTITLES"].forEach(function(n){t[n].activeGroup=pm(n,e),t[n].activeTrack=mm[n](n,e),t[n].onGroupChanged=lm(n,e),t[n].onTrackChanged=cm(n,e)});var a=t.AUDIO.activeGroup(),o=(a.filter(function(e){return e.default})[0]||a[0]).id;t.AUDIO.tracks[o].enabled=!0,t.AUDIO.onTrackChanged(),n.on("mediachange",function(){["AUDIO","SUBTITLES"].forEach(function(e){return t[e].onGroupChanged()})});var s=function(){t.AUDIO.onTrackChanged(),r.trigger({type:"usage",name:"hls-audio-change"})};r.audioTracks().addEventListener("change",s),r.remoteTextTracks().addEventListener("change",t.SUBTITLES.onTrackChanged),i.on("dispose",function(){r.audioTracks().removeEventListener("change",s),r.remoteTextTracks().removeEventListener("change",t.SUBTITLES.onTrackChanged)}),r.clearTracks("audio");for(var u in t.AUDIO.tracks)r.audioTracks().addTrack(t.AUDIO.tracks[u])},gm=function(){var e={};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(function(t){e[t]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:gt,activeTrack:gt,onGroupChanged:gt,onTrackChanged:gt}}),e},ym=void 0,_m=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred"],bm=function(e){return this.audioSegmentLoader_[e]+this.mainSegmentLoader_[e]},Tm=function(t){function n(e){lf(this,n);var t=hf(this,(n.__proto__||Object.getPrototypeOf(n)).call(this)),r=e.url,i=e.handleManifestRedirects,a=e.withCredentials,o=e.tech,s=e.bandwidth,u=e.externHls,l=e.useCueTags,c=e.blacklistDuration,d=e.enableLowInitialPlaylist,f=e.sourceType,h=e.seekTo,p=e.cacheEncryptionKeys;if(!r)throw new Error("A non-empty playlist URL is required");ym=u,t.withCredentials=a,t.tech_=o,t.hls_=o.hls,t.seekTo_=h,t.sourceType_=f,t.useCueTags_=l,t.blacklistDuration=c,t.enableLowInitialPlaylist=d,t.useCueTags_&&(t.cueTagsTrack_=t.tech_.addTextTrack("metadata","ad-cues"),t.cueTagsTrack_.inBandMetadataTrackDispatchType=""),t.requestOptions_={withCredentials:a,handleManifestRedirects:i,timeout:null},t.mediaTypes_=gm(),t.mediaSource=new ut.MediaSource,t.mediaSource.addEventListener("sourceopen",t.handleSourceOpen_.bind(t)),t.seekable_=ut.createTimeRanges(),t.hasPlayed_=function(){return!1},t.syncController_=new im(e),t.segmentMetadataTrack_=o.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,t.decrypter_=new am,t.inbandTextTracks_={};var m={hls:t.hls_,mediaSource:t.mediaSource,currentTime:t.tech_.currentTime.bind(t.tech_),seekable:function(){return t.seekable()},seeking:function(){return t.tech_.seeking()},duration:function(){return t.mediaSource.duration},hasPlayed:function(){return t.hasPlayed_()},goalBufferLength:function(){return t.goalBufferLength()},bandwidth:s,syncController:t.syncController_,decrypter:t.decrypter_,sourceType:t.sourceType_,inbandTextTracks:t.inbandTextTracks_,cacheEncryptionKeys:p};return t.masterPlaylistLoader_="dash"===t.sourceType_?new _p(r,t.hls_,t.requestOptions_):new Ef(r,t.hls_,t.requestOptions_),t.setupMasterPlaylistLoaderListeners_(),t.mainSegmentLoader_=new Xp(ut.mergeOptions(m,{segmentMetadataTrack:t.segmentMetadataTrack_,loaderType:"main"}),e),t.audioSegmentLoader_=new Xp(ut.mergeOptions(m,{loaderType:"audio"}),e),t.subtitleSegmentLoader_=new Zp(ut.mergeOptions(m,{loaderType:"vtt"}),e),t.setupSegmentLoaderListeners_(),_m.forEach(function(e){t[e+"_"]=bm.bind(t,e)}),t.logger_=bp("MPC"),t.masterPlaylistLoader_.load(),t}return ff(n,t),cf(n,[{key:"setupMasterPlaylistLoaderListeners_",value:function(){var e=this;this.masterPlaylistLoader_.on("loadedmetadata",function(){var t=e.masterPlaylistLoader_.media(),n=1.5*t.targetDuration*1e3;Yf(e.masterPlaylistLoader_.master,e.masterPlaylistLoader_.media())?e.requestOptions_.timeout=0:e.requestOptions_.timeout=n,t.endList&&"none"!==e.tech_.preload()&&(e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.mainSegmentLoader_.load()),vm({sourceType:e.sourceType_,segmentLoaders:{AUDIO:e.audioSegmentLoader_,SUBTITLES:e.subtitleSegmentLoader_,main:e.mainSegmentLoader_},tech:e.tech_,requestOptions:e.requestOptions_,masterPlaylistLoader:e.masterPlaylistLoader_,hls:e.hls_,master:e.master(),mediaTypes:e.mediaTypes_,blacklistCurrentPlaylist:e.blacklistCurrentPlaylist.bind(e)}),e.triggerPresenceUsage_(e.master(),t);try{e.setupSourceBuffers_()}catch(t){return ut.log.warn("Failed to create SourceBuffers",t),e.mediaSource.endOfStream("decode")}e.setupFirstPlay(),!e.mediaTypes_.AUDIO.activePlaylistLoader||e.mediaTypes_.AUDIO.activePlaylistLoader.media()?e.trigger("selectedinitialmedia"):e.mediaTypes_.AUDIO.activePlaylistLoader.one("loadedmetadata",function(){e.trigger("selectedinitialmedia")})}),this.masterPlaylistLoader_.on("loadedplaylist",function(){var t=e.masterPlaylistLoader_.media();if(!t){e.excludeUnsupportedVariants_();var n=void 0;return e.enableLowInitialPlaylist&&(n=e.selectInitialPlaylist()),n||(n=e.selectPlaylist()),e.initialMedia_=n,void e.masterPlaylistLoader_.media(e.initialMedia_)}if(e.useCueTags_&&e.updateAdCues_(t),e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.updateDuration(),e.tech_.paused()||(e.mainSegmentLoader_.load(),e.audioSegmentLoader_&&e.audioSegmentLoader_.load()),!t.endList){var r=function(){var t=e.seekable();0!==t.length&&e.mediaSource.addSeekableRange_(t.start(0),t.end(0))};if(e.duration()!==1/0){var i=function t(){e.duration()===1/0?r():e.tech_.one("durationchange",t)};e.tech_.one("durationchange",i)}else r()}}),this.masterPlaylistLoader_.on("error",function(){e.blacklistCurrentPlaylist(e.masterPlaylistLoader_.error)}),this.masterPlaylistLoader_.on("mediachanging",function(){e.mainSegmentLoader_.abort(),e.mainSegmentLoader_.pause()}),this.masterPlaylistLoader_.on("mediachange",function(){var t=e.masterPlaylistLoader_.media(),n=1.5*t.targetDuration*1e3;Yf(e.masterPlaylistLoader_.master,e.masterPlaylistLoader_.media())?e.requestOptions_.timeout=0:e.requestOptions_.timeout=n,e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.mainSegmentLoader_.load(),e.tech_.trigger({type:"mediachange",bubbles:!0})}),this.masterPlaylistLoader_.on("playlistunchanged",function(){var t=e.masterPlaylistLoader_.media();e.stuckAtPlaylistEnd_(t)&&(e.blacklistCurrentPlaylist({message:"Playlist no longer updating."}),e.tech_.trigger("playliststuck"))}),this.masterPlaylistLoader_.on("renditiondisabled",function(){e.tech_.trigger({type:"usage",name:"hls-rendition-disabled"})}),this.masterPlaylistLoader_.on("renditionenabled",function(){e.tech_.trigger({type:"usage",name:"hls-rendition-enabled"})})}},{key:"triggerPresenceUsage_",value:function(e,t){var n=e.mediaGroups||{},r=!0,i=Object.keys(n.AUDIO);for(var a in n.AUDIO)for(var o in n.AUDIO[a]){var s=n.AUDIO[a][o];s.uri||(r=!1)}r&&this.tech_.trigger({type:"usage",name:"hls-demuxed"}),Object.keys(n.SUBTITLES).length&&this.tech_.trigger({type:"usage",name:"hls-webvtt"}),ym.Playlist.isAes(t)&&this.tech_.trigger({type:"usage",name:"hls-aes"}),ym.Playlist.isFmp4(t)&&this.tech_.trigger({type:"usage",name:"hls-fmp4"}),i.length&&Object.keys(n.AUDIO[i[0]]).length>1&&this.tech_.trigger({type:"usage",name:"hls-alternate-audio"}),this.useCueTags_&&this.tech_.trigger({type:"usage",name:"hls-playlist-cue-tags"})}},{key:"setupSegmentLoaderListeners_",value:function(){var e=this;this.mainSegmentLoader_.on("bandwidthupdate",function(){var t=e.selectPlaylist(),n=e.masterPlaylistLoader_.media(),r=e.tech_.buffered(),i=r.length?r.end(r.length-1)-e.tech_.currentTime():0,a=e.bufferLowWaterLine();(!n.endList||e.duration()<Sp.MAX_BUFFER_LOW_WATER_LINE||t.attributes.BANDWIDTH<n.attributes.BANDWIDTH||i>=a)&&e.masterPlaylistLoader_.media(t),e.tech_.trigger("bandwidthupdate")}),this.mainSegmentLoader_.on("progress",function(){e.trigger("progress")}),this.mainSegmentLoader_.on("error",function(){e.blacklistCurrentPlaylist(e.mainSegmentLoader_.error())}),this.mainSegmentLoader_.on("syncinfoupdate",function(){e.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("timestampoffset",function(){e.tech_.trigger({type:"usage",name:"hls-timestamp-offset"})}),this.audioSegmentLoader_.on("syncinfoupdate",function(){e.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("ended",function(){e.onEndOfStream()}),this.mainSegmentLoader_.on("earlyabort",function(){e.blacklistCurrentPlaylist({message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},120)}),this.mainSegmentLoader_.on("reseteverything",function(){e.tech_.trigger("hls-reset")}),this.mainSegmentLoader_.on("segmenttimemapping",function(t){e.tech_.trigger({type:"hls-segment-time-mapping",mapping:t.mapping})}),this.audioSegmentLoader_.on("ended",function(){e.onEndOfStream()})}},{key:"mediaSecondsLoaded_",value:function(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)}},{key:"load",value:function(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()}},{key:"smoothQualityChange_",value:function(){var e=this.selectPlaylist();e!==this.masterPlaylistLoader_.media()&&(this.masterPlaylistLoader_.media(e),this.mainSegmentLoader_.resetLoader())}},{key:"fastQualityChange_",value:function(){var e=this,t=this.selectPlaylist();t!==this.masterPlaylistLoader_.media()&&(this.masterPlaylistLoader_.media(t),this.mainSegmentLoader_.resetEverything(function(){ut.browser.IE_VERSION||ut.browser.IS_EDGE?e.tech_.setCurrentTime(e.tech_.currentTime()+.04):e.tech_.setCurrentTime(e.tech_.currentTime())}))}},{key:"play",value:function(){if(!this.setupFirstPlay()){this.tech_.ended()&&this.seekTo_(0),this.hasPlayed_()&&this.load();var e=this.tech_.seekable();return this.tech_.duration()===1/0&&this.tech_.currentTime()<e.start(0)?this.seekTo_(e.end(e.length-1)):void 0}}},{key:"setupFirstPlay",value:function(){var e=this,t=this.masterPlaylistLoader_.media();if(!t||this.tech_.paused()||this.hasPlayed_())return!1;if(!t.endList){var n=this.seekable();if(!n.length)return!1;if(ut.browser.IE_VERSION&&0===this.tech_.readyState())return this.tech_.one("loadedmetadata",function(){e.trigger("firstplay"),e.seekTo_(n.end(0)),e.hasPlayed_=function(){return!0}}),!1;this.trigger("firstplay"),this.seekTo_(n.end(0))}return this.hasPlayed_=function(){return!0},this.load(),!0}},{key:"handleSourceOpen_",value:function(){try{this.setupSourceBuffers_()}catch(e){return ut.log.warn("Failed to create Source Buffers",e),this.mediaSource.endOfStream("decode")}if(this.tech_.autoplay()){var e=this.tech_.play();void 0!==e&&"function"==typeof e.then&&e.then(null,function(e){})}this.trigger("sourceopen")}},{key:"onEndOfStream",value:function(){var e=this.mainSegmentLoader_.ended_;if(this.mediaTypes_.AUDIO.activePlaylistLoader&&(e=!this.mainSegmentLoader_.startingMedia_||this.mainSegmentLoader_.startingMedia_.containsVideo?e&&this.audioSegmentLoader_.ended_:this.audioSegmentLoader_.ended_),e){this.logger_("calling mediaSource.endOfStream()");try{this.mediaSource.endOfStream()}catch(e){ut.log.warn("Failed to call media source endOfStream",e)}}}},{key:"stuckAtPlaylistEnd_",value:function(e){if(!this.seekable().length)return!1;var t=this.syncController_.getExpiredTime(e,this.mediaSource.duration);if(null===t)return!1;var n=ym.Playlist.playlistEnd(e,t),r=this.tech_.currentTime(),i=this.tech_.buffered();if(!i.length)return n-r<=.1;var a=i.end(i.length-1);return a-r<=.1&&n-a<=.1}},{key:"blacklistCurrentPlaylist",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments[1],n=void 0,r=void 0;if(n=e.playlist||this.masterPlaylistLoader_.media(),t=t||e.blacklistDuration||this.blacklistDuration,!n){this.error=e;try{return this.mediaSource.endOfStream("network")}catch(e){return this.trigger("error")}}var i=1===this.masterPlaylistLoader_.master.playlists.filter(qf).length,a=this.masterPlaylistLoader_.master.playlists;return 1===a.length?(ut.log.warn("Problem encountered with the current HLS playlist. Trying again since it is the only playlist."),this.tech_.trigger("retryplaylist"),this.masterPlaylistLoader_.load(i)):(i&&(ut.log.warn("Removing all playlists from the blacklist because the last rendition is about to be blacklisted."),a.forEach(function(e){e.excludeUntil!==1/0&&delete e.excludeUntil}),this.tech_.trigger("retryplaylist")),n.excludeUntil=Date.now()+1e3*t,this.tech_.trigger("blacklistplaylist"),this.tech_.trigger({type:"usage",name:"hls-rendition-blacklisted"}),r=this.selectPlaylist(),ut.log.warn("Problem encountered with the current HLS playlist."+(e.message?" "+e.message:"")+" Switching to another playlist."),this.masterPlaylistLoader_.media(r,i))}},{key:"pauseLoading",value:function(){this.mainSegmentLoader_.pause(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.pause(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.pause()}},{key:"setCurrentTime",value:function(e){var t=bh(this.tech_.buffered(),e);return this.masterPlaylistLoader_&&this.masterPlaylistLoader_.media()&&this.masterPlaylistLoader_.media().segments?t&&t.length?e:(this.mainSegmentLoader_.resetEverything(),this.mainSegmentLoader_.abort(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.resetEverything(),this.audioSegmentLoader_.abort()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.resetEverything(),this.subtitleSegmentLoader_.abort()),void this.load()):0}},{key:"duration",value:function(){return this.masterPlaylistLoader_?this.mediaSource?this.mediaSource.duration:ym.Playlist.duration(this.masterPlaylistLoader_.media()):0}},{key:"seekable",value:function(){return this.seekable_}},{key:"onSyncInfoUpdate_",value:function(){var e=void 0,t=void 0;if(this.masterPlaylistLoader_){var n=this.masterPlaylistLoader_.media();if(n){var r=this.syncController_.getExpiredTime(n,this.mediaSource.duration);if(null!==r&&(e=ym.Playlist.seekable(n,r),0!==e.length)){if(this.mediaTypes_.AUDIO.activePlaylistLoader){if(n=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),null===(r=this.syncController_.getExpiredTime(n,this.mediaSource.duration)))return;if(t=ym.Playlist.seekable(n,r),0===t.length)return}var i=void 0,a=void 0;this.seekable_&&this.seekable_.length&&(i=this.seekable_.end(0),a=this.seekable_.start(0)),t?t.start(0)>e.end(0)||e.start(0)>t.end(0)?this.seekable_=e:this.seekable_=ut.createTimeRanges([[t.start(0)>e.start(0)?t.start(0):e.start(0),t.end(0)<e.end(0)?t.end(0):e.end(0)]]):this.seekable_=e,this.seekable_&&this.seekable_.length&&this.seekable_.end(0)===i&&this.seekable_.start(0)===a||(this.logger_("seekable updated ["+wh(this.seekable_)+"]"),this.tech_.trigger("seekablechanged"))}}}}},{key:"updateDuration",value:function(){var e=this,t=this.mediaSource.duration,n=ym.Playlist.duration(this.masterPlaylistLoader_.media()),r=this.tech_.buffered(),i=function t(){e.logger_("Setting duration from "+e.mediaSource.duration+" => "+n);try{e.mediaSource.duration=n}catch(e){ut.log.warn("Failed to set media source duration",e)}e.tech_.trigger("durationchange"),e.mediaSource.removeEventListener("sourceopen",t)};r.length>0&&(n=Math.max(n,r.end(r.length-1))),t!==n&&("open"!==this.mediaSource.readyState?this.mediaSource.addEventListener("sourceopen",i):i())}},{key:"dispose",value:function(){var e=this;this.decrypter_.terminate(),this.masterPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),["AUDIO","SUBTITLES"].forEach(function(t){var n=e.mediaTypes_[t].groups;for(var r in n)n[r].forEach(function(e){e.playlistLoader&&e.playlistLoader.dispose()})}),this.audioSegmentLoader_.dispose(),this.subtitleSegmentLoader_.dispose()}},{key:"master",value:function(){return this.masterPlaylistLoader_.master}},{key:"media",value:function(){return this.masterPlaylistLoader_.media()||this.initialMedia_}},{key:"setupSourceBuffers_",value:function(){var e=this.masterPlaylistLoader_.media(),t=void 0;if(e&&"open"===this.mediaSource.readyState){if(t=Kh(this.masterPlaylistLoader_.master,e),t.length<1)return this.error="No compatible SourceBuffer configuration for the variant stream:"+e.resolvedUri,this.mediaSource.endOfStream("decode");this.configureLoaderMimeTypes_(t),this.excludeIncompatibleVariants_(e)}}},{key:"configureLoaderMimeTypes_",value:function(e){var t=e.length>1&&-1===e[0].indexOf(",")&&e[0]!==e[1]?new ut.EventTarget:null;this.mainSegmentLoader_.mimeType(e[0],t),e[1]&&this.audioSegmentLoader_.mimeType(e[1],t)}},{key:"excludeUnsupportedVariants_",value:function(){this.master().playlists.forEach(function(t){t.attributes.CODECS&&e.MediaSource&&e.MediaSource.isTypeSupported&&!e.MediaSource.isTypeSupported('video/mp4; codecs="'+Hh(t.attributes.CODECS)+'"')&&(t.excludeUntil=1/0)})}},{key:"excludeIncompatibleVariants_",value:function(e){var t=2,n=null,r=void 0;e.attributes.CODECS&&(r=Gh(e.attributes.CODECS),n=r.videoCodec,t=r.codecCount),this.master().playlists.forEach(function(e){var r={codecCount:2,videoCodec:null};e.attributes.CODECS&&(r=Gh(e.attributes.CODECS)),r.codecCount!==t&&(e.excludeUntil=1/0),r.videoCodec!==n&&(e.excludeUntil=1/0)})}},{key:"updateAdCues_",value:function(e){var t=0,n=this.seekable();n.length&&(t=n.start(0)),tm(e,this.cueTagsTrack_,t)}},{key:"goalBufferLength",value:function(){var e=this.tech_.currentTime(),t=Sp.GOAL_BUFFER_LENGTH,n=Sp.GOAL_BUFFER_LENGTH_RATE,r=Math.max(t,Sp.MAX_GOAL_BUFFER_LENGTH);return Math.min(t+e*n,r)}},{key:"bufferLowWaterLine",value:function(){var e=this.tech_.currentTime(),t=Sp.BUFFER_LOW_WATER_LINE,n=Sp.BUFFER_LOW_WATER_LINE_RATE,r=Math.max(t,Sp.MAX_BUFFER_LOW_WATER_LINE);return Math.min(t+e*n,r)}}]),n}(ut.EventTarget),Sm=function(e,t,n){return function(r){var i=e.master.playlists[t],a=Vf(i),o=qf(i);return void 0===r?o:(r?delete i.disabled:i.disabled=!0,r===o||a||(n(),r?e.trigger("renditionenabled"):e.trigger("renditiondisabled")),r)}},wm=function e(t,n,r){lf(this,e);var i=t.masterPlaylistController_,a=t.options_.smoothQualityChange,o=a?"smooth":"fast",s=i[o+"QualityChange_"].bind(i);if(n.attributes.RESOLUTION){var u=n.attributes.RESOLUTION;this.width=u.width,this.height=u.height}this.bandwidth=n.attributes.BANDWIDTH,this.id=r,this.enabled=Sm(t.playlists,n.uri,s)},km=function(e){var t=e.playlists;e.representations=function(){return t.master.playlists.filter(function(e){return!Vf(e)}).map(function(t,n){return new wm(e,t,t.uri)})}},Em=["seeking","seeked","pause","playing","error"],Am=function(){function t(n){var r=this;lf(this,t),this.tech_=n.tech,this.seekable=n.seekable,this.seekTo=n.seekTo,this.allowSeeksWithinUnsafeLiveWindow=n.allowSeeksWithinUnsafeLiveWindow,this.media=n.media,this.consecutiveUpdates=0,this.lastRecordedTime=null,this.timer_=null,this.checkCurrentTimeTimeout_=null,this.logger_=bp("PlaybackWatcher"),this.logger_("initialize");var i=function(){return r.monitorCurrentTime_()},a=function(){return r.techWaiting_()},o=function(){return r.cancelTimer_()},s=function(){return r.fixesBadSeeks_()};this.tech_.on("seekablechanged",s),this.tech_.on("waiting",a),this.tech_.on(Em,o),this.tech_.on("canplay",i),this.dispose=function(){r.logger_("dispose"),r.tech_.off("seekablechanged",s),r.tech_.off("waiting",a),r.tech_.off(Em,o),r.tech_.off("canplay",i),r.checkCurrentTimeTimeout_&&e.clearTimeout(r.checkCurrentTimeTimeout_),r.cancelTimer_()}}return cf(t,[{key:"monitorCurrentTime_",value:function(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&e.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=e.setTimeout(this.monitorCurrentTime_.bind(this),250)}},{key:"checkCurrentTime_",value:function(){if(this.tech_.seeking()&&this.fixesBadSeeks_())return this.consecutiveUpdates=0,void(this.lastRecordedTime=this.tech_.currentTime());if(!this.tech_.paused()&&!this.tech_.seeking()){var e=this.tech_.currentTime(),t=this.tech_.buffered();if(this.lastRecordedTime===e&&(!t.length||e+.1>=t.end(t.length-1)))return this.techWaiting_();this.consecutiveUpdates>=5&&e===this.lastRecordedTime?(this.consecutiveUpdates++,this.waiting_()):e===this.lastRecordedTime?this.consecutiveUpdates++:(this.consecutiveUpdates=0,this.lastRecordedTime=e)}}},{key:"cancelTimer_",value:function(){this.consecutiveUpdates=0,this.timer_&&(this.logger_("cancelTimer_"),clearTimeout(this.timer_)),this.timer_=null}},{key:"fixesBadSeeks_",value:function(){if(!this.tech_.seeking())return!1;var e=this.seekable(),t=this.tech_.currentTime(),n=this.afterSeekableWindow_(e,t,this.media(),this.allowSeeksWithinUnsafeLiveWindow),r=void 0;return n&&(r=e.end(e.length-1)),this.beforeSeekableWindow_(e,t)&&(r=e.start(0)+.1),void 0!==r&&(this.logger_("Trying to seek outside of seekable at time "+t+" with seekable range "+wh(e)+". Seeking to "+r+"."),this.seekTo(r),!0)}},{key:"waiting_",value:function(){if(!this.techWaiting_()){var e=this.tech_.currentTime(),t=this.tech_.buffered(),n=bh(t,e);return n.length&&e+3<=n.end(0)?(this.cancelTimer_(),this.seekTo(e),this.logger_("Stopped at "+e+" while inside a buffered region ["+n.start(0)+" -> "+n.end(0)+"]. Attempting to resume playback by seeking to the current time."),void this.tech_.trigger({type:"usage",name:"hls-unknown-waiting"})):void 0}}},{key:"techWaiting_",value:function(){var e=this.seekable(),t=this.tech_.currentTime();if(this.tech_.seeking()&&this.fixesBadSeeks_())return!0;if(this.tech_.seeking()||null!==this.timer_)return!0;if(this.beforeSeekableWindow_(e,t)){var n=e.end(e.length-1);return this.logger_("Fell out of live window at time "+t+". Seeking to live point (seekable end) "+n),this.cancelTimer_(),this.seekTo(n),this.tech_.trigger({type:"usage",name:"hls-live-resync"}),!0}var r=this.tech_.buffered(),i=Th(r,t);if(this.videoUnderflow_(i,r,t))return this.cancelTimer_(),this.seekTo(t),this.tech_.trigger({type:"usage",name:"hls-video-underflow"}),!0;if(i.length>0){var a=i.start(0)-t;return this.logger_("Stopped at "+t+", setting timer for "+a+", seeking to "+i.start(0)),this.timer_=setTimeout(this.skipTheGap_.bind(this),1e3*a,t),!0}return!1}},{key:"afterSeekableWindow_",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!e.length)return!1;var i=e.end(e.length-1)+.1;return!n.endList&&r&&(i=e.end(e.length-1)+3*n.targetDuration),t>i}},{key:"beforeSeekableWindow_",value:function(e,t){return!!(e.length&&e.start(0)>0&&t<e.start(0)-.1)}},{key:"videoUnderflow_",value:function(e,t,n){if(0===e.length){var r=this.gapFromVideoUnderflow_(t,n);if(r)return this.logger_("Encountered a gap in video from "+r.start+" to "+r.end+". Seeking to current time "+n),!0}return!1}},{key:"skipTheGap_",value:function(e){var t=this.tech_.buffered(),n=this.tech_.currentTime(),r=Th(t,n);this.cancelTimer_(),0!==r.length&&n===e&&(this.logger_("skipTheGap_:","currentTime:",n,"scheduled currentTime:",e,"nextRange start:",r.start(0)),this.seekTo(r.start(0)+1/30),this.tech_.trigger({type:"usage",name:"hls-gap-skip"}))}},{key:"gapFromVideoUnderflow_",value:function(e,t){for(var n=Sh(e),r=0;r<n.length;r++){var i=n.start(r),a=n.end(r);if(t-i<4&&t-i>2)return{start:i,end:a}}return null}}]),t}(),Cm={errorInterval:30,getSource:function(e){return e(this.tech({IWillNotUseThisInPlugins:!0}).currentSource_)}},Lm=function e(t,n){var r=0,i=0,a=ut.mergeOptions(Cm,n);t.ready(function(){t.trigger({type:"usage",name:"hls-error-reload-initialized"})});var o=function(){i&&t.currentTime(i)},s=function(e){null!==e&&void 0!==e&&(i=t.duration()!==1/0&&t.currentTime()||0,t.one("loadedmetadata",o),t.src(e),t.trigger({type:"usage",name:"hls-error-reload"}),t.play())},u=function(){return Date.now()-r<1e3*a.errorInterval?void t.trigger({type:"usage",name:"hls-error-reload-canceled"}):a.getSource&&"function"==typeof a.getSource?(r=Date.now(),a.getSource.call(t,s)):void ut.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!")},l=function e(){t.off("loadedmetadata",o),t.off("error",u),t.off("dispose",e)},c=function(n){l(),e(t,n)};t.on("error",u),t.on("dispose",l),t.reloadSourceOnError=c},xm=function(e){Lm(this,e)};ut.use("*",function(e){return{setSource:function(e,t){t(null,e)},setCurrentTime:function(t){return e.vhs&&e.currentSource().src===e.vhs.source_.src&&e.vhs.setCurrentTime(t),t},play:function(){e.vhs&&e.currentSource().src===e.vhs.source_.src&&e.vhs.setCurrentTime(e.tech_.currentTime())}}});var jm={PlaylistLoader:Ef,Playlist:Kf,Decrypter:of,AsyncStream:nf,decrypt:af,utils:ch,STANDARD_PLAYLIST_SELECTOR:Fp,INITIAL_PLAYLIST_SELECTOR:qp,comparePlaylistBandwidth:Up,comparePlaylistResolution:Bp,xhr:Qf()};["GOAL_BUFFER_LENGTH","MAX_GOAL_BUFFER_LENGTH","GOAL_BUFFER_LENGTH_RATE","BUFFER_LOW_WATER_LINE","MAX_BUFFER_LOW_WATER_LINE","BUFFER_LOW_WATER_LINE_RATE","BANDWIDTH_VARIANCE"].forEach(function(e){Object.defineProperty(jm,e,{get:function(){return ut.log.warn("using Hls."+e+" is UNSAFE be sure you know what you are doing"),Sp[e]},set:function(t){if(ut.log.warn("using Hls."+e+" is UNSAFE be sure you know what you are doing"),"number"!=typeof t||t<0)return void ut.log.warn("value of Hls."+e+" must be greater than or equal to 0");Sp[e]=t}})});var Om=function(e){return/^(audio|video|application)\/(x-|vnd\.apple\.)?mpegurl/i.test(e)?"hls":/^application\/dash\+xml/i.test(e)?"dash":null},Im=function(e,t){for(var n=t.media(),r=-1,i=0;i<e.length;i++)if(e[i].id===n.uri){r=i;break}e.selectedIndex_=r,e.trigger({selectedIndex:r,type:"change"})},Pm=function(e,t){t.representations().forEach(function(t){e.addQualityLevel(t)}),Im(e,t.playlists)};jm.canPlaySource=function(){return ut.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var Rm=function(e,t,n){if(!e)return e;var r={};for(var i in e)r[i]={audioContentType:'audio/mp4; codecs="'+n.attributes.CODECS+'"',videoContentType:'video/mp4; codecs="'+t.attributes.CODECS+'"'},t.contentProtection&&t.contentProtection[i]&&t.contentProtection[i].pssh&&(r[i].pssh=t.contentProtection[i].pssh),"string"==typeof e[i]&&(r[i].url=e[i]);return ut.mergeOptions(e,r)},Dm=function(e){if("dash"===e.options_.sourceType){var t=ut.players[e.tech_.options_.playerId];if(t.eme){var n=Rm(e.source_.keySystems,e.playlists.media(),e.masterPlaylistController_.mediaTypes_.AUDIO.activePlaylistLoader.media());n&&(t.currentSource().keySystems=n,t.eme.initializeMediaKeys&&t.eme.initializeMediaKeys())}}},Mm=function(){if(!window.localStorage)return null;var e=window.localStorage.getItem("videojs-vhs");if(!e)return null;try{return JSON.parse(e)}catch(e){return null}},Um=function(e){if(!window.localStorage)return!1;var t=Mm();t=t?ut.mergeOptions(t,e):e;try{window.localStorage.setItem("videojs-vhs",JSON.stringify(t))}catch(e){return!1}return t};jm.supportsNativeHls=function(){var e=t.createElement("video");return!!ut.getTech("Html5").isSupported()&&["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"].some(function(t){return/maybe|probably/i.test(e.canPlayType(t))})}(),jm.supportsNativeDash=function(){return!!ut.getTech("Html5").isSupported()&&/maybe|probably/i.test(t.createElement("video").canPlayType("application/dash+xml"))}(),jm.supportsTypeNatively=function(e){return"hls"===e?jm.supportsNativeHls:"dash"===e&&jm.supportsNativeDash},jm.isSupported=function(){return ut.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var Bm=ut.getComponent("Component"),Nm=function(e){function n(e,r,i){lf(this,n);var a=hf(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,r,i.hls));if(r.options_&&r.options_.playerId){var o=ut(r.options_.playerId);o.hasOwnProperty("hls")||Object.defineProperty(o,"hls",{get:function(){return ut.log.warn("player.hls is deprecated. Use player.tech().hls instead."),r.trigger({type:"usage",name:"hls-player-access"}),a},configurable:!0}),o.vhs=a,o.dash=a,a.player_=o}if(a.tech_=r,a.source_=e,a.stats={},a.setOptions_(),a.options_.overrideNative&&r.overrideNativeAudioTracks&&r.overrideNativeVideoTracks)r.overrideNativeAudioTracks(!0),r.overrideNativeVideoTracks(!0);else if(a.options_.overrideNative&&(r.featuresNativeVideoTracks||r.featuresNativeAudioTracks))throw new Error("Overriding native HLS requires emulated tracks. See https://git.io/vMpjB");return a.on(t,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],function(e){var n=t.fullscreenElement||t.webkitFullscreenElement||t.mozFullScreenElement||t.msFullscreenElement;n&&n.contains(a.tech_.el())&&a.masterPlaylistController_.smoothQualityChange_()}),a.on(a.tech_,"seeking",function(){0===this.tech_.currentTime()&&this.tech_.player_.loop()&&this.setCurrentTime(0)}),a.on(a.tech_,"error",function(){this.masterPlaylistController_&&this.masterPlaylistController_.pauseLoading()}),a.on(a.tech_,"play",a.play),a}return ff(n,e),cf(n,[{key:"setOptions_",value:function(){var e=this;if(this.options_.withCredentials=this.options_.withCredentials||!1,this.options_.handleManifestRedirects=this.options_.handleManifestRedirects||!1,this.options_.limitRenditionByPlayerDimensions=!1!==this.options_.limitRenditionByPlayerDimensions,this.options_.smoothQualityChange=this.options_.smoothQualityChange||!1,this.options_.useBandwidthFromLocalStorage=void 0!==this.source_.useBandwidthFromLocalStorage?this.source_.useBandwidthFromLocalStorage:this.options_.useBandwidthFromLocalStorage||!1,this.options_.customTagParsers=this.options_.customTagParsers||[],this.options_.customTagMappers=this.options_.customTagMappers||[],this.options_.cacheEncryptionKeys=this.options_.cacheEncryptionKeys||!1,"number"!=typeof this.options_.blacklistDuration&&(this.options_.blacklistDuration=300),"number"!=typeof this.options_.bandwidth&&this.options_.useBandwidthFromLocalStorage){var t=Mm();t&&t.bandwidth&&(this.options_.bandwidth=t.bandwidth,this.tech_.trigger({type:"usage",name:"hls-bandwidth-from-local-storage"})),t&&t.throughput&&(this.options_.throughput=t.throughput,this.tech_.trigger({type:"usage",name:"hls-throughput-from-local-storage"}))}"number"!=typeof this.options_.bandwidth&&(this.options_.bandwidth=Sp.INITIAL_BANDWIDTH),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&this.options_.bandwidth===Sp.INITIAL_BANDWIDTH,["withCredentials","limitRenditionByPlayerDimensions","bandwidth","smoothQualityChange","customTagParsers","customTagMappers","handleManifestRedirects","cacheEncryptionKeys"].forEach(function(t){void 0!==e.source_[t]&&(e.options_[t]=e.source_[t])}),this.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions}},{key:"src",value:function(e,t){var n=this;e&&(this.setOptions_(),this.options_.url=this.source_.src,this.options_.tech=this.tech_,this.options_.externHls=jm,this.options_.sourceType=Om(t),this.options_.seekTo=function(e){n.tech_.setCurrentTime(e),n.setCurrentTime(e)},this.masterPlaylistController_=new Tm(this.options_),this.playbackWatcher_=new Am(ut.mergeOptions(this.options_,{seekable:function(){return n.seekable()},media:function(){return n.masterPlaylistController_.media()}})),this.masterPlaylistController_.on("error",function(){ut.players[n.tech_.options_.playerId].error(n.masterPlaylistController_.error)}),this.masterPlaylistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):jm.STANDARD_PLAYLIST_SELECTOR.bind(this),this.masterPlaylistController_.selectInitialPlaylist=jm.INITIAL_PLAYLIST_SELECTOR.bind(this),this.playlists=this.masterPlaylistController_.masterPlaylistLoader_,this.mediaSource=this.masterPlaylistController_.mediaSource,Object.defineProperties(this,{selectPlaylist:{get:function(){return this.masterPlaylistController_.selectPlaylist},set:function(e){this.masterPlaylistController_.selectPlaylist=e.bind(this)}},throughput:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.throughput.rate},set:function(e){this.masterPlaylistController_.mainSegmentLoader_.throughput.rate=e,this.masterPlaylistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.bandwidth},set:function(e){this.masterPlaylistController_.mainSegmentLoader_.bandwidth=e,this.masterPlaylistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get:function(){var e=1/(this.bandwidth||1),t=void 0;return t=this.throughput>0?1/this.throughput:0,Math.floor(1/(e+t))},set:function(){ut.log.error('The "systemBandwidth" property is read-only')}}}),this.options_.bandwidth&&(this.bandwidth=this.options_.bandwidth),this.options_.throughput&&(this.throughput=this.options_.throughput),Object.defineProperties(this.stats,{bandwidth:{get:function(){return n.bandwidth||0},enumerable:!0},mediaRequests:{get:function(){return n.masterPlaylistController_.mediaRequests_()||0},enumerable:!0},mediaRequestsAborted:{get:function(){return n.masterPlaylistController_.mediaRequestsAborted_()||0},enumerable:!0},mediaRequestsTimedout:{get:function(){return n.masterPlaylistController_.mediaRequestsTimedout_()||0},enumerable:!0},mediaRequestsErrored:{get:function(){return n.masterPlaylistController_.mediaRequestsErrored_()||0},enumerable:!0},mediaTransferDuration:{get:function(){return n.masterPlaylistController_.mediaTransferDuration_()||0},enumerable:!0},mediaBytesTransferred:{get:function(){return n.masterPlaylistController_.mediaBytesTransferred_()||0},enumerable:!0},mediaSecondsLoaded:{get:function(){return n.masterPlaylistController_.mediaSecondsLoaded_()||0},enumerable:!0},buffered:{get:function(){return Eh(n.tech_.buffered())},enumerable:!0},currentTime:{get:function(){return n.tech_.currentTime()},enumerable:!0},currentSource:{get:function(){return n.tech_.currentSource_},enumerable:!0},currentTech:{get:function(){return n.tech_.name_},enumerable:!0},duration:{get:function(){return n.tech_.duration()},enumerable:!0},master:{get:function(){return n.playlists.master},enumerable:!0},playerDimensions:{get:function(){return n.tech_.currentDimensions()},enumerable:!0},seekable:{get:function(){return Eh(n.tech_.seekable())},enumerable:!0},timestamp:{get:function(){return Date.now()},enumerable:!0},videoPlaybackQuality:{get:function(){return n.tech_.getVideoPlaybackQuality()},enumerable:!0}}),this.tech_.one("canplay",this.masterPlaylistController_.setupFirstPlay.bind(this.masterPlaylistController_)),this.tech_.on("bandwidthupdate",function(){n.options_.useBandwidthFromLocalStorage&&Um({bandwidth:n.bandwidth,throughput:Math.round(n.throughput)})}),this.masterPlaylistController_.on("selectedinitialmedia",function(){km(n),Dm(n)}),this.on(this.masterPlaylistController_,"progress",function(){this.tech_.trigger("progress")}),this.tech_.ready(function(){return n.setupQualityLevels_()}),this.tech_.el()&&this.tech_.src(ut.URL.createObjectURL(this.masterPlaylistController_.mediaSource)))}},{key:"setupQualityLevels_",value:function(){var e=this,t=ut.players[this.tech_.options_.playerId];t&&t.qualityLevels&&(this.qualityLevels_=t.qualityLevels(),this.masterPlaylistController_.on("selectedinitialmedia",function(){Pm(e.qualityLevels_,e)}),this.playlists.on("mediachange",function(){Im(e.qualityLevels_,e.playlists)}))}},{key:"play",value:function(){this.masterPlaylistController_.play()}},{key:"setCurrentTime",value:function(e){this.masterPlaylistController_.setCurrentTime(e)}},{key:"duration",value:function(){return this.masterPlaylistController_.duration()}},{key:"seekable",value:function(){return this.masterPlaylistController_.seekable()}},{key:"dispose",value:function(){this.playbackWatcher_&&this.playbackWatcher_.dispose(),this.masterPlaylistController_&&this.masterPlaylistController_.dispose(),this.qualityLevels_&&this.qualityLevels_.dispose(),this.player_&&(delete this.player_.vhs,delete this.player_.dash,delete this.player_.hls),this.tech_&&this.tech_.hls&&delete this.tech_.hls,df(n.prototype.__proto__||Object.getPrototypeOf(n.prototype),"dispose",this).call(this)}},{key:"convertToProgramTime",value:function(e,t){return gh({playlist:this.masterPlaylistController_.media(),time:e,callback:t})}},{key:"seekToProgramTime",value:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:2;return yh({programTime:e,playlist:this.masterPlaylistController_.media(),retryCount:r,pauseAfterSeek:n,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:t})}}]),n}(Bm),Fm={name:"videojs-http-streaming",VERSION:"1.10.3",canHandleSource:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=ut.mergeOptions(ut.options,t);return Fm.canPlayType(e.type,n)},handleSource:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=ut.mergeOptions(ut.options,n);return t.hls=new Nm(e,t,r),t.hls.xhr=Qf(),t.hls.src(e.src,e.type),t.hls},canPlayType:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=ut.mergeOptions(ut.options,t),r=n.hls.overrideNative,i=Om(e);return!i||jm.supportsTypeNatively(i)&&!r?"":"maybe"}};return void 0!==ut.MediaSource&&void 0!==ut.URL||(ut.MediaSource=lp,ut.URL=cp),lp.supportsNativeMediaSources()&&ut.getTech("Html5").registerSourceHandler(Fm,0),ut.HlsHandler=Nm,ut.HlsSourceHandler=Fm,ut.Hls=jm,ut.use||ut.registerComponent("Hls",jm),ut.options.hls=ut.options.hls||{},ut.registerPlugin?ut.registerPlugin("reloadSourceOnError",xm):ut.plugin("reloadSourceOnError",xm),ut}),function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("video.js")):"function"==typeof define&&define.amd?define(["video.js"],t):e.videojsSnapshot=t(e.videojs)}(this,function(e){"use strict";e="default"in e?e.default:e;var t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};return function(n,r){return r={exports:{}},function(n){!function(t,r){n.exports?n.exports=r(e):t.returnExports=r(t.videojs)}(t,function(e){var t={},n=e.registerPlugin||e.plugin,r=e.getComponent("Component"),i=e.getComponent("Button");e.SnapshoterBaseComponent=e.extend(r,{constructor:function(e,t){r.call(this,e,t)},dispose:function(){}}),e.SnapshoterComponent=e.extend(e.SnapshoterBaseComponent,{constructor:function(t,n){r.call(this,t,n),this.loadOptions(),this.resetState(),this.player().one("ready",this.setupUI.bind(this));var i=e.ImageCaptureEngine;try{this.engine=new i(this.player())}catch(t){throw new Error("Could not load "+e.ImageCaptureEngine+" plugin")}},loadOptions:function(){},setupUI:function(){this.player().controlBar.addChild(this.player().cameraButton),this.player().controlBar.el().appendChild(this.player().cameraButton.el()),this.player().options_.controls&&(this.player().controlBar.show(),this.player().controlBar.el().style.display="flex")},isSnapshoting:function(){return this._snapshoting},isProcessing:function(){return this._processing},isDestroyed:function(){return this.player()&&null===this.player().children()},start:function(){this.isProcessing()||(this._snapshoting=!0,this._processing=!0,this.player().controlBar.playToggle.hide(),this.createSnapshot())},stop:function(){this.isProcessing()&&(this._snapshoting=!1,this._processing=!1),this.player().controlBar.playToggle.show()},destroy:function(){this.stop(),this.player().dispose(),this.resetState()},reset:function(){this.stop(),this.loadOptions(),this.resetState(),this.player().reset(),this.player().snapshotCanvas.hide(),this.player().cameraButton.hide()},resetState:function(){this._snapshoting=!1,this._processing=!1},createSnapshot:function(){var e=this;this.captureFrame().then(function(t){e.player().trigger("snap",t),e.stop()}).catch(function(e){console.log(e)})},retrySnapshot:function(){this._processing=!1,this.player().snapshotCanvas.hide()},captureFrame:function(){var e=this,t=this.player().snapshotCanvas.el().firstChild;return t.width=this.player().videoWidth(),t.height=this.player().videoHeight(),new Promise(function(n,r){return n(e.engine.imageCaptureByIdAndCanvasDom(e.player().id(),t))})}});var a,o;o=e.extend(r),a=e.extend(i,{constructor:function(e,t){i.call(this,e,t),this.on("click",this.onClick),this.on("tap",this.onClick)}}),a.prototype.onClick=function(e){e.stopImmediatePropagation();var t=this.player().snapshoter;t.isProcessing()?(t.retrySnapshot(),this.onStop()):t.start()},a.prototype.onStart=function(){this.removeClass("vjs-icon-photo-camera"),this.addClass("vjs-icon-photo-retry"),this.el().firstChild.firstChild.innerHTML=this.localize("Retry")},a.prototype.onStop=function(){this.removeClass("vjs-icon-photo-retry"),this.addClass("vjs-icon-photo-camera"),this.el().firstChild.firstChild.innerHTML=this.localize("Image")};var s=function(e,t,n){var i={className:"vjs-fullscreen-control vjs-control vjs-button",innerHTML:'<span aria-hidden="true" class="vjs-icon-'+n+'"></span><span class="vjs-control-text" aria-live="polite">'+t+"</span>"},a={title:t,type:"button","aria-disabled":"false"};return r.prototype.createEl("button",i,a)},u=function(e){var t={className:"vjs-"+e+"-canvas",innerHTML:"<canvas></canvas>"};return r.prototype.createEl("div",t)},l=function(e,t){e.addClass("vjs-snapshot")},c=function(n){var r=this,i=e.mergeOptions(t,n),c=this;c.ready(function(){l(r,e.mergeOptions(t,n))}),c.on("play",function(){try{c.tech_.el_.setAttribute("crossorigin","anonymous")}catch(e){}}),c.snapshoter=new e.SnapshoterComponent(this,{options:i}),c.addChild(c.snapshoter),c.snapshotCanvas=new o(c,{el:u("snapshot")}),c.snapshotCanvas.hide(),c.snapshoter.addChild(c.snapshotCanvas),c.cameraButton=new a(c,{el:s(0,c.localize("Snapshot"),"spinner")}),c.cameraButton.show()};return n("snapshot",c),c}),function(t,r){n.exports?n.exports=r(e):t.returnExports=r(t.videojs)}(t,function(e){var t=e.getComponent("Component");e.ImageCaptureEngine=e.extend(t,{constructor:function(e,n){t.call(this,e,n)},formatTag:function(e){if(e&&(e=e.trim(),0!==e.length))return e},getDomByIdAndTag:function(e,t){t=this.formatTag(t);var n=document.getElementById(e);if(t&&0!==t.trim().length)return n.tagName.toUpperCase()===t.toUpperCase()?n:n.getElementsByTagName(t)[0]},getScreenContainerDomByIdAndTag:function(e,t){return(t=this.formatTag(t))?this.getDomByIdAndTag(e,t):this.getDomByIdAndTag(e,"object")||this.getDomByIdAndTag(e,"video")},drawCanvas:function(e,t){e.width=t.videoWidth,e.height=t.videoHeight,e.getContext("2d").drawImage(t,0,0,e.width,e.height)},imageCaptureByDom:function(e,t){var n;return e&&e.tagName.toUpperCase()==="object".toUpperCase()?n=e.vjs_snap():(this.drawCanvas(t,e),n=t.toDataURL("image/png")),n},imageCaptureById:function(e,t){return this.imageCaptureByDom(this.getScreenContainerDomByIdAndTag(e),this.getDomByIdAndTag(t,"canvas"))},imageCaptureByIdAndCanvasDom:function(e,t){return this.imageCaptureByDom(this.getScreenContainerDomByIdAndTag(e),t)}})})}(r,r.exports),r.exports}()}),function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.flvjs=e()}}(function(){var e;return function(){function e(t,n,r){function i(o,s){if(!n[o]){if(!t[o]){var u="function"==typeof require&&require;if(!s&&u)return u(o,!0);if(a)return a(o,!0);var l=new Error("Cannot find module '"+o+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[o]={exports:{}};t[o][0].call(c.exports,function(e){return i(t[o][1][e]||e)},c,c.exports,e,t,n,r)}return n[o].exports}for(var a="function"==typeof require&&require,o=0;o<r.length;o++)i(r[o]);return i}return e}()({1:[function(t,n,r){(function(i,a){!function(t,i){"object"==typeof r&&void 0!==n?n.exports=i():"function"==typeof e&&e.amd?e(i):t.ES6Promise=i()}(this,function(){"use strict";function e(e){var t=typeof e;return null!==e&&("object"===t||"function"===t)}function n(e){return"function"==typeof e}function r(e){q=e}function o(e){G=e}function s(){return void 0!==V?function(){V(l)}:u()}function u(){var e=setTimeout;return function(){return e(l,1)}}function l(){for(var e=0;e<F;e+=2)(0,K[e])(K[e+1]),K[e]=void 0,K[e+1]=void 0;F=0}function c(e,t){var n=this,r=new this.constructor(f);void 0===r[J]&&j(r);var i=n._state;if(i){var a=arguments[i-1];G(function(){return C(i,r,a,n._result)})}else k(n,r,e,t);return r}function d(e){var t=this;if(e&&"object"==typeof e&&e.constructor===t)return e;var n=new t(f);return b(n,e),n}function f(){}function h(){return new TypeError("You cannot resolve a promise with itself")}function p(){return new TypeError("A promises callback cannot return that same promise.")}function m(e){try{return e.then}catch(e){return te.error=e,te}}function v(e,t,n,r){try{e.call(t,n,r)}catch(e){return e}}function g(e,t,n){G(function(e){var r=!1,i=v(n,t,function(n){r||(r=!0,t!==n?b(e,n):S(e,n))},function(t){r||(r=!0,w(e,t))},"Settle: "+(e._label||" unknown promise"));!r&&i&&(r=!0,w(e,i))},e)}function y(e,t){t._state===Z?S(e,t._result):t._state===ee?w(e,t._result):k(t,void 0,function(t){return b(e,t)},function(t){return w(e,t)})}function _(e,t,r){t.constructor===e.constructor&&r===c&&t.constructor.resolve===d?y(e,t):r===te?(w(e,te.error),te.error=null):void 0===r?S(e,t):n(r)?g(e,t,r):S(e,t)}function b(t,n){t===n?w(t,h()):e(n)?_(t,n,m(n)):S(t,n)}function T(e){e._onerror&&e._onerror(e._result),E(e)}function S(e,t){e._state===Q&&(e._result=t,e._state=Z,0!==e._subscribers.length&&G(E,e))}function w(e,t){e._state===Q&&(e._state=ee,e._result=t,G(T,e))}function k(e,t,n,r){var i=e._subscribers,a=i.length;e._onerror=null,i[a]=t,i[a+Z]=n,i[a+ee]=r,0===a&&e._state&&G(E,e)}function E(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var r=void 0,i=void 0,a=e._result,o=0;o<t.length;o+=3)r=t[o],i=t[o+n],r?C(n,r,i,a):i(a);e._subscribers.length=0}}function A(e,t){try{return e(t)}catch(e){return te.error=e,te}}function C(e,t,r,i){var a=n(r),o=void 0,s=void 0,u=void 0,l=void 0;if(a){if(o=A(r,i),o===te?(l=!0,s=o.error,o.error=null):u=!0,t===o)return void w(t,p())}else o=i,u=!0;t._state!==Q||(a&&u?b(t,o):l?w(t,s):e===Z?S(t,o):e===ee&&w(t,o))}function L(e,t){try{t(function(t){b(e,t)},function(t){w(e,t)})}catch(t){w(e,t)}}function x(){return ne++}function j(e){e[J]=ne++,e._state=void 0,e._result=void 0,e._subscribers=[]}function O(){return new Error("Array Methods must be provided an Array")}function I(e){return new re(this,e).promise}function P(e){var t=this;return new t(N(e)?function(n,r){for(var i=e.length,a=0;a<i;a++)t.resolve(e[a]).then(n,r)}:function(e,t){return t(new TypeError("You must pass an array to race."))})}function R(e){var t=this,n=new t(f);return w(n,e),n}function D(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function M(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}function U(){var e=void 0;if(void 0!==a)e=a;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;if(t){var n=null;try{n=Object.prototype.toString.call(t.resolve())}catch(e){}if("[object Promise]"===n&&!t.cast)return}e.Promise=ie}var B=void 0;B=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)};var N=B,F=0,V=void 0,q=void 0,G=function(e,t){K[F]=e,K[F+1]=t,2===(F+=2)&&(q?q(l):X())},H="undefined"!=typeof window?window:void 0,z=H||{},W=z.MutationObserver||z.WebKitMutationObserver,$="undefined"==typeof self&&void 0!==i&&"[object process]"==={}.toString.call(i),Y="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,K=new Array(1e3),X=void 0;X=$?function(){return function(){return i.nextTick(l)}}():W?function(){var e=0,t=new W(l),n=document.createTextNode("");return t.observe(n,{characterData:!0}),function(){n.data=e=++e%2}}():Y?function(){var e=new MessageChannel;return e.port1.onmessage=l,function(){return e.port2.postMessage(0)}}():void 0===H&&"function"==typeof t?function(){try{var e=Function("return this")().require("vertx");return V=e.runOnLoop||e.runOnContext,s()}catch(e){return u()}}():u();var J=Math.random().toString(36).substring(2),Q=void 0,Z=1,ee=2,te={error:null},ne=0,re=function(){function e(e,t){this._instanceConstructor=e,this.promise=new e(f),this.promise[J]||j(this.promise),N(t)?(this.length=t.length,this._remaining=t.length,this._result=new Array(this.length),0===this.length?S(this.promise,this._result):(this.length=this.length||0,this._enumerate(t),0===this._remaining&&S(this.promise,this._result))):w(this.promise,O())}return e.prototype._enumerate=function(e){for(var t=0;this._state===Q&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var n=this._instanceConstructor,r=n.resolve;if(r===d){var i=m(e);if(i===c&&e._state!==Q)this._settledAt(e._state,t,e._result);else if("function"!=typeof i)this._remaining--,this._result[t]=e;else if(n===ie){var a=new n(f);_(a,e,i),this._willSettleAt(a,t)}else this._willSettleAt(new n(function(t){return t(e)}),t)}else this._willSettleAt(r(e),t)},e.prototype._settledAt=function(e,t,n){var r=this.promise;r._state===Q&&(this._remaining--,e===ee?w(r,n):this._result[t]=n),0===this._remaining&&S(r,this._result)},e.prototype._willSettleAt=function(e,t){var n=this;k(e,void 0,function(e){return n._settledAt(Z,t,e)},function(e){return n._settledAt(ee,t,e)})},e}(),ie=function(){function e(t){this[J]=x(),this._result=this._state=void 0,this._subscribers=[],f!==t&&("function"!=typeof t&&D(),this instanceof e?L(this,t):M())}return e.prototype.catch=function(e){return this.then(null,e)},e.prototype.finally=function(e){var t=this,r=t.constructor;return n(e)?t.then(function(t){return r.resolve(e()).then(function(){return t})},function(t){return r.resolve(e()).then(function(){throw t})}):t.then(e,e)},e}();return ie.prototype.then=c,ie.all=I,ie.race=P,ie.resolve=d,ie.reject=R,ie._setScheduler=r,ie._setAsap=o,ie._asap=G,ie.polyfill=U,ie.Promise=ie,ie})}).call(this,t("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:3}],2:[function(e,t,n){function r(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function i(e){return"function"==typeof e}function a(e){return"number"==typeof e}function o(e){return"object"==typeof e&&null!==e}function s(e){return void 0===e}t.exports=r,r.EventEmitter=r,r.prototype._events=void 0,r.prototype._maxListeners=void 0,r.defaultMaxListeners=10,r.prototype.setMaxListeners=function(e){if(!a(e)||e<0||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},r.prototype.emit=function(e){var t,n,r,a,u,l;if(this._events||(this._events={}),"error"===e&&(!this._events.error||o(this._events.error)&&!this._events.error.length)){if((t=arguments[1])instanceof Error)throw t;var c=new Error('Uncaught, unspecified "error" event. ('+t+")");throw c.context=t,c}if(n=this._events[e],s(n))return!1;if(i(n))switch(arguments.length){case 1:n.call(this);break;case 2:n.call(this,arguments[1]);break;case 3:n.call(this,arguments[1],arguments[2]);break;default:a=Array.prototype.slice.call(arguments,1),n.apply(this,a)}else if(o(n))for(a=Array.prototype.slice.call(arguments,1),l=n.slice(),r=l.length,u=0;u<r;u++)l[u].apply(this,a);return!0},r.prototype.addListener=function(e,t){var n;if(!i(t))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",e,i(t.listener)?t.listener:t),this._events[e]?o(this._events[e])?this._events[e].push(t):this._events[e]=[this._events[e],t]:this._events[e]=t,o(this._events[e])&&!this._events[e].warned&&(n=s(this._maxListeners)?r.defaultMaxListeners:this._maxListeners)&&n>0&&this._events[e].length>n&&(this._events[e].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),"function"==typeof console.trace&&console.trace()),this},r.prototype.on=r.prototype.addListener,r.prototype.once=function(e,t){function n(){this.removeListener(e,n),r||(r=!0,t.apply(this,arguments))}if(!i(t))throw TypeError("listener must be a function");var r=!1;return n.listener=t,this.on(e,n),this},r.prototype.removeListener=function(e,t){var n,r,a,s;if(!i(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(n=this._events[e],a=n.length,r=-1,n===t||i(n.listener)&&n.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(o(n)){for(s=a;s-- >0;)if(n[s]===t||n[s].listener&&n[s].listener===t){r=s;break}if(r<0)return this;1===n.length?(n.length=0,delete this._events[e]):n.splice(r,1),this._events.removeListener&&this.emit("removeListener",e,t)}return this},r.prototype.removeAllListeners=function(e){var t,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[e]&&delete this._events[e],this;if(0===arguments.length){for(t in this._events)"removeListener"!==t&&this.removeAllListeners(t);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[e],i(n))this.removeListener(e,n);else if(n)for(;n.length;)this.removeListener(e,n[n.length-1]);return delete this._events[e],this},r.prototype.listeners=function(e){return this._events&&this._events[e]?i(this._events[e])?[this._events[e]]:this._events[e].slice():[]},r.prototype.listenerCount=function(e){if(this._events){var t=this._events[e];if(i(t))return 1;if(t)return t.length}return 0},r.listenerCount=function(e,t){return e.listenerCount(t)}},{}],3:[function(e,t,n){function r(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function a(e){if(d===setTimeout)return setTimeout(e,0);if((d===r||!d)&&setTimeout)return d=setTimeout,setTimeout(e,0);try{return d(e,0)}catch(t){try{return d.call(null,e,0)}catch(t){return d.call(this,e,0)}}}function o(e){if(f===clearTimeout)return clearTimeout(e);if((f===i||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function s(){v&&p&&(v=!1,p.length?m=p.concat(m):g=-1,m.length&&u())}function u(){if(!v){var e=a(s);v=!0;for(var t=m.length;t;){for(p=m,m=[];++g<t;)p&&p[g].run();g=-1,t=m.length}p=null,v=!1,o(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var d,f,h=t.exports={};!function(){try{d="function"==typeof setTimeout?setTimeout:r}catch(e){d=r}try{f="function"==typeof clearTimeout?clearTimeout:i}catch(e){f=i}}();var p,m=[],v=!1,g=-1;h.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];m.push(new l(e,t)),1!==m.length||v||a(u)},l.prototype.run=function(){this.fun.apply(null,this.array)},h.title="browser",h.browser=!0,h.env={},h.argv=[],h.version="",h.versions={},h.on=c,h.addListener=c,h.once=c,h.off=c,h.removeListener=c,h.removeAllListeners=c,h.emit=c,h.prependListener=c,h.prependOnceListener=c,h.listeners=function(e){return[]},h.binding=function(e){throw new Error("process.binding is not supported")},h.cwd=function(){return"/"},h.chdir=function(e){throw new Error("process.chdir is not supported")},h.umask=function(){return 0}},{}],4:[function(e,t,n){var r=arguments[3],i=arguments[4],a=arguments[5],o=JSON.stringify;t.exports=function(e,t){function n(e){v[e]=!0;for(var t in i[e][1]){var r=i[e][1][t];v[r]||n(r)}}for(var s,u=Object.keys(a),l=0,c=u.length;l<c;l++){var d=u[l],f=a[d].exports;if(f===e||f&&f.default===e){s=d;break}}if(!s){s=Math.floor(Math.pow(16,8)*Math.random()).toString(16);for(var h={},l=0,c=u.length;l<c;l++){var d=u[l];h[d]=d}i[s]=["function(require,module,exports){"+e+"(self); }",h]}var p=Math.floor(Math.pow(16,8)*Math.random()).toString(16),m={};m[s]=s,i[p]=["function(require,module,exports){var f = require("+o(s)+");(f.default ? f.default : f)(self);}",m];var v={};n(p);var g="("+r+")({"+Object.keys(v).map(function(e){return o(e)+":["+i[e][0]+","+o(i[e][1])+"]"}).join(",")+"},{},["+o(p)+"])",y=window.URL||window.webkitURL||window.mozURL||window.msURL,_=new Blob([g],{type:"text/javascript"});if(t&&t.bare)return _;var b=y.createObjectURL(_),T=new Worker(b);return T.objectURL=b,T}},{}],5:[function(e,t,n){"use strict";function r(){return Object.assign({},i)}Object.defineProperty(n,"__esModule",{value:!0}),n.createDefaultConfig=r;var i=n.defaultConfig={enableWorker:!1,enableStashBuffer:!0,stashInitialSize:void 0,isLive:!1,lazyLoad:!0,lazyLoadMaxDuration:180,lazyLoadRecoverDuration:30,deferLoadAfterSourceOpen:!0,autoCleanupMaxBackwardDuration:180,autoCleanupMinBackwardDuration:120,statisticsInfoReportInterval:600,fixAudioTimestampGap:!0,accurateSeek:!1,seekType:"range",seekParamStart:"bstart",seekParamEnd:"bend",rangeLoadZeroStart:!1,customSeekHandler:void 0,reuseRedirectedURL:!1,headers:void 0,customLoader:void 0}},{}],6:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=e("../io/io-controller.js"),o=function(e){return e&&e.__esModule?e:{default:e}}(a),s=e("../config.js"),u=function(){function e(){r(this,e)}return i(e,null,[{key:"supportMSEH264Playback",value:function(){return window.MediaSource&&window.MediaSource.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"')}},{key:"supportNetworkStreamIO",value:function(){var e=new o.default({},(0,s.createDefaultConfig)()),t=e.loaderType;return e.destroy(),"fetch-stream-loader"==t||"xhr-moz-chunked-loader"==t}},{key:"getNetworkLoaderTypeName",value:function(){var e=new o.default({},(0,s.createDefaultConfig)()),t=e.loaderType;return e.destroy(),t}},{key:"supportNativeMediaPlayback",value:function(t){void 0==e.videoElement&&(e.videoElement=window.document.createElement("video"));var n=e.videoElement.canPlayType(t);return"probably"===n||"maybe"==n}},{key:"getFeatureList",value:function(){var t={mseFlvPlayback:!1,mseLiveFlvPlayback:!1,networkStreamIO:!1,networkLoaderName:"",nativeMP4H264Playback:!1,nativeWebmVP8Playback:!1,nativeWebmVP9Playback:!1};return t.mseFlvPlayback=e.supportMSEH264Playback(),t.networkStreamIO=e.supportNetworkStreamIO(),t.networkLoaderName=e.getNetworkLoaderTypeName(),t.mseLiveFlvPlayback=t.mseFlvPlayback&&t.networkStreamIO,t.nativeMP4H264Playback=e.supportNativeMediaPlayback('video/mp4; codecs="avc1.42001E, mp4a.40.2"'),t.nativeWebmVP8Playback=e.supportNativeMediaPlayback('video/webm; codecs="vp8.0, vorbis"'),t.nativeWebmVP9Playback=e.supportNativeMediaPlayback('video/webm; codecs="vp9"'),t}}]),e}();n.default=u},{"../config.js":5,"../io/io-controller.js":23}],7:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this.mimeType=null,this.duration=null,this.hasAudio=null,this.hasVideo=null,this.audioCodec=null,this.videoCodec=null,this.audioDataRate=null,this.videoDataRate=null,this.audioSampleRate=null,this.audioChannelCount=null,this.width=null,this.height=null,this.fps=null,this.profile=null,this.level=null,this.refFrames=null,this.chromaFormat=null,this.sarNum=null,this.sarDen=null,this.metadata=null,this.segments=null,this.segmentCount=null,this.hasKeyframesIndex=null,this.keyframesIndex=null}return i(e,[{key:"isComplete",value:function(){var e=!1===this.hasAudio||!0===this.hasAudio&&null!=this.audioCodec&&null!=this.audioSampleRate&&null!=this.audioChannelCount,t=!1===this.hasVideo||!0===this.hasVideo&&null!=this.videoCodec&&null!=this.width&&null!=this.height&&null!=this.fps&&null!=this.profile&&null!=this.level&&null!=this.refFrames&&null!=this.chromaFormat&&null!=this.sarNum&&null!=this.sarDen;return null!=this.mimeType&&null!=this.duration&&null!=this.metadata&&null!=this.hasKeyframesIndex&&e&&t}},{key:"isSeekable",value:function(){return!0===this.hasKeyframesIndex}},{key:"getNearestKeyframe",value:function(e){if(null==this.keyframesIndex)return null;var t=this.keyframesIndex,n=this._search(t.times,e);return{index:n,milliseconds:t.times[n],fileposition:t.filepositions[n]}}},{key:"_search",value:function(e,t){var n=0,r=e.length-1,i=0,a=0,o=r;for(t<e[0]&&(n=0,a=o+1);a<=o;){if((i=a+Math.floor((o-a)/2))===r||t>=e[i]&&t<e[i+1]){n=i;break}e[i]<t?a=i+1:o=i-1}return n}}]),e}();n.default=a},{}],8:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();n.SampleInfo=function e(t,n,i,a,o){r(this,e),this.dts=t,this.pts=n,this.duration=i,this.originalDts=a,this.isSyncPoint=o,this.fileposition=null},n.MediaSegmentInfo=function(){function e(){r(this,e),this.beginDts=0,this.endDts=0,this.beginPts=0,this.endPts=0,this.originalBeginDts=0,this.originalEndDts=0,this.syncPoints=[],this.firstSample=null,this.lastSample=null}return i(e,[{key:"appendSyncPoint",value:function(e){e.isSyncPoint=!0,this.syncPoints.push(e)}}]),e}(),n.IDRSampleList=function(){function e(){r(this,e),this._list=[]}return i(e,[{key:"clear",value:function(){this._list=[]}},{key:"appendArray",value:function(e){var t=this._list;0!==e.length&&(t.length>0&&e[0].originalDts<t[t.length-1].originalDts&&this.clear(),Array.prototype.push.apply(t,e))}},{key:"getLastSyncPointBeforeDts",value:function(e){if(0==this._list.length)return null;var t=this._list,n=0,r=t.length-1,i=0,a=0,o=r;for(e<t[0].dts&&(n=0,a=o+1);a<=o;){if((i=a+Math.floor((o-a)/2))===r||e>=t[i].dts&&e<t[i+1].dts){n=i;break}t[i].dts<e?a=i+1:o=i-1}return this._list[n]}}]),e}(),n.MediaSegmentInfoList=function(){function e(t){r(this,e),this._type=t,this._list=[],this._lastAppendLocation=-1}return i(e,[{key:"isEmpty",value:function(){return 0===this._list.length}},{key:"clear",value:function(){this._list=[],this._lastAppendLocation=-1}},{key:"_searchNearestSegmentBefore",value:function(e){var t=this._list;if(0===t.length)return-2;var n=t.length-1,r=0,i=0,a=n,o=0;if(e<t[0].originalBeginDts)return o=-1;for(;i<=a;){if((r=i+Math.floor((a-i)/2))===n||e>t[r].lastSample.originalDts&&e<t[r+1].originalBeginDts){o=r;break}t[r].originalBeginDts<e?i=r+1:a=r-1}return o}},{key:"_searchNearestSegmentAfter",value:function(e){return this._searchNearestSegmentBefore(e)+1}},{key:"append",value:function(e){var t=this._list,n=e,r=this._lastAppendLocation,i=0;-1!==r&&r<t.length&&n.originalBeginDts>=t[r].lastSample.originalDts&&(r===t.length-1||r<t.length-1&&n.originalBeginDts<t[r+1].originalBeginDts)?i=r+1:t.length>0&&(i=this._searchNearestSegmentBefore(n.originalBeginDts)+1),this._lastAppendLocation=i,this._list.splice(i,0,n)}},{key:"getLastSegmentBefore",value:function(e){var t=this._searchNearestSegmentBefore(e);return t>=0?this._list[t]:null}},{key:"getLastSampleBefore",value:function(e){var t=this.getLastSegmentBefore(e);return null!=t?t.lastSample:null}},{key:"getLastSyncPointBefore",value:function(e){for(var t=this._searchNearestSegmentBefore(e),n=this._list[t].syncPoints;0===n.length&&t>0;)t--,n=this._list[t].syncPoints;return n.length>0?n[n.length-1]:null}},{key:"type",get:function(){return this._type}},{key:"length",get:function(){return this._list.length}}]),e}()},{}],9:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("events"),s=r(o),u=e("../utils/logger.js"),l=r(u),c=e("../utils/browser.js"),d=r(c),f=e("./mse-events.js"),h=r(f),p=e("./media-segment-info.js"),m=e("../utils/exception.js"),v=function(){function e(t){i(this,e),this.TAG="MSEController",this._config=t,this._emitter=new s.default,this._config.isLive&&void 0==this._config.autoCleanupSourceBuffer&&(this._config.autoCleanupSourceBuffer=!0),this.e={onSourceOpen:this._onSourceOpen.bind(this),onSourceEnded:this._onSourceEnded.bind(this),onSourceClose:this._onSourceClose.bind(this),onSourceBufferError:this._onSourceBufferError.bind(this),onSourceBufferUpdateEnd:this._onSourceBufferUpdateEnd.bind(this)},this._mediaSource=null,this._mediaSourceObjectURL=null,this._mediaElement=null,this._isBufferFull=!1,this._hasPendingEos=!1,this._requireSetMediaDuration=!1,this._pendingMediaDuration=0,this._pendingSourceBufferInit=[],this._mimeTypes={video:null,audio:null},this._sourceBuffers={video:null,audio:null},this._lastInitSegments={video:null,audio:null},this._pendingSegments={video:[],audio:[]},this._pendingRemoveRanges={video:[],audio:[]},this._idrList=new p.IDRSampleList}return a(e,[{key:"destroy",value:function(){(this._mediaElement||this._mediaSource)&&this.detachMediaElement(),this.e=null,this._emitter.removeAllListeners(),this._emitter=null}},{key:"on",value:function(e,t){this._emitter.addListener(e,t)}},{key:"off",value:function(e,t){this._emitter.removeListener(e,t)}},{key:"attachMediaElement",value:function(e){if(this._mediaSource)throw new m.IllegalStateException("MediaSource has been attached to an HTMLMediaElement!");var t=this._mediaSource=new window.MediaSource;t.addEventListener("sourceopen",this.e.onSourceOpen),t.addEventListener("sourceended",this.e.onSourceEnded),t.addEventListener("sourceclose",this.e.onSourceClose),this._mediaElement=e,this._mediaSourceObjectURL=window.URL.createObjectURL(this._mediaSource),e.src=this._mediaSourceObjectURL}},{key:"detachMediaElement",value:function(){if(this._mediaSource){var e=this._mediaSource;for(var t in this._sourceBuffers){var n=this._pendingSegments[t];n.splice(0,n.length),this._pendingSegments[t]=null,this._pendingRemoveRanges[t]=null,this._lastInitSegments[t]=null;var r=this._sourceBuffers[t];if(r){if("closed"!==e.readyState){try{e.removeSourceBuffer(r)}catch(e){l.default.e(this.TAG,e.message)}r.removeEventListener("error",this.e.onSourceBufferError),r.removeEventListener("updateend",this.e.onSourceBufferUpdateEnd)}this._mimeTypes[t]=null,this._sourceBuffers[t]=null}}if("open"===e.readyState)try{e.endOfStream()}catch(e){l.default.e(this.TAG,e.message)}e.removeEventListener("sourceopen",this.e.onSourceOpen),e.removeEventListener("sourceended",this.e.onSourceEnded),e.removeEventListener("sourceclose",this.e.onSourceClose),this._pendingSourceBufferInit=[],this._isBufferFull=!1,this._idrList.clear(),this._mediaSource=null}this._mediaElement&&(this._mediaElement.src="",this._mediaElement.removeAttribute("src"),this._mediaElement=null),this._mediaSourceObjectURL&&(window.URL.revokeObjectURL(this._mediaSourceObjectURL),this._mediaSourceObjectURL=null)}},{key:"appendInitSegment",value:function(e,t){if(!this._mediaSource||"open"!==this._mediaSource.readyState)return this._pendingSourceBufferInit.push(e),void this._pendingSegments[e.type].push(e);var n=e,r=""+n.container;n.codec&&n.codec.length>0&&(r+=";codecs="+n.codec);var i=!1;if(l.default.v(this.TAG,"Received Initialization Segment, mimeType: "+r),this._lastInitSegments[n.type]=n,r!==this._mimeTypes[n.type]){if(this._mimeTypes[n.type])l.default.v(this.TAG,"Notice: "+n.type+" mimeType changed, origin: "+this._mimeTypes[n.type]+", target: "+r);else{i=!0;try{var a=this._sourceBuffers[n.type]=this._mediaSource.addSourceBuffer(r);a.addEventListener("error",this.e.onSourceBufferError),a.addEventListener("updateend",this.e.onSourceBufferUpdateEnd)}catch(e){return l.default.e(this.TAG,e.message),void this._emitter.emit(h.default.ERROR,{code:e.code,msg:e.message})}}this._mimeTypes[n.type]=r}t||this._pendingSegments[n.type].push(n),i||this._sourceBuffers[n.type]&&!this._sourceBuffers[n.type].updating&&this._doAppendSegments(),d.default.safari&&"audio/mpeg"===n.container&&n.mediaDuration>0&&(this._requireSetMediaDuration=!0,this._pendingMediaDuration=n.mediaDuration/1e3,this._updateMediaSourceDuration())}},{key:"appendMediaSegment",value:function(e){var t=e;this._pendingSegments[t.type].push(t),this._config.autoCleanupSourceBuffer&&this._needCleanupSourceBuffer()&&this._doCleanupSourceBuffer();var n=this._sourceBuffers[t.type];!n||n.updating||this._hasPendingRemoveRanges()||this._doAppendSegments()}},{key:"seek",value:function(e){for(var t in this._sourceBuffers)if(this._sourceBuffers[t]){var n=this._sourceBuffers[t];if("open"===this._mediaSource.readyState)try{n.abort()}catch(e){l.default.e(this.TAG,e.message)}this._idrList.clear();var r=this._pendingSegments[t];if(r.splice(0,r.length),"closed"!==this._mediaSource.readyState){for(var i=0;i<n.buffered.length;i++){var a=n.buffered.start(i),o=n.buffered.end(i);this._pendingRemoveRanges[t].push({start:a,end:o})}if(n.updating||this._doRemoveRanges(),d.default.safari){var s=this._lastInitSegments[t];s&&(this._pendingSegments[t].push(s),n.updating||this._doAppendSegments())}}}}},{key:"endOfStream",value:function(){var e=this._mediaSource,t=this._sourceBuffers;if(!e||"open"!==e.readyState)return void(e&&"closed"===e.readyState&&this._hasPendingSegments()&&(this._hasPendingEos=!0));t.video&&t.video.updating||t.audio&&t.audio.updating?this._hasPendingEos=!0:(this._hasPendingEos=!1,e.endOfStream())}},{key:"getNearestKeyframe",value:function(e){return this._idrList.getLastSyncPointBeforeDts(e)}},{key:"_needCleanupSourceBuffer",value:function(){if(!this._config.autoCleanupSourceBuffer)return!1;var e=this._mediaElement.currentTime;for(var t in this._sourceBuffers){var n=this._sourceBuffers[t];if(n){var r=n.buffered;if(r.length>=1&&e-r.start(0)>=this._config.autoCleanupMaxBackwardDuration)return!0}}return!1}},{key:"_doCleanupSourceBuffer",value:function(){var e=this._mediaElement.currentTime;for(var t in this._sourceBuffers){var n=this._sourceBuffers[t];if(n){for(var r=n.buffered,i=!1,a=0;a<r.length;a++){var o=r.start(a),s=r.end(a);if(o<=e&&e<s+3){if(e-o>=this._config.autoCleanupMaxBackwardDuration){i=!0;var u=e-this._config.autoCleanupMinBackwardDuration;this._pendingRemoveRanges[t].push({start:o,end:u})}}else s<e&&(i=!0,this._pendingRemoveRanges[t].push({start:o,end:s}))}i&&!n.updating&&this._doRemoveRanges()}}}},{key:"_updateMediaSourceDuration",value:function(){var e=this._sourceBuffers;if(0!==this._mediaElement.readyState&&"open"===this._mediaSource.readyState&&!(e.video&&e.video.updating||e.audio&&e.audio.updating)){var t=this._mediaSource.duration,n=this._pendingMediaDuration;n>0&&(isNaN(t)||n>t)&&(l.default.v(this.TAG,"Update MediaSource duration from "+t+" to "+n),this._mediaSource.duration=n),this._requireSetMediaDuration=!1,this._pendingMediaDuration=0}}},{key:"_doRemoveRanges",value:function(){for(var e in this._pendingRemoveRanges)if(this._sourceBuffers[e]&&!this._sourceBuffers[e].updating)for(var t=this._sourceBuffers[e],n=this._pendingRemoveRanges[e];n.length&&!t.updating;){var r=n.shift();t.remove(r.start,r.end)}}},{key:"_doAppendSegments",value:function(){var e=this._pendingSegments;for(var t in e)if(this._sourceBuffers[t]&&!this._sourceBuffers[t].updating&&e[t].length>0){var n=e[t].shift();if(n.timestampOffset){var r=this._sourceBuffers[t].timestampOffset,i=n.timestampOffset/1e3,a=Math.abs(r-i);a>.1&&(l.default.v(this.TAG,"Update MPEG audio timestampOffset from "+r+" to "+i),this._sourceBuffers[t].timestampOffset=i),delete n.timestampOffset}if(!n.data||0===n.data.byteLength)continue;try{this._sourceBuffers[t].appendBuffer(n.data),this._isBufferFull=!1,"video"===t&&n.hasOwnProperty("info")&&this._idrList.appendArray(n.info.syncPoints)}catch(e){this._pendingSegments[t].unshift(n),22===e.code?(this._isBufferFull||this._emitter.emit(h.default.BUFFER_FULL),this._isBufferFull=!0):(l.default.e(this.TAG,e.message),this._emitter.emit(h.default.ERROR,{code:e.code,msg:e.message}))}}}},{key:"_onSourceOpen",value:function(){if(l.default.v(this.TAG,"MediaSource onSourceOpen"),this._mediaSource.removeEventListener("sourceopen",this.e.onSourceOpen),this._pendingSourceBufferInit.length>0)for(var e=this._pendingSourceBufferInit;e.length;){var t=e.shift();this.appendInitSegment(t,!0)}this._hasPendingSegments()&&this._doAppendSegments(),this._emitter.emit(h.default.SOURCE_OPEN)}},{key:"_onSourceEnded",value:function(){l.default.v(this.TAG,"MediaSource onSourceEnded")}},{key:"_onSourceClose",value:function(){l.default.v(this.TAG,"MediaSource onSourceClose"),this._mediaSource&&null!=this.e&&(this._mediaSource.removeEventListener("sourceopen",this.e.onSourceOpen),this._mediaSource.removeEventListener("sourceended",this.e.onSourceEnded),this._mediaSource.removeEventListener("sourceclose",this.e.onSourceClose))}},{key:"_hasPendingSegments",value:function(){var e=this._pendingSegments;return e.video.length>0||e.audio.length>0}},{key:"_hasPendingRemoveRanges",value:function(){var e=this._pendingRemoveRanges;return e.video.length>0||e.audio.length>0}},{key:"_onSourceBufferUpdateEnd",value:function(){this._requireSetMediaDuration?this._updateMediaSourceDuration():this._hasPendingRemoveRanges()?this._doRemoveRanges():this._hasPendingSegments()?this._doAppendSegments():this._hasPendingEos&&this.endOfStream(),this._emitter.emit(h.default.UPDATE_END)}},{key:"_onSourceBufferError",value:function(e){l.default.e(this.TAG,"SourceBuffer Error: "+e)}}]),e}();n.default=v},{"../utils/browser.js":39,"../utils/exception.js":40,"../utils/logger.js":41,"./media-segment-info.js":8,"./mse-events.js":10,events:2}],10:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={ERROR:"error",SOURCE_OPEN:"source_open",UPDATE_END:"update_end",BUFFER_FULL:"buffer_full"};n.default=r},{}],11:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("events"),s=r(o),u=e("../utils/logger.js"),l=r(u),c=e("../utils/logging-control.js"),d=r(c),f=e("./transmuxing-controller.js"),h=r(f),p=e("./transmuxing-events.js"),m=r(p),v=e("./transmuxing-worker.js"),g=r(v),y=e("./media-info.js"),_=r(y),b=function(){function t(n,r){if(i(this,t),this.TAG="Transmuxer",this._emitter=new s.default,r.enableWorker&&"undefined"!=typeof Worker)try{var a=e("webworkify");this._worker=a(g.default),this._workerDestroying=!1,this._worker.addEventListener("message",this._onWorkerMessage.bind(this)),this._worker.postMessage({cmd:"init",param:[n,r]}),this.e={onLoggingConfigChanged:this._onLoggingConfigChanged.bind(this)},d.default.registerListener(this.e.onLoggingConfigChanged),this._worker.postMessage({cmd:"logging_config",param:d.default.getConfig()})}catch(e){l.default.e(this.TAG,"Error while initialize transmuxing worker, fallback to inline transmuxing"),this._worker=null,this._controller=new h.default(n,r)}else this._controller=new h.default(n,r);if(this._controller){var o=this._controller;o.on(m.default.IO_ERROR,this._onIOError.bind(this)),o.on(m.default.DEMUX_ERROR,this._onDemuxError.bind(this)),o.on(m.default.INIT_SEGMENT,this._onInitSegment.bind(this)),o.on(m.default.MEDIA_SEGMENT,this._onMediaSegment.bind(this)),o.on(m.default.LOADING_COMPLETE,this._onLoadingComplete.bind(this)),o.on(m.default.RECOVERED_EARLY_EOF,this._onRecoveredEarlyEof.bind(this)),o.on(m.default.MEDIA_INFO,this._onMediaInfo.bind(this)),o.on(m.default.METADATA_ARRIVED,this._onMetaDataArrived.bind(this)),o.on(m.default.SCRIPTDATA_ARRIVED,this._onScriptDataArrived.bind(this)),o.on(m.default.STATISTICS_INFO,this._onStatisticsInfo.bind(this)),o.on(m.default.RECOMMEND_SEEKPOINT,this._onRecommendSeekpoint.bind(this))}}return a(t,[{key:"destroy",value:function(){this._worker?this._workerDestroying||(this._workerDestroying=!0,this._worker.postMessage({cmd:"destroy"}),d.default.removeListener(this.e.onLoggingConfigChanged),this.e=null):(this._controller.destroy(),this._controller=null),this._emitter.removeAllListeners(),this._emitter=null}},{key:"on",value:function(e,t){this._emitter.addListener(e,t)}},{key:"off",value:function(e,t){this._emitter.removeListener(e,t)}},{key:"hasWorker",value:function(){return null!=this._worker}},{key:"open",value:function(){this._worker?this._worker.postMessage({cmd:"start"}):this._controller.start()}},{key:"close",value:function(){this._worker?this._worker.postMessage({cmd:"stop"}):this._controller.stop()}},{key:"seek",value:function(e){this._worker?this._worker.postMessage({cmd:"seek",param:e}):this._controller.seek(e)}},{key:"pause",value:function(){this._worker?this._worker.postMessage({cmd:"pause"}):this._controller.pause()}},{key:"resume",value:function(){this._worker?this._worker.postMessage({cmd:"resume"}):this._controller.resume()}},{key:"_onInitSegment",value:function(e,t){var n=this;Promise.resolve().then(function(){n._emitter.emit(m.default.INIT_SEGMENT,e,t)}).catch(function(){})}},{key:"_onMediaSegment",value:function(e,t){var n=this;Promise.resolve().then(function(){n._emitter.emit(m.default.MEDIA_SEGMENT,e,t)}).catch(function(){})}},{key:"_onLoadingComplete",value:function(){var e=this;Promise.resolve().then(function(){e._emitter.emit(m.default.LOADING_COMPLETE)}).catch(function(){})}},{key:"_onRecoveredEarlyEof",value:function(){var e=this;Promise.resolve().then(function(){e._emitter.emit(m.default.RECOVERED_EARLY_EOF)}).catch(function(){})}},{key:"_onMediaInfo",value:function(e){var t=this;Promise.resolve().then(function(){t._emitter.emit(m.default.MEDIA_INFO,e)}).catch(function(){})}},{key:"_onMetaDataArrived",value:function(e){var t=this;Promise.resolve().then(function(){t._emitter.emit(m.default.METADATA_ARRIVED,e)}).catch(function(){})}},{key:"_onScriptDataArrived",value:function(e){var t=this;Promise.resolve().then(function(){t._emitter.emit(m.default.SCRIPTDATA_ARRIVED,e)}).catch(function(){})}},{key:"_onStatisticsInfo",value:function(e){var t=this;Promise.resolve().then(function(){t._emitter.emit(m.default.STATISTICS_INFO,e)}).catch(function(){})}},{key:"_onIOError",value:function(e,t){var n=this;Promise.resolve().then(function(){n._emitter.emit(m.default.IO_ERROR,e,t)}).catch(function(){})}},{key:"_onDemuxError",value:function(e,t){var n=this;Promise.resolve().then(function(){n._emitter.emit(m.default.DEMUX_ERROR,e,t)}).catch(function(){})}},{key:"_onRecommendSeekpoint",value:function(e){var t=this;Promise.resolve().then(function(){t._emitter.emit(m.default.RECOMMEND_SEEKPOINT,e)}).catch(function(){})}},{key:"_onLoggingConfigChanged",value:function(e){this._worker&&this._worker.postMessage({cmd:"logging_config",param:e})}},{key:"_onWorkerMessage",value:function(e){var t=e.data,n=t.data;if("destroyed"===t.msg||this._workerDestroying)return this._workerDestroying=!1,this._worker.terminate(),void(this._worker=null);switch(t.msg){case m.default.INIT_SEGMENT:case m.default.MEDIA_SEGMENT:this._emitter.emit(t.msg,n.type,n.data);break;case m.default.LOADING_COMPLETE:case m.default.RECOVERED_EARLY_EOF:this._emitter.emit(t.msg);break;case m.default.MEDIA_INFO:Object.setPrototypeOf(n,_.default.prototype),this._emitter.emit(t.msg,n);break;case m.default.METADATA_ARRIVED:case m.default.SCRIPTDATA_ARRIVED:case m.default.STATISTICS_INFO:this._emitter.emit(t.msg,n);break;case m.default.IO_ERROR:case m.default.DEMUX_ERROR:this._emitter.emit(t.msg,n.type,n.info);break;case m.default.RECOMMEND_SEEKPOINT:this._emitter.emit(t.msg,n);break;case"logcat_callback":l.default.emitter.emit("log",n.type,n.logcat)}}}]),t}();n.default=b},{"../utils/logger.js":41,"../utils/logging-control.js":42,"./media-info.js":7,"./transmuxing-controller.js":12,"./transmuxing-events.js":13,"./transmuxing-worker.js":14,events:2,webworkify:4}],12:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("events"),s=r(o),u=e("../utils/logger.js"),l=r(u),c=e("../utils/browser.js"),d=r(c),f=e("./media-info.js"),h=r(f),p=e("../demux/flv-demuxer.js"),m=r(p),v=e("../remux/mp4-remuxer.js"),g=r(v),y=e("../demux/demux-errors.js"),_=r(y),b=e("../io/io-controller.js"),T=r(b),S=e("./transmuxing-events.js"),w=r(S),k=(e("../io/loader.js"),function(){function e(t,n){i(this,e),this.TAG="TransmuxingController",this._emitter=new s.default,this._config=n,t.segments||(t.segments=[{duration:t.duration,filesize:t.filesize,url:t.url}]),"boolean"!=typeof t.cors&&(t.cors=!0),"boolean"!=typeof t.withCredentials&&(t.withCredentials=!1),this._mediaDataSource=t,this._currentSegmentIndex=0;var r=0;this._mediaDataSource.segments.forEach(function(e){e.timestampBase=r,r+=e.duration,e.cors=t.cors,e.withCredentials=t.withCredentials,n.referrerPolicy&&(e.referrerPolicy=n.referrerPolicy)}),isNaN(r)||this._mediaDataSource.duration===r||(this._mediaDataSource.duration=r),this._mediaInfo=null,this._demuxer=null,this._remuxer=null,this._ioctl=null,this._pendingSeekTime=null,this._pendingResolveSeekPoint=null,this._statisticsReporter=null}return a(e,[{key:"destroy",value:function(){this._mediaInfo=null,this._mediaDataSource=null,this._statisticsReporter&&this._disableStatisticsReporter(),this._ioctl&&(this._ioctl.destroy(),this._ioctl=null),this._demuxer&&(this._demuxer.destroy(),this._demuxer=null),this._remuxer&&(this._remuxer.destroy(),this._remuxer=null),this._emitter.removeAllListeners(),this._emitter=null}},{key:"on",value:function(e,t){this._emitter.addListener(e,t)}},{key:"off",value:function(e,t){this._emitter.removeListener(e,t)}},{key:"start",value:function(){this._loadSegment(0),this._enableStatisticsReporter()}},{key:"_loadSegment",value:function(e,t){this._currentSegmentIndex=e;var n=this._mediaDataSource.segments[e],r=this._ioctl=new T.default(n,this._config,e);r.onError=this._onIOException.bind(this),r.onSeeked=this._onIOSeeked.bind(this),r.onComplete=this._onIOComplete.bind(this),r.onRedirect=this._onIORedirect.bind(this),r.onRecoveredEarlyEof=this._onIORecoveredEarlyEof.bind(this),t?this._demuxer.bindDataSource(this._ioctl):r.onDataArrival=this._onInitChunkArrival.bind(this),r.open(t)}},{key:"stop",value:function(){this._internalAbort(),this._disableStatisticsReporter()}},{key:"_internalAbort",value:function(){this._ioctl&&(this._ioctl.destroy(),this._ioctl=null)}},{key:"pause",value:function(){this._ioctl&&this._ioctl.isWorking()&&(this._ioctl.pause(),this._disableStatisticsReporter())}},{key:"resume",value:function(){this._ioctl&&this._ioctl.isPaused()&&(this._ioctl.resume(),this._enableStatisticsReporter())}},{key:"seek",value:function(e){if(null!=this._mediaInfo&&this._mediaInfo.isSeekable()){var t=this._searchSegmentIndexContains(e);if(t===this._currentSegmentIndex){var n=this._mediaInfo.segments[t];if(void 0==n)this._pendingSeekTime=e;else{var r=n.getNearestKeyframe(e);this._remuxer.seek(r.milliseconds),this._ioctl.seek(r.fileposition),this._pendingResolveSeekPoint=r.milliseconds}}else{var i=this._mediaInfo.segments[t];if(void 0==i)this._pendingSeekTime=e,this._internalAbort(),this._remuxer.seek(),this._remuxer.insertDiscontinuity(),this._loadSegment(t);else{var a=i.getNearestKeyframe(e);this._internalAbort(),this._remuxer.seek(e),this._remuxer.insertDiscontinuity(),this._demuxer.resetMediaInfo(),this._demuxer.timestampBase=this._mediaDataSource.segments[t].timestampBase,this._loadSegment(t,a.fileposition),this._pendingResolveSeekPoint=a.milliseconds,this._reportSegmentMediaInfo(t)}}this._enableStatisticsReporter()}}},{key:"_searchSegmentIndexContains",value:function(e){for(var t=this._mediaDataSource.segments,n=t.length-1,r=0;r<t.length;r++)if(e<t[r].timestampBase){n=r-1;break}return n}},{key:"_onInitChunkArrival",value:function(e,t){var n=this,r=null,i=0;if(t>0)this._demuxer.bindDataSource(this._ioctl),this._demuxer.timestampBase=this._mediaDataSource.segments[this._currentSegmentIndex].timestampBase,i=this._demuxer.parseChunks(e,t);else if((r=m.default.probe(e)).match){this._demuxer=new m.default(r,this._config),this._remuxer||(this._remuxer=new g.default(this._config));var a=this._mediaDataSource;void 0==a.duration||isNaN(a.duration)||(this._demuxer.overridedDuration=a.duration),"boolean"==typeof a.hasAudio&&(this._demuxer.overridedHasAudio=a.hasAudio),"boolean"==typeof a.hasVideo&&(this._demuxer.overridedHasVideo=a.hasVideo),this._demuxer.timestampBase=a.segments[this._currentSegmentIndex].timestampBase,this._demuxer.onError=this._onDemuxException.bind(this),this._demuxer.onMediaInfo=this._onMediaInfo.bind(this),this._demuxer.onMetaDataArrived=this._onMetaDataArrived.bind(this),this._demuxer.onScriptDataArrived=this._onScriptDataArrived.bind(this),this._remuxer.bindDataSource(this._demuxer.bindDataSource(this._ioctl)),this._remuxer.onInitSegment=this._onRemuxerInitSegmentArrival.bind(this),this._remuxer.onMediaSegment=this._onRemuxerMediaSegmentArrival.bind(this),i=this._demuxer.parseChunks(e,t)}else r=null,l.default.e(this.TAG,"Non-FLV, Unsupported media type!"),Promise.resolve().then(function(){n._internalAbort()}),this._emitter.emit(w.default.DEMUX_ERROR,_.default.FORMAT_UNSUPPORTED,"Non-FLV, Unsupported media type"),i=0;return i}},{key:"_onMediaInfo",value:function(e){var t=this;null==this._mediaInfo&&(this._mediaInfo=Object.assign({},e),this._mediaInfo.keyframesIndex=null,this._mediaInfo.segments=[],this._mediaInfo.segmentCount=this._mediaDataSource.segments.length,Object.setPrototypeOf(this._mediaInfo,h.default.prototype));var n=Object.assign({},e);Object.setPrototypeOf(n,h.default.prototype),this._mediaInfo.segments[this._currentSegmentIndex]=n,this._reportSegmentMediaInfo(this._currentSegmentIndex),null!=this._pendingSeekTime&&Promise.resolve().then(function(){var e=t._pendingSeekTime;t._pendingSeekTime=null,t.seek(e)})}},{key:"_onMetaDataArrived",value:function(e){this._emitter.emit(w.default.METADATA_ARRIVED,e)}},{key:"_onScriptDataArrived",value:function(e){this._emitter.emit(w.default.SCRIPTDATA_ARRIVED,e)}},{key:"_onIOSeeked",value:function(){this._remuxer.insertDiscontinuity()}},{key:"_onIOComplete",value:function(e){var t=e,n=t+1;n<this._mediaDataSource.segments.length?(this._internalAbort(),this._remuxer&&this._remuxer.flushStashedSamples(),this._loadSegment(n)):(this._remuxer&&this._remuxer.flushStashedSamples(),this._emitter.emit(w.default.LOADING_COMPLETE),this._disableStatisticsReporter())}},{key:"_onIORedirect",value:function(e){var t=this._ioctl.extraData;this._mediaDataSource.segments[t].redirectedURL=e}},{key:"_onIORecoveredEarlyEof",value:function(){this._emitter.emit(w.default.RECOVERED_EARLY_EOF)}},{key:"_onIOException",value:function(e,t){l.default.e(this.TAG,"IOException: type = "+e+", code = "+t.code+", msg = "+t.msg),this._emitter.emit(w.default.IO_ERROR,e,t),this._disableStatisticsReporter()}},{key:"_onDemuxException",value:function(e,t){l.default.e(this.TAG,"DemuxException: type = "+e+", info = "+t),this._emitter.emit(w.default.DEMUX_ERROR,e,t)}},{key:"_onRemuxerInitSegmentArrival",value:function(e,t){this._emitter.emit(w.default.INIT_SEGMENT,e,t)}},{key:"_onRemuxerMediaSegmentArrival",value:function(e,t){if(null==this._pendingSeekTime&&(this._emitter.emit(w.default.MEDIA_SEGMENT,e,t),null!=this._pendingResolveSeekPoint&&"video"===e)){var n=t.info.syncPoints,r=this._pendingResolveSeekPoint;this._pendingResolveSeekPoint=null,d.default.safari&&n.length>0&&n[0].originalDts===r&&(r=n[0].pts),this._emitter.emit(w.default.RECOMMEND_SEEKPOINT,r)}}},{key:"_enableStatisticsReporter",value:function(){null==this._statisticsReporter&&(this._statisticsReporter=self.setInterval(this._reportStatisticsInfo.bind(this),this._config.statisticsInfoReportInterval))}},{key:"_disableStatisticsReporter",value:function(){this._statisticsReporter&&(self.clearInterval(this._statisticsReporter),this._statisticsReporter=null)}},{key:"_reportSegmentMediaInfo",value:function(e){var t=this._mediaInfo.segments[e],n=Object.assign({},t);n.duration=this._mediaInfo.duration,n.segmentCount=this._mediaInfo.segmentCount,delete n.segments,delete n.keyframesIndex,this._emitter.emit(w.default.MEDIA_INFO,n)}},{key:"_reportStatisticsInfo",value:function(){var e={};e.url=this._ioctl.currentURL,e.hasRedirect=this._ioctl.hasRedirect,e.hasRedirect&&(e.redirectedURL=this._ioctl.currentRedirectedURL),e.speed=this._ioctl.currentSpeed,e.loaderType=this._ioctl.loaderType,e.currentSegmentIndex=this._currentSegmentIndex,e.totalSegmentCount=this._mediaDataSource.segments.length,this._emitter.emit(w.default.STATISTICS_INFO,e)}}]),e}());n.default=k},{"../demux/demux-errors.js":16,"../demux/flv-demuxer.js":18,"../io/io-controller.js":23,"../io/loader.js":24,"../remux/mp4-remuxer.js":38,"../utils/browser.js":39,"../utils/logger.js":41,"./media-info.js":7,"./transmuxing-events.js":13,events:2}],13:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={IO_ERROR:"io_error",DEMUX_ERROR:"demux_error",INIT_SEGMENT:"init_segment",MEDIA_SEGMENT:"media_segment",LOADING_COMPLETE:"loading_complete",RECOVERED_EARLY_EOF:"recovered_early_eof",MEDIA_INFO:"media_info",METADATA_ARRIVED:"metadata_arrived",SCRIPTDATA_ARRIVED:"scriptdata_arrived",STATISTICS_INFO:"statistics_info",RECOMMEND_SEEKPOINT:"recommend_seekpoint"};n.default=r},{}],14:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("../utils/logger.js"),a=(r(i),e("../utils/logging-control.js")),o=r(a),s=e("../utils/polyfill.js"),u=r(s),l=e("./transmuxing-controller.js"),c=r(l),d=e("./transmuxing-events.js"),f=r(d),h=function(e){function t(t,n){var r={msg:f.default.INIT_SEGMENT,data:{type:t,data:n}};e.postMessage(r,[n.data])}function n(t,n){var r={msg:f.default.MEDIA_SEGMENT,data:{type:t,data:n}};e.postMessage(r,[n.data])}function r(){var t={msg:f.default.LOADING_COMPLETE};e.postMessage(t)}function i(){var t={msg:f.default.RECOVERED_EARLY_EOF};e.postMessage(t)}function a(t){var n={msg:f.default.MEDIA_INFO,data:t};e.postMessage(n)}function s(t){var n={msg:f.default.METADATA_ARRIVED,data:t};e.postMessage(n)}function l(t){var n={msg:f.default.SCRIPTDATA_ARRIVED,data:t};e.postMessage(n)}function d(t){var n={msg:f.default.STATISTICS_INFO,data:t};e.postMessage(n)}function h(t,n){e.postMessage({msg:f.default.IO_ERROR,data:{type:t,info:n}})}function p(t,n){e.postMessage({msg:f.default.DEMUX_ERROR,data:{type:t,info:n}})}function m(t){e.postMessage({msg:f.default.RECOMMEND_SEEKPOINT,data:t})}function v(t,n){e.postMessage({msg:"logcat_callback",data:{type:t,logcat:n}})}var g=null,y=v.bind(this);u.default.install(),e.addEventListener("message",function(u){switch(u.data.cmd){case"init":g=new c.default(u.data.param[0],u.data.param[1]),g.on(f.default.IO_ERROR,h.bind(this)),g.on(f.default.DEMUX_ERROR,p.bind(this)),g.on(f.default.INIT_SEGMENT,t.bind(this)),g.on(f.default.MEDIA_SEGMENT,n.bind(this)),g.on(f.default.LOADING_COMPLETE,r.bind(this)),g.on(f.default.RECOVERED_EARLY_EOF,i.bind(this)),g.on(f.default.MEDIA_INFO,a.bind(this)),g.on(f.default.METADATA_ARRIVED,s.bind(this)),g.on(f.default.SCRIPTDATA_ARRIVED,l.bind(this)),g.on(f.default.STATISTICS_INFO,d.bind(this)),g.on(f.default.RECOMMEND_SEEKPOINT,m.bind(this));break;case"destroy":g&&(g.destroy(),g=null),e.postMessage({msg:"destroyed"});break;case"start":g.start();break;case"stop":g.stop();break;case"seek":g.seek(u.data.param);break;case"pause":g.pause();break;case"resume":g.resume();break;case"logging_config":var v=u.data.param;o.default.applyConfig(v),!0===v.enableCallback?o.default.addLogListener(y):o.default.removeLogListener(y)}})};n.default=h},{"../utils/logger.js":41,"../utils/logging-control.js":42,"../utils/polyfill.js":43,"./transmuxing-controller.js":12,"./transmuxing-events.js":13}],15:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("../utils/logger.js"),s=r(o),u=e("../utils/utf8-conv.js"),l=r(u),c=e("../utils/exception.js"),d=function(){var e=new ArrayBuffer(2);return new DataView(e).setInt16(0,256,!0),256===new Int16Array(e)[0]}(),f=function(){function e(){i(this,e)}return a(e,null,[{key:"parseScriptData",value:function(t,n,r){var i={};try{var a=e.parseValue(t,n,r),o=e.parseValue(t,n+a.size,r-a.size);i[a.data]=o.data}catch(e){}return i}},{key:"parseObject",value:function(t,n,r){if(r<3)throw new c.IllegalStateException("Data not enough when parse ScriptDataObject");var i=e.parseString(t,n,r),a=e.parseValue(t,n+i.size,r-i.size),o=a.objectEnd;return{data:{name:i.data,value:a.data},size:i.size+a.size,objectEnd:o}}},{key:"parseVariable",value:function(t,n,r){return e.parseObject(t,n,r)}},{key:"parseString",value:function(e,t,n){if(n<2)throw new c.IllegalStateException("Data not enough when parse String");var r=new DataView(e,t,n),i=r.getUint16(0,!d),a=void 0;return a=i>0?(0,l.default)(new Uint8Array(e,t+2,i)):"",{data:a,size:2+i}}},{key:"parseLongString",value:function(e,t,n){if(n<4)throw new c.IllegalStateException("Data not enough when parse LongString");var r=new DataView(e,t,n),i=r.getUint32(0,!d),a=void 0;return a=i>0?(0,l.default)(new Uint8Array(e,t+4,i)):"",{data:a,size:4+i}}},{key:"parseDate",value:function(e,t,n){if(n<10)throw new c.IllegalStateException("Data size invalid when parse Date");var r=new DataView(e,t,n),i=r.getFloat64(0,!d);return i+=60*r.getInt16(8,!d)*1e3,{data:new Date(i),size:10}}},{key:"parseValue",value:function(t,n,r){if(r<1)throw new c.IllegalStateException("Data not enough when parse Value");var i=new DataView(t,n,r),a=1,o=i.getUint8(0),u=void 0,l=!1;try{switch(o){case 0:u=i.getFloat64(1,!d),a+=8;break;case 1:u=!!i.getUint8(1),a+=1;break;case 2:var f=e.parseString(t,n+1,r-1);u=f.data,a+=f.size;break;case 3:u={};var h=0;for(9==(16777215&i.getUint32(r-4,!d))&&(h=3);a<r-4;){var p=e.parseObject(t,n+a,r-a-h);if(p.objectEnd)break;u[p.data.name]=p.data.value,a+=p.size}a<=r-3&&9==(16777215&i.getUint32(a-1,!d))&&(a+=3);break;case 8:u={},a+=4;var m=0;for(9==(16777215&i.getUint32(r-4,!d))&&(m=3);a<r-8;){var v=e.parseVariable(t,n+a,r-a-m);if(v.objectEnd)break;u[v.data.name]=v.data.value,a+=v.size}a<=r-3&&9==(16777215&i.getUint32(a-1,!d))&&(a+=3);break;case 9:u=void 0,a=1,l=!0;break;case 10:u=[];var g=i.getUint32(1,!d);a+=4;for(var y=0;y<g;y++){var _=e.parseValue(t,n+a,r-a);u.push(_.data),a+=_.size}break;case 11:var b=e.parseDate(t,n+1,r-1);u=b.data,a+=b.size;break;case 12:var T=e.parseString(t,n+1,r-1);u=T.data,a+=T.size;break;default:a=r,s.default.w("AMF","Unsupported AMF value type "+o)}}catch(e){s.default.e("AMF",e.toString())}return{data:u,size:a,objectEnd:l}}}]),e}();n.default=f},{"../utils/exception.js":40,"../utils/logger.js":41,"../utils/utf8-conv.js":44}],16:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={OK:"OK",FORMAT_ERROR:"FormatError",FORMAT_UNSUPPORTED:"FormatUnsupported",CODEC_UNSUPPORTED:"CodecUnsupported"};n.default=r},{}],17:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=e("../utils/exception.js"),o=function(){function e(t){r(this,e),this.TAG="ExpGolomb",this._buffer=t,this._buffer_index=0,this._total_bytes=t.byteLength,this._total_bits=8*t.byteLength,this._current_word=0,this._current_word_bits_left=0}return i(e,[{key:"destroy",value:function(){this._buffer=null}},{key:"_fillCurrentWord",value:function(){var e=this._total_bytes-this._buffer_index;if(e<=0)throw new a.IllegalStateException("ExpGolomb: _fillCurrentWord() but no bytes available");var t=Math.min(4,e),n=new Uint8Array(4);n.set(this._buffer.subarray(this._buffer_index,this._buffer_index+t)),this._current_word=new DataView(n.buffer).getUint32(0,!1),this._buffer_index+=t,this._current_word_bits_left=8*t}},{key:"readBits",value:function(e){if(e>32)throw new a.InvalidArgumentException("ExpGolomb: readBits() bits exceeded max 32bits!");if(e<=this._current_word_bits_left){var t=this._current_word>>>32-e;return this._current_word<<=e,this._current_word_bits_left-=e,t}var n=this._current_word_bits_left?this._current_word:0;n>>>=32-this._current_word_bits_left;var r=e-this._current_word_bits_left;this._fillCurrentWord();var i=Math.min(r,this._current_word_bits_left),o=this._current_word>>>32-i;return this._current_word<<=i,this._current_word_bits_left-=i,n=n<<i|o}},{key:"readBool",value:function(){return 1===this.readBits(1)}},{key:"readByte",value:function(){return this.readBits(8)}},{key:"_skipLeadingZero",value:function(){var e=void 0;for(e=0;e<this._current_word_bits_left;e++)if(0!=(this._current_word&2147483648>>>e))return this._current_word<<=e,this._current_word_bits_left-=e,e;return this._fillCurrentWord(),e+this._skipLeadingZero()}},{key:"readUEG",value:function(){var e=this._skipLeadingZero();return this.readBits(e+1)-1}},{key:"readSEG",value:function(){var e=this.readUEG();return 1&e?e+1>>>1:-1*(e>>>1)}}]),e}();n.default=o},{"../utils/exception.js":40}],18:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){return e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3]}Object.defineProperty(n,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=e("../utils/logger.js"),l=r(u),c=e("./amf-parser.js"),d=r(c),f=e("./sps-parser.js"),h=r(f),p=e("./demux-errors.js"),m=r(p),v=e("../core/media-info.js"),g=r(v),y=e("../utils/exception.js"),_=function(){function e(t,n){i(this,e),this.TAG="FLVDemuxer",this._config=n,this._onError=null,this._onMediaInfo=null,this._onMetaDataArrived=null,this._onScriptDataArrived=null,this._onTrackMetadata=null,this._onDataAvailable=null,this._dataOffset=t.dataOffset,this._firstParse=!0,this._dispatch=!1,this._hasAudio=t.hasAudioTrack,this._hasVideo=t.hasVideoTrack,this._hasAudioFlagOverrided=!1,this._hasVideoFlagOverrided=!1,this._audioInitialMetadataDispatched=!1,this._videoInitialMetadataDispatched=!1,this._mediaInfo=new g.default,this._mediaInfo.hasAudio=this._hasAudio,this._mediaInfo.hasVideo=this._hasVideo,this._metadata=null,this._audioMetadata=null,this._videoMetadata=null,this._naluLengthSize=4,this._timestampBase=0,this._timescale=1e3,this._duration=0,this._durationOverrided=!1,this._referenceFrameRate={fixed:!0,fps:23.976,fps_num:23976,fps_den:1e3},this._flvSoundRateTable=[5500,11025,22050,44100,48e3],this._mpegSamplingRates=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],this._mpegAudioV10SampleRateTable=[44100,48e3,32e3,0],this._mpegAudioV20SampleRateTable=[22050,24e3,16e3,0],this._mpegAudioV25SampleRateTable=[11025,12e3,8e3,0],this._mpegAudioL1BitRateTable=[0,32,64,96,128,160,192,224,256,288,320,352,384,416,448,-1],this._mpegAudioL2BitRateTable=[0,32,48,56,64,80,96,112,128,160,192,224,256,320,384,-1],this._mpegAudioL3BitRateTable=[0,32,40,48,56,64,80,96,112,128,160,192,224,256,320,-1],this._videoTrack={type:"video",id:1,sequenceNumber:0,samples:[],length:0},this._audioTrack={type:"audio",id:2,sequenceNumber:0,samples:[],length:0},this._littleEndian=function(){var e=new ArrayBuffer(2);return new DataView(e).setInt16(0,256,!0),256===new Int16Array(e)[0]}()}return s(e,[{key:"destroy",value:function(){this._mediaInfo=null,this._metadata=null,this._audioMetadata=null,this._videoMetadata=null,this._videoTrack=null,this._audioTrack=null,this._onError=null,this._onMediaInfo=null,this._onMetaDataArrived=null,this._onScriptDataArrived=null,this._onTrackMetadata=null,this._onDataAvailable=null}},{key:"bindDataSource",value:function(e){return e.onDataArrival=this.parseChunks.bind(this),this}},{key:"resetMediaInfo",value:function(){this._mediaInfo=new g.default}},{key:"_isInitialMetadataDispatched",value:function(){return this._hasAudio&&this._hasVideo?this._audioInitialMetadataDispatched&&this._videoInitialMetadataDispatched:this._hasAudio&&!this._hasVideo?this._audioInitialMetadataDispatched:!(this._hasAudio||!this._hasVideo)&&this._videoInitialMetadataDispatched}},{key:"parseChunks",value:function(t,n){if(!(this._onError&&this._onMediaInfo&&this._onTrackMetadata&&this._onDataAvailable))throw new y.IllegalStateException("Flv: onError & onMediaInfo & onTrackMetadata & onDataAvailable callback must be specified");var r=0,i=this._littleEndian;if(0===n){if(!(t.byteLength>13))return 0;r=e.probe(t).dataOffset}for(this._firstParse&&(this._firstParse=!1,n+r!==this._dataOffset&&l.default.w(this.TAG,"First time parsing but chunk byteStart invalid!"),0!==new DataView(t,r).getUint32(0,!i)&&l.default.w(this.TAG,"PrevTagSize0 !== 0 !!!"),r+=4);r<t.byteLength;){this._dispatch=!0;var a=new DataView(t,r);if(r+11+4>t.byteLength)break;var o=a.getUint8(0),s=16777215&a.getUint32(0,!i);if(r+11+s+4>t.byteLength)break;if(8===o||9===o||18===o){var u=a.getUint8(4),c=a.getUint8(5),d=a.getUint8(6),f=a.getUint8(7),h=d|c<<8|u<<16|f<<24;0!=(16777215&a.getUint32(7,!i))&&l.default.w(this.TAG,"Meet tag which has StreamID != 0!");var p=r+11;switch(o){case 8:this._parseAudioData(t,p,s,h);break;case 9:this._parseVideoData(t,p,s,h,n+r);break;case 18:this._parseScriptData(t,p,s)}var m=a.getUint32(11+s,!i);m!==11+s&&l.default.w(this.TAG,"Invalid PrevTagSize "+m),r+=11+s+4}else l.default.w(this.TAG,"Unsupported tag type "+o+", skipped"),r+=11+s+4}return this._isInitialMetadataDispatched()&&this._dispatch&&(this._audioTrack.length||this._videoTrack.length)&&this._onDataAvailable(this._audioTrack,this._videoTrack),r}},{key:"_parseScriptData",value:function(e,t,n){var r=d.default.parseScriptData(e,t,n);if(r.hasOwnProperty("onMetaData")){if(null==r.onMetaData||"object"!==o(r.onMetaData))return void l.default.w(this.TAG,"Invalid onMetaData structure!");this._metadata&&l.default.w(this.TAG,"Found another onMetaData tag!"),this._metadata=r;var i=this._metadata.onMetaData;if(this._onMetaDataArrived&&this._onMetaDataArrived(Object.assign({},i)),"boolean"==typeof i.hasAudio&&!1===this._hasAudioFlagOverrided&&(this._hasAudio=i.hasAudio,this._mediaInfo.hasAudio=this._hasAudio),"boolean"==typeof i.hasVideo&&!1===this._hasVideoFlagOverrided&&(this._hasVideo=i.hasVideo,this._mediaInfo.hasVideo=this._hasVideo),"number"==typeof i.audiodatarate&&(this._mediaInfo.audioDataRate=i.audiodatarate),"number"==typeof i.videodatarate&&(this._mediaInfo.videoDataRate=i.videodatarate),"number"==typeof i.width&&(this._mediaInfo.width=i.width),"number"==typeof i.height&&(this._mediaInfo.height=i.height),"number"==typeof i.duration){if(!this._durationOverrided){var a=Math.floor(i.duration*this._timescale);this._duration=a,this._mediaInfo.duration=a}}else this._mediaInfo.duration=0;if("number"==typeof i.framerate){var s=Math.floor(1e3*i.framerate);if(s>0){var u=s/1e3;this._referenceFrameRate.fixed=!0,this._referenceFrameRate.fps=u,this._referenceFrameRate.fps_num=s,this._referenceFrameRate.fps_den=1e3,this._mediaInfo.fps=u}}if("object"===o(i.keyframes)){this._mediaInfo.hasKeyframesIndex=!0;var c=i.keyframes;this._mediaInfo.keyframesIndex=this._parseKeyframesIndex(c),i.keyframes=null}else this._mediaInfo.hasKeyframesIndex=!1;this._dispatch=!1,this._mediaInfo.metadata=i,l.default.v(this.TAG,"Parsed onMetaData"),this._mediaInfo.isComplete()&&this._onMediaInfo(this._mediaInfo)}Object.keys(r).length>0&&this._onScriptDataArrived&&this._onScriptDataArrived(Object.assign({},r))}},{key:"_parseKeyframesIndex",value:function(e){for(var t=[],n=[],r=1;r<e.times.length;r++){var i=this._timestampBase+Math.floor(1e3*e.times[r]);t.push(i),n.push(e.filepositions[r])}return{times:t,filepositions:n}}},{key:"_parseAudioData",value:function(e,t,n,r){if(n<=1)return void l.default.w(this.TAG,"Flv: Invalid audio packet, missing SoundData payload!");if(!0!==this._hasAudioFlagOverrided||!1!==this._hasAudio){var i=(this._littleEndian,new DataView(e,t,n)),a=i.getUint8(0),o=a>>>4;if(2!==o&&10!==o)return void this._onError(m.default.CODEC_UNSUPPORTED,"Flv: Unsupported audio codec idx: "+o);var s=0,u=(12&a)>>>2;if(!(u>=0&&u<=4))return void this._onError(m.default.FORMAT_ERROR,"Flv: Invalid audio sample rate idx: "+u);s=this._flvSoundRateTable[u];var c=1&a,d=this._audioMetadata,f=this._audioTrack;if(d||(!1===this._hasAudio&&!1===this._hasAudioFlagOverrided&&(this._hasAudio=!0,this._mediaInfo.hasAudio=!0),d=this._audioMetadata={},d.type="audio",d.id=f.id,d.timescale=this._timescale,d.duration=this._duration,d.audioSampleRate=s,d.channelCount=0===c?1:2),10===o){var h=this._parseAACAudioData(e,t+1,n-1);if(void 0==h)return;if(0===h.packetType){if(d.config)return void l.default.w(this.TAG,"Found another AudioSpecificConfig!");var p=h.data;d.audioSampleRate=p.samplingRate,d.channelCount=p.channelCount,d.codec=p.codec,d.originalCodec=p.originalCodec,d.config=p.config,d.refSampleDuration=1024/d.audioSampleRate*d.timescale,l.default.v(this.TAG,"Parsed AudioSpecificConfig"),this._isInitialMetadataDispatched()?this._dispatch&&(this._audioTrack.length||this._videoTrack.length)&&this._onDataAvailable(this._audioTrack,this._videoTrack):this._audioInitialMetadataDispatched=!0,this._dispatch=!1,this._onTrackMetadata("audio",d);var v=this._mediaInfo;v.audioCodec=d.originalCodec,v.audioSampleRate=d.audioSampleRate,v.audioChannelCount=d.channelCount,v.hasVideo?null!=v.videoCodec&&(v.mimeType='video/x-flv; codecs="'+v.videoCodec+","+v.audioCodec+'"'):v.mimeType='video/x-flv; codecs="'+v.audioCodec+'"',v.isComplete()&&this._onMediaInfo(v)}else if(1===h.packetType){var g=this._timestampBase+r,y={unit:h.data,length:h.data.byteLength,dts:g,pts:g};f.samples.push(y),f.length+=h.data.length}else l.default.e(this.TAG,"Flv: Unsupported AAC data type "+h.packetType)}else if(2===o){if(!d.codec){var _=this._parseMP3AudioData(e,t+1,n-1,!0);if(void 0==_)return;d.audioSampleRate=_.samplingRate,d.channelCount=_.channelCount,d.codec=_.codec,d.originalCodec=_.originalCodec,d.refSampleDuration=1152/d.audioSampleRate*d.timescale,l.default.v(this.TAG,"Parsed MPEG Audio Frame Header"),this._audioInitialMetadataDispatched=!0,this._onTrackMetadata("audio",d);var b=this._mediaInfo;b.audioCodec=d.codec,b.audioSampleRate=d.audioSampleRate,b.audioChannelCount=d.channelCount,b.audioDataRate=_.bitRate,b.hasVideo?null!=b.videoCodec&&(b.mimeType='video/x-flv; codecs="'+b.videoCodec+","+b.audioCodec+'"'):b.mimeType='video/x-flv; codecs="'+b.audioCodec+'"',b.isComplete()&&this._onMediaInfo(b)}var T=this._parseMP3AudioData(e,t+1,n-1,!1);if(void 0==T)return;var S=this._timestampBase+r,w={unit:T,length:T.byteLength,dts:S,pts:S};f.samples.push(w),f.length+=T.length}}}},{key:"_parseAACAudioData",value:function(e,t,n){if(n<=1)return void l.default.w(this.TAG,"Flv: Invalid AAC packet, missing AACPacketType or/and Data!");var r={},i=new Uint8Array(e,t,n);return r.packetType=i[0],0===i[0]?r.data=this._parseAACAudioSpecificConfig(e,t+1,n-1):r.data=i.subarray(1),r}},{key:"_parseAACAudioSpecificConfig",value:function(e,t,n){var r=new Uint8Array(e,t,n),i=null,a=0,o=0,s=0,u=null;if(a=o=r[0]>>>3,(s=(7&r[0])<<1|r[1]>>>7)<0||s>=this._mpegSamplingRates.length)return void this._onError(m.default.FORMAT_ERROR,"Flv: AAC invalid sampling frequency index!");var l=this._mpegSamplingRates[s],c=(120&r[1])>>>3;if(c<0||c>=8)return void this._onError(m.default.FORMAT_ERROR,"Flv: AAC invalid channel configuration");5===a&&(u=(7&r[1])<<1|r[2]>>>7,r[2]);var d=self.navigator.userAgent.toLowerCase();return-1!==d.indexOf("firefox")?s>=6?(a=5,i=new Array(4),u=s-3):(a=2,i=new Array(2),u=s):-1!==d.indexOf("android")?(a=2,i=new Array(2),u=s):(a=5,u=s,i=new Array(4),s>=6?u=s-3:1===c&&(a=2,i=new Array(2),u=s)),i[0]=a<<3,i[0]|=(15&s)>>>1,i[1]=(15&s)<<7,i[1]|=(15&c)<<3,5===a&&(i[1]|=(15&u)>>>1,i[2]=(1&u)<<7,i[2]|=8,i[3]=0),{config:i,samplingRate:l,channelCount:c,codec:"mp4a.40."+a,originalCodec:"mp4a.40."+o}}},{key:"_parseMP3AudioData",value:function(e,t,n,r){if(n<4)return void l.default.w(this.TAG,"Flv: Invalid MP3 packet, header missing!");var i=(this._littleEndian,new Uint8Array(e,t,n)),a=null;if(r){if(255!==i[0])return;var o=i[1]>>>3&3,s=(6&i[1])>>1,u=(240&i[2])>>>4,c=(12&i[2])>>>2,d=i[3]>>>6&3,f=3!==d?2:1,h=0,p=0;switch(o){case 0:h=this._mpegAudioV25SampleRateTable[c];break;case 2:h=this._mpegAudioV20SampleRateTable[c];break;case 3:h=this._mpegAudioV10SampleRateTable[c]}switch(s){case 1:u<this._mpegAudioL3BitRateTable.length&&(p=this._mpegAudioL3BitRateTable[u]);break;case 2:u<this._mpegAudioL2BitRateTable.length&&(p=this._mpegAudioL2BitRateTable[u]);break;case 3:u<this._mpegAudioL1BitRateTable.length&&(p=this._mpegAudioL1BitRateTable[u])}a={bitRate:p,samplingRate:h,channelCount:f,codec:"mp3",originalCodec:"mp3"}}else a=i;return a}},{key:"_parseVideoData",value:function(e,t,n,r,i){if(n<=1)return void l.default.w(this.TAG,"Flv: Invalid video packet, missing VideoData payload!");if(!0!==this._hasVideoFlagOverrided||!1!==this._hasVideo){var a=new Uint8Array(e,t,n)[0],o=(240&a)>>>4,s=15&a;if(7!==s)return void this._onError(m.default.CODEC_UNSUPPORTED,"Flv: Unsupported codec in video frame: "+s);this._parseAVCVideoPacket(e,t+1,n-1,r,i,o)}}},{key:"_parseAVCVideoPacket",value:function(e,t,n,r,i,a){if(n<4)return void l.default.w(this.TAG,"Flv: Invalid AVC packet, missing AVCPacketType or/and CompositionTime");var o=this._littleEndian,s=new DataView(e,t,n),u=s.getUint8(0),c=16777215&s.getUint32(0,!o),d=c<<8>>8;if(0===u)this._parseAVCDecoderConfigurationRecord(e,t+4,n-4);else if(1===u)this._parseAVCVideoData(e,t+4,n-4,r,i,a,d);else if(2!==u)return void this._onError(m.default.FORMAT_ERROR,"Flv: Invalid video packet type "+u)}},{key:"_parseAVCDecoderConfigurationRecord",value:function(e,t,n){if(n<7)return void l.default.w(this.TAG,"Flv: Invalid AVCDecoderConfigurationRecord, lack of data!");var r=this._videoMetadata,i=this._videoTrack,a=this._littleEndian,o=new DataView(e,t,n);if(r){if(void 0!==r.avcc)return void l.default.w(this.TAG,"Found another AVCDecoderConfigurationRecord!")}else!1===this._hasVideo&&!1===this._hasVideoFlagOverrided&&(this._hasVideo=!0,this._mediaInfo.hasVideo=!0),r=this._videoMetadata={},r.type="video",r.id=i.id,r.timescale=this._timescale,r.duration=this._duration;var s=o.getUint8(0),u=o.getUint8(1);if(o.getUint8(2),o.getUint8(3),1!==s||0===u)return void this._onError(m.default.FORMAT_ERROR,"Flv: Invalid AVCDecoderConfigurationRecord");if(this._naluLengthSize=1+(3&o.getUint8(4)),3!==this._naluLengthSize&&4!==this._naluLengthSize)return void this._onError(m.default.FORMAT_ERROR,"Flv: Strange NaluLengthSizeMinusOne: "+(this._naluLengthSize-1));var c=31&o.getUint8(5);if(0===c)return void this._onError(m.default.FORMAT_ERROR,"Flv: Invalid AVCDecoderConfigurationRecord: No SPS");c>1&&l.default.w(this.TAG,"Flv: Strange AVCDecoderConfigurationRecord: SPS Count = "+c);for(var d=6,f=0;f<c;f++){var p=o.getUint16(d,!a);if(d+=2,0!==p){var v=new Uint8Array(e,t+d,p);d+=p;var g=h.default.parseSPS(v);if(0===f){r.codecWidth=g.codec_size.width,r.codecHeight=g.codec_size.height,r.presentWidth=g.present_size.width,r.presentHeight=g.present_size.height,r.profile=g.profile_string,r.level=g.level_string,r.bitDepth=g.bit_depth,r.chromaFormat=g.chroma_format,r.sarRatio=g.sar_ratio,r.frameRate=g.frame_rate,!1!==g.frame_rate.fixed&&0!==g.frame_rate.fps_num&&0!==g.frame_rate.fps_den||(r.frameRate=this._referenceFrameRate);var y=r.frameRate.fps_den,_=r.frameRate.fps_num;r.refSampleDuration=r.timescale*(y/_);for(var b=v.subarray(1,4),T="avc1.",S=0;S<3;S++){var w=b[S].toString(16);w.length<2&&(w="0"+w),T+=w}r.codec=T;var k=this._mediaInfo;k.width=r.codecWidth,k.height=r.codecHeight,k.fps=r.frameRate.fps,k.profile=r.profile,k.level=r.level,k.refFrames=g.ref_frames,k.chromaFormat=g.chroma_format_string,k.sarNum=r.sarRatio.width,k.sarDen=r.sarRatio.height,k.videoCodec=T,k.hasAudio?null!=k.audioCodec&&(k.mimeType='video/x-flv; codecs="'+k.videoCodec+","+k.audioCodec+'"'):k.mimeType='video/x-flv; codecs="'+k.videoCodec+'"',k.isComplete()&&this._onMediaInfo(k)}}}var E=o.getUint8(d);if(0===E)return void this._onError(m.default.FORMAT_ERROR,"Flv: Invalid AVCDecoderConfigurationRecord: No PPS");E>1&&l.default.w(this.TAG,"Flv: Strange AVCDecoderConfigurationRecord: PPS Count = "+E),d++;for(var A=0;A<E;A++){var C=o.getUint16(d,!a);d+=2,0!==C&&(d+=C)}r.avcc=new Uint8Array(n),r.avcc.set(new Uint8Array(e,t,n),0),l.default.v(this.TAG,"Parsed AVCDecoderConfigurationRecord"),this._isInitialMetadataDispatched()?this._dispatch&&(this._audioTrack.length||this._videoTrack.length)&&this._onDataAvailable(this._audioTrack,this._videoTrack):this._videoInitialMetadataDispatched=!0,this._dispatch=!1,this._onTrackMetadata("video",r)}},{key:"_parseAVCVideoData",value:function(e,t,n,r,i,a,o){for(var s=this._littleEndian,u=new DataView(e,t,n),c=[],d=0,f=0,h=this._naluLengthSize,p=this._timestampBase+r,m=1===a;f<n;){if(f+4>=n){l.default.w(this.TAG,"Malformed Nalu near timestamp "+p+", offset = "+f+", dataSize = "+n);break}var v=u.getUint32(f,!s);if(3===h&&(v>>>=8),v>n-h)return void l.default.w(this.TAG,"Malformed Nalus near timestamp "+p+", NaluSize > DataSize!");var g=31&u.getUint8(f+h);5===g&&(m=!0);var y=new Uint8Array(e,t+f,h+v),_={type:g,data:y};c.push(_),d+=y.byteLength,f+=h+v}if(c.length){var b=this._videoTrack,T={units:c,length:d,isKeyframe:m,dts:p,cts:o,pts:p+o};m&&(T.fileposition=i),b.samples.push(T),b.length+=d}}},{key:"onTrackMetadata",get:function(){return this._onTrackMetadata},set:function(e){this._onTrackMetadata=e}},{key:"onMediaInfo",get:function(){return this._onMediaInfo},set:function(e){this._onMediaInfo=e}},{key:"onMetaDataArrived",get:function(){return this._onMetaDataArrived},set:function(e){this._onMetaDataArrived=e}},{key:"onScriptDataArrived",get:function(){return this._onScriptDataArrived},set:function(e){this._onScriptDataArrived=e}},{key:"onError",get:function(){return this._onError},set:function(e){this._onError=e}},{key:"onDataAvailable",get:function(){return this._onDataAvailable},set:function(e){this._onDataAvailable=e}},{key:"timestampBase",get:function(){return this._timestampBase},set:function(e){this._timestampBase=e}},{key:"overridedDuration",get:function(){return this._duration},set:function(e){this._durationOverrided=!0,this._duration=e,this._mediaInfo.duration=e}},{key:"overridedHasAudio",set:function(e){this._hasAudioFlagOverrided=!0,this._hasAudio=e,this._mediaInfo.hasAudio=e}},{key:"overridedHasVideo",set:function(e){this._hasVideoFlagOverrided=!0,this._hasVideo=e,this._mediaInfo.hasVideo=e}}],[{key:"probe",value:function(e){var t=new Uint8Array(e),n={match:!1};if(70!==t[0]||76!==t[1]||86!==t[2]||1!==t[3])return n;var r=(4&t[4])>>>2!=0,i=0!=(1&t[4]),o=a(t,5);return o<9?n:{match:!0,consumed:o,dataOffset:o,hasAudioTrack:r,hasVideoTrack:i}}}]),e}();n.default=_},{"../core/media-info.js":7,"../utils/exception.js":40,"../utils/logger.js":41,"./amf-parser.js":15,"./demux-errors.js":16,"./sps-parser.js":19}],19:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=e("./exp-golomb.js"),o=function(e){return e&&e.__esModule?e:{default:e}}(a),s=function(){function e(){r(this,e)}return i(e,null,[{key:"_ebsp2rbsp",value:function(e){for(var t=e,n=t.byteLength,r=new Uint8Array(n),i=0,a=0;a<n;a++)a>=2&&3===t[a]&&0===t[a-1]&&0===t[a-2]||(r[i]=t[a],i++);return new Uint8Array(r.buffer,0,i)}},{key:"parseSPS",value:function(t){var n=e._ebsp2rbsp(t),r=new o.default(n);r.readByte();var i=r.readByte();r.readByte();var a=r.readByte();r.readUEG();var s=e.getProfileString(i),u=e.getLevelString(a),l=1,c=420,d=[0,420,422,444],f=8;if((100===i||110===i||122===i||244===i||44===i||83===i||86===i||118===i||128===i||138===i||144===i)&&(l=r.readUEG(),3===l&&r.readBits(1),l<=3&&(c=d[l]),f=r.readUEG()+8,r.readUEG(),r.readBits(1),r.readBool()))for(var h=3!==l?8:12,p=0;p<h;p++)r.readBool()&&(p<6?e._skipScalingList(r,16):e._skipScalingList(r,64));r.readUEG();var m=r.readUEG();if(0===m)r.readUEG();else if(1===m){r.readBits(1),r.readSEG(),r.readSEG();for(var v=r.readUEG(),g=0;g<v;g++)r.readSEG()}var y=r.readUEG();r.readBits(1);var _=r.readUEG(),b=r.readUEG(),T=r.readBits(1);0===T&&r.readBits(1),r.readBits(1);var S=0,w=0,k=0,E=0;r.readBool()&&(S=r.readUEG(),w=r.readUEG(),k=r.readUEG(),E=r.readUEG());var A=1,C=1,L=0,x=!0,j=0,O=0;if(r.readBool()){if(r.readBool()){var I=r.readByte(),P=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],R=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1];I>0&&I<16?(A=P[I-1],C=R[I-1]):255===I&&(A=r.readByte()<<8|r.readByte(),C=r.readByte()<<8|r.readByte())}if(r.readBool()&&r.readBool(),r.readBool()&&(r.readBits(4),r.readBool()&&r.readBits(24)),r.readBool()&&(r.readUEG(),r.readUEG()),r.readBool()){var D=r.readBits(32),M=r.readBits(32);x=r.readBool(),j=M,O=2*D,L=j/O}}var U=1;1===A&&1===C||(U=A/C);var B=0,N=0;if(0===l)B=1,N=2-T;else{var F=3===l?1:2,V=1===l?2:1;B=F,N=V*(2-T)}var q=16*(_+1),G=16*(b+1)*(2-T);q-=(S+w)*B,G-=(k+E)*N;var H=Math.ceil(q*U);return r.destroy(),r=null,{profile_string:s,level_string:u,bit_depth:f,ref_frames:y,chroma_format:c,chroma_format_string:e.getChromaFormatString(c),frame_rate:{fixed:x,fps:L,fps_den:O,fps_num:j},sar_ratio:{width:A,height:C},codec_size:{width:q,height:G},present_size:{width:H,height:G}}}},{key:"_skipScalingList",value:function(e,t){for(var n=8,r=8,i=0,a=0;a<t;a++)0!==r&&(i=e.readSEG(),r=(n+i+256)%256),n=0===r?n:r}},{key:"getProfileString",value:function(e){switch(e){case 66:return"Baseline";case 77:return"Main";case 88:return"Extended";case 100:return"High";case 110:return"High10";case 122:return"High422";case 244:return"High444";default:return"Unknown"}}},{key:"getLevelString",value:function(e){return(e/10).toFixed(1)}},{key:"getChromaFormatString",value:function(e){switch(e){case 420:return"4:2:0";case 422:return"4:2:2";case 444:return"4:4:4";default:return"Unknown"}}}]),e}();n.default=s},{"./exp-golomb.js":17}],20:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n=e;if(null==n||"object"!==(void 0===n?"undefined":s(n)))throw new S.InvalidArgumentException("MediaDataSource must be an javascript object!");if(!n.hasOwnProperty("type"))throw new S.InvalidArgumentException("MediaDataSource must has type field to indicate video file type!");switch(n.type){case"flv":return new p.default(n,t);default:return new v.default(n,t)}}function a(){return d.default.supportMSEH264Playback()}function o(){return d.default.getFeatureList()}Object.defineProperty(n,"__esModule",{value:!0});var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=e("./utils/polyfill.js"),l=r(u),c=e("./core/features.js"),d=r(c),f=e("./io/loader.js"),h=e("./player/flv-player.js"),p=r(h),m=e("./player/native-player.js"),v=r(m),g=e("./player/player-events.js"),y=r(g),_=e("./player/player-errors.js"),b=e("./utils/logging-control.js"),T=r(b),S=e("./utils/exception.js");l.default.install();var w={};w.createPlayer=i,w.isSupported=a,w.getFeatureList=o,w.BaseLoader=f.BaseLoader,w.LoaderStatus=f.LoaderStatus,w.LoaderErrors=f.LoaderErrors,w.Events=y.default,w.ErrorTypes=_.ErrorTypes,w.ErrorDetails=_.ErrorDetails,w.FlvPlayer=p.default,w.NativePlayer=v.default,w.LoggingControl=T.default,w.reconnect=!1,Object.defineProperty(w,"version",{enumerable:!0,get:function(){return"1.4.2"}}),n.default=w},{"./core/features.js":6,"./io/loader.js":24,"./player/flv-player.js":32,"./player/native-player.js":33,"./player/player-errors.js":34,"./player/player-events.js":35,"./utils/exception.js":40,"./utils/logging-control.js":42,"./utils/polyfill.js":43}],21:[function(e,t,n){"use strict";t.exports=e("./flv.js").default},{"./flv.js":20}],22:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},l=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=e("../utils/logger.js"),d=(r(c),e("../utils/browser.js")),f=r(d),h=e("./loader.js"),p=e("../utils/exception.js"),m=function(e){function t(e,n){i(this,t);var r=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"fetch-stream-loader"));return r.TAG="FetchStreamLoader",r._seekHandler=e,r._config=n,r._needStash=!0,r._requestAbort=!1,r._contentLength=null,r._receivedLength=0,r}return o(t,e),l(t,null,[{key:"isSupported",value:function(){try{var e=f.default.msedge&&f.default.version.minor>=15048,t=!f.default.msedge||e;return self.fetch&&self.ReadableStream&&t}catch(e){return!1}}}]),l(t,[{key:"destroy",value:function(){this.isWorking()&&this.abort(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"open",value:function(e,t){var n=this;this._dataSource=e,this._range=t;var r=e.url;this._config.reuseRedirectedURL&&void 0!=e.redirectedURL&&(r=e.redirectedURL);var i=this._seekHandler.getConfig(r,t),a=new self.Headers;if("object"===s(i.headers)){var o=i.headers;for(var u in o)o.hasOwnProperty(u)&&a.append(u,o[u])}var l={method:"GET",headers:a,mode:"cors",cache:"default",referrerPolicy:"no-referrer-when-downgrade"};if("object"===s(this._config.headers))for(var c in this._config.headers)a.append(c,this._config.headers[c]);!1===e.cors&&(l.mode="same-origin"),e.withCredentials&&(l.credentials="include"),e.referrerPolicy&&(l.referrerPolicy=e.referrerPolicy),this._status=h.LoaderStatus.kConnecting,self.fetch(i.url,l).then(function(e){if(n._requestAbort){try{var t=e.body.getReader();t&&t.cancel()}catch(e){}return n._requestAbort=!1,void(n._status=h.LoaderStatus.kIdle)}if(e.ok&&e.status>=200&&e.status<=299){if(e.url!==i.url&&n._onURLRedirect){var r=n._seekHandler.removeURLParameters(e.url);n._onURLRedirect(r)}var a=e.headers.get("Content-Length");return null!=a&&(n._contentLength=parseInt(a),0!==n._contentLength&&n._onContentLengthKnown&&n._onContentLengthKnown(n._contentLength)),n._pump.call(n,e.body.getReader())}if(n._status=h.LoaderStatus.kError,!n._onError)throw new p.RuntimeException("FetchStreamLoader: Http code invalid, "+e.status+" "+e.statusText);n._onError(h.LoaderErrors.HTTP_STATUS_CODE_INVALID,{code:e.status,msg:e.statusText})}).catch(function(e){if(n._status=h.LoaderStatus.kError,!n._onError)throw e;n._onError(h.LoaderErrors.EXCEPTION,{code:-1,msg:e.message})})}},{key:"abort",value:function(){this._requestAbort=!0}},{key:"_pump",value:function(e){var t=this;return e.read().then(function(n){if(n.done)if(null!==t._contentLength&&t._receivedLength<t._contentLength){t._status=h.LoaderStatus.kError;var r=h.LoaderErrors.EARLY_EOF,i={code:-1,msg:"Fetch stream meet Early-EOF"};if(!t._onError)throw new p.RuntimeException(i.msg);t._onError(r,i)}else t._status=h.LoaderStatus.kComplete,t._onComplete&&t._onComplete(t._range.from,t._range.from+t._receivedLength-1);else{if(!0===t._requestAbort)return t._requestAbort=!1,t._status=h.LoaderStatus.kComplete,e.cancel();t._status=h.LoaderStatus.kBuffering;var a=n.value.buffer,o=t._range.from+t._receivedLength;t._receivedLength+=a.byteLength,t._onDataArrival&&t._onDataArrival(a,o,t._receivedLength),t._pump(e)}}).catch(function(e){if(11!==e.code||!f.default.msedge){t._status=h.LoaderStatus.kError;var n=0,r=null;if(19!==e.code&&"network error"!==e.message||!(null===t._contentLength||null!==t._contentLength&&t._receivedLength<t._contentLength)?(n=h.LoaderErrors.EXCEPTION,r={code:e.code,msg:e.message}):(n=h.LoaderErrors.EARLY_EOF,r={code:e.code,msg:"Fetch stream meet Early-EOF"}),!t._onError)throw new p.RuntimeException(r.msg);t._onError(n,r)}})}}]),t}(h.BaseLoader);n.default=m},{"../utils/browser.js":39,"../utils/exception.js":40,"../utils/logger.js":41,"./loader.js":24}],23:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("../utils/logger.js"),s=r(o),u=e("./speed-sampler.js"),l=r(u),c=e("./loader.js"),d=e("./fetch-stream-loader.js"),f=r(d),h=e("./xhr-moz-chunked-loader.js"),p=r(h),m=e("./xhr-msstream-loader.js"),v=(r(m),e("./xhr-range-loader.js")),g=r(v),y=e("./websocket-loader.js"),_=r(y),b=e("./range-seek-handler.js"),T=r(b),S=e("./param-seek-handler.js"),w=r(S),k=e("../utils/exception.js"),E=function(){function e(t,n,r){i(this,e),this.TAG="IOController",this._config=n,this._extraData=r,this._stashInitialSize=393216,void 0!=n.stashInitialSize&&n.stashInitialSize>0&&(this._stashInitialSize=n.stashInitialSize),this._stashUsed=0,this._stashSize=this._stashInitialSize,this._bufferSize=3145728,this._stashBuffer=new ArrayBuffer(this._bufferSize),this._stashByteStart=0,this._enableStash=!0,!1===n.enableStashBuffer&&(this._enableStash=!1),this._loader=null,this._loaderClass=null,this._seekHandler=null,this._dataSource=t,this._isWebSocketURL=/wss?:\/\/(.+?)/.test(t.url),this._refTotalLength=t.filesize?t.filesize:null,this._totalLength=this._refTotalLength,this._fullRequestFlag=!1,this._currentRange=null,this._redirectedURL=null,this._speedNormalized=0,this._speedSampler=new l.default,this._speedNormalizeList=[64,128,256,384,512,768,1024,1536,2048,3072,4096],this._isEarlyEofReconnecting=!1,this._paused=!1,this._resumeFrom=0,this._onDataArrival=null,this._onSeeked=null,this._onError=null,this._onComplete=null,this._onRedirect=null,this._onRecoveredEarlyEof=null,this._selectSeekHandler(),this._selectLoader(),this._createLoader()}return a(e,[{key:"destroy",value:function(){this._loader.isWorking()&&this._loader.abort(),this._loader.destroy(),this._loader=null,this._loaderClass=null,this._dataSource=null,this._stashBuffer=null,this._stashUsed=this._stashSize=this._bufferSize=this._stashByteStart=0,this._currentRange=null,this._speedSampler=null,this._isEarlyEofReconnecting=!1,this._onDataArrival=null,this._onSeeked=null,this._onError=null,this._onComplete=null,this._onRedirect=null,this._onRecoveredEarlyEof=null,this._extraData=null}},{key:"isWorking",value:function(){return this._loader&&this._loader.isWorking()&&!this._paused}},{key:"isPaused",value:function(){return this._paused}},{key:"_selectSeekHandler",value:function(){var e=this._config;if("range"===e.seekType)this._seekHandler=new T.default(this._config.rangeLoadZeroStart);else if("param"===e.seekType){var t=e.seekParamStart||"bstart",n=e.seekParamEnd||"bend";this._seekHandler=new w.default(t,n)}else{if("custom"!==e.seekType)throw new k.InvalidArgumentException("Invalid seekType in config: "+e.seekType);if("function"!=typeof e.customSeekHandler)throw new k.InvalidArgumentException("Custom seekType specified in config but invalid customSeekHandler!");this._seekHandler=new e.customSeekHandler}}},{key:"_selectLoader",value:function(){if(null!=this._config.customLoader)this._loaderClass=this._config.customLoader;else if(this._isWebSocketURL)this._loaderClass=_.default;else if(f.default.isSupported())this._loaderClass=f.default;else if(p.default.isSupported())this._loaderClass=p.default;else{if(!g.default.isSupported())throw new k.RuntimeException("Your browser doesn't support xhr with arraybuffer responseType!");this._loaderClass=g.default}}},{key:"_createLoader",value:function(){this._loader=new this._loaderClass(this._seekHandler,this._config),!1===this._loader.needStashBuffer&&(this._enableStash=!1),this._loader.onContentLengthKnown=this._onContentLengthKnown.bind(this),this._loader.onURLRedirect=this._onURLRedirect.bind(this),this._loader.onDataArrival=this._onLoaderChunkArrival.bind(this),this._loader.onComplete=this._onLoaderComplete.bind(this),this._loader.onError=this._onLoaderError.bind(this)}},{key:"open",value:function(e){this._currentRange={from:0,to:-1},e&&(this._currentRange.from=e),this._speedSampler.reset(),e||(this._fullRequestFlag=!0),this._loader.open(this._dataSource,Object.assign({},this._currentRange))}},{key:"abort",value:function(){this._loader.abort(),this._paused&&(this._paused=!1,this._resumeFrom=0)}},{key:"pause",value:function(){this.isWorking()&&(this._loader.abort(),0!==this._stashUsed?(this._resumeFrom=this._stashByteStart,this._currentRange.to=this._stashByteStart-1):this._resumeFrom=this._currentRange.to+1,this._stashUsed=0,this._stashByteStart=0,this._paused=!0)}},{key:"resume",value:function(){if(this._paused){this._paused=!1;var e=this._resumeFrom;this._resumeFrom=0,this._internalSeek(e,!0)}}},{key:"seek",value:function(e){this._paused=!1,this._stashUsed=0,this._stashByteStart=0,this._internalSeek(e,!0)}},{key:"_internalSeek",value:function(e,t){this._loader.isWorking()&&this._loader.abort(),this._flushStashBuffer(t),this._loader.destroy(),this._loader=null;var n={from:e,to:-1};this._currentRange={from:n.from,to:-1},this._speedSampler.reset(),this._stashSize=this._stashInitialSize,this._createLoader(),this._loader.open(this._dataSource,n),this._onSeeked&&this._onSeeked()}},{key:"updateUrl",value:function(e){if(!e||"string"!=typeof e||0===e.length)throw new k.InvalidArgumentException("Url must be a non-empty string!");this._dataSource.url=e}},{key:"_expandBuffer",value:function(e){for(var t=this._stashSize;t+1048576<e;)t*=2;if((t+=1048576)!==this._bufferSize){var n=new ArrayBuffer(t);if(this._stashUsed>0){var r=new Uint8Array(this._stashBuffer,0,this._stashUsed);new Uint8Array(n,0,t).set(r,0)}this._stashBuffer=n,this._bufferSize=t}}},{key:"_normalizeSpeed",value:function(e){var t=this._speedNormalizeList,n=t.length-1,r=0,i=0,a=n;if(e<t[0])return t[0];for(;i<=a;){if((r=i+Math.floor((a-i)/2))===n||e>=t[r]&&e<t[r+1])return t[r];t[r]<e?i=r+1:a=r-1}}},{key:"_adjustStashSize",value:function(e){var t=0;(t=this._config.isLive?e:e<512?e:e>=512&&e<=1024?Math.floor(1.5*e):2*e)>8192&&(t=8192);var n=1024*t+1048576;this._bufferSize<n&&this._expandBuffer(n),this._stashSize=1024*t}},{key:"_dispatchChunks",value:function(e,t){return this._currentRange.to=t+e.byteLength-1,this._onDataArrival(e,t)}},{key:"_onURLRedirect",value:function(e){this._redirectedURL=e,this._onRedirect&&this._onRedirect(e)}},{key:"_onContentLengthKnown",value:function(e){e&&this._fullRequestFlag&&(this._totalLength=e,this._fullRequestFlag=!1)}},{key:"_onLoaderChunkArrival",value:function(e,t,n){if(!this._onDataArrival)throw new k.IllegalStateException("IOController: No existing consumer (onDataArrival) callback!");if(!this._paused){this._isEarlyEofReconnecting&&(this._isEarlyEofReconnecting=!1,this._onRecoveredEarlyEof&&this._onRecoveredEarlyEof()),this._speedSampler.addBytes(e.byteLength);var r=this._speedSampler.lastSecondKBps;if(0!==r){var i=this._normalizeSpeed(r);this._speedNormalized!==i&&(this._speedNormalized=i,this._adjustStashSize(i))}if(this._enableStash)if(0===this._stashUsed&&0===this._stashByteStart&&(this._stashByteStart=t),this._stashUsed+e.byteLength<=this._stashSize){var a=new Uint8Array(this._stashBuffer,0,this._stashSize);a.set(new Uint8Array(e),this._stashUsed),this._stashUsed+=e.byteLength}else{var o=new Uint8Array(this._stashBuffer,0,this._bufferSize);if(this._stashUsed>0){var s=this._stashBuffer.slice(0,this._stashUsed),u=this._dispatchChunks(s,this._stashByteStart);if(u<s.byteLength){if(u>0){var l=new Uint8Array(s,u);o.set(l,0),this._stashUsed=l.byteLength,this._stashByteStart+=u}}else this._stashUsed=0,this._stashByteStart+=u;this._stashUsed+e.byteLength>this._bufferSize&&(this._expandBuffer(this._stashUsed+e.byteLength),o=new Uint8Array(this._stashBuffer,0,this._bufferSize)),o.set(new Uint8Array(e),this._stashUsed),this._stashUsed+=e.byteLength}else{var c=this._dispatchChunks(e,t);if(c<e.byteLength){var d=e.byteLength-c;d>this._bufferSize&&(this._expandBuffer(d),o=new Uint8Array(this._stashBuffer,0,this._bufferSize)),o.set(new Uint8Array(e,c),0),this._stashUsed+=d,this._stashByteStart=t+c}}}else if(0===this._stashUsed){var f=this._dispatchChunks(e,t);if(f<e.byteLength){var h=e.byteLength-f;h>this._bufferSize&&this._expandBuffer(h);var p=new Uint8Array(this._stashBuffer,0,this._bufferSize);p.set(new Uint8Array(e,f),0),this._stashUsed+=h,this._stashByteStart=t+f}}else{this._stashUsed+e.byteLength>this._bufferSize&&this._expandBuffer(this._stashUsed+e.byteLength);var m=new Uint8Array(this._stashBuffer,0,this._bufferSize);m.set(new Uint8Array(e),this._stashUsed),this._stashUsed+=e.byteLength;var v=this._dispatchChunks(this._stashBuffer.slice(0,this._stashUsed),this._stashByteStart);if(v<this._stashUsed&&v>0){var g=new Uint8Array(this._stashBuffer,v);m.set(g,0)}this._stashUsed-=v,this._stashByteStart+=v}}}},{key:"_flushStashBuffer",value:function(e){if(this._stashUsed>0){var t=this._stashBuffer.slice(0,this._stashUsed),n=this._dispatchChunks(t,this._stashByteStart),r=t.byteLength-n;if(n<t.byteLength){if(!e){if(n>0){var i=new Uint8Array(this._stashBuffer,0,this._bufferSize),a=new Uint8Array(t,n);i.set(a,0),this._stashUsed=a.byteLength,this._stashByteStart+=n}return 0}s.default.w(this.TAG,r+" bytes unconsumed data remain when flush buffer, dropped")}return this._stashUsed=0,this._stashByteStart=0,r}return 0}},{key:"_onLoaderComplete",value:function(e,t){this._flushStashBuffer(!0),this._onComplete&&this._onComplete(this._extraData)}},{key:"_onLoaderError",value:function(e,t){switch(s.default.e(this.TAG,"Loader error, code = "+t.code+", msg = "+t.msg),this._flushStashBuffer(!1),this._isEarlyEofReconnecting&&(this._isEarlyEofReconnecting=!1,e=c.LoaderErrors.UNRECOVERABLE_EARLY_EOF),e){case c.LoaderErrors.EARLY_EOF:if(!this._config.isLive&&this._totalLength){var n=this._currentRange.to+1;return void(n<this._totalLength&&(s.default.w(this.TAG,"Connection lost, trying reconnect..."),this._isEarlyEofReconnecting=!0,this._internalSeek(n,!1)))}e=c.LoaderErrors.UNRECOVERABLE_EARLY_EOF;break;case c.LoaderErrors.UNRECOVERABLE_EARLY_EOF:case c.LoaderErrors.CONNECTING_TIMEOUT:case c.LoaderErrors.HTTP_STATUS_CODE_INVALID:case c.LoaderErrors.EXCEPTION:}if(!this._onError)throw new k.RuntimeException("IOException: "+t.msg);this._onError(e,t)}},{key:"status",get:function(){return this._loader.status}},{key:"extraData",get:function(){return this._extraData},set:function(e){this._extraData=e}},{key:"onDataArrival",get:function(){return this._onDataArrival},set:function(e){this._onDataArrival=e}},{key:"onSeeked",get:function(){return this._onSeeked},set:function(e){this._onSeeked=e}},{key:"onError",get:function(){return this._onError},set:function(e){this._onError=e}},{key:"onComplete",get:function(){return this._onComplete},set:function(e){this._onComplete=e}},{key:"onRedirect",get:function(){return this._onRedirect},set:function(e){this._onRedirect=e}},{key:"onRecoveredEarlyEof",get:function(){return this._onRecoveredEarlyEof},set:function(e){this._onRecoveredEarlyEof=e}},{key:"currentURL",get:function(){return this._dataSource.url}},{key:"hasRedirect",get:function(){return null!=this._redirectedURL||void 0!=this._dataSource.redirectedURL}},{key:"currentRedirectedURL",get:function(){return this._redirectedURL||this._dataSource.redirectedURL}},{key:"currentSpeed",get:function(){return this._loaderClass===g.default?this._loader.currentSpeed:this._speedSampler.lastSecondKBps}},{key:"loaderType",get:function(){return this._loader.type}}]),e}();n.default=E},{"../utils/exception.js":40,"../utils/logger.js":41,"./fetch-stream-loader.js":22,"./loader.js":24,"./param-seek-handler.js":25,"./range-seek-handler.js":26,"./speed-sampler.js":27,"./websocket-loader.js":28,"./xhr-moz-chunked-loader.js":29,"./xhr-msstream-loader.js":30,"./xhr-range-loader.js":31}],24:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0}),n.BaseLoader=n.LoaderErrors=n.LoaderStatus=void 0;var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=e("../utils/exception.js"),o=n.LoaderStatus={kIdle:0,kConnecting:1,kBuffering:2,kError:3,kComplete:4};n.LoaderErrors={OK:"OK",EXCEPTION:"Exception",HTTP_STATUS_CODE_INVALID:"HttpStatusCodeInvalid",CONNECTING_TIMEOUT:"ConnectingTimeout",EARLY_EOF:"EarlyEof",UNRECOVERABLE_EARLY_EOF:"UnrecoverableEarlyEof"},n.BaseLoader=function(){function e(t){r(this,e),this._type=t||"undefined",this._status=o.kIdle,this._needStash=!1,this._onContentLengthKnown=null,this._onURLRedirect=null,this._onDataArrival=null,this._onError=null,this._onComplete=null}return i(e,[{key:"destroy",value:function(){this._status=o.kIdle,this._onContentLengthKnown=null,this._onURLRedirect=null,this._onDataArrival=null,this._onError=null,this._onComplete=null}},{key:"isWorking",value:function(){return this._status===o.kConnecting||this._status===o.kBuffering}},{key:"open",value:function(e,t){throw new a.NotImplementedException("Unimplemented abstract function!")}},{key:"abort",value:function(){throw new a.NotImplementedException("Unimplemented abstract function!")}},{key:"type",get:function(){return this._type}},{key:"status",get:function(){return this._status}},{key:"needStashBuffer",get:function(){return this._needStash}},{key:"onContentLengthKnown",get:function(){return this._onContentLengthKnown},set:function(e){this._onContentLengthKnown=e}},{key:"onURLRedirect",get:function(){return this._onURLRedirect},set:function(e){this._onURLRedirect=e}},{key:"onDataArrival",get:function(){return this._onDataArrival},set:function(e){this._onDataArrival=e}},{key:"onError",get:function(){return this._onError},set:function(e){this._onError=e}},{key:"onComplete",get:function(){return this._onComplete},set:function(e){this._onComplete=e}}]),e}()},{"../utils/exception.js":40}],25:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(t,n){r(this,e),this._startName=t,this._endName=n}return i(e,[{key:"getConfig",value:function(e,t){var n=e;if(0!==t.from||-1!==t.to){var r=!0;-1===n.indexOf("?")&&(n+="?",r=!1),r&&(n+="&"),n+=this._startName+"="+t.from.toString(),-1!==t.to&&(n+="&"+this._endName+"="+t.to.toString())}return{url:n,headers:{}}}},{key:"removeURLParameters",value:function(e){var t=e.split("?")[0],n=void 0,r=e.indexOf("?");-1!==r&&(n=e.substring(r+1));var i="";if(void 0!=n&&n.length>0)for(var a=n.split("&"),o=0;o<a.length;o++){var s=a[o].split("="),u=o>0;s[0]!==this._startName&&s[0]!==this._endName&&(u&&(i+="&"),i+=a[o])}return 0===i.length?t:t+"?"+i}}]),e}();n.default=a},{}],26:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(t){r(this,e),this._zeroStart=t||!1}return i(e,[{key:"getConfig",value:function(e,t){var n={};if(0!==t.from||-1!==t.to){var r=void 0;r=-1!==t.to?"bytes="+t.from.toString()+"-"+t.to.toString():"bytes="+t.from.toString()+"-",n.Range=r}else this._zeroStart&&(n.Range="bytes=0-");return{url:e,headers:n}}},{key:"removeURLParameters",value:function(e){return e}}]),e}();n.default=a},{}],27:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this._firstCheckpoint=0,this._lastCheckpoint=0,this._intervalBytes=0,this._totalBytes=0,this._lastSecondBytes=0,self.performance&&self.performance.now?this._now=self.performance.now.bind(self.performance):this._now=Date.now}return i(e,[{key:"reset",value:function(){this._firstCheckpoint=this._lastCheckpoint=0,this._totalBytes=this._intervalBytes=0,this._lastSecondBytes=0}},{key:"addBytes",value:function(e){0===this._firstCheckpoint?(this._firstCheckpoint=this._now(),this._lastCheckpoint=this._firstCheckpoint,this._intervalBytes+=e,this._totalBytes+=e):this._now()-this._lastCheckpoint<1e3?(this._intervalBytes+=e,this._totalBytes+=e):(this._lastSecondBytes=this._intervalBytes,this._intervalBytes=e,this._totalBytes+=e,this._lastCheckpoint=this._now())}},{key:"currentKBps",get:function(){this.addBytes(0);var e=(this._now()-this._lastCheckpoint)/1e3;return 0==e&&(e=1),this._intervalBytes/e/1024}},{key:"lastSecondKBps",get:function(){return this.addBytes(0),0!==this._lastSecondBytes?this._lastSecondBytes/1024:this._now()-this._lastCheckpoint>=500?this.currentKBps:0}},{key:"averageKBps",get:function(){var e=(this._now()-this._firstCheckpoint)/1e3;return this._totalBytes/e/1024}}]),e}();n.default=a},{}],28:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=e("../utils/logger.js"),l=(function(e){e&&e.__esModule}(u),e("./loader.js")),c=e("../utils/exception.js"),d=function(e){function t(){r(this,t);var e=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"websocket-loader"));return e.TAG="WebSocketLoader",e._needStash=!0,e._ws=null,e._requestAbort=!1,e._receivedLength=0,e}return a(t,e),s(t,null,[{key:"isSupported",value:function(){try{return void 0!==self.WebSocket}catch(e){return!1}}}]),s(t,[{key:"destroy",value:function(){this._ws&&this.abort(),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"open",value:function(e){try{var t=this._ws=new self.WebSocket(e.url);t.binaryType="arraybuffer",t.onopen=this._onWebSocketOpen.bind(this),t.onclose=this._onWebSocketClose.bind(this),t.onmessage=this._onWebSocketMessage.bind(this),t.onerror=this._onWebSocketError.bind(this),this._status=l.LoaderStatus.kConnecting}catch(e){this._status=l.LoaderStatus.kError;var n={code:e.code,msg:e.message};if(!this._onError)throw new c.RuntimeException(n.msg);this._onError(l.LoaderErrors.EXCEPTION,n)}}},{key:"abort",value:function(){var e=this._ws;!e||0!==e.readyState&&1!==e.readyState||(this._requestAbort=!0,e.close()),this._ws=null,this._status=l.LoaderStatus.kComplete}},{key:"_onWebSocketOpen",value:function(e){this._status=l.LoaderStatus.kBuffering}},{key:"_onWebSocketClose",value:function(e){if(!0===this._requestAbort)return void(this._requestAbort=!1);this._status=l.LoaderStatus.kComplete,this._onComplete&&this._onComplete(0,this._receivedLength-1)}},{key:"_onWebSocketMessage",value:function(e){var t=this;if(e.data instanceof ArrayBuffer)this._dispatchArrayBuffer(e.data);else if(e.data instanceof Blob){var n=new FileReader;n.onload=function(){t._dispatchArrayBuffer(n.result)},n.readAsArrayBuffer(e.data)}else{this._status=l.LoaderStatus.kError;var r={code:-1,msg:"Unsupported WebSocket message type: "+e.data.constructor.name};if(!this._onError)throw new c.RuntimeException(r.msg);this._onError(l.LoaderErrors.EXCEPTION,r)}}},{key:"_dispatchArrayBuffer",value:function(e){var t=e,n=this._receivedLength;this._receivedLength+=t.byteLength,this._onDataArrival&&this._onDataArrival(t,n,this._receivedLength)}},{key:"_onWebSocketError",value:function(e){this._status=l.LoaderStatus.kError;var t={code:e.code,msg:e.message};if(!this._onError)throw new c.RuntimeException(t.msg);this._onError(l.LoaderErrors.EXCEPTION,t)}}]),t}(l.BaseLoader);n.default=d},{"../utils/exception.js":40,"../utils/logger.js":41,"./loader.js":24}],29:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=e("../utils/logger.js"),c=function(e){return e&&e.__esModule?e:{default:e}}(l),d=e("./loader.js"),f=e("../utils/exception.js"),h=function(e){function t(e,n){r(this,t);var a=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"xhr-moz-chunked-loader"));return a.TAG="MozChunkedLoader",a._seekHandler=e,a._config=n,a._needStash=!0,a._xhr=null,a._requestAbort=!1,a._contentLength=null,a._receivedLength=0,a}return a(t,e),u(t,null,[{key:"isSupported",value:function(){try{var e=new XMLHttpRequest;return e.open("GET","https://example.com",!0),e.responseType="moz-chunked-arraybuffer","moz-chunked-arraybuffer"===e.responseType}catch(e){return c.default.w("MozChunkedLoader",e.message),!1}}}]),u(t,[{key:"destroy",value:function(){this.isWorking()&&this.abort(),this._xhr&&(this._xhr.onreadystatechange=null,this._xhr.onprogress=null,this._xhr.onloadend=null,this._xhr.onerror=null,this._xhr=null),s(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"open",value:function(e,t){this._dataSource=e,this._range=t;var n=e.url;this._config.reuseRedirectedURL&&void 0!=e.redirectedURL&&(n=e.redirectedURL);var r=this._seekHandler.getConfig(n,t);this._requestURL=r.url;var i=this._xhr=new XMLHttpRequest;if(i.open("GET",r.url,!0),i.responseType="moz-chunked-arraybuffer",i.onreadystatechange=this._onReadyStateChange.bind(this),i.onprogress=this._onProgress.bind(this),i.onloadend=this._onLoadEnd.bind(this),i.onerror=this._onXhrError.bind(this),e.withCredentials&&(i.withCredentials=!0),"object"===o(r.headers)){var a=r.headers;for(var s in a)a.hasOwnProperty(s)&&i.setRequestHeader(s,a[s])}if("object"===o(this._config.headers)){var u=this._config.headers;for(var l in u)u.hasOwnProperty(l)&&i.setRequestHeader(l,u[l])}this._status=d.LoaderStatus.kConnecting,i.send()}},{key:"abort",value:function(){this._requestAbort=!0,this._xhr&&this._xhr.abort(),this._status=d.LoaderStatus.kComplete}},{key:"_onReadyStateChange",value:function(e){var t=e.target;if(2===t.readyState){if(void 0!=t.responseURL&&t.responseURL!==this._requestURL&&this._onURLRedirect){var n=this._seekHandler.removeURLParameters(t.responseURL);this._onURLRedirect(n)}if(0!==t.status&&(t.status<200||t.status>299)){if(this._status=d.LoaderStatus.kError,!this._onError)throw new f.RuntimeException("MozChunkedLoader: Http code invalid, "+t.status+" "+t.statusText);this._onError(d.LoaderErrors.HTTP_STATUS_CODE_INVALID,{code:t.status,msg:t.statusText})}else this._status=d.LoaderStatus.kBuffering}}},{key:"_onProgress",value:function(e){if(this._status!==d.LoaderStatus.kError){null===this._contentLength&&null!==e.total&&0!==e.total&&(this._contentLength=e.total,this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength));var t=e.target.response,n=this._range.from+this._receivedLength;this._receivedLength+=t.byteLength,this._onDataArrival&&this._onDataArrival(t,n,this._receivedLength)}}},{key:"_onLoadEnd",value:function(e){if(!0===this._requestAbort)return void(this._requestAbort=!1);this._status!==d.LoaderStatus.kError&&(this._status=d.LoaderStatus.kComplete,this._onComplete&&this._onComplete(this._range.from,this._range.from+this._receivedLength-1))}},{key:"_onXhrError",value:function(e){this._status=d.LoaderStatus.kError;var t=0,n=null;if(this._contentLength&&e.loaded<this._contentLength?(t=d.LoaderErrors.EARLY_EOF,n={code:-1,msg:"Moz-Chunked stream meet Early-Eof"}):(t=d.LoaderErrors.EXCEPTION,n={code:-1,msg:e.constructor.name+" "+e.type}),!this._onError)throw new f.RuntimeException(n.msg);this._onError(t,n)}}]),t}(d.BaseLoader);n.default=h},{"../utils/exception.js":40,"../utils/logger.js":41,"./loader.js":24}],30:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=e("../utils/logger.js"),c=function(e){return e&&e.__esModule?e:{default:e}}(l),d=e("./loader.js"),f=e("../utils/exception.js"),h=function(e){function t(e,n){r(this,t);var a=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"xhr-msstream-loader"));return a.TAG="MSStreamLoader",a._seekHandler=e,a._config=n,a._needStash=!0,a._xhr=null,a._reader=null,a._totalRange=null,a._currentRange=null,a._currentRequestURL=null,a._currentRedirectedURL=null,a._contentLength=null,a._receivedLength=0,a._bufferLimit=16777216,a._lastTimeBufferSize=0,a._isReconnecting=!1,a}return a(t,e),u(t,null,[{key:"isSupported",value:function(){try{if(void 0===self.MSStream||void 0===self.MSStreamReader)return!1;var e=new XMLHttpRequest;return e.open("GET","https://example.com",!0),e.responseType="ms-stream","ms-stream"===e.responseType}catch(e){return c.default.w("MSStreamLoader",e.message),!1}}}]),u(t,[{key:"destroy",value:function(){this.isWorking()&&this.abort(),this._reader&&(this._reader.onprogress=null,this._reader.onload=null,this._reader.onerror=null,this._reader=null),this._xhr&&(this._xhr.onreadystatechange=null,this._xhr=null),s(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"open",value:function(e,t){this._internalOpen(e,t,!1)}},{key:"_internalOpen",value:function(e,t,n){this._dataSource=e,n?this._currentRange=t:this._totalRange=t;var r=e.url;this._config.reuseRedirectedURL&&(void 0!=this._currentRedirectedURL?r=this._currentRedirectedURL:void 0!=e.redirectedURL&&(r=e.redirectedURL));var i=this._seekHandler.getConfig(r,t);this._currentRequestURL=i.url;var a=this._reader=new self.MSStreamReader;a.onprogress=this._msrOnProgress.bind(this),a.onload=this._msrOnLoad.bind(this),a.onerror=this._msrOnError.bind(this);var s=this._xhr=new XMLHttpRequest;if(s.open("GET",i.url,!0),s.responseType="ms-stream",s.onreadystatechange=this._xhrOnReadyStateChange.bind(this),s.onerror=this._xhrOnError.bind(this),e.withCredentials&&(s.withCredentials=!0),"object"===o(i.headers)){var u=i.headers;for(var l in u)u.hasOwnProperty(l)&&s.setRequestHeader(l,u[l])}if("object"===o(this._config.headers)){var c=this._config.headers;for(var f in c)c.hasOwnProperty(f)&&s.setRequestHeader(f,c[f])}this._isReconnecting?this._isReconnecting=!1:this._status=d.LoaderStatus.kConnecting,s.send()}},{key:"abort",value:function(){this._internalAbort(),this._status=d.LoaderStatus.kComplete}},{key:"_internalAbort",value:function(){this._reader&&(1===this._reader.readyState&&this._reader.abort(),this._reader.onprogress=null,this._reader.onload=null,this._reader.onerror=null,this._reader=null),this._xhr&&(this._xhr.abort(),this._xhr.onreadystatechange=null,this._xhr=null)}},{key:"_xhrOnReadyStateChange",value:function(e){var t=e.target;if(2===t.readyState)if(t.status>=200&&t.status<=299){if(this._status=d.LoaderStatus.kBuffering,void 0!=t.responseURL){var n=this._seekHandler.removeURLParameters(t.responseURL);t.responseURL!==this._currentRequestURL&&n!==this._currentRedirectedURL&&(this._currentRedirectedURL=n,this._onURLRedirect&&this._onURLRedirect(n))}var r=t.getResponseHeader("Content-Length");if(null!=r&&null==this._contentLength){var i=parseInt(r);i>0&&(this._contentLength=i,this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength))}}else{if(this._status=d.LoaderStatus.kError,!this._onError)throw new f.RuntimeException("MSStreamLoader: Http code invalid, "+t.status+" "+t.statusText);this._onError(d.LoaderErrors.HTTP_STATUS_CODE_INVALID,{code:t.status,msg:t.statusText})}else if(3===t.readyState&&t.status>=200&&t.status<=299){this._status=d.LoaderStatus.kBuffering;var a=t.response;this._reader.readAsArrayBuffer(a)}}},{key:"_xhrOnError",value:function(e){this._status=d.LoaderStatus.kError;var t=d.LoaderErrors.EXCEPTION,n={code:-1,msg:e.constructor.name+" "+e.type};if(!this._onError)throw new f.RuntimeException(n.msg);this._onError(t,n)}},{key:"_msrOnProgress",value:function(e){var t=e.target,n=t.result;if(null==n)return void this._doReconnectIfNeeded();var r=n.slice(this._lastTimeBufferSize);this._lastTimeBufferSize=n.byteLength;var i=this._totalRange.from+this._receivedLength;this._receivedLength+=r.byteLength,this._onDataArrival&&this._onDataArrival(r,i,this._receivedLength),n.byteLength>=this._bufferLimit&&(c.default.v(this.TAG,"MSStream buffer exceeded max size near "+(i+r.byteLength)+", reconnecting..."),this._doReconnectIfNeeded())}},{key:"_doReconnectIfNeeded",value:function(){if(null==this._contentLength||this._receivedLength<this._contentLength){this._isReconnecting=!0,this._lastTimeBufferSize=0,this._internalAbort();var e={from:this._totalRange.from+this._receivedLength,to:-1};this._internalOpen(this._dataSource,e,!0)}}},{key:"_msrOnLoad",value:function(e){this._status=d.LoaderStatus.kComplete,this._onComplete&&this._onComplete(this._totalRange.from,this._totalRange.from+this._receivedLength-1)}},{key:"_msrOnError",value:function(e){this._status=d.LoaderStatus.kError;var t=0,n=null;if(this._contentLength&&this._receivedLength<this._contentLength?(t=d.LoaderErrors.EARLY_EOF,n={code:-1,msg:"MSStream meet Early-Eof"}):(t=d.LoaderErrors.EARLY_EOF,n={code:-1,msg:e.constructor.name+" "+e.type}),!this._onError)throw new f.RuntimeException(n.msg);this._onError(t,n)}}]),t}(d.BaseLoader);n.default=h},{"../utils/exception.js":40,"../utils/logger.js":41,"./loader.js":24}],31:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},l=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=e("../utils/logger.js"),d=r(c),f=e("./speed-sampler.js"),h=r(f),p=e("./loader.js"),m=e("../utils/exception.js"),v=function(e){function t(e,n){i(this,t);var r=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"xhr-range-loader"));return r.TAG="RangeLoader",r._seekHandler=e,r._config=n,r._needStash=!1,r._chunkSizeKBList=[128,256,384,512,768,1024,1536,2048,3072,4096,5120,6144,7168,8192],r._currentChunkSizeKB=384,r._currentSpeedNormalized=0,r._zeroSpeedChunkCount=0,r._xhr=null,r._speedSampler=new h.default,r._requestAbort=!1,r._waitForTotalLength=!1,r._totalLengthReceived=!1,r._currentRequestURL=null,r._currentRedirectedURL=null,r._currentRequestRange=null,r._totalLength=null,r._contentLength=null,r._receivedLength=0,r._lastTimeLoaded=0,r}return o(t,e),l(t,null,[{key:"isSupported",value:function(){try{var e=new XMLHttpRequest;return e.open("GET","https://example.com",!0),e.responseType="arraybuffer","arraybuffer"===e.responseType}catch(e){return d.default.w("RangeLoader",e.message),!1}}}]),l(t,[{key:"destroy",value:function(){this.isWorking()&&this.abort(),this._xhr&&(this._xhr.onreadystatechange=null,this._xhr.onprogress=null,this._xhr.onload=null,this._xhr.onerror=null,this._xhr=null),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"open",value:function(e,t){this._dataSource=e,this._range=t,this._status=p.LoaderStatus.kConnecting;var n=!1;void 0!=this._dataSource.filesize&&0!==this._dataSource.filesize&&(n=!0,this._totalLength=this._dataSource.filesize),this._totalLengthReceived||n?this._openSubRange():(this._waitForTotalLength=!0,this._internalOpen(this._dataSource,{from:0,to:-1}))}},{key:"_openSubRange",value:function(){var e=1024*this._currentChunkSizeKB,t=this._range.from+this._receivedLength,n=t+e;null!=this._contentLength&&n-this._range.from>=this._contentLength&&(n=this._range.from+this._contentLength-1),this._currentRequestRange={from:t,to:n},this._internalOpen(this._dataSource,this._currentRequestRange)}},{key:"_internalOpen",value:function(e,t){this._lastTimeLoaded=0;var n=e.url;this._config.reuseRedirectedURL&&(void 0!=this._currentRedirectedURL?n=this._currentRedirectedURL:void 0!=e.redirectedURL&&(n=e.redirectedURL));var r=this._seekHandler.getConfig(n,t);this._currentRequestURL=r.url;var i=this._xhr=new XMLHttpRequest;if(i.open("GET",r.url,!0),i.responseType="arraybuffer",i.onreadystatechange=this._onReadyStateChange.bind(this),i.onprogress=this._onProgress.bind(this),i.onload=this._onLoad.bind(this),i.onerror=this._onXhrError.bind(this),e.withCredentials&&(i.withCredentials=!0),"object"===s(r.headers)){var a=r.headers;for(var o in a)a.hasOwnProperty(o)&&i.setRequestHeader(o,a[o])}if("object"===s(this._config.headers)){var u=this._config.headers;for(var l in u)u.hasOwnProperty(l)&&i.setRequestHeader(l,u[l])}i.send()}},{key:"abort",value:function(){this._requestAbort=!0,this._internalAbort(),this._status=p.LoaderStatus.kComplete}},{key:"_internalAbort",value:function(){this._xhr&&(this._xhr.onreadystatechange=null,this._xhr.onprogress=null,this._xhr.onload=null,this._xhr.onerror=null,this._xhr.abort(),this._xhr=null)}},{key:"_onReadyStateChange",value:function(e){var t=e.target;if(2===t.readyState){if(void 0!=t.responseURL){var n=this._seekHandler.removeURLParameters(t.responseURL);t.responseURL!==this._currentRequestURL&&n!==this._currentRedirectedURL&&(this._currentRedirectedURL=n,this._onURLRedirect&&this._onURLRedirect(n))}if(t.status>=200&&t.status<=299){if(this._waitForTotalLength)return;this._status=p.LoaderStatus.kBuffering}else{if(this._status=p.LoaderStatus.kError,!this._onError)throw new m.RuntimeException("RangeLoader: Http code invalid, "+t.status+" "+t.statusText);this._onError(p.LoaderErrors.HTTP_STATUS_CODE_INVALID,{code:t.status,msg:t.statusText})}}}},{key:"_onProgress",value:function(e){if(this._status!==p.LoaderStatus.kError){if(null===this._contentLength){var t=!1;if(this._waitForTotalLength){this._waitForTotalLength=!1,this._totalLengthReceived=!0,t=!0;var n=e.total;this._internalAbort(),null!=n&0!==n&&(this._totalLength=n)}if(-1===this._range.to?this._contentLength=this._totalLength-this._range.from:this._contentLength=this._range.to-this._range.from+1,t)return void this._openSubRange();this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength)}var r=e.loaded-this._lastTimeLoaded;this._lastTimeLoaded=e.loaded,this._speedSampler.addBytes(r)}}},{key:"_normalizeSpeed",value:function(e){var t=this._chunkSizeKBList,n=t.length-1,r=0,i=0,a=n;if(e<t[0])return t[0];for(;i<=a;){if((r=i+Math.floor((a-i)/2))===n||e>=t[r]&&e<t[r+1])return t[r];t[r]<e?i=r+1:a=r-1}}},{key:"_onLoad",value:function(e){if(this._status!==p.LoaderStatus.kError){if(this._waitForTotalLength)return void(this._waitForTotalLength=!1);this._lastTimeLoaded=0;var t=this._speedSampler.lastSecondKBps;if(0===t&&++this._zeroSpeedChunkCount>=3&&(t=this._speedSampler.currentKBps),0!==t){var n=this._normalizeSpeed(t);this._currentSpeedNormalized!==n&&(this._currentSpeedNormalized=n,this._currentChunkSizeKB=n)}var r=e.target.response,i=this._range.from+this._receivedLength;this._receivedLength+=r.byteLength;var a=!1;null!=this._contentLength&&this._receivedLength<this._contentLength?this._openSubRange():a=!0,this._onDataArrival&&this._onDataArrival(r,i,this._receivedLength),a&&(this._status=p.LoaderStatus.kComplete,this._onComplete&&this._onComplete(this._range.from,this._range.from+this._receivedLength-1))}}},{key:"_onXhrError",value:function(e){this._status=p.LoaderStatus.kError;var t=0,n=null;if(this._contentLength&&this._receivedLength>0&&this._receivedLength<this._contentLength?(t=p.LoaderErrors.EARLY_EOF,n={code:-1,msg:"RangeLoader meet Early-Eof"}):(t=p.LoaderErrors.EXCEPTION,n={code:-1,msg:e.constructor.name+" "+e.type}),!this._onError)throw new m.RuntimeException(n.msg);this._onError(t,n)}},{key:"currentSpeed",get:function(){return this._speedSampler.lastSecondKBps}}]),t}(p.BaseLoader);n.default=v},{"../utils/exception.js":40,"../utils/logger.js":41,"./loader.js":24,"./speed-sampler.js":27}],32:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=e("events"),u=r(s),l=e("../utils/logger.js"),c=r(l),d=e("../utils/browser.js"),f=r(d),h=e("./player-events.js"),p=r(h),m=e("../core/transmuxer.js"),v=r(m),g=e("../core/transmuxing-events.js"),y=r(g),_=e("../core/mse-controller.js"),b=r(_),T=e("../core/mse-events.js"),S=r(T),w=e("./player-errors.js"),k=e("../config.js"),E=e("../utils/exception.js"),A=function(){function e(t,n){if(i(this,e),this.TAG="FlvPlayer",this._type="FlvPlayer",this._emitter=new u.default,this._config=(0,k.createDefaultConfig)(),"object"===(void 0===n?"undefined":a(n))&&Object.assign(this._config,n),"flv"!==t.type.toLowerCase())throw new E.InvalidArgumentException("FlvPlayer requires an flv MediaDataSource input!");!0===t.isLive&&(this._config.isLive=!0),this.e={onvLoadedMetadata:this._onvLoadedMetadata.bind(this),onvSeeking:this._onvSeeking.bind(this),onvCanPlay:this._onvCanPlay.bind(this),onvStalled:this._onvStalled.bind(this),onvProgress:this._onvProgress.bind(this)},self.performance&&self.performance.now?this._now=self.performance.now.bind(self.performance):this._now=Date.now,this._pendingSeekTime=null,this._requestSetTime=!1,this._seekpointRecord=null,this._progressChecker=null,this._mediaDataSource=t,this._mediaElement=null,this._msectl=null,this._transmuxer=null,this._mseSourceOpened=!1,this._hasPendingLoad=!1,this._receivedCanPlay=!1,this._mediaInfo=null,this._statisticsInfo=null;var r=f.default.chrome&&(f.default.version.major<50||50===f.default.version.major&&f.default.version.build<2661);this._alwaysSeekKeyframe=!!(r||f.default.msedge||f.default.msie),this._alwaysSeekKeyframe&&(this._config.accurateSeek=!1)}return o(e,[{key:"destroy",value:function(){null!=this._progressChecker&&(window.clearInterval(this._progressChecker),this._progressChecker=null),this._transmuxer&&this.unload(),this._mediaElement&&this.detachMediaElement(),this.e=null,this._mediaDataSource=null,this._emitter.removeAllListeners(),this._emitter=null}},{key:"on",value:function(e,t){var n=this;e===p.default.MEDIA_INFO?null!=this._mediaInfo&&Promise.resolve().then(function(){n._emitter.emit(p.default.MEDIA_INFO,n.mediaInfo)}):e===p.default.STATISTICS_INFO&&null!=this._statisticsInfo&&Promise.resolve().then(function(){n._emitter.emit(p.default.STATISTICS_INFO,n.statisticsInfo)}),this._emitter.addListener(e,t)}},{key:"off",value:function(e,t){this._emitter.removeListener(e,t)}},{key:"attachMediaElement",value:function(e){var t=this;if(this._mediaElement=e,e.addEventListener("loadedmetadata",this.e.onvLoadedMetadata),e.addEventListener("seeking",this.e.onvSeeking),e.addEventListener("canplay",this.e.onvCanPlay),e.addEventListener("stalled",this.e.onvStalled),e.addEventListener("progress",this.e.onvProgress),this._msectl=new b.default(this._config),this._msectl.on(S.default.UPDATE_END,this._onmseUpdateEnd.bind(this)),this._msectl.on(S.default.BUFFER_FULL,this._onmseBufferFull.bind(this)),this._msectl.on(S.default.SOURCE_OPEN,function(){t._mseSourceOpened=!0,t._hasPendingLoad&&(t._hasPendingLoad=!1,t.load())}),this._msectl.on(S.default.ERROR,function(e){t._emitter.emit(p.default.ERROR,w.ErrorTypes.MEDIA_ERROR,w.ErrorDetails.MEDIA_MSE_ERROR,e)}),this._msectl.attachMediaElement(e),null!=this._pendingSeekTime)try{e.currentTime=this._pendingSeekTime,this._pendingSeekTime=null}catch(e){}}},{key:"detachMediaElement",value:function(){this._mediaElement&&(this._msectl.detachMediaElement(),this._mediaElement.removeEventListener("loadedmetadata",this.e.onvLoadedMetadata),this._mediaElement.removeEventListener("seeking",this.e.onvSeeking),this._mediaElement.removeEventListener("canplay",this.e.onvCanPlay),this._mediaElement.removeEventListener("stalled",this.e.onvStalled),this._mediaElement.removeEventListener("progress",this.e.onvProgress),this._mediaElement=null),this._msectl&&(this._msectl.destroy(),this._msectl=null)}},{key:"load",value:function(){var e=this,t=!1,n=0;if(!this._mediaElement)throw new E.IllegalStateException("HTMLMediaElement must be attached before load()!");if(this._transmuxer)throw new E.IllegalStateException("FlvPlayer.load() has been called, please call unload() first!");if(!this._hasPendingLoad){if(this._config.deferLoadAfterSourceOpen&&!1===this._mseSourceOpened)return void(this._hasPendingLoad=!0);this._mediaElement.readyState>0&&(this._requestSetTime=!0,this._mediaElement.currentTime=0),this._transmuxer=new v.default(this._mediaDataSource,this._config),this._transmuxer.on(y.default.INIT_SEGMENT,function(t,n){e._msectl.appendInitSegment(n)}),this._transmuxer.on(y.default.MEDIA_SEGMENT,function(r,i){if(e._msectl.appendMediaSegment(i),e._config.isLive&&"video"==i.type){flvjs.reconnect&&(e.dataRetryTimer&&(clearTimeout(e.dataRetryTimer),e.dataRetryTimer=0),e.dataRetryTimer=setTimeout(function(){e._mediaElement&&(e.unload(),e.load(),setTimeout(function(){e.play().catch(function(){})},1e3),console.log("reconnect"))},1e3));var a=e._mediaElement.currentTime,o=e._mediaElement.paused,s=i.info.beginPts-1e3*a;if(s>=3e3&&!t&&!o){if(n&&n==a)return void(s>=5e3&&e._emitter.emit(p.default.ERROR,w.ErrorTypes.OTHER_ERROR,"got wrong timestamp ",i.info.beginPts));var u=i.info.beginPts/1e3-1;c.default.w(e.TAG,"Live seems stuck at "+a+", try seek to "+u),t=!0,e._requestSetTime=!0,e.currentTime=u,n=a}else i.info.beginPts-1e3*a>=2e3&&t&&(t=!1)}if(e._config.lazyLoad&&!e._config.isLive){var a=e._mediaElement.currentTime;i.info.endDts>=1e3*(a+e._config.lazyLoadMaxDuration)&&null==e._progressChecker&&(c.default.v(e.TAG,"Maximum buffering duration exceeded, suspend transmuxing task"),e._suspendTransmuxer())}}),this._transmuxer.on(y.default.LOADING_COMPLETE,function(){e._msectl.endOfStream(),e._emitter.emit(p.default.LOADING_COMPLETE)}),this._transmuxer.on(y.default.RECOVERED_EARLY_EOF,function(){e._emitter.emit(p.default.RECOVERED_EARLY_EOF)}),this._transmuxer.on(y.default.IO_ERROR,function(t,n){e._emitter.emit(p.default.ERROR,w.ErrorTypes.NETWORK_ERROR,t,n)}),this._transmuxer.on(y.default.DEMUX_ERROR,function(t,n){e._emitter.emit(p.default.ERROR,w.ErrorTypes.MEDIA_ERROR,t,{code:-1,msg:n})}),this._transmuxer.on(y.default.MEDIA_INFO,function(t){e._mediaInfo=t,e._emitter.emit(p.default.MEDIA_INFO,Object.assign({},t))}),this._transmuxer.on(y.default.METADATA_ARRIVED,function(t){e._emitter.emit(p.default.METADATA_ARRIVED,t)}),this._transmuxer.on(y.default.SCRIPTDATA_ARRIVED,function(t){e._emitter.emit(p.default.SCRIPTDATA_ARRIVED,t)}),this._transmuxer.on(y.default.STATISTICS_INFO,function(t){e._statisticsInfo=e._fillStatisticsInfo(t),e._emitter.emit(p.default.STATISTICS_INFO,Object.assign({},e._statisticsInfo))}),this._transmuxer.on(y.default.RECOMMEND_SEEKPOINT,function(t){e._mediaElement&&!e._config.accurateSeek&&(console.log("recommend seekpoint",t/1e3),e._requestSetTime=!0,e._mediaElement.currentTime=t/1e3)}),this._transmuxer.open()}}},{key:"unload",value:function(){this._mediaElement&&this._mediaElement.pause(),this._msectl&&this._msectl.seek(0),this._transmuxer&&(this._transmuxer.close(),this._transmuxer.destroy(),this._transmuxer=null)}},{key:"play",value:function(){return this._mediaElement.play()}},{key:"pause",value:function(){this._mediaElement.pause()}},{key:"_fillStatisticsInfo",value:function(e){if(e.playerType=this._type,!(this._mediaElement instanceof HTMLVideoElement))return e;var t=!0,n=0,r=0;if(this._mediaElement.getVideoPlaybackQuality){var i=this._mediaElement.getVideoPlaybackQuality();n=i.totalVideoFrames,r=i.droppedVideoFrames}else void 0!=this._mediaElement.webkitDecodedFrameCount?(n=this._mediaElement.webkitDecodedFrameCount,r=this._mediaElement.webkitDroppedFrameCount):t=!1;return t&&(e.decodedFrames=n,e.droppedFrames=r),e}},{key:"_onmseUpdateEnd",value:function(){if(this._config.lazyLoad&&!this._config.isLive){for(var e=this._mediaElement.buffered,t=this._mediaElement.currentTime,n=0,r=0;r<e.length;r++){var i=e.start(r),a=e.end(r);if(i<=t&&t<a){n=a;break}}n>=t+this._config.lazyLoadMaxDuration&&null==this._progressChecker&&(c.default.v(this.TAG,"Maximum buffering duration exceeded, suspend transmuxing task"),this._suspendTransmuxer())}}},{key:"_onmseBufferFull",value:function(){c.default.v(this.TAG,"MSE SourceBuffer is full, suspend transmuxing task"),null==this._progressChecker&&this._suspendTransmuxer()}},{key:"_suspendTransmuxer",value:function(){this._transmuxer&&(this._transmuxer.pause(),null==this._progressChecker&&(this._progressChecker=window.setInterval(this._checkProgressAndResume.bind(this),1e3)))}},{key:"_checkProgressAndResume",value:function(){for(var e=this._mediaElement.currentTime,t=this._mediaElement.buffered,n=!1,r=0;r<t.length;r++){var i=t.start(r),a=t.end(r);if(e>=i&&e<a){e>=a-this._config.lazyLoadRecoverDuration&&(n=!0);break}}n&&(window.clearInterval(this._progressChecker),this._progressChecker=null,n&&(c.default.v(this.TAG,"Continue loading from paused position"),this._transmuxer.resume()))}},{key:"_isTimepointBuffered",value:function(e){for(var t=this._mediaElement.buffered,n=0;n<t.length;n++){var r=t.start(n),i=t.end(n);if(e>=r&&e<i)return!0}return!1}},{key:"_internalSeek",value:function(e){var t=this._isTimepointBuffered(e),n=!1,r=0;if(e<1&&this._mediaElement.buffered.length>0){var i=this._mediaElement.buffered.start(0);(i<1&&e<i||f.default.safari)&&(n=!0,r=f.default.safari?.1:i)}if(n)this._requestSetTime=!0,this._mediaElement.currentTime=r;else if(t){if(this._alwaysSeekKeyframe){var a=this._msectl.getNearestKeyframe(Math.floor(1e3*e));this._requestSetTime=!0,this._mediaElement.currentTime=null!=a?a.dts/1e3:e}else this._requestSetTime=!0,this._mediaElement.currentTime=e;null!=this._progressChecker&&this._checkProgressAndResume()}else null!=this._progressChecker&&(window.clearInterval(this._progressChecker),this._progressChecker=null),this._msectl.seek(e),this._transmuxer.seek(Math.floor(1e3*e)),this._config.accurateSeek&&(this._requestSetTime=!0,this._mediaElement.currentTime=e)}},{key:"_checkAndApplyUnbufferedSeekpoint",value:function(){if(this._seekpointRecord)if(this._seekpointRecord.recordTime<=this._now()-100){var e=this._mediaElement.currentTime;this._seekpointRecord=null,this._isTimepointBuffered(e)||(null!=this._progressChecker&&(window.clearTimeout(this._progressChecker),this._progressChecker=null),this._msectl.seek(e),this._transmuxer.seek(Math.floor(1e3*e)),this._config.accurateSeek&&(this._requestSetTime=!0,this._mediaElement.currentTime=e))}else window.setTimeout(this._checkAndApplyUnbufferedSeekpoint.bind(this),50)}},{key:"_checkAndResumeStuckPlayback",value:function(e){var t=this._mediaElement;if(e||!this._receivedCanPlay||t.readyState<2){var n=t.buffered;if(n.length>0&&t.currentTime<n.end(0)){if(this._config.isLive&&n.end(0)-t.currentTime>3600)return c.default.w(this.TAG,"Playback seems stuck at "+t.currentTime+", try seek to "+n.end(0)+", cancle"),this._mediaElement.removeEventListener("progress",this.e.onvProgress),void this._emitter.emit(p.default.ERROR,w.ErrorTypes.MEDIA_ERROR,"got wrong timestamp ",n.end(0));c.default.w(this.TAG,"Playback seems stuck at "+t.currentTime+", seek to "+n.end(0)),this._requestSetTime=!0,this._mediaElement.currentTime=n.end(0),this._mediaElement.removeEventListener("progress",this.e.onvProgress)}}else this._mediaElement.removeEventListener("progress",this.e.onvProgress)}},{key:"_onvLoadedMetadata",value:function(e){null!=this._pendingSeekTime&&(this._mediaElement.currentTime=this._pendingSeekTime,this._pendingSeekTime=null)}},{key:"_onvSeeking",value:function(e){var t=this._mediaElement.currentTime,n=this._mediaElement.buffered;if(this._requestSetTime)return void(this._requestSetTime=!1);if(t<1&&n.length>0){var r=n.start(0);if(r<1&&t<r||f.default.safari)return this._requestSetTime=!0,void(this._mediaElement.currentTime=f.default.safari?.1:r)}if(this._isTimepointBuffered(t)){if(this._alwaysSeekKeyframe){var i=this._msectl.getNearestKeyframe(Math.floor(1e3*t));null!=i&&(this._requestSetTime=!0,this._mediaElement.currentTime=i.dts/1e3)}return void(null!=this._progressChecker&&this._checkProgressAndResume())}this._seekpointRecord={seekPoint:t,recordTime:this._now()},window.setTimeout(this._checkAndApplyUnbufferedSeekpoint.bind(this),50)}},{key:"_onvCanPlay",value:function(e){this._receivedCanPlay=!0,this._mediaElement.removeEventListener("canplay",this.e.onvCanPlay)}},{key:"_onvStalled",value:function(e){this._checkAndResumeStuckPlayback(!0)}},{key:"_onvProgress",value:function(e){this._checkAndResumeStuckPlayback()}},{key:"type",get:function(){return this._type}},{key:"buffered",get:function(){return this._mediaElement.buffered}},{key:"duration",get:function(){return this._mediaElement.duration}},{key:"volume",get:function(){return this._mediaElement.volume},set:function(e){this._mediaElement.volume=e}},{key:"muted",get:function(){return this._mediaElement.muted},set:function(e){this._mediaElement.muted=e}},{key:"currentTime",get:function(){return this._mediaElement?this._mediaElement.currentTime:0},set:function(e){this._mediaElement?this._internalSeek(e):this._pendingSeekTime=e}},{key:"mediaInfo",get:function(){return Object.assign({},this._mediaInfo)}},{key:"statisticsInfo",get:function(){return null==this._statisticsInfo&&(this._statisticsInfo={}),this._statisticsInfo=this._fillStatisticsInfo(this._statisticsInfo),Object.assign({},this._statisticsInfo)}}]),e}();n.default=A},{"../config.js":5,"../core/mse-controller.js":9,"../core/mse-events.js":10,"../core/transmuxer.js":11,"../core/transmuxing-events.js":13,"../utils/browser.js":39,"../utils/exception.js":40,"../utils/logger.js":41,"./player-errors.js":34,"./player-events.js":35,events:2}],33:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=e("events"),u=r(s),l=e("./player-events.js"),c=r(l),d=e("../config.js"),f=e("../utils/exception.js"),h=function(){function e(t,n){if(i(this,e),this.TAG="NativePlayer",this._type="NativePlayer",this._emitter=new u.default,this._config=(0,d.createDefaultConfig)(),"object"===(void 0===n?"undefined":a(n))&&Object.assign(this._config,n),"flv"===t.type.toLowerCase())throw new f.InvalidArgumentException("NativePlayer does't support flv MediaDataSource input!");if(t.hasOwnProperty("segments"))throw new f.InvalidArgumentException("NativePlayer("+t.type+") doesn't support multipart playback!");this.e={onvLoadedMetadata:this._onvLoadedMetadata.bind(this)},this._pendingSeekTime=null,this._statisticsReporter=null,this._mediaDataSource=t,this._mediaElement=null}return o(e,[{key:"destroy",value:function(){this._mediaElement&&(this.unload(),this.detachMediaElement()),this.e=null,this._mediaDataSource=null,this._emitter.removeAllListeners(),this._emitter=null}},{key:"on",value:function(e,t){var n=this;e===c.default.MEDIA_INFO?null!=this._mediaElement&&0!==this._mediaElement.readyState&&Promise.resolve().then(function(){n._emitter.emit(c.default.MEDIA_INFO,n.mediaInfo)}):e===c.default.STATISTICS_INFO&&null!=this._mediaElement&&0!==this._mediaElement.readyState&&Promise.resolve().then(function(){n._emitter.emit(c.default.STATISTICS_INFO,n.statisticsInfo)}),this._emitter.addListener(e,t)}},{key:"off",value:function(e,t){this._emitter.removeListener(e,t)}},{key:"attachMediaElement",value:function(e){if(this._mediaElement=e,e.addEventListener("loadedmetadata",this.e.onvLoadedMetadata),null!=this._pendingSeekTime)try{e.currentTime=this._pendingSeekTime,this._pendingSeekTime=null}catch(e){}}},{key:"detachMediaElement",value:function(){this._mediaElement&&(this._mediaElement.src="",this._mediaElement.removeAttribute("src"),this._mediaElement.removeEventListener("loadedmetadata",this.e.onvLoadedMetadata),this._mediaElement=null),null!=this._statisticsReporter&&(window.clearInterval(this._statisticsReporter),this._statisticsReporter=null)}},{key:"load",value:function(){if(!this._mediaElement)throw new f.IllegalStateException("HTMLMediaElement must be attached before load()!");this._mediaElement.src=this._mediaDataSource.url,this._mediaElement.readyState>0&&(this._mediaElement.currentTime=0),this._mediaElement.preload="auto",this._mediaElement.load(),this._statisticsReporter=window.setInterval(this._reportStatisticsInfo.bind(this),this._config.statisticsInfoReportInterval)}},{key:"unload",value:function(){this._mediaElement&&(this._mediaElement.src="",this._mediaElement.removeAttribute("src")),null!=this._statisticsReporter&&(window.clearInterval(this._statisticsReporter),this._statisticsReporter=null)}},{key:"play",value:function(){return this._mediaElement.play()}},{key:"pause",value:function(){this._mediaElement.pause()}},{key:"_onvLoadedMetadata",value:function(e){null!=this._pendingSeekTime&&(this._mediaElement.currentTime=this._pendingSeekTime,this._pendingSeekTime=null),this._emitter.emit(c.default.MEDIA_INFO,this.mediaInfo)}},{key:"_reportStatisticsInfo",value:function(){this._emitter.emit(c.default.STATISTICS_INFO,this.statisticsInfo)}},{key:"type",get:function(){return this._type}},{key:"buffered",get:function(){return this._mediaElement.buffered}},{key:"duration",get:function(){return this._mediaElement.duration}},{key:"volume",get:function(){return this._mediaElement.volume},set:function(e){this._mediaElement.volume=e}},{key:"muted",get:function(){return this._mediaElement.muted},set:function(e){this._mediaElement.muted=e}},{key:"currentTime",get:function(){return this._mediaElement?this._mediaElement.currentTime:0},set:function(e){this._mediaElement?this._mediaElement.currentTime=e:this._pendingSeekTime=e}},{key:"mediaInfo",get:function(){var e=this._mediaElement instanceof HTMLAudioElement?"audio/":"video/",t={mimeType:e+this._mediaDataSource.type};return this._mediaElement&&(t.duration=Math.floor(1e3*this._mediaElement.duration),this._mediaElement instanceof HTMLVideoElement&&(t.width=this._mediaElement.videoWidth,t.height=this._mediaElement.videoHeight)),t}},{key:"statisticsInfo",get:function(){var e={playerType:this._type,url:this._mediaDataSource.url};if(!(this._mediaElement instanceof HTMLVideoElement))return e;var t=!0,n=0,r=0;if(this._mediaElement.getVideoPlaybackQuality){var i=this._mediaElement.getVideoPlaybackQuality();n=i.totalVideoFrames,r=i.droppedVideoFrames}else void 0!=this._mediaElement.webkitDecodedFrameCount?(n=this._mediaElement.webkitDecodedFrameCount,r=this._mediaElement.webkitDroppedFrameCount):t=!1;return t&&(e.decodedFrames=n,e.droppedFrames=r),e}}]),e}();n.default=h},{"../config.js":5,"../utils/exception.js":40,"./player-events.js":35,events:2}],34:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.ErrorDetails=n.ErrorTypes=void 0;var r=e("../io/loader.js"),i=e("../demux/demux-errors.js"),a=function(e){return e&&e.__esModule?e:{default:e}}(i);n.ErrorTypes={NETWORK_ERROR:"NetworkError",MEDIA_ERROR:"MediaError",OTHER_ERROR:"OtherError"},n.ErrorDetails={NETWORK_EXCEPTION:r.LoaderErrors.EXCEPTION,NETWORK_STATUS_CODE_INVALID:r.LoaderErrors.HTTP_STATUS_CODE_INVALID,NETWORK_TIMEOUT:r.LoaderErrors.CONNECTING_TIMEOUT,NETWORK_UNRECOVERABLE_EARLY_EOF:r.LoaderErrors.UNRECOVERABLE_EARLY_EOF,MEDIA_MSE_ERROR:"MediaMSEError",MEDIA_FORMAT_ERROR:a.default.FORMAT_ERROR,MEDIA_FORMAT_UNSUPPORTED:a.default.FORMAT_UNSUPPORTED,MEDIA_CODEC_UNSUPPORTED:a.default.CODEC_UNSUPPORTED}},{"../demux/demux-errors.js":16,"../io/loader.js":24}],35:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={ERROR:"error",LOADING_COMPLETE:"loading_complete",RECOVERED_EARLY_EOF:"recovered_early_eof",MEDIA_INFO:"media_info",METADATA_ARRIVED:"metadata_arrived",SCRIPTDATA_ARRIVED:"scriptdata_arrived",STATISTICS_INFO:"statistics_info"};n.default=r},{}],36:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return i(e,null,[{key:"getSilentFrame",value:function(e,t){if("mp4a.40.2"===e){if(1===t)return new Uint8Array([0,200,0,128,35,128]);if(2===t)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224])}else{if(1===t)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(3===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}return null}}]),e}();n.default=a},{}],37:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return i(e,null,[{key:"init",value:function(){e.types={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],sdtp:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[],smhd:[],".mp3":[]};for(var t in e.types)e.types.hasOwnProperty(t)&&(e.types[t]=[t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2),t.charCodeAt(3)]);var n=e.constants={};n.FTYP=new Uint8Array([105,115,111,109,0,0,0,1,105,115,111,109,97,118,99,49]),n.STSD_PREFIX=new Uint8Array([0,0,0,0,0,0,0,1]),n.STTS=new Uint8Array([0,0,0,0,0,0,0,0]),n.STSC=n.STCO=n.STTS,n.STSZ=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),n.HDLR_VIDEO=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),n.HDLR_AUDIO=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),n.DREF=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),n.SMHD=new Uint8Array([0,0,0,0,0,0,0,0]),n.VMHD=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}},{key:"box",value:function(e){for(var t=8,n=null,r=Array.prototype.slice.call(arguments,1),i=r.length,a=0;a<i;a++)t+=r[a].byteLength;n=new Uint8Array(t),n[0]=t>>>24&255,n[1]=t>>>16&255,n[2]=t>>>8&255,n[3]=255&t,n.set(e,4);for(var o=8,s=0;s<i;s++)n.set(r[s],o),o+=r[s].byteLength;return n}},{key:"generateInitSegment",value:function(t){var n=e.box(e.types.ftyp,e.constants.FTYP),r=e.moov(t),i=new Uint8Array(n.byteLength+r.byteLength);return i.set(n,0),i.set(r,n.byteLength),i}},{key:"moov",value:function(t){var n=e.mvhd(t.timescale,t.duration),r=e.trak(t),i=e.mvex(t);return e.box(e.types.moov,n,r,i)}},{key:"mvhd",value:function(t,n){return e.box(e.types.mvhd,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,t>>>24&255,t>>>16&255,t>>>8&255,255&t,n>>>24&255,n>>>16&255,n>>>8&255,255&n,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]))}},{key:"trak",value:function(t){return e.box(e.types.trak,e.tkhd(t),e.mdia(t))}},{key:"tkhd",value:function(t){var n=t.id,r=t.duration,i=t.presentWidth,a=t.presentHeight;return e.box(e.types.tkhd,new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,n>>>24&255,n>>>16&255,n>>>8&255,255&n,0,0,0,0,r>>>24&255,r>>>16&255,r>>>8&255,255&r,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,i>>>8&255,255&i,0,0,a>>>8&255,255&a,0,0]))}},{key:"mdia",value:function(t){return e.box(e.types.mdia,e.mdhd(t),e.hdlr(t),e.minf(t))}},{key:"mdhd",value:function(t){var n=t.timescale,r=t.duration;return e.box(e.types.mdhd,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,n>>>24&255,n>>>16&255,n>>>8&255,255&n,r>>>24&255,r>>>16&255,r>>>8&255,255&r,85,196,0,0]))}},{key:"hdlr",value:function(t){var n=null;return n="audio"===t.type?e.constants.HDLR_AUDIO:e.constants.HDLR_VIDEO,e.box(e.types.hdlr,n)}},{key:"minf",value:function(t){var n=null;return n="audio"===t.type?e.box(e.types.smhd,e.constants.SMHD):e.box(e.types.vmhd,e.constants.VMHD),e.box(e.types.minf,n,e.dinf(),e.stbl(t))}},{key:"dinf",value:function(){return e.box(e.types.dinf,e.box(e.types.dref,e.constants.DREF))}},{key:"stbl",value:function(t){return e.box(e.types.stbl,e.stsd(t),e.box(e.types.stts,e.constants.STTS),e.box(e.types.stsc,e.constants.STSC),e.box(e.types.stsz,e.constants.STSZ),e.box(e.types.stco,e.constants.STCO))}},{key:"stsd",value:function(t){return"audio"===t.type?"mp3"===t.codec?e.box(e.types.stsd,e.constants.STSD_PREFIX,e.mp3(t)):e.box(e.types.stsd,e.constants.STSD_PREFIX,e.mp4a(t)):e.box(e.types.stsd,e.constants.STSD_PREFIX,e.avc1(t))}},{key:"mp3",value:function(t){var n=t.channelCount,r=t.audioSampleRate,i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,n,0,16,0,0,0,0,r>>>8&255,255&r,0,0]);return e.box(e.types[".mp3"],i)}},{key:"mp4a",value:function(t){var n=t.channelCount,r=t.audioSampleRate,i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,n,0,16,0,0,0,0,r>>>8&255,255&r,0,0]);return e.box(e.types.mp4a,i,e.esds(t))}},{key:"esds",value:function(t){var n=t.config||[],r=n.length,i=new Uint8Array([0,0,0,0,3,23+r,0,1,0,4,15+r,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([r]).concat(n).concat([6,1,2]));return e.box(e.types.esds,i)}},{key:"avc1",value:function(t){var n=t.avcc,r=t.codecWidth,i=t.codecHeight,a=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,r>>>8&255,255&r,i>>>8&255,255&i,0,72,0,0,0,72,0,0,0,0,0,0,0,1,10,120,113,113,47,102,108,118,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,255,255]);return e.box(e.types.avc1,a,e.box(e.types.avcC,n))}},{key:"mvex",value:function(t){return e.box(e.types.mvex,e.trex(t))}},{key:"trex",value:function(t){var n=t.id,r=new Uint8Array([0,0,0,0,n>>>24&255,n>>>16&255,n>>>8&255,255&n,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return e.box(e.types.trex,r)}},{key:"moof",value:function(t,n){return e.box(e.types.moof,e.mfhd(t.sequenceNumber),e.traf(t,n))}},{key:"mfhd",value:function(t){var n=new Uint8Array([0,0,0,0,t>>>24&255,t>>>16&255,t>>>8&255,255&t]);return e.box(e.types.mfhd,n)}},{key:"traf",value:function(t,n){var r=t.id,i=e.box(e.types.tfhd,new Uint8Array([0,0,0,0,r>>>24&255,r>>>16&255,r>>>8&255,255&r])),a=e.box(e.types.tfdt,new Uint8Array([0,0,0,0,n>>>24&255,n>>>16&255,n>>>8&255,255&n])),o=e.sdtp(t),s=e.trun(t,o.byteLength+16+16+8+16+8+8);return e.box(e.types.traf,i,a,s,o)}},{key:"sdtp",value:function(t){for(var n=t.samples||[],r=n.length,i=new Uint8Array(4+r),a=0;a<r;a++){var o=n[a].flags;i[a+4]=o.isLeading<<6|o.dependsOn<<4|o.isDependedOn<<2|o.hasRedundancy}return e.box(e.types.sdtp,i)}},{key:"trun",value:function(t,n){var r=t.samples||[],i=r.length,a=12+16*i,o=new Uint8Array(a);n+=8+a,o.set([0,0,15,1,i>>>24&255,i>>>16&255,i>>>8&255,255&i,n>>>24&255,n>>>16&255,n>>>8&255,255&n],0);for(var s=0;s<i;s++){var u=r[s].duration,l=r[s].size,c=r[s].flags,d=r[s].cts;o.set([u>>>24&255,u>>>16&255,u>>>8&255,255&u,l>>>24&255,l>>>16&255,l>>>8&255,255&l,c.isLeading<<2|c.dependsOn,c.isDependedOn<<6|c.hasRedundancy<<4|c.isNonSync,0,0,d>>>24&255,d>>>16&255,d>>>8&255,255&d],12+16*s)}return e.box(e.types.trun,o)}},{key:"mdat",value:function(t){return e.box(e.types.mdat,t)}}]),e}();a.init(),n.default=a},{}],38:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("../utils/logger.js"),s=r(o),u=e("./mp4-generator.js"),l=r(u),c=e("./aac-silent.js"),d=r(c),f=e("../utils/browser.js"),h=r(f),p=e("../core/media-segment-info.js"),m=e("../utils/exception.js"),v=function(){function e(t){i(this,e),this.TAG="MP4Remuxer",this._config=t,this._isLive=!0===t.isLive,this._dtsBase=-1,this._dtsBaseInited=!1,this._audioDtsBase=1/0,this._videoDtsBase=1/0,this._audioNextDts=void 0,this._videoNextDts=void 0,this._audioStashedLastSample=null,this._videoStashedLastSample=null,this._audioMeta=null,this._videoMeta=null,this._audioSegmentInfoList=new p.MediaSegmentInfoList("audio"),this._videoSegmentInfoList=new p.MediaSegmentInfoList("video"),this._onInitSegment=null,this._onMediaSegment=null,this._forceFirstIDR=!(!h.default.chrome||!(h.default.version.major<50||50===h.default.version.major&&h.default.version.build<2661)),this._fillSilentAfterSeek=h.default.msedge||h.default.msie,this._mp3UseMpegAudio=!h.default.firefox,this._fillAudioTimestampGap=this._config.fixAudioTimestampGap}return a(e,[{key:"destroy",value:function(){this._dtsBase=-1,this._dtsBaseInited=!1,this._audioMeta=null,this._videoMeta=null,this._audioSegmentInfoList.clear(),this._audioSegmentInfoList=null,this._videoSegmentInfoList.clear(),this._videoSegmentInfoList=null,this._onInitSegment=null,this._onMediaSegment=null}},{key:"bindDataSource",value:function(e){return e.onDataAvailable=this.remux.bind(this),e.onTrackMetadata=this._onTrackMetadataReceived.bind(this),this}},{key:"insertDiscontinuity",value:function(){this._audioNextDts=this._videoNextDts=void 0}},{key:"seek",value:function(e){this._audioStashedLastSample=null,this._videoStashedLastSample=null,this._videoSegmentInfoList.clear(),this._audioSegmentInfoList.clear()}},{key:"remux",value:function(e,t){if(!this._onMediaSegment)throw new m.IllegalStateException("MP4Remuxer: onMediaSegment callback must be specificed!");this._dtsBaseInited||this._calculateDtsBase(e,t),this._remuxVideo(t),this._remuxAudio(e)}},{key:"_onTrackMetadataReceived",value:function(e,t){var n=null,r="mp4",i=t.codec;if("audio"===e)this._audioMeta=t,"mp3"===t.codec&&this._mp3UseMpegAudio?(r="mpeg",i="",n=new Uint8Array):n=l.default.generateInitSegment(t);else{if("video"!==e)return;this._videoMeta=t,n=l.default.generateInitSegment(t)}if(!this._onInitSegment)throw new m.IllegalStateException("MP4Remuxer: onInitSegment callback must be specified!");this._onInitSegment(e,{type:e,data:n.buffer,codec:i,container:e+"/"+r,mediaDuration:t.duration})}},{key:"_calculateDtsBase",value:function(e,t){this._dtsBaseInited||(e.samples&&e.samples.length&&(this._audioDtsBase=e.samples[0].dts),t.samples&&t.samples.length&&(this._videoDtsBase=t.samples[0].dts),this._dtsBase=Math.min(this._audioDtsBase,this._videoDtsBase),this._dtsBaseInited=!0)}},{key:"flushStashedSamples",value:function(){var e=this._videoStashedLastSample,t=this._audioStashedLastSample,n={type:"video",id:1,sequenceNumber:0,samples:[],length:0};null!=e&&(n.samples.push(e),n.length=e.length);var r={type:"audio",id:2,sequenceNumber:0,samples:[],length:0};null!=t&&(r.samples.push(t),r.length=t.length),this._videoStashedLastSample=null,this._audioStashedLastSample=null,this._remuxVideo(n,!0),this._remuxAudio(r,!0)}},{key:"_remuxAudio",value:function(e,t){if(null!=this._audioMeta){var n=e,r=n.samples,i=void 0,a=-1,o=-1,u=this._audioMeta.refSampleDuration,c="mp3"===this._audioMeta.codec&&this._mp3UseMpegAudio,f=this._dtsBaseInited&&void 0===this._audioNextDts,m=!1;if(r&&0!==r.length&&(1!==r.length||t)){var v=0,g=null,y=0;c?(v=0,y=n.length):(v=8,y=8+n.length);var _=null;if(r.length>1&&(_=r.pop(),y-=_.length),null!=this._audioStashedLastSample){var b=this._audioStashedLastSample;this._audioStashedLastSample=null,r.unshift(b),y+=b.length}null!=_&&(this._audioStashedLastSample=_);var T=r[0].dts-this._dtsBase;if(this._audioNextDts)i=T-this._audioNextDts;else if(this._audioSegmentInfoList.isEmpty())i=0,this._fillSilentAfterSeek&&!this._videoSegmentInfoList.isEmpty()&&"mp3"!==this._audioMeta.originalCodec&&(m=!0);else{var S=this._audioSegmentInfoList.getLastSampleBefore(T);if(null!=S){var w=T-(S.originalDts+S.duration);w<=3&&(w=0);var k=S.dts+S.duration+w;i=T-k}else i=0}if(m){var E=T-i,A=this._videoSegmentInfoList.getLastSegmentBefore(T);if(null!=A&&A.beginDts<E){var C=d.default.getSilentFrame(this._audioMeta.originalCodec,this._audioMeta.channelCount);if(C){var L=A.beginDts,x=E-A.beginDts;s.default.v(this.TAG,"InsertPrefixSilentAudio: dts: "+L+", duration: "+x),r.unshift({unit:C,dts:L,pts:L}),y+=C.byteLength}}else m=!1}for(var j=[],O=0;O<r.length;O++){var I=r[O],P=I.unit,R=I.dts-this._dtsBase,D=R,M=!1,U=null,B=0;if(!(R<-.001)){if("mp3"!==this._audioMeta.codec){var N=R;if(this._audioNextDts&&(N=this._audioNextDts),(i=R-N)<=-3*u){s.default.w(this.TAG,"Dropping 1 audio frame (originalDts: "+R+" ms ,curRefDts: "+N+" ms) due to dtsCorrection: "+i+" ms overlap.");continue}if(i>=3*u&&this._fillAudioTimestampGap&&!h.default.safari){M=!0;var F=Math.floor(i/u);s.default.w(this.TAG,"Large audio timestamp gap detected, may cause AV sync to drift. Silent frames will be generated to avoid unsync.\noriginalDts: "+R+" ms, curRefDts: "+N+" ms, dtsCorrection: "+Math.round(i)+" ms, generate: "+F+" frames"),D=Math.floor(N),B=Math.floor(N+u)-D;var V=d.default.getSilentFrame(this._audioMeta.originalCodec,this._audioMeta.channelCount);null==V&&(s.default.w(this.TAG,"Unable to generate silent frame for "+this._audioMeta.originalCodec+" with "+this._audioMeta.channelCount+" channels, repeat last frame"),V=P),U=[];for(var q=0;q<F;q++){N+=u;var G=Math.floor(N),H=Math.floor(N+u)-G,z={dts:G,pts:G,cts:0,unit:V,size:V.byteLength,duration:H,originalDts:R,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0}};U.push(z),y+=P.byteLength}this._audioNextDts=N+u}else D=Math.floor(N),B=Math.floor(N+u)-D,this._audioNextDts=N+u}else{if(D=R-i,O!==r.length-1)B=r[O+1].dts-this._dtsBase-i-D;else if(null!=_){var W=_.dts-this._dtsBase-i;B=W-D}else B=j.length>=1?j[j.length-1].duration:Math.floor(u);this._audioNextDts=D+B}-1===a&&(a=D),j.push({dts:D,pts:D,cts:0,unit:I.unit,size:I.unit.byteLength,duration:B,originalDts:R,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0}}),M&&j.push.apply(j,U)}}if(0===j.length)return n.samples=[],void(n.length=0);c?g=new Uint8Array(y):(g=new Uint8Array(y),g[0]=y>>>24&255,g[1]=y>>>16&255,g[2]=y>>>8&255,g[3]=255&y,g.set(l.default.types.mdat,4));for(var $=0;$<j.length;$++){var Y=j[$].unit;g.set(Y,v),v+=Y.byteLength}var K=j[j.length-1];o=K.dts+K.duration;var X=new p.MediaSegmentInfo;X.beginDts=a,X.endDts=o,X.beginPts=a,X.endPts=o,X.originalBeginDts=j[0].originalDts,X.originalEndDts=K.originalDts+K.duration,X.firstSample=new p.SampleInfo(j[0].dts,j[0].pts,j[0].duration,j[0].originalDts,!1),X.lastSample=new p.SampleInfo(K.dts,K.pts,K.duration,K.originalDts,!1),this._isLive||this._audioSegmentInfoList.append(X),n.samples=j,n.sequenceNumber++;var J=null;J=c?new Uint8Array:l.default.moof(n,a),n.samples=[],n.length=0;var Q={type:"audio",data:this._mergeBoxes(J,g).buffer,sampleCount:j.length,info:X};c&&f&&(Q.timestampOffset=a),this._onMediaSegment("audio",Q)}}}},{key:"_remuxVideo",value:function(e,t){if(null!=this._videoMeta){var n=e,r=n.samples,i=void 0,a=-1,o=-1,s=-1,u=-1;if(r&&0!==r.length&&(1!==r.length||t)){var c=8,d=null,f=8+e.length,h=null;if(r.length>1&&(h=r.pop(),f-=h.length),null!=this._videoStashedLastSample){var m=this._videoStashedLastSample;this._videoStashedLastSample=null,r.unshift(m),f+=m.length}null!=h&&(this._videoStashedLastSample=h);var v=r[0].dts-this._dtsBase;if(this._videoNextDts)i=v-this._videoNextDts;else if(this._videoSegmentInfoList.isEmpty())i=0;else{var g=this._videoSegmentInfoList.getLastSampleBefore(v);if(null!=g){var y=v-(g.originalDts+g.duration);y<=3&&(y=0);var _=g.dts+g.duration+y;i=v-_}else i=0}for(var b=new p.MediaSegmentInfo,T=[],S=0;S<r.length;S++){var w=r[S],k=w.dts-this._dtsBase,E=w.isKeyframe,A=k-i,C=w.cts,L=A+C;-1===a&&(a=A,s=L);var x=0;if(S!==r.length-1)x=r[S+1].dts-this._dtsBase-i-A;else if(null!=h){var j=h.dts-this._dtsBase-i;x=j-A}else x=T.length>=1?T[T.length-1].duration:Math.floor(this._videoMeta.refSampleDuration);if(E){var O=new p.SampleInfo(A,L,x,w.dts,!0);O.fileposition=w.fileposition,b.appendSyncPoint(O)}T.push({dts:A,pts:L,cts:C,units:w.units,size:w.length,isKeyframe:E,duration:x,originalDts:k,flags:{isLeading:0,dependsOn:E?2:1,isDependedOn:E?1:0,hasRedundancy:0,isNonSync:E?0:1}})}d=new Uint8Array(f),d[0]=f>>>24&255,d[1]=f>>>16&255,d[2]=f>>>8&255,d[3]=255&f,d.set(l.default.types.mdat,4);for(var I=0;I<T.length;I++)for(var P=T[I].units;P.length;){var R=P.shift(),D=R.data;d.set(D,c),c+=D.byteLength}var M=T[T.length-1];if(o=M.dts+M.duration,u=M.pts+M.duration,this._videoNextDts=o,b.beginDts=a,b.endDts=o,b.beginPts=s,b.endPts=u,b.originalBeginDts=T[0].originalDts,b.originalEndDts=M.originalDts+M.duration,b.firstSample=new p.SampleInfo(T[0].dts,T[0].pts,T[0].duration,T[0].originalDts,T[0].isKeyframe),b.lastSample=new p.SampleInfo(M.dts,M.pts,M.duration,M.originalDts,M.isKeyframe),this._isLive||this._videoSegmentInfoList.append(b),n.samples=T,n.sequenceNumber++,this._forceFirstIDR){var U=T[0].flags;U.dependsOn=2,U.isNonSync=0}var B=l.default.moof(n,a);n.samples=[],n.length=0,this._onMediaSegment("video",{type:"video",data:this._mergeBoxes(B,d).buffer,sampleCount:T.length,info:b})}}}},{key:"_mergeBoxes",value:function(e,t){var n=new Uint8Array(e.byteLength+t.byteLength);return n.set(e,0),n.set(t,e.byteLength),n}},{key:"onInitSegment",get:function(){return this._onInitSegment},set:function(e){this._onInitSegment=e}},{key:"onMediaSegment",get:function(){return this._onMediaSegment},set:function(e){this._onMediaSegment=e}}]),e}();n.default=v},{"../core/media-segment-info.js":8,"../utils/browser.js":39,"../utils/exception.js":40,"../utils/logger.js":41,"./aac-silent.js":36,"./mp4-generator.js":37}],39:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={};!function(){var e=self.navigator.userAgent.toLowerCase(),t=/(edge)\/([\w.]+)/.exec(e)||/(opr)[\/]([\w.]+)/.exec(e)||/(chrome)[ \/]([\w.]+)/.exec(e)||/(iemobile)[\/]([\w.]+)/.exec(e)||/(version)(applewebkit)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(e)||/(webkit)[ \/]([\w.]+).*(version)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(e)||/(webkit)[ \/]([\w.]+)/.exec(e)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(e)||/(msie) ([\w.]+)/.exec(e)||e.indexOf("trident")>=0&&/(rv)(?::| )([\w.]+)/.exec(e)||e.indexOf("compatible")<0&&/(firefox)[ \/]([\w.]+)/.exec(e)||[],n=/(ipad)/.exec(e)||/(ipod)/.exec(e)||/(windows phone)/.exec(e)||/(iphone)/.exec(e)||/(kindle)/.exec(e)||/(android)/.exec(e)||/(windows)/.exec(e)||/(mac)/.exec(e)||/(linux)/.exec(e)||/(cros)/.exec(e)||[],i={browser:t[5]||t[3]||t[1]||"",version:t[2]||t[4]||"0",majorVersion:t[4]||t[2]||"0",platform:n[0]||""},a={};if(i.browser){a[i.browser]=!0;var o=i.majorVersion.split(".");a.version={major:parseInt(i.majorVersion,10),string:i.version},o.length>1&&(a.version.minor=parseInt(o[1],10)),o.length>2&&(a.version.build=parseInt(o[2],10))}i.platform&&(a[i.platform]=!0),(a.chrome||a.opr||a.safari)&&(a.webkit=!0),(a.rv||a.iemobile)&&(a.rv&&delete a.rv,i.browser="msie",a.msie=!0),a.edge&&(delete a.edge,i.browser="msedge",a.msedge=!0),a.opr&&(i.browser="opera",a.opera=!0),a.safari&&a.android&&(i.browser="android",a.android=!0),a.name=i.browser,a.platform=i.platform;for(var s in r)r.hasOwnProperty(s)&&delete r[s];Object.assign(r,a)}(),n.default=r},{}],40:[function(e,t,n){"use strict";function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=n.RuntimeException=function(){function e(t){a(this,e),this._message=t}return o(e,[{key:"toString",value:function(){return this.name+": "+this.message}},{key:"name",get:function(){return"RuntimeException"}},{key:"message",get:function(){return this._message}}]),e}();n.IllegalStateException=function(e){function t(e){return a(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e))}return i(t,e),o(t,[{key:"name",get:function(){return"IllegalStateException"}}]),t}(s),n.InvalidArgumentException=function(e){function t(e){return a(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e))}return i(t,e),o(t,[{key:"name",get:function(){return"InvalidArgumentException"}}]),t}(s),n.NotImplementedException=function(e){function t(e){return a(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e))}return i(t,e),o(t,[{key:"name",get:function(){return"NotImplementedException"}}]),t}(s)},{}],41:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=e("events"),o=function(e){return e&&e.__esModule?e:{default:e}}(a),s=function(){function e(){r(this,e)}return i(e,null,[{key:"e",value:function(t,n){t&&!e.FORCE_GLOBAL_TAG||(t=e.GLOBAL_TAG);var r="["+t+"] > "+n;e.ENABLE_CALLBACK&&e.emitter.emit("log","error",r),e.ENABLE_ERROR&&(console.error?console.error(r):console.warn?console.warn(r):console.log(r))}},{key:"i",value:function(t,n){t&&!e.FORCE_GLOBAL_TAG||(t=e.GLOBAL_TAG);var r="["+t+"] > "+n;e.ENABLE_CALLBACK&&e.emitter.emit("log","info",r),e.ENABLE_INFO&&(console.info?console.info(r):console.log(r))}},{key:"w",value:function(t,n){t&&!e.FORCE_GLOBAL_TAG||(t=e.GLOBAL_TAG);var r="["+t+"] > "+n;e.ENABLE_CALLBACK&&e.emitter.emit("log","warn",r),e.ENABLE_WARN&&(console.warn?console.warn(r):console.log(r))}},{key:"d",value:function(t,n){t&&!e.FORCE_GLOBAL_TAG||(t=e.GLOBAL_TAG);var r="["+t+"] > "+n;e.ENABLE_CALLBACK&&e.emitter.emit("log","debug",r),e.ENABLE_DEBUG&&(console.debug?console.debug(r):console.log(r))}},{key:"v",value:function(t,n){t&&!e.FORCE_GLOBAL_TAG||(t=e.GLOBAL_TAG);var r="["+t+"] > "+n;e.ENABLE_CALLBACK&&e.emitter.emit("log","verbose",r),e.ENABLE_VERBOSE&&console.log(r)}}]),e}();s.GLOBAL_TAG="flv.js",s.FORCE_GLOBAL_TAG=!1,s.ENABLE_ERROR=!0,s.ENABLE_INFO=!0,s.ENABLE_WARN=!0,s.ENABLE_DEBUG=!0,s.ENABLE_VERBOSE=!0,s.ENABLE_CALLBACK=!1,s.emitter=new o.default,n.default=s},{events:2}],42:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("events"),s=r(o),u=e("./logger.js"),l=r(u),c=function(){function e(){i(this,e)}return a(e,null,[{key:"getConfig",value:function(){return{globalTag:l.default.GLOBAL_TAG,forceGlobalTag:l.default.FORCE_GLOBAL_TAG,enableVerbose:l.default.ENABLE_VERBOSE,enableDebug:l.default.ENABLE_DEBUG,enableInfo:l.default.ENABLE_INFO,enableWarn:l.default.ENABLE_WARN,enableError:l.default.ENABLE_ERROR,enableCallback:l.default.ENABLE_CALLBACK}}},{key:"applyConfig",value:function(e){l.default.GLOBAL_TAG=e.globalTag,l.default.FORCE_GLOBAL_TAG=e.forceGlobalTag,l.default.ENABLE_VERBOSE=e.enableVerbose,l.default.ENABLE_DEBUG=e.enableDebug,l.default.ENABLE_INFO=e.enableInfo,l.default.ENABLE_WARN=e.enableWarn,l.default.ENABLE_ERROR=e.enableError,l.default.ENABLE_CALLBACK=e.enableCallback}},{key:"_notifyChange",value:function(){var t=e.emitter;if(t.listenerCount("change")>0){var n=e.getConfig();t.emit("change",n)}}},{key:"registerListener",value:function(t){e.emitter.addListener("change",t)}},{key:"removeListener",value:function(t){e.emitter.removeListener("change",t)}},{key:"addLogListener",value:function(t){l.default.emitter.addListener("log",t),l.default.emitter.listenerCount("log")>0&&(l.default.ENABLE_CALLBACK=!0,e._notifyChange())}},{key:"removeLogListener",value:function(t){l.default.emitter.removeListener("log",t),0===l.default.emitter.listenerCount("log")&&(l.default.ENABLE_CALLBACK=!1,e._notifyChange())}},{key:"forceGlobalTag",get:function(){return l.default.FORCE_GLOBAL_TAG},set:function(t){l.default.FORCE_GLOBAL_TAG=t,e._notifyChange()}},{key:"globalTag",get:function(){return l.default.GLOBAL_TAG},set:function(t){l.default.GLOBAL_TAG=t,e._notifyChange()}},{key:"enableAll",get:function(){return l.default.ENABLE_VERBOSE&&l.default.ENABLE_DEBUG&&l.default.ENABLE_INFO&&l.default.ENABLE_WARN&&l.default.ENABLE_ERROR},set:function(t){l.default.ENABLE_VERBOSE=t,l.default.ENABLE_DEBUG=t,l.default.ENABLE_INFO=t,l.default.ENABLE_WARN=t,l.default.ENABLE_ERROR=t,e._notifyChange()}},{key:"enableDebug",get:function(){return l.default.ENABLE_DEBUG},set:function(t){l.default.ENABLE_DEBUG=t,e._notifyChange()}},{key:"enableVerbose",get:function(){return l.default.ENABLE_VERBOSE},set:function(t){l.default.ENABLE_VERBOSE=t,e._notifyChange()}},{key:"enableInfo",get:function(){return l.default.ENABLE_INFO},set:function(t){l.default.ENABLE_INFO=t,e._notifyChange()}},{key:"enableWarn",get:function(){return l.default.ENABLE_WARN},set:function(t){l.default.ENABLE_WARN=t,e._notifyChange()}},{key:"enableError",get:function(){return l.default.ENABLE_ERROR},set:function(t){l.default.ENABLE_ERROR=t,e._notifyChange()}}]),e}();c.emitter=new s.default,n.default=c},{"./logger.js":41,events:2}],43:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function t(){r(this,t)}return i(t,null,[{key:"install",value:function(){Object.setPrototypeOf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Object.assign=Object.assign||function(e){if(void 0===e||null===e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),n=1;n<arguments.length;n++){var r=arguments[n];if(void 0!==r&&null!==r)for(var i in r)r.hasOwnProperty(i)&&(t[i]=r[i])}return t},"function"!=typeof self.Promise&&e("es6-promise").polyfill()}}]),t}();a.install(),n.default=a},{"es6-promise":1}],44:[function(e,t,n){"use strict";function r(e,t,n){var r=e;if(t+n<r.length){for(;n--;)if(128!=(192&r[++t]))return!1;return!0}return!1}function i(e){for(var t=[],n=e,i=0,a=e.length;i<a;)if(n[i]<128)t.push(String.fromCharCode(n[i])),++i;else{if(n[i]<192);else if(n[i]<224){if(r(n,i,1)){var o=(31&n[i])<<6|63&n[i+1];if(o>=128){t.push(String.fromCharCode(65535&o)),i+=2;continue}}}else if(n[i]<240){if(r(n,i,2)){var s=(15&n[i])<<12|(63&n[i+1])<<6|63&n[i+2];if(s>=2048&&55296!=(63488&s)){t.push(String.fromCharCode(65535&s)),i+=3;continue}}}else if(n[i]<248&&r(n,i,3)){var u=(7&n[i])<<18|(63&n[i+1])<<12|(63&n[i+2])<<6|63&n[i+3];if(u>65536&&u<1114112){u-=65536,t.push(String.fromCharCode(u>>>10|55296)),t.push(String.fromCharCode(1023&u|56320)),i+=4;continue}}t.push(String.fromCharCode(65533)),++i}return t.join("")}Object.defineProperty(n,"__esModule",{value:!0}),n.default=i},{}]},{},[21])(21)}),function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("video.js")):"function"==typeof define&&define.amd?define(["video.js"],t):e.videojsFlash=t(e.videojs)}(this,function(e){"use strict";function t(e){g[e]=function(){return this.el_.vjs_getProperty(e)}}e=e&&e.hasOwnProperty("default")?e.default:e;var n,r="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};n="undefined"!=typeof window?window:void 0!==r?r:"undefined"!=typeof self?self:{};for(var i=n,a=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},o=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)},s=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t},u=e.getComponent("Tech"),l=e.dom,c=e.url,d=e.createTimeRange,f=e.mergeOptions,h=i&&i.navigator||{},p=function(e){function t(n,r){a(this,t);var o=s(this,e.call(this,n,r));return n.source&&o.ready(function(){this.setSource(n.source)},!0),n.startTime&&o.ready(function(){this.load(),this.play(),this.currentTime(n.startTime)},!0),i.videojs=i.videojs||{},i.videojs.Flash=i.videojs.Flash||{},i.videojs.Flash.onReady=t.onReady,i.videojs.Flash.onEvent=t.onEvent,i.videojs.Flash.onError=t.onError,o.on("seeked",function(){this.lastSeekTarget_=void 0}),o}return o(t,e),t.prototype.createEl=function(){var e=this.options_;e.swf||(e.swf="https://vjs.zencdn.net/swf/5.4.2/video-js.swf");var n=e.techId,r=f({readyFunction:"videojs.Flash.onReady",eventProxyFunction:"videojs.Flash.onEvent",errorEventProxyFunction:"videojs.Flash.onError",autoplay:e.autoplay,stretch:e.stretch||!1,fluent:e.fluent||!1,preload:e.preload,loop:e.loop,muted:e.muted},e.flashVars),i=f({wmode:"opaque",bgcolor:"#000000"},e.params),a=f({id:n,name:n,class:"vjs-tech"},e.attributes);return this.el_=t.embed(e.swf,r,i,a),this.el_.tech=this,this.el_},t.prototype.play=function(){this.ended()&&this.setCurrentTime(0),this.el_.vjs_play()},t.prototype.pause=function(){this.el_.vjs_pause()},t.prototype.src=function(e){return void 0===e?this.currentSrc():this.setSrc(e)},t.prototype.setSrc=function(e){var t=this;e=c.getAbsoluteURL(e),this.el_.vjs_src(e),this.autoplay()&&this.setTimeout(function(){return t.play()},0)},t.prototype.seeking=function(){return void 0!==this.lastSeekTarget_},t.prototype.setCurrentTime=function(t){var n=this.seekable();n.length&&(t=t>n.start(0)?t:n.start(0),t=t<n.end(n.length-1)?t:n.end(n.length-1),this.lastSeekTarget_=t,this.trigger("seeking"),this.el_.vjs_setProperty("currentTime",t),e.prototype.setCurrentTime.call(this))},t.prototype.currentTime=function(){return this.seeking()?this.lastSeekTarget_||0:this.el_.vjs_getProperty("currentTime")},t.prototype.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.vjs_getProperty("currentSrc")},t.prototype.duration=function(){if(0===this.readyState())return NaN;var e=this.el_.vjs_getProperty("duration");return e>=0?e:1/0},t.prototype.load=function(){this.el_.vjs_load()},t.prototype.poster=function(){this.el_.vjs_getProperty("poster")},t.prototype.setPoster=function(){},t.prototype.seekable=function(){var e=this.duration();return 0===e?d():d(0,e)},t.prototype.buffered=function(){var e=this.el_.vjs_getProperty("buffered");return 0===e.length?d():d(e[0][0],e[0][1])},t.prototype.supportsFullScreen=function(){return!1},t.prototype.enterFullScreen=function(){return!1},t.prototype.getVideoPlaybackQuality=function(){var e=this.el_.vjs_getProperty("getVideoPlaybackQuality");return i.performance&&"function"==typeof i.performance.now?e.creationTime=i.performance.now():i.performance&&i.performance.timing&&"number"==typeof i.performance.timing.navigationStart&&(e.creationTime=i.Date.now()-i.performance.timing.navigationStart),e},t}(u),m=["rtmpConnection","rtmpStream","preload","defaultPlaybackRate","playbackRate","autoplay","stretch","fluent","loop","controls","volume","muted","defaultMuted"],v=["networkState","readyState","initialTime","startOffsetTime","paused","ended","videoWidth","videoHeight"],g=p.prototype,y=0;y<m.length;y++)t(m[y]),function(e){var t=e.charAt(0).toUpperCase()+e.slice(1);g["set"+t]=function(t){return this.el_.vjs_setProperty(e,t)}}(m[y]);for(var _=0;_<v.length;_++)t(v[_]);return p.isSupported=function(){return!!(e.browser.IS_CHROME&&!e.browser.IS_ANDROID||e.browser.IS_SAFARI&&!e.browser.IS_IOS)||p.version()[0]>=10},u.withSourceHandlers(p),p.nativeSourceHandler={},p.nativeSourceHandler.canPlayType=function(e){return e in p.formats?"maybe":""},p.nativeSourceHandler.canHandleSource=function(e,t){var n=void 0;return n=e.type?e.type.replace(/;.*/,"").toLowerCase():function(e){var t=c.getFileExtension(e);return t?"video/"+t:""}(e.src),p.nativeSourceHandler.canPlayType(n)},p.nativeSourceHandler.handleSource=function(e,t,n){t.setSrc(e.src)},p.nativeSourceHandler.dispose=function(){},p.registerSourceHandler(p.nativeSourceHandler),p.formats={"video/flv":"FLV","video/x-flv":"FLV","video/mp4":"MP4","video/m4v":"MP4"},p.onReady=function(e){var t=l.$("#"+e),n=t&&t.tech;n&&n.el()&&p.checkReady(n)},p.checkReady=function(e){e.el()&&(e.el().vjs_getProperty?e.triggerReady():this.setTimeout(function(){p.checkReady(e)},50))},p.onEvent=function(e,t){var n=l.$("#"+e).tech,r=Array.prototype.slice.call(arguments,2);n.setTimeout(function(){n.trigger(t,r)},1)},p.onError=function(e,t){var n=l.$("#"+e).tech;if("srcnotfound"===t)return n.error(4);"string"==typeof t?n.error("FLASH: "+t):(t.origin="flash",n.error(t))},p.version=function(){var e="0,0,0";try{e=new i.ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version").replace(/\D+/g,",").match(/^,?(.+),?$/)[1]}catch(t){try{h.mimeTypes["application/x-shockwave-flash"].enabledPlugin&&(e=(h.plugins["Shockwave Flash 2.0"]||h.plugins["Shockwave Flash"]).description.replace(/\D+/g,",").match(/^,?(.+),?$/)[1])}catch(e){}}return e.split(",")},p.embed=function(e,t,n,r){var i=p.getEmbedCode(e,t,n,r);return l.createEl("div",{innerHTML:i}).childNodes[0]},p.getEmbedCode=function(e,t,n,r){var i="",a="",o="";return t&&Object.getOwnPropertyNames(t).forEach(function(e){i+=e+"="+t[e]+"&amp;"}),n=f({movie:e,flashvars:i,allowScriptAccess:"always",allowNetworking:"all"},n),Object.getOwnPropertyNames(n).forEach(function(e){a+='<param name="'+e+'" value="'+n[e]+'" />'}),r=f({data:e,width:"100%",height:"100%"},r),Object.getOwnPropertyNames(r).forEach(function(e){o+=e+'="'+r[e]+'" '}),'<object type="application/x-shockwave-flash" '+o+">"+a+"</object>"},function(e){e.streamingFormats={"rtmp/mp4":"MP4","rtmp/flv":"FLV"},e.streamFromParts=function(e,t){return e+"&"+t},e.streamToParts=function(e){var t={connection:"",stream:""};if(!e)return t;var n=e.search(/&(?![\w-]+=)/),r=void 0;return-1!==n?r=n+1:0===(n=r=e.lastIndexOf("/")+1)&&(n=r=e.length),t.connection=e.substring(0,n),t.stream=e.substring(r,e.length),t},e.isStreamingType=function(t){return t in e.streamingFormats},e.RTMP_RE=/^rtmp[set]?:\/\//i,e.isStreamingSrc=function(t){return e.RTMP_RE.test(t)},e.rtmpSourceHandler={},e.rtmpSourceHandler.canPlayType=function(t){return e.isStreamingType(t)?"maybe":""},e.rtmpSourceHandler.canHandleSource=function(t,n){return e.rtmpSourceHandler.canPlayType(t.type)||(e.isStreamingSrc(t.src)?"maybe":"")},e.rtmpSourceHandler.handleSource=function(t,n,r){var i=e.streamToParts(t.src);n.setRtmpConnection(i.connection),n.setRtmpStream(i.stream)},e.registerSourceHandler(e.rtmpSourceHandler)}(p),u.getTech("Flash")?(e.log.warn("Not using videojs-flash as it appears to already be registered"),e.log.warn("videojs-flash should only be used with video.js@6 and above")):e.registerTech("Flash",p),p.VERSION="2.1.2",p}),function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.videojsContribHls=e()}}(function(){var e;return function e(t,n,r){function i(o,s){if(!n[o]){if(!t[o]){var u="function"==typeof require&&require;if(!s&&u)return u(o,!0);if(a)return a(o,!0);var l=new Error("Cannot find module '"+o+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[o]={exports:{}};t[o][0].call(c.exports,function(e){return i(t[o][1][e]||e)},c,c.exports,e,t,n,r)}return n[o].exports}for(var a="function"==typeof require&&require,o=0;o<r.length;o++)i(r[o]);return i}({1:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function e(e,t){var n=[],r=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(r=(o=s.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){i=!0,a=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw a}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),i=e("global/window"),a=function(e){return e&&e.__esModule?e:{default:e}}(i),o=function(e,t){for(var n=e.cues,r=0;r<n.length;r++){var i=n[r];if(t>=i.adStartTime&&t<=i.adEndTime)return i}return null},s=function(e,t){var n=arguments.length<=2||void 0===arguments[2]?0:arguments[2];if(e.segments)for(var i=n,s=void 0,u=0;u<e.segments.length;u++){var l=e.segments[u];if(s||(s=o(t,i+l.duration/2)),s){if("cueIn"in l){s.endTime=i,s.adEndTime=i,i+=l.duration,s=null;continue}if(i<s.endTime){i+=l.duration;continue}s.endTime+=l.duration}else if("cueOut"in l&&(s=new a.default.VTTCue(i,i+l.duration,l.cueOut),s.adStartTime=i,s.adEndTime=i+parseFloat(l.cueOut),t.addCue(s)),"cueOutCont"in l){var c=void 0,d=void 0,f=l.cueOutCont.split("/").map(parseFloat),h=r(f,2);c=h[0],d=h[1],s=new a.default.VTTCue(i,i+l.duration,""),s.adStartTime=i-c,s.adEndTime=s.adStartTime+d,t.addCue(s)}i+=l.duration}};n.default={updateAdCues:s,findAdCue:o},t.exports=n.default},{"global/window":32}],2:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(e,t){return e.start(t)+"-"+e.end(t)},i=function(e,t){var n=e.toString(16);return"00".substring(0,2-n.length)+n+(t%2?" ":"")},a=function(e){return e>=32&&e<126?String.fromCharCode(e):"."},o=function(e){var t={};return Object.keys(e).forEach(function(n){var r=e[n];ArrayBuffer.isView(r)?t[n]={bytes:r.buffer,byteOffset:r.byteOffset,byteLength:r.byteLength}:t[n]=r}),t},s=function(e){var t=e.byterange||{length:1/0,offset:0};return[t.length,t.offset,e.resolvedUri].join(",")},u={hexDump:function(e){for(var t=Array.prototype.slice.call(e),n="",r=void 0,o=void 0,s=0;s<t.length/16;s++)r=t.slice(16*s,16*s+16).map(i).join(""),o=t.slice(16*s,16*s+16).map(a).join(""),n+=r+" "+o+"\n";return n},tagDump:function(e){return u.hexDump(e.bytes)},textRanges:function(e){var t="",n=void 0;for(n=0;n<e.length;n++)t+=r(e,n)+" ";return t},createTransferableMessage:o,initSegmentId:s};n.default=u,t.exports=n.default},{}],3:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default={GOAL_BUFFER_LENGTH:30,MAX_GOAL_BUFFER_LENGTH:60,GOAL_BUFFER_LENGTH_RATE:1,BANDWIDTH_VARIANCE:1.2,BUFFER_LOW_WATER_LINE:0,MAX_BUFFER_LOW_WATER_LINE:30,BUFFER_LOW_WATER_LINE_RATE:1},t.exports=n.default},{}],4:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e("global/window"),i=function(e){return e&&e.__esModule?e:{default:e}}(r),a=e("aes-decrypter"),o=e("./bin-utils"),s=function(e){e.onmessage=function(e){var t=e.data,n=new Uint8Array(t.encrypted.bytes,t.encrypted.byteOffset,t.encrypted.byteLength),r=new Uint32Array(t.key.bytes,t.key.byteOffset,t.key.byteLength/4),s=new Uint32Array(t.iv.bytes,t.iv.byteOffset,t.iv.byteLength/4);new a.Decrypter(n,r,s,function(e,n){i.default.postMessage((0,o.createTransferableMessage)({source:t.source,decrypted:n}),[n.buffer])})}};n.default=function(e){return new s(e)},t.exports=n.default},{"./bin-utils":2,"aes-decrypter":25,"global/window":32}],5:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},u=e("./playlist-loader"),l=r(u),c=e("./playlist.js"),d=e("./segment-loader"),f=r(d),h=e("./vtt-segment-loader"),p=r(h),m=e("./ranges"),v=r(m),g="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,y=r(g),_=e("./ad-cue-tags"),b=r(_),T=e("./sync-controller"),S=r(T),w=e("videojs-contrib-media-sources/es5/codec-utils"),k=e("webwackify"),E=r(k),A=e("./decrypter-worker"),C=r(A),L=e("./config"),x=r(L),j=e("./util/codecs.js"),O=e("./media-groups"),I=void 0,P={videoCodec:"avc1",videoObjectTypeIndicator:".4d400d",audioProfile:"2"},R=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred"],D=function(e){return this.audioSegmentLoader_[e]+this.mainSegmentLoader_[e]},M=function(){var t=void 0;try{t=e.resolve("./decrypter-worker")}catch(e){}return t},U=function(e){return e.replace(/avc1\.(\d+)\.(\d+)/i,function(e){return(0,w.translateLegacyCodecs)([e])[0]})};n.mapLegacyAvcCodecs_=U;var B=function(e,t,n){return e+"/"+t+'; codecs="'+n.filter(function(e){return!!e}).join(", ")+'"'},N=function(e){return e.segments&&e.segments.length&&e.segments[0].map?"mp4":"mp2t"},F=function(e){var t=e.attributes||{};return t.CODECS?(0,j.parseCodecs)(t.CODECS):P},V=function(e,t){var n=N(t),r=F(t),i=t.attributes||{},a=!0,o=!1;if(!t)return[];if(e.mediaGroups.AUDIO&&i.AUDIO){var s=e.mediaGroups.AUDIO[i.AUDIO];if(s){o=!0,a=!1;for(var u in s)if(!s[u].uri){a=!0;break}}}o&&!r.audioProfile&&(y.default.log.warn("Multiple audio tracks present but no audio codec string is specified. Attempting to use the default audio codec (mp4a.40.2)"),r.audioProfile=P.audioProfile);var l={};r.videoCodec&&(l.video=""+r.videoCodec+r.videoObjectTypeIndicator),r.audioProfile&&(l.audio="mp4a.40."+r.audioProfile);var c=B("audio",n,[l.audio]),d=B("video",n,[l.video]),f=B("video",n,[l.video,l.audio]);return o?!a&&l.video?[d,c]:[f,c]:l.video?[f]:[c]};n.mimeTypesForPlaylist_=V;var q=function(e){function t(e){var n=this;i(this,t),s(Object.getPrototypeOf(t.prototype),"constructor",this).call(this);var r=e.url,a=e.handleManifestRedirects,o=e.withCredentials,u=e.mode,c=e.tech,d=e.bandwidth,h=e.externHls,m=e.useCueTags,v=e.blacklistDuration,g=e.enableLowInitialPlaylist;if(!r)throw new Error("A non-empty playlist URL is required");I=h,this.tech_=c,this.hls_=c.hls,this.mode_=u,this.useCueTags_=m,this.blacklistDuration=v,this.enableLowInitialPlaylist=g,this.useCueTags_&&(this.cueTagsTrack_=this.tech_.addTextTrack("metadata","ad-cues"),this.cueTagsTrack_.inBandMetadataTrackDispatchType=""),this.requestOptions_={withCredentials:o,handleManifestRedirects:a,timeout:null},this.mediaTypes_=(0,O.createMediaTypes)(),this.mediaSource=new y.default.MediaSource({mode:u}),this.mediaSource.addEventListener("sourceopen",this.handleSourceOpen_.bind(this)),this.seekable_=y.default.createTimeRanges(),this.hasPlayed_=function(){return!1},this.syncController_=new S.default(e),this.segmentMetadataTrack_=c.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,this.decrypter_=(0,E.default)(C.default,M());var _={hls:this.hls_,mediaSource:this.mediaSource,currentTime:this.tech_.currentTime.bind(this.tech_),seekable:function(){return n.seekable()},seeking:function(){return n.tech_.seeking()},duration:function(){return n.mediaSource.duration},hasPlayed:function(){return n.hasPlayed_()},goalBufferLength:function(){return n.goalBufferLength()},bandwidth:d,syncController:this.syncController_,decrypter:this.decrypter_};this.masterPlaylistLoader_=new l.default(r,this.hls_,this.requestOptions_),this.setupMasterPlaylistLoaderListeners_(),this.mainSegmentLoader_=new f.default(y.default.mergeOptions(_,{segmentMetadataTrack:this.segmentMetadataTrack_,loaderType:"main"}),e),this.audioSegmentLoader_=new f.default(y.default.mergeOptions(_,{loaderType:"audio"}),e),this.subtitleSegmentLoader_=new p.default(y.default.mergeOptions(_,{loaderType:"vtt"}),e),this.setupSegmentLoaderListeners_(),R.forEach(function(e){n[e+"_"]=D.bind(n,e)}),this.masterPlaylistLoader_.load()}return a(t,e),o(t,[{key:"setupMasterPlaylistLoaderListeners_",value:function(){var e=this;this.masterPlaylistLoader_.on("loadedmetadata",function(){var t=e.masterPlaylistLoader_.media(),n=1.5*e.masterPlaylistLoader_.targetDuration*1e3;(0,c.isLowestEnabledRendition)(e.masterPlaylistLoader_.master,e.masterPlaylistLoader_.media())?e.requestOptions_.timeout=0:e.requestOptions_.timeout=n,t.endList&&"none"!==e.tech_.preload()&&(e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.mainSegmentLoader_.load()),(0,O.setupMediaGroups)({segmentLoaders:{AUDIO:e.audioSegmentLoader_,SUBTITLES:e.subtitleSegmentLoader_,main:e.mainSegmentLoader_},tech:e.tech_,requestOptions:e.requestOptions_,masterPlaylistLoader:e.masterPlaylistLoader_,mode:e.mode_,hls:e.hls_,master:e.master(),mediaTypes:e.mediaTypes_,blacklistCurrentPlaylist:e.blacklistCurrentPlaylist.bind(e)}),e.triggerPresenceUsage_(e.master(),t);try{e.setupSourceBuffers_()}catch(t){return y.default.log.warn("Failed to create SourceBuffers",t),e.mediaSource.endOfStream("decode")}e.setupFirstPlay(),e.trigger("selectedinitialmedia")}),this.masterPlaylistLoader_.on("loadedplaylist",function(){var t=e.masterPlaylistLoader_.media();if(!t){var n=void 0;return e.enableLowInitialPlaylist&&(n=e.selectInitialPlaylist()),n||(n=e.selectPlaylist()),e.initialMedia_=n,void e.masterPlaylistLoader_.media(e.initialMedia_)}e.useCueTags_&&e.updateAdCues_(t),e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.updateDuration(),e.tech_.paused()||e.mainSegmentLoader_.load(),t.endList||function(){var t=function(){var t=e.seekable();0!==t.length&&e.mediaSource.addSeekableRange_(t.start(0),t.end(0))};e.duration()!==1/0?function(){var n=function n(){e.duration()===1/0?t():e.tech_.one("durationchange",n)};e.tech_.one("durationchange",n)}():t()}()}),this.masterPlaylistLoader_.on("error",function(){e.blacklistCurrentPlaylist(e.masterPlaylistLoader_.error)}),this.masterPlaylistLoader_.on("mediachanging",function(){e.mainSegmentLoader_.abort(),e.mainSegmentLoader_.pause()}),this.masterPlaylistLoader_.on("mediachange",function(){var t=e.masterPlaylistLoader_.media(),n=1.5*e.masterPlaylistLoader_.targetDuration*1e3;(0,c.isLowestEnabledRendition)(e.masterPlaylistLoader_.master,e.masterPlaylistLoader_.media())?e.requestOptions_.timeout=0:e.requestOptions_.timeout=n,e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.mainSegmentLoader_.load(),e.tech_.trigger({type:"mediachange",bubbles:!0})}),this.masterPlaylistLoader_.on("playlistunchanged",function(){var t=e.masterPlaylistLoader_.media();e.stuckAtPlaylistEnd_(t)&&(e.blacklistCurrentPlaylist({message:"Playlist no longer updating."}),e.tech_.trigger("playliststuck"))}),this.masterPlaylistLoader_.on("renditiondisabled",function(){e.tech_.trigger({type:"usage",name:"hls-rendition-disabled"})}),this.masterPlaylistLoader_.on("renditionenabled",function(){e.tech_.trigger({type:"usage",name:"hls-rendition-enabled"})})}},{key:"triggerPresenceUsage_",value:function(e,t){var n=e.mediaGroups||{},r=!0,i=Object.keys(n.AUDIO);for(var a in n.AUDIO)for(var o in n.AUDIO[a]){var s=n.AUDIO[a][o];s.uri||(r=!1)}r&&this.tech_.trigger({type:"usage",name:"hls-demuxed"}),Object.keys(n.SUBTITLES).length&&this.tech_.trigger({type:"usage",name:"hls-webvtt"}),I.Playlist.isAes(t)&&this.tech_.trigger({type:"usage",name:"hls-aes"}),I.Playlist.isFmp4(t)&&this.tech_.trigger({type:"usage",name:"hls-fmp4"}),i.length&&Object.keys(n.AUDIO[i[0]]).length>1&&this.tech_.trigger({type:"usage",name:"hls-alternate-audio"}),this.useCueTags_&&this.tech_.trigger({type:"usage",name:"hls-playlist-cue-tags"})}},{key:"setupSegmentLoaderListeners_",value:function(){var e=this;this.mainSegmentLoader_.on("bandwidthupdate",function(){var t=e.selectPlaylist(),n=e.masterPlaylistLoader_.media(),r=e.tech_.buffered(),i=r.length?r.end(r.length-1)-e.tech_.currentTime():0,a=e.bufferLowWaterLine();(!n.endList||e.duration()<x.default.MAX_BUFFER_LOW_WATER_LINE||t.attributes.BANDWIDTH<n.attributes.BANDWIDTH||i>=a)&&e.masterPlaylistLoader_.media(t),e.tech_.trigger("bandwidthupdate")}),this.mainSegmentLoader_.on("progress",function(){e.trigger("progress")}),this.mainSegmentLoader_.on("error",function(){e.blacklistCurrentPlaylist(e.mainSegmentLoader_.error())}),this.mainSegmentLoader_.on("syncinfoupdate",function(){e.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("timestampoffset",function(){e.tech_.trigger({type:"usage",name:"hls-timestamp-offset"})}),this.audioSegmentLoader_.on("syncinfoupdate",function(){e.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("ended",function(){e.onEndOfStream()}),this.mainSegmentLoader_.on("earlyabort",function(){e.blacklistCurrentPlaylist({message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},120)}),this.mainSegmentLoader_.on("reseteverything",function(){e.tech_.trigger("hls-reset")}),this.mainSegmentLoader_.on("segmenttimemapping",function(t){e.tech_.trigger({type:"hls-segment-time-mapping",mapping:t.mapping})}),this.audioSegmentLoader_.on("ended",function(){e.onEndOfStream()})}},{key:"mediaSecondsLoaded_",value:function(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)}},{key:"load",value:function(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()}},{key:"fastQualityChange_",value:function(){var e=this.selectPlaylist();e!==this.masterPlaylistLoader_.media()&&(this.masterPlaylistLoader_.media(e),this.mainSegmentLoader_.resetLoader())}},{key:"play",value:function(){if(!this.setupFirstPlay()){this.tech_.ended()&&this.tech_.setCurrentTime(0),this.hasPlayed_()&&this.load();var e=this.tech_.seekable();return this.tech_.duration()===1/0&&this.tech_.currentTime()<e.start(0)?this.tech_.setCurrentTime(e.end(e.length-1)):void 0}}},{key:"setupFirstPlay",value:function(){var e=this,t=this.masterPlaylistLoader_.media();if(!t||this.tech_.paused()||this.hasPlayed_())return!1;if(!t.endList){var n=function(){var t=e.seekable();return t.length?y.default.browser.IE_VERSION&&"html5"===e.mode_&&0===e.tech_.readyState()?(e.tech_.one("loadedmetadata",function(){e.trigger("firstplay"),e.tech_.setCurrentTime(t.end(0)),e.hasPlayed_=function(){return!0}}),{v:!1}):(e.trigger("firstplay"),void e.tech_.setCurrentTime(t.end(0))):{v:!1}}();if("object"==typeof n)return n.v}return this.hasPlayed_=function(){return!0},this.load(),!0}},{key:"handleSourceOpen_",value:function(){try{this.setupSourceBuffers_()}catch(e){return y.default.log.warn("Failed to create Source Buffers",e),this.mediaSource.endOfStream("decode")}if(this.tech_.autoplay()){var e=this.tech_.play();void 0!==e&&"function"==typeof e.then&&e.then(null,function(e){})}this.trigger("sourceopen")}},{key:"onEndOfStream",value:function(){var e=this.mainSegmentLoader_.ended_;this.mediaTypes_.AUDIO.activePlaylistLoader&&(e=e&&this.audioSegmentLoader_.ended_),e&&this.mediaSource.endOfStream()}},{key:"stuckAtPlaylistEnd_",value:function(e){if(!this.seekable().length)return!1;var t=this.syncController_.getExpiredTime(e,this.mediaSource.duration);if(null===t)return!1;var n=I.Playlist.playlistEnd(e,t),r=this.tech_.currentTime(),i=this.tech_.buffered();if(!i.length)return n-r<=v.default.SAFE_TIME_DELTA;var a=i.end(i.length-1);return a-r<=v.default.SAFE_TIME_DELTA&&n-a<=v.default.SAFE_TIME_DELTA}},{key:"blacklistCurrentPlaylist",value:function(e,t){void 0===e&&(e={});var n=void 0,r=void 0;if(n=e.playlist||this.masterPlaylistLoader_.media(),t=t||e.blacklistDuration||this.blacklistDuration,!n){this.error=e;try{return this.mediaSource.endOfStream("network")}catch(e){return this.trigger("error")}}var i=1===this.masterPlaylistLoader_.master.playlists.filter(c.isEnabled).length;return i?(y.default.log.warn("Problem encountered with the current HLS playlist. Trying again since it is the final playlist."),this.tech_.trigger("retryplaylist"),this.masterPlaylistLoader_.load(i)):(n.excludeUntil=Date.now()+1e3*t,this.tech_.trigger("blacklistplaylist"),this.tech_.trigger({type:"usage",name:"hls-rendition-blacklisted"}),r=this.selectPlaylist(),y.default.log.warn("Problem encountered with the current HLS playlist."+(e.message?" "+e.message:"")+" Switching to another playlist."),this.masterPlaylistLoader_.media(r))}},{key:"pauseLoading",value:function(){this.mainSegmentLoader_.pause(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.pause(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.pause()}},{key:"setCurrentTime",value:function(e){var t=v.default.findRange(this.tech_.buffered(),e);return this.masterPlaylistLoader_&&this.masterPlaylistLoader_.media()&&this.masterPlaylistLoader_.media().segments?t&&t.length&&"flash"!==this.mode_?e:(this.mainSegmentLoader_.resetEverything(),this.mainSegmentLoader_.abort(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.resetEverything(),this.audioSegmentLoader_.abort()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.resetEverything(),this.subtitleSegmentLoader_.abort()),void this.load()):0}},{key:"duration",value:function(){return this.masterPlaylistLoader_?this.mediaSource?this.mediaSource.duration:I.Playlist.duration(this.masterPlaylistLoader_.media()):0}},{key:"seekable",value:function(){return this.seekable_}},{key:"onSyncInfoUpdate_",value:function(){var e=void 0,t=void 0;if(this.masterPlaylistLoader_){var n=this.masterPlaylistLoader_.media();if(n){var r=this.syncController_.getExpiredTime(n,this.mediaSource.duration);if(null!==r&&(e=I.Playlist.seekable(n,r),0!==e.length)){if(this.mediaTypes_.AUDIO.activePlaylistLoader){if(n=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),null===(r=this.syncController_.getExpiredTime(n,this.mediaSource.duration)))return;if(t=I.Playlist.seekable(n,r),0===t.length)return}t?t.start(0)>e.end(0)||e.start(0)>t.end(0)?this.seekable_=e:this.seekable_=y.default.createTimeRanges([[t.start(0)>e.start(0)?t.start(0):e.start(0),t.end(0)<e.end(0)?t.end(0):e.end(0)]]):this.seekable_=e,this.tech_.trigger("seekablechanged")}}}}},{key:"updateDuration",value:function(){var e=this,t=this.mediaSource.duration,n=I.Playlist.duration(this.masterPlaylistLoader_.media()),r=this.tech_.buffered(),i=function t(){e.mediaSource.duration=n,e.tech_.trigger("durationchange"),e.mediaSource.removeEventListener("sourceopen",t)};r.length>0&&(n=Math.max(n,r.end(r.length-1))),t!==n&&("open"!==this.mediaSource.readyState?this.mediaSource.addEventListener("sourceopen",i):i())}},{key:"dispose",value:function(){var e=this;this.decrypter_.terminate(),this.masterPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),["AUDIO","SUBTITLES"].forEach(function(t){var n=e.mediaTypes_[t].groups;for(var r in n)n[r].forEach(function(e){e.playlistLoader&&e.playlistLoader.dispose()})}),this.audioSegmentLoader_.dispose(),this.subtitleSegmentLoader_.dispose()}},{key:"master",value:function(){return this.masterPlaylistLoader_.master}},{key:"media",value:function(){return this.masterPlaylistLoader_.media()||this.initialMedia_}},{key:"setupSourceBuffers_",value:function(){var e=this.masterPlaylistLoader_.media(),t=void 0;if(e&&"open"===this.mediaSource.readyState){if(t=V(this.masterPlaylistLoader_.master,e),t.length<1)return this.error="No compatible SourceBuffer configuration for the variant stream:"+e.resolvedUri,this.mediaSource.endOfStream("decode");this.mainSegmentLoader_.mimeType(t[0]),t[1]&&this.audioSegmentLoader_.mimeType(t[1]),this.excludeIncompatibleVariants_(e)}}},{key:"excludeIncompatibleVariants_",value:function(e){var t=this.masterPlaylistLoader_.master,n=2,r=null,i=void 0;e.attributes.CODECS&&(i=(0,j.parseCodecs)(e.attributes.CODECS),r=i.videoCodec,n=i.codecCount),t.playlists.forEach(function(e){var t={codecCount:2,videoCodec:null};if(e.attributes.CODECS){var i=e.attributes.CODECS;t=(0,j.parseCodecs)(i),window.MediaSource&&window.MediaSource.isTypeSupported&&!window.MediaSource.isTypeSupported('video/mp4; codecs="'+U(i)+'"')&&(e.excludeUntil=1/0)}t.codecCount!==n&&(e.excludeUntil=1/0),t.videoCodec!==r&&(e.excludeUntil=1/0)})}},{key:"updateAdCues_",value:function(e){var t=0,n=this.seekable();n.length&&(t=n.start(0)),b.default.updateAdCues(e,this.cueTagsTrack_,t)}},{key:"goalBufferLength",value:function(){var e=this.tech_.currentTime(),t=x.default.GOAL_BUFFER_LENGTH,n=x.default.GOAL_BUFFER_LENGTH_RATE,r=Math.max(t,x.default.MAX_GOAL_BUFFER_LENGTH);return Math.min(t+e*n,r)}},{key:"bufferLowWaterLine",value:function(){var e=this.tech_.currentTime(),t=x.default.BUFFER_LOW_WATER_LINE,n=x.default.BUFFER_LOW_WATER_LINE_RATE,r=Math.max(t,x.default.MAX_BUFFER_LOW_WATER_LINE);return Math.min(t+e*n,r)}}]),t}(y.default.EventTarget);n.MasterPlaylistController=q}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./ad-cue-tags":1,"./config":3,"./decrypter-worker":4,"./media-groups":6,"./playlist-loader":9,"./playlist.js":11,"./ranges":12,"./segment-loader":16,"./sync-controller":18,"./util/codecs.js":19,"./vtt-segment-loader":20,"videojs-contrib-media-sources/es5/codec-utils":65,webwackify:76}],6:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var i="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,a=r(i),o=e("./playlist-loader"),s=r(o),u=function(){},l=function(e){var t=e.default?"main":"alternative";return e.characteristics&&e.characteristics.indexOf("public.accessibility.describes-video")>=0&&(t="main-desc"),t},c=function(e,t){e.abort(),e.pause(),t&&t.activePlaylistLoader&&(t.activePlaylistLoader.pause(),t.activePlaylistLoader=null)};n.stopLoaders=c;var d=function(e,t){t.activePlaylistLoader=e,e.load()};n.startLoaders=d;var f=function(e,t){return function(){var n=t.segmentLoaders,r=n[e],i=n.main,a=t.mediaTypes[e],o=a.activeTrack(),s=a.activeGroup(o),u=a.activePlaylistLoader;if(c(r,a),s){if(!s.playlistLoader)return void(u&&i.resetEverything());r.resyncLoader(),d(s.playlistLoader,a)}}};n.onGroupChanged=f;var h=function(e,t){return function(){var n=t.segmentLoaders,r=n[e],i=n.main,a=t.mediaTypes[e],o=a.activeTrack(),s=a.activeGroup(o),u=a.activePlaylistLoader;if(c(r,a),s){if(!s.playlistLoader)return void i.resetEverything();if(u===s.playlistLoader)return void d(s.playlistLoader,a);r.track&&r.track(o),r.resetEverything(),d(s.playlistLoader,a)}}};n.onTrackChanged=h;var p={AUDIO:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e],i=t.blacklistCurrentPlaylist;c(n,r);var o=r.activeTrack(),s=r.activeGroup(),u=(s.filter(function(e){return e.default})[0]||s[0]).id,l=r.tracks[u];if(o===l)return void i({message:"Problem encountered loading the default audio track."});a.default.log.warn("Problem encountered loading the alternate audio track.Switching back to default.");for(var d in r.tracks)r.tracks[d].enabled=r.tracks[d]===l;r.onTrackChanged()}},SUBTITLES:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e];a.default.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track."),c(n,r);var i=r.activeTrack();i&&(i.mode="disabled"),r.onTrackChanged()}}};n.onError=p;var m={AUDIO:function(e,t,n){if(t){var r=n.tech,i=n.requestOptions,a=n.segmentLoaders[e];t.on("loadedmetadata",function(){var e=t.media();a.playlist(e,i),(!r.paused()||e.endList&&"none"!==r.preload())&&a.load()}),t.on("loadedplaylist",function(){a.playlist(t.media(),i),r.paused()||a.load()}),t.on("error",p[e](e,n))}},SUBTITLES:function(e,t,n){var r=n.tech,i=n.requestOptions,a=n.segmentLoaders[e],o=n.mediaTypes[e];t.on("loadedmetadata",function(){var e=t.media();a.playlist(e,i),a.track(o.activeTrack()),(!r.paused()||e.endList&&"none"!==r.preload())&&a.load()}),t.on("loadedplaylist",function(){a.playlist(t.media(),i),r.paused()||a.load()}),t.on("error",p[e](e,n))}};n.setupListeners=m;var v={AUDIO:function(e,t){var n=t.mode,r=t.hls,i=t.segmentLoaders[e],o=t.requestOptions,u=t.master.mediaGroups,c=t.mediaTypes[e],d=c.groups,f=c.tracks;u[e]&&0!==Object.keys(u[e]).length&&"html5"===n||(u[e]={main:{default:{default:!0}}});for(var h in u[e]){d[h]||(d[h]=[]);for(var v in u[e][h]){var g=u[e][h][v],y=void 0;if(y=g.resolvedUri?new s.default(g.resolvedUri,r,o):null,g=a.default.mergeOptions({id:v,playlistLoader:y},g),m[e](e,g.playlistLoader,t),d[h].push(g),void 0===f[v]){var _=new a.default.AudioTrack({id:v,kind:l(g),enabled:!1,language:g.language,default:g.default,label:v});f[v]=_}}}i.on("error",p[e](e,t))},SUBTITLES:function(e,t){var n=t.tech,r=t.hls,i=t.segmentLoaders[e],o=t.requestOptions,u=t.master.mediaGroups,l=t.mediaTypes[e],c=l.groups,d=l.tracks;for(var f in u[e]){c[f]||(c[f]=[]);for(var h in u[e][f])if(!u[e][f][h].forced){var v=u[e][f][h];if(v=a.default.mergeOptions({id:h,playlistLoader:new s.default(v.resolvedUri,r,o)},v),m[e](e,v.playlistLoader,t),c[f].push(v),void 0===d[h]){var g=n.addRemoteTextTrack({id:h,kind:"subtitles",enabled:!1,language:v.language,label:h},!1).track;d[h]=g}}}i.on("error",p[e](e,t))},"CLOSED-CAPTIONS":function(e,t){var n=t.tech,r=t.master.mediaGroups,i=t.mediaTypes[e],o=i.groups,s=i.tracks;for(var u in r[e]){o[u]||(o[u]=[]);for(var l in r[e][u]){var c=r[e][u][l];if(c.instreamId.match(/CC\d/)&&(o[u].push(a.default.mergeOptions({id:l},c)),void 0===s[l])){var d=n.addRemoteTextTrack({id:c.instreamId,kind:"captions",enabled:!1,language:c.language,label:l},!1).track;s[l]=d}}}}};n.initialize=v;var g=function(e,t){return function(n){var r=t.masterPlaylistLoader,i=t.mediaTypes[e].groups,a=r.media();if(!a)return null;var o=null;return a.attributes[e]&&(o=i[a.attributes[e]]),o=o||i.main,void 0===n?o:null===n?null:o.filter(function(e){return e.id===n.id})[0]||null}};n.activeGroup=g;var y={AUDIO:function(e,t){return function(){var n=t.mediaTypes[e].tracks;for(var r in n)if(n[r].enabled)return n[r];return null}},SUBTITLES:function(e,t){return function(){var n=t.mediaTypes[e].tracks;for(var r in n)if("showing"===n[r].mode)return n[r];return null}}};n.activeTrack=y;var _=function(e){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(function(t){v[t](t,e)});var t=e.mediaTypes,n=e.masterPlaylistLoader,r=e.tech,i=e.hls;["AUDIO","SUBTITLES"].forEach(function(n){t[n].activeGroup=g(n,e),t[n].activeTrack=y[n](n,e),t[n].onGroupChanged=f(n,e),t[n].onTrackChanged=h(n,e)});var a=t.AUDIO.activeGroup(),o=(a.filter(function(e){return e.default})[0]||a[0]).id;t.AUDIO.tracks[o].enabled=!0,t.AUDIO.onTrackChanged(),n.on("mediachange",function(){["AUDIO","SUBTITLES"].forEach(function(e){return t[e].onGroupChanged()})});var s=function(){t.AUDIO.onTrackChanged(),r.trigger({type:"usage",name:"hls-audio-change"})};r.audioTracks().addEventListener("change",s),r.remoteTextTracks().addEventListener("change",t.SUBTITLES.onTrackChanged),i.on("dispose",function(){r.audioTracks().removeEventListener("change",s),r.remoteTextTracks().removeEventListener("change",t.SUBTITLES.onTrackChanged)}),r.clearTracks("audio");for(var u in t.AUDIO.tracks)r.audioTracks().addTrack(t.AUDIO.tracks[u])};n.setupMediaGroups=_;var b=function(){var e={};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(function(t){e[t]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:u,activeTrack:u,onGroupChanged:u,onTrackChanged:u}}),e};n.createMediaTypes=b}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./playlist-loader":9}],7:[function(e,t,n){(function(t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,i=function(e){return e&&e.__esModule?e:{default:e}}(r),a=e("./bin-utils"),o={FAILURE:2,TIMEOUT:-101,ABORTED:-102};n.REQUEST_ERRORS=o;var s=function(e){var t=void 0;return t=e.offset+e.length-1,"bytes="+e.offset+"-"+t},u=function(e){var t={};return e.byterange&&(t.Range=s(e.byterange)),t},l=function(e){e.forEach(function(e){e.abort()})},c=function(e){return{bandwidth:e.bandwidth,bytesReceived:e.bytesReceived||0,roundTripTime:e.roundTripTime||0}},d=function(e){var t=e.target,n=Date.now()-t.requestTime,r={bandwidth:1/0,bytesReceived:0,roundTripTime:n||0};return r.bytesReceived=e.loaded,r.bandwidth=Math.floor(r.bytesReceived/r.roundTripTime*8*1e3),r},f=function(e,t){return t.timedout?{status:t.status,message:"HLS request timed-out at URL: "+t.uri,code:o.TIMEOUT,xhr:t}:t.aborted?{status:t.status,message:"HLS request aborted at URL: "+t.uri,code:o.ABORTED,xhr:t}:e?{status:t.status,message:"HLS request errored at URL: "+t.uri,code:o.FAILURE,xhr:t}:null},h=function(e,t){return function(n,r){var i=r.response,a=f(n,r);if(a)return t(a,e);if(16!==i.byteLength)return t({status:r.status,message:"Invalid HLS key at URL: "+r.uri,code:o.FAILURE,xhr:r},e);var s=new DataView(i);return e.key.bytes=new Uint32Array([s.getUint32(0),s.getUint32(4),s.getUint32(8),s.getUint32(12)]),t(null,e)}},p=function(e,t){return function(n,r){var i=r.response,a=f(n,r);return a?t(a,e):0===i.byteLength?t({status:r.status,message:"Empty HLS segment content at URL: "+r.uri,code:o.FAILURE,xhr:r},e):(e.map.bytes=new Uint8Array(r.response),t(null,e))}},m=function(e,t){return function(n,r){var i=r.response,a=f(n,r);return a?t(a,e):0===i.byteLength?t({status:r.status,message:"Empty HLS segment content at URL: "+r.uri,code:o.FAILURE,xhr:r},e):(e.stats=c(r),e.key?e.encryptedBytes=new Uint8Array(r.response):e.bytes=new Uint8Array(r.response),t(null,e))}},v=function(e,t,n){var r=function r(i){if(i.data.source===t.requestId){e.removeEventListener("message",r);var a=i.data.decrypted;return t.bytes=new Uint8Array(a.bytes,a.byteOffset,a.byteLength),n(null,t)}};e.addEventListener("message",r),e.postMessage((0,a.createTransferableMessage)({source:t.requestId,encrypted:t.encryptedBytes,key:t.key.bytes,iv:t.key.iv}),[t.encryptedBytes.buffer,t.key.bytes.buffer])},g=function(e){return e.reduce(function(e,t){return t.code>e.code?t:e})},y=function(e,t,n){var r=[],i=0;return function(a,o){if(a&&(l(e),r.push(a)),(i+=1)===e.length){if(o.endOfAllRequests=Date.now(),r.length>0){var s=g(r);return n(s,o)}return o.encryptedBytes?v(t,o,n):n(null,o)}}},_=function(e,t){return function(n){return e.stats=i.default.mergeOptions(e.stats,d(n)),!e.stats.firstBytesReceivedAt&&e.stats.bytesReceived&&(e.stats.firstBytesReceivedAt=Date.now()),t(n,e)}},b=function(e,t,n,r,a,o){var s=[],c=y(s,n,o);if(r.key){var d=i.default.mergeOptions(t,{uri:r.key.resolvedUri,responseType:"arraybuffer"}),f=h(r,c),v=e(d,f);s.push(v)}if(r.map&&!r.map.bytes){var g=i.default.mergeOptions(t,{uri:r.map.resolvedUri,responseType:"arraybuffer",headers:u(r.map)}),b=p(r,c),T=e(g,b);s.push(T)}var S=i.default.mergeOptions(t,{uri:r.resolvedUri,responseType:"arraybuffer",headers:u(r)}),w=m(r,c),k=e(S,w);return k.addEventListener("progress",_(r,a)),s.push(k),function(){return l(s)}};n.mediaSegmentRequest=b}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./bin-utils":2}],8:[function(e,t,n){(function(r){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=e("global/window"),u=i(s),l=e("./ranges"),c=i(l),d="undefined"!=typeof window?window.videojs:void 0!==r?r.videojs:null,f=i(d),h=["seeking","seeked","pause","playing","error"],p=function(){function e(t){var n=this;a(this,e),this.tech_=t.tech,this.seekable=t.seekable,this.consecutiveUpdates=0,this.lastRecordedTime=null,this.timer_=null,this.checkCurrentTimeTimeout_=null,t.debug&&(this.logger_=f.default.log.bind(f.default,"playback-watcher ->")),this.logger_("initialize");var r=function(){return n.monitorCurrentTime_()},i=function(){return n.techWaiting_()},o=function(){return n.cancelTimer_()},s=function(){return n.fixesBadSeeks_()};this.tech_.on("seekablechanged",s),this.tech_.on("waiting",i),this.tech_.on(h,o),this.tech_.on("canplay",r),this.dispose=function(){n.logger_("dispose"),n.tech_.off("seekablechanged",s),n.tech_.off("waiting",i),n.tech_.off(h,o),n.tech_.off("canplay",r),n.checkCurrentTimeTimeout_&&u.default.clearTimeout(n.checkCurrentTimeTimeout_),n.cancelTimer_()}}return o(e,[{key:"monitorCurrentTime_",value:function(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&u.default.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=u.default.setTimeout(this.monitorCurrentTime_.bind(this),250)}},{key:"checkCurrentTime_",value:function(){if(this.tech_.seeking()&&this.fixesBadSeeks_())return this.consecutiveUpdates=0,void(this.lastRecordedTime=this.tech_.currentTime());if(!this.tech_.paused()&&!this.tech_.seeking()){var e=this.tech_.currentTime(),t=this.tech_.buffered();if(this.lastRecordedTime===e&&(!t.length||e+c.default.SAFE_TIME_DELTA>=t.end(t.length-1)))return this.techWaiting_();this.consecutiveUpdates>=5&&e===this.lastRecordedTime?(this.consecutiveUpdates++,this.waiting_()):e===this.lastRecordedTime?this.consecutiveUpdates++:(this.consecutiveUpdates=0,this.lastRecordedTime=e)}}},{key:"cancelTimer_",value:function(){this.consecutiveUpdates=0,this.timer_&&(this.logger_("cancelTimer_"),clearTimeout(this.timer_)),this.timer_=null}},{key:"fixesBadSeeks_",value:function(){var e=this.tech_.seeking(),t=this.seekable(),n=this.tech_.currentTime(),r=void 0;return e&&this.afterSeekableWindow_(t,n)&&(r=t.end(t.length-1)),e&&this.beforeSeekableWindow_(t,n)&&(r=t.start(0)+c.default.SAFE_TIME_DELTA),void 0!==r&&(this.logger_("Trying to seek outside of seekable at time "+n+" with seekable range "+c.default.printableRange(t)+". Seeking to "+r+"."),this.tech_.setCurrentTime(r),!0)}},{key:"waiting_",value:function(){if(!this.techWaiting_()){var e=this.tech_.currentTime(),t=this.tech_.buffered(),n=c.default.findRange(t,e);return n.length&&e+3<=n.end(0)?(this.cancelTimer_(),this.tech_.setCurrentTime(e),this.logger_("Stopped at "+e+" while inside a buffered region ["+n.start(0)+" -> "+n.end(0)+"]. Attempting to resume playback by seeking to the current time."),void this.tech_.trigger({type:"usage",name:"hls-unknown-waiting"})):void 0}}},{key:"techWaiting_",value:function(){var e=this.seekable(),t=this.tech_.currentTime();if(this.tech_.seeking()&&this.fixesBadSeeks_())return!0;if(this.tech_.seeking()||null!==this.timer_)return!0;if(this.beforeSeekableWindow_(e,t)){var n=e.end(e.length-1);return this.logger_("Fell out of live window at time "+t+". Seeking to live point (seekable end) "+n),this.cancelTimer_(),this.tech_.setCurrentTime(n),this.tech_.trigger({type:"usage",name:"hls-live-resync"}),!0}var r=this.tech_.buffered(),i=c.default.findNextRange(r,t);if(this.videoUnderflow_(i,r,t))return this.cancelTimer_(),this.tech_.setCurrentTime(t),this.tech_.trigger({type:"usage",name:"hls-video-underflow"}),!0;if(i.length>0){var a=i.start(0)-t;return this.logger_("Stopped at "+t+", setting timer for "+a+", seeking to "+i.start(0)),this.timer_=setTimeout(this.skipTheGap_.bind(this),1e3*a,t),!0}return!1}},{key:"afterSeekableWindow_",value:function(e,t){return!!e.length&&t>e.end(e.length-1)+c.default.SAFE_TIME_DELTA}},{key:"beforeSeekableWindow_",value:function(e,t){return!!(e.length&&e.start(0)>0&&t<e.start(0)-c.default.SAFE_TIME_DELTA)}},{key:"videoUnderflow_",value:function(e,t,n){if(0===e.length){var r=this.gapFromVideoUnderflow_(t,n);if(r)return this.logger_("Encountered a gap in video from "+r.start+" to "+r.end+". Seeking to current time "+n),!0}return!1}},{key:"skipTheGap_",value:function(e){var t=this.tech_.buffered(),n=this.tech_.currentTime(),r=c.default.findNextRange(t,n);this.cancelTimer_(),0!==r.length&&n===e&&(this.logger_("skipTheGap_:","currentTime:",n,"scheduled currentTime:",e,"nextRange start:",r.start(0)),this.tech_.setCurrentTime(r.start(0)+c.default.TIME_FUDGE_FACTOR),this.tech_.trigger({type:"usage",name:"hls-gap-skip"}))}},{key:"gapFromVideoUnderflow_",value:function(e,t){for(var n=c.default.findGaps(e),r=0;r<n.length;r++){var i=n.start(r),a=n.end(r);if(t-i<4&&t-i>2)return{start:i,end:a}}return null}},{key:"logger_",value:function(){}}]),e}();n.default=p,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./ranges":12,"global/window":32}],9:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},u=e("./resolve-url"),l=r(u),c="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,d=e("m3u8-parser"),f=r(d),h=e("global/window"),p=r(h),m=function(e,t,n){var r=t.slice();n=n||0;for(var i=Math.min(e.length,t.length+n),a=n;a<i;a++)r[a-n]=(0,c.mergeOptions)(e[a],r[a-n]);return r};n.updateSegments=m;var v=function(e,t){e.resolvedUri||(e.resolvedUri=(0,l.default)(t,e.uri)),e.key&&!e.key.resolvedUri&&(e.key.resolvedUri=(0,l.default)(t,e.key.uri)),e.map&&!e.map.resolvedUri&&(e.map.resolvedUri=(0,l.default)(t,e.map.uri))};n.resolveSegmentUris=v;var g=function(e,t){var n=(0,c.mergeOptions)(e,{}),r=n.playlists.filter(function(e){return e.uri===t.uri})[0];if(!r)return null;if(r.segments&&t.segments&&r.segments.length===t.segments.length&&r.mediaSequence===t.mediaSequence)return null;var i=(0,c.mergeOptions)(r,t);r.segments&&(i.segments=m(r.segments,t.segments,t.mediaSequence-r.mediaSequence)),i.segments.forEach(function(e){v(e,i.resolvedUri)});for(var a=0;a<n.playlists.length;a++)n.playlists[a].uri===t.uri&&(n.playlists[a]=i);return n.playlists[t.uri]=i,n};n.updateMaster=g;var y=function(e){for(var t=e.playlists.length;t--;){var n=e.playlists[t];e.playlists[n.uri]=n,n.resolvedUri=(0,l.default)(e.uri,n.uri),n.attributes||(n.attributes={},c.log.warn("Invalid playlist STREAM-INF detected. Missing BANDWIDTH attribute."))}};n.setupMediaPlaylists=y;var _=function(e){["AUDIO","SUBTITLES"].forEach(function(t){for(var n in e.mediaGroups[t])for(var r in e.mediaGroups[t][n]){var i=e.mediaGroups[t][n][r];i.uri&&(i.resolvedUri=(0,l.default)(e.uri,i.uri))}})};n.resolveMediaGroupUris=_;var b=function(e,t){var n=e.segments[e.segments.length-1];return t&&n&&n.duration?1e3*n.duration:500*(e.targetDuration||10)};n.refreshDelay=b;var T=function(e){function t(e,n,r){var a=this;if(i(this,t),s(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),r=r||{},this.srcUrl=e,this.hls_=n,this.withCredentials=!!r.withCredentials,this.handleManifestRedirects=!!r.handleManifestRedirects,!this.srcUrl)throw new Error("A non-empty playlist URL is required");this.state="HAVE_NOTHING",this.on("mediaupdatetimeout",function(){"HAVE_METADATA"===a.state&&(a.state="HAVE_CURRENT_METADATA",a.request=a.hls_.xhr({uri:(0,l.default)(a.master.uri,a.media().uri),withCredentials:a.withCredentials},function(e,t){if(a.request)return e?a.playlistRequestError(a.request,a.media().uri,"HAVE_METADATA"):void a.haveMetadata(a.request,a.media().uri)}))})}return a(t,e),o(t,[{key:"playlistRequestError",value:function(e,t,n){this.request=null,n&&(this.state=n),this.error={playlist:this.master.playlists[t],status:e.status,message:"HLS playlist request error at URL: "+t,responseText:e.responseText,code:e.status>=500?4:2},this.trigger("error")}},{key:"haveMetadata",value:function(e,t){var n=this;this.request=null,this.state="HAVE_METADATA";var r=new f.default.Parser;r.push(e.responseText),r.end(),r.manifest.uri=t,r.manifest.attributes=r.manifest.attributes||{};var i=g(this.master,r.manifest);this.targetDuration=r.manifest.targetDuration,i?(this.master=i,this.media_=this.master.playlists[r.manifest.uri]):this.trigger("playlistunchanged"),this.media().endList||(p.default.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=p.default.setTimeout(function(){n.trigger("mediaupdatetimeout")},b(this.media(),!!i))),this.trigger("loadedplaylist")}},{key:"dispose",value:function(){this.stopRequest(),p.default.clearTimeout(this.mediaUpdateTimeout)}},{key:"stopRequest",value:function(){if(this.request){var e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}},{key:"media",value:function(e){var t=this;if(!e)return this.media_;if("HAVE_NOTHING"===this.state)throw new Error("Cannot switch media playlist from "+this.state);var n=this.state;if("string"==typeof e){if(!this.master.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.master.playlists[e]}var r=!this.media_||e.uri!==this.media_.uri;if(this.master.playlists[e.uri].endList)return this.request&&(this.request.onreadystatechange=null,this.request.abort(),this.request=null),this.state="HAVE_METADATA",this.media_=e,void(r&&(this.trigger("mediachanging"),this.trigger("mediachange")));if(r){if(this.state="SWITCHING_MEDIA",this.request){if(e.resolvedUri===this.request.url)return;this.request.onreadystatechange=null,this.request.abort(),this.request=null}this.media_&&this.trigger("mediachanging"),this.request=this.hls_.xhr({uri:e.resolvedUri,withCredentials:this.withCredentials},function(r,i){if(t.request){if(e.resolvedUri=t.resolveManifestRedirect(e.resolvedUri,i),r)return t.playlistRequestError(t.request,e.uri,n);t.haveMetadata(i,e.uri),"HAVE_MASTER"===n?t.trigger("loadedmetadata"):t.trigger("mediachange")}})}}},{key:"resolveManifestRedirect",value:function(e,t){return this.handleManifestRedirects&&t.responseURL&&e!==t.responseURL?t.responseURL:e}},{key:"pause",value:function(){this.stopRequest(),p.default.clearTimeout(this.mediaUpdateTimeout),"HAVE_NOTHING"===this.state&&(this.started=!1),"SWITCHING_MEDIA"===this.state?this.media_?this.state="HAVE_METADATA":this.state="HAVE_MASTER":"HAVE_CURRENT_METADATA"===this.state&&(this.state="HAVE_METADATA")}},{key:"load",value:function(e){var t=this;p.default.clearTimeout(this.mediaUpdateTimeout);var n=this.media();if(e){var r=n?n.targetDuration/2*1e3:5e3;return void(this.mediaUpdateTimeout=p.default.setTimeout(function(){return t.load()},r))}if(!this.started)return void this.start();n&&!n.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist")}},{key:"start",value:function(){var e=this;this.started=!0,this.request=this.hls_.xhr({uri:this.srcUrl,withCredentials:this.withCredentials},function(t,n){if(e.request){if(e.request=null,t)return e.error={status:n.status,message:"HLS playlist request error at URL: "+e.srcUrl,responseText:n.responseText,code:2},"HAVE_NOTHING"===e.state&&(e.started=!1),e.trigger("error");var r=new f.default.Parser;return r.push(n.responseText),r.end(),e.state="HAVE_MASTER",e.srcUrl=e.resolveManifestRedirect(e.srcUrl,n),r.manifest.uri=e.srcUrl,r.manifest.playlists?(e.master=r.manifest,y(e.master),_(e.master),e.trigger("loadedplaylist"),void(e.request||e.media(r.manifest.playlists[0]))):(e.master={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:p.default.location.href,playlists:[{uri:e.srcUrl,resolvedUri:e.srcUrl,attributes:{}}]},e.master.playlists[e.srcUrl]=e.master.playlists[0],e.haveMetadata(n,e.srcUrl),e.trigger("loadedmetadata"))}})}}]),t}(c.EventTarget);n.default=T}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./resolve-url":15,"global/window":32,"m3u8-parser":33}],10:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./config"),a=r(i),o=e("./playlist"),s=r(o),u=e("./util/codecs.js"),l=function(e,t){var n=void 0;return e?(n=window.getComputedStyle(e),n?n[t]:""):""},c=function(e,t){var n=e.slice();e.sort(function(e,r){var i=t(e,r);return 0===i?n.indexOf(e)-n.indexOf(r):i})},d=function(e,t){var n=void 0,r=void 0;return e.attributes.BANDWIDTH&&(n=e.attributes.BANDWIDTH),n=n||window.Number.MAX_VALUE,t.attributes.BANDWIDTH&&(r=t.attributes.BANDWIDTH),r=r||window.Number.MAX_VALUE,n-r};n.comparePlaylistBandwidth=d;var f=function(e,t){var n=void 0,r=void 0;return e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(n=e.attributes.RESOLUTION.width),n=n||window.Number.MAX_VALUE,t.attributes.RESOLUTION&&t.attributes.RESOLUTION.width&&(r=t.attributes.RESOLUTION.width),r=r||window.Number.MAX_VALUE,n===r&&e.attributes.BANDWIDTH&&t.attributes.BANDWIDTH?e.attributes.BANDWIDTH-t.attributes.BANDWIDTH:n-r};n.comparePlaylistResolution=f;var h=function(e,t,n,r){var i=e.playlists.map(function(e){var t=void 0,n=void 0,r=void 0;return t=e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width,n=e.attributes.RESOLUTION&&e.attributes.RESOLUTION.height,r=e.attributes.BANDWIDTH,r=r||window.Number.MAX_VALUE,{bandwidth:r,width:t,height:n,playlist:e}});c(i,function(e,t){return e.bandwidth-t.bandwidth}),i=i.filter(function(e){return!s.default.isIncompatible(e.playlist)});var o=i.filter(function(e){return s.default.isEnabled(e.playlist)});o.length||(o=i.filter(function(e){return!s.default.isDisabled(e.playlist)}));var u=o.filter(function(e){return e.bandwidth*a.default.BANDWIDTH_VARIANCE<t}),l=u[u.length-1],d=u.filter(function(e){return e.bandwidth===l.bandwidth})[0],f=u.filter(function(e){return e.width&&e.height});c(f,function(e,t){return e.width-t.width});var h=f.filter(function(e){return e.width===n&&e.height===r});l=h[h.length-1];var p=h.filter(function(e){return e.bandwidth===l.bandwidth})[0],m=void 0,v=void 0,g=void 0;p||(m=f.filter(function(e){return e.width>n||e.height>r}),v=m.filter(function(e){return e.width===m[0].width&&e.height===m[0].height}),l=v[v.length-1],g=v.filter(function(e){return e.bandwidth===l.bandwidth})[0]);var y=g||p||d||o[0]||i[0];return y?y.playlist:null};n.simpleSelector=h;var p=function(){return h(this.playlists.master,this.systemBandwidth,parseInt(l(this.tech_.el(),"width"),10),parseInt(l(this.tech_.el(),"height"),10))};n.lastBandwidthSelector=p;var m=function(e){var t=-1;if(e<0||e>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){return t<0&&(t=this.systemBandwidth),t=e*this.systemBandwidth+(1-e)*t,h(this.playlists.master,t,parseInt(l(this.tech_.el(),"width"),10),parseInt(l(this.tech_.el(),"height"),10))}};n.movingAverageBandwidthSelector=m;var v=function(e){var t=e.master,n=e.currentTime,r=e.bandwidth,i=e.duration,a=e.segmentDuration,o=e.timeUntilRebuffer,u=e.currentTimeline,l=e.syncController,f=t.playlists.filter(function(e){return!s.default.isIncompatible(e)}),h=f.filter(s.default.isEnabled);h.length||(h=f.filter(function(e){return!s.default.isDisabled(e)}));var p=h.filter(s.default.hasAttribute.bind(null,"BANDWIDTH")),m=p.map(function(e){var t=l.getSyncPoint(e,i,u,n),c=t?1:2;return{playlist:e,rebufferingImpact:s.default.estimateSegmentRequestTime(a,r,e)*c-o}}),v=m.filter(function(e){return e.rebufferingImpact<=0});return c(v,function(e,t){return d(t.playlist,e.playlist)}),v.length?v[0]:(c(m,function(e,t){return e.rebufferingImpact-t.rebufferingImpact}),m[0]||null)};n.minRebufferMaxBandwidthSelector=v;var g=function(){var e=this.playlists.master.playlists.filter(s.default.isEnabled);return c(e,function(e,t){return d(e,t)}),e.filter(function(e){return(0,u.parseCodecs)(e.attributes.CODECS).videoCodec})[0]||null};n.lowestBitrateCompatibleVariantSelector=g},{"./config":3,"./playlist":11,"./util/codecs.js":19}],11:[function(e,t,n){(function(t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,i=e("global/window"),a=function(e){return e&&e.__esModule?e:{default:e}}(i),o=function(e,t){var n=0,r=t-e.mediaSequence,i=e.segments[r];if(i){if(void 0!==i.start)return{result:i.start,precise:!0};if(void 0!==i.end)return{result:i.end-i.duration,precise:!0}}for(;r--;){if(i=e.segments[r],void 0!==i.end)return{result:n+i.end,precise:!0};if(n+=i.duration,void 0!==i.start)return{result:n+i.start,precise:!0}}return{result:n,precise:!1}},s=function(e,t){for(var n=0,r=void 0,i=t-e.mediaSequence;i<e.segments.length;i++){if(r=e.segments[i],void 0!==r.start)return{result:r.start-n,precise:!0};if(n+=r.duration,void 0!==r.end)return{result:r.end-n,precise:!0}}return{result:-1,precise:!1}},u=function(e,t,n){var r=void 0,i=void 0;return void 0===t&&(t=e.mediaSequence+e.segments.length),t<e.mediaSequence?0:(r=o(e,t),r.precise?r.result:(i=s(e,t),i.precise?i.result:r.result+n))},l=function(e,t,n){if(!e)return 0;if("number"!=typeof n&&(n=0),void 0===t){if(e.totalDuration)return e.totalDuration;if(!e.endList)return a.default.Infinity}return u(e,t,n)};n.duration=l;var c=function(e,t,n){var r=0;if(t>n){var i=[n,t];t=i[0],n=i[1]}if(t<0){for(var a=t;a<Math.min(0,n);a++)r+=e.targetDuration;t=0}for(var a=t;a<n;a++)r+=e.segments[a].duration;return r};n.sumDurations=c;var d=function(e){if(!e.segments.length)return 0;for(var t=e.segments.length-1,n=e.segments[t].duration||e.targetDuration,r=n+2*e.targetDuration;t--&&!((n+=e.segments[t].duration)>=r););return Math.max(0,t)};n.safeLiveIndex=d;var f=function(e,t,n){if(!e||!e.segments)return null;if(e.endList)return l(e);if(null===t)return null;t=t||0;var r=n?d(e):e.segments.length;return u(e,e.mediaSequence+r,t)};n.playlistEnd=f;var h=function(e,t){var n=t||0,i=f(e,t,!0);return null===i?(0,r.createTimeRange)():(0,r.createTimeRange)(n,i)};n.seekable=h;var p=function(e){return e-Math.floor(e)==0},m=function(e,t){if(p(t))return t+.1*e;for(var n=t.toString().split(".")[1].length,r=1;r<=n;r++){var i=Math.pow(10,r),a=t*i;if(p(a)||r===n)return(a+e)/i}},v=m.bind(null,1),g=m.bind(null,-1),y=function(e,t,n,r){var i=void 0,a=void 0,o=e.segments.length,s=t-r;if(s<0){if(n>0)for(i=n-1;i>=0;i--)if(a=e.segments[i],(s+=g(a.duration))>0)return{mediaIndex:i,startTime:r-c(e,n,i)};return{mediaIndex:0,startTime:t}}if(n<0){for(i=n;i<0;i++)if((s-=e.targetDuration)<0)return{mediaIndex:0,startTime:t};n=0}for(i=n;i<o;i++)if(a=e.segments[i],(s-=v(a.duration))<0)return{mediaIndex:i,startTime:r+c(e,n,i)};return{mediaIndex:o-1,startTime:t}};n.getMediaInfoForTime=y;var _=function(e){return e.excludeUntil&&e.excludeUntil>Date.now()};n.isBlacklisted=_;var b=function(e){return e.excludeUntil&&e.excludeUntil===1/0};n.isIncompatible=b;var T=function(e){var t=_(e);return!e.disabled&&!t};n.isEnabled=T;var S=function(e){return e.disabled};n.isDisabled=S;var w=function(e){for(var t=0;t<e.segments.length;t++)if(e.segments[t].key)return!0;return!1};n.isAes=w;var k=function(e){for(var t=0;t<e.segments.length;t++)if(e.segments[t].map)return!0;return!1};n.isFmp4=k;var E=function(e,t){return t.attributes&&t.attributes[e]};n.hasAttribute=E;var A=function(e,t,n){var r=arguments.length<=3||void 0===arguments[3]?0:arguments[3];return E("BANDWIDTH",n)?(e*n.attributes.BANDWIDTH-8*r)/t:NaN};n.estimateSegmentRequestTime=A;var C=function(e,t){if(1===e.playlists.length)return!0;var n=t.attributes.BANDWIDTH||Number.MAX_VALUE;return 0===e.playlists.filter(function(e){return!!T(e)&&(e.attributes.BANDWIDTH||0)<n}).length};n.isLowestEnabledRendition=C,n.default={duration:l,seekable:h,safeLiveIndex:d,getMediaInfoForTime:y,isEnabled:T,isDisabled:S,isBlacklisted:_,isIncompatible:b,playlistEnd:f,isAes:w,isFmp4:k,hasAttribute:E,estimateSegmentRequestTime:A,isLowestEnabledRendition:C}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"global/window":32}],12:[function(e,t,n){(function(e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function e(e,t){var n=[],r=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(r=(o=s.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){i=!0,a=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw a}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),i="undefined"!=typeof window?window.videojs:void 0!==e?e.videojs:null,a=function(e){return e&&e.__esModule?e:{default:e}}(i),o=function(e,t){var n=r(t,2),i=n[0],a=n[1];return Math.min(Math.max(i,e),a)},s=function(e,t){var n=[],r=void 0;if(e&&e.length)for(r=0;r<e.length;r++)t(e.start(r),e.end(r))&&n.push([e.start(r),e.end(r)]);return a.default.createTimeRanges(n)},u=function(e,t){return s(e,function(e,n){return e-1/30<=t&&n+1/30>=t})},l=function(e,t){return s(e,function(e){return e-1/30>=t})},c=function(e){if(e.length<2)return a.default.createTimeRanges();for(var t=[],n=1;n<e.length;n++){var r=e.end(n-1),i=e.start(n);t.push([r,i])}return a.default.createTimeRanges(t)},d=function(e,t){var n=void 0,r=void 0,i=void 0,a=[],o=[],s=function(e){return e[0]<=i&&e[1]>=i};if(e)for(n=0;n<e.length;n++)r=e.start(n),i=e.end(n),o.push([r,i]);if(t)for(n=0;n<t.length;n++)r=t.start(n),i=t.end(n),o.some(s)||a.push(i);return 1!==a.length?null:a[0]},f=function(e,t){var n=null,r=null,i=0,o=[],s=[];if(!(e&&e.length&&t&&t.length))return a.default.createTimeRange();for(var u=e.length;u--;)o.push({time:e.start(u),type:"start"}),o.push({time:e.end(u),type:"end"});for(u=t.length;u--;)o.push({time:t.start(u),type:"start"}),o.push({time:t.end(u),type:"end"});for(o.sort(function(e,t){return e.time-t.time}),u=0;u<o.length;u++)"start"===o[u].type?2==++i&&(n=o[u].time):"end"===o[u].type&&1==--i&&(r=o[u].time),null!==n&&null!==r&&(s.push([n,r]),n=null,r=null);return a.default.createTimeRanges(s)},h=function(e,t,n,r){for(var i=t.end(0)-t.start(0),a=e.end(0)-e.start(0),o=i-a,s=f(e,r),u=f(t,r),l=0,c=0,d=s.length;d--;)l+=s.end(d)-s.start(d),s.start(d)===n&&(l+=o);for(d=u.length;d--;)c+=u.end(d)-u.start(d);return Math.max(l,c)/i*100},p=function(e,t,n,r){var i=e+t,s=a.default.createTimeRanges([[e,i]]),u=a.default.createTimeRanges([[o(e,[n,i]),i]]);if(u.start(0)===u.end(0))return 0;var l=h(u,s,n,r);return isNaN(l)||l===1/0||l===-1/0?0:l},m=function(e){var t=[];if(!e||!e.length)return"";for(var n=0;n<e.length;n++)t.push(e.start(n)+" => "+e.end(n));return t.join(", ")},v=function(e,t){var n=arguments.length<=2||void 0===arguments[2]?1:arguments[2];return((e.length?e.end(e.length-1):0)-t)/n};n.default={findRange:u,findNextRange:l,findGaps:c,findSoleUncommonTimeRangesEnd:d,getSegmentBufferedPercent:p,TIME_FUDGE_FACTOR:1/30,SAFE_TIME_DELTA:.1,printableRange:m,timeUntilRebuffer:v},t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],13:[function(e,t,n){(function(e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="undefined"!=typeof window?window.videojs:void 0!==e?e.videojs:null,i=function(e){return e&&e.__esModule?e:{default:e}}(r),a={errorInterval:30,getSource:function(e){return e(this.tech({IWillNotUseThisInPlugins:!0}).currentSource_)}},o=function e(t,n){var r=0,o=0,s=i.default.mergeOptions(a,n);t.ready(function(){t.trigger({type:"usage",name:"hls-error-reload-initialized"})});var u=function(){o&&t.currentTime(o)},l=function(e){null!==e&&void 0!==e&&(o=t.duration()!==1/0&&t.currentTime()||0,t.one("loadedmetadata",u),t.src(e),t.trigger({type:"usage",name:"hls-error-reload"}),t.play())},c=function(){return Date.now()-r<1e3*s.errorInterval?void t.trigger({type:"usage",name:"hls-error-reload-canceled"}):s.getSource&&"function"==typeof s.getSource?(r=Date.now(),s.getSource.call(t,l)):void i.default.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!")},d=function e(){t.off("loadedmetadata",u),t.off("error",c),t.off("dispose",e)},f=function(n){d(),e(t,n)};t.on("error",c),t.on("dispose",d),t.reloadSourceOnError=f},s=function(e){o(this,e)};n.default=s,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],14:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./playlist.js"),a=function(e,t,n){return function(r){var a=e.master.playlists[t],o=(0,i.isIncompatible)(a),s=(0,i.isEnabled)(a);return void 0===r?s:(r?delete a.disabled:a.disabled=!0,r===s||o||(n(),r?e.trigger("renditionenabled"):e.trigger("renditiondisabled")),r)}},o=function e(t,n,i){r(this,e);var o=t.masterPlaylistController_.fastQualityChange_.bind(t.masterPlaylistController_);if(n.attributes.RESOLUTION){var s=n.attributes.RESOLUTION;this.width=s.width,this.height=s.height}this.bandwidth=n.attributes.BANDWIDTH,this.id=i,this.enabled=a(t.playlists,n.uri,o)},s=function(e){var t=e.playlists;e.representations=function(){return t.master.playlists.filter(function(e){return!(0,i.isIncompatible)(e)}).map(function(t,n){return new o(e,t,t.uri)})}};n.default=s,t.exports=n.default},{"./playlist.js":11}],15:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("url-toolkit"),a=r(i),o=e("global/window"),s=r(o),u=function(e,t){return/^[a-z]+:/i.test(t)?t:(/\/\//i.test(e)||(e=a.default.buildAbsoluteURL(s.default.location.href,e)),a.default.buildAbsoluteURL(e,t))};n.default=u,t.exports=n.default},{"global/window":32,"url-toolkit":63}],16:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},u=e("./playlist"),l=r(u),c="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,d=r(c),f=e("./source-updater"),h=r(f),p=e("./config"),m=r(p),v=e("global/window"),g=r(v),y=e("videojs-contrib-media-sources/es5/remove-cues-from-track.js"),_=r(y),b=e("./bin-utils"),T=e("./media-segment-request"),S=e("./ranges"),w=e("./playlist-selectors"),k=function(e,t,n){if(!e||!t)return!1;var r=e.segments,i=n===r.length;return e.endList&&"open"===t.readyState&&i},E=function(e){return"number"==typeof e&&isFinite(e)},A=function(e,t,n){return"main"===e&&t&&n?n.containsAudio||n.containsVideo?t.containsVideo&&!n.containsVideo?"Only audio found in segment when we expected video. We can't switch to audio only from a stream that had video. To get rid of this message, please add codec information to the manifest.":!t.containsVideo&&n.containsVideo?"Video found in segment when we expected only audio. We can't switch to a stream with video from an audio only stream. To get rid of this message, please add codec information to the manifest.":null:"Neither audio nor video found in segment.":null};n.illegalMediaSwitch=A;var C=function(e,t,n){var r=void 0;return r=e.length&&e.start(0)>0&&e.start(0)<t?e.start(0):t-30,Math.min(r,t-n)};n.safeBackBufferTrimTime=C;var L=function(e){function t(e){var n=this,r=arguments.length<=1||void 0===arguments[1]?{}:arguments[1];if(i(this,t),s(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),!e)throw new TypeError("Initialization settings are required");if("function"!=typeof e.currentTime)throw new TypeError("No currentTime getter specified");if(!e.mediaSource)throw new TypeError("No MediaSource specified");this.state="INIT",this.bandwidth=e.bandwidth,this.throughput={rate:0,count:0},this.roundTrip=NaN,this.resetStats_(),this.mediaIndex=null,this.hasPlayed_=e.hasPlayed,this.currentTime_=e.currentTime,this.seekable_=e.seekable,this.seeking_=e.seeking,this.duration_=e.duration,this.mediaSource_=e.mediaSource,this.hls_=e.hls,this.loaderType_=e.loaderType,this.startingMedia_=void 0,this.segmentMetadataTrack_=e.segmentMetadataTrack,this.goalBufferLength_=e.goalBufferLength,this.checkBufferTimeout_=null,this.error_=void 0,this.currentTimeline_=-1,this.pendingSegment_=null,this.mimeType_=null,this.sourceUpdater_=null,this.xhrOptions_=null,this.activeInitSegmentId_=null,this.initSegments_={},this.decrypter_=e.decrypter,this.syncController_=e.syncController,this.syncPoint_={segmentIndex:0,time:0},this.syncController_.on("syncinfoupdate",function(){return n.trigger("syncinfoupdate")}),this.mediaSource_.addEventListener("sourceopen",function(){return n.ended_=!1}),this.fetchAtBuffer_=!1,r.debug&&(this.logger_=d.default.log.bind(d.default,"segment-loader",this.loaderType_,"->"))}return a(t,e),o(t,[{key:"resetStats_",value:function(){this.mediaBytesTransferred=0,this.mediaRequests=0,this.mediaRequestsAborted=0,this.mediaRequestsTimedout=0,this.mediaRequestsErrored=0,this.mediaTransferDuration=0,this.mediaSecondsLoaded=0}},{key:"dispose",value:function(){this.state="DISPOSED",this.pause(),this.abort_(),this.sourceUpdater_&&this.sourceUpdater_.dispose(),this.resetStats_()}},{key:"abort",value:function(){if("WAITING"!==this.state)return void(this.pendingSegment_&&(this.pendingSegment_=null));this.abort_(),this.state="READY",this.paused()||this.monitorBuffer_()}},{key:"abort_",value:function(){this.pendingSegment_&&this.pendingSegment_.abortRequests(),this.pendingSegment_=null}},{key:"error",value:function(e){return void 0!==e&&(this.error_=e),this.pendingSegment_=null,this.error_}},{key:"endOfStream",value:function(){this.ended_=!0,this.pause(),this.trigger("ended")}},{key:"buffered_",value:function(){return this.sourceUpdater_?this.sourceUpdater_.buffered():d.default.createTimeRanges()}},{key:"initSegment",value:function(e){var t=!(arguments.length<=1||void 0===arguments[1])&&arguments[1];if(!e)return null;var n=(0,b.initSegmentId)(e),r=this.initSegments_[n];return t&&!r&&e.bytes&&(this.initSegments_[n]=r={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:e.bytes}),r||e}},{key:"couldBeginLoading_",value:function(){return this.playlist_&&(this.sourceUpdater_||this.mimeType_&&"INIT"===this.state)&&!this.paused()}},{key:"load",value:function(){if(this.monitorBuffer_(),this.playlist_){if(this.syncController_.setDateTimeMapping(this.playlist_),"INIT"===this.state&&this.couldBeginLoading_())return this.init_();!this.couldBeginLoading_()||"READY"!==this.state&&"INIT"!==this.state||(this.state="READY")}}},{key:"init_",value:function(){return this.state="READY",this.sourceUpdater_=new h.default(this.mediaSource_,this.mimeType_),this.resetEverything(),this.monitorBuffer_()}},{key:"playlist",value:function(e){var t=arguments.length<=1||void 0===arguments[1]?{}:arguments[1];if(e){var n=this.playlist_,r=this.pendingSegment_;if(this.playlist_=e,this.xhrOptions_=t,this.hasPlayed_()||(e.syncInfo={mediaSequence:e.mediaSequence,time:0}),this.trigger("syncinfoupdate"),"INIT"===this.state&&this.couldBeginLoading_())return this.init_();if(!n||n.uri!==e.uri)return void(null!==this.mediaIndex&&this.resyncLoader());var i=e.mediaSequence-n.mediaSequence;this.logger_("mediaSequenceDiff",i),null!==this.mediaIndex&&(this.mediaIndex-=i),r&&(r.mediaIndex-=i,r.mediaIndex>=0&&(r.segment=e.segments[r.mediaIndex])),this.syncController_.saveExpiredSegmentInfo(n,e)}}},{key:"pause",value:function(){this.checkBufferTimeout_&&(g.default.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=null)}},{key:"paused",value:function(){return null===this.checkBufferTimeout_}},{key:"mimeType",value:function(e){this.mimeType_||(this.mimeType_=e,"INIT"===this.state&&this.couldBeginLoading_()&&this.init_())}},{key:"resetEverything",value:function(){this.ended_=!1,this.resetLoader(),this.remove(0,this.duration_()),this.trigger("reseteverything")}},{key:"resetLoader",value:function(){this.fetchAtBuffer_=!1,this.resyncLoader()}},{key:"resyncLoader",value:function(){this.mediaIndex=null,this.syncPoint_=null,this.abort()}},{key:"remove",value:function(e,t){this.sourceUpdater_&&this.sourceUpdater_.remove(e,t),(0,_.default)(e,t,this.segmentMetadataTrack_)}},{key:"monitorBuffer_",value:function(){this.checkBufferTimeout_&&g.default.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=g.default.setTimeout(this.monitorBufferTick_.bind(this),1)}},{key:"monitorBufferTick_",value:function(){"READY"===this.state&&this.fillBuffer_(),this.checkBufferTimeout_&&g.default.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=g.default.setTimeout(this.monitorBufferTick_.bind(this),500)}},{key:"fillBuffer_",value:function(){if(!this.sourceUpdater_.updating()){this.syncPoint_||(this.syncPoint_=this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_()));var e=this.checkBuffer_(this.buffered_(),this.playlist_,this.mediaIndex,this.hasPlayed_(),this.currentTime_(),this.syncPoint_);if(e){if(k(this.playlist_,this.mediaSource_,e.mediaIndex))return void this.endOfStream();(e.mediaIndex!==this.playlist_.segments.length-1||"ended"!==this.mediaSource_.readyState||this.seeking_())&&((e.timeline!==this.currentTimeline_||null!==e.startOfSegment&&e.startOfSegment<this.sourceUpdater_.timestampOffset())&&(this.syncController_.reset(),e.timestampOffset=e.startOfSegment),this.loadSegment_(e))}}}},{key:"checkBuffer_",value:function(e,t,n,r,i,a){var o=0,s=void 0;e.length&&(o=e.end(e.length-1));var u=Math.max(0,o-i);if(!t.segments.length)return null;if(u>=this.goalBufferLength_())return null;if(!r&&u>=1)return null;if(this.logger_("checkBuffer_","mediaIndex:",n,"hasPlayed:",r,"currentTime:",i,"syncPoint:",a,"fetchAtBuffer:",this.fetchAtBuffer_,"bufferedTime:",u),null===a)return n=this.getSyncSegmentCandidate_(t),this.logger_("getSync","mediaIndex:",n),this.generateSegmentInfo_(t,n,null,!0);if(null!==n){this.logger_("walkForward","mediaIndex:",n+1);var c=t.segments[n];return s=c&&c.end?c.end:o,this.generateSegmentInfo_(t,n+1,s,!1)}if(this.fetchAtBuffer_){var d=l.default.getMediaInfoForTime(t,o,a.segmentIndex,a.time);n=d.mediaIndex,s=d.startTime}else{var d=l.default.getMediaInfoForTime(t,i,a.segmentIndex,a.time);n=d.mediaIndex,s=d.startTime}return this.logger_("getMediaIndexForTime","mediaIndex:",n,"startOfSegment:",s),this.generateSegmentInfo_(t,n,s,!1)}},{key:"getSyncSegmentCandidate_",value:function(e){var t=this;if(-1===this.currentTimeline_)return 0;var n=e.segments.map(function(e,t){return{timeline:e.timeline,segmentIndex:t}}).filter(function(e){return e.timeline===t.currentTimeline_});return n.length?n[Math.min(n.length-1,1)].segmentIndex:Math.max(e.segments.length-1,0)}},{key:"generateSegmentInfo_",value:function(e,t,n,r){if(t<0||t>=e.segments.length)return null;var i=e.segments[t];return{requestId:"segment-loader-"+Math.random(),uri:i.resolvedUri,mediaIndex:t,isSyncRequest:r,startOfSegment:n,playlist:e,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:i.timeline,duration:i.duration,segment:i}}},{key:"abortRequestEarly_",value:function(e){if(this.hls_.tech_.paused()||!this.xhrOptions_.timeout||!this.playlist_.attributes.BANDWIDTH)return!1;if(Date.now()-(e.firstBytesReceivedAt||Date.now())<1e3)return!1;var t=this.currentTime_(),n=e.bandwidth,r=this.pendingSegment_.duration,i=l.default.estimateSegmentRequestTime(r,n,this.playlist_,e.bytesReceived),a=(0,S.timeUntilRebuffer)(this.buffered_(),t,this.hls_.tech_.playbackRate())-1;if(i<=a)return!1;var o=(0,w.minRebufferMaxBandwidthSelector)({master:this.hls_.playlists.master,currentTime:t,bandwidth:n,duration:this.duration_(),segmentDuration:r,timeUntilRebuffer:a,currentTimeline:this.currentTimeline_,syncController:this.syncController_});if(o){var s=i-a,u=s-o.rebufferingImpact,c=.5;return a<=S.TIME_FUDGE_FACTOR&&(c=1),!(!o.playlist||o.playlist.uri===this.playlist_.uri||u<c)&&(this.bandwidth=o.playlist.attributes.BANDWIDTH*m.default.BANDWIDTH_VARIANCE+1,this.abort(),this.trigger("earlyabort"),!0)}}},{key:"handleProgress_",value:function(e,t){this.pendingSegment_&&t.requestId===this.pendingSegment_.requestId&&!this.abortRequestEarly_(t.stats)&&this.trigger("progress")}},{key:"loadSegment_",value:function(e){this.state="WAITING",this.pendingSegment_=e,this.trimBackBuffer_(e),e.abortRequests=(0,T.mediaSegmentRequest)(this.hls_.xhr,this.xhrOptions_,this.decrypter_,this.createSimplifiedSegmentObj_(e),this.handleProgress_.bind(this),this.segmentRequestFinished_.bind(this))}},{key:"trimBackBuffer_",value:function(e){var t=C(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);t>0&&this.remove(0,t)}},{key:"createSimplifiedSegmentObj_",value:function(e){var t=e.segment,n={resolvedUri:t.resolvedUri,byterange:t.byterange,requestId:e.requestId};if(t.key){var r=t.key.iv||new Uint32Array([0,0,0,e.mediaIndex+e.playlist.mediaSequence]);n.key={resolvedUri:t.key.resolvedUri,iv:r}}return t.map&&(n.map=this.initSegment(t.map)),n}},{key:"segmentRequestFinished_",value:function(e,t){if(this.mediaRequests+=1,t.stats&&(this.mediaBytesTransferred+=t.stats.bytesReceived,this.mediaTransferDuration+=t.stats.roundTripTime),!this.pendingSegment_)return void(this.mediaRequestsAborted+=1);if(t.requestId===this.pendingSegment_.requestId){if(e)return this.pendingSegment_=null,this.state="READY",e.code===T.REQUEST_ERRORS.ABORTED?void(this.mediaRequestsAborted+=1):(this.pause(),e.code===T.REQUEST_ERRORS.TIMEOUT?(this.mediaRequestsTimedout+=1,this.bandwidth=1,this.roundTrip=NaN,void this.trigger("bandwidthupdate")):(this.mediaRequestsErrored+=1,this.error(e),void this.trigger("error")));this.bandwidth=t.stats.bandwidth,this.roundTrip=t.stats.roundTripTime,t.map&&(t.map=this.initSegment(t.map,!0)),this.processSegmentResponse_(t)}}},{key:"processSegmentResponse_",value:function(e){var t=this.pendingSegment_;t.bytes=e.bytes,e.map&&(t.segment.map.bytes=e.map.bytes),t.endOfAllRequests=e.endOfAllRequests,this.handleSegment_()}},{key:"handleSegment_",value:function(){var e=this;if(!this.pendingSegment_)return void(this.state="READY");var t=this.pendingSegment_,n=t.segment,r=this.syncController_.probeSegmentInfo(t);void 0===this.startingMedia_&&r&&(r.containsAudio||r.containsVideo)&&(this.startingMedia_={containsAudio:r.containsAudio,containsVideo:r.containsVideo});var i=A(this.loaderType_,this.startingMedia_,r);if(i)return this.error({message:i,blacklistDuration:1/0}),void this.trigger("error");if(t.isSyncRequest)return this.trigger("syncinfoupdate"),this.pendingSegment_=null,void(this.state="READY");null!==t.timestampOffset&&t.timestampOffset!==this.sourceUpdater_.timestampOffset()&&(this.sourceUpdater_.timestampOffset(t.timestampOffset),this.trigger("timestampoffset"));var a=this.syncController_.mappingForTimeline(t.timeline);null!==a&&this.trigger({type:"segmenttimemapping",mapping:a}),this.state="APPENDING",n.map&&function(){var t=(0,b.initSegmentId)(n.map);if(!e.activeInitSegmentId_||e.activeInitSegmentId_!==t){var r=e.initSegment(n.map);e.sourceUpdater_.appendBuffer(r.bytes,function(){e.activeInitSegmentId_=t})}}(),t.byteLength=t.bytes.byteLength,"number"==typeof n.start&&"number"==typeof n.end?this.mediaSecondsLoaded+=n.end-n.start:this.mediaSecondsLoaded+=n.duration,this.sourceUpdater_.appendBuffer(t.bytes,this.handleUpdateEnd_.bind(this))}},{key:"handleUpdateEnd_",value:function(){if(this.logger_("handleUpdateEnd_","segmentInfo:",this.pendingSegment_),!this.pendingSegment_)return this.state="READY",void(this.paused()||this.monitorBuffer_());var e=this.pendingSegment_,t=e.segment,n=null!==this.mediaIndex;if(this.pendingSegment_=null,this.recordThroughput_(e),this.addSegmentMetadataCue_(e),this.state="READY",this.mediaIndex=e.mediaIndex,this.fetchAtBuffer_=!0,this.currentTimeline_=e.timeline,this.trigger("syncinfoupdate"),t.end&&this.currentTime_()-t.end>3*e.playlist.targetDuration)return void this.resetEverything();n&&this.trigger("bandwidthupdate"),this.trigger("progress"),k(e.playlist,this.mediaSource_,e.mediaIndex+1)&&this.endOfStream(),this.paused()||this.monitorBuffer_()}},{key:"recordThroughput_",value:function(e){var t=this.throughput.rate,n=Date.now()-e.endOfAllRequests+1,r=Math.floor(e.byteLength/n*8*1e3);this.throughput.rate+=(r-t)/++this.throughput.count}},{key:"logger_",value:function(){}},{key:"addSegmentMetadataCue_",value:function(e){if(this.segmentMetadataTrack_){var t=e.segment,n=t.start,r=t.end;if(E(n)&&E(r)){(0,_.default)(n,r,this.segmentMetadataTrack_);var i=g.default.WebKitDataCue||g.default.VTTCue,a={bandwidth:e.playlist.attributes.BANDWIDTH,resolution:e.playlist.attributes.RESOLUTION,codecs:e.playlist.attributes.CODECS,byteLength:e.byteLength,uri:e.uri,timeline:e.timeline,playlist:e.playlist.uri,start:n,end:r},o=JSON.stringify(a),s=new i(n,r,o);s.value=a,this.segmentMetadataTrack_.addCue(s)}}}}]),t}(d.default.EventTarget);n.default=L}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./bin-utils":2,"./config":3,"./media-segment-request":7,"./playlist":11,"./playlist-selectors":10,"./ranges":12,"./source-updater":17,"global/window":32,"videojs-contrib-media-sources/es5/remove-cues-from-track.js":72}],17:[function(e,t,n){(function(e){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a="undefined"!=typeof window?window.videojs:void 0!==e?e.videojs:null,o=function(e){return e&&e.__esModule?e:{default:e}}(a),s=function(){},u=function(){function e(t,n){var i=this;r(this,e);var a=function(){i.sourceBuffer_=t.addSourceBuffer(n),i.onUpdateendCallback_=function(){var e=i.pendingCallback_;i.pendingCallback_=null,e&&e(),i.runCallback_()},i.sourceBuffer_.addEventListener("updateend",i.onUpdateendCallback_),i.runCallback_()};this.callbacks_=[],this.pendingCallback_=null,this.timestampOffset_=0,this.mediaSource=t,this.processedAppend_=!1,"closed"===t.readyState?t.addEventListener("sourceopen",a):a()}return i(e,[{key:"abort",value:function(e){var t=this;this.processedAppend_&&this.queueCallback_(function(){t.sourceBuffer_.abort()},e)}},{key:"appendBuffer",value:function(e,t){var n=this;this.processedAppend_=!0,this.queueCallback_(function(){n.sourceBuffer_.appendBuffer(e)},t)}},{key:"buffered",value:function(){return this.sourceBuffer_?this.sourceBuffer_.buffered:o.default.createTimeRanges()}},{key:"remove",value:function(e,t){var n=this;this.processedAppend_&&this.queueCallback_(function(){n.sourceBuffer_.remove(e,t)},s)}},{key:"updating",value:function(){return!this.sourceBuffer_||this.sourceBuffer_.updating||this.pendingCallback_}},{key:"timestampOffset",value:function(e){var t=this;return void 0!==e&&(this.queueCallback_(function(){t.sourceBuffer_.timestampOffset=e}),this.timestampOffset_=e),this.timestampOffset_}},{key:"queueCallback_",value:function(e,t){this.callbacks_.push([e.bind(this),t]),this.runCallback_()}},{key:"runCallback_",value:function(){var e=void 0;!this.updating()&&this.callbacks_.length&&(e=this.callbacks_.shift(),this.pendingCallback_=e[1],e[0]())}},{key:"dispose",value:function(){this.sourceBuffer_.removeEventListener("updateend",this.onUpdateendCallback_),this.sourceBuffer_&&"open"===this.mediaSource.readyState&&this.sourceBuffer_.abort()}}]),e}();n.default=u,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],18:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},u=e("mux.js/lib/mp4/probe"),l=r(u),c=e("mux.js/lib/tools/ts-inspector.js"),d=e("./playlist"),f="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,h=r(f),p=[{name:"VOD",run:function(e,t,n,r,i){return n!==1/0?{time:0,segmentIndex:0}:null}},{name:"ProgramDateTime",run:function(e,t,n,r,i){return e.datetimeToDisplayTime&&t.dateTimeObject?{time:t.dateTimeObject.getTime()/1e3+e.datetimeToDisplayTime,segmentIndex:0}:null}},{name:"Segment",run:function(e,t,n,r,i){var a=t.segments||[],o=null,s=null;i=i||0;for(var u=0;u<a.length;u++){var l=a[u];if(l.timeline===r&&void 0!==l.start){var c=Math.abs(i-l.start);if(null!==s&&s<c)break;(!o||null===s||s>=c)&&(s=c,o={time:l.start,segmentIndex:u})}}return o}},{name:"Discontinuity",run:function(e,t,n,r,i){var a=null;if(i=i||0,t.discontinuityStarts&&t.discontinuityStarts.length)for(var o=null,s=0;s<t.discontinuityStarts.length;s++){var u=t.discontinuityStarts[s],l=t.discontinuitySequence+s+1,c=e.discontinuities[l];if(c){var d=Math.abs(i-c.time);if(null!==o&&o<d)break;(!a||null===o||o>=d)&&(o=d,a={time:c.time,segmentIndex:u})}}return a}},{name:"Playlist",run:function(e,t,n,r,i){return t.syncInfo?{time:t.syncInfo.time,segmentIndex:t.syncInfo.mediaSequence-t.mediaSequence}:null}}];n.syncPointStrategies=p;var m=function(e){function t(){var e=arguments.length<=0||void 0===arguments[0]?{}:arguments[0];i(this,t),s(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),this.inspectCache_=void 0,this.timelines=[],this.discontinuities=[],this.datetimeToDisplayTime=null,e.debug&&(this.logger_=h.default.log.bind(h.default,"sync-controller ->"))}return a(t,e),o(t,[{key:"getSyncPoint",value:function(e,t,n,r){var i=this.runStrategies_(e,t,n,r);return i.length?this.selectSyncPoint_(i,{key:"time",value:r}):null}},{key:"getExpiredTime",value:function(e,t){if(!e||!e.segments)return null;var n=this.runStrategies_(e,t,e.discontinuitySequence,0);if(!n.length)return null;var r=this.selectSyncPoint_(n,{key:"segmentIndex",value:0});return r.segmentIndex>0&&(r.time*=-1),Math.abs(r.time+(0,d.sumDurations)(e,r.segmentIndex,0))}},{key:"runStrategies_",value:function(e,t,n,r){for(var i=[],a=0;a<p.length;a++){var o=p[a],s=o.run(this,e,t,n,r);s&&(s.strategy=o.name,i.push({strategy:o.name,syncPoint:s}),this.logger_("syncPoint found via <"+o.name+">:",s))}return i}},{key:"selectSyncPoint_",value:function(e,t){for(var n=e[0].syncPoint,r=Math.abs(e[0].syncPoint[t.key]-t.value),i=e[0].strategy,a=1;a<e.length;a++){var o=Math.abs(e[a].syncPoint[t.key]-t.value);o<r&&(r=o,n=e[a].syncPoint,i=e[a].strategy)}return this.logger_("syncPoint with strategy <"+i+"> chosen: ",n),n}},{key:"saveExpiredSegmentInfo",value:function(e,t){for(var n=t.mediaSequence-e.mediaSequence,r=n-1;r>=0;r--){var i=e.segments[r];if(i&&void 0!==i.start){t.syncInfo={mediaSequence:e.mediaSequence+r,time:i.start},this.logger_("playlist sync:",t.syncInfo),this.trigger("syncinfoupdate");break}}}},{key:"setDateTimeMapping",value:function(e){if(!this.datetimeToDisplayTime&&e.dateTimeObject){var t=e.dateTimeObject.getTime()/1e3;this.datetimeToDisplayTime=-t}}},{key:"reset",value:function(){this.inspectCache_=void 0}},{key:"probeSegmentInfo",value:function(e){var t=e.segment,n=e.playlist,r=void 0;return r=t.map?this.probeMp4Segment_(e):this.probeTsSegment_(e),r&&this.calculateSegmentTimeMapping_(e,r)&&(this.saveDiscontinuitySyncInfo_(e),n.syncInfo||(n.syncInfo={mediaSequence:n.mediaSequence+e.mediaIndex,time:t.start})),r}},{key:"probeMp4Segment_",value:function(e){var t=e.segment,n=l.default.timescale(t.map.bytes),r=l.default.startTime(n,e.bytes);return null!==e.timestampOffset&&(e.timestampOffset-=r),{start:r,end:r+t.duration}}},{key:"probeTsSegment_",value:function(e){var t=(0,c.inspect)(e.bytes,this.inspectCache_),n=void 0,r=void 0;return t?(t.video&&2===t.video.length?(this.inspectCache_=t.video[1].dts,n=t.video[0].dtsTime,r=t.video[1].dtsTime):t.audio&&2===t.audio.length&&(this.inspectCache_=t.audio[1].dts,n=t.audio[0].dtsTime,r=t.audio[1].dtsTime),{start:n,end:r,containsVideo:t.video&&2===t.video.length,containsAudio:t.audio&&2===t.audio.length}):null}},{key:"timestampOffsetForTimeline",value:function(e){return void 0===this.timelines[e]?null:this.timelines[e].time}},{key:"mappingForTimeline",value:function(e){return void 0===this.timelines[e]?null:this.timelines[e].mapping}},{key:"calculateSegmentTimeMapping_",value:function(e,t){var n=e.segment,r=this.timelines[e.timeline];if(null!==e.timestampOffset)this.logger_("tsO:",e.timestampOffset),r={time:e.startOfSegment,mapping:e.startOfSegment-t.start},this.timelines[e.timeline]=r,this.trigger("timestampoffset"),n.start=e.startOfSegment,n.end=t.end+r.mapping;else{if(!r)return!1;n.start=t.start+r.mapping,n.end=t.end+r.mapping}return!0}},{key:"saveDiscontinuitySyncInfo_",value:function(e){var t=e.playlist,n=e.segment;if(n.discontinuity)this.discontinuities[n.timeline]={time:n.start,accuracy:0};else if(t.discontinuityStarts.length)for(var r=0;r<t.discontinuityStarts.length;r++){var i=t.discontinuityStarts[r],a=t.discontinuitySequence+r+1,o=i-e.mediaIndex,s=Math.abs(o);if(!this.discontinuities[a]||this.discontinuities[a].accuracy>s){var u=void 0;u=o<0?n.start-(0,d.sumDurations)(t,e.mediaIndex,i):n.end+(0,d.sumDurations)(t,e.mediaIndex+1,i),this.discontinuities[a]={time:u,accuracy:s}}}}},{key:"logger_",value:function(){}}]),t}(h.default.EventTarget);n.default=m}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./playlist":11,"mux.js/lib/mp4/probe":57,"mux.js/lib/tools/ts-inspector.js":59}],19:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(){var e=arguments.length<=0||void 0===arguments[0]?"":arguments[0],t={codecCount:0},n=void 0;return t.codecCount=e.split(",").length,t.codecCount=t.codecCount||2,n=/(^|\s|,)+(avc1)([^ ,]*)/i.exec(e),n&&(t.videoCodec=n[2],t.videoObjectTypeIndicator=n[3]),t.audioProfile=/(^|\s|,)+mp4a.[0-9A-Fa-f]+\.([0-9A-Fa-f]+)/i.exec(e),t.audioProfile=t.audioProfile&&t.audioProfile[2],t};n.parseCodecs=r},{}],20:[function(e,t,n){(function(r){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},l=e("./segment-loader"),c=i(l),d="undefined"!=typeof window?window.videojs:void 0!==r?r.videojs:null,f=i(d),h=e("global/window"),p=i(h),m=e("videojs-contrib-media-sources/es5/remove-cues-from-track.js"),v=i(m),g=e("./bin-utils"),y=new Uint8Array("\n\n".split("").map(function(e){return e.charCodeAt(0)})),_=function(e){return String.fromCharCode.apply(null,e)},b=function(e){function t(e){var n=arguments.length<=1||void 0===arguments[1]?{}:arguments[1];a(this,t),u(Object.getPrototypeOf(t.prototype),"constructor",this).call(this,e,n),this.mediaSource_=null,this.subtitlesTrack_=null}return o(t,e),s(t,[{key:"buffered_",value:function(){if(!this.subtitlesTrack_||!this.subtitlesTrack_.cues.length)return f.default.createTimeRanges();var e=this.subtitlesTrack_.cues,t=e[0].startTime,n=e[e.length-1].startTime;return f.default.createTimeRanges([[t,n]])}},{key:"initSegment",value:function(e){var t=!(arguments.length<=1||void 0===arguments[1])&&arguments[1];if(!e)return null;var n=(0,g.initSegmentId)(e),r=this.initSegments_[n];if(t&&!r&&e.bytes){var i=y.byteLength+e.bytes.byteLength,a=new Uint8Array(i);a.set(e.bytes),a.set(y,e.bytes.byteLength),this.initSegments_[n]=r={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:a}}return r||e}},{key:"couldBeginLoading_",value:function(){return this.playlist_&&this.subtitlesTrack_&&!this.paused()}},{key:"init_",value:function(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()}},{key:"track",value:function(e){return void 0===e?this.subtitlesTrack_:(this.subtitlesTrack_=e,"INIT"===this.state&&this.couldBeginLoading_()&&this.init_(),this.subtitlesTrack_)}},{key:"remove",value:function(e,t){(0,v.default)(e,t,this.subtitlesTrack_)}},{key:"fillBuffer_",value:function(){var e=this;this.syncPoint_||(this.syncPoint_=this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_()));var t=this.checkBuffer_(this.buffered_(),this.playlist_,this.mediaIndex,this.hasPlayed_(),this.currentTime_(),this.syncPoint_);if(t=this.skipEmptySegments_(t)){if(null===this.syncController_.timestampOffsetForTimeline(t.timeline)){var n=function(){e.state="READY",e.paused()||e.monitorBuffer_()};return this.syncController_.one("timestampoffset",n),void(this.state="WAITING_ON_TIMELINE")}this.loadSegment_(t)}}},{key:"skipEmptySegments_",value:function(e){for(;e&&e.segment.empty;)e=this.generateSegmentInfo_(e.playlist,e.mediaIndex+1,e.startOfSegment+e.duration,e.isSyncRequest);return e}},{key:"handleSegment_",value:function(){var e=this;if(!this.pendingSegment_||!this.subtitlesTrack_)return void(this.state="READY");this.state="APPENDING";var t=this.pendingSegment_,n=t.segment;if("function"!=typeof p.default.WebVTT&&this.subtitlesTrack_&&this.subtitlesTrack_.tech_){var r=function(){var t=function(){e.handleSegment_()};return e.state="WAITING_ON_VTTJS",e.subtitlesTrack_.tech_.one("vttjsloaded",t),e.subtitlesTrack_.tech_.one("vttjserror",function(){e.subtitlesTrack_.tech_.off("vttjsloaded",t),e.error({message:"Error loading vtt.js"}),e.state="READY",e.pause(),e.trigger("error")}),{v:void 0}}();if("object"==typeof r)return r.v}n.requested=!0;try{this.parseVTTCues_(t)}catch(e){return this.error({message:e.message}),this.state="READY",this.pause(),this.trigger("error")}if(this.updateTimeMapping_(t,this.syncController_.timelines[t.timeline],this.playlist_),t.isSyncRequest)return this.trigger("syncinfoupdate"),this.pendingSegment_=null,void(this.state="READY");t.byteLength=t.bytes.byteLength,this.mediaSecondsLoaded+=n.duration,t.cues.length&&this.remove(t.cues[0].endTime,t.cues[t.cues.length-1].endTime),t.cues.forEach(function(t){e.subtitlesTrack_.addCue(t)}),this.handleUpdateEnd_()}},{key:"parseVTTCues_",value:function(e){var t=void 0,n=!1;"function"==typeof p.default.TextDecoder?t=new p.default.TextDecoder("utf8"):(t=p.default.WebVTT.StringDecoder(),n=!0);var r=new p.default.WebVTT.Parser(p.default,p.default.vttjs,t);if(e.cues=[],e.timestampmap={MPEGTS:0,LOCAL:0},r.oncue=e.cues.push.bind(e.cues),r.ontimestampmap=function(t){return e.timestampmap=t},r.onparsingerror=function(e){f.default.log.warn("Error encountered when parsing cues: "+e.message)},e.segment.map){var i=e.segment.map.bytes;n&&(i=_(i)),r.parse(i)}var a=e.bytes;n&&(a=_(a)),r.parse(a),r.flush()}},{key:"updateTimeMapping_",value:function(e,t,n){var r=e.segment;if(t){if(!e.cues.length)return void(r.empty=!0);var i=e.timestampmap,a=i.MPEGTS/9e4-i.LOCAL+t.mapping;if(e.cues.forEach(function(e){e.startTime+=a,e.endTime+=a}),!n.syncInfo){var o=e.cues[0].startTime,s=e.cues[e.cues.length-1].startTime;n.syncInfo={mediaSequence:n.mediaSequence+e.mediaIndex,time:Math.min(o,s-r.duration)}}}}}]),t}(c.default);n.default=b,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./bin-utils":2,"./segment-loader":16,"global/window":32,"videojs-contrib-media-sources/es5/remove-cues-from-track.js":72}],21:[function(e,t,n){(function(e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="undefined"!=typeof window?window.videojs:void 0!==e?e.videojs:null,i=function(e){return e&&e.__esModule?e:{default:e}}(r),a=function(){return function e(t,n){t=(0,r.mergeOptions)({timeout:45e3},t);var a=e.beforeRequest||i.default.Hls.xhr.beforeRequest;if(a&&"function"==typeof a){var o=a(t);o&&(t=o)}var s=(0,r.xhr)(t,function(e,t){var r=s.response;!e&&r&&(s.responseTime=Date.now(),s.roundTripTime=s.responseTime-s.requestTime,s.bytesReceived=r.byteLength||r.length,s.bandwidth||(s.bandwidth=Math.floor(s.bytesReceived/s.roundTripTime*8*1e3))),e&&"ETIMEDOUT"===e.code&&(s.timedout=!0),e||s.aborted||200===t.statusCode||206===t.statusCode||0===t.statusCode||(e=new Error("XHR Failed with a response of: "+(s&&(r||s.responseText)))),n(e,s)}),u=s.abort;return s.abort=function(){return s.aborted=!0,u.apply(s,arguments)},s.uri=t.uri,s.requestTime=Date.now(),s}};n.default=a,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],22:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){var e=[[[],[],[],[],[]],[[],[],[],[],[]]],t=e[0],n=e[1],r=t[4],i=n[4],a=void 0,o=void 0,s=void 0,u=[],l=[],c=void 0,d=void 0,f=void 0,h=void 0,p=void 0,m=void 0;for(a=0;a<256;a++)l[(u[a]=a<<1^283*(a>>7))^a]=a;for(o=s=0;!r[o];o^=c||1,s=l[s]||1)for(h=s^s<<1^s<<2^s<<3^s<<4,h=h>>8^255&h^99,r[o]=h,i[h]=o,f=u[d=u[c=u[o]]],m=16843009*f^65537*d^257*c^16843008*o,p=257*u[h]^16843008*h,a=0;a<4;a++)t[a][o]=p=p<<24^p>>>8,n[a][h]=m=m<<24^m>>>8;for(a=0;a<5;a++)t[a]=t[a].slice(0),n[a]=n[a].slice(0);return e},o=null,s=function(){function e(t){r(this,e),o||(o=a()),this._tables=[[o[0][0].slice(),o[0][1].slice(),o[0][2].slice(),o[0][3].slice(),o[0][4].slice()],[o[1][0].slice(),o[1][1].slice(),o[1][2].slice(),o[1][3].slice(),o[1][4].slice()]];var n=void 0,i=void 0,s=void 0,u=void 0,l=void 0,c=this._tables[0][4],d=this._tables[1],f=t.length,h=1;if(4!==f&&6!==f&&8!==f)throw new Error("Invalid aes key size");for(u=t.slice(0),l=[],this._key=[u,l],n=f;n<4*f+28;n++)s=u[n-1],(n%f==0||8===f&&n%f==4)&&(s=c[s>>>24]<<24^c[s>>16&255]<<16^c[s>>8&255]<<8^c[255&s],n%f==0&&(s=s<<8^s>>>24^h<<24,h=h<<1^283*(h>>7))),u[n]=u[n-f]^s;for(i=0;n;i++,n--)s=u[3&i?n:n-4],l[i]=n<=4||i<4?s:d[0][c[s>>>24]]^d[1][c[s>>16&255]]^d[2][c[s>>8&255]]^d[3][c[255&s]]}return i(e,[{key:"decrypt",value:function(e,t,n,r,i,a){var o=this._key[1],s=e^o[0],u=r^o[1],l=n^o[2],c=t^o[3],d=void 0,f=void 0,h=void 0,p=o.length/4-2,m=void 0,v=4,g=this._tables[1],y=g[0],_=g[1],b=g[2],T=g[3],S=g[4];for(m=0;m<p;m++)d=y[s>>>24]^_[u>>16&255]^b[l>>8&255]^T[255&c]^o[v],f=y[u>>>24]^_[l>>16&255]^b[c>>8&255]^T[255&s]^o[v+1],h=y[l>>>24]^_[c>>16&255]^b[s>>8&255]^T[255&u]^o[v+2],c=y[c>>>24]^_[s>>16&255]^b[u>>8&255]^T[255&l]^o[v+3],v+=4,s=d,u=f,l=h;for(m=0;m<4;m++)i[(3&-m)+a]=S[s>>>24]<<24^S[u>>16&255]<<16^S[l>>8&255]<<8^S[255&c]^o[v++],d=s,s=u,u=l,l=c,c=d}}]),e}();n.default=s,t.exports=n.default},{}],23:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},s=e("./stream"),u=function(e){return e&&e.__esModule?e:{default:e}}(s),l=function(e){function t(){r(this,t),o(Object.getPrototypeOf(t.prototype),"constructor",this).call(this,u.default),this.jobs=[],this.delay=1,this.timeout_=null}return i(t,e),a(t,[{key:"processJob_",value:function(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null}},{key:"push",value:function(e){this.jobs.push(e),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))}}]),t}(u.default);n.default=l,t.exports=n.default},{"./stream":26}],24:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("./aes"),s=r(o),u=e("./async-stream"),l=r(u),c=e("pkcs7"),d=function(e){return e<<24|(65280&e)<<8|(16711680&e)>>8|e>>>24},f=function(e,t,n){var r=new Int32Array(e.buffer,e.byteOffset,e.byteLength>>2),i=new s.default(Array.prototype.slice.call(t)),a=new Uint8Array(e.byteLength),o=new Int32Array(a.buffer),u=void 0,l=void 0,c=void 0,f=void 0,h=void 0,p=void 0,m=void 0,v=void 0,g=void 0;for(u=n[0],l=n[1],c=n[2],f=n[3],g=0;g<r.length;g+=4)h=d(r[g]),p=d(r[g+1]),m=d(r[g+2]),v=d(r[g+3]),i.decrypt(h,p,m,v,o,g),o[g]=d(o[g]^u),o[g+1]=d(o[g+1]^l),o[g+2]=d(o[g+2]^c),o[g+3]=d(o[g+3]^f),u=h,l=p,c=m,f=v;return a};n.decrypt=f;var h=function(){function e(t,n,r,a){i(this,e);var o=e.STEP,s=new Int32Array(t.buffer),u=new Uint8Array(t.byteLength),f=0;for(this.asyncStream_=new l.default,this.asyncStream_.push(this.decryptChunk_(s.subarray(f,f+o),n,r,u)),f=o;f<s.length;f+=o)r=new Uint32Array([d(s[f-4]),d(s[f-3]),d(s[f-2]),d(s[f-1])]),this.asyncStream_.push(this.decryptChunk_(s.subarray(f,f+o),n,r,u));this.asyncStream_.push(function(){a(null,(0,c.unpad)(u))})}return a(e,[{key:"decryptChunk_",value:function(e,t,n,r){return function(){var i=f(e,t,n);r.set(i,e.byteOffset)}}}],[{key:"STEP",get:function(){return 32e3}}]),e}();n.Decrypter=h,n.default={Decrypter:h,decrypt:f}},{"./aes":22,"./async-stream":23,pkcs7:28}],25:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e("./decrypter"),i=e("./async-stream"),a=function(e){return e&&e.__esModule?e:{default:e}}(i);n.default={decrypt:r.decrypt,Decrypter:r.Decrypter,AsyncStream:a.default},t.exports=n.default},{"./async-stream":23,"./decrypter":24}],26:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this.listeners={}}return i(e,[{key:"on",value:function(e,t){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push(t)}},{key:"off",value:function(e,t){var n=void 0;return!!this.listeners[e]&&(n=this.listeners[e].indexOf(t),this.listeners[e].splice(n,1),n>-1)}},{key:"trigger",value:function(e){var t=void 0,n=void 0,r=void 0,i=void 0;if(t=this.listeners[e])if(2===arguments.length)for(r=t.length,n=0;n<r;++n)t[n].call(this,arguments[1]);else for(i=Array.prototype.slice.call(arguments,1),r=t.length,n=0;n<r;++n)t[n].apply(this,i)}},{key:"dispose",value:function(){this.listeners={}}},{key:"pipe",value:function(e){this.on("data",function(t){e.push(t)})}}]),e}();n.default=a,t.exports=n.default},{}],27:[function(e,t,n){"use strict";var r;t.exports=function(e){var t=r[e.byteLength%16||0],n=new Uint8Array(e.byteLength+t.length);return n.set(e),n.set(t,e.byteLength),n},r=[[16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16],[15,15,15,15,15,15,15,15,15,15,15,15,15,15,15],[14,14,14,14,14,14,14,14,14,14,14,14,14,14],[13,13,13,13,13,13,13,13,13,13,13,13,13],[12,12,12,12,12,12,12,12,12,12,12,12],[11,11,11,11,11,11,11,11,11,11,11],[10,10,10,10,10,10,10,10,10,10],[9,9,9,9,9,9,9,9,9],[8,8,8,8,8,8,8,8],[7,7,7,7,7,7,7],[6,6,6,6,6,6],[5,5,5,5,5],[4,4,4,4],[3,3,3],[2,2],[1]]},{}],28:[function(e,t,n){"use strict";n.pad=e("./pad.js"),n.unpad=e("./unpad.js")},{"./pad.js":27,"./unpad.js":29}],29:[function(e,t,n){"use strict";t.exports=function(e){return e.subarray(0,e.byteLength-e[e.byteLength-1])}},{}],30:[function(e,t,n){},{}],31:[function(e,t,n){(function(n){var r,i=void 0!==n?n:"undefined"!=typeof window?window:{},a=e("min-document");"undefined"!=typeof document?r=document:(r=i["__GLOBAL_DOCUMENT_CACHE@4"])||(r=i["__GLOBAL_DOCUMENT_CACHE@4"]=a),t.exports=r}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"min-document":30}],32:[function(e,t,n){(function(e){var n;n="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},t.exports=n}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],33:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}var i=e("./line-stream"),a=r(i),o=e("./parse-stream"),s=r(o),u=e("./parser"),l=r(u);t.exports={LineStream:a.default,ParseStream:s.default,Parser:l.default}},{"./line-stream":34,"./parse-stream":35,"./parser":36}],34:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=e("./stream"),u=function(e){return e&&e.__esModule?e:{default:e}}(s),l=function(e){function t(){r(this,t);var e=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return e.buffer="",e}return a(t,e),o(t,[{key:"push",value:function(e){var t=void 0;for(this.buffer+=e,t=this.buffer.indexOf("\n");t>-1;t=this.buffer.indexOf("\n"))this.trigger("data",this.buffer.substring(0,t)),this.buffer=this.buffer.substring(t+1)}}]),t}(u.default);n.default=l},{"./stream":37}],35:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){var n=[],r=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(r=(o=s.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){i=!0,a=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw a}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=e("./stream"),l=function(e){return e&&e.__esModule?e:{default:e}}(u),c=function(){return new RegExp('(?:^|,)((?:[^=]*)=(?:"[^"]*"|[^,]*))')},d=function(e){for(var t=e.split(c()),n={},r=t.length,i=void 0;r--;)""!==t[r]&&(i=/([^=]*)=(.*)/.exec(t[r]).slice(1),i[0]=i[0].replace(/^\s+|\s+$/g,""),i[1]=i[1].replace(/^\s+|\s+$/g,""),i[1]=i[1].replace(/^['"](.*)['"]$/g,"$1"),n[i[0]]=i[1]);return n},f=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this))}return a(t,e),s(t,[{key:"push",value:function(e){var t=void 0,n=void 0;if(e=e.replace(/^[\u0000\s]+|[\u0000\s]+$/g,""),0!==e.length){if("#"!==e[0])return void this.trigger("data",{type:"uri",uri:e});if(0!==e.indexOf("#EXT"))return void this.trigger("data",{type:"comment",text:e.slice(1)});if(e=e.replace("\r",""),t=/^#EXTM3U/.exec(e))return void this.trigger("data",{type:"tag",tagType:"m3u"});if(t=/^#EXTINF:?([0-9\.]*)?,?(.*)?$/.exec(e))return n={type:"tag",tagType:"inf"},t[1]&&(n.duration=parseFloat(t[1])),t[2]&&(n.title=t[2]),void this.trigger("data",n);if(t=/^#EXT-X-TARGETDURATION:?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"targetduration"},t[1]&&(n.duration=parseInt(t[1],10)),void this.trigger("data",n);if(t=/^#ZEN-TOTAL-DURATION:?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"totalduration"},t[1]&&(n.duration=parseInt(t[1],10)),void this.trigger("data",n);if(t=/^#EXT-X-VERSION:?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"version"},t[1]&&(n.version=parseInt(t[1],10)),void this.trigger("data",n);if(t=/^#EXT-X-MEDIA-SEQUENCE:?(\-?[0-9.]*)?/.exec(e))return n={type:"tag",tagType:"media-sequence"},t[1]&&(n.number=parseInt(t[1],10)),void this.trigger("data",n);if(t=/^#EXT-X-DISCONTINUITY-SEQUENCE:?(\-?[0-9.]*)?/.exec(e))return n={type:"tag",tagType:"discontinuity-sequence"},t[1]&&(n.number=parseInt(t[1],10)),void this.trigger("data",n);if(t=/^#EXT-X-PLAYLIST-TYPE:?(.*)?$/.exec(e))return n={type:"tag",tagType:"playlist-type"},t[1]&&(n.playlistType=t[1]),void this.trigger("data",n);if(t=/^#EXT-X-BYTERANGE:?([0-9.]*)?@?([0-9.]*)?/.exec(e))return n={type:"tag",tagType:"byterange"},t[1]&&(n.length=parseInt(t[1],10)),t[2]&&(n.offset=parseInt(t[2],10)),void this.trigger("data",n);if(t=/^#EXT-X-ALLOW-CACHE:?(YES|NO)?/.exec(e))return n={type:"tag",tagType:"allow-cache"},t[1]&&(n.allowed=!/NO/.test(t[1])),void this.trigger("data",n);if(t=/^#EXT-X-MAP:?(.*)$/.exec(e)){if(n={type:"tag",tagType:"map"},t[1]){var r=d(t[1]);if(r.URI&&(n.uri=r.URI),r.BYTERANGE){var i=r.BYTERANGE.split("@"),a=o(i,2),s=a[0],u=a[1];n.byterange={},s&&(n.byterange.length=parseInt(s,10)),u&&(n.byterange.offset=parseInt(u,10))}}return void this.trigger("data",n)}if(t=/^#EXT-X-STREAM-INF:?(.*)$/.exec(e)){if(n={type:"tag",tagType:"stream-inf"},t[1]){if(n.attributes=d(t[1]),n.attributes.RESOLUTION){var l=n.attributes.RESOLUTION.split("x"),c={};l[0]&&(c.width=parseInt(l[0],10)),l[1]&&(c.height=parseInt(l[1],10)),n.attributes.RESOLUTION=c}n.attributes.BANDWIDTH&&(n.attributes.BANDWIDTH=parseInt(n.attributes.BANDWIDTH,10)),n.attributes["PROGRAM-ID"]&&(n.attributes["PROGRAM-ID"]=parseInt(n.attributes["PROGRAM-ID"],10))}return void this.trigger("data",n)}if(t=/^#EXT-X-MEDIA:?(.*)$/.exec(e))return n={type:"tag",tagType:"media"},t[1]&&(n.attributes=d(t[1])),void this.trigger("data",n);if(t=/^#EXT-X-ENDLIST/.exec(e))return void this.trigger("data",{type:"tag",tagType:"endlist"});if(t=/^#EXT-X-DISCONTINUITY/.exec(e))return void this.trigger("data",{type:"tag",tagType:"discontinuity"});if(t=/^#EXT-X-PROGRAM-DATE-TIME:?(.*)$/.exec(e))return n={type:"tag",tagType:"program-date-time"},t[1]&&(n.dateTimeString=t[1],n.dateTimeObject=new Date(t[1])),void this.trigger("data",n);if(t=/^#EXT-X-KEY:?(.*)$/.exec(e))return n={type:"tag",tagType:"key"},t[1]&&(n.attributes=d(t[1]),n.attributes.IV&&("0x"===n.attributes.IV.substring(0,2).toLowerCase()&&(n.attributes.IV=n.attributes.IV.substring(2)),n.attributes.IV=n.attributes.IV.match(/.{8}/g),n.attributes.IV[0]=parseInt(n.attributes.IV[0],16),n.attributes.IV[1]=parseInt(n.attributes.IV[1],16),n.attributes.IV[2]=parseInt(n.attributes.IV[2],16),n.attributes.IV[3]=parseInt(n.attributes.IV[3],16),n.attributes.IV=new Uint32Array(n.attributes.IV))),void this.trigger("data",n);if(t=/^#EXT-X-CUE-OUT-CONT:?(.*)?$/.exec(e))return n={type:"tag",tagType:"cue-out-cont"},t[1]?n.data=t[1]:n.data="",void this.trigger("data",n);if(t=/^#EXT-X-CUE-OUT:?(.*)?$/.exec(e))return n={type:"tag",tagType:"cue-out"},t[1]?n.data=t[1]:n.data="",void this.trigger("data",n);if(t=/^#EXT-X-CUE-IN:?(.*)?$/.exec(e))return n={type:"tag",tagType:"cue-in"},t[1]?n.data=t[1]:n.data="",void this.trigger("data",n);this.trigger("data",{type:"tag",data:e.slice(4)})}}}]),t}(l.default);n.default=f},{"./stream":37}],36:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=e("./stream"),c=r(l),d=e("./line-stream"),f=r(d),h=e("./parse-stream"),p=r(h),m=function(e){function t(){i(this,t);var e=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));e.lineStream=new f.default,e.parseStream=new p.default,e.lineStream.pipe(e.parseStream);var n=e,r=[],o={},u=void 0,l=void 0,c=function(){},d={AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},h=0;return e.manifest={allowCache:!0,discontinuityStarts:[],segments:[]},e.parseStream.on("data",function(e){var t=void 0,i=void 0;({tag:function(){(({"allow-cache":function(){this.manifest.allowCache=e.allowed,"allowed"in e||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange:function(){var t={};"length"in e&&(o.byterange=t,t.length=e.length,"offset"in e||(this.trigger("info",{message:"defaulting offset to zero"}),e.offset=0)),"offset"in e&&(o.byterange=t,t.offset=e.offset)},endlist:function(){this.manifest.endList=!0},inf:function(){"mediaSequence"in this.manifest||(this.manifest.mediaSequence=0,this.trigger("info",{message:"defaulting media sequence to zero"})),"discontinuitySequence"in this.manifest||(this.manifest.discontinuitySequence=0,this.trigger("info",{message:"defaulting discontinuity sequence to zero"})),e.duration>0&&(o.duration=e.duration),0===e.duration&&(o.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=r},key:function(){return e.attributes?"NONE"===e.attributes.METHOD?void(l=null):e.attributes.URI?(e.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),l={method:e.attributes.METHOD||"AES-128",uri:e.attributes.URI},void(void 0!==e.attributes.IV&&(l.iv=e.attributes.IV))):void this.trigger("warn",{message:"ignoring key declaration without URI"}):void this.trigger("warn",{message:"ignoring key declaration without attribute list"})},"media-sequence":function(){if(!isFinite(e.number))return void this.trigger("warn",{message:"ignoring invalid media sequence: "+e.number});this.manifest.mediaSequence=e.number},"discontinuity-sequence":function(){if(!isFinite(e.number))return void this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+e.number});this.manifest.discontinuitySequence=e.number,h=e.number},"playlist-type":function(){if(!/VOD|EVENT/.test(e.playlistType))return void this.trigger("warn",{message:"ignoring unknown playlist type: "+e.playlist});this.manifest.playlistType=e.playlistType},map:function(){u={},e.uri&&(u.uri=e.uri),e.byterange&&(u.byterange=e.byterange)},"stream-inf":function(){if(this.manifest.playlists=r,this.manifest.mediaGroups=this.manifest.mediaGroups||d,!e.attributes)return void this.trigger("warn",{message:"ignoring empty stream-inf attributes"});o.attributes||(o.attributes={}),s(o.attributes,e.attributes)},media:function(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||d,!(e.attributes&&e.attributes.TYPE&&e.attributes["GROUP-ID"]&&e.attributes.NAME))return void this.trigger("warn",{message:"ignoring incomplete or missing media group"});var n=this.manifest.mediaGroups[e.attributes.TYPE];n[e.attributes["GROUP-ID"]]=n[e.attributes["GROUP-ID"]]||{},t=n[e.attributes["GROUP-ID"]],i={default:/yes/i.test(e.attributes.DEFAULT)},i.default?i.autoselect=!0:i.autoselect=/yes/i.test(e.attributes.AUTOSELECT),e.attributes.LANGUAGE&&(i.language=e.attributes.LANGUAGE),e.attributes.URI&&(i.uri=e.attributes.URI),e.attributes["INSTREAM-ID"]&&(i.instreamId=e.attributes["INSTREAM-ID"]),e.attributes.CHARACTERISTICS&&(i.characteristics=e.attributes.CHARACTERISTICS),e.attributes.FORCED&&(i.forced=/yes/i.test(e.attributes.FORCED)),t[e.attributes.NAME]=i},discontinuity:function(){h+=1,o.discontinuity=!0,this.manifest.discontinuityStarts.push(r.length)},"program-date-time":function(){this.manifest.dateTimeString=e.dateTimeString,this.manifest.dateTimeObject=e.dateTimeObject},targetduration:function(){if(!isFinite(e.duration)||e.duration<0)return void this.trigger("warn",{message:"ignoring invalid target duration: "+e.duration});this.manifest.targetDuration=e.duration},totalduration:function(){if(!isFinite(e.duration)||e.duration<0)return void this.trigger("warn",{message:"ignoring invalid total duration: "+e.duration});this.manifest.totalDuration=e.duration},"cue-out":function(){o.cueOut=e.data},"cue-out-cont":function(){o.cueOutCont=e.data},"cue-in":function(){o.cueIn=e.data}})[e.tagType]||c).call(n)},uri:function(){o.uri=e.uri,r.push(o),!this.manifest.targetDuration||"duration"in o||(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),o.duration=this.manifest.targetDuration),l&&(o.key=l),o.timeline=h,u&&(o.map=u),o={}},comment:function(){}})[e.type].call(n)}),e}return o(t,e),u(t,[{key:"push",value:function(e){this.lineStream.push(e)}},{key:"end",value:function(){this.lineStream.push("\n")}}]),t}(c.default);n.default=m},{"./line-stream":34,"./parse-stream":35,"./stream":37}],37:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this.listeners={}}return i(e,[{key:"on",value:function(e,t){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push(t)}},{key:"off",value:function(e,t){if(!this.listeners[e])return!1;var n=this.listeners[e].indexOf(t);return this.listeners[e].splice(n,1),n>-1}},{key:"trigger",value:function(e){var t=this.listeners[e],n=void 0,r=void 0,i=void 0;if(t)if(2===arguments.length)for(r=t.length,n=0;n<r;++n)t[n].call(this,arguments[1]);else for(i=Array.prototype.slice.call(arguments,1),r=t.length,n=0;n<r;++n)t[n].apply(this,i)}},{key:"dispose",value:function(){this.listeners={}}},{key:"pipe",value:function(e){this.on("data",function(t){e.push(t)})}}]),e}();n.default=a},{}],38:[function(e,t,n){"use strict";var r,i=e("../utils/stream.js");r=function(){var e=new Uint8Array,t=0;r.prototype.init.call(this),this.setTimestamp=function(e){t=e},this.parseId3TagSize=function(e,t){var n=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9];return(16&e[t+5])>>4?n+20:n+10},this.parseAdtsSize=function(e,t){var n=(224&e[t+5])>>5,r=e[t+4]<<3;return 6144&e[t+3]|r|n},this.push=function(n){var r,i,a,o,s=0,u=0;for(e.length?(o=e.length,e=new Uint8Array(n.byteLength+o),e.set(e.subarray(0,o)),e.set(n,o)):e=n;e.length-u>=3;)if(e[u]!=="I".charCodeAt(0)||e[u+1]!=="D".charCodeAt(0)||e[u+2]!=="3".charCodeAt(0))if(!0&e[u]&&240==(240&e[u+1])){if(e.length-u<7)break;if((s=this.parseAdtsSize(e,u))>e.length)break;a={type:"audio",data:e.subarray(u,u+s),pts:t,dts:t},this.trigger("data",a),u+=s}else u++;else{if(e.length-u<10)break;if((s=this.parseId3TagSize(e,u))>e.length)break;i={type:"timed-metadata",data:e.subarray(u,u+s)},this.trigger("data",i),u+=s}r=e.length-u,e=r>0?e.subarray(u):new Uint8Array}},r.prototype=new i,t.exports=r},{"../utils/stream.js":62}],39:[function(e,t,n){"use strict";var r=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],i=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},a=function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i},o=function(e,t,n){return unescape(a(e,t,n))},s=function(e,t){var n=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9];return(16&e[t+5])>>4?n+20:n+10},u=function(e,t){var n=(224&e[t+5])>>5,r=e[t+4]<<3;return 6144&e[t+3]|r|n},l=function(e,t){return e[t]==="I".charCodeAt(0)&&e[t+1]==="D".charCodeAt(0)&&e[t+2]==="3".charCodeAt(0)?"timed-metadata":!0&e[t]&&240==(240&e[t+1])?"audio":null},c=function(e){for(var t=0;t+5<e.length;){if(255===e[t]&&240==(246&e[t+1]))return r[(60&e[t+2])>>>2];t++}return null},d=function(e){var t,n,r;t=10,64&e[5]&&(t+=4,t+=i(e.subarray(10,14)));do{if((n=i(e.subarray(t+4,t+8)))<1)return null;if("PRIV"===String.fromCharCode(e[t],e[t+1],e[t+2],e[t+3])){r=e.subarray(t+10,t+n+10);for(var a=0;a<r.byteLength;a++)if(0===r[a]){var s=o(r,0,a);if("com.apple.streaming.transportStreamTimestamp"===s){var u=r.subarray(a+1),l=(1&u[3])<<30|u[4]<<22|u[5]<<14|u[6]<<6|u[7]>>>2;return l*=4,l+=3&u[7]}break}}t+=10,t+=n}while(t<e.byteLength);return null};t.exports={parseId3TagSize:s,parseAdtsSize:u,parseType:l,parseSampleRate:c,parseAacTimestamp:d}},{}],40:[function(e,t,n){"use strict";var r,i=e("../utils/stream.js"),a=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];r=function(){var e;r.prototype.init.call(this),this.push=function(t){var n,r,i,o,s,u,l=0,c=0;if("audio"===t.type)for(e?(o=e,e=new Uint8Array(o.byteLength+t.data.byteLength),e.set(o),e.set(t.data,o.byteLength)):e=t.data;l+5<e.length;)if(255===e[l]&&240==(246&e[l+1])){if(r=2*(1&~e[l+1]),n=(3&e[l+3])<<11|e[l+4]<<3|(224&e[l+5])>>5,s=1024*(1+(3&e[l+6])),u=9e4*s/a[(60&e[l+2])>>>2],i=l+n,e.byteLength<i)return;if(this.trigger("data",{pts:t.pts+c*u,dts:t.dts+c*u,sampleCount:s,audioobjecttype:1+(e[l+2]>>>6&3),channelcount:(1&e[l+2])<<2|(192&e[l+3])>>>6,samplerate:a[(60&e[l+2])>>>2],samplingfrequencyindex:(60&e[l+2])>>>2,samplesize:16,data:e.subarray(l+7+r,i)}),e.byteLength===i)return void(e=void 0);c++,e=e.subarray(i)}else l++},this.flush=function(){this.trigger("done")}},r.prototype=new i,t.exports=r},{"../utils/stream.js":62}],41:[function(e,t,n){"use strict";var r,i,a,o=e("../utils/stream.js"),s=e("../utils/exp-golomb.js");i=function(){var e,t,n=0;i.prototype.init.call(this),this.push=function(r){var i;for(t?(i=new Uint8Array(t.byteLength+r.data.byteLength),i.set(t),i.set(r.data,t.byteLength),t=i):t=r.data;n<t.byteLength-3;n++)if(1===t[n+2]){e=n+5;break}for(;e<t.byteLength;)switch(t[e]){case 0:if(0!==t[e-1]){e+=2;break}if(0!==t[e-2]){e++;break}n+3!==e-2&&this.trigger("data",t.subarray(n+3,e-2));do{e++}while(1!==t[e]&&e<t.length);n=e-2,e+=3;break;case 1:if(0!==t[e-1]||0!==t[e-2]){e+=3;break}this.trigger("data",t.subarray(n+3,e-2)),n=e-2,e+=3;break;default:e+=3}t=t.subarray(n),e-=n,n=0},this.flush=function(){t&&t.byteLength>3&&this.trigger("data",t.subarray(n+3)),t=null,n=0,this.trigger("done")}},i.prototype=new o,a={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},r=function(){var e,t,n,o,u,l,c,d=new i;r.prototype.init.call(this),e=this,this.push=function(e){"video"===e.type&&(t=e.trackId,n=e.pts,o=e.dts,d.push(e))},d.on("data",function(r){var i={trackId:t,pts:n,dts:o,data:r};switch(31&r[0]){case 5:i.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:i.nalUnitType="sei_rbsp",i.escapedRBSP=u(r.subarray(1));break;case 7:i.nalUnitType="seq_parameter_set_rbsp",i.escapedRBSP=u(r.subarray(1)),i.config=l(i.escapedRBSP);break;case 8:i.nalUnitType="pic_parameter_set_rbsp";break;case 9:i.nalUnitType="access_unit_delimiter_rbsp"}e.trigger("data",i)}),d.on("done",function(){e.trigger("done")}),this.flush=function(){d.flush()},c=function(e,t){var n,r,i=8,a=8;for(n=0;n<e;n++)0!==a&&(r=t.readExpGolomb(),a=(i+r+256)%256),i=0===a?i:a},u=function(e){for(var t,n,r=e.byteLength,i=[],a=1;a<r-2;)0===e[a]&&0===e[a+1]&&3===e[a+2]?(i.push(a+2),a+=2):a++;if(0===i.length)return e;t=r-i.length,n=new Uint8Array(t);var o=0;for(a=0;a<t;o++,a++)o===i[0]&&(o++,i.shift()),n[a]=e[o];return n},l=function(e){var t,n,r,i,o,u,l,d,f,h,p,m,v,g=0,y=0,_=0,b=0,T=1;if(t=new s(e),n=t.readUnsignedByte(),i=t.readUnsignedByte(),r=t.readUnsignedByte(),t.skipUnsignedExpGolomb(),a[n]&&(o=t.readUnsignedExpGolomb(),3===o&&t.skipBits(1),t.skipUnsignedExpGolomb(),t.skipUnsignedExpGolomb(),t.skipBits(1),t.readBoolean()))for(p=3!==o?8:12,v=0;v<p;v++)t.readBoolean()&&(v<6?c(16,t):c(64,t));if(t.skipUnsignedExpGolomb(),0===(u=t.readUnsignedExpGolomb()))t.readUnsignedExpGolomb();else if(1===u)for(t.skipBits(1),t.skipExpGolomb(),t.skipExpGolomb(),l=t.readUnsignedExpGolomb(),v=0;v<l;v++)t.skipExpGolomb();if(t.skipUnsignedExpGolomb(),t.skipBits(1),d=t.readUnsignedExpGolomb(),f=t.readUnsignedExpGolomb(),h=t.readBits(1),0===h&&t.skipBits(1),t.skipBits(1),t.readBoolean()&&(g=t.readUnsignedExpGolomb(),y=t.readUnsignedExpGolomb(),_=t.readUnsignedExpGolomb(),b=t.readUnsignedExpGolomb()),t.readBoolean()&&t.readBoolean()){switch(t.readUnsignedByte()){case 1:m=[1,1];break;case 2:m=[12,11];break;case 3:m=[10,11];break;case 4:m=[16,11];break;case 5:m=[40,33];break;case 6:m=[24,11];break;case 7:m=[20,11];break;case 8:m=[32,11];break;case 9:m=[80,33];break;case 10:m=[18,11];break;case 11:m=[15,11];break;case 12:m=[64,33];break;case 13:m=[160,99];break;case 14:m=[4,3];break;case 15:m=[3,2];break;case 16:m=[2,1];break;case 255:m=[t.readUnsignedByte()<<8|t.readUnsignedByte(),t.readUnsignedByte()<<8|t.readUnsignedByte()]}m&&(T=m[0]/m[1])}return{profileIdc:n,levelIdc:r,profileCompatibility:i,width:Math.ceil((16*(d+1)-2*g-2*y)*T),height:(2-h)*(f+1)*16-2*_-2*b}}},r.prototype=new o,t.exports={H264Stream:r,NalByteStream:i}},{"../utils/exp-golomb.js":61,"../utils/stream.js":62}],42:[function(e,t,n){var r=[33,16,5,32,164,27],i=[33,65,108,84,1,2,4,8,168,2,4,8,17,191,252],a=function(e){for(var t=[];e--;)t.push(0);return t},o={96e3:[r,[227,64],a(154),[56]],88200:[r,[231],a(170),[56]],64e3:[r,[248,192],a(240),[56]],48e3:[r,[255,192],a(268),[55,148,128],a(54),[112]],44100:[r,[255,192],a(268),[55,163,128],a(84),[112]],32e3:[r,[255,192],a(268),[55,234],a(226),[112]],24e3:[r,[255,192],a(268),[55,255,128],a(268),[111,112],a(126),[224]],16e3:[r,[255,192],a(268),[55,255,128],a(268),[111,255],a(269),[223,108],a(195),[1,192]],12e3:[i,a(268),[3,127,248],a(268),[6,255,240],a(268),[13,255,224],a(268),[27,253,128],a(259),[56]],11025:[i,a(268),[3,127,248],a(268),[6,255,240],a(268),[13,255,224],a(268),[27,255,192],a(268),[55,175,128],a(108),[112]],8e3:[i,a(268),[3,121,16],a(47),[7]]};t.exports=function(e){return Object.keys(e).reduce(function(t,n){return t[n]=new Uint8Array(e[n].reduce(function(e,t){return e.concat(t)},[])),t},{})}(o)},{}],43:[function(e,t,n){"use strict";var r=e("../utils/stream.js"),i=function(e){this.numberOfTracks=0,this.metadataStream=e.metadataStream,this.videoTags=[],this.audioTags=[],this.videoTrack=null,this.audioTrack=null,this.pendingCaptions=[],this.pendingMetadata=[],this.pendingTracks=0,this.processedTracks=0,i.prototype.init.call(this),this.push=function(e){return e.text?this.pendingCaptions.push(e):e.frames?this.pendingMetadata.push(e):("video"===e.track.type&&(this.videoTrack=e.track,this.videoTags=e.tags,this.pendingTracks++),void("audio"===e.track.type&&(this.audioTrack=e.track,this.audioTags=e.tags,this.pendingTracks++)))}};i.prototype=new r,i.prototype.flush=function(e){var t,n,r,i,a={tags:{},captions:[],captionStreams:{},metadata:[]};if(this.pendingTracks<this.numberOfTracks){if("VideoSegmentStream"!==e&&"AudioSegmentStream"!==e)return;if(0===this.pendingTracks&&++this.processedTracks<this.numberOfTracks)return}if(this.processedTracks+=this.pendingTracks,this.pendingTracks=0,!(this.processedTracks<this.numberOfTracks)){for(this.videoTrack?i=this.videoTrack.timelineStartInfo.pts:this.audioTrack&&(i=this.audioTrack.timelineStartInfo.pts),a.tags.videoTags=this.videoTags,a.tags.audioTags=this.audioTags,r=0;r<this.pendingCaptions.length;r++)n=this.pendingCaptions[r],n.startTime=n.startPts-i,n.startTime/=9e4,n.endTime=n.endPts-i,n.endTime/=9e4,a.captionStreams[n.stream]=!0,a.captions.push(n);for(r=0;r<this.pendingMetadata.length;r++)t=this.pendingMetadata[r],t.cueTime=t.pts-i,t.cueTime/=9e4,a.metadata.push(t);a.metadata.dispatchType=this.metadataStream.dispatchType,this.videoTrack=null,this.audioTrack=null,this.videoTags=[],this.audioTags=[],this.pendingCaptions.length=0,this.pendingMetadata.length=0,this.pendingTracks=0,this.processedTracks=0,this.trigger("data",a),this.trigger("done")}},t.exports=i},{"../utils/stream.js":62}],44:[function(e,t,n){"use strict";var r=e("./flv-tag.js"),i=function(e,t,n){var i,a,o,s=new Uint8Array(9),u=new DataView(s.buffer);return e=e||0,t=void 0===t||t,n=void 0===n||n,u.setUint8(0,70),u.setUint8(1,76),u.setUint8(2,86),u.setUint8(3,1),u.setUint8(4,(t?4:0)|(n?1:0)),u.setUint32(5,s.byteLength),e<=0?(a=new Uint8Array(s.byteLength+4),a.set(s),a.set([0,0,0,0],s.byteLength),a):(i=new r(r.METADATA_TAG),i.pts=i.dts=0,i.writeMetaDataDouble("duration",e),o=i.finalize().length,a=new Uint8Array(s.byteLength+o),a.set(s),a.set(u.byteLength,o),a)};t.exports=i},{"./flv-tag.js":45}],45:[function(e,t,n){"use strict";var r;r=function(e,t){var n,i=0,a=16384,o=function(e,t){var n,r=e.position+t;r<e.bytes.byteLength||(n=new Uint8Array(2*r),n.set(e.bytes.subarray(0,e.position),0),e.bytes=n,e.view=new DataView(e.bytes.buffer))},s=r.widthBytes||new Uint8Array("width".length),u=r.heightBytes||new Uint8Array("height".length),l=r.videocodecidBytes||new Uint8Array("videocodecid".length);if(!r.widthBytes){for(n=0;n<"width".length;n++)s[n]="width".charCodeAt(n);for(n=0;n<"height".length;n++)u[n]="height".charCodeAt(n);for(n=0;n<"videocodecid".length;n++)l[n]="videocodecid".charCodeAt(n);r.widthBytes=s,r.heightBytes=u,r.videocodecidBytes=l}switch(this.keyFrame=!1,e){case r.VIDEO_TAG:this.length=16,a*=6;break;case r.AUDIO_TAG:this.length=13,this.keyFrame=!0;break;case r.METADATA_TAG:this.length=29,this.keyFrame=!0;break;default:throw new Error("Unknown FLV tag type")}this.bytes=new Uint8Array(a),this.view=new DataView(this.bytes.buffer),this.bytes[0]=e,this.position=this.length,this.keyFrame=t,this.pts=0,this.dts=0,this.writeBytes=function(e,t,n){var r,i=t||0;n=n||e.byteLength,r=i+n,o(this,n),this.bytes.set(e.subarray(i,r),this.position),this.position+=n,this.length=Math.max(this.length,this.position)},this.writeByte=function(e){o(this,1),this.bytes[this.position]=e,this.position++,this.length=Math.max(this.length,this.position)},this.writeShort=function(e){o(this,2),this.view.setUint16(this.position,e),this.position+=2,this.length=Math.max(this.length,this.position)},this.negIndex=function(e){return this.bytes[this.length-e]},this.nalUnitSize=function(){return 0===i?0:this.length-(i+4)},this.startNalUnit=function(){if(i>0)throw new Error("Attempted to create new NAL wihout closing the old one");i=this.length,this.length+=4,this.position=this.length},this.endNalUnit=function(e){var t,n;this.length===i+4?this.length-=4:i>0&&(t=i+4,n=this.length-t,this.position=i,this.view.setUint32(this.position,n),this.position=this.length,e&&e.push(this.bytes.subarray(t,t+n))),i=0},this.writeMetaDataDouble=function(e,t){var n;if(o(this,2+e.length+9),this.view.setUint16(this.position,e.length),this.position+=2,"width"===e)this.bytes.set(s,this.position),this.position+=5;else if("height"===e)this.bytes.set(u,this.position),this.position+=6;else if("videocodecid"===e)this.bytes.set(l,this.position),this.position+=12;else for(n=0;n<e.length;n++)this.bytes[this.position]=e.charCodeAt(n),this.position++;this.position++,this.view.setFloat64(this.position,t),this.position+=8,this.length=Math.max(this.length,this.position),++i},this.writeMetaDataBoolean=function(e,t){var n;for(o(this,2),this.view.setUint16(this.position,e.length),this.position+=2,n=0;n<e.length;n++)o(this,1),this.bytes[this.position]=e.charCodeAt(n),this.position++;o(this,2),this.view.setUint8(this.position,1),this.position++,this.view.setUint8(this.position,t?1:0),this.position++,this.length=Math.max(this.length,this.position),++i},this.finalize=function(){var e,n;switch(this.bytes[0]){case r.VIDEO_TAG:this.bytes[11]=7|(this.keyFrame||t?16:32),this.bytes[12]=t?0:1,e=this.pts-this.dts,this.bytes[13]=(16711680&e)>>>16,this.bytes[14]=(65280&e)>>>8,this.bytes[15]=(255&e)>>>0;break;case r.AUDIO_TAG:this.bytes[11]=175,this.bytes[12]=t?0:1;break;case r.METADATA_TAG:this.position=11,this.view.setUint8(this.position,2),this.position++,this.view.setUint16(this.position,10),this.position+=2,this.bytes.set([111,110,77,101,116,97,68,97,116,97],this.position),this.position+=10,this.bytes[this.position]=8,this.position++,this.view.setUint32(this.position,i),this.position=this.length,this.bytes.set([0,0,9],this.position),this.position+=3,this.length=this.position}return n=this.length-11,this.bytes[1]=(16711680&n)>>>16,this.bytes[2]=(65280&n)>>>8,this.bytes[3]=(255&n)>>>0,this.bytes[4]=(16711680&this.dts)>>>16,this.bytes[5]=(65280&this.dts)>>>8,this.bytes[6]=(255&this.dts)>>>0,this.bytes[7]=(4278190080&this.dts)>>>24,this.bytes[8]=0,this.bytes[9]=0,this.bytes[10]=0,o(this,4),this.view.setUint32(this.length,this.length),this.length+=4,this.position+=4,this.bytes=this.bytes.subarray(0,this.length),this.frameTime=r.frameTime(this.bytes),this}},r.AUDIO_TAG=8,r.VIDEO_TAG=9,r.METADATA_TAG=18,r.isAudioFrame=function(e){return r.AUDIO_TAG===e[0]},r.isVideoFrame=function(e){return r.VIDEO_TAG===e[0]},r.isMetaData=function(e){return r.METADATA_TAG===e[0]},r.isKeyFrame=function(e){return r.isVideoFrame(e)?23===e[11]:!!r.isAudioFrame(e)||!!r.isMetaData(e)},r.frameTime=function(e){var t=e[4]<<16;return t|=e[5]<<8,t|=e[6]<<0,t|=e[7]<<24},t.exports=r},{}],46:[function(e,t,n){t.exports={tag:e("./flv-tag"),Transmuxer:e("./transmuxer"),getFlvHeader:e("./flv-header")}},{"./flv-header":44,"./flv-tag":45,"./transmuxer":48}],47:[function(e,t,n){"use strict";var r=function(){var e=this;this.list=[],this.push=function(e){this.list.push({bytes:e.bytes,dts:e.dts,pts:e.pts,keyFrame:e.keyFrame,metaDataTag:e.metaDataTag})},Object.defineProperty(this,"length",{get:function(){return e.list.length}})};t.exports=r},{}],48:[function(e,t,n){"use strict";var r,i,a,o,s,u,l=e("../utils/stream.js"),c=e("./flv-tag.js"),d=e("../m2ts/m2ts.js"),f=e("../codecs/adts.js"),h=e("../codecs/h264").H264Stream,p=e("./coalesce-stream.js"),m=e("./tag-list.js");o=function(e,t){"number"==typeof t.pts&&(void 0===e.timelineStartInfo.pts?e.timelineStartInfo.pts=t.pts:e.timelineStartInfo.pts=Math.min(e.timelineStartInfo.pts,t.pts)),"number"==typeof t.dts&&(void 0===e.timelineStartInfo.dts?e.timelineStartInfo.dts=t.dts:e.timelineStartInfo.dts=Math.min(e.timelineStartInfo.dts,t.dts))},s=function(e,t){var n=new c(c.METADATA_TAG);return n.dts=t,n.pts=t,n.writeMetaDataDouble("videocodecid",7),n.writeMetaDataDouble("width",e.width),n.writeMetaDataDouble("height",e.height),n},u=function(e,t){var n,r=new c(c.VIDEO_TAG,!0);for(r.dts=t,r.pts=t,r.writeByte(1),r.writeByte(e.profileIdc),r.writeByte(e.profileCompatibility),r.writeByte(e.levelIdc),r.writeByte(255),r.writeByte(225),r.writeShort(e.sps[0].length),r.writeBytes(e.sps[0]),r.writeByte(e.pps.length),n=0;n<e.pps.length;++n)r.writeShort(e.pps[n].length),r.writeBytes(e.pps[n]);return r},a=function(e){var t,n=[],r=[];a.prototype.init.call(this),this.push=function(t){o(e,t),e&&(e.audioobjecttype=t.audioobjecttype,e.channelcount=t.channelcount,e.samplerate=t.samplerate,e.samplingfrequencyindex=t.samplingfrequencyindex,e.samplesize=t.samplesize,e.extraData=e.audioobjecttype<<11|e.samplingfrequencyindex<<7|e.channelcount<<3),t.pts=Math.round(t.pts/90),t.dts=Math.round(t.dts/90),n.push(t)},this.flush=function(){var i,a,o,s=new m;if(0===n.length)return void this.trigger("done","AudioSegmentStream");for(o=-1/0;n.length;)i=n.shift(),r.length&&i.pts>=r[0]&&(o=r.shift(),this.writeMetaDataTags(s,o)),(e.extraData!==t||i.pts-o>=1e3)&&(this.writeMetaDataTags(s,i.pts),t=e.extraData,o=i.pts),a=new c(c.AUDIO_TAG),a.pts=i.pts,a.dts=i.dts,a.writeBytes(i.data),s.push(a.finalize());r.length=0,t=null,this.trigger("data",{track:e,tags:s.list}),this.trigger("done","AudioSegmentStream")},this.writeMetaDataTags=function(t,n){var r;r=new c(c.METADATA_TAG),r.pts=n,r.dts=n,r.writeMetaDataDouble("audiocodecid",10),r.writeMetaDataBoolean("stereo",2===e.channelcount),r.writeMetaDataDouble("audiosamplerate",e.samplerate),r.writeMetaDataDouble("audiosamplesize",16),t.push(r.finalize()),r=new c(c.AUDIO_TAG,!0),r.pts=n,r.dts=n,r.view.setUint16(r.position,e.extraData),r.position+=2,r.length=Math.max(r.length,r.position),t.push(r.finalize())},this.onVideoKeyFrame=function(e){r.push(e)}},a.prototype=new l,i=function(e){var t,n,r=[];i.prototype.init.call(this),this.finishFrame=function(r,i){if(i){if(t&&e&&e.newMetadata&&(i.keyFrame||0===r.length)){var a=s(t,i.dts).finalize(),o=u(e,i.dts).finalize();a.metaDataTag=o.metaDataTag=!0,r.push(a),r.push(o),e.newMetadata=!1,this.trigger("keyframe",i.dts)}i.endNalUnit(),r.push(i.finalize()),n=null}},this.push=function(t){o(e,t),t.pts=Math.round(t.pts/90),t.dts=Math.round(t.dts/90),r.push(t)},this.flush=function(){for(var i,a=new m;r.length&&"access_unit_delimiter_rbsp"!==r[0].nalUnitType;)r.shift();if(0===r.length)return void this.trigger("done","VideoSegmentStream");for(;r.length;)i=r.shift(),"seq_parameter_set_rbsp"===i.nalUnitType?(e.newMetadata=!0,t=i.config,e.width=t.width,e.height=t.height,e.sps=[i.data],e.profileIdc=t.profileIdc,e.levelIdc=t.levelIdc,e.profileCompatibility=t.profileCompatibility,n.endNalUnit()):"pic_parameter_set_rbsp"===i.nalUnitType?(e.newMetadata=!0,e.pps=[i.data],n.endNalUnit()):"access_unit_delimiter_rbsp"===i.nalUnitType?(n&&this.finishFrame(a,n),n=new c(c.VIDEO_TAG),n.pts=i.pts,n.dts=i.dts):("slice_layer_without_partitioning_rbsp_idr"===i.nalUnitType&&(n.keyFrame=!0),n.endNalUnit()),n.startNalUnit(),n.writeBytes(i.data);n&&this.finishFrame(a,n),this.trigger("data",{track:e,tags:a.list}),this.trigger("done","VideoSegmentStream")}},i.prototype=new l,r=function(e){var t,n,o,s,u,l,c,m,v,g,y,_,b=this;r.prototype.init.call(this),e=e||{},this.metadataStream=new d.MetadataStream,e.metadataStream=this.metadataStream,t=new d.TransportPacketStream,n=new d.TransportParseStream,o=new d.ElementaryStream,s=new d.TimestampRolloverStream("video"),u=new d.TimestampRolloverStream("audio"),l=new d.TimestampRolloverStream("timed-metadata"),c=new f,m=new h,_=new p(e),t.pipe(n).pipe(o),o.pipe(s).pipe(m),o.pipe(u).pipe(c),o.pipe(l).pipe(this.metadataStream).pipe(_),y=new d.CaptionStream,m.pipe(y).pipe(_),o.on("data",function(e){var t,n,r;if("metadata"===e.type){for(t=e.tracks.length;t--;)"video"===e.tracks[t].type?n=e.tracks[t]:"audio"===e.tracks[t].type&&(r=e.tracks[t]);n&&!v&&(_.numberOfTracks++,v=new i(n),m.pipe(v).pipe(_)),r&&!g&&(_.numberOfTracks++,g=new a(r),c.pipe(g).pipe(_),v&&v.on("keyframe",g.onVideoKeyFrame))}}),this.push=function(e){t.push(e)},this.flush=function(){t.flush()},this.resetCaptions=function(){y.reset()},_.on("data",function(e){b.trigger("data",e)}),_.on("done",function(){b.trigger("done")})},r.prototype=new l,t.exports=r},{"../codecs/adts.js":40,"../codecs/h264":41,"../m2ts/m2ts.js":50,"../utils/stream.js":62,"./coalesce-stream.js":43,"./flv-tag.js":45,"./tag-list.js":47}],49:[function(e,t,n){"use strict";var r=e("../utils/stream"),i=function(e){for(var t=0,n={payloadType:-1,payloadSize:0},r=0,i=0;t<e.byteLength&&128!==e[t];){for(;255===e[t];)r+=255,t++;for(r+=e[t++];255===e[t];)i+=255,t++;if(i+=e[t++],!n.payload&&4===r){n.payloadType=r,n.payloadSize=i,n.payload=e.subarray(t,t+i);break}t+=i,r=0,i=0}return n},a=function(e){return 181!==e.payload[0]?null:49!=(e.payload[1]<<8|e.payload[2])?null:"GA94"!==String.fromCharCode(e.payload[3],e.payload[4],e.payload[5],e.payload[6])?null:3!==e.payload[7]?null:e.payload.subarray(8,e.payload.length-1)},o=function(e,t){var n,r,i,a,o=[];if(!(64&t[0]))return o;for(r=31&t[0],n=0;n<r;n++)i=3*n,a={type:3&t[i+2],pts:e},4&t[i+2]&&(a.ccData=t[i+3]<<8|t[i+4],o.push(a));return o},s=function(){s.prototype.init.call(this),this.captionPackets_=[],this.ccStreams_=[new f(0,0),new f(0,1),new f(1,0),new f(1,1)],this.reset(),this.ccStreams_.forEach(function(e){e.on("data",this.trigger.bind(this,"data")),e.on("done",this.trigger.bind(this,"done"))},this)};s.prototype=new r,s.prototype.push=function(e){var t,n;if("sei_rbsp"===e.nalUnitType&&(t=i(e.escapedRBSP),4===t.payloadType&&(n=a(t)))){if(e.dts<this.latestDts_)return void(this.ignoreNextEqualDts_=!0);if(e.dts===this.latestDts_&&this.ignoreNextEqualDts_)return void(this.ignoreNextEqualDts_=!1);this.captionPackets_=this.captionPackets_.concat(o(e.pts,n)),this.latestDts_=e.dts}},s.prototype.flush=function(){if(!this.captionPackets_.length)return void this.ccStreams_.forEach(function(e){e.flush()},this);this.captionPackets_.forEach(function(e,t){e.presortIndex=t}),this.captionPackets_.sort(function(e,t){return e.pts===t.pts?e.presortIndex-t.presortIndex:e.pts-t.pts}),this.captionPackets_.forEach(function(e){e.type<2&&this.dispatchCea608Packet(e)},this),this.captionPackets_.length=0,this.ccStreams_.forEach(function(e){e.flush()},this)},s.prototype.reset=function(){this.latestDts_=null,this.ignoreNextEqualDts_=!1,this.activeCea608Channel_=[null,null],this.ccStreams_.forEach(function(e){e.reset()})},s.prototype.dispatchCea608Packet=function(e){this.setsChannel1Active(e)?this.activeCea608Channel_[e.type]=0:this.setsChannel2Active(e)&&(this.activeCea608Channel_[e.type]=1),null!==this.activeCea608Channel_[e.type]&&this.ccStreams_[(e.type<<1)+this.activeCea608Channel_[e.type]].push(e)},s.prototype.setsChannel1Active=function(e){return 4096==(30720&e.ccData)},s.prototype.setsChannel2Active=function(e){return 6144==(30720&e.ccData)};var u={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,304:174,305:176,306:189,307:191,308:8482,309:162,310:163,311:9834,312:224,313:160,314:232,315:226,316:234,317:238,318:244,319:251,544:193,545:201,546:211,547:218,548:220,549:252,550:8216,551:161,552:42,553:39,554:8212,555:169,556:8480,557:8226,558:8220,559:8221,560:192,561:194,562:199,563:200,564:202,565:203,566:235,567:206,568:207,569:239,570:212,571:217,572:249,573:219,574:171,575:187,800:195,801:227,802:205,803:204,804:236,805:210,806:242,807:213,808:245,809:123,810:125,811:92,812:94,813:95,814:124,815:126,816:196,817:228,818:214,819:246,820:223,821:165,822:164,823:9474,824:197,825:229,826:216,827:248,828:9484,829:9488,830:9492,831:9496},l=function(e){return null===e?"":(e=u[e]||e,String.fromCharCode(e))},c=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],d=function(){for(var e=[],t=15;t--;)e.push("");return e},f=function(e,t){f.prototype.init.call(this),this.field_=e||0,this.dataChannel_=t||0,this.name_="CC"+(1+(this.field_<<1|this.dataChannel_)),this.setConstants(),this.reset(),this.push=function(e){var t,n,r,i,a;if((t=32639&e.ccData)===this.lastControlCode_)return void(this.lastControlCode_=null);if(4096==(61440&t)?this.lastControlCode_=t:t!==this.PADDING_&&(this.lastControlCode_=null),r=t>>>8,i=255&t,t!==this.PADDING_)if(t===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(t===this.END_OF_CAPTION_)this.clearFormatting(e.pts),this.flushDisplayed(e.pts),n=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=n,this.startPts_=e.pts;else if(t===this.ROLL_UP_2_ROWS_)this.topRow_=13,this.mode_="rollUp";else if(t===this.ROLL_UP_3_ROWS_)this.topRow_=12,this.mode_="rollUp";else if(t===this.ROLL_UP_4_ROWS_)this.topRow_=11,this.mode_="rollUp";else if(t===this.CARRIAGE_RETURN_)this.clearFormatting(e.pts),this.flushDisplayed(e.pts),this.shiftRowsUp_(),this.startPts_=e.pts;else if(t===this.BACKSPACE_)"popOn"===this.mode_?this.nonDisplayed_[14]=this.nonDisplayed_[14].slice(0,-1):this.displayed_[14]=this.displayed_[14].slice(0,-1);else if(t===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(e.pts),this.displayed_=d();else if(t===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=d();else if(t===this.RESUME_DIRECT_CAPTIONING_)this.mode_="paintOn";else if(this.isSpecialCharacter(r,i))r=(3&r)<<8,a=l(r|i),this[this.mode_](e.pts,a),this.column_++;else if(this.isExtCharacter(r,i))"popOn"===this.mode_?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[14]=this.displayed_[14].slice(0,-1),r=(3&r)<<8,a=l(r|i),this[this.mode_](e.pts,a),this.column_++;else if(this.isMidRowCode(r,i))this.clearFormatting(e.pts),this[this.mode_](e.pts," "),this.column_++,14==(14&i)&&this.addFormatting(e.pts,["i"]),1==(1&i)&&this.addFormatting(e.pts,["u"]);else if(this.isOffsetControlCode(r,i))this.column_+=3&i;else if(this.isPAC(r,i)){var o=c.indexOf(7968&t);o!==this.row_&&(this.clearFormatting(e.pts),this.row_=o),1&i&&-1===this.formatting_.indexOf("u")&&this.addFormatting(e.pts,["u"]),16==(16&t)&&(this.column_=4*((14&t)>>1)),this.isColorPAC(i)&&14==(14&i)&&this.addFormatting(e.pts,["i"])}else this.isNormalChar(r)&&(0===i&&(i=null),a=l(r),a+=l(i),this[this.mode_](e.pts,a),this.column_+=a.length)}};f.prototype=new r,f.prototype.flushDisplayed=function(e){var t=this.displayed_.map(function(e){return e.trim()}).join("\n").replace(/^\n+|\n+$/g,"");t.length&&this.trigger("data",{startPts:this.startPts_,endPts:e,text:t,stream:this.name_})},f.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=d(),this.nonDisplayed_=d(),this.lastControlCode_=null,this.column_=0,this.row_=14,this.formatting_=[]},f.prototype.setConstants=function(){0===this.dataChannel_?(this.BASE_=16,this.EXT_=17,this.CONTROL_=(20|this.field_)<<8,this.OFFSET_=23):1===this.dataChannel_&&(this.BASE_=24,this.EXT_=25,this.CONTROL_=(28|this.field_)<<8,this.OFFSET_=31),this.PADDING_=0,this.RESUME_CAPTION_LOADING_=32|this.CONTROL_,this.END_OF_CAPTION_=47|this.CONTROL_,this.ROLL_UP_2_ROWS_=37|this.CONTROL_,this.ROLL_UP_3_ROWS_=38|this.CONTROL_,this.ROLL_UP_4_ROWS_=39|this.CONTROL_,this.CARRIAGE_RETURN_=45|this.CONTROL_,this.RESUME_DIRECT_CAPTIONING_=41|this.CONTROL_,this.BACKSPACE_=33|this.CONTROL_,this.ERASE_DISPLAYED_MEMORY_=44|this.CONTROL_,this.ERASE_NON_DISPLAYED_MEMORY_=46|this.CONTROL_},f.prototype.isSpecialCharacter=function(e,t){return e===this.EXT_&&t>=48&&t<=63},f.prototype.isExtCharacter=function(e,t){return(e===this.EXT_+1||e===this.EXT_+2)&&t>=32&&t<=63},f.prototype.isMidRowCode=function(e,t){return e===this.EXT_&&t>=32&&t<=47},f.prototype.isOffsetControlCode=function(e,t){return e===this.OFFSET_&&t>=33&&t<=35},f.prototype.isPAC=function(e,t){return e>=this.BASE_&&e<this.BASE_+8&&t>=64&&t<=127},f.prototype.isColorPAC=function(e){return e>=64&&e<=79||e>=96&&e<=127},f.prototype.isNormalChar=function(e){return e>=32&&e<=127},f.prototype.addFormatting=function(e,t){this.formatting_=this.formatting_.concat(t);var n=t.reduce(function(e,t){return e+"<"+t+">"},"");this[this.mode_](e,n)},f.prototype.clearFormatting=function(e){if(this.formatting_.length){var t=this.formatting_.reverse().reduce(function(e,t){return e+"</"+t+">"},"");this.formatting_=[],this[this.mode_](e,t)}},f.prototype.popOn=function(e,t){var n=this.nonDisplayed_[this.row_];n+=t,this.nonDisplayed_[this.row_]=n},f.prototype.rollUp=function(e,t){var n=this.displayed_[14];n+=t,this.displayed_[14]=n},f.prototype.shiftRowsUp_=function(){var e;for(e=0;e<this.topRow_;e++)this.displayed_[e]="";for(e=this.topRow_;e<14;e++)this.displayed_[e]=this.displayed_[e+1];this.displayed_[14]=""},f.prototype.paintOn=function(){},t.exports={CaptionStream:s,Cea608Stream:f}},{"../utils/stream":62}],50:[function(e,t,n){"use strict";var r,i,a,o=e("../utils/stream.js"),s=e("./caption-stream"),u=e("./stream-types"),l=e("./timestamp-rollover-stream").TimestampRolloverStream,c=e("./stream-types.js");r=function(){var e=new Uint8Array(188),t=0;r.prototype.init.call(this),this.push=function(n){var r,i=0,a=188;for(t?(r=new Uint8Array(n.byteLength+t),r.set(e.subarray(0,t)),r.set(n,t),t=0):r=n;a<r.byteLength;)71!==r[i]||71!==r[a]?(i++,a++):(this.trigger("data",r.subarray(i,a)),i+=188,a+=188);i<r.byteLength&&(e.set(r.subarray(i),0),t=r.byteLength-i)},this.flush=function(){188===t&&71===e[0]&&(this.trigger("data",e),t=0),this.trigger("done")}},r.prototype=new o,i=function(){var e,t,n,r;i.prototype.init.call(this),r=this,this.packetsWaitingForPmt=[],this.programMapTable=void 0,e=function(e,r){var i=0;r.payloadUnitStartIndicator&&(i+=e[i]+1),"pat"===r.type?t(e.subarray(i),r):n(e.subarray(i),r)},t=function(e,t){t.section_number=e[7],t.last_section_number=e[8],r.pmtPid=(31&e[10])<<8|e[11],t.pmtPid=r.pmtPid},n=function(e,t){var n,i,a,o;if(1&e[5]){for(r.programMapTable={video:null,audio:null,"timed-metadata":{}},n=(15&e[1])<<8|e[2],i=3+n-4,a=(15&e[10])<<8|e[11],o=12+a;o<i;){var s=e[o],l=(31&e[o+1])<<8|e[o+2];s===u.H264_STREAM_TYPE&&null===r.programMapTable.video?r.programMapTable.video=l:s===u.ADTS_STREAM_TYPE&&null===r.programMapTable.audio?r.programMapTable.audio=l:s===u.METADATA_STREAM_TYPE&&(r.programMapTable["timed-metadata"][l]=s),o+=5+((15&e[o+3])<<8|e[o+4])}t.programMapTable=r.programMapTable}},this.push=function(t){var n={},r=4;if(n.payloadUnitStartIndicator=!!(64&t[1]),n.pid=31&t[1],n.pid<<=8,n.pid|=t[2],(48&t[3])>>>4>1&&(r+=t[r]+1),0===n.pid)n.type="pat",e(t.subarray(r),n),this.trigger("data",n);else if(n.pid===this.pmtPid)for(n.type="pmt",e(t.subarray(r),n),this.trigger("data",n);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else void 0===this.programMapTable?this.packetsWaitingForPmt.push([t,r,n]):this.processPes_(t,r,n)},this.processPes_=function(e,t,n){n.pid===this.programMapTable.video?n.streamType=u.H264_STREAM_TYPE:n.pid===this.programMapTable.audio?n.streamType=u.ADTS_STREAM_TYPE:n.streamType=this.programMapTable["timed-metadata"][n.pid],n.type="pes",n.data=e.subarray(t),this.trigger("data",n)}},i.prototype=new o,i.STREAM_TYPES={h264:27,adts:15},a=function(){var e=this,t={data:[],size:0},n={data:[],size:0},r={data:[],size:0},i=function(e,t){var n;t.packetLength=6+(e[4]<<8|e[5]),t.dataAlignmentIndicator=0!=(4&e[6]),n=e[7],192&n&&(t.pts=(14&e[9])<<27|(255&e[10])<<20|(254&e[11])<<12|(255&e[12])<<5|(254&e[13])>>>3,t.pts*=4,t.pts+=(6&e[13])>>>1,t.dts=t.pts,64&n&&(t.dts=(14&e[14])<<27|(255&e[15])<<20|(254&e[16])<<12|(255&e[17])<<5|(254&e[18])>>>3,t.dts*=4,t.dts+=(6&e[18])>>>1)),t.data=e.subarray(9+e[8])},o=function(t,n,r){var a,o=new Uint8Array(t.size),s={type:n},u=0,l=0,c=!1;if(t.data.length&&!(t.size<9)){for(s.trackId=t.data[0].pid,u=0;u<t.data.length;u++)a=t.data[u],o.set(a.data,l),l+=a.data.byteLength;i(o,s),c="video"===n||s.packetLength<=t.size,(r||c)&&(t.size=0,t.data.length=0),c&&e.trigger("data",s)}};a.prototype.init.call(this),this.push=function(i){({pat:function(){},pes:function(){var e,a;switch(i.streamType){case u.H264_STREAM_TYPE:case c.H264_STREAM_TYPE:e=t,a="video";break;case u.ADTS_STREAM_TYPE:e=n,a="audio";break;case u.METADATA_STREAM_TYPE:e=r,a="timed-metadata";break;default:return}i.payloadUnitStartIndicator&&o(e,a,!0),e.data.push(i),e.size+=i.data.byteLength},pmt:function(){var t={type:"metadata",tracks:[]},n=i.programMapTable;null!==n.video&&t.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+n.video,codec:"avc",type:"video"}),null!==n.audio&&t.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+n.audio,codec:"adts",type:"audio"}),e.trigger("data",t)}})[i.type]()},this.flush=function(){o(t,"video"),o(n,"audio"),o(r,"timed-metadata"),this.trigger("done")}},a.prototype=new o;var d={PAT_PID:0,MP2T_PACKET_LENGTH:188,TransportPacketStream:r,TransportParseStream:i,ElementaryStream:a,TimestampRolloverStream:l,CaptionStream:s.CaptionStream,Cea608Stream:s.Cea608Stream,MetadataStream:e("./metadata-stream")};for(var f in u)u.hasOwnProperty(f)&&(d[f]=u[f]);t.exports=d},{"../utils/stream.js":62,"./caption-stream":49,"./metadata-stream":51,"./stream-types":53,"./stream-types.js":53,"./timestamp-rollover-stream":54}],51:[function(e,t,n){"use strict";var r,i=e("../utils/stream"),a=e("./stream-types"),o=function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i},s=function(e,t,n){return decodeURIComponent(o(e,t,n))},u=function(e,t,n){return unescape(o(e,t,n))},l=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},c={TXXX:function(e){var t;if(3===e.data[0]){for(t=1;t<e.data.length;t++)if(0===e.data[t]){e.description=s(e.data,1,t),e.value=s(e.data,t+1,e.data.length).replace(/\0*$/,"");break}e.data=e.value}},WXXX:function(e){var t;if(3===e.data[0])for(t=1;t<e.data.length;t++)if(0===e.data[t]){e.description=s(e.data,1,t),e.url=s(e.data,t+1,e.data.length);break}},PRIV:function(e){var t;for(t=0;t<e.data.length;t++)if(0===e.data[t]){e.owner=u(e.data,0,t);break}e.privateData=e.data.subarray(t+1),e.data=e.privateData}};r=function(e){var t,n={debug:!(!e||!e.debug),descriptor:e&&e.descriptor},i=0,o=[],s=0;if(r.prototype.init.call(this),this.dispatchType=a.METADATA_STREAM_TYPE.toString(16),n.descriptor)for(t=0;t<n.descriptor.length;t++)this.dispatchType+=("00"+n.descriptor[t].toString(16)).slice(-2);this.push=function(e){var t,r,a,u,d,f;if("timed-metadata"===e.type){if(e.dataAlignmentIndicator&&(s=0,o.length=0),0===o.length&&(e.data.length<10||e.data[0]!=="I".charCodeAt(0)||e.data[1]!=="D".charCodeAt(0)||e.data[2]!=="3".charCodeAt(0)))return void(n.debug&&console.log("Skipping unrecognized metadata packet"));if(o.push(e),s+=e.data.byteLength,1===o.length&&(i=l(e.data.subarray(6,10)),i+=10),!(s<i)){for(t={data:new Uint8Array(i),frames:[],pts:o[0].pts,dts:o[0].dts},d=0;d<i;)t.data.set(o[0].data.subarray(0,i-d),d),d+=o[0].data.byteLength,s-=o[0].data.byteLength,o.shift();r=10,64&t.data[5]&&(r+=4,r+=l(t.data.subarray(10,14)),i-=l(t.data.subarray(16,20)));do{if((a=l(t.data.subarray(r+4,r+8)))<1)return console.log("Malformed ID3 frame encountered. Skipping metadata parsing.");if(f=String.fromCharCode(t.data[r],t.data[r+1],t.data[r+2],t.data[r+3]),u={id:f,data:t.data.subarray(r+10,r+a+10)},u.key=u.id,c[u.id]&&(c[u.id](u),"com.apple.streaming.transportStreamTimestamp"===u.owner)){var h=u.data,p=(1&h[3])<<30|h[4]<<22|h[5]<<14|h[6]<<6|h[7]>>>2;p*=4,p+=3&h[7],u.timeStamp=p,void 0===t.pts&&void 0===t.dts&&(t.pts=u.timeStamp,t.dts=u.timeStamp),this.trigger("timestamp",u)}t.frames.push(u),r+=10,r+=a}while(r<i);this.trigger("data",t)}}}},r.prototype=new i,t.exports=r},{"../utils/stream":62,"./stream-types":53}],52:[function(e,t,n){"use strict";var r=e("./stream-types.js"),i=function(e){var t=31&e[1];return t<<=8,t|=e[2]},a=function(e){return!!(64&e[1])},o=function(e){var t=0;return(48&e[3])>>>4>1&&(t+=e[4]+1),t},s=function(e,t){var n=i(e);return 0===n?"pat":n===t?"pmt":t?"pes":null},u=function(e){var t=a(e),n=4+o(e);return t&&(n+=e[n]+1),(31&e[n+10])<<8|e[n+11]},l=function(e){var t={},n=a(e),r=4+o(e);if(n&&(r+=e[r]+1),1&e[r+5]){var i,s,u;i=(15&e[r+1])<<8|e[r+2],s=3+i-4,u=(15&e[r+10])<<8|e[r+11];for(var l=12+u;l<s;){var c=r+l;t[(31&e[c+1])<<8|e[c+2]]=e[c],l+=5+((15&e[c+3])<<8|e[c+4])}return t}},c=function(e,t){switch(t[i(e)]){case r.H264_STREAM_TYPE:return"video";case r.ADTS_STREAM_TYPE:return"audio";case r.METADATA_STREAM_TYPE:return"timed-metadata";default:return null}},d=function(e){if(!a(e))return null;var t=4+o(e);if(t>=e.byteLength)return null;var n,r=null;return n=e[t+7],192&n&&(r={},r.pts=(14&e[t+9])<<27|(255&e[t+10])<<20|(254&e[t+11])<<12|(255&e[t+12])<<5|(254&e[t+13])>>>3,r.pts*=4,r.pts+=(6&e[t+13])>>>1,r.dts=r.pts,64&n&&(r.dts=(14&e[t+14])<<27|(255&e[t+15])<<20|(254&e[t+16])<<12|(255&e[t+17])<<5|(254&e[t+18])>>>3,r.dts*=4,r.dts+=(6&e[t+18])>>>1)),r},f=function(e){switch(e){case 5:return"slice_layer_without_partitioning_rbsp_idr";case 6:return"sei_rbsp";case 7:return"seq_parameter_set_rbsp";case 8:return"pic_parameter_set_rbsp";case 9:return"access_unit_delimiter_rbsp";default:return null}},h=function(e){for(var t,n=4+o(e),r=e.subarray(n),i=0,a=0,s=!1;a<r.byteLength-3;a++)if(1===r[a+2]){i=a+5;break}for(;i<r.byteLength;)switch(r[i]){case 0:if(0!==r[i-1]){i+=2;break}if(0!==r[i-2]){i++;break}a+3!==i-2&&"slice_layer_without_partitioning_rbsp_idr"===(t=f(31&r[a+3]))&&(s=!0);do{i++}while(1!==r[i]&&i<r.length);a=i-2,i+=3;break;case 1:if(0!==r[i-1]||0!==r[i-2]){i+=3;break}t=f(31&r[a+3]),"slice_layer_without_partitioning_rbsp_idr"===t&&(s=!0),a=i-2,i+=3;break;default:i+=3}return r=r.subarray(a),i-=a,a=0,r&&r.byteLength>3&&"slice_layer_without_partitioning_rbsp_idr"===(t=f(31&r[a+3]))&&(s=!0),s};t.exports={parseType:s,parsePat:u,parsePmt:l,parsePayloadUnitStartIndicator:a,parsePesType:c,parsePesTime:d,videoPacketContainsKeyFrame:h}},{"./stream-types.js":53}],53:[function(e,t,n){"use strict";t.exports={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21}},{}],54:[function(e,t,n){"use strict";var r=e("../utils/stream"),i=function(e,t){var n=1;for(e>t&&(n=-1);Math.abs(t-e)>4294967296;)e+=8589934592*n;return e},a=function(e){var t,n;a.prototype.init.call(this),this.type_=e,this.push=function(e){e.type===this.type_&&(void 0===n&&(n=e.dts),e.dts=i(e.dts,n),e.pts=i(e.pts,n),t=e.dts,this.trigger("data",e))},this.flush=function(){n=t,this.trigger("done")},this.discontinuity=function(){n=void 0,t=void 0}};a.prototype=new r,t.exports={TimestampRolloverStream:a,handleRollover:i}},{"../utils/stream":62}],55:[function(e,t,n){t.exports={generator:e("./mp4-generator"),Transmuxer:e("./transmuxer").Transmuxer,AudioSegmentStream:e("./transmuxer").AudioSegmentStream,VideoSegmentStream:e("./transmuxer").VideoSegmentStream}},{"./mp4-generator":56,"./transmuxer":58}],56:[function(e,t,n){"use strict";var r,i,a,o,s,u,l,c,d,f,h,p,m,v,g,y,_,b,T,S,w,k,E,A,C,L,x,j,O,I,P,R,D,M,U,B,N=Math.pow(2,32)-1;!function(){var e;if(E={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],sdtp:[],smhd:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],styp:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[]},"undefined"!=typeof Uint8Array){for(e in E)E.hasOwnProperty(e)&&(E[e]=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)]);A=new Uint8Array(["i".charCodeAt(0),"s".charCodeAt(0),"o".charCodeAt(0),"m".charCodeAt(0)]),L=new Uint8Array(["a".charCodeAt(0),"v".charCodeAt(0),"c".charCodeAt(0),"1".charCodeAt(0)]),C=new Uint8Array([0,0,0,1]),x=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),j=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),O={video:x,audio:j},R=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),P=new Uint8Array([0,0,0,0,0,0,0,0]),D=new Uint8Array([0,0,0,0,0,0,0,0]),M=D,U=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),B=D,I=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}}(),r=function(e){var t,n,r,i=[],a=0;for(t=1;t<arguments.length;t++)i.push(arguments[t]);for(t=i.length;t--;)a+=i[t].byteLength;for(n=new Uint8Array(a+8),r=new DataView(n.buffer,n.byteOffset,n.byteLength),r.setUint32(0,n.byteLength),n.set(e,4),t=0,a=8;t<i.length;t++)n.set(i[t],a),a+=i[t].byteLength;return n},i=function(){return r(E.dinf,r(E.dref,R))},a=function(e){return r(E.esds,new Uint8Array([0,0,0,0,3,25,0,0,0,4,17,64,21,0,6,0,0,0,218,192,0,0,218,192,5,2,e.audioobjecttype<<3|e.samplingfrequencyindex>>>1,e.samplingfrequencyindex<<7|e.channelcount<<3,6,1,2]))},o=function(){return r(E.ftyp,A,C,A,L)},y=function(e){return r(E.hdlr,O[e])},s=function(e){return r(E.mdat,e)},g=function(e){var t=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,e.duration>>>24&255,e.duration>>>16&255,e.duration>>>8&255,255&e.duration,85,196,0,0]);return e.samplerate&&(t[12]=e.samplerate>>>24&255,t[13]=e.samplerate>>>16&255,t[14]=e.samplerate>>>8&255,t[15]=255&e.samplerate),r(E.mdhd,t)},v=function(e){return r(E.mdia,g(e),y(e.type),l(e))},u=function(e){return r(E.mfhd,new Uint8Array([0,0,0,0,(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e]))},l=function(e){return r(E.minf,"video"===e.type?r(E.vmhd,I):r(E.smhd,P),i(),b(e))},c=function(e,t){for(var n=[],i=t.length;i--;)n[i]=S(t[i]);return r.apply(null,[E.moof,u(e)].concat(n))},d=function(e){for(var t=e.length,n=[];t--;)n[t]=p(e[t]);return r.apply(null,[E.moov,h(4294967295)].concat(n).concat(f(e)))},f=function(e){for(var t=e.length,n=[];t--;)n[t]=w(e[t]);return r.apply(null,[E.mvex].concat(n))},h=function(e){var t=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return r(E.mvhd,t)},_=function(e){var t,n,i=e.samples||[],a=new Uint8Array(4+i.length);for(n=0;n<i.length;n++)t=i[n].flags,a[n+4]=t.dependsOn<<4|t.isDependedOn<<2|t.hasRedundancy;return r(E.sdtp,a)},b=function(e){return r(E.stbl,T(e),r(E.stts,B),r(E.stsc,M),r(E.stsz,U),r(E.stco,D))},function(){var e,t;T=function(n){return r(E.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),"video"===n.type?e(n):t(n))},e=function(e){var t,n=e.sps||[],i=e.pps||[],a=[],o=[];for(t=0;t<n.length;t++)a.push((65280&n[t].byteLength)>>>8),a.push(255&n[t].byteLength),a=a.concat(Array.prototype.slice.call(n[t]));for(t=0;t<i.length;t++)o.push((65280&i[t].byteLength)>>>8),o.push(255&i[t].byteLength),o=o.concat(Array.prototype.slice.call(i[t]));return r(E.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,(65280&e.width)>>8,255&e.width,(65280&e.height)>>8,255&e.height,0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),r(E.avcC,new Uint8Array([1,e.profileIdc,e.profileCompatibility,e.levelIdc,255].concat([n.length]).concat(a).concat([i.length]).concat(o))),r(E.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])))},t=function(e){return r(E.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(65280&e.channelcount)>>8,255&e.channelcount,(65280&e.samplesize)>>8,255&e.samplesize,0,0,0,0,(65280&e.samplerate)>>8,255&e.samplerate,0,0]),a(e))}}(),m=function(e){var t=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(4278190080&e.id)>>24,(16711680&e.id)>>16,(65280&e.id)>>8,255&e.id,0,0,0,0,(4278190080&e.duration)>>24,(16711680&e.duration)>>16,(65280&e.duration)>>8,255&e.duration,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,(65280&e.width)>>8,255&e.width,0,0,(65280&e.height)>>8,255&e.height,0,0]);return r(E.tkhd,t)},S=function(e){var t,n,i,a,o,s,u;return t=r(E.tfhd,new Uint8Array([0,0,0,58,(4278190080&e.id)>>24,(16711680&e.id)>>16,(65280&e.id)>>8,255&e.id,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),s=Math.floor(e.baseMediaDecodeTime/(N+1)),u=Math.floor(e.baseMediaDecodeTime%(N+1)),n=r(E.tfdt,new Uint8Array([1,0,0,0,s>>>24&255,s>>>16&255,s>>>8&255,255&s,u>>>24&255,u>>>16&255,u>>>8&255,255&u])),o=92,"audio"===e.type?(i=k(e,o),r(E.traf,t,n,i)):(a=_(e),i=k(e,a.length+o),r(E.traf,t,n,i,a))},p=function(e){return e.duration=e.duration||4294967295,r(E.trak,m(e),v(e))},w=function(e){var t=new Uint8Array([0,0,0,0,(4278190080&e.id)>>24,(16711680&e.id)>>16,(65280&e.id)>>8,255&e.id,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return"video"!==e.type&&(t[t.length-1]=0),r(E.trex,t)},function(){var e,t,n;n=function(e,t){var n=0,r=0,i=0,a=0;return e.length&&(void 0!==e[0].duration&&(n=1),void 0!==e[0].size&&(r=2),void 0!==e[0].flags&&(i=4),void 0!==e[0].compositionTimeOffset&&(a=8)),[0,0,n|r|i|a,1,(4278190080&e.length)>>>24,(16711680&e.length)>>>16,(65280&e.length)>>>8,255&e.length,(4278190080&t)>>>24,(16711680&t)>>>16,(65280&t)>>>8,255&t]},t=function(e,t){var i,a,o,s;for(a=e.samples||[],t+=20+16*a.length,i=n(a,t),s=0;s<a.length;s++)o=a[s],i=i.concat([(4278190080&o.duration)>>>24,(16711680&o.duration)>>>16,(65280&o.duration)>>>8,255&o.duration,(4278190080&o.size)>>>24,(16711680&o.size)>>>16,(65280&o.size)>>>8,255&o.size,o.flags.isLeading<<2|o.flags.dependsOn,o.flags.isDependedOn<<6|o.flags.hasRedundancy<<4|o.flags.paddingValue<<1|o.flags.isNonSyncSample,61440&o.flags.degradationPriority,15&o.flags.degradationPriority,(4278190080&o.compositionTimeOffset)>>>24,(16711680&o.compositionTimeOffset)>>>16,(65280&o.compositionTimeOffset)>>>8,255&o.compositionTimeOffset]);return r(E.trun,new Uint8Array(i))},e=function(e,t){var i,a,o,s;for(a=e.samples||[],t+=20+8*a.length,i=n(a,t),s=0;s<a.length;s++)o=a[s],i=i.concat([(4278190080&o.duration)>>>24,(16711680&o.duration)>>>16,(65280&o.duration)>>>8,255&o.duration,(4278190080&o.size)>>>24,(16711680&o.size)>>>16,(65280&o.size)>>>8,255&o.size]);return r(E.trun,new Uint8Array(i))},k=function(n,r){return"audio"===n.type?e(n,r):t(n,r)}}(),t.exports={ftyp:o,mdat:s,moof:c,moov:d,initSegment:function(e){var t,n=o(),r=d(e);return t=new Uint8Array(n.byteLength+r.byteLength),t.set(n),t.set(r,n.byteLength),t}}},{}],57:[function(e,t,n){"use strict";var r,i,a,o;r=function(e,t){var n,a,o,s,u,l=[];if(!t.length)return null;for(n=0;n<e.byteLength;)a=e[n]<<24,a|=e[n+1]<<16,a|=e[n+2]<<8,a|=e[n+3],o=i(e.subarray(n+4,n+8)),s=a>1?n+a:e.byteLength,o===t[0]&&(1===t.length?l.push(e.subarray(n+8,s)):(u=r(e.subarray(n+8,s),t.slice(1)),u.length&&(l=l.concat(u)))),n=s;return l},i=function(e){var t="";return t+=String.fromCharCode(e[0]),t+=String.fromCharCode(e[1]),t+=String.fromCharCode(e[2]),t+=String.fromCharCode(e[3])},a=function(e){var t={};return r(e,["moov","trak"]).reduce(function(e,t){var n,i,a,o,s;return(n=r(t,["tkhd"])[0])?(i=n[0],a=0===i?12:20,o=n[a]<<24|n[a+1]<<16|n[a+2]<<8|n[a+3],(s=r(t,["mdia","mdhd"])[0])?(i=s[0],a=0===i?12:20,e[o]=s[a]<<24|s[a+1]<<16|s[a+2]<<8|s[a+3],e):null):null},t)},o=function(e,t){var n,i,a;return n=r(t,["moof","traf"]),i=[].concat.apply([],n.map(function(t){return r(t,["tfhd"]).map(function(n){var i,a,o;return i=n[4]<<24|n[5]<<16|n[6]<<8|n[7],a=e[i]||9e4,o=r(t,["tfdt"]).map(function(e){var t,n;return t=e[0],n=e[4]<<24|e[5]<<16|e[6]<<8|e[7],1===t&&(n*=Math.pow(2,32),n+=e[8]<<24|e[9]<<16|e[10]<<8|e[11]),n})[0],(o=o||1/0)/a})})),a=Math.min.apply(null,i),isFinite(a)?a:0},t.exports={parseType:i,timescale:a,startTime:o}},{}],58:[function(e,t,n){"use strict";var r,i,a,o,s,u,l,c,d,f,h,p=e("../utils/stream.js"),m=e("./mp4-generator.js"),v=e("../m2ts/m2ts.js"),g=e("../codecs/adts.js"),y=e("../codecs/h264").H264Stream,_=e("../aac"),b=e("../data/silence"),T=e("../utils/clock"),S=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],w=["width","height","profileIdc","levelIdc","profileCompatibility"];s=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0}}},u=function(e){return e[0]==="I".charCodeAt(0)&&e[1]==="D".charCodeAt(0)&&e[2]==="3".charCodeAt(0)},f=function(e,t){var n;if(e.length!==t.length)return!1;for(n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0},h=function(e){var t,n,r=0;for(t=0;t<e.length;t++)n=e[t],r+=n.data.byteLength;return r},i=function(e){var t=[],n=0,r=0,a=0,o=1/0;i.prototype.init.call(this),this.push=function(n){l(e,n),e&&S.forEach(function(t){e[t]=n[t]}),t.push(n)},this.setEarliestDts=function(t){r=t-e.timelineStartInfo.baseMediaDecodeTime},this.setVideoBaseMediaDecodeTime=function(e){o=e},this.setAudioAppendStart=function(e){a=e},this.flush=function(){var r,i,a,o;if(0===t.length)return void this.trigger("done","AudioSegmentStream");r=this.trimAdtsFramesByEarliestDts_(t),e.baseMediaDecodeTime=d(e),this.prefixWithSilence_(e,r),e.samples=this.generateSampleTable_(r),a=m.mdat(this.concatenateFrameData_(r)),t=[],i=m.moof(n,[e]),o=new Uint8Array(i.byteLength+a.byteLength),n++,o.set(i),o.set(a,i.byteLength),c(e),this.trigger("data",{track:e,boxes:o}),this.trigger("done","AudioSegmentStream")},this.prefixWithSilence_=function(e,t){var n,r,i,s=0,u=0,l=0,c=0;if(t.length&&(n=T.audioTsToVideoTs(e.baseMediaDecodeTime,e.samplerate),s=Math.ceil(9e4/(e.samplerate/1024)),a&&o&&(u=n-Math.max(a,o),l=Math.floor(u/s),c=l*s),!(l<1||c>45e3))){for(r=b[e.samplerate],r||(r=t[0].data),i=0;i<l;i++)t.splice(i,0,{data:r});e.baseMediaDecodeTime-=Math.floor(T.videoTsToAudioTs(c,e.samplerate))}},this.trimAdtsFramesByEarliestDts_=function(t){return e.minSegmentDts>=r?t:(e.minSegmentDts=1/0,t.filter(function(t){return t.dts>=r&&(e.minSegmentDts=Math.min(e.minSegmentDts,t.dts),e.minSegmentPts=e.minSegmentDts,!0)}))},this.generateSampleTable_=function(e){var t,n,r=[];for(t=0;t<e.length;t++)n=e[t],r.push({size:n.data.byteLength,duration:1024});return r},this.concatenateFrameData_=function(e){var t,n,r=0,i=new Uint8Array(h(e));for(t=0;t<e.length;t++)n=e[t],i.set(n.data,r),r+=n.data.byteLength;return i}},i.prototype=new p,r=function(e,t){var n,i,a=0,o=[],u=[];t=t||{},r.prototype.init.call(this),delete e.minPTS,this.gopCache_=[],this.push=function(t){l(e,t),"seq_parameter_set_rbsp"!==t.nalUnitType||n||(n=t.config,e.sps=[t.data],w.forEach(function(t){e[t]=n[t]},this)),"pic_parameter_set_rbsp"!==t.nalUnitType||i||(i=t.data,e.pps=[t.data]),o.push(t)},this.flush=function(){for(var n,r,i,s,f,h;o.length&&"access_unit_delimiter_rbsp"!==o[0].nalUnitType;)o.shift();if(0===o.length)return this.resetStream_(),void this.trigger("done","VideoSegmentStream");if(n=this.groupNalsIntoFrames_(o),i=this.groupFramesIntoGops_(n),i[0][0].keyFrame||(r=this.getGopForFusion_(o[0],e),r?(i.unshift(r),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.pts=r.pts,i.dts=r.dts,i.duration+=r.duration):i=this.extendFirstKeyFrame_(i)),u.length){var p;if(!(p=t.alignGopsAtEnd?this.alignGopsAtEnd_(i):this.alignGopsAtStart_(i)))return this.gopCache_.unshift({gop:i.pop(),pps:e.pps,sps:e.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),o=[],this.resetStream_(),void this.trigger("done","VideoSegmentStream");c(e),i=p}l(e,i),e.samples=this.generateSampleTable_(i),f=m.mdat(this.concatenateNalData_(i)),e.baseMediaDecodeTime=d(e),this.trigger("processedGopsInfo",i.map(function(e){return{pts:e.pts,dts:e.dts,byteLength:e.byteLength}})),this.gopCache_.unshift({gop:i.pop(),pps:e.pps,sps:e.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),o=[],this.trigger("baseMediaDecodeTime",e.baseMediaDecodeTime),this.trigger("timelineStartInfo",e.timelineStartInfo),s=m.moof(a,[e]),h=new Uint8Array(s.byteLength+f.byteLength),a++,h.set(s),h.set(f,s.byteLength),this.trigger("data",{track:e,boxes:h}),this.resetStream_(),this.trigger("done","VideoSegmentStream")},this.resetStream_=function(){c(e),n=void 0,i=void 0},this.getGopForFusion_=function(t){var n,r,i,a,o,s=1/0;for(o=0;o<this.gopCache_.length;o++)a=this.gopCache_[o],i=a.gop,e.pps&&f(e.pps[0],a.pps[0])&&e.sps&&f(e.sps[0],a.sps[0])&&(i.dts<e.timelineStartInfo.dts||(n=t.dts-i.dts-i.duration)>=-1e4&&n<=45e3&&(!r||s>n)&&(r=a,s=n));return r?r.gop:null},this.extendFirstKeyFrame_=function(e){var t;return!e[0][0].keyFrame&&e.length>1&&(t=e.shift(),e.byteLength-=t.byteLength,e.nalCount-=t.nalCount,e[0][0].dts=t.dts,e[0][0].pts=t.pts,e[0][0].duration+=t.duration),e},this.groupNalsIntoFrames_=function(e){var t,n,r=[],i=[];for(r.byteLength=0,t=0;t<e.length;t++)n=e[t],"access_unit_delimiter_rbsp"===n.nalUnitType?(r.length&&(r.duration=n.dts-r.dts,i.push(r)),r=[n],r.byteLength=n.data.byteLength,r.pts=n.pts,r.dts=n.dts):("slice_layer_without_partitioning_rbsp_idr"===n.nalUnitType&&(r.keyFrame=!0),r.duration=n.dts-r.dts,r.byteLength+=n.data.byteLength,r.push(n));return i.length&&(!r.duration||r.duration<=0)&&(r.duration=i[i.length-1].duration),i.push(r),i},this.groupFramesIntoGops_=function(e){var t,n,r=[],i=[];for(r.byteLength=0,r.nalCount=0,r.duration=0,r.pts=e[0].pts,r.dts=e[0].dts,i.byteLength=0,i.nalCount=0,i.duration=0,i.pts=e[0].pts,i.dts=e[0].dts,t=0;t<e.length;t++)n=e[t],n.keyFrame?(r.length&&(i.push(r),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.duration+=r.duration),r=[n],r.nalCount=n.length,r.byteLength=n.byteLength,r.pts=n.pts,r.dts=n.dts,r.duration=n.duration):(r.duration+=n.duration,r.nalCount+=n.length,r.byteLength+=n.byteLength,r.push(n));return i.length&&r.duration<=0&&(r.duration=i[i.length-1].duration),i.byteLength+=r.byteLength,i.nalCount+=r.nalCount,i.duration+=r.duration,i.push(r),i},this.generateSampleTable_=function(e,t){var n,r,i,a,o,u=t||0,l=[];for(n=0;n<e.length;n++)for(a=e[n],r=0;r<a.length;r++)o=a[r],i=s(),i.dataOffset=u,i.compositionTimeOffset=o.pts-o.dts,i.duration=o.duration,i.size=4*o.length,i.size+=o.byteLength,o.keyFrame&&(i.flags.dependsOn=2),u+=i.size,l.push(i);return l},this.concatenateNalData_=function(e){var t,n,r,i,a,o,s=0,u=e.byteLength,l=e.nalCount,c=u+4*l,d=new Uint8Array(c),f=new DataView(d.buffer);for(t=0;t<e.length;t++)for(i=e[t],n=0;n<i.length;n++)for(a=i[n],r=0;r<a.length;r++)o=a[r],f.setUint32(s,o.data.byteLength),s+=4,d.set(o.data,s),s+=o.data.byteLength;return d},this.alignGopsAtStart_=function(e){var t,n,r,i,a,o,s,l;for(a=e.byteLength,o=e.nalCount,s=e.duration,t=n=0;t<u.length&&n<e.length&&(r=u[t],i=e[n],r.pts!==i.pts);)i.pts>r.pts?t++:(n++,a-=i.byteLength,o-=i.nalCount,s-=i.duration);return 0===n?e:n===e.length?null:(l=e.slice(n),l.byteLength=a,l.duration=s,l.nalCount=o,l.pts=l[0].pts,l.dts=l[0].dts,l)},this.alignGopsAtEnd_=function(e){var t,n,r,i,a,o;for(t=u.length-1,n=e.length-1,a=null,o=!1;t>=0&&n>=0;){if(r=u[t],i=e[n],r.pts===i.pts){o=!0;break}r.pts>i.pts?t--:(t===u.length-1&&(a=n),n--)}if(!o&&null===a)return null;var s;if(0===(s=o?n:a))return e;var l=e.slice(s),c=l.reduce(function(e,t){return e.byteLength+=t.byteLength,e.duration+=t.duration,e.nalCount+=t.nalCount,e},{byteLength:0,duration:0,nalCount:0});return l.byteLength=c.byteLength,l.duration=c.duration,l.nalCount=c.nalCount,l.pts=l[0].pts,l.dts=l[0].dts,l},this.alignGopsWith=function(e){u=e}},r.prototype=new p,l=function(e,t){"number"==typeof t.pts&&(void 0===e.timelineStartInfo.pts&&(e.timelineStartInfo.pts=t.pts),void 0===e.minSegmentPts?e.minSegmentPts=t.pts:e.minSegmentPts=Math.min(e.minSegmentPts,t.pts),void 0===e.maxSegmentPts?e.maxSegmentPts=t.pts:e.maxSegmentPts=Math.max(e.maxSegmentPts,t.pts)),"number"==typeof t.dts&&(void 0===e.timelineStartInfo.dts&&(e.timelineStartInfo.dts=t.dts),void 0===e.minSegmentDts?e.minSegmentDts=t.dts:e.minSegmentDts=Math.min(e.minSegmentDts,t.dts),void 0===e.maxSegmentDts?e.maxSegmentDts=t.dts:e.maxSegmentDts=Math.max(e.maxSegmentDts,t.dts))},c=function(e){delete e.minSegmentDts,delete e.maxSegmentDts,delete e.minSegmentPts,delete e.maxSegmentPts},d=function(e){var t,n,r=e.minSegmentDts-e.timelineStartInfo.dts;return t=e.timelineStartInfo.baseMediaDecodeTime,t+=r,t=Math.max(0,t),"audio"===e.type&&(n=e.samplerate/9e4,t*=n,t=Math.floor(t)),t},o=function(e,t){this.numberOfTracks=0,this.metadataStream=t,void 0!==e.remux?this.remuxTracks=!!e.remux:this.remuxTracks=!0,this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,o.prototype.init.call(this),this.push=function(e){return e.text?this.pendingCaptions.push(e):e.frames?this.pendingMetadata.push(e):(this.pendingTracks.push(e.track),this.pendingBoxes.push(e.boxes),this.pendingBytes+=e.boxes.byteLength,"video"===e.track.type&&(this.videoTrack=e.track),void("audio"===e.track.type&&(this.audioTrack=e.track)))}},o.prototype=new p,o.prototype.flush=function(e){var t,n,r,i,a=0,o={captions:[],captionStreams:{},metadata:[],info:{}},s=0;if(this.pendingTracks.length<this.numberOfTracks){if("VideoSegmentStream"!==e&&"AudioSegmentStream"!==e)return;if(this.remuxTracks)return;if(0===this.pendingTracks.length)return void(++this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0))}for(this.videoTrack?(s=this.videoTrack.timelineStartInfo.pts,w.forEach(function(e){o.info[e]=this.videoTrack[e]},this)):this.audioTrack&&(s=this.audioTrack.timelineStartInfo.pts,S.forEach(function(e){o.info[e]=this.audioTrack[e]},this)),1===this.pendingTracks.length?o.type=this.pendingTracks[0].type:o.type="combined",this.emittedTracks+=this.pendingTracks.length,r=m.initSegment(this.pendingTracks),o.initSegment=new Uint8Array(r.byteLength),o.initSegment.set(r),o.data=new Uint8Array(this.pendingBytes),i=0;i<this.pendingBoxes.length;i++)o.data.set(this.pendingBoxes[i],a),a+=this.pendingBoxes[i].byteLength;for(i=0;i<this.pendingCaptions.length;i++)t=this.pendingCaptions[i],t.startTime=t.startPts-s,t.startTime/=9e4,t.endTime=t.endPts-s,t.endTime/=9e4,o.captionStreams[t.stream]=!0,o.captions.push(t);for(i=0;i<this.pendingMetadata.length;i++)n=this.pendingMetadata[i],n.cueTime=n.pts-s,n.cueTime/=9e4,o.metadata.push(n);o.metadata.dispatchType=this.metadataStream.dispatchType,this.pendingTracks.length=0,this.videoTrack=null,this.pendingBoxes.length=0,this.pendingCaptions.length=0,this.pendingBytes=0,this.pendingMetadata.length=0,this.trigger("data",o),this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},a=function(e){var t,n,s=this,l=!0;a.prototype.init.call(this),e=e||{},this.baseMediaDecodeTime=e.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var t={};this.transmuxPipeline_=t,t.type="aac",t.metadataStream=new v.MetadataStream,t.aacStream=new _,t.audioTimestampRolloverStream=new v.TimestampRolloverStream("audio"),t.timedMetadataTimestampRolloverStream=new v.TimestampRolloverStream("timed-metadata"),t.adtsStream=new g,t.coalesceStream=new o(e,t.metadataStream),t.headOfPipeline=t.aacStream,t.aacStream.pipe(t.audioTimestampRolloverStream).pipe(t.adtsStream),t.aacStream.pipe(t.timedMetadataTimestampRolloverStream).pipe(t.metadataStream).pipe(t.coalesceStream),t.metadataStream.on("timestamp",function(e){t.aacStream.setTimestamp(e.timeStamp)}),t.aacStream.on("data",function(e){"timed-metadata"!==e.type||t.audioSegmentStream||(n=n||{timelineStartInfo:{baseMediaDecodeTime:s.baseMediaDecodeTime},codec:"adts",type:"audio"},t.coalesceStream.numberOfTracks++,t.audioSegmentStream=new i(n),t.adtsStream.pipe(t.audioSegmentStream).pipe(t.coalesceStream))}),t.coalesceStream.on("data",this.trigger.bind(this,"data")),t.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setupTsPipeline=function(){var a={};this.transmuxPipeline_=a,a.type="ts",a.metadataStream=new v.MetadataStream,a.packetStream=new v.TransportPacketStream,a.parseStream=new v.TransportParseStream,a.elementaryStream=new v.ElementaryStream,a.videoTimestampRolloverStream=new v.TimestampRolloverStream("video"),a.audioTimestampRolloverStream=new v.TimestampRolloverStream("audio"),a.timedMetadataTimestampRolloverStream=new v.TimestampRolloverStream("timed-metadata"),a.adtsStream=new g,a.h264Stream=new y,a.captionStream=new v.CaptionStream,a.coalesceStream=new o(e,a.metadataStream),a.headOfPipeline=a.packetStream,a.packetStream.pipe(a.parseStream).pipe(a.elementaryStream),a.elementaryStream.pipe(a.videoTimestampRolloverStream).pipe(a.h264Stream),a.elementaryStream.pipe(a.audioTimestampRolloverStream).pipe(a.adtsStream),a.elementaryStream.pipe(a.timedMetadataTimestampRolloverStream).pipe(a.metadataStream).pipe(a.coalesceStream),a.h264Stream.pipe(a.captionStream).pipe(a.coalesceStream),a.elementaryStream.on("data",function(o){var u;if("metadata"===o.type){for(u=o.tracks.length;u--;)t||"video"!==o.tracks[u].type?n||"audio"!==o.tracks[u].type||(n=o.tracks[u],n.timelineStartInfo.baseMediaDecodeTime=s.baseMediaDecodeTime):(t=o.tracks[u],t.timelineStartInfo.baseMediaDecodeTime=s.baseMediaDecodeTime);t&&!a.videoSegmentStream&&(a.coalesceStream.numberOfTracks++,a.videoSegmentStream=new r(t,e),a.videoSegmentStream.on("timelineStartInfo",function(e){n&&(n.timelineStartInfo=e,a.audioSegmentStream.setEarliestDts(e.dts))}),a.videoSegmentStream.on("processedGopsInfo",s.trigger.bind(s,"gopInfo")),a.videoSegmentStream.on("baseMediaDecodeTime",function(e){n&&a.audioSegmentStream.setVideoBaseMediaDecodeTime(e)}),a.h264Stream.pipe(a.videoSegmentStream).pipe(a.coalesceStream)),n&&!a.audioSegmentStream&&(a.coalesceStream.numberOfTracks++,a.audioSegmentStream=new i(n),a.adtsStream.pipe(a.audioSegmentStream).pipe(a.coalesceStream))}}),a.coalesceStream.on("data",this.trigger.bind(this,"data")),a.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setBaseMediaDecodeTime=function(e){var r=this.transmuxPipeline_;this.baseMediaDecodeTime=e,n&&(n.timelineStartInfo.dts=void 0,n.timelineStartInfo.pts=void 0,c(n),n.timelineStartInfo.baseMediaDecodeTime=e,r.audioTimestampRolloverStream&&r.audioTimestampRolloverStream.discontinuity()),t&&(r.videoSegmentStream&&(r.videoSegmentStream.gopCache_=[],r.videoTimestampRolloverStream.discontinuity()),t.timelineStartInfo.dts=void 0,t.timelineStartInfo.pts=void 0,c(t),r.captionStream.reset(),t.timelineStartInfo.baseMediaDecodeTime=e),r.timedMetadataTimestampRolloverStream&&r.timedMetadataTimestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(e){n&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(e)},this.alignGopsWith=function(e){t&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(e)},this.push=function(e){if(l){var t=u(e);t&&"aac"!==this.transmuxPipeline_.type?this.setupAacPipeline():t||"ts"===this.transmuxPipeline_.type||this.setupTsPipeline(),l=!1}this.transmuxPipeline_.headOfPipeline.push(e)},this.flush=function(){l=!0,this.transmuxPipeline_.headOfPipeline.flush()},this.resetCaptions=function(){this.transmuxPipeline_.captionStream&&this.transmuxPipeline_.captionStream.reset()}},a.prototype=new p,t.exports={Transmuxer:a,VideoSegmentStream:r,AudioSegmentStream:i,AUDIO_PROPERTIES:S,VIDEO_PROPERTIES:w}},{"../aac":38,"../codecs/adts.js":40,"../codecs/h264":41,"../data/silence":42,"../m2ts/m2ts.js":50,"../utils/clock":60,"../utils/stream.js":62,"./mp4-generator.js":56}],59:[function(e,t,n){"use strict";var r=e("../m2ts/stream-types.js"),i=e("../m2ts/timestamp-rollover-stream.js").handleRollover,a={};a.ts=e("../m2ts/probe.js"),a.aac=e("../aac/probe.js");var o=function(e){return e[0]==="I".charCodeAt(0)&&e[1]==="D".charCodeAt(0)&&e[2]==="3".charCodeAt(0)},s=function(e,t){for(var n,r=0,i=188;i<e.byteLength;)if(71!==e[r]||71!==e[i])r++,i++;else{switch(n=e.subarray(r,i),a.ts.parseType(n,t.pid)){case"pat":t.pid||(t.pid=a.ts.parsePat(n));break;case"pmt":t.table||(t.table=a.ts.parsePmt(n))}if(t.pid&&t.table)return;r+=188,i+=188}},u=function(e,t,n){for(var r,i,o,s,u=0,l=188,c=!1;l<e.byteLength;)if(71!==e[u]||71!==e[l])u++,l++;else{switch(r=e.subarray(u,l),a.ts.parseType(r,t.pid)){case"pes":i=a.ts.parsePesType(r,t.table),o=a.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&o&&(s=a.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),c=!0)}if(c)break;u+=188,l+=188}for(l=e.byteLength,u=l-188,c=!1;u>=0;)if(71!==e[u]||71!==e[l])u--,l--;else{switch(r=e.subarray(u,l),a.ts.parseType(r,t.pid)){case"pes":i=a.ts.parsePesType(r,t.table),o=a.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&o&&(s=a.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),c=!0)}if(c)break;u-=188,l-=188}},l=function(e,t,n){for(var r,i,o,s,u,l,c,d=0,f=188,h=!1,p={data:[],size:0};f<e.byteLength;)if(71!==e[d]||71!==e[f])d++,f++;else{switch(r=e.subarray(d,f),a.ts.parseType(r,t.pid)){case"pes":if(i=a.ts.parsePesType(r,t.table),o=a.ts.parsePayloadUnitStartIndicator(r),"video"===i&&(o&&!h&&(s=a.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),h=!0),!n.firstKeyFrame)){if(o&&0!==p.size){for(u=new Uint8Array(p.size),l=0;p.data.length;)c=p.data.shift(),u.set(c,l),l+=c.byteLength;a.ts.videoPacketContainsKeyFrame(u)&&(n.firstKeyFrame=a.ts.parsePesTime(u),n.firstKeyFrame.type="video"),p.size=0}p.data.push(r),p.size+=r.byteLength}}if(h&&n.firstKeyFrame)break;d+=188,f+=188}for(f=e.byteLength,d=f-188,h=!1;d>=0;)if(71!==e[d]||71!==e[f])d--,f--;else{switch(r=e.subarray(d,f),a.ts.parseType(r,t.pid)){case"pes":i=a.ts.parsePesType(r,t.table),o=a.ts.parsePayloadUnitStartIndicator(r),"video"===i&&o&&(s=a.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),h=!0)}if(h)break;d-=188,f-=188}},c=function(e,t){if(e.audio&&e.audio.length){var n=t;void 0===n&&(n=e.audio[0].dts),e.audio.forEach(function(e){e.dts=i(e.dts,n),e.pts=i(e.pts,n),e.dtsTime=e.dts/9e4,e.ptsTime=e.pts/9e4})}if(e.video&&e.video.length){var r=t;if(void 0===r&&(r=e.video[0].dts),e.video.forEach(function(e){e.dts=i(e.dts,r),e.pts=i(e.pts,r),e.dtsTime=e.dts/9e4,e.ptsTime=e.pts/9e4}),e.firstKeyFrame){var a=e.firstKeyFrame;a.dts=i(a.dts,r),a.pts=i(a.pts,r),a.dtsTime=a.dts/9e4,a.ptsTime=a.dts/9e4}}},d=function(e){for(var t,n=!1,r=0,i=null,o=null,s=0,u=0;e.length-u>=3;){switch(a.aac.parseType(e,u)){case"timed-metadata":if(e.length-u<10){n=!0;break}if((s=a.aac.parseId3TagSize(e,u))>e.length){n=!0;break}null===o&&(t=e.subarray(u,u+s),o=a.aac.parseAacTimestamp(t)),u+=s;break;case"audio":if(e.length-u<7){n=!0;break}if((s=a.aac.parseAdtsSize(e,u))>e.length){n=!0;break}null===i&&(t=e.subarray(u,u+s),i=a.aac.parseSampleRate(t)),r++,u+=s;break;default:u++}if(n)return null}if(null===i||null===o)return null;var l=9e4/i;return{audio:[{type:"audio",dts:o,pts:o},{type:"audio",dts:o+1024*r*l,pts:o+1024*r*l}]}},f=function(e){var t={pid:null,table:null},n={};s(e,t);for(var i in t.table)if(t.table.hasOwnProperty(i)){var a=t.table[i];switch(a){case r.H264_STREAM_TYPE:n.video=[],l(e,t,n),0===n.video.length&&delete n.video;break;case r.ADTS_STREAM_TYPE:n.audio=[],u(e,t,n),0===n.audio.length&&delete n.audio}}return n},h=function(e,t){var n;return(n=o(e)?d(e):f(e))&&(n.audio||n.video)?(c(n,t),n):null};t.exports={inspect:h}},{"../aac/probe.js":39,"../m2ts/probe.js":52,"../m2ts/stream-types.js":53,"../m2ts/timestamp-rollover-stream.js":54}],60:[function(e,t,n){var r,i,a,o,s,u;r=function(e){return 9e4*e},i=function(e,t){return e*t},a=function(e){return e/9e4},o=function(e,t){return e/t},s=function(e,t){return r(o(e,t))},u=function(e,t){return i(a(e),t)},t.exports={secondsToVideoTs:r,secondsToAudioTs:i,videoTsToSeconds:a,audioTsToSeconds:o,audioTsToVideoTs:s,videoTsToAudioTs:u}},{}],61:[function(e,t,n){"use strict";var r;r=function(e){var t=e.byteLength,n=0,r=0;this.length=function(){return 8*t},this.bitsAvailable=function(){return 8*t+r},this.loadWord=function(){var i=e.byteLength-t,a=new Uint8Array(4),o=Math.min(4,t);if(0===o)throw new Error("no bytes available");a.set(e.subarray(i,i+o)),n=new DataView(a.buffer).getUint32(0),r=8*o,t-=o},this.skipBits=function(e){var i;r>e?(n<<=e,r-=e):(e-=r,i=Math.floor(e/8),e-=8*i,t-=i,this.loadWord(),n<<=e,r-=e)},this.readBits=function(e){var i=Math.min(r,e),a=n>>>32-i;return r-=i,r>0?n<<=i:t>0&&this.loadWord(),i=e-i,i>0?a<<i|this.readBits(i):a},this.skipLeadingZeros=function(){var e;for(e=0;e<r;++e)if(0!=(n&2147483648>>>e))return n<<=e,r-=e,e;return this.loadWord(),e+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var e=this.skipLeadingZeros();return this.readBits(e+1)-1},this.readExpGolomb=function(){var e=this.readUnsignedExpGolomb();return 1&e?1+e>>>1:-1*(e>>>1)},this.readBoolean=function(){return 1===this.readBits(1)},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()},t.exports=r},{}],62:[function(e,t,n){"use strict";var r=function(){this.init=function(){var e={};this.on=function(t,n){e[t]||(e[t]=[]),e[t]=e[t].concat(n)},this.off=function(t,n){var r;return!!e[t]&&(r=e[t].indexOf(n),e[t]=e[t].slice(),e[t].splice(r,1),r>-1)},this.trigger=function(t){var n,r,i,a;if(n=e[t])if(2===arguments.length)for(i=n.length,r=0;r<i;++r)n[r].call(this,arguments[1]);else{for(a=[],r=arguments.length,r=1;r<arguments.length;++r)a.push(arguments[r]);for(i=n.length,r=0;r<i;++r)n[r].apply(this,a)}},this.dispose=function(){e={}}}};r.prototype.pipe=function(e){return this.on("data",function(t){e.push(t)}),this.on("done",function(t){e.flush(t)}),e},r.prototype.push=function(e){this.trigger("data",e)},r.prototype.flush=function(e){this.trigger("done",e)},t.exports=r},{}],63:[function(t,n,r){!function(t){var i=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/\;?#]*)?(.*?)??(;.*?)?(\?.*?)?(#.*?)?$/,a=/^([^\/;?#]*)(.*)$/,o=/(?:\/|^)\.(?=\/)/g,s=/(?:\/|^)\.\.\/(?!\.\.\/).*?(?=\/)/g,u={buildAbsoluteURL:function(e,t,n){if(n=n||{},e=e.trim(),!(t=t.trim())){if(!n.alwaysNormalize)return e;var r=this.parseURL(e);if(!r)throw new Error("Error trying to parse base URL.");return r.path=u.normalizePath(r.path),u.buildURLFromParts(r)}var i=this.parseURL(t);if(!i)throw new Error("Error trying to parse relative URL.");if(i.scheme)return n.alwaysNormalize?(i.path=u.normalizePath(i.path),u.buildURLFromParts(i)):t;var o=this.parseURL(e);if(!o)throw new Error("Error trying to parse base URL.");if(!o.netLoc&&o.path&&"/"!==o.path[0]){var s=a.exec(o.path);o.netLoc=s[1],o.path=s[2]}o.netLoc&&!o.path&&(o.path="/");var l={scheme:o.scheme,netLoc:i.netLoc,path:null,params:i.params,query:i.query,fragment:i.fragment};if(!i.netLoc&&(l.netLoc=o.netLoc,"/"!==i.path[0]))if(i.path){var c=o.path,d=c.substring(0,c.lastIndexOf("/")+1)+i.path;l.path=u.normalizePath(d)}else l.path=o.path,i.params||(l.params=o.params,i.query||(l.query=o.query));return null===l.path&&(l.path=n.alwaysNormalize?u.normalizePath(i.path):i.path),u.buildURLFromParts(l)},parseURL:function(e){var t=i.exec(e);return t?{scheme:t[1]||"",netLoc:t[2]||"",path:t[3]||"",params:t[4]||"",query:t[5]||"",fragment:t[6]||""}:null},normalizePath:function(e){for(e=e.split("").reverse().join("").replace(o,"");e.length!==(e=e.replace(s,"")).length;);return e.split("").reverse().join("")},buildURLFromParts:function(e){return e.scheme+e.netLoc+e.path+e.params+e.query+e.fragment}};"object"==typeof r&&"object"==typeof n?n.exports=u:"function"==typeof e&&e.amd?e([],function(){return u}):"object"==typeof r?r.URLToolkit=u:t.URLToolkit=u}(this)},{}],64:[function(e,t,n){(function(r){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var a=e("global/window"),o=i(a),s="undefined"!=typeof window?window.videojs:void 0!==r?r.videojs:null,u=i(s),l=function(e){Object.defineProperties(e.frame,{id:{get:function(){return u.default.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),e.value.key}},value:{get:function(){return u.default.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),e.value.data}},privateData:{get:function(){return u.default.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),e.value.data}}})},c=function(e){return isNaN(e)||Math.abs(e)===1/0?Number.MAX_VALUE:e},d=function(e,t,n){var r=o.default.WebKitDataCue||o.default.VTTCue;t&&t.forEach(function(e){var t=e.stream;this.inbandTextTracks_[t].addCue(new r(e.startTime+this.timestampOffset,e.endTime+this.timestampOffset,e.text))},e),n&&function(){var t=c(e.mediaSource_.duration);n.forEach(function(e){var t=e.cueTime+this.timestampOffset;e.frames.forEach(function(e){var n=new r(t,t,e.value||e.url||e.data||"");n.frame=e,n.value=e,l(n),this.metadataTrack_.addCue(n)},this)},e),e.metadataTrack_&&e.metadataTrack_.cues&&e.metadataTrack_.cues.length&&function(){for(var n=e.metadataTrack_.cues,r=[],i=0;i<n.length;i++)n[i]&&r.push(n[i]);var a=r.reduce(function(e,t){var n=e[t.startTime]||[];return n.push(t),e[t.startTime]=n,e},{}),o=Object.keys(a).sort(function(e,t){return Number(e)-Number(t)});o.forEach(function(e,n){var r=a[e],i=Number(o[n+1])||t;r.forEach(function(e){e.endTime=i})})}()}()};n.default={addTextTrackData:d,durationOfVideo:c},t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"global/window":32}],65:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(e){return/mp4a\.\d+.\d+/i.test(e)},i=function(e){return/avc1\.[\da-f]+/i.test(e)},a=function(e){var t={type:"",parameters:{}},n=e.trim().split(";");return t.type=n.shift().trim(),n.forEach(function(e){var n=e.trim().split("=");if(n.length>1){var r=n[0].replace(/"/g,"").trim(),i=n[1].replace(/"/g,"").trim();t.parameters[r]=i}}),t},o=function(e){return e.map(function(e){return e.replace(/avc1\.(\d+)\.(\d+)/i,function(e,t,n){return"avc1."+("00"+Number(t).toString(16)).slice(-2)+"00"+("00"+Number(n).toString(16)).slice(-2)})})};n.default={isAudioCodec:r,parseContentType:a,isVideoCodec:i,translateLegacyCodecs:o},t.exports=n.default},{}],66:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(e,t,n){var r=t.player_;if(n.captions&&n.captions.length){e.inbandTextTracks_||(e.inbandTextTracks_={});for(var i in n.captionStreams)if(!e.inbandTextTracks_[i]){r.tech_.trigger({type:"usage",name:"hls-608"});var a=r.textTracks().getTrackById(i);e.inbandTextTracks_[i]=a||r.addRemoteTextTrack({kind:"captions",id:i,label:i},!1).track}}n.metadata&&n.metadata.length&&!e.metadataTrack_&&(e.metadataTrack_=r.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,e.metadataTrack_.inBandMetadataTrackDispatchType=n.metadata.dispatchType)};n.default=r,t.exports=n.default},{}],67:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={TIME_BETWEEN_CHUNKS:1,BYTES_PER_CHUNK:32768};n.default=r,t.exports=n.default},{}],68:[function(e,t,n){(function(r){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},l=e("global/document"),c=i(l),d="undefined"!=typeof window?window.videojs:void 0!==r?r.videojs:null,f=i(d),h=e("./flash-source-buffer"),p=i(h),m=e("./flash-constants"),v=i(m),g=e("./codec-utils"),y=function(e){function t(){var e=this;a(this,t),u(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),this.sourceBuffers=[],this.readyState="closed",this.on(["sourceopen","webkitsourceopen"],function(t){e.swfObj=c.default.getElementById(t.swfId),e.player_=(0,f.default)(e.swfObj.parentNode),e.tech_=e.swfObj.tech,e.readyState="open",e.tech_.on("seeking",function(){for(var t=e.sourceBuffers.length;t--;)e.sourceBuffers[t].abort()}),e.swfObj&&e.swfObj.vjs_load()})}return o(t,e),s(t,[{key:"addSeekableRange_",value:function(){}},{key:"addSourceBuffer",value:function(e){var t=(0,g.parseContentType)(e),n=void 0;if("video/mp2t"!==t.type&&"audio/mp2t"!==t.type)throw new Error("NotSupportedError (Video.js)");return n=new p.default(this),this.sourceBuffers.push(n),n}},{key:"endOfStream",value:function(e){"network"===e?this.tech_.error(2):"decode"===e&&this.tech_.error(3),"ended"!==this.readyState&&(this.readyState="ended",this.swfObj.vjs_endOfStream())}}]),t}(f.default.EventTarget);n.default=y;try{Object.defineProperty(y.prototype,"duration",{get:function(){return this.swfObj?this.swfObj.vjs_getProperty("duration"):NaN},set:function(e){var t=void 0,n=this.swfObj.vjs_getProperty("duration");if(this.swfObj.vjs_setProperty("duration",e),e<n)for(t=0;t<this.sourceBuffers.length;t++)this.sourceBuffers[t].remove(e,n);return e}})}catch(e){y.prototype.duration=NaN}for(var _ in v.default)y[_]=v.default[_];t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./codec-utils":65,"./flash-constants":67,"./flash-source-buffer":69,"global/document":31}],69:[function(e,t,n){(function(r){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},l=e("global/window"),c=i(l),d="undefined"!=typeof window?window.videojs:void 0!==r?r.videojs:null,f=i(d),h=e("mux.js/lib/flv"),p=i(h),m=e("./remove-cues-from-track"),v=i(m),g=e("./create-text-tracks-if-necessary"),y=i(g),_=e("./add-text-track-data"),b=e("./flash-transmuxer-worker"),T=i(b),S=e("webwackify"),w=i(S),k=e("./flash-constants"),E=i(k),A=function(){var t=void 0;try{t=e.resolve("./flash-transmuxer-worker")}catch(e){}return t},C=function(e){c.default.setTimeout(e,E.default.TIME_BETWEEN_CHUNKS)},L=function(){return Math.random().toString(36).slice(2,8)},x=function(e,t){("number"!=typeof t||t<0)&&(t=0);var n=Math.pow(10,t);return Math.round(e*n)/n},j=function(e){function t(e){var n=this;a(this,t),u(Object.getPrototypeOf(t.prototype),"constructor",this).call(this);var r=void 0;this.chunkSize_=E.default.BYTES_PER_CHUNK,this.buffer_=[],this.bufferSize_=0,this.basePtsOffset_=NaN,this.mediaSource_=e,this.audioBufferEnd_=NaN,this.videoBufferEnd_=NaN,this.updating=!1,this.timestampOffset_=0,r=c.default.btoa(String.fromCharCode.apply(null,Array.prototype.slice.call(p.default.getFlvHeader())));var i=this.mediaSource_.player_.id().replace(/[^a-zA-Z0-9]/g,"_");this.flashEncodedHeaderName_="vjs_flashEncodedHeader_"+i+L(),this.flashEncodedDataName_="vjs_flashEncodedData_"+i+L(),c.default[this.flashEncodedHeaderName_]=function(){return delete c.default[n.flashEncodedHeaderName_],r},this.mediaSource_.swfObj.vjs_appendChunkReady(this.flashEncodedHeaderName_),this.transmuxer_=(0,w.default)(T.default,A()),this.transmuxer_.postMessage({action:"init",options:{}}),this.transmuxer_.onmessage=function(e){"data"===e.data.action&&n.receiveBuffer_(e.data.segment)},this.one("updateend",function(){n.mediaSource_.tech_.trigger("loadedmetadata")}),Object.defineProperty(this,"timestampOffset",{get:function(){return this.timestampOffset_},set:function(e){"number"==typeof e&&e>=0&&(this.timestampOffset_=e,this.mediaSource_.swfObj.vjs_discontinuity(),this.basePtsOffset_=NaN,this.audioBufferEnd_=NaN,this.videoBufferEnd_=NaN,this.transmuxer_.postMessage({action:"reset"}))}}),Object.defineProperty(this,"buffered",{get:function(){if(!(this.mediaSource_&&this.mediaSource_.swfObj&&"vjs_getProperty"in this.mediaSource_.swfObj))return f.default.createTimeRange();var e=this.mediaSource_.swfObj.vjs_getProperty("buffered");return e&&e.length&&(e[0][0]=x(e[0][0],3),e[0][1]=x(e[0][1],3)),f.default.createTimeRanges(e)}}),this.mediaSource_.player_.on("seeked",function(){if((0,v.default)(0,1/0,n.metadataTrack_),n.inbandTextTracks_)for(var e in n.inbandTextTracks_)(0,v.default)(0,1/0,n.inbandTextTracks_[e])});var o=this.onHlsReset_.bind(this);this.mediaSource_.player_.tech_.on("hls-reset",o),this.mediaSource_.player_.tech_.hls.on("dispose",function(){n.transmuxer_.terminate(),n.mediaSource_.player_.tech_.off("hls-reset",o)})}return o(t,e),s(t,[{key:"appendBuffer",value:function(e){var t=void 0;if(this.updating)throw t=new Error("SourceBuffer.append() cannot be called while an update is in progress"),t.name="InvalidStateError",t.code=11,t;this.updating=!0,this.mediaSource_.readyState="open",this.trigger({type:"update"}),this.transmuxer_.postMessage({action:"push",data:e.buffer,byteOffset:e.byteOffset,byteLength:e.byteLength},[e.buffer]),this.transmuxer_.postMessage({action:"flush"})}},{key:"abort",value:function(){this.buffer_=[],this.bufferSize_=0,this.mediaSource_.swfObj.vjs_abort(),this.updating&&(this.updating=!1,this.trigger({type:"updateend"}))}},{key:"remove",value:function(e,t){if((0,v.default)(e,t,this.metadataTrack_),this.inbandTextTracks_)for(var n in this.inbandTextTracks_)(0,v.default)(e,t,this.inbandTextTracks_[n]);this.trigger({type:"update"}),this.trigger({type:"updateend"})}},{key:"receiveBuffer_",value:function(e){var t=this;(0,y.default)(this,this.mediaSource_,e),(0,_.addTextTrackData)(this,e.captions,e.metadata),C(function(){var n=t.convertTagsToData_(e);0===t.buffer_.length&&C(t.processBuffer_.bind(t)),n&&(t.buffer_.push(n),t.bufferSize_+=n.byteLength)})}},{key:"processBuffer_",value:function(){var e=this,t=E.default.BYTES_PER_CHUNK;if(!this.buffer_.length)return void(!1!==this.updating&&(this.updating=!1,this.trigger({type:"updateend"})));var n=this.buffer_[0].subarray(0,t);n.byteLength<t||this.buffer_[0].byteLength===t?this.buffer_.shift():this.buffer_[0]=this.buffer_[0].subarray(t),this.bufferSize_-=n.byteLength;for(var r=[],i=n.byteLength,a=0;a<i;a++)r.push(String.fromCharCode(n[a]));var o=c.default.btoa(r.join(""));c.default[this.flashEncodedDataName_]=function(){return C(e.processBuffer_.bind(e)),delete c.default[e.flashEncodedDataName_],o},this.mediaSource_.swfObj.vjs_appendChunkReady(this.flashEncodedDataName_)}},{key:"convertTagsToData_",value:function(e){var t=0,n=this.mediaSource_.tech_,r=0,i=void 0,a=e.tags.videoTags,o=e.tags.audioTags;if(isNaN(this.basePtsOffset_)&&(a.length||o.length)){var s=a[0]||{pts:1/0},u=o[0]||{pts:1/0};this.basePtsOffset_=Math.min(u.pts,s.pts)}n.seeking()&&(this.videoBufferEnd_=NaN,this.audioBufferEnd_=NaN),isNaN(this.videoBufferEnd_)?(n.buffered().length&&(r=n.buffered().end(0)-this.timestampOffset),n.seeking()&&(r=Math.max(r,n.currentTime()-this.timestampOffset)),r*=1e3,r+=this.basePtsOffset_):r=this.videoBufferEnd_+.1;var l=a.length;if(l&&a[l-1].pts>=r){for(;--l;){var c=a[l];if(!(c.pts>r)&&(c.keyFrame||c.metaDataTag))break}for(;l&&a[l-1].metaDataTag;)l--}var d=a.slice(l),f=void 0;for(f=isNaN(this.audioBufferEnd_)?r:this.audioBufferEnd_+.1,d.length&&(f=Math.min(f,d[0].pts)),l=0;l<o.length&&!(o[l].pts>=f);)l++;var h=o.slice(l);h.length&&(this.audioBufferEnd_=h[h.length-1].pts),d.length&&(this.videoBufferEnd_=d[d.length-1].pts);var p=this.getOrderedTags_(d,h);if(0!==p.length){if(p[0].pts<r&&n.seeking()){var m=n.currentTime(),v=(r-p[0].pts)/1e3,g=m-v;g<1/30&&(g=0);try{this.mediaSource_.swfObj.vjs_adjustCurrentTime(g)}catch(e){}}for(var y=0;y<p.length;y++)t+=p[y].bytes.byteLength;i=new Uint8Array(t);for(var y=0,_=0;y<p.length;y++)i.set(p[y].bytes,_),_+=p[y].bytes.byteLength;return i}}},{key:"getOrderedTags_",value:function(e,t){for(var n=void 0,r=[];e.length||t.length;)n=e.length?t.length&&t[0].dts<e[0].dts?t.shift():e.shift():t.shift(),r.push(n);return r}},{key:"onHlsReset_",value:function(){this.transmuxer_.postMessage({action:"resetCaptions"})}}]),t}(f.default.EventTarget);n.default=j,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./add-text-track-data":64,"./create-text-tracks-if-necessary":66,"./flash-constants":67,"./flash-transmuxer-worker":70,"./remove-cues-from-track":72,"global/window":32,"mux.js/lib/flv":46,webwackify:76}],70:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("global/window"),s=r(o),u=e("mux.js/lib/flv"),l=r(u),c=function(e){e.on("data",function(e){s.default.postMessage({action:"data",segment:e})}),e.on("done",function(e){s.default.postMessage({action:"done"})})},d=function(){function e(t){i(this,e),this.options=t||{},this.init()}return a(e,[{key:"init",value:function(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new l.default.Transmuxer(this.options),c(this.transmuxer)}},{key:"push",value:function(e){var t=new Uint8Array(e.data,e.byteOffset,e.byteLength);this.transmuxer.push(t)}},{key:"reset",value:function(){this.init()}},{key:"flush",value:function(){this.transmuxer.flush()}},{key:"resetCaptions",value:function(){this.transmuxer.resetCaptions()}}]),e}(),f=function(e){e.onmessage=function(e){if("init"===e.data.action&&e.data.options)return void(this.messageHandlers=new d(e.data.options));this.messageHandlers||(this.messageHandlers=new d),e.data&&e.data.action&&"init"!==e.data.action&&this.messageHandlers[e.data.action]&&this.messageHandlers[e.data.action](e.data)}};n.default=function(e){return new f(e)},t.exports=n.default},{"global/window":32,"mux.js/lib/flv":46}],71:[function(e,t,n){(function(r){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},l=e("global/window"),c=i(l),d=e("global/document"),f=i(d),h="undefined"!=typeof window?window.videojs:void 0!==r?r.videojs:null,p=i(h),m=e("./virtual-source-buffer"),v=i(m),g=e("./add-text-track-data"),y=e("./codec-utils"),_=function(e){function t(){var e=this;a(this,t),u(Object.getPrototypeOf(t.prototype),"constructor",this).call(this);var n=void 0;this.nativeMediaSource_=new c.default.MediaSource;for(n in this.nativeMediaSource_)n in t.prototype||"function"!=typeof this.nativeMediaSource_[n]||(this[n]=this.nativeMediaSource_[n].bind(this.nativeMediaSource_));this.duration_=NaN,Object.defineProperty(this,"duration",{get:function(){return this.duration_===1/0?this.duration_:this.nativeMediaSource_.duration},set:function(e){if(this.duration_=e,e!==1/0)return void(this.nativeMediaSource_.duration=e)}}),Object.defineProperty(this,"seekable",{get:function(){return this.duration_===1/0?p.default.createTimeRanges([[0,this.nativeMediaSource_.duration]]):this.nativeMediaSource_.seekable}}),Object.defineProperty(this,"readyState",{get:function(){return this.nativeMediaSource_.readyState}}),Object.defineProperty(this,"activeSourceBuffers",{get:function(){return this.activeSourceBuffers_}}),this.sourceBuffers=[],this.activeSourceBuffers_=[],this.updateActiveSourceBuffers_=function(){if(e.activeSourceBuffers_.length=0,1===e.sourceBuffers.length){var t=e.sourceBuffers[0];return t.appendAudioInitSegment_=!0,t.audioDisabled_=!t.audioCodec_,void e.activeSourceBuffers_.push(t)}for(var n=!1,r=!0,i=0;i<e.player_.audioTracks().length;i++){var a=e.player_.audioTracks()[i];if(a.enabled&&"main"!==a.kind){n=!0,r=!1;break}}e.sourceBuffers.forEach(function(t){if(t.appendAudioInitSegment_=!0,t.videoCodec_&&t.audioCodec_)t.audioDisabled_=n;else if(t.videoCodec_&&!t.audioCodec_)t.audioDisabled_=!0,r=!1;else if(!t.videoCodec_&&t.audioCodec_&&(t.audioDisabled_=r,r))return;e.activeSourceBuffers_.push(t)})},this.onPlayerMediachange_=function(){e.sourceBuffers.forEach(function(e){e.appendAudioInitSegment_=!0})},this.onHlsReset_=function(){e.sourceBuffers.forEach(function(e){e.transmuxer_&&e.transmuxer_.postMessage({action:"resetCaptions"})})},this.onHlsSegmentTimeMapping_=function(t){e.sourceBuffers.forEach(function(e){return e.timeMapping_=t.mapping})},["sourceopen","sourceclose","sourceended"].forEach(function(e){this.nativeMediaSource_.addEventListener(e,this.trigger.bind(this))},this),this.on("sourceopen",function(t){var n=f.default.querySelector('[src="'+e.url_+'"]');n&&(e.player_=(0,p.default)(n.parentNode),e.player_.tech_.on("hls-reset",e.onHlsReset_),e.player_.tech_.on("hls-segment-time-mapping",e.onHlsSegmentTimeMapping_),e.player_.audioTracks&&e.player_.audioTracks()&&(e.player_.audioTracks().on("change",e.updateActiveSourceBuffers_),e.player_.audioTracks().on("addtrack",e.updateActiveSourceBuffers_),e.player_.audioTracks().on("removetrack",e.updateActiveSourceBuffers_)),e.player_.on("mediachange",e.onPlayerMediachange_))}),this.on("sourceended",function(t){for(var n=(0,g.durationOfVideo)(e.duration),r=0;r<e.sourceBuffers.length;r++){var i=e.sourceBuffers[r],a=i.metadataTrack_&&i.metadataTrack_.cues;a&&a.length&&(a[a.length-1].endTime=n)}}),this.on("sourceclose",function(e){this.sourceBuffers.forEach(function(e){e.transmuxer_&&e.transmuxer_.terminate()}),this.sourceBuffers.length=0,this.player_&&(this.player_.audioTracks&&this.player_.audioTracks()&&(this.player_.audioTracks().off("change",this.updateActiveSourceBuffers_),this.player_.audioTracks().off("addtrack",this.updateActiveSourceBuffers_),this.player_.audioTracks().off("removetrack",this.updateActiveSourceBuffers_)),this.player_.el_&&(this.player_.off("mediachange",this.onPlayerMediachange_),this.player_.tech_.off("hls-reset",this.onHlsReset_),this.player_.tech_.off("hls-segment-time-mapping",this.onHlsSegmentTimeMapping_)))})}return o(t,e),s(t,[{key:"addSeekableRange_",value:function(e,t){var n=void 0;if(this.duration!==1/0)throw n=new Error("MediaSource.addSeekableRange() can only be invoked when the duration is Infinity"),n.name="InvalidStateError",n.code=11,n;(t>this.nativeMediaSource_.duration||isNaN(this.nativeMediaSource_.duration))&&(this.nativeMediaSource_.duration=t)}},{key:"addSourceBuffer",value:function(e){var t=void 0,n=(0,y.parseContentType)(e);if(/^(video|audio)\/mp2t$/i.test(n.type)){var r=[];n.parameters&&n.parameters.codecs&&(r=n.parameters.codecs.split(","),r=(0,y.translateLegacyCodecs)(r),r=r.filter(function(e){return(0,y.isAudioCodec)(e)||(0,y.isVideoCodec)(e)})),0===r.length&&(r=["avc1.4d400d","mp4a.40.2"]),t=new v.default(this,r),0!==this.sourceBuffers.length&&(this.sourceBuffers[0].createRealSourceBuffers_(),t.createRealSourceBuffers_(),this.sourceBuffers[0].audioDisabled_=!0)}else t=this.nativeMediaSource_.addSourceBuffer(e);return this.sourceBuffers.push(t),t}}]),t}(p.default.EventTarget);n.default=_,t.exports=n.default}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./add-text-track-data":64,"./codec-utils":65,"./virtual-source-buffer":75,"global/document":31,"global/window":32}],72:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=function(e,t,n){var r=void 0,i=void 0;if(n&&n.cues)for(r=n.cues.length;r--;)i=n.cues[r],i.startTime<=t&&i.endTime>=e&&n.removeCue(i)};n.default=r,t.exports=n.default},{}],73:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=e("global/window"),s=r(o),u=e("mux.js/lib/mp4"),l=r(u),c=function(e){e.on("data",function(e){var t=e.initSegment;e.initSegment={data:t.buffer,byteOffset:t.byteOffset,byteLength:t.byteLength};var n=e.data;e.data=n.buffer,s.default.postMessage({action:"data",segment:e,byteOffset:n.byteOffset,byteLength:n.byteLength},[e.data])}),e.captionStream&&e.captionStream.on("data",function(e){s.default.postMessage({action:"caption",data:e})}),e.on("done",function(e){s.default.postMessage({action:"done"})}),e.on("gopInfo",function(e){s.default.postMessage({action:"gopInfo",gopInfo:e})})},d=function(){function e(t){i(this,e),this.options=t||{},this.init()}return a(e,[{key:"init",value:function(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new l.default.Transmuxer(this.options),c(this.transmuxer)}},{key:"push",value:function(e){var t=new Uint8Array(e.data,e.byteOffset,e.byteLength);this.transmuxer.push(t)}},{key:"reset",value:function(){this.init()}},{key:"setTimestampOffset",value:function(e){var t=e.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(9e4*t))}},{key:"setAudioAppendStart",value:function(e){this.transmuxer.setAudioAppendStart(Math.ceil(9e4*e.appendStart))}},{key:"flush",value:function(e){this.transmuxer.flush()}},{key:"resetCaptions",value:function(){this.transmuxer.resetCaptions()}},{key:"alignGopsWith",value:function(e){this.transmuxer.alignGopsWith(e.gopsToAlignWith.slice())}}]),e}(),f=function(e){e.onmessage=function(e){if("init"===e.data.action&&e.data.options)return void(this.messageHandlers=new d(e.data.options));this.messageHandlers||(this.messageHandlers=new d),e.data&&e.data.action&&"init"!==e.data.action&&this.messageHandlers[e.data.action]&&this.messageHandlers[e.data.action](e.data)}};n.default=function(e){return new f(e)},t.exports=n.default},{"global/window":32,"mux.js/lib/mp4":55}],74:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("global/window"),a=r(i),o=e("./flash-media-source"),s=r(o),u=e("./html-media-source"),l=r(u),c="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,d=r(c),f=0,h={mode:"auto"};d.default.mediaSources={};var p=function(e,t){var n=d.default.mediaSources[e];if(!n)throw new Error("Media Source not found (Video.js)");n.trigger({type:"sourceopen",swfId:t})},m=function(){return!!a.default.MediaSource&&!!a.default.MediaSource.isTypeSupported&&a.default.MediaSource.isTypeSupported('video/mp4;codecs="avc1.4d400d,mp4a.40.2"')},v=function(e){var t=d.default.mergeOptions(h,e);if(this.MediaSource={open:p,supportsNativeMediaSources:m},"html5"===t.mode||"auto"===t.mode&&m())return new l.default;if(d.default.getTech("Flash"))return new s.default;throw new Error("Cannot use Flash or Html5 to create a MediaSource for this video")};n.MediaSource=v,v.open=p,v.supportsNativeMediaSources=m;var g={createObjectURL:function(e){var t=void 0;return e instanceof l.default?(t=a.default.URL.createObjectURL(e.nativeMediaSource_),e.url_=t,t):e instanceof s.default?(t="blob:vjs-media-source/"+f,f++,d.default.mediaSources[t]=e,t):(t=a.default.URL.createObjectURL(e),e.url_=t,t)}};n.URL=g,d.default.MediaSource=v,d.default.URL=g}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./flash-media-source":68,"./html-media-source":71,"global/window":32}],75:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},u="undefined"!=typeof window?window.videojs:void 0!==t?t.videojs:null,l=r(u),c=e("./create-text-tracks-if-necessary"),d=r(c),f=e("./remove-cues-from-track"),h=r(f),p=e("./add-text-track-data"),m=e("webwackify"),v=r(m),g=e("./transmuxer-worker"),y=r(g),_=e("./codec-utils"),b=function(){var t=void 0;try{t=e.resolve("./transmuxer-worker")}catch(e){}return t},T=function(e,t){var n=e.addSourceBuffer(t),r=Object.create(null);r.updating=!1,r.realBuffer_=n;for(var i in n)!function(e){"function"==typeof n[e]?r[e]=function(){return n[e].apply(n,arguments)}:void 0===r[e]&&Object.defineProperty(r,e,{get:function(){return n[e]},set:function(t){return n[e]=t}})}(i);return r},S=function(e,t,n){if(!t||!e.length)return[];var r=Math.ceil(9e4*(t.currentTime()-n+3)),i=void 0;for(i=0;i<e.length&&!(e[i].pts>r);i++);return e.slice(i)};n.gopsSafeToAlignWith=S;var w=function(e,t,n){if(!t.length)return e;if(n)return t.slice();var r=t[0].pts,i=0;for(i;i<e.length&&!(e[i].pts>=r);i++);return e.slice(0,i).concat(t)};n.updateGopBuffer=w;var k=function(e,t,n,r){for(var i=Math.ceil(9e4*(t-r)),a=Math.ceil(9e4*(n-r)),o=e.slice(),s=e.length;s--&&!(e[s].pts<=a););if(-1===s)return o;for(var u=s+1;u--&&!(e[u].pts<=i););return u=Math.max(u,0),o.splice(u,s-u+1),o};n.removeGopBuffer=k;var E=function(e){function t(e,n){var r=this;i(this,t),s(Object.getPrototypeOf(t.prototype),"constructor",this).call(this,l.default.EventTarget),this.timestampOffset_=0,this.pendingBuffers_=[],this.bufferUpdating_=!1,this.mediaSource_=e,this.codecs_=n,this.audioCodec_=null,this.videoCodec_=null,this.audioDisabled_=!1,this.appendAudioInitSegment_=!0,this.gopBuffer_=[],this.timeMapping_=0,this.safeAppend_=l.default.browser.IE_VERSION>=11;var a={remux:!1,alignGopsAtEnd:this.safeAppend_};this.codecs_.forEach(function(e){(0,_.isAudioCodec)(e)?r.audioCodec_=e:(0,_.isVideoCodec)(e)&&(r.videoCodec_=e)}),this.transmuxer_=(0,v.default)(y.default,b()),this.transmuxer_.postMessage({action:"init",options:a}),this.transmuxer_.onmessage=function(e){return"data"===e.data.action?r.data_(e):"done"===e.data.action?r.done_(e):"gopInfo"===e.data.action?r.appendGopInfo_(e):void 0},Object.defineProperty(this,"timestampOffset",{get:function(){return this.timestampOffset_},set:function(e){"number"==typeof e&&e>=0&&(this.timestampOffset_=e,this.appendAudioInitSegment_=!0,this.gopBuffer_.length=0,this.timeMapping_=0,this.transmuxer_.postMessage({action:"setTimestampOffset",timestampOffset:e}))}}),Object.defineProperty(this,"appendWindowStart",{get:function(){return(this.videoBuffer_||this.audioBuffer_).appendWindowStart},set:function(e){this.videoBuffer_&&(this.videoBuffer_.appendWindowStart=e),this.audioBuffer_&&(this.audioBuffer_.appendWindowStart=e)}}),Object.defineProperty(this,"updating",{get:function(){return!!(this.bufferUpdating_||!this.audioDisabled_&&this.audioBuffer_&&this.audioBuffer_.updating||this.videoBuffer_&&this.videoBuffer_.updating)}}),Object.defineProperty(this,"buffered",{get:function(){var e=null,t=null,n=0,r=[],i=[];if(!this.videoBuffer_&&!this.audioBuffer_)return l.default.createTimeRange();if(!this.videoBuffer_)return this.audioBuffer_.buffered;if(!this.audioBuffer_)return this.videoBuffer_.buffered;if(this.audioDisabled_)return this.videoBuffer_.buffered;if(0===this.videoBuffer_.buffered.length&&0===this.audioBuffer_.buffered.length)return l.default.createTimeRange();for(var a=this.videoBuffer_.buffered,o=this.audioBuffer_.buffered,s=a.length;s--;)r.push({time:a.start(s),type:"start"}),r.push({time:a.end(s),type:"end"});for(s=o.length;s--;)r.push({time:o.start(s),type:"start"}),r.push({time:o.end(s),type:"end"});for(r.sort(function(e,t){return e.time-t.time}),s=0;s<r.length;s++)"start"===r[s].type?2==++n&&(e=r[s].time):"end"===r[s].type&&1==--n&&(t=r[s].time),null!==e&&null!==t&&(i.push([e,t]),e=null,t=null);return l.default.createTimeRanges(i)}})}return a(t,e),o(t,[{key:"data_",value:function(e){var t=e.data.segment;t.data=new Uint8Array(t.data,e.data.byteOffset,e.data.byteLength),t.initSegment=new Uint8Array(t.initSegment.data,t.initSegment.byteOffset,t.initSegment.byteLength),(0,d.default)(this,this.mediaSource_,t),this.pendingBuffers_.push(t)}},{key:"done_",value:function(e){if("closed"===this.mediaSource_.readyState)return void(this.pendingBuffers_.length=0);this.processPendingSegments_()}},{key:"createRealSourceBuffers_",value:function(){var e=this,t=["audio","video"];t.forEach(function(n){if(e[n+"Codec_"]&&!e[n+"Buffer_"]){var r=null;if(e.mediaSource_[n+"Buffer_"])r=e.mediaSource_[n+"Buffer_"],r.updating=!1;else{var i=n+"Codec_",a=n+'/mp4;codecs="'+e[i]+'"';r=T(e.mediaSource_.nativeMediaSource_,a),e.mediaSource_[n+"Buffer_"]=r}e[n+"Buffer_"]=r,["update","updatestart","updateend"].forEach(function(i){r.addEventListener(i,function(){if("audio"!==n||!e.audioDisabled_)return"updateend"===i&&(e[n+"Buffer_"].updating=!1),t.every(function(t){return!("audio"!==t||!e.audioDisabled_)||n===t||!e[t+"Buffer_"]||!e[t+"Buffer_"].updating})?e.trigger(i):void 0})})}})}},{key:"appendBuffer",value:function(e){if(this.bufferUpdating_=!0,this.audioBuffer_&&this.audioBuffer_.buffered.length){var t=this.audioBuffer_.buffered;this.transmuxer_.postMessage({action:"setAudioAppendStart",appendStart:t.end(t.length-1)})}this.videoBuffer_&&this.transmuxer_.postMessage({action:"alignGopsWith",gopsToAlignWith:S(this.gopBuffer_,this.mediaSource_.player_,this.timeMapping_)}),this.transmuxer_.postMessage({action:"push",data:e.buffer,byteOffset:e.byteOffset,byteLength:e.byteLength},[e.buffer]),this.transmuxer_.postMessage({action:"flush"})}},{key:"appendGopInfo_",value:function(e){this.gopBuffer_=w(this.gopBuffer_,e.data.gopInfo,this.safeAppend_)}},{key:"remove",value:function(e,t){if(this.videoBuffer_&&(this.videoBuffer_.updating=!0,this.videoBuffer_.remove(e,t),this.gopBuffer_=k(this.gopBuffer_,e,t,this.timeMapping_)),!this.audioDisabled_&&this.audioBuffer_&&(this.audioBuffer_.updating=!0,this.audioBuffer_.remove(e,t)),(0,h.default)(e,t,this.metadataTrack_),this.inbandTextTracks_)for(var n in this.inbandTextTracks_)(0,h.default)(e,t,this.inbandTextTracks_[n])}},{key:"processPendingSegments_",value:function(){var e={video:{segments:[],bytes:0},audio:{segments:[],bytes:0},captions:[],metadata:[]};e=this.pendingBuffers_.reduce(function(e,t){var n=t.type,r=t.data,i=t.initSegment;return e[n].segments.push(r),e[n].bytes+=r.byteLength,e[n].initSegment=i,t.captions&&(e.captions=e.captions.concat(t.captions)),t.info&&(e[n].info=t.info),t.metadata&&(e.metadata=e.metadata.concat(t.metadata)),e},e),this.videoBuffer_||this.audioBuffer_||(0===e.video.bytes&&(this.videoCodec_=null),0===e.audio.bytes&&(this.audioCodec_=null),this.createRealSourceBuffers_()),e.audio.info&&this.mediaSource_.trigger({type:"audioinfo",info:e.audio.info}),e.video.info&&this.mediaSource_.trigger({type:"videoinfo",info:e.video.info}),this.appendAudioInitSegment_&&(!this.audioDisabled_&&this.audioBuffer_&&(e.audio.segments.unshift(e.audio.initSegment),e.audio.bytes+=e.audio.initSegment.byteLength),this.appendAudioInitSegment_=!1);var t=!1;this.videoBuffer_&&e.video.bytes?(e.video.segments.unshift(e.video.initSegment),e.video.bytes+=e.video.initSegment.byteLength,this.concatAndAppendSegments_(e.video,this.videoBuffer_),(0,p.addTextTrackData)(this,e.captions,e.metadata)):!this.videoBuffer_||!this.audioDisabled_&&this.audioBuffer_||(t=!0),!this.audioDisabled_&&this.audioBuffer_&&this.concatAndAppendSegments_(e.audio,this.audioBuffer_),this.pendingBuffers_.length=0,t&&this.trigger("updateend"),this.bufferUpdating_=!1}},{key:"concatAndAppendSegments_",value:function(e,t){var n=0,r=void 0;if(e.bytes){r=new Uint8Array(e.bytes),e.segments.forEach(function(e){r.set(e,n),n+=e.byteLength});try{t.updating=!0,t.appendBuffer(r)}catch(e){this.mediaSource_.player_&&this.mediaSource_.player_.error({code:-3,type:"APPEND_BUFFER_ERR",message:e.message,originalError:e})}}}},{key:"abort",value:function(){this.videoBuffer_&&this.videoBuffer_.abort(),!this.audioDisabled_&&this.audioBuffer_&&this.audioBuffer_.abort(),this.transmuxer_&&this.transmuxer_.postMessage({action:"reset"}),this.pendingBuffers_.length=0,this.bufferUpdating_=!1}}]),t}(l.default.EventTarget);n.default=E}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./add-text-track-data":64,"./codec-utils":65,"./create-text-tracks-if-necessary":66,"./remove-cues-from-track":72,"./transmuxer-worker":73,webwackify:76}],76:[function(e,t,n){var r=arguments[3],i=arguments[4],a=arguments[5],o=JSON.stringify,s=!1,u=function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=entryModule)};void 0===r&&(s=!0,r=u,i=__webpack_modules__);var l=function(e){for(var t,n=Object.keys(a),s=0;s<n.length;s++){var u=n[s],l=a[u].exports;if(l===e||l&&l.default===e){t=u;break}}if(!t){t=Math.floor(Math.pow(16,8)*Math.random()).toString(16);for(var c={},s=0;s<n.length;s++){var u=n[s];c[u]=u}i[t]=["function(require,module,exports){"+e+"(self); }",c]}var d=Math.floor(Math.pow(16,8)*Math.random()).toString(16),f={};return f[t]=t,i[d]=["function(require,module,exports){var f = require("+o(t)+");(f.default ? f.default : f)(self);}",f],"("+r+")({"+Object.keys(i).map(function(e){return o(e)+":["+i[e][0]+","+o(i[e][1])+"]"}).join(",")+"},{},["+o(d)+"])"},c=function(e,t){var n,a="string"==typeof t;n=a?{}:[],Object.keys(i).forEach(function(e){i[e]&&(n[e]=i[e].toString())});var s=__webpack_require__(t);if(!s||s!==e&&s.default!==e){var u=n[t];n[t]=u.substring(0,u.length-1)+"\n"+e.name+"();\n}"}var l;return a?(t=o(t),l="{"+Object.keys(n).map(function(e){return o(e)+":"+n[e]}).join(",")+"}"):l="["+n.join(",")+"]","var fn = ("+r.toString().replace("entryModule",t)+")("+l+');\n(typeof fn === "function") && fn(self);'};t.exports=function(e,t){var n;n=s?c(e,t):l(e);var r=new Blob([n],{type:"text/javascript"}),i=window.URL||window.webkitURL||window.mozURL||window.msURL,a=i.createObjectURL(r),o=new Worker(a);return o.objectURL=a,o}},{}],77:[function(e,t,n){(function(n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e,t,n){for(var r=!0;r;){var i=e,a=t,o=n;r=!1,null===i&&(i=Function.prototype);var s=Object.getOwnPropertyDescriptor(i,a);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(o)}var l=Object.getPrototypeOf(i);if(null===l)return;e=l,t=a,n=o,r=!0,s=l=void 0}},u=e("global/document"),l=r(u),c=e("./playlist-loader"),d=r(c),f=e("./playlist"),h=r(f),p=e("./xhr"),m=r(p),v=e("aes-decrypter"),g=e("./bin-utils"),y=r(g),_=e("videojs-contrib-media-sources"),b=e("m3u8-parser"),T=r(b),S="undefined"!=typeof window?window.videojs:void 0!==n?n.videojs:null,w=r(S),k=e("./master-playlist-controller"),E=e("./config"),A=r(E),C=e("./rendition-mixin"),L=r(C),x=e("global/window"),j=r(x),O=e("./playback-watcher"),I=r(O),P=e("./reload-source-on-error"),R=(r(P),e("./playlist-selectors.js")),D={PlaylistLoader:d.default,Playlist:h.default,Decrypter:v.Decrypter,AsyncStream:v.AsyncStream,decrypt:v.decrypt,utils:y.default,STANDARD_PLAYLIST_SELECTOR:R.lastBandwidthSelector,INITIAL_PLAYLIST_SELECTOR:R.lowestBitrateCompatibleVariantSelector,comparePlaylistBandwidth:R.comparePlaylistBandwidth,comparePlaylistResolution:R.comparePlaylistResolution,xhr:(0,m.default)()};["GOAL_BUFFER_LENGTH","MAX_GOAL_BUFFER_LENGTH","GOAL_BUFFER_LENGTH_RATE","BUFFER_LOW_WATER_LINE","MAX_BUFFER_LOW_WATER_LINE","BUFFER_LOW_WATER_LINE_RATE","BANDWIDTH_VARIANCE"].forEach(function(e){Object.defineProperty(D,e,{get:function(){return w.default.log.warn("using Hls."+e+" is UNSAFE be sure you know what you are doing"),A.default[e]},set:function(t){if(w.default.log.warn("using Hls."+e+" is UNSAFE be sure you know what you are doing"),"number"!=typeof t||t<0)return void w.default.log.warn("value of Hls."+e+" must be greater than or equal to 0");A.default[e]=t}})});var M=function(e,t){for(var n=t.media(),r=-1,i=0;i<e.length;i++)if(e[i].id===n.uri){r=i;break}e.selectedIndex_=r,e.trigger({selectedIndex:r,type:"change"})},U=function(e,t){t.representations().forEach(function(t){e.addQualityLevel(t)}),M(e,t.playlists)};D.canPlaySource=function(){return w.default.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")},D.supportsNativeHls=function(){var e=l.default.createElement("video");return!!w.default.getTech("Html5").isSupported()&&["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"].some(function(t){return/maybe|probably/i.test(e.canPlayType(t))})}(),D.isSupported=function(){return w.default.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var B=w.default.getComponent("Component"),N=function(e){function t(e,n,r){var a=this;if(i(this,t),s(Object.getPrototypeOf(t.prototype),"constructor",this).call(this,n,r.hls),n.options_&&n.options_.playerId){var o=(0,w.default)(n.options_.playerId);o.hasOwnProperty("hls")||Object.defineProperty(o,"hls",{get:function(){return w.default.log.warn("player.hls is deprecated. Use player.tech_.hls instead."),n.trigger({type:"usage",name:"hls-player-access"}),a}})}if(this.tech_=n,this.source_=e,this.stats={},this.ignoreNextSeekingEvent_=!1,this.setOptions_(),this.options_.overrideNative&&(n.featuresNativeVideoTracks||n.featuresNativeAudioTracks))throw new Error("Overriding native HLS requires emulated tracks. See https://git.io/vMpjB");this.on(l.default,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],function(e){var t=l.default.fullscreenElement||l.default.webkitFullscreenElement||l.default.mozFullScreenElement||l.default.msFullscreenElement;t&&t.contains(a.tech_.el())&&a.masterPlaylistController_.fastQualityChange_()}),this.on(this.tech_,"seeking",function(){if(this.ignoreNextSeekingEvent_)return void(this.ignoreNextSeekingEvent_=!1);this.setCurrentTime(this.tech_.currentTime())}),this.on(this.tech_,"error",function(){this.masterPlaylistController_&&this.masterPlaylistController_.pauseLoading()}),this.on(this.tech_,"play",this.play)}return a(t,e),o(t,[{key:"setOptions_",value:function(){var e=this;this.options_.withCredentials=this.options_.withCredentials||!1,"number"!=typeof this.options_.blacklistDuration&&(this.options_.blacklistDuration=300),"number"!=typeof this.options_.bandwidth&&(this.options_.bandwidth=4194304),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&4194304===this.options_.bandwidth,["withCredentials","bandwidth","handleManifestRedirects"].forEach(function(t){void 0!==e.source_[t]&&(e.options_[t]=e.source_[t])}),this.bandwidth=this.options_.bandwidth}},{key:"src",value:function(e){var t=this;e&&(this.setOptions_(),this.options_.url=this.source_.src,this.options_.tech=this.tech_,this.options_.externHls=D,this.masterPlaylistController_=new k.MasterPlaylistController(this.options_),this.playbackWatcher_=new I.default(w.default.mergeOptions(this.options_,{seekable:function(){return t.seekable()}})),this.masterPlaylistController_.on("error",function(){w.default.players[t.tech_.options_.playerId].error(t.masterPlaylistController_.error)}),this.masterPlaylistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):D.STANDARD_PLAYLIST_SELECTOR.bind(this),this.masterPlaylistController_.selectInitialPlaylist=D.INITIAL_PLAYLIST_SELECTOR.bind(this),this.playlists=this.masterPlaylistController_.masterPlaylistLoader_,this.mediaSource=this.masterPlaylistController_.mediaSource,Object.defineProperties(this,{selectPlaylist:{get:function(){return this.masterPlaylistController_.selectPlaylist},set:function(e){this.masterPlaylistController_.selectPlaylist=e.bind(this)}},throughput:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.throughput.rate},set:function(e){this.masterPlaylistController_.mainSegmentLoader_.throughput.rate=e,this.masterPlaylistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.bandwidth},set:function(e){this.masterPlaylistController_.mainSegmentLoader_.bandwidth=e,this.masterPlaylistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get:function(){var e=1/(this.bandwidth||1),t=void 0;return t=this.throughput>0?1/this.throughput:0,Math.floor(1/(e+t))},set:function(){w.default.log.error('The "systemBandwidth" property is read-only')}}}),Object.defineProperties(this.stats,{bandwidth:{get:function(){return t.bandwidth||0},enumerable:!0},mediaRequests:{get:function(){return t.masterPlaylistController_.mediaRequests_()||0},enumerable:!0},mediaRequestsAborted:{get:function(){return t.masterPlaylistController_.mediaRequestsAborted_()||0},enumerable:!0},mediaRequestsTimedout:{get:function(){return t.masterPlaylistController_.mediaRequestsTimedout_()||0},enumerable:!0},mediaRequestsErrored:{get:function(){return t.masterPlaylistController_.mediaRequestsErrored_()||0},enumerable:!0},mediaTransferDuration:{get:function(){return t.masterPlaylistController_.mediaTransferDuration_()||0},enumerable:!0},mediaBytesTransferred:{get:function(){return t.masterPlaylistController_.mediaBytesTransferred_()||0},enumerable:!0},mediaSecondsLoaded:{get:function(){return t.masterPlaylistController_.mediaSecondsLoaded_()||0},enumerable:!0}}),this.tech_.one("canplay",this.masterPlaylistController_.setupFirstPlay.bind(this.masterPlaylistController_)),this.masterPlaylistController_.on("selectedinitialmedia",function(){(0,L.default)(t)}),this.on(this.masterPlaylistController_,"progress",function(){this.tech_.trigger("progress")}),this.on(this.masterPlaylistController_,"firstplay",function(){this.ignoreNextSeekingEvent_=!0}),this.tech_.ready(function(){return t.setupQualityLevels_()}),this.tech_.el()&&this.tech_.src(w.default.URL.createObjectURL(this.masterPlaylistController_.mediaSource)))}},{key:"setupQualityLevels_",value:function(){var e=this,t=w.default.players[this.tech_.options_.playerId];t&&t.qualityLevels&&(this.qualityLevels_=t.qualityLevels(),this.masterPlaylistController_.on("selectedinitialmedia",function(){U(e.qualityLevels_,e)}),this.playlists.on("mediachange",function(){M(e.qualityLevels_,e.playlists)}))}},{key:"play",value:function(){this.masterPlaylistController_.play()}},{key:"setCurrentTime",value:function(e){this.masterPlaylistController_.setCurrentTime(e)}},{key:"duration",value:function(){return this.masterPlaylistController_.duration()}},{key:"seekable",value:function(){return this.masterPlaylistController_.seekable()}},{key:"dispose",value:function(){this.playbackWatcher_&&this.playbackWatcher_.dispose(),this.masterPlaylistController_&&this.masterPlaylistController_.dispose(),this.qualityLevels_&&this.qualityLevels_.dispose(),s(Object.getPrototypeOf(t.prototype),"dispose",this).call(this)}}]),t}(B),F=function e(t){return{canHandleSource:function(n){var r=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],i=w.default.mergeOptions(w.default.options,r);return(!i.hls||!i.hls.mode||i.hls.mode===t)&&e.canPlayType(n.type,i)},handleSource:function(e,n){var r=arguments.length<=2||void 0===arguments[2]?{}:arguments[2],i=w.default.mergeOptions(w.default.options,r,{hls:{mode:t}});return"flash"===t&&n.setTimeout(function(){n.trigger("loadstart")},1),n.hls=new N(e,n,i),n.hls.xhr=(0,m.default)(),n.hls.src(e.src),n.hls},canPlayType:function(t){var n=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],r=w.default.mergeOptions(w.default.options,n);return e.canPlayType(t,r)?"maybe":""}}};F.canPlayType=function(e,t){if(w.default.browser.IE_VERSION&&w.default.browser.IE_VERSION<=10)return!1;var n=/^(audio|video|application)\/(x-|vnd\.apple\.)?mpegurl/i;return!(!t.hls.overrideNative&&D.supportsNativeHls)&&n.test(e)},void 0!==w.default.MediaSource&&void 0!==w.default.URL||(w.default.MediaSource=_.MediaSource,w.default.URL=_.URL);var V=w.default.getTech("Flash");_.MediaSource.supportsNativeMediaSources()&&w.default.getTech("Html5").registerSourceHandler(F("html5"),0),j.default.Uint8Array&&V&&V.registerSourceHandler(F("flash")),w.default.HlsHandler=N,w.default.HlsSourceHandler=F,w.default.Hls=D,w.default.use||w.default.registerComponent("Hls",D),w.default.m3u8=T.default,w.default.options.hls=w.default.options.hls||{},t.exports={Hls:D,HlsHandler:N,HlsSourceHandler:F}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./bin-utils":2,"./config":3,"./master-playlist-controller":5,"./playback-watcher":8,"./playlist":11,"./playlist-loader":9,"./playlist-selectors.js":10,"./reload-source-on-error":13,"./rendition-mixin":14,"./xhr":21,"aes-decrypter":25,"global/document":31,"global/window":32,"m3u8-parser":33,"videojs-contrib-media-sources":74}]},{},[77])(77)}),function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.videojsFlvjs=e()}}(function(){return function e(t,n,r){function i(o,s){if(!n[o]){if(!t[o]){var u="function"==typeof require&&require;if(!s&&u)return u(o,!0);if(a)return a(o,!0);var l=new Error("Cannot find module '"+o+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[o]={exports:{}};t[o][0].call(c.exports,function(e){return i(t[o][1][e]||e)},c,c.exports,e,t,n,r)}return n[o].exports}for(var a="function"==typeof require&&require,o=0;o<r.length;o++)i(r[o]);return i}({1:[function(e,t,n){(function(e){"use strict";function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var a=Object.getPrototypeOf(t);return null===a?void 0:e(a,n,r)}if("value"in i)return i.value;var o=i.get;return void 0!==o?o.call(r):void 0},s="undefined"!=typeof window?window.videojs:void 0!==e?e.videojs:null,u=function(e){return e&&e.__esModule?e:{default:e}}(s),l=u.default.getTech("Html5"),c=u.default.mergeOptions||u.default.util.mergeOptions,d={mediaDataSource:{},config:{}},f=function(e){function n(e,i){return t(this,n),e=c(d,e),r(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,i))}return i(n,e),a(n,[{key:"setSrc",value:function(e){this.flvPlayer&&(this.flvPlayer.unload(),this.flvPlayer.detachMediaElement(),this.flvPlayer.destroy());var t=this.options_.mediaDataSource,n=this.options_.config;t.type=void 0===t.type?"flv":t.type,t.url=e,this.flvPlayer=window.flvjs.createPlayer(t,n),this.flvPlayer.attachMediaElement(this.el_),this.flvPlayer.load()}},{key:"dispose",value:function(){this.flvPlayer&&(this.flvPlayer.detachMediaElement(),this.flvPlayer.unload(),this.flvPlayer.destroy(),this.flvPlayer=null),o(n.prototype.__proto__||Object.getPrototypeOf(n.prototype),"dispose",this).call(this)}}]),n}(l);f.isSupported=function(){return window.flvjs&&window.flvjs.isSupported()},f.formats={"video/flv":"FLV","video/x-flv":"FLV"},f.canPlayType=function(e){return f.isSupported()&&e in f.formats?"maybe":""},f.canPlaySource=function(e,t){return f.canPlayType(e.type)},f.VERSION="0.2.0",u.default.registerTech("Flvjs",f),n.default=f}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}]},{},[1])(1)}),function(){"use strict";var e=null;e=void 0===window.videojs&&"function"==typeof require?require("video.js"):window.videojs,function(e,t){function n(e,t,n,r){return a={label:n,sources:t},"function"==typeof r?r(e,t,n):e.src(t.map(function(e){return{src:e.src,type:e.type,res:e.res}}))}var r,i={},a={},o={},s=t.getComponent("MenuItem"),u=t.extend(s,{constructor:function(e,t,n,r){this.onClickListener=n,this.label=r,s.call(this,e,t),this.src=t.src,this.on("click",this.onClick),this.on("touchstart",this.onClick),t.initialySelected&&(this.showAsLabel(),this.selected(!0),this.addClass("vjs-selected"))},showAsLabel:function(){this.label&&(this.label.innerHTML=this.options_.label)},onClick:function(e){this.onClickListener(this);var t=this.player_.currentTime(),r=this.player_.paused();this.showAsLabel(),this.addClass("vjs-selected"),r||this.player_.bigPlayButton.hide(),"function"!=typeof e&&"function"==typeof this.options_.customSourcePicker&&(e=this.options_.customSourcePicker);var i="loadeddata";"Youtube"!==this.player_.techName_&&"none"===this.player_.preload()&&"Flash"!==this.player_.techName_&&(i="timeupdate"),n(this.player_,this.src,this.options_.label,e),this.player_.one(i,function(){this.player_.currentTime(t),this.player_.handleTechSeeked_(),this.player_.trigger("resolutionchange")})}}),l=t.getComponent("MenuButton"),c=t.extend(l,{constructor:function(e,n,r,i){if(this.sources=n.sources,this.label=i,this.label.innerHTML=n.initialySelectedLabel,l.call(this,e,n,r),this.controlText("Quality"),r.dynamicLabel)this.el().appendChild(i);else{var a=document.createElement("span");t.dom.addClass(a,"vjs-resolution-button-staticlabel"),this.el().appendChild(a)}},createItems:function(){var e=[],t=this.sources&&this.sources.label||{},n=function(t){e.map(function(e){e.selected(e===t),e.removeClass("vjs-selected")})};for(var r in t)t.hasOwnProperty(r)&&(e.push(new u(this.player_,{label:r,src:t[r],initialySelected:r===this.options_.initialySelectedLabel,customSourcePicker:this.options_.customSourcePicker},n,this.label)),o[r]=e[e.length-1]);return e}});r=function(e){function r(e,t){return e.res&&t.res?+t.res-+e.res:0}function s(e){var t={label:{},res:{},type:{}};return e.map(function(e){u(t,"label",e),u(t,"res",e),u(t,"type",e),l(t,"label",e),l(t,"res",e),l(t,"type",e)}),t}function u(e,t,n){null==e[t][n[t]]&&(e[t][n[t]]=[])}function l(e,t,n){e[t][n[t]].push(n)}function d(e,t){var n=h.default,r="";return"high"===n?(n=t[0].res,r=t[0].label):"low"!==n&&null!=n&&e.res[n]?e.res[n]&&(r=e.res[n][0].label):(n=t[t.length-1].res,r=t[t.length-1].label),{res:n,label:r,sources:e.res[n]}}function f(e){e.tech_.ytPlayer.setPlaybackQuality("default"),e.tech_.ytPlayer.addEventListener("onPlaybackQualityChange",function(){e.trigger("resolutionchange")}),e.one("play",function(){var t=e.tech_.ytPlayer.getAvailableQualityLevels(),n={highres:{res:1080,label:"1080",yt:"highres"},hd1080:{res:1080,label:"1080",yt:"hd1080"},hd720:{res:720,label:"720",yt:"hd720"},large:{res:480,label:"480",yt:"large"},medium:{res:360,label:"360",yt:"medium"},small:{res:240,label:"240",yt:"small"},tiny:{res:144,label:"144",yt:"tiny"},auto:{res:0,label:"auto",yt:"default"}},r=[];t.map(function(t){r.push({src:e.src().src,type:e.src().type,label:n[t].label,res:n[t].res,_yt:n[t].yt})}),v=s(r);var i=function(t,n,r){return e.tech_.ytPlayer.setPlaybackQuality(n[0]._yt),e},a={label:"auto",res:0,sources:v.label.auto},o=new c(e,{sources:v,initialySelectedLabel:a.label,initialySelectedRes:a.res,customSourcePicker:i},h,m);o.el().classList.add("vjs-resolution-button"),e.controlBar.resolutionSwitcher=e.controlBar.addChild(o)})}var h=t.mergeOptions(i,e),p=this,m=document.createElement("span"),v={};t.dom.addClass(m,"vjs-menu"),t.browser.IE_VERSION?t.dom.addClass(m,"vjs-resolution-button-label-ie"):t.dom.addClass(m,"vjs-resolution-button-label"),p.updateSrc=function(e){if(!e)return p.src();p.controlBar.resolutionSwitcher&&(p.controlBar.resolutionSwitcher.dispose(),delete p.controlBar.resolutionSwitcher),e=e.sort(r),v=s(e);var i=d(v,e),a=new c(p,{sources:v,initialySelectedLabel:i.label,initialySelectedRes:i.res,customSourcePicker:h.customSourcePicker},h,m);return t.dom.addClass(a.el(),"vjs-resolution-button"),p.controlBar.resolutionSwitcher=p.controlBar.el_.insertBefore(a.el_,p.controlBar.getChild("fullscreenToggle").el_),p.controlBar.resolutionSwitcher.dispose=function(){this.parentNode.removeChild(this)},n(p,i.sources,i.label)},p.currentResolution=function(e,t){return null==e?a:(null!=o[e]&&o[e].onClick(t),p)},p.getGroupedSrc=function(){return v},p.ready(function(){p.options_.sources.length>1&&p.updateSrc(p.options_.sources),"Youtube"===p.techName_&&f(p)})},t.registerPlugin("videoJsResolutionSwitcher",r)}(window,e)}(),function(e,t){"undefined"!=typeof window&&window.videojs?t(window.videojs):"function"==typeof define&&define.amd?define("videojs-hotkeys",["video.js"],function(e){return t(e.default||e)}):"undefined"!=typeof module&&module.exports&&(module.exports=t(require("video.js")))}(0,function(e){"use strict";"undefined"!=typeof window&&(window.videojs_hotkeys={version:"0.2.22"});var t=function(t){function n(e){return 32===e.which||179===e.which}function r(e){return 37===e.which||177===e.which}function i(e){return 39===e.which||176===e.which}function a(e){return 38===e.which}function o(e){return 40===e.which}function s(e){return 77===e.which}function u(e){return 70===e.which}function l(e){return"function"==typeof v?v(e):v}var c=this,d=c.el(),f=document,h={volumeStep:.1,seekStep:5,enableMute:!0,enableVolumeScroll:!0,enableFullscreen:!0,enableNumbers:!0,enableJogStyle:!1,alwaysCaptureHotkeys:!1,enableModifiersForNumbers:!0,enableInactiveFocus:!0,skipInitialFocus:!1,playPauseKey:n,rewindKey:r,forwardKey:i,volumeUpKey:a,volumeDownKey:o,muteKey:s,fullscreenKey:u,customKeys:{}},p=e.mergeOptions||e.util.mergeOptions;t=p(h,t||{});var m=t.volumeStep,v=t.seekStep,g=t.enableMute,y=t.enableVolumeScroll,_=t.enableFullscreen,b=t.enableNumbers,T=t.enableJogStyle,S=t.alwaysCaptureHotkeys,w=t.enableModifiersForNumbers,k=t.enableInactiveFocus,E=t.skipInitialFocus;d.hasAttribute("tabIndex")||d.setAttribute("tabIndex","-1"),d.style.outline="none",!S&&c.autoplay()||E||c.one("play",function(){d.focus({preventScroll:!0})}),k&&c.on("userinactive",function(){var e=function(){clearTimeout(t)},t=setTimeout(function(){c.off("useractive",e);var t=f.activeElement,n=d.querySelector(".vjs-control-bar");t&&t.parentElement==n&&d.focus()},10);c.one("useractive",e)}),c.on("play",function(){var e=d.querySelector(".iframeblocker");e&&""===e.style.display&&(e.style.display="block",e.style.bottom="39px")});var A=function(e){var n,r,i=e.which,a=e.preventDefault,o=c.duration();if(c.controls()){var s=f.activeElement;if(S||s==d||s==d.querySelector(".vjs-tech")||s==d.querySelector(".vjs-control-bar")||s==d.querySelector(".iframeblocker"))switch(L(e,c)){case 1:a(),S&&e.stopPropagation(),c.paused()?c.play():c.pause();break;case 2:n=!c.paused(),a(),n&&c.pause(),r=c.currentTime()-l(e),r<=0&&(r=0),c.currentTime(r),n&&c.play();break;case 3:n=!c.paused(),a(),n&&c.pause(),r=c.currentTime()+l(e),r>=o&&(r=n?o-.001:o),c.currentTime(r),n&&c.play();break;case 5:a(),T?(r=c.currentTime()-1,c.currentTime()<=1&&(r=0),c.currentTime(r)):c.volume(c.volume()-m);break;case 4:a(),T?(r=c.currentTime()+1,r>=o&&(r=o),c.currentTime(r)):c.volume(c.volume()+m);break;case 6:g&&c.muted(!c.muted());break;case 7:_&&(c.isFullscreen()?c.exitFullscreen():c.requestFullscreen());break;default:if((i>47&&i<59||i>95&&i<106)&&(w||!(e.metaKey||e.ctrlKey||e.altKey))&&b){var u=48;i>95&&(u=96);var h=i-u;a(),c.currentTime(c.duration()*h*.1)}for(var p in t.customKeys){var v=t.customKeys[p];v&&v.key&&v.handler&&v.key(e)&&(a(),v.handler(c,t,e))}}}},C=function(e){if(c.controls()){var t=f.activeElement;if((S||t==d||t==d.querySelector(".vjs-tech")||t==d.querySelector(".iframeblocker")||t==d.querySelector(".vjs-control-bar"))&&y){e=window.event||e;var n=Math.max(-1,Math.min(1,e.wheelDelta||-e.detail));e.preventDefault(),1==n?c.volume(c.volume()+m):-1==n&&c.volume(c.volume()-m)}}},L=function(e,n){return t.playPauseKey(e,n)?1:t.rewindKey(e,n)?2:t.forwardKey(e,n)?3:t.volumeUpKey(e,n)?4:t.volumeDownKey(e,n)?5:t.muteKey(e,n)?6:t.fullscreenKey(e,n)?7:void 0};return c.on("keydown",A),c.on("mousewheel",C),c.on("DOMMouseScroll",C),this};(e.registerPlugin||e.plugin)("hotkeys",t)}),function(e){e.URL=e.URL||e.webkitURL,navigator.getUserMedia=navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.mozGetUserMedia||navigator.msGetUserMedia;var t=function(t,n){n=n||{},n.sampleBits=n.sampleBits||8,n.sampleRate=n.sampleRate||8e3;var r=new(e.webkitAudioContext||e.AudioContext),i=r.createMediaStreamSource(t),a=r.createScriptProcessor||r.createJavaScriptNode,o=a.apply(r,[4096,1,1]),s=!1,u={size:0,buffer:[],inputSampleRate:r.sampleRate,inputSampleBits:16,outputSampleRate:n.sampleRate,oututSampleBits:n.sampleBits,input:function(e){this.buffer.push(new Float32Array(e)),this.size+=e.length,n.pcmCallback&&(n.pcmCallback(this.encodePCM()),this.buffer.splice(0,this.size),this.size=0)},compress:function(){for(var e=new Float32Array(this.size),t=0,n=0;n<this.buffer.length;n++)e.set(this.buffer[n],t),t+=this.buffer[n].length;for(var r=parseInt(this.inputSampleRate/this.outputSampleRate),i=e.length/r,a=new Float32Array(i),o=0,s=0;o<i;)a[o]=e[s],s+=r,o++;return a},encodePCM:function(){var e=Math.min(this.inputSampleBits,this.oututSampleBits),t=this.compress(),n=t.length*(e/8),r=new ArrayBuffer(n),i=new DataView(r),a=0;if(8===e)for(var o=0;o<t.length;o++,a++){var s=Math.max(-1,Math.min(1,t[o])),u=s<0?32768*s:32767*s;u=parseInt(255/(65535/(u+32768))),i.setInt8(a,u,!0)}else for(var o=0;o<t.length;o++,a+=2){var s=Math.max(-1,Math.min(1,t[o]));i.setInt16(a,s<0?32768*s:32767*s,!0)}return new Blob([i],{type:"audio/pcm"})},encodeWAV:function(){var e=Math.min(this.inputSampleRate,this.outputSampleRate),t=Math.min(this.inputSampleBits,this.oututSampleBits),n=this.compress(),r=n.length*(t/8),i=new ArrayBuffer(44+r),a=new DataView(i),o=0,s=function(e){for(var t=0;t<e.length;t++)a.setUint8(o+t,e.charCodeAt(t))};if(s("RIFF"),o+=4,a.setUint32(o,36+r,!0),o+=4,s("WAVE"),o+=4,s("fmt "),o+=4,a.setUint32(o,16,!0),o+=4,a.setUint16(o,1,!0),o+=2,a.setUint16(o,1,!0),o+=2,a.setUint32(o,e,!0),o+=4,a.setUint32(o,1*e*(t/8),!0),o+=4,a.setUint16(o,t/8*1,!0),o+=2,a.setUint16(o,t,!0),o+=2,s("data"),o+=4,a.setUint32(o,r,!0),o+=4,8===t)for(var u=0;u<n.length;u++,o++){var l=Math.max(-1,Math.min(1,n[u])),c=l<0?32768*l:32767*l;c=parseInt(255/(65535/(c+32768))),a.setInt8(o,c,!0)}else for(var u=0;u<n.length;u++,o+=2){var l=Math.max(-1,Math.min(1,n[u]));a.setInt16(o,l<0?32768*l:32767*l,!0)}return new Blob([a],{type:"audio/wav"})}};this.start=function(){s||(i.connect(o),o.connect(r.destination),s=!0)},this.stop=function(){s&&(o.disconnect(),s=!1)},this.destroy=function(){this.stop(),r&&(r.close(),r=null)},this.getBlob=function(){return this.stop(),u.encodeWAV()},this.getPCMBlob=function(){return this.stop(),u.encodePCM()},this.play=function(t){t.src=e.URL.createObjectURL(this.getBlob())},this.recording=function(){return s},this.upload=function(e,t){var n=new FormData;n.append("audioData",this.getBlob()),n.append("pcmData",this.getPCMBlob());var r=new XMLHttpRequest;t&&(r.upload.addEventListener("progress",function(e){t("uploading",e)},!1),r.addEventListener("load",function(e){t("ok",e)},!1),r.addEventListener("error",function(e){t("error",e)},!1),r.addEventListener("abort",function(e){t("cancel",e)},!1)),r.open("POST",e),r.send(n)},o.onaudioprocess=function(e){u.input(e.inputBuffer.getChannelData(0))}};t.canRecording=null!=navigator.getUserMedia,t.get=function(e,n){if(e){if(!navigator.getUserMedia)return"https:"!=String(location.protocol).toLowerCase()?void e(null,"当前浏览器不支持录音功能, 请确认当前是否访问 HTTPS 服务!"):void e(null,"当前浏览器不支持录音功能。");navigator.getUserMedia({audio:!0},function(r){var i=new t(r,n);e(i,null)},function(t){switch(t.name||t.code){case"PERMISSION_DENIED":case"PermissionDeniedError":e(null,"用户拒绝提供信息。");break;case"NOT_SUPPORTED_ERROR":case"NotSupportedError":e(null,"浏览器不支持硬件设备。");break;case"MANDATORY_UNSATISFIED_ERROR":case"MandatoryUnsatisfiedError":e(null,"无法发现指定的硬件设备。");break;default:e(null,"无法打开麦克风。异常信息:"+(t.name||t.code))}})}},e.LiveRecorder=t}(window),videojs.addLanguage("zh-CN",{Play:"播放",Pause:"暂停","Current Time":"当前时间",Duration:"时长","Remaining Time":"剩余时间","Stream Type":"媒体流类型",LIVE:"直播",Loaded:"加载完毕",Progress:"进度",Fullscreen:"全屏","Non-Fullscreen":"退出全屏",Mute:"静音",Unmute:"取消静音","Playback Rate":"播放速度",Subtitles:"字幕","subtitles off":"关闭字幕",Captions:"内嵌字幕","captions off":"关闭内嵌字幕",Chapters:"节目段落","Close Modal Dialog":"关闭弹窗",Descriptions:"描述","descriptions off":"关闭描述","Audio Track":"音轨","You aborted the media playback":"视频播放被终止","A network error caused the media download to fail part-way.":"网络错误导致视频下载中途失败。","The media could not be loaded, either because the server or network failed or because the format is not supported.":"视频因格式不支持或者服务器或网络的问题无法加载。","The media playback was aborted due to a corruption problem or because the media used features your browser did not support.":"由于视频文件损坏或是该视频使用了你的浏览器不支持的功能,播放终止。","No compatible source was found for this media.":"无法找到此视频兼容的源。","The media is encrypted and we do not have the keys to decrypt it.":"视频已加密,无法解密。","Play Video":"播放视频",Close:"关闭","Modal Window":"弹窗","This is a modal window":"这是一个弹窗","This modal can be closed by pressing the Escape key or activating the close button.":"可以按ESC按键或启用关闭按钮来关闭此弹窗。",", opens captions settings dialog":", 开启标题设置弹窗",", opens subtitles settings dialog":", 开启字幕设置弹窗",", opens descriptions settings dialog":", 开启描述设置弹窗",", selected":", 选择","captions settings":"字幕设定","Audio Player":"音频播放器","Video Player":"视频播放器",Replay:"重播","Progress Bar":"进度条","Volume Level":"音量","subtitles settings":"字幕设定","descriptions settings":"描述设定",Text:"文字",White:"白",Black:"黑",Red:"红",Green:"绿",Blue:"蓝",Yellow:"黄",Magenta:"紫红",Cyan:"青",Background:"背景",Window:"视窗",Transparent:"透明","Semi-Transparent":"半透明",Opaque:"不透明","Font Size":"字体尺寸","Text Edge Style":"字体边缘样式",None:"无",Raised:"浮雕",Depressed:"压低",Uniform:"均匀",Dropshadow:"下阴影","Font Family":"字体库","Proportional Sans-Serif":"比例无细体","Monospace Sans-Serif":"单间隔无细体","Proportional Serif":"比例细体","Monospace Serif":"单间隔细体",Casual:"舒适",Script:"手写体","Small Caps":"小型大写字体",Reset:"重置","restore all settings to the default values":"恢复全部设定至预设值",Done:"完成","Caption Settings Dialog":"字幕设定视窗","Beginning of dialog window. Escape will cancel and close the window.":"开始对话视窗。离开会取消及关闭视窗","End of dialog window.":"结束对话视窗","Seek to live, currently behind live":"试图直播,当前延时播放","Seek to live, currently playing live":"试图直播,当前实时播放","progress bar timing: currentTime={1} duration={2}":"{1}/{2}","{1} is loading.":"正在加载 {1}。","Picture-in-Picture":"画中画","Exit Picture-in-Picture":"退出画中画",Snapshot:"截图"}),function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=0)}({"+hPR":function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=r.key,o=r.set;r.exp({defineMetadata:function(e,t,n,r){o(e,t,i(n),a(r))}})},"+qBm":function(e,t,n){"use strict";var r=n("HTem");e.exports=function(e,t){return!!e&&r(function(){t?e.call(null,function(){},1):e.call(null)})}},"/CZk":function(e,t,n){"use strict";n("48Hh")("fontsize",function(e){return function(t){return e(this,"font","size",t)}})},"/TTR":function(e,t,n){var r=n("qMAc");"string"==typeof r&&(r=[[e.i,r,""]]);var i={hmr:!0};i.transform=void 0;n("MTIv")(r,i);r.locals&&(e.exports=r.locals)},"/dY/":function(e,t,n){var r=n("AIRG"),i=n("iYN6");e.exports=Object.keys||function(e){return r(e,i)}},"/w37":function(e,t,n){"use strict";var r=n("eqAp"),i=n("bmV0");r(r.P+r.F*n("rNRh")("includes"),"String",{includes:function(e){return!!~i(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},0:function(e,t,n){n("j1ja"),e.exports=n("GDCL")},"07De":function(e,t,n){"use strict";function r(e){var t,n;this.promise=new e(function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r}),this.resolve=i(t),this.reject=i(n)}var i=n("B63G");e.exports.f=function(e){return new r(e)}},"0W8K":function(e,t,n){n("YQk9")("WeakMap")},"162o":function(e,t,n){(function(e){function r(e,t){this._id=e,this._clearFn=t}var i=void 0!==e&&e||"undefined"!=typeof self&&self||window,a=Function.prototype.apply;t.setTimeout=function(){return new r(a.call(setTimeout,i,arguments),clearTimeout)},t.setInterval=function(){return new r(a.call(setInterval,i,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e&&e.close()},r.prototype.unref=r.prototype.ref=function(){},r.prototype.close=function(){this._clearFn.call(i,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},n("mypn"),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(t,n("DuR2"))},"17/W":function(e,t,n){var r=n("eqAp"),i=n("kLED")(!1);r(r.S,"Object",{values:function(e){return i(e)}})},"1SZZ":function(e,t,n){"use strict";n("48Hh")("fontcolor",function(e){return function(t){return e(this,"font","color",t)}})},"1Yoh":function(e,t){function n(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function r(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&n(e.slice(0,0))}e.exports=function(e){return null!=e&&(n(e)||r(e)||!!e._isBuffer)}},"1oJE":function(e,t,n){var r=n("eqAp"),i=n("2zMK");r(r.S+r.F*(Number.parseInt!=i),"Number",{parseInt:i})},"1vD2":function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},"2+22":function(e,t,n){"use strict";if(n("8yv5")){var r=n("G3Gk"),i=n("vR0S"),a=n("HTem"),o=n("eqAp"),s=n("Au7w"),u=n("Ee0C"),l=n("wRig"),c=n("S5no"),d=n("D8PY"),f=n("CfIS"),h=n("NmAK"),p=n("sxvG"),m=n("J5DO"),v=n("4oJ4"),g=n("IfkE"),y=n("E2U5"),_=n("3ty/"),b=n("bPSW"),T=n("U9LJ"),S=n("AeeY"),w=n("e1Y9"),k=n("NkR5"),E=n("spe/"),A=n("XjC+").f,C=n("JuSo"),L=n("guD1"),x=n("6hGG"),j=n("Q2Ff"),O=n("VqU3"),I=n("8rdt"),P=n("K0e4"),R=n("xnnD"),D=n("GAJc"),M=n("7QiM"),U=n("T8YM"),B=n("EAuC"),N=n("rBVO"),F=n("gWbE"),V=N.f,q=F.f,G=i.RangeError,H=i.TypeError,z=i.Uint8Array,W=Array.prototype,$=u.ArrayBuffer,Y=u.DataView,K=j(0),X=j(2),J=j(3),Q=j(4),Z=j(5),ee=j(6),te=O(!0),ne=O(!1),re=P.values,ie=P.keys,ae=P.entries,oe=W.lastIndexOf,se=W.reduce,ue=W.reduceRight,le=W.join,ce=W.sort,de=W.slice,fe=W.toString,he=W.toLocaleString,pe=x("iterator"),me=x("toStringTag"),ve=L("typed_constructor"),ge=L("def_constructor"),ye=s.CONSTR,_e=s.TYPED,be=s.VIEW,Te=j(1,function(e,t){return Ae(I(e,e[ge]),t)}),Se=a(function(){return 1===new z(new Uint16Array([1]).buffer)[0]}),we=!!z&&!!z.prototype.set&&a(function(){new z(1).set({})}),ke=function(e,t){var n=p(e);if(n<0||n%t)throw G("Wrong offset!");return n},Ee=function(e){if(T(e)&&_e in e)return e;throw H(e+" is not a typed array!")},Ae=function(e,t){if(!(T(e)&&ve in e))throw H("It is not a typed array constructor!");return new e(t)},Ce=function(e,t){return Le(I(e,e[ge]),t)},Le=function(e,t){for(var n=0,r=t.length,i=Ae(e,r);r>n;)i[n]=t[n++];return i},xe=function(e,t,n){V(e,t,{get:function(){return this._d[n]}})},je=function(e){var t,n,r,i,a,o,s=S(e),u=arguments.length,c=u>1?arguments[1]:void 0,d=void 0!==c,f=C(s);if(void 0!=f&&!w(f)){for(o=f.call(s),r=[],t=0;!(a=o.next()).done;t++)r.push(a.value);s=r}for(d&&u>2&&(c=l(c,arguments[2],2)),t=0,n=m(s.length),i=Ae(this,n);n>t;t++)i[t]=d?c(s[t],t):s[t];return i},Oe=function(){for(var e=0,t=arguments.length,n=Ae(this,t);t>e;)n[e]=arguments[e++];return n},Ie=!!z&&a(function(){he.call(new z(1))}),Pe=function(){return he.apply(Ie?de.call(Ee(this)):Ee(this),arguments)},Re={copyWithin:function(e,t){return B.call(Ee(this),e,t,arguments.length>2?arguments[2]:void 0)},every:function(e){return Q(Ee(this),e,arguments.length>1?arguments[1]:void 0)},fill:function(e){return U.apply(Ee(this),arguments)},filter:function(e){return Ce(this,X(Ee(this),e,arguments.length>1?arguments[1]:void 0))},find:function(e){return Z(Ee(this),e,arguments.length>1?arguments[1]:void 0)},findIndex:function(e){return ee(Ee(this),e,arguments.length>1?arguments[1]:void 0)},forEach:function(e){K(Ee(this),e,arguments.length>1?arguments[1]:void 0)},indexOf:function(e){return ne(Ee(this),e,arguments.length>1?arguments[1]:void 0)},includes:function(e){return te(Ee(this),e,arguments.length>1?arguments[1]:void 0)},join:function(e){return le.apply(Ee(this),arguments)},lastIndexOf:function(e){return oe.apply(Ee(this),arguments)},map:function(e){return Te(Ee(this),e,arguments.length>1?arguments[1]:void 0)},reduce:function(e){return se.apply(Ee(this),arguments)},reduceRight:function(e){return ue.apply(Ee(this),arguments)},reverse:function(){for(var e,t=this,n=Ee(t).length,r=Math.floor(n/2),i=0;i<r;)e=t[i],t[i++]=t[--n],t[n]=e;return t},some:function(e){return J(Ee(this),e,arguments.length>1?arguments[1]:void 0)},sort:function(e){return ce.call(Ee(this),e)},subarray:function(e,t){var n=Ee(this),r=n.length,i=g(e,r);return new(I(n,n[ge]))(n.buffer,n.byteOffset+i*n.BYTES_PER_ELEMENT,m((void 0===t?r:g(t,r))-i))}},De=function(e,t){return Ce(this,de.call(Ee(this),e,t))},Me=function(e){Ee(this);var t=ke(arguments[1],1),n=this.length,r=S(e),i=m(r.length),a=0;if(i+t>n)throw G("Wrong length!");for(;a<i;)this[t+a]=r[a++]},Ue={entries:function(){return ae.call(Ee(this))},keys:function(){return ie.call(Ee(this))},values:function(){return re.call(Ee(this))}},Be=function(e,t){return T(e)&&e[_e]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},Ne=function(e,t){return Be(e,t=y(t,!0))?d(2,e[t]):q(e,t)},Fe=function(e,t,n){return!(Be(e,t=y(t,!0))&&T(n)&&_(n,"value"))||_(n,"get")||_(n,"set")||n.configurable||_(n,"writable")&&!n.writable||_(n,"enumerable")&&!n.enumerable?V(e,t,n):(e[t]=n.value,e)};ye||(F.f=Ne,N.f=Fe),o(o.S+o.F*!ye,"Object",{getOwnPropertyDescriptor:Ne,defineProperty:Fe}),a(function(){fe.call({})})&&(fe=he=function(){return le.call(this)});var Ve=h({},Re);h(Ve,Ue),f(Ve,pe,Ue.values),h(Ve,{slice:De,set:Me,constructor:function(){},toString:fe,toLocaleString:Pe}),xe(Ve,"buffer","b"),xe(Ve,"byteOffset","o"),xe(Ve,"byteLength","l"),xe(Ve,"length","e"),V(Ve,me,{get:function(){return this[_e]}}),e.exports=function(e,t,n,u){u=!!u;var l=e+(u?"Clamped":"")+"Array",d="get"+e,h="set"+e,p=i[l],g=p||{},y=p&&E(p),_=!p||!s.ABV,S={},w=p&&p.prototype,C=function(e,n){var r=e._d;return r.v[d](n*t+r.o,Se)},L=function(e,n,r){var i=e._d;u&&(r=(r=Math.round(r))<0?0:r>255?255:255&r),i.v[h](n*t+i.o,r,Se)},x=function(e,t){V(e,t,{get:function(){return C(this,t)},set:function(e){return L(this,t,e)},enumerable:!0})};_?(p=n(function(e,n,r,i){c(e,p,l,"_d");var a,o,s,u,d=0,h=0;if(T(n)){if(!(n instanceof $||"ArrayBuffer"==(u=b(n))||"SharedArrayBuffer"==u))return _e in n?Le(p,n):je.call(p,n);a=n,h=ke(r,t);var g=n.byteLength;if(void 0===i){if(g%t)throw G("Wrong length!");if((o=g-h)<0)throw G("Wrong length!")}else if((o=m(i)*t)+h>g)throw G("Wrong length!");s=o/t}else s=v(n),o=s*t,a=new $(o);for(f(e,"_d",{b:a,o:h,l:o,e:s,v:new Y(a)});d<s;)x(e,d++)}),w=p.prototype=k(Ve),f(w,"constructor",p)):a(function(){p(1)})&&a(function(){new p(-1)})&&D(function(e){new p,new p(null),new p(1.5),new p(e)},!0)||(p=n(function(e,n,r,i){c(e,p,l);var a;return T(n)?n instanceof $||"ArrayBuffer"==(a=b(n))||"SharedArrayBuffer"==a?void 0!==i?new g(n,ke(r,t),i):void 0!==r?new g(n,ke(r,t)):new g(n):_e in n?Le(p,n):je.call(p,n):new g(v(n))}),K(y!==Function.prototype?A(g).concat(A(y)):A(g),function(e){e in p||f(p,e,g[e])}),p.prototype=w,r||(w.constructor=p));var j=w[pe],O=!!j&&("values"==j.name||void 0==j.name),I=Ue.values;f(p,ve,!0),f(w,_e,l),f(w,be,!0),f(w,ge,p),(u?new p(1)[me]==l:me in w)||V(w,me,{get:function(){return l}}),S[l]=p,o(o.G+o.W+o.F*(p!=g),S),o(o.S,l,{BYTES_PER_ELEMENT:t}),o(o.S+o.F*a(function(){g.of.call(p,1)}),l,{from:je,of:Oe}),"BYTES_PER_ELEMENT"in w||f(w,"BYTES_PER_ELEMENT",t),o(o.P,l,Re),M(l),o(o.P+o.F*we,l,{set:Me}),o(o.P+o.F*!O,l,Ue),r||w.toString==fe||(w.toString=fe),o(o.P+o.F*a(function(){new p(1).slice()}),l,{slice:De}),o(o.P+o.F*(a(function(){return[1,2].toLocaleString()!=new p([1,2]).toLocaleString()})||!a(function(){w.toLocaleString.call([1,2])})),l,{toLocaleString:Pe}),R[l]=O?j:I,r||O||f(w,pe,I)}}else e.exports=function(){}},"21It":function(e,t,n){"use strict";var r=n("FtD3");e.exports=function(e,t,n){var i=n.config.validateStatus;n.status&&i&&!i(n.status)?t(r("Request failed with status code "+n.status,n.config,null,n.request,n)):e(n)}},"26gs":function(e,t,n){var r=n("eqAp");r(r.S,"Math",{trunc:function(e){return(e>0?Math.floor:Math.ceil)(e)}})},"2R19":function(e,t,n){n("sGlJ")("Map")},"2Zej":function(e,t){e.exports=function(e,t){var n=t===Object(t)?function(e){return t[e]}:t;return function(t){return String(t).replace(e,n)}}},"2gXL":function(e,t,n){var r=n("eqAp"),i=n("nCxY"),a=Math.abs;r(r.S,"Number",{isSafeInteger:function(e){return i(e)&&a(e)<=9007199254740991}})},"2zMK":function(e,t,n){var r=n("vR0S").parseInt,i=n("XOiX").trim,a=n("tBsZ"),o=/^[-+]?0[xX]/;e.exports=8!==r(a+"08")||22!==r(a+"0x16")?function(e,t){var n=i(String(e),3);return r(n,t>>>0||(o.test(n)?16:10))}:r},"3CFP":function(e,t,n){"use strict";var r=n("eqAp"),i=n("AeeY"),a=n("E2U5");r(r.P+r.F*n("HTem")(function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})}),"Date",{toJSON:function(e){var t=i(this),n=a(t);return"number"!=typeof n||isFinite(n)?t.toISOString():null}})},"3IRH":function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},"3K1F":function(e,t,n){var r=n("eqAp");r(r.S,"Math",{iaddh:function(e,t,n,r){var i=e>>>0,a=t>>>0,o=n>>>0;return a+(r>>>0)+((i&o|(i|o)&~(i+o>>>0))>>>31)|0}})},"3Qkz":function(e,t,n){var r=n("eqAp"),i=n("2Zej")(/[\\^$*+?.()|[\]{}]/g,"\\$&");r(r.S,"RegExp",{escape:function(e){return i(e)}})},"3TcY":function(e,t,n){n("2+22")("Int8",1,function(e){return function(t,n,r){return e(this,t,n,r)}})},"3gWO":function(e,t,n){var r=n("U9LJ"),i=n("QhHn").onFreeze;n("Iiwq")("preventExtensions",function(e){return function(t){return e&&r(t)?e(i(t)):t}})},"3jLb":function(e,t,n){var r=n("J5DO"),i=n("sbdb"),a=n("VmoO");e.exports=function(e,t,n,o){var s=String(a(e)),u=s.length,l=void 0===n?" ":String(n),c=r(t);if(c<=u||""==l)return s;var d=c-u,f=i.call(l,Math.ceil(d/l.length));return f.length>d&&(f=f.slice(0,d)),o?f+s:s+f}},"3tLj":function(e,t,n){var r=n("gWbE"),i=n("eqAp"),a=n("PGRs");i(i.S,"Reflect",{getOwnPropertyDescriptor:function(e,t){return r.f(a(e),t)}})},"3ty/":function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},"46HX":function(e,t,n){var r=n("eqAp");r(r.P,"Array",{copyWithin:n("EAuC")}),n("5BZE")("copyWithin")},"48Hh":function(e,t,n){var r=n("eqAp"),i=n("HTem"),a=n("VmoO"),o=/"/g,s=function(e,t,n,r){var i=String(a(e)),s="<"+t;return""!==n&&(s+=" "+n+'="'+String(r).replace(o,"&quot;")+'"'),s+">"+i+"</"+t+">"};e.exports=function(e,t){var n={};n[e]=t(s),r(r.P+r.F*i(function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3}),"String",n)}},"4TB0":function(e,t,n){var r=n("eqAp"),i=n("E3yU")(),a=n("vR0S").process,o="process"==n("1vD2")(a);r(r.G,{asap:function(e){var t=o&&a.domain;i(t?t.bind(e):e)}})},"4WJq":function(e,t,n){var r=n("PGRs"),i=n("U9LJ"),a=n("07De");e.exports=function(e,t){if(r(e),i(t)&&t.constructor===e)return t;var n=a.f(e);return(0,n.resolve)(t),n.promise}},"4gN1":function(e,t,n){n("2+22")("Float64",8,function(e){return function(t,n,r){return e(this,t,n,r)}})},"4oJ4":function(e,t,n){var r=n("sxvG"),i=n("J5DO");e.exports=function(e){if(void 0===e)return 0;var t=r(e),n=i(t);if(t!==n)throw RangeError("Wrong length!");return n}},"535S":function(e,t,n){"use strict";var r=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"player-wrapper"},[n("div",{staticClass:"video-wrapper",style:e.videoWrapperStyle},[n("div",{staticClass:"video-inner",class:{live:e.live,"av-loading":e.avLoading,"hide-waiting":e.hideWaiting,"show-time":e.showTime&&!e.live},staticStyle:{position:"absolute",top:"0",bottom:"0",left:"0",right:"0"}}),e._v(" "),n("div",{directives:[{name:"show",rawName:"v-show",value:e.showSlot,expression:"showSlot"}],staticClass:"video-slot"},[e._t("default")],2),e._v(" "),n("span",{directives:[{name:"show",rawName:"v-show",value:e.videoTitle&&e.showSlot,expression:"videoTitle && showSlot"}],staticClass:"video-title",attrs:{title:e.videoTitle}},[e._v(e._s(e.videoTitle))])])])},i=[],a={render:r,staticRenderFns:i};t.a=a},"5BZE":function(e,t,n){var r=n("6hGG")("unscopables"),i=Array.prototype;void 0==i[r]&&n("CfIS")(i,r,{}),e.exports=function(e){i[r][e]=!0}},"5EKM":function(e,t,n){var r=n("eqAp"),i=Math.atanh;r(r.S+r.F*!(i&&1/i(-0)<0),"Math",{atanh:function(e){return 0==(e=+e)?e:Math.log((1+e)/(1-e))/2}})},"5NQZ":function(e,t,n){"use strict";var r,i,a,o,s=n("G3Gk"),u=n("vR0S"),l=n("wRig"),c=n("bPSW"),d=n("eqAp"),f=n("U9LJ"),h=n("B63G"),p=n("S5no"),m=n("VLJK"),v=n("8rdt"),g=n("XJA6").set,y=n("E3yU")(),_=n("07De"),b=n("xfzY"),T=n("N2PI"),S=n("4WJq"),w=u.TypeError,k=u.process,E=k&&k.versions,A=E&&E.v8||"",C=u.Promise,L="process"==c(k),x=function(){},j=i=_.f,O=!!function(){try{var e=C.resolve(1),t=(e.constructor={})[n("6hGG")("species")]=function(e){e(x,x)};return(L||"function"==typeof PromiseRejectionEvent)&&e.then(x)instanceof t&&0!==A.indexOf("6.6")&&-1===T.indexOf("Chrome/66")}catch(e){}}(),I=function(e){var t;return!(!f(e)||"function"!=typeof(t=e.then))&&t},P=function(e,t){if(!e._n){e._n=!0;var n=e._c;y(function(){for(var r=e._v,i=1==e._s,a=0;n.length>a;)!function(t){var n,a,o,s=i?t.ok:t.fail,u=t.resolve,l=t.reject,c=t.domain;try{s?(i||(2==e._h&&M(e),e._h=1),!0===s?n=r:(c&&c.enter(),n=s(r),c&&(c.exit(),o=!0)),n===t.promise?l(w("Promise-chain cycle")):(a=I(n))?a.call(n,u,l):u(n)):l(r)}catch(e){c&&!o&&c.exit(),l(e)}}(n[a++]);e._c=[],e._n=!1,t&&!e._h&&R(e)})}},R=function(e){g.call(u,function(){var t,n,r,i=e._v,a=D(e);if(a&&(t=b(function(){L?k.emit("unhandledRejection",i,e):(n=u.onunhandledrejection)?n({promise:e,reason:i}):(r=u.console)&&r.error&&r.error("Unhandled promise rejection",i)}),e._h=L||D(e)?2:1),e._a=void 0,a&&t.e)throw t.v})},D=function(e){return 1!==e._h&&0===(e._a||e._c).length},M=function(e){g.call(u,function(){var t;L?k.emit("rejectionHandled",e):(t=u.onrejectionhandled)&&t({promise:e,reason:e._v})})},U=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),P(t,!0))},B=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw w("Promise can't be resolved itself");(t=I(e))?y(function(){var r={_w:n,_d:!1};try{t.call(e,l(B,r,1),l(U,r,1))}catch(e){U.call(r,e)}}):(n._v=e,n._s=1,P(n,!1))}catch(e){U.call({_w:n,_d:!1},e)}}};O||(C=function(e){p(this,C,"Promise","_h"),h(e),r.call(this);try{e(l(B,this,1),l(U,this,1))}catch(e){U.call(this,e)}},r=function(e){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("NmAK")(C.prototype,{then:function(e,t){var n=j(v(this,C));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=L?k.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&P(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),a=function(){var e=new r;this.promise=e,this.resolve=l(B,e,1),this.reject=l(U,e,1)},_.f=j=function(e){return e===C||e===o?new a(e):i(e)}),d(d.G+d.W+d.F*!O,{Promise:C}),n("W97E")(C,"Promise"),n("7QiM")("Promise"),o=n("QhVj").Promise,d(d.S+d.F*!O,"Promise",{reject:function(e){var t=j(this);return(0,t.reject)(e),t.promise}}),d(d.S+d.F*(s||!O),"Promise",{resolve:function(e){return S(s&&this===o?C:this,e)}}),d(d.S+d.F*!(O&&n("GAJc")(function(e){C.all(e).catch(x)})),"Promise",{all:function(e){var t=this,n=j(t),r=n.resolve,i=n.reject,a=b(function(){var n=[],a=0,o=1;m(e,!1,function(e){var s=a++,u=!1;n.push(void 0),o++,t.resolve(e).then(function(e){u||(u=!0,n[s]=e,--o||r(n))},i)}),--o||r(n)});return a.e&&i(a.v),n.promise},race:function(e){var t=this,n=j(t),r=n.reject,i=b(function(){m(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return i.e&&r(i.v),n.promise}})},"5VQ+":function(e,t,n){"use strict";var r=n("cGG2");e.exports=function(e,t){r.forEach(e,function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])})}},"5gDf":function(e,t,n){var r=n("U9LJ");n("Iiwq")("isExtensible",function(e){return function(t){return!!r(t)&&(!e||e(t))}})},"5vV0":function(e,t,n){var r=n("/dY/"),i=n("xWqz"),a=n("dWWz");e.exports=function(e){var t=r(e),n=i.f;if(n)for(var o,s=n(e),u=a.f,l=0;s.length>l;)u.call(e,o=s[l++])&&t.push(o);return t}},"6Nc+":function(e,t,n){var r=n("U9LJ"),i=n("QhHn").onFreeze;n("Iiwq")("freeze",function(e){return function(t){return e&&r(t)?e(i(t)):t}})},"6VhL":function(e,t,n){var r=n("1vD2");e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},"6hGG":function(e,t,n){var r=n("94Rb")("wks"),i=n("guD1"),a=n("vR0S").Symbol,o="function"==typeof a;(e.exports=function(e){return r[e]||(r[e]=o&&a[e]||(o?a:i)("Symbol."+e))}).store=r},"6kKt":function(e,t,n){var r=n("eqAp");r(r.S,"Math",{isubh:function(e,t,n,r){var i=e>>>0,a=t>>>0,o=n>>>0;return a-(r>>>0)-((~i&o|~(i^o)&i-o>>>0)>>>31)|0}})},"77Mz":function(e,t,n){var r=n("eqAp"),i=n("IfkE"),a=String.fromCharCode,o=String.fromCodePoint;r(r.S+r.F*(!!o&&1!=o.length),"String",{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,o=0;r>o;){if(t=+arguments[o++],i(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?a(t):a(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},"7GwW":function(e,t,n){"use strict";var r=n("cGG2"),i=n("21It"),a=n("DQCr"),o=n("oJlt"),s=n("GHBc"),u=n("FtD3"),l="undefined"!=typeof window&&window.btoa&&window.btoa.bind(window)||n("thJu");e.exports=function(e){return new Promise(function(t,c){var d=e.data,f=e.headers;r.isFormData(d)&&delete f["Content-Type"];var h=new XMLHttpRequest,p="onreadystatechange",m=!1;if("undefined"==typeof window||!window.XDomainRequest||"withCredentials"in h||s(e.url)||(h=new window.XDomainRequest,p="onload",m=!0,h.onprogress=function(){},h.ontimeout=function(){}),e.auth){var v=e.auth.username||"",g=e.auth.password||"";f.Authorization="Basic "+l(v+":"+g)}if(h.open(e.method.toUpperCase(),a(e.url,e.params,e.paramsSerializer),!0),h.timeout=e.timeout,h[p]=function(){if(h&&(4===h.readyState||m)&&(0!==h.status||h.responseURL&&0===h.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in h?o(h.getAllResponseHeaders()):null,r=e.responseType&&"text"!==e.responseType?h.response:h.responseText,a={data:r,status:1223===h.status?204:h.status,statusText:1223===h.status?"No Content":h.statusText,headers:n,config:e,request:h};i(t,c,a),h=null}},h.onerror=function(){c(u("Network Error",e,null,h)),h=null},h.ontimeout=function(){c(u("timeout of "+e.timeout+"ms exceeded",e,"ECONNABORTED",h)),h=null},r.isStandardBrowserEnv()){var y=n("p1b6"),_=(e.withCredentials||s(e.url))&&e.xsrfCookieName?y.read(e.xsrfCookieName):void 0;_&&(f[e.xsrfHeaderName]=_)}if("setRequestHeader"in h&&r.forEach(f,function(e,t){void 0===d&&"content-type"===t.toLowerCase()?delete f[t]:h.setRequestHeader(t,e)}),e.withCredentials&&(h.withCredentials=!0),e.responseType)try{h.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&h.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&h.upload&&h.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){h&&(h.abort(),c(e),h=null)}),void 0===d&&(d=null),h.send(d)})}},"7QiM":function(e,t,n){"use strict";var r=n("vR0S"),i=n("rBVO"),a=n("8yv5"),o=n("6hGG")("species");e.exports=function(e){var t=r[e];a&&t&&!t[o]&&i.f(t,o,{configurable:!0,get:function(){return this}})}},"7hWC":function(e,t,n){"use strict";var r=n("vR0S"),i=n("3ty/"),a=n("1vD2"),o=n("BDba"),s=n("E2U5"),u=n("HTem"),l=n("XjC+").f,c=n("gWbE").f,d=n("rBVO").f,f=n("XOiX").trim,h=r.Number,p=h,m=h.prototype,v="Number"==a(n("NkR5")(m)),g="trim"in String.prototype,y=function(e){var t=s(e,!1);if("string"==typeof t&&t.length>2){t=g?t.trim():f(t,3);var n,r,i,a=t.charCodeAt(0);if(43===a||45===a){if(88===(n=t.charCodeAt(2))||120===n)return NaN}else if(48===a){switch(t.charCodeAt(1)){case 66:case 98:r=2,i=49;break;case 79:case 111:r=8,i=55;break;default:return+t}for(var o,u=t.slice(2),l=0,c=u.length;l<c;l++)if((o=u.charCodeAt(l))<48||o>i)return NaN;return parseInt(u,r)}}return+t};if(!h(" 0o1")||!h("0b1")||h("+0x1")){h=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof h&&(v?u(function(){m.valueOf.call(n)}):"Number"!=a(n))?o(new p(y(t)),n,h):y(t)};for(var _,b=n("8yv5")?l(p):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),T=0;b.length>T;T++)i(p,_=b[T])&&!i(h,_)&&d(h,_,c(p,_));h.prototype=m,m.constructor=h,n("au66")(r,"Number",h)}},"7oKK":function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(3);r(r.P+r.F*!n("+qBm")([].some,!0),"Array",{some:function(e){return i(this,e,arguments[1])}})},"87Ux":function(e,t,n){"use strict";var r=n("vR0S"),i=n("3ty/"),a=n("8yv5"),o=n("eqAp"),s=n("au66"),u=n("QhHn").KEY,l=n("HTem"),c=n("94Rb"),d=n("W97E"),f=n("guD1"),h=n("6hGG"),p=n("nbAL"),m=n("xU4Q"),v=n("5vV0"),g=n("lwhV"),y=n("PGRs"),_=n("U9LJ"),b=n("xpmJ"),T=n("E2U5"),S=n("D8PY"),w=n("NkR5"),k=n("xH/3"),E=n("gWbE"),A=n("rBVO"),C=n("/dY/"),L=E.f,x=A.f,j=k.f,O=r.Symbol,I=r.JSON,P=I&&I.stringify,R=h("_hidden"),D=h("toPrimitive"),M={}.propertyIsEnumerable,U=c("symbol-registry"),B=c("symbols"),N=c("op-symbols"),F=Object.prototype,V="function"==typeof O,q=r.QObject,G=!q||!q.prototype||!q.prototype.findChild,H=a&&l(function(){return 7!=w(x({},"a",{get:function(){return x(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=L(F,t);r&&delete F[t],x(e,t,n),r&&e!==F&&x(F,t,r)}:x,z=function(e){var t=B[e]=w(O.prototype);return t._k=e,t},W=V&&"symbol"==typeof O.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof O},$=function(e,t,n){return e===F&&$(N,t,n),y(e),t=T(t,!0),y(n),i(B,t)?(n.enumerable?(i(e,R)&&e[R][t]&&(e[R][t]=!1),n=w(n,{enumerable:S(0,!1)})):(i(e,R)||x(e,R,S(1,{})),e[R][t]=!0),H(e,t,n)):x(e,t,n)},Y=function(e,t){y(e);for(var n,r=v(t=b(t)),i=0,a=r.length;a>i;)$(e,n=r[i++],t[n]);return e},K=function(e,t){return void 0===t?w(e):Y(w(e),t)},X=function(e){var t=M.call(this,e=T(e,!0));return!(this===F&&i(B,e)&&!i(N,e))&&(!(t||!i(this,e)||!i(B,e)||i(this,R)&&this[R][e])||t)},J=function(e,t){if(e=b(e),t=T(t,!0),e!==F||!i(B,t)||i(N,t)){var n=L(e,t);return!n||!i(B,t)||i(e,R)&&e[R][t]||(n.enumerable=!0),n}},Q=function(e){for(var t,n=j(b(e)),r=[],a=0;n.length>a;)i(B,t=n[a++])||t==R||t==u||r.push(t);return r},Z=function(e){for(var t,n=e===F,r=j(n?N:b(e)),a=[],o=0;r.length>o;)!i(B,t=r[o++])||n&&!i(F,t)||a.push(B[t]);return a};V||(O=function(){if(this instanceof O)throw TypeError("Symbol is not a constructor!");var e=f(arguments.length>0?arguments[0]:void 0),t=function(n){this===F&&t.call(N,n),i(this,R)&&i(this[R],e)&&(this[R][e]=!1),H(this,e,S(1,n))};return a&&G&&H(F,e,{configurable:!0,set:t}),z(e)},s(O.prototype,"toString",function(){return this._k}),E.f=J,A.f=$,n("XjC+").f=k.f=Q,n("dWWz").f=X,n("xWqz").f=Z,a&&!n("G3Gk")&&s(F,"propertyIsEnumerable",X,!0),p.f=function(e){return z(h(e))}),o(o.G+o.W+o.F*!V,{Symbol:O});for(var ee="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),te=0;ee.length>te;)h(ee[te++]);for(var ne=C(h.store),re=0;ne.length>re;)m(ne[re++]);o(o.S+o.F*!V,"Symbol",{for:function(e){return i(U,e+="")?U[e]:U[e]=O(e)},keyFor:function(e){if(!W(e))throw TypeError(e+" is not a symbol!");for(var t in U)if(U[t]===e)return t},useSetter:function(){G=!0},useSimple:function(){G=!1}}),o(o.S+o.F*!V,"Object",{create:K,defineProperty:$,defineProperties:Y,getOwnPropertyDescriptor:J,getOwnPropertyNames:Q,getOwnPropertySymbols:Z}),I&&o(o.S+o.F*(!V||l(function(){var e=O();return"[null]"!=P([e])||"{}"!=P({a:e})||"{}"!=P(Object(e))})),"JSON",{stringify:function(e){for(var t,n,r=[e],i=1;arguments.length>i;)r.push(arguments[i++]);if(n=t=r[1],(_(t)||void 0!==e)&&!W(e))return g(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!W(t))return t}),r[1]=t,P.apply(I,r)}}),O.prototype[D]||n("CfIS")(O.prototype,D,O.prototype.valueOf),d(O,"Symbol"),d(Math,"Math",!0),d(r.JSON,"JSON",!0)},"8ApB":function(e,t,n){var r=n("eqAp"),i=n("T9ir");r(r.S+r.F*(i!=Math.expm1),"Math",{expm1:i})},"8VQU":function(e,t,n){n("8yv5")&&"g"!=/./g.flags&&n("rBVO").f(RegExp.prototype,"flags",{configurable:!0,get:n("AQEt")})},"8gt8":function(e,t,n){"use strict";var r=n("PGRs"),i=n("AeeY"),a=n("J5DO"),o=n("sxvG"),s=n("jLAN"),u=n("Zn18"),l=Math.max,c=Math.min,d=Math.floor,f=/\$([$&`']|\d\d?|<[^>]*>)/g,h=/\$([$&`']|\d\d?)/g,p=function(e){return void 0===e?e:String(e)};n("UIZt")("replace",2,function(e,t,n,m){function v(e,t,r,a,o,s){var u=r+e.length,l=a.length,c=h;return void 0!==o&&(o=i(o),c=f),n.call(s,c,function(n,i){var s;switch(i.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,r);case"'":return t.slice(u);case"<":s=o[i.slice(1,-1)];break;default:var c=+i;if(0===c)return n;if(c>l){var f=d(c/10);return 0===f?n:f<=l?void 0===a[f-1]?i.charAt(1):a[f-1]+i.charAt(1):n}s=a[c-1]}return void 0===s?"":s})}return[function(r,i){var a=e(this),o=void 0==r?void 0:r[t];return void 0!==o?o.call(r,a,i):n.call(String(a),r,i)},function(e,t){var i=m(n,e,this,t);if(i.done)return i.value;var d=r(e),f=String(this),h="function"==typeof t;h||(t=String(t));var g=d.global;if(g){var y=d.unicode;d.lastIndex=0}for(var _=[];;){var b=u(d,f);if(null===b)break;if(_.push(b),!g)break;""===String(b[0])&&(d.lastIndex=s(f,a(d.lastIndex),y))}for(var T="",S=0,w=0;w<_.length;w++){b=_[w];for(var k=String(b[0]),E=l(c(o(b.index),f.length),0),A=[],C=1;C<b.length;C++)A.push(p(b[C]));var L=b.groups;if(h){var x=[k].concat(A,E,f);void 0!==L&&x.push(L);var j=String(t.apply(void 0,x))}else j=v(k,f,E,A,L,t);E>=S&&(T+=f.slice(S,E)+j,S=E+k.length)}return T+f.slice(S)}]})},"8rdt":function(e,t,n){var r=n("PGRs"),i=n("B63G"),a=n("6hGG")("species");e.exports=function(e,t){var n,o=r(e).constructor;return void 0===o||void 0==(n=r(o)[a])?t:i(n)}},"8yv5":function(e,t,n){e.exports=!n("HTem")(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},"935F":function(e,t,n){var r=n("eqAp"),i=n("gWbE").f,a=n("PGRs");r(r.S,"Reflect",{deleteProperty:function(e,t){var n=i(a(e),t);return!(n&&!n.configurable)&&delete e[t]}})},"94Rb":function(e,t,n){var r=n("QhVj"),i=n("vR0S"),a=i["__core-js_shared__"]||(i["__core-js_shared__"]={});(e.exports=function(e,t){return a[e]||(a[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:n("G3Gk")?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},"9XDH":function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(5),a=!0;"find"in[]&&Array(1).find(function(){a=!1}),r(r.P+r.F*a,"Array",{find:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n("5BZE")("find")},"9dbO":function(e,t,n){var r=n("94Rb")("keys"),i=n("guD1");e.exports=function(e){return r[e]||(r[e]=i(e))}},"9nZh":function(e,t,n){var r=n("pqvg");e.exports=function(e,t){return new(r(e))(t)}},A0jK:function(e,t,n){var r=n("eqAp"),i=n("HAfA");i&&r(r.S,"Reflect",{setPrototypeOf:function(e,t){i.check(e,t);try{return i.set(e,t),!0}catch(e){return!1}}})},AIRG:function(e,t,n){var r=n("3ty/"),i=n("xpmJ"),a=n("VqU3")(!1),o=n("9dbO")("IE_PROTO");e.exports=function(e,t){var n,s=i(e),u=0,l=[];for(n in s)n!=o&&r(s,n)&&l.push(n);for(;t.length>u;)r(s,n=t[u++])&&(~a(l,n)||l.push(n));return l}},AQEt:function(e,t,n){"use strict";var r=n("PGRs");e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},"AX+V":function(e,t,n){n("7QiM")("Array")},AeeY:function(e,t,n){var r=n("VmoO");e.exports=function(e){return Object(r(e))}},Akkh:function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(2);r(r.P+r.F*!n("+qBm")([].filter,!0),"Array",{filter:function(e){return i(this,e,arguments[1])}})},AtpX:function(e,t,n){var r=n("6hGG")("toPrimitive"),i=Date.prototype;r in i||n("CfIS")(i,r,n("FMRs"))},Au7w:function(e,t,n){for(var r,i=n("vR0S"),a=n("CfIS"),o=n("guD1"),s=o("typed_array"),u=o("view"),l=!(!i.ArrayBuffer||!i.DataView),c=l,d=0,f="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");d<9;)(r=i[f[d++]])?(a(r.prototype,s,!0),a(r.prototype,u,!0)):c=!1;e.exports={ABV:l,CONSTR:c,TYPED:s,VIEW:u}},B63G:function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},BDba:function(e,t,n){var r=n("U9LJ"),i=n("HAfA").set;e.exports=function(e,t,n){var a,o=t.constructor;return o!==n&&"function"==typeof o&&(a=o.prototype)!==n.prototype&&r(a)&&i&&i(e,a),e}},BHN6:function(e,t,n){"use strict";function r(e,t,n,l,c,d,f,h){for(var p,m,v=c,g=0,y=!!f&&s(f,h,3);g<l;){if(g in n){if(p=y?y(n[g],g,t):n[g],m=!1,a(p)&&(m=p[u],m=void 0!==m?!!m:i(p)),m&&d>0)v=r(e,t,p,o(p.length),v,d-1)-1;else{if(v>=9007199254740991)throw TypeError();e[v]=p}v++}g++}return v}var i=n("lwhV"),a=n("U9LJ"),o=n("J5DO"),s=n("wRig"),u=n("6hGG")("isConcatSpreadable");e.exports=r},CLCt:function(e,t){!function(e,t){"use strict";function n(){var e=C.splice(0,C.length);for(et=0;e.length;)e.shift().call(null,e.shift())}function r(e,t){for(var n=0,r=e.length;n<r;n++)v(e[n],t)}function i(e){for(var t,n=0,r=e.length;n<r;n++)t=e[n],R(t,oe[o(t)])}function a(e){return function(t){Ne(t)&&(v(t,e),se.length&&r(t.querySelectorAll(se),e))}}function o(e){var t=ze.call(e,"is"),n=e.nodeName.toUpperCase(),r=le.call(ae,t?ne+t.toUpperCase():te+n);return t&&-1<r&&!s(n,t)?-1:r}function s(e,t){return-1<se.indexOf(e+'[is="'+t+'"]')}function u(e){var t=e.currentTarget,n=e.attrChange,r=e.attrName,i=e.target,a=e[X]||2,o=e[J]||3;!ot||i&&i!==t||!t[H]||"style"===r||e.prevValue===e.newValue&&(""!==e.newValue||n!==a&&n!==o)||t[H](r,n===a?null:e.prevValue,n===o?null:e.newValue)}function l(e){var t=a(e);return function(e){C.push(t,e.target),et&&clearTimeout(et),et=setTimeout(n,1)}}function c(e){at&&(at=!1,e.currentTarget.removeEventListener(Z,c)),se.length&&r((e.target||k).querySelectorAll(se),e.detail===q?q:F),Ue&&p()}function d(e,t){var n=this;Ye.call(n,e,t),L.call(n,{target:n})}function f(e,t,n){var r=t.apply(e,n),a=o(r);return-1<a&&R(r,oe[a]),n.pop()&&se.length&&i(r.querySelectorAll(se)),r}function h(e,t){Pe(e,t),O?O.observe(e,Qe):(it&&(e.setAttribute=d,e[B]=j(e),e[N](ee,L)),e[N](Q,u)),e[Y]&&ot&&(e.created=!0,e[Y](),e.created=!1)}function p(){for(var e,t=0,n=Fe.length;t<n;t++)e=Fe[t],ue.contains(e)||(n--,Fe.splice(t--,1),v(e,q))}function m(e){throw new Error("A "+e+" type is already registered")}function v(e,t){var n,r,i=o(e);-1<i&&!Ge.call(e,"TEMPLATE")&&(P(e,oe[i]),i=0,t!==F||e[F]?t!==q||e[q]||(e[F]=!1,e[q]=!0,r="disconnected",i=1):(e[q]=!1,e[F]=!0,r="connected",i=1,Ue&&le.call(Fe,e)<0&&Fe.push(e)),i&&(n=e[t+V]||e[r+V])&&n.call(e))}function g(){}function y(e,t,n){var r=n&&n[G]||"",i=t.prototype,a=Ie(i),o=t.observedAttributes||pe,s={prototype:a};Be(a,Y,{value:function(){if(Ce)Ce=!1;else if(!this[Te]){this[Te]=!0,new t(this),i[Y]&&i[Y].call(this);var e=Le[je.get(t)];(!we||e.create.length>1)&&T(this)}}}),Be(a,H,{value:function(e){-1<le.call(o,e)&&i[H]&&i[H].apply(this,arguments)}}),i[W]&&Be(a,z,{value:i[W]}),i[$]&&Be(a,K,{value:i[$]}),r&&(s[G]=r),e=e.toUpperCase(),Le[e]={constructor:t,create:r?[r,Oe(e)]:[e]},je.set(t,e),k[M](e.toLowerCase(),s),S(e),xe[e].r()}function _(e){var t=Le[e.toUpperCase()];return t&&t.constructor}function b(e){return"string"==typeof e?e:e&&e.is||""}function T(e){for(var t,n=e[H],r=n?e.attributes:pe,i=r.length;i--;)t=r[i],n.call(e,t.name||t.nodeName,null,t.value||t.nodeValue)}function S(e){return e=e.toUpperCase(),e in xe||(xe[e]={},xe[e].p=new Ae(function(t){xe[e].r=t})),xe[e].p}function w(){Se&&delete e.customElements,he(e,"customElements",{configurable:!0,value:new g}),he(e,"CustomElementRegistry",{configurable:!0,value:g});for(var t=A.get(/^HTML[A-Z]*[a-z]/),n=t.length;n--;function(t){var n=e[t];if(n){e[t]=function(e){var t,r;return e||(e=this),e[Te]||(Ce=!0,t=Le[je.get(e.constructor)],r=we&&1===t.create.length,e=r?Reflect.construct(n,pe,t.constructor):k.createElement.apply(k,t.create),e[Te]=!0,Ce=!1,r||T(e)),e},e[t].prototype=n.prototype;try{n.prototype.constructor=e[t]}catch(r){be=!0,he(n,Te,{value:e[t]})}}}(t[n]));k.createElement=function(e,t){var n=b(t);return n?Je.call(this,e,Oe(n)):Je.call(this,e)},tt||(rt=!0,k[M](""))}var k=e.document,E=e.Object,A=function(e){var t,n,r,i,a=/^[A-Z]+[a-z]/,o=function(e){var t,n=[];for(t in u)e.test(t)&&n.push(t);return n},s=function(e,t){(t=t.toLowerCase())in u||(u[e]=(u[e]||[]).concat(t),u[t]=u[t.toUpperCase()]=e)},u=(E.create||E)(null),l={};for(n in e)for(i in e[n])for(r=e[n][i],u[i]=r,t=0;t<r.length;t++)u[r[t].toLowerCase()]=u[r[t].toUpperCase()]=i;return l.get=function(e){return"string"==typeof e?u[e]||(a.test(e)?[]:""):o(e)},l.set=function(e,t){return a.test(e)?s(e,t):s(t,e),l},l}({collections:{HTMLAllCollection:["all"],HTMLCollection:["forms"],HTMLFormControlsCollection:["elements"],HTMLOptionsCollection:["options"]},elements:{Element:["element"],HTMLAnchorElement:["a"],HTMLAppletElement:["applet"],HTMLAreaElement:["area"],HTMLAttachmentElement:["attachment"],HTMLAudioElement:["audio"],HTMLBRElement:["br"],HTMLBaseElement:["base"],HTMLBodyElement:["body"],HTMLButtonElement:["button"],HTMLCanvasElement:["canvas"],HTMLContentElement:["content"],HTMLDListElement:["dl"],HTMLDataElement:["data"],HTMLDataListElement:["datalist"],HTMLDetailsElement:["details"],HTMLDialogElement:["dialog"],HTMLDirectoryElement:["dir"],HTMLDivElement:["div"],HTMLDocument:["document"],HTMLElement:["element","abbr","address","article","aside","b","bdi","bdo","cite","code","command","dd","dfn","dt","em","figcaption","figure","footer","header","i","kbd","mark","nav","noscript","rp","rt","ruby","s","samp","section","small","strong","sub","summary","sup","u","var","wbr"],HTMLEmbedElement:["embed"],HTMLFieldSetElement:["fieldset"],HTMLFontElement:["font"],HTMLFormElement:["form"],HTMLFrameElement:["frame"],HTMLFrameSetElement:["frameset"],HTMLHRElement:["hr"],HTMLHeadElement:["head"],HTMLHeadingElement:["h1","h2","h3","h4","h5","h6"],HTMLHtmlElement:["html"],HTMLIFrameElement:["iframe"],HTMLImageElement:["img"],HTMLInputElement:["input"],HTMLKeygenElement:["keygen"],HTMLLIElement:["li"],HTMLLabelElement:["label"],HTMLLegendElement:["legend"],HTMLLinkElement:["link"],HTMLMapElement:["map"],HTMLMarqueeElement:["marquee"],HTMLMediaElement:["media"],HTMLMenuElement:["menu"],HTMLMenuItemElement:["menuitem"],HTMLMetaElement:["meta"],HTMLMeterElement:["meter"],HTMLModElement:["del","ins"],HTMLOListElement:["ol"],HTMLObjectElement:["object"],HTMLOptGroupElement:["optgroup"],HTMLOptionElement:["option"],HTMLOutputElement:["output"],HTMLParagraphElement:["p"],HTMLParamElement:["param"],HTMLPictureElement:["picture"],HTMLPreElement:["pre"],HTMLProgressElement:["progress"],HTMLQuoteElement:["blockquote","q","quote"],HTMLScriptElement:["script"],HTMLSelectElement:["select"],HTMLShadowElement:["shadow"],HTMLSlotElement:["slot"],HTMLSourceElement:["source"],HTMLSpanElement:["span"],HTMLStyleElement:["style"],HTMLTableCaptionElement:["caption"],HTMLTableCellElement:["td","th"],HTMLTableColElement:["col","colgroup"],HTMLTableElement:["table"],HTMLTableRowElement:["tr"],HTMLTableSectionElement:["thead","tbody","tfoot"],HTMLTemplateElement:["template"],HTMLTextAreaElement:["textarea"],HTMLTimeElement:["time"],HTMLTitleElement:["title"],HTMLTrackElement:["track"],HTMLUListElement:["ul"],HTMLUnknownElement:["unknown","vhgroupv","vkeygen"],HTMLVideoElement:["video"]},nodes:{Attr:["node"],Audio:["audio"],CDATASection:["node"],CharacterData:["node"],Comment:["#comment"],Document:["#document"],DocumentFragment:["#document-fragment"],DocumentType:["node"],HTMLDocument:["#document"],Image:["img"],Option:["option"],ProcessingInstruction:["node"],ShadowRoot:["#shadow-root"],Text:["#text"],XMLDocument:["xml"]}});"object"!=typeof t&&(t={type:t||"auto"});var C,L,x,j,O,I,P,R,D,M="registerElement",U=1e5*e.Math.random()>>0,B="__"+M+U,N="addEventListener",F="attached",V="Callback",q="detached",G="extends",H="attributeChanged"+V,z=F+V,W="connected"+V,$="disconnected"+V,Y="created"+V,K=q+V,X="ADDITION",J="REMOVAL",Q="DOMAttrModified",Z="DOMContentLoaded",ee="DOMSubtreeModified",te="<",ne="=",re=/^[A-Z][._A-Z0-9]*-[-._A-Z0-9]*$/,ie=["ANNOTATION-XML","COLOR-PROFILE","FONT-FACE","FONT-FACE-SRC","FONT-FACE-URI","FONT-FACE-FORMAT","FONT-FACE-NAME","MISSING-GLYPH"],ae=[],oe=[],se="",ue=k.documentElement,le=ae.indexOf||function(e){for(var t=this.length;t--&&this[t]!==e;);return t},ce=E.prototype,de=ce.hasOwnProperty,fe=ce.isPrototypeOf,he=E.defineProperty,pe=[],me=E.getOwnPropertyDescriptor,ve=E.getOwnPropertyNames,ge=E.getPrototypeOf,ye=E.setPrototypeOf,_e=!!E.__proto__,be=!1,Te="__dreCEv1",Se=e.customElements,we=!/^force/.test(t.type)&&!!(Se&&Se.define&&Se.get&&Se.whenDefined),ke=E.create||E,Ee=e.Map||function(){var e,t=[],n=[];return{get:function(e){return n[le.call(t,e)]},set:function(r,i){e=le.call(t,r),e<0?n[t.push(r)-1]=i:n[e]=i}}},Ae=e.Promise||function(e){function t(e){for(r=!0;n.length;)n.shift()(e)}var n=[],r=!1,i={catch:function(){return i},then:function(e){return n.push(e),r&&setTimeout(t,1),i}};return e(t),i},Ce=!1,Le=ke(null),xe=ke(null),je=new Ee,Oe=function(e){return e.toLowerCase()},Ie=E.create||function e(t){return t?(e.prototype=t,new e):this},Pe=ye||(_e?function(e,t){return e.__proto__=t,e}:ve&&me?function(){function e(e,t){for(var n,r=ve(t),i=0,a=r.length;i<a;i++)n=r[i],de.call(e,n)||he(e,n,me(t,n))}return function(t,n){do{e(t,n)}while((n=ge(n))&&!fe.call(n,t));return t}}():function(e,t){for(var n in t)e[n]=t[n];return e}),Re=e.MutationObserver||e.WebKitMutationObserver,De=e.HTMLAnchorElement,Me=(e.HTMLElement||e.Element||e.Node).prototype,Ue=!fe.call(Me,ue),Be=Ue?function(e,t,n){return e[t]=n.value,e}:he,Ne=Ue?function(e){return 1===e.nodeType}:function(e){return fe.call(Me,e)},Fe=Ue&&[],Ve=Me.attachShadow,qe=Me.cloneNode,Ge=Me.closest||function(e){for(var t=this;t&&t.nodeName!==e;)t=t.parentNode;return t},He=Me.dispatchEvent,ze=Me.getAttribute,We=Me.hasAttribute,$e=Me.removeAttribute,Ye=Me.setAttribute,Ke=k.createElement,Xe=k.importNode,Je=Ke,Qe=Re&&{attributes:!0,characterData:!0,attributeOldValue:!0},Ze=Re||function(e){it=!1,ue.removeEventListener(Q,Ze)},et=0,tt=M in k&&!/^force-all/.test(t.type),nt=!0,rt=!1,it=!0,at=!0,ot=!0;if(Re&&(D=k.createElement("div"),D.innerHTML="<div><div></div></div>",new Re(function(e,t){if(e[0]&&"childList"==e[0].type&&!e[0].removedNodes[0].childNodes.length){D=me(Me,"innerHTML");var n=D&&D.set;n&&he(Me,"innerHTML",{set:function(e){for(;this.lastChild;)this.removeChild(this.lastChild);n.call(this,e)}})}t.disconnect(),D=null}).observe(D,{childList:!0,subtree:!0}),D.innerHTML=""),tt||(ye||_e?(P=function(e,t){fe.call(t,e)||h(e,t)},R=h):(P=function(e,t){e[B]||(e[B]=E(!0),h(e,t))},R=P),Ue?(it=!1,function(){var e=me(Me,N),t=e.value,n=function(e){var t=new CustomEvent(Q,{bubbles:!0});t.attrName=e,t.prevValue=ze.call(this,e),t.newValue=null,t[J]=t.attrChange=2,$e.call(this,e),He.call(this,t)},r=function(e,t){var n=We.call(this,e),r=n&&ze.call(this,e),i=new CustomEvent(Q,{bubbles:!0});Ye.call(this,e,t),i.attrName=e,i.prevValue=n?r:null,i.newValue=t,n?i.MODIFICATION=i.attrChange=1:i[X]=i.attrChange=0,He.call(this,i)},i=function(e){var t,n=e.currentTarget,r=n[B],i=e.propertyName;r.hasOwnProperty(i)&&(r=r[i],t=new CustomEvent(Q,{bubbles:!0}),t.attrName=r.name,t.prevValue=r.value||null,t.newValue=r.value=n[i]||null,null==t.prevValue?t[X]=t.attrChange=0:t.MODIFICATION=t.attrChange=1,He.call(n,t))};e.value=function(e,a,o){e===Q&&this[H]&&this.setAttribute!==r&&(this[B]={className:{name:"class",value:this.className}},this.setAttribute=r,this.removeAttribute=n,t.call(this,"propertychange",i)),t.call(this,e,a,o)},he(Me,N,e)}()):Re||(ue[N](Q,Ze),ue.setAttribute(B,1),ue.removeAttribute(B),it&&(L=function(e){var t,n,r,i=this;if(i===e.target){t=i[B],i[B]=n=j(i);for(r in n){if(!(r in t))return x(0,i,r,t[r],n[r],X);if(n[r]!==t[r])return x(1,i,r,t[r],n[r],"MODIFICATION")}for(r in t)if(!(r in n))return x(2,i,r,t[r],n[r],J)}},x=function(e,t,n,r,i,a){var o={attrChange:e,currentTarget:t,attrName:n,prevValue:r,newValue:i};o[a]=e,u(o)},j=function(e){for(var t,n,r={},i=e.attributes,a=0,o=i.length;a<o;a++)t=i[a],"setAttribute"!==(n=t.name)&&(r[n]=t.value);return r})),k[M]=function(e,t){if(n=e.toUpperCase(),nt&&(nt=!1,Re?(O=function(e,t){function n(e,t){for(var n=0,r=e.length;n<r;t(e[n++]));}return new Re(function(r){for(var i,a,o,s=0,u=r.length;s<u;s++)i=r[s],"childList"===i.type?(n(i.addedNodes,e),n(i.removedNodes,t)):(a=i.target,ot&&a[H]&&"style"!==i.attributeName&&(o=ze.call(a,i.attributeName))!==i.oldValue&&a[H](i.attributeName,i.oldValue,o))})}(a(F),a(q)),I=function(e){return O.observe(e,{childList:!0,subtree:!0}),e},I(k),Ve&&(Me.attachShadow=function(){return I(Ve.apply(this,arguments))})):(C=[],k[N]("DOMNodeInserted",l(F)),k[N]("DOMNodeRemoved",l(q))),k[N](Z,c),k[N]("readystatechange",c),k.importNode=function(e,t){switch(e.nodeType){case 1:return f(k,Xe,[e,!!t]);case 11:for(var n=k.createDocumentFragment(),r=e.childNodes,i=r.length,a=0;a<i;a++)n.appendChild(k.importNode(r[a],!!t));return n;default:return qe.call(e,!!t)}},Me.cloneNode=function(e){return f(this,qe,[!!e])}),rt)return rt=!1;if(-2<le.call(ae,ne+n)+le.call(ae,te+n)&&m(e),!re.test(n)||-1<le.call(ie,n))throw new Error("The type "+e+" is invalid");var n,i,o=function(){return u?k.createElement(d,n):k.createElement(d)},s=t||ce,u=de.call(s,G),d=u?t[G].toUpperCase():n;return u&&-1<le.call(ae,te+d)&&m(d),i=ae.push((u?ne:te)+n)-1,se=se.concat(se.length?",":"",u?d+'[is="'+e.toLowerCase()+'"]':d),o.prototype=oe[i]=de.call(s,"prototype")?s.prototype:Ie(Me),se.length&&r(k.querySelectorAll(se),F),o},k.createElement=Je=function(e,t){var n=b(t),r=n?Ke.call(k,e,Oe(n)):Ke.call(k,e),i=""+e,a=le.call(ae,(n?ne:te)+(n||i).toUpperCase()),o=-1<a;return n&&(r.setAttribute("is",n=n.toLowerCase()),o&&(o=s(i.toUpperCase(),n))),ot=!k.createElement.innerHTMLHelper,o&&R(r,oe[a]),r}),addEventListener("beforeunload",function(){delete k.createElement,delete k.importNode,delete k[M]},!1),g.prototype={constructor:g,define:we?function(e,t,n){if(n)y(e,t,n);else{var r=e.toUpperCase();Le[r]={constructor:t,create:[r]},je.set(t,r),Se.define(e,t)}}:y,get:we?function(e){return Se.get(e)||_(e)}:_,whenDefined:we?function(e){return Ae.race([Se.whenDefined(e),S(e)])}:S},!Se||/^force/.test(t.type))w();else if(!t.noBuiltIn)try{!function(t,n,r){var i=new RegExp("^<a\\s+is=('|\")"+r+"\\1></a>$");if(n[G]="a",t.prototype=Ie(De.prototype),t.prototype.constructor=t,e.customElements.define(r,t,n),!i.test(k.createElement("a",{is:r}).outerHTML)||!i.test((new t).outerHTML))throw n}(function e(){return Reflect.construct(De,[],e)},{},"document-register-element-a"+U)}catch(e){w()}if(!t.noBuiltIn)try{if(Ke.call(k,"a","a").outerHTML.indexOf("is")<0)throw{}}catch(e){Oe=function(e){return{is:e.toLowerCase()}}}}(window)},CMSL:function(e,t,n){"use strict";var r=n("eqAp"),i=n("RvsJ");r(r.S+r.F*n("HTem")(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)i(n,e,arguments[e++]);return n.length=t,n}})},CYr4:function(e,t,n){var r=n("xpmJ"),i=n("gWbE").f;n("Iiwq")("getOwnPropertyDescriptor",function(){return function(e,t){return i(r(e),t)}})},CfIS:function(e,t,n){var r=n("rBVO"),i=n("D8PY");e.exports=n("8yv5")?function(e,t,n){return r.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},D8PY:function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},D8lc:function(e,t,n){var r=n("rBVO"),i=n("eqAp"),a=n("PGRs"),o=n("E2U5");i(i.S+i.F*n("HTem")(function(){Reflect.defineProperty(r.f({},1,{value:1}),1,{value:2})}),"Reflect",{defineProperty:function(e,t,n){a(e),t=o(t,!0),a(n);try{return r.f(e,t,n),!0}catch(e){return!1}}})},DQCr:function(e,t,n){"use strict";function r(e){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var i=n("cGG2");e.exports=function(e,t,n){if(!t)return e;var a;if(n)a=n(t);else if(i.isURLSearchParams(t))a=t.toString();else{var o=[];i.forEach(t,function(e,t){null!==e&&void 0!==e&&(i.isArray(e)&&(t+="[]"),i.isArray(e)||(e=[e]),i.forEach(e,function(e){i.isDate(e)?e=e.toISOString():i.isObject(e)&&(e=JSON.stringify(e)),o.push(r(t)+"="+r(e))}))}),a=o.join("&")}return a&&(e+=(-1===e.indexOf("?")?"?":"&")+a),e}},DfOq:function(e,t,n){var r=n("eqAp"),i=n("1vD2");r(r.S,"Error",{isError:function(e){return"Error"===i(e)}})},DuR2:function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},E2U5:function(e,t,n){var r=n("U9LJ");e.exports=function(e,t){if(!r(e))return e;var n,i;if(t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;if("function"==typeof(n=e.valueOf)&&!r(i=n.call(e)))return i;if(!t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},E3Zq:function(e,t,n){var r=n("rBVO"),i=n("PGRs"),a=n("/dY/");e.exports=n("8yv5")?Object.defineProperties:function(e,t){i(e);for(var n,o=a(t),s=o.length,u=0;s>u;)r.f(e,n=o[u++],t[n]);return e}},E3yU:function(e,t,n){var r=n("vR0S"),i=n("XJA6").set,a=r.MutationObserver||r.WebKitMutationObserver,o=r.process,s=r.Promise,u="process"==n("1vD2")(o);e.exports=function(){var e,t,n,l=function(){var r,i;for(u&&(r=o.domain)&&r.exit();e;){i=e.fn,e=e.next;try{i()}catch(r){throw e?n():t=void 0,r}}t=void 0,r&&r.enter()};if(u)n=function(){o.nextTick(l)};else if(!a||r.navigator&&r.navigator.standalone)if(s&&s.resolve){var c=s.resolve(void 0);n=function(){c.then(l)}}else n=function(){i.call(r,l)};else{var d=!0,f=document.createTextNode("");new a(l).observe(f,{characterData:!0}),n=function(){f.data=d=!d}}return function(r){var i={fn:r,next:void 0};t&&(t.next=i),e||(e=i,n()),t=i}}},E5Nd:function(e,t,n){var r=n("eqAp"),i=n("XJA6");r(r.G+r.B,{setImmediate:i.set,clearImmediate:i.clear})},EAuC:function(e,t,n){"use strict";var r=n("AeeY"),i=n("IfkE"),a=n("J5DO");e.exports=[].copyWithin||function(e,t){var n=r(this),o=a(n.length),s=i(e,o),u=i(t,o),l=arguments.length>2?arguments[2]:void 0,c=Math.min((void 0===l?o:i(l,o))-u,o-s),d=1;for(u<s&&s<u+c&&(d=-1,u+=c-1,s+=c-1);c-- >0;)u in n?n[s]=n[u]:delete n[s],s+=d,u+=d;return n}},ESkD:function(e,t,n){"use strict";var r=n("eqAp"),i=n("bFIN")(!1);r(r.P,"String",{codePointAt:function(e){return i(this,e)}})},Ee0C:function(e,t,n){"use strict";function r(e,t,n){var r,i,a,o=new Array(n),s=8*n-t-1,u=(1<<s)-1,l=u>>1,c=23===t?B(2,-24)-B(2,-77):0,d=0,f=e<0||0===e&&1/e<0?1:0;for(e=U(e),e!=e||e===D?(i=e!=e?1:0,r=u):(r=N(F(e)/V),e*(a=B(2,-r))<1&&(r--,a*=2),e+=r+l>=1?c/a:c*B(2,1-l),e*a>=2&&(r++,a/=2),r+l>=u?(i=0,r=u):r+l>=1?(i=(e*a-1)*B(2,t),r+=l):(i=e*B(2,l-1)*B(2,t),r=0));t>=8;o[d++]=255&i,i/=256,t-=8);for(r=r<<t|i,s+=t;s>0;o[d++]=255&r,r/=256,s-=8);return o[--d]|=128*f,o}function i(e,t,n){var r,i=8*n-t-1,a=(1<<i)-1,o=a>>1,s=i-7,u=n-1,l=e[u--],c=127&l;for(l>>=7;s>0;c=256*c+e[u],u--,s-=8);for(r=c&(1<<-s)-1,c>>=-s,s+=t;s>0;r=256*r+e[u],u--,s-=8);if(0===c)c=1-o;else{if(c===a)return r?NaN:l?-D:D;r+=B(2,t),c-=o}return(l?-1:1)*r*B(2,c-t)}function a(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function o(e){return[255&e]}function s(e){return[255&e,e>>8&255]}function u(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function l(e){return r(e,52,8)}function c(e){return r(e,23,4)}function d(e,t,n){A(e[x],t,{get:function(){return this[n]}})}function f(e,t,n,r){var i=+n,a=k(i);if(a+t>e[G])throw R(j);var o=e[q]._b,s=a+e[H],u=o.slice(s,s+t);return r?u:u.reverse()}function h(e,t,n,r,i,a){var o=+n,s=k(o);if(s+t>e[G])throw R(j);for(var u=e[q]._b,l=s+e[H],c=r(+i),d=0;d<t;d++)u[l+d]=c[a?d:t-d-1]}var p=n("vR0S"),m=n("8yv5"),v=n("G3Gk"),g=n("Au7w"),y=n("CfIS"),_=n("NmAK"),b=n("HTem"),T=n("S5no"),S=n("sxvG"),w=n("J5DO"),k=n("4oJ4"),E=n("XjC+").f,A=n("rBVO").f,C=n("T8YM"),L=n("W97E"),x="prototype",j="Wrong index!",O=p.ArrayBuffer,I=p.DataView,P=p.Math,R=p.RangeError,D=p.Infinity,M=O,U=P.abs,B=P.pow,N=P.floor,F=P.log,V=P.LN2,q=m?"_b":"buffer",G=m?"_l":"byteLength",H=m?"_o":"byteOffset";if(g.ABV){if(!b(function(){O(1)})||!b(function(){new O(-1)})||b(function(){return new O,new O(1.5),new O(NaN),"ArrayBuffer"!=O.name})){O=function(e){return T(this,O),new M(k(e))};for(var z,W=O[x]=M[x],$=E(M),Y=0;$.length>Y;)(z=$[Y++])in O||y(O,z,M[z]);v||(W.constructor=O)}var K=new I(new O(2)),X=I[x].setInt8;K.setInt8(0,2147483648),K.setInt8(1,2147483649),!K.getInt8(0)&&K.getInt8(1)||_(I[x],{setInt8:function(e,t){X.call(this,e,t<<24>>24)},setUint8:function(e,t){X.call(this,e,t<<24>>24)}},!0)}else O=function(e){T(this,O,"ArrayBuffer");var t=k(e);this._b=C.call(new Array(t),0),this[G]=t},I=function(e,t,n){T(this,I,"DataView"),T(e,O,"DataView");var r=e[G],i=S(t);if(i<0||i>r)throw R("Wrong offset!");if(n=void 0===n?r-i:w(n),i+n>r)throw R("Wrong length!");this[q]=e,this[H]=i,this[G]=n},m&&(d(O,"byteLength","_l"),d(I,"buffer","_b"),d(I,"byteLength","_l"),d(I,"byteOffset","_o")),_(I[x],{getInt8:function(e){return f(this,1,e)[0]<<24>>24},getUint8:function(e){return f(this,1,e)[0]},getInt16:function(e){var t=f(this,2,e,arguments[1]);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=f(this,2,e,arguments[1]);return t[1]<<8|t[0]},getInt32:function(e){return a(f(this,4,e,arguments[1]))},getUint32:function(e){return a(f(this,4,e,arguments[1]))>>>0},getFloat32:function(e){return i(f(this,4,e,arguments[1]),23,4)},getFloat64:function(e){return i(f(this,8,e,arguments[1]),52,8)},setInt8:function(e,t){h(this,1,e,o,t)},setUint8:function(e,t){h(this,1,e,o,t)},setInt16:function(e,t){h(this,2,e,s,t,arguments[2])},setUint16:function(e,t){h(this,2,e,s,t,arguments[2])},setInt32:function(e,t){h(this,4,e,u,t,arguments[2])},setUint32:function(e,t){h(this,4,e,u,t,arguments[2])},setFloat32:function(e,t){h(this,4,e,c,t,arguments[2])},setFloat64:function(e,t){h(this,8,e,l,t,arguments[2])}});L(O,"ArrayBuffer"),L(I,"DataView"),y(I[x],g.VIEW,!0),t.ArrayBuffer=O,t.DataView=I},Egxl:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{signbit:function(e){return(e=+e)!=e?e:0==e?1/e==1/0:e>0}})},EmrZ:function(e,t,n){var r=n("eqAp");r(r.S,"Number",{isInteger:n("nCxY")})},EqqB:function(e,t,n){var r=n("eqAp");r(r.S,"Object",{is:n("wNcl")})},Eseb:function(e,t,n){var r=n("eqAp");r(r.S+r.F*!n("8yv5"),"Object",{defineProperties:n("E3Zq")})},EyN7:function(e,t,n){var r=n("eqAp");r(r.P+r.R,"Map",{toJSON:n("j/BO")("Map")})},FAzY:function(e,t,n){var r=n("eqAp"),i=Math.exp;r(r.S,"Math",{cosh:function(e){return(i(e=+e)+i(-e))/2}})},FD60:function(e,t,n){var r=n("znM9");"string"==typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals);n("rjj0")("7c2b8340",r,!0,{})},FMRs:function(e,t,n){"use strict";var r=n("PGRs"),i=n("E2U5");e.exports=function(e){if("string"!==e&&"number"!==e&&"default"!==e)throw TypeError("Incorrect hint");return i(r(this),"number"!=e)}},FWVt:function(e,t,n){var r=n("eqAp");r(r.P,"Array",{fill:n("T8YM")}),n("5BZE")("fill")},"FZ+f":function(e,t){function n(e,t){var n=e[1]||"",i=e[3];if(!i)return n;if(t&&"function"==typeof btoa){var a=r(i);return[n].concat(i.sources.map(function(e){return"/*# sourceURL="+i.sourceRoot+e+" */"})).concat([a]).join("\n")}return[n].join("\n")}function r(e){return"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */"}e.exports=function(e){var t=[];return t.toString=function(){return this.map(function(t){var r=n(t,e);return t[2]?"@media "+t[2]+"{"+r+"}":r}).join("")},t.i=function(e,n){"string"==typeof e&&(e=[[null,e,""]]);for(var r={},i=0;i<this.length;i++){var a=this[i][0];"number"==typeof a&&(r[a]=!0)}for(i=0;i<e.length;i++){var o=e[i];"number"==typeof o[0]&&r[o[0]]||(n&&!o[2]?o[2]=n:n&&(o[2]="("+o[2]+") and ("+n+")"),t.push(o))}},t}},FtD3:function(e,t,n){"use strict";var r=n("t8qj");e.exports=function(e,t,n,i,a){var o=new Error(e);return r(o,t,n,i,a)}},FtQo:function(e,t,n){"use strict";var r=n("eqAp"),i=n("PBY2");r(r.P+r.F*!n("+qBm")([].reduce,!0),"Array",{reduce:function(e){return i(this,e,arguments.length,arguments[1],!1)}})},"G+F0":function(e,t,n){for(var r=n("K0e4"),i=n("/dY/"),a=n("au66"),o=n("vR0S"),s=n("CfIS"),u=n("xnnD"),l=n("6hGG"),c=l("iterator"),d=l("toStringTag"),f=u.Array,h={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},p=i(h),m=0;m<p.length;m++){var v,g=p[m],y=h[g],_=o[g],b=_&&_.prototype;if(b&&(b[c]||s(b,c,f),b[d]||s(b,d,g),u[g]=f,y))for(v in r)b[v]||a(b,v,r[v],!0)}},G26h:function(e,t,n){"use strict";var r=n("eqAp"),i=n("AeeY"),a=n("E2U5"),o=n("spe/"),s=n("gWbE").f;n("8yv5")&&r(r.P+n("danu"),"Object",{__lookupSetter__:function(e){var t,n=i(this),r=a(e,!0);do{if(t=s(n,r))return t.set}while(n=o(n))}})},G3Gk:function(e,t){e.exports=!1},GAJc:function(e,t,n){var r=n("6hGG")("iterator"),i=!1;try{var a=[7][r]();a.return=function(){i=!0},Array.from(a,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!i)return!1;var n=!1;try{var a=[7],o=a[r]();o.next=function(){return{done:n=!0}},a[r]=function(){return o},e(a)}catch(e){}return n}},GBLZ:function(e,t,n){var r=n("eqAp");r(r.P,"Function",{bind:n("xfkl")})},GDCL:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n("I3G/"),i=n.n(r),a=n("CLCt"),o=(n.n(a),n("PXmv")),s=n("yFfH");i.a.use(o.a),i.a.customElement(s.a.name,s.a)},GFPg:function(e,t,n){n("YQk9")("WeakSet")},GHBc:function(e,t,n){"use strict";var r=n("cGG2");e.exports=r.isStandardBrowserEnv()?function(){function e(e){var t=e;return n&&(i.setAttribute("href",t),t=i.href),i.setAttribute("href",t),{href:i.href,protocol:i.protocol?i.protocol.replace(/:$/,""):"",host:i.host,search:i.search?i.search.replace(/^\?/,""):"",hash:i.hash?i.hash.replace(/^#/,""):"",hostname:i.hostname,port:i.port,pathname:"/"===i.pathname.charAt(0)?i.pathname:"/"+i.pathname}}var t,n=/(msie|trident)/i.test(navigator.userAgent),i=document.createElement("a");return t=e(window.location.href),function(n){var i=r.isString(n)?e(n):n;return i.protocol===t.protocol&&i.host===t.host}}():function(){return function(){return!0}}()},Gc7k:function(e,t,n){var r=n("eqAp"),i=Math.imul;r(r.S+r.F*n("HTem")(function(){return-5!=i(4294967295,5)||2!=i.length}),"Math",{imul:function(e,t){var n=+e,r=+t,i=65535&n,a=65535&r;return 0|i*a+((65535&n>>>16)*a+i*(65535&r>>>16)<<16>>>0)}})},Gkho:function(e,t,n){"use strict";var r=n("PGRs"),i=n("J5DO"),a=n("jLAN"),o=n("Zn18");n("UIZt")("match",1,function(e,t,n,s){return[function(n){var r=e(this),i=void 0==n?void 0:n[t];return void 0!==i?i.call(n,r):new RegExp(n)[t](String(r))},function(e){var t=s(n,e,this);if(t.done)return t.value;var u=r(e),l=String(this);if(!u.global)return o(u,l);var c=u.unicode;u.lastIndex=0;for(var d,f=[],h=0;null!==(d=o(u,l));){var p=String(d[0]);f[h]=p,""===p&&(u.lastIndex=a(l,i(u.lastIndex),c)),h++}return 0===h?null:f}]})},"H7V+":function(e,t,n){var r=n("eqAp"),i=n("kLED")(!0);r(r.S,"Object",{entries:function(e){return i(e)}})},H97Y:function(e,t,n){"use strict";n("48Hh")("sup",function(e){return function(){return e(this,"sup","","")}})},HAfA:function(e,t,n){var r=n("U9LJ"),i=n("PGRs"),a=function(e,t){if(i(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{r=n("wRig")(Function.call,n("gWbE").f(Object.prototype,"__proto__").set,2),r(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return a(e,n),t?e.__proto__=n:r(e,n),e}}({},!1):void 0),check:a}},HRXJ:function(e,t,n){"use strict";n("48Hh")("italics",function(e){return function(){return e(this,"i","","")}})},HTem:function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},HdM2:function(e,t,n){var r=n("eqAp"),i=180/Math.PI;r(r.S,"Math",{degrees:function(e){return e*i}})},"I3G/":function(e,t,n){"use strict";(function(t,n){function r(e){return void 0===e||null===e}function i(e){return void 0!==e&&null!==e}function a(e){return!0===e}function o(e){return!1===e}function s(e){return"string"==typeof e||"number"==typeof e||"symbol"==typeof e||"boolean"==typeof e}function u(e){return null!==e&&"object"==typeof e}function l(e){return"[object Object]"===na.call(e)}function c(e){return"[object RegExp]"===na.call(e)}function d(e){var t=parseFloat(String(e));return t>=0&&Math.floor(t)===t&&isFinite(e)}function f(e){return null==e?"":"object"==typeof e?JSON.stringify(e,null,2):String(e)}function h(e){var t=parseFloat(e);return isNaN(t)?e:t}function p(e,t){for(var n=Object.create(null),r=e.split(","),i=0;i<r.length;i++)n[r[i]]=!0;return t?function(e){return n[e.toLowerCase()]}:function(e){return n[e]}}function m(e,t){if(e.length){var n=e.indexOf(t);if(n>-1)return e.splice(n,1)}}function v(e,t){return aa.call(e,t)}function g(e){var t=Object.create(null);return function(n){return t[n]||(t[n]=e(n))}}function y(e,t){function n(n){var r=arguments.length;return r?r>1?e.apply(t,arguments):e.call(t,n):e.call(t)}return n._length=e.length,n}function _(e,t){t=t||0;for(var n=e.length-t,r=new Array(n);n--;)r[n]=e[n+t];return r}function b(e,t){for(var n in t)e[n]=t[n];return e}function T(e){for(var t={},n=0;n<e.length;n++)e[n]&&b(t,e[n]);return t}function S(e,t,n){}function w(e,t){if(e===t)return!0;var n=u(e),r=u(t);if(!n||!r)return!n&&!r&&String(e)===String(t);try{var i=Array.isArray(e),a=Array.isArray(t);if(i&&a)return e.length===t.length&&e.every(function(e,n){return w(e,t[n])});if(i||a)return!1;var o=Object.keys(e),s=Object.keys(t);return o.length===s.length&&o.every(function(n){return w(e[n],t[n])})}catch(e){return!1}}function k(e,t){for(var n=0;n<e.length;n++)if(w(e[n],t))return n;return-1}function E(e){var t=!1;return function(){t||(t=!0,e.apply(this,arguments))}}function A(e){var t=(e+"").charCodeAt(0);return 36===t||95===t}function C(e,t,n,r){Object.defineProperty(e,t,{value:n,enumerable:!!r,writable:!0,configurable:!0})}function L(e){if(!ga.test(e)){var t=e.split(".");return function(e){for(var n=0;n<t.length;n++){if(!e)return;e=e[t[n]]}return e}}}function x(e){return"function"==typeof e&&/native code/.test(e.toString())}function j(e){Ba.target&&Na.push(Ba.target),Ba.target=e}function O(){Ba.target=Na.pop()}function I(e){return new Fa(void 0,void 0,void 0,String(e))}function P(e,t){var n=e.componentOptions,r=new Fa(e.tag,e.data,e.children,e.text,e.elm,e.context,n,e.asyncFactory);return r.ns=e.ns,r.isStatic=e.isStatic,r.key=e.key,r.isComment=e.isComment,r.fnContext=e.fnContext,r.fnOptions=e.fnOptions,r.fnScopeId=e.fnScopeId,r.isCloned=!0,t&&(e.children&&(r.children=R(e.children,!0)),n&&n.children&&(n.children=R(n.children,!0))),r}function R(e,t){for(var n=e.length,r=new Array(n),i=0;i<n;i++)r[i]=P(e[i],t);return r}function D(e,t,n){e.__proto__=t}function M(e,t,n){for(var r=0,i=n.length;r<i;r++){var a=n[r];C(e,a,t[a])}}function U(e,t){if(u(e)&&!(e instanceof Fa)){var n;return v(e,"__ob__")&&e.__ob__ instanceof $a?n=e.__ob__:Wa.shouldConvert&&!Pa()&&(Array.isArray(e)||l(e))&&Object.isExtensible(e)&&!e._isVue&&(n=new $a(e)),t&&n&&n.vmCount++,n}}function B(e,t,n,r,i){var a=new Ba,o=Object.getOwnPropertyDescriptor(e,t);if(!o||!1!==o.configurable){var s=o&&o.get,u=o&&o.set,l=!i&&U(n);Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get:function(){var t=s?s.call(e):n;return Ba.target&&(a.depend(),l&&(l.dep.depend(),Array.isArray(t)&&V(t))),t},set:function(t){var r=s?s.call(e):n;t===r||t!==t&&r!==r||(u?u.call(e,t):n=t,l=!i&&U(t),a.notify())}})}}function N(e,t,n){if(Array.isArray(e)&&d(t))return e.length=Math.max(e.length,t),e.splice(t,1,n),n;if(t in e&&!(t in Object.prototype))return e[t]=n,n;var r=e.__ob__;return e._isVue||r&&r.vmCount?n:r?(B(r.value,t,n),r.dep.notify(),n):(e[t]=n,n)}function F(e,t){if(Array.isArray(e)&&d(t))return void e.splice(t,1);var n=e.__ob__;e._isVue||n&&n.vmCount||v(e,t)&&(delete e[t],n&&n.dep.notify())}function V(e){for(var t=void 0,n=0,r=e.length;n<r;n++)t=e[n],t&&t.__ob__&&t.__ob__.dep.depend(),Array.isArray(t)&&V(t)}function q(e,t){if(!t)return e;for(var n,r,i,a=Object.keys(t),o=0;o<a.length;o++)n=a[o],r=e[n],i=t[n],v(e,n)?l(r)&&l(i)&&q(r,i):N(e,n,i);return e}function G(e,t,n){return n?function(){var r="function"==typeof t?t.call(n,n):t,i="function"==typeof e?e.call(n,n):e;return r?q(r,i):i}:t?e?function(){return q("function"==typeof t?t.call(this,this):t,"function"==typeof e?e.call(this,this):e)}:t:e}function H(e,t){return t?e?e.concat(t):Array.isArray(t)?t:[t]:e}function z(e,t,n,r){var i=Object.create(e||null);return t?b(i,t):i}function W(e,t){var n=e.props;if(n){var r,i,a,o={};if(Array.isArray(n))for(r=n.length;r--;)"string"==typeof(i=n[r])&&(a=sa(i),o[a]={type:null});else if(l(n))for(var s in n)i=n[s],a=sa(s),o[a]=l(i)?i:{type:i};e.props=o}}function $(e,t){var n=e.inject;if(n){var r=e.inject={};if(Array.isArray(n))for(var i=0;i<n.length;i++)r[n[i]]={from:n[i]};else if(l(n))for(var a in n){var o=n[a];r[a]=l(o)?b({from:a},o):{from:o}}}}function Y(e){var t=e.directives;if(t)for(var n in t){var r=t[n];"function"==typeof r&&(t[n]={bind:r,update:r})}}function K(e,t,n){function r(r){var i=Ya[r]||Ja;u[r]=i(e[r],t[r],n,r)}"function"==typeof t&&(t=t.options),W(t,n),$(t,n),Y(t);var i=t.extends;if(i&&(e=K(e,i,n)),t.mixins)for(var a=0,o=t.mixins.length;a<o;a++)e=K(e,t.mixins[a],n);var s,u={};for(s in e)r(s);for(s in t)v(e,s)||r(s);return u}function X(e,t,n,r){if("string"==typeof n){var i=e[t];if(v(i,n))return i[n];var a=sa(n);if(v(i,a))return i[a];var o=ua(a);if(v(i,o))return i[o];return i[n]||i[a]||i[o]}}function J(e,t,n,r){var i=t[e],a=!v(n,e),o=n[e];if(ee(Boolean,i.type)&&(a&&!v(i,"default")?o=!1:ee(String,i.type)||""!==o&&o!==ca(e)||(o=!0)),void 0===o){o=Q(r,i,e);var s=Wa.shouldConvert;Wa.shouldConvert=!0,U(o),Wa.shouldConvert=s}return o}function Q(e,t,n){if(v(t,"default")){var r=t.default;return e&&e.$options.propsData&&void 0===e.$options.propsData[n]&&void 0!==e._props[n]?e._props[n]:"function"==typeof r&&"Function"!==Z(t.type)?r.call(e):r}}function Z(e){var t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:""}function ee(e,t){if(!Array.isArray(t))return Z(t)===Z(e);for(var n=0,r=t.length;n<r;n++)if(Z(t[n])===Z(e))return!0;return!1}function te(e,t,n){if(t)for(var r=t;r=r.$parent;){var i=r.$options.errorCaptured;if(i)for(var a=0;a<i.length;a++)try{var o=!1===i[a].call(r,e,t,n);if(o)return}catch(e){ne(e,r,"errorCaptured hook")}}ne(e,t,n)}function ne(e,t,n){if(va.errorHandler)try{return va.errorHandler.call(null,e,t,n)}catch(e){re(e,null,"config.errorHandler")}re(e,t,n)}function re(e,t,n){if(!_a&&!ba||"undefined"==typeof console)throw e;console.error(e)}function ie(){Za=!1;var e=Qa.slice(0);Qa.length=0;for(var t=0;t<e.length;t++)e[t]()}function ae(e){return e._withTask||(e._withTask=function(){eo=!0;var t=e.apply(null,arguments);return eo=!1,t})}function oe(e,t){var n;if(Qa.push(function(){if(e)try{e.call(t)}catch(e){te(e,t,"nextTick")}else n&&n(t)}),Za||(Za=!0,eo?Xa():Ka()),!e&&"undefined"!=typeof Promise)return new Promise(function(e){n=e})}function se(e){ue(e,ao),ao.clear()}function ue(e,t){var n,r,i=Array.isArray(e);if((i||u(e))&&!Object.isFrozen(e)){if(e.__ob__){var a=e.__ob__.dep.id;if(t.has(a))return;t.add(a)}if(i)for(n=e.length;n--;)ue(e[n],t);else for(r=Object.keys(e),n=r.length;n--;)ue(e[r[n]],t)}}function le(e){function t(){var e=arguments,n=t.fns;if(!Array.isArray(n))return n.apply(null,arguments);for(var r=n.slice(),i=0;i<r.length;i++)r[i].apply(null,e)}return t.fns=e,t}function ce(e,t,n,i,a){var o,s,u,l;for(o in e)s=e[o],u=t[o],l=oo(o),r(s)||(r(u)?(r(s.fns)&&(s=e[o]=le(s)),n(l.name,s,l.once,l.capture,l.passive,l.params)):s!==u&&(u.fns=s,e[o]=u));for(o in t)r(e[o])&&(l=oo(o),i(l.name,t[o],l.capture))}function de(e,t,n){function o(){n.apply(this,arguments),m(s.fns,o)}e instanceof Fa&&(e=e.data.hook||(e.data.hook={}));var s,u=e[t];r(u)?s=le([o]):i(u.fns)&&a(u.merged)?(s=u,s.fns.push(o)):s=le([u,o]),s.merged=!0,e[t]=s}function fe(e,t,n){var a=t.options.props;if(!r(a)){var o={},s=e.attrs,u=e.props;if(i(s)||i(u))for(var l in a){var c=ca(l);he(o,u,l,c,!0)||he(o,s,l,c,!1)}return o}}function he(e,t,n,r,a){if(i(t)){if(v(t,n))return e[n]=t[n],a||delete t[n],!0;if(v(t,r))return e[n]=t[r],a||delete t[r],!0}return!1}function pe(e){for(var t=0;t<e.length;t++)if(Array.isArray(e[t]))return Array.prototype.concat.apply([],e);return e}function me(e){return s(e)?[I(e)]:Array.isArray(e)?ge(e):void 0}function ve(e){return i(e)&&i(e.text)&&o(e.isComment)}function ge(e,t){var n,o,u,l,c=[];for(n=0;n<e.length;n++)o=e[n],r(o)||"boolean"==typeof o||(u=c.length-1,l=c[u],Array.isArray(o)?o.length>0&&(o=ge(o,(t||"")+"_"+n),ve(o[0])&&ve(l)&&(c[u]=I(l.text+o[0].text),o.shift()),c.push.apply(c,o)):s(o)?ve(l)?c[u]=I(l.text+o):""!==o&&c.push(I(o)):ve(o)&&ve(l)?c[u]=I(l.text+o.text):(a(e._isVList)&&i(o.tag)&&r(o.key)&&i(t)&&(o.key="__vlist"+t+"_"+n+"__"),c.push(o)));return c}function ye(e,t){return(e.__esModule||Da&&"Module"===e[Symbol.toStringTag])&&(e=e.default),u(e)?t.extend(e):e}function _e(e,t,n,r,i){var a=qa();return a.asyncFactory=e,a.asyncMeta={data:t,context:n,children:r,tag:i},a}function be(e,t,n){if(a(e.error)&&i(e.errorComp))return e.errorComp;if(i(e.resolved))return e.resolved;if(a(e.loading)&&i(e.loadingComp))return e.loadingComp;if(!i(e.contexts)){var o=e.contexts=[n],s=!0,l=function(){for(var e=0,t=o.length;e<t;e++)o[e].$forceUpdate()},c=E(function(n){e.resolved=ye(n,t),s||l()}),d=E(function(t){i(e.errorComp)&&(e.error=!0,l())}),f=e(c,d);return u(f)&&("function"==typeof f.then?r(e.resolved)&&f.then(c,d):i(f.component)&&"function"==typeof f.component.then&&(f.component.then(c,d),i(f.error)&&(e.errorComp=ye(f.error,t)),i(f.loading)&&(e.loadingComp=ye(f.loading,t),0===f.delay?e.loading=!0:setTimeout(function(){r(e.resolved)&&r(e.error)&&(e.loading=!0,l())},f.delay||200)),i(f.timeout)&&setTimeout(function(){r(e.resolved)&&d(null)},f.timeout))),s=!1,e.loading?e.loadingComp:e.resolved}e.contexts.push(n)}function Te(e){return e.isComment&&e.asyncFactory}function Se(e){if(Array.isArray(e))for(var t=0;t<e.length;t++){var n=e[t];if(i(n)&&(i(n.componentOptions)||Te(n)))return n}}function we(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&Ae(e,t)}function ke(e,t,n){n?io.$once(e,t):io.$on(e,t)}function Ee(e,t){io.$off(e,t)}function Ae(e,t,n){io=e,ce(t,n||{},ke,Ee,e),io=void 0}function Ce(e,t){var n={};if(!e)return n;for(var r=0,i=e.length;r<i;r++){var a=e[r],o=a.data;if(o&&o.attrs&&o.attrs.slot&&delete o.attrs.slot,a.context!==t&&a.fnContext!==t||!o||null==o.slot)(n.default||(n.default=[])).push(a);else{var s=o.slot,u=n[s]||(n[s]=[]);"template"===a.tag?u.push.apply(u,a.children||[]):u.push(a)}}for(var l in n)n[l].every(Le)&&delete n[l];return n}function Le(e){return e.isComment&&!e.asyncFactory||" "===e.text}function xe(e,t){t=t||{};for(var n=0;n<e.length;n++)Array.isArray(e[n])?xe(e[n],t):t[e[n].key]=e[n].fn;return t}function je(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){for(;n.$options.abstract&&n.$parent;)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}function Oe(e,t,n){e.$el=t,e.$options.render||(e.$options.render=qa),Me(e,"beforeMount");var r;return r=function(){e._update(e._render(),n)},new vo(e,r,S,null,!0),n=!1,null==e.$vnode&&(e._isMounted=!0,Me(e,"mounted")),e}function Ie(e,t,n,r,i){var a=!!(i||e.$options._renderChildren||r.data.scopedSlots||e.$scopedSlots!==ta);if(e.$options._parentVnode=r,e.$vnode=r,e._vnode&&(e._vnode.parent=r),e.$options._renderChildren=i,e.$attrs=r.data&&r.data.attrs||ta,e.$listeners=n||ta,t&&e.$options.props){Wa.shouldConvert=!1;for(var o=e._props,s=e.$options._propKeys||[],u=0;u<s.length;u++){var l=s[u];o[l]=J(l,e.$options.props,t,e)}Wa.shouldConvert=!0,e.$options.propsData=t}if(n){var c=e.$options._parentListeners;e.$options._parentListeners=n,Ae(e,n,c)}a&&(e.$slots=Ce(i,r.context),e.$forceUpdate())}function Pe(e){for(;e&&(e=e.$parent);)if(e._inactive)return!0;return!1}function Re(e,t){if(t){if(e._directInactive=!1,Pe(e))return}else if(e._directInactive)return;if(e._inactive||null===e._inactive){e._inactive=!1;for(var n=0;n<e.$children.length;n++)Re(e.$children[n]);Me(e,"activated")}}function De(e,t){if(!(t&&(e._directInactive=!0,Pe(e))||e._inactive)){e._inactive=!0;for(var n=0;n<e.$children.length;n++)De(e.$children[n]);Me(e,"deactivated")}}function Me(e,t){var n=e.$options[t];if(n)for(var r=0,i=n.length;r<i;r++)try{n[r].call(e)}catch(n){te(n,e,t+" hook")}e._hasHookEvent&&e.$emit("hook:"+t)}function Ue(){po=uo.length=lo.length=0,co={},fo=ho=!1}function Be(){ho=!0;var e,t;for(uo.sort(function(e,t){return e.id-t.id}),po=0;po<uo.length;po++)e=uo[po],t=e.id,co[t]=null,e.run();var n=lo.slice(),r=uo.slice();Ue(),Ve(n),Ne(r),Ra&&va.devtools&&Ra.emit("flush")}function Ne(e){for(var t=e.length;t--;){var n=e[t],r=n.vm;r._watcher===n&&r._isMounted&&Me(r,"updated")}}function Fe(e){e._inactive=!1,lo.push(e)}function Ve(e){for(var t=0;t<e.length;t++)e[t]._inactive=!0,Re(e[t],!0)}function qe(e){var t=e.id;if(null==co[t]){if(co[t]=!0,ho){for(var n=uo.length-1;n>po&&uo[n].id>e.id;)n--;uo.splice(n+1,0,e)}else uo.push(e);fo||(fo=!0,oe(Be))}}function Ge(e,t,n){go.get=function(){return this[t][n]},go.set=function(e){this[t][n]=e},Object.defineProperty(e,n,go)}function He(e){e._watchers=[];var t=e.$options;t.props&&ze(e,t.props),t.methods&&Je(e,t.methods),t.data?We(e):U(e._data={},!0),t.computed&&Ye(e,t.computed),t.watch&&t.watch!==La&&Qe(e,t.watch)}function ze(e,t){var n=e.$options.propsData||{},r=e._props={},i=e.$options._propKeys=[],a=!e.$parent;Wa.shouldConvert=a;for(var o in t)!function(a){i.push(a);var o=J(a,t,n,e);B(r,a,o),a in e||Ge(e,"_props",a)}(o);Wa.shouldConvert=!0}function We(e){var t=e.$options.data;t=e._data="function"==typeof t?$e(t,e):t||{},l(t)||(t={});for(var n=Object.keys(t),r=e.$options.props,i=(e.$options.methods,n.length);i--;){var a=n[i];r&&v(r,a)||A(a)||Ge(e,"_data",a)}U(t,!0)}function $e(e,t){try{return e.call(t,t)}catch(e){return te(e,t,"data()"),{}}}function Ye(e,t){var n=e._computedWatchers=Object.create(null),r=Pa();for(var i in t){var a=t[i],o="function"==typeof a?a:a.get;r||(n[i]=new vo(e,o||S,S,yo)),i in e||Ke(e,i,a)}}function Ke(e,t,n){var r=!Pa();"function"==typeof n?(go.get=r?Xe(t):n,go.set=S):(go.get=n.get?r&&!1!==n.cache?Xe(t):n.get:S,go.set=n.set?n.set:S),Object.defineProperty(e,t,go)}function Xe(e){return function(){var t=this._computedWatchers&&this._computedWatchers[e];if(t)return t.dirty&&t.evaluate(),Ba.target&&t.depend(),t.value}}function Je(e,t){e.$options.props;for(var n in t)e[n]=null==t[n]?S:y(t[n],e)}function Qe(e,t){for(var n in t){var r=t[n];if(Array.isArray(r))for(var i=0;i<r.length;i++)Ze(e,n,r[i]);else Ze(e,n,r)}}function Ze(e,t,n,r){return l(n)&&(r=n,n=n.handler),"string"==typeof n&&(n=e[n]),e.$watch(t,n,r)}function et(e){var t=e.$options.provide;t&&(e._provided="function"==typeof t?t.call(e):t)}function tt(e){var t=nt(e.$options.inject,e);t&&(Wa.shouldConvert=!1,Object.keys(t).forEach(function(n){B(e,n,t[n])}),Wa.shouldConvert=!0)}function nt(e,t){if(e){for(var n=Object.create(null),r=Da?Reflect.ownKeys(e).filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}):Object.keys(e),i=0;i<r.length;i++){for(var a=r[i],o=e[a].from,s=t;s;){if(s._provided&&o in s._provided){n[a]=s._provided[o];break}s=s.$parent}if(!s&&"default"in e[a]){var u=e[a].default;n[a]="function"==typeof u?u.call(t):u}}return n}}function rt(e,t){var n,r,a,o,s;if(Array.isArray(e)||"string"==typeof e)for(n=new Array(e.length),r=0,a=e.length;r<a;r++)n[r]=t(e[r],r);else if("number"==typeof e)for(n=new Array(e),r=0;r<e;r++)n[r]=t(r+1,r);else if(u(e))for(o=Object.keys(e),n=new Array(o.length),r=0,a=o.length;r<a;r++)s=o[r],n[r]=t(e[s],s,r);return i(n)&&(n._isVList=!0),n}function it(e,t,n,r){var i,a=this.$scopedSlots[e];if(a)n=n||{},r&&(n=b(b({},r),n)),i=a(n)||t;else{var o=this.$slots[e];o&&(o._rendered=!0),i=o||t}var s=n&&n.slot;return s?this.$createElement("template",{slot:s},i):i}function at(e){return X(this.$options,"filters",e,!0)||fa}function ot(e,t,n,r){var i=va.keyCodes[t]||n;return i?Array.isArray(i)?-1===i.indexOf(e):i!==e:r?ca(r)!==t:void 0}function st(e,t,n,r,i){if(n)if(u(n)){Array.isArray(n)&&(n=T(n));var a;for(var o in n)!function(o){if("class"===o||"style"===o||ia(o))a=e;else{var s=e.attrs&&e.attrs.type;a=r||va.mustUseProp(t,s,o)?e.domProps||(e.domProps={}):e.attrs||(e.attrs={})}if(!(o in a)&&(a[o]=n[o],i)){(e.on||(e.on={}))["update:"+o]=function(e){n[o]=e}}}(o)}else;return e}function ut(e,t){var n=this._staticTrees||(this._staticTrees=[]),r=n[e];return r&&!t?Array.isArray(r)?R(r):P(r):(r=n[e]=this.$options.staticRenderFns[e].call(this._renderProxy,null,this),ct(r,"__static__"+e,!1),r)}function lt(e,t,n){return ct(e,"__once__"+t+(n?"_"+n:""),!0),e}function ct(e,t,n){if(Array.isArray(e))for(var r=0;r<e.length;r++)e[r]&&"string"!=typeof e[r]&&dt(e[r],t+"_"+r,n);else dt(e,t,n)}function dt(e,t,n){e.isStatic=!0,e.key=t,e.isOnce=n}function ft(e,t){if(t)if(l(t)){var n=e.on=e.on?b({},e.on):{};for(var r in t){var i=n[r],a=t[r];n[r]=i?[].concat(i,a):a}}else;return e}function ht(e){e._o=lt,e._n=h,e._s=f,e._l=rt,e._t=it,e._q=w,e._i=k,e._m=ut,e._f=at,e._k=ot,e._b=st,e._v=I,e._e=qa,e._u=xe,e._g=ft}function pt(e,t,n,r,i){var o=i.options;this.data=e,this.props=t,this.children=n,this.parent=r,this.listeners=e.on||ta,this.injections=nt(o.inject,r),this.slots=function(){return Ce(n,r)};var s=Object.create(r),u=a(o._compiled),l=!u;u&&(this.$options=o,this.$slots=this.slots(),this.$scopedSlots=e.scopedSlots||ta),o._scopeId?this._c=function(e,t,n,i){var a=St(s,e,t,n,i,l);return a&&(a.fnScopeId=o._scopeId,a.fnContext=r),a}:this._c=function(e,t,n,r){return St(s,e,t,n,r,l)}}function mt(e,t,n,r,a){var o=e.options,s={},u=o.props;if(i(u))for(var l in u)s[l]=J(l,u,t||ta);else i(n.attrs)&&vt(s,n.attrs),i(n.props)&&vt(s,n.props);var c=new pt(n,s,a,r,e),d=o.render.call(null,c._c,c);return d instanceof Fa&&(d.fnContext=r,d.fnOptions=o,n.slot&&((d.data||(d.data={})).slot=n.slot)),d}function vt(e,t){for(var n in t)e[sa(n)]=t[n]}function gt(e,t,n,o,s){if(!r(e)){var l=n.$options._base;if(u(e)&&(e=l.extend(e)),"function"==typeof e){var c;if(r(e.cid)&&(c=e,void 0===(e=be(c,l,n))))return _e(c,t,n,o,s);t=t||{},Ct(e),i(t.model)&&Tt(e.options,t);var d=fe(t,e,s);if(a(e.options.functional))return mt(e,d,t,n,o);var f=t.on;if(t.on=t.nativeOn,a(e.options.abstract)){var h=t.slot;t={},h&&(t.slot=h)}_t(t);var p=e.options.name||s;return new Fa("vue-component-"+e.cid+(p?"-"+p:""),t,void 0,void 0,void 0,n,{Ctor:e,propsData:d,listeners:f,tag:s,children:o},c)}}}function yt(e,t,n,r){var a={_isComponent:!0,parent:t,_parentVnode:e,_parentElm:n||null,_refElm:r||null},o=e.data.inlineTemplate;return i(o)&&(a.render=o.render,a.staticRenderFns=o.staticRenderFns),new e.componentOptions.Ctor(a)}function _t(e){e.hook||(e.hook={});for(var t=0;t<bo.length;t++){var n=bo[t],r=e.hook[n],i=_o[n];e.hook[n]=r?bt(i,r):i}}function bt(e,t){return function(n,r,i,a){e(n,r,i,a),t(n,r,i,a)}}function Tt(e,t){var n=e.model&&e.model.prop||"value",r=e.model&&e.model.event||"input";(t.props||(t.props={}))[n]=t.model.value;var a=t.on||(t.on={});i(a[r])?a[r]=[t.model.callback].concat(a[r]):a[r]=t.model.callback}function St(e,t,n,r,i,o){return(Array.isArray(n)||s(n))&&(i=r,r=n,n=void 0),a(o)&&(i=So),wt(e,t,n,r,i)}function wt(e,t,n,r,a){if(i(n)&&i(n.__ob__))return qa();if(i(n)&&i(n.is)&&(t=n.is),!t)return qa();Array.isArray(r)&&"function"==typeof r[0]&&(n=n||{},n.scopedSlots={default:r[0]},r.length=0),a===So?r=me(r):a===To&&(r=pe(r));var o,s;if("string"==typeof t){var u;s=e.$vnode&&e.$vnode.ns||va.getTagNamespace(t),o=va.isReservedTag(t)?new Fa(va.parsePlatformTagName(t),n,r,void 0,void 0,e):i(u=X(e.$options,"components",t))?gt(u,n,e,r,t):new Fa(t,n,r,void 0,void 0,e)}else o=gt(t,n,e,r);return i(o)?(s&&kt(o,s),o):qa()}function kt(e,t,n){if(e.ns=t,"foreignObject"===e.tag&&(t=void 0,n=!0),i(e.children))for(var o=0,s=e.children.length;o<s;o++){var u=e.children[o];i(u.tag)&&(r(u.ns)||a(n))&&kt(u,t,n)}}function Et(e){e._vnode=null,e._staticTrees=null;var t=e.$options,n=e.$vnode=t._parentVnode,r=n&&n.context;e.$slots=Ce(t._renderChildren,r),e.$scopedSlots=ta,e._c=function(t,n,r,i){return St(e,t,n,r,i,!1)},e.$createElement=function(t,n,r,i){return St(e,t,n,r,i,!0)};var i=n&&n.data;B(e,"$attrs",i&&i.attrs||ta,null,!0),B(e,"$listeners",t._parentListeners||ta,null,!0)}function At(e,t){var n=e.$options=Object.create(e.constructor.options),r=t._parentVnode;n.parent=t.parent,n._parentVnode=r,n._parentElm=t._parentElm,n._refElm=t._refElm;var i=r.componentOptions;n.propsData=i.propsData,n._parentListeners=i.listeners,n._renderChildren=i.children,n._componentTag=i.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}function Ct(e){var t=e.options;if(e.super){var n=Ct(e.super);if(n!==e.superOptions){e.superOptions=n;var r=Lt(e);r&&b(e.extendOptions,r),t=e.options=K(n,e.extendOptions),t.name&&(t.components[t.name]=e)}}return t}function Lt(e){var t,n=e.options,r=e.extendOptions,i=e.sealedOptions;for(var a in n)n[a]!==i[a]&&(t||(t={}),t[a]=xt(n[a],r[a],i[a]));return t}function xt(e,t,n){if(Array.isArray(e)){var r=[];n=Array.isArray(n)?n:[n],t=Array.isArray(t)?t:[t];for(var i=0;i<e.length;i++)(t.indexOf(e[i])>=0||n.indexOf(e[i])<0)&&r.push(e[i]);return r}return e}function jt(e){this._init(e)}function Ot(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=_(arguments,1);return n.unshift(this),"function"==typeof e.install?e.install.apply(e,n):"function"==typeof e&&e.apply(null,n),t.push(e),this}}function It(e){e.mixin=function(e){return this.options=K(this.options,e),this}}function Pt(e){e.cid=0;var t=1;e.extend=function(e){e=e||{};var n=this,r=n.cid,i=e._Ctor||(e._Ctor={});if(i[r])return i[r];var a=e.name||n.options.name,o=function(e){this._init(e)};return o.prototype=Object.create(n.prototype),o.prototype.constructor=o,o.cid=t++,o.options=K(n.options,e),o.super=n,o.options.props&&Rt(o),o.options.computed&&Dt(o),o.extend=n.extend,o.mixin=n.mixin,o.use=n.use,pa.forEach(function(e){o[e]=n[e]}),a&&(o.options.components[a]=o),o.superOptions=n.options,o.extendOptions=e,o.sealedOptions=b({},o.options),i[r]=o,o}}function Rt(e){var t=e.options.props;for(var n in t)Ge(e.prototype,"_props",n)}function Dt(e){var t=e.options.computed;for(var n in t)Ke(e.prototype,n,t[n])}function Mt(e){pa.forEach(function(t){e[t]=function(e,n){return n?("component"===t&&l(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&"function"==typeof n&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}})}function Ut(e){return e&&(e.Ctor.options.name||e.tag)}function Bt(e,t){return Array.isArray(e)?e.indexOf(t)>-1:"string"==typeof e?e.split(",").indexOf(t)>-1:!!c(e)&&e.test(t)}function Nt(e,t){var n=e.cache,r=e.keys,i=e._vnode;for(var a in n){var o=n[a];if(o){var s=Ut(o.componentOptions);s&&!t(s)&&Ft(n,a,r,i)}}}function Ft(e,t,n,r){var i=e[t];!i||r&&i.tag===r.tag||i.componentInstance.$destroy(),e[t]=null,m(n,t)}function Vt(e){for(var t=e.data,n=e,r=e;i(r.componentInstance);)(r=r.componentInstance._vnode)&&r.data&&(t=qt(r.data,t));for(;i(n=n.parent);)n&&n.data&&(t=qt(t,n.data));return Gt(t.staticClass,t.class)}function qt(e,t){return{staticClass:Ht(e.staticClass,t.staticClass),class:i(e.class)?[e.class,t.class]:t.class}}function Gt(e,t){return i(e)||i(t)?Ht(e,zt(t)):""}function Ht(e,t){return e?t?e+" "+t:e:t||""}function zt(e){return Array.isArray(e)?Wt(e):u(e)?$t(e):"string"==typeof e?e:""}function Wt(e){for(var t,n="",r=0,a=e.length;r<a;r++)i(t=zt(e[r]))&&""!==t&&(n&&(n+=" "),n+=t);return n}function $t(e){var t="";for(var n in e)e[n]&&(t&&(t+=" "),t+=n);return t}function Yt(e){return $o(e)?"svg":"math"===e?"math":void 0}function Kt(e){if(!_a)return!0;if(Ko(e))return!1;if(e=e.toLowerCase(),null!=Xo[e])return Xo[e];var t=document.createElement(e);return e.indexOf("-")>-1?Xo[e]=t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:Xo[e]=/HTMLUnknownElement/.test(t.toString())}function Xt(e){if("string"==typeof e){var t=document.querySelector(e);return t||document.createElement("div")}return e}function Jt(e,t){var n=document.createElement(e);return"select"!==e?n:(t.data&&t.data.attrs&&void 0!==t.data.attrs.multiple&&n.setAttribute("multiple","multiple"),n)}function Qt(e,t){return document.createElementNS(zo[e],t)}function Zt(e){return document.createTextNode(e)}function en(e){return document.createComment(e)}function tn(e,t,n){e.insertBefore(t,n)}function nn(e,t){e.removeChild(t)}function rn(e,t){e.appendChild(t)}function an(e){return e.parentNode}function on(e){return e.nextSibling}function sn(e){return e.tagName}function un(e,t){e.textContent=t}function ln(e,t,n){e.setAttribute(t,n)}function cn(e,t){var n=e.data.ref;if(n){var r=e.context,i=e.componentInstance||e.elm,a=r.$refs;t?Array.isArray(a[n])?m(a[n],i):a[n]===i&&(a[n]=void 0):e.data.refInFor?Array.isArray(a[n])?a[n].indexOf(i)<0&&a[n].push(i):a[n]=[i]:a[n]=i}}function dn(e,t){return e.key===t.key&&(e.tag===t.tag&&e.isComment===t.isComment&&i(e.data)===i(t.data)&&fn(e,t)||a(e.isAsyncPlaceholder)&&e.asyncFactory===t.asyncFactory&&r(t.asyncFactory.error))}function fn(e,t){if("input"!==e.tag)return!0;var n,r=i(n=e.data)&&i(n=n.attrs)&&n.type,a=i(n=t.data)&&i(n=n.attrs)&&n.type;return r===a||Jo(r)&&Jo(a)}function hn(e,t,n){var r,a,o={};for(r=t;r<=n;++r)a=e[r].key,i(a)&&(o[a]=r);return o}function pn(e,t){(e.data.directives||t.data.directives)&&mn(e,t)}function mn(e,t){var n,r,i,a=e===es,o=t===es,s=vn(e.data.directives,e.context),u=vn(t.data.directives,t.context),l=[],c=[];for(n in u)r=s[n],i=u[n],r?(i.oldValue=r.value,yn(i,"update",t,e),i.def&&i.def.componentUpdated&&c.push(i)):(yn(i,"bind",t,e),i.def&&i.def.inserted&&l.push(i));if(l.length){var d=function(){for(var n=0;n<l.length;n++)yn(l[n],"inserted",t,e)};a?de(t,"insert",d):d()}if(c.length&&de(t,"postpatch",function(){for(var n=0;n<c.length;n++)yn(c[n],"componentUpdated",t,e)}),!a)for(n in s)u[n]||yn(s[n],"unbind",e,e,o)}function vn(e,t){var n=Object.create(null);if(!e)return n;var r,i;for(r=0;r<e.length;r++)i=e[r],i.modifiers||(i.modifiers=rs),n[gn(i)]=i,i.def=X(t.$options,"directives",i.name,!0);return n}function gn(e){return e.rawName||e.name+"."+Object.keys(e.modifiers||{}).join(".")}function yn(e,t,n,r,i){var a=e.def&&e.def[t];if(a)try{a(n.elm,e,n,r,i)}catch(r){te(r,n.context,"directive "+e.name+" "+t+" hook")}}function _n(e,t){var n=t.componentOptions;if(!(i(n)&&!1===n.Ctor.options.inheritAttrs||r(e.data.attrs)&&r(t.data.attrs))){var a,o,s=t.elm,u=e.data.attrs||{},l=t.data.attrs||{};i(l.__ob__)&&(l=t.data.attrs=b({},l));for(a in l)o=l[a],u[a]!==o&&bn(s,a,o);(wa||Ea)&&l.value!==u.value&&bn(s,"value",l.value);for(a in u)r(l[a])&&(qo(a)?s.removeAttributeNS(Vo,Go(a)):No(a)||s.removeAttribute(a))}}function bn(e,t,n){if(Fo(t))Ho(n)?e.removeAttribute(t):(n="allowfullscreen"===t&&"EMBED"===e.tagName?"true":t,e.setAttribute(t,n));else if(No(t))e.setAttribute(t,Ho(n)||"false"===n?"false":"true");else if(qo(t))Ho(n)?e.removeAttributeNS(Vo,Go(t)):e.setAttributeNS(Vo,t,n);else if(Ho(n))e.removeAttribute(t);else{if(wa&&!ka&&"TEXTAREA"===e.tagName&&"placeholder"===t&&!e.__ieph){var r=function(t){t.stopImmediatePropagation(),e.removeEventListener("input",r)};e.addEventListener("input",r),e.__ieph=!0}e.setAttribute(t,n)}}function Tn(e,t){var n=t.elm,a=t.data,o=e.data;if(!(r(a.staticClass)&&r(a.class)&&(r(o)||r(o.staticClass)&&r(o.class)))){var s=Vt(t),u=n._transitionClasses;i(u)&&(s=Ht(s,zt(u))),s!==n._prevClass&&(n.setAttribute("class",s),n._prevClass=s)}}function Sn(e){function t(){(o||(o=[])).push(e.slice(p,i).trim()),p=i+1}var n,r,i,a,o,s=!1,u=!1,l=!1,c=!1,d=0,f=0,h=0,p=0;for(i=0;i<e.length;i++)if(r=n,n=e.charCodeAt(i),s)39===n&&92!==r&&(s=!1);else if(u)34===n&&92!==r&&(u=!1);else if(l)96===n&&92!==r&&(l=!1);else if(c)47===n&&92!==r&&(c=!1);else if(124!==n||124===e.charCodeAt(i+1)||124===e.charCodeAt(i-1)||d||f||h){switch(n){case 34:u=!0;break;case 39:s=!0;break;case 96:l=!0;break;case 40:h++;break;case 41:h--;break;case 91:f++;break;case 93:f--;break;case 123:d++;break;case 125:d--}if(47===n){for(var m=i-1,v=void 0;m>=0&&" "===(v=e.charAt(m));m--);v&&ss.test(v)||(c=!0)}}else void 0===a?(p=i+1,a=e.slice(0,i).trim()):t();if(void 0===a?a=e.slice(0,i).trim():0!==p&&t(),o)for(i=0;i<o.length;i++)a=wn(a,o[i]);return a}function wn(e,t){var n=t.indexOf("(");return n<0?'_f("'+t+'")('+e+")":'_f("'+t.slice(0,n)+'")('+e+","+t.slice(n+1)}function kn(e){console.error("[Vue compiler]: "+e)}function En(e,t){return e?e.map(function(e){return e[t]}).filter(function(e){return e}):[]}function An(e,t,n){(e.props||(e.props=[])).push({name:t,value:n}),e.plain=!1}function Cn(e,t,n){(e.attrs||(e.attrs=[])).push({name:t,value:n}),e.plain=!1}function Ln(e,t,n){e.attrsMap[t]=n,e.attrsList.push({name:t,value:n})}function xn(e,t,n,r,i,a){(e.directives||(e.directives=[])).push({name:t,rawName:n,value:r,arg:i,modifiers:a}),e.plain=!1}function jn(e,t,n,r,i,a){r=r||ta,r.capture&&(delete r.capture,t="!"+t),r.once&&(delete r.once,t="~"+t),r.passive&&(delete r.passive,t="&"+t),"click"===t&&(r.right?(t="contextmenu",delete r.right):r.middle&&(t="mouseup"));var o;r.native?(delete r.native,o=e.nativeEvents||(e.nativeEvents={})):o=e.events||(e.events={});var s={value:n};r!==ta&&(s.modifiers=r);var u=o[t];Array.isArray(u)?i?u.unshift(s):u.push(s):o[t]=u?i?[s,u]:[u,s]:s,e.plain=!1}function On(e,t,n){var r=In(e,":"+t)||In(e,"v-bind:"+t);if(null!=r)return Sn(r);if(!1!==n){var i=In(e,t);if(null!=i)return JSON.stringify(i)}}function In(e,t,n){var r;if(null!=(r=e.attrsMap[t]))for(var i=e.attrsList,a=0,o=i.length;a<o;a++)if(i[a].name===t){i.splice(a,1);break}return n&&delete e.attrsMap[t],r}function Pn(e,t,n){var r=n||{},i=r.number,a=r.trim,o="$$v";a&&(o="(typeof $$v === 'string'? $$v.trim(): $$v)"),i&&(o="_n("+o+")");var s=Rn(t,o);e.model={value:"("+t+")",expression:'"'+t+'"',callback:"function ($$v) {"+s+"}"}}function Rn(e,t){var n=Dn(e);return null===n.key?e+"="+t:"$set("+n.exp+", "+n.key+", "+t+")"}function Dn(e){if(Co=e.length,e.indexOf("[")<0||e.lastIndexOf("]")<Co-1)return jo=e.lastIndexOf("."),jo>-1?{exp:e.slice(0,jo),key:'"'+e.slice(jo+1)+'"'}:{exp:e,key:null};for(Lo=e,jo=Oo=Io=0;!Un();)xo=Mn(),Bn(xo)?Fn(xo):91===xo&&Nn(xo);return{exp:e.slice(0,Oo),key:e.slice(Oo+1,Io)}}function Mn(){return Lo.charCodeAt(++jo)}function Un(){return jo>=Co}function Bn(e){return 34===e||39===e}function Nn(e){var t=1;for(Oo=jo;!Un();)if(e=Mn(),Bn(e))Fn(e);else if(91===e&&t++,93===e&&t--,0===t){Io=jo;break}}function Fn(e){for(var t=e;!Un()&&(e=Mn())!==t;);}function Vn(e,t,n){Po=n;var r=t.value,i=t.modifiers,a=e.tag,o=e.attrsMap.type;if(e.component)return Pn(e,r,i),!1;if("select"===a)Hn(e,r,i);else if("input"===a&&"checkbox"===o)qn(e,r,i);else if("input"===a&&"radio"===o)Gn(e,r,i);else if("input"===a||"textarea"===a)zn(e,r,i);else if(!va.isReservedTag(a))return Pn(e,r,i),!1;return!0}function qn(e,t,n){var r=n&&n.number,i=On(e,"value")||"null",a=On(e,"true-value")||"true",o=On(e,"false-value")||"false";An(e,"checked","Array.isArray("+t+")?_i("+t+","+i+")>-1"+("true"===a?":("+t+")":":_q("+t+","+a+")")),jn(e,"change","var $$a="+t+",$$el=$event.target,$$c=$$el.checked?("+a+"):("+o+");if(Array.isArray($$a)){var $$v="+(r?"_n("+i+")":i)+",$$i=_i($$a,$$v);if($$el.checked){$$i<0&&("+t+"=$$a.concat([$$v]))}else{$$i>-1&&("+t+"=$$a.slice(0,$$i).concat($$a.slice($$i+1)))}}else{"+Rn(t,"$$c")+"}",null,!0)}function Gn(e,t,n){var r=n&&n.number,i=On(e,"value")||"null";i=r?"_n("+i+")":i,An(e,"checked","_q("+t+","+i+")"),jn(e,"change",Rn(t,i),null,!0)}function Hn(e,t,n){var r=n&&n.number,i='Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;return '+(r?"_n(val)":"val")+"})",a="var $$selectedVal = "+i+";";a=a+" "+Rn(t,"$event.target.multiple ? $$selectedVal : $$selectedVal[0]"),jn(e,"change",a,null,!0)}function zn(e,t,n){var r=e.attrsMap.type,i=n||{},a=i.lazy,o=i.number,s=i.trim,u=!a&&"range"!==r,l=a?"change":"range"===r?us:"input",c="$event.target.value";s&&(c="$event.target.value.trim()"),o&&(c="_n("+c+")");var d=Rn(t,c);u&&(d="if($event.target.composing)return;"+d),An(e,"value","("+t+")"),jn(e,l,d,null,!0),(s||o)&&jn(e,"blur","$forceUpdate()")}function Wn(e){if(i(e[us])){var t=wa?"change":"input";e[t]=[].concat(e[us],e[t]||[]),delete e[us]}i(e[ls])&&(e.change=[].concat(e[ls],e.change||[]),delete e[ls])}function $n(e,t,n){var r=Ro;return function i(){null!==e.apply(null,arguments)&&Kn(t,i,n,r)}}function Yn(e,t,n,r,i){t=ae(t),n&&(t=$n(t,e,r)),Ro.addEventListener(e,t,xa?{capture:r,passive:i}:r)}function Kn(e,t,n,r){(r||Ro).removeEventListener(e,t._withTask||t,n)}function Xn(e,t){if(!r(e.data.on)||!r(t.data.on)){var n=t.data.on||{},i=e.data.on||{};Ro=t.elm,Wn(n),ce(n,i,Yn,Kn,t.context),Ro=void 0}}function Jn(e,t){if(!r(e.data.domProps)||!r(t.data.domProps)){var n,a,o=t.elm,s=e.data.domProps||{},u=t.data.domProps||{};i(u.__ob__)&&(u=t.data.domProps=b({},u));for(n in s)r(u[n])&&(o[n]="");for(n in u){if(a=u[n],"textContent"===n||"innerHTML"===n){if(t.children&&(t.children.length=0),a===s[n])continue;1===o.childNodes.length&&o.removeChild(o.childNodes[0])}if("value"===n){o._value=a;var l=r(a)?"":String(a);Qn(o,l)&&(o.value=l)}else o[n]=a}}}function Qn(e,t){return!e.composing&&("OPTION"===e.tagName||Zn(e,t)||er(e,t))}function Zn(e,t){var n=!0;try{n=document.activeElement!==e}catch(e){}return n&&e.value!==t}function er(e,t){var n=e.value,r=e._vModifiers;if(i(r)){if(r.lazy)return!1;if(r.number)return h(n)!==h(t);if(r.trim)return n.trim()!==t.trim()}return n!==t}function tr(e){var t=nr(e.style);return e.staticStyle?b(e.staticStyle,t):t}function nr(e){return Array.isArray(e)?T(e):"string"==typeof e?fs(e):e}function rr(e,t){var n,r={};if(t)for(var i=e;i.componentInstance;)(i=i.componentInstance._vnode)&&i.data&&(n=tr(i.data))&&b(r,n);(n=tr(e.data))&&b(r,n);for(var a=e;a=a.parent;)a.data&&(n=tr(a.data))&&b(r,n);return r}function ir(e,t){var n=t.data,a=e.data;if(!(r(n.staticStyle)&&r(n.style)&&r(a.staticStyle)&&r(a.style))){var o,s,u=t.elm,l=a.staticStyle,c=a.normalizedStyle||a.style||{},d=l||c,f=nr(t.data.style)||{};t.data.normalizedStyle=i(f.__ob__)?b({},f):f;var h=rr(t,!0);for(s in d)r(h[s])&&ms(u,s,"");for(s in h)(o=h[s])!==d[s]&&ms(u,s,null==o?"":o)}}function ar(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split(/\s+/).forEach(function(t){return e.classList.add(t)}):e.classList.add(t);else{var n=" "+(e.getAttribute("class")||"")+" ";n.indexOf(" "+t+" ")<0&&e.setAttribute("class",(n+t).trim())}}function or(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split(/\s+/).forEach(function(t){return e.classList.remove(t)}):e.classList.remove(t),e.classList.length||e.removeAttribute("class");else{for(var n=" "+(e.getAttribute("class")||"")+" ",r=" "+t+" ";n.indexOf(r)>=0;)n=n.replace(r," ");n=n.trim(),n?e.setAttribute("class",n):e.removeAttribute("class")}}function sr(e){if(e){if("object"==typeof e){var t={};return!1!==e.css&&b(t,_s(e.name||"v")),b(t,e),t}return"string"==typeof e?_s(e):void 0}}function ur(e){Cs(function(){Cs(e)})}function lr(e,t){var n=e._transitionClasses||(e._transitionClasses=[]);n.indexOf(t)<0&&(n.push(t),ar(e,t))}function cr(e,t){e._transitionClasses&&m(e._transitionClasses,t),or(e,t)}function dr(e,t,n){var r=fr(e,t),i=r.type,a=r.timeout,o=r.propCount;if(!i)return n();var s=i===Ts?ks:As,u=0,l=function(){e.removeEventListener(s,c),n()},c=function(t){t.target===e&&++u>=o&&l()};setTimeout(function(){u<o&&l()},a+1),e.addEventListener(s,c)}function fr(e,t){var n,r=window.getComputedStyle(e),i=r[ws+"Delay"].split(", "),a=r[ws+"Duration"].split(", "),o=hr(i,a),s=r[Es+"Delay"].split(", "),u=r[Es+"Duration"].split(", "),l=hr(s,u),c=0,d=0;return t===Ts?o>0&&(n=Ts,c=o,d=a.length):t===Ss?l>0&&(n=Ss,c=l,d=u.length):(c=Math.max(o,l),n=c>0?o>l?Ts:Ss:null,d=n?n===Ts?a.length:u.length:0),{type:n,timeout:c,propCount:d,hasTransform:n===Ts&&Ls.test(r[ws+"Property"])}}function hr(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max.apply(null,t.map(function(t,n){return pr(t)+pr(e[n])}))}function pr(e){return 1e3*Number(e.slice(0,-1))}function mr(e,t){var n=e.elm;i(n._leaveCb)&&(n._leaveCb.cancelled=!0,n._leaveCb());var a=sr(e.data.transition);if(!r(a)&&!i(n._enterCb)&&1===n.nodeType){for(var o=a.css,s=a.type,l=a.enterClass,c=a.enterToClass,d=a.enterActiveClass,f=a.appearClass,p=a.appearToClass,m=a.appearActiveClass,v=a.beforeEnter,g=a.enter,y=a.afterEnter,_=a.enterCancelled,b=a.beforeAppear,T=a.appear,S=a.afterAppear,w=a.appearCancelled,k=a.duration,A=so,C=so.$vnode;C&&C.parent;)C=C.parent,A=C.context;var L=!A._isMounted||!e.isRootInsert;if(!L||T||""===T){var x=L&&f?f:l,j=L&&m?m:d,O=L&&p?p:c,I=L?b||v:v,P=L&&"function"==typeof T?T:g,R=L?S||y:y,D=L?w||_:_,M=h(u(k)?k.enter:k),U=!1!==o&&!ka,B=yr(P),N=n._enterCb=E(function(){U&&(cr(n,O),cr(n,j)),N.cancelled?(U&&cr(n,x),D&&D(n)):R&&R(n),n._enterCb=null});e.data.show||de(e,"insert",function(){var t=n.parentNode,r=t&&t._pending&&t._pending[e.key];r&&r.tag===e.tag&&r.elm._leaveCb&&r.elm._leaveCb(),P&&P(n,N)}),I&&I(n),U&&(lr(n,x),lr(n,j),ur(function(){lr(n,O),cr(n,x),N.cancelled||B||(gr(M)?setTimeout(N,M):dr(n,s,N))})),e.data.show&&(t&&t(),P&&P(n,N)),U||B||N()}}}function vr(e,t){function n(){w.cancelled||(e.data.show||((a.parentNode._pending||(a.parentNode._pending={}))[e.key]=e),p&&p(a),b&&(lr(a,c),lr(a,f),ur(function(){lr(a,d),cr(a,c),w.cancelled||T||(gr(S)?setTimeout(w,S):dr(a,l,w))})),m&&m(a,w),b||T||w())}var a=e.elm;i(a._enterCb)&&(a._enterCb.cancelled=!0,a._enterCb());var o=sr(e.data.transition);if(r(o)||1!==a.nodeType)return t();if(!i(a._leaveCb)){var s=o.css,l=o.type,c=o.leaveClass,d=o.leaveToClass,f=o.leaveActiveClass,p=o.beforeLeave,m=o.leave,v=o.afterLeave,g=o.leaveCancelled,y=o.delayLeave,_=o.duration,b=!1!==s&&!ka,T=yr(m),S=h(u(_)?_.leave:_),w=a._leaveCb=E(function(){a.parentNode&&a.parentNode._pending&&(a.parentNode._pending[e.key]=null),b&&(cr(a,d),cr(a,f)),w.cancelled?(b&&cr(a,c),g&&g(a)):(t(),v&&v(a)),a._leaveCb=null});y?y(n):n()}}function gr(e){return"number"==typeof e&&!isNaN(e)}function yr(e){if(r(e))return!1;var t=e.fns;return i(t)?yr(Array.isArray(t)?t[0]:t):(e._length||e.length)>1}function _r(e,t){!0!==t.data.show&&mr(t)}function br(e,t,n){Tr(e,t,n),(wa||Ea)&&setTimeout(function(){Tr(e,t,n)},0)}function Tr(e,t,n){var r=t.value,i=e.multiple;if(!i||Array.isArray(r)){for(var a,o,s=0,u=e.options.length;s<u;s++)if(o=e.options[s],i)a=k(r,wr(o))>-1,o.selected!==a&&(o.selected=a);else if(w(wr(o),r))return void(e.selectedIndex!==s&&(e.selectedIndex=s));i||(e.selectedIndex=-1)}}function Sr(e,t){return t.every(function(t){return!w(t,e)})}function wr(e){return"_value"in e?e._value:e.value}function kr(e){e.target.composing=!0}function Er(e){e.target.composing&&(e.target.composing=!1,Ar(e.target,"input"))}function Ar(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}function Cr(e){return!e.componentInstance||e.data&&e.data.transition?e:Cr(e.componentInstance._vnode)}function Lr(e){var t=e&&e.componentOptions;return t&&t.Ctor.options.abstract?Lr(Se(t.children)):e}function xr(e){var t={},n=e.$options;for(var r in n.propsData)t[r]=e[r];var i=n._parentListeners;for(var a in i)t[sa(a)]=i[a];return t}function jr(e,t){if(/\d-keep-alive$/.test(t.tag))return e("keep-alive",{props:t.componentOptions.propsData})}function Or(e){for(;e=e.parent;)if(e.data.transition)return!0}function Ir(e,t){return t.key===e.key&&t.tag===e.tag}function Pr(e){e.elm._moveCb&&e.elm._moveCb(),e.elm._enterCb&&e.elm._enterCb()}function Rr(e){e.data.newPos=e.elm.getBoundingClientRect()}function Dr(e){var t=e.data.pos,n=e.data.newPos,r=t.left-n.left,i=t.top-n.top;if(r||i){e.data.moved=!0;var a=e.elm.style;a.transform=a.WebkitTransform="translate("+r+"px,"+i+"px)",a.transitionDuration="0s"}}function Mr(e,t){var n=t?Hs(t):qs;if(n.test(e)){for(var r,i,a,o=[],s=[],u=n.lastIndex=0;r=n.exec(e);){i=r.index,i>u&&(s.push(a=e.slice(u,i)),o.push(JSON.stringify(a)));var l=Sn(r[1].trim());o.push("_s("+l+")"),s.push({"@binding":l}),u=i+r[0].length}return u<e.length&&(s.push(a=e.slice(u)),o.push(JSON.stringify(a))),{expression:o.join("+"),tokens:s}}}function Ur(e,t){var n=(t.warn,In(e,"class"));n&&(e.staticClass=JSON.stringify(n));var r=On(e,"class",!1);r&&(e.classBinding=r)}function Br(e){var t="";return e.staticClass&&(t+="staticClass:"+e.staticClass+","),e.classBinding&&(t+="class:"+e.classBinding+","),t}function Nr(e,t){var n=(t.warn,In(e,"style"));if(n){e.staticStyle=JSON.stringify(fs(n))}var r=On(e,"style",!1);r&&(e.styleBinding=r)}function Fr(e){var t="";return e.staticStyle&&(t+="staticStyle:"+e.staticStyle+","),e.styleBinding&&(t+="style:("+e.styleBinding+"),"),t}function Vr(e,t){var n=t?Su:Tu;return e.replace(n,function(e){return bu[e]})}function qr(e,t){function n(t){c+=t,e=e.substring(t)}function r(e,n,r){var i,s;if(null==n&&(n=c),null==r&&(r=c),e&&(s=e.toLowerCase()),e)for(i=o.length-1;i>=0&&o[i].lowerCasedTag!==s;i--);else i=0;if(i>=0){for(var u=o.length-1;u>=i;u--)t.end&&t.end(o[u].tag,n,r);o.length=i,a=i&&o[i-1].tag}else"br"===s?t.start&&t.start(e,[],!0,n,r):"p"===s&&(t.start&&t.start(e,[],!1,n,r),t.end&&t.end(e,n,r))}for(var i,a,o=[],s=t.expectHTML,u=t.isUnaryTag||da,l=t.canBeLeftOpenTag||da,c=0;e;){if(i=e,a&&yu(a)){var d=0,f=a.toLowerCase(),h=_u[f]||(_u[f]=new RegExp("([\\s\\S]*?)(</"+f+"[^>]*>)","i")),p=e.replace(h,function(e,n,r){return d=r.length,yu(f)||"noscript"===f||(n=n.replace(/<!--([\s\S]*?)-->/g,"$1").replace(/<!\[CDATA\[([\s\S]*?)]]>/g,"$1")),ku(f,n)&&(n=n.slice(1)),t.chars&&t.chars(n),""});c+=e.length-p.length,e=p,r(f,c-d,c)}else{var m=e.indexOf("<");if(0===m){if(iu.test(e)){var v=e.indexOf("--\x3e");if(v>=0){t.shouldKeepComment&&t.comment(e.substring(4,v)),n(v+3);continue}}if(au.test(e)){var g=e.indexOf("]>");if(g>=0){n(g+2);continue}}var y=e.match(ru);if(y){n(y[0].length);continue}var _=e.match(nu);if(_){var b=c;n(_[0].length),r(_[1],b,c);continue}var T=function(){var t=e.match(eu);if(t){var r={tagName:t[1],attrs:[],start:c};n(t[0].length);for(var i,a;!(i=e.match(tu))&&(a=e.match(Js));)n(a[0].length),r.attrs.push(a);if(i)return r.unarySlash=i[1],n(i[0].length),r.end=c,r}}();if(T){!function(e){var n=e.tagName,i=e.unarySlash;s&&("p"===a&&Xs(n)&&r(a),l(n)&&a===n&&r(n));for(var c=u(n)||!!i,d=e.attrs.length,f=new Array(d),h=0;h<d;h++){var p=e.attrs[h];ou&&-1===p[0].indexOf('""')&&(""===p[3]&&delete p[3],""===p[4]&&delete p[4],""===p[5]&&delete p[5]);var m=p[3]||p[4]||p[5]||"",v="a"===n&&"href"===p[1]?t.shouldDecodeNewlinesForHref:t.shouldDecodeNewlines;f[h]={name:p[1],value:Vr(m,v)}}c||(o.push({tag:n,lowerCasedTag:n.toLowerCase(),attrs:f}),a=n),t.start&&t.start(n,f,c,e.start,e.end)}(T),ku(a,e)&&n(1);continue}}var S=void 0,w=void 0,k=void 0;if(m>=0){for(w=e.slice(m);!(nu.test(w)||eu.test(w)||iu.test(w)||au.test(w)||(k=w.indexOf("<",1))<0);)m+=k,w=e.slice(m);S=e.substring(0,m),n(m)}m<0&&(S=e,e=""),t.chars&&S&&t.chars(S)}if(e===i){t.chars&&t.chars(e);break}}r()}function Gr(e,t,n){return{type:1,tag:e,attrsList:t,attrsMap:ui(t),parent:n,children:[]}}function Hr(e,t){function n(e){e.pre&&(s=!1),fu(e.tag)&&(u=!1);for(var n=0;n<du.length;n++)du[n](e,t)}su=t.warn||kn,fu=t.isPreTag||da,hu=t.mustUseProp||da,pu=t.getTagNamespace||da,lu=En(t.modules,"transformNode"),cu=En(t.modules,"preTransformNode"),du=En(t.modules,"postTransformNode"),uu=t.delimiters;var r,i,a=[],o=!1!==t.preserveWhitespace,s=!1,u=!1;return qr(e,{warn:su,expectHTML:t.expectHTML,isUnaryTag:t.isUnaryTag,canBeLeftOpenTag:t.canBeLeftOpenTag,shouldDecodeNewlines:t.shouldDecodeNewlines,shouldDecodeNewlinesForHref:t.shouldDecodeNewlinesForHref,shouldKeepComment:t.comments,start:function(e,o,l){var c=i&&i.ns||pu(e);wa&&"svg"===c&&(o=di(o));var d=Gr(e,o,i);c&&(d.ns=c),ci(d)&&!Pa()&&(d.forbidden=!0);for(var f=0;f<cu.length;f++)d=cu[f](d,t)||d;if(s||(zr(d),d.pre&&(s=!0)),fu(d.tag)&&(u=!0),s?Wr(d):d.processed||(Xr(d),Qr(d),ni(d),$r(d,t)),r?a.length||r.if&&(d.elseif||d.else)&&ti(r,{exp:d.elseif,block:d}):r=d,i&&!d.forbidden)if(d.elseif||d.else)Zr(d,i);else if(d.slotScope){i.plain=!1;var h=d.slotTarget||'"default"';(i.scopedSlots||(i.scopedSlots={}))[h]=d}else i.children.push(d),d.parent=i;l?n(d):(i=d,a.push(d))},end:function(){var e=a[a.length-1],t=e.children[e.children.length-1];t&&3===t.type&&" "===t.text&&!u&&e.children.pop(),a.length-=1,i=a[a.length-1],n(e)},chars:function(e){if(i&&(!wa||"textarea"!==i.tag||i.attrsMap.placeholder!==e)){var t=i.children;if(e=u||e.trim()?li(i)?e:Pu(e):o&&t.length?" ":""){var n;!s&&" "!==e&&(n=Mr(e,uu))?t.push({type:2,expression:n.expression,tokens:n.tokens,text:e}):" "===e&&t.length&&" "===t[t.length-1].text||t.push({type:3,text:e})}}},comment:function(e){i.children.push({type:3,text:e,isComment:!0})}}),r}function zr(e){null!=In(e,"v-pre")&&(e.pre=!0)}function Wr(e){var t=e.attrsList.length;if(t)for(var n=e.attrs=new Array(t),r=0;r<t;r++)n[r]={name:e.attrsList[r].name,value:JSON.stringify(e.attrsList[r].value)};else e.pre||(e.plain=!0)}function $r(e,t){Yr(e),e.plain=!e.key&&!e.attrsList.length,Kr(e),ri(e),ii(e);for(var n=0;n<lu.length;n++)e=lu[n](e,t)||e;ai(e)}function Yr(e){var t=On(e,"key");t&&(e.key=t)}function Kr(e){var t=On(e,"ref");t&&(e.ref=t,e.refInFor=oi(e))}function Xr(e){var t;if(t=In(e,"v-for")){var n=Jr(t);n&&b(e,n)}}function Jr(e){var t=e.match(Cu);if(t){var n={};n.for=t[2].trim();var r=t[1].trim().replace(xu,""),i=r.match(Lu);return i?(n.alias=r.replace(Lu,""),n.iterator1=i[1].trim(),i[2]&&(n.iterator2=i[2].trim())):n.alias=r,n}}function Qr(e){var t=In(e,"v-if");if(t)e.if=t,ti(e,{exp:t,block:e});else{null!=In(e,"v-else")&&(e.else=!0);var n=In(e,"v-else-if");n&&(e.elseif=n)}}function Zr(e,t){var n=ei(t.children);n&&n.if&&ti(n,{exp:e.elseif,block:e})}function ei(e){for(var t=e.length;t--;){if(1===e[t].type)return e[t];e.pop()}}function ti(e,t){e.ifConditions||(e.ifConditions=[]),e.ifConditions.push(t)}function ni(e){null!=In(e,"v-once")&&(e.once=!0)}function ri(e){if("slot"===e.tag)e.slotName=On(e,"name");else{var t;"template"===e.tag?(t=In(e,"scope"),e.slotScope=t||In(e,"slot-scope")):(t=In(e,"slot-scope"))&&(e.slotScope=t);var n=On(e,"slot");n&&(e.slotTarget='""'===n?'"default"':n,"template"===e.tag||e.slotScope||Cn(e,"slot",n))}}function ii(e){var t;(t=On(e,"is"))&&(e.component=t),null!=In(e,"inline-template")&&(e.inlineTemplate=!0)}function ai(e){var t,n,r,i,a,o,s,u=e.attrsList;for(t=0,n=u.length;t<n;t++)if(r=i=u[t].name,a=u[t].value,Au.test(r))if(e.hasBindings=!0,o=si(r),o&&(r=r.replace(Iu,"")),Ou.test(r))r=r.replace(Ou,""),a=Sn(a),s=!1,o&&(o.prop&&(s=!0,"innerHtml"===(r=sa(r))&&(r="innerHTML")),o.camel&&(r=sa(r)),o.sync&&jn(e,"update:"+sa(r),Rn(a,"$event"))),s||!e.component&&hu(e.tag,e.attrsMap.type,r)?An(e,r,a):Cn(e,r,a);else if(Eu.test(r))r=r.replace(Eu,""),jn(e,r,a,o,!1,su);else{r=r.replace(Au,"");var l=r.match(ju),c=l&&l[1];c&&(r=r.slice(0,-(c.length+1))),xn(e,r,i,a,c,o)}else{Cn(e,r,JSON.stringify(a)),!e.component&&"muted"===r&&hu(e.tag,e.attrsMap.type,r)&&An(e,r,"true")}}function oi(e){for(var t=e;t;){if(void 0!==t.for)return!0;t=t.parent}return!1}function si(e){var t=e.match(Iu);if(t){var n={};return t.forEach(function(e){n[e.slice(1)]=!0}),n}}function ui(e){for(var t={},n=0,r=e.length;n<r;n++)t[e[n].name]=e[n].value;return t}function li(e){return"script"===e.tag||"style"===e.tag}function ci(e){return"style"===e.tag||"script"===e.tag&&(!e.attrsMap.type||"text/javascript"===e.attrsMap.type)}function di(e){for(var t=[],n=0;n<e.length;n++){var r=e[n];Ru.test(r.name)||(r.name=r.name.replace(Du,""),t.push(r))}return t}function fi(e,t){if("input"===e.tag){var n=e.attrsMap;if(n["v-model"]&&(n["v-bind:type"]||n[":type"])){var r=On(e,"type"),i=In(e,"v-if",!0),a=i?"&&("+i+")":"",o=null!=In(e,"v-else",!0),s=In(e,"v-else-if",!0),u=hi(e);Xr(u),Ln(u,"type","checkbox"),$r(u,t),u.processed=!0,u.if="("+r+")==='checkbox'"+a,ti(u,{exp:u.if,block:u});var l=hi(e);In(l,"v-for",!0),Ln(l,"type","radio"),$r(l,t),ti(u,{exp:"("+r+")==='radio'"+a,block:l});var c=hi(e);return In(c,"v-for",!0),Ln(c,":type",r),$r(c,t),ti(u,{exp:i,block:c}),o?u.else=!0:s&&(u.elseif=s),u}}}function hi(e){return Gr(e.tag,e.attrsList.slice(),e.parent)}function pi(e,t){t.value&&An(e,"textContent","_s("+t.value+")")}function mi(e,t){t.value&&An(e,"innerHTML","_s("+t.value+")")}function vi(e,t){e&&(mu=Fu(t.staticKeys||""),vu=t.isReservedTag||da,yi(e),_i(e,!1))}function gi(e){return p("type,tag,attrsList,attrsMap,plain,parent,children,attrs"+(e?","+e:""))}function yi(e){if(e.static=bi(e),1===e.type){if(!vu(e.tag)&&"slot"!==e.tag&&null==e.attrsMap["inline-template"])return;for(var t=0,n=e.children.length;t<n;t++){var r=e.children[t];yi(r),r.static||(e.static=!1)}if(e.ifConditions)for(var i=1,a=e.ifConditions.length;i<a;i++){var o=e.ifConditions[i].block;yi(o),o.static||(e.static=!1)}}}function _i(e,t){if(1===e.type){if((e.static||e.once)&&(e.staticInFor=t),e.static&&e.children.length&&(1!==e.children.length||3!==e.children[0].type))return void(e.staticRoot=!0);if(e.staticRoot=!1,e.children)for(var n=0,r=e.children.length;n<r;n++)_i(e.children[n],t||!!e.for);if(e.ifConditions)for(var i=1,a=e.ifConditions.length;i<a;i++)_i(e.ifConditions[i].block,t)}}function bi(e){return 2!==e.type&&(3===e.type||!(!e.pre&&(e.hasBindings||e.if||e.for||ra(e.tag)||!vu(e.tag)||Ti(e)||!Object.keys(e).every(mu))))}function Ti(e){for(;e.parent;){if(e=e.parent,"template"!==e.tag)return!1;if(e.for)return!0}return!1}function Si(e,t,n){var r=t?"nativeOn:{":"on:{";for(var i in e)r+='"'+i+'":'+wi(i,e[i])+",";return r.slice(0,-1)+"}"}function wi(e,t){if(!t)return"function(){}";if(Array.isArray(t))return"["+t.map(function(t){return wi(e,t)}).join(",")+"]";var n=qu.test(t.value),r=Vu.test(t.value);if(t.modifiers){var i="",a="",o=[];for(var s in t.modifiers)if(zu[s])a+=zu[s],Gu[s]&&o.push(s);else if("exact"===s){var u=t.modifiers;a+=Hu(["ctrl","shift","alt","meta"].filter(function(e){return!u[e]}).map(function(e){return"$event."+e+"Key"}).join("||"))}else o.push(s);o.length&&(i+=ki(o)),a&&(i+=a);return"function($event){"+i+(n?t.value+"($event)":r?"("+t.value+")($event)":t.value)+"}"}return n||r?t.value:"function($event){"+t.value+"}"}function ki(e){return"if(!('button' in $event)&&"+e.map(Ei).join("&&")+")return null;"}function Ei(e){var t=parseInt(e,10);if(t)return"$event.keyCode!=="+t;var n=Gu[e];return"_k($event.keyCode,"+JSON.stringify(e)+","+JSON.stringify(n)+",$event.key)"}function Ai(e,t){e.wrapListeners=function(e){return"_g("+e+","+t.value+")"}}function Ci(e,t){e.wrapData=function(n){return"_b("+n+",'"+e.tag+"',"+t.value+","+(t.modifiers&&t.modifiers.prop?"true":"false")+(t.modifiers&&t.modifiers.sync?",true":"")+")"}}function Li(e,t){var n=new $u(t);return{render:"with(this){return "+(e?xi(e,n):'_c("div")')+"}",staticRenderFns:n.staticRenderFns}}function xi(e,t){if(e.staticRoot&&!e.staticProcessed)return ji(e,t);if(e.once&&!e.onceProcessed)return Oi(e,t);if(e.for&&!e.forProcessed)return Ri(e,t);if(e.if&&!e.ifProcessed)return Ii(e,t);if("template"!==e.tag||e.slotTarget){if("slot"===e.tag)return $i(e,t);var n;if(e.component)n=Yi(e.component,e,t);else{var r=e.plain?void 0:Di(e,t),i=e.inlineTemplate?null:Vi(e,t,!0);n="_c('"+e.tag+"'"+(r?","+r:"")+(i?","+i:"")+")"}for(var a=0;a<t.transforms.length;a++)n=t.transforms[a](e,n);return n}return Vi(e,t)||"void 0"}function ji(e,t){return e.staticProcessed=!0,t.staticRenderFns.push("with(this){return "+xi(e,t)+"}"),"_m("+(t.staticRenderFns.length-1)+(e.staticInFor?",true":"")+")"}function Oi(e,t){if(e.onceProcessed=!0,e.if&&!e.ifProcessed)return Ii(e,t);if(e.staticInFor){for(var n="",r=e.parent;r;){if(r.for){n=r.key;break}r=r.parent}return n?"_o("+xi(e,t)+","+t.onceId+++","+n+")":xi(e,t)}return ji(e,t)}function Ii(e,t,n,r){return e.ifProcessed=!0,Pi(e.ifConditions.slice(),t,n,r)}function Pi(e,t,n,r){function i(e){return n?n(e,t):e.once?Oi(e,t):xi(e,t)}if(!e.length)return r||"_e()";var a=e.shift();return a.exp?"("+a.exp+")?"+i(a.block)+":"+Pi(e,t,n,r):""+i(a.block)}function Ri(e,t,n,r){var i=e.for,a=e.alias,o=e.iterator1?","+e.iterator1:"",s=e.iterator2?","+e.iterator2:"";return e.forProcessed=!0,(r||"_l")+"(("+i+"),function("+a+o+s+"){return "+(n||xi)(e,t)+"})"}function Di(e,t){var n="{",r=Mi(e,t);r&&(n+=r+","),e.key&&(n+="key:"+e.key+","),e.ref&&(n+="ref:"+e.ref+","),e.refInFor&&(n+="refInFor:true,"),e.pre&&(n+="pre:true,"),e.component&&(n+='tag:"'+e.tag+'",');for(var i=0;i<t.dataGenFns.length;i++)n+=t.dataGenFns[i](e);if(e.attrs&&(n+="attrs:{"+Ki(e.attrs)+"},"),e.props&&(n+="domProps:{"+Ki(e.props)+"},"),e.events&&(n+=Si(e.events,!1,t.warn)+","),e.nativeEvents&&(n+=Si(e.nativeEvents,!0,t.warn)+","),e.slotTarget&&!e.slotScope&&(n+="slot:"+e.slotTarget+","),e.scopedSlots&&(n+=Bi(e.scopedSlots,t)+","),e.model&&(n+="model:{value:"+e.model.value+",callback:"+e.model.callback+",expression:"+e.model.expression+"},"),e.inlineTemplate){var a=Ui(e,t);a&&(n+=a+",")}return n=n.replace(/,$/,"")+"}",e.wrapData&&(n=e.wrapData(n)),e.wrapListeners&&(n=e.wrapListeners(n)),n}function Mi(e,t){var n=e.directives;if(n){var r,i,a,o,s="directives:[",u=!1;for(r=0,i=n.length;r<i;r++){a=n[r],o=!0;var l=t.directives[a.name];l&&(o=!!l(e,a,t.warn)),o&&(u=!0,s+='{name:"'+a.name+'",rawName:"'+a.rawName+'"'+(a.value?",value:("+a.value+"),expression:"+JSON.stringify(a.value):"")+(a.arg?',arg:"'+a.arg+'"':"")+(a.modifiers?",modifiers:"+JSON.stringify(a.modifiers):"")+"},")}return u?s.slice(0,-1)+"]":void 0}}function Ui(e,t){var n=e.children[0];if(1===n.type){var r=Li(n,t.options);return"inlineTemplate:{render:function(){"+r.render+"},staticRenderFns:["+r.staticRenderFns.map(function(e){return"function(){"+e+"}"}).join(",")+"]}"}}function Bi(e,t){return"scopedSlots:_u(["+Object.keys(e).map(function(n){return Ni(n,e[n],t)}).join(",")+"])"}function Ni(e,t,n){return t.for&&!t.forProcessed?Fi(e,t,n):"{key:"+e+",fn:function("+String(t.slotScope)+"){return "+("template"===t.tag?t.if?t.if+"?"+(Vi(t,n)||"undefined")+":undefined":Vi(t,n)||"undefined":xi(t,n))+"}}"}function Fi(e,t,n){var r=t.for,i=t.alias,a=t.iterator1?","+t.iterator1:"",o=t.iterator2?","+t.iterator2:"";return t.forProcessed=!0,"_l(("+r+"),function("+i+a+o+"){return "+Ni(e,t,n)+"})"}function Vi(e,t,n,r,i){var a=e.children;if(a.length){var o=a[0];if(1===a.length&&o.for&&"template"!==o.tag&&"slot"!==o.tag)return(r||xi)(o,t);var s=n?qi(a,t.maybeComponent):0,u=i||Hi;return"["+a.map(function(e){return u(e,t)}).join(",")+"]"+(s?","+s:"")}}function qi(e,t){for(var n=0,r=0;r<e.length;r++){var i=e[r];if(1===i.type){if(Gi(i)||i.ifConditions&&i.ifConditions.some(function(e){return Gi(e.block)})){n=2;break}(t(i)||i.ifConditions&&i.ifConditions.some(function(e){return t(e.block)}))&&(n=1)}}return n}function Gi(e){return void 0!==e.for||"template"===e.tag||"slot"===e.tag}function Hi(e,t){return 1===e.type?xi(e,t):3===e.type&&e.isComment?Wi(e):zi(e)}function zi(e){return"_v("+(2===e.type?e.expression:Xi(JSON.stringify(e.text)))+")"}function Wi(e){return"_e("+JSON.stringify(e.text)+")"}function $i(e,t){var n=e.slotName||'"default"',r=Vi(e,t),i="_t("+n+(r?","+r:""),a=e.attrs&&"{"+e.attrs.map(function(e){return sa(e.name)+":"+e.value}).join(",")+"}",o=e.attrsMap["v-bind"];return!a&&!o||r||(i+=",null"),a&&(i+=","+a),o&&(i+=(a?"":",null")+","+o),i+")"}function Yi(e,t,n){var r=t.inlineTemplate?null:Vi(t,n,!0);return"_c("+e+","+Di(t,n)+(r?","+r:"")+")"}function Ki(e){for(var t="",n=0;n<e.length;n++){var r=e[n];t+='"'+r.name+'":'+Xi(r.value)+","}return t.slice(0,-1)}function Xi(e){return e.replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}function Ji(e,t){try{return new Function(e)}catch(n){return t.push({err:n,code:e}),S}}function Qi(e){var t=Object.create(null);return function(n,r,i){r=b({},r);r.warn;delete r.warn;var a=r.delimiters?String(r.delimiters)+n:n;if(t[a])return t[a];var o=e(n,r),s={},u=[];return s.render=Ji(o.render,u),s.staticRenderFns=o.staticRenderFns.map(function(e){return Ji(e,u)}),t[a]=s}}function Zi(e){return gu=gu||document.createElement("div"),gu.innerHTML=e?'<a href="\n"/>':'<div a="\n"/>',gu.innerHTML.indexOf("&#10;")>0}function ea(e){if(e.outerHTML)return e.outerHTML;var t=document.createElement("div");return t.appendChild(e.cloneNode(!0)),t.innerHTML}var ta=Object.freeze({}),na=Object.prototype.toString,ra=p("slot,component",!0),ia=p("key,ref,slot,slot-scope,is"),aa=Object.prototype.hasOwnProperty,oa=/-(\w)/g,sa=g(function(e){return e.replace(oa,function(e,t){return t?t.toUpperCase():""})}),ua=g(function(e){return e.charAt(0).toUpperCase()+e.slice(1)}),la=/\B([A-Z])/g,ca=g(function(e){return e.replace(la,"-$1").toLowerCase()}),da=function(e,t,n){return!1},fa=function(e){return e},ha="data-server-rendered",pa=["component","directive","filter"],ma=["beforeCreate","created","beforeMount","mounted","beforeUpdate","updated","beforeDestroy","destroyed","activated","deactivated","errorCaptured"],va={optionMergeStrategies:Object.create(null),silent:!1,productionTip:!1,devtools:!1,performance:!1,errorHandler:null,warnHandler:null,ignoredElements:[],keyCodes:Object.create(null),isReservedTag:da,isReservedAttr:da,isUnknownElement:da,getTagNamespace:S,parsePlatformTagName:fa,mustUseProp:da,_lifecycleHooks:ma},ga=/[^\w.$]/,ya="__proto__"in{},_a="undefined"!=typeof window,ba="undefined"!=typeof WXEnvironment&&!!WXEnvironment.platform,Ta=ba&&WXEnvironment.platform.toLowerCase(),Sa=_a&&window.navigator.userAgent.toLowerCase(),wa=Sa&&/msie|trident/.test(Sa),ka=Sa&&Sa.indexOf("msie 9.0")>0,Ea=Sa&&Sa.indexOf("edge/")>0,Aa=Sa&&Sa.indexOf("android")>0||"android"===Ta,Ca=Sa&&/iphone|ipad|ipod|ios/.test(Sa)||"ios"===Ta,La=(Sa&&/chrome\/\d+/.test(Sa),{}.watch),xa=!1;if(_a)try{var ja={};Object.defineProperty(ja,"passive",{get:function(){xa=!0}}),window.addEventListener("test-passive",null,ja)}catch(e){}var Oa,Ia,Pa=function(){return void 0===Oa&&(Oa=!_a&&void 0!==t&&"server"===t.process.env.VUE_ENV),Oa},Ra=_a&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__,Da="undefined"!=typeof Symbol&&x(Symbol)&&"undefined"!=typeof Reflect&&x(Reflect.ownKeys);Ia="undefined"!=typeof Set&&x(Set)?Set:function(){function e(){this.set=Object.create(null)}return e.prototype.has=function(e){return!0===this.set[e]},e.prototype.add=function(e){this.set[e]=!0},e.prototype.clear=function(){this.set=Object.create(null)},e}();var Ma=S,Ua=0,Ba=function(){this.id=Ua++,this.subs=[]};Ba.prototype.addSub=function(e){this.subs.push(e)},Ba.prototype.removeSub=function(e){m(this.subs,e)},Ba.prototype.depend=function(){Ba.target&&Ba.target.addDep(this)},Ba.prototype.notify=function(){for(var e=this.subs.slice(),t=0,n=e.length;t<n;t++)e[t].update()},Ba.target=null;var Na=[],Fa=function(e,t,n,r,i,a,o,s){this.tag=e,this.data=t,this.children=n,this.text=r,this.elm=i,this.ns=void 0,this.context=a,this.fnContext=void 0,this.fnOptions=void 0,this.fnScopeId=void 0,this.key=t&&t.key,this.componentOptions=o,this.componentInstance=void 0,this.parent=void 0,this.raw=!1,this.isStatic=!1,this.isRootInsert=!0,this.isComment=!1,this.isCloned=!1,this.isOnce=!1,this.asyncFactory=s,this.asyncMeta=void 0,this.isAsyncPlaceholder=!1},Va={child:{configurable:!0}};Va.child.get=function(){return this.componentInstance},Object.defineProperties(Fa.prototype,Va);var qa=function(e){void 0===e&&(e="");var t=new Fa;return t.text=e,t.isComment=!0,t},Ga=Array.prototype,Ha=Object.create(Ga);["push","pop","shift","unshift","splice","sort","reverse"].forEach(function(e){var t=Ga[e];C(Ha,e,function(){for(var n=[],r=arguments.length;r--;)n[r]=arguments[r];var i,a=t.apply(this,n),o=this.__ob__;switch(e){case"push":case"unshift":i=n;break;case"splice":i=n.slice(2)}return i&&o.observeArray(i),o.dep.notify(),a})});var za=Object.getOwnPropertyNames(Ha),Wa={shouldConvert:!0},$a=function(e){if(this.value=e,this.dep=new Ba,this.vmCount=0,C(e,"__ob__",this),Array.isArray(e)){(ya?D:M)(e,Ha,za),this.observeArray(e)}else this.walk(e)};$a.prototype.walk=function(e){for(var t=Object.keys(e),n=0;n<t.length;n++)B(e,t[n],e[t[n]])},$a.prototype.observeArray=function(e){for(var t=0,n=e.length;t<n;t++)U(e[t])};var Ya=va.optionMergeStrategies;Ya.data=function(e,t,n){return n?G(e,t,n):t&&"function"!=typeof t?e:G(e,t)},ma.forEach(function(e){Ya[e]=H}),pa.forEach(function(e){Ya[e+"s"]=z}),Ya.watch=function(e,t,n,r){if(e===La&&(e=void 0),t===La&&(t=void 0),!t)return Object.create(e||null);if(!e)return t;var i={};b(i,e);for(var a in t){var o=i[a],s=t[a];o&&!Array.isArray(o)&&(o=[o]),i[a]=o?o.concat(s):Array.isArray(s)?s:[s]}return i},Ya.props=Ya.methods=Ya.inject=Ya.computed=function(e,t,n,r){if(!e)return t;var i=Object.create(null);return b(i,e),t&&b(i,t),i},Ya.provide=G;var Ka,Xa,Ja=function(e,t){return void 0===t?e:t},Qa=[],Za=!1,eo=!1;if(void 0!==n&&x(n))Xa=function(){n(ie)};else if("undefined"==typeof MessageChannel||!x(MessageChannel)&&"[object MessageChannelConstructor]"!==MessageChannel.toString())Xa=function(){setTimeout(ie,0)};else{var to=new MessageChannel,no=to.port2;to.port1.onmessage=ie,Xa=function(){no.postMessage(1)}}if("undefined"!=typeof Promise&&x(Promise)){var ro=Promise.resolve();Ka=function(){ro.then(ie),Ca&&setTimeout(S)}}else Ka=Xa;var io,ao=new Ia,oo=g(function(e){var t="&"===e.charAt(0);e=t?e.slice(1):e;var n="~"===e.charAt(0);e=n?e.slice(1):e;var r="!"===e.charAt(0);return e=r?e.slice(1):e,{name:e,once:n,capture:r,passive:t}}),so=null,uo=[],lo=[],co={},fo=!1,ho=!1,po=0,mo=0,vo=function(e,t,n,r,i){this.vm=e,i&&(e._watcher=this),e._watchers.push(this),r?(this.deep=!!r.deep,this.user=!!r.user,this.lazy=!!r.lazy,this.sync=!!r.sync):this.deep=this.user=this.lazy=this.sync=!1,this.cb=n,this.id=++mo,this.active=!0,this.dirty=this.lazy,this.deps=[],this.newDeps=[],this.depIds=new Ia,this.newDepIds=new Ia,this.expression="","function"==typeof t?this.getter=t:(this.getter=L(t),this.getter||(this.getter=function(){})),this.value=this.lazy?void 0:this.get()};vo.prototype.get=function(){j(this);var e,t=this.vm;try{e=this.getter.call(t,t)}catch(e){if(!this.user)throw e;te(e,t,'getter for watcher "'+this.expression+'"')}finally{this.deep&&se(e),O(),this.cleanupDeps()}return e},vo.prototype.addDep=function(e){var t=e.id;this.newDepIds.has(t)||(this.newDepIds.add(t),this.newDeps.push(e),this.depIds.has(t)||e.addSub(this))},vo.prototype.cleanupDeps=function(){for(var e=this,t=this.deps.length;t--;){var n=e.deps[t];e.newDepIds.has(n.id)||n.removeSub(e)}var r=this.depIds;this.depIds=this.newDepIds,this.newDepIds=r,this.newDepIds.clear(),r=this.deps,this.deps=this.newDeps,this.newDeps=r,this.newDeps.length=0},vo.prototype.update=function(){this.lazy?this.dirty=!0:this.sync?this.run():qe(this)},vo.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||u(e)||this.deep){var t=this.value;if(this.value=e,this.user)try{this.cb.call(this.vm,e,t)}catch(e){te(e,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,e,t)}}},vo.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},vo.prototype.depend=function(){for(var e=this,t=this.deps.length;t--;)e.deps[t].depend()},vo.prototype.teardown=function(){var e=this;if(this.active){this.vm._isBeingDestroyed||m(this.vm._watchers,this);for(var t=this.deps.length;t--;)e.deps[t].removeSub(e);this.active=!1}};var go={enumerable:!0,configurable:!0,get:S,set:S},yo={lazy:!0};ht(pt.prototype);var _o={init:function(e,t,n,r){if(!e.componentInstance||e.componentInstance._isDestroyed){(e.componentInstance=yt(e,so,n,r)).$mount(t?e.elm:void 0,t)}else if(e.data.keepAlive){var i=e;_o.prepatch(i,i)}},prepatch:function(e,t){var n=t.componentOptions;Ie(t.componentInstance=e.componentInstance,n.propsData,n.listeners,t,n.children)},insert:function(e){var t=e.context,n=e.componentInstance;n._isMounted||(n._isMounted=!0,Me(n,"mounted")),e.data.keepAlive&&(t._isMounted?Fe(n):Re(n,!0))},destroy:function(e){var t=e.componentInstance;t._isDestroyed||(e.data.keepAlive?De(t,!0):t.$destroy())}},bo=Object.keys(_o),To=1,So=2,wo=0;!function(e){e.prototype._init=function(e){var t=this;t._uid=wo++,t._isVue=!0,e&&e._isComponent?At(t,e):t.$options=K(Ct(t.constructor),e||{},t),t._renderProxy=t,t._self=t,je(t),we(t),Et(t),Me(t,"beforeCreate"),tt(t),He(t),et(t),Me(t,"created"),t.$options.el&&t.$mount(t.$options.el)}}(jt),function(e){var t={};t.get=function(){return this._data};var n={};n.get=function(){return this._props},Object.defineProperty(e.prototype,"$data",t),Object.defineProperty(e.prototype,"$props",n),e.prototype.$set=N,e.prototype.$delete=F,e.prototype.$watch=function(e,t,n){var r=this;if(l(t))return Ze(r,e,t,n);n=n||{},n.user=!0;var i=new vo(r,e,t,n);return n.immediate&&t.call(r,i.value),function(){i.teardown()}}}(jt),function(e){var t=/^hook:/;e.prototype.$on=function(e,n){var r=this,i=this;if(Array.isArray(e))for(var a=0,o=e.length;a<o;a++)r.$on(e[a],n);else(i._events[e]||(i._events[e]=[])).push(n),t.test(e)&&(i._hasHookEvent=!0);return i},e.prototype.$once=function(e,t){function n(){r.$off(e,n),t.apply(r,arguments)}var r=this;return n.fn=t,r.$on(e,n),r},e.prototype.$off=function(e,t){var n=this,r=this;if(!arguments.length)return r._events=Object.create(null),r;if(Array.isArray(e)){for(var i=0,a=e.length;i<a;i++)n.$off(e[i],t);return r}var o=r._events[e];if(!o)return r;if(!t)return r._events[e]=null,r;if(t)for(var s,u=o.length;u--;)if((s=o[u])===t||s.fn===t){o.splice(u,1);break}return r},e.prototype.$emit=function(e){var t=this,n=t._events[e];if(n){n=n.length>1?_(n):n;for(var r=_(arguments,1),i=0,a=n.length;i<a;i++)try{n[i].apply(t,r)}catch(n){te(n,t,'event handler for "'+e+'"')}}return t}}(jt),function(e){e.prototype._update=function(e,t){var n=this;n._isMounted&&Me(n,"beforeUpdate");var r=n.$el,i=n._vnode,a=so;so=n,n._vnode=e,i?n.$el=n.__patch__(i,e):(n.$el=n.__patch__(n.$el,e,t,!1,n.$options._parentElm,n.$options._refElm),n.$options._parentElm=n.$options._refElm=null),so=a,r&&(r.__vue__=null),n.$el&&(n.$el.__vue__=n),n.$vnode&&n.$parent&&n.$vnode===n.$parent._vnode&&(n.$parent.$el=n.$el)},e.prototype.$forceUpdate=function(){var e=this;e._watcher&&e._watcher.update()},e.prototype.$destroy=function(){var e=this;if(!e._isBeingDestroyed){Me(e,"beforeDestroy"),e._isBeingDestroyed=!0;var t=e.$parent;!t||t._isBeingDestroyed||e.$options.abstract||m(t.$children,e),e._watcher&&e._watcher.teardown();for(var n=e._watchers.length;n--;)e._watchers[n].teardown();e._data.__ob__&&e._data.__ob__.vmCount--,e._isDestroyed=!0,e.__patch__(e._vnode,null),Me(e,"destroyed"),e.$off(),e.$el&&(e.$el.__vue__=null),e.$vnode&&(e.$vnode.parent=null)}}}(jt),function(e){ht(e.prototype),e.prototype.$nextTick=function(e){return oe(e,this)},e.prototype._render=function(){var e=this,t=e.$options,n=t.render,r=t._parentVnode;if(e._isMounted)for(var i in e.$slots){var a=e.$slots[i];(a._rendered||a[0]&&a[0].elm)&&(e.$slots[i]=R(a,!0))}e.$scopedSlots=r&&r.data.scopedSlots||ta,e.$vnode=r;var o;try{o=n.call(e._renderProxy,e.$createElement)}catch(t){te(t,e,"render"),o=e._vnode}return o instanceof Fa||(o=qa()),o.parent=r,o}}(jt);var ko=[String,RegExp,Array],Eo={name:"keep-alive",abstract:!0,props:{include:ko,exclude:ko,max:[String,Number]},created:function(){this.cache=Object.create(null),this.keys=[]},destroyed:function(){var e=this;for(var t in e.cache)Ft(e.cache,t,e.keys)},watch:{include:function(e){Nt(this,function(t){return Bt(e,t)})},exclude:function(e){Nt(this,function(t){return!Bt(e,t)})}},render:function(){var e=this.$slots.default,t=Se(e),n=t&&t.componentOptions;if(n){var r=Ut(n),i=this,a=i.include,o=i.exclude;if(a&&(!r||!Bt(a,r))||o&&r&&Bt(o,r))return t;var s=this,u=s.cache,l=s.keys,c=null==t.key?n.Ctor.cid+(n.tag?"::"+n.tag:""):t.key;u[c]?(t.componentInstance=u[c].componentInstance,m(l,c),l.push(c)):(u[c]=t,l.push(c),this.max&&l.length>parseInt(this.max)&&Ft(u,l[0],l,this._vnode)),t.data.keepAlive=!0}return t||e&&e[0]}},Ao={KeepAlive:Eo};!function(e){var t={};t.get=function(){return va},Object.defineProperty(e,"config",t),e.util={warn:Ma,extend:b,mergeOptions:K,defineReactive:B},e.set=N,e.delete=F,e.nextTick=oe,e.options=Object.create(null),pa.forEach(function(t){e.options[t+"s"]=Object.create(null)}),e.options._base=e,b(e.options.components,Ao),Ot(e),It(e),Pt(e),Mt(e)}(jt),Object.defineProperty(jt.prototype,"$isServer",{get:Pa}),Object.defineProperty(jt.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),jt.version="2.5.13";var Co,Lo,xo,jo,Oo,Io,Po,Ro,Do,Mo=p("style,class"),Uo=p("input,textarea,option,select,progress"),Bo=function(e,t,n){return"value"===n&&Uo(e)&&"button"!==t||"selected"===n&&"option"===e||"checked"===n&&"input"===e||"muted"===n&&"video"===e},No=p("contenteditable,draggable,spellcheck"),Fo=p("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,translate,truespeed,typemustmatch,visible"),Vo="http://www.w3.org/1999/xlink",qo=function(e){return":"===e.charAt(5)&&"xlink"===e.slice(0,5)},Go=function(e){return qo(e)?e.slice(6,e.length):""},Ho=function(e){return null==e||!1===e},zo={svg:"http://www.w3.org/2000/svg",math:"http://www.w3.org/1998/Math/MathML"},Wo=p("html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,menuitem,summary,content,element,shadow,template,blockquote,iframe,tfoot"),$o=p("svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view",!0),Yo=function(e){return"pre"===e},Ko=function(e){return Wo(e)||$o(e)},Xo=Object.create(null),Jo=p("text,number,password,search,email,tel,url"),Qo=Object.freeze({createElement:Jt,createElementNS:Qt,createTextNode:Zt,createComment:en,insertBefore:tn,removeChild:nn,appendChild:rn,parentNode:an,nextSibling:on,tagName:sn,setTextContent:un,setAttribute:ln}),Zo={create:function(e,t){cn(t)},update:function(e,t){e.data.ref!==t.data.ref&&(cn(e,!0),cn(t))},destroy:function(e){cn(e,!0)}},es=new Fa("",{},[]),ts=["create","activate","update","remove","destroy"],ns={create:pn,update:pn,destroy:function(e){pn(e,es)}},rs=Object.create(null),is=[Zo,ns],as={create:_n,update:_n},os={create:Tn,update:Tn},ss=/[\w).+\-_$\]]/,us="__r",ls="__c",cs={create:Xn,update:Xn},ds={create:Jn,update:Jn},fs=g(function(e){var t={},n=/;(?![^(]*\))/g,r=/:(.+)/;return e.split(n).forEach(function(e){if(e){var n=e.split(r);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}),hs=/^--/,ps=/\s*!important$/,ms=function(e,t,n){if(hs.test(t))e.style.setProperty(t,n);else if(ps.test(n))e.style.setProperty(t,n.replace(ps,""),"important");else{var r=gs(t);if(Array.isArray(n))for(var i=0,a=n.length;i<a;i++)e.style[r]=n[i];else e.style[r]=n}},vs=["Webkit","Moz","ms"],gs=g(function(e){if(Do=Do||document.createElement("div").style,"filter"!==(e=sa(e))&&e in Do)return e;for(var t=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<vs.length;n++){var r=vs[n]+t;if(r in Do)return r}}),ys={create:ir,update:ir},_s=g(function(e){return{enterClass:e+"-enter",enterToClass:e+"-enter-to",enterActiveClass:e+"-enter-active",leaveClass:e+"-leave",leaveToClass:e+"-leave-to",leaveActiveClass:e+"-leave-active"}}),bs=_a&&!ka,Ts="transition",Ss="animation",ws="transition",ks="transitionend",Es="animation",As="animationend";bs&&(void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend&&(ws="WebkitTransition",ks="webkitTransitionEnd"),void 0===window.onanimationend&&void 0!==window.onwebkitanimationend&&(Es="WebkitAnimation",As="webkitAnimationEnd"));var Cs=_a?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(e){return e()},Ls=/\b(transform|all)(,|$)/,xs=_a?{create:_r,activate:_r,remove:function(e,t){!0!==e.data.show?vr(e,t):t()}}:{},js=[as,os,cs,ds,ys,xs],Os=js.concat(is),Is=function(e){function t(e){return new Fa(O.tagName(e).toLowerCase(),{},[],void 0,e)}function n(e,t){function n(){0==--n.listeners&&o(e)}return n.listeners=t,n}function o(e){var t=O.parentNode(e);i(t)&&O.removeChild(t,e)}function u(e,t,n,r,o){if(e.isRootInsert=!o,!l(e,t,n,r)){var s=e.data,u=e.children,c=e.tag;i(c)?(e.elm=e.ns?O.createElementNS(e.ns,c):O.createElement(c,e),g(e),h(e,u,t),i(s)&&v(e,t),f(n,e.elm,r)):a(e.isComment)?(e.elm=O.createComment(e.text),f(n,e.elm,r)):(e.elm=O.createTextNode(e.text),f(n,e.elm,r))}}function l(e,t,n,r){var o=e.data;if(i(o)){var s=i(e.componentInstance)&&o.keepAlive;if(i(o=o.hook)&&i(o=o.init)&&o(e,!1,n,r),i(e.componentInstance))return c(e,t),a(s)&&d(e,t,n,r),!0}}function c(e,t){i(e.data.pendingInsert)&&(t.push.apply(t,e.data.pendingInsert),e.data.pendingInsert=null),e.elm=e.componentInstance.$el,m(e)?(v(e,t),g(e)):(cn(e),t.push(e))}function d(e,t,n,r){for(var a,o=e;o.componentInstance;)if(o=o.componentInstance._vnode,i(a=o.data)&&i(a=a.transition)){for(a=0;a<x.activate.length;++a)x.activate[a](es,o);t.push(o);break}f(n,e.elm,r)}function f(e,t,n){i(e)&&(i(n)?n.parentNode===e&&O.insertBefore(e,t,n):O.appendChild(e,t))}function h(e,t,n){if(Array.isArray(t))for(var r=0;r<t.length;++r)u(t[r],n,e.elm,null,!0);else s(e.text)&&O.appendChild(e.elm,O.createTextNode(String(e.text)))}function m(e){for(;e.componentInstance;)e=e.componentInstance._vnode;return i(e.tag)}function v(e,t){for(var n=0;n<x.create.length;++n)x.create[n](es,e);C=e.data.hook,i(C)&&(i(C.create)&&C.create(es,e),i(C.insert)&&t.push(e))}function g(e){var t;if(i(t=e.fnScopeId))O.setAttribute(e.elm,t,"");else for(var n=e;n;)i(t=n.context)&&i(t=t.$options._scopeId)&&O.setAttribute(e.elm,t,""),n=n.parent;i(t=so)&&t!==e.context&&t!==e.fnContext&&i(t=t.$options._scopeId)&&O.setAttribute(e.elm,t,"")}function y(e,t,n,r,i,a){for(;r<=i;++r)u(n[r],a,e,t)}function _(e){var t,n,r=e.data;if(i(r))for(i(t=r.hook)&&i(t=t.destroy)&&t(e),t=0;t<x.destroy.length;++t)x.destroy[t](e);if(i(t=e.children))for(n=0;n<e.children.length;++n)_(e.children[n])}function b(e,t,n,r){for(;n<=r;++n){var a=t[n];i(a)&&(i(a.tag)?(T(a),_(a)):o(a.elm))}}function T(e,t){if(i(t)||i(e.data)){var r,a=x.remove.length+1;for(i(t)?t.listeners+=a:t=n(e.elm,a),i(r=e.componentInstance)&&i(r=r._vnode)&&i(r.data)&&T(r,t),r=0;r<x.remove.length;++r)x.remove[r](e,t);i(r=e.data.hook)&&i(r=r.remove)?r(e,t):t()}else o(e.elm)}function S(e,t,n,a,o){for(var s,l,c,d,f=0,h=0,p=t.length-1,m=t[0],v=t[p],g=n.length-1,_=n[0],T=n[g],S=!o;f<=p&&h<=g;)r(m)?m=t[++f]:r(v)?v=t[--p]:dn(m,_)?(k(m,_,a),m=t[++f],_=n[++h]):dn(v,T)?(k(v,T,a),v=t[--p],T=n[--g]):dn(m,T)?(k(m,T,a),S&&O.insertBefore(e,m.elm,O.nextSibling(v.elm)),m=t[++f],T=n[--g]):dn(v,_)?(k(v,_,a),S&&O.insertBefore(e,v.elm,m.elm),v=t[--p],_=n[++h]):(r(s)&&(s=hn(t,f,p)),l=i(_.key)?s[_.key]:w(_,t,f,p),r(l)?u(_,a,e,m.elm):(c=t[l],dn(c,_)?(k(c,_,a),t[l]=void 0,S&&O.insertBefore(e,c.elm,m.elm)):u(_,a,e,m.elm)),_=n[++h]);f>p?(d=r(n[g+1])?null:n[g+1].elm,y(e,d,n,h,g,a)):h>g&&b(e,t,f,p)}function w(e,t,n,r){for(var a=n;a<r;a++){var o=t[a];if(i(o)&&dn(e,o))return a}}function k(e,t,n,o){if(e!==t){var s=t.elm=e.elm;if(a(e.isAsyncPlaceholder))return void(i(t.asyncFactory.resolved)?A(e.elm,t,n):t.isAsyncPlaceholder=!0);if(a(t.isStatic)&&a(e.isStatic)&&t.key===e.key&&(a(t.isCloned)||a(t.isOnce)))return void(t.componentInstance=e.componentInstance);var u,l=t.data;i(l)&&i(u=l.hook)&&i(u=u.prepatch)&&u(e,t);var c=e.children,d=t.children;if(i(l)&&m(t)){for(u=0;u<x.update.length;++u)x.update[u](e,t);i(u=l.hook)&&i(u=u.update)&&u(e,t)}r(t.text)?i(c)&&i(d)?c!==d&&S(s,c,d,n,o):i(d)?(i(e.text)&&O.setTextContent(s,""),y(s,null,d,0,d.length-1,n)):i(c)?b(s,c,0,c.length-1):i(e.text)&&O.setTextContent(s,""):e.text!==t.text&&O.setTextContent(s,t.text),i(l)&&i(u=l.hook)&&i(u=u.postpatch)&&u(e,t)}}function E(e,t,n){if(a(n)&&i(e.parent))e.parent.data.pendingInsert=t;else for(var r=0;r<t.length;++r)t[r].data.hook.insert(t[r])}function A(e,t,n,r){var o,s=t.tag,u=t.data,l=t.children;if(r=r||u&&u.pre,t.elm=e,a(t.isComment)&&i(t.asyncFactory))return t.isAsyncPlaceholder=!0,!0;if(i(u)&&(i(o=u.hook)&&i(o=o.init)&&o(t,!0),i(o=t.componentInstance)))return c(t,n),!0;if(i(s)){if(i(l))if(e.hasChildNodes())if(i(o=u)&&i(o=o.domProps)&&i(o=o.innerHTML)){if(o!==e.innerHTML)return!1}else{for(var d=!0,f=e.firstChild,p=0;p<l.length;p++){if(!f||!A(f,l[p],n,r)){d=!1;break}f=f.nextSibling}if(!d||f)return!1}else h(t,l,n);if(i(u)){var m=!1;for(var g in u)if(!I(g)){m=!0,v(t,n);break}!m&&u.class&&se(u.class)}}else e.data!==t.text&&(e.data=t.text);return!0}var C,L,x={},j=e.modules,O=e.nodeOps;for(C=0;C<ts.length;++C)for(x[ts[C]]=[],L=0;L<j.length;++L)i(j[L][ts[C]])&&x[ts[C]].push(j[L][ts[C]]);var I=p("attrs,class,staticClass,staticStyle,key");return function(e,n,o,s,l,c){if(r(n))return void(i(e)&&_(e));var d=!1,f=[];if(r(e))d=!0,u(n,f,l,c);else{var h=i(e.nodeType);if(!h&&dn(e,n))k(e,n,f,s);else{if(h){if(1===e.nodeType&&e.hasAttribute(ha)&&(e.removeAttribute(ha),o=!0),a(o)&&A(e,n,f))return E(n,f,!0),e;e=t(e)}var p=e.elm,v=O.parentNode(p);if(u(n,f,p._leaveCb?null:v,O.nextSibling(p)),i(n.parent))for(var g=n.parent,y=m(n);g;){for(var T=0;T<x.destroy.length;++T)x.destroy[T](g);if(g.elm=n.elm,y){for(var S=0;S<x.create.length;++S)x.create[S](es,g);var w=g.data.hook.insert;if(w.merged)for(var C=1;C<w.fns.length;C++)w.fns[C]()}else cn(g);g=g.parent}i(v)?b(v,[e],0,0):i(e.tag)&&_(e)}}return E(n,f,d),n.elm}}({nodeOps:Qo,modules:Os});ka&&document.addEventListener("selectionchange",function(){var e=document.activeElement;e&&e.vmodel&&Ar(e,"input")});var Ps={inserted:function(e,t,n,r){"select"===n.tag?(r.elm&&!r.elm._vOptions?de(n,"postpatch",function(){Ps.componentUpdated(e,t,n)}):br(e,t,n.context),e._vOptions=[].map.call(e.options,wr)):("textarea"===n.tag||Jo(e.type))&&(e._vModifiers=t.modifiers,t.modifiers.lazy||(e.addEventListener("change",Er),Aa||(e.addEventListener("compositionstart",kr),e.addEventListener("compositionend",Er)),ka&&(e.vmodel=!0)))},componentUpdated:function(e,t,n){if("select"===n.tag){br(e,t,n.context);var r=e._vOptions,i=e._vOptions=[].map.call(e.options,wr);if(i.some(function(e,t){return!w(e,r[t])})){(e.multiple?t.value.some(function(e){return Sr(e,i)}):t.value!==t.oldValue&&Sr(t.value,i))&&Ar(e,"change")}}}},Rs={bind:function(e,t,n){var r=t.value;n=Cr(n);var i=n.data&&n.data.transition,a=e.__vOriginalDisplay="none"===e.style.display?"":e.style.display;r&&i?(n.data.show=!0,mr(n,function(){e.style.display=a})):e.style.display=r?a:"none"},update:function(e,t,n){var r=t.value;r!==t.oldValue&&(n=Cr(n),n.data&&n.data.transition?(n.data.show=!0,r?mr(n,function(){e.style.display=e.__vOriginalDisplay}):vr(n,function(){e.style.display="none"})):e.style.display=r?e.__vOriginalDisplay:"none")},unbind:function(e,t,n,r,i){i||(e.style.display=e.__vOriginalDisplay)}},Ds={model:Ps,show:Rs},Ms={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]},Us={name:"transition",props:Ms,abstract:!0,render:function(e){var t=this,n=this.$slots.default;if(n&&(n=n.filter(function(e){return e.tag||Te(e)}),n.length)){var r=this.mode,i=n[0];if(Or(this.$vnode))return i;var a=Lr(i);if(!a)return i;if(this._leaving)return jr(e,i);var o="__transition-"+this._uid+"-";a.key=null==a.key?a.isComment?o+"comment":o+a.tag:s(a.key)?0===String(a.key).indexOf(o)?a.key:o+a.key:a.key;var u=(a.data||(a.data={})).transition=xr(this),l=this._vnode,c=Lr(l);if(a.data.directives&&a.data.directives.some(function(e){return"show"===e.name})&&(a.data.show=!0),c&&c.data&&!Ir(a,c)&&!Te(c)&&(!c.componentInstance||!c.componentInstance._vnode.isComment)){var d=c.data.transition=b({},u);if("out-in"===r)return this._leaving=!0,de(d,"afterLeave",function(){t._leaving=!1,t.$forceUpdate()}),jr(e,i);if("in-out"===r){if(Te(a))return l;var f,h=function(){f()};de(u,"afterEnter",h),de(u,"enterCancelled",h),de(d,"delayLeave",function(e){f=e})}}return i}}},Bs=b({tag:String,moveClass:String},Ms);delete Bs.mode;var Ns={props:Bs,render:function(e){for(var t=this.tag||this.$vnode.data.tag||"span",n=Object.create(null),r=this.prevChildren=this.children,i=this.$slots.default||[],a=this.children=[],o=xr(this),s=0;s<i.length;s++){var u=i[s];if(u.tag)if(null!=u.key&&0!==String(u.key).indexOf("__vlist"))a.push(u),n[u.key]=u,(u.data||(u.data={})).transition=o;else;}if(r){for(var l=[],c=[],d=0;d<r.length;d++){var f=r[d];f.data.transition=o,f.data.pos=f.elm.getBoundingClientRect(),n[f.key]?l.push(f):c.push(f)}this.kept=e(t,null,l),this.removed=c}return e(t,null,a)},beforeUpdate:function(){this.__patch__(this._vnode,this.kept,!1,!0),this._vnode=this.kept},updated:function(){var e=this.prevChildren,t=this.moveClass||(this.name||"v")+"-move";e.length&&this.hasMove(e[0].elm,t)&&(e.forEach(Pr),e.forEach(Rr),e.forEach(Dr),this._reflow=document.body.offsetHeight,e.forEach(function(e){if(e.data.moved){var n=e.elm,r=n.style;lr(n,t),r.transform=r.WebkitTransform=r.transitionDuration="",n.addEventListener(ks,n._moveCb=function e(r){r&&!/transform$/.test(r.propertyName)||(n.removeEventListener(ks,e),n._moveCb=null,cr(n,t))})}}))},methods:{hasMove:function(e,t){if(!bs)return!1;if(this._hasMove)return this._hasMove;var n=e.cloneNode();e._transitionClasses&&e._transitionClasses.forEach(function(e){or(n,e)}),ar(n,t),n.style.display="none",this.$el.appendChild(n);var r=fr(n);return this.$el.removeChild(n),this._hasMove=r.hasTransform}}},Fs={Transition:Us,TransitionGroup:Ns};jt.config.mustUseProp=Bo,jt.config.isReservedTag=Ko,jt.config.isReservedAttr=Mo,jt.config.getTagNamespace=Yt,jt.config.isUnknownElement=Kt,b(jt.options.directives,Ds),b(jt.options.components,Fs),jt.prototype.__patch__=_a?Is:S,jt.prototype.$mount=function(e,t){return e=e&&_a?Xt(e):void 0,Oe(this,e,t)},jt.nextTick(function(){va.devtools&&Ra&&Ra.emit("init",jt)},0);var Vs,qs=/\{\{((?:.|\n)+?)\}\}/g,Gs=/[-.*+?^${}()|[\]\/\\]/g,Hs=g(function(e){var t=e[0].replace(Gs,"\\$&"),n=e[1].replace(Gs,"\\$&");return new RegExp(t+"((?:.|\\n)+?)"+n,"g")}),zs={staticKeys:["staticClass"],transformNode:Ur,genData:Br},Ws={staticKeys:["staticStyle"],transformNode:Nr,genData:Fr},$s={decode:function(e){return Vs=Vs||document.createElement("div"),Vs.innerHTML=e,Vs.textContent}},Ys=p("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),Ks=p("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),Xs=p("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),Js=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Qs="[a-zA-Z_][\\w\\-\\.]*",Zs="((?:"+Qs+"\\:)?"+Qs+")",eu=new RegExp("^<"+Zs),tu=/^\s*(\/?)>/,nu=new RegExp("^<\\/"+Zs+"[^>]*>"),ru=/^<!DOCTYPE [^>]+>/i,iu=/^<!--/,au=/^<!\[/,ou=!1;"x".replace(/x(.)?/g,function(e,t){ou=""===t});var su,uu,lu,cu,du,fu,hu,pu,mu,vu,gu,yu=p("script,style,textarea",!0),_u={},bu={"&lt;":"<","&gt;":">","&quot;":'"',"&amp;":"&","&#10;":"\n","&#9;":"\t"},Tu=/&(?:lt|gt|quot|amp);/g,Su=/&(?:lt|gt|quot|amp|#10|#9);/g,wu=p("pre,textarea",!0),ku=function(e,t){return e&&wu(e)&&"\n"===t[0]},Eu=/^@|^v-on:/,Au=/^v-|^@|^:/,Cu=/(.*?)\s+(?:in|of)\s+(.*)/,Lu=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,xu=/^\(|\)$/g,ju=/:(.*)$/,Ou=/^:|^v-bind:/,Iu=/\.[^.]+/g,Pu=g($s.decode),Ru=/^xmlns:NS\d+/,Du=/^NS\d+:/,Mu={preTransformNode:fi},Uu=[zs,Ws,Mu],Bu={model:Vn,text:pi,html:mi},Nu={expectHTML:!0,modules:Uu,directives:Bu,isPreTag:Yo,isUnaryTag:Ys,mustUseProp:Bo,canBeLeftOpenTag:Ks,isReservedTag:Ko,getTagNamespace:Yt,staticKeys:function(e){return e.reduce(function(e,t){return e.concat(t.staticKeys||[])},[]).join(",")}(Uu)},Fu=g(gi),Vu=/^\s*([\w$_]+|\([^)]*?\))\s*=>|^function\s*\(/,qu=/^\s*[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['.*?']|\[".*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*\s*$/,Gu={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},Hu=function(e){return"if("+e+")return null;"},zu={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:Hu("$event.target !== $event.currentTarget"),ctrl:Hu("!$event.ctrlKey"),shift:Hu("!$event.shiftKey"),alt:Hu("!$event.altKey"),meta:Hu("!$event.metaKey"),left:Hu("'button' in $event && $event.button !== 0"),middle:Hu("'button' in $event && $event.button !== 1"),right:Hu("'button' in $event && $event.button !== 2")},Wu={on:Ai,bind:Ci,cloak:S},$u=function(e){this.options=e,this.warn=e.warn||kn,this.transforms=En(e.modules,"transformCode"),this.dataGenFns=En(e.modules,"genData"),this.directives=b(b({},Wu),e.directives);var t=e.isReservedTag||da;this.maybeComponent=function(e){return!t(e.tag)},this.onceId=0,this.staticRenderFns=[]},Yu=(new RegExp("\\b"+"do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments".split(",").join("\\b|\\b")+"\\b"),new RegExp("\\b"+"delete,typeof,void".split(",").join("\\s*\\([^\\)]*\\)|\\b")+"\\s*\\([^\\)]*\\)"),function(e){return function(t){function n(n,r){var i=Object.create(t),a=[],o=[];if(i.warn=function(e,t){(t?o:a).push(e)},r){r.modules&&(i.modules=(t.modules||[]).concat(r.modules)),r.directives&&(i.directives=b(Object.create(t.directives||null),r.directives));for(var s in r)"modules"!==s&&"directives"!==s&&(i[s]=r[s])}var u=e(n,i);return u.errors=a,u.tips=o,u}return{compile:n,compileToFunctions:Qi(n)}}}(function(e,t){var n=Hr(e.trim(),t);!1!==t.optimize&&vi(n,t);var r=Li(n,t);return{ast:n,render:r.render,staticRenderFns:r.staticRenderFns}})),Ku=Yu(Nu),Xu=Ku.compileToFunctions,Ju=!!_a&&Zi(!1),Qu=!!_a&&Zi(!0),Zu=g(function(e){var t=Xt(e);return t&&t.innerHTML}),el=jt.prototype.$mount;jt.prototype.$mount=function(e,t){if((e=e&&Xt(e))===document.body||e===document.documentElement)return this;var n=this.$options;if(!n.render){var r=n.template;if(r)if("string"==typeof r)"#"===r.charAt(0)&&(r=Zu(r));else{if(!r.nodeType)return this;r=r.innerHTML}else e&&(r=ea(e));if(r){var i=Xu(r,{shouldDecodeNewlines:Ju,shouldDecodeNewlinesForHref:Qu,delimiters:n.delimiters,comments:n.comments},this),a=i.render,o=i.staticRenderFns;n.render=a,n.staticRenderFns=o}}return el.call(this,e,t)},jt.compile=Xu,e.exports=jt}).call(t,n("DuR2"),n("162o").setImmediate)},IE6n:function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(6),a="findIndex",o=!0;a in[]&&Array(1)[a](function(){o=!1}),r(r.P+r.F*o,"Array",{findIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n("5BZE")(a)},"IGk/":function(e,t,n){"use strict";var r=n("eqAp"),i=n("xpmJ"),a=n("sxvG"),o=n("J5DO"),s=[].lastIndexOf,u=!!s&&1/[1].lastIndexOf(1,-0)<0;r(r.P+r.F*(u||!n("+qBm")(s)),"Array",{lastIndexOf:function(e){if(u)return s.apply(this,arguments)||0;var t=i(this),n=o(t.length),r=n-1;for(arguments.length>1&&(r=Math.min(r,a(arguments[1]))),r<0&&(r=n+r);r>=0;r--)if(r in t&&t[r]===e)return r||0;return-1}})},"IS1/":function(e,t,n){var r=n("vR0S"),i=n("BDba"),a=n("rBVO").f,o=n("XjC+").f,s=n("RVW2"),u=n("AQEt"),l=r.RegExp,c=l,d=l.prototype,f=/a/g,h=/a/g,p=new l(f)!==f;if(n("8yv5")&&(!p||n("HTem")(function(){return h[n("6hGG")("match")]=!1,l(f)!=f||l(h)==h||"/a/i"!=l(f,"i")}))){l=function(e,t){var n=this instanceof l,r=s(e),a=void 0===t;return!n&&r&&e.constructor===l&&a?e:i(p?new c(r&&!a?e.source:e,t):c((r=e instanceof l)?e.source:e,r&&a?u.call(e):t),n?this:d,l)};for(var m=o(c),v=0;m.length>v;)!function(e){e in l||a(l,e,{configurable:!0,get:function(){return c[e]},set:function(t){c[e]=t}})}(m[v++]);d.constructor=l,l.prototype=d,n("au66")(r,"RegExp",l)}n("7QiM")("RegExp")},IahY:function(e,t,n){"use strict";n("48Hh")("sub",function(e){return function(){return e(this,"sub","","")}})},IfkE:function(e,t,n){var r=n("sxvG"),i=Math.max,a=Math.min;e.exports=function(e,t){return e=r(e),e<0?i(e+t,0):a(e,t)}},Iiwq:function(e,t,n){var r=n("eqAp"),i=n("QhVj"),a=n("HTem");e.exports=function(e,t){var n=(i.Object||{})[e]||Object[e],o={};o[e]=t(n),r(r.S+r.F*a(function(){n(1)}),"Object",o)}},IjnQ:function(e,t,n){"use strict";var r=n("eqAp"),i=n("bFIN")(!0);r(r.P,"String",{at:function(e){return i(this,e)}})},J0zq:function(e,t,n){"use strict";var r=n("eqAp"),i=n("B63G"),a=n("AeeY"),o=n("HTem"),s=[].sort,u=[1,2,3];r(r.P+r.F*(o(function(){u.sort(void 0)})||!o(function(){u.sort(null)})||!n("+qBm")(s)),"Array",{sort:function(e){return void 0===e?s.call(a(this)):s.call(a(this),i(e))}})},J5DO:function(e,t,n){var r=n("sxvG"),i=Math.min;e.exports=function(e){return e>0?i(r(e),9007199254740991):0}},JCOx:function(e,t,n){"use strict";var r=n("bFIN")(!0);n("lPz5")(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})})},"JP+z":function(e,t,n){"use strict";e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}}},JPCZ:function(e,t,n){n("YQk9")("Set")},JSYz:function(e,t,n){"use strict";n("48Hh")("link",function(e){return function(t){return e(this,"a","href",t)}})},JVxX:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=n("spe/"),o=r.has,s=r.get,u=r.key,l=function(e,t,n){if(o(e,t,n))return s(e,t,n);var r=a(t);return null!==r?l(e,r,n):void 0};r.exp({getMetadata:function(e,t){return l(e,i(t),arguments.length<3?void 0:u(arguments[2]))}})},JuSo:function(e,t,n){var r=n("bPSW"),i=n("6hGG")("iterator"),a=n("xnnD");e.exports=n("QhVj").getIteratorMethod=function(e){if(void 0!=e)return e[i]||e["@@iterator"]||a[r(e)]}},JwEh:function(e,t,n){n("xU4Q")("observable")},K0e4:function(e,t,n){"use strict";var r=n("5BZE"),i=n("fLOS"),a=n("xnnD"),o=n("xpmJ");e.exports=n("lPz5")(Array,"Array",function(e,t){this._t=o(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,i(1)):"keys"==t?i(0,n):"values"==t?i(0,e[n]):i(0,[n,e[n]])},"values"),a.Arguments=a.Array,r("keys"),r("values"),r("entries")},KCLY:function(e,t,n){"use strict";(function(t){function r(e,t){!i.isUndefined(e)&&i.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var i=n("cGG2"),a=n("5VQ+"),o={"Content-Type":"application/x-www-form-urlencoded"},s={adapter:function(){var e;return"undefined"!=typeof XMLHttpRequest?e=n("7GwW"):void 0!==t&&(e=n("7GwW")),e}(),transformRequest:[function(e,t){return a(t,"Content-Type"),i.isFormData(e)||i.isArrayBuffer(e)||i.isBuffer(e)||i.isStream(e)||i.isFile(e)||i.isBlob(e)?e:i.isArrayBufferView(e)?e.buffer:i.isURLSearchParams(e)?(r(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):i.isObject(e)?(r(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&e<300}};s.headers={common:{Accept:"application/json, text/plain, */*"}},i.forEach(["delete","get","head"],function(e){s.headers[e]={}}),i.forEach(["post","put","patch"],function(e){s.headers[e]=i.merge(o)}),e.exports=s}).call(t,n("W2nU"))},KS3q:function(e,t,n){var r=n("eqAp"),i=n("PbK0"),a=n("Wx9E");r(r.S,"Math",{fscale:function(e,t,n,r,o){return a(i(e,t,n,r,o))}})},KkGp:function(e,t,n){var r=n("VLJK");e.exports=function(e,t){var n=[];return r(e,!1,n.push,n,t),n}},L1YH:function(e,t,n){"use strict";var r,i=n("vR0S"),a=n("Q2Ff")(0),o=n("au66"),s=n("QhHn"),u=n("i5O8"),l=n("PWt5"),c=n("U9LJ"),d=n("q90C"),f=n("q90C"),h=!i.ActiveXObject&&"ActiveXObject"in i,p=s.getWeak,m=Object.isExtensible,v=l.ufstore,g=function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},y={get:function(e){if(c(e)){var t=p(e);return!0===t?v(d(this,"WeakMap")).get(e):t?t[this._i]:void 0}},set:function(e,t){return l.def(d(this,"WeakMap"),e,t)}},_=e.exports=n("LFIv")("WeakMap",g,y,l,!0,!0);f&&h&&(r=l.getConstructor(g,"WeakMap"),u(r.prototype,y),s.NEED=!0,a(["delete","has","get","set"],function(e){var t=_.prototype,n=t[e];o(t,e,function(t,i){if(c(t)&&!m(t)){this._f||(this._f=new r);var a=this._f[e](t,i);return"set"==e?this:a}return n.call(this,t,i)})}))},L3my:function(e,t,n){"use strict";var r=n("eqAp"),i=n("3jLb"),a=n("N2PI"),o=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(a);r(r.P+r.F*o,"String",{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},"LC+M":function(e,t,n){var r=n("eqAp");r(r.S,"Math",{log2:function(e){return Math.log(e)/Math.LN2}})},LFIv:function(e,t,n){"use strict";var r=n("vR0S"),i=n("eqAp"),a=n("au66"),o=n("NmAK"),s=n("QhHn"),u=n("VLJK"),l=n("S5no"),c=n("U9LJ"),d=n("HTem"),f=n("GAJc"),h=n("W97E"),p=n("BDba");e.exports=function(e,t,n,m,v,g){var y=r[e],_=y,b=v?"set":"add",T=_&&_.prototype,S={},w=function(e){var t=T[e];a(T,e,"delete"==e?function(e){return!(g&&!c(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(g&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return g&&!c(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof _&&(g||T.forEach&&!d(function(){(new _).entries().next()}))){var k=new _,E=k[b](g?{}:-0,1)!=k,A=d(function(){k.has(1)}),C=f(function(e){new _(e)}),L=!g&&d(function(){for(var e=new _,t=5;t--;)e[b](t,t);return!e.has(-0)});C||(_=t(function(t,n){l(t,_,e);var r=p(new y,t,_);return void 0!=n&&u(n,v,r[b],r),r}),_.prototype=T,T.constructor=_),(A||L)&&(w("delete"),w("has"),v&&w("get")),(L||E)&&w(b),g&&T.clear&&delete T.clear}else _=m.getConstructor(t,e,v,b),o(_.prototype,n),s.NEED=!0;return h(_,e),S[e]=_,i(i.G+i.W+i.F*(_!=y),S),g||m.setStrong(_,e,v),_}},LMcF:function(e,t,n){var r=n("eqAp");r(r.S,"Object",{setPrototypeOf:n("HAfA").set})},LN0b:function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(1);r(r.P+r.F*!n("+qBm")([].map,!0),"Array",{map:function(e){return i(this,e,arguments[1])}})},LiyF:function(e,t,n){var r=n("eqAp"),i=n("NkR5"),a=n("B63G"),o=n("PGRs"),s=n("U9LJ"),u=n("HTem"),l=n("xfkl"),c=(n("vR0S").Reflect||{}).construct,d=u(function(){function e(){}return!(c(function(){},[],e)instanceof e)}),f=!u(function(){c(function(){})});r(r.S+r.F*(d||f),"Reflect",{construct:function(e,t){a(e),o(t);var n=arguments.length<3?e:a(arguments[2]);if(f&&!d)return c(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var r=[null];return r.push.apply(r,t),new(l.apply(e,r))}var u=n.prototype,h=i(s(u)?u:Object.prototype),p=Function.apply.call(e,h,t);return s(p)?p:h}})},M4fF:function(e,t,n){(function(e,r){var i;(function(){function a(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function o(e,t,n,r){for(var i=-1,a=null==e?0:e.length;++i<a;){var o=e[i];t(r,o,n(o),e)}return r}function s(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function u(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function l(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function c(e,t){for(var n=-1,r=null==e?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}function d(e,t){return!!(null==e?0:e.length)&&S(e,t,0)>-1}function f(e,t,n){for(var r=-1,i=null==e?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function h(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}function p(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function m(e,t,n,r){var i=-1,a=null==e?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}function v(e,t,n,r){var i=null==e?0:e.length;for(r&&i&&(n=e[--i]);i--;)n=t(n,e[i],i,e);return n}function g(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function y(e){return e.split("")}function _(e){return e.match(Ut)||[]}function b(e,t,n){var r;return n(e,function(e,n,i){if(t(e,n,i))return r=n,!1}),r}function T(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}function S(e,t,n){return t===t?K(e,t,n):T(e,k,n)}function w(e,t,n,r){for(var i=n-1,a=e.length;++i<a;)if(r(e[i],t))return i;return-1}function k(e){return e!==e}function E(e,t){var n=null==e?0:e.length;return n?j(e,t)/n:Pe}function A(e){return function(t){return null==t?ne:t[e]}}function C(e){return function(t){return null==e?ne:e[t]}}function L(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}function x(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}function j(e,t){for(var n,r=-1,i=e.length;++r<i;){var a=t(e[r]);a!==ne&&(n=n===ne?a:n+a)}return n}function O(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function I(e,t){return h(t,function(t){return[t,e[t]]})}function P(e){return function(t){return e(t)}}function R(e,t){return h(t,function(t){return e[t]})}function D(e,t){return e.has(t)}function M(e,t){for(var n=-1,r=e.length;++n<r&&S(t,e[n],0)>-1;);return n}function U(e,t){for(var n=e.length;n--&&S(t,e[n],0)>-1;);return n}function B(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}function N(e){return"\\"+En[e]}function F(e,t){return null==e?ne:e[t]}function V(e){return vn.test(e)}function q(e){return gn.test(e)}function G(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}function H(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function z(e,t){return function(n){return e(t(n))}}function W(e,t){for(var n=-1,r=e.length,i=0,a=[];++n<r;){var o=e[n];o!==t&&o!==ue||(e[n]=ue,a[i++]=n)}return a}function $(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}function Y(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=[e,e]}),n}function K(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function X(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}function J(e){return V(e)?Z(e):qn(e)}function Q(e){return V(e)?ee(e):y(e)}function Z(e){for(var t=pn.lastIndex=0;pn.test(e);)++t;return t}function ee(e){return e.match(pn)||[]}function te(e){return e.match(mn)||[]}var ne,re=200,ie="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",ae="Expected a function",oe="__lodash_hash_undefined__",se=500,ue="__lodash_placeholder__",le=1,ce=2,de=4,fe=1,he=2,pe=1,me=2,ve=4,ge=8,ye=16,_e=32,be=64,Te=128,Se=256,we=512,ke=30,Ee="...",Ae=800,Ce=16,Le=1,xe=2,je=1/0,Oe=9007199254740991,Ie=1.7976931348623157e308,Pe=NaN,Re=4294967295,De=Re-1,Me=Re>>>1,Ue=[["ary",Te],["bind",pe],["bindKey",me],["curry",ge],["curryRight",ye],["flip",we],["partial",_e],["partialRight",be],["rearg",Se]],Be="[object Arguments]",Ne="[object Array]",Fe="[object AsyncFunction]",Ve="[object Boolean]",qe="[object Date]",Ge="[object DOMException]",He="[object Error]",ze="[object Function]",We="[object GeneratorFunction]",$e="[object Map]",Ye="[object Number]",Ke="[object Null]",Xe="[object Object]",Je="[object Proxy]",Qe="[object RegExp]",Ze="[object Set]",et="[object String]",tt="[object Symbol]",nt="[object Undefined]",rt="[object WeakMap]",it="[object WeakSet]",at="[object ArrayBuffer]",ot="[object DataView]",st="[object Float32Array]",ut="[object Float64Array]",lt="[object Int8Array]",ct="[object Int16Array]",dt="[object Int32Array]",ft="[object Uint8Array]",ht="[object Uint8ClampedArray]",pt="[object Uint16Array]",mt="[object Uint32Array]",vt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,_t=/&(?:amp|lt|gt|quot|#39);/g,bt=/[&<>"']/g,Tt=RegExp(_t.source),St=RegExp(bt.source),wt=/<%-([\s\S]+?)%>/g,kt=/<%([\s\S]+?)%>/g,Et=/<%=([\s\S]+?)%>/g,At=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Ct=/^\w*$/,Lt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,xt=/[\\^$.*+?()[\]{}|]/g,jt=RegExp(xt.source),Ot=/^\s+|\s+$/g,It=/^\s+/,Pt=/\s+$/,Rt=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Dt=/\{\n\/\* \[wrapped with (.+)\] \*/,Mt=/,? & /,Ut=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Bt=/\\(\\)?/g,Nt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ft=/\w*$/,Vt=/^[-+]0x[0-9a-f]+$/i,qt=/^0b[01]+$/i,Gt=/^\[object .+?Constructor\]$/,Ht=/^0o[0-7]+$/i,zt=/^(?:0|[1-9]\d*)$/,Wt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,$t=/($^)/,Yt=/['\n\r\u2028\u2029\\]/g,Kt="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Xt="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Jt="["+Xt+"]",Qt="["+Kt+"]",Zt="[a-z\\xdf-\\xf6\\xf8-\\xff]",en="[^\\ud800-\\udfff"+Xt+"\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",tn="\\ud83c[\\udffb-\\udfff]",nn="(?:\\ud83c[\\udde6-\\uddff]){2}",rn="[\\ud800-\\udbff][\\udc00-\\udfff]",an="[A-Z\\xc0-\\xd6\\xd8-\\xde]",on="(?:"+Zt+"|"+en+")",sn="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",un="(?:\\u200d(?:"+["[^\\ud800-\\udfff]",nn,rn].join("|")+")[\\ufe0e\\ufe0f]?"+sn+")*",ln="[\\ufe0e\\ufe0f]?"+sn+un,cn="(?:"+["[\\u2700-\\u27bf]",nn,rn].join("|")+")"+ln,dn="(?:"+["[^\\ud800-\\udfff]"+Qt+"?",Qt,nn,rn,"[\\ud800-\\udfff]"].join("|")+")",fn=RegExp("['’]","g"),hn=RegExp(Qt,"g"),pn=RegExp(tn+"(?="+tn+")|"+dn+ln,"g"),mn=RegExp([an+"?"+Zt+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[Jt,an,"$"].join("|")+")","(?:[A-Z\\xc0-\\xd6\\xd8-\\xde]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[Jt,an+on,"$"].join("|")+")",an+"?"+on+"+(?:['’](?:d|ll|m|re|s|t|ve))?",an+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])","\\d+",cn].join("|"),"g"),vn=RegExp("[\\u200d\\ud800-\\udfff"+Kt+"\\ufe0e\\ufe0f]"),gn=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,yn=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],_n=-1,bn={};bn[st]=bn[ut]=bn[lt]=bn[ct]=bn[dt]=bn[ft]=bn[ht]=bn[pt]=bn[mt]=!0,bn[Be]=bn[Ne]=bn[at]=bn[Ve]=bn[ot]=bn[qe]=bn[He]=bn[ze]=bn[$e]=bn[Ye]=bn[Xe]=bn[Qe]=bn[Ze]=bn[et]=bn[rt]=!1;var Tn={};Tn[Be]=Tn[Ne]=Tn[at]=Tn[ot]=Tn[Ve]=Tn[qe]=Tn[st]=Tn[ut]=Tn[lt]=Tn[ct]=Tn[dt]=Tn[$e]=Tn[Ye]=Tn[Xe]=Tn[Qe]=Tn[Ze]=Tn[et]=Tn[tt]=Tn[ft]=Tn[ht]=Tn[pt]=Tn[mt]=!0,Tn[He]=Tn[ze]=Tn[rt]=!1;var Sn={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},wn={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},kn={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},En={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},An=parseFloat,Cn=parseInt,Ln="object"==typeof e&&e&&e.Object===Object&&e,xn="object"==typeof self&&self&&self.Object===Object&&self,jn=Ln||xn||Function("return this")(),On="object"==typeof t&&t&&!t.nodeType&&t,In=On&&"object"==typeof r&&r&&!r.nodeType&&r,Pn=In&&In.exports===On,Rn=Pn&&Ln.process,Dn=function(){try{var e=In&&In.require&&In.require("util").types;return e||Rn&&Rn.binding&&Rn.binding("util")}catch(e){}}(),Mn=Dn&&Dn.isArrayBuffer,Un=Dn&&Dn.isDate,Bn=Dn&&Dn.isMap,Nn=Dn&&Dn.isRegExp,Fn=Dn&&Dn.isSet,Vn=Dn&&Dn.isTypedArray,qn=A("length"),Gn=C(Sn),Hn=C(wn),zn=C(kn),Wn=function e(t){function n(e){if(tu(e)&&!hf(e)&&!(e instanceof y)){if(e instanceof i)return e;if(fc.call(e,"__wrapped__"))return Ja(e)}return new i(e)}function r(){}function i(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=ne}function y(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Re,this.__views__=[]}function C(){var e=new y(this.__wrapped__);return e.__actions__=Ii(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=Ii(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=Ii(this.__views__),e}function K(){if(this.__filtered__){var e=new y(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}function Z(){var e=this.__wrapped__.value(),t=this.__dir__,n=hf(e),r=t<0,i=n?e.length:0,a=Ta(0,i,this.__views__),o=a.start,s=a.end,u=s-o,l=r?s:o-1,c=this.__iteratees__,d=c.length,f=0,h=qc(u,this.__takeCount__);if(!n||!r&&i==u&&h==u)return mi(e,this.__actions__);var p=[];e:for(;u--&&f<h;){l+=t;for(var m=-1,v=e[l];++m<d;){var g=c[m],y=g.iteratee,_=g.type,b=y(v);if(_==xe)v=b;else if(!b){if(_==Le)continue e;break e}}p[f++]=v}return p}function ee(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Ut(){this.__data__=Qc?Qc(null):{},this.size=0}function Kt(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}function Xt(e){var t=this.__data__;if(Qc){var n=t[e];return n===oe?ne:n}return fc.call(t,e)?t[e]:ne}function Jt(e){var t=this.__data__;return Qc?t[e]!==ne:fc.call(t,e)}function Qt(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Qc&&t===ne?oe:t,this}function Zt(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function en(){this.__data__=[],this.size=0}function tn(e){var t=this.__data__,n=$n(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ac.call(t,n,1),--this.size,!0)}function nn(e){var t=this.__data__,n=$n(t,e);return n<0?ne:t[n][1]}function rn(e){return $n(this.__data__,e)>-1}function an(e,t){var n=this.__data__,r=$n(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function on(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function sn(){this.size=0,this.__data__={hash:new ee,map:new(Yc||Zt),string:new ee}}function un(e){var t=ga(this,e).delete(e);return this.size-=t?1:0,t}function ln(e){return ga(this,e).get(e)}function cn(e){return ga(this,e).has(e)}function dn(e,t){var n=ga(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function pn(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new on;++t<n;)this.add(e[t])}function mn(e){return this.__data__.set(e,oe),this}function vn(e){return this.__data__.has(e)}function gn(e){var t=this.__data__=new Zt(e);this.size=t.size}function Sn(){this.__data__=new Zt,this.size=0}function wn(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function kn(e){return this.__data__.get(e)}function En(e){return this.__data__.has(e)}function Ln(e,t){var n=this.__data__;if(n instanceof Zt){var r=n.__data__;if(!Yc||r.length<re-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new on(r)}return n.set(e,t),this.size=n.size,this}function xn(e,t){var n=hf(e),r=!n&&ff(e),i=!n&&!r&&mf(e),a=!n&&!r&&!i&&bf(e),o=n||r||i||a,s=o?O(e.length,ac):[],u=s.length;for(var l in e)!t&&!fc.call(e,l)||o&&("length"==l||i&&("offset"==l||"parent"==l)||a&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||xa(l,u))||s.push(l);return s}function On(e){var t=e.length;return t?e[Xr(0,t-1)]:ne}function In(e,t){return $a(Ii(e),Zn(t,0,e.length))}function Rn(e){return $a(Ii(e))}function Dn(e,t,n){(n===ne||Vs(e[t],n))&&(n!==ne||t in e)||Jn(e,t,n)}function qn(e,t,n){var r=e[t];fc.call(e,t)&&Vs(r,n)&&(n!==ne||t in e)||Jn(e,t,n)}function $n(e,t){for(var n=e.length;n--;)if(Vs(e[n][0],t))return n;return-1}function Yn(e,t,n,r){return cd(e,function(e,i,a){t(r,e,n(e),a)}),r}function Kn(e,t){return e&&Pi(t,Mu(t),e)}function Xn(e,t){return e&&Pi(t,Uu(t),e)}function Jn(e,t,n){"__proto__"==t&&jc?jc(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Qn(e,t){for(var n=-1,r=t.length,i=Ql(r),a=null==e;++n<r;)i[n]=a?ne:Pu(e,t[n]);return i}function Zn(e,t,n){return e===e&&(n!==ne&&(e=e<=n?e:n),t!==ne&&(e=e>=t?e:t)),e}function er(e,t,n,r,i,a){var o,u=t&le,l=t&ce,c=t&de;if(n&&(o=i?n(e,r,i,a):n(e)),o!==ne)return o;if(!eu(e))return e;var d=hf(e);if(d){if(o=ka(e),!u)return Ii(e,o)}else{var f=Sd(e),h=f==ze||f==We;if(mf(e))return Si(e,u);if(f==Xe||f==Be||h&&!i){if(o=l||h?{}:Ea(e),!u)return l?Di(e,Xn(o,e)):Ri(e,Kn(o,e))}else{if(!Tn[f])return i?e:{};o=Aa(e,f,u)}}a||(a=new gn);var p=a.get(e);if(p)return p;if(a.set(e,o),_f(e))return e.forEach(function(r){o.add(er(r,t,n,r,e,a))}),o;if(gf(e))return e.forEach(function(r,i){o.set(i,er(r,t,n,i,e,a))}),o;var m=c?l?ha:fa:l?Uu:Mu,v=d?ne:m(e);return s(v||e,function(r,i){v&&(i=r,r=e[i]),qn(o,i,er(r,t,n,i,e,a))}),o}function tr(e){var t=Mu(e);return function(n){return nr(n,e,t)}}function nr(e,t,n){var r=n.length;if(null==e)return!r;for(e=rc(e);r--;){var i=n[r],a=t[i],o=e[i];if(o===ne&&!(i in e)||!a(o))return!1}return!0}function rr(e,t,n){if("function"!=typeof e)throw new oc(ae);return Ed(function(){e.apply(ne,n)},t)}function ir(e,t,n,r){var i=-1,a=d,o=!0,s=e.length,u=[],l=t.length;if(!s)return u;n&&(t=h(t,P(n))),r?(a=f,o=!1):t.length>=re&&(a=D,o=!1,t=new pn(t));e:for(;++i<s;){var c=e[i],p=null==n?c:n(c);if(c=r||0!==c?c:0,o&&p===p){for(var m=l;m--;)if(t[m]===p)continue e;u.push(c)}else a(t,p,r)||u.push(c)}return u}function ar(e,t){var n=!0;return cd(e,function(e,r,i){return n=!!t(e,r,i)}),n}function or(e,t,n){for(var r=-1,i=e.length;++r<i;){var a=e[r],o=t(a);if(null!=o&&(s===ne?o===o&&!fu(o):n(o,s)))var s=o,u=a}return u}function sr(e,t,n,r){var i=e.length;for(n=yu(n),n<0&&(n=-n>i?0:i+n),r=r===ne||r>i?i:yu(r),r<0&&(r+=i),r=n>r?0:_u(r);n<r;)e[n++]=t;return e}function ur(e,t){var n=[];return cd(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}function lr(e,t,n,r,i){var a=-1,o=e.length;for(n||(n=La),i||(i=[]);++a<o;){var s=e[a];t>0&&n(s)?t>1?lr(s,t-1,n,r,i):p(i,s):r||(i[i.length]=s)}return i}function cr(e,t){return e&&fd(e,t,Mu)}function dr(e,t){return e&&hd(e,t,Mu)}function fr(e,t){return c(t,function(t){return Js(e[t])})}function hr(e,t){t=bi(t,e);for(var n=0,r=t.length;null!=e&&n<r;)e=e[Ya(t[n++])];return n&&n==r?e:ne}function pr(e,t,n){var r=t(e);return hf(e)?r:p(r,n(e))}function mr(e){return null==e?e===ne?nt:Ke:xc&&xc in rc(e)?ba(e):Fa(e)}function vr(e,t){return e>t}function gr(e,t){return null!=e&&fc.call(e,t)}function yr(e,t){return null!=e&&t in rc(e)}function _r(e,t,n){return e>=qc(t,n)&&e<Vc(t,n)}function br(e,t,n){for(var r=n?f:d,i=e[0].length,a=e.length,o=a,s=Ql(a),u=1/0,l=[];o--;){var c=e[o];o&&t&&(c=h(c,P(t))),u=qc(c.length,u),s[o]=!n&&(t||i>=120&&c.length>=120)?new pn(o&&c):ne}c=e[0];var p=-1,m=s[0];e:for(;++p<i&&l.length<u;){var v=c[p],g=t?t(v):v;if(v=n||0!==v?v:0,!(m?D(m,g):r(l,g,n))){for(o=a;--o;){var y=s[o];if(!(y?D(y,g):r(e[o],g,n)))continue e}m&&m.push(g),l.push(v)}}return l}function Tr(e,t,n,r){return cr(e,function(e,i,a){t(r,n(e),i,a)}),r}function Sr(e,t,n){t=bi(t,e),e=qa(e,t);var r=null==e?e:e[Ya(go(t))];return null==r?ne:a(r,e,n)}function wr(e){return tu(e)&&mr(e)==Be}function kr(e){return tu(e)&&mr(e)==at}function Er(e){return tu(e)&&mr(e)==qe}function Ar(e,t,n,r,i){return e===t||(null==e||null==t||!tu(e)&&!tu(t)?e!==e&&t!==t:Cr(e,t,n,r,Ar,i))}function Cr(e,t,n,r,i,a){var o=hf(e),s=hf(t),u=o?Ne:Sd(e),l=s?Ne:Sd(t);u=u==Be?Xe:u,l=l==Be?Xe:l;var c=u==Xe,d=l==Xe,f=u==l;if(f&&mf(e)){if(!mf(t))return!1;o=!0,c=!1}if(f&&!c)return a||(a=new gn),o||bf(e)?ua(e,t,n,r,i,a):la(e,t,u,n,r,i,a);if(!(n&fe)){var h=c&&fc.call(e,"__wrapped__"),p=d&&fc.call(t,"__wrapped__");if(h||p){var m=h?e.value():e,v=p?t.value():t;return a||(a=new gn),i(m,v,n,r,a)}}return!!f&&(a||(a=new gn),ca(e,t,n,r,i,a))}function Lr(e){return tu(e)&&Sd(e)==$e}function xr(e,t,n,r){var i=n.length,a=i,o=!r;if(null==e)return!a;for(e=rc(e);i--;){var s=n[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=n[i];var u=s[0],l=e[u],c=s[1];if(o&&s[2]){if(l===ne&&!(u in e))return!1}else{var d=new gn;if(r)var f=r(l,c,u,e,t,d);if(!(f===ne?Ar(c,l,fe|he,r,d):f))return!1}}return!0}function jr(e){return!(!eu(e)||Ra(e))&&(Js(e)?yc:Gt).test(Ka(e))}function Or(e){return tu(e)&&mr(e)==Qe}function Ir(e){return tu(e)&&Sd(e)==Ze}function Pr(e){return tu(e)&&Zs(e.length)&&!!bn[mr(e)]}function Rr(e){return"function"==typeof e?e:null==e?Al:"object"==typeof e?hf(e)?Fr(e[0],e[1]):Nr(e):Rl(e)}function Dr(e){if(!Da(e))return Fc(e);var t=[];for(var n in rc(e))fc.call(e,n)&&"constructor"!=n&&t.push(n);return t}function Mr(e){if(!eu(e))return Na(e);var t=Da(e),n=[];for(var r in e)("constructor"!=r||!t&&fc.call(e,r))&&n.push(r);return n}function Ur(e,t){return e<t}function Br(e,t){var n=-1,r=qs(e)?Ql(e.length):[];return cd(e,function(e,i,a){r[++n]=t(e,i,a)}),r}function Nr(e){var t=ya(e);return 1==t.length&&t[0][2]?Ua(t[0][0],t[0][1]):function(n){return n===e||xr(n,e,t)}}function Fr(e,t){return Oa(e)&&Ma(t)?Ua(Ya(e),t):function(n){var r=Pu(n,e);return r===ne&&r===t?Du(n,e):Ar(t,r,fe|he)}}function Vr(e,t,n,r,i){e!==t&&fd(t,function(a,o){if(eu(a))i||(i=new gn),qr(e,t,o,n,Vr,r,i);else{var s=r?r(Ha(e,o),a,o+"",e,t,i):ne;s===ne&&(s=a),Dn(e,o,s)}},Uu)}function qr(e,t,n,r,i,a,o){var s=Ha(e,n),u=Ha(t,n),l=o.get(u);if(l)return void Dn(e,n,l);var c=a?a(s,u,n+"",e,t,o):ne,d=c===ne;if(d){var f=hf(u),h=!f&&mf(u),p=!f&&!h&&bf(u);c=u,f||h||p?hf(s)?c=s:Gs(s)?c=Ii(s):h?(d=!1,c=Si(u,!0)):p?(d=!1,c=Ci(u,!0)):c=[]:lu(u)||ff(u)?(c=s,ff(s)?c=Tu(s):eu(s)&&!Js(s)||(c=Ea(u))):d=!1}d&&(o.set(u,c),i(c,u,r,a,o),o.delete(u)),Dn(e,n,c)}function Gr(e,t){var n=e.length;if(n)return t+=t<0?n:0,xa(t,n)?e[t]:ne}function Hr(e,t,n){var r=-1;return t=h(t.length?t:[Al],P(va())),x(Br(e,function(e,n,i){return{criteria:h(t,function(t){return t(e)}),index:++r,value:e}}),function(e,t){return xi(e,t,n)})}function zr(e,t){return Wr(e,t,function(t,n){return Du(e,n)})}function Wr(e,t,n){for(var r=-1,i=t.length,a={};++r<i;){var o=t[r],s=hr(e,o);n(s,o)&&ni(a,bi(o,e),s)}return a}function $r(e){return function(t){return hr(t,e)}}function Yr(e,t,n,r){var i=r?w:S,a=-1,o=t.length,s=e;for(e===t&&(t=Ii(t)),n&&(s=h(e,P(n)));++a<o;)for(var u=0,l=t[a],c=n?n(l):l;(u=i(s,c,u,r))>-1;)s!==e&&Ac.call(s,u,1),Ac.call(e,u,1);return e}function Kr(e,t){for(var n=e?t.length:0,r=n-1;n--;){var i=t[n];if(n==r||i!==a){var a=i;xa(i)?Ac.call(e,i,1):fi(e,i)}}return e}function Xr(e,t){return e+Dc(zc()*(t-e+1))}function Jr(e,t,n,r){for(var i=-1,a=Vc(Rc((t-e)/(n||1)),0),o=Ql(a);a--;)o[r?a:++i]=e,e+=n;return o}function Qr(e,t){var n="";if(!e||t<1||t>Oe)return n;do{t%2&&(n+=e),(t=Dc(t/2))&&(e+=e)}while(t);return n}function Zr(e,t){return Ad(Va(e,t,Al),e+"")}function ei(e){return On(Ku(e))}function ti(e,t){var n=Ku(e);return $a(n,Zn(t,0,n.length))}function ni(e,t,n,r){if(!eu(e))return e;t=bi(t,e);for(var i=-1,a=t.length,o=a-1,s=e;null!=s&&++i<a;){var u=Ya(t[i]),l=n;if(i!=o){var c=s[u];l=r?r(c,u,s):ne,l===ne&&(l=eu(c)?c:xa(t[i+1])?[]:{})}qn(s,u,l),s=s[u]}return e}function ri(e){return $a(Ku(e))}function ii(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Ql(i);++r<i;)a[r]=e[r+t];return a}function ai(e,t){var n;return cd(e,function(e,r,i){return!(n=t(e,r,i))}),!!n}function oi(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t===t&&i<=Me){for(;r<i;){var a=r+i>>>1,o=e[a];null!==o&&!fu(o)&&(n?o<=t:o<t)?r=a+1:i=a}return i}return si(e,t,Al,n)}function si(e,t,n,r){t=n(t);for(var i=0,a=null==e?0:e.length,o=t!==t,s=null===t,u=fu(t),l=t===ne;i<a;){var c=Dc((i+a)/2),d=n(e[c]),f=d!==ne,h=null===d,p=d===d,m=fu(d);if(o)var v=r||p;else v=l?p&&(r||f):s?p&&f&&(r||!h):u?p&&f&&!h&&(r||!m):!h&&!m&&(r?d<=t:d<t);v?i=c+1:a=c}return qc(a,De)}function ui(e,t){for(var n=-1,r=e.length,i=0,a=[];++n<r;){var o=e[n],s=t?t(o):o;if(!n||!Vs(s,u)){var u=s;a[i++]=0===o?0:o}}return a}function li(e){return"number"==typeof e?e:fu(e)?Pe:+e}function ci(e){if("string"==typeof e)return e;if(hf(e))return h(e,ci)+"";if(fu(e))return ud?ud.call(e):"";var t=e+"";return"0"==t&&1/e==-je?"-0":t}function di(e,t,n){var r=-1,i=d,a=e.length,o=!0,s=[],u=s;if(n)o=!1,i=f;else if(a>=re){var l=t?null:yd(e);if(l)return $(l);o=!1,i=D,u=new pn}else u=t?[]:s;e:for(;++r<a;){var c=e[r],h=t?t(c):c;if(c=n||0!==c?c:0,o&&h===h){for(var p=u.length;p--;)if(u[p]===h)continue e;t&&u.push(h),s.push(c)}else i(u,h,n)||(u!==s&&u.push(h),s.push(c))}return s}function fi(e,t){return t=bi(t,e),null==(e=qa(e,t))||delete e[Ya(go(t))]}function hi(e,t,n,r){return ni(e,t,n(hr(e,t)),r)}function pi(e,t,n,r){for(var i=e.length,a=r?i:-1;(r?a--:++a<i)&&t(e[a],a,e););return n?ii(e,r?0:a,r?a+1:i):ii(e,r?a+1:0,r?i:a)}function mi(e,t){var n=e;return n instanceof y&&(n=n.value()),m(t,function(e,t){return t.func.apply(t.thisArg,p([e],t.args))},n)}function vi(e,t,n){var r=e.length;if(r<2)return r?di(e[0]):[];for(var i=-1,a=Ql(r);++i<r;)for(var o=e[i],s=-1;++s<r;)s!=i&&(a[i]=ir(a[i]||o,e[s],t,n));return di(lr(a,1),t,n)}function gi(e,t,n){for(var r=-1,i=e.length,a=t.length,o={};++r<i;){var s=r<a?t[r]:ne;n(o,e[r],s)}return o}function yi(e){return Gs(e)?e:[]}function _i(e){return"function"==typeof e?e:Al}function bi(e,t){return hf(e)?e:Oa(e,t)?[e]:Cd(wu(e))}function Ti(e,t,n){var r=e.length;return n=n===ne?r:n,!t&&n>=r?e:ii(e,t,n)}function Si(e,t){if(t)return e.slice();var n=e.length,r=Sc?Sc(n):new e.constructor(n);return e.copy(r),r}function wi(e){var t=new e.constructor(e.byteLength);return new Tc(t).set(new Tc(e)),t}function ki(e,t){var n=t?wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}function Ei(e){var t=new e.constructor(e.source,Ft.exec(e));return t.lastIndex=e.lastIndex,t}function Ai(e){return sd?rc(sd.call(e)):{}}function Ci(e,t){var n=t?wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function Li(e,t){if(e!==t){var n=e!==ne,r=null===e,i=e===e,a=fu(e),o=t!==ne,s=null===t,u=t===t,l=fu(t);if(!s&&!l&&!a&&e>t||a&&o&&u&&!s&&!l||r&&o&&u||!n&&u||!i)return 1;if(!r&&!a&&!l&&e<t||l&&n&&i&&!r&&!a||s&&n&&i||!o&&i||!u)return-1}return 0}function xi(e,t,n){for(var r=-1,i=e.criteria,a=t.criteria,o=i.length,s=n.length;++r<o;){var u=Li(i[r],a[r]);if(u){if(r>=s)return u;return u*("desc"==n[r]?-1:1)}}return e.index-t.index}function ji(e,t,n,r){for(var i=-1,a=e.length,o=n.length,s=-1,u=t.length,l=Vc(a-o,0),c=Ql(u+l),d=!r;++s<u;)c[s]=t[s];for(;++i<o;)(d||i<a)&&(c[n[i]]=e[i]);for(;l--;)c[s++]=e[i++];return c}function Oi(e,t,n,r){for(var i=-1,a=e.length,o=-1,s=n.length,u=-1,l=t.length,c=Vc(a-s,0),d=Ql(c+l),f=!r;++i<c;)d[i]=e[i];for(var h=i;++u<l;)d[h+u]=t[u];for(;++o<s;)(f||i<a)&&(d[h+n[o]]=e[i++]);return d}function Ii(e,t){var n=-1,r=e.length;for(t||(t=Ql(r));++n<r;)t[n]=e[n];return t}function Pi(e,t,n,r){var i=!n;n||(n={});for(var a=-1,o=t.length;++a<o;){var s=t[a],u=r?r(n[s],e[s],s,n,e):ne;u===ne&&(u=e[s]),i?Jn(n,s,u):qn(n,s,u)}return n}function Ri(e,t){return Pi(e,bd(e),t)}function Di(e,t){return Pi(e,Td(e),t)}function Mi(e,t){return function(n,r){var i=hf(n)?o:Yn,a=t?t():{};return i(n,e,va(r,2),a)}}function Ui(e){return Zr(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:ne,o=i>2?n[2]:ne;for(a=e.length>3&&"function"==typeof a?(i--,a):ne,o&&ja(n[0],n[1],o)&&(a=i<3?ne:a,i=1),t=rc(t);++r<i;){var s=n[r];s&&e(t,s,r,a)}return t})}function Bi(e,t){return function(n,r){if(null==n)return n;if(!qs(n))return e(n,r);for(var i=n.length,a=t?i:-1,o=rc(n);(t?a--:++a<i)&&!1!==r(o[a],a,o););return n}}function Ni(e){return function(t,n,r){for(var i=-1,a=rc(t),o=r(t),s=o.length;s--;){var u=o[e?s:++i];if(!1===n(a[u],u,a))break}return t}}function Fi(e,t,n){function r(){return(this&&this!==jn&&this instanceof r?a:e).apply(i?n:this,arguments)}var i=t&pe,a=Gi(e);return r}function Vi(e){return function(t){t=wu(t);var n=V(t)?Q(t):ne,r=n?n[0]:t.charAt(0),i=n?Ti(n,1).join(""):t.slice(1);return r[e]()+i}}function qi(e){return function(t){return m(Tl(tl(t).replace(fn,"")),e,"")}}function Gi(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=ld(e.prototype),r=e.apply(n,t);return eu(r)?r:n}}function Hi(e,t,n){function r(){for(var o=arguments.length,s=Ql(o),u=o,l=ma(r);u--;)s[u]=arguments[u];var c=o<3&&s[0]!==l&&s[o-1]!==l?[]:W(s,l);return(o-=c.length)<n?ta(e,t,$i,r.placeholder,ne,s,c,ne,ne,n-o):a(this&&this!==jn&&this instanceof r?i:e,this,s)}var i=Gi(e);return r}function zi(e){return function(t,n,r){var i=rc(t);if(!qs(t)){var a=va(n,3);t=Mu(t),n=function(e){return a(i[e],e,i)}}var o=e(t,n,r);return o>-1?i[a?t[o]:o]:ne}}function Wi(e){return da(function(t){var n=t.length,r=n,a=i.prototype.thru;for(e&&t.reverse();r--;){var o=t[r];if("function"!=typeof o)throw new oc(ae);if(a&&!s&&"wrapper"==pa(o))var s=new i([],!0)}for(r=s?r:n;++r<n;){o=t[r];var u=pa(o),l="wrapper"==u?_d(o):ne;s=l&&Pa(l[0])&&l[1]==(Te|ge|_e|Se)&&!l[4].length&&1==l[9]?s[pa(l[0])].apply(s,l[3]):1==o.length&&Pa(o)?s[u]():s.thru(o)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&hf(r))return s.plant(r).value();for(var i=0,a=n?t[i].apply(this,e):r;++i<n;)a=t[i].call(this,a);return a}})}function $i(e,t,n,r,i,a,o,s,u,l){function c(){for(var g=arguments.length,y=Ql(g),_=g;_--;)y[_]=arguments[_];if(p)var b=ma(c),T=B(y,b);if(r&&(y=ji(y,r,i,p)),a&&(y=Oi(y,a,o,p)),g-=T,p&&g<l){var S=W(y,b);return ta(e,t,$i,c.placeholder,n,y,S,s,u,l-g)}var w=f?n:this,k=h?w[e]:e;return g=y.length,s?y=Ga(y,s):m&&g>1&&y.reverse(),d&&u<g&&(y.length=u),this&&this!==jn&&this instanceof c&&(k=v||Gi(k)),k.apply(w,y)}var d=t&Te,f=t&pe,h=t&me,p=t&(ge|ye),m=t&we,v=h?ne:Gi(e);return c}function Yi(e,t){return function(n,r){return Tr(n,e,t(r),{})}}function Ki(e,t){return function(n,r){var i;if(n===ne&&r===ne)return t;if(n!==ne&&(i=n),r!==ne){if(i===ne)return r;"string"==typeof n||"string"==typeof r?(n=ci(n),r=ci(r)):(n=li(n),r=li(r)),i=e(n,r)}return i}}function Xi(e){return da(function(t){return t=h(t,P(va())),Zr(function(n){var r=this;return e(t,function(e){return a(e,r,n)})})})}function Ji(e,t){t=t===ne?" ":ci(t);var n=t.length;if(n<2)return n?Qr(t,e):t;var r=Qr(t,Rc(e/J(t)));return V(t)?Ti(Q(r),0,e).join(""):r.slice(0,e)}function Qi(e,t,n,r){function i(){for(var t=-1,u=arguments.length,l=-1,c=r.length,d=Ql(c+u),f=this&&this!==jn&&this instanceof i?s:e;++l<c;)d[l]=r[l];for(;u--;)d[l++]=arguments[++t];return a(f,o?n:this,d)}var o=t&pe,s=Gi(e);return i}function Zi(e){return function(t,n,r){return r&&"number"!=typeof r&&ja(t,n,r)&&(n=r=ne),t=gu(t),n===ne?(n=t,t=0):n=gu(n),r=r===ne?t<n?1:-1:gu(r),Jr(t,n,r,e)}}function ea(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=bu(t),n=bu(n)),e(t,n)}}function ta(e,t,n,r,i,a,o,s,u,l){var c=t&ge,d=c?o:ne,f=c?ne:o,h=c?a:ne,p=c?ne:a;t|=c?_e:be,(t&=~(c?be:_e))&ve||(t&=~(pe|me));var m=[e,t,i,h,d,p,f,s,u,l],v=n.apply(ne,m);return Pa(e)&&kd(v,m),v.placeholder=r,za(v,e,t)}function na(e){var t=nc[e];return function(e,n){if(e=bu(e),n=null==n?0:qc(yu(n),292)){var r=(wu(e)+"e").split("e");return r=(wu(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"),+(r[0]+"e"+(+r[1]-n))}return t(e)}}function ra(e){return function(t){var n=Sd(t);return n==$e?H(t):n==Ze?Y(t):I(t,e(t))}}function ia(e,t,n,r,i,a,o,s){var u=t&me;if(!u&&"function"!=typeof e)throw new oc(ae);var l=r?r.length:0;if(l||(t&=~(_e|be),r=i=ne),o=o===ne?o:Vc(yu(o),0),s=s===ne?s:yu(s),l-=i?i.length:0,t&be){var c=r,d=i;r=i=ne}var f=u?ne:_d(e),h=[e,t,n,r,i,c,d,a,o,s];if(f&&Ba(h,f),e=h[0],t=h[1],n=h[2],r=h[3],i=h[4],s=h[9]=h[9]===ne?u?0:e.length:Vc(h[9]-l,0),!s&&t&(ge|ye)&&(t&=~(ge|ye)),t&&t!=pe)p=t==ge||t==ye?Hi(e,t,s):t!=_e&&t!=(pe|_e)||i.length?$i.apply(ne,h):Qi(e,t,n,r);else var p=Fi(e,t,n);return za((f?pd:kd)(p,h),e,t)}function aa(e,t,n,r){return e===ne||Vs(e,lc[n])&&!fc.call(r,n)?t:e}function oa(e,t,n,r,i,a){return eu(e)&&eu(t)&&(a.set(t,e),Vr(e,t,ne,oa,a),a.delete(t)),e}function sa(e){return lu(e)?ne:e}function ua(e,t,n,r,i,a){var o=n&fe,s=e.length,u=t.length;if(s!=u&&!(o&&u>s))return!1;var l=a.get(e);if(l&&a.get(t))return l==t;var c=-1,d=!0,f=n&he?new pn:ne;for(a.set(e,t),a.set(t,e);++c<s;){var h=e[c],p=t[c];if(r)var m=o?r(p,h,c,t,e,a):r(h,p,c,e,t,a);if(m!==ne){if(m)continue;d=!1;break}if(f){if(!g(t,function(e,t){if(!D(f,t)&&(h===e||i(h,e,n,r,a)))return f.push(t)})){d=!1;break}}else if(h!==p&&!i(h,p,n,r,a)){d=!1;break}}return a.delete(e),a.delete(t),d}function la(e,t,n,r,i,a,o){switch(n){case ot:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case at:return!(e.byteLength!=t.byteLength||!a(new Tc(e),new Tc(t)));case Ve:case qe:case Ye:return Vs(+e,+t);case He:return e.name==t.name&&e.message==t.message;case Qe:case et:return e==t+"";case $e:var s=H;case Ze:var u=r&fe;if(s||(s=$),e.size!=t.size&&!u)return!1;var l=o.get(e);if(l)return l==t;r|=he,o.set(e,t);var c=ua(s(e),s(t),r,i,a,o);return o.delete(e),c;case tt:if(sd)return sd.call(e)==sd.call(t)}return!1}function ca(e,t,n,r,i,a){var o=n&fe,s=fa(e),u=s.length;if(u!=fa(t).length&&!o)return!1;for(var l=u;l--;){var c=s[l];if(!(o?c in t:fc.call(t,c)))return!1}var d=a.get(e);if(d&&a.get(t))return d==t;var f=!0;a.set(e,t),a.set(t,e);for(var h=o;++l<u;){c=s[l];var p=e[c],m=t[c];if(r)var v=o?r(m,p,c,t,e,a):r(p,m,c,e,t,a);if(!(v===ne?p===m||i(p,m,n,r,a):v)){f=!1;break}h||(h="constructor"==c)}if(f&&!h){var g=e.constructor,y=t.constructor;g!=y&&"constructor"in e&&"constructor"in t&&!("function"==typeof g&&g instanceof g&&"function"==typeof y&&y instanceof y)&&(f=!1)}return a.delete(e),a.delete(t),f}function da(e){return Ad(Va(e,ne,uo),e+"")}function fa(e){return pr(e,Mu,bd)}function ha(e){return pr(e,Uu,Td)}function pa(e){for(var t=e.name+"",n=ed[t],r=fc.call(ed,t)?n.length:0;r--;){var i=n[r],a=i.func;if(null==a||a==e)return i.name}return t}function ma(e){return(fc.call(n,"placeholder")?n:e).placeholder}function va(){var e=n.iteratee||Cl;return e=e===Cl?Rr:e,arguments.length?e(arguments[0],arguments[1]):e}function ga(e,t){var n=e.__data__;return Ia(t)?n["string"==typeof t?"string":"hash"]:n.map}function ya(e){for(var t=Mu(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Ma(i)]}return t}function _a(e,t){var n=F(e,t);return jr(n)?n:ne}function ba(e){var t=fc.call(e,xc),n=e[xc];try{e[xc]=ne;var r=!0}catch(e){}var i=mc.call(e);return r&&(t?e[xc]=n:delete e[xc]),i}function Ta(e,t,n){for(var r=-1,i=n.length;++r<i;){var a=n[r],o=a.size;switch(a.type){case"drop":e+=o;break;case"dropRight":t-=o;break;case"take":t=qc(t,e+o);break;case"takeRight":e=Vc(e,t-o)}}return{start:e,end:t}}function Sa(e){var t=e.match(Dt);return t?t[1].split(Mt):[]}function wa(e,t,n){t=bi(t,e);for(var r=-1,i=t.length,a=!1;++r<i;){var o=Ya(t[r]);if(!(a=null!=e&&n(e,o)))break;e=e[o]}return a||++r!=i?a:!!(i=null==e?0:e.length)&&Zs(i)&&xa(o,i)&&(hf(e)||ff(e))}function ka(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&fc.call(e,"index")&&(n.index=e.index,n.input=e.input),n}function Ea(e){return"function"!=typeof e.constructor||Da(e)?{}:ld(wc(e))}function Aa(e,t,n){var r=e.constructor;switch(t){case at:return wi(e);case Ve:case qe:return new r(+e);case ot:return ki(e,n);case st:case ut:case lt:case ct:case dt:case ft:case ht:case pt:case mt:return Ci(e,n);case $e:return new r;case Ye:case et:return new r(e);case Qe:return Ei(e);case Ze:return new r;case tt:return Ai(e)}}function Ca(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(Rt,"{\n/* [wrapped with "+t+"] */\n")}function La(e){return hf(e)||ff(e)||!!(Cc&&e&&e[Cc])}function xa(e,t){var n=typeof e;return!!(t=null==t?Oe:t)&&("number"==n||"symbol"!=n&&zt.test(e))&&e>-1&&e%1==0&&e<t}function ja(e,t,n){if(!eu(n))return!1;var r=typeof t;return!!("number"==r?qs(n)&&xa(t,n.length):"string"==r&&t in n)&&Vs(n[t],e)}function Oa(e,t){if(hf(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!fu(e))||(Ct.test(e)||!At.test(e)||null!=t&&e in rc(t))}function Ia(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}function Pa(e){var t=pa(e),r=n[t];if("function"!=typeof r||!(t in y.prototype))return!1;if(e===r)return!0;var i=_d(r);return!!i&&e===i[0]}function Ra(e){return!!pc&&pc in e}function Da(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||lc)}function Ma(e){return e===e&&!eu(e)}function Ua(e,t){return function(n){return null!=n&&(n[e]===t&&(t!==ne||e in rc(n)))}}function Ba(e,t){var n=e[1],r=t[1],i=n|r,a=i<(pe|me|Te),o=r==Te&&n==ge||r==Te&&n==Se&&e[7].length<=t[8]||r==(Te|Se)&&t[7].length<=t[8]&&n==ge;if(!a&&!o)return e;r&pe&&(e[2]=t[2],i|=n&pe?0:ve);var s=t[3];if(s){var u=e[3];e[3]=u?ji(u,s,t[4]):s,e[4]=u?W(e[3],ue):t[4]}return s=t[5],s&&(u=e[5],e[5]=u?Oi(u,s,t[6]):s,e[6]=u?W(e[5],ue):t[6]),s=t[7],s&&(e[7]=s),r&Te&&(e[8]=null==e[8]?t[8]:qc(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=i,e}function Na(e){var t=[];if(null!=e)for(var n in rc(e))t.push(n);return t}function Fa(e){return mc.call(e)}function Va(e,t,n){return t=Vc(t===ne?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=Vc(r.length-t,0),s=Ql(o);++i<o;)s[i]=r[t+i];i=-1;for(var u=Ql(t+1);++i<t;)u[i]=r[i];return u[t]=n(s),a(e,this,u)}}function qa(e,t){return t.length<2?e:hr(e,ii(t,0,-1))}function Ga(e,t){for(var n=e.length,r=qc(t.length,n),i=Ii(e);r--;){var a=t[r];e[r]=xa(a,n)?i[a]:ne}return e}function Ha(e,t){if("__proto__"!=t)return e[t]}function za(e,t,n){var r=t+"";return Ad(e,Ca(r,Xa(Sa(r),n)))}function Wa(e){var t=0,n=0;return function(){var r=Gc(),i=Ce-(r-n);if(n=r,i>0){if(++t>=Ae)return arguments[0]}else t=0;return e.apply(ne,arguments)}}function $a(e,t){var n=-1,r=e.length,i=r-1;for(t=t===ne?r:t;++n<t;){var a=Xr(n,i),o=e[a];e[a]=e[n],e[n]=o}return e.length=t,e}function Ya(e){if("string"==typeof e||fu(e))return e;var t=e+"";return"0"==t&&1/e==-je?"-0":t}function Ka(e){if(null!=e){try{return dc.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Xa(e,t){return s(Ue,function(n){var r="_."+n[0];t&n[1]&&!d(e,r)&&e.push(r)}),e.sort()}function Ja(e){if(e instanceof y)return e.clone();var t=new i(e.__wrapped__,e.__chain__);return t.__actions__=Ii(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}function Qa(e,t,n){t=(n?ja(e,t,n):t===ne)?1:Vc(yu(t),0);var r=null==e?0:e.length;if(!r||t<1)return[];for(var i=0,a=0,o=Ql(Rc(r/t));i<r;)o[a++]=ii(e,i,i+=t);return o}function Za(e){for(var t=-1,n=null==e?0:e.length,r=0,i=[];++t<n;){var a=e[t];a&&(i[r++]=a)}return i}function eo(){var e=arguments.length;if(!e)return[];for(var t=Ql(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return p(hf(n)?Ii(n):[n],lr(t,1))}function to(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===ne?1:yu(t),ii(e,t<0?0:t,r)):[]}function no(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===ne?1:yu(t),t=r-t,ii(e,0,t<0?0:t)):[]}function ro(e,t){return e&&e.length?pi(e,va(t,3),!0,!0):[]}function io(e,t){return e&&e.length?pi(e,va(t,3),!0):[]}function ao(e,t,n,r){var i=null==e?0:e.length;return i?(n&&"number"!=typeof n&&ja(e,t,n)&&(n=0,r=i),sr(e,t,n,r)):[]}function oo(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:yu(n);return i<0&&(i=Vc(r+i,0)),T(e,va(t,3),i)}function so(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=r-1;return n!==ne&&(i=yu(n),i=n<0?Vc(r+i,0):qc(i,r-1)),T(e,va(t,3),i,!0)}function uo(e){return(null==e?0:e.length)?lr(e,1):[]}function lo(e){return(null==e?0:e.length)?lr(e,je):[]}function co(e,t){return(null==e?0:e.length)?(t=t===ne?1:yu(t),lr(e,t)):[]}function fo(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r}function ho(e){return e&&e.length?e[0]:ne}function po(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:yu(n);return i<0&&(i=Vc(r+i,0)),S(e,t,i)}function mo(e){return(null==e?0:e.length)?ii(e,0,-1):[]}function vo(e,t){return null==e?"":Nc.call(e,t)}function go(e){var t=null==e?0:e.length;return t?e[t-1]:ne}function yo(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=r;return n!==ne&&(i=yu(n),i=i<0?Vc(r+i,0):qc(i,r-1)),t===t?X(e,t,i):T(e,k,i,!0)}function _o(e,t){return e&&e.length?Gr(e,yu(t)):ne}function bo(e,t){return e&&e.length&&t&&t.length?Yr(e,t):e}function To(e,t,n){return e&&e.length&&t&&t.length?Yr(e,t,va(n,2)):e}function So(e,t,n){return e&&e.length&&t&&t.length?Yr(e,t,ne,n):e}function wo(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],a=e.length;for(t=va(t,3);++r<a;){var o=e[r];t(o,r,e)&&(n.push(o),i.push(r))}return Kr(e,i),n}function ko(e){return null==e?e:Wc.call(e)}function Eo(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&ja(e,t,n)?(t=0,n=r):(t=null==t?0:yu(t),n=n===ne?r:yu(n)),ii(e,t,n)):[]}function Ao(e,t){return oi(e,t)}function Co(e,t,n){return si(e,t,va(n,2))}function Lo(e,t){var n=null==e?0:e.length;if(n){var r=oi(e,t);if(r<n&&Vs(e[r],t))return r}return-1}function xo(e,t){return oi(e,t,!0)}function jo(e,t,n){return si(e,t,va(n,2),!0)}function Oo(e,t){if(null==e?0:e.length){var n=oi(e,t,!0)-1;if(Vs(e[n],t))return n}return-1}function Io(e){return e&&e.length?ui(e):[]}function Po(e,t){return e&&e.length?ui(e,va(t,2)):[]}function Ro(e){var t=null==e?0:e.length;return t?ii(e,1,t):[]}function Do(e,t,n){return e&&e.length?(t=n||t===ne?1:yu(t),ii(e,0,t<0?0:t)):[]}function Mo(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===ne?1:yu(t),t=r-t,ii(e,t<0?0:t,r)):[]}function Uo(e,t){return e&&e.length?pi(e,va(t,3),!1,!0):[]}function Bo(e,t){return e&&e.length?pi(e,va(t,3)):[]}function No(e){return e&&e.length?di(e):[]}function Fo(e,t){return e&&e.length?di(e,va(t,2)):[]}function Vo(e,t){return t="function"==typeof t?t:ne,e&&e.length?di(e,ne,t):[]}function qo(e){if(!e||!e.length)return[];var t=0;return e=c(e,function(e){if(Gs(e))return t=Vc(e.length,t),!0}),O(t,function(t){return h(e,A(t))})}function Go(e,t){if(!e||!e.length)return[];var n=qo(e);return null==t?n:h(n,function(e){return a(t,ne,e)})}function Ho(e,t){return gi(e||[],t||[],qn)}function zo(e,t){return gi(e||[],t||[],ni)}function Wo(e){var t=n(e);return t.__chain__=!0,t}function $o(e,t){return t(e),e}function Yo(e,t){return t(e)}function Ko(){return Wo(this)}function Xo(){return new i(this.value(),this.__chain__)}function Jo(){this.__values__===ne&&(this.__values__=vu(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?ne:this.__values__[this.__index__++]}}function Qo(){return this}function Zo(e){for(var t,n=this;n instanceof r;){var i=Ja(n);i.__index__=0,i.__values__=ne,t?a.__wrapped__=i:t=i;var a=i;n=n.__wrapped__}return a.__wrapped__=e,t}function es(){var e=this.__wrapped__;if(e instanceof y){var t=e;return this.__actions__.length&&(t=new y(this)),t=t.reverse(),t.__actions__.push({func:Yo,args:[ko],thisArg:ne}),new i(t,this.__chain__)}return this.thru(ko)}function ts(){return mi(this.__wrapped__,this.__actions__)}function ns(e,t,n){var r=hf(e)?l:ar;return n&&ja(e,t,n)&&(t=ne),r(e,va(t,3))}function rs(e,t){return(hf(e)?c:ur)(e,va(t,3))}function is(e,t){return lr(cs(e,t),1)}function as(e,t){return lr(cs(e,t),je)}function os(e,t,n){return n=n===ne?1:yu(n),lr(cs(e,t),n)}function ss(e,t){return(hf(e)?s:cd)(e,va(t,3))}function us(e,t){return(hf(e)?u:dd)(e,va(t,3))}function ls(e,t,n,r){e=qs(e)?e:Ku(e),n=n&&!r?yu(n):0;var i=e.length;return n<0&&(n=Vc(i+n,0)),du(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&S(e,t,n)>-1}function cs(e,t){return(hf(e)?h:Br)(e,va(t,3))}function ds(e,t,n,r){return null==e?[]:(hf(t)||(t=null==t?[]:[t]),n=r?ne:n,hf(n)||(n=null==n?[]:[n]),Hr(e,t,n))}function fs(e,t,n){var r=hf(e)?m:L,i=arguments.length<3;return r(e,va(t,4),n,i,cd)}function hs(e,t,n){var r=hf(e)?v:L,i=arguments.length<3;return r(e,va(t,4),n,i,dd)}function ps(e,t){return(hf(e)?c:ur)(e,Ls(va(t,3)))}function ms(e){return(hf(e)?On:ei)(e)}function vs(e,t,n){return t=(n?ja(e,t,n):t===ne)?1:yu(t),(hf(e)?In:ti)(e,t)}function gs(e){return(hf(e)?Rn:ri)(e)}function ys(e){if(null==e)return 0;if(qs(e))return du(e)?J(e):e.length;var t=Sd(e);return t==$e||t==Ze?e.size:Dr(e).length}function _s(e,t,n){var r=hf(e)?g:ai;return n&&ja(e,t,n)&&(t=ne),r(e,va(t,3))}function bs(e,t){if("function"!=typeof t)throw new oc(ae);return e=yu(e),function(){if(--e<1)return t.apply(this,arguments)}}function Ts(e,t,n){return t=n?ne:t,t=e&&null==t?e.length:t,ia(e,Te,ne,ne,ne,ne,t)}function Ss(e,t){var n;if("function"!=typeof t)throw new oc(ae);return e=yu(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=ne),n}}function ws(e,t,n){t=n?ne:t;var r=ia(e,ge,ne,ne,ne,ne,ne,t);return r.placeholder=ws.placeholder,r}function ks(e,t,n){t=n?ne:t;var r=ia(e,ye,ne,ne,ne,ne,ne,t);return r.placeholder=ks.placeholder,r}function Es(e,t,n){function r(t){var n=f,r=h;return f=h=ne,y=t,m=e.apply(r,n)}function i(e){return y=e,v=Ed(s,t),_?r(e):m}function a(e){var n=e-g,r=e-y,i=t-n;return b?qc(i,p-r):i}function o(e){var n=e-g,r=e-y;return g===ne||n>=t||n<0||b&&r>=p}function s(){var e=ef();if(o(e))return u(e);v=Ed(s,a(e))}function u(e){return v=ne,T&&f?r(e):(f=h=ne,m)}function l(){v!==ne&&gd(v),y=0,f=g=h=v=ne}function c(){return v===ne?m:u(ef())}function d(){var e=ef(),n=o(e);if(f=arguments,h=this,g=e,n){if(v===ne)return i(g);if(b)return v=Ed(s,t),r(g)}return v===ne&&(v=Ed(s,t)),m}var f,h,p,m,v,g,y=0,_=!1,b=!1,T=!0;if("function"!=typeof e)throw new oc(ae);return t=bu(t)||0,eu(n)&&(_=!!n.leading,b="maxWait"in n,p=b?Vc(bu(n.maxWait)||0,t):p,T="trailing"in n?!!n.trailing:T),d.cancel=l,d.flush=c,d}function As(e){return ia(e,we)}function Cs(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new oc(ae);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(Cs.Cache||on),n}function Ls(e){if("function"!=typeof e)throw new oc(ae);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function xs(e){return Ss(2,e)}function js(e,t){if("function"!=typeof e)throw new oc(ae);return t=t===ne?t:yu(t),Zr(e,t)}function Os(e,t){if("function"!=typeof e)throw new oc(ae);return t=null==t?0:Vc(yu(t),0),Zr(function(n){var r=n[t],i=Ti(n,0,t);return r&&p(i,r),a(e,this,i)})}function Is(e,t,n){var r=!0,i=!0;if("function"!=typeof e)throw new oc(ae);return eu(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Es(e,t,{leading:r,maxWait:t,trailing:i})}function Ps(e){return Ts(e,1)}function Rs(e,t){return sf(_i(t),e)}function Ds(){if(!arguments.length)return[];var e=arguments[0];return hf(e)?e:[e]}function Ms(e){return er(e,de)}function Us(e,t){return t="function"==typeof t?t:ne,er(e,de,t)}function Bs(e){return er(e,le|de)}function Ns(e,t){return t="function"==typeof t?t:ne,er(e,le|de,t)}function Fs(e,t){return null==t||nr(e,t,Mu(t))}function Vs(e,t){return e===t||e!==e&&t!==t}function qs(e){return null!=e&&Zs(e.length)&&!Js(e)}function Gs(e){return tu(e)&&qs(e)}function Hs(e){return!0===e||!1===e||tu(e)&&mr(e)==Ve}function zs(e){return tu(e)&&1===e.nodeType&&!lu(e)}function Ws(e){if(null==e)return!0;if(qs(e)&&(hf(e)||"string"==typeof e||"function"==typeof e.splice||mf(e)||bf(e)||ff(e)))return!e.length;var t=Sd(e);if(t==$e||t==Ze)return!e.size;if(Da(e))return!Dr(e).length;for(var n in e)if(fc.call(e,n))return!1;return!0}function $s(e,t){return Ar(e,t)}function Ys(e,t,n){n="function"==typeof n?n:ne;var r=n?n(e,t):ne;return r===ne?Ar(e,t,ne,n):!!r}function Ks(e){if(!tu(e))return!1;var t=mr(e);return t==He||t==Ge||"string"==typeof e.message&&"string"==typeof e.name&&!lu(e)}function Xs(e){return"number"==typeof e&&Bc(e)}function Js(e){if(!eu(e))return!1;var t=mr(e);return t==ze||t==We||t==Fe||t==Je}function Qs(e){return"number"==typeof e&&e==yu(e)}function Zs(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=Oe}function eu(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function tu(e){return null!=e&&"object"==typeof e}function nu(e,t){return e===t||xr(e,t,ya(t))}function ru(e,t,n){return n="function"==typeof n?n:ne,xr(e,t,ya(t),n)}function iu(e){return uu(e)&&e!=+e}function au(e){if(wd(e))throw new ec(ie);return jr(e)}function ou(e){return null===e}function su(e){return null==e}function uu(e){return"number"==typeof e||tu(e)&&mr(e)==Ye}function lu(e){if(!tu(e)||mr(e)!=Xe)return!1;var t=wc(e);if(null===t)return!0;var n=fc.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&dc.call(n)==vc}function cu(e){return Qs(e)&&e>=-Oe&&e<=Oe}function du(e){return"string"==typeof e||!hf(e)&&tu(e)&&mr(e)==et}function fu(e){return"symbol"==typeof e||tu(e)&&mr(e)==tt}function hu(e){return e===ne}function pu(e){return tu(e)&&Sd(e)==rt}function mu(e){return tu(e)&&mr(e)==it}function vu(e){if(!e)return[];if(qs(e))return du(e)?Q(e):Ii(e);if(Lc&&e[Lc])return G(e[Lc]());var t=Sd(e);return(t==$e?H:t==Ze?$:Ku)(e)}function gu(e){if(!e)return 0===e?e:0;if((e=bu(e))===je||e===-je){return(e<0?-1:1)*Ie}return e===e?e:0}function yu(e){var t=gu(e),n=t%1;return t===t?n?t-n:t:0}function _u(e){return e?Zn(yu(e),0,Re):0}function bu(e){if("number"==typeof e)return e;if(fu(e))return Pe;if(eu(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=eu(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(Ot,"");var n=qt.test(e);return n||Ht.test(e)?Cn(e.slice(2),n?2:8):Vt.test(e)?Pe:+e}function Tu(e){return Pi(e,Uu(e))}function Su(e){return e?Zn(yu(e),-Oe,Oe):0===e?e:0}function wu(e){return null==e?"":ci(e)}function ku(e,t){var n=ld(e);return null==t?n:Kn(n,t)}function Eu(e,t){return b(e,va(t,3),cr)}function Au(e,t){return b(e,va(t,3),dr)}function Cu(e,t){return null==e?e:fd(e,va(t,3),Uu)}function Lu(e,t){return null==e?e:hd(e,va(t,3),Uu)}function xu(e,t){return e&&cr(e,va(t,3))}function ju(e,t){return e&&dr(e,va(t,3))}function Ou(e){return null==e?[]:fr(e,Mu(e))}function Iu(e){return null==e?[]:fr(e,Uu(e))}function Pu(e,t,n){var r=null==e?ne:hr(e,t);return r===ne?n:r}function Ru(e,t){return null!=e&&wa(e,t,gr)}function Du(e,t){return null!=e&&wa(e,t,yr)}function Mu(e){return qs(e)?xn(e):Dr(e)}function Uu(e){return qs(e)?xn(e,!0):Mr(e)}function Bu(e,t){var n={};return t=va(t,3),cr(e,function(e,r,i){Jn(n,t(e,r,i),e)}),n}function Nu(e,t){var n={};return t=va(t,3),cr(e,function(e,r,i){Jn(n,r,t(e,r,i))}),n}function Fu(e,t){return Vu(e,Ls(va(t)))}function Vu(e,t){if(null==e)return{};var n=h(ha(e),function(e){return[e]});return t=va(t),Wr(e,n,function(e,n){return t(e,n[0])})}function qu(e,t,n){t=bi(t,e);var r=-1,i=t.length;for(i||(i=1,e=ne);++r<i;){var a=null==e?ne:e[Ya(t[r])];a===ne&&(r=i,a=n),e=Js(a)?a.call(e):a}return e}function Gu(e,t,n){return null==e?e:ni(e,t,n)}function Hu(e,t,n,r){return r="function"==typeof r?r:ne,null==e?e:ni(e,t,n,r)}function zu(e,t,n){var r=hf(e),i=r||mf(e)||bf(e);if(t=va(t,4),null==n){var a=e&&e.constructor;n=i?r?new a:[]:eu(e)&&Js(a)?ld(wc(e)):{}}return(i?s:cr)(e,function(e,r,i){return t(n,e,r,i)}),n}function Wu(e,t){return null==e||fi(e,t)}function $u(e,t,n){return null==e?e:hi(e,t,_i(n))}function Yu(e,t,n,r){return r="function"==typeof r?r:ne,null==e?e:hi(e,t,_i(n),r)}function Ku(e){return null==e?[]:R(e,Mu(e))}function Xu(e){return null==e?[]:R(e,Uu(e))}function Ju(e,t,n){return n===ne&&(n=t,t=ne),n!==ne&&(n=bu(n),n=n===n?n:0),t!==ne&&(t=bu(t),t=t===t?t:0),Zn(bu(e),t,n)}function Qu(e,t,n){return t=gu(t),n===ne?(n=t,t=0):n=gu(n),e=bu(e),_r(e,t,n)}function Zu(e,t,n){if(n&&"boolean"!=typeof n&&ja(e,t,n)&&(t=n=ne),n===ne&&("boolean"==typeof t?(n=t,t=ne):"boolean"==typeof e&&(n=e,e=ne)),e===ne&&t===ne?(e=0,t=1):(e=gu(e),t===ne?(t=e,e=0):t=gu(t)),e>t){var r=e;e=t,t=r}if(n||e%1||t%1){var i=zc();return qc(e+i*(t-e+An("1e-"+((i+"").length-1))),t)}return Xr(e,t)}function el(e){return Wf(wu(e).toLowerCase())}function tl(e){return(e=wu(e))&&e.replace(Wt,Gn).replace(hn,"")}function nl(e,t,n){e=wu(e),t=ci(t);var r=e.length;n=n===ne?r:Zn(yu(n),0,r);var i=n;return(n-=t.length)>=0&&e.slice(n,i)==t}function rl(e){return e=wu(e),e&&St.test(e)?e.replace(bt,Hn):e}function il(e){return e=wu(e),e&&jt.test(e)?e.replace(xt,"\\$&"):e}function al(e,t,n){e=wu(e),t=yu(t);var r=t?J(e):0;if(!t||r>=t)return e;var i=(t-r)/2;return Ji(Dc(i),n)+e+Ji(Rc(i),n)}function ol(e,t,n){e=wu(e),t=yu(t);var r=t?J(e):0;return t&&r<t?e+Ji(t-r,n):e}function sl(e,t,n){e=wu(e),t=yu(t);var r=t?J(e):0;return t&&r<t?Ji(t-r,n)+e:e}function ul(e,t,n){return n||null==t?t=0:t&&(t=+t),Hc(wu(e).replace(It,""),t||0)}function ll(e,t,n){return t=(n?ja(e,t,n):t===ne)?1:yu(t),Qr(wu(e),t)}function cl(){var e=arguments,t=wu(e[0]);return e.length<3?t:t.replace(e[1],e[2])}function dl(e,t,n){return n&&"number"!=typeof n&&ja(e,t,n)&&(t=n=ne),(n=n===ne?Re:n>>>0)?(e=wu(e),e&&("string"==typeof t||null!=t&&!yf(t))&&!(t=ci(t))&&V(e)?Ti(Q(e),0,n):e.split(t,n)):[]}function fl(e,t,n){return e=wu(e),n=null==n?0:Zn(yu(n),0,e.length),t=ci(t),e.slice(n,n+t.length)==t}function hl(e,t,r){var i=n.templateSettings;r&&ja(e,t,r)&&(t=ne),e=wu(e),t=Ef({},t,i,aa);var a,o,s=Ef({},t.imports,i.imports,aa),u=Mu(s),l=R(s,u),c=0,d=t.interpolate||$t,f="__p += '",h=ic((t.escape||$t).source+"|"+d.source+"|"+(d===Et?Nt:$t).source+"|"+(t.evaluate||$t).source+"|$","g"),p="//# sourceURL="+("sourceURL"in t?t.sourceURL:"lodash.templateSources["+ ++_n+"]")+"\n";e.replace(h,function(t,n,r,i,s,u){return r||(r=i),f+=e.slice(c,u).replace(Yt,N),n&&(a=!0,f+="' +\n__e("+n+") +\n'"),s&&(o=!0,f+="';\n"+s+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),c=u+t.length,t}),f+="';\n";var m=t.variable;m||(f="with (obj) {\n"+f+"\n}\n"),f=(o?f.replace(vt,""):f).replace(gt,"$1").replace(yt,"$1;"),f="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(a?", __e = _.escape":"")+(o?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=$f(function(){return tc(u,p+"return "+f).apply(ne,l)});if(v.source=f,Ks(v))throw v;return v}function pl(e){return wu(e).toLowerCase()}function ml(e){return wu(e).toUpperCase()}function vl(e,t,n){if((e=wu(e))&&(n||t===ne))return e.replace(Ot,"");if(!e||!(t=ci(t)))return e;var r=Q(e),i=Q(t);return Ti(r,M(r,i),U(r,i)+1).join("")}function gl(e,t,n){if((e=wu(e))&&(n||t===ne))return e.replace(Pt,"");if(!e||!(t=ci(t)))return e;var r=Q(e);return Ti(r,0,U(r,Q(t))+1).join("")}function yl(e,t,n){if((e=wu(e))&&(n||t===ne))return e.replace(It,"");if(!e||!(t=ci(t)))return e;var r=Q(e);return Ti(r,M(r,Q(t))).join("")}function _l(e,t){var n=ke,r=Ee;if(eu(t)){var i="separator"in t?t.separator:i;n="length"in t?yu(t.length):n,r="omission"in t?ci(t.omission):r}e=wu(e);var a=e.length;if(V(e)){var o=Q(e);a=o.length}if(n>=a)return e;var s=n-J(r);if(s<1)return r;var u=o?Ti(o,0,s).join(""):e.slice(0,s);if(i===ne)return u+r;if(o&&(s+=u.length-s),yf(i)){if(e.slice(s).search(i)){var l,c=u;for(i.global||(i=ic(i.source,wu(Ft.exec(i))+"g")),i.lastIndex=0;l=i.exec(c);)var d=l.index;u=u.slice(0,d===ne?s:d)}}else if(e.indexOf(ci(i),s)!=s){var f=u.lastIndexOf(i);f>-1&&(u=u.slice(0,f))}return u+r}function bl(e){return e=wu(e),e&&Tt.test(e)?e.replace(_t,zn):e}function Tl(e,t,n){return e=wu(e),t=n?ne:t,t===ne?q(e)?te(e):_(e):e.match(t)||[]}function Sl(e){var t=null==e?0:e.length,n=va();return e=t?h(e,function(e){if("function"!=typeof e[1])throw new oc(ae);return[n(e[0]),e[1]]}):[],Zr(function(n){for(var r=-1;++r<t;){var i=e[r];if(a(i[0],this,n))return a(i[1],this,n)}})}function wl(e){return tr(er(e,le))}function kl(e){return function(){return e}}function El(e,t){return null==e||e!==e?t:e}function Al(e){return e}function Cl(e){return Rr("function"==typeof e?e:er(e,le))}function Ll(e){return Nr(er(e,le))}function xl(e,t){return Fr(e,er(t,le))}function jl(e,t,n){var r=Mu(t),i=fr(t,r);null!=n||eu(t)&&(i.length||!r.length)||(n=t,t=e,e=this,i=fr(t,Mu(t)));var a=!(eu(n)&&"chain"in n&&!n.chain),o=Js(e);return s(i,function(n){var r=t[n];e[n]=r,o&&(e.prototype[n]=function(){var t=this.__chain__;if(a||t){var n=e(this.__wrapped__);return(n.__actions__=Ii(this.__actions__)).push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,p([this.value()],arguments))})}),e}function Ol(){return jn._===this&&(jn._=gc),this}function Il(){}function Pl(e){return e=yu(e),Zr(function(t){return Gr(t,e)})}function Rl(e){return Oa(e)?A(Ya(e)):$r(e)}function Dl(e){return function(t){return null==e?ne:hr(e,t)}}function Ml(){return[]}function Ul(){return!1}function Bl(){return{}}function Nl(){return""}function Fl(){return!0}function Vl(e,t){if((e=yu(e))<1||e>Oe)return[];var n=Re,r=qc(e,Re);t=va(t),e-=Re;for(var i=O(r,t);++n<e;)t(n);return i}function ql(e){return hf(e)?h(e,Ya):fu(e)?[e]:Ii(Cd(wu(e)))}function Gl(e){var t=++hc;return wu(e)+t}function Hl(e){return e&&e.length?or(e,Al,vr):ne}function zl(e,t){return e&&e.length?or(e,va(t,2),vr):ne}function Wl(e){return E(e,Al)}function $l(e,t){return E(e,va(t,2))}function Yl(e){return e&&e.length?or(e,Al,Ur):ne}function Kl(e,t){return e&&e.length?or(e,va(t,2),Ur):ne}function Xl(e){return e&&e.length?j(e,Al):0}function Jl(e,t){return e&&e.length?j(e,va(t,2)):0}t=null==t?jn:Wn.defaults(jn.Object(),t,Wn.pick(jn,yn));var Ql=t.Array,Zl=t.Date,ec=t.Error,tc=t.Function,nc=t.Math,rc=t.Object,ic=t.RegExp,ac=t.String,oc=t.TypeError,sc=Ql.prototype,uc=tc.prototype,lc=rc.prototype,cc=t["__core-js_shared__"],dc=uc.toString,fc=lc.hasOwnProperty,hc=0,pc=function(){var e=/[^.]+$/.exec(cc&&cc.keys&&cc.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),mc=lc.toString,vc=dc.call(rc),gc=jn._,yc=ic("^"+dc.call(fc).replace(xt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),_c=Pn?t.Buffer:ne,bc=t.Symbol,Tc=t.Uint8Array,Sc=_c?_c.allocUnsafe:ne,wc=z(rc.getPrototypeOf,rc),kc=rc.create,Ec=lc.propertyIsEnumerable,Ac=sc.splice,Cc=bc?bc.isConcatSpreadable:ne,Lc=bc?bc.iterator:ne,xc=bc?bc.toStringTag:ne,jc=function(){try{var e=_a(rc,"defineProperty");return e({},"",{}),e}catch(e){}}(),Oc=t.clearTimeout!==jn.clearTimeout&&t.clearTimeout,Ic=Zl&&Zl.now!==jn.Date.now&&Zl.now,Pc=t.setTimeout!==jn.setTimeout&&t.setTimeout,Rc=nc.ceil,Dc=nc.floor,Mc=rc.getOwnPropertySymbols,Uc=_c?_c.isBuffer:ne,Bc=t.isFinite,Nc=sc.join,Fc=z(rc.keys,rc),Vc=nc.max,qc=nc.min,Gc=Zl.now,Hc=t.parseInt,zc=nc.random,Wc=sc.reverse,$c=_a(t,"DataView"),Yc=_a(t,"Map"),Kc=_a(t,"Promise"),Xc=_a(t,"Set"),Jc=_a(t,"WeakMap"),Qc=_a(rc,"create"),Zc=Jc&&new Jc,ed={},td=Ka($c),nd=Ka(Yc),rd=Ka(Kc),id=Ka(Xc),ad=Ka(Jc),od=bc?bc.prototype:ne,sd=od?od.valueOf:ne,ud=od?od.toString:ne,ld=function(){function e(){}return function(t){if(!eu(t))return{};if(kc)return kc(t);e.prototype=t;var n=new e;return e.prototype=ne,n}}();n.templateSettings={escape:wt,evaluate:kt,interpolate:Et,variable:"",imports:{_:n}},n.prototype=r.prototype,n.prototype.constructor=n,i.prototype=ld(r.prototype),i.prototype.constructor=i,y.prototype=ld(r.prototype),y.prototype.constructor=y,ee.prototype.clear=Ut,ee.prototype.delete=Kt,ee.prototype.get=Xt,ee.prototype.has=Jt,ee.prototype.set=Qt,Zt.prototype.clear=en,Zt.prototype.delete=tn,Zt.prototype.get=nn,Zt.prototype.has=rn,Zt.prototype.set=an,on.prototype.clear=sn,on.prototype.delete=un,on.prototype.get=ln,on.prototype.has=cn,on.prototype.set=dn,pn.prototype.add=pn.prototype.push=mn,pn.prototype.has=vn,gn.prototype.clear=Sn,gn.prototype.delete=wn,gn.prototype.get=kn,gn.prototype.has=En,gn.prototype.set=Ln;var cd=Bi(cr),dd=Bi(dr,!0),fd=Ni(),hd=Ni(!0),pd=Zc?function(e,t){return Zc.set(e,t),e}:Al,md=jc?function(e,t){return jc(e,"toString",{configurable:!0,enumerable:!1,value:kl(t),writable:!0})}:Al,vd=Zr,gd=Oc||function(e){return jn.clearTimeout(e)},yd=Xc&&1/$(new Xc([,-0]))[1]==je?function(e){return new Xc(e)}:Il,_d=Zc?function(e){return Zc.get(e)}:Il,bd=Mc?function(e){return null==e?[]:(e=rc(e),c(Mc(e),function(t){return Ec.call(e,t)}))}:Ml,Td=Mc?function(e){for(var t=[];e;)p(t,bd(e)),e=wc(e);return t}:Ml,Sd=mr;($c&&Sd(new $c(new ArrayBuffer(1)))!=ot||Yc&&Sd(new Yc)!=$e||Kc&&"[object Promise]"!=Sd(Kc.resolve())||Xc&&Sd(new Xc)!=Ze||Jc&&Sd(new Jc)!=rt)&&(Sd=function(e){var t=mr(e),n=t==Xe?e.constructor:ne,r=n?Ka(n):"";if(r)switch(r){case td:return ot;case nd:return $e;case rd:return"[object Promise]";case id:return Ze;case ad:return rt}return t});var wd=cc?Js:Ul,kd=Wa(pd),Ed=Pc||function(e,t){return jn.setTimeout(e,t)},Ad=Wa(md),Cd=function(e){var t=Cs(e,function(e){return n.size===se&&n.clear(),e}),n=t.cache;return t}(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Lt,function(e,n,r,i){t.push(r?i.replace(Bt,"$1"):n||e)}),t}),Ld=Zr(function(e,t){return Gs(e)?ir(e,lr(t,1,Gs,!0)):[]}),xd=Zr(function(e,t){var n=go(t);return Gs(n)&&(n=ne),Gs(e)?ir(e,lr(t,1,Gs,!0),va(n,2)):[]}),jd=Zr(function(e,t){var n=go(t);return Gs(n)&&(n=ne),Gs(e)?ir(e,lr(t,1,Gs,!0),ne,n):[]}),Od=Zr(function(e){var t=h(e,yi);return t.length&&t[0]===e[0]?br(t):[]}),Id=Zr(function(e){var t=go(e),n=h(e,yi);return t===go(n)?t=ne:n.pop(),n.length&&n[0]===e[0]?br(n,va(t,2)):[]}),Pd=Zr(function(e){var t=go(e),n=h(e,yi);return t="function"==typeof t?t:ne,t&&n.pop(),n.length&&n[0]===e[0]?br(n,ne,t):[]}),Rd=Zr(bo),Dd=da(function(e,t){var n=null==e?0:e.length,r=Qn(e,t);return Kr(e,h(t,function(e){return xa(e,n)?+e:e}).sort(Li)),r}),Md=Zr(function(e){return di(lr(e,1,Gs,!0))}),Ud=Zr(function(e){var t=go(e);return Gs(t)&&(t=ne),di(lr(e,1,Gs,!0),va(t,2))}),Bd=Zr(function(e){var t=go(e);return t="function"==typeof t?t:ne,di(lr(e,1,Gs,!0),ne,t)}),Nd=Zr(function(e,t){return Gs(e)?ir(e,t):[]}),Fd=Zr(function(e){return vi(c(e,Gs))}),Vd=Zr(function(e){var t=go(e);return Gs(t)&&(t=ne),vi(c(e,Gs),va(t,2))}),qd=Zr(function(e){var t=go(e);return t="function"==typeof t?t:ne,vi(c(e,Gs),ne,t)}),Gd=Zr(qo),Hd=Zr(function(e){var t=e.length,n=t>1?e[t-1]:ne;return n="function"==typeof n?(e.pop(),n):ne,Go(e,n)}),zd=da(function(e){var t=e.length,n=t?e[0]:0,r=this.__wrapped__,a=function(t){return Qn(t,e)};return!(t>1||this.__actions__.length)&&r instanceof y&&xa(n)?(r=r.slice(n,+n+(t?1:0)),r.__actions__.push({func:Yo,args:[a],thisArg:ne}),new i(r,this.__chain__).thru(function(e){return t&&!e.length&&e.push(ne),e})):this.thru(a)}),Wd=Mi(function(e,t,n){fc.call(e,n)?++e[n]:Jn(e,n,1)}),$d=zi(oo),Yd=zi(so),Kd=Mi(function(e,t,n){fc.call(e,n)?e[n].push(t):Jn(e,n,[t])}),Xd=Zr(function(e,t,n){var r=-1,i="function"==typeof t,o=qs(e)?Ql(e.length):[];return cd(e,function(e){o[++r]=i?a(t,e,n):Sr(e,t,n)}),o}),Jd=Mi(function(e,t,n){Jn(e,n,t)}),Qd=Mi(function(e,t,n){e[n?0:1].push(t)},function(){return[[],[]]}),Zd=Zr(function(e,t){if(null==e)return[];var n=t.length;return n>1&&ja(e,t[0],t[1])?t=[]:n>2&&ja(t[0],t[1],t[2])&&(t=[t[0]]),Hr(e,lr(t,1),[])}),ef=Ic||function(){return jn.Date.now()},tf=Zr(function(e,t,n){var r=pe;if(n.length){var i=W(n,ma(tf));r|=_e}return ia(e,r,t,n,i)}),nf=Zr(function(e,t,n){var r=pe|me;if(n.length){var i=W(n,ma(nf));r|=_e}return ia(t,r,e,n,i)}),rf=Zr(function(e,t){return rr(e,1,t)}),af=Zr(function(e,t,n){return rr(e,bu(t)||0,n)});Cs.Cache=on;var of=vd(function(e,t){t=1==t.length&&hf(t[0])?h(t[0],P(va())):h(lr(t,1),P(va()));var n=t.length;return Zr(function(r){for(var i=-1,o=qc(r.length,n);++i<o;)r[i]=t[i].call(this,r[i]);return a(e,this,r)})}),sf=Zr(function(e,t){var n=W(t,ma(sf));return ia(e,_e,ne,t,n)}),uf=Zr(function(e,t){var n=W(t,ma(uf));return ia(e,be,ne,t,n)}),lf=da(function(e,t){return ia(e,Se,ne,ne,ne,t)}),cf=ea(vr),df=ea(function(e,t){return e>=t}),ff=wr(function(){return arguments}())?wr:function(e){return tu(e)&&fc.call(e,"callee")&&!Ec.call(e,"callee")},hf=Ql.isArray,pf=Mn?P(Mn):kr,mf=Uc||Ul,vf=Un?P(Un):Er,gf=Bn?P(Bn):Lr,yf=Nn?P(Nn):Or,_f=Fn?P(Fn):Ir,bf=Vn?P(Vn):Pr,Tf=ea(Ur),Sf=ea(function(e,t){return e<=t}),wf=Ui(function(e,t){if(Da(t)||qs(t))return void Pi(t,Mu(t),e);for(var n in t)fc.call(t,n)&&qn(e,n,t[n])}),kf=Ui(function(e,t){Pi(t,Uu(t),e)}),Ef=Ui(function(e,t,n,r){Pi(t,Uu(t),e,r)}),Af=Ui(function(e,t,n,r){Pi(t,Mu(t),e,r)}),Cf=da(Qn),Lf=Zr(function(e,t){e=rc(e);var n=-1,r=t.length,i=r>2?t[2]:ne;for(i&&ja(t[0],t[1],i)&&(r=1);++n<r;)for(var a=t[n],o=Uu(a),s=-1,u=o.length;++s<u;){var l=o[s],c=e[l];(c===ne||Vs(c,lc[l])&&!fc.call(e,l))&&(e[l]=a[l])}return e}),xf=Zr(function(e){return e.push(ne,oa),a(Rf,ne,e)}),jf=Yi(function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=mc.call(t)),e[t]=n},kl(Al)),Of=Yi(function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=mc.call(t)),fc.call(e,t)?e[t].push(n):e[t]=[n]},va),If=Zr(Sr),Pf=Ui(function(e,t,n){Vr(e,t,n)}),Rf=Ui(function(e,t,n,r){Vr(e,t,n,r)}),Df=da(function(e,t){var n={};if(null==e)return n;var r=!1;t=h(t,function(t){return t=bi(t,e),r||(r=t.length>1),t}),Pi(e,ha(e),n),r&&(n=er(n,le|ce|de,sa));for(var i=t.length;i--;)fi(n,t[i]);return n}),Mf=da(function(e,t){return null==e?{}:zr(e,t)}),Uf=ra(Mu),Bf=ra(Uu),Nf=qi(function(e,t,n){return t=t.toLowerCase(),e+(n?el(t):t)}),Ff=qi(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),Vf=qi(function(e,t,n){return e+(n?" ":"")+t.toLowerCase()}),qf=Vi("toLowerCase"),Gf=qi(function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}),Hf=qi(function(e,t,n){return e+(n?" ":"")+Wf(t)}),zf=qi(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),Wf=Vi("toUpperCase"),$f=Zr(function(e,t){try{return a(e,ne,t)}catch(e){return Ks(e)?e:new ec(e)}}),Yf=da(function(e,t){return s(t,function(t){t=Ya(t),Jn(e,t,tf(e[t],e))}),e}),Kf=Wi(),Xf=Wi(!0),Jf=Zr(function(e,t){return function(n){return Sr(n,e,t)}}),Qf=Zr(function(e,t){return function(n){return Sr(e,n,t)}}),Zf=Xi(h),eh=Xi(l),th=Xi(g),nh=Zi(),rh=Zi(!0),ih=Ki(function(e,t){return e+t},0),ah=na("ceil"),oh=Ki(function(e,t){return e/t},1),sh=na("floor"),uh=Ki(function(e,t){return e*t},1),lh=na("round"),ch=Ki(function(e,t){return e-t},0);return n.after=bs,n.ary=Ts,n.assign=wf,n.assignIn=kf,n.assignInWith=Ef,n.assignWith=Af,n.at=Cf,n.before=Ss,n.bind=tf,n.bindAll=Yf,n.bindKey=nf,n.castArray=Ds,n.chain=Wo,n.chunk=Qa,n.compact=Za,n.concat=eo,n.cond=Sl,n.conforms=wl,n.constant=kl,n.countBy=Wd,n.create=ku,n.curry=ws,n.curryRight=ks,n.debounce=Es,n.defaults=Lf,n.defaultsDeep=xf,n.defer=rf,n.delay=af,n.difference=Ld,n.differenceBy=xd,n.differenceWith=jd,n.drop=to,n.dropRight=no,n.dropRightWhile=ro,n.dropWhile=io,n.fill=ao,n.filter=rs,n.flatMap=is,n.flatMapDeep=as,n.flatMapDepth=os,n.flatten=uo,n.flattenDeep=lo,n.flattenDepth=co,n.flip=As,n.flow=Kf,n.flowRight=Xf,n.fromPairs=fo,n.functions=Ou,n.functionsIn=Iu,n.groupBy=Kd,n.initial=mo,n.intersection=Od,n.intersectionBy=Id,n.intersectionWith=Pd,n.invert=jf,n.invertBy=Of,n.invokeMap=Xd,n.iteratee=Cl,n.keyBy=Jd,n.keys=Mu,n.keysIn=Uu,n.map=cs,n.mapKeys=Bu,n.mapValues=Nu,n.matches=Ll,n.matchesProperty=xl,n.memoize=Cs,n.merge=Pf,n.mergeWith=Rf,n.method=Jf,n.methodOf=Qf,n.mixin=jl,n.negate=Ls,n.nthArg=Pl,n.omit=Df,n.omitBy=Fu,n.once=xs,n.orderBy=ds,n.over=Zf,n.overArgs=of,n.overEvery=eh,n.overSome=th,n.partial=sf,n.partialRight=uf,n.partition=Qd,n.pick=Mf,n.pickBy=Vu,n.property=Rl,n.propertyOf=Dl,n.pull=Rd,n.pullAll=bo,n.pullAllBy=To,n.pullAllWith=So,n.pullAt=Dd,n.range=nh,n.rangeRight=rh,n.rearg=lf,n.reject=ps,n.remove=wo,n.rest=js,n.reverse=ko,n.sampleSize=vs,n.set=Gu,n.setWith=Hu,n.shuffle=gs,n.slice=Eo,n.sortBy=Zd,n.sortedUniq=Io,n.sortedUniqBy=Po,n.split=dl,n.spread=Os,n.tail=Ro,n.take=Do,n.takeRight=Mo,n.takeRightWhile=Uo,n.takeWhile=Bo,n.tap=$o,n.throttle=Is,n.thru=Yo,n.toArray=vu,n.toPairs=Uf,n.toPairsIn=Bf,n.toPath=ql,n.toPlainObject=Tu,n.transform=zu,n.unary=Ps,n.union=Md,n.unionBy=Ud,n.unionWith=Bd,n.uniq=No,n.uniqBy=Fo,n.uniqWith=Vo,n.unset=Wu,n.unzip=qo,n.unzipWith=Go,n.update=$u,n.updateWith=Yu,n.values=Ku,n.valuesIn=Xu,n.without=Nd,n.words=Tl,n.wrap=Rs,n.xor=Fd,n.xorBy=Vd,n.xorWith=qd,n.zip=Gd,n.zipObject=Ho,n.zipObjectDeep=zo,n.zipWith=Hd,n.entries=Uf,n.entriesIn=Bf,n.extend=kf,n.extendWith=Ef,jl(n,n),n.add=ih,n.attempt=$f,n.camelCase=Nf,n.capitalize=el,n.ceil=ah,n.clamp=Ju,n.clone=Ms,n.cloneDeep=Bs,n.cloneDeepWith=Ns,n.cloneWith=Us,n.conformsTo=Fs,n.deburr=tl,n.defaultTo=El,n.divide=oh,n.endsWith=nl,n.eq=Vs,n.escape=rl,n.escapeRegExp=il,n.every=ns,n.find=$d,n.findIndex=oo,n.findKey=Eu,n.findLast=Yd,n.findLastIndex=so,n.findLastKey=Au,n.floor=sh,n.forEach=ss,n.forEachRight=us,n.forIn=Cu,n.forInRight=Lu,n.forOwn=xu,n.forOwnRight=ju,n.get=Pu,n.gt=cf,n.gte=df,n.has=Ru,n.hasIn=Du,n.head=ho,n.identity=Al,n.includes=ls,n.indexOf=po,n.inRange=Qu,n.invoke=If,n.isArguments=ff,n.isArray=hf,n.isArrayBuffer=pf,n.isArrayLike=qs,n.isArrayLikeObject=Gs,n.isBoolean=Hs,n.isBuffer=mf,n.isDate=vf,n.isElement=zs,n.isEmpty=Ws,n.isEqual=$s,n.isEqualWith=Ys,n.isError=Ks,n.isFinite=Xs,n.isFunction=Js,n.isInteger=Qs,n.isLength=Zs,n.isMap=gf,n.isMatch=nu,n.isMatchWith=ru,n.isNaN=iu,n.isNative=au,n.isNil=su,n.isNull=ou,n.isNumber=uu,n.isObject=eu,n.isObjectLike=tu,n.isPlainObject=lu,n.isRegExp=yf,n.isSafeInteger=cu,n.isSet=_f,n.isString=du,n.isSymbol=fu,n.isTypedArray=bf,n.isUndefined=hu,n.isWeakMap=pu,n.isWeakSet=mu,n.join=vo,n.kebabCase=Ff,n.last=go,n.lastIndexOf=yo,n.lowerCase=Vf,n.lowerFirst=qf,n.lt=Tf,n.lte=Sf,n.max=Hl,n.maxBy=zl,n.mean=Wl,n.meanBy=$l,n.min=Yl,n.minBy=Kl,n.stubArray=Ml,n.stubFalse=Ul,n.stubObject=Bl,n.stubString=Nl,n.stubTrue=Fl,n.multiply=uh,n.nth=_o,n.noConflict=Ol,n.noop=Il,n.now=ef,n.pad=al,n.padEnd=ol,n.padStart=sl,n.parseInt=ul,n.random=Zu,n.reduce=fs,n.reduceRight=hs,n.repeat=ll,n.replace=cl,n.result=qu,n.round=lh,n.runInContext=e,n.sample=ms,n.size=ys,n.snakeCase=Gf,n.some=_s,n.sortedIndex=Ao,n.sortedIndexBy=Co,n.sortedIndexOf=Lo,n.sortedLastIndex=xo,n.sortedLastIndexBy=jo,n.sortedLastIndexOf=Oo,n.startCase=Hf,n.startsWith=fl,n.subtract=ch,n.sum=Xl,n.sumBy=Jl,n.template=hl,n.times=Vl,n.toFinite=gu,n.toInteger=yu,n.toLength=_u,n.toLower=pl,n.toNumber=bu,n.toSafeInteger=Su,n.toString=wu,n.toUpper=ml,n.trim=vl,n.trimEnd=gl,n.trimStart=yl,n.truncate=_l,n.unescape=bl,n.uniqueId=Gl,n.upperCase=zf,n.upperFirst=Wf,n.each=ss,n.eachRight=us,n.first=ho,jl(n,function(){var e={};return cr(n,function(t,r){fc.call(n.prototype,r)||(e[r]=t)}),e}(),{chain:!1}),n.VERSION="4.17.11",s(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){n[e].placeholder=n}),s(["drop","take"],function(e,t){y.prototype[e]=function(n){n=n===ne?1:Vc(yu(n),0);var r=this.__filtered__&&!t?new y(this):this.clone();return r.__filtered__?r.__takeCount__=qc(n,r.__takeCount__):r.__views__.push({size:qc(n,Re),type:e+(r.__dir__<0?"Right":"")}),r},y.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}}),s(["filter","map","takeWhile"],function(e,t){var n=t+1,r=n==Le||3==n;y.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:va(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}}),s(["head","last"],function(e,t){var n="take"+(t?"Right":"");y.prototype[e]=function(){return this[n](1).value()[0]}}),s(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");y.prototype[e]=function(){return this.__filtered__?new y(this):this[n](1)}}),y.prototype.compact=function(){return this.filter(Al)},y.prototype.find=function(e){return this.filter(e).head()},y.prototype.findLast=function(e){return this.reverse().find(e)},y.prototype.invokeMap=Zr(function(e,t){return"function"==typeof e?new y(this):this.map(function(n){return Sr(n,e,t)})}),y.prototype.reject=function(e){return this.filter(Ls(va(e)))},y.prototype.slice=function(e,t){e=yu(e);var n=this;return n.__filtered__&&(e>0||t<0)?new y(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==ne&&(t=yu(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},y.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},y.prototype.toArray=function(){return this.take(Re)},cr(y.prototype,function(e,t){var r=/^(?:filter|find|map|reject)|While$/.test(t),a=/^(?:head|last)$/.test(t),o=n[a?"take"+("last"==t?"Right":""):t],s=a||/^find/.test(t);o&&(n.prototype[t]=function(){var t=this.__wrapped__,u=a?[1]:arguments,l=t instanceof y,c=u[0],d=l||hf(t),f=function(e){var t=o.apply(n,p([e],u));return a&&h?t[0]:t};d&&r&&"function"==typeof c&&1!=c.length&&(l=d=!1);var h=this.__chain__,m=!!this.__actions__.length,v=s&&!h,g=l&&!m;if(!s&&d){t=g?t:new y(this);var _=e.apply(t,u);return _.__actions__.push({func:Yo,args:[f],thisArg:ne}),new i(_,h)}return v&&g?e.apply(this,u):(_=this.thru(f),v?a?_.value()[0]:_.value():_)})}),s(["pop","push","shift","sort","splice","unshift"],function(e){var t=sc[e],r=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",i=/^(?:pop|shift)$/.test(e);n.prototype[e]=function(){var e=arguments;if(i&&!this.__chain__){var n=this.value();return t.apply(hf(n)?n:[],e)}return this[r](function(n){return t.apply(hf(n)?n:[],e)})}}),cr(y.prototype,function(e,t){var r=n[t];if(r){var i=r.name+"";(ed[i]||(ed[i]=[])).push({name:t,func:r})}}),ed[$i(ne,me).name]=[{name:"wrapper",func:ne}],y.prototype.clone=C,y.prototype.reverse=K,y.prototype.value=Z,n.prototype.at=zd,n.prototype.chain=Ko,n.prototype.commit=Xo,n.prototype.next=Jo,n.prototype.plant=Zo,n.prototype.reverse=es,n.prototype.toJSON=n.prototype.valueOf=n.prototype.value=ts,n.prototype.first=n.prototype.head,Lc&&(n.prototype[Lc]=Qo),n}();jn._=Wn,(i=function(){return Wn}.call(t,n,t,r))!==ne&&(r.exports=i)}).call(this)}).call(t,n("DuR2"),n("3IRH")(e))},MAG8:function(e,t,n){"use strict";var r=n("eqAp"),i=n("PGRs"),a=function(e){this._t=i(e),this._i=0;var t,n=this._k=[];for(t in e)n.push(t)};n("m1wx")(a,"Object",function(){var e,t=this,n=t._k;do{if(t._i>=n.length)return{value:void 0,done:!0}}while(!((e=n[t._i++])in t._t));return{value:e,done:!1}}),r(r.S,"Reflect",{enumerate:function(e){return new a(e)}})},MTIv:function(e,t,n){function r(e,t){for(var n=0;n<e.length;n++){var r=e[n],i=p[r.id];if(i){i.refs++;for(var a=0;a<i.parts.length;a++)i.parts[a](r.parts[a]);for(;a<r.parts.length;a++)i.parts.push(c(r.parts[a],t))}else{for(var o=[],a=0;a<r.parts.length;a++)o.push(c(r.parts[a],t));p[r.id]={id:r.id,refs:1,parts:o}}}}function i(e,t){for(var n=[],r={},i=0;i<e.length;i++){var a=e[i],o=t.base?a[0]+t.base:a[0],s=a[1],u=a[2],l=a[3],c={css:s,media:u,sourceMap:l};r[o]?r[o].parts.push(c):n.push(r[o]={id:o,parts:[c]})}return n}function a(e,t){var n=v(e.insertInto);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");var r=_[_.length-1];if("top"===e.insertAt)r?r.nextSibling?n.insertBefore(t,r.nextSibling):n.appendChild(t):n.insertBefore(t,n.firstChild),_.push(t);else if("bottom"===e.insertAt)n.appendChild(t);else{if("object"!=typeof e.insertAt||!e.insertAt.before)throw new Error("[Style Loader]\n\n Invalid value for parameter 'insertAt' ('options.insertAt') found.\n Must be 'top', 'bottom', or Object.\n (https://github.com/webpack-contrib/style-loader#insertat)\n");var i=v(e.insertInto+" "+e.insertAt.before);n.insertBefore(t,i)}}function o(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e);var t=_.indexOf(e);t>=0&&_.splice(t,1)}function s(e){var t=document.createElement("style");return e.attrs.type="text/css",l(t,e.attrs),a(e,t),t}function u(e){var t=document.createElement("link");return e.attrs.type="text/css",e.attrs.rel="stylesheet",l(t,e.attrs),a(e,t),t}function l(e,t){Object.keys(t).forEach(function(n){e.setAttribute(n,t[n])})}function c(e,t){var n,r,i,a;if(t.transform&&e.css){if(!(a=t.transform(e.css)))return function(){};e.css=a}if(t.singleton){var l=y++;n=g||(g=s(t)),r=d.bind(null,n,l,!1),i=d.bind(null,n,l,!0)}else e.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=u(t),r=h.bind(null,n,t),i=function(){o(n),n.href&&URL.revokeObjectURL(n.href)}):(n=s(t),r=f.bind(null,n),i=function(){o(n)});return r(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;r(e=t)}else i()}}function d(e,t,n,r){var i=n?"":r.css;if(e.styleSheet)e.styleSheet.cssText=T(t,i);else{var a=document.createTextNode(i),o=e.childNodes;o[t]&&e.removeChild(o[t]),o.length?e.insertBefore(a,o[t]):e.appendChild(a)}}function f(e,t){var n=t.css,r=t.media;if(r&&e.setAttribute("media",r),e.styleSheet)e.styleSheet.cssText=n;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}function h(e,t,n){var r=n.css,i=n.sourceMap,a=void 0===t.convertToAbsoluteUrls&&i;(t.convertToAbsoluteUrls||a)&&(r=b(r)),i&&(r+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */");var o=new Blob([r],{type:"text/css"}),s=e.href;e.href=URL.createObjectURL(o),s&&URL.revokeObjectURL(s)}var p={},m=function(e){var t;return function(){return void 0===t&&(t=e.apply(this,arguments)),t}}(function(){return window&&document&&document.all&&!window.atob}),v=function(e){var t={};return function(n){if(void 0===t[n]){var r=e.call(this,n);if(r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}t[n]=r}return t[n]}}(function(e){return document.querySelector(e)}),g=null,y=0,_=[],b=n("mJPh");e.exports=function(e,t){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");t=t||{},t.attrs="object"==typeof t.attrs?t.attrs:{},t.singleton||(t.singleton=m()),t.insertInto||(t.insertInto="head"),t.insertAt||(t.insertAt="bottom");var n=i(e,t);return r(n,t),function(e){for(var a=[],o=0;o<n.length;o++){var s=n[o],u=p[s.id];u.refs--,a.push(u)}if(e){r(i(e,t),t)}for(var o=0;o<a.length;o++){var u=a[o];if(0===u.refs){for(var l=0;l<u.parts.length;l++)u.parts[l]();delete p[u.id]}}}};var T=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}()},MkYW:function(e,t,n){"use strict";n("48Hh")("strike",function(e){return function(){return e(this,"strike","","")}})},Mlxs:function(e,t,n){n("2+22")("Float32",4,function(e){return function(t,n,r){return e(this,t,n,r)}})},Mw4q:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{clamp:function(e,t,n){return Math.min(n,Math.max(t,e))}})},N2PI:function(e,t,n){var r=n("vR0S"),i=r.navigator;e.exports=i&&i.userAgent||""},N4VP:function(e,t,n){"use strict";var r=n("eqAp"),i=n("J5DO"),a=n("bmV0"),o="".startsWith;r(r.P+r.F*n("rNRh")("startsWith"),"String",{startsWith:function(e){var t=a(this,e,"startsWith"),n=i(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return o?o.call(t,r,n):t.slice(n,n+r.length)===r}})},N8ur:function(e,t,n){"use strict";var r=n("AQEt"),i=RegExp.prototype.exec,a=String.prototype.replace,o=i,s=function(){var e=/a/,t=/b*/g;return i.call(e,"a"),i.call(t,"a"),0!==e.lastIndex||0!==t.lastIndex}(),u=void 0!==/()??/.exec("")[1];(s||u)&&(o=function(e){var t,n,o,l,c=this;return u&&(n=new RegExp("^"+c.source+"$(?!\\s)",r.call(c))),s&&(t=c.lastIndex),o=i.call(c,e),s&&o&&(c.lastIndex=c.global?o.index+o[0].length:t),u&&o&&o.length>1&&a.call(o[0],n,function(){for(l=1;l<arguments.length-2;l++)void 0===arguments[l]&&(o[l]=void 0)}),o}),e.exports=o},NKNJ:function(e,t,n){"use strict";n("8VQU");var r=n("PGRs"),i=n("AQEt"),a=n("8yv5"),o=/./.toString,s=function(e){n("au66")(RegExp.prototype,"toString",e,!0)};n("HTem")(function(){return"/a/b"!=o.call({source:"a",flags:"b"})})?s(function(){var e=r(this);return"/".concat(e.source,"/","flags"in e?e.flags:!a&&e instanceof RegExp?i.call(e):void 0)}):"toString"!=o.name&&s(function(){return o.call(this)})},NQ5z:function(e,t,n){"use strict";var r=n("eqAp"),i=n("VqU3")(!0);r(r.P,"Array",{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n("5BZE")("includes")},NkR5:function(e,t,n){var r=n("PGRs"),i=n("E3Zq"),a=n("iYN6"),o=n("9dbO")("IE_PROTO"),s=function(){},u=function(){var e,t=n("nixg")("iframe"),r=a.length;for(t.style.display="none",n("hrFQ").appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write("<script>document.F=Object<\/script>"),e.close(),u=e.F;r--;)delete u.prototype[a[r]];return u()};e.exports=Object.create||function(e,t){var n;return null!==e?(s.prototype=r(e),n=new s,s.prototype=null,n[o]=e):n=u(),void 0===t?n:i(n,t)}},NmAK:function(e,t,n){var r=n("au66");e.exports=function(e,t,n){for(var i in t)r(e,i,t[i],n);return e}},Nqrn:function(e,t,n){"use strict";var r=n("/TTR"),i=(n.n(r),n("M4fF")),a=n.n(i),o=n("mtWM"),s=n.n(o),u=n("t4zo"),l=n.n(u);videojs.options.controlBar={volumePanel:{inline:!1}},videojs.options.flash.swf="liveplayer.swf",videojs.options.techOrder=["html5","flash"],videojs.browser.IE_VERSION&&videojs.browser.IE_VERSION<11&&(videojs.options.techOrder=["flash","html5"]),videojs.log.level("off"),flvjs.LoggingControl.enableAll=!1,t.a={name:"live-player",data:function(){return{player:null,timer:0,fluentBtnCls:"live-player-fluent-btn",stretchBtnCls:"live-player-stretch-btn",snapFromOutside:!1,snapForPoster:!1,snapForReload:!1,showSlot:!1,fluent_:!0,muted_:!0,stretch_:!1,poster_:"",avLoading:!1,resolutionName:{sd:"标清",hd:"高清",fhd:"超清",yh:"原画"}}},props:{videoUrl:{type:String,default:""},videoTitle:{type:String,default:""},poster:{default:""},autoplay:{type:Boolean,default:!0},live:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},currentTime:{type:Number,default:0},timeout:{type:Number,default:20},alt:{type:String,default:"无信号"},muted:{type:Boolean,default:!0},aspect:{type:String,default:"16:9"},videoBufferSize:{type:Number,default:204800},audioBufferSize:{type:Number,default:131072},pauseWhenHidden:{type:Boolean,default:!0},fluent:{type:Boolean,default:!0},stretch:{type:Boolean,default:!1},loop:{type:Boolean,default:!1},controls:{type:Boolean,default:!0},hideWaiting:{type:Boolean,default:!0},showTime:{type:Boolean,default:function(){return!videojs.browser.IS_IOS&&!videojs.browser.IS_ANDROID}},showCustomButton:{type:Boolean,default:!0},debug:{type:Boolean,default:!1},hasvideo:{type:Boolean,default:void 0},hasaudio:{type:Boolean,default:void 0},resolution:{type:String,default:""},resolutiondefault:{type:String,default:"hd"},reconnect:{type:Boolean,default:!1},playbackRates:{type:Array,default:function(){return videojs.browser.IS_IOS||videojs.browser.IS_ANDROID?[]:[.5,1,2,3]}}},beforeDestroy:function(){this.destroyVideoJS()},deactivated:function(){this.destroyVideoJS()},watch:{videoUrl:function(e){this.reload()},fluent:function(e){this.fluent_=e,this.reload()},muted:function(e){this.muted_=e,this.reload()},stretch:function(e){this.stretch_=e,this.reload()},poster:function(e){this.poster_=e},loop:function(e){this.reload()},currentTime:function(e){this.player&&this.player.currentTime(e)}},mounted:function(){flvjs.reconnect=this.reconnect,this.muted_=this.muted,this.fluent_=this.fluent,this.stretch_=this.stretch,this.poster_=this.poster,this.debug&&(videojs.log.level("info"),flvjs.LoggingControl.enableAll=!0),this.initVideoJS()},computed:{videoType:function(){var e="video/mp4";return this.rtmp?e="rtmp/mp4":(this.http||this.ws)&&this.flv?e="video/x-flv":this.m3u8&&(e="application/x-mpegURL"),e},videoWrapperStyle:function(){if("100%"==this.aspect||"fullscreen"==this.aspect)return{width:"100%",height:"100%"};var e=this.aspect.split(":"),t=parseInt(e[0])||16;return{paddingBottom:(parseInt(e[1])||9)/t*100+"%",position:"relative",margin:"0 auto",overflow:"hidden"}},rtmp:function(){return 0==(this.src||"").indexOf("rtmp")},http:function(){return 0==(this.src||"").indexOf("http")},ws:function(){return 0==(this.src||"").indexOf("ws")},mp4:function(){return/\.mp4.*$/.test(this.src||"")},m3u8:function(){return/\.m3u8.*$/.test(this.src||"")},flv:function(){return/\.flv.*$/.test(this.src||"")},src:function(){return this.videoUrl?0===this.videoUrl.indexOf("/")?location.protocol+"//"+location.host+this.videoUrl:this.videoUrl:""},blankHtml:function(){return this.poster_&&this.videoUrl?'\n <div class="alt">\n <img src="'+this.poster_+'" alt="'+this.alt+'">\n </div>\n ':'\n <div class="alt">\n <table>\n <tr>\n <td>'+this.alt+"</td>\n </tr>\n </table>\n </div>\n "},videoHtml:function(){return this.src?this.rtmp||this.http||this.flv?'\n <video class="video-js vjs-default-skin vjs-big-play-centered" style="width: 100%; height: 100%; '+(this.stretch_?"object-fit: fill;":"")+'"\n webkit-playsinline="" playsinline="" x-webkit-airplay="allow" x5-playsinline=""\n preload="none" poster="'+this.poster_+'" '+(this.muted_?"muted":"")+" "+(this.loop?"loop":"")+'>\n <source src="'+this.src+'" type="'+this.videoType+'"></source>\n <p class="vjs-no-js">\n To view this video please enable JavaScript, and consider upgrading to a web browser that\n <a href="http://videojs.com/html5-video-support/" target="_blank">\n supports HTML5 video\n </a>\n </p>\n </video>\n ':'\n <canvas style="width: 100%; height: 100%;"></canvas>\n ':this.blankHtml}},methods:{isMobile:function(){return videojs.browser.IS_IOS||videojs.browser.IS_ANDROID},hasUsableSWF:function(){return!!(void 0!==window.ActiveXObject?new ActiveXObject("ShockwaveFlash.ShockwaveFlash"):navigator.plugins["Shockwave Flash"])},reload:function(){this.destroyVideoJS(),this.initVideoJS()},loadResolutionlist:function(e){if(""!=this.resolution){for(var t,n=this.resolution.split(","),r=[],i=0;i<n.length;i++)n[i]==this.resolutiondefault&&i,t="yh"==n[i]?this.videoUrl:this.videoUrl.replace(".m3u8","_"+n[i]+".m3u8"),r.push({src:t,type:this.videoType,label:this.resolutionName[n[i]],res:n[i]});e.updateSrc(r),e.on("resolutionchange",function(){console.log("change resolution")})}},getCustomBtn:function(e){var t=this.$el.querySelectorAll(".video-js .vjs-control-bar .vjs-button."+e);return t.length>0?t[0]:null},customFlashButton:function(){var e=this;if(!this.getCustomBtn(this.fluentBtnCls)){var t=this.player.controlBar.addChild("button");t.el_.classList.add(this.fluentBtnCls),t.el_.innerText=this.fluent_?"流畅":"极速",t.el_.title=this.fluent_?"点击切换到极速播放":"点击切换到流畅播放";var n=function(){e.fluent_=!e.fluent_,t.el_.innerText=e.fluent_?"流畅":"极速",t.el_.title=e.fluent_?"点击切换到极速播放":"点击切换到流畅播放",e.player.tech_.setFluent(e.fluent_)};t.on("click",n),t.on("tap",n)}if(!this.getCustomBtn(this.stretchBtnCls)){var r=this.player.controlBar.addChild("button");r.el_.classList.add(this.stretchBtnCls),r.el_.innerText=this.stretch_?"拉伸":"标准",r.el_.title=this.stretch_?"点击切换到标准显示":"点击切换到拉伸显示";var n=function(){e.stretch_=!e.stretch_,r.el_.innerText=e.stretch_?"拉伸":"标准",r.el_.title=e.stretch_?"点击切换到标准显示":"点击切换到拉伸显示",e.player.tech_.setStretch(e.stretch_)};r.on("click",n),r.on("tap",n)}},customH5Button:function(){var e=this;if(!this.getCustomBtn(this.stretchBtnCls)&&!videojs.browser.IE_VERSION){var t=this.player.controlBar.addChild("button");t.el_.classList.add(this.stretchBtnCls),t.el_.innerText=this.stretch_?"拉伸":"标准",t.el_.title=this.stretch_?"点击切换到标准显示":"点击切换到拉伸显示";var n=function(){e.stretch_=!e.stretch_,t.el_.innerText=e.stretch_?"拉伸":"标准",t.el_.title=e.stretch_?"点击切换到标准显示":"点击切换到拉伸显示";var n=e.$el.querySelector("video");n?n.style.objectFit=e.stretch_?"fill":"":e.player.tech_.setStretch(e.stretch_)};t.on("click",n),t.on("tap",n)}},destroyVideoJS:function(){this.showSlot=!1;var e=this.$el.querySelector(".video-js"),t=this.$el.querySelector(".video-wrapper");if(e&&t){var n=e.querySelector(".video-slot");n&&(e.removeChild(n),t.appendChild(n));var r=e.querySelector(".video-title");r&&(e.removeChild(r),t.appendChild(r))}this.player&&this.player.dispose&&(this.player.dispose(),this.player=null),this.player&&this.player.destroy&&(this.player.destroy(),this.player=null),this.timer&&(clearInterval(this.timer),this.timer=0),this.$el.querySelector(".video-inner").innerHTML=this.blankHtml,this.$emit("update:loading",!1)},getCurrentTime:function(){return this.player&&"function"==typeof this.player.currentTime?this.player.currentTime():-1},snap:function(){this.player&&this.player.cameraButton?(this.snapFromOutside=!0,this.player.cameraButton.el().click()):console.log("snap not support")},play:function(){this.player&&this.player.play()},pause:function(){this.player&&this.player.pause()},paused:function(){return!!this.player&&this.player.paused()},setMuted:function(e){this.player&&this.player.muted(!!e)},getMuted:function(){return!!this.player&&this.player.muted()},setVolume:function(e){this.player&&this.player.volume(e)},getVolume:function(){return this.player?this.player.volume():0},isFullscreen:function(){return!!this.player&&this.player.isFullscreen()},requestFullscreen:function(){this.player&&this.player.requestFullscreen()},convertDataURIToBinary:function(e){for(var t=e.indexOf(";base64,")+";base64,".length,n=e.substring(t),r=window.atob(n),i=r.length,a=new Uint8Array(i),o=0;o<i;o++)a[o]=r.charCodeAt(o);return a},convertDataURIToMIME:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=e.indexOf("data:");0==t&&(t+="data:".length);var n=e.indexOf(";base64,");return t>=0&&n>t?e.substring(t,n):""},saveFile:function(e){if(e&&e.length>100){this.poster_=e;var t=this.$el.querySelector("video");t&&t.setAttribute("poster",e)}if(this.snapFromOutside)return this.$emit("snapOutside",e),this.snapFromOutside=!1,this.snapForPoster=!1,void(this.snapForReload=!1);if(this.snapForPoster)return void(this.snapForPoster=!1);if(this.snapForReload)return this.snapForReload=!1,void this.reload();this.$emit("snapInside",e);var n=this.convertDataURIToBinary(e),r=this.convertDataURIToMIME(e),i=".jpg",a=r.indexOf("/");a>0&&(i="."+r.substring(a+1)),l.a.saveAs(new Blob([n],{type:r}),(this.videoTitle||"snap")+i)},debounceInitVideoJS:a.a.debounce(function(){this.initVideoJS()},500),initVideoJSOK:function(){var e=this;this.player&&(this.player.muted(this.muted_),this.player.on("pause",function(){e.$emit("pause",e.player.currentTime())}),this.player.on("snap",function(t,n){e.saveFile(n)}),this.player.on("volumechange",function(t,n){e.muted_=e.player.muted()}));var t=this.$el.querySelector(".video-js"),n=this.$el.querySelector(".video-wrapper");if(t&&n){var r=n.querySelector(".video-slot");r&&(n.removeChild(r),t.appendChild(r));var i=n.querySelector(".video-title");i&&(n.removeChild(i),t.appendChild(i))}this.showSlot=!0},initVideoJS:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if(this.$el.querySelector(".video-inner").innerHTML=this.videoHtml,this.src)if(this.rtmp||videojs.browser.IE_VERSION&&this.http&&this.flv){var n=document.title;this.player=videojs(this.$el.querySelector("video"),{notSupportedMessage:"您的浏览器没有安装或开启Flash",tech:["flash"],autoplay:this.autoplay,stretch:this.stretch,fluent:this.fluent,controls:this.controls}),videojs.browser.IS_SAFARI||this.player.snapshot(),this.player.one("ready",function(){e.initVideoJSOK(),videojs.browser.IE_VERSION&&e.player.tech_.off("fullscreentoggle"),e.$emit("update:loading",!1),document.title=n,e.player.hotkeys({volumeStep:.1,seekStep:5,enableModifiersForNumbers:!1,enableVolumeScroll:!1}),e.player.on("ended",function(){e.$emit("ended")}),e.player.on("error",function(t){e.$emit("error",t)}),e.player.on("timeupdate",function(){e.$emit("timeupdate",e.player.currentTime())}),e.player.on("playing",function(){e.$emit("play",e.player.currentTime())}),e.showCustomButton&&e.customFlashButton();var t=e.$el.querySelectorAll(".video-js .vjs-control-bar .vjs-button"),r=!0,i=!1,a=void 0;try{for(var o,s=t[Symbol.iterator]();!(r=(o=s.next()).done);r=!0){o.value.addEventListener("mouseup",function(){e.player.focus()})}}catch(e){i=!0,a=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw a}}if(!e.hasUsableSWF()){var u=e.$el.querySelector(".vjs-poster");u&&(u.style.display="none")}document.getElementsByClassName("vjs-picture-in-picture-control")[0].style.display="none"}),document.title=n,this.player.on("error",function(t){var t=e.$el.querySelector(".vjs-error .vjs-error-display .vjs-modal-dialog-content");t.innerHTML="<a href='http://www.adobe.com/go/getflashplayer' target='_blank'>"+t.textContent+"</a>"})}else if((this.http||this.ws)&&this.flv){var r={isLive:this.live,cors:!0,withCredentials:!0};void 0!=this.hasaudio&&(r.hasAudio=this.hasaudio),void 0!=this.hasvideo&&(r.hasVideo=this.hasvideo),this.player=videojs(this.$el.querySelector("video"),{techOrder:["flvjs","html5"],controls:this.controls,flvjs:{mediaDataSource:r,config:{enableWorker:!1,enableStashBuffer:!1}}}),videojs.browser.IS_SAFARI||this.player.snapshot(),this.player.one("ready",function(){e.initVideoJSOK(),e.$emit("update:loading",!1),e.stretch_&&(e.player.tech_.el_.style.objectFit="fill"),e.player.hotkeys({volumeStep:.1,seekStep:5,enableModifiersForNumbers:!1,enableVolumeScroll:!1}),e.player.tech_.flvPlayer.on("error",function(t){e.debug&&console.log(t),e.live&&(e.avLoading=!0,!e.snapForReload&&e.player.cameraButton&&(e.snapForReload=!0,e.player.cameraButton.el().click()))}),e.player.one("canplay",function(){e.autoplay&&e.player.tech_.flvPlayer.play().catch(function(){})}),e.player.on("timeupdate",function(){var t=e.player.currentTime();!e.snapForPoster&&!e.poster_&&t>2&&e.player.cameraButton&&(e.snapForPoster=!0,e.player.cameraButton.el().click()),e.$emit("timeupdate",t)}),e.player.on("error",function(t){e.$emit("error",t)}),e.player.on("ended",function(){e.live&&(e.avLoading=!0,!e.snapForReload&&e.player.cameraButton&&(e.snapForReload=!0,e.player.cameraButton.el().click())),e.$emit("ended")}),e.player.on("playing",function(){e.avLoading=!1,e.$emit("play",e.player.currentTime())}),e.showCustomButton&&e.customH5Button();var t=e.$el.querySelectorAll(".video-js .vjs-control-bar .vjs-button"),n=!0,r=!1,i=void 0;try{for(var a,o=t[Symbol.iterator]();!(n=(a=o.next()).done);n=!0){a.value.addEventListener("mouseup",function(){e.player.focus()})}}catch(e){r=!0,i=e}finally{try{!n&&o.return&&o.return()}finally{if(r)throw i}}})}else if(this.http&&this.m3u8){var i=(new Date).getTime();this.$emit("update:loading",!0),this.avLoading=!0;var a=0,o=function(){var n=document.title;e.player||(""!=e.resolution?(-1==e.resolution.indexOf(e.resolutiondefault)&&(e.resolutiondefault="yh"),e.player=videojs(e.$el.querySelector("video"),{autoplay:e.autoplay,stretch:e.stretch,controls:e.controls,plugins:{videoJsResolutionSwitcher:{default:e.resolutiondefault,dynamicLabel:!0}},playbackRates:e.live?[]:e.playbackRates}),e.loadResolutionlist(e.player)):e.player=videojs(e.$el.querySelector("video"),{autoplay:e.autoplay,stretch:e.stretch,controls:e.controls,playbackRates:e.live?[]:e.playbackRates}),videojs.browser.IS_SAFARI||e.player.snapshot(),e.player.one("ready",function(){e.initVideoJSOK(),0==t||e.live||(e.player.currentTime(t),e.player.handleTechSeeked_()),a=setTimeout(function(){e.avLoading=!1,e.$emit("update:loading",!1)},1e3),document.title=n,e.player.hotkeys({volumeStep:.1,seekStep:5,enableModifiersForNumbers:!1,enableVolumeScroll:!1}),e.player.on("ended",function(){e.$emit("ended")}),e.player.on("timeupdate",function(){e.$emit("timeupdate",e.player.currentTime())}),e.player.on("playing",function(){e.$emit("play",e.player.currentTime())}),e.player.on("error",function(n,r){a&&(clearTimeout(a),a=0),e.$emit("error",n),e.live?setTimeout(function(){e.destroyVideoJS(),e.initVideoJS()},1e3):(e.destroyVideoJS(),t+=3,e.initVideoJS(t))}),document.title=n,e.player&&e.player.reloadSourceOnError(),e.player&&e.currentTime>0&&(videojs.browser.IE_VERSION?e.player.on("loadeddata",function(){setTimeout(function(){e.player.currentTime(e.currentTime)},500)}):e.player.currentTime(e.currentTime)),e.autoplay&&setTimeout(function(){var t=e.$el.querySelector(".vjs-big-play-button");if(t){var n=window.getComputedStyle(t);n&&"block"===n.display&&t.click()}},2e3),e.showCustomButton&&e.customH5Button();var r=e.$el.querySelectorAll(".video-js .vjs-control-bar .vjs-button"),i=!0,o=!1,s=void 0;try{for(var u,l=r[Symbol.iterator]();!(i=(u=l.next()).done);i=!0){u.value.addEventListener("mouseup",function(){e.player.focus()})}}catch(e){o=!0,s=e}finally{try{!i&&l.return&&l.return()}finally{if(o)throw s}}}))};this.timer=setInterval(function(){var t=(new Date).getTime();if(e.timeout>0&&t-i>1e3*e.timeout)return clearInterval(e.timer),e.timer=0,e.$emit("update:loading",!1),e.avLoading=!1,void e.$emit("message",{type:"error",message:"加载播放资源失败"});s.a.head(e.src).then(function(t){clearInterval(e.timer),e.timer=0,o()}).catch(function(e){console.log(e)})},1e3)}else this.ws?(this.player=new EPlayer.Player(this.src,{canvas:this.$el.querySelector(".video-inner canvas"),pauseWhenHidden:this.pauseWhenHidden,audio:!this.muted,videoBufferSize:this.videoBufferSize,audioBufferSize:this.audioBufferSize}),this.muted||document.body.addEventListener("touchstart",function(){e.player.audioOut.unlock(function(){console.log("audio unlock")})})):(this.player=videojs(this.$el.querySelector("video"),{autoplay:this.autoplay,stretch:this.stretch,controls:this.controls,playbackRates:this.live?[]:this.playbackRates}),this.player.one("ready",function(){e.initVideoJSOK()}))}}}},NzmX:function(e,t,n){"use strict";var r=n("bPSW"),i={};i[n("6hGG")("toStringTag")]="z",i+""!="[object z]"&&n("au66")(Object.prototype,"toString",function(){return"[object "+r(this)+"]"},!0)},OnBH:function(e,t,n){"use strict";n("XOiX")("trim",function(e){return function(){return e(this,3)}})},PBY2:function(e,t,n){var r=n("B63G"),i=n("AeeY"),a=n("6VhL"),o=n("J5DO");e.exports=function(e,t,n,s,u){r(t);var l=i(e),c=a(l),d=o(l.length),f=u?d-1:0,h=u?-1:1;if(n<2)for(;;){if(f in c){s=c[f],f+=h;break}if(f+=h,u?f<0:d<=f)throw TypeError("Reduce of empty array with no initial value")}for(;u?f>=0:d>f;f+=h)f in c&&(s=t(s,c[f],f,l));return s}},PGRs:function(e,t,n){var r=n("U9LJ");e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},PLrh:function(e,t,n){n("3Qkz"),e.exports=n("QhVj").RegExp.escape},PWt5:function(e,t,n){"use strict";var r=n("NmAK"),i=n("QhHn").getWeak,a=n("PGRs"),o=n("U9LJ"),s=n("S5no"),u=n("VLJK"),l=n("Q2Ff"),c=n("3ty/"),d=n("q90C"),f=l(5),h=l(6),p=0,m=function(e){return e._l||(e._l=new v)},v=function(){this.a=[]},g=function(e,t){return f(e.a,function(e){return e[0]===t})};v.prototype={get:function(e){var t=g(this,e);if(t)return t[1]},has:function(e){return!!g(this,e)},set:function(e,t){var n=g(this,e);n?n[1]=t:this.a.push([e,t])},delete:function(e){var t=h(this.a,function(t){return t[0]===e});return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,n,a){var l=e(function(e,r){s(e,l,t,"_i"),e._t=t,e._i=p++,e._l=void 0,void 0!=r&&u(r,n,e[a],e)});return r(l.prototype,{delete:function(e){if(!o(e))return!1;var n=i(e);return!0===n?m(d(this,t)).delete(e):n&&c(n,this._i)&&delete n[this._i]},has:function(e){if(!o(e))return!1;var n=i(e);return!0===n?m(d(this,t)).has(e):n&&c(n,this._i)}}),l},def:function(e,t,n){var r=i(a(t),!0);return!0===r?m(e).set(t,n):r[e._i]=n,e},ufstore:m}},PXmv:function(e,t,n){"use strict";function r(e,t){return e.__proto__=t,e}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function s(){return Reflect.construct(HTMLElement,[],this.__proto__.constructor)}function u(e){function t(){!0===c.shadow&&HTMLElement.prototype.attachShadow&&this.attachShadow({mode:"open"}),"function"==typeof c.constructorCallback&&c.constructorCallback.call(this)}function n(){"function"==typeof c.connectedCallback&&c.connectedCallback.call(this)}function r(){"function"==typeof c.disconnectedCallback&&c.disconnectedCallback.call(this)}function u(e,t,n){"function"==typeof c.attributeChangedCallback&&c.attributeChangedCallback.call(this,e,t,n)}function l(e,t){var n=customElements.get(e);return void 0!==n?n:customElements.define(e,t)}var c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("undefined"!=typeof customElements){if(w){var d=function(e){function n(e){var r;i(this,n);var o=a(this,(n.__proto__||Object.getPrototypeOf(n)).call(this)),s=e?HTMLElement.call(e):o;return t.call(s),r=s,a(o,r)}return o(n,e),k(n,null,[{key:"observedAttributes",get:function(){return c.observedAttributes||[]}}]),n}(s);return d.prototype.connectedCallback=n,d.prototype.disconnectedCallback=r,d.prototype.attributeChangedCallback=u,l(e,d),d}var f=function(e){var n=e?HTMLElement.call(e):this;return t.call(n),n};return f.observedAttributes=c.observedAttributes||[],f.prototype=Object.create(HTMLElement.prototype,{constructor:{configurable:!0,writable:!0,value:f}}),f.prototype.connectedCallback=n,f.prototype.disconnectedCallback=r,f.prototype.attributeChangedCallback=u,l(e,f),f}}function l(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=e.length-t,r=new Array(n);n--;)r[n]=e[n+t];return r}function c(e,t){var n=e,r=["true","false"].indexOf(e)>-1,i=parseFloat(n,10),a=!isNaN(i)&&isFinite(n)&&"string"==typeof n&&!n.match(/^0+[^.]\d*$/g);return t&&t!==Boolean&&(void 0===n?"undefined":x(n))!==t?n=t(e):r||t===Boolean?n=""===n||"true"===n:a&&(n=i),n}function d(e,t){if(e&&e.length)e.forEach(function(e){var n=A(e);-1===t.camelCase.indexOf(n)&&t.camelCase.push(n)});else if(e&&"object"===(void 0===e?"undefined":x(e)))for(var n in e){var r=A(n);-1===t.camelCase.indexOf(r)&&t.camelCase.push(r),e[r]&&e[r].type&&(t.types[n]=[].concat(e[r].type)[0])}}function f(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={camelCase:[],hyphenate:[],types:{}};if(e.mixins&&e.mixins.forEach(function(e){d(e.props,t)}),e.extends&&e.extends.props){d(e.extends.props,t)}return d(e.props,t),t.camelCase.forEach(function(e){t.hyphenate.push(L(e))}),t}function h(e,t){t.camelCase.forEach(function(n,r){Object.defineProperty(e,n,{get:function(){return this.__vue_custom_element__[n]},set:function(e){if("object"!==(void 0===e?"undefined":x(e))&&"function"!=typeof e||!this.__vue_custom_element__){var n=t.types[t.camelCase[r]];this.setAttribute(t.hyphenate[r],c(e,n))}else{var i=t.camelCase[r];this.__vue_custom_element__[i]=e}}})})}function p(e,t,n){var r=t.propsData||{};return n.hyphenate.forEach(function(t,i){var a=n.camelCase[i],o=e.attributes[t]||e[a],s=null;n.types[a]&&(s=n.types[a]),o instanceof Attr?r[a]=c(o.value,s):void 0!==o&&(r[a]=o)}),r}function m(e){var t={};return l(e.attributes).forEach(function(e){t["vue-slot"===e.nodeName?"slot":e.nodeName]=e.nodeValue}),t}function v(e){if(e.childNodes.length)return e.childNodes;if(e.content&&e.content.childNodes&&e.content.childNodes.length)return e.content.childNodes;var t=document.createElement("div");return t.innerHTML=e.innerHTML,t.childNodes}function g(e,t,n){var r=v(t),i=l(r).map(function(t){return"#text"===t.nodeName?t.nodeValue:e(t.tagName,{attrs:m(t),domProps:{innerHTML:t.innerHTML}})});return n.slot=t.id,e("template",n,i)}function y(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments[1],n=[];return l(e).forEach(function(e){if("#text"===e.nodeName)e.nodeValue.trim()&&n.push(t("span",e.nodeValue));else if("#comment"!==e.nodeName){var r=m(e),i={attrs:r,domProps:{innerHTML:""===e.innerHTML?e.innerText:e.innerHTML}};r.slot&&(i.slot=r.slot,r.slot=void 0);var a="TEMPLATE"===e.tagName?g(t,e,i):t(e.tagName,i);n.push(a)}}),n}function _(e,t){var n={bubbles:!1,cancelable:!1,detail:t},r=void 0;return"function"==typeof window.CustomEvent?r=new CustomEvent(e,n):(r=document.createEvent("CustomEvent"),r.initCustomEvent(e,n.bubbles,n.cancelable,n.detail)),r}function b(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var a=_(t,[].concat(r));e.dispatchEvent(a)}function T(e,t,n,r,i){if(!e.__vue_custom_element__){var a=function(){this.$emit=function(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];b.apply(void 0,[e].concat(r)),this.__proto__&&(t=this.__proto__.$emit).call.apply(t,[this].concat(r))}},o=t.util.extend({},n),s=p(e,o,r),u=t.version&&parseInt(t.version.split(".")[0],10)||0;if(o.beforeCreate=[].concat(o.beforeCreate||[],a),o._compiled){var l={};o._Ctor&&(l=Object.values(o._Ctor)[0].options),l.beforeCreate=o.beforeCreate}var c=void 0;if(u>=2){var d=e.cloneNode(!0).childNodes;c={propsData:s,props:r.camelCase,computed:{reactiveProps:function(){var e=this,t={};return r.camelCase.forEach(function(n){void 0!==e[n]&&(t[n]=e[n])}),t}},render:function(e){var t={props:this.reactiveProps};return e(o,t,y(d,e))}}}else if(1===u)c=o,c.propsData=s;else{c=o;var f={};Object.keys(s).forEach(function(e){f[e]={default:s[e]}}),c.props=f}var m=u>=2?"<div></div>":("<div>"+e.innerHTML+"</div>").replace(/vue-slot=/g,"slot=");if(i.shadow&&e.shadowRoot?(e.shadowRoot.innerHTML=m,c.el=e.shadowRoot.children[0]):(e.innerHTML=m,c.el=e.children[0]),h(e,r),"function"==typeof i.beforeCreateVueInstance&&(c=i.beforeCreateVueInstance(c)||c),e.__vue_custom_element__=new t(c),e.__vue_custom_element_props__=r,e.getVueInstance=function(){return e.__vue_custom_element__.$children[0]},i.shadow&&i.shadowCss&&e.shadowRoot){var v=document.createElement("style");v.type="text/css",v.appendChild(document.createTextNode(i.shadowCss)),e.shadowRoot.appendChild(v)}e.removeAttribute("vce-cloak"),e.setAttribute("vce-ready",""),b(e,"vce-ready")}}function S(e){e.customElement=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i="function"==typeof n,a=i&&{props:r.props||[]},o=f(i?a:n);return u(t,{constructorCallback:function(){"function"==typeof r.constructorCallback&&r.constructorCallback.call(this)},connectedCallback:function(){var a=this,s=i&&n(),u=s&&s.then&&"function"==typeof s.then;if("function"==typeof r.connectedCallback&&r.connectedCallback.call(this),i&&!u)throw new Error("Async component "+t+" do not returns Promise");this.__detached__||(u?s.then(function(t){var n=f(t);T(a,e,t,n,r),"function"==typeof r.vueInstanceCreatedCallback&&r.vueInstanceCreatedCallback.call(a)}):(T(this,e,n,o,r),"function"==typeof r.vueInstanceCreatedCallback&&r.vueInstanceCreatedCallback.call(this))),this.__detached__=!1},disconnectedCallback:function(){var e=this;this.__detached__=!0,"function"==typeof r.disconnectedCallback&&r.disconnectedCallback.call(this),null!==r.destroyTimeout&&setTimeout(function(){e.__detached__&&e.__vue_custom_element__&&(e.__vue_custom_element__.$destroy(!0),delete e.__vue_custom_element__,delete e.__vue_custom_element_props__)},r.destroyTimeout||3e3)},attributeChangedCallback:function(e,t,n){if(this.__vue_custom_element__&&void 0!==n){var i=A(e);"function"==typeof r.attributeChangedCallback&&r.attributeChangedCallback.call(this,e,t,n);var a=this.__vue_custom_element_props__.types[i];this.__vue_custom_element__[i]=c(n,a)}},observedAttributes:o.hyphenate,shadow:!!r.shadow&&!!HTMLElement.prototype.attachShadow})}}Object.setPrototypeOf=Object.setPrototypeOf||r;var w=(r.bind(Object),function(){return"undefined"!=typeof Symbol&&"undefined"!=typeof Reflect&&"undefined"!=typeof Proxy&&!Object.isSealed(Proxy)}()),k=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();Object.setPrototypeOf(s.prototype,HTMLElement.prototype),Object.setPrototypeOf(s,HTMLElement);var E=/-(\w)/g,A=function(e){return e.replace(E,function(e,t){return t?t.toUpperCase():""})},C=/([^-])([A-Z])/g,L=function(e){return e.replace(C,"$1-$2").replace(C,"$1-$2").toLowerCase()},x="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};"undefined"!=typeof window&&window.Vue&&(window.Vue.use(S),S.installed&&(S.installed=!1)),t.a=S},PaZz:function(e,t,n){"use strict";var r=n("eqAp"),i=n("vR0S"),a=n("QhVj"),o=n("E3yU")(),s=n("6hGG")("observable"),u=n("B63G"),l=n("PGRs"),c=n("S5no"),d=n("NmAK"),f=n("CfIS"),h=n("VLJK"),p=h.RETURN,m=function(e){return null==e?void 0:u(e)},v=function(e){var t=e._c;t&&(e._c=void 0,t())},g=function(e){return void 0===e._o},y=function(e){g(e)||(e._o=void 0,v(e))},_=function(e,t){l(e),this._c=void 0,this._o=e,e=new b(this);try{var n=t(e),r=n;null!=n&&("function"==typeof n.unsubscribe?n=function(){r.unsubscribe()}:u(n),this._c=n)}catch(t){return void e.error(t)}g(this)&&v(this)};_.prototype=d({},{unsubscribe:function(){y(this)}});var b=function(e){this._s=e};b.prototype=d({},{next:function(e){var t=this._s;if(!g(t)){var n=t._o;try{var r=m(n.next);if(r)return r.call(n,e)}catch(e){try{y(t)}finally{throw e}}}},error:function(e){var t=this._s;if(g(t))throw e;var n=t._o;t._o=void 0;try{var r=m(n.error);if(!r)throw e;e=r.call(n,e)}catch(e){try{v(t)}finally{throw e}}return v(t),e},complete:function(e){var t=this._s;if(!g(t)){var n=t._o;t._o=void 0;try{var r=m(n.complete);e=r?r.call(n,e):void 0}catch(e){try{v(t)}finally{throw e}}return v(t),e}}});var T=function(e){c(this,T,"Observable","_f")._f=u(e)};d(T.prototype,{subscribe:function(e){return new _(e,this._f)},forEach:function(e){var t=this;return new(a.Promise||i.Promise)(function(n,r){u(e);var i=t.subscribe({next:function(t){try{return e(t)}catch(e){r(e),i.unsubscribe()}},error:r,complete:n})})}}),d(T,{from:function(e){var t="function"==typeof this?this:T,n=m(l(e)[s]);if(n){var r=l(n.call(e));return r.constructor===t?r:new t(function(e){return r.subscribe(e)})}return new t(function(t){var n=!1;return o(function(){if(!n){try{if(h(e,!1,function(e){if(t.next(e),n)return p})===p)return}catch(e){if(n)throw e;return void t.error(e)}t.complete()}}),function(){n=!0}})},of:function(){for(var e=0,t=arguments.length,n=new Array(t);e<t;)n[e]=arguments[e++];return new("function"==typeof this?this:T)(function(e){var t=!1;return o(function(){if(!t){for(var r=0;r<n.length;++r)if(e.next(n[r]),t)return;e.complete()}}),function(){t=!0}})}}),f(T.prototype,s,function(){return this}),r(r.G,{Observable:T}),n("7QiM")("Observable")},PbK0:function(e,t){e.exports=Math.scale||function(e,t,n,r,i){return 0===arguments.length||e!=e||t!=t||n!=n||r!=r||i!=i?NaN:e===1/0||e===-1/0?e:(e-t)*(i-r)/(n-t)+r}},PcBk:function(e,t,n){"use strict";var r=n("HTem"),i=Date.prototype.getTime,a=Date.prototype.toISOString,o=function(e){return e>9?e:"0"+e};e.exports=r(function(){return"0385-07-25T07:06:39.999Z"!=a.call(new Date(-5e13-1))})||!r(function(){a.call(new Date(NaN))})?function(){if(!isFinite(i.call(this)))throw RangeError("Invalid time value");var e=this,t=e.getUTCFullYear(),n=e.getUTCMilliseconds(),r=t<0?"-":t>9999?"+":"";return r+("00000"+Math.abs(t)).slice(r?-6:-4)+"-"+o(e.getUTCMonth()+1)+"-"+o(e.getUTCDate())+"T"+o(e.getUTCHours())+":"+o(e.getUTCMinutes())+":"+o(e.getUTCSeconds())+"."+(n>99?n:"0"+o(n))+"Z"}:a},Q2Ff:function(e,t,n){var r=n("wRig"),i=n("6VhL"),a=n("AeeY"),o=n("J5DO"),s=n("9nZh");e.exports=function(e,t){var n=1==e,u=2==e,l=3==e,c=4==e,d=6==e,f=5==e||d,h=t||s;return function(t,s,p){for(var m,v,g=a(t),y=i(g),_=r(s,p,3),b=o(y.length),T=0,S=n?h(t,b):u?h(t,0):void 0;b>T;T++)if((f||T in y)&&(m=y[T],v=_(m,T,g),e))if(n)S[T]=v;else if(v)switch(e){case 3:return!0;case 5:return m;case 6:return T;case 2:S.push(m)}else if(c)return!1;return d?-1:l||c?c:S}}},Q2xf:function(e,t,n){var r=n("eqAp"),i=n("xpmJ"),a=n("J5DO");r(r.S,"String",{raw:function(e){for(var t=i(e.raw),n=a(t.length),r=arguments.length,o=[],s=0;n>s;)o.push(String(t[s++])),s<r&&o.push(String(arguments[s]));return o.join("")}})},"QFL/":function(e,t,n){var r=n("AeeY"),i=n("spe/");n("Iiwq")("getPrototypeOf",function(){return function(e){return i(r(e))}})},QRrs:function(e,t,n){var r=n("eqAp");r(r.G+r.W+r.F*!n("Au7w").ABV,{DataView:n("Ee0C").DataView})},QU4K:function(e,t,n){var r=n("eqAp");r(r.S,"Number",{EPSILON:Math.pow(2,-52)})},"QV+U":function(e,t,n){"use strict";var r=n("RVW2"),i=n("PGRs"),a=n("8rdt"),o=n("jLAN"),s=n("J5DO"),u=n("Zn18"),l=n("N8ur"),c=n("HTem"),d=Math.min,f=[].push,h="length",p=!c(function(){RegExp(4294967295,"y")});n("UIZt")("split",2,function(e,t,n,c){var m;return m="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1)[h]||2!="ab".split(/(?:ab)*/)[h]||4!=".".split(/(.?)(.?)/)[h]||".".split(/()()/)[h]>1||"".split(/.?/)[h]?function(e,t){var i=String(this);if(void 0===e&&0===t)return[];if(!r(e))return n.call(i,e,t);for(var a,o,s,u=[],c=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),d=0,p=void 0===t?4294967295:t>>>0,m=new RegExp(e.source,c+"g");(a=l.call(m,i))&&!((o=m.lastIndex)>d&&(u.push(i.slice(d,a.index)),a[h]>1&&a.index<i[h]&&f.apply(u,a.slice(1)),s=a[0][h],d=o,u[h]>=p));)m.lastIndex===a.index&&m.lastIndex++;return d===i[h]?!s&&m.test("")||u.push(""):u.push(i.slice(d)),u[h]>p?u.slice(0,p):u}:"0".split(void 0,0)[h]?function(e,t){return void 0===e&&0===t?[]:n.call(this,e,t)}:n,[function(n,r){var i=e(this),a=void 0==n?void 0:n[t];return void 0!==a?a.call(n,i,r):m.call(String(i),n,r)},function(e,t){var r=c(m,e,this,t,m!==n);if(r.done)return r.value;var l=i(e),f=String(this),h=a(l,RegExp),v=l.unicode,g=(l.ignoreCase?"i":"")+(l.multiline?"m":"")+(l.unicode?"u":"")+(p?"y":"g"),y=new h(p?l:"^(?:"+l.source+")",g),_=void 0===t?4294967295:t>>>0;if(0===_)return[];if(0===f.length)return null===u(y,f)?[f]:[];for(var b=0,T=0,S=[];T<f.length;){y.lastIndex=p?T:0;var w,k=u(y,p?f:f.slice(T));if(null===k||(w=d(s(y.lastIndex+(p?0:T)),f.length))===b)T=o(f,T,v);else{if(S.push(f.slice(b,T)),S.length===_)return S;for(var E=1;E<=k.length-1;E++)if(S.push(k[E]),S.length===_)return S;T=b=w}}return S.push(f.slice(b)),S}]})},Qagw:function(e,t,n){var r=n("eqAp");r(r.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},QhHn:function(e,t,n){var r=n("guD1")("meta"),i=n("U9LJ"),a=n("3ty/"),o=n("rBVO").f,s=0,u=Object.isExtensible||function(){return!0},l=!n("HTem")(function(){return u(Object.preventExtensions({}))}),c=function(e){o(e,r,{value:{i:"O"+ ++s,w:{}}})},d=function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!a(e,r)){if(!u(e))return"F";if(!t)return"E";c(e)}return e[r].i},f=function(e,t){if(!a(e,r)){if(!u(e))return!0;if(!t)return!1;c(e)}return e[r].w},h=function(e){return l&&p.NEED&&u(e)&&!a(e,r)&&c(e),e},p=e.exports={KEY:r,NEED:!1,fastKey:d,getWeak:f,onFreeze:h}},QhVj:function(e,t){var n=e.exports={version:"2.6.5"};"number"==typeof __e&&(__e=n)},QzD4:function(e,t,n){"use strict";var r=n("eqAp"),i=n("hrFQ"),a=n("1vD2"),o=n("IfkE"),s=n("J5DO"),u=[].slice;r(r.P+r.F*n("HTem")(function(){i&&u.call(i)}),"Array",{slice:function(e,t){var n=s(this.length),r=a(this);if(t=void 0===t?n:t,"Array"==r)return u.call(this,e,t);for(var i=o(e,n),l=o(t,n),c=s(l-i),d=new Array(c),f=0;f<c;f++)d[f]="String"==r?this.charAt(i+f):this[i+f];return d}})},QzFE:function(e,t,n){"use strict";var r=n("eqAp"),i=n("AeeY"),a=n("E2U5"),o=n("spe/"),s=n("gWbE").f;n("8yv5")&&r(r.P+n("danu"),"Object",{__lookupGetter__:function(e){var t,n=i(this),r=a(e,!0);do{if(t=s(n,r))return t.get}while(n=o(n))}})},R2Uq:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=r.get,o=r.key;r.exp({getOwnMetadata:function(e,t){return a(e,i(t),arguments.length<3?void 0:o(arguments[2]))}})},RVW2:function(e,t,n){var r=n("U9LJ"),i=n("1vD2"),a=n("6hGG")("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[a])?!!t:"RegExp"==i(e))}},RXyq:function(e,t,n){var r=n("vR0S").parseFloat,i=n("XOiX").trim;e.exports=1/r(n("tBsZ")+"-0")!=-1/0?function(e){var t=i(String(e),3),n=r(t);return 0===n&&"-"==t.charAt(0)?-0:n}:r},"RqJ/":function(e,t,n){var r=n("eqAp");r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},RvsJ:function(e,t,n){"use strict";var r=n("rBVO"),i=n("D8PY");e.exports=function(e,t,n){t in e?r.f(e,t,i(0,n)):e[t]=n}},S5no:function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},Sl8e:function(e,t,n){var r=n("eqAp");r(r.S+r.F,"Object",{assign:n("i5O8")})},T8YM:function(e,t,n){"use strict";var r=n("AeeY"),i=n("IfkE"),a=n("J5DO");e.exports=function(e){for(var t=r(this),n=a(t.length),o=arguments.length,s=i(o>1?arguments[1]:void 0,n),u=o>2?arguments[2]:void 0,l=void 0===u?n:i(u,n);l>s;)t[s++]=e;return t}},T9ir:function(e,t){var n=Math.expm1;e.exports=!n||n(10)>22025.465794806718||n(10)<22025.465794806718||-2e-17!=n(-2e-17)?function(e){return 0==(e=+e)?e:e>-1e-6&&e<1e-6?e+e*e/2:Math.exp(e)-1}:n},TLNA:function(e,t,n){function r(e,t){var n,s,c=arguments.length<3?e:arguments[2];return l(e)===c?e[t]:(n=i.f(e,t))?o(n,"value")?n.value:void 0!==n.get?n.get.call(c):void 0:u(s=a(e))?r(s,t,c):void 0}var i=n("gWbE"),a=n("spe/"),o=n("3ty/"),s=n("eqAp"),u=n("U9LJ"),l=n("PGRs");s(s.S,"Reflect",{get:r})},TMyd:function(e,t,n){var r=n("1vD2");e.exports=function(e,t){if("number"!=typeof e&&"Number"!=r(e))throw TypeError(t);return+e}},TNV1:function(e,t,n){"use strict";var r=n("cGG2");e.exports=function(e,t,n){return r.forEach(n,function(n){e=n(e,t)}),e}},TU7o:function(e,t,n){"use strict";n("48Hh")("blink",function(e){return function(){return e(this,"blink","","")}})},Ta4Y:function(e,t,n){"use strict";var r=n("U9LJ"),i=n("spe/"),a=n("6hGG")("hasInstance"),o=Function.prototype;a in o||n("rBVO").f(o,a,{value:function(e){if("function"!=typeof this||!r(e))return!1;if(!r(this.prototype))return e instanceof this;for(;e=i(e);)if(this.prototype===e)return!0;return!1}})},TaU0:function(e,t,n){"use strict";var r=n("eqAp"),i=n("xpmJ"),a=[].join;r(r.P+r.F*(n("6VhL")!=Object||!n("+qBm")(a)),"Array",{join:function(e){return a.call(i(this),void 0===e?",":e)}})},TsdC:function(e,t,n){var r=Date.prototype,i=r.toString,a=r.getTime;new Date(NaN)+""!="Invalid Date"&&n("au66")(r,"toString",function(){var e=a.call(this);return e===e?i.call(this):"Invalid Date"})},U9LJ:function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},UIZt:function(e,t,n){"use strict";n("Y94b");var r=n("au66"),i=n("CfIS"),a=n("HTem"),o=n("VmoO"),s=n("6hGG"),u=n("N8ur"),l=s("species"),c=!a(function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}),d=function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2===n.length&&"a"===n[0]&&"b"===n[1]}();e.exports=function(e,t,n){var f=s(e),h=!a(function(){var t={};return t[f]=function(){return 7},7!=""[e](t)}),p=h?!a(function(){var t=!1,n=/a/;return n.exec=function(){return t=!0,null},"split"===e&&(n.constructor={},n.constructor[l]=function(){return n}),n[f](""),!t}):void 0;if(!h||!p||"replace"===e&&!c||"split"===e&&!d){var m=/./[f],v=n(o,f,""[e],function(e,t,n,r,i){return t.exec===u?h&&!i?{done:!0,value:m.call(t,n,r)}:{done:!0,value:e.call(n,t,r)}:{done:!1}}),g=v[0],y=v[1];r(String.prototype,e,g),i(RegExp.prototype,f,2==t?function(e,t){return y.call(e,this,t)}:function(e){return y.call(e,this)})}}},Uk5j:function(e,t,n){"use strict";n("48Hh")("anchor",function(e){return function(t){return e(this,"a","name",t)}})},Uz1t:function(e,t,n){var r=n("eqAp"),i=n("2zMK");r(r.G+r.F*(parseInt!=i),{parseInt:i})},V8Cm:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{fround:n("Wx9E")})},VEfk:function(e,t,n){var r=n("eqAp");r(r.S,"Number",{isNaN:function(e){return e!=e}})},VLJK:function(e,t,n){var r=n("wRig"),i=n("dkfP"),a=n("e1Y9"),o=n("PGRs"),s=n("J5DO"),u=n("JuSo"),l={},c={},t=e.exports=function(e,t,n,d,f){var h,p,m,v,g=f?function(){return e}:u(e),y=r(n,d,t?2:1),_=0;if("function"!=typeof g)throw TypeError(e+" is not iterable!");if(a(g)){for(h=s(e.length);h>_;_++)if((v=t?y(o(p=e[_])[0],p[1]):y(e[_]))===l||v===c)return v}else for(m=g.call(e);!(p=m.next()).done;)if((v=i(m,y,p.value,t))===l||v===c)return v};t.BREAK=l,t.RETURN=c},"VU/8":function(e,t){e.exports=function(e,t,n,r,i,a){var o,s=e=e||{},u=typeof e.default;"object"!==u&&"function"!==u||(o=e,s=e.default);var l="function"==typeof s?s.options:s;t&&(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0),n&&(l.functional=!0),i&&(l._scopeId=i);var c;if(a?(c=function(e){e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,e||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),r&&r.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},l._ssrRegister=c):r&&(c=r),c){var d=l.functional,f=d?l.render:l.beforeCreate;d?(l._injectStyles=c,l.render=function(e,t){return c.call(t),f(e,t)}):l.beforeCreate=f?[].concat(f,c):[c]}return{esModule:o,exports:s,options:l}}},Vdun:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{RAD_PER_DEG:180/Math.PI})},Vk48:function(e,t,n){var r=n("eqAp"),i=n("vR0S").isFinite;r(r.S,"Number",{isFinite:function(e){return"number"==typeof e&&i(e)}})},VlEH:function(e,t,n){"use strict";var r=n("eqAp"),i=n("BHN6"),a=n("AeeY"),o=n("J5DO"),s=n("sxvG"),u=n("9nZh");r(r.P,"Array",{flatten:function(){var e=arguments[0],t=a(this),n=o(t.length),r=u(t,0);return i(r,t,t,n,0,void 0===e?1:s(e)),r}}),n("5BZE")("flatten")},Vm8t:function(e,t,n){var r=n("vR0S"),i=n("eqAp"),a=n("N2PI"),o=[].slice,s=/MSIE .\./.test(a),u=function(e){return function(t,n){var r=arguments.length>2,i=!!r&&o.call(arguments,2);return e(r?function(){("function"==typeof t?t:Function(t)).apply(this,i)}:t,n)}};i(i.G+i.B+i.F*s,{setTimeout:u(r.setTimeout),setInterval:u(r.setInterval)})},VmoO:function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},VpOn:function(e,t,n){var r=n("YGNL"),i=n("eqAp"),a=n("94Rb")("metadata"),o=a.store||(a.store=new(n("L1YH"))),s=function(e,t,n){var i=o.get(e);if(!i){if(!n)return;o.set(e,i=new r)}var a=i.get(t);if(!a){if(!n)return;i.set(t,a=new r)}return a},u=function(e,t,n){var r=s(t,n,!1);return void 0!==r&&r.has(e)},l=function(e,t,n){var r=s(t,n,!1);return void 0===r?void 0:r.get(e)},c=function(e,t,n,r){s(n,r,!0).set(e,t)},d=function(e,t){var n=s(e,t,!1),r=[];return n&&n.forEach(function(e,t){r.push(t)}),r},f=function(e){return void 0===e||"symbol"==typeof e?e:String(e)},h=function(e){i(i.S,"Reflect",e)};e.exports={store:o,map:s,has:u,get:l,set:c,keys:d,key:f,exp:h}},VqU3:function(e,t,n){var r=n("xpmJ"),i=n("J5DO"),a=n("IfkE");e.exports=function(e){return function(t,n,o){var s,u=r(t),l=i(u.length),c=a(o,l);if(e&&n!=n){for(;l>c;)if((s=u[c++])!=s)return!0}else for(;l>c;c++)if((e||c in u)&&u[c]===n)return e||c||0;return!e&&-1}}},W2nU:function(e,t){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function i(e){if(c===setTimeout)return setTimeout(e,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(e,0);try{return c(e,0)}catch(t){try{return c.call(null,e,0)}catch(t){return c.call(this,e,0)}}}function a(e){if(d===clearTimeout)return clearTimeout(e);if((d===r||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(e);try{return d(e)}catch(t){try{return d.call(null,e)}catch(t){return d.call(this,e)}}}function o(){m&&h&&(m=!1,h.length?p=h.concat(p):v=-1,p.length&&s())}function s(){if(!m){var e=i(o);m=!0;for(var t=p.length;t;){for(h=p,p=[];++v<t;)h&&h[v].run();v=-1,t=p.length}h=null,m=!1,a(e)}}function u(e,t){this.fun=e,this.array=t}function l(){}var c,d,f=e.exports={};!function(){try{c="function"==typeof setTimeout?setTimeout:n}catch(e){c=n}try{d="function"==typeof clearTimeout?clearTimeout:r}catch(e){d=r}}();var h,p=[],m=!1,v=-1;f.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];p.push(new u(e,t)),1!==p.length||m||i(s)},u.prototype.run=function(){this.fun.apply(null,this.array)},f.title="browser",f.browser=!0,f.env={},f.argv=[],f.version="",f.versions={},f.on=l,f.addListener=l,f.once=l,f.off=l,f.removeListener=l,f.removeAllListeners=l,f.emit=l,f.prependListener=l,f.prependOnceListener=l,f.listeners=function(e){return[]},f.binding=function(e){throw new Error("process.binding is not supported")},f.cwd=function(){return"/"},f.chdir=function(e){throw new Error("process.chdir is not supported")},f.umask=function(){return 0}},W8W2:function(e,t,n){"use strict";var r=n("hSxG"),i=n("q90C");e.exports=n("LFIv")("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(i(this,"Set"),e=0===e?0:e,e)}},r)},W97E:function(e,t,n){var r=n("rBVO").f,i=n("3ty/"),a=n("6hGG")("toStringTag");e.exports=function(e,t,n){e&&!i(e=n?e:e.prototype,a)&&r(e,a,{configurable:!0,value:t})}},Wfy6:function(e,t,n){var r=n("eqAp");r(r.S,"Reflect",{ownKeys:n("qvDY")})},Whqc:function(e,t,n){"use strict";var r=n("eqAp"),i=n("sxvG"),a=n("TMyd"),o=n("sbdb"),s=1..toFixed,u=Math.floor,l=[0,0,0,0,0,0],c="Number.toFixed: incorrect invocation!",d=function(e,t){for(var n=-1,r=t;++n<6;)r+=e*l[n],l[n]=r%1e7,r=u(r/1e7)},f=function(e){for(var t=6,n=0;--t>=0;)n+=l[t],l[t]=u(n/e),n=n%e*1e7},h=function(){for(var e=6,t="";--e>=0;)if(""!==t||0===e||0!==l[e]){var n=String(l[e]);t=""===t?n:t+o.call("0",7-n.length)+n}return t},p=function(e,t,n){return 0===t?n:t%2==1?p(e,t-1,n*e):p(e*e,t/2,n)},m=function(e){for(var t=0,n=e;n>=4096;)t+=12,n/=4096;for(;n>=2;)t+=1,n/=2;return t};r(r.P+r.F*(!!s&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!n("HTem")(function(){s.call({})})),"Number",{toFixed:function(e){var t,n,r,s,u=a(this,c),l=i(e),v="",g="0";if(l<0||l>20)throw RangeError(c);if(u!=u)return"NaN";if(u<=-1e21||u>=1e21)return String(u);if(u<0&&(v="-",u=-u),u>1e-21)if(t=m(u*p(2,69,1))-69,n=t<0?u*p(2,-t,1):u/p(2,t,1),n*=4503599627370496,(t=52-t)>0){for(d(0,n),r=l;r>=7;)d(1e7,0),r-=7;for(d(p(10,r,1),0),r=t-1;r>=23;)f(1<<23),r-=23;f(1<<r),d(1,1),f(2),g=h()}else d(0,n),d(1<<-t,0),g=h()+o.call("0",l);return l>0?(s=g.length,g=v+(s<=l?"0."+o.call("0",l-s)+g:g.slice(0,s-l)+"."+g.slice(s-l))):g=v+g,g}})},WsP5:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=n("spe/"),o=r.has,s=r.key,u=function(e,t,n){if(o(e,t,n))return!0;var r=a(t);return null!==r&&u(e,r,n)};r.exp({hasMetadata:function(e,t){return u(e,i(t),arguments.length<3?void 0:s(arguments[2]))}})},Wx9E:function(e,t,n){var r=n("iIAy"),i=Math.pow,a=i(2,-52),o=i(2,-23),s=i(2,127)*(2-o),u=i(2,-126),l=function(e){return e+1/a-1/a};e.exports=Math.fround||function(e){var t,n,i=Math.abs(e),c=r(e);return i<u?c*l(i/u/o)*u*o:(t=(1+o/a)*i,n=t-(t-i),n>s||n!=n?c*(1/0):c*n)}},X0LW:function(e,t,n){"use strict";var r=n("eqAp"),i=n("J5DO"),a=n("bmV0"),o="".endsWith;r(r.P+r.F*n("rNRh")("endsWith"),"String",{endsWith:function(e){var t=a(this,e,"endsWith"),n=arguments.length>1?arguments[1]:void 0,r=i(t.length),s=void 0===n?r:Math.min(i(n),r),u=String(e);return o?o.call(t,u,s):t.slice(s-u.length,s)===u}})},X1d6:function(e,t,n){var r=n("eqAp");r(r.S,"Object",{create:n("NkR5")})},X8tW:function(e,t,n){var r=n("eqAp"),i=Math.abs;r(r.S,"Math",{hypot:function(e,t){for(var n,r,a=0,o=0,s=arguments.length,u=0;o<s;)n=i(arguments[o++]),u<n?(r=u/n,a=a*r*r+1,u=n):n>0?(r=n/u,a+=r*r):a+=n;return u===1/0?1/0:u*Math.sqrt(a)}})},XJA6:function(e,t,n){var r,i,a,o=n("wRig"),s=n("ujn+"),u=n("hrFQ"),l=n("nixg"),c=n("vR0S"),d=c.process,f=c.setImmediate,h=c.clearImmediate,p=c.MessageChannel,m=c.Dispatch,v=0,g={},y=function(){var e=+this;if(g.hasOwnProperty(e)){var t=g[e];delete g[e],t()}},_=function(e){y.call(e.data)};f&&h||(f=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return g[++v]=function(){s("function"==typeof e?e:Function(e),t)},r(v),v},h=function(e){delete g[e]},"process"==n("1vD2")(d)?r=function(e){d.nextTick(o(y,e,1))}:m&&m.now?r=function(e){m.now(o(y,e,1))}:p?(i=new p,a=i.port2,i.port1.onmessage=_,r=o(a.postMessage,a,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(r=function(e){c.postMessage(e+"","*")},c.addEventListener("message",_,!1)):r="onreadystatechange"in l("script")?function(e){u.appendChild(l("script")).onreadystatechange=function(){u.removeChild(this),y.call(e)}}:function(e){setTimeout(o(y,e,1),0)}),e.exports={set:f,clear:h}},XOiX:function(e,t,n){var r=n("eqAp"),i=n("VmoO"),a=n("HTem"),o=n("tBsZ"),s="["+o+"]",u="​…",l=RegExp("^"+s+s+"*"),c=RegExp(s+s+"*$"),d=function(e,t,n){var i={},s=a(function(){return!!o[e]()||u[e]()!=u}),l=i[e]=s?t(f):o[e];n&&(i[n]=l),r(r.P+r.F*s,"String",i)},f=d.trim=function(e,t){return e=String(i(e)),1&t&&(e=e.replace(l,"")),2&t&&(e=e.replace(c,"")),e};e.exports=d},XWLd:function(e,t,n){var r=n("eqAp");r(r.S,"System",{global:n("vR0S")})},Xd2u:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=r.has,o=r.key;r.exp({hasOwnMetadata:function(e,t){return a(e,i(t),arguments.length<3?void 0:o(arguments[2]))}})},"XjC+":function(e,t,n){var r=n("AIRG"),i=n("iYN6").concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},XmWM:function(e,t,n){"use strict";function r(e){this.defaults=e,this.interceptors={request:new o,response:new o}}var i=n("KCLY"),a=n("cGG2"),o=n("fuGk"),s=n("xLtR");r.prototype.request=function(e){"string"==typeof e&&(e=a.merge({url:arguments[0]},arguments[1])),e=a.merge(i,this.defaults,{method:"get"},e),e.method=e.method.toLowerCase();var t=[s,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n},a.forEach(["delete","get","head","options"],function(e){r.prototype[e]=function(t,n){return this.request(a.merge(n||{},{method:e,url:t}))}}),a.forEach(["post","put","patch"],function(e){r.prototype[e]=function(t,n,r){return this.request(a.merge(r||{},{method:e,url:t,data:n}))}}),e.exports=r},Xqrs:function(e,t,n){var r=n("U9LJ");n("Iiwq")("isFrozen",function(e){return function(t){return!r(t)||!!e&&e(t)}})},"Y+OG":function(e,t,n){"use strict";n("48Hh")("fixed",function(e){return function(){return e(this,"tt","","")}})},Y94b:function(e,t,n){"use strict";var r=n("N8ur");n("eqAp")({target:"RegExp",proto:!0,forced:r!==/./.exec},{exec:r})},YGNL:function(e,t,n){"use strict";var r=n("hSxG"),i=n("q90C");e.exports=n("LFIv")("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(i(this,"Map"),e);return t&&t.v},set:function(e,t){return r.def(i(this,"Map"),0===e?0:e,t)}},r,!0)},YHsq:function(e,t,n){"use strict";n("48Hh")("small",function(e){return function(){return e(this,"small","","")}})},YQk9:function(e,t,n){"use strict";var r=n("eqAp");e.exports=function(e){r(r.S,e,{of:function(){for(var e=arguments.length,t=new Array(e);e--;)t[e]=arguments[e];return new this(t)}})}},YTGC:function(e,t,n){"use strict";var r=n("eqAp"),i=n("07De"),a=n("xfzY");r(r.S,"Promise",{try:function(e){var t=i.f(this),n=a(e);return(n.e?t.reject:t.resolve)(n.v),t.promise}})},YsJ8:function(e,t,n){n("2+22")("Uint8",1,function(e){return function(t,n,r){return e(this,t,n,r)}},!0)},ZLYQ:function(e,t,n){function r(e,t,n){var u,f,h=arguments.length<4?e:arguments[3],p=a.f(c(e),t);if(!p){if(d(f=o(e)))return r(f,t,n,h);p=l(0)}if(s(p,"value")){if(!1===p.writable||!d(h))return!1;if(u=a.f(h,t)){if(u.get||u.set||!1===u.writable)return!1;u.value=n,i.f(h,t,u)}else i.f(h,t,l(0,n));return!0}return void 0!==p.set&&(p.set.call(h,n),!0)}var i=n("rBVO"),a=n("gWbE"),o=n("spe/"),s=n("3ty/"),u=n("eqAp"),l=n("D8PY"),c=n("PGRs"),d=n("U9LJ");u(u.S,"Reflect",{set:r})},Zn18:function(e,t,n){"use strict";var r=n("bPSW"),i=RegExp.prototype.exec;e.exports=function(e,t){var n=e.exec;if("function"==typeof n){var a=n.call(e,t);if("object"!=typeof a)throw new TypeError("RegExp exec method returned something other than an Object or null");return a}if("RegExp"!==r(e))throw new TypeError("RegExp#exec called on incompatible receiver");return i.call(e,t)}},aGYi:function(e,t,n){var r=n("eqAp"),i=Math.PI/180;r(r.S,"Math",{radians:function(e){return e*i}})},acbg:function(e,t,n){var r=n("eqAp"),i=n("spe/"),a=n("PGRs");r(r.S,"Reflect",{getPrototypeOf:function(e){return i(a(e))}})},au66:function(e,t,n){var r=n("vR0S"),i=n("CfIS"),a=n("3ty/"),o=n("guD1")("src"),s=n("az7O"),u=(""+s).split("toString");n("QhVj").inspectSource=function(e){return s.call(e)},(e.exports=function(e,t,n,s){var l="function"==typeof n;l&&(a(n,"name")||i(n,"name",t)),e[t]!==n&&(l&&(a(n,o)||i(n,o,e[t]?""+e[t]:u.join(String(t)))),e===r?e[t]=n:s?e[t]?e[t]=n:i(e,t,n):(delete e[t],i(e,t,n)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[o]||s.call(this)})},az7O:function(e,t,n){e.exports=n("94Rb")("native-function-to-string",Function.toString)},bBPJ:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{imulh:function(e,t){var n=+e,r=+t,i=65535&n,a=65535&r,o=n>>16,s=r>>16,u=(o*a>>>0)+(i*a>>>16);return o*s+(u>>16)+((i*s>>>0)+(65535&u)>>16)}})},bFIN:function(e,t,n){var r=n("sxvG"),i=n("VmoO");e.exports=function(e){return function(t,n){var a,o,s=String(i(t)),u=r(n),l=s.length;return u<0||u>=l?e?"":void 0:(a=s.charCodeAt(u),a<55296||a>56319||u+1===l||(o=s.charCodeAt(u+1))<56320||o>57343?e?s.charAt(u):a:e?s.slice(u,u+2):o-56320+(a-55296<<10)+65536)}}},bKMx:function(e,t,n){"use strict";var r=n("PWt5"),i=n("q90C");n("LFIv")("WeakSet",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(i(this,"WeakSet"),e,!0)}},r,!1,!0)},bPSW:function(e,t,n){var r=n("1vD2"),i=n("6hGG")("toStringTag"),a="Arguments"==r(function(){return arguments}()),o=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,n,s;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=o(t=Object(e),i))?n:a?r(t):"Object"==(s=r(t))&&"function"==typeof t.callee?"Arguments":s}},bleF:function(e,t,n){var r=n("U9LJ");n("Iiwq")("isSealed",function(e){return function(t){return!r(t)||!!e&&e(t)}})},bmV0:function(e,t,n){var r=n("RVW2"),i=n("VmoO");e.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(i(e))}},cAN6:function(e,t,n){var r=n("eqAp"),i=n("PGRs"),a=Object.isExtensible;r(r.S,"Reflect",{isExtensible:function(e){return i(e),!a||a(e)}})},cGG2:function(e,t,n){"use strict";function r(e){return"[object Array]"===k.call(e)}function i(e){return"[object ArrayBuffer]"===k.call(e)}function a(e){return"undefined"!=typeof FormData&&e instanceof FormData}function o(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer}function s(e){return"string"==typeof e}function u(e){return"number"==typeof e}function l(e){return void 0===e}function c(e){return null!==e&&"object"==typeof e}function d(e){return"[object Date]"===k.call(e)}function f(e){return"[object File]"===k.call(e)}function h(e){return"[object Blob]"===k.call(e)}function p(e){return"[object Function]"===k.call(e)}function m(e){return c(e)&&p(e.pipe)}function v(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams}function g(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}function y(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)}function _(e,t){if(null!==e&&void 0!==e)if("object"!=typeof e&&(e=[e]),r(e))for(var n=0,i=e.length;n<i;n++)t.call(null,e[n],n,e);else for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.call(null,e[a],a,e)}function b(){function e(e,n){"object"==typeof t[n]&&"object"==typeof e?t[n]=b(t[n],e):t[n]=e}for(var t={},n=0,r=arguments.length;n<r;n++)_(arguments[n],e);return t}function T(e,t,n){return _(t,function(t,r){e[r]=n&&"function"==typeof t?S(t,n):t}),e}var S=n("JP+z"),w=n("1Yoh"),k=Object.prototype.toString;e.exports={isArray:r,isArrayBuffer:i,isBuffer:w,isFormData:a,isArrayBufferView:o,isString:s,isNumber:u,isObject:c,isUndefined:l,isDate:d,isFile:f,isBlob:h,isFunction:p,isStream:m,isURLSearchParams:v,isStandardBrowserEnv:y,forEach:_,merge:b,extend:T,trim:g}},cL5L:function(e,t,n){var r=n("W8W2"),i=n("KkGp"),a=n("VpOn"),o=n("PGRs"),s=n("spe/"),u=a.keys,l=a.key,c=function(e,t){var n=u(e,t),a=s(e);if(null===a)return n;var o=c(a,t);return o.length?n.length?i(new r(n.concat(o))):o:n};a.exp({getMetadataKeys:function(e){return c(o(e),arguments.length<2?void 0:l(arguments[1]))}})},cWxy:function(e,t,n){"use strict";function r(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var n=this;e(function(e){n.reason||(n.reason=new i(e),t(n.reason))})}var i=n("dVOP");r.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},r.source=function(){var e;return{token:new r(function(t){e=t}),cancel:e}},e.exports=r},cdBD:function(e,t,n){var r=n("eqAp"),i=n("RXyq");r(r.S+r.F*(Number.parseFloat!=i),"Number",{parseFloat:i})},d8xy:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{log1p:n("ttMd")})},dIwP:function(e,t,n){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},dVOP:function(e,t,n){"use strict";function r(e){this.message=e}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,e.exports=r},dWWz:function(e,t){t.f={}.propertyIsEnumerable},dXsE:function(e,t,n){function r(e){return isFinite(e=+e)&&0!=e?e<0?-r(-e):Math.log(e+Math.sqrt(e*e+1)):e}var i=n("eqAp"),a=Math.asinh;i(i.S+i.F*!(a&&1/a(0)>0),"Math",{asinh:r})},danu:function(e,t,n){"use strict";e.exports=n("G3Gk")||!n("HTem")(function(){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete n("vR0S")[e]})},dkfP:function(e,t,n){var r=n("PGRs");e.exports=function(e,t,n,i){try{return i?t(r(n)[0],n[1]):t(n)}catch(t){var a=e.return;throw void 0!==a&&r(a.call(e)),t}}},dkvW:function(e,t,n){"use strict";var r=n("eqAp"),i=n("3jLb"),a=n("N2PI"),o=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(a);r(r.P+r.F*o,"String",{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},e1Y9:function(e,t,n){var r=n("xnnD"),i=n("6hGG")("iterator"),a=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||a[i]===e)}},eqAp:function(e,t,n){var r=n("vR0S"),i=n("QhVj"),a=n("CfIS"),o=n("au66"),s=n("wRig"),u=function(e,t,n){var l,c,d,f,h=e&u.F,p=e&u.G,m=e&u.S,v=e&u.P,g=e&u.B,y=p?r:m?r[t]||(r[t]={}):(r[t]||{}).prototype,_=p?i:i[t]||(i[t]={}),b=_.prototype||(_.prototype={});p&&(n=t);for(l in n)c=!h&&y&&void 0!==y[l],d=(c?y:n)[l],f=g&&c?s(d,r):v&&"function"==typeof d?s(Function.call,d):d,y&&o(y,l,d,e&u.U),_[l]!=d&&a(_,l,f),v&&b[l]!=d&&(b[l]=d)};r.core=i,u.F=1,u.G=2,u.S=4,u.P=8,u.B=16,u.W=32,u.U=64,u.R=128,e.exports=u},eu0Z:function(e,t,n){var r=n("eqAp");r(r.S+r.F*!n("8yv5"),"Object",{defineProperty:n("rBVO").f})},fLOS:function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},"fPV+":function(e,t,n){"use strict";var r=n("eqAp"),i=n("AeeY"),a=n("B63G"),o=n("rBVO");n("8yv5")&&r(r.P+n("danu"),"Object",{__defineSetter__:function(e,t){o.f(i(this),e,{set:a(t),enumerable:!0,configurable:!0})}})},fYR6:function(e,t,n){var r=n("eqAp");r(r.G,{global:n("vR0S")})},fuGk:function(e,t,n){"use strict";function r(){this.handlers=[]}var i=n("cGG2");r.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},r.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},r.prototype.forEach=function(e){i.forEach(this.handlers,function(t){null!==t&&e(t)})},e.exports=r},fvVZ:function(e,t,n){"use strict";var r=n("eqAp"),i=n("HTem"),a=n("TMyd"),o=1..toPrecision;r(r.P+r.F*(i(function(){return"1"!==o.call(1,void 0)})||!i(function(){o.call({})})),"Number",{toPrecision:function(e){var t=a(this,"Number#toPrecision: incorrect invocation!");return void 0===e?o.call(t):o.call(t,e)}})},"gGS/":function(e,t,n){n("sGlJ")("WeakMap")},gWbE:function(e,t,n){var r=n("dWWz"),i=n("D8PY"),a=n("xpmJ"),o=n("E2U5"),s=n("3ty/"),u=n("thuU"),l=Object.getOwnPropertyDescriptor;t.f=n("8yv5")?l:function(e,t){if(e=a(e),t=o(t,!0),u)try{return l(e,t)}catch(e){}if(s(e,t))return i(!r.f.call(e,t),e[t])}},guD1:function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},gzYr:function(e,t,n){n("2+22")("Uint32",4,function(e){return function(t,n,r){return e(this,t,n,r)}})},h86t:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{sign:n("iIAy")})},hG4L:function(e,t,n){"use strict";var r=n("eqAp"),i=n("VmoO"),a=n("J5DO"),o=n("RVW2"),s=n("AQEt"),u=RegExp.prototype,l=function(e,t){this._r=e,this._s=t};n("m1wx")(l,"RegExp String",function(){var e=this._r.exec(this._s);return{value:e,done:null===e}}),r(r.P,"String",{matchAll:function(e){if(i(this),!o(e))throw TypeError(e+" is not a regexp!");var t=String(this),n="flags"in u?String(e.flags):s.call(e),r=new RegExp(e.source,~n.indexOf("g")?n:"g"+n);return r.lastIndex=a(e.lastIndex),new l(r,t)}})},hSxG:function(e,t,n){"use strict";var r=n("rBVO").f,i=n("NkR5"),a=n("NmAK"),o=n("wRig"),s=n("S5no"),u=n("VLJK"),l=n("lPz5"),c=n("fLOS"),d=n("7QiM"),f=n("8yv5"),h=n("QhHn").fastKey,p=n("q90C"),m=f?"_s":"size",v=function(e,t){var n,r=h(t);if("F"!==r)return e._i[r];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,l){var c=e(function(e,r){s(e,c,t,"_i"),e._t=t,e._i=i(null),e._f=void 0,e._l=void 0,e[m]=0,void 0!=r&&u(r,n,e[l],e)});return a(c.prototype,{clear:function(){for(var e=p(this,t),n=e._i,r=e._f;r;r=r.n)r.r=!0,r.p&&(r.p=r.p.n=void 0),delete n[r.i];e._f=e._l=void 0,e[m]=0},delete:function(e){var n=p(this,t),r=v(n,e);if(r){var i=r.n,a=r.p;delete n._i[r.i],r.r=!0,a&&(a.n=i),i&&(i.p=a),n._f==r&&(n._f=i),n._l==r&&(n._l=a),n[m]--}return!!r},forEach:function(e){p(this,t);for(var n,r=o(e,arguments.length>1?arguments[1]:void 0,3);n=n?n.n:this._f;)for(r(n.v,n.k,this);n&&n.r;)n=n.p},has:function(e){return!!v(p(this,t),e)}}),f&&r(c.prototype,"size",{get:function(){return p(this,t)[m]}}),c},def:function(e,t,n){var r,i,a=v(e,t);return a?a.v=n:(e._l=a={i:i=h(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=a),r&&(r.n=a),e[m]++,"F"!==i&&(e._i[i]=a)),e},getEntry:v,setStrong:function(e,t,n){l(e,t,function(e,n){this._t=p(e,t),this._k=n,this._l=void 0},function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?"keys"==t?c(0,n.k):"values"==t?c(0,n.v):c(0,[n.k,n.v]):(e._t=void 0,c(1))},n?"entries":"values",!n,!0),d(t)}}},hrFQ:function(e,t,n){var r=n("vR0S").document;e.exports=r&&r.documentElement},i4QR:function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(4);r(r.P+r.F*!n("+qBm")([].every,!0),"Array",{every:function(e){return i(this,e,arguments[1])}})},i5O8:function(e,t,n){"use strict";var r=n("/dY/"),i=n("xWqz"),a=n("dWWz"),o=n("AeeY"),s=n("6VhL"),u=Object.assign;e.exports=!u||n("HTem")(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=u({},e)[n]||Object.keys(u({},t)).join("")!=r})?function(e,t){for(var n=o(e),u=arguments.length,l=1,c=i.f,d=a.f;u>l;)for(var f,h=s(arguments[l++]),p=c?r(h).concat(c(h)):r(h),m=p.length,v=0;m>v;)d.call(h,f=p[v++])&&(n[f]=h[f]);return n}:u},iIAy:function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},iUoc:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{DEG_PER_RAD:Math.PI/180})},iYN6:function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},"iqo/":function(e,t,n){var r=n("eqAp");r(r.S,"Math",{umulh:function(e,t){var n=+e,r=+t,i=65535&n,a=65535&r,o=n>>>16,s=r>>>16,u=(o*a>>>0)+(i*a>>>16);return o*s+(u>>>16)+((i*s>>>0)+(65535&u)>>>16)}})},"j/BO":function(e,t,n){var r=n("bPSW"),i=n("KkGp");e.exports=function(e){return function(){if(r(this)!=e)throw TypeError(e+"#toJSON isn't generic");return i(this)}}},j1ja:function(e,t,n){"use strict";(function(e){function t(e,t,n){e[t]||Object[r](e,t,{writable:!0,configurable:!0,value:n})}if(n("vATM"),n("zkX4"),n("PLrh"),e._babelPolyfill)throw new Error("only one instance of babel-polyfill is allowed");e._babelPolyfill=!0;var r="defineProperty";t(String.prototype,"padLeft","".padStart),t(String.prototype,"padRight","".padEnd),"pop,reverse,shift,keys,values,entries,indexOf,every,some,forEach,map,filter,find,findIndex,includes,join,slice,concat,push,splice,unshift,sort,lastIndexOf,reduce,reduceRight,copyWithin,fill".split(",").forEach(function(e){[][e]&&t(Array,e,Function.call.bind([][e]))})}).call(t,n("DuR2"))},jLAN:function(e,t,n){"use strict";var r=n("bFIN")(!0);e.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},jYoD:function(e,t,n){"use strict";var r=n("eqAp"),i=n("PBY2");r(r.P+r.F*!n("+qBm")([].reduceRight,!0),"Array",{reduceRight:function(e){return i(this,e,arguments.length,arguments[1],!0)}})},jfqE:function(e,t,n){n("Iiwq")("getOwnPropertyNames",function(){return n("xH/3").f})},kKiV:function(e,t,n){var r=n("U9LJ"),i=n("QhHn").onFreeze;n("Iiwq")("seal",function(e){return function(t){return e&&r(t)?e(i(t)):t}})},kLED:function(e,t,n){var r=n("/dY/"),i=n("xpmJ"),a=n("dWWz").f;e.exports=function(e){return function(t){for(var n,o=i(t),s=r(o),u=s.length,l=0,c=[];u>l;)a.call(o,n=s[l++])&&c.push(e?[n,o[n]]:o[n]);return c}}},kfMr:function(e,t,n){"use strict";var r=n("PGRs"),i=n("wNcl"),a=n("Zn18");n("UIZt")("search",1,function(e,t,n,o){return[function(n){var r=e(this),i=void 0==n?void 0:n[t];return void 0!==i?i.call(n,r):new RegExp(n)[t](String(r))},function(e){var t=o(n,e,this);if(t.done)return t.value;var s=r(e),u=String(this),l=s.lastIndex;i(l,0)||(s.lastIndex=0);var c=a(s,u);return i(s.lastIndex,l)||(s.lastIndex=l),null===c?-1:c.index}]})},kruC:function(e,t,n){"use strict";var r=n("eqAp"),i=n("AeeY"),a=n("B63G"),o=n("rBVO");n("8yv5")&&r(r.P+n("danu"),"Object",{__defineGetter__:function(e,t){o.f(i(this),e,{get:a(t),enumerable:!0,configurable:!0})}})},lCha:function(e,t,n){var r=n("eqAp"),i=n("B63G"),a=n("PGRs"),o=(n("vR0S").Reflect||{}).apply,s=Function.apply;r(r.S+r.F*!n("HTem")(function(){o(function(){})}),"Reflect",{apply:function(e,t,n){var r=i(e),u=a(n);return o?o(r,t,u):s.call(r,t,u)}})},lHtY:function(e,t,n){var r=n("eqAp"),i=n("RXyq");r(r.G+r.F*(parseFloat!=i),{parseFloat:i})},lPz5:function(e,t,n){"use strict";var r=n("G3Gk"),i=n("eqAp"),a=n("au66"),o=n("CfIS"),s=n("xnnD"),u=n("m1wx"),l=n("W97E"),c=n("spe/"),d=n("6hGG")("iterator"),f=!([].keys&&"next"in[].keys()),h=function(){return this};e.exports=function(e,t,n,p,m,v,g){u(n,t,p);var y,_,b,T=function(e){if(!f&&e in E)return E[e];switch(e){case"keys":case"values":return function(){return new n(this,e)}}return function(){return new n(this,e)}},S=t+" Iterator",w="values"==m,k=!1,E=e.prototype,A=E[d]||E["@@iterator"]||m&&E[m],C=A||T(m),L=m?w?T("entries"):C:void 0,x="Array"==t?E.entries||A:A;if(x&&(b=c(x.call(new e)))!==Object.prototype&&b.next&&(l(b,S,!0),r||"function"==typeof b[d]||o(b,d,h)),w&&A&&"values"!==A.name&&(k=!0,C=function(){return A.call(this)}),r&&!g||!f&&!k&&E[d]||o(E,d,C),s[t]=C,s[S]=h,m)if(y={values:w?C:T("values"),keys:v?C:T("keys"),entries:L},g)for(_ in y)_ in E||a(E,_,y[_]);else i(i.P+i.F*(f||k),t,y);return y}},lkrK:function(e,t,n){n("2+22")("Int16",2,function(e){return function(t,n,r){return e(this,t,n,r)}})},lwhV:function(e,t,n){var r=n("1vD2");e.exports=Array.isArray||function(e){return"Array"==r(e)}},m1wx:function(e,t,n){"use strict";var r=n("NkR5"),i=n("D8PY"),a=n("W97E"),o={};n("CfIS")(o,n("6hGG")("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=r(o,{next:i(1,n)}),a(e,t+" Iterator")}},mJPh:function(e,t){e.exports=function(e){var t="undefined"!=typeof window&&window.location;if(!t)throw new Error("fixUrls requires window.location");if(!e||"string"!=typeof e)return e;var n=t.protocol+"//"+t.host,r=n+t.pathname.replace(/\/[^\/]*$/,"/");return e.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi,function(e,t){var i=t.trim().replace(/^"(.*)"$/,function(e,t){return t}).replace(/^'(.*)'$/,function(e,t){return t});if(/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(i))return e;var a;return a=0===i.indexOf("//")?i:0===i.indexOf("/")?n+i:r+i.replace(/^\.\//,""),"url("+JSON.stringify(a)+")"})}},mK6O:function(e,t,n){n("2+22")("Uint8",1,function(e){return function(t,n,r){return e(this,t,n,r)}})},mXza:function(e,t,n){"use strict";var r=n("eqAp"),i=n("VqU3")(!1),a=[].indexOf,o=!!a&&1/[1].indexOf(1,-0)<0;r(r.P+r.F*(o||!n("+qBm")(a)),"Array",{indexOf:function(e){return o?a.apply(this,arguments)||0:i(this,e,arguments[1])}})},mtWM:function(e,t,n){e.exports=n("tIFN")},mypn:function(e,t,n){(function(e,t){!function(e,n){"use strict";function r(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n<t.length;n++)t[n]=arguments[n+1];var r={callback:e,args:t};return l[u]=r,s(u),u++}function i(e){delete l[e]}function a(e){var t=e.callback,r=e.args;switch(r.length){case 0:t();break;case 1:t(r[0]);break;case 2:t(r[0],r[1]);break;case 3:t(r[0],r[1],r[2]);break;default:t.apply(n,r)}}function o(e){if(c)setTimeout(o,0,e);else{var t=l[e];if(t){c=!0;try{a(t)}finally{i(e),c=!1}}}}if(!e.setImmediate){var s,u=1,l={},c=!1,d=e.document,f=Object.getPrototypeOf&&Object.getPrototypeOf(e);f=f&&f.setTimeout?f:e,"[object process]"==={}.toString.call(e.process)?function(){s=function(e){t.nextTick(function(){o(e)})}}():function(){if(e.postMessage&&!e.importScripts){var t=!0,n=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=n,t}}()?function(){var t="setImmediate$"+Math.random()+"$",n=function(n){n.source===e&&"string"==typeof n.data&&0===n.data.indexOf(t)&&o(+n.data.slice(t.length))};e.addEventListener?e.addEventListener("message",n,!1):e.attachEvent("onmessage",n),s=function(n){e.postMessage(t+n,"*")}}():e.MessageChannel?function(){var e=new MessageChannel;e.port1.onmessage=function(e){o(e.data)},s=function(t){e.port2.postMessage(t)}}():d&&"onreadystatechange"in d.createElement("script")?function(){var e=d.documentElement;s=function(t){var n=d.createElement("script");n.onreadystatechange=function(){o(t),n.onreadystatechange=null,e.removeChild(n),n=null},e.appendChild(n)}}():function(){s=function(e){setTimeout(o,0,e)}}(),f.setImmediate=r,f.clearImmediate=i}}("undefined"==typeof self?void 0===e?this:e:self)}).call(t,n("DuR2"),n("W2nU"))},n1Fu:function(e,t,n){var r=n("eqAp");r(r.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},nCxY:function(e,t,n){var r=n("U9LJ"),i=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&i(e)===e}},"nFL/":function(e,t,n){var r=n("eqAp"),i=n("T9ir"),a=Math.exp;r(r.S,"Math",{tanh:function(e){var t=i(e=+e),n=i(-e);return t==1/0?1:n==1/0?-1:(t-n)/(a(e)+a(-e))}})},nbAL:function(e,t,n){t.f=n("6hGG")},nixg:function(e,t,n){var r=n("U9LJ"),i=n("vR0S").document,a=r(i)&&r(i.createElement);e.exports=function(e){return a?i.createElement(e):{}}},noA0:function(e,t,n){var r=n("eqAp"),i=n("T9ir"),a=Math.exp;r(r.S+r.F*n("HTem")(function(){return-2e-17!=!Math.sinh(-2e-17)}),"Math",{sinh:function(e){return Math.abs(e=+e)<1?(i(e)-i(-e))/2:(a(e-1)-a(-e-1))*(Math.E/2)}})},oJlE:function(e,t,n){"use strict";n("XOiX")("trimLeft",function(e){return function(){return e(this,1)}},"trimStart")},oJlt:function(e,t,n){"use strict";var r=n("cGG2"),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,a,o={};return e?(r.forEach(e.split("\n"),function(e){if(a=e.indexOf(":"),t=r.trim(e.substr(0,a)).toLowerCase(),n=r.trim(e.substr(a+1)),t){if(o[t]&&i.indexOf(t)>=0)return;o[t]="set-cookie"===t?(o[t]?o[t]:[]).concat([n]):o[t]?o[t]+", "+n:n}}),o):o}},oSrZ:function(e,t,n){var r=n("eqAp"),i=n("iIAy");r(r.S,"Math",{cbrt:function(e){return i(e=+e)*Math.pow(Math.abs(e),1/3)}})},oZJn:function(e,t,n){n("xU4Q")("asyncIterator")},p1b6:function(e,t,n){"use strict";var r=n("cGG2");e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,i,a,o){var s=[];s.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),r.isString(i)&&s.push("path="+i),r.isString(a)&&s.push("domain="+a),!0===o&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},pBtG:function(e,t,n){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},pqvg:function(e,t,n){var r=n("U9LJ"),i=n("lwhV"),a=n("6hGG")("species");e.exports=function(e){var t;return i(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!i(t.prototype)||(t=void 0),r(t)&&null===(t=t[a])&&(t=void 0)),void 0===t?Array:t}},psjt:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=r.keys,o=r.key;r.exp({getOwnMetadataKeys:function(e){return a(i(e),arguments.length<2?void 0:o(arguments[1]))}})},pxG4:function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},q90C:function(e,t,n){var r=n("U9LJ");e.exports=function(e,t){if(!r(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},qHaP:function(e,t,n){"use strict";var r=n("wRig"),i=n("eqAp"),a=n("AeeY"),o=n("dkfP"),s=n("e1Y9"),u=n("J5DO"),l=n("RvsJ"),c=n("JuSo");i(i.S+i.F*!n("GAJc")(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,i,d,f=a(e),h="function"==typeof this?this:Array,p=arguments.length,m=p>1?arguments[1]:void 0,v=void 0!==m,g=0,y=c(f);if(v&&(m=r(m,p>2?arguments[2]:void 0,2)),void 0==y||h==Array&&s(y))for(t=u(f.length),n=new h(t);t>g;g++)l(n,g,v?m(f[g],g):f[g]);else for(d=y.call(f),n=new h;!(i=d.next()).done;g++)l(n,g,v?o(d,m,[i.value,g],!0):i.value);return n.length=g,n}})},qMAc:function(e,t,n){t=e.exports=n("FZ+f")(void 0),t.push([e.i,'.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.video-js .vjs-modal-dialog,.vjs-button>.vjs-icon-placeholder:before,.vjs-modal-dialog .vjs-modal-dialog-content{position:absolute;top:0;left:0;width:100%;height:100%}.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.vjs-button>.vjs-icon-placeholder:before{text-align:center}@font-face{font-family:VideoJS;src:url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAABDkAAsAAAAAG6gAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADsAAABUIIslek9TLzIAAAFEAAAAPgAAAFZRiV3hY21hcAAAAYQAAADaAAADPv749/pnbHlmAAACYAAAC3AAABHQZg6OcWhlYWQAAA3QAAAAKwAAADYZw251aGhlYQAADfwAAAAdAAAAJA+RCLFobXR4AAAOHAAAABMAAACM744AAGxvY2EAAA4wAAAASAAAAEhF6kqubWF4cAAADngAAAAfAAAAIAE0AIFuYW1lAAAOmAAAASUAAAIK1cf1oHBvc3QAAA/AAAABJAAAAdPExYuNeJxjYGRgYOBiMGCwY2BycfMJYeDLSSzJY5BiYGGAAJA8MpsxJzM9kYEDxgPKsYBpDiBmg4gCACY7BUgAeJxjYGS7wTiBgZWBgaWQ5RkDA8MvCM0cwxDOeI6BgYmBlZkBKwhIc01hcPjI+FGJHcRdyA4RZgQRADK3CxEAAHic7dFZbsMgAEXRS0ycyZnnOeG7y+qC8pU1dHusIOXxuoxaOlwZYWQB0Aea4quIEN4E9LzKbKjzDeM6H/mua6Lmc/p8yhg0lvdYx15ZG8uOLQOGjMp3EzqmzJizYMmKNRu27Nhz4MiJMxeu3Ljz4Ekqm7T8P52G8PP3lnTOVk++Z6iN6QZzNN1F7ptuN7eGOjDUoaGODHVsuvU8MdTO9Hd5aqgzQ50b6sJQl4a6MtS1oW4MdWuoO0PdG+rBUI+GejLUs6FeDPVqqDdDvRvqw1CfhpqM9At0iFLaAAB4nJ1YDXBTVRZ+5/22TUlJ8we0pHlJm7RJf5O8F2j6EymlSPkpxaL8U2xpa3DKj0CBhc2IW4eWKSokIoLsuMqssM64f+jA4HSdWXXXscBq67IOs3FXZ1ZYWVyRFdo899yXtIBQZ90k7717zz3v3HPPOfd854YCCj9cL9dL0RQFOqCbGJnrHb5EayiKIWN8iA/hWBblo6hUWm8TtCDwE80WMJus/irwyxOdxeB0MDb14VNJHnXYoLLSl6FfCUYO9nYPTA8Epg9090LprfbBbZ2hY0UlJUXHQp3/vtWkS6EBv8+rPMq5u9692f/dNxJNiqwC1xPE9TCUgCsSdQWgE3XQD25lkG4CN2xmTcOXWBOyser6RN6KnGbKSbmQ3+d0OI1m2W8QzLLkI2sykrWAgJJEtA8vGGW/2Q+CmT3n8zS9wZwu2DCvtuZKZN3xkrLh36yCZuUomQSqGpY8t/25VfHVhw8z4ebGBtfLb0ya9PCaDc+8dGTvk2dsh6z7WzvowlXKUSWo9MJ15a3KrEP2loOr2Ojhw6iW6hf2BDdEccQvZGpaAy7YovSwq8kr7HGllxpd71rkS6G0Sf11sl9OvMK1+jwPPODxjUwkOim9CU3ix1wNjXDfmJSEn618Bs6lpWwUpU+8PCqLMY650zjq8VhCIP17NEKTx3eaLL+s5Pi6yJWaWjTHLR1jYzPSV9VF/6Ojdb/1kO3Mk3uhHC0x6gc1BjlKQ+nQFxTYdaJkZ7ySVxLBbhR1dsboNXp1tCYKW2LRaEzpYcIx2BKNxaL0ZaUnSqfFoiNhHKR/GkX6PWUSAaJelQaqZL1EpoHNsajSEyPSoJ9IjhIxTdjHLmwZvhRDOiFTY/YeQnvrVZmiTQtGncECXtFTBZLOVwwMRgoXHAkXzMzPn1nAJJ8jYSbMDaqN2waGLzNhih/bZynUBMpIWSg7VYi7DRx2m8ALkIdRCJwI6ArJx2EI8kaDWeTQKeAFk9fjl/1AvwktjQ1P7NjyMGQyfd4vjipX6M/i52D7Cq80kqlcxEcGXRr/FEcgs0u5uGgB4VWuMFfpdn2Re6Hi3PqzmxWKsz6+ae2Pn9hXXw/fqM859UiGC0oKYYILJBqJrsn1Z1E5qOs9rQCiUQRREjm8yJcbHF5cUJufX1vAHlefw0XgUoboS3ETfQlTxBC4SOtuE8VPRJTBSCQSjZCpk7Gqzu+masaZ2y7Zjehho4F3g82BNDkAHpORG4+OCS+f6JTPmtRn/PH1kch6d04sp7AQb25aQ/pqUyXeQ8vrebG8OYQdXOQ+585u0sdW9rqalzRURiJ+9F4MweRFrKUjl1GUYhH1A27WOHw5cTFSFPMo9EeUIGnQTZHIaJ7AHLaOKsOODaNF9jkBjYG2QEsQ2xjMUAx2bBEbeTBWMHwskBjngq56S/yfgkBnWBa4K9sqKtq2t1UI8S9He5XuBRbawAdatrQEAi30Aks2+LM8WeCbalVZkWNylvJ+dqJnzVb+OHlSoKW8nPCP7Rd+CcZ2DdWAGqJ2CBFOphgywFFCFBNtfAbGtNPBCwxvygHeYMZMY9ZboBqwq/pVrsbgN5tkv152ODlbMfiqwGMBgxa4Exz3QhovRIUp6acqZmQzRq0ypDXS2TPLT02YIkQETnOE445oOGxOmXAqUJNNG7XgupMjPq2ua9asrj5yY/yuKteO1Kx0YNJTufrirLe1mZnat7OL6rnUdCWenpW6I8mAnbsY8KWs1PuSovCW9A/Z25PQ24a7cNOqgmTkLmBMgh4THgc4b9k2IVv1/g/F5nGljwPLfOgHAzJzh45V/4+WenTzmMtR5Z7us2Tys909UHqrPY7KbckoxRvRHhmVc3cJGE97uml0R1S0jdULVl7EvZtDFVBF35N9cEdjpgmAiOlFZ+Dtoh93+D3zzHr8RRNZQhnCNMNbcegOvpEwZoL+06cJQ07h+th3fZ/7PVbVC6ngTAV/KoLFuO6+2KFcU651gEb5ugPSIb1D+Xp8V4+k3sEIGnw5mYe4If4k1lFYr6SCzmM2EQ8iWtmwjnBI9kTwe1TlfAmXh7H02by9fW2gsjKwtv0aaURKil4OdV7rDL1MXIFNrhdxohcZXYTnq47WisrKitaObbf5+yvkLi5J6lCNZZ+B6GC38VNBZBDidSS/+mSvh6s+srgC8pyKMvDtt+de3c9fU76ZPfuM8ud4Kv0fyP/LqfepMT/3oZxSqpZaTa1DaQYLY8TFsHYbWYsPoRhRWfL5eSSQbhUGgGC3YLbVMk6PitTFNGpAsNrC6D1VNBKgBHMejaiuRWEWGgsSDBTJjqWIl8kJLlsaLJ2tXDr6xGfT85bM2Q06a46x2HTgvdnV8z5YDy/27J4zt6x2VtkzjoYpkq36kaBr4eQSg7tyiVweWubXZugtadl58ydapfbORfKsDTuZ0OBgx4cfdjCf5tbWNITnL120fdOi1RV1C3uKGzNdwYLcMvZ3BxoPyTOCD1XvXTp7U10gWCVmTV9b3r2z0SkGWovb2hp9I89O8a2smlyaO8muMU+dRmtzp60IzAoFpjLr1n388boLyf0dRvxhsHZ0qbWqDkwqvvpkj4l0fY6EIXRi5sQSrAvsVYwXRy4qJ2EVtD1AN7a0HWth9ymvL1xc3WTUKK/TAHA/bXDVtVWfOMfuGxGZv4Ln/jVr9jc3j1yMv0tndmyt9Vq88Y9gH1wtLX3KWjot5++jWHgAoZZkQ14wGQ20Fli71UmKJAy4xKMSTGbVdybW7FDDAut9XpD5AzWrYO7zQ8qffqF8+Ynd/clrHcdyxGy3a/3+mfNnzC/cBsveTjnTvXf1o6vzOlZw7WtqtdmPK/Errz/6NNtD72zmNOZfbmYdTGHfoofqI79Oc+R2n1lrnL6pOm0Up7kwxhTW12Amm7WYkXR2qYrF2AmgmbAsxZjwy1xpg/m1Je2vrp8v/nz2xpmlBg4E9hrMU341wVpTOh/OfmGvAnra8q6uctr60ZQHV3Q+WMQJykMj8ZsWn2QBOmmHMB+m5pDIpTFonYigiaKAhGEiAHF7EliVnQkjoLVIMPtJpBKHYd3A8GYH9jJzrWwmHx5Qjp7vDAX0suGRym1vtm/9W1/HyR8vczfMs6Sk8DSv855/5dlX9oQq52hT8syyp2rx5Id17IAyAM3wIjQPMOHzytEB64q6D5zT91yNbnx3V/nqnd017S9Y0605k3izoXLpsxde2n38yoOV9s1LcjwzNjbdX6asnBVaBj/6/DwKwPkpcqbDG7BnsXoSqWnUAmottYF6jMSdVyYZh3zVXCjwTiwwHH6sGuRiEHQGzuRX6whZkp123oy1BWE2mEfJ/tvIRtM4ZM5bDXiMsPMaAKOTyc5uL57rqyyc5y5JE5pm1i2S2iUX0CcaQ6lC6Zog7JqSqZmYlosl2K6pwNA84zRnQW6SaALYZQGW5lhCtU/W34N6o+bKfZ8cf3/Cl/+iTX3wBzpOY4mRkeNf3rptycGSshQWgGbYt5jFc2e0+DglIrwl6DVWQ7BuwaJ3Xk1J4VL5urnLl/Wf+gHU/hZoZdKNym6lG+I34FaNeZKcSpJIo2IeCVvpdsDGfKvzJnAwmeD37Ow65ZWwSowpgwX5T69s/rB55dP5BcpgDKFV8p7q2sn/1uc93bVzT/w6UrCqDTWvfCq/oCD/qZXNoUj8BL5Kp6GU017frfNXkAtiiyf/SOCEeLqnd8R/Ql9GlCRfctS6k5chvIBuQ1zCCjoCHL2DHNHIXxMJ3kQeO8lbsUXONeSfA5EjcG6/E+KdhN4bP04vBhdi883+BFBzQbxFbvZzQeY9LNBZc0FNfn5NwfDn6rCTnTw6R8o+gfpf5hCom33cRuiTlss3KHmZjD+BPN+5gXuA2ziS/Q73mLxUkpbKN/eqwz5uK0X9F3h2d1V4nGNgZGBgAOJd776+iue3+crAzc4AAje5Bfcg0xz9YHEOBiYQBQA8FQlFAHicY2BkYGBnAAGOPgaG//85+hkYGVCBMgBGGwNYAAAAeJxjYGBgYB8EmKOPgQEAQ04BfgAAAAAAAA4AaAB+AMwA4AECAUIBbAGYAcICGAJYArQC4AMwA7AD3gQwBJYE3AUkBWYFigYgBmYGtAbqB1gIEghYCG4IhAi2COh4nGNgZGBgUGYoZWBnAAEmIOYCQgaG/2A+AwAYCQG2AHicXZBNaoNAGIZfE5PQCKFQ2lUps2oXBfOzzAESyDKBQJdGR2NQR3QSSE/QE/QEPUUPUHqsvsrXjTMw83zPvPMNCuAWP3DQDAejdm1GjzwS7pMmwi75XngAD4/CQ/oX4TFe4Qt7uMMbOzjuDc0EmXCP/C7cJ38Iu+RP4QEe8CU8pP8WHmOPX2EPz87TPo202ey2OjlnQSXV/6arOjWFmvszMWtd6CqwOlKHq6ovycLaWMWVydXKFFZnmVFlZU46tP7R2nI5ncbi/dDkfDtFBA2DDXbYkhKc+V0Bqs5Zt9JM1HQGBRTm/EezTmZNKtpcAMs9Yu6AK9caF76zoLWIWcfMGOSkVduvSWechqZsz040Ib2PY3urxBJTzriT95lipz+TN1fmAAAAeJxtkMl2wjAMRfOAhABlKm2h80C3+ajgCKKDY6cegP59TYBzukAL+z1Zsq8ctaJTTKPrsUQLbXQQI0EXKXroY4AbDDHCGBNMcYsZ7nCPB8yxwCOe8IwXvOIN7/jAJ76wxHfUqWX+OzgumWAjJMV17i0Ndlr6irLKO+qftdT7i6y4uFSUvCknay+lFYZIZaQcmfH/xIFdYn98bqhra1aKTM/6lWMnyaYirx1rFUQZFBkb2zJUtoXeJCeg0WnLtHeSFc3OtrnozNwqi0TkSpBMDB1nSde5oJXW23hTS2/T0LilglXX7dmFVxLnq5U0vYATHFk3zX3BOisoQHNDFDeZnqKDy9hRNawN7Vh727hFzcJ5c8TILrKZfH7tIPxAFP0BpLeJPA==) format("woff");font-weight:400;font-style:normal}.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.video-js .vjs-play-control .vjs-icon-placeholder,.vjs-icon-play{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-big-play-button .vjs-icon-placeholder:before,.video-js .vjs-play-control .vjs-icon-placeholder:before,.vjs-icon-play:before{content:"\\F101"}.vjs-icon-play-circle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-play-circle:before{content:"\\F102"}.video-js .vjs-play-control.vjs-playing .vjs-icon-placeholder,.vjs-icon-pause{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-play-control.vjs-playing .vjs-icon-placeholder:before,.vjs-icon-pause:before{content:"\\F103"}.video-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder,.vjs-icon-volume-mute{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-mute-control.vjs-vol-0 .vjs-icon-placeholder:before,.vjs-icon-volume-mute:before{content:"\\F104"}.video-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder,.vjs-icon-volume-low{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-mute-control.vjs-vol-1 .vjs-icon-placeholder:before,.vjs-icon-volume-low:before{content:"\\F105"}.video-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder,.vjs-icon-volume-mid{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-mute-control.vjs-vol-2 .vjs-icon-placeholder:before,.vjs-icon-volume-mid:before{content:"\\F106"}.video-js .vjs-mute-control .vjs-icon-placeholder,.vjs-icon-volume-high{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-mute-control .vjs-icon-placeholder:before,.vjs-icon-volume-high:before{content:"\\F107"}.video-js .vjs-fullscreen-control .vjs-icon-placeholder,.vjs-icon-fullscreen-enter{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-fullscreen-control .vjs-icon-placeholder:before,.vjs-icon-fullscreen-enter:before{content:"\\F108"}.video-js.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder,.vjs-icon-fullscreen-exit{font-family:VideoJS;font-weight:400;font-style:normal}.video-js.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder:before,.vjs-icon-fullscreen-exit:before{content:"\\F109"}.vjs-icon-square{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-square:before{content:"\\F10A"}.vjs-icon-spinner{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-spinner:before{content:"\\F10B"}.video-js.video-js:lang(en-AU) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-GB) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-IE) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js.video-js:lang(en-NZ) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js .vjs-subs-caps-button .vjs-icon-placeholder,.video-js .vjs-subtitles-button .vjs-icon-placeholder,.vjs-icon-subtitles{font-family:VideoJS;font-weight:400;font-style:normal}.video-js.video-js:lang(en-AU) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-GB) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-IE) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js.video-js:lang(en-NZ) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js .vjs-subtitles-button .vjs-icon-placeholder:before,.vjs-icon-subtitles:before{content:"\\F10C"}.video-js .vjs-captions-button .vjs-icon-placeholder,.video-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder,.video-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder,.vjs-icon-captions{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-captions-button .vjs-icon-placeholder:before,.video-js:lang(en) .vjs-subs-caps-button .vjs-icon-placeholder:before,.video-js:lang(fr-CA) .vjs-subs-caps-button .vjs-icon-placeholder:before,.vjs-icon-captions:before{content:"\\F10D"}.video-js .vjs-chapters-button .vjs-icon-placeholder,.vjs-icon-chapters{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-chapters-button .vjs-icon-placeholder:before,.vjs-icon-chapters:before{content:"\\F10E"}.vjs-icon-share{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-share:before{content:"\\F10F"}.vjs-icon-cog{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-cog:before{content:"\\F110"}.video-js .vjs-play-progress,.video-js .vjs-volume-level,.vjs-icon-circle,.vjs-seek-to-live-control .vjs-icon-placeholder{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-play-progress:before,.video-js .vjs-volume-level:before,.vjs-icon-circle:before,.vjs-seek-to-live-control .vjs-icon-placeholder:before{content:"\\F111"}.vjs-icon-circle-outline{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle-outline:before{content:"\\F112"}.vjs-icon-circle-inner-circle{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-circle-inner-circle:before{content:"\\F113"}.vjs-icon-hd{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-hd:before{content:"\\F114"}.video-js .vjs-control.vjs-close-button .vjs-icon-placeholder,.vjs-icon-cancel{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-control.vjs-close-button .vjs-icon-placeholder:before,.vjs-icon-cancel:before{content:"\\F115"}.video-js .vjs-play-control.vjs-ended .vjs-icon-placeholder,.vjs-icon-replay{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-play-control.vjs-ended .vjs-icon-placeholder:before,.vjs-icon-replay:before{content:"\\F116"}.vjs-icon-facebook{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-facebook:before{content:"\\F117"}.vjs-icon-gplus{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-gplus:before{content:"\\F118"}.vjs-icon-linkedin{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-linkedin:before{content:"\\F119"}.vjs-icon-twitter{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-twitter:before{content:"\\F11A"}.vjs-icon-tumblr{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-tumblr:before{content:"\\F11B"}.vjs-icon-pinterest{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-pinterest:before{content:"\\F11C"}.video-js .vjs-descriptions-button .vjs-icon-placeholder,.vjs-icon-audio-description{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-descriptions-button .vjs-icon-placeholder:before,.vjs-icon-audio-description:before{content:"\\F11D"}.video-js .vjs-audio-button .vjs-icon-placeholder,.vjs-icon-audio{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-audio-button .vjs-icon-placeholder:before,.vjs-icon-audio:before{content:"\\F11E"}.vjs-icon-next-item{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-next-item:before{content:"\\F11F"}.vjs-icon-previous-item{font-family:VideoJS;font-weight:400;font-style:normal}.vjs-icon-previous-item:before{content:"\\F120"}.video-js .vjs-picture-in-picture-control .vjs-icon-placeholder,.vjs-icon-picture-in-picture-enter{font-family:VideoJS;font-weight:400;font-style:normal}.video-js .vjs-picture-in-picture-control .vjs-icon-placeholder:before,.vjs-icon-picture-in-picture-enter:before{content:"\\F121"}.video-js.vjs-picture-in-picture .vjs-picture-in-picture-control .vjs-icon-placeholder,.vjs-icon-picture-in-picture-exit{font-family:VideoJS;font-weight:400;font-style:normal}.video-js.vjs-picture-in-picture .vjs-picture-in-picture-control .vjs-icon-placeholder:before,.vjs-icon-picture-in-picture-exit:before{content:"\\F122"}.video-js{display:block;vertical-align:top;box-sizing:border-box;color:#fff;background-color:#000;position:relative;padding:0;font-size:10px;line-height:1;font-weight:400;font-style:normal;font-family:Arial,Helvetica,sans-serif;word-break:normal}.video-js:-moz-full-screen{position:absolute}.video-js:-webkit-full-screen{width:100%!important;height:100%!important}.video-js[tabindex="-1"]{outline:none}.video-js *,.video-js :after,.video-js :before{box-sizing:inherit}.video-js ul{font-family:inherit;font-size:inherit;line-height:inherit;list-style-position:outside;margin:0}.video-js.vjs-4-3,.video-js.vjs-16-9,.video-js.vjs-fluid{width:100%;max-width:100%;height:0}.video-js.vjs-16-9{padding-top:56.25%}.video-js.vjs-4-3{padding-top:75%}.video-js.vjs-fill,.video-js .vjs-tech{width:100%;height:100%}.video-js .vjs-tech{position:absolute;top:0;left:0}body.vjs-full-window{padding:0;margin:0;height:100%}.vjs-full-window .video-js.vjs-fullscreen{position:fixed;overflow:hidden;z-index:1000;left:0;top:0;bottom:0;right:0}.video-js.vjs-fullscreen{width:100%!important;height:100%!important;padding-top:0!important}.video-js.vjs-fullscreen.vjs-user-inactive{cursor:none}.vjs-hidden{display:none!important}.vjs-disabled{opacity:.5;cursor:default}.video-js .vjs-offscreen{height:1px;left:-9999px;position:absolute;top:0;width:1px}.vjs-lock-showing{display:block!important;opacity:1;visibility:visible}.vjs-no-js{padding:20px;color:#fff;background-color:#000;font-size:18px;font-family:Arial,Helvetica,sans-serif;text-align:center;width:300px;height:150px;margin:0 auto}.vjs-no-js a,.vjs-no-js a:visited{color:#66a8cc}.video-js .vjs-big-play-button{font-size:3em;line-height:1.5em;height:1.63332em;width:3em;display:block;position:absolute;top:10px;left:10px;padding:0;cursor:pointer;opacity:1;border:.06666em solid #fff;background-color:#2b333f;background-color:rgba(43,51,63,.7);border-radius:.3em;transition:all .4s}.vjs-big-play-centered .vjs-big-play-button{top:50%;left:50%;margin-top:-.81666em;margin-left:-1.5em}.video-js .vjs-big-play-button:focus,.video-js:hover .vjs-big-play-button{border-color:#fff;background-color:#73859f;background-color:rgba(115,133,159,.5);transition:all 0s}.vjs-controls-disabled .vjs-big-play-button,.vjs-error .vjs-big-play-button,.vjs-has-started .vjs-big-play-button,.vjs-using-native-controls .vjs-big-play-button{display:none}.vjs-has-started.vjs-paused.vjs-show-big-play-button-on-pause .vjs-big-play-button{display:block}.video-js button{background:none;border:none;color:inherit;display:inline-block;font-size:inherit;line-height:inherit;text-transform:none;text-decoration:none;transition:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.vjs-control .vjs-button{width:100%;height:100%}.video-js .vjs-control.vjs-close-button{cursor:pointer;height:3em;position:absolute;right:0;top:.5em;z-index:2}.video-js .vjs-modal-dialog{background:rgba(0,0,0,.8);background:linear-gradient(180deg,rgba(0,0,0,.8),hsla(0,0%,100%,0));overflow:auto}.video-js .vjs-modal-dialog>*{box-sizing:border-box}.vjs-modal-dialog .vjs-modal-dialog-content{font-size:1.2em;line-height:1.5;padding:20px 24px;z-index:1}.vjs-menu-button{cursor:pointer}.vjs-menu-button.vjs-disabled{cursor:default}.vjs-workinghover .vjs-menu-button.vjs-disabled:hover .vjs-menu{display:none}.vjs-menu .vjs-menu-content{display:block;padding:0;margin:0;font-family:Arial,Helvetica,sans-serif;overflow:auto}.vjs-menu .vjs-menu-content>*{box-sizing:border-box}.vjs-scrubbing .vjs-control.vjs-menu-button:hover .vjs-menu{display:none}.vjs-menu li{list-style:none;margin:0;padding:.2em 0;line-height:1.4em;font-size:1.2em;text-align:center;text-transform:lowercase}.js-focus-visible .vjs-menu li.vjs-menu-item:hover,.vjs-menu li.vjs-menu-item:focus,.vjs-menu li.vjs-menu-item:hover{background-color:#73859f;background-color:rgba(115,133,159,.5)}.js-focus-visible .vjs-menu li.vjs-selected:hover,.vjs-menu li.vjs-selected,.vjs-menu li.vjs-selected:focus,.vjs-menu li.vjs-selected:hover{background-color:#fff;color:#2b333f}.vjs-menu li.vjs-menu-title{text-align:center;text-transform:uppercase;font-size:1em;line-height:2em;padding:0;margin:0 0 .3em;font-weight:700;cursor:default}.vjs-menu-button-popup .vjs-menu{display:none;position:absolute;bottom:0;width:10em;left:-3em;height:0;margin-bottom:1.5em;border-top-color:rgba(43,51,63,.7)}.vjs-menu-button-popup .vjs-menu .vjs-menu-content{background-color:#2b333f;background-color:rgba(43,51,63,.7);position:absolute;width:100%;bottom:1.5em;max-height:15em}.vjs-layout-tiny .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-x-small .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:5em}.vjs-layout-small .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:10em}.vjs-layout-medium .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:14em}.vjs-layout-huge .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-large .vjs-menu-button-popup .vjs-menu .vjs-menu-content,.vjs-layout-x-large .vjs-menu-button-popup .vjs-menu .vjs-menu-content{max-height:25em}.vjs-menu-button-popup .vjs-menu.vjs-lock-showing,.vjs-workinghover .vjs-menu-button-popup.vjs-hover .vjs-menu{display:block}.video-js .vjs-menu-button-inline{transition:all .4s;overflow:hidden}.video-js .vjs-menu-button-inline:before{width:2.222222222em}.video-js .vjs-menu-button-inline.vjs-slider-active,.video-js .vjs-menu-button-inline:focus,.video-js .vjs-menu-button-inline:hover,.video-js.vjs-no-flex .vjs-menu-button-inline{width:12em}.vjs-menu-button-inline .vjs-menu{opacity:0;height:100%;width:auto;position:absolute;left:4em;top:0;padding:0;margin:0;transition:all .4s}.vjs-menu-button-inline.vjs-slider-active .vjs-menu,.vjs-menu-button-inline:focus .vjs-menu,.vjs-menu-button-inline:hover .vjs-menu{display:block;opacity:1}.vjs-no-flex .vjs-menu-button-inline .vjs-menu{display:block;opacity:1;position:relative;width:auto}.vjs-no-flex .vjs-menu-button-inline.vjs-slider-active .vjs-menu,.vjs-no-flex .vjs-menu-button-inline:focus .vjs-menu,.vjs-no-flex .vjs-menu-button-inline:hover .vjs-menu{width:auto}.vjs-menu-button-inline .vjs-menu-content{width:auto;height:100%;margin:0;overflow:hidden}.video-js .vjs-control-bar{display:none;width:100%;position:absolute;bottom:0;left:0;right:0;height:3em;background-color:#2b333f;background-color:rgba(43,51,63,.7)}.vjs-has-started .vjs-control-bar{display:flex;visibility:visible;opacity:1;transition:visibility .1s,opacity .1s}.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar{visibility:visible;opacity:0;transition:visibility 1s,opacity 1s}.vjs-controls-disabled .vjs-control-bar,.vjs-error .vjs-control-bar,.vjs-using-native-controls .vjs-control-bar{display:none!important}.vjs-audio.vjs-has-started.vjs-user-inactive.vjs-playing .vjs-control-bar{opacity:1;visibility:visible}.vjs-has-started.vjs-no-flex .vjs-control-bar{display:table}.video-js .vjs-control{position:relative;text-align:center;margin:0;padding:0;height:100%;width:4em;flex:none}.vjs-button>.vjs-icon-placeholder:before{font-size:1.8em;line-height:1.67}.video-js .vjs-control:focus,.video-js .vjs-control:focus:before,.video-js .vjs-control:hover:before{text-shadow:0 0 1em #fff}.video-js .vjs-control-text{border:0;clip:rect(0 0 0 0);height:1px;overflow:hidden;padding:0;position:absolute;width:1px}.vjs-no-flex .vjs-control{display:table-cell;vertical-align:middle}.video-js .vjs-custom-control-spacer{display:none}.video-js .vjs-progress-control{cursor:pointer;flex:auto;display:flex;align-items:center;min-width:4em;touch-action:none}.video-js .vjs-progress-control.disabled{cursor:default}.vjs-live .vjs-progress-control{display:none}.vjs-liveui .vjs-progress-control{display:flex;align-items:center}.vjs-no-flex .vjs-progress-control{width:auto}.video-js .vjs-progress-holder{flex:auto;transition:all .2s;height:.3em}.video-js .vjs-progress-control .vjs-progress-holder{margin:0 10px}.video-js .vjs-progress-control:hover .vjs-progress-holder{font-size:1.6666666667em}.video-js .vjs-progress-control:hover .vjs-progress-holder.disabled{font-size:1em}.video-js .vjs-progress-holder .vjs-load-progress,.video-js .vjs-progress-holder .vjs-load-progress div,.video-js .vjs-progress-holder .vjs-play-progress{position:absolute;display:block;height:100%;margin:0;padding:0;width:0}.video-js .vjs-play-progress{background-color:#fff}.video-js .vjs-play-progress:before{font-size:.9em;position:absolute;right:-.5em;top:-.3333333333em;z-index:1}.video-js .vjs-load-progress{background:rgba(115,133,159,.5)}.video-js .vjs-load-progress div{background:rgba(115,133,159,.75)}.video-js .vjs-time-tooltip{background-color:#fff;background-color:hsla(0,0%,100%,.8);border-radius:.3em;color:#000;float:right;font-family:Arial,Helvetica,sans-serif;font-size:1em;padding:6px 8px 8px;pointer-events:none;position:absolute;top:-3.4em;visibility:hidden;z-index:1}.video-js .vjs-progress-holder:focus .vjs-time-tooltip{display:none}.video-js .vjs-progress-control:hover .vjs-progress-holder:focus .vjs-time-tooltip,.video-js .vjs-progress-control:hover .vjs-time-tooltip{display:block;font-size:.6em;visibility:visible}.video-js .vjs-progress-control.disabled:hover .vjs-time-tooltip{font-size:1em}.video-js .vjs-progress-control .vjs-mouse-display{display:none;position:absolute;width:1px;height:100%;background-color:#000;z-index:1}.vjs-no-flex .vjs-progress-control .vjs-mouse-display{z-index:0}.video-js .vjs-progress-control:hover .vjs-mouse-display{display:block}.video-js.vjs-user-inactive .vjs-progress-control .vjs-mouse-display{visibility:hidden;opacity:0;transition:visibility 1s,opacity 1s}.video-js.vjs-user-inactive.vjs-no-flex .vjs-progress-control .vjs-mouse-display{display:none}.vjs-mouse-display .vjs-time-tooltip{color:#fff;background-color:#000;background-color:rgba(0,0,0,.8)}.video-js .vjs-slider{position:relative;cursor:pointer;padding:0;margin:0 .45em;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:#73859f;background-color:rgba(115,133,159,.5)}.video-js .vjs-slider.disabled{cursor:default}.video-js .vjs-slider:focus{text-shadow:0 0 1em #fff;box-shadow:0 0 1em #fff}.video-js .vjs-mute-control{cursor:pointer;flex:none}.video-js .vjs-volume-control{cursor:pointer;margin-right:1em;display:flex}.video-js .vjs-volume-control.vjs-volume-horizontal{width:5em}.video-js .vjs-volume-panel .vjs-volume-control{visibility:visible;opacity:0;width:1px;height:1px;margin-left:-1px}.video-js .vjs-volume-panel{transition:width 1s}.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control,.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active,.video-js .vjs-volume-panel .vjs-volume-control:active,.video-js .vjs-volume-panel:active .vjs-volume-control,.video-js .vjs-volume-panel:focus .vjs-volume-control{visibility:visible;opacity:1;position:relative;transition:visibility .1s,opacity .1s,height .1s,width .1s,left 0s,top 0s}.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-horizontal,.video-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-horizontal,.video-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-horizontal,.video-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-horizontal{width:5em;height:3em}.video-js .vjs-volume-panel.vjs-hover .vjs-mute-control~.vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-vertical,.video-js .vjs-volume-panel .vjs-volume-control:active.vjs-volume-vertical,.video-js .vjs-volume-panel:active .vjs-volume-control.vjs-volume-vertical,.video-js .vjs-volume-panel:focus .vjs-volume-control.vjs-volume-vertical{left:-3.5em;transition:left 0s}.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js .vjs-volume-panel.vjs-volume-panel-horizontal:active{width:9em;transition:width .1s}.video-js .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-mute-toggle-only{width:4em}.video-js .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical{height:8em;width:3em;left:-3000em;transition:visibility 1s,opacity 1s,height 1s 1s,width 1s 1s,left 1s 1s,top 1s 1s}.video-js .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal{transition:visibility 1s,opacity 1s,height 1s 1s,width 1s,left 1s 1s,top 1s 1s}.video-js.vjs-no-flex .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal{width:5em;height:3em;visibility:visible;opacity:1;position:relative;transition:none}.video-js.vjs-no-flex .vjs-volume-control.vjs-volume-vertical,.video-js.vjs-no-flex .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical{position:absolute;bottom:3em;left:.5em}.video-js .vjs-volume-panel{display:flex}.video-js .vjs-volume-bar{margin:1.35em .45em}.vjs-volume-bar.vjs-slider-horizontal{width:5em;height:.3em}.vjs-volume-bar.vjs-slider-vertical{width:.3em;height:5em;margin:1.35em auto}.video-js .vjs-volume-level{position:absolute;bottom:0;left:0;background-color:#fff}.video-js .vjs-volume-level:before{position:absolute;font-size:.9em}.vjs-slider-vertical .vjs-volume-level{width:.3em}.vjs-slider-vertical .vjs-volume-level:before{top:-.5em;left:-.3em}.vjs-slider-horizontal .vjs-volume-level{height:.3em}.vjs-slider-horizontal .vjs-volume-level:before{top:-.3em;right:-.5em}.video-js .vjs-volume-panel.vjs-volume-panel-vertical{width:4em}.vjs-volume-bar.vjs-slider-vertical .vjs-volume-level{height:100%}.vjs-volume-bar.vjs-slider-horizontal .vjs-volume-level{width:100%}.video-js .vjs-volume-vertical{width:3em;height:8em;bottom:8em;background-color:#2b333f;background-color:rgba(43,51,63,.7)}.video-js .vjs-volume-horizontal .vjs-menu{left:-2em}.vjs-poster{display:inline-block;vertical-align:middle;background-repeat:no-repeat;background-position:50% 50%;background-size:contain;background-color:#000;cursor:pointer;margin:0;padding:0;position:absolute;top:0;right:0;bottom:0;left:0;height:100%}.vjs-has-started .vjs-poster{display:none}.vjs-audio.vjs-has-started .vjs-poster{display:block}.vjs-using-native-controls .vjs-poster{display:none}.video-js .vjs-live-control{display:flex;align-items:flex-start;flex:auto;font-size:1em;line-height:3em}.vjs-no-flex .vjs-live-control{display:table-cell;width:auto;text-align:left}.video-js.vjs-liveui .vjs-live-control,.video-js:not(.vjs-live) .vjs-live-control{display:none}.video-js .vjs-seek-to-live-control{cursor:pointer;flex:none;display:inline-flex;height:100%;padding-left:.5em;padding-right:.5em;font-size:1em;line-height:3em;width:auto;min-width:4em}.vjs-no-flex .vjs-seek-to-live-control{display:table-cell;width:auto;text-align:left}.video-js.vjs-live:not(.vjs-liveui) .vjs-seek-to-live-control,.video-js:not(.vjs-live) .vjs-seek-to-live-control{display:none}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge{cursor:auto}.vjs-seek-to-live-control .vjs-icon-placeholder{margin-right:.5em;color:#888}.vjs-seek-to-live-control.vjs-control.vjs-at-live-edge .vjs-icon-placeholder{color:red}.video-js .vjs-time-control{flex:none;font-size:1em;line-height:3em;min-width:2em;width:auto;padding-left:1em;padding-right:1em}.video-js .vjs-current-time,.video-js .vjs-duration,.vjs-live .vjs-time-control,.vjs-no-flex .vjs-current-time,.vjs-no-flex .vjs-duration{display:none}.vjs-time-divider{display:none;line-height:3em}.vjs-live .vjs-time-divider{display:none}.video-js .vjs-play-control{cursor:pointer}.video-js .vjs-play-control .vjs-icon-placeholder{flex:none}.vjs-text-track-display{position:absolute;bottom:3em;left:0;right:0;top:0;pointer-events:none}.video-js.vjs-user-inactive.vjs-playing .vjs-text-track-display{bottom:1em}.video-js .vjs-text-track{font-size:1.4em;text-align:center;margin-bottom:.1em}.vjs-subtitles{color:#fff}.vjs-captions{color:#fc6}.vjs-tt-cue{display:block}video::-webkit-media-text-track-display{transform:translateY(-3em)}.video-js.vjs-user-inactive.vjs-playing video::-webkit-media-text-track-display{transform:translateY(-1.5em)}.video-js .vjs-fullscreen-control,.video-js .vjs-picture-in-picture-control{cursor:pointer;flex:none}.vjs-playback-rate .vjs-playback-rate-value,.vjs-playback-rate>.vjs-menu-button{position:absolute;top:0;left:0;width:100%;height:100%}.vjs-playback-rate .vjs-playback-rate-value{pointer-events:none;font-size:1.5em;line-height:2;text-align:center}.vjs-playback-rate .vjs-menu{width:4em;left:0}.vjs-error .vjs-error-display .vjs-modal-dialog-content{font-size:1.4em;text-align:center}.vjs-error .vjs-error-display:before{color:#fff;content:"X";font-family:Arial,Helvetica,sans-serif;font-size:4em;left:0;line-height:1;margin-top:-.5em;position:absolute;text-shadow:.05em .05em .1em #000;text-align:center;top:50%;vertical-align:middle;width:100%}.vjs-loading-spinner{display:none;position:absolute;top:50%;left:50%;margin:-25px 0 0 -25px;opacity:.85;text-align:left;border:6px solid rgba(43,51,63,.7);box-sizing:border-box;background-clip:padding-box;width:50px;height:50px;border-radius:25px;visibility:hidden}.vjs-seeking .vjs-loading-spinner,.vjs-waiting .vjs-loading-spinner{display:block;-webkit-animation:vjs-spinner-show 0s linear .3s forwards;animation:vjs-spinner-show 0s linear .3s forwards}.vjs-loading-spinner:after,.vjs-loading-spinner:before{content:"";position:absolute;margin:-6px;box-sizing:inherit;width:inherit;height:inherit;border-radius:inherit;opacity:1;border:inherit;border-color:transparent;border-top-color:#fff}.vjs-seeking .vjs-loading-spinner:after,.vjs-seeking .vjs-loading-spinner:before,.vjs-waiting .vjs-loading-spinner:after,.vjs-waiting .vjs-loading-spinner:before{-webkit-animation:vjs-spinner-spin 1.1s cubic-bezier(.6,.2,0,.8) infinite,vjs-spinner-fade 1.1s linear infinite;animation:vjs-spinner-spin 1.1s cubic-bezier(.6,.2,0,.8) infinite,vjs-spinner-fade 1.1s linear infinite}.vjs-seeking .vjs-loading-spinner:before,.vjs-waiting .vjs-loading-spinner:before{border-top-color:#fff}.vjs-seeking .vjs-loading-spinner:after,.vjs-waiting .vjs-loading-spinner:after{border-top-color:#fff;-webkit-animation-delay:.44s;animation-delay:.44s}@keyframes vjs-spinner-show{to{visibility:visible}}@-webkit-keyframes vjs-spinner-show{to{visibility:visible}}@keyframes vjs-spinner-spin{to{transform:rotate(1turn)}}@-webkit-keyframes vjs-spinner-spin{to{-webkit-transform:rotate(1turn)}}@keyframes vjs-spinner-fade{0%{border-top-color:#73859f}20%{border-top-color:#73859f}35%{border-top-color:#fff}60%{border-top-color:#73859f}to{border-top-color:#73859f}}@-webkit-keyframes vjs-spinner-fade{0%{border-top-color:#73859f}20%{border-top-color:#73859f}35%{border-top-color:#fff}60%{border-top-color:#73859f}to{border-top-color:#73859f}}.vjs-chapters-button .vjs-menu ul{width:24em}.video-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder{vertical-align:middle;display:inline-block;margin-bottom:-.1em}.video-js .vjs-subs-caps-button+.vjs-menu .vjs-captions-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before{font-family:VideoJS;content:"\\F10D";font-size:1.5em;line-height:inherit}.video-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder{vertical-align:middle;display:inline-block;margin-bottom:-.1em}.video-js .vjs-audio-button+.vjs-menu .vjs-main-desc-menu-item .vjs-menu-item-text .vjs-icon-placeholder:before{font-family:VideoJS;content:" \\F11D";font-size:1.5em;line-height:inherit}.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-audio-button,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-captions-button,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-chapters-button,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-current-time,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-descriptions-button,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-duration,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-playback-rate,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-remaining-time,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-subtitles-button,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-time-divider,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-volume-control,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-audio-button,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-captions-button,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-chapters-button,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-current-time,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-descriptions-button,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-duration,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-playback-rate,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-remaining-time,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-subtitles-button,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-time-divider,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-volume-control,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-audio-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-captions-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-chapters-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-current-time,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-descriptions-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-duration,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-playback-rate,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-remaining-time,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-subtitles-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-time-divider,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-volume-control{display:none}.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js:not(.vjs-fullscreen).vjs-layout-small .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-volume-panel.vjs-volume-panel-horizontal:hover,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal:active,.video-js:not(.vjs-fullscreen).vjs-layout-x-small .vjs-volume-panel.vjs-volume-panel-horizontal:hover{width:auto}.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-subs-caps-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small:not(.vjs-live) .vjs-subs-caps-button,.video-js:not(.vjs-fullscreen).vjs-layout-x-small:not(.vjs-liveui) .vjs-subs-caps-button{display:none}.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-custom-control-spacer,.video-js:not(.vjs-fullscreen).vjs-layout-x-small.vjs-liveui .vjs-custom-control-spacer{flex:auto;display:block}.video-js:not(.vjs-fullscreen).vjs-layout-tiny.vjs-no-flex .vjs-custom-control-spacer,.video-js:not(.vjs-fullscreen).vjs-layout-x-small.vjs-liveui.vjs-no-flex .vjs-custom-control-spacer{width:auto}.video-js:not(.vjs-fullscreen).vjs-layout-tiny .vjs-progress-control,.video-js:not(.vjs-fullscreen).vjs-layout-x-small.vjs-liveui .vjs-progress-control{display:none}.vjs-modal-dialog.vjs-text-track-settings{background-color:#2b333f;background-color:rgba(43,51,63,.75);color:#fff;height:70%}.vjs-text-track-settings .vjs-modal-dialog-content{display:table}.vjs-text-track-settings .vjs-track-settings-colors,.vjs-text-track-settings .vjs-track-settings-controls,.vjs-text-track-settings .vjs-track-settings-font{display:table-cell}.vjs-text-track-settings .vjs-track-settings-controls{text-align:right;vertical-align:bottom}@supports (display:grid){.vjs-text-track-settings .vjs-modal-dialog-content{display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr;padding:20px 24px 0}.vjs-track-settings-controls .vjs-default-button{margin-bottom:20px}.vjs-text-track-settings .vjs-track-settings-controls{grid-column:1/-1}.vjs-layout-small .vjs-text-track-settings .vjs-modal-dialog-content,.vjs-layout-tiny .vjs-text-track-settings .vjs-modal-dialog-content,.vjs-layout-x-small .vjs-text-track-settings .vjs-modal-dialog-content{grid-template-columns:1fr}}.vjs-track-setting>select{margin-right:1em;margin-bottom:.5em}.vjs-text-track-settings fieldset{margin:5px;padding:3px;border:none}.vjs-text-track-settings fieldset span{display:inline-block}.vjs-text-track-settings fieldset span>select{max-width:7.3em}.vjs-text-track-settings legend{color:#fff;margin:0 0 5px}.vjs-text-track-settings .vjs-label{position:absolute;clip:rect(1px 1px 1px 1px);clip:rect(1px,1px,1px,1px);display:block;margin:0 0 5px;padding:0;border:0;height:1px;width:1px;overflow:hidden}.vjs-track-settings-controls button:active,.vjs-track-settings-controls button:focus{outline-style:solid;outline-width:medium;background-image:linear-gradient(0deg,#fff 88%,#73859f)}.vjs-track-settings-controls button:hover{color:rgba(43,51,63,.75)}.vjs-track-settings-controls button{background-color:#fff;background-image:linear-gradient(-180deg,#fff 88%,#73859f);color:#2b333f;cursor:pointer;border-radius:2px}.vjs-track-settings-controls .vjs-default-button{margin-right:1em}@media print{.video-js>:not(.vjs-tech):not(.vjs-poster){visibility:hidden}}.vjs-resize-manager{position:absolute;top:0;left:0;width:100%;height:100%;border:none;z-index:-1000}.js-focus-visible .video-js :focus:not(.focus-visible),.video-js .vjs-menu :focus:not(:focus-visible),.video-js :focus:not(:focus-visible){outline:none;background:none}',""])},qPtA:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=n("B63G"),o=r.key,s=r.set;r.exp({metadata:function(e,t){return function(n,r){s(e,t,(void 0!==r?i:a)(n),o(r))}}})},qRfI:function(e,t,n){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},qRls:function(e,t,n){n("sGlJ")("WeakSet")},qYTp:function(e,t,n){"use strict";var r=n("eqAp"),i=n("Au7w"),a=n("Ee0C"),o=n("PGRs"),s=n("IfkE"),u=n("J5DO"),l=n("U9LJ"),c=n("vR0S").ArrayBuffer,d=n("8rdt"),f=a.ArrayBuffer,h=a.DataView,p=i.ABV&&c.isView,m=f.prototype.slice,v=i.VIEW;r(r.G+r.W+r.F*(c!==f),{ArrayBuffer:f}),r(r.S+r.F*!i.CONSTR,"ArrayBuffer",{isView:function(e){return p&&p(e)||l(e)&&v in e}}),r(r.P+r.U+r.F*n("HTem")(function(){return!new f(2).slice(1,void 0).byteLength}),"ArrayBuffer",{slice:function(e,t){if(void 0!==m&&void 0===t)return m.call(o(this),e);for(var n=o(this).byteLength,r=s(e,n),i=s(void 0===t?n:t,n),a=new(d(this,f))(u(i-r)),l=new h(this),c=new h(a),p=0;r<i;)c.setUint8(p++,l.getUint8(r++));return a}}),n("7QiM")("ArrayBuffer")},qvDY:function(e,t,n){var r=n("XjC+"),i=n("xWqz"),a=n("PGRs"),o=n("vR0S").Reflect;e.exports=o&&o.ownKeys||function(e){var t=r.f(a(e)),n=i.f;return n?t.concat(n(e)):t}},rBVO:function(e,t,n){var r=n("PGRs"),i=n("thuU"),a=n("E2U5"),o=Object.defineProperty;t.f=n("8yv5")?Object.defineProperty:function(e,t,n){if(r(e),t=a(t,!0),r(n),i)try{return o(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},rNRh:function(e,t,n){var r=n("6hGG")("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},rjj0:function(e,t,n){function r(e){for(var t=0;t<e.length;t++){var n=e[t],r=c[n.id];if(r){r.refs++;for(var i=0;i<r.parts.length;i++)r.parts[i](n.parts[i]);for(;i<n.parts.length;i++)r.parts.push(a(n.parts[i]));r.parts.length>n.parts.length&&(r.parts.length=n.parts.length)}else{for(var o=[],i=0;i<n.parts.length;i++)o.push(a(n.parts[i]));c[n.id]={id:n.id,refs:1,parts:o}}}}function i(){var e=document.createElement("style");return e.type="text/css",d.appendChild(e),e}function a(e){var t,n,r=document.querySelector("style["+g+'~="'+e.id+'"]');if(r){if(p)return m;r.parentNode.removeChild(r)}if(y){var a=h++;r=f||(f=i()),t=o.bind(null,r,a,!1),n=o.bind(null,r,a,!0)}else r=i(),t=s.bind(null,r),n=function(){r.parentNode.removeChild(r)};return t(e),function(r){if(r){if(r.css===e.css&&r.media===e.media&&r.sourceMap===e.sourceMap)return;t(e=r)}else n()}}function o(e,t,n,r){var i=n?"":r.css;if(e.styleSheet)e.styleSheet.cssText=_(t,i);else{var a=document.createTextNode(i),o=e.childNodes;o[t]&&e.removeChild(o[t]),o.length?e.insertBefore(a,o[t]):e.appendChild(a)}}function s(e,t){var n=t.css,r=t.media,i=t.sourceMap;if(r&&e.setAttribute("media",r),v.ssrId&&e.setAttribute(g,t.id),i&&(n+="\n/*# sourceURL="+i.sources[0]+" */",n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */"),e.styleSheet)e.styleSheet.cssText=n;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}var u="undefined"!=typeof document;if("undefined"!=typeof DEBUG&&DEBUG&&!u)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var l=n("tTVk"),c={},d=u&&(document.head||document.getElementsByTagName("head")[0]),f=null,h=0,p=!1,m=function(){},v=null,g="data-vue-ssr-id",y="undefined"!=typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());e.exports=function(e,t,n,i){p=n,v=i||{};var a=l(e,t);return r(a),function(t){for(var n=[],i=0;i<a.length;i++){var o=a[i],s=c[o.id];s.refs--,n.push(s)}t?(a=l(e,t),r(a)):a=[];for(var i=0;i<n.length;i++){var s=n[i];if(0===s.refs){for(var u=0;u<s.parts.length;u++)s.parts[u]();delete c[s.id]}}}};var _=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}()},rkP2:function(e,t,n){var r=n("eqAp"),i=n("qvDY"),a=n("xpmJ"),o=n("gWbE"),s=n("RvsJ");r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,r=a(e),u=o.f,l=i(r),c={},d=0;l.length>d;)void 0!==(n=u(r,t=l[d++]))&&s(c,t,n);return c}})},rny3:function(e,t,n){var r=n("rBVO").f,i=Function.prototype,a=/^\s*function ([^ (]*)/;"name"in i||n("8yv5")&&r(i,"name",{configurable:!0,get:function(){try{return(""+this).match(a)[1]}catch(e){return""}}})},rpfS:function(e,t,n){n("2+22")("Int32",4,function(e){return function(t,n,r){return e(this,t,n,r)}})},s133:function(e,t,n){var r=n("VpOn"),i=n("PGRs"),a=r.key,o=r.map,s=r.store;r.exp({deleteMetadata:function(e,t){var n=arguments.length<3?void 0:a(arguments[2]),r=o(i(t),n,!1);if(void 0===r||!r.delete(e))return!1;if(r.size)return!0;var u=s.get(t);return u.delete(n),!!u.size||s.delete(t)}})},sDxg:function(e,t,n){n("2+22")("Uint16",2,function(e){return function(t,n,r){return e(this,t,n,r)}})},sGlJ:function(e,t,n){"use strict";var r=n("eqAp"),i=n("B63G"),a=n("wRig"),o=n("VLJK");e.exports=function(e){r(r.S,e,{from:function(e){var t,n,r,s,u=arguments[1];return i(this),t=void 0!==u,t&&i(u),void 0==e?new this:(n=[],t?(r=0,s=a(u,arguments[2],2),o(e,!1,function(e){n.push(s(e,r++))})):o(e,!1,n.push,n),new this(n))}})}},sWxu:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{log10:function(e){return Math.log(e)*Math.LOG10E}})},sbdb:function(e,t,n){"use strict";var r=n("sxvG"),i=n("VmoO");e.exports=function(e){var t=String(i(this)),n="",a=r(e);if(a<0||a==1/0)throw RangeError("Count can't be negative");for(;a>0;(a>>>=1)&&(t+=t))1&a&&(n+=t);return n}},"spe/":function(e,t,n){var r=n("3ty/"),i=n("AeeY"),a=n("9dbO")("IE_PROTO"),o=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=i(e),r(e,a)?e[a]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?o:null}},sxvG:function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},t4zo:function(e,t,n){(function(n){var r,i,a;!function(n,o){i=[],r=o,void 0!==(a="function"==typeof r?r.apply(t,i):r)&&(e.exports=a)}(0,function(){"use strict";function t(e,t){return void 0===t?t={autoBom:!1}:"object"!=typeof t&&(console.warn("Deprecated: Expected third argument to be a object"),t={autoBom:!t}),t.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\ufeff",e],{type:e.type}):e}function r(e,t,n){var r=new XMLHttpRequest;r.open("GET",e),r.responseType="blob",r.onload=function(){s(r.response,t,n)},r.onerror=function(){console.error("could not download file")},r.send()}function i(e){var t=new XMLHttpRequest;return t.open("HEAD",e,!1),t.send(),200<=t.status&&299>=t.status}function a(e){try{e.dispatchEvent(new MouseEvent("click"))}catch(n){var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}var o="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof n&&n.global===n?n:void 0,s=o.saveAs||("object"!=typeof window||window!==o?function(){}:"download"in HTMLAnchorElement.prototype?function(e,t,n){var s=o.URL||o.webkitURL,u=document.createElement("a");t=t||e.name||"download",u.download=t,u.rel="noopener","string"==typeof e?(u.href=e,u.origin===location.origin?a(u):i(u.href)?r(e,t,n):a(u,u.target="_blank")):(u.href=s.createObjectURL(e),setTimeout(function(){s.revokeObjectURL(u.href)},4e4),setTimeout(function(){a(u)},0))}:"msSaveOrOpenBlob"in navigator?function(e,n,o){if(n=n||e.name||"download","string"!=typeof e)navigator.msSaveOrOpenBlob(t(e,o),n);else if(i(e))r(e,n,o);else{var s=document.createElement("a");s.href=e,s.target="_blank",setTimeout(function(){a(s)})}}:function(e,t,n,i){if(i=i||open("","_blank"),i&&(i.document.title=i.document.body.innerText="downloading..."),"string"==typeof e)return r(e,t,n);var a="application/octet-stream"===e.type,s=/constructor/i.test(o.HTMLElement)||o.safari,u=/CriOS\/[\d]+/.test(navigator.userAgent);if((u||a&&s)&&"object"==typeof FileReader){var l=new FileReader;l.onloadend=function(){var e=l.result;e=u?e:e.replace(/^data:[^;]*;/,"data:attachment/file;"),i?i.location.href=e:location=e,i=null},l.readAsDataURL(e)}else{var c=o.URL||o.webkitURL,d=c.createObjectURL(e);i?i.location=d:location.href=d,i=null,setTimeout(function(){c.revokeObjectURL(d)},4e4)}});o.saveAs=s.saveAs=s,void 0!==e&&(e.exports=s)})}).call(t,n("DuR2"))},t8qj:function(e,t,n){"use strict";e.exports=function(e,t,n,r,i){return e.config=t,n&&(e.code=n),e.request=r,e.response=i,e}},tBo3:function(e,t,n){n("YQk9")("Map")},tBsZ:function(e,t){e.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},tIFN:function(e,t,n){"use strict";function r(e){var t=new o(e),n=a(o.prototype.request,t);return i.extend(n,o.prototype,t),i.extend(n,t),n}var i=n("cGG2"),a=n("JP+z"),o=n("XmWM"),s=n("KCLY"),u=r(s);u.Axios=o,u.create=function(e){return r(i.merge(s,e))},u.Cancel=n("dVOP"),u.CancelToken=n("cWxy"),u.isCancel=n("pBtG"),u.all=function(e){return Promise.all(e)},u.spread=n("pxG4"),e.exports=u,e.exports.default=u},tTVk:function(e,t){e.exports=function(e,t){for(var n=[],r={},i=0;i<t.length;i++){var a=t[i],o=a[0],s=a[1],u=a[2],l=a[3],c={id:e+":"+i,css:s,media:u,sourceMap:l};r[o]?r[o].parts.push(c):n.push(r[o]={id:o,parts:[c]})}return n}},tUVG:function(e,t,n){var r=n("eqAp"),i=n("PcBk");r(r.P+r.F*(Date.prototype.toISOString!==i),"Date",{toISOString:i})},thJu:function(e,t,n){"use strict";function r(){this.message="String contains an invalid character"}function i(e){for(var t,n,i=String(e),o="",s=0,u=a;i.charAt(0|s)||(u="=",s%1);o+=u.charAt(63&t>>8-s%1*8)){if((n=i.charCodeAt(s+=.75))>255)throw new r;t=t<<8|n}return o}var a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";r.prototype=new Error,r.prototype.code=5,r.prototype.name="InvalidCharacterError",e.exports=i},thYL:function(e,t,n){"use strict";n("48Hh")("bold",function(e){return function(){return e(this,"b","","")}})},thuU:function(e,t,n){e.exports=!n("8yv5")&&!n("HTem")(function(){return 7!=Object.defineProperty(n("nixg")("div"),"a",{get:function(){return 7}}).a})},ttMd:function(e,t){e.exports=Math.log1p||function(e){return(e=+e)>-1e-8&&e<1e-8?e-e*e/2:Math.log(1+e)}},uDdG:function(e,t,n){var r=n("eqAp");r(r.S,"Reflect",{has:function(e,t){return t in e}})},uhbZ:function(e,t,n){var r=n("eqAp");r(r.P,"String",{repeat:n("sbdb")})},"ujn+":function(e,t){e.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},"uyI+":function(e,t,n){var r=n("AeeY"),i=n("/dY/");n("Iiwq")("keys",function(){return function(e){return i(r(e))}})},vATM:function(e,t,n){n("87Ux"),n("X1d6"),n("eu0Z"),n("Eseb"),n("CYr4"),n("QFL/"),n("uyI+"),n("jfqE"),n("6Nc+"),n("kKiV"),n("3gWO"),n("Xqrs"),n("bleF"),n("5gDf"),n("Sl8e"),n("EqqB"),n("LMcF"),n("NzmX"),n("GBLZ"),n("rny3"),n("Ta4Y"),n("Uz1t"),n("lHtY"),n("7hWC"),n("Whqc"),n("fvVZ"),n("QU4K"),n("Vk48"),n("EmrZ"),n("VEfk"),n("2gXL"),n("n1Fu"),n("Qagw"),n("cdBD"),n("1oJE"),n("y0q8"),n("dXsE"),n("5EKM"),n("oSrZ"),n("RqJ/"),n("FAzY"),n("8ApB"),n("V8Cm"),n("X8tW"),n("Gc7k"),n("sWxu"),n("d8xy"),n("LC+M"),n("h86t"),n("noA0"),n("nFL/"),n("26gs"),n("77Mz"),n("Q2xf"),n("OnBH"),n("JCOx"),n("ESkD"),n("X0LW"),n("/w37"),n("uhbZ"),n("N4VP"),n("Uk5j"),n("yNP9"),n("TU7o"),n("thYL"),n("Y+OG"),n("1SZZ"),n("/CZk"),n("HRXJ"),n("JSYz"),n("YHsq"),n("MkYW"),n("IahY"),n("H97Y"),n("y5Zd"),n("3CFP"),n("tUVG"),n("TsdC"),n("AtpX"),n("yyHQ"),n("qHaP"),n("CMSL"),n("TaU0"),n("QzD4"),n("J0zq"),n("vLj9"),n("LN0b"),n("Akkh"),n("7oKK"),n("i4QR"),n("FtQo"),n("jYoD"),n("mXza"),n("IGk/"),n("46HX"),n("FWVt"),n("9XDH"),n("IE6n"),n("AX+V"),n("K0e4"),n("IS1/"),n("Y94b"),n("NKNJ"),n("8VQU"),n("Gkho"),n("8gt8"),n("kfMr"),n("QV+U"),n("5NQZ"),n("YGNL"),n("W8W2"),n("L1YH"),n("bKMx"),n("qYTp"),n("QRrs"),n("3TcY"),n("mK6O"),n("YsJ8"),n("lkrK"),n("sDxg"),n("rpfS"),n("gzYr"),n("Mlxs"),n("4gN1"),n("lCha"),n("LiyF"),n("D8lc"),n("935F"),n("MAG8"),n("TLNA"),n("3tLj"),n("acbg"),n("uDdG"),n("cAN6"),n("Wfy6"),n("w3cP"),n("ZLYQ"),n("A0jK"),n("NQ5z"),n("wzsE"),n("VlEH"),n("IjnQ"),n("dkvW"),n("L3my"),n("oJlE"),n("yZU5"),n("hG4L"),n("oZJn"),n("JwEh"),n("rkP2"),n("17/W"),n("H7V+"),n("kruC"),n("fPV+"),n("QzFE"),n("G26h"),n("EyN7"),n("xe3j"),n("tBo3"),n("JPCZ"),n("0W8K"),n("GFPg"),n("2R19"),n("x3L7"),n("gGS/"),n("qRls"),n("fYR6"),n("XWLd"),n("DfOq"),n("Mw4q"),n("iUoc"),n("HdM2"),n("KS3q"),n("3K1F"),n("6kKt"),n("bBPJ"),n("Vdun"),n("aGYi"),n("x9oa"),n("iqo/"),n("Egxl"),n("vNZZ"),n("YTGC"),n("+hPR"),n("s133"),n("JVxX"),n("cL5L"),n("R2Uq"),n("psjt"),n("WsP5"),n("Xd2u"),n("qPtA"),n("4TB0"),n("PaZz"),n("Vm8t"),n("E5Nd"),n("G+F0"),e.exports=n("QhVj")},vLj9:function(e,t,n){"use strict";var r=n("eqAp"),i=n("Q2Ff")(0),a=n("+qBm")([].forEach,!0);r(r.P+r.F*!a,"Array",{forEach:function(e){return i(this,e,arguments[1])}})},vNZZ:function(e,t,n){"use strict";var r=n("eqAp"),i=n("QhVj"),a=n("vR0S"),o=n("8rdt"),s=n("4WJq");r(r.P+r.R,"Promise",{finally:function(e){var t=o(this,i.Promise||a.Promise),n="function"==typeof e;return this.then(n?function(n){return s(t,e()).then(function(){return n})}:e,n?function(n){return s(t,e()).then(function(){throw n})}:e)}})},vR0S:function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},w3cP:function(e,t,n){var r=n("eqAp"),i=n("PGRs"),a=Object.preventExtensions;r(r.S,"Reflect",{preventExtensions:function(e){i(e);try{return a&&a(e),!0}catch(e){return!1}}})},wNcl:function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},wRig:function(e,t,n){var r=n("B63G");e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,i){return e.call(t,n,r,i)}}return function(){return e.apply(t,arguments)}}},wzsE:function(e,t,n){"use strict";var r=n("eqAp"),i=n("BHN6"),a=n("AeeY"),o=n("J5DO"),s=n("B63G"),u=n("9nZh");r(r.P,"Array",{flatMap:function(e){var t,n,r=a(this);return s(e),t=o(r.length),n=u(r,0),i(n,r,r,t,0,1,e,arguments[1]),n}}),n("5BZE")("flatMap")},x3L7:function(e,t,n){n("sGlJ")("Set")},x9oa:function(e,t,n){var r=n("eqAp");r(r.S,"Math",{scale:n("PbK0")})},"xH/3":function(e,t,n){var r=n("xpmJ"),i=n("XjC+").f,a={}.toString,o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(e){try{return i(e)}catch(e){return o.slice()}};e.exports.f=function(e){return o&&"[object Window]"==a.call(e)?s(e):i(r(e))}},xLtR:function(e,t,n){"use strict";function r(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var i=n("cGG2"),a=n("TNV1"),o=n("pBtG"),s=n("KCLY"),u=n("dIwP"),l=n("qRfI");e.exports=function(e){return r(e),e.baseURL&&!u(e.url)&&(e.url=l(e.baseURL,e.url)),e.headers=e.headers||{},e.data=a(e.data,e.headers,e.transformRequest),e.headers=i.merge(e.headers.common||{},e.headers[e.method]||{},e.headers||{}),i.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]}),(e.adapter||s.adapter)(e).then(function(t){return r(e),t.data=a(t.data,t.headers,e.transformResponse),t},function(t){return o(t)||(r(e),t&&t.response&&(t.response.data=a(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})}},xU4Q:function(e,t,n){var r=n("vR0S"),i=n("QhVj"),a=n("G3Gk"),o=n("nbAL"),s=n("rBVO").f;e.exports=function(e){var t=i.Symbol||(i.Symbol=a?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||s(t,e,{value:o.f(e)})}},xWqz:function(e,t){t.f=Object.getOwnPropertySymbols},xe3j:function(e,t,n){var r=n("eqAp");r(r.P+r.R,"Set",{toJSON:n("j/BO")("Set")})},xfkl:function(e,t,n){"use strict";var r=n("B63G"),i=n("U9LJ"),a=n("ujn+"),o=[].slice,s={},u=function(e,t,n){if(!(t in s)){for(var r=[],i=0;i<t;i++)r[i]="a["+i+"]";s[t]=Function("F,a","return new F("+r.join(",")+")")}return s[t](e,n)};e.exports=Function.bind||function(e){var t=r(this),n=o.call(arguments,1),s=function(){var r=n.concat(o.call(arguments));return this instanceof s?u(t,r.length,r):a(t,r,e)};return i(t.prototype)&&(s.prototype=t.prototype),s}},xfzY:function(e,t){e.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},xnnD:function(e,t){e.exports={}},xpmJ:function(e,t,n){var r=n("6VhL"),i=n("VmoO");e.exports=function(e){return r(i(e))}},y0q8:function(e,t,n){var r=n("eqAp"),i=n("ttMd"),a=Math.sqrt,o=Math.acosh;r(r.S+r.F*!(o&&710==Math.floor(o(Number.MAX_VALUE))&&o(1/0)==1/0),"Math",{acosh:function(e){return(e=+e)<1?NaN:e>94906265.62425156?Math.log(e)+Math.LN2:i(e-1+a(e-1)*a(e+1))}})},y5Zd:function(e,t,n){var r=n("eqAp");r(r.S,"Date",{now:function(){return(new Date).getTime()}})},yFfH:function(e,t,n){"use strict";function r(e){n("FD60")}var i=n("Nqrn"),a=n("535S"),o=n("VU/8"),s=r,u=o(i.a,a.a,!1,s,null,null);t.a=u.exports},yNP9:function(e,t,n){"use strict";n("48Hh")("big",function(e){return function(){return e(this,"big","","")}})},yZU5:function(e,t,n){"use strict";n("XOiX")("trimRight",function(e){return function(){return e(this,2)}},"trimEnd")},yyHQ:function(e,t,n){var r=n("eqAp");r(r.S,"Array",{isArray:n("lwhV")})},zkX4:function(e,t,n){(function(t){!function(t){"use strict";function n(e,t,n,r){var a=t&&t.prototype instanceof i?t:i,o=Object.create(a.prototype),s=new h(r||[]);return o._invoke=l(e,n,s),o}function r(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}function i(){}function a(){}function o(){}function s(e){["next","throw","return"].forEach(function(t){e[t]=function(e){return this._invoke(t,e)}})}function u(e){function n(t,i,a,o){var s=r(e[t],e,i);if("throw"!==s.type){var u=s.arg,l=u.value;return l&&"object"==typeof l&&y.call(l,"__await")?Promise.resolve(l.__await).then(function(e){n("next",e,a,o)},function(e){n("throw",e,a,o)}):Promise.resolve(l).then(function(e){u.value=e,a(u)},o)}o(s.arg)}function i(e,t){function r(){return new Promise(function(r,i){n(e,t,r,i)})}return a=a?a.then(r,r):r()}"object"==typeof t.process&&t.process.domain&&(n=t.process.domain.bind(n));var a;this._invoke=i}function l(e,t,n){var i=E;return function(a,o){if(i===C)throw new Error("Generator is already running");if(i===L){if("throw"===a)throw o;return m()}for(n.method=a,n.arg=o;;){var s=n.delegate;if(s){var u=c(s,n);if(u){if(u===x)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(i===E)throw i=L,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);i=C;var l=r(e,t,n);if("normal"===l.type){if(i=n.done?L:A,l.arg===x)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(i=L,n.method="throw",n.arg=l.arg)}}}function c(e,t){var n=e.iterator[t.method];if(n===v){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=v,c(e,t),"throw"===t.method))return x;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return x}var i=r(n,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,x;var a=i.arg;return a?a.done?(t[e.resultName]=a.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=v),t.delegate=null,x):a:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,x)}function d(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function f(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function h(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(d,this),this.reset(!0)}function p(e){if(e){var t=e[b];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var n=-1,r=function t(){for(;++n<e.length;)if(y.call(e,n))return t.value=e[n],t.done=!1,t;return t.value=v,t.done=!0,t};return r.next=r}}return{next:m}}function m(){return{value:v,done:!0}}var v,g=Object.prototype,y=g.hasOwnProperty,_="function"==typeof Symbol?Symbol:{},b=_.iterator||"@@iterator",T=_.asyncIterator||"@@asyncIterator",S=_.toStringTag||"@@toStringTag",w="object"==typeof e,k=t.regeneratorRuntime;if(k)return void(w&&(e.exports=k));k=t.regeneratorRuntime=w?e.exports:{},k.wrap=n;var E="suspendedStart",A="suspendedYield",C="executing",L="completed",x={},j={};j[b]=function(){return this};var O=Object.getPrototypeOf,I=O&&O(O(p([])));I&&I!==g&&y.call(I,b)&&(j=I);var P=o.prototype=i.prototype=Object.create(j);a.prototype=P.constructor=o,o.constructor=a,o[S]=a.displayName="GeneratorFunction",k.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===a||"GeneratorFunction"===(t.displayName||t.name))},k.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,o):(e.__proto__=o,S in e||(e[S]="GeneratorFunction")),e.prototype=Object.create(P),e},k.awrap=function(e){return{__await:e}},s(u.prototype),u.prototype[T]=function(){return this},k.AsyncIterator=u,k.async=function(e,t,r,i){var a=new u(n(e,t,r,i));return k.isGeneratorFunction(t)?a:a.next().then(function(e){return e.done?e.value:a.next()})},s(P),P[S]="Generator",P[b]=function(){return this},P.toString=function(){return"[object Generator]"},k.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},k.values=p,h.prototype={constructor:h,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=v,this.done=!1,this.delegate=null,this.method="next",this.arg=v,this.tryEntries.forEach(f),!e)for(var t in this)"t"===t.charAt(0)&&y.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=v)},stop:function(){this.done=!0;var e=this.tryEntries[0],t=e.completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){function t(t,r){return a.type="throw",a.arg=e,n.next=t,r&&(n.method="next",n.arg=v),!!r}if(this.done)throw e;for(var n=this,r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r],a=i.completion;if("root"===i.tryLoc)return t("end");if(i.tryLoc<=this.prev){var o=y.call(i,"catchLoc"),s=y.call(i,"finallyLoc");if(o&&s){if(this.prev<i.catchLoc)return t(i.catchLoc,!0);if(this.prev<i.finallyLoc)return t(i.finallyLoc)}else if(o){if(this.prev<i.catchLoc)return t(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return t(i.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&y.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var i=r;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,x):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),x},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),f(n),x}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;f(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:p(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=v),x}}}("object"==typeof t?t:"object"==typeof window?window:"object"==typeof self?self:this)}).call(t,n("DuR2"))},znM9:function(e,t,n){t=e.exports=n("FZ+f")(void 0),t.push([e.i,'.video-wrapper .show-time .video-js .vjs-time-control:not(.vjs-remaining-time){padding-left:.5em;padding-right:0;min-width:0;display:block}.video-wrapper .video-js .vjs-remaining-time{display:none}.video-wrapper .live .vjs-progress-control{visibility:hidden}.video-wrapper .av-loading .vjs-big-play-button,.video-wrapper .live .vjs-remaining-time,.video-wrapper .live .vjs-time-control{display:none}.video-wrapper .hide-waiting .vjs-seeking .vjs-loading-spinner,.video-wrapper .hide-waiting .vjs-waiting .vjs-loading-spinner{display:none!important}.video-wrapper .alt{position:absolute;left:0;top:0;right:0;bottom:0;background:#000;color:#fff;text-align:center}.video-wrapper .alt>table{width:100%;height:100%}.video-wrapper .alt>table tr>td{vertical-align:middle}.video-wrapper .alt>img{width:100%;height:100%}.video-wrapper .video-js .video-slot{font-size:14px}.video-wrapper .video-js .video-title{font-size:14px;position:absolute;top:5px;right:5px;color:#fff;background-color:hsla(0,0%,50%,.5);border-radius:2px;padding:5px;max-width:120px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.video-wrapper .video-js .vjs-control-bar .vjs-button{cursor:pointer;outline:none}.video-wrapper .video-js .vjs-control-bar .vjs-icon-spinner:before{font-size:1.4em;line-height:1.87}.video-wrapper .vjs-error-display{display:none}.video-wrapper .video-js .vjs-time-control{font-size:1.035em;line-height:2.93em}.video-wrapper .vjs-resolution-button{color:#ccc;font-family:VideoJS}.video-wrapper .vjs-resolution-button .vjs-resolution-button-staticlabel:before{content:"\\F110";font-size:1.8em;line-height:1.7em}.video-wrapper .vjs-resolution-button .vjs-resolution-button-label{width:100%;height:.6em;display:block!important}.video-wrapper .vjs-resolution-button .vjs-resolution-button-label-ie{width:100%;height:.4em;display:block!important}.video-wrapper .vjs-resolution-button ul.vjs-menu-content{width:4em!important}.video-wrapper .vjs-resolution-button .vjs-menu{left:0}.video-wrapper .vjs-resolution-button .vjs-menu li{text-transform:none;font-size:1em;line-height:1.5em;font-family:Arial,Helvetica,sans-serif}.video-wrapper .vjs-audio-button{display:none!important}.video-wrapper .video-js .vjs-big-play-button .vjs-icon-placeholder:before,.video-wrapper .vjs-button>.vjs-icon-placeholder:before{position:relative!important}.video-wrapper .video-js .vjs-play-progress:before{top:-.33em!important}@media screen and (-webkit-min-device-pixel-ratio:0){.video-wrapper .video-js .vjs-control-bar{font-size:14px}.video-wrapper .video-js .vjs-slider-vertical .vjs-volume-level:before{left:-.33em!important}}',""])}});