/*! For license information please see 2.4b11d035.chunk.js.LICENSE.txt */ (this["webpackJsonpsession-dash"]=this["webpackJsonpsession-dash"]||[]).push([[2],[function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(1),i={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},o=r.createContext&&r.createContext(i),a=function(){return(a=Object.assign||function(e){for(var t,n=1,r=arguments.length;n=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}},function(e,t,n){e.exports=n(642)},function(e,t,n){e.exports=n(1565)()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(9);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t1?t-1:0),r=1;r0?" Args: "+n.join(", "):""))}var O=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,n=0;n=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,i=r;e>=i;)(i<<=1)<0&&E(16,""+e);this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var o=r;o=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],r=this.indexOfGroup(e),i=r+n,o=r;o=0;n--){var r=t[n];if(r&&1===r.nodeType&&r.hasAttribute(S))return r}}(n),o=void 0!==i?i.nextSibling:null;r.setAttribute(S,"active"),r.setAttribute("data-styled-version","5.3.0");var a=L();return a&&r.setAttribute("nonce",a),n.insertBefore(r,o),r},z=function(){function e(e){var t=this.element=B(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n=0){var n=document.createTextNode(t),r=this.nodes[e];return this.element.insertBefore(n,r||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e0&&(u+=e+",")})),r+=""+s+c+'{content:"'+u+'"}/*!sc*/\n'}}}return r}(this)},e}(),H=/(a)(d)/gi,K=function(e){return String.fromCharCode(e+(e>25?39:97))};function Z(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=K(t%52)+n;return(K(t%52)+n).replace(H,"$1-$2")}var G=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},X=function(e){return G(5381,e)};function Y(e){for(var t=0;t>>0);if(!t.hasNameForId(r,a)){var s=n(o,"."+a,void 0,r);t.insertRules(r,a,s)}i.push(a),this.staticRulesId=a}else{for(var c=this.rules.length,u=G(this.baseHash,n.hash),l="",d=0;d>>0);if(!t.hasNameForId(r,m)){var g=n(l,"."+m,void 0,r);t.insertRules(r,m,g)}i.push(m)}}return i.join(" ")},e}(),Q=/^\s*\/\/.*$/gm,ee=[":","[",".","#"];function te(e){var t,n,r,i,o=void 0===e?v:e,a=o.options,s=void 0===a?v:a,u=o.plugins,l=void 0===u?g:u,d=new c.a(s),f=[],h=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(n,r,i,o,a,s,c,u,l,d){switch(n){case 1:if(0===l&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===u)return r+"/*|*/";break;case 3:switch(u){case 102:case 112:return e(i[0]+r),"";default:return r+(0===d?"/*|*/":"")}case-2:r.split("/*|*/}").forEach(t)}}}((function(e){f.push(e)})),p=function(e,r,o){return 0===r&&-1!==ee.indexOf(o[n.length])||o.match(i)?e:"."+t};function m(e,o,a,s){void 0===s&&(s="&");var c=e.replace(Q,""),u=o&&a?a+" "+o+" { "+c+" }":c;return t=s,n=o,r=new RegExp("\\"+n+"\\b","g"),i=new RegExp("(\\"+n+"\\b){2,}"),d(a||!o?"":o,u)}return d.use([].concat(l,[function(e,t,i){2===e&&i.length&&i[0].lastIndexOf(n)>0&&(i[0]=i[0].replace(r,p))},h,function(e){if(-2===e){var t=f;return f=[],t}}])),m.hash=l.length?l.reduce((function(e,t){return t.name||E(15),G(e,t.name)}),5381).toString():"",m}var ne=o.a.createContext(),re=(ne.Consumer,o.a.createContext()),ie=(re.Consumer,new W),oe=te();function ae(){return Object(i.useContext)(ne)||ie}function se(){return Object(i.useContext)(re)||oe}function ce(e){var t=Object(i.useState)(e.stylisPlugins),n=t[0],r=t[1],a=ae(),c=Object(i.useMemo)((function(){var t=a;return e.sheet?t=e.sheet:e.target&&(t=t.reconstructWithOptions({target:e.target},!1)),e.disableCSSOMInjection&&(t=t.reconstructWithOptions({useCSSOMInjection:!1})),t}),[e.disableCSSOMInjection,e.sheet,e.target]),u=Object(i.useMemo)((function(){return te({options:{prefix:!e.disableVendorPrefixes},plugins:n})}),[e.disableVendorPrefixes,n]);return Object(i.useEffect)((function(){s()(n,e.stylisPlugins)||r(e.stylisPlugins)}),[e.stylisPlugins]),o.a.createElement(ne.Provider,{value:c},o.a.createElement(re.Provider,{value:u},e.children))}var ue=function(){function e(e,t){var n=this;this.inject=function(e,t){void 0===t&&(t=oe);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"))},this.toString=function(){return E(12,String(n.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t}return e.prototype.getName=function(e){return void 0===e&&(e=oe),this.name+e.hash},e}(),le=/([A-Z])/,de=/([A-Z])/g,fe=/^ms-/,he=function(e){return"-"+e.toLowerCase()};function pe(e){return le.test(e)?e.replace(de,he).replace(fe,"-ms-"):e}var me=function(e){return null==e||!1===e||""===e};function ge(e,t,n,r){if(Array.isArray(e)){for(var i,o=[],a=0,s=e.length;a1?t-1:0),r=1;r?@[\\\]^`{|}~-]+/g,we=/(^-|-$)/g;function Se(e){return e.replace(ye,"-").replace(we,"")}var _e=function(e){return Z(X(e)>>>0)};function ke(e){return"string"==typeof e&&!0}var xe=function(e){return"function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},Ee=function(e){return"__proto__"!==e&&"constructor"!==e&&"prototype"!==e};function Oe(e,t,n){var r=e[n];xe(t)&&xe(r)?Me(r,t):e[n]=t}function Me(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r=0||(i[n]=e[n]);return i}(t,["componentId"]),o=r&&r+"-"+(ke(e)?e:Se(y(e)));return Ie(e,h({},i,{attrs:_,componentId:o}),n)},Object.defineProperty(x,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(t){this._foldedDefaultProps=r?Me({},e.defaultProps,t):t}}),x.toString=function(){return"."+x.styledComponentId},a&&f()(x,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),x}var Pe=function(e){return function e(t,n,i){if(void 0===i&&(i=v),!Object(r.isValidElementType)(n))return E(1,String(n));var o=function(){return t(n,i,ve.apply(void 0,arguments))};return o.withConfig=function(r){return e(t,n,h({},i,{},r))},o.attrs=function(r){return e(t,n,h({},i,{attrs:Array.prototype.concat(i.attrs,r).filter(Boolean)}))},o}(Ie,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach((function(e){Pe[e]=Pe(e)}));var Re=function(){function e(e,t){this.rules=e,this.componentId=t,this.isStatic=Y(e),W.registerId(this.componentId+1)}var t=e.prototype;return t.createStyles=function(e,t,n,r){var i=r(ge(this.rules,t,n,r).join(""),""),o=this.componentId+e;n.insertRules(o,o,i)},t.removeStyles=function(e,t){t.clearRules(this.componentId+e)},t.renderStyles=function(e,t,n,r){e>2&&W.registerId(this.componentId+e),this.removeStyles(e,n),this.createStyles(e,t,n,r)},e}();function De(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r1?t-1:0),r=1;r"+t+""},this.getStyleTags=function(){return e.sealed?E(2):e._emitSheetCSS()},this.getStyleElement=function(){var t;if(e.sealed)return E(2);var n=((t={})[S]="",t["data-styled-version"]="5.3.0",t.dangerouslySetInnerHTML={__html:e.instance.toString()},t),r=L();return r&&(n.nonce=r),[o.a.createElement("style",h({},n,{key:"sc-0-0"}))]},this.seal=function(){e.sealed=!0},this.instance=new W({isServer:!0}),this.sealed=!1}var t=e.prototype;t.collectStyles=function(e){return this.sealed?E(2):o.a.createElement(ce,{sheet:this.instance},e)},t.interleaveWithNodeStream=function(e){return E(3)}}();t.d=Pe}).call(this,n(81))},function(e,t,n){"use strict";function r(e,t){if(t.length1?"s":"")+" required, but only "+t.length+" present")}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.r(t),n.d(t,"hexToRgb",(function(){return r.h})),n.d(t,"rgbToHex",(function(){return r.l})),n.d(t,"hslToRgb",(function(){return r.i})),n.d(t,"decomposeColor",(function(){return r.c})),n.d(t,"recomposeColor",(function(){return r.k})),n.d(t,"getContrastRatio",(function(){return r.f})),n.d(t,"getLuminance",(function(){return r.g})),n.d(t,"emphasize",(function(){return r.d})),n.d(t,"fade",(function(){return r.e})),n.d(t,"alpha",(function(){return r.a})),n.d(t,"darken",(function(){return r.b})),n.d(t,"lighten",(function(){return r.j})),n.d(t,"createTheme",(function(){return i.b})),n.d(t,"createMuiTheme",(function(){return i.a})),n.d(t,"unstable_createMuiStrictModeTheme",(function(){return a})),n.d(t,"createStyles",(function(){return s.a})),n.d(t,"makeStyles",(function(){return c.a})),n.d(t,"responsiveFontSizes",(function(){return u.a})),n.d(t,"styled",(function(){return l.a})),n.d(t,"easing",(function(){return d.c})),n.d(t,"duration",(function(){return d.b})),n.d(t,"useTheme",(function(){return f.a})),n.d(t,"withStyles",(function(){return h.a})),n.d(t,"withTheme",(function(){return p.a})),n.d(t,"createGenerateClassName",(function(){return m.a})),n.d(t,"jssPreset",(function(){return g.a})),n.d(t,"ServerStyleSheets",(function(){return v.a})),n.d(t,"StylesProvider",(function(){return b.b})),n.d(t,"MuiThemeProvider",(function(){return y.a})),n.d(t,"ThemeProvider",(function(){return y.a}));var r=n(29),i=n(288),o=n(536);function a(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r :not(:first-child)":{marginLeft:8}}},{name:"MuiAccordionActions"})(V),H=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=Object(R.a)(e,["classes","className"]);return D.createElement("div",Object(O.a)({className:Object(N.default)(n.root,r),ref:t},i))})),K=Object(B.a)((function(e){return{root:{display:"flex",padding:e.spacing(1,2,2)}}}),{name:"MuiAccordionDetails"})(H),Z=n(266),G=n(263),X=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.expandIcon,a=e.focusVisibleClassName,s=e.IconButtonProps,c=void 0===s?{}:s,u=e.onClick,l=Object(R.a)(e,["children","classes","className","expandIcon","focusVisibleClassName","IconButtonProps","onClick"]),d=D.useContext(z),f=d.disabled,h=void 0!==f&&f,p=d.expanded,m=d.toggle;return D.createElement(Z.a,Object(O.a)({focusRipple:!1,disableRipple:!0,disabled:h,component:"div","aria-expanded":p,className:Object(N.default)(r.root,i,h&&r.disabled,p&&r.expanded),focusVisibleClassName:Object(N.default)(r.focusVisible,r.focused,a),onClick:function(e){m&&m(e),u&&u(e)},ref:t},l),D.createElement("div",{className:Object(N.default)(r.content,p&&r.expanded)},n),o&&D.createElement(G.a,Object(O.a)({className:Object(N.default)(r.expandIcon,p&&r.expanded),edge:"end",component:"div",tabIndex:null,role:null,"aria-hidden":!0},c),o))})),Y=Object(B.a)((function(e){var t={duration:e.transitions.duration.shortest};return{root:{display:"flex",minHeight:48,transition:e.transitions.create(["min-height","background-color"],t),padding:e.spacing(0,2),"&:hover:not($disabled)":{cursor:"pointer"},"&$expanded":{minHeight:64},"&$focused, &$focusVisible":{backgroundColor:e.palette.action.focus},"&$disabled":{opacity:e.palette.action.disabledOpacity}},expanded:{},focused:{},focusVisible:{},disabled:{},content:{display:"flex",flexGrow:1,transition:e.transitions.create(["margin"],t),margin:"12px 0","&$expanded":{margin:"20px 0"}},expandIcon:{transform:"rotate(0deg)",transition:e.transitions.create("transform",t),"&:hover":{backgroundColor:"transparent"},"&$expanded":{transform:"rotate(180deg)"}}}}),{name:"MuiAccordionSummary"})(X),$=n(2383),J=n(54),Q=Object(J.a)(D.createElement("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"}),"Person");var ee=D.forwardRef((function(e,t){var n=e.alt,r=e.children,i=e.classes,o=e.className,a=e.component,s=void 0===a?"div":a,c=e.imgProps,u=e.sizes,l=e.src,d=e.srcSet,f=e.variant,h=void 0===f?"circular":f,p=Object(R.a)(e,["alt","children","classes","className","component","imgProps","sizes","src","srcSet","variant"]),m=null,g=function(e){var t=e.src,n=e.srcSet,r=D.useState(!1),i=r[0],o=r[1];return D.useEffect((function(){if(t||n){o(!1);var e=!0,r=new Image;return r.src=t,r.srcSet=n,r.onload=function(){e&&o("loaded")},r.onerror=function(){e&&o("error")},function(){e=!1}}}),[t,n]),i}({src:l,srcSet:d}),v=l||d,b=v&&"error"!==g;return m=b?D.createElement("img",Object(O.a)({alt:n,src:l,srcSet:d,sizes:u,className:i.img},c)):null!=r?r:v&&n?n[0]:D.createElement(Q,{className:i.fallback}),D.createElement(s,Object(O.a)({className:Object(N.default)(i.root,i.system,i[h],o,!b&&i.colorDefault),ref:t},p),m)})),te=Object(B.a)((function(e){return{root:{position:"relative",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,width:40,height:40,fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(20),lineHeight:1,borderRadius:"50%",overflow:"hidden",userSelect:"none"},colorDefault:{color:e.palette.background.default,backgroundColor:"light"===e.palette.type?e.palette.grey[400]:e.palette.grey[600]},circle:{},circular:{},rounded:{borderRadius:e.shape.borderRadius},square:{borderRadius:0},img:{width:"100%",height:"100%",textAlign:"center",objectFit:"cover",color:"transparent",textIndent:1e4},fallback:{width:"75%",height:"75%"}}}),{name:"MuiAvatar"})(ee),ne=n(1320),re=n(2392),ie=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.component,a=void 0===o?"div":o,s=e.onChange,c=e.showLabels,u=void 0!==c&&c,l=e.value,d=Object(R.a)(e,["children","classes","className","component","onChange","showLabels","value"]);return D.createElement(a,Object(O.a)({className:Object(N.default)(r.root,i),ref:t},d),D.Children.map(n,(function(e,t){if(!D.isValidElement(e))return null;var n=void 0===e.props.value?t:e.props.value;return D.cloneElement(e,{selected:n===l,showLabel:void 0!==e.props.showLabel?e.props.showLabel:u,value:n,onChange:s})})))})),oe=Object(B.a)((function(e){return{root:{display:"flex",justifyContent:"center",height:56,backgroundColor:e.palette.background.paper}}}),{name:"MuiBottomNavigation"})(ie),ae=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=e.icon,o=e.label,a=e.onChange,s=e.onClick,c=e.selected,u=e.showLabel,l=e.value,d=Object(R.a)(e,["classes","className","icon","label","onChange","onClick","selected","showLabel","value"]);return D.createElement(Z.a,Object(O.a)({ref:t,className:Object(N.default)(n.root,r,c?n.selected:!u&&n.iconOnly),focusRipple:!0,onClick:function(e){a&&a(e,l),s&&s(e)}},d),D.createElement("span",{className:n.wrapper},i,D.createElement("span",{className:Object(N.default)(n.label,c?n.selected:!u&&n.iconOnly)},o)))})),se=Object(B.a)((function(e){return{root:{transition:e.transitions.create(["color","padding-top"],{duration:e.transitions.duration.short}),padding:"6px 12px 8px",minWidth:80,maxWidth:168,color:e.palette.text.secondary,flex:"1","&$iconOnly":{paddingTop:16},"&$selected":{paddingTop:6,color:e.palette.primary.main}},selected:{},iconOnly:{},wrapper:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:"100%",flexDirection:"column"},label:{fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(12),opacity:1,transition:"font-size 0.2s, opacity 0.2s",transitionDelay:"0.1s","&$iconOnly":{opacity:0,transitionDelay:"0s"},"&$selected":{fontSize:e.typography.pxToRem(14)}}}}),{name:"MuiBottomNavigationAction"})(ae),ce=n(460),ue=n(113),le=n(461),de=n(898),fe=n(462),he=n(463),pe=n(464),me=n(465),ge=n(899),ve=n(466),be=n(531),ye=n(467),we=n(532),Se=Object(ce.b)(Object(ue.a)(le.h,de.a,fe.d,he.a,pe.b,me.c,ge.a,ve.b,be.b,ye.a)),_e=Object(we.a)("div")(Se,{name:"MuiBox"}),ke=n(80),xe=n(117),Ee=n(29),Oe=Object(J.a)(D.createElement("path",{d:"M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreHoriz");var Me=Object(B.a)((function(e){return{root:{display:"flex",marginLeft:e.spacing(.5),marginRight:e.spacing(.5),backgroundColor:e.palette.grey[100],color:e.palette.grey[700],borderRadius:2,cursor:"pointer","&:hover, &:focus":{backgroundColor:e.palette.grey[200]},"&:active":{boxShadow:e.shadows[0],backgroundColor:Object(Ee.d)(e.palette.grey[200],.12)}},icon:{width:24,height:16}}}),{name:"PrivateBreadcrumbCollapsed"})((function(e){var t=e.classes,n=Object(R.a)(e,["classes"]);return D.createElement(Z.a,Object(O.a)({component:"li",className:t.root,focusRipple:!0},n),D.createElement(Oe,{className:t.icon}))}));var Ce=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.component,a=void 0===o?"nav":o,s=e.expandText,c=void 0===s?"Show path":s,u=e.itemsAfterCollapse,l=void 0===u?1:u,d=e.itemsBeforeCollapse,f=void 0===d?1:d,h=e.maxItems,p=void 0===h?8:h,m=e.separator,g=void 0===m?"/":m,v=Object(R.a)(e,["children","classes","className","component","expandText","itemsAfterCollapse","itemsBeforeCollapse","maxItems","separator"]),b=D.useState(!1),y=b[0],w=b[1],S=D.Children.toArray(n).filter((function(e){return D.isValidElement(e)})).map((function(e,t){return D.createElement("li",{className:r.li,key:"child-".concat(t)},e)}));return D.createElement(xe.a,Object(O.a)({ref:t,component:a,color:"textSecondary",className:Object(N.default)(r.root,i)},v),D.createElement("ol",{className:r.ol},function(e,t,n){return e.reduce((function(r,i,o){return o=e.length?e:[].concat(Object(ke.a)(e.slice(0,f)),[D.createElement(Me,{"aria-label":c,key:"ellipsis",onClick:function(e){w(!0);var t=e.currentTarget.parentNode.querySelector("a[href],button,[tabindex]");t&&t.focus()}})],Object(ke.a)(e.slice(e.length-l,e.length)))}(S),r.separator,g)))})),Te=Object(B.a)({root:{},ol:{display:"flex",flexWrap:"wrap",alignItems:"center",padding:0,margin:0,listStyle:"none"},li:{},separator:{display:"flex",userSelect:"none",marginLeft:8,marginRight:8}},{name:"MuiBreadcrumbs"})(Ce),Ae=n(264),Ie=n(900),Pe=n(2393),Re=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.focusVisibleClassName,a=Object(R.a)(e,["children","classes","className","focusVisibleClassName"]);return D.createElement(Z.a,Object(O.a)({className:Object(N.default)(r.root,i),focusVisibleClassName:Object(N.default)(o,r.focusVisible),ref:t},a),n,D.createElement("span",{className:r.focusHighlight}))})),De=Object(B.a)((function(e){return{root:{display:"block",textAlign:"inherit",width:"100%","&:hover $focusHighlight":{opacity:e.palette.action.hoverOpacity},"&$focusVisible $focusHighlight":{opacity:.12}},focusVisible:{},focusHighlight:{overflow:"hidden",pointerEvents:"none",position:"absolute",top:0,right:0,bottom:0,left:0,borderRadius:"inherit",opacity:0,backgroundColor:"currentcolor",transition:e.transitions.create("opacity",{duration:e.transitions.duration.short})}}}),{name:"MuiCardActionArea"})(Re),Ne=D.forwardRef((function(e,t){var n=e.disableSpacing,r=void 0!==n&&n,i=e.classes,o=e.className,a=Object(R.a)(e,["disableSpacing","classes","className"]);return D.createElement("div",Object(O.a)({className:Object(N.default)(i.root,o,!r&&i.spacing),ref:t},a))})),je=Object(B.a)({root:{display:"flex",alignItems:"center",padding:8},spacing:{"& > :not(:first-child)":{marginLeft:8}}},{name:"MuiCardActions"})(Ne),Le=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=e.component,o=void 0===i?"div":i,a=Object(R.a)(e,["classes","className","component"]);return D.createElement(o,Object(O.a)({className:Object(N.default)(n.root,r),ref:t},a))})),Be=Object(B.a)({root:{padding:16,"&:last-child":{paddingBottom:24}}},{name:"MuiCardContent"})(Le),ze=D.forwardRef((function(e,t){var n=e.action,r=e.avatar,i=e.classes,o=e.className,a=e.component,s=void 0===a?"div":a,c=e.disableTypography,u=void 0!==c&&c,l=e.subheader,d=e.subheaderTypographyProps,f=e.title,h=e.titleTypographyProps,p=Object(R.a)(e,["action","avatar","classes","className","component","disableTypography","subheader","subheaderTypographyProps","title","titleTypographyProps"]),m=f;null==m||m.type===xe.a||u||(m=D.createElement(xe.a,Object(O.a)({variant:r?"body2":"h5",className:i.title,component:"span",display:"block"},h),m));var g=l;return null==g||g.type===xe.a||u||(g=D.createElement(xe.a,Object(O.a)({variant:r?"body2":"body1",className:i.subheader,color:"textSecondary",component:"span",display:"block"},d),g)),D.createElement(s,Object(O.a)({className:Object(N.default)(i.root,o),ref:t},p),r&&D.createElement("div",{className:i.avatar},r),D.createElement("div",{className:i.content},m,g),n&&D.createElement("div",{className:i.action},n))})),Fe=Object(B.a)({root:{display:"flex",alignItems:"center",padding:16},avatar:{flex:"0 0 auto",marginRight:16},action:{flex:"0 0 auto",alignSelf:"flex-start",marginTop:-8,marginRight:-8},content:{flex:"1 1 auto"},title:{},subheader:{}},{name:"MuiCardHeader"})(ze),Ue=["video","audio","picture","iframe","img"],qe=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.component,a=void 0===o?"div":o,s=e.image,c=e.src,u=e.style,l=Object(R.a)(e,["children","classes","className","component","image","src","style"]),d=-1!==Ue.indexOf(a),f=!d&&s?Object(O.a)({backgroundImage:'url("'.concat(s,'")')},u):u;return D.createElement(a,Object(O.a)({className:Object(N.default)(r.root,i,d&&r.media,-1!=="picture img".indexOf(a)&&r.img),ref:t,style:f,src:d?s||c:void 0},l),n)})),Ve=Object(B.a)({root:{display:"block",backgroundSize:"cover",backgroundRepeat:"no-repeat",backgroundPosition:"center"},media:{width:"100%"},img:{objectFit:"cover"}},{name:"MuiCardMedia"})(qe),We=n(1219),He=n(1222),Ke=n(895),Ze=n(2361),Ge=n(22),Xe=n(18),Ye=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=e.component,o=void 0===i?"div":i,a=e.disableGutters,s=void 0!==a&&a,c=e.fixed,u=void 0!==c&&c,l=e.maxWidth,d=void 0===l?"lg":l,f=Object(R.a)(e,["classes","className","component","disableGutters","fixed","maxWidth"]);return D.createElement(o,Object(O.a)({className:Object(N.default)(n.root,r,u&&n.fixed,s&&n.disableGutters,!1!==d&&n["maxWidth".concat(Object(Xe.a)(String(d)))]),ref:t},f))})),$e=Object(B.a)((function(e){return{root:Object(Ge.a)({width:"100%",marginLeft:"auto",boxSizing:"border-box",marginRight:"auto",paddingLeft:e.spacing(2),paddingRight:e.spacing(2),display:"block"},e.breakpoints.up("sm"),{paddingLeft:e.spacing(3),paddingRight:e.spacing(3)}),disableGutters:{paddingLeft:0,paddingRight:0},fixed:Object.keys(e.breakpoints.values).reduce((function(t,n){var r=e.breakpoints.values[n];return 0!==r&&(t[e.breakpoints.up(n)]={maxWidth:r}),t}),{}),maxWidthXs:Object(Ge.a)({},e.breakpoints.up("xs"),{maxWidth:Math.max(e.breakpoints.values.xs,444)}),maxWidthSm:Object(Ge.a)({},e.breakpoints.up("sm"),{maxWidth:e.breakpoints.values.sm}),maxWidthMd:Object(Ge.a)({},e.breakpoints.up("md"),{maxWidth:e.breakpoints.values.md}),maxWidthLg:Object(Ge.a)({},e.breakpoints.up("lg"),{maxWidth:e.breakpoints.values.lg}),maxWidthXl:Object(Ge.a)({},e.breakpoints.up("xl"),{maxWidth:e.breakpoints.values.xl})}}),{name:"MuiContainer"})(Ye),Je={WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",boxSizing:"border-box"},Qe=function(e){return Object(O.a)({color:e.palette.text.primary},e.typography.body2,{backgroundColor:e.palette.background.default,"@media print":{backgroundColor:e.palette.common.white}})};var et=Object(B.a)((function(e){return{"@global":{html:Je,"*, *::before, *::after":{boxSizing:"inherit"},"strong, b":{fontWeight:e.typography.fontWeightBold},body:Object(O.a)({margin:0},Qe(e),{"&::backdrop":{backgroundColor:e.palette.background.default}})}}}),{name:"MuiCssBaseline"})((function(e){var t=e.children,n=void 0===t?null:t;return e.classes,D.createElement(D.Fragment,null,n)})),tt=n(2362),nt=n(2363),rt=n(2364),it=n(2394),ot=n(2395),at=n(2385),st=n(181);var ct=D.createContext({}),ut=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.defaultExpanded,a=void 0!==o&&o,s=e.disabled,c=void 0!==s&&s,u=e.expanded,l=e.onChange,d=e.square,f=void 0!==d&&d,h=e.TransitionComponent,p=void 0===h?j.a:h,m=e.TransitionProps,g=Object(R.a)(e,["children","classes","className","defaultExpanded","disabled","expanded","onChange","square","TransitionComponent","TransitionProps"]),v=Object(F.a)({controlled:u,default:a,name:"ExpansionPanel",state:"expanded"}),b=Object(P.a)(v,2),y=b[0],w=b[1],S=D.useCallback((function(e){w(!y),l&&l(e,!y)}),[y,l,w]),_=I(D.Children.toArray(n)),k=_[0],x=_.slice(1),E=D.useMemo((function(){return{expanded:y,disabled:c,toggle:S}}),[y,c,S]);return D.createElement(L.a,Object(O.a)({className:Object(N.default)(r.root,i,y&&r.expanded,c&&r.disabled,!f&&r.rounded),ref:t,square:f},g),D.createElement(ct.Provider,{value:E},k),D.createElement(p,Object(O.a)({in:y,timeout:"auto"},m),D.createElement("div",{"aria-labelledby":k.props.id,id:k.props["aria-controls"],role:"region"},x)))})),lt=Object(B.a)((function(e){var t={duration:e.transitions.duration.shortest};return{root:{position:"relative",transition:e.transitions.create(["margin"],t),"&:before":{position:"absolute",left:0,top:-1,right:0,height:1,content:'""',opacity:1,backgroundColor:e.palette.divider,transition:e.transitions.create(["opacity","background-color"],t)},"&:first-child":{"&:before":{display:"none"}},"&$expanded":{margin:"16px 0","&:first-child":{marginTop:0},"&:last-child":{marginBottom:0},"&:before":{opacity:0}},"&$expanded + &":{"&:before":{display:"none"}},"&$disabled":{backgroundColor:e.palette.action.disabledBackground}},rounded:{borderRadius:0,"&:first-child":{borderTopLeftRadius:e.shape.borderRadius,borderTopRightRadius:e.shape.borderRadius},"&:last-child":{borderBottomLeftRadius:e.shape.borderRadius,borderBottomRightRadius:e.shape.borderRadius,"@supports (-ms-ime-align: auto)":{borderBottomLeftRadius:0,borderBottomRightRadius:0}}},expanded:{},disabled:{}}}),{name:"MuiExpansionPanel"})(ut),dt=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=e.disableSpacing,o=void 0!==i&&i,a=Object(R.a)(e,["classes","className","disableSpacing"]);return D.createElement("div",Object(O.a)({className:Object(N.default)(n.root,r,!o&&n.spacing),ref:t},a))})),ft=Object(B.a)({root:{display:"flex",alignItems:"center",padding:8,justifyContent:"flex-end"},spacing:{"& > :not(:first-child)":{marginLeft:8}}},{name:"MuiExpansionPanelActions"})(dt),ht=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=Object(R.a)(e,["classes","className"]);return D.createElement("div",Object(O.a)({className:Object(N.default)(n.root,r),ref:t},i))})),pt=Object(B.a)((function(e){return{root:{display:"flex",padding:e.spacing(1,2,2)}}}),{name:"MuiExpansionPanelDetails"})(ht),mt=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=e.expandIcon,a=e.IconButtonProps,s=e.onBlur,c=e.onClick,u=e.onFocusVisible,l=Object(R.a)(e,["children","classes","className","expandIcon","IconButtonProps","onBlur","onClick","onFocusVisible"]),d=D.useState(!1),f=d[0],h=d[1],p=D.useContext(ct),m=p.disabled,g=void 0!==m&&m,v=p.expanded,b=p.toggle;return D.createElement(Z.a,Object(O.a)({focusRipple:!1,disableRipple:!0,disabled:g,component:"div","aria-expanded":v,className:Object(N.default)(r.root,i,g&&r.disabled,v&&r.expanded,f&&r.focused),onFocusVisible:function(e){h(!0),u&&u(e)},onBlur:function(e){h(!1),s&&s(e)},onClick:function(e){b&&b(e),c&&c(e)},ref:t},l),D.createElement("div",{className:Object(N.default)(r.content,v&&r.expanded)},n),o&&D.createElement(G.a,Object(O.a)({className:Object(N.default)(r.expandIcon,v&&r.expanded),edge:"end",component:"div",tabIndex:null,role:null,"aria-hidden":!0},a),o))})),gt=Object(B.a)((function(e){var t={duration:e.transitions.duration.shortest};return{root:{display:"flex",minHeight:48,transition:e.transitions.create(["min-height","background-color"],t),padding:e.spacing(0,2),"&:hover:not($disabled)":{cursor:"pointer"},"&$expanded":{minHeight:64},"&$focused":{backgroundColor:e.palette.action.focus},"&$disabled":{opacity:e.palette.action.disabledOpacity}},expanded:{},focused:{},disabled:{},content:{display:"flex",flexGrow:1,transition:e.transitions.create(["margin"],t),margin:"12px 0","&$expanded":{margin:"20px 0"}},expandIcon:{transform:"rotate(0deg)",transition:e.transitions.create("transform",t),"&:hover":{backgroundColor:"transparent"},"&$expanded":{transform:"rotate(180deg)"}}}}),{name:"MuiExpansionPanelSummary"})(mt),vt=n(1322),bt=n(1321),yt=n(2365),wt=n(749),St=n(272),_t=n(901),kt=n(902),xt=n(750),Et=n(2367),Ot=n(751),Mt=D.forwardRef((function(e,t){var n=e.cellHeight,r=void 0===n?180:n,i=e.children,o=e.classes,a=e.className,s=e.cols,c=void 0===s?2:s,u=e.component,l=void 0===u?"ul":u,d=e.spacing,f=void 0===d?4:d,h=e.style,p=Object(R.a)(e,["cellHeight","children","classes","className","cols","component","spacing","style"]);return D.createElement(l,Object(O.a)({className:Object(N.default)(o.root,a),ref:t,style:Object(O.a)({margin:-f/2},h)},p),D.Children.map(i,(function(e){if(!D.isValidElement(e))return null;var t=e.props.cols||1,n=e.props.rows||1;return D.cloneElement(e,{style:Object(O.a)({width:"".concat(100/c*t,"%"),height:"auto"===r?"auto":r*n+f,padding:f/2},e.props.style)})})))})),Ct=Object(B.a)({root:{display:"flex",flexWrap:"wrap",overflowY:"auto",listStyle:"none",padding:0,WebkitOverflowScrolling:"touch"}},{name:"MuiGridList"})(Mt),Tt=n(120),At=n(139),It=function(e,t){var n,r,i,o;e&&e.complete&&(e.width/e.height>e.parentElement.offsetWidth/e.parentElement.offsetHeight?((n=e.classList).remove.apply(n,Object(ke.a)(t.imgFullWidth.split(" "))),(r=e.classList).add.apply(r,Object(ke.a)(t.imgFullHeight.split(" ")))):((i=e.classList).remove.apply(i,Object(ke.a)(t.imgFullHeight.split(" "))),(o=e.classList).add.apply(o,Object(ke.a)(t.imgFullWidth.split(" ")))))};var Pt=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=(e.cols,e.component),a=void 0===o?"li":o,s=(e.rows,Object(R.a)(e,["children","classes","className","cols","component","rows"])),c=D.useRef(null);return D.useEffect((function(){!function(e,t){e&&(e.complete?It(e,t):e.addEventListener("load",(function(){It(e,t)})))}(c.current,r)})),D.useEffect((function(){var e=Object(Tt.a)((function(){It(c.current,r)}));return window.addEventListener("resize",e),function(){e.clear(),window.removeEventListener("resize",e)}}),[r]),D.createElement(a,Object(O.a)({className:Object(N.default)(r.root,i),ref:t},s),D.createElement("div",{className:r.tile},D.Children.map(n,(function(e){return D.isValidElement(e)?"img"===e.type||Object(At.a)(e,["Image"])?D.cloneElement(e,{ref:c}):e:null}))))})),Rt=Object(B.a)({root:{boxSizing:"border-box",flexShrink:0},tile:{position:"relative",display:"block",height:"100%",overflow:"hidden"},imgFullHeight:{height:"100%",transform:"translateX(-50%)",position:"relative",left:"50%"},imgFullWidth:{width:"100%",position:"relative",transform:"translateY(-50%)",top:"50%"}},{name:"MuiGridListTile"})(Pt),Dt=D.forwardRef((function(e,t){var n=e.actionIcon,r=e.actionPosition,i=void 0===r?"right":r,o=e.classes,a=e.className,s=e.subtitle,c=e.title,u=e.titlePosition,l=void 0===u?"bottom":u,d=Object(R.a)(e,["actionIcon","actionPosition","classes","className","subtitle","title","titlePosition"]),f=n&&i;return D.createElement("div",Object(O.a)({className:Object(N.default)(o.root,a,"top"===l?o.titlePositionTop:o.titlePositionBottom,s&&o.rootSubtitle),ref:t},d),D.createElement("div",{className:Object(N.default)(o.titleWrap,{left:o.titleWrapActionPosLeft,right:o.titleWrapActionPosRight}[f])},D.createElement("div",{className:o.title},c),s?D.createElement("div",{className:o.subtitle},s):null),n?D.createElement("div",{className:Object(N.default)(o.actionIcon,"left"===f&&o.actionIconActionPosLeft)},n):null)})),Nt=Object(B.a)((function(e){return{root:{position:"absolute",left:0,right:0,height:48,background:"rgba(0, 0, 0, 0.5)",display:"flex",alignItems:"center",fontFamily:e.typography.fontFamily},titlePositionBottom:{bottom:0},titlePositionTop:{top:0},rootSubtitle:{height:68},titleWrap:{flexGrow:1,marginLeft:16,marginRight:16,color:e.palette.common.white,overflow:"hidden"},titleWrapActionPosLeft:{marginLeft:0},titleWrapActionPosRight:{marginRight:0},title:{fontSize:e.typography.pxToRem(16),lineHeight:"24px",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},subtitle:{fontSize:e.typography.pxToRem(12),lineHeight:1,textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},actionIcon:{},actionIconActionPosLeft:{order:-1}}}),{name:"MuiGridListTileBar"})(Dt),jt=n(598),Lt=n(1220),Bt=n(903),zt=D.forwardRef((function(e,t){var n=e.cellHeight,r=e.children,i=e.classes,o=e.className,a=e.cols,s=void 0===a?2:a,c=e.component,u=void 0===c?"ul":c,l=e.gap,d=void 0===l?4:l,f=e.rowHeight,h=void 0===f?180:f,p=e.spacing,m=e.style,g=Object(R.a)(e,["cellHeight","children","classes","className","cols","component","gap","rowHeight","spacing","style"]),v=p||d,b=n||h;return D.createElement(u,Object(O.a)({className:Object(N.default)(i.root,o),ref:t,style:Object(O.a)({margin:-v/2},m)},g),D.Children.map(r,(function(e){if(!D.isValidElement(e))return null;var t=e.props.cols||1,n=e.props.rows||1;return D.cloneElement(e,{style:Object(O.a)({width:"".concat(100/s*t,"%"),height:"auto"===b?"auto":b*n+v,padding:v/2},e.props.style)})})))})),Ft=Object(B.a)({root:{display:"flex",flexWrap:"wrap",overflowY:"auto",listStyle:"none",padding:0,WebkitOverflowScrolling:"touch"}},{name:"MuiImageList"})(zt),Ut=function(e,t){var n,r,i,o;e&&e.complete&&(e.width/e.height>e.parentElement.offsetWidth/e.parentElement.offsetHeight?((n=e.classList).remove.apply(n,Object(ke.a)(t.imgFullWidth.split(" "))),(r=e.classList).add.apply(r,Object(ke.a)(t.imgFullHeight.split(" ")))):((i=e.classList).remove.apply(i,Object(ke.a)(t.imgFullHeight.split(" "))),(o=e.classList).add.apply(o,Object(ke.a)(t.imgFullWidth.split(" ")))))};var qt=D.forwardRef((function(e,t){var n=e.children,r=e.classes,i=e.className,o=(e.cols,e.component),a=void 0===o?"li":o,s=(e.rows,Object(R.a)(e,["children","classes","className","cols","component","rows"])),c=D.useRef(null);return D.useEffect((function(){!function(e,t){e&&(e.complete?Ut(e,t):e.addEventListener("load",(function(){Ut(e,t)})))}(c.current,r)})),D.useEffect((function(){var e=Object(Tt.a)((function(){Ut(c.current,r)}));return window.addEventListener("resize",e),function(){e.clear(),window.removeEventListener("resize",e)}}),[r]),D.createElement(a,Object(O.a)({className:Object(N.default)(r.root,i),ref:t},s),D.createElement("div",{className:r.item},D.Children.map(n,(function(e){return D.isValidElement(e)?"img"===e.type||Object(At.a)(e,["Image"])?D.cloneElement(e,{ref:c}):e:null}))))})),Vt=Object(B.a)({root:{boxSizing:"border-box",flexShrink:0},item:{position:"relative",display:"block",height:"100%",overflow:"hidden"},imgFullHeight:{height:"100%",transform:"translateX(-50%)",position:"relative",left:"50%"},imgFullWidth:{width:"100%",position:"relative",transform:"translateY(-50%)",top:"50%"}},{name:"MuiImageListItem"})(qt),Wt=D.forwardRef((function(e,t){var n=e.actionIcon,r=e.actionPosition,i=void 0===r?"right":r,o=e.classes,a=e.className,s=e.subtitle,c=e.title,u=e.position,l=void 0===u?"bottom":u,d=e.titlePosition,f=Object(R.a)(e,["actionIcon","actionPosition","classes","className","subtitle","title","position","titlePosition"]),h=d||l,p=n&&i;return D.createElement("div",Object(O.a)({className:Object(N.default)(o.root,a,s&&o.rootSubtitle,{bottom:o.positionBottom,top:o.positionTop}[h]),ref:t},f),D.createElement("div",{className:Object(N.default)(o.titleWrap,{left:o.titleWrapActionPosLeft,right:o.titleWrapActionPosRight}[p])},D.createElement("div",{className:o.title},c),s?D.createElement("div",{className:o.subtitle},s):null),n?D.createElement("div",{className:Object(N.default)(o.actionIcon,"left"===p&&o.actionIconActionPosLeft)},n):null)})),Ht=Object(B.a)((function(e){return{root:{position:"absolute",left:0,right:0,height:48,background:"rgba(0, 0, 0, 0.5)",display:"flex",alignItems:"center",fontFamily:e.typography.fontFamily},positionBottom:{bottom:0},positionTop:{top:0},rootSubtitle:{height:68},titleWrap:{flexGrow:1,marginLeft:16,marginRight:16,color:e.palette.common.white,overflow:"hidden"},titleWrapActionPosLeft:{marginLeft:0},titleWrapActionPosRight:{marginRight:0},title:{fontSize:e.typography.pxToRem(16),lineHeight:"24px",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},subtitle:{fontSize:e.typography.pxToRem(12),lineHeight:1,textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},actionIcon:{},actionIconActionPosLeft:{order:-1}}}),{name:"MuiImageListItemBar"})(Wt),Kt=n(548),Zt=n(904),Gt=n(547),Xt=n(752),Yt=n(2396),$t=n(905),Jt=n(746),Qt=n(747),en=n(180),tn=D.forwardRef((function(e,t){var n=e.classes,r=e.className,i=Object(R.a)(e,["classes","className"]),o=D.useContext(en.a);return D.createElement("div",Object(O.a)({className:Object(N.default)(n.root,r,"flex-start"===o.alignItems&&n.alignItemsFlexStart),ref:t},i))})),nn=Object(B.a)({root:{minWidth:56,flexShrink:0},alignItemsFlexStart:{marginTop:8}},{name:"MuiListItemAvatar"})(tn),rn=n(2387),on=n(2397),an=n(2388),sn=n(2386),cn=n(533),un=n(906),ln=n(2368),dn=D.forwardRef((function(e,t){var n=e.activeStep,r=void 0===n?0:n,i=e.backButton,o=e.classes,a=e.className,s=e.LinearProgressProps,c=e.nextButton,u=e.position,l=void 0===u?"bottom":u,d=e.steps,f=e.variant,h=void 0===f?"dots":f,p=Object(R.a)(e,["activeStep","backButton","classes","className","LinearProgressProps","nextButton","position","steps","variant"]);return D.createElement(L.a,Object(O.a)({square:!0,elevation:0,className:Object(N.default)(o.root,o["position".concat(Object(Xe.a)(l))],a),ref:t},p),i,"text"===h&&D.createElement(D.Fragment,null,r+1," / ",d),"dots"===h&&D.createElement("div",{className:o.dots},Object(ke.a)(new Array(d)).map((function(e,t){return D.createElement("div",{key:t,className:Object(N.default)(o.dot,t===r&&o.dotActive)})}))),"progress"===h&&D.createElement(Yt.a,Object(O.a)({className:o.progress,variant:"determinate",value:Math.ceil(r/(d-1)*100)},s)),c)})),fn=Object(B.a)((function(e){return{root:{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",background:e.palette.background.default,padding:8},positionBottom:{position:"fixed",bottom:0,left:0,right:0,zIndex:e.zIndex.mobileStepper},positionTop:{position:"fixed",top:0,left:0,right:0,zIndex:e.zIndex.mobileStepper},positionStatic:{},dots:{display:"flex",flexDirection:"row"},dot:{backgroundColor:e.palette.action.disabled,borderRadius:"50%",width:8,height:8,margin:"0 2px"},dotActive:{backgroundColor:e.palette.primary.main},progress:{width:"50%"}}}),{name:"MuiMobileStepper"})(dn),hn=n(432),pn=n(273),mn=n(1233),gn=n(2384),vn=n(761),bn=n(753),yn=n(1324),wn=n(2357),Sn=n(335),_n=Object(J.a)(D.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"RadioButtonUnchecked"),kn=Object(J.a)(D.createElement("path",{d:"M8.465 8.465C9.37 7.56 10.62 7 12 7C14.76 7 17 9.24 17 12C17 13.38 16.44 14.63 15.535 15.535C14.63 16.44 13.38 17 12 17C9.24 17 7 14.76 7 12C7 10.62 7.56 9.37 8.465 8.465Z"}),"RadioButtonChecked");var xn=Object(B.a)((function(e){return{root:{position:"relative",display:"flex","&$checked $layer":{transform:"scale(1)",transition:e.transitions.create("transform",{easing:e.transitions.easing.easeOut,duration:e.transitions.duration.shortest})}},layer:{left:0,position:"absolute",transform:"scale(0)",transition:e.transitions.create("transform",{easing:e.transitions.easing.easeIn,duration:e.transitions.duration.shortest})},checked:{}}}),{name:"PrivateRadioButtonIcon"})((function(e){var t=e.checked,n=e.classes,r=e.fontSize;return D.createElement("div",{className:Object(N.default)(n.root,t&&n.checked)},D.createElement(_n,{fontSize:r}),D.createElement(kn,{fontSize:r,className:n.layer}))})),En=n(138);var On=D.createContext();function Mn(){return D.useContext(On)}var Cn=D.createElement(xn,{checked:!0}),Tn=D.createElement(xn,null),An=D.forwardRef((function(e,t){var n=e.checked,r=e.classes,i=e.color,o=void 0===i?"secondary":i,a=e.name,s=e.onChange,c=e.size,u=void 0===c?"medium":c,l=Object(R.a)(e,["checked","classes","color","name","onChange","size"]),d=Mn(),f=n,h=Object(En.a)(s,d&&d.onChange),p=a;return d&&("undefined"===typeof f&&(f=d.value===e.value),"undefined"===typeof p&&(p=d.name)),D.createElement(Sn.a,Object(O.a)({color:o,type:"radio",icon:D.cloneElement(Tn,{fontSize:"small"===u?"small":"medium"}),checkedIcon:D.cloneElement(Cn,{fontSize:"small"===u?"small":"medium"}),classes:{root:Object(N.default)(r.root,r["color".concat(Object(Xe.a)(o))]),checked:r.checked,disabled:r.disabled},name:p,checked:f,onChange:h,ref:t},l))})),In=Object(B.a)((function(e){return{root:{color:e.palette.text.secondary},checked:{},disabled:{},colorPrimary:{"&$checked":{color:e.palette.primary.main,"&:hover":{backgroundColor:Object(Ee.a)(e.palette.primary.main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},"&$disabled":{color:e.palette.action.disabled}},colorSecondary:{"&$checked":{color:e.palette.secondary.main,"&:hover":{backgroundColor:Object(Ee.a)(e.palette.secondary.main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},"&$disabled":{color:e.palette.action.disabled}}}}),{name:"MuiRadio"})(An),Pn=n(36),Rn=n(230),Dn=D.forwardRef((function(e,t){var n=e.actions,r=e.children,i=e.name,o=e.value,a=e.onChange,s=Object(R.a)(e,["actions","children","name","value","onChange"]),c=D.useRef(null),u=Object(F.a)({controlled:o,default:e.defaultValue,name:"RadioGroup"}),l=Object(P.a)(u,2),d=l[0],f=l[1];D.useImperativeHandle(n,(function(){return{focus:function(){var e=c.current.querySelector("input:not(:disabled):checked");e||(e=c.current.querySelector("input:not(:disabled)")),e&&e.focus()}}}),[]);var h=Object(Pn.a)(t,c),p=Object(Rn.a)(i);return D.createElement(On.Provider,{value:{name:p,onChange:function(e){f(e.target.value),a&&a(e,e.target.value)},value:d}},D.createElement(kt.a,Object(O.a)({role:"radiogroup",ref:h},s),r))})),Nn=n(257),jn=n(179),Ln=n(588),Bn=n(551),zn=n(345),Fn=n(41),Un=n(111);function qn(e){var t=function(){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}}();return function(){var n,r=Object(zn.a)(e);if(t){var i=Object(zn.a)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Object(Bn.a)(this,n)}}var Vn=function(e){Object(Ln.a)(n,e);var t=qn(n);function n(){return Object(Nn.a)(this,n),t.apply(this,arguments)}return Object(jn.a)(n,[{key:"componentDidMount",value:function(){this.ref=Fn.findDOMNode(this),Object(Un.a)(this.props.rootRef,this.ref)}},{key:"componentDidUpdate",value:function(e){var t=Fn.findDOMNode(this);e.rootRef===this.props.rootRef&&this.ref===t||(e.rootRef!==this.props.rootRef&&Object(Un.a)(e.rootRef,null),this.ref=t,Object(Un.a)(this.props.rootRef,this.ref))}},{key:"componentWillUnmount",value:function(){this.ref=null,Object(Un.a)(this.props.rootRef,null)}},{key:"render",value:function(){return this.props.children}}]),n}(D.Component),Wn=n(762),Hn=n(2356),Kn=n(52),Zn=n(203),Gn=n(74),Xn=n(62);var Yn=Object(B.a)((function(e){return{thumb:{"&$open":{"& $offset":{transform:"scale(1) translateY(-10px)"}}},open:{},offset:Object(O.a)({zIndex:1},e.typography.body2,{fontSize:e.typography.pxToRem(12),lineHeight:1.2,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),top:-34,transformOrigin:"bottom center",transform:"scale(0)",position:"absolute"}),circle:{display:"flex",alignItems:"center",justifyContent:"center",width:32,height:32,borderRadius:"50% 50% 50% 0",backgroundColor:"currentColor",transform:"rotate(-45deg)"},label:{color:e.palette.primary.contrastText,transform:"rotate(45deg)"}}}),{name:"PrivateValueLabel"})((function(e){var t=e.children,n=e.classes,r=e.className,i=e.open,o=e.value,a=e.valueLabelDisplay;return"off"===a?t:D.cloneElement(t,{className:Object(N.default)(t.props.className,(i||"on"===a)&&n.open,n.thumb)},D.createElement("span",{className:Object(N.default)(n.offset,r)},D.createElement("span",{className:n.circle},D.createElement("span",{className:n.label},o))))}));function $n(e,t){return e-t}function Jn(e,t,n){return Math.min(Math.max(t,e),n)}function Qn(e,t){return e.reduce((function(e,n,r){var i=Math.abs(t-n);return null===e||i0&&le.some((function(e){return e.label}))&&o.marked,!1===U&&o.trackFalse,"vertical"===C&&o.vertical,"inverted"===U&&o.trackInverted),onMouseDown:De},X),D.createElement("span",{className:o.rail}),D.createElement("span",{className:o.track,style:Le}),D.createElement("input",{value:ue.join(","),name:_,type:"hidden"}),le.map((function(e,t){var n,r=tr(e.value,S,y),i=or[Te].offset(r);return n=!1===U?-1!==ue.indexOf(e.value):"normal"===U&&(ce?e.value>=ue[0]&&e.value<=ue[ue.length-1]:e.value<=ue[0])||"inverted"===U&&(ce?e.value<=ue[0]||e.value>=ue[ue.length-1]:e.value>=ue[0]),D.createElement(D.Fragment,{key:e.value},D.createElement("span",{style:i,"data-index":t,className:Object(N.default)(o.mark,n&&o.markActive)}),null!=e.label?D.createElement("span",{"aria-hidden":!0,"data-index":t,style:i,className:Object(N.default)(o.markLabel,n&&o.markLabelActive)},e.label):null)})),ue.map((function(e,t){var a=tr(e,S,y),s=or[Te].offset(a);return D.createElement(W,{key:t,valueLabelFormat:G,valueLabelDisplay:K,className:o.valueLabel,value:"function"===typeof G?G(A(e),t):G,index:t,open:ne===t||Q===t||"on"===K,disabled:h},D.createElement(B,{className:Object(N.default)(o.thumb,o["thumbColor".concat(Object(Xe.a)(c))],Q===t&&o.active,h&&o.disabled,ge===t&&o.focusVisible),tabIndex:h?null:0,role:"slider",style:s,"data-index":t,"aria-label":p?p(t):n,"aria-labelledby":r,"aria-orientation":C,"aria-valuemax":A(y),"aria-valuemin":A(S),"aria-valuenow":A(e),"aria-valuetext":m?m(A(e),t):i,onKeyDown:Me,onFocus:Se,onBlur:_e,onMouseOver:xe,onMouseLeave:Ee}))})))})),cr=Object(B.a)((function(e){return{root:{height:2,width:"100%",boxSizing:"content-box",padding:"13px 0",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",color:e.palette.primary.main,WebkitTapHighlightColor:"transparent","&$disabled":{pointerEvents:"none",cursor:"default",color:e.palette.grey[400]},"&$vertical":{width:2,height:"100%",padding:"0 13px"},"@media (pointer: coarse)":{padding:"20px 0","&$vertical":{padding:"0 20px"}},"@media print":{colorAdjust:"exact"}},colorPrimary:{},colorSecondary:{color:e.palette.secondary.main},marked:{marginBottom:20,"&$vertical":{marginBottom:"auto",marginRight:20}},vertical:{},disabled:{},rail:{display:"block",position:"absolute",width:"100%",height:2,borderRadius:1,backgroundColor:"currentColor",opacity:.38,"$vertical &":{height:"100%",width:2}},track:{display:"block",position:"absolute",height:2,borderRadius:1,backgroundColor:"currentColor","$vertical &":{width:2}},trackFalse:{"& $track":{display:"none"}},trackInverted:{"& $track":{backgroundColor:"light"===e.palette.type?Object(Ee.j)(e.palette.primary.main,.62):Object(Ee.b)(e.palette.primary.main,.5)},"& $rail":{opacity:1}},thumb:{position:"absolute",width:12,height:12,marginLeft:-6,marginTop:-5,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow"],{duration:e.transitions.duration.shortest}),"&::after":{position:"absolute",content:'""',borderRadius:"50%",left:-15,top:-15,right:-15,bottom:-15},"&$focusVisible,&:hover":{boxShadow:"0px 0px 0px 8px ".concat(Object(Ee.a)(e.palette.primary.main,.16)),"@media (hover: none)":{boxShadow:"none"}},"&$active":{boxShadow:"0px 0px 0px 14px ".concat(Object(Ee.a)(e.palette.primary.main,.16))},"&$disabled":{width:8,height:8,marginLeft:-4,marginTop:-3,"&:hover":{boxShadow:"none"}},"$vertical &":{marginLeft:-5,marginBottom:-6},"$vertical &$disabled":{marginLeft:-3,marginBottom:-4}},thumbColorPrimary:{},thumbColorSecondary:{"&$focusVisible,&:hover":{boxShadow:"0px 0px 0px 8px ".concat(Object(Ee.a)(e.palette.secondary.main,.16))},"&$active":{boxShadow:"0px 0px 0px 14px ".concat(Object(Ee.a)(e.palette.secondary.main,.16))}},active:{},focusVisible:{},valueLabel:{left:"calc(-50% - 4px)"},mark:{position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor"},markActive:{backgroundColor:e.palette.background.paper,opacity:.8},markLabel:Object(O.a)({},e.typography.body2,{color:e.palette.text.secondary,position:"absolute",top:26,transform:"translateX(-50%)",whiteSpace:"nowrap","$vertical &":{top:"auto",left:26,transform:"translateY(50%)"},"@media (pointer: coarse)":{top:40,"$vertical &":{left:31}}}),markLabelActive:{color:e.palette.text.primary}}}),{name:"MuiSlider"})(sr),ur=n(2398),lr=n(2369),dr=D.forwardRef((function(e,t){var n=e.active,r=void 0!==n&&n,i=e.alternativeLabel,o=e.children,a=e.classes,s=e.className,c=e.completed,u=void 0!==c&&c,l=e.connector,d=e.disabled,f=void 0!==d&&d,h=e.expanded,p=void 0!==h&&h,m=e.index,g=e.last,v=e.orientation,b=Object(R.a)(e,["active","alternativeLabel","children","classes","className","completed","connector","disabled","expanded","index","last","orientation"]),y=l?D.cloneElement(l,{orientation:v,alternativeLabel:i,index:m,active:r,completed:u,disabled:f}):null,w=D.createElement("div",Object(O.a)({className:Object(N.default)(a.root,a[v],s,i&&a.alternativeLabel,u&&a.completed),ref:t},b),y&&i&&0!==m?y:null,D.Children.map(o,(function(e){return D.isValidElement(e)?D.cloneElement(e,Object(O.a)({active:r,alternativeLabel:i,completed:u,disabled:f,expanded:p,last:g,icon:m+1,orientation:v},e.props)):null})));return y&&!i&&0!==m?D.createElement(D.Fragment,null,y,w):w})),fr=Object(B.a)({root:{},horizontal:{paddingLeft:8,paddingRight:8},vertical:{},alternativeLabel:{flex:1,position:"relative"},completed:{}},{name:"MuiStep"})(dr),hr=Object(J.a)(D.createElement("path",{d:"M12 0a12 12 0 1 0 0 24 12 12 0 0 0 0-24zm-2 17l-5-5 1.4-1.4 3.6 3.6 7.6-7.6L19 8l-9 9z"}),"CheckCircle"),pr=Object(J.a)(D.createElement("path",{d:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"}),"Warning"),mr=n(1319),gr=D.createElement("circle",{cx:"12",cy:"12",r:"12"}),vr=D.forwardRef((function(e,t){var n=e.completed,r=void 0!==n&&n,i=e.icon,o=e.active,a=void 0!==o&&o,s=e.error,c=void 0!==s&&s,u=e.classes;if("number"===typeof i||"string"===typeof i){var l=Object(N.default)(u.root,a&&u.active,c&&u.error,r&&u.completed);return c?D.createElement(pr,{className:l,ref:t}):r?D.createElement(hr,{className:l,ref:t}):D.createElement(mr.a,{className:l,ref:t},gr,D.createElement("text",{className:u.text,x:"12",y:"16",textAnchor:"middle"},i))}return i})),br=Object(B.a)((function(e){return{root:{display:"block",color:e.palette.text.disabled,"&$completed":{color:e.palette.primary.main},"&$active":{color:e.palette.primary.main},"&$error":{color:e.palette.error.main}},text:{fill:e.palette.primary.contrastText,fontSize:e.typography.caption.fontSize,fontFamily:e.typography.fontFamily},active:{},completed:{},error:{}}}),{name:"MuiStepIcon"})(vr),yr=D.forwardRef((function(e,t){var n=e.active,r=void 0!==n&&n,i=e.alternativeLabel,o=void 0!==i&&i,a=e.children,s=e.classes,c=e.className,u=e.completed,l=void 0!==u&&u,d=e.disabled,f=void 0!==d&&d,h=e.error,p=void 0!==h&&h,m=(e.expanded,e.icon),g=(e.last,e.optional),v=e.orientation,b=void 0===v?"horizontal":v,y=e.StepIconComponent,w=e.StepIconProps,S=Object(R.a)(e,["active","alternativeLabel","children","classes","className","completed","disabled","error","expanded","icon","last","optional","orientation","StepIconComponent","StepIconProps"]),_=y;return m&&!_&&(_=br),D.createElement("span",Object(O.a)({className:Object(N.default)(s.root,s[b],c,f&&s.disabled,o&&s.alternativeLabel,p&&s.error),ref:t},S),m||_?D.createElement("span",{className:Object(N.default)(s.iconContainer,o&&s.alternativeLabel)},D.createElement(_,Object(O.a)({completed:l,active:r,error:p,icon:m},w))):null,D.createElement("span",{className:s.labelContainer},a?D.createElement(xe.a,{variant:"body2",component:"span",display:"block",className:Object(N.default)(s.label,o&&s.alternativeLabel,l&&s.completed,r&&s.active,p&&s.error)},a):null,g))}));yr.muiName="StepLabel";var wr=Object(B.a)((function(e){return{root:{display:"flex",alignItems:"center","&$alternativeLabel":{flexDirection:"column"},"&$disabled":{cursor:"default"}},horizontal:{},vertical:{},label:{color:e.palette.text.secondary,"&$active":{color:e.palette.text.primary,fontWeight:500},"&$completed":{color:e.palette.text.primary,fontWeight:500},"&$alternativeLabel":{textAlign:"center",marginTop:16},"&$error":{color:e.palette.error.main}},active:{},completed:{},error:{},disabled:{},iconContainer:{flexShrink:0,display:"flex",paddingRight:8,"&$alternativeLabel":{paddingRight:0}},alternativeLabel:{},labelContainer:{width:"100%"}}}),{name:"MuiStepLabel"})(yr),Sr=D.forwardRef((function(e,t){var n=e.active,r=e.alternativeLabel,i=e.children,o=e.classes,a=e.className,s=e.completed,c=e.disabled,u=(e.expanded,e.icon),l=(e.last,e.optional),d=e.orientation,f=Object(R.a)(e,["active","alternativeLabel","children","classes","className","completed","disabled","expanded","icon","last","optional","orientation"]),h={active:n,alternativeLabel:r,completed:s,disabled:c,icon:u,optional:l,orientation:d},p=Object(At.a)(i,["StepLabel"])?D.cloneElement(i,h):D.createElement(wr,h,i);return D.createElement(Z.a,Object(O.a)({focusRipple:!0,disabled:c,TouchRippleProps:{className:o.touchRipple},className:Object(N.default)(o.root,o[d],a),ref:t},f),p)})),_r=Object(B.a)({root:{width:"100%",padding:"24px 16px",margin:"-24px -16px",boxSizing:"content-box"},horizontal:{},vertical:{justifyContent:"flex-start",padding:"8px",margin:"-8px"},touchRipple:{color:"rgba(0, 0, 0, 0.3)"}},{name:"MuiStepButton"})(Sr),kr=D.forwardRef((function(e,t){var n=e.active,r=e.alternativeLabel,i=void 0!==r&&r,o=e.classes,a=e.className,s=e.completed,c=e.disabled,u=(e.index,e.orientation),l=void 0===u?"horizontal":u,d=Object(R.a)(e,["active","alternativeLabel","classes","className","completed","disabled","index","orientation"]);return D.createElement("div",Object(O.a)({className:Object(N.default)(o.root,o[l],a,i&&o.alternativeLabel,n&&o.active,s&&o.completed,c&&o.disabled),ref:t},d),D.createElement("span",{className:Object(N.default)(o.line,{horizontal:o.lineHorizontal,vertical:o.lineVertical}[l])}))})),xr=Object(B.a)((function(e){return{root:{flex:"1 1 auto"},horizontal:{},vertical:{marginLeft:12,padding:"0 0 8px"},alternativeLabel:{position:"absolute",top:12,left:"calc(-50% + 20px)",right:"calc(50% + 20px)"},active:{},completed:{},disabled:{},line:{display:"block",borderColor:"light"===e.palette.type?e.palette.grey[400]:e.palette.grey[600]},lineHorizontal:{borderTopStyle:"solid",borderTopWidth:1},lineVertical:{borderLeftStyle:"solid",borderLeftWidth:1,minHeight:24}}}),{name:"MuiStepConnector"})(kr),Er=D.forwardRef((function(e,t){var n=e.active,r=(e.alternativeLabel,e.children),i=e.classes,o=e.className,a=(e.completed,e.expanded),s=e.last,c=(e.optional,e.orientation,e.TransitionComponent),u=void 0===c?j.a:c,l=e.transitionDuration,d=void 0===l?"auto":l,f=e.TransitionProps,h=Object(R.a)(e,["active","alternativeLabel","children","classes","className","completed","expanded","last","optional","orientation","TransitionComponent","transitionDuration","TransitionProps"]);var p=d;return"auto"!==d||u.muiSupportAuto||(p=void 0),D.createElement("div",Object(O.a)({className:Object(N.default)(i.root,o,s&&i.last),ref:t},h),D.createElement(u,Object(O.a)({in:n||a,className:i.transition,timeout:p,unmountOnExit:!0},f),r))})),Or=Object(B.a)((function(e){return{root:{marginTop:8,marginLeft:12,paddingLeft:20,paddingRight:8,borderLeft:"1px solid ".concat("light"===e.palette.type?e.palette.grey[400]:e.palette.grey[600])},last:{borderLeft:"none"},transition:{}}}),{name:"MuiStepContent"})(Er),Mr=D.createElement(xr,null),Cr=D.forwardRef((function(e,t){var n=e.activeStep,r=void 0===n?0:n,i=e.alternativeLabel,o=void 0!==i&&i,a=e.children,s=e.classes,c=e.className,u=e.connector,l=void 0===u?Mr:u,d=e.nonLinear,f=void 0!==d&&d,h=e.orientation,p=void 0===h?"horizontal":h,m=Object(R.a)(e,["activeStep","alternativeLabel","children","classes","className","connector","nonLinear","orientation"]),g=D.isValidElement(l)?D.cloneElement(l,{orientation:p}):null,v=D.Children.toArray(a),b=v.map((function(e,t){var n={index:t,active:!1,completed:!1,disabled:!1};return r===t?n.active=!0:!f&&r>t?n.completed=!0:!f&&r=Math.ceil(r/l)-1,color:"inherit"},i),"rtl"===f.direction?Gr:Xr))})),$r=function(e){var t=e.from,n=e.to,r=e.count;return"".concat(t,"-").concat(n," of ").concat(-1!==r?r:"more than ".concat(n))},Jr=[10,25,50,100],Qr=D.forwardRef((function(e,t){var n,r=e.ActionsComponent,i=void 0===r?Yr:r,o=e.backIconButtonProps,a=e.backIconButtonText,s=void 0===a?"Previous page":a,c=e.classes,u=e.className,l=e.colSpan,d=e.component,f=void 0===d?jr.a:d,h=e.count,p=e.labelDisplayedRows,m=void 0===p?$r:p,g=e.labelRowsPerPage,v=void 0===g?"Rows per page:":g,b=e.nextIconButtonProps,y=e.nextIconButtonText,w=void 0===y?"Next page":y,S=e.onChangePage,_=e.onPageChange,k=e.onChangeRowsPerPage,x=e.onRowsPerPageChange,E=e.page,M=e.rowsPerPage,C=e.rowsPerPageOptions,T=void 0===C?Jr:C,A=e.SelectProps,I=void 0===A?{}:A,P=Object(R.a)(e,["ActionsComponent","backIconButtonProps","backIconButtonText","classes","className","colSpan","component","count","labelDisplayedRows","labelRowsPerPage","nextIconButtonProps","nextIconButtonText","onChangePage","onPageChange","onChangeRowsPerPage","onRowsPerPageChange","page","rowsPerPage","rowsPerPageOptions","SelectProps"]),j=k||x;f!==jr.a&&"td"!==f||(n=l||1e3);var L=Object(Rn.a)(),B=Object(Rn.a)(),z=I.native?"option":un.a;return D.createElement(f,Object(O.a)({className:Object(N.default)(c.root,u),colSpan:n,ref:t},P),D.createElement(Vr.a,{className:c.toolbar},D.createElement("div",{className:c.spacer}),T.length>1&&D.createElement(xe.a,{color:"inherit",variant:"body2",className:c.caption,id:B},v),T.length>1&&D.createElement(Wn.a,Object(O.a)({classes:{select:c.select,icon:c.selectIcon},input:D.createElement(Gt.a,{className:Object(N.default)(c.input,c.selectRoot)}),value:M,onChange:j,id:L,labelId:B},I),T.map((function(e){return D.createElement(z,{className:c.menuItem,key:e.value?e.value:e,value:e.value?e.value:e},e.label?e.label:e)}))),D.createElement(xe.a,{color:"inherit",variant:"body2",className:c.caption},m({from:0===h?0:E*M+1,to:-1!==h?Math.min(h,(E+1)*M):(E+1)*M,count:-1===h?-1:h,page:E})),D.createElement(i,{className:c.actions,backIconButtonProps:Object(O.a)({title:s,"aria-label":s},o),count:h,nextIconButtonProps:Object(O.a)({title:w,"aria-label":w},b),onChangePage:S,onPageChange:_,page:E,rowsPerPage:M})))})),ei=Object(B.a)((function(e){return{root:{color:e.palette.text.primary,fontSize:e.typography.pxToRem(14),overflow:"auto","&:last-child":{padding:0}},toolbar:{minHeight:52,paddingRight:2},spacer:{flex:"1 1 100%"},caption:{flexShrink:0},selectRoot:{marginRight:32,marginLeft:8},select:{paddingLeft:8,paddingRight:24,textAlign:"right",textAlignLast:"right"},selectIcon:{},input:{color:"inherit",fontSize:"inherit",flexShrink:0},menuItem:{},actions:{flexShrink:0,marginLeft:20}}}),{name:"MuiTablePagination"})(Qr),ti=n(909),ni=n(1223),ri=n(2371),ii=n(2402),oi=n(910),ai=n(2366),si=n(754),ci=n(2358),ui=n(1323);function li(e,t){var n=t.disableHysteresis,r=void 0!==n&&n,i=t.threshold,o=void 0===i?100:i,a=t.target,s=e.current;return a&&(e.current=void 0!==a.pageYOffset?a.pageYOffset:a.scrollTop),!(!r&&void 0!==s&&e.currento}var di="undefined"!==typeof window?window:null;function fi(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.getTrigger,n=void 0===t?li:t,r=e.target,i=void 0===r?di:r,o=Object(R.a)(e,["getTrigger","target"]),a=D.useRef(),s=D.useState((function(){return n(a,o)})),c=s[0],u=s[1];return D.useEffect((function(){var e=function(){u(n(a,Object(O.a)({target:i},o)))};return e(),i.addEventListener("scroll",e),function(){i.removeEventListener("scroll",e)}}),[i,n,JSON.stringify(o)]),c}var hi=n(468),pi=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(t){var n=e.breakpoint,r=void 0===n?"sm":n;return Object(hi.a)()((function(e){return D.createElement(t,Object(O.a)({fullScreen:Object(hi.b)(r,e.width)},e))}))}},mi=n(374),gi=n(2370)},function(e,t,n){"use strict";n.d(t,"h",(function(){return o})),n.d(t,"l",(function(){return a})),n.d(t,"i",(function(){return s})),n.d(t,"c",(function(){return c})),n.d(t,"k",(function(){return u})),n.d(t,"f",(function(){return l})),n.d(t,"g",(function(){return d})),n.d(t,"d",(function(){return f})),n.d(t,"e",(function(){return h})),n.d(t,"a",(function(){return p})),n.d(t,"b",(function(){return m})),n.d(t,"j",(function(){return g}));var r=n(420);function i(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return Math.min(Math.max(t,e),n)}function o(e){e=e.substr(1);var t=new RegExp(".{1,".concat(e.length>=6?2:1,"}"),"g"),n=e.match(t);return n&&1===n[0].length&&(n=n.map((function(e){return e+e}))),n?"rgb".concat(4===n.length?"a":"","(").concat(n.map((function(e,t){return t<3?parseInt(e,16):Math.round(parseInt(e,16)/255*1e3)/1e3})).join(", "),")"):""}function a(e){if(0===e.indexOf("#"))return e;var t=c(e).values;return"#".concat(t.map((function(e){return function(e){var t=e.toString(16);return 1===t.length?"0".concat(t):t}(e)})).join(""))}function s(e){var t=(e=c(e)).values,n=t[0],r=t[1]/100,i=t[2]/100,o=r*Math.min(i,1-i),a=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(e+n/30)%12;return i-o*Math.max(Math.min(t-3,9-t,1),-1)},s="rgb",l=[Math.round(255*a(0)),Math.round(255*a(8)),Math.round(255*a(4))];return"hsla"===e.type&&(s+="a",l.push(t[3])),u({type:s,values:l})}function c(e){if(e.type)return e;if("#"===e.charAt(0))return c(o(e));var t=e.indexOf("("),n=e.substring(0,t);if(-1===["rgb","rgba","hsl","hsla"].indexOf(n))throw new Error(Object(r.a)(3,e));var i=e.substring(t+1,e.length-1).split(",");return{type:n,values:i=i.map((function(e){return parseFloat(e)}))}}function u(e){var t=e.type,n=e.values;return-1!==t.indexOf("rgb")?n=n.map((function(e,t){return t<3?parseInt(e,10):e})):-1!==t.indexOf("hsl")&&(n[1]="".concat(n[1],"%"),n[2]="".concat(n[2],"%")),"".concat(t,"(").concat(n.join(", "),")")}function l(e,t){var n=d(e),r=d(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function d(e){var t="hsl"===(e=c(e)).type?c(s(e)).values:e.values;return t=t.map((function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)})),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.15;return d(e)>.5?m(e,t):g(e,t)}function h(e,t){return p(e,t)}function p(e,t){return e=c(e),t=i(t),"rgb"!==e.type&&"hsl"!==e.type||(e.type+="a"),e.values[3]=t,u(e)}function m(e,t){if(e=c(e),t=i(t),-1!==e.type.indexOf("hsl"))e.values[2]*=1-t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]*=1-t;return u(e)}function g(e,t){if(e=c(e),t=i(t),-1!==e.type.indexOf("hsl"))e.values[2]+=(100-e.values[2])*t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;return u(e)}},function(e,t,n){var r=n(699);e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";e.exports=n(1546)},function(e,t,n){"use strict";var r=n(22),i=n(325);function o(e,t){return t&&"string"===typeof t?t.split(".").reduce((function(e,t){return e&&e[t]?e[t]:null}),e):null}t.a=function(e){var t=e.prop,n=e.cssProperty,a=void 0===n?e.prop:n,s=e.themeKey,c=e.transform,u=function(e){if(null==e[t])return null;var n=e[t],u=o(e.theme,s)||{};return Object(i.b)(e,n,(function(e){var t;return"function"===typeof u?t=u(e):Array.isArray(u)?t=u[e]||e:(t=o(u,e)||e,c&&(t=c(t))),!1===a?t:Object(r.a)({},a,t)}))};return u.propTypes={},u.filterProps=[t],u}},function(e,t,n){"use strict";function r(e,t){return function(){return null}}n.r(t),n.d(t,"chainPropTypes",(function(){return r})),n.d(t,"deepmerge",(function(){return i.a})),n.d(t,"elementAcceptingRef",(function(){return c})),n.d(t,"elementTypeAcceptingRef",(function(){return u})),n.d(t,"exactProp",(function(){return l})),n.d(t,"formatMuiErrorMessage",(function(){return d.a})),n.d(t,"getDisplayName",(function(){return b})),n.d(t,"HTMLElementType",(function(){return y})),n.d(t,"ponyfillGlobal",(function(){return w})),n.d(t,"refType",(function(){return S}));var i=n(536),o=n(7),a=n.n(o);var s=(a.a.element,function(){return null});s.isRequired=(a.a.element.isRequired,function(){return null});var c=s;var u=(o.elementType,function(){return null});n(22),n(2);function l(e){return e}var d=n(420),f=n(128),h=n(93),p=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function m(e){var t="".concat(e).match(p);return t&&t[1]||""}function g(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e.displayName||e.name||m(e)||t}function v(e,t,n){var r=g(t);return e.displayName||(""!==r?"".concat(n,"(").concat(r,")"):n)}function b(e){if(null!=e){if("string"===typeof e)return e;if("function"===typeof e)return g(e,"Component");if("object"===Object(f.a)(e))switch(e.$$typeof){case h.ForwardRef:return v(e,e.render,"ForwardRef");case h.Memo:return v(e,e.type,"memo");default:return}}}function y(e,t,n,r,i){return null}var w="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),S=a.a.oneOfType([a.a.func,a.a.object])},function(e,t){e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t,n){"use strict";function r(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}n.d(t,"a",(function(){return r}))},function(e,t,n){(function(t,n){!function(t){"use strict";"function"===typeof bootstrap?bootstrap("promise",t):e.exports=t()}((function(){"use strict";var e=!1;try{throw new Error}catch(G){e=!!G.stack}var r,i=_(),o=function(){},a=function(){var e={task:void 0,next:null},r=e,i=!1,o=void 0,s=!1,c=[];function u(){for(var t,n;e.next;)t=(e=e.next).task,e.task=void 0,(n=e.domain)&&(e.domain=void 0,n.enter()),l(t,n);for(;c.length;)l(t=c.pop());i=!1}function l(e,t){try{e()}catch(G){if(s)throw t&&t.exit(),setTimeout(u,0),t&&t.enter(),G;setTimeout((function(){throw G}),0)}t&&t.exit()}if(a=function(e){r=r.next={task:e,domain:s&&t.domain,next:null},i||(i=!0,o())},"object"===typeof t&&"[object process]"===t.toString()&&t.nextTick)s=!0,o=function(){t.nextTick(u)};else if("function"===typeof n)o="undefined"!==typeof window?n.bind(window,u):function(){n(u)};else if("undefined"!==typeof MessageChannel){var d=new MessageChannel;d.port1.onmessage=function(){o=f,d.port1.onmessage=u,u()};var f=function(){d.port2.postMessage(0)};o=function(){setTimeout(u,0),f()}}else o=function(){setTimeout(u,0)};return a.runAfter=function(e){c.push(e),i||(i=!0,o())},a}(),s=Function.call;function c(e){return function(){return s.apply(e,arguments)}}var u,l=c(Array.prototype.slice),d=c(Array.prototype.reduce||function(e,t){var n=0,r=this.length;if(1===arguments.length)for(;;){if(n in this){t=this[n++];break}if(++n>=r)throw new TypeError}for(;n=i&&o<=Z}function _(){if(e)try{throw new Error}catch(G){var t=G.stack.split("\n"),n=w(t[0].indexOf("@")>0?t[1]:t[2]);if(!n)return;return r=n[0],n[1]}}function k(e){return e instanceof M?e:I(e)?function(e){var t=x();return k.nextTick((function(){try{e.then(t.resolve,t.reject,t.notify)}catch(n){t.reject(n)}})),t.promise}(e):U(e)}function x(){var t,n=[],r=[],i=p(x.prototype),o=p(M.prototype);if(o.promiseDispatch=function(e,i,o){var a=l(arguments);n?(n.push(a),"when"===i&&o[1]&&r.push(o[1])):k.nextTick((function(){t.promiseDispatch.apply(t,a)}))},o.valueOf=function(){if(n)return o;var e=T(t);return A(e)&&(t=e),e},o.inspect=function(){return t?t.inspect():{state:"pending"}},k.longStackSupport&&e)try{throw new Error}catch(G){o.stack=G.stack.substring(G.stack.indexOf("\n")+1)}function a(e){t=e,o.source=e,d(n,(function(t,n){k.nextTick((function(){e.promiseDispatch.apply(e,n)}))}),void 0),n=void 0,r=void 0}return i.promise=o,i.resolve=function(e){t||a(k(e))},i.fulfill=function(e){t||a(U(e))},i.reject=function(e){t||a(F(e))},i.notify=function(e){t||d(r,(function(t,n){k.nextTick((function(){n(e)}))}),void 0)},i}function E(e){if("function"!==typeof e)throw new TypeError("resolver must be a function.");var t=x();try{e(t.resolve,t.reject,t.notify)}catch(n){t.reject(n)}return t.promise}function O(e){return E((function(t,n){for(var r=0,i=e.length;r2?e.resolve(l(arguments,1)):e.resolve(n)}},k.Promise=E,k.promise=E,E.race=O,E.all=W,E.reject=F,E.resolve=k,k.passByCopy=function(e){return e},M.prototype.passByCopy=function(){return this},k.join=function(e,t){return k(e).join(t)},M.prototype.join=function(e){return k([this,e]).spread((function(e,t){if(e===t)return e;throw new Error("Can't join: not the same: "+e+" "+t)}))},k.race=O,M.prototype.race=function(){return this.then(k.race)},k.makePromise=M,M.prototype.toString=function(){return"[object Promise]"},M.prototype.then=function(e,t,n){var r=this,i=x(),o=!1;return k.nextTick((function(){r.promiseDispatch((function(t){o||(o=!0,i.resolve(function(t){try{return"function"===typeof e?e(t):t}catch(n){return F(n)}}(t)))}),"when",[function(e){o||(o=!0,i.resolve(function(e){if("function"===typeof t){y(e,r);try{return t(e)}catch(n){return F(n)}}return F(e)}(e)))}])})),r.promiseDispatch(void 0,"when",[void 0,function(e){var t,r=!1;try{t=function(e){return"function"===typeof n?n(e):e}(e)}catch(G){if(r=!0,!k.onerror)throw G;k.onerror(G)}r||i.notify(t)}]),i.promise},k.tap=function(e,t){return k(e).tap(t)},M.prototype.tap=function(e){return e=k(e),this.then((function(t){return e.fcall(t).thenResolve(t)}))},k.when=C,M.prototype.thenResolve=function(e){return this.then((function(){return e}))},k.thenResolve=function(e,t){return k(e).thenResolve(t)},M.prototype.thenReject=function(e){return this.then((function(){throw e}))},k.thenReject=function(e,t){return k(e).thenReject(t)},k.nearer=T,k.isPromise=A,k.isPromiseAlike=I,k.isPending=function(e){return A(e)&&"pending"===e.inspect().state},M.prototype.isPending=function(){return"pending"===this.inspect().state},k.isFulfilled=function(e){return!A(e)||"fulfilled"===e.inspect().state},M.prototype.isFulfilled=function(){return"fulfilled"===this.inspect().state},k.isRejected=function(e){return A(e)&&"rejected"===e.inspect().state},M.prototype.isRejected=function(){return"rejected"===this.inspect().state};var P,R,D,N=[],j=[],L=[],B=!0;function z(){N.length=0,j.length=0,B||(B=!0)}function F(e){var n=M({when:function(n){return n&&function(e){if(B){var n=f(j,e);-1!==n&&("object"===typeof t&&"function"===typeof t.emit&&k.nextTick.runAfter((function(){var r=f(L,e);-1!==r&&(t.emit("rejectionHandled",N[n],e),L.splice(r,1))})),j.splice(n,1),N.splice(n,1))}}(this),n?n(e):this}},(function(){return this}),(function(){return{state:"rejected",reason:e}}));return function(e,n){B&&("object"===typeof t&&"function"===typeof t.emit&&k.nextTick.runAfter((function(){-1!==f(j,e)&&(t.emit("unhandledRejection",n,e),L.push(e))})),j.push(e),n&&"undefined"!==typeof n.stack?N.push(n.stack):N.push("(no stack) "+n))}(n,e),n}function U(e){return M({when:function(){return e},get:function(t){return e[t]},set:function(t,n){e[t]=n},delete:function(t){delete e[t]},post:function(t,n){return null===t||void 0===t?e.apply(void 0,n):e[t].apply(e,n)},apply:function(t,n){return e.apply(t,n)},keys:function(){return g(e)}},void 0,(function(){return{state:"fulfilled",value:e}}))}function q(e,t,n){return k(e).spread(t,n)}function V(e,t,n){return k(e).dispatch(t,n)}function W(e){return C(e,(function(e){var t=0,n=x();return d(e,(function(r,i,o){var a;A(i)&&"fulfilled"===(a=i.inspect()).state?e[o]=a.value:(++t,C(i,(function(r){e[o]=r,0===--t&&n.resolve(e)}),n.reject,(function(e){n.notify({index:o,value:e})})))}),void 0),0===t&&n.resolve(e),n.promise}))}function H(e){if(0===e.length)return k.resolve();var t=k.defer(),n=0;return d(e,(function(r,i,o){var a=e[o];n++,C(a,(function(e){t.resolve(e)}),(function(){0===--n&&t.reject(new Error("Can't get fulfillment value from any promise, all promises were rejected."))}),(function(e){t.notify({index:o,value:e})}))}),void 0),t.promise}function K(e){return C(e,(function(e){return e=h(e,k),C(W(h(e,(function(e){return C(e,o,o)}))),(function(){return e}))}))}k.resetUnhandledRejections=z,k.getUnhandledReasons=function(){return N.slice()},k.stopUnhandledRejectionTracking=function(){z(),B=!1},z(),k.reject=F,k.fulfill=U,k.master=function(e){return M({isDef:function(){}},(function(t,n){return V(e,t,n)}),(function(){return k(e).inspect()}))},k.spread=q,M.prototype.spread=function(e,t){return this.all().then((function(t){return e.apply(void 0,t)}),t)},k.async=function(e){return function(){function t(e,t){var o;if("undefined"===typeof StopIteration){try{o=n[e](t)}catch(a){return F(a)}return o.done?k(o.value):C(o.value,r,i)}try{o=n[e](t)}catch(a){return b(a)?k(a.value):F(a)}return C(o,r,i)}var n=e.apply(this,arguments),r=t.bind(t,"next"),i=t.bind(t,"throw");return r()}},k.spawn=function(e){k.done(k.async(e)())},k.return=function(e){throw new u(e)},k.promised=function(e){return function(){return q([this,W(arguments)],(function(t,n){return e.apply(t,n)}))}},k.dispatch=V,M.prototype.dispatch=function(e,t){var n=this,r=x();return k.nextTick((function(){n.promiseDispatch(r.resolve,e,t)})),r.promise},k.get=function(e,t){return k(e).dispatch("get",[t])},M.prototype.get=function(e){return this.dispatch("get",[e])},k.set=function(e,t,n){return k(e).dispatch("set",[t,n])},M.prototype.set=function(e,t){return this.dispatch("set",[e,t])},k.del=k.delete=function(e,t){return k(e).dispatch("delete",[t])},M.prototype.del=M.prototype.delete=function(e){return this.dispatch("delete",[e])},k.mapply=k.post=function(e,t,n){return k(e).dispatch("post",[t,n])},M.prototype.mapply=M.prototype.post=function(e,t){return this.dispatch("post",[e,t])},k.send=k.mcall=k.invoke=function(e,t){return k(e).dispatch("post",[t,l(arguments,2)])},M.prototype.send=M.prototype.mcall=M.prototype.invoke=function(e){return this.dispatch("post",[e,l(arguments,1)])},k.fapply=function(e,t){return k(e).dispatch("apply",[void 0,t])},M.prototype.fapply=function(e){return this.dispatch("apply",[void 0,e])},k.try=k.fcall=function(e){return k(e).dispatch("apply",[void 0,l(arguments,1)])},M.prototype.fcall=function(){return this.dispatch("apply",[void 0,l(arguments)])},k.fbind=function(e){var t=k(e),n=l(arguments,1);return function(){return t.dispatch("apply",[this,n.concat(l(arguments))])}},M.prototype.fbind=function(){var e=this,t=l(arguments);return function(){return e.dispatch("apply",[this,t.concat(l(arguments))])}},k.keys=function(e){return k(e).dispatch("keys",[])},M.prototype.keys=function(){return this.dispatch("keys",[])},k.all=W,M.prototype.all=function(){return W(this)},k.any=H,M.prototype.any=function(){return H(this)},k.allResolved=(P=K,R="allResolved",D="allSettled",function(){return"undefined"!==typeof console&&"function"===typeof console.warn&&console.warn(R+" is deprecated, use "+D+" instead.",new Error("").stack),P.apply(P,arguments)}),M.prototype.allResolved=function(){return K(this)},k.allSettled=function(e){return k(e).allSettled()},M.prototype.allSettled=function(){return this.then((function(e){return W(h(e,(function(e){function t(){return e.inspect()}return(e=k(e)).then(t,t)})))}))},k.fail=k.catch=function(e,t){return k(e).then(void 0,t)},M.prototype.fail=M.prototype.catch=function(e){return this.then(void 0,e)},k.progress=function(e,t){return k(e).then(void 0,void 0,t)},M.prototype.progress=function(e){return this.then(void 0,void 0,e)},k.fin=k.finally=function(e,t){return k(e).finally(t)},M.prototype.fin=M.prototype.finally=function(e){return e=k(e),this.then((function(t){return e.fcall().then((function(){return t}))}),(function(t){return e.fcall().then((function(){throw t}))}))},k.done=function(e,t,n,r){return k(e).done(t,n,r)},M.prototype.done=function(e,n,r){var i=function(e){k.nextTick((function(){if(y(e,o),!k.onerror)throw e;k.onerror(e)}))},o=e||n||r?this.then(e,n,r):this;"object"===typeof t&&t&&t.domain&&(i=t.domain.bind(i)),o.then(void 0,i)},k.timeout=function(e,t,n){return k(e).timeout(t,n)},M.prototype.timeout=function(e,t){var n=x(),r=setTimeout((function(){t&&"string"!==typeof t||((t=new Error(t||"Timed out after "+e+" ms")).code="ETIMEDOUT"),n.reject(t)}),e);return this.then((function(e){clearTimeout(r),n.resolve(e)}),(function(e){clearTimeout(r),n.reject(e)}),n.notify),n.promise},k.delay=function(e,t){return void 0===t&&(t=e,e=void 0),k(e).delay(t)},M.prototype.delay=function(e){return this.then((function(t){var n=x();return setTimeout((function(){n.resolve(t)}),e),n.promise}))},k.nfapply=function(e,t){return k(e).nfapply(t)},M.prototype.nfapply=function(e){var t=x(),n=l(e);return n.push(t.makeNodeResolver()),this.fapply(n).fail(t.reject),t.promise},k.nfcall=function(e){var t=l(arguments,1);return k(e).nfapply(t)},M.prototype.nfcall=function(){var e=l(arguments),t=x();return e.push(t.makeNodeResolver()),this.fapply(e).fail(t.reject),t.promise},k.nfbind=k.denodeify=function(e){var t=l(arguments,1);return function(){var n=t.concat(l(arguments)),r=x();return n.push(r.makeNodeResolver()),k(e).fapply(n).fail(r.reject),r.promise}},M.prototype.nfbind=M.prototype.denodeify=function(){var e=l(arguments);return e.unshift(this),k.denodeify.apply(void 0,e)},k.nbind=function(e,t){var n=l(arguments,2);return function(){var r=n.concat(l(arguments)),i=x();function o(){return e.apply(t,arguments)}return r.push(i.makeNodeResolver()),k(o).fapply(r).fail(i.reject),i.promise}},M.prototype.nbind=function(){var e=l(arguments,0);return e.unshift(this),k.nbind.apply(void 0,e)},k.nmapply=k.npost=function(e,t,n){return k(e).npost(t,n)},M.prototype.nmapply=M.prototype.npost=function(e,t){var n=l(t||[]),r=x();return n.push(r.makeNodeResolver()),this.dispatch("post",[e,n]).fail(r.reject),r.promise},k.nsend=k.nmcall=k.ninvoke=function(e,t){var n=l(arguments,2),r=x();return n.push(r.makeNodeResolver()),k(e).dispatch("post",[t,n]).fail(r.reject),r.promise},M.prototype.nsend=M.prototype.nmcall=M.prototype.ninvoke=function(e){var t=l(arguments,1),n=x();return t.push(n.makeNodeResolver()),this.dispatch("post",[e,t]).fail(n.reject),n.promise},k.nodeify=function(e,t){return k(e).nodeify(t)},M.prototype.nodeify=function(e){if(!e)return this;this.then((function(t){k.nextTick((function(){e(null,t)}))}),(function(t){k.nextTick((function(){e(t)}))}))},k.noConflict=function(){throw new Error("Q.noConflict only works when Q is used as a global")};var Z=_();return k}))}).call(this,n(81),n(506).setImmediate)},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(540);var i=n(327),o=n(541);function a(e,t){return Object(r.a)(e)||function(e,t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(c){i=!0,o=c}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}}(e,t)||Object(i.a)(e,t)||Object(o.a)()}},function(e,t){"function"===typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}}},function(e,t,n){var r={util:n(100)};({}).toString(),e.exports=r,r.util.update(r,{VERSION:"2.946.0",Signers:{},Protocol:{Json:n(700),Query:n(1053),Rest:n(512),RestJson:n(1055),RestXml:n(1056)},XML:{Builder:n(2072),Parser:null},JSON:{Builder:n(701),Parser:n(702)},Model:{Api:n(1057),Operation:n(1058),Shape:n(402),Paginator:n(1059),ResourceWaiter:n(1060)},apiLoader:n(2077),EndpointCache:n(2078).EndpointCache}),n(1062),n(2080),n(2082),n(1065),n(2083),n(2088),n(2090),n(2091),n(2092),n(2098),r.events=new r.SequentialExecutor,r.util.memoizedProperty(r,"endpointCache",(function(){return new r.EndpointCache(r.config.endpointCacheSize)}),!0)},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 a[e];var n,o=String(e);return(n=r[o.toLowerCase()])?n:(n=i[o.toLowerCase()])||(1===o.length?o.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 o;if(o=r[t.toLowerCase()])return o===n;if(o=i[t.toLowerCase()])return o===n}else if("number"===typeof t)return t===n;return!1}};var r=(t=e.exports=n).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,"\u21e7":16,"\u2325":18,"\u2303":17,"\u2318":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(o=97;o<123;o++)r[String.fromCharCode(o)]=o-32;for(var o=48;o<58;o++)r[o-48]=o;for(o=1;o<13;o++)r["f"+o]=o+111;for(o=0;o<10;o++)r["numpad "+o]=o+96;var a=t.names=t.title={};for(o in r)a[r[o]]=o;for(var s in i)r[s]=i[s]},function(e,t,n){(function(t){var n=function(e){return e&&e.Math==Math&&e};e.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof t&&t)||function(){return this}()||Function("return this")()}).call(this,n(56))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReactCSS=t.loop=t.handleActive=t.handleHover=t.hover=void 0;var r=u(n(1869)),i=u(n(1874)),o=u(n(1875)),a=u(n(1876)),s=u(n(1877)),c=u(n(1878));function u(e){return e&&e.__esModule?e:{default:e}}t.hover=a.default,t.handleHover=a.default,t.handleActive=s.default,t.loop=c.default;var l=t.ReactCSS=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),a=1;a>>0;for(t=0;t0)for(n=0;n=0?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}r.suppressDeprecationWarnings=!1,r.deprecationHandler=null,x=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)a(e,t)&&n.push(t);return n};var I=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,P=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,R={},D={};function N(e,t,n,r){var i=r;"string"===typeof r&&(i=function(){return this[r]()}),e&&(D[e]=i),t&&(D[t[0]]=function(){return A(i.apply(this,arguments),t[1],t[2])}),n&&(D[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),e)})}function j(e,t){return e.isValid()?(t=L(t,e.localeData()),R[t]=R[t]||function(e){var t,n,r,i=e.match(I);for(t=0,n=i.length;t=0&&P.test(e);)e=e.replace(P,r),P.lastIndex=0,n-=1;return e}var B={};function z(e,t){var n=e.toLowerCase();B[n]=B[n+"s"]=B[t]=e}function F(e){return"string"===typeof e?B[e]||B[e.toLowerCase()]:void 0}function U(e){var t,n,r={};for(n in e)a(e,n)&&(t=F(n))&&(r[t]=e[n]);return r}var q={};function V(e,t){q[e]=t}function W(e){return e%4===0&&e%100!==0||e%400===0}function H(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function K(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=H(t)),n}function Z(e,t){return function(n){return null!=n?(X(this,e,n),r.updateOffset(this,t),this):G(this,e)}}function G(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function X(e,t,n){e.isValid()&&!isNaN(n)&&("FullYear"===t&&W(e.year())&&1===e.month()&&29===e.date()?(n=K(n),e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),Se(n,e.month()))):e._d["set"+(e._isUTC?"UTC":"")+t](n))}var Y,$=/\d/,J=/\d\d/,Q=/\d{3}/,ee=/\d{4}/,te=/[+-]?\d{6}/,ne=/\d\d?/,re=/\d\d\d\d?/,ie=/\d\d\d\d\d\d?/,oe=/\d{1,3}/,ae=/\d{1,4}/,se=/[+-]?\d{1,6}/,ce=/\d+/,ue=/[+-]?\d+/,le=/Z|[+-]\d\d:?\d\d/gi,de=/Z|[+-]\d\d(?::?\d\d)?/gi,fe=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;function he(e,t,n){Y[e]=M(t)?t:function(e,r){return e&&n?n:t}}function pe(e,t){return a(Y,e)?Y[e](t._strict,t._locale):new RegExp(me(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(e,t,n,r,i){return t||n||r||i}))))}function me(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}Y={};var ge,ve={};function be(e,t){var n,r=t;for("string"===typeof e&&(e=[e]),u(t)&&(r=function(e,n){n[t]=K(e)}),n=0;n68?1900:2e3)};var Pe=Z("FullYear",!0);function Re(e,t,n,r,i,o,a){var s;return e<100&&e>=0?(s=new Date(e+400,t,n,r,i,o,a),isFinite(s.getFullYear())&&s.setFullYear(e)):s=new Date(e,t,n,r,i,o,a),s}function De(e){var t,n;return e<100&&e>=0?((n=Array.prototype.slice.call(arguments))[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function Ne(e,t,n){var r=7+t-n;return-(7+De(e,0,r).getUTCDay()-t)%7+r-1}function je(e,t,n,r,i){var o,a,s=1+7*(t-1)+(7+n-r)%7+Ne(e,r,i);return s<=0?a=Ie(o=e-1)+s:s>Ie(e)?(o=e+1,a=s-Ie(e)):(o=e,a=s),{year:o,dayOfYear:a}}function Le(e,t,n){var r,i,o=Ne(e.year(),t,n),a=Math.floor((e.dayOfYear()-o-1)/7)+1;return a<1?r=a+Be(i=e.year()-1,t,n):a>Be(e.year(),t,n)?(r=a-Be(e.year(),t,n),i=e.year()+1):(i=e.year(),r=a),{week:r,year:i}}function Be(e,t,n){var r=Ne(e,t,n),i=Ne(e+1,t,n);return(Ie(e)-r+i)/7}function ze(e,t){return e.slice(t,7).concat(e.slice(0,t))}N("w",["ww",2],"wo","week"),N("W",["WW",2],"Wo","isoWeek"),z("week","w"),z("isoWeek","W"),V("week",5),V("isoWeek",5),he("w",ne),he("ww",ne,J),he("W",ne),he("WW",ne,J),ye(["w","ww","W","WW"],(function(e,t,n,r){t[r.substr(0,1)]=K(e)})),N("d",0,"do","day"),N("dd",0,0,(function(e){return this.localeData().weekdaysMin(this,e)})),N("ddd",0,0,(function(e){return this.localeData().weekdaysShort(this,e)})),N("dddd",0,0,(function(e){return this.localeData().weekdays(this,e)})),N("e",0,0,"weekday"),N("E",0,0,"isoWeekday"),z("day","d"),z("weekday","e"),z("isoWeekday","E"),V("day",11),V("weekday",11),V("isoWeekday",11),he("d",ne),he("e",ne),he("E",ne),he("dd",(function(e,t){return t.weekdaysMinRegex(e)})),he("ddd",(function(e,t){return t.weekdaysShortRegex(e)})),he("dddd",(function(e,t){return t.weekdaysRegex(e)})),ye(["dd","ddd","dddd"],(function(e,t,n,r){var i=n._locale.weekdaysParse(e,r,n._strict);null!=i?t.d=i:p(n).invalidWeekday=e})),ye(["d","e","E"],(function(e,t,n,r){t[r]=K(e)}));var Fe="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ue="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),qe="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Ve=fe,We=fe,He=fe;function Ke(e,t,n){var r,i,o,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)o=h([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(o,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(o,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(o,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(i=ge.call(this._weekdaysParse,a))?i:null:"ddd"===t?-1!==(i=ge.call(this._shortWeekdaysParse,a))?i:null:-1!==(i=ge.call(this._minWeekdaysParse,a))?i:null:"dddd"===t?-1!==(i=ge.call(this._weekdaysParse,a))||-1!==(i=ge.call(this._shortWeekdaysParse,a))||-1!==(i=ge.call(this._minWeekdaysParse,a))?i:null:"ddd"===t?-1!==(i=ge.call(this._shortWeekdaysParse,a))||-1!==(i=ge.call(this._weekdaysParse,a))||-1!==(i=ge.call(this._minWeekdaysParse,a))?i:null:-1!==(i=ge.call(this._minWeekdaysParse,a))||-1!==(i=ge.call(this._weekdaysParse,a))||-1!==(i=ge.call(this._shortWeekdaysParse,a))?i:null}function Ze(){function e(e,t){return t.length-e.length}var t,n,r,i,o,a=[],s=[],c=[],u=[];for(t=0;t<7;t++)n=h([2e3,1]).day(t),r=me(this.weekdaysMin(n,"")),i=me(this.weekdaysShort(n,"")),o=me(this.weekdays(n,"")),a.push(r),s.push(i),c.push(o),u.push(r),u.push(i),u.push(o);a.sort(e),s.sort(e),c.sort(e),u.sort(e),this._weekdaysRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+a.join("|")+")","i")}function Ge(){return this.hours()%12||12}function Xe(e,t){N(e,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)}))}function Ye(e,t){return t._meridiemParse}N("H",["HH",2],0,"hour"),N("h",["hh",2],0,Ge),N("k",["kk",2],0,(function(){return this.hours()||24})),N("hmm",0,0,(function(){return""+Ge.apply(this)+A(this.minutes(),2)})),N("hmmss",0,0,(function(){return""+Ge.apply(this)+A(this.minutes(),2)+A(this.seconds(),2)})),N("Hmm",0,0,(function(){return""+this.hours()+A(this.minutes(),2)})),N("Hmmss",0,0,(function(){return""+this.hours()+A(this.minutes(),2)+A(this.seconds(),2)})),Xe("a",!0),Xe("A",!1),z("hour","h"),V("hour",13),he("a",Ye),he("A",Ye),he("H",ne),he("h",ne),he("k",ne),he("HH",ne,J),he("hh",ne,J),he("kk",ne,J),he("hmm",re),he("hmmss",ie),he("Hmm",re),he("Hmmss",ie),be(["H","HH"],3),be(["k","kk"],(function(e,t,n){var r=K(e);t[3]=24===r?0:r})),be(["a","A"],(function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e})),be(["h","hh"],(function(e,t,n){t[3]=K(e),p(n).bigHour=!0})),be("hmm",(function(e,t,n){var r=e.length-2;t[3]=K(e.substr(0,r)),t[4]=K(e.substr(r)),p(n).bigHour=!0})),be("hmmss",(function(e,t,n){var r=e.length-4,i=e.length-2;t[3]=K(e.substr(0,r)),t[4]=K(e.substr(r,2)),t[5]=K(e.substr(i)),p(n).bigHour=!0})),be("Hmm",(function(e,t,n){var r=e.length-2;t[3]=K(e.substr(0,r)),t[4]=K(e.substr(r))})),be("Hmmss",(function(e,t,n){var r=e.length-4,i=e.length-2;t[3]=K(e.substr(0,r)),t[4]=K(e.substr(r,2)),t[5]=K(e.substr(i))}));var $e,Je=Z("Hours",!0),Qe={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:_e,monthsShort:ke,week:{dow:0,doy:6},weekdays:Fe,weekdaysMin:qe,weekdaysShort:Ue,meridiemParse:/[ap]\.?m?\.?/i},et={},tt={};function nt(e,t){var n,r=Math.min(e.length,t.length);for(n=0;n0;){if(r=it(i.slice(0,t).join("-")))return r;if(n&&n.length>=t&&nt(i,n)>=t-1)break;t--}o++}return $e}(e)}function ct(e){var t,n=e._a;return n&&-2===p(e).overflow&&(t=n[1]<0||n[1]>11?1:n[2]<1||n[2]>Se(n[0],n[1])?2:n[3]<0||n[3]>24||24===n[3]&&(0!==n[4]||0!==n[5]||0!==n[6])?3:n[4]<0||n[4]>59?4:n[5]<0||n[5]>59?5:n[6]<0||n[6]>999?6:-1,p(e)._overflowDayOfYear&&(t<0||t>2)&&(t=2),p(e)._overflowWeeks&&-1===t&&(t=7),p(e)._overflowWeekday&&-1===t&&(t=8),p(e).overflow=t),e}var ut=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,lt=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,dt=/Z|[+-]\d\d(?::?\d\d)?/,ft=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],ht=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],pt=/^\/?Date\((-?\d+)/i,mt=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,gt={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function vt(e){var t,n,r,i,o,a,s=e._i,c=ut.exec(s)||lt.exec(s);if(c){for(p(e).iso=!0,t=0,n=ft.length;t7)&&(c=!0)):(o=e._locale._week.dow,a=e._locale._week.doy,u=Le(Et(),o,a),n=wt(t.gg,e._a[0],u.year),r=wt(t.w,u.week),null!=t.d?((i=t.d)<0||i>6)&&(c=!0):null!=t.e?(i=t.e+o,(t.e<0||t.e>6)&&(c=!0)):i=o),r<1||r>Be(n,o,a)?p(e)._overflowWeeks=!0:null!=c?p(e)._overflowWeekday=!0:(s=je(n,r,i,o,a),e._a[0]=s.year,e._dayOfYear=s.dayOfYear)}(e),null!=e._dayOfYear&&(a=wt(e._a[0],i[0]),(e._dayOfYear>Ie(a)||0===e._dayOfYear)&&(p(e)._overflowDayOfYear=!0),n=De(a,0,e._dayOfYear),e._a[1]=n.getUTCMonth(),e._a[2]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=s[t]=i[t];for(;t<7;t++)e._a[t]=s[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[3]&&0===e._a[4]&&0===e._a[5]&&0===e._a[6]&&(e._nextDay=!0,e._a[3]=0),e._d=(e._useUTC?De:Re).apply(null,s),o=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[3]=24),e._w&&"undefined"!==typeof e._w.d&&e._w.d!==o&&(p(e).weekdayMismatch=!0)}}function _t(e){if(e._f!==r.ISO_8601)if(e._f!==r.RFC_2822){e._a=[],p(e).empty=!0;var t,n,i,o,a,s,c=""+e._i,u=c.length,l=0;for(i=L(e._f,e._locale).match(I)||[],t=0;t0&&p(e).unusedInput.push(a),c=c.slice(c.indexOf(n)+n.length),l+=n.length),D[o]?(n?p(e).empty=!1:p(e).unusedTokens.push(o),we(o,n,e)):e._strict&&!n&&p(e).unusedTokens.push(o);p(e).charsLeftOver=u-l,c.length>0&&p(e).unusedInput.push(c),e._a[3]<=12&&!0===p(e).bigHour&&e._a[3]>0&&(p(e).bigHour=void 0),p(e).parsedDateParts=e._a.slice(0),p(e).meridiem=e._meridiem,e._a[3]=function(e,t,n){var r;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((r=e.isPM(n))&&t<12&&(t+=12),r||12!==t||(t=0),t):t}(e._locale,e._a[3],e._meridiem),null!==(s=p(e).era)&&(e._a[0]=e._locale.erasConvertYear(s,e._a[0])),St(e),ct(e)}else yt(e);else vt(e)}function kt(e){var t=e._i,n=e._f;return e._locale=e._locale||st(e._l),null===t||void 0===n&&""===t?g({nullInput:!0}):("string"===typeof t&&(e._i=t=e._locale.preparse(t)),S(t)?new w(ct(t)):(l(t)?e._d=t:i(n)?function(e){var t,n,r,i,o,a,s=!1;if(0===e._f.length)return p(e).invalidFormat=!0,void(e._d=new Date(NaN));for(i=0;ithis?this:e:g()}));function Ct(e,t){var n,r;if(1===t.length&&i(t[0])&&(t=t[0]),!t.length)return Et();for(n=t[0],r=1;r=0?new Date(e+400,t,n)-126227808e5:new Date(e,t,n).valueOf()}function rn(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-126227808e5:Date.UTC(e,t,n)}function on(e,t){return t.erasAbbrRegex(e)}function an(){var e,t,n=[],r=[],i=[],o=[],a=this.eras();for(e=0,t=a.length;e(o=Be(e,r,i))&&(t=o),un.call(this,e,t,n,r,i))}function un(e,t,n,r,i){var o=je(e,t,n,r,i),a=De(o.year,0,o.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}N("N",0,0,"eraAbbr"),N("NN",0,0,"eraAbbr"),N("NNN",0,0,"eraAbbr"),N("NNNN",0,0,"eraName"),N("NNNNN",0,0,"eraNarrow"),N("y",["y",1],"yo","eraYear"),N("y",["yy",2],0,"eraYear"),N("y",["yyy",3],0,"eraYear"),N("y",["yyyy",4],0,"eraYear"),he("N",on),he("NN",on),he("NNN",on),he("NNNN",(function(e,t){return t.erasNameRegex(e)})),he("NNNNN",(function(e,t){return t.erasNarrowRegex(e)})),be(["N","NN","NNN","NNNN","NNNNN"],(function(e,t,n,r){var i=n._locale.erasParse(e,r,n._strict);i?p(n).era=i:p(n).invalidEra=e})),he("y",ce),he("yy",ce),he("yyy",ce),he("yyyy",ce),he("yo",(function(e,t){return t._eraYearOrdinalRegex||ce})),be(["y","yy","yyy","yyyy"],0),be(["yo"],(function(e,t,n,r){var i;n._locale._eraYearOrdinalRegex&&(i=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[0]=n._locale.eraYearOrdinalParse(e,i):t[0]=parseInt(e,10)})),N(0,["gg",2],0,(function(){return this.weekYear()%100})),N(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),sn("gggg","weekYear"),sn("ggggg","weekYear"),sn("GGGG","isoWeekYear"),sn("GGGGG","isoWeekYear"),z("weekYear","gg"),z("isoWeekYear","GG"),V("weekYear",1),V("isoWeekYear",1),he("G",ue),he("g",ue),he("GG",ne,J),he("gg",ne,J),he("GGGG",ae,ee),he("gggg",ae,ee),he("GGGGG",se,te),he("ggggg",se,te),ye(["gggg","ggggg","GGGG","GGGGG"],(function(e,t,n,r){t[r.substr(0,2)]=K(e)})),ye(["gg","GG"],(function(e,t,n,i){t[i]=r.parseTwoDigitYear(e)})),N("Q",0,"Qo","quarter"),z("quarter","Q"),V("quarter",7),he("Q",$),be("Q",(function(e,t){t[1]=3*(K(e)-1)})),N("D",["DD",2],"Do","date"),z("date","D"),V("date",9),he("D",ne),he("DD",ne,J),he("Do",(function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient})),be(["D","DD"],2),be("Do",(function(e,t){t[2]=K(e.match(ne)[0])}));var ln=Z("Date",!0);N("DDD",["DDDD",3],"DDDo","dayOfYear"),z("dayOfYear","DDD"),V("dayOfYear",4),he("DDD",oe),he("DDDD",Q),be(["DDD","DDDD"],(function(e,t,n){n._dayOfYear=K(e)})),N("m",["mm",2],0,"minute"),z("minute","m"),V("minute",14),he("m",ne),he("mm",ne,J),be(["m","mm"],4);var dn=Z("Minutes",!1);N("s",["ss",2],0,"second"),z("second","s"),V("second",15),he("s",ne),he("ss",ne,J),be(["s","ss"],5);var fn,hn,pn=Z("Seconds",!1);for(N("S",0,0,(function(){return~~(this.millisecond()/100)})),N(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),N(0,["SSS",3],0,"millisecond"),N(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),N(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),N(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),N(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),N(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),N(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),z("millisecond","ms"),V("millisecond",16),he("S",oe,$),he("SS",oe,J),he("SSS",oe,Q),fn="SSSS";fn.length<=9;fn+="S")he(fn,ce);function mn(e,t){t[6]=K(1e3*("0."+e))}for(fn="S";fn.length<=9;fn+="S")be(fn,mn);hn=Z("Milliseconds",!1),N("z",0,0,"zoneAbbr"),N("zz",0,0,"zoneName");var gn=w.prototype;function vn(e){return e}gn.add=Kt,gn.calendar=function(e,t){1===arguments.length&&(Xt(arguments[0])?(e=arguments[0],t=void 0):Yt(arguments[0])&&(t=arguments[0],e=void 0));var n=e||Et(),i=jt(n,this).startOf("day"),o=r.calendarFormat(this,i)||"sameElse",a=t&&(M(t[o])?t[o].call(this,n):t[o]);return this.format(a||this.localeData().calendar(o,this,Et(n)))},gn.clone=function(){return new w(this)},gn.diff=function(e,t,n){var r,i,o;if(!this.isValid())return NaN;if(!(r=jt(e,this)).isValid())return NaN;switch(i=6e4*(r.utcOffset()-this.utcOffset()),t=F(t)){case"year":o=$t(this,r)/12;break;case"month":o=$t(this,r);break;case"quarter":o=$t(this,r)/3;break;case"second":o=(this-r)/1e3;break;case"minute":o=(this-r)/6e4;break;case"hour":o=(this-r)/36e5;break;case"day":o=(this-r-i)/864e5;break;case"week":o=(this-r-i)/6048e5;break;default:o=this-r}return n?o:H(o)},gn.endOf=function(e){var t,n;if(void 0===(e=F(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?rn:nn,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=36e5-tn(t+(this._isUTC?0:6e4*this.utcOffset()),36e5)-1;break;case"minute":t=this._d.valueOf(),t+=6e4-tn(t,6e4)-1;break;case"second":t=this._d.valueOf(),t+=1e3-tn(t,1e3)-1}return this._d.setTime(t),r.updateOffset(this,!0),this},gn.format=function(e){e||(e=this.isUtc()?r.defaultFormatUtc:r.defaultFormat);var t=j(this,e);return this.localeData().postformat(t)},gn.from=function(e,t){return this.isValid()&&(S(e)&&e.isValid()||Et(e).isValid())?Ut({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},gn.fromNow=function(e){return this.from(Et(),e)},gn.to=function(e,t){return this.isValid()&&(S(e)&&e.isValid()||Et(e).isValid())?Ut({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},gn.toNow=function(e){return this.to(Et(),e)},gn.get=function(e){return M(this[e=F(e)])?this[e]():this},gn.invalidAt=function(){return p(this).overflow},gn.isAfter=function(e,t){var n=S(e)?e:Et(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=F(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()9999?j(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):M(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",j(n,"Z")):j(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},gn.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,r="moment",i="";return this.isLocal()||(r=0===this.utcOffset()?"moment.utc":"moment.parseZone",i="Z"),e="["+r+'("]',t=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",n=i+'[")]',this.format(e+t+"-MM-DD[T]HH:mm:ss.SSS"+n)},"undefined"!==typeof Symbol&&null!=Symbol.for&&(gn[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),gn.toJSON=function(){return this.isValid()?this.toISOString():null},gn.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},gn.unix=function(){return Math.floor(this.valueOf()/1e3)},gn.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},gn.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},gn.eraName=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;ethis.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},gn.isLocal=function(){return!!this.isValid()&&!this._isUTC},gn.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},gn.isUtc=Bt,gn.isUTC=Bt,gn.zoneAbbr=function(){return this._isUTC?"UTC":""},gn.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},gn.dates=k("dates accessor is deprecated. Use date instead.",ln),gn.months=k("months accessor is deprecated. Use month instead",Te),gn.years=k("years accessor is deprecated. Use year instead",Pe),gn.zone=k("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(e,t){return null!=e?("string"!==typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()})),gn.isDSTShifted=k("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!c(this._isDSTShifted))return this._isDSTShifted;var e,t={};return y(t,this),(t=kt(t))._a?(e=t._isUTC?h(t._a):Et(t._a),this._isDSTShifted=this.isValid()&&function(e,t,n){var r,i=Math.min(e.length,t.length),o=Math.abs(e.length-t.length),a=0;for(r=0;r0):this._isDSTShifted=!1,this._isDSTShifted}));var bn=T.prototype;function yn(e,t,n,r){var i=st(),o=h().set(r,t);return i[n](o,e)}function wn(e,t,n){if(u(e)&&(t=e,e=void 0),e=e||"",null!=t)return yn(e,t,n,"month");var r,i=[];for(r=0;r<12;r++)i[r]=yn(e,r,n,"month");return i}function Sn(e,t,n,r){"boolean"===typeof e?(u(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,u(t)&&(n=t,t=void 0),t=t||"");var i,o=st(),a=e?o._week.dow:0,s=[];if(null!=n)return yn(t,(n+a)%7,r,"day");for(i=0;i<7;i++)s[i]=yn(t,(i+a)%7,r,"day");return s}bn.calendar=function(e,t,n){var r=this._calendar[e]||this._calendar.sameElse;return M(r)?r.call(t,n):r},bn.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(I).map((function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e})).join(""),this._longDateFormat[e])},bn.invalidDate=function(){return this._invalidDate},bn.ordinal=function(e){return this._ordinal.replace("%d",e)},bn.preparse=vn,bn.postformat=vn,bn.relativeTime=function(e,t,n,r){var i=this._relativeTime[n];return M(i)?i(e,t,n,r):i.replace(/%d/i,e)},bn.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return M(n)?n(t):n.replace(/%s/i,t)},bn.set=function(e){var t,n;for(n in e)a(e,n)&&(M(t=e[n])?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},bn.eras=function(e,t){var n,i,o,a=this._eras||st("en")._eras;for(n=0,i=a.length;n=0)return c[r]},bn.erasConvertYear=function(e,t){var n=e.since<=e.until?1:-1;return void 0===t?r(e.since).year():r(e.since).year()+(t-e.offset)*n},bn.erasAbbrRegex=function(e){return a(this,"_erasAbbrRegex")||an.call(this),e?this._erasAbbrRegex:this._erasRegex},bn.erasNameRegex=function(e){return a(this,"_erasNameRegex")||an.call(this),e?this._erasNameRegex:this._erasRegex},bn.erasNarrowRegex=function(e){return a(this,"_erasNarrowRegex")||an.call(this),e?this._erasNarrowRegex:this._erasRegex},bn.months=function(e,t){return e?i(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||xe).test(t)?"format":"standalone"][e.month()]:i(this._months)?this._months:this._months.standalone},bn.monthsShort=function(e,t){return e?i(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[xe.test(t)?"format":"standalone"][e.month()]:i(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},bn.monthsParse=function(e,t,n){var r,i,o;if(this._monthsParseExact)return Me.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(i=h([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(o="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(o.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[r].test(e))return r;if(n&&"MMM"===t&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}},bn.monthsRegex=function(e){return this._monthsParseExact?(a(this,"_monthsRegex")||Ae.call(this),e?this._monthsStrictRegex:this._monthsRegex):(a(this,"_monthsRegex")||(this._monthsRegex=Oe),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},bn.monthsShortRegex=function(e){return this._monthsParseExact?(a(this,"_monthsRegex")||Ae.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(a(this,"_monthsShortRegex")||(this._monthsShortRegex=Ee),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},bn.week=function(e){return Le(e,this._week.dow,this._week.doy).week},bn.firstDayOfYear=function(){return this._week.doy},bn.firstDayOfWeek=function(){return this._week.dow},bn.weekdays=function(e,t){var n=i(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?ze(n,this._week.dow):e?n[e.day()]:n},bn.weekdaysMin=function(e){return!0===e?ze(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin},bn.weekdaysShort=function(e){return!0===e?ze(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort},bn.weekdaysParse=function(e,t,n){var r,i,o;if(this._weekdaysParseExact)return Ke.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(i=h([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(o="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(o.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}},bn.weekdaysRegex=function(e){return this._weekdaysParseExact?(a(this,"_weekdaysRegex")||Ze.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(a(this,"_weekdaysRegex")||(this._weekdaysRegex=Ve),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},bn.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(a(this,"_weekdaysRegex")||Ze.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(a(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=We),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},bn.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(a(this,"_weekdaysRegex")||Ze.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(a(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=He),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},bn.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},bn.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},ot("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===K(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),r.lang=k("moment.lang is deprecated. Use moment.locale instead.",ot),r.langData=k("moment.langData is deprecated. Use moment.localeData instead.",st);var _n=Math.abs;function kn(e,t,n,r){var i=Ut(t,n);return e._milliseconds+=r*i._milliseconds,e._days+=r*i._days,e._months+=r*i._months,e._bubble()}function xn(e){return e<0?Math.floor(e):Math.ceil(e)}function En(e){return 4800*e/146097}function On(e){return 146097*e/4800}function Mn(e){return function(){return this.as(e)}}var Cn=Mn("ms"),Tn=Mn("s"),An=Mn("m"),In=Mn("h"),Pn=Mn("d"),Rn=Mn("w"),Dn=Mn("M"),Nn=Mn("Q"),jn=Mn("y");function Ln(e){return function(){return this.isValid()?this._data[e]:NaN}}var Bn=Ln("milliseconds"),zn=Ln("seconds"),Fn=Ln("minutes"),Un=Ln("hours"),qn=Ln("days"),Vn=Ln("months"),Wn=Ln("years"),Hn=Math.round,Kn={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function Zn(e,t,n,r,i){return i.relativeTime(t||1,!!n,e,r)}var Gn=Math.abs;function Xn(e){return(e>0)-(e<0)||+e}function Yn(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,r,i,o,a,s,c=Gn(this._milliseconds)/1e3,u=Gn(this._days),l=Gn(this._months),d=this.asSeconds();return d?(e=H(c/60),t=H(e/60),c%=60,e%=60,n=H(l/12),l%=12,r=c?c.toFixed(3).replace(/\.?0+$/,""):"",i=d<0?"-":"",o=Xn(this._months)!==Xn(d)?"-":"",a=Xn(this._days)!==Xn(d)?"-":"",s=Xn(this._milliseconds)!==Xn(d)?"-":"",i+"P"+(n?o+n+"Y":"")+(l?o+l+"M":"")+(u?a+u+"D":"")+(t||e||c?"T":"")+(t?s+t+"H":"")+(e?s+e+"M":"")+(c?s+r+"S":"")):"P0D"}var $n=At.prototype;return $n.isValid=function(){return this._isValid},$n.abs=function(){var e=this._data;return this._milliseconds=_n(this._milliseconds),this._days=_n(this._days),this._months=_n(this._months),e.milliseconds=_n(e.milliseconds),e.seconds=_n(e.seconds),e.minutes=_n(e.minutes),e.hours=_n(e.hours),e.months=_n(e.months),e.years=_n(e.years),this},$n.add=function(e,t){return kn(this,e,t,1)},$n.subtract=function(e,t){return kn(this,e,t,-1)},$n.as=function(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if("month"===(e=F(e))||"quarter"===e||"year"===e)switch(t=this._days+r/864e5,n=this._months+En(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(On(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}},$n.asMilliseconds=Cn,$n.asSeconds=Tn,$n.asMinutes=An,$n.asHours=In,$n.asDays=Pn,$n.asWeeks=Rn,$n.asMonths=Dn,$n.asQuarters=Nn,$n.asYears=jn,$n.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*K(this._months/12):NaN},$n._bubble=function(){var e,t,n,r,i,o=this._milliseconds,a=this._days,s=this._months,c=this._data;return o>=0&&a>=0&&s>=0||o<=0&&a<=0&&s<=0||(o+=864e5*xn(On(s)+a),a=0,s=0),c.milliseconds=o%1e3,e=H(o/1e3),c.seconds=e%60,t=H(e/60),c.minutes=t%60,n=H(t/60),c.hours=n%24,a+=H(n/24),i=H(En(a)),s+=i,a-=xn(On(i)),r=H(s/12),s%=12,c.days=a,c.months=s,c.years=r,this},$n.clone=function(){return Ut(this)},$n.get=function(e){return e=F(e),this.isValid()?this[e+"s"]():NaN},$n.milliseconds=Bn,$n.seconds=zn,$n.minutes=Fn,$n.hours=Un,$n.days=qn,$n.weeks=function(){return H(this.days()/7)},$n.months=Vn,$n.years=Wn,$n.humanize=function(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,r,i=!1,o=Kn;return"object"===typeof e&&(t=e,e=!1),"boolean"===typeof e&&(i=e),"object"===typeof t&&(o=Object.assign({},Kn,t),null!=t.s&&null==t.ss&&(o.ss=t.s-1)),n=this.localeData(),r=function(e,t,n,r){var i=Ut(e).abs(),o=Hn(i.as("s")),a=Hn(i.as("m")),s=Hn(i.as("h")),c=Hn(i.as("d")),u=Hn(i.as("M")),l=Hn(i.as("w")),d=Hn(i.as("y")),f=o<=n.ss&&["s",o]||o0,f[4]=r,Zn.apply(null,f)}(this,!i,o,n),i&&(r=n.pastFuture(+this,r)),n.postformat(r)},$n.toISOString=Yn,$n.toString=Yn,$n.toJSON=Yn,$n.locale=Jt,$n.localeData=en,$n.toIsoString=k("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Yn),$n.lang=Qt,N("X",0,0,"unix"),N("x",0,0,"valueOf"),he("x",ue),he("X",/[+-]?\d+(\.\d{1,3})?/),be("X",(function(e,t,n){n._d=new Date(1e3*parseFloat(e))})),be("x",(function(e,t,n){n._d=new Date(K(e))})),r.version="2.28.0",t=Et,r.fn=gn,r.min=function(){var e=[].slice.call(arguments,0);return Ct("isBefore",e)},r.max=function(){var e=[].slice.call(arguments,0);return Ct("isAfter",e)},r.now=function(){return Date.now?Date.now():+new Date},r.utc=h,r.unix=function(e){return Et(1e3*e)},r.months=function(e,t){return wn(e,t,"months")},r.isDate=l,r.locale=ot,r.invalid=g,r.duration=Ut,r.isMoment=S,r.weekdays=function(e,t,n){return Sn(e,t,n,"weekdays")},r.parseZone=function(){return Et.apply(null,arguments).parseZone()},r.localeData=st,r.isDuration=It,r.monthsShort=function(e,t){return wn(e,t,"monthsShort")},r.weekdaysMin=function(e,t,n){return Sn(e,t,n,"weekdaysMin")},r.defineLocale=at,r.updateLocale=function(e,t){if(null!=t){var n,r,i=Qe;null!=et[e]&&null!=et[e].parentLocale?et[e].set(C(et[e]._config,t)):(null!=(r=it(e))&&(i=r._config),t=C(i,t),null==r&&(t.abbr=e),(n=new T(t)).parentLocale=et[e],et[e]=n),ot(e)}else null!=et[e]&&(null!=et[e].parentLocale?(et[e]=et[e].parentLocale,e===ot()&&ot(e)):null!=et[e]&&delete et[e]);return et[e]},r.locales=function(){return x(et)},r.weekdaysShort=function(e,t,n){return Sn(e,t,n,"weekdaysShort")},r.normalizeUnits=F,r.relativeTimeRounding=function(e){return void 0===e?Hn:"function"===typeof e&&(Hn=e,!0)},r.relativeTimeThreshold=function(e,t){return void 0!==Kn[e]&&(void 0===t?Kn[e]:(Kn[e]=t,"s"===e&&(Kn.ss=t-1),!0))},r.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},r.prototype=gn,r.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},r}()}).call(this,n(145)(e))},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},function(e,t,n){var r=n(78),i=r.Buffer;function o(e,t){for(var n in e)t[n]=e[n]}function a(e,t,n){return i(e,t,n)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=r:(o(r,t),t.Buffer=a),o(i,a),a.from=function(e,t,n){if("number"===typeof e)throw new TypeError("Argument must not be a number");return i(e,t,n)},a.alloc=function(e,t,n){if("number"!==typeof e)throw new TypeError("Argument must be a number");var r=i(e);return void 0!==t?"string"===typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},a.allocUnsafe=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return r.SlowBuffer(e)}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(338);function i(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Object(r.a)(e,t)}},function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(427),i=n(570);function o(e){return(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})(e)}var a=n(571);function s(e,t){return!t||"object"!==o(t)&&"function"!==typeof t?Object(a.a)(e):t}function c(e){return function(){var t,n=Object(r.a)(e);if(Object(i.a)()){var o=Object(r.a)(this).constructor;t=Reflect.construct(n,arguments,o)}else t=n.apply(this,arguments);return s(this,t)}}},function(e,t,n){var r=n(643);e.exports=function(e){if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=r(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o,a=!0,s=!1;return{s:function(){i=e[Symbol.iterator]()},n:function(){var e=i.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==i.return||i.return()}finally{if(s)throw o}}}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return D})),n.d(t,"b",(function(){return L})),n.d(t,"c",(function(){return P})),n.d(t,"d",(function(){return A}));var r=n(140),i=n.n(r),o=n(293),a=n.n(o),s=n(85),c=n.n(s),u=n(1),l=n(232),d=n(4);function f(e,t){var n=m(e),r=m(t),i=n.pop(),o=r.pop(),a=y(n,r);return 0!==a?a:i&&o?y(i.split("."),o.split(".")):i||o?i?-1:1:0}var h=function(e,t,n){_(n);var r=f(e,t);return w[n].includes(r)};f.validate=function(e){return"string"===typeof e&&/^[v\d]/.test(e)&&p.test(e)},f.compare=h,f.satisfies=function(e,t){var n=t.match(/^([<>=~^]+)/),r=n?n[1]:"=";if("^"!==r&&"~"!==r)return h(e,t,r);var i=m(e),o=Object(d.a)(i,3),a=o[0],s=o[1],c=o[2],u=m(t),l=Object(d.a)(u,3),f=l[0],p=l[1],g=l[2];return 0===b(a,f)&&("^"===r?y([s,c],[p,g])>=0:0===b(s,p)&&b(c,g)>=0)};var p=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,m=function(e){if("string"!==typeof e)throw new TypeError("Invalid argument expected string");var t=e.match(p);if(!t)throw new Error("Invalid argument not valid semver ('".concat(e,"' received)"));return t.shift(),t},g=function(e){return"*"===e||"x"===e||"X"===e},v=function(e){var t=parseInt(e,10);return isNaN(t)?e:t},b=function(e,t){if(g(e)||g(t))return 0;var n=function(e,t){return typeof e!==typeof t?[String(e),String(t)]:[e,t]}(v(e),v(t)),r=Object(d.a)(n,2),i=r[0],o=r[1];return i>o?1:i":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1]},S=Object.keys(w),_=function(e){if("string"!==typeof e)throw new TypeError("Invalid operator type, expected string but got ".concat(typeof e));if(-1===S.indexOf(e))throw new Error("Invalid operator, expected one of ".concat(S.join("|")))},k=n(324),x=n.n(k),E=n(163),O=n.n(E),M=n(127),C=n(101),T=u.createContext(null),A=function(){return u.useContext(T)},I=function(e){var t=e.error;return t.name&&t.message?u.createElement("p",null,t.name,": ",t.message):u.createElement("p",null,"Error: ",t.toString())},P=function(e){var t=e.oktaAuth,n=e.restoreOriginalUri,r=e.onAuthRequired,o=e.children,s=u.useState((function(){return t?t.authStateManager.getAuthState():null})),d=a()(s,2),f=d[0],p=d[1];if(u.useEffect((function(){t&&n&&(t.options.restoreOriginalUri&&console.warn("Two custom restoreOriginalUri callbacks are detected. The one from the OktaAuth configuration will be overridden by the provided restoreOriginalUri prop from the Security component."),t.options.restoreOriginalUri=function(){var e=i()(c.a.mark((function e(t,r){return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n(t,r);case 1:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}())}),[]),u.useEffect((function(){if(t){t._oktaUserAgent?t._oktaUserAgent.addEnvironment("@okta/okta-react".concat("/","6.7.0")):console.warn("_oktaUserAgent is not available on auth SDK instance. Please use okta-auth-js@^5.3.1 .");var e=t.authStateManager.getAuthState();e!==f&&p(e);var n=function(e){p(e)};return t.authStateManager.subscribe(n),t.start(),function(){t.authStateManager.unsubscribe(n)}}}),[t]),!t){var m=new l.AuthSdkError("No oktaAuth instance passed to Security Component.");return u.createElement(I,{error:m})}if(!n){var g=new l.AuthSdkError("No restoreOriginalUri callback passed to Security Component.");return u.createElement(I,{error:g})}if(t._oktaUserAgent){if(!h(t._oktaUserAgent.getVersion(),"5.3.1",">=")){var v=new l.AuthSdkError("\n Passed in oktaAuth is not compatible with the SDK,\n minimum supported okta-auth-js version is ".concat("5.3.1",".\n "));return u.createElement(I,{error:v})}}else console.warn("_oktaUserAgent is not available on auth SDK instance. Please use okta-auth-js@^5.3.1 .");return u.createElement(T.Provider,{value:{oktaAuth:t,authState:f,_onAuthRequired:r}},o)};var R,D=function(e){var t=e.errorComponent,n=e.loadingElement,r=void 0===n?null:n,i=e.onAuthResume,o=A(),s=o.oktaAuth,c=o.authState,l=u.useState(null),d=a()(l,2),f=d[0],h=d[1],p=t||I;u.useEffect((function(){var e=s.idx.isInteractionRequired||s.isInteractionRequired.bind(s);i&&e()?i():s.handleLoginRedirect().catch((function(e){h(e)}))}),[s]);var m=null===c||void 0===c?void 0:c.error,g=f||m;return g?u.createElement(p,{error:g}):r},N=["onAuthRequired","errorComponent"];function j(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}R="useRouteMatch"in M?M["useRouteMatch"in M?"useRouteMatch":""]:function(){throw new l.AuthSdkError('Unsupported: SecureRoute only works with react-router-dom v5 or any router library with compatible APIs. See examples under the "samples" folder for how to implement your own custom SecureRoute Component.')};var L=function(e){var t=e.onAuthRequired,n=e.errorComponent,r=O()(e,N),o=A(),s=o.oktaAuth,d=o.authState,f=o._onAuthRequired,h=R(r),p=u.useRef(!1),m=u.useState(null),g=a()(m,2),v=g[0],b=g[1],y=n||I;return u.useEffect((function(){var e=function(){var e=i()(c.a.mark((function e(){var n,r;return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!p.current){e.next=2;break}return e.abrupt("return");case 2:if(p.current=!0,n=Object(l.toRelativeUrl)(window.location.href,window.location.origin),s.setOriginalUri(n),!(r=t||f)){e.next=11;break}return e.next=9,r(s);case 9:e.next=13;break;case 11:return e.next=13,s.signInWithRedirect();case 13:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();h&&d&&(d.isAuthenticated?p.current=!1:d.isAuthenticated||e().catch((function(e){b(e)})))}),[d,s,h,t,f]),v?u.createElement(y,{error:v}):d&&d.isAuthenticated?u.createElement(C.d,function(e){for(var t=1;t>>0;if(""+n!==t||4294967295===n)return NaN;t=n}return t<0?_(e)+t:t}function x(){return!0}function E(e,t,n){return(0===e||void 0!==n&&e<=-n)&&(void 0===t||void 0!==n&&t>=n)}function O(e,t){return C(e,t,0)}function M(e,t){return C(e,t,t)}function C(e,t,n){return void 0===e?n:e<0?Math.max(0,t+e):void 0===t?e:Math.min(t,e)}var T,A,I,P="function"===typeof Symbol&&Symbol.iterator,R=P||"@@iterator";function D(e){this.next=e}function N(e,t,n,r){var i=0===e?t:1===e?n:[t,n];return r?r.value=i:r={value:i,done:!1},r}function j(){return{value:void 0,done:!0}}function L(e){return!!F(e)}function B(e){return e&&"function"===typeof e.next}function z(e){var t=F(e);return t&&t.call(e)}function F(e){var t=e&&(P&&e[P]||e["@@iterator"]);if("function"===typeof t)return t}function U(e){return e&&"number"===typeof e.length}function q(e){return null===e||void 0===e?$():a(e)?e.toSeq():function(e){var t=ee(e)||"object"===typeof e&&new Z(e);if(!t)throw new TypeError("Expected Array or iterable object of values, or keyed object: "+e);return t}(e)}function V(e){return null===e||void 0===e?$().toKeyedSeq():a(e)?s(e)?e.toSeq():e.fromEntrySeq():J(e)}function W(e){return null===e||void 0===e?$():a(e)?s(e)?e.entrySeq():e.toIndexedSeq():Q(e)}function H(e){return(null===e||void 0===e?$():a(e)?s(e)?e.entrySeq():e:Q(e)).toSetSeq()}function K(e){this._array=e,this.size=e.length}function Z(e){var t=Object.keys(e);this._object=e,this._keys=t,this.size=t.length}function G(e){this._iterable=e,this.size=e.length||e.size}function X(e){this._iterator=e,this._iteratorCache=[]}function Y(e){return!(!e||!e["@@__IMMUTABLE_SEQ__@@"])}function $(){return T||(T=new K([]))}function J(e){var t=Array.isArray(e)?new K(e).fromEntrySeq():B(e)?new X(e).fromEntrySeq():L(e)?new G(e).fromEntrySeq():"object"===typeof e?new Z(e):void 0;if(!t)throw new TypeError("Expected Array or iterable object of [k, v] entries, or keyed object: "+e);return t}function Q(e){var t=ee(e);if(!t)throw new TypeError("Expected Array or iterable object of values: "+e);return t}function ee(e){return U(e)?new K(e):B(e)?new X(e):L(e)?new G(e):void 0}function te(e,t,n,r){var i=e._cache;if(i){for(var o=i.length-1,a=0;a<=o;a++){var s=i[n?o-a:a];if(!1===t(s[1],r?s[0]:a,e))return a+1}return a}return e.__iterateUncached(t,n)}function ne(e,t,n,r){var i=e._cache;if(i){var o=i.length-1,a=0;return new D((function(){var e=i[n?o-a:a];return a++>o?{value:void 0,done:!0}:N(t,r?e[0]:a-1,e[1])}))}return e.__iteratorUncached(t,n)}function re(e,t){return t?function e(t,n,r,i){return Array.isArray(n)?t.call(i,r,W(n).map((function(r,i){return e(t,r,i,n)}))):oe(n)?t.call(i,r,V(n).map((function(r,i){return e(t,r,i,n)}))):n}(t,e,"",{"":e}):ie(e)}function ie(e){return Array.isArray(e)?W(e).map(ie).toList():oe(e)?V(e).map(ie).toMap():e}function oe(e){return e&&(e.constructor===Object||void 0===e.constructor)}function ae(e,t){if(e===t||e!==e&&t!==t)return!0;if(!e||!t)return!1;if("function"===typeof e.valueOf&&"function"===typeof t.valueOf){if((e=e.valueOf())===(t=t.valueOf())||e!==e&&t!==t)return!0;if(!e||!t)return!1}return!("function"!==typeof e.equals||"function"!==typeof t.equals||!e.equals(t))}function se(e,t){if(e===t)return!0;if(!a(t)||void 0!==e.size&&void 0!==t.size&&e.size!==t.size||void 0!==e.__hash&&void 0!==t.__hash&&e.__hash!==t.__hash||s(e)!==s(t)||c(e)!==c(t)||l(e)!==l(t))return!1;if(0===e.size&&0===t.size)return!0;var n=!u(e);if(l(e)){var r=e.entries();return t.every((function(e,t){var i=r.next().value;return i&&ae(i[1],e)&&(n||ae(i[0],t))}))&&r.next().done}var i=!1;if(void 0===e.size)if(void 0===t.size)"function"===typeof e.cacheResult&&e.cacheResult();else{i=!0;var o=e;e=t,t=o}var d=!0,f=t.__iterate((function(t,r){if(n?!e.has(t):i?!ae(t,e.get(r,m)):!ae(e.get(r,m),t))return d=!1,!1}));return d&&e.size===f}function ce(e,t){if(!(this instanceof ce))return new ce(e,t);if(this._value=e,this.size=void 0===t?1/0:Math.max(0,t),0===this.size){if(A)return A;A=this}}function ue(e,t){if(!e)throw new Error(t)}function le(e,t,n){if(!(this instanceof le))return new le(e,t,n);if(ue(0!==n,"Cannot step a Range by 0"),e=e||0,void 0===t&&(t=1/0),n=void 0===n?1:Math.abs(n),tr?{value:void 0,done:!0}:N(e,i,n[t?r-i++:i++])}))},t(Z,V),Z.prototype.get=function(e,t){return void 0===t||this.has(e)?this._object[e]:t},Z.prototype.has=function(e){return this._object.hasOwnProperty(e)},Z.prototype.__iterate=function(e,t){for(var n=this._object,r=this._keys,i=r.length-1,o=0;o<=i;o++){var a=r[t?i-o:o];if(!1===e(n[a],a,this))return o+1}return o},Z.prototype.__iterator=function(e,t){var n=this._object,r=this._keys,i=r.length-1,o=0;return new D((function(){var a=r[t?i-o:o];return o++>i?{value:void 0,done:!0}:N(e,a,n[a])}))},Z.prototype[p]=!0,t(G,W),G.prototype.__iterateUncached=function(e,t){if(t)return this.cacheResult().__iterate(e,t);var n=z(this._iterable),r=0;if(B(n))for(var i;!(i=n.next()).done&&!1!==e(i.value,r++,this););return r},G.prototype.__iteratorUncached=function(e,t){if(t)return this.cacheResult().__iterator(e,t);var n=z(this._iterable);if(!B(n))return new D(j);var r=0;return new D((function(){var t=n.next();return t.done?t:N(e,r++,t.value)}))},t(X,W),X.prototype.__iterateUncached=function(e,t){if(t)return this.cacheResult().__iterate(e,t);for(var n,r=this._iterator,i=this._iteratorCache,o=0;o=r.length){var t=n.next();if(t.done)return t;r[i]=t.value}return N(e,i,r[i++])}))},t(ce,W),ce.prototype.toString=function(){return 0===this.size?"Repeat []":"Repeat [ "+this._value+" "+this.size+" times ]"},ce.prototype.get=function(e,t){return this.has(e)?this._value:t},ce.prototype.includes=function(e){return ae(this._value,e)},ce.prototype.slice=function(e,t){var n=this.size;return E(e,t,n)?this:new ce(this._value,M(t,n)-O(e,n))},ce.prototype.reverse=function(){return this},ce.prototype.indexOf=function(e){return ae(this._value,e)?0:-1},ce.prototype.lastIndexOf=function(e){return ae(this._value,e)?this.size:-1},ce.prototype.__iterate=function(e,t){for(var n=0;n1?" by "+this._step:"")+" ]"},le.prototype.get=function(e,t){return this.has(e)?this._start+k(this,e)*this._step:t},le.prototype.includes=function(e){var t=(e-this._start)/this._step;return t>=0&&t=0&&nn?{value:void 0,done:!0}:N(e,o++,a)}))},le.prototype.equals=function(e){return e instanceof le?this._start===e._start&&this._end===e._end&&this._step===e._step:se(this,e)},t(de,n),t(fe,de),t(he,de),t(pe,de),de.Keyed=fe,de.Indexed=he,de.Set=pe;var me="function"===typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(e,t){var n=65535&(e|=0),r=65535&(t|=0);return n*r+((e>>>16)*r+n*(t>>>16)<<16>>>0)|0};function ge(e){return e>>>1&1073741824|3221225471&e}function ve(e){if(!1===e||null===e||void 0===e)return 0;if("function"===typeof e.valueOf&&(!1===(e=e.valueOf())||null===e||void 0===e))return 0;if(!0===e)return 1;var t=typeof e;if("number"===t){var n=0|e;for(n!==e&&(n^=4294967295*e);e>4294967295;)n^=e/=4294967295;return ge(n)}if("string"===t)return e.length>Ee?function(e){var t=Ce[e];return void 0===t&&(t=be(e),Me===Oe&&(Me=0,Ce={}),Me++,Ce[e]=t),t}(e):be(e);if("function"===typeof e.hashCode)return e.hashCode();if("object"===t)return function(e){var t;if(_e&&void 0!==(t=ye.get(e)))return t;if(void 0!==(t=e[xe]))return t;if(!Se){if(void 0!==(t=e.propertyIsEnumerable&&e.propertyIsEnumerable[xe]))return t;if(void 0!==(t=function(e){if(e&&e.nodeType>0)switch(e.nodeType){case 1:return e.uniqueID;case 9:return e.documentElement&&e.documentElement.uniqueID}}(e)))return t}if(t=++ke,1073741824&ke&&(ke=0),_e)ye.set(e,t);else{if(void 0!==we&&!1===we(e))throw new Error("Non-extensible objects are not allowed as keys.");if(Se)Object.defineProperty(e,xe,{enumerable:!1,configurable:!1,writable:!1,value:t});else if(void 0!==e.propertyIsEnumerable&&e.propertyIsEnumerable===e.constructor.prototype.propertyIsEnumerable)e.propertyIsEnumerable=function(){return this.constructor.prototype.propertyIsEnumerable.apply(this,arguments)},e.propertyIsEnumerable[xe]=t;else{if(void 0===e.nodeType)throw new Error("Unable to set a non-enumerable property on object.");e[xe]=t}}return t}(e);if("function"===typeof e.toString)return be(e.toString());throw new Error("Value type "+t+" cannot be hashed.")}function be(e){for(var t=0,n=0;n>>n),s=31&(0===n?r:r>>>n);return new je(t,1<>1&1431655765))+(e>>2&858993459))+(e>>4)&252645135,e+=e>>8,127&(e+=e>>16)}function et(e,t,n,r){var i=r?e:S(e);return i[t]=n,i}De[Re]=!0,De.delete=De.remove,De.removeIn=De.deleteIn,Ne.prototype.get=function(e,t,n,r){for(var i=this.entries,o=0,a=i.length;o=tt)return function(e,t,n,r){e||(e=new w);for(var i=new ze(e,ve(n),[n,r]),o=0;o>>e)),o=this.bitmap;return 0===(o&i)?r:this.nodes[Qe(o&i-1)].get(e+5,t,n,r)},je.prototype.update=function(e,t,n,r,i,o,a){void 0===n&&(n=ve(r));var s=31&(0===t?n:n>>>t),c=1<=nt)return function(e,t,n,r,i){for(var o=0,a=new Array(32),s=0;0!==n;s++,n>>>=1)a[s]=1&n?t[o++]:void 0;return a[r]=i,new Le(e,o+1,a)}(e,f,u,s,p);if(l&&!p&&2===f.length&&Ze(f[1^d]))return f[1^d];if(l&&p&&1===f.length&&Ze(p))return p;var g=e&&e===this.ownerID,v=l?p?u:u^c:u|c,b=l?p?et(f,d,p,g):function(e,t,n){var r=e.length-1;if(n&&t===r)return e.pop(),e;for(var i=new Array(r),o=0,a=0;a>>e),o=this.nodes[i];return o?o.get(e+5,t,n,r):r},Le.prototype.update=function(e,t,n,r,i,o,a){void 0===n&&(n=ve(r));var s=31&(0===t?n:n>>>t),c=i===m,u=this.nodes,l=u[s];if(c&&!l)return this;var d=Ke(l,e,t+5,n,r,i,o,a);if(d===l)return this;var f=this.count;if(l){if(!d&&--f0&&r<32?ht(0,r,5,null,new ct(n.toArray())):t.withMutations((function(e){e.setSize(r),n.forEach((function(t,n){return e.set(n,t)}))})))}function ot(e){return!(!e||!e[at])}t(it,he),it.of=function(){return this(arguments)},it.prototype.toString=function(){return this.__toString("List [","]")},it.prototype.get=function(e,t){if((e=k(this,e))>=0&&e=e.size||t<0)return e.withMutations((function(e){t<0?bt(e,t).set(0,n):bt(e,0,t+1).set(t,n)}));t+=e._origin;var r=e._tail,i=e._root,o=b(v);return t>=wt(e._capacity)?r=mt(r,e.__ownerID,0,t,n,o):i=mt(i,e.__ownerID,e._level,t,n,o),o.value?e.__ownerID?(e._root=i,e._tail=r,e.__hash=void 0,e.__altered=!0,e):ht(e._origin,e._capacity,e._level,i,r):e}(this,e,t)},it.prototype.remove=function(e){return this.has(e)?0===e?this.shift():e===this.size-1?this.pop():this.splice(e,1):this},it.prototype.insert=function(e,t){return this.splice(e,0,t)},it.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=this._origin=this._capacity=0,this._level=5,this._root=this._tail=null,this.__hash=void 0,this.__altered=!0,this):pt()},it.prototype.push=function(){var e=arguments,t=this.size;return this.withMutations((function(n){bt(n,0,t+e.length);for(var r=0;r>>t&31;if(r>=this.array.length)return new ct([],e);var i,o=0===r;if(t>0){var a=this.array[r];if((i=a&&a.removeBefore(e,t-5,n))===a&&o)return this}if(o&&!i)return this;var s=gt(this,e);if(!o)for(var c=0;c>>t&31;if(i>=this.array.length)return this;if(t>0){var o=this.array[i];if((r=o&&o.removeAfter(e,t-5,n))===o&&i===this.array.length-1)return this}var a=gt(this,e);return a.array.splice(i+1),r&&(a.array[i]=r),a};var ut,lt,dt={};function ft(e,t){var n=e._origin,r=e._capacity,i=wt(r),o=e._tail;return a(e._root,e._level,0);function a(e,s,c){return 0===s?function(e,a){var s=a===i?o&&o.array:e&&e.array,c=a>n?0:n-a,u=r-a;return u>32&&(u=32),function(){if(c===u)return dt;var e=t?--u:c++;return s&&s[e]}}(e,c):function(e,i,o){var s,c=e&&e.array,u=o>n?0:n-o>>i,l=1+(r-o>>i);return l>32&&(l=32),function(){for(;;){if(s){var e=s();if(e!==dt)return e;s=null}if(u===l)return dt;var n=t?--l:u++;s=a(c&&c[n],i-5,o+(n<>>n&31,c=e&&s0){var u=e&&e.array[s],l=mt(u,t,n-5,r,i,o);return l===u?e:((a=gt(e,t)).array[s]=l,a)}return c&&e.array[s]===i?e:(y(o),a=gt(e,t),void 0===i&&s===a.array.length-1?a.array.pop():a.array[s]=i,a)}function gt(e,t){return t&&e&&t===e.ownerID?e:new ct(e?e.array.slice():[],t)}function vt(e,t){if(t>=wt(e._capacity))return e._tail;if(t<1<0;)n=n.array[t>>>r&31],r-=5;return n}}function bt(e,t,n){void 0!==t&&(t|=0),void 0!==n&&(n|=0);var r=e.__ownerID||new w,i=e._origin,o=e._capacity,a=i+t,s=void 0===n?o:n<0?o+n:i+n;if(a===i&&s===o)return e;if(a>=s)return e.clear();for(var c=e._level,u=e._root,l=0;a+l<0;)u=new ct(u&&u.array.length?[void 0,u]:[],r),l+=1<<(c+=5);l&&(a+=l,i+=l,s+=l,o+=l);for(var d=wt(o),f=wt(s);f>=1<d?new ct([],r):h;if(h&&f>d&&a5;g-=5){var v=d>>>g&31;m=m.array[v]=gt(m.array[v],r)}m.array[d>>>5&31]=h}if(s=f)a-=f,s-=f,c=5,u=null,p=p&&p.removeBefore(r,0,a);else if(a>i||f>>c&31;if(b!==f>>>c&31)break;b&&(l+=(1<i&&(u=u.removeBefore(r,c,a-l)),u&&fo&&(o=u.size),a(c)||(u=u.map((function(e){return re(e)}))),r.push(u)}return o>e.size&&(e=e.setSize(o)),Je(e,t,r)}function wt(e){return e<32?0:e-1>>>5<<5}function St(e){return null===e||void 0===e?xt():_t(e)?e:xt().withMutations((function(t){var n=r(e);Te(n.size),n.forEach((function(e,n){return t.set(n,e)}))}))}function _t(e){return Ie(e)&&l(e)}function kt(e,t,n,r){var i=Object.create(St.prototype);return i.size=e?e.size:0,i._map=e,i._list=t,i.__ownerID=n,i.__hash=r,i}function xt(){return lt||(lt=kt(We(),pt()))}function Et(e,t,n){var r,i,o=e._map,a=e._list,s=o.get(t),c=void 0!==s;if(n===m){if(!c)return e;a.size>=32&&a.size>=2*o.size?(r=(i=a.filter((function(e,t){return void 0!==e&&s!==t}))).toKeyedSeq().map((function(e){return e[0]})).flip().toMap(),e.__ownerID&&(r.__ownerID=i.__ownerID=e.__ownerID)):(r=o.remove(t),i=s===a.size-1?a.pop():a.set(s,void 0))}else if(c){if(n===a.get(s)[1])return e;r=o,i=a.set(s,[t,n])}else r=o.set(t,a.size),i=a.set(a.size,[t,n]);return e.__ownerID?(e.size=r.size,e._map=r,e._list=i,e.__hash=void 0,e):kt(r,i)}function Ot(e,t){this._iter=e,this._useKeys=t,this.size=e.size}function Mt(e){this._iter=e,this.size=e.size}function Ct(e){this._iter=e,this.size=e.size}function Tt(e){this._iter=e,this.size=e.size}function At(e){var t=Kt(e);return t._iter=e,t.size=e.size,t.flip=function(){return e},t.reverse=function(){var t=e.reverse.apply(this);return t.flip=function(){return e.reverse()},t},t.has=function(t){return e.includes(t)},t.includes=function(t){return e.has(t)},t.cacheResult=Zt,t.__iterateUncached=function(t,n){var r=this;return e.__iterate((function(e,n){return!1!==t(n,e,r)}),n)},t.__iteratorUncached=function(t,n){if(2===t){var r=e.__iterator(t,n);return new D((function(){var e=r.next();if(!e.done){var t=e.value[0];e.value[0]=e.value[1],e.value[1]=t}return e}))}return e.__iterator(1===t?0:1,n)},t}function It(e,t,n){var r=Kt(e);return r.size=e.size,r.has=function(t){return e.has(t)},r.get=function(r,i){var o=e.get(r,m);return o===m?i:t.call(n,o,r,e)},r.__iterateUncached=function(r,i){var o=this;return e.__iterate((function(e,i,a){return!1!==r(t.call(n,e,i,a),i,o)}),i)},r.__iteratorUncached=function(r,i){var o=e.__iterator(2,i);return new D((function(){var i=o.next();if(i.done)return i;var a=i.value,s=a[0];return N(r,s,t.call(n,a[1],s,e),i)}))},r}function Pt(e,t){var n=Kt(e);return n._iter=e,n.size=e.size,n.reverse=function(){return e},e.flip&&(n.flip=function(){var t=At(e);return t.reverse=function(){return e.flip()},t}),n.get=function(n,r){return e.get(t?n:-1-n,r)},n.has=function(n){return e.has(t?n:-1-n)},n.includes=function(t){return e.includes(t)},n.cacheResult=Zt,n.__iterate=function(t,n){var r=this;return e.__iterate((function(e,n){return t(e,n,r)}),!n)},n.__iterator=function(t,n){return e.__iterator(t,!n)},n}function Rt(e,t,n,r){var i=Kt(e);return r&&(i.has=function(r){var i=e.get(r,m);return i!==m&&!!t.call(n,i,r,e)},i.get=function(r,i){var o=e.get(r,m);return o!==m&&t.call(n,o,r,e)?o:i}),i.__iterateUncached=function(i,o){var a=this,s=0;return e.__iterate((function(e,o,c){if(t.call(n,e,o,c))return s++,i(e,r?o:s-1,a)}),o),s},i.__iteratorUncached=function(i,o){var a=e.__iterator(2,o),s=0;return new D((function(){for(;;){var o=a.next();if(o.done)return o;var c=o.value,u=c[0],l=c[1];if(t.call(n,l,u,e))return N(i,r?u:s++,l,o)}}))},i}function Dt(e,t,n,r){var i=e.size;if(void 0!==t&&(t|=0),void 0!==n&&(n|=0),E(t,n,i))return e;var o=O(t,i),a=M(n,i);if(o!==o||a!==a)return Dt(e.toSeq().cacheResult(),t,n,r);var s,c=a-o;c===c&&(s=c<0?0:c);var u=Kt(e);return u.size=0===s?s:e.size&&s||void 0,!r&&Y(e)&&s>=0&&(u.get=function(t,n){return(t=k(this,t))>=0&&ts)return{value:void 0,done:!0};var e=i.next();return r||1===t?e:N(t,c-1,0===t?void 0:e.value[1],e)}))},u}function Nt(e,t,n,r){var i=Kt(e);return i.__iterateUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterate(i,o);var s=!0,c=0;return e.__iterate((function(e,o,u){if(!s||!(s=t.call(n,e,o,u)))return c++,i(e,r?o:c-1,a)})),c},i.__iteratorUncached=function(i,o){var a=this;if(o)return this.cacheResult().__iterator(i,o);var s=e.__iterator(2,o),c=!0,u=0;return new D((function(){var e,o,l;do{if((e=s.next()).done)return r||1===i?e:N(i,u++,0===i?void 0:e.value[1],e);var d=e.value;o=d[0],l=d[1],c&&(c=t.call(n,l,o,a))}while(c);return 2===i?e:N(i,o,l,e)}))},i}function jt(e,t){var n=s(e),i=[e].concat(t).map((function(e){return a(e)?n&&(e=r(e)):e=n?J(e):Q(Array.isArray(e)?e:[e]),e})).filter((function(e){return 0!==e.size}));if(0===i.length)return e;if(1===i.length){var o=i[0];if(o===e||n&&s(o)||c(e)&&c(o))return o}var u=new K(i);return n?u=u.toKeyedSeq():c(e)||(u=u.toSetSeq()),(u=u.flatten(!0)).size=i.reduce((function(e,t){if(void 0!==e){var n=t.size;if(void 0!==n)return e+n}}),0),u}function Lt(e,t,n){var r=Kt(e);return r.__iterateUncached=function(r,i){var o=0,s=!1;return function e(c,u){var l=this;c.__iterate((function(i,c){return(!t||u0}function Ut(e,t,r){var i=Kt(e);return i.size=new K(r).map((function(e){return e.size})).min(),i.__iterate=function(e,t){for(var n,r=this.__iterator(1,t),i=0;!(n=r.next()).done&&!1!==e(n.value,i++,this););return i},i.__iteratorUncached=function(e,i){var o=r.map((function(e){return e=n(e),z(i?e.reverse():e)})),a=0,s=!1;return new D((function(){var n;return s||(n=o.map((function(e){return e.next()})),s=n.some((function(e){return e.done}))),s?{value:void 0,done:!0}:N(e,a++,t.apply(null,n.map((function(e){return e.value}))))}))},i}function qt(e,t){return Y(e)?t:e.constructor(t)}function Vt(e){if(e!==Object(e))throw new TypeError("Expected [K, V] tuple: "+e)}function Wt(e){return Te(e.size),_(e)}function Ht(e){return s(e)?r:c(e)?i:o}function Kt(e){return Object.create((s(e)?V:c(e)?W:H).prototype)}function Zt(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):q.prototype.cacheResult.call(this)}function Gt(e,t){return e>t?1:e=0;n--)t={value:arguments[n],next:t};return this.__ownerID?(this.size=e,this._head=t,this.__hash=void 0,this.__altered=!0,this):Sn(e,t)},gn.prototype.pushAll=function(e){if(0===(e=i(e)).size)return this;Te(e.size);var t=this.size,n=this._head;return e.reverse().forEach((function(e){t++,n={value:e,next:n}})),this.__ownerID?(this.size=t,this._head=n,this.__hash=void 0,this.__altered=!0,this):Sn(t,n)},gn.prototype.pop=function(){return this.slice(1)},gn.prototype.unshift=function(){return this.push.apply(this,arguments)},gn.prototype.unshiftAll=function(e){return this.pushAll(e)},gn.prototype.shift=function(){return this.pop.apply(this,arguments)},gn.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):_n()},gn.prototype.slice=function(e,t){if(E(e,t,this.size))return this;var n=O(e,this.size);if(M(t,this.size)!==this.size)return he.prototype.slice.call(this,e,t);for(var r=this.size-n,i=this._head;n--;)i=i.next;return this.__ownerID?(this.size=r,this._head=i,this.__hash=void 0,this.__altered=!0,this):Sn(r,i)},gn.prototype.__ensureOwner=function(e){return e===this.__ownerID?this:e?Sn(this.size,this._head,e,this.__hash):(this.__ownerID=e,this.__altered=!1,this)},gn.prototype.__iterate=function(e,t){if(t)return this.reverse().__iterate(e);for(var n=0,r=this._head;r&&!1!==e(r.value,n++,this);)r=r.next;return n},gn.prototype.__iterator=function(e,t){if(t)return this.reverse().__iterator(e);var n=0,r=this._head;return new D((function(){if(r){var t=r.value;return r=r.next,N(e,n++,t)}return{value:void 0,done:!0}}))},gn.isStack=vn;var bn,yn="@@__IMMUTABLE_STACK__@@",wn=gn.prototype;function Sn(e,t,n,r){var i=Object.create(wn);return i.size=e,i._head=t,i.__ownerID=n,i.__hash=r,i.__altered=!1,i}function _n(){return bn||(bn=Sn(0))}function kn(e,t){var n=function(n){e.prototype[n]=t[n]};return Object.keys(t).forEach(n),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(t).forEach(n),e}wn[yn]=!0,wn.withMutations=De.withMutations,wn.asMutable=De.asMutable,wn.asImmutable=De.asImmutable,wn.wasAltered=De.wasAltered,n.Iterator=D,kn(n,{toArray:function(){Te(this.size);var e=new Array(this.size||0);return this.valueSeq().__iterate((function(t,n){e[n]=t})),e},toIndexedSeq:function(){return new Mt(this)},toJS:function(){return this.toSeq().map((function(e){return e&&"function"===typeof e.toJS?e.toJS():e})).__toJS()},toJSON:function(){return this.toSeq().map((function(e){return e&&"function"===typeof e.toJSON?e.toJSON():e})).__toJS()},toKeyedSeq:function(){return new Ot(this,!0)},toMap:function(){return Ae(this.toKeyedSeq())},toObject:function(){Te(this.size);var e={};return this.__iterate((function(t,n){e[n]=t})),e},toOrderedMap:function(){return St(this.toKeyedSeq())},toOrderedSet:function(){return ln(s(this)?this.valueSeq():this)},toSet:function(){return tn(s(this)?this.valueSeq():this)},toSetSeq:function(){return new Ct(this)},toSeq:function(){return c(this)?this.toIndexedSeq():s(this)?this.toKeyedSeq():this.toSetSeq()},toStack:function(){return gn(s(this)?this.valueSeq():this)},toList:function(){return it(s(this)?this.valueSeq():this)},toString:function(){return"[Iterable]"},__toString:function(e,t){return 0===this.size?e+t:e+" "+this.toSeq().map(this.__toStringMapper).join(", ")+" "+t},concat:function(){var t=e.call(arguments,0);return qt(this,jt(this,t))},includes:function(e){return this.some((function(t){return ae(t,e)}))},entries:function(){return this.__iterator(2)},every:function(e,t){Te(this.size);var n=!0;return this.__iterate((function(r,i,o){if(!e.call(t,r,i,o))return n=!1,!1})),n},filter:function(e,t){return qt(this,Rt(this,e,t,!0))},find:function(e,t,n){var r=this.findEntry(e,t);return r?r[1]:n},findEntry:function(e,t){var n;return this.__iterate((function(r,i,o){if(e.call(t,r,i,o))return n=[i,r],!1})),n},findLastEntry:function(e,t){return this.toSeq().reverse().findEntry(e,t)},forEach:function(e,t){return Te(this.size),this.__iterate(t?e.bind(t):e)},join:function(e){Te(this.size),e=void 0!==e?""+e:",";var t="",n=!0;return this.__iterate((function(r){n?n=!1:t+=e,t+=null!==r&&void 0!==r?r.toString():""})),t},keys:function(){return this.__iterator(0)},map:function(e,t){return qt(this,It(this,e,t))},reduce:function(e,t,n){var r,i;return Te(this.size),arguments.length<2?i=!0:r=t,this.__iterate((function(t,o,a){i?(i=!1,r=t):r=e.call(n,r,t,o,a)})),r},reduceRight:function(e,t,n){var r=this.toKeyedSeq().reverse();return r.reduce.apply(r,arguments)},reverse:function(){return qt(this,Pt(this,!0))},slice:function(e,t){return qt(this,Dt(this,e,t,!0))},some:function(e,t){return!this.every(Cn(e),t)},sort:function(e){return qt(this,Bt(this,e))},values:function(){return this.__iterator(1)},butLast:function(){return this.slice(0,-1)},isEmpty:function(){return void 0!==this.size?0===this.size:!this.some((function(){return!0}))},count:function(e,t){return _(e?this.toSeq().filter(e,t):this)},countBy:function(e,t){return function(e,t,n){var r=Ae().asMutable();return e.__iterate((function(i,o){r.update(t.call(n,i,o,e),0,(function(e){return e+1}))})),r.asImmutable()}(this,e,t)},equals:function(e){return se(this,e)},entrySeq:function(){var e=this;if(e._cache)return new K(e._cache);var t=e.toSeq().map(Mn).toIndexedSeq();return t.fromEntrySeq=function(){return e.toSeq()},t},filterNot:function(e,t){return this.filter(Cn(e),t)},findLast:function(e,t,n){return this.toKeyedSeq().reverse().find(e,t,n)},first:function(){return this.find(x)},flatMap:function(e,t){return qt(this,function(e,t,n){var r=Ht(e);return e.toSeq().map((function(i,o){return r(t.call(n,i,o,e))})).flatten(!0)}(this,e,t))},flatten:function(e){return qt(this,Lt(this,e,!0))},fromEntrySeq:function(){return new Tt(this)},get:function(e,t){return this.find((function(t,n){return ae(n,e)}),void 0,t)},getIn:function(e,t){for(var n,r=this,i=Xt(e);!(n=i.next()).done;){var o=n.value;if((r=r&&r.get?r.get(o,m):m)===m)return t}return r},groupBy:function(e,t){return function(e,t,n){var r=s(e),i=(l(e)?St():Ae()).asMutable();e.__iterate((function(o,a){i.update(t.call(n,o,a,e),(function(e){return(e=e||[]).push(r?[a,o]:o),e}))}));var o=Ht(e);return i.map((function(t){return qt(e,o(t))}))}(this,e,t)},has:function(e){return this.get(e,m)!==m},hasIn:function(e){return this.getIn(e,m)!==m},isSubset:function(e){return e="function"===typeof e.includes?e:n(e),this.every((function(t){return e.includes(t)}))},isSuperset:function(e){return(e="function"===typeof e.isSubset?e:n(e)).isSubset(this)},keySeq:function(){return this.toSeq().map(On).toIndexedSeq()},last:function(){return this.toSeq().reverse().first()},max:function(e){return zt(this,e)},maxBy:function(e,t){return zt(this,t,e)},min:function(e){return zt(this,e?Tn(e):Pn)},minBy:function(e,t){return zt(this,t?Tn(t):Pn,e)},rest:function(){return this.slice(1)},skip:function(e){return this.slice(Math.max(0,e))},skipLast:function(e){return qt(this,this.toSeq().reverse().skip(e).reverse())},skipWhile:function(e,t){return qt(this,Nt(this,e,t,!0))},skipUntil:function(e,t){return this.skipWhile(Cn(e),t)},sortBy:function(e,t){return qt(this,Bt(this,t,e))},take:function(e){return this.slice(0,Math.max(0,e))},takeLast:function(e){return qt(this,this.toSeq().reverse().take(e).reverse())},takeWhile:function(e,t){return qt(this,function(e,t,n){var r=Kt(e);return r.__iterateUncached=function(r,i){var o=this;if(i)return this.cacheResult().__iterate(r,i);var a=0;return e.__iterate((function(e,i,s){return t.call(n,e,i,s)&&++a&&r(e,i,o)})),a},r.__iteratorUncached=function(r,i){var o=this;if(i)return this.cacheResult().__iterator(r,i);var a=e.__iterator(2,i),s=!0;return new D((function(){if(!s)return{value:void 0,done:!0};var e=a.next();if(e.done)return e;var i=e.value,c=i[0],u=i[1];return t.call(n,u,c,o)?2===r?e:N(r,c,u,e):(s=!1,{value:void 0,done:!0})}))},r}(this,e,t))},takeUntil:function(e,t){return this.takeWhile(Cn(e),t)},valueSeq:function(){return this.toIndexedSeq()},hashCode:function(){return this.__hash||(this.__hash=function(e){if(e.size===1/0)return 0;var t=l(e),n=s(e),r=t?1:0;return function(e,t){return t=me(t,3432918353),t=me(t<<15|t>>>-15,461845907),t=me(t<<13|t>>>-13,5),t=me((t=(t+3864292196|0)^e)^t>>>16,2246822507),t=ge((t=me(t^t>>>13,3266489909))^t>>>16)}(e.__iterate(n?t?function(e,t){r=31*r+Rn(ve(e),ve(t))|0}:function(e,t){r=r+Rn(ve(e),ve(t))|0}:t?function(e){r=31*r+ve(e)|0}:function(e){r=r+ve(e)|0}),r)}(this))}});var xn=n.prototype;xn[d]=!0,xn[R]=xn.values,xn.__toJS=xn.toArray,xn.__toStringMapper=An,xn.inspect=xn.toSource=function(){return this.toString()},xn.chain=xn.flatMap,xn.contains=xn.includes,function(){try{Object.defineProperty(xn,"length",{get:function(){if(!n.noLengthWarning){var e;try{throw new Error}catch(t){e=t.stack}if(-1===e.indexOf("_wrapObject"))return console&&console.warn&&console.warn("iterable.length has been deprecated, use iterable.size or iterable.count(). This warning will become a silent error in a future version. "+e),this.size}}})}catch(e){}}(),kn(r,{flip:function(){return qt(this,At(this))},findKey:function(e,t){var n=this.findEntry(e,t);return n&&n[0]},findLastKey:function(e,t){return this.toSeq().reverse().findKey(e,t)},keyOf:function(e){return this.findKey((function(t){return ae(t,e)}))},lastKeyOf:function(e){return this.findLastKey((function(t){return ae(t,e)}))},mapEntries:function(e,t){var n=this,r=0;return qt(this,this.toSeq().map((function(i,o){return e.call(t,[o,i],r++,n)})).fromEntrySeq())},mapKeys:function(e,t){var n=this;return qt(this,this.toSeq().flip().map((function(r,i){return e.call(t,r,i,n)})).flip())}});var En=r.prototype;function On(e,t){return t}function Mn(e,t){return[t,e]}function Cn(e){return function(){return!e.apply(this,arguments)}}function Tn(e){return function(){return-e.apply(this,arguments)}}function An(e){return"string"===typeof e?JSON.stringify(e):e}function In(){return S(arguments)}function Pn(e,t){return et?-1:0}function Rn(e,t){return e^t+2654435769+(e<<6)+(e>>2)|0}return En[f]=!0,En[R]=xn.entries,En.__toJS=xn.toObject,En.__toStringMapper=function(e,t){return JSON.stringify(t)+": "+An(e)},kn(i,{toKeyedSeq:function(){return new Ot(this,!1)},filter:function(e,t){return qt(this,Rt(this,e,t,!1))},findIndex:function(e,t){var n=this.findEntry(e,t);return n?n[0]:-1},indexOf:function(e){var t=this.toKeyedSeq().keyOf(e);return void 0===t?-1:t},lastIndexOf:function(e){var t=this.toKeyedSeq().reverse().keyOf(e);return void 0===t?-1:t},reverse:function(){return qt(this,Pt(this,!1))},slice:function(e,t){return qt(this,Dt(this,e,t,!1))},splice:function(e,t){var n=arguments.length;if(t=Math.max(0|t,0),0===n||2===n&&!t)return this;e=O(e,e<0?this.count():this.size);var r=this.slice(0,e);return qt(this,1===n?r:r.concat(S(arguments,2),this.slice(e+t)))},findLastIndex:function(e,t){var n=this.toKeyedSeq().findLastKey(e,t);return void 0===n?-1:n},first:function(){return this.get(0)},flatten:function(e){return qt(this,Lt(this,e,!1))},get:function(e,t){return(e=k(this,e))<0||this.size===1/0||void 0!==this.size&&e>this.size?t:this.find((function(t,n){return n===e}),void 0,t)},has:function(e){return(e=k(this,e))>=0&&(void 0!==this.size?this.size===1/0||e1&&(i=t,o=n),n=Math.max(o,n),t=Math.max(t,i)}return t};if(!0===e.mask&&u&&!d){var b=v(o),y=m(o.substr(b))[0];b=o.indexOf(y,b),o="".concat(o.substr(0,b)).concat(o.substr(b+1))}var w=e.format(o);null==a||c.selectionStart!==o.length||d||(u?w=a(w):""===m(w.slice(-1))&&(w=w.slice(0,-1)));var S=i?i(w):w;return s===S?n():e.onChange(S),function(){var t=v(w);if(null!=e.mask&&(u||l&&!f))for(;w[t]&&""===m(w[t]);)t+=1;c.selectionStart=c.selectionEnd=t+(f?1+p:0)}}})),Object(o.useEffect)((function(){var e=function(e){"Delete"===e.code&&(c.current=!0)},t=function(e){"Delete"===e.code&&(c.current=!1)};return document.addEventListener("keydown",e),document.addEventListener("keyup",t),function(){document.removeEventListener("keydown",e),document.removeEventListener("keyup",t)}}),[]),{value:null!=r.current?r.current[0]:s,onChange:function(t){var i=t.target.value;r.current=[i,t.target,i.length>s.length,c.current,s===e.format(i)],n()}}},O=n(86),M=n(2416),C=n(2412),T=(n(128),n(266));function A(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function I(e){for(var t=1;t *":{position:"absolute",top:0,right:0,left:0}},"slideEnter-left":{willChange:"transform",transform:"translate(100%)",zIndex:1},"slideEnter-right":{willChange:"transform",transform:"translate(-100%)",zIndex:1},slideEnterActive:{transform:"translate(0%)",transition:t},slideExit:{transform:"translate(0%)"},"slideExitActiveLeft-left":{willChange:"transform",transform:"translate(-100%)",transition:t,zIndex:0},"slideExitActiveLeft-right":{willChange:"transform",transform:"translate(100%)",transition:t,zIndex:0}}}),{name:"MuiPickersSlideTransition"}),L=function(e){var t=e.children,n=e.className,r=e.reduceAnimations,a=e.slideDirection,s=e.transKey,c=Object(i.a)(e,["children","className","reduceAnimations","slideDirection","transKey"]),u=j();if(r)return Object(o.createElement)("div",{className:Object(p.default)(u.root,n)},t);var l={exit:u.slideExit,enterActive:u.slideEnterActive,enter:u["slideEnter-"+a],exitActive:u["slideExitActiveLeft-"+a]};return Object(o.createElement)(M.a,{className:Object(p.default)(u.root,n),childFactory:function(e){return Object(o.cloneElement)(e,{classNames:l})}},Object(o.createElement)(C.a,Object(h.a)({mountOnEnter:!0,unmountOnExit:!0,key:s,timeout:350,classNames:l,children:t},c)))},B={name:"MuiPickersCalendar"},z=Object(s.a)((function(e){var t=6*(f.e+4*f.a);return{root:{minHeight:t},loadingContainer:{display:"flex",justifyContent:"center",alignItems:"center",minHeight:t},weekContainer:{overflow:"hidden"},week:{margin:"".concat(f.a,"px 0"),display:"flex",justifyContent:"center"},iconButton:{zIndex:1,backgroundColor:e.palette.background.paper},previousMonthButton:{marginRight:12},daysHeader:{display:"flex",justifyContent:"center",alignItems:"center"},weekDayLabel:{width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:e.palette.text.secondary}}}),B),F=Object(d.c)(B,(function(e){var t,n=e.date,i=e.isMonthSwitchingAnimating,a=e.onMonthSwitchingAnimationEnd,s=e.focusedDay,c=e.changeFocusedDay,l=e.onChange,d=e.slideDirection,g=e.currentMonth,v=e.renderDay,b=e.reduceAnimations,y=e.allowKeyboardControl,w=e.isDateDisabled,S=e.disableHighlightToday,_=e.showDaysOutsideCurrentMonth,k=e.className,x=e.loading,E=e.renderLoading,M=void 0===E?function(){return Object(o.createElement)("span",{"data-mui-test":"loading-progress"},"...")}:E,C=e.TransitionProps,T=Object(f.d)(),A=Object(f.h)(),I=Object(u.a)(),P=z(),R=Object(o.useCallback)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"finish",r=Array.isArray(n)?e:A.mergeDateAndTime(e,n||T);l(r,t)}),[n,T,l,A]),D=Array.isArray(n)?n[0]:n,j=s||D||T;Object(O.c)(Boolean(y),(t={},Object(r.a)(t,O.b.ArrowUp,(function(){return c(A.addDays(j,-7))})),Object(r.a)(t,O.b.ArrowDown,(function(){return c(A.addDays(j,7))})),Object(r.a)(t,O.b.ArrowLeft,(function(){return c(A.addDays(j,"ltr"===I.direction?-1:1))})),Object(r.a)(t,O.b.ArrowRight,(function(){return c(A.addDays(j,"ltr"===I.direction?1:-1))})),Object(r.a)(t,O.b.Home,(function(){return c(A.startOfWeek(j))})),Object(r.a)(t,O.b.End,(function(){return c(A.endOfWeek(j))})),Object(r.a)(t,O.b.PageUp,(function(){return c(A.getNextMonth(j))})),Object(r.a)(t,O.b.PageDown,(function(){return c(A.getPreviousMonth(j))})),t));var B=A.getMonth(g),F=(Array.isArray(n)?n:[n]).filter(Boolean).map((function(e){return A.startOfDay(e)}));return Object(o.createElement)(o.Fragment,null,Object(o.createElement)("div",{className:P.daysHeader},A.getWeekdays().map((function(e,t){return Object(o.createElement)(m.a,{"aria-hidden":!0,key:e+t.toString(),variant:"caption",className:P.weekDayLabel,children:e.charAt(0).toUpperCase()})}))),x?Object(o.createElement)("div",{className:P.loadingContainer},M()):Object(o.createElement)(L,Object(h.a)({transKey:B,onExited:a,reduceAnimations:b,slideDirection:d,className:Object(p.default)(P.root,k)},C),Object(o.createElement)("div",{role:"grid",className:P.weekContainer},A.getWeekArray(g).map((function(e){return Object(o.createElement)("div",{role:"row",key:"week-".concat(e[0]),className:P.week},e.map((function(e){var t,n=w(e),r=A.getMonth(e)===B,a={key:null===(t=e)||void 0===t?void 0:t.toString(),day:e,role:"cell",isAnimating:i,disabled:n,allowKeyboardControl:y,focused:y&&Boolean(s)&&A.isSameDay(e,s),today:A.isSameDay(e,T),inCurrentMonth:r,selected:F.some((function(t){return A.isSameDay(t,e)})),disableHighlightToday:S,showDaysOutsideCurrentMonth:_,focusable:y&&Boolean(j)&&A.toJsDate(j).getDate()===A.toJsDate(e).getDate(),onDayFocus:c,onDaySelect:R};return v?v(e,F,a):Object(o.createElement)(N,a)})))})))))}));F.displayName="Calendar";var U=n(1321),q=function(e){var t=e.date,n=e.utils,r=e.minDate,i=e.maxDate,o=e.disableFuture,a=e.disablePast,s=e.shouldDisableDate,c=n.startOfDay(n.date());a&&n.isBefore(r,c)&&(r=c),o&&n.isAfter(i,c)&&(i=c);var u=t,l=t;for(n.isBefore(t,r)&&(u=n.date(r),l=null),n.isAfter(t,i)&&(l&&(l=n.date(i)),u=null);u||l;){if(u&&n.isAfter(u,i)&&(u=null),l&&n.isBefore(l,r)&&(l=null),u){if(!s(u))return u;u=n.addDays(u,1)}if(l){if(!s(l))return l;l=n.addDays(l,-1)}}return n.date()},V=function(e){return 1===e.length&&"year"===e[0]},W=function(e){return 2===e.length&&Object(S.b)(e,"month")&&Object(S.b)(e,"year")},H=function(e,t){return V(e)?{mask:"____",inputFormat:t.formats.year}:W(e)?{disableMaskedInput:!0,inputFormat:t.formats.monthAndYear}:{mask:"__/__/____",inputFormat:t.formats.keyboardDate}};function K(e,t){var n=t.value,r=e.date(n);return e.isValid(r)?r:null}var Z=function(e,t,n){var r=n.minDate,i=n.maxDate,o=n.disableFuture,a=n.shouldDisableDate,s=n.disablePast,c=e.date(),u=e.date(t);if(null===t)return null;switch(!0){case!e.isValid(t):return"invalidDate";case Boolean(a&&a(u)):return"shouldDisableDate";case Boolean(o&&e.isAfterDay(u,c)):return"disableFuture";case Boolean(s&&e.isBeforeDay(u,c)):return"disablePast";case Boolean(r&&e.isBeforeDay(u,r)):return"minDate";case Boolean(i&&e.isAfterDay(u,i)):return"maxDate";default:return null}};function G(e,t){return e&&t.isValid(t.date(e))?"Choose date, selected date is ".concat(t.format(t.date(e),"fullDate")):"Choose date"}var X=function(e,t,n){var r=e.date(t);return null===t?"":e.isValid(r)?e.formatByString(r,n):""};function Y(e,t,n){return e||("undefined"===typeof t?n.localized:t?n["12h"]:n["24h"])}var $=new Date("2019-11-21T22:30:00.000"),J=new Date("2019-01-01T09:00:00.000");function Q(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ee(e){for(var t=1;te.length-1)return"";var o=e[i],a=e[i+1],s=t.test(r)?r:"",c="_"===o?s:o+s;return i===n.length-1&&a&&"_"!==a?c?c+a:"":c})).join("")}}(l,n):function(e){return e}}),[n,l,T]);Object(o.useEffect)((function(){null!==h&&!b.isValid(h)||y.current||C(_())}),[b,_,h]);var I=function(e){var t=""===e||e===l?"":e;C(t);var n=null===t?null:b.parse(t,s);a&&!b.isValid(n)||d(n,t||void 0)},P=E({value:M,onChange:I,format:m||A});return ee({label:u,disabled:r,error:v,helperText:k,inputProps:ee(ee(ee({},T?P:{value:M,onChange:function(e){I(e.currentTarget.value)}}),{},{disabled:r,placeholder:k,readOnly:p,type:T?"tel":"text"},c),{},{onFocus:Object(S.d)((function(){return y.current=!0}),null===c||void 0===c?void 0:c.onFocus),onBlur:Object(S.d)((function(){return y.current=!1}),null===c||void 0===c?void 0:c.onBlur)})},g)}function ne(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function re(e){for(var t=1;t1&&Object(o.createElement)(g.a,{size:"small","data-mui-test":"calendar-view-switcher",onClick:I,className:C.yearSelectionSwitcher,"aria-label":O(t)},Object(o.createElement)(ve,{className:Object(p.default)(C.switchViewDropdown,"year"===t&&C.switchViewDropdownDown)}))),Object(o.createElement)(U.a,{in:"date"===t},Object(o.createElement)(y.a,{leftArrowButtonProps:h,rightArrowButtonProps:v,leftArrowButtonText:_,rightArrowButtonText:x,leftArrowIcon:b,rightArrowIcon:w,onLeftClick:function(){return l(M.getPreviousMonth(r),"right")},onRightClick:function(){return l(M.getNextMonth(r),"left")},isLeftDisabled:A,isRightDisabled:T}))))};function Se(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _e(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:"finish",n=function(e){p(e,t),i(e),m&&m(e)},r=y.setYear(k,e);if(s(r)){var o=q({utils:y,date:r,minDate:l,maxDate:c,disablePast:Boolean(h),disableFuture:Boolean(d),shouldDisableDate:s});n(o)}else n(r)}),[y,k,s,p,i,m,l,c,h,d]),R=Object(o.useCallback)((function(e){s(y.setYear(k,e))||I(e)}),[k,s,y]),D="desktop"===E?4:3,N=A||x;return Object(O.c)(Boolean(n),(t={},Object(r.a)(t,O.b.ArrowUp,(function(){return R(N-D)})),Object(r.a)(t,O.b.ArrowDown,(function(){return R(N+D)})),Object(r.a)(t,O.b.ArrowLeft,(function(){return R(N+("ltr"===b.direction?-1:1))})),Object(r.a)(t,O.b.ArrowRight,(function(){return R(N+("ltr"===b.direction?1:-1))})),t)),Object(o.createElement)("div",{className:S.root},y.getYearRange(l,c).map((function(e){var t=y.getYear(e),r=t===x;return Object(o.createElement)(Ee,{key:y.format(e,"year"),selected:r,value:t,onSelect:P,allowKeyboardControl:n,focused:t===A,ref:r?M:void 0,disabled:h&&y.isBeforeYear(e,v)||d&&y.isAfterYear(e,v)||g&&g(e)},y.format(e,"year"))})))},Ce={name:"MuiPickersCalendarView"},Te=Object(s.a)({viewTransitionContainer:{overflowY:"auto"},fullHeightContainer:{flex:1,display:"flex",justifyContent:"center",alignItems:"center",minHeight:7*(f.e+4*f.a),height:"100%"}},Ce),Ae="undefined"!==typeof navigator&&/(android)/i.test(navigator.userAgent),Ie=Object(d.c)(Ce,(function(e){var t=e.allowKeyboardControl,n=e.changeView,r=e.date,a=e.disableFuture,s=e.disablePast,c=e.loading,u=e.maxDate,l=e.minDate,d=e.onChange,p=e.onMonthChange,m=e.reduceAnimations,g=void 0===m?Ae:m,v=e.renderLoading,b=e.shouldDisableDate,y=e.shouldDisableYear,w=e.view,S=Object(i.a)(e,["allowKeyboardControl","changeView","date","disableFuture","disablePast","loading","maxDate","minDate","onChange","onMonthChange","reduceAnimations","renderLoading","shouldDisableDate","shouldDisableYear","view"]),k=Object(f.h)(),x=Te(),E=Object(o.useContext)(_.b),O=null!==t&&void 0!==t?t:!E,M=l||k.date(ae),C=u||k.date(se),T=pe({date:r,reduceAnimations:g,onMonthChange:p,minDate:M,maxDate:C,shouldDisableDate:b,disablePast:s,disableFuture:a}),A=T.calendarState,I=T.changeFocusedDay,P=T.changeMonth,R=T.isDateDisabled,D=T.handleChangeMonth,N=T.onMonthSwitchingAnimationEnd;return Object(o.useEffect)((function(){if(r&&R(r)){var e=q({utils:k,date:r,minDate:M,maxDate:C,disablePast:Boolean(s),disableFuture:Boolean(a),shouldDisableDate:R});d(e,"partial")}}),[]),Object(o.useEffect)((function(){P(r)}),[r]),Object(o.createElement)(o.Fragment,null,Object(o.createElement)(we,Object(h.a)({},S,{view:w,currentMonth:A.currentMonth,changeView:n,onMonthChange:function(e,t){return D({newMonth:e,direction:t})},minDate:M,maxDate:C,disablePast:s,disableFuture:a,reduceAnimations:g})),Object(o.createElement)(ge,{reduceAnimations:g,className:x.viewTransitionContainer,transKey:w},Object(o.createElement)("div",null,"year"===w&&Object(o.createElement)(Me,Object(h.a)({},S,{date:r,onChange:d,minDate:M,maxDate:C,disableFuture:a,disablePast:s,isDateDisabled:R,allowKeyboardControl:O,shouldDisableYear:y,changeFocusedDay:I})),"month"===w&&Object(o.createElement)(de,Object(h.a)({},S,{date:r,onChange:d,minDate:M,maxDate:C,onMonthChange:p})),"date"===w&&Object(o.createElement)(F,Object(h.a)({},S,A,{onMonthSwitchingAnimationEnd:N,changeFocusedDay:I,reduceAnimations:g,date:r,onChange:d,isDateDisabled:R,allowKeyboardControl:O,loading:c,renderLoading:v})))))})),Pe=function(){return"undefined"===typeof window?"portrait":window.screen&&window.screen.orientation&&window.screen.orientation.angle?90===Math.abs(window.screen.orientation.angle)?"landscape":"portrait":window.orientation&&90===Math.abs(Number(window.orientation))?"landscape":"portrait"};var Re=Object(l.a)("div")({padding:"16px 24px"},{name:"MuiPickersMobileKeyboardInputView"}),De={name:"MuiPickersBasePicker"},Ne=Object(s.a)({root:{display:"flex",flexDirection:"column"},landscape:{flexDirection:"row"},pickerView:{overflowX:"hidden",width:f.f,maxHeight:f.c,display:"flex",flexDirection:"column",margin:"0 auto"},pickerViewLandscape:{padding:"0 8px"}},De),je={fullWidth:!0};var Le=Object(d.c)(De,(function(e){var t,n=e.className,r=e.date,a=e.DateInputProps,s=e.isMobileKeyboardViewOpen,c=e.onDateChange,u=e.openTo,l=void 0===u?"date":u,d=e.orientation,f=e.showToolbar,m=e.toggleMobileKeyboardView,g=e.ToolbarComponent,v=void 0===g?function(){return null}:g,b=e.toolbarFormat,k=e.toolbarPlaceholder,x=e.toolbarTitle,E=e.views,M=void 0===E?["year","month","date","hours","minutes","seconds"]:E,C=Object(i.a)(e,["className","date","DateInputProps","isMobileKeyboardViewOpen","onDateChange","openTo","orientation","showToolbar","toggleMobileKeyboardView","ToolbarComponent","toolbarFormat","toolbarPlaceholder","toolbarTitle","views"]),T=Ne(),A=function(e,t){var n=Object(o.useState)(Pe()),r=Object(w.a)(n,2),i=r[0],a=r[1];return Object(O.a)((function(){var e=function(){a(Pe())};return window.addEventListener("orientationchange",e),function(){window.removeEventListener("orientationchange",e)}}),[]),!Object(S.b)(e,["hours","minutes","seconds"])&&"landscape"===(t||i)}(M,d),I=Object(o.useContext)(_.c),P="undefined"===typeof f?"desktop"!==I:f,R=Object(o.useCallback)((function(e,t){c(e,I,t)}),[c,I]),D=function(e){var t=e.views,n=e.openTo,r=e.onChange,i=e.isMobileKeyboardViewOpen,a=e.toggleMobileKeyboardView,s=Object(o.useState)(n&&Object(S.b)(t,n)?n:t[0]),c=Object(w.a)(s,2),u=c[0],l=c[1],d=Object(o.useCallback)((function(){i&&a(),l.apply(void 0,arguments)}),[i,a]),f=t[t.indexOf(u)-1],h=t[t.indexOf(u)+1],p=Object(o.useCallback)((function(){h&&d(h)}),[h,d]),m=Object(o.useCallback)((function(e,t){var n="finish"===t,i=n&&Boolean(h)?"partial":t;r(e,i),n&&p()}),[h,r,p]);return{nextView:h,previousView:f,openNext:p,handleChangeAndOpenNext:m,openView:u,setOpenView:d}}({views:M,openTo:l,onChange:R,isMobileKeyboardViewOpen:s,toggleMobileKeyboardView:m}),N=D.openView,j=D.nextView,L=D.previousView,B=D.setOpenView,z=D.handleChangeAndOpenNext;return Object(o.createElement)("div",{className:Object(p.default)(T.root,n,A&&T.landscape)},P&&Object(o.createElement)(v,Object(h.a)({},C,{views:M,isLandscape:A,date:r,onChange:R,setOpenView:B,openView:N,toolbarTitle:x,toolbarFormat:b,toolbarPlaceholder:k,isMobileKeyboardViewOpen:s,toggleMobileKeyboardView:m})),Object(o.createElement)("div",{className:Object(p.default)(T.pickerView,A&&T.pickerViewLandscape)},s?Object(o.createElement)(Re,null,Object(o.createElement)(ie,Object(h.a)({},a,{ignoreInvalidInputs:!0,disableOpenPicker:!0,TextFieldProps:je}))):Object(o.createElement)(o.Fragment,null,("year"===N||"month"===N||"date"===N)&&Object(o.createElement)(Ie,Object(h.a)({date:r,changeView:B,views:M,onChange:z,view:N},C)),("hours"===N||"minutes"===N||"seconds"===N)&&Object(o.createElement)(y.b,Object(h.a)({},C,{date:r,type:N,onDateChange:R,onChange:z,openNextView:function(){return B(j)},openPreviousView:function(){return B(L)},nextViewAvailable:!Boolean(j),previousViewAvailable:!Boolean(L)||(t=L,"year"===t||"month"===t||"date"===t),showViewSwitcher:"desktop"===I})))))}))},function(e,t,n){"use strict";var r=function(e){};e.exports=function(e,t){for(var n=arguments.length,i=new Array(n>2?n-2:0),o=2;o0?i(r(e),9007199254740991):0}},function(e,t,n){var r=n(49),i=n(446),o=n(99),a=n(360),s=n(624),c=n(848),u=i("wks"),l=r.Symbol,d=c?l:l&&l.withoutSetter||a;e.exports=function(e){return o(u,e)&&(s||"string"==typeof u[e])||(s&&o(l,e)?u[e]=l[e]:u[e]=d("Symbol."+e)),u[e]}},function(e,t,n){"use strict";n.d(t,"a",(function(){return D})),n.d(t,"b",(function(){return U})),n.d(t,"c",(function(){return G})),n.d(t,"d",(function(){return z})),n.d(t,"e",(function(){return L})),n.d(t,"f",(function(){return V}));var r=n(22),i=n(5),o=n(1),a=n.n(o),s=(n(7),n(132)),c=n(103),u=n(38),l=n(2),d=n(3),f=n(36),h=n(45),p=n(67),m=n(68),g=n(1323),v=n(95),b=n(264),y=n(2363),w=n(2364),S=n(2362),_=n(598),k=n(211),x=n(1324),E=n(2358),O=n(86);function M(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function C(e){for(var t=1;t $dialogRoot":{outline:"auto","@media (pointer:coarse)":{outline:0}}},dialog:{"&:first-child":{padding:0}},dialogAction:{},withAdditionalAction:{justifyContent:"flex-start","& > *:first-child":{marginRight:"auto"}}},{name:"MuiPickersModalDialog"}),R=function(e){var t=e.cancelText,n=void 0===t?"Cancel":t,r=e.children,a=e.classes,s=e.clearable,c=void 0!==s&&s,u=e.clearText,f=void 0===u?"Clear":u,h=e.okText,p=void 0===h?"OK":h,m=e.onAccept,g=e.onClear,v=e.onDismiss,_=e.onSetToday,k=(e.showTabs,e.showTodayButton),x=void 0!==k&&k,E=e.todayText,O=void 0===E?"Today":E,M=e.wider,C=Object(i.a)(e,["cancelText","children","classes","clearable","clearText","okText","onAccept","onClear","onDismiss","onSetToday","showTabs","showTodayButton","todayText","wider"]),T=P();return Object(o.createElement)(S.a,Object(l.a)({onClose:v,classes:I({container:T.dialogContainer,paper:Object(d.default)(T.dialogRoot,M&&T.dialogRootWider)},a)},C),Object(o.createElement)(w.a,{children:r,className:T.dialog}),Object(o.createElement)(y.a,{className:Object(d.default)(T.dialogAction,(c||x)&&T.withAdditionalAction)},c&&Object(o.createElement)(b.a,{"data-mui-test":"clear-action-button",color:"primary",onClick:g},f),x&&Object(o.createElement)(b.a,{"data-mui-test":"today-action-button",color:"primary",onClick:_},O),n&&Object(o.createElement)(b.a,{color:"primary",onClick:v},n),p&&Object(o.createElement)(b.a,{color:"primary",onClick:m},p)))},D=function(e){var t=e.cancelText,n=e.children,r=e.clearable,a=e.clearText,s=e.DateInputProps,c=e.DialogProps,u=(e.displayStaticWrapperAs,e.KeyboardDateInputComponent,e.okText),d=e.onAccept,f=e.onClear,h=e.onDismiss,p=e.onSetToday,m=e.open,g=(e.PopperProps,e.PureDateInputComponent),b=void 0===g?T:g,y=e.showTabs,w=e.showTodayButton,S=e.todayText,_=e.wider,k=Object(i.a)(e,["cancelText","children","clearable","clearText","DateInputProps","DialogProps","displayStaticWrapperAs","KeyboardDateInputComponent","okText","onAccept","onClear","onDismiss","onSetToday","open","PopperProps","PureDateInputComponent","showTabs","showTodayButton","todayText","wider"]);return Object(o.createElement)(v.c.Provider,{value:"mobile"},Object(o.createElement)(b,Object(l.a)({},k,s)),Object(o.createElement)(R,Object(l.a)({wider:_,showTabs:y,open:m,onClear:f,onAccept:d,onDismiss:h,onSetToday:p,clearText:a,todayText:S,okText:u,cancelText:t,clearable:r,showTodayButton:w,children:n,"data-mui-test":"mobile-wrapper-dialog"},c)))},N=Object(s.a)((function(e){return{root:{zIndex:e.zIndex.modal},paper:{transformOrigin:"top center","&:focus":Object(r.a)({},u.b,{outline:0})},topTransition:{transformOrigin:"bottom center"}}}),{name:"MuiPickersPopper"}),j=function(e){var t=e.anchorEl,n=e.children,i=e.innerRef,a=void 0===i?null:i,s=e.onClose,c=e.onOpen,u=e.open,h=e.PopperProps,m=e.role,g=e.TransitionComponent,v=void 0===g?_.a:g,b=e.TrapFocusProps,y=N(),w=Object(o.useRef)(null),S=Object(f.a)(w,a),M=Object(o.useRef)(null),C=Object(o.useMemo)((function(){return{onCreate:c}}),[c]);Object(O.c)(u,Object(r.a)({},O.b.Esc,s)),Object(o.useEffect)((function(){"tooltip"!==m&&(u?M.current=document.activeElement:M.current&&M.current instanceof HTMLElement&&M.current.focus())}),[u,m]);var T=function(){u&&Object(p.e)((function(){var e;(null===(e=w.current)||void 0===e?void 0:e.contains(document.activeElement))||s()}))};return Object(o.createElement)(x.a,Object(l.a)({transition:!0,role:m,open:u,anchorEl:t,className:Object(d.default)(y.root,null===h||void 0===h?void 0:h.className),popperOptions:C},h),(function(e){var t=e.TransitionProps,r=e.placement;return Object(o.createElement)(E.a,Object(l.a)({open:u,disableAutoFocus:!0,disableEnforceFocus:"tooltip"===m,isEnabled:function(){return!0},getDoc:function(){var e,t;return null!==(e=null===(t=w.current)||void 0===t?void 0:t.ownerDocument)&&void 0!==e?e:document}},b),Object(o.createElement)(v,t,Object(o.createElement)(k.a,{tabIndex:-1,elevation:8,ref:S,className:Object(d.default)(y.paper,"top"===r&&y.topTransition),onBlur:T},n)))}))},L=function(e){var t=e.children,n=e.DateInputProps,r=e.KeyboardDateInputComponent,i=void 0===r?m.a:r,a=e.onDismiss,s=e.open,c=e.PopperProps,u=e.TransitionComponent,d=Object(o.useRef)(null),f=Object(p.c)(s),h=f.canAutoFocus,g=f.onOpen;return Object(o.createElement)(v.c.Provider,{value:"desktop"},Object(o.createElement)(p.a.Provider,{value:h},Object(o.createElement)(i,Object(l.a)({},n,{inputRef:d})),Object(o.createElement)(j,{role:"dialog",open:s,anchorEl:d.current,TransitionComponent:u,PopperProps:c,onClose:a,onOpen:g},t)))},B=function(e,t){return function(n){var r=n.cancelText,a=n.clearable,s=n.clearText,c=n.desktopModeMediaQuery,d=void 0===c?u.b:c,f=n.DialogProps,h=(n.displayStaticWrapperAs,n.okText),p=n.PopperProps,m=n.showTodayButton,v=n.todayText,b=n.TransitionComponent,y=Object(i.a)(n,["cancelText","clearable","clearText","desktopModeMediaQuery","DialogProps","displayStaticWrapperAs","okText","PopperProps","showTodayButton","todayText","TransitionComponent"]);return Object(g.a)(d)?Object(o.createElement)(e,Object(l.a)({PopperProps:p,TransitionComponent:b},y)):Object(o.createElement)(t,Object(l.a)({okText:h,cancelText:r,clearText:s,todayText:v,showTodayButton:m,clearable:a,DialogProps:f},y))}},z=B(L,D),F=(B((function(e){var t=e.open,n=e.children,r=e.PopperProps,i=e.onDismiss,a=e.DateInputProps,s=e.TransitionComponent,c=e.KeyboardDateInputComponent,u=void 0===c?m.a:c,d=Object(o.useRef)(null),f=Object(o.useRef)(null),h=Object(p.c)(t),g=h.canAutoFocus,b=h.onOpen,y=function(){Object(p.e)((function(){var e,t;(null===(e=d.current)||void 0===e?void 0:e.contains(document.activeElement))||(null===(t=f.current)||void 0===t?void 0:t.contains(document.activeElement))||i()}))};return Object(o.createElement)(v.c.Provider,{value:"desktop"},Object(o.createElement)(p.a.Provider,{value:g},Object(o.createElement)(u,Object(l.a)({},a,{containerRef:d,onBlur:y})),Object(o.createElement)(j,{role:"tooltip",open:t,innerRef:f,anchorEl:d.current,TransitionComponent:s,PopperProps:r,onBlur:y,onClose:i,onOpen:b},n)))}),D),Object(s.a)((function(e){return{root:{overflow:"hidden",minWidth:u.f,display:"flex",flexDirection:"column",backgroundColor:e.palette.background.paper}}}),{name:"MuiPickersStaticWrapper"})),U=function(e){var t=e.displayStaticWrapperAs,n=void 0===t?"static":t,r=e.children,i=F();return Object(o.createElement)(v.b.Provider,{value:!0},Object(o.createElement)(v.c.Provider,{value:n},Object(o.createElement)("div",{className:i.root,children:r})))},q=function(e,t){return e===t};function V(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.defaultValidationError,r=t.isSameError,i=void 0===r?q:r;return function(t,r){var a=Object(u.h)(),s=Object(o.useRef)(n||null),c=e(a,t,r);return Object(o.useEffect)((function(){r.onError&&!i(c,s.current)&&r.onError(c,t),s.current=c}),[s,r,c,t]),c}}function W(e,t){var n=e.inputFormat,r=e.disabled,i=e.readOnly,a=e.onAccept,s=e.onChange,c=e.disableCloseOnSelect,l=e.value;if(!n)throw new Error("inputFormat prop is required");var d=Object(u.d)(),f=Object(u.h)(),p=function(e){var t=e.open,n=e.onOpen,r=e.onClose,i=Object(o.useRef)("boolean"===typeof t).current,a=Object(o.useState)(!1),s=Object(h.a)(a,2),c=s[0],u=s[1];return Object(o.useEffect)((function(){if(i){if("boolean"!==typeof t)throw new Error("You must not mix controlling and uncontrolled mode for `open` prop");u(t)}}),[i,t]),{isOpen:c,setIsOpen:Object(o.useCallback)((function(e){return i||u(e),e?n&&n():r&&r()}),[i,n,r])}}(e),m=p.isOpen,g=p.setIsOpen,v=Object(o.useState)(t.parseInput(f,e)),b=Object(h.a)(v,2),y=b[0],w=b[1],S=Object(o.useState)(!1),_=Object(h.a)(S,2),k=_[0],x=_[1];Object(o.useEffect)((function(){var n=t.parseInput(f,e);w((function(e){return t.areValuesEqual(f,e,n)?e:n}))}),[l,f]);var E=Object(o.useCallback)((function(e,t){s(e),t&&(g(!1),a&&a(e))}),[a,s,g]),O=Object(o.useMemo)((function(){return{open:m,onClear:function(){return E(t.emptyValue,!0)},onAccept:function(){return E(y,!0)},onDismiss:function(){return g(!1)},onSetToday:function(){w(d),E(d,!c)}}}),[E,c,m,d,y,g,t.emptyValue]),M={pickerProps:Object(o.useMemo)((function(){return{date:y,isMobileKeyboardViewOpen:k,toggleMobileKeyboardView:function(){k||w(y),x(!k)},onDateChange:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"partial";if(w(e),"partial"===n&&E(e,!1),"finish"===n){var r=!(null!==c&&void 0!==c?c:"mobile"===t);E(e,r)}}}}),[E,c,k,y]),inputProps:Object(o.useMemo)((function(){return{onChange:s,inputFormat:n,open:m,rawValue:l,openPicker:function(){return!i&&!r&&g(!0)}}}),[s,n,m,l,i,r,g]),wrapperProps:O};return Object(o.useDebugValue)(M,(function(){return{MuiPickerState:{pickerDate:y,other:M}}})),M}function H(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function K(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:["all"],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.duration,s=void 0===n?o.standard:n,c=t.easing,u=void 0===c?i.easeInOut:c,l=t.delay,d=void 0===l?0:l;Object(r.a)(t,["duration","easing","delay"]);return(Array.isArray(e)?e:[e]).map((function(e){return"".concat(e," ").concat("string"===typeof s?s:a(s)," ").concat(u," ").concat("string"===typeof d?d:a(d))})).join(",")},getAutoHeightDuration:function(e){if(!e)return 0;var t=e/36;return Math.round(10*(4+15*Math.pow(t,.25)+t/5))}}},function(e,t,n){var r=n(34);e.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},function(e,t,n){"use strict";n.r(t);var r=n(263);n.d(t,"default",(function(){return r.a}))},function(e,t,n){"use strict";(function(e){var r=n(1862),i=n(1863),o=n(1864);function a(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function p(e,t){if(c.isBuffer(e))return e.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!==typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return U(e).length;default:if(r)return F(e).length;t=(""+t).toLowerCase(),r=!0}}function m(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return T(this,t,n);case"utf8":case"utf-8":return O(this,t,n);case"ascii":return M(this,t,n);case"latin1":case"binary":return C(this,t,n);case"base64":return E(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function v(e,t,n,r,i){if(0===e.length)return-1;if("string"===typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"===typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:b(e,t,n,r,i);if("number"===typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):b(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function b(e,t,n,r,i){var o,a=1,s=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,c/=2,n/=2}function u(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var l=-1;for(o=n;os&&(n=s-c),o=n;o>=0;o--){for(var d=!0,f=0;fi&&(r=i):r=i;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var a=0;a>8,i=n%256,o.push(i),o.push(r);return o}(t,e.length-n),e,n,r)}function E(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function O(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i239?4:u>223?3:u>191?2:1;if(i+d<=n)switch(d){case 1:u<128&&(l=u);break;case 2:128===(192&(o=e[i+1]))&&(c=(31&u)<<6|63&o)>127&&(l=c);break;case 3:o=e[i+1],a=e[i+2],128===(192&o)&&128===(192&a)&&(c=(15&u)<<12|(63&o)<<6|63&a)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128===(192&o)&&128===(192&a)&&128===(192&s)&&(c=(15&u)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&c<1114112&&(l=c)}null===l?(l=65533,d=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),i+=d}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},c.prototype.compare=function(e,t,n,r,i){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),s=Math.min(o,a),u=this.slice(r,i),l=e.slice(t,n),d=0;di)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return y(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return S(this,e,t,n);case"latin1":case"binary":return _(this,e,t,n);case"base64":return k(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function M(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;ir)&&(n=r);for(var i="",o=t;on)throw new RangeError("Trying to access beyond buffer length")}function P(e,t,n,r,i,o){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function R(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i>>8*(r?i:1-i)}function D(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i>>8*(r?i:3-i)&255}function N(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function j(e,t,n,r,o){return o||N(e,0,n,4),i.write(e,t,n,r,23,4),n+4}function L(e,t,n,r,o){return o||N(e,0,n,8),i.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t0&&(i*=256);)r+=this[e+--t]*i;return r},c.prototype.readUInt8=function(e,t){return t||I(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||I(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||I(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||I(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||I(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||I(e,t,this.length);for(var r=this[e],i=1,o=0;++o=(i*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||I(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},c.prototype.readInt8=function(e,t){return t||I(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||I(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||I(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||I(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||I(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||I(e,4,this.length),i.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||I(e,4,this.length),i.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||I(e,8,this.length),i.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||I(e,8,this.length),i.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||P(this,e,t,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[t]=255&e;++o=0&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):R(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):R(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):D(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);P(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);P(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):R(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):R(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):D(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return j(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return j(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return L(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return L(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t=0;--i)e[i+t]=this[i+n];else if(o<1e3||!c.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"===typeof e)for(o=t;o55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function U(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(B,"")).length<2)return"";for(;e.length%4!==0;)e+="=";return e}(e))}function q(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}}).call(this,n(56))},function(e,t,n){"use strict";var r=n(6),i=n(13),o=n(14),a=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(t){o(t)}}function s(e){try{c(r.throw(e))}catch(t){o(t)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});var s=n(1073),c=n(708),u=function(){function e(t){i(this,e),this.logger=t,this.taskName="BaseTask",this.parentTask=null,this.status=c.default.IDLE,this.run=this.baseRun.bind(this,this.run),this.cancel=this.baseCancel.bind(this,this.cancel)}return o(e,[{key:"once",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n1)for(var n=1;n0)return i.getInlineStyleAt(r-1);if(i.getLength())return i.getInlineStyleAt(0);return w(e,n)}(t,n):function(e,t){var n=t.getStartKey(),r=t.getStartOffset(),i=e.getBlockForKey(n);if(r0)return i.getInlineStyleAt(r-1);return w(e,n)}(t,n)},e.getBlockTree=function(e){return this.getImmutable().getIn(["treeMap",e])},e.isSelectionAtStartOfContent=function(){var e=this.getCurrentContent().getBlockMap().first().getKey();return this.getSelection().hasEdgeWithin(e,0,0)},e.isSelectionAtEndOfContent=function(){var e=this.getCurrentContent().getBlockMap().last(),t=e.getLength();return this.getSelection().hasEdgeWithin(e.getKey(),t,t)},e.getDirectionMap=function(){return this.getImmutable().get("directionMap")},t.acceptSelection=function(e,t){return v(e,t,!1)},t.forceSelection=function(e,t){return t.getHasFocus()||(t=t.set("hasFocus",!0)),v(e,t,!0)},t.moveSelectionToEnd=function(e){var n=e.getCurrentContent().getLastBlock(),r=n.getKey(),i=n.getLength();return t.acceptSelection(e,new c({anchorKey:r,anchorOffset:i,focusKey:r,focusOffset:i,isBackward:!1}))},t.moveFocusToEnd=function(e){var n=t.moveSelectionToEnd(e);return t.forceSelection(n,n.getSelection())},t.push=function(e,n,r){var i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];if(e.getCurrentContent()===n)return e;var o=s.getDirectionMap(n,e.getDirectionMap());if(!e.getAllowUndo())return t.set(e,{currentContent:n,directionMap:o,lastChangeType:r,selection:n.getSelectionAfter(),forceSelection:i,inlineStyleOverride:null});var a=e.getSelection(),c=e.getCurrentContent(),u=e.getUndoStack(),l=n;a!==c.getSelectionAfter()||y(e,r)?(u=u.push(c),l=l.set("selectionBefore",a)):"insert-characters"!==r&&"backspace-character"!==r&&"delete-character"!==r||(l=l.set("selectionBefore",c.getSelectionBefore()));var d=e.getInlineStyleOverride(),h=["adjust-depth","change-block-type","split-block"];-1===h.indexOf(r)&&(d=null);var p={currentContent:l,directionMap:o,undoStack:u,redoStack:f(),lastChangeType:r,selection:n.getSelectionAfter(),forceSelection:i,inlineStyleOverride:d};return t.set(e,p)},t.undo=function(e){if(!e.getAllowUndo())return e;var n=e.getUndoStack(),r=n.peek();if(!r)return e;var i=e.getCurrentContent(),o=s.getDirectionMap(r,e.getDirectionMap());return t.set(e,{currentContent:r,directionMap:o,undoStack:n.shift(),redoStack:e.getRedoStack().push(i),forceSelection:!0,inlineStyleOverride:null,lastChangeType:"undo",nativelyRenderedContent:null,selection:i.getSelectionBefore()})},t.redo=function(e){if(!e.getAllowUndo())return e;var n=e.getRedoStack(),r=n.peek();if(!r)return e;var i=e.getCurrentContent(),o=s.getDirectionMap(r,e.getDirectionMap());return t.set(e,{currentContent:r,directionMap:o,undoStack:e.getUndoStack().push(i),redoStack:n.shift(),forceSelection:!0,inlineStyleOverride:null,lastChangeType:"redo",nativelyRenderedContent:null,selection:r.getSelectionAfter()})},e.getImmutable=function(){return this._immutable},t}();function v(e,t,n){return g.set(e,{selection:t,forceSelection:n,nativelyRenderedContent:null,inlineStyleOverride:null})}function b(e,t){return e.getBlockMap().map((function(n){return o.generate(e,n,t)})).toOrderedMap()}function y(e,t){return t!==e.getLastChangeType()||"insert-characters"!==t&&"backspace-character"!==t&&"delete-character"!==t}function w(e,t){var n=e.getBlockMap().reverse().skipUntil((function(e,n){return n===t})).skip(1).skipUntil((function(e,t){return e.getLength()})).first();return n?n.getInlineStyleAt(n.getLength()-1):l()}e.exports=g},function(e,t,n){"use strict";var r=n(17),i=n(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=i(n(1)),a=(0,r(n(20)).default)(o.createElement("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"}),"Add");t.default=a},function(e,t,n){"use strict";var r=n(53);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"MTableAction",{enumerable:!0,get:function(){return l.MTableAction}}),Object.defineProperty(t,"MTableActions",{enumerable:!0,get:function(){return l.MTableActions}}),Object.defineProperty(t,"MTableBody",{enumerable:!0,get:function(){return l.MTableBody}}),Object.defineProperty(t,"MTableBodyRow",{enumerable:!0,get:function(){return l.MTableBodyRow}}),Object.defineProperty(t,"MTableCell",{enumerable:!0,get:function(){return l.MTableCell}}),Object.defineProperty(t,"MTableEditCell",{enumerable:!0,get:function(){return l.MTableEditCell}}),Object.defineProperty(t,"MTableEditField",{enumerable:!0,get:function(){return l.MTableEditField}}),Object.defineProperty(t,"MTableEditRow",{enumerable:!0,get:function(){return l.MTableEditRow}}),Object.defineProperty(t,"MTableFilterRow",{enumerable:!0,get:function(){return l.MTableFilterRow}}),Object.defineProperty(t,"MTableGroupRow",{enumerable:!0,get:function(){return l.MTableGroupRow}}),Object.defineProperty(t,"MTableGroupbar",{enumerable:!0,get:function(){return l.MTableGroupbar}}),Object.defineProperty(t,"MTableHeader",{enumerable:!0,get:function(){return l.MTableHeader}}),Object.defineProperty(t,"MTablePagination",{enumerable:!0,get:function(){return l.MTablePagination}}),Object.defineProperty(t,"MTableSteppedPagination",{enumerable:!0,get:function(){return l.MTableSteppedPagination}}),Object.defineProperty(t,"MTableToolbar",{enumerable:!0,get:function(){return l.MTableToolbar}}),t.default=void 0;var i=r(n(92));n(1570);var o=r(n(1)),a=n(1571),s=n(1612),c=r(n(1613)),u=n(28),l=n(255);c.default.defaultProps=a.defaultProps,c.default.propTypes=s.propTypes;var d=(0,u.withStyles)((function(e){return{paginationRoot:{width:"100%"},paginationToolbar:{padding:0,width:"100%"},paginationCaption:{display:"none"},paginationSelectRoot:{margin:0}}}),{withTheme:!0})((function(e){return o.default.createElement(c.default,(0,i.default)({},e,{ref:e.tableRef}))}));t.default=d},function(e,t,n){e.exports=n(642)},function(e,t,n){"use strict";n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return o}));var r=n(1),i="undefined"===typeof window?r.useEffect:r.useLayoutEffect;function o(e,t){var n=Object(r.useRef)(t);n.current=t,i((function(){if(e){var t=function(e){!function(e,t){var n=t[e.keyCode];n&&(n(),e.preventDefault())}(e,n.current)};return window.addEventListener("keydown",t),function(){window.removeEventListener("keydown",t)}}}),[e])}var a={ArrowUp:38,ArrowDown:40,ArrowLeft:37,ArrowRight:39,Enter:13,Home:36,End:35,PageUp:33,PageDown:34,Esc:27}},function(e,t,n){"use strict";var r,i=n(10),o=n.n(i),a=n(23),s=n.n(a),c=n(265),u=n.n(c),l=n(44),d=n.n(l),f=n(30),h=n.n(f),p=n(1258),m=n.n(p),g=n(48),v=n.n(g),b=n(773),y=n.n(b),w=n(774),S=n.n(w),_=n(1259),k=n.n(_),x=n(1260),E=n.n(x),O=n(775),M=n.n(O),C=function(e,t){if(/^[a-z]+:/i.test(t))return t;/^data:/.test(e)&&(e=o.a.location&&o.a.location.href||"");var n="function"===typeof o.a.URL,r=/^\/\//.test(e),i=!o.a.location&&!/\/\//i.test(e);if(n?e=new o.a.URL(e,o.a.location||"http://example.com"):/\/\//i.test(e)||(e=M.a.buildAbsoluteURL(o.a.location&&o.a.location.href||"",e)),n){var a=new URL(t,e);return i?a.href.slice("http://example.com".length):r?a.href.slice(a.protocol.length):a.href}return M.a.buildAbsoluteURL(e,t)},T=n(595),A=n.n(T),I=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]=this.listeners[e].slice(0),this.listeners[e].splice(n,1),n>-1},t.trigger=function(e){var t=this.listeners[e];if(t)if(2===arguments.length)for(var n=t.length,r=0;r-1;t=this.buffer.indexOf("\n"))this.trigger("data",this.buffer.substring(0,t)),this.buffer=this.buffer.substring(t+1)},t}(I),B=String.fromCharCode(9),z=function(e){var t=/([0-9.]*)?@?([0-9.]*)?/.exec(e||""),n={};return t[1]&&(n.length=parseInt(t[1],10)),t[2]&&(n.offset=parseInt(t[2],10)),n},F=function(e){for(var t,n=e.split(new RegExp('(?:^|,)((?:[^=]*)=(?:"[^"]*"|[^,]*))')),r={},i=n.length;i--;)""!==n[i]&&((t=/([^=]*)=(.*)/.exec(n[i]).slice(1))[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},U=function(e){function t(){var t;return(t=e.call(this)||this).customParsers=[],t.tagMappers=[],t}A()(t,e);var n=t.prototype;return n.push=function(e){var t,n,r=this;0!==(e=e.trim()).length&&("#"===e[0]?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;i0&&(a.duration=e.duration),0===e.duration&&(a.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=o},key:function(){if(e.attributes)if("NONE"!==e.attributes.METHOD)if(e.attributes.URI){if("com.apple.streamingkeydelivery"===e.attributes.KEYFORMAT)return this.manifest.contentProtection=this.manifest.contentProtection||{},void(this.manifest.contentProtection["com.apple.fps.1_0"]={attributes:e.attributes});if("urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed"===e.attributes.KEYFORMAT){return-1===["SAMPLE-AES","SAMPLE-AES-CTR","SAMPLE-AES-CENC"].indexOf(e.attributes.METHOD)?void this.trigger("warn",{message:"invalid key method provided for Widevine"}):("SAMPLE-AES-CENC"===e.attributes.METHOD&&this.trigger("warn",{message:"SAMPLE-AES-CENC is deprecated, please use SAMPLE-AES-CTR instead"}),"data:text/plain;base64,"!==e.attributes.URI.substring(0,23)?void this.trigger("warn",{message:"invalid key URI provided for Widevine"}):e.attributes.KEYID&&"0x"===e.attributes.KEYID.substring(0,2)?(this.manifest.contentProtection=this.manifest.contentProtection||{},void(this.manifest.contentProtection["com.widevine.alpha"]={attributes:{schemeIdUri:e.attributes.KEYFORMAT,keyId:e.attributes.KEYID.substring(2)},pssh:Object(j.a)(e.attributes.URI.split(",")[1])})):void this.trigger("warn",{message:"invalid key ID provided for Widevine"}))}e.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),r={method:e.attributes.METHOD||"AES-128",uri:e.attributes.URI},"undefined"!==typeof e.attributes.IV&&(r.iv=e.attributes.IV)}else this.trigger("warn",{message:"ignoring key declaration without URI"});else r=null;else this.trigger("warn",{message:"ignoring key declaration without attribute list"})},"media-sequence":function(){isFinite(e.number)?this.manifest.mediaSequence=e.number:this.trigger("warn",{message:"ignoring invalid media sequence: "+e.number})},"discontinuity-sequence":function(){isFinite(e.number)?(this.manifest.discontinuitySequence=e.number,l=e.number):this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+e.number})},"playlist-type":function(){/VOD|EVENT/.test(e.playlistType)?this.manifest.playlistType=e.playlistType:this.trigger("warn",{message:"ignoring unknown playlist type: "+e.playlist})},map:function(){n={},e.uri&&(n.uri=e.uri),e.byterange&&(n.byterange=e.byterange),r&&(n.key=r)},"stream-inf":function(){this.manifest.playlists=o,this.manifest.mediaGroups=this.manifest.mediaGroups||u,e.attributes?(a.attributes||(a.attributes={}),R()(a.attributes,e.attributes)):this.trigger("warn",{message:"ignoring empty stream-inf attributes"})},media:function(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||u,e.attributes&&e.attributes.TYPE&&e.attributes["GROUP-ID"]&&e.attributes.NAME){var n=this.manifest.mediaGroups[e.attributes.TYPE];n[e.attributes["GROUP-ID"]]=n[e.attributes["GROUP-ID"]]||{},t=n[e.attributes["GROUP-ID"]],(h={default:/yes/i.test(e.attributes.DEFAULT)}).default?h.autoselect=!0:h.autoselect=/yes/i.test(e.attributes.AUTOSELECT),e.attributes.LANGUAGE&&(h.language=e.attributes.LANGUAGE),e.attributes.URI&&(h.uri=e.attributes.URI),e.attributes["INSTREAM-ID"]&&(h.instreamId=e.attributes["INSTREAM-ID"]),e.attributes.CHARACTERISTICS&&(h.characteristics=e.attributes.CHARACTERISTICS),e.attributes.FORCED&&(h.forced=/yes/i.test(e.attributes.FORCED)),t[e.attributes.NAME]=h}else this.trigger("warn",{message:"ignoring incomplete or missing media group"})},discontinuity:function(){l+=1,a.discontinuity=!0,this.manifest.discontinuityStarts.push(o.length)},"program-date-time":function(){"undefined"===typeof this.manifest.dateTimeString&&(this.manifest.dateTimeString=e.dateTimeString,this.manifest.dateTimeObject=e.dateTimeObject),a.dateTimeString=e.dateTimeString,a.dateTimeObject=e.dateTimeObject},targetduration:function(){!isFinite(e.duration)||e.duration<0?this.trigger("warn",{message:"ignoring invalid target duration: "+e.duration}):(this.manifest.targetDuration=e.duration,V.call(this,this.manifest))},start:function(){e.attributes&&!isNaN(e.attributes["TIME-OFFSET"])?this.manifest.start={timeOffset:e.attributes["TIME-OFFSET"],precise:e.attributes.PRECISE}:this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"})},"cue-out":function(){a.cueOut=e.data},"cue-out-cont":function(){a.cueOutCont=e.data},"cue-in":function(){a.cueIn=e.data},skip:function(){this.manifest.skip=q(e.attributes),this.warnOnMissingAttributes_("#EXT-X-SKIP",e.attributes,["SKIPPED-SEGMENTS"])},part:function(){var t=this;s=!0;var n=this.manifest.segments.length,r=q(e.attributes);a.parts=a.parts||[],a.parts.push(r),r.byterange&&(r.byterange.hasOwnProperty("offset")||(r.byterange.offset=f),f=r.byterange.offset+r.byterange.length);var i=a.parts.length-1;this.warnOnMissingAttributes_("#EXT-X-PART #"+i+" for segment #"+n,e.attributes,["URI","DURATION"]),this.manifest.renditionReports&&this.manifest.renditionReports.forEach((function(e,n){e.hasOwnProperty("lastPart")||t.trigger("warn",{message:"#EXT-X-RENDITION-REPORT #"+n+" lacks required attribute(s): LAST-PART"})}))},"server-control":function(){var t=this.manifest.serverControl=q(e.attributes);t.hasOwnProperty("canBlockReload")||(t.canBlockReload=!1,this.trigger("info",{message:"#EXT-X-SERVER-CONTROL defaulting CAN-BLOCK-RELOAD to false"})),V.call(this,this.manifest),t.canSkipDateranges&&!t.hasOwnProperty("canSkipUntil")&&this.trigger("warn",{message:"#EXT-X-SERVER-CONTROL lacks required attribute CAN-SKIP-UNTIL which is required when CAN-SKIP-DATERANGES is set"})},"preload-hint":function(){var t=this.manifest.segments.length,n=q(e.attributes),r=n.type&&"PART"===n.type;a.preloadHints=a.preloadHints||[],a.preloadHints.push(n),n.byterange&&(n.byterange.hasOwnProperty("offset")||(n.byterange.offset=r?f:0,r&&(f=n.byterange.offset+n.byterange.length)));var i=a.preloadHints.length-1;if(this.warnOnMissingAttributes_("#EXT-X-PRELOAD-HINT #"+i+" for segment #"+t,e.attributes,["TYPE","URI"]),n.type)for(var o=0;o=0&&(h.minimumUpdatePeriod=1e3*c),t&&(h.locations=t),"dynamic"===a&&(h.suggestedPresentationDelay=s);var p=0===h.playlists.length;return l.length&&(h.mediaGroups.AUDIO.audio=function(e,t,n){var r;void 0===t&&(t={}),void 0===n&&(n=!1);var i=e.reduce((function(e,i){var o=i.attributes.role&&i.attributes.role.value||"",a=i.attributes.lang||"",s=i.attributes.label||"main";if(a&&!i.attributes.label){var c=o?" ("+o+")":"";s=""+i.attributes.lang+c}e[s]||(e[s]={language:a,autoselect:!0,default:"main"===o,playlists:[],uri:""});var u=_e(function(e,t){var n,r=e.attributes,i=e.segments,o=e.sidx,a={attributes:(n={NAME:r.id,BANDWIDTH:r.bandwidth,CODECS:r.codecs},n["PROGRAM-ID"]=1,n),uri:"",endList:"static"===r.type,timeline:r.periodIndex,resolvedUri:"",targetDuration:r.duration,segments:i,mediaSequence:i.length?i[0].number:1};return r.contentProtection&&(a.contentProtection=r.contentProtection),o&&(a.sidx=o),t&&(a.attributes.AUDIO="audio",a.attributes.SUBTITLES="subs"),a}(i,n),t);return e[s].playlists.push(u),"undefined"===typeof r&&"main"===o&&((r=i).default=!0),e}),{});r||(i[Object.keys(i)[0]].default=!0);return i}(l,n,p)),d.length&&(h.mediaGroups.SUBTITLES.subs=function(e,t){return void 0===t&&(t={}),e.reduce((function(e,n){var r=n.attributes.lang||"text";return e[r]||(e[r]={language:r,default:!1,autoselect:!1,playlists:[],uri:""}),e[r].playlists.push(_e(function(e){var t,n=e.attributes,r=e.segments;"undefined"===typeof r&&(r=[{uri:n.baseUrl,timeline:n.periodIndex,resolvedUri:n.baseUrl||"",duration:n.sourceDuration,number:0}],n.duration=n.sourceDuration);var i=((t={NAME:n.id,BANDWIDTH:n.bandwidth})["PROGRAM-ID"]=1,t);return n.codecs&&(i.CODECS=n.codecs),{attributes:i,uri:"",endList:"static"===n.type,timeline:n.periodIndex,resolvedUri:n.baseUrl||"",targetDuration:n.duration,segments:r,mediaSequence:r.length?r[0].number:1}}(n),t)),e}),{})}(d,n)),f.length&&(h.mediaGroups["CLOSED-CAPTIONS"].cc=f.reduce((function(e,t){return t?(t.forEach((function(t){var n=t.channel,r=t.language;e[r]={autoselect:!1,default:!1,instreamId:n,language:r},t.hasOwnProperty("aspectRatio")&&(e[r].aspectRatio=t.aspectRatio),t.hasOwnProperty("easyReader")&&(e[r].easyReader=t.easyReader),t.hasOwnProperty("3D")&&(e[r]["3D"]=t["3D"])})),e):e}),{})),h},Te=function(e,t,n){var r=e.NOW,i=e.clientOffset,o=e.availabilityStartTime,a=e.timescale,s=void 0===a?1:a,c=e.start,u=void 0===c?0:c,l=e.minimumUpdatePeriod,d=(r+i)/1e3+(void 0===l?0:l)-(o+u);return Math.ceil((d*s-t)/n)},Ae=function(e,t){for(var n=e.type,r=e.minimumUpdatePeriod,i=void 0===r?0:r,o=e.media,a=void 0===o?"":o,s=e.sourceDuration,c=e.timescale,u=void 0===c?1:c,l=e.startNumber,d=void 0===l?1:l,f=e.periodIndex,h=[],p=-1,m=0;mp&&(p=y);var w=void 0;if(b<0){var S=m+1;w=S===t.length?"dynamic"===n&&i>0&&a.indexOf("$Number$")>0?Te(e,p,v):(s*u-p)/v:(t[S].t-p)/v}else w=b+1;for(var _=d+h.length+w,k=d+h.length;k<_;)h.push({number:k,duration:v/u,time:p,timeline:f}),p+=v,k++}return h},Ie=/\$([A-z]*)(?:(%0)([0-9]+)d)?\$/g,Pe=function(e,t){return e.replace(Ie,function(e){return function(t,n,r,i){if("$$"===t)return"$";if("undefined"===typeof e[n])return t;var o=""+e[n];return"RepresentationID"===n?o:(i=r?parseInt(i,10):1,o.length>=i?o:""+new Array(i-o.length+1).join("0")+o)}}(t))},Re=function(e,t){var n={RepresentationID:e.id,Bandwidth:e.bandwidth||0},r=e.initialization,i=void 0===r?{sourceURL:"",range:""}:r,o=pe({baseUrl:e.baseUrl,source:Pe(i.sourceURL,n),range:i.range});return function(e,t){return e.duration||t?e.duration?ve(e):Ae(e,t):[{number:e.startNumber||1,duration:e.sourceDuration,time:0,timeline:e.periodIndex}]}(e,t).map((function(t){n.Number=t.number,n.Time=t.time;var r=Pe(e.media||"",n),i=e.timescale||1,a=e.presentationTimeOffset||0,s=e.periodStart+(t.time-a)/i;return{uri:r,timeline:t.timeline,duration:t.duration,resolvedUri:C(e.baseUrl||"",r),map:o,number:t.number,presentationTime:s}}))},De=function(e,t){var n=e.duration,r=e.segmentUrls,i=void 0===r?[]:r,o=e.periodStart;if(!n&&!t||n&&t)throw new Error(fe);var a,s=i.map((function(t){return function(e,t){var n=e.baseUrl,r=e.initialization,i=void 0===r?{}:r,o=pe({baseUrl:n,source:i.sourceURL,range:i.range}),a=pe({baseUrl:n,source:t.media,range:t.mediaRange});return a.map=o,a}(e,t)}));return n&&(a=ve(e)),t&&(a=Ae(e,t)),a.map((function(t,n){if(s[n]){var r=s[n],i=e.timescale||1,a=e.presentationTimeOffset||0;return r.timeline=t.timeline,r.duration=t.duration,r.number=t.number,r.presentationTime=o+(t.time-a)/i,r}})).filter((function(e){return e}))},Ne=function(e){var t,n,r=e.attributes,i=e.segmentInfo;i.template?(n=Re,t=oe(r,i.template)):i.base?(n=be,t=oe(r,i.base)):i.list&&(n=De,t=oe(r,i.list));var o={attributes:r};if(!n)return o;var a=n(t,i.segmentTimeline);if(t.duration){var s=t,c=s.duration,u=s.timescale,l=void 0===u?1:u;t.duration=c/l}else a.length?t.duration=a.reduce((function(e,t){return Math.max(e,Math.ceil(t.duration))}),0):t.duration=0;return o.attributes=t,o.segments=a,i.base&&t.indexRange&&(o.sidx=a[0],o.segments=[]),o},je=function(e,t){return se(e.childNodes).filter((function(e){return e.tagName===t}))},Le=function(e){return e.textContent.trim()},Be=function(e){var t=/P(?:(\d*)Y)?(?:(\d*)M)?(?:(\d*)D)?(?:T(?:(\d*)H)?(?:(\d*)M)?(?:([\d.]*)S)?)?/.exec(e);if(!t)return 0;var n=t.slice(1),r=n[0],i=n[1],o=n[2],a=n[3],s=n[4],c=n[5];return 31536e3*parseFloat(r||0)+2592e3*parseFloat(i||0)+86400*parseFloat(o||0)+3600*parseFloat(a||0)+60*parseFloat(s||0)+parseFloat(c||0)},ze={mediaPresentationDuration:function(e){return Be(e)},availabilityStartTime:function(e){return/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(t=e)&&(t+="Z"),Date.parse(t)/1e3;var t},minimumUpdatePeriod:function(e){return Be(e)},suggestedPresentationDelay:function(e){return Be(e)},type:function(e){return e},timeShiftBufferDepth:function(e){return Be(e)},start:function(e){return Be(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)},presentationTimeOffset:function(e){return parseInt(e,10)},duration:function(e){var t=parseInt(e,10);return isNaN(t)?Be(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}},Fe=function(e){return e&&e.attributes?se(e.attributes).reduce((function(e,t){var n=ze[t.name]||ze.DEFAULT;return e[t.name]=n(t.value),e}),{}):{}},Ue={"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"},qe=function(e,t){return t.length?ae(e.map((function(e){return t.map((function(t){return C(e,Le(t))}))}))):e},Ve=function(e){var t=je(e,"SegmentTemplate")[0],n=je(e,"SegmentList")[0],r=n&&je(n,"SegmentURL").map((function(e){return oe({tag:"SegmentURL"},Fe(e))})),i=je(e,"SegmentBase")[0],o=n||t,a=o&&je(o,"SegmentTimeline")[0],s=n||i||t,c=s&&je(s,"Initialization")[0],u=t&&Fe(t);u&&c?u.initialization=c&&Fe(c):u&&u.initialization&&(u.initialization={sourceURL:u.initialization});var l={template:u,segmentTimeline:a&&je(a,"S").map((function(e){return Fe(e)})),list:n&&oe(Fe(n),{segmentUrls:r,initialization:Fe(c)}),base:i&&oe(Fe(i),{initialization:Fe(c)})};return Object.keys(l).forEach((function(e){l[e]||delete l[e]})),l},We=function(e,t,n){return function(r){var i,o=Fe(r),a=qe(t,je(r,"BaseURL")),s=je(r,"Role")[0],c={role:Fe(s)},u=oe(e,o,c),l=je(r,"Accessibility")[0],d="urn:scte:dash:cc:cea-608:2015"===(i=Fe(l)).schemeIdUri?i.value.split(";").map((function(e){var t,n;if(n=e,/^CC\d=/.test(e)){var r=e.split("=");t=r[0],n=r[1]}else/^CC\d$/.test(e)&&(t=e);return{channel:t,language:n}})):"urn:scte:dash:cc:cea-708:2015"===i.schemeIdUri?i.value.split(";").map((function(e){var t={channel:void 0,language:void 0,aspectRatio:1,easyReader:0,"3D":0};if(/=/.test(e)){var n=e.split("="),r=n[0],i=n[1],o=void 0===i?"":i;t.channel=r,t.language=e,o.split(",").forEach((function(e){var n=e.split(":"),r=n[0],i=n[1];"lang"===r?t.language=i:"er"===r?t.easyReader=Number(i):"war"===r?t.aspectRatio=Number(i):"3D"===r&&(t["3D"]=Number(i))}))}else t.language=e;return t.channel&&(t.channel="SERVICE"+t.channel),t})):void 0;d&&(u=oe(u,{captionServices:d}));var f=je(r,"Label")[0];if(f&&f.childNodes.length){var h=f.childNodes[0].nodeValue.trim();u=oe(u,{label:h})}var p=je(r,"ContentProtection").reduce((function(e,t){var n=Fe(t),r=Ue[n.schemeIdUri];if(r){e[r]={attributes:n};var i=je(t,"cenc:pssh")[0];if(i){var o=Le(i),a=o&&Object(j.a)(o);e[r].pssh=a}}return e}),{});Object.keys(p).length&&(u=oe(u,{contentProtection:p}));var m=Ve(r),g=je(r,"Representation"),v=oe(n,m);return ae(g.map(function(e,t,n){return function(r){var i=je(r,"BaseURL"),o=qe(t,i),a=oe(e,Fe(r)),s=Ve(r);return o.map((function(e){return{segmentInfo:oe(n,s),attributes:oe(a,{baseUrl:e})}}))}}(u,a,v)))}},He=function(e,t){return function(n,r){var i=qe(t,je(n.node,"BaseURL")),a=parseInt(n.attributes.id,10),s=o.a.isNaN(a)?r:a,c=oe(e,{periodIndex:s,periodStart:n.attributes.start});"number"===typeof n.attributes.duration&&(c.periodDuration=n.attributes.duration);var u=je(n.node,"AdaptationSet"),l=Ve(n.node);return ae(u.map(We(c,i,l)))}},Ke=function(e){if(""===e)throw new Error(ue);var t,n,r=new re.DOMParser;try{n=(t=r.parseFromString(e,"application/xml"))&&"MPD"===t.documentElement.tagName?t.documentElement:null}catch(i){}if(!n||n&&n.getElementsByTagName("parsererror").length>0)throw new Error(le);return n},Ze=function(e,t){void 0===t&&(t={});var n=function(e,t){void 0===t&&(t={});var n=t,r=n.manifestUri,i=void 0===r?"":r,o=n.NOW,a=void 0===o?Date.now():o,s=n.clientOffset,c=void 0===s?0:s,u=je(e,"Period");if(!u.length)throw new Error(ce);var l=je(e,"Location"),d=Fe(e),f=qe([i],je(e,"BaseURL"));d.type=d.type||"static",d.sourceDuration=d.mediaPresentationDuration||0,d.NOW=a,d.clientOffset=c,l.length&&(d.locations=l.map(Le));var h=[];return u.forEach((function(e,t){var n=Fe(e),r=h[t-1];n.start=function(e){var t=e.attributes,n=e.priorPeriodAttributes,r=e.mpdType;return"number"===typeof t.start?t.start:n&&"number"===typeof n.start&&"number"===typeof n.duration?n.start+n.duration:n||"static"!==r?null:0}({attributes:n,priorPeriodAttributes:r?r.attributes:null,mpdType:d.type}),h.push({node:e,attributes:n})})),{locations:d.locations,representationInfo:ae(h.map(He(d,f)))}}(Ke(e),t),r=n.representationInfo.map(Ne);return Ce(r,n.locations,t.sidxMapping)},Ge=function(e){return function(e){var t=je(e,"UTCTiming")[0];if(!t)return null;var n=Fe(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(he)}return n}(Ke(e))},Xe=n(1263),Ye=n.n(Xe),$e=function(e){return e instanceof Uint8Array?e:(Array.isArray(e)||(t=e,ArrayBuffer.isView(t))||e instanceof ArrayBuffer||(e="number"!==typeof e||"number"===typeof e&&e!==e?0:[e]),new Uint8Array(e&&e.buffer||e,e&&e.byteOffset||0,e&&e.byteLength||0));var t},Je=o.a.BigInt||Number,Qe=[Je("0x1"),Je("0x100"),Je("0x10000"),Je("0x1000000"),Je("0x100000000"),Je("0x10000000000"),Je("0x1000000000000"),Je("0x100000000000000"),Je("0x10000000000000000")],et=(function(){var e=new Uint16Array([65484]),t=new Uint8Array(e.buffer,e.byteOffset,e.byteLength);255===t[0]||t[0]}(),function(e,t){var n=void 0===t?{}:t,r=n.signed,i=void 0!==r&&r,o=n.le,a=void 0!==o&&o;e=$e(e);var s=a?"reduce":"reduceRight",c=(e[s]?e[s]:Array.prototype[s]).call(e,(function(t,n,r){var i=a?r:Math.abs(r+1-e.length);return t+Je(n)*Qe[i]}),Je(0));if(i){var u=Qe[e.length]/Je(2)-Je(1);(c=Je(c))>u&&(c-=u,c-=u,c-=Je(2))}return Number(c)}),tt=function(e,t){var n=(void 0===t?{}:t).le,r=void 0!==n&&n;("bigint"!==typeof e&&"number"!==typeof e||"number"===typeof e&&e!==e)&&(e=0),e=Je(e);for(var i,o=(i=e,Math.ceil(function(e){return e.toString(2).length}(i)/8)),a=new Uint8Array(new ArrayBuffer(o)),s=0;s=t.length&&c.call(t,(function(t,n){return t===(s[n]?s[n]&e[o+n]:e[o+n])}))},ot=$e([73,68,51]),at=function e(t,n){return void 0===n&&(n=0),(t=$e(t)).length-n<10||!it(t,ot,{offset:n})?n:(n+=function(e,t){void 0===t&&(t=0);var n=(e=$e(e))[t+5],r=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9];return(16&n)>>4?r+20:r+10}(t,n),e(t,n))},st=(new Uint8Array([79,112,117,115,72,101,97,100]),function(e){return"string"===typeof e?rt(e):e}),ct=function(e){e=$e(e);for(var t=[],n=0;e.length>n;){var i=e[n],o=0,a=0,s=e[++a];for(a++;128&s;)o=(127&s)<<7,s=e[a],a++;o+=127&s;for(var c=0;c>>0,s=t.subarray(o+4,o+8);if(0===a)break;var c=o+a;if(c>t.length){if(r)break;c=t.length}var u=t.subarray(o+8,c);it(s,n[0])&&(1===n.length?i.push(u):i.push.apply(i,e(u,n.slice(1),r))),o=c}return i},lt={EBML:$e([26,69,223,163]),DocType:$e([66,130]),Segment:$e([24,83,128,103]),SegmentInfo:$e([21,73,169,102]),Tracks:$e([22,84,174,107]),Track:$e([174]),TrackNumber:$e([215]),DefaultDuration:$e([35,227,131]),TrackEntry:$e([174]),TrackType:$e([131]),FlagDefault:$e([136]),CodecID:$e([134]),CodecPrivate:$e([99,162]),VideoTrack:$e([224]),AudioTrack:$e([225]),Cluster:$e([31,67,182,117]),Timestamp:$e([231]),TimestampScale:$e([42,215,177]),BlockGroup:$e([160]),BlockDuration:$e([155]),Block:$e([161]),SimpleBlock:$e([163])},dt=[128,64,32,16,8,4,2,1],ft=function(e,t,n,r){void 0===n&&(n=!0),void 0===r&&(r=!1);var i=function(e){for(var t=1,n=0;n=n.length)return n.length;var i=ft(n,r,!1);if(it(t.bytes,i.bytes))return r;var o=ft(n,r+i.length);return e(t,n,r+o.length+o.value+i.length)},mt=function e(t,n){n=function(e){return Array.isArray(e)?e.map((function(e){return ht(e)})):[ht(e)]}(n),t=$e(t);var r=[];if(!n.length)return r;for(var i=0;it.length?t.length:s+a.value,u=t.subarray(s,c);it(n[0],o.bytes)&&(1===n.length?r.push(u):r=r.concat(e(u,n.slice(1)))),i+=o.length+a.length+u.length}return r},gt=$e([0,0,0,1]),vt=$e([0,0,1]),bt=$e([0,0,3]),yt=function(e){for(var t=[],n=1;n>1&63),-1!==n.indexOf(c)&&(i=o+s),o+=s+("h264"===t?1:2)}else o++}return e.subarray(0,0)},St={webm:$e([119,101,98,109]),matroska:$e([109,97,116,114,111,115,107,97]),flac:$e([102,76,97,67]),ogg:$e([79,103,103,83]),ac3:$e([11,119]),riff:$e([82,73,70,70]),avi:$e([65,86,73]),wav:$e([87,65,86,69]),"3gp":$e([102,116,121,112,51,103]),mp4:$e([102,116,121,112]),fmp4:$e([115,116,121,112]),mov:$e([102,116,121,112,113,116]),moov:$e([109,111,111,118]),moof:$e([109,111,111,102])},_t={aac:function(e){var t=at(e);return it(e,[255,16],{offset:t,mask:[255,22]})},mp3:function(e){var t=at(e);return it(e,[255,2],{offset:t,mask:[255,6]})},webm:function(e){var t=mt(e,[lt.EBML,lt.DocType])[0];return it(t,St.webm)},mkv:function(e){var t=mt(e,[lt.EBML,lt.DocType])[0];return it(t,St.matroska)},mp4:function(e){return!_t["3gp"](e)&&!_t.mov(e)&&(!(!it(e,St.mp4,{offset:4})&&!it(e,St.fmp4,{offset:4}))||(!(!it(e,St.moof,{offset:4})&&!it(e,St.moov,{offset:4}))||void 0))},mov:function(e){return it(e,St.mov,{offset:4})},"3gp":function(e){return it(e,St["3gp"],{offset:4})},ac3:function(e){var t=at(e);return it(e,St.ac3,{offset:t})},ts:function(e){if(e.length<189&&e.length>=1)return 71===e[0];for(var t=0;t+1880?c:0)}if(o.a.console){var u=o.a.console[n];u||"debug"!==n||(u=o.a.console.info||o.a.console.log),u&&a&&s.test(n)&&u[Array.isArray(i)?"apply":"call"](o.a.console,i)}}}(t,i),i.createLogger=function(n){return e(t+": "+n)},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 jt?[].concat(jt):[]}).filter=function(e){return(jt||[]).filter((function(t){return new RegExp(".*"+e+".*").test(t[0])}))},i.history.clear=function(){jt&&(jt.length=0)},i.history.disable=function(){null!==jt&&(jt.length=0,jt=null)},i.history.enable=function(){null===jt&&(jt=[])},i.error=function(){for(var e=arguments.length,t=new Array(e),i=0;i1?t-1:0),r=1;r=0)throw new Error("class has illegal whitespace characters")}function gn(){return s.a===o.a.document}function vn(e){return Vt(e)&&1===e.nodeType}function bn(){try{return o.a.parent!==o.a.self}catch(e){return!0}}function yn(e){return function(t,n){if(!pn(t))return s.a[e](null);pn(n)&&(n=s.a.querySelector(n));var r=vn(n)?n:s.a;return r[e]&&r[e](t)}}function wn(e,t,n,r){void 0===e&&(e="div"),void 0===t&&(t={}),void 0===n&&(n={});var i=s.a.createElement(e);return Object.getOwnPropertyNames(t).forEach((function(e){var n=t[e];-1!==e.indexOf("aria-")||"role"===e||"type"===e?(Lt.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 "+n+"."),i.setAttribute(e,n)):"textContent"===e?Sn(i,n):i[e]===n&&"tabIndex"!==e||(i[e]=n)})),Object.getOwnPropertyNames(n).forEach((function(e){i.setAttribute(e,n[e])})),r&&Fn(i,r),i}function Sn(e,t){return"undefined"===typeof e.textContent?e.innerText=t:e.textContent=t,e}function _n(e,t){t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}function kn(e,t){return mn(t),e.classList?e.classList.contains(t):(n=t,new RegExp("(^|\\s)"+n+"($|\\s)")).test(e.className);var n}function xn(e,t){return e.classList?e.classList.add(t):kn(e,t)||(e.className=(e.className+" "+t).trim()),e}function En(e,t){return e?(e.classList?e.classList.remove(t):(mn(t),e.className=e.className.split(/\s+/).filter((function(e){return e!==t})).join(" ")),e):(Lt.warn("removeClass was called with an element that doesn't exist"),null)}function On(e,t,n){var r=kn(e,t);if("function"===typeof n&&(n=n(e,t)),"boolean"!==typeof n&&(n=!r),n!==r)return n?xn(e,t):En(e,t),e}function Mn(e,t){Object.getOwnPropertyNames(t).forEach((function(n){var r=t[n];null===r||"undefined"===typeof r||!1===r?e.removeAttribute(n):e.setAttribute(n,!0===r?"":r)}))}function Cn(e){var t={},n=",autoplay,controls,playsinline,loop,muted,default,defaultMuted,";if(e&&e.attributes&&e.attributes.length>0)for(var r=e.attributes,i=r.length-1;i>=0;i--){var o=r[i].name,a=r[i].value;"boolean"!==typeof e[o]&&-1===n.indexOf(","+o+",")||(a=null!==a),t[o]=a}return t}function Tn(e,t){return e.getAttribute(t)}function An(e,t,n){e.setAttribute(t,n)}function In(e,t){e.removeAttribute(t)}function Pn(){s.a.body.focus(),s.a.onselectstart=function(){return!1}}function Rn(){s.a.onselectstart=function(){return!0}}function Dn(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(Ht(e,"height"))),n.width||(n.width=parseFloat(Ht(e,"width"))),n}}function Nn(e){if(!e||e&&!e.offsetParent)return{left:0,top:0,width:0,height:0};for(var t=e.offsetWidth,n=e.offsetHeight,r=0,i=0;e.offsetParent&&e!==s.a[It.fullscreenElement];)r+=e.offsetLeft,i+=e.offsetTop,e=e.offsetParent;return{left:r,top:i,width:t,height:n}}function jn(e,t){var n={x:0,y:0};if(dn)for(var r=e;r&&"html"!==r.nodeName.toLowerCase();){var i=Ht(r,"transform");if(/^matrix/.test(i)){var o=i.slice(7,-1).split(/,\s/).map(Number);n.x+=o[4],n.y+=o[5]}else if(/^matrix3d/.test(i)){var a=i.slice(9,-1).split(/,\s/).map(Number);n.x+=a[12],n.y+=a[13]}r=r.parentNode}var s={},c=Nn(t.target),u=Nn(e),l=u.width,d=u.height,f=t.offsetY-(u.top-c.top),h=t.offsetX-(u.left-c.left);return t.changedTouches&&(h=t.changedTouches[0].pageX-u.left,f=t.changedTouches[0].pageY+u.top,dn&&(h-=n.x,f-=n.y)),s.y=1-Math.max(0,Math.min(1,f/d)),s.x=Math.max(0,Math.min(1,h/l)),s}function Ln(e){return Vt(e)&&3===e.nodeType}function Bn(e){for(;e.firstChild;)e.removeChild(e.firstChild);return e}function zn(e){return"function"===typeof e&&(e=e()),(Array.isArray(e)?e:[e]).map((function(e){return"function"===typeof e&&(e=e()),vn(e)||Ln(e)?e:"string"===typeof e&&/\S/.test(e)?s.a.createTextNode(e):void 0})).filter((function(e){return e}))}function Fn(e,t){return zn(t).forEach((function(t){return e.appendChild(t)})),e}function Un(e,t){return Fn(Bn(e),t)}function qn(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))}var Vn,Wn=yn("querySelector"),Hn=yn("querySelectorAll"),Kn=Object.freeze({__proto__:null,isReal:gn,isEl:vn,isInFrame:bn,createEl:wn,textContent:Sn,prependTo:_n,hasClass:kn,addClass:xn,removeClass:En,toggleClass:On,setAttributes:Mn,getAttributes:Cn,getAttribute:Tn,setAttribute:An,removeAttribute:In,blockTextSelection:Pn,unblockTextSelection:Rn,getBoundingClientRect:Dn,findPosition:Nn,getPointerPosition:jn,isTextNode:Ln,emptyEl:Bn,normalizeContent:zn,appendContent:Fn,insertContent:Un,isSingleLeftClick:qn,$:Wn,$$:Hn}),Zn=!1,Gn=function(){if(!1!==Vn.options.autoSetup){var e=Array.prototype.slice.call(s.a.getElementsByTagName("video")),t=Array.prototype.slice.call(s.a.getElementsByTagName("audio")),n=Array.prototype.slice.call(s.a.getElementsByTagName("video-js")),r=e.concat(t,n);if(r&&r.length>0)for(var i=0,o=r.length;i-1&&(i={passive:!0}),e.addEventListener(t,r.dispatcher,i)}else e.attachEvent&&e.attachEvent("on"+t,r.dispatcher)}function ur(e,t,n){if(rr.has(e)){var r=rr.get(e);if(r.handlers){if(Array.isArray(t))return or(ur,e,t,n);var i=function(e,t){r.handlers[t]=[],ir(e,t)};if(void 0!==t){var o=r.handlers[t];if(o)if(n){if(n.guid)for(var a=0;a=t&&(e.apply(void 0,arguments),n=r)}},vr=function(){};vr.prototype.allowedEvents_={},vr.prototype.on=function(e,t){var n=this.addEventListener;this.addEventListener=function(){},cr(this,e,t),this.addEventListener=n},vr.prototype.addEventListener=vr.prototype.on,vr.prototype.off=function(e,t){ur(this,e,t)},vr.prototype.removeEventListener=vr.prototype.off,vr.prototype.one=function(e,t){var n=this.addEventListener;this.addEventListener=function(){},dr(this,e,t),this.addEventListener=n},vr.prototype.any=function(e,t){var n=this.addEventListener;this.addEventListener=function(){},fr(this,e,t),this.addEventListener=n},vr.prototype.trigger=function(e){var t=e.type||e;"string"===typeof e&&(e={type:t}),e=ar(e),this.allowedEvents_[t]&&this["on"+t]&&this["on"+t](e),lr(this,e)},vr.prototype.dispatchEvent=vr.prototype.trigger,vr.prototype.queueTrigger=function(e){var t=this;hr||(hr=new Map);var n=e.type||e,r=hr.get(this);r||(r=new Map,hr.set(this,r));var i=r.get(n);r.delete(n),o.a.clearTimeout(i);var a=o.a.setTimeout((function(){0===r.size&&(r=null,hr.delete(t)),t.trigger(e)}),0);r.set(n,a)};var br=function(e){return"function"===typeof e.name?e.name():"string"===typeof e.name?e.name:e.name_?e.name_:e.constructor&&e.constructor.name?e.constructor.name:typeof e},yr=function(e){return e instanceof vr||!!e.eventBusEl_&&["on","one","off","trigger"].every((function(t){return"function"===typeof e[t]}))},wr=function(e){return"string"===typeof e&&/\S/.test(e)||Array.isArray(e)&&!!e.length},Sr=function(e,t,n){if(!e||!e.nodeName&&!yr(e))throw new Error("Invalid target for "+br(t)+"#"+n+"; must be a DOM node or evented object.")},_r=function(e,t,n){if(!wr(e))throw new Error("Invalid event type for "+br(t)+"#"+n+"; must be a non-empty string or array.")},kr=function(e,t,n){if("function"!==typeof e)throw new Error("Invalid listener for "+br(t)+"#"+n+"; must be a function.")},xr=function(e,t,n){var r,i,o,a=t.length<3||t[0]===e||t[0]===e.eventBusEl_;return a?(r=e.eventBusEl_,t.length>=3&&t.shift(),i=t[0],o=t[1]):(r=t[0],i=t[1],o=t[2]),Sr(r,e,n),_r(i,e,n),kr(o,e,n),{isTargetingSelf:a,target:r,type:i,listener:o=mr(e,o)}},Er=function(e,t,n,r){Sr(e,e,t),e.nodeName?pr[t](e,n,r):e[t](n,r)},Or={on:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r=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_),this.el_=null),this.player_=null}},t.isDisposed=function(){return Boolean(this.isDisposed_)},t.player=function(){return this.player_},t.options=function(e){return e?(this.options_=Pr(this.options_,e),this.options_):this.options_},t.el=function(){return this.el_},t.createEl=function(e,t,n){return wn(e,t,n)},t.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(),o=i&&i[r],a=r&&r.split("-")[0],s=i&&i[a],c=n;return o&&o[e]?c=o[e]:s&&s[e]&&(c=s[e]),t&&(c=c.replace(/\{(\d+)\}/g,(function(e,n){var r=t[n-1],i=r;return"undefined"===typeof r&&(i=e),i}))),c},t.handleLanguagechange=function(){},t.contentEl=function(){return this.contentEl_||this.el_},t.id=function(){return this.id_},t.name=function(){return this.name_},t.children=function(){return this.children_},t.getChildById=function(e){return this.childIndex_[e]},t.getChild=function(e){if(e)return this.childNameIndex_[e]},t.getDescendant=function(){for(var e=arguments.length,t=new Array(e),n=0;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_[Ir(e.name())]=null,this.childNameIndex_[Ar(e.name())]=null;var r=e.el();r&&r.parentNode===this.contentEl()&&this.contentEl().removeChild(e.el())}}},t.initChildren=function(){var t=this,n=this.options_.children;if(n){var r,i=this.options_,o=e.getComponent("Tech");(r=Array.isArray(n)?n:Object.keys(n)).concat(Object.keys(this.options_).filter((function(e){return!r.some((function(t){return"string"===typeof t?e===t:e===t.name}))}))).map((function(e){var r,i;return"string"===typeof e?i=n[r=e]||t.options_[r]||{}:(r=e.name,i=e),{name:r,opts:i}})).filter((function(t){var n=e.getComponent(t.opts.componentClass||Ir(t.name));return n&&!o.isTech(n)})).forEach((function(e){var n=e.name,r=e.opts;if(void 0!==i[n]&&(r=i[n]),!1!==r){!0===r&&(r={}),r.playerOptions=t.options_.playerOptions;var o=t.addChild(n,r);o&&(t[n]=o)}}))}},t.buildCSSClass=function(){return""},t.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))},t.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)},t.$=function(e,t){return Wn(e,t||this.contentEl())},t.$$=function(e,t){return Hn(e,t||this.contentEl())},t.hasClass=function(e){return kn(this.el_,e)},t.addClass=function(e){xn(this.el_,e)},t.removeClass=function(e){En(this.el_,e)},t.toggleClass=function(e,t){On(this.el_,e,t)},t.show=function(){this.removeClass("vjs-hidden")},t.hide=function(){this.addClass("vjs-hidden")},t.lockShowing=function(){this.addClass("vjs-lock-showing")},t.unlockShowing=function(){this.removeClass("vjs-lock-showing")},t.getAttribute=function(e){return Tn(this.el_,e)},t.setAttribute=function(e,t){An(this.el_,e,t)},t.removeAttribute=function(e){In(this.el_,e)},t.width=function(e,t){return this.dimension("width",e,t)},t.height=function(e,t){return this.dimension("height",e,t)},t.dimensions=function(e,t){this.width(e,!0),this.height(t)},t.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"+Ir(e)],10)},t.currentDimension=function(e){var t=0;if("width"!==e&&"height"!==e)throw new Error("currentDimension only accepts width or height value");if(t=Ht(this.el_,e),0===(t=parseFloat(t))||isNaN(t)){var n="offset"+Ir(e);t=this.el_[n]}return t},t.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},t.currentWidth=function(){return this.currentDimension("width")},t.currentHeight=function(){return this.currentDimension("height")},t.focus=function(){this.el_.focus()},t.blur=function(){this.el_.blur()},t.handleKeyDown=function(e){this.player_&&(e.stopPropagation(),this.player_.handleKeyDown(e))},t.handleKeyPress=function(e){this.handleKeyDown(e)},t.emitTapEvents=function(){var e,t=0,n=null;this.on("touchstart",(function(r){1===r.touches.length&&(n={pageX:r.touches[0].pageX,pageY:r.touches[0].pageY},t=o.a.performance.now(),e=!0)})),this.on("touchmove",(function(t){if(t.touches.length>1)e=!1;else if(n){var r=t.touches[0].pageX-n.pageX,i=t.touches[0].pageY-n.pageY;Math.sqrt(r*r+i*i)>10&&(e=!1)}}));var r=function(){e=!1};this.on("touchleave",r),this.on("touchcancel",r),this.on("touchend",(function(r){(n=null,!0===e)&&(o.a.performance.now()-t<200&&(r.preventDefault(),this.trigger("tap")))}))},t.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var e,t=mr(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)}},t.setTimeout=function(e,t){var n,r=this;return e=mr(this,e),this.clearTimersOnDispose_(),n=o.a.setTimeout((function(){r.setTimeoutIds_.has(n)&&r.setTimeoutIds_.delete(n),e()}),t),this.setTimeoutIds_.add(n),n},t.clearTimeout=function(e){return this.setTimeoutIds_.has(e)&&(this.setTimeoutIds_.delete(e),o.a.clearTimeout(e)),e},t.setInterval=function(e,t){e=mr(this,e),this.clearTimersOnDispose_();var n=o.a.setInterval(e,t);return this.setIntervalIds_.add(n),n},t.clearInterval=function(e){return this.setIntervalIds_.has(e)&&(this.setIntervalIds_.delete(e),o.a.clearInterval(e)),e},t.requestAnimationFrame=function(e){var t,n=this;return this.supportsRaf_?(this.clearTimersOnDispose_(),e=mr(this,e),t=o.a.requestAnimationFrame((function(){n.rafIds_.has(t)&&n.rafIds_.delete(t),e()})),this.rafIds_.add(t),t):this.setTimeout(e,1e3/60)},t.requestNamedAnimationFrame=function(e,t){var n=this;if(!this.namedRafs_.has(e)){this.clearTimersOnDispose_(),t=mr(this,t);var r=this.requestAnimationFrame((function(){t(),n.namedRafs_.has(e)&&n.namedRafs_.delete(e)}));return this.namedRafs_.set(e,r),e}},t.cancelNamedAnimationFrame=function(e){this.namedRafs_.has(e)&&(this.cancelAnimationFrame(this.namedRafs_.get(e)),this.namedRafs_.delete(e))},t.cancelAnimationFrame=function(e){return this.supportsRaf_?(this.rafIds_.has(e)&&(this.rafIds_.delete(e),o.a.cancelAnimationFrame(e)),e):this.clearTimeout(e)},t.clearTimersOnDispose_=function(){var e=this;this.clearingTimersOnDispose_||(this.clearingTimersOnDispose_=!0,this.one("dispose",(function(){[["namedRafs_","cancelNamedAnimationFrame"],["rafIds_","cancelAnimationFrame"],["setTimeoutIds_","clearTimeout"],["setIntervalIds_","clearInterval"]].forEach((function(t){var n=t[0],r=t[1];e[n].forEach((function(t,n){return e[r](n)}))})),e.clearingTimersOnDispose_=!1})))},e.registerComponent=function(t,n){if("string"!==typeof t||!t)throw new Error('Illegal component name, "'+t+'"; must be a non-empty string.');var r,i=e.getComponent("Tech"),o=i&&i.isTech(n),a=e===n||e.prototype.isPrototypeOf(n.prototype);if(o||!a)throw r=o?"techs must be registered using Tech.registerTech()":"must be a Component subclass",new Error('Illegal component, "'+t+'"; '+r+".");t=Ir(t),e.components_||(e.components_={});var s=e.getComponent("Player");if("Player"===t&&s&&s.players){var c=s.players,u=Object.keys(c);if(c&&u.length>0&&u.map((function(e){return c[e]})).every(Boolean))throw new Error("Can not register Player component after player has been created.")}return e.components_[t]=n,e.components_[Ar(t)]=n,n},e.getComponent=function(t){if(t&&e.components_)return e.components_[t]},e}();function Br(e,t,n,r){return function(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+").")}(e,r,n.length-1),n[r][t]}function zr(e){var t;return t=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:Br.bind(null,"start",0,e),end:Br.bind(null,"end",1,e)},o.a.Symbol&&o.a.Symbol.iterator&&(t[o.a.Symbol.iterator]=function(){return(e||[]).values()}),t}function Fr(e,t){return Array.isArray(e)?zr(e):void 0===e||void 0===t?zr():zr([[e,t]])}function Ur(e,t){var n,r,i=0;if(!t)return 0;e&&e.length||(e=Fr(0,0));for(var o=0;ot&&(r=t),i+=r-n;return i/t}function qr(e){if(e instanceof qr)return e;"number"===typeof e?this.code=e:"string"===typeof e?this.message=e:Vt(e)&&("number"===typeof e.code&&(this.code=e.code),qt(this,e)),this.message||(this.message=qr.defaultMessages[this.code]||"")}Lr.prototype.supportsRaf_="function"===typeof o.a.requestAnimationFrame&&"function"===typeof o.a.cancelAnimationFrame,Lr.registerComponent("Component",Lr),qr.prototype.code=0,qr.prototype.message="",qr.prototype.status=null,qr.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],qr.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 Vr=0;Vr=0;r--)if(t[r].enabled){Jr(t,t[r]);break}return(n=e.call(this,t)||this).changing_=!1,n}h()(t,e);var n=t.prototype;return n.addTrack=function(t){var n=this;t.enabled&&Jr(this,t),e.prototype.addTrack.call(this,t),t.addEventListener&&(t.enabledChange_=function(){n.changing_||(n.changing_=!0,Jr(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}(Yr),ei=function(e,t){for(var n=0;n=0;r--)if(t[r].selected){ei(t,t[r]);break}return(n=e.call(this,t)||this).changing_=!1,Object.defineProperty(d()(n),"selectedIndex",{get:function(){for(var e=0;e0&&(o.a.console&&o.a.console.groupCollapsed&&o.a.console.groupCollapsed("Text Track parsing errors for "+t.src),r.forEach((function(e){return Lt.error(e)})),o.a.console&&o.a.console.groupEnd&&o.a.console.groupEnd()),n.flush()},gi=function(e,t){var n={uri:e},r=hi(e);r&&(n.cors=r);var i="use-credentials"===t.tech_.crossOrigin();i&&(n.withCredentials=i),y()(n,mr(this,(function(e,n,r){if(e)return Lt.error(e,n);t.loaded_=!0,"function"!==typeof o.a.WebVTT?t.tech_&&t.tech_.any(["vttjsloaded","vttjserror"],(function(e){if("vttjserror"!==e.type)return mi(r,t);Lt.error("vttjs failed to load, stopping trying to process "+t.src)})):mi(r,t)})))},vi=function(e){function t(t){var n;if(void 0===t&&(t={}),!t.tech)throw new Error("A tech was not provided.");var r=Pr(t,{kind:si[t.kind]||"subtitles",language:t.language||t.srclang||""}),i=ci[r.mode]||"disabled",o=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(i="hidden"),(n=e.call(this,r)||this).tech_=r.tech,n.cues_=[],n.activeCues_=[],n.preload_=!1!==n.tech_.preloadTextTracks;var a=new ii(n.cues_),s=new ii(n.activeCues_),c=!1,u=mr(d()(n),(function(){this.tech_.isReady_&&!this.tech_.isDisposed()&&(this.activeCues=this.activeCues,c&&(this.trigger("cuechange"),c=!1))}));return n.tech_.one("dispose",(function(){n.tech_.off("timeupdate",u)})),"disabled"!==i&&n.tech_.on("timeupdate",u),Object.defineProperties(d()(n),{default:{get:function(){return o},set:function(){}},mode:{get:function(){return i},set:function(e){ci[e]&&i!==e&&(i=e,this.preload_||"disabled"===i||0!==this.cues.length||gi(this.src,this),this.tech_.off("timeupdate",u),"disabled"!==i&&this.tech_.on("timeupdate",u),this.trigger("modechange"))}},cues:{get:function(){return this.loaded_?a: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=e||i.startTime===i.endTime&&i.startTime<=e&&i.startTime+.5>=e)&&t.push(i)}if(c=!1,t.length!==this.activeCues_.length)c=!0;else for(var o=0;o0)return void this.trigger("vttjsloaded");var t=s.a.createElement("script");t.src=this.options_["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.14.1/vtt.min.js",t.onload=function(){e.trigger("vttjsloaded")},t.onerror=function(){e.trigger("vttjserror")},this.on("dispose",(function(){t.onload=null,t.onerror=null})),o.a.WebVTT=!0,this.el().parentNode.appendChild(t)}else this.ready(this.addWebVttScript_)},n.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 o=function(){return e.trigger("texttrackchange")},a=function(){o();for(var e=0;e=0;i--){var o=e[i];o[t]&&o[t](r,n)}}(e,n,s,a),s}var Ai={buffered:1,currentTime:1,duration:1,muted:1,played:1,paused:1,seekable:1,volume:1,ended:1},Ii={setCurrentTime:1,setMuted:1,setVolume:1},Pi={play:1,pause:1};function Ri(e){return function(t,n){return t===Mi?Mi:n[e]?n[e](t):t}}var Di={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",caf:"audio/x-caf",flac:"audio/flac",oga:"audio/ogg",wav:"audio/wav",m3u8:"application/x-mpegURL",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",png:"image/png",svg:"image/svg+xml",webp:"image/webp"},Ni=function(e){void 0===e&&(e="");var t=fi(e);return Di[t.toLowerCase()]||""};function ji(e){if(!e.type){var t=Ni(e.src);t&&(e.type=t)}return e}var Li=function(e){function t(t,n,r){var i,o=Pr({createEl:!1},n);if(i=e.call(this,t,o,r)||this,n.playerOptions.sources&&0!==n.playerOptions.sources.length)t.src(n.playerOptions.sources);else for(var a=0,s=n.playerOptions.techOrder;a0;!this.player_.tech(!0)||(on||tn)&&t||this.player_.tech(!0).focus(),this.player_.paused()?Hr(this.player_.play()):this.player_.pause()}},t}(Bi);Lr.registerComponent("PosterImage",zi);var Fi={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function Ui(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 qi(e,t,n){try{e.style[t]=n}catch(r){return}}var Vi=function(e){function t(t,n,r){var i;i=e.call(this,t,n,r)||this;var a=function(e){return i.updateDisplay(e)};return t.on("loadstart",(function(e){return i.toggleDisplay(e)})),t.on("texttrackchange",a),t.on("loadedmetadata",(function(e){return i.preselectTrack(e)})),t.ready(mr(d()(i),(function(){if(t.tech_&&t.tech_.featuresNativeTextTracks)this.hide();else{t.on("fullscreenchange",a),t.on("playerresize",a),o.a.addEventListener("orientationchange",a),t.on("dispose",(function(){return o.a.removeEventListener("orientationchange",a)}));for(var e=this.options_.playerOptions.tracks||[],n=0;n0;return Hr(t),void(!this.player_.tech(!0)||(on||tn)&&n||this.player_.tech(!0).focus())}var r=this.player_.getChild("controlBar"),i=r&&r.getChild("playToggle");if(i){var o=function(){return i.focus()};Wr(t)?t.then(o,(function(){})):this.setTimeout(o,1)}else this.player_.tech(!0).focus()},n.handleKeyDown=function(t){this.mouseused_=!1,e.prototype.handleKeyDown.call(this,t)},n.handleMouseDown=function(e){this.mouseused_=!0},t}(Hi);Ki.prototype.controlText_="Play Video",Lr.registerComponent("BigPlayButton",Ki);var Zi=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).controlText(n&&n.controlText||r.localize("Close")),r}h()(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){v.a.isEventKey(t,"Esc")?(t.preventDefault(),t.stopPropagation(),this.trigger("click")):e.prototype.handleKeyDown.call(this,t)},t}(Hi);Lr.registerComponent("CloseButton",Zi);var Gi=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",(function(e){return r.handlePlay(e)})),r.on(t,"pause",(function(e){return r.handlePause(e)})),n.replay&&r.on(t,"ended",(function(e){return r.handleEnded(e)})),r}h()(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()?Hr(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){var t=this;this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.controlText("Replay"),this.one(this.player_,"seeked",(function(e){return t.handleSeeked(e)}))},t}(Hi);Gi.prototype.controlText_="Play",Lr.registerComponent("PlayToggle",Gi);var Xi=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),o=Math.floor(t/60%60),a=Math.floor(t/3600);return(isNaN(e)||e===1/0)&&(i=r=n="-"),(i=i>0||a>0?i+":":"")+(r=((i||o>=10)&&r<10?"0"+r:r)+":")+(n=n<10?"0"+n:n)},Yi=Xi;function $i(e,t){return void 0===t&&(t=e),Yi(e,t)}var Ji=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).on(t,["timeupdate","ended"],(function(e){return r.updateContent(e)})),r.updateTextNode_(),r}h()(t,e);var n=t.prototype;return n.createEl=function(){var t=this.buildCSSClass(),n=e.prototype.createEl.call(this,"div",{className:t+" vjs-time-control vjs-control"}),r=wn("span",{className:"vjs-control-text",textContent:this.localize(this.labelText_)+"\xa0"},{role:"presentation"});return n.appendChild(r),this.contentEl_=wn("span",{className:t+"-display"},{"aria-live":"off",role:"presentation"}),n.appendChild(this.contentEl_),n},n.dispose=function(){this.contentEl_=null,this.textNode_=null,e.prototype.dispose.call(this)},n.updateTextNode_=function(e){var t=this;void 0===e&&(e=0),e=$i(e),this.formattedTime_!==e&&(this.formattedTime_=e,this.requestNamedAnimationFrame("TimeDisplay#updateTextNode_",(function(){if(t.contentEl_){var e=t.textNode_;e&&t.contentEl_.firstChild!==e&&(e=null,Lt.warn("TimeDisplay#updateTextnode_: Prevented replacement of text node element since it was no longer a child of this node. Appending a new node instead.")),t.textNode_=s.a.createTextNode(t.formattedTime_),t.textNode_&&(e?t.contentEl_.replaceChild(t.textNode_,e):t.contentEl_.appendChild(t.textNode_))}})))},n.updateContent=function(e){},t}(Lr);Ji.prototype.labelText_="Time",Ji.prototype.controlText_="Time",Lr.registerComponent("TimeDisplay",Ji);var Qi=function(e){function t(){return e.apply(this,arguments)||this}h()(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-current-time"},n.updateContent=function(e){var t;t=this.player_.ended()?this.player_.duration():this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime(),this.updateTextNode_(t)},t}(Ji);Qi.prototype.labelText_="Current Time",Qi.prototype.controlText_="Current Time",Lr.registerComponent("CurrentTimeDisplay",Qi);var eo=function(e){function t(t,n){var r,i=function(e){return r.updateContent(e)};return(r=e.call(this,t,n)||this).on(t,"durationchange",i),r.on(t,"loadstart",i),r.on(t,"loadedmetadata",i),r}h()(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-duration"},n.updateContent=function(e){var t=this.player_.duration();this.updateTextNode_(t)},t}(Ji);eo.prototype.labelText_="Duration",eo.prototype.controlText_="Duration",Lr.registerComponent("DurationDisplay",eo);var to=function(e){function t(){return e.apply(this,arguments)||this}return h()(t,e),t.prototype.createEl=function(){var t=e.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider"},{"aria-hidden":!0}),n=e.prototype.createEl.call(this,"div"),r=e.prototype.createEl.call(this,"span",{textContent:"/"});return n.appendChild(r),t.appendChild(n),t},t}(Lr);Lr.registerComponent("TimeDivider",to);var no=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).on(t,"durationchange",(function(e){return r.updateContent(e)})),r}h()(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(wn("span",{},{"aria-hidden":!0},"-"),this.contentEl_),t},n.updateContent=function(e){var t;"number"===typeof this.player_.duration()&&(t=this.player_.ended()?0:this.player_.remainingTimeDisplay?this.player_.remainingTimeDisplay():this.player_.remainingTime(),this.updateTextNode_(t))},t}(Ji);no.prototype.labelText_="Remaining Time",no.prototype.controlText_="Remaining Time",Lr.registerComponent("RemainingTimeDisplay",no);var ro=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).updateShowing(),r.on(r.player(),"durationchange",(function(e){return r.updateShowing(e)})),r}h()(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_=wn("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.contentEl_.appendChild(wn("span",{className:"vjs-control-text",textContent:this.localize("Stream Type")+"\xa0"})),this.contentEl_.appendChild(s.a.createTextNode(this.localize("LIVE"))),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}(Lr);Lr.registerComponent("LiveDisplay",ro);var io=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).updateLiveEdgeStatus(),r.player_.liveTracker&&(r.updateLiveEdgeStatusHandler_=function(e){return r.updateLiveEdgeStatus(e)},r.on(r.player_.liveTracker,"liveedgechange",r.updateLiveEdgeStatusHandler_)),r}h()(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_=wn("span",{className:"vjs-seek-to-live-text",textContent:this.localize("LIVE")},{"aria-hidden":"true"}),t.appendChild(this.textEl_),t},n.updateLiveEdgeStatus=function(){!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.updateLiveEdgeStatusHandler_),this.textEl_=null,e.prototype.dispose.call(this)},t}(Hi);io.prototype.controlText_="Seek to live, currently playing live",Lr.registerComponent("SeekToLive",io);var oo=function(e,t,n){return e=Number(e),Math.min(n,Math.max(t,isNaN(e)?t:e))},ao=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).handleMouseDown_=function(e){return r.handleMouseDown(e)},r.handleMouseUp_=function(e){return r.handleMouseUp(e)},r.handleKeyDown_=function(e){return r.handleKeyDown(e)},r.handleClick_=function(e){return r.handleClick(e)},r.handleMouseMove_=function(e){return r.handleMouseMove(e)},r.update_=function(e){return r.update(e)},r.bar=r.getChild(r.options_.barName),r.vertical(!!r.options_.vertical),r.enable(),r}h()(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=qt({tabIndex:0},n),r=qt({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||nn||e.preventDefault(),Pn(),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;Rn(),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(){var e=this;if(this.el_&&this.bar){var t=this.getProgress();return t===this.progress_||(this.progress_=t,this.requestNamedAnimationFrame("Slider#update",(function(){var n=e.vertical()?"height":"width";e.bar.el().style[n]=(100*t).toFixed(2)+"%"}))),t}},n.getProgress=function(){return Number(oo(this.getPercent(),0,1).toFixed(4))},n.calculateDistance=function(e){var t=jn(this.el_,e);return this.vertical()?t.y:t.x},n.handleKeyDown=function(t){v.a.isEventKey(t,"Left")||v.a.isEventKey(t,"Down")?(t.preventDefault(),t.stopPropagation(),this.stepBack()):v.a.isEventKey(t,"Right")||v.a.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}(Lr);Lr.registerComponent("Slider",ao);var so=function(e,t){return oo(e/t*100,0,100).toFixed(2)+"%"},co=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).partEls_=[],r.on(t,"progress",(function(e){return r.update(e)})),r}h()(t,e);var n=t.prototype;return n.createEl=function(){var t=e.prototype.createEl.call(this,"div",{className:"vjs-load-progress"}),n=wn("span",{className:"vjs-control-text"}),r=wn("span",{textContent:this.localize("Loaded")}),i=s.a.createTextNode(": ");return this.percentageEl_=wn("span",{className:"vjs-control-text-loaded-percentage",textContent:"0%"}),t.appendChild(n),n.appendChild(r),n.appendChild(i),n.appendChild(this.percentageEl_),t},n.dispose=function(){this.partEls_=null,this.percentageEl_=null,e.prototype.dispose.call(this)},n.update=function(e){var t=this;this.requestNamedAnimationFrame("LoadProgressBar#update",(function(){var e=t.player_.liveTracker,n=t.player_.buffered(),r=e&&e.isLive()?e.seekableEnd():t.player_.duration(),i=t.player_.bufferedEnd(),o=t.partEls_,a=so(i,r);t.percent_!==a&&(t.el_.style.width=a,Sn(t.percentageEl_,a),t.percent_=a);for(var s=0;sn.length;d--)t.el_.removeChild(o[d-1]);o.length=n.length}))},t}(Lr);Lr.registerComponent("LoadProgressBar",co);var uo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).update=gr(mr(d()(r),r.update),30),r}h()(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=Nn(this.el_),i=Dn(this.player_.el()),o=e.width*t;if(i&&r){var a=e.left-i.left+o,s=e.width-o+(i.right-e.right),c=r.width/2;ar.width&&(c=r.width),c=Math.round(c),this.el_.style.right="-"+c+"px",this.write(n)}},n.write=function(e){Sn(this.el_,e)},n.updateTime=function(e,t,n,r){var i=this;this.requestNamedAnimationFrame("TimeTooltip#updateTime",(function(){var o,a=i.player_.duration();if(i.player_.liveTracker&&i.player_.liveTracker.isLive()){var s=i.player_.liveTracker.liveWindow(),c=s-t*s;o=(c<1?"":"-")+$i(c,s)}else o=$i(n,a);i.update(e,t,o),r&&r()}))},t}(Lr);Lr.registerComponent("TimeTooltip",uo);var lo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).update=gr(mr(d()(r),r.update),30),r}h()(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}(Lr);lo.prototype.options_={children:[]},dn||$t||lo.prototype.options_.children.push("timeTooltip"),Lr.registerComponent("PlayProgressBar",lo);var fo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).update=gr(mr(d()(r),r.update),30),r}h()(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}(Lr);fo.prototype.options_={children:["timeTooltip"]},Lr.registerComponent("MouseTimeDisplay",fo);var ho=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).setEventHandlers_(),r}h()(t,e);var n=t.prototype;return n.setEventHandlers_=function(){var e=this;this.update_=mr(this,this.update),this.update=gr(this.update_,30),this.on(this.player_,["ended","durationchange","timeupdate"],this.update),this.player_.liveTracker&&this.on(this.player_.liveTracker,"liveedgechange",this.update),this.updateInterval=null,this.enableIntervalHandler_=function(t){return e.enableInterval_(t)},this.disableIntervalHandler_=function(t){return e.disableInterval_(t)},this.on(this.player_,["playing"],this.enableIntervalHandler_),this.on(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in s.a&&"visibilityState"in s.a&&this.on(s.a,"visibilitychange",this.toggleVisibility_)},n.toggleVisibility_=function(e){"hidden"===s.a.visibilityState?(this.cancelNamedAnimationFrame("SeekBar#update"),this.cancelNamedAnimationFrame("Slider#update"),this.disableInterval_(e)):(this.player_.ended()||this.player_.paused()||this.enableInterval_(),this.update())},n.enableInterval_=function(){this.updateInterval||(this.updateInterval=this.setInterval(this.update,30))},n.disableInterval_=function(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&e&&"ended"!==e.type||this.updateInterval&&(this.clearInterval(this.updateInterval),this.updateInterval=null)},n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})},n.update=function(t){var n=this;if("hidden"!==s.a.visibilityState){var r=e.prototype.update.call(this);return this.requestNamedAnimationFrame("SeekBar#update",(function(){var e=n.player_.ended()?n.player_.duration():n.getCurrentTime_(),t=n.player_.liveTracker,i=n.player_.duration();t&&t.isLive()&&(i=n.player_.liveTracker.liveCurrentTime()),n.percent_!==r&&(n.el_.setAttribute("aria-valuenow",(100*r).toFixed(2)),n.percent_=r),n.currentTime_===e&&n.duration_===i||(n.el_.setAttribute("aria-valuetext",n.localize("progress bar timing: currentTime={1} duration={2}",[$i(e,i),$i(i,i)],"{1} of {2}")),n.currentTime_=e,n.duration_=i),n.bar&&n.bar.update(Dn(n.el()),n.getProgress())})),r}},n.userSeek_=function(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&this.player_.liveTracker.nextSeekedFromUser(),this.player_.currentTime(e)},n.getCurrentTime_=function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()},n.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},n.handleMouseDown=function(t){qn(t)&&(t.stopPropagation(),this.player_.scrubbing(!0),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),e.prototype.handleMouseDown.call(this,t))},n.handleMouseMove=function(e){if(qn(e)){var t,n=this.calculateDistance(e),r=this.player_.liveTracker;if(r&&r.isLive()){if(n>=.99)return void r.seekToLiveEdge();var i=r.seekableStart(),o=r.liveCurrentTime();if((t=i+n*r.liveWindow())>=o&&(t=o),t<=i&&(t=i+.1),t===1/0)return}else(t=n*this.player_.duration())===this.player_.duration()&&(t-=.1);this.userSeek_(t)}},n.enable=function(){e.prototype.enable.call(this);var t=this.getChild("mouseTimeDisplay");t&&t.show()},n.disable=function(){e.prototype.disable.call(this);var t=this.getChild("mouseTimeDisplay");t&&t.hide()},n.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?Hr(this.player_.play()):this.update_()},n.stepForward=function(){this.userSeek_(this.player_.currentTime()+5)},n.stepBack=function(){this.userSeek_(this.player_.currentTime()-5)},n.handleAction=function(e){this.player_.paused()?this.player_.play():this.player_.pause()},n.handleKeyDown=function(t){var n=this.player_.liveTracker;if(v.a.isEventKey(t,"Space")||v.a.isEventKey(t,"Enter"))t.preventDefault(),t.stopPropagation(),this.handleAction(t);else if(v.a.isEventKey(t,"Home"))t.preventDefault(),t.stopPropagation(),this.userSeek_(0);else if(v.a.isEventKey(t,"End"))t.preventDefault(),t.stopPropagation(),n&&n.isLive()?this.userSeek_(n.liveCurrentTime()):this.userSeek_(this.player_.duration());else if(/^[0-9]$/.test(v()(t))){t.preventDefault(),t.stopPropagation();var r=10*(v.a.codes[v()(t)]-v.a.codes[0])/100;n&&n.isLive()?this.userSeek_(n.seekableStart()+n.liveWindow()*r):this.userSeek_(this.player_.duration()*r)}else v.a.isEventKey(t,"PgDn")?(t.preventDefault(),t.stopPropagation(),this.userSeek_(this.player_.currentTime()-60)):v.a.isEventKey(t,"PgUp")?(t.preventDefault(),t.stopPropagation(),this.userSeek_(this.player_.currentTime()+60)):e.prototype.handleKeyDown.call(this,t)},n.dispose=function(){this.disableInterval_(),this.off(this.player_,["ended","durationchange","timeupdate"],this.update),this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.update),this.off(this.player_,["playing"],this.enableIntervalHandler_),this.off(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in s.a&&"visibilityState"in s.a&&this.off(s.a,"visibilitychange",this.toggleVisibility_),e.prototype.dispose.call(this)},t}(ao);ho.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"},dn||$t||ho.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Lr.registerComponent("SeekBar",ho);var po=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).handleMouseMove=gr(mr(d()(r),r.handleMouseMove),30),r.throttledHandleMouseSeek=gr(mr(d()(r),r.handleMouseSeek),30),r.handleMouseUpHandler_=function(e){return r.handleMouseUp(e)},r.handleMouseDownHandler_=function(e){return r.handleMouseDown(e)},r.enable(),r}h()(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("playProgressBar"),r=t.getChild("mouseTimeDisplay");if(n||r){var i=t.el(),o=Nn(i),a=jn(i,e).x;a=oo(a,0,1),r&&r.update(o,a),n&&n.update(o,t.getProgress())}}},n.handleMouseSeek=function(e){var t=this.getChild("seekBar");t&&t.handleMouseMove(e)},n.enabled=function(){return this.enabled_},n.disable=function(){if(this.children().forEach((function(e){return e.disable&&e.disable()})),this.enabled()&&(this.off(["mousedown","touchstart"],this.handleMouseDownHandler_),this.off(this.el_,"mousemove",this.handleMouseMove),this.removeListenersAddedOnMousedownAndTouchstart(),this.addClass("disabled"),this.enabled_=!1,this.player_.scrubbing())){var e=this.getChild("seekBar");this.player_.scrubbing(!1),e.videoWasPlaying&&Hr(this.player_.play())}},n.enable=function(){this.children().forEach((function(e){return e.enable&&e.enable()})),this.enabled()||(this.on(["mousedown","touchstart"],this.handleMouseDownHandler_),this.on(this.el_,"mousemove",this.handleMouseMove),this.removeClass("disabled"),this.enabled_=!0)},n.removeListenersAddedOnMousedownAndTouchstart=function(){var e=this.el_.ownerDocument;this.off(e,"mousemove",this.throttledHandleMouseSeek),this.off(e,"touchmove",this.throttledHandleMouseSeek),this.off(e,"mouseup",this.handleMouseUpHandler_),this.off(e,"touchend",this.handleMouseUpHandler_)},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.handleMouseUpHandler_),this.on(t,"touchend",this.handleMouseUpHandler_)},n.handleMouseUp=function(e){var t=this.getChild("seekBar");t&&t.handleMouseUp(e),this.removeListenersAddedOnMousedownAndTouchstart()},t}(Lr);po.prototype.options_={children:["seekBar"]},Lr.registerComponent("ProgressControl",po);var mo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).on(t,["enterpictureinpicture","leavepictureinpicture"],(function(e){return r.handlePictureInPictureChange(e)})),r.on(t,["disablepictureinpicturechanged","loadedmetadata"],(function(e){return r.handlePictureInPictureEnabledChange(e)})),r.disable(),r}h()(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-picture-in-picture-control "+e.prototype.buildCSSClass.call(this)},n.handlePictureInPictureEnabledChange=function(){s.a.pictureInPictureEnabled&&!1===this.player_.disablePictureInPicture()?this.enable():this.disable()},n.handlePictureInPictureChange=function(e){this.player_.isInPictureInPicture()?this.controlText("Exit Picture-in-Picture"):this.controlText("Picture-in-Picture"),this.handlePictureInPictureEnabledChange()},n.handleClick=function(e){this.player_.isInPictureInPicture()?this.player_.exitPictureInPicture():this.player_.requestPictureInPicture()},t}(Hi);mo.prototype.controlText_="Picture-in-Picture",Lr.registerComponent("PictureInPictureToggle",mo);var go=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).on(t,"fullscreenchange",(function(e){return r.handleFullscreenChange(e)})),!1===s.a[t.fsApi_.fullscreenEnabled]&&r.disable(),r}h()(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-fullscreen-control "+e.prototype.buildCSSClass.call(this)},n.handleFullscreenChange=function(e){this.player_.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},n.handleClick=function(e){this.player_.isFullscreen()?this.player_.exitFullscreen():this.player_.requestFullscreen()},t}(Hi);go.prototype.controlText_="Fullscreen",Lr.registerComponent("FullscreenToggle",go);var vo=function(e){function t(){return e.apply(this,arguments)||this}return h()(t,e),t.prototype.createEl=function(){var t=e.prototype.createEl.call(this,"div",{className:"vjs-volume-level"});return t.appendChild(e.prototype.createEl.call(this,"span",{className:"vjs-control-text"})),t},t}(Lr);Lr.registerComponent("VolumeLevel",vo);var bo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).update=gr(mr(d()(r),r.update),30),r}h()(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-volume-tooltip"},{"aria-hidden":"true"})},n.update=function(e,t,n,r){if(!n){var i=Dn(this.el_),o=Dn(this.player_.el()),a=e.width*t;if(!o||!i)return;var s=e.left-o.left+a,c=e.width-a+(o.right-e.right),u=i.width/2;si.width&&(u=i.width),this.el_.style.right="-"+u+"px"}this.write(r+"%")},n.write=function(e){Sn(this.el_,e)},n.updateVolume=function(e,t,n,r,i){var o=this;this.requestNamedAnimationFrame("VolumeLevelTooltip#updateVolume",(function(){o.update(e,t,n,r.toFixed(0)),i&&i()}))},t}(Lr);Lr.registerComponent("VolumeLevelTooltip",bo);var yo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).update=gr(mr(d()(r),r.update),30),r}h()(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,n){var r=this,i=100*t;this.getChild("volumeLevelTooltip").updateVolume(e,t,n,i,(function(){n?r.el_.style.bottom=e.height*t+"px":r.el_.style.left=e.width*t+"px"}))},t}(Lr);yo.prototype.options_={children:["volumeLevelTooltip"]},Lr.registerComponent("MouseVolumeLevelDisplay",yo);var wo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).on("slideractive",(function(e){return r.updateLastVolume_(e)})),r.on(t,"volumechange",(function(e){return r.updateARIAAttributes(e)})),t.ready((function(){return r.updateARIAAttributes()})),r}h()(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){qn(t)&&e.prototype.handleMouseDown.call(this,t)},n.handleMouseMove=function(e){var t=this.getChild("mouseVolumeLevelDisplay");if(t){var n=this.el(),r=Dn(n),i=this.vertical(),o=jn(n,e);o=i?o.y:o.x,o=oo(o,0,1),t.update(r,o,i)}qn(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}(ao);wo.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"},dn||$t||wo.prototype.options_.children.splice(0,0,"mouseVolumeLevelDisplay"),wo.prototype.playerEvent="volumechange",Lr.registerComponent("VolumeBar",wo);var So=function(e){function t(t,n){var r;return void 0===n&&(n={}),n.vertical=n.vertical||!1,("undefined"===typeof n.volumeBar||Wt(n.volumeBar))&&(n.volumeBar=n.volumeBar||{},n.volumeBar.vertical=n.vertical),r=e.call(this,t,n)||this,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")}))}(d()(r),t),r.throttledHandleMouseMove=gr(mr(d()(r),r.handleMouseMove),30),r.handleMouseUpHandler_=function(e){return r.handleMouseUp(e)},r.on("mousedown",(function(e){return r.handleMouseDown(e)})),r.on("touchstart",(function(e){return r.handleMouseDown(e)})),r.on("mousemove",(function(e){return r.handleMouseMove(e)})),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}h()(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.handleMouseUpHandler_),this.on(t,"touchend",this.handleMouseUpHandler_)},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.handleMouseUpHandler_),this.off(t,"touchend",this.handleMouseUpHandler_)},n.handleMouseMove=function(e){this.volumeBar.handleMouseMove(e)},t}(Lr);So.prototype.options_={children:["volumeBar"]},Lr.registerComponent("VolumeControl",So);var _o=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,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")}))}(d()(r),t),r.on(t,["loadstart","volumechange"],(function(e){return r.update(e)})),r}h()(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;dn&&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++)En(this.el_,"vjs-vol-"+n);xn(this.el_,"vjs-vol-"+t)},n.updateControlText_=function(){var e=this.player_.muted()||0===this.player_.volume()?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e)},t}(Hi);_o.prototype.controlText_="Mute",Lr.registerComponent("MuteToggle",_o);var ko=function(e){function t(t,n){var r;return void 0===n&&(n={}),"undefined"!==typeof n.inline?n.inline=n.inline:n.inline=!0,("undefined"===typeof n.volumeControl||Wt(n.volumeControl))&&(n.volumeControl=n.volumeControl||{},n.volumeControl.vertical=!n.inline),(r=e.call(this,t,n)||this).handleKeyPressHandler_=function(e){return r.handleKeyPress(e)},r.on(t,["loadstart"],(function(e){return r.volumePanelState_(e)})),r.on(r.muteToggle,"keyup",(function(e){return r.handleKeyPress(e)})),r.on(r.volumeControl,"keyup",(function(e){return r.handleVolumeControlKeyUp(e)})),r.on("keydown",(function(e){return r.handleKeyPress(e)})),r.on("mouseover",(function(e){return r.handleMouseOver(e)})),r.on("mouseout",(function(e){return r.handleMouseOut(e)})),r.on(r.volumeControl,["slideractive"],r.sliderActive_),r.on(r.volumeControl,["sliderinactive"],r.sliderInactive_),r}h()(t,e);var n=t.prototype;return n.sliderActive_=function(){this.addClass("vjs-slider-active")},n.sliderInactive_=function(){this.removeClass("vjs-slider-active")},n.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")},n.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})},n.dispose=function(){this.handleMouseOut(),e.prototype.dispose.call(this)},n.handleVolumeControlKeyUp=function(e){v.a.isEventKey(e,"Esc")&&this.muteToggle.focus()},n.handleMouseOver=function(e){this.addClass("vjs-hover"),cr(s.a,"keyup",this.handleKeyPressHandler_)},n.handleMouseOut=function(e){this.removeClass("vjs-hover"),ur(s.a,"keyup",this.handleKeyPressHandler_)},n.handleKeyPress=function(e){v.a.isEventKey(e,"Esc")&&this.handleMouseOut()},t}(Lr);ko.prototype.options_={children:["muteToggle","volumeControl"]},Lr.registerComponent("VolumePanel",ko);var xo=function(e){function t(t,n){var r;return r=e.call(this,t,n)||this,n&&(r.menuButton_=n.menuButton),r.focusedChild_=-1,r.on("keydown",(function(e){return r.handleKeyDown(e)})),r.boundHandleBlur_=function(e){return r.handleBlur(e)},r.boundHandleTapClick_=function(e){return r.handleTapClick(e)},r}h()(t,e);var n=t.prototype;return n.addEventListenerForItem=function(e){e instanceof Lr&&(this.on(e,"blur",this.boundHandleBlur_),this.on(e,["tap","click"],this.boundHandleTapClick_))},n.removeEventListenerForItem=function(e){e instanceof Lr&&(this.off(e,"blur",this.boundHandleBlur_),this.off(e,["tap","click"],this.boundHandleTapClick_))},n.removeChild=function(t){"string"===typeof t&&(t=this.getChild(t)),this.removeEventListenerForItem(t),e.prototype.removeChild.call(this,t)},n.addItem=function(e){var t=this.addChild(e);t&&this.addEventListenerForItem(t)},n.createEl=function(){var t=this.options_.contentElType||"ul";this.contentEl_=wn(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_),cr(n,"click",(function(e){e.preventDefault(),e.stopImmediatePropagation()})),n},n.dispose=function(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,e.prototype.dispose.call(this)},n.handleBlur=function(e){var t=e.relatedTarget||s.a.activeElement;if(!this.children().some((function(e){return e.el()===t}))){var n=this.menuButton_;n&&n.buttonPressed_&&t!==n.el().firstChild&&n.unpressButton()}},n.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()}},n.handleKeyDown=function(e){v.a.isEventKey(e,"Left")||v.a.isEventKey(e,"Down")?(e.preventDefault(),e.stopPropagation(),this.stepForward()):(v.a.isEventKey(e,"Right")||v.a.isEventKey(e,"Up"))&&(e.preventDefault(),e.stopPropagation(),this.stepBack())},n.stepForward=function(){var e=0;void 0!==this.focusedChild_&&(e=this.focusedChild_+1),this.focus(e)},n.stepBack=function(){var e=0;void 0!==this.focusedChild_&&(e=this.focusedChild_-1),this.focus(e)},n.focus=function(e){void 0===e&&(e=0);var t=this.children().slice();t.length&&t[0].hasClass("vjs-menu-title")&&t.shift(),t.length>0&&(e<0?e=0:e>=t.length&&(e=t.length-1),this.focusedChild_=e,t[e].el_.focus())},t}(Lr);Lr.registerComponent("Menu",xo);var Eo=function(e){function t(t,n){var r;void 0===n&&(n={}),(r=e.call(this,t,n)||this).menuButton_=new Hi(t,n),r.menuButton_.controlText(r.controlText_),r.menuButton_.el_.setAttribute("aria-haspopup","true");var i=Hi.prototype.buildCSSClass();r.menuButton_.el_.className=r.buildCSSClass()+" "+i,r.menuButton_.removeClass("vjs-control"),r.addChild(r.menuButton_),r.update(),r.enabled_=!0;var o=function(e){return r.handleClick(e)};return r.handleMenuKeyUp_=function(e){return r.handleMenuKeyUp(e)},r.on(r.menuButton_,"tap",o),r.on(r.menuButton_,"click",o),r.on(r.menuButton_,"keydown",(function(e){return r.handleKeyDown(e)})),r.on(r.menuButton_,"mouseenter",(function(){r.addClass("vjs-hover"),r.menu.show(),cr(s.a,"keyup",r.handleMenuKeyUp_)})),r.on("mouseleave",(function(e){return r.handleMouseLeave(e)})),r.on("keydown",(function(e){return r.handleSubmenuKeyDown(e)})),r}h()(t,e);var n=t.prototype;return n.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()},n.createMenu=function(){var e=new xo(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var t=wn("li",{className:"vjs-menu-title",textContent:Ir(this.options_.title),tabIndex:-1}),n=new Lr(this.player_,{el:t});e.addItem(n)}if(this.items=this.createItems(),this.items)for(var r=0;r-1&&"showing"===o.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-1&&"showing"===o.mode){n=!1;break}}n&&(this.player_.cache_.selectedLanguage={enabled:!1})},t}(To);Lr.registerComponent("OffTextTrackMenuItem",Ao);var Io=function(e){function t(t,n){return void 0===n&&(n={}),n.tracks=t.textTracks(),e.call(this,t,n)||this}return h()(t,e),t.prototype.createItems=function(e,t){var n;void 0===e&&(e=[]),void 0===t&&(t=To),this.label_&&(n=this.label_+" off"),e.push(new Ao(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-1){var a=new t(this.player_,{track:o,kinds:this.kinds_,kind:this.kind_,selectable:!0,multiSelectable:!1});a.addClass("vjs-"+o.kind+"-menu-item"),e.push(a)}}return e},t}(Oo);Lr.registerComponent("TextTrackButton",Io);var Po=function(e){function t(t,n){var r,i=n.track,o=n.cue,a=t.currentTime();return n.selectable=!0,n.multiSelectable=!1,n.label=o.text,n.selected=o.startTime<=a&&a=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(Ir(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-1&&(r.label_="captions"),r.menuButton_.controlText(Ir(r.label_)),r}h()(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 jo(this.player_,{kind:this.label_})),this.hideThreshold_+=1),t=e.prototype.createItems.call(this,t,Bo)},t}(Io);zo.prototype.kinds_=["captions","subtitles"],zo.prototype.controlText_="Subtitles",Lr.registerComponent("SubsCapsButton",zo);var Fo=function(e){function t(t,n){var r,i=n.track,o=t.audioTracks();n.label=i.label||i.language||"Unknown",n.selected=i.enabled,(r=e.call(this,t,n)||this).track=i,r.addClass("vjs-"+i.kind+"-menu-item");var a=function(){for(var e=arguments.length,t=new Array(e),n=0;n=0;n--)t.push(new qo(this.player(),{rate:e[n]+"x"}));return t},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;it){r=n[i];break}this.player().playbackRate(r)},n.handlePlaybackRateschange=function(e){this.update()},n.playbackRates=function(){var e=this.player();return e.playbackRates&&e.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_.textContent=this.player().playbackRate()+"x")},t}(Eo);Vo.prototype.controlText_="Playback Rate",Lr.registerComponent("PlaybackRateMenuButton",Vo);var Wo=function(e){function t(){return e.apply(this,arguments)||this}h()(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-spacer "+e.prototype.buildCSSClass.call(this)},n.createEl=function(t,n,r){return void 0===t&&(t="div"),void 0===n&&(n={}),void 0===r&&(r={}),n.className||(n.className=this.buildCSSClass()),e.prototype.createEl.call(this,t,n,r)},t}(Lr);Lr.registerComponent("Spacer",Wo);var Ho=function(e){function t(){return e.apply(this,arguments)||this}h()(t,e);var n=t.prototype;return n.buildCSSClass=function(){return"vjs-custom-control-spacer "+e.prototype.buildCSSClass.call(this)},n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),textContent:"\xa0"})},t}(Wo);Lr.registerComponent("CustomControlSpacer",Ho);var Ko=function(e){function t(){return e.apply(this,arguments)||this}return h()(t,e),t.prototype.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"})},t}(Lr);Ko.prototype.options_={children:["playToggle","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","seekToLive","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","fullscreenToggle"]},"exitPictureInPicture"in s.a&&Ko.prototype.options_.children.splice(Ko.prototype.options_.children.length-1,0,"pictureInPictureToggle"),Lr.registerComponent("ControlBar",Ko);var Zo=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).on(t,"error",(function(e){return r.open(e)})),r}h()(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}(Xr);Zo.prototype.options_=u()({},Xr.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),Lr.registerComponent("ErrorDisplay",Zo);var Go=["#000","Black"],Xo=["#00F","Blue"],Yo=["#0FF","Cyan"],$o=["#0F0","Green"],Jo=["#F0F","Magenta"],Qo=["#F00","Red"],ea=["#FFF","White"],ta=["#FF0","Yellow"],na=["1","Opaque"],ra=["0.5","Semi-Transparent"],ia=["0","Transparent"],oa={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Go,ea,Qo,$o,Xo,ta,Jo,Yo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[na,ra,ia]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[ea,Go,Qo,$o,Xo,ta,Jo,Yo]},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:[na,ra]},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:[ia,ra,na]}};function aa(e,t){if(t&&(e=t(e)),e&&"none"!==e)return e}oa.windowColor.options=oa.backgroundColor.options;var sa=function(e){function t(t,n){var r;return n.temporary=!1,(r=e.call(this,t,n)||this).updateDisplay=r.updateDisplay.bind(d()(r)),r.fill(),r.hasBeenOpened_=r.hasBeenFilled_=!0,r.endDialog=wn("p",{className:"vjs-control-text",textContent:r.localize("End of dialog window.")}),r.el().appendChild(r.endDialog),r.setDefaults(),void 0===n.persistTextTrackSettings&&(r.options_.persistTextTrackSettings=r.options_.playerOptions.persistTextTrackSettings),r.on(r.$(".vjs-done-button"),"click",(function(){r.saveSettings(),r.close()})),r.on(r.$(".vjs-default-button"),"click",(function(){r.setDefaults(),r.updateDisplay()})),Ut(oa,(function(e){r.on(r.$(e.selector),"change",r.updateDisplay)})),r.options_.persistTextTrackSettings&&r.restoreSettings(),r}h()(t,e);var n=t.prototype;return n.dispose=function(){this.endDialog=null,e.prototype.dispose.call(this)},n.createElSelect_=function(e,t,n){var r=this;void 0===t&&(t=""),void 0===n&&(n="label");var i=oa[e],o=i.id.replace("%s",this.id_),a=[t,o].join(" ").trim();return["<"+n+' id="'+o+'" class="'+("label"===n?"vjs-label":"")+'">',this.localize(i.label),"",'").join("")},n.createElFgColor_=function(){var e="captions-text-legend-"+this.id_;return['
','',this.localize("Text"),"",this.createElSelect_("color",e),'',this.createElSelect_("textOpacity",e),"","
"].join("")},n.createElBgColor_=function(){var e="captions-background-"+this.id_;return['
','',this.localize("Background"),"",this.createElSelect_("backgroundColor",e),'',this.createElSelect_("backgroundOpacity",e),"","
"].join("")},n.createElWinColor_=function(){var e="captions-window-"+this.id_;return['
','',this.localize("Window"),"",this.createElSelect_("windowColor",e),'',this.createElSelect_("windowOpacity",e),"","
"].join("")},n.createElColors_=function(){return wn("div",{className:"vjs-track-settings-colors",innerHTML:[this.createElFgColor_(),this.createElBgColor_(),this.createElWinColor_()].join("")})},n.createElFont_=function(){return wn("div",{className:"vjs-track-settings-font",innerHTML:['
',this.createElSelect_("fontPercent","","legend"),"
",'
',this.createElSelect_("edgeStyle","","legend"),"
",'
',this.createElSelect_("fontFamily","","legend"),"
"].join("")})},n.createElControls_=function(){var e=this.localize("restore all settings to the default values");return wn("div",{className:"vjs-track-settings-controls",innerHTML:['",'"].join("")})},n.content=function(){return[this.createElColors_(),this.createElFont_(),this.createElControls_()]},n.label=function(){return this.localize("Caption Settings Dialog")},n.description=function(){return this.localize("Beginning of dialog window. Escape will cancel and close the window.")},n.buildCSSClass=function(){return e.prototype.buildCSSClass.call(this)+" vjs-text-track-settings"},n.getValues=function(){var e,t,n,r=this;return t=function(e,t,n){var i,o,a=(i=r.$(t.selector),o=t.parser,aa(i.options[i.options.selectedIndex].value,o));return void 0!==a&&(e[n]=a),e},void 0===(n={})&&(n=0),Ft(e=oa).reduce((function(n,r){return t(n,e[r],r)}),n)},n.setValues=function(e){var t=this;Ut(oa,(function(n,r){!function(e,t,n){if(t)for(var r=0;rthis.options_.liveTolerance;this.timeupdateSeen_&&r!==1/0||(a=!1),a!==this.behindLiveEdge_&&(this.behindLiveEdge_=a,this.trigger("liveedgechange"))}},n.handleDurationchange=function(){this.toggleTracking()},n.toggleTracking=function(){this.player_.duration()===1/0&&this.liveWindow()>=this.options_.trackingThreshold?(this.player_.options_.liveui&&this.player_.addClass("vjs-liveui"),this.startTracking()):(this.player_.removeClass("vjs-liveui"),this.stopTracking())},n.startTracking=function(){this.isTracking()||(this.timeupdateSeen_||(this.timeupdateSeen_=this.player_.hasStarted()),this.trackingInterval_=this.setInterval(this.trackLiveHandler_,30),this.trackLive_(),this.on(this.player_,["play","pause"],this.trackLiveHandler_),this.timeupdateSeen_?this.on(this.player_,"seeked",this.handleSeeked_):(this.one(this.player_,"play",this.handlePlay_),this.one(this.player_,"timeupdate",this.handleFirstTimeupdate_)))},n.handleFirstTimeupdate=function(){this.timeupdateSeen_=!0,this.on(this.player_,"seeked",this.handleSeeked_)},n.handleSeeked=function(){var e=Math.abs(this.liveCurrentTime()-this.player_.currentTime());this.seekedBehindLive_=this.nextSeekedFromUser_&&e>2,this.nextSeekedFromUser_=!1,this.trackLive_()},n.handlePlay=function(){this.one(this.player_,"timeupdate",this.seekToLiveEdge_)},n.reset_=function(){this.lastTime_=-1,this.pastSeekEnd_=0,this.lastSeekEnd_=-1,this.behindLiveEdge_=!0,this.timeupdateSeen_=!1,this.seekedBehindLive_=!1,this.nextSeekedFromUser_=!1,this.clearInterval(this.trackingInterval_),this.trackingInterval_=null,this.off(this.player_,["play","pause"],this.trackLiveHandler_),this.off(this.player_,"seeked",this.handleSeeked_),this.off(this.player_,"play",this.handlePlay_),this.off(this.player_,"timeupdate",this.handleFirstTimeupdate_),this.off(this.player_,"timeupdate",this.seekToLiveEdge_)},n.nextSeekedFromUser=function(){this.nextSeekedFromUser_=!0},n.stopTracking=function(){this.isTracking()&&(this.reset_(),this.trigger("liveedgechange"))},n.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},n.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},n.liveWindow=function(){var e=this.liveCurrentTime();return e===1/0?0:e-this.seekableStart()},n.isLive=function(){return this.isTracking()},n.atLiveEdge=function(){return!this.behindLiveEdge()},n.liveCurrentTime=function(){return this.pastSeekEnd()+this.seekableEnd()},n.pastSeekEnd=function(){var e=this.seekableEnd();return-1!==this.lastSeekEnd_&&e!==this.lastSeekEnd_&&(this.pastSeekEnd_=0),this.lastSeekEnd_=e,this.pastSeekEnd_},n.behindLiveEdge=function(){return this.behindLiveEdge_},n.isTracking=function(){return"number"===typeof this.trackingInterval_},n.seekToLiveEdge=function(){this.seekedBehindLive_=!1,this.atLiveEdge()||(this.nextSeekedFromUser_=!1,this.player_.currentTime(this.liveCurrentTime()))},n.dispose=function(){this.off(s.a,"visibilitychange",this.handleVisibilityChange_),this.stopTracking(),e.prototype.dispose.call(this)},t}(Lr);Lr.registerComponent("LiveTracker",la);var da,fa=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 o=0;o=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)}))}},n.setScrubbing=function(e){this.isScrubbing_=e},n.scrubbing=function(){return this.isScrubbing_},n.setCurrentTime=function(e){try{this.isScrubbing_&&this.el_.fastSeek&&fn?this.el_.fastSeek(e):this.el_.currentTime=e}catch(t){Lt(t,"Video is not ready. (Video.js)")}},n.duration=function(){var e=this;if(this.el_.duration===1/0&&$t&&nn&&0===this.el_.currentTime){return this.on("timeupdate",(function t(){e.el_.currentTime>0&&(e.el_.duration===1/0&&e.trigger("durationchange"),e.off("timeupdate",t))})),NaN}return this.el_.duration||NaN},n.width=function(){return this.el_.offsetWidth},n.height=function(){return this.el_.offsetHeight},n.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,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",n),this.on("dispose",(function(){e.off("webkitbeginfullscreen",n),e.off("webkitendfullscreen",t)}))}},n.supportsFullScreen=function(){if("function"===typeof this.el_.webkitEnterFullScreen){var e=o.a.navigator&&o.a.navigator.userAgent||"";if(/Android/.test(e)||!/Chrome|Mac OS X 10.5/.test(e))return!0}return!1},n.enterFullScreen=function(){var e=this.el_;if(e.paused&&e.networkState<=e.HAVE_METADATA)Hr(this.el_.play()),this.setTimeout((function(){e.pause();try{e.webkitEnterFullScreen()}catch(t){this.trigger("fullscreenerror",t)}}),0);else try{e.webkitEnterFullScreen()}catch(t){this.trigger("fullscreenerror",t)}},n.exitFullScreen=function(){this.el_.webkitDisplayingFullscreen?this.el_.webkitExitFullScreen():this.trigger("fullscreenerror",new Error("The video is not fullscreen"))},n.requestPictureInPicture=function(){return this.el_.requestPictureInPicture()},n.src=function(e){if(void 0===e)return this.el_.src;this.setSrc(e)},n.reset=function(){t.resetMediaElement(this.el_)},n.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc},n.setControls=function(e){this.el_.controls=!!e},n.addTextTrack=function(t,n,r){return this.featuresNativeTextTracks?this.el_.addTextTrack(t,n,r):e.prototype.addTextTrack.call(this,t,n,r)},n.createRemoteTextTrack=function(t){if(!this.featuresNativeTextTracks)return e.prototype.createRemoteTextTrack.call(this,t);var n=s.a.createElement("track");return t.kind&&(n.kind=t.kind),t.label&&(n.label=t.label),(t.language||t.srclang)&&(n.srclang=t.language||t.srclang),t.default&&(n.default=t.default),t.id&&(n.id=t.id),t.src&&(n.src=t.src),n},n.addRemoteTextTrack=function(t,n){var r=e.prototype.addRemoteTextTrack.call(this,t,n);return this.featuresNativeTextTracks&&this.el().appendChild(r),r},n.removeRemoteTextTrack=function(t){if(e.prototype.removeRemoteTextTrack.call(this,t),this.featuresNativeTextTracks)for(var n=this.$$("track"),r=n.length;r--;)t!==n[r]&&t!==n[r].track||this.el().removeChild(n[r])},n.getVideoPlaybackQuality=function(){if("function"===typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var e={};return"undefined"!==typeof this.el().webkitDroppedFrameCount&&"undefined"!==typeof this.el().webkitDecodedFrameCount&&(e.droppedVideoFrames=this.el().webkitDroppedFrameCount,e.totalVideoFrames=this.el().webkitDecodedFrameCount),o.a.performance&&"function"===typeof o.a.performance.now?e.creationTime=o.a.performance.now():o.a.performance&&o.a.performance.timing&&"number"===typeof o.a.performance.timing.navigationStart&&(e.creationTime=o.a.Date.now()-o.a.performance.timing.navigationStart),e},t}(xi);ba(ya,"TEST_VID",(function(){if(gn()){var e=s.a.createElement("video"),t=s.a.createElement("track");return t.kind="captions",t.srclang="en",t.label="English",e.appendChild(t),e}})),ya.isSupported=function(){try{ya.TEST_VID.volume=.5}catch(e){return!1}return!(!ya.TEST_VID||!ya.TEST_VID.canPlayType)},ya.canPlayType=function(e){return ya.TEST_VID.canPlayType(e)},ya.canPlaySource=function(e,t){return ya.canPlayType(e.type)},ya.canControlVolume=function(){try{var e=ya.TEST_VID.volume;return ya.TEST_VID.volume=e/2+.1,e!==ya.TEST_VID.volume}catch(t){return!1}},ya.canMuteVolume=function(){try{var e=ya.TEST_VID.muted;return ya.TEST_VID.muted=!e,ya.TEST_VID.muted?An(ya.TEST_VID,"muted","muted"):In(ya.TEST_VID,"muted"),e!==ya.TEST_VID.muted}catch(t){return!1}},ya.canControlPlaybackRate=function(){if($t&&nn&&rn<58)return!1;try{var e=ya.TEST_VID.playbackRate;return ya.TEST_VID.playbackRate=e/2+.1,e!==ya.TEST_VID.playbackRate}catch(t){return!1}},ya.canOverrideAttributes=function(){try{var e=function(){};Object.defineProperty(s.a.createElement("video"),"src",{get:e,set:e}),Object.defineProperty(s.a.createElement("audio"),"src",{get:e,set:e}),Object.defineProperty(s.a.createElement("video"),"innerHTML",{get:e,set:e}),Object.defineProperty(s.a.createElement("audio"),"innerHTML",{get:e,set:e})}catch(t){return!1}return!0},ya.supportsNativeTextTracks=function(){return fn||dn&&nn},ya.supportsNativeVideoTracks=function(){return!(!ya.TEST_VID||!ya.TEST_VID.videoTracks)},ya.supportsNativeAudioTracks=function(){return!(!ya.TEST_VID||!ya.TEST_VID.audioTracks)},ya.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"],[["featuresVolumeControl","canControlVolume"],["featuresMuteControl","canMuteVolume"],["featuresPlaybackRate","canControlPlaybackRate"],["featuresSourceset","canOverrideAttributes"],["featuresNativeTextTracks","supportsNativeTextTracks"],["featuresNativeVideoTracks","supportsNativeVideoTracks"],["featuresNativeAudioTracks","supportsNativeAudioTracks"]].forEach((function(e){var t=e[0],n=e[1];ba(ya.prototype,t,(function(){return ya[n]()}),!0)})),ya.prototype.movingMediaElementInDOM=!dn,ya.prototype.featuresFullscreenResize=!0,ya.prototype.featuresProgressEvents=!0,ya.prototype.featuresTimeupdateEvents=!0,ya.patchCanPlayType=function(){Jt>=4&&!en&&!nn&&(da=ya.TEST_VID&&ya.TEST_VID.constructor.prototype.canPlayType,ya.TEST_VID.constructor.prototype.canPlayType=function(e){return e&&/^application\/(?:x-|vnd\.apple\.)mpegurl/i.test(e)?"maybe":da.call(this,e)})},ya.unpatchCanPlayType=function(){var e=ya.TEST_VID.constructor.prototype.canPlayType;return da&&(ya.TEST_VID.constructor.prototype.canPlayType=da),e},ya.patchCanPlayType(),ya.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(t){}}()}},ya.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(t){}}()}},["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach((function(e){ya.prototype[e]=function(){return this.el_[e]||this.el_.hasAttribute(e)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(e){ya.prototype["set"+Ir(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","disablePictureInPicture","played","networkState","readyState","videoWidth","videoHeight","crossOrigin"].forEach((function(e){ya.prototype[e]=function(){return this.el_[e]}})),["volume","src","poster","preload","playbackRate","defaultPlaybackRate","disablePictureInPicture","crossOrigin"].forEach((function(e){ya.prototype["set"+Ir(e)]=function(t){this.el_[e]=t}})),["pause","load","play"].forEach((function(e){ya.prototype[e]=function(){return this.el_[e]()}})),xi.withSourceHandlers(ya),ya.nativeSourceHandler={},ya.nativeSourceHandler.canPlayType=function(e){try{return ya.TEST_VID.canPlayType(e)}catch(t){return""}},ya.nativeSourceHandler.canHandleSource=function(e,t){if(e.type)return ya.nativeSourceHandler.canPlayType(e.type);if(e.src){var n=fi(e.src);return ya.nativeSourceHandler.canPlayType("video/"+n)}return""},ya.nativeSourceHandler.handleSource=function(e,t,n){t.setSrc(e.src)},ya.nativeSourceHandler.dispose=function(){},ya.registerSourceHandler(ya.nativeSourceHandler),xi.registerTech("Html5",ya);var wa=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","resize","volumechange","texttrackchange"],Sa={canplay:"CanPlay",canplaythrough:"CanPlayThrough",playing:"Playing",seeked:"Seeked"},_a=["tiny","xsmall","small","medium","large","xlarge","huge"],ka={};_a.forEach((function(e){var t="x"===e.charAt(0)?"x-"+e.substring(1):e;ka[e]="vjs-layout-"+t}));var xa={tiny:210,xsmall:320,small:425,medium:768,large:1440,xlarge:2560,huge:1/0},Ea=function(e){function t(n,r,i){var o;if(n.id=n.id||r.id||"vjs_video_"+tr(),(r=qt(t.getTagSettings(n),r)).initChildren=!1,r.createEl=!1,r.evented=!1,r.reportTouchActivity=!1,!r.language)if("function"===typeof n.closest){var a=n.closest("[lang]");a&&a.getAttribute&&(r.language=a.getAttribute("lang"))}else for(var c=n;c&&1===c.nodeType;){if(Cn(c).hasOwnProperty("lang")){r.language=c.getAttribute("lang");break}c=c.parentNode}if((o=e.call(this,null,r,i)||this).boundDocumentFullscreenChange_=function(e){return o.documentFullscreenChange_(e)},o.boundFullWindowOnEscKey_=function(e){return o.fullWindowOnEscKey(e)},o.boundUpdateStyleEl_=function(e){return o.updateStyleEl_(e)},o.boundApplyInitTime_=function(e){return o.applyInitTime_(e)},o.boundUpdateCurrentBreakpoint_=function(e){return o.updateCurrentBreakpoint_(e)},o.boundHandleTechClick_=function(e){return o.handleTechClick_(e)},o.boundHandleTechDoubleClick_=function(e){return o.handleTechDoubleClick_(e)},o.boundHandleTechTouchStart_=function(e){return o.handleTechTouchStart_(e)},o.boundHandleTechTouchMove_=function(e){return o.handleTechTouchMove_(e)},o.boundHandleTechTouchEnd_=function(e){return o.handleTechTouchEnd_(e)},o.boundHandleTechTap_=function(e){return o.handleTechTap_(e)},o.isFullscreen_=!1,o.log=Bt(o.id_),o.fsApi_=It,o.isPosterFromTech_=!1,o.queuedCallbacks_=[],o.isReady_=!1,o.hasStarted_=!1,o.userActive_=!1,o.debugEnabled_=!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=n,o.tagAttributes=n&&Cn(n),o.language(o.options_.language),r.languages){var u={};Object.getOwnPropertyNames(r.languages).forEach((function(e){u[e.toLowerCase()]=r.languages[e]})),o.languages_=u}else o.languages_=t.prototype.options_.languages;o.resetCache_(),o.poster_=r.poster||"",o.controls_=!!r.controls,n.controls=!1,n.removeAttribute("controls"),o.changingSrc_=!1,o.playCallbacks_=[],o.playTerminatedQueue_=[],n.hasAttribute("autoplay")?o.autoplay(!0):o.autoplay(o.options_.autoplay),r.plugins&&Object.keys(r.plugins).forEach((function(e){if("function"!==typeof o[e])throw new Error('plugin "'+e+'" does not exist')})),o.scrubbing_=!1,o.el_=o.createEl(),Mr(d()(o),{eventBusKey:"el_"}),o.fsApi_.requestFullscreen&&(cr(s.a,o.fsApi_.fullscreenchange,o.boundDocumentFullscreenChange_),o.on(o.fsApi_.fullscreenchange,o.boundDocumentFullscreenChange_)),o.fluid_&&o.on(["playerreset","resize"],o.boundUpdateStyleEl_);var l=Pr(o.options_);r.plugins&&Object.keys(r.plugins).forEach((function(e){o[e](r.plugins[e])})),r.debug&&o.debug(!0),o.options_.playerOptions=l,o.middleware_=[],o.playbackRates(r.playbackRates),o.initChildren(),o.isAudio("audio"===n.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"),cn&&o.addClass("vjs-touch-enabled"),dn||o.addClass("vjs-workinghover"),t.players[o.id_]=d()(o);var f="7.16.0".split(".")[0];return o.addClass("vjs-v"+f),o.userActive(!0),o.reportUserActivity(),o.one("play",(function(e){return o.listenForUserActivity_(e)})),o.on("stageclick",(function(e){return o.handleStageClick_(e)})),o.on("keydown",(function(e){return o.handleKeyDown(e)})),o.on("languagechange",(function(e){return o.handleLanguagechange(e)})),o.breakpoints(o.options_.breakpoints),o.responsive(o.options_.responsive),o}h()(t,e);var n=t.prototype;return n.dispose=function(){var n=this;this.trigger("dispose"),this.off("dispose"),ur(s.a,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),ur(s.a,"keydown",this.boundFullWindowOnEscKey_),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),t.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),Oi[this.id()]=null,ki.names.forEach((function(e){var t=ki[e],r=n[t.getterName]();r&&r.off&&r.off()})),e.prototype.dispose.call(this)},n.createEl=function(){var t,n=this.tag,r=this.playerElIngest_=n.parentNode&&n.parentNode.hasAttribute&&n.parentNode.hasAttribute("data-vjs-player"),i="video-js"===this.tag.tagName.toLowerCase();r?t=this.el_=n.parentNode:i||(t=this.el_=e.prototype.createEl.call(this,"div"));var a=Cn(n);if(i){for(t=this.el_=n,n=this.tag=s.a.createElement("video");t.children.length;)n.appendChild(t.firstChild);kn(t,"video-js")||xn(t,"video-js"),t.appendChild(n),r=this.playerElIngest_=t,Object.keys(t).forEach((function(e){try{n[e]=t[e]}catch(r){}}))}if(n.setAttribute("tabindex","-1"),a.tabindex="-1",(on||nn&&sn)&&(n.setAttribute("role","application"),a.role="application"),n.removeAttribute("width"),n.removeAttribute("height"),"width"in a&&delete a.width,"height"in a&&delete a.height,Object.getOwnPropertyNames(a).forEach((function(e){i&&"class"===e||t.setAttribute(e,a[e]),i&&n.setAttribute(e,a[e])})),n.playerId=n.id,n.id+="_html5_api",n.className="vjs-tech",n.player=t.player=this,this.addClass("vjs-paused"),!0!==o.a.VIDEOJS_NO_DYNAMIC_STYLE){this.styleEl_=Jn("vjs-styles-dimensions");var c=Wn(".vjs-styles-defaults"),u=Wn("head");u.insertBefore(this.styleEl_,c?c.nextSibling:u.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),this.crossOrigin(this.options_.crossOrigin||this.options_.crossorigin);for(var l=n.getElementsByTagName("a"),d=0;d0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),i=r[1]/r[0];e=void 0!==this.width_?this.width_:void 0!==this.height_?this.height_/i:this.videoWidth()||300,t=void 0!==this.height_?this.height_:e*i,n=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(n),Qn(this.styleEl_,"\n ."+n+" {\n width: "+e+"px;\n height: "+t+"px;\n }\n\n ."+n+".vjs-fluid {\n padding-top: "+100*i+"%;\n }\n ")}else{var a="number"===typeof this.width_?this.width_:this.options_.width,s="number"===typeof this.height_?this.height_:this.options_.height,c=this.tech_&&this.tech_.el();c&&(a>=0&&(c.width=a),s>=0&&(c.height=s))}},n.loadTech_=function(e,t){var n=this;this.tech_&&this.unloadTech_();var r=Ir(e),i=e.charAt(0).toLowerCase()+e.slice(1);"Html5"!==r&&this.tag&&(xi.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=r,this.isReady_=!1;var o=this.autoplay();("string"===typeof this.autoplay()||!0===this.autoplay()&&this.options_.normalizeAutoplay)&&(o=!1);var a={source:t,autoplay:o,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+i+"_api",playsinline:this.options_.playsinline,preload:this.options_.preload,loop:this.options_.loop,disablePictureInPicture:this.options_.disablePictureInPicture,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};ki.names.forEach((function(e){var t=ki[e];a[t.getterName]=n[t.privateName]})),qt(a,this.options_[r]),qt(a,this.options_[i]),qt(a,this.options_[e.toLowerCase()]),this.tag&&(a.tag=this.tag),t&&t.src===this.cache_.src&&this.cache_.currentTime>0&&(a.startTime=this.cache_.currentTime);var s=xi.getTech(e);if(!s)throw new Error("No Tech named '"+r+"' exists! '"+r+"' should be registered using videojs.registerTech()'");this.tech_=new s(a),this.tech_.ready(mr(this,this.handleTechReady_),!0),Gr(this.textTracksJson_||[],this.tech_),wa.forEach((function(e){n.on(n.tech_,e,(function(t){return n["handleTech"+Ir(e)+"_"](t)}))})),Object.keys(Sa).forEach((function(e){n.on(n.tech_,e,(function(t){0===n.tech_.playbackRate()&&n.tech_.seeking()?n.queuedCallbacks_.push({callback:n["handleTech"+Sa[e]+"_"].bind(n),event:t}):n["handleTech"+Sa[e]+"_"](t)}))})),this.on(this.tech_,"loadstart",(function(e){return n.handleTechLoadStart_(e)})),this.on(this.tech_,"sourceset",(function(e){return n.handleTechSourceset_(e)})),this.on(this.tech_,"waiting",(function(e){return n.handleTechWaiting_(e)})),this.on(this.tech_,"ended",(function(e){return n.handleTechEnded_(e)})),this.on(this.tech_,"seeking",(function(e){return n.handleTechSeeking_(e)})),this.on(this.tech_,"play",(function(e){return n.handleTechPlay_(e)})),this.on(this.tech_,"firstplay",(function(e){return n.handleTechFirstPlay_(e)})),this.on(this.tech_,"pause",(function(e){return n.handleTechPause_(e)})),this.on(this.tech_,"durationchange",(function(e){return n.handleTechDurationChange_(e)})),this.on(this.tech_,"fullscreenchange",(function(e,t){return n.handleTechFullscreenChange_(e,t)})),this.on(this.tech_,"fullscreenerror",(function(e,t){return n.handleTechFullscreenError_(e,t)})),this.on(this.tech_,"enterpictureinpicture",(function(e){return n.handleTechEnterPictureInPicture_(e)})),this.on(this.tech_,"leavepictureinpicture",(function(e){return n.handleTechLeavePictureInPicture_(e)})),this.on(this.tech_,"error",(function(e){return n.handleTechError_(e)})),this.on(this.tech_,"posterchange",(function(e){return n.handleTechPosterChange_(e)})),this.on(this.tech_,"textdata",(function(e){return n.handleTechTextData_(e)})),this.on(this.tech_,"ratechange",(function(e){return n.handleTechRateChange_(e)})),this.on(this.tech_,"loadedmetadata",this.boundUpdateStyleEl_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode===this.el()||"Html5"===r&&this.tag||_n(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)},n.unloadTech_=function(){var e=this;ki.names.forEach((function(t){var n=ki[t];e[n.privateName]=e[n.getterName]()})),this.textTracksJson_=Zr(this.tech_),this.isReady_=!1,this.tech_.dispose(),this.tech_=!1,this.isPosterFromTech_&&(this.poster_="",this.trigger("posterchange")),this.isPosterFromTech_=!1},n.tech=function(e){return void 0===e&&Lt.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_},n.addTechControlsListeners_=function(){this.removeTechControlsListeners_(),this.on(this.tech_,"click",this.boundHandleTechClick_),this.on(this.tech_,"dblclick",this.boundHandleTechDoubleClick_),this.on(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.on(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.on(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.on(this.tech_,"tap",this.boundHandleTechTap_)},n.removeTechControlsListeners_=function(){this.off(this.tech_,"tap",this.boundHandleTechTap_),this.off(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.off(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.off(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.off(this.tech_,"click",this.boundHandleTechClick_),this.off(this.tech_,"dblclick",this.boundHandleTechDoubleClick_)},n.handleTechReady_=function(){this.triggerReady(),this.cache_.volume&&this.techCall_("setVolume",this.cache_.volume),this.handleTechPosterChange_(),this.handleTechDurationChange_()},n.handleTechLoadStart_=function(){this.removeClass("vjs-ended"),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_(!0===this.autoplay()&&this.options_.normalizeAutoplay?"play":this.autoplay())},n.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(Wr(r))return r.catch((function(e){throw n(),new Error("Rejection at manualAutoplay. Restoring muted value. "+(e||""))}))};if("any"!==e||this.muted()?n="muted"!==e||this.muted()?this.play():r():Wr(n=this.play())&&(n=n.catch(r)),Wr(n))return n.then((function(){t.trigger({type:"autoplay-success",autoplay:e})})).catch((function(){t.trigger({type:"autoplay-failure",autoplay:e})}))}},n.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=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;i0&&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")},n.handleTechWaiting_=function(){var e=this;this.addClass("vjs-waiting"),this.trigger("waiting");var t=this.currentTime();this.on("timeupdate",(function n(){t!==e.currentTime()&&(e.removeClass("vjs-waiting"),e.off("timeupdate",n))}))},n.handleTechCanPlay_=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},n.handleTechCanPlayThrough_=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},n.handleTechPlaying_=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},n.handleTechSeeking_=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},n.handleTechSeeked_=function(){this.removeClass("vjs-seeking"),this.removeClass("vjs-ended"),this.trigger("seeked")},n.handleTechFirstPlay_=function(){this.options_.starttime&&(Lt.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")},n.handleTechPause_=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},n.handleTechEnded_=function(){this.addClass("vjs-ended"),this.removeClass("vjs-waiting"),this.options_.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},n.handleTechDurationChange_=function(){this.duration(this.techGet_("duration"))},n.handleTechClick_=function(e){this.controls_&&(this.paused()?Hr(this.play()):this.pause())},n.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()))},n.handleTechTap_=function(){this.userActive(!this.userActive())},n.handleTechTouchStart_=function(){this.userWasActive=this.userActive()},n.handleTechTouchMove_=function(){this.userWasActive&&this.reportUserActivity()},n.handleTechTouchEnd_=function(e){e.cancelable&&e.preventDefault()},n.handleStageClick_=function(){this.reportUserActivity()},n.toggleFullscreenClass_=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},n.documentFullscreenChange_=function(e){var t=e.target.player;if(!t||t===this){var n=this.el(),r=s.a[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)}},n.handleTechFullscreenChange_=function(e,t){t&&(t.nativeIOSFullscreen&&this.toggleClass("vjs-ios-native-fs"),this.isFullscreen(t.isFullscreen))},n.handleTechFullscreenError_=function(e,t){this.trigger("fullscreenerror",t)},n.togglePictureInPictureClass_=function(){this.isInPictureInPicture()?this.addClass("vjs-picture-in-picture"):this.removeClass("vjs-picture-in-picture")},n.handleTechEnterPictureInPicture_=function(e){this.isInPictureInPicture(!0)},n.handleTechLeavePictureInPicture_=function(e){this.isInPictureInPicture(!1)},n.handleTechError_=function(){var e=this.tech_.error();this.error(e)},n.handleTechTextData_=function(){var e=null;arguments.length>1&&(e=arguments[1]),this.trigger("textdata",e)},n.getCache=function(){return this.cache_},n.resetCache_=function(){this.cache_={currentTime:0,initTime:0,inactivityTimeout:this.options_.inactivityTimeout,duration:NaN,lastVolume:1,lastPlaybackRate:this.defaultPlaybackRate(),media:null,src:"",source:{},sources:[],playbackRates:[],volume:1}},n.techCall_=function(e,t){this.ready((function(){if(e in Ii)return function(e,t,n,r){return t[n](e.reduce(Ri(n),r))}(this.middleware_,this.tech_,e,t);if(e in Pi)return Ti(this.middleware_,this.tech_,e,t);try{this.tech_&&this.tech_[e](t)}catch(n){throw Lt(n),n}}),!0)},n.techGet_=function(e){if(this.tech_&&this.tech_.isReady_){if(e in Ai)return function(e,t,n){return e.reduceRight(Ri(n),t[n]())}(this.middleware_,this.tech_,e);if(e in Pi)return Ti(this.middleware_,this.tech_,e);try{return this.tech_[e]()}catch(t){if(void 0===this.tech_[e])throw Lt("Video.js: "+e+" method not defined for "+this.techName_+" playback technology.",t),t;if("TypeError"===t.name)throw Lt("Video.js: "+e+" unavailable on "+this.techName_+" playback technology element.",t),this.tech_.isReady_=!1,t;throw Lt(t),t}}},n.play=function(){var e=this,t=this.options_.Promise||o.a.Promise;return t?new t((function(t){e.play_(t)})):this.play_()},n.play_=function(e){var t=this;void 0===e&&(e=Hr),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||!fn&&!dn||this.load());var r=this.techGet_("play");null===r?this.runPlayTerminatedQueue_():this.runPlayCallbacks_(r)},n.runPlayTerminatedQueue_=function(){var e=this.playTerminatedQueue_.slice(0);this.playTerminatedQueue_=[],e.forEach((function(e){e()}))},n.runPlayCallbacks_=function(e){var t=this.playCallbacks_.slice(0);this.playCallbacks_=[],this.playTerminatedQueue_=[],t.forEach((function(t){t(e)}))},n.pause=function(){this.techCall_("pause")},n.paused=function(){return!1!==this.techGet_("paused")},n.played=function(){return this.techGet_("played")||Fr(0,0)},n.scrubbing=function(e){if("undefined"===typeof e)return this.scrubbing_;this.scrubbing_=!!e,this.techCall_("setScrubbing",this.scrubbing_),e?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing")},n.currentTime=function(e){return"undefined"!==typeof e?(e<0&&(e=0),this.isReady_&&!this.changingSrc_&&this.tech_&&this.tech_.isReady_?(this.techCall_("setCurrentTime",e),void(this.cache_.initTime=0)):(this.cache_.initTime=e,this.off("canplay",this.boundApplyInitTime_),void this.one("canplay",this.boundApplyInitTime_))):(this.cache_.currentTime=this.techGet_("currentTime")||0,this.cache_.currentTime)},n.applyInitTime_=function(){this.currentTime(this.cache_.initTime)},n.duration=function(e){if(void 0===e)return void 0!==this.cache_.duration?this.cache_.duration:NaN;(e=parseFloat(e))<0&&(e=1/0),e!==this.cache_.duration&&(this.cache_.duration=e,e===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),isNaN(e)||this.trigger("durationchange"))},n.remainingTime=function(){return this.duration()-this.currentTime()},n.remainingTimeDisplay=function(){return Math.floor(this.duration())-Math.floor(this.currentTime())},n.buffered=function(){var e=this.techGet_("buffered");return e&&e.length||(e=Fr(0,0)),e},n.bufferedPercent=function(){return Ur(this.buffered(),this.duration())},n.bufferedEnd=function(){var e=this.buffered(),t=this.duration(),n=e.end(e.length-1);return n>t&&(n=t),n},n.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)},n.muted=function(e){if(void 0===e)return this.techGet_("muted")||!1;this.techCall_("setMuted",e)},n.defaultMuted=function(e){return void 0!==e?this.techCall_("setDefaultMuted",e):this.techGet_("defaultMuted")||!1},n.lastVolume_=function(e){if(void 0===e||0===e)return this.cache_.lastVolume;this.cache_.lastVolume=e},n.supportsFullScreen=function(){return this.techGet_("supportsFullScreen")||!1},n.isFullscreen=function(e){if(void 0!==e){var t=this.isFullscreen_;return this.isFullscreen_=Boolean(e),this.isFullscreen_!==t&&this.fsApi_.prefixed&&this.trigger("fullscreenchange"),void this.toggleFullscreenClass_()}return this.isFullscreen_},n.requestFullscreen=function(e){var t=this.options_.Promise||o.a.Promise;if(t){var n=this;return new t((function(t,r){function i(){n.off("fullscreenerror",a),n.off("fullscreenchange",o)}function o(){i(),t()}function a(e,t){i(),r(t)}n.one("fullscreenchange",o),n.one("fullscreenerror",a);var s=n.requestFullscreenHelper_(e);s&&(s.then(i,i),s.then(t,r))}))}return this.requestFullscreenHelper_()},n.requestFullscreenHelper_=function(e){var t,n=this;if(this.fsApi_.prefixed||(t=this.options_.fullscreen&&this.options_.fullscreen.options||{},void 0!==e&&(t=e)),this.fsApi_.requestFullscreen){var r=this.el_[this.fsApi_.requestFullscreen](t);return r&&r.then((function(){return n.isFullscreen(!0)}),(function(){return n.isFullscreen(!1)})),r}this.tech_.supportsFullScreen()&&!0===!this.options_.preferFullWindow?this.techCall_("enterFullScreen"):this.enterFullWindow()},n.exitFullscreen=function(){var e=this.options_.Promise||o.a.Promise;if(e){var t=this;return new e((function(e,n){function r(){t.off("fullscreenerror",o),t.off("fullscreenchange",i)}function i(){r(),e()}function o(e,t){r(),n(t)}t.one("fullscreenchange",i),t.one("fullscreenerror",o);var a=t.exitFullscreenHelper_();a&&(a.then(r,r),a.then(e,n))}))}return this.exitFullscreenHelper_()},n.exitFullscreenHelper_=function(){var e=this;if(this.fsApi_.requestFullscreen){var t=s.a[this.fsApi_.exitFullscreen]();return t&&Hr(t.then((function(){return e.isFullscreen(!1)}))),t}this.tech_.supportsFullScreen()&&!0===!this.options_.preferFullWindow?this.techCall_("exitFullScreen"):this.exitFullWindow()},n.enterFullWindow=function(){this.isFullscreen(!0),this.isFullWindow=!0,this.docOrigOverflow=s.a.documentElement.style.overflow,cr(s.a,"keydown",this.boundFullWindowOnEscKey_),s.a.documentElement.style.overflow="hidden",xn(s.a.body,"vjs-full-window"),this.trigger("enterFullWindow")},n.fullWindowOnEscKey=function(e){v.a.isEventKey(e,"Esc")&&!0===this.isFullscreen()&&(this.isFullWindow?this.exitFullWindow():this.exitFullscreen())},n.exitFullWindow=function(){this.isFullscreen(!1),this.isFullWindow=!1,ur(s.a,"keydown",this.boundFullWindowOnEscKey_),s.a.documentElement.style.overflow=this.docOrigOverflow,En(s.a.body,"vjs-full-window"),this.trigger("exitFullWindow")},n.disablePictureInPicture=function(e){if(void 0===e)return this.techGet_("disablePictureInPicture");this.techCall_("setDisablePictureInPicture",e),this.options_.disablePictureInPicture=e,this.trigger("disablepictureinpicturechanged")},n.isInPictureInPicture=function(e){return void 0!==e?(this.isInPictureInPicture_=!!e,void this.togglePictureInPictureClass_()):!!this.isInPictureInPicture_},n.requestPictureInPicture=function(){if("pictureInPictureEnabled"in s.a&&!1===this.disablePictureInPicture())return this.techGet_("requestPictureInPicture")},n.exitPictureInPicture=function(){if("pictureInPictureEnabled"in s.a)return s.a.exitPictureInPicture()},n.handleKeyDown=function(e){var t=this.options_.userActions;if(t&&t.hotkeys){(function(e){var t=e.tagName.toLowerCase();if(e.isContentEditable)return!0;if("input"===t)return-1===["button","checkbox","hidden","radio","reset","submit"].indexOf(e.type);return-1!==["textarea"].indexOf(t)})(this.el_.ownerDocument.activeElement)||("function"===typeof t.hotkeys?t.hotkeys.call(this,e):this.handleHotkeys(e))}},n.handleHotkeys=function(e){var t=this.options_.userActions?this.options_.userActions.hotkeys:{},n=t.fullscreenKey,r=void 0===n?function(e){return v.a.isEventKey(e,"f")}:n,i=t.muteKey,o=void 0===i?function(e){return v.a.isEventKey(e,"m")}:i,a=t.playPauseKey,c=void 0===a?function(e){return v.a.isEventKey(e,"k")||v.a.isEventKey(e,"Space")}:a;if(r.call(this,e)){e.preventDefault(),e.stopPropagation();var u=Lr.getComponent("FullscreenToggle");!1!==s.a[this.fsApi_.fullscreenEnabled]&&u.prototype.handleClick.call(this,e)}else if(o.call(this,e)){e.preventDefault(),e.stopPropagation(),Lr.getComponent("MuteToggle").prototype.handleClick.call(this,e)}else if(c.call(this,e)){e.preventDefault(),e.stopPropagation(),Lr.getComponent("PlayToggle").prototype.handleClick.call(this,e)}},n.canPlayType=function(e){for(var t,n=0,r=this.options_.techOrder;n1?n.handleSrc_(r.slice(1)):(n.changingSrc_=!1,n.setTimeout((function(){this.error({code:4,message:this.localize(this.options_.notSupportedMessage)})}),0),void n.triggerReady());o=i,a=n.tech_,o.forEach((function(e){return e.setTech&&e.setTech(a)}))})),this.options_.retryOnError&&r.length>1){var i=function(){n.error(null),n.handleSrc_(r.slice(1),!0)},o=function(){n.off("error",i)};this.one("error",i),this.one("playing",o),this.resetRetryOnError_=function(){n.off("error",i),n.off("playing",o)}}}else this.setTimeout((function(){this.error({code:4,message:this.localize(this.options_.notSupportedMessage)})}),0)},n.src=function(e){return this.handleSrc_(e,!1)},n.src_=function(e){var t,n,r=this,i=this.selectSource([e]);return!i||(t=i.tech,n=this.techName_,Ir(t)!==Ir(n)?(this.changingSrc_=!0,this.loadTech_(i.tech,i.source),this.tech_.ready((function(){r.changingSrc_=!1})),!1):(this.ready((function(){this.tech_.constructor.prototype.hasOwnProperty("setSource")?this.techCall_("setSource",e):this.techCall_("src",e.src),this.changingSrc_=!1}),!0),!1))},n.load=function(){this.techCall_("load")},n.reset=function(){var e=this,t=this.options_.Promise||o.a.Promise;this.paused()||!t?this.doReset_():Hr(this.play().then((function(){return e.doReset_()})))},n.doReset_=function(){this.tech_&&this.tech_.clearTracks("text"),this.resetCache_(),this.poster(""),this.loadTech_(this.options_.techOrder[0],null),this.techCall_("reset"),this.resetControlBarUI_(),yr(this)&&this.trigger("playerreset")},n.resetControlBarUI_=function(){this.resetProgressBar_(),this.resetPlaybackRate_(),this.resetVolumeBar_()},n.resetProgressBar_=function(){this.currentTime(0);var e=this.controlBar,t=e.durationDisplay,n=e.remainingTimeDisplay;t&&t.updateContent(),n&&n.updateContent()},n.resetPlaybackRate_=function(){this.playbackRate(this.defaultPlaybackRate()),this.handleTechRateChange_()},n.resetVolumeBar_=function(){this.volume(1),this.trigger("volumechange")},n.currentSources=function(){var e=this.currentSource(),t=[];return 0!==Object.keys(e).length&&t.push(e),this.cache_.sources||t},n.currentSource=function(){return this.cache_.source||{}},n.currentSrc=function(){return this.currentSource()&&this.currentSource().src||""},n.currentType=function(){return this.currentSource()&&this.currentSource().type||""},n.preload=function(e){return void 0!==e?(this.techCall_("setPreload",e),void(this.options_.preload=e)):this.techGet_("preload")},n.autoplay=function(e){if(void 0===e)return this.options_.autoplay||!1;var t;"string"===typeof e&&/(any|play|muted)/.test(e)||!0===e&&this.options_.normalizeAutoplay?(this.options_.autoplay=e,this.manualAutoplay_("string"===typeof e?e:"play"),t=!1):this.options_.autoplay=!!e,t="undefined"===typeof t?this.options_.autoplay:t,this.tech_&&this.techCall_("setAutoplay",t)},n.playsinline=function(e){return void 0!==e?(this.techCall_("setPlaysinline",e),this.options_.playsinline=e,this):this.techGet_("playsinline")},n.loop=function(e){return void 0!==e?(this.techCall_("setLoop",e),void(this.options_.loop=e)):this.techGet_("loop")},n.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"))},n.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"))}},n.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_()))},n.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")))},n.error=function(e){var t=this;if(void 0===e)return this.error_||null;if(Tt("beforeerror").forEach((function(n){var r=n(t,e);Vt(r)&&!Array.isArray(r)||"string"===typeof r||"number"===typeof r||null===r?e=r:t.log.error("please return a value that MediaError expects in beforeerror hooks")})),this.options_.suppressNotSupportedError&&e&&4===e.code){var n=function(){this.error(e)};return this.options_.suppressNotSupportedError=!1,this.any(["click","touchstart"],n),void this.one("loadstart",(function(){this.off(["click","touchstart"],n)}))}if(null===e)return this.error_=e,this.removeClass("vjs-error"),void(this.errorDisplay&&this.errorDisplay.close());this.error_=new qr(e),this.addClass("vjs-error"),Lt.error("(CODE:"+this.error_.code+" "+qr.errorTypes[this.error_.code]+")",this.error_.message,this.error_),this.trigger("error"),Tt("error").forEach((function(e){return e(t,t.error_)}))},n.reportUserActivity=function(e){this.userActivity_=!0},n.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")}},n.listenForUserActivity_=function(){var e,t,n,r=mr(this,this.reportUserActivity),i=function(t){r(),this.clearInterval(e)};this.on("mousedown",(function(){r(),this.clearInterval(e),e=this.setInterval(r,250)})),this.on("mousemove",(function(e){e.screenX===t&&e.screenY===n||(t=e.screenX,n=e.screenY,r())})),this.on("mouseup",i),this.on("mouseleave",i);var o,a=this.getChild("controlBar");!a||dn||$t||(a.on("mouseenter",(function(e){0!==this.player().options_.inactivityTimeout&&(this.player().cache_.inactivityTimeout=this.player().options_.inactivityTimeout),this.player().options_.inactivityTimeout=0})),a.on("mouseleave",(function(e){this.player().options_.inactivityTimeout=this.player().cache_.inactivityTimeout}))),this.on("keydown",r),this.on("keyup",r),this.setInterval((function(){if(this.userActivity_){this.userActivity_=!1,this.userActive(!0),this.clearTimeout(o);var e=this.options_.inactivityTimeout;e<=0||(o=this.setTimeout((function(){this.userActivity_||this.userActive(!1)}),e))}}),250)},n.playbackRate=function(e){if(void 0===e)return this.tech_&&this.tech_.featuresPlaybackRate?this.cache_.lastPlaybackRate||this.techGet_("playbackRate"):1;this.techCall_("setPlaybackRate",e)},n.defaultPlaybackRate=function(e){return void 0!==e?this.techCall_("setDefaultPlaybackRate",e):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("defaultPlaybackRate"):1},n.isAudio=function(e){if(void 0===e)return!!this.isAudio_;this.isAudio_=!!e},n.addTextTrack=function(e,t,n){if(this.tech_)return this.tech_.addTextTrack(e,t,n)},n.addRemoteTextTrack=function(e,t){if(this.tech_)return this.tech_.addRemoteTextTrack(e,t)},n.removeRemoteTextTrack=function(e){void 0===e&&(e={});var t=e.track;if(t||(t=e),this.tech_)return this.tech_.removeRemoteTextTrack(t)},n.getVideoPlaybackQuality=function(){return this.techGet_("getVideoPlaybackQuality")},n.videoWidth=function(){return this.tech_&&this.tech_.videoWidth&&this.tech_.videoWidth()||0},n.videoHeight=function(){return this.tech_&&this.tech_.videoHeight&&this.tech_.videoHeight()||0},n.language=function(e){if(void 0===e)return this.language_;this.language_!==String(e).toLowerCase()&&(this.language_=String(e).toLowerCase(),yr(this)&&this.trigger("languagechange"))},n.languages=function(){return Pr(t.prototype.options_.languages,this.languages_)},n.toJSON=function(){var e=Pr(this.options_),t=e.tracks;e.tracks=[];for(var n=0;n"):function(){}},Ua=function(e,t){var n,r=[];if(e&&e.length)for(n=0;n=t}))},Va=function(e,t){return Ua(e,(function(e){return e-1/30>=t}))},Wa=function(e){var t=[];if(!e||!e.length)return"";for(var n=0;n "+e.end(n));return t.join(", ")},Ha=function(e){for(var t=[],n=0;no||(n+=t>i&&t<=o?o-t:o-i)}return n},Ga=Na.createTimeRange,Xa=function(e){return(e.segments||[]).reduce((function(e,t,n){return t.parts?t.parts.forEach((function(r,i){e.push({duration:r.duration,segmentIndex:n,partIndex:i,part:r,segment:t})})):e.push({duration:t.duration,segmentIndex:n,partIndex:null,segment:t,part:null}),e}),[])},Ya=function(e){var t=e.segments&&e.segments.length&&e.segments[e.segments.length-1];return t&&t.parts||[]},$a=function(e){var t=e.preloadSegment;if(t){var n=t.parts,r=(t.preloadHints||[]).reduce((function(e,t){return e+("PART"===t.type?1:0)}),0);return r+=n&&n.length?n.length:0}},Ja=function(e,t){if(t.endList)return 0;if(e&&e.suggestedPresentationDelay)return e.suggestedPresentationDelay;var n=Ya(t).length>0;return n&&t.serverControl&&t.serverControl.partHoldBack?t.serverControl.partHoldBack:n&&t.partTargetDuration?3*t.partTargetDuration:t.serverControl&&t.serverControl.holdBack?t.serverControl.holdBack:t.targetDuration?3*t.targetDuration:0},Qa=function(e,t,n){if("undefined"===typeof t&&(t=e.mediaSequence+e.segments.length),ti){var a=[i,r];r=a[0],i=a[1]}if(r<0){for(var s=r;sDate.now()},is=function(e){return e.excludeUntil&&e.excludeUntil===1/0},os=function(e){var t=rs(e);return!e.disabled&&!t},as=function(e,t){return t.attributes&&t.attributes[e]},ss=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!!os(e)&&(e.attributes.BANDWIDTH||0)0)for(var f=u-1;f>=0;f--){var h=c[f];if(s+=h.duration,a){if(s<0)continue}else if(s+1/30<=0)continue;return{partIndex:h.partIndex,segmentIndex:h.segmentIndex,startTime:o-ts({defaultDuration:t.targetDuration,durationList:c,startIndex:u,endIndex:f})}}return{partIndex:c[0]&&c[0].partIndex||null,segmentIndex:c[0]&&c[0].segmentIndex||0,startTime:n}}if(u<0){for(var p=u;p<0;p++)if((s-=t.targetDuration)<0)return{partIndex:c[0]&&c[0].partIndex||null,segmentIndex:c[0]&&c[0].segmentIndex||0,startTime:n};u=0}for(var m=u;m0)continue}else if(s-1/30>=0)continue;return{partIndex:g.partIndex,segmentIndex:g.segmentIndex,startTime:o+ts({defaultDuration:t.targetDuration,durationList:c,startIndex:u,endIndex:m})}}return{segmentIndex:c[c.length-1].segmentIndex,partIndex:c[c.length-1].partIndex,startTime:n}},isEnabled:os,isDisabled:function(e){return e.disabled},isBlacklisted:rs,isIncompatible:is,playlistEnd:ns,isAes:function(e){for(var t=0;t-1&&s!==a.length-1&&(n._HLS_part=s),(s>-1||a.length)&&i--}n._HLS_msn=i}if(t.serverControl&&t.serverControl.canSkipUntil&&(n._HLS_skip=t.serverControl.canSkipDateranges?"v2":"YES"),Object.keys(n).length){var c=new o.a.URL(e);["_HLS_skip","_HLS_msn","_HLS_part"].forEach((function(e){n.hasOwnProperty(e)&&c.searchParams.set(e,n[e])})),e=c.toString()}return e}(n,t)),this.state="HAVE_CURRENT_METADATA",this.request=this.vhs_.xhr({uri:n,withCredentials:this.withCredentials},(function(t,n){if(e.request)return t?e.playlistRequestError(e.request,e.media(),"HAVE_METADATA"):void e.haveMetadata({playlistString:e.request.responseText,url:e.media().uri,id:e.media().id})}))}},n.playlistRequestError=function(e,t,n){var r=t.uri,i=t.id;this.request=null,n&&(this.state=n),this.error={playlist:this.master.playlists[i],status:e.status,message:"HLS playlist request error at URL: "+r+".",responseText:e.responseText,code:e.status>=500?4:2},this.trigger("error")},n.parseManifest_=function(e){var t=this,n=e.url;return function(e){var t=e.onwarn,n=e.oninfo,r=e.manifestString,i=e.customTagParsers,o=void 0===i?[]:i,a=e.customTagMappers,s=void 0===a?[]:a,c=e.experimentalLLHLS,u=new W;t&&u.on("warn",t),n&&u.on("info",n),o.forEach((function(e){return u.addParser(e)})),s.forEach((function(e){return u.addTagMapper(e)})),u.push(r),u.end();var l=u.manifest;if(c||(["preloadSegment","skip","serverControl","renditionReports","partInf","partTargetDuration"].forEach((function(e){l.hasOwnProperty(e)&&delete l[e]})),l.segments&&l.segments.forEach((function(e){["parts","preloadHints"].forEach((function(t){e.hasOwnProperty(t)&&delete e[t]}))}))),!l.targetDuration){var d=10;l.segments&&l.segments.length&&(d=l.segments.reduce((function(e,t){return Math.max(e,t.duration)}),0)),t&&t("manifest has no targetDuration defaulting to "+d),l.targetDuration=d}var f=Ya(l);if(f.length&&!l.partTargetDuration){var h=f.reduce((function(e,t){return Math.max(e,t.duration)}),0);t&&(t("manifest has no partTargetDuration defaulting to "+h),fs.error("LL-HLS manifest has parts but lacks required #EXT-X-PART-INF:PART-TARGET value. See https://datatracker.ietf.org/doc/html/draft-pantos-hls-rfc8216bis-09#section-4.4.3.7. Playback is not guaranteed.")),l.partTargetDuration=h}return l}({onwarn:function(e){var r=e.message;return t.logger_("m3u8-parser warn for "+n+": "+r)},oninfo:function(e){var r=e.message;return t.logger_("m3u8-parser info for "+n+": "+r)},manifestString:e.manifestString,customTagParsers:this.customTagParsers,customTagMappers:this.customTagMappers,experimentalLLHLS:this.experimentalLLHLS})},n.haveMetadata=function(e){var t=e.playlistString,n=e.playlistObject,r=e.url,i=e.id;this.request=null,this.state="HAVE_METADATA";var o=n||this.parseManifest_({url:r,manifestString:t});o.lastRequest=Date.now(),ms({playlist:o,uri:r,id:i});var a=ks(this.master,o);this.targetDuration=o.partTargetDuration||o.targetDuration,a?(this.master=a,this.media_=this.master.playlists[i]):this.trigger("playlistunchanged"),this.updateMediaUpdateTimeout_(xs(this.media(),!!a)),this.trigger("loadedplaylist")},n.dispose=function(){this.trigger("dispose"),this.stopRequest(),o.a.clearTimeout(this.mediaUpdateTimeout),o.a.clearTimeout(this.finalRenditionTimeout),this.off()},n.stopRequest=function(){if(this.request){var e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}},n.media=function(e,t){var n=this;if(!e)return this.media_;if("HAVE_NOTHING"===this.state)throw new Error("Cannot switch media playlist from "+this.state);if("string"===typeof e){if(!this.master.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.master.playlists[e]}if(o.a.clearTimeout(this.finalRenditionTimeout),t){var r=(e.partTargetDuration||e.targetDuration)/2*1e3||5e3;this.finalRenditionTimeout=o.a.setTimeout(this.media.bind(this,e,!1),r)}else{var i=this.state,a=!this.media_||e.id!==this.media_.id,s=this.master.playlists[e.id];if(s&&s.endList||e.endList&&e.segments.length)return this.request&&(this.request.onreadystatechange=null,this.request.abort(),this.request=null),this.state="HAVE_METADATA",this.media_=e,void(a&&(this.trigger("mediachanging"),"HAVE_MASTER"===i?this.trigger("loadedmetadata"):this.trigger("mediachange")));if(this.updateMediaUpdateTimeout_(xs(e,!0)),a){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.vhs_.xhr({uri:e.resolvedUri,withCredentials:this.withCredentials},(function(t,r){if(n.request){if(e.lastRequest=Date.now(),e.resolvedUri=za(n.handleManifestRedirects,e.resolvedUri,r),t)return n.playlistRequestError(n.request,e,i);n.haveMetadata({playlistString:r.responseText,url:e.uri,id:e.id}),"HAVE_MASTER"===i?n.trigger("loadedmetadata"):n.trigger("mediachange")}}))}}},n.pause=function(){this.mediaUpdateTimeout&&(o.a.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),this.stopRequest(),"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")},n.load=function(e){var t=this;this.mediaUpdateTimeout&&(o.a.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null);var n=this.media();if(e){var r=n?(n.partTargetDuration||n.targetDuration)/2*1e3:5e3;this.mediaUpdateTimeout=o.a.setTimeout((function(){t.mediaUpdateTimeout=null,t.load()}),r)}else this.started?n&&!n.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist"):this.start()},n.updateMediaUpdateTimeout_=function(e){var t=this;this.mediaUpdateTimeout&&(o.a.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),this.media()&&!this.media().endList&&(this.mediaUpdateTimeout=o.a.setTimeout((function(){t.mediaUpdateTimeout=null,t.trigger("mediaupdatetimeout"),t.updateMediaUpdateTimeout_(e)}),e))},n.start=function(){var e=this;if(this.started=!0,"object"===typeof this.src)return this.src.uri||(this.src.uri=o.a.location.href),this.src.resolvedUri=this.src.uri,void setTimeout((function(){e.setupInitialPlaylist(e.src)}),0);this.request=this.vhs_.xhr({uri:this.src,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.src+".",responseText:n.responseText,code:2},"HAVE_NOTHING"===e.state&&(e.started=!1),e.trigger("error");e.src=za(e.handleManifestRedirects,e.src,n);var r=e.parseManifest_({manifestString:n.responseText,url:e.src});e.setupInitialPlaylist(r)}}))},n.srcUri=function(){return"string"===typeof this.src?this.src:this.src.uri},n.setupInitialPlaylist=function(e){if(this.state="HAVE_MASTER",e.playlists)return this.master=e,gs(this.master,this.srcUri()),e.playlists.forEach((function(e){e.segments=Ss(e),e.segments.forEach((function(t){ws(t,e.resolvedUri)}))})),this.trigger("loadedplaylist"),void(this.request||this.media(this.master.playlists[0]));var t=this.srcUri()||o.a.location.href;this.master=function(e,t){var n=hs(0,t),r={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:o.a.location.href,resolvedUri:o.a.location.href,playlists:[{uri:t,id:n,resolvedUri:t,attributes:{}}]};return r.playlists[n]=r.playlists[0],r.playlists[t]=r.playlists[0],r}(0,t),this.haveMetadata({playlistObject:e,url:t,id:this.master.playlists[0].id}),this.trigger("loadedmetadata")},t}(bs),Os=Na.xhr,Ms=Na.mergeOptions,Cs=function(e,t,n,r){var i="arraybuffer"===e.responseType?e.response:e.responseText;!t&&i&&(e.responseTime=Date.now(),e.roundTripTime=e.responseTime-e.requestTime,e.bytesReceived=i.byteLength||i.length,e.bandwidth||(e.bandwidth=Math.floor(e.bytesReceived/e.roundTripTime*8*1e3))),n.headers&&(e.responseHeaders=n.headers),t&&"ETIMEDOUT"===t.code&&(e.timedout=!0),t||e.aborted||200===n.statusCode||206===n.statusCode||0===n.statusCode||(t=new Error("XHR Failed with a response of: "+(e&&(i||e.responseText)))),r(t,e)},Ts=function(){var e=function e(t,n){t=Ms({timeout:45e3},t);var r=e.beforeRequest||Na.Vhs.xhr.beforeRequest;if(r&&"function"===typeof r){var i=r(t);i&&(t=i)}var o=(!0===Na.Vhs.xhr.original?Os:Na.Vhs.xhr)(t,(function(e,t){return Cs(o,e,t,n)})),a=o.abort;return o.abort=function(){return o.aborted=!0,a.apply(o,arguments)},o.uri=t.uri,o.requestTime=Date.now(),o};return e.original=!0,e},As=function(e){var t={};return e.byterange&&(t.Range=function(e){var t=e.offset+e.length-1;return"bytes="+e.offset+"-"+t}(e.byterange)),t},Is=function(e,t){return e.start(t)+"-"+e.end(t)},Ps=function(e,t){var n=e.toString(16);return"00".substring(0,2-n.length)+n+(t%2?" ":"")},Rs=function(e){return e>=32&&e<126?String.fromCharCode(e):"."},Ds=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},Ns=function(e){var t=e.byterange||{length:1/0,offset:0};return[t.length,t.offset,e.resolvedUri].join(",")},js=function(e){return e.resolvedUri},Ls=function(e){for(var t=Array.prototype.slice.call(e),n="",r=0;rr){if(e>r+.25*o.duration)return null;n=o}return{segment:n,estimatedStart:n.videoTimingInfo?n.videoTimingInfo.transmuxedPresentationStart:r-n.duration,type:n.videoTimingInfo?"accurate":"estimate"}}(r,t);if(!o)return i({message:"valid programTime was not found"});if("estimate"===o.type)return i({message:"Accurate programTime could not be determined. Please seek to e.seekTime and try again",seekTime:o.estimatedStart});var a={mediaSeconds:r},s=function(e,t){if(!t.dateTimeObject)return null;var n=t.videoTimingInfo.transmuxerPrependedSeconds,r=e-(t.videoTimingInfo.transmuxedPresentationStart+n);return new Date(t.dateTimeObject.getTime()+1e3*r)}(r,o.segment);return s&&(a.programDateTime=s.toISOString()),i(null,a)},Fs=function e(t){var n=t.programTime,r=t.playlist,i=t.retryCount,o=void 0===i?2:i,a=t.seekTo,s=t.pauseAfterSeek,c=void 0===s||s,u=t.tech,l=t.callback;if(!l)throw new Error("seekToProgramTime: callback must be provided");if("undefined"===typeof n||!r||!a)return l({message:"seekToProgramTime: programTime, seekTo and playlist must be provided"});if(!r.endList&&!u.hasStarted_)return l({message:"player must be playing a live stream to start buffering"});if(!function(e){if(!e.segments||0===e.segments.length)return!1;for(var t=0;tnew Date(s.getTime()+1e3*c)?null:(n>s&&(r=a),{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:ds.duration(t,t.mediaSequence+t.segments.indexOf(r)),type:r.videoTimingInfo?"accurate":"estimate"})}(n,r);if(!d)return l({message:n+" was not found in the stream"});var f=d.segment,h=function(e,t){var n,r;try{n=new Date(e),r=new Date(t)}catch(o){}var i=n.getTime();return(r.getTime()-i)/1e3}(f.dateTimeObject,n);if("estimate"===d.type)return 0===o?l({message:n+" is not buffered yet. Try again"}):(a(d.estimatedStart+h),void u.one("seeked",(function(){e({programTime:n,playlist:r,retryCount:o-1,seekTo:a,pauseAfterSeek:c,tech:u,callback:l})})));var p=f.start+h;u.one("seeked",(function(){return l(null,u.currentTime())})),c&&u.pause(),a(p)},Us=function(e,t){if(4===e.readyState)return t()},qs=function(e,t,n){var r,i=[],o=!1,a=function(e,t,r,i){return t.abort(),o=!0,n(e,t,r,i)},s=function(e,t){if(!o){if(e)return a(e,t,"",i);var n=t.responseText.substring(i&&i.byteLength||0,t.responseText.length);if(i=function(){for(var e=arguments.length,t=new Array(e),n=0;n=l+u)return s(t,{response:o.subarray(u,u+l),status:n.status,uri:n.uri});r.request=r.vhs_.xhr({uri:a,responseType:"arraybuffer",headers:As({byterange:e.sidx.byterange})},s)}))}else this.mediaRequest_=o.a.setTimeout((function(){return n(!1)}),0)},n.dispose=function(){this.trigger("dispose"),this.stopRequest(),this.loadedPlaylists_={},o.a.clearTimeout(this.minimumUpdatePeriodTimeout_),o.a.clearTimeout(this.mediaRequest_),o.a.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.mediaRequest_=null,this.minimumUpdatePeriodTimeout_=null,this.masterPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.masterPlaylistLoader_.createMupOnMedia_),this.masterPlaylistLoader_.createMupOnMedia_=null),this.off()},n.hasPendingRequest=function(){return this.request||this.mediaRequest_},n.stopRequest=function(){if(this.request){var e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}},n.media=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.masterPlaylistLoader_.master.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.masterPlaylistLoader_.master.playlists[e]}var r=!this.media_||e.id!==this.media_.id;if(r&&this.loadedPlaylists_[e.id]&&this.loadedPlaylists_[e.id].endList)return this.state="HAVE_METADATA",this.media_=e,void(r&&(this.trigger("mediachanging"),this.trigger("mediachange")));r&&(this.media_&&this.trigger("mediachanging"),this.addSidxSegments_(e,n,(function(r){t.haveMetadata({startingState:n,playlist:e})})))},n.haveMetadata=function(e){var t=e.startingState,n=e.playlist;this.state="HAVE_METADATA",this.loadedPlaylists_[n.id]=n,this.mediaRequest_=null,this.refreshMedia_(n.id),"HAVE_MASTER"===t?this.trigger("loadedmetadata"):this.trigger("mediachange")},n.pause=function(){this.masterPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.masterPlaylistLoader_.createMupOnMedia_),this.masterPlaylistLoader_.createMupOnMedia_=null),this.stopRequest(),o.a.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.isMaster_&&(o.a.clearTimeout(this.masterPlaylistLoader_.minimumUpdatePeriodTimeout_),this.masterPlaylistLoader_.minimumUpdatePeriodTimeout_=null),"HAVE_NOTHING"===this.state&&(this.started=!1)},n.load=function(e){var t=this;o.a.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null;var n=this.media();if(e){var r=n?n.targetDuration/2*1e3:5e3;this.mediaUpdateTimeout=o.a.setTimeout((function(){return t.load()}),r)}else this.started?n&&!n.endList?(this.isMaster_&&!this.minimumUpdatePeriodTimeout_&&(this.trigger("minimumUpdatePeriod"),this.updateMinimumUpdatePeriodTimeout_()),this.trigger("mediaupdatetimeout")):this.trigger("loadedplaylist"):this.start()},n.start=function(){var e=this;this.started=!0,this.isMaster_?this.requestMaster_((function(t,n){e.haveMaster_(),e.hasPendingRequest()||e.media_||e.media(e.masterPlaylistLoader_.master.playlists[0])})):this.mediaRequest_=o.a.setTimeout((function(){return e.haveMaster_()}),0)},n.requestMaster_=function(e){var t=this;this.request=this.vhs_.xhr({uri:this.masterPlaylistLoader_.srcUrl,withCredentials:this.withCredentials},(function(n,r){if(!t.requestErrored_(n,r)){var i=r.responseText!==t.masterPlaylistLoader_.masterXml_;return t.masterPlaylistLoader_.masterXml_=r.responseText,r.responseHeaders&&r.responseHeaders.date?t.masterLoaded_=Date.parse(r.responseHeaders.date):t.masterLoaded_=Date.now(),t.masterPlaylistLoader_.srcUrl=za(t.handleManifestRedirects,t.masterPlaylistLoader_.srcUrl,r),i?(t.handleMaster_(),void t.syncClientServerClock_((function(){return e(r,i)}))):e(r,i)}"HAVE_NOTHING"===t.state&&(t.started=!1)}))},n.syncClientServerClock_=function(e){var t=this,n=Ge(this.masterPlaylistLoader_.masterXml_);return null===n?(this.masterPlaylistLoader_.clientOffset_=this.masterLoaded_-Date.now(),e()):"DIRECT"===n.method?(this.masterPlaylistLoader_.clientOffset_=n.value-Date.now(),e()):void(this.request=this.vhs_.xhr({uri:Ba(this.masterPlaylistLoader_.srcUrl,n.value),method:n.method,withCredentials:this.withCredentials},(function(r,i){if(t.request){if(r)return t.masterPlaylistLoader_.clientOffset_=t.masterLoaded_-Date.now(),e();var o;o="HEAD"===n.method?i.responseHeaders&&i.responseHeaders.date?Date.parse(i.responseHeaders.date):t.masterLoaded_:Date.parse(i.responseText),t.masterPlaylistLoader_.clientOffset_=o-Date.now(),e()}})))},n.haveMaster_=function(){this.state="HAVE_MASTER",this.isMaster_?this.trigger("loadedplaylist"):this.media_||this.media(this.childPlaylist_)},n.handleMaster_=function(){this.mediaRequest_=null;var e=function(e){var t=e.masterXml,n=e.srcUrl,r=e.clientOffset,i=e.sidxMapping,o=Ze(t,{manifestUri:n,clientOffset:r,sidxMapping:i});return gs(o,n),o}({masterXml:this.masterPlaylistLoader_.masterXml_,srcUrl:this.masterPlaylistLoader_.srcUrl,clientOffset:this.masterPlaylistLoader_.clientOffset_,sidxMapping:this.masterPlaylistLoader_.sidxMapping_}),t=this.masterPlaylistLoader_.master;t&&(e=function(e,t,n){for(var r=!0,i=Ws(e,{duration:t.duration,minimumUpdatePeriod:t.minimumUpdatePeriod}),o=0;o-1)},this.trigger=function(t){var n,r,i,o;if(n=e[t])if(2===arguments.length)for(i=n.length,r=0;r>>1,e.samplingfrequencyindex<<7|e.channelcount<<3,6,1,2]))},i=function(){return t(k.ftyp,x,E,x,O)},g=function(e){return t(k.hdlr,T[e])},o=function(e){return t(k.mdat,e)},m=function(e){var n=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&&(n[12]=e.samplerate>>>24&255,n[13]=e.samplerate>>>16&255,n[14]=e.samplerate>>>8&255,n[15]=255&e.samplerate),t(k.mdhd,n)},p=function(e){return t(k.mdia,m(e),g(e.type),s(e))},a=function(e){return t(k.mfhd,new Uint8Array([0,0,0,0,(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e]))},s=function(e){return t(k.minf,"video"===e.type?t(k.vmhd,A):t(k.smhd,I),n(),b(e))},c=function(e,n){for(var r=[],i=n.length;i--;)r[i]=w(n[i]);return t.apply(null,[k.moof,a(e)].concat(r))},u=function(e){for(var n=e.length,r=[];n--;)r[n]=f(e[n]);return t.apply(null,[k.moov,d(4294967295)].concat(r).concat(l(e)))},l=function(e){for(var n=e.length,r=[];n--;)r[n]=S(e[n]);return t.apply(null,[k.mvex].concat(r))},d=function(e){var n=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 t(k.mvhd,n)},v=function(e){var n,r,i=e.samples||[],o=new Uint8Array(4+i.length);for(r=0;r>>8),a.push(255&i[n].byteLength),a=a.concat(Array.prototype.slice.call(i[n]));for(n=0;n>>8),s.push(255&o[n].byteLength),s=s.concat(Array.prototype.slice.call(o[n]));if(r=[k.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]),t(k.avcC,new Uint8Array([1,e.profileIdc,e.profileCompatibility,e.levelIdc,255].concat([i.length],a,[o.length],s))),t(k.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192]))],e.sarRatio){var c=e.sarRatio[0],u=e.sarRatio[1];r.push(t(k.pasp,new Uint8Array([(4278190080&c)>>24,(16711680&c)>>16,(65280&c)>>8,255&c,(4278190080&u)>>24,(16711680&u)>>16,(65280&u)>>8,255&u])))}return t.apply(null,r)},n=function(e){return t(k.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]),r(e))}}(),h=function(e){var n=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 t(k.tkhd,n)},w=function(e){var n,r,i,o,a,s;return n=t(k.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])),a=Math.floor(e.baseMediaDecodeTime/(B+1)),s=Math.floor(e.baseMediaDecodeTime%(B+1)),r=t(k.tfdt,new Uint8Array([1,0,0,0,a>>>24&255,a>>>16&255,a>>>8&255,255&a,s>>>24&255,s>>>16&255,s>>>8&255,255&s])),92,"audio"===e.type?(i=_(e,92),t(k.traf,n,r,i)):(o=v(e),i=_(e,o.length+92),t(k.traf,n,r,i,o))},f=function(e){return e.duration=e.duration||4294967295,t(k.trak,h(e),p(e))},S=function(e){var n=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&&(n[n.length-1]=0),t(k.trex,n)},function(){var e,n,r;r=function(e,t){var n=0,r=0,i=0,o=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&&(o=8)),[0,0,n|r|i|o,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(e,n){var i,o,a,s,c,u;for(n+=20+16*(s=e.samples||[]).length,a=r(s,n),(o=new Uint8Array(a.length+16*s.length)).set(a),i=a.length,u=0;u>>24,o[i++]=(16711680&c.duration)>>>16,o[i++]=(65280&c.duration)>>>8,o[i++]=255&c.duration,o[i++]=(4278190080&c.size)>>>24,o[i++]=(16711680&c.size)>>>16,o[i++]=(65280&c.size)>>>8,o[i++]=255&c.size,o[i++]=c.flags.isLeading<<2|c.flags.dependsOn,o[i++]=c.flags.isDependedOn<<6|c.flags.hasRedundancy<<4|c.flags.paddingValue<<1|c.flags.isNonSyncSample,o[i++]=61440&c.flags.degradationPriority,o[i++]=15&c.flags.degradationPriority,o[i++]=(4278190080&c.compositionTimeOffset)>>>24,o[i++]=(16711680&c.compositionTimeOffset)>>>16,o[i++]=(65280&c.compositionTimeOffset)>>>8,o[i++]=255&c.compositionTimeOffset;return t(k.trun,o)},e=function(e,n){var i,o,a,s,c,u;for(n+=20+8*(s=e.samples||[]).length,a=r(s,n),(i=new Uint8Array(a.length+8*s.length)).set(a),o=a.length,u=0;u>>24,i[o++]=(16711680&c.duration)>>>16,i[o++]=(65280&c.duration)>>>8,i[o++]=255&c.duration,i[o++]=(4278190080&c.size)>>>24,i[o++]=(16711680&c.size)>>>16,i[o++]=(65280&c.size)>>>8,i[o++]=255&c.size;return t(k.trun,i)},_=function(t,r){return"audio"===t.type?e(t,r):n(t,r)}}();var z,F,U,q,V,W,H,K,Z=o,G=c,X=function(e){var t,n=i(),r=u(e);return(t=new Uint8Array(n.byteLength+r.byteLength)).set(n),t.set(r,n.byteLength),t},Y=function(e,t){var n={size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}};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},$=function(e){var t,n,r=[],i=[];for(i.byteLength=0,i.nalCount=0,i.duration=0,r.byteLength=0,t=0;t1&&(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},ee=function(e,t){var n,r,i,o,a,s=t||0,c=[];for(n=0;nae/2))){for((a=oe()[e.samplerate])||(a=t[0].data),s=0;s=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)})))},pe=function(e){var t,n,r=[];for(t=0;t=this.virtualRowCount&&"function"===typeof this.beforeRowOverflow&&this.beforeRowOverflow(e),this.rows.length>0&&(this.rows.push(""),this.rowIdx++);this.rows.length>this.virtualRowCount;)this.rows.shift(),this.rowIdx--},Ce.prototype.isEmpty=function(){return 0===this.rows.length||1===this.rows.length&&""===this.rows[0]},Ce.prototype.addText=function(e){this.rows[this.rowIdx]+=e},Ce.prototype.backspace=function(){if(!this.isEmpty()){var e=this.rows[this.rowIdx];this.rows[this.rowIdx]=e.substr(0,e.length-1)}};var Te=function(e,t,n){this.serviceNum=e,this.text="",this.currentWindow=new Ce(-1),this.windows=[],this.stream=n,"string"===typeof t&&this.createTextDecoder(t)};Te.prototype.init=function(e,t){this.startPts=e;for(var n=0;n<8;n++)this.windows[n]=new Ce(n),"function"===typeof t&&(this.windows[n].beforeRowOverflow=t)},Te.prototype.setCurrentWindow=function(e){this.currentWindow=this.windows[e]},Te.prototype.createTextDecoder=function(e){if("undefined"===typeof TextDecoder)this.stream.trigger("log",{level:"warn",message:"The `encoding` option is unsupported without TextDecoder support"});else try{this.textDecoder_=new TextDecoder(e)}catch(t){this.stream.trigger("log",{level:"warn",message:"TextDecoder could not be created with "+e+" encoding. "+t})}};var Ae=function e(t){t=t||{},e.prototype.init.call(this);var n,r=this,i=t.captionServices||{},o={};Object.keys(i).forEach((function(e){n=i[e],/^SERVICE/.test(e)&&(o[e]=n.encoding)})),this.serviceEncodings=o,this.current708Packet=null,this.services={},this.push=function(e){3===e.type?(r.new708Packet(),r.add708Bytes(e)):(null===r.current708Packet&&r.new708Packet(),r.add708Bytes(e))}};Ae.prototype=new L,Ae.prototype.new708Packet=function(){null!==this.current708Packet&&this.push708Packet(),this.current708Packet={data:[],ptsVals:[]}},Ae.prototype.add708Bytes=function(e){var t=e.ccData,n=t>>>8,r=255&t;this.current708Packet.ptsVals.push(e.pts),this.current708Packet.data.push(n),this.current708Packet.data.push(r)},Ae.prototype.push708Packet=function(){var e=this.current708Packet,t=e.data,n=null,r=null,i=0,o=t[i++];for(e.seq=o>>6,e.sizeCode=63&o;i>5)&&r>0&&(n=o=t[i++]),this.pushServiceBlock(n,i,r),r>0&&(i+=r-1)},Ae.prototype.pushServiceBlock=function(e,t,n){var r,i=t,o=this.current708Packet.data,a=this.services[e];for(a||(a=this.initService(e,i));i>5,o.rowLock=(16&r)>>4,o.columnLock=(8&r)>>3,o.priority=7&r,r=n[++e],o.relativePositioning=(128&r)>>7,o.anchorVertical=127&r,r=n[++e],o.anchorHorizontal=r,r=n[++e],o.anchorPoint=(240&r)>>4,o.rowCount=15&r,r=n[++e],o.columnCount=63&r,r=n[++e],o.windowStyle=(56&r)>>3,o.penStyle=7&r,o.virtualRowCount=o.rowCount+1,e},Ae.prototype.setWindowAttributes=function(e,t){var n=this.current708Packet.data,r=n[e],i=t.currentWindow.winAttr;return r=n[++e],i.fillOpacity=(192&r)>>6,i.fillRed=(48&r)>>4,i.fillGreen=(12&r)>>2,i.fillBlue=3&r,r=n[++e],i.borderType=(192&r)>>6,i.borderRed=(48&r)>>4,i.borderGreen=(12&r)>>2,i.borderBlue=3&r,r=n[++e],i.borderType+=(128&r)>>5,i.wordWrap=(64&r)>>6,i.printDirection=(48&r)>>4,i.scrollDirection=(12&r)>>2,i.justify=3&r,r=n[++e],i.effectSpeed=(240&r)>>4,i.effectDirection=(12&r)>>2,i.displayEffect=3&r,e},Ae.prototype.flushDisplayed=function(e,t){for(var n=[],r=0;r<8;r++)t.windows[r].visible&&!t.windows[r].isEmpty()&&n.push(t.windows[r].getText());t.endPts=e,t.text=n.join("\n\n"),this.pushCaption(t),t.startPts=e},Ae.prototype.pushCaption=function(e){""!==e.text&&(this.trigger("data",{startPts:e.startPts,endPts:e.endPts,text:e.text,stream:"cc708_"+e.serviceNum}),e.text="",e.startPts=e.endPts)},Ae.prototype.displayWindows=function(e,t){var n=this.current708Packet.data[++e],r=this.getPts(e);this.flushDisplayed(r,t);for(var i=0;i<8;i++)n&1<>4,i.offset=(12&r)>>2,i.penSize=3&r,r=n[++e],i.italics=(128&r)>>7,i.underline=(64&r)>>6,i.edgeType=(56&r)>>3,i.fontStyle=7&r,e},Ae.prototype.setPenColor=function(e,t){var n=this.current708Packet.data,r=n[e],i=t.currentWindow.penColor;return r=n[++e],i.fgOpacity=(192&r)>>6,i.fgRed=(48&r)>>4,i.fgGreen=(12&r)>>2,i.fgBlue=3&r,r=n[++e],i.bgOpacity=(192&r)>>6,i.bgRed=(48&r)>>4,i.bgGreen=(12&r)>>2,i.bgBlue=3&r,r=n[++e],i.edgeRed=(48&r)>>4,i.edgeGreen=(12&r)>>2,i.edgeBlue=3&r,e},Ae.prototype.setPenLocation=function(e,t){var n=this.current708Packet.data,r=n[e],i=t.currentWindow.penLoc;return t.currentWindow.pendingNewLine=!0,r=n[++e],i.row=15&r,r=n[++e],i.column=63&r,e},Ae.prototype.reset=function(e,t){var n=this.getPts(e);return this.flushDisplayed(n,t),this.initService(t.serviceNum,e)};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},Ne=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,o;if((t=32639&e.ccData)!==this.lastControlCode_){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))o=Pe((r=(3&r)<<8)|i),this[this.mode_](e.pts,o),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),o=Pe((r=(3&r)<<8)|i),this[this.mode_](e.pts,o),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 a=Re.indexOf(7968&t);"rollUp"===this.mode_&&(a-this.rollUpRows_+1<0&&(a=this.rollUpRows_-1),this.setRollUp(e.pts,a)),a!==this.row_&&(this.clearFormatting(e.pts),this.row_=a),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),o=Pe(r),o+=Pe(i),this[this.mode_](e.pts,o),this.column_+=o.length)}else this.lastControlCode_=null}};Ne.prototype=new L,Ne.prototype.flushDisplayed=function(e){var t=this.displayed_.map((function(e,t){try{return e.trim()}catch(n){return this.trigger("log",{level:"warn",message:"Skipping a malformed 608 caption at index "+t+"."}),""}}),this).join("\n").replace(/^\n+|\n+$/g,"");t.length&&this.trigger("data",{startPts:this.startPts_,endPts:e,text:t,stream:this.name_})},Ne.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_=[]},Ne.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_},Ne.prototype.isSpecialCharacter=function(e,t){return e===this.EXT_&&t>=48&&t<=63},Ne.prototype.isExtCharacter=function(e,t){return(e===this.EXT_+1||e===this.EXT_+2)&&t>=32&&t<=63},Ne.prototype.isMidRowCode=function(e,t){return e===this.EXT_&&t>=32&&t<=47},Ne.prototype.isOffsetControlCode=function(e,t){return e===this.OFFSET_&&t>=33&&t<=35},Ne.prototype.isPAC=function(e,t){return e>=this.BASE_&&e=64&&t<=127},Ne.prototype.isColorPAC=function(e){return e>=64&&e<=79||e>=96&&e<=127},Ne.prototype.isNormalChar=function(e){return e>=32&&e<=127},Ne.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[this.mode_](e,n)},Ne.prototype.clearFormatting=function(e){if(this.formatting_.length){var t=this.formatting_.reverse().reduce((function(e,t){return e+""}),"");this.formatting_=[],this[this.mode_](e,t)}},Ne.prototype.popOn=function(e,t){var n=this.nonDisplayed_[this.row_];n+=t,this.nonDisplayed_[this.row_]=n},Ne.prototype.rollUp=function(e,t){var n=this.displayed_[this.row_];n+=t,this.displayed_[this.row_]=n},Ne.prototype.shiftRowsUp_=function(){var e;for(e=0;et&&(n=-1);Math.abs(t-e)>4294967296;)e+=8589934592*n;return e},ze=function e(t){var n,r;e.prototype.init.call(this),this.type_=t||"shared",this.push=function(e){"shared"!==this.type_&&e.type!==this.type_||(void 0===r&&(r=e.dts),e.dts=Be(e.dts,r),e.pts=Be(e.pts,r),n=e.dts,this.trigger("data",e))},this.flush=function(){r=n,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.discontinuity=function(){r=void 0,n=void 0},this.reset=function(){this.discontinuity(),this.trigger("reset")}};ze.prototype=new L;var Fe,Ue=ze,qe=Be,Ve=function(e,t,n){var r,i="";for(r=t;r>>2;l*=4,l+=3&u[7],s.timeStamp=l,void 0===t.pts&&void 0===t.dts&&(t.pts=s.timeStamp,t.dts=s.timeStamp),this.trigger("timestamp",s)}t.frames.push(s),n+=10,n+=a}while(n>>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=Le.H264_STREAM_TYPE:n.pid===this.programMapTable.audio?n.streamType=Le.ADTS_STREAM_TYPE:n.streamType=this.programMapTable["timed-metadata"][n.pid],n.type="pes",n.data=e.subarray(t),this.trigger("data",n)}}).prototype=new L,Ge.STREAM_TYPES={h264:27,adts:15},(Xe=function(){var e,t=this,n=!1,r={data:[],size:0},i={data:[],size:0},o={data:[],size:0},a=function(e,n,r){var i,o,a=new Uint8Array(e.size),s={type:n},c=0,u=0;if(e.data.length&&!(e.size<9)){for(s.trackId=e.data[0].pid,c=0;c>>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,s),i="video"===n||s.packetLength<=e.size,(r||i)&&(e.size=0,e.data.length=0),i&&t.trigger("data",s)}};Xe.prototype.init.call(this),this.push=function(s){({pat:function(){},pes:function(){var e,t;switch(s.streamType){case Le.H264_STREAM_TYPE:e=r,t="video";break;case Le.ADTS_STREAM_TYPE:e=i,t="audio";break;case Le.METADATA_STREAM_TYPE:e=o,t="timed-metadata";break;default:return}s.payloadUnitStartIndicator&&a(e,t,!0),e.data.push(s),e.size+=s.data.byteLength},pmt:function(){var r={type:"metadata",tracks:[]};null!==(e=s.programMapTable).video&&r.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+e.video,codec:"avc",type:"video"}),null!==e.audio&&r.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+e.audio,codec:"adts",type:"audio"}),n=!0,t.trigger("data",r)}})[s.type]()},this.reset=function(){r.size=0,r.data.length=0,i.size=0,i.data.length=0,this.trigger("reset")},this.flushStreams_=function(){a(r,"video"),a(i,"audio"),a(o,"timed-metadata")},this.flush=function(){if(!n&&e){var r={type:"metadata",tracks:[]};null!==e.video&&r.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+e.video,codec:"avc",type:"video"}),null!==e.audio&&r.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+e.audio,codec:"adts",type:"audio"}),t.trigger("data",r)}n=!1,this.flushStreams_(),this.trigger("done")}}).prototype=new L;var Je={PAT_PID:0,MP2T_PACKET_LENGTH:188,TransportPacketStream:Ze,TransportParseStream:Ge,ElementaryStream:Xe,TimestampRolloverStream:$e,CaptionStream:je.CaptionStream,Cea608Stream:je.Cea608Stream,Cea708Stream:je.Cea708Stream,MetadataStream:Ye};for(var Qe in Le)Le.hasOwnProperty(Qe)&&(Je[Qe]=Le[Qe]);var et,tt=Je,nt=ae,rt=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];(et=function(e){var t,n=0;et.prototype.init.call(this),this.skipWarn_=function(e,t){this.trigger("log",{level:"warn",message:"adts skiping bytes "+e+" to "+t+" in frame "+n+" outside syncword"})},this.push=function(r){var i,o,a,s,c,u=0;if(e||(n=0),"audio"===r.type){var l;for(t&&t.length?(a=t,(t=new Uint8Array(a.byteLength+r.data.byteLength)).set(a),t.set(r.data,a.byteLength)):t=r.data;u+7>5,c=(s=1024*(1+(3&t[u+6])))*nt/rt[(60&t[u+2])>>>2],t.byteLength-u>>6&3),channelcount:(1&t[u+2])<<2|(192&t[u+3])>>>6,samplerate:rt[(60&t[u+2])>>>2],samplingfrequencyindex:(60&t[u+2])>>>2,samplesize:16,data:t.subarray(u+7+o,u+i)}),n++,u+=i}else"number"!==typeof l&&(l=u),u++;"number"===typeof l&&(this.skipWarn_(l,u),l=null),t=t.subarray(u)}},this.flush=function(){n=0,this.trigger("done")},this.reset=function(){t=void 0,this.trigger("reset")},this.endTimeline=function(){t=void 0,this.trigger("endedtimeline")}}).prototype=new L;var it,ot,at,st=et,ct=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,o=new Uint8Array(4),a=Math.min(4,t);if(0===a)throw new Error("no bytes available");o.set(e.subarray(i,i+a)),n=new DataView(o.buffer).getUint32(0),r=8*a,t-=a},this.skipBits=function(e){var i;r>e?(n<<=e,r-=e):(e-=r,e-=8*(i=Math.floor(e/8)),t-=i,this.loadWord(),n<<=e,r-=e)},this.readBits=function(e){var i=Math.min(r,e),o=n>>>32-i;return(r-=i)>0?n<<=i:t>0&&this.loadWord(),(i=e-i)>0?o<>>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()};(ot=function(){var e,t,n=0;ot.prototype.init.call(this),this.push=function(r){var i;t?((i=new Uint8Array(t.byteLength+r.data.byteLength)).set(t),i.set(r.data,t.byteLength),t=i):t=r.data;for(var o=t.byteLength;n3&&this.trigger("data",t.subarray(n+3)),t=null,n=0,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")}}).prototype=new L,at={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},(it=function(){var e,t,n,r,i,o,a,s=new ot;it.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(a){var s={trackId:t,pts:n,dts:r,data:a,nalUnitTypeCode:31&a[0]};switch(s.nalUnitTypeCode){case 5:s.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:s.nalUnitType="sei_rbsp",s.escapedRBSP=i(a.subarray(1));break;case 7:s.nalUnitType="seq_parameter_set_rbsp",s.escapedRBSP=i(a.subarray(1)),s.config=o(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")})),s.on("partialdone",(function(){e.trigger("partialdone")})),s.on("reset",(function(){e.trigger("reset")})),s.on("endedtimeline",(function(){e.trigger("endedtimeline")})),this.flush=function(){s.flush()},this.partialFlush=function(){s.partialFlush()},this.reset=function(){s.reset()},this.endTimeline=function(){s.endTimeline()},a=function(e,t){var n,r=8,i=8;for(n=0;n=0?n:0,(16&e[t+5])>>4?n+20:n+10},ht=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]},pt={isLikelyAacData:function(e){var t=function e(t,n){return t.length-n<10||t[n]!=="I".charCodeAt(0)||t[n+1]!=="D".charCodeAt(0)||t[n+2]!=="3".charCodeAt(0)?n:e(t,n+=ft(t,n))}(e,0);return e.length>=t+2&&255===(255&e[t])&&240===(240&e[t+1])&&16===(22&e[t+1])},parseId3TagSize:ft,parseAdtsSize:function(e,t){var n=(224&e[t+5])>>5,r=e[t+4]<<3;return 6144&e[t+3]|r|n},parseType: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},parseSampleRate:function(e){for(var t=0;t+5>>2];t++}return null},parseAacTimestamp:function(e){var t,n,r;t=10,64&e[5]&&(t+=4,t+=ht(e.subarray(10,14)));do{if((n=ht(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>>2;return a*=4,a+=3&o[7]}break}}t+=10,t+=n}while(t=3;)if(e[c]!=="I".charCodeAt(0)||e[c+1]!=="D".charCodeAt(0)||e[c+2]!=="3".charCodeAt(0))if(255!==(255&e[c])||240!==(240&e[c+1]))c++;else{if(e.length-c<7)break;if(c+(s=pt.parseAdtsSize(e,c))>e.length)break;o={type:"audio",data:e.subarray(c,c+s),pts:t,dts:t},this.trigger("data",o),c+=s}else{if(e.length-c<10)break;if(c+(s=pt.parseId3TagSize(e,c))>e.length)break;i={type:"timed-metadata",data:e.subarray(c,c+s)},this.trigger("data",i),c+=s}r=e.length-c,e=r>0?e.subarray(c):new Uint8Array},this.reset=function(){e=new Uint8Array,this.trigger("reset")},this.endTimeline=function(){e=new Uint8Array,this.trigger("endedtimeline")}}).prototype=new L;var mt,gt,vt,bt,yt=ut,wt=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],St=["width","height","profileIdc","levelIdc","profileCompatibility","sarRatio"],_t=lt.H264Stream,kt=pt.isLikelyAacData,xt=ae,Et=function(e,t){var n;if(e.length!==t.length)return!1;for(n=0;n=-1e4&&n<=45e3&&(!r||s>n)&&(r=o,s=n));return r?r.gop:null},this.alignGopsAtStart_=function(e){var t,n,r,i,o,s,c,u;for(o=e.byteLength,s=e.nalCount,c=e.duration,t=n=0;tr.pts?t++:(n++,o-=i.byteLength,s-=i.nalCount,c-=i.duration);return 0===n?e:n===e.length?null:((u=e.slice(n)).byteLength=o,u.duration=c,u.nalCount=s,u.pts=u[0].pts,u.dts=u[0].dts,u)},this.alignGopsAtEnd_=function(e){var t,n,r,i,o,s,c;for(t=a.length-1,n=e.length-1,o=null,s=!1;t>=0&&n>=0;){if(r=a[t],i=e[n],r.pts===i.pts){s=!0;break}r.pts>i.pts?t--:(t===a.length-1&&(o=n),n--)}if(!s&&null===o)return null;if(0===(c=s?n:o))return e;var u=e.slice(c),l=u.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 u.byteLength=l.byteLength,u.duration=l.duration,u.nalCount=l.nalCount,u.pts=u[0].pts,u.dts=u[0].dts,u},this.alignGopsWith=function(e){a=e}}).prototype=new L,(bt=function(e,t){this.numberOfTracks=0,this.metadataStream=t,"undefined"!==typeof(e=e||{}).remux?this.remuxTracks=!!e.remux:this.remuxTracks=!0,"boolean"===typeof e.keepOriginalTimestamps?this.keepOriginalTimestamps=e.keepOriginalTimestamps:this.keepOriginalTimestamps=!1,this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,bt.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.pendingBytes+=e.boxes.byteLength,"video"===e.track.type&&(this.videoTrack=e.track,this.pendingBoxes.push(e.boxes)),void("audio"===e.track.type&&(this.audioTrack=e.track,this.pendingBoxes.unshift(e.boxes))))}}).prototype=new L,bt.prototype.flush=function(e){var t,n,r,i,o=0,a={captions:[],captionStreams:{},metadata:[],info:{}},s=0;if(this.pendingTracks.length=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0))}if(this.videoTrack?(s=this.videoTrack.timelineStartInfo.pts,St.forEach((function(e){a.info[e]=this.videoTrack[e]}),this)):this.audioTrack&&(s=this.audioTrack.timelineStartInfo.pts,wt.forEach((function(e){a.info[e]=this.audioTrack[e]}),this)),this.videoTrack||this.audioTrack){for(1===this.pendingTracks.length?a.type=this.pendingTracks[0].type:a.type="combined",this.emittedTracks+=this.pendingTracks.length,r=X(this.pendingTracks),a.initSegment=new Uint8Array(r.byteLength),a.initSegment.set(r),a.data=new Uint8Array(this.pendingBytes),i=0;i=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},bt.prototype.setRemux=function(e){this.remuxTracks=e},(vt=function(e){var t,n,r=this,i=!0;vt.prototype.init.call(this),e=e||{},this.baseMediaDecodeTime=e.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var i={};this.transmuxPipeline_=i,i.type="aac",i.metadataStream=new tt.MetadataStream,i.aacStream=new yt,i.audioTimestampRolloverStream=new tt.TimestampRolloverStream("audio"),i.timedMetadataTimestampRolloverStream=new tt.TimestampRolloverStream("timed-metadata"),i.adtsStream=new st,i.coalesceStream=new bt(e,i.metadataStream),i.headOfPipeline=i.aacStream,i.aacStream.pipe(i.audioTimestampRolloverStream).pipe(i.adtsStream),i.aacStream.pipe(i.timedMetadataTimestampRolloverStream).pipe(i.metadataStream).pipe(i.coalesceStream),i.metadataStream.on("timestamp",(function(e){i.aacStream.setTimestamp(e.timeStamp)})),i.aacStream.on("data",(function(o){"timed-metadata"!==o.type&&"audio"!==o.type||i.audioSegmentStream||(n=n||{timelineStartInfo:{baseMediaDecodeTime:r.baseMediaDecodeTime},codec:"adts",type:"audio"},i.coalesceStream.numberOfTracks++,i.audioSegmentStream=new gt(n,e),i.audioSegmentStream.on("log",r.getLogTrigger_("audioSegmentStream")),i.audioSegmentStream.on("timingInfo",r.trigger.bind(r,"audioTimingInfo")),i.adtsStream.pipe(i.audioSegmentStream).pipe(i.coalesceStream),r.trigger("trackinfo",{hasAudio:!!n,hasVideo:!!t}))})),i.coalesceStream.on("data",this.trigger.bind(this,"data")),i.coalesceStream.on("done",this.trigger.bind(this,"done"))},this.setupTsPipeline=function(){var i={};this.transmuxPipeline_=i,i.type="ts",i.metadataStream=new tt.MetadataStream,i.packetStream=new tt.TransportPacketStream,i.parseStream=new tt.TransportParseStream,i.elementaryStream=new tt.ElementaryStream,i.timestampRolloverStream=new tt.TimestampRolloverStream,i.adtsStream=new st,i.h264Stream=new _t,i.captionStream=new tt.CaptionStream(e),i.coalesceStream=new bt(e,i.metadataStream),i.headOfPipeline=i.packetStream,i.packetStream.pipe(i.parseStream).pipe(i.elementaryStream).pipe(i.timestampRolloverStream),i.timestampRolloverStream.pipe(i.h264Stream),i.timestampRolloverStream.pipe(i.adtsStream),i.timestampRolloverStream.pipe(i.metadataStream).pipe(i.coalesceStream),i.h264Stream.pipe(i.captionStream).pipe(i.coalesceStream),i.elementaryStream.on("data",(function(o){var a;if("metadata"===o.type){for(a=o.tracks.length;a--;)t||"video"!==o.tracks[a].type?n||"audio"!==o.tracks[a].type||((n=o.tracks[a]).timelineStartInfo.baseMediaDecodeTime=r.baseMediaDecodeTime):(t=o.tracks[a]).timelineStartInfo.baseMediaDecodeTime=r.baseMediaDecodeTime;t&&!i.videoSegmentStream&&(i.coalesceStream.numberOfTracks++,i.videoSegmentStream=new mt(t,e),i.videoSegmentStream.on("log",r.getLogTrigger_("videoSegmentStream")),i.videoSegmentStream.on("timelineStartInfo",(function(t){n&&!e.keepOriginalTimestamps&&(n.timelineStartInfo=t,i.audioSegmentStream.setEarliestDts(t.dts-r.baseMediaDecodeTime))})),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.videoSegmentStream.on("timingInfo",r.trigger.bind(r,"videoTimingInfo")),i.h264Stream.pipe(i.videoSegmentStream).pipe(i.coalesceStream)),n&&!i.audioSegmentStream&&(i.coalesceStream.numberOfTracks++,i.audioSegmentStream=new gt(n,e),i.audioSegmentStream.on("log",r.getLogTrigger_("audioSegmentStream")),i.audioSegmentStream.on("timingInfo",r.trigger.bind(r,"audioTimingInfo")),i.audioSegmentStream.on("segmentTimingInfo",r.trigger.bind(r,"audioSegmentTimingInfo")),i.adtsStream.pipe(i.audioSegmentStream).pipe(i.coalesceStream)),r.trigger("trackinfo",{hasAudio:!!n,hasVideo:!!t})}})),i.coalesceStream.on("data",this.trigger.bind(this,"data")),i.coalesceStream.on("id3Frame",(function(e){e.dispatchType=i.metadataStream.dispatchType,r.trigger("id3Frame",e)})),i.coalesceStream.on("caption",this.trigger.bind(this,"caption")),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,ve(n),i.audioTimestampRolloverStream&&i.audioTimestampRolloverStream.discontinuity()),t&&(i.videoSegmentStream&&(i.videoSegmentStream.gopCache_=[]),t.timelineStartInfo.dts=void 0,t.timelineStartInfo.pts=void 0,ve(t),i.captionStream.reset()),i.timestampRolloverStream&&i.timestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(e){n&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(e)},this.setRemux=function(t){var n=this.transmuxPipeline_;e.remux=t,n&&n.coalesceStream&&n.coalesceStream.setRemux(t)},this.alignGopsWith=function(e){t&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(e)},this.getLogTrigger_=function(e){var t=this;return function(n){n.stream=e,t.trigger("log",n)}},this.push=function(e){if(i){var t=kt(e);if(t&&"aac"!==this.transmuxPipeline_.type?this.setupAacPipeline():t||"ts"===this.transmuxPipeline_.type||this.setupTsPipeline(),this.transmuxPipeline_)for(var n=Object.keys(this.transmuxPipeline_),r=0;r>>0},Pt=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])},Rt=It,Dt=function e(t,n){var r,i,o,a,s,c=[];if(!n.length)return null;for(r=0;r1?r+i:t.byteLength,o===n[0]&&(1===n.length?c.push(t.subarray(r+8,a)):(s=e(t.subarray(r+8,a),n.slice(1))).length&&(c=c.concat(s))),r=a;return c},Nt=It,jt=function(e){var t={version:e[0],flags:new Uint8Array(e.subarray(1,4)),baseMediaDecodeTime:Nt(e[4]<<24|e[5]<<16|e[6]<<8|e[7])};return 1===t.version&&(t.baseMediaDecodeTime*=Math.pow(2,32),t.baseMediaDecodeTime+=Nt(e[8]<<24|e[9]<<16|e[10]<<8|e[11])),t},Lt=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]}},Bt=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],o=4&n.flags[2],a=1&n.flags[1],s=2&n.flags[1],c=4&n.flags[1],u=8&n.flags[1],l=r.getUint32(4),d=8;for(i&&(n.dataOffset=r.getInt32(d),d+=4),o&&l&&(t={flags:Lt(e.subarray(d,d+4))},d+=4,a&&(t.duration=r.getUint32(d),d+=4),s&&(t.size=r.getUint32(d),d+=4),u&&(1===n.version?t.compositionTimeOffset=r.getInt32(d):t.compositionTimeOffset=r.getUint32(d),d+=4),n.samples.push(t),l--);l--;)t={},a&&(t.duration=r.getUint32(d),d+=4),s&&(t.size=r.getUint32(d),d+=4),c&&(t.flags=Lt(e.subarray(d,d+4)),d+=4),u&&(1===n.version?t.compositionTimeOffset=r.getInt32(d):t.compositionTimeOffset=r.getUint32(d),d+=4),n.samples.push(t);return n},zt=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],o=2&r.flags[2],a=8&r.flags[2],s=16&r.flags[2],c=32&r.flags[2],u=65536&r.flags[0],l=131072&r.flags[0];return t=8,i&&(t+=4,r.baseDataOffset=n.getUint32(12),t+=4),o&&(r.sampleDescriptionIndex=n.getUint32(t),t+=4),a&&(r.defaultSampleDuration=n.getUint32(t),t+=4),s&&(r.defaultSampleSize=n.getUint32(t),t+=4),c&&(r.defaultSampleFlags=n.getUint32(t)),u&&(r.durationIsEmpty=!0),!i&&l&&(r.baseDataOffsetIsMoof=!0),r},Ft=ke,Ut=je.CaptionStream,qt=function(e,t){for(var n=e,r=0;r0?jt(u[0]).baseMediaDecodeTime:0,d=Dt(o,["trun"]);t===c&&d.length>0&&(n=function(e,t,n){var r,i,o,a,s=new DataView(e.buffer,e.byteOffset,e.byteLength),c={logs:[],seiNals:[]};for(i=0;i+40;){var c=t.shift();this.parse(c,o,a)}return(s=function(e,t,n){if(null===t)return null;var r=Vt(e,t)[t]||{};return{seiNals:r.seiNals,logs:r.logs,timescale:n}}(e,n,r))&&s.logs&&(i.logs=i.logs.concat(s.logs)),null!==s&&s.seiNals?(this.pushNals(s.seiNals),this.flushStream(),i):i.logs.length?{logs:i.logs,captions:[],captionStreams:[]}: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;o?e.partialFlush():e.flush()},this.clearParsedCaptions=function(){i.captions=[],i.captionStreams={},i.logs=[]},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:{},logs:[]},this.resetCaptionStream()},this.reset()},Ht=It,Kt=function(e){return("00"+e.toString(16)).slice(-2)};Mt=function(e,t){var n,r,i;return n=Dt(t,["moof","traf"]),r=[].concat.apply([],n.map((function(t){return Dt(t,["tfhd"]).map((function(n){var r,i,o;return r=Ht(n[4]<<24|n[5]<<16|n[6]<<8|n[7]),i=e[r]||9e4,(o="number"!==typeof(o=Dt(t,["tfdt"]).map((function(e){var t,n;return t=e[0],n=Ht(e[4]<<24|e[5]<<16|e[6]<<8|e[7]),1===t&&(n*=Math.pow(2,32),n+=Ht(e[8]<<24|e[9]<<16|e[10]<<8|e[11])),n}))[0])||isNaN(o)?1/0:o)/i}))}))),i=Math.min.apply(null,r),isFinite(i)?i:0},Ct=function(e){var t=Dt(e,["moov","trak"]),n=[];return t.forEach((function(e){var t,r,i={},o=Dt(e,["tkhd"])[0];o&&(r=(t=new DataView(o.buffer,o.byteOffset,o.byteLength)).getUint8(0),i.id=0===r?t.getUint32(12):t.getUint32(20));var a=Dt(e,["mdia","hdlr"])[0];if(a){var s=Pt(a.subarray(8,12));i.type="vide"===s?"video":"soun"===s?"audio":s}var c=Dt(e,["mdia","minf","stbl","stsd"])[0];if(c){var u=c.subarray(8);i.codec=Pt(u.subarray(4,8));var l,d=Dt(u,[i.codec])[0];d&&(/^[a-z]vc[1-9]$/i.test(i.codec)?(l=d.subarray(78),"avcC"===Pt(l.subarray(4,8))&&l.length>11?(i.codec+=".",i.codec+=Kt(l[9]),i.codec+=Kt(l[10]),i.codec+=Kt(l[11])):i.codec="avc1.4d400d"):/^mp4[a,v]$/i.test(i.codec)?(l=d.subarray(28),"esds"===Pt(l.subarray(4,8))&&l.length>20&&0!==l[19]?(i.codec+="."+Kt(l[19]),i.codec+="."+Kt(l[20]>>>2&63).replace(/^0/,"")):i.codec="mp4a.40.2"):i.codec=i.codec.toLowerCase())}var f=Dt(e,["mdia","mdhd"])[0];f&&(i.timescale=Tt(f)),n.push(i)})),n};var Zt=Mt,Gt=Ct,Xt=(Tt=function(e){var t=0===e[0]?12:20;return Ht(e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3])},function(e){var t=31&e[1];return t<<=8,t|=e[2]}),Yt=function(e){return!!(64&e[1])},$t=function(e){var t=0;return(48&e[3])>>>4>1&&(t+=e[4]+1),t},Jt=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}},Qt={parseType:function(e,t){var n=Xt(e);return 0===n?"pat":n===t?"pmt":t?"pes":null},parsePat:function(e){var t=Yt(e),n=4+$t(e);return t&&(n+=e[n]+1),(31&e[n+10])<<8|e[n+11]},parsePmt:function(e){var t={},n=Yt(e),r=4+$t(e);if(n&&(r+=e[r]+1),1&e[r+5]){var i;i=3+((15&e[r+1])<<8|e[r+2])-4;for(var o=12+((15&e[r+10])<<8|e[r+11]);o=e.byteLength)return null;var n,r=null;return 192&(n=e[t+7])&&((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},videoPacketContainsKeyFrame:function(e){for(var t=4+$t(e),n=e.subarray(t),r=0,i=0,o=!1;i3&&"slice_layer_without_partitioning_rbsp_idr"===Jt(31&n[i+3])&&(o=!0),o}},en=qe,tn={};tn.ts=Qt,tn.aac=pt;var nn=ae,rn=function(e,t,n){for(var r,i,o,a,s=0,c=188,u=!1;c<=e.byteLength;)if(71!==e[s]||71!==e[c]&&c!==e.byteLength)s++,c++;else{switch(r=e.subarray(s,c),tn.ts.parseType(r,t.pid)){case"pes":i=tn.ts.parsePesType(r,t.table),o=tn.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&o&&(a=tn.ts.parsePesTime(r))&&(a.type="audio",n.audio.push(a),u=!0)}if(u)break;s+=188,c+=188}for(s=(c=e.byteLength)-188,u=!1;s>=0;)if(71!==e[s]||71!==e[c]&&c!==e.byteLength)s--,c--;else{switch(r=e.subarray(s,c),tn.ts.parseType(r,t.pid)){case"pes":i=tn.ts.parsePesType(r,t.table),o=tn.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&o&&(a=tn.ts.parsePesTime(r))&&(a.type="audio",n.audio.push(a),u=!0)}if(u)break;s-=188,c-=188}},on=function(e,t,n){for(var r,i,o,a,s,c,u,l=0,d=188,f=!1,h={data:[],size:0};d=0;)if(71!==e[l]||71!==e[d])l--,d--;else{switch(r=e.subarray(l,d),tn.ts.parseType(r,t.pid)){case"pes":i=tn.ts.parsePesType(r,t.table),o=tn.ts.parsePayloadUnitStartIndicator(r),"video"===i&&o&&(a=tn.ts.parsePesTime(r))&&(a.type="video",n.video.push(a),f=!0)}if(f)break;l-=188,d-=188}},an=function(e){var t={pid:null,table:null},n={};for(var r in function(e,t){for(var n,r=0,i=188;i=3;){switch(tn.aac.parseType(e,s)){case"timed-metadata":if(e.length-s<10){n=!0;break}if((a=tn.aac.parseId3TagSize(e,s))>e.length){n=!0;break}null===o&&(t=e.subarray(s,s+a),o=tn.aac.parseAacTimestamp(t)),s+=a;break;case"audio":if(e.length-s<7){n=!0;break}if((a=tn.aac.parseAdtsSize(e,s))>e.length){n=!0;break}null===i&&(t=e.subarray(s,s+a),i=tn.aac.parseSampleRate(t)),r++,s+=a;break;default:s++}if(n)return null}if(null===i||null===o)return null;var c=nn/i;return{audio:[{type:"audio",dts:o,pts:o},{type:"audio",dts:o+1024*r*c,pts:o+1024*r*c}]}}(e):an(e))&&(n.audio||n.video)?(function(e,t){if(e.audio&&e.audio.length){var n=t;("undefined"===typeof n||isNaN(n))&&(n=e.audio[0].dts),e.audio.forEach((function(e){e.dts=en(e.dts,n),e.pts=en(e.pts,n),e.dtsTime=e.dts/nn,e.ptsTime=e.pts/nn}))}if(e.video&&e.video.length){var r=t;if(("undefined"===typeof r||isNaN(r))&&(r=e.video[0].dts),e.video.forEach((function(e){e.dts=en(e.dts,r),e.pts=en(e.pts,r),e.dtsTime=e.dts/nn,e.ptsTime=e.pts/nn})),e.firstKeyFrame){var i=e.firstKeyFrame;i.dts=en(i.dts,r),i.pts=en(i.pts,r),i.dtsTime=i.dts/nn,i.ptsTime=i.pts/nn}}}(n,t),n):null},cn=function(){function e(e,t){this.options=t||{},this.self=e,this.init()}var t=e.prototype;return t.init=function(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new At.Transmuxer(this.options),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.on("done",(function(t){e.postMessage({action:"done"})})),t.on("gopInfo",(function(t){e.postMessage({action:"gopInfo",gopInfo:t})})),t.on("videoSegmentTimingInfo",(function(t){var n={start:{decode:ce(t.start.dts),presentation:ce(t.start.pts)},end:{decode:ce(t.end.dts),presentation:ce(t.end.pts)},baseMediaDecodeTime:ce(t.baseMediaDecodeTime)};t.prependedContentDuration&&(n.prependedContentDuration=ce(t.prependedContentDuration)),e.postMessage({action:"videoSegmentTimingInfo",videoSegmentTimingInfo:n})})),t.on("audioSegmentTimingInfo",(function(t){var n={start:{decode:ce(t.start.dts),presentation:ce(t.start.pts)},end:{decode:ce(t.end.dts),presentation:ce(t.end.pts)},baseMediaDecodeTime:ce(t.baseMediaDecodeTime)};t.prependedContentDuration&&(n.prependedContentDuration=ce(t.prependedContentDuration)),e.postMessage({action:"audioSegmentTimingInfo",audioSegmentTimingInfo:n})})),t.on("id3Frame",(function(t){e.postMessage({action:"id3Frame",id3Frame:t})})),t.on("caption",(function(t){e.postMessage({action:"caption",caption:t})})),t.on("trackinfo",(function(t){e.postMessage({action:"trackinfo",trackInfo:t})})),t.on("audioTimingInfo",(function(t){e.postMessage({action:"audioTimingInfo",audioTimingInfo:{start:ce(t.start),end:ce(t.end)}})})),t.on("videoTimingInfo",(function(t){e.postMessage({action:"videoTimingInfo",videoTimingInfo:{start:ce(t.start),end:ce(t.end)}})})),t.on("log",(function(t){e.postMessage({action:"log",log:t})}))}(this.self,this.transmuxer)},t.pushMp4Captions=function(e){this.captionParser||(this.captionParser=new Wt,this.captionParser.init());var t=new Uint8Array(e.data,e.byteOffset,e.byteLength),n=this.captionParser.parse(t,e.trackIds,e.timescales);this.self.postMessage({action:"mp4Captions",captions:n&&n.captions||[],logs:n&&n.logs||[],data:t.buffer},[t.buffer])},t.probeMp4StartTime=function(e){var t=e.timescales,n=e.data,r=Zt(t,n);this.self.postMessage({action:"probeMp4StartTime",startTime:r,data:n},[n.buffer])},t.probeMp4Tracks=function(e){var t=e.data,n=Gt(t);this.self.postMessage({action:"probeMp4Tracks",tracks:n,data:t},[t.buffer])},t.probeTs=function(e){var t=e.data,n=e.baseStartTime,r="number"!==typeof n||isNaN(n)?void 0:n*ae,i=sn(t,r),o=null;i&&((o={hasVideo:i.video&&2===i.video.length||!1,hasAudio:i.audio&&2===i.audio.length||!1}).hasVideo&&(o.videoStart=i.video[0].ptsTime),o.hasAudio&&(o.audioStart=i.audio[0].ptsTime)),this.self.postMessage({action:"probeTs",result:o,data:t},[t.buffer])},t.clearAllMp4Captions=function(){this.captionParser&&this.captionParser.clearAllCaptions()},t.clearParsedMp4Captions=function(){this.captionParser&&this.captionParser.clearParsedCaptions()},t.push=function(e){var t=new Uint8Array(e.data,e.byteOffset,e.byteLength);this.transmuxer.push(t)},t.reset=function(){this.transmuxer.reset()},t.setTimestampOffset=function(e){var t=e.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(se(t)))},t.setAudioAppendStart=function(e){this.transmuxer.setAudioAppendStart(Math.ceil(se(e.appendStart)))},t.setRemux=function(e){this.transmuxer.setRemux(e.remux)},t.flush=function(e){this.transmuxer.flush(),self.postMessage({action:"done",type:"transmuxed"})},t.endTimeline=function(){this.transmuxer.endTimeline(),self.postMessage({action:"endedtimeline",type:"transmuxed"})},t.alignGopsWith=function(e){this.transmuxer.alignGopsWith(e.gopsToAlignWith.slice())},e}();self.onmessage=function(e){"init"===e.data.action&&e.data.options?this.messageHandlers=new cn(self,e.data.options):(this.messageHandlers||(this.messageHandlers=new cn(self)),e.data&&e.data.action&&"init"!==e.data.action&&this.messageHandlers[e.data.action]&&this.messageHandlers[e.data.action](e.data))}})))),ec=function(e){var t=e.transmuxer,n=e.bytes,r=e.audioAppendStart,i=e.gopsToAlignWith,o=e.remux,a=e.onData,s=e.onTrackInfo,c=e.onAudioTimingInfo,u=e.onVideoTimingInfo,l=e.onVideoSegmentTimingInfo,d=e.onAudioSegmentTimingInfo,f=e.onId3,h=e.onCaptions,p=e.onDone,m=e.onEndedTimeline,g=e.onTransmuxerLog,v=e.isEndOfTimeline,b={buffer:[]},y=v;if(t.onmessage=function(n){t.currentTransmux===e&&("data"===n.data.action&&function(e,t,n){var r=e.data.segment,i=r.type,o=r.initSegment,a=r.captions,s=r.captionStreams,c=r.metadata,u=r.videoFrameDtsTime,l=r.videoFramePtsTime;t.buffer.push({captions:a,captionStreams:s,metadata:c});var d=e.data.segment.boxes||{data:e.data.segment.data},f={type:i,data:new Uint8Array(d.data,d.data.byteOffset,d.data.byteLength),initSegment:new Uint8Array(o.data,o.byteOffset,o.byteLength)};"undefined"!==typeof u&&(f.videoFrameDtsTime=u),"undefined"!==typeof l&&(f.videoFramePtsTime=l),n(f)}(n,b,a),"trackinfo"===n.data.action&&s(n.data.trackInfo),"gopInfo"===n.data.action&&function(e,t){t.gopInfo=e.data.gopInfo}(n,b),"audioTimingInfo"===n.data.action&&c(n.data.audioTimingInfo),"videoTimingInfo"===n.data.action&&u(n.data.videoTimingInfo),"videoSegmentTimingInfo"===n.data.action&&l(n.data.videoSegmentTimingInfo),"audioSegmentTimingInfo"===n.data.action&&d(n.data.audioSegmentTimingInfo),"id3Frame"===n.data.action&&f([n.data.id3Frame],n.data.id3Frame.dispatchType),"caption"===n.data.action&&h(n.data.caption),"endedtimeline"===n.data.action&&(y=!1,m()),"log"===n.data.action&&g(n.data.log),"transmuxed"===n.data.type&&(y||(t.onmessage=null,function(e){var t=e.transmuxedData,n=e.callback;t.buffer=[],n(t)}({transmuxedData:b,callback:p}),tc(t))))},r&&t.postMessage({action:"setAudioAppendStart",appendStart:r}),Array.isArray(i)&&t.postMessage({action:"alignGopsWith",gopsToAlignWith:i}),"undefined"!==typeof o&&t.postMessage({action:"setRemux",remux:o}),n.byteLength){var w=n instanceof ArrayBuffer?n:n.buffer,S=n instanceof ArrayBuffer?0:n.byteOffset;t.postMessage({action:"push",data:w,byteOffset:S,byteLength:n.byteLength},[w])}v&&t.postMessage({action:"endTimeline"}),t.postMessage({action:"flush"})},tc=function(e){e.currentTransmux=null,e.transmuxQueue.length&&(e.currentTransmux=e.transmuxQueue.shift(),"function"===typeof e.currentTransmux?e.currentTransmux():ec(e.currentTransmux))},nc=function(e,t){e.postMessage({action:t}),tc(e)},rc=function(e,t){if(!t.currentTransmux)return t.currentTransmux=e,void nc(t,e);t.transmuxQueue.push(nc.bind(null,t,e))},ic=function(e){if(!e.transmuxer.currentTransmux)return e.transmuxer.currentTransmux=e,void ec(e);e.transmuxer.transmuxQueue.push(e)},oc=function(e){rc("reset",e)},ac=function(e){var t=new Qs;t.currentTransmux=null,t.transmuxQueue=[];var n=t.terminate;return t.terminate=function(){return t.currentTransmux=null,t.transmuxQueue.length=0,n.call(t)},t.postMessage({action:"init",options:e}),t},sc=function(e){var t=e.transmuxer,n=e.endAction||e.action,r=e.callback,i=u()({},e,{endAction:null,transmuxer:null,callback:null});if(t.addEventListener("message",(function i(o){o.data.action===n&&(t.removeEventListener("message",i),o.data.data&&(o.data.data=new Uint8Array(o.data.data,e.byteOffset||0,e.byteLength||o.data.data.byteLength),e.data&&(e.data=o.data.data)),r(o.data))})),e.data){var o=e.data instanceof ArrayBuffer;i.byteOffset=o?0:e.data.byteOffset,i.byteLength=e.data.byteLength;var a=[o?e.data:e.data.buffer];t.postMessage(i,a)}else t.postMessage(i)},cc=2,uc=-101,lc=-102,dc=function(e){e.forEach((function(e){e.abort()}))},fc=function(e,t){return t.timedout?{status:t.status,message:"HLS request timed-out at URL: "+t.uri,code:uc,xhr:t}:t.aborted?{status:t.status,message:"HLS request aborted at URL: "+t.uri,code:lc,xhr:t}:e?{status:t.status,message:"HLS request errored at URL: "+t.uri,code:cc,xhr:t}:"arraybuffer"===t.responseType&&0===t.response.byteLength?{status:t.status,message:"Empty HLS response at URL: "+t.uri,code:cc,xhr:t}:null},hc=function(e,t,n){return function(r,i){var o=i.response,a=fc(r,i);if(a)return n(a,e);if(16!==o.byteLength)return n({status:i.status,message:"Invalid HLS key at URL: "+i.uri,code:cc,xhr:i},e);for(var s=new DataView(o),c=new Uint32Array([s.getUint32(0),s.getUint32(4),s.getUint32(8),s.getUint32(12)]),u=0;u0}(p)){t.isFmp4=!0;var m=t.map.tracks,g={isFmp4:!0,hasVideo:!!m.video,hasAudio:!!m.audio};m.audio&&m.audio.codec&&"enca"!==m.audio.codec&&(g.audioCodec=m.audio.codec),m.video&&m.video.codec&&"encv"!==m.video.codec&&(g.videoCodec=m.video.codec),m.video&&m.audio&&(g.isMuxed=!0),r(t,g);var v=function(e){d(t,{data:p,type:g.hasAudio&&!g.isMuxed?"audio":"video"}),e&&e.length&&c(t,e),f(null,t,{})};sc({action:"probeMp4StartTime",timescales:t.map.timescales,data:p,transmuxer:t.transmuxer,callback:function(e){var r=e.data,o=e.startTime;n=r.buffer,t.bytes=p=r,g.hasAudio&&!g.isMuxed&&i(t,"audio","start",o),g.hasVideo&&i(t,"video","start",o),m.video&&r.byteLength&&t.transmuxer?sc({action:"pushMp4Captions",endAction:"mp4Captions",transmuxer:t.transmuxer,data:p,timescales:t.map.timescales,trackIds:[m.video.id],callback:function(e){n=e.data.buffer,t.bytes=p=e.data,e.logs.forEach((function(e){h(Na.mergeOptions(e,{stream:"mp4CaptionParser"}))})),v(e.captions)}}):v()}})}else if(t.transmuxer){if("undefined"===typeof t.container&&(t.container=Ot(p)),"ts"!==t.container&&"aac"!==t.container)return r(t,{hasAudio:!1,hasVideo:!1}),void f(null,t,{});gc({segment:t,bytes:n,trackInfoFn:r,timingInfoFn:i,videoSegmentTimingInfoFn:o,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:c,isEndOfTimeline:u,endedTimelineFn:l,dataFn:d,doneFn:f,onTransmuxerLog:h})}else f(null,t,{})},bc=function(e,t){var n,r=e.id,i=e.key,o=e.encryptedBytes,a=e.decryptionWorker;a.addEventListener("message",(function e(n){if(n.data.source===r){a.removeEventListener("message",e);var i=n.data.decrypted;t(new Uint8Array(i.bytes,i.byteOffset,i.byteLength))}})),n=i.bytes.slice?i.bytes.slice():new Uint32Array(Array.prototype.slice.call(i.bytes)),a.postMessage(Ds({source:r,encrypted:o,key:n,iv:i.iv}),[o.buffer,n.buffer])},yc=function(e){var t=e.activeXhrs,n=e.decryptionWorker,r=e.trackInfoFn,i=e.timingInfoFn,o=e.videoSegmentTimingInfoFn,a=e.audioSegmentTimingInfoFn,s=e.id3Fn,c=e.captionsFn,u=e.isEndOfTimeline,l=e.endedTimelineFn,d=e.dataFn,f=e.doneFn,h=e.onTransmuxerLog,p=0,m=!1;return function(e,g){if(!m){if(e)return m=!0,dc(t),f(e,g);if((p+=1)===t.length){var v=function(){if(g.encryptedBytes)return function(e){var t=e.decryptionWorker,n=e.segment,r=e.trackInfoFn,i=e.timingInfoFn,o=e.videoSegmentTimingInfoFn,a=e.audioSegmentTimingInfoFn,s=e.id3Fn,c=e.captionsFn,u=e.isEndOfTimeline,l=e.endedTimelineFn,d=e.dataFn,f=e.doneFn,h=e.onTransmuxerLog;bc({id:n.requestId,key:n.key,encryptedBytes:n.encryptedBytes,decryptionWorker:t},(function(e){n.bytes=e,vc({segment:n,bytes:n.bytes,trackInfoFn:r,timingInfoFn:i,videoSegmentTimingInfoFn:o,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:c,isEndOfTimeline:u,endedTimelineFn:l,dataFn:d,doneFn:f,onTransmuxerLog:h})}))}({decryptionWorker:n,segment:g,trackInfoFn:r,timingInfoFn:i,videoSegmentTimingInfoFn:o,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:c,isEndOfTimeline:u,endedTimelineFn:l,dataFn:d,doneFn:f,onTransmuxerLog:h});vc({segment:g,bytes:g.bytes,trackInfoFn:r,timingInfoFn:i,videoSegmentTimingInfoFn:o,audioSegmentTimingInfoFn:a,id3Fn:s,captionsFn:c,isEndOfTimeline:u,endedTimelineFn:l,dataFn:d,doneFn:f,onTransmuxerLog:h})};if(g.endOfAllRequests=Date.now(),g.map&&g.map.encryptedBytes&&!g.map.bytes)return bc({decryptionWorker:n,id:g.requestId+"-init",encryptedBytes:g.map.encryptedBytes,key:g.map.key},(function(e){g.map.bytes=e,pc(g,(function(e){if(e)return dc(t),f(e,g);v()}))}));v()}}}},wc=function(e){var t=e.segment,n=e.progressFn;return e.trackInfoFn,e.timingInfoFn,e.videoSegmentTimingInfoFn,e.audioSegmentTimingInfoFn,e.id3Fn,e.captionsFn,e.isEndOfTimeline,e.endedTimelineFn,e.dataFn,function(e){if(!e.target.aborted)return t.stats=Na.mergeOptions(t.stats,function(e){var t=e.target,n={bandwidth:1/0,bytesReceived:0,roundTripTime:Date.now()-t.requestTime||0};return n.bytesReceived=e.loaded,n.bandwidth=Math.floor(n.bytesReceived/n.roundTripTime*8*1e3),n}(e)),!t.stats.firstBytesReceivedAt&&t.stats.bytesReceived&&(t.stats.firstBytesReceivedAt=Date.now()),n(e,t)}},Sc=function(e){var t=e.xhr,n=e.xhrOptions,r=e.decryptionWorker,i=e.segment,o=e.abortFn,a=e.progressFn,s=e.trackInfoFn,c=e.timingInfoFn,u=e.videoSegmentTimingInfoFn,l=e.audioSegmentTimingInfoFn,d=e.id3Fn,f=e.captionsFn,h=e.isEndOfTimeline,p=e.endedTimelineFn,m=e.dataFn,g=e.doneFn,v=e.onTransmuxerLog,b=[],y=yc({activeXhrs:b,decryptionWorker:r,trackInfoFn:s,timingInfoFn:c,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:d,captionsFn:f,isEndOfTimeline:h,endedTimelineFn:p,dataFn:m,doneFn:g,onTransmuxerLog:v});if(i.key&&!i.key.bytes){var w=[i.key];i.map&&!i.map.bytes&&i.map.key&&i.map.key.resolvedUri===i.key.resolvedUri&&w.push(i.map.key);var S=t(Na.mergeOptions(n,{uri:i.key.resolvedUri,responseType:"arraybuffer"}),hc(i,w,y));b.push(S)}if(i.map&&!i.map.bytes){if(i.map.key&&(!i.key||i.key.resolvedUri!==i.map.key.resolvedUri)){var _=t(Na.mergeOptions(n,{uri:i.map.key.resolvedUri,responseType:"arraybuffer"}),hc(i,[i.map.key],y));b.push(_)}var k=t(Na.mergeOptions(n,{uri:i.map.resolvedUri,responseType:"arraybuffer",headers:As(i.map)}),function(e){var t=e.segment,n=e.finishProcessingFn;return function(e,r){var i=fc(e,r);if(i)return n(i,t);var o=new Uint8Array(r.response);if(t.map.key)return t.map.encryptedBytes=o,n(null,t);t.map.bytes=o,pc(t,(function(e){if(e)return e.xhr=r,e.status=r.status,n(e,t);n(null,t)}))}}({segment:i,finishProcessingFn:y}));b.push(k)}var x=Na.mergeOptions(n,{uri:i.part&&i.part.resolvedUri||i.resolvedUri,responseType:"arraybuffer",headers:As(i)}),E=t(x,mc({segment:i,finishProcessingFn:y,responseType:x.responseType}));E.addEventListener("progress",wc({segment:i,progressFn:a,trackInfoFn:s,timingInfoFn:c,videoSegmentTimingInfoFn:u,audioSegmentTimingInfoFn:l,id3Fn:d,captionsFn:f,isEndOfTimeline:h,endedTimelineFn:p,dataFn:m})),b.push(E);var O={};return b.forEach((function(e){e.addEventListener("loadend",function(e){var t=e.loadendState,n=e.abortFn;return function(e){e.target.aborted&&n&&!t.calledAbortFn&&(n(),t.calledAbortFn=!0)}}({loadendState:O,abortFn:o}))})),function(){return dc(b)}},_c=Fa("CodecUtils"),kc=function(e,t){var n=t.attributes||{};return e&&e.mediaGroups&&e.mediaGroups.AUDIO&&n.AUDIO&&e.mediaGroups.AUDIO[n.AUDIO]},xc=function(e){var t={};return e.forEach((function(e){var n=e.mediaType,r=e.type,i=e.details;t[n]=t[n]||[],t[n].push(G(""+r+i))})),Object.keys(t).forEach((function(e){if(t[e].length>1)return _c("multiple "+e+" codecs found as attributes: "+t[e].join(", ")+". Setting playlist codecs to null so that we wait for mux.js to probe segments for real codecs."),void(t[e]=null);t[e]=t[e][0]})),t},Ec=function(e){var t=0;return e.audio&&t++,e.video&&t++,t},Oc=function(e,t){var n=t.attributes||{},r=xc(function(e){var t=e.attributes||{};if(t.CODECS)return X(t.CODECS)}(t)||[]);if(kc(e,t)&&!r.audio&&!function(e,t){if(!kc(e,t))return!0;var n=t.attributes||{},r=e.mediaGroups.AUDIO[n.AUDIO];for(var i in r)if(!r[i].uri&&!r[i].playlists)return!0;return!1}(e,t)){var i=xc(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 X(i.playlists[0].attributes.CODECS)}return null}(e,n.AUDIO)||[]);i.audio&&(r.audio=i.audio)}return r},Mc=Fa("PlaylistSelector"),Cc=function(e){if(e&&e.playlist){var t=e.playlist;return JSON.stringify({id:t.id,bandwidth:e.bandwidth,width:e.width,height:e.height,codecs:t.attributes&&t.attributes.CODECS||""})}},Tc=function(e,t){if(!e)return"";var n=o.a.getComputedStyle(e);return n?n[t]:""},Ac=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}))},Ic=function(e,t){var n,r;return e.attributes.BANDWIDTH&&(n=e.attributes.BANDWIDTH),n=n||o.a.Number.MAX_VALUE,t.attributes.BANDWIDTH&&(r=t.attributes.BANDWIDTH),n-(r=r||o.a.Number.MAX_VALUE)},Pc=function(e,t,n,r,i,a){if(e){var s={bandwidth:t,width:n,height:r,limitRenditionByPlayerDimensions:i},c=e.playlists;ds.isAudioOnly(e)&&(c=a.getAudioTrackPlaylists_(),s.audioOnly=!0);var u=c.map((function(e){var t=e.attributes&&e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width,n=e.attributes&&e.attributes.RESOLUTION&&e.attributes.RESOLUTION.height;return{bandwidth:e.attributes&&e.attributes.BANDWIDTH||o.a.Number.MAX_VALUE,width:t,height:n,playlist:e}}));Ac(u,(function(e,t){return e.bandwidth-t.bandwidth}));var l=(u=u.filter((function(e){return!ds.isIncompatible(e.playlist)}))).filter((function(e){return ds.isEnabled(e.playlist)}));l.length||(l=u.filter((function(e){return!ds.isDisabled(e.playlist)})));var d=l.filter((function(e){return e.bandwidth*Gs.BANDWIDTH_VARIANCEn||e.height>r}))).filter((function(e){return e.width===b[0].width&&e.height===b[0].height})),f=y[y.length-1],w=y.filter((function(e){return e.bandwidth===f.bandwidth}))[0]),a.experimentalLeastPixelDiffSelector){var k=g.map((function(e){return e.pixelDiff=Math.abs(e.width-n)+Math.abs(e.height-r),e}));Ac(k,(function(e,t){return e.pixelDiff===t.pixelDiff?t.bandwidth-e.bandwidth:e.pixelDiff-t.pixelDiff})),S=k[0]}var x=S||w||_||h||l[0]||u[0];if(x&&x.playlist){var E="sortedPlaylistReps";return S?E="leastPixelDiffRep":w?E="resolutionPlusOneRep":_?E="resolutionBestRep":h?E="bandwidthBestRep":l[0]&&(E="enabledPlaylistReps"),Mc("choosing "+Cc(x)+" using "+E+" with options",s),x.playlist}return Mc("could not choose a playlist with options",s),null}},Rc=function(){var e=this.useDevicePixelRatio&&o.a.devicePixelRatio||1;return Pc(this.playlists.master,this.systemBandwidth,parseInt(Tc(this.tech_.el(),"width"),10)*e,parseInt(Tc(this.tech_.el(),"height"),10)*e,this.limitRenditionByPlayerDimensions,this.masterPlaylistController_)},Dc=function(e){var t=e.inbandTextTracks,n=e.metadataArray,r=e.timestampOffset,i=e.videoDuration;if(n){var a=o.a.WebKitDataCue||o.a.VTTCue,s=t.metadataTrack_;if(s&&(n.forEach((function(e){var t=e.cueTime+r;!("number"!==typeof t||o.a.isNaN(t)||t<0)&&t<1/0&&e.frames.forEach((function(e){var n=new a(t,t,e.value||e.url||e.data||"");n.frame=e,n.value=e,function(e){Object.defineProperties(e.frame,{id:{get:function(){return Na.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),e.value.key}},value:{get:function(){return Na.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),e.value.data}},privateData:{get:function(){return Na.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),e.value.data}}})}(n),s.addCue(n)}))})),s.cues&&s.cues.length)){for(var c=s.cues,u=[],l=0;l=e&&i.endTime<=t&&n.removeCue(i)},jc=function(e){return"number"===typeof e&&isFinite(e)},Lc=function(e){var t=e.startOfSegment,n=e.duration,r=e.segment,i=e.part,o=e.playlist,a=o.mediaSequence,s=o.id,c=o.segments,u=void 0===c?[]:c,l=e.mediaIndex,d=e.partIndex,f=e.timeline,h=u.length-1,p="mediaIndex/partIndex increment";e.getMediaInfoForTime?p="getMediaInfoForTime ("+e.getMediaInfoForTime+")":e.isSyncRequest&&(p="getSyncSegmentCandidate (isSyncRequest)");var m="number"===typeof d,g=e.segment.uri?"segment":"pre-segment",v=m?$a({preloadSegment:r})-1:0;return g+" ["+(a+l)+"/"+(a+h)+"]"+(m?" part ["+d+"/"+v+"]":"")+" segment start/end ["+r.start+" => "+r.end+"]"+(m?" part start/end ["+i.start+" => "+i.end+"]":"")+" startOfSegment ["+t+"] duration ["+n+"] timeline ["+f+"] selected by ["+p+"] playlist ["+s+"]"},Bc=function(e){return e+"TimingInfo"},zc=function(e){var t=e.timelineChangeController,n=e.currentTimeline,r=e.segmentTimeline,i=e.loaderType,o=e.audioDisabled;if(n===r)return!1;if("audio"===i){var a=t.lastTimelineChange({type:"main"});return!a||a.to!==r}if("main"===i&&o){var s=t.pendingTimelineChange({type:"audio"});return!s||s.to!==r}return!1},Fc=function(e){var t=e.segmentDuration,n=e.maxDuration;return!!t&&Math.round(t)>n+1/30},Uc=function(e,t){if("hls"!==t)return null;var n=function(e,t){var n=e&&"number"===typeof e.start&&"number"===typeof e.end?e.end-e.start:0,r=t&&"number"===typeof t.start&&"number"===typeof t.end?t.end-t.start:0;return Math.max(n,r)}(e.audioTimingInfo,e.videoTimingInfo);if(!n)return null;var r=e.playlist.targetDuration,i=Fc({segmentDuration:n,maxDuration:2*r}),o=Fc({segmentDuration:n,maxDuration:r}),a="Segment with index "+e.mediaIndex+" from playlist "+e.playlist.id+" has a duration of "+n+" when the reported duration is "+e.duration+" and the target duration is "+r+". For HLS content, a duration in excess of the target duration may result in playback issues. See the HLS specification section on EXT-X-TARGETDURATION for more details: https://tools.ietf.org/html/draft-pantos-http-live-streaming-23#section-4.3.3.1";return i||o?{severity:i?"warn":"info",message:a}:null},qc=function(e){function t(t,n){var r;if(r=e.call(this)||this,!t)throw new TypeError("Initialization settings are required");if("function"!==typeof t.currentTime)throw new TypeError("No currentTime getter specified");if(!t.mediaSource)throw new TypeError("No MediaSource specified");return r.bandwidth=t.bandwidth,r.throughput={rate:0,count:0},r.roundTrip=NaN,r.resetStats_(),r.mediaIndex=null,r.partIndex=null,r.hasPlayed_=t.hasPlayed,r.currentTime_=t.currentTime,r.seekable_=t.seekable,r.seeking_=t.seeking,r.duration_=t.duration,r.mediaSource_=t.mediaSource,r.vhs_=t.vhs,r.loaderType_=t.loaderType,r.currentMediaInfo_=void 0,r.startingMediaInfo_=void 0,r.segmentMetadataTrack_=t.segmentMetadataTrack,r.goalBufferLength_=t.goalBufferLength,r.sourceType_=t.sourceType,r.sourceUpdater_=t.sourceUpdater,r.inbandTextTracks_=t.inbandTextTracks,r.state_="INIT",r.timelineChangeController_=t.timelineChangeController,r.shouldSaveSegmentTimingInfo_=!0,r.parse708captions_=t.parse708captions,r.captionServices_=t.captionServices,r.experimentalExactManifestTimings=t.experimentalExactManifestTimings,r.checkBufferTimeout_=null,r.error_=void 0,r.currentTimeline_=-1,r.pendingSegment_=null,r.xhrOptions_=null,r.pendingSegments_=[],r.audioDisabled_=!1,r.isPendingTimestampOffset_=!1,r.gopBuffer_=[],r.timeMapping_=0,r.safeAppend_=Na.browser.IE_VERSION>=11,r.appendInitSegment_={audio:!0,video:!0},r.playlistOfLastInitSegment_={audio:null,video:null},r.callQueue_=[],r.loadQueue_=[],r.metadataQueue_={id3:[],caption:[]},r.waitingOnRemove_=!1,r.quotaExceededErrorRetryTimeout_=null,r.activeInitSegmentId_=null,r.initSegments_={},r.cacheEncryptionKeys_=t.cacheEncryptionKeys,r.keyCache_={},r.decrypter_=t.decrypter,r.syncController_=t.syncController,r.syncPoint_={segmentIndex:0,time:0},r.transmuxer_=r.createTransmuxer_(),r.triggerSyncInfoUpdate_=function(){return r.trigger("syncinfoupdate")},r.syncController_.on("syncinfoupdate",r.triggerSyncInfoUpdate_),r.mediaSource_.addEventListener("sourceopen",(function(){r.isEndOfStream_()||(r.ended_=!1)})),r.fetchAtBuffer_=!1,r.logger_=Fa("SegmentLoader["+r.loaderType_+"]"),Object.defineProperty(d()(r),"state",{get:function(){return this.state_},set:function(e){e!==this.state_&&(this.logger_(this.state_+" -> "+e),this.state_=e,this.trigger("statechange"))}}),r.sourceUpdater_.on("ready",(function(){r.hasEnoughInfoToAppend_()&&r.processCallQueue_()})),"main"===r.loaderType_&&r.timelineChangeController_.on("pendingtimelinechange",(function(){r.hasEnoughInfoToAppend_()&&r.processCallQueue_()})),"audio"===r.loaderType_&&r.timelineChangeController_.on("timelinechange",(function(){r.hasEnoughInfoToLoad_()&&r.processLoadQueue_(),r.hasEnoughInfoToAppend_()&&r.processCallQueue_()})),r}h()(t,e);var n=t.prototype;return n.createTransmuxer_=function(){return ac({remux:!1,alignGopsAtEnd:this.safeAppend_,keepOriginalTimestamps:!0,parse708captions:this.parse708captions_,captionServices:this.captionServices_})},n.resetStats_=function(){this.mediaBytesTransferred=0,this.mediaRequests=0,this.mediaRequestsAborted=0,this.mediaRequestsTimedout=0,this.mediaRequestsErrored=0,this.mediaTransferDuration=0,this.mediaSecondsLoaded=0,this.mediaAppends=0},n.dispose=function(){this.trigger("dispose"),this.state="DISPOSED",this.pause(),this.abort_(),this.transmuxer_&&this.transmuxer_.terminate(),this.resetStats_(),this.checkBufferTimeout_&&o.a.clearTimeout(this.checkBufferTimeout_),this.syncController_&&this.triggerSyncInfoUpdate_&&this.syncController_.off("syncinfoupdate",this.triggerSyncInfoUpdate_),this.off()},n.setAudio=function(e){this.audioDisabled_=!e,e?this.appendInitSegment_.audio=!0:this.sourceUpdater_.removeAudio(0,this.duration_())},n.abort=function(){"WAITING"===this.state?(this.abort_(),this.state="READY",this.paused()||this.monitorBuffer_()):this.pendingSegment_&&(this.pendingSegment_=null)},n.abort_=function(){this.pendingSegment_&&this.pendingSegment_.abortRequests&&this.pendingSegment_.abortRequests(),this.pendingSegment_=null,this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.timelineChangeController_.clearPendingTimelineChange(this.loaderType_),this.waitingOnRemove_=!1,o.a.clearTimeout(this.quotaExceededErrorRetryTimeout_),this.quotaExceededErrorRetryTimeout_=null},n.checkForAbort_=function(e){return"APPENDING"!==this.state||this.pendingSegment_?!this.pendingSegment_||this.pendingSegment_.requestId!==e:(this.state="READY",!0)},n.error=function(e){return"undefined"!==typeof e&&(this.logger_("error occurred:",e),this.error_=e),this.pendingSegment_=null,this.error_},n.endOfStream=function(){this.ended_=!0,this.transmuxer_&&oc(this.transmuxer_),this.gopBuffer_.length=0,this.pause(),this.trigger("ended")},n.buffered_=function(){var e=this.getMediaInfo_();if(!this.sourceUpdater_||!e)return Na.createTimeRanges();if("main"===this.loaderType_){var t=e.hasAudio,n=e.hasVideo,r=e.isMuxed;if(n&&t&&!this.audioDisabled_&&!r)return this.sourceUpdater_.buffered();if(n)return this.sourceUpdater_.videoBuffered()}return this.sourceUpdater_.audioBuffered()},n.initSegmentForMap=function(e,t){if(void 0===t&&(t=!1),!e)return null;var n=Ns(e),r=this.initSegments_[n];return t&&!r&&e.bytes&&(this.initSegments_[n]=r={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:e.bytes,tracks:e.tracks,timescales:e.timescales}),r||e},n.segmentKey=function(e,t){if(void 0===t&&(t=!1),!e)return null;var n=js(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},n.couldBeginLoading_=function(){return this.playlist_&&!this.paused()},n.load=function(){if(this.monitorBuffer_(),this.playlist_)return"INIT"===this.state&&this.couldBeginLoading_()?this.init_():void(!this.couldBeginLoading_()||"READY"!==this.state&&"INIT"!==this.state||(this.state="READY"))},n.init_=function(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()},n.playlist=function(e,t){if(void 0===t&&(t={}),e){var n=this.playlist_,r=this.pendingSegment_;this.playlist_=e,this.xhrOptions_=t,"INIT"===this.state&&(e.syncInfo={mediaSequence:e.mediaSequence,time:0},"main"===this.loaderType_&&this.syncController_.setDateTimeMappingForStart(e));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 null!==this.mediaIndex&&this.resyncLoader(),this.currentMediaInfo_=void 0,void this.trigger("playlistupdate");var o=e.mediaSequence-n.mediaSequence;if(this.logger_("live window shift ["+o+"]"),null!==this.mediaIndex)if(this.mediaIndex-=o,this.mediaIndex<0)this.mediaIndex=null,this.partIndex=null;else{var a=this.playlist_.segments[this.mediaIndex];if(this.partIndex&&(!a.parts||!a.parts.length||!a.parts[this.partIndex])){var s=this.mediaIndex;this.logger_("currently processing part (index "+this.partIndex+") no longer exists."),this.resetLoader(),this.mediaIndex=s}}r&&(r.mediaIndex-=o,r.mediaIndex<0?(r.mediaIndex=null,r.partIndex=null):(r.mediaIndex>=0&&(r.segment=e.segments[r.mediaIndex]),r.partIndex>=0&&r.segment.parts&&(r.part=r.segment.parts[r.partIndex]))),this.syncController_.saveExpiredSegmentInfo(n,e)}},n.pause=function(){this.checkBufferTimeout_&&(o.a.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=null)},n.paused=function(){return null===this.checkBufferTimeout_},n.resetEverything=function(e){this.ended_=!1,this.appendInitSegment_={audio:!0,video:!0},this.resetLoader(),this.remove(0,1/0,e),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearAllMp4Captions"})},n.resetLoader=function(){this.fetchAtBuffer_=!1,this.resyncLoader()},n.resyncLoader=function(){this.transmuxer_&&oc(this.transmuxer_),this.mediaIndex=null,this.partIndex=null,this.syncPoint_=null,this.isPendingTimestampOffset_=!1,this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.abort(),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})},n.remove=function(e,t,n,r){if(void 0===n&&(n=function(){}),void 0===r&&(r=!1),t===1/0&&(t=this.duration_()),t<=e)this.logger_("skipping remove because end ${end} is <= start ${start}");else if(this.sourceUpdater_&&this.getMediaInfo_()){var i=1,o=function(){0===--i&&n()};for(var a in!r&&this.audioDisabled_||(i++,this.sourceUpdater_.removeAudio(e,t,o)),(r||"main"===this.loaderType_)&&(this.gopBuffer_=function(e,t,n,r){for(var i=Math.ceil((t-r)*Mt.ONE_SECOND_IN_TS),o=Math.ceil((n-r)*Mt.ONE_SECOND_IN_TS),a=e.slice(),s=e.length;s--&&!(e[s].pts<=o););if(-1===s)return a;for(var c=s+1;c--&&!(e[c].pts<=i););return c=Math.max(c,0),a.splice(c,s-c+1),a}(this.gopBuffer_,e,t,this.timeMapping_),i++,this.sourceUpdater_.removeVideo(e,t,o)),this.inbandTextTracks_)Nc(e,t,this.inbandTextTracks_[a]);Nc(e,t,this.segmentMetadataTrack_),o()}else this.logger_("skipping remove because no source updater or starting media info")},n.monitorBuffer_=function(){this.checkBufferTimeout_&&o.a.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=o.a.setTimeout(this.monitorBufferTick_.bind(this),1)},n.monitorBufferTick_=function(){"READY"===this.state&&this.fillBuffer_(),this.checkBufferTimeout_&&o.a.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=o.a.setTimeout(this.monitorBufferTick_.bind(this),500)},n.fillBuffer_=function(){if(!this.sourceUpdater_.updating()){var e=this.chooseNextRequest_();e&&("number"===typeof e.timestampOffset&&(this.isPendingTimestampOffset_=!1,this.timelineChangeController_.pendingTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:e.timeline})),this.loadSegment_(e))}},n.isEndOfStream_=function(e,t,n){if(void 0===e&&(e=this.mediaIndex),void 0===t&&(t=this.playlist_),void 0===n&&(n=this.partIndex),!t||!this.mediaSource_)return!1;var r="number"===typeof e&&t.segments[e],i=e+1===t.segments.length,o=!r||!r.parts||n+1===r.parts.length;return t.endList&&"open"===this.mediaSource_.readyState&&i&&o},n.chooseNextRequest_=function(){var e=Ka(this.buffered_())||0,t=Math.max(0,e-this.currentTime_()),n=!this.hasPlayed_()&&t>=1,r=t>=this.goalBufferLength_(),i=this.playlist_.segments;if(!i.length||n||r)return null;this.syncPoint_=this.syncPoint_||this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_());var o={partIndex:null,mediaIndex:null,startOfSegment:null,playlist:this.playlist_,isSyncRequest:Boolean(!this.syncPoint_)};if(o.isSyncRequest)o.mediaIndex=function(e,t,n){t=t||[];for(var r=[],i=0,o=0;on))return o}return 0===r.length?0:r[r.length-1]}(this.currentTimeline_,i,e);else if(null!==this.mediaIndex){var a=i[this.mediaIndex],s="number"===typeof this.partIndex?this.partIndex:-1;o.startOfSegment=a.end?a.end:e,a.parts&&a.parts[s+1]?(o.mediaIndex=this.mediaIndex,o.partIndex=s+1):o.mediaIndex=this.mediaIndex+1}else{var c=ds.getMediaInfoForTime({experimentalExactManifestTimings:this.experimentalExactManifestTimings,playlist:this.playlist_,currentTime:this.fetchAtBuffer_?e:this.currentTime_(),startingPartIndex:this.syncPoint_.partIndex,startingSegmentIndex:this.syncPoint_.segmentIndex,startTime:this.syncPoint_.time}),u=c.segmentIndex,l=c.startTime,d=c.partIndex;o.getMediaInfoForTime=this.fetchAtBuffer_?"bufferedEnd":"currentTime",o.mediaIndex=u,o.startOfSegment=l,o.partIndex=d}var f=i[o.mediaIndex],h=f&&"number"===typeof o.partIndex&&f.parts&&f.parts[o.partIndex];if(!f||"number"===typeof o.partIndex&&!h)return null;"number"!==typeof o.partIndex&&f.parts&&(o.partIndex=0);var p=this.mediaSource_&&"ended"===this.mediaSource_.readyState;return o.mediaIndex>=i.length-1&&p&&!this.seeking_()?null:this.generateSegmentInfo_(o)},n.generateSegmentInfo_=function(e){var t=e.playlist,n=e.mediaIndex,r=e.startOfSegment,i=e.isSyncRequest,o=e.partIndex,a=e.forceTimestampOffset,s=e.getMediaInfoForTime,c=t.segments[n],u="number"===typeof o&&c.parts[o],l={requestId:"segment-loader-"+Math.random(),uri:u&&u.resolvedUri||c.resolvedUri,mediaIndex:n,partIndex:u?o:null,isSyncRequest:i,startOfSegment:r,playlist:t,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:c.timeline,duration:u&&u.duration||c.duration,segment:c,part:u,byteLength:0,transmuxer:this.transmuxer_,getMediaInfoForTime:s},d="undefined"!==typeof a?a:this.isPendingTimestampOffset_;l.timestampOffset=this.timestampOffsetForSegment_({segmentTimeline:c.timeline,currentTimeline:this.currentTimeline_,startOfSegment:r,buffered:this.buffered_(),overrideCheck:d});var f=Ka(this.sourceUpdater_.audioBuffered());return"number"===typeof f&&(l.audioAppendStart=f-this.sourceUpdater_.audioTimestampOffset()),this.sourceUpdater_.videoBuffered().length&&(l.gopsToAlignWith=function(e,t,n){if("undefined"===typeof t||null===t||!e.length)return[];var r,i=Math.ceil((t-n+3)*Mt.ONE_SECOND_IN_TS);for(r=0;ri);r++);return e.slice(r)}(this.gopBuffer_,this.currentTime_()-this.sourceUpdater_.videoTimestampOffset(),this.timeMapping_)),l},n.timestampOffsetForSegment_=function(e){return function(e){var t=e.segmentTimeline,n=e.currentTimeline,r=e.startOfSegment,i=e.buffered;return e.overrideCheck||t!==n?t "+s+" for "+e),function(e,t,n){if(!e[n]){t.trigger({type:"usage",name:"vhs-608"}),t.trigger({type:"usage",name:"hls-608"});var r=n;/^cc708_/.test(n)&&(r="SERVICE"+n.split("_")[1]);var i=t.textTracks().getTrackById(r);if(i)e[n]=i;else{var o=n,a=n,s=!1,c=(t.options_.vhs&&t.options_.vhs.captionServices||{})[r];c&&(o=c.label,a=c.language,s=c.default),e[n]=t.addRemoteTextTrack({kind:"captions",id:r,default:s,label:o,language:a},!1).track}}}(u,n.vhs_.tech_,e),Nc(a,s,u[e]),function(e){var t=e.inbandTextTracks,n=e.captionArray,r=e.timestampOffset;if(n){var i=o.a.WebKitDataCue||o.a.VTTCue;n.forEach((function(e){var n=e.stream;t[n].addCue(new i(e.startTime+r,e.endTime+r,e.text))}))}}({captionArray:c,inbandTextTracks:u,timestampOffset:r})})),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}else this.metadataQueue_.caption.push(this.handleCaptions_.bind(this,e,t));else this.logger_("SegmentLoader received no captions from a caption event")},n.handleId3_=function(e,t,n){if(this.earlyAbortWhenNeeded_(e.stats),!this.checkForAbort_(e.requestId))if(this.pendingSegment_.hasAppendedData_){var r=null===this.sourceUpdater_.videoTimestampOffset()?this.sourceUpdater_.audioTimestampOffset():this.sourceUpdater_.videoTimestampOffset();!function(e,t,n){e.metadataTrack_||(e.metadataTrack_=n.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,e.metadataTrack_.inBandMetadataTrackDispatchType=t)}(this.inbandTextTracks_,n,this.vhs_.tech_),Dc({inbandTextTracks:this.inbandTextTracks_,metadataArray:t,timestampOffset:r,videoDuration:this.duration_()})}else this.metadataQueue_.id3.push(this.handleId3_.bind(this,e,t,n))},n.processMetadataQueue_=function(){this.metadataQueue_.id3.forEach((function(e){return e()})),this.metadataQueue_.caption.forEach((function(e){return e()})),this.metadataQueue_.id3=[],this.metadataQueue_.caption=[]},n.processCallQueue_=function(){var e=this.callQueue_;this.callQueue_=[],e.forEach((function(e){return e()}))},n.processLoadQueue_=function(){var e=this.loadQueue_;this.loadQueue_=[],e.forEach((function(e){return e()}))},n.hasEnoughInfoToLoad_=function(){if("audio"!==this.loaderType_)return!0;var e=this.pendingSegment_;return!!e&&(!this.getCurrentMediaInfo_()||!zc({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}))},n.getCurrentMediaInfo_=function(e){return void 0===e&&(e=this.pendingSegment_),e&&e.trackInfo||this.currentMediaInfo_},n.getMediaInfo_=function(e){return void 0===e&&(e=this.pendingSegment_),this.getCurrentMediaInfo_(e)||this.startingMediaInfo_},n.hasEnoughInfoToAppend_=function(){if(!this.sourceUpdater_.ready())return!1;if(this.waitingOnRemove_||this.quotaExceededErrorRetryTimeout_)return!1;var e=this.pendingSegment_,t=this.getCurrentMediaInfo_();if(!e||!t)return!1;var n=t.hasAudio,r=t.hasVideo,i=t.isMuxed;return!(r&&!e.videoTimingInfo)&&(!(n&&!this.audioDisabled_&&!i&&!e.audioTimingInfo)&&!zc({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}))},n.handleData_=function(e,t){if(this.earlyAbortWhenNeeded_(e.stats),!this.checkForAbort_(e.requestId))if(!this.callQueue_.length&&this.hasEnoughInfoToAppend_()){var n=this.pendingSegment_;if(this.setTimeMapping_(n.timeline),this.updateMediaSecondsLoaded_(n.segment),"closed"!==this.mediaSource_.readyState){if(e.map&&(e.map=this.initSegmentForMap(e.map,!0),n.segment.map=e.map),e.key&&this.segmentKey(e.key,!0),n.isFmp4=e.isFmp4,n.timingInfo=n.timingInfo||{},n.isFmp4)this.trigger("fmp4"),n.timingInfo.start=n[Bc(t.type)].start;else{var r,i=this.getCurrentMediaInfo_(),o="main"===this.loaderType_&&i&&i.hasVideo;o&&(r=n.videoTimingInfo.start),n.timingInfo.start=this.trueSegmentStart_({currentStart:n.timingInfo.start,playlist:n.playlist,mediaIndex:n.mediaIndex,currentVideoTimestampOffset:this.sourceUpdater_.videoTimestampOffset(),useVideoTimingInfo:o,firstVideoFrameTimeForData:r,videoTimingInfo:n.videoTimingInfo,audioTimingInfo:n.audioTimingInfo})}if(this.updateAppendInitSegmentStatus(n,t.type),this.updateSourceBufferTimestampOffset_(n),n.isSyncRequest){this.updateTimingInfoEnd_(n),this.syncController_.saveSegmentTimingInfo({segmentInfo:n,shouldSaveTimelineMapping:"main"===this.loaderType_});var a=this.chooseNextRequest_();if(a.mediaIndex!==n.mediaIndex||a.partIndex!==n.partIndex)return void this.logger_("sync segment was incorrect, not appending");this.logger_("sync segment was correct, appending")}n.hasAppendedData_=!0,this.processMetadataQueue_(),this.appendData_(n,t)}}else this.callQueue_.push(this.handleData_.bind(this,e,t))},n.updateAppendInitSegmentStatus=function(e,t){"main"!==this.loaderType_||"number"!==typeof e.timestampOffset||e.changedTimestampOffset||(this.appendInitSegment_={audio:!0,video:!0}),this.playlistOfLastInitSegment_[t]!==e.playlist&&(this.appendInitSegment_[t]=!0)},n.getInitSegmentAndUpdateState_=function(e){var t=e.type,n=e.initSegment,r=e.map,i=e.playlist;if(r){var o=Ns(r);if(this.activeInitSegmentId_===o)return null;n=this.initSegmentForMap(r,!0).bytes,this.activeInitSegmentId_=o}return n&&this.appendInitSegment_[t]?(this.playlistOfLastInitSegment_[t]=i,this.appendInitSegment_[t]=!1,this.activeInitSegmentId_=null,n):null},n.handleQuotaExceededError_=function(e,t){var n=this,r=e.segmentInfo,i=e.type,a=e.bytes,s=this.sourceUpdater_.audioBuffered(),c=this.sourceUpdater_.videoBuffered();s.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the audio buffer: "+Ha(s).join(", ")),c.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the video buffer: "+Ha(c).join(", "));var u=s.length?s.start(0):0,l=s.length?s.end(s.length-1):0,d=c.length?c.start(0):0,f=c.length?c.end(c.length-1):0;if(l-u<=1&&f-d<=1)return this.logger_("On QUOTA_EXCEEDED_ERR, single segment too large to append to buffer, triggering an error. Appended byte length: "+a.byteLength+", audio buffer: "+Ha(s).join(", ")+", video buffer: "+Ha(c).join(", ")+", "),this.error({message:"Quota exceeded error with append of a single segment of content",excludeUntil:1/0}),void this.trigger("error");this.waitingOnRemove_=!0,this.callQueue_.push(this.appendToSourceBuffer_.bind(this,{segmentInfo:r,type:i,bytes:a}));var h=this.currentTime_()-1;this.logger_("On QUOTA_EXCEEDED_ERR, removing audio/video from 0 to "+h),this.remove(0,h,(function(){n.logger_("On QUOTA_EXCEEDED_ERR, retrying append in 1s"),n.waitingOnRemove_=!1,n.quotaExceededErrorRetryTimeout_=o.a.setTimeout((function(){n.logger_("On QUOTA_EXCEEDED_ERR, re-processing call queue"),n.quotaExceededErrorRetryTimeout_=null,n.processCallQueue_()}),1e3)}),!0)},n.handleAppendError_=function(e,t){var n=e.segmentInfo,r=e.type,i=e.bytes;t&&(22!==t.code?(this.logger_("Received non QUOTA_EXCEEDED_ERR on append",t),this.error(r+" append of "+i.length+"b failed for segment #"+n.mediaIndex+" in playlist "+n.playlist.id),this.trigger("appenderror")):this.handleQuotaExceededError_({segmentInfo:n,type:r,bytes:i}))},n.appendToSourceBuffer_=function(e){var t=e.segmentInfo,n=e.type,r=e.initSegment,i=e.data,o=e.bytes;if(!o){var a=[i],s=i.byteLength;r&&(a.unshift(r),s+=r.byteLength),o=function(e){var t,n=0;return e.bytes&&(t=new Uint8Array(e.bytes),e.segments.forEach((function(e){t.set(e,n),n+=e.byteLength}))),t}({bytes:s,segments:a})}this.sourceUpdater_.appendBuffer({segmentInfo:t,type:n,bytes:o},this.handleAppendError_.bind(this,{segmentInfo:t,type:n,bytes:o}))},n.handleSegmentTimingInfo_=function(e,t,n){if(this.pendingSegment_&&t===this.pendingSegment_.requestId){var r=this.pendingSegment_.segment,i=e+"TimingInfo";r[i]||(r[i]={}),r[i].transmuxerPrependedSeconds=n.prependedContentDuration||0,r[i].transmuxedPresentationStart=n.start.presentation,r[i].transmuxedDecodeStart=n.start.decode,r[i].transmuxedPresentationEnd=n.end.presentation,r[i].transmuxedDecodeEnd=n.end.decode,r[i].baseMediaDecodeTime=n.baseMediaDecodeTime}},n.appendData_=function(e,t){var n=t.type,r=t.data;if(r&&r.byteLength&&("audio"!==n||!this.audioDisabled_)){var i=this.getInitSegmentAndUpdateState_({type:n,initSegment:t.initSegment,playlist:e.playlist,map:e.isFmp4?e.segment.map:null});this.appendToSourceBuffer_({segmentInfo:e,type:n,initSegment:i,data:r})}},n.loadSegment_=function(e){var t=this;this.state="WAITING",this.pendingSegment_=e,this.trimBackBuffer_(e),"number"===typeof e.timestampOffset&&this.transmuxer_&&this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),this.hasEnoughInfoToLoad_()?this.updateTransmuxerAndRequestSegment_(e):this.loadQueue_.push((function(){var n=u()({},e,{forceTimestampOffset:!0});u()(e,t.generateSegmentInfo_(n)),t.isPendingTimestampOffset_=!1,t.updateTransmuxerAndRequestSegment_(e)}))},n.updateTransmuxerAndRequestSegment_=function(e){var t=this;this.shouldUpdateTransmuxerTimestampOffset_(e.timestampOffset)&&(this.gopBuffer_.length=0,e.gopsToAlignWith=[],this.timeMapping_=0,this.transmuxer_.postMessage({action:"reset"}),this.transmuxer_.postMessage({action:"setTimestampOffset",timestampOffset:e.timestampOffset}));var n=this.createSimplifiedSegmentObj_(e),r=this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex),i=null!==this.mediaIndex,o=e.timeline!==this.currentTimeline_&&e.timeline>0,a=r||i&&o;this.logger_("Requesting "+Lc(e)),n.map&&!n.map.bytes&&(this.logger_("going to request init segment."),this.appendInitSegment_={video:!0,audio:!0}),e.abortRequests=Sc({xhr:this.vhs_.xhr,xhrOptions:this.xhrOptions_,decryptionWorker:this.decrypter_,segment:n,abortFn:this.handleAbort_.bind(this,e),progressFn:this.handleProgress_.bind(this),trackInfoFn:this.handleTrackInfo_.bind(this),timingInfoFn:this.handleTimingInfo_.bind(this),videoSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"video",e.requestId),audioSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"audio",e.requestId),captionsFn:this.handleCaptions_.bind(this),isEndOfTimeline:a,endedTimelineFn:function(){t.logger_("received endedtimeline callback")},id3Fn:this.handleId3_.bind(this),dataFn:this.handleData_.bind(this),doneFn:this.segmentRequestFinished_.bind(this),onTransmuxerLog:function(n){var r=n.message,i=n.level,o=n.stream;t.logger_(Lc(e)+" logged from transmuxer stream "+o+" as a "+i+": "+r)}})},n.trimBackBuffer_=function(e){var t=function(e,t,n){var r=t-Gs.BACK_BUFFER_LENGTH;e.length&&(r=Math.max(r,e.start(0)));var i=t-n;return Math.min(i,r)}(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);t>0&&this.remove(0,t)},n.createSimplifiedSegmentObj_=function(e){var t=e.segment,n=e.part,r={resolvedUri:n?n.resolvedUri:t.resolvedUri,byterange:n?n.byterange:t.byterange,requestId:e.requestId,transmuxer:e.transmuxer,audioAppendStart:e.audioAppendStart,gopsToAlignWith:e.gopsToAlignWith,part:e.part},i=e.playlist.segments[e.mediaIndex-1];if(i&&i.timeline===t.timeline&&(i.videoTimingInfo?r.baseStartTime=i.videoTimingInfo.transmuxedDecodeEnd:i.audioTimingInfo&&(r.baseStartTime=i.audioTimingInfo.transmuxedDecodeEnd)),t.key){var o=t.key.iv||new Uint32Array([0,0,0,e.mediaIndex+e.playlist.mediaSequence]);r.key=this.segmentKey(t.key),r.key.iv=o}return t.map&&(r.map=this.initSegmentForMap(t.map)),r},n.saveTransferStats_=function(e){this.mediaRequests+=1,e&&(this.mediaBytesTransferred+=e.bytesReceived,this.mediaTransferDuration+=e.roundTripTime)},n.saveBandwidthRelatedStats_=function(e,t){this.pendingSegment_.byteLength=t.bytesReceived,e<1/60?this.logger_("Ignoring segment's bandwidth because its duration of "+e+" is less than the min to record "+1/60):(this.bandwidth=t.bandwidth,this.roundTrip=t.roundTripTime)},n.handleTimeout_=function(){this.mediaRequestsTimedout+=1,this.bandwidth=1,this.roundTrip=NaN,this.trigger("bandwidthupdate")},n.segmentRequestFinished_=function(e,t,n){if(this.callQueue_.length)this.callQueue_.push(this.segmentRequestFinished_.bind(this,e,t,n));else if(this.saveTransferStats_(t.stats),this.pendingSegment_&&t.requestId===this.pendingSegment_.requestId){if(e){if(this.pendingSegment_=null,this.state="READY",e.code===lc)return;return this.pause(),e.code===uc?void this.handleTimeout_():(this.mediaRequestsErrored+=1,this.error(e),void this.trigger("error"))}var r=this.pendingSegment_;this.saveBandwidthRelatedStats_(r.duration,t.stats),r.endOfAllRequests=t.endOfAllRequests,n.gopInfo&&(this.gopBuffer_=function(e,t,n){if(!t.length)return e;if(n)return t.slice();for(var r=t[0].pts,i=0;i=r);i++);return e.slice(0,i).concat(t)}(this.gopBuffer_,n.gopInfo,this.safeAppend_)),this.state="APPENDING",this.trigger("appending"),this.waitForAppendsToComplete_(r)}},n.setTimeMapping_=function(e){var t=this.syncController_.mappingForTimeline(e);null!==t&&(this.timeMapping_=t)},n.updateMediaSecondsLoaded_=function(e){"number"===typeof e.start&&"number"===typeof e.end?this.mediaSecondsLoaded+=e.end-e.start:this.mediaSecondsLoaded+=e.duration},n.shouldUpdateTransmuxerTimestampOffset_=function(e){return null!==e&&("main"===this.loaderType_&&e!==this.sourceUpdater_.videoTimestampOffset()||!this.audioDisabled_&&e!==this.sourceUpdater_.audioTimestampOffset())},n.trueSegmentStart_=function(e){var t=e.currentStart,n=e.playlist,r=e.mediaIndex,i=e.firstVideoFrameTimeForData,o=e.currentVideoTimestampOffset,a=e.useVideoTimingInfo,s=e.videoTimingInfo,c=e.audioTimingInfo;if("undefined"!==typeof t)return t;if(!a)return c.start;var u=n.segments[r-1];return 0!==r&&u&&"undefined"!==typeof u.start&&u.end===i+o?s.start:i},n.waitForAppendsToComplete_=function(e){var t=this.getCurrentMediaInfo_(e);if(!t)return this.error({message:"No starting media returned, likely due to an unsupported media format.",blacklistDuration:1/0}),void this.trigger("error");var n=t.hasAudio,r=t.hasVideo,i=t.isMuxed,o="main"===this.loaderType_&&r,a=!this.audioDisabled_&&n&&!i;if(e.waitingOnAppends=0,!e.hasAppendedData_)return e.timingInfo||"number"!==typeof e.timestampOffset||(this.isPendingTimestampOffset_=!0),e.timingInfo={start:0},e.waitingOnAppends++,this.isPendingTimestampOffset_||(this.updateSourceBufferTimestampOffset_(e),this.processMetadataQueue_()),void this.checkAppendsDone_(e);o&&e.waitingOnAppends++,a&&e.waitingOnAppends++,o&&this.sourceUpdater_.videoQueueCallback(this.checkAppendsDone_.bind(this,e)),a&&this.sourceUpdater_.audioQueueCallback(this.checkAppendsDone_.bind(this,e))},n.checkAppendsDone_=function(e){this.checkForAbort_(e.requestId)||(e.waitingOnAppends--,0===e.waitingOnAppends&&this.handleAppendsDone_())},n.checkForIllegalMediaSwitch=function(e){var t=function(e,t,n){return"main"===e&&t&&n?n.hasAudio||n.hasVideo?t.hasVideo&&!n.hasVideo?"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.hasVideo&&n.hasVideo?"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}(this.loaderType_,this.getCurrentMediaInfo_(),e);return!!t&&(this.error({message:t,blacklistDuration:1/0}),this.trigger("error"),!0)},n.updateSourceBufferTimestampOffset_=function(e){if(null!==e.timestampOffset&&"number"===typeof e.timingInfo.start&&!e.changedTimestampOffset&&"main"===this.loaderType_){var t=!1;e.timestampOffset-=e.timingInfo.start,e.changedTimestampOffset=!0,e.timestampOffset!==this.sourceUpdater_.videoTimestampOffset()&&(this.sourceUpdater_.videoTimestampOffset(e.timestampOffset),t=!0),e.timestampOffset!==this.sourceUpdater_.audioTimestampOffset()&&(this.sourceUpdater_.audioTimestampOffset(e.timestampOffset),t=!0),t&&this.trigger("timestampoffset")}},n.updateTimingInfoEnd_=function(e){e.timingInfo=e.timingInfo||{};var t=this.getMediaInfo_(),n="main"===this.loaderType_&&t&&t.hasVideo&&e.videoTimingInfo?e.videoTimingInfo:e.audioTimingInfo;n&&(e.timingInfo.end="number"===typeof n.end?n.end:n.start+e.duration)},n.handleAppendsDone_=function(){if(this.pendingSegment_&&this.trigger("appendsdone"),!this.pendingSegment_)return this.state="READY",void(this.paused()||this.monitorBuffer_());var e=this.pendingSegment_;this.updateTimingInfoEnd_(e),this.shouldSaveSegmentTimingInfo_&&this.syncController_.saveSegmentTimingInfo({segmentInfo:e,shouldSaveTimelineMapping:"main"===this.loaderType_});var t=Uc(e,this.sourceType_);if(t&&("warn"===t.severity?Na.log.warn(t.message):this.logger_(t.message)),this.recordThroughput_(e),this.pendingSegment_=null,this.state="READY",!e.isSyncRequest||(this.trigger("syncinfoupdate"),e.hasAppendedData_)){this.logger_("Appended "+Lc(e)),this.addSegmentMetadataCue_(e),this.fetchAtBuffer_=!0,this.currentTimeline_!==e.timeline&&(this.timelineChangeController_.lastTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:e.timeline}),"main"!==this.loaderType_||this.audioDisabled_||this.timelineChangeController_.lastTimelineChange({type:"audio",from:this.currentTimeline_,to:e.timeline})),this.currentTimeline_=e.timeline,this.trigger("syncinfoupdate");var n=e.segment;if(n.end&&this.currentTime_()-n.end>3*e.playlist.targetDuration)this.resetEverything();else null!==this.mediaIndex&&this.trigger("bandwidthupdate"),this.trigger("progress"),this.mediaIndex=e.mediaIndex,this.partIndex=e.partIndex,this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex)&&this.endOfStream(),this.trigger("appended"),e.hasAppendedData_&&this.mediaAppends++,this.paused()||this.monitorBuffer_()}else this.logger_("Throwing away un-appended sync request "+Lc(e))},n.recordThroughput_=function(e){if(e.duration<1/60)this.logger_("Ignoring segment's throughput because its duration of "+e.duration+" is less than the min to record "+1/60);else{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}},n.addSegmentMetadataCue_=function(e){if(this.segmentMetadataTrack_){var t=e.segment,n=t.start,r=t.end;if(jc(n)&&jc(r)){Nc(n,r,this.segmentMetadataTrack_);var i=o.a.WebKitDataCue||o.a.VTTCue,a={custom:t.custom,dateTimeObject:t.dateTimeObject,dateTimeString:t.dateTimeString,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.id,start:n,end:r},s=new i(n,r,JSON.stringify(a));s.value=a,this.segmentMetadataTrack_.addCue(s)}}},t}(Na.EventTarget);function Vc(){}var Wc,Hc=function(e){return"string"!==typeof e?e:e.replace(/./,(function(e){return e.toUpperCase()}))},Kc=["video","audio"],Zc=function(e,t){var n=t[e+"Buffer"];return n&&n.updating||t.queuePending[e]},Gc=function e(t,n){if(0!==n.queue.length){var r=0,i=n.queue[r];if("mediaSource"!==i.type){if("mediaSource"!==t&&n.ready()&&"closed"!==n.mediaSource.readyState&&!Zc(t,n)){if(i.type!==t){if(null===(r=function(e,t){for(var n=0;n=e.playlist.segments.length){e=null;break}e=this.generateSegmentInfo_({playlist:e.playlist,mediaIndex:e.mediaIndex+1,startOfSegment:e.startOfSegment+e.duration,isSyncRequest:e.isSyncRequest})}return e},n.stopForError=function(e){this.error(e),this.state="READY",this.pause(),this.trigger("error")},n.segmentRequestFinished_=function(e,t,n){var r=this;if(this.subtitlesTrack_){if(this.saveTransferStats_(t.stats),!this.pendingSegment_)return this.state="READY",void(this.mediaRequestsAborted+=1);if(e)return e.code===uc&&this.handleTimeout_(),e.code===lc?this.mediaRequestsAborted+=1:this.mediaRequestsErrored+=1,void this.stopForError(e);var i=this.pendingSegment_;this.saveBandwidthRelatedStats_(i.duration,t.stats),this.state="APPENDING",this.trigger("appending");var a=i.segment;if(a.map&&(a.map.bytes=t.map.bytes),i.bytes=t.bytes,"function"!==typeof o.a.WebVTT&&this.subtitlesTrack_&&this.subtitlesTrack_.tech_){var s,c=function(){r.subtitlesTrack_.tech_.off("vttjsloaded",s),r.stopForError({message:"Error loading vtt.js"})};return s=function(){r.subtitlesTrack_.tech_.off("vttjserror",c),r.segmentRequestFinished_(e,t,n)},this.state="WAITING_ON_VTTJS",this.subtitlesTrack_.tech_.one("vttjsloaded",s),void this.subtitlesTrack_.tech_.one("vttjserror",c)}a.requested=!0;try{this.parseVTTCues_(i)}catch(u){return void this.stopForError({message:u.message})}if(this.updateTimeMapping_(i,this.syncController_.timelines[i.timeline],this.playlist_),i.cues.length?i.timingInfo={start:i.cues[0].startTime,end:i.cues[i.cues.length-1].endTime}:i.timingInfo={start:i.startOfSegment,end:i.startOfSegment+i.duration},i.isSyncRequest)return this.trigger("syncinfoupdate"),this.pendingSegment_=null,void(this.state="READY");i.byteLength=i.bytes.byteLength,this.mediaSecondsLoaded+=a.duration,i.cues.forEach((function(e){r.subtitlesTrack_.addCue(r.featuresNativeTextTracks_?new o.a.VTTCue(e.startTime,e.endTime,e.text):e)})),function(e){var t=e.cues;if(t)for(var n=0;n1&&r.push(t[o]);r.length&&r.forEach((function(t){return e.removeCue(t)}))}}(this.subtitlesTrack_),this.handleAppendsDone_()}else this.state="READY"},n.handleData_=function(){},n.updateTimingInfoEnd_=function(){},n.parseVTTCues_=function(e){var t,n=!1;"function"===typeof o.a.TextDecoder?t=new o.a.TextDecoder("utf8"):(t=o.a.WebVTT.StringDecoder(),n=!0);var r=new o.a.WebVTT.Parser(o.a,o.a.vttjs,t);if(e.cues=[],e.timestampmap={MPEGTS:0,LOCAL:0},r.oncue=e.cues.push.bind(e.cues),r.ontimestampmap=function(t){e.timestampmap=t},r.onparsingerror=function(e){Na.log.warn("Error encountered when parsing cues: "+e.message)},e.segment.map){var i=e.segment.map.bytes;n&&(i=lu(i)),r.parse(i)}var a=e.bytes;n&&(a=lu(a)),r.parse(a),r.flush()},n.updateTimeMapping_=function(e,t,n){var r=e.segment;if(t)if(e.cues.length){var i=e.timestampmap,o=i.MPEGTS/Mt.ONE_SECOND_IN_TS-i.LOCAL+t.mapping;if(e.cues.forEach((function(e){e.startTime+=o,e.endTime+=o})),!n.syncInfo){var a=e.cues[0].startTime,s=e.cues[e.cues.length-1].startTime;n.syncInfo={mediaSequence:n.mediaSequence+e.mediaIndex,time:Math.min(a,s-r.duration)}}}else r.empty=!0},t}(qc),hu=function(e,t){for(var n=e.cues,r=0;r=i.adStartTime&&t<=i.adEndTime)return i}return null},pu=[{name:"VOD",run:function(e,t,n,r,i){if(n!==1/0){return{time:0,segmentIndex:0,partIndex:null}}return null}},{name:"ProgramDateTime",run:function(e,t,n,r,i){if(!Object.keys(e.timelineToDatetimeMappings).length)return null;var o=null,a=null,s=Xa(t);i=i||0;for(var c=0;c=f)&&(a=f,o={time:d,segmentIndex:u.segmentIndex,partIndex:u.partIndex})}}return o}},{name:"Discontinuity",run:function(e,t,n,r,i){var o=null;if(i=i||0,t.discontinuityStarts&&t.discontinuityStarts.length)for(var a=null,s=0;s=d)&&(a=d,o={time:l.time,segmentIndex:c,partIndex:null})}}return o}},{name:"Playlist",run:function(e,t,n,r,i){return t.syncInfo?{time:t.syncInfo.time,segmentIndex:t.syncInfo.mediaSequence-t.mediaSequence,partIndex:null}:null}}],mu=function(e){function t(t){var n;return(n=e.call(this)||this).timelines=[],n.discontinuities=[],n.timelineToDatetimeMappings={},n.logger_=Fa("SyncController"),n}h()(t,e);var n=t.prototype;return n.getSyncPoint=function(e,t,n,r){var i=this.runStrategies_(e,t,n,r);return i.length?this.selectSyncPoint_(i,{key:"time",value:r}):null},n.getExpiredTime=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+ts({defaultDuration:e.targetDuration,durationList:e.segments,startIndex:r.segmentIndex,endIndex:0}))},n.runStrategies_=function(e,t,n,r){for(var i=[],o=0;o86400)Na.log.warn("Not saving expired segment info. Media sequence gap "+n+" is too large.");else for(var r=n-1;r>=0;r--){var i=e.segments[r];if(i&&"undefined"!==typeof 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}}},n.setDateTimeMappingForStart=function(e){if(this.timelineToDatetimeMappings={},e.segments&&e.segments.length&&e.segments[0].dateTimeObject){var t=e.segments[0],n=t.dateTimeObject.getTime()/1e3;this.timelineToDatetimeMappings[t.timeline]=-n}},n.saveSegmentTimingInfo=function(e){var t=e.segmentInfo,n=e.shouldSaveTimelineMapping,r=this.calculateSegmentTimeMapping_(t,t.timingInfo,n),i=t.segment;r&&(this.saveDiscontinuitySyncInfo_(t),t.playlist.syncInfo||(t.playlist.syncInfo={mediaSequence:t.playlist.mediaSequence+t.mediaIndex,time:i.start}));var o=i.dateTimeObject;i.discontinuity&&n&&o&&(this.timelineToDatetimeMappings[i.timeline]=-o.getTime()/1e3)},n.timestampOffsetForTimeline=function(e){return"undefined"===typeof this.timelines[e]?null:this.timelines[e].time},n.mappingForTimeline=function(e){return"undefined"===typeof this.timelines[e]?null:this.timelines[e].mapping},n.calculateSegmentTimeMapping_=function(e,t,n){var r,i,o=e.segment,a=e.part,s=this.timelines[e.timeline];if("number"===typeof e.timestampOffset)s={time:e.startOfSegment,mapping:e.startOfSegment-t.start},n&&(this.timelines[e.timeline]=s,this.trigger("timestampoffset"),this.logger_("time mapping for timeline "+e.timeline+": [time: "+s.time+"] [mapping: "+s.mapping+"]")),r=e.startOfSegment,i=t.end+s.mapping;else{if(!s)return!1;r=t.start+s.mapping,i=t.end+s.mapping}return a&&(a.start=r,a.end=i),(!o.start||rs){var c=void 0;c=a<0?n.start-ts({defaultDuration:t.targetDuration,durationList:t.segments,startIndex:e.mediaIndex,endIndex:i}):n.end+ts({defaultDuration:t.targetDuration,durationList:t.segments,startIndex:e.mediaIndex+1,endIndex:i}),this.discontinuities[o]={time:c,accuracy:s}}}},n.dispose=function(){this.trigger("dispose"),this.off()},t}(Na.EventTarget),gu=function(e){function t(){var t;return(t=e.call(this)||this).pendingTimelineChanges_={},t.lastTimelineChanges_={},t}h()(t,e);var n=t.prototype;return n.clearPendingTimelineChange=function(e){this.pendingTimelineChanges_[e]=null,this.trigger("pendingtimelinechange")},n.pendingTimelineChange=function(e){var t=e.type,n=e.from,r=e.to;return"number"===typeof n&&"number"===typeof r&&(this.pendingTimelineChanges_[t]={type:t,from:n,to:r},this.trigger("pendingtimelinechange")),this.pendingTimelineChanges_[t]},n.lastTimelineChange=function(e){var t=e.type,n=e.from,r=e.to;return"number"===typeof n&&"number"===typeof r&&(this.lastTimelineChanges_[t]={type:t,from:n,to:r},delete this.pendingTimelineChanges_[t],this.trigger("timelinechange")),this.lastTimelineChanges_[t]},n.dispose=function(){this.trigger("dispose"),this.pendingTimelineChanges_={},this.lastTimelineChanges_={},this.off()},t}(Na.EventTarget),vu=Ys($s(Js((function(){function e(e,t,n){return e(n={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}((void 0===t||null===t)&&n.path)}},n.exports),n.exports}var t=e((function(e){function t(e,t){for(var n=0;n-1},t.trigger=function(e){var t=this.listeners[e];if(t)if(2===arguments.length)for(var n=t.length,r=0;r>7))^e]=e;for(t=n=0;!d[t];t^=r||1,n=p[n]||1)for(o=(o=n^n<<1^n<<2^n<<3^n<<4)>>8^255&o^99,d[t]=o,f[o]=t,s=16843009*h[i=h[r=h[t]]]^65537*i^257*r^16843008*t,a=257*h[o]^16843008*o,e=0;e<4;e++)u[e][t]=a=a<<24^a>>>8,l[e][o]=s=s<<24^s>>>8;for(e=0;e<5;e++)u[e]=u[e].slice(0),l[e]=l[e].slice(0);return c}()),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 i=this._tables[0][4],a=this._tables[1],s=e.length,c=1;if(4!==s&&6!==s&&8!==s)throw new Error("Invalid aes key size");var u=e.slice(0),l=[];for(this._key=[u,l],t=s;t<4*s+28;t++)r=u[t-1],(t%s===0||8===s&&t%s===4)&&(r=i[r>>>24]<<24^i[r>>16&255]<<16^i[r>>8&255]<<8^i[255&r],t%s===0&&(r=r<<8^r>>>24^c<<24,c=c<<1^283*(c>>7))),u[t]=u[t-s]^r;for(n=0;t;n++,t--)r=u[3&n?t:t-4],l[n]=t<=4||n<4?r:a[0][i[r>>>24]]^a[1][i[r>>16&255]]^a[2][i[r>>8&255]]^a[3][i[255&r]]}return e.prototype.decrypt=function(e,t,n,r,i,o){var a,s,c,u,l=this._key[1],d=e^l[0],f=r^l[1],h=n^l[2],p=t^l[3],m=l.length/4-2,g=4,v=this._tables[1],b=v[0],y=v[1],w=v[2],S=v[3],_=v[4];for(u=0;u>>24]^y[f>>16&255]^w[h>>8&255]^S[255&p]^l[g],s=b[f>>>24]^y[h>>16&255]^w[p>>8&255]^S[255&d]^l[g+1],c=b[h>>>24]^y[p>>16&255]^w[d>>8&255]^S[255&f]^l[g+2],p=b[p>>>24]^y[d>>16&255]^w[f>>8&255]^S[255&h]^l[g+3],g+=4,d=a,f=s,h=c;for(u=0;u<4;u++)i[(3&-u)+o]=_[d>>>24]<<24^_[f>>16&255]<<16^_[h>>8&255]<<8^_[255&p]^l[g++],a=d,d=f,f=h,h=p,p=a},e}(),s=function(e){function t(){var t;return(t=e.call(this,i)||this).jobs=[],t.delay=1,t.timeout_=null,t}r(t,e);var n=t.prototype;return n.processJob_=function(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null},n.push=function(e){this.jobs.push(e),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))},t}(i),c=function(e){return e<<24|(65280&e)<<8|(16711680&e)>>8|e>>>24},u=function(){function e(t,n,r,i){var o=e.STEP,a=new Int32Array(t.buffer),u=new Uint8Array(t.byteLength),l=0;for(this.asyncStream_=new s,this.asyncStream_.push(this.decryptChunk_(a.subarray(l,l+o),n,r,u)),l=o;l>2),m=new a(Array.prototype.slice.call(t)),g=new Uint8Array(e.byteLength),v=new Int32Array(g.buffer);for(r=n[0],i=n[1],o=n[2],s=n[3],h=0;h=0&&(t="main-desc"),t},yu=function(e,t){e.abort(),e.pause(),t&&t.activePlaylistLoader&&(t.activePlaylistLoader.pause(),t.activePlaylistLoader=null)},wu=function(e,t){t.activePlaylistLoader=e,e.load()},Su={AUDIO:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e],i=t.blacklistCurrentPlaylist;yu(n,r);var o=r.activeTrack(),a=r.activeGroup(),s=(a.filter((function(e){return e.default}))[0]||a[0]).id,c=r.tracks[s];if(o!==c){for(var u in Na.log.warn("Problem encountered loading the alternate audio track.Switching back to default."),r.tracks)r.tracks[u].enabled=r.tracks[u]===c;r.onTrackChanged()}else i({message:"Problem encountered loading the default audio track."})}},SUBTITLES:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e];Na.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track."),yu(n,r);var i=r.activeTrack();i&&(i.mode="disabled"),r.onTrackChanged()}}},_u={AUDIO:function(e,t,n){if(t){var r=n.tech,i=n.requestOptions,o=n.segmentLoaders[e];t.on("loadedmetadata",(function(){var e=t.media();o.playlist(e,i),(!r.paused()||e.endList&&"none"!==r.preload())&&o.load()})),t.on("loadedplaylist",(function(){o.playlist(t.media(),i),r.paused()||o.load()})),t.on("error",Su[e](e,n))}},SUBTITLES:function(e,t,n){var r=n.tech,i=n.requestOptions,o=n.segmentLoaders[e],a=n.mediaTypes[e];t.on("loadedmetadata",(function(){var e=t.media();o.playlist(e,i),o.track(a.activeTrack()),(!r.paused()||e.endList&&"none"!==r.preload())&&o.load()})),t.on("loadedplaylist",(function(){o.playlist(t.media(),i),r.paused()||o.load()})),t.on("error",Su[e](e,n))}},ku={AUDIO:function(e,t){var n=t.vhs,r=t.sourceType,i=t.segmentLoaders[e],o=t.requestOptions,a=t.master.mediaGroups,s=t.mediaTypes[e],c=s.groups,u=s.tracks,l=s.logger_,d=t.masterPlaylistLoader,f=ls(d.master);for(var h in a[e]&&0!==Object.keys(a[e]).length||(a[e]={main:{default:{default:!0}}},f&&(a[e].main.default.playlists=d.master.playlists)),a[e])for(var p in c[h]||(c[h]=[]),a[e][h]){var m=a[e][h][p],g=void 0;if(f?(l("AUDIO group '"+h+"' label '"+p+"' is a master playlist"),m.isMasterPlaylist=!0,g=null):g="vhs-json"===r&&m.playlists?new Es(m.playlists[0],n,o):m.resolvedUri?new Es(m.resolvedUri,n,o):m.playlists&&"dash"===r?new Zs(m.playlists[0],n,o,d):null,m=Na.mergeOptions({id:p,playlistLoader:g},m),_u[e](e,m.playlistLoader,t),c[h].push(m),"undefined"===typeof u[p]){var v=new Na.AudioTrack({id:p,kind:bu(m),enabled:!1,language:m.language,default:m.default,label:p});u[p]=v}}i.on("error",Su[e](e,t))},SUBTITLES:function(e,t){var n=t.tech,r=t.vhs,i=t.sourceType,o=t.segmentLoaders[e],a=t.requestOptions,s=t.master.mediaGroups,c=t.mediaTypes[e],u=c.groups,l=c.tracks,d=t.masterPlaylistLoader;for(var f in s[e])for(var h in u[f]||(u[f]=[]),s[e][f])if(!s[e][f][h].forced){var p=s[e][f][h],m=void 0;if("hls"===i)m=new Es(p.resolvedUri,r,a);else if("dash"===i){if(!p.playlists.filter((function(e){return e.excludeUntil!==1/0})).length)return;m=new Zs(p.playlists[0],r,a,d)}else"vhs-json"===i&&(m=new Es(p.playlists?p.playlists[0]:p.resolvedUri,r,a));if(p=Na.mergeOptions({id:h,playlistLoader:m},p),_u[e](e,p.playlistLoader,t),u[f].push(p),"undefined"===typeof l[h]){var g=n.addRemoteTextTrack({id:h,kind:"subtitles",default:p.default&&p.autoselect,language:p.language,label:h},!1).track;l[h]=g}}o.on("error",Su[e](e,t))},"CLOSED-CAPTIONS":function(e,t){var n=t.tech,r=t.master.mediaGroups,i=t.mediaTypes[e],o=i.groups,a=i.tracks;for(var s in r[e])for(var c in o[s]||(o[s]=[]),r[e][s]){var u=r[e][s][c];if(/^(?:CC|SERVICE)/.test(u.instreamId)){var l=n.options_.vhs&&n.options_.vhs.captionServices||{},d={label:c,language:u.language,instreamId:u.instreamId,default:u.default&&u.autoselect};if(l[d.instreamId]&&(d=Na.mergeOptions(d,l[d.instreamId])),void 0===d.default&&delete d.default,o[s].push(Na.mergeOptions({id:c},u)),"undefined"===typeof a[c]){var f=n.addRemoteTextTrack({id:d.instreamId,kind:"captions",default:d.default,language:d.language,label:d.label},!1).track;a[c]=f}}}}},xu=function e(t,n){for(var r=0;r1&&ls(t.master))for(var c=0;c "+o+" from "+t),this.tech_.trigger({type:"usage",name:"vhs-rendition-change-"+t})),this.masterPlaylistLoader_.media(e,n)},n.startABRTimer_=function(){var e=this;this.stopABRTimer_(),this.abrTimer_=o.a.setInterval((function(){return e.checkABR_()}),250)},n.stopABRTimer_=function(){this.tech_.scrubbing&&this.tech_.scrubbing()||(o.a.clearInterval(this.abrTimer_),this.abrTimer_=null)},n.getAudioTrackPlaylists_=function(){var e=this.master(),t=e&&e.playlists||[];if(!e||!e.mediaGroups||!e.mediaGroups.AUDIO)return t;var n,r=e.mediaGroups.AUDIO,i=Object.keys(r);if(Object.keys(this.mediaTypes_.AUDIO.groups).length)n=this.mediaTypes_.AUDIO.activeTrack();else{var o=r.main||i.length&&r[i[0]];for(var a in o)if(o[a].default){n={label:a};break}}if(!n)return t;var s=[];for(var c in r)if(r[c][n.label]){var u=r[c][n.label];if(u.playlists&&u.playlists.length)s.push.apply(s,u.playlists);else if(u.uri)s.push(u);else if(e.playlists.length)for(var l=0;l1&&(this.tech_.trigger({type:"usage",name:"vhs-alternate-audio"}),this.tech_.trigger({type:"usage",name:"hls-alternate-audio"})),this.useCueTags_&&(this.tech_.trigger({type:"usage",name:"vhs-playlist-cue-tags"}),this.tech_.trigger({type:"usage",name:"hls-playlist-cue-tags"}))},n.shouldSwitchToMedia_=function(e){var t=this.masterPlaylistLoader_.media(),n=this.tech_.buffered();return function(e){var t=e.currentPlaylist,n=e.nextPlaylist,r=e.forwardBuffer,i=e.bufferLowWaterLine,o=e.bufferHighWaterLine,a=e.duration,s=e.experimentalBufferBasedABR,c=e.log;if(!n)return Na.log.warn("We received no playlist to switch to. Please check your stream."),!1;var u="allowing switch "+(t&&t.id||"null")+" -> "+n.id;if(!t)return c(u+" as current playlist is not set"),!0;if(n.id===t.id)return!1;if(!t.endList)return c(u+" as current playlist is live"),!0;var l=s?Gs.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:Gs.MAX_BUFFER_LOW_WATER_LINE;if(af)&&r>=i){var p=u+" as forwardBuffer >= bufferLowWaterLine ("+r+" >= "+i+")";return s&&(p+=" and next bandwidth > current bandwidth ("+d+" > "+f+")"),c(p),!0}return c("not "+u+" as no switching criteria met"),!1}({currentPlaylist:t,nextPlaylist:e,forwardBuffer:n.length?n.end(n.length-1)-this.tech_.currentTime():0,bufferLowWaterLine:this.bufferLowWaterLine(),bufferHighWaterLine:this.bufferHighWaterLine(),duration:this.duration(),experimentalBufferBasedABR:this.experimentalBufferBasedABR,log:this.logger_})},n.setupSegmentLoaderListeners_=function(){var e=this;this.experimentalBufferBasedABR||(this.mainSegmentLoader_.on("bandwidthupdate",(function(){var t=e.selectPlaylist();e.shouldSwitchToMedia_(t)&&e.switchMedia_(t,"bandwidthupdate"),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("appenderror",(function(){e.error=e.mainSegmentLoader_.error_,e.trigger("error")})),this.mainSegmentLoader_.on("syncinfoupdate",(function(){e.onSyncInfoUpdate_()})),this.mainSegmentLoader_.on("timestampoffset",(function(){e.tech_.trigger({type:"usage",name:"vhs-timestamp-offset"}),e.tech_.trigger({type:"usage",name:"hls-timestamp-offset"})})),this.audioSegmentLoader_.on("syncinfoupdate",(function(){e.onSyncInfoUpdate_()})),this.audioSegmentLoader_.on("appenderror",(function(){e.error=e.audioSegmentLoader_.error_,e.trigger("error")})),this.mainSegmentLoader_.on("ended",(function(){e.logger_("main segment loader ended"),e.onEndOfStream()})),this.mainSegmentLoader_.on("earlyabort",(function(t){e.experimentalBufferBasedABR||(e.delegateLoaders_("all",["abort"]),e.blacklistCurrentPlaylist({message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},120))}));var t=function(){if(!e.sourceUpdater_.hasCreatedSourceBuffers())return e.tryToCreateSourceBuffers_();var t=e.getCodecsOrExclude_();t&&e.sourceUpdater_.addOrChangeSourceBuffers(t)};this.mainSegmentLoader_.on("trackinfo",t),this.audioSegmentLoader_.on("trackinfo",t),this.mainSegmentLoader_.on("fmp4",(function(){e.triggeredFmp4Usage||(e.tech_.trigger({type:"usage",name:"vhs-fmp4"}),e.tech_.trigger({type:"usage",name:"hls-fmp4"}),e.triggeredFmp4Usage=!0)})),this.audioSegmentLoader_.on("fmp4",(function(){e.triggeredFmp4Usage||(e.tech_.trigger({type:"usage",name:"vhs-fmp4"}),e.tech_.trigger({type:"usage",name:"hls-fmp4"}),e.triggeredFmp4Usage=!0)})),this.audioSegmentLoader_.on("ended",(function(){e.logger_("audioSegmentLoader ended"),e.onEndOfStream()}))},n.mediaSecondsLoaded_=function(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)},n.load=function(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()},n.smoothQualityChange_=function(e){void 0===e&&(e=this.selectPlaylist()),this.fastQualityChange_(e)},n.fastQualityChange_=function(e){var t=this;void 0===e&&(e=this.selectPlaylist()),e!==this.masterPlaylistLoader_.media()?(this.switchMedia_(e,"fast-quality"),this.mainSegmentLoader_.resetEverything((function(){Na.browser.IE_VERSION||Na.browser.IS_EDGE?t.tech_.setCurrentTime(t.tech_.currentTime()+.04):t.tech_.setCurrentTime(t.tech_.currentTime())}))):this.logger_("skipping fastQualityChange because new media is same as old")},n.play=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()this.maxPlaylistRetries?1/0:Date.now()+1e3*t,n.excludeUntil=r,e.reason&&(n.lastExcludeReason_=e.reason),this.tech_.trigger("blacklistplaylist"),this.tech_.trigger({type:"usage",name:"vhs-rendition-blacklisted"}),this.tech_.trigger({type:"usage",name:"hls-rendition-blacklisted"});var c=this.selectPlaylist();if(!c)return this.error="Playback cannot continue. No available working or supported playlists.",void this.trigger("error");var u=e.internal?this.logger_:Na.log.warn,l=e.message?" "+e.message:"";u((e.internal?"Internal problem":"Problem")+" encountered with playlist "+n.id+"."+l+" Switching to playlist "+c.id+"."),c.attributes.AUDIO!==n.attributes.AUDIO&&this.delegateLoaders_("audio",["abort","pause"]),c.attributes.SUBTITLES!==n.attributes.SUBTITLES&&this.delegateLoaders_("subtitle",["abort","pause"]),this.delegateLoaders_("main",["abort","pause"]);var d=c.targetDuration/2*1e3||5e3,f="number"===typeof c.lastRequest&&Date.now()-c.lastRequest<=d;return this.switchMedia_(c,"exclude",a||f)},n.pauseLoading=function(){this.delegateLoaders_("all",["abort","pause"]),this.stopABRTimer_()},n.delegateLoaders_=function(e,t){var n=this,r=[],i="all"===e;(i||"main"===e)&&r.push(this.masterPlaylistLoader_);var o=[];(i||"audio"===e)&&o.push("AUDIO"),(i||"subtitle"===e)&&(o.push("CLOSED-CAPTIONS"),o.push("SUBTITLES")),o.forEach((function(e){var t=n.mediaTypes_[e]&&n.mediaTypes_[e].activePlaylistLoader;t&&r.push(t)})),["main","audio","subtitle"].forEach((function(t){var i=n[t+"SegmentLoader_"];!i||e!==t&&"all"!==e||r.push(i)})),r.forEach((function(e){return t.forEach((function(t){"function"===typeof e[t]&&e[t]()}))}))},n.setCurrentTime=function(e){var t=qa(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},n.duration=function(){if(!this.masterPlaylistLoader_)return 0;var e=this.masterPlaylistLoader_.media();return e?e.endList?this.mediaSource?this.mediaSource.duration:Wc.Playlist.duration(e):1/0:0},n.seekable=function(){return this.seekable_},n.onSyncInfoUpdate_=function(){var e;if(this.masterPlaylistLoader_){var t=this.masterPlaylistLoader_.media();if(t){var n=this.syncController_.getExpiredTime(t,this.duration());if(null!==n){var r=this.masterPlaylistLoader_.master,i=Wc.Playlist.seekable(t,n,Wc.Playlist.liveEdgeDelay(r,t));if(0!==i.length){if(this.mediaTypes_.AUDIO.activePlaylistLoader){if(t=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),null===(n=this.syncController_.getExpiredTime(t,this.duration())))return;if(0===(e=Wc.Playlist.seekable(t,n,Wc.Playlist.liveEdgeDelay(r,t))).length)return}var o,a;this.seekable_&&this.seekable_.length&&(o=this.seekable_.end(0),a=this.seekable_.start(0)),e?e.start(0)>i.end(0)||i.start(0)>e.end(0)?this.seekable_=i:this.seekable_=Na.createTimeRanges([[e.start(0)>i.start(0)?e.start(0):i.start(0),e.end(0)0&&(r=Math.max(r,n.end(n.length-1))),this.mediaSource.duration!==r&&this.sourceUpdater_.setDuration(r)}},n.dispose=function(){var e=this;this.trigger("dispose"),this.decrypter_.terminate(),this.masterPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),this.loadOnPlay_&&this.tech_.off("play",this.loadOnPlay_),["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(),this.sourceUpdater_.dispose(),this.timelineChangeController_.dispose(),this.stopABRTimer_(),this.updateDuration_&&this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.mediaSource.removeEventListener("durationchange",this.handleDurationChange_),this.mediaSource.removeEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.removeEventListener("sourceended",this.handleSourceEnded_),this.off()},n.master=function(){return this.masterPlaylistLoader_.master},n.media=function(){return this.masterPlaylistLoader_.media()||this.initialMedia_},n.areMediaTypesKnown_=function(){var e=!!this.mediaTypes_.AUDIO.activePlaylistLoader,t=!!this.mainSegmentLoader_.getCurrentMediaInfo_(),n=!e||!!this.audioSegmentLoader_.getCurrentMediaInfo_();return!(!t||!n)},n.getCodecsOrExclude_=function(){var e=this,t={main:this.mainSegmentLoader_.getCurrentMediaInfo_()||{},audio:this.audioSegmentLoader_.getCurrentMediaInfo_()||{}};t.video=t.main;var n=Oc(this.master(),this.media()),r={},i=!!this.mediaTypes_.AUDIO.activePlaylistLoader;if(t.main.hasVideo&&(r.video=n.video||t.main.videoCodec||"avc1.4d400d"),t.main.isMuxed&&(r.video+=","+(n.audio||t.main.audioCodec||"mp4a.40.2")),(t.main.hasAudio&&!t.main.isMuxed||t.audio.hasAudio||i)&&(r.audio=n.audio||t.main.audioCodec||t.audio.audioCodec||"mp4a.40.2",t.audio.isFmp4=t.main.hasAudio&&!t.main.isMuxed?t.main.isFmp4:t.audio.isFmp4),r.audio||r.video){var o,a={};if(["video","audio"].forEach((function(e){if(r.hasOwnProperty(e)&&(i=t[e].isFmp4,s=r[e],!(i?J(s):Q(s)))){var n=t[e].isFmp4?"browser":"muxer";a[n]=a[n]||[],a[n].push(r[e]),"audio"===e&&(o=n)}var i,s})),i&&o&&this.media().attributes.AUDIO){var s=this.media().attributes.AUDIO;this.master().playlists.forEach((function(t){(t.attributes&&t.attributes.AUDIO)===s&&t!==e.media()&&(t.excludeUntil=1/0)})),this.logger_("excluding audio group "+s+" as "+o+' does not support codec(s): "'+r.audio+'"')}if(!Object.keys(a).length){if(this.sourceUpdater_.hasCreatedSourceBuffers()&&!this.sourceUpdater_.canChangeType()){var c=[];if(["video","audio"].forEach((function(t){var n=(X(e.sourceUpdater_.codecs[t]||"")[0]||{}).type,i=(X(r[t]||"")[0]||{}).type;n&&i&&n.toLowerCase()!==i.toLowerCase()&&c.push('"'+e.sourceUpdater_.codecs[t]+'" -> "'+r[t]+'"')})),c.length)return void this.blacklistCurrentPlaylist({playlist:this.media(),message:"Codec switching not supported: "+c.join(", ")+".",blacklistDuration:1/0,internal:!0})}return r}var u=Object.keys(a).reduce((function(e,t){return e&&(e+=", "),e+=t+' does not support codec(s): "'+a[t].join(",")+'"'}),"")+".";this.blacklistCurrentPlaylist({playlist:this.media(),internal:!0,message:u,blacklistDuration:1/0})}else this.blacklistCurrentPlaylist({playlist:this.media(),message:"Could not determine codecs for playlist.",blacklistDuration:1/0})},n.tryToCreateSourceBuffers_=function(){if("open"===this.mediaSource.readyState&&!this.sourceUpdater_.hasCreatedSourceBuffers()&&this.areMediaTypesKnown_()){var e=this.getCodecsOrExclude_();if(e){this.sourceUpdater_.createSourceBuffers(e);var t=[e.video,e.audio].filter(Boolean).join(",");this.excludeIncompatibleVariants_(t)}}},n.excludeUnsupportedVariants_=function(){var e=this,t=this.master().playlists,n=[];Object.keys(t).forEach((function(r){var i=t[r];if(-1===n.indexOf(i.id)){n.push(i.id);var o=Oc(e.master,i),a=[];!o.audio||Q(o.audio)||J(o.audio)||a.push("audio codec "+o.audio),!o.video||Q(o.video)||J(o.video)||a.push("video codec "+o.video),o.text&&"stpp.ttml.im1t"===o.text&&a.push("text codec "+o.text),a.length&&(i.excludeUntil=1/0,e.logger_("excluding "+i.id+" for unsupported: "+a.join(", ")))}}))},n.excludeIncompatibleVariants_=function(e){var t=this,n=[],r=this.master().playlists,i=xc(X(e)),o=Ec(i),a=i.video&&X(i.video)[0]||null,s=i.audio&&X(i.audio)[0]||null;Object.keys(r).forEach((function(e){var i=r[e];if(-1===n.indexOf(i.id)&&i.excludeUntil!==1/0){n.push(i.id);var c=[],u=Oc(t.masterPlaylistLoader_.master,i),l=Ec(u);if(u.audio||u.video){if(l!==o&&c.push('codec count "'+l+'" !== "'+o+'"'),!t.sourceUpdater_.canChangeType()){var d=u.video&&X(u.video)[0]||null,f=u.audio&&X(u.audio)[0]||null;d&&a&&d.type.toLowerCase()!==a.type.toLowerCase()&&c.push('video codec "'+d.type+'" !== "'+a.type+'"'),f&&s&&f.type.toLowerCase()!==s.type.toLowerCase()&&c.push('audio codec "'+f.type+'" !== "'+s.type+'"')}c.length&&(i.excludeUntil=1/0,t.logger_("blacklisting "+i.id+": "+c.join(" && ")))}}}))},n.updateAdCues_=function(e){var t=0,n=this.seekable();n.length&&(t=n.start(0)),function(e,t,n){if(void 0===n&&(n=0),e.segments)for(var r,i=n,a=0;a0&&this.logger_("resetting possible stalled download count for "+e+" loader"),this[e+"StalledDownloads_"]=0,this[e+"Buffered_"]=t.buffered_()},t.checkSegmentDownloads_=function(e){var t=this.masterPlaylistController_,n=t[e+"SegmentLoader_"],r=n.buffered_(),i=function(e,t){if(e===t)return!1;if(!e&&t||!t&&e)return!0;if(e.length!==t.length)return!0;for(var n=0;n=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)}},t.cancelTimer_=function(){this.consecutiveUpdates=0,this.timer_&&(this.logger_("cancelTimer_"),clearTimeout(this.timer_)),this.timer_=null},t.fixesBadSeeks_=function(){if(!this.tech_.seeking())return!1;var e,t=this.seekable(),n=this.tech_.currentTime();this.afterSeekableWindow_(t,n,this.media(),this.allowSeeksWithinUnsafeLiveWindow)&&(e=t.end(t.length-1));if(this.beforeSeekableWindow_(t,n)){var r=t.start(0);e=r+(r===t.end(0)?0:.1)}if("undefined"!==typeof e)return this.logger_("Trying to seek outside of seekable at time "+n+" with seekable range "+Wa(t)+". Seeking to "+e+"."),this.tech_.setCurrentTime(e),!0;for(var i=this.masterPlaylistController_.sourceUpdater_,o=this.tech_.buffered(),a=i.audioBuffer?i.audioBuffered():null,s=i.videoBuffer?i.videoBuffered():null,c=2*(this.media().targetDuration-1/30),u=[a,s],l=0;l "+n.end(0)+"]. Attempting to resume playback by seeking to the current time."),this.tech_.trigger({type:"usage",name:"vhs-unknown-waiting"}),void this.tech_.trigger({type:"usage",name:"hls-unknown-waiting"})):void 0}},t.techWaiting_=function(){var e=this.seekable(),t=this.tech_.currentTime();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:"vhs-live-resync"}),this.tech_.trigger({type:"usage",name:"hls-live-resync"}),!0}var r=this.tech_.vhs.masterPlaylistController_.sourceUpdater_,i=this.tech_.buffered();if(this.videoUnderflow_({audioBuffered:r.audioBuffered(),videoBuffered:r.videoBuffered(),currentTime:t}))return this.cancelTimer_(),this.tech_.setCurrentTime(t),this.tech_.trigger({type:"usage",name:"vhs-video-underflow"}),this.tech_.trigger({type:"usage",name:"hls-video-underflow"}),!0;var o=Va(i,t);if(o.length>0){var a=o.start(0)-t;return this.logger_("Stopped at "+t+", setting timer for "+a+", seeking to "+o.start(0)),this.cancelTimer_(),this.timer_=setTimeout(this.skipTheGap_.bind(this),1e3*a,t),!0}return!1},t.afterSeekableWindow_=function(e,t,n,r){if(void 0===r&&(r=!1),!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},t.beforeSeekableWindow_=function(e,t){return!!(e.length&&e.start(0)>0&&t2)return{start:i,end:o}}return null},e}(),Ru={errorInterval:30,getSource:function(e){return e(this.tech({IWillNotUseThisInPlugins:!0}).currentSource_||this.currentSource())}},Du={PlaylistLoader:Es,Playlist:ds,utils:Bs,STANDARD_PLAYLIST_SELECTOR:Rc,INITIAL_PLAYLIST_SELECTOR:function(){var e=this,t=this.playlists.master.playlists.filter(ds.isEnabled);return Ac(t,(function(e,t){return Ic(e,t)})),t.filter((function(t){return!!Oc(e.playlists.master,t).video}))[0]||null},lastBandwidthSelector:Rc,movingAverageBandwidthSelector:function(e){var t=-1,n=-1;if(e<0||e>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){var r=this.useDevicePixelRatio&&o.a.devicePixelRatio||1;return t<0&&(t=this.systemBandwidth,n=this.systemBandwidth),this.systemBandwidth>0&&this.systemBandwidth!==n&&(t=e*this.systemBandwidth+(1-e)*t,n=this.systemBandwidth),Pc(this.playlists.master,t,parseInt(Tc(this.tech_.el(),"width"),10)*r,parseInt(Tc(this.tech_.el(),"height"),10)*r,this.limitRenditionByPlayerDimensions,this.masterPlaylistController_)}},comparePlaylistBandwidth:Ic,comparePlaylistResolution:function(e,t){var n,r;return e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(n=e.attributes.RESOLUTION.width),n=n||o.a.Number.MAX_VALUE,t.attributes.RESOLUTION&&t.attributes.RESOLUTION.width&&(r=t.attributes.RESOLUTION.width),n===(r=r||o.a.Number.MAX_VALUE)&&e.attributes.BANDWIDTH&&t.attributes.BANDWIDTH?e.attributes.BANDWIDTH-t.attributes.BANDWIDTH:n-r},xhr:Ts()};Object.keys(Gs).forEach((function(e){Object.defineProperty(Du,e,{get:function(){return Na.log.warn("using Vhs."+e+" is UNSAFE be sure you know what you are doing"),Gs[e]},set:function(t){Na.log.warn("using Vhs."+e+" is UNSAFE be sure you know what you are doing"),"number"!==typeof t||t<0?Na.log.warn("value of Vhs."+e+" must be greater than or equal to 0"):Gs[e]=t}})}));var Nu=function(e,t){for(var n=t.media(),r=-1,i=0;i0?1/this.throughput:0,Math.floor(1/(t+e))},set:function(){Na.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},mediaAppends:{get:function(){return n.masterPlaylistController_.mediaAppends_()||0},enumerable:!0},mainAppendsToLoadedData:{get:function(){return n.masterPlaylistController_.mainAppendsToLoadedData_()||0},enumerable:!0},audioAppendsToLoadedData:{get:function(){return n.masterPlaylistController_.audioAppendsToLoadedData_()||0},enumerable:!0},appendsToLoadedData:{get:function(){return n.masterPlaylistController_.appendsToLoadedData_()||0},enumerable:!0},timeToLoadedData:{get:function(){return n.masterPlaylistController_.timeToLoadedData_()||0},enumerable:!0},buffered:{get:function(){return Ha(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 Ha(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&&function(e){if(!o.a.localStorage)return!1;var t=Bu();t=t?Na.mergeOptions(t,e):e;try{o.a.localStorage.setItem("videojs-vhs",JSON.stringify(t))}catch(n){return!1}}({bandwidth:n.bandwidth,throughput:Math.round(n.throughput)})})),this.masterPlaylistController_.on("selectedinitialmedia",(function(){var e;(e=n).representations=function(){var t=e.masterPlaylistController_.master(),n=ls(t)?e.masterPlaylistController_.getAudioTrackPlaylists_():t.playlists;return n?n.filter((function(e){return!is(e)})).map((function(t,n){return new Au(e,t,t.id)})):[]}})),this.masterPlaylistController_.sourceUpdater_.on("createdsourcebuffers",(function(){n.setupEme_()})),this.on(this.masterPlaylistController_,"progress",(function(){this.tech_.trigger("progress")})),this.on(this.masterPlaylistController_,"firstplay",(function(){this.ignoreNextSeekingEvent_=!0})),this.setupQualityLevels_(),this.tech_.el()&&(this.mediaSourceUrl_=o.a.URL.createObjectURL(this.masterPlaylistController_.mediaSource),this.tech_.src(this.mediaSourceUrl_))}},n.setupEme_=function(){var e=this,t=this.masterPlaylistController_.mediaTypes_.AUDIO.activePlaylistLoader,n=Lu({player:this.player_,sourceKeySystems:this.source_.keySystems,media:this.playlists.media(),audioMedia:t&&t.media()});this.player_.tech_.on("keystatuschange",(function(t){"output-restricted"===t.status&&e.masterPlaylistController_.blacklistCurrentPlaylist({playlist:e.masterPlaylistController_.media(),message:"DRM keystatus changed to "+t.status+". Playlist will fail to play. Check for HDCP content.",blacklistDuration:1/0})})),11!==Na.browser.IE_VERSION&&n?(this.logger_("waiting for EME key session creation"),ju({player:this.player_,sourceKeySystems:this.source_.keySystems,audioMedia:t&&t.media(),mainPlaylists:this.playlists.master.playlists}).then((function(){e.logger_("created EME key session"),e.masterPlaylistController_.sourceUpdater_.initializedEme()})).catch((function(t){e.logger_("error while creating EME key session",t),e.player_.error({message:"Failed to initialize media keys for EME",code:3})}))):this.masterPlaylistController_.sourceUpdater_.initializedEme()},n.setupQualityLevels_=function(){var e=this,t=Na.players[this.tech_.options_.playerId];t&&t.qualityLevels&&!this.qualityLevels_&&(this.qualityLevels_=t.qualityLevels(),this.masterPlaylistController_.on("selectedinitialmedia",(function(){var t,n;t=e.qualityLevels_,(n=e).representations().forEach((function(e){t.addQualityLevel(e)})),Nu(t,n.playlists)})),this.playlists.on("mediachange",(function(){Nu(e.qualityLevels_,e.playlists)})))},t.version=function(){return{"@videojs/http-streaming":"2.11.0","mux.js":"5.14.0","mpd-parser":"0.19.1","m3u8-parser":"4.7.0","aes-decrypter":"3.1.2"}},n.version=function(){return this.constructor.version()},n.canChangeType=function(){return uu.canChangeType()},n.play=function(){this.masterPlaylistController_.play()},n.setCurrentTime=function(e){this.masterPlaylistController_.setCurrentTime(e)},n.duration=function(){return this.masterPlaylistController_.duration()},n.seekable=function(){return this.masterPlaylistController_.seekable()},n.dispose=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_.vhs&&delete this.tech_.vhs,this.tech_&&delete this.tech_.hls,this.mediaSourceUrl_&&o.a.URL.revokeObjectURL&&(o.a.URL.revokeObjectURL(this.mediaSourceUrl_),this.mediaSourceUrl_=null),e.prototype.dispose.call(this)},n.convertToProgramTime=function(e,t){return zs({playlist:this.masterPlaylistController_.media(),time:e,callback:t})},n.seekToProgramTime=function(e,t,n,r){return void 0===n&&(n=!0),void 0===r&&(r=2),Fs({programTime:e,playlist:this.masterPlaylistController_.media(),retryCount:r,pauseAfterSeek:n,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:t})},t}(Na.getComponent("Component")),Fu={name:"videojs-http-streaming",VERSION:"2.11.0",canHandleSource:function(e,t){void 0===t&&(t={});var n=Na.mergeOptions(Na.options,t);return Fu.canPlayType(e.type,n)},handleSource:function(e,t,n){void 0===n&&(n={});var r=Na.mergeOptions(Na.options,n);return t.vhs=new zu(e,t,r),Na.hasOwnProperty("hls")||Object.defineProperty(t,"hls",{get:function(){return Na.log.warn("player.tech().hls is deprecated. Use player.tech().vhs instead."),t.vhs},configurable:!0}),t.vhs.xhr=Ts(),t.vhs.src(e.src,e.type),t.vhs},canPlayType:function(e,t){void 0===t&&(t={});var n=Na.mergeOptions(Na.options,t).vhs.overrideNative,r=void 0===n?!Na.browser.IS_ANY_SAFARI:n,i=ne(e);return i&&(!Du.supportsTypeNatively(i)||r)?"maybe":""}};(J("avc1.4d400d,mp4a.40.2")&&Na.getTech("Html5").registerSourceHandler(Fu,0),Na.VhsHandler=zu,Object.defineProperty(Na,"HlsHandler",{get:function(){return Na.log.warn("videojs.HlsHandler is deprecated. Use videojs.VhsHandler instead."),zu},configurable:!0}),Na.VhsSourceHandler=Fu,Object.defineProperty(Na,"HlsSourceHandler",{get:function(){return Na.log.warn("videojs.HlsSourceHandler is deprecated. Use videojs.VhsSourceHandler instead."),Fu},configurable:!0}),Na.Vhs=Du,Object.defineProperty(Na,"Hls",{get:function(){return Na.log.warn("videojs.Hls is deprecated. Use videojs.Vhs instead."),Du},configurable:!0}),Na.use||(Na.registerComponent("Hls",Du),Na.registerComponent("Vhs",Du)),Na.options.vhs=Na.options.vhs||{},Na.options.hls=Na.options.hls||{},Na.getPlugin&&Na.getPlugin("reloadSourceOnError"))||(Na.registerPlugin||Na.plugin)("reloadSourceOnError",(function(e){!function e(t,n){var r=0,i=0,o=Na.mergeOptions(Ru,n);t.ready((function(){t.trigger({type:"usage",name:"vhs-error-reload-initialized"}),t.trigger({type:"usage",name:"hls-error-reload-initialized"})}));var a=function(){i&&t.currentTime(i)},s=function(e){null!==e&&void 0!==e&&(i=t.duration()!==1/0&&t.currentTime()||0,t.one("loadedmetadata",a),t.src(e),t.trigger({type:"usage",name:"vhs-error-reload"}),t.trigger({type:"usage",name:"hls-error-reload"}),t.play())},c=function(){return Date.now()-r<1e3*o.errorInterval?(t.trigger({type:"usage",name:"vhs-error-reload-canceled"}),void t.trigger({type:"usage",name:"hls-error-reload-canceled"})):o.getSource&&"function"===typeof o.getSource?(r=Date.now(),o.getSource.call(t,s)):void Na.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!")},u=function e(){t.off("loadedmetadata",a),t.off("error",c),t.off("dispose",e)};t.on("error",c),t.on("dispose",u),t.reloadSourceOnError=function(n){u(),e(t,n)}}(this,e)}));t.a=Na},function(e,t,n){var r=n(1621);e.exports=function(e){return r(e,5)}},function(e,t,n){"use strict";function r(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}n.d(t,"a",(function(){return r}))},function(e,t,n){var r=n(143);e.exports=function(e){return Object(r(e))}},function(e,t,n){var r=n(76),i=n(843),o=n(64),a=n(184),s=Object.defineProperty;t.f=r?s:function(e,t,n){if(o(e),t=a(t,!0),o(n),i)try{return s(e,t,n)}catch(r){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t=0||(i[n]=e[n]);return i}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return z})),n.d(t,"b",(function(){return k})),n.d(t,"c",(function(){return _})),n.d(t,"d",(function(){return N})),n.d(t,"e",(function(){return C})),n.d(t,"f",(function(){return T})),n.d(t,"g",(function(){return M})),n.d(t,"h",(function(){return j}));var r=n(22),i=n(5),o=n(1),a=n(7),s=n(748),c=n(12),u=n(132),l=n(103),d=n(38),f=n(2),h=n(3),p=n(117),m=n(263),g=n(86),v=n(257),b=n(179),y=n(588),w=n(551),S=n(345),_=Object(o.createContext)(null),k=Object(o.createContext)(!1);function x(e){var t=function(){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}}();return function(){var n,r=Object(S.a)(e);if(t){var i=Object(S.a)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Object(w.a)(this,n)}}var E=function(e){Object(y.a)(n,e);var t=x(n);function n(){var e;Object(v.a)(this,n);for(var r=arguments.length,i=new Array(r),o=0;o12&&(o-=360),{height:r?"26%":"40%",transform:"rotateZ(".concat(o,"deg)")}},e}return Object(b.a)(n,[{key:"render",value:function(){var e=this.props,t=e.classes,n=e.hasSelected,r=(e.isInner,e.type,e.value,Object(i.a)(e,["classes","hasSelected","isInner","type","value"]));return Object(o.createElement)("div",Object(f.a)({},r,{style:this.getAngleStyle(),className:Object(h.default)(t.pointer,this.state.toAnimateTransform&&t.animateTransform)}),Object(o.createElement)("div",{className:Object(h.default)(t.thumb,n&&t.noPoint)}))}}]),n}(o.Component);E.getDerivedStateFromProps=function(e,t){return e.type!==t.previousType?{toAnimateTransform:!0,previousType:e.type}:{toAnimateTransform:!1,previousType:e.type}};var O=Object(c.a)((function(e){return Object(s.a)({pointer:{width:2,backgroundColor:e.palette.primary.main,position:"absolute",left:"calc(50% - 1px)",bottom:"50%",transformOrigin:"center bottom 0px"},animateTransform:{transition:e.transitions.create(["transform","height"])},thumb:{width:4,height:4,backgroundColor:e.palette.primary.contrastText,borderRadius:"100%",position:"absolute",top:-21,left:-15,border:"14px solid ".concat(e.palette.primary.main),boxSizing:"content-box"},noPoint:{backgroundColor:e.palette.primary.main}})}),{name:"MuiPickersClockPointer"})(E),M=function(e,t){return e?t.getHours(e)>=12?"pm":"am":null},C=function(e,t,n){if(n&&(e>=12?"pm":"am")!==t)return"am"===t?e-12:e+12;return e},T=function(e,t,n,r){var i=C(r.getHours(e),t,n);return r.setHours(e,i)},A={x:130,y:130},I=A.x-A.x,P=0-A.y,R=function(e,t,n){var r=t-A.x,i=n-A.y,o=Math.atan2(I,P)-Math.atan2(r,i),a=57.29577951308232*o;a=Math.round(a/e)*e,a%=360;var s=Math.floor(a/e)||0,c=Math.pow(r,2)+Math.pow(i,2);return{value:s,distance:Math.sqrt(c)}};function D(e,t){return 3600*t.getHours(e)+60*t.getMinutes(e)+t.getSeconds(e)}var N=function(e,t){return function(n,r){return e?t.isAfter(n,r):D(n,t)>D(r,t)}},j=function(e,t,n){var r=n.minTime,i=n.maxTime,o=n.shouldDisableTime,a=n.disableIgnoringDatePartForTimeValidation,s=e.date(t),c=N(Boolean(a),e);if(null===t)return null;switch(!0){case!e.isValid(t):return"invalidDate";case Boolean(r&&c(r,s)):return"minTime";case Boolean(i&&c(s,i)):return"maxTime";case Boolean(o&&o(e.getHours(s),"hours")):return"shouldDisableTime-hours";case Boolean(o&&o(e.getMinutes(s),"minutes")):return"shouldDisableTime-minutes";case Boolean(o&&o(e.getSeconds(s),"seconds")):return"shouldDisableTime-seconds";default:return null}},L={name:"MuiPickersClock"},B=Object(u.a)((function(e){return{root:{display:"flex",justifyContent:"center",position:"relative",minHeight:d.c,alignItems:"center"},clock:{backgroundColor:"rgba(0,0,0,.07)",borderRadius:"50%",height:260,width:260,position:"relative",pointerEvents:"none"},squareMask:{width:"100%",height:"100%",position:"absolute",pointerEvents:"auto",outline:"none",touchActions:"none",userSelect:"none","&:active":{cursor:"move"}},pin:{width:6,height:6,borderRadius:"50%",backgroundColor:e.palette.primary.main,position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},amButton:{zIndex:1,left:8,position:"absolute",bottom:8},pmButton:{zIndex:1,position:"absolute",bottom:8,right:8},meridiemButtonSelected:{backgroundColor:e.palette.primary.main,color:e.palette.primary.contrastText,"&:hover":{backgroundColor:e.palette.primary.light}}}}),L),z=Object(l.c)(L,(function(e){var t,n=e.allowKeyboardControl,i=e.ampm,a=e.ampmInClock,s=void 0!==a&&a,c=e.children,u=e.date,l=e.handleMeridiemChange,f=e.isTimeDisabled,v=e.meridiemMode,b=e.minutesStep,y=void 0===b?1:b,w=e.onChange,S=e.type,k=e.value,x=Object(d.h)(),E=B(),M=Object(o.useContext)(_),C=Object(o.useRef)(!1),T=f(k,S),A=!i&&"hours"===S&&(k<1||k>12),I=function(e,t){f(e,S)||w(e,t)},P=function(e,t){var n=e.offsetX,r=e.offsetY;if("undefined"===typeof n){var o=e.target.getBoundingClientRect();n=e.changedTouches[0].clientX-o.left,r=e.changedTouches[0].clientY-o.top}var a="seconds"===S||"minutes"===S?function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=6*n,i=R(r,e,t),o=i.value;return o=o*n%60}(n,r,y):function(e,t,n){var r=R(30,e,t),i=r.value,o=r.distance;return i=i||12,n?i%=12:o<90&&(i+=12,i%=24),i}(n,r,Boolean(i));I(a,t)},D=Object(o.useMemo)((function(){return"hours"===S||k%5===0}),[S,k]),N="minutes"===S?y:1;return Object(g.c)(Boolean(null!==n&&void 0!==n?n:"static"!==M)&&!C.current,(t={},Object(r.a)(t,g.b.Home,(function(){return I(0,"partial")})),Object(r.a)(t,g.b.End,(function(){return I("minutes"===S?59:23,"partial")})),Object(r.a)(t,g.b.ArrowUp,(function(){return I(k+N,"partial")})),Object(r.a)(t,g.b.ArrowDown,(function(){return I(k-N,"partial")})),t)),Object(o.createElement)("div",{className:E.root},Object(o.createElement)("div",{className:E.clock},Object(o.createElement)("div",{role:"menu",tabIndex:-1,className:E.squareMask,onTouchMove:function(e){C.current=!0,P(e,"shallow")},onTouchEnd:function(e){C.current&&(P(e,"finish"),C.current=!1)},onMouseUp:function(e){C.current&&(C.current=!1),P(e.nativeEvent,"finish")},onMouseMove:function(e){e.preventDefault(),e.stopPropagation(),("undefined"===typeof e.buttons?1===e.nativeEvent.which:1===e.buttons)&&P(e.nativeEvent,"shallow")}}),!T&&Object(o.createElement)(o.Fragment,null,Object(o.createElement)("div",{className:E.pin}),u&&Object(o.createElement)(O,{type:S,value:k,isInner:A,hasSelected:D,"aria-live":"polite","aria-label":"Selected time ".concat(x.format(u,"fullTime"))})),c),i&&("desktop"===M||s)&&Object(o.createElement)(o.Fragment,null,Object(o.createElement)(m.a,{"data-mui-test":"in-clock-am-btn",onClick:function(){return l("am")},disabled:null===v,className:Object(h.default)(E.amButton,"am"===v&&E.meridiemButtonSelected)},Object(o.createElement)(p.a,{variant:"caption"},"AM")),Object(o.createElement)(m.a,{disabled:null===v,"data-mui-test":"in-clock-pm-btn",onClick:function(){return l("pm")},className:Object(h.default)(E.pmButton,"pm"===v&&E.meridiemButtonSelected)},Object(o.createElement)(p.a,{variant:"caption"},"PM"))))}));z.defaultProps={ampm:a.bool,minutesStep:a.number},z.displayName="Clock"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultModality=t.DefaultMessagingSession=t.DefaultMeetingSession=t.DefaultMeetingReadinessChecker=t.DefaultMeetingEventReporter=t.DefaultMediaDeviceFactory=t.DefaultEventController=t.DefaultDevicePixelRatioMonitor=t.DefaultDeviceController=t.DefaultContentShareController=t.DefaultClientMetricReport=t.DefaultBrowserBehavior=t.DefaultAudioVideoFacade=t.DefaultAudioVideoController=t.DefaultAudioMixController=t.DefaultActiveSpeakerPolicy=t.DefaultActiveSpeakerDetector=t.DataMessage=t.CreateSDPTask=t.CreatePeerConnectionTask=t.ContentShareMediaStreamBroker=t.ContentShareConstants=t.ConsoleLogger=t.ConnectionHealthPolicyConfiguration=t.ConnectionHealthData=t.ClientVideoStreamReceivingReport=t.ClientMetricReportMediaType=t.ClientMetricReportDirection=t.CleanStoppedSessionTask=t.CleanRestartedSessionTask=t.CheckVideoInputFeedback=t.CheckVideoConnectivityFeedback=t.CheckNetworkUDPConnectivityFeedback=t.CheckNetworkTCPConnectivityFeedback=t.CheckContentShareConnectivityFeedback=t.CheckCameraResolutionFeedback=t.CheckAudioOutputFeedback=t.CheckAudioInputFeedback=t.CheckAudioConnectivityFeedback=t.CanvasVideoFrameBuffer=t.BitrateParameters=t.BaseTask=t.BaseConnectionHealthPolicy=t.AudioVideoControllerState=t.AudioProfile=t.AudioLogEvent=t.Attendee=t.AttachMediaInputTask=t.AsyncScheduler=t.AllHighestVideoBandwidthPolicy=void 0,t.MeetingSessionTURNCredentials=t.MeetingSessionStatusCode=t.MeetingSessionStatus=t.MeetingSessionPOSTLogger=t.MeetingSessionLifecycleEventCondition=t.MeetingSessionLifecycleEvent=t.MeetingSessionCredentials=t.MeetingSessionConfiguration=t.MeetingReadinessCheckerConfiguration=t.MeetingEventsClientConfiguration=t.MediaDeviceProxyHandler=t.Maybe=t.LogLevel=t.Log=t.ListenForVolumeIndicatorsTask=t.LeaveAndReceiveLeaveAckTask=t.JoinAndReceiveIndexTask=t.IntervalScheduler=t.InMemoryJSONEventBuffer=t.GlobalMetricReport=t.GetUserMediaError=t.FullJitterLimitedBackoff=t.FullJitterBackoffFactory=t.FullJitterBackoff=t.FinishGatheringICECandidatesTask=t.EventIngestionConfiguration=t.EventBufferConfiguration=t.DeviceSelection=t.DevicePixelRatioWindowSource=t.DefaultWebSocketAdapter=t.DefaultVolumeIndicatorAdapter=t.DefaultVideoTransformDevice=t.DefaultVideoTileFactory=t.DefaultVideoTileController=t.DefaultVideoTile=t.DefaultVideoStreamIndex=t.DefaultVideoStreamIdSet=t.DefaultVideoFrameProcessorPipeline=t.DefaultVideoCaptureAndEncodeParameter=t.DefaultUserAgentParser=t.DefaultTransceiverController=t.DefaultStatsCollector=t.DefaultSimulcastUplinkPolicy=t.DefaultSignalingClient=t.DefaultSigV4=t.DefaultSessionStateController=t.DefaultSDP=t.DefaultReconnectController=t.DefaultRealtimeController=t.DefaultPingPong=void 0,t.SignalingClientEventType=t.SignalingClientEvent=t.SignalingClientConnectionRequest=t.SignalingAndMetricsConnectionMonitor=t.SetRemoteDescriptionTask=t.SetLocalDescriptionTask=t.SessionStateControllerTransitionResult=t.SessionStateControllerState=t.SessionStateControllerDeferPriority=t.SessionStateControllerAction=t.SerialGroupTask=t.SendAndReceiveDataMessagesTask=t.SDPCandidateType=t.RunnableTask=t.ReleaseMediaStreamsTask=t.ReconnectionHealthPolicy=t.ReceiveVideoStreamIndexTask=t.ReceiveVideoInputTask=t.ReceiveTURNCredentialsTask=t.ReceiveAudioInputTask=t.RealtimeVolumeIndicator=t.RealtimeState=t.RealtimeAttendeePositionInFrame=t.PermissionDeniedError=t.ParallelGroupTask=t.OverconstrainedError=t.OpenSignalingConnectionTask=t.OnceTask=t.NotReadableError=t.NotFoundError=t.None=t.NoVideoUplinkBandwidthPolicy=t.NoVideoDownlinkBandwidthPolicy=t.NoOpVideoFrameProcessor=t.NoOpVideoElementFactory=t.NoOpTask=t.NoOpMediaStreamBroker=t.NoOpLogger=t.NoOpEventReporter=t.NoOpDeviceController=t.NoOpDebugLogger=t.NoOpAudioVideoController=t.NScaleVideoUplinkBandwidthPolicy=t.MutableVideoPreferences=t.MultiLogger=t.MonitorTask=t.MessagingSessionConfiguration=t.Message=t.MeetingSessionVideoAvailability=t.MeetingSessionURLs=void 0,t.isVideoTransformDevice=t.isDestroyable=t.isAudioTransformDevice=t.WebSocketReadyState=t.WaitForAttendeePresenceTask=t.VoiceFocusTransformDevice=t.VoiceFocusDeviceTransformer=t.VideoTileState=t.VideoStreamDescription=t.VideoSource=t.VideoQualitySettings=t.VideoPriorityBasedPolicy=t.VideoPreferences=t.VideoPreference=t.VideoOnlyTransceiverController=t.VideoLogEvent=t.VideoAdaptiveProbePolicy=t.Versioning=t.UnusableAudioWarningConnectionHealthPolicy=t.TypeError=t.TimeoutTask=t.TimeoutScheduler=t.TaskStatus=t.TargetDisplaySize=t.SubscribeAndReceiveSubscribeAckTask=t.StreamMetricReport=t.Some=t.SingleNodeAudioTransformDevice=t.SimulcastVideoStreamIndex=t.SimulcastTransceiverController=t.SimulcastLayers=t.SignalingClientSubscribe=t.SignalingClientJoin=void 0;var r=n(707);t.AllHighestVideoBandwidthPolicy=r.default;var i=n(202);t.AsyncScheduler=i.default;var o=n(1072);t.AttachMediaInputTask=o.default;var a=n(2140);t.Attendee=a.default;var s=n(709);t.AudioLogEvent=s.default;var c=n(1074);t.AudioProfile=c.default;var u=n(1075);t.AudioVideoControllerState=u.default;var l=n(710);t.BaseConnectionHealthPolicy=l.default;var d=n(79);t.BaseTask=d.default;var f=n(1076);t.BitrateParameters=f.default;var h=n(1077);t.CanvasVideoFrameBuffer=h.default;var p=n(1078);t.CheckAudioConnectivityFeedback=p.default;var m=n(1079);t.CheckAudioInputFeedback=m.default;var g=n(1080);t.CheckAudioOutputFeedback=g.default;var v=n(1081);t.CheckCameraResolutionFeedback=v.default;var b=n(1082);t.CheckContentShareConnectivityFeedback=b.default;var y=n(1083);t.CheckNetworkTCPConnectivityFeedback=y.default;var w=n(1084);t.CheckNetworkUDPConnectivityFeedback=w.default;var S=n(1085);t.CheckVideoConnectivityFeedback=S.default;var _=n(1086);t.CheckVideoInputFeedback=_.default;var k=n(1087);t.CleanRestartedSessionTask=k.default;var x=n(1088);t.CleanStoppedSessionTask=x.default;var E=n(404);t.ClientMetricReportDirection=E.default;var O=n(516);t.ClientMetricReportMediaType=O.default;var M=n(1089);t.ClientVideoStreamReceivingReport=M.default;var C=n(1090);t.ConnectionHealthData=C.default;var T=n(1091);t.ConnectionHealthPolicyConfiguration=T.default;var A=n(2141);t.ConsoleLogger=A.default;var I=n(405);t.ContentShareConstants=I.default;var P=n(1092);t.ContentShareMediaStreamBroker=P.default;var R=n(1105);t.CreatePeerConnectionTask=R.default;var D=n(1106);t.CreateSDPTask=D.default;var N=n(1108);t.DataMessage=N.default;var j=n(1109);t.DefaultActiveSpeakerDetector=j.default;var L=n(2143);t.DefaultActiveSpeakerPolicy=L.default;var B=n(715);t.DefaultAudioMixController=B.default;var z=n(716);t.DefaultAudioVideoController=z.default;var F=n(1161);t.DefaultAudioVideoFacade=F.default;var U=n(161);t.DefaultBrowserBehavior=U.default;var q=n(1123);t.DefaultClientMetricReport=q.default;var V=n(1162);t.DefaultContentShareController=V.default;var W=n(711);t.DefaultDeviceController=W.default;var H=n(1155);t.DefaultDevicePixelRatioMonitor=H.default;var K=n(1111);t.DefaultEventController=K.default;var Z=n(1095);t.DefaultMediaDeviceFactory=Z.default;var G=n(1163);t.DefaultMeetingEventReporter=G.default;var X=n(2161);t.DefaultMeetingReadinessChecker=X.default;var Y=n(2162);t.DefaultMeetingSession=Y.default;var $=n(2163);t.DefaultMessagingSession=$.default;var J=n(406);t.DefaultModality=J.default;var Q=n(1114);t.DefaultPingPong=Q.default;var ee=n(1115);t.DefaultRealtimeController=ee.default;var te=n(522);t.DefaultReconnectController=te.default;var ne=n(407);t.DefaultSDP=ne.default;var re=n(1118);t.DefaultSessionStateController=re.default;var ie=n(1171);t.DefaultSigV4=ie.default;var oe=n(1120);t.DefaultSignalingClient=oe.default;var ae=n(1158);t.DefaultSimulcastUplinkPolicy=ae.default;var se=n(1122);t.DefaultStatsCollector=se.default;var ce=n(519);t.DefaultTransceiverController=ce.default;var ue=n(1165);t.DefaultUserAgentParser=ue.default;var le=n(408);t.DefaultVideoCaptureAndEncodeParameter=le.default;var de=n(1172);t.DefaultVideoFrameProcessorPipeline=de.default;var fe=n(319);t.DefaultVideoStreamIdSet=fe.default;var he=n(727);t.DefaultVideoStreamIndex=he.default;var pe=n(712);t.DefaultVideoTile=pe.default;var me=n(1154);t.DefaultVideoTileController=me.default;var ge=n(1157);t.DefaultVideoTileFactory=ge.default;var ve=n(2164);t.DefaultVideoTransformDevice=ve.default;var be=n(1160);t.DefaultVolumeIndicatorAdapter=be.default;var ye=n(523);t.DefaultWebSocketAdapter=ye.default;var we=n(1156);t.DevicePixelRatioWindowSource=we.default;var Se=n(1099);t.DeviceSelection=Se.default;var _e=n(1168);t.EventBufferConfiguration=_e.default;var ke=n(1167);t.EventIngestionConfiguration=ke.default;var xe=n(1128);t.FinishGatheringICECandidatesTask=xe.default;var Ee=n(320);t.FullJitterBackoff=Ee.default;var Oe=n(2165);t.FullJitterBackoffFactory=Oe.default;var Me=n(1173);t.FullJitterLimitedBackoff=Me.default;var Ce=n(284);t.GetUserMediaError=Ce.default;var Te=n(1124);t.GlobalMetricReport=Te.default;var Ae=n(1164);t.InMemoryJSONEventBuffer=Ae.default;var Ie=n(251);t.IntervalScheduler=Ie.default;var Pe=n(1129);t.JoinAndReceiveIndexTask=Pe.default;var Re=n(1131);t.LeaveAndReceiveLeaveAckTask=Re.default;var De=n(1132);t.ListenForVolumeIndicatorsTask=De.default;var Ne=n(1174);t.Log=Ne.default;var je=n(250);t.LogLevel=je.default;var Le=n(162);t.Maybe=Le.default;var Be=n(1096);t.MediaDeviceProxyHandler=Be.default;var ze=n(1169);t.MeetingEventsClientConfiguration=ze.default;var Fe=n(1166);t.MeetingReadinessCheckerConfiguration=Fe.default;var Ue=n(731);t.MeetingSessionConfiguration=Ue.default;var qe=n(521);t.MeetingSessionCredentials=qe.default;var Ve=n(1126);t.MeetingSessionLifecycleEvent=Ve.default;var We=n(1127);t.MeetingSessionLifecycleEventCondition=We.default;var He=n(2166);t.MeetingSessionPOSTLogger=He.default;var Ke=n(517);t.MeetingSessionStatus=Ke.default;var Ze=n(225);t.MeetingSessionStatusCode=Ze.default;var Ge=n(721);t.MeetingSessionTURNCredentials=Ge.default;var Xe=n(732);t.MeetingSessionURLs=Xe.default;var Ye=n(717);t.MeetingSessionVideoAvailability=Ye.default;var $e=n(1170);t.Message=$e.default;var Je=n(2167);t.MessagingSessionConfiguration=Je.default;var Qe=n(1133);t.MonitorTask=Qe.default;var et=n(2168);t.MultiLogger=et.default;var tt=n(730);t.NScaleVideoUplinkBandwidthPolicy=tt.default;var nt=n(2169);t.NoOpAudioVideoController=nt.default;var rt=n(1175);t.NoOpDebugLogger=rt.default;var it=n(2170);t.NoOpDeviceController=it.default;var ot=n(2171);t.NoOpEventReporter=ot.default;var at=n(1176);t.NoOpLogger=at.default;var st=n(734);t.NoOpMediaStreamBroker=st.default;var ct=n(2172);t.NoOpTask=ct.default;var ut=n(2173);t.NoOpVideoElementFactory=ut.default;var lt=n(2174);t.NoOpVideoFrameProcessor=lt.default;var dt=n(2175);t.NoVideoDownlinkBandwidthPolicy=dt.default;var ft=n(2176);t.NoVideoUplinkBandwidthPolicy=ft.default;var ht=n(1093);t.None=ht.default;var pt=n(1100);t.NotFoundError=pt.default;var mt=n(1101);t.NotReadableError=mt.default;var gt=n(1073);t.OnceTask=gt.default;var vt=n(1136);t.OpenSignalingConnectionTask=vt.default;var bt=n(1102);t.OverconstrainedError=bt.default;var yt=n(1138);t.ParallelGroupTask=yt.default;var wt=n(713);t.PermissionDeniedError=wt.default;var St=n(2177);t.RealtimeAttendeePositionInFrame=St.default;var _t=n(1116);t.RealtimeState=_t.default;var kt=n(1117);t.RealtimeVolumeIndicator=kt.default;var xt=n(1139);t.ReceiveAudioInputTask=xt.default;var Et=n(1140);t.ReceiveTURNCredentialsTask=Et.default;var Ot=n(1141);t.ReceiveVideoInputTask=Ot.default;var Mt=n(1142);t.ReceiveVideoStreamIndexTask=Mt.default;var Ct=n(1134);t.ReconnectionHealthPolicy=Ct.default;var Tt=n(1143);t.ReleaseMediaStreamsTask=Tt.default;var At=n(2178);t.RunnableTask=At.default;var It=n(1107);t.SDPCandidateType=It.default;var Pt=n(1144);t.SendAndReceiveDataMessagesTask=Pt.default;var Rt=n(1145);t.SerialGroupTask=Rt.default;var Dt=n(718);t.SessionStateControllerAction=Dt.default;var Nt=n(1119);t.SessionStateControllerDeferPriority=Nt.default;var jt=n(719);t.SessionStateControllerState=jt.default;var Lt=n(720);t.SessionStateControllerTransitionResult=Lt.default;var Bt=n(1146);t.SetLocalDescriptionTask=Bt.default;var zt=n(1147);t.SetRemoteDescriptionTask=zt.default;var Ft=n(1110);t.SignalingAndMetricsConnectionMonitor=Ft.default;var Ut=n(1137);t.SignalingClientConnectionRequest=Ut.default;var qt=n(1121);t.SignalingClientEvent=qt.default;var Vt=n(150);t.SignalingClientEventType=Vt.default;var Wt=n(1130);t.SignalingClientJoin=Wt.default;var Ht=n(1149);t.SignalingClientSubscribe=Ht.default;var Kt=n(1159);t.SimulcastLayers=Kt.default;var Zt=n(723);t.SimulcastTransceiverController=Zt.default;var Gt=n(1152);t.SimulcastVideoStreamIndex=Gt.default;var Xt=n(2179);t.SingleNodeAudioTransformDevice=Xt.default;var Yt=n(1094);t.Some=Yt.default;var $t=n(1125);t.StreamMetricReport=$t.default;var Jt=n(1148);t.SubscribeAndReceiveSubscribeAckTask=Jt.default;var Qt=n(725);t.TargetDisplaySize=Qt.default;var en=n(708);t.TaskStatus=en.default;var tn=n(514);t.TimeoutScheduler=tn.default;var nn=n(722);t.TimeoutTask=nn.default;var rn=n(1103);t.TypeError=rn.default;var on=n(1135);t.UnusableAudioWarningConnectionHealthPolicy=on.default;var an=n(252);t.Versioning=an.default;var sn=n(2180);t.VideoAdaptiveProbePolicy=sn.default;var cn=n(515);t.VideoLogEvent=cn.default;var un=n(1151);t.VideoOnlyTransceiverController=un.default;var ln=n(726);t.VideoPreference=ln.default;var dn=n(520);t.VideoPreferences=dn.default;var fn=n(724);t.VideoPriorityBasedPolicy=fn.default;var hn=n(1104);t.VideoQualitySettings=hn.default;var pn=n(2182);t.VideoSource=pn.default;var mn=n(728);t.VideoStreamDescription=mn.default;var gn=n(1097);t.VideoTileState=gn.default;var vn=n(2183);t.VoiceFocusDeviceTransformer=vn.default;var bn=n(1178);t.VoiceFocusTransformDevice=bn.default;var yn=n(1150);t.WaitForAttendeePresenceTask=yn.default;var wn=n(518);t.WebSocketReadyState=wn.default;var Sn=n(520);Object.defineProperty(t,"MutableVideoPreferences",{enumerable:!0,get:function(){return Sn.MutableVideoPreferences}});var _n=n(1098);Object.defineProperty(t,"isAudioTransformDevice",{enumerable:!0,get:function(){return _n.isAudioTransformDevice}});var kn=n(733);Object.defineProperty(t,"isDestroyable",{enumerable:!0,get:function(){return kn.isDestroyable}});var xn=n(714);Object.defineProperty(t,"isVideoTransformDevice",{enumerable:!0,get:function(){return xn.isVideoTransformDevice}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1879);Object.defineProperty(t,"Alpha",{enumerable:!0,get:function(){return d(r).default}});var i=n(678);Object.defineProperty(t,"Checkboard",{enumerable:!0,get:function(){return d(i).default}});var o=n(1882);Object.defineProperty(t,"EditableInput",{enumerable:!0,get:function(){return d(o).default}});var a=n(1883);Object.defineProperty(t,"Hue",{enumerable:!0,get:function(){return d(a).default}});var s=n(1885);Object.defineProperty(t,"Raised",{enumerable:!0,get:function(){return d(s).default}});var c=n(1891);Object.defineProperty(t,"Saturation",{enumerable:!0,get:function(){return d(c).default}});var u=n(995);Object.defineProperty(t,"ColorWrap",{enumerable:!0,get:function(){return d(u).default}});var l=n(1901);function d(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"Swatch",{enumerable:!0,get:function(){return d(l).default}})},function(e,t,n){"use strict";function r(e,t){for(var n=0;n=e.length)return t.push(null);var i=n+r;i>e.length&&(i=e.length),t.push(e.slice(n,i)),n=i},t},concat:function(e){var t,n,r=0,i=0;for(n=0;n>>8^t[255&(n^e.readUInt8(r))]}return(-1^n)>>>0},hmac:function(e,t,n,r){return n||(n="binary"),"buffer"===n&&(n=void 0),r||(r="sha256"),"string"===typeof t&&(t=o.buffer.toBuffer(t)),o.crypto.lib.createHmac(r,e).update(t).digest(n)},md5:function(e,t,n){return o.crypto.hash("md5",e,t,n)},sha256:function(e,t,n){return o.crypto.hash("sha256",e,t,n)},hash:function(e,t,n,r){var i=o.crypto.createHash(e);n||(n="binary"),"buffer"===n&&(n=void 0),"string"===typeof t&&(t=o.buffer.toBuffer(t));var a=o.arraySliceFn(t),s=o.Buffer.isBuffer(t);if(o.isBrowser()&&"undefined"!==typeof ArrayBuffer&&t&&t.buffer instanceof ArrayBuffer&&(s=!0),r&&"object"===typeof t&&"function"===typeof t.on&&!s)t.on("data",(function(e){i.update(e)})),t.on("error",(function(e){r(e)})),t.on("end",(function(){r(null,i.digest(n))}));else{if(!r||!a||s||"undefined"===typeof FileReader){o.isBrowser()&&"object"===typeof t&&!s&&(t=new o.Buffer(new Uint8Array(t)));var c=i.update(t).digest(n);return r&&r(null,c),c}var u=0,l=new FileReader;l.onerror=function(){r(new Error("Failed to read data."))},l.onload=function(){var e=new o.Buffer(new Uint8Array(l.result));i.update(e),u+=e.length,l._continueReading()},l._continueReading=function(){if(u>=t.size)r(null,i.digest(n));else{var e=u+524288;e>t.size&&(e=t.size),l.readAsArrayBuffer(a.call(t,u,e))}},l._continueReading()}},toHex:function(e){for(var t=[],n=0;n=3e5,!1),i.config.isClockSkewed},applyClockOffset:function(e){e&&(i.config.systemClockOffset=e-(new Date).getTime())},extractRequestId:function(e){var t=e.httpResponse.headers["x-amz-request-id"]||e.httpResponse.headers["x-amzn-requestid"];!t&&e.data&&e.data.ResponseMetadata&&(t=e.data.ResponseMetadata.RequestId),t&&(e.requestId=t),e.error&&(e.error.requestId=t)},addPromises:function(e,t){var n=!1;void 0===t&&i&&i.config&&(t=i.config.getPromisesDependency()),void 0===t&&"undefined"!==typeof Promise&&(t=Promise),"function"!==typeof t&&(n=!0),Array.isArray(e)||(e=[e]);for(var r=0;r=0)return s++,void setTimeout(u,i+(e.retryAfter||0))}n(e)},u=function(){var t="";r.handleRequest(e,a,(function(e){e.on("data",(function(e){t+=e.toString()})),e.on("end",(function(){var r=e.statusCode;if(r<300)n(null,t);else{var i=1e3*parseInt(e.headers["retry-after"],10)||0,a=o.error(new Error,{statusCode:r,retryable:r>=500||429===r});i&&a.retryable&&(a.retryAfter=i),c(a)}}))}),c)};i.util.defer(u)},uuid:{v4:function(){return n(2099).v4()}},convertPayloadToString:function(e){var t=e.request,n=t.operation,r=t.service.api.operations[n].output||{};r.payload&&e.data[r.payload]&&(e.data[r.payload]=e.data[r.payload].toString())},defer:function(e){"object"===typeof t&&"function"===typeof t.nextTick?t.nextTick(e):"function"===typeof r?r(e):setTimeout(e,0)},getRequestPayloadShape:function(e){var t=e.service.api.operations;if(t){var n=(t||{})[e.operation];if(n&&n.input&&n.input.payload)return n.input.members[n.input.payload]}},getProfilesFromSharedConfig:function(e,t){var n={},r={};if(Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0})[o.configOptInEnv])r=e.loadFrom({isConfig:!0,filename:Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0})[o.sharedConfigFileEnv]});var i={};try{i=e.loadFrom({filename:t||Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0})[o.configOptInEnv]&&Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0})[o.sharedCredentialsFileEnv]})}catch(u){if(!Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0})[o.configOptInEnv])throw u}for(var a=0,s=Object.keys(r);a=6},parse:function(e){var t=e.split(":");return{partition:t[1],service:t[2],region:t[3],accountId:t[4],resource:t.slice(5).join(":")}},build:function(e){if(void 0===e.service||void 0===e.region||void 0===e.accountId||void 0===e.resource)throw o.error(new Error("Input ARN object is invalid"));return"arn:"+(e.partition||"aws")+":"+e.service+":"+e.region+":"+e.accountId+":"+e.resource}},defaultProfile:"default",configOptInEnv:"AWS_SDK_LOAD_CONFIG",sharedCredentialsFileEnv:"AWS_SHARED_CREDENTIALS_FILE",sharedConfigFileEnv:"AWS_CONFIG_FILE",imdsDisabledEnv:"AWS_EC2_METADATA_DISABLED"};e.exports=o}).call(this,n(81),n(506).setImmediate)},function(e,t,n){"use strict";n.d(t,"a",(function(){return b})),n.d(t,"b",(function(){return w})),n.d(t,"c",(function(){return x})),n.d(t,"d",(function(){return C})),n.d(t,"e",(function(){return v})),n.d(t,"f",(function(){return D})),n.d(t,"g",(function(){return N})),n.d(t,"h",(function(){return g})),n.d(t,"i",(function(){return k})),n.d(t,"j",(function(){return M})),n.d(t,"k",(function(){return B})),n.d(t,"l",(function(){return z})),n.d(t,"m",(function(){return F})),n.d(t,"n",(function(){return U})),n.d(t,"o",(function(){return j}));var r=n(89),i=n(1),o=n.n(i),a=(n(7),n(182)),s=n(763),c=n(141),u=n(2),l=n(764),d=n.n(l),f=(n(93),n(94)),h=n(130),p=n.n(h),m=function(e){var t=Object(s.a)();return t.displayName=e,t}("Router-History"),g=function(e){var t=Object(s.a)();return t.displayName=e,t}("Router"),v=function(e){function t(t){var n;return(n=e.call(this,t)||this).state={location:t.history.location},n._isMounted=!1,n._pendingLocation=null,t.staticContext||(n.unlisten=t.history.listen((function(e){n._isMounted?n.setState({location:e}):n._pendingLocation=e}))),n}Object(r.a)(t,e),t.computeRootMatch=function(e){return{path:"/",url:"/",params:{},isExact:"/"===e}};var n=t.prototype;return n.componentDidMount=function(){this._isMounted=!0,this._pendingLocation&&this.setState({location:this._pendingLocation})},n.componentWillUnmount=function(){this.unlisten&&this.unlisten()},n.render=function(){return o.a.createElement(g.Provider,{value:{history:this.props.history,location:this.state.location,match:t.computeRootMatch(this.state.location.pathname),staticContext:this.props.staticContext}},o.a.createElement(m.Provider,{children:this.props.children||null,value:this.props.history}))},t}(o.a.Component);var b=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<+~=|^:(),"'`\s])/g,b="undefined"!==typeof CSS&&CSS.escape,y=function(e){return b?b(e):e.replace(v,"\\$1")},w=function(){function e(e,t,n){this.type="style",this.isProcessed=!1;var r=n.sheet,i=n.Renderer;this.key=e,this.options=n,this.style=t,r?this.renderer=r.renderer:i&&(this.renderer=new i)}return e.prototype.prop=function(e,t,n){if(void 0===t)return this.style[e];var r=!!n&&n.force;if(!r&&this.style[e]===t)return this;var i=t;n&&!1===n.process||(i=this.options.jss.plugins.onChangeValue(t,e,this));var o=null==i||!1===i,a=e in this.style;if(o&&!a&&!r)return this;var s=o&&a;if(s?delete this.style[e]:this.style[e]=i,this.renderable&&this.renderer)return s?this.renderer.removeProperty(this.renderable,e):this.renderer.setProperty(this.renderable,e,i),this;var c=this.options.sheet;return c&&c.attached,this},e}(),S=function(e){function t(t,n,r){var i;i=e.call(this,t,n,r)||this;var o=r.selector,a=r.scoped,c=r.sheet,u=r.generateId;return o?i.selectorText=o:!1!==a&&(i.id=u(Object(s.a)(Object(s.a)(i)),c),i.selectorText="."+y(i.id)),i}Object(a.a)(t,e);var n=t.prototype;return n.applyTo=function(e){var t=this.renderer;if(t){var n=this.toJSON();for(var r in n)t.setProperty(e,r,n[r])}return this},n.toJSON=function(){var e={};for(var t in this.style){var n=this.style[t];"object"!==typeof n?e[t]=n:Array.isArray(n)&&(e[t]=h(n))}return e},n.toString=function(e){var t=this.options.sheet,n=!!t&&t.options.link?Object(r.a)({},e,{allowEmpty:!0}):e;return g(this.selectorText,this.style,n)},Object(o.a)(t,[{key:"selector",set:function(e){if(e!==this.selectorText){this.selectorText=e;var t=this.renderer,n=this.renderable;if(n&&t)t.setSelector(n,e)||t.replaceRule(n,this)}},get:function(){return this.selectorText}}]),t}(w),_={onCreateRule:function(e,t,n){return"@"===e[0]||n.parent&&"keyframes"===n.parent.type?null:new S(e,t,n)}},k={indent:1,children:!0},x=/@([\w-]+)/,E=function(){function e(e,t,n){this.type="conditional",this.isProcessed=!1,this.key=e;var i=e.match(x);for(var o in this.at=i?i[1]:"unknown",this.query=n.name||"@"+this.at,this.options=n,this.rules=new G(Object(r.a)({},n,{parent:this})),t)this.rules.add(o,t[o]);this.rules.process()}var t=e.prototype;return t.getRule=function(e){return this.rules.get(e)},t.indexOf=function(e){return this.rules.indexOf(e)},t.addRule=function(e,t,n){var r=this.rules.add(e,t,n);return r?(this.options.jss.plugins.onProcessRule(r),r):null},t.toString=function(e){void 0===e&&(e=k);var t=p(e).linebreak;if(null==e.indent&&(e.indent=k.indent),null==e.children&&(e.children=k.children),!1===e.children)return this.query+" {}";var n=this.rules.toString(e);return n?this.query+" {"+t+n+t+"}":""},e}(),O=/@media|@supports\s+/,M={onCreateRule:function(e,t,n){return O.test(e)?new E(e,t,n):null}},C={indent:1,children:!0},T=/@keyframes\s+([\w-]+)/,A=function(){function e(e,t,n){this.type="keyframes",this.at="@keyframes",this.isProcessed=!1;var i=e.match(T);i&&i[1]?this.name=i[1]:this.name="noname",this.key=this.type+"-"+this.name,this.options=n;var o=n.scoped,a=n.sheet,s=n.generateId;for(var c in this.id=!1===o?this.name:y(s(this,a)),this.rules=new G(Object(r.a)({},n,{parent:this})),t)this.rules.add(c,t[c],Object(r.a)({},n,{parent:this}));this.rules.process()}return e.prototype.toString=function(e){void 0===e&&(e=C);var t=p(e).linebreak;if(null==e.indent&&(e.indent=C.indent),null==e.children&&(e.children=C.children),!1===e.children)return this.at+" "+this.id+" {}";var n=this.rules.toString(e);return n&&(n=""+t+n+t),this.at+" "+this.id+" {"+n+"}"},e}(),I=/@keyframes\s+/,P=/\$([\w-]+)/g,R=function(e,t){return"string"===typeof e?e.replace(P,(function(e,n){return n in t?t[n]:e})):e},D=function(e,t,n){var r=e[t],i=R(r,n);i!==r&&(e[t]=i)},N={onCreateRule:function(e,t,n){return"string"===typeof e&&I.test(e)?new A(e,t,n):null},onProcessStyle:function(e,t,n){return"style"===t.type&&n?("animation-name"in e&&D(e,"animation-name",n.keyframes),"animation"in e&&D(e,"animation",n.keyframes),e):e},onChangeValue:function(e,t,n){var r=n.options.sheet;if(!r)return e;switch(t){case"animation":case"animation-name":return R(e,r.keyframes);default:return e}}},j=function(e){function t(){return e.apply(this,arguments)||this}return Object(a.a)(t,e),t.prototype.toString=function(e){var t=this.options.sheet,n=!!t&&t.options.link?Object(r.a)({},e,{allowEmpty:!0}):e;return g(this.key,this.style,n)},t}(w),L={onCreateRule:function(e,t,n){return n.parent&&"keyframes"===n.parent.type?new j(e,t,n):null}},B=function(){function e(e,t,n){this.type="font-face",this.at="@font-face",this.isProcessed=!1,this.key=e,this.style=t,this.options=n}return e.prototype.toString=function(e){var t=p(e).linebreak;if(Array.isArray(this.style)){for(var n="",r=0;r=this.index)t.push(e);else for(var r=0;rn)return void t.splice(r,0,e)},t.reset=function(){this.registry=[]},t.remove=function(e){var t=this.registry.indexOf(e);this.registry.splice(t,1)},t.toString=function(e){for(var t=void 0===e?{}:e,n=t.attached,r=Object(c.a)(t,["attached"]),i=p(r).linebreak,o="",a=0;a0){var n=function(e,t){for(var n=0;nt.index&&r.options.insertionPoint===t.insertionPoint)return r}return null}(t,e);if(n&&n.renderer)return{parent:n.renderer.element.parentNode,node:n.renderer.element};if((n=function(e,t){for(var n=e.length-1;n>=0;n--){var r=e[n];if(r.attached&&r.options.insertionPoint===t.insertionPoint)return r}return null}(t,e))&&n.renderer)return{parent:n.renderer.element.parentNode,node:n.renderer.element.nextSibling}}var r=e.insertionPoint;if(r&&"string"===typeof r){var i=function(e){for(var t=ce(),n=0;nn?n:t},he=function(){function e(e){this.getPropertyValue=ie,this.setProperty=oe,this.removeProperty=ae,this.setSelector=se,this.hasInsertedRules=!1,this.cssRules=[],e&&J.add(e),this.sheet=e;var t=this.sheet?this.sheet.options:{},n=t.media,r=t.meta,i=t.element;this.element=i||function(){var e=document.createElement("style");return e.textContent="\n",e}(),this.element.setAttribute("data-jss",""),n&&this.element.setAttribute("media",n),r&&this.element.setAttribute("data-meta",r);var o=le();o&&this.element.setAttribute("nonce",o)}var t=e.prototype;return t.attach=function(){if(!this.element.parentNode&&this.sheet){!function(e,t){var n=t.insertionPoint,r=ue(t);if(!1!==r&&r.parent)r.parent.insertBefore(e,r.node);else if(n&&"number"===typeof n.nodeType){var i=n,o=i.parentNode;o&&o.insertBefore(e,i.nextSibling)}else ce().appendChild(e)}(this.element,this.sheet.options);var e=Boolean(this.sheet&&this.sheet.deployed);this.hasInsertedRules&&e&&(this.hasInsertedRules=!1,this.deploy())}},t.detach=function(){if(this.sheet){var e=this.element.parentNode;e&&e.removeChild(this.element),this.sheet.options.link&&(this.cssRules=[],this.element.textContent="\n")}},t.deploy=function(){var e=this.sheet;e&&(e.options.link?this.insertRules(e.rules):this.element.textContent="\n"+e.toString()+"\n")},t.insertRules=function(e,t){for(var n=0;n0&&t-1 in e)}function O(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}x.fn=x.prototype={jquery:"3.7.0",constructor:x,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=x.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return x.each(this,e)},map:function(e){return this.pushStack(x.map(this,(function(t,n){return e.call(t,n,t)})))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(x.grep(this,(function(e,t){return(t+1)%2})))},odd:function(){return this.pushStack(x.grep(this,(function(e,t){return t%2})))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n+~]|"+A+")"+A+"*"),U=new RegExp(A+"|>"),q=new RegExp(L),V=new RegExp("^"+R+"$"),W={ID:new RegExp("^#("+R+")"),CLASS:new RegExp("^\\.("+R+")"),TAG:new RegExp("^("+R+"|[*])"),ATTR:new RegExp("^"+j),PSEUDO:new RegExp("^"+L),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+A+"*(even|odd|(([+-]|)(\\d*)n|)"+A+"*(?:([+-]|)"+A+"*(\\d+)|))"+A+"*\\)|)","i"),bool:new RegExp("^(?:"+P+")$","i"),needsContext:new RegExp("^"+A+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+A+"*((?:-\\d)?\\d*)"+A+"*\\)|)(?=[^-]|$)","i")},H=/^(?:input|select|textarea|button)$/i,K=/^h\d$/i,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,G=/[+~]/,X=new RegExp("\\\\[\\da-fA-F]{1,6}"+A+"?|\\\\([^\\r\\n\\f])","g"),Y=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},$=function(){ce()},J=fe((function(e){return!0===e.disabled&&O(e,"fieldset")}),{dir:"parentNode",next:"legend"});try{m.apply(o=s.call(D.childNodes),D.childNodes),o[D.childNodes.length].nodeType}catch(ye){m={apply:function(e,t){N.apply(e,s.call(t))},call:function(e){N.apply(e,s.call(arguments,1))}}}function Q(e,t,n,r){var i,o,a,s,u,l,h,p=t&&t.ownerDocument,b=t?t.nodeType:9;if(n=n||[],"string"!==typeof e||!e||1!==b&&9!==b&&11!==b)return n;if(!r&&(ce(t),t=t||c,d)){if(11!==b&&(u=Z.exec(e)))if(i=u[1]){if(9===b){if(!(a=t.getElementById(i)))return n;if(a.id===i)return m.call(n,a),n}else if(p&&(a=p.getElementById(i))&&Q.contains(t,a)&&a.id===i)return m.call(n,a),n}else{if(u[2])return m.apply(n,t.getElementsByTagName(e)),n;if((i=u[3])&&t.getElementsByClassName)return m.apply(n,t.getElementsByClassName(i)),n}if(!k[e+" "]&&(!f||!f.test(e))){if(h=e,p=t,1===b&&(U.test(e)||F.test(e))){for((p=G.test(e)&&se(t.parentNode)||t)==t&&g.scope||((s=t.getAttribute("id"))?s=x.escapeSelector(s):t.setAttribute("id",s=v)),o=(l=le(e)).length;o--;)l[o]=(s?"#"+s:":scope")+" "+de(l[o]);h=l.join(",")}try{return m.apply(n,p.querySelectorAll(h)),n}catch(y){k(e,!0)}finally{s===v&&t.removeAttribute("id")}}}return be(e.replace(I,"$1"),t,n,r)}function ee(){var e=[];return function n(r,i){return e.push(r+" ")>t.cacheLength&&delete n[e.shift()],n[r+" "]=i}}function te(e){return e[v]=!0,e}function ne(e){var t=c.createElement("fieldset");try{return!!e(t)}catch(ye){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function re(e){return function(t){return O(t,"input")&&t.type===e}}function ie(e){return function(t){return(O(t,"input")||O(t,"button"))&&t.type===e}}function oe(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&J(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function ae(e){return te((function(t){return t=+t,te((function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))}))}))}function se(e){return e&&"undefined"!==typeof e.getElementsByTagName&&e}function ce(e){var n,r=e?e.ownerDocument||e:D;return r!=c&&9===r.nodeType&&r.documentElement?(u=(c=r).documentElement,d=!x.isXMLDoc(c),p=u.matches||u.webkitMatchesSelector||u.msMatchesSelector,D!=c&&(n=c.defaultView)&&n.top!==n&&n.addEventListener("unload",$),g.getById=ne((function(e){return u.appendChild(e).id=x.expando,!c.getElementsByName||!c.getElementsByName(x.expando).length})),g.disconnectedMatch=ne((function(e){return p.call(e,"*")})),g.scope=ne((function(){return c.querySelectorAll(":scope")})),g.cssHas=ne((function(){try{return c.querySelector(":has(*,:jqfake)"),!1}catch(ye){return!0}})),g.getById?(t.filter.ID=function(e){var t=e.replace(X,Y);return function(e){return e.getAttribute("id")===t}},t.find.ID=function(e,t){if("undefined"!==typeof t.getElementById&&d){var n=t.getElementById(e);return n?[n]:[]}}):(t.filter.ID=function(e){var t=e.replace(X,Y);return function(e){var n="undefined"!==typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}},t.find.ID=function(e,t){if("undefined"!==typeof t.getElementById&&d){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];for(i=t.getElementsByName(e),r=0;o=i[r++];)if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),t.find.TAG=function(e,t){return"undefined"!==typeof t.getElementsByTagName?t.getElementsByTagName(e):t.querySelectorAll(e)},t.find.CLASS=function(e,t){if("undefined"!==typeof t.getElementsByClassName&&d)return t.getElementsByClassName(e)},f=[],ne((function(e){var t;u.appendChild(e).innerHTML="",e.querySelectorAll("[selected]").length||f.push("\\["+A+"*(?:value|"+P+")"),e.querySelectorAll("[id~="+v+"-]").length||f.push("~="),e.querySelectorAll("a#"+v+"+*").length||f.push(".#.+[+~]"),e.querySelectorAll(":checked").length||f.push(":checked"),(t=c.createElement("input")).setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),u.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&f.push(":enabled",":disabled"),(t=c.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||f.push("\\["+A+"*name"+A+"*="+A+"*(?:''|\"\")")})),g.cssHas||f.push(":has"),f=f.length&&new RegExp(f.join("|")),E=function(e,t){if(e===t)return a=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!g.sortDetached&&t.compareDocumentPosition(e)===n?e===c||e.ownerDocument==D&&Q.contains(D,e)?-1:t===c||t.ownerDocument==D&&Q.contains(D,t)?1:i?l.call(i,e)-l.call(i,t):0:4&n?-1:1)},c):c}for(e in Q.matches=function(e,t){return Q(e,null,null,t)},Q.matchesSelector=function(e,t){if(ce(e),d&&!k[t+" "]&&(!f||!f.test(t)))try{var n=p.call(e,t);if(n||g.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(ye){k(t,!0)}return Q(t,c,null,[e]).length>0},Q.contains=function(e,t){return(e.ownerDocument||e)!=c&&ce(e),x.contains(e,t)},Q.attr=function(e,n){(e.ownerDocument||e)!=c&&ce(e);var r=t.attrHandle[n.toLowerCase()],i=r&&h.call(t.attrHandle,n.toLowerCase())?r(e,n,!d):void 0;return void 0!==i?i:e.getAttribute(n)},Q.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},x.uniqueSort=function(e){var t,n=[],r=0,o=0;if(a=!g.sortStable,i=!g.sortStable&&s.call(e,0),C.call(e,E),a){for(;t=e[o++];)t===e[o]&&(r=n.push(o));for(;r--;)T.call(e,n[r],1)}return i=null,e},x.fn.uniqueSort=function(){return this.pushStack(x.uniqueSort(s.apply(this)))},(t=x.expr={cacheLength:50,createPseudo:te,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(X,Y),e[3]=(e[3]||e[4]||e[5]||"").replace(X,Y),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||Q.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&Q.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return W.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&q.test(n)&&(t=le(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(X,Y).toLowerCase();return"*"===e?function(){return!0}:function(e){return O(e,t)}},CLASS:function(e){var t=w[e+" "];return t||(t=new RegExp("(^|"+A+")"+e+"("+A+"|$)"))&&w(e,(function(e){return t.test("string"===typeof e.className&&e.className||"undefined"!==typeof e.getAttribute&&e.getAttribute("class")||"")}))},ATTR:function(e,t,n){return function(r){var i=Q.attr(r,e);return null==i?"!="===t:!t||(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i.replace(B," ")+" ").indexOf(n)>-1:"|="===t&&(i===n||i.slice(0,n.length+1)===n+"-"))}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,c){var u,l,d,f,h,p=o!==a?"nextSibling":"previousSibling",m=t.parentNode,g=s&&t.nodeName.toLowerCase(),y=!c&&!s,w=!1;if(m){if(o){for(;p;){for(d=t;d=d[p];)if(s?O(d,g):1===d.nodeType)return!1;h=p="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&y){for(w=(f=(u=(l=m[v]||(m[v]={}))[e]||[])[0]===b&&u[1])&&u[2],d=f&&m.childNodes[f];d=++f&&d&&d[p]||(w=f=0)||h.pop();)if(1===d.nodeType&&++w&&d===t){l[e]=[b,f,w];break}}else if(y&&(w=f=(u=(l=t[v]||(t[v]={}))[e]||[])[0]===b&&u[1]),!1===w)for(;(d=++f&&d&&d[p]||(w=f=0)||h.pop())&&(!(s?O(d,g):1===d.nodeType)||!++w||(y&&((l=d[v]||(d[v]={}))[e]=[b,w]),d!==t)););return(w-=i)===r||w%r===0&&w/r>=0}}},PSEUDO:function(e,n){var r,i=t.pseudos[e]||t.setFilters[e.toLowerCase()]||Q.error("unsupported pseudo: "+e);return i[v]?i(n):i.length>1?(r=[e,e,"",n],t.setFilters.hasOwnProperty(e.toLowerCase())?te((function(e,t){for(var r,o=i(e,n),a=o.length;a--;)e[r=l.call(e,o[a])]=!(t[r]=o[a])})):function(e){return i(e,0,r)}):i}},pseudos:{not:te((function(e){var t=[],n=[],r=ve(e.replace(I,"$1"));return r[v]?te((function(e,t,n,i){for(var o,a=r(e,null,i,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))})):function(e,i,o){return t[0]=e,r(t,null,o,n),t[0]=null,!n.pop()}})),has:te((function(e){return function(t){return Q(e,t).length>0}})),contains:te((function(e){return e=e.replace(X,Y),function(t){return(t.textContent||x.text(t)).indexOf(e)>-1}})),lang:te((function(e){return V.test(e||"")||Q.error("unsupported lang: "+e),e=e.replace(X,Y).toLowerCase(),function(t){var n;do{if(n=d?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}})),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===u},focus:function(e){return e===function(){try{return c.activeElement}catch(e){}}()&&c.hasFocus()&&!!(e.type||e.href||~e.tabIndex)},enabled:oe(!1),disabled:oe(!0),checked:function(e){return O(e,"input")&&!!e.checked||O(e,"option")&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!t.pseudos.empty(e)},header:function(e){return K.test(e.nodeName)},input:function(e){return H.test(e.nodeName)},button:function(e){return O(e,"input")&&"button"===e.type||O(e,"button")},text:function(e){var t;return O(e,"input")&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ae((function(){return[0]})),last:ae((function(e,t){return[t-1]})),eq:ae((function(e,t,n){return[n<0?n+t:n]})),even:ae((function(e,t){for(var n=0;nt?t:n;--r>=0;)e.push(r);return e})),gt:ae((function(e,t,n){for(var r=n<0?n+t:n;++r1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function pe(e,t,n,r,i){for(var o,a=[],s=0,c=e.length,u=null!=t;s-1&&(o[u]=!(a[u]=f))}}else h=pe(h===a?h.splice(v,h.length):h),i?i(null,a,h,c):m.apply(a,h)}))}function ge(e){for(var n,i,o,a=e.length,s=t.relative[e[0].type],c=s||t.relative[" "],u=s?1:0,d=fe((function(e){return e===n}),c,!0),f=fe((function(e){return l.call(n,e)>-1}),c,!0),h=[function(e,t,i){var o=!s&&(i||t!=r)||((n=t).nodeType?d(e,t,i):f(e,t,i));return n=null,o}];u1&&he(h),u>1&&de(e.slice(0,u-1).concat({value:" "===e[u-2].type?"*":""})).replace(I,"$1"),i,u0,o=e.length>0,a=function(a,s,u,l,f){var h,p,g,v=0,y="0",w=a&&[],S=[],_=r,k=a||o&&t.find.TAG("*",f),E=b+=null==_?1:Math.random()||.1,O=k.length;for(f&&(r=s==c||s||f);y!==O&&null!=(h=k[y]);y++){if(o&&h){for(p=0,s||h.ownerDocument==c||(ce(h),u=!d);g=e[p++];)if(g(h,s||c,u)){m.call(l,h);break}f&&(b=E)}i&&((h=!g&&h)&&v--,a&&w.push(h))}if(v+=y,i&&y!==v){for(p=0;g=n[p++];)g(w,S,s,u);if(a){if(v>0)for(;y--;)w[y]||S[y]||(S[y]=M.call(l));S=pe(S)}m.apply(l,S),f&&!a&&S.length>0&&v+n.length>1&&x.uniqueSort(l)}return f&&(b=E,r=_),w};return i?te(a):a}(a,o))).selector=e}return s}function be(e,n,r,i){var o,a,s,c,u,l="function"===typeof e&&e,f=!i&&le(e=l.selector||e);if(r=r||[],1===f.length){if((a=f[0]=f[0].slice(0)).length>2&&"ID"===(s=a[0]).type&&9===n.nodeType&&d&&t.relative[a[1].type]){if(!(n=(t.find.ID(s.matches[0].replace(X,Y),n)||[])[0]))return r;l&&(n=n.parentNode),e=e.slice(a.shift().value.length)}for(o=W.needsContext.test(e)?0:a.length;o--&&(s=a[o],!t.relative[c=s.type]);)if((u=t.find[c])&&(i=u(s.matches[0].replace(X,Y),G.test(a[0].type)&&se(n.parentNode)||n))){if(a.splice(o,1),!(e=i.length&&de(a)))return m.apply(r,i),r;break}}return(l||ve(e,f))(i,n,!d,r,!n||G.test(e)&&se(n.parentNode)||n),r}ue.prototype=t.filters=t.pseudos,t.setFilters=new ue,g.sortStable=v.split("").sort(E).join("")===v,ce(),g.sortDetached=ne((function(e){return 1&e.compareDocumentPosition(c.createElement("fieldset"))})),x.find=Q,x.expr[":"]=x.expr.pseudos,x.unique=x.uniqueSort,Q.compile=ve,Q.select=be,Q.setDocument=ce,Q.escape=x.escapeSelector,Q.getText=x.text,Q.isXML=x.isXMLDoc,Q.selectors=x.expr,Q.support=x.support,Q.uniqueSort=x.uniqueSort}();var j=function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&x(e).is(n))break;r.push(e)}return r},L=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},B=x.expr.match.needsContext,z=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function F(e,t,n){return v(t)?x.grep(e,(function(e,r){return!!t.call(e,r,e)!==n})):t.nodeType?x.grep(e,(function(e){return e===t!==n})):"string"!==typeof t?x.grep(e,(function(e){return l.call(t,e)>-1!==n})):x.filter(t,e,n)}x.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?x.find.matchesSelector(r,e)?[r]:[]:x.find.matches(e,x.grep(t,(function(e){return 1===e.nodeType})))},x.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!==typeof e)return this.pushStack(x(e).filter((function(){for(t=0;t1?x.uniqueSort(n):n},filter:function(e){return this.pushStack(F(this,e||[],!1))},not:function(e){return this.pushStack(F(this,e||[],!0))},is:function(e){return!!F(this,"string"===typeof e&&B.test(e)?x(e):e||[],!1).length}});var U,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(x.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||U,"string"===typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof x?t[0]:t,x.merge(this,x.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:y,!0)),z.test(r[1])&&x.isPlainObject(t))for(r in t)v(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=y.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):v(e)?void 0!==n.ready?n.ready(e):e(x):x.makeArray(e,this)}).prototype=x.fn,U=x(y);var V=/^(?:parents|prev(?:Until|All))/,W={children:!0,contents:!0,next:!0,prev:!0};function H(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}x.fn.extend({has:function(e){var t=x(e,this),n=t.length;return this.filter((function(){for(var e=0;e-1:1===n.nodeType&&x.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?x.uniqueSort(o):o)},index:function(e){return e?"string"===typeof e?l.call(x(e),this[0]):l.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(x.uniqueSort(x.merge(this.get(),x(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),x.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return j(e,"parentNode")},parentsUntil:function(e,t,n){return j(e,"parentNode",n)},next:function(e){return H(e,"nextSibling")},prev:function(e){return H(e,"previousSibling")},nextAll:function(e){return j(e,"nextSibling")},prevAll:function(e){return j(e,"previousSibling")},nextUntil:function(e,t,n){return j(e,"nextSibling",n)},prevUntil:function(e,t,n){return j(e,"previousSibling",n)},siblings:function(e){return L((e.parentNode||{}).firstChild,e)},children:function(e){return L(e.firstChild)},contents:function(e){return null!=e.contentDocument&&a(e.contentDocument)?e.contentDocument:(O(e,"template")&&(e=e.content||e),x.merge([],e.childNodes))}},(function(e,t){x.fn[e]=function(n,r){var i=x.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"===typeof r&&(i=x.filter(r,i)),this.length>1&&(W[e]||x.uniqueSort(i),V.test(e)&&i.reverse()),this.pushStack(i)}}));var K=/[^\x20\t\r\n\f]+/g;function Z(e){return e}function G(e){throw e}function X(e,t,n,r){var i;try{e&&v(i=e.promise)?i.call(e).done(t).fail(n):e&&v(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}x.Callbacks=function(e){e="string"===typeof e?function(e){var t={};return x.each(e.match(K)||[],(function(e,n){t[n]=!0})),t}(e):x.extend({},e);var t,n,r,i,o=[],a=[],s=-1,c=function(){for(i=i||e.once,r=t=!0;a.length;s=-1)for(n=a.shift();++s-1;)o.splice(n,1),n<=s&&s--})),this},has:function(e){return e?x.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n="",this},disabled:function(){return!o},lock:function(){return i=a=[],n||t||(o=n=""),this},locked:function(){return!!i},fireWith:function(e,n){return i||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||c()),this},fire:function(){return u.fireWith(this,arguments),this},fired:function(){return!!r}};return u},x.extend({Deferred:function(e){var t=[["notify","progress",x.Callbacks("memory"),x.Callbacks("memory"),2],["resolve","done",x.Callbacks("once memory"),x.Callbacks("once memory"),0,"resolved"],["reject","fail",x.Callbacks("once memory"),x.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return i.then(null,e)},pipe:function(){var e=arguments;return x.Deferred((function(n){x.each(t,(function(t,r){var i=v(e[r[4]])&&e[r[4]];o[r[1]]((function(){var e=i&&i.apply(this,arguments);e&&v(e.promise)?e.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[r[0]+"With"](this,i?[e]:arguments)}))})),e=null})).promise()},then:function(e,r,i){var o=0;function a(e,t,r,i){return function(){var s=this,c=arguments,u=function(){var n,u;if(!(e=o&&(r!==G&&(s=void 0,c=[n]),t.rejectWith(s,c))}};e?l():(x.Deferred.getErrorHook?l.error=x.Deferred.getErrorHook():x.Deferred.getStackHook&&(l.error=x.Deferred.getStackHook()),n.setTimeout(l))}}return x.Deferred((function(n){t[0][3].add(a(0,n,v(i)?i:Z,n.notifyWith)),t[1][3].add(a(0,n,v(e)?e:Z)),t[2][3].add(a(0,n,v(r)?r:G))})).promise()},promise:function(e){return null!=e?x.extend(e,i):i}},o={};return x.each(t,(function(e,n){var a=n[2],s=n[5];i[n[1]]=a.add,s&&a.add((function(){r=s}),t[3-e][2].disable,t[3-e][3].disable,t[0][2].lock,t[0][3].lock),a.add(n[3].fire),o[n[0]]=function(){return o[n[0]+"With"](this===o?void 0:this,arguments),this},o[n[0]+"With"]=a.fireWith})),i.promise(o),e&&e.call(o,o),o},when:function(e){var t=arguments.length,n=t,r=Array(n),i=s.call(arguments),o=x.Deferred(),a=function(e){return function(n){r[e]=this,i[e]=arguments.length>1?s.call(arguments):n,--t||o.resolveWith(r,i)}};if(t<=1&&(X(e,o.done(a(n)).resolve,o.reject,!t),"pending"===o.state()||v(i[n]&&i[n].then)))return o.then();for(;n--;)X(i[n],a(n),o.reject);return o.promise()}});var Y=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;x.Deferred.exceptionHook=function(e,t){n.console&&n.console.warn&&e&&Y.test(e.name)&&n.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},x.readyException=function(e){n.setTimeout((function(){throw e}))};var $=x.Deferred();function J(){y.removeEventListener("DOMContentLoaded",J),n.removeEventListener("load",J),x.ready()}x.fn.ready=function(e){return $.then(e).catch((function(e){x.readyException(e)})),this},x.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--x.readyWait:x.isReady)||(x.isReady=!0,!0!==e&&--x.readyWait>0||$.resolveWith(y,[x]))}}),x.ready.then=$.then,"complete"===y.readyState||"loading"!==y.readyState&&!y.documentElement.doScroll?n.setTimeout(x.ready):(y.addEventListener("DOMContentLoaded",J),n.addEventListener("load",J));var Q=function e(t,n,r,i,o,a,s){var c=0,u=t.length,l=null==r;if("object"===_(r))for(c in o=!0,r)e(t,n,c,r[c],!0,a,s);else if(void 0!==i&&(o=!0,v(i)||(s=!0),l&&(s?(n.call(t,i),n=null):(l=n,n=function(e,t,n){return l.call(x(e),n)})),n))for(;c1,null,!0)},removeData:function(e){return this.each((function(){se.remove(this,e)}))}}),x.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=ae.get(e,t),n&&(!r||Array.isArray(n)?r=ae.access(e,t,x.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){var n=x.queue(e,t=t||"fx"),r=n.length,i=n.shift(),o=x._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,(function(){x.dequeue(e,t)}),o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return ae.get(e,n)||ae.access(e,n,{empty:x.Callbacks("once memory").add((function(){ae.remove(e,[t+"queue",n])}))})}}),x.fn.extend({queue:function(e,t){var n=2;return"string"!==typeof e&&(t=e,e="fx",n--),arguments.length\x20\t\r\n\f]*)/i,xe=/^$|^module$|\/(?:java|ecma)script/i;!function(){var e=y.createDocumentFragment().appendChild(y.createElement("div")),t=y.createElement("input");t.setAttribute("type","radio"),t.setAttribute("checked","checked"),t.setAttribute("name","t"),e.appendChild(t),g.checkClone=e.cloneNode(!0).cloneNode(!0).lastChild.checked,e.innerHTML="",g.noCloneChecked=!!e.cloneNode(!0).lastChild.defaultValue,e.innerHTML="",g.option=!!e.lastChild}();var Ee={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function Oe(e,t){var n;return n="undefined"!==typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!==typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&O(e,t)?x.merge([e],n):n}function Me(e,t){for(var n=0,r=e.length;n",""]);var Ce=/<|&#?\w+;/;function Te(e,t,n,r,i){for(var o,a,s,c,u,l,d=t.createDocumentFragment(),f=[],h=0,p=e.length;h-1)i&&i.push(o);else if(u=me(o),a=Oe(d.appendChild(o),"script"),u&&Me(a),n)for(l=0;o=a[l++];)xe.test(o.type||"")&&n.push(o);return d}var Ae=/^([^.]*)(?:\.(.+)|)/;function Ie(){return!0}function Pe(){return!1}function Re(e,t,n,r,i,o){var a,s;if("object"===typeof t){for(s in"string"!==typeof n&&(r=r||n,n=void 0),t)Re(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"===typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Pe;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return x().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=x.guid++)),e.each((function(){x.event.add(this,t,i,r,n)}))}function De(e,t,n){n?(ae.set(e,t,!1),x.event.add(e,t,{namespace:!1,handler:function(e){var n,r=ae.get(this,t);if(1&e.isTrigger&&this[t]){if(r)(x.event.special[t]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),ae.set(this,t,r),this[t](),n=ae.get(this,t),ae.set(this,t,!1),r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n}else r&&(ae.set(this,t,x.event.trigger(r[0],r.slice(1),this)),e.stopPropagation(),e.isImmediatePropagationStopped=Ie)}})):void 0===ae.get(e,t)&&x.event.add(e,t,Ie)}x.event={global:{},add:function(e,t,n,r,i){var o,a,s,c,u,l,d,f,h,p,m,g=ae.get(e);if(ie(e))for(n.handler&&(n=(o=n).handler,i=o.selector),i&&x.find.matchesSelector(pe,i),n.guid||(n.guid=x.guid++),(c=g.events)||(c=g.events=Object.create(null)),(a=g.handle)||(a=g.handle=function(t){return x.event.triggered!==t.type?x.event.dispatch.apply(e,arguments):void 0}),u=(t=(t||"").match(K)||[""]).length;u--;)h=m=(s=Ae.exec(t[u])||[])[1],p=(s[2]||"").split(".").sort(),h&&(d=x.event.special[h]||{},h=(i?d.delegateType:d.bindType)||h,d=x.event.special[h]||{},l=x.extend({type:h,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&x.expr.match.needsContext.test(i),namespace:p.join(".")},o),(f=c[h])||((f=c[h]=[]).delegateCount=0,d.setup&&!1!==d.setup.call(e,r,p,a)||e.addEventListener&&e.addEventListener(h,a)),d.add&&(d.add.call(e,l),l.handler.guid||(l.handler.guid=n.guid)),i?f.splice(f.delegateCount++,0,l):f.push(l),x.event.global[h]=!0)},remove:function(e,t,n,r,i){var o,a,s,c,u,l,d,f,h,p,m,g=ae.hasData(e)&&ae.get(e);if(g&&(c=g.events)){for(u=(t=(t||"").match(K)||[""]).length;u--;)if(h=m=(s=Ae.exec(t[u])||[])[1],p=(s[2]||"").split(".").sort(),h){for(d=x.event.special[h]||{},f=c[h=(r?d.delegateType:d.bindType)||h]||[],s=s[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=f.length;o--;)l=f[o],!i&&m!==l.origType||n&&n.guid!==l.guid||s&&!s.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(f.splice(o,1),l.selector&&f.delegateCount--,d.remove&&d.remove.call(e,l));a&&!f.length&&(d.teardown&&!1!==d.teardown.call(e,p,g.handle)||x.removeEvent(e,h,g.handle),delete c[h])}else for(h in c)x.event.remove(e,h+t[u],n,r,!0);x.isEmptyObject(c)&&ae.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),c=x.event.fix(e),u=(ae.get(this,"events")||Object.create(null))[c.type]||[],l=x.event.special[c.type]||{};for(s[0]=c,t=1;t=1))for(;u!==this;u=u.parentNode||this)if(1===u.nodeType&&("click"!==e.type||!0!==u.disabled)){for(o=[],a={},n=0;n-1:x.find(i,this,null,[u]).length),a[i]&&o.push(r);o.length&&s.push({elem:u,handlers:o})}return u=this,c\s*$/g;function Be(e,t){return O(e,"table")&&O(11!==t.nodeType?t:t.firstChild,"tr")&&x(e).children("tbody")[0]||e}function ze(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Fe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Ue(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(ae.hasData(e)&&(s=ae.get(e).events))for(i in ae.remove(t,"handle events"),s)for(n=0,r=s[i].length;n1&&"string"===typeof p&&!g.checkClone&&je.test(p))return e.each((function(i){var o=e.eq(i);m&&(t[0]=p.call(this,i,o.html())),Ve(o,t,n,r)}));if(f&&(o=(i=Te(t,e[0].ownerDocument,!1,e,r)).firstChild,1===i.childNodes.length&&(i=o),o||r)){for(s=(a=x.map(Oe(i,"script"),ze)).length;d0&&Me(a,!c&&Oe(e,"script")),s},cleanData:function(e){for(var t,n,r,i=x.event.special,o=0;void 0!==(n=e[o]);o++)if(ie(n)){if(t=n[ae.expando]){if(t.events)for(r in t.events)i[r]?x.event.remove(n,r):x.removeEvent(n,r,t.handle);n[ae.expando]=void 0}n[se.expando]&&(n[se.expando]=void 0)}}}),x.fn.extend({detach:function(e){return We(this,e,!0)},remove:function(e){return We(this,e)},text:function(e){return Q(this,(function(e){return void 0===e?x.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)}))}),null,e,arguments.length)},append:function(){return Ve(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Be(this,e).appendChild(e)}))},prepend:function(){return Ve(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Be(this,e);t.insertBefore(e,t.firstChild)}}))},before:function(){return Ve(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return Ve(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(x.cleanData(Oe(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map((function(){return x.clone(this,e,t)}))},html:function(e){return Q(this,(function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"===typeof e&&!Ne.test(e)&&!Ee[(ke.exec(e)||["",""])[1].toLowerCase()]){e=x.htmlPrefilter(e);try{for(;n=0&&(c+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-c-s-.5))||0),c+u}function st(e,t,n){var r=Ze(e),i=(!g.boxSizingReliable()||n)&&"border-box"===x.css(e,"boxSizing",!1,r),o=i,a=Ye(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(He.test(a)){if(!n)return a;a="auto"}return(!g.boxSizingReliable()&&i||!g.reliableTrDimensions()&&O(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===x.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===x.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+at(e,t,n||(i?"border":"content"),o,r,a)+"px"}function ct(e,t,n,r,i){return new ct.prototype.init(e,t,n,r,i)}x.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Ye(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=re(t),c=Ke.test(t),u=e.style;if(c||(t=tt(s)),a=x.cssHooks[t]||x.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:u[t];"string"===(o=typeof n)&&(i=fe.exec(n))&&i[1]&&(n=be(e,t,i),o="number"),null!=n&&n===n&&("number"!==o||c||(n+=i&&i[3]||(x.cssNumber[s]?"":"px")),g.clearCloneStyle||""!==n||0!==t.indexOf("background")||(u[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(c?u.setProperty(t,n):u[t]=n))}},css:function(e,t,n,r){var i,o,a,s=re(t);return Ke.test(t)||(t=tt(s)),(a=x.cssHooks[t]||x.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Ye(e,t,r)),"normal"===i&&t in it&&(i=it[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),x.each(["height","width"],(function(e,t){x.cssHooks[t]={get:function(e,n,r){if(n)return!nt.test(x.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?st(e,t,r):Ge(e,rt,(function(){return st(e,t,r)}))},set:function(e,n,r){var i,o=Ze(e),a=!g.scrollboxSize()&&"absolute"===o.position,s=(a||r)&&"border-box"===x.css(e,"boxSizing",!1,o),c=r?at(e,t,r,s,o):0;return s&&a&&(c-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-at(e,t,"border",!1,o)-.5)),c&&(i=fe.exec(n))&&"px"!==(i[3]||"px")&&(e.style[t]=n,n=x.css(e,t)),ot(0,n,c)}}})),x.cssHooks.marginLeft=$e(g.reliableMarginLeft,(function(e,t){if(t)return(parseFloat(Ye(e,"marginLeft"))||e.getBoundingClientRect().left-Ge(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})))+"px"})),x.each({margin:"",padding:"",border:"Width"},(function(e,t){x.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"===typeof n?n.split(" "):[n];r<4;r++)i[e+he[r]+t]=o[r]||o[r-2]||o[0];return i}},"margin"!==e&&(x.cssHooks[e+t].set=ot)})),x.fn.extend({css:function(e,t){return Q(this,(function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ze(e),i=t.length;a1)}}),x.Tween=ct,ct.prototype={constructor:ct,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||x.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(x.cssNumber[n]?"":"px")},cur:function(){var e=ct.propHooks[this.prop];return e&&e.get?e.get(this):ct.propHooks._default.get(this)},run:function(e){var t,n=ct.propHooks[this.prop];return this.options.duration?this.pos=t=x.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):ct.propHooks._default.set(this),this}},ct.prototype.init.prototype=ct.prototype,ct.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=x.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){x.fx.step[e.prop]?x.fx.step[e.prop](e):1!==e.elem.nodeType||!x.cssHooks[e.prop]&&null==e.elem.style[tt(e.prop)]?e.elem[e.prop]=e.now:x.style(e.elem,e.prop,e.now+e.unit)}}},ct.propHooks.scrollTop=ct.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},x.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},(x.fx=ct.prototype.init).step={};var ut,lt,dt=/^(?:toggle|show|hide)$/,ft=/queueHooks$/;function ht(){lt&&(!1===y.hidden&&n.requestAnimationFrame?n.requestAnimationFrame(ht):n.setTimeout(ht,x.fx.interval),x.fx.tick())}function pt(){return n.setTimeout((function(){ut=void 0})),ut=Date.now()}function mt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=he[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function gt(e,t,n){for(var r,i=(vt.tweeners[t]||[]).concat(vt.tweeners["*"]),o=0,a=i.length;o1)},removeAttr:function(e){return this.each((function(){x.removeAttr(this,e)}))}}),x.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"===typeof e.getAttribute?x.prop(e,t,n):(1===o&&x.isXMLDoc(e)||(i=x.attrHooks[t.toLowerCase()]||(x.expr.match.bool.test(t)?bt:void 0)),void 0!==n?null===n?void x.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=x.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!g.radioValue&&"radio"===t&&O(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(K);if(i&&1===e.nodeType)for(;n=i[r++];)e.removeAttribute(n)}}),bt={set:function(e,t,n){return!1===t?x.removeAttr(e,n):e.setAttribute(n,n),n}},x.each(x.expr.match.bool.source.match(/\w+/g),(function(e,t){var n=yt[t]||x.find.attr;yt[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=yt[a],yt[a]=i,i=null!=n(e,t,r)?a:null,yt[a]=o),i}}));var wt=/^(?:input|select|textarea|button)$/i,St=/^(?:a|area)$/i;function _t(e){return(e.match(K)||[]).join(" ")}function kt(e){return e.getAttribute&&e.getAttribute("class")||""}function xt(e){return Array.isArray(e)?e:"string"===typeof e&&e.match(K)||[]}x.fn.extend({prop:function(e,t){return Q(this,x.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each((function(){delete this[x.propFix[e]||e]}))}}),x.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&x.isXMLDoc(e)||(t=x.propFix[t]||t,i=x.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=x.find.attr(e,"tabindex");return t?parseInt(t,10):wt.test(e.nodeName)||St.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),g.optSelected||(x.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),x.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){x.propFix[this.toLowerCase()]=this})),x.fn.extend({addClass:function(e){var t,n,r,i,o,a;return v(e)?this.each((function(t){x(this).addClass(e.call(this,t,kt(this)))})):(t=xt(e)).length?this.each((function(){if(r=kt(this),n=1===this.nodeType&&" "+_t(r)+" "){for(o=0;o-1;)n=n.replace(" "+i+" "," ");a=_t(n),r!==a&&this.setAttribute("class",a)}})):this:this.attr("class","")},toggleClass:function(e,t){var n,r,i,o,a=typeof e,s="string"===a||Array.isArray(e);return v(e)?this.each((function(n){x(this).toggleClass(e.call(this,n,kt(this),t),t)})):"boolean"===typeof t&&s?t?this.addClass(e):this.removeClass(e):(n=xt(e),this.each((function(){if(s)for(o=x(this),i=0;i-1)return!0;return!1}});var Et=/\r/g;x.fn.extend({val:function(e){var t,n,r,i=this[0];return arguments.length?(r=v(e),this.each((function(n){var i;1===this.nodeType&&(null==(i=r?e.call(this,n,x(this).val()):e)?i="":"number"===typeof i?i+="":Array.isArray(i)&&(i=x.map(i,(function(e){return null==e?"":e+""}))),(t=x.valHooks[this.type]||x.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))}))):i?(t=x.valHooks[i.type]||x.valHooks[i.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:"string"===typeof(n=i.value)?n.replace(Et,""):null==n?"":n:void 0}}),x.extend({valHooks:{option:{get:function(e){var t=x.find.attr(e,"value");return null!=t?t:_t(x.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],c=a?o+1:i.length;for(r=o<0?c:a?o:0;r-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),x.each(["radio","checkbox"],(function(){x.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=x.inArray(x(e).val(),t)>-1}},g.checkOn||(x.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}));var Ot=n.location,Mt={guid:Date.now()},Ct=/\?/;x.parseXML=function(e){var t,r;if(!e||"string"!==typeof e)return null;try{t=(new n.DOMParser).parseFromString(e,"text/xml")}catch(i){}return r=t&&t.getElementsByTagName("parsererror")[0],t&&!r||x.error("Invalid XML: "+(r?x.map(r.childNodes,(function(e){return e.textContent})).join("\n"):e)),t};var Tt=/^(?:focusinfocus|focusoutblur)$/,At=function(e){e.stopPropagation()};x.extend(x.event,{trigger:function(e,t,r,i){var o,a,s,c,u,l,d,f,p=[r||y],m=h.call(e,"type")?e.type:e,g=h.call(e,"namespace")?e.namespace.split("."):[];if(a=f=s=r=r||y,3!==r.nodeType&&8!==r.nodeType&&!Tt.test(m+x.event.triggered)&&(m.indexOf(".")>-1&&(g=m.split("."),m=g.shift(),g.sort()),u=m.indexOf(":")<0&&"on"+m,(e=e[x.expando]?e:new x.Event(m,"object"===typeof e&&e)).isTrigger=i?2:3,e.namespace=g.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+g.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=r),t=null==t?[e]:x.makeArray(t,[e]),d=x.event.special[m]||{},i||!d.trigger||!1!==d.trigger.apply(r,t))){if(!i&&!d.noBubble&&!b(r)){for(c=d.delegateType||m,Tt.test(c+m)||(a=a.parentNode);a;a=a.parentNode)p.push(a),s=a;s===(r.ownerDocument||y)&&p.push(s.defaultView||s.parentWindow||n)}for(o=0;(a=p[o++])&&!e.isPropagationStopped();)f=a,e.type=o>1?c:d.bindType||m,(l=(ae.get(a,"events")||Object.create(null))[e.type]&&ae.get(a,"handle"))&&l.apply(a,t),(l=u&&a[u])&&l.apply&&ie(a)&&(e.result=l.apply(a,t),!1===e.result&&e.preventDefault());return e.type=m,i||e.isDefaultPrevented()||d._default&&!1!==d._default.apply(p.pop(),t)||!ie(r)||u&&v(r[m])&&!b(r)&&((s=r[u])&&(r[u]=null),x.event.triggered=m,e.isPropagationStopped()&&f.addEventListener(m,At),r[m](),e.isPropagationStopped()&&f.removeEventListener(m,At),x.event.triggered=void 0,s&&(r[u]=s)),e.result}},simulate:function(e,t,n){var r=x.extend(new x.Event,n,{type:e,isSimulated:!0});x.event.trigger(r,null,t)}}),x.fn.extend({trigger:function(e,t){return this.each((function(){x.event.trigger(e,t,this)}))},triggerHandler:function(e,t){var n=this[0];if(n)return x.event.trigger(e,t,n,!0)}});var It=/\[\]$/,Pt=/\r?\n/g,Rt=/^(?:submit|button|image|reset|file)$/i,Dt=/^(?:input|select|textarea|keygen)/i;function Nt(e,t,n,r){var i;if(Array.isArray(t))x.each(t,(function(t,i){n||It.test(e)?r(e,i):Nt(e+"["+("object"===typeof i&&null!=i?t:"")+"]",i,n,r)}));else if(n||"object"!==_(t))r(e,t);else for(i in t)Nt(e+"["+i+"]",t[i],n,r)}x.param=function(e,t){var n,r=[],i=function(e,t){var n=v(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!x.isPlainObject(e))x.each(e,(function(){i(this.name,this.value)}));else for(n in e)Nt(n,e[n],t,i);return r.join("&")},x.fn.extend({serialize:function(){return x.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=x.prop(this,"elements");return e?x.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!x(this).is(":disabled")&&Dt.test(this.nodeName)&&!Rt.test(e)&&(this.checked||!_e.test(e))})).map((function(e,t){var n=x(this).val();return null==n?null:Array.isArray(n)?x.map(n,(function(e){return{name:t.name,value:e.replace(Pt,"\r\n")}})):{name:t.name,value:n.replace(Pt,"\r\n")}})).get()}});var jt=/%20/g,Lt=/#.*$/,Bt=/([?&])_=[^&]*/,zt=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ft=/^(?:GET|HEAD)$/,Ut=/^\/\//,qt={},Vt={},Wt="*/".concat("*"),Ht=y.createElement("a");function Kt(e){return function(t,n){"string"!==typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(K)||[];if(v(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function Zt(e,t,n,r){var i={},o=e===Vt;function a(s){var c;return i[s]=!0,x.each(e[s]||[],(function(e,s){var u=s(t,n,r);return"string"!==typeof u||o||i[u]?o?!(c=u):void 0:(t.dataTypes.unshift(u),a(u),!1)})),c}return a(t.dataTypes[0])||!i["*"]&&a("*")}function Gt(e,t){var n,r,i=x.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&x.extend(!0,e,r),e}Ht.href=Ot.href,x.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ot.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Ot.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Wt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":x.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Gt(Gt(e,x.ajaxSettings),t):Gt(x.ajaxSettings,e)},ajaxPrefilter:Kt(qt),ajaxTransport:Kt(Vt),ajax:function(e,t){"object"===typeof e&&(t=e,e=void 0);var r,i,o,a,s,c,u,l,d,f,h=x.ajaxSetup({},t=t||{}),p=h.context||h,m=h.context&&(p.nodeType||p.jquery)?x(p):x.event,g=x.Deferred(),v=x.Callbacks("once memory"),b=h.statusCode||{},w={},S={},_="canceled",k={readyState:0,getResponseHeader:function(e){var t;if(u){if(!a)for(a={};t=zt.exec(o);)a[t[1].toLowerCase()+" "]=(a[t[1].toLowerCase()+" "]||[]).concat(t[2]);t=a[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return u?o:null},setRequestHeader:function(e,t){return null==u&&(e=S[e.toLowerCase()]=S[e.toLowerCase()]||e,w[e]=t),this},overrideMimeType:function(e){return null==u&&(h.mimeType=e),this},statusCode:function(e){var t;if(e)if(u)k.always(e[k.status]);else for(t in e)b[t]=[b[t],e[t]];return this},abort:function(e){var t=e||_;return r&&r.abort(t),E(0,t),this}};if(g.promise(k),h.url=((e||h.url||Ot.href)+"").replace(Ut,Ot.protocol+"//"),h.type=t.method||t.type||h.method||h.type,h.dataTypes=(h.dataType||"*").toLowerCase().match(K)||[""],null==h.crossDomain){c=y.createElement("a");try{c.href=h.url,c.href=c.href,h.crossDomain=Ht.protocol+"//"+Ht.host!==c.protocol+"//"+c.host}catch(O){h.crossDomain=!0}}if(h.data&&h.processData&&"string"!==typeof h.data&&(h.data=x.param(h.data,h.traditional)),Zt(qt,h,t,k),u)return k;for(d in(l=x.event&&h.global)&&0===x.active++&&x.event.trigger("ajaxStart"),h.type=h.type.toUpperCase(),h.hasContent=!Ft.test(h.type),i=h.url.replace(Lt,""),h.hasContent?h.data&&h.processData&&0===(h.contentType||"").indexOf("application/x-www-form-urlencoded")&&(h.data=h.data.replace(jt,"+")):(f=h.url.slice(i.length),h.data&&(h.processData||"string"===typeof h.data)&&(i+=(Ct.test(i)?"&":"?")+h.data,delete h.data),!1===h.cache&&(i=i.replace(Bt,"$1"),f=(Ct.test(i)?"&":"?")+"_="+Mt.guid+++f),h.url=i+f),h.ifModified&&(x.lastModified[i]&&k.setRequestHeader("If-Modified-Since",x.lastModified[i]),x.etag[i]&&k.setRequestHeader("If-None-Match",x.etag[i])),(h.data&&h.hasContent&&!1!==h.contentType||t.contentType)&&k.setRequestHeader("Content-Type",h.contentType),k.setRequestHeader("Accept",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+("*"!==h.dataTypes[0]?", "+Wt+"; q=0.01":""):h.accepts["*"]),h.headers)k.setRequestHeader(d,h.headers[d]);if(h.beforeSend&&(!1===h.beforeSend.call(p,k,h)||u))return k.abort();if(_="abort",v.add(h.complete),k.done(h.success),k.fail(h.error),r=Zt(Vt,h,t,k)){if(k.readyState=1,l&&m.trigger("ajaxSend",[k,h]),u)return k;h.async&&h.timeout>0&&(s=n.setTimeout((function(){k.abort("timeout")}),h.timeout));try{u=!1,r.send(w,E)}catch(O){if(u)throw O;E(-1,O)}}else E(-1,"No Transport");function E(e,t,a,c){var d,f,y,w,S,_=t;u||(u=!0,s&&n.clearTimeout(s),r=void 0,o=c||"",k.readyState=e>0?4:0,d=e>=200&&e<300||304===e,a&&(w=function(e,t,n){for(var r,i,o,a,s=e.contents,c=e.dataTypes;"*"===c[0];)c.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){c.unshift(i);break}if(c[0]in n)o=c[0];else{for(i in n){if(!c[0]||e.converters[i+" "+c[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==c[0]&&c.unshift(o),n[o]}(h,k,a)),!d&&x.inArray("script",h.dataTypes)>-1&&x.inArray("json",h.dataTypes)<0&&(h.converters["text script"]=function(){}),w=function(e,t,n,r){var i,o,a,s,c,u={},l=e.dataTypes.slice();if(l[1])for(a in e.converters)u[a.toLowerCase()]=e.converters[a];for(o=l.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!c&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),c=o,o=l.shift())if("*"===o)o=c;else if("*"!==c&&c!==o){if(!(a=u[c+" "+o]||u["* "+o]))for(i in u)if((s=i.split(" "))[1]===o&&(a=u[c+" "+s[0]]||u["* "+s[0]])){!0===a?a=u[i]:!0!==u[i]&&(o=s[0],l.unshift(s[1]));break}if(!0!==a)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(O){return{state:"parsererror",error:a?O:"No conversion from "+c+" to "+o}}}return{state:"success",data:t}}(h,w,k,d),d?(h.ifModified&&((S=k.getResponseHeader("Last-Modified"))&&(x.lastModified[i]=S),(S=k.getResponseHeader("etag"))&&(x.etag[i]=S)),204===e||"HEAD"===h.type?_="nocontent":304===e?_="notmodified":(_=w.state,f=w.data,d=!(y=w.error))):(y=_,!e&&_||(_="error",e<0&&(e=0))),k.status=e,k.statusText=(t||_)+"",d?g.resolveWith(p,[f,_,k]):g.rejectWith(p,[k,_,y]),k.statusCode(b),b=void 0,l&&m.trigger(d?"ajaxSuccess":"ajaxError",[k,h,d?f:y]),v.fireWith(p,[k,_]),l&&(m.trigger("ajaxComplete",[k,h]),--x.active||x.event.trigger("ajaxStop")))}return k},getJSON:function(e,t,n){return x.get(e,t,n,"json")},getScript:function(e,t){return x.get(e,void 0,t,"script")}}),x.each(["get","post"],(function(e,t){x[t]=function(e,n,r,i){return v(n)&&(i=i||r,r=n,n=void 0),x.ajax(x.extend({url:e,type:t,dataType:i,data:n,success:r},x.isPlainObject(e)&&e))}})),x.ajaxPrefilter((function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")})),x._evalUrl=function(e,t,n){return x.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){x.globalEval(e,t,n)}})},x.fn.extend({wrapAll:function(e){var t;return this[0]&&(v(e)&&(e=e.call(this[0])),t=x(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map((function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e})).append(this)),this},wrapInner:function(e){return v(e)?this.each((function(t){x(this).wrapInner(e.call(this,t))})):this.each((function(){var t=x(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)}))},wrap:function(e){var t=v(e);return this.each((function(n){x(this).wrapAll(t?e.call(this,n):e)}))},unwrap:function(e){return this.parent(e).not("body").each((function(){x(this).replaceWith(this.childNodes)})),this}}),x.expr.pseudos.hidden=function(e){return!x.expr.pseudos.visible(e)},x.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},x.ajaxSettings.xhr=function(){try{return new n.XMLHttpRequest}catch(e){}};var Xt={0:200,1223:204},Yt=x.ajaxSettings.xhr();g.cors=!!Yt&&"withCredentials"in Yt,g.ajax=Yt=!!Yt,x.ajaxTransport((function(e){var t,r;if(g.cors||Yt&&!e.crossDomain)return{send:function(i,o){var a,s=e.xhr();if(s.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(a in e.xhrFields)s[a]=e.xhrFields[a];for(a in e.mimeType&&s.overrideMimeType&&s.overrideMimeType(e.mimeType),e.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest"),i)s.setRequestHeader(a,i[a]);t=function(e){return function(){t&&(t=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!==typeof s.status?o(0,"error"):o(s.status,s.statusText):o(Xt[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!==typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=t(),r=s.onerror=s.ontimeout=t("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&n.setTimeout((function(){t&&r()}))},t=t("abort");try{s.send(e.hasContent&&e.data||null)}catch(c){if(t)throw c}},abort:function(){t&&t()}}})),x.ajaxPrefilter((function(e){e.crossDomain&&(e.contents.script=!1)})),x.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return x.globalEval(e),e}}}),x.ajaxPrefilter("script",(function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")})),x.ajaxTransport("script",(function(e){var t,n;if(e.crossDomain||e.scriptAttrs)return{send:function(r,i){t=x("