var Purs_EntryPoints_Livestream_Livestream=(()=>{var KK=Object.create;var gg=Object.defineProperty;var YK=Object.getOwnPropertyDescriptor;var XK=Object.getOwnPropertyNames;var ZK=Object.getPrototypeOf,eY=Object.prototype.hasOwnProperty;var FL=e=>gg(e,"__esModule",{value:!0});var nY=(e,n)=>()=>(e&&(n=e(e=0)),n);var je=(e,n)=>()=>(n||e((n={exports:{}}).exports,n),n.exports),GL=(e,n)=>{FL(e);for(var a in n)gg(e,a,{get:n[a],enumerable:!0})},aY=(e,n,a)=>{if(n&&typeof n=="object"||typeof n=="function")for(let t of XK(n))!eY.call(e,t)&&t!=="default"&&gg(e,t,{get:()=>n[t],enumerable:!(a=YK(n,t))||a.enumerable});return e},Cu=e=>aY(FL(gg(e!=null?KK(ZK(e)):{},"default",e&&e.__esModule&&"default"in e?{get:()=>e.default,enumerable:!0}:{value:e,enumerable:!0})),e);var ET={};GL(ET,{Children:()=>kf,Component:()=>Bf,Fragment:()=>wT,Suspense:()=>pne,cloneElement:()=>wm,createContext:()=>yT,createElement:()=>vt,createRef:()=>PR,default:()=>ka,forwardRef:()=>Di,isValidElement:()=>bT,lazy:()=>_ne,useCallback:()=>bm,useContext:()=>dne,useEffect:()=>Gt,useImperativeHandle:()=>rs,useLayoutEffect:()=>Em,useMemo:()=>Im,useReducer:()=>mne,useRef:()=>lt,useState:()=>Ll});var ka,kf,wm,Bf,yT,vt,PR,Di,wT,bT,_ne,pne,bm,dne,Gt,rs,Em,Im,mne,lt,Ll,$a=nY(()=>{ka=window.React,{Children:kf,cloneElement:wm,Component:Bf,createContext:yT,createElement:vt,createRef:PR,forwardRef:Di,Fragment:wT,isValidElement:bT,lazy:_ne,Suspense:pne,useCallback:bm,useContext:dne,useEffect:Gt,useImperativeHandle:rs,useLayoutEffect:Em,useMemo:Im,useReducer:mne,useRef:lt,useState:Ll}=window.React});var IT=je((Oze,Ix)=>{"use strict";var Ex=Object.getOwnPropertySymbols,hne=Object.prototype.hasOwnProperty,Dne=Object.prototype.propertyIsEnumerable;function gne(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function Rne(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var n={},a=0;a<10;a++)n["_"+String.fromCharCode(a)]=a;var t=Object.getOwnPropertyNames(n).map(function(u){return n[u]});if(t.join("")!=="0123456789")return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(u){o[u]=u}),Object.keys(Object.assign({},o)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}Ix.exports=Rne()?Object.assign:function(e,n){for(var a,t=gne(e),o,u=1;u{"use strict";var TT=IT(),J0=60103,Tx=60106;mt.Fragment=60107;mt.StrictMode=60108;mt.Profiler=60114;var Sx=60109,Cx=60110,Fx=60112;mt.Suspense=60113;var Gx=60115,Mx=60116;typeof Symbol=="function"&&Symbol.for&&(el=Symbol.for,J0=el("react.element"),Tx=el("react.portal"),mt.Fragment=el("react.fragment"),mt.StrictMode=el("react.strict_mode"),mt.Profiler=el("react.profiler"),Sx=el("react.provider"),Cx=el("react.context"),Fx=el("react.forward_ref"),mt.Suspense=el("react.suspense"),Gx=el("react.memo"),Mx=el("react.lazy"));var el,Ax=typeof Symbol=="function"&&Symbol.iterator;function yne(e){return e===null||typeof e!="object"?null:(e=Ax&&e[Ax]||e["@@iterator"],typeof e=="function"?e:null)}function Tm(e){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+e,a=1;a{"use strict";Hx.exports=Bx()});var vN=je($0=>{"use strict";var Pl=IT(),us=AT();function _r(e){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+e,a=1;aFm;Fm++)Go[Fm]=Fm+1;var Go,Fm;Go[15]=0;var Cne=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Qx=Object.prototype.hasOwnProperty,Kx={},Yx={};function Xx(e){return Qx.call(Yx,e)?!0:Qx.call(Kx,e)?!1:Cne.test(e)?Yx[e]=!0:(Kx[e]=!0,!1)}function Fne(e,n,a,t){if(a!==null&&a.type===0)return!1;switch(typeof n){case"function":case"symbol":return!0;case"boolean":return t?!1:a!==null?!a.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Gne(e,n,a,t){if(n===null||typeof n=="undefined"||Fne(e,n,a,t))return!0;if(t)return!1;if(a!==null)switch(a.type){case 3:return!n;case 4:return n===!1;case 5:return isNaN(n);case 6:return isNaN(n)||1>n}return!1}function mu(e,n,a,t,o,u,i){this.acceptsBooleans=n===2||n===3||n===4,this.attributeName=t,this.attributeNamespace=o,this.mustUseProperty=a,this.propertyName=e,this.type=n,this.sanitizeURL=u,this.removeEmptyString=i}var Mo={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Mo[e]=new mu(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var n=e[0];Mo[n]=new mu(n,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Mo[e]=new mu(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Mo[e]=new mu(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Mo[e]=new mu(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Mo[e]=new mu(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Mo[e]=new mu(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Mo[e]=new mu(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Mo[e]=new mu(e,5,!1,e.toLowerCase(),null,!1,!1)});var BT=/[\-:]([a-z])/g;function HT(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var n=e.replace(BT,HT);Mo[n]=new mu(n,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var n=e.replace(BT,HT);Mo[n]=new mu(n,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var n=e.replace(BT,HT);Mo[n]=new mu(n,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Mo[e]=new mu(e,1,!1,e.toLowerCase(),null,!1,!1)});Mo.xlinkHref=new mu("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Mo[e]=new mu(e,1,!1,e.toLowerCase(),null,!0,!0)});var Mne=/["'&<>]/;function Hf(e){if(typeof e=="boolean"||typeof e=="number")return""+e;e=""+e;var n=Mne.exec(e);if(n){var a="",t,o=0;for(t=n.index;tqR))throw Error(_r(301));if(e===vc)if(HR=!0,e={action:a,next:null},_v===null&&(_v=new Map),a=_v.get(n),a===void 0)_v.set(n,e);else{for(n=a;n.next!==null;)n=n.next;n.next=e}}function JT(){}var Jf=null,Nne={readContext:function(e){var n=Jf.threadID;return Cm(e,n),e[n]},useContext:function(e){qf();var n=Jf.threadID;return Cm(e,n),e[n]},useMemo:rN,useReducer:tN,useRef:function(e){vc=qf(),Yt=qT();var n=Yt.memoizedState;return n===null?(e={current:e},Yt.memoizedState=e):n},useState:function(e){return tN(aN,e)},useLayoutEffect:function(){},useCallback:function(e,n){return rN(function(){return e},n)},useImperativeHandle:JT,useEffect:JT,useDebugValue:JT,useDeferredValue:function(e){return qf(),e},useTransition:function(){return qf(),[function(e){e()},!1]},useOpaqueIdentifier:function(){return(Jf.identifierPrefix||"")+"R:"+(Jf.uniqueID++).toString(36)},useMutableSource:function(e,n){return qf(),n(e._source)}},oN={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function uN(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}var iN={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},jne=Pl({menuitem:!0},iN),Mm={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},One=["Webkit","ms","Moz","O"];Object.keys(Mm).forEach(function(e){One.forEach(function(n){n=n+e.charAt(0).toUpperCase()+e.substring(1),Mm[n]=Mm[e]})});var Une=/([A-Z])/g,kne=/^ms-/,pv=us.Children.toArray,WT=Tne.ReactCurrentDispatcher,Bne={listing:!0,pre:!0,textarea:!0},Hne=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,lN={},$T={};function qne(e){if(e==null)return e;var n="";return us.Children.forEach(e,function(a){a!=null&&(n+=a)}),n}var Jne=Object.prototype.hasOwnProperty,Wne={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null,suppressHydrationWarning:null};function cN(e,n){if(e===void 0)throw Error(_r(152,Sm(n)||"Component"))}function $ne(e,n,a){function t(i,l){var s=l.prototype&&l.prototype.isReactComponent,R=Sne(l,n,a,s),d=[],y=!1,I={isMounted:function(){return!1},enqueueForceUpdate:function(){if(d===null)return null},enqueueReplaceState:function(ee,oe){y=!0,d=[oe]},enqueueSetState:function(ee,oe){if(d===null)return null;d.push(oe)}};if(s){if(s=new l(i.props,R,I),typeof l.getDerivedStateFromProps=="function"){var b=l.getDerivedStateFromProps.call(null,i.props,s.state);b!=null&&(s.state=Pl({},s.state,b))}}else if(vc={},s=l(i.props,R,I),s=eN(l,i.props,s,R),s==null||s.render==null){e=s,cN(e,l);return}if(s.props=i.props,s.context=R,s.updater=I,I=s.state,I===void 0&&(s.state=I=null),typeof s.UNSAFE_componentWillMount=="function"||typeof s.componentWillMount=="function")if(typeof s.componentWillMount=="function"&&typeof l.getDerivedStateFromProps!="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&typeof l.getDerivedStateFromProps!="function"&&s.UNSAFE_componentWillMount(),d.length){I=d;var S=y;if(d=null,y=!1,S&&I.length===1)s.state=I[0];else{b=S?I[0]:s.state;var L=!0;for(S=S?1:0;S=l))throw Error(_r(304));var s=new Uint16Array(l);for(s.set(i),Go=s,Go[0]=u+1,i=u;i=s.children.length){var R=s.footer;if(R!==""&&(this.previousWasTextNode=!1),this.stack.pop(),s.type==="select")this.currentSelectValue=null;else if(s.type!=null&&s.type.type!=null&&s.type.type.$$typeof===UR)this.popProvider(s.type);else if(s.type===kR){this.suspenseDepth--;var d=u.pop();if(i){i=!1;var y=s.fallbackFrame;if(!y)throw Error(_r(303));this.stack.push(y),u[this.suspenseDepth]+="";continue}else u[this.suspenseDepth]+=d}u[this.suspenseDepth]+=R}else{var I=s.children[s.childIndex++],b="";try{b+=this.render(I,s.context,s.domNamespace)}catch(S){throw S!=null&&typeof S.then=="function"?Error(_r(294)):S}finally{}u.length<=this.suspenseDepth&&u.push(""),u[this.suspenseDepth]+=b}}return u[0]}finally{WT.current=o,Jf=t,nN()}},n.render=function(a,t,o){if(typeof a=="string"||typeof a=="number")return o=""+a,o===""?"":this.makeStaticMarkup?Hf(o):this.previousWasTextNode?""+Hf(o):(this.previousWasTextNode=!0,Hf(o));if(t=$ne(a,t,this.threadID),a=t.child,t=t.context,a===null||a===!1)return"";if(!us.isValidElement(a)){if(a!=null&&a.$$typeof!=null)throw o=a.$$typeof,Error(o===LT?_r(257):_r(258,o.toString()));return a=pv(a),this.stack.push({type:null,domNamespace:o,children:a,childIndex:0,context:t,footer:""}),""}var u=a.type;if(typeof u=="string")return this.renderDOM(a,t,o);switch(u){case zx:case $x:case PT:case xT:case OT:case OR:return a=pv(a.props.children),this.stack.push({type:null,domNamespace:o,children:a,childIndex:0,context:t,footer:""}),"";case kR:throw Error(_r(294));case Wx:throw Error(_r(343))}if(typeof u=="object"&&u!==null)switch(u.$$typeof){case jT:vc={};var i=u.render(a.props,a.ref);return i=eN(u.render,a.props,i,a.ref),i=pv(i),this.stack.push({type:null,domNamespace:o,children:i,childIndex:0,context:t,footer:""}),"";case UT:return a=[us.createElement(u.type,Pl({ref:a.ref},a.props))],this.stack.push({type:null,domNamespace:o,children:a,childIndex:0,context:t,footer:""}),"";case UR:return u=pv(a.props.children),o={type:a,domNamespace:o,children:u,childIndex:0,context:t,footer:""},this.pushProvider(a),this.stack.push(o),"";case NT:u=a.type,i=a.props;var l=this.threadID;return Cm(u,l),u=pv(i.children(u[l])),this.stack.push({type:a,domNamespace:o,children:u,childIndex:0,context:t,footer:""}),"";case Jx:throw Error(_r(338));case kT:return u=a.type,i=u._init,u=i(u._payload),a=[us.createElement(u,Pl({ref:a.ref},a.props))],this.stack.push({type:null,domNamespace:o,children:a,childIndex:0,context:t,footer:""}),""}throw Error(_r(130,u==null?u:typeof u,""))},n.renderDOM=function(a,t,o){var u=a.type.toLowerCase();if(o===oN.html&&uN(u),!lN.hasOwnProperty(u)){if(!Hne.test(u))throw Error(_r(65,u));lN[u]=!0}var i=a.props;if(u==="input")i=Pl({type:void 0},i,{defaultChecked:void 0,defaultValue:void 0,value:i.value!=null?i.value:i.defaultValue,checked:i.checked!=null?i.checked:i.defaultChecked});else if(u==="textarea"){var l=i.value;if(l==null){l=i.defaultValue;var s=i.children;if(s!=null){if(l!=null)throw Error(_r(92));if(Array.isArray(s)){if(!(1>=s.length))throw Error(_r(93));s=s[0]}l=""+s}l==null&&(l="")}i=Pl({},i,{value:void 0,children:""+l})}else if(u==="select")this.currentSelectValue=i.value!=null?i.value:i.defaultValue,i=Pl({},i,{value:void 0});else if(u==="option"){s=this.currentSelectValue;var R=qne(i.children);if(s!=null){var d=i.value!=null?i.value+"":R;if(l=!1,Array.isArray(s)){for(var y=0;y":(oe+=">",l="");e:{if(s=i.dangerouslySetInnerHTML,s!=null){if(s.__html!=null){s=s.__html;break e}}else if(s=i.children,typeof s=="string"||typeof s=="number"){s=Hf(s);break e}s=null}return s!=null?(i=[],Bne.hasOwnProperty(u)&&s.charAt(0)===` `&&(oe+=` `),oe+=s):i=pv(i.children),a=a.type,o=o==null||o==="http://www.w3.org/1999/xhtml"?uN(a):o==="http://www.w3.org/2000/svg"&&a==="foreignObject"?"http://www.w3.org/1999/xhtml":o,this.stack.push({domNamespace:o,type:u,children:i,childIndex:0,context:t,footer:l}),this.previousWasTextNode=!1,oe},e}();$0.renderToNodeStream=function(){throw Error(_r(207))};$0.renderToStaticMarkup=function(e,n){e=new sN(e,!0,n);try{return e.read(1/0)}finally{e.destroy()}};$0.renderToStaticNodeStream=function(){throw Error(_r(208))};$0.renderToString=function(e,n){e=new sN(e,!1,n);try{return e.read(1/0)}finally{e.destroy()}};$0.version="17.0.2"});var _N=je((Hze,fN)=>{"use strict";fN.exports=vN()});var _O=je((Qy,LC)=>{(function(n,a){typeof Qy=="object"&&typeof LC=="object"?LC.exports=a():typeof define=="function"&&define.amd?define([],a):typeof Qy=="object"?Qy.Pusher=a():n.Pusher=a()})(window,function(){return function(e){var n={};function a(t){if(n[t])return n[t].exports;var o=n[t]={i:t,l:!1,exports:{}};return e[t].call(o.exports,o,o.exports,a),o.l=!0,o.exports}return a.m=e,a.c=n,a.d=function(t,o,u){a.o(t,o)||Object.defineProperty(t,o,{enumerable:!0,get:u})},a.r=function(t){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.t=function(t,o){if(o&1&&(t=a(t)),o&8||o&4&&typeof t=="object"&&t&&t.__esModule)return t;var u=Object.create(null);if(a.r(u),Object.defineProperty(u,"default",{enumerable:!0,value:t}),o&2&&typeof t!="string")for(var i in t)a.d(u,i,function(l){return t[l]}.bind(null,i));return u},a.n=function(t){var o=t&&t.__esModule?function(){return t.default}:function(){return t};return a.d(o,"a",o),o},a.o=function(t,o){return Object.prototype.hasOwnProperty.call(t,o)},a.p="",a(a.s=2)}([function(e,n,a){"use strict";var t=this&&this.__extends||function(){var b=function(S,L){return b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(O,$){O.__proto__=$}||function(O,$){for(var z in $)$.hasOwnProperty(z)&&(O[z]=$[z])},b(S,L)};return function(S,L){b(S,L);function O(){this.constructor=S}S.prototype=L===null?Object.create(L):(O.prototype=L.prototype,new O)}}();Object.defineProperty(n,"__esModule",{value:!0});var o=256,u=function(){function b(S){S===void 0&&(S="="),this._paddingCharacter=S}return b.prototype.encodedLength=function(S){return this._paddingCharacter?(S+2)/3*4|0:(S*8+5)/6|0},b.prototype.encode=function(S){for(var L="",O=0;O>>3*6&63),L+=this._encodeByte($>>>2*6&63),L+=this._encodeByte($>>>1*6&63),L+=this._encodeByte($>>>0*6&63)}var z=S.length-O;if(z>0){var $=S[O]<<16|(z===2?S[O+1]<<8:0);L+=this._encodeByte($>>>3*6&63),L+=this._encodeByte($>>>2*6&63),z===2?L+=this._encodeByte($>>>1*6&63):L+=this._paddingCharacter||"",L+=this._paddingCharacter||""}return L},b.prototype.maxDecodedLength=function(S){return this._paddingCharacter?S/4*3|0:(S*6+7)/8|0},b.prototype.decodedLength=function(S){return this.maxDecodedLength(S.length-this._getPaddingLength(S))},b.prototype.decode=function(S){if(S.length===0)return new Uint8Array(0);for(var L=this._getPaddingLength(S),O=S.length-L,$=new Uint8Array(this.maxDecodedLength(O)),z=0,ee=0,oe=0,te=0,ve=0,Re=0,nn=0;ee>>4,$[z++]=ve<<4|Re>>>2,$[z++]=Re<<6|nn,oe|=te&o,oe|=ve&o,oe|=Re&o,oe|=nn&o;if(ee>>4,oe|=te&o,oe|=ve&o),ee>>2,oe|=Re&o),ee>>8&0-65-26+97,L+=51-S>>>8&26-97-52+48,L+=61-S>>>8&52-48-62+43,L+=62-S>>>8&62-43-63+47,String.fromCharCode(L)},b.prototype._decodeChar=function(S){var L=o;return L+=(42-S&S-44)>>>8&-o+S-43+62,L+=(46-S&S-48)>>>8&-o+S-47+63,L+=(47-S&S-58)>>>8&-o+S-48+52,L+=(64-S&S-91)>>>8&-o+S-65+0,L+=(96-S&S-123)>>>8&-o+S-97+26,L},b.prototype._getPaddingLength=function(S){var L=0;if(this._paddingCharacter){for(var O=S.length-1;O>=0&&S[O]===this._paddingCharacter;O--)L++;if(S.length<4||L>2)throw new Error("Base64Coder: incorrect padding")}return L},b}();n.Coder=u;var i=new u;function l(b){return i.encode(b)}n.encode=l;function s(b){return i.decode(b)}n.decode=s;var R=function(b){t(S,b);function S(){return b!==null&&b.apply(this,arguments)||this}return S.prototype._encodeByte=function(L){var O=L;return O+=65,O+=25-L>>>8&0-65-26+97,O+=51-L>>>8&26-97-52+48,O+=61-L>>>8&52-48-62+45,O+=62-L>>>8&62-45-63+95,String.fromCharCode(O)},S.prototype._decodeChar=function(L){var O=o;return O+=(44-L&L-46)>>>8&-o+L-45+62,O+=(94-L&L-96)>>>8&-o+L-95+63,O+=(47-L&L-58)>>>8&-o+L-48+52,O+=(64-L&L-91)>>>8&-o+L-65+0,O+=(96-L&L-123)>>>8&-o+L-97+26,O},S}(u);n.URLSafeCoder=R;var d=new R;function y(b){return d.encode(b)}n.encodeURLSafe=y;function I(b){return d.decode(b)}n.decodeURLSafe=I,n.encodedLength=function(b){return i.encodedLength(b)},n.maxDecodedLength=function(b){return i.maxDecodedLength(b)},n.decodedLength=function(b){return i.decodedLength(b)}},function(e,n,a){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var t="utf8: invalid string",o="utf8: invalid source encoding";function u(s){for(var R=new Uint8Array(i(s)),d=0,y=0;y>6,R[d++]=128|I&63):I<55296?(R[d++]=224|I>>12,R[d++]=128|I>>6&63,R[d++]=128|I&63):(y++,I=(I&1023)<<10,I|=s.charCodeAt(y)&1023,I+=65536,R[d++]=240|I>>18,R[d++]=128|I>>12&63,R[d++]=128|I>>6&63,R[d++]=128|I&63)}return R}n.encode=u;function i(s){for(var R=0,d=0;d=s.length-1)throw new Error(t);d++,R+=4}else throw new Error(t)}return R}n.encodedLength=i;function l(s){for(var R=[],d=0;d=s.length)throw new Error(o);var b=s[++d];if((b&192)!=128)throw new Error(o);y=(y&31)<<6|b&63,I=128}else if(y<240){if(d>=s.length-1)throw new Error(o);var b=s[++d],S=s[++d];if((b&192)!=128||(S&192)!=128)throw new Error(o);y=(y&15)<<12|(b&63)<<6|S&63,I=2048}else if(y<248){if(d>=s.length-2)throw new Error(o);var b=s[++d],S=s[++d],L=s[++d];if((b&192)!=128||(S&192)!=128||(L&192)!=128)throw new Error(o);y=(y&15)<<18|(b&63)<<12|(S&63)<<6|L&63,I=65536}else throw new Error(o);if(y=55296&&y<=57343)throw new Error(o);if(y>=65536){if(y>1114111)throw new Error(o);y-=65536,R.push(String.fromCharCode(55296|y>>10)),y=56320|y&1023}}R.push(String.fromCharCode(y))}return R.join("")}n.decode=l},function(e,n,a){e.exports=a(3).default},function(e,n,a){"use strict";a.r(n);var t=function(){function m(p,D){this.lastId=0,this.prefix=p,this.name=D}return m.prototype.create=function(p){this.lastId++;var D=this.lastId,G=this.prefix+D,A=this.name+"["+D+"]",Q=!1,be=function(){Q||(p.apply(null,arguments),Q=!0)};return this[D]=be,{number:D,id:G,name:A,callback:be}},m.prototype.remove=function(p){delete this[p.number]},m}(),o=new t("_pusher_script_","Pusher.ScriptReceivers"),u={VERSION:"6.0.3",PROTOCOL:7,wsPort:80,wssPort:443,wsPath:"",httpHost:"sockjs.pusher.com",httpPort:80,httpsPort:443,httpPath:"/pusher",stats_host:"stats.pusher.com",authEndpoint:"/pusher/auth",authTransport:"ajax",activityTimeout:12e4,pongTimeout:3e4,unavailableTimeout:1e4,cluster:"mt1",cdn_http:"http://js.pusher.com",cdn_https:"https://js.pusher.com",dependency_suffix:""},i=u,l=function(){function m(p){this.options=p,this.receivers=p.receivers||o,this.loading={}}return m.prototype.load=function(p,D,G){var A=this;if(A.loading[p]&&A.loading[p].length>0)A.loading[p].push(G);else{A.loading[p]=[G];var Q=qa.createScriptRequest(A.getPath(p,D)),be=A.receivers.create(function(_n){if(A.receivers.remove(be),A.loading[p]){var ha=A.loading[p];delete A.loading[p];for(var gt=function(bo){bo||Q.cleanup()},zt=0;zt>>6)+I(128|p&63):I(224|p>>>12&15)+I(128|p>>>6&63)+I(128|p&63)},z=function(m){return m.replace(/[^\x00-\x7F]/g,$)},ee=function(m){var p=[0,2,1][m.length%3],D=m.charCodeAt(0)<<16|(m.length>1?m.charCodeAt(1):0)<<8|(m.length>2?m.charCodeAt(2):0),G=[b.charAt(D>>>18),b.charAt(D>>>12&63),p>=2?"=":b.charAt(D>>>6&63),p>=1?"=":b.charAt(D&63)];return G.join("")},oe=window.btoa||function(m){return m.replace(/[\s\S]{1,3}/g,ee)},te=function(){function m(p,D,G,A){var Q=this;this.clear=D,this.timer=p(function(){Q.timer&&(Q.timer=A(Q.timer))},G)}return m.prototype.isRunning=function(){return this.timer!==null},m.prototype.ensureAborted=function(){this.timer&&(this.clear(this.timer),this.timer=null)},m}(),ve=te,Re=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}();function nn(m){window.clearTimeout(m)}function cn(m){window.clearInterval(m)}var ce=function(m){Re(p,m);function p(D,G){return m.call(this,setTimeout,nn,D,function(A){return G(),null})||this}return p}(ve),le=function(m){Re(p,m);function p(D,G){return m.call(this,setInterval,cn,D,function(A){return G(),A})||this}return p}(ve),Ne={now:function(){return Date.now?Date.now():new Date().valueOf()},defer:function(m){return new ce(0,m)},method:function(m){for(var p=[],D=1;D0)for(var A=0;A=1002&&m.code<=1004?"backoff":null:m.code===4e3?"tls_only":m.code<4100?"refused":m.code<4200?"backoff":m.code<4300?"retry":"refused"},getCloseError:function(m){return m.code!==1e3&&m.code!==1001?{type:"PusherError",data:{code:m.code,message:m.reason||m.message}}:null}},se=xc,yl=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),wl=function(m){yl(p,m);function p(D,G){var A=m.call(this)||this;return A.id=D,A.transport=G,A.activityTimeout=G.activityTimeout,A.bindListeners(),A}return p.prototype.handlesActivityChecks=function(){return this.transport.handlesActivityChecks()},p.prototype.send=function(D){return this.transport.send(D)},p.prototype.send_event=function(D,G,A){var Q={event:D,data:G};return A&&(Q.channel=A),sn.debug("Event sent",Q),this.send(se.encodeMessage(Q))},p.prototype.ping=function(){this.transport.supportsPing()?this.transport.ping():this.send_event("pusher:ping",{})},p.prototype.close=function(){this.transport.close()},p.prototype.bindListeners=function(){var D=this,G={message:function(Q){var be;try{be=se.decodeMessage(Q)}catch(_n){D.emit("error",{type:"MessageParseError",error:_n,data:Q.data})}if(be!==void 0){switch(sn.debug("Event recd",be),be.event){case"pusher:error":D.emit("error",{type:"PusherError",data:be.data});break;case"pusher:ping":D.emit("ping");break;case"pusher:pong":D.emit("pong");break}D.emit("message",be)}},activity:function(){D.emit("activity")},error:function(Q){D.emit("error",{type:"WebSocketError",error:Q})},closed:function(Q){A(),Q&&Q.code&&D.handleCloseEvent(Q),D.transport=null,D.emit("closed")}},A=function(){ra(G,function(Q,be){D.transport.unbind(be,Q)})};ra(G,function(Q,be){D.transport.bind(be,Q)})},p.prototype.handleCloseEvent=function(D){var G=se.getCloseAction(D),A=se.getCloseError(D);A&&this.emit("error",A),G&&this.emit(G,{action:G,error:A})},p}(pa),Nc=wl,bl=function(){function m(p,D){this.transport=p,this.callback=D,this.bindListeners()}return m.prototype.close=function(){this.unbindListeners(),this.transport.close()},m.prototype.bindListeners=function(){var p=this;this.onMessage=function(D){p.unbindListeners();var G;try{G=se.processHandshake(D)}catch(A){p.finish("error",{error:A}),p.transport.close();return}G.action==="connected"?p.finish("connected",{connection:new Nc(G.id,p.transport),activityTimeout:G.activityTimeout}):(p.finish(G.action,{error:G.error}),p.transport.close())},this.onClosed=function(D){p.unbindListeners();var G=se.getCloseAction(D)||"backoff",A=se.getCloseError(D);p.finish(G,{error:A})},this.transport.bind("message",this.onMessage),this.transport.bind("closed",this.onClosed)},m.prototype.unbindListeners=function(){this.transport.unbind("message",this.onMessage),this.transport.unbind("closed",this.onClosed)},m.prototype.finish=function(p,D){this.callback(Be({transport:this.transport,action:p},D))},m}(),Pi=bl,pd=function(){function m(p,D){this.channel=p;var G=D.authTransport;if(typeof qa.getAuthorizers()[G]=="undefined")throw"'"+G+"' is not a recognized auth transport";this.type=G,this.options=D,this.authOptions=D.auth||{}}return m.prototype.composeQuery=function(p){var D="socket_id="+encodeURIComponent(p)+"&channel_name="+encodeURIComponent(this.channel.name);for(var G in this.authOptions.params)D+="&"+encodeURIComponent(G)+"="+encodeURIComponent(this.authOptions.params[G]);return D},m.prototype.authorize=function(p,D){m.authorizers=m.authorizers||qa.getAuthorizers(),m.authorizers[this.type].call(this,qa,p,D)},m}(),ef=pd,$_=function(){function m(p,D){this.timeline=p,this.options=D||{}}return m.prototype.send=function(p,D){this.timeline.isEmpty()||this.timeline.send(qa.TimelineTransport.getAgent(this,p),D)},m}(),z_=$_,xi=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),tu=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),jc=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),V_=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),dd=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),Q_=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),kD=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),Js=function(m){xi(p,m);function p(D){var G=this.constructor,A=m.call(this,D)||this;return Object.setPrototypeOf(A,G.prototype),A}return p}(Error),fE=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),_E=function(m){fE(p,m);function p(D,G){var A=m.call(this,function(Q,be){sn.debug("No callbacks on "+D+" for "+Q)})||this;return A.name=D,A.pusher=G,A.subscribed=!1,A.subscriptionPending=!1,A.subscriptionCancelled=!1,A}return p.prototype.authorize=function(D,G){return G(!1,{auth:""})},p.prototype.trigger=function(D,G){if(D.indexOf("client-")!==0)throw new tu("Event '"+D+"' does not start with 'client-'");if(!this.subscribed){var A=Da.buildLogSuffix("triggeringClientEvents");sn.warn("Client event triggered before channel 'subscription_succeeded' event . "+A)}return this.pusher.send_event(D,G,this.name)},p.prototype.disconnect=function(){this.subscribed=!1,this.subscriptionPending=!1},p.prototype.handleEvent=function(D){var G=D.event,A=D.data;if(G==="pusher_internal:subscription_succeeded")this.handleSubscriptionSucceededEvent(D);else if(G.indexOf("pusher_internal:")!==0){var Q={};this.emit(G,A,Q)}},p.prototype.handleSubscriptionSucceededEvent=function(D){this.subscriptionPending=!1,this.subscribed=!0,this.subscriptionCancelled?this.pusher.unsubscribe(this.name):this.emit("pusher:subscription_succeeded",D.data)},p.prototype.subscribe=function(){var D=this;this.subscribed||(this.subscriptionPending=!0,this.subscriptionCancelled=!1,this.authorize(this.pusher.connection.socket_id,function(G,A){G?(sn.error(A),D.emit("pusher:subscription_error",A)):(A=A,D.pusher.send_event("pusher:subscribe",{auth:A.auth,channel_data:A.channel_data,channel:D.name}))}))},p.prototype.unsubscribe=function(){this.subscribed=!1,this.pusher.send_event("pusher:unsubscribe",{channel:this.name})},p.prototype.cancelSubscription=function(){this.subscriptionCancelled=!0},p.prototype.reinstateSubscription=function(){this.subscriptionCancelled=!1},p}(pa),BD=_E,pE=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),dE=function(m){pE(p,m);function p(){return m!==null&&m.apply(this,arguments)||this}return p.prototype.authorize=function(D,G){var A=Ni.createAuthorizer(this,this.pusher.config);return A.authorize(D,G)},p}(BD),md=dE,HD=function(){function m(){this.reset()}return m.prototype.get=function(p){return Object.prototype.hasOwnProperty.call(this.members,p)?{id:p,info:this.members[p]}:null},m.prototype.each=function(p){var D=this;ra(this.members,function(G,A){p(D.get(A))})},m.prototype.setMyID=function(p){this.myID=p},m.prototype.onSubscription=function(p){this.members=p.presence.hash,this.count=p.presence.count,this.me=this.get(this.myID)},m.prototype.addMember=function(p){return this.get(p.user_id)===null&&this.count++,this.members[p.user_id]=p.user_info,this.get(p.user_id)},m.prototype.removeMember=function(p){var D=this.get(p.user_id);return D&&(delete this.members[p.user_id],this.count--),D},m.prototype.reset=function(){this.members={},this.count=0,this.myID=null,this.me=null},m}(),mE=HD,hE=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),qD=function(m){hE(p,m);function p(D,G){var A=m.call(this,D,G)||this;return A.members=new mE,A}return p.prototype.authorize=function(D,G){var A=this;m.prototype.authorize.call(this,D,function(Q,be){if(!Q){if(be=be,be.channel_data===void 0){var _n=Da.buildLogSuffix("authenticationEndpoint");sn.error("Invalid auth response for channel '"+A.name+"',"+("expected 'channel_data' field. "+_n)),G("Invalid auth response");return}var ha=JSON.parse(be.channel_data);A.members.setMyID(ha.user_id)}G(Q,be)})},p.prototype.handleEvent=function(D){var G=D.event;if(G.indexOf("pusher_internal:")===0)this.handleInternalEvent(D);else{var A=D.data,Q={};D.user_id&&(Q.user_id=D.user_id),this.emit(G,A,Q)}},p.prototype.handleInternalEvent=function(D){var G=D.event,A=D.data;switch(G){case"pusher_internal:subscription_succeeded":this.handleSubscriptionSucceededEvent(D);break;case"pusher_internal:member_added":var Q=this.members.addMember(A);this.emit("pusher:member_added",Q);break;case"pusher_internal:member_removed":var be=this.members.removeMember(A);be&&this.emit("pusher:member_removed",be);break}},p.prototype.handleSubscriptionSucceededEvent=function(D){this.subscriptionPending=!1,this.subscribed=!0,this.subscriptionCancelled?this.pusher.unsubscribe(this.name):(this.members.onSubscription(D.data),this.emit("pusher:subscription_succeeded",this.members))},p.prototype.disconnect=function(){this.members.reset(),m.prototype.disconnect.call(this)},p}(md),DE=qD,JD=a(1),hd=a(0),gE=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),RE=function(m){gE(p,m);function p(D,G,A){var Q=m.call(this,D,G)||this;return Q.key=null,Q.nacl=A,Q}return p.prototype.authorize=function(D,G){var A=this;m.prototype.authorize.call(this,D,function(Q,be){if(Q){G(!0,be);return}var _n=be.shared_secret;if(!_n){var ha="No shared_secret key in auth payload for encrypted channel: "+A.name;G(!0,ha);return}A.key=Object(hd.decode)(_n),delete be.shared_secret,G(!1,be)})},p.prototype.trigger=function(D,G){throw new Q_("Client events are not currently supported for encrypted channels")},p.prototype.handleEvent=function(D){var G=D.event,A=D.data;if(G.indexOf("pusher_internal:")===0||G.indexOf("pusher:")===0){m.prototype.handleEvent.call(this,D);return}this.handleEncryptedEvent(G,A)},p.prototype.handleEncryptedEvent=function(D,G){var A=this;if(!this.key){sn.debug("Received encrypted event before key has been retrieved from the authEndpoint");return}if(!G.ciphertext||!G.nonce){sn.error("Unexpected format for encrypted event, expected object with `ciphertext` and `nonce` fields, got: "+G);return}var Q=Object(hd.decode)(G.ciphertext);if(Q.length0&&this.emit("connecting_in",Math.round(D/1e3)),this.retryTimer=new ce(D||0,function(){G.disconnectInternally(),G.connect()})},p.prototype.clearRetryTimer=function(){this.retryTimer&&(this.retryTimer.ensureAborted(),this.retryTimer=null)},p.prototype.setUnavailableTimer=function(){var D=this;this.unavailableTimer=new ce(this.options.unavailableTimeout,function(){D.updateState("unavailable")})},p.prototype.clearUnavailableTimer=function(){this.unavailableTimer&&this.unavailableTimer.ensureAborted()},p.prototype.sendActivityCheck=function(){var D=this;this.stopActivityCheck(),this.connection.ping(),this.activityTimer=new ce(this.options.pongTimeout,function(){D.timeline.error({pong_timed_out:D.options.pongTimeout}),D.retryIn(0)})},p.prototype.resetActivityCheck=function(){var D=this;this.stopActivityCheck(),this.connection&&!this.connection.handlesActivityChecks()&&(this.activityTimer=new ce(this.activityTimeout,function(){D.sendActivityCheck()}))},p.prototype.stopActivityCheck=function(){this.activityTimer&&this.activityTimer.ensureAborted()},p.prototype.buildConnectionCallbacks=function(D){var G=this;return Be({},D,{message:function(A){G.resetActivityCheck(),G.emit("message",A)},ping:function(){G.send_event("pusher:pong",{})},activity:function(){G.resetActivityCheck()},error:function(A){G.emit("error",{type:"WebSocketError",error:A})},closed:function(){G.abandonConnection(),G.shouldRetry()&&G.retryIn(1e3)}})},p.prototype.buildHandshakeCallbacks=function(D){var G=this;return Be({},D,{connected:function(A){G.activityTimeout=Math.min(G.options.activityTimeout,A.activityTimeout,A.connection.activityTimeout||1/0),G.clearUnavailableTimer(),G.setConnection(A.connection),G.socket_id=G.connection.id,G.updateState("connected",{socket_id:G.socket_id})}})},p.prototype.buildErrorCallbacks=function(){var D=this,G=function(A){return function(Q){Q.error&&D.emit("error",{type:"WebSocketError",error:Q.error}),A(Q)}};return{tls_only:G(function(){D.usingTLS=!0,D.updateStrategy(),D.retryIn(0)}),refused:G(function(){D.disconnect()}),backoff:G(function(){D.retryIn(1e3)}),retry:G(function(){D.retryIn(0)})}},p.prototype.setConnection=function(D){this.connection=D;for(var G in this.connectionCallbacks)this.connection.bind(G,this.connectionCallbacks[G]);this.resetActivityCheck()},p.prototype.abandonConnection=function(){if(!!this.connection){this.stopActivityCheck();for(var D in this.connectionCallbacks)this.connection.unbind(D,this.connectionCallbacks[D]);var G=this.connection;return this.connection=null,G}},p.prototype.updateState=function(D,G){var A=this.state;if(this.state=D,A!==D){var Q=D;Q==="connected"&&(Q+=" with new socket ID "+G.socket_id),sn.debug("State changed",A+" -> "+Q),this.timeline.info({state:D,params:G}),this.emit("state_change",{previous:A,current:D}),this.emit(D,G)}},p.prototype.shouldRetry=function(){return this.state==="connecting"||this.state==="connected"},p}(pa),WD=bE,EE=function(){function m(){this.channels={}}return m.prototype.add=function(p,D){return this.channels[p]||(this.channels[p]=$D(p,D)),this.channels[p]},m.prototype.all=function(){return Hn(this.channels)},m.prototype.find=function(p){return this.channels[p]},m.prototype.remove=function(p){var D=this.channels[p];return delete this.channels[p],D},m.prototype.disconnect=function(){ra(this.channels,function(p){p.disconnect()})},m}(),IE=EE;function $D(m,p){if(m.indexOf("private-encrypted-")===0){if(p.config.nacl)return Ni.createEncryptedChannel(m,p,p.config.nacl);var D="Tried to subscribe to a private-encrypted- channel but no nacl implementation available",G=Da.buildLogSuffix("encryptedChannelSupport");throw new Q_(D+". "+G)}else return m.indexOf("private-")===0?Ni.createPrivateChannel(m,p):m.indexOf("presence-")===0?Ni.createPresenceChannel(m,p):Ni.createChannel(m,p)}var TE={createChannels:function(){return new IE},createConnectionManager:function(m,p){return new WD(m,p)},createChannel:function(m,p){return new BD(m,p)},createPrivateChannel:function(m,p){return new md(m,p)},createPresenceChannel:function(m,p){return new DE(m,p)},createEncryptedChannel:function(m,p,D){return new yE(m,p,D)},createTimelineSender:function(m,p){return new z_(m,p)},createAuthorizer:function(m,p){return p.authorizer?p.authorizer(m,p):new ef(m,p)},createHandshake:function(m,p){return new Pi(m,p)},createAssistantToTheTransportManager:function(m,p,D){return new Ql(m,p,D)}},Ni=TE,SE=function(){function m(p){this.options=p||{},this.livesLeft=this.options.lives||1/0}return m.prototype.getAssistant=function(p){return Ni.createAssistantToTheTransportManager(this,p,{minPingDelay:this.options.minPingDelay,maxPingDelay:this.options.maxPingDelay})},m.prototype.isAlive=function(){return this.livesLeft>0},m.prototype.reportDeath=function(){this.livesLeft-=1},m}(),zD=SE,CE=function(){function m(p,D){this.strategies=p,this.loop=Boolean(D.loop),this.failFast=Boolean(D.failFast),this.timeout=D.timeout,this.timeoutLimit=D.timeoutLimit}return m.prototype.isSupported=function(){return En(this.strategies,Ce.method("isSupported"))},m.prototype.connect=function(p,D){var G=this,A=this.strategies,Q=0,be=this.timeout,_n=null,ha=function(gt,zt){zt?D(null,zt):(Q=Q+1,G.loop&&(Q=Q%A.length),Q0&&(Q=new ce(G.timeout,function(){be.abort(),A(!0)})),be=p.connect(D,function(_n,ha){_n&&Q&&Q.isRunning()&&!G.failFast||(Q&&Q.ensureAborted(),A(_n,ha))}),{abort:function(){Q&&Q.ensureAborted(),be.abort()},forceMinPriority:function(_n){be.forceMinPriority(_n)}}},m}(),Oc=CE,FE=function(){function m(p){this.strategies=p}return m.prototype.isSupported=function(){return En(this.strategies,Ce.method("isSupported"))},m.prototype.connect=function(p,D){return GE(this.strategies,p,function(G,A){return function(Q,be){if(A[G].error=Q,Q){VD(A)&&D(!0);return}Kn(A,function(_n){_n.forceMinPriority(be.transport.priority)}),D(null,be)}})},m}(),Dd=FE;function GE(m,p,D){var G=qn(m,function(A,Q,be,_n){return A.connect(p,D(Q,_n))});return{abort:function(){Kn(G,gd)},forceMinPriority:function(A){Kn(G,function(Q){Q.forceMinPriority(A)})}}}function VD(m){return gn(m,function(p){return Boolean(p.error)})}function gd(m){!m.error&&!m.aborted&&(m.abort(),m.aborted=!0)}var ME=function(){function m(p,D,G){this.strategy=p,this.transports=D,this.ttl=G.ttl||1800*1e3,this.usingTLS=G.useTLS,this.timeline=G.timeline}return m.prototype.isSupported=function(){return this.strategy.isSupported()},m.prototype.connect=function(p,D){var G=this.usingTLS,A=QD(G),Q=[this.strategy];if(A&&A.timestamp+this.ttl>=Ce.now()){var be=this.transports[A.transport];be&&(this.timeline.info({cached:!0,transport:A.transport,latency:A.latency}),Q.push(new Oc([be],{timeout:A.latency*2+1e3,failFast:!0})))}var _n=Ce.now(),ha=Q.pop().connect(p,function gt(zt,bo){zt?(KD(G),Q.length>0?(_n=Ce.now(),ha=Q.pop().connect(p,gt)):D(zt)):(LE(G,bo.transport.name,Ce.now()-_n),D(null,bo))});return{abort:function(){ha.abort()},forceMinPriority:function(gt){p=gt,ha&&ha.forceMinPriority(gt)}}},m}(),AE=ME;function Rd(m){return"pusherTransport"+(m?"TLS":"NonTLS")}function QD(m){var p=qa.getLocalStorage();if(p)try{var D=p[Rd(m)];if(D)return JSON.parse(D)}catch{KD(m)}return null}function LE(m,p,D){var G=qa.getLocalStorage();if(G)try{G[Rd(m)]=La({timestamp:Ce.now(),transport:p,latency:D})}catch{}}function KD(m){var p=qa.getLocalStorage();if(p)try{delete p[Rd(m)]}catch{}}var PE=function(){function m(p,D){var G=D.delay;this.strategy=p,this.options={delay:G}}return m.prototype.isSupported=function(){return this.strategy.isSupported()},m.prototype.connect=function(p,D){var G=this.strategy,A,Q=new ce(this.options.delay,function(){A=G.connect(p,D)});return{abort:function(){Q.ensureAborted(),A&&A.abort()},forceMinPriority:function(be){p=be,A&&A.forceMinPriority(be)}}},m}(),K_=PE,YD=function(){function m(p,D,G){this.test=p,this.trueBranch=D,this.falseBranch=G}return m.prototype.isSupported=function(){var p=this.test()?this.trueBranch:this.falseBranch;return p.isSupported()},m.prototype.connect=function(p,D){var G=this.test()?this.trueBranch:this.falseBranch;return G.connect(p,D)},m}(),nf=YD,xE=function(){function m(p){this.strategy=p}return m.prototype.isSupported=function(){return this.strategy.isSupported()},m.prototype.connect=function(p,D){var G=this.strategy.connect(p,function(A,Q){Q&&G.abort(),D(A,Q)});return G},m}(),NE=xE;function El(m){return function(){return m.isSupported()}}var XD=function(m,p,D){var G={};function A(Gr,mg,hg,vI,Dg){var w=D(m,Gr,mg,hg,vI,Dg);return G[Gr]=w,w}var Q=Object.assign({},p,{hostNonTLS:m.wsHost+":"+m.wsPort,hostTLS:m.wsHost+":"+m.wssPort,httpPath:m.wsPath}),be=Object.assign({},Q,{useTLS:!0}),_n=Object.assign({},p,{hostNonTLS:m.httpHost+":"+m.httpPort,hostTLS:m.httpHost+":"+m.httpsPort,httpPath:m.httpPath}),ha={loop:!0,timeout:15e3,timeoutLimit:6e4},gt=new zD({lives:2,minPingDelay:1e4,maxPingDelay:m.activityTimeout}),zt=new zD({lives:2,minPingDelay:1e4,maxPingDelay:m.activityTimeout}),bo=A("ws","ws",3,Q,gt),oi=A("wss","ws",3,be,gt),iI=A("sockjs","sockjs",1,_n),cg=A("xhr_streaming","xhr_streaming",1,_n,zt),sg=A("xdr_streaming","xdr_streaming",1,_n,zt),vg=A("xhr_polling","xhr_polling",1,_n),lI=A("xdr_polling","xdr_polling",1,_n),fg=new Oc([bo],ha),cI=new Oc([oi],ha),sI=new Oc([iI],ha),_g=new Oc([new nf(El(cg),cg,sg)],ha),pg=new Oc([new nf(El(vg),vg,lI)],ha),dg=new Oc([new nf(El(_g),new Dd([_g,new K_(pg,{delay:4e3})]),pg)],ha),Td=new nf(El(dg),dg,sI),Sd;return p.useTLS?Sd=new Dd([fg,new K_(Td,{delay:2e3})]):Sd=new Dd([fg,new K_(cI,{delay:2e3}),new K_(Td,{delay:5e3})]),new AE(new NE(new nf(El(bo),Sd,Td)),G,{ttl:18e5,timeline:p.timeline,useTLS:p.useTLS})},jE=XD,OE=function(){var m=this;m.timeline.info(m.buildTimelineMessage({transport:m.name+(m.options.useTLS?"s":"")})),m.hooks.isInitialized()?m.changeState("initialized"):m.hooks.file?(m.changeState("initializing"),d.load(m.hooks.file,{useTLS:m.options.useTLS},function(p,D){m.hooks.isInitialized()?(m.changeState("initialized"),D(!0)):(p&&m.onError(p),m.onClose(),D(!1))})):m.onClose()},ZD={getRequest:function(m){var p=new window.XDomainRequest;return p.ontimeout=function(){m.emit("error",new jc),m.close()},p.onerror=function(D){m.emit("error",D),m.close()},p.onprogress=function(){p.responseText&&p.responseText.length>0&&m.onChunk(200,p.responseText)},p.onload=function(){p.responseText&&p.responseText.length>0&&m.onChunk(200,p.responseText),m.emit("finished",200),m.close()},p},abortRequest:function(m){m.ontimeout=m.onerror=m.onprogress=m.onload=null,m.abort()}},UE=ZD,eg=function(){var m=function(p,D){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var Q in A)A.hasOwnProperty(Q)&&(G[Q]=A[Q])},m(p,D)};return function(p,D){m(p,D);function G(){this.constructor=p}p.prototype=D===null?Object.create(D):(G.prototype=D.prototype,new G)}}(),kE=256*1024,ng=function(m){eg(p,m);function p(D,G,A){var Q=m.call(this)||this;return Q.hooks=D,Q.method=G,Q.url=A,Q}return p.prototype.start=function(D){var G=this;this.position=0,this.xhr=this.hooks.getRequest(this),this.unloader=function(){G.close()},qa.addUnloadListener(this.unloader),this.xhr.open(this.method,this.url,!0),this.xhr.setRequestHeader&&this.xhr.setRequestHeader("Content-Type","application/json"),this.xhr.send(D)},p.prototype.close=function(){this.unloader&&(qa.removeUnloadListener(this.unloader),this.unloader=null),this.xhr&&(this.hooks.abortRequest(this.xhr),this.xhr=null)},p.prototype.onChunk=function(D,G){for(;;){var A=this.advanceBuffer(G);if(A)this.emit("chunk",{status:D,data:A});else break}this.isBufferTooLong(G)&&this.emit("buffer_too_long")},p.prototype.advanceBuffer=function(D){var G=D.slice(this.position),A=G.indexOf(` `);return A!==-1?(this.position+=A+1,G.slice(0,A)):null},p.prototype.isBufferTooLong=function(D){return this.position===D.length&&D.length>kE},p}(pa),ag=ng,af;(function(m){m[m.CONNECTING=0]="CONNECTING",m[m.OPEN=1]="OPEN",m[m.CLOSED=3]="CLOSED"})(af||(af={}));var ji=af,BE=1,tg=function(){function m(p,D){this.hooks=p,this.session=Tu(1e3)+"/"+Il(8),this.location=HE(D),this.readyState=ji.CONNECTING,this.openStream()}return m.prototype.send=function(p){return this.sendRaw(JSON.stringify([p]))},m.prototype.ping=function(){this.hooks.sendHeartbeat(this)},m.prototype.close=function(p,D){this.onClose(p,D,!0)},m.prototype.sendRaw=function(p){if(this.readyState===ji.OPEN)try{return qa.createSocketRequest("POST",yd(qE(this.location,this.session))).start(p),!0}catch{return!1}else return!1},m.prototype.reconnect=function(){this.closeStream(),this.openStream()},m.prototype.onClose=function(p,D,G){this.closeStream(),this.readyState=ji.CLOSED,this.onclose&&this.onclose({code:p,reason:D,wasClean:G})},m.prototype.onChunk=function(p){if(p.status===200){this.readyState===ji.OPEN&&this.onActivity();var D,G=p.data.slice(0,1);switch(G){case"o":D=JSON.parse(p.data.slice(1)||"{}"),this.onOpen(D);break;case"a":D=JSON.parse(p.data.slice(1)||"[]");for(var A=0;A0&&m.onChunk(D.status,D.responseText);break;case 4:D.responseText&&D.responseText.length>0&&m.onChunk(D.status,D.responseText),m.emit("finished",D.status),m.close();break}},D},abortRequest:function(m){m.onreadystatechange=null,m.abort()}},Ha=og,Uc={createStreamingSocket:function(m){return this.createSocket($E,m)},createPollingSocket:function(m){return this.createSocket(VE,m)},createSocket:function(m,p){return new JE(m,p)},createXHR:function(m,p){return this.createRequest(Ha,m,p)},createRequest:function(m,p,D){return new ag(m,p,D)}},wd=Uc;wd.createXDR=function(m,p){return this.createRequest(UE,m,p)};var QE=wd,KE={nextAuthCallbackID:1,auth_callbacks:{},ScriptReceivers:o,DependenciesReceivers:R,getDefaultStrategy:jE,Transports:wo,transportConnectionInitializer:OE,HTTPFactory:QE,TimelineTransport:re,getXHRAPI:function(){return window.XMLHttpRequest},getWebSocketAPI:function(){return window.WebSocket||window.MozWebSocket},setup:function(m){var p=this;window.Pusher=m;var D=function(){p.onDocumentBody(m.ready)};window.JSON?D():d.load("json2",{},D)},getDocument:function(){return document},getProtocol:function(){return this.getDocument().location.protocol},getAuthorizers:function(){return{ajax:q,jsonp:j}},onDocumentBody:function(m){var p=this;document.body?m():setTimeout(function(){p.onDocumentBody(m)},0)},createJSONPRequest:function(m,p){return new J(m,p)},createScriptRequest:function(m){return new P(m)},getLocalStorage:function(){try{return window.localStorage}catch{return}},createXHR:function(){return this.getXHRAPI()?this.createXMLHttpRequest():this.createMicrosoftXHR()},createXMLHttpRequest:function(){var m=this.getXHRAPI();return new m},createMicrosoftXHR:function(){return new ActiveXObject("Microsoft.XMLHTTP")},getNetwork:function(){return ri},createWebSocket:function(m){var p=this.getWebSocketAPI();return new p(m)},createSocketRequest:function(m,p){if(this.isXHRSupported())return this.HTTPFactory.createXHR(m,p);if(this.isXDRSupported(p.indexOf("https:")===0))return this.HTTPFactory.createXDR(m,p);throw"Cross-origin HTTP requests are not supported"},isXHRSupported:function(){var m=this.getXHRAPI();return Boolean(m)&&new m().withCredentials!==void 0},isXDRSupported:function(m){var p=m?"https:":"http:",D=this.getProtocol();return Boolean(window.XDomainRequest)&&D===p},addUnloadListener:function(m){window.addEventListener!==void 0?window.addEventListener("unload",m,!1):window.attachEvent!==void 0&&window.attachEvent("onunload",m)},removeUnloadListener:function(m){window.addEventListener!==void 0?window.removeEventListener("unload",m,!1):window.detachEvent!==void 0&&window.detachEvent("onunload",m)}},qa=KE,Y_;(function(m){m[m.ERROR=3]="ERROR",m[m.INFO=6]="INFO",m[m.DEBUG=7]="DEBUG"})(Y_||(Y_={}));var X_=Y_,YE=function(){function m(p,D,G){this.key=p,this.session=D,this.events=[],this.options=G||{},this.sent=0,this.uniqueID=0}return m.prototype.log=function(p,D){p<=this.options.level&&(this.events.push(Be({},D,{timestamp:Ce.now()})),this.options.limit&&this.events.length>this.options.limit&&this.events.shift())},m.prototype.error=function(p){this.log(X_.ERROR,p)},m.prototype.info=function(p){this.log(X_.INFO,p)},m.prototype.debug=function(p){this.log(X_.DEBUG,p)},m.prototype.isEmpty=function(){return this.events.length===0},m.prototype.send=function(p,D){var G=this,A=Be({session:this.session,bundle:this.sent+1,key:this.key,lib:"js",version:this.options.version,cluster:this.options.cluster,features:this.options.features,timeline:this.events},this.options.params);return this.events=[],p(A,function(Q,be){Q||G.sent++,D&&D(Q,be)}),!0},m.prototype.generateUniqueID=function(){return this.uniqueID++,this.uniqueID},m}(),ug=YE,bd=function(){function m(p,D,G,A){this.name=p,this.priority=D,this.transport=G,this.options=A||{}}return m.prototype.isSupported=function(){return this.transport.isSupported({useTLS:this.options.useTLS})},m.prototype.connect=function(p,D){var G=this;if(this.isSupported()){if(this.priority{"use strict";var Do=typeof Symbol=="function"&&Symbol.for,GF=Do?Symbol.for("react.element"):60103,MF=Do?Symbol.for("react.portal"):60106,dw=Do?Symbol.for("react.fragment"):60107,mw=Do?Symbol.for("react.strict_mode"):60108,hw=Do?Symbol.for("react.profiler"):60114,Dw=Do?Symbol.for("react.provider"):60109,gw=Do?Symbol.for("react.context"):60110,AF=Do?Symbol.for("react.async_mode"):60111,Rw=Do?Symbol.for("react.concurrent_mode"):60111,yw=Do?Symbol.for("react.forward_ref"):60112,ww=Do?Symbol.for("react.suspense"):60113,zve=Do?Symbol.for("react.suspense_list"):60120,bw=Do?Symbol.for("react.memo"):60115,Ew=Do?Symbol.for("react.lazy"):60116,Vve=Do?Symbol.for("react.block"):60121,Qve=Do?Symbol.for("react.fundamental"):60117,Kve=Do?Symbol.for("react.responder"):60118,Yve=Do?Symbol.for("react.scope"):60119;function Si(e){if(typeof e=="object"&&e!==null){var n=e.$$typeof;switch(n){case GF:switch(e=e.type,e){case AF:case Rw:case dw:case hw:case mw:case ww:return e;default:switch(e=e&&e.$$typeof,e){case gw:case yw:case Ew:case bw:case Dw:return e;default:return n}}case MF:return n}}}function NU(e){return Si(e)===Rw}jt.AsyncMode=AF;jt.ConcurrentMode=Rw;jt.ContextConsumer=gw;jt.ContextProvider=Dw;jt.Element=GF;jt.ForwardRef=yw;jt.Fragment=dw;jt.Lazy=Ew;jt.Memo=bw;jt.Portal=MF;jt.Profiler=hw;jt.StrictMode=mw;jt.Suspense=ww;jt.isAsyncMode=function(e){return NU(e)||Si(e)===AF};jt.isConcurrentMode=NU;jt.isContextConsumer=function(e){return Si(e)===gw};jt.isContextProvider=function(e){return Si(e)===Dw};jt.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===GF};jt.isForwardRef=function(e){return Si(e)===yw};jt.isFragment=function(e){return Si(e)===dw};jt.isLazy=function(e){return Si(e)===Ew};jt.isMemo=function(e){return Si(e)===bw};jt.isPortal=function(e){return Si(e)===MF};jt.isProfiler=function(e){return Si(e)===hw};jt.isStrictMode=function(e){return Si(e)===mw};jt.isSuspense=function(e){return Si(e)===ww};jt.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===dw||e===Rw||e===hw||e===mw||e===ww||e===zve||typeof e=="object"&&e!==null&&(e.$$typeof===Ew||e.$$typeof===bw||e.$$typeof===Dw||e.$$typeof===gw||e.$$typeof===yw||e.$$typeof===Qve||e.$$typeof===Kve||e.$$typeof===Yve||e.$$typeof===Vve)};jt.typeOf=Si});var UU=je((DCa,OU)=>{"use strict";OU.exports=jU()});var y_=je((ACa,Sw)=>{(function(){"use strict";var e={}.hasOwnProperty;function n(){for(var a=[],t=0;t{function jfe(){this.__data__=[],this.size=0}G6.exports=jfe});var aG=je((wGa,A6)=>{function Ofe(e,n){return e===n||e!==e&&n!==n}A6.exports=Ofe});var Dh=je((bGa,L6)=>{var Ufe=aG();function kfe(e,n){for(var a=e.length;a--;)if(Ufe(e[a][0],n))return a;return-1}L6.exports=kfe});var x6=je((EGa,P6)=>{var Bfe=Dh(),Hfe=Array.prototype,qfe=Hfe.splice;function Jfe(e){var n=this.__data__,a=Bfe(n,e);if(a<0)return!1;var t=n.length-1;return a==t?n.pop():qfe.call(n,a,1),--this.size,!0}P6.exports=Jfe});var j6=je((IGa,N6)=>{var Wfe=Dh();function $fe(e){var n=this.__data__,a=Wfe(n,e);return a<0?void 0:n[a][1]}N6.exports=$fe});var U6=je((TGa,O6)=>{var zfe=Dh();function Vfe(e){return zfe(this.__data__,e)>-1}O6.exports=Vfe});var B6=je((SGa,k6)=>{var Qfe=Dh();function Kfe(e,n){var a=this.__data__,t=Qfe(a,e);return t<0?(++this.size,a.push([e,n])):a[t][1]=n,this}k6.exports=Kfe});var gh=je((CGa,H6)=>{var Yfe=M6(),Xfe=x6(),Zfe=j6(),e_e=U6(),n_e=B6();function Tp(e){var n=-1,a=e==null?0:e.length;for(this.clear();++n{var a_e=gh();function t_e(){this.__data__=new a_e,this.size=0}q6.exports=t_e});var $6=je((GGa,W6)=>{function r_e(e){var n=this.__data__,a=n.delete(e);return this.size=n.size,a}W6.exports=r_e});var V6=je((MGa,z6)=>{function o_e(e){return this.__data__.get(e)}z6.exports=o_e});var K6=je((AGa,Q6)=>{function u_e(e){return this.__data__.has(e)}Q6.exports=u_e});var tG=je((LGa,Y6)=>{var i_e=typeof global=="object"&&global&&global.Object===Object&&global;Y6.exports=i_e});var Tc=je((PGa,X6)=>{var l_e=tG(),c_e=typeof self=="object"&&self&&self.Object===Object&&self,s_e=l_e||c_e||Function("return this")();X6.exports=s_e});var Qw=je((xGa,Z6)=>{var v_e=Tc(),f_e=v_e.Symbol;Z6.exports=f_e});var t5=je((NGa,a5)=>{var e5=Qw(),n5=Object.prototype,__e=n5.hasOwnProperty,p_e=n5.toString,Rh=e5?e5.toStringTag:void 0;function d_e(e){var n=__e.call(e,Rh),a=e[Rh];try{e[Rh]=void 0;var t=!0}catch{}var o=p_e.call(e);return t&&(n?e[Rh]=a:delete e[Rh]),o}a5.exports=d_e});var o5=je((jGa,r5)=>{var m_e=Object.prototype,h_e=m_e.toString;function D_e(e){return h_e.call(e)}r5.exports=D_e});var yh=je((OGa,l5)=>{var u5=Qw(),g_e=t5(),R_e=o5(),y_e="[object Null]",w_e="[object Undefined]",i5=u5?u5.toStringTag:void 0;function b_e(e){return e==null?e===void 0?w_e:y_e:i5&&i5 in Object(e)?g_e(e):R_e(e)}l5.exports=b_e});var rG=je((UGa,c5)=>{function E_e(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}c5.exports=E_e});var oG=je((kGa,s5)=>{var I_e=yh(),T_e=rG(),S_e="[object AsyncFunction]",C_e="[object Function]",F_e="[object GeneratorFunction]",G_e="[object Proxy]";function M_e(e){if(!T_e(e))return!1;var n=I_e(e);return n==C_e||n==F_e||n==S_e||n==G_e}s5.exports=M_e});var f5=je((BGa,v5)=>{var A_e=Tc(),L_e=A_e["__core-js_shared__"];v5.exports=L_e});var d5=je((HGa,p5)=>{var uG=f5(),_5=function(){var e=/[^.]+$/.exec(uG&&uG.keys&&uG.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function P_e(e){return!!_5&&_5 in e}p5.exports=P_e});var iG=je((qGa,m5)=>{var x_e=Function.prototype,N_e=x_e.toString;function j_e(e){if(e!=null){try{return N_e.call(e)}catch{}try{return e+""}catch{}}return""}m5.exports=j_e});var D5=je((JGa,h5)=>{var O_e=oG(),U_e=d5(),k_e=rG(),B_e=iG(),H_e=/[\\^$.*+?()[\]{}|]/g,q_e=/^\[object .+?Constructor\]$/,J_e=Function.prototype,W_e=Object.prototype,$_e=J_e.toString,z_e=W_e.hasOwnProperty,V_e=RegExp("^"+$_e.call(z_e).replace(H_e,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Q_e(e){if(!k_e(e)||U_e(e))return!1;var n=O_e(e)?V_e:q_e;return n.test(B_e(e))}h5.exports=Q_e});var R5=je((WGa,g5)=>{function K_e(e,n){return e==null?void 0:e[n]}g5.exports=K_e});var b_=je(($Ga,y5)=>{var Y_e=D5(),X_e=R5();function Z_e(e,n){var a=X_e(e,n);return Y_e(a)?a:void 0}y5.exports=Z_e});var Kw=je((zGa,w5)=>{var e0e=b_(),n0e=Tc(),a0e=e0e(n0e,"Map");w5.exports=a0e});var wh=je((VGa,b5)=>{var t0e=b_(),r0e=t0e(Object,"create");b5.exports=r0e});var T5=je((QGa,I5)=>{var E5=wh();function o0e(){this.__data__=E5?E5(null):{},this.size=0}I5.exports=o0e});var C5=je((KGa,S5)=>{function u0e(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}S5.exports=u0e});var G5=je((YGa,F5)=>{var i0e=wh(),l0e="__lodash_hash_undefined__",c0e=Object.prototype,s0e=c0e.hasOwnProperty;function v0e(e){var n=this.__data__;if(i0e){var a=n[e];return a===l0e?void 0:a}return s0e.call(n,e)?n[e]:void 0}F5.exports=v0e});var A5=je((XGa,M5)=>{var f0e=wh(),_0e=Object.prototype,p0e=_0e.hasOwnProperty;function d0e(e){var n=this.__data__;return f0e?n[e]!==void 0:p0e.call(n,e)}M5.exports=d0e});var P5=je((ZGa,L5)=>{var m0e=wh(),h0e="__lodash_hash_undefined__";function D0e(e,n){var a=this.__data__;return this.size+=this.has(e)?0:1,a[e]=m0e&&n===void 0?h0e:n,this}L5.exports=D0e});var N5=je((eMa,x5)=>{var g0e=T5(),R0e=C5(),y0e=G5(),w0e=A5(),b0e=P5();function Sp(e){var n=-1,a=e==null?0:e.length;for(this.clear();++n{var j5=N5(),E0e=gh(),I0e=Kw();function T0e(){this.size=0,this.__data__={hash:new j5,map:new(I0e||E0e),string:new j5}}O5.exports=T0e});var B5=je((aMa,k5)=>{function S0e(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}k5.exports=S0e});var bh=je((tMa,H5)=>{var C0e=B5();function F0e(e,n){var a=e.__data__;return C0e(n)?a[typeof n=="string"?"string":"hash"]:a.map}H5.exports=F0e});var J5=je((rMa,q5)=>{var G0e=bh();function M0e(e){var n=G0e(this,e).delete(e);return this.size-=n?1:0,n}q5.exports=M0e});var $5=je((oMa,W5)=>{var A0e=bh();function L0e(e){return A0e(this,e).get(e)}W5.exports=L0e});var V5=je((uMa,z5)=>{var P0e=bh();function x0e(e){return P0e(this,e).has(e)}z5.exports=x0e});var K5=je((iMa,Q5)=>{var N0e=bh();function j0e(e,n){var a=N0e(this,e),t=a.size;return a.set(e,n),this.size+=a.size==t?0:1,this}Q5.exports=j0e});var lG=je((lMa,Y5)=>{var O0e=U5(),U0e=J5(),k0e=$5(),B0e=V5(),H0e=K5();function Cp(e){var n=-1,a=e==null?0:e.length;for(this.clear();++n{var q0e=gh(),J0e=Kw(),W0e=lG(),$0e=200;function z0e(e,n){var a=this.__data__;if(a instanceof q0e){var t=a.__data__;if(!J0e||t.length<$0e-1)return t.push([e,n]),this.size=++a.size,this;a=this.__data__=new W0e(t)}return a.set(e,n),this.size=a.size,this}X5.exports=z0e});var n9=je((sMa,e9)=>{var V0e=gh(),Q0e=J6(),K0e=$6(),Y0e=V6(),X0e=K6(),Z0e=Z5();function Fp(e){var n=this.__data__=new V0e(e);this.size=n.size}Fp.prototype.clear=Q0e;Fp.prototype.delete=K0e;Fp.prototype.get=Y0e;Fp.prototype.has=X0e;Fp.prototype.set=Z0e;e9.exports=Fp});var t9=je((vMa,a9)=>{var epe="__lodash_hash_undefined__";function npe(e){return this.__data__.set(e,epe),this}a9.exports=npe});var o9=je((fMa,r9)=>{function ape(e){return this.__data__.has(e)}r9.exports=ape});var i9=je((_Ma,u9)=>{var tpe=lG(),rpe=t9(),ope=o9();function Yw(e){var n=-1,a=e==null?0:e.length;for(this.__data__=new tpe;++n{function upe(e,n){for(var a=-1,t=e==null?0:e.length;++a{function ipe(e,n){return e.has(n)}s9.exports=ipe});var cG=je((mMa,f9)=>{var lpe=i9(),cpe=c9(),spe=v9(),vpe=1,fpe=2;function _pe(e,n,a,t,o,u){var i=a&vpe,l=e.length,s=n.length;if(l!=s&&!(i&&s>l))return!1;var R=u.get(e),d=u.get(n);if(R&&d)return R==n&&d==e;var y=-1,I=!0,b=a&fpe?new lpe:void 0;for(u.set(e,n),u.set(n,e);++y{var ppe=Tc(),dpe=ppe.Uint8Array;_9.exports=dpe});var m9=je((DMa,d9)=>{function mpe(e){var n=-1,a=Array(e.size);return e.forEach(function(t,o){a[++n]=[o,t]}),a}d9.exports=mpe});var D9=je((gMa,h9)=>{function hpe(e){var n=-1,a=Array(e.size);return e.forEach(function(t){a[++n]=t}),a}h9.exports=hpe});var b9=je((RMa,w9)=>{var g9=Qw(),R9=p9(),Dpe=aG(),gpe=cG(),Rpe=m9(),ype=D9(),wpe=1,bpe=2,Epe="[object Boolean]",Ipe="[object Date]",Tpe="[object Error]",Spe="[object Map]",Cpe="[object Number]",Fpe="[object RegExp]",Gpe="[object Set]",Mpe="[object String]",Ape="[object Symbol]",Lpe="[object ArrayBuffer]",Ppe="[object DataView]",y9=g9?g9.prototype:void 0,sG=y9?y9.valueOf:void 0;function xpe(e,n,a,t,o,u,i){switch(a){case Ppe:if(e.byteLength!=n.byteLength||e.byteOffset!=n.byteOffset)return!1;e=e.buffer,n=n.buffer;case Lpe:return!(e.byteLength!=n.byteLength||!u(new R9(e),new R9(n)));case Epe:case Ipe:case Cpe:return Dpe(+e,+n);case Tpe:return e.name==n.name&&e.message==n.message;case Fpe:case Mpe:return e==n+"";case Spe:var l=Rpe;case Gpe:var s=t&wpe;if(l||(l=ype),e.size!=n.size&&!s)return!1;var R=i.get(e);if(R)return R==n;t|=bpe,i.set(e,n);var d=gpe(l(e),l(n),t,o,u,i);return i.delete(e),d;case Ape:if(sG)return sG.call(e)==sG.call(n)}return!1}w9.exports=xpe});var I9=je((yMa,E9)=>{function Npe(e,n){for(var a=-1,t=n.length,o=e.length;++a{var jpe=Array.isArray;T9.exports=jpe});var C9=je((bMa,S9)=>{var Ope=I9(),Upe=Xw();function kpe(e,n,a){var t=n(e);return Upe(e)?t:Ope(t,a(e))}S9.exports=kpe});var G9=je((EMa,F9)=>{function Bpe(e,n){for(var a=-1,t=e==null?0:e.length,o=0,u=[];++a{function Hpe(){return[]}M9.exports=Hpe});var x9=je((TMa,P9)=>{var qpe=G9(),Jpe=A9(),Wpe=Object.prototype,$pe=Wpe.propertyIsEnumerable,L9=Object.getOwnPropertySymbols,zpe=L9?function(e){return e==null?[]:(e=Object(e),qpe(L9(e),function(n){return $pe.call(e,n)}))}:Jpe;P9.exports=zpe});var j9=je((SMa,N9)=>{function Vpe(e,n){for(var a=-1,t=Array(e);++a{function Qpe(e){return e!=null&&typeof e=="object"}O9.exports=Qpe});var k9=je((FMa,U9)=>{var Kpe=yh(),Ype=Eh(),Xpe="[object Arguments]";function Zpe(e){return Ype(e)&&Kpe(e)==Xpe}U9.exports=Zpe});var J9=je((GMa,q9)=>{var B9=k9(),ede=Eh(),H9=Object.prototype,nde=H9.hasOwnProperty,ade=H9.propertyIsEnumerable,tde=B9(function(){return arguments}())?B9:function(e){return ede(e)&&nde.call(e,"callee")&&!ade.call(e,"callee")};q9.exports=tde});var $9=je((MMa,W9)=>{function rde(){return!1}W9.exports=rde});var vG=je((Ih,Gp)=>{var ode=Tc(),ude=$9(),z9=typeof Ih=="object"&&Ih&&!Ih.nodeType&&Ih,V9=z9&&typeof Gp=="object"&&Gp&&!Gp.nodeType&&Gp,ide=V9&&V9.exports===z9,Q9=ide?ode.Buffer:void 0,lde=Q9?Q9.isBuffer:void 0,cde=lde||ude;Gp.exports=cde});var Y9=je((AMa,K9)=>{var sde=9007199254740991,vde=/^(?:0|[1-9]\d*)$/;function fde(e,n){var a=typeof e;return n=n==null?sde:n,!!n&&(a=="number"||a!="symbol"&&vde.test(e))&&e>-1&&e%1==0&&e{var _de=9007199254740991;function pde(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=_de}X9.exports=pde});var ek=je((PMa,Z9)=>{var dde=yh(),mde=fG(),hde=Eh(),Dde="[object Arguments]",gde="[object Array]",Rde="[object Boolean]",yde="[object Date]",wde="[object Error]",bde="[object Function]",Ede="[object Map]",Ide="[object Number]",Tde="[object Object]",Sde="[object RegExp]",Cde="[object Set]",Fde="[object String]",Gde="[object WeakMap]",Mde="[object ArrayBuffer]",Ade="[object DataView]",Lde="[object Float32Array]",Pde="[object Float64Array]",xde="[object Int8Array]",Nde="[object Int16Array]",jde="[object Int32Array]",Ode="[object Uint8Array]",Ude="[object Uint8ClampedArray]",kde="[object Uint16Array]",Bde="[object Uint32Array]",ur={};ur[Lde]=ur[Pde]=ur[xde]=ur[Nde]=ur[jde]=ur[Ode]=ur[Ude]=ur[kde]=ur[Bde]=!0;ur[Dde]=ur[gde]=ur[Mde]=ur[Rde]=ur[Ade]=ur[yde]=ur[wde]=ur[bde]=ur[Ede]=ur[Ide]=ur[Tde]=ur[Sde]=ur[Cde]=ur[Fde]=ur[Gde]=!1;function Hde(e){return hde(e)&&mde(e.length)&&!!ur[dde(e)]}Z9.exports=Hde});var ak=je((xMa,nk)=>{function qde(e){return function(n){return e(n)}}nk.exports=qde});var rk=je((Sh,Mp)=>{var Jde=tG(),tk=typeof Sh=="object"&&Sh&&!Sh.nodeType&&Sh,Th=tk&&typeof Mp=="object"&&Mp&&!Mp.nodeType&&Mp,Wde=Th&&Th.exports===tk,_G=Wde&&Jde.process,$de=function(){try{var e=Th&&Th.require&&Th.require("util").types;return e||_G&&_G.binding&&_G.binding("util")}catch{}}();Mp.exports=$de});var pG=je((NMa,ik)=>{var zde=ek(),Vde=ak(),ok=rk(),uk=ok&&ok.isTypedArray,Qde=uk?Vde(uk):zde;ik.exports=Qde});var ck=je((jMa,lk)=>{var Kde=j9(),Yde=J9(),Xde=Xw(),Zde=vG(),eme=Y9(),nme=pG(),ame=Object.prototype,tme=ame.hasOwnProperty;function rme(e,n){var a=Xde(e),t=!a&&Yde(e),o=!a&&!t&&Zde(e),u=!a&&!t&&!o&&nme(e),i=a||t||o||u,l=i?Kde(e.length,String):[],s=l.length;for(var R in e)(n||tme.call(e,R))&&!(i&&(R=="length"||o&&(R=="offset"||R=="parent")||u&&(R=="buffer"||R=="byteLength"||R=="byteOffset")||eme(R,s)))&&l.push(R);return l}lk.exports=rme});var vk=je((OMa,sk)=>{var ome=Object.prototype;function ume(e){var n=e&&e.constructor,a=typeof n=="function"&&n.prototype||ome;return e===a}sk.exports=ume});var _k=je((UMa,fk)=>{function ime(e,n){return function(a){return e(n(a))}}fk.exports=ime});var dk=je((kMa,pk)=>{var lme=_k(),cme=lme(Object.keys,Object);pk.exports=cme});var hk=je((BMa,mk)=>{var sme=vk(),vme=dk(),fme=Object.prototype,_me=fme.hasOwnProperty;function pme(e){if(!sme(e))return vme(e);var n=[];for(var a in Object(e))_me.call(e,a)&&a!="constructor"&&n.push(a);return n}mk.exports=pme});var gk=je((HMa,Dk)=>{var dme=oG(),mme=fG();function hme(e){return e!=null&&mme(e.length)&&!dme(e)}Dk.exports=hme});var yk=je((qMa,Rk)=>{var Dme=ck(),gme=hk(),Rme=gk();function yme(e){return Rme(e)?Dme(e):gme(e)}Rk.exports=yme});var bk=je((JMa,wk)=>{var wme=C9(),bme=x9(),Eme=yk();function Ime(e){return wme(e,Eme,bme)}wk.exports=Ime});var Tk=je((WMa,Ik)=>{var Ek=bk(),Tme=1,Sme=Object.prototype,Cme=Sme.hasOwnProperty;function Fme(e,n,a,t,o,u){var i=a&Tme,l=Ek(e),s=l.length,R=Ek(n),d=R.length;if(s!=d&&!i)return!1;for(var y=s;y--;){var I=l[y];if(!(i?I in n:Cme.call(n,I)))return!1}var b=u.get(e),S=u.get(n);if(b&&S)return b==n&&S==e;var L=!0;u.set(e,n),u.set(n,e);for(var O=i;++y{var Gme=b_(),Mme=Tc(),Ame=Gme(Mme,"DataView");Sk.exports=Ame});var Gk=je((zMa,Fk)=>{var Lme=b_(),Pme=Tc(),xme=Lme(Pme,"Promise");Fk.exports=xme});var Ak=je((VMa,Mk)=>{var Nme=b_(),jme=Tc(),Ome=Nme(jme,"Set");Mk.exports=Ome});var Pk=je((QMa,Lk)=>{var Ume=b_(),kme=Tc(),Bme=Ume(kme,"WeakMap");Lk.exports=Bme});var Hk=je((KMa,Bk)=>{var dG=Ck(),mG=Kw(),hG=Gk(),DG=Ak(),gG=Pk(),xk=yh(),Ap=iG(),Nk="[object Map]",Hme="[object Object]",jk="[object Promise]",Ok="[object Set]",Uk="[object WeakMap]",kk="[object DataView]",qme=Ap(dG),Jme=Ap(mG),Wme=Ap(hG),$me=Ap(DG),zme=Ap(gG),E_=xk;(dG&&E_(new dG(new ArrayBuffer(1)))!=kk||mG&&E_(new mG)!=Nk||hG&&E_(hG.resolve())!=jk||DG&&E_(new DG)!=Ok||gG&&E_(new gG)!=Uk)&&(E_=function(e){var n=xk(e),a=n==Hme?e.constructor:void 0,t=a?Ap(a):"";if(t)switch(t){case qme:return kk;case Jme:return Nk;case Wme:return jk;case $me:return Ok;case zme:return Uk}return n});Bk.exports=E_});var Kk=je((YMa,Qk)=>{var RG=n9(),Vme=cG(),Qme=b9(),Kme=Tk(),qk=Hk(),Jk=Xw(),Wk=vG(),Yme=pG(),Xme=1,$k="[object Arguments]",zk="[object Array]",Zw="[object Object]",Zme=Object.prototype,Vk=Zme.hasOwnProperty;function ehe(e,n,a,t,o,u){var i=Jk(e),l=Jk(n),s=i?zk:qk(e),R=l?zk:qk(n);s=s==$k?Zw:s,R=R==$k?Zw:R;var d=s==Zw,y=R==Zw,I=s==R;if(I&&Wk(e)){if(!Wk(n))return!1;i=!0,d=!1}if(I&&!d)return u||(u=new RG),i||Yme(e)?Vme(e,n,a,t,o,u):Qme(e,n,s,a,t,o,u);if(!(a&Xme)){var b=d&&Vk.call(e,"__wrapped__"),S=y&&Vk.call(n,"__wrapped__");if(b||S){var L=b?e.value():e,O=S?n.value():n;return u||(u=new RG),o(L,O,a,t,u)}}return I?(u||(u=new RG),Kme(e,n,a,t,o,u)):!1}Qk.exports=ehe});var eB=je((XMa,Zk)=>{var nhe=Kk(),Yk=Eh();function Xk(e,n,a,t,o){return e===n?!0:e==null||n==null||!Yk(e)&&!Yk(n)?e!==e&&n!==n:nhe(e,n,a,t,Xk,o)}Zk.exports=Xk});var aB=je((ZMa,nB)=>{var ahe=eB();function the(e,n){return ahe(e,n)}nB.exports=the});var jB=je(($La,Mhe)=>{Mhe.exports=`.rc-tooltip.rc-tooltip-zoom-appear, .rc-tooltip.rc-tooltip-zoom-enter { opacity: 0; } .rc-tooltip.rc-tooltip-zoom-enter, .rc-tooltip.rc-tooltip-zoom-leave { display: block; } .rc-tooltip-zoom-enter, .rc-tooltip-zoom-appear { opacity: 0; animation-duration: 0.3s; animation-fill-mode: both; animation-timing-function: cubic-bezier(0.18, 0.89, 0.32, 1.28); animation-play-state: paused; } .rc-tooltip-zoom-leave { animation-duration: 0.3s; animation-fill-mode: both; animation-timing-function: cubic-bezier(0.6, -0.3, 0.74, 0.05); animation-play-state: paused; } .rc-tooltip-zoom-enter.rc-tooltip-zoom-enter-active, .rc-tooltip-zoom-appear.rc-tooltip-zoom-appear-active { animation-name: rcToolTipZoomIn; animation-play-state: running; } .rc-tooltip-zoom-leave.rc-tooltip-zoom-leave-active { animation-name: rcToolTipZoomOut; animation-play-state: running; } @keyframes rcToolTipZoomIn { 0% { opacity: 0; transform-origin: 50% 50%; transform: scale(0, 0); } 100% { opacity: 1; transform-origin: 50% 50%; transform: scale(1, 1); } } @keyframes rcToolTipZoomOut { 0% { opacity: 1; transform-origin: 50% 50%; transform: scale(1, 1); } 100% { opacity: 0; transform-origin: 50% 50%; transform: scale(0, 0); } } .rc-tooltip { position: absolute; z-index: 1070; display: block; visibility: visible; line-height: 1.5; font-size: 12px; background-color: rgba(0, 0, 0, 0.05); padding: 1px; opacity: 0.9; } .rc-tooltip-hidden { display: none; } .rc-tooltip-inner { padding: 8px 10px; color: #333333; text-align: left; text-decoration: none; background-color: #ffffff; border-radius: 3px; min-height: 34px; border: 1px solid #b1b1b1; } .rc-tooltip-arrow, .rc-tooltip-arrow-inner { position: absolute; width: 0; height: 0; border-color: transparent; border-style: solid; } .rc-tooltip-placement-top .rc-tooltip-arrow, .rc-tooltip-placement-topLeft .rc-tooltip-arrow, .rc-tooltip-placement-topRight .rc-tooltip-arrow { bottom: -5px; margin-left: -6px; border-width: 6px 6px 0; border-top-color: #b1b1b1; } .rc-tooltip-placement-top .rc-tooltip-arrow-inner, .rc-tooltip-placement-topLeft .rc-tooltip-arrow-inner, .rc-tooltip-placement-topRight .rc-tooltip-arrow-inner { bottom: 1px; margin-left: -6px; border-width: 6px 6px 0; border-top-color: #ffffff; } .rc-tooltip-placement-top .rc-tooltip-arrow { left: 50%; } .rc-tooltip-placement-topLeft .rc-tooltip-arrow { left: 15%; } .rc-tooltip-placement-topRight .rc-tooltip-arrow { right: 15%; } .rc-tooltip-placement-right .rc-tooltip-arrow, .rc-tooltip-placement-rightTop .rc-tooltip-arrow, .rc-tooltip-placement-rightBottom .rc-tooltip-arrow { left: -5px; margin-top: -6px; border-width: 6px 6px 6px 0; border-right-color: #b1b1b1; } .rc-tooltip-placement-right .rc-tooltip-arrow-inner, .rc-tooltip-placement-rightTop .rc-tooltip-arrow-inner, .rc-tooltip-placement-rightBottom .rc-tooltip-arrow-inner { left: 1px; margin-top: -6px; border-width: 6px 6px 6px 0; border-right-color: #ffffff; } .rc-tooltip-placement-right .rc-tooltip-arrow { top: 50%; } .rc-tooltip-placement-rightTop .rc-tooltip-arrow { top: 15%; margin-top: 0; } .rc-tooltip-placement-rightBottom .rc-tooltip-arrow { bottom: 15%; } .rc-tooltip-placement-left .rc-tooltip-arrow, .rc-tooltip-placement-leftTop .rc-tooltip-arrow, .rc-tooltip-placement-leftBottom .rc-tooltip-arrow { right: -5px; margin-top: -6px; border-width: 6px 0 6px 6px; border-left-color: #b1b1b1; } .rc-tooltip-placement-left .rc-tooltip-arrow-inner, .rc-tooltip-placement-leftTop .rc-tooltip-arrow-inner, .rc-tooltip-placement-leftBottom .rc-tooltip-arrow-inner { right: 1px; margin-top: -6px; border-width: 6px 0 6px 6px; border-left-color: #ffffff; } .rc-tooltip-placement-left .rc-tooltip-arrow { top: 50%; } .rc-tooltip-placement-leftTop .rc-tooltip-arrow { top: 15%; margin-top: 0; } .rc-tooltip-placement-leftBottom .rc-tooltip-arrow { bottom: 15%; } .rc-tooltip-placement-bottom .rc-tooltip-arrow, .rc-tooltip-placement-bottomLeft .rc-tooltip-arrow, .rc-tooltip-placement-bottomRight .rc-tooltip-arrow { top: -5px; margin-left: -6px; border-width: 0 6px 6px; border-bottom-color: #b1b1b1; } .rc-tooltip-placement-bottom .rc-tooltip-arrow-inner, .rc-tooltip-placement-bottomLeft .rc-tooltip-arrow-inner, .rc-tooltip-placement-bottomRight .rc-tooltip-arrow-inner { top: 1px; margin-left: -6px; border-width: 0 6px 6px; border-bottom-color: #ffffff; } .rc-tooltip-placement-bottom .rc-tooltip-arrow { left: 50%; } .rc-tooltip-placement-bottomLeft .rc-tooltip-arrow { left: 15%; } .rc-tooltip-placement-bottomRight .rc-tooltip-arrow { right: 15%; } `});var gz=je((mD,mA)=>{typeof window!="undefined"&&function(n,a){typeof mD=="object"&&typeof mA=="object"?mA.exports=a():typeof define=="function"&&define.amd?define([],a):typeof mD=="object"?mD.Hls=a():n.Hls=a()}(mD,function(){return function(e){var n={};function a(t){if(n[t])return n[t].exports;var o=n[t]={i:t,l:!1,exports:{}};return e[t].call(o.exports,o,o.exports,a),o.l=!0,o.exports}return a.m=e,a.c=n,a.d=function(t,o,u){a.o(t,o)||Object.defineProperty(t,o,{enumerable:!0,get:u})},a.r=function(t){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.t=function(t,o){if(o&1&&(t=a(t)),o&8||o&4&&typeof t=="object"&&t&&t.__esModule)return t;var u=Object.create(null);if(a.r(u),Object.defineProperty(u,"default",{enumerable:!0,value:t}),o&2&&typeof t!="string")for(var i in t)a.d(u,i,function(l){return t[l]}.bind(null,i));return u},a.n=function(t){var o=t&&t.__esModule?function(){return t.default}:function(){return t};return a.d(o,"a",o),o},a.o=function(t,o){return Object.prototype.hasOwnProperty.call(t,o)},a.p="/dist/",a(a.s="./src/hls.ts")}({"./node_modules/eventemitter3/index.js":function(e,n,a){"use strict";var t=Object.prototype.hasOwnProperty,o="~";function u(){}Object.create&&(u.prototype=Object.create(null),new u().__proto__||(o=!1));function i(d,y,I){this.fn=d,this.context=y,this.once=I||!1}function l(d,y,I,b,S){if(typeof I!="function")throw new TypeError("The listener must be a function");var L=new i(I,b||d,S),O=o?o+y:y;return d._events[O]?d._events[O].fn?d._events[O]=[d._events[O],L]:d._events[O].push(L):(d._events[O]=L,d._eventsCount++),d}function s(d,y){--d._eventsCount==0?d._events=new u:delete d._events[y]}function R(){this._events=new u,this._eventsCount=0}R.prototype.eventNames=function(){var y=[],I,b;if(this._eventsCount===0)return y;for(b in I=this._events)t.call(I,b)&&y.push(o?b.slice(1):b);return Object.getOwnPropertySymbols?y.concat(Object.getOwnPropertySymbols(I)):y},R.prototype.listeners=function(y){var I=o?o+y:y,b=this._events[I];if(!b)return[];if(b.fn)return[b.fn];for(var S=0,L=b.length,O=new Array(L);S0},!1)}function d(y,I){for(var b={main:[I]},S={main:[]},L={main:{}};R(b);)for(var O=Object.keys(b),$=0;$>>8^Hn&255^99,ee[Sn]=Hn,oe[Hn]=Sn;var Kn=Xe[Sn],qn=Xe[Kn],ft=Xe[qn],Oe=Xe[Hn]*257^Hn*16843008;ve[Sn]=Oe<<24|Oe>>>8,Re[Sn]=Oe<<16|Oe>>>16,nn[Sn]=Oe<<8|Oe>>>24,cn[Sn]=Oe,Oe=ft*16843009^qn*65537^Kn*257^Sn*16843008,le[Hn]=Oe<<24|Oe>>>8,Ne[Hn]=Oe<<16|Oe>>>16,Ce[Hn]=Oe<<8|Oe>>>24,Be[Hn]=Oe,Sn?(Sn=Kn^Xe[Xe[Xe[ft^Kn]]],ra^=Xe[Xe[ra]]):Sn=ra=1}},$.expandKey=function(ee){for(var oe=this.uint8ArrayToUint32Array_(ee),te=!0,ve=0;ve>>6)+1,N=(K[j+2]&60)>>>2,N>Ie.length-1){q.trigger(t.default.ERROR,{type:o.ErrorTypes.MEDIA_ERROR,details:o.ErrorDetails.FRAG_PARSING_ERROR,fatal:!0,reason:"invalid ADTS sampling index:"+N});return}return V=(K[j+2]&1)<<2,V|=(K[j+3]&192)>>>6,l.logger.log("manifest codec:"+E+",ADTS data:type:"+P+",sampleingIndex:"+N+"["+Ie[N]+"Hz],channelConfig:"+V),/firefox/i.test(re)?N>=6?(P=5,ue=new Array(4),J=N-3):(P=2,ue=new Array(2),J=N):re.indexOf("android")!==-1?(P=2,ue=new Array(2),J=N):(P=5,ue=new Array(4),E&&(E.indexOf("mp4a.40.29")!==-1||E.indexOf("mp4a.40.5")!==-1)||!E&&N>=6?J=N-3:((E&&E.indexOf("mp4a.40.2")!==-1&&(N>=6&&V===1||/vivaldi/i.test(re))||!E&&V===1)&&(P=2,ue=new Array(2)),J=N)),ue[0]=P<<3,ue[0]|=(N&14)>>1,ue[1]|=(N&1)<<7,ue[1]|=V<<3,P===5&&(ue[1]|=(J&14)>>1,ue[2]=(J&1)<<7,ue[2]|=2<<2,ue[3]=0),{config:ue,samplerate:Ie[N],channelCount:V,codec:"mp4a.40."+P,manifestCodec:he}}function d(q,K){return q[K]===255&&(q[K+1]&246)==240}function y(q,K){return q[K+1]&1?7:9}function I(q,K){return(q[K+3]&3)<<11|q[K+4]<<3|(q[K+5]&224)>>>5}function b(q,K){return!!(K+10&&K+N+J<=ue)return V=j+E*P,{headerLength:N,frameLength:J,stamp:V}}function z(q,K,j,E,P){var N=O(q.samplerate),J=$(K,j,E,P,N);if(J){var V=J.stamp,ue=J.headerLength,re=J.frameLength,he={unit:K.subarray(j+ue,j+ue+re),pts:V,dts:V};return q.samples.push(he),{sample:he,length:re+ue}}}var ee=a("./src/demux/id3.js"),oe=function(){function q(j,E,P){this.observer=j,this.config=P,this.remuxer=E}var K=q.prototype;return K.resetInitSegment=function(E,P,N,J){this._audioTrack={container:"audio/adts",type:"audio",id:0,sequenceNumber:0,isAAC:!0,samples:[],len:0,manifestCodec:P,duration:J,inputTimeScale:9e4}},K.resetTimeStamp=function(){},q.probe=function(E){if(!E)return!1;for(var P=ee.default.getID3Data(E,0)||[],N=P.length,J=E.length;Nj.length)){var J=this.parseHeader(j,E);if(J&&E+J.frameLength<=j.length){var V=J.samplesPerFrame*9e4/J.sampleRate,ue=P+N*V,re={unit:j.subarray(E,E+J.frameLength),pts:ue,dts:ue};return K.config=[],K.channelCount=J.channelCount,K.samplerate=J.sampleRate,K.samples.push(re),{sample:re,length:J.frameLength}}}},parseHeader:function(K,j){var E=K[j+1]>>3&3,P=K[j+1]>>1&3,N=K[j+2]>>4&15,J=K[j+2]>>2&3,V=K[j+2]>>1&1;if(E!==1&&N!==0&&N!==15&&J!==3){var ue=E===3?3-P:P===3?3:4,re=Re.BitratesMap[ue*14+N-1]*1e3,he=E===3?0:E===2?1:2,Ie=Re.SamplingRateMap[he*3+J],Fe=K[j+3]>>6==3?1:2,Ge=Re.SamplesCoefficients[E][P],ln=Re.BytesInSlot[P],mn=Ge*8*ln,Pe=parseInt(Ge*re/Ie+V,10)*ln;return{sampleRate:Ie,channelCount:Fe,frameLength:Pe,samplesPerFrame:mn}}},isHeaderPattern:function(K,j){return K[j]===255&&(K[j+1]&224)==224&&(K[j+1]&6)!=0},isHeader:function(K,j){return!!(j+1E?(this.word<<=E,this.bitsAvailable-=E):(E-=this.bitsAvailable,P=E>>3,E-=P>>3,this.bytesAvailable-=P,this.loadWord(),this.word<<=E,this.bitsAvailable-=E)},K.readBits=function(E){var P=Math.min(this.bitsAvailable,E),N=this.word>>>32-P;return E>32&&l.logger.error("Cannot read more than 32 bits at a time"),this.bitsAvailable-=P,this.bitsAvailable>0?this.word<<=P:this.bytesAvailable>0&&this.loadWord(),P=E-P,P>0&&this.bitsAvailable?N<>>E)!=0)return this.word<<=E,this.bitsAvailable-=E,E;return this.loadWord(),E+this.skipLZ()},K.skipUEG=function(){this.skipBits(1+this.skipLZ())},K.skipEG=function(){this.skipBits(1+this.skipLZ())},K.readUEG=function(){var E=this.skipLZ();return this.readBits(E+1)-1},K.readEG=function(){var E=this.readUEG();return 1&E?1+E>>>1:-1*(E>>>1)},K.readBoolean=function(){return this.readBits(1)===1},K.readUByte=function(){return this.readBits(8)},K.readUShort=function(){return this.readBits(16)},K.readUInt=function(){return this.readBits(32)},K.skipScalingList=function(E){var P=8,N=8,J,V;for(J=0;J=E.length){N();return}if(!(E[P].unit.length<32)){var J=this.decrypter.isSync();if(this.decryptAacSample(E,P,N,J),!J)return}}},K.getAvcEncryptedData=function(E){for(var P=Math.floor((E.length-48)/160)*16+16,N=new Int8Array(P),J=0,V=32;V<=E.length-16;V+=160,J+=16)N.set(E.subarray(V,V+16),J);return N},K.getAvcDecryptedUnit=function(E,P){P=new Uint8Array(P);for(var N=0,J=32;J<=E.length-16;J+=160,N+=16)E.set(P.subarray(N,N+16),J);return E},K.decryptAvcSample=function(E,P,N,J,V,ue){var re=this.discardEPB(V.data),he=this.getAvcEncryptedData(re),Ie=this;this.decryptBuffer(he.buffer,function(Fe){V.data=Ie.getAvcDecryptedUnit(re,Fe),ue||Ie.decryptAvcSamples(E,P,N+1,J)})},K.decryptAvcSamples=function(E,P,N,J){for(;;P++,N=0){if(P>=E.length){J();return}for(var V=E[P].units;!(N>=V.length);N++){var ue=V[N];if(!(ue.length<=48||ue.type!==1&&ue.type!==5)){var re=this.decrypter.isSync();if(this.decryptAvcSample(E,P,N,J,ue,re),!re)return}}}},q}(),Ne=le,Ce={video:1,audio:2,id3:3,text:4},Be=function(){function q(j,E,P,N){this.observer=j,this.config=P,this.typeSupported=N,this.remuxer=E,this.sampleAes=null}var K=q.prototype;return K.setDecryptData=function(E){E!=null&&E.key!=null&&E.method==="SAMPLE-AES"?this.sampleAes=new Ne(this.observer,this.config,E,this.discardEPB):this.sampleAes=null},q.probe=function(E){var P=q._syncOffset(E);return P<0?!1:(P&&l.logger.warn("MPEG2-TS detected but first sync word found @ offset "+P+", junk ahead ?"),!0)},q._syncOffset=function(E){for(var P=Math.min(1e3,E.length-3*188),N=0;N>4,Ie>1){if(Fe=V+5+E[V+4],Fe===V+188)continue}else Fe=V+4;switch(he){case pa:re&&(pt&&(Ge=ir(pt))&&Cr(Ge,!1),pt={data:[],size:0}),pt&&(pt.data.push(E.subarray(Fe,V+188)),pt.size+=V+188-Fe);break;case Za:re&&(Pa&&(Ge=ir(Pa))&&(Rn.isAAC?ro(Ge):mr(Ge)),Pa={data:[],size:0}),Pa&&(Pa.data.push(E.subarray(Fe,V+188)),Pa.size+=V+188-Fe);break;case Lt:re&&(Ot&&(Ge=ir(Ot))&&No(Ge),Ot={data:[],size:0}),Ot&&(Ot.data.push(E.subarray(Fe,V+188)),Ot.size+=V+188-Fe);break;case 0:re&&(Fe+=E[Fe]+1),wa=this._pmtId=Ba(E,Fe);break;case wa:re&&(Fe+=E[Fe]+1);var Zt=Et(E,Fe,this.typeSupported.mpeg===!0||this.typeSupported.mp3===!0,this.sampleAes!=null);pa=Zt.avc,pa>0&&(Pe.pid=pa),Za=Zt.audio,Za>0&&(Rn.pid=Za,Rn.isAAC=Zt.isAAC),Lt=Zt.id3,Lt>0&&(Vn.pid=Lt),ln&&!mn&&(l.logger.log("reparse from beginning"),ln=!1,V=Fr-188),mn=this.pmtParsed=!0;break;case 17:case 8191:break;default:ln=!0;break}}else this.observer.trigger(t.default.ERROR,{type:o.ErrorTypes.MEDIA_ERROR,details:o.ErrorDetails.FRAG_PARSING_ERROR,fatal:!1,reason:"TS packet did not start with 0x47"});pt&&(Ge=ir(pt))?(Cr(Ge,!0),Pe.pesData=null):Pe.pesData=pt,Pa&&(Ge=ir(Pa))?(Rn.isAAC?ro(Ge):mr(Ge),Rn.pesData=null):(Pa&&Pa.size&&l.logger.log("last AAC PES packet truncated,might overlap between fragments"),Rn.pesData=Pa),Ot&&(Ge=ir(Ot))?(No(Ge),Vn.pesData=null):Vn.pesData=Ot,this.sampleAes==null?this.remuxer.remux(Rn,Pe,Vn,this._txtTrack,P,N,J):this.decryptAndRemux(Rn,Pe,Vn,this._txtTrack,P,N,J)},K.decryptAndRemux=function(E,P,N,J,V,ue,re){if(E.samples&&E.isAAC){var he=this;this.sampleAes.decryptAacSamples(E.samples,0,function(){he.decryptAndRemuxAvc(E,P,N,J,V,ue,re)})}else this.decryptAndRemuxAvc(E,P,N,J,V,ue,re)},K.decryptAndRemuxAvc=function(E,P,N,J,V,ue,re){if(P.samples){var he=this;this.sampleAes.decryptAvcSamples(P.samples,0,0,function(){he.remuxer.remux(E,P,N,J,V,ue,re)})}else this.remuxer.remux(E,P,N,J,V,ue,re)},K.destroy=function(){this._initPTS=this._initDTS=void 0,this._duration=0},K._parsePAT=function(E,P){return(E[P+10]&31)<<8|E[P+11]},K._parsePMT=function(E,P,N,J){var V,ue,re,he,Ie={audio:-1,avc:-1,id3:-1,isAAC:!0};for(V=(E[P+1]&15)<<8|E[P+2],ue=P+3+V-4,re=(E[P+10]&15)<<8|E[P+11],P+=12+re;P1;){var mn=new Uint8Array(ln[0].length+ln[1].length);mn.set(ln[0]),mn.set(ln[1],ln[0].length),ln[0]=mn,ln.splice(1,1)}if(N=ln[0],V=(N[0]<<16)+(N[1]<<8)+N[2],V===1){if(ue=(N[4]<<8)+N[5],ue&&ue>E.size-6||(J=N[7],J&192&&(Ie=(N[9]&14)*536870912+(N[10]&255)*4194304+(N[11]&254)*16384+(N[12]&255)*128+(N[13]&254)/2,Ie>4294967295&&(Ie-=8589934592),J&64?(Fe=(N[14]&14)*536870912+(N[15]&255)*4194304+(N[16]&254)*16384+(N[17]&255)*128+(N[18]&254)/2,Fe>4294967295&&(Fe-=8589934592),Ie-Fe>60*9e4&&(l.logger.warn(Math.round((Ie-Fe)/9e4)+"s delta between PTS and DTS, align them"),Ie=Fe)):Fe=Ie),re=N[8],Ge=re+9,E.size<=Ge))return null;E.size-=Ge,he=new Uint8Array(E.size);for(var Pe=0,Rn=ln.length;PeVn){Ge-=Vn;continue}else N=N.subarray(Ge),Vn-=Ge,Ge=0;he.set(N,P),P+=Vn}return ue&&(ue-=re+3),{data:he,pts:Ie,dts:Fe,len:ue}}else return null},K.pushAccesUnit=function(E,P){if(E.units.length&&E.frame){var N=P.samples,J=N.length;if(isNaN(E.pts))if(J){var V=N[J-1];E.pts=V.pts,E.dts=V.dts}else{P.dropped++;return}!this.config.forceKeyFrameOnDiscontinuity||E.key===!0||P.sps&&(J||this.contiguous)?(E.id=J,N.push(E)):P.dropped++}E.debug.length&&l.logger.log(E.pts+"/"+E.dts+":"+E.debug)},K._parseAVCPES=function(E,P){var N=this,J=this._avcTrack,V=this._parseAVCNALu(E.data),ue=!1,re,he=this.avcSample,Ie,Fe=!1,Ge,ln=this.pushAccesUnit.bind(this),mn=function(Rn,Vn,pa,Za){return{key:Rn,pts:Vn,dts:pa,units:[],debug:Za}};E.data=null,he&&V.length&&!J.audFound&&(ln(he,J),he=this.avcSample=mn(!1,E.pts,E.dts,"")),V.forEach(function(Pe){switch(Pe.type){case 1:Ie=!0,he||(he=N.avcSample=mn(!0,E.pts,E.dts,"")),ue&&(he.debug+="NDR "),he.frame=!0;var Rn=Pe.data;if(Fe&&Rn.length>4){var Vn=new ce(Rn).readSliceType();(Vn===2||Vn===4||Vn===7||Vn===9)&&(he.key=!0)}break;case 5:Ie=!0,he||(he=N.avcSample=mn(!0,E.pts,E.dts,"")),ue&&(he.debug+="IDR "),he.key=!0,he.frame=!0;break;case 6:Ie=!0,ue&&he&&(he.debug+="SEI "),re=new ce(N.discardEPB(Pe.data)),re.readUByte();for(var pa=0,Za=0,Lt=!1,wa=0;!Lt&&re.bytesAvailable>1;){pa=0;do wa=re.readUByte(),pa+=wa;while(wa===255);Za=0;do wa=re.readUByte(),Za+=wa;while(wa===255);if(pa===4&&re.bytesAvailable!==0){Lt=!0;var pt=re.readUByte();if(pt===181){var Pa=re.readUShort();if(Pa===49){var Ot=re.readUInt();if(Ot===1195456820){var Ba=re.readUByte();if(Ba===3){var Et=re.readUByte(),ir=re.readUByte(),Cr=31&Et,ro=[Et,ir];for(Ge=0;Ge16){var mr=[];for(Ge=0;Ge<16;Ge++)mr.push(re.readUByte().toString(16)),(Ge===3||Ge===5||Ge===7||Ge===9)&&mr.push("-");var No=Za-16,Fr=new Uint8Array(No);for(Ge=0;Ge0){if(P.pts>=E[N-1].pts)E.push(P);else for(var J=N-1;J>=0;J--)if(P.pts=0)Fe={data:E.subarray(ln,P-re-1),type:mn},Ie.push(Fe);else{var Pe=this._getLastNalUnit();if(Pe&&(he&&P<=4-he&&Pe.state&&(Pe.data=Pe.data.subarray(0,Pe.data.byteLength-he)),V=P-re-1,V>0)){var Rn=new Uint8Array(Pe.data.byteLength+V);Rn.set(Pe.data,0),Rn.set(E.subarray(0,V),Pe.data.byteLength),Pe.data=Rn}}P=0&&re>=0&&(Fe={data:E.subarray(ln,N),type:mn,state:re},Ie.push(Fe)),Ie.length===0){var Vn=this._getLastNalUnit();if(Vn){var pa=new Uint8Array(Vn.data.byteLength+E.byteLength);pa.set(Vn.data,0),pa.set(E,Vn.data.byteLength),Vn.data=pa}}return ue.naluState=re,Ie},K.discardEPB=function(E){for(var P=E.byteLength,N=[],J=1,V,ue;J1&&(l.logger.log("AAC: align PTS for overlapping frames by "+Math.round((Vn-J)/90)),J=Vn)}for(;Fe>24&255,V[1]=P>>16&255,V[2]=P>>8&255,V[3]=P&255,V.set(j,4),N=0,P=8;N>24&255,j>>16&255,j>>8&255,j&255,P>>24,P>>16&255,P>>8&255,P&255,N>>24,N>>16&255,N>>8&255,N&255,85,196,0,0]))},q.mdia=function(j){return q.box(q.types.mdia,q.mdhd(j.timescale,j.duration),q.hdlr(j.type),q.minf(j))},q.mfhd=function(j){return q.box(q.types.mfhd,new Uint8Array([0,0,0,0,j>>24,j>>16&255,j>>8&255,j&255]))},q.minf=function(j){return j.type==="audio"?q.box(q.types.minf,q.box(q.types.smhd,q.SMHD),q.DINF,q.stbl(j)):q.box(q.types.minf,q.box(q.types.vmhd,q.VMHD),q.DINF,q.stbl(j))},q.moof=function(j,E,P){return q.box(q.types.moof,q.mfhd(j),q.traf(P,E))},q.moov=function(j){for(var E=j.length,P=[];E--;)P[E]=q.trak(j[E]);return q.box.apply(null,[q.types.moov,q.mvhd(j[0].timescale,j[0].duration)].concat(P).concat(q.mvex(j)))},q.mvex=function(j){for(var E=j.length,P=[];E--;)P[E]=q.trex(j[E]);return q.box.apply(null,[q.types.mvex].concat(P))},q.mvhd=function(j,E){E*=j;var P=Math.floor(E/(Kn+1)),N=Math.floor(E%(Kn+1)),J=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,j>>24&255,j>>16&255,j>>8&255,j&255,P>>24,P>>16&255,P>>8&255,P&255,N>>24,N>>16&255,N>>8&255,N&255,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 q.box(q.types.mvhd,J)},q.sdtp=function(j){var E=j.samples||[],P=new Uint8Array(4+E.length),N,J;for(J=0;J>>8&255),E.push(V&255),E=E.concat(Array.prototype.slice.call(J));for(N=0;N>>8&255),P.push(V&255),P=P.concat(Array.prototype.slice.call(J));var ue=q.box(q.types.avcC,new Uint8Array([1,E[3],E[4],E[5],252|3,224|j.sps.length].concat(E).concat([j.pps.length]).concat(P))),re=j.width,he=j.height,Ie=j.pixelRatio[0],Fe=j.pixelRatio[1];return q.box(q.types.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,re>>8&255,re&255,he>>8&255,he&255,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),ue,q.box(q.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),q.box(q.types.pasp,new Uint8Array([Ie>>24,Ie>>16&255,Ie>>8&255,Ie&255,Fe>>24,Fe>>16&255,Fe>>8&255,Fe&255])))},q.esds=function(j){var E=j.config.length;return new Uint8Array([0,0,0,0,3,23+E,0,1,0,4,15+E,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([E]).concat(j.config).concat([6,1,2]))},q.mp4a=function(j){var E=j.samplerate;return q.box(q.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,j.channelCount,0,16,0,0,0,0,E>>8&255,E&255,0,0]),q.box(q.types.esds,q.esds(j)))},q.mp3=function(j){var E=j.samplerate;return q.box(q.types[".mp3"],new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,j.channelCount,0,16,0,0,0,0,E>>8&255,E&255,0,0]))},q.stsd=function(j){return j.type==="audio"?!j.isAAC&&j.codec==="mp3"?q.box(q.types.stsd,q.STSD,q.mp3(j)):q.box(q.types.stsd,q.STSD,q.mp4a(j)):q.box(q.types.stsd,q.STSD,q.avc1(j))},q.tkhd=function(j){var E=j.id,P=j.duration*j.timescale,N=j.width,J=j.height,V=Math.floor(P/(Kn+1)),ue=Math.floor(P%(Kn+1));return q.box(q.types.tkhd,new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,E>>24&255,E>>16&255,E>>8&255,E&255,0,0,0,0,V>>24,V>>16&255,V>>8&255,V&255,ue>>24,ue>>16&255,ue>>8&255,ue&255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,N>>8&255,N&255,0,0,J>>8&255,J&255,0,0]))},q.traf=function(j,E){var P=q.sdtp(j),N=j.id,J=Math.floor(E/(Kn+1)),V=Math.floor(E%(Kn+1));return q.box(q.types.traf,q.box(q.types.tfhd,new Uint8Array([0,0,0,0,N>>24,N>>16&255,N>>8&255,N&255])),q.box(q.types.tfdt,new Uint8Array([1,0,0,0,J>>24,J>>16&255,J>>8&255,J&255,V>>24,V>>16&255,V>>8&255,V&255])),q.trun(j,P.length+16+20+8+16+8+8),P)},q.trak=function(j){return j.duration=j.duration||4294967295,q.box(q.types.trak,q.tkhd(j),q.mdia(j))},q.trex=function(j){var E=j.id;return q.box(q.types.trex,new Uint8Array([0,0,0,0,E>>24,E>>16&255,E>>8&255,E&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))},q.trun=function(j,E){var P=j.samples||[],N=P.length,J=12+16*N,V=new Uint8Array(J),ue,re,he,Ie,Fe,Ge;for(E+=8+J,V.set([0,0,15,1,N>>>24&255,N>>>16&255,N>>>8&255,N&255,E>>>24&255,E>>>16&255,E>>>8&255,E&255],0),ue=0;ue>>24&255,he>>>16&255,he>>>8&255,he&255,Ie>>>24&255,Ie>>>16&255,Ie>>>8&255,Ie&255,Fe.isLeading<<2|Fe.dependsOn,Fe.isDependedOn<<6|Fe.hasRedundancy<<4|Fe.paddingValue<<1|Fe.isNonSync,Fe.degradPrio&240<<8,Fe.degradPrio&15,Ge>>>24&255,Ge>>>16&255,Ge>>>8&255,Ge&255],12+16*ue);return q.box(q.types.trun,V)},q.initSegment=function(j){q.types||q.init();var E=q.moov(j),P;return P=new Uint8Array(q.FTYP.byteLength+E.byteLength),P.set(q.FTYP),P.set(E,q.FTYP.byteLength),P},q}(),ft=qn,Oe=9e4;function ua(q,K,j,E){return j===void 0&&(j=1),E===void 0&&(E=!1),Ta(q,K,1/j)}function Ta(q,K,j,E){j===void 0&&(j=1),E===void 0&&(E=!1);var P=q*K*j;return E?Math.round(P):P}function En(q,K){return K===void 0&&(K=!1),Ta(q,1e3,1/Oe,K)}function gn(q,K){return K===void 0&&(K=1),Ta(q,Oe,1/K)}var He=gn(10),ea=gn(.2),va=function(){function q(j,E,P,N){this.observer=j,this.config=E,this.typeSupported=P;var J=navigator.userAgent;this.isSafari=N&&N.indexOf("Apple")>-1&&J&&!J.match("CriOS"),this.ISGenerated=!1}var K=q.prototype;return K.destroy=function(){},K.resetTimeStamp=function(E){this._initPTS=this._initDTS=E},K.resetInitSegment=function(){this.ISGenerated=!1},K.remux=function(E,P,N,J,V,ue,re){if(this.ISGenerated||this.generateIS(E,P,V),this.ISGenerated){var he=E.samples.length,Ie=P.samples.length,Fe=V,Ge=V;if(he&&Ie){var ln=(E.samples[0].pts-P.samples[0].pts)/P.inputTimeScale;Fe+=Math.max(0,ln),Ge+=Math.max(0,-ln)}if(he){E.timescale||(l.logger.warn("regenerate InitSegment as audio detected"),this.generateIS(E,P,V));var mn=this.remuxAudio(E,Fe,ue,re);if(Ie){var Pe;mn&&(Pe=mn.endPTS-mn.startPTS),P.timescale||(l.logger.warn("regenerate InitSegment as video detected"),this.generateIS(E,P,V)),this.remuxVideo(P,Ge,ue,Pe,re)}}else if(Ie){var Rn=this.remuxVideo(P,Ge,ue,0,re);Rn&&E.codec&&this.remuxEmptyAudio(E,Fe,ue,Rn)}}N.samples.length&&this.remuxID3(N,V),J.samples.length&&this.remuxText(J,V),this.observer.trigger(t.default.FRAG_PARSED)},K.generateIS=function(E,P,N){var J=this.observer,V=E.samples,ue=P.samples,re=this.typeSupported,he="audio/mp4",Ie={},Fe={tracks:Ie},Ge=this._initPTS===void 0,ln,mn;if(Ge&&(ln=mn=1/0),E.config&&V.length&&(E.timescale=E.samplerate,l.logger.log("audio sampling rate : "+E.samplerate),E.isAAC||(re.mpeg?(he="audio/mpeg",E.codec=""):re.mp3&&(E.codec="mp3")),Ie.audio={container:he,codec:E.codec,initSegment:!E.isAAC&&re.mpeg?new Uint8Array:ft.initSegment([E]),metadata:{channelCount:E.channelCount}},Ge&&(ln=mn=V[0].pts-E.inputTimeScale*N)),P.sps&&P.pps&&ue.length){var Pe=P.inputTimeScale;P.timescale=Pe,Ie.video={container:"video/mp4",codec:P.codec,initSegment:ft.initSegment([P]),metadata:{width:P.width,height:P.height}},Ge&&(ln=Math.min(ln,ue[0].pts-Pe*N),mn=Math.min(mn,ue[0].dts-Pe*N),this.observer.trigger(t.default.INIT_PTS_FOUND,{initPTS:ln}))}Object.keys(Ie).length?(J.trigger(t.default.FRAG_PARSING_INIT_SEGMENT,Fe),this.ISGenerated=!0,Ge&&(this._initPTS=ln,this._initDTS=mn)):J.trigger(t.default.ERROR,{type:o.ErrorTypes.MEDIA_ERROR,details:o.ErrorDetails.FRAG_PARSING_ERROR,fatal:!1,reason:"no audio/video samples found"})},K.remuxVideo=function(E,P,N,J,V){var ue=8,re,he,Ie,Fe,Ge,ln,mn,Pe=E.timescale,Rn=E.samples,Vn=[],pa=Rn.length,Za=this._PTSNormalize,Lt=this._initPTS,wa=this.nextAvcDts,pt=this.isSafari;if(pa!==0){pt&&(N|=Rn.length&&wa&&(V&&Math.abs(P-wa/Pe)<.1||Math.abs(Rn[0].pts-wa-Lt)1?l.logger.log("AVC: "+En(Et,!0)+" ms hole between fragments detected,filling it"):Et<-1&&l.logger.log("AVC: "+En(-Et,!0)+" ms overlapping between fragments detected"),Ge=wa,Rn[0].dts=Ge,Fe=Math.max(Fe-Et,wa),Rn[0].pts=Fe,l.logger.log("Video: PTS/DTS adjusted: "+En(Fe,!0)+"/"+En(Ge,!0)+", delta: "+En(Et,!0)+" ms")),Ba=Rn[Rn.length-1],mn=Math.max(Ba.dts,0),ln=Math.max(Ba.pts,0,mn),pt&&(re=Math.round((mn-Ge)/(Rn.length-1)));for(var ir=0,Cr=0,ro=0;ro0?wo-1:wo].dts;if(Nc.stretchShortVideoTrack){var Pi=Nc.maxBufferHole,pd=Math.floor(Pi*Pe),ef=(J?Fe+J*Pe:this.nextAudioPts)-kr.pts;ef>pd?(re=ef-bl,re<0&&(re=bl),l.logger.log("It is approximately "+En(ef,!1)+" ms to the next segment; using duration "+En(re,!1)+" ms for the last video frame.")):re=bl}else re=bl}Li=Math.round(kr.pts-kr.dts)}Vn.push({size:ri,duration:re,cts:Li,flags:{isLeading:0,isDependedOn:0,hasRedundancy:0,degradPrio:0,dependsOn:kr.key?2:1,isNonSync:kr.key?0:1}})}this.nextAvcDts=mn+re;var $_=E.dropped;if(E.nbNalu=0,E.dropped=0,Vn.length&&navigator.userAgent.toLowerCase().indexOf("chrome")>-1){var z_=Vn[0].flags;z_.dependsOn=2,z_.isNonSync=0}E.samples=Vn,Ie=ft.moof(E.sequenceNumber++,Ge,E),E.samples=[];var xi={data1:Ie,data2:he,startPTS:Fe/Pe,endPTS:(ln+re)/Pe,startDTS:Ge/Pe,endDTS:this.nextAvcDts/Pe,type:"video",hasAudio:!1,hasVideo:!0,nb:Vn.length,dropped:$_};return this.observer.trigger(t.default.FRAG_PARSING_DATA,xi),xi}},K.remuxAudio=function(E,P,N,J){var V=E.inputTimeScale,ue=E.timescale,re=V/ue,he=E.isAAC?1024:1152,Ie=he*re,Fe=this._PTSNormalize,Ge=this._initPTS,ln=!E.isAAC&&this.typeSupported.mpeg,mn,Pe,Rn,Vn,pa,Za,Lt=ln?0:8,wa=E.samples,pt=[],Pa=this.nextAudioPts;if(N|=wa.length&&Pa&&(J&&Math.abs(P-Pa/V)<.1||Math.abs(wa[0].pts-Pa-Ge)<20*Ie),wa.forEach(function(Pi){Pi.pts=Pi.dts=Fe(Pi.pts-Ge,P*V)}),wa=wa.filter(function(Pi){return Pi.pts>=0}),wa.length!==0){if(N||(J?Pa=P*V:Pa=wa[0].pts),E.isAAC)for(var Ot=this.config.maxAudioFramesDrift,Ba=0,Et=Pa;Ba=Ot*Ie&&Cr.1*Ie,ir.pts=ir.dts=Et,Et+=Ie,Ba++}for(var Zt=wa.length,Ur=0;Zt--;)Ur+=wa[Zt].unit.byteLength;for(var nu=0,au=wa.length;nu0&&ri0&&(Pe=Hn.getSilentFrame(E.manifestCodec||E.codec,E.channelCount),Pe||(Pe=kr.subarray()),Ur+=Li*Pe.length);else if(ri<-12){l.logger.log("drop overlapping AAC sample, expected/parsed/delta: "+En(Pa,!0)+" ms / "+En(Iu,!0)+" ms / "+En(-ri,!0)+" ms"),Ur-=kr.byteLength;continue}Iu=Pa}if(pa=Iu,Ur>0){Ur+=Lt;try{Rn=new Uint8Array(Ur)}catch{this.observer.trigger(t.default.ERROR,{type:o.ErrorTypes.MUX_ERROR,details:o.ErrorDetails.REMUX_ALLOC_ERROR,fatal:!1,bytes:Ur,reason:"fail allocating audio mdat "+Ur});return}if(!ln){var Ql=new DataView(Rn.buffer);Ql.setUint32(0,Ur),Rn.set(ft.types.mdat,4)}}else return;for(var xc=0;xc=2&&(yl=pt[Zt-2].duration,mn.duration=yl),Zt){this.nextAudioPts=Pa=Za+re*yl,E.samples=pt,ln?Vn=new Uint8Array:Vn=ft.moof(E.sequenceNumber++,pa/re,E),E.samples=[];var wl=pa/V,Nc=Pa/V,bl={data1:Vn,data2:Rn,startPTS:wl,endPTS:Nc,startDTS:wl,endDTS:Nc,type:"audio",hasAudio:!0,hasVideo:!1,nb:Zt};return this.observer.trigger(t.default.FRAG_PARSING_DATA,bl),bl}return null}},K.remuxEmptyAudio=function(E,P,N,J){var V=E.inputTimeScale,ue=E.samplerate?E.samplerate:V,re=V/ue,he=this.nextAudioPts,Ie=(he!==void 0?he:J.startDTS*V)+this._initDTS,Fe=J.endDTS*V+this._initDTS,Ge=1024,ln=re*Ge,mn=Math.ceil((Fe-Ie)/ln),Pe=Hn.getSilentFrame(E.manifestCodec||E.codec,E.channelCount);if(l.logger.warn("remux empty Audio"),!Pe){l.logger.trace("Unable to remuxEmptyAudio since we were unable to get a silent frame for given audio codec!");return}for(var Rn=[],Vn=0;Vn4294967296;)E+=N;return E},q}(),La=va,_t=function(){function q(j){this.observer=j}var K=q.prototype;return K.destroy=function(){},K.resetTimeStamp=function(){},K.resetInitSegment=function(){},K.remux=function(E,P,N,J,V,ue,re,he){var Ie=this.observer,Fe="";E&&(Fe+="audio"),P&&(Fe+="video"),Ie.trigger(t.default.FRAG_PARSING_DATA,{data1:he,startPTS:V,startDTS:V,type:Fe,hasAudio:!!E,hasVideo:!!P,nb:1,dropped:0}),Ie.trigger(t.default.FRAG_PARSED)},q}(),sn=_t,ia=Object(s.getSelfScope)(),bt;try{bt=ia.performance.now.bind(ia.performance)}catch{l.logger.debug("Unable to use Performance API on this environment"),bt=ia.Date.now}var Da=function(){function q(j,E,P,N){this.observer=j,this.typeSupported=E,this.config=P,this.vendor=N}var K=q.prototype;return K.destroy=function(){var E=this.demuxer;E&&E.destroy()},K.push=function(E,P,N,J,V,ue,re,he,Ie,Fe,Ge,ln){var mn=this;if(E.byteLength>0&&P!=null&&P.key!=null&&P.method==="AES-128"){var Pe=this.decrypter;Pe==null&&(Pe=this.decrypter=new u.default(this.observer,this.config));var Rn=bt();Pe.decrypt(E,P.key.buffer,P.iv.buffer,function(Vn){var pa=bt();mn.observer.trigger(t.default.FRAG_DECRYPTED,{stats:{tstart:Rn,tdecrypt:pa}}),mn.pushDecrypted(new Uint8Array(Vn),P,new Uint8Array(N),J,V,ue,re,he,Ie,Fe,Ge,ln)})}else this.pushDecrypted(new Uint8Array(E),P,new Uint8Array(N),J,V,ue,re,he,Ie,Fe,Ge,ln)},K.pushDecrypted=function(E,P,N,J,V,ue,re,he,Ie,Fe,Ge,ln){var mn=this.demuxer;if(!mn||(re||he)&&!this.probe(E)){for(var Pe=this.observer,Rn=this.typeSupported,Vn=this.config,pa=[{demux:Xe,remux:La},{demux:ve.default,remux:sn},{demux:te,remux:La},{demux:ra,remux:La}],Za=0,Lt=pa.length;Za1?L-1:0),$=1;$1?L-1:0),$=1;$0)return d.subarray(I,I+b)},s._readSize=function(d,y){var I=0;return I=(d[y]&127)<<21,I|=(d[y+1]&127)<<14,I|=(d[y+2]&127)<<7,I|=d[y+3]&127,I},s.getTimeStamp=function(d){for(var y=s.getID3Frames(d),I=0;I>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:ee+=String.fromCharCode(O);break;case 12:case 13:$=d[oe++],ee+=String.fromCharCode((O&31)<<6|$&63);break;case 14:$=d[oe++],z=d[oe++],ee+=String.fromCharCode((O&15)<<12|($&63)<<6|(z&63)<<0);break;default:}}return ee},s}(),u;function i(){var s=Object(t.getSelfScope)();return!u&&typeof s.TextDecoder!="undefined"&&(u=new s.TextDecoder("utf-8")),u}var l=o._utf8ArrayToStr;n.default=o},"./src/demux/mp4demuxer.js":function(e,n,a){"use strict";a.r(n);var t=a("./src/utils/logger.js"),o=a("./src/events.js"),u=Math.pow(2,32)-1,i=function(){function l(R,d){this.observer=R,this.remuxer=d}var s=l.prototype;return s.resetTimeStamp=function(d){this.initPTS=d},s.resetInitSegment=function(d,y,I,b){if(d&&d.byteLength){var S=this.initData=l.parseInitSegment(d);y==null&&(y="mp4a.40.5"),I==null&&(I="avc1.42e01e");var L={};S.audio&&S.video?L.audiovideo={container:"video/mp4",codec:y+","+I,initSegment:b?d:null}:(S.audio&&(L.audio={container:"audio/mp4",codec:y,initSegment:b?d:null}),S.video&&(L.video={container:"video/mp4",codec:I,initSegment:b?d:null})),this.observer.trigger(o.default.FRAG_PARSING_INIT_SEGMENT,{tracks:L})}else y&&(this.audioCodec=y),I&&(this.videoCodec=I)},l.probe=function(d){return l.findBox({data:d,start:0,end:Math.min(d.length,16384)},["moof"]).length>0},l.bin2str=function(d){return String.fromCharCode.apply(null,d)},l.readUint16=function(d,y){d.data&&(y+=d.start,d=d.data);var I=d[y]<<8|d[y+1];return I<0?65536+I:I},l.readUint32=function(d,y){d.data&&(y+=d.start,d=d.data);var I=d[y]<<24|d[y+1]<<16|d[y+2]<<8|d[y+3];return I<0?4294967296+I:I},l.writeUint32=function(d,y,I){d.data&&(y+=d.start,d=d.data),d[y]=I>>24,d[y+1]=I>>16&255,d[y+2]=I>>8&255,d[y+3]=I&255},l.findBox=function(d,y){var I=[],b,S,L,O,$,z,ee;if(d.data?(z=d.start,O=d.end,d=d.data):(z=0,O=d.byteLength),!y.length)return null;for(b=z;b1?b+S:O,L===y[0]&&(y.length===1?I.push({data:d,start:b+8,end:ee}):($=l.findBox({data:d,start:b+8,end:ee},y.slice(1)),$.length&&(I=I.concat($)))),b=ee;return I},l.parseSegmentIndex=function(d){var y=l.findBox(d,["moov"])[0],I=y?y.end:null,b=0,S=l.findBox(d,["sidx"]),L;if(!S||!S[0])return null;L=[],S=S[0];var O=S.data[0];b=O===0?8:16;var $=l.readUint32(S,b);b+=4;var z=0,ee=0;O===0?b+=8:b+=16,b+=2;var oe=S.end+ee,te=l.readUint16(S,b);b+=2;for(var ve=0;ve>>31;if(ce===1){console.warn("SIDX has hierarchical references (not supported)");return}var le=l.readUint32(S,Re);Re+=4,L.push({referenceSize:cn,subsegmentDuration:le,info:{duration:le/$,start:oe,end:oe+cn-1}}),oe+=cn,Re+=4,b=Re}return{earliestPresentationTime:z,timescale:$,version:O,referencesCount:te,references:L,moovEndOffset:I}},l.parseInitSegment=function(d){var y=[],I=l.findBox(d,["moov","trak"]);return I.forEach(function(b){var S=l.findBox(b,["tkhd"])[0];if(S){var L=S.data[S.start],O=L===0?12:20,$=l.readUint32(S,O),z=l.findBox(b,["mdia","mdhd"])[0];if(z){L=z.data[z.start],O=L===0?12:20;var ee=l.readUint32(z,O),oe=l.findBox(b,["mdia","hdlr"])[0];if(oe){var te=l.bin2str(oe.data.subarray(oe.start+8,oe.start+12)),ve={soun:"audio",vide:"video"}[te];if(ve){var Re=l.findBox(b,["mdia","minf","stbl","stsd"]);if(Re.length){Re=Re[0];var nn=l.bin2str(Re.data.subarray(Re.start+12,Re.start+16));t.logger.log("MP4Demuxer:"+ve+":"+nn+" found")}y[$]={timescale:ee,type:ve},y[ve]={timescale:ee,id:$}}}}}}),y},l.getStartDTS=function(d,y){var I,b,S;return I=l.findBox(y,["moof","traf"]),b=[].concat.apply([],I.map(function(L){return l.findBox(L,["tfhd"]).map(function(O){var $,z,ee;return $=l.readUint32(O,4),z=d[$].timescale||9e4,ee=l.findBox(L,["tfdt"]).map(function(oe){var te,ve;return te=oe.data[oe.start],ve=l.readUint32(oe,4),te===1&&(ve*=Math.pow(2,32),ve+=l.readUint32(oe,8)),ve})[0],ee/z})})),S=Math.min.apply(null,b),isFinite(S)?S:0},l.offsetStartDTS=function(d,y,I){l.findBox(y,["moof","traf"]).map(function(b){return l.findBox(b,["tfhd"]).map(function(S){var L=l.readUint32(S,4),O=d[L].timescale||9e4;l.findBox(b,["tfdt"]).map(function($){var z=$.data[$.start],ee=l.readUint32($,4);if(z===0)l.writeUint32($,4,ee-I*O);else{ee*=Math.pow(2,32),ee+=l.readUint32($,8),ee-=I*O,ee=Math.max(ee,0);var oe=Math.floor(ee/(u+1)),te=Math.floor(ee%(u+1));l.writeUint32($,4,oe),l.writeUint32($,8,te)}})})})},s.append=function(d,y,I,b){var S=this.initData;S||(this.resetInitSegment(d,this.audioCodec,this.videoCodec,!1),S=this.initData);var L,O=this.initPTS;if(O===void 0){var $=l.getStartDTS(S,d);this.initPTS=O=$-y,this.observer.trigger(o.default.INIT_PTS_FOUND,{initPTS:O})}l.offsetStartDTS(S,d,O),L=l.getStartDTS(S,d),this.remuxer.remux(S.audio,S.video,null,null,L,I,b,d)},s.destroy=function(){},l}();n.default=i},"./src/errors.ts":function(e,n,a){"use strict";a.r(n),a.d(n,"ErrorTypes",function(){return t}),a.d(n,"ErrorDetails",function(){return o});var t;(function(u){u.NETWORK_ERROR="networkError",u.MEDIA_ERROR="mediaError",u.KEY_SYSTEM_ERROR="keySystemError",u.MUX_ERROR="muxError",u.OTHER_ERROR="otherError"})(t||(t={}));var o;(function(u){u.KEY_SYSTEM_NO_KEYS="keySystemNoKeys",u.KEY_SYSTEM_NO_ACCESS="keySystemNoAccess",u.KEY_SYSTEM_NO_SESSION="keySystemNoSession",u.KEY_SYSTEM_LICENSE_REQUEST_FAILED="keySystemLicenseRequestFailed",u.KEY_SYSTEM_NO_INIT_DATA="keySystemNoInitData",u.MANIFEST_LOAD_ERROR="manifestLoadError",u.MANIFEST_LOAD_TIMEOUT="manifestLoadTimeOut",u.MANIFEST_PARSING_ERROR="manifestParsingError",u.MANIFEST_INCOMPATIBLE_CODECS_ERROR="manifestIncompatibleCodecsError",u.LEVEL_LOAD_ERROR="levelLoadError",u.LEVEL_LOAD_TIMEOUT="levelLoadTimeOut",u.LEVEL_SWITCH_ERROR="levelSwitchError",u.AUDIO_TRACK_LOAD_ERROR="audioTrackLoadError",u.AUDIO_TRACK_LOAD_TIMEOUT="audioTrackLoadTimeOut",u.FRAG_LOAD_ERROR="fragLoadError",u.FRAG_LOAD_TIMEOUT="fragLoadTimeOut",u.FRAG_DECRYPT_ERROR="fragDecryptError",u.FRAG_PARSING_ERROR="fragParsingError",u.REMUX_ALLOC_ERROR="remuxAllocError",u.KEY_LOAD_ERROR="keyLoadError",u.KEY_LOAD_TIMEOUT="keyLoadTimeOut",u.BUFFER_ADD_CODEC_ERROR="bufferAddCodecError",u.BUFFER_APPEND_ERROR="bufferAppendError",u.BUFFER_APPENDING_ERROR="bufferAppendingError",u.BUFFER_STALLED_ERROR="bufferStalledError",u.BUFFER_FULL_ERROR="bufferFullError",u.BUFFER_SEEK_OVER_HOLE="bufferSeekOverHole",u.BUFFER_NUDGE_ON_STALL="bufferNudgeOnStall",u.INTERNAL_EXCEPTION="internalException"})(o||(o={}))},"./src/events.js":function(e,n,a){"use strict";a.r(n);var t={MEDIA_ATTACHING:"hlsMediaAttaching",MEDIA_ATTACHED:"hlsMediaAttached",MEDIA_DETACHING:"hlsMediaDetaching",MEDIA_DETACHED:"hlsMediaDetached",BUFFER_RESET:"hlsBufferReset",BUFFER_CODECS:"hlsBufferCodecs",BUFFER_CREATED:"hlsBufferCreated",BUFFER_APPENDING:"hlsBufferAppending",BUFFER_APPENDED:"hlsBufferAppended",BUFFER_EOS:"hlsBufferEos",BUFFER_FLUSHING:"hlsBufferFlushing",BUFFER_FLUSHED:"hlsBufferFlushed",MANIFEST_LOADING:"hlsManifestLoading",MANIFEST_LOADED:"hlsManifestLoaded",MANIFEST_PARSED:"hlsManifestParsed",LEVEL_SWITCHING:"hlsLevelSwitching",LEVEL_SWITCHED:"hlsLevelSwitched",LEVEL_LOADING:"hlsLevelLoading",LEVEL_LOADED:"hlsLevelLoaded",LEVEL_UPDATED:"hlsLevelUpdated",LEVEL_PTS_UPDATED:"hlsLevelPtsUpdated",AUDIO_TRACKS_UPDATED:"hlsAudioTracksUpdated",AUDIO_TRACK_SWITCHING:"hlsAudioTrackSwitching",AUDIO_TRACK_SWITCHED:"hlsAudioTrackSwitched",AUDIO_TRACK_LOADING:"hlsAudioTrackLoading",AUDIO_TRACK_LOADED:"hlsAudioTrackLoaded",SUBTITLE_TRACKS_UPDATED:"hlsSubtitleTracksUpdated",SUBTITLE_TRACK_SWITCH:"hlsSubtitleTrackSwitch",SUBTITLE_TRACK_LOADING:"hlsSubtitleTrackLoading",SUBTITLE_TRACK_LOADED:"hlsSubtitleTrackLoaded",SUBTITLE_FRAG_PROCESSED:"hlsSubtitleFragProcessed",INIT_PTS_FOUND:"hlsInitPtsFound",FRAG_LOADING:"hlsFragLoading",FRAG_LOAD_PROGRESS:"hlsFragLoadProgress",FRAG_LOAD_EMERGENCY_ABORTED:"hlsFragLoadEmergencyAborted",FRAG_LOADED:"hlsFragLoaded",FRAG_DECRYPTED:"hlsFragDecrypted",FRAG_PARSING_INIT_SEGMENT:"hlsFragParsingInitSegment",FRAG_PARSING_USERDATA:"hlsFragParsingUserdata",FRAG_PARSING_METADATA:"hlsFragParsingMetadata",FRAG_PARSING_DATA:"hlsFragParsingData",FRAG_PARSED:"hlsFragParsed",FRAG_BUFFERED:"hlsFragBuffered",FRAG_CHANGED:"hlsFragChanged",FPS_DROP:"hlsFpsDrop",FPS_DROP_LEVEL_CAPPING:"hlsFpsDropLevelCapping",ERROR:"hlsError",DESTROYING:"hlsDestroying",KEY_LOADING:"hlsKeyLoading",KEY_LOADED:"hlsKeyLoaded",STREAM_STATE_TRANSITION:"hlsStreamStateTransition",LIVE_BACK_BUFFER_REACHED:"hlsLiveBackBufferReached"};n.default=t},"./src/hls.ts":function(e,n,a){"use strict";a.r(n);var t={};a.r(t),a.d(t,"newCue",function(){return qE});var o=a("./node_modules/url-toolkit/src/url-toolkit.js"),u=a("./src/errors.ts"),i=a("./src/polyfills/number-isFinite.js"),l=a("./src/events.js"),s=a("./src/utils/logger.js"),R={hlsEventGeneric:!0,hlsHandlerDestroying:!0,hlsHandlerDestroyed:!0},d=function(){function w(f){this.hls=void 0,this.handledEvents=void 0,this.useGenericHandler=void 0,this.hls=f,this.onEvent=this.onEvent.bind(this);for(var v=arguments.length,r=new Array(v>1?v-1:0),c=1;c>8*(15-c)&255;return r},h.setDecryptDataFromLevelKey=function(v,r){var c=v;return v&&v.method&&v.uri&&!v.iv&&(c=new $(v.baseuri,v.reluri),c.method=v.method,c.iv=this.createInitializationVector(r)),c},ee(w,[{key:"url",get:function(){return!this._url&&this.relurl&&(this._url=Object(o.buildAbsoluteURL)(this.baseurl,this.relurl,{alwaysNormalize:!0})),this._url},set:function(v){this._url=v}},{key:"byteRange",get:function(){return this._byteRange?this._byteRange:[]}},{key:"byteRangeStartOffset",get:function(){return this.byteRange[0]}},{key:"byteRangeEndOffset",get:function(){return this.byteRange[1]}},{key:"decryptdata",get:function(){if(!this.levelkey&&!this._decryptdata)return null;if(!this._decryptdata&&this.levelkey){var v=this.sn;typeof v!="number"&&(this.levelkey&&this.levelkey.method==="AES-128"&&!this.levelkey.iv&&s.logger.warn('missing IV for initialization segment with method="'+this.levelkey.method+'" - compliance issue'),v=0),this._decryptdata=this.setDecryptDataFromLevelKey(this.levelkey,v)}return this._decryptdata}},{key:"endProgramDateTime",get:function(){if(this.programDateTime===null||!Object(i.isFiniteNumber)(this.programDateTime))return null;var v=Object(i.isFiniteNumber)(this.duration)?this.duration:0;return this.programDateTime+v*1e3}},{key:"encrypted",get:function(){return!!(this.decryptdata&&this.decryptdata.uri!==null&&this.decryptdata.key===null)}}]),w}();function ve(w,h){for(var f=0;fNumber.MAX_SAFE_INTEGER?1/0:r},h.hexadecimalInteger=function(v){if(this[v]){var r=(this[v]||"0x").slice(2);r=(r.length&1?"0":"")+r;for(var c=new Uint8Array(r.length/2),_=0;_Number.MAX_SAFE_INTEGER?1/0:r},h.decimalFloatingPoint=function(v){return parseFloat(this[v])},h.enumeratedString=function(v){return this[v]},h.decimalResolution=function(v){var r=cn.exec(this[v]);if(r!==null)return{width:parseInt(r[1],10),height:parseInt(r[2],10)}},w.parseAttrList=function(v){var r,c={};for(ce.lastIndex=0;(r=ce.exec(v))!==null;){var _=r[2],g='"';_.indexOf(g)===0&&_.lastIndexOf(g)===_.length-1&&(_=_.slice(1,-1)),c[r[1]]=_}return c},w}(),Ne=le,Ce={audio:{a3ds:!0,"ac-3":!0,"ac-4":!0,alac:!0,alaw:!0,dra1:!0,"dts+":!0,"dts-":!0,dtsc:!0,dtse:!0,dtsh:!0,"ec-3":!0,enca:!0,g719:!0,g726:!0,m4ae:!0,mha1:!0,mha2:!0,mhm1:!0,mhm2:!0,mlpa:!0,mp4a:!0,"raw ":!0,Opus:!0,samr:!0,sawb:!0,sawp:!0,sevc:!0,sqcp:!0,ssmv:!0,twos:!0,ulaw:!0},video:{avc1:!0,avc2:!0,avc3:!0,avc4:!0,avcp:!0,drac:!0,dvav:!0,dvhe:!0,encv:!0,hev1:!0,hvc1:!0,mjp2:!0,mp4v:!0,mvc1:!0,mvc2:!0,mvc3:!0,mvc4:!0,resv:!0,rv60:!0,s263:!0,svc1:!0,svc2:!0,"vc-1":!0,vp08:!0,vp09:!0}};function Be(w,h){var f=Ce[h];return!!f&&f[w.slice(0,4)]===!0}function Xe(w,h){return MediaSource.isTypeSupported((h||"video")+'/mp4;codecs="'+w+'"')}var Sn=/#EXT-X-STREAM-INF:([^\n\r]*)[\r\n]+([^\r\n]+)/g,ra=/#EXT-X-MEDIA:(.*)/g,kn=new RegExp([/#EXTINF:\s*(\d*(?:\.\d+)?)(?:,(.*)\s+)?/.source,/|(?!#)([\S+ ?]+)/.source,/|#EXT-X-BYTERANGE:*(.+)/.source,/|#EXT-X-PROGRAM-DATE-TIME:(.+)/.source,/|#.*/.source].join(""),"g"),Hn=/(?:(?:#(EXTM3U))|(?:#EXT-X-(PLAYLIST-TYPE):(.+))|(?:#EXT-X-(MEDIA-SEQUENCE): *(\d+))|(?:#EXT-X-(TARGETDURATION): *(\d+))|(?:#EXT-X-(KEY):(.+))|(?:#EXT-X-(START):(.+))|(?:#EXT-X-(ENDLIST))|(?:#EXT-X-(DISCONTINUITY-SEQ)UENCE:(\d+))|(?:#EXT-X-(DIS)CONTINUITY))|(?:#EXT-X-(VERSION):(\d+))|(?:#EXT-X-(MAP):(.+))|(?:(#)([^:]*):(.*))|(?:(#)(.*))(?:.*)\r?\n?/,Kn=/\.(mp4|m4s|m4v|m4a)$/i,qn=function(){function w(){}return w.findGroup=function(f,v){for(var r=0;r2?(r=v.shift()+".",r+=parseInt(v.shift()).toString(16),r+=("000"+parseInt(v.shift()).toString(16)).substr(-4)):r=f,r},w.resolve=function(f,v){return o.buildAbsoluteURL(v,f,{alwaysNormalize:!0})},w.parseMasterPlaylist=function(f,v){var r=[];Sn.lastIndex=0;function c(x,H){["video","audio"].forEach(function(U){var X=x.filter(function(qe){return Be(qe,U)});if(X.length){var ye=X.filter(function(qe){return qe.lastIndexOf("avc1",0)===0||qe.lastIndexOf("mp4a",0)===0});H[U+"Codec"]=ye.length>0?ye[0]:X[0],x=x.filter(function(qe){return X.indexOf(qe)===-1})}}),H.unknownCodecs=x}for(var _;(_=Sn.exec(f))!=null;){var g={},C=g.attrs=new Ne(_[1]);g.url=w.resolve(_[2],v);var F=C.decimalResolution("RESOLUTION");F&&(g.width=F.width,g.height=F.height),g.bitrate=C.decimalInteger("AVERAGE-BANDWIDTH")||C.decimalInteger("BANDWIDTH"),g.name=C.NAME,c([].concat((C.CODECS||"").split(/[ ,]+/)),g),g.videoCodec&&g.videoCodec.indexOf("avc1")!==-1&&(g.videoCodec=w.convertAVC1ToAVCOTI(g.videoCodec)),r.push(g)}return r},w.parseMasterPlaylistMedia=function(f,v,r,c){c===void 0&&(c=[]);var _,g=[],C=0;for(ra.lastIndex=0;(_=ra.exec(f))!==null;){var F=new Ne(_[1]);if(F.TYPE===r){var x={id:C++,groupId:F["GROUP-ID"],name:F.NAME||F.LANGUAGE,type:r,default:F.DEFAULT==="YES",autoselect:F.AUTOSELECT==="YES",forced:F.FORCED==="YES",lang:F.LANGUAGE};if(F.URI&&(x.url=w.resolve(F.URI,v)),c.length){var H=w.findGroup(c,x.groupId);x.audioCodec=H?H.codec:c[0].codec}g.push(x)}}return g},w.parseLevelPlaylist=function(f,v,r,c,_){var g=0,C=0,F=new nn(v),x=0,H=null,U=new te,X,ye,qe,vn=null;for(kn.lastIndex=0;(X=kn.exec(f))!==null;){var fa=X[1];if(fa){U.duration=parseFloat(fa);var Zn=(" "+X[2]).slice(1);U.title=Zn||null,U.tagList.push(Zn?["INF",fa,Zn]:["INF",fa])}else if(X[3]){if(Object(i.isFiniteNumber)(U.duration)){var la=g++;U.type=c,U.start=C,qe&&(U.levelkey=qe),U.sn=la,U.level=r,U.cc=x,U.urlId=_,U.baseurl=v,U.relurl=(" "+X[3]).slice(1),Oe(U,H),F.fragments.push(U),H=U,C+=U.duration,U=new te}}else if(X[4]){var Ra=(" "+X[4]).slice(1);H?U.setByteRange(Ra,H):U.setByteRange(Ra)}else if(X[5])U.rawProgramDateTime=(" "+X[5]).slice(1),U.tagList.push(["PROGRAM-DATE-TIME",U.rawProgramDateTime]),vn===null&&(vn=F.fragments.length);else{if(X=X[0].match(Hn),!X){s.logger.warn("No matches on slow regex match for level playlist!");continue}for(ye=1;ye=0&&(qe.method=ct,qe.key=null,qe.iv=xa));break}case"START":{var Eo=new Ne(Oa),e0=Eo.decimalFloatingPoint("TIME-OFFSET");Object(i.isFiniteNumber)(e0)&&(F.startTimeOffset=e0);break}case"MAP":{var n0=new Ne(Oa);U.relurl=n0.URI,n0.BYTERANGE&&U.setByteRange(n0.BYTERANGE),U.baseurl=v,U.level=r,U.type=c,U.sn="initSegment",F.initSegment=U,U=new te,U.rawProgramDateTime=F.initSegment.rawProgramDateTime;break}default:s.logger.warn("line parsed but not handled: "+X);break}}}return U=H,U&&!U.relurl&&(F.fragments.pop(),C-=U.duration),F.totalduration=C,F.averagetargetduration=C/F.fragments.length,F.endSN=g-1,F.startCC=F.fragments[0]?F.fragments[0].cc:0,F.endCC=x,!F.initSegment&&F.fragments.length&&F.fragments.every(function(fI){return Kn.test(fI.relurl)})&&(s.logger.warn("MP4 fragments found but no init segment (probably no MAP, incomplete M3U8), trying to fetch SIDX"),U=new te,U.relurl=F.fragments[0].relurl,U.baseurl=v,U.level=r,U.type=c,U.sn="initSegment",F.initSegment=U,F.needSidxRanges=!0),vn&&ft(F.fragments,vn),F},w}();function ft(w,h){for(var f=w[h],v=h-1;v>=0;v--){var r=w[v];r.programDateTime=f.programDateTime-r.duration*1e3,f=r}}function Oe(w,h){w.rawProgramDateTime?w.programDateTime=Date.parse(w.rawProgramDateTime):h&&h.programDateTime&&(w.programDateTime=h.endProgramDateTime),Object(i.isFiniteNumber)(w.programDateTime)||(w.programDateTime=null,w.rawProgramDateTime=null)}function ua(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var Ta=window,En=Ta.performance,gn=function(w){ua(h,w);function h(v){var r;return r=w.call(this,v,l.default.MANIFEST_LOADING,l.default.LEVEL_LOADING,l.default.AUDIO_TRACK_LOADING,l.default.SUBTITLE_TRACK_LOADING)||this,r.loaders={},r}h.canHaveQualityLevels=function(r){return r!==I.AUDIO_TRACK&&r!==I.SUBTITLE_TRACK},h.mapContextToLevelType=function(r){var c=r.type;switch(c){case I.AUDIO_TRACK:return b.AUDIO;case I.SUBTITLE_TRACK:return b.SUBTITLE;default:return b.MAIN}},h.getResponseUrl=function(r,c){var _=r.url;return(_===void 0||_.indexOf("data:")===0)&&(_=c.url),_};var f=h.prototype;return f.createInternalLoader=function(r){var c=this.hls.config,_=c.pLoader,g=c.loader,C=_||g,F=new C(c);return r.loader=F,this.loaders[r.type]=F,F},f.getInternalLoader=function(r){return this.loaders[r.type]},f.resetInternalLoader=function(r){this.loaders[r]&&delete this.loaders[r]},f.destroyInternalLoaders=function(){for(var r in this.loaders){var c=this.loaders[r];c&&c.destroy(),this.resetInternalLoader(r)}},f.destroy=function(){this.destroyInternalLoaders(),w.prototype.destroy.call(this)},f.onManifestLoading=function(r){this.load({url:r.url,type:I.MANIFEST,level:0,id:null,responseType:"text"})},f.onLevelLoading=function(r){this.load({url:r.url,type:I.LEVEL,level:r.level,id:r.id,responseType:"text"})},f.onAudioTrackLoading=function(r){this.load({url:r.url,type:I.AUDIO_TRACK,level:null,id:r.id,responseType:"text"})},f.onSubtitleTrackLoading=function(r){this.load({url:r.url,type:I.SUBTITLE_TRACK,level:null,id:r.id,responseType:"text"})},f.load=function(r){var c=this.hls.config;s.logger.debug("Loading playlist of type "+r.type+", level: "+r.level+", id: "+r.id);var _=this.getInternalLoader(r);if(_){var g=_.context;if(g&&g.url===r.url)return s.logger.trace("playlist request ongoing"),!1;s.logger.warn("aborting previous loader for type: "+r.type),_.abort()}var C,F,x,H;switch(r.type){case I.MANIFEST:C=c.manifestLoadingMaxRetry,F=c.manifestLoadingTimeOut,x=c.manifestLoadingRetryDelay,H=c.manifestLoadingMaxRetryTimeout;break;case I.LEVEL:C=0,H=0,x=0,F=c.levelLoadingTimeOut;break;default:C=c.levelLoadingMaxRetry,F=c.levelLoadingTimeOut,x=c.levelLoadingRetryDelay,H=c.levelLoadingMaxRetryTimeout;break}_=this.createInternalLoader(r);var U={timeout:F,maxRetry:C,retryDelay:x,maxRetryDelay:H},X={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};return s.logger.debug("Calling internal loader delegate for URL: "+r.url),_.load(r,U,X),!0},f.loadsuccess=function(r,c,_,g){if(g===void 0&&(g=null),_.isSidxRequest){this._handleSidxRequest(r,_),this._handlePlaylistLoaded(r,c,_,g);return}if(this.resetInternalLoader(_.type),typeof r.data!="string")throw new Error('expected responseType of "text" for PlaylistLoader');var C=r.data;if(c.tload=En.now(),C.indexOf("#EXTM3U")!==0){this._handleManifestParsingError(r,_,"no EXTM3U delimiter",g);return}C.indexOf("#EXTINF:")>0||C.indexOf("#EXT-X-TARGETDURATION:")>0?this._handleTrackOrLevelPlaylist(r,c,_,g):this._handleMasterPlaylist(r,c,_,g)},f.loaderror=function(r,c,_){_===void 0&&(_=null),this._handleNetworkError(c,_,!1,r)},f.loadtimeout=function(r,c,_){_===void 0&&(_=null),this._handleNetworkError(c,_,!0)},f._handleMasterPlaylist=function(r,c,_,g){var C=this.hls,F=r.data,x=h.getResponseUrl(r,_),H=qn.parseMasterPlaylist(F,x);if(!H.length){this._handleManifestParsingError(r,_,"no level found in manifest",g);return}var U=H.map(function(vn){return{id:vn.attrs.AUDIO,codec:vn.audioCodec}}),X=qn.parseMasterPlaylistMedia(F,x,"AUDIO",U),ye=qn.parseMasterPlaylistMedia(F,x,"SUBTITLES");if(X.length){var qe=!1;X.forEach(function(vn){vn.url||(qe=!0)}),qe===!1&&H[0].audioCodec&&!H[0].attrs.AUDIO&&(s.logger.log("audio codec signaled in quality level, but no embedded audio track signaled, create one"),X.unshift({type:"main",name:"main",default:!1,autoselect:!1,forced:!1,id:-1}))}C.trigger(l.default.MANIFEST_LOADED,{levels:H,audioTracks:X,subtitles:ye,url:x,stats:c,networkDetails:g})},f._handleTrackOrLevelPlaylist=function(r,c,_,g){var C=this.hls,F=_.id,x=_.level,H=_.type,U=h.getResponseUrl(r,_),X=Object(i.isFiniteNumber)(F)?F:0,ye=Object(i.isFiniteNumber)(x)?x:X,qe=h.mapContextToLevelType(_),vn=qn.parseLevelPlaylist(r.data,U,ye,qe,X);if(vn.tload=c.tload,H===I.MANIFEST){var fa={url:U,details:vn};C.trigger(l.default.MANIFEST_LOADED,{levels:[fa],audioTracks:[],url:U,stats:c,networkDetails:g})}if(c.tparsed=En.now(),vn.needSidxRanges){var Zn=vn.initSegment.url;this.load({url:Zn,isSidxRequest:!0,type:H,level:x,levelDetails:vn,id:F,rangeStart:0,rangeEnd:2048,responseType:"arraybuffer"});return}_.levelDetails=vn,this._handlePlaylistLoaded(r,c,_,g)},f._handleSidxRequest=function(r,c){if(typeof r.data=="string")throw new Error("sidx request must be made with responseType of array buffer");var _=S.default.parseSegmentIndex(new Uint8Array(r.data));if(!!_){var g=_.references,C=c.levelDetails;g.forEach(function(F,x){var H=F.info;if(!!C){var U=C.fragments[x];U.byteRange.length===0&&U.setByteRange(String(1+H.end-H.start)+"@"+String(H.start))}}),C&&C.initSegment.setByteRange(String(_.moovEndOffset)+"@0")}},f._handleManifestParsingError=function(r,c,_,g){this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.NETWORK_ERROR,details:u.ErrorDetails.MANIFEST_PARSING_ERROR,fatal:!0,url:r.url,reason:_,networkDetails:g})},f._handleNetworkError=function(r,c,_,g){_===void 0&&(_=!1),g===void 0&&(g=null),s.logger.info("A network error occured while loading a "+r.type+"-type playlist");var C,F,x=this.getInternalLoader(r);switch(r.type){case I.MANIFEST:C=_?u.ErrorDetails.MANIFEST_LOAD_TIMEOUT:u.ErrorDetails.MANIFEST_LOAD_ERROR,F=!0;break;case I.LEVEL:C=_?u.ErrorDetails.LEVEL_LOAD_TIMEOUT:u.ErrorDetails.LEVEL_LOAD_ERROR,F=!1;break;case I.AUDIO_TRACK:C=_?u.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:u.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,F=!1;break;default:F=!1}x&&(x.abort(),this.resetInternalLoader(r.type));var H={type:u.ErrorTypes.NETWORK_ERROR,details:C,fatal:F,url:r.url,loader:x,context:r,networkDetails:c};g&&(H.response=g),this.hls.trigger(l.default.ERROR,H)},f._handlePlaylistLoaded=function(r,c,_,g){var C=_.type,F=_.level,x=_.id,H=_.levelDetails;if(!H||!H.targetduration){this._handleManifestParsingError(r,_,"invalid target duration",g);return}var U=h.canHaveQualityLevels(_.type);if(U)this.hls.trigger(l.default.LEVEL_LOADED,{details:H,level:F||0,id:x||0,stats:c,networkDetails:g});else switch(C){case I.AUDIO_TRACK:this.hls.trigger(l.default.AUDIO_TRACK_LOADED,{details:H,id:x,stats:c,networkDetails:g});break;case I.SUBTITLE_TRACK:this.hls.trigger(l.default.SUBTITLE_TRACK_LOADED,{details:H,id:x,stats:c,networkDetails:g});break}},h}(y),He=gn;function ea(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var va=function(w){ea(h,w);function h(v){var r;return r=w.call(this,v,l.default.FRAG_LOADING)||this,r.loaders={},r}var f=h.prototype;return f.destroy=function(){var r=this.loaders;for(var c in r){var _=r[c];_&&_.destroy()}this.loaders={},w.prototype.destroy.call(this)},f.onFragLoading=function(r){var c=r.frag,_=c.type,g=this.loaders,C=this.hls.config,F=C.fLoader,x=C.loader;c.loaded=0;var H=g[_];H&&(s.logger.warn("abort previous fragment loader for type: "+_),H.abort()),H=g[_]=c.loader=C.fLoader?new F(C):new x(C);var U,X,ye;U={url:c.url,frag:c,responseType:"arraybuffer",progressData:!1};var qe=c.byteRangeStartOffset,vn=c.byteRangeEndOffset;Object(i.isFiniteNumber)(qe)&&Object(i.isFiniteNumber)(vn)&&(U.rangeStart=qe,U.rangeEnd=vn),X={timeout:C.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:C.fragLoadingMaxRetryTimeout},ye={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this),onProgress:this.loadprogress.bind(this)},H.load(U,X,ye)},f.loadsuccess=function(r,c,_,g){g===void 0&&(g=null);var C=r.data,F=_.frag;F.loader=void 0,this.loaders[F.type]=void 0,this.hls.trigger(l.default.FRAG_LOADED,{payload:C,frag:F,stats:c,networkDetails:g})},f.loaderror=function(r,c,_){_===void 0&&(_=null);var g=c.frag,C=g.loader;C&&C.abort(),this.loaders[g.type]=void 0,this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.NETWORK_ERROR,details:u.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:c.frag,response:r,networkDetails:_})},f.loadtimeout=function(r,c,_){_===void 0&&(_=null);var g=c.frag,C=g.loader;C&&C.abort(),this.loaders[g.type]=void 0,this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.NETWORK_ERROR,details:u.ErrorDetails.FRAG_LOAD_TIMEOUT,fatal:!1,frag:c.frag,networkDetails:_})},f.loadprogress=function(r,c,_,g){g===void 0&&(g=null);var C=c.frag;C.loaded=r.loaded,this.hls.trigger(l.default.FRAG_LOAD_PROGRESS,{frag:C,stats:r,networkDetails:g})},h}(y),La=va;function _t(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var sn=function(w){_t(h,w);function h(v){var r;return r=w.call(this,v,l.default.KEY_LOADING)||this,r.loaders={},r.decryptkey=null,r.decrypturl=null,r}var f=h.prototype;return f.destroy=function(){for(var r in this.loaders){var c=this.loaders[r];c&&c.destroy()}this.loaders={},w.prototype.destroy.call(this)},f.onKeyLoading=function(r){var c=r.frag,_=c.type,g=this.loaders[_];if(!c.decryptdata){s.logger.warn("Missing decryption data on fragment in onKeyLoading");return}var C=c.decryptdata.uri;if(C!==this.decrypturl||this.decryptkey===null){var F=this.hls.config;if(g&&(s.logger.warn("abort previous key loader for type:"+_),g.abort()),!C){s.logger.warn("key uri is falsy");return}c.loader=this.loaders[_]=new F.loader(F),this.decrypturl=C,this.decryptkey=null;var x={url:C,frag:c,responseType:"arraybuffer"},H={timeout:F.fragLoadingTimeOut,maxRetry:0,retryDelay:F.fragLoadingRetryDelay,maxRetryDelay:F.fragLoadingMaxRetryTimeout},U={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};c.loader.load(x,H,U)}else this.decryptkey&&(c.decryptdata.key=this.decryptkey,this.hls.trigger(l.default.KEY_LOADED,{frag:c}))},f.loadsuccess=function(r,c,_){var g=_.frag;if(!g.decryptdata){s.logger.error("after key load, decryptdata unset");return}this.decryptkey=g.decryptdata.key=new Uint8Array(r.data),g.loader=void 0,delete this.loaders[g.type],this.hls.trigger(l.default.KEY_LOADED,{frag:g})},f.loaderror=function(r,c){var _=c.frag,g=_.loader;g&&g.abort(),delete this.loaders[_.type],this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.NETWORK_ERROR,details:u.ErrorDetails.KEY_LOAD_ERROR,fatal:!1,frag:_,response:r})},f.loadtimeout=function(r,c){var _=c.frag,g=_.loader;g&&g.abort(),delete this.loaders[_.type],this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.NETWORK_ERROR,details:u.ErrorDetails.KEY_LOAD_TIMEOUT,fatal:!1,frag:_})},h}(y),ia=sn;function bt(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var Da={NOT_LOADED:"NOT_LOADED",APPENDING:"APPENDING",PARTIAL:"PARTIAL",OK:"OK"},ut=function(w){bt(h,w);function h(v){var r;return r=w.call(this,v,l.default.BUFFER_APPENDED,l.default.FRAG_BUFFERED,l.default.FRAG_LOADED)||this,r.bufferPadding=.2,r.fragments=Object.create(null),r.timeRanges=Object.create(null),r.config=v.config,r}var f=h.prototype;return f.destroy=function(){this.fragments=Object.create(null),this.timeRanges=Object.create(null),this.config=null,y.prototype.destroy.call(this),w.prototype.destroy.call(this)},f.getBufferedFrag=function(r,c){var _=this.fragments,g=Object.keys(_).filter(function(F){var x=_[F];if(x.body.type!==c||!x.buffered)return!1;var H=x.body;return H.startPTS<=r&&r<=H.endPTS});if(g.length===0)return null;var C=g.pop();return _[C].body},f.detectEvictedFragments=function(r,c){var _=this,g,C;Object.keys(this.fragments).forEach(function(F){var x=_.fragments[F];if(x.buffered===!0){var H=x.range[r];if(H){g=H.time;for(var U=0;U=C&&c<=F){g.push({startPTS:Math.max(r,_.start(H)),endPTS:Math.min(c,_.end(H))});break}else if(rC)g.push({startPTS:Math.max(r,_.start(H)),endPTS:Math.min(c,_.end(H))}),x=!0;else if(c<=C)break;return{time:g,partial:x}},f.getFragmentKey=function(r){return r.type+"_"+r.level+"_"+r.urlId+"_"+r.sn},f.getPartialFragment=function(r){var c=this,_,g,C,F=null,x=0;return Object.keys(this.fragments).forEach(function(H){var U=c.fragments[H];c.isPartial(U)&&(g=U.body.startPTS-c.bufferPadding,C=U.body.endPTS+c.bufferPadding,r>=g&&r<=C&&(_=Math.min(r-g,C-r),x<=_&&(F=U.body,x=_)))}),F},f.getState=function(r){var c=this.getFragmentKey(r),_=this.fragments[c],g=Da.NOT_LOADED;return _!==void 0&&(_.buffered?this.isPartial(_)===!0?g=Da.PARTIAL:g=Da.OK:g=Da.APPENDING),g},f.isPartial=function(r){return r.buffered===!0&&(r.range.video!==void 0&&r.range.video.partial===!0||r.range.audio!==void 0&&r.range.audio.partial===!0)},f.isTimeBuffered=function(r,c,_){for(var g,C,F=0;F<_.length;F++){if(g=_.start(F)-this.bufferPadding,C=_.end(F)+this.bufferPadding,r>=g&&c<=C)return!0;if(c<=g)return!1}return!1},f.onFragLoaded=function(r){var c=r.frag;!Object(i.isFiniteNumber)(c.sn)||c.bitrateTest||(this.fragments[this.getFragmentKey(c)]={body:c,range:Object.create(null),buffered:!1})},f.onBufferAppended=function(r){var c=this;this.timeRanges=r.timeRanges,Object.keys(this.timeRanges).forEach(function(_){var g=c.timeRanges[_];c.detectEvictedFragments(_,g)})},f.onFragBuffered=function(r){this.detectPartialFragments(r.frag)},f.hasFragment=function(r){var c=this.getFragmentKey(r);return this.fragments[c]!==void 0},f.removeFragment=function(r){var c=this.getFragmentKey(r);delete this.fragments[c]},f.removeAllFragments=function(){this.fragments=Object.create(null)},h}(y),q={search:function(h,f){for(var v=0,r=h.length-1,c=null,_=null;v<=r;){c=(v+r)/2|0,_=h[c];var g=f(_);if(g>0)v=c+1;else if(g<0)r=c-1;else return _}return null}},K=q,j=function(){function w(){}return w.isBuffered=function(f,v){try{if(f){for(var r=f.buffered,c=0;c=r.start(c)&&v<=r.end(c))return!0}}catch{}return!1},w.bufferInfo=function(f,v,r){try{if(f){var c=f.buffered,_=[],g;for(g=0;gC&&(c[g-1].end=f[_].end):c.push(f[_])}else c.push(f[_])}else c=f;for(var F=0,x,H=v,U=v,X=0;X=ye&&v1?c-1:0),g=1;gh?(v.duration=c-v.start,v.duration<0&&s.logger.warn("negative duration computed for frag "+v.sn+",level "+v.level+", there should be some duration drift between playlist and fragment!")):(r.duration=v.start-c,r.duration<0&&s.logger.warn("negative duration computed for frag "+r.sn+",level "+r.level+", there should be some duration drift between playlist and fragment!")):f>h?r.start=v.start+v.duration:r.start=Math.max(v.start-r.duration,0)}function Pe(w,h,f,v,r,c){var _=f;if(Object(i.isFiniteNumber)(h.startPTS)){var g=Math.abs(h.startPTS-f);Object(i.isFiniteNumber)(h.deltaPTS)?h.deltaPTS=Math.max(g,h.deltaPTS):h.deltaPTS=g,_=Math.max(f,h.startPTS),f=Math.min(f,h.startPTS),v=Math.max(v,h.endPTS),r=Math.min(r,h.startDTS),c=Math.max(c,h.endDTS)}var C=f-h.start;h.start=h.startPTS=f,h.maxStartPTS=_,h.endPTS=v,h.startDTS=r,h.endDTS=c,h.duration=v-f;var F=h.sn;if(!w||Fw.endSN)return 0;var x,H,U;for(x=F-w.startSN,H=w.fragments,H[x]=h,U=x;U>0;U--)mn(H,U,U-1);for(U=x;Uv.length))for(var c=0;ch?-1:0})}function Ba(w,h,f){var v=!1;return h&&h.details&&f&&(f.endCC>f.startCC||w&&w.cc=(r||0))return null;f=f||0;for(var c=0;cw&&f.start?-1:0}function Ur(w,h,f){var v=Math.min(h,f.duration+(f.deltaPTS?f.deltaPTS:0))*1e3,r=f.endProgramDateTime||0;return r-v>w}var nu=250,au=2,wo=.1,kr=.05,Iu=function(){function w(f,v,r,c){this.config=f,this.media=v,this.fragmentTracker=r,this.hls=c,this.nudgeRetry=0,this.stallReported=!1,this.stalled=null,this.moved=!1,this.seeking=!1}var h=w.prototype;return h.poll=function(v){var r=this.config,c=this.media,_=this.stalled,g=c.currentTime,C=c.seeking,F=this.seeking&&!C,x=!this.seeking&&C;if(this.seeking=C,g!==v){if(this.moved=!0,_!==null){if(this.stallReported){var H=self.performance.now()-_;s.logger.warn("playback not stuck anymore @"+g+", after "+Math.round(H)+"ms"),this.stallReported=!1}this.stalled=null,this.nudgeRetry=0}return}if((x||F)&&(this.stalled=null),!(c.paused||c.ended||c.playbackRate===0||!c.buffered.length)){var U=j.bufferInfo(c,g,0),X=U.len>0,ye=U.nextStart||0;if(!(!X&&!ye)){if(C){var qe=U.len>au,vn=!ye||ye-g>au;if(qe||vn)return;this.moved=!1}if(!this.moved&&this.stalled){var fa=Math.max(ye,U.start||0)-g;if(fa>0&&fa<=au){this._trySkipBufferHole(null);return}}var Zn=self.performance.now();if(_===null){this.stalled=Zn;return}var la=Zn-_;!C&&la>=nu&&this._reportStall(U.len);var Ra=j.bufferInfo(c,g,r.maxBufferHole);this._tryFixBufferStall(Ra,la)}}},h._tryFixBufferStall=function(v,r){var c=this.config,_=this.fragmentTracker,g=this.media,C=g.currentTime,F=_.getPartialFragment(C);if(F){var x=this._trySkipBufferHole(F);if(x)return}v.len>c.maxBufferHole&&r>c.highBufferWatchdogPeriod*1e3&&(s.logger.warn("Trying to nudge playhead over buffer-hole"),this.stalled=null,this._tryNudgeBuffer())},h._reportStall=function(v){var r=this.hls,c=this.media,_=this.stallReported;_||(this.stallReported=!0,s.logger.warn("Playback stalling at @"+c.currentTime+" due to low buffer"),r.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.BUFFER_STALLED_ERROR,fatal:!1,buffer:v}))},h._trySkipBufferHole=function(v){for(var r=this.config,c=this.hls,_=this.media,g=_.currentTime,C=0,F=0;F<_.buffered.length;F++){var x=_.buffered.start(F);if(g+r.maxBufferHole>=C&&g1?c-1:0),g=1;g1&&(this.clearNextTick(),this._tickTimer=self.setTimeout(this._boundTick,0)),this._tickCallCount=0)},f.doTick=function(){},h}(y);function xc(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var se={STOPPED:"STOPPED",STARTING:"STARTING",IDLE:"IDLE",PAUSED:"PAUSED",KEY_LOADING:"KEY_LOADING",FRAG_LOADING:"FRAG_LOADING",FRAG_LOADING_WAITING_RETRY:"FRAG_LOADING_WAITING_RETRY",WAITING_TRACK:"WAITING_TRACK",PARSING:"PARSING",PARSED:"PARSED",BUFFER_FLUSHING:"BUFFER_FLUSHING",ENDED:"ENDED",ERROR:"ERROR",WAITING_INIT_PTS:"WAITING_INIT_PTS",WAITING_LEVEL:"WAITING_LEVEL"},yl=function(w){xc(h,w);function h(){return w.apply(this,arguments)||this}var f=h.prototype;return f.doTick=function(){},f.startLoad=function(){},f.stopLoad=function(){var r=this.fragCurrent;r&&(r.loader&&r.loader.abort(),this.fragmentTracker.removeFragment(r)),this.demuxer&&(this.demuxer.destroy(),this.demuxer=null),this.fragCurrent=null,this.fragPrevious=null,this.clearInterval(),this.clearNextTick(),this.state=se.STOPPED},f._streamEnded=function(r,c){var _=this.fragCurrent,g=this.fragmentTracker;if(!c.live&&_&&!_.backtracked&&_.sn===c.endSN&&!r.nextStart){var C=g.getState(_);return C===Da.PARTIAL||C===Da.OK}return!1},f.onMediaSeeking=function(){var r=this.config,c=this.media,_=this.mediaBuffer,g=this.state,C=c?c.currentTime:null,F=j.bufferInfo(_||c,C,this.config.maxBufferHole);if(Object(i.isFiniteNumber)(C)&&s.logger.log("media seeking to "+C.toFixed(3)),g===se.FRAG_LOADING){var x=this.fragCurrent;if(F.len===0&&x){var H=r.maxFragLookUpTolerance,U=x.start-H,X=x.start+x.duration+H;CX?(x.loader&&(s.logger.log("seeking outside of buffer while fragment load in progress, cancel fragment load"),x.loader.abort()),this.fragCurrent=null,this.fragPrevious=null,this.state=se.IDLE):s.logger.log("seeking outside of buffer but within currently loaded fragment range")}}else g===se.ENDED&&(F.len===0&&(this.fragPrevious=null,this.fragCurrent=null),this.state=se.IDLE);c&&(this.lastCurrentTime=C),this.loadedmetadata||(this.nextLoadPosition=this.startPosition=C),this.tick()},f.onMediaEnded=function(){this.startPosition=this.lastCurrentTime=0},f.onHandlerDestroying=function(){this.stopLoad(),w.prototype.onHandlerDestroying.call(this)},f.onHandlerDestroyed=function(){this.state=se.STOPPED,this.fragmentTracker=null},f.computeLivePosition=function(r,c){var _=this.config.liveSyncDuration!==void 0?this.config.liveSyncDuration:this.config.liveSyncDurationCount*c.targetduration;return r+Math.max(0,c.totalduration-_)},h}(Ql);function wl(w,h){for(var f=0;f0&&r===-1&&(s.logger.log("override startPosition with lastCurrentTime @"+c.toFixed(3)),r=c),this.state=se.IDLE,this.nextLoadPosition=this.startPosition=this.lastCurrentTime=r,this.tick()}else this.forceStartLoad=!0,this.state=se.STOPPED},f.stopLoad=function(){this.forceStartLoad=!1,w.prototype.stopLoad.call(this)},f.doTick=function(){switch(this.state){case se.BUFFER_FLUSHING:this.fragLoadError=0;break;case se.IDLE:this._doTickIdle();break;case se.WAITING_LEVEL:var r=this.levels[this.level];r&&r.details&&(this.state=se.IDLE);break;case se.FRAG_LOADING_WAITING_RETRY:var c=window.performance.now(),_=this.retryDate;(!_||c>=_||this.media&&this.media.seeking)&&(s.logger.log("mediaController: retryDate reached, switch back to IDLE state"),this.state=se.IDLE);break;case se.ERROR:case se.STOPPED:case se.FRAG_LOADING:case se.PARSING:case se.PARSED:case se.ENDED:break;default:break}this._checkBuffer(),this._checkFragmentChanged()},f._doTickIdle=function(){var r=this.hls,c=r.config,_=this.media;if(!(this.levelLastLoaded===void 0||!_&&(this.startFragRequested||!c.startFragPrefetch))){var g;this.loadedmetadata?g=_.currentTime:g=this.nextLoadPosition;var C=r.nextLoadLevel,F=this.levels[C];if(!!F){var x=F.bitrate,H;x?H=Math.max(8*c.maxBufferSize/x,c.maxBufferLength):H=c.maxBufferLength,H=Math.min(H,c.maxMaxBufferLength);var U=j.bufferInfo(this.mediaBuffer?this.mediaBuffer:_,g,c.maxBufferHole),X=U.len;if(!(X>=H)){s.logger.trace("buffer length of "+X.toFixed(3)+" is below max of "+H.toFixed(3)+". checking for more payload ..."),this.level=r.nextLoadLevel=C;var ye=F.details;if(!ye||ye.live&&this.levelLastLoaded!==C){this.state=se.WAITING_LEVEL;return}if(this._streamEnded(U,ye)){var qe={};this.altAudio&&(qe.type="video"),this.hls.trigger(l.default.BUFFER_EOS,qe),this.state=se.ENDED;return}this._fetchPayloadOrEos(g,U,ye)}}}},f._fetchPayloadOrEos=function(r,c,_){var g=this.fragPrevious,C=this.level,F=_.fragments,x=F.length;if(x!==0){var H=F[0].start,U=F[x-1].start+F[x-1].duration,X=c.end,ye;if(_.initSegment&&!_.initSegment.data)ye=_.initSegment;else if(_.live){var qe=this.config.initialLiveManifestSize;if(xqe&&qe>U.currentTime&&(s.logger.log("buffer end: "+c.toFixed(3)+" is located too far from the end of live sliding playlist, reset currentTime to : "+qe.toFixed(3)),U.currentTime=qe),this.nextLoadPosition=qe}if(r.PTSKnown&&c>g&&U&&U.readyState)return null;if(this.startFragRequested&&!r.PTSKnown){if(C)if(r.hasProgramDateTime)s.logger.log("live playlist, switching playlist, load frag with same PDT: "+C.programDateTime),X=No(F,C.endProgramDateTime,H.maxFragLookUpTolerance);else{var vn=C.sn+1;if(vn>=r.startSN&&vn<=r.endSN){var fa=F[vn-r.startSN];C.cc===fa.cc&&(X=fa,s.logger.log("live playlist, switching playlist, load frag with next SN: "+X.sn))}X||(X=K.search(F,function(Zn){return C.cc-Zn.cc}),X&&s.logger.log("live playlist, switching playlist, load frag with same CC: "+X.sn))}X||(X=F[Math.min(x-1,Math.round(x/2))],s.logger.log("live playlist, switching playlist, unknown, load middle frag : "+X.sn))}return X},f._findFragment=function(r,c,_,g,C,F,x){var H=this.hls.config,U;if(CF-H.maxFragLookUpTolerance?0:H.maxFragLookUpTolerance;U=Fr(c,g,C,X)}else U=g[_-1];if(U){var ye=U.sn-x.startSN,qe=c&&U.level===c.level,vn=g[ye-1],fa=g[ye+1];if(c&&U.sn===c.sn)if(qe&&!U.backtracked)if(U.snH.maxBufferHole&&c.dropped&&ye?(U=vn,s.logger.warn("Previous fragment was dropped with large PTS gap between audio and video. Maybe fragment is not starting with a keyframe? Loading previous one to try to overcome this")):(U=fa,s.logger.log("Re-loading fragment with SN: "+U.sn))}else U=null;else U.backtracked&&(fa&&fa.backtracked?(s.logger.warn("Already backtracked from fragment "+fa.sn+", will not backtrack to fragment "+U.sn+". Loading fragment "+fa.sn),U=fa):(s.logger.warn("Loaded fragment with dropped frames, backtracking 1 segment to find a keyframe"),U.dropped=0,vn?(U=vn,U.backtracked=!0):ye&&(U=null)))}return U},f._loadKey=function(r){this.state=se.KEY_LOADING,this.hls.trigger(l.default.KEY_LOADING,{frag:r})},f._loadFragment=function(r){var c=this.fragmentTracker.getState(r);this.fragCurrent=r,r.sn!=="initSegment"&&(this.startFragRequested=!0),Object(i.isFiniteNumber)(r.sn)&&!r.bitrateTest&&(this.nextLoadPosition=r.start+r.duration),r.backtracked||c===Da.NOT_LOADED||c===Da.PARTIAL?(r.autoLevel=this.hls.autoLevelEnabled,r.bitrateTest=this.bitrateTest,this.hls.trigger(l.default.FRAG_LOADING,{frag:r}),this.demuxer||(this.demuxer=new Ge(this.hls,"main")),this.state=se.FRAG_LOADING):c===Da.APPENDING&&this._reduceMaxBufferLength(r.duration)&&this.fragmentTracker.removeFragment(r)},f.getBufferedFrag=function(r){return this.fragmentTracker.getBufferedFrag(r,b.MAIN)},f.followingBufferedFrag=function(r){return r?this.getBufferedFrag(r.endPTS+.5):null},f._checkFragmentChanged=function(){var r,c,_=this.media;if(_&&_.readyState&&_.seeking===!1&&(c=_.currentTime,c>this.lastCurrentTime&&(this.lastCurrentTime=c),j.isBuffered(_,c)?r=this.getBufferedFrag(c):j.isBuffered(_,c+.1)&&(r=this.getBufferedFrag(c+.1)),r)){var g=r;if(g!==this.fragPlaying){this.hls.trigger(l.default.FRAG_CHANGED,{frag:g});var C=g.level;(!this.fragPlaying||this.fragPlaying.level!==C)&&this.hls.trigger(l.default.LEVEL_SWITCHED,{level:C}),this.fragPlaying=g}}},f.immediateLevelSwitch=function(){if(s.logger.log("immediateLevelSwitch"),!this.immediateSwitch){this.immediateSwitch=!0;var r=this.media,c;r?(c=r.paused,r.pause()):c=!0,this.previouslyPaused=c}var _=this.fragCurrent;_&&_.loader&&_.loader.abort(),this.fragCurrent=null,this.flushMainBuffer(0,Number.POSITIVE_INFINITY)},f.immediateLevelSwitchEnd=function(){var r=this.media;r&&r.buffered.length&&(this.immediateSwitch=!1,j.isBuffered(r,r.currentTime)&&(r.currentTime-=1e-4),this.previouslyPaused||r.play())},f.nextLevelSwitch=function(){var r=this.media;if(r&&r.readyState){var c,_,g;if(_=this.getBufferedFrag(r.currentTime),_&&_.startPTS>1&&this.flushMainBuffer(0,_.startPTS-1),r.paused)c=0;else{var C=this.hls.nextLoadLevel,F=this.levels[C],x=this.fragLastKbps;x&&this.fragCurrent?c=this.fragCurrent.duration*F.bitrate/(1e3*x)+1:c=0}if(g=this.getBufferedFrag(r.currentTime+c),g&&(g=this.followingBufferedFrag(g),g)){var H=this.fragCurrent;H&&H.loader&&H.loader.abort(),this.fragCurrent=null,this.flushMainBuffer(g.maxStartPTS,Number.POSITIVE_INFINITY)}}},f.flushMainBuffer=function(r,c){this.state=se.BUFFER_FLUSHING;var _={startOffset:r,endOffset:c};this.altAudio&&(_.type="video"),this.hls.trigger(l.default.BUFFER_FLUSHING,_)},f.onMediaAttached=function(r){var c=this.media=this.mediaBuffer=r.media;this.onvseeking=this.onMediaSeeking.bind(this),this.onvseeked=this.onMediaSeeked.bind(this),this.onvended=this.onMediaEnded.bind(this),c.addEventListener("seeking",this.onvseeking),c.addEventListener("seeked",this.onvseeked),c.addEventListener("ended",this.onvended);var _=this.config;this.levels&&_.autoStartLoad&&this.hls.startLoad(_.startPosition),this.gapController=new Iu(_,c,this.fragmentTracker,this.hls)},f.onMediaDetaching=function(){var r=this.media;r&&r.ended&&(s.logger.log("MSE detaching and video ended, reset startPosition"),this.startPosition=this.lastCurrentTime=0);var c=this.levels;c&&c.forEach(function(_){_.details&&_.details.fragments.forEach(function(g){g.backtracked=void 0})}),r&&(r.removeEventListener("seeking",this.onvseeking),r.removeEventListener("seeked",this.onvseeked),r.removeEventListener("ended",this.onvended),this.onvseeking=this.onvseeked=this.onvended=null),this.fragmentTracker.removeAllFragments(),this.media=this.mediaBuffer=null,this.loadedmetadata=!1,this.stopLoad()},f.onMediaSeeked=function(){var r=this.media,c=r?r.currentTime:void 0;Object(i.isFiniteNumber)(c)&&s.logger.log("media seeked to "+c.toFixed(3)),this.tick()},f.onManifestLoading=function(){s.logger.log("trigger BUFFER_RESET"),this.hls.trigger(l.default.BUFFER_RESET),this.fragmentTracker.removeAllFragments(),this.stalled=!1,this.startPosition=this.lastCurrentTime=0},f.onManifestParsed=function(r){var c=!1,_=!1,g;r.levels.forEach(function(F){g=F.audioCodec,g&&(g.indexOf("mp4a.40.2")!==-1&&(c=!0),g.indexOf("mp4a.40.5")!==-1&&(_=!0))}),this.audioCodecSwitch=c&&_,this.audioCodecSwitch&&s.logger.log("both AAC/HE-AAC audio found in levels; declaring level codec as HE-AAC"),this.altAudio=r.altAudio,this.levels=r.levels,this.startFragRequested=!1;var C=this.config;(C.autoStartLoad||this.forceStartLoad)&&this.hls.startLoad(C.startPosition)},f.onLevelLoaded=function(r){var c=r.details,_=r.level,g=this.levels[this.levelLastLoaded],C=this.levels[_],F=c.totalduration,x=0;if(s.logger.log("level "+_+" loaded ["+c.startSN+","+c.endSN+"],duration:"+F),c.live){var H=C.details;H&&c.fragments.length>0?(Rn(H,c),x=c.fragments[0].start,this.liveSyncPosition=this.computeLivePosition(x,H),c.PTSKnown&&Object(i.isFiniteNumber)(x)?s.logger.log("live playlist sliding:"+x.toFixed(3)):(s.logger.log("live playlist - outdated PTS, unknown sliding"),Cr(this.fragPrevious,g,c))):(s.logger.log("live playlist - first load, unknown sliding"),c.PTSKnown=!1,Cr(this.fragPrevious,g,c))}else c.PTSKnown=!1;if(C.details=c,this.levelLastLoaded=_,this.hls.trigger(l.default.LEVEL_UPDATED,{details:c,level:_}),this.startFragRequested===!1){if(this.startPosition===-1||this.lastCurrentTime===-1){var U=c.startTimeOffset;Object(i.isFiniteNumber)(U)?(U<0&&(s.logger.log("negative start time offset "+U+", count from end of last fragment"),U=x+F+U),s.logger.log("start time offset found in playlist, adjust startPosition to "+U),this.startPosition=U):c.live?(this.startPosition=this.computeLivePosition(x,c),s.logger.log("configure startPosition to "+this.startPosition)):this.startPosition=0,this.lastCurrentTime=this.startPosition}this.nextLoadPosition=this.startPosition}this.state===se.WAITING_LEVEL&&(this.state=se.IDLE),this.tick()},f.onKeyLoaded=function(){this.state===se.KEY_LOADING&&(this.state=se.IDLE,this.tick())},f.onFragLoaded=function(r){var c=this.fragCurrent,_=this.hls,g=this.levels,C=this.media,F=r.frag;if(this.state===se.FRAG_LOADING&&c&&F.type==="main"&&F.level===c.level&&F.sn===c.sn){var x=r.stats,H=g[c.level],U=H.details;if(this.bitrateTest=!1,this.stats=x,s.logger.log("Loaded "+c.sn+" of ["+U.startSN+" ,"+U.endSN+"],level "+c.level),F.bitrateTest&&_.nextLoadLevel)this.state=se.IDLE,this.startFragRequested=!1,x.tparsed=x.tbuffered=window.performance.now(),_.trigger(l.default.FRAG_BUFFERED,{stats:x,frag:c,id:"main"}),this.tick();else if(F.sn==="initSegment")this.state=se.IDLE,x.tparsed=x.tbuffered=window.performance.now(),U.initSegment.data=r.payload,_.trigger(l.default.FRAG_BUFFERED,{stats:x,frag:c,id:"main"}),this.tick();else{s.logger.log("Parsing "+c.sn+" of ["+U.startSN+" ,"+U.endSN+"],level "+c.level+", cc "+c.cc),this.state=se.PARSING,this.pendingBuffering=!0,this.appended=!1,F.bitrateTest&&(F.bitrateTest=!1,this.fragmentTracker.onFragLoaded({frag:F}));var X=!(C&&C.seeking)&&(U.PTSKnown||!U.live),ye=U.initSegment?U.initSegment.data:[],qe=this._getAudioCodec(H),vn=this.demuxer=this.demuxer||new Ge(this.hls,"main");vn.push(r.payload,ye,qe,H.videoCodec,c,U.totalduration,X)}}this.fragLoadError=0},f.onFragParsingInitSegment=function(r){var c=this.fragCurrent,_=r.frag;if(c&&r.id==="main"&&_.sn===c.sn&&_.level===c.level&&this.state===se.PARSING){var g=r.tracks,C,F;if(g.audio&&this.altAudio&&delete g.audio,F=g.audio,F){var x=this.levels[this.level].audioCodec,H=navigator.userAgent.toLowerCase();x&&this.audioCodecSwap&&(s.logger.log("swapping playlist audio codec"),x.indexOf("mp4a.40.5")!==-1?x="mp4a.40.2":x="mp4a.40.5"),this.audioCodecSwitch&&F.metadata.channelCount!==1&&H.indexOf("firefox")===-1&&(x="mp4a.40.5"),H.indexOf("android")!==-1&&F.container!=="audio/mpeg"&&(x="mp4a.40.2",s.logger.log("Android: force audio codec to "+x)),F.levelCodec=x,F.id=r.id}F=g.video,F&&(F.levelCodec=this.levels[this.level].videoCodec,F.id=r.id),this.hls.trigger(l.default.BUFFER_CODECS,g);for(C in g){F=g[C],s.logger.log("main track:"+C+",container:"+F.container+",codecs[level/parsed]=["+F.levelCodec+"/"+F.codec+"]");var U=F.initSegment;U&&(this.appended=!0,this.pendingBuffering=!0,this.hls.trigger(l.default.BUFFER_APPENDING,{type:C,data:U,parent:"main",content:"initSegment"}))}this.tick()}},f.onFragParsingData=function(r){var c=this,_=this.fragCurrent,g=r.frag;if(_&&r.id==="main"&&g.sn===_.sn&&g.level===_.level&&!(r.type==="audio"&&this.altAudio)&&this.state===se.PARSING){var C=this.levels[this.level],F=_;if(Object(i.isFiniteNumber)(r.endPTS)||(r.endPTS=r.startPTS+_.duration,r.endDTS=r.startDTS+_.duration),r.hasAudio===!0&&F.addElementaryStream(oe.AUDIO),r.hasVideo===!0&&F.addElementaryStream(oe.VIDEO),s.logger.log("Parsed "+r.type+",PTS:["+r.startPTS.toFixed(3)+","+r.endPTS.toFixed(3)+"],DTS:["+r.startDTS.toFixed(3)+"/"+r.endDTS.toFixed(3)+"],nb:"+r.nb+",dropped:"+(r.dropped||0)),r.type==="video")if(F.dropped=r.dropped,F.dropped)if(F.backtracked)s.logger.warn("Already backtracked on this fragment, appending with the gap",F.sn);else{var x=C.details;if(x&&F.sn===x.startSN)s.logger.warn("missing video frame(s) on first frag, appending with gap",F.sn);else{s.logger.warn("missing video frame(s), backtracking fragment",F.sn),this.fragmentTracker.removeFragment(F),F.backtracked=!0,this.nextLoadPosition=r.startPTS,this.state=se.IDLE,this.fragPrevious=F,this.tick();return}}else F.backtracked=!1;var H=Pe(C.details,F,r.startPTS,r.endPTS,r.startDTS,r.endDTS),U=this.hls;U.trigger(l.default.LEVEL_PTS_UPDATED,{details:C.details,level:this.level,drift:H,type:r.type,start:r.startPTS,end:r.endPTS}),[r.data1,r.data2].forEach(function(X){X&&X.length&&c.state===se.PARSING&&(c.appended=!0,c.pendingBuffering=!0,U.trigger(l.default.BUFFER_APPENDING,{type:r.type,data:X,parent:"main",content:"data"}))}),this.tick()}},f.onFragParsed=function(r){var c=this.fragCurrent,_=r.frag;c&&r.id==="main"&&_.sn===c.sn&&_.level===c.level&&this.state===se.PARSING&&(this.stats.tparsed=window.performance.now(),this.state=se.PARSED,this._checkAppendedParsed())},f.onAudioTrackSwitching=function(r){var c=!!r.url,_=r.id;if(!c){if(this.mediaBuffer!==this.media){s.logger.log("switching on main audio, use media.buffered to schedule main fragment loading"),this.mediaBuffer=this.media;var g=this.fragCurrent;g.loader&&(s.logger.log("switching to main audio track, cancel main fragment load"),g.loader.abort()),this.fragCurrent=null,this.fragPrevious=null,this.demuxer&&(this.demuxer.destroy(),this.demuxer=null),this.state=se.IDLE}var C=this.hls;C.trigger(l.default.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"}),C.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:_}),this.altAudio=!1}},f.onAudioTrackSwitched=function(r){var c=r.id,_=!!this.hls.audioTracks[c].url;if(_){var g=this.videoBuffer;g&&this.mediaBuffer!==g&&(s.logger.log("switching on alternate audio, use video.buffered to schedule main fragment loading"),this.mediaBuffer=g)}this.altAudio=_,this.tick()},f.onBufferCreated=function(r){var c=r.tracks,_,g,C=!1;for(var F in c){var x=c[F];x.id==="main"?(g=F,_=x,F==="video"&&(this.videoBuffer=c[F].buffer)):C=!0}C&&_?(s.logger.log("alternate track found, use "+g+".buffered to schedule main fragment loading"),this.mediaBuffer=_.buffer):this.mediaBuffer=this.media},f.onBufferAppended=function(r){if(r.parent==="main"){var c=this.state;(c===se.PARSING||c===se.PARSED)&&(this.pendingBuffering=r.pending>0,this._checkAppendedParsed())}},f._checkAppendedParsed=function(){if(this.state===se.PARSED&&(!this.appended||!this.pendingBuffering)){var r=this.fragCurrent;if(r){var c=this.mediaBuffer?this.mediaBuffer:this.media;s.logger.log("main buffered : "+pt.toString(c.buffered)),this.fragPrevious=r;var _=this.stats;_.tbuffered=window.performance.now(),this.fragLastKbps=Math.round(8*_.total/(_.tbuffered-_.tfirst)),this.hls.trigger(l.default.FRAG_BUFFERED,{stats:_,frag:r,id:"main"}),this.state=se.IDLE}this.tick()}},f.onError=function(r){var c=r.frag||this.fragCurrent;if(!(c&&c.type!=="main")){var _=!!this.media&&j.isBuffered(this.media,this.media.currentTime)&&j.isBuffered(this.media,this.media.currentTime+.5);switch(r.details){case u.ErrorDetails.FRAG_LOAD_ERROR:case u.ErrorDetails.FRAG_LOAD_TIMEOUT:case u.ErrorDetails.KEY_LOAD_ERROR:case u.ErrorDetails.KEY_LOAD_TIMEOUT:if(!r.fatal)if(this.fragLoadError+1<=this.config.fragLoadingMaxRetry){var g=Math.min(Math.pow(2,this.fragLoadError)*this.config.fragLoadingRetryDelay,this.config.fragLoadingMaxRetryTimeout);s.logger.warn("mediaController: frag loading failed, retry in "+g+" ms"),this.retryDate=window.performance.now()+g,this.loadedmetadata||(this.startFragRequested=!1,this.nextLoadPosition=this.startPosition),this.fragLoadError++,this.state=se.FRAG_LOADING_WAITING_RETRY}else s.logger.error("mediaController: "+r.details+" reaches max retry, redispatch as fatal ..."),r.fatal=!0,this.state=se.ERROR;break;case u.ErrorDetails.LEVEL_LOAD_ERROR:case u.ErrorDetails.LEVEL_LOAD_TIMEOUT:this.state!==se.ERROR&&(r.fatal?(this.state=se.ERROR,s.logger.warn("streamController: "+r.details+",switch to "+this.state+" state ...")):!r.levelRetry&&this.state===se.WAITING_LEVEL&&(this.state=se.IDLE));break;case u.ErrorDetails.BUFFER_FULL_ERROR:r.parent==="main"&&(this.state===se.PARSING||this.state===se.PARSED)&&(_?(this._reduceMaxBufferLength(this.config.maxBufferLength),this.state=se.IDLE):(s.logger.warn("buffer full error also media.currentTime is not buffered, flush everything"),this.fragCurrent=null,this.flushMainBuffer(0,Number.POSITIVE_INFINITY)));break;default:break}}},f._reduceMaxBufferLength=function(r){var c=this.config;return c.maxMaxBufferLength>=r?(c.maxMaxBufferLength/=2,s.logger.warn("main:reduce max buffer length to "+c.maxMaxBufferLength+"s"),!0):!1},f._checkBuffer=function(){var r=this.media;if(!(!r||r.readyState===0)){var c=this.mediaBuffer?this.mediaBuffer:r,_=c.buffered;!this.loadedmetadata&&_.length?(this.loadedmetadata=!0,this._seekToStartPos()):this.immediateSwitch?this.immediateLevelSwitchEnd():this.gapController.poll(this.lastCurrentTime,_)}},f.onFragLoadEmergencyAborted=function(){this.state=se.IDLE,this.loadedmetadata||(this.startFragRequested=!1,this.nextLoadPosition=this.startPosition),this.tick()},f.onBufferFlushed=function(){var r=this.mediaBuffer?this.mediaBuffer:this.media;r&&this.fragmentTracker.detectEvictedFragments(oe.VIDEO,r.buffered),this.state=se.IDLE,this.fragPrevious=null},f.swapAudioCodec=function(){this.audioCodecSwap=!this.audioCodecSwap},f._seekToStartPos=function(){var r=this.media,c=r.currentTime,_=r.seeking?c:this.startPosition;c!==_&&_>=0&&(s.logger.log("target start position not buffered, seek to buffered.start(0) "+_+" from current time "+c+" "),r.currentTime=_)},f._getAudioCodec=function(r){var c=this.config.defaultAudioCodec||r.audioCodec;return this.audioCodecSwap&&(s.logger.log("swapping playlist audio codec"),c&&(c.indexOf("mp4a.40.5")!==-1?c="mp4a.40.2":c="mp4a.40.5")),c},Nc(h,[{key:"state",set:function(r){if(this.state!==r){var c=this.state;this._state=r,s.logger.log("main stream-controller: "+c+"->"+r),this.hls.trigger(l.default.STREAM_STATE_TRANSITION,{previousState:c,nextState:r})}},get:function(){return this._state}},{key:"currentLevel",get:function(){var r=this.media;if(r){var c=this.getBufferedFrag(r.currentTime);if(c)return c.level}return-1}},{key:"nextBufferedFrag",get:function(){var r=this.media;return r?this.followingBufferedFrag(this.getBufferedFrag(r.currentTime)):null}},{key:"nextLevel",get:function(){var r=this.nextBufferedFrag;return r?r.level:-1}},{key:"liveSyncPosition",get:function(){return this._liveSyncPosition},set:function(r){this._liveSyncPosition=r}}]),h}(yl),ef=pd;function $_(w,h){for(var f=0;f0){g=c[0].bitrate,c.sort(function(X,ye){return X.bitrate-ye.bitrate}),this._levels=c;for(var U=0;U=0&&r1&&H.loadError0){var c=this.currentLevelIndex,_=r.urlId,g=r.url[_];s.logger.log("Attempt loading level index "+c+" with URL-id "+_),this.hls.trigger(l.default.LEVEL_LOADING,{url:g,level:c,id:_})}}},z_(h,[{key:"levels",get:function(){return this._levels}},{key:"level",get:function(){return this.currentLevelIndex},set:function(r){var c=this._levels;c&&(r=Math.min(r,c.length-1),(this.currentLevelIndex!==r||!c[r].details)&&this.setLevelInternal(r))}},{key:"manualLevel",get:function(){return this.manualLevelIndex},set:function(r){this.manualLevelIndex=r,this._startLevel===void 0&&(this._startLevel=r),r!==-1&&(this.level=r)}},{key:"firstLevel",get:function(){return this._firstLevel},set:function(r){this._firstLevel=r}},{key:"startLevel",get:function(){if(this._startLevel===void 0){var r=this.hls.config.startLevel;return r!==void 0?r:this._firstLevel}else return this._startLevel},set:function(r){this._startLevel=r}},{key:"nextLoadLevel",get:function(){return this.manualLevelIndex!==-1?this.manualLevelIndex:this.hls.nextAutoLevel},set:function(r){this.level=r,this.manualLevelIndex===-1&&(this.hls.nextAutoLevel=r)}}]),h}(y),Q_=a("./src/demux/id3.js");function kD(w,h){var f;try{f=new Event("addtrack")}catch{f=document.createEvent("Event"),f.initEvent("addtrack",!1,!1)}f.track=w,h.dispatchEvent(f)}function Js(w){if(w&&w.cues)for(;w.cues.length>0;)w.removeCue(w.cues[0])}function fE(w,h){if(hw[w.length-1].endTime)return w[w.length-1];for(var f=0,v=w.length-1;f<=v;){var r=Math.floor((v+f)/2);if(hw[r].endTime)f=r+1;else return w[r]}return w[f].endTime-hH&&(s.logger.warn("detected an id3 sample with endTime < startTime, adjusting endTime to (startTime + 0.25)"),H=x+.25);for(var U=0;U=this.minWeight_},h.getEstimate=function(){return this.canEstimate()?Math.min(this.fast_.getEstimate(),this.slow_.getEstimate()):this.defaultEstimate_},h.destroy=function(){},w}(),hE=mE;function qD(w,h){for(var f=0;f500*_.duration/H){var U=r.levels,X=Math.max(1,F.bw?F.bw/8:F.loaded*1e3/x),ye=U[_.level],qe=ye.realBitrate?Math.max(ye.realBitrate,ye.bitrate):ye.bitrate,vn=F.total?F.total:Math.max(F.loaded,Math.round(_.duration*qe/8)),fa=c.currentTime,Zn=(vn-F.loaded)/X,la=(j.bufferInfo(c,fa,r.config.maxBufferHole).end-fa)/H;if(la<2*_.duration/H&&Zn>la){var Ra,Oa;for(Oa=_.level-1;Oa>C;Oa--){var Su=U[Oa].realBitrate?Math.max(U[Oa].realBitrate,U[Oa].bitrate):U[Oa].bitrate,jo=_.duration*Su/(8*.8*X);if(jo=g;X--){var ye=U[X];if(!!ye){var qe=ye.details,vn=qe?qe.totalduration/qe.fragments.length:c,fa=qe?qe.live:!1,Zn=void 0;X<=r?Zn=x*_:Zn=H*_;var la=U[X].realBitrate?Math.max(U[X].realBitrate,U[X].bitrate):U[X].bitrate,Ra=la*vn/Zn;if(s.logger.trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: "+X+"/"+Math.round(Zn)+"/"+la+"/"+vn+"/"+F+"/"+Ra),Zn>la&&(!Ra||fa&&!this.bitrateTestDelay||Ra=0)return vn;s.logger.trace("rebuffering expected to happen, lets try to find a quality level minimizing the rebuffering");var fa=H?Math.min(H,g.maxStarvationDelay):g.maxStarvationDelay,Zn=g.abrBandWidthFactor,la=g.abrBandWidthUpFactor;if(qe===0){var Ra=this.bitrateTestDelay;if(Ra){var Oa=H?Math.min(H,g.maxLoadingDelay):g.maxLoadingDelay;fa=Oa-Ra,s.logger.trace("bitrate test took "+Math.round(1e3*Ra)+"ms, set first fragment max fetchDuration to "+Math.round(1e3*fa)+" ms"),Zn=la=1}}return vn=this._findBestLevel(x,H,ye,C,c,qe+fa,Zn,la,_),Math.max(vn,0)}}]),h}(y),wE=yE;function bE(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var WD=J(),EE=function(w){bE(h,w);function h(v){var r;return r=w.call(this,v,l.default.MEDIA_ATTACHING,l.default.MEDIA_DETACHING,l.default.MANIFEST_PARSED,l.default.BUFFER_RESET,l.default.BUFFER_APPENDING,l.default.BUFFER_CODECS,l.default.BUFFER_EOS,l.default.BUFFER_FLUSHING,l.default.LEVEL_PTS_UPDATED,l.default.LEVEL_UPDATED)||this,r._msDuration=null,r._levelDuration=null,r._levelTargetDuration=10,r._live=null,r._objectUrl=null,r._needsFlush=!1,r._needsEos=!1,r.config=void 0,r.audioTimestampOffset=void 0,r.bufferCodecEventsExpected=0,r._bufferCodecEventsTotal=0,r.media=null,r.mediaSource=null,r.segments=[],r.parent=void 0,r.appending=!1,r.appended=0,r.appendError=0,r.flushBufferCounter=0,r.tracks={},r.pendingTracks={},r.sourceBuffer={},r.flushRange=[],r._onMediaSourceOpen=function(){s.logger.log("media source opened"),r.hls.trigger(l.default.MEDIA_ATTACHED,{media:r.media});var c=r.mediaSource;c&&c.removeEventListener("sourceopen",r._onMediaSourceOpen),r.checkPendingTracks()},r._onMediaSourceClose=function(){s.logger.log("media source closed")},r._onMediaSourceEnded=function(){s.logger.log("media source ended")},r._onSBUpdateEnd=function(){if(r.audioTimestampOffset&&r.sourceBuffer.audio){var c=r.sourceBuffer.audio;s.logger.warn("change mpeg audio timestamp offset from "+c.timestampOffset+" to "+r.audioTimestampOffset),c.timestampOffset=r.audioTimestampOffset,delete r.audioTimestampOffset}r._needsFlush&&r.doFlush(),r._needsEos&&r.checkEos(),r.appending=!1;var _=r.parent,g=r.segments.reduce(function(U,X){return X.parent===_?U+1:U},0),C={},F=r.sourceBuffer;for(var x in F){var H=F[x];if(!H)throw Error("handling source buffer update end error: source buffer for "+x+" uninitilized and unable to update buffered TimeRanges.");C[x]=H.buffered}r.hls.trigger(l.default.BUFFER_APPENDED,{parent:_,pending:g,timeRanges:C}),r._needsFlush||r.doAppending(),r.updateMediaElementDuration(),g===0&&r.flushLiveBackBuffer()},r._onSBUpdateError=function(c){s.logger.error("sourceBuffer error:",c),r.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.BUFFER_APPENDING_ERROR,fatal:!1})},r.config=v.config,r}var f=h.prototype;return f.destroy=function(){y.prototype.destroy.call(this)},f.onLevelPtsUpdated=function(r){var c=r.type,_=this.tracks.audio;if(c==="audio"&&_&&_.container==="audio/mpeg"){var g=this.sourceBuffer.audio;if(!g)throw Error("Level PTS Updated and source buffer for audio uninitalized");var C=Math.abs(g.timestampOffset-r.start);if(C>.1){var F=g.updating;try{g.abort()}catch(x){s.logger.warn("can not abort audio buffer: "+x)}F?this.audioTimestampOffset=r.start:(s.logger.warn("change mpeg audio timestamp offset from "+g.timestampOffset+" to "+r.start),g.timestampOffset=r.start)}}},f.onManifestParsed=function(r){this.bufferCodecEventsExpected=this._bufferCodecEventsTotal=r.altAudio?2:1,s.logger.log(this.bufferCodecEventsExpected+" bufferCodec event(s) expected")},f.onMediaAttaching=function(r){var c=this.media=r.media;if(c&&WD){var _=this.mediaSource=new WD;_.addEventListener("sourceopen",this._onMediaSourceOpen),_.addEventListener("sourceended",this._onMediaSourceEnded),_.addEventListener("sourceclose",this._onMediaSourceClose),c.src=window.URL.createObjectURL(_),this._objectUrl=c.src}},f.onMediaDetaching=function(){s.logger.log("media source detaching");var r=this.mediaSource;if(r){if(r.readyState==="open")try{r.endOfStream()}catch(c){s.logger.warn("onMediaDetaching:"+c.message+" while calling endOfStream")}r.removeEventListener("sourceopen",this._onMediaSourceOpen),r.removeEventListener("sourceended",this._onMediaSourceEnded),r.removeEventListener("sourceclose",this._onMediaSourceClose),this.media&&(this._objectUrl&&window.URL.revokeObjectURL(this._objectUrl),this.media.src===this._objectUrl?(this.media.removeAttribute("src"),this.media.load()):s.logger.warn("media.src was changed by a third party - skip cleanup")),this.mediaSource=null,this.media=null,this._objectUrl=null,this.bufferCodecEventsExpected=this._bufferCodecEventsTotal,this.pendingTracks={},this.tracks={},this.sourceBuffer={},this.flushRange=[],this.segments=[],this.appended=0}this.hls.trigger(l.default.MEDIA_DETACHED)},f.checkPendingTracks=function(){var r=this.bufferCodecEventsExpected,c=this.pendingTracks,_=Object.keys(c).length;(_&&!r||_===2)&&(this.createSourceBuffers(c),this.pendingTracks={},this.doAppending())},f.onBufferReset=function(){var r=this.sourceBuffer;for(var c in r){var _=r[c];try{_&&(this.mediaSource&&this.mediaSource.removeSourceBuffer(_),_.removeEventListener("updateend",this._onSBUpdateEnd),_.removeEventListener("error",this._onSBUpdateError))}catch{}}this.sourceBuffer={},this.flushRange=[],this.segments=[],this.appended=0},f.onBufferCodecs=function(r){var c=this;Object.keys(this.sourceBuffer).length||(Object.keys(r).forEach(function(_){c.pendingTracks[_]=r[_]}),this.bufferCodecEventsExpected=Math.max(this.bufferCodecEventsExpected-1,0),this.mediaSource&&this.mediaSource.readyState==="open"&&this.checkPendingTracks())},f.createSourceBuffers=function(r){var c=this.sourceBuffer,_=this.mediaSource;if(!_)throw Error("createSourceBuffers called when mediaSource was null");for(var g in r)if(!c[g]){var C=r[g];if(!C)throw Error("source buffer exists for track "+g+", however track does not");var F=C.levelCodec||C.codec,x=C.container+";codecs="+F;s.logger.log("creating sourceBuffer("+x+")");try{var H=c[g]=_.addSourceBuffer(x);H.addEventListener("updateend",this._onSBUpdateEnd),H.addEventListener("error",this._onSBUpdateError),this.tracks[g]={buffer:H,codec:F,id:C.id,container:C.container,levelCodec:C.levelCodec}}catch(U){s.logger.error("error while trying to add sourceBuffer:"+U.message),this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.BUFFER_ADD_CODEC_ERROR,fatal:!1,err:U,mimeType:x})}}this.hls.trigger(l.default.BUFFER_CREATED,{tracks:this.tracks})},f.onBufferAppending=function(r){this._needsFlush||(this.segments?this.segments.push(r):this.segments=[r],this.doAppending())},f.onBufferEos=function(r){for(var c in this.sourceBuffer)if(!r.type||r.type===c){var _=this.sourceBuffer[c];_&&!_.ended&&(_.ended=!0,s.logger.log(c+" sourceBuffer now EOS"))}this.checkEos()},f.checkEos=function(){var r=this.sourceBuffer,c=this.mediaSource;if(!c||c.readyState!=="open"){this._needsEos=!1;return}for(var _ in r){var g=r[_];if(!!g){if(!g.ended)return;if(g.updating){this._needsEos=!0;return}}}s.logger.log("all media data are available, signal endOfStream() to MediaSource and stop loading fragment");try{c.endOfStream()}catch{s.logger.warn("exception while calling mediaSource.endOfStream()")}this._needsEos=!1},f.onBufferFlushing=function(r){r.type?this.flushRange.push({start:r.startOffset,end:r.endOffset,type:r.type}):(this.flushRange.push({start:r.startOffset,end:r.endOffset,type:"video"}),this.flushRange.push({start:r.startOffset,end:r.endOffset,type:"audio"})),this.flushBufferCounter=0,this.doFlush()},f.flushLiveBackBuffer=function(){if(!!this._live){var r=this.config.liveBackBufferLength;if(!(!isFinite(r)||r<0)){if(!this.media){s.logger.error("flushLiveBackBuffer called without attaching media");return}for(var c=this.media.currentTime,_=this.sourceBuffer,g=Object.keys(_),C=c-Math.max(r,this._levelTargetDuration),F=g.length-1;F>=0;F--){var x=g[F],H=_[x];if(H){var U=H.buffered;U.length>0&&C>U.start(0)&&this.removeBufferRange(x,H,0,C)&&this.hls.trigger(l.default.LIVE_BACK_BUFFER_REACHED,{bufferEnd:C})}}}}},f.onLevelUpdated=function(r){var c=r.details;c.fragments.length>0&&(this._levelDuration=c.totalduration+c.fragments[0].start,this._levelTargetDuration=c.averagetargetduration||c.targetduration||10,this._live=c.live,this.updateMediaElementDuration())},f.updateMediaElementDuration=function(){var r=this.config,c;if(!(this._levelDuration===null||!this.media||!this.mediaSource||!this.sourceBuffer||this.media.readyState===0||this.mediaSource.readyState!=="open")){for(var _ in this.sourceBuffer){var g=this.sourceBuffer[_];if(g&&g.updating===!0)return}c=this.media.duration,this._msDuration===null&&(this._msDuration=this.mediaSource.duration),this._live===!0&&r.liveDurationInfinity===!0?(s.logger.log("Media Source duration is set to Infinity"),this._msDuration=this.mediaSource.duration=1/0):(this._levelDuration>this._msDuration&&this._levelDuration>c||!Object(i.isFiniteNumber)(c))&&(s.logger.log("Updating Media Source duration to "+this._levelDuration.toFixed(3)),this._msDuration=this.mediaSource.duration=this._levelDuration)}},f.doFlush=function(){for(;this.flushRange.length;){var r=this.flushRange[0];if(this.flushBuffer(r.start,r.end,r.type))this.flushRange.shift(),this.flushBufferCounter=0;else{this._needsFlush=!0;return}}if(this.flushRange.length===0){this._needsFlush=!1;var c=0,_=this.sourceBuffer;try{for(var g in _){var C=_[g];C&&(c+=C.buffered.length)}}catch{s.logger.error("error while accessing sourceBuffer.buffered")}this.appended=c,this.hls.trigger(l.default.BUFFER_FLUSHED)}},f.doAppending=function(){var r=this.config,c=this.hls,_=this.segments,g=this.sourceBuffer;if(!!Object.keys(g).length){if(!this.media||this.media.error){this.segments=[],s.logger.error("trying to append although a media error occured, flush segment and abort");return}if(!this.appending){var C=_.shift();if(!!C)try{var F=g[C.type];if(!F){this._onSBUpdateEnd();return}if(F.updating){_.unshift(C);return}F.ended=!1,this.parent=C.parent,F.appendBuffer(C.data),this.appendError=0,this.appended++,this.appending=!0}catch(H){s.logger.error("error while trying to append buffer:"+H.message),_.unshift(C);var x={type:u.ErrorTypes.MEDIA_ERROR,parent:C.parent,details:"",fatal:!1};H.code===22?(this.segments=[],x.details=u.ErrorDetails.BUFFER_FULL_ERROR):(this.appendError++,x.details=u.ErrorDetails.BUFFER_APPEND_ERROR,this.appendError>r.appendErrorMaxRetry&&(s.logger.log("fail "+r.appendErrorMaxRetry+" times to append segment in sourceBuffer"),this.segments=[],x.fatal=!0)),c.trigger(l.default.ERROR,x)}}}},f.flushBuffer=function(r,c,_){var g=this.sourceBuffer;if(!Object.keys(g).length)return!0;var C="null";if(this.media&&(C=this.media.currentTime.toFixed(3)),s.logger.log("flushBuffer,pos/start/end: "+C+"/"+r+"/"+c),this.flushBufferCounter>=this.appended)return s.logger.warn("abort flushing too many retries"),!0;var F=g[_];if(F){if(F.ended=!1,F.updating)return s.logger.warn("cannot flush, sb updating in progress"),!1;if(this.removeBufferRange(_,F,r,c))return this.flushBufferCounter++,!1}return s.logger.log("buffer flushed"),!0},f.removeBufferRange=function(r,c,_,g){try{for(var C=0;C.5){var X="null";return this.media&&(X=this.media.currentTime.toString()),s.logger.log("sb remove "+r+" ["+H+","+U+"], of ["+F+","+x+"], pos:"+X),c.remove(H,U),!0}}}catch(ye){s.logger.warn("removeBufferRange failed",ye)}return!1},h}(y),IE=EE;function $D(w,h){for(var f=0;fthis.autoLevelCapping&&c.streamController.nextLevelSwitch(),this.autoLevelCapping=c.autoLevelCapping}}},f.getMaxLevel=function(r){var c=this;if(!this.levels)return-1;var _=this.levels.filter(function(g,C){return h.isLevelAllowed(C,c.restrictedLevels)&&C<=r});return h.getMaxLevelByMediaSize(_,this.mediaWidth,this.mediaHeight)},f.startCapping=function(){this.timer||(this.autoLevelCapping=Number.POSITIVE_INFINITY,this.hls.firstLevel=this.getMaxLevel(this.firstLevel),clearInterval(this.timer),this.timer=setInterval(this.detectPlayerSize.bind(this),1e3),this.detectPlayerSize())},f.stopCapping=function(){this.restrictedLevels=[],this.firstLevel=null,this.autoLevelCapping=Number.POSITIVE_INFINITY,this.timer&&(this.timer=clearInterval(this.timer),this.timer=null)},h.isLevelAllowed=function(r,c){return c===void 0&&(c=[]),c.indexOf(r)===-1},h.getMaxLevelByMediaSize=function(r,c,_){if(!r||r&&!r.length)return-1;for(var g=function(U,X){return X?U.width!==X.width||U.height!==X.height:!0},C=r.length-1,F=0;F=c||x.height>=_)&&g(x,r[F+1])){C=F;break}}return C},TE(h,[{key:"mediaWidth",get:function(){var r,c=this.media;return c&&(r=c.width||c.clientWidth||c.offsetWidth,r*=h.contentScaleFactor),r}},{key:"mediaHeight",get:function(){var r,c=this.media;return c&&(r=c.height||c.clientHeight||c.offsetHeight,r*=h.contentScaleFactor),r}}],[{key:"contentScaleFactor",get:function(){var r=1;try{r=window.devicePixelRatio}catch{}return r}}]),h}(y),zD=SE;function CE(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var Oc=window,FE=Oc.performance,Dd=function(w){CE(h,w);function h(v){return w.call(this,v,l.default.MEDIA_ATTACHING)||this}var f=h.prototype;return f.destroy=function(){this.timer&&clearInterval(this.timer),this.isVideoPlaybackQualityAvailable=!1},f.onMediaAttaching=function(r){var c=this.hls.config;if(c.capLevelOnFPSDrop){var _=this.video=r.media instanceof window.HTMLVideoElement?r.media:null;typeof _.getVideoPlaybackQuality=="function"&&(this.isVideoPlaybackQualityAvailable=!0),clearInterval(this.timer),this.timer=setInterval(this.checkFPSInterval.bind(this),c.fpsDroppedMonitoringPeriod)}},f.checkFPS=function(r,c,_){var g=FE.now();if(c){if(this.lastTime){var C=g-this.lastTime,F=_-this.lastDroppedFrames,x=c-this.lastDecodedFrames,H=1e3*F/C,U=this.hls;if(U.trigger(l.default.FPS_DROP,{currentDropped:F,currentDecoded:x,totalDroppedFrames:_}),H>0&&F>U.config.fpsDroppedMonitoringThreshold*x){var X=U.currentLevel;s.logger.warn("drop FPS ratio greater than max allowed value for currentLevel: "+X),X>0&&(U.autoLevelCapping===-1||U.autoLevelCapping>=X)&&(X=X-1,U.trigger(l.default.FPS_DROP_LEVEL_CAPPING,{level:X,droppedLevel:U.currentLevel}),U.autoLevelCapping=X,U.streamController.nextLevelSwitch())}}this.lastTime=g,this.lastDroppedFrames=_,this.lastDecodedFrames=c}},f.checkFPSInterval=function(){var r=this.video;if(r)if(this.isVideoPlaybackQualityAvailable){var c=r.getVideoPlaybackQuality();this.checkFPS(r,c.totalVideoFrames,c.droppedVideoFrames)}else this.checkFPS(r,r.webkitDecodedFrameCount,r.webkitDroppedFrameCount)},h}(y),GE=Dd,VD=window,gd=VD.performance,ME=VD.XMLHttpRequest,AE=function(){function w(f){f&&f.xhrSetup&&(this.xhrSetup=f.xhrSetup)}var h=w.prototype;return h.destroy=function(){this.abort(),this.loader=null},h.abort=function(){var v=this.loader;v&&v.readyState!==4&&(this.stats.aborted=!0,v.abort()),window.clearTimeout(this.requestTimeout),this.requestTimeout=null,window.clearTimeout(this.retryTimeout),this.retryTimeout=null},h.load=function(v,r,c){this.context=v,this.config=r,this.callbacks=c,this.stats={trequest:gd.now(),retry:0},this.retryDelay=r.retryDelay,this.loadInternal()},h.loadInternal=function(){var v,r=this.context;v=this.loader=new ME;var c=this.stats;c.tfirst=0,c.loaded=0;var _=this.xhrSetup;try{if(_)try{_(v,r.url)}catch{v.open("GET",r.url,!0),_(v,r.url)}v.readyState||v.open("GET",r.url,!0)}catch(g){this.callbacks.onError({code:v.status,text:g.message},r,v);return}r.rangeEnd&&v.setRequestHeader("Range","bytes="+r.rangeStart+"-"+(r.rangeEnd-1)),v.onreadystatechange=this.readystatechange.bind(this),v.onprogress=this.loadprogress.bind(this),v.responseType=r.responseType,this.requestTimeout=window.setTimeout(this.loadtimeout.bind(this),this.config.timeout),v.send()},h.readystatechange=function(v){var r=v.currentTarget,c=r.readyState,_=this.stats,g=this.context,C=this.config;if(!_.aborted&&c>=2)if(window.clearTimeout(this.requestTimeout),_.tfirst===0&&(_.tfirst=Math.max(gd.now(),_.trequest)),c===4){var F=r.status;if(F>=200&&F<300){_.tload=Math.max(_.tfirst,gd.now());var x,H;g.responseType==="arraybuffer"?(x=r.response,H=x.byteLength):(x=r.responseText,H=x.length),_.loaded=_.total=H;var U={url:r.responseURL,data:x};this.callbacks.onSuccess(U,_,g,r)}else _.retry>=C.maxRetry||F>=400&&F<499?(s.logger.error(F+" while loading "+g.url),this.callbacks.onError({code:F,text:r.statusText},g,r)):(s.logger.warn(F+" while loading "+g.url+", retrying in "+this.retryDelay+"..."),this.destroy(),this.retryTimeout=window.setTimeout(this.loadInternal.bind(this),this.retryDelay),this.retryDelay=Math.min(2*this.retryDelay,C.maxRetryDelay),_.retry++)}else this.requestTimeout=window.setTimeout(this.loadtimeout.bind(this),C.timeout)},h.loadtimeout=function(){s.logger.warn("timeout while loading "+this.context.url),this.callbacks.onTimeout(this.stats,this.context,null)},h.loadprogress=function(v){var r=v.currentTarget,c=this.stats;c.loaded=v.loaded,v.lengthComputable&&(c.total=v.total);var _=this.callbacks.onProgress;_&&_(c,this.context,null,r)},w}(),Rd=AE;function QD(w,h){for(var f=0;f=this.tracks.length){s.logger.warn("Invalid audio track id:",r.id);return}if(s.logger.log("audioTrack "+r.id+" loaded"),this.tracks[r.id].details=r.details,r.details.live&&!this.hasInterval()){var c=r.details.targetduration*1e3;this.setInterval(c)}!r.details.live&&this.hasInterval()&&this.clearInterval()},f.onAudioTrackSwitched=function(r){var c=this.tracks[r.id].groupId;c&&this.audioGroupId!==c&&(this.audioGroupId=c)},f.onLevelLoaded=function(r){this._selectAudioGroup(r.level)},f.onError=function(r){r.type===u.ErrorTypes.NETWORK_ERROR&&(r.fatal&&this.clearInterval(),r.details===u.ErrorDetails.AUDIO_TRACK_LOAD_ERROR&&(s.logger.warn("Network failure on audio-track id:",r.context.id),this._handleLoadError()))},f._setAudioTrack=function(r){if(this._trackId===r&&this.tracks[this._trackId].details){s.logger.debug("Same id as current audio-track passed, and track details available -> no-op");return}if(r<0||r>=this.tracks.length){s.logger.warn("Invalid id passed to audio-track controller");return}var c=this.tracks[r];s.logger.log("Now switching to audio-track index "+r),this.clearInterval(),this._trackId=r;var _=c.url,g=c.type,C=c.id;this.hls.trigger(l.default.AUDIO_TRACK_SWITCHING,{id:C,type:g,url:_}),this._loadTrackDetailsIfNeeded(c)},f.doTick=function(){this._updateTrack(this._trackId)},f._selectAudioGroup=function(r){var c=this.hls.levels[r];if(!(!c||!c.audioGroupIds)){var _=c.audioGroupIds[c.urlId];this.audioGroupId!==_&&(this.audioGroupId=_,this._selectInitialAudioTrack())}},f._selectInitialAudioTrack=function(){var r=this,c=this.tracks;if(!!c.length){var _=this.tracks[this._trackId],g=null;if(_&&(g=_.name),this._selectDefaultTrack){var C=c.filter(function(H){return H.default});C.length?c=C:s.logger.warn("No default audio tracks defined")}var F=!1,x=function(){c.forEach(function(U){F||(!r.audioGroupId||U.groupId===r.audioGroupId)&&(!g||g===U.name)&&(r._setAudioTrack(U.id),F=!0)})};x(),F||(g=null,x()),F||(s.logger.error("No track found for running audio group-ID: "+this.audioGroupId),this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,fatal:!0}))}},f._needsTrackLoading=function(r){var c=r.details,_=r.url;return!c||c.live?!!_:!1},f._loadTrackDetailsIfNeeded=function(r){if(this._needsTrackLoading(r)){var c=r.url,_=r.id;s.logger.log("loading audio-track playlist for id: "+_),this.hls.trigger(l.default.AUDIO_TRACK_LOADING,{url:c,id:_})}},f._updateTrack=function(r){if(!(r<0||r>=this.tracks.length)){this.clearInterval(),this._trackId=r,s.logger.log("trying to update audio-track "+r);var c=this.tracks[r];this._loadTrackDetailsIfNeeded(c)}},f._handleLoadError=function(){this.trackIdBlacklist[this._trackId]=!0;var r=this._trackId,c=this.tracks[r],_=c.name,g=c.language,C=c.groupId;s.logger.warn("Loading failed on audio track id: "+r+", group-id: "+C+', name/language: "'+_+'" / "'+g+'"');for(var F=r,x=0;x0&&r===-1?(s.logger.log("audio:override startPosition with lastCurrentTime @"+c.toFixed(3)),this.state=se.IDLE):(this.lastCurrentTime=this.startPosition?this.startPosition:r,this.state=se.STARTING),this.nextLoadPosition=this.startPosition=this.lastCurrentTime,this.tick()}else this.startPosition=r,this.state=se.STOPPED},f.doTick=function(){var r,c,_,g=this.hls,C=g.config;switch(this.state){case se.ERROR:case se.PAUSED:case se.BUFFER_FLUSHING:break;case se.STARTING:this.state=se.WAITING_TRACK,this.loadedmetadata=!1;break;case se.IDLE:var F=this.tracks;if(!F||!this.media&&(this.startFragRequested||!C.startFragPrefetch))break;if(this.loadedmetadata)r=this.media.currentTime;else if(r=this.nextLoadPosition,r===void 0)break;var x=this.mediaBuffer?this.mediaBuffer:this.media,H=this.videoBuffer?this.videoBuffer:this.media,U=j.bufferInfo(x,r,C.maxBufferHole),X=j.bufferInfo(H,r,C.maxBufferHole),ye=U.len,qe=U.end,vn=this.fragPrevious,fa=Math.min(C.maxBufferLength,C.maxMaxBufferLength),Zn=Math.max(fa,X.len),la=this.audioSwitch,Ra=this.trackId;if((yejo||U.nextStart)s.logger.log("alt audio track ahead of main track, seek to start of alt audio track"),this.media.currentTime=jo+.05;else return}if(_.initSegment&&!_.initSegment.data)ct=_.initSegment;else if(qe<=jo){if(ct=Oa[0],this.videoTrackCC!==null&&ct.cc!==this.videoTrackCC&&(ct=Ot(Oa,this.videoTrackCC)),_.live&&ct.loadIdx&&ct.loadIdx===this.fragLoadIdx){var dt=U.nextStart?U.nextStart:jo;s.logger.log("no alt audio available @currentTime:"+this.media.currentTime+", seeking @"+(dt+.05)),this.media.currentTime=dt+.05;return}}else{var xa,Eo=C.maxFragLookUpTolerance,e0=vn?Oa[vn.sn-Oa[0].sn+1]:void 0,n0=function(Cd){var CL=Math.min(Eo,Cd.duration);return Cd.start+Cd.duration-CL<=qe?1:Cd.start-CL>qe&&Cd.start?-1:0};qeOi-Eo&&(Eo=0),e0&&!n0(e0)?xa=e0:xa=K.search(Oa,n0)):xa=Oa[Su-1],xa&&(ct=xa,jo=xa.start,vn&&ct.level===vn.level&&ct.sn===vn.sn&&(ct.sn<_.endSN?(ct=Oa[ct.sn+1-_.startSN],s.logger.log("SN just loaded, load next one: "+ct.sn)):ct=null))}ct&&(ct.encrypted?(s.logger.log("Loading key for "+ct.sn+" of ["+_.startSN+" ,"+_.endSN+"],track "+Ra),this.state=se.KEY_LOADING,g.trigger(l.default.KEY_LOADING,{frag:ct})):(s.logger.log("Loading "+ct.sn+", cc: "+ct.cc+" of ["+_.startSN+" ,"+_.endSN+"],track "+Ra+", currentTime:"+r+",bufferEnd:"+qe.toFixed(3)),this.fragCurrent=ct,(la||this.fragmentTracker.getState(ct)===Da.NOT_LOADED)&&(ct.sn!=="initSegment"&&(this.startFragRequested=!0),Object(i.isFiniteNumber)(ct.sn)&&(this.nextLoadPosition=ct.start+ct.duration),g.trigger(l.default.FRAG_LOADING,{frag:ct}),this.state=se.FRAG_LOADING)))}break;case se.WAITING_TRACK:c=this.tracks[this.trackId],c&&c.details&&(this.state=se.IDLE);break;case se.FRAG_LOADING_WAITING_RETRY:var fI=El.now(),IL=this.retryDate;x=this.media;var QK=x&&x.seeking;(!IL||fI>=IL||QK)&&(s.logger.log("audioStreamController: retryDate reached, switch back to IDLE state"),this.state=se.IDLE);break;case se.WAITING_INIT_PTS:var _I=this.videoTrackCC;if(this.initPTS[_I]===void 0)break;var TL=this.waitingFragment;if(TL){var SL=TL.frag.cc;_I!==SL?(c=this.tracks[this.trackId],c.details&&c.details.live&&(s.logger.warn("Waiting fragment CC ("+SL+") does not match video track CC ("+_I+")"),this.waitingFragment=null,this.state=se.IDLE)):(this.state=se.FRAG_LOADING,this.onFragLoaded(this.waitingFragment),this.waitingFragment=null)}else this.state=se.IDLE;break;case se.STOPPED:case se.FRAG_LOADING:case se.PARSING:case se.PARSED:case se.ENDED:break;default:break}},f.onMediaAttached=function(r){var c=this.media=this.mediaBuffer=r.media;this.onvseeking=this.onMediaSeeking.bind(this),this.onvended=this.onMediaEnded.bind(this),c.addEventListener("seeking",this.onvseeking),c.addEventListener("ended",this.onvended);var _=this.config;this.tracks&&_.autoStartLoad&&this.startLoad(_.startPosition)},f.onMediaDetaching=function(){var r=this.media;r&&r.ended&&(s.logger.log("MSE detaching and video ended, reset startPosition"),this.startPosition=this.lastCurrentTime=0),r&&(r.removeEventListener("seeking",this.onvseeking),r.removeEventListener("ended",this.onvended),this.onvseeking=this.onvseeked=this.onvended=null),this.media=this.mediaBuffer=this.videoBuffer=null,this.loadedmetadata=!1,this.fragmentTracker.removeAllFragments(),this.stopLoad()},f.onAudioTracksUpdated=function(r){s.logger.log("audio tracks updated"),this.tracks=r.audioTracks},f.onAudioTrackSwitching=function(r){var c=!!r.url;this.trackId=r.id,this.fragCurrent=null,this.state=se.PAUSED,this.waitingFragment=null,c?this.setInterval(XD):this.demuxer&&(this.demuxer.destroy(),this.demuxer=null),c&&(this.audioSwitch=!0,this.state=se.IDLE),this.tick()},f.onAudioTrackLoaded=function(r){var c=r.details,_=r.id,g=this.tracks[_],C=c.totalduration,F=0;if(s.logger.log("track "+_+" loaded ["+c.startSN+","+c.endSN+"],duration:"+C),c.live){var x=g.details;x&&c.fragments.length>0?(Rn(x,c),F=c.fragments[0].start,c.PTSKnown?s.logger.log("live audio playlist sliding:"+F.toFixed(3)):s.logger.log("live audio playlist - outdated PTS, unknown sliding")):(c.PTSKnown=!1,s.logger.log("live audio playlist - first load, unknown sliding"))}else c.PTSKnown=!1;if(g.details=c,!this.startFragRequested){if(this.startPosition===-1){var H=c.startTimeOffset;Object(i.isFiniteNumber)(H)?(s.logger.log("start time offset found in playlist, adjust startPosition to "+H),this.startPosition=H):c.live?(this.startPosition=this.computeLivePosition(F,c),s.logger.log("compute startPosition for audio-track to "+this.startPosition)):this.startPosition=0}this.nextLoadPosition=this.startPosition}this.state===se.WAITING_TRACK&&(this.state=se.IDLE),this.tick()},f.onKeyLoaded=function(){this.state===se.KEY_LOADING&&(this.state=se.IDLE,this.tick())},f.onFragLoaded=function(r){var c=this.fragCurrent,_=r.frag;if(this.state===se.FRAG_LOADING&&c&&_.type==="audio"&&_.level===c.level&&_.sn===c.sn){var g=this.tracks[this.trackId],C=g.details,F=C.totalduration,x=c.level,H=c.sn,U=c.cc,X=this.config.defaultAudioCodec||g.audioCodec||"mp4a.40.2",ye=this.stats=r.stats;if(H==="initSegment")this.state=se.IDLE,ye.tparsed=ye.tbuffered=El.now(),C.initSegment.data=r.payload,this.hls.trigger(l.default.FRAG_BUFFERED,{stats:ye,frag:c,id:"audio"}),this.tick();else{this.state=se.PARSING,this.appended=!1,this.demuxer||(this.demuxer=new Ge(this.hls,"audio"));var qe=this.initPTS[U],vn=C.initSegment?C.initSegment.data:[];if(C.initSegment||qe!==void 0){this.pendingBuffering=!0,s.logger.log("Demuxing "+H+" of ["+C.startSN+" ,"+C.endSN+"],track "+x);var fa=!1;this.demuxer.push(r.payload,vn,X,null,c,F,fa,qe)}else s.logger.log("unknown video PTS for continuity counter "+U+", waiting for video PTS before demuxing audio frag "+H+" of ["+C.startSN+" ,"+C.endSN+"],track "+x),this.waitingFragment=r,this.state=se.WAITING_INIT_PTS}}this.fragLoadError=0},f.onFragParsingInitSegment=function(r){var c=this.fragCurrent,_=r.frag;if(c&&r.id==="audio"&&_.sn===c.sn&&_.level===c.level&&this.state===se.PARSING){var g=r.tracks,C;if(g.video&&delete g.video,C=g.audio,C){C.levelCodec=C.codec,C.id=r.id,this.hls.trigger(l.default.BUFFER_CODECS,g),s.logger.log("audio track:audio,container:"+C.container+",codecs[level/parsed]=["+C.levelCodec+"/"+C.codec+"]");var F=C.initSegment;if(F){var x={type:"audio",data:F,parent:"audio",content:"initSegment"};this.audioSwitch?this.pendingData=[x]:(this.appended=!0,this.pendingBuffering=!0,this.hls.trigger(l.default.BUFFER_APPENDING,x))}this.tick()}}},f.onFragParsingData=function(r){var c=this,_=this.fragCurrent,g=r.frag;if(_&&r.id==="audio"&&r.type==="audio"&&g.sn===_.sn&&g.level===_.level&&this.state===se.PARSING){var C=this.trackId,F=this.tracks[C],x=this.hls;Object(i.isFiniteNumber)(r.endPTS)||(r.endPTS=r.startPTS+_.duration,r.endDTS=r.startDTS+_.duration),_.addElementaryStream(oe.AUDIO),s.logger.log("parsed "+r.type+",PTS:["+r.startPTS.toFixed(3)+","+r.endPTS.toFixed(3)+"],DTS:["+r.startDTS.toFixed(3)+"/"+r.endDTS.toFixed(3)+"],nb:"+r.nb),Pe(F.details,_,r.startPTS,r.endPTS);var H=this.audioSwitch,U=this.media,X=!1;if(H)if(U&&U.readyState){var ye=U.currentTime;s.logger.log("switching audio track : currentTime:"+ye),ye>=r.startPTS&&(s.logger.log("switching audio track : flushing all audio"),this.state=se.BUFFER_FLUSHING,x.trigger(l.default.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"}),X=!0,this.audioSwitch=!1,x.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:C}))}else this.audioSwitch=!1,x.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:C});var qe=this.pendingData;if(!qe){s.logger.warn("Apparently attempt to enqueue media payload without codec initialization data upfront"),x.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:null,fatal:!0});return}this.audioSwitch||([r.data1,r.data2].forEach(function(vn){vn&&vn.length&&qe.push({type:r.type,data:vn,parent:"audio",content:"data"})}),!X&&qe.length&&(qe.forEach(function(vn){c.state===se.PARSING&&(c.pendingBuffering=!0,c.hls.trigger(l.default.BUFFER_APPENDING,vn))}),this.pendingData=[],this.appended=!0)),this.tick()}},f.onFragParsed=function(r){var c=this.fragCurrent,_=r.frag;c&&r.id==="audio"&&_.sn===c.sn&&_.level===c.level&&this.state===se.PARSING&&(this.stats.tparsed=El.now(),this.state=se.PARSED,this._checkAppendedParsed())},f.onBufferReset=function(){this.mediaBuffer=this.videoBuffer=null,this.loadedmetadata=!1},f.onBufferCreated=function(r){var c=r.tracks.audio;c&&(this.mediaBuffer=c.buffer,this.loadedmetadata=!0),r.tracks.video&&(this.videoBuffer=r.tracks.video.buffer)},f.onBufferAppended=function(r){if(r.parent==="audio"){var c=this.state;(c===se.PARSING||c===se.PARSED)&&(this.pendingBuffering=r.pending>0,this._checkAppendedParsed())}},f._checkAppendedParsed=function(){if(this.state===se.PARSED&&(!this.appended||!this.pendingBuffering)){var r=this.fragCurrent,c=this.stats,_=this.hls;if(r){this.fragPrevious=r,c.tbuffered=El.now(),_.trigger(l.default.FRAG_BUFFERED,{stats:c,frag:r,id:"audio"});var g=this.mediaBuffer?this.mediaBuffer:this.media;g&&s.logger.log("audio buffered : "+pt.toString(g.buffered)),this.audioSwitch&&this.appended&&(this.audioSwitch=!1,_.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:this.trackId})),this.state=se.IDLE}this.tick()}},f.onError=function(r){var c=r.frag;if(!(c&&c.type!=="audio"))switch(r.details){case u.ErrorDetails.FRAG_LOAD_ERROR:case u.ErrorDetails.FRAG_LOAD_TIMEOUT:var _=r.frag;if(_&&_.type!=="audio")break;if(!r.fatal){var g=this.fragLoadError;g?g++:g=1;var C=this.config;if(g<=C.fragLoadingMaxRetry){this.fragLoadError=g;var F=Math.min(Math.pow(2,g-1)*C.fragLoadingRetryDelay,C.fragLoadingMaxRetryTimeout);s.logger.warn("AudioStreamController: frag loading failed, retry in "+F+" ms"),this.retryDate=El.now()+F,this.state=se.FRAG_LOADING_WAITING_RETRY}else s.logger.error("AudioStreamController: "+r.details+" reaches max retry, redispatch as fatal ..."),r.fatal=!0,this.state=se.ERROR}break;case u.ErrorDetails.AUDIO_TRACK_LOAD_ERROR:case u.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:case u.ErrorDetails.KEY_LOAD_ERROR:case u.ErrorDetails.KEY_LOAD_TIMEOUT:this.state!==se.ERROR&&(this.state=r.fatal?se.ERROR:se.IDLE,s.logger.warn("AudioStreamController: "+r.details+" while loading frag, now switching to "+this.state+" state ..."));break;case u.ErrorDetails.BUFFER_FULL_ERROR:if(r.parent==="audio"&&(this.state===se.PARSING||this.state===se.PARSED)){var x=this.mediaBuffer,H=this.media.currentTime,U=x&&j.isBuffered(x,H)&&j.isBuffered(x,H+.5);if(U){var X=this.config;X.maxMaxBufferLength>=X.maxBufferLength&&(X.maxMaxBufferLength/=2,s.logger.warn("AudioStreamController: reduce max buffer length to "+X.maxMaxBufferLength+"s")),this.state=se.IDLE}else s.logger.warn("AudioStreamController: buffer full error also media.currentTime is not buffered, flush audio buffer"),this.fragCurrent=null,this.state=se.BUFFER_FLUSHING,this.hls.trigger(l.default.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"})}break;default:break}},f.onBufferFlushed=function(){var r=this,c=this.pendingData;c&&c.length?(s.logger.log("AudioStreamController: appending pending audio data after buffer flushed"),c.forEach(function(_){r.hls.trigger(l.default.BUFFER_APPENDING,_)}),this.appended=!0,this.pendingData=[],this.state=se.PARSED):(this.state=se.IDLE,this.fragPrevious=null,this.tick())},nf(h,[{key:"state",set:function(r){if(this.state!==r){var c=this.state;this._state=r,s.logger.log("audio stream:"+c+"->"+r)}},get:function(){return this._state}}]),h}(yl),OE=jE,ZD=function(){if(typeof window!="undefined"&&window.VTTCue)return window.VTTCue;var w="auto",h={"":!0,lr:!0,rl:!0},f={start:!0,middle:!0,end:!0,left:!0,right:!0};function v(g){if(typeof g!="string")return!1;var C=h[g.toLowerCase()];return C?g.toLowerCase():!1}function r(g){if(typeof g!="string")return!1;var C=f[g.toLowerCase()];return C?g.toLowerCase():!1}function c(g){for(var C=1;C100)throw new Error("Position must be between 0 and 100.");Su=xa,this.hasBeenReset=!0}})),Object.defineProperty(x,"positionAlign",c({},H,{get:function(){return jo},set:function(xa){var Eo=r(xa);if(!Eo)throw new SyntaxError("An invalid or illegal string was specified.");jo=Eo,this.hasBeenReset=!0}})),Object.defineProperty(x,"size",c({},H,{get:function(){return Oi},set:function(xa){if(xa<0||xa>100)throw new Error("Size must be between 0 and 100.");Oi=xa,this.hasBeenReset=!0}})),Object.defineProperty(x,"align",c({},H,{get:function(){return ct},set:function(xa){var Eo=r(xa);if(!Eo)throw new SyntaxError("An invalid or illegal string was specified.");ct=Eo,this.hasBeenReset=!0}})),x.displayState=void 0}return _.prototype.getCueAsHTML=function(){var g=window.WebVTT;return g.convertCueToDOMTree(window,this.text)},_}(),UE=function(){return{decode:function(f){if(!f)return"";if(typeof f!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(f))}}};function eg(){this.window=window,this.state="INITIAL",this.buffer="",this.decoder=new UE,this.regionList=[]}function kE(w){function h(v,r,c,_){return(v|0)*3600+(r|0)*60+(c|0)+(_|0)/1e3}var f=w.match(/^(\d+):(\d{2})(:\d{2})?\.(\d{3})/);return f?f[3]?h(f[1],f[2],f[3].replace(":",""),f[4]):f[1]>59?h(f[1],f[2],0,f[4]):h(0,f[1],f[2],f[4]):null}function ng(){this.values=Object.create(null)}ng.prototype={set:function(h,f){!this.get(h)&&f!==""&&(this.values[h]=f)},get:function(h,f,v){return v?this.has(h)?this.values[h]:f[v]:this.has(h)?this.values[h]:f},has:function(h){return h in this.values},alt:function(h,f,v){for(var r=0;r=0&&f<=100)?(this.set(h,f),!0):!1}};function ag(w,h,f,v){var r=v?w.split(v):[w];for(var c in r)if(typeof r[c]=="string"){var _=r[c].split(f);if(_.length===2){var g=_[0],C=_[1];h(g,C)}}}var af=new ZD(0,0,0),ji=af.align==="middle"?"middle":"center";function BE(w,h,f){var v=w;function r(){var g=kE(w);if(g===null)throw new Error("Malformed timestamp: "+v);return w=w.replace(/^[^\sa-zA-Z-]+/,""),g}function c(g,C){var F=new ng;ag(g,function(U,X){switch(U){case"region":for(var ye=f.length-1;ye>=0;ye--)if(f[ye].id===X){F.set(U,f[ye].region);break}break;case"vertical":F.alt(U,X,["rl","lr"]);break;case"line":var qe=X.split(","),vn=qe[0];F.integer(U,vn),F.percent(U,vn)&&F.set("snapToLines",!1),F.alt(U,vn,["auto"]),qe.length===2&&F.alt("lineAlign",qe[1],["start",ji,"end"]);break;case"position":qe=X.split(","),F.percent(U,qe[0]),qe.length===2&&F.alt("positionAlign",qe[1],["start",ji,"end","line-left","line-right","auto"]);break;case"size":F.percent(U,X);break;case"align":F.alt(U,X,["start",ji,"end","left","right"]);break}},/:/,/\s/),C.region=F.get("region",null),C.vertical=F.get("vertical","");var x=F.get("line","auto");x==="auto"&&af.line===-1&&(x=-1),C.line=x,C.lineAlign=F.get("lineAlign","start"),C.snapToLines=F.get("snapToLines",!0),C.size=F.get("size",100),C.align=F.get("align",ji);var H=F.get("position","auto");H==="auto"&&af.position===50&&(H=C.align==="start"||C.align==="left"?0:C.align==="end"||C.align==="right"?100:50),C.position=H}function _(){w=w.replace(/^\s+/,"")}if(_(),h.startTime=r(),_(),w.substr(0,3)!=="-->")throw new Error("Malformed time stamp (time stamps must be separated by '-->'): "+v);w=w.substr(3),_(),h.endTime=r(),_(),c(w,h)}function tg(w){return w.replace(//gi,` `)}eg.prototype={parse:function(h){var f=this;h&&(f.buffer+=f.decoder.decode(h,{stream:!0}));function v(){var F=f.buffer,x=0;for(F=tg(F);x")===-1){f.cue.id=c;continue}case"CUE":try{BE(c,f.cue,f.regionList)}catch{f.cue=null,f.state="BADCUE";continue}f.state="CUETEXT";continue;case"CUETEXT":var C=c.indexOf("-->")!==-1;if(!c||C&&(g=!0)){f.oncue&&f.oncue(f.cue),f.cue=null,f.state="ID";continue}f.cue.text&&(f.cue.text+=` `),f.cue.text+=c;continue;case"BADCUE":c||(f.state="ID");continue}}}catch{f.state==="CUETEXT"&&f.cue&&f.oncue&&f.oncue(f.cue),f.cue=null,f.state=f.state==="INITIAL"?"BADWEBVTT":"BADCUE"}return this},flush:function(){var h=this;try{if(h.buffer+=h.decoder.decode(),(h.cue||h.state==="HEADER")&&(h.buffer+=` `,h.parse()),h.state==="INITIAL")throw new Error("Malformed WebVTT signature.")}catch(f){throw f}return h.onflush&&h.onflush(),this}};var HE=eg;function qE(w,h,f,v){for(var r,c,_,g,C,F=window.VTTCue||TextTrackCue,x=0;x=16?g--:g++,navigator.userAgent.match(/Firefox\//)?c.line=x+1:c.line=x>7?x-2:x+1,c.align="left",c.position=Math.max(0,Math.min(100,100*(g/32))),w.addCue(c)}}var yd={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,128:174,129:176,130:189,131:191,132:8482,133:162,134:163,135:9834,136:224,137:32,138:232,139:226,140:234,141:238,142:244,143:251,144:193,145:201,146:211,147:218,148:220,149:252,150:8216,151:161,152:42,153:8217,154:9473,155:169,156:8480,157:8226,158:8220,159:8221,160:192,161:194,162:199,163:200,164:202,165:203,166:235,167:206,168:207,169:239,170:212,171:217,172:249,173:219,174:171,175:187,176:195,177:227,178:205,179:204,180:236,181:210,182:242,183:213,184:245,185:123,186:125,187:92,188:94,189:95,190:124,191:8764,192:196,193:228,194:214,195:246,196:223,197:165,198:164,199:9475,200:197,201:229,202:216,203:248,204:9487,205:9491,206:9495,207:9499},rg=function(h){var f=h;return yd.hasOwnProperty(h)&&(f=yd[h]),String.fromCharCode(f)},Tu=15,Il=100,JE={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},WE={17:2,18:4,21:6,22:8,23:10,19:13,20:15},$E={25:1,26:3,29:5,30:7,31:9,24:11,27:12,28:14},zE={25:2,26:4,29:6,30:8,31:10,27:13,28:15},VE=["white","green","blue","cyan","red","yellow","magenta","black","transparent"],og;(function(w){w[w.ERROR=0]="ERROR",w[w.TEXT=1]="TEXT",w[w.WARNING=2]="WARNING",w[w.INFO=2]="INFO",w[w.DEBUG=3]="DEBUG",w[w.DATA=3]="DATA"})(og||(og={}));var Ha={verboseFilter:{DATA:3,DEBUG:3,INFO:2,WARNING:2,TEXT:1,ERROR:0},time:null,verboseLevel:0,setTime:function(h){this.time=h},log:function(h,f){var v=this.verboseFilter[h];this.verboseLevel>=v}},Uc=function(h){for(var f=[],v=0;vIl&&(Ha.log("ERROR","Too large cursor position "+this.pos),this.pos=Il)},h.moveCursor=function(v){var r=this.pos+v;if(v>1)for(var c=this.pos+1;c=144&&this.backSpace();var r=rg(v);if(this.pos>=Il){Ha.log("ERROR","Cannot insert "+v.toString(16)+" ("+r+") at position "+this.pos+". Skipping it!");return}this.chars[this.pos].setChar(r,this.currPenState),this.moveCursor(1)},h.clearFromPos=function(v){var r;for(r=v;r0&&(v?c="["+r.join(" | ")+"]":c=r.join(` `)),c},h.getTextAndFormat=function(){return this.rows},w}(),Y_=function(){function w(f,v){this.chNr=void 0,this.outputFilter=void 0,this.mode=void 0,this.verbose=void 0,this.displayedMemory=void 0,this.nonDisplayedMemory=void 0,this.lastOutputScreen=void 0,this.currRollUpRow=void 0,this.writeScreen=void 0,this.cueStartTime=void 0,this.lastCueEndTime=void 0,this.chNr=f,this.outputFilter=v,this.mode=null,this.verbose=0,this.displayedMemory=new qa,this.nonDisplayedMemory=new qa,this.lastOutputScreen=new qa,this.currRollUpRow=this.displayedMemory.rows[Tu-1],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null}var h=w.prototype;return h.reset=function(){this.mode=null,this.displayedMemory.reset(),this.nonDisplayedMemory.reset(),this.lastOutputScreen.reset(),this.currRollUpRow=this.displayedMemory.rows[Tu-1],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null},h.getHandler=function(){return this.outputFilter},h.setHandler=function(v){this.outputFilter=v},h.setPAC=function(v){this.writeScreen.setPAC(v)},h.setBkgData=function(v){this.writeScreen.setBkgData(v)},h.setMode=function(v){v!==this.mode&&(this.mode=v,Ha.log("INFO","MODE="+v),this.mode==="MODE_POP-ON"?this.writeScreen=this.nonDisplayedMemory:(this.writeScreen=this.displayedMemory,this.writeScreen.reset()),this.mode!=="MODE_ROLL-UP"&&(this.displayedMemory.nrRollUpRows=null,this.nonDisplayedMemory.nrRollUpRows=null),this.mode=v)},h.insertChars=function(v){for(var r=0;r=46,r.italics)r.foreground="white";else{var c=Math.floor(v/2)-16,_=["white","green","blue","cyan","red","yellow","magenta"];r.foreground=_[c]}Ha.log("INFO","MIDROW: "+JSON.stringify(r)),this.writeScreen.setPen(r)},h.outputDataUpdate=function(v){v===void 0&&(v=!1);var r=Ha.time;r!==null&&this.outputFilter&&(this.cueStartTime===null&&!this.displayedMemory.isEmpty()?this.cueStartTime=r:this.displayedMemory.equals(this.lastOutputScreen)||(this.outputFilter.newCue(this.cueStartTime,r,this.lastOutputScreen),v&&this.outputFilter.dispatchCue&&this.outputFilter.dispatchCue(),this.cueStartTime=this.displayedMemory.isEmpty()?null:r),this.lastOutputScreen.copy(this.displayedMemory))},h.cueSplitAtTime=function(v){this.outputFilter&&(this.displayedMemory.isEmpty()||(this.outputFilter.newCue&&this.outputFilter.newCue(this.cueStartTime,v,this.displayedMemory),this.cueStartTime=v))},w}(),X_=function(){function w(f,v,r){this.field=void 0,this.outputs=void 0,this.channels=void 0,this.currChNr=void 0,this.lastCmdA=void 0,this.lastCmdB=void 0,this.lastTime=void 0,this.dataCounters=void 0,this.field=f||1,this.outputs=[v,r],this.channels=[new Y_(1,v),new Y_(2,r)],this.currChNr=-1,this.lastCmdA=null,this.lastCmdB=null,this.lastTime=null,this.dataCounters={padding:0,char:0,cmd:0,other:0}}var h=w.prototype;return h.getHandler=function(v){return this.channels[v].getHandler()},h.setHandler=function(v,r){this.channels[v].setHandler(r)},h.addData=function(v,r){var c,_,g,C=!1;this.lastTime=v,Ha.setTime(v);for(var F=0;F ("+Uc([_,g])+")");if(c=this.parseCmd(_,g),c||(c=this.parseMidrow(_,g)),c||(c=this.parsePAC(_,g)),c||(c=this.parseBackgroundAttributes(_,g)),!c&&(C=this.parseChars(_,g),C))if(this.currChNr&&this.currChNr>=0){var x=this.channels[this.currChNr-1];x.insertChars(C)}else Ha.log("WARNING","No channel found yet. TEXT-MODE?");c?this.dataCounters.cmd+=2:C?this.dataCounters.char+=2:(this.dataCounters.other+=2,Ha.log("WARNING","Couldn't parse cleaned data "+Uc([_,g])+" orig: "+Uc([r[F],r[F+1]])))}},h.parseCmd=function(v,r){var c=null,_=(v===20||v===28)&&r>=32&&r<=47,g=(v===23||v===31)&&r>=33&&r<=35;if(!(_||g))return!1;if(v===this.lastCmdA&&r===this.lastCmdB)return this.lastCmdA=null,this.lastCmdB=null,Ha.log("DEBUG","Repeated command ("+Uc([v,r])+") is dropped"),!0;v===20||v===23?c=1:c=2;var C=this.channels[c-1];return v===20||v===28?r===32?C.ccRCL():r===33?C.ccBS():r===34?C.ccAOF():r===35?C.ccAON():r===36?C.ccDER():r===37?C.ccRU(2):r===38?C.ccRU(3):r===39?C.ccRU(4):r===40?C.ccFON():r===41?C.ccRDC():r===42?C.ccTR():r===43?C.ccRTD():r===44?C.ccEDM():r===45?C.ccCR():r===46?C.ccENM():r===47&&C.ccEOC():C.ccTO(r-32),this.lastCmdA=v,this.lastCmdB=r,this.currChNr=c,!0},h.parseMidrow=function(v,r){var c=null;if((v===17||v===25)&&r>=32&&r<=47){if(v===17?c=1:c=2,c!==this.currChNr)return Ha.log("ERROR","Mismatch channel in midrow parsing"),!1;var _=this.channels[c-1];return _.ccMIDROW(r),Ha.log("DEBUG","MIDROW ("+Uc([v,r])+")"),!0}return!1},h.parsePAC=function(v,r){var c=null,_=null,g=(v>=17&&v<=23||v>=25&&v<=31)&&r>=64&&r<=127,C=(v===16||v===24)&&r>=64&&r<=95;if(!(g||C))return!1;if(v===this.lastCmdA&&r===this.lastCmdB)return this.lastCmdA=null,this.lastCmdB=null,!0;c=v<=23?1:2,r>=64&&r<=95?_=c===1?JE[v]:$E[v]:_=c===1?WE[v]:zE[v];var F=this.interpretPAC(_,r),x=this.channels[c-1];return x.setPAC(F),this.lastCmdA=v,this.lastCmdB=r,this.currChNr=c,!0},h.interpretPAC=function(v,r){var c=r,_={color:null,italics:!1,indent:null,underline:!1,row:v};return r>95?c=r-96:c=r-64,_.underline=(c&1)==1,c<=13?_.color=["white","green","blue","cyan","red","yellow","magenta","white"][Math.floor(c/2)]:c<=15?(_.italics=!0,_.color="white"):_.indent=Math.floor((c-16)/2)*4,_},h.parseChars=function(v,r){var c=null,_=null,g=null;if(v>=25?(c=2,g=v-8):(c=1,g=v),g>=17&&g<=19){var C=r;g===17?C=r+80:g===18?C=r+112:C=r+144,Ha.log("INFO","Special char '"+rg(C)+"' in channel "+c),_=[C]}else v>=32&&v<=127&&(_=r===0?[v]:[v,r]);if(_){var F=Uc(_);Ha.log("DEBUG","Char codes = "+F.join(",")),this.lastCmdA=null,this.lastCmdB=null}return _},h.parseBackgroundAttributes=function(v,r){var c,_,g,C,F=(v===16||v===24)&&r>=32&&r<=47,x=(v===23||v===31)&&r>=45&&r<=47;return F||x?(c={},v===16||v===24?(_=Math.floor((r-32)/2),c.background=VE[_],r%2==1&&(c.background=c.background+"_semi")):r===45?c.background="transparent":(c.foreground="black",r===47&&(c.underline=!0)),g=v<24?1:2,C=this.channels[g-1],C.setBkgData(c),this.lastCmdA=null,this.lastCmdB=null,!0):!1},h.reset=function(){for(var v=0;vv)&&(this.startTime=v),this.endTime=r,this.screen=c,this.timelineController.createCaptionsTrack(this.trackName)},w}(),bd=function(h,f,v){return h.substr(v||0,f.length)===f},XE=function(h){var f=parseInt(h.substr(-3)),v=parseInt(h.substr(-6,2)),r=parseInt(h.substr(-9,2)),c=h.length>9?parseInt(h.substr(0,h.indexOf(":"))):0;if(!Object(i.isFiniteNumber)(f)||!Object(i.isFiniteNumber)(v)||!Object(i.isFiniteNumber)(r)||!Object(i.isFiniteNumber)(c))throw Error("Malformed X-TIMESTAMP-MAP: Local:"+h);return f+=1e3*v,f+=60*1e3*r,f+=60*60*1e3*c,f},Z_=function(h){for(var f=5381,v=h.length;v;)f=f*33^h.charCodeAt(--v);return(f>>>0).toString()},ZE=function(h,f,v){var r=h[f],c=h[r.prevCC];if(!c||!c.new&&r.new){h.ccOffset=h.presentationOffset=r.start,r.new=!1;return}for(;c&&c.new;)h.ccOffset+=r.start-c.start,r.new=!1,r=c,c=h[r.prevCC];h.presentationOffset=v},eI={parse:function(h,f,v,r,c,_){var g=/\r\n|\n\r|\n|\r/g,C=Object(Q_.utf8ArrayToStr)(new Uint8Array(h)).trim().replace(g,` `).split(` `),F="00:00.000",x=0,H=0,U=0,X=[],ye,qe=!0,vn=!1,fa=new HE;fa.oncue=function(Zn){var la=v[r],Ra=v.ccOffset;la&&la.new&&(H!==void 0?Ra=v.ccOffset=la.start:ZE(v,r,U)),U&&(Ra=U-v.presentationOffset),vn&&(Zn.startTime+=Ra-H,Zn.endTime+=Ra-H),Zn.id=Z_(Zn.startTime.toString())+Z_(Zn.endTime.toString())+Z_(Zn.text),Zn.text=decodeURIComponent(encodeURIComponent(Zn.text)),Zn.endTime>0&&X.push(Zn)},fa.onparsingerror=function(Zn){ye=Zn},fa.onflush=function(){if(ye&&_){_(ye);return}c(X)},C.forEach(function(Zn){if(qe)if(bd(Zn,"X-TIMESTAMP-MAP=")){qe=!1,vn=!0,Zn.substr(16).split(",").forEach(function(la){bd(la,"LOCAL:")?F=la.substr(6):bd(la,"MPEGTS:")&&(x=parseInt(la.substr(7)))});try{f+(v[r].start*9e4||0)<0&&(f+=8589934592),x-=f,H=XE(F)/1e3,U=x/9e4}catch(la){vn=!1,ye=la}return}else Zn===""&&(qe=!1);fa.parse(Zn+` `)}),fa.flush()}},nI=eI;function ig(w){if(w===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w}function aI(w,h){w.prototype=Object.create(h.prototype),w.prototype.constructor=w,w.__proto__=h}var tI=function(w){aI(h,w);function h(v){var r;if(r=w.call(this,v,l.default.MEDIA_ATTACHING,l.default.MEDIA_DETACHING,l.default.FRAG_PARSING_USERDATA,l.default.FRAG_DECRYPTED,l.default.MANIFEST_LOADING,l.default.MANIFEST_LOADED,l.default.FRAG_LOADED,l.default.INIT_PTS_FOUND)||this,r.media=null,r.config=void 0,r.enabled=!0,r.Cues=void 0,r.textTracks=[],r.tracks=[],r.initPTS=[],r.unparsedVttFrags=[],r.cueRanges=[],r.captionsTracks={},r.captionsProperties=void 0,r.cea608Parser=void 0,r.lastSn=-1,r.prevCC=-1,r.vttCCs=null,r.hls=v,r.config=v.config,r.Cues=v.config.cueHandler,r.captionsProperties={textTrack1:{label:r.config.captionsTextTrack1Label,languageCode:r.config.captionsTextTrack1LanguageCode},textTrack2:{label:r.config.captionsTextTrack2Label,languageCode:r.config.captionsTextTrack2LanguageCode}},r.config.enableCEA708Captions){var c=new ug(ig(r),"textTrack1"),_=new ug(ig(r),"textTrack2");r.cea608Parser=new YE(0,c,_)}return r}var f=h.prototype;return f.addCues=function(r,c,_,g){for(var C=this.cueRanges,F=!1,x=C.length;x--;){var H=C[x],U=rI(H[0],H[1],c,_);if(U>=0&&(H[0]=Math.min(H[0],c),H[1]=Math.max(H[1],_),F=!0,U/(_-c)>.5))return}F||C.push([c,_]),this.Cues.newCue(this.captionsTracks[r],c,_,g)},f.onInitPtsFound=function(r){var c=this,_=r.frag,g=r.id,C=r.initPTS,F=this.unparsedVttFrags;g==="main"&&(this.initPTS[_.cc]=C),F.length&&(this.unparsedVttFrags=[],F.forEach(function(x){c.onFragLoaded(x)}))},f.getExistingTrack=function(r){var c=this.media;if(c)for(var _=0;_=F.length||_!==C||!x||this.stopped){this._clearReloadTimer();return}if(s.logger.log("subtitle track "+_+" loaded"),g.live){var H=Lt(x.details,g,r.stats.trequest);s.logger.log("Reloading live subtitle playlist in "+H+"ms"),this.timer=setTimeout(function(){c._loadCurrentTrack()},H)}else this._clearReloadTimer()},f.startLoad=function(){this.stopped=!1,this._loadCurrentTrack()},f.stopLoad=function(){this.stopped=!0,this._clearReloadTimer()},f._clearReloadTimer=function(){this.timer&&(clearTimeout(this.timer),this.timer=null)},f._loadCurrentTrack=function(){var r=this.trackId,c=this.tracks,_=this.hls,g=c[r];r<0||!g||g.details&&!g.details.live||(s.logger.log("Loading subtitle track "+r),_.trigger(l.default.SUBTITLE_TRACK_LOADING,{url:g.url,id:r}))},f._toggleTrackModes=function(r){var c=this.media,_=this.subtitleDisplay,g=this.trackId;if(!!c){var C=p(c.textTracks);if(r===-1)[].slice.call(C).forEach(function(H){H.mode="disabled"});else{var F=C[g];F&&(F.mode="disabled")}var x=C[r];x&&(x.mode=_?"showing":"hidden")}},f._setSubtitleTrackInternal=function(r){var c=this.hls,_=this.tracks;!Object(i.isFiniteNumber)(r)||r<-1||r>=_.length||(this.trackId=r,s.logger.log("Switching to subtitle track "+r),c.trigger(l.default.SUBTITLE_TRACK_SWITCH,{id:r}),this._loadCurrentTrack())},f._onTextTracksChanged=function(){if(!!this.media){for(var r=-1,c=p(this.media.textTracks),_=0;_=g[x].start&&F<=g[x].end){C=g[x];break}var H=c.start+c.duration;C?C.end=H:(C={start:F,end:H},g.push(C))}}},f.onMediaAttached=function(r){var c=r.media;this.media=c,c.addEventListener("seeking",this._onMediaSeeking),this.state=se.IDLE},f.onMediaDetaching=function(){var r=this;!this.media||(this.media.removeEventListener("seeking",this._onMediaSeeking),this.fragmentTracker.removeAllFragments(),this.currentTrackId=-1,this.tracks.forEach(function(c){r.tracksBuffered[c.id]=[]}),this.media=null,this.state=se.STOPPED)},f.onError=function(r){var c=r.frag;!c||c.type!=="subtitle"||(this.state=se.IDLE)},f.onSubtitleTracksUpdated=function(r){var c=this;s.logger.log("subtitle tracks updated"),this.tracksBuffered=[],this.tracks=r.subtitleTracks,this.tracks.forEach(function(_){c.tracksBuffered[_.id]=[]})},f.onSubtitleTrackSwitch=function(r){if(this.currentTrackId=r.id,!this.tracks||!this.tracks.length||this.currentTrackId===-1){this.clearInterval();return}var c=this.tracks[this.currentTrackId];c&&c.details&&this.setInterval(ha)},f.onSubtitleTrackLoaded=function(r){var c=r.id,_=r.details,g=this.currentTrackId,C=this.tracks,F=C[g];c>=C.length||c!==g||!F||(_.live&&Vn(F.details,_,this.lastAVStart),F.details=_,this.setInterval(ha))},f.onKeyLoaded=function(){this.state===se.KEY_LOADING&&(this.state=se.IDLE)},f.onFragLoaded=function(r){var c=this.fragCurrent,_=r.frag.decryptdata,g=r.frag,C=this.hls;if(this.state===se.FRAG_LOADING&&c&&r.frag.type==="subtitle"&&c.sn===r.frag.sn&&r.payload.byteLength>0&&_&&_.key&&_.method==="AES-128"){var F=_n.now();this.decrypter.decrypt(r.payload,_.key.buffer,_.iv.buffer,function(x){var H=_n.now();C.trigger(l.default.FRAG_DECRYPTED,{frag:g,payload:x,stats:{tstart:F,tdecrypt:H}})})}},f.onLevelUpdated=function(r){var c=r.details,_=c.fragments;this.lastAVStart=_.length?_[0].start:0},f.doTick=function(){if(!this.media){this.state=se.IDLE;return}switch(this.state){case se.IDLE:{var r=this.config,c=this.currentTrackId,_=this.fragmentTracker,g=this.media,C=this.tracks;if(!C||!C[c]||!C[c].details)break;var F=r.maxBufferHole,x=r.maxFragLookUpTolerance,H=Math.min(r.maxBufferLength,r.maxMaxBufferLength),U=j.bufferedInfo(this._getBuffered(),g.currentTime,F),X=U.end,ye=U.len,qe=C[c].details,vn=qe.fragments,fa=vn.length,Zn=vn[fa-1].start+vn[fa-1].duration;if(ye>H)return;var la,Ra=this.fragPrevious;Xsg){this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.KEY_SYSTEM_ERROR,details:u.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,fatal:!0});return}var C=sg-this._requestLicenseFailureCount+1;s.logger.warn("Retrying license request, "+C+" attempts left"),this._requestLicense(_,g)}break}},f._generateLicenseRequestChallenge=function(r,c){switch(r.mediaKeySystemDomain){case zt.WIDEVINE:return c}throw new Error("unsupported key-system: "+r.mediaKeySystemDomain)},f._requestLicense=function(r,c){s.logger.log("Requesting content license for key-system");var _=this._mediaKeysList[0];if(!_){s.logger.error("Fatal error: Media is encrypted but no key-system access has been obtained yet"),this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.KEY_SYSTEM_ERROR,details:u.ErrorDetails.KEY_SYSTEM_NO_ACCESS,fatal:!0});return}try{var g=this.getLicenseServerUrl(_.mediaKeySystemDomain),C=this._createLicenseXhr(g,r,c);s.logger.log("Sending license request to URL: "+g);var F=this._generateLicenseRequestChallenge(_,r);C.send(F)}catch(x){s.logger.error("Failure requesting DRM license: "+x),this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.KEY_SYSTEM_ERROR,details:u.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,fatal:!0})}},f.onMediaAttached=function(r){if(!!this._emeEnabled){var c=r.media;this._media=c,c.addEventListener("encrypted",this._onMediaEncrypted)}},f.onMediaDetached=function(){this._media&&(this._media.removeEventListener("encrypted",this._onMediaEncrypted),this._media=null)},f.onManifestParsed=function(r){if(!!this._emeEnabled){var c=r.levels.map(function(g){return g.audioCodec}),_=r.levels.map(function(g){return g.videoCodec});this._attemptKeySystemAccess(zt.WIDEVINE,c,_)}},iI(h,[{key:"requestMediaKeySystemAccess",get:function(){if(!this._requestMediaKeySystemAccess)throw new Error("No requestMediaKeySystemAccess function configured");return this._requestMediaKeySystemAccess}}]),h}(y),cI=fg;function sI(w){for(var h=1;hc)return g}return 0}},{key:"maxAutoLevel",get:function(){var r=this.levels,c=this.autoLevelCapping,_;return c===-1&&r&&r.length?_=r.length-1:_=c,_}},{key:"nextAutoLevel",get:function(){return Math.min(Math.max(this.abrController.nextAutoLevel,this.minAutoLevel),this.maxAutoLevel)},set:function(r){this.abrController.nextAutoLevel=Math.max(this.minAutoLevel,r)}},{key:"audioTracks",get:function(){var r=this.audioTrackController;return r?r.audioTracks:[]}},{key:"audioTrack",get:function(){var r=this.audioTrackController;return r?r.audioTrack:-1},set:function(r){var c=this.audioTrackController;c&&(c.audioTrack=r)}},{key:"liveSyncPosition",get:function(){return this.streamController.liveSyncPosition}},{key:"subtitleTracks",get:function(){var r=this.subtitleTrackController;return r?r.subtitleTracks:[]}},{key:"subtitleTrack",get:function(){var r=this.subtitleTrackController;return r?r.subtitleTrack:-1},set:function(r){var c=this.subtitleTrackController;c&&(c.subtitleTrack=r)}},{key:"subtitleDisplay",get:function(){var r=this.subtitleTrackController;return r?r.subtitleDisplay:!1},set:function(r){var c=this.subtitleTrackController;c&&(c.subtitleDisplay=r)}}]),h}(re);Dg.defaultConfig=void 0},"./src/polyfills/number-isFinite.js":function(e,n,a){"use strict";a.r(n),a.d(n,"isFiniteNumber",function(){return t});var t=Number.isFinite||function(o){return typeof o=="number"&&isFinite(o)}},"./src/utils/get-self-scope.js":function(e,n,a){"use strict";a.r(n),a.d(n,"getSelfScope",function(){return t});function t(){return typeof window=="undefined"?self:window}},"./src/utils/logger.js":function(e,n,a){"use strict";a.r(n),a.d(n,"enableLogs",function(){return y}),a.d(n,"logger",function(){return I});var t=a("./src/utils/get-self-scope.js");function o(){}var u={trace:o,debug:o,log:o,warn:o,info:o,error:o},i=u;function l(b,S){return S="["+b+"] > "+S,S}var s=Object(t.getSelfScope)();function R(b){var S=s.console[b];return S?function(){for(var L=arguments.length,O=new Array(L),$=0;$1?S-1:0),O=1;O{"use strict";Object.defineProperty(hD,"__esModule",{value:!0});hD.Direction=void 0;var g1e;(function(e){e.Right="to right",e.Left="to left",e.Down="to bottom",e.Up="to top"})(g1e=hD.Direction||(hD.Direction={}))});var DA=je(Aa=>{"use strict";var DD=Aa&&Aa.__spreadArray||function(e,n,a){if(a||arguments.length===2)for(var t=0,o=n.length,u;te)return s;if(R&&Rt)return t;if(e=a)throw new RangeError("min (".concat(n,") is equal/bigger than max (").concat(a,")"));if(ea)throw new RangeError("value (".concat(e,") is bigger than max (").concat(a,")"))}Aa.checkBoundaries=I1e;function T1e(e,n,a){return ea?a:e}Aa.checkValuesAgainstBoundaries=T1e;function S1e(e){if(!(e.length<2)&&!e.slice(1).every(function(n,a){return e[a]<=n}))throw new RangeError("values={[".concat(e,"]} needs to be sorted when allowOverlap={false}"))}Aa.checkInitialOverlap=S1e;function C1e(e){var n=window.getComputedStyle(e);return{top:parseInt(n["margin-top"],10),bottom:parseInt(n["margin-bottom"],10),left:parseInt(n["margin-left"],10),right:parseInt(n["margin-right"],10)}}Aa.getMargin=C1e;function F1e(e){var n=window.getComputedStyle(e);return{top:parseInt(n["padding-top"],10)+parseInt(n["border-top-width"],10),bottom:parseInt(n["padding-bottom"],10)+parseInt(n["border-bottom-width"],10),left:parseInt(n["padding-left"],10)+parseInt(n["border-left-width"],10),right:parseInt(n["padding-right"],10)+parseInt(n["border-right-width"],10)}}Aa.getPaddingAndBorder=F1e;function G1e(e,n,a){var t=a?-1:1;e.forEach(function(o,u){return bz(o,t*n[u].x,n[u].y)})}Aa.translateThumbs=G1e;function M1e(e,n,a,t){for(var o=0,u=Iz(e[0],n,a,t),i=1;ii?s:i},e.getBoundingClientRect().width));return u},j1e=function(e,n,a,t,o,u,i){i===void 0&&(i=function(R){return R});var l=[],s=function(R){var d=Ez(a[R],t[R],o,u,i),y=n[R].x;n.forEach(function(I,b){var S=I.x,L=Ez(a[b],t[b],o,u,i);R!==b&&(y>=S&&y<=S+L||y+d>=S&&y+d<=S+L)&&(l.includes(b)||(l.push(R),l.push(b),l=DD(DD([],l,!0),[R,b],!1),s(b)))})};return s(e),Array.from(new Set(l.sort()))},O1e=function(e,n,a,t,o,u){t===void 0&&(t=.1),o===void 0&&(o=" - "),u===void 0&&(u=function(b){return b});var i=(0,Aa.getStepDecimals)(t),l=(0,hA.useState)({}),s=l[0],R=l[1],d=(0,hA.useState)(u(n[a].toFixed(i))),y=d[0],I=d[1];return(0,hA.useEffect)(function(){if(e){var b=e.getThumbs();if(b.length<1)return;var S={},L=e.getOffsets(),O=j1e(a,L,b,n,o,i,u),$=u(n[a].toFixed(i));if(O.length){var z=O.reduce(function(Re,nn,cn,ce){return Re.length?DD(DD([],Re,!0),[L[ce[cn]].x],!1):[L[ce[cn]].x]},[]);if(Math.min.apply(Math,z)===L[a].x){var ee=[];O.forEach(function(Re){ee.push(n[Re].toFixed(i))}),$=Array.from(new Set(ee.sort(function(Re,nn){return parseFloat(Re)-parseFloat(nn)}))).map(u).join(o);var oe=Math.min.apply(Math,z),te=Math.max.apply(Math,z),ve=b[O[z.indexOf(te)]].getBoundingClientRect().width;S.left="".concat(Math.abs(oe-(te+ve))/2,"px"),S.transform="translate(-50%, 0)"}else S.visibility="hidden"}I($),R(S)}},[e,n]),[y,s]};Aa.useThumbOverlap=O1e;function Iz(e,n,a,t){var o=e.getBoundingClientRect(),u=o.left,i=o.top,l=o.width,s=o.height;return wz(t)?Math.abs(a-(i+s/2)):Math.abs(n-(u+l/2))}});var Sz=je(Fi=>{"use strict";var U1e=Fi&&Fi.__extends||function(){var e=function(n,a){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,o){t.__proto__=o}||function(t,o){for(var u in o)Object.prototype.hasOwnProperty.call(o,u)&&(t[u]=o[u])},e(n,a)};return function(n,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");e(n,a);function t(){this.constructor=n}n.prototype=a===null?Object.create(a):(t.prototype=a.prototype,new t)}}(),k1e=Fi&&Fi.__createBinding||(Object.create?function(e,n,a,t){t===void 0&&(t=a);var o=Object.getOwnPropertyDescriptor(n,a);(!o||("get"in o?!n.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return n[a]}}),Object.defineProperty(e,t,o)}:function(e,n,a,t){t===void 0&&(t=a),e[t]=n[a]}),B1e=Fi&&Fi.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:!0,value:n})}:function(e,n){e.default=n}),H1e=Fi&&Fi.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var a in e)a!=="default"&&Object.prototype.hasOwnProperty.call(e,a)&&k1e(n,e,a);return B1e(n,e),n},Tz=Fi&&Fi.__spreadArray||function(e,n,a){if(a||arguments.length===2)for(var t=0,o=n.length,u;t1&&t.props.draggableTrack){if(t.thumbRefs.some(function(l){var s;return(s=l.current)===null||s===void 0?void 0:s.contains(o.target)}))return;t.setState({draggedTrackPos:[o.clientX,o.clientY]},function(){return t.onMove(o.clientX,o.clientY)})}else{var i=(0,Dt.getClosestThumbIndex)(t.thumbRefs.map(function(l){return l.current}),o.clientX,o.clientY,t.props.direction);(u=t.thumbRefs[i].current)===null||u===void 0||u.focus(),t.setState({draggedThumbIndex:i},function(){return t.onMove(o.clientX,o.clientY)})}},t.onResize=function(){(0,Dt.translateThumbs)(t.getThumbs(),t.getOffsets(),t.props.rtl),t.calculateMarkOffsets()},t.onTouchStartTrack=function(o){var u;if(o.persist(),t.addTouchEvents(o.nativeEvent),t.props.values.length>1&&t.props.draggableTrack){if(t.thumbRefs.some(function(l){var s;return(s=l.current)===null||s===void 0?void 0:s.contains(o.target)}))return;t.setState({draggedTrackPos:[o.touches[0].clientX,o.touches[0].clientY]},function(){return t.onMove(o.touches[0].clientX,o.touches[0].clientY)})}else{var i=(0,Dt.getClosestThumbIndex)(t.thumbRefs.map(function(l){return l.current}),o.touches[0].clientX,o.touches[0].clientY,t.props.direction);(u=t.thumbRefs[i].current)===null||u===void 0||u.focus(),t.setState({draggedThumbIndex:i},function(){return t.onMove(o.touches[0].clientX,o.touches[0].clientY)})}},t.onMouseOrTouchStart=function(o){if(!t.props.disabled){var u=(0,Dt.isTouchEvent)(o);if(!(!u&&o.button!==0)){var i=t.getTargetIndex(o);i!==-1&&(u?t.addTouchEvents(o):t.addMouseEvents(o),t.setState({draggedThumbIndex:i,thumbZIndexes:t.state.thumbZIndexes.map(function(l,s){return s===i?Math.max.apply(Math,t.state.thumbZIndexes):l<=t.state.thumbZIndexes[i]?l:l-1})}))}}},t.onMouseMove=function(o){o.preventDefault(),t.onMove(o.clientX,o.clientY)},t.onTouchMove=function(o){o.preventDefault(),t.onMove(o.touches[0].clientX,o.touches[0].clientY)},t.onKeyDown=function(o){var u=t.props,i=u.values,l=u.onChange,s=u.step,R=u.rtl,d=u.direction,y=t.state.isChanged,I=t.getTargetIndex(o.nativeEvent),b=R||d===no.Direction.Left||d===no.Direction.Down?-1:1;I!==-1&&(q1e.includes(o.key)?(o.preventDefault(),t.setState({draggedThumbIndex:I,isChanged:!0}),l((0,Dt.replaceAt)(i,I,t.normalizeValue(i[I]+b*(o.key==="PageUp"?s*10:s),I)))):J1e.includes(o.key)?(o.preventDefault(),t.setState({draggedThumbIndex:I,isChanged:!0}),l((0,Dt.replaceAt)(i,I,t.normalizeValue(i[I]-b*(o.key==="PageDown"?s*10:s),I)))):o.key==="Tab"?t.setState({draggedThumbIndex:-1},function(){y&&t.fireOnFinalChange()}):y&&t.fireOnFinalChange())},t.onKeyUp=function(o){var u=t.state.isChanged;t.setState({draggedThumbIndex:-1},function(){u&&t.fireOnFinalChange()})},t.onMove=function(o,u){var i=t.state,l=i.draggedThumbIndex,s=i.draggedTrackPos,R=t.props,d=R.direction,y=R.min,I=R.max,b=R.onChange,S=R.values,L=R.step,O=R.rtl;if(l===-1&&s[0]===-1&&s[1]===-1)return null;var $=t.trackRef.current;if(!$)return null;var z=$.getBoundingClientRect(),ee=(0,Dt.isVertical)(d)?z.height:z.width;if(s[0]!==-1&&s[1]!==-1){var oe=o-s[0],te=u-s[1],ve=0;switch(d){case no.Direction.Right:case no.Direction.Left:ve=oe/ee*(I-y);break;case no.Direction.Down:case no.Direction.Up:ve=te/ee*(I-y);break;default:(0,Dt.assertUnreachable)(d)}if(O&&(ve*=-1),Math.abs(ve)>=L/2){for(var Re=0;ReI?ve=I-S[Re]:nn=L/2&&b((0,Dt.replaceAt)(S,l,t.normalizeValue(ce,l)))}},t.normalizeValue=function(o,u){var i=t.props,l=i.min,s=i.max,R=i.step,d=i.allowOverlap,y=i.values;return(0,Dt.normalizeValue)(o,u,l,s,R,d,y)},t.onEnd=function(o){if(o.preventDefault(),document.removeEventListener("mousemove",t.schdOnMouseMove),document.removeEventListener("touchmove",t.schdOnTouchMove),document.removeEventListener("mouseup",t.schdOnEnd),document.removeEventListener("touchend",t.schdOnEnd),document.removeEventListener("touchcancel",t.schdOnEnd),t.state.draggedThumbIndex===-1&&t.state.draggedTrackPos[0]===-1&&t.state.draggedTrackPos[1]===-1)return null;t.setState({draggedThumbIndex:-1,draggedTrackPos:[-1,-1]},function(){t.fireOnFinalChange()})},t.fireOnFinalChange=function(){t.setState({isChanged:!1});var o=t.props,u=o.onFinalChange,i=o.values;u&&u(i)},t.updateMarkRefs=function(o){if(!o.renderMark){t.numOfMarks=void 0,t.markRefs=void 0;return}t.numOfMarks=(o.max-o.min)/t.props.step,t.markRefs=[];for(var u=0;u-1?"grabbing":this.props.draggableTrack?(0,Dt.isVertical)(this.props.direction)?"ns-resize":"ew-resize":s.length===1&&!I?"pointer":"inherit"},onMouseDown:I?Dt.voidFn:this.onMouseDownTrack,onTouchStart:I?Dt.voidFn:this.onTouchStartTrack,ref:this.trackRef},isDragged:this.state.draggedThumbIndex>-1,disabled:I,children:Tz(Tz([],O.map(function($,z,ee){return l({props:{style:a.props.direction===no.Direction.Left||a.props.direction===no.Direction.Right?{position:"absolute",left:"".concat($[0],"px"),marginTop:"".concat($[1],"px")}:{position:"absolute",top:"".concat($[0],"px"),marginLeft:"".concat($[1],"px")},key:"mark".concat(z),ref:a.markRefs[z]},index:z})}),!0),s.map(function($,z){var ee=a.state.draggedThumbIndex===z;return u({index:z,value:$,isDragged:ee,props:{style:{position:"absolute",zIndex:L[z],cursor:I?"inherit":ee?"grabbing":"grab",userSelect:"none",touchAction:"none",WebkitUserSelect:"none",MozUserSelect:"none",msUserSelect:"none"},key:z,tabIndex:I?void 0:0,"aria-valuemax":y?d:s[z+1]||d,"aria-valuemin":y?R:s[z-1]||R,"aria-valuenow":$,draggable:!1,ref:a.thumbRefs[z],role:"slider",onKeyDown:I?Dt.voidFn:a.onKeyDown,onKeyUp:I?Dt.voidFn:a.onKeyUp}})}),!0)})},n.defaultProps={step:1,direction:no.Direction.Right,rtl:!1,disabled:!1,allowOverlap:!1,draggableTrack:!1,min:0,max:100},n}(b1.Component);Fi.default=W1e});var Cz=je(eu=>{"use strict";var $1e=eu&&eu.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(eu,"__esModule",{value:!0});eu.checkValuesAgainstBoundaries=eu.relativeValue=eu.useThumbOverlap=eu.Direction=eu.getTrackBackground=eu.Range=void 0;var z1e=$1e(Sz());eu.Range=z1e.default;var E1=DA();Object.defineProperty(eu,"getTrackBackground",{enumerable:!0,get:function(){return E1.getTrackBackground}});Object.defineProperty(eu,"useThumbOverlap",{enumerable:!0,get:function(){return E1.useThumbOverlap}});Object.defineProperty(eu,"relativeValue",{enumerable:!0,get:function(){return E1.relativeValue}});Object.defineProperty(eu,"checkValuesAgainstBoundaries",{enumerable:!0,get:function(){return E1.checkValuesAgainstBoundaries}});var V1e=w1();Object.defineProperty(eu,"Direction",{enumerable:!0,get:function(){return V1e.Direction}})});var MCe={};GL(MCe,{boot:()=>GCe});var ML=function(e){return function(n){for(var a=e.length,t=n.length,o=new Array(a*t),u=0,i=0;i=a.length?n:e(a[t])};var OL=function(e,n,a,t){for(var o=0,u=t.length;o=t.length)return n;var o=t.slice();return o.splice(a,1),e(o)};var Ad=function(e){return e.slice().reverse()};var kL=function(e,n){return n.filter(e)};var BL=function(){function e(n,a,t,o,u,i){var l,s,R,d,y,I,b;for(l=u+(i-u>>1),l-u>1&&e(n,a,o,t,u,l),i-l>1&&e(n,a,o,t,l,i),s=u,R=l,d=u;s0?(t[d++]=I,++R):(t[d++]=y,++s);for(;s="0"&&e[o]<="9"?"\\&":"";return"\\"+a.charCodeAt(0).toString(10)+u})+'"'};var nr={show:R2};var y2=function(e){return e.showRecordFields},lf=function(){return function(){return function(e){var n=y2(e);return{show:function(a){return"{"+(n(et.value)(a)+"}")}}}}};var cf={show:D2},Ze={show:h2},Od={show:g2},Gg={show:function(e){if(e)return"true";if(!e)return"false";throw new Error("Failed pattern match at Data.Show (line 29, column 1 - line 31, column 23): "+[e.constructor.name])}},ne=function(e){return e.show};var sf=function(e){var n=er(e);return function(a){var t=y2(a);return function(o){var u=ne(o);return{showRecordFields:function(i){return function(l){var s=t(et.value)(l),R=n(et.value),d=Gu(R)(l);return" "+(R+(": "+(u(d)+(","+s))))}}}}}},vf=function(e){var n=er(e);return function(a){var t=ne(a);return{showRecordFields:function(o){return function(u){var i=n(et.value),l=Gu(i)(u);return" "+(i+(": "+(t(l)+" ")))}}}}};var ge=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),ie=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var xe=function(){function e(){}return e.value=new e,e}(),Ud=function(e){return e};var i0=function(e){return e.to};var l0=function(e){return e.from};var dY=pn(dn),M=function(){function e(){}return e.value=new e,e}(),T=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var w2=function(e){var n=an(e);return{append:function(a){return function(t){if(a instanceof M)return t;if(t instanceof M)return a;if(a instanceof T&&t instanceof T)return new T(n(a.value0)(t.value0));throw new Error("Failed pattern match at Data.Maybe (line 182, column 1 - line 185, column 43): "+[a.constructor.name,t.constructor.name])}}}};var bn=function(e){return function(n){return function(a){if(a instanceof M)return e;if(a instanceof T)return n(a.value0);throw new Error("Failed pattern match at Data.Maybe (line 237, column 1 - line 237, column 51): "+[e.constructor.name,n.constructor.name,a.constructor.name])}}},Tt=bn(!0)(hn(!1)),Ct=bn(!1)(hn(!0));var ae={map:function(e){return function(n){return n instanceof T?new T(e(n.value0)):M.value}}},mY=k(ae);var ke=function(e){return bn(e)(dY)},St=function(){return function(e){if(e instanceof T)return e.value0;throw new Error("Failed pattern match at Data.Maybe (line 288, column 1 - line 288, column 46): "+[e.constructor.name])}};var Vt=function(e){var n=we(e);return{eq:function(a){return function(t){return a instanceof M&&t instanceof M?!0:a instanceof T&&t instanceof T?n(a.value0)(t.value0):!1}}}},ru=function(e){var n=Qe(e),a=Vt(e.Eq0());return{compare:function(t){return function(o){if(t instanceof M&&o instanceof M)return Ue.value;if(t instanceof M)return De.value;if(o instanceof M)return de.value;if(t instanceof T&&o instanceof T)return n(t.value0)(o.value0);throw new Error("Failed pattern match at Data.Maybe (line 0, column 0 - line 0, column 0): "+[t.constructor.name,o.constructor.name])}},Eq0:function(){return a}}};var hr={apply:function(e){return function(n){if(e instanceof T)return mY(e.value0)(n);if(e instanceof M)return M.value;throw new Error("Failed pattern match at Data.Maybe (line 67, column 1 - line 69, column 30): "+[e.constructor.name,n.constructor.name])}},Functor0:function(){return ae}};var en={bind:function(e){return function(n){if(e instanceof T)return n(e.value0);if(e instanceof M)return M.value;throw new Error("Failed pattern match at Data.Maybe (line 125, column 1 - line 127, column 28): "+[e.constructor.name,n.constructor.name])}},Apply0:function(){return hr}};var aa=function(){return{pure:T.create,Apply0:function(){return hr}}}();var $r={alt:function(e){return function(n){return e instanceof M?n:e}},Functor0:function(){return ae}},hY=function(){return{empty:M.value,Alt0:function(){return $r}}}(),Br={Applicative0:function(){return aa},Plus1:function(){return hY}};var Me=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Le=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var s0=function(e){return bn(new Me(e))(Le.create)};var Dr={map:function(e){return function(n){if(n instanceof Me)return new Me(n.value0);if(n instanceof Le)return new Le(e(n.value0));throw new Error("Failed pattern match at Data.Either (line 0, column 0 - line 0, column 0): "+[n.constructor.name])}}},DY=k(Dr);var Ut=function(e){return function(n){return function(a){if(a instanceof Me)return e(a.value0);if(a instanceof Le)return n(a.value0);throw new Error("Failed pattern match at Data.Either (line 208, column 1 - line 208, column 64): "+[e.constructor.name,n.constructor.name,a.constructor.name])}}},ff=function(){return Ut(hn(M.value))(T.create)}();var Mg={apply:function(e){return function(n){if(e instanceof Me)return new Me(e.value0);if(e instanceof Le)return DY(e.value0)(n);throw new Error("Failed pattern match at Data.Either (line 70, column 1 - line 72, column 30): "+[e.constructor.name,n.constructor.name])}},Functor0:function(){return Dr}};var Mu={bind:Ut(function(e){return function(n){return new Me(e)}})(function(e){return function(n){return n(e)}}),Apply0:function(){return Mg}};var qc=function(){return{pure:Le.create,Apply0:function(){return Mg}}}(),Ag={Applicative0:function(){return qc},Bind1:function(){return Mu}};var li=function(e){return e};var Jc={map:function(e){return function(n){return e(n)}}};var b2={apply:function(e){return function(n){return e(n)}},Functor0:function(){return Jc}},gY={bind:function(e){return function(n){return n(e)}},Apply0:function(){return b2}},E2={pure:li,Apply0:function(){return b2}},cr={Applicative0:function(){return E2},Bind1:function(){return gY}};var I2=function(e){return Math.min(Math.abs(e),2147483647)},T2=function(e){return function(n){return n===0?0:n>0?Math.floor(e/n):-Math.floor(e/-n)}},S2=function(e){return function(n){if(n===0)return 0;var a=Math.abs(n);return(e%a+a)%a}};var DI={Ring0:function(){return Yl}};var Io=function(e){return e.mod};var ar={degree:I2,div:T2,mod:S2,CommutativeRing0:function(){return DI}},io=function(e){return e.div};var yt={mempty:"",Semigroup0:function(){return of}};var Xa=function(e){return e.mempty};var F2=function(e){return function(){return e}},G2=function(e){return function(n){return function(){return n(e())()}}};var gI=function(e){return function(n){return function(){for(var a=0,t=e.length;a>1),l-u>1&&e(n,a,o,t,u,l),i-l>1&&e(n,a,o,t,l,i),s=u,R=l,d=u;s0?(t[d++]=I,++R):(t[d++]=y,++s);for(;s=0;u--)t=e(a[u])(t);return t}}},a3=function(e){return function(n){return function(a){for(var t=n,o=a.length,u=0;u":e===void 0?"":e instanceof Date?e.toString():typeof Blob!="undefined"&&e instanceof Blob?"file["+e.name+"]":JSON.stringify(e)}var JX=Qt(fn),F3=tv(R0),WX=Bt(fn);var Xd=function(e){return e.foldrWithIndex};var Zd=function(e){return e.foldlWithIndex};var $X=function(e){var n=Xd(e);return function(a){var t=an(a.Semigroup0()),o=Xa(a);return function(u){return n(function(i){return function(l){return function(s){return t(u(i)(l))(s)}}})(o)}}},em={foldrWithIndex:function(e){return function(n){var a=JX(function(o){return function(u){return e(o.value0)(o.value1)(u)}})(n),t=F3(Dn.create);return function(o){return a(t(o))}}},foldlWithIndex:function(e){return function(n){var a=WX(function(o){return function(u){return e(u.value0)(o)(u.value1)}})(n),t=F3(Dn.create);return function(o){return a(t(o))}}},foldMapWithIndex:function(e){return $X(em)(e)},Foldable0:function(){return fn}};var G3=function(e){var n=Zd(e);return function(a){var t=function(o){return function(u){return function(i){return u instanceof M?a(o)(i):u}}};return n(t)(M.value)}};var M3=function(e){return function(n){return function(a){return(a|0)===a?e(a):n}}},Ft=function(e){return e},A3=function(e){return function(n){return function(a){var t;a<11?t="[0-"+(a-1).toString()+"]":a===11?t="[0-9a]":t="[0-9a-"+String.fromCharCode(86+a)+"]";var o=new RegExp("^[\\+\\-]?"+t+"+$","i");return function(u){if(o.test(u)){var i=parseInt(u,a);return(i|0)===i?e(i):n}else return n}}}};var qg=isFinite;var Jg=Math.abs;var T0=Math.floor,$I=Math.log;var Wg=function(e){return function(n){return Math.pow(e,n)}};var Ef=Math.round;var L3=2.302585092994046;var P3=qt(jd),x3=tt(jd);var XX=function(){return A3(T.create)(M.value)}(),Vc=XX(10),If=function(){return M3(T.create)(M.value)}(),N3=function(e){if(!qg(e))return 0;if(e>=Ft(P3))return P3;if(e<=Ft(x3))return x3;if($e)return ke(0)(If(e));throw new Error("Failed pattern match at Data.Int (line 72, column 1 - line 72, column 29): "+[e.constructor.name])},$g=function(e){return N3(Ef(e))};var co=function(e){return N3(T0(e))};function zg(e){return Object.prototype.toString.call(e).slice(8,-1)}function nm(e){return e===null}function Tf(e){return e===void 0}var Vg=Array.isArray||function(e){return Object.prototype.toString.call(e)==="[object Array]"};function j3(e){return e.stack||e.toString()}function cu(e){return new Error(e)}function S0(e){return e.message}function Qg(e){return function(){throw e}}var U3=function(e){return Qg(cu(e))};var k3={show:j3};var Pr=function(e){return e.throwError};var xt=function(e){return e.catchError};var Sf=function(e){var n=xt(e),a=e.MonadThrow0().Monad0(),t=k(a.Bind1().Apply0().Functor0()),o=W(a.Applicative0());return function(u){return n(t(Le.create)(u))(function(i){return o(Me.create(i))})}};var gr={liftEffect:pn(dn),Monad0:function(){return Zl}},Bn=function(e){return e.liftEffect};var ZX=k(Dr);var VI=function(e){return e};var Xg=function(e){return e};var Zg=function(e){return function(n){return e(n)}},eR=function(e){var n=k(e);return{map:function(a){return Zg(n(ZX(a)))}}};var QI=function(e){return{Applicative0:function(){return Qc(e)},Bind1:function(){return Ff(e)}}},Ff=function(e){var n=Z(e.Bind1()),a=W(e.Applicative0());return{bind:function(t){return function(o){return n(t)(Ut(function(u){return a(Me.create(u))})(function(u){var i=o(u);return i}))}},Apply0:function(){return H3(e)}}},H3=function(e){var n=eR(e.Bind1().Apply0().Functor0());return{apply:Ui(QI(e)),Functor0:function(){return n}}},Qc=function(e){return{pure:function(){var n=W(e.Applicative0());return function(a){return VI(n(Le.create(a)))}}(),Apply0:function(){return H3(e)}}};var q3=function(e){var n=QI(e);return{throwError:function(){var a=W(e.Applicative0());return function(t){return VI(a(Me.create(t)))}}(),Monad0:function(){return n}}};var nR=function(e){var n=an(e);return function(a){var t=a.Bind1(),o=Z(t),u=W(a.Applicative0()),i=eR(t.Apply0().Functor0());return{alt:function(l){return function(s){return o(l)(function(R){if(R instanceof Le)return u(new Le(R.value0));if(R instanceof Me)return o(s)(function(d){if(d instanceof Le)return u(new Le(d.value0));if(d instanceof Me)return u(new Me(n(R.value0)(d.value0)));throw new Error("Failed pattern match at Control.Monad.Except.Trans (line 86, column 9 - line 88, column 49): "+[d.constructor.name])});throw new Error("Failed pattern match at Control.Monad.Except.Trans (line 82, column 5 - line 88, column 49): "+[R.constructor.name])})}},Functor0:function(){return i}}}};var Nu=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}();var rR=function(e){var n=ou(e);return function(a){return new Nu(a,n)}};var KI=function(e){var n=k(e);return{map:function(a){return function(t){return new Nu(a(t.value0),n(a)(t.value1))}}}};var YI=function(e){var n=Lr(e),a=Bt(e),t=Qt(e);return{foldMap:function(o){var u=an(o.Semigroup0()),i=n(o);return function(l){return function(s){return u(l(s.value0))(i(l)(s.value1))}}},foldl:function(o){return function(u){return function(i){return a(o)(o(u)(i.value0))(i.value1)}}},foldr:function(o){return function(u){return function(i){return o(i.value0)(t(o)(u)(i.value1))}}}}};var Wt=function(){function e(){}return e.value=new e,e}(),at=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),oR=function(e){return e},lZ=function(e){return new at(e.value0,e.value1)};var cZ=function(e){var n=function(a){return function(t){var o=a,u=!1,i;function l(s,R){if(R instanceof at&&R.value1 instanceof at&&R.value1.value1 instanceof at){o=new at(R,s),t=R.value1.value1.value1;return}var d=function(I){return I instanceof at&&I.value1 instanceof at&&I.value1.value1 instanceof Wt?new at(e(I.value0),new at(e(I.value1.value0),Wt.value)):I instanceof at&&I.value1 instanceof Wt?new at(e(I.value0),Wt.value):Wt.value},y=function(I){return function(b){var S=I,L=!1,O;function $(z,ee){if(z instanceof at&&z.value0 instanceof at&&z.value0.value1 instanceof at&&z.value0.value1.value1 instanceof at){S=z.value1,b=new at(e(z.value0.value0),new at(e(z.value0.value1.value0),new at(e(z.value0.value1.value1.value0),ee)));return}return L=!0,ee}for(;!L;)O=$(S,b);return O}};return u=!0,y(s)(d(R))}for(;!u;)i=l(o,t);return i}};return n(Wt.value)},z3={map:cZ};var XI=KI(z3),Co={foldr:function(e){return function(n){var a=function(){var o=function(u){return function(i){var l=u,s=!1,R;function d(y,I){if(I instanceof Wt)return s=!0,y;if(I instanceof at){l=new at(I.value0,y),i=I.value1;return}throw new Error("Failed pattern match at Data.List.Types (line 107, column 7 - line 107, column 23): "+[y.constructor.name,I.constructor.name])}for(;!s;)R=d(l,i);return R}};return o(Wt.value)}(),t=Bt(Co)(za(e))(n);return function(o){return t(a(o))}}},foldl:function(e){var n=function(a){return function(t){var o=a,u=!1,i;function l(s,R){if(R instanceof Wt)return u=!0,s;if(R instanceof at){o=e(s)(R.value0),t=R.value1;return}throw new Error("Failed pattern match at Data.List.Types (line 111, column 12 - line 113, column 30): "+[R.constructor.name])}for(;!u;)i=l(o,t);return i}};return n},foldMap:function(e){var n=an(e.Semigroup0()),a=Xa(e);return function(t){return Bt(Co)(function(o){var u=n(o);return function(i){return u(t(i))}})(a)}}};var sZ=Qt(Co);var uR=YI(Co);var ZI={append:function(e){return function(n){return sZ(at.create)(n)(e)}}},V3=an(ZI);var iR={append:function(e){return function(n){return new Nu(e.value0,V3(e.value1)(lZ(n)))}}};var vZ={alt:V3,Functor0:function(){return z3}},Q3=function(){return{empty:Wt.value,Alt0:function(){return vZ}}}();var gZ=it(j2);var Z3=function(e){return new at(e,Wt.value)};var eT=function(){var e=function(n){return function(a){var t=n,o=!1,u;function i(l,s){if(s instanceof Wt)return o=!0,l;if(s instanceof at){t=new at(s.value0,l),a=s.value1;return}throw new Error("Failed pattern match at Data.List (line 368, column 3 - line 368, column 19): "+[l.constructor.name,s.constructor.name])}for(;!o;)u=i(t,a);return u}};return e(Wt.value)}();var nT=function(e){var n=Z(e.Monad0().Bind1()),a=To(e);return function(t){var o=t.Plus1().Alt0(),u=ma(o),i=k(o.Functor0()),l=W(t.Applicative0());return function(s){var R=function(d){return n(u(i(Jt.create)(s))(l(new kt(Ee))))(function(y){return l(gZ(function(I){return new at(I,d)})(function(I){return eT(d)})(y))})};return a(R)(Wt.value)}}};var Wo=function(e){return Qt(e)(at.create)(Wt.value)};var eP=function(e){return e()};var nP=function(e){throw new Error(e)};var aP=function(){return nP};var RZ=aP(),yZ=eP,tc=function(e){return yZ(function(){return RZ(e)})};var cR=function(){var e=rR(Q3);return function(n){return oR(e(n))}}();var rP=function(e){return e.value0};var G0=function(e){return e.join("")},tm=function(e){return e.split("")},ju=function(e){return e},oP=function(e){return function(n){return function(a){return function(t){return a>=0&&a=0&&e=0&&e<100&&l.setUTCFullYear(e),l.getTime()};function yP(e,n){var a=oT(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond),t=oT(n.year,n.month-1,n.day,n.hour,n.minute,n.second,n.millisecond);return a-t}function wP(e){return function(n){return function(a){return function(t){var o=oT(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond),u=new Date(o+a);return isNaN(u.getTime())?n:e({year:u.getUTCFullYear(),month:u.getUTCMonth()+1,day:u.getUTCDate(),hour:u.getUTCHours(),minute:u.getUTCMinutes(),second:u.getUTCSeconds(),millisecond:u.getUTCMilliseconds()})}}}}var bP=function(e,n,a){var t=new Date(Date.UTC(e,n,a));return e>=0&&e<100&&t.setUTCFullYear(e),t};function EP(e,n,a,t){var o=bP(n,a-1,t);return e(o.getUTCFullYear())(o.getUTCMonth()+1)(o.getUTCDate())}function IP(e,n,a){return bP(e,n-1,a).getUTCDay()}function lv(e){return e.charCodeAt(0)}function TP(e){return String.fromCharCode(e)}var yr=function(e){var n=W(e.Applicative0()),a=ou(e.Plus1());return function(t){if(t)return n(Ee);if(!t)return a;throw new Error("Failed pattern match at Control.Alternative (line 48, column 1 - line 48, column 54): "+[t.constructor.name])}};var SP=tt(Xs),CP=qt(Xs);var oa=function(e){return e.toEnum};var Jn=function(e){return e.fromEnum},uT=function(e){var n=oa(e),a=Jn(e),t=tt(e.Bounded0());return function(o){return function(u){return function(i){var l=n(i);if(l instanceof T)return l.value0;if(l instanceof M){var s=i=lv(SP)&&e<=lv(CP)?new T(TP(e)):M.value},HZ={succ:xf(iT)(lv),pred:Nf(iT)(lv),Ord0:function(){return Fg}};var jf=function(){return{cardinality:lv(CP)-lv(SP)|0,toEnum:iT,fromEnum:lv,Bounded0:function(){return Xs},Enum1:function(){return HZ}}}();var pR=function(e,n,a){var t=0,o;return function(u){if(t===2)return o;if(t===1)throw new ReferenceError(e+" was needed before it finished initializing (module "+n+", line "+u+")",n,u);return t=1,o=a(),t=2,o}},FP=ne(Ze);var _i=function(){function e(){}return e.value=new e,e}(),zi=function(){function e(){}return e.value=new e,e}(),Vi=function(){function e(){}return e.value=new e,e}(),Qi=function(){function e(){}return e.value=new e,e}(),Ki=function(){function e(){}return e.value=new e,e}(),Yi=function(){function e(){}return e.value=new e,e}(),Al=function(){function e(){}return e.value=new e,e}(),su=function(){function e(){}return e.value=new e,e}(),Uu=function(){function e(){}return e.value=new e,e}(),vu=function(){function e(){}return e.value=new e,e}(),ku=function(){function e(){}return e.value=new e,e}(),Bu=function(){function e(){}return e.value=new e,e}(),fu=function(){function e(){}return e.value=new e,e}(),_u=function(){function e(){}return e.value=new e,e}(),Hu=function(){function e(){}return e.value=new e,e}(),qu=function(){function e(){}return e.value=new e,e}(),Ju=function(){function e(){}return e.value=new e,e}(),Wu=function(){function e(){}return e.value=new e,e}(),pi=function(){function e(){}return e.value=new e,e}();var GP={show:function(e){return"(Year "+(FP(e)+")")}},MP={show:function(e){if(e instanceof _i)return"Monday";if(e instanceof zi)return"Tuesday";if(e instanceof Vi)return"Wednesday";if(e instanceof Qi)return"Thursday";if(e instanceof Ki)return"Friday";if(e instanceof Yi)return"Saturday";if(e instanceof Al)return"Sunday";throw new Error("Failed pattern match at Data.Date.Component (line 184, column 1 - line 191, column 25): "+[e.constructor.name])}},dR={show:function(e){if(e instanceof su)return"January";if(e instanceof Uu)return"February";if(e instanceof vu)return"March";if(e instanceof ku)return"April";if(e instanceof Bu)return"May";if(e instanceof fu)return"June";if(e instanceof _u)return"July";if(e instanceof Hu)return"August";if(e instanceof qu)return"September";if(e instanceof Ju)return"October";if(e instanceof Wu)return"November";if(e instanceof pi)return"December";throw new Error("Failed pattern match at Data.Date.Component (line 101, column 1 - line 113, column 29): "+[e.constructor.name])}},AP={show:function(e){return"(Day "+(FP(e)+")")}},mR=na,hR=na,LP=nt,qZ={eq:function(e){return function(n){return e instanceof _i&&n instanceof _i||e instanceof zi&&n instanceof zi||e instanceof Vi&&n instanceof Vi||e instanceof Qi&&n instanceof Qi||e instanceof Ki&&n instanceof Ki||e instanceof Yi&&n instanceof Yi||e instanceof Al&&n instanceof Al}}},PP={compare:function(e){return function(n){if(e instanceof _i&&n instanceof _i)return Ue.value;if(e instanceof _i)return De.value;if(n instanceof _i)return de.value;if(e instanceof zi&&n instanceof zi)return Ue.value;if(e instanceof zi)return De.value;if(n instanceof zi)return de.value;if(e instanceof Vi&&n instanceof Vi)return Ue.value;if(e instanceof Vi)return De.value;if(n instanceof Vi)return de.value;if(e instanceof Qi&&n instanceof Qi)return Ue.value;if(e instanceof Qi)return De.value;if(n instanceof Qi)return de.value;if(e instanceof Ki&&n instanceof Ki)return Ue.value;if(e instanceof Ki)return De.value;if(n instanceof Ki)return de.value;if(e instanceof Yi&&n instanceof Yi)return Ue.value;if(e instanceof Yi)return De.value;if(n instanceof Yi)return de.value;if(e instanceof Al&&n instanceof Al)return Ue.value;throw new Error("Failed pattern match at Data.Date.Component (line 0, column 0 - line 0, column 0): "+[e.constructor.name,n.constructor.name])}},Eq0:function(){return qZ}},lT={eq:function(e){return function(n){return e instanceof su&&n instanceof su||e instanceof Uu&&n instanceof Uu||e instanceof vu&&n instanceof vu||e instanceof ku&&n instanceof ku||e instanceof Bu&&n instanceof Bu||e instanceof fu&&n instanceof fu||e instanceof _u&&n instanceof _u||e instanceof Hu&&n instanceof Hu||e instanceof qu&&n instanceof qu||e instanceof Ju&&n instanceof Ju||e instanceof Wu&&n instanceof Wu||e instanceof pi&&n instanceof pi}}},x0={compare:function(e){return function(n){if(e instanceof su&&n instanceof su)return Ue.value;if(e instanceof su)return De.value;if(n instanceof su)return de.value;if(e instanceof Uu&&n instanceof Uu)return Ue.value;if(e instanceof Uu)return De.value;if(n instanceof Uu)return de.value;if(e instanceof vu&&n instanceof vu)return Ue.value;if(e instanceof vu)return De.value;if(n instanceof vu)return de.value;if(e instanceof ku&&n instanceof ku)return Ue.value;if(e instanceof ku)return De.value;if(n instanceof ku)return de.value;if(e instanceof Bu&&n instanceof Bu)return Ue.value;if(e instanceof Bu)return De.value;if(n instanceof Bu)return de.value;if(e instanceof fu&&n instanceof fu)return Ue.value;if(e instanceof fu)return De.value;if(n instanceof fu)return de.value;if(e instanceof _u&&n instanceof _u)return Ue.value;if(e instanceof _u)return De.value;if(n instanceof _u)return de.value;if(e instanceof Hu&&n instanceof Hu)return Ue.value;if(e instanceof Hu)return De.value;if(n instanceof Hu)return de.value;if(e instanceof qu&&n instanceof qu)return Ue.value;if(e instanceof qu)return De.value;if(n instanceof qu)return de.value;if(e instanceof Ju&&n instanceof Ju)return Ue.value;if(e instanceof Ju)return De.value;if(n instanceof Ju)return de.value;if(e instanceof Wu&&n instanceof Wu)return Ue.value;if(e instanceof Wu)return De.value;if(n instanceof Wu)return de.value;if(e instanceof pi&&n instanceof pi)return Ue.value;throw new Error("Failed pattern match at Data.Date.Component (line 0, column 0 - line 0, column 0): "+[e.constructor.name,n.constructor.name])}},Eq0:function(){return lT}},xP=nt,DR=function(){return{bottom:-271820|0,top:275759,Ord0:function(){return mR}}}(),JZ=function(){return{bottom:_i.value,top:Al.value,Ord0:function(){return PP}}}(),gR=function(){return{bottom:su.value,top:pi.value,Ord0:function(){return x0}}}(),xr={cardinality:547580,toEnum:function(e){if(e>=(-271820|0)&&e<=275759)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.Date.Component (line 35, column 1 - line 40, column 24): "+[e.constructor.name])},fromEnum:function(e){return e},Bounded0:function(){return DR},Enum1:function(){return WZ(0)}},WZ=pR("enumYear","Data.Date.Component",function(){return{succ:function(){var e=oa(xr),n=Jn(xr);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(xr),n=Jn(xr);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return mR}}});var cv={cardinality:7,toEnum:function(e){return e===1?new T(_i.value):e===2?new T(zi.value):e===3?new T(Vi.value):e===4?new T(Qi.value):e===5?new T(Ki.value):e===6?new T(Yi.value):e===7?new T(Al.value):M.value},fromEnum:function(e){if(e instanceof _i)return 1;if(e instanceof zi)return 2;if(e instanceof Vi)return 3;if(e instanceof Qi)return 4;if(e instanceof Ki)return 5;if(e instanceof Yi)return 6;if(e instanceof Al)return 7;throw new Error("Failed pattern match at Data.Date.Component (line 175, column 14 - line 182, column 16): "+[e.constructor.name])},Bounded0:function(){return JZ},Enum1:function(){return $Z(0)}},$Z=pR("enumWeekday","Data.Date.Component",function(){return{succ:function(){var e=oa(cv),n=Jn(cv);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(cv),n=Jn(cv);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return PP}}});var rr={cardinality:12,toEnum:function(e){return e===1?new T(su.value):e===2?new T(Uu.value):e===3?new T(vu.value):e===4?new T(ku.value):e===5?new T(Bu.value):e===6?new T(fu.value):e===7?new T(_u.value):e===8?new T(Hu.value):e===9?new T(qu.value):e===10?new T(Ju.value):e===11?new T(Wu.value):e===12?new T(pi.value):M.value},fromEnum:function(e){if(e instanceof su)return 1;if(e instanceof Uu)return 2;if(e instanceof vu)return 3;if(e instanceof ku)return 4;if(e instanceof Bu)return 5;if(e instanceof fu)return 6;if(e instanceof _u)return 7;if(e instanceof Hu)return 8;if(e instanceof qu)return 9;if(e instanceof Ju)return 10;if(e instanceof Wu)return 11;if(e instanceof pi)return 12;throw new Error("Failed pattern match at Data.Date.Component (line 87, column 14 - line 99, column 19): "+[e.constructor.name])},Bounded0:function(){return gR},Enum1:function(){return zZ(0)}},zZ=pR("enumMonth","Data.Date.Component",function(){return{succ:function(){var e=oa(rr),n=Jn(rr);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(rr),n=Jn(rr);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return x0}}});var fm={bottom:1,top:31,Ord0:function(){return hR}},pu={cardinality:31,toEnum:function(e){if(e>=1&&e<=31)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.Date.Component (line 133, column 1 - line 138, column 23): "+[e.constructor.name])},fromEnum:function(e){return e},Bounded0:function(){return fm},Enum1:function(){return VZ(0)}},VZ=pR("enumDay","Data.Date.Component",function(){return{succ:function(){var e=oa(pu),n=Jn(pu);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(pu),n=Jn(pu);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return hR}}});var N0=GI()();var NP=pn(dn),cT=function(e){return e},QZ=function(e){return e},_m=function(e){return e};var KZ=function(e){return e},j0=function(e){return e.toDuration};var jP={append:function(e){return function(n){return e+n}}};var RR={append:function(e){return function(n){return e+n}}};var OP=Bc;var UP=Bc;var yR=function(e){return e.fromDuration};var es={fromDuration:N0(cT)(function(e){return e*1e3}),toDuration:N0(_m)(function(e){return e/1e3})},sv={fromDuration:N0(QZ)(function(e){return e*6e4}),toDuration:N0(_m)(function(e){return e/6e4})},O0={fromDuration:NP,toDuration:NP};var sT={fromDuration:N0(KZ)(function(e){return e*864e5}),toDuration:N0(_m)(function(e){return e/864e5})};var HP=Jn(rr),vT=St(),qP=oa(cv),XZ=ne(GP),ZZ=ne(dR),eee=ne(AP);var nee=we(LP),aee=we(lT),tee=we(xP),ree=Qe(mR),oee=Qe(x0),uee=Qe(hR);var iee=oa(rr);var wR=function(){function e(n,a,t){this.value0=n,this.value1=a,this.value2=t}return e.create=function(n){return function(a){return function(t){return new e(n,a,t)}}},e}(),$u=function(e){return e.value0},pm=function(e){var n=IP(e.value0,HP(e.value1),e.value2),a=n===0;return vT(qP(a?7:n))},JP={show:function(e){return"(Date "+(XZ(e.value0)+(" "+(ZZ(e.value1)+(" "+(eee(e.value2)+")")))))}},zu=function(e){return e.value1};var bR={eq:function(e){return function(n){return nee(e.value0)(n.value0)&&aee(e.value1)(n.value1)&&tee(e.value2)(n.value2)}}},lee=we(bR),fT={compare:function(e){return function(n){var a=ree(e.value0)(n.value0);if(a instanceof De)return De.value;if(a instanceof de)return de.value;var t=oee(e.value1)(n.value1);return t instanceof De?De.value:t instanceof de?de.value:uee(e.value2)(n.value2)}},Eq0:function(){return bR}};var uc=function(e){return e.value2},vv=function(e){return function(n){return function(a){var t=function(o){return function(u){return function(i){return new wR(o,vT(iee(u)),i)}}};return EP(t,e,HP(n),a)}}},ER=function(e){return function(n){return function(a){var t=new wR(e,n,a),o=lee(vv(e)(n)(a))(t);return o?new T(t):M.value}}},_T=function(){return{bottom:new wR(tt(DR),tt(gR),tt(fm)),top:new wR(qt(DR),qt(gR),qt(fm)),Ord0:function(){return fT}}}();var IR=function(e,n,a){var t=0,o;return function(u){if(t===2)return o;if(t===1)throw new ReferenceError(e+" was needed before it finished initializing (module "+n+", line "+u+")",n,u);return t=1,o=a(),t=2,o}},TR=ne(Ze);var WP={show:function(e){return"(Second "+(TR(e)+")")}},$P={show:function(e){return"(Minute "+(TR(e)+")")}},zP={show:function(e){return"(Millisecond "+(TR(e)+")")}},VP={show:function(e){return"(Hour "+(TR(e)+")")}},SR=na,CR=na,FR=na,GR=na,QP=nt,KP=nt,YP=nt,XP=nt,dm={bottom:0,top:59,Ord0:function(){return SR}},mm={bottom:0,top:59,Ord0:function(){return CR}},hm={bottom:0,top:999,Ord0:function(){return FR}},Dm={bottom:0,top:23,Ord0:function(){return GR}},di={cardinality:60,toEnum:function(e){if(e>=0&&e<=59)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.Time.Component (line 90, column 1 - line 95, column 26): "+[e.constructor.name])},fromEnum:function(e){return e},Bounded0:function(){return dm},Enum1:function(){return cee(0)}},cee=IR("enumSecond","Data.Time.Component",function(){return{succ:function(){var e=oa(di),n=Jn(di);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(di),n=Jn(di);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return SR}}});var mi={cardinality:60,toEnum:function(e){if(e>=0&&e<=59)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.Time.Component (line 61, column 1 - line 66, column 26): "+[e.constructor.name])},fromEnum:function(e){return e},Bounded0:function(){return mm},Enum1:function(){return see(0)}},see=IR("enumMinute","Data.Time.Component",function(){return{succ:function(){var e=oa(mi),n=Jn(mi);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(mi),n=Jn(mi);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return CR}}});var du={cardinality:1e3,toEnum:function(e){if(e>=0&&e<=999)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.Time.Component (line 120, column 1 - line 125, column 31): "+[e.constructor.name])},fromEnum:function(e){return e},Bounded0:function(){return hm},Enum1:function(){return vee(0)}},vee=IR("enumMillisecond","Data.Time.Component",function(){return{succ:function(){var e=oa(du),n=Jn(du);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(du),n=Jn(du);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return FR}}});var hi={cardinality:24,toEnum:function(e){if(e>=0&&e<=23)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.Time.Component (line 32, column 1 - line 37, column 24): "+[e.constructor.name])},fromEnum:function(e){return e},Bounded0:function(){return Dm},Enum1:function(){return fee(0)}},fee=IR("enumHour","Data.Time.Component",function(){return{succ:function(){var e=oa(hi),n=Jn(hi);return function(a){return e(function(t){return t+1|0}(n(a)))}}(),pred:function(){var e=oa(hi),n=Jn(hi);return function(a){return e(function(t){return t-1|0}(n(a)))}}(),Ord0:function(){return GR}}});var dee=ne(VP),mee=ne($P),hee=ne(WP),Dee=ne(zP);var gee=we(XP),Ree=we(KP),yee=we(QP),wee=we(YP),bee=Qe(GR),Eee=Qe(CR),Iee=Qe(SR),Tee=Qe(FR);var ic=function(){function e(n,a,t,o){this.value0=n,this.value1=a,this.value2=t,this.value3=o}return e.create=function(n){return function(a){return function(t){return function(o){return new e(n,a,t,o)}}}},e}(),ZP={show:function(e){return"(Time "+(dee(e.value0)+(" "+(mee(e.value1)+(" "+(hee(e.value2)+(" "+(Dee(e.value3)+")")))))))}};var ns=function(e){return e.value2},as=function(e){return e.value1},Xi=function(e){return e.value3};var lc=function(e){return e.value0};var pT={eq:function(e){return function(n){return gee(e.value0)(n.value0)&&Ree(e.value1)(n.value1)&&yee(e.value2)(n.value2)&&wee(e.value3)(n.value3)}}},dT={compare:function(e){return function(n){var a=bee(e.value0)(n.value0);if(a instanceof De)return De.value;if(a instanceof de)return de.value;var t=Eee(e.value1)(n.value1);if(t instanceof De)return De.value;if(t instanceof de)return de.value;var o=Iee(e.value2)(n.value2);return o instanceof De?De.value:o instanceof de?de.value:Tee(e.value3)(n.value3)}},Eq0:function(){return pT}};var gm=function(){return{bottom:new ic(tt(Dm),tt(mm),tt(dm),tt(hm)),top:new ic(qt(Dm),qt(mm),qt(dm),qt(hm)),Ord0:function(){return dT}}}();var See=Jn(xr),Cee=Jn(rr),Fee=Jn(pu),Gee=Jn(hi),Mee=Jn(mi),Aee=Jn(di),Lee=Jn(du),Pee=ne(JP),xee=ne(ZP),Nee=we(bR),jee=we(pT),Oee=Qe(fT),Uee=Qe(dT),kee=Z(en),U0=Yn(hr),mT=k(ae),Bee=Tl(en),Hee=oa(xr),qee=oa(rr),Jee=oa(pu),Wee=oa(hi),$ee=oa(mi),zee=oa(di),Vee=oa(du),cc=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),hT=function(e){return{year:See($u(e.value0)),month:Cee(zu(e.value0)),day:Fee(uc(e.value0)),hour:Gee(lc(e.value1)),minute:Mee(as(e.value1)),second:Aee(ns(e.value1)),millisecond:Lee(Xi(e.value1))}},DT=function(e){return e.value1},ex={show:function(e){return"(DateTime "+(Pee(e.value0)+(" "+(xee(e.value1)+")")))}};var Qee={eq:function(e){return function(n){return Nee(e.value0)(n.value0)&&jee(e.value1)(n.value1)}}},Vu={compare:function(e){return function(n){var a=Oee(e.value0)(n.value0);return a instanceof De?De.value:a instanceof de?de.value:Uee(e.value1)(n.value1)}},Eq0:function(){return Qee}},Qu=function(e){var n=j0(e);return function(a){return function(t){return n(yP(hT(a),hT(t)))}}},Of=function(e){return e.value0},k0=function(){return{bottom:new cc(tt(_T),tt(gm)),top:new cc(qt(_T),qt(gm)),Ord0:function(){return Vu}}}(),sc=function(e){var n=yR(e);return function(a){return function(t){return kee(wP(T.create)(M.value)(n(a))(hT(t)))(function(o){return U0(mT(cc.create)(Bee(U0(U0(mT(ER)(Hee(o.year)))(qee(o.month)))(Jee(o.day)))))(U0(U0(U0(mT(ic.create)(Wee(o.hour)))($ee(o.minute)))(zee(o.second)))(Vee(o.millisecond)))})}}};var $o=function(){var e={},n="Pure",a="Throw",t="Catch",o="Sync",u="Async",i="Bind",l="Bracket",s="Fork",R="Sequential",d="Map",y="Apply",I="Alt",b="Cons",S="Resume",L="Release",O="Finalizer",$="Finalized",z="Forked",ee="Fiber",oe="Thunk";function te(Oe,ua,Ta,En){this.tag=Oe,this._1=ua,this._2=Ta,this._3=En}function ve(Oe){var ua=function(Ta,En,gn){return new te(Oe,Ta,En,gn)};return ua.tag=Oe,ua}function Re(Oe){return new te(n,void 0)}function nn(Oe){try{Oe()}catch(ua){setTimeout(function(){throw ua},0)}}function cn(Oe,ua,Ta){try{return ua(Ta())}catch(En){return Oe(En)}}function ce(Oe,ua,Ta){try{return ua(Ta)()}catch(En){return Ta(Oe(En))(),Re}}var le=function(){var Oe=1024,ua=0,Ta=0,En=new Array(Oe),gn=!1;function He(){var ea;for(gn=!0;ua!==0;)ua--,ea=En[Ta],En[Ta]=void 0,Ta=(Ta+1)%Oe,ea();gn=!1}return{isDraining:function(){return gn},enqueue:function(ea){var va,La;ua===Oe&&(La=gn,He(),gn=La),En[(Ta+ua)%Oe]=ea,ua++,gn||He()}}}();function Ne(Oe){var ua={},Ta=0,En=0;return{register:function(gn){var He=Ta++;gn.onComplete({rethrow:!0,handler:function(ea){return function(){En--,delete ua[He]}}})(),ua[He]=gn,En++},isEmpty:function(){return En===0},killAll:function(gn,He){return function(){if(En===0)return He();var ea=0,va={};function La(sn){va[sn]=ua[sn].kill(gn,function(ia){return function(){delete va[sn],ea--,Oe.isLeft(ia)&&Oe.fromLeft(ia)&&setTimeout(function(){throw Oe.fromLeft(ia)},0),ea===0&&He()}})()}for(var _t in ua)ua.hasOwnProperty(_t)&&(ea++,La(_t));return ua={},Ta=0,En=0,function(sn){return new te(o,function(){for(var ia in va)va.hasOwnProperty(ia)&&va[ia]()})}}}}}var Ce=0,Be=1,Xe=2,Sn=3,ra=4,kn=5,Hn=6;function Kn(Oe,ua,Ta){var En=0,gn=Ce,He=Ta,ea=null,va=null,La=null,_t=null,sn=null,ia=0,bt=0,Da=null,ut=!0;function q(P){for(var N,J,V;;)switch(N=null,J=null,V=null,gn){case Xe:gn=Be;try{He=La(He),_t===null?La=null:(La=_t._1,_t=_t._2)}catch(re){gn=kn,ea=Oe.left(re),He=null}break;case Sn:Oe.isLeft(He)?(gn=kn,ea=He,He=null):La===null?gn=kn:(gn=Xe,He=Oe.fromRight(He));break;case Be:switch(He.tag){case i:La&&(_t=new te(b,La,_t)),La=He._2,gn=Be,He=He._1;break;case n:La===null?(gn=kn,He=Oe.right(He._1)):(gn=Xe,He=He._1);break;case o:gn=Sn,He=cn(Oe.left,Oe.right,He._1);break;case u:gn=ra,He=ce(Oe.left,He._1,function(re){return function(){En===P&&(En++,le.enqueue(function(){En===P+1&&(gn=Sn,He=re,q(En))}))}});return;case a:gn=kn,ea=Oe.left(He._1),He=null;break;case t:La===null?sn=new te(b,He,sn,va):sn=new te(b,He,new te(b,new te(S,La,_t),sn,va),va),La=null,_t=null,gn=Be,He=He._1;break;case l:ia++,La===null?sn=new te(b,He,sn,va):sn=new te(b,He,new te(b,new te(S,La,_t),sn,va),va),La=null,_t=null,gn=Be,He=He._1;break;case s:gn=Sn,N=Kn(Oe,ua,He._2),ua&&ua.register(N),He._1&&N.run(),He=Oe.right(N);break;case R:gn=Be,He=ft(Oe,ua,He._1);break}break;case kn:if(La=null,_t=null,sn===null)gn=Hn,He=va||ea||He;else switch(N=sn._3,V=sn._1,sn=sn._2,V.tag){case t:va&&va!==N&&ia===0?gn=kn:ea&&(gn=Be,He=V._2(Oe.fromLeft(ea)),ea=null);break;case S:va&&va!==N&&ia===0||ea?gn=kn:(La=V._1,_t=V._2,gn=Xe,He=Oe.fromRight(He));break;case l:ia--,ea===null&&(J=Oe.fromRight(He),sn=new te(b,new te(L,V._2,J),sn,N),(va===N||ia>0)&&(gn=Be,He=V._3(J)));break;case L:sn=new te(b,new te($,He,ea),sn,va),gn=Be,va&&va!==N&&ia===0?He=V._1.killed(Oe.fromLeft(va))(V._2):ea?He=V._1.failed(Oe.fromLeft(ea))(V._2):He=V._1.completed(Oe.fromRight(He))(V._2),ea=null,ia++;break;case O:ia++,sn=new te(b,new te($,He,ea),sn,va),gn=Be,He=V._1;break;case $:ia--,gn=kn,He=V._1,ea=V._2;break}break;case Hn:for(var ue in Da)Da.hasOwnProperty(ue)&&(ut=ut&&Da[ue].rethrow,nn(Da[ue].handler(He)));Da=null,va&&ea?setTimeout(function(){throw Oe.fromLeft(ea)},0):Oe.isLeft(He)&&ut&&setTimeout(function(){if(ut)throw Oe.fromLeft(He)},0);return;case Ce:gn=Be;break;case ra:return}}function K(P){return function(){if(gn===Hn)return ut=ut&&P.rethrow,P.handler(He)(),function(){};var N=bt++;return Da=Da||{},Da[N]=P,function(){Da!==null&&delete Da[N]}}}function j(P,N){return function(){if(gn===Hn)return N(Oe.right(void 0))(),function(){};var J=K({rethrow:!1,handler:function(){return N(Oe.right(void 0))}})();switch(gn){case Ce:va=Oe.left(P),gn=Hn,He=va,q(En);break;case ra:va===null&&(va=Oe.left(P)),ia===0&&(gn===ra&&(sn=new te(b,new te(O,He(P)),sn,va)),gn=kn,He=null,ea=null,q(++En));break;default:va===null&&(va=Oe.left(P)),ia===0&&(gn=kn,He=null,ea=null)}return J}}function E(P){return function(){var N=K({rethrow:!1,handler:P})();return gn===Ce&&q(En),N}}return{kill:j,join:E,onComplete:K,isSuspended:function(){return gn===Ce},run:function(){gn===Ce&&(le.isDraining()?q(En):le.enqueue(function(){q(En)}))}}}function qn(Oe,ua,Ta,En){var gn=0,He={},ea=0,va={},La=new Error("[ParAff] Early exit"),_t=null,sn=e;function ia(K,j,E){var P=j,N=null,J=null,V=0,ue={},re,he;e:for(;;)switch(re=null,P.tag){case z:if(P._3===e&&(re=He[P._1],ue[V++]=re.kill(K,function(Ie){return function(){V--,V===0&&E(Ie)()}})),N===null)break e;P=N._2,J===null?N=null:(N=J._1,J=J._2);break;case d:P=P._2;break;case y:case I:N&&(J=new te(b,N,J)),N=P,P=P._1;break}if(V===0)E(Oe.right(void 0))();else for(he=0,re=V;he""),zne=gi.unmountComponentAtNode;function gN(e,n,a){return ka.createElement.apply(null,[e,Vne(e,n)].concat(a))}function Vne(e,n){if(typeof e!="string"||n._data==null)return n;var a={_data:void 0};for(var t in n._data){var o=n._data[t];a["data-"+t]=o}return Object.assign({},n,a)}var RN=(e,n)=>n[e],yN=(e,n,a)=>a[e]=n;var Wf=function(n){return function(a){return n(a)()}};var z0=function(n){return function(a){return function(){return n(a)}}},dv=function(n){return function(a){return function(t){return function(){return n(a,t)}}}},V0=function(n){return function(a){return function(t){return function(o){return function(){return n(a,t,o)}}}}};function EN(e){return n=>e===n}var QT=function(e){return function(n){return function(a){var t=fe(a);if(e instanceof M&&t instanceof M)return Ee;if(e instanceof T&&t instanceof M)return Ee;if(e instanceof T&&t instanceof T){if(EN(e.value0)(t.value0))return Ee;if($e)return n(new T(t.value0))()}return n(t)()}}};var cae=pe(zn);var Y={asReactChildren:function(e){return[e]}},We={asReactChildren:function(e){return[e]}},me={asReactChildren:pn(dn)};var KT=V0(dN),IN=function(){return V0(yN)},TN=dv(hN),SN=dv(DN),CN=z0(pN),YT=function(e){var n=wt(e);return function(a){return function(t){return cae(function(){return RN(a,t)})(n)}}},FN=dv(mN),Am=function(e){return e.asReactChildren},is=function(){return function(e){var n=Am(e);return function(a){return function(t){return function(o){return gN(a,t,n(o))}}}}},sae=is()(me),mv=function(){return function(e){return function(n){return sae(e)(n)([])}}};var XT=k(zn),vae=W(rt),GN=function(e){return{initialize:function(n){return FN(n)(e.initialState)},getState:function(n){return function(){var t=XT(fe)(CN(n))();return ke(e.initialState)(t)}},setState:KT}},MN=function(){var e=function(n){return function(a){return{initialize:function(t){return Wc(new T(a.initialState))(n)},getState:function(t){return XT(ke(a.initialState))(ec(n))},setState:function(t){return function(o){return function(u){return function(){return Wc(new T(o))(n)(),KT(t)(o)(vae(Ee))(),u()}}}}}}};return XT(e)($c(M.value))}();var AN=pe(ze),LN=an(Rt);var _ae=W(rt),PN=IN(),pae=YT(Ia),xN=k(zn),dae=YT(Ca(gP)),mae=un(tn),hae=Ja(tr),Dae=LI(rt)(fn),gae=mae(_a),NN=Bn(gr),Rae=Eg(Zl),yae=an($s(yI(wg))),jN=function(e){return e},$f=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),wae={map:function(e){return function(n){return new $f(e(n.value0),n.value1)}}},wr=function(e){return{bimap:function(n){return function(a){return function(t){return new $f(a(t.value0),AN(t.value1)(function(o){return function(u){return o({dispatch:function(i){return u.dispatch(n(i))},onStop:u.onStop})}}))}}}}},ON={apply:function(e){return function(n){return new $f(e.value0(n.value0),LN(e.value1)(n.value1))}},Functor0:function(){return wae}},Qn={bind:function(e){return function(n){var a=n(e.value0);return new $f(a.value0,LN(e.value1)(a.value1))}},Apply0:function(){return ON}},yn={pure:function(e){return new $f(e,[])},Apply0:function(){return ON}};var bae=function(e){var n=Z(e);return function(a){var t=Bn(a);return function(o){return function(u){return new $f(o,AN(u)(function(i){return function(l){return n(i)(function(s){return t(l.dispatch(s))})}}))}}}};var Lm=function(e){return new $f(Ee,[e])},Va=function(e){return Lm(hn(e))},Q0=function(e){var n=Z(e.Monad0().Bind1()),a=Bn(e);return function(t){return Lm(function(o){return n(t)(function(u){return a(bn(_ae(Ee))(o.dispatch)(u))})})}},Ma=function(e){var n=bae(e.Monad0().Bind1())(e);return function(a){return n(Ee)([a])}},UN=function(e){return function(n){return function(a){var t=a({initialState:n.init.value0}),o=PN("__unmounted"),u=PN("__subscriptions"),i=function(){var b=xN(ke(!1)),S=pae("__unmounted");return function(L){return b(S(L))}}(),l=function(){var b=xN(ke([])),S=dae("__subscriptions");return function(L){return b(S(L))}}(),s=function(b){return function(){return hae(Dae)(l(b))(),u([])(b)()}},R=function(b){return function(S){return function(){var O=l(b)();return u(qo(ym(S))(O))(b)()}}},d=function(b){return function(S){var L=function(O){return ym(gae(Kt(0))(function(){return O({dispatch:function(){var $=y(S);return function(z){return NN($(z))}}(),onStop:R(S)})}))};return gI(b)(L)}},y=function(b){return function(S){return Rae(i(b))(function(){var O=t.getState(b)(),$=n.update(O)(S);return t.setState(b)($.value0)(d($.value1)(b))()})}},I=function(b){return function(){var L=t.getState(b)();return n.view(L)(y(b))}};return yx(e,{init:t.initialize,render:I,componentDidMount:d(n.init.value1),componentWillUnmount:yae(o(!0))(s)})}}},kN=function(e){return function(){var a=NN(MN)();return Rx(function(t){return UN(t)(e)(a)})}},hv=function(e){return function(n){return gx(e,function(a){return function(t){return UN(a)(n(t))(GN)}})}};var BN=W(rt),HN=uu(),JR=function(e){return{handleMaybe:function(n){return function(a){return Wf(function(){var t=bn(BN(Ee))(n);return function(o){return t(HN(a(o)))}}())}}}},Dv=function(e){return{handleMaybe:function(n){return function(a){return function(t){return bn(BN(Ee))(n)(HN(a))()}}}}},vo={handle:function(e){return function(n){return function(a){return e(n(a))()}}}},gv={handleEffect:function(e){return Wf(e)}},zo={handleEffect:function(e){return Wf(hn(e))}},ga={handle:function(e){return function(n){return function(a){return e(n)()}}}},nl=function(e){return e.handleMaybe},sr=function(e){return e.handleEffect},Xn=function(e){return e.handle};function WR(e,n){var a={};for(var t in n)({}).hasOwnProperty.call(n,t)&&(a[t]=n[t]);for(var o in e)({}).hasOwnProperty.call(e,o)&&(a[o]=e[o]);return a}var ls=function(){return function(){return function(e){return function(n){return WR(e,n)}}}};var $R=function(e){var n=er(e);return function(){return function(){return function(a){return function(t){return dI(n(a))(t)}}}}};var ZT=mv(),qN=is(),JN=ls()();var Pm=Je,WN=function(e){return function(n){return ZT(Pm(e))(n)}};var Ri=function(e){var n=qN(e);return function(a){return function(t){return function(o){return n(Pm(a))(JN(o)({className:t}))}}}},xm=function(e){return function(n){return function(a){return ZT(Pm(e))(JN(a)({className:n}))}}},$N=function(e){return function(n){return ZT(Pm(e))({className:n})}},br=function(e){return function(n){var a=qN(n);return function(t){return function(o){return a(Pm(e))({className:t})(o)}}}};var ot=Je;var zR=function(e){var n=Ri(e);return function(){return function(){return n("video")}}},zN=function(e){return br("video")(e)};var VN=function(e){return br("ul")(e)};var zf=function(e){return br("tr")(e)};var K0=function(e){return br("thead")(e)};var Y0=function(e){return br("th")(e)};var VR=function(){return function(){return xm("textarea")}};var QN=function(e){var n=Ri(e);return function(){return function(){return n("td")}}},cs=function(e){return br("td")(e)};var X0=function(e){return br("tbody")(e)};var Z0=function(e){return br("table")(e)};var Vo=function(e){return br("strong")(e)},QR=function(e){var n=Ri(e);return function(){return function(){return n("span")}}},Ua=function(e){return br("span")(e)},KN=function(){return function(){return xm("source")}};var YN=function(e){var n=Ri(e);return function(){return function(){return n("select")}}};var KR=function(e){var n=Ri(e);return function(){return function(){return n("p")}}},$t=function(e){return br("p")(e)};var XN=function(e){var n=Ri(e);return function(){return function(){return n("option")}}};var ZN=function(e){return br("li")(e)};var ep=function(e){return br("label")(e)};var fo=function(){return function(){return xm("input")}};var al=function(){return function(){return xm("img")}};var Qa=function(e){return br("i")(e)};var ss=$N("hr");var Nm=function(e){return br("h6")(e)};var Ku=function(e){return br("h4")(e)},ej=function(e){var n=Ri(e);return function(){return function(){return n("h3")}}},Hr=function(e){return br("h3")(e)},Rv=function(e){var n=Ri(e);return function(){return function(){return n("h2")}}},Ht=function(e){return br("h2")(e)};var yv=function(e){return br("h1")(e)},np=function(e){var n=Ri(e);return function(){return function(){return n("form")}}};var or=function(e){var n=Ri(e);return function(){return function(){return n("div")}}},Te=function(e){return br("div")(e)};var Wn=function(e){var n=Ri(e);return function(){return function(){return n("button")}}},nj=function(e){return br("button")(e)};var Mt=function(e){var n=Ri(e);return function(){return function(){return n("a")}}};var aj=Cu(AT()),tj=aj.Fragment;var Ke=Je,Se=is()(me)(tj)({}),$n=!1;var rj=MR(Rm),Eae=W(rt);var oj={map:function(e){return function(n){return rj(rj(e))(n)}}},jm=function(e){var n=Z(e.Monad0().Bind1()),a=Bn(e);return function(t){return function(o){return Lm(function(u){return n(o(function(){var i=bn(Eae(Ee))(u.dispatch);return function(l){return i(t(l))}}()))(function(i){return a(u.onStop(i))})})}}},tl=function(e){var n=jm(e);return function(a){return n(function(t){return T.create(a(t))})}};var Cn=function(){return{"genericTop'":xe.value}}();var eS=function(e){return e["genericTop'"]},Fn=function(e){return{"genericTop'":eS(e)}};var Gn=function(){return{"genericBottom'":xe.value}}();var Om=function(e){return e["genericBottom'"]},Mn=function(e){return{"genericBottom'":Om(e)}};var An=function(e){return{"genericBottom'":new ge(Om(e))}},uj=function(e){var n=i0(e);return function(a){return n(Om(a))}};var wv=k(ae),YR=ba();var nS=function(e){return e["genericToEnum'"]};var XR=function(e){return e["genericSucc'"]},aS=function(e){var n=i0(e),a=l0(e);return function(t){var o=wv(n),u=XR(t);return function(i){return o(u(a(i)))}}},tS=function(e){return e["genericPred'"]};var rS=function(e){return e["genericFromEnum'"]};var Ln=function(e){var n=tS(e),a=XR(e);return function(t){var o=eS(t);return function(u){var i=tS(u),l=XR(u);return function(s){var R=Om(s);return{"genericPred'":function(d){if(d instanceof ge)return wv(ge.create)(n(d.value0));if(d instanceof ie){var y=i(d.value0);if(y instanceof M)return new T(new ge(o));if(y instanceof T)return new T(new ie(y.value0));throw new Error("Failed pattern match at Data.Enum.Generic (line 30, column 14 - line 32, column 31): "+[y.constructor.name])}throw new Error("Failed pattern match at Data.Enum.Generic (line 28, column 18 - line 32, column 31): "+[d.constructor.name])},"genericSucc'":function(d){if(d instanceof ge){var y=a(d.value0);if(y instanceof M)return new T(new ie(R));if(y instanceof T)return new T(new ge(y.value0));throw new Error("Failed pattern match at Data.Enum.Generic (line 34, column 14 - line 36, column 31): "+[y.constructor.name])}if(d instanceof ie)return wv(ie.create)(l(d.value0));throw new Error("Failed pattern match at Data.Enum.Generic (line 33, column 18 - line 37, column 36): "+[d.constructor.name])}}}}}};var Pn={"genericPred'":function(e){return M.value},"genericSucc'":function(e){return M.value}},xn=function(e){var n=tS(e),a=XR(e);return{"genericPred'":function(t){return wv(Ud)(n(t))},"genericSucc'":function(t){return wv(Ud)(a(t))}}};var oS=function(e){return e["genericCardinality'"]};var Nn=function(e){var n=oS(e),a=nS(e),t=rS(e);return function(o){var u=nS(o),i=rS(o);return{"genericCardinality'":YR(n)+YR(oS(o))|0,"genericToEnum'":function(l){var s=function(R){if(l>=0&&lt.value0;return o?a.value0:t.value0}()|0,(1+a.value1|0)+t.value1|0,e,n,a,t);throw new Error("Failed pattern match at Data.Map.Internal (line 686, column 5 - line 690, column 68): "+[t.constructor.name])}throw new Error("Failed pattern match at Data.Map.Internal (line 678, column 32 - line 690, column 68): "+[a.constructor.name])};var cS=function(e){return function(n){return new Ao(1,1,e,n,rl.value,rl.value)}},vj=function(){var e=function(t){if(t instanceof rl)return 0;if(t instanceof Ao)return t.value0;throw new Error("Failed pattern match at Data.Map.Internal (line 735, column 12 - line 737, column 26): "+[t.constructor.name])},n=function(t,o,u,i,l,s,R){return s instanceof Ao&&s.value0>e(R)?ol(s.value2,s.value3,ol(t,o,u,s.value4),ol(i,l,s.value5,R)):ol(i,l,ol(t,o,u,s),R)},a=function(t,o,u,i,l,s,R){return s instanceof Ao&&e(l)<=s.value0?ol(s.value2,s.value3,ol(u,i,l,s.value4),ol(t,o,s.value5,R)):ol(u,i,l,ol(t,o,s,R))};return function(t,o,u,i){if(u instanceof rl)return i instanceof rl?cS(t)(o):i instanceof Ao&&i.value0>1?n(t,o,u,i.value2,i.value3,i.value4,i.value5):ol(t,o,u,i);if(u instanceof Ao){if(i instanceof Ao){if(i.value0>(u.value0+1|0))return n(t,o,u,i.value2,i.value3,i.value4,i.value5);if(u.value0>(i.value0+1|0))return a(t,o,u.value2,u.value3,u.value4,u.value5,i)}return i instanceof rl&&u.value0>1?a(t,o,u.value2,u.value3,u.value4,u.value5,i):ol(t,o,u,i)}throw new Error("Failed pattern match at Data.Map.Internal (line 695, column 40 - line 716, column 34): "+[u.constructor.name])}}();var vs=function(e){var n=Qe(e);return function(a){var t=function(o){var u=!1,i;function l(s){if(s instanceof rl)return u=!0,M.value;if(s instanceof Ao){var R=n(a)(s.value2);if(R instanceof De){o=s.value4;return}if(R instanceof de){o=s.value5;return}if(R instanceof Ue)return u=!0,new T(s.value3);throw new Error("Failed pattern match at Data.Map.Internal (line 281, column 7 - line 284, column 22): "+[R.constructor.name])}throw new Error("Failed pattern match at Data.Map.Internal (line 278, column 8 - line 284, column 22): "+[s.constructor.name])}for(;!u;)i=l(o);return i};return t}};var fj=function(e){var n=Qe(e);return function(a){return function(t){var o=function(u){if(u instanceof rl)return cS(a)(t);if(u instanceof Ao){var i=n(a)(u.value2);if(i instanceof De)return vj(u.value2,u.value3,o(u.value4),u.value5);if(i instanceof de)return vj(u.value2,u.value3,u.value4,o(u.value5));if(i instanceof Ue)return new Ao(u.value0,u.value1,a,t,u.value4,u.value5);throw new Error("Failed pattern match at Data.Map.Internal (line 469, column 7 - line 472, column 35): "+[i.constructor.name])}throw new Error("Failed pattern match at Data.Map.Internal (line 466, column 8 - line 472, column 35): "+[u.constructor.name])};return o}}};var fs=function(){return rl.value}(),ul=function(e){var n=fj(e);return function(a){return Bt(a)(function(t){return function(o){return n(o.value0)(o.value1)(t)}})(fs)}};var jae=typeof Array.from=="function",dj=typeof Symbol!="undefined"&&Symbol!=null&&typeof Symbol.iterator!="undefined"&&typeof String.prototype[Symbol.iterator]=="function",Oae=typeof String.prototype.fromCodePoint=="function",Uae=typeof String.prototype.codePointAt=="function",mj=function(e){return Uae?function(n){return n.codePointAt(0)}:e},hj=function(e){return function(n){return function(a){return function(t){return function(o){return function(u){var i=u.length;if(o<0||o>=i)return a;if(dj)for(var l=u[Symbol.iterator](),s=o;;--s){var R=l.next();if(R.done)return a;if(s===0)return n(t(R.value))}return e(o)(u)}}}}}};var Dj=function(e){return Oae?String.fromCodePoint:e},gj=function(e){return function(n){return dj?function(a){for(var t="",o=a[Symbol.iterator](),u=0;u1;if(a){var t=km(Kc(1)(e)),o=Ej(t);return o?bj(n)(t):n}return n},vS=mj(Kae),ey=Rj(Qae)(vS),Ko=function(e){return uo(ey(e))};var Tj=function(e){return function(n){return wj(function(a){return Ko(Gf(a)(n))})(vR(e)(n))}},fS=function(){var e=uT(jf)(tt(Xs))(qt(Xs));return function(n){return ju(e(n))}}(),Yae=function(e){if(e<=65535)return fS(e);var n=Wae(e-65536|0)(1024)+55296|0,a=$ae(e-65536|0)(1024)+56320|0;return fS(n)+fS(a)};var _S=Dj(Yae),Sj=function(e){return function(n){if(e<1)return"";var a=Qf(n);return a instanceof T?_S(a.value0.head)+Sj(e-1|0)(a.value0.tail):n}},xl=gj(Sj);var ny={eq:function(e){return function(n){return e===n}}},ay={compare:function(e){return function(n){return zae(e)(n)}},Eq0:function(){return ny}},Bm=function(e){return function(n){return rc(Gl(xl(e)(n)))(n)}};var Xae=function(e){return function(n){var a=e,t=!1,o;function u(i,l){var s=Qf(l);if(s instanceof T){var R=i===0;if(R)return t=!0,new T(s.value0.head);a=i-1|0,n=s.value0.tail;return}return t=!0,M.value}for(;!t;)o=u(a,n);return o}},pS=function(e){return function(n){return e<0?M.value:e===0&&n===""?M.value:e===0?new T(vS(n)):hj(Xae)(T.create)(M.value)(vS)(e)(n)}},Zae={bottom:0,top:1114111,Ord0:function(){return ay}},fc=function(){return{cardinality:1114111+1|0,fromEnum:function(e){return e},toEnum:function(e){if(e>=0&&e<=1114111)return new T(e);if($e)return M.value;throw new Error("Failed pattern match at Data.String.CodePoints (line 63, column 1 - line 68, column 26): "+[e.constructor.name])},Bounded0:function(){return Zae},Enum1:function(){return ete(0)}}}(),ete=qae("enumCodePoint","Data.String.CodePoints",function(){return{succ:xf(oa(fc))(Jn(fc)),pred:Nf(oa(fc))(Jn(fc)),Ord0:function(){return ay}}});var fte=ba();var Pj={show:fte};var xj=_e;var _te=uv(fn),pte=pe(ze),dte=gf(uS),In=function(e){return function(n){var a=_te(pte(n)(function(t){return new Dn(e(t),t)}));return function(t){return oc(t)(a)}}},mte=function(e){var n=aS(e),a=uj(e);return function(t){var o=n(t);return function(u){return function(i){return dte(function(l){return new Dn(l,o(l))})(a(i))}}}},Un=function(e){var n=mte(e);return function(a){var t=n(a);return function(o){var u=t(o);return function(i){return ap(u(i))}}}};var hte={info:"info",warning:"warn",error:"error"},Nl=e=>n=>a=>t=>{let o=hte[e];if(typeof console!="undefined"&&console[o]&&console[o](n,a),typeof window!="undefined"){let u=new Error(n);typeof window.Sentry!="undefined"&&window.Sentry.captureException(u,{extra:a})}return t()},Nj=(e,n)=>(n.__sentryFingerprint=e,n);var jj=function(e){return qi(Nj)(e)};var _c="error";var ry={parseOrPanic:function(e){return function(n){var a=e.parse(n);if(a instanceof Le)return a.value0;if(a instanceof Me)return Nl(_c)("Failed to parse "+e.diagnosticName)({error:a.value0,value:n})(function(t){return e.default});throw new Error("Failed pattern match at Utils.Parse (line 49, column 5 - line 57, column 24): "+[a.constructor.name])}}},ta=function(e){return e.parseOrPanic},Dte=ta(ry),Na=function(e){var n=ta(e);return function(a){var t=k(a);return function(o){return n({parse:function(u){return t(T.create)(o.parse(u))},default:M.value,diagnosticName:o.diagnosticName})}}},gte=Na(ry)(Dr),_s=function(e){var n=Pf(e);return function(a){return gte({parse:n,diagnosticName:a})}},Ye={parseOrPanic:function(e){return Dte({default:e.default,diagnosticName:e.diagnosticName,parse:function(){var n=bn(new Me(""))(Le.create);return function(a){return n(e.parse(a))}}()})}};var Oj=xn(Pn),Uj=Mn(Gn),kj=On(jn),ps=function(){function e(){}return e.value=new e,e}(),ds=function(){function e(){}return e.value=new e,e}(),Rte={to:function(e){if(e instanceof ge)return ps.value;if(e instanceof ie)return ds.value;throw new Error("Failed pattern match at Sem.Connections.Types.Actor (line 20, column 1 - line 20, column 32): "+[e.constructor.name])},from:function(e){if(e instanceof ps)return new ge(xe.value);if(e instanceof ds)return new ie(xe.value);throw new Error("Failed pattern match at Sem.Connections.Types.Actor (line 20, column 1 - line 20, column 32): "+[e.constructor.name])}};var yte=function(e){if(e instanceof ps)return"school";if(e instanceof ds)return"vine";throw new Error("Failed pattern match at Sem.Connections.Types.Actor (line 32, column 1 - line 32, column 29): "+[e.constructor.name])},oy=function(){return ta(Ye)({parse:In(yte)(Un(Rte)(Ln(Oj)(Fn(Cn))(Oj)(Uj))(Nn(kj)(kj))(An(Uj))),default:ps.value,diagnosticName:"Sem.Connections.Types.Actor"})}();var Bj=xn(Pn),Hj=Ln(Bj)(Fn(Cn)),qj=Mn(Gn),Jj=An(qj),Wj=On(jn),$j=Nn(Wj),wte=ma($r),jl=function(){function e(){}return e.value=new e,e}(),Ev=function(){function e(){}return e.value=new e,e}(),ms=function(){function e(){}return e.value=new e,e}(),bte={to:function(e){if(e instanceof ge)return jl.value;if(e instanceof ie&&e.value0 instanceof ge)return Ev.value;if(e instanceof ie&&e.value0 instanceof ie)return ms.value;throw new Error("Failed pattern match at Sem.Connections.Types.Status (line 24, column 1 - line 24, column 33): "+[e.constructor.name])},from:function(e){if(e instanceof jl)return new ge(xe.value);if(e instanceof Ev)return new ie(new ge(xe.value));if(e instanceof ms)return new ie(new ie(xe.value));throw new Error("Failed pattern match at Sem.Connections.Types.Status (line 24, column 1 - line 24, column 33): "+[e.constructor.name])}};var Ete=function(e){if(e instanceof jl)return"pending";if(e instanceof Ev)return"connected";if(e instanceof ms)return"ignored";throw new Error("Failed pattern match at Sem.Connections.Types.Status (line 40, column 1 - line 40, column 30): "+[e.constructor.name])},mS=function(){var e=In(Ete)(Un(bte)(Hj(Hj(Bj)(qj))(Jj))($j($j(Wj)))(Jj)),n=function(a){return a==="cold"?new T(ms.value):M.value};return ta(Ye)({parse:function(a){return wte(e(a))(n(a))},default:jl.value,diagnosticName:"Sem.Connections.Types.Status"})}();var Ite=g3(yt),zj=ne(Ze),Tte=vi(yt),Ste=Ua(Y);var Vj=function(e){return{initiator:oy(e.initiator),status:mS(e.status),introMessage:ke("")(fe(e.introMessage))}},Qj=25,hS=function(e){return Ko(e)>=Qj},Kj=function(e){var n=Ko(e),a=n>0,t=Ite(" ")([function(){return a?zj(n)+" characters":""}(),Tte(["(",zj(Qj),function(){return a?"":" character"}()," minimum)"])]),o=function(){var u=hS(e);return u?"text-success":""}();return Ste(o)(t)};var uy=function(){function e(){}return e.value=new e,e}(),Yj=function(){function e(){}return e.value=new e,e}();var Xj=function(){var e=ta(Ye)({parse:function(n){return n instanceof T&&n.value0==="paid"?new T(Yj.value):n instanceof T&&n.value0==="free"?new T(uy.value):n instanceof T&&n.value0==="churned"?new T(uy.value):n instanceof M?new T(uy.value):M.value},default:uy.value,diagnosticName:"Sem.Types.PartnerStatus"});return function(n){return e(fe(n))}}();var Zj=function(e){return{allowedToContact:e.allowedToContact,id:e.id,name:e.name,imageUrl:fe(e.imageUrl),partnerStatus:Xj(e.partnerStatus)}};var Cte=Z(en),DS=Sa(),Hm=Wa(_e),e4=B({reflectSymbol:function(){return"id"}}),Fte=un(tn)(en),Gte=yr(Br),Mte=k(ae);var Ate=function(){function e(){}return e.value=new e,e}(),Lte=function(){function e(){}return e.value=new e,e}(),Pte=function(){function e(){}return e.value=new e,e}(),gS=function(){function e(){}return e.value=new e,e}(),xte=function(){function e(){}return e.value=new e,e}(),iy=function(){function e(){}return e.value=new e,e}(),qm=function(){function e(){}return e.value=new e,e}(),RS=function(){function e(){}return e.value=new e,e}(),yS=function(){function e(){}return e.value=new e,e}();var n4={show:ba()};var Nte=_e,jte=_s(DS(B({reflectSymbol:function(){return"avatarUrl"}})(Hm)(B({reflectSymbol:function(){return"bio"}})(Hm)(B({reflectSymbol:function(){return"connection"}})(Wa(DS(B({reflectSymbol:function(){return"initiator"}})(_e)(B({reflectSymbol:function(){return"introMessage"}})(Hm)(B({reflectSymbol:function(){return"status"}})(_e)(rn))))))(B({reflectSymbol:function(){return"firstName"}})(_e)(e4(Nte)(B({reflectSymbol:function(){return"lastName"}})(_e)(B({reflectSymbol:function(){return"school"}})(DS(B({reflectSymbol:function(){return"allowedToContact"}})(Ia)(e4(xj)(B({reflectSymbol:function(){return"imageUrl"}})(Hm)(B({reflectSymbol:function(){return"name"}})(_e)(B({reflectSymbol:function(){return"partnerStatus"}})(Hm)(rn)))))))(B({reflectSymbol:function(){return"title"}})(_e)(B({reflectSymbol:function(){return"type"}})(_e)(B({reflectSymbol:function(){return"unreadMessageCountFromSemUser"}})(on)(rn))))))))))));var a4=function(e){if(e instanceof Ate)return"sheet-view";if(e instanceof Lte)return"school-details";if(e instanceof Pte)return"network-gallery";if(e instanceof gS)return"livestream-details";if(e instanceof xte)return"card-view";throw new Error("Failed pattern match at Sem.Types.User (line 105, column 25 - line 110, column 26): "+[e.constructor.name])},t4=function(e){return Cte(jte("SemUser")(e))(function(n){return Fte(Gte(n.type==="Sem::User"))(function(){return new T({school:Zj(n.school),firstName:n.firstName,lastName:n.lastName,avatarUrl:fe(n.avatarUrl),title:n.title,bio:fe(n.bio),connection:Mte(Vj)(fe(n.connection)),unreadMessageCountFromSemUser:n.unreadMessageCountFromSemUser,id:n.id})})})};var hs=function(e){var n=null;return function(){return e===void 0||(n=e(),e=void 0),n}},Ds=function(e){return e()};var f4=function(){function e(){}return e.value=new e,e}(),_4=function(){function e(){}return e.value=new e,e}(),p4=function(){function e(){}return e.value=new e,e}();var Zte=function(e){if(e instanceof f4)return"disabled";if(e instanceof _4)return"free-consultation";if(e instanceof p4)return"more-information";throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types.InquiryMode (line 31, column 13 - line 34, column 40): "+[e.constructor.name])};var ere=function(){return[f4.value,_4.value,p4.value]}(),d4=Na(Ye)(ae)({parse:In(Zte)(ere),diagnosticName:"InquiryMode"});var nre=function(e,n,a,t,o,u,i){var l=new Date(Date.UTC(e,n,a,t,o,u,i));return e>=0&&e<100&&l.setUTCFullYear(e),l};function m4(e,n,a,t,o,u,i){return nre(e,n-1,a,t,o,u,i).getTime()}function h4(e){return function(n){var a=new Date(n);return e(a.getUTCFullYear())(a.getUTCMonth()+1)(a.getUTCDate())(a.getUTCHours())(a.getUTCMinutes())(a.getUTCSeconds())(a.getUTCMilliseconds())}}var are=St(),tre=oa(rr);var rre=Jn(rr);var D4=function(e){return e},sy=function(){var e=function(n){return function(a){return function(t){return function(o){return function(u){return function(i){return function(l){return new cc(vv(n)(are(tre(a)))(t),new ic(o,u,i,l))}}}}}}};return h4(e)}();var g4=function(e){return m4($u(e.value0),rre(zu(e.value0)),uc(e.value0),lc(e.value1),as(e.value1),ns(e.value1),Xi(e.value1))};var R4=function(e){var n=an(e.Semigroup0()),a=function(t){return function(o){return function(u){var i=t,l=o,s=!1,R;function d(y,I,b){if(b<1)return s=!0,y;i=n(y)(I),l=I,u=b-1|0}for(;!s;)R=d(i,l,u);return R}}};return a(Xa(e))};var ore=ba();var Kf=function(){function e(n,a,t){this.value0=n,this.value1=a,this.value2=t}return e.create=function(n){return function(a){return function(t){return new e(n,a,t)}}},e}(),Jm=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}();var y4=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),w4=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),TS=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}();var rp={defer:function(e){var n=hs(e);return function(a,t,o,u,i){var l=Ds(n);return l(a,t,o,u,i)}}};var pc={map:function(e){return function(n){return function(a,t,o,u,i){return t(function(l){return n(a,t,o,u,function(s,R){return t(function(d){return i(s,e(R))})})})}}}};var dc={apply:function(e){return function(n){return function(a,t,o,u,i){return t(function(l){return e(a,t,o,u,function(s,R){return t(function(d){return n(s,t,o,u,function(y,I){return t(function(b){return i(y,R(I))})})})})})}}},Functor0:function(){return pc}};var mc={bind:function(e){return function(n){return function(a,t,o,u,i){return t(function(l){return e(a,t,o,u,function(s,R){return t(function(d){var y=n(R);return y(s,t,o,u,i)})})})}}},Apply0:function(){return dc}},ure=Ja(mc);var il={pure:function(e){return function(n,a,t,o,u){return u(n,e)}},Apply0:function(){return dc}};var ire={Applicative0:function(){return il},Bind1:function(){return mc}};var b4={throwError:function(e){return function(n,a,t,o,u){return o(n,e)}},Monad0:function(){return ire}},lre=Pr(b4);var Yf={alt:function(e){return function(n){return function(a,t,o,u,i){return t(function(l){return e(new Kf(a.value0,a.value1,!1),t,o,function(s,R){return t(function(d){return s.value2?u(s,R):n(a,t,o,u,i)})},i)})}}},Functor0:function(){return pc}},cre=function(e){return function(n,a,t,o,u){var i=e(n);return u(i.value1,i.value0)}};var sre=function(e){var n=e.Monad0(),a=k(n.Bind1().Apply0().Functor0()),t=W(n.Applicative0()),o=To(e);return function(u){return function(i){var l=function(s){var R=!1,d;function y(I){var b=I(Ee);if(b instanceof y4){s=b.value0;return}if(b instanceof w4)return R=!0,a(Jt.create)(b.value0);if(b instanceof TS)return R=!0,t(new kt(new Dn(b.value1,b.value0)));throw new Error("Failed pattern match at Parsing (line 152, column 13 - line 158, column 32): "+[b.constructor.name])}for(;!R;)d=y(s);return d};return o(l)(function(s){return i(u,y4.create,w4.create,function(R,d){return new TS(R,new Me(d))},function(R,d){return new TS(R,new Le(d))})})}}};var E4=cre(function(e){return new Dn(e.value1,e)}),SS=function(e){return e.value1},CS=function(e){return e.value0};var vre={index:0,line:1,column:1},I4=function(e){var n=k(e.Monad0().Bind1().Apply0().Functor0()),a=sre(e);return function(t){return function(o){var u=new Kf(t,vre,!1);return n(So)(a(u)(o))}}},fre=I4(kd),T4=function(e){var n=fre(e);return function(a){return ore(n(a))}};var _re=function(e){return function(n){return lre(new Jm(e,n))}},op=function(e){return ure(_re(e))(E4)};var S4={empty:op("No alternative"),Alt0:function(){return Yf}},Xf={Applicative0:function(){return il},Plus1:function(){return S4}};var wre=ma(Yf);var bre=W(il);var Ere=k(pc);var hc=function(e){return function(n,a,t,o,u){return e(n,a,t,function(i,l){return o(new Kf(i.value0,i.value1,n.value2),l)},u)}};var vy=function(e){return function(n){return wre(n)(bre(e))}},Zf=function(e){return vy(M.value)(Ere(T.create)(e))};var F4=function(e){return function(n){return function(a){return function(t){try{return n(new RegExp(a,t))}catch(o){return e(o.message)}}}}};var Wm=function(e){return function(n){return function(a){return a.replace(e,n)}}};var GS={append:function(e){return function(n){return{global:e.global||n.global,ignoreCase:e.ignoreCase||n.ignoreCase,multiline:e.multiline||n.multiline,dotAll:e.dotAll||n.dotAll,sticky:e.sticky||n.sticky,unicode:e.unicode||n.unicode}}}};var fy={global:!1,ignoreCase:!0,multiline:!1,dotAll:!1,sticky:!1,unicode:!1},up={global:!0,ignoreCase:!1,multiline:!1,dotAll:!1,sticky:!1,unicode:!1};var Ire=function(e){return function(){return e.global?"g":""}()+(function(){return e.ignoreCase?"i":""}()+(function(){return e.multiline?"m":""}()+(function(){return e.dotAll?"s":""}()+(function(){return e.sticky?"y":""}()+function(){return e.unicode?"u":""}()))))},gs=function(e){return function(n){return F4(Me.create)(Le.create)(e)(Ire(n))}};var L4=Jn(fc),Sre=Io(ar);var Cre=ne(nr);var P4=function(e){return function(n){return function(a){var t=L4(n);if(t===10)return{index:e.index+1|0,line:e.line+1|0,column:1};if(t===13){var o=pS(0)(a);return o instanceof T&&L4(o.value0)===10?{index:e.index+1|0,line:e.line,column:e.column}:{index:e.index+1|0,line:e.line+1|0,column:1}}return t===9?{index:e.index+1|0,line:e.line,column:(e.column+8|0)-Sre(e.column-1|0)(8)|0}:{index:e.index+1|0,line:e.line,column:e.column+1|0}}}},Fre=function(e){return function(n){return function(a){var t=e,o=n,u=!1,i;function l(s,R,d){var y=Qf(R);if(y instanceof M)return u=!0,s;if(y instanceof T){var I=function(){if(yi(y.value0.tail))return P4(s)(y.value0.head)(d);if($e)return P4(s)(y.value0.head)(y.value0.tail);throw new Error("Failed pattern match at Parsing.String (line 165, column 7 - line 167, column 52): "+[])}();t=I,o=y.value0.tail,a=d;return}throw new Error("Failed pattern match at Parsing.String (line 161, column 36 - line 168, column 38): "+[y.constructor.name])}for(;!u;)i=l(t,o,a);return i}}};var AS=jg(function(e){return function(n){return function(a){return function(t){return function(o){var u=yi(e.value0);return u?o(new Kf(e.value0,e.value1,!0),Ee):t(e,new Jm("Expected EOF",e.value1))}}}}}),x4=function(e){return jg(function(n){return function(a){return function(t){return function(o){return function(u){var i=e(n.value0);if(i instanceof Me)return o(n,new Jm(i.value0,n.value1));if(i instanceof Le)return u(new Kf(i.value0.remainder,Fre(n.value1)(i.value0.consumed)(i.value0.remainder),!yi(i.value0.consumed)),i.value0.value);throw new Error("Failed pattern match at Parsing.String (line 286, column 7 - line 290, column 121): "+[i.constructor.name])}}}}})};var Dc=function(e){return x4(function(n){var a=fi(e)(n);return a instanceof T?new Le({value:e,consumed:e,remainder:a.value0}):new Me("Expected "+Cre(e))})};var N4=ne(Ze),Mre=fr(Au),Are=t0(dc);var Lre=function(e){return"(line "+(N4(e.line)+(", col "+(N4(e.column)+")")))},Pre=function(e){return CS(e)+(" "+Lre(SS(e)))},LS=function(e){return function(n){return Mre(Pre)(T4(n)(Are(e)(AS)))}};var _y=oa(jf);var Lo=ne(Ze);var $re=Lr(Co),zre=$re(yt);var Vre=hI(na)(Yl);var PS=Jn(xr),Qre=ne(dR),Kre=Jn(rr),B4=Jn(pu),Yre=ba(),Xre=Jn(cv),H4=ne(MP),xS=Jn(hi),Zre=Io(ar),q4=Jn(mi),J4=Jn(di),NS=Jn(du),W4=io(ar);var ip=function(){function e(){}return e.value=new e,e}(),$4=function(){function e(){}return e.value=new e,e}(),eoe=function(){function e(){}return e.value=new e,e}(),Ol=function(){function e(){}return e.value=new e,e}(),jS=function(){function e(){}return e.value=new e,e}(),z4=function(){function e(){}return e.value=new e,e}(),V4=function(){function e(){}return e.value=new e,e}(),Ul=function(){function e(){}return e.value=new e,e}(),noe=function(){function e(){}return e.value=new e,e}(),aoe=function(){function e(){}return e.value=new e,e}(),kl=function(){function e(){}return e.value=new e,e}(),toe=function(){function e(){}return e.value=new e,e}(),OS=function(){function e(){}return e.value=new e,e}(),Bl=function(){function e(){}return e.value=new e,e}(),Hl=function(){function e(){}return e.value=new e,e}(),roe=function(){function e(){}return e.value=new e,e}(),wi=function(){function e(){}return e.value=new e,e}(),ooe=function(){function e(){}return e.value=new e,e}(),US=function(){function e(){}return e.value=new e,e}(),uoe=function(){function e(){}return e.value=new e,e}(),ioe=function(){function e(){}return e.value=new e,e}(),loe=function(){function e(){}return e.value=new e,e}(),ht=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var coe=function(e){if(e instanceof su)return"Jan";if(e instanceof Uu)return"Feb";if(e instanceof vu)return"Mar";if(e instanceof ku)return"Apr";if(e instanceof Bu)return"May";if(e instanceof fu)return"Jun";if(e instanceof _u)return"Jul";if(e instanceof Hu)return"Aug";if(e instanceof qu)return"Sep";if(e instanceof Ju)return"Oct";if(e instanceof Wu)return"Nov";if(e instanceof pi)return"Dec";throw new Error("Failed pattern match at Data.Formatter.DateTime (line 489, column 19 - line 501, column 22): "+[e.constructor.name])};var Tv=function(e){if(e<0)return"-"+Tv(-e|0);if(e<10)return"0"+Lo(e);if($e)return Lo(e);throw new Error("Failed pattern match at Data.Formatter.DateTime (line 194, column 1 - line 194, column 32): "+[e.constructor.name])},Q4=function(e){if(e<0)return"-"+Q4(-e|0);if(e<10)return"000"+Lo(e);if(e<100)return"00"+Lo(e);if(e<1e3)return"0"+Lo(e);if($e)return Lo(e);throw new Error("Failed pattern match at Data.Formatter.DateTime (line 207, column 1 - line 207, column 35): "+[e.constructor.name])},K4=function(e){if(e<0)return"-"+K4(-e|0);if(e<10)return"00"+Lo(e);if(e<100)return"0"+Lo(e);if($e)return Lo(e);throw new Error("Failed pattern match at Data.Formatter.DateTime (line 200, column 1 - line 200, column 32): "+[e.constructor.name])};var soe=function(e){var n=Lo(Vre(e)),a=Ko(n);return a===1?"0"+n:a===2?n:Bm(a-2|0)(n)};var voe=function(e){var n=e===0;return n?12:e},foe=function(e){return function(n){if(n instanceof ip)return Q4(PS($u(e.value0)));if(n instanceof $4)return soe(PS($u(e.value0)));if(n instanceof eoe)return Lo(PS($u(e.value0)));if(n instanceof Ol)return Qre(zu(e.value0));if(n instanceof jS)return coe(zu(e.value0));if(n instanceof z4)return Tv(Kre(zu(e.value0)));if(n instanceof V4)return Tv(B4(uc(e.value0)));if(n instanceof Ul)return Lo(B4(uc(e.value0)));if(n instanceof noe)return Lo(co(function(t){return t/1e3}(Yre(D4(g4(e))))));if(n instanceof aoe)return Lo(Xre(pm(e.value0)));if(n instanceof kl)return H4(pm(e.value0));if(n instanceof toe)return xl(3)(H4(pm(e.value0)));if(n instanceof OS)return Tv(xS(lc(e.value1)));if(n instanceof Bl)return Tv(voe(Zre(xS(lc(e.value1)))(12)));if(n instanceof Hl){var a=xS(lc(e.value1))>=12;return a?"PM":"AM"}if(n instanceof roe)return Lo(q4(as(e.value1)));if(n instanceof wi)return Tv(q4(as(e.value1)));if(n instanceof ooe)return Lo(J4(ns(e.value1)));if(n instanceof US)return Tv(J4(ns(e.value1)));if(n instanceof uoe)return K4(NS(Xi(e.value1)));if(n instanceof ioe)return Lo(function(t){return W4(t)(100)}(NS(Xi(e.value1))));if(n instanceof loe)return Tv(function(t){return W4(t)(10)}(NS(Xi(e.value1))));if(n instanceof ht)return n.value0;throw new Error("Failed pattern match at Data.Formatter.DateTime (line 169, column 38 - line 192, column 21): "+[n.constructor.name])}},Po=function(e){return function(n){return zre(foe(n))(e)}};function py(e){return Math.round(e).toString()}var lp=Z(mc);var _oe=W(il),poe=I0(Xf)(rp);var doe=qI(Xf)(rp),dy=R4(yt),moe=y0(il)(Vd),hoe=k(ae);var Y4=Hc(na),Doe=io(ar),goe=ne(Ze),Roe=pe(Dr),yoe=ne(cf),woe=pn(dn);var boe=lp(Zf(hc(Dc("+"))))(function(e){return lp(poe(Dc("0")))(function(n){return lp(Zf(hc(Dc(",0"))))(function(a){return lp(Zf(hc(Dc("."))))(function(t){return lp(moe(t)(function(o){return hc(doe(Dc("0")))}))(function(o){return lp(Zf(hc(Dc("a"))))(function(u){return _oe({sign:Ct(e),before:uo(n),comma:Ct(a),after:ke(0)(hoe(uo)(o)),abbreviations:Ct(u)})})})})})})}),Eoe=LS(boe);var X4=function(e){return function(n){var a=Jg(n),t=function(){if(a>0)return Y4(co($I(a)/L3))(0);if($e)return 0;throw new Error("Failed pattern match at Data.Formatter.Number (line 100, column 5 - line 102, column 22): "+[])}();if(e.abbreviations){var o=Doe(t)(3),u=function(){var $=o<1;return $?n:n/Wg(1e3)(Ft(o))}(),i=function(){if(o===0)return"";if(o===1)return"K";if(o===2)return"M";if(o===3)return"G";if(o===4)return"T";if(o===5)return"P";if(o===6)return"E";if(o===7)return"Z";if(o===8)return"Y";if($e)return"10e+"+goe(o*3|0);throw new Error("Failed pattern match at Data.Formatter.Number (line 107, column 7 - line 117, column 53): "+[])}();return X4({comma:e.comma,before:e.before,after:e.after,sign:e.sign,abbreviations:!1})(u)+i}var l=(e.before-t|0)-1|0,s=Wg(10)(Ft(Y4(0)(e.after))),R=Ef(a*s)/s,d=T0(R),y=R-d,I=Ef(y*s),b=function(){var $=py(I),z=Ko($),ee=dy("0")(e.after-z|0);return ee+$}(),S=function(){var $=e.after<1;return $?"":"."+(function(){var z=I===0;return z?dy("0")(e.after):""}()+function(){var z=I>0;return z?b:""}())}(),L=function($){return function(z){return function(ee){var oe=$,te=z,ve=!1,Re;function nn(cn,ce,le){var Ne=Qd(le);if(Ne instanceof M)return ve=!0,G0(cn);if(Ne instanceof T&&ce<3){oe=qo(Ne.value0.head)(cn),te=ce+1|0,ee=Ne.value0.tail;return}oe=qo(",")(cn),te=0,ee=le}for(;!ve;)Re=nn(oe,te,ee);return Re}}},O=function(){return e.comma?L([])(0)(Ad(tm(dy("0")(l)+py(d)))):dy("0")(l)+py(d)}();return function(){var $=n<0;if($)return"-";var z=n>0&&e.sign;return z?"+":""}()+(O+S)}},Ioe=function(e){return function(n){return Roe(Eoe(e))(za(X4)(n))}},e_=function(e){return function(n){return Ut(hn(yoe(n)))(woe)(Ioe(e)(n))}};var Soe=Je;var Z4=function(e){return Tf(e)};var ll=function(e){var n=Z4(e);return n?M.value:new T(Soe(e))};var Ka=function(e){return function(n){var a=Z4(e);return a?n:e}};var Vr=function(){return Je};var $m=ne(Ze),Coe=Jn(xr),Foe=Jn(rr),Goe=Vr(),Moe=uu(),Aoe=Qu(sv),kS=io(ar),Loe=Wo(fn);var Poe=function(e){return function(n){if(n.minutes<=0)return e.justNow;if(n.minutes<=1)return"a minute"+e.suffix;if(n.minutes<=45)return $m(n.minutes)+(" minutes"+e.suffix);if(n.hours<=1)return"an hour"+e.suffix;if(n.hours<24)return $m(n.hours)+(" hours"+e.suffix);if(n.days<=1)return"a day"+e.suffix;if(n.days<30)return $m(n.days)+(" days"+e.suffix);if(n.months<=1)return"a month"+e.suffix;if(n.months<12)return $m(n.months)+(" months"+e.suffix);if(n.years<=1)return"a year"+e.suffix;if($e)return $m(n.years)+(" years"+e.suffix);throw new Error("Failed pattern match at Utils.Format (line 150, column 1 - line 150, column 81): "+[e.constructor.name,n.constructor.name])}},my=function(e){return Poe({suffix:" "+e,justNow:"just now"})},e8=function(){return function(e){var n=function(R){return(Coe($u(Of(R)))*12|0)+Foe(zu(Of(R)))|0},a=Goe(e),t=Ka(a.format)(my("ago")),o=$g(Moe(Aoe(a.to)(a.from))),u=kS(o+30|0)(60),i=kS(u+12|0)(24),l=n(a.to)-n(a.from)|0,s=kS(l+6|0)(12);return t({minutes:o,hours:u,days:i,months:l,years:s})}};var xoe=function(e){return function(n){return function(a){var t=e===1;return t?n:a}}},cl=function(e){return function(n){return function(a){return e_("0,0")(Ft(e))+(" "+xoe(e)(n)(a))}}};var n8=e_("0,0");var a8=function(){return Po(Loe([kl.value,new ht(", "),Ol.value,new ht(" "),Ul.value,new ht(" at "),Bl.value,new ht(":"),wi.value,new ht(" "),Hl.value]))}();var BS=()=>document.visibilityState=="visible",t8=(e,n)=>document.elementFromPoint(e,n);var r8=function(){return function(){return WN("br")}};function o8(e){return function(n){return function(){return n.getElementById(e)}}}var Noe=k(zn),hy=function(e){var n=Noe(fe),a=o8(e);return function(t){return n(a(t))}};var Dy=function(e){return function(n){return function(){return n[e]}}},joe=Dy("children"),Ooe=Dy("firstElementChild"),Uoe=Dy("lastElementChild"),koe=Dy("childElementCount");var Yu=function(){return window};function u8(e,n,a,t){if(typeof window!="undefined"){var o=window[a];if(o!=null&&t instanceof o)return n(t)}for(var u=t;u!=null;){var i=Object.getPrototypeOf(u),l=i.constructor.name;if(l===a)return n(t);if(l==="Object")return e;u=i}return e}var Tn=function(e){return function(n){return u8(M.value,T.create,e,n)}};var i8=Je;var gy=Je;function l8(e,n,a){var t=Object.prototype.toString.call(a);return t.indexOf("[object HTML")===0&&t.indexOf("Element]")===t.length-8?n(a):e}var HS=Je;var c8=function(e){return l8(M.value,T.create,e)};function qS(e){return function(){return e.seeking}}function zm(e){return function(){return e.currentTime}}function JS(e){return function(){return e.volume}}function WS(e){return function(n){return function(){n.volume=e}}}function $S(e){return function(){return e.muted}}function n_(e){return function(n){return function(){n.muted=e}}}var s8=Tn("HTMLMediaElement");var v8=Tn("HTMLMediaElement");function zS(e){return function(){return e.hash}}function VS(e){return function(n){return function(){n.hash=e}}}function QS(e){return function(n){return function(){n.href=e}}}function KS(e){return function(){return e.platform}}function cp(e){return function(){return e.document}}function YS(e){return function(){return e.navigator}}function sp(e){return function(){return e.location}}var Yoe=k(ze);var Xoe=r8()(),Zoe=y0(rt)(Vd),f8=Z(tr),_8=pe(zn),eue=Z(en);var p8=Ke("\xA0");var da=za(bn($n));var nue=function(e){return function(n){if(e)return $n;if($e)return n(Ee);throw new Error("Failed pattern match at Utils.HTML (line 107, column 1 - line 107, column 65): "+[e.constructor.name,n.constructor.name])}},d8=function(e){return function(n){return nue(e)(hn(n))}};var m8=function(e){return function(n){if(e)return n(Ee);if($e)return $n;throw new Error("Failed pattern match at Utils.HTML (line 94, column 1 - line 94, column 61): "+[e.constructor.name,n.constructor.name])}},ya=function(e){return function(n){return m8(e)(hn(n))}};var Vm=function(e){return Se(BI(Xoe({}))(Yoe(Ke)(Qo(` `)(e))))},Ry=function(e){return Zoe(v8(e.target))(zm)};var h8=function(e){return function(){return t8(e.x,e.y)}},D8=function(e){return f8(_8(f8(Yu)(cp))(gy))(hy(e))},yy=function(e){return _8(D8(e))(function(n){return eue(n)(c8)})};var fp=on;var g8=({just:e,nothing:n})=>a=>{try{let t=new Date(a);return isNaN(t.getTime())?n:e(t)}catch{return n}},XS=e=>({year:e.getFullYear(),month:e.getMonth(),day:e.getDate(),hour:e.getHours(),minute:e.getMinutes(),second:e.getSeconds(),millisecond:e.getMilliseconds()}),R8=()=>new Date,y8=(()=>{let e=new Date;return typeof window!="undefined"?()=>e:()=>{let n=new Date;return n-e>1e3&&(e=n),e}})();var a_=(()=>{let e=new Date().toString(),n=(e.match(/\(([\w\s]+)\)$/)||[])[1];return n?/\s/.test(n)?(n.match(/\b(\w)/g)||[]).join(""):n:(n=(e.match(/(\w{3,4})\s\d{4}$/)||[])[1],n||(n=(e.match(/(UTC[\+\-]\d+)/)||[])[1],n)||(n=(e.match(/(GMT[\+\-]\d+)/)||[])[1],n)?n:"")})();function ZS(){return Date.now()}var oue=k(zn);var Xu=oue(sy)(ZS);var w8={liftAff:pn(dn),MonadEffect0:function(){return Ve}};var u7n=function(){function e(){this.head=null,this.last=null,this.size=0}function n(d,y){this.queue=d,this.value=y,this.next=null,this.prev=null}function a(d){this.draining=!1,this.error=null,this.value=d,this.takes=new e,this.reads=new e,this.puts=new e}var t={};function o(d){try{d()}catch(y){setTimeout(function(){throw y},0)}}function u(d,y){var I=new n(d,y);switch(d.size){case 0:d.head=I;break;case 1:I.prev=d.head,d.head.next=I,d.last=I;break;default:I.prev=d.last,d.last.next=I,d.last=I}return d.size++,I}function i(d){var y;switch(d.size){case 0:return null;case 1:y=d.head,d.head=null;break;case 2:y=d.last,d.head.next=null,d.last=null;break;default:y=d.last,d.last=y.prev,d.last.next=null}return y.prev=null,y.queue=null,d.size--,y.value}function l(d){var y;switch(d.size){case 0:return null;case 1:y=d.head,d.head=null;break;case 2:y=d.head,d.last.prev=null,d.head=d.last,d.last=null;break;default:y=d.head,d.head=y.next,d.head.prev=null}return y.next=null,y.queue=null,d.size--,y.value}function s(d){if(d.queue!==null){if(d.queue.last===d){i(d.queue);return}if(d.queue.head===d){l(d.queue);return}d.prev&&(d.prev.next=d.next),d.next&&(d.next.prev=d.prev),d.queue.size--,d.queue=null,d.value=null,d.next=null,d.prev=null}}function R(d,y){if(!y.draining){var I=y.puts,b=y.takes,S=y.reads,L,O,$,z,ee;for(y.draining=!0;;){if(L=null,O=null,$=null,z=y.value,ee=S.size,y.error!==null){for(z=d.left(y.error);L=l(I);)o(L.cb(z));for(;O=l(S);)o(O(z));for(;$=l(b);)o($(z));break}if(z===t&&(L=l(I))&&(y.value=z=L.value),z!==t){for($=l(b);ee--&&(O=l(S));)o(O(d.right(z)));$!==null&&(y.value=t,o($(d.right(z))))}if(L!==null&&o(L.cb(d.right(void 0))),y.value===t&&I.size===0||y.value!==t&&b.size===0)break}y.draining=!1}}return a.EMPTY=t,a.putLast=u,a.takeLast=i,a.takeHead=l,a.deleteCell=s,a.drainVar=R,a}();var pue=Z(tr);var Sv=Z(en),due=oa(xr),mue=oa(rr),hue=oa(pu),Due=oa(hi),gue=oa(mi),Rue=oa(di),yue=oa(du),wue=W(aa),E8=W(rt),I8=Ja(tr),bue=pe(ae);var Eue=function(){return ts($c(M.value))}();var T8=function(e){return Sv(due(e.year))(function(n){return Sv(mue(e.month+1|0))(function(a){return Sv(hue(e.day))(function(t){return Sv(Due(e.hour))(function(o){return Sv(gue(e.minute))(function(u){return Sv(Rue(e.second))(function(i){return Sv(yue(e.millisecond))(function(l){return wue(new cc(vv(n)(a)(t),new ic(o,u,i,l)))})})})})})})})},S8=function(e){var n=U3("Failed to obtain current time. This should never happen.");return bn(n)(E8)(T8(XS(e)))},t_=I8(S8)(R8),nC=function(e){return ts(pue(ec(Eue))(bn(I8(S8)(y8))(E8)))},hu=function(e){return Sv(bue(g8({just:T.create,nothing:M.value})(e))(XS))(T8)};var aC=W(aa),Sue=k(ae),C8=Z(en);var F8=xn(Pn),G8=Ln(F8)(Fn(Cn)),M8=Mn(Gn),A8=An(M8),L8=On(jn),P8=Nn(L8);var tC=function(){function e(){}return e.value=new e,e}(),rC=function(){function e(){}return e.value=new e,e}(),oC=function(){function e(){}return e.value=new e,e}();var Cue={to:function(e){if(e instanceof ge)return tC.value;if(e instanceof ie&&e.value0 instanceof ge)return rC.value;if(e instanceof ie&&e.value0 instanceof ie)return oC.value;throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types (line 183, column 1 - line 183, column 41): "+[e.constructor.name])},from:function(e){if(e instanceof tC)return new ge(xe.value);if(e instanceof rC)return new ie(new ge(xe.value));if(e instanceof oC)return new ie(new ie(xe.value));throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types (line 183, column 1 - line 183, column 41): "+[e.constructor.name])}};var Fue=function(e){if(e instanceof tC)return"stuffed";if(e instanceof rC)return"satisfied";if(e instanceof oC)return"hungry";throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types (line 242, column 27 - line 245, column 35): "+[e.constructor.name])};var Gue=Na(Ye)(ae)({parse:In(Fue)(Un(Cue)(G8(G8(F8)(M8))(A8))(P8(P8(L8)))(A8)),diagnosticName:"ClientAppetite"}),x8=function(e){return C8(bn(aC(M.value))(function(){var n=Sue(aC);return function(a){return n(Gue(a))}}())(fe(e.clientAppetite)))(function(n){return C8(d4(e.inquiryMode))(function(a){return aC({packages:e.packages,pricePerHourCents:e.pricePerHourCents,singleSessionDurationMinutes:e.singleSessionDurationMinutes,singleSessionRefundPeriodLengthDays:e.singleSessionRefundPeriodLengthDays,themes:e.themes,freeConsultationDurationMinutes:fe(e.freeConsultationDurationMinutes),canSubmitConsultInquiry:fe(e.canSubmitConsultInquiry),clientAppetite:n,inquiryMode:a})})})};var N8=Z(en),_p=Sa(),uC=Wa(_e),j8=B({reflectSymbol:function(){return"description"}})(_e),by=B({reflectSymbol:function(){return"id"}})(on),iC=B({reflectSymbol:function(){return"name"}})(_e),O8=_p(by(iC(B({reflectSymbol:function(){return"slug"}})(_e)(rn)))),U8=Ca(O8),Mue=_s(_p(B({reflectSymbol:function(){return"advisingConfig"}})(Wa(_p(B({reflectSymbol:function(){return"canSubmitConsultInquiry"}})(Wa(Ia))(B({reflectSymbol:function(){return"clientAppetite"}})(uC)(B({reflectSymbol:function(){return"freeConsultationDurationMinutes"}})(Wa(on))(B({reflectSymbol:function(){return"inquiryMode"}})(_e)(B({reflectSymbol:function(){return"packages"}})(Ca(_p(B({reflectSymbol:function(){return"activeForSale"}})(Ia)(j8(by(iC(B({reflectSymbol:function(){return"numMinutes"}})(on)(B({reflectSymbol:function(){return"packageCategories"}})(U8)(B({reflectSymbol:function(){return"refundPeriodLengthDays"}})(on)(B({reflectSymbol:function(){return"totalPriceCents"}})(fp)(rn)))))))))))(B({reflectSymbol:function(){return"pricePerHourCents"}})(fp)(B({reflectSymbol:function(){return"singleSessionDurationMinutes"}})(on)(B({reflectSymbol:function(){return"singleSessionRefundPeriodLengthDays"}})(on)(B({reflectSymbol:function(){return"themes"}})(Ca(_p(B({reflectSymbol:function(){return"active"}})(Ia)(B({reflectSymbol:function(){return"category"}})(O8)(j8(B({reflectSymbol:function(){return"durationMinutes"}})(on)(by(B({reflectSymbol:function(){return"priceCents"}})(fp)(B({reflectSymbol:function(){return"title"}})(_e)(rn))))))))))(rn))))))))))))(B({reflectSymbol:function(){return"entity"}})(_p(B({reflectSymbol:function(){return"bio"}})(_e)(by(B({reflectSymbol:function(){return"imageUrl"}})(uC)(iC(B({reflectSymbol:function(){return"organizationId"}})(on)(B({reflectSymbol:function(){return"organizationName"}})(_e)(B({reflectSymbol:function(){return"shortEducation"}})(uC)(B({reflectSymbol:function(){return"tags"}})(U8)(rn))))))))))(rn)))),lC=W(aa),cC=k(ae),r_=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Rs=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Aue=function(e){return N8(Mue("ServiceProviderPresenter")(e))(function(n){return N8(bn(lC(M.value))(function(){var a=cC(lC);return function(t){return a(x8(t))}}())(fe(n.advisingConfig)))(function(a){return lC({entity:n.entity,advisingConfig:a})})})},k8=Na(Ye)(ae)({parse:function(e){return e.type==="Sem::User"?cC(r_.create)(t4(e.presenter)):e.type==="ServiceProviders::Individual"?cC(Rs.create)(Aue(e.presenter)):M.value},diagnosticName:"Livestream Guest Presenter"});var B8=xn(Pn),H8=Ln(B8)(Fn(Cn)),q8=Mn(Gn),J8=An(q8),W8=On(jn),$8=Nn(W8),ys=function(){function e(){}return e.value=new e,e}(),gc=function(){function e(){}return e.value=new e,e}(),ws=function(){function e(){}return e.value=new e,e}(),Lue={to:function(e){if(e instanceof ge)return ys.value;if(e instanceof ie&&e.value0 instanceof ge)return gc.value;if(e instanceof ie&&e.value0 instanceof ie)return ws.value;throw new Error("Failed pattern match at Livestream.Types.Poll (line 41, column 1 - line 41, column 37): "+[e.constructor.name])},from:function(e){if(e instanceof ys)return new ge(xe.value);if(e instanceof gc)return new ie(new ge(xe.value));if(e instanceof ws)return new ie(new ie(xe.value));throw new Error("Failed pattern match at Livestream.Types.Poll (line 41, column 1 - line 41, column 37): "+[e.constructor.name])}},z8={eq:function(e){return function(n){return e instanceof ys&&n instanceof ys||e instanceof gc&&n instanceof gc||e instanceof ws&&n instanceof ws}}},Ey=function(e){if(e instanceof ys)return"ready";if(e instanceof gc)return"live";if(e instanceof ws)return"closed";throw new Error("Failed pattern match at Livestream.Types.Poll (line 64, column 23 - line 67, column 21): "+[e.constructor.name])};var Qm=function(){return ta(Ye)({parse:In(Ey)(Un(Lue)(H8(H8(B8)(q8))(J8))($8($8(W8)))(J8)),default:ys.value,diagnosticName:"livestream poll status"})}(),sC=function(e){return{id:e.id,question:e.question,multiSelect:e.multiSelect,options:e.options,autoDisplayMinutesFromStart:fe(e.autoDisplayMinutesFromStart)}};var V8=function(e){return{fullName:e.fullName,firstName:e.firstName,totalStreams:e.totalStreams,undergrad:{college:fe(e.undergrad.college),major:fe(e.undergrad.major),year:fe(e.undergrad.year)},gradCollege:fe(e.gradCollege),workExperience:fe(e.workExperience),admissionsStory:fe(e.admissionsStory),pictureUrl:fe(e.pictureUrl),allStreamsUrl:fe(e.allStreamsUrl)}};var Pue=Qe(na),xue=Ou(),Q8=pe(ae),K8=xn(Pn),Y8=Ln(K8)(Fn(Cn)),X8=Mn(Gn),Z8=An(X8),e7=On(jn),n7=Nn(e7),a7=ta(Ye),t7=df(),r7=Ja(en),Nue=pe(ze),jue=k(ae),Oue=Z(en),Du=function(){function e(){}return e.value=new e,e}(),qr=function(){function e(){}return e.value=new e,e}(),Er=function(){function e(){}return e.value=new e,e}();var Zu=Ze,Uue=ne(Zu);var kue={to:function(e){if(e instanceof ge)return Du.value;if(e instanceof ie&&e.value0 instanceof ge)return qr.value;if(e instanceof ie&&e.value0 instanceof ie)return Er.value;throw new Error("Failed pattern match at Livestream.Types.Conference (line 175, column 1 - line 175, column 39): "+[e.constructor.name])},from:function(e){if(e instanceof Du)return new ge(xe.value);if(e instanceof qr)return new ie(new ge(xe.value));if(e instanceof Er)return new ie(new ie(xe.value));throw new Error("Failed pattern match at Livestream.Types.Conference (line 175, column 1 - line 175, column 39): "+[e.constructor.name])}},Cv={eq:function(e){return function(n){return e instanceof Du&&n instanceof Du||e instanceof qr&&n instanceof qr||e instanceof Er&&n instanceof Er}}},Km={eq:function(e){return function(n){return e===n}}},o7={compare:function(e){return function(n){return Pue(e)(n)}},Eq0:function(){return Km}};var Fv=function(e){return xue({livestream_conference_id:Uue(e.id),livestream_conference_presenter_name:ke("")(Q8(e.presenter)(function(n){return n.fullName})),livestream_conference_uid:e.uid,livestream_conference_title:e.title,livestream_conference_partner_type:ke("")(e.partnerType)})},u7=function(){var e=function(n){if(n instanceof Du)return"waiting_room";if(n instanceof qr)return"on_air";if(n instanceof Er)return"complete";throw new Error("Failed pattern match at Livestream.Types.Conference (line 188, column 17 - line 191, column 35): "+[n.constructor.name])};return In(e)(Un(kue)(Y8(Y8(K8)(X8))(Z8))(n7(n7(e7)))(Z8))}(),i7=function(){return a7({parse:u7,default:Du.value,diagnosticName:"livestream status"})}(),Bue=a7({parse:hu,default:tt(k0),diagnosticName:"livestream scheduled start time"}),Ym=function(e){return{uid:e.uid,title:e.title,description:e.description,url:e.url,imageUrl:e.imageUrl,duration:e.duration,tailTime:e.tailTime,stats:e.stats,isPrivate:e.isPrivate,legacyRecording:e.legacyRecording,collegeFair:e.collegeFair,id:e.id,school:Q8(fe(e.school))(function(n){return{cityState:n.cityState,name:n.name,id:t7(n.id),slug:t7(n.slug)}}),scheduledStartTime:Bue(e.scheduledStartTime),onAirTime:r7(hu)(fe(e.onAirTime)),streamStatus:i7(e.streamStatus),watchUrl:fe(e.watchUrl),streamingStartTime:r7(hu)(fe(e.streamingStartTime)),polls:Nue(e.polls)(function(n){return{poll:sC(n.poll),status:Qm(n.status)}}),presenter:jue(V8)(fe(e.presenter)),partnerType:fe(e.partnerType),guestPresenter:Oue(fe(e.guestPresenter))(k8),zoomJoinUrl:fe(e.zoomJoinUrl),zoomStartUrl:fe(e.zoomStartUrl)}};var l7=xn(Pn),c7=Mn(Gn),s7=On(jn),bi=function(){function e(){}return e.value=new e,e}(),pp=function(){function e(){}return e.value=new e,e}(),Hue={to:function(e){if(e instanceof ge)return bi.value;if(e instanceof ie)return pp.value;throw new Error("Failed pattern match at Profile.PublishScope (line 24, column 1 - line 24, column 39): "+[e.constructor.name])},from:function(e){if(e instanceof bi)return new ge(xe.value);if(e instanceof pp)return new ie(xe.value);throw new Error("Failed pattern match at Profile.PublishScope (line 24, column 1 - line 24, column 39): "+[e.constructor.name])}},Iy={eq:function(e){return function(n){return e instanceof bi&&n instanceof bi||e instanceof pp&&n instanceof pp}}};var Xm=function(e){if(e instanceof pp)return"anonymous-all-schools";if(e instanceof bi)return"all-schools";throw new Error("Failed pattern match at Profile.PublishScope (line 34, column 13 - line 36, column 30): "+[e.constructor.name])},Ty=function(){return ta(Ye)({parse:In(Xm)(Un(Hue)(Ln(l7)(Fn(Cn))(l7)(c7))(Nn(s7)(s7))(An(c7))),diagnosticName:"Profile.PublishScope",default:pp.value})}();var sl=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),vl=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),fl=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),_l=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var vC=function(e){return{id:e.id,title:e.title,requireAnonymousUserFirstName:e.requireAnonymousUserFirstName,requireAnonymousUserLastName:e.requireAnonymousUserLastName,requireAnonymousUserEmail:e.requireAnonymousUserEmail,requireReferredUserFirstName:e.requireReferredUserFirstName,requireReferredUserLastName:e.requireReferredUserLastName,description:fe(e.description)}},o_=function(e){return{author:e.author,text:e.text,isFromHQ:e.isFromHQ,isPublic:e.isPublic,id:e.id,time:hu(e.time)}},v7=function(e){return{autoRequestFromLivestreams:e.autoRequestFromLivestreams,fullName:fe(e.fullName),publishScope:Ty(e.publishScope)}},fC=function(e){return{id:e.id,title:e.title,url:e.url,buttonText:e.buttonText,autoDisplayMinutesFromStart:fe(e.autoDisplayMinutesFromStart)}},Ei="overlay-visibility-test";var f7=xn(Pn),Sy=Ln(f7)(Fn(Cn)),_7=Mn(Gn),Cy=An(_7),p7=On(jn),Fy=Nn(p7),bs=function(){function e(){}return e.value=new e,e}(),Gv=function(){function e(){}return e.value=new e,e}(),u_=function(){function e(){}return e.value=new e,e}(),Mv=function(){function e(){}return e.value=new e,e}(),Av=function(){function e(){}return e.value=new e,e}(),que={to:function(e){if(e instanceof ge)return bs.value;if(e instanceof ie&&e.value0 instanceof ge)return Gv.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ge)return u_.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ie&&e.value0.value0.value0 instanceof ge)return Mv.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ie&&e.value0.value0.value0 instanceof ie)return Av.value;throw new Error("Failed pattern match at Livestream.Types.Reaction (line 20, column 1 - line 20, column 39): "+[e.constructor.name])},from:function(e){if(e instanceof bs)return new ge(xe.value);if(e instanceof Gv)return new ie(new ge(xe.value));if(e instanceof u_)return new ie(new ie(new ge(xe.value)));if(e instanceof Mv)return new ie(new ie(new ie(new ge(xe.value))));if(e instanceof Av)return new ie(new ie(new ie(new ie(xe.value))));throw new Error("Failed pattern match at Livestream.Types.Reaction (line 20, column 1 - line 20, column 39): "+[e.constructor.name])}},d7=function(e){if(e instanceof bs)return"love-this";if(e instanceof Gv)return"helpful";if(e instanceof u_)return"not-helpful";if(e instanceof Mv)return"writing-down";if(e instanceof Av)return"funny";throw new Error("Failed pattern match at Livestream.Types.Reaction (line 51, column 17 - line 56, column 19): "+[e.constructor.name])},m7=function(e){return{authorTag:e.authorTag,kind:d7(e.kind)}},Jue=function(){return ta(Ye)({parse:In(d7)(Un(que)(Sy(Sy(Sy(Sy(f7)(_7))(Cy))(Cy))(Cy))(Fy(Fy(Fy(Fy(p7)))))(Cy)),default:bs.value,diagnosticName:"Livestream Reaction Kind"})}(),h7=function(e){return{authorTag:e.authorTag,kind:Jue(e.kind)}};var D7=typeof CV!="undefined"&&CV.pathInfo||typeof global!="undefined"&&global.CV&&global.CV.pathInfo||(e=>null);function g7(e,n){let a=typeof CV!="undefined"&&CV.apiEndpoint||typeof global!="undefined"&&global.CV&&global.CV.apiEndpoint;return a||console.error("Missing `CV.apiEndpoint` function"),a&&a(e,n)}function R7(e,n,a,t,o){return function(u,i){var l=e.newXHR(),s=e.fixupUrl(o.url,l);if(l.open(o.method||"GET",s,!0,o.username,o.password),o.headers)try{for(var R=0,d;(d=o.headers[R])!=null;R++)l.setRequestHeader(d.field,d.value)}catch(I){u(I)}var y=function(I){return function(){u(new Error(I))}};return l.onerror=y(a),l.ontimeout=y(n),l.onload=function(){i({status:l.status,statusText:l.statusText,headers:l.getAllResponseHeaders().split(`\r `).filter(function(I){return I.length>0}).map(function(I){var b=I.indexOf(":");return t(I.substring(0,b))(I.substring(b+2))}),body:l.response})},l.responseType=o.responseType,l.withCredentials=o.withCredentials,l.timeout=o.timeout,l.send(o.content),function(I,b,S){try{l.abort()}catch(L){return b(L)}return S()}}}var Gy="application/json",y7="application/x-www-form-urlencoded";var w7=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),b7=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),E7=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),I7=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),T7=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),_C=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),My=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),S7=function(e){return e instanceof _C?new T(y7):e instanceof My?new T(Gy):M.value};var C7=function(){return My.create}();var F7=ba();var Ay=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Ly=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),dp=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),G7=function(e){if(e instanceof Ay||e instanceof Ly)return F7(e.value0);if(e instanceof dp)return e.value1;throw new Error("Failed pattern match at Affjax.RequestHeader (line 26, column 1 - line 26, column 33): "+[e.constructor.name])};var pC=function(e){if(e instanceof Ay)return"Accept";if(e instanceof Ly)return"Content-Type";if(e instanceof dp)return e.value0;throw new Error("Failed pattern match at Affjax.RequestHeader (line 21, column 1 - line 21, column 32): "+[e.constructor.name])};var M7=pn(dn),dC=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),mC=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),hC=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Py=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),xy=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Ny=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),A7=function(e){if(e instanceof dC)return"arraybuffer";if(e instanceof mC)return"blob";if(e instanceof hC)return"document";if(e instanceof Py||e instanceof xy)return"text";if(e instanceof Ny)return"";throw new Error("Failed pattern match at Affjax.ResponseFormat (line 44, column 3 - line 50, column 19): "+[e.constructor.name])},L7=function(e){return e instanceof Py?new T(Gy):M.value},P7=function(){return new xy(M7)}();var x7=function(){return new Ny(M7)}();var N7=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}();var $ue=ba();var Zm=function(e){return $ue(Xg(e))};function j7(e,n,a){try{return n(JSON.parse(a))}catch(t){return e(t.message)}}var jy=function(e){return j7(Me.create,Le.create,e)};function O7(e){return e.replace(/[!'()*]/g,function(n){return"%"+n.charCodeAt(0).toString(16)})}function U7(e,n,a){try{return n(O7(encodeURIComponent(a)))}catch(t){return e(t)}}function k7(e,n,a){try{return n(O7(encodeURIComponent(a)).replace(/%20/g,"+"))}catch(t){return e(t)}}var Oy=function(){return av(U7)(hn(M.value))(T.create)}();var Uy=function(){return av(k7)(hn(M.value))(T.create)}();var zue=Yn(hr),B7=k(ae),Vue=lo(xu)(aa);var Que=function(e){return e};var H7=function(){var e=function(t){if(t.value1 instanceof M)return Uy(t.value0);if(t.value1 instanceof T)return zue(B7(function(o){return function(u){return o+("="+u)}})(Uy(t.value0)))(Uy(t.value1.value0));throw new Error("Failed pattern match at Data.FormURLEncoded (line 37, column 16 - line 39, column 114): "+[t.constructor.name])},n=B7(vr("&")),a=Vue(e);return function(t){return n(a(Que(t)))}}();var DC=function(){function e(){}return e.value=new e,e}(),i_=function(){function e(){}return e.value=new e,e}(),gC=function(){function e(){}return e.value=new e,e}(),l_=function(){function e(){}return e.value=new e,e}(),ky=function(){function e(){}return e.value=new e,e}(),eh=function(){function e(){}return e.value=new e,e}(),RC=function(){function e(){}return e.value=new e,e}(),yC=function(){function e(){}return e.value=new e,e}(),wC=function(){function e(){}return e.value=new e,e}(),bC=function(){function e(){}return e.value=new e,e}(),EC=function(){function e(){}return e.value=new e,e}(),IC=function(){function e(){}return e.value=new e,e}(),TC=function(){function e(){}return e.value=new e,e}(),SC=function(){function e(){}return e.value=new e,e}(),CC=function(){function e(){}return e.value=new e,e}(),By=function(){function e(){}return e.value=new e,e}();var Kue=function(e){return e},Yue={show:function(e){if(e instanceof DC)return"OPTIONS";if(e instanceof i_)return"GET";if(e instanceof gC)return"HEAD";if(e instanceof l_)return"POST";if(e instanceof ky)return"PUT";if(e instanceof eh)return"DELETE";if(e instanceof RC)return"TRACE";if(e instanceof yC)return"CONNECT";if(e instanceof wC)return"PROPFIND";if(e instanceof bC)return"PROPPATCH";if(e instanceof EC)return"MKCOL";if(e instanceof IC)return"COPY";if(e instanceof TC)return"MOVE";if(e instanceof SC)return"LOCK";if(e instanceof CC)return"UNLOCK";if(e instanceof By)return"PATCH";throw new Error("Failed pattern match at Data.HTTP.Method (line 43, column 1 - line 59, column 23): "+[e.constructor.name])}};var q7=Ut(ne(Yue))(Kue);var J7={eq:function(e){return function(n){return e instanceof DC&&n instanceof DC||e instanceof i_&&n instanceof i_||e instanceof gC&&n instanceof gC||e instanceof l_&&n instanceof l_||e instanceof ky&&n instanceof ky||e instanceof eh&&n instanceof eh||e instanceof RC&&n instanceof RC||e instanceof yC&&n instanceof yC||e instanceof wC&&n instanceof wC||e instanceof bC&&n instanceof bC||e instanceof EC&&n instanceof EC||e instanceof IC&&n instanceof IC||e instanceof TC&&n instanceof TC||e instanceof SC&&n instanceof SC||e instanceof CC&&n instanceof CC||e instanceof By&&n instanceof By}}};var W7=function(e){return fv(function(n){return function(){var t=e(function(o){return n(Me.create(o))()},function(o){return n(Le.create(o))()});return function(o){return fv(function(u){return function(){return t(o,function(l){return u(Me.create(l))()},function(l){return u(Le.create(l))()}),RT}})}}})};var FC=W(Qc(cr)),Xue=A0(cr),c_=Xc(cr),$7=ma(nR(iR)(cr)),Zue=tf(Ff(cr)),Hy=k(ae),eie=ci(fn)(st),nie=we(Pt),aie=Ja(en),tie=k(ze),rie=pe(Ga),oie=Sf(Nr),uie=W(ca);var qy=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Jy=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),Wy=function(){function e(){}return e.value=new e,e}(),$y=function(){function e(){}return e.value=new e,e}(),zy=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),z7=function(e){return function(n){var a=function(d){return d===""?FC(lj):Ut(function(y){return Xue(um.create(y))})(FC)(jy(d))},t=function(){if(n.responseFormat instanceof dC)return c_("ArrayBuffer");if(n.responseFormat instanceof mC)return c_("Blob");if(n.responseFormat instanceof hC)return function(d){return $7(c_("Document")(d))($7(c_("XMLDocument")(d))(c_("HTMLDocument")(d)))};if(n.responseFormat instanceof Py)return Zue(function(d){return n.responseFormat.value0(a(d))})(c_("String"));if(n.responseFormat instanceof xy)return c_("String");if(n.responseFormat instanceof Ny)return hn(n.responseFormat.value0(FC(Ee)));throw new Error("Failed pattern match at Affjax (line 274, column 18 - line 283, column 57): "+[n.responseFormat.constructor.name])}(),o=function(d){if(d instanceof w7)return new Le(d.value0(so));if(d instanceof b7)return new Le(so(d.value0));if(d instanceof E7)return new Le(so(d.value0));if(d instanceof I7)return new Le(so(d.value0));if(d instanceof T7)return new Le(so(d.value0));if(d instanceof _C)return s0("Body contains values that cannot be encoded as application/x-www-form-urlencoded")(Hy(so)(H7(d.value0)));if(d instanceof My)return new Le(so(ZR(d.value0)));throw new Error("Failed pattern match at Affjax (line 235, column 20 - line 250, column 69): "+[d.constructor.name])},u=function(d){return function(y){return d instanceof T&&!eie(a0(nie)(pC)(d.value0))(y)?w0(y)(d.value0):y}},i=function(d){return u(Hy(Ly.create)(aie(S7)(d)))(u(Hy(Ay.create)(L7(n.responseFormat)))(n.headers))},l=function(d){return{method:q7(n.method),url:n.url,headers:tie(function(y){return{field:pC(y),value:G7(y)}})(i(n.content)),content:d,responseType:A7(n.responseFormat),username:Fa(n.username),password:Fa(n.password),withCredentials:n.withCredentials,timeout:ke(0)(Hy(function(y){return y})(n.timeout))}},s=function(d){return rie(oie(W7(R7(e,"AffjaxTimeoutErrorMessageIdent","AffjaxRequestFailedMessageIdent",N7.create,l(d)))))(function(y){if(y instanceof Le){var I=Zm(t(y.value0.body));if(I instanceof Me)return new Me(new Jy(rP(I.value0),y.value0));if(I instanceof Le)return new Le({headers:y.value0.headers,status:y.value0.status,statusText:y.value0.statusText,body:I.value0});throw new Error("Failed pattern match at Affjax (line 209, column 9 - line 211, column 52): "+[I.constructor.name])}if(y instanceof Me)return new Me(function(){var b=S0(y.value0),S=b==="AffjaxTimeoutErrorMessageIdent";if(S)return Wy.value;var L=b==="AffjaxRequestFailedMessageIdent";return L?$y.value:new zy(y.value0)}());throw new Error("Failed pattern match at Affjax (line 207, column 144 - line 219, column 28): "+[y.constructor.name])})};if(n.content instanceof M)return s(Fa(M.value));if(n.content instanceof T){var R=o(n.content.value0);if(R instanceof Le)return s(Fa(new T(R.value0)));if(R instanceof Me)return uie(new Me(new qy(R.value0)));throw new Error("Failed pattern match at Affjax (line 199, column 7 - line 203, column 48): "+[R.constructor.name])}throw new Error("Failed pattern match at Affjax (line 195, column 3 - line 203, column 48): "+[n.content.constructor.name])}};var mp=function(){return{method:new Me(i_.value),url:"/",headers:[],content:M.value,username:M.value,password:M.value,withCredentials:!1,responseFormat:x7,timeout:M.value}}();var V7={eq:function(e){return function(n){return e===n}}};var GC={newXHR:function(){return new XMLHttpRequest},fixupUrl:function(e){return e||"/"}};var Q7=z7(GC);function K7(e){return Buffer.from(e).toString("base64")}function Y7(e,n,a){let t;try{t=n(btoa(a))}catch(o){t=e(o)}return t}var MC=typeof btoa=="function";function X7(e){let n=32768,a=[];for(let t=0;t{let e=null,n=0,a=()=>{if(!bc||!bc.key)return bc||console.error("Pusher config is missing in global context"),new Cie;let t={auth:{headers:{"X-CSRF-Token":bc.authToken}},authEndpoint:bc.authPath,cluster:bc.cluster};return bc.dev&&Object.assign(t,{wsHost:bc.dev.wsHost,wsPort:bc.dev.wsPort,enabledTransports:["ws"],forceTLS:!1,disableStats:!0}),new pO.default(bc.key,t)};return{acquireConnection:()=>(e||(e=a(),n=0),n++,e),releaseConnection:()=>{--n<=0&&(e.disconnect(),e=null)}}})(),dO=e=>{let n=Tie().subscribe(e.channel);return n.bind(e.event,e.handler),()=>{n.unbind(e.event,e.handler),Sie()}};function Cie(){typeof document!="undefined"&&(document.mockPusher=this),this.localObject={},this.channels=[],this.disconnect=function(){document.mockPusher=null},this.subscribe=function(e){let n=this.channels.find(t=>t.name===e);if(n)return n;let a=new Fie(e);return this.channels.push(a),a},this.channelNames=function(){return this.channels.map(e=>e.name)}}function Fie(e){this.name=e,this.handlers={},this.triggered=[],this.disconnect=()=>{},this.bind=function(n,a){this.handlers[n]=a},this.unbind=function(n,a){this.handlers[n]===a&&(this.handlers[n]=null)},this.trigger=function(n,a){this.triggered.push({eventName:n,eventData:a})}}var Gie=vi(yt),Mie=ko(rt)(Pu),Aie=pe(oj);var Lie={show:function(e){return e}},Pie=ne(Lie),Ky=_e,xie=function(e){var n=_s(e);return function(a){return function(t){return function(o){var u=Gie(["Pusher event ",t," over channel ",Pie(a)]),i=function(l){return Mie(n(u)(l))(o)()};return function(){return dO({channel:a,event:t,handler:i})}}}}},Ii=function(e){var n=xie(e);return function(a){var t=a.Monad0(),o=Z(t.Bind1()),u=Bn(a),i=W(t.Applicative0());return function(l){return function(s){return function(R){return o(u(n(l)(s)(R)))(function(d){return i(u(d))})}}}}},Nie=Ii(Lf),Yy=function(e){var n=Nie(e);return function(a){return function(t){return Aie(n(a)(t))(hn(Ee))}}};var mO=wc(Rc),gu=ql(mO),Ir=Z(_a),ah=ql(wc(mO)),hO=W(ca),jie=pe(ae),th=Sa(),DO=B({reflectSymbol:function(){return"pollId"}})(on),Oie=B({reflectSymbol:function(){return"status"}})(_e)(rn),Uie=wt(Ca(th(DO(Oie)))),gO=k(ze),RO=k(Ga),kie=B({reflectSymbol:function(){return"id"}}),Bie=kie(on),yO=th(B({reflectSymbol:function(){return"author"}})(th(B({reflectSymbol:function(){return"cvid"}})(_e)(B({reflectSymbol:function(){return"username"}})(_e)(rn))))(Bie(B({reflectSymbol:function(){return"isFromHQ"}})(Ia)(B({reflectSymbol:function(){return"isPublic"}})(Ia)(B({reflectSymbol:function(){return"text"}})(_e)(B({reflectSymbol:function(){return"time"}})(_e)(rn))))))),Hie=Dp(yO);var qie=Wa(_e);var Jie=Dp(Ca(th(DO(B({reflectSymbol:function(){return"responses"}})(th(B({reflectSymbol:function(){return"answered"}})(on)(B({reflectSymbol:function(){return"optionCounts"}})(Ca(on))(B({reflectSymbol:function(){return"seen"}})(on)(B({reflectSymbol:function(){return"skipped"}})(on)(rn))))))(rn))))),Wie=Dp(qie),$ie=Dp(Ca(yO));var PC=ah("livestreams_polls_status_path")(function(e){return function(n){return function(a){return Ir(e({id:n.id,status:Ey(a)}))(yc(function(t){return hO(ke([])(jie(Uie(t))(gO(function(o){return{pollId:o.pollId,status:Qm(o.status)}}))))}))}}});var xC=ah("livestreams_polls_answer_path")(function(e){return function(n){return function(a){return Ir(e({id:n.id,options:a}))(Xt)}}}),wO=gu("livestreams_conferences_status_on_air_path")(function(e){return function(n){return Ir(e({conference_id:n}))(Xt)}}),bO=gu("livestreams_conferences_status_complete_path")(function(e){return function(n){return Ir(e({conference_id:n}))(Xt)}}),EO=gu("livestreams_cta_save_referral_path")(function(e){return function(n){return Ir(e(n))(Xt)}}),IO=gu("livestreams_polls_report_shown_path")(function(e){return function(n){return Ir(e({id:n.id}))(Xt)}}),TO=ah("livestreams_client_window_visibility_path")(function(e){return function(n){return function(a){return Ir(e({stream_id:n,visible:a.visible}))(Xt)}}}),SO=ah("livestreams_recording_watch_event_path")(function(e){return function(n){return function(a){return Ir(e({conference_id:n,current_time_minutes:a}))(Xt)}}}),CO=gu("livestreams_questions_visibility_path")(function(e){return function(n){return Ir(e({question_id:n.questionId,is_public:n.isPublic}))(Xt)}}),FO=gu("livestreams_questions_post_path")(function(e){return function(n){return Ir(e({conference_id:n.conferenceId,question_text:n.text,hq_broadcast:n.hqBroadcast}))(yc(function(a){return RO(o_)(Hie("Livestream question")(a))}))}}),GO=gu("livestreams_cta_open_path")(function(e){return function(n){return Ir(e({is_referral:!0,from_conference_id:n.fromConference,id:n.ctaId}))(Xt)}}),MO=gu("livestreams_cta_open_path")(function(e){return function(n){return Ir(e({is_general:!0,from_conference_id:n.fromConference,id:n.ctaId}))(Xt)}}),AO=gu("livestreams_cta_open_path")(function(e){return function(n){return Ir(e({is_featured_service_providers:!0,from_conference_id:n.fromConference,id:n.ctaId}))(Xt)}}),LO=gu("livestreams_cta_open_path")(function(e){return function(n){return Ir(e({is_event:!0,from_conference_id:n.fromConference,cta_conference_id:n.cta}))(Xt)}}),Xy=gu("livestreams_register_path")(function(e){return function(n){return Ir(e({from_conference_id:Fa(n.fromConference),register_for_conference_id:n.registerForConference,utm_cv_source:n.utmSource}))(Xt)}});var PO=ah("livestreams_reactions_launch_path")(function(e){return function(n){return function(a){return Ir(e({conference_id:n,reaction:m7(a)}))(Xt)}}}),xO=gu("livestreams_polls_responses_path")(function(e){return function(n){return Ir(e({conference_id:n}))(yc(Jie("livestream poll responses")))}}),NO=gu("livestreams_conferences_download_url_path")(function(e){return function(n){return Ir(e({conference_id:n}))(yc(function(a){return RO(fe)(Wie("Livestream download URL")(a))}))}}),Zy=ql(Rc)("livestreams_dismiss_network_settings_modal_path")(function(e){return Ir(e({}))(Xt)});var jO=gu("livestreams_conferences_ban_user_path")(function(e){return function(n){return Ir(e({conference_id:n.conferenceId,user_cvid:n.userCvid}))(Xt)}}),ew=gu("livestreams_questions_all_path")(function(e){return function(n){return Ir(e({conference_id:n}))(yc(function(a){return Ir($ie("Livestream questions")(a))(function(t){return hO(gO(o_)(t))})}))}});var jC=function(){function e(){}return e.value=new e,e}(),OC=function(){function e(){}return e.value=new e,e}(),UC=function(){function e(){}return e.value=new e,e}(),kC=function(){function e(){}return e.value=new e,e}(),BC=function(){function e(){}return e.value=new e,e}(),HC=function(){function e(){}return e.value=new e,e}(),qC=function(){function e(){}return e.value=new e,e}(),JC=function(){function e(){}return e.value=new e,e}(),WC=function(){function e(){}return e.value=new e,e}(),$C=function(){function e(){}return e.value=new e,e}(),zC=function(){function e(){}return e.value=new e,e}(),VC=function(){function e(){}return e.value=new e,e}(),QC=function(){function e(){}return e.value=new e,e}(),KC=function(){function e(){}return e.value=new e,e}(),Nt=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),YC=function(){function e(){}return e.value=new e,e}();var aw=function(e){if(e instanceof Nt&&e.value0 instanceof jC)return"architecture";if(e instanceof Nt&&e.value0 instanceof UC)return"chemistry";if(e instanceof Nt&&e.value0 instanceof OC)return"business";if(e instanceof Nt&&e.value0 instanceof kC)return"computer-science";if(e instanceof Nt&&e.value0 instanceof BC)return"criminal-justice-and-corrections";if(e instanceof Nt&&e.value0 instanceof HC)return"economics";if(e instanceof Nt&&e.value0 instanceof qC)return"engineering";if(e instanceof Nt&&e.value0 instanceof JC)return"english";if(e instanceof Nt&&e.value0 instanceof WC)return"film";if(e instanceof Nt&&e.value0 instanceof $C)return"finance";if(e instanceof Nt&&e.value0 instanceof zC)return"history";if(e instanceof Nt&&e.value0 instanceof VC)return"political-science";if(e instanceof Nt&&e.value0 instanceof QC)return"pre-med";if(e instanceof Nt&&e.value0 instanceof KC)return"psychology";if(e instanceof YC)return"overall";throw new Error("Failed pattern match at Hub.Ranking (line 98, column 8 - line 113, column 23): "+[e.constructor.name])};var tw=function(){function e(){}return e.value=new e,e}(),Yie=function(){function e(){}return e.value=new e,e}(),Xie=function(){function e(){}return e.value=new e,e}();var OO=function(e){if(e instanceof tw)return M.value;if(e instanceof Xie)return new T("open");if(e instanceof Yie)return new T("on");throw new Error("Failed pattern match at Hub.Types.WhatificatorPhase (line 26, column 13 - line 29, column 22): "+[e.constructor.name])};var HO=St();var v_=function(e){return function(n){var a=function(){var u=Yc("?")(n);return u?"&":"?"}(),t=HO(Oy(e.value)),o=HO(Oy(e.key));return n+(a+(o+("="+t)))}};var yle=function(){function e(){}return e.value=new e,e}(),wle=function(){function e(){}return e.value=new e,e}(),ble=function(){function e(){}return e.value=new e,e}(),Ele=function(){function e(){}return e.value=new e,e}(),Ile=function(){function e(){}return e.value=new e,e}(),Tle=function(){function e(){}return e.value=new e,e}(),Sle=function(){function e(){}return e.value=new e,e}(),Cle=function(){function e(){}return e.value=new e,e}(),Fle=function(){function e(){}return e.value=new e,e}(),Gle=function(){function e(){}return e.value=new e,e}(),Mle=function(){function e(){}return e.value=new e,e}(),Ale=function(){function e(){}return e.value=new e,e}(),Lle=function(){function e(){}return e.value=new e,e}(),Ple=function(){function e(){}return e.value=new e,e}(),xle=function(){function e(){}return e.value=new e,e}(),Nle=function(){function e(){}return e.value=new e,e}(),jle=function(){function e(){}return e.value=new e,e}(),Ole=function(){function e(){}return e.value=new e,e}(),Ule=function(){function e(){}return e.value=new e,e}(),kle=function(){function e(){}return e.value=new e,e}(),Ble=function(){function e(){}return e.value=new e,e}(),Hle=function(){function e(){}return e.value=new e,e}(),qle=function(){function e(){}return e.value=new e,e}(),Jle=function(){function e(){}return e.value=new e,e}(),Wle=function(){function e(){}return e.value=new e,e}(),$le=function(){function e(){}return e.value=new e,e}(),zle=function(){function e(){}return e.value=new e,e}(),Vle=function(){function e(){}return e.value=new e,e}(),Qle=function(){function e(){}return e.value=new e,e}(),Kle=function(){function e(){}return e.value=new e,e}(),Yle=function(){function e(){}return e.value=new e,e}(),Xle=function(){function e(){}return e.value=new e,e}(),Zle=function(){function e(){}return e.value=new e,e}(),ece=function(){function e(){}return e.value=new e,e}(),nce=function(){function e(){}return e.value=new e,e}(),ace=function(){function e(){}return e.value=new e,e}(),tce=function(){function e(){}return e.value=new e,e}(),rce=function(){function e(){}return e.value=new e,e}(),oce=function(){function e(){}return e.value=new e,e}(),uce=function(){function e(){}return e.value=new e,e}(),ice=function(){function e(){}return e.value=new e,e}(),lce=function(){function e(){}return e.value=new e,e}(),cce=function(){function e(){}return e.value=new e,e}(),sce=function(){function e(){}return e.value=new e,e}(),vce=function(){function e(){}return e.value=new e,e}(),fce=function(){function e(){}return e.value=new e,e}(),_ce=function(){function e(){}return e.value=new e,e}(),pce=function(){function e(){}return e.value=new e,e}(),dce=function(){function e(){}return e.value=new e,e}(),mce=function(){function e(){}return e.value=new e,e}(),hce=function(){function e(){}return e.value=new e,e}(),Dce=function(){function e(){}return e.value=new e,e}(),gce=function(){function e(){}return e.value=new e,e}(),Rce=function(){function e(){}return e.value=new e,e}(),yce=function(){function e(){}return e.value=new e,e}(),wce=function(){function e(){}return e.value=new e,e}();var sa=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Ru=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var qO=function(e){if(e instanceof sa&&e.value0 instanceof yle)return"AcceptanceRate";if(e instanceof sa&&e.value0 instanceof wle)return"AcceptanceRateMen";if(e instanceof sa&&e.value0 instanceof ble)return"AcceptanceRateWomen";if(e instanceof sa&&e.value0 instanceof Ele)return"Address";if(e instanceof sa&&e.value0 instanceof Ile)return"AdmissionChances";if(e instanceof sa&&e.value0 instanceof Tle)return"AdmissionDifficulty";if(e instanceof sa&&e.value0 instanceof Sle)return"AdmissionsNotificationDate";if(e instanceof sa&&e.value0 instanceof Cle)return"AdmissionsWebsite";if(e instanceof sa&&e.value0 instanceof Fle)return"AppDeadlineIsRolling";if(e instanceof sa&&e.value0 instanceof Gle)return"ApplicationEffort";if(e instanceof sa&&e.value0 instanceof Mle)return"ApplicationRound";if(e instanceof sa&&e.value0 instanceof Ale)return"BasketballConference";if(e instanceof sa&&e.value0 instanceof Lle)return"CampusSetting";if(e instanceof sa&&e.value0 instanceof Ple)return"City";if(e instanceof sa&&e.value0 instanceof xle)return"ClassRank";if(e instanceof sa&&e.value0 instanceof Nle)return"CoEdSingleSex";if(e instanceof sa&&e.value0 instanceof jle)return"CollegeType";if(e instanceof sa&&e.value0 instanceof Ole)return"CommuterCollege";if(e instanceof sa&&e.value0 instanceof Ule)return"Diversity";if(e instanceof sa&&e.value0 instanceof kle)return"DropoutRate";if(e instanceof sa&&e.value0 instanceof Hle)return"FinancialAidWebsite";if(e instanceof sa&&e.value0 instanceof qle)return"FirstYearEnrollment";if(e instanceof sa&&e.value0 instanceof Jle)return"FootballConference";if(e instanceof sa&&e.value0 instanceof Wle)return"FourYearGraduationRate";if(e instanceof sa&&e.value0 instanceof $le)return"HasDivisionOneBasketball";if(e instanceof sa&&e.value0 instanceof zle)return"HasDivisionOneFootball";if(e instanceof sa&&e.value0 instanceof Vle)return"HasMedicalSchool";if(e instanceof sa&&e.value0 instanceof Qle)return"HasStudyAbroad";if(e instanceof sa&&e.value0 instanceof Kle)return"HBCU";if(e instanceof sa&&e.value0 instanceof Yle)return"InListStatus";if(e instanceof sa&&e.value0 instanceof Xle)return"MainWebsite";if(e instanceof sa&&e.value0 instanceof Ble)return"Majors";if(e instanceof sa&&e.value0 instanceof Zle)return"Name";if(e instanceof sa&&e.value0 instanceof ece)return"NetCostEstimate";if(e instanceof sa&&e.value0 instanceof nce)return"Notes";if(e instanceof sa&&e.value0 instanceof ace)return"PercentInternationalStudents";if(e instanceof sa&&e.value0 instanceof tce)return"Phone";if(e instanceof sa&&e.value0 instanceof rce)return"Photo";if(e instanceof sa&&e.value0 instanceof oce)return"Prestige";if(e instanceof sa&&e.value0 instanceof uce)return"ProgramLength";if(e instanceof sa&&e.value0 instanceof ice)return"PublicPrivate";if(e instanceof sa&&e.value0 instanceof lce)return"RecommendationLetters";if(e instanceof sa&&e.value0 instanceof cce)return"Region";if(e instanceof sa&&e.value0 instanceof sce)return"ReligiousAffiliation";if(e instanceof sa&&e.value0 instanceof vce)return"SatActDeadline";if(e instanceof sa&&e.value0 instanceof fce)return"SatActTestPolicy";if(e instanceof sa&&e.value0 instanceof _ce)return"SatSubjectTestDeadline";if(e instanceof sa&&e.value0 instanceof pce)return"SixYearGraduationRate";if(e instanceof sa&&e.value0 instanceof dce)return"State";if(e instanceof sa&&e.value0 instanceof mce)return"StudentFacultyRatio";if(e instanceof sa&&e.value0 instanceof hce)return"SubmissionDeadline";if(e instanceof sa&&e.value0 instanceof Dce)return"TOEFLPolicy";if(e instanceof sa&&e.value0 instanceof gce)return"TotalUndergrads";if(e instanceof sa&&e.value0 instanceof Rce)return"TuitionInState";if(e instanceof sa&&e.value0 instanceof yce)return"TuitionOutOfState";if(e instanceof sa&&e.value0 instanceof wce)return"YieldRate";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof jC)return"RankingArchitecture";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof OC)return"RankingBusiness";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof UC)return"RankingChemistry";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof kC)return"RankingComputerScience";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof BC)return"RankingCriminalJusticeAndCorrections";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof HC)return"RankingEconomics";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof qC)return"RankingEngineering";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof JC)return"RankingEnglish";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof WC)return"RankingFilm";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof $C)return"RankingFinance";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof zC)return"RankingHistory";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof VC)return"RankingPoliticalScience";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof QC)return"RankingPreMed";if(e instanceof Ru&&e.value0 instanceof Nt&&e.value0.value0 instanceof KC)return"RankingPsychology";if(e instanceof Ru&&e.value0 instanceof YC)return"OverallRanking";throw new Error("Failed pattern match at Hub.Facet (line 309, column 6 - line 380, column 43): "+[e.constructor.name])};var bce=function(){function e(){}return e.value=new e,e}(),Ece=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Ice=function(){function e(){}return e.value=new e,e}();var JO=function(e){if(e instanceof bce)return"filters";if(e instanceof Ece)return"filter:"+qO(e.value0);if(e instanceof Ice)return"rankings";throw new Error("Failed pattern match at Hub.Visuals.MobileOverlay (line 40, column 26 - line 43, column 39): "+[e.constructor.name])};function WO(e,n){typeof CV!="undefined"&&CV.tracking&&CV.tracking.event(e,n)}var Tce=Ou();var Es=function(e){var n=Bn(e);return function(a){return function(t){return n(function(){return WO(a,t)})}}},Is=function(e){var n=Es(e);return function(){return function(a){return function(t){return n(a)(Tce(t))}}}};var rh=function(){function e(){}return e.value=new e,e}(),Lv=function(){function e(){}return e.value=new e,e}(),oh=function(){function e(){}return e.value=new e,e}(),nse=function(){function e(){}return e.value=new e,e}(),VO=function(e){if(e instanceof rh)return"modal-sm";if(e instanceof Lv)return"";if(e instanceof oh)return"modal-lg";if(e instanceof nse)return"modal-xl";throw new Error("Failed pattern match at Bootstrap.Modal.Size (line 14, column 13 - line 18, column 27): "+[e.constructor.name])};$a();var ase=["selectionchange","visibilitychange","keyup","keydown"],tse=["resize","mouseup","mousemove","hashchange","popstate","message"],ZC=class extends ka.Component{constructor(){super();let n=a=>{let t={};return a.forEach(o=>{t[o]=u=>{let i=this.props[o];i&&i(u)}}),t};this.handleWindow=n(tse),this.handleDocument=n(ase)}componentDidMount(){let n=(a,t)=>Object.keys(t).forEach(o=>a.addEventListener(o,t[o]));n(window,this.handleWindow),n(document,this.handleDocument)}componentWillUnmount(){let n=(a,t)=>Object.keys(t).forEach(o=>a.removeEventListener(o,t[o]));n(window,this.handleWindow),n(document,this.handleDocument)}render(){return null}};var rse=mv(),Ts=function(){return function(){return rse(ZC)}};var ow=function(){return Je};var Rp=Te(We),eF=Vr(),ose=or(We)()(),use=or(me)()(),ise=Te(me),lse=Wn(Y)()(),cse=sr(zo),sse=lr(rt),QO=ow(),vse=Ts()(),fse=sr(gv),Jl=function(){return function(e){var n=Rp("modal-backdrop fade show")($n),a=eF(e),t=ll(a.footer),o=ll(a.header),u=Ka(a.size)(Lv.value),i=vr(" ")([function(){var s=Ka(a.scrollable)(!0);return s?"modal-dialog-scrollable":""}(),function(){var s=Ka(a.centered)(!0);return s?"modal-dialog-centered":""}(),VO(u),Ka(a.dialogClass)("")]),l=Rp("modal fade show d-block")(ose("modal-dialog "+i)({style:Ka(a.dialogStyle)(ot({}))})(use("modal-content "+Ka(a.contentClass)(""))({style:Ka(a.contentStyle)(ot({}))})([da(o)(Rp("modal-header "+Ka(a.headerClass)(""))),Rp("modal-body "+Ka(a.bodyClass)(""))(a.body),da(t)(Rp("modal-footer "+Ka(a.footerClass)("")))])));return Se([l,n])}},nF=Jl(),Wl=function(){return function(e){var n=eF(e),a=ise("d-flex w-100 justify-content-between align-items-center")([Rp("mr-4")(Ka(n.title)($n)),lse("btn btn-link large mr-n3 py-0 fe fe-x t--close "+Ka(n.dismissButtonClass)("text-body"))({type:"button",onClick:cse(n.onDismiss)})("")]),t=function(o){return sse(o.key==="Escape")(n.onDismiss)};return Se([function(){var o=Ka(n.bodyScrollable)(!1);return nF(o?function(){var u=eF(QO(n));return{body:u.body,bodyClass:u.bodyClass,centered:u.centered,contentClass:u.contentClass,contentStyle:u.contentStyle,dialogClass:u.dialogClass,dialogStyle:u.dialogStyle,footer:u.footer,footerClass:u.footerClass,headerClass:u.headerClass,scrollable:u.scrollable,size:u.size,header:a}}():QO({bodyClass:n.bodyClass,bodyScrollable:n.bodyScrollable,centered:n.centered,contentClass:n.contentClass,contentStyle:n.contentStyle,dialogClass:n.dialogClass,dialogStyle:n.dialogStyle,dismissButtonClass:n.dismissButtonClass,footer:n.footer,footerClass:n.footerClass,headerClass:n.headerClass,onDismiss:n.onDismiss,scrollable:n.scrollable,size:n.size,title:n.title,body:Se([a,n.body])}))}(),vse({keyup:fse(t)})])}},yp=function(e){var n=Am(e);return function(a){return function(t){return nF({bodyClass:a,body:Se(n(t))})}}};var uh="";function KO(e){var n=e.split(` `);return n.reduce(function(a,t){var o=dse(t)||hse(t)||Rse(t)||Ese(t)||wse(t);return o&&a.push(o),a},[])}var _se=/^\s*at (.*?) ?\(((?:file|https?|blob|chrome-extension|native|eval|webpack||\/|[a-z]:\\|\\\\).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,pse=/\((\S*)(?::(\d+))(?::(\d+))\)/;function dse(e){var n=_se.exec(e);if(!n)return null;var a=n[2]&&n[2].indexOf("native")===0,t=n[2]&&n[2].indexOf("eval")===0,o=pse.exec(n[2]);return t&&o!=null&&(n[2]=o[1],n[3]=o[2],n[4]=o[3]),{file:a?null:n[2],methodName:n[1]||uh,arguments:a?[n[2]]:[],lineNumber:n[3]?+n[3]:null,column:n[4]?+n[4]:null}}var mse=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i;function hse(e){var n=mse.exec(e);return n?{file:n[2],methodName:n[1]||uh,arguments:[],lineNumber:+n[3],column:n[4]?+n[4]:null}:null}var Dse=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|\[native).*?|[^@]*bundle)(?::(\d+))?(?::(\d+))?\s*$/i,gse=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i;function Rse(e){var n=Dse.exec(e);if(!n)return null;var a=n[3]&&n[3].indexOf(" > eval")>-1,t=gse.exec(n[3]);return a&&t!=null&&(n[3]=t[1],n[4]=t[2],n[5]=null),{file:n[3],methodName:n[1]||uh,arguments:n[2]?n[2].split(","):[],lineNumber:n[4]?+n[4]:null,column:n[5]?+n[5]:null}}var yse=/^\s*(?:([^@]*)(?:\((.*?)\))?@)?(\S.*?):(\d+)(?::(\d+))?\s*$/i;function wse(e){var n=yse.exec(e);return n?{file:n[3],methodName:n[1]||uh,arguments:[],lineNumber:+n[4],column:n[5]?+n[5]:null}:null}var bse=/^\s*at (?:((?:\[object object\])?[^\\/]+(?: \[as \S+\])?) )?\(?(.*?):(\d+)(?::(\d+))?\)?\s*$/i;function Ese(e){var n=bse.exec(e);return n?{file:n[2],methodName:n[1]||uh,arguments:[],lineNumber:+n[3],column:n[4]?+n[4]:null}:null}function YO({skipFrames:e,prefix:n}){let a=new Error().stack,o=KO(a)[e],u=XO(o.file.replace(/^(http(s?):\/\/)?[^\/]+/,"")),i=XO(o.methodName);return`${n}_${u}_${i}_${o.lineNumber}_${o.column}`}var XO=e=>e.replace(/[^\d\w]+/g,"_").replace(/(^_|_$)/g,"");var Ise=W(yn),Tse=pn(dn),aF=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var Sse=function(e){return jN(YO(e))},f_=function(e){return new aF(function(n){return n(e)})},uw=function(e){return function(n){return new aF(function(a){return hv(e)(n)(a)})}},Cse=function(e){return function(n){return hv(e)(function(a){return{init:Ise(Ee),update:hn(o0),view:hn(hn(n.value0(Tse)))}})(Ee)}};var iw=function(e){var n=Sse({skipFrames:3,prefix:"HooksComponent"});return Cse(n)(e)},Pv=function(){return function(e){return function(n){return new aF(function(a){return e.value0(function(t){var o=n(t);return o.value0(a)})})}}},Fse=Pv(),tF=function(e){return function(){return Fse}};var ZO=W(yn),Mse=pn(dn);var Ase=function(e){return function(n){return function(a){return uw(e)(function(t){return n({init:ZO(a),update:function(o){return function(u){return ZO(u)}},view:d0(t)})})}}},Ss=function(e){return Ase("UseState")(Mse)(e)};var Lse=Vr(),Pse=pn(dn),xse=np(me)()(),Nse=Wn(We)()(),jse=fo()();var lw="login",rF=function(){return function(e){var n=Lse(e),a=function(){var u=Ka(n.auth0ActiveTab)(lw);return u}(),t=ke({path:"",token:""})(Vy("login_path")),o=function(u){return function(i){return bn(Pse)(function(l){return v_(function(s){return{key:u,value:s}}(l))})(ll(i))}};return xse("d-inline")({method:"post",action:o("origin")(n.origin)(o("login_hint")(n.auth0LoginHint)(v_({key:"screen_hint",value:a})(t.path))),target:function(){var u=Ka(n.openInNewTab)(!1);return u?"_blank":""}()})([Nse(Ka(n.className)("btn btn-primary px-4"))({type:"submit",disabled:Ka(n.disabled)(!1)})(Ka(n.content)(Ke(Ka(n.text)("Log in")))),jse("")({type:"hidden",name:"authenticity_token",value:t.token})])}};var oF=typeof CV!="undefined"&&CV.assetsRoot||typeof global!="undefined"&&global.CV&&global.CV.assetsRoot||"/";var uF=zc(Uo(st)),Ose=pn(dn),Use=al()(),cw=function(e){var n=fi(e);return function(a){return Ct(n(a))}},kse=function(e){if(uF(cw("http://"))(uF(cw("https://"))(uF(cw("//"))(cw("blob:"))))(e))return e;if($e)return oF+ke(e)(fi("/")(e));throw new Error("Failed pattern match at Utils.AppAssets (line 47, column 1 - line 47, column 30): "+[e.constructor.name])},yu=function(){return function(){return function(e){return function(n){var a=function(o){return Ose},t=a(n)(P0("src")(kse(n.src))(n));return Use(e)(t)}}}};var __=function(e){return function(n){return function(){return n[e]}}},Bse=__("URL"),Hse=__("documentURI"),qse=__("origin"),Jse=__("compatMode"),Wse=__("characterSet"),$se=__("contentType");var zse=__("documentElement");var sw=function(e){return function(n){return n[e]}},Qse=sw("namespaceURI"),Kse=sw("prefix"),Yse=sw("localName"),Xse=sw("tagName");function iF(e){return function(){return e.id}}function lF(e){return function(){return e.classList}}function cF(e){return function(){var n=e.getBoundingClientRect();return{top:n.top,right:n.right,bottom:n.bottom,left:n.left,width:n.width,height:n.height,x:n.x,y:n.y}}}var sF=Je;var nU=Tn("Element");var $l=function(e){return function(n){return function(){return n[e]}}};var eve=$l("baseURI"),nve=$l("ownerDocument"),aU=$l("parentNode"),ave=$l("parentElement");var tve=$l("childNodes"),rve=$l("firstChild"),ove=$l("lastChild"),uve=$l("previousSibling"),ive=$l("nextSibling"),lve=$l("nodeValue");var cve=$l("textContent");function vF(e){return function(n){return function(){return e.isEqualNode(n)}}}var fve=k(zn);var tU=function(){var e=fve(fe);return function(n){return e(aU(n))}}();var _ve=JSON.stringify;var d_=function(){function e(){}return e.value=new e,e}(),rU=function(){function e(){}return e.value=new e,e}(),oU=function(){function e(){}return e.value=new e,e}(),ih=function(){function e(){}return e.value=new e,e}(),uU=function(){function e(){}return e.value=new e,e}(),iU=function(){function e(){}return e.value=new e,e}(),lU=function(){function e(){}return e.value=new e,e}();var vw=function(e){if(e instanceof d_)return M.value;if(e instanceof rU)return new T("for-you");if(e instanceof oU)return new T("chancing");if(e instanceof ih)return new T("finances");if(e instanceof uU)return new T("majors");if(e instanceof iU)return new T("admission-requirements");if(e instanceof lU)return new T("essay-prompts");throw new Error("Failed pattern match at SchoolDetails.Types (line 96, column 14 - line 103, column 39): "+[e.constructor.name])};var cU=Ja(tr);var sU=function(e){return cU(QS(e))(cU(sp)(Yu))};var fF=pe(ae);var _F=Lu(fn)(yt),hve=ba(),Dve=ui(ae),pF=function(e){return"/schools/"+e.slug},dF="/schools/hub";var vU=function(e){return function(n){var a=fF(OO(n.whatificator))(function(l){return"simulator="+l}),t=fF(n.mobileOverlay)(function(l){return"overlay="+JO(l)}),o=vr("&")(Jo([t,a])),u=fF(n.focusedSchool)(function(l){return _F("/")(Jo([new T(hve(l.slug)),vw(l.tab)]))}),i=function(){return e.knownSeoState instanceof T&&n.seoView?_F("/")(Jo([new T(pF({slug:e.knownSeoState.value0.slug})),u])):_F("/")(Jo([new T(dF),new T(bn(e.basePath)(aw)(n.ranking)),Dve(u)("d"),u]))}();return i+(function(){var l=o==="";return l?"":"?"}()+o)}};var fU="/profile";var Rve=ba();var mF=function(e){return function(n){return vr("/")(Jo([new T("/schools"),new T(Rve(n)),vw(e)]))}},_U=fU,pU="/livestreams/upcoming";var yve=function(e){return vU({basePath:"all",knownSeoState:M.value})({ranking:M.value,focusedSchool:e,mobileOverlay:M.value,seoView:!1,whatificator:tw.value})};var fw=function(e){return function(n){return yve(new T({tab:e,slug:n}))}};var dU=function(){function e(){}return e.value=new e,e}(),mU=function(){function e(){}return e.value=new e,e}(),_w=function(){function e(){}return e.value=new e,e}(),pw=function(){function e(){}return e.value=new e,e}(),hU=function(){function e(){}return e.value=new e,e}(),DU=function(){function e(){}return e.value=new e,e}(),gU=function(){function e(){}return e.value=new e,e}(),RU=function(e){if(e instanceof dU)return"avatar-xxs";if(e instanceof mU)return"avatar-xs";if(e instanceof _w)return"avatar-sm";if(e instanceof pw)return"";if(e instanceof hU)return"avatar-lg";if(e instanceof DU)return"avatar-xl";if(e instanceof gU)return"avatar-xxl";throw new Error("Failed pattern match at Dashkit.Avatar.Size (line 16, column 13 - line 23, column 34): "+[e.constructor.name])};var yU={show:ba()};var wve=Number.MAX_SAFE_INTEGER;var DF=function(e){if(e.first==="")return e.last;if(e.last==="")return e.first;if($e)return e.first+(" "+e.last);throw new Error("Failed pattern match at Profile.Types.Name (line 11, column 1 - line 11, column 27): "+[e.constructor.name])};var Uve=we(Iy);var bU={show:function(e){return e}};var EU=function(e){return Uve(e.publishScope)(bi.value)};var wp=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),gF=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),RF=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),yF=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),wF=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),bF=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var EF=ne(yU);var kve=ne(n4),Bve=ne(Pj),Hve=ne(bU),qve="/messages";var IF=function(e){return qve+("/"+function(){if(e instanceof wp)return"admission-officer/"+kve(e.value0);if(e instanceof gF)return"school/"+Bve(e.value0);if(e instanceof RF)return"student/"+Hve(e.value0);if(e instanceof yF)return"high-school/"+EF(e.value0);if(e instanceof wF)return"service-provider/"+EF(e.value0);if(e instanceof bF)return"parent/"+EF(e.value0);throw new Error("Failed pattern match at DirectMessages.Urls (line 28, column 48 - line 34, column 39): "+[e.constructor.name])}())};var Jve=ql(wc(Rc)),Wve=Z(_a),IU=pe(ae),TU=ba(),$ve=It(Ga);var SU=Jve("network_connections_invite_school_path")(function(e){return function(n){return Wve(e({school_id:n.schoolId,message:Fa(n.introMessage),sem_user_id:Fa(IU(n.semUserId)(TU)),livestream_id:Fa(IU(n.livestreamId)(TU))}))(Xt)}}),CU=function(e){return function(n){return $ve(SU({schoolId:e,introMessage:M.value,semUserId:M.value,livestreamId:new T(n)}))}};var FU=function(e){return function(n){return function(a){return SU({schoolId:e,introMessage:new T(a.introMessage),semUserId:new T(n),livestreamId:M.value})}}};$a();function ho(){return ho=Object.assign?Object.assign.bind():function(e){for(var n=1;n=0)&&(a[o]=e[o]);return a}function xv(e,n){if(e==null)return{};var a=TF(e,n),t,o;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);for(o=0;o=0)&&(!Object.prototype.propertyIsEnumerable.call(e,t)||(a[t]=e[t]))}return a}$a();$a();function m_(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function MU(e,n){for(var a=0;a1&&arguments[1]!==void 0?arguments[1]:1;PU+=1;var a=PU;function t(o){if(o===0)xU(a),e();else{var u=AU(function(){t(o-1)});FF.set(a,u)}}return t(n),a}Ti.cancel=function(e){var n=FF.get(e);return xU(n),LU(n)};function R_(e,n){return e?e.contains(n):!1}function sh(e){return e instanceof HTMLElement?e:gi.findDOMNode(e)}var kU=Cu(UU());$a();function LF(e,n){typeof e=="function"?e(n):eo(e)==="object"&&e&&"current"in e&&(e.current=n)}function Iw(){for(var e=arguments.length,n=new Array(e),a=0;ae.length)&&(n=e.length);for(var a=0,t=new Array(n);a1&&arguments[1]!==void 0?arguments[1]:2;n();var u=Ti(function(){o<=1?t({isCanceled:function(){return u!==e.current}}):a(t,o-1)});e.current=u}return Gt(function(){return function(){n()}},[]),[a,n]};$a();var afe=Ec()?Em:Gt,Aw=afe;var XU=[pl,Cs,Ov,Mw],HF=!1,ZU=!0;function Lw(e){return e===Ov||e===Mw}var e6=function(e,n){var a=Fs(BF),t=At(a,2),o=t[0],u=t[1],i=YU(),l=At(i,2),s=l[0],R=l[1];function d(){u(pl,!0)}return Aw(function(){if(o!==BF&&o!==Mw){var y=XU.indexOf(o),I=XU[y+1],b=n(o);b===HF?u(I,!0):s(function(S){function L(){S.isCanceled()||u(I,!0)}b===!0?L():Promise.resolve(b).then(L)})}},[e,o]),Gt(function(){return function(){R()}},[]),[d,o]};$a();$a();var n6=function(e){var n=lt(),a=lt(e);a.current=e;var t=bm(function(i){a.current(i)},[]);function o(i){i&&(i.removeEventListener(UF,t),i.removeEventListener(OF,t))}function u(i){n.current&&n.current!==i&&o(n.current),i&&i!==n.current&&(i.addEventListener(UF,t),i.addEventListener(OF,t),n.current=i)}return Gt(function(){return function(){o(n.current)}},[]),[u,o]};function qF(e,n,a,t){var o=t.motionEnter,u=o===void 0?!0:o,i=t.motionAppear,l=i===void 0?!0:i,s=t.motionLeave,R=s===void 0?!0:s,d=t.motionDeadline,y=t.motionLeaveImmediately,I=t.onAppearPrepare,b=t.onEnterPrepare,S=t.onLeavePrepare,L=t.onAppearStart,O=t.onEnterStart,$=t.onLeaveStart,z=t.onAppearActive,ee=t.onEnterActive,oe=t.onLeaveActive,te=t.onAppearEnd,ve=t.onEnterEnd,Re=t.onLeaveEnd,nn=t.onVisibleChanged,cn=Fs(),ce=At(cn,2),le=ce[0],Ne=ce[1],Ce=Fs(jv),Be=At(Ce,2),Xe=Be[0],Sn=Be[1],ra=Fs(null),kn=At(ra,2),Hn=kn[0],Kn=kn[1],qn=lt(!1),ft=lt(null);function Oe(){return a()}var ua=lt(!1);function Ta(ut){var q=Oe();if(!(ut&&!ut.deadline&&ut.target!==q)){var K=ua.current,j;Xe===vh&&K?j=te==null?void 0:te(q,ut):Xe===fh&&K?j=ve==null?void 0:ve(q,ut):Xe===_h&&K&&(j=Re==null?void 0:Re(q,ut)),Xe!==jv&&K&&j!==!1&&(Sn(jv,!0),Kn(null,!0))}}var En=n6(Ta),gn=At(En,1),He=gn[0],ea=Im(function(){var ut,q,K;switch(Xe){case vh:return ut={},Yo(ut,pl,I),Yo(ut,Cs,L),Yo(ut,Ov,z),ut;case fh:return q={},Yo(q,pl,b),Yo(q,Cs,O),Yo(q,Ov,ee),q;case _h:return K={},Yo(K,pl,S),Yo(K,Cs,$),Yo(K,Ov,oe),K;default:return{}}},[Xe]),va=e6(Xe,function(ut){if(ut===pl){var q=ea[pl];return q?q(Oe()):HF}if(sn in ea){var K;Kn(((K=ea[sn])===null||K===void 0?void 0:K.call(ea,Oe(),null))||null)}return sn===Ov&&(He(Oe()),d>0&&(clearTimeout(ft.current),ft.current=setTimeout(function(){Ta({deadline:!0})},d))),ZU}),La=At(va,2),_t=La[0],sn=La[1],ia=Lw(sn);ua.current=ia,Aw(function(){Ne(n);var ut=qn.current;if(qn.current=!0,!!e){var q;!ut&&n&&l&&(q=vh),ut&&n&&u&&(q=fh),(ut&&!n&&R||!ut&&y&&!n&&R)&&(q=_h),q&&(Sn(q),_t())}},[n]),Gt(function(){(Xe===vh&&!l||Xe===fh&&!u||Xe===_h&&!R)&&Sn(jv)},[l,u,R]),Gt(function(){return function(){qn.current=!1,clearTimeout(ft.current)}},[]);var bt=lt(!1);Gt(function(){le&&(bt.current=!0),le!==void 0&&Xe===jv&&((bt.current||le)&&(nn==null||nn(le)),bt.current=!0)},[le,Xe]);var Da=Hn;return ea[pl]&&sn===Cs&&(Da=Ea({transition:"none"},Da)),[Xe,sn,Da,le!=null?le:n]}$a();var tfe=function(e){D_(a,e);var n=g_(a);function a(){return m_(this,a),n.apply(this,arguments)}return h_(a,[{key:"render",value:function(){return this.props.children}}]),a}(Bf),a6=tfe;function rfe(e){var n=e;eo(e)==="object"&&(n=e.transitionSupport);function a(o){return!!(o.motionName&&n)}var t=Di(function(o,u){var i=o.visible,l=i===void 0?!0:i,s=o.removeOnLeave,R=s===void 0?!0:s,d=o.forceRender,y=o.children,I=o.motionName,b=o.leavedClassName,S=o.eventProps,L=a(o),O=lt(),$=lt();function z(){try{return O.current instanceof HTMLElement?O.current:sh($.current)}catch{return null}}var ee=qF(L,l,z,o),oe=At(ee,4),te=oe[0],ve=oe[1],Re=oe[2],nn=oe[3],cn=lt(nn);nn&&(cn.current=!0);var ce=bm(function(ra){O.current=ra,LF(u,ra)},[u]),le,Ne=Ea(Ea({},S),{},{visible:l});if(!y)le=null;else if(te===jv||!a(o))nn?le=y(Ea({},Ne),ce):!R&&cn.current?le=y(Ea(Ea({},Ne),{},{className:b}),ce):d?le=y(Ea(Ea({},Ne),{},{style:{display:"none"}}),ce):le=null;else{var Ce,Be;ve===pl?Be="prepare":Lw(ve)?Be="active":ve===Cs&&(Be="start"),le=y(Ea(Ea({},Ne),{},{className:(0,t6.default)(kF(I,te),(Ce={},Yo(Ce,kF(I,"".concat(te,"-").concat(Be)),Be),Yo(Ce,I,typeof I=="string"),Ce)),style:Re}),ce)}if(bT(le)&&Tw(le)){var Xe=le,Sn=Xe.ref;Sn||(le=wm(le,{ref:ce}))}return vt(a6,{ref:$},le)});return t.displayName="CSSMotion",t}var Pw=rfe(Gw);$a();var xw="add",Nw="keep",jw="remove",Ow="removed";function ofe(e){var n;return e&&eo(e)==="object"&&"key"in e?n=e:n={key:e},Ea(Ea({},n),{},{key:String(n.key)})}function Uw(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(ofe)}function r6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],a=[],t=0,o=n.length,u=Uw(e),i=Uw(n);u.forEach(function(R){for(var d=!1,y=t;y1});return s.forEach(function(R){a=a.filter(function(d){var y=d.key,I=d.status;return y!==R||I!==jw}),a.forEach(function(d){d.key===R&&(d.status=Nw)})}),a}var ufe=["component","children","onVisibleChanged","onAllRemoved"],ife=["status"],lfe=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function cfe(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Pw,a=function(t){D_(u,t);var o=g_(u);function u(){var i;m_(this,u);for(var l=arguments.length,s=new Array(l),R=0;R=0&&a.left>=0&&a.bottom>a.top&&a.right>a.left?a:null}function Lfe(e,n,a,t){var o=ja.clone(e),u={width:n.width,height:n.height};return t.adjustX&&o.left=a.left&&o.left+u.width>a.right&&(u.width-=o.left+u.width-a.right),t.adjustX&&o.left+u.width>a.right&&(o.left=Math.max(a.right-u.width,a.left)),t.adjustY&&o.top=a.top&&o.top+u.height>a.bottom&&(u.height-=o.top+u.height-a.bottom),t.adjustY&&o.top+u.height>a.bottom&&(o.top=Math.max(a.bottom-u.height,a.top)),ja.mix(o,u)}function nG(e){var n,a,t;if(!ja.isWindow(e)&&e.nodeType!==9)n=ja.offset(e),a=ja.outerWidth(e),t=ja.outerHeight(e);else{var o=ja.getWindow(e);n={left:ja.getWindowScrollLeft(o),top:ja.getWindowScrollTop(o)},a=ja.viewportWidth(o),t=ja.viewportHeight(o)}return n.width=a,n.height=t,n}function b6(e,n){var a=n.charAt(0),t=n.charAt(1),o=e.width,u=e.height,i=e.left,l=e.top;return a==="c"?l+=u/2:a==="b"&&(l+=u),t==="c"?i+=o/2:t==="r"&&(i+=o),{left:i,top:l}}function Ww(e,n,a,t,o){var u=b6(n,a[1]),i=b6(e,a[0]),l=[i.left-u.left,i.top-u.top];return{left:Math.round(e.left-l[0]+t[0]-o[0]),top:Math.round(e.top-l[1]+t[1]-o[1])}}function E6(e,n,a){return e.lefta.right}function I6(e,n,a){return e.topa.bottom}function Pfe(e,n,a){return e.left>a.right||e.left+n.widtha.bottom||e.top+n.height=a.right||t.top>=a.bottom}function Vw(e,n,a){var t=a.target||n,o=nG(t),u=!Nfe(t,a.overflow&&a.overflow.alwaysByViewport);return C6(e,o,a,u)}Vw.__getOffsetParent=ZF;Vw.__getVisibleRectForElement=eG;function F6(e,n,a){var t,o,u=ja.getDocument(e),i=u.defaultView||u.parentWindow,l=ja.getWindowScrollLeft(i),s=ja.getWindowScrollTop(i),R=ja.viewportWidth(i),d=ja.viewportHeight(i);"pageX"in n?t=n.pageX:t=l+n.clientX,"pageY"in n?o=n.pageY:o=s+n.clientY;var y={left:t,top:o,width:0,height:0},I=t>=0&&t<=l+R&&o>=0&&o<=s+d,b=[a.points[0],"cc"];return C6(e,y,l6(l6({},a),{},{points:b}),I)}var _B=Cu(aB());var tB=function(){if(typeof Map!="undefined")return Map;function e(n,a){var t=-1;return n.some(function(o,u){return o[0]===a?(t=u,!0):!1}),t}return function(){function n(){this.__entries__=[]}return Object.defineProperty(n.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),n.prototype.get=function(a){var t=e(this.__entries__,a),o=this.__entries__[t];return o&&o[1]},n.prototype.set=function(a,t){var o=e(this.__entries__,a);~o?this.__entries__[o][1]=t:this.__entries__.push([a,t])},n.prototype.delete=function(a){var t=this.__entries__,o=e(t,a);~o&&t.splice(o,1)},n.prototype.has=function(a){return!!~e(this.__entries__,a)},n.prototype.clear=function(){this.__entries__.splice(0)},n.prototype.forEach=function(a,t){t===void 0&&(t=null);for(var o=0,u=this.__entries__;o0},e.prototype.connect_=function(){!yG||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),che?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){!yG||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(n){var a=n.propertyName,t=a===void 0?"":a,o=lhe.some(function(u){return!!~t.indexOf(u)});o&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),rB=function(e,n){for(var a=0,t=Object.keys(n);a0},e}(),iB=typeof WeakMap!="undefined"?new WeakMap:new tB,lB=function(){function e(n){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var a=she.getInstance(),t=new Rhe(n,a,this);iB.set(this,t)}return e}();["observe","unobserve","disconnect"].forEach(function(e){lB.prototype[e]=function(){var n;return(n=iB.get(this))[e].apply(n,arguments)}});var yhe=function(){return typeof eb.ResizeObserver!="undefined"?eb.ResizeObserver:lB}(),cB=yhe;function sB(e,n){return e===n?!0:!e||!n?!1:"pageX"in n&&"pageY"in n?e.pageX===n.pageX&&e.pageY===n.pageY:"clientX"in n&&"clientY"in n?e.clientX===n.clientX&&e.clientY===n.clientY:!1}function vB(e,n){e!==document.activeElement&&R_(n,e)&&typeof e.focus=="function"&&e.focus()}function wG(e,n){var a=null,t=null;function o(i){var l=At(i,1),s=l[0].target;if(!!document.documentElement.contains(s)){var R=s.getBoundingClientRect(),d=R.width,y=R.height,I=Math.floor(d),b=Math.floor(y);(a!==I||t!==b)&&Promise.resolve().then(function(){n({width:I,height:b})}),a=I,t=b}}var u=new cB(o);return e&&u.observe(e),function(){u.disconnect()}}$a();var fB=function(e,n){var a=ka.useRef(!1),t=ka.useRef(null);function o(){window.clearTimeout(t.current)}function u(i){if(o(),!a.current||i===!0){if(e()===!1)return;a.current=!0,t.current=window.setTimeout(function(){a.current=!1},n)}else t.current=window.setTimeout(function(){a.current=!1,u()},n)}return[u,function(){a.current=!1,o()}]};function pB(e){return typeof e!="function"?null:e()}function dB(e){return eo(e)!=="object"||!e?null:e}var whe=function(n,a){var t=n.children,o=n.disabled,u=n.target,i=n.align,l=n.onAlign,s=n.monitorWindowResize,R=n.monitorBufferTime,d=R===void 0?0:R,y=ka.useRef({}),I=ka.useRef(),b=ka.Children.only(t),S=ka.useRef({});S.current.disabled=o,S.current.target=u,S.current.align=i,S.current.onAlign=l;var L=fB(function(){var ve=S.current,Re=ve.disabled,nn=ve.target,cn=ve.align,ce=ve.onAlign;if(!Re&&nn){var le=I.current,Ne,Ce=pB(nn),Be=dB(nn);y.current.element=Ce,y.current.point=Be,y.current.align=cn;var Xe=document,Sn=Xe.activeElement;return Ce&&u6(Ce)?Ne=Vw(le,Ce,cn):Be&&(Ne=F6(le,Be,cn)),vB(Sn,le),ce&&Ne&&ce(le,Ne),!0}return!1},d),O=At(L,2),$=O[0],z=O[1],ee=ka.useRef({cancel:function(){}}),oe=ka.useRef({cancel:function(){}});ka.useEffect(function(){var ve=pB(u),Re=dB(u);I.current!==oe.current.element&&(oe.current.cancel(),oe.current.element=I.current,oe.current.cancel=wG(I.current,$)),(y.current.element!==ve||!sB(y.current.point,Re)||!(0,_B.default)(y.current.align,i))&&($(),ee.current.element!==ve&&(ee.current.cancel(),ee.current.element=ve,ee.current.cancel=wG(ve,$)))}),ka.useEffect(function(){o?z():$()},[o]);var te=ka.useRef(null);return ka.useEffect(function(){s?te.current||(te.current=Nv(window,"resize",$)):te.current&&(te.current.remove(),te.current=null)},[s]),ka.useEffect(function(){return function(){ee.current.cancel(),oe.current.cancel(),te.current&&te.current.remove(),z()}},[]),ka.useImperativeHandle(a,function(){return{forceAlign:function(){return $(!0)}}}),ka.isValidElement(b)&&(b=ka.cloneElement(b,{ref:Iw(b.ref,I)})),b},mB=ka.forwardRef(whe);mB.displayName="Align";var hB=mB;var DB=hB;$a();var bhe=Ec()?Em:Gt,bG=bhe;var bB=Cu(y_());function Ch(){"use strict";Ch=function(){return e};var e={},n=Object.prototype,a=n.hasOwnProperty,t=typeof Symbol=="function"?Symbol:{},o=t.iterator||"@@iterator",u=t.asyncIterator||"@@asyncIterator",i=t.toStringTag||"@@toStringTag";function l(ce,le,Ne){return Object.defineProperty(ce,le,{value:Ne,enumerable:!0,configurable:!0,writable:!0}),ce[le]}try{l({},"")}catch{l=function(Ne,Ce,Be){return Ne[Ce]=Be}}function s(ce,le,Ne,Ce){var Be=le&&le.prototype instanceof y?le:y,Xe=Object.create(Be.prototype),Sn=new Re(Ce||[]);return Xe._invoke=function(ra,kn,Hn){var Kn="suspendedStart";return function(qn,ft){if(Kn==="executing")throw new Error("Generator is already running");if(Kn==="completed"){if(qn==="throw")throw ft;return cn()}for(Hn.method=qn,Hn.arg=ft;;){var Oe=Hn.delegate;if(Oe){var ua=oe(Oe,Hn);if(ua){if(ua===d)continue;return ua}}if(Hn.method==="next")Hn.sent=Hn._sent=Hn.arg;else if(Hn.method==="throw"){if(Kn==="suspendedStart")throw Kn="completed",Hn.arg;Hn.dispatchException(Hn.arg)}else Hn.method==="return"&&Hn.abrupt("return",Hn.arg);Kn="executing";var Ta=R(ra,kn,Hn);if(Ta.type==="normal"){if(Kn=Hn.done?"completed":"suspendedYield",Ta.arg===d)continue;return{value:Ta.arg,done:Hn.done}}Ta.type==="throw"&&(Kn="completed",Hn.method="throw",Hn.arg=Ta.arg)}}}(ce,Ne,Sn),Xe}function R(ce,le,Ne){try{return{type:"normal",arg:ce.call(le,Ne)}}catch(Ce){return{type:"throw",arg:Ce}}}e.wrap=s;var d={};function y(){}function I(){}function b(){}var S={};l(S,o,function(){return this});var L=Object.getPrototypeOf,O=L&&L(L(nn([])));O&&O!==n&&a.call(O,o)&&(S=O);var $=b.prototype=y.prototype=Object.create(S);function z(ce){["next","throw","return"].forEach(function(le){l(ce,le,function(Ne){return this._invoke(le,Ne)})})}function ee(ce,le){function Ne(Be,Xe,Sn,ra){var kn=R(ce[Be],ce,Xe);if(kn.type!=="throw"){var Hn=kn.arg,Kn=Hn.value;return Kn&&eo(Kn)=="object"&&a.call(Kn,"__await")?le.resolve(Kn.__await).then(function(qn){Ne("next",qn,Sn,ra)},function(qn){Ne("throw",qn,Sn,ra)}):le.resolve(Kn).then(function(qn){Hn.value=qn,Sn(Hn)},function(qn){return Ne("throw",qn,Sn,ra)})}ra(kn.arg)}var Ce;this._invoke=function(Be,Xe){function Sn(){return new le(function(ra,kn){Ne(Be,Xe,ra,kn)})}return Ce=Ce?Ce.then(Sn,Sn):Sn()}}function oe(ce,le){var Ne=ce.iterator[le.method];if(Ne===void 0){if(le.delegate=null,le.method==="throw"){if(ce.iterator.return&&(le.method="return",le.arg=void 0,oe(ce,le),le.method==="throw"))return d;le.method="throw",le.arg=new TypeError("The iterator does not provide a 'throw' method")}return d}var Ce=R(Ne,ce.iterator,le.arg);if(Ce.type==="throw")return le.method="throw",le.arg=Ce.arg,le.delegate=null,d;var Be=Ce.arg;return Be?Be.done?(le[ce.resultName]=Be.value,le.next=ce.nextLoc,le.method!=="return"&&(le.method="next",le.arg=void 0),le.delegate=null,d):Be:(le.method="throw",le.arg=new TypeError("iterator result is not an object"),le.delegate=null,d)}function te(ce){var le={tryLoc:ce[0]};1 in ce&&(le.catchLoc=ce[1]),2 in ce&&(le.finallyLoc=ce[2],le.afterLoc=ce[3]),this.tryEntries.push(le)}function ve(ce){var le=ce.completion||{};le.type="normal",delete le.arg,ce.completion=le}function Re(ce){this.tryEntries=[{tryLoc:"root"}],ce.forEach(te,this),this.reset(!0)}function nn(ce){if(ce){var le=ce[o];if(le)return le.call(ce);if(typeof ce.next=="function")return ce;if(!isNaN(ce.length)){var Ne=-1,Ce=function Be(){for(;++Ne=0;--Be){var Xe=this.tryEntries[Be],Sn=Xe.completion;if(Xe.tryLoc==="root")return Ce("end");if(Xe.tryLoc<=this.prev){var ra=a.call(Xe,"catchLoc"),kn=a.call(Xe,"finallyLoc");if(ra&&kn){if(this.prev=0;--Ce){var Be=this.tryEntries[Ce];if(Be.tryLoc<=this.prev&&a.call(Be,"finallyLoc")&&this.prev=0;--Ne){var Ce=this.tryEntries[Ne];if(Ce.finallyLoc===le)return this.complete(Ce.completion,Ce.afterLoc),ve(Ce),d}},catch:function(le){for(var Ne=this.tryEntries.length-1;Ne>=0;--Ne){var Ce=this.tryEntries[Ne];if(Ce.tryLoc===le){var Be=Ce.completion;if(Be.type==="throw"){var Xe=Be.arg;ve(Ce)}return Xe}}throw new Error("illegal catch attempt")},delegateYield:function(le,Ne,Ce){return this.delegate={iterator:nn(le),resultName:Ne,nextLoc:Ce},this.method==="next"&&(this.arg=void 0),d}},e}function gB(e,n,a,t,o,u,i){try{var l=e[u](i),s=l.value}catch(R){a(R);return}l.done?n(s):Promise.resolve(s).then(t,o)}function EG(e){return function(){var n=this,a=arguments;return new Promise(function(t,o){var u=e.apply(n,a);function i(s){gB(u,t,o,i,l,"next",s)}function l(s){gB(u,t,o,i,l,"throw",s)}i(void 0)})}}$a();var RB=["measure","alignPre","align",null,"motion"],yB=function(e,n){var a=Fs(null),t=At(a,2),o=t[0],u=t[1],i=lt();function l(d){u(d,!0)}function s(){Ti.cancel(i.current)}function R(d){s(),i.current=Ti(function(){l(function(y){switch(o){case"align":return"motion";case"motion":return"stable";default:}return y}),d==null||d()})}return Gt(function(){l("measure")},[e]),Gt(function(){switch(o){case"measure":n();break;default:}o&&(i.current=Ti(EG(Ch().mark(function d(){var y,I;return Ch().wrap(function(S){for(;;)switch(S.prev=S.next){case 0:y=RB.indexOf(o),I=RB[y+1],I&&y!==-1&&l(I);case 3:case"end":return S.stop()}},d)}))))},[o]),Gt(function(){return function(){s()}},[]),[o,R]};$a();var wB=function(e){var n=Ll({width:0,height:0}),a=At(n,2),t=a[0],o=a[1];function u(l){o({width:l.offsetWidth,height:l.offsetHeight})}var i=Im(function(){var l={};if(e){var s=t.width,R=t.height;e.indexOf("height")!==-1&&R?l.height=R:e.indexOf("minHeight")!==-1&&R&&(l.minHeight=R),e.indexOf("width")!==-1&&s?l.width=s:e.indexOf("minWidth")!==-1&&s&&(l.minWidth=s)}return l},[e,t]);return[i,u]};var EB=Di(function(e,n){var a=e.visible,t=e.prefixCls,o=e.className,u=e.style,i=e.children,l=e.zIndex,s=e.stretch,R=e.destroyPopupOnHide,d=e.forceRender,y=e.align,I=e.point,b=e.getRootDomNode,S=e.getClassNameFromAlign,L=e.onAlign,O=e.onMouseEnter,$=e.onMouseLeave,z=e.onMouseDown,ee=e.onTouchStart,oe=e.onClick,te=lt(),ve=lt(),Re=Ll(),nn=At(Re,2),cn=nn[0],ce=nn[1],le=wB(s),Ne=At(le,2),Ce=Ne[0],Be=Ne[1];function Xe(){s&&Be(b())}var Sn=yB(a,Xe),ra=At(Sn,2),kn=ra[0],Hn=ra[1],Kn=Ll(0),qn=At(Kn,2),ft=qn[0],Oe=qn[1],ua=lt();bG(function(){kn==="alignPre"&&Oe(0)},[kn]);function Ta(){return I||b}function En(){var sn;(sn=te.current)===null||sn===void 0||sn.forceAlign()}function gn(sn,ia){var bt=S(ia);cn!==bt&&ce(bt),Oe(function(Da){return Da+1}),kn==="align"&&(L==null||L(sn,ia))}bG(function(){kn==="align"&&(ft<2?En():Hn(function(){var sn;(sn=ua.current)===null||sn===void 0||sn.call(ua)}))},[ft]);var He=Ea({},kw(e));["onAppearEnd","onEnterEnd","onLeaveEnd"].forEach(function(sn){var ia=He[sn];He[sn]=function(bt,Da){return Hn(),ia==null?void 0:ia(bt,Da)}});function ea(){return new Promise(function(sn){ua.current=sn})}Gt(function(){!He.motionName&&kn==="motion"&&Hn()},[He.motionName,kn]),rs(n,function(){return{forceAlign:En,getElement:function(){return ve.current}}});var va=Ea(Ea({},Ce),{},{zIndex:l,opacity:kn==="motion"||kn==="stable"||!a?void 0:0,pointerEvents:!a&&kn!=="stable"?"none":void 0},u),La=!0;(y==null?void 0:y.points)&&(kn==="align"||kn==="stable")&&(La=!1);var _t=i;return kf.count(i)>1&&(_t=vt("div",{className:"".concat(t,"-content")},i)),vt(Ep,ho({visible:a,ref:ve,leavedClassName:"".concat(t,"-hidden")},He,{onAppearPrepare:ea,onEnterPrepare:ea,removeOnLeave:R,forceRender:d}),function(sn,ia){var bt=sn.className,Da=sn.style,ut=(0,bB.default)(t,o,cn,bt);return vt(DB,{target:Ta(),key:"popup",ref:te,monitorWindowResize:!0,disabled:La,align:y,onAlign:gn},vt("div",{ref:ia,className:ut,onMouseEnter:O,onMouseLeave:$,onMouseDownCapture:z,onTouchStartCapture:ee,onClick:oe,style:Ea(Ea({},Da),va)},_t))})});EB.displayName="PopupInner";var IB=EB;$a();var TB=Cu(y_()),SB=Di(function(e,n){var a=e.prefixCls,t=e.visible,o=e.zIndex,u=e.children,i=e.mobile;i=i===void 0?{}:i;var l=i.popupClassName,s=i.popupStyle,R=i.popupMotion,d=R===void 0?{}:R,y=i.popupRender,I=e.onClick,b=lt();rs(n,function(){return{forceAlign:function(){},getElement:function(){return b.current}}});var S=Ea({zIndex:o},s),L=u;return kf.count(u)>1&&(L=vt("div",{className:"".concat(a,"-content")},u)),y&&(L=y(L)),vt(Ep,ho({visible:t,ref:b,removeOnLeave:!0},d),function(O,$){var z=O.className,ee=O.style,oe=(0,TB.default)(a,l,z);return vt("div",{ref:$,className:oe,onClick:I,style:Ea(Ea({},ee),S)},L)})});SB.displayName="MobilePopupInner";var CB=SB;var Ehe=["visible","mobile"],FB=Di(function(e,n){var a=e.visible,t=e.mobile,o=xv(e,Ehe),u=Ll(a),i=At(u,2),l=i[0],s=i[1],R=Ll(!1),d=At(R,2),y=d[0],I=d[1],b=Ea(Ea({},o),{},{visible:l});Gt(function(){s(a),a&&t&&I(JU())},[a,t]);var S=y?vt(CB,ho({},b,{mobile:t,ref:n})):vt(IB,ho({},b,{ref:n}));return vt("div",null,vt(JF,b),S)});FB.displayName="Popup";var GB=FB;$a();var Ihe=yT(null),IG=Ihe;function TG(){}function The(){return""}function She(e){return e?e.ownerDocument:window.document}var Che=["onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur","onContextMenu"];function Fhe(e){var n=function(a){D_(o,a);var t=g_(o);function o(u){var i;m_(this,o),i=t.call(this,u),i.popupRef=PR(),i.triggerRef=PR(),i.portalContainer=void 0,i.attachId=void 0,i.clickOutsideHandler=void 0,i.touchOutsideHandler=void 0,i.contextMenuOutsideHandler1=void 0,i.contextMenuOutsideHandler2=void 0,i.mouseDownTimeout=void 0,i.focusTime=void 0,i.preClickTime=void 0,i.preTouchTime=void 0,i.delayTimer=void 0,i.hasPopupMouseDown=void 0,i.onMouseEnter=function(s){var R=i.props.mouseEnterDelay;i.fireEvents("onMouseEnter",s),i.delaySetPopupVisible(!0,R,R?null:s)},i.onMouseMove=function(s){i.fireEvents("onMouseMove",s),i.setPoint(s)},i.onMouseLeave=function(s){i.fireEvents("onMouseLeave",s),i.delaySetPopupVisible(!1,i.props.mouseLeaveDelay)},i.onPopupMouseEnter=function(){i.clearDelayTimer()},i.onPopupMouseLeave=function(s){var R;s.relatedTarget&&!s.relatedTarget.setTimeout&&R_((R=i.popupRef.current)===null||R===void 0?void 0:R.getElement(),s.relatedTarget)||i.delaySetPopupVisible(!1,i.props.mouseLeaveDelay)},i.onFocus=function(s){i.fireEvents("onFocus",s),i.clearDelayTimer(),i.isFocusToShow()&&(i.focusTime=Date.now(),i.delaySetPopupVisible(!0,i.props.focusDelay))},i.onMouseDown=function(s){i.fireEvents("onMouseDown",s),i.preClickTime=Date.now()},i.onTouchStart=function(s){i.fireEvents("onTouchStart",s),i.preTouchTime=Date.now()},i.onBlur=function(s){i.fireEvents("onBlur",s),i.clearDelayTimer(),i.isBlurToHide()&&i.delaySetPopupVisible(!1,i.props.blurDelay)},i.onContextMenu=function(s){s.preventDefault(),i.fireEvents("onContextMenu",s),i.setPopupVisible(!0,s)},i.onContextMenuClose=function(){i.isContextMenuToShow()&&i.close()},i.onClick=function(s){if(i.fireEvents("onClick",s),i.focusTime){var R;if(i.preClickTime&&i.preTouchTime?R=Math.min(i.preClickTime,i.preTouchTime):i.preClickTime?R=i.preClickTime:i.preTouchTime&&(R=i.preTouchTime),Math.abs(R-i.focusTime)<20)return;i.focusTime=0}i.preClickTime=0,i.preTouchTime=0,i.isClickToShow()&&(i.isClickToHide()||i.isBlurToHide())&&s&&s.preventDefault&&s.preventDefault();var d=!i.state.popupVisible;(i.isClickToHide()&&!d||d&&i.isClickToShow())&&i.setPopupVisible(!i.state.popupVisible,s)},i.onPopupMouseDown=function(){if(i.hasPopupMouseDown=!0,clearTimeout(i.mouseDownTimeout),i.mouseDownTimeout=window.setTimeout(function(){i.hasPopupMouseDown=!1},0),i.context){var s;(s=i.context).onPopupMouseDown.apply(s,arguments)}},i.onDocumentClick=function(s){if(!(i.props.mask&&!i.props.maskClosable)){var R=s.target,d=i.getRootDomNode(),y=i.getPopupDomNode();(!R_(d,R)||i.isContextMenuOnly())&&!R_(y,R)&&!i.hasPopupMouseDown&&i.close()}},i.getRootDomNode=function(){var s=i.props.getTriggerDOMNode;if(s)return s(i.triggerRef.current);try{var R=sh(i.triggerRef.current);if(R)return R}catch{}return gi.findDOMNode(lh(i))},i.getPopupClassNameFromAlign=function(s){var R=[],d=i.props,y=d.popupPlacement,I=d.builtinPlacements,b=d.prefixCls,S=d.alignPoint,L=d.getPopupClassNameFromAlign;return y&&I&&R.push(qU(I,b,s,S)),L&&R.push(L(s)),R.join(" ")},i.getComponent=function(){var s=i.props,R=s.prefixCls,d=s.destroyPopupOnHide,y=s.popupClassName,I=s.onPopupAlign,b=s.popupMotion,S=s.popupAnimation,L=s.popupTransitionName,O=s.popupStyle,$=s.mask,z=s.maskAnimation,ee=s.maskTransitionName,oe=s.maskMotion,te=s.zIndex,ve=s.popup,Re=s.stretch,nn=s.alignPoint,cn=s.mobile,ce=s.forceRender,le=s.onPopupClick,Ne=i.state,Ce=Ne.popupVisible,Be=Ne.point,Xe=i.getPopupAlign(),Sn={};return i.isMouseEnterToShow()&&(Sn.onMouseEnter=i.onPopupMouseEnter),i.isMouseLeaveToHide()&&(Sn.onMouseLeave=i.onPopupMouseLeave),Sn.onMouseDown=i.onPopupMouseDown,Sn.onTouchStart=i.onPopupMouseDown,vt(GB,ho({prefixCls:R,destroyPopupOnHide:d,visible:Ce,point:nn&&Be,className:y,align:Xe,onAlign:I,animation:S,getClassNameFromAlign:i.getPopupClassNameFromAlign},Sn,{stretch:Re,getRootDomNode:i.getRootDomNode,style:O,mask:$,zIndex:te,transitionName:L,maskAnimation:z,maskTransitionName:ee,maskMotion:oe,ref:i.popupRef,motion:b,mobile:cn,forceRender:ce,onClick:le}),typeof ve=="function"?ve():ve)},i.attachParent=function(s){Ti.cancel(i.attachId);var R=i.props,d=R.getPopupContainer,y=R.getDocument,I=i.getRootDomNode(),b;d?(I||d.length===0)&&(b=d(I)):b=y(i.getRootDomNode()).body,b?b.appendChild(s):i.attachId=Ti(function(){i.attachParent(s)})},i.getContainer=function(){if(!i.portalContainer){var s=i.props.getDocument,R=s(i.getRootDomNode()).createElement("div");R.style.position="absolute",R.style.top="0",R.style.left="0",R.style.width="100%",i.portalContainer=R}return i.attachParent(i.portalContainer),i.portalContainer},i.setPoint=function(s){var R=i.props.alignPoint;!R||!s||i.setState({point:{pageX:s.pageX,pageY:s.pageY}})},i.handlePortalUpdate=function(){i.state.prevPopupVisible!==i.state.popupVisible&&i.props.afterPopupVisibleChange(i.state.popupVisible)},i.triggerContextValue={onPopupMouseDown:i.onPopupMouseDown};var l;return"popupVisible"in u?l=!!u.popupVisible:l=!!u.defaultPopupVisible,i.state={prevPopupVisible:l,popupVisible:l},Che.forEach(function(s){i["fire".concat(s)]=function(R){i.fireEvents(s,R)}}),i}return h_(o,[{key:"componentDidMount",value:function(){this.componentDidUpdate()}},{key:"componentDidUpdate",value:function(){var i=this.props,l=this.state;if(l.popupVisible){var s;!this.clickOutsideHandler&&(this.isClickToHide()||this.isContextMenuToShow())&&(s=i.getDocument(this.getRootDomNode()),this.clickOutsideHandler=Nv(s,"mousedown",this.onDocumentClick)),this.touchOutsideHandler||(s=s||i.getDocument(this.getRootDomNode()),this.touchOutsideHandler=Nv(s,"touchstart",this.onDocumentClick)),!this.contextMenuOutsideHandler1&&this.isContextMenuToShow()&&(s=s||i.getDocument(this.getRootDomNode()),this.contextMenuOutsideHandler1=Nv(s,"scroll",this.onContextMenuClose)),!this.contextMenuOutsideHandler2&&this.isContextMenuToShow()&&(this.contextMenuOutsideHandler2=Nv(window,"blur",this.onContextMenuClose));return}this.clearOutsideHandler()}},{key:"componentWillUnmount",value:function(){this.clearDelayTimer(),this.clearOutsideHandler(),clearTimeout(this.mouseDownTimeout),Ti.cancel(this.attachId)}},{key:"getPopupDomNode",value:function(){var i;return((i=this.popupRef.current)===null||i===void 0?void 0:i.getElement())||null}},{key:"getPopupAlign",value:function(){var i=this.props,l=i.popupPlacement,s=i.popupAlign,R=i.builtinPlacements;return l&&R?HU(R,l,s):s}},{key:"setPopupVisible",value:function(i,l){var s=this.props.alignPoint,R=this.state.popupVisible;this.clearDelayTimer(),R!==i&&("popupVisible"in this.props||this.setState({popupVisible:i,prevPopupVisible:R}),this.props.onPopupVisibleChange(i)),s&&l&&i&&this.setPoint(l)}},{key:"delaySetPopupVisible",value:function(i,l,s){var R=this,d=l*1e3;if(this.clearDelayTimer(),d){var y=s?{pageX:s.pageX,pageY:s.pageY}:null;this.delayTimer=window.setTimeout(function(){R.setPopupVisible(i,y),R.clearDelayTimer()},d)}else this.setPopupVisible(i,s)}},{key:"clearDelayTimer",value:function(){this.delayTimer&&(clearTimeout(this.delayTimer),this.delayTimer=null)}},{key:"clearOutsideHandler",value:function(){this.clickOutsideHandler&&(this.clickOutsideHandler.remove(),this.clickOutsideHandler=null),this.contextMenuOutsideHandler1&&(this.contextMenuOutsideHandler1.remove(),this.contextMenuOutsideHandler1=null),this.contextMenuOutsideHandler2&&(this.contextMenuOutsideHandler2.remove(),this.contextMenuOutsideHandler2=null),this.touchOutsideHandler&&(this.touchOutsideHandler.remove(),this.touchOutsideHandler=null)}},{key:"createTwoChains",value:function(i){var l=this.props.children.props,s=this.props;return l[i]&&s[i]?this["fire".concat(i)]:l[i]||s[i]}},{key:"isClickToShow",value:function(){var i=this.props,l=i.action,s=i.showAction;return l.indexOf("click")!==-1||s.indexOf("click")!==-1}},{key:"isContextMenuOnly",value:function(){var i=this.props.action;return i==="contextMenu"||i.length===1&&i[0]==="contextMenu"}},{key:"isContextMenuToShow",value:function(){var i=this.props,l=i.action,s=i.showAction;return l.indexOf("contextMenu")!==-1||s.indexOf("contextMenu")!==-1}},{key:"isClickToHide",value:function(){var i=this.props,l=i.action,s=i.hideAction;return l.indexOf("click")!==-1||s.indexOf("click")!==-1}},{key:"isMouseEnterToShow",value:function(){var i=this.props,l=i.action,s=i.showAction;return l.indexOf("hover")!==-1||s.indexOf("mouseEnter")!==-1}},{key:"isMouseLeaveToHide",value:function(){var i=this.props,l=i.action,s=i.hideAction;return l.indexOf("hover")!==-1||s.indexOf("mouseLeave")!==-1}},{key:"isFocusToShow",value:function(){var i=this.props,l=i.action,s=i.showAction;return l.indexOf("focus")!==-1||s.indexOf("focus")!==-1}},{key:"isBlurToHide",value:function(){var i=this.props,l=i.action,s=i.hideAction;return l.indexOf("focus")!==-1||s.indexOf("blur")!==-1}},{key:"forcePopupAlign",value:function(){if(this.state.popupVisible){var i;(i=this.popupRef.current)===null||i===void 0||i.forceAlign()}}},{key:"fireEvents",value:function(i,l){var s=this.props.children.props[i];s&&s(l);var R=this.props[i];R&&R(l)}},{key:"close",value:function(){this.setPopupVisible(!1)}},{key:"render",value:function(){var i=this.state.popupVisible,l=this.props,s=l.children,R=l.forceRender,d=l.alignPoint,y=l.className,I=l.autoDestroy,b=kf.only(s),S={key:"trigger"};this.isContextMenuToShow()?S.onContextMenu=this.onContextMenu:S.onContextMenu=this.createTwoChains("onContextMenu"),this.isClickToHide()||this.isClickToShow()?(S.onClick=this.onClick,S.onMouseDown=this.onMouseDown,S.onTouchStart=this.onTouchStart):(S.onClick=this.createTwoChains("onClick"),S.onMouseDown=this.createTwoChains("onMouseDown"),S.onTouchStart=this.createTwoChains("onTouchStart")),this.isMouseEnterToShow()?(S.onMouseEnter=this.onMouseEnter,d&&(S.onMouseMove=this.onMouseMove)):S.onMouseEnter=this.createTwoChains("onMouseEnter"),this.isMouseLeaveToHide()?S.onMouseLeave=this.onMouseLeave:S.onMouseLeave=this.createTwoChains("onMouseLeave"),this.isFocusToShow()||this.isBlurToHide()?(S.onFocus=this.onFocus,S.onBlur=this.onBlur):(S.onFocus=this.createTwoChains("onFocus"),S.onBlur=this.createTwoChains("onBlur"));var L=(0,MB.default)(b&&b.props&&b.props.className,y);L&&(S.className=L);var O=Ea({},S);Tw(b)&&(O.ref=Iw(this.triggerRef,b.ref));var $=wm(b,O),z;return(i||this.popupRef.current||R)&&(z=vt(e,{key:"portal",getContainer:this.getContainer,didUpdate:this.handlePortalUpdate},this.getComponent())),!i&&I&&(z=null),vt(IG.Provider,{value:this.triggerContextValue},$,z)}}],[{key:"getDerivedStateFromProps",value:function(i,l){var s=i.popupVisible,R={};return s!==void 0&&l.popupVisible!==s&&(R.popupVisible=s,R.prevPopupVisible=l.popupVisible),R}}]),o}(Bf);return n.contextType=IG,n.defaultProps={prefixCls:"rc-trigger-popup",getPopupClassNameFromAlign:The,getDocument:She,onPopupVisibleChange:TG,afterPopupVisibleChange:TG,onPopupAlign:TG,popupClassName:"",mouseEnterDelay:0,mouseLeaveDelay:.1,focusDelay:0,blurDelay:.15,popupStyle:{},destroyPopupOnHide:!1,popupAlign:{},defaultPopupVisible:!1,mask:!1,maskClosable:!0,action:[],showAction:[],hideAction:[],autoDestroy:!1},n}var AB=Fhe(BU);var dl={adjustX:1,adjustY:1},ml=[0,0],LB={left:{points:["cr","cl"],overflow:dl,offset:[-4,0],targetOffset:ml},right:{points:["cl","cr"],overflow:dl,offset:[4,0],targetOffset:ml},top:{points:["bc","tc"],overflow:dl,offset:[0,-4],targetOffset:ml},bottom:{points:["tc","bc"],overflow:dl,offset:[0,4],targetOffset:ml},topLeft:{points:["bl","tl"],overflow:dl,offset:[0,-4],targetOffset:ml},leftTop:{points:["tr","tl"],overflow:dl,offset:[-4,0],targetOffset:ml},topRight:{points:["br","tr"],overflow:dl,offset:[0,-4],targetOffset:ml},rightTop:{points:["tl","tr"],overflow:dl,offset:[4,0],targetOffset:ml},bottomRight:{points:["tr","br"],overflow:dl,offset:[0,4],targetOffset:ml},rightBottom:{points:["bl","br"],overflow:dl,offset:[4,0],targetOffset:ml},bottomLeft:{points:["tl","bl"],overflow:dl,offset:[0,4],targetOffset:ml},leftBottom:{points:["br","bl"],overflow:dl,offset:[-4,0],targetOffset:ml}};$a();var PB=Cu(y_());function tb(e){var n=e.showArrow,a=e.arrowContent,t=e.children,o=e.prefixCls,u=e.id,i=e.overlayInnerStyle,l=e.className,s=e.style;return vt("div",{className:(0,PB.default)("".concat(o,"-content"),l),style:s},n!==!1&&vt("div",{className:"".concat(o,"-arrow"),key:"arrow"},a),vt("div",{className:"".concat(o,"-inner"),id:u,role:"tooltip",style:i},typeof t=="function"?t():t))}var Ghe=function(n,a){var t=n.overlayClassName,o=n.trigger,u=o===void 0?["hover"]:o,i=n.mouseEnterDelay,l=i===void 0?0:i,s=n.mouseLeaveDelay,R=s===void 0?.1:s,d=n.overlayStyle,y=n.prefixCls,I=y===void 0?"rc-tooltip":y,b=n.children,S=n.onVisibleChange,L=n.afterVisibleChange,O=n.transitionName,$=n.animation,z=n.motion,ee=n.placement,oe=ee===void 0?"right":ee,te=n.align,ve=te===void 0?{}:te,Re=n.destroyTooltipOnHide,nn=Re===void 0?!1:Re,cn=n.defaultVisible,ce=n.getTooltipContainer,le=n.overlayInnerStyle,Ne=n.arrowContent,Ce=n.overlay,Be=n.id,Xe=n.showArrow,Sn=xv(n,["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow"]),ra=lt(null);rs(a,function(){return ra.current});var kn=Ea({},Sn);"visible"in n&&(kn.popupVisible=n.visible);var Hn=function(){return vt(tb,{showArrow:Xe,arrowContent:Ne,key:"content",prefixCls:I,id:Be,overlayInnerStyle:le},Ce)},Kn=!1,qn=!1;if(typeof nn=="boolean")Kn=nn;else if(nn&&eo(nn)==="object"){var ft=nn.keepParent;Kn=ft===!0,qn=ft===!1}return vt(AB,ho({popupClassName:t,prefixCls:I,popup:Hn,action:u,builtinPlacements:LB,popupPlacement:oe,ref:ra,popupAlign:ve,getPopupContainer:ce,onPopupVisibleChange:S,afterPopupVisibleChange:L,popupTransitionName:O,popupAnimation:$,popupMotion:z,defaultPopupVisible:cn,destroyPopupOnHide:Kn,autoDestroy:qn,mouseLeaveDelay:R,popupStyle:d,mouseEnterDelay:l},kn),b)},xB=Di(Ghe);var NB=xB;var OB=e=>ka.createElement(NB,Object.assign({},e,{overlayClassName:`cv-tooltip ${e.overlayClassName}`,getTooltipContainer:e.tooltipContainerSelector?()=>document.querySelector(e.tooltipContainerSelector)||document.body:void 0}));if(typeof window!="undefined"&&typeof global=="undefined")try{Promise.resolve().then(()=>Cu(jB())).then(e=>{let n=e.default,a=document.createElement("style");a.type="text/css",a.appendChild(document.createTextNode(n)),document.head.appendChild(a)})}catch(e){window.Sentry&&window.Sentry.captureException(e)}$a();var UB=class extends ka.Component{componentDidUpdate(n){this.props.componentDidUpdate(n.deps)}render(){return this.props.children}},kB=UB;var Ahe=St();var BB=function(e){return"ref:"+er(e)(et.value)},HB=function(e){var n=BB(e);return function(a){return Ahe(oc(n)(a))}},qB=function(e){var n=BB(e);return function(a){return _R(n)(a)}};var Lhe=is(),JB=un(tn)(Qn),WB=W(yn),Phe=nl(JR(Zi)),$B={reflectSymbol:function(){return"deps"}},xhe=HB($B),Nhe=qB($B),jhe=pn(dn);var Ohe=function(e){var n=Lhe(e);return function(){return function(){return n(kB)}}},Uhe=Ohe(We)()(),khe=function(e){var n=Oo(e);return function(a){return function(t){return function(o){return function(u){return uw(a)(function(i){return t({init:JB(Va(u(o)))(function(){return WB(o)}),update:function(l){return function(s){return JB(Va(u(s)))(function(){return WB(s)})}},view:function(l){return function(s){return Uhe({componentDidUpdate:Phe(s)(function(R){var d=n(xhe(R))(o);return d?new T(o):M.value}),deps:Nhe(o)})(i(Ee))}}})})}}}}};var zB=function(e){var n=khe(e);return function(a){return function(t){return n("UseEffectPrime")(jhe)(a)(t)}}};var Hhe=is();var VB="click";var rb="top",Pp=function(e){var n=Hhe(e);return function(){return function(){return n(OB)}}};var QB="right";var KB=e=>()=>e.preventDefault&&e.preventDefault();var SG=function(){return KB};var qhe=Sa();var CG=Z(en),FG=wt(qhe(B({reflectSymbol:function(){return"value"}})(_e)(rn))),GG=W(aa);var ob=function(e){return ke("")(CG(FG(so(e.target)))(function(n){return GG(n.value)}))},MG=function(e){return ke("")(CG(FG(so(e.target)))(function(n){return GG(n.value)}))},Gs=function(e){return ke("")(CG(FG(so(e.target)))(function(n){return GG(n.value)}))};var YB="/network/connections";var XB=15;var Jhe=Pp(We)()(),Whe=Ua(me),$he=function(){return"You\u2019ve hit the "+(ne(Ze)(XB)+`-connection limit, designed to encourage you to focus on building meaningful connections that lead to impactful opportunities. Remove an existing connection to make space for a new one that aligns with your goals. `)}(),zhe=Vo(We)("text-decoration-underline")(Mt(Y)()()("text-dark")({href:YB})("Manage my connections")),ZB=function(e){return function(n){return Jhe({placement:e,trigger:VB,overlay:Whe("")([Ke($he),zhe]),overlayStyle:ot({width:"15rem"}),overlayClassName:"t--connection-limit-tooltip"})(n)}};var eH=Z(en),xp=function(e){var n=eH(e.guestPresenter)(function(a){if(a instanceof r_)return new T(a.value0);if(a instanceof Rs)return M.value;throw new Error("Failed pattern match at Livestream.Utils (line 21, column 31 - line 23, column 40): "+[a.constructor.name])});return eH(n)(function(a){return new T({name:a.school.name,id:a.school.id})})};var Vhe=function(){function e(){}return e.value=new e,e}(),Qhe=function(){function e(){}return e.value=new e,e}(),AG=function(){function e(){}return e.value=new e,e}(),Khe=function(){function e(){}return e.value=new e,e}(),Yhe=function(){function e(){}return e.value=new e,e}(),Xhe=function(){function e(){}return e.value=new e,e}(),nH=function(e){if(e instanceof Vhe)return"account_settings_page";if(e instanceof Qhe)return"preference_survey";if(e instanceof AG)return"livestream_registration";if(e instanceof Khe)return"chancing_wizard_network_step";if(e instanceof Yhe)return"main_profile_page";if(e instanceof Xhe)return"autopilot_acceptance_page";throw new Error("Failed pattern match at Profile.PublishContext (line 15, column 13 - line 21, column 57): "+[e.constructor.name])};var aDe=wc(Rc),LG=ql(aDe),PG=Z(_a);var tDe=Vr(),aH=pe(ae);var tH=LG("profile_visibility_path")(function(e){return function(n){return PG(e({visibility:{publish_scope:Xm(n)}}))(Xt)}}),rH=function(){return LG("profile_network_settings_path")(function(e){return function(n){return function(a){return PG(e({network_settings:{publish_scope:Xm(a.publishScope),publish_context:nH(a.publishContext),automatic_accept_requests_for_school_list:a.autoAcceptForSchoolList,automatic_connection_requests_from_livestreams:a.autoRequestFromLivestreams,livestream:Fa(aH(ll(a.livestreamConference))(function(t){return{school_name:Fa(aH(xp(t))(function(o){return o.name})),title:t.title,id:t.id}}))}}))(Xt)}(tDe(n))}})},oH=LG("profile_name_path")(function(e){return function(n){return PG(e({name:n}))(Xt)}});var Ae=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),wn=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var rDe=Wl(),oDe=Hr(Y),uDe=Ht(Y),xG=$t(Y),NG=Ku(Y),Uv=Te(me),Np=Wn(Y)()(),jG=sr(zo),iDe=un(tn),OG=Xn(ga),I_=Te(We),uH=yu()(),lDe=yv(Y),cDe=vi(yt),iH=fo()(),UG=Xn(vo),sDe=VR()(),lH=Te(Y),vDe=VN(me),kG=ZN(Y),fDe=Ua(Y),_De=Pp(We)()(),pDe=$t(me),dDe=Mt(Y)()(),mDe=Qa(Y),T_=W(yn),cH=iDe(Qn),hDe=ow(),Fh=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),sH=function(){function e(){}return e.value=new e,e}(),vH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),fH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),_H=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),pH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Gh=function(){function e(){}return e.value=new e,e}(),BG=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),dH=function(e){return function(n){var a=function(R){return rDe({body:R,title:oDe("my-0")(function(){return e.stage instanceof iy?"Join the CollegeVine network":"Connect with "+e.schoolName}()),headerClass:"pb-0",onDismiss:n(new wn(Gh.value)),size:oh.value})},t=a4(e.context),o=Se([uDe("mt-3")("Review your message before you send it"),xG("mt-2")(` Because this is your first message to the counselor, we want to make sure you\u2019re ready to send. `),NG("mt-4")("Your message"),Vm(e.message),Uv("d-flex mt-4 justify-content-start")([Np("btn btn-primary btn-lg t--sem-user-connection-modal-confirm-message-"+t)({onClick:jG(function(){return n(new wn(new BG({introMessage:e.message})))(),n(new Ae(new Fh(yS.value)))()})})("Send"),Np("btn btn-lg btn-outline-primary ml-3 text-nowrap")({onClick:OG(n)(new Ae(new Fh(qm.value)))})("No, I need to edit something")])]),u=Se([Uv("text-center")([I_("")(uH("mt-4")({src:"/img/checkmate-icon.png",height:"80",width:"80"})),lDe("mt-4")("Connection request sent!"),xG("mx-md-4")(cDe(["You\u2019ve successfully demonstrated your interest to ",e.schoolName,". ","This counselor isn\u2019t part of the platform yet but we\u2019ve forwarded your message to them. ","You\u2019ll get an email notification when they respond."])),Np("btn btn-lg btn-outline-secondary mt-4")({onClick:OG(n)(new wn(Gh.value))})("Close")])]),i=Np("btn btn-outline-secondary ml-3 t--sem-user-connection-modal-close-"+t)({onClick:OG(n)(new wn(Gh.value))})("Cancel"),l=function(){var R=hS(e.message)&&function(){if(e.profile.fullName instanceof T)return!0;if(e.profile.fullName instanceof M)return!yi(e.firstName)&&!yi(e.lastName);throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 240, column 15 - line 244, column 88): "+[e.profile.fullName.constructor.name])}(),d=function(){if(e.vineBelowConnectionLimit instanceof T&&e.vineBelowConnectionLimit.value0)return!1;if(e.vineBelowConnectionLimit instanceof T&&!e.vineBelowConnectionLimit.value0)return!0;if(e.vineBelowConnectionLimit instanceof M)return!1;throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 233, column 13 - line 236, column 31): "+[e.vineBelowConnectionLimit.constructor.name])}();return Se([ya(Tt(e.profile.fullName))(Se([NG("mt-md-4")("Your preferred name"),Uv("form-row mx-1")([iH("col form-control mr-2 t--sem-user-connection-modal-first-name-"+t)({type:"text",value:e.firstName,onChange:UG(n)(function(y){return Ae.create(_H.create(Gs(y)))}),placeholder:"First name"}),iH("col form-control ml-2 t--sem-user-connection-modal-last-name-"+t)({type:"text",value:e.lastName,onChange:UG(n)(function(y){return Ae.create(pH.create(Gs(y)))}),placeholder:"Last name"})])])),NG("mt-md-4")("Your message"),sDe("form-control t--sem-user-connection-modal-text-area-"+t)({rows:7,value:e.message,onChange:UG(n)(function(y){return Ae.create(fH.create(ob(y)))}),placeholder:`Sample introductory message: Hi Jane, My name is Sam and I\u2019m a senior at Oak Ridge High School in Oak Ridge, MD. I\u2019m really excited to apply for CV University this fall, and I\u2019m hoping to study history there. Are there any upcoming virtual events I can register for? I\u2019m excited to stay in touch and learn more about your school. Thanks! `}),I_("mt-2")(Kj(e.message)),lH("mt-3 mt-md-4 small")("The ideal connection message should include:"),vDe("small")([kG("")("Your name, where you\u2019re from, and a bit about who you are"),kG("")("What you\u2019re interested in studying along with one or two insightful questions"),kG("")("That you\u2019re eager to connect with an admissions counselor and would love to stay in touch")]),Uv("d-flex mt-4 justify-content-start")([ZB(rb)(I_("")(Np("btn btn-primary btn-lg t--sem-user-connection-modal-connect-"+t)({onClick:jG(function(){return function(){if(e.profile.fullName instanceof T)return Ee;if(e.profile.fullName instanceof M)return n(new Ae(new vH({first:e.firstName,last:e.lastName})))();throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 216, column 23 - line 220, column 113): "+[e.profile.fullName.constructor.name])}(),n(new Ae(new Fh(RS.value)))()}),disabled:!R||d,style:ot({pointerEvents:function(){return d?"none":"auto"}()})})("Connect"))),i])])}(),s=Uv("mx-md-7")([I_("border border-success rounded p-4 my-4")(Uv("row align-items-center")([I_("col-12 col-md-auto text-center text-md-left")(uH("img-fluid")({src:"/img/network/publish-profile-icon.png",height:"67",width:"143"})),I_("col text-center text-md-left")(fDe("fw-bold font-weight-bold text-gray-800")("Network with verified admissions counselors on CollegeVine"))])),Uv("d-flex flex-nowrap align-items-center")([lH("mr-4")("Publish your profile to join the CollegeVine Network"),_De({placement:QB,overlay:pDe("")([Ke(` Your profile includes academics, extracurriculars, major interest, demographics and financial aid intent. By agreeing to publish, you will also be adding select preferences survey answers to `),dDe("")({href:_U})("your profile"),Ke(".")]),overlayStyle:ot({width:"15rem"})})(mDe("cursor-default text-secondary fe fe-info large")(""))]),xG("text-secondary small d-none d-md-block mt-4")("Joining the CollegeVine Network won\u2019t result in spam from colleges you don\u2019t want to hear from."),Uv("d-flex mt-4 justify-content-start justify-content-md-center")([Np("btn btn-primary t--sem-user-connection-modal-publish-profile-"+t)({onClick:jG(function(){return n(new Ae(sH.value))(),n(new Ae(new Fh(qm.value)))()})})("Publish profile"),i])]);return I_("t--network-sem-user-modal")(function(){if(e.stage instanceof iy)return a(s);if(e.stage instanceof qm)return a(l);if(e.stage instanceof RS)return a(o);if(e.stage instanceof yS)return a(u);throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 98, column 5 - line 102, column 38): "+[e.stage.constructor.name])}())}},mH=function(e){return function(n){if(n instanceof Ae){if(n.value0 instanceof Fh)return T_({context:e.context,firstName:e.firstName,lastName:e.lastName,message:e.message,profile:e.profile,schoolName:e.schoolName,vineBelowConnectionLimit:e.vineBelowConnectionLimit,stage:n.value0.value0});if(n.value0 instanceof sH)return cH(Va(tH(bi.value)))(function(){return T_({context:e.context,firstName:e.firstName,lastName:e.lastName,message:e.message,schoolName:e.schoolName,stage:e.stage,vineBelowConnectionLimit:e.vineBelowConnectionLimit,profile:{fullName:e.profile.fullName,publishScope:bi.value}})});if(n.value0 instanceof vH)return cH(Va(oH(n.value0.value0)))(function(){return T_({context:e.context,firstName:e.firstName,lastName:e.lastName,message:e.message,schoolName:e.schoolName,stage:e.stage,vineBelowConnectionLimit:e.vineBelowConnectionLimit,profile:{publishScope:e.profile.publishScope,fullName:new T(DF(n.value0.value0))}})});if(n.value0 instanceof fH)return T_({context:e.context,firstName:e.firstName,lastName:e.lastName,profile:e.profile,schoolName:e.schoolName,stage:e.stage,vineBelowConnectionLimit:e.vineBelowConnectionLimit,message:n.value0.value0});if(n.value0 instanceof _H)return T_({context:e.context,lastName:e.lastName,message:e.message,profile:e.profile,schoolName:e.schoolName,stage:e.stage,vineBelowConnectionLimit:e.vineBelowConnectionLimit,firstName:n.value0.value0});if(n.value0 instanceof pH)return T_({context:e.context,firstName:e.firstName,message:e.message,profile:e.profile,schoolName:e.schoolName,stage:e.stage,vineBelowConnectionLimit:e.vineBelowConnectionLimit,lastName:n.value0.value0});throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 81, column 31 - line 91, column 61): "+[n.value0.constructor.name])}if(n instanceof wn)return T_(e);throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 80, column 1 - line 80, column 55): "+[e.constructor.name,n.constructor.name])}},DDe=function(e){var n=EU(e);return n?qm.value:iy.value},hH=function(e){return{firstName:"",lastName:"",message:"",profile:hDe(e.profile),stage:DDe(e.profile),schoolName:e.schoolName,context:e.context,vineBelowConnectionLimit:e.vineBelowConnectionLimit}};var ub=we(Vt(Pt)),gDe=Vr(),HG=Te(We),RDe=yu()(),qG=Ua(Y),yDe=Qa(Y),wDe=Pv(),bDe=tF(tn)(),EDe=Bn(Ve),IDe=or(We)()(),TDe=Wn(me)()(),SDe=sr(gv),CDe=SG(),FDe=Ja(tr),jp=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Mh=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),JG=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),WG=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),DH=function(){function e(){}return e.value=new e,e}(),GDe=function(){function e(){}return e.value=new e,e}(),MDe={eq:function(e){return function(n){return e instanceof jp&&n instanceof jp?e.value0.url===n.value0.url:e instanceof Mh&&n instanceof Mh?ub(e.value0.backgroundColorClass)(n.value0.backgroundColorClass)&&e.value0.initials===n.value0.initials&&ub(e.value0.textColorClass)(n.value0.textColorClass):e instanceof JG&&n instanceof JG?ub(e.value0.backgroundColorClass)(n.value0.backgroundColorClass)&&e.value0.iconClass===n.value0.iconClass:e instanceof WG&&n instanceof WG?ub(e.value0.backgroundColorClass)(n.value0.backgroundColorClass)&&e.value0.name===n.value0.name:!1}}},ADe=zB(MDe),gH=function(){return function(e){var n=gDe(e),a=function(){var o=Ka(n.shape)(DH.value);if(o instanceof DH)return"rounded-circle";if(o instanceof GDe)return"rounded";throw new Error("Failed pattern match at Dashkit.Avatar (line 122, column 9 - line 124, column 37): "+[o.constructor.name])}(),t=function(o){return HG("avatar "+(RU(Ka(n.size)(pw.value))+(" "+Ka(n.className)(""))))(function(){if(o instanceof jp)return RDe("avatar-img img-fluid "+(a+(" "+Ka(n.borderClassName)(""))))({src:o.value0.url});if(o instanceof Mh)return qG("avatar-title font-weight-bold fw-bold "+(a+(" "+(ke("")(o.value0.backgroundColorClass)+(" "+(ke("")(o.value0.textColorClass)+(" "+Ka(n.borderClassName)(""))))))))(o.value0.initials);if(o instanceof JG)return HG("avatar-title "+(a+(" "+(ke("")(o.value0.backgroundColorClass)+(" "+Ka(n.borderClassName)(""))))))(yDe(o.value0.iconClass)(""));if(o instanceof WG)return HG("avatar-title "+(a+(" "+(ke("")(o.value0.backgroundColorClass)+(" "+Ka(n.borderClassName)(""))))))(qG("material-symbol")(o.value0.name));throw new Error("Failed pattern match at Dashkit.Avatar (line 83, column 11 - line 119, column 46): "+[o.constructor.name])}())};return iw(wDe(Ss(n.source))(function(o){return bDe(ADe(n.source)(function(u){return EDe(o.value1(u))}))(function(){return f_(Se([t(o.value0),function(){return o.value0 instanceof jp?da(ll(n.hideAvatar))(function(u){return IDe("hq-only-menu-item")({style:ot({marginTop:"-50px",marginLeft:"200px"})})(TDe("btn btn-sm btn-warning mb-4 t--hide-avatar")({onClick:SDe(function(i){return function(){return CDe(i)(),FDe(o.value1)(u)()}})})([qG("badge badge-info bg-info text-dark mr-2")("HQ"),Ke("Hide")]))}):$n}()]))})}))}};var LDe=gH();var RH=function(e){return function(n){return LDe({source:function(){if(e.avatarUrl instanceof T)return new jp({url:e.avatarUrl.value0});if(e.avatarUrl instanceof M)return new Mh({initials:e.initials,backgroundColorClass:M.value,textColorClass:M.value});throw new Error("Failed pattern match at Sem.Utils (line 18, column 15 - line 26, column 14): "+[e.avatarUrl.constructor.name])}(),size:n})}};var $G=k(ae),PDe=an(w2(of));var yH=function(e){var n=function(a){return ke("")($G(ju)(om(0)(a)))};return bv(function(){var a=Qo(" ")(e);return a.length===2?n(a[0])+n(a[1]):a.length===1?n(a[0]):a.length===0?"":ke("?")(PDe($G(n)(E0(a)))($G(n)(Kd(a))))}())},wH=function(e){return e.firstName+(" "+e.lastName)};var zG=Hr(Y),xDe=Mt(Y)()(),NDe=Mt(me)()(),bH=Qa(Y),jDe=Wn(me)()(),ODe=nl(Dv(Zi)),UDe=pe(ae),kDe=Z(en),VG=Te(Y),ib=Te(me),EH=Te(We),BDe=Nm(Y),IH=ls()(),HDe=Ku(Y),qDe=$t(Y),Op=W(yn),TH=un(tn),JDe=TH(Qn),WDe=Ma(Ve),$De=TH(_a),zDe=W(ca),VDe=it(wr(Ga)),SH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Ah=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),CH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),FH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),GH=function(){var e=function(a){return function(t){return function(o){var u=zG("text-primary")(t.semUser.firstName+(" from "+(t.semUser.school.name+" sent you a connection request!"))),i=zG("text-primary")("Reach out to "+(t.semUser.firstName+" to ask a question or introduce yourself!")),l=[u,xDe("btn btn-primary d-flex align-items-center w-50 justify-content-center t--livestream-details-view-pending-invitation-from-sem-user")({href:IF(new wp(t.semUser.id))})("View Message")],s=wH(t.semUser),R=yH(s),d=zG("text-primary")("Reach out to "+(t.semUser.firstName+" to ask a question!")),y=[d,NDe("btn btn-primary d-flex align-items-center w-50 justify-content-center t--livestream-details-messages-link")({href:IF(new wp(t.semUser.id))})([bH("fe fe-message-square mr-2 large")(""),Ke("Send a message to "+t.semUser.firstName)])],I=function(L){return jDe("btn btn-primary d-flex align-items-center justify-content-center t--livestream-details-connect-with-sem-user")({onClick:ODe(o)(UDe(kDe(a.currentUser)(function(O){return O.profile}))(CH.create)),disabled:L.isDisabled})([bH("fe fe-message-square mr-2 large")(""),Ke("Connect with "+t.semUser.firstName)])},b=[i,I({isDisabled:!1})],S=[i,I({isDisabled:!0}),VG("mt-4 text-secondary small")("Invitation pending")];return ib("t--livestream-details-guest-presenter-sem-user mb-4")([da(a.currentUser)(function(L){return ya(L.hasAccessToNetwork&&t.semUser.school.allowedToContact)(EH("card")(ib("card-body")(function(){if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof Ev)return y;if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof jl&&t.semUser.connection.value0.initiator instanceof ds||t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof ms&&t.semUser.connection.value0.initiator instanceof ds)return S;if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof jl&&t.semUser.connection.value0.initiator instanceof ps)return l;if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof ms&&t.semUser.connection.value0.initiator instanceof ps||t.semUser.connection instanceof M)return b;throw new Error("Failed pattern match at Livestream.GuestPresenter.SemUser (line 97, column 17 - line 103, column 53): "+[t.semUser.connection.constructor.name])}())))}),BDe("text-uppercase text-secondary")("Your guest presenter"),ib("row align-items-center mt-4")([EH("col-auto")(RH(IH(t.semUser)({initials:R}))(_w.value)),ib("col")([HDe("mb-1")(s),VG("text-secondary small")(t.semUser.school.name),VG("text-secondary small")(t.semUser.title)]),da(t.semUser.bio)(function(L){return qDe("mt-4 mb-2 ml-2")(L)})]),da(t.modal)(function(L){return dH(L.value0)(function(O){return o(Ah.create(O))})})])}}},n=function(a){return function(t){return function(o){if(o instanceof Ah&&o.value0 instanceof wn){if(o.value0.value0 instanceof Gh)return Op({currentUser:t.currentUser,semUser:t.semUser,vineBelowConnectionLimit:t.vineBelowConnectionLimit,modal:M.value});if(o.value0.value0 instanceof BG)return JDe(WDe($De(FU(t.semUser.school.id)(t.semUser.id)({introMessage:o.value0.value0.value0.introMessage}))(function(){return zDe(new FH({introMessage:o.value0.value0.value0.introMessage}))})))(function(){return Op(t)});throw new Error("Failed pattern match at Livestream.GuestPresenter.SemUser (line 53, column 55 - line 59, column 19): "+[o.value0.value0.constructor.name])}if(t.modal instanceof T&&o instanceof Ah&&o.value0 instanceof Ae)return VDe(Ah.create)(function(u){return{currentUser:t.currentUser,semUser:t.semUser,vineBelowConnectionLimit:t.vineBelowConnectionLimit,modal:new T(new SH(u))}})(mH(t.modal.value0.value0)(new Ae(o.value0.value0)));if(o instanceof Ah&&o.value0 instanceof Ae)return Op(t);if(o instanceof CH)return Op({currentUser:t.currentUser,semUser:t.semUser,vineBelowConnectionLimit:t.vineBelowConnectionLimit,modal:new T(new SH(hH({schoolName:a.semUser.school.name,context:gS.value,profile:o.value0,vineBelowConnectionLimit:a.vineBelowConnectionLimit})))});if(o instanceof FH)return Op({currentUser:t.currentUser,modal:t.modal,vineBelowConnectionLimit:t.vineBelowConnectionLimit,semUser:{avatarUrl:t.semUser.avatarUrl,bio:t.semUser.bio,firstName:t.semUser.firstName,id:t.semUser.id,lastName:t.semUser.lastName,school:t.semUser.school,title:t.semUser.title,unreadMessageCountFromSemUser:t.semUser.unreadMessageCountFromSemUser,connection:new T({initiator:ds.value,introMessage:o.value0.introMessage,status:jl.value})}});throw new Error("Failed pattern match at Livestream.GuestPresenter.SemUser (line 52, column 5 - line 52, column 67): "+[a.constructor.name,t.constructor.name,o.constructor.name])}}};return hv("Livestream Guest Presenter SEM user")(function(a){return{init:Op(IH(a)({modal:M.value})),view:e(a),update:n(a)}})}();var lb=function(){function e(){}return e.value=new e,e}(),MH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),AH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),LH=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}();var QDe=St(),KDe=an(GS),QG=function(e){var n=function(u){return QDe(ff(u))},a=n(gs("[^a-z0-9\\-_]+")(KDe(up)(fy))),t=n(gs("^-|-$")(up)),o=n(gs("-{2,}")(up));return Wm(t)("")(Wm(o)("-")(Wm(a)("-")(Vf(Um(e)))))};var ZDe=k(ze),ege=pe(ze),Lh=ne(Ze),KG=ba(),nge=an(Rt),Ph=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),age=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),tge=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),rge=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),xh=function(){function e(){}return e.value=new e,e}(),oge=function(){function e(){}return e.value=new e,e}();var PH=function(e){var n=function(t){return t.key+("="+t.value)},a=function(t){return t.length===0?"":"?"+vr("&")(t)};return a(ZDe(n)(e))};var xH=function(e){return ege(e)(function(n){if(n instanceof Ph)return{key:"utm_cv_source",value:n.value0};if(n instanceof age)return{key:"utm_source",value:n.value0};if(n instanceof tge)return{key:"utm_campaign",value:n.value0};if(n instanceof rge)return{key:"utm_content",value:n.value0};throw new Error("Failed pattern match at ServiceProviders.Retail.Urls (line 198, column 3 - line 206, column 36): "+[n.constructor.name])})};var cb=function(e){return function(n){return function(a){var t=function(){if(e instanceof xh)return"i";if(e instanceof oge)return"o";throw new Error("Failed pattern match at ServiceProviders.Retail.Urls (line 114, column 12 - line 116, column 24): "+[e.constructor.name])}();return"/experts/profile/"+(t+("/"+(Lh(n.id)+("-"+(QG(n.name)+PH(xH(a)))))))}}};var NH=function(e){return function(n){return function(a){var t=function(){if(n instanceof lb)return[];if(n instanceof MH)return[{key:"theme",value:Lh(KG(n.value0))}];if(n instanceof AH)return[{key:"package",value:Lh(KG(n.value0))}];if(n instanceof LH)return[{key:"packageOffer",value:Lh(KG(n.value0))}];throw new Error("Failed pattern match at ServiceProviders.Retail.Urls (line 148, column 5 - line 156, column 71): "+[n.constructor.name])}(),o=nge(t)(xH(a));return"/experts/advising/book/"+(Lh(e.id)+("-"+(QG(e.name)+PH(o))))}}};var uge=ne(Ze),ige=ba(),lge=Ua(me),YG=Qa(Y),Ms=Te(me),jH=Nm(Y),cge=k(ze),sge=Mt(We)()(),sb=Te(We),vge=al()(),fge=Hr(Y),OH=Mt(me)()(),vb=Mt(Y)()(),UH=function(e){return function(n){var a=new Ph("sp-guest-presenter-card-from-conference-"+uge(ige(e))),t=function(d){return lge("badge badge-light bg-light text-dark mr-3")([YG("fe fe-tag mr-2")(""),Ke(d.name)])},o=cb(xh.value)(n.entity)([a]),u=function(d){return function(y){return Ms("mb-3")([jH("text-secondary text-uppercase mb-2")(d),y])}},i=Ms("mt-4")([da(fe(n.entity.shortEducation))(function(d){return u("Education")(Ke(d))}),u("Bio")(Vm(n.entity.bio)),d8(si(n.entity.tags))(u("Specialties")(Se(cge(t)(n.entity.tags))))]),l=Ms("row")([da(fe(n.entity.imageUrl))(function(d){return sge("btn btn-link text-body p-0 m-0")({href:o,target:"_blank"})(sb("col-auto my-auto")(sb("avatar avatar-md")(vge("avatar-img rounded-circle")({src:d}))))}),Ms("col-auto my-auto")([jH("text-uppercase text-secondary mb-2")("Advisor"),fge("m-0")(n.entity.name)]),Ms("col text-center text-md-right my-auto")([sb("d-none d-md-block")(OH("btn btn-sm btn-outline-primary t--open-message-modal")({href:o,target:"_blank"})([YG("fe fe-message-square mr-2")(""),Ke("Message")])),sb("d-block d-md-none")(OH("btn btn-sm btn-outline-primary t--open-message-modal")({href:o,target:"_blank"})([YG("fe fe-message-square mr-2")(""),Ke("Message")]))])]),s=NH(n.entity)(lb.value)([a]),R=da(n.advisingConfig)(function(d){return Ms("mt-4")([Ms("d-none d-md-block")([da(d.freeConsultationDurationMinutes)(function(y){return vb("btn btn-primary px-3 mr-3")({href:o,target:"_blank"})("Book a free consultation")}),vb("btn btn-outline-primary px-3 mr-3")({href:s,target:"_blank"})("Book a session")]),Ms("d-block d-md-none text-center")([da(d.freeConsultationDurationMinutes)(function(y){return vb("btn btn-primary mr-3")({href:o,target:"_blank"})("Book a free consultation")}),vb("btn btn-outline-primary")({href:s,target:"_blank"})("Book a session")])])});return Ms("mt-4 mt-md-0 t--service-provider-guest-presenter")([l,i,R])}};var Nh=function(e){return function(n){return function(a){return function(t){if(n instanceof r_)return GH({semUser:n.value0,currentUser:a,vineBelowConnectionLimit:t.vineBelowConnectionLimit});if(n instanceof Rs)return UH(e)(n.value0);throw new Error("Failed pattern match at Livestream.GuestPresenter.GuestPresenter (line 16, column 1 - line 16, column 78): "+[e.constructor.name,n.constructor.name,a.constructor.name,t.constructor.name])}}}};var kH="/experts/essay-review";var _ge=Mt(me)()(),pge=Qa(Y),Up=Te(Y),wu=Te(We),Xo=Te(me),BH=Hr(Y),HH=al()(),qH=pe(ze),dge=Ua(Y),JH=pe(ae),mge=$t(me),WH=Vo(Y),XG=Mt(Y)()(),hge=ne(Ze),jh=k(ae),Dge=KR(me)()(),gge=ne(Zu),Oh=function(e){var n=function(a){return function(t){return _ge("mr-3")({href:t,target:"_blank"})([Ke(a),pge("fe fe-external-link ml-1")("")])}};return Se([Up("text-uppercase text-muted small mb-2")("School information"),wu("card shadow-none")(Xo("card-body")([BH("mb-1")(e.name),Up("text-uppercase small text-secondary")(e.cityState),Xo("mt-3 d-none d-md-block")([n("Stats")(fw(d_.value)(e.slug)),n("Cost")(fw(ih.value)(e.slug)),n("Map")(fw(d_.value)(e.slug))]),Xo("mt-3 d-md-none")([n("Stats")(mF(d_.value)(e.slug)),n("Cost")(mF(ih.value)(e.slug))])]))])},Rge=function(e){var n=function(i){return HH("avatar-img rounded-circle")({src:i})},a=vr(" ")(qH(Qo(" ")(e.fullName))(xl(1))),t=dge("avatar-title rounded-circle text-uppercase")(a),o=function(i){return ke("")(JH(i)(function(l){return" '"+l}))},u=function(i){return function(l){return mge("")([WH("")(i+": "),Ke(l)])}};return Se([Up("text-uppercase text-muted small mb-2")("Your host"),Xo("row align-items-center mb-4 pr-4")([wu("col-auto")(wu("avatar")(bn(t)(n)(e.pictureUrl))),wu("col")(Xo("row align-items-center justify-content-between")([Up("col-12 col-md-auto x-large")(e.fullName),wu("col-12 col-md-auto")(da(e.allStreamsUrl)(function(i){return XG("t--host-streams")({href:i})("See all "+(hge(e.totalStreams)+(" streams by "+e.firstName)))}))]))]),Se(Jo([jh(u("Undergrad College"))(JH(e.undergrad.college)(function(i){return i+o(e.undergrad.year)})),jh(u("Major"))(e.undergrad.major),jh(u("Graduate College"))(e.gradCollege),jh(u("Work Experience"))(e.workExperience),jh(u("My Admissions Story"))(e.admissionsStory)]))])},yge=Xo("rounded bg-tan mb-3 overflow-hidden")([Xo("row")([wu("col-12 col-md")(Xo("m-4")([Ku(Y)("")("Get your essay reviewed by an expert"),$t(Y)("small")(` CollegeVine\u2019s network of admissions experts have helped students write essays that stand out to admissions officers. Work with an expert today to craft the perfect essay. `),XG("btn btn-dark px-4")({href:v_({key:"utm_cv_source",value:"essay-livestream-cta"})(kH)})("Submit my essay for review")])),wu("d-none d-md-block col-12 col-md-auto")(yu()()("h-100")({src:"/img/livestreams/mkt-239-livestreams-advisors-essays-cta.svg"}))])]),wge=function(e){return Se([Up("text-uppercase text-muted small mb-2")("Description"),Xo("")([wu("col-6 col-md-4 float-right")(HH("img-fluid rounded")({src:e.imageUrl})),Xo("")(qH(Qo(` `)(e.description))(function(n){return Dge("")({dangerouslySetInnerHTML:{__html:n}})([])}))])])},bge=function(e){var n=e.paths.collegeFair+("?utm_cv_source=banner-livestream-watch-"+gge(e.conference.id));return wu("card mt-3")(wu("card-body py-3")(Xo("row align-items-center")([wu("col-12 col-md-auto mb-3 mb-md-0")(Up("bg-warning rounded px-3 py-1 small mt-2 mt-md-0")("SPECIAL EVENT")),Xo("col-12 col-md mb-3 mb-md-0")([Ke("This livestream was part of the "),WH("")("\u{1F3AA} Student panel college fair"),Ke(". Recordings for all 100+ Q&A panels are available.")]),wu("col-12 col-md-auto")(XG("btn btn-sm btn-outline-primary px-3")({href:n})("See all recordings"))])))},fb=function(e){var n=function(){if(e.conference.presenter instanceof T&&e.conference.guestPresenter instanceof T||e.conference.presenter instanceof T&&e.conference.guestPresenter instanceof M||e.conference.presenter instanceof M&&e.conference.guestPresenter instanceof T)return"col-12 col-md-6";if(e.conference.presenter instanceof M&&e.conference.guestPresenter instanceof M)return"col-12";throw new Error("Failed pattern match at Livestream.AboutLivestream (line 68, column 16 - line 72, column 35): "+[e.conference.presenter.constructor.name,e.conference.guestPresenter.constructor.name])}();return Se([ya(e.conference.collegeFair)(bge(e)),function(){return e.featureFlags.mkt293LivestreamsEssayReviewCtaForAdvisorStreams&&e.conference.guestPresenter instanceof T&&e.conference.guestPresenter.value0 instanceof Rs?yge:$n}(),wu("card")(Xo("card-body")([BH("text-center mb-4")("About this livestream"),Xo("row")([Xo(n)([da(e.conference.school)(function(a){return wu("d-md-none")(Oh(a))}),wge(e.conference)]),Xo(n)([da(e.conference.guestPresenter)(function(a){return Nh(e.conference.id)(a)(e.user)({vineBelowConnectionLimit:e.vineBelowConnectionLimit})}),da(e.conference.school)(function(a){return wu("d-none d-md-block")(Oh(a))}),da(e.conference.presenter)(Rge)])])]))])};var $H=un(tn),Ege=$H(Qn),Ige=Ma(Ve),Tge=xt(Nr),zH=W(ca),_b=W(yn),Sge=$H(_a),pb=W(aa),VH=Te(Y),db=Ku(Y),mb=Z0(me),hb=K0(me),kv=zf(me),hl=Y0(Y),Db=X0(me),gb=pe(ze),Bv=cs(Y),Rb=cs(We),yb=Wn(Y)()(),wb=Xn(ga),Cge=Hi(Ya),Fge=k(ze),Gge=an($s($s(Tg))),Mge=Hi(Vu),Age=Hi(o7),Lge=ne(Zu),Pge=Ht(Y),xge=Te(me),bb=function(){function e(){}return e.value=new e,e}(),QH=function(){function e(){}return e.value=new e,e}(),Uh=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),KH=function(){function e(){}return e.value=new e,e}(),YH=function(){function e(){}return e.value=new e,e}(),XH=function(e){return function(n){return function(a){var t=function(u){return Ege(Ige(Tge(u)(function(i){return zH(YH.value)})))(function(){return _b({ctas:n.ctas,stage:QH.value,error:M.value})})},o=function(u){if(u instanceof sl)return LO({fromConference:e.conference.id,cta:u.value0.conferenceId});if(u instanceof vl)return MO({fromConference:e.conference.id,ctaId:u.value0.id});if(u instanceof fl)return AO({fromConference:e.conference.id,ctaId:u.value0.id});if(u instanceof _l)return GO({fromConference:e.conference.id,ctaId:u.value0.id});throw new Error("Failed pattern match at Livestream.Ctas.LaunchCtas (line 228, column 15 - line 236, column 83): "+[u.constructor.name])};if(a instanceof Uh)return t(Sge(o(a.value0))(function(){return zH(KH.value)}));if(a instanceof KH)return _b({ctas:n.ctas,error:n.error,stage:bb.value});if(a instanceof YH)return _b({ctas:n.ctas,stage:bb.value,error:new T("That didn't work for some reason, try again")});throw new Error("Failed pattern match at Livestream.Ctas.LaunchCtas (line 211, column 24 - line 221, column 92): "+[a.constructor.name])}}},ZH=function(e){return _b({stage:bb.value,error:M.value,ctas:e})},Nge=function(){return Po(Wo(fn)([Ol.value,new ht(" "),Ul.value,new ht(", "),Bl.value,new ht(":"),wi.value,new ht(" "),Hl.value]))}(),eq=function(e){return function(n){if(e.ctas.length===0)return $n;var a=function(L){return L instanceof _l?pb(L.value0):M.value},t=function(L){return L instanceof vl?pb(L.value0):M.value},o=function(L){return L instanceof fl?pb(L.value0):M.value},u=function(L){return L instanceof sl?pb(L.value0):M.value},i=function(){if(e.stage instanceof bb)return $n;if(e.stage instanceof QH)return VH("position-absolute-fullsize d-flex align-items-center justify-content-center bg-semi-transparent-white")("Opening...");throw new Error("Failed pattern match at Livestream.Ctas.LaunchCtas (line 190, column 24 - line 195, column 23): "+[e.stage.constructor.name])}(),l=function(L){return L.length===0?$n:Se([db("")("Referrals"),mb("table table-sm mb-0")([hb("")([kv("")([hl("")("Title"),hl("")("Actions")])]),Db("")(gb(L)(function(O){return kv("t--cta t--cta-referral")([Bv("pt-3")(O.title),Rb("text-nowrap")(yb("btn btn-white btn-sm px-4 t--open")({onClick:wb(n)(new Uh(new _l(O)))})("Launch CTA"))])}))])])},s=function(L){return L.length===0?$n:Se([db("")("General"),mb("table table-sm mb-0")([hb("")([kv("")([hl("")("Title"),hl("")("URL"),hl("")("Link Text"),hl("")("Actions")])]),Db("")(gb(Rf(Cge(function(O){return O.title}))(L))(function(O){return kv("t--cta t--cta-general")([Bv("pt-3")(function(){var $=Ct(O.autoDisplayMinutesFromStart);return $?"\u23F0 ":""}()+O.title),Bv("pt-3")(O.url),Bv("pt-3")(O.buttonText),Rb("text-nowrap")(yb("btn btn-white btn-sm px-4 t--open")({onClick:wb(n)(new Uh(new vl(O)))})("Launch CTA"))])}))])])},R=function(L){return L.length===0?$n:Se([db("")("Featured Service Providers"),mb("table table-sm mb-0")([hb("")([kv("")([hl("")("Advisors"),hl("")("Link Text"),hl("")("Actions")])]),Db("")(gb(L)(function(O){return kv("t--cta t--cta-featured-sp")([Bv("pt-3")(vr(", ")(Fge(function($){return $.name})(O.providers))),Bv("pt-3")(O.linkText),Rb("text-nowrap")(yb("btn btn-white btn-sm px-4 t--open")({onClick:wb(n)(new Uh(new fl(O)))})("Launch CTA"))])}))])])},d=function(L){return L.length===0?$n:Se([db("")("Upcoming events"),mb("table table-sm mb-0")([hb("")([kv("")([hl("")("Livestream"),hl("")("Date & Time"),hl("")("Actions")])]),Db("")(gb(Rf(Gge(Mge(function(O){return O.startTime}))(Age(function(O){return O.conferenceId})))(L))(function(O){return kv("t--cta t--cta-stream-"+Lge(O.conferenceId))([Bv("pt-3")(O.title),Bv("pt-3")(Nge(O.startTime)+(" "+a_)),Rb("text-nowrap")(yb("btn btn-white btn-sm px-4 t--open")({onClick:wb(n)(new Uh(new sl(O)))})("Launch CTA"))])}))])])},y=zr(a)(e.ctas),I=zr(t)(e.ctas),b=zr(o)(e.ctas),S=zr(u)(e.ctas);return Se([Pge("")("Calls to action"),xge("t--ctas position-relative")([da(e.error)(function(L){return VH("alert alert-danger")(L)}),d(S),s(I),R(b),l(y),i])])}};var nq=ql(wc(Rc)),aq=Z(_a),jge=AC(_e),kp=function(){function e(){}return e.value=new e,e}(),kh=function(){function e(){}return e.value=new e,e}(),Bh=function(){function e(){}return e.value=new e,e}(),tq={eq:function(e){return function(n){return e instanceof kp&&n instanceof kp||e instanceof kh&&n instanceof kh||e instanceof Bh&&n instanceof Bh}}},rq=nq("profile_validate_username_path")(function(e){return function(n){return aq(e({username:n}))(yc(function(a){return jge("username validation result")(a)(function(t){return t==="available"?new T(kp.value):t==="taken"?new T(kh.value):t==="invalid"?new T(Bh.value):M.value})}))}}),oq=nq("profile_set_username_path")(function(e){return function(n){return aq(e({username:n}))(Xt)}});var Oge=we(Vt(Cl()(ki(ki(Sl)()({reflectSymbol:function(){return"username"}})(Pt))()({reflectSymbol:function(){return"result"}})(tq)))),ZG=Te(me),uq=Te(We),Uge=$t(Y),kge=yu()(),Hh=Te(Y),Bge=fo()(),Hge=Xn(vo),iq=Wn(Y)()(),qge=Xn(ga),Jge=nl(Dv(Zi)),eM=un(tn)(Qn),Wge=lr(yn),nM=Ma(Ve),$ge=ui(Ga),S_=W(yn),zge=k(Ga),Vge=Z(_a),Qge=Sf(Nr),lq=W(ca),cq=function(){function e(){}return e.value=new e,e}(),sq=function(){function e(){}return e.value=new e,e}(),vq=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),fq=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),_q=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),pq=function(){function e(){}return e.value=new e,e}(),dq=function(){function e(){}return e.value=new e,e}(),aM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),tM=function(){function e(){}return e.value=new e,e}(),mq=function(e){return function(n){var a=e.username!==""&&Tt(e.updating)&&Oge(e.validated)(new T({username:e.username,result:kp.value}));return Se([ZG("row")([uq("col col-md-6")(Uge("")("This username will keep your identity private in CollegeVine communities, livestreams, and on peer essay review leaderboards.")),uq("col-6 d-none d-md-block")(kge("img-fluid")({src:"/img/illustrations/clipboards.svg"}))]),Hh("")("Your username:"),ZG("input-group")([Bge("form-control")({autoFocus:!0,type:"text",value:e.username,onChange:Hge(n)(function(t){return Ae.create(vq.create(Gs(t)))})})]),ZG("d-flex mt-3")([iq("btn btn-light mr-3")({onClick:qge(n)(new wn(tM.value))})("Cancel"),iq("btn btn-primary t--submit-username")({type:"button",disabled:!a,onClick:Jge(n)(function(){return a?new T(new Ae(pq.value)):M.value}())})("Save")]),da(e.validated)(function(t){if(t.result instanceof kp)return $n;if(t.result instanceof kh)return Hh("small text-danger")("Sorry, this username is already taken");if(t.result instanceof Bh)return Hh("small text-danger")("Usernames can only contain letters, numbers, or these symbols: _ - . with no spaces");throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 80, column 37 - line 86, column 121): "+[t.result.constructor.name])}),da(e.updating)(function(t){if(t instanceof cq)return Hh("text-success")("Updating your username...");if(t instanceof sq)return Hh("small text-danger")("There was an error saving your username. Please try again.");throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 87, column 30 - line 91, column 95): "+[t.constructor.name])})])}},hq=function(e){return function(n){if(n instanceof Ae){if(n.value0 instanceof vq)return eM(Wge(n.value0.value0!=="")(nM($ge(Kt(100))(new Ae(new fq(n.value0.value0))))))(function(){return S_({updating:e.updating,validated:e.validated,username:n.value0.value0})});if(n.value0 instanceof fq){if(n.value0.value0===e.username)return eM(nM(zge(function(){var a=_q.create(n.value0.value0);return function(t){return Ae.create(a(t))}}())(rq(n.value0.value0))))(function(){return S_({username:e.username,validated:M.value,updating:M.value})});if($e)return S_(e)}if(n.value0 instanceof _q)return S_({updating:e.updating,username:e.username,validated:new T({username:n.value0.value0,result:n.value0.value1})});if(n.value0 instanceof pq)return eM(nM(Vge(Qge(oq(e.username)))(function(a){if(a instanceof Le)return lq(new wn(new aM(e.username)));if(a instanceof Me)return lq(new Ae(dq.value));throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 119, column 7 - line 123, column 48): "+[a.constructor.name])})))(function(){return S_({username:e.username,validated:M.value,updating:new T(cq.value)})});if(n.value0 instanceof dq)return S_({username:e.username,validated:e.validated,updating:new T(sq.value)});throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 100, column 31 - line 127, column 48): "+[n.value0.constructor.name])}if(n instanceof wn)return S_(e);throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 99, column 1 - line 99, column 55): "+[e.constructor.name,n.constructor.name])}},Dq=function(e){return{username:e,validated:M.value,updating:M.value}};var Kge=Vr(),Yge=Pp(We)()(),Xge=Ua(me),Zge=Qa(Y),eRe=function(e){var n=Am(e);return function(){return function(a){return function(t){var o=Kge(a);return Yge({placement:rb,overlay:Se(n(t)),overlayStyle:Ka(o.overlayStyle)(ot({width:"15rem"}))})(Xge("d-inline-flex align-items-center text-secondary "+o.className)([Zge("d-inline-block fe fe-help-circle "+function(){var u=yi(o.anchorText);return u?"":"mr-2"}())(""),Ke(o.anchorText)]))}}}},Eb=function(e){var n=eRe(e)();return function(a){return n({className:a,anchorText:""})}};var rM=function(e){return e};var nRe=function(e){return e},gq=function(e){var n=Qe(e),a=nRe(e.Eq0());return{compare:function(t){return function(o){return l2(n(t)(o))}},Eq0:function(){return a}}};var Rq=xn(Pn),qh=Ln(Rq)(Fn(Cn)),yq=Mn(Gn),Jh=An(yq),wq=On(jn),Wh=Nn(wq),aRe=k(ae),Bp=function(){function e(){}return e.value=new e,e}(),Hp=function(){function e(){}return e.value=new e,e}(),qp=function(){function e(){}return e.value=new e,e}(),Jp=function(){function e(){}return e.value=new e,e}(),Wp=function(){function e(){}return e.value=new e,e}(),C_=function(){function e(){}return e.value=new e,e}(),tRe={to:function(e){if(e instanceof ge)return Bp.value;if(e instanceof ie&&e.value0 instanceof ge)return Hp.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ge)return qp.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ie&&e.value0.value0.value0 instanceof ge)return Jp.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ie&&e.value0.value0.value0 instanceof ie&&e.value0.value0.value0.value0 instanceof ge)return Wp.value;if(e instanceof ie&&e.value0 instanceof ie&&e.value0.value0 instanceof ie&&e.value0.value0.value0 instanceof ie&&e.value0.value0.value0.value0 instanceof ie)return C_.value;throw new Error("Failed pattern match at Common.Persona (line 25, column 1 - line 25, column 34): "+[e.constructor.name])},from:function(e){if(e instanceof Bp)return new ge(xe.value);if(e instanceof Hp)return new ie(new ge(xe.value));if(e instanceof qp)return new ie(new ie(new ge(xe.value)));if(e instanceof Jp)return new ie(new ie(new ie(new ge(xe.value))));if(e instanceof Wp)return new ie(new ie(new ie(new ie(new ge(xe.value)))));if(e instanceof C_)return new ie(new ie(new ie(new ie(new ie(xe.value)))));throw new Error("Failed pattern match at Common.Persona (line 25, column 1 - line 25, column 34): "+[e.constructor.name])}},bq=Un(tRe)(qh(qh(qh(qh(qh(Rq)(yq))(Jh))(Jh))(Jh))(Jh))(Wh(Wh(Wh(Wh(Wh(wq))))))(Jh);var rRe={eq:function(e){return function(n){return e instanceof Bp&&n instanceof Bp||e instanceof Hp&&n instanceof Hp||e instanceof qp&&n instanceof qp||e instanceof Jp&&n instanceof Jp||e instanceof Wp&&n instanceof Wp||e instanceof C_&&n instanceof C_}}},Ib=function(e){if(e instanceof Bp)return"student";if(e instanceof Hp)return"transfer_student";if(e instanceof qp)return"counselor";if(e instanceof Jp)return"iec";if(e instanceof Wp)return"parent";if(e instanceof C_)return"sem_user";throw new Error("Failed pattern match at Common.Persona (line 43, column 13 - line 49, column 24): "+[e.constructor.name])},Eq=function(){var e=In(Ib)(bq);return ta(Ye)({parse:function(n){return n==="unknown"?new T(M.value):aRe(T.create)(e(n))},default:M.value,diagnosticName:"User Persona"})}(),Iq=function(e){if(e instanceof Bp)return"Student";if(e instanceof Hp)return"Transfer Student";if(e instanceof qp)return"High School Counselor";if(e instanceof Jp)return"Independent Educational Counselor (IEC)";if(e instanceof Wp)return"Parent";if(e instanceof C_)return"SEM User";throw new Error("Failed pattern match at Common.Persona (line 33, column 11 - line 39, column 24): "+[e.constructor.name])},Tq=function(){return bf(rRe)(C_.value)(bq)}();function Sq(){typeof fbq!="undefined"&&fbq("trackCustom","LivestreamRegistrationComplete")}var oRe=W(rt),uRe=ts($c(!1));var Tb=function(e){if(ts(ec(uRe)))return oRe(Ee);if($e)return Sq;throw new Error("Failed pattern match at Livestream.Upcoming.Register.Tracking (line 18, column 1 - line 18, column 53): "+[e.constructor.name])};var oM=k(Dr);var uM=Z(Mu),iRe=W(qc),lRe=To(N2);var Cq=function(e){return e},Fq=function(e){return function(n){return oM(function(a){return a.result})(e({substring:n,position:0}))}};var Sc={map:function(e){return function(n){var a=oM(function(t){return{result:e(t.result),suffix:t.suffix}});return function(t){return a(n(t))}}}},F_=function(e){return function(n){return new Me({pos:n.position,error:e})}},G_={apply:function(e){return function(n){return function(a){return uM(e(a))(function(t){return uM(n(t.suffix))(function(o){return iRe({result:t.result(o.result),suffix:o.suffix})})})}}},Functor0:function(){return Sc}};var As={bind:function(e){return function(n){return function(a){return uM(e(a))(function(t){return Cq(n(t.result))(t.suffix)})}}},Apply0:function(){return G_}};var Ls={pure:function(e){return function(n){return new Le({result:e,suffix:n})}},Apply0:function(){return G_}};var cRe={Applicative0:function(){return Ls},Bind1:function(){return As}},Gq={tailRecM:function(e){return function(n){var a=function(t){if(t.result instanceof Jt)return new Jt({state:t.result.value0,str:t.suffix});if(t.result instanceof kt)return new kt({result:t.result.value0,suffix:t.suffix});throw new Error("Failed pattern match at StringParser.Parser (line 87, column 5 - line 87, column 68): "+[t.constructor.name])};return function(t){return lRe(function(o){return oM(a)(Cq(e(o.state))(o.str))})({state:n,str:t})}}},Monad0:function(){return cRe}};var M_={alt:function(e){return function(n){return function(a){var t=e(a);if(t instanceof Me){if(a.position===t.value0.pos)return n(a);if($e)return new Me({error:t.value0.error,pos:t.value0.pos})}return t}}},Functor0:function(){return Sc}},sRe={empty:F_("No alternative"),Alt0:function(){return M_}},Mq={Applicative0:function(){return Ls},Plus1:function(){return sRe}};var Aq=ma(M_),iM=Z(As),lM=W(Ls),vRe=k(Sc);var fRe=oo(G_),_Re=Yn(G_);var cM=function(e){return function(n){return Aq(e)(F_(n))}},sM=function(e){return function(n){var a=e(n);return a instanceof Me?new Me({pos:n.position,error:a.value0.error}):a}},Cc=function(e){return Aq(iM(e)(function(n){return lM(Ee)}))(lM(Ee))};var Lq=function(e){return function(n){return new Nu(e,n)}};var pRe=function(e){return function(n){var a=e(n);if(a instanceof Le){var t=n.position65535;return t?e(n):jq(a.value0)}if(a instanceof M)return e(n);throw new Error("Failed pattern match at StringParser.CodePoints (line 57, column 3 - line 65, column 27): "+[a.constructor.name])})}(),Hv=function(e){return sM(Nq(DRe)(function(n){var a=e(n);return a?jq(n):F_("Character "+(Oq(n)+" did not satisfy predicate"))}))},Ci=function(e){return cM(Hv(function(n){return n===e}))("Could not match character "+Oq(e))};var gRe=function(e,n,a){var t=0,o;return function(u){if(t===2)return o;if(t===1)throw new ReferenceError(e+" was needed before it finished initializing (module "+n+", line "+u+")",n,u);return t=1,o=a(),t=2,o}},RRe=St(),vM=k(Sc),yRe=Fl(uR)(yt),wRe=k(XI),go=un(tn)(As),Zo=It(Sc),Ps=W(Ls),ei=ma(M_);var $p=oo(G_),qv=Z(As),kq=Fl(Co)(yt);var Tr=function(e){return RRe(_y(e))},fM=function(e){return vM(function(){var n=wRe(ju);return function(a){return yRe(n(a))}}())(Pq(Hv(e)))},Bq=function(e){return go(Zo(e))(function(){return go(Zo(Sb(e)))(function(){return Ps(Ee)})})},Sb=function(e){return ei(Bq(e))(Ps(Ee))},Hq=function(e){return go(Zo(Hv(e)))(function(){return go(Zo(Sb(Hv(e))))(function(){return Ps(Ee)})})},bRe=Ci(Tr(0));var qq=Ci(` `),Jq=function(e){return e===" "||e===" "},ERe=Hv(Jq),_M=Hq(Jq),IRe=function(e){var n=e>="0"&&e<="9",a=e>="a"&&e<="z"||e>="A"&&e<="Z";return n||a},Fc=function(e){return function(n){return function(a){return a>=e&&a<=n}}},TRe=Fc(Tr(33))(Tr(126)),SRe=Hv(TRe),pM=function(e){return function(n){return Yc(ju(n))(e)}},Cb=function(e){return Fc(Tr(1))(Tr(8))(e)||Fc(Tr(14))(Tr(31))(e)||pM("\v\f\x7F")(e)},CRe=function(e){return Fc(Tr(33))(Tr(39))(e)||Fc(Tr(42))(Tr(91))(e)||Fc(Tr(93))(Tr(126))(e)||Cb(e)},FRe=function(e){return Fc(Tr(33))(Tr(90))(e)||Fc(Tr(94))(Tr(126))(e)||Cb(e)},GRe=Hv(Cb),MRe=function(e){return pM(ju(Tr(33)))(e)||Fc(Tr(35))(Tr(91))(e)||Fc(Tr(93))(Tr(126))(e)||Cb(e)};var Wq=Ci("\r"),$q=Zo($p(Wq)(qq)),zp=function(){var e=Bq($p($q)(_M)),n=$p(_M)(Cc($p($q)(_M)));return ei(n)(e)}(),zq=function(){var e=go(Zo(Ci("\\")))(function(){return ei(SRe)(ei(ERe)(ei(qq)(ei(Wq)(ei(GRe)(bRe)))))});return qv(e)(function(n){return Ps("\\"+ju(n))})}(),ARe=ei(fM(MRe))(zq),LRe=function(){var e=go(Zo(Ci('"')))(function(){return qv(A_($p(Cc(zp))(ARe)))(function(n){return go(Zo(Cc(zp)))(function(){return go(Zo(Ci('"')))(function(){return Ps(n)})})})});return vM(function(n){return'"'+(kq(n)+'"')})(e)}(),Vq=gRe("comment","Text.Email.Parser",function(){return go(Zo(Ci("(")))(function(){return go(Sb(ei(Hq(CRe))(ei(Zo(zq))(ei(Vq(155))(zp)))))(function(){return go(Zo(Ci(")")))(function(){return Ps(Ee)})})})}),PRe=Vq(152),Fb=Sb(ei(PRe)(zp)),xRe=go(Cc(Fb))(function(){return go(Zo(Ci("[")))(function(){return qv(A_($p(Cc(zp))(fM(FRe))))(function(e){return go(Cc(zp))(function(){return go(Zo(Ci("]")))(function(){return go(Cc(Fb))(function(){return Ps("["+(kq(e)+"]"))})})})})})}),NRe=function(){var e=function(n){return IRe(n)||pM("!#$%&'*+/=?^_`{|}~-")(n)};return fM(e)}(),Qq=function(){var e=go(Zo(Cc(Fb)))(function(){return qv(ei(NRe)(LRe))(function(a){return go(Zo(Cc(Fb)))(function(){return Ps(a)})})}),n=xq(e)(Ci("."));return vM(Lu(uR)(yt)("."))(n)}(),jRe=ei(Qq)(xRe),ORe=Qq,dM=qv(ORe)(function(e){return qv(Ci("@"))(function(){return qv(jRe)(function(n){return qv(Uq)(function(){return Ps({localPart:e,domainPart:n})})})})});var kRe=function(e){return Fq(dM)(e)},BRe=function(){var e=fr(Au)(ne(lf()()(sf({reflectSymbol:function(){return"error"}})(vf({reflectSymbol:function(){return"pos"}})(Ze))(nr))));return function(n){return e(kRe(n))}}(),$h=function(e){var n=BRe(e);if(n instanceof Me)return!1;if(n instanceof Le)return!0;throw new Error("Failed pattern match at Text.Email.Validate (line 35, column 5 - line 37, column 25): "+[n.constructor.name])};var mM=Vo(Y),Gb=fo()(),HRe=Xn(vo),Kq=YN(me)()(),Yq=pe(ae),Xq=nl(JR(Zi)),Zq=k(ae),Mb=XN(Y)()(),eJ=pe(ze),zh=Te(me),qRe=rF(),hM=ne(Ze),JRe=PI(fn)(st),WRe=np(me)()(),L_=Te(We),nJ=Wn(Y)()(),$Re=Xn(ga),zRe=sr(zo),VRe=ne(Zu),Vh=W(yn),aJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),tJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),rJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),oJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),uJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Vp=function(e){return function(n){return function(a){return function(t){var o=function(d){return function(y){return function(I){return function(b){return function(S){return function(L){return Se([mM("")(y),Gb("form-control")({type:"text",name:"livestream_public_registration_form["+(d+"]"),value:b,placeholder:I,autoFocus:L.autoFocus,onChange:HRe(t)(function(O){return S(Gs(O))})})])}}}}}},u=[mM("")("I'm a..."),Kq("form-control")({name:"livestream_public_registration_form[i_am_a]",value:ke("")(Yq(a.persona)(Ib)),onChange:Xq(t)(function(d){return Zq(uJ.create)(Eq(MG(d)))})})([ya(Tt(a.persona))(Mb("")({value:""})("Select one...")),Se(eJ(Tq)(function(d){return Mb("")({value:Ib(d)})(Iq(d))}))])],i=zh("d-flex align-items-center")([Ke("Already have an account? "),qRe({text:"Log in",className:"btn btn-link px-2",auth0ActiveTab:lw,openInNewTab:!1})]),l=[mM("")("Graduation year"),Kq("form-control")({name:"livestream_public_registration_form[high_school_graduation_year]",value:ke("")(Yq(a.gradYear)(hM)),onChange:Xq(t)(function(d){return Zq(oJ.create)(Vc(MG(d)))})})([ya(Tt(a.gradYear))(Mb("")({value:""})("Select one...")),Se(eJ(n.allowedGradYears)(function(d){return Mb("")({value:hM(d)})(hM(d))}))])],s=ke({path:"",token:""})(Vy("livestreams_register_path")),R=JRe([$h(a.email),a.firstName!=="",a.lastName!=="",Ct(a.gradYear),Ct(a.persona)]);return Se([i,WRe("")({action:s.path,method:"POST"})([L_("row")(L_("col")(o("email")("Email")("Your email")(a.email)(aJ.create)({autoFocus:e.autoFocus}))),L_("row mt-3")(L_("col")(o("first_name")("First name")("Your first name")(a.firstName)(tJ.create)({autoFocus:!1}))),L_("row mt-3")(L_("col")(o("last_name")("Last name")("Your last name")(a.lastName)(rJ.create)({autoFocus:!1}))),zh("row mt-3")([zh("col-6")(l),zh("col-6")(u)]),L_("row mt-3")(zh("col-12")([nJ("btn btn-primary w-100 mt-3 t--register")({type:"submit",disabled:!R,onClick:$Re(Tb)(Ee)})("Register"),da(e.cancelButton)(function(d){return nJ("btn btn-outline-primary w-100 mt-3 t--cancel-registration")({type:"button",onClick:zRe(d.click)})(d.text)})])),Gb("")({type:"hidden",name:"authenticity_token",value:s.token}),Gb("")({type:"hidden",name:"register_for_conference_id",value:VRe(n.conference.id)}),Gb("")({type:"hidden",name:"utm_cv_source",value:n.paths.utmSource})])])}}}},Qp=function(e){return function(n){if(n instanceof aJ)return Vh({firstName:e.firstName,gradYear:e.gradYear,lastName:e.lastName,persona:e.persona,email:n.value0});if(n instanceof tJ)return Vh({email:e.email,gradYear:e.gradYear,lastName:e.lastName,persona:e.persona,firstName:n.value0});if(n instanceof rJ)return Vh({email:e.email,firstName:e.firstName,gradYear:e.gradYear,persona:e.persona,lastName:n.value0});if(n instanceof oJ)return Vh({email:e.email,firstName:e.firstName,lastName:e.lastName,persona:e.persona,gradYear:new T(n.value0)});if(n instanceof uJ)return Vh({email:e.email,firstName:e.firstName,gradYear:e.gradYear,lastName:e.lastName,persona:new T(n.value0)});throw new Error("Failed pattern match at Livestream.Register.Anonymous (line 176, column 16 - line 186, column 36): "+[n.constructor.name])}},Kp=function(){return{email:"",firstName:"",lastName:"",gradYear:M.value,persona:M.value}}();var iJ=Te(me),QRe=Eb(Y),KRe=Mt(Y)()(),Yp=function(e){return Se([iJ("")([Ke(` For college information sessions, we may tell the college that you attended. You can opt out anytime in your profile. `),QRe("")(` The only information we may share with colleges when you attend their events includes your name, email, graduation year, and whether you\u2019re a student, parent, or school counselor. `)]),iJ("")([Ke(` By completing this registration form you agree to CollegeVine\u2019s Website Terms and Conditions, which can be found `),KRe("")({href:e.paths.termsAndConditions})("here"),Ke(".")])])};var DM={eq:function(e){return function(n){return e===n}}};var xs=un(tn)(Qn),YRe=tl(Ve),lJ=Sa(),XRe=Ii(lJ(B({reflectSymbol:function(){return"author"}})(lJ(B({reflectSymbol:function(){return"cvid"}})(_e)(B({reflectSymbol:function(){return"username"}})(_e)(rn))))(B({reflectSymbol:function(){return"id"}})(on)(B({reflectSymbol:function(){return"isFromHQ"}})(Ia)(B({reflectSymbol:function(){return"isPublic"}})(Ia)(B({reflectSymbol:function(){return"text"}})(_e)(B({reflectSymbol:function(){return"time"}})(_e)(rn))))))))(Ve),Xp=Ma(Ve),Ab=W(ca),Sr=W(yn),gM=Wl(),ZRe=$t(me),RM=Ua(Y),yM=Vo(Y),eye=Qa(Y),P_=Te(me),Zp=Te(We),Lb=Wn(Y)()(),ed=Xn(ga),Qh=Te(Y),cJ=Ht(Y),sJ=pe(ze),nye=or(me)()(),aye=Ua(me),vJ=Z(en),tye=VR()(),rye=Xn(vo),oye=nl(Dv(Zi)),uye=ep(me),iye=fo()(),lye=Eb(Y),cye=we(Vt(Pt)),sye=pe(ae),fJ=Ho(gq(ru(Vu))),vye=Oo(DM),_J=k(Ga),fye=an(Rt),_ye=Hg(DM),pJ=it(wr(Ga)),dJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),mJ=function(){function e(){}return e.value=new e,e}(),hJ=function(){function e(){}return e.value=new e,e}(),x_=function(){function e(){}return e.value=new e,e}(),Pb=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),xb=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Nb=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),DJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),gJ=function(){function e(){}return e.value=new e,e}(),wM=function(){function e(){}return e.value=new e,e}(),bM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),RJ=function(){function e(){}return e.value=new e,e}(),yJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),EM=function(){function e(){}return e.value=new e,e}(),jb=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Ob=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),wJ=function(){function e(){}return e.value=new e,e}(),nd=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Kh=function(){function e(){}return e.value=new e,e}();var bJ=function(e){return xs(YRe(function(n){return Ae.create(bM.create(o_(n)))})(XRe(e.pusher.dataChannel)("question")))(function(){return xs(Xp(Ab(new Ae(RJ.value))))(function(){return Sr({newQuestionText:"",newQuestionBroadcast:!1,questions:[],modal:x_.value})})})},EJ=function(e){if(e.user instanceof M)return new T(new Ae(EM.value));if(e.user instanceof T&&e.user.value0.username instanceof M)return new T(new Ae(wJ.value));if(e.user instanceof T&&e.user.value0.username instanceof T)return M.value;throw new Error("Failed pattern match at Livestream.Live.Questions (line 363, column 3 - line 369, column 14): "+[e.user.constructor.name])},pye=function(){return Po(Wo(fn)([Bl.value,new ht(":"),wi.value,new ht(" "),Hl.value]))}(),IJ=function(e){return function(n){return function(a){var t=function(s){return a(Ae.create(s))},o=function(s){return gM({onDismiss:t(Kh.value),body:Se([ZRe("")([RM("")("By: "),yM("")("@"+s.author.username)]),eye("")(s.text),ss(""),P_("row align-items-center mb-3")([Zp("col-4")(Lb("btn w-100 btn-"+function(){return s.isPublic?"secondary":"success"}())({onClick:ed(t)(new Ob(mJ.value))})(function(){return s.isPublic?"Hide from audience":"Show to audience"}())),Qh("col")(function(){return s.isPublic?"This question will no longer be visible to the public, but HQ people will still see it.":"This question will become visible to the audience, even anonymous users."}())]),P_("row align-items-center")([Zp("col-4")(Lb("btn w-100 btn-danger")({onClick:ed(t)(new Ob(hJ.value))})("Ban this user")),P_("col")([Ke("This user will not be able to ask any more questions "),yM("")("in this livestream. "),RM("text-danger")("There is no way to un-ban a user!")])])]),bodyClass:"t--question-modal",footer:Se([Lb("btn btn-outline-primary px-4")({onClick:ed(t)(Kh.value)})("Never mind, close this dialog")])})},u=function(s){return gM({onDismiss:t(Kh.value),title:cJ("")("Please introduce yourself to participate:"),bodyClass:"t--questions-registration-form",body:Se([Vp({cancelButton:M.value,autoFocus:!0})(e)(s)(function(R){return t(jb.create(R))}),Zp("small mt-3")(Yp(e))])})},i=function(s){return gM({onDismiss:t(Kh.value),title:cJ("")("Please select a user name"),body:mq(s)(function(R){return t(nd.create(R))}),bodyClass:"t--username-modal"})},l=function(s){var R=function(y){return function(I){return function(b){return Se([Qh("ml-2 badge badge-"+I)(y),da(b)(function(S){return Qh("ml-2 text-secondary")(pye(S))})])}}},d=s.isFromHQ&&s.isPublic;return d?R("CollegeVine")("success")(s.time):s.isPublic?R("Question")("warning")(M.value):$n};return Se([Zp("position-relative h-100")(Zp("d-flex flex-column position-absolute-fullsize")(P_("d-flex flex-column flex-grow-1 min-height-0")([P_("flex-grow-1 min-height-0 overflow-y-auto bg-white border rounded mb-2 p-2 t--questions-list")(sJ(n.questions)(function(s){return nye("p-1 t--question"+function(){return e.isPrivilegedUser?" cursor-pointer":""}())({onClick:ed(t)(new Ob(new dJ(s)))})([aye("small d-inline-flex align-items-center")([yM("")("@"+s.author.username),l(s),Ke(":")]),RM("ml-1")(s.text)])})),P_("")([da(vJ(e.user)(function(s){return s.username}))(function(s){return Qh("small text-secondary mt-2")("@"+s)}),tye("form-control t--question-text")({onChange:rye(t)(function(s){return DJ.create(ob(s))}),onClick:oye(a)(EJ(e)),placeholder:"Ask a question...",rows:1,value:n.newQuestionText}),ya(e.isPrivilegedUser)(Zp("form-check my-2")(uye("form-check-label d-flex align-items-center t--broadcast-checkbox")([iye("form-check-input mr-2 mt-0")({type:"checkbox",checked:n.newQuestionBroadcast,onChange:ed(t)(gJ.value)}),Qh("badge badge-info bg-info text-dark mr-2")("HQ"),Ke("Send to all viewers")]))),P_("d-flex justify-content-end align-items-center")([lye("large mr-2")(` Questions you ask will only be visible to you and the host unless they select it to read to the audience, at which point it will appear with a yellow \u201CQuestion\u201D tag for all viewers to see. `),Lb("mt-2 px-5 btn-sm btn btn-primary t--submit-question")({onClick:ed(t)(wM.value),disabled:n.newQuestionText===""})(function(){return n.newQuestionBroadcast?"Send to all":"Send to host"}())])])]))),function(){if(n.modal instanceof x_)return $n;if(n.modal instanceof xb)return u(n.modal.value0);if(n.modal instanceof Pb)return o(n.modal.value0);if(n.modal instanceof Nb)return i(n.modal.value0);throw new Error("Failed pattern match at Livestream.Live.Questions (line 146, column 5 - line 150, column 41): "+[n.modal.constructor.name])}()])}}},dye=function(e){return function(n){return cye(sye(e.user)(function(a){return a.cvid}))(new T(n.author.cvid))||n.isPublic||e.isPrivilegedUser}},TJ=function(e){return function(n){return function(a){if(a instanceof wn)return Sr(n);if(a instanceof Ae){if(a.value0 instanceof DJ){var t=EJ(e);if(t instanceof T)return xs(Xp(Ab(t.value0)))(function(){return Sr(n)});if(t instanceof M)return Sr({modal:n.modal,newQuestionBroadcast:n.newQuestionBroadcast,questions:n.questions,newQuestionText:a.value0.value0});throw new Error("Failed pattern match at Livestream.Live.Questions (line 250, column 5 - line 255, column 46): "+[t.constructor.name])}if(a.value0 instanceof gJ)return Sr({modal:n.modal,newQuestionText:n.newQuestionText,questions:n.questions,newQuestionBroadcast:!n.newQuestionBroadcast});var t=function(o){if(a.value0 instanceof wM)return xs(Xp(Ab(new Ae(EM.value))))(function(){return Sr(n)});if(a.value0 instanceof bM)return Sr({modal:n.modal,newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:fJ(function(l){return rM(function(s){return s.time}(l))})(iu(dye(e))(qo(a.value0.value0)(iu(function(){var l=vye(a.value0.value0.id);return function(s){return l(function(R){return R.id}(s))}}())(n.questions))))});if(a.value0 instanceof RJ)return xs(Xp(_J(function(l){return Ae.create(yJ.create(l))})(ew(e.conference.id))))(function(){return Sr(n)});if(a.value0 instanceof yJ){var u=sJ(a.value0.value0)(function(l){return l.id});return Sr({modal:n.modal,newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:fJ(function(l){return rM(function(s){return s.time}(l))})(fye(a.value0.value0)(iu(function(l){return _ye(l.id)(u)})(n.questions)))})}if(a.value0 instanceof EM)return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new xb(Kp)});var i=function(l){if(a.value0 instanceof jb)return Sr(n);if(a.value0 instanceof wJ)return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new Nb(Dq(ke("")(vJ(e.user)(function(R){return R.username}))))});if(a.value0 instanceof nd&&a.value0.value0 instanceof wn&&a.value0.value0.value0 instanceof aM)return xs(Xp(Ab(new wn(a.value0.value0.value0.value0))))(function(){return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:x_.value})});if(a.value0 instanceof nd&&a.value0.value0 instanceof wn&&a.value0.value0.value0 instanceof tM)return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:x_.value});var s=function(R){if(a.value0 instanceof nd&&$e)return Sr(n);if(a.value0 instanceof Kh)return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:x_.value});if(a.value0 instanceof Ob){if(e.isPrivilegedUser){if(a.value0.value0 instanceof dJ)return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new Pb(a.value0.value0.value0)});var d=function(y){var I=function(b){return Sr(n)};return a.value0.value0 instanceof hJ&&n.modal instanceof Pb?xs(Va(jO({conferenceId:e.conference.id,userCvid:n.modal.value0.author.cvid})))(function(){return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:x_.value})}):I(!0)};return a.value0.value0 instanceof mJ&&n.modal instanceof Pb?xs(Va(CO({questionId:n.modal.value0.id,isPublic:!n.modal.value0.isPublic})))(function(){return Sr({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:x_.value})}):d(!0)}if($e)return Sr(n)}throw new Error("Failed pattern match at Livestream.Live.Questions (line 246, column 1 - line 246, column 76): "+[a.value0.constructor.name])};return a.value0 instanceof nd&&n.modal instanceof Nb?pJ(function(R){return Ae.create(nd.create(R))})(function(R){return{newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new Nb(R)}})(hq(n.modal.value0)(a.value0.value0)):s(!0)};return a.value0 instanceof jb&&n.modal instanceof xb?pJ(function(l){return Ae.create(jb.create(l))})(function(l){return{newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new xb(l)}})(Qp(n.modal.value0)(a.value0.value0)):i(!0)};return a.value0 instanceof wM&&e.user instanceof T?xs(Xp(_J(function(o){return Ae.create(bM.create(o))})(FO({conferenceId:e.conference.id,text:n.newQuestionText,hqBroadcast:n.newQuestionBroadcast}))))(function(){return Sr({modal:n.modal,questions:n.questions,newQuestionText:"",newQuestionBroadcast:!1})}):t(!0)}throw new Error("Failed pattern match at Livestream.Live.Questions (line 246, column 1 - line 246, column 76): "+[e.constructor.name,n.constructor.name,a.constructor.name])}}};var Ub,mye=new Uint8Array(16);function IM(){if(!Ub&&(Ub=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto!="undefined"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),!Ub))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ub(mye)}var SJ=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function hye(e){return typeof e=="string"&&SJ.test(e)}var TM=hye;var xo=[];for(kb=0;kb<256;++kb)xo.push((kb+256).toString(16).substr(1));var kb;function Dye(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,a=(xo[e[n+0]]+xo[e[n+1]]+xo[e[n+2]]+xo[e[n+3]]+"-"+xo[e[n+4]]+xo[e[n+5]]+"-"+xo[e[n+6]]+xo[e[n+7]]+"-"+xo[e[n+8]]+xo[e[n+9]]+"-"+xo[e[n+10]]+xo[e[n+11]]+xo[e[n+12]]+xo[e[n+13]]+xo[e[n+14]]+xo[e[n+15]]).toLowerCase();if(!TM(a))throw TypeError("Stringified UUID is invalid");return a}var CJ=Dye;function gye(e,n,a){e=e||{};var t=e.random||(e.rng||IM)();if(t[6]=t[6]&15|64,t[8]=t[8]&63|128,n){a=a||0;for(var o=0;o<16;++o)n[a+o]=t[o];return n}return CJ(t)}var SM=gye;var FJ=SM;var Rye=function(e){return e},CM=function(e){return e};var FM=Z(tr)(FJ)(function(){var e=W(rt);return function(n){return e(Rye(n))}}());var ad=Ma(Ve),GJ=un(tn),yye=GJ(_a),wye=an(RR),bye=k(Ga),Yh=Bn(Ve),Eye=Qa(Y),Iye=yu()(),MJ=or(We)()(),AJ=Nd(Vu),Tye=Io(ar),Sye=Jn(du),Cye=ne(ex),LJ=ne(cf),Fye=k(ze),Gc=GJ(Qn),Gye=tl(Ve),Mye=Ii(Sa()(B({reflectSymbol:function(){return"authorTag"}})(_e)(B({reflectSymbol:function(){return"kind"}})(_e)(rn))))(Ve),Bb=k(zn),Jv=W(yn),PJ=tt(k0),xJ=xd(Vu),Aye=W(ca),GM=sc(O0),Lye=Te(me),Pye=pe(ze),xye=Wn(me)()(),Nye=Xn(ga),jye=Ua(Y),Hb=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),Xh=function(){function e(n,a){this.value0=n,this.value1=a}return e.create=function(n){return function(a){return new e(n,a)}},e}(),NJ=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),MM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),AM=function(e){return ad(yye(Kt(wye(e)(10)))(function(){return bye(MM.create)(Yh(Xu))}))},jJ=50,OJ=function(e){var n=function(o){return Eye("text-white fe fe-"+o)("")},a=function(){if(e instanceof bs)return n("heart");if(e instanceof Gv)return n("thumbs-up");if(e instanceof u_)return n("thumbs-down");if(e instanceof Mv)return n("file-text");if(e instanceof Av)return Iye("")({src:"/img/icons/smile-white.svg",style:ot({width:"1em"})});throw new Error("Failed pattern match at Livestream.Live.Reactions (line 158, column 12 - line 163, column 108): "+[e.constructor.name])}(),t=function(){if(e instanceof bs)return"#F0747B";if(e instanceof Gv)return"#008CFD";if(e instanceof u_)return"#6E84A3";if(e instanceof Mv)return"#18A668";if(e instanceof Av)return"#F6C343";throw new Error("Failed pattern match at Livestream.Live.Reactions (line 165, column 23 - line 170, column 34): "+[e.constructor.name])}();return MJ("d-flex justify-content-center align-items-center rounded-circle")({style:ot({backgroundColor:t,height:"1.5rem",width:"1.5rem"})})(a)},UJ=6,kJ=function(){return UJ*1e3}(),BJ=function(e){return function(n){var a=function(t){if(AJ(t.removeAt)(e.currentTime))return $n;var o=Ft(Tye(Sye(Xi(DT(t.startDecayAt))))(10)),u=function(){var d=o<=3;if(d)return"linear";var y=o<=7;return y?"ease-in":"ease"}(),i=t.reaction.authorTag===e.authorTag,l=1+(o-5)/4,s=AJ(t.startDecayAt)(e.currentTime),R=UJ+(o-5)/10;return MJ("position-absolute mb-4 mt-2")({key:Cye(t.startDecayAt),style:ot({right:LJ(l)+"rem",top:function(){return s?"0":"90%"}(),opacity:function(){return s?0:i?1:.6}(),transitionProperty:"top opacity",transitionDuration:LJ(R)+"s",transitionTimingFunction:u})})(OJ(t.reaction.kind))};return Se(Fye(a)(e.reactions))}},HJ=function(e){return Gc(Gye(function(n){return new Xh(h7(n),M.value)})(Mye(e.pusher.dataChannel)("reaction")))(function(){return Gc(ad(Yh(Bb(function(n){return NJ.create(CM(n))})(FM))))(function(){return Gc(ad(Yh(Bb(MM.create)(Xu))))(function(){return Jv({authorTag:"",currentTime:PJ,coolDownUntil:PJ,reactions:[]})})})})},qJ=800,JJ=function(e){return function(n){return function(a){if(a instanceof Hb&&a.value1 instanceof M)return Gc(ad(Yh(Bb(function(){var t=Hb.create(a.value0);return function(o){return t(T.create(o))}}())(Xu))))(function(){return Jv(n)});if(a instanceof Hb&&a.value1 instanceof T){if(xJ(n.coolDownUntil)(a.value1.value0))return Gc(ad(Aye(new Xh({kind:a.value0,authorTag:n.authorTag},new T(a.value1.value0)))))(function(){return Jv(n)});if($e)return Gc(Va(PO(e.conference.id)({authorTag:n.authorTag,kind:a.value0})))(function(){return Gc(AM(qJ))(function(){return Jv({authorTag:n.authorTag,currentTime:n.currentTime,reactions:n.reactions,coolDownUntil:ke(a.value1.value0)(GM(qJ)(a.value1.value0))})})})}if(a instanceof Xh&&a.value1 instanceof M)return Gc(ad(Yh(Bb(function(){var t=Xh.create(a.value0);return function(o){return t(T.create(o))}}())(Xu))))(function(){return Jv(n)});if(a instanceof Xh&&a.value1 instanceof T)return Gc(AM(jJ))(function(){return Gc(AM(kJ))(function(){var t={reaction:a.value0,startDecayAt:ke(a.value1.value0)(GM(jJ)(a.value1.value0)),removeAt:ke(a.value1.value0)(GM(kJ)(a.value1.value0))};return Jv({authorTag:n.authorTag,coolDownUntil:n.coolDownUntil,reactions:w0(n.reactions)(t),currentTime:a.value1.value0})})});if(a instanceof NJ)return Jv({coolDownUntil:n.coolDownUntil,currentTime:n.currentTime,reactions:n.reactions,authorTag:a.value0});if(a instanceof MM)return Jv({authorTag:n.authorTag,coolDownUntil:n.coolDownUntil,reactions:iu(function(t){return xJ(t.removeAt)(a.value0)})(n.reactions),currentTime:a.value0});throw new Error("Failed pattern match at Livestream.Live.Reactions (line 176, column 22 - line 219, column 8): "+[a.constructor.name])}}},WJ=function(e){return function(n){var a=function(t){if(t instanceof bs)return"love this";if(t instanceof Gv)return"helpful";if(t instanceof u_)return"not helpful";if(t instanceof Mv)return"taking notes";if(t instanceof Av)return"LOL";throw new Error("Failed pattern match at Livestream.Live.Reactions (line 144, column 13 - line 149, column 30): "+[t.constructor.name])};return Lye("d-flex justify-content-end my-2")(Pye([bs.value,Av.value,Gv.value,Mv.value])(function(t){return xye("btn bg-light d-flex align-items-center p-0 ml-3")({onClick:Nye(n)(new Hb(t,M.value)),style:ot({borderRadius:"1em"})})([OJ(t),jye("d-none d-md-inline text-secondary small ml-2 mr-3")(a(t))])}))}};var $J=un(tn),Oye=Z(_a),LM=Bn(Ve),qb=W(ca),Jb=$t(Y),Wb=ne(Ze),Zh=$J(Qn),eD=Ma(Ve),Dl=W(yn),zJ=xt(Nr),VJ=oo(LR),QJ=k(Ga),Uye=ko(yn)(Pu),kye=Qu(es),KJ=Te(Y),Bye=Jl(),Hye=Ht(Y),YJ=Wn(Y)()(),PM=Xn(ga),XJ=Te(We),qye=Wn(me)()(),Jye=Qa(Y),Wye=Te(me),ZJ=function(){function e(){}return e.value=new e,e}(),eW=function(){function e(){}return e.value=new e,e}(),nW=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),aW=function(){function e(){}return e.value=new e,e}(),tW=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),rW=function(){function e(){}return e.value=new e,e}(),oW=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),xM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),uW=function(){function e(){}return e.value=new e,e}(),iW=function(){function e(){}return e.value=new e,e}(),NM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),jM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),$b=function(){function e(){}return e.value=new e,e}(),lW=$J(_a)(Kt(1e3))(function(){return Oye(LM(Xu))(function(e){return qb(new NM(e))})}),$ye=function(e){return{header:"Go on-air?",body:Se([Jb("")("Are you sure you want to go on-air?"),Jb("mb-0 font-weight-bold fw-bold")(` Watchers will start seeing your stream in `+(Wb(e.videoLagSeconds)+` seconds if you confirm. If you're presenting with Zoom, make sure you've gone "live" on Zoom as well. `))]),confirmText:"Confirm, go on-air!",cancelText:"Cancel",confirmMsg:aW.value}},cW=function(e){return function(n){return function(a){return function(t){return Zh(eD(lW))(function(){return Dl({confirmation:n.confirmation,network:ZJ.value,streamStatus:t,transition:new T({since:a,secondsLeft:e.videoLagSeconds})})})}}}},sW=function(e){return function(n){return function(a){if(a instanceof aW)return Zh(eD(zJ(VJ(wO(e.conference.id))(QJ(tW.create)(LM(Xu))))(function(l){return qb(new jM("Error opening the stream. Please try again."))})))(function(){return Dl({confirmation:n.confirmation,streamStatus:n.streamStatus,transition:n.transition,network:eW.value})});if(a instanceof tW)return cW(e)(n)(a.value0)(qr.value);if(a instanceof rW)return Zh(eD(zJ(VJ(bO(e.conference.id))(QJ(oW.create)(LM(Xu))))(function(l){return qb(new jM("Error closing the stream. Please try again."))})))(function(){return Dl(n)});if(a instanceof oW)return cW(e)(n)(a.value0)(Er.value);if(a instanceof xM)return Dl({network:n.network,streamStatus:n.streamStatus,transition:n.transition,confirmation:new T(a.value0)});if(a instanceof uW)return Zh(Uye(n.confirmation)(function(l){return eD(qb(l.confirmMsg))}))(function(){return Dl({network:n.network,streamStatus:n.streamStatus,transition:n.transition,confirmation:M.value})});if(a instanceof iW)return Dl({network:n.network,streamStatus:n.streamStatus,transition:n.transition,confirmation:M.value});if(a instanceof jM)return Dl({confirmation:n.confirmation,streamStatus:n.streamStatus,transition:n.transition,network:new nW(a.value0)});var t=function(l){if(a instanceof NM||a instanceof $b)return Dl(n);throw new Error("Failed pattern match at Livestream.Live.StreamControls (line 185, column 1 - line 185, column 76): "+[a.constructor.name])};if(a instanceof NM){if(n.transition instanceof T){var o=kye(a.value0)(n.transition.value0.since),u=e.videoLagSeconds-co(o)|0,i=u>0;return i?Zh(eD(lW))(function(){return Dl({confirmation:n.confirmation,network:n.network,streamStatus:n.streamStatus,transition:new T({since:n.transition.value0.since,secondsLeft:u})})}):Dl({confirmation:n.confirmation,network:n.network,streamStatus:n.streamStatus,transition:M.value})}return t(!0)}return t(!0)}}},vW=function(e){return Dl({streamStatus:e.streamStatus,transition:M.value,network:ZJ.value,confirmation:M.value})},zye=function(){return{header:"End the stream?",body:Se([Jb("")("Are you sure you want to end the stream?"),Jb("mb-0 font-weight-bold fw-bold")("You won't be able to restart it again!")]),confirmText:"Yes, end it",cancelText:"No, keep streaming",confirmMsg:rW.value}}(),fW=function(e){return function(n){return function(a){var t=function(){return n.network instanceof eW?KJ("position-absolute-fullsize d-flex align-items-center justify-content-center bg-semi-transparent-white")("Switching..."):$n}(),o=function(R){return Bye({header:Hye("my-0")(R.header),bodyClass:"p-5",body:R.body,footerClass:"p-4",footer:Se([YJ("btn btn-primary px-4")({onClick:PM(a)(uW.value)})(R.confirmText),YJ("btn btn-outline-primary px-4")({onClick:PM(a)(iW.value)})(R.cancelText)])})},u=function(R){return function(d){return function(y){return function(I){return function(b){return XJ("col-auto pr-0")(qye("btn btn-"+(R+(" px-5 d-flex align-items-center font-size-lg btn-"+I)))({onClick:PM(a)(b)})([Jye("fe mr-2 fe-"+d)(""),Ke(y)]))}}}}},i=function(){if(n.streamStatus instanceof Du)return u("lg")("power")("GO ON-AIR")("outline-secondary")(new xM($ye(e)));var R=function(d){if(n.streamStatus instanceof qr)return Se([u("lg")("radio")("ON AIR")("success")($b.value),u("sm")("x-circle")("End stream")("outline-danger")(new xM(zye))]);if(n.streamStatus instanceof Er)return u("lg")("slash")("STREAM IS OVER")("outline-secondary")($b.value);throw new Error("Failed pattern match at Livestream.Live.StreamControls (line 78, column 1 - line 78, column 71): "+[n.streamStatus.constructor.name])};return n.streamStatus instanceof qr&&n.transition instanceof T?u("lg")("radio")("ON AIR")("success")($b.value):R(!0)}(),l=function(R){return KJ("alert small m-0 flex-grow-1 alert-"+R)},s=function(){if(n.network instanceof nW)return l("danger")(n.network.value0);if(n.streamStatus instanceof Du)return l("warning")("The stream has not been started yet. To start, click the big 'GO ON-AIR' button on the left.");var R=function(d){if(n.streamStatus instanceof qr)return l("light")(` We're live. The audience should see your video with a `+(Wb(e.videoLagSeconds)+`-second delay. If you don't see your face above (give it a few seconds), it means you're not streaming. `));var y=function(I){if(n.streamStatus instanceof Er)return l("light")("The stream has ended. The audience does not see any video right now.");throw new Error("Failed pattern match at Livestream.Live.StreamControls (line 78, column 1 - line 78, column 71): "+[n.streamStatus.constructor.name,n.network.constructor.name])};return n.streamStatus instanceof Er&&n.transition instanceof T?l("info")("You may stop presenting now. The audience will keep seeing the tail of the stream for another "+(Wb(n.transition.value0.secondsLeft)+" seconds.")):y(!0)};return n.streamStatus instanceof qr&&n.transition instanceof T?l("info")("Start presenting now. The audience will see the stream in "+(Wb(n.transition.value0.secondsLeft)+" seconds...")):R(!0)}();return Wye("position-relative row align-items-center t--stream-controls")([i,XJ("col")(s),t,da(n.confirmation)(o)])}}};var Vye=sc(sv),_W=Qu(sv),pW=e8(),Qye=Wl(),Kye=Ht(Y),Yye=Te(Y),dW=$t(Y),Xye=Wn(Y)()(),Zye=Xn(ga),mW=Ma(Ve),hW=un(tn),DW=k(Ga),gW=Bn(Ve),RW=hW(Qn),ewe=Ji(nt),OM=W(yn),UM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),kM=function(){function e(){}return e.value=new e,e}(),nwe=[30,15,5,0],yW=function(e){return ke(e.conference.scheduledStartTime)(Vye(Ft(e.conference.duration))(e.conference.scheduledStartTime))},wW=function(e){return function(n){return function(a){if(!n.modal)return $n;if(n.now instanceof M)return $n;if(n.now instanceof T){var t=yW(e),o=_W(t)(n.now.value0),u=function(){if(o<1)return" ended "+pW({from:t,to:n.now.value0,format:my("ago")});if($e)return" ends "+pW({from:n.now.value0,to:t,format:my("from now")});throw new Error("Failed pattern match at Livestream.Live.StreamEndWarning (line 75, column 7 - line 77, column 105): "+[])}();return Qye({onDismiss:a(kM.value),body:Se([Kye("mb-0")("Host-only warning"),Yye("text-secondary mb-4")("You see this because you're the host. The audience doesn't see this."),dW("font-weight-bold fw-bold")("\u23F0 Scheduled stream time "+u),dW("")(` You have `+(cl(e.conference.tailTime)("extra minute")("extra minutes")+` after scheduled stream end, in case you absolutely cannot wrap up before then. After that the video streaming will be terminated. `)),Xye("btn btn-primary px-4")({onClick:Zye(a)(kM.value)})("Got it")])})}throw new Error("Failed pattern match at Livestream.Live.StreamEndWarning (line 51, column 1 - line 51, column 71): "+[e.constructor.name,n.constructor.name,a.constructor.name])}}},awe=mW(hW(_a)(Kt(60100))(function(){return DW(UM.create)(gW(t_))})),bW=function(e){return function(n){return function(a){if(a instanceof UM)return RW(awe)(function(){var t=_W(yW(e))(a.value0),o=ewe(co(t))(nwe);return OM({now:new T(a.value0),modal:n.modal||o})});if(a instanceof kM)return OM({now:n.now,modal:!1});throw new Error("Failed pattern match at Livestream.Live.StreamEndWarning (line 80, column 22 - line 91, column 33): "+[a.constructor.name])}}},EW=function(){return RW(mW(DW(UM.create)(gW(t_))))(function(){return OM({modal:!1,now:M.value})})}();var IW=un(tn),twe=IW(_a),TW=W(ca),rwe=IW(Qn),owe=Ma(Ve),uwe=xt(Nr),zb=W(yn),iwe=we(Km),SW=Wo(fn),BM=Te(me),Vb=Qa(Y),lwe=Wn(Y)()(),CW=Xn(ga),cwe=Mt(Y)()(),swe=Wn(We)()(),vwe=Jl(),FW=Te(We),fwe=Vo(Y),_we=Rv(Y)()(),pwe=Ua(Y),GW=function(){function e(){}return e.value=new e,e}(),MW=function(){function e(){}return e.value=new e,e}(),HM=function(){function e(){}return e.value=new e,e}(),AW=function(){function e(){}return e.value=new e,e}(),LW=function(){function e(){}return e.value=new e,e}(),PW=function(){function e(){}return e.value=new e,e}(),xW=function(){function e(){}return e.value=new e,e}(),dwe=function(){function e(){}return e.value=new e,e}(),NW=function(e){return function(n){return function(a){var t=twe(Xy({fromConference:new T(e.conference.id),registerForConference:n.cta.conferenceId,utmSource:e.paths.utmSource}))(function(){return TW(new Ae(PW.value))});if(a instanceof LW)return rwe(owe(uwe(t)(function(o){return TW(new Ae(xW.value))})))(function(){return zb({cta:n.cta,stage:MW.value})});if(a instanceof PW)return zb({cta:n.cta,stage:AW.value});if(a instanceof xW)return zb({cta:n.cta,stage:HM.value});throw new Error("Failed pattern match at Livestream.Ctas.Display.Event (line 138, column 24 - line 148, column 44): "+[a.constructor.name])}}},jW=function(e){return function(n){return iwe(e.cta.conferenceId)(n.conferenceId)}},OW=function(e){return zb({cta:e,stage:GW.value})},mwe=function(){return Po(SW([kl.value,new ht(", "),Ol.value,new ht(" "),Ul.value,new ht(" at "),Bl.value,new ht(":"),wi.value,new ht(" "),Hl.value]))}(),hwe=function(){return Po(SW([kl.value]))}(),UW=function(e){return function(n){return function(a){var t=function(){return n.stage instanceof HM?BM("text-danger small mt-2")([Vb("fe fe-x-circle mr-2")(""),Ke("Something went wrong. Please try again.")]):$n}(),o=function(R){return a(Ae.create(R))},u=function(){if(e.user instanceof T)return lwe("btn btn-primary px-4 t--register-one-click")({onClick:CW(o)(LW.value)})("Register (one-click)");if(e.user instanceof M)return cwe("btn btn-primary px-4 t--register-new-tab")({href:n.cta.registrationPath,target:"_blank",rel:"noopener"})("Register now");throw new Error("Failed pattern match at Livestream.Ctas.Display.Event (line 92, column 22 - line 100, column 25): "+[e.user.constructor.name])}(),i=function(){if(n.stage instanceof GW||n.stage instanceof HM)return u;if(n.stage instanceof MW)return BM("text-secondary")([Vb("fe fe-refresh-cw mr-2")(""),Ke("Hold on tight...")]);if(n.stage instanceof AW)return BM("text-success")([Vb("fe fe-check-circle mr-2")(""),Ke("You\u2019ve registered \u2013\xA0see you "+(hwe(n.cta.startTime)+"!"))]);throw new Error("Failed pattern match at Livestream.Ctas.Display.Event (line 76, column 36 - line 90, column 10): "+[n.stage.constructor.name])}(),l=function(R){return a(wn.create(R))},s=swe("btn btn-sm btn-outline-primary d-flex py-1 px-2")({onClick:CW(l)(dwe.value)})(Vb("fe fe-x")(""));return vwe({body:Se([FW("row justify-content-end mt-n3")(s),fwe("")("Join us for our upcoming livestream:"),_we("mt-3")({id:Ei})(n.cta.title),pwe("small")(mwe(n.cta.startTime)+(" "+a_)),FW("row mt-6 ml-0")(i),t]),bodyClass:"t--cta-active",size:rh.value})}}};var Dwe=Jl(),Qb=Te(me),gwe=ej(Y)()(),Kb=Te(We),Rwe=Wn(We)()(),kW=Xn(ga),ywe=Qa(Y),wwe=pe(ze),bwe=al()(),Ewe=Hr(Y),Iwe=$t(Y),Twe=Mt(Y)()(),Swe=un(tn),Cwe=Swe(Qn),Fwe=Ma(Ve),Gwe=Bn(Ve),Mwe=Is(gr)(),Awe=ne(Ze),BW=W(yn),Lwe=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),HW=function(){function e(){}return e.value=new e,e}(),qW=function(e){return function(n){var a=function(){var i=uo(e.cta.providers);return i===1?Lv.value:i===2?Lv.value:oh.value}(),t=function(i){return n(Ae.create(i))},o=function(i){return n(wn.create(i))},u=function(){var i=uo(e.cta.providers);return i===1?"col-12":i===2?"col-12 col-md-6 mb-3 mb-md-0":"col-12 col-md-4 mb-3 mb-md-0"}();return Dwe({bodyClass:"bg-gray-900 text-white t--cta-active",body:Se([Qb("row no-gutters g-0 mb-4")([Qb("col text-center")([gwe("mb-2")({id:Ei})("The admissions process is hard - advisors are here to help!"),Ke("Schedule a free consulation to get your questions answered")]),Kb("col-auto text-right")(Rwe("btn btn-link p-0 m-0 text-white")({onClick:kW(o)(HW.value)})(ywe("fe fe-x")("")))]),Qb("row text-center")(wwe(e.cta.providers)(function(i){return Qb(u)([Kb("row mb-3")(Kb("col-auto mx-auto")(Kb("avatar avatar-xl")(bwe("avatar-img rounded-circle img-fluid")({src:i.avatarUrl})))),Ewe("mb-2")(i.name),Iwe("mb-3")(i.location),Twe("btn btn-primary btn-sm px-3 py-1")({target:"_blank",href:i.linkUrl,onClick:kW(t)(new Lwe(i.avatarUrl))})(e.cta.linkText)])}))]),size:a})}},JW=function(e){return function(n){return Cwe(Fwe(Gwe(function(){return Mwe("Livestream: CTA Popup Link Clicked")({livestream_cta_id:Awe(e.cta.id),livestream_cta_url:n.value0})(),new wn(HW.value)})))(function(){return BW(e)})}},WW=function(e){return function(n){return e.cta.id===n.id}},$W=function(e){return BW({cta:e})};var Pwe=Mt(Y)()(),zW=Xn(ga),xwe=Wn(We)()(),Nwe=Qa(Y),jwe=Jl(),VW=Te(We),Owe=Rv(Y)()(),Uwe=un(tn),kwe=Uwe(Qn),Bwe=Ma(Ve),Hwe=Bn(Ve),qwe=Is(gr)(),Jwe=ne(Ze),QW=W(yn),Wwe=function(){function e(){}return e.value=new e,e}(),KW=function(){function e(){}return e.value=new e,e}(),YW=function(e){return function(n){var a=function(i){return n(Ae.create(i))},t=Pwe("btn btn-primary px-4 t--register-new-tab")({href:e.cta.url,target:"_blank",rel:"noopener",onClick:zW(a)(Wwe.value)})(e.cta.buttonText),o=function(i){return n(wn.create(i))},u=xwe("btn btn-sm btn-outline-primary d-flex py-1 px-2")({onClick:zW(o)(KW.value)})(Nwe("fe fe-x")(""));return jwe({body:Se([VW("row justify-content-end mt-n3")(u),Owe("mt-3")({id:Ei})(e.cta.title),VW("row mt-6 ml-0")(t)]),bodyClass:"t--cta-active",size:rh.value})}},XW=function(e){return function(n){return kwe(Bwe(Hwe(function(){return qwe("Livestream: CTA Popup Link Clicked")({livestream_cta_id:Jwe(e.cta.id),livestream_cta_title:e.cta.title,livestream_cta_url:e.cta.url})(),new wn(KW.value)})))(function(){return QW(e)})}},ZW=function(e){return function(n){return e.cta.id===n.id}},e$=function(e){return QW({cta:e})};var qM=un(tn),ni=qM(en),ai=yr(Br),td=W(aa),n$=Mr(Uo(st)),nD=ma($r),Ns=W(yn),$we=qM(Qn),zwe=Ma(Ve),Vwe=qM(_a),Qwe=W(ca),JM=Te(me),Kwe=ep(Y),Ywe=fo()(),Xwe=Xn(vo),Zwe=Wn(We)()(),a$=Xn(ga),ebe=Qa(Y),nbe=Jl(),WM=Te(We),abe=Rv(Y)()(),tbe=$t(Y),rbe=Wn(Y)()(),t$=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),r$=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),o$=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),u$=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),i$=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),l$=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),c$=function(){function e(){}return e.value=new e,e}(),s$=function(){function e(){}return e.value=new e,e}(),v$=function(e){return function(n){return e.cta.id===n.id}},f$=function(e){return function(n){var a=ni(ai(n.cta.requireReferredUserLastName))(function(){return ni(ai(n.referredUserLastName===""))(function(){return td("Please enter the other person\u2019s last name")})}),t=ni(ai(n.cta.requireReferredUserFirstName))(function(){return ni(ai(n.referredUserFirstName===""))(function(){return td("Please enter the other person\u2019s first name")})}),o=ni(ai(n$($h)(n.referredUserEmail)))(function(){return td("Please enter a valid email address")}),u=ni(ai(Tt(e.user)))(function(){return ni(ai(n.cta.requireAnonymousUserLastName))(function(){return ni(ai(n.anonymousUserLastName===""))(function(){return td("Please enter your last name")})})}),i=ni(ai(Tt(e.user)))(function(){return ni(ai(n.cta.requireAnonymousUserFirstName))(function(){return ni(ai(n.anonymousUserFirstName===""))(function(){return td("Please enter your first name")})})}),l=ni(ai(Tt(e.user)))(function(){return ni(ai(n.cta.requireAnonymousUserEmail))(function(){return ni(ai(n$($h)(n.anonymousUserEmail)))(function(){return td("Please enter a valid email address")})})});return nD(i)(nD(u)(nD(l)(nD(t)(nD(a)(o)))))}},_$=function(e){return function(n){return function(a){if(a instanceof t$)return Ns({anonymousUserEmail:n.anonymousUserEmail,anonymousUserLastName:n.anonymousUserLastName,cta:n.cta,referredUserEmail:n.referredUserEmail,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,validationActive:n.validationActive,anonymousUserFirstName:a.value0});if(a instanceof r$)return Ns({anonymousUserEmail:n.anonymousUserEmail,anonymousUserFirstName:n.anonymousUserFirstName,cta:n.cta,referredUserEmail:n.referredUserEmail,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,validationActive:n.validationActive,anonymousUserLastName:a.value0});if(a instanceof o$)return Ns({anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,cta:n.cta,referredUserEmail:n.referredUserEmail,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,validationActive:n.validationActive,anonymousUserEmail:a.value0});if(a instanceof u$)return Ns({anonymousUserEmail:n.anonymousUserEmail,anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,cta:n.cta,referredUserEmail:n.referredUserEmail,referredUserLastName:n.referredUserLastName,validationActive:n.validationActive,referredUserFirstName:a.value0});if(a instanceof i$)return Ns({anonymousUserEmail:n.anonymousUserEmail,anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,cta:n.cta,referredUserEmail:n.referredUserEmail,referredUserFirstName:n.referredUserFirstName,validationActive:n.validationActive,referredUserLastName:a.value0});if(a instanceof l$)return Ns({anonymousUserEmail:n.anonymousUserEmail,anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,cta:n.cta,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,validationActive:n.validationActive,referredUserEmail:a.value0});if(a instanceof c$){var t=Tt(f$(e)(n));return t?$we(zwe(Vwe(EO({ctaId:n.cta.id,anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,anonymousUserEmail:n.anonymousUserEmail,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,referredUserEmail:n.referredUserEmail}))(function(){return Qwe(new wn(s$.value))})))(function(){return Ns(n)}):Ns({anonymousUserEmail:n.anonymousUserEmail,anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,cta:n.cta,referredUserEmail:n.referredUserEmail,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,validationActive:!0})}throw new Error("Failed pattern match at Livestream.Ctas.Display.Referral (line 146, column 24 - line 175, column 45): "+[a.constructor.name])}}},p$=function(e){return function(n){return function(a){var t=f$(e)(n),o=function(I){return function(b){return function(S){return function(L){return function(O){return JM(I)([Kwe("mb-2")(S),Ywe("form-control "+b)({type:"text",value:L,onChange:Xwe(a)(function($){return Ae.create(O(Gs($)))})})])}}}}},u=ya(Tt(e.user)&&n.cta.requireAnonymousUserEmail)(o("col-12 mb-3")("t--anon-email")("Your email")(n.anonymousUserEmail)(o$.create)),i=ya(Tt(e.user))(Se([ya(n.cta.requireAnonymousUserFirstName)(o("col-12 col-md-6 mb-3")("t--anon-first-name")("Your first name")(n.anonymousUserFirstName)(t$.create)),ya(n.cta.requireAnonymousUserLastName)(o("col-12 col-md-6 mb-3")("t--anon-last-name")("Your last name")(n.anonymousUserLastName)(r$.create))])),l=o("col-12 mb-3")("t--referred-email")("Other person\u2019s email")(n.referredUserEmail)(l$.create),s=Se([ya(n.cta.requireReferredUserFirstName)(o("col-12 col-md-6 mb-3")("t--referred-first-name")("Other person\u2019s first name")(n.referredUserFirstName)(u$.create)),ya(n.cta.requireReferredUserLastName)(o("col-12 col-md-6 mb-3")("t--referred-last-name")("Other person\u2019s last name")(n.referredUserLastName)(i$.create))]),R=function(I){return a(Ae.create(I))},d=function(I){return a(wn.create(I))},y=Zwe("btn btn-sm btn-outline-primary d-flex py-1 px-2 t--close")({onClick:a$(d)(s$.value)})(ebe("fe fe-x")(""));return nbe({body:Se([WM("row justify-content-end mt-n3")(y),abe("mt-3")({id:Ei})(n.cta.title),da(n.cta.description)(tbe("")),JM("row")([i,u,s,l]),JM("row")([WM("col-auto my-auto")(rbe("btn btn-primary t--save")({onClick:a$(R)(c$.value)})("Save")),WM("col my-auto text-danger")(ya(n.validationActive)(da(t)(Ke)))])]),bodyClass:"t--cta-active",size:Lv.value})}}},d$=function(e){return Ns({cta:e,anonymousUserFirstName:"",anonymousUserLastName:"",anonymousUserEmail:"",referredUserFirstName:"",referredUserLastName:"",referredUserEmail:"",validationActive:!1})};var obe=Ma(Ve),ube=W(ca),Wv=it(wr(Ga)),Yb=un(tn)(Qn),aD=W(yn),tD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),rD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),oD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),uD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Xb=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Zb=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),e1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),n1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),ibe=function(){function e(){}return e.value=new e,e}(),m$=function(e){return function(n){return function(a){var t=function(o){return a(Ae.create(o))};if(n instanceof tD)return UW(e)(n.value0)(function(o){return t(Xb.create(o))});if(n instanceof rD)return qW(n.value0)(function(o){return t(Zb.create(o))});if(n instanceof oD)return YW(n.value0)(function(o){return t(e1.create(o))});if(n instanceof uD)return p$(e)(n.value0)(function(o){return t(n1.create(o))});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 61, column 29 - line 69, column 61): "+[n.constructor.name])}}},h$=function(e){return function(n){return function(a){var t=obe(ube(new wn(ibe.value)));if(n instanceof tD&&a instanceof Xb){if(a.value0 instanceof Ae)return Wv(function(o){return Ae.create(Xb.create(o))})(tD.create)(NW(e)(n.value0)(a.value0.value0));if(a.value0 instanceof wn)return Yb(t)(function(){return aD(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 76, column 5 - line 81, column 19): "+[a.value0.constructor.name])}if(n instanceof rD&&a instanceof Zb){if(a.value0 instanceof Ae)return Wv(function(o){return Ae.create(Zb.create(o))})(rD.create)(JW(n.value0)(a.value0.value0));if(a.value0 instanceof wn)return Yb(t)(function(){return aD(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 84, column 5 - line 90, column 19): "+[a.value0.constructor.name])}if(n instanceof oD&&a instanceof e1){if(a.value0 instanceof Ae)return Wv(function(o){return Ae.create(e1.create(o))})(oD.create)(XW(n.value0)(a.value0.value0));if(a.value0 instanceof wn)return Yb(t)(function(){return aD(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 93, column 5 - line 98, column 19): "+[a.value0.constructor.name])}if(n instanceof uD&&a instanceof n1){if(a.value0 instanceof Ae)return Wv(function(o){return Ae.create(n1.create(o))})(uD.create)(_$(e)(n.value0)(a.value0.value0));if(a.value0 instanceof wn)return Yb(t)(function(){return aD(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 101, column 5 - line 107, column 19): "+[a.value0.constructor.name])}return aD(n)}}},D$=function(e){return function(n){return e instanceof tD&&n instanceof sl?jW(e.value0)(n.value0):e instanceof oD&&n instanceof vl?ZW(e.value0)(n.value0):e instanceof rD&&n instanceof fl?WW(e.value0)(n.value0):e instanceof uD&&n instanceof _l?v$(e.value0)(n.value0):!1}},g$=function(e){if(e instanceof sl)return Wv(function(n){return Ae.create(Xb.create(n))})(tD.create)(OW(e.value0));if(e instanceof fl)return Wv(function(n){return Ae.create(Zb.create(n))})(rD.create)($W(e.value0));if(e instanceof vl)return Wv(function(n){return Ae.create(e1.create(n))})(oD.create)(e$(e.value0));if(e instanceof _l)return Wv(function(n){return Ae.create(n1.create(n))})(uD.create)(d$(e.value0));throw new Error("Failed pattern match at Livestream.Ctas.Display (line 49, column 8 - line 58, column 66): "+[e.constructor.name])};var R$=Ht(Y),a1=Te(me),lbe=Vo(Y),cbe=Rv(Y)()(),sbe=ep(me),vbe=fo()(),$M=Ji(nt),fbe=Xn(vo),y$=Wn(Y)()(),w$=Xn(ga),_be=yp(We),pbe=Bn(Ve),dbe=Es(gr),mbe=Ou(),hbe=ne(Ze),N_=W(yn),Dbe=bf(nt),j_=un(tn)(Qn),gbe=xt(Nr),zM=W(ca),Rbe=ko(ca)(fn),ybe=lr(ca),b$=Ma(Ve),wbe=it(wr(Ga)),rd=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),VM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),QM=function(){function e(){}return e.value=new e,e}(),E$=function(){function e(){}return e.value=new e,e}(),KM=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),I$=function(e){return function(n){return function(a){var t=Se([R$("text-center")("The host just asked a poll question!"),R$("text-center")("To participate in live polls, please introduce yourself:"),Vp({cancelButton:new T({text:"Not now",click:a(new rd({keepShowingPolls:!1}))}),autoFocus:!0})(e)(n.registration)(function(i){return a(KM.create(i))}),a1("small mt-3")([Yp(e),a1("mt-2")([Ke("After submitting, you\u2019ll be able to answer all "),lbe("")("future"),Ke(" poll questions in this stream!")])])]),o=Se([cbe("font-weight-bold fw-bold")({id:Ei})(n.poll.question),a1("d-flex flex-column ml-4")(b0(function(i){return function(l){return sbe("form-check-label mb-2")([vbe("form-check-input mt-2 t--option")({checked:$M(i)(n.selected),onChange:fbe(a)(function(s){return new VM(i)}),type:function(){return n.poll.multiSelect?"checkbox":"radio"}()}),Ke(l)])}})(n.poll.options)),a1("d-flex justify-content-start mt-6")([y$("btn btn-primary px-4 mr-3 t--submit")({onClick:w$(a)(QM.value),disabled:si(n.selected)})("Submit answer"),y$("btn btn-outline-primary px-4 d-flex align-items-center t--skip")({onClick:w$(a)(E$.value)})("Do it later")])]),u=function(){if(e.user instanceof T)return"t--poll-active";if(e.user instanceof M)return"t--poll-registration-form";throw new Error("Failed pattern match at Livestream.Polls.DisplayPoll (line 62, column 18 - line 64, column 45): "+[e.user.constructor.name])}();return _be(u)(function(){if(e.user instanceof T)return o;if(e.user instanceof M)return t;throw new Error("Failed pattern match at Livestream.Polls.DisplayPoll (line 58, column 5 - line 60, column 34): "+[e.user.constructor.name])}())}}},T$=function(e){return function(n){return function(a){var t=function(o){return pbe(dbe("Livestream: Poll Response")(Zc(Fv(e.conference))(mbe({livestream_poll_id:hbe(n.poll.id),livestream_poll_question:n.poll.question,livestream_poll_skipped:function(){return o.skipped?"true":""}(),livestream_poll_multiselect:function(){return n.poll.multiSelect?"true":"false"}(),livestream_poll_response:o.option}))))};if(a instanceof rd)return N_(n);if(a instanceof VM&&n.poll.multiSelect)return N_({poll:n.poll,registration:n.registration,selected:function(){var o=$M(a.value0)(n.selected);return o?Dbe(a.value0)(n.selected):qo(a.value0)(n.selected)}()});if(a instanceof VM)return N_({poll:n.poll,registration:n.registration,selected:[a.value0]});if(a instanceof QM&&si(n.selected))return N_(n);if(a instanceof QM)return j_(Va(gbe(xC(n.poll)(n.selected))(function(o){return Nl(_c)("Error answering a Livestream poll")({poll_id:n.poll.id})(function(u){return zM(Ee)})})))(function(){return j_(Va(Rbe(b0(function(o){return function(u){return{idx:o,opt:u}}})(n.poll.options))(function(o){return ybe($M(o.idx)(n.selected))(t({skipped:!1,option:o.opt}))})))(function(){return j_(b$(zM(new rd({keepShowingPolls:!0}))))(function(){return N_(n)})})});if(a instanceof E$)return j_(Va(xC(n.poll)([])))(function(){return j_(Va(t({skipped:!0,option:""})))(function(){return j_(b$(zM(new rd({keepShowingPolls:!0}))))(function(){return N_(n)})})});if(a instanceof KM)return wbe(KM.create)(function(o){return{poll:n.poll,selected:n.selected,registration:o}})(Qp(n.registration)(a.value0));throw new Error("Failed pattern match at Livestream.Polls.DisplayPoll (line 114, column 24 - line 161, column 55): "+[a.constructor.name])}}},S$=function(e){return j_(Va(IO(e)))(function(){return N_({poll:e,selected:[],registration:Kp})})};var C$=un(tn),bbe=C$(_a),Ebe=Z(_a),F$=Bn(Ve),Ibe=ko(ca)(Pu),Tbe=Es(gr),G$=Ou(),Sbe=ne(Gg),Cbe=ne(Zu),t1=ne(Ze),gl=W(yn),M$=wr(Ga),A$=it(M$),L$=Z(Qn),P$=fr(M$),$v=C$(Qn),Fbe=we(nt),zv=W(aa),iD=jm(Ve),lD=k(ae),Gbe=k(Fu),cD=D0(fn),YM=Sa(),x$=Ii(YM(B({reflectSymbol:function(){return"poll_id"}})(on)(rn)))(Ve),Mbe=tl(Ve),Abe=we(Vt(Km)),Lbe=Ii(YM(B({reflectSymbol:function(){return"conference_id"}})(on)(rn)))(Ve),XM=we(Vt(nt)),ZM=Ii(YM(B({reflectSymbol:function(){return"id"}})(on)(rn)))(Ve),sD=function(){function e(){}return e.value=new e,e}(),od=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),vD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),ud=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),r1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),o1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),eA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),id=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),N$=function(e){return function(n){return function(a){if(n.stage instanceof sD)return $n;if(n.stage instanceof od)return I$(e)(n.stage.value0)(function(t){return a(ud.create(t))});if(n.stage instanceof vD)return m$(e)(n.stage.value0)(function(t){return a(r1.create(t))});throw new Error("Failed pattern match at Livestream.Live.VideoOverlay (line 96, column 3 - line 102, column 59): "+[n.stage.constructor.name])}}},Pbe=function(e){return function(n){return e instanceof vD?D$(e.value0)(n):!1}},xbe=function(){return function(e){return function(n){return function(a){return bbe(Kt(100))(function(){return Ebe(F$(yy(Ei)))(function(t){return Ibe(t)(function(o){return F$(function(){var i=cF(HS(o))(),l=h8({x:i.left+1,y:i.top+1})(),s=iF(HS(l))();return Tbe(n)(Zc(G$(a))(Zc(Fv(e.conference))(G$({livestream_popup_visible:Sbe(s===Ei)}))))()})})})})}}}},j$=xbe(),Nbe=function(e){var n=function(){return j$(e)("Livestream: CTA Popup Shown")},a=n();return function(t){if(t instanceof sl)return a({livestream_cta_target_conference_id:Cbe(t.value0.conferenceId)});if(t instanceof fl)return a({livestream_cta_id:t1(t.value0.id)});if(t instanceof vl)return a({livestream_cta_id:t1(t.value0.id),livestream_cta_title:t.value0.title,livestream_cta_url:t.value0.url});if(t instanceof _l)return a({livestream_cta_id:t1(t.value0.id),livestream_cta_title:t.value0.title});throw new Error("Failed pattern match at Livestream.Live.VideoOverlay (line 156, column 29 - line 173, column 8): "+[t.constructor.name])}},O$=function(e){return function(n){return function(a){if(a instanceof ud&&a.value0 instanceof rd)return gl({stage:sD.value,showPolls:a.value0.value0.keepShowingPolls});var t=function(o){if(a instanceof ud)return gl(n);if(a instanceof r1){if(a.value0 instanceof wn)return gl({showPolls:n.showPolls,stage:sD.value});var u=function(s){return gl(n)};return a.value0 instanceof Ae&&n.stage instanceof vD?A$(r1.create)(function(s){return{showPolls:n.showPolls,stage:new vD(s)}})(h$(e)(n.stage.value0)(a.value0.value0)):u(!0)}var u=function(l){if(a instanceof o1&&n.showPolls)return L$(P$(ud.create)(S$(a.value0)))(function(d){return $v(Va(j$(e)("Livestream: Poll Popup Shown")({livestream_poll_id:t1(a.value0.id)})))(function(){return gl({showPolls:n.showPolls,stage:new od(d)})})});if(a instanceof o1)return gl(n);var s=function(d){if(a instanceof eA||a instanceof id&&Pbe(n.stage)(a.value0))return gl(n);if(a instanceof id)return $v(Va(Nbe(e)(a.value0)))(function(){return L$(P$(r1.create)(g$(a.value0)))(function(y){return gl({showPolls:n.showPolls,stage:new vD(y)})})});throw new Error("Failed pattern match at Livestream.Live.VideoOverlay (line 104, column 1 - line 104, column 76): "+[a.constructor.name])};if(a instanceof eA){if(n.stage instanceof od){var R=n.stage.value0.poll.id===a.value0.pollId;return R?gl({showPolls:n.showPolls,stage:sD.value}):s(!0)}return s(!0)}return s(!0)};if(a instanceof o1){if(n.stage instanceof od){var i=n.stage.value0.poll.id===a.value0.id;return i?gl(n):u(!0)}return u(!0)}return u(!0)};return a instanceof ud&&n.stage instanceof od?A$(ud.create)(function(o){return{showPolls:n.showPolls,stage:new od(o)}})(T$(e)(n.stage.value0)(a.value0)):t(!0)}}},U$=function(e){var n=function(u){return u instanceof _l?zv(u.value0.id):M.value},a=function(u){return u instanceof fl?zv(u.value0.id):M.value},t=function(u){return u instanceof vl?zv(u.value0.id):M.value},o=function(u){return u instanceof sl?zv(u.value0.conferenceId):M.value};return $v(iD(function(u){return lD(Gbe(o1.create)(function(i){return i.poll}))(cD(function(){var i=Fbe(u.poll_id);return function(l){return i(function(s){return s.poll.id}(l))}}())(e.conference.polls))})(x$(e.pusher.dataChannel)("show-poll")))(function(){return $v(Mbe(function(u){return new eA({pollId:u.poll_id})})(x$(e.pusher.dataChannel)("hide-poll")))(function(){return $v(iD(function(u){return lD(id.create)(cD(function(){var i=Abe(zv(u.conference_id));return function(l){return i(o(l))}}())(e.ctas))})(Lbe(e.pusher.dataChannel)("show-event-cta")))(function(){return $v(iD(function(u){return lD(id.create)(cD(function(){var i=XM(zv(u.id));return function(l){return i(t(l))}}())(e.ctas))})(ZM(e.pusher.dataChannel)("show-general-cta")))(function(){return $v(iD(function(u){return lD(id.create)(cD(function(){var i=XM(zv(u.id));return function(l){return i(a(l))}}())(e.ctas))})(ZM(e.pusher.dataChannel)("show-featured-sps-cta")))(function(){return $v(iD(function(u){return lD(id.create)(cD(function(){var i=XM(zv(u.id));return function(l){return i(n(l))}}())(e.ctas))})(ZM(e.pusher.dataChannel)("show-referral-cta")))(function(){return gl({stage:sD.value,showPolls:!0})})})})})})})};var jbe=Wl(),nA=Te(me),Obe=Ht(We),Ube=Ua(me),kbe=Qa(Y),k$=yu()(),B$=Ht(Y),Bbe=$t(Y),u1=Wn(Y)()(),Hbe=sr(zo),qbe=un(tn),aA=Xn(ga),H$=qbe(Qn),Jbe=rH(),tA=W(yn),q$=Z(en),Wbe=Ys(UP),$be=Qu(sT),zbe=we(Iy),Vbe=we(Vs),Qbe=ls()(),J$=function(){function e(){}return e.value=new e,e}(),rA=function(){function e(){}return e.value=new e,e}(),W$=function(){function e(){}return e.value=new e,e}(),oA=function(){function e(){}return e.value=new e,e}(),uA=function(){function e(){}return e.value=new e,e}(),i1=function(e){return function(n){return jbe({onDismiss:n(new wn(uA.value)),bodyClass:"t--livestreams-update-network-settings-modal",body:function(){if(e.modalView instanceof J$)return nA("text-center")([ya(e.confirmConferenceRegistration)(Obe("mb-4")(Ube("badge badge-soft-primary bg-primary-soft")([kbe("fe fe-check mr-1")(""),Ke("You\u2019re registered!")]))),k$("my-4")({src:"/img/network/counselor.svg",height:"76",width:"91"}),B$("")("Connect with colleges when you attend or register for their livestreams?"),Bbe("text-secondary")("Connecting with colleges puts you on their radar and introduces you to admissions officers and current students"),nA("mx-md-6 mt-4")([u1("btn btn-primary w-100 t--livestream-opt-into-auto-connect")({onClick:Hbe(function(){return n(new Ae(W$.value))(),n(new Ae(oA.value))()})})("Yes, always connect"),u1("btn btn-outline-primary w-100 mt-3 t--livestream-connect-with-school")({onClick:aA(n)(new Ae(oA.value))})("Only connect with "+e.school.name),u1("btn btn-link mt-3")({onClick:aA(n)(new wn(uA.value))})("Close")])]);if(e.modalView instanceof rA)return nA("text-center")([k$("mt-4")({src:"/img/livestreams/network-settings-modal/connection-sent.png",height:"42",width:"42"}),B$("")("Connection request sent!"),u1("mt-4 btn btn-primary t--livestream-network-settings-modal-close")({onClick:aA(n)(new wn(uA.value))})("Close")]);throw new Error("Failed pattern match at Livestream.NetworkSettingsModal (line 81, column 13 - line 112, column 12): "+[e.modalView.constructor.name])}()})}},l1=function(e){return function(n){if(n instanceof Ae){if(n.value0 instanceof W$)return H$(Va(Jbe({publishScope:bi.value,publishContext:AG.value,autoRequestFromLivestreams:!0,livestreamConference:e.conference})))(function(){return tA({conference:e.conference,confirmConferenceRegistration:e.confirmConferenceRegistration,school:e.school,modalView:rA.value})});if(n.value0 instanceof oA)return H$(Va(CU(e.school.id)(e.conference.id)))(function(){return tA({conference:e.conference,confirmConferenceRegistration:e.confirmConferenceRegistration,school:e.school,modalView:rA.value})});throw new Error("Failed pattern match at Livestream.NetworkSettingsModal (line 59, column 31 - line 71, column 44): "+[n.value0.constructor.name])}if(n instanceof wn)return tA(e);throw new Error("Failed pattern match at Livestream.NetworkSettingsModal (line 58, column 1 - line 58, column 55): "+[e.constructor.name,n.constructor.name])}},c1=function(e){return function(n){var a=ke(!1)(q$(e.dismissedNetworkSettingsModalAt)(function(o){return new T(Wbe($be(nC(Ee))(o))(30))})),t=function(o){return[n.rcr834NetworkSettingsModal,zbe(o.publishScope)(bi.value),!o.autoRequestFromLivestreams,e.hasAccessToNetwork,!a]};return ke(!1)(q$(e.profile)(function(o){return new T(JI(Vbe(!0))(t(o)))}))}},s1=function(e){return Qbe(e)({modalView:J$.value})};var fD=function(){function e(){}return e.value=new e,e}(),ld=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),_D=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),v1=function(){function e(){}return e.value=new e,e}();var $$=un(tn),z$=$$(Qn),iA=Ma(Ve),Kbe=$$(_a),lA=W(ca),f1=W(yn),V$=function(e){return function(n){return function(a){return function(t){return a.throttleState instanceof fD&&t instanceof _D?z$(iA(Kbe(Kt(a.delay))(function(){return lA(e(v1.value))})))(function(){return f1(n({delay:a.delay,throttleState:new ld(t.value0)}))}):a.throttleState instanceof ld&&t instanceof _D?f1(n({delay:a.delay,throttleState:new ld(t.value0)})):a.throttleState instanceof ld&&t instanceof v1?z$(iA(lA(a.throttleState.value0)))(function(){return f1(n({delay:a.delay,throttleState:fD.value}))}):f1(n(a))}}}},Q$=function(e){return function(n){return iA(lA(e(new _D(n))))}},K$=function(e){return{throttleState:fD.value,delay:e}};var _1=Te(Y),p1=Te(me),Ybe=Ht(Y),js=ne(Ze),Xbe=io(ar),Y$=Te(We),Zbe=or(Y)()(),e1e=Vo(Y),n1e=Ua(Y),a1e=zf(We),t1e=QN(me)()(),X$=vs(na),d1=Wn(Y)()(),cA=Xn(ga),Z$=Ji(nt),ez=zf(me),m1=cs(Y),r1e=cs(We),o1e=cs(me),u1e=Z0(me),i1e=K0(me),cd=Y0(Y),l1e=X0(me),h1=pe(ze),c1e=Ho(na),pD=un(tn)(Qn),sA=Ma(Ve),s1e=xt(Nr),nz=W(ca),Vv=W(yn),vA=k(Ga),v1e=we(z8),az=ul(na)(fn),f1e=kg(na),_1e=an(Rt),p1e=bf(nt),d1e=tl(Ve),m1e=Yy(Ve),D1=function(){function e(){}return e.value=new e,e}(),tz=function(){function e(){}return e.value=new e,e}(),rz=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),oz=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),fA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),uz=function(){function e(){}return e.value=new e,e}(),iz=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),lz=function(){function e(){}return e.value=new e,e}(),_A=function(){function e(){}return e.value=new e,e}(),cz=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),pA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),sz=function(e){return function(n){return function(a){if(e.conference.polls.length===0)return $n;var t=function(){if(n.stage instanceof D1)return $n;if(n.stage instanceof tz)return _1("position-absolute-fullsize d-flex align-items-center justify-content-center bg-semi-transparent-white")("Switching...");throw new Error("Failed pattern match at Livestream.Polls.LaunchPolls (line 185, column 24 - line 190, column 25): "+[n.stage.constructor.name])}(),o=p1("d-flex flex-nowrap align-items-baseline")([Ybe("")("Polls"),_1("text-muted ml-3 small")("Polls will be shown to viewers "+(js(e.videoLagSeconds)+" seconds after you launch them, to account for the audio/video delay"))]),u=function(s){return function(R){return function(d){var y=function(I){return function(b){var S=function(){if(R===0)return"0%";if($e)return js(Xbe(100*b|0)(R))+"%";throw new Error("Failed pattern match at Livestream.Polls.LaunchPolls (line 181, column 13 - line 183, column 69): "+[])}();return p1("row align-items-center bg-light-grey mb-1 py-2 t--poll-response-option")([_1("col-7 d-flex justify-content-end")(I),Y$("col-4")(Y$("progress")(Zbe("progress-bar")({style:ot({width:S})})(""))),p1("col-1")([e1e("")(js(b)),n1e("text-secondary text-nowrap")(" ("+(S+")"))])])}};return a1e("t--poll-responses-"+js(s.id))(t1e("py-0")({colSpan:6})(UI(y)(s.options)(d.optionCounts)))}}},i=function(s){var R=ke(s.status)(X$(s.poll.id)(n.statuses)),d=d1("btn btn-white btn-sm px-4 t--open")({onClick:cA(a)(new rz(s.poll))})("Launch poll");if(R instanceof ys)return d;if(R instanceof gc)return Se([d1("btn btn-success btn-sm px-4 mr-3")({disabled:!0})("Poll LIVE"),d1("btn btn-danger btn-sm px-4 t--close")({onClick:cA(a)(new oz(s.poll))})("Close poll")]);if(R instanceof ws)return d;throw new Error("Failed pattern match at Livestream.Polls.LaunchPolls (line 143, column 17 - line 155, column 21): "+[R.constructor.name])},l=function(s){var R=Z$(s.poll.id)(n.expandedResponses),d=X$(s.poll.id)(n.responses),y=bn(0)(function(S){return S.answered})(d),I=bn(0)(function(S){return S.seen})(d),b=bn(0)(function(S){return S.skipped})(d);return Se([ez("t--poll t--poll-"+js(s.poll.id))([m1("pt-3")(function(){var S=Ct(s.poll.autoDisplayMinutesFromStart);return S?"\u23F0 ":""}()+s.poll.question),r1e("text-nowrap")(i(s)),m1("t--shown")(js(I)),o1e("t--answers")([Ke(js(y)),d1("btn btn-sm btn-white ml-2 py-0 px-1 "+("fe fe-chevron-"+function(){return R?"up":"down t--expand-responses"}()))({onClick:cA(a)(new iz(s.poll.id))})("")]),m1("t--skipped")(js(b)),m1("t--pending")(js((I-y|0)-b|0))]),ya(R)(da(d)(u(s.poll)(y)))])};return Se([o,p1("t--polls position-relative")([da(n.error)(function(s){return _1("alert alert-danger")(s)}),u1e("table table-sm mb-0")([i1e("")([ez("")([cd("")("Question"),cd("")("Actions"),cd("")("# saw poll"),cd("")("# answered"),cd("")("# skipped"),cd("")("# not responded")])]),l1e("")(h1(c1e(function(s){return-function(R){return R.poll.id}(s)|0})(e.conference.polls))(l))]),t])])}}},vz=function(e){return function(n){var a=function(t){return pD(sA(s1e(t)(function(o){return nz(uz.value)})))(function(){return Vv({expandedResponses:n.expandedResponses,responseThrottle:n.responseThrottle,responses:n.responses,statuses:n.statuses,stage:tz.value,error:M.value})})};return function(t){if(t instanceof rz)return a(vA(fA.create)(PC(t.value0)(gc.value)));if(t instanceof oz)return a(vA(fA.create)(PC(t.value0)(ws.value)));if(t instanceof fA){var o=h1(iu(function(){var u=v1e(gc.value);return function(i){return u(function(l){return l.status}(i))}}())(t.value0))(function(u){return u.pollId});return Vv({error:n.error,responseThrottle:n.responseThrottle,responses:n.responses,statuses:az(h1(t.value0)(function(u){return new Dn(u.pollId,u.status)})),expandedResponses:f1e(_1e(n.expandedResponses)(o)),stage:D1.value})}if(t instanceof uz)return Vv({expandedResponses:n.expandedResponses,responseThrottle:n.responseThrottle,responses:n.responses,statuses:n.statuses,stage:D1.value,error:new T("That didn't work for some reason, try again")});if(t instanceof iz)return Vv({error:n.error,responseThrottle:n.responseThrottle,responses:n.responses,stage:n.stage,statuses:n.statuses,expandedResponses:function(){var u=Z$(t.value0)(n.expandedResponses);return u?p1e(t.value0)(n.expandedResponses):qo(t.value0)(n.expandedResponses)}()});if(t instanceof lz)return pD(Q$(pA.create)(_A.value))(function(){return Vv(n)});if(t instanceof _A)return pD(sA(vA(cz.create)(xO(e.conference.id))))(function(){return Vv(n)});if(t instanceof cz)return Vv({error:n.error,expandedResponses:n.expandedResponses,responseThrottle:n.responseThrottle,stage:n.stage,statuses:n.statuses,responses:az(h1(t.value0)(function(u){return new Dn(u.pollId,u.responses)}))});if(t instanceof pA)return V$(pA.create)(function(u){return{error:n.error,expandedResponses:n.expandedResponses,responses:n.responses,stage:n.stage,statuses:n.statuses,responseThrottle:u}})(n.responseThrottle)(t.value0);throw new Error("Failed pattern match at Livestream.Polls.LaunchPolls (line 202, column 22 - line 248, column 98): "+[t.constructor.name])}}},fz=function(e){return pD(d1e(hn(lz.value))(m1e(e.pusher.dataChannel)("poll-responses-changed")))(function(){return pD(sA(nz(_A.value)))(function(){return Vv({statuses:fs,responses:fs,expandedResponses:[],responseThrottle:K$(500),stage:D1.value,error:M.value})})})};var _z=yu()(),pz=Te(me),dz=Ht(Y),mz=Hr(Y),hz=_z("img-fluid mb-6")({src:"/img/logo-white.svg",style:ot({width:"5em"})}),g1=function(e){return pz(e+` t--splashscreen position-absolute-fullsize d-flex flex-column align-items-center justify-content-around bg-dark text-white `)},dD=function(e){return g1("")([dz("text-center")(e)])},dA=g1("t--splashscreen-intro")([Te(We)("text-center mt-7")(mz("")("The recording will load in a moment.")),hz]),R1=g1("px-4 px-md-6 t--splashscreen-intro")([_z("img-fluid")({src:"/img/illustrations/livestreams/2022-02-intro.svg"})]),Dz=g1("t--splashscreen-complete")([pz("text-center mt-7")([mz("")("The event is now over."),dz("")("Thank you for attending!"),Ku(Y)("")("A recording will be available to watch shortly.")]),hz]);var y1=e=>e.play();var Qv=Cu(gz());$a();var Rz=e=>{let[n,a]=ka.useState(),[t,o]=ka.useState(),u=ka.useRef();return u.current=e,Gt(()=>{if(!t)return Qv.default.isSupported()?a(h1e(e.videoStreamUrl,e.videoElementId,u)):e.onNotSupported(),o(!0),()=>{n&&n.destroy()}}),null},h1e=(e,n,a)=>{let t=document.getElementById(n);return t?(hls=new Qv.default,a.current.onInstanceCreated&&a.current.onInstanceCreated(hls),hls.on(Qv.default.Events.ERROR,function(o,u){if(a.current.onError&&a.current.onError("HLS error: "+u.type,u),u.fatal)switch(u.type){case Qv.default.ErrorTypes.MEDIA_ERROR:hls.recoverMediaError();break;default:hls.destroy(),a.current.onCriticalFail&&a.current.onCriticalFail(u.type);break}}),hls.on(Qv.default.Events.MEDIA_ATTACHED,()=>hls.loadSource(e)),hls.on(Qv.default.Events.MANIFEST_PARSED,()=>a.current.onReady&&a.current.onReady()),hls.on(Qv.default.Events.INIT_PTS_FOUND,(o,u)=>a.current.onInitialPts&&a.current.onInitialPts({initPTS:u.initPTS})),hls.attachMedia(t),hls):(a.current.onCriticalFail&&a.current.onCriticalFail("Couldn't find element #"+n),null)};var D1e=mv();var yz=function(){return function(){return D1e(Rz)}};$a();var zl={PRIMARY:"#008CFD",SECONDARY:"#6E84A3",WHITE:"#FFF",GRAY_300:"#E3EBF6"};var gD=Cu(Cz()),Fz=4,Q1e=({trackColor:e,background:n})=>({props:a,children:t})=>ka.createElement("div",Object.assign({},a,{style:Object.assign({},a.style,{height:`${Fz}px`,borderRadius:`${Fz*2}px`,background:n||e})}),...t),K1e=({horizontal:e})=>({props:n,isDragged:a})=>ka.createElement("svg",Object.assign({},n,{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",fill:"none",viewBox:"0 0 18 18"}),ka.createElement("circle",{cx:"9",cy:"9",r:"8.5",fill:a?zl.SECONDARY:zl.WHITE,stroke:zl.SECONDARY}),ka.createElement("path",{stroke:a?zl.WHITE:zl.SECONDARY,d:e?"M7.5 6L7.5 12":"M6 7.5L12 7.5"}),ka.createElement("path",{stroke:a?zl.WHITE:zl.SECONDARY,d:e?"M10.5 6L10.5 12":"M6 10.5L12 10.5"})),Gz=e=>ka.createElement(gD.Range,{step:e.step,min:e.min,max:e.max,values:[e.value],onChange:([n])=>e.onChange(n),onFinalChange:([n])=>e.onFinalChange&&e.onFinalChange(n),renderTrack:Q1e({trackColor:e.trackColor||zl.GRAY_300,background:e.fillBefore?(0,gD.getTrackBackground)({values:[e.value],colors:[zl.PRIMARY,zl.GRAY_300],min:e.min,max:e.max}):void 0}),renderThumb:K1e({horizontal:!0})});var Y1e=mv(),Mz={CanPassToJavaScript0:function(){},CanReceiveFromJavaScript1:function(){return iv}};var Az=function(e){return function(){return function(){return Y1e(Gz)}}};var X1e=or(We)()(),Z1e=Az(Mz)()(),eEe=Xn(vo),nEe=Wn(We)()(),aEe=Xn(ga),Lz=Te(me),tEe=Ua(Y),I1=Ma(Ve),gA=W(ca),Pz=un(tn),rEe=tt(k0),Mc=W(yn),oEe=Q0(Ve),RA=Bn(Ve),uEe=k(ae),iEe=sc(O0),lEe=Pz(_a),Kv=Pz(Qn),cEe=lr(yn),sEe=Z(_a),vEe=Xl(Vu),fEe=lr(rt),yA=function(){function e(){}return e.value=new e,e}(),wA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),bA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),xz=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),EA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Nz=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),jz=function(){function e(){}return e.value=new e,e}(),_Ee=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),Oz=function(e){return function(n){if(e.videoState instanceof M)return $n;if(e.videoState instanceof T){var a=X1e("")({style:ot({minWidth:"6rem",width:"6rem"})})(Z1e({value:function(){return e.videoState.value0.muted?0:e.videoState.value0.volume}(),min:0,max:1,step:.05,onChange:eEe(n)(function(i){return Ae.create(wA.create(i))})})),t=function(){if(e.videoState.value0.muted)return"fe-volume-x";if($e)return"fe-volume-2";throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 128, column 5 - line 130, column 34): "+[])}(),o=nEe("btn large px-3 py-1 mr-3 text-white fe "+t)({onClick:aEe(n)(new Ae(yA.value))})($n),u=Lz("d-flex align-items-center text-white px-3")([Ke("LIVE"),tEe("text-danger x-large ml-2 mt-n1")("\u25CF")]);return Lz("mb-2 w-100 d-flex align-items-center bg-semi-transparent-black "+function(){return e.visible?"":"hidden"}())([ya(e.config.liveIndicator)(u),ya(e.config.mute)(o),ya(e.config.volume)(a)])}throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 105, column 1 - line 105, column 50): "+[e.constructor.name,n.constructor.name])}},Uz=function(e){return Ae.create(bA.create(e))},kz=function(e){return I1(gA(new wn(new _Ee(function(n){return function(){return e(n)(),new Ae(new bA(n))}}))))},T1=function(){return new Ae(new EA(!0))}(),Bz=function(e){return{config:e,videoState:M.value,visible:!1,visibilityExpiration:rEe}},Hz=2e3,qz=function(e){return function(n){if(n instanceof wn)return Mc(e);if(n instanceof Ae){var a=oEe(RA(function(){var i=Xu();return uEe(function(l){return Ae.create(Nz.create(l))})(iEe(Hz)(i))})),t=lEe(Kt(Hz))(function(){return gA(new Ae(jz.value))}),o=function(u){if(n.value0 instanceof yA)return Mc(e);var i=function(l){if(n.value0 instanceof wA)return Mc(e);if(n.value0 instanceof bA)return Kv(I1(RA(function(){var R=$S(n.value0.value0)(),d=JS(n.value0.value0)();return new Ae(new xz({muted:R,volume:d}))})))(function(){return Mc(e)});if(n.value0 instanceof xz)return Mc({config:e.config,visibilityExpiration:e.visibilityExpiration,visible:e.visible,videoState:new T(n.value0.value0)});if(n.value0 instanceof EA)return Kv(cEe(n.value0.value0)(a))(function(){return Kv(I1(t))(function(){return Mc({config:e.config,videoState:e.videoState,visibilityExpiration:e.visibilityExpiration,visible:n.value0.value0})})});if(n.value0 instanceof Nz)return Mc({config:e.config,videoState:e.videoState,visible:e.visible,visibilityExpiration:n.value0.value0});if(n.value0 instanceof jz)return Kv(I1(sEe(RA(Xu))(function(s){var R=vEe(s)(e.visibilityExpiration);return R?gA(new Ae(new EA(!1))):t})))(function(){return Mc(e)});throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 143, column 1 - line 143, column 55): "+[n.value0.constructor.name])};return n.value0 instanceof wA&&e.videoState instanceof T?Kv(a)(function(){return Kv(kz(function(l){return function(){return fEe(n.value0.value0>0)(n_(!1)(l))(),WS(n.value0.value0)(l)()}}))(function(){return Mc({config:e.config,visibilityExpiration:e.visibilityExpiration,visible:e.visible,videoState:new T({muted:e.videoState.value0.muted,volume:n.value0.value0})})})}):i(!0)};return n.value0 instanceof yA&&e.videoState instanceof T?Kv(a)(function(){return Kv(kz(n_(!e.videoState.value0.muted)))(function(){return Mc({config:e.config,visibilityExpiration:e.visibilityExpiration,visible:e.visible,videoState:new T({volume:e.videoState.value0.volume,muted:!e.videoState.value0.muted})})})}):o(!0)}throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 143, column 1 - line 143, column 55): "+[e.constructor.name,n.constructor.name])}},Jz=function(e){if(e instanceof T)return!1;if(e instanceof M)return!0;throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 212, column 1 - line 212, column 37): "+[e.constructor.name])};var Wz=e=>n=>a=>()=>e.then(a,n),$z=e=>e instanceof Error,zz=e=>e===null?"null":typeof e=="undefined"?"undefined":e.toString();var pEe=W(Qc(cr)),dEe=A0(cr),mEe=pn(dn),Vz=ma(nR(iR)(cr)),hEe=Xc(cr),DEe=k(eR(Jc)),gEe=lm(cr),REe=Rg(zn),yEe=Xa(Dx);var wEe=function(e){var n=function(a){if($z(a))return pEe(a);if($e)return dEe(new um(""));throw new Error("Failed pattern match at Utils.Promise (line 53, column 5 - line 55, column 43): "+[a.constructor.name])};return Ut(function(a){return cu("Promise failed: "+zz(e))})(mEe)(Zm(Vz(n(e))(Vz(hEe("Error")(e))(DEe(cu)(gEe(e))))))},S1=function(e){return fv(function(n){return REe(yEe)(Wz(e)(function(a){return n(Me.create(wEe(a)))()})(function(a){return n(Le.create(a))()}))})};var bEe=Z(en),EEe=Te(We),IA=sr(gv),RD=Z(tr),TA=ev(rt)(Pu),C1=Xn(ga),Qz=zR(Y)()(),IEe=yz()(),TEe=W(rt),yD=Xn(vo),Kz=or(We)()(),SEe=Wn(me)()(),CEe=Qa(Y),FEe=Te(me),Yz=un(tn),GEe=Is(Ve)(),MEe=ci(fn)(st),AEe=we(Vt(nt)),sd=Yz(_a),LEe=Ws(ca),PEe=Pr(q0),ao=W(ca),Xz=Bn(Ve),Zz=xt(Nr),eV=pI(_a),Jr=W(yn),to=Yz(Qn),bu=Ma(Ve),nV=k(Ga),aV=Q0(Ve),tV=k(zn),xEe=it(wr(Ga)),NEe=k(ae),jEe=pe(ae),rV=an(jP),oV=function(){function e(){}return e.value=new e,e}(),uV=function(){function e(){}return e.value=new e,e}(),wD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),iV=function(){function e(){}return e.value=new e,e}(),vd=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),lV=function(){function e(){}return e.value=new e,e}(),cV=function(){function e(){}return e.value=new e,e}(),sV=function(){function e(){}return e.value=new e,e}(),SA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),CA=function(){function e(){}return e.value=new e,e}(),F1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),G1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),M1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),vV=function(){function e(){}return e.value=new e,e}(),FA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),GA=function(){function e(){}return e.value=new e,e}(),fV=function(){function e(){}return e.value=new e,e}(),_V=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),U_=function(){function e(){}return e.value=new e,e}(),Ac=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),A1=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),MA=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),bD=function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e}(),AA=function(e){var n=e.Monad0(),a=Z(n.Bind1()),t=Bn(e),o=W(n.Applicative0());return function(u){return function(i){return function(l){return a(t(yy(u.videoId)))(function(s){return bn(o(i.whenNotFound))(l)(bEe(s)(s8))})}}}},pV=AA(gr),LA=AA(Ve),dV=function(e){var n=AA(e);return function(a){return n(a)({whenNotFound:Ee})}},OEe=dV(gr),UEe=dV(Ve),L1=function(e){return function(n){return function(a){var t=function(){var S=EEe("position-absolute-fullsize py-6 d-flex align-items-center justify-content-around");if(n.stage instanceof iV)return S(e.errorScreen("It appears that video playback is not supported in your browser."));if(n.stage instanceof lV)return S(e.errorScreen("The video didn't load correctly, try refreshing the page."));if(n.stage instanceof wD)return S(e.introScreen);if(n.stage instanceof vd)return $n;throw new Error("Failed pattern match at Livestream.VideoPlayer (line 253, column 20 - line 264, column 16): "+[n.stage.constructor.name])}(),o=function(){return n.stage instanceof wD?n.stage.value0.reset:!1}(),u=IA(function(S){return RD(Ry(S))(TA(function(L){return a(new Ae(new MA({time:L})))}))}),i=IA(function(S){return RD(Ry(S))(TA(function(L){return a(new Ae(new A1({playing:!0,time:L})))}))}),l=function(S){return a(wn.create(S))},s=IA(function(S){return RD(Ry(S))(TA(function(L){return l(new FA(L))}))}),R=C1(l)(vV.value),d=Se([Qz("w-100 t--real-video")({id:n.videoId,controls:Tt(n.customControls),onVolumeChange:R,onTimeUpdate:u,onPlay:i,onPause:s})(""),ya(!o)(IEe({videoStreamUrl:e.watchUrl,videoElementId:n.videoId,onNotSupported:l(cV.value),onError:function(S,L){return Ee},onCriticalFail:yD(l)(function(S){var L=S==="networkError";return L?CA.value:new F1("HLS player crashed")}),onReady:l(new G1({autoPlay:e.autoPlay})),onInitialPts:yD(l)(function(S){return new _V(S.initPTS)})}))]),y=function(){return n.stage instanceof vd&&n.stage.value0.unmuteOverlay?Kz("position-absolute-fullsize d-flex align-items-center justify-content-center t--unmute-overlay")({style:ot({pointerEvents:"none"})})(SEe("btn btn-sm btn-light border-dark px-4 d-flex align-items-center")({onClick:C1(l)(fV.value),style:ot({pointerEvents:"all"})})([Ke("click for sound"),CEe("fe fe-volume-2 ml-2")("")])):$n}(),I=function(S){return Kz("position-absolute-fullsize d-flex align-items-end t--controls-overlay")({onMouseMove:yD(l)(function(L){return new Ac(T1)}),onMouseDown:yD(l)(function(L){return new Ac(T1)}),onTouchStart:yD(l)(function(L){return new Ac(T1)})})(Oz(S)(function(L){return l(Ac.create(L))}))},b=Qz("w-100 t--real-video")({id:n.videoId,controls:Tt(n.customControls),playsInline:!0,onVolumeChange:R,onTimeUpdate:u,onPlay:i,onPause:s,onLoadedMetadata:C1(l)(new G1({autoPlay:e.autoPlay})),onError:C1(l)(CA.value),src:function(){return o?"":e.watchUrl}()})("");return FEe("position-relative w-100")([function(){if(n.support instanceof oV)return d;if(n.support instanceof uV)return b;throw new Error("Failed pattern match at Livestream.VideoPlayer (line 175, column 7 - line 177, column 40): "+[n.support.constructor.name])}(),da(n.customControls)(I),ya(n.allowSound)(y),t])}}},kEe=function(e){var n=Bn(e.MonadEffect0());return function(a){return n(function(){return OEe(a)(n_(!1))(),GA.value})}},BEe=kEe(w8),PA=function(e){return GEe("Livestream: Error")({livestream_error_message:e})},mV=function(e){return pV(e)({whenNotFound:!1})(qS)},HEe=function(e){return Bn(e)(function(){var a=RD(RD(Yu)(YS))(KS)();return MEe(function(t){return AEe(Tj(t)(a))(new T(0))})(["iPad","iPod","iPhone"])})},hV=HEe(Ve),qEe=function(e){var n=function(t){return sd(LEe(e.allowSound)(PEe(cu("Skipping attempt to play unmuted because sound was programmatically disallowed"))))(function(){return sd(S1(y1(t)))(function(){return ao(new M1({unmuteOverlay:!1}))})})},a=function(t){return sd(Xz(n_(!0)(t)))(function(){return sd(S1(y1(t)))(function(){return ao(new M1({unmuteOverlay:!0}))})})};return LA(e)({whenNotFound:new F1("