var Purs_EntryPoints_Livestream_Livestream=(()=>{var qre=Object.create;var Zw=Object.defineProperty;var $re=Object.getOwnPropertyDescriptor;var Wre=Object.getOwnPropertyNames;var xre=Object.getPrototypeOf,jre=Object.prototype.hasOwnProperty;var zre=(e,n)=>()=>(e&&(n=e(e=0)),n);var He=(e,n)=>()=>(n||e((n={exports:{}}).exports,n),n.exports),J4=(e,n)=>{for(var a in n)Zw(e,a,{get:n[a],enumerable:!0})},q4=(e,n,a,t)=>{if(n&&typeof n=="object"||typeof n=="function")for(let r of Wre(n))!jre.call(e,r)&&r!==a&&Zw(e,r,{get:()=>n[r],enumerable:!(t=$re(n,r))||t.enumerable});return e};var pl=(e,n,a)=>(a=e!=null?qre(xre(e)):{},q4(n||!e||!e.__esModule?Zw(a,"default",{value:e,enumerable:!0}):a,e)),Ng=e=>q4(Zw({},"__esModule",{value:!0}),e);var Do={};J4(Do,{Children:()=>Gp,Component:()=>Mp,Fragment:()=>QG,PureComponent:()=>Xce,Suspense:()=>Zce,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:()=>Qce,cloneElement:()=>kD,createContext:()=>VG,createElement:()=>nr,createRef:()=>d1,default:()=>vt,forwardRef:()=>rc,isValidElement:()=>KG,lazy:()=>Kce,memo:()=>Yce,useCallback:()=>BD,useContext:()=>ese,useDebugValue:()=>nse,useEffect:()=>Lr,useImperativeHandle:()=>Gf,useLayoutEffect:()=>HD,useMemo:()=>JD,useReducer:()=>ase,useRef:()=>Kt,useState:()=>As,version:()=>tse});var vt,Qce,Gp,kD,Mp,VG,nr,d1,rc,QG,KG,Kce,Yce,Xce,Zce,BD,ese,nse,Lr,Gf,HD,JD,ase,Kt,As,tse,Et=zre(()=>{vt=window.React,{__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Qce,Children:Gp,cloneElement:kD,Component:Mp,createContext:VG,createElement:nr,createRef:d1,forwardRef:rc,Fragment:QG,isValidElement:KG,lazy:Kce,memo:Yce,PureComponent:Xce,Suspense:Zce,useCallback:BD,useContext:ese,useDebugValue:nse,useEffect:Lr,useImperativeHandle:Gf,useLayoutEffect:HD,useMemo:JD,useReducer:ase,useRef:Kt,useState:As,version:tse}=window.React});var q6=He((EVe,J6)=>{"use strict";var H6=Object.getOwnPropertySymbols,Ise=Object.prototype.hasOwnProperty,Tse=Object.prototype.propertyIsEnumerable;function Sse(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function Cse(){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 r={};return"abcdefghijklmnopqrst".split("").forEach(function(u){r[u]=u}),Object.keys(Object.assign({},r)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}J6.exports=Cse()?Object.assign:function(e,n){for(var a,t=Sse(e),r,u=1;u{"use strict";var Ls=q6(),Mf=(Et(),Ng(Do));function Eo(e){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+e,a=1;axD;xD++)ii[xD]=xD+1;var ii,xD;ii[15]=0;var Mse=/^[: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]*$/,$6=Object.prototype.hasOwnProperty,W6={},x6={};function oU(e){return $6.call(x6,e)?!0:$6.call(W6,e)?!1:Mse.test(e)?x6[e]=!0:(W6[e]=!0,!1)}function Ase(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 Lse(e,n,a,t){if(n===null||typeof n>"u"||Ase(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 tl(e,n,a,t,r,u,i){this.acceptsBooleans=n===2||n===3||n===4,this.attributeName=t,this.attributeNamespace=r,this.mustUseProperty=a,this.propertyName=e,this.type=n,this.sanitizeURL=u,this.removeEmptyString=i}var li={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){li[e]=new tl(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var n=e[0];li[n]=new tl(n,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){li[e]=new tl(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){li[e]=new tl(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){li[e]=new tl(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){li[e]=new tl(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){li[e]=new tl(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){li[e]=new tl(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){li[e]=new tl(e,5,!1,e.toLowerCase(),null,!1,!1)});var cM=/[\-:]([a-z])/g;function sM(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(cM,sM);li[n]=new tl(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(cM,sM);li[n]=new tl(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(cM,sM);li[n]=new tl(n,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){li[e]=new tl(e,1,!1,e.toLowerCase(),null,!1,!1)});li.xlinkHref=new tl("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){li[e]=new tl(e,1,!1,e.toLowerCase(),null,!0,!0)});var Pse=/["'&<>]/;function Pp(e){if(typeof e=="boolean"||typeof e=="number")return""+e;e=""+e;var n=Pse.exec(e);if(n){var a="",t,r=0;for(t=n.index;tb1))throw Error(Eo(301));if(e===yv)if(w1=!0,e={action:a,next:null},x_===null&&(x_=new Map),a=x_.get(n),a===void 0)x_.set(n,e);else{for(n=a;n.next!==null;)n=n.next;n.next=e}}function XG(){}var Op=null,Bse={readContext:function(e){var n=Op.threadID;return QD(e,n),e[n]},useContext:function(e){Np();var n=Op.threadID;return QD(e,n),e[n]},useMemo:V6,useReducer:z6,useRef:function(e){yv=Np(),no=vM();var n=no.memoizedState;return n===null?(e={current:e},no.memoizedState=e):n},useState:function(e){return z6(lU,e)},useLayoutEffect:function(){},useCallback:function(e,n){return V6(function(){return e},n)},useImperativeHandle:XG,useEffect:XG,useDebugValue:XG,useDeferredValue:function(e){return Np(),e},useTransition:function(){return Np(),[function(e){e()},!1]},useOpaqueIdentifier:function(){return(Op.identifierPrefix||"")+"R:"+(Op.uniqueID++).toString(36)},useMutableSource:function(e,n){return Np(),n(e._source)}},Q6={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function K6(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 cU={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},Hse=Ls({menuitem:!0},cU),VD={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},Jse=["Webkit","ms","Moz","O"];Object.keys(VD).forEach(function(e){Jse.forEach(function(n){n=n+e.charAt(0).toUpperCase()+e.substring(1),VD[n]=VD[e]})});var qse=/([A-Z])/g,$se=/^ms-/,W_=Mf.Children.toArray,ZG=Fse.ReactCurrentDispatcher,Wse={listing:!0,pre:!0,textarea:!0},xse=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,Y6={},eM={};function jse(e){if(e==null)return e;var n="";return Mf.Children.forEach(e,function(a){a!=null&&(n+=a)}),n}var zse=Object.prototype.hasOwnProperty,Vse={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null,suppressHydrationWarning:null};function X6(e,n){if(e===void 0)throw Error(Eo(152,zD(n)||"Component"))}function Qse(e,n,a){function t(i,l){var s=l.prototype&&l.prototype.isReactComponent,h=Gse(l,n,a,s),p=[],R=!1,E={isMounted:function(){return!1},enqueueForceUpdate:function(){if(p===null)return null},enqueueReplaceState:function(te,le){R=!0,p=[le]},enqueueSetState:function(te,le){if(p===null)return null;p.push(le)}};if(s){if(s=new l(i.props,h,E),typeof l.getDerivedStateFromProps=="function"){var w=l.getDerivedStateFromProps.call(null,i.props,s.state);w!=null&&(s.state=Ls({},s.state,w))}}else if(yv={},s=l(i.props,h,E),s=uU(l,i.props,s,h),s==null||s.render==null){e=s,X6(e,l);return}if(s.props=i.props,s.context=h,s.updater=E,E=s.state,E===void 0&&(s.state=E=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(),p.length){E=p;var I=R;if(p=null,R=!1,I&&E.length===1)s.state=E[0];else{w=I?E[0]:s.state;var L=!0;for(I=I?1:0;I=l))throw Error(Eo(304));var s=new Uint16Array(l);for(s.set(i),ii=s,ii[0]=u+1,i=u;i=s.children.length){var h=s.footer;if(h!==""&&(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===R1)this.popProvider(s.type);else if(s.type===y1){this.suspenseDepth--;var p=u.pop();if(i){i=!1;var R=s.fallbackFrame;if(!R)throw Error(Eo(303));this.stack.push(R),u[this.suspenseDepth]+="";continue}else u[this.suspenseDepth]+=p}u[this.suspenseDepth]+=h}else{var E=s.children[s.childIndex++],w="";try{w+=this.render(E,s.context,s.domNamespace)}catch(I){throw I!=null&&typeof I.then=="function"?Error(Eo(294)):I}u.length<=this.suspenseDepth&&u.push(""),u[this.suspenseDepth]+=w}}return u[0]}finally{ZG.current=r,Op=t,iU()}},n.render=function(a,t,r){if(typeof a=="string"||typeof a=="number")return r=""+a,r===""?"":this.makeStaticMarkup?Pp(r):this.previousWasTextNode?""+Pp(r):(this.previousWasTextNode=!0,Pp(r));if(t=Qse(a,t,this.threadID),a=t.child,t=t.context,a===null||a===!1)return"";if(!Mf.isValidElement(a)){if(a!=null&&a.$$typeof!=null)throw r=a.$$typeof,Error(r===nM?Eo(257):Eo(258,r.toString()));return a=W_(a),this.stack.push({type:null,domNamespace:r,children:a,childIndex:0,context:t,footer:""}),""}var u=a.type;if(typeof u=="string")return this.renderDOM(a,t,r);switch(u){case tU:case aU:case aM:case tM:case uM:case D1:return a=W_(a.props.children),this.stack.push({type:null,domNamespace:r,children:a,childIndex:0,context:t,footer:""}),"";case y1:throw Error(Eo(294));case nU:throw Error(Eo(343))}if(typeof u=="object"&&u!==null)switch(u.$$typeof){case oM:yv={};var i=u.render(a.props,a.ref);return i=uU(u.render,a.props,i,a.ref),i=W_(i),this.stack.push({type:null,domNamespace:r,children:i,childIndex:0,context:t,footer:""}),"";case iM:return a=[Mf.createElement(u.type,Ls({ref:a.ref},a.props))],this.stack.push({type:null,domNamespace:r,children:a,childIndex:0,context:t,footer:""}),"";case R1:return u=W_(a.props.children),r={type:a,domNamespace:r,children:u,childIndex:0,context:t,footer:""},this.pushProvider(a),this.stack.push(r),"";case rM:u=a.type,i=a.props;var l=this.threadID;return QD(u,l),u=W_(i.children(u[l])),this.stack.push({type:a,domNamespace:r,children:u,childIndex:0,context:t,footer:""}),"";case eU:throw Error(Eo(338));case lM:return u=a.type,i=u._init,u=i(u._payload),a=[Mf.createElement(u,Ls({ref:a.ref},a.props))],this.stack.push({type:null,domNamespace:r,children:a,childIndex:0,context:t,footer:""}),""}throw Error(Eo(130,u==null?u:typeof u,""))},n.renderDOM=function(a,t,r){var u=a.type.toLowerCase();if(r===Q6.html&&K6(u),!Y6.hasOwnProperty(u)){if(!xse.test(u))throw Error(Eo(65,u));Y6[u]=!0}var i=a.props;if(u==="input")i=Ls({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(Eo(92));if(Array.isArray(s)){if(!(1>=s.length))throw Error(Eo(93));s=s[0]}l=""+s}l==null&&(l="")}i=Ls({},i,{value:void 0,children:""+l})}else if(u==="select")this.currentSelectValue=i.value!=null?i.value:i.defaultValue,i=Ls({},i,{value:void 0});else if(u==="option"){s=this.currentSelectValue;var h=jse(i.children);if(s!=null){var p=i.value!=null?i.value+"":h;if(l=!1,Array.isArray(s)){for(var R=0;R":(le+=">",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=Pp(s);break e}s=null}return s!=null?(i=[],Wse.hasOwnProperty(u)&&s.charAt(0)===` `&&(le+=` `),le+=s):i=W_(i.children),a=a.type,r=r==null||r==="http://www.w3.org/1999/xhtml"?K6(a):r==="http://www.w3.org/2000/svg"&&a==="foreignObject"?"http://www.w3.org/1999/xhtml":r,this.stack.push({domNamespace:r,type:u,children:i,childIndex:0,context:t,footer:l}),this.previousWasTextNode=!1,le},e})();xd.renderToNodeStream=function(){throw Error(Eo(207))};xd.renderToStaticMarkup=function(e,n){e=new sU(e,!0,n);try{return e.read(1/0)}finally{e.destroy()}};xd.renderToStaticNodeStream=function(){throw Error(Eo(208))};xd.renderToString=function(e,n){e=new sU(e,!1,n);try{return e.read(1/0)}finally{e.destroy()}};xd.version="17.0.2"});var _U=He((TVe,fU)=>{"use strict";fU.exports=vU()});var KH=He((XE,h2)=>{(function(n,a){typeof XE=="object"&&typeof h2=="object"?h2.exports=a():typeof define=="function"&&define.amd?define([],a):typeof XE=="object"?XE.Pusher=a():n.Pusher=a()})(window,function(){return(function(e){var n={};function a(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,a),r.l=!0,r.exports}return a.m=e,a.c=n,a.d=function(t,r,u){a.o(t,r)||Object.defineProperty(t,r,{enumerable:!0,get:u})},a.r=function(t){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.t=function(t,r){if(r&1&&(t=a(t)),r&8||r&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}),r&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 r=t&&t.__esModule?function(){return t.default}:function(){return t};return a.d(r,"a",r),r},a.o=function(t,r){return Object.prototype.hasOwnProperty.call(t,r)},a.p="",a(a.s=2)})([(function(e,n,a){"use strict";var t=this&&this.__extends||(function(){var w=function(I,L){return w=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(U,V){U.__proto__=V}||function(U,V){for(var Q in V)V.hasOwnProperty(Q)&&(U[Q]=V[Q])},w(I,L)};return function(I,L){w(I,L);function U(){this.constructor=I}I.prototype=L===null?Object.create(L):(U.prototype=L.prototype,new U)}})();Object.defineProperty(n,"__esModule",{value:!0});var r=256,u=(function(){function w(I){I===void 0&&(I="="),this._paddingCharacter=I}return w.prototype.encodedLength=function(I){return this._paddingCharacter?(I+2)/3*4|0:(I*8+5)/6|0},w.prototype.encode=function(I){for(var L="",U=0;U>>18&63),L+=this._encodeByte(V>>>12&63),L+=this._encodeByte(V>>>6&63),L+=this._encodeByte(V>>>0&63)}var Q=I.length-U;if(Q>0){var V=I[U]<<16|(Q===2?I[U+1]<<8:0);L+=this._encodeByte(V>>>18&63),L+=this._encodeByte(V>>>12&63),Q===2?L+=this._encodeByte(V>>>6&63):L+=this._paddingCharacter||"",L+=this._paddingCharacter||""}return L},w.prototype.maxDecodedLength=function(I){return this._paddingCharacter?I/4*3|0:(I*6+7)/8|0},w.prototype.decodedLength=function(I){return this.maxDecodedLength(I.length-this._getPaddingLength(I))},w.prototype.decode=function(I){if(I.length===0)return new Uint8Array(0);for(var L=this._getPaddingLength(I),U=I.length-L,V=new Uint8Array(this.maxDecodedLength(U)),Q=0,te=0,le=0,ne=0,Z=0,ee=0,me=0;te>>4,V[Q++]=Z<<4|ee>>>2,V[Q++]=ee<<6|me,le|=ne&r,le|=Z&r,le|=ee&r,le|=me&r;if(te>>4,le|=ne&r,le|=Z&r),te>>2,le|=ee&r),te>>8&6,L+=51-I>>>8&-75,L+=61-I>>>8&-15,L+=62-I>>>8&3,String.fromCharCode(L)},w.prototype._decodeChar=function(I){var L=r;return L+=(42-I&I-44)>>>8&-r+I-43+62,L+=(46-I&I-48)>>>8&-r+I-47+63,L+=(47-I&I-58)>>>8&-r+I-48+52,L+=(64-I&I-91)>>>8&-r+I-65+0,L+=(96-I&I-123)>>>8&-r+I-97+26,L},w.prototype._getPaddingLength=function(I){var L=0;if(this._paddingCharacter){for(var U=I.length-1;U>=0&&I[U]===this._paddingCharacter;U--)L++;if(I.length<4||L>2)throw new Error("Base64Coder: incorrect padding")}return L},w})();n.Coder=u;var i=new u;function l(w){return i.encode(w)}n.encode=l;function s(w){return i.decode(w)}n.decode=s;var h=(function(w){t(I,w);function I(){return w!==null&&w.apply(this,arguments)||this}return I.prototype._encodeByte=function(L){var U=L;return U+=65,U+=25-L>>>8&6,U+=51-L>>>8&-75,U+=61-L>>>8&-13,U+=62-L>>>8&49,String.fromCharCode(U)},I.prototype._decodeChar=function(L){var U=r;return U+=(44-L&L-46)>>>8&-r+L-45+62,U+=(94-L&L-96)>>>8&-r+L-95+63,U+=(47-L&L-58)>>>8&-r+L-48+52,U+=(64-L&L-91)>>>8&-r+L-65+0,U+=(96-L&L-123)>>>8&-r+L-97+26,U},I})(u);n.URLSafeCoder=h;var p=new h;function R(w){return p.encode(w)}n.encodeURLSafe=R;function E(w){return p.decode(w)}n.decodeURLSafe=E,n.encodedLength=function(w){return i.encodedLength(w)},n.maxDecodedLength=function(w){return i.maxDecodedLength(w)},n.decodedLength=function(w){return i.decodedLength(w)}}),(function(e,n,a){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var t="utf8: invalid string",r="utf8: invalid source encoding";function u(s){for(var h=new Uint8Array(i(s)),p=0,R=0;R>6,h[p++]=128|E&63):E<55296?(h[p++]=224|E>>12,h[p++]=128|E>>6&63,h[p++]=128|E&63):(R++,E=(E&1023)<<10,E|=s.charCodeAt(R)&1023,E+=65536,h[p++]=240|E>>18,h[p++]=128|E>>12&63,h[p++]=128|E>>6&63,h[p++]=128|E&63)}return h}n.encode=u;function i(s){for(var h=0,p=0;p=s.length-1)throw new Error(t);p++,h+=4}else throw new Error(t)}return h}n.encodedLength=i;function l(s){for(var h=[],p=0;p=s.length)throw new Error(r);var w=s[++p];if((w&192)!==128)throw new Error(r);R=(R&31)<<6|w&63,E=128}else if(R<240){if(p>=s.length-1)throw new Error(r);var w=s[++p],I=s[++p];if((w&192)!==128||(I&192)!==128)throw new Error(r);R=(R&15)<<12|(w&63)<<6|I&63,E=2048}else if(R<248){if(p>=s.length-2)throw new Error(r);var w=s[++p],I=s[++p],L=s[++p];if((w&192)!==128||(I&192)!==128||(L&192)!==128)throw new Error(r);R=(R&15)<<18|(w&63)<<12|(I&63)<<6|L&63,E=65536}else throw new Error(r);if(R=55296&&R<=57343)throw new Error(r);if(R>=65536){if(R>1114111)throw new Error(r);R-=65536,h.push(String.fromCharCode(55296|R>>10)),R=56320|R&1023}}h.push(String.fromCharCode(R))}return h.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 d(m,D){this.lastId=0,this.prefix=m,this.name=D}return d.prototype.create=function(m){this.lastId++;var D=this.lastId,M=this.prefix+D,A=this.name+"["+D+"]",Y=!1,Ge=function(){Y||(m.apply(null,arguments),Y=!0)};return this[D]=Ge,{number:D,id:M,name:A,callback:Ge}},d.prototype.remove=function(m){delete this[m.number]},d})(),r=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 d(m){this.options=m,this.receivers=m.receivers||r,this.loading={}}return d.prototype.load=function(m,D,M){var A=this;if(A.loading[m]&&A.loading[m].length>0)A.loading[m].push(M);else{A.loading[m]=[M];var Y=Pt.createScriptRequest(A.getPath(m,D)),Ge=A.receivers.create(function(Cn){if(A.receivers.remove(Ge),A.loading[m]){var xa=A.loading[m];delete A.loading[m];for(var _r=function(Xu){Xu||Y.cleanup()},Zr=0;Zr>>6)+E(128|m&63):E(224|m>>>12&15)+E(128|m>>>6&63)+E(128|m&63)},Q=function(d){return d.replace(/[^\x00-\x7F]/g,V)},te=function(d){var m=[0,2,1][d.length%3],D=d.charCodeAt(0)<<16|(d.length>1?d.charCodeAt(1):0)<<8|(d.length>2?d.charCodeAt(2):0),M=[w.charAt(D>>>18),w.charAt(D>>>12&63),m>=2?"=":w.charAt(D>>>6&63),m>=1?"=":w.charAt(D&63)];return M.join("")},le=window.btoa||function(d){return d.replace(/[\s\S]{1,3}/g,te)},ne=(function(){function d(m,D,M,A){var Y=this;this.clear=D,this.timer=m(function(){Y.timer&&(Y.timer=A(Y.timer))},M)}return d.prototype.isRunning=function(){return this.timer!==null},d.prototype.ensureAborted=function(){this.timer&&(this.clear(this.timer),this.timer=null)},d})(),Z=ne,ee=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})();function me(d){window.clearTimeout(d)}function $e(d){window.clearInterval(d)}var Qe=(function(d){ee(m,d);function m(D,M){return d.call(this,setTimeout,me,D,function(A){return M(),null})||this}return m})(Z),dn=(function(d){ee(m,d);function m(D,M){return d.call(this,setInterval,$e,D,function(A){return M(),A})||this}return m})(Z),qn={now:function(){return Date.now?Date.now():new Date().valueOf()},defer:function(d){return new Qe(0,d)},method:function(d){for(var m=[],D=1;D0)for(var A=0;A=1002&&d.code<=1004?"backoff":null:d.code===4e3?"tls_only":d.code<4100?"refused":d.code<4200?"backoff":d.code<4300?"retry":"refused"},getCloseError:function(d){return d.code!==1e3&&d.code!==1001?{type:"PusherError",data:{code:d.code,message:d.reason||d.message}}:null}},pe=ef,ms=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),ds=(function(d){ms(m,d);function m(D,M){var A=d.call(this)||this;return A.id=D,A.transport=M,A.activityTimeout=M.activityTimeout,A.bindListeners(),A}return m.prototype.handlesActivityChecks=function(){return this.transport.handlesActivityChecks()},m.prototype.send=function(D){return this.transport.send(D)},m.prototype.send_event=function(D,M,A){var Y={event:D,data:M};return A&&(Y.channel=A),In.debug("Event sent",Y),this.send(pe.encodeMessage(Y))},m.prototype.ping=function(){this.transport.supportsPing()?this.transport.ping():this.send_event("pusher:ping",{})},m.prototype.close=function(){this.transport.close()},m.prototype.bindListeners=function(){var D=this,M={message:function(Y){var Ge;try{Ge=pe.decodeMessage(Y)}catch(Cn){D.emit("error",{type:"MessageParseError",error:Cn,data:Y.data})}if(Ge!==void 0){switch(In.debug("Event recd",Ge),Ge.event){case"pusher:error":D.emit("error",{type:"PusherError",data:Ge.data});break;case"pusher:ping":D.emit("ping");break;case"pusher:pong":D.emit("pong");break}D.emit("message",Ge)}},activity:function(){D.emit("activity")},error:function(Y){D.emit("error",{type:"WebSocketError",error:Y})},closed:function(Y){A(),Y&&Y.code&&D.handleCloseEvent(Y),D.transport=null,D.emit("closed")}},A=function(){Da(M,function(Y,Ge){D.transport.unbind(Ge,Y)})};Da(M,function(Y,Ge){D.transport.bind(Ge,Y)})},m.prototype.handleCloseEvent=function(D){var M=pe.getCloseAction(D),A=pe.getCloseError(D);A&&this.emit("error",A),M&&this.emit(M,{action:M,error:A})},m})($a),nf=ds,hs=(function(){function d(m,D){this.transport=m,this.callback=D,this.bindListeners()}return d.prototype.close=function(){this.unbindListeners(),this.transport.close()},d.prototype.bindListeners=function(){var m=this;this.onMessage=function(D){m.unbindListeners();var M;try{M=pe.processHandshake(D)}catch(A){m.finish("error",{error:A}),m.transport.close();return}M.action==="connected"?m.finish("connected",{connection:new nf(M.id,m.transport),activityTimeout:M.activityTimeout}):(m.finish(M.action,{error:M.error}),m.transport.close())},this.onClosed=function(D){m.unbindListeners();var M=pe.getCloseAction(D)||"backoff",A=pe.getCloseError(D);m.finish(M,{error:A})},this.transport.bind("message",this.onMessage),this.transport.bind("closed",this.onClosed)},d.prototype.unbindListeners=function(){this.transport.unbind("message",this.onMessage),this.transport.unbind("closed",this.onClosed)},d.prototype.finish=function(m,D){this.callback(An({transport:this.transport,action:m},D))},d})(),Tc=hs,Rg=(function(){function d(m,D){this.channel=m;var M=D.authTransport;if(typeof Pt.getAuthorizers()[M]>"u")throw"'"+M+"' is not a recognized auth transport";this.type=M,this.options=D,this.authOptions=D.auth||{}}return d.prototype.composeQuery=function(m){var D="socket_id="+encodeURIComponent(m)+"&channel_name="+encodeURIComponent(this.channel.name);for(var M in this.authOptions.params)D+="&"+encodeURIComponent(M)+"="+encodeURIComponent(this.authOptions.params[M]);return D},d.prototype.authorize=function(m,D){d.authorizers=d.authorizers||Pt.getAuthorizers(),d.authorizers[this.type].call(this,Pt,m,D)},d})(),$0=Rg,xm=(function(){function d(m,D){this.timeline=m,this.options=D||{}}return d.prototype.send=function(m,D){this.timeline.isEmpty()||this.timeline.send(Pt.TimelineTransport.getAgent(this,m),D)},d})(),jm=xm,Sc=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),Ui=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),af=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),zm=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),yg=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),Vm=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),Rw=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),s_=(function(d){Sc(m,d);function m(D){var M=this.constructor,A=d.call(this,D)||this;return Object.setPrototypeOf(A,M.prototype),A}return m})(Error),AC=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),LC=(function(d){AC(m,d);function m(D,M){var A=d.call(this,function(Y,Ge){In.debug("No callbacks on "+D+" for "+Y)})||this;return A.name=D,A.pusher=M,A.subscribed=!1,A.subscriptionPending=!1,A.subscriptionCancelled=!1,A}return m.prototype.authorize=function(D,M){return M(!1,{auth:""})},m.prototype.trigger=function(D,M){if(D.indexOf("client-")!==0)throw new Ui("Event '"+D+"' does not start with 'client-'");if(!this.subscribed){var A=za.buildLogSuffix("triggeringClientEvents");In.warn("Client event triggered before channel 'subscription_succeeded' event . "+A)}return this.pusher.send_event(D,M,this.name)},m.prototype.disconnect=function(){this.subscribed=!1,this.subscriptionPending=!1},m.prototype.handleEvent=function(D){var M=D.event,A=D.data;if(M==="pusher_internal:subscription_succeeded")this.handleSubscriptionSucceededEvent(D);else if(M.indexOf("pusher_internal:")!==0){var Y={};this.emit(M,A,Y)}},m.prototype.handleSubscriptionSucceededEvent=function(D){this.subscriptionPending=!1,this.subscribed=!0,this.subscriptionCancelled?this.pusher.unsubscribe(this.name):this.emit("pusher:subscription_succeeded",D.data)},m.prototype.subscribe=function(){var D=this;this.subscribed||(this.subscriptionPending=!0,this.subscriptionCancelled=!1,this.authorize(this.pusher.connection.socket_id,function(M,A){M?(In.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}))}))},m.prototype.unsubscribe=function(){this.subscribed=!1,this.pusher.send_event("pusher:unsubscribe",{channel:this.name})},m.prototype.cancelSubscription=function(){this.subscriptionCancelled=!0},m.prototype.reinstateSubscription=function(){this.subscriptionCancelled=!1},m})($a),yw=LC,PC=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),NC=(function(d){PC(m,d);function m(){return d!==null&&d.apply(this,arguments)||this}return m.prototype.authorize=function(D,M){var A=Cc.createAuthorizer(this,this.pusher.config);return A.authorize(D,M)},m})(yw),wg=NC,ww=(function(){function d(){this.reset()}return d.prototype.get=function(m){return Object.prototype.hasOwnProperty.call(this.members,m)?{id:m,info:this.members[m]}:null},d.prototype.each=function(m){var D=this;Da(this.members,function(M,A){m(D.get(A))})},d.prototype.setMyID=function(m){this.myID=m},d.prototype.onSubscription=function(m){this.members=m.presence.hash,this.count=m.presence.count,this.me=this.get(this.myID)},d.prototype.addMember=function(m){return this.get(m.user_id)===null&&this.count++,this.members[m.user_id]=m.user_info,this.get(m.user_id)},d.prototype.removeMember=function(m){var D=this.get(m.user_id);return D&&(delete this.members[m.user_id],this.count--),D},d.prototype.reset=function(){this.members={},this.count=0,this.myID=null,this.me=null},d})(),OC=ww,UC=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),bw=(function(d){UC(m,d);function m(D,M){var A=d.call(this,D,M)||this;return A.members=new OC,A}return m.prototype.authorize=function(D,M){var A=this;d.prototype.authorize.call(this,D,function(Y,Ge){if(!Y){if(Ge=Ge,Ge.channel_data===void 0){var Cn=za.buildLogSuffix("authenticationEndpoint");In.error("Invalid auth response for channel '"+A.name+"',"+("expected 'channel_data' field. "+Cn)),M("Invalid auth response");return}var xa=JSON.parse(Ge.channel_data);A.members.setMyID(xa.user_id)}M(Y,Ge)})},m.prototype.handleEvent=function(D){var M=D.event;if(M.indexOf("pusher_internal:")===0)this.handleInternalEvent(D);else{var A=D.data,Y={};D.user_id&&(Y.user_id=D.user_id),this.emit(M,A,Y)}},m.prototype.handleInternalEvent=function(D){var M=D.event,A=D.data;switch(M){case"pusher_internal:subscription_succeeded":this.handleSubscriptionSucceededEvent(D);break;case"pusher_internal:member_added":var Y=this.members.addMember(A);this.emit("pusher:member_added",Y);break;case"pusher_internal:member_removed":var Ge=this.members.removeMember(A);Ge&&this.emit("pusher:member_removed",Ge);break}},m.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))},m.prototype.disconnect=function(){this.members.reset(),d.prototype.disconnect.call(this)},m})(wg),kC=bw,Ew=a(1),bg=a(0),BC=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),HC=(function(d){BC(m,d);function m(D,M,A){var Y=d.call(this,D,M)||this;return Y.key=null,Y.nacl=A,Y}return m.prototype.authorize=function(D,M){var A=this;d.prototype.authorize.call(this,D,function(Y,Ge){if(Y){M(!0,Ge);return}var Cn=Ge.shared_secret;if(!Cn){var xa="No shared_secret key in auth payload for encrypted channel: "+A.name;M(!0,xa);return}A.key=Object(bg.decode)(Cn),delete Ge.shared_secret,M(!1,Ge)})},m.prototype.trigger=function(D,M){throw new Vm("Client events are not currently supported for encrypted channels")},m.prototype.handleEvent=function(D){var M=D.event,A=D.data;if(M.indexOf("pusher_internal:")===0||M.indexOf("pusher:")===0){d.prototype.handleEvent.call(this,D);return}this.handleEncryptedEvent(M,A)},m.prototype.handleEncryptedEvent=function(D,M){var A=this;if(!this.key){In.debug("Received encrypted event before key has been retrieved from the authEndpoint");return}if(!M.ciphertext||!M.nonce){In.error("Unexpected format for encrypted event, expected object with `ciphertext` and `nonce` fields, got: "+M);return}var Y=Object(bg.decode)(M.ciphertext);if(Y.length0&&this.emit("connecting_in",Math.round(D/1e3)),this.retryTimer=new Qe(D||0,function(){M.disconnectInternally(),M.connect()})},m.prototype.clearRetryTimer=function(){this.retryTimer&&(this.retryTimer.ensureAborted(),this.retryTimer=null)},m.prototype.setUnavailableTimer=function(){var D=this;this.unavailableTimer=new Qe(this.options.unavailableTimeout,function(){D.updateState("unavailable")})},m.prototype.clearUnavailableTimer=function(){this.unavailableTimer&&this.unavailableTimer.ensureAborted()},m.prototype.sendActivityCheck=function(){var D=this;this.stopActivityCheck(),this.connection.ping(),this.activityTimer=new Qe(this.options.pongTimeout,function(){D.timeline.error({pong_timed_out:D.options.pongTimeout}),D.retryIn(0)})},m.prototype.resetActivityCheck=function(){var D=this;this.stopActivityCheck(),this.connection&&!this.connection.handlesActivityChecks()&&(this.activityTimer=new Qe(this.activityTimeout,function(){D.sendActivityCheck()}))},m.prototype.stopActivityCheck=function(){this.activityTimer&&this.activityTimer.ensureAborted()},m.prototype.buildConnectionCallbacks=function(D){var M=this;return An({},D,{message:function(A){M.resetActivityCheck(),M.emit("message",A)},ping:function(){M.send_event("pusher:pong",{})},activity:function(){M.resetActivityCheck()},error:function(A){M.emit("error",{type:"WebSocketError",error:A})},closed:function(){M.abandonConnection(),M.shouldRetry()&&M.retryIn(1e3)}})},m.prototype.buildHandshakeCallbacks=function(D){var M=this;return An({},D,{connected:function(A){M.activityTimeout=Math.min(M.options.activityTimeout,A.activityTimeout,A.connection.activityTimeout||1/0),M.clearUnavailableTimer(),M.setConnection(A.connection),M.socket_id=M.connection.id,M.updateState("connected",{socket_id:M.socket_id})}})},m.prototype.buildErrorCallbacks=function(){var D=this,M=function(A){return function(Y){Y.error&&D.emit("error",{type:"WebSocketError",error:Y.error}),A(Y)}};return{tls_only:M(function(){D.usingTLS=!0,D.updateStrategy(),D.retryIn(0)}),refused:M(function(){D.disconnect()}),backoff:M(function(){D.retryIn(1e3)}),retry:M(function(){D.retryIn(0)})}},m.prototype.setConnection=function(D){this.connection=D;for(var M in this.connectionCallbacks)this.connection.bind(M,this.connectionCallbacks[M]);this.resetActivityCheck()},m.prototype.abandonConnection=function(){if(this.connection){this.stopActivityCheck();for(var D in this.connectionCallbacks)this.connection.unbind(D,this.connectionCallbacks[D]);var M=this.connection;return this.connection=null,M}},m.prototype.updateState=function(D,M){var A=this.state;if(this.state=D,A!==D){var Y=D;Y==="connected"&&(Y+=" with new socket ID "+M.socket_id),In.debug("State changed",A+" -> "+Y),this.timeline.info({state:D,params:M}),this.emit("state_change",{previous:A,current:D}),this.emit(D,M)}},m.prototype.shouldRetry=function(){return this.state==="connecting"||this.state==="connected"},m})($a),Iw=$C,WC=(function(){function d(){this.channels={}}return d.prototype.add=function(m,D){return this.channels[m]||(this.channels[m]=Tw(m,D)),this.channels[m]},d.prototype.all=function(){return Dt(this.channels)},d.prototype.find=function(m){return this.channels[m]},d.prototype.remove=function(m){var D=this.channels[m];return delete this.channels[m],D},d.prototype.disconnect=function(){Da(this.channels,function(m){m.disconnect()})},d})(),xC=WC;function Tw(d,m){if(d.indexOf("private-encrypted-")===0){if(m.config.nacl)return Cc.createEncryptedChannel(d,m,m.config.nacl);var D="Tried to subscribe to a private-encrypted- channel but no nacl implementation available",M=za.buildLogSuffix("encryptedChannelSupport");throw new Vm(D+". "+M)}else return d.indexOf("private-")===0?Cc.createPrivateChannel(d,m):d.indexOf("presence-")===0?Cc.createPresenceChannel(d,m):Cc.createChannel(d,m)}var jC={createChannels:function(){return new xC},createConnectionManager:function(d,m){return new Iw(d,m)},createChannel:function(d,m){return new yw(d,m)},createPrivateChannel:function(d,m){return new wg(d,m)},createPresenceChannel:function(d,m){return new kC(d,m)},createEncryptedChannel:function(d,m,D){return new JC(d,m,D)},createTimelineSender:function(d,m){return new jm(d,m)},createAuthorizer:function(d,m){return m.authorizer?m.authorizer(d,m):new $0(d,m)},createHandshake:function(d,m){return new Tc(d,m)},createAssistantToTheTransportManager:function(d,m,D){return new Ks(d,m,D)}},Cc=jC,zC=(function(){function d(m){this.options=m||{},this.livesLeft=this.options.lives||1/0}return d.prototype.getAssistant=function(m){return Cc.createAssistantToTheTransportManager(this,m,{minPingDelay:this.options.minPingDelay,maxPingDelay:this.options.maxPingDelay})},d.prototype.isAlive=function(){return this.livesLeft>0},d.prototype.reportDeath=function(){this.livesLeft-=1},d})(),Sw=zC,VC=(function(){function d(m,D){this.strategies=m,this.loop=!!D.loop,this.failFast=!!D.failFast,this.timeout=D.timeout,this.timeoutLimit=D.timeoutLimit}return d.prototype.isSupported=function(){return zn(this.strategies,Mn.method("isSupported"))},d.prototype.connect=function(m,D){var M=this,A=this.strategies,Y=0,Ge=this.timeout,Cn=null,xa=function(_r,Zr){Zr?D(null,Zr):(Y=Y+1,M.loop&&(Y=Y%A.length),Y0&&(Y=new Qe(M.timeout,function(){Ge.abort(),A(!0)})),Ge=m.connect(D,function(Cn,xa){Cn&&Y&&Y.isRunning()&&!M.failFast||(Y&&Y.ensureAborted(),A(Cn,xa))}),{abort:function(){Y&&Y.ensureAborted(),Ge.abort()},forceMinPriority:function(Cn){Ge.forceMinPriority(Cn)}}},d})(),tf=VC,QC=(function(){function d(m){this.strategies=m}return d.prototype.isSupported=function(){return zn(this.strategies,Mn.method("isSupported"))},d.prototype.connect=function(m,D){return KC(this.strategies,m,function(M,A){return function(Y,Ge){if(A[M].error=Y,Y){Cw(A)&&D(!0);return}_t(A,function(Cn){Cn.forceMinPriority(Ge.transport.priority)}),D(null,Ge)}})},d})(),Eg=QC;function KC(d,m,D){var M=Ha(d,function(A,Y,Ge,Cn){return A.connect(m,D(Y,Cn))});return{abort:function(){_t(M,Ig)},forceMinPriority:function(A){_t(M,function(Y){Y.forceMinPriority(A)})}}}function Cw(d){return On(d,function(m){return!!m.error})}function Ig(d){!d.error&&!d.aborted&&(d.abort(),d.aborted=!0)}var YC=(function(){function d(m,D,M){this.strategy=m,this.transports=D,this.ttl=M.ttl||1800*1e3,this.usingTLS=M.useTLS,this.timeline=M.timeline}return d.prototype.isSupported=function(){return this.strategy.isSupported()},d.prototype.connect=function(m,D){var M=this.usingTLS,A=Fw(M),Y=[this.strategy];if(A&&A.timestamp+this.ttl>=Mn.now()){var Ge=this.transports[A.transport];Ge&&(this.timeline.info({cached:!0,transport:A.transport,latency:A.latency}),Y.push(new tf([Ge],{timeout:A.latency*2+1e3,failFast:!0})))}var Cn=Mn.now(),xa=Y.pop().connect(m,function _r(Zr,Xu){Zr?(Gw(M),Y.length>0?(Cn=Mn.now(),xa=Y.pop().connect(m,_r)):D(Zr)):(ZC(M,Xu.transport.name,Mn.now()-Cn),D(null,Xu))});return{abort:function(){xa.abort()},forceMinPriority:function(_r){m=_r,xa&&xa.forceMinPriority(_r)}}},d})(),XC=YC;function Tg(d){return"pusherTransport"+(d?"TLS":"NonTLS")}function Fw(d){var m=Pt.getLocalStorage();if(m)try{var D=m[Tg(d)];if(D)return JSON.parse(D)}catch{Gw(d)}return null}function ZC(d,m,D){var M=Pt.getLocalStorage();if(M)try{M[Tg(d)]=pt({timestamp:Mn.now(),transport:m,latency:D})}catch{}}function Gw(d){var m=Pt.getLocalStorage();if(m)try{delete m[Tg(d)]}catch{}}var eF=(function(){function d(m,D){var M=D.delay;this.strategy=m,this.options={delay:M}}return d.prototype.isSupported=function(){return this.strategy.isSupported()},d.prototype.connect=function(m,D){var M=this.strategy,A,Y=new Qe(this.options.delay,function(){A=M.connect(m,D)});return{abort:function(){Y.ensureAborted(),A&&A.abort()},forceMinPriority:function(Ge){m=Ge,A&&A.forceMinPriority(Ge)}}},d})(),Qm=eF,Mw=(function(){function d(m,D,M){this.test=m,this.trueBranch=D,this.falseBranch=M}return d.prototype.isSupported=function(){var m=this.test()?this.trueBranch:this.falseBranch;return m.isSupported()},d.prototype.connect=function(m,D){var M=this.test()?this.trueBranch:this.falseBranch;return M.connect(m,D)},d})(),W0=Mw,nF=(function(){function d(m){this.strategy=m}return d.prototype.isSupported=function(){return this.strategy.isSupported()},d.prototype.connect=function(m,D){var M=this.strategy.connect(m,function(A,Y){Y&&M.abort(),D(A,Y)});return M},d})(),aF=nF;function gs(d){return function(){return d.isSupported()}}var Aw=function(d,m,D){var M={};function A($o,Kw,Yw,MF,Xw){var b=D(d,$o,Kw,Yw,MF,Xw);return M[$o]=b,b}var Y=Object.assign({},m,{hostNonTLS:d.wsHost+":"+d.wsPort,hostTLS:d.wsHost+":"+d.wssPort,httpPath:d.wsPath}),Ge=Object.assign({},Y,{useTLS:!0}),Cn=Object.assign({},m,{hostNonTLS:d.httpHost+":"+d.httpPort,hostTLS:d.httpHost+":"+d.httpsPort,httpPath:d.httpPath}),xa={loop:!0,timeout:15e3,timeoutLimit:6e4},_r=new Sw({lives:2,minPingDelay:1e4,maxPingDelay:d.activityTimeout}),Zr=new Sw({lives:2,minPingDelay:1e4,maxPingDelay:d.activityTimeout}),Xu=A("ws","ws",3,Y,_r),xl=A("wss","ws",3,Ge,_r),SF=A("sockjs","sockjs",1,Cn),$w=A("xhr_streaming","xhr_streaming",1,Cn,Zr),Ww=A("xdr_streaming","xdr_streaming",1,Cn,Zr),xw=A("xhr_polling","xhr_polling",1,Cn),CF=A("xdr_polling","xdr_polling",1,Cn),jw=new tf([Xu],xa),FF=new tf([xl],xa),GF=new tf([SF],xa),zw=new tf([new W0(gs($w),$w,Ww)],xa),Vw=new tf([new W0(gs(xw),xw,CF)],xa),Qw=new tf([new W0(gs(zw),new Eg([zw,new Qm(Vw,{delay:4e3})]),Vw)],xa),Ag=new W0(gs(Qw),Qw,GF),Lg;return m.useTLS?Lg=new Eg([jw,new Qm(Ag,{delay:2e3})]):Lg=new Eg([jw,new Qm(FF,{delay:2e3}),new Qm(Ag,{delay:5e3})]),new XC(new aF(new W0(gs(Xu),Lg,Ag)),M,{ttl:18e5,timeline:m.timeline,useTLS:m.useTLS})},tF=Aw,rF=(function(){var d=this;d.timeline.info(d.buildTimelineMessage({transport:d.name+(d.options.useTLS?"s":"")})),d.hooks.isInitialized()?d.changeState("initialized"):d.hooks.file?(d.changeState("initializing"),p.load(d.hooks.file,{useTLS:d.options.useTLS},function(m,D){d.hooks.isInitialized()?(d.changeState("initialized"),D(!0)):(m&&d.onError(m),d.onClose(),D(!1))})):d.onClose()}),Lw={getRequest:function(d){var m=new window.XDomainRequest;return m.ontimeout=function(){d.emit("error",new af),d.close()},m.onerror=function(D){d.emit("error",D),d.close()},m.onprogress=function(){m.responseText&&m.responseText.length>0&&d.onChunk(200,m.responseText)},m.onload=function(){m.responseText&&m.responseText.length>0&&d.onChunk(200,m.responseText),d.emit("finished",200),d.close()},m},abortRequest:function(d){d.ontimeout=d.onerror=d.onprogress=d.onload=null,d.abort()}},oF=Lw,Pw=(function(){var d=function(m,D){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(M,A){M.__proto__=A}||function(M,A){for(var Y in A)A.hasOwnProperty(Y)&&(M[Y]=A[Y])},d(m,D)};return function(m,D){d(m,D);function M(){this.constructor=m}m.prototype=D===null?Object.create(D):(M.prototype=D.prototype,new M)}})(),uF=256*1024,Nw=(function(d){Pw(m,d);function m(D,M,A){var Y=d.call(this)||this;return Y.hooks=D,Y.method=M,Y.url=A,Y}return m.prototype.start=function(D){var M=this;this.position=0,this.xhr=this.hooks.getRequest(this),this.unloader=function(){M.close()},Pt.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)},m.prototype.close=function(){this.unloader&&(Pt.removeUnloadListener(this.unloader),this.unloader=null),this.xhr&&(this.hooks.abortRequest(this.xhr),this.xhr=null)},m.prototype.onChunk=function(D,M){for(;;){var A=this.advanceBuffer(M);if(A)this.emit("chunk",{status:D,data:A});else break}this.isBufferTooLong(M)&&this.emit("buffer_too_long")},m.prototype.advanceBuffer=function(D){var M=D.slice(this.position),A=M.indexOf(` `);return A!==-1?(this.position+=A+1,M.slice(0,A)):null},m.prototype.isBufferTooLong=function(D){return this.position===D.length&&D.length>uF},m})($a),Ow=Nw,x0;(function(d){d[d.CONNECTING=0]="CONNECTING",d[d.OPEN=1]="OPEN",d[d.CLOSED=3]="CLOSED"})(x0||(x0={}));var Fc=x0,iF=1,Uw=(function(){function d(m,D){this.hooks=m,this.session=fl(1e3)+"/"+Ds(8),this.location=lF(D),this.readyState=Fc.CONNECTING,this.openStream()}return d.prototype.send=function(m){return this.sendRaw(JSON.stringify([m]))},d.prototype.ping=function(){this.hooks.sendHeartbeat(this)},d.prototype.close=function(m,D){this.onClose(m,D,!0)},d.prototype.sendRaw=function(m){if(this.readyState===Fc.OPEN)try{return Pt.createSocketRequest("POST",Sg(cF(this.location,this.session))).start(m),!0}catch{return!1}else return!1},d.prototype.reconnect=function(){this.closeStream(),this.openStream()},d.prototype.onClose=function(m,D,M){this.closeStream(),this.readyState=Fc.CLOSED,this.onclose&&this.onclose({code:m,reason:D,wasClean:M})},d.prototype.onChunk=function(m){if(m.status===200){this.readyState===Fc.OPEN&&this.onActivity();var D,M=m.data.slice(0,1);switch(M){case"o":D=JSON.parse(m.data.slice(1)||"{}"),this.onOpen(D);break;case"a":D=JSON.parse(m.data.slice(1)||"[]");for(var A=0;A0&&d.onChunk(D.status,D.responseText);break;case 4:D.responseText&&D.responseText.length>0&&d.onChunk(D.status,D.responseText),d.emit("finished",D.status),d.close();break}},D},abortRequest:function(d){d.onreadystatechange=null,d.abort()}},Lt=Bw,rf={createStreamingSocket:function(d){return this.createSocket(fF,d)},createPollingSocket:function(d){return this.createSocket(pF,d)},createSocket:function(d,m){return new sF(d,m)},createXHR:function(d,m){return this.createRequest(Lt,d,m)},createRequest:function(d,m,D){return new Ow(d,m,D)}},Cg=rf;Cg.createXDR=function(d,m){return this.createRequest(oF,d,m)};var mF=Cg,dF={nextAuthCallbackID:1,auth_callbacks:{},ScriptReceivers:r,DependenciesReceivers:h,getDefaultStrategy:tF,Transports:Yu,transportConnectionInitializer:rF,HTTPFactory:mF,TimelineTransport:ce,getXHRAPI:function(){return window.XMLHttpRequest},getWebSocketAPI:function(){return window.WebSocket||window.MozWebSocket},setup:function(d){var m=this;window.Pusher=d;var D=function(){m.onDocumentBody(d.ready)};window.JSON?D():p.load("json2",{},D)},getDocument:function(){return document},getProtocol:function(){return this.getDocument().location.protocol},getAuthorizers:function(){return{ajax:W,jsonp:k}},onDocumentBody:function(d){var m=this;document.body?d():setTimeout(function(){m.onDocumentBody(d)},0)},createJSONPRequest:function(d,m){return new j(d,m)},createScriptRequest:function(d){return new P(d)},getLocalStorage:function(){try{return window.localStorage}catch{return}},createXHR:function(){return this.getXHRAPI()?this.createXMLHttpRequest():this.createMicrosoftXHR()},createXMLHttpRequest:function(){var d=this.getXHRAPI();return new d},createMicrosoftXHR:function(){return new ActiveXObject("Microsoft.XMLHTTP")},getNetwork:function(){return Wl},createWebSocket:function(d){var m=this.getWebSocketAPI();return new m(d)},createSocketRequest:function(d,m){if(this.isXHRSupported())return this.HTTPFactory.createXHR(d,m);if(this.isXDRSupported(m.indexOf("https:")===0))return this.HTTPFactory.createXDR(d,m);throw"Cross-origin HTTP requests are not supported"},isXHRSupported:function(){var d=this.getXHRAPI();return!!d&&new d().withCredentials!==void 0},isXDRSupported:function(d){var m=d?"https:":"http:",D=this.getProtocol();return!!window.XDomainRequest&&D===m},addUnloadListener:function(d){window.addEventListener!==void 0?window.addEventListener("unload",d,!1):window.attachEvent!==void 0&&window.attachEvent("onunload",d)},removeUnloadListener:function(d){window.addEventListener!==void 0?window.removeEventListener("unload",d,!1):window.detachEvent!==void 0&&window.detachEvent("onunload",d)}},Pt=dF,Km;(function(d){d[d.ERROR=3]="ERROR",d[d.INFO=6]="INFO",d[d.DEBUG=7]="DEBUG"})(Km||(Km={}));var Ym=Km,hF=(function(){function d(m,D,M){this.key=m,this.session=D,this.events=[],this.options=M||{},this.sent=0,this.uniqueID=0}return d.prototype.log=function(m,D){m<=this.options.level&&(this.events.push(An({},D,{timestamp:Mn.now()})),this.options.limit&&this.events.length>this.options.limit&&this.events.shift())},d.prototype.error=function(m){this.log(Ym.ERROR,m)},d.prototype.info=function(m){this.log(Ym.INFO,m)},d.prototype.debug=function(m){this.log(Ym.DEBUG,m)},d.prototype.isEmpty=function(){return this.events.length===0},d.prototype.send=function(m,D){var M=this,A=An({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=[],m(A,function(Y,Ge){Y||M.sent++,D&&D(Y,Ge)}),!0},d.prototype.generateUniqueID=function(){return this.uniqueID++,this.uniqueID},d})(),Hw=hF,Fg=(function(){function d(m,D,M,A){this.name=m,this.priority=D,this.transport=M,this.options=A||{}}return d.prototype.isSupported=function(){return this.transport.isSupported({useTLS:this.options.useTLS})},d.prototype.connect=function(m,D){var M=this;if(this.isSupported()){if(this.priority{"use strict";var YIe="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";o$.exports=YIe});var s$=He((aAn,c$)=>{"use strict";var XIe=u$();function i$(){}function l$(){}l$.resetWarningCache=i$;c$.exports=function(){function e(t,r,u,i,l,s){if(s!==XIe){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}e.isRequired=e;function n(){return e}var a={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:n,element:e,elementType:e,instanceOf:n,node:e,objectOf:n,oneOf:n,oneOfType:n,shape:n,exact:n,checkPropTypes:l$,resetWarningCache:i$};return a.PropTypes=a,a}});var f$=He((oAn,v$)=>{v$.exports=s$()();var tAn,rAn});var iL=He(bh=>{"use strict";Object.defineProperty(bh,"__esModule",{value:!0});var p$=["input","select","textarea","a[href]","button","[tabindex]:not(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"],yI=p$.join(","),m$=typeof Element>"u",fm=m$?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,oL=!m$&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},d$=function(n,a,t){var r=Array.prototype.slice.apply(n.querySelectorAll(yI));return a&&fm.call(n,yI)&&r.unshift(n),r=r.filter(t),r},h$=function e(n,a,t){for(var r=[],u=Array.from(n);u.length;){var i=u.shift();if(i.tagName==="SLOT"){var l=i.assignedElements(),s=l.length?l:i.children,h=e(s,!0,t);t.flatten?r.push.apply(r,h):r.push({scope:i,candidates:h})}else{var p=fm.call(i,yI);p&&t.filter(i)&&(a||!n.includes(i))&&r.push(i);var R=i.shadowRoot||typeof t.getShadowRoot=="function"&&t.getShadowRoot(i),E=!t.shadowRootFilter||t.shadowRootFilter(i);if(R&&E){var w=e(R===!0?i.children:R.children,!0,t);t.flatten?r.push.apply(r,w):r.push({scope:i,candidates:w})}else u.unshift.apply(u,i.children)}}return r},g$=function(n,a){return n.tabIndex<0&&(a||/^(AUDIO|VIDEO|DETAILS)$/.test(n.tagName)||n.isContentEditable)&&isNaN(parseInt(n.getAttribute("tabindex"),10))?0:n.tabIndex},ZIe=function(n,a){return n.tabIndex===a.tabIndex?n.documentOrder-a.documentOrder:n.tabIndex-a.tabIndex},D$=function(n){return n.tagName==="INPUT"},eTe=function(n){return D$(n)&&n.type==="hidden"},nTe=function(n){var a=n.tagName==="DETAILS"&&Array.prototype.slice.apply(n.children).some(function(t){return t.tagName==="SUMMARY"});return a},aTe=function(n,a){for(var t=0;tsummary:first-of-type"),i=u?n.parentElement:n;if(fm.call(i,"details:not([open]) *"))return!0;var l=oL(n).host,s=(l==null?void 0:l.ownerDocument.contains(l))||n.ownerDocument.contains(n);if(!t||t==="full"){if(typeof r=="function"){for(var h=n;n;){var p=n.parentElement,R=oL(n);if(p&&!p.shadowRoot&&r(p)===!0)return _$(n);n.assignedSlot?n=n.assignedSlot:!p&&R!==n.ownerDocument?n=R.host:n=p}n=h}if(s)return!n.getClientRects().length}else if(t==="non-zero-area")return _$(n);return!1},iTe=function(n){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(n.tagName))for(var a=n.parentElement;a;){if(a.tagName==="FIELDSET"&&a.disabled){for(var t=0;t=0)},cTe=function e(n){var a=[],t=[];return n.forEach(function(r,u){var i=!!r.scope,l=i?r.scope:r,s=g$(l,i),h=i?e(r.candidates):l;s===0?i?a.push.apply(a,h):a.push(l):t.push({documentOrder:u,tabIndex:s,item:r,isScope:i,content:h})}),t.sort(ZIe).reduce(function(r,u){return u.isScope?r.push.apply(r,u.content):r.push(u.content),r},[]).concat(a)},sTe=function(n,a){a=a||{};var t;return a.getShadowRoot?t=h$([n],a.includeContainer,{filter:uL.bind(null,a),flatten:!1,getShadowRoot:a.getShadowRoot,shadowRootFilter:lTe}):t=d$(n,a.includeContainer,uL.bind(null,a)),cTe(t)},vTe=function(n,a){a=a||{};var t;return a.getShadowRoot?t=h$([n],a.includeContainer,{filter:wI.bind(null,a),flatten:!0,getShadowRoot:a.getShadowRoot}):t=d$(n,a.includeContainer,wI.bind(null,a)),t},fTe=function(n,a){if(a=a||{},!n)throw new Error("No node provided");return fm.call(n,yI)===!1?!1:uL(a,n)},_Te=p$.concat("iframe").join(","),pTe=function(n,a){if(a=a||{},!n)throw new Error("No node provided");return fm.call(n,_Te)===!1?!1:wI(a,n)};bh.focusable=vTe;bh.isFocusable=pTe;bh.isTabbable=fTe;bh.tabbable=sTe});var I$=He(lL=>{"use strict";Object.defineProperty(lL,"__esModule",{value:!0});var Kf=iL();function R$(e,n){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),a.push.apply(a,t)}return a}function y$(e){for(var n=1;n0){var t=e[e.length-1];t!==a&&t.pause()}var r=e.indexOf(a);r===-1||e.splice(r,1),e.push(a)},deactivateTrap:function(a){var t=e.indexOf(a);t!==-1&&e.splice(t,1),e.length>0&&e[e.length-1].unpause()}}})(),dTe=function(n){return n.tagName&&n.tagName.toLowerCase()==="input"&&typeof n.select=="function"},hTe=function(n){return n.key==="Escape"||n.key==="Esc"||n.keyCode===27},gTe=function(n){return n.key==="Tab"||n.keyCode===9},b$=function(n){return setTimeout(n,0)},E$=function(n,a){var t=-1;return n.every(function(r,u){return a(r)?(t=u,!1):!0}),t},BR=function(n){for(var a=arguments.length,t=new Array(a>1?a-1:0),r=1;r1?me-1:0),Qe=1;Qe=0)Z=t.activeElement;else{var ee=u.tabbableGroups[0],me=ee&&ee.firstTabbableNode;Z=me||h("fallbackFocus")}if(!Z)throw new Error("Your focus-trap needs to have at least one focusable element");return Z},R=function(){if(u.containerGroups=u.containers.map(function(Z){var ee=Kf.tabbable(Z,r.tabbableOptions),me=Kf.focusable(Z,r.tabbableOptions);return{container:Z,tabbableNodes:ee,focusableNodes:me,firstTabbableNode:ee.length>0?ee[0]:null,lastTabbableNode:ee.length>0?ee[ee.length-1]:null,nextTabbableNode:function(Qe){var dn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,qn=me.findIndex(function(Mn){return Mn===Qe});if(!(qn<0))return dn?me.slice(qn+1).find(function(Mn){return Kf.isTabbable(Mn,r.tabbableOptions)}):me.slice(0,qn).reverse().find(function(Mn){return Kf.isTabbable(Mn,r.tabbableOptions)})}}}),u.tabbableGroups=u.containerGroups.filter(function(Z){return Z.tabbableNodes.length>0}),u.tabbableGroups.length<=0&&!h("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},E=function ne(Z){if(Z!==!1&&Z!==t.activeElement){if(!Z||!Z.focus){ne(p());return}Z.focus({preventScroll:!!r.preventScroll}),u.mostRecentlyFocusedNode=Z,dTe(Z)&&Z.select()}},w=function(Z){var ee=h("setReturnFocus",Z);return ee||(ee===!1?!1:Z)},I=function(Z){var ee=bI(Z);if(!(s(ee)>=0)){if(BR(r.clickOutsideDeactivates,Z)){i.deactivate({returnFocus:r.returnFocusOnDeactivate&&!Kf.isFocusable(ee,r.tabbableOptions)});return}BR(r.allowOutsideClick,Z)||Z.preventDefault()}},L=function(Z){var ee=bI(Z),me=s(ee)>=0;me||ee instanceof Document?me&&(u.mostRecentlyFocusedNode=ee):(Z.stopImmediatePropagation(),E(u.mostRecentlyFocusedNode||p()))},U=function(Z){var ee=bI(Z);R();var me=null;if(u.tabbableGroups.length>0){var $e=s(ee),Qe=$e>=0?u.containerGroups[$e]:void 0;if($e<0)Z.shiftKey?me=u.tabbableGroups[u.tabbableGroups.length-1].lastTabbableNode:me=u.tabbableGroups[0].firstTabbableNode;else if(Z.shiftKey){var dn=E$(u.tabbableGroups,function(Da){var da=Da.firstTabbableNode;return ee===da});if(dn<0&&(Qe.container===ee||Kf.isFocusable(ee,r.tabbableOptions)&&!Kf.isTabbable(ee,r.tabbableOptions)&&!Qe.nextTabbableNode(ee,!1))&&(dn=$e),dn>=0){var qn=dn===0?u.tabbableGroups.length-1:dn-1,Mn=u.tabbableGroups[qn];me=Mn.lastTabbableNode}}else{var An=E$(u.tabbableGroups,function(Da){var da=Da.lastTabbableNode;return ee===da});if(An<0&&(Qe.container===ee||Kf.isFocusable(ee,r.tabbableOptions)&&!Kf.isTabbable(ee,r.tabbableOptions)&&!Qe.nextTabbableNode(ee))&&(An=$e),An>=0){var kn=An===u.tabbableGroups.length-1?0:An+1,Ia=u.tabbableGroups[kn];me=Ia.firstTabbableNode}}}else me=h("fallbackFocus");me&&(Z.preventDefault(),E(me))},V=function(Z){if(hTe(Z)&&BR(r.escapeDeactivates,Z)!==!1){Z.preventDefault(),i.deactivate();return}if(gTe(Z)){U(Z);return}},Q=function(Z){var ee=bI(Z);s(ee)>=0||BR(r.clickOutsideDeactivates,Z)||BR(r.allowOutsideClick,Z)||(Z.preventDefault(),Z.stopImmediatePropagation())},te=function(){if(u.active)return w$.activateTrap(i),u.delayInitialFocusTimer=r.delayInitialFocus?b$(function(){E(p())}):E(p()),t.addEventListener("focusin",L,!0),t.addEventListener("mousedown",I,{capture:!0,passive:!1}),t.addEventListener("touchstart",I,{capture:!0,passive:!1}),t.addEventListener("click",Q,{capture:!0,passive:!1}),t.addEventListener("keydown",V,{capture:!0,passive:!1}),i},le=function(){if(u.active)return t.removeEventListener("focusin",L,!0),t.removeEventListener("mousedown",I,!0),t.removeEventListener("touchstart",I,!0),t.removeEventListener("click",Q,!0),t.removeEventListener("keydown",V,!0),i};return i={get active(){return u.active},get paused(){return u.paused},activate:function(Z){if(u.active)return this;var ee=l(Z,"onActivate"),me=l(Z,"onPostActivate"),$e=l(Z,"checkCanFocusTrap");$e||R(),u.active=!0,u.paused=!1,u.nodeFocusedBeforeActivation=t.activeElement,ee&&ee();var Qe=function(){$e&&R(),te(),me&&me()};return $e?($e(u.containers.concat()).then(Qe,Qe),this):(Qe(),this)},deactivate:function(Z){if(!u.active)return this;var ee=y$({onDeactivate:r.onDeactivate,onPostDeactivate:r.onPostDeactivate,checkCanReturnFocus:r.checkCanReturnFocus},Z);clearTimeout(u.delayInitialFocusTimer),u.delayInitialFocusTimer=void 0,le(),u.active=!1,u.paused=!1,w$.deactivateTrap(i);var me=l(ee,"onDeactivate"),$e=l(ee,"onPostDeactivate"),Qe=l(ee,"checkCanReturnFocus"),dn=l(ee,"returnFocus","returnFocusOnDeactivate");me&&me();var qn=function(){b$(function(){dn&&E(w(u.nodeFocusedBeforeActivation)),$e&&$e()})};return dn&&Qe?(Qe(w(u.nodeFocusedBeforeActivation)).then(qn,qn),this):(qn(),this)},pause:function(){return u.paused||!u.active?this:(u.paused=!0,le(),this)},unpause:function(){return!u.paused||!u.active?this:(u.paused=!1,R(),te(),this)},updateContainerElements:function(Z){var ee=[].concat(Z).filter(Boolean);return u.containers=ee.map(function(me){return typeof me=="string"?t.querySelector(me):me}),u.active&&R(),this}},i.updateContainerElements(n),i};lL.createFocusTrap=DTe});var C$=He((lAn,S$)=>{"use strict";function cL(e){"@babel/helpers - typeof";return cL=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},cL(e)}function RTe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function T$(e,n){for(var a=0;a"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function II(e){return II=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},II(e)}function TTe(e,n,a){return n in e?Object.defineProperty(e,n,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[n]=a,e}var EI=(Et(),Ng(Do)),gt=f$(),STe=I$(),CTe=STe.createFocusTrap,FTe=iL(),GTe=FTe.isFocusable,vL=(function(e){wTe(a,e);var n=bTe(a);function a(t){var r;RTe(this,a),r=n.call(this,t),TTe(JR(r),"getNodeForOption",function(l){var s,h=(s=this.internalOptions[l])!==null&&s!==void 0?s:this.originalOptions[l];if(typeof h=="function"){for(var p=arguments.length,R=new Array(p>1?p-1:0),E=1;E element.");var i=function(h){var p=r.props.containerElements;u&&(typeof u.ref=="function"?u.ref(h):u.ref&&(u.ref.current=h)),r.focusTrapElements=p||[h]},l=EI.cloneElement(u,{ref:i});return l}return null}}]),a})(EI.Component),HR=typeof Element>"u"?Function:Element;vL.propTypes={active:gt.bool,paused:gt.bool,focusTrapOptions:gt.shape({document:gt.object,onActivate:gt.func,onPostActivate:gt.func,checkCanFocusTrap:gt.func,onDeactivate:gt.func,onPostDeactivate:gt.func,checkCanReturnFocus:gt.func,initialFocus:gt.oneOfType([gt.instanceOf(HR),gt.string,gt.bool,gt.func]),fallbackFocus:gt.oneOfType([gt.instanceOf(HR),gt.string,gt.func]),escapeDeactivates:gt.oneOfType([gt.bool,gt.func]),clickOutsideDeactivates:gt.oneOfType([gt.bool,gt.func]),returnFocusOnDeactivate:gt.bool,setReturnFocus:gt.oneOfType([gt.instanceOf(HR),gt.string,gt.bool,gt.func]),allowOutsideClick:gt.oneOfType([gt.bool,gt.func]),preventScroll:gt.bool,tabbableOptions:gt.shape({displayCheck:gt.oneOf(["full","non-zero-area","none"]),getShadowRoot:gt.oneOfType([gt.bool,gt.func])})}),containerElements:gt.arrayOf(gt.instanceOf(HR)),children:gt.oneOfType([gt.element,gt.instanceOf(HR)])};vL.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:CTe};S$.exports=vL});var BW=He(Br=>{"use strict";var zu=typeof Symbol=="function"&&Symbol.for,zL=zu?Symbol.for("react.element"):60103,VL=zu?Symbol.for("react.portal"):60106,kI=zu?Symbol.for("react.fragment"):60107,BI=zu?Symbol.for("react.strict_mode"):60108,HI=zu?Symbol.for("react.profiler"):60114,JI=zu?Symbol.for("react.provider"):60109,qI=zu?Symbol.for("react.context"):60110,QL=zu?Symbol.for("react.async_mode"):60111,$I=zu?Symbol.for("react.concurrent_mode"):60111,WI=zu?Symbol.for("react.forward_ref"):60112,xI=zu?Symbol.for("react.suspense"):60113,TFe=zu?Symbol.for("react.suspense_list"):60120,jI=zu?Symbol.for("react.memo"):60115,zI=zu?Symbol.for("react.lazy"):60116,SFe=zu?Symbol.for("react.block"):60121,CFe=zu?Symbol.for("react.fundamental"):60117,FFe=zu?Symbol.for("react.responder"):60118,GFe=zu?Symbol.for("react.scope"):60119;function hc(e){if(typeof e=="object"&&e!==null){var n=e.$$typeof;switch(n){case zL:switch(e=e.type,e){case QL:case $I:case kI:case HI:case BI:case xI:return e;default:switch(e=e&&e.$$typeof,e){case qI:case WI:case zI:case jI:case JI:return e;default:return n}}case VL:return n}}}function kW(e){return hc(e)===$I}Br.AsyncMode=QL;Br.ConcurrentMode=$I;Br.ContextConsumer=qI;Br.ContextProvider=JI;Br.Element=zL;Br.ForwardRef=WI;Br.Fragment=kI;Br.Lazy=zI;Br.Memo=jI;Br.Portal=VL;Br.Profiler=HI;Br.StrictMode=BI;Br.Suspense=xI;Br.isAsyncMode=function(e){return kW(e)||hc(e)===QL};Br.isConcurrentMode=kW;Br.isContextConsumer=function(e){return hc(e)===qI};Br.isContextProvider=function(e){return hc(e)===JI};Br.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===zL};Br.isForwardRef=function(e){return hc(e)===WI};Br.isFragment=function(e){return hc(e)===kI};Br.isLazy=function(e){return hc(e)===zI};Br.isMemo=function(e){return hc(e)===jI};Br.isPortal=function(e){return hc(e)===VL};Br.isProfiler=function(e){return hc(e)===HI};Br.isStrictMode=function(e){return hc(e)===BI};Br.isSuspense=function(e){return hc(e)===xI};Br.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===kI||e===$I||e===HI||e===BI||e===xI||e===TFe||typeof e=="object"&&e!==null&&(e.$$typeof===zI||e.$$typeof===jI||e.$$typeof===JI||e.$$typeof===qI||e.$$typeof===WI||e.$$typeof===CFe||e.$$typeof===FFe||e.$$typeof===GFe||e.$$typeof===SFe)};Br.typeOf=hc});var JW=He((o4n,HW)=>{"use strict";HW.exports=BW()});var Dm=He((g4n,KI)=>{(function(){"use strict";var e={}.hasOwnProperty;function n(){for(var r="",u=0;u{function dGe(){this.__data__=[],this.size=0}Ox.exports=dGe});var d3=He((Z8n,kx)=>{function hGe(e,n){return e===n||e!==e&&n!==n}kx.exports=hGe});var ZR=He((e7n,Bx)=>{var gGe=d3();function DGe(e,n){for(var a=e.length;a--;)if(gGe(e[a][0],n))return a;return-1}Bx.exports=DGe});var Jx=He((n7n,Hx)=>{var RGe=ZR(),yGe=Array.prototype,wGe=yGe.splice;function bGe(e){var n=this.__data__,a=RGe(n,e);if(a<0)return!1;var t=n.length-1;return a==t?n.pop():wGe.call(n,a,1),--this.size,!0}Hx.exports=bGe});var $x=He((a7n,qx)=>{var EGe=ZR();function IGe(e){var n=this.__data__,a=EGe(n,e);return a<0?void 0:n[a][1]}qx.exports=IGe});var xx=He((t7n,Wx)=>{var TGe=ZR();function SGe(e){return TGe(this.__data__,e)>-1}Wx.exports=SGe});var zx=He((r7n,jx)=>{var CGe=ZR();function FGe(e,n){var a=this.__data__,t=CGe(a,e);return t<0?(++this.size,a.push([e,n])):a[t][1]=n,this}jx.exports=FGe});var ey=He((o7n,Vx)=>{var GGe=Ux(),MGe=Jx(),AGe=$x(),LGe=xx(),PGe=zx();function Ah(e){var n=-1,a=e==null?0:e.length;for(this.clear();++n{var NGe=ey();function OGe(){this.__data__=new NGe,this.size=0}Qx.exports=OGe});var Xx=He((i7n,Yx)=>{function UGe(e){var n=this.__data__,a=n.delete(e);return this.size=n.size,a}Yx.exports=UGe});var ej=He((l7n,Zx)=>{function kGe(e){return this.__data__.get(e)}Zx.exports=kGe});var aj=He((c7n,nj)=>{function BGe(e){return this.__data__.has(e)}nj.exports=BGe});var h3=He((s7n,tj)=>{var HGe=typeof global=="object"&&global&&global.Object===Object&&global;tj.exports=HGe});var Wv=He((v7n,rj)=>{var JGe=h3(),qGe=typeof self=="object"&&self&&self.Object===Object&&self,$Ge=JGe||qGe||Function("return this")();rj.exports=$Ge});var hT=He((f7n,oj)=>{var WGe=Wv(),xGe=WGe.Symbol;oj.exports=xGe});var cj=He((_7n,lj)=>{var uj=hT(),ij=Object.prototype,jGe=ij.hasOwnProperty,zGe=ij.toString,ny=uj?uj.toStringTag:void 0;function VGe(e){var n=jGe.call(e,ny),a=e[ny];try{e[ny]=void 0;var t=!0}catch{}var r=zGe.call(e);return t&&(n?e[ny]=a:delete e[ny]),r}lj.exports=VGe});var vj=He((p7n,sj)=>{var QGe=Object.prototype,KGe=QGe.toString;function YGe(e){return KGe.call(e)}sj.exports=YGe});var ay=He((m7n,pj)=>{var fj=hT(),XGe=cj(),ZGe=vj(),eMe="[object Null]",nMe="[object Undefined]",_j=fj?fj.toStringTag:void 0;function aMe(e){return e==null?e===void 0?nMe:eMe:_j&&_j in Object(e)?XGe(e):ZGe(e)}pj.exports=aMe});var g3=He((d7n,mj)=>{function tMe(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}mj.exports=tMe});var D3=He((h7n,dj)=>{var rMe=ay(),oMe=g3(),uMe="[object AsyncFunction]",iMe="[object Function]",lMe="[object GeneratorFunction]",cMe="[object Proxy]";function sMe(e){if(!oMe(e))return!1;var n=rMe(e);return n==iMe||n==lMe||n==uMe||n==cMe}dj.exports=sMe});var gj=He((g7n,hj)=>{var vMe=Wv(),fMe=vMe["__core-js_shared__"];hj.exports=fMe});var yj=He((D7n,Rj)=>{var R3=gj(),Dj=(function(){var e=/[^.]+$/.exec(R3&&R3.keys&&R3.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function _Me(e){return!!Dj&&Dj in e}Rj.exports=_Me});var y3=He((R7n,wj)=>{var pMe=Function.prototype,mMe=pMe.toString;function dMe(e){if(e!=null){try{return mMe.call(e)}catch{}try{return e+""}catch{}}return""}wj.exports=dMe});var Ej=He((y7n,bj)=>{var hMe=D3(),gMe=yj(),DMe=g3(),RMe=y3(),yMe=/[\\^$.*+?()[\]{}|]/g,wMe=/^\[object .+?Constructor\]$/,bMe=Function.prototype,EMe=Object.prototype,IMe=bMe.toString,TMe=EMe.hasOwnProperty,SMe=RegExp("^"+IMe.call(TMe).replace(yMe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function CMe(e){if(!DMe(e)||gMe(e))return!1;var n=hMe(e)?SMe:wMe;return n.test(RMe(e))}bj.exports=CMe});var Tj=He((w7n,Ij)=>{function FMe(e,n){return e==null?void 0:e[n]}Ij.exports=FMe});var ym=He((b7n,Sj)=>{var GMe=Ej(),MMe=Tj();function AMe(e,n){var a=MMe(e,n);return GMe(a)?a:void 0}Sj.exports=AMe});var gT=He((E7n,Cj)=>{var LMe=ym(),PMe=Wv(),NMe=LMe(PMe,"Map");Cj.exports=NMe});var ty=He((I7n,Fj)=>{var OMe=ym(),UMe=OMe(Object,"create");Fj.exports=UMe});var Aj=He((T7n,Mj)=>{var Gj=ty();function kMe(){this.__data__=Gj?Gj(null):{},this.size=0}Mj.exports=kMe});var Pj=He((S7n,Lj)=>{function BMe(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}Lj.exports=BMe});var Oj=He((C7n,Nj)=>{var HMe=ty(),JMe="__lodash_hash_undefined__",qMe=Object.prototype,$Me=qMe.hasOwnProperty;function WMe(e){var n=this.__data__;if(HMe){var a=n[e];return a===JMe?void 0:a}return $Me.call(n,e)?n[e]:void 0}Nj.exports=WMe});var kj=He((F7n,Uj)=>{var xMe=ty(),jMe=Object.prototype,zMe=jMe.hasOwnProperty;function VMe(e){var n=this.__data__;return xMe?n[e]!==void 0:zMe.call(n,e)}Uj.exports=VMe});var Hj=He((G7n,Bj)=>{var QMe=ty(),KMe="__lodash_hash_undefined__";function YMe(e,n){var a=this.__data__;return this.size+=this.has(e)?0:1,a[e]=QMe&&n===void 0?KMe:n,this}Bj.exports=YMe});var qj=He((M7n,Jj)=>{var XMe=Aj(),ZMe=Pj(),eAe=Oj(),nAe=kj(),aAe=Hj();function Lh(e){var n=-1,a=e==null?0:e.length;for(this.clear();++n{var $j=qj(),tAe=ey(),rAe=gT();function oAe(){this.size=0,this.__data__={hash:new $j,map:new(rAe||tAe),string:new $j}}Wj.exports=oAe});var zj=He((L7n,jj)=>{function uAe(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}jj.exports=uAe});var ry=He((P7n,Vj)=>{var iAe=zj();function lAe(e,n){var a=e.__data__;return iAe(n)?a[typeof n=="string"?"string":"hash"]:a.map}Vj.exports=lAe});var Kj=He((N7n,Qj)=>{var cAe=ry();function sAe(e){var n=cAe(this,e).delete(e);return this.size-=n?1:0,n}Qj.exports=sAe});var Xj=He((O7n,Yj)=>{var vAe=ry();function fAe(e){return vAe(this,e).get(e)}Yj.exports=fAe});var ez=He((U7n,Zj)=>{var _Ae=ry();function pAe(e){return _Ae(this,e).has(e)}Zj.exports=pAe});var az=He((k7n,nz)=>{var mAe=ry();function dAe(e,n){var a=mAe(this,e),t=a.size;return a.set(e,n),this.size+=a.size==t?0:1,this}nz.exports=dAe});var w3=He((B7n,tz)=>{var hAe=xj(),gAe=Kj(),DAe=Xj(),RAe=ez(),yAe=az();function Ph(e){var n=-1,a=e==null?0:e.length;for(this.clear();++n{var wAe=ey(),bAe=gT(),EAe=w3(),IAe=200;function TAe(e,n){var a=this.__data__;if(a instanceof wAe){var t=a.__data__;if(!bAe||t.length{var SAe=ey(),CAe=Kx(),FAe=Xx(),GAe=ej(),MAe=aj(),AAe=oz();function Nh(e){var n=this.__data__=new SAe(e);this.size=n.size}Nh.prototype.clear=CAe;Nh.prototype.delete=FAe;Nh.prototype.get=GAe;Nh.prototype.has=MAe;Nh.prototype.set=AAe;uz.exports=Nh});var cz=He((q7n,lz)=>{var LAe="__lodash_hash_undefined__";function PAe(e){return this.__data__.set(e,LAe),this}lz.exports=PAe});var vz=He(($7n,sz)=>{function NAe(e){return this.__data__.has(e)}sz.exports=NAe});var _z=He((W7n,fz)=>{var OAe=w3(),UAe=cz(),kAe=vz();function DT(e){var n=-1,a=e==null?0:e.length;for(this.__data__=new OAe;++n{function BAe(e,n){for(var a=-1,t=e==null?0:e.length;++a{function HAe(e,n){return e.has(n)}dz.exports=HAe});var b3=He((z7n,gz)=>{var JAe=_z(),qAe=mz(),$Ae=hz(),WAe=1,xAe=2;function jAe(e,n,a,t,r,u){var i=a&WAe,l=e.length,s=n.length;if(l!=s&&!(i&&s>l))return!1;var h=u.get(e),p=u.get(n);if(h&&p)return h==n&&p==e;var R=-1,E=!0,w=a&xAe?new JAe:void 0;for(u.set(e,n),u.set(n,e);++R{var zAe=Wv(),VAe=zAe.Uint8Array;Dz.exports=VAe});var wz=He((Q7n,yz)=>{function QAe(e){var n=-1,a=Array(e.size);return e.forEach(function(t,r){a[++n]=[r,t]}),a}yz.exports=QAe});var Ez=He((K7n,bz)=>{function KAe(e){var n=-1,a=Array(e.size);return e.forEach(function(t){a[++n]=t}),a}bz.exports=KAe});var Fz=He((Y7n,Cz)=>{var Iz=hT(),Tz=Rz(),YAe=d3(),XAe=b3(),ZAe=wz(),e2e=Ez(),n2e=1,a2e=2,t2e="[object Boolean]",r2e="[object Date]",o2e="[object Error]",u2e="[object Map]",i2e="[object Number]",l2e="[object RegExp]",c2e="[object Set]",s2e="[object String]",v2e="[object Symbol]",f2e="[object ArrayBuffer]",_2e="[object DataView]",Sz=Iz?Iz.prototype:void 0,E3=Sz?Sz.valueOf:void 0;function p2e(e,n,a,t,r,u,i){switch(a){case _2e:if(e.byteLength!=n.byteLength||e.byteOffset!=n.byteOffset)return!1;e=e.buffer,n=n.buffer;case f2e:return!(e.byteLength!=n.byteLength||!u(new Tz(e),new Tz(n)));case t2e:case r2e:case i2e:return YAe(+e,+n);case o2e:return e.name==n.name&&e.message==n.message;case l2e:case s2e:return e==n+"";case u2e:var l=ZAe;case c2e:var s=t&n2e;if(l||(l=e2e),e.size!=n.size&&!s)return!1;var h=i.get(e);if(h)return h==n;t|=a2e,i.set(e,n);var p=XAe(l(e),l(n),t,r,u,i);return i.delete(e),p;case v2e:if(E3)return E3.call(e)==E3.call(n)}return!1}Cz.exports=p2e});var Mz=He((X7n,Gz)=>{function m2e(e,n){for(var a=-1,t=n.length,r=e.length;++a{var d2e=Array.isArray;Az.exports=d2e});var Pz=He((eOn,Lz)=>{var h2e=Mz(),g2e=RT();function D2e(e,n,a){var t=n(e);return g2e(e)?t:h2e(t,a(e))}Lz.exports=D2e});var Oz=He((nOn,Nz)=>{function R2e(e,n){for(var a=-1,t=e==null?0:e.length,r=0,u=[];++a{function y2e(){return[]}Uz.exports=y2e});var Jz=He((tOn,Hz)=>{var w2e=Oz(),b2e=kz(),E2e=Object.prototype,I2e=E2e.propertyIsEnumerable,Bz=Object.getOwnPropertySymbols,T2e=Bz?function(e){return e==null?[]:(e=Object(e),w2e(Bz(e),function(n){return I2e.call(e,n)}))}:b2e;Hz.exports=T2e});var $z=He((rOn,qz)=>{function S2e(e,n){for(var a=-1,t=Array(e);++a{function C2e(e){return e!=null&&typeof e=="object"}Wz.exports=C2e});var jz=He((uOn,xz)=>{var F2e=ay(),G2e=oy(),M2e="[object Arguments]";function A2e(e){return G2e(e)&&F2e(e)==M2e}xz.exports=A2e});var Kz=He((iOn,Qz)=>{var zz=jz(),L2e=oy(),Vz=Object.prototype,P2e=Vz.hasOwnProperty,N2e=Vz.propertyIsEnumerable,O2e=zz((function(){return arguments})())?zz:function(e){return L2e(e)&&P2e.call(e,"callee")&&!N2e.call(e,"callee")};Qz.exports=O2e});var Xz=He((lOn,Yz)=>{function U2e(){return!1}Yz.exports=U2e});var I3=He((uy,Oh)=>{var k2e=Wv(),B2e=Xz(),nV=typeof uy=="object"&&uy&&!uy.nodeType&&uy,Zz=nV&&typeof Oh=="object"&&Oh&&!Oh.nodeType&&Oh,H2e=Zz&&Zz.exports===nV,eV=H2e?k2e.Buffer:void 0,J2e=eV?eV.isBuffer:void 0,q2e=J2e||B2e;Oh.exports=q2e});var tV=He((cOn,aV)=>{var $2e=9007199254740991,W2e=/^(?:0|[1-9]\d*)$/;function x2e(e,n){var a=typeof e;return n=n==null?$2e:n,!!n&&(a=="number"||a!="symbol"&&W2e.test(e))&&e>-1&&e%1==0&&e{var j2e=9007199254740991;function z2e(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=j2e}rV.exports=z2e});var uV=He((vOn,oV)=>{var V2e=ay(),Q2e=T3(),K2e=oy(),Y2e="[object Arguments]",X2e="[object Array]",Z2e="[object Boolean]",eLe="[object Date]",nLe="[object Error]",aLe="[object Function]",tLe="[object Map]",rLe="[object Number]",oLe="[object Object]",uLe="[object RegExp]",iLe="[object Set]",lLe="[object String]",cLe="[object WeakMap]",sLe="[object ArrayBuffer]",vLe="[object DataView]",fLe="[object Float32Array]",_Le="[object Float64Array]",pLe="[object Int8Array]",mLe="[object Int16Array]",dLe="[object Int32Array]",hLe="[object Uint8Array]",gLe="[object Uint8ClampedArray]",DLe="[object Uint16Array]",RLe="[object Uint32Array]",_o={};_o[fLe]=_o[_Le]=_o[pLe]=_o[mLe]=_o[dLe]=_o[hLe]=_o[gLe]=_o[DLe]=_o[RLe]=!0;_o[Y2e]=_o[X2e]=_o[sLe]=_o[Z2e]=_o[vLe]=_o[eLe]=_o[nLe]=_o[aLe]=_o[tLe]=_o[rLe]=_o[oLe]=_o[uLe]=_o[iLe]=_o[lLe]=_o[cLe]=!1;function yLe(e){return K2e(e)&&Q2e(e.length)&&!!_o[V2e(e)]}oV.exports=yLe});var lV=He((fOn,iV)=>{function wLe(e){return function(n){return e(n)}}iV.exports=wLe});var sV=He((iy,Uh)=>{var bLe=h3(),cV=typeof iy=="object"&&iy&&!iy.nodeType&&iy,ly=cV&&typeof Uh=="object"&&Uh&&!Uh.nodeType&&Uh,ELe=ly&&ly.exports===cV,S3=ELe&&bLe.process,ILe=(function(){try{var e=ly&&ly.require&&ly.require("util").types;return e||S3&&S3.binding&&S3.binding("util")}catch{}})();Uh.exports=ILe});var C3=He((_On,_V)=>{var TLe=uV(),SLe=lV(),vV=sV(),fV=vV&&vV.isTypedArray,CLe=fV?SLe(fV):TLe;_V.exports=CLe});var mV=He((pOn,pV)=>{var FLe=$z(),GLe=Kz(),MLe=RT(),ALe=I3(),LLe=tV(),PLe=C3(),NLe=Object.prototype,OLe=NLe.hasOwnProperty;function ULe(e,n){var a=MLe(e),t=!a&&GLe(e),r=!a&&!t&&ALe(e),u=!a&&!t&&!r&&PLe(e),i=a||t||r||u,l=i?FLe(e.length,String):[],s=l.length;for(var h in e)(n||OLe.call(e,h))&&!(i&&(h=="length"||r&&(h=="offset"||h=="parent")||u&&(h=="buffer"||h=="byteLength"||h=="byteOffset")||LLe(h,s)))&&l.push(h);return l}pV.exports=ULe});var hV=He((mOn,dV)=>{var kLe=Object.prototype;function BLe(e){var n=e&&e.constructor,a=typeof n=="function"&&n.prototype||kLe;return e===a}dV.exports=BLe});var DV=He((dOn,gV)=>{function HLe(e,n){return function(a){return e(n(a))}}gV.exports=HLe});var yV=He((hOn,RV)=>{var JLe=DV(),qLe=JLe(Object.keys,Object);RV.exports=qLe});var bV=He((gOn,wV)=>{var $Le=hV(),WLe=yV(),xLe=Object.prototype,jLe=xLe.hasOwnProperty;function zLe(e){if(!$Le(e))return WLe(e);var n=[];for(var a in Object(e))jLe.call(e,a)&&a!="constructor"&&n.push(a);return n}wV.exports=zLe});var IV=He((DOn,EV)=>{var VLe=D3(),QLe=T3();function KLe(e){return e!=null&&QLe(e.length)&&!VLe(e)}EV.exports=KLe});var SV=He((ROn,TV)=>{var YLe=mV(),XLe=bV(),ZLe=IV();function e3e(e){return ZLe(e)?YLe(e):XLe(e)}TV.exports=e3e});var GV=He((yOn,FV)=>{var n3e=Pz(),a3e=Jz(),t3e=SV();function r3e(e){return n3e(e,t3e,a3e)}FV.exports=r3e});var LV=He((wOn,AV)=>{var MV=GV(),o3e=1,u3e=Object.prototype,i3e=u3e.hasOwnProperty;function l3e(e,n,a,t,r,u){var i=a&o3e,l=MV(e),s=l.length,h=MV(n),p=h.length;if(s!=p&&!i)return!1;for(var R=s;R--;){var E=l[R];if(!(i?E in n:i3e.call(n,E)))return!1}var w=u.get(e),I=u.get(n);if(w&&I)return w==n&&I==e;var L=!0;u.set(e,n),u.set(n,e);for(var U=i;++R{var c3e=ym(),s3e=Wv(),v3e=c3e(s3e,"DataView");PV.exports=v3e});var UV=He((EOn,OV)=>{var f3e=ym(),_3e=Wv(),p3e=f3e(_3e,"Promise");OV.exports=p3e});var BV=He((IOn,kV)=>{var m3e=ym(),d3e=Wv(),h3e=m3e(d3e,"Set");kV.exports=h3e});var JV=He((TOn,HV)=>{var g3e=ym(),D3e=Wv(),R3e=g3e(D3e,"WeakMap");HV.exports=R3e});var QV=He((SOn,VV)=>{var F3=NV(),G3=gT(),M3=UV(),A3=BV(),L3=JV(),zV=ay(),kh=y3(),qV="[object Map]",y3e="[object Object]",$V="[object Promise]",WV="[object Set]",xV="[object WeakMap]",jV="[object DataView]",w3e=kh(F3),b3e=kh(G3),E3e=kh(M3),I3e=kh(A3),T3e=kh(L3),wm=zV;(F3&&wm(new F3(new ArrayBuffer(1)))!=jV||G3&&wm(new G3)!=qV||M3&&wm(M3.resolve())!=$V||A3&&wm(new A3)!=WV||L3&&wm(new L3)!=xV)&&(wm=function(e){var n=zV(e),a=n==y3e?e.constructor:void 0,t=a?kh(a):"";if(t)switch(t){case w3e:return jV;case b3e:return qV;case E3e:return $V;case I3e:return WV;case T3e:return xV}return n});VV.exports=wm});var tQ=He((COn,aQ)=>{var P3=iz(),S3e=b3(),C3e=Fz(),F3e=LV(),KV=QV(),YV=RT(),XV=I3(),G3e=C3(),M3e=1,ZV="[object Arguments]",eQ="[object Array]",yT="[object Object]",A3e=Object.prototype,nQ=A3e.hasOwnProperty;function L3e(e,n,a,t,r,u){var i=YV(e),l=YV(n),s=i?eQ:KV(e),h=l?eQ:KV(n);s=s==ZV?yT:s,h=h==ZV?yT:h;var p=s==yT,R=h==yT,E=s==h;if(E&&XV(e)){if(!XV(n))return!1;i=!0,p=!1}if(E&&!p)return u||(u=new P3),i||G3e(e)?S3e(e,n,a,t,r,u):C3e(e,n,s,a,t,r,u);if(!(a&M3e)){var w=p&&nQ.call(e,"__wrapped__"),I=R&&nQ.call(n,"__wrapped__");if(w||I){var L=w?e.value():e,U=I?n.value():n;return u||(u=new P3),r(L,U,a,t,u)}}return E?(u||(u=new P3),F3e(e,n,a,t,r,u)):!1}aQ.exports=L3e});var iQ=He((FOn,uQ)=>{var P3e=tQ(),rQ=oy();function oQ(e,n,a,t,r){return e===n?!0:e==null||n==null||!rQ(e)&&!rQ(n)?e!==e&&n!==n:P3e(e,n,a,t,oQ,r)}uQ.exports=oQ});var cQ=He((GOn,lQ)=>{var N3e=iQ();function O3e(e,n){return N3e(e,n)}lQ.exports=O3e});var zQ=He((NUn,sPe)=>{sPe.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 dne=He((Xy,FN)=>{typeof window<"u"&&(function(n,a){typeof Xy=="object"&&typeof FN=="object"?FN.exports=a():typeof define=="function"&&define.amd?define([],a):typeof Xy=="object"?Xy.Hls=a():n.Hls=a()})(Xy,function(){return(function(e){var n={};function a(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,a),r.l=!0,r.exports}return a.m=e,a.c=n,a.d=function(t,r,u){a.o(t,r)||Object.defineProperty(t,r,{enumerable:!0,get:u})},a.r=function(t){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.t=function(t,r){if(r&1&&(t=a(t)),r&8||r&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}),r&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 r=t&&t.__esModule?function(){return t.default}:function(){return t};return a.d(r,"a",r),r},a.o=function(t,r){return Object.prototype.hasOwnProperty.call(t,r)},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,r="~";function u(){}Object.create&&(u.prototype=Object.create(null),new u().__proto__||(r=!1));function i(p,R,E){this.fn=p,this.context=R,this.once=E||!1}function l(p,R,E,w,I){if(typeof E!="function")throw new TypeError("The listener must be a function");var L=new i(E,w||p,I),U=r?r+R:R;return p._events[U]?p._events[U].fn?p._events[U]=[p._events[U],L]:p._events[U].push(L):(p._events[U]=L,p._eventsCount++),p}function s(p,R){--p._eventsCount===0?p._events=new u:delete p._events[R]}function h(){this._events=new u,this._eventsCount=0}h.prototype.eventNames=function(){var R=[],E,w;if(this._eventsCount===0)return R;for(w in E=this._events)t.call(E,w)&&R.push(r?w.slice(1):w);return Object.getOwnPropertySymbols?R.concat(Object.getOwnPropertySymbols(E)):R},h.prototype.listeners=function(R){var E=r?r+R:R,w=this._events[E];if(!w)return[];if(w.fn)return[w.fn];for(var I=0,L=w.length,U=new Array(L);I0},!1)}function p(R,E){for(var w={main:[E]},I={main:[]},L={main:{}};h(w);)for(var U=Object.keys(w),V=0;V>>8^Dt&255^99,te[Ia]=Dt,le[Dt]=Ia;var _t=kn[Ia],Ha=kn[_t],Tr=kn[Ha],Xe=kn[Dt]*257^Dt*16843008;Z[Ia]=Xe<<24|Xe>>>8,ee[Ia]=Xe<<16|Xe>>>16,me[Ia]=Xe<<8|Xe>>>24,$e[Ia]=Xe,Xe=Tr*16843009^Ha*65537^_t*257^Ia*16843008,dn[Dt]=Xe<<24|Xe>>>8,qn[Dt]=Xe<<16|Xe>>>16,Mn[Dt]=Xe<<8|Xe>>>24,An[Dt]=Xe,Ia?(Ia=_t^kn[kn[kn[Tr^_t]]],Da^=kn[kn[Da]]):Ia=Da=1}},V.expandKey=function(te){for(var le=this.uint8ArrayToUint32Array_(te),ne=!0,Z=0;Z>>6)+1,O=(X[k+2]&60)>>>2,O>Ae.length-1){W.trigger(t.default.ERROR,{type:r.ErrorTypes.MEDIA_ERROR,details:r.ErrorDetails.FRAG_PARSING_ERROR,fatal:!0,reason:"invalid ADTS sampling index:"+O});return}return K=(X[k+2]&1)<<2,K|=(X[k+3]&192)>>>6,l.logger.log("manifest codec:"+S+",ADTS data:type:"+P+",sampleingIndex:"+O+"["+Ae[O]+"Hz],channelConfig:"+K),/firefox/i.test(ce)?O>=6?(P=5,ve=new Array(4),j=O-3):(P=2,ve=new Array(2),j=O):ce.indexOf("android")!==-1?(P=2,ve=new Array(2),j=O):(P=5,ve=new Array(4),S&&(S.indexOf("mp4a.40.29")!==-1||S.indexOf("mp4a.40.5")!==-1)||!S&&O>=6?j=O-3:((S&&S.indexOf("mp4a.40.2")!==-1&&(O>=6&&K===1||/vivaldi/i.test(ce))||!S&&K===1)&&(P=2,ve=new Array(2)),j=O)),ve[0]=P<<3,ve[0]|=(O&14)>>1,ve[1]|=(O&1)<<7,ve[1]|=K<<3,P===5&&(ve[1]|=(j&14)>>1,ve[2]=(j&1)<<7,ve[2]|=8,ve[3]=0),{config:ve,samplerate:Ae[O],channelCount:K,codec:"mp4a.40."+P,manifestCodec:Ie}}function p(W,X){return W[X]===255&&(W[X+1]&246)===240}function R(W,X){return W[X+1]&1?7:9}function E(W,X){return(W[X+3]&3)<<11|W[X+4]<<3|(W[X+5]&224)>>>5}function w(W,X){return!!(X+10&&X+O+j<=ve)return K=k+S*P,{headerLength:O,frameLength:j,stamp:K}}function Q(W,X,k,S,P){var O=U(W.samplerate),j=V(X,k,S,P,O);if(j){var K=j.stamp,ve=j.headerLength,ce=j.frameLength,Ie={unit:X.subarray(k+ve,k+ve+ce),pts:K,dts:K};return W.samples.push(Ie),{sample:Ie,length:ce+ve}}}var te=a("./src/demux/id3.js"),le=(function(){function W(k,S,P){this.observer=k,this.config=P,this.remuxer=S}var X=W.prototype;return X.resetInitSegment=function(S,P,O,j){this._audioTrack={container:"audio/adts",type:"audio",id:0,sequenceNumber:0,isAAC:!0,samples:[],len:0,manifestCodec:P,duration:j,inputTimeScale:9e4}},X.resetTimeStamp=function(){},W.probe=function(S){if(!S)return!1;for(var P=te.default.getID3Data(S,0)||[],O=P.length,j=S.length;Ok.length)){var j=this.parseHeader(k,S);if(j&&S+j.frameLength<=k.length){var K=j.samplesPerFrame*9e4/j.sampleRate,ve=P+O*K,ce={unit:k.subarray(S,S+j.frameLength),pts:ve,dts:ve};return X.config=[],X.channelCount=j.channelCount,X.samplerate=j.sampleRate,X.samples.push(ce),{sample:ce,length:j.frameLength}}}},parseHeader:function(X,k){var S=X[k+1]>>3&3,P=X[k+1]>>1&3,O=X[k+2]>>4&15,j=X[k+2]>>2&3,K=X[k+2]>>1&1;if(S!==1&&O!==0&&O!==15&&j!==3){var ve=S===3?3-P:P===3?3:4,ce=ee.BitratesMap[ve*14+O-1]*1e3,Ie=S===3?0:S===2?1:2,Ae=ee.SamplingRateMap[Ie*3+j],Ne=X[k+3]>>6===3?1:2,ke=ee.SamplesCoefficients[S][P],Rn=ee.BytesInSlot[P],Ln=ke*8*Rn,ze=parseInt(ke*ce/Ae+K,10)*Rn;return{sampleRate:Ae,channelCount:Ne,frameLength:ze,samplesPerFrame:Ln}}},isHeaderPattern:function(X,k){return X[k]===255&&(X[k+1]&224)===224&&(X[k+1]&6)!==0},isHeader:function(X,k){return!!(k+1S?(this.word<<=S,this.bitsAvailable-=S):(S-=this.bitsAvailable,P=S>>3,S-=P>>3,this.bytesAvailable-=P,this.loadWord(),this.word<<=S,this.bitsAvailable-=S)},X.readBits=function(S){var P=Math.min(this.bitsAvailable,S),O=this.word>>>32-P;return S>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=S-P,P>0&&this.bitsAvailable?O<>>S)!==0)return this.word<<=S,this.bitsAvailable-=S,S;return this.loadWord(),S+this.skipLZ()},X.skipUEG=function(){this.skipBits(1+this.skipLZ())},X.skipEG=function(){this.skipBits(1+this.skipLZ())},X.readUEG=function(){var S=this.skipLZ();return this.readBits(S+1)-1},X.readEG=function(){var S=this.readUEG();return 1&S?1+S>>>1:-1*(S>>>1)},X.readBoolean=function(){return this.readBits(1)===1},X.readUByte=function(){return this.readBits(8)},X.readUShort=function(){return this.readBits(16)},X.readUInt=function(){return this.readBits(32)},X.skipScalingList=function(S){var P=8,O=8,j,K;for(j=0;j=S.length){O();return}if(!(S[P].unit.length<32)){var j=this.decrypter.isSync();if(this.decryptAacSample(S,P,O,j),!j)return}}},X.getAvcEncryptedData=function(S){for(var P=Math.floor((S.length-48)/160)*16+16,O=new Int8Array(P),j=0,K=32;K<=S.length-16;K+=160,j+=16)O.set(S.subarray(K,K+16),j);return O},X.getAvcDecryptedUnit=function(S,P){P=new Uint8Array(P);for(var O=0,j=32;j<=S.length-16;j+=160,O+=16)S.set(P.subarray(O,O+16),j);return S},X.decryptAvcSample=function(S,P,O,j,K,ve){var ce=this.discardEPB(K.data),Ie=this.getAvcEncryptedData(ce),Ae=this;this.decryptBuffer(Ie.buffer,function(Ne){K.data=Ae.getAvcDecryptedUnit(ce,Ne),ve||Ae.decryptAvcSamples(S,P,O+1,j)})},X.decryptAvcSamples=function(S,P,O,j){for(;;P++,O=0){if(P>=S.length){j();return}for(var K=S[P].units;!(O>=K.length);O++){var ve=K[O];if(!(ve.length<=48||ve.type!==1&&ve.type!==5)){var ce=this.decrypter.isSync();if(this.decryptAvcSample(S,P,O,j,ve,ce),!ce)return}}}},W})(),qn=dn,Mn={video:1,audio:2,id3:3,text:4},An=(function(){function W(k,S,P,O){this.observer=k,this.config=P,this.typeSupported=O,this.remuxer=S,this.sampleAes=null}var X=W.prototype;return X.setDecryptData=function(S){S!=null&&S.key!=null&&S.method==="SAMPLE-AES"?this.sampleAes=new qn(this.observer,this.config,S,this.discardEPB):this.sampleAes=null},W.probe=function(S){var P=W._syncOffset(S);return P<0?!1:(P&&l.logger.warn("MPEG2-TS detected but first sync word found @ offset "+P+", junk ahead ?"),!0)},W._syncOffset=function(S){for(var P=Math.min(1e3,S.length-564),O=0;O>4,Ae>1){if(Ne=K+5+S[K+4],Ne===K+188)continue}else Ne=K+4;switch(Ie){case $a:ce&&(rr&&(ke=po(rr))&&Jo(ke,!1),rr={data:[],size:0}),rr&&(rr.data.push(S.subarray(Ne,K+188)),rr.size+=K+188-Ne);break;case qt:ce&&(Rt&&(ke=po(Rt))&&($n.isAAC?Pu(ke):Co(ke)),Rt={data:[],size:0}),Rt&&(Rt.data.push(S.subarray(Ne,K+188)),Rt.size+=K+188-Ne);break;case Pr:ce&&(Jr&&(ke=po(Jr))&&di(ke),Jr={data:[],size:0}),Jr&&(Jr.data.push(S.subarray(Ne,K+188)),Jr.size+=K+188-Ne);break;case 0:ce&&(Ne+=S[Ne]+1),Xa=this._pmtId=At(S,Ne);break;case Xa:ce&&(Ne+=S[Ne]+1);var oo=hr(S,Ne,this.typeSupported.mpeg===!0||this.typeSupported.mp3===!0,this.sampleAes!=null);$a=oo.avc,$a>0&&(ze.pid=$a),qt=oo.audio,qt>0&&($n.pid=qt,$n.isAAC=oo.isAAC),Pr=oo.id3,Pr>0&&(Ra.pid=Pr),Rn&&!Ln&&(l.logger.log("reparse from beginning"),Rn=!1,K=qo-188),Ln=this.pmtParsed=!0;break;case 17:case 8191:break;default:Rn=!0;break}}else this.observer.trigger(t.default.ERROR,{type:r.ErrorTypes.MEDIA_ERROR,details:r.ErrorDetails.FRAG_PARSING_ERROR,fatal:!1,reason:"TS packet did not start with 0x47"});rr&&(ke=po(rr))?(Jo(ke,!0),ze.pesData=null):ze.pesData=rr,Rt&&(ke=po(Rt))?($n.isAAC?Pu(ke):Co(ke),$n.pesData=null):(Rt&&Rt.size&&l.logger.log("last AAC PES packet truncated,might overlap between fragments"),$n.pesData=Rt),Jr&&(ke=po(Jr))?(di(ke),Ra.pesData=null):Ra.pesData=Jr,this.sampleAes==null?this.remuxer.remux($n,ze,Ra,this._txtTrack,P,O,j):this.decryptAndRemux($n,ze,Ra,this._txtTrack,P,O,j)},X.decryptAndRemux=function(S,P,O,j,K,ve,ce){if(S.samples&&S.isAAC){var Ie=this;this.sampleAes.decryptAacSamples(S.samples,0,function(){Ie.decryptAndRemuxAvc(S,P,O,j,K,ve,ce)})}else this.decryptAndRemuxAvc(S,P,O,j,K,ve,ce)},X.decryptAndRemuxAvc=function(S,P,O,j,K,ve,ce){if(P.samples){var Ie=this;this.sampleAes.decryptAvcSamples(P.samples,0,0,function(){Ie.remuxer.remux(S,P,O,j,K,ve,ce)})}else this.remuxer.remux(S,P,O,j,K,ve,ce)},X.destroy=function(){this._initPTS=this._initDTS=void 0,this._duration=0},X._parsePAT=function(S,P){return(S[P+10]&31)<<8|S[P+11]},X._parsePMT=function(S,P,O,j){var K,ve,ce,Ie,Ae={audio:-1,avc:-1,id3:-1,isAAC:!0};for(K=(S[P+1]&15)<<8|S[P+2],ve=P+3+K-4,ce=(S[P+10]&15)<<8|S[P+11],P+=12+ce;P1;){var Ln=new Uint8Array(Rn[0].length+Rn[1].length);Ln.set(Rn[0]),Ln.set(Rn[1],Rn[0].length),Rn[0]=Ln,Rn.splice(1,1)}if(O=Rn[0],K=(O[0]<<16)+(O[1]<<8)+O[2],K===1){if(ve=(O[4]<<8)+O[5],ve&&ve>S.size-6||(j=O[7],j&192&&(Ae=(O[9]&14)*536870912+(O[10]&255)*4194304+(O[11]&254)*16384+(O[12]&255)*128+(O[13]&254)/2,Ae>4294967295&&(Ae-=8589934592),j&64?(Ne=(O[14]&14)*536870912+(O[15]&255)*4194304+(O[16]&254)*16384+(O[17]&255)*128+(O[18]&254)/2,Ne>4294967295&&(Ne-=8589934592),Ae-Ne>60*9e4&&(l.logger.warn(Math.round((Ae-Ne)/9e4)+"s delta between PTS and DTS, align them"),Ae=Ne)):Ne=Ae),ce=O[8],ke=ce+9,S.size<=ke))return null;S.size-=ke,Ie=new Uint8Array(S.size);for(var ze=0,$n=Rn.length;ze<$n;ze++){O=Rn[ze];var Ra=O.byteLength;if(ke)if(ke>Ra){ke-=Ra;continue}else O=O.subarray(ke),Ra-=ke,ke=0;Ie.set(O,P),P+=Ra}return ve&&(ve-=ce+3),{data:Ie,pts:Ae,dts:Ne,len:ve}}else return null},X.pushAccesUnit=function(S,P){if(S.units.length&&S.frame){var O=P.samples,j=O.length;if(isNaN(S.pts))if(j){var K=O[j-1];S.pts=K.pts,S.dts=K.dts}else{P.dropped++;return}!this.config.forceKeyFrameOnDiscontinuity||S.key===!0||P.sps&&(j||this.contiguous)?(S.id=j,O.push(S)):P.dropped++}S.debug.length&&l.logger.log(S.pts+"/"+S.dts+":"+S.debug)},X._parseAVCPES=function(S,P){var O=this,j=this._avcTrack,K=this._parseAVCNALu(S.data),ve=!1,ce,Ie=this.avcSample,Ae,Ne=!1,ke,Rn=this.pushAccesUnit.bind(this),Ln=function($n,Ra,$a,qt){return{key:$n,pts:Ra,dts:$a,units:[],debug:qt}};S.data=null,Ie&&K.length&&!j.audFound&&(Rn(Ie,j),Ie=this.avcSample=Ln(!1,S.pts,S.dts,"")),K.forEach(function(ze){switch(ze.type){case 1:Ae=!0,Ie||(Ie=O.avcSample=Ln(!0,S.pts,S.dts,"")),ve&&(Ie.debug+="NDR "),Ie.frame=!0;var $n=ze.data;if(Ne&&$n.length>4){var Ra=new Qe($n).readSliceType();(Ra===2||Ra===4||Ra===7||Ra===9)&&(Ie.key=!0)}break;case 5:Ae=!0,Ie||(Ie=O.avcSample=Ln(!0,S.pts,S.dts,"")),ve&&(Ie.debug+="IDR "),Ie.key=!0,Ie.frame=!0;break;case 6:Ae=!0,ve&&Ie&&(Ie.debug+="SEI "),ce=new Qe(O.discardEPB(ze.data)),ce.readUByte();for(var $a=0,qt=0,Pr=!1,Xa=0;!Pr&&ce.bytesAvailable>1;){$a=0;do Xa=ce.readUByte(),$a+=Xa;while(Xa===255);qt=0;do Xa=ce.readUByte(),qt+=Xa;while(Xa===255);if($a===4&&ce.bytesAvailable!==0){Pr=!0;var rr=ce.readUByte();if(rr===181){var Rt=ce.readUShort();if(Rt===49){var Jr=ce.readUInt();if(Jr===1195456820){var At=ce.readUByte();if(At===3){var hr=ce.readUByte(),po=ce.readUByte(),Jo=31&hr,Pu=[hr,po];for(ke=0;ke16){var Co=[];for(ke=0;ke<16;ke++)Co.push(ce.readUByte().toString(16)),(ke===3||ke===5||ke===7||ke===9)&&Co.push("-");var di=qt-16,qo=new Uint8Array(di);for(ke=0;ke0){if(P.pts>=S[O-1].pts)S.push(P);else for(var j=O-1;j>=0;j--)if(P.pts=0)Ne={data:S.subarray(Rn,P-ce-1),type:Ln},Ae.push(Ne);else{var ze=this._getLastNalUnit();if(ze&&(Ie&&P<=4-Ie&&ze.state&&(ze.data=ze.data.subarray(0,ze.data.byteLength-Ie)),K=P-ce-1,K>0)){var $n=new Uint8Array(ze.data.byteLength+K);$n.set(ze.data,0),$n.set(S.subarray(0,K),ze.data.byteLength),ze.data=$n}}P=0&&ce>=0&&(Ne={data:S.subarray(Rn,O),type:Ln,state:ce},Ae.push(Ne)),Ae.length===0){var Ra=this._getLastNalUnit();if(Ra){var $a=new Uint8Array(Ra.data.byteLength+S.byteLength);$a.set(Ra.data,0),$a.set(S,Ra.data.byteLength),Ra.data=$a}}return ve.naluState=ce,Ae},X.discardEPB=function(S){for(var P=S.byteLength,O=[],j=1,K,ve;j1&&(l.logger.log("AAC: align PTS for overlapping frames by "+Math.round((Ra-j)/90)),j=Ra)}for(;Ne>24&255,K[1]=P>>16&255,K[2]=P>>8&255,K[3]=P&255,K.set(k,4),O=0,P=8;O>24&255,k>>16&255,k>>8&255,k&255,P>>24,P>>16&255,P>>8&255,P&255,O>>24,O>>16&255,O>>8&255,O&255,85,196,0,0]))},W.mdia=function(k){return W.box(W.types.mdia,W.mdhd(k.timescale,k.duration),W.hdlr(k.type),W.minf(k))},W.mfhd=function(k){return W.box(W.types.mfhd,new Uint8Array([0,0,0,0,k>>24,k>>16&255,k>>8&255,k&255]))},W.minf=function(k){return k.type==="audio"?W.box(W.types.minf,W.box(W.types.smhd,W.SMHD),W.DINF,W.stbl(k)):W.box(W.types.minf,W.box(W.types.vmhd,W.VMHD),W.DINF,W.stbl(k))},W.moof=function(k,S,P){return W.box(W.types.moof,W.mfhd(k),W.traf(P,S))},W.moov=function(k){for(var S=k.length,P=[];S--;)P[S]=W.trak(k[S]);return W.box.apply(null,[W.types.moov,W.mvhd(k[0].timescale,k[0].duration)].concat(P).concat(W.mvex(k)))},W.mvex=function(k){for(var S=k.length,P=[];S--;)P[S]=W.trex(k[S]);return W.box.apply(null,[W.types.mvex].concat(P))},W.mvhd=function(k,S){S*=k;var P=Math.floor(S/(_t+1)),O=Math.floor(S%(_t+1)),j=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,k>>24&255,k>>16&255,k>>8&255,k&255,P>>24,P>>16&255,P>>8&255,P&255,O>>24,O>>16&255,O>>8&255,O&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 W.box(W.types.mvhd,j)},W.sdtp=function(k){var S=k.samples||[],P=new Uint8Array(4+S.length),O,j;for(j=0;j>>8&255),S.push(K&255),S=S.concat(Array.prototype.slice.call(j));for(O=0;O>>8&255),P.push(K&255),P=P.concat(Array.prototype.slice.call(j));var ve=W.box(W.types.avcC,new Uint8Array([1,S[3],S[4],S[5],255,224|k.sps.length].concat(S).concat([k.pps.length]).concat(P))),ce=k.width,Ie=k.height,Ae=k.pixelRatio[0],Ne=k.pixelRatio[1];return W.box(W.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,ce>>8&255,ce&255,Ie>>8&255,Ie&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]),ve,W.box(W.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),W.box(W.types.pasp,new Uint8Array([Ae>>24,Ae>>16&255,Ae>>8&255,Ae&255,Ne>>24,Ne>>16&255,Ne>>8&255,Ne&255])))},W.esds=function(k){var S=k.config.length;return new Uint8Array([0,0,0,0,3,23+S,0,1,0,4,15+S,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([S]).concat(k.config).concat([6,1,2]))},W.mp4a=function(k){var S=k.samplerate;return W.box(W.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,k.channelCount,0,16,0,0,0,0,S>>8&255,S&255,0,0]),W.box(W.types.esds,W.esds(k)))},W.mp3=function(k){var S=k.samplerate;return W.box(W.types[".mp3"],new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,k.channelCount,0,16,0,0,0,0,S>>8&255,S&255,0,0]))},W.stsd=function(k){return k.type==="audio"?!k.isAAC&&k.codec==="mp3"?W.box(W.types.stsd,W.STSD,W.mp3(k)):W.box(W.types.stsd,W.STSD,W.mp4a(k)):W.box(W.types.stsd,W.STSD,W.avc1(k))},W.tkhd=function(k){var S=k.id,P=k.duration*k.timescale,O=k.width,j=k.height,K=Math.floor(P/(_t+1)),ve=Math.floor(P%(_t+1));return W.box(W.types.tkhd,new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,S>>24&255,S>>16&255,S>>8&255,S&255,0,0,0,0,K>>24,K>>16&255,K>>8&255,K&255,ve>>24,ve>>16&255,ve>>8&255,ve&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,O>>8&255,O&255,0,0,j>>8&255,j&255,0,0]))},W.traf=function(k,S){var P=W.sdtp(k),O=k.id,j=Math.floor(S/(_t+1)),K=Math.floor(S%(_t+1));return W.box(W.types.traf,W.box(W.types.tfhd,new Uint8Array([0,0,0,0,O>>24,O>>16&255,O>>8&255,O&255])),W.box(W.types.tfdt,new Uint8Array([1,0,0,0,j>>24,j>>16&255,j>>8&255,j&255,K>>24,K>>16&255,K>>8&255,K&255])),W.trun(k,P.length+16+20+8+16+8+8),P)},W.trak=function(k){return k.duration=k.duration||4294967295,W.box(W.types.trak,W.tkhd(k),W.mdia(k))},W.trex=function(k){var S=k.id;return W.box(W.types.trex,new Uint8Array([0,0,0,0,S>>24,S>>16&255,S>>8&255,S&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))},W.trun=function(k,S){var P=k.samples||[],O=P.length,j=12+16*O,K=new Uint8Array(j),ve,ce,Ie,Ae,Ne,ke;for(S+=8+j,K.set([0,0,15,1,O>>>24&255,O>>>16&255,O>>>8&255,O&255,S>>>24&255,S>>>16&255,S>>>8&255,S&255],0),ve=0;ve>>24&255,Ie>>>16&255,Ie>>>8&255,Ie&255,Ae>>>24&255,Ae>>>16&255,Ae>>>8&255,Ae&255,Ne.isLeading<<2|Ne.dependsOn,Ne.isDependedOn<<6|Ne.hasRedundancy<<4|Ne.paddingValue<<1|Ne.isNonSync,Ne.degradPrio&61440,Ne.degradPrio&15,ke>>>24&255,ke>>>16&255,ke>>>8&255,ke&255],12+16*ve);return W.box(W.types.trun,K)},W.initSegment=function(k){W.types||W.init();var S=W.moov(k),P;return P=new Uint8Array(W.FTYP.byteLength+S.byteLength),P.set(W.FTYP),P.set(S,W.FTYP.byteLength),P},W})(),Tr=Ha,Xe=9e4;function Wa(W,X,k,S){return k===void 0&&(k=1),S===void 0&&(S=!1),Mt(W,X,1/k)}function Mt(W,X,k,S){k===void 0&&(k=1),S===void 0&&(S=!1);var P=W*X*k;return S?Math.round(P):P}function zn(W,X){return X===void 0&&(X=!1),Mt(W,1e3,1/Xe,X)}function On(W,X){return X===void 0&&(X=1),Mt(W,Xe,1/X)}var Ze=On(10),Ma=On(.2),Ja=(function(){function W(k,S,P,O){this.observer=k,this.config=S,this.typeSupported=P;var j=navigator.userAgent;this.isSafari=O&&O.indexOf("Apple")>-1&&j&&!j.match("CriOS"),this.ISGenerated=!1}var X=W.prototype;return X.destroy=function(){},X.resetTimeStamp=function(S){this._initPTS=this._initDTS=S},X.resetInitSegment=function(){this.ISGenerated=!1},X.remux=function(S,P,O,j,K,ve,ce){if(this.ISGenerated||this.generateIS(S,P,K),this.ISGenerated){var Ie=S.samples.length,Ae=P.samples.length,Ne=K,ke=K;if(Ie&&Ae){var Rn=(S.samples[0].pts-P.samples[0].pts)/P.inputTimeScale;Ne+=Math.max(0,Rn),ke+=Math.max(0,-Rn)}if(Ie){S.timescale||(l.logger.warn("regenerate InitSegment as audio detected"),this.generateIS(S,P,K));var Ln=this.remuxAudio(S,Ne,ve,ce);if(Ae){var ze;Ln&&(ze=Ln.endPTS-Ln.startPTS),P.timescale||(l.logger.warn("regenerate InitSegment as video detected"),this.generateIS(S,P,K)),this.remuxVideo(P,ke,ve,ze,ce)}}else if(Ae){var $n=this.remuxVideo(P,ke,ve,0,ce);$n&&S.codec&&this.remuxEmptyAudio(S,Ne,ve,$n)}}O.samples.length&&this.remuxID3(O,K),j.samples.length&&this.remuxText(j,K),this.observer.trigger(t.default.FRAG_PARSED)},X.generateIS=function(S,P,O){var j=this.observer,K=S.samples,ve=P.samples,ce=this.typeSupported,Ie="audio/mp4",Ae={},Ne={tracks:Ae},ke=this._initPTS===void 0,Rn,Ln;if(ke&&(Rn=Ln=1/0),S.config&&K.length&&(S.timescale=S.samplerate,l.logger.log("audio sampling rate : "+S.samplerate),S.isAAC||(ce.mpeg?(Ie="audio/mpeg",S.codec=""):ce.mp3&&(S.codec="mp3")),Ae.audio={container:Ie,codec:S.codec,initSegment:!S.isAAC&&ce.mpeg?new Uint8Array:Tr.initSegment([S]),metadata:{channelCount:S.channelCount}},ke&&(Rn=Ln=K[0].pts-S.inputTimeScale*O)),P.sps&&P.pps&&ve.length){var ze=P.inputTimeScale;P.timescale=ze,Ae.video={container:"video/mp4",codec:P.codec,initSegment:Tr.initSegment([P]),metadata:{width:P.width,height:P.height}},ke&&(Rn=Math.min(Rn,ve[0].pts-ze*O),Ln=Math.min(Ln,ve[0].dts-ze*O),this.observer.trigger(t.default.INIT_PTS_FOUND,{initPTS:Rn}))}Object.keys(Ae).length?(j.trigger(t.default.FRAG_PARSING_INIT_SEGMENT,Ne),this.ISGenerated=!0,ke&&(this._initPTS=Rn,this._initDTS=Ln)):j.trigger(t.default.ERROR,{type:r.ErrorTypes.MEDIA_ERROR,details:r.ErrorDetails.FRAG_PARSING_ERROR,fatal:!1,reason:"no audio/video samples found"})},X.remuxVideo=function(S,P,O,j,K){var ve=8,ce,Ie,Ae,Ne,ke,Rn,Ln,ze=S.timescale,$n=S.samples,Ra=[],$a=$n.length,qt=this._PTSNormalize,Pr=this._initPTS,Xa=this.nextAvcDts,rr=this.isSafari;if($a!==0){rr&&(O|=$n.length&&Xa&&(K&&Math.abs(P-Xa/ze)<.1||Math.abs($n[0].pts-Xa-Pr)1?l.logger.log("AVC: "+zn(hr,!0)+" ms hole between fragments detected,filling it"):hr<-1&&l.logger.log("AVC: "+zn(-hr,!0)+" ms overlapping between fragments detected"),ke=Xa,$n[0].dts=ke,Ne=Math.max(Ne-hr,Xa),$n[0].pts=Ne,l.logger.log("Video: PTS/DTS adjusted: "+zn(Ne,!0)+"/"+zn(ke,!0)+", delta: "+zn(hr,!0)+" ms")),At=$n[$n.length-1],Ln=Math.max(At.dts,0),Rn=Math.max(At.pts,0,Ln),rr&&(ce=Math.round((Ln-ke)/($n.length-1)));for(var po=0,Jo=0,Pu=0;Pu<$a;Pu++){for(var Co=$n[Pu],di=Co.units,qo=di.length,oo=0,au=0;au0?Yu-1:Yu].dts;if(nf.stretchShortVideoTrack){var Tc=nf.maxBufferHole,Rg=Math.floor(Tc*ze),$0=(j?Ne+j*ze:this.nextAudioPts)-tu.pts;$0>Rg?(ce=$0-hs,ce<0&&(ce=hs),l.logger.log("It is approximately "+zn($0,!1)+" ms to the next segment; using duration "+zn(ce,!1)+" ms for the last video frame.")):ce=hs}else ce=hs}Ic=Math.round(tu.pts-tu.dts)}Ra.push({size:Wl,duration:ce,cts:Ic,flags:{isLeading:0,isDependedOn:0,hasRedundancy:0,degradPrio:0,dependsOn:tu.key?2:1,isNonSync:tu.key?0:1}})}this.nextAvcDts=Ln+ce;var xm=S.dropped;if(S.nbNalu=0,S.dropped=0,Ra.length&&navigator.userAgent.toLowerCase().indexOf("chrome")>-1){var jm=Ra[0].flags;jm.dependsOn=2,jm.isNonSync=0}S.samples=Ra,Ae=Tr.moof(S.sequenceNumber++,ke,S),S.samples=[];var Sc={data1:Ae,data2:Ie,startPTS:Ne/ze,endPTS:(Rn+ce)/ze,startDTS:ke/ze,endDTS:this.nextAvcDts/ze,type:"video",hasAudio:!1,hasVideo:!0,nb:Ra.length,dropped:xm};return this.observer.trigger(t.default.FRAG_PARSING_DATA,Sc),Sc}},X.remuxAudio=function(S,P,O,j){var K=S.inputTimeScale,ve=S.timescale,ce=K/ve,Ie=S.isAAC?1024:1152,Ae=Ie*ce,Ne=this._PTSNormalize,ke=this._initPTS,Rn=!S.isAAC&&this.typeSupported.mpeg,Ln,ze,$n,Ra,$a,qt,Pr=Rn?0:8,Xa=S.samples,rr=[],Rt=this.nextAudioPts;if(O|=Xa.length&&Rt&&(j&&Math.abs(P-Rt/K)<.1||Math.abs(Xa[0].pts-Rt-ke)<20*Ae),Xa.forEach(function(Tc){Tc.pts=Tc.dts=Ne(Tc.pts-ke,P*K)}),Xa=Xa.filter(function(Tc){return Tc.pts>=0}),Xa.length!==0){if(O||(j?Rt=P*K:Rt=Xa[0].pts),S.isAAC)for(var Jr=this.config.maxAudioFramesDrift,At=0,hr=Rt;At=Jr*Ae&&Jo.1*Ae,po.pts=po.dts=hr,hr+=Ae,At++}for(var oo=Xa.length,au=0;oo--;)au+=Xa[oo].unit.byteLength;for(var Ni=0,Oi=Xa.length;Ni0&&Wl0&&(ze=Dt.getSilentFrame(S.manifestCodec||S.codec,S.channelCount),ze||(ze=tu.subarray()),au+=Ic*ze.length);else if(Wl<-12){l.logger.log("drop overlapping AAC sample, expected/parsed/delta: "+zn(Rt,!0)+" ms / "+zn(vl,!0)+" ms / "+zn(-Wl,!0)+" ms"),au-=tu.byteLength;continue}vl=Rt}if($a=vl,au>0){au+=Pr;try{$n=new Uint8Array(au)}catch{this.observer.trigger(t.default.ERROR,{type:r.ErrorTypes.MUX_ERROR,details:r.ErrorDetails.REMUX_ALLOC_ERROR,fatal:!1,bytes:au,reason:"fail allocating audio mdat "+au});return}if(!Rn){var Ks=new DataView($n.buffer);Ks.setUint32(0,au),$n.set(Tr.types.mdat,4)}}else return;for(var ef=0;ef=2&&(ms=rr[oo-2].duration,Ln.duration=ms),oo){this.nextAudioPts=Rt=qt+ce*ms,S.samples=rr,Rn?Ra=new Uint8Array:Ra=Tr.moof(S.sequenceNumber++,$a/ce,S),S.samples=[];var ds=$a/K,nf=Rt/K,hs={data1:Ra,data2:$n,startPTS:ds,endPTS:nf,startDTS:ds,endDTS:nf,type:"audio",hasAudio:!0,hasVideo:!1,nb:oo};return this.observer.trigger(t.default.FRAG_PARSING_DATA,hs),hs}return null}},X.remuxEmptyAudio=function(S,P,O,j){var K=S.inputTimeScale,ve=S.samplerate?S.samplerate:K,ce=K/ve,Ie=this.nextAudioPts,Ae=(Ie!==void 0?Ie:j.startDTS*K)+this._initDTS,Ne=j.endDTS*K+this._initDTS,ke=1024,Rn=ce*ke,Ln=Math.ceil((Ne-Ae)/Rn),ze=Dt.getSilentFrame(S.manifestCodec||S.codec,S.channelCount);if(l.logger.warn("remux empty Audio"),!ze){l.logger.trace("Unable to remuxEmptyAudio since we were unable to get a silent frame for given audio codec!");return}for(var $n=[],Ra=0;Ra4294967296;)S+=O;return S},W})(),pt=Ja,tr=(function(){function W(k){this.observer=k}var X=W.prototype;return X.destroy=function(){},X.resetTimeStamp=function(){},X.resetInitSegment=function(){},X.remux=function(S,P,O,j,K,ve,ce,Ie){var Ae=this.observer,Ne="";S&&(Ne+="audio"),P&&(Ne+="video"),Ae.trigger(t.default.FRAG_PARSING_DATA,{data1:Ie,startPTS:K,startDTS:K,type:Ne,hasAudio:!!S,hasVideo:!!P,nb:1,dropped:0}),Ae.trigger(t.default.FRAG_PARSED)},W})(),In=tr,Oa=Object(s.getSelfScope)(),dr;try{dr=Oa.performance.now.bind(Oa.performance)}catch{l.logger.debug("Unable to use Performance API on this environment"),dr=Oa.Date.now}var za=(function(){function W(k,S,P,O){this.observer=k,this.typeSupported=S,this.config=P,this.vendor=O}var X=W.prototype;return X.destroy=function(){var S=this.demuxer;S&&S.destroy()},X.push=function(S,P,O,j,K,ve,ce,Ie,Ae,Ne,ke,Rn){var Ln=this;if(S.byteLength>0&&P!=null&&P.key!=null&&P.method==="AES-128"){var ze=this.decrypter;ze==null&&(ze=this.decrypter=new u.default(this.observer,this.config));var $n=dr();ze.decrypt(S,P.key.buffer,P.iv.buffer,function(Ra){var $a=dr();Ln.observer.trigger(t.default.FRAG_DECRYPTED,{stats:{tstart:$n,tdecrypt:$a}}),Ln.pushDecrypted(new Uint8Array(Ra),P,new Uint8Array(O),j,K,ve,ce,Ie,Ae,Ne,ke,Rn)})}else this.pushDecrypted(new Uint8Array(S),P,new Uint8Array(O),j,K,ve,ce,Ie,Ae,Ne,ke,Rn)},X.pushDecrypted=function(S,P,O,j,K,ve,ce,Ie,Ae,Ne,ke,Rn){var Ln=this.demuxer;if(!Ln||(ce||Ie)&&!this.probe(S)){for(var ze=this.observer,$n=this.typeSupported,Ra=this.config,$a=[{demux:kn,remux:pt},{demux:Z.default,remux:In},{demux:ne,remux:pt},{demux:Da,remux:pt}],qt=0,Pr=$a.length;qt1?L-1:0),V=1;V1?L-1:0),V=1;V0)return p.subarray(E,E+w)},s._readSize=function(p,R){var E=0;return E=(p[R]&127)<<21,E|=(p[R+1]&127)<<14,E|=(p[R+2]&127)<<7,E|=p[R+3]&127,E},s.getTimeStamp=function(p){for(var R=s.getID3Frames(p),E=0;E>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:te+=String.fromCharCode(U);break;case 12:case 13:V=p[le++],te+=String.fromCharCode((U&31)<<6|V&63);break;case 14:V=p[le++],Q=p[le++],te+=String.fromCharCode((U&15)<<12|(V&63)<<6|(Q&63)<<0);break;default:}}return te},s})(),u;function i(){var s=Object(t.getSelfScope)();return!u&&typeof s.TextDecoder<"u"&&(u=new s.TextDecoder("utf-8")),u}var l=r._utf8ArrayToStr;n.default=r}),"./src/demux/mp4demuxer.js":(function(e,n,a){"use strict";a.r(n);var t=a("./src/utils/logger.js"),r=a("./src/events.js"),u=Math.pow(2,32)-1,i=(function(){function l(h,p){this.observer=h,this.remuxer=p}var s=l.prototype;return s.resetTimeStamp=function(p){this.initPTS=p},s.resetInitSegment=function(p,R,E,w){if(p&&p.byteLength){var I=this.initData=l.parseInitSegment(p);R==null&&(R="mp4a.40.5"),E==null&&(E="avc1.42e01e");var L={};I.audio&&I.video?L.audiovideo={container:"video/mp4",codec:R+","+E,initSegment:w?p:null}:(I.audio&&(L.audio={container:"audio/mp4",codec:R,initSegment:w?p:null}),I.video&&(L.video={container:"video/mp4",codec:E,initSegment:w?p:null})),this.observer.trigger(r.default.FRAG_PARSING_INIT_SEGMENT,{tracks:L})}else R&&(this.audioCodec=R),E&&(this.videoCodec=E)},l.probe=function(p){return l.findBox({data:p,start:0,end:Math.min(p.length,16384)},["moof"]).length>0},l.bin2str=function(p){return String.fromCharCode.apply(null,p)},l.readUint16=function(p,R){p.data&&(R+=p.start,p=p.data);var E=p[R]<<8|p[R+1];return E<0?65536+E:E},l.readUint32=function(p,R){p.data&&(R+=p.start,p=p.data);var E=p[R]<<24|p[R+1]<<16|p[R+2]<<8|p[R+3];return E<0?4294967296+E:E},l.writeUint32=function(p,R,E){p.data&&(R+=p.start,p=p.data),p[R]=E>>24,p[R+1]=E>>16&255,p[R+2]=E>>8&255,p[R+3]=E&255},l.findBox=function(p,R){var E=[],w,I,L,U,V,Q,te;if(p.data?(Q=p.start,U=p.end,p=p.data):(Q=0,U=p.byteLength),!R.length)return null;for(w=Q;w1?w+I:U,L===R[0]&&(R.length===1?E.push({data:p,start:w+8,end:te}):(V=l.findBox({data:p,start:w+8,end:te},R.slice(1)),V.length&&(E=E.concat(V)))),w=te;return E},l.parseSegmentIndex=function(p){var R=l.findBox(p,["moov"])[0],E=R?R.end:null,w=0,I=l.findBox(p,["sidx"]),L;if(!I||!I[0])return null;L=[],I=I[0];var U=I.data[0];w=U===0?8:16;var V=l.readUint32(I,w);w+=4;var Q=0,te=0;U===0?w+=8:w+=16,w+=2;var le=I.end+te,ne=l.readUint16(I,w);w+=2;for(var Z=0;Z>>31;if(Qe===1){console.warn("SIDX has hierarchical references (not supported)");return}var dn=l.readUint32(I,ee);ee+=4,L.push({referenceSize:$e,subsegmentDuration:dn,info:{duration:dn/V,start:le,end:le+$e-1}}),le+=$e,ee+=4,w=ee}return{earliestPresentationTime:Q,timescale:V,version:U,referencesCount:ne,references:L,moovEndOffset:E}},l.parseInitSegment=function(p){var R=[],E=l.findBox(p,["moov","trak"]);return E.forEach(function(w){var I=l.findBox(w,["tkhd"])[0];if(I){var L=I.data[I.start],U=L===0?12:20,V=l.readUint32(I,U),Q=l.findBox(w,["mdia","mdhd"])[0];if(Q){L=Q.data[Q.start],U=L===0?12:20;var te=l.readUint32(Q,U),le=l.findBox(w,["mdia","hdlr"])[0];if(le){var ne=l.bin2str(le.data.subarray(le.start+8,le.start+12)),Z={soun:"audio",vide:"video"}[ne];if(Z){var ee=l.findBox(w,["mdia","minf","stbl","stsd"]);if(ee.length){ee=ee[0];var me=l.bin2str(ee.data.subarray(ee.start+12,ee.start+16));t.logger.log("MP4Demuxer:"+Z+":"+me+" found")}R[V]={timescale:te,type:Z},R[Z]={timescale:te,id:V}}}}}}),R},l.getStartDTS=function(p,R){var E,w,I;return E=l.findBox(R,["moof","traf"]),w=[].concat.apply([],E.map(function(L){return l.findBox(L,["tfhd"]).map(function(U){var V,Q,te;return V=l.readUint32(U,4),Q=p[V].timescale||9e4,te=l.findBox(L,["tfdt"]).map(function(le){var ne,Z;return ne=le.data[le.start],Z=l.readUint32(le,4),ne===1&&(Z*=Math.pow(2,32),Z+=l.readUint32(le,8)),Z})[0],te/Q})})),I=Math.min.apply(null,w),isFinite(I)?I:0},l.offsetStartDTS=function(p,R,E){l.findBox(R,["moof","traf"]).map(function(w){return l.findBox(w,["tfhd"]).map(function(I){var L=l.readUint32(I,4),U=p[L].timescale||9e4;l.findBox(w,["tfdt"]).map(function(V){var Q=V.data[V.start],te=l.readUint32(V,4);if(Q===0)l.writeUint32(V,4,te-E*U);else{te*=Math.pow(2,32),te+=l.readUint32(V,8),te-=E*U,te=Math.max(te,0);var le=Math.floor(te/(u+1)),ne=Math.floor(te%(u+1));l.writeUint32(V,4,le),l.writeUint32(V,8,ne)}})})})},s.append=function(p,R,E,w){var I=this.initData;I||(this.resetInitSegment(p,this.audioCodec,this.videoCodec,!1),I=this.initData);var L,U=this.initPTS;if(U===void 0){var V=l.getStartDTS(I,p);this.initPTS=U=V-R,this.observer.trigger(r.default.INIT_PTS_FOUND,{initPTS:U})}l.offsetStartDTS(I,p,U),L=l.getStartDTS(I,p),this.remuxer.remux(I.audio,I.video,null,null,L,E,w,p)},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 r});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 r;(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"})(r||(r={}))}),"./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 cF});var r=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"),h={hlsEventGeneric:!0,hlsHandlerDestroying:!0,hlsHandlerDestroyed:!0},p=(function(){function b(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,o=new Array(v>1?v-1:0),c=1;c>8*(15-c)&255;return o},g.setDecryptDataFromLevelKey=function(v,o){var c=v;return v&&v.method&&v.uri&&!v.iv&&(c=new V(v.baseuri,v.reluri),c.method=v.method,c.iv=this.createInitializationVector(o)),c},te(b,[{key:"url",get:function(){return!this._url&&this.relurl&&(this._url=Object(r.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)}}]),b})();function Z(b,g){for(var f=0;fNumber.MAX_SAFE_INTEGER?1/0:o},g.hexadecimalInteger=function(v){if(this[v]){var o=(this[v]||"0x").slice(2);o=(o.length&1?"0":"")+o;for(var c=new Uint8Array(o.length/2),_=0;_Number.MAX_SAFE_INTEGER?1/0:o},g.decimalFloatingPoint=function(v){return parseFloat(this[v])},g.enumeratedString=function(v){return this[v]},g.decimalResolution=function(v){var o=$e.exec(this[v]);if(o!==null)return{width:parseInt(o[1],10),height:parseInt(o[2],10)}},b.parseAttrList=function(v){var o,c={};for(Qe.lastIndex=0;(o=Qe.exec(v))!==null;){var _=o[2],y='"';_.indexOf(y)===0&&_.lastIndexOf(y)===_.length-1&&(_=_.slice(1,-1)),c[o[1]]=_}return c},b})(),qn=dn,Mn={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 An(b,g){var f=Mn[g];return!!f&&f[b.slice(0,4)]===!0}function kn(b,g){return MediaSource.isTypeSupported((g||"video")+'/mp4;codecs="'+b+'"')}var Ia=/#EXT-X-STREAM-INF:([^\n\r]*)[\r\n]+([^\r\n]+)/g,Da=/#EXT-X-MEDIA:(.*)/g,da=new RegExp([/#EXTINF:\s*(\d*(?:\.\d+)?)(?:,(.*)\s+)?/.source,/|(?!#)([\S+ ?]+)/.source,/|#EXT-X-BYTERANGE:*(.+)/.source,/|#EXT-X-PROGRAM-DATE-TIME:(.+)/.source,/|#.*/.source].join(""),"g"),Dt=/(?:(?:#(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?/,_t=/\.(mp4|m4s|m4v|m4a)$/i,Ha=(function(){function b(){}return b.findGroup=function(f,v){for(var o=0;o2?(o=v.shift()+".",o+=parseInt(v.shift()).toString(16),o+=("000"+parseInt(v.shift()).toString(16)).substr(-4)):o=f,o},b.resolve=function(f,v){return r.buildAbsoluteURL(v,f,{alwaysNormalize:!0})},b.parseMasterPlaylist=function(f,v){var o=[];Ia.lastIndex=0;function c(N,q){["video","audio"].forEach(function(J){var re=N.filter(function(en){return An(en,J)});if(re.length){var Ce=re.filter(function(en){return en.lastIndexOf("avc1",0)===0||en.lastIndexOf("mp4a",0)===0});q[J+"Codec"]=Ce.length>0?Ce[0]:re[0],N=N.filter(function(en){return re.indexOf(en)===-1})}}),q.unknownCodecs=N}for(var _;(_=Ia.exec(f))!=null;){var y={},C=y.attrs=new qn(_[1]);y.url=b.resolve(_[2],v);var F=C.decimalResolution("RESOLUTION");F&&(y.width=F.width,y.height=F.height),y.bitrate=C.decimalInteger("AVERAGE-BANDWIDTH")||C.decimalInteger("BANDWIDTH"),y.name=C.NAME,c([].concat((C.CODECS||"").split(/[ ,]+/)),y),y.videoCodec&&y.videoCodec.indexOf("avc1")!==-1&&(y.videoCodec=b.convertAVC1ToAVCOTI(y.videoCodec)),o.push(y)}return o},b.parseMasterPlaylistMedia=function(f,v,o,c){c===void 0&&(c=[]);var _,y=[],C=0;for(Da.lastIndex=0;(_=Da.exec(f))!==null;){var F=new qn(_[1]);if(F.TYPE===o){var N={id:C++,groupId:F["GROUP-ID"],name:F.NAME||F.LANGUAGE,type:o,default:F.DEFAULT==="YES",autoselect:F.AUTOSELECT==="YES",forced:F.FORCED==="YES",lang:F.LANGUAGE};if(F.URI&&(N.url=b.resolve(F.URI,v)),c.length){var q=b.findGroup(c,N.groupId);N.audioCodec=q?q.codec:c[0].codec}y.push(N)}}return y},b.parseLevelPlaylist=function(f,v,o,c,_){var y=0,C=0,F=new me(v),N=0,q=null,J=new ne,re,Ce,en,Sn=null;for(da.lastIndex=0;(re=da.exec(f))!==null;){var qa=re[1];if(qa){J.duration=parseFloat(qa);var Sa=(" "+re[2]).slice(1);J.title=Sa||null,J.tagList.push(Sa?["INF",qa,Sa]:["INF",qa])}else if(re[3]){if(Object(i.isFiniteNumber)(J.duration)){var Ua=y++;J.type=c,J.start=C,en&&(J.levelkey=en),J.sn=Ua,J.level=o,J.cc=N,J.urlId=_,J.baseurl=v,J.relurl=(" "+re[3]).slice(1),Xe(J,q),F.fragments.push(J),q=J,C+=J.duration,J=new ne}}else if(re[4]){var Ka=(" "+re[4]).slice(1);q?J.setByteRange(Ka,q):J.setByteRange(Ka)}else if(re[5])J.rawProgramDateTime=(" "+re[5]).slice(1),J.tagList.push(["PROGRAM-DATE-TIME",J.rawProgramDateTime]),Sn===null&&(Sn=F.fragments.length);else{if(re=re[0].match(Dt),!re){s.logger.warn("No matches on slow regex match for level playlist!");continue}for(Ce=1;Ce=0&&(en.method=Xt,en.key=null,en.iv=yt));break}case"START":{var Zu=new qn(St),Zm=Zu.decimalFloatingPoint("TIME-OFFSET");Object(i.isFiniteNumber)(Zm)&&(F.startTimeOffset=Zm);break}case"MAP":{var ed=new qn(St);J.relurl=ed.URI,ed.BYTERANGE&&J.setByteRange(ed.BYTERANGE),J.baseurl=v,J.level=o,J.type=c,J.sn="initSegment",F.initSegment=J,J=new ne,J.rawProgramDateTime=F.initSegment.rawProgramDateTime;break}default:s.logger.warn("line parsed but not handled: "+re);break}}}return J=q,J&&!J.relurl&&(F.fragments.pop(),C-=J.duration),F.totalduration=C,F.averagetargetduration=C/F.fragments.length,F.endSN=y-1,F.startCC=F.fragments[0]?F.fragments[0].cc:0,F.endCC=N,!F.initSegment&&F.fragments.length&&F.fragments.every(function(AF){return _t.test(AF.relurl)})&&(s.logger.warn("MP4 fragments found but no init segment (probably no MAP, incomplete M3U8), trying to fetch SIDX"),J=new ne,J.relurl=F.fragments[0].relurl,J.baseurl=v,J.level=o,J.type=c,J.sn="initSegment",F.initSegment=J,F.needSidxRanges=!0),Sn&&Tr(F.fragments,Sn),F},b})();function Tr(b,g){for(var f=b[g],v=g-1;v>=0;v--){var o=b[v];o.programDateTime=f.programDateTime-o.duration*1e3,f=o}}function Xe(b,g){b.rawProgramDateTime?b.programDateTime=Date.parse(b.rawProgramDateTime):g&&g.programDateTime&&(b.programDateTime=g.endProgramDateTime),Object(i.isFiniteNumber)(b.programDateTime)||(b.programDateTime=null,b.rawProgramDateTime=null)}function Wa(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var Mt=window,zn=Mt.performance,On=(function(b){Wa(g,b);function g(v){var o;return o=b.call(this,v,l.default.MANIFEST_LOADING,l.default.LEVEL_LOADING,l.default.AUDIO_TRACK_LOADING,l.default.SUBTITLE_TRACK_LOADING)||this,o.loaders={},o}g.canHaveQualityLevels=function(o){return o!==E.AUDIO_TRACK&&o!==E.SUBTITLE_TRACK},g.mapContextToLevelType=function(o){var c=o.type;switch(c){case E.AUDIO_TRACK:return w.AUDIO;case E.SUBTITLE_TRACK:return w.SUBTITLE;default:return w.MAIN}},g.getResponseUrl=function(o,c){var _=o.url;return(_===void 0||_.indexOf("data:")===0)&&(_=c.url),_};var f=g.prototype;return f.createInternalLoader=function(o){var c=this.hls.config,_=c.pLoader,y=c.loader,C=_||y,F=new C(c);return o.loader=F,this.loaders[o.type]=F,F},f.getInternalLoader=function(o){return this.loaders[o.type]},f.resetInternalLoader=function(o){this.loaders[o]&&delete this.loaders[o]},f.destroyInternalLoaders=function(){for(var o in this.loaders){var c=this.loaders[o];c&&c.destroy(),this.resetInternalLoader(o)}},f.destroy=function(){this.destroyInternalLoaders(),b.prototype.destroy.call(this)},f.onManifestLoading=function(o){this.load({url:o.url,type:E.MANIFEST,level:0,id:null,responseType:"text"})},f.onLevelLoading=function(o){this.load({url:o.url,type:E.LEVEL,level:o.level,id:o.id,responseType:"text"})},f.onAudioTrackLoading=function(o){this.load({url:o.url,type:E.AUDIO_TRACK,level:null,id:o.id,responseType:"text"})},f.onSubtitleTrackLoading=function(o){this.load({url:o.url,type:E.SUBTITLE_TRACK,level:null,id:o.id,responseType:"text"})},f.load=function(o){var c=this.hls.config;s.logger.debug("Loading playlist of type "+o.type+", level: "+o.level+", id: "+o.id);var _=this.getInternalLoader(o);if(_){var y=_.context;if(y&&y.url===o.url)return s.logger.trace("playlist request ongoing"),!1;s.logger.warn("aborting previous loader for type: "+o.type),_.abort()}var C,F,N,q;switch(o.type){case E.MANIFEST:C=c.manifestLoadingMaxRetry,F=c.manifestLoadingTimeOut,N=c.manifestLoadingRetryDelay,q=c.manifestLoadingMaxRetryTimeout;break;case E.LEVEL:C=0,q=0,N=0,F=c.levelLoadingTimeOut;break;default:C=c.levelLoadingMaxRetry,F=c.levelLoadingTimeOut,N=c.levelLoadingRetryDelay,q=c.levelLoadingMaxRetryTimeout;break}_=this.createInternalLoader(o);var J={timeout:F,maxRetry:C,retryDelay:N,maxRetryDelay:q},re={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: "+o.url),_.load(o,J,re),!0},f.loadsuccess=function(o,c,_,y){if(y===void 0&&(y=null),_.isSidxRequest){this._handleSidxRequest(o,_),this._handlePlaylistLoaded(o,c,_,y);return}if(this.resetInternalLoader(_.type),typeof o.data!="string")throw new Error('expected responseType of "text" for PlaylistLoader');var C=o.data;if(c.tload=zn.now(),C.indexOf("#EXTM3U")!==0){this._handleManifestParsingError(o,_,"no EXTM3U delimiter",y);return}C.indexOf("#EXTINF:")>0||C.indexOf("#EXT-X-TARGETDURATION:")>0?this._handleTrackOrLevelPlaylist(o,c,_,y):this._handleMasterPlaylist(o,c,_,y)},f.loaderror=function(o,c,_){_===void 0&&(_=null),this._handleNetworkError(c,_,!1,o)},f.loadtimeout=function(o,c,_){_===void 0&&(_=null),this._handleNetworkError(c,_,!0)},f._handleMasterPlaylist=function(o,c,_,y){var C=this.hls,F=o.data,N=g.getResponseUrl(o,_),q=Ha.parseMasterPlaylist(F,N);if(!q.length){this._handleManifestParsingError(o,_,"no level found in manifest",y);return}var J=q.map(function(Sn){return{id:Sn.attrs.AUDIO,codec:Sn.audioCodec}}),re=Ha.parseMasterPlaylistMedia(F,N,"AUDIO",J),Ce=Ha.parseMasterPlaylistMedia(F,N,"SUBTITLES");if(re.length){var en=!1;re.forEach(function(Sn){Sn.url||(en=!0)}),en===!1&&q[0].audioCodec&&!q[0].attrs.AUDIO&&(s.logger.log("audio codec signaled in quality level, but no embedded audio track signaled, create one"),re.unshift({type:"main",name:"main",default:!1,autoselect:!1,forced:!1,id:-1}))}C.trigger(l.default.MANIFEST_LOADED,{levels:q,audioTracks:re,subtitles:Ce,url:N,stats:c,networkDetails:y})},f._handleTrackOrLevelPlaylist=function(o,c,_,y){var C=this.hls,F=_.id,N=_.level,q=_.type,J=g.getResponseUrl(o,_),re=Object(i.isFiniteNumber)(F)?F:0,Ce=Object(i.isFiniteNumber)(N)?N:re,en=g.mapContextToLevelType(_),Sn=Ha.parseLevelPlaylist(o.data,J,Ce,en,re);if(Sn.tload=c.tload,q===E.MANIFEST){var qa={url:J,details:Sn};C.trigger(l.default.MANIFEST_LOADED,{levels:[qa],audioTracks:[],url:J,stats:c,networkDetails:y})}if(c.tparsed=zn.now(),Sn.needSidxRanges){var Sa=Sn.initSegment.url;this.load({url:Sa,isSidxRequest:!0,type:q,level:N,levelDetails:Sn,id:F,rangeStart:0,rangeEnd:2048,responseType:"arraybuffer"});return}_.levelDetails=Sn,this._handlePlaylistLoaded(o,c,_,y)},f._handleSidxRequest=function(o,c){if(typeof o.data=="string")throw new Error("sidx request must be made with responseType of array buffer");var _=I.default.parseSegmentIndex(new Uint8Array(o.data));if(_){var y=_.references,C=c.levelDetails;y.forEach(function(F,N){var q=F.info;if(C){var J=C.fragments[N];J.byteRange.length===0&&J.setByteRange(String(1+q.end-q.start)+"@"+String(q.start))}}),C&&C.initSegment.setByteRange(String(_.moovEndOffset)+"@0")}},f._handleManifestParsingError=function(o,c,_,y){this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.NETWORK_ERROR,details:u.ErrorDetails.MANIFEST_PARSING_ERROR,fatal:!0,url:o.url,reason:_,networkDetails:y})},f._handleNetworkError=function(o,c,_,y){_===void 0&&(_=!1),y===void 0&&(y=null),s.logger.info("A network error occured while loading a "+o.type+"-type playlist");var C,F,N=this.getInternalLoader(o);switch(o.type){case E.MANIFEST:C=_?u.ErrorDetails.MANIFEST_LOAD_TIMEOUT:u.ErrorDetails.MANIFEST_LOAD_ERROR,F=!0;break;case E.LEVEL:C=_?u.ErrorDetails.LEVEL_LOAD_TIMEOUT:u.ErrorDetails.LEVEL_LOAD_ERROR,F=!1;break;case E.AUDIO_TRACK:C=_?u.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:u.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,F=!1;break;default:F=!1}N&&(N.abort(),this.resetInternalLoader(o.type));var q={type:u.ErrorTypes.NETWORK_ERROR,details:C,fatal:F,url:o.url,loader:N,context:o,networkDetails:c};y&&(q.response=y),this.hls.trigger(l.default.ERROR,q)},f._handlePlaylistLoaded=function(o,c,_,y){var C=_.type,F=_.level,N=_.id,q=_.levelDetails;if(!q||!q.targetduration){this._handleManifestParsingError(o,_,"invalid target duration",y);return}var J=g.canHaveQualityLevels(_.type);if(J)this.hls.trigger(l.default.LEVEL_LOADED,{details:q,level:F||0,id:N||0,stats:c,networkDetails:y});else switch(C){case E.AUDIO_TRACK:this.hls.trigger(l.default.AUDIO_TRACK_LOADED,{details:q,id:N,stats:c,networkDetails:y});break;case E.SUBTITLE_TRACK:this.hls.trigger(l.default.SUBTITLE_TRACK_LOADED,{details:q,id:N,stats:c,networkDetails:y});break}},g})(R),Ze=On;function Ma(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var Ja=(function(b){Ma(g,b);function g(v){var o;return o=b.call(this,v,l.default.FRAG_LOADING)||this,o.loaders={},o}var f=g.prototype;return f.destroy=function(){var o=this.loaders;for(var c in o){var _=o[c];_&&_.destroy()}this.loaders={},b.prototype.destroy.call(this)},f.onFragLoading=function(o){var c=o.frag,_=c.type,y=this.loaders,C=this.hls.config,F=C.fLoader,N=C.loader;c.loaded=0;var q=y[_];q&&(s.logger.warn("abort previous fragment loader for type: "+_),q.abort()),q=y[_]=c.loader=C.fLoader?new F(C):new N(C);var J,re,Ce;J={url:c.url,frag:c,responseType:"arraybuffer",progressData:!1};var en=c.byteRangeStartOffset,Sn=c.byteRangeEndOffset;Object(i.isFiniteNumber)(en)&&Object(i.isFiniteNumber)(Sn)&&(J.rangeStart=en,J.rangeEnd=Sn),re={timeout:C.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:C.fragLoadingMaxRetryTimeout},Ce={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this),onProgress:this.loadprogress.bind(this)},q.load(J,re,Ce)},f.loadsuccess=function(o,c,_,y){y===void 0&&(y=null);var C=o.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:y})},f.loaderror=function(o,c,_){_===void 0&&(_=null);var y=c.frag,C=y.loader;C&&C.abort(),this.loaders[y.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:o,networkDetails:_})},f.loadtimeout=function(o,c,_){_===void 0&&(_=null);var y=c.frag,C=y.loader;C&&C.abort(),this.loaders[y.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(o,c,_,y){y===void 0&&(y=null);var C=c.frag;C.loaded=o.loaded,this.hls.trigger(l.default.FRAG_LOAD_PROGRESS,{frag:C,stats:o,networkDetails:y})},g})(R),pt=Ja;function tr(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var In=(function(b){tr(g,b);function g(v){var o;return o=b.call(this,v,l.default.KEY_LOADING)||this,o.loaders={},o.decryptkey=null,o.decrypturl=null,o}var f=g.prototype;return f.destroy=function(){for(var o in this.loaders){var c=this.loaders[o];c&&c.destroy()}this.loaders={},b.prototype.destroy.call(this)},f.onKeyLoading=function(o){var c=o.frag,_=c.type,y=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(y&&(s.logger.warn("abort previous key loader for type:"+_),y.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 N={url:C,frag:c,responseType:"arraybuffer"},q={timeout:F.fragLoadingTimeOut,maxRetry:0,retryDelay:F.fragLoadingRetryDelay,maxRetryDelay:F.fragLoadingMaxRetryTimeout},J={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};c.loader.load(N,q,J)}else this.decryptkey&&(c.decryptdata.key=this.decryptkey,this.hls.trigger(l.default.KEY_LOADED,{frag:c}))},f.loadsuccess=function(o,c,_){var y=_.frag;if(!y.decryptdata){s.logger.error("after key load, decryptdata unset");return}this.decryptkey=y.decryptdata.key=new Uint8Array(o.data),y.loader=void 0,delete this.loaders[y.type],this.hls.trigger(l.default.KEY_LOADED,{frag:y})},f.loaderror=function(o,c){var _=c.frag,y=_.loader;y&&y.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:o})},f.loadtimeout=function(o,c){var _=c.frag,y=_.loader;y&&y.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:_})},g})(R),Oa=In;function dr(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var za={NOT_LOADED:"NOT_LOADED",APPENDING:"APPENDING",PARTIAL:"PARTIAL",OK:"OK"},jt=(function(b){dr(g,b);function g(v){var o;return o=b.call(this,v,l.default.BUFFER_APPENDED,l.default.FRAG_BUFFERED,l.default.FRAG_LOADED)||this,o.bufferPadding=.2,o.fragments=Object.create(null),o.timeRanges=Object.create(null),o.config=v.config,o}var f=g.prototype;return f.destroy=function(){this.fragments=Object.create(null),this.timeRanges=Object.create(null),this.config=null,R.prototype.destroy.call(this),b.prototype.destroy.call(this)},f.getBufferedFrag=function(o,c){var _=this.fragments,y=Object.keys(_).filter(function(F){var N=_[F];if(N.body.type!==c||!N.buffered)return!1;var q=N.body;return q.startPTS<=o&&o<=q.endPTS});if(y.length===0)return null;var C=y.pop();return _[C].body},f.detectEvictedFragments=function(o,c){var _=this,y,C;Object.keys(this.fragments).forEach(function(F){var N=_.fragments[F];if(N.buffered===!0){var q=N.range[o];if(q){y=q.time;for(var J=0;J=C&&c<=F){y.push({startPTS:Math.max(o,_.start(q)),endPTS:Math.min(c,_.end(q))});break}else if(oC)y.push({startPTS:Math.max(o,_.start(q)),endPTS:Math.min(c,_.end(q))}),N=!0;else if(c<=C)break;return{time:y,partial:N}},f.getFragmentKey=function(o){return o.type+"_"+o.level+"_"+o.urlId+"_"+o.sn},f.getPartialFragment=function(o){var c=this,_,y,C,F=null,N=0;return Object.keys(this.fragments).forEach(function(q){var J=c.fragments[q];c.isPartial(J)&&(y=J.body.startPTS-c.bufferPadding,C=J.body.endPTS+c.bufferPadding,o>=y&&o<=C&&(_=Math.min(o-y,C-o),N<=_&&(F=J.body,N=_)))}),F},f.getState=function(o){var c=this.getFragmentKey(o),_=this.fragments[c],y=za.NOT_LOADED;return _!==void 0&&(_.buffered?this.isPartial(_)===!0?y=za.PARTIAL:y=za.OK:y=za.APPENDING),y},f.isPartial=function(o){return o.buffered===!0&&(o.range.video!==void 0&&o.range.video.partial===!0||o.range.audio!==void 0&&o.range.audio.partial===!0)},f.isTimeBuffered=function(o,c,_){for(var y,C,F=0;F<_.length;F++){if(y=_.start(F)-this.bufferPadding,C=_.end(F)+this.bufferPadding,o>=y&&c<=C)return!0;if(c<=y)return!1}return!1},f.onFragLoaded=function(o){var c=o.frag;!Object(i.isFiniteNumber)(c.sn)||c.bitrateTest||(this.fragments[this.getFragmentKey(c)]={body:c,range:Object.create(null),buffered:!1})},f.onBufferAppended=function(o){var c=this;this.timeRanges=o.timeRanges,Object.keys(this.timeRanges).forEach(function(_){var y=c.timeRanges[_];c.detectEvictedFragments(_,y)})},f.onFragBuffered=function(o){this.detectPartialFragments(o.frag)},f.hasFragment=function(o){var c=this.getFragmentKey(o);return this.fragments[c]!==void 0},f.removeFragment=function(o){var c=this.getFragmentKey(o);delete this.fragments[c]},f.removeAllFragments=function(){this.fragments=Object.create(null)},g})(R),W={search:function(g,f){for(var v=0,o=g.length-1,c=null,_=null;v<=o;){c=(v+o)/2|0,_=g[c];var y=f(_);if(y>0)v=c+1;else if(y<0)o=c-1;else return _}return null}},X=W,k=(function(){function b(){}return b.isBuffered=function(f,v){try{if(f){for(var o=f.buffered,c=0;c=o.start(c)&&v<=o.end(c))return!0}}catch{}return!1},b.bufferInfo=function(f,v,o){try{if(f){var c=f.buffered,_=[],y;for(y=0;yC&&(c[y-1].end=f[_].end):c.push(f[_])}else c.push(f[_])}else c=f;for(var F=0,N,q=v,J=v,re=0;re=Ce&&v1?c-1:0),y=1;yg?(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!")):(o.duration=v.start-c,o.duration<0&&s.logger.warn("negative duration computed for frag "+o.sn+",level "+o.level+", there should be some duration drift between playlist and fragment!")):f>g?o.start=v.start+v.duration:o.start=Math.max(v.start-o.duration,0)}function ze(b,g,f,v,o,c){var _=f;if(Object(i.isFiniteNumber)(g.startPTS)){var y=Math.abs(g.startPTS-f);Object(i.isFiniteNumber)(g.deltaPTS)?g.deltaPTS=Math.max(y,g.deltaPTS):g.deltaPTS=y,_=Math.max(f,g.startPTS),f=Math.min(f,g.startPTS),v=Math.max(v,g.endPTS),o=Math.min(o,g.startDTS),c=Math.max(c,g.endDTS)}var C=f-g.start;g.start=g.startPTS=f,g.maxStartPTS=_,g.endPTS=v,g.startDTS=o,g.endDTS=c,g.duration=v-f;var F=g.sn;if(!b||Fb.endSN)return 0;var N,q,J;for(N=F-b.startSN,q=b.fragments,q[N]=g,J=N;J>0;J--)Ln(q,J,J-1);for(J=N;Jv.length))for(var c=0;cg?-1:0})}function At(b,g,f){var v=!1;return g&&g.details&&f&&(f.endCC>f.startCC||b&&b.cc=(o||0))return null;f=f||0;for(var c=0;cb&&f.start?-1:0}function au(b,g,f){var v=Math.min(g,f.duration+(f.deltaPTS?f.deltaPTS:0))*1e3,o=f.endProgramDateTime||0;return o-v>b}var Ni=250,Oi=2,Yu=.1,tu=.05,vl=(function(){function b(f,v,o,c){this.config=f,this.media=v,this.fragmentTracker=o,this.hls=c,this.nudgeRetry=0,this.stallReported=!1,this.stalled=null,this.moved=!1,this.seeking=!1}var g=b.prototype;return g.poll=function(v){var o=this.config,c=this.media,_=this.stalled,y=c.currentTime,C=c.seeking,F=this.seeking&&!C,N=!this.seeking&&C;if(this.seeking=C,y!==v){if(this.moved=!0,_!==null){if(this.stallReported){var q=self.performance.now()-_;s.logger.warn("playback not stuck anymore @"+y+", after "+Math.round(q)+"ms"),this.stallReported=!1}this.stalled=null,this.nudgeRetry=0}return}if((N||F)&&(this.stalled=null),!(c.paused||c.ended||c.playbackRate===0||!c.buffered.length)){var J=k.bufferInfo(c,y,0),re=J.len>0,Ce=J.nextStart||0;if(!(!re&&!Ce)){if(C){var en=J.len>Oi,Sn=!Ce||Ce-y>Oi;if(en||Sn)return;this.moved=!1}if(!this.moved&&this.stalled){var qa=Math.max(Ce,J.start||0)-y;if(qa>0&&qa<=Oi){this._trySkipBufferHole(null);return}}var Sa=self.performance.now();if(_===null){this.stalled=Sa;return}var Ua=Sa-_;!C&&Ua>=Ni&&this._reportStall(J.len);var Ka=k.bufferInfo(c,y,o.maxBufferHole);this._tryFixBufferStall(Ka,Ua)}}},g._tryFixBufferStall=function(v,o){var c=this.config,_=this.fragmentTracker,y=this.media,C=y.currentTime,F=_.getPartialFragment(C);if(F){var N=this._trySkipBufferHole(F);if(N)return}v.len>c.maxBufferHole&&o>c.highBufferWatchdogPeriod*1e3&&(s.logger.warn("Trying to nudge playhead over buffer-hole"),this.stalled=null,this._tryNudgeBuffer())},g._reportStall=function(v){var o=this.hls,c=this.media,_=this.stallReported;_||(this.stallReported=!0,s.logger.warn("Playback stalling at @"+c.currentTime+" due to low buffer"),o.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.BUFFER_STALLED_ERROR,fatal:!1,buffer:v}))},g._trySkipBufferHole=function(v){for(var o=this.config,c=this.hls,_=this.media,y=_.currentTime,C=0,F=0;F<_.buffered.length;F++){var N=_.buffered.start(F);if(y+o.maxBufferHole>=C&&y1?c-1:0),y=1;y1&&(this.clearNextTick(),this._tickTimer=self.setTimeout(this._boundTick,0)),this._tickCallCount=0)},f.doTick=function(){},g})(R);function ef(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var pe={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"},ms=(function(b){ef(g,b);function g(){return b.apply(this,arguments)||this}var f=g.prototype;return f.doTick=function(){},f.startLoad=function(){},f.stopLoad=function(){var o=this.fragCurrent;o&&(o.loader&&o.loader.abort(),this.fragmentTracker.removeFragment(o)),this.demuxer&&(this.demuxer.destroy(),this.demuxer=null),this.fragCurrent=null,this.fragPrevious=null,this.clearInterval(),this.clearNextTick(),this.state=pe.STOPPED},f._streamEnded=function(o,c){var _=this.fragCurrent,y=this.fragmentTracker;if(!c.live&&_&&!_.backtracked&&_.sn===c.endSN&&!o.nextStart){var C=y.getState(_);return C===za.PARTIAL||C===za.OK}return!1},f.onMediaSeeking=function(){var o=this.config,c=this.media,_=this.mediaBuffer,y=this.state,C=c?c.currentTime:null,F=k.bufferInfo(_||c,C,this.config.maxBufferHole);if(Object(i.isFiniteNumber)(C)&&s.logger.log("media seeking to "+C.toFixed(3)),y===pe.FRAG_LOADING){var N=this.fragCurrent;if(F.len===0&&N){var q=o.maxFragLookUpTolerance,J=N.start-q,re=N.start+N.duration+q;Cre?(N.loader&&(s.logger.log("seeking outside of buffer while fragment load in progress, cancel fragment load"),N.loader.abort()),this.fragCurrent=null,this.fragPrevious=null,this.state=pe.IDLE):s.logger.log("seeking outside of buffer but within currently loaded fragment range")}}else y===pe.ENDED&&(F.len===0&&(this.fragPrevious=null,this.fragCurrent=null),this.state=pe.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(),b.prototype.onHandlerDestroying.call(this)},f.onHandlerDestroyed=function(){this.state=pe.STOPPED,this.fragmentTracker=null},f.computeLivePosition=function(o,c){var _=this.config.liveSyncDuration!==void 0?this.config.liveSyncDuration:this.config.liveSyncDurationCount*c.targetduration;return o+Math.max(0,c.totalduration-_)},g})(Ks);function ds(b,g){for(var f=0;f0&&o===-1&&(s.logger.log("override startPosition with lastCurrentTime @"+c.toFixed(3)),o=c),this.state=pe.IDLE,this.nextLoadPosition=this.startPosition=this.lastCurrentTime=o,this.tick()}else this.forceStartLoad=!0,this.state=pe.STOPPED},f.stopLoad=function(){this.forceStartLoad=!1,b.prototype.stopLoad.call(this)},f.doTick=function(){switch(this.state){case pe.BUFFER_FLUSHING:this.fragLoadError=0;break;case pe.IDLE:this._doTickIdle();break;case pe.WAITING_LEVEL:var o=this.levels[this.level];o&&o.details&&(this.state=pe.IDLE);break;case pe.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=pe.IDLE);break;case pe.ERROR:case pe.STOPPED:case pe.FRAG_LOADING:case pe.PARSING:case pe.PARSED:case pe.ENDED:break;default:break}this._checkBuffer(),this._checkFragmentChanged()},f._doTickIdle=function(){var o=this.hls,c=o.config,_=this.media;if(!(this.levelLastLoaded===void 0||!_&&(this.startFragRequested||!c.startFragPrefetch))){var y;this.loadedmetadata?y=_.currentTime:y=this.nextLoadPosition;var C=o.nextLoadLevel,F=this.levels[C];if(F){var N=F.bitrate,q;N?q=Math.max(8*c.maxBufferSize/N,c.maxBufferLength):q=c.maxBufferLength,q=Math.min(q,c.maxMaxBufferLength);var J=k.bufferInfo(this.mediaBuffer?this.mediaBuffer:_,y,c.maxBufferHole),re=J.len;if(!(re>=q)){s.logger.trace("buffer length of "+re.toFixed(3)+" is below max of "+q.toFixed(3)+". checking for more payload ..."),this.level=o.nextLoadLevel=C;var Ce=F.details;if(!Ce||Ce.live&&this.levelLastLoaded!==C){this.state=pe.WAITING_LEVEL;return}if(this._streamEnded(J,Ce)){var en={};this.altAudio&&(en.type="video"),this.hls.trigger(l.default.BUFFER_EOS,en),this.state=pe.ENDED;return}this._fetchPayloadOrEos(y,J,Ce)}}}},f._fetchPayloadOrEos=function(o,c,_){var y=this.fragPrevious,C=this.level,F=_.fragments,N=F.length;if(N!==0){var q=F[0].start,J=F[N-1].start+F[N-1].duration,re=c.end,Ce;if(_.initSegment&&!_.initSegment.data)Ce=_.initSegment;else if(_.live){var en=this.config.initialLiveManifestSize;if(Nen&&en>J.currentTime&&(s.logger.log("buffer end: "+c.toFixed(3)+" is located too far from the end of live sliding playlist, reset currentTime to : "+en.toFixed(3)),J.currentTime=en),this.nextLoadPosition=en}if(o.PTSKnown&&c>y&&J&&J.readyState)return null;if(this.startFragRequested&&!o.PTSKnown){if(C)if(o.hasProgramDateTime)s.logger.log("live playlist, switching playlist, load frag with same PDT: "+C.programDateTime),re=di(F,C.endProgramDateTime,q.maxFragLookUpTolerance);else{var Sn=C.sn+1;if(Sn>=o.startSN&&Sn<=o.endSN){var qa=F[Sn-o.startSN];C.cc===qa.cc&&(re=qa,s.logger.log("live playlist, switching playlist, load frag with next SN: "+re.sn))}re||(re=X.search(F,function(Sa){return C.cc-Sa.cc}),re&&s.logger.log("live playlist, switching playlist, load frag with same CC: "+re.sn))}re||(re=F[Math.min(N-1,Math.round(N/2))],s.logger.log("live playlist, switching playlist, unknown, load middle frag : "+re.sn))}return re},f._findFragment=function(o,c,_,y,C,F,N){var q=this.hls.config,J;if(CF-q.maxFragLookUpTolerance?0:q.maxFragLookUpTolerance;J=qo(c,y,C,re)}else J=y[_-1];if(J){var Ce=J.sn-N.startSN,en=c&&J.level===c.level,Sn=y[Ce-1],qa=y[Ce+1];if(c&&J.sn===c.sn)if(en&&!J.backtracked)if(J.snq.maxBufferHole&&c.dropped&&Ce?(J=Sn,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")):(J=qa,s.logger.log("Re-loading fragment with SN: "+J.sn))}else J=null;else J.backtracked&&(qa&&qa.backtracked?(s.logger.warn("Already backtracked from fragment "+qa.sn+", will not backtrack to fragment "+J.sn+". Loading fragment "+qa.sn),J=qa):(s.logger.warn("Loaded fragment with dropped frames, backtracking 1 segment to find a keyframe"),J.dropped=0,Sn?(J=Sn,J.backtracked=!0):Ce&&(J=null)))}return J},f._loadKey=function(o){this.state=pe.KEY_LOADING,this.hls.trigger(l.default.KEY_LOADING,{frag:o})},f._loadFragment=function(o){var c=this.fragmentTracker.getState(o);this.fragCurrent=o,o.sn!=="initSegment"&&(this.startFragRequested=!0),Object(i.isFiniteNumber)(o.sn)&&!o.bitrateTest&&(this.nextLoadPosition=o.start+o.duration),o.backtracked||c===za.NOT_LOADED||c===za.PARTIAL?(o.autoLevel=this.hls.autoLevelEnabled,o.bitrateTest=this.bitrateTest,this.hls.trigger(l.default.FRAG_LOADING,{frag:o}),this.demuxer||(this.demuxer=new ke(this.hls,"main")),this.state=pe.FRAG_LOADING):c===za.APPENDING&&this._reduceMaxBufferLength(o.duration)&&this.fragmentTracker.removeFragment(o)},f.getBufferedFrag=function(o){return this.fragmentTracker.getBufferedFrag(o,w.MAIN)},f.followingBufferedFrag=function(o){return o?this.getBufferedFrag(o.endPTS+.5):null},f._checkFragmentChanged=function(){var o,c,_=this.media;if(_&&_.readyState&&_.seeking===!1&&(c=_.currentTime,c>this.lastCurrentTime&&(this.lastCurrentTime=c),k.isBuffered(_,c)?o=this.getBufferedFrag(c):k.isBuffered(_,c+.1)&&(o=this.getBufferedFrag(c+.1)),o)){var y=o;if(y!==this.fragPlaying){this.hls.trigger(l.default.FRAG_CHANGED,{frag:y});var C=y.level;(!this.fragPlaying||this.fragPlaying.level!==C)&&this.hls.trigger(l.default.LEVEL_SWITCHED,{level:C}),this.fragPlaying=y}}},f.immediateLevelSwitch=function(){if(s.logger.log("immediateLevelSwitch"),!this.immediateSwitch){this.immediateSwitch=!0;var o=this.media,c;o?(c=o.paused,o.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 o=this.media;o&&o.buffered.length&&(this.immediateSwitch=!1,k.isBuffered(o,o.currentTime)&&(o.currentTime-=1e-4),this.previouslyPaused||o.play())},f.nextLevelSwitch=function(){var o=this.media;if(o&&o.readyState){var c,_,y;if(_=this.getBufferedFrag(o.currentTime),_&&_.startPTS>1&&this.flushMainBuffer(0,_.startPTS-1),o.paused)c=0;else{var C=this.hls.nextLoadLevel,F=this.levels[C],N=this.fragLastKbps;N&&this.fragCurrent?c=this.fragCurrent.duration*F.bitrate/(1e3*N)+1:c=0}if(y=this.getBufferedFrag(o.currentTime+c),y&&(y=this.followingBufferedFrag(y),y)){var q=this.fragCurrent;q&&q.loader&&q.loader.abort(),this.fragCurrent=null,this.flushMainBuffer(y.maxStartPTS,Number.POSITIVE_INFINITY)}}},f.flushMainBuffer=function(o,c){this.state=pe.BUFFER_FLUSHING;var _={startOffset:o,endOffset:c};this.altAudio&&(_.type="video"),this.hls.trigger(l.default.BUFFER_FLUSHING,_)},f.onMediaAttached=function(o){var c=this.media=this.mediaBuffer=o.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 vl(_,c,this.fragmentTracker,this.hls)},f.onMediaDetaching=function(){var o=this.media;o&&o.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(y){y.backtracked=void 0})}),o&&(o.removeEventListener("seeking",this.onvseeking),o.removeEventListener("seeked",this.onvseeked),o.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 o=this.media,c=o?o.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(o){var c=!1,_=!1,y;o.levels.forEach(function(F){y=F.audioCodec,y&&(y.indexOf("mp4a.40.2")!==-1&&(c=!0),y.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=o.altAudio,this.levels=o.levels,this.startFragRequested=!1;var C=this.config;(C.autoStartLoad||this.forceStartLoad)&&this.hls.startLoad(C.startPosition)},f.onLevelLoaded=function(o){var c=o.details,_=o.level,y=this.levels[this.levelLastLoaded],C=this.levels[_],F=c.totalduration,N=0;if(s.logger.log("level "+_+" loaded ["+c.startSN+","+c.endSN+"],duration:"+F),c.live){var q=C.details;q&&c.fragments.length>0?($n(q,c),N=c.fragments[0].start,this.liveSyncPosition=this.computeLivePosition(N,q),c.PTSKnown&&Object(i.isFiniteNumber)(N)?s.logger.log("live playlist sliding:"+N.toFixed(3)):(s.logger.log("live playlist - outdated PTS, unknown sliding"),Jo(this.fragPrevious,y,c))):(s.logger.log("live playlist - first load, unknown sliding"),c.PTSKnown=!1,Jo(this.fragPrevious,y,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 J=c.startTimeOffset;Object(i.isFiniteNumber)(J)?(J<0&&(s.logger.log("negative start time offset "+J+", count from end of last fragment"),J=N+F+J),s.logger.log("start time offset found in playlist, adjust startPosition to "+J),this.startPosition=J):c.live?(this.startPosition=this.computeLivePosition(N,c),s.logger.log("configure startPosition to "+this.startPosition)):this.startPosition=0,this.lastCurrentTime=this.startPosition}this.nextLoadPosition=this.startPosition}this.state===pe.WAITING_LEVEL&&(this.state=pe.IDLE),this.tick()},f.onKeyLoaded=function(){this.state===pe.KEY_LOADING&&(this.state=pe.IDLE,this.tick())},f.onFragLoaded=function(o){var c=this.fragCurrent,_=this.hls,y=this.levels,C=this.media,F=o.frag;if(this.state===pe.FRAG_LOADING&&c&&F.type==="main"&&F.level===c.level&&F.sn===c.sn){var N=o.stats,q=y[c.level],J=q.details;if(this.bitrateTest=!1,this.stats=N,s.logger.log("Loaded "+c.sn+" of ["+J.startSN+" ,"+J.endSN+"],level "+c.level),F.bitrateTest&&_.nextLoadLevel)this.state=pe.IDLE,this.startFragRequested=!1,N.tparsed=N.tbuffered=window.performance.now(),_.trigger(l.default.FRAG_BUFFERED,{stats:N,frag:c,id:"main"}),this.tick();else if(F.sn==="initSegment")this.state=pe.IDLE,N.tparsed=N.tbuffered=window.performance.now(),J.initSegment.data=o.payload,_.trigger(l.default.FRAG_BUFFERED,{stats:N,frag:c,id:"main"}),this.tick();else{s.logger.log("Parsing "+c.sn+" of ["+J.startSN+" ,"+J.endSN+"],level "+c.level+", cc "+c.cc),this.state=pe.PARSING,this.pendingBuffering=!0,this.appended=!1,F.bitrateTest&&(F.bitrateTest=!1,this.fragmentTracker.onFragLoaded({frag:F}));var re=!(C&&C.seeking)&&(J.PTSKnown||!J.live),Ce=J.initSegment?J.initSegment.data:[],en=this._getAudioCodec(q),Sn=this.demuxer=this.demuxer||new ke(this.hls,"main");Sn.push(o.payload,Ce,en,q.videoCodec,c,J.totalduration,re)}}this.fragLoadError=0},f.onFragParsingInitSegment=function(o){var c=this.fragCurrent,_=o.frag;if(c&&o.id==="main"&&_.sn===c.sn&&_.level===c.level&&this.state===pe.PARSING){var y=o.tracks,C,F;if(y.audio&&this.altAudio&&delete y.audio,F=y.audio,F){var N=this.levels[this.level].audioCodec,q=navigator.userAgent.toLowerCase();N&&this.audioCodecSwap&&(s.logger.log("swapping playlist audio codec"),N.indexOf("mp4a.40.5")!==-1?N="mp4a.40.2":N="mp4a.40.5"),this.audioCodecSwitch&&F.metadata.channelCount!==1&&q.indexOf("firefox")===-1&&(N="mp4a.40.5"),q.indexOf("android")!==-1&&F.container!=="audio/mpeg"&&(N="mp4a.40.2",s.logger.log("Android: force audio codec to "+N)),F.levelCodec=N,F.id=o.id}F=y.video,F&&(F.levelCodec=this.levels[this.level].videoCodec,F.id=o.id),this.hls.trigger(l.default.BUFFER_CODECS,y);for(C in y){F=y[C],s.logger.log("main track:"+C+",container:"+F.container+",codecs[level/parsed]=["+F.levelCodec+"/"+F.codec+"]");var J=F.initSegment;J&&(this.appended=!0,this.pendingBuffering=!0,this.hls.trigger(l.default.BUFFER_APPENDING,{type:C,data:J,parent:"main",content:"initSegment"}))}this.tick()}},f.onFragParsingData=function(o){var c=this,_=this.fragCurrent,y=o.frag;if(_&&o.id==="main"&&y.sn===_.sn&&y.level===_.level&&!(o.type==="audio"&&this.altAudio)&&this.state===pe.PARSING){var C=this.levels[this.level],F=_;if(Object(i.isFiniteNumber)(o.endPTS)||(o.endPTS=o.startPTS+_.duration,o.endDTS=o.startDTS+_.duration),o.hasAudio===!0&&F.addElementaryStream(le.AUDIO),o.hasVideo===!0&&F.addElementaryStream(le.VIDEO),s.logger.log("Parsed "+o.type+",PTS:["+o.startPTS.toFixed(3)+","+o.endPTS.toFixed(3)+"],DTS:["+o.startDTS.toFixed(3)+"/"+o.endDTS.toFixed(3)+"],nb:"+o.nb+",dropped:"+(o.dropped||0)),o.type==="video")if(F.dropped=o.dropped,F.dropped)if(F.backtracked)s.logger.warn("Already backtracked on this fragment, appending with the gap",F.sn);else{var N=C.details;if(N&&F.sn===N.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=o.startPTS,this.state=pe.IDLE,this.fragPrevious=F,this.tick();return}}else F.backtracked=!1;var q=ze(C.details,F,o.startPTS,o.endPTS,o.startDTS,o.endDTS),J=this.hls;J.trigger(l.default.LEVEL_PTS_UPDATED,{details:C.details,level:this.level,drift:q,type:o.type,start:o.startPTS,end:o.endPTS}),[o.data1,o.data2].forEach(function(re){re&&re.length&&c.state===pe.PARSING&&(c.appended=!0,c.pendingBuffering=!0,J.trigger(l.default.BUFFER_APPENDING,{type:o.type,data:re,parent:"main",content:"data"}))}),this.tick()}},f.onFragParsed=function(o){var c=this.fragCurrent,_=o.frag;c&&o.id==="main"&&_.sn===c.sn&&_.level===c.level&&this.state===pe.PARSING&&(this.stats.tparsed=window.performance.now(),this.state=pe.PARSED,this._checkAppendedParsed())},f.onAudioTrackSwitching=function(o){var c=!!o.url,_=o.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 y=this.fragCurrent;y.loader&&(s.logger.log("switching to main audio track, cancel main fragment load"),y.loader.abort()),this.fragCurrent=null,this.fragPrevious=null,this.demuxer&&(this.demuxer.destroy(),this.demuxer=null),this.state=pe.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(o){var c=o.id,_=!!this.hls.audioTracks[c].url;if(_){var y=this.videoBuffer;y&&this.mediaBuffer!==y&&(s.logger.log("switching on alternate audio, use video.buffered to schedule main fragment loading"),this.mediaBuffer=y)}this.altAudio=_,this.tick()},f.onBufferCreated=function(o){var c=o.tracks,_,y,C=!1;for(var F in c){var N=c[F];N.id==="main"?(y=F,_=N,F==="video"&&(this.videoBuffer=c[F].buffer)):C=!0}C&&_?(s.logger.log("alternate track found, use "+y+".buffered to schedule main fragment loading"),this.mediaBuffer=_.buffer):this.mediaBuffer=this.media},f.onBufferAppended=function(o){if(o.parent==="main"){var c=this.state;(c===pe.PARSING||c===pe.PARSED)&&(this.pendingBuffering=o.pending>0,this._checkAppendedParsed())}},f._checkAppendedParsed=function(){if(this.state===pe.PARSED&&(!this.appended||!this.pendingBuffering)){var o=this.fragCurrent;if(o){var c=this.mediaBuffer?this.mediaBuffer:this.media;s.logger.log("main buffered : "+rr.toString(c.buffered)),this.fragPrevious=o;var _=this.stats;_.tbuffered=window.performance.now(),this.fragLastKbps=Math.round(8*_.total/(_.tbuffered-_.tfirst)),this.hls.trigger(l.default.FRAG_BUFFERED,{stats:_,frag:o,id:"main"}),this.state=pe.IDLE}this.tick()}},f.onError=function(o){var c=o.frag||this.fragCurrent;if(!(c&&c.type!=="main")){var _=!!this.media&&k.isBuffered(this.media,this.media.currentTime)&&k.isBuffered(this.media,this.media.currentTime+.5);switch(o.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(!o.fatal)if(this.fragLoadError+1<=this.config.fragLoadingMaxRetry){var y=Math.min(Math.pow(2,this.fragLoadError)*this.config.fragLoadingRetryDelay,this.config.fragLoadingMaxRetryTimeout);s.logger.warn("mediaController: frag loading failed, retry in "+y+" ms"),this.retryDate=window.performance.now()+y,this.loadedmetadata||(this.startFragRequested=!1,this.nextLoadPosition=this.startPosition),this.fragLoadError++,this.state=pe.FRAG_LOADING_WAITING_RETRY}else s.logger.error("mediaController: "+o.details+" reaches max retry, redispatch as fatal ..."),o.fatal=!0,this.state=pe.ERROR;break;case u.ErrorDetails.LEVEL_LOAD_ERROR:case u.ErrorDetails.LEVEL_LOAD_TIMEOUT:this.state!==pe.ERROR&&(o.fatal?(this.state=pe.ERROR,s.logger.warn("streamController: "+o.details+",switch to "+this.state+" state ...")):!o.levelRetry&&this.state===pe.WAITING_LEVEL&&(this.state=pe.IDLE));break;case u.ErrorDetails.BUFFER_FULL_ERROR:o.parent==="main"&&(this.state===pe.PARSING||this.state===pe.PARSED)&&(_?(this._reduceMaxBufferLength(this.config.maxBufferLength),this.state=pe.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(o){var c=this.config;return c.maxMaxBufferLength>=o?(c.maxMaxBufferLength/=2,s.logger.warn("main:reduce max buffer length to "+c.maxMaxBufferLength+"s"),!0):!1},f._checkBuffer=function(){var o=this.media;if(!(!o||o.readyState===0)){var c=this.mediaBuffer?this.mediaBuffer:o,_=c.buffered;!this.loadedmetadata&&_.length?(this.loadedmetadata=!0,this._seekToStartPos()):this.immediateSwitch?this.immediateLevelSwitchEnd():this.gapController.poll(this.lastCurrentTime,_)}},f.onFragLoadEmergencyAborted=function(){this.state=pe.IDLE,this.loadedmetadata||(this.startFragRequested=!1,this.nextLoadPosition=this.startPosition),this.tick()},f.onBufferFlushed=function(){var o=this.mediaBuffer?this.mediaBuffer:this.media;o&&this.fragmentTracker.detectEvictedFragments(le.VIDEO,o.buffered),this.state=pe.IDLE,this.fragPrevious=null},f.swapAudioCodec=function(){this.audioCodecSwap=!this.audioCodecSwap},f._seekToStartPos=function(){var o=this.media,c=o.currentTime,_=o.seeking?c:this.startPosition;c!==_&&_>=0&&(s.logger.log("target start position not buffered, seek to buffered.start(0) "+_+" from current time "+c+" "),o.currentTime=_)},f._getAudioCodec=function(o){var c=this.config.defaultAudioCodec||o.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},nf(g,[{key:"state",set:function(o){if(this.state!==o){var c=this.state;this._state=o,s.logger.log("main stream-controller: "+c+"->"+o),this.hls.trigger(l.default.STREAM_STATE_TRANSITION,{previousState:c,nextState:o})}},get:function(){return this._state}},{key:"currentLevel",get:function(){var o=this.media;if(o){var c=this.getBufferedFrag(o.currentTime);if(c)return c.level}return-1}},{key:"nextBufferedFrag",get:function(){var o=this.media;return o?this.followingBufferedFrag(this.getBufferedFrag(o.currentTime)):null}},{key:"nextLevel",get:function(){var o=this.nextBufferedFrag;return o?o.level:-1}},{key:"liveSyncPosition",get:function(){return this._liveSyncPosition},set:function(o){this._liveSyncPosition=o}}]),g})(ms),$0=Rg;function xm(b,g){for(var f=0;f0){y=c[0].bitrate,c.sort(function(re,Ce){return re.bitrate-Ce.bitrate}),this._levels=c;for(var J=0;J=0&&o1&&q.loadError0){var c=this.currentLevelIndex,_=o.urlId,y=o.url[_];s.logger.log("Attempt loading level index "+c+" with URL-id "+_),this.hls.trigger(l.default.LEVEL_LOADING,{url:y,level:c,id:_})}}},jm(g,[{key:"levels",get:function(){return this._levels}},{key:"level",get:function(){return this.currentLevelIndex},set:function(o){var c=this._levels;c&&(o=Math.min(o,c.length-1),(this.currentLevelIndex!==o||!c[o].details)&&this.setLevelInternal(o))}},{key:"manualLevel",get:function(){return this.manualLevelIndex},set:function(o){this.manualLevelIndex=o,this._startLevel===void 0&&(this._startLevel=o),o!==-1&&(this.level=o)}},{key:"firstLevel",get:function(){return this._firstLevel},set:function(o){this._firstLevel=o}},{key:"startLevel",get:function(){if(this._startLevel===void 0){var o=this.hls.config.startLevel;return o!==void 0?o:this._firstLevel}else return this._startLevel},set:function(o){this._startLevel=o}},{key:"nextLoadLevel",get:function(){return this.manualLevelIndex!==-1?this.manualLevelIndex:this.hls.nextAutoLevel},set:function(o){this.level=o,this.manualLevelIndex===-1&&(this.hls.nextAutoLevel=o)}}]),g})(R),Vm=a("./src/demux/id3.js");function Rw(b,g){var f;try{f=new Event("addtrack")}catch{f=document.createEvent("Event"),f.initEvent("addtrack",!1,!1)}f.track=b,g.dispatchEvent(f)}function s_(b){if(b&&b.cues)for(;b.cues.length>0;)b.removeCue(b.cues[0])}function AC(b,g){if(gb[b.length-1].endTime)return b[b.length-1];for(var f=0,v=b.length-1;f<=v;){var o=Math.floor((v+f)/2);if(gb[o].endTime)f=o+1;else return b[o]}return b[f].endTime-gq&&(s.logger.warn("detected an id3 sample with endTime < startTime, adjusting endTime to (startTime + 0.25)"),q=N+.25);for(var J=0;J=this.minWeight_},g.getEstimate=function(){return this.canEstimate()?Math.min(this.fast_.getEstimate(),this.slow_.getEstimate()):this.defaultEstimate_},g.destroy=function(){},b})(),UC=OC;function bw(b,g){for(var f=0;f500*_.duration/q){var J=o.levels,re=Math.max(1,F.bw?F.bw/8:F.loaded*1e3/N),Ce=J[_.level],en=Ce.realBitrate?Math.max(Ce.realBitrate,Ce.bitrate):Ce.bitrate,Sn=F.total?F.total:Math.max(F.loaded,Math.round(_.duration*en/8)),qa=c.currentTime,Sa=(Sn-F.loaded)/re,Ua=(k.bufferInfo(c,qa,o.config.maxBufferHole).end-qa)/q;if(Ua<2*_.duration/q&&Sa>Ua){var Ka,St;for(St=_.level-1;St>C;St--){var _l=J[St].realBitrate?Math.max(J[St].realBitrate,J[St].bitrate):J[St].bitrate,hi=_.duration*_l/(8*.8*re);if(hi=y;re--){var Ce=J[re];if(Ce){var en=Ce.details,Sn=en?en.totalduration/en.fragments.length:c,qa=en?en.live:!1,Sa=void 0;re<=o?Sa=N*_:Sa=q*_;var Ua=J[re].realBitrate?Math.max(J[re].realBitrate,J[re].bitrate):J[re].bitrate,Ka=Ua*Sn/Sa;if(s.logger.trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: "+re+"/"+Math.round(Sa)+"/"+Ua+"/"+Sn+"/"+F+"/"+Ka),Sa>Ua&&(!Ka||qa&&!this.bitrateTestDelay||Ka=0)return Sn;s.logger.trace("rebuffering expected to happen, lets try to find a quality level minimizing the rebuffering");var qa=q?Math.min(q,y.maxStarvationDelay):y.maxStarvationDelay,Sa=y.abrBandWidthFactor,Ua=y.abrBandWidthUpFactor;if(en===0){var Ka=this.bitrateTestDelay;if(Ka){var St=q?Math.min(q,y.maxLoadingDelay):y.maxLoadingDelay;qa=St-Ka,s.logger.trace("bitrate test took "+Math.round(1e3*Ka)+"ms, set first fragment max fetchDuration to "+Math.round(1e3*qa)+" ms"),Sa=Ua=1}}return Sn=this._findBestLevel(N,q,Ce,C,c,en+qa,Sa,Ua,_),Math.max(Sn,0)}}]),g})(R),qC=JC;function $C(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var Iw=j(),WC=(function(b){$C(g,b);function g(v){var o;return o=b.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,o._msDuration=null,o._levelDuration=null,o._levelTargetDuration=10,o._live=null,o._objectUrl=null,o._needsFlush=!1,o._needsEos=!1,o.config=void 0,o.audioTimestampOffset=void 0,o.bufferCodecEventsExpected=0,o._bufferCodecEventsTotal=0,o.media=null,o.mediaSource=null,o.segments=[],o.parent=void 0,o.appending=!1,o.appended=0,o.appendError=0,o.flushBufferCounter=0,o.tracks={},o.pendingTracks={},o.sourceBuffer={},o.flushRange=[],o._onMediaSourceOpen=function(){s.logger.log("media source opened"),o.hls.trigger(l.default.MEDIA_ATTACHED,{media:o.media});var c=o.mediaSource;c&&c.removeEventListener("sourceopen",o._onMediaSourceOpen),o.checkPendingTracks()},o._onMediaSourceClose=function(){s.logger.log("media source closed")},o._onMediaSourceEnded=function(){s.logger.log("media source ended")},o._onSBUpdateEnd=function(){if(o.audioTimestampOffset&&o.sourceBuffer.audio){var c=o.sourceBuffer.audio;s.logger.warn("change mpeg audio timestamp offset from "+c.timestampOffset+" to "+o.audioTimestampOffset),c.timestampOffset=o.audioTimestampOffset,delete o.audioTimestampOffset}o._needsFlush&&o.doFlush(),o._needsEos&&o.checkEos(),o.appending=!1;var _=o.parent,y=o.segments.reduce(function(J,re){return re.parent===_?J+1:J},0),C={},F=o.sourceBuffer;for(var N in F){var q=F[N];if(!q)throw Error("handling source buffer update end error: source buffer for "+N+" uninitilized and unable to update buffered TimeRanges.");C[N]=q.buffered}o.hls.trigger(l.default.BUFFER_APPENDED,{parent:_,pending:y,timeRanges:C}),o._needsFlush||o.doAppending(),o.updateMediaElementDuration(),y===0&&o.flushLiveBackBuffer()},o._onSBUpdateError=function(c){s.logger.error("sourceBuffer error:",c),o.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.BUFFER_APPENDING_ERROR,fatal:!1})},o.config=v.config,o}var f=g.prototype;return f.destroy=function(){R.prototype.destroy.call(this)},f.onLevelPtsUpdated=function(o){var c=o.type,_=this.tracks.audio;if(c==="audio"&&_&&_.container==="audio/mpeg"){var y=this.sourceBuffer.audio;if(!y)throw Error("Level PTS Updated and source buffer for audio uninitalized");var C=Math.abs(y.timestampOffset-o.start);if(C>.1){var F=y.updating;try{y.abort()}catch(N){s.logger.warn("can not abort audio buffer: "+N)}F?this.audioTimestampOffset=o.start:(s.logger.warn("change mpeg audio timestamp offset from "+y.timestampOffset+" to "+o.start),y.timestampOffset=o.start)}}},f.onManifestParsed=function(o){this.bufferCodecEventsExpected=this._bufferCodecEventsTotal=o.altAudio?2:1,s.logger.log(this.bufferCodecEventsExpected+" bufferCodec event(s) expected")},f.onMediaAttaching=function(o){var c=this.media=o.media;if(c&&Iw){var _=this.mediaSource=new Iw;_.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 o=this.mediaSource;if(o){if(o.readyState==="open")try{o.endOfStream()}catch(c){s.logger.warn("onMediaDetaching:"+c.message+" while calling endOfStream")}o.removeEventListener("sourceopen",this._onMediaSourceOpen),o.removeEventListener("sourceended",this._onMediaSourceEnded),o.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 o=this.bufferCodecEventsExpected,c=this.pendingTracks,_=Object.keys(c).length;(_&&!o||_===2)&&(this.createSourceBuffers(c),this.pendingTracks={},this.doAppending())},f.onBufferReset=function(){var o=this.sourceBuffer;for(var c in o){var _=o[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(o){var c=this;Object.keys(this.sourceBuffer).length||(Object.keys(o).forEach(function(_){c.pendingTracks[_]=o[_]}),this.bufferCodecEventsExpected=Math.max(this.bufferCodecEventsExpected-1,0),this.mediaSource&&this.mediaSource.readyState==="open"&&this.checkPendingTracks())},f.createSourceBuffers=function(o){var c=this.sourceBuffer,_=this.mediaSource;if(!_)throw Error("createSourceBuffers called when mediaSource was null");for(var y in o)if(!c[y]){var C=o[y];if(!C)throw Error("source buffer exists for track "+y+", however track does not");var F=C.levelCodec||C.codec,N=C.container+";codecs="+F;s.logger.log("creating sourceBuffer("+N+")");try{var q=c[y]=_.addSourceBuffer(N);q.addEventListener("updateend",this._onSBUpdateEnd),q.addEventListener("error",this._onSBUpdateError),this.tracks[y]={buffer:q,codec:F,id:C.id,container:C.container,levelCodec:C.levelCodec}}catch(J){s.logger.error("error while trying to add sourceBuffer:"+J.message),this.hls.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:u.ErrorDetails.BUFFER_ADD_CODEC_ERROR,fatal:!1,err:J,mimeType:N})}}this.hls.trigger(l.default.BUFFER_CREATED,{tracks:this.tracks})},f.onBufferAppending=function(o){this._needsFlush||(this.segments?this.segments.push(o):this.segments=[o],this.doAppending())},f.onBufferEos=function(o){for(var c in this.sourceBuffer)if(!o.type||o.type===c){var _=this.sourceBuffer[c];_&&!_.ended&&(_.ended=!0,s.logger.log(c+" sourceBuffer now EOS"))}this.checkEos()},f.checkEos=function(){var o=this.sourceBuffer,c=this.mediaSource;if(!c||c.readyState!=="open"){this._needsEos=!1;return}for(var _ in o){var y=o[_];if(y){if(!y.ended)return;if(y.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(o){o.type?this.flushRange.push({start:o.startOffset,end:o.endOffset,type:o.type}):(this.flushRange.push({start:o.startOffset,end:o.endOffset,type:"video"}),this.flushRange.push({start:o.startOffset,end:o.endOffset,type:"audio"})),this.flushBufferCounter=0,this.doFlush()},f.flushLiveBackBuffer=function(){if(this._live){var o=this.config.liveBackBufferLength;if(!(!isFinite(o)||o<0)){if(!this.media){s.logger.error("flushLiveBackBuffer called without attaching media");return}for(var c=this.media.currentTime,_=this.sourceBuffer,y=Object.keys(_),C=c-Math.max(o,this._levelTargetDuration),F=y.length-1;F>=0;F--){var N=y[F],q=_[N];if(q){var J=q.buffered;J.length>0&&C>J.start(0)&&this.removeBufferRange(N,q,0,C)&&this.hls.trigger(l.default.LIVE_BACK_BUFFER_REACHED,{bufferEnd:C})}}}}},f.onLevelUpdated=function(o){var c=o.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 o=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 y=this.sourceBuffer[_];if(y&&y.updating===!0)return}c=this.media.duration,this._msDuration===null&&(this._msDuration=this.mediaSource.duration),this._live===!0&&o.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 o=this.flushRange[0];if(this.flushBuffer(o.start,o.end,o.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 y in _){var C=_[y];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 o=this.config,c=this.hls,_=this.segments,y=this.sourceBuffer;if(Object.keys(y).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=y[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(q){s.logger.error("error while trying to append buffer:"+q.message),_.unshift(C);var N={type:u.ErrorTypes.MEDIA_ERROR,parent:C.parent,details:"",fatal:!1};q.code===22?(this.segments=[],N.details=u.ErrorDetails.BUFFER_FULL_ERROR):(this.appendError++,N.details=u.ErrorDetails.BUFFER_APPEND_ERROR,this.appendError>o.appendErrorMaxRetry&&(s.logger.log("fail "+o.appendErrorMaxRetry+" times to append segment in sourceBuffer"),this.segments=[],N.fatal=!0)),c.trigger(l.default.ERROR,N)}}}},f.flushBuffer=function(o,c,_){var y=this.sourceBuffer;if(!Object.keys(y).length)return!0;var C="null";if(this.media&&(C=this.media.currentTime.toFixed(3)),s.logger.log("flushBuffer,pos/start/end: "+C+"/"+o+"/"+c),this.flushBufferCounter>=this.appended)return s.logger.warn("abort flushing too many retries"),!0;var F=y[_];if(F){if(F.ended=!1,F.updating)return s.logger.warn("cannot flush, sb updating in progress"),!1;if(this.removeBufferRange(_,F,o,c))return this.flushBufferCounter++,!1}return s.logger.log("buffer flushed"),!0},f.removeBufferRange=function(o,c,_,y){try{for(var C=0;C.5){var re="null";return this.media&&(re=this.media.currentTime.toString()),s.logger.log("sb remove "+o+" ["+q+","+J+"], of ["+F+","+N+"], pos:"+re),c.remove(q,J),!0}}}catch(Ce){s.logger.warn("removeBufferRange failed",Ce)}return!1},g})(R),xC=WC;function Tw(b,g){for(var f=0;fthis.autoLevelCapping&&c.streamController.nextLevelSwitch(),this.autoLevelCapping=c.autoLevelCapping}}},f.getMaxLevel=function(o){var c=this;if(!this.levels)return-1;var _=this.levels.filter(function(y,C){return g.isLevelAllowed(C,c.restrictedLevels)&&C<=o});return g.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)},g.isLevelAllowed=function(o,c){return c===void 0&&(c=[]),c.indexOf(o)===-1},g.getMaxLevelByMediaSize=function(o,c,_){if(!o||o&&!o.length)return-1;for(var y=function(J,re){return re?J.width!==re.width||J.height!==re.height:!0},C=o.length-1,F=0;F=c||N.height>=_)&&y(N,o[F+1])){C=F;break}}return C},jC(g,[{key:"mediaWidth",get:function(){var o,c=this.media;return c&&(o=c.width||c.clientWidth||c.offsetWidth,o*=g.contentScaleFactor),o}},{key:"mediaHeight",get:function(){var o,c=this.media;return c&&(o=c.height||c.clientHeight||c.offsetHeight,o*=g.contentScaleFactor),o}}],[{key:"contentScaleFactor",get:function(){var o=1;try{o=window.devicePixelRatio}catch{}return o}}]),g})(R),Sw=zC;function VC(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var tf=window,QC=tf.performance,Eg=(function(b){VC(g,b);function g(v){return b.call(this,v,l.default.MEDIA_ATTACHING)||this}var f=g.prototype;return f.destroy=function(){this.timer&&clearInterval(this.timer),this.isVideoPlaybackQualityAvailable=!1},f.onMediaAttaching=function(o){var c=this.hls.config;if(c.capLevelOnFPSDrop){var _=this.video=o.media instanceof window.HTMLVideoElement?o.media:null;typeof _.getVideoPlaybackQuality=="function"&&(this.isVideoPlaybackQualityAvailable=!0),clearInterval(this.timer),this.timer=setInterval(this.checkFPSInterval.bind(this),c.fpsDroppedMonitoringPeriod)}},f.checkFPS=function(o,c,_){var y=QC.now();if(c){if(this.lastTime){var C=y-this.lastTime,F=_-this.lastDroppedFrames,N=c-this.lastDecodedFrames,q=1e3*F/C,J=this.hls;if(J.trigger(l.default.FPS_DROP,{currentDropped:F,currentDecoded:N,totalDroppedFrames:_}),q>0&&F>J.config.fpsDroppedMonitoringThreshold*N){var re=J.currentLevel;s.logger.warn("drop FPS ratio greater than max allowed value for currentLevel: "+re),re>0&&(J.autoLevelCapping===-1||J.autoLevelCapping>=re)&&(re=re-1,J.trigger(l.default.FPS_DROP_LEVEL_CAPPING,{level:re,droppedLevel:J.currentLevel}),J.autoLevelCapping=re,J.streamController.nextLevelSwitch())}}this.lastTime=y,this.lastDroppedFrames=_,this.lastDecodedFrames=c}},f.checkFPSInterval=function(){var o=this.video;if(o)if(this.isVideoPlaybackQualityAvailable){var c=o.getVideoPlaybackQuality();this.checkFPS(o,c.totalVideoFrames,c.droppedVideoFrames)}else this.checkFPS(o,o.webkitDecodedFrameCount,o.webkitDroppedFrameCount)},g})(R),KC=Eg,Cw=window,Ig=Cw.performance,YC=Cw.XMLHttpRequest,XC=(function(){function b(f){f&&f.xhrSetup&&(this.xhrSetup=f.xhrSetup)}var g=b.prototype;return g.destroy=function(){this.abort(),this.loader=null},g.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},g.load=function(v,o,c){this.context=v,this.config=o,this.callbacks=c,this.stats={trequest:Ig.now(),retry:0},this.retryDelay=o.retryDelay,this.loadInternal()},g.loadInternal=function(){var v,o=this.context;v=this.loader=new YC;var c=this.stats;c.tfirst=0,c.loaded=0;var _=this.xhrSetup;try{if(_)try{_(v,o.url)}catch{v.open("GET",o.url,!0),_(v,o.url)}v.readyState||v.open("GET",o.url,!0)}catch(y){this.callbacks.onError({code:v.status,text:y.message},o,v);return}o.rangeEnd&&v.setRequestHeader("Range","bytes="+o.rangeStart+"-"+(o.rangeEnd-1)),v.onreadystatechange=this.readystatechange.bind(this),v.onprogress=this.loadprogress.bind(this),v.responseType=o.responseType,this.requestTimeout=window.setTimeout(this.loadtimeout.bind(this),this.config.timeout),v.send()},g.readystatechange=function(v){var o=v.currentTarget,c=o.readyState,_=this.stats,y=this.context,C=this.config;if(!_.aborted&&c>=2)if(window.clearTimeout(this.requestTimeout),_.tfirst===0&&(_.tfirst=Math.max(Ig.now(),_.trequest)),c===4){var F=o.status;if(F>=200&&F<300){_.tload=Math.max(_.tfirst,Ig.now());var N,q;y.responseType==="arraybuffer"?(N=o.response,q=N.byteLength):(N=o.responseText,q=N.length),_.loaded=_.total=q;var J={url:o.responseURL,data:N};this.callbacks.onSuccess(J,_,y,o)}else _.retry>=C.maxRetry||F>=400&&F<499?(s.logger.error(F+" while loading "+y.url),this.callbacks.onError({code:F,text:o.statusText},y,o)):(s.logger.warn(F+" while loading "+y.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)},g.loadtimeout=function(){s.logger.warn("timeout while loading "+this.context.url),this.callbacks.onTimeout(this.stats,this.context,null)},g.loadprogress=function(v){var o=v.currentTarget,c=this.stats;c.loaded=v.loaded,v.lengthComputable&&(c.total=v.total);var _=this.callbacks.onProgress;_&&_(c,this.context,null,o)},b})(),Tg=XC;function Fw(b,g){for(var f=0;f=this.tracks.length){s.logger.warn("Invalid audio track id:",o.id);return}if(s.logger.log("audioTrack "+o.id+" loaded"),this.tracks[o.id].details=o.details,o.details.live&&!this.hasInterval()){var c=o.details.targetduration*1e3;this.setInterval(c)}!o.details.live&&this.hasInterval()&&this.clearInterval()},f.onAudioTrackSwitched=function(o){var c=this.tracks[o.id].groupId;c&&this.audioGroupId!==c&&(this.audioGroupId=c)},f.onLevelLoaded=function(o){this._selectAudioGroup(o.level)},f.onError=function(o){o.type===u.ErrorTypes.NETWORK_ERROR&&(o.fatal&&this.clearInterval(),o.details===u.ErrorDetails.AUDIO_TRACK_LOAD_ERROR&&(s.logger.warn("Network failure on audio-track id:",o.context.id),this._handleLoadError()))},f._setAudioTrack=function(o){if(this._trackId===o&&this.tracks[this._trackId].details){s.logger.debug("Same id as current audio-track passed, and track details available -> no-op");return}if(o<0||o>=this.tracks.length){s.logger.warn("Invalid id passed to audio-track controller");return}var c=this.tracks[o];s.logger.log("Now switching to audio-track index "+o),this.clearInterval(),this._trackId=o;var _=c.url,y=c.type,C=c.id;this.hls.trigger(l.default.AUDIO_TRACK_SWITCHING,{id:C,type:y,url:_}),this._loadTrackDetailsIfNeeded(c)},f.doTick=function(){this._updateTrack(this._trackId)},f._selectAudioGroup=function(o){var c=this.hls.levels[o];if(!(!c||!c.audioGroupIds)){var _=c.audioGroupIds[c.urlId];this.audioGroupId!==_&&(this.audioGroupId=_,this._selectInitialAudioTrack())}},f._selectInitialAudioTrack=function(){var o=this,c=this.tracks;if(c.length){var _=this.tracks[this._trackId],y=null;if(_&&(y=_.name),this._selectDefaultTrack){var C=c.filter(function(q){return q.default});C.length?c=C:s.logger.warn("No default audio tracks defined")}var F=!1,N=function(){c.forEach(function(J){F||(!o.audioGroupId||J.groupId===o.audioGroupId)&&(!y||y===J.name)&&(o._setAudioTrack(J.id),F=!0)})};N(),F||(y=null,N()),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(o){var c=o.details,_=o.url;return!c||c.live?!!_:!1},f._loadTrackDetailsIfNeeded=function(o){if(this._needsTrackLoading(o)){var c=o.url,_=o.id;s.logger.log("loading audio-track playlist for id: "+_),this.hls.trigger(l.default.AUDIO_TRACK_LOADING,{url:c,id:_})}},f._updateTrack=function(o){if(!(o<0||o>=this.tracks.length)){this.clearInterval(),this._trackId=o,s.logger.log("trying to update audio-track "+o);var c=this.tracks[o];this._loadTrackDetailsIfNeeded(c)}},f._handleLoadError=function(){this.trackIdBlacklist[this._trackId]=!0;var o=this._trackId,c=this.tracks[o],_=c.name,y=c.language,C=c.groupId;s.logger.warn("Loading failed on audio track id: "+o+", group-id: "+C+', name/language: "'+_+'" / "'+y+'"');for(var F=o,N=0;N0&&o===-1?(s.logger.log("audio:override startPosition with lastCurrentTime @"+c.toFixed(3)),this.state=pe.IDLE):(this.lastCurrentTime=this.startPosition?this.startPosition:o,this.state=pe.STARTING),this.nextLoadPosition=this.startPosition=this.lastCurrentTime,this.tick()}else this.startPosition=o,this.state=pe.STOPPED},f.doTick=function(){var o,c,_,y=this.hls,C=y.config;switch(this.state){case pe.ERROR:case pe.PAUSED:case pe.BUFFER_FLUSHING:break;case pe.STARTING:this.state=pe.WAITING_TRACK,this.loadedmetadata=!1;break;case pe.IDLE:var F=this.tracks;if(!F||!this.media&&(this.startFragRequested||!C.startFragPrefetch))break;if(this.loadedmetadata)o=this.media.currentTime;else if(o=this.nextLoadPosition,o===void 0)break;var N=this.mediaBuffer?this.mediaBuffer:this.media,q=this.videoBuffer?this.videoBuffer:this.media,J=k.bufferInfo(N,o,C.maxBufferHole),re=k.bufferInfo(q,o,C.maxBufferHole),Ce=J.len,en=J.end,Sn=this.fragPrevious,qa=Math.min(C.maxBufferLength,C.maxMaxBufferLength),Sa=Math.max(qa,re.len),Ua=this.audioSwitch,Ka=this.trackId;if((Ce"u"){this.state=pe.WAITING_TRACK;break}if(!Ua&&this._streamEnded(J,_)){this.hls.trigger(l.default.BUFFER_EOS,{type:"audio"}),this.state=pe.ENDED;return}var St=_.fragments,_l=St.length,hi=St[0].start,Gc=St[_l-1].start+St[_l-1].duration,Xt;if(Ua){if(_.live&&!_.PTSKnown)s.logger.log("switching audiotrack, live stream, unknown PTS,load first fragment"),en=0;else if(en=o,_.PTSKnown&&ohi||J.nextStart)s.logger.log("alt audio track ahead of main track, seek to start of alt audio track"),this.media.currentTime=hi+.05;else return}if(_.initSegment&&!_.initSegment.data)Xt=_.initSegment;else if(en<=hi){if(Xt=St[0],this.videoTrackCC!==null&&Xt.cc!==this.videoTrackCC&&(Xt=Jr(St,this.videoTrackCC)),_.live&&Xt.loadIdx&&Xt.loadIdx===this.fragLoadIdx){var or=J.nextStart?J.nextStart:hi;s.logger.log("no alt audio available @currentTime:"+this.media.currentTime+", seeking @"+(or+.05)),this.media.currentTime=or+.05;return}}else{var yt,Zu=C.maxFragLookUpTolerance,Zm=Sn?St[Sn.sn-St[0].sn+1]:void 0,ed=function(Pg){var H4=Math.min(Zu,Pg.duration);return Pg.start+Pg.duration-H4<=en?1:Pg.start-H4>en&&Pg.start?-1:0};enGc-Zu&&(Zu=0),Zm&&!ed(Zm)?yt=Zm:yt=X.search(St,ed)):yt=St[_l-1],yt&&(Xt=yt,hi=yt.start,Sn&&Xt.level===Sn.level&&Xt.sn===Sn.sn&&(Xt.sn<_.endSN?(Xt=St[Xt.sn+1-_.startSN],s.logger.log("SN just loaded, load next one: "+Xt.sn)):Xt=null))}Xt&&(Xt.encrypted?(s.logger.log("Loading key for "+Xt.sn+" of ["+_.startSN+" ,"+_.endSN+"],track "+Ka),this.state=pe.KEY_LOADING,y.trigger(l.default.KEY_LOADING,{frag:Xt})):(s.logger.log("Loading "+Xt.sn+", cc: "+Xt.cc+" of ["+_.startSN+" ,"+_.endSN+"],track "+Ka+", currentTime:"+o+",bufferEnd:"+en.toFixed(3)),this.fragCurrent=Xt,(Ua||this.fragmentTracker.getState(Xt)===za.NOT_LOADED)&&(Xt.sn!=="initSegment"&&(this.startFragRequested=!0),Object(i.isFiniteNumber)(Xt.sn)&&(this.nextLoadPosition=Xt.start+Xt.duration),y.trigger(l.default.FRAG_LOADING,{frag:Xt}),this.state=pe.FRAG_LOADING)))}break;case pe.WAITING_TRACK:c=this.tracks[this.trackId],c&&c.details&&(this.state=pe.IDLE);break;case pe.FRAG_LOADING_WAITING_RETRY:var AF=gs.now(),U4=this.retryDate;N=this.media;var Jre=N&&N.seeking;(!U4||AF>=U4||Jre)&&(s.logger.log("audioStreamController: retryDate reached, switch back to IDLE state"),this.state=pe.IDLE);break;case pe.WAITING_INIT_PTS:var LF=this.videoTrackCC;if(this.initPTS[LF]===void 0)break;var k4=this.waitingFragment;if(k4){var B4=k4.frag.cc;LF!==B4?(c=this.tracks[this.trackId],c.details&&c.details.live&&(s.logger.warn("Waiting fragment CC ("+B4+") does not match video track CC ("+LF+")"),this.waitingFragment=null,this.state=pe.IDLE)):(this.state=pe.FRAG_LOADING,this.onFragLoaded(this.waitingFragment),this.waitingFragment=null)}else this.state=pe.IDLE;break;case pe.STOPPED:case pe.FRAG_LOADING:case pe.PARSING:case pe.PARSED:case pe.ENDED:break;default:break}},f.onMediaAttached=function(o){var c=this.media=this.mediaBuffer=o.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 o=this.media;o&&o.ended&&(s.logger.log("MSE detaching and video ended, reset startPosition"),this.startPosition=this.lastCurrentTime=0),o&&(o.removeEventListener("seeking",this.onvseeking),o.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(o){s.logger.log("audio tracks updated"),this.tracks=o.audioTracks},f.onAudioTrackSwitching=function(o){var c=!!o.url;this.trackId=o.id,this.fragCurrent=null,this.state=pe.PAUSED,this.waitingFragment=null,c?this.setInterval(Aw):this.demuxer&&(this.demuxer.destroy(),this.demuxer=null),c&&(this.audioSwitch=!0,this.state=pe.IDLE),this.tick()},f.onAudioTrackLoaded=function(o){var c=o.details,_=o.id,y=this.tracks[_],C=c.totalduration,F=0;if(s.logger.log("track "+_+" loaded ["+c.startSN+","+c.endSN+"],duration:"+C),c.live){var N=y.details;N&&c.fragments.length>0?($n(N,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(y.details=c,!this.startFragRequested){if(this.startPosition===-1){var q=c.startTimeOffset;Object(i.isFiniteNumber)(q)?(s.logger.log("start time offset found in playlist, adjust startPosition to "+q),this.startPosition=q):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===pe.WAITING_TRACK&&(this.state=pe.IDLE),this.tick()},f.onKeyLoaded=function(){this.state===pe.KEY_LOADING&&(this.state=pe.IDLE,this.tick())},f.onFragLoaded=function(o){var c=this.fragCurrent,_=o.frag;if(this.state===pe.FRAG_LOADING&&c&&_.type==="audio"&&_.level===c.level&&_.sn===c.sn){var y=this.tracks[this.trackId],C=y.details,F=C.totalduration,N=c.level,q=c.sn,J=c.cc,re=this.config.defaultAudioCodec||y.audioCodec||"mp4a.40.2",Ce=this.stats=o.stats;if(q==="initSegment")this.state=pe.IDLE,Ce.tparsed=Ce.tbuffered=gs.now(),C.initSegment.data=o.payload,this.hls.trigger(l.default.FRAG_BUFFERED,{stats:Ce,frag:c,id:"audio"}),this.tick();else{this.state=pe.PARSING,this.appended=!1,this.demuxer||(this.demuxer=new ke(this.hls,"audio"));var en=this.initPTS[J],Sn=C.initSegment?C.initSegment.data:[];if(C.initSegment||en!==void 0){this.pendingBuffering=!0,s.logger.log("Demuxing "+q+" of ["+C.startSN+" ,"+C.endSN+"],track "+N);var qa=!1;this.demuxer.push(o.payload,Sn,re,null,c,F,qa,en)}else s.logger.log("unknown video PTS for continuity counter "+J+", waiting for video PTS before demuxing audio frag "+q+" of ["+C.startSN+" ,"+C.endSN+"],track "+N),this.waitingFragment=o,this.state=pe.WAITING_INIT_PTS}}this.fragLoadError=0},f.onFragParsingInitSegment=function(o){var c=this.fragCurrent,_=o.frag;if(c&&o.id==="audio"&&_.sn===c.sn&&_.level===c.level&&this.state===pe.PARSING){var y=o.tracks,C;if(y.video&&delete y.video,C=y.audio,C){C.levelCodec=C.codec,C.id=o.id,this.hls.trigger(l.default.BUFFER_CODECS,y),s.logger.log("audio track:audio,container:"+C.container+",codecs[level/parsed]=["+C.levelCodec+"/"+C.codec+"]");var F=C.initSegment;if(F){var N={type:"audio",data:F,parent:"audio",content:"initSegment"};this.audioSwitch?this.pendingData=[N]:(this.appended=!0,this.pendingBuffering=!0,this.hls.trigger(l.default.BUFFER_APPENDING,N))}this.tick()}}},f.onFragParsingData=function(o){var c=this,_=this.fragCurrent,y=o.frag;if(_&&o.id==="audio"&&o.type==="audio"&&y.sn===_.sn&&y.level===_.level&&this.state===pe.PARSING){var C=this.trackId,F=this.tracks[C],N=this.hls;Object(i.isFiniteNumber)(o.endPTS)||(o.endPTS=o.startPTS+_.duration,o.endDTS=o.startDTS+_.duration),_.addElementaryStream(le.AUDIO),s.logger.log("parsed "+o.type+",PTS:["+o.startPTS.toFixed(3)+","+o.endPTS.toFixed(3)+"],DTS:["+o.startDTS.toFixed(3)+"/"+o.endDTS.toFixed(3)+"],nb:"+o.nb),ze(F.details,_,o.startPTS,o.endPTS);var q=this.audioSwitch,J=this.media,re=!1;if(q)if(J&&J.readyState){var Ce=J.currentTime;s.logger.log("switching audio track : currentTime:"+Ce),Ce>=o.startPTS&&(s.logger.log("switching audio track : flushing all audio"),this.state=pe.BUFFER_FLUSHING,N.trigger(l.default.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"}),re=!0,this.audioSwitch=!1,N.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:C}))}else this.audioSwitch=!1,N.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:C});var en=this.pendingData;if(!en){s.logger.warn("Apparently attempt to enqueue media payload without codec initialization data upfront"),N.trigger(l.default.ERROR,{type:u.ErrorTypes.MEDIA_ERROR,details:null,fatal:!0});return}this.audioSwitch||([o.data1,o.data2].forEach(function(Sn){Sn&&Sn.length&&en.push({type:o.type,data:Sn,parent:"audio",content:"data"})}),!re&&en.length&&(en.forEach(function(Sn){c.state===pe.PARSING&&(c.pendingBuffering=!0,c.hls.trigger(l.default.BUFFER_APPENDING,Sn))}),this.pendingData=[],this.appended=!0)),this.tick()}},f.onFragParsed=function(o){var c=this.fragCurrent,_=o.frag;c&&o.id==="audio"&&_.sn===c.sn&&_.level===c.level&&this.state===pe.PARSING&&(this.stats.tparsed=gs.now(),this.state=pe.PARSED,this._checkAppendedParsed())},f.onBufferReset=function(){this.mediaBuffer=this.videoBuffer=null,this.loadedmetadata=!1},f.onBufferCreated=function(o){var c=o.tracks.audio;c&&(this.mediaBuffer=c.buffer,this.loadedmetadata=!0),o.tracks.video&&(this.videoBuffer=o.tracks.video.buffer)},f.onBufferAppended=function(o){if(o.parent==="audio"){var c=this.state;(c===pe.PARSING||c===pe.PARSED)&&(this.pendingBuffering=o.pending>0,this._checkAppendedParsed())}},f._checkAppendedParsed=function(){if(this.state===pe.PARSED&&(!this.appended||!this.pendingBuffering)){var o=this.fragCurrent,c=this.stats,_=this.hls;if(o){this.fragPrevious=o,c.tbuffered=gs.now(),_.trigger(l.default.FRAG_BUFFERED,{stats:c,frag:o,id:"audio"});var y=this.mediaBuffer?this.mediaBuffer:this.media;y&&s.logger.log("audio buffered : "+rr.toString(y.buffered)),this.audioSwitch&&this.appended&&(this.audioSwitch=!1,_.trigger(l.default.AUDIO_TRACK_SWITCHED,{id:this.trackId})),this.state=pe.IDLE}this.tick()}},f.onError=function(o){var c=o.frag;if(!(c&&c.type!=="audio"))switch(o.details){case u.ErrorDetails.FRAG_LOAD_ERROR:case u.ErrorDetails.FRAG_LOAD_TIMEOUT:var _=o.frag;if(_&&_.type!=="audio")break;if(!o.fatal){var y=this.fragLoadError;y?y++:y=1;var C=this.config;if(y<=C.fragLoadingMaxRetry){this.fragLoadError=y;var F=Math.min(Math.pow(2,y-1)*C.fragLoadingRetryDelay,C.fragLoadingMaxRetryTimeout);s.logger.warn("AudioStreamController: frag loading failed, retry in "+F+" ms"),this.retryDate=gs.now()+F,this.state=pe.FRAG_LOADING_WAITING_RETRY}else s.logger.error("AudioStreamController: "+o.details+" reaches max retry, redispatch as fatal ..."),o.fatal=!0,this.state=pe.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!==pe.ERROR&&(this.state=o.fatal?pe.ERROR:pe.IDLE,s.logger.warn("AudioStreamController: "+o.details+" while loading frag, now switching to "+this.state+" state ..."));break;case u.ErrorDetails.BUFFER_FULL_ERROR:if(o.parent==="audio"&&(this.state===pe.PARSING||this.state===pe.PARSED)){var N=this.mediaBuffer,q=this.media.currentTime,J=N&&k.isBuffered(N,q)&&k.isBuffered(N,q+.5);if(J){var re=this.config;re.maxMaxBufferLength>=re.maxBufferLength&&(re.maxMaxBufferLength/=2,s.logger.warn("AudioStreamController: reduce max buffer length to "+re.maxMaxBufferLength+"s")),this.state=pe.IDLE}else s.logger.warn("AudioStreamController: buffer full error also media.currentTime is not buffered, flush audio buffer"),this.fragCurrent=null,this.state=pe.BUFFER_FLUSHING,this.hls.trigger(l.default.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"})}break;default:break}},f.onBufferFlushed=function(){var o=this,c=this.pendingData;c&&c.length?(s.logger.log("AudioStreamController: appending pending audio data after buffer flushed"),c.forEach(function(_){o.hls.trigger(l.default.BUFFER_APPENDING,_)}),this.appended=!0,this.pendingData=[],this.state=pe.PARSED):(this.state=pe.IDLE,this.fragPrevious=null,this.tick())},W0(g,[{key:"state",set:function(o){if(this.state!==o){var c=this.state;this._state=o,s.logger.log("audio stream:"+c+"->"+o)}},get:function(){return this._state}}]),g})(ms),rF=tF,Lw=(function(){if(typeof window<"u"&&window.VTTCue)return window.VTTCue;var b="auto",g={"":!0,lr:!0,rl:!0},f={start:!0,middle:!0,end:!0,left:!0,right:!0};function v(y){if(typeof y!="string")return!1;var C=g[y.toLowerCase()];return C?y.toLowerCase():!1}function o(y){if(typeof y!="string")return!1;var C=f[y.toLowerCase()];return C?y.toLowerCase():!1}function c(y){for(var C=1;C100)throw new Error("Position must be between 0 and 100.");_l=yt,this.hasBeenReset=!0}})),Object.defineProperty(N,"positionAlign",c({},q,{get:function(){return hi},set:function(yt){var Zu=o(yt);if(!Zu)throw new SyntaxError("An invalid or illegal string was specified.");hi=Zu,this.hasBeenReset=!0}})),Object.defineProperty(N,"size",c({},q,{get:function(){return Gc},set:function(yt){if(yt<0||yt>100)throw new Error("Size must be between 0 and 100.");Gc=yt,this.hasBeenReset=!0}})),Object.defineProperty(N,"align",c({},q,{get:function(){return Xt},set:function(yt){var Zu=o(yt);if(!Zu)throw new SyntaxError("An invalid or illegal string was specified.");Xt=Zu,this.hasBeenReset=!0}})),N.displayState=void 0}return _.prototype.getCueAsHTML=function(){var y=window.WebVTT;return y.convertCueToDOMTree(window,this.text)},_})(),oF=function(){return{decode:function(f){if(!f)return"";if(typeof f!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(f))}}};function Pw(){this.window=window,this.state="INITIAL",this.buffer="",this.decoder=new oF,this.regionList=[]}function uF(b){function g(v,o,c,_){return(v|0)*3600+(o|0)*60+(c|0)+(_|0)/1e3}var f=b.match(/^(\d+):(\d{2})(:\d{2})?\.(\d{3})/);return f?f[3]?g(f[1],f[2],f[3].replace(":",""),f[4]):f[1]>59?g(f[1],f[2],0,f[4]):g(0,f[1],f[2],f[4]):null}function Nw(){this.values=Object.create(null)}Nw.prototype={set:function(g,f){!this.get(g)&&f!==""&&(this.values[g]=f)},get:function(g,f,v){return v?this.has(g)?this.values[g]:f[v]:this.has(g)?this.values[g]:f},has:function(g){return g in this.values},alt:function(g,f,v){for(var o=0;o=0&&f<=100)?(this.set(g,f),!0):!1}};function Ow(b,g,f,v){var o=v?b.split(v):[b];for(var c in o)if(typeof o[c]=="string"){var _=o[c].split(f);if(_.length===2){var y=_[0],C=_[1];g(y,C)}}}var x0=new Lw(0,0,0),Fc=x0.align==="middle"?"middle":"center";function iF(b,g,f){var v=b;function o(){var y=uF(b);if(y===null)throw new Error("Malformed timestamp: "+v);return b=b.replace(/^[^\sa-zA-Z-]+/,""),y}function c(y,C){var F=new Nw;Ow(y,function(J,re){switch(J){case"region":for(var Ce=f.length-1;Ce>=0;Ce--)if(f[Ce].id===re){F.set(J,f[Ce].region);break}break;case"vertical":F.alt(J,re,["rl","lr"]);break;case"line":var en=re.split(","),Sn=en[0];F.integer(J,Sn),F.percent(J,Sn)&&F.set("snapToLines",!1),F.alt(J,Sn,["auto"]),en.length===2&&F.alt("lineAlign",en[1],["start",Fc,"end"]);break;case"position":en=re.split(","),F.percent(J,en[0]),en.length===2&&F.alt("positionAlign",en[1],["start",Fc,"end","line-left","line-right","auto"]);break;case"size":F.percent(J,re);break;case"align":F.alt(J,re,["start",Fc,"end","left","right"]);break}},/:/,/\s/),C.region=F.get("region",null),C.vertical=F.get("vertical","");var N=F.get("line","auto");N==="auto"&&x0.line===-1&&(N=-1),C.line=N,C.lineAlign=F.get("lineAlign","start"),C.snapToLines=F.get("snapToLines",!0),C.size=F.get("size",100),C.align=F.get("align",Fc);var q=F.get("position","auto");q==="auto"&&x0.position===50&&(q=C.align==="start"||C.align==="left"?0:C.align==="end"||C.align==="right"?100:50),C.position=q}function _(){b=b.replace(/^\s+/,"")}if(_(),g.startTime=o(),_(),b.substr(0,3)!=="-->")throw new Error("Malformed time stamp (time stamps must be separated by '-->'): "+v);b=b.substr(3),_(),g.endTime=o(),_(),c(b,g)}function Uw(b){return b.replace(//gi,` `)}Pw.prototype={parse:function(g){var f=this;g&&(f.buffer+=f.decoder.decode(g,{stream:!0}));function v(){var F=f.buffer,N=0;for(F=Uw(F);N")===-1){f.cue.id=c;continue}case"CUE":try{iF(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&&(y=!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 g=this;try{if(g.buffer+=g.decoder.decode(),(g.cue||g.state==="HEADER")&&(g.buffer+=` `,g.parse()),g.state==="INITIAL")throw new Error("Malformed WebVTT signature.")}catch(f){throw f}return g.onflush&&g.onflush(),this}};var lF=Pw;function cF(b,g,f,v){for(var o,c,_,y,C,F=window.VTTCue||TextTrackCue,N=0;N=16?y--:y++,navigator.userAgent.match(/Firefox\//)?c.line=N+1:c.line=N>7?N-2:N+1,c.align="left",c.position=Math.max(0,Math.min(100,100*(y/32))),b.addCue(c)}}var Sg={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},kw=function(g){var f=g;return Sg.hasOwnProperty(g)&&(f=Sg[g]),String.fromCharCode(f)},fl=15,Ds=100,sF={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},vF={17:2,18:4,21:6,22:8,23:10,19:13,20:15},fF={25:1,26:3,29:5,30:7,31:9,24:11,27:12,28:14},_F={25:2,26:4,29:6,30:8,31:10,27:13,28:15},pF=["white","green","blue","cyan","red","yellow","magenta","black","transparent"],Bw;(function(b){b[b.ERROR=0]="ERROR",b[b.TEXT=1]="TEXT",b[b.WARNING=2]="WARNING",b[b.INFO=2]="INFO",b[b.DEBUG=3]="DEBUG",b[b.DATA=3]="DATA"})(Bw||(Bw={}));var Lt={verboseFilter:{DATA:3,DEBUG:3,INFO:2,WARNING:2,TEXT:1,ERROR:0},time:null,verboseLevel:0,setTime:function(g){this.time=g},log:function(g,f){var v=this.verboseFilter[g];this.verboseLevel>=v}},rf=function(g){for(var f=[],v=0;vDs&&(Lt.log("ERROR","Too large cursor position "+this.pos),this.pos=Ds)},g.moveCursor=function(v){var o=this.pos+v;if(v>1)for(var c=this.pos+1;c=144&&this.backSpace();var o=kw(v);if(this.pos>=Ds){Lt.log("ERROR","Cannot insert "+v.toString(16)+" ("+o+") at position "+this.pos+". Skipping it!");return}this.chars[this.pos].setChar(o,this.currPenState),this.moveCursor(1)},g.clearFromPos=function(v){var o;for(o=v;o0&&(v?c="["+o.join(" | ")+"]":c=o.join(` `)),c},g.getTextAndFormat=function(){return this.rows},b})(),Km=(function(){function b(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 Pt,this.nonDisplayedMemory=new Pt,this.lastOutputScreen=new Pt,this.currRollUpRow=this.displayedMemory.rows[fl-1],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null}var g=b.prototype;return g.reset=function(){this.mode=null,this.displayedMemory.reset(),this.nonDisplayedMemory.reset(),this.lastOutputScreen.reset(),this.currRollUpRow=this.displayedMemory.rows[fl-1],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null},g.getHandler=function(){return this.outputFilter},g.setHandler=function(v){this.outputFilter=v},g.setPAC=function(v){this.writeScreen.setPAC(v)},g.setBkgData=function(v){this.writeScreen.setBkgData(v)},g.setMode=function(v){v!==this.mode&&(this.mode=v,Lt.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)},g.insertChars=function(v){for(var o=0;o=46,o.italics)o.foreground="white";else{var c=Math.floor(v/2)-16,_=["white","green","blue","cyan","red","yellow","magenta"];o.foreground=_[c]}Lt.log("INFO","MIDROW: "+JSON.stringify(o)),this.writeScreen.setPen(o)},g.outputDataUpdate=function(v){v===void 0&&(v=!1);var o=Lt.time;o!==null&&this.outputFilter&&(this.cueStartTime===null&&!this.displayedMemory.isEmpty()?this.cueStartTime=o:this.displayedMemory.equals(this.lastOutputScreen)||(this.outputFilter.newCue(this.cueStartTime,o,this.lastOutputScreen),v&&this.outputFilter.dispatchCue&&this.outputFilter.dispatchCue(),this.cueStartTime=this.displayedMemory.isEmpty()?null:o),this.lastOutputScreen.copy(this.displayedMemory))},g.cueSplitAtTime=function(v){this.outputFilter&&(this.displayedMemory.isEmpty()||(this.outputFilter.newCue&&this.outputFilter.newCue(this.cueStartTime,v,this.displayedMemory),this.cueStartTime=v))},b})(),Ym=(function(){function b(f,v,o){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,o],this.channels=[new Km(1,v),new Km(2,o)],this.currChNr=-1,this.lastCmdA=null,this.lastCmdB=null,this.lastTime=null,this.dataCounters={padding:0,char:0,cmd:0,other:0}}var g=b.prototype;return g.getHandler=function(v){return this.channels[v].getHandler()},g.setHandler=function(v,o){this.channels[v].setHandler(o)},g.addData=function(v,o){var c,_,y,C=!1;this.lastTime=v,Lt.setTime(v);for(var F=0;F ("+rf([_,y])+")");if(c=this.parseCmd(_,y),c||(c=this.parseMidrow(_,y)),c||(c=this.parsePAC(_,y)),c||(c=this.parseBackgroundAttributes(_,y)),!c&&(C=this.parseChars(_,y),C))if(this.currChNr&&this.currChNr>=0){var N=this.channels[this.currChNr-1];N.insertChars(C)}else Lt.log("WARNING","No channel found yet. TEXT-MODE?");c?this.dataCounters.cmd+=2:C?this.dataCounters.char+=2:(this.dataCounters.other+=2,Lt.log("WARNING","Couldn't parse cleaned data "+rf([_,y])+" orig: "+rf([o[F],o[F+1]])))}},g.parseCmd=function(v,o){var c=null,_=(v===20||v===28)&&o>=32&&o<=47,y=(v===23||v===31)&&o>=33&&o<=35;if(!(_||y))return!1;if(v===this.lastCmdA&&o===this.lastCmdB)return this.lastCmdA=null,this.lastCmdB=null,Lt.log("DEBUG","Repeated command ("+rf([v,o])+") is dropped"),!0;v===20||v===23?c=1:c=2;var C=this.channels[c-1];return v===20||v===28?o===32?C.ccRCL():o===33?C.ccBS():o===34?C.ccAOF():o===35?C.ccAON():o===36?C.ccDER():o===37?C.ccRU(2):o===38?C.ccRU(3):o===39?C.ccRU(4):o===40?C.ccFON():o===41?C.ccRDC():o===42?C.ccTR():o===43?C.ccRTD():o===44?C.ccEDM():o===45?C.ccCR():o===46?C.ccENM():o===47&&C.ccEOC():C.ccTO(o-32),this.lastCmdA=v,this.lastCmdB=o,this.currChNr=c,!0},g.parseMidrow=function(v,o){var c=null;if((v===17||v===25)&&o>=32&&o<=47){if(v===17?c=1:c=2,c!==this.currChNr)return Lt.log("ERROR","Mismatch channel in midrow parsing"),!1;var _=this.channels[c-1];return _.ccMIDROW(o),Lt.log("DEBUG","MIDROW ("+rf([v,o])+")"),!0}return!1},g.parsePAC=function(v,o){var c=null,_=null,y=(v>=17&&v<=23||v>=25&&v<=31)&&o>=64&&o<=127,C=(v===16||v===24)&&o>=64&&o<=95;if(!(y||C))return!1;if(v===this.lastCmdA&&o===this.lastCmdB)return this.lastCmdA=null,this.lastCmdB=null,!0;c=v<=23?1:2,o>=64&&o<=95?_=c===1?sF[v]:fF[v]:_=c===1?vF[v]:_F[v];var F=this.interpretPAC(_,o),N=this.channels[c-1];return N.setPAC(F),this.lastCmdA=v,this.lastCmdB=o,this.currChNr=c,!0},g.interpretPAC=function(v,o){var c=o,_={color:null,italics:!1,indent:null,underline:!1,row:v};return o>95?c=o-96:c=o-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,_},g.parseChars=function(v,o){var c=null,_=null,y=null;if(v>=25?(c=2,y=v-8):(c=1,y=v),y>=17&&y<=19){var C=o;y===17?C=o+80:y===18?C=o+112:C=o+144,Lt.log("INFO","Special char '"+kw(C)+"' in channel "+c),_=[C]}else v>=32&&v<=127&&(_=o===0?[v]:[v,o]);if(_){var F=rf(_);Lt.log("DEBUG","Char codes = "+F.join(",")),this.lastCmdA=null,this.lastCmdB=null}return _},g.parseBackgroundAttributes=function(v,o){var c,_,y,C,F=(v===16||v===24)&&o>=32&&o<=47,N=(v===23||v===31)&&o>=45&&o<=47;return F||N?(c={},v===16||v===24?(_=Math.floor((o-32)/2),c.background=pF[_],o%2===1&&(c.background=c.background+"_semi")):o===45?c.background="transparent":(c.foreground="black",o===47&&(c.underline=!0)),y=v<24?1:2,C=this.channels[y-1],C.setBkgData(c),this.lastCmdA=null,this.lastCmdB=null,!0):!1},g.reset=function(){for(var v=0;vv)&&(this.startTime=v),this.endTime=o,this.screen=c,this.timelineController.createCaptionsTrack(this.trackName)},b})(),Fg=function(g,f,v){return g.substr(v||0,f.length)===f},gF=function(g){var f=parseInt(g.substr(-3)),v=parseInt(g.substr(-6,2)),o=parseInt(g.substr(-9,2)),c=g.length>9?parseInt(g.substr(0,g.indexOf(":"))):0;if(!Object(i.isFiniteNumber)(f)||!Object(i.isFiniteNumber)(v)||!Object(i.isFiniteNumber)(o)||!Object(i.isFiniteNumber)(c))throw Error("Malformed X-TIMESTAMP-MAP: Local:"+g);return f+=1e3*v,f+=60*1e3*o,f+=3600*1e3*c,f},Xm=function(g){for(var f=5381,v=g.length;v;)f=f*33^g.charCodeAt(--v);return(f>>>0).toString()},DF=function(g,f,v){var o=g[f],c=g[o.prevCC];if(!c||!c.new&&o.new){g.ccOffset=g.presentationOffset=o.start,o.new=!1;return}for(;c&&c.new;)g.ccOffset+=o.start-c.start,o.new=!1,o=c,c=g[o.prevCC];g.presentationOffset=v},RF={parse:function(g,f,v,o,c,_){var y=/\r\n|\n\r|\n|\r/g,C=Object(Vm.utf8ArrayToStr)(new Uint8Array(g)).trim().replace(y,` `).split(` `),F="00:00.000",N=0,q=0,J=0,re=[],Ce,en=!0,Sn=!1,qa=new lF;qa.oncue=function(Sa){var Ua=v[o],Ka=v.ccOffset;Ua&&Ua.new&&(q!==void 0?Ka=v.ccOffset=Ua.start:DF(v,o,J)),J&&(Ka=J-v.presentationOffset),Sn&&(Sa.startTime+=Ka-q,Sa.endTime+=Ka-q),Sa.id=Xm(Sa.startTime.toString())+Xm(Sa.endTime.toString())+Xm(Sa.text),Sa.text=decodeURIComponent(encodeURIComponent(Sa.text)),Sa.endTime>0&&re.push(Sa)},qa.onparsingerror=function(Sa){Ce=Sa},qa.onflush=function(){if(Ce&&_){_(Ce);return}c(re)},C.forEach(function(Sa){if(en)if(Fg(Sa,"X-TIMESTAMP-MAP=")){en=!1,Sn=!0,Sa.substr(16).split(",").forEach(function(Ua){Fg(Ua,"LOCAL:")?F=Ua.substr(6):Fg(Ua,"MPEGTS:")&&(N=parseInt(Ua.substr(7)))});try{f+(v[o].start*9e4||0)<0&&(f+=8589934592),N-=f,q=gF(F)/1e3,J=N/9e4}catch(Ua){Sn=!1,Ce=Ua}return}else Sa===""&&(en=!1);qa.parse(Sa+` `)}),qa.flush()}},yF=RF;function Jw(b){if(b===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b}function wF(b,g){b.prototype=Object.create(g.prototype),b.prototype.constructor=b,b.__proto__=g}var bF=(function(b){wF(g,b);function g(v){var o;if(o=b.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,o.media=null,o.config=void 0,o.enabled=!0,o.Cues=void 0,o.textTracks=[],o.tracks=[],o.initPTS=[],o.unparsedVttFrags=[],o.cueRanges=[],o.captionsTracks={},o.captionsProperties=void 0,o.cea608Parser=void 0,o.lastSn=-1,o.prevCC=-1,o.vttCCs=null,o.hls=v,o.config=v.config,o.Cues=v.config.cueHandler,o.captionsProperties={textTrack1:{label:o.config.captionsTextTrack1Label,languageCode:o.config.captionsTextTrack1LanguageCode},textTrack2:{label:o.config.captionsTextTrack2Label,languageCode:o.config.captionsTextTrack2LanguageCode}},o.config.enableCEA708Captions){var c=new Hw(Jw(o),"textTrack1"),_=new Hw(Jw(o),"textTrack2");o.cea608Parser=new hF(0,c,_)}return o}var f=g.prototype;return f.addCues=function(o,c,_,y){for(var C=this.cueRanges,F=!1,N=C.length;N--;){var q=C[N],J=EF(q[0],q[1],c,_);if(J>=0&&(q[0]=Math.min(q[0],c),q[1]=Math.max(q[1],_),F=!0,J/(_-c)>.5))return}F||C.push([c,_]),this.Cues.newCue(this.captionsTracks[o],c,_,y)},f.onInitPtsFound=function(o){var c=this,_=o.frag,y=o.id,C=o.initPTS,F=this.unparsedVttFrags;y==="main"&&(this.initPTS[_.cc]=C),F.length&&(this.unparsedVttFrags=[],F.forEach(function(N){c.onFragLoaded(N)}))},f.getExistingTrack=function(o){var c=this.media;if(c)for(var _=0;_=F.length||_!==C||!N||this.stopped){this._clearReloadTimer();return}if(s.logger.log("subtitle track "+_+" loaded"),y.live){var q=Pr(N.details,y,o.stats.trequest);s.logger.log("Reloading live subtitle playlist in "+q+"ms"),this.timer=setTimeout(function(){c._loadCurrentTrack()},q)}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 o=this.trackId,c=this.tracks,_=this.hls,y=c[o];o<0||!y||y.details&&!y.details.live||(s.logger.log("Loading subtitle track "+o),_.trigger(l.default.SUBTITLE_TRACK_LOADING,{url:y.url,id:o}))},f._toggleTrackModes=function(o){var c=this.media,_=this.subtitleDisplay,y=this.trackId;if(c){var C=m(c.textTracks);if(o===-1)[].slice.call(C).forEach(function(q){q.mode="disabled"});else{var F=C[y];F&&(F.mode="disabled")}var N=C[o];N&&(N.mode=_?"showing":"hidden")}},f._setSubtitleTrackInternal=function(o){var c=this.hls,_=this.tracks;!Object(i.isFiniteNumber)(o)||o<-1||o>=_.length||(this.trackId=o,s.logger.log("Switching to subtitle track "+o),c.trigger(l.default.SUBTITLE_TRACK_SWITCH,{id:o}),this._loadCurrentTrack())},f._onTextTracksChanged=function(){if(this.media){for(var o=-1,c=m(this.media.textTracks),_=0;_=y[N].start&&F<=y[N].end){C=y[N];break}var q=c.start+c.duration;C?C.end=q:(C={start:F,end:q},y.push(C))}}},f.onMediaAttached=function(o){var c=o.media;this.media=c,c.addEventListener("seeking",this._onMediaSeeking),this.state=pe.IDLE},f.onMediaDetaching=function(){var o=this;this.media&&(this.media.removeEventListener("seeking",this._onMediaSeeking),this.fragmentTracker.removeAllFragments(),this.currentTrackId=-1,this.tracks.forEach(function(c){o.tracksBuffered[c.id]=[]}),this.media=null,this.state=pe.STOPPED)},f.onError=function(o){var c=o.frag;!c||c.type!=="subtitle"||(this.state=pe.IDLE)},f.onSubtitleTracksUpdated=function(o){var c=this;s.logger.log("subtitle tracks updated"),this.tracksBuffered=[],this.tracks=o.subtitleTracks,this.tracks.forEach(function(_){c.tracksBuffered[_.id]=[]})},f.onSubtitleTrackSwitch=function(o){if(this.currentTrackId=o.id,!this.tracks||!this.tracks.length||this.currentTrackId===-1){this.clearInterval();return}var c=this.tracks[this.currentTrackId];c&&c.details&&this.setInterval(xa)},f.onSubtitleTrackLoaded=function(o){var c=o.id,_=o.details,y=this.currentTrackId,C=this.tracks,F=C[y];c>=C.length||c!==y||!F||(_.live&&Ra(F.details,_,this.lastAVStart),F.details=_,this.setInterval(xa))},f.onKeyLoaded=function(){this.state===pe.KEY_LOADING&&(this.state=pe.IDLE)},f.onFragLoaded=function(o){var c=this.fragCurrent,_=o.frag.decryptdata,y=o.frag,C=this.hls;if(this.state===pe.FRAG_LOADING&&c&&o.frag.type==="subtitle"&&c.sn===o.frag.sn&&o.payload.byteLength>0&&_&&_.key&&_.method==="AES-128"){var F=Cn.now();this.decrypter.decrypt(o.payload,_.key.buffer,_.iv.buffer,function(N){var q=Cn.now();C.trigger(l.default.FRAG_DECRYPTED,{frag:y,payload:N,stats:{tstart:F,tdecrypt:q}})})}},f.onLevelUpdated=function(o){var c=o.details,_=c.fragments;this.lastAVStart=_.length?_[0].start:0},f.doTick=function(){if(!this.media){this.state=pe.IDLE;return}switch(this.state){case pe.IDLE:{var o=this.config,c=this.currentTrackId,_=this.fragmentTracker,y=this.media,C=this.tracks;if(!C||!C[c]||!C[c].details)break;var F=o.maxBufferHole,N=o.maxFragLookUpTolerance,q=Math.min(o.maxBufferLength,o.maxMaxBufferLength),J=k.bufferedInfo(this._getBuffered(),y.currentTime,F),re=J.end,Ce=J.len,en=C[c].details,Sn=en.fragments,qa=Sn.length,Sa=Sn[qa-1].start+Sn[qa-1].duration;if(Ce>q)return;var Ua,Ka=this.fragPrevious;reWw){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=Ww-this._requestLicenseFailureCount+1;s.logger.warn("Retrying license request, "+C+" attempts left"),this._requestLicense(_,y)}break}},f._generateLicenseRequestChallenge=function(o,c){if(o.mediaKeySystemDomain===Zr.WIDEVINE)return c;throw new Error("unsupported key-system: "+o.mediaKeySystemDomain)},f._requestLicense=function(o,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 y=this.getLicenseServerUrl(_.mediaKeySystemDomain),C=this._createLicenseXhr(y,o,c);s.logger.log("Sending license request to URL: "+y);var F=this._generateLicenseRequestChallenge(_,o);C.send(F)}catch(N){s.logger.error("Failure requesting DRM license: "+N),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(o){if(this._emeEnabled){var c=o.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(o){if(this._emeEnabled){var c=o.levels.map(function(y){return y.audioCodec}),_=o.levels.map(function(y){return y.videoCodec});this._attemptKeySystemAccess(Zr.WIDEVINE,c,_)}},SF(g,[{key:"requestMediaKeySystemAccess",get:function(){if(!this._requestMediaKeySystemAccess)throw new Error("No requestMediaKeySystemAccess function configured");return this._requestMediaKeySystemAccess}}]),g})(R),FF=jw;function GF(b){for(var g=1;gc)return y}return 0}},{key:"maxAutoLevel",get:function(){var o=this.levels,c=this.autoLevelCapping,_;return c===-1&&o&&o.length?_=o.length-1:_=c,_}},{key:"nextAutoLevel",get:function(){return Math.min(Math.max(this.abrController.nextAutoLevel,this.minAutoLevel),this.maxAutoLevel)},set:function(o){this.abrController.nextAutoLevel=Math.max(this.minAutoLevel,o)}},{key:"audioTracks",get:function(){var o=this.audioTrackController;return o?o.audioTracks:[]}},{key:"audioTrack",get:function(){var o=this.audioTrackController;return o?o.audioTrack:-1},set:function(o){var c=this.audioTrackController;c&&(c.audioTrack=o)}},{key:"liveSyncPosition",get:function(){return this.streamController.liveSyncPosition}},{key:"subtitleTracks",get:function(){var o=this.subtitleTrackController;return o?o.subtitleTracks:[]}},{key:"subtitleTrack",get:function(){var o=this.subtitleTrackController;return o?o.subtitleTrack:-1},set:function(o){var c=this.subtitleTrackController;c&&(c.subtitleTrack=o)}},{key:"subtitleDisplay",get:function(){var o=this.subtitleTrackController;return o?o.subtitleDisplay:!1},set:function(o){var c=this.subtitleTrackController;c&&(c.subtitleDisplay=o)}}]),g})(ce);Xw.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(r){return typeof r=="number"&&isFinite(r)}}),"./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>"u"?self:window}}),"./src/utils/logger.js":(function(e,n,a){"use strict";a.r(n),a.d(n,"enableLogs",function(){return R}),a.d(n,"logger",function(){return E});var t=a("./src/utils/get-self-scope.js");function r(){}var u={trace:r,debug:r,log:r,warn:r,info:r,error:r},i=u;function l(w,I){return I="["+w+"] > "+I,I}var s=Object(t.getSelfScope)();function h(w){var I=s.console[w];return I?function(){for(var L=arguments.length,U=new Array(L),V=0;V1?I-1:0),U=1;U{"use strict";Object.defineProperty(Zy,"__esModule",{value:!0});Zy.Direction=void 0;var wUe;(function(e){e.Right="to right",e.Left="to left",e.Down="to bottom",e.Up="to top"})(wUe=Zy.Direction||(Zy.Direction={}))});var MN=He(ft=>{"use strict";var ew=ft&&ft.__spreadArray||function(e,n,a){if(a||arguments.length===2)for(var t=0,r=n.length,u;te)return s;if(h&&ht)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,")"))}ft.checkBoundaries=CUe;function FUe(e,n,a){return ea?a:e}ft.checkValuesAgainstBoundaries=FUe;function GUe(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}"))}ft.checkInitialOverlap=GUe;function MUe(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)}}ft.getMargin=MUe;function AUe(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)}}ft.getPaddingAndBorder=AUe;function LUe(e,n,a){var t=a?-1:1;e.forEach(function(r,u){return wne(r,t*n[u].x,n[u].y)})}ft.translateThumbs=LUe;function PUe(e,n,a,t){for(var r=0,u=Rne(e[0],n,a,t),i=1;ii?s:i},e.getBoundingClientRect().width));return u},HUe=function(e,n,a,t,r,u,i){i===void 0&&(i=function(h){return h});var l=[],s=function(h){var p=Dne(a[h],t[h],r,u,i),R=n[h].x;n.forEach(function(E,w){var I=E.x,L=Dne(a[w],t[w],r,u,i);h!==w&&(R>=I&&R<=I+L||R+p>=I&&R+p<=I+L)&&(l.includes(w)||(l.push(h),l.push(w),l=ew(ew([],l,!0),[h,w],!1),s(w)))})};return s(e),Array.from(new Set(l.sort()))},JUe=function(e,n,a,t,r,u){t===void 0&&(t=.1),r===void 0&&(r=" - "),u===void 0&&(u=function(w){return w});var i=(0,ft.getStepDecimals)(t),l=(0,GN.useState)({}),s=l[0],h=l[1],p=(0,GN.useState)(u(n[a].toFixed(i))),R=p[0],E=p[1];return(0,GN.useEffect)(function(){if(e){var w=e.getThumbs();if(w.length<1)return;var I={},L=e.getOffsets(),U=HUe(a,L,w,n,r,i,u),V=u(n[a].toFixed(i));if(U.length){var Q=U.reduce(function(ee,me,$e,Qe){return ee.length?ew(ew([],ee,!0),[L[Qe[$e]].x],!1):[L[Qe[$e]].x]},[]);if(Math.min.apply(Math,Q)===L[a].x){var te=[];U.forEach(function(ee){te.push(n[ee].toFixed(i))}),V=Array.from(new Set(te.sort(function(ee,me){return parseFloat(ee)-parseFloat(me)}))).map(u).join(r);var le=Math.min.apply(Math,Q),ne=Math.max.apply(Math,Q),Z=w[U[Q.indexOf(ne)]].getBoundingClientRect().width;I.left="".concat(Math.abs(le-(ne+Z))/2,"px"),I.transform="translate(-50%, 0)"}else I.visibility="hidden"}E(V),h(I)}},[e,n]),[R,s]};ft.useThumbOverlap=JUe;function Rne(e,n,a,t){var r=e.getBoundingClientRect(),u=r.left,i=r.top,l=r.width,s=r.height;return yne(t)?Math.abs(a-(i+s/2)):Math.abs(n-(u+l/2))}});var Ene=He(yc=>{"use strict";var qUe=yc&&yc.__extends||(function(){var e=function(n,a){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,r){t.__proto__=r}||function(t,r){for(var u in r)Object.prototype.hasOwnProperty.call(r,u)&&(t[u]=r[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)}})(),$Ue=yc&&yc.__createBinding||(Object.create?(function(e,n,a,t){t===void 0&&(t=a);var r=Object.getOwnPropertyDescriptor(n,a);(!r||("get"in r?!n.__esModule:r.writable||r.configurable))&&(r={enumerable:!0,get:function(){return n[a]}}),Object.defineProperty(e,t,r)}):(function(e,n,a,t){t===void 0&&(t=a),e[t]=n[a]})),WUe=yc&&yc.__setModuleDefault||(Object.create?(function(e,n){Object.defineProperty(e,"default",{enumerable:!0,value:n})}):function(e,n){e.default=n}),xUe=yc&&yc.__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)&&$Ue(n,e,a);return WUe(n,e),n},bne=yc&&yc.__spreadArray||function(e,n,a){if(a||arguments.length===2)for(var t=0,r=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(r.target)}))return;t.setState({draggedTrackPos:[r.clientX,r.clientY]},function(){return t.onMove(r.clientX,r.clientY)})}else{var i=(0,fr.getClosestThumbIndex)(t.thumbRefs.map(function(l){return l.current}),r.clientX,r.clientY,t.props.direction);(u=t.thumbRefs[i].current)===null||u===void 0||u.focus(),t.setState({draggedThumbIndex:i},function(){return t.onMove(r.clientX,r.clientY)})}},t.onResize=function(){(0,fr.translateThumbs)(t.getThumbs(),t.getOffsets(),t.props.rtl),t.calculateMarkOffsets()},t.onTouchStartTrack=function(r){var u;if(r.persist(),t.addTouchEvents(r.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(r.target)}))return;t.setState({draggedTrackPos:[r.touches[0].clientX,r.touches[0].clientY]},function(){return t.onMove(r.touches[0].clientX,r.touches[0].clientY)})}else{var i=(0,fr.getClosestThumbIndex)(t.thumbRefs.map(function(l){return l.current}),r.touches[0].clientX,r.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(r.touches[0].clientX,r.touches[0].clientY)})}},t.onMouseOrTouchStart=function(r){if(!t.props.disabled){var u=(0,fr.isTouchEvent)(r);if(!(!u&&r.button!==0)){var i=t.getTargetIndex(r);i!==-1&&(u?t.addTouchEvents(r):t.addMouseEvents(r),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(r){r.preventDefault(),t.onMove(r.clientX,r.clientY)},t.onTouchMove=function(r){r.preventDefault(),t.onMove(r.touches[0].clientX,r.touches[0].clientY)},t.onKeyDown=function(r){var u=t.props,i=u.values,l=u.onChange,s=u.step,h=u.rtl,p=u.direction,R=t.state.isChanged,E=t.getTargetIndex(r.nativeEvent),w=h||p===Mu.Direction.Left||p===Mu.Direction.Down?-1:1;E!==-1&&(jUe.includes(r.key)?(r.preventDefault(),t.setState({draggedThumbIndex:E,isChanged:!0}),l((0,fr.replaceAt)(i,E,t.normalizeValue(i[E]+w*(r.key==="PageUp"?s*10:s),E)))):zUe.includes(r.key)?(r.preventDefault(),t.setState({draggedThumbIndex:E,isChanged:!0}),l((0,fr.replaceAt)(i,E,t.normalizeValue(i[E]-w*(r.key==="PageDown"?s*10:s),E)))):r.key==="Tab"?t.setState({draggedThumbIndex:-1},function(){R&&t.fireOnFinalChange()}):R&&t.fireOnFinalChange())},t.onKeyUp=function(r){var u=t.state.isChanged;t.setState({draggedThumbIndex:-1},function(){u&&t.fireOnFinalChange()})},t.onMove=function(r,u){var i=t.state,l=i.draggedThumbIndex,s=i.draggedTrackPos,h=t.props,p=h.direction,R=h.min,E=h.max,w=h.onChange,I=h.values,L=h.step,U=h.rtl;if(l===-1&&s[0]===-1&&s[1]===-1)return null;var V=t.trackRef.current;if(!V)return null;var Q=V.getBoundingClientRect(),te=(0,fr.isVertical)(p)?Q.height:Q.width;if(s[0]!==-1&&s[1]!==-1){var le=r-s[0],ne=u-s[1],Z=0;switch(p){case Mu.Direction.Right:case Mu.Direction.Left:Z=le/te*(E-R);break;case Mu.Direction.Down:case Mu.Direction.Up:Z=ne/te*(E-R);break;default:(0,fr.assertUnreachable)(p)}if(U&&(Z*=-1),Math.abs(Z)>=L/2){for(var ee=0;eeE?Z=E-I[ee]:me=L/2&&w((0,fr.replaceAt)(I,l,t.normalizeValue(Qe,l)))}},t.normalizeValue=function(r,u){var i=t.props,l=i.min,s=i.max,h=i.step,p=i.allowOverlap,R=i.values;return(0,fr.normalizeValue)(r,u,l,s,h,p,R)},t.onEnd=function(r){if(r.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 r=t.props,u=r.onFinalChange,i=r.values;u&&u(i)},t.updateMarkRefs=function(r){if(!r.renderMark){t.numOfMarks=void 0,t.markRefs=void 0;return}t.numOfMarks=(r.max-r.min)/t.props.step,t.markRefs=[];for(var u=0;u-1?"grabbing":this.props.draggableTrack?(0,fr.isVertical)(this.props.direction)?"ns-resize":"ew-resize":s.length===1&&!E?"pointer":"inherit"},onMouseDown:E?fr.voidFn:this.onMouseDownTrack,onTouchStart:E?fr.voidFn:this.onTouchStartTrack,ref:this.trackRef},isDragged:this.state.draggedThumbIndex>-1,disabled:E,children:bne(bne([],U.map(function(V,Q,te){return l({props:{style:a.props.direction===Mu.Direction.Left||a.props.direction===Mu.Direction.Right?{position:"absolute",left:"".concat(V[0],"px"),marginTop:"".concat(V[1],"px")}:{position:"absolute",top:"".concat(V[0],"px"),marginLeft:"".concat(V[1],"px")},key:"mark".concat(Q),ref:a.markRefs[Q]},index:Q})}),!0),s.map(function(V,Q){var te=a.state.draggedThumbIndex===Q;return u({index:Q,value:V,isDragged:te,props:{style:{position:"absolute",zIndex:L[Q],cursor:E?"inherit":te?"grabbing":"grab",userSelect:"none",touchAction:"none",WebkitUserSelect:"none",MozUserSelect:"none",msUserSelect:"none"},key:Q,tabIndex:E?void 0:0,"aria-valuemax":R?p:s[Q+1]||p,"aria-valuemin":R?h:s[Q-1]||h,"aria-valuenow":V,draggable:!1,ref:a.thumbRefs[Q],role:"slider",onKeyDown:E?fr.voidFn:a.onKeyDown,onKeyUp:E?fr.voidFn:a.onKeyUp}})}),!0)})},n.defaultProps={step:1,direction:Mu.Direction.Right,rtl:!1,disabled:!1,allowOverlap:!1,draggableTrack:!1,min:0,max:100},n})(qS.Component);yc.default=VUe});var Ine=He(Pi=>{"use strict";var QUe=Pi&&Pi.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Pi,"__esModule",{value:!0});Pi.checkValuesAgainstBoundaries=Pi.relativeValue=Pi.useThumbOverlap=Pi.Direction=Pi.getTrackBackground=Pi.Range=void 0;var KUe=QUe(Ene());Pi.Range=KUe.default;var $S=MN();Object.defineProperty(Pi,"getTrackBackground",{enumerable:!0,get:function(){return $S.getTrackBackground}});Object.defineProperty(Pi,"useThumbOverlap",{enumerable:!0,get:function(){return $S.useThumbOverlap}});Object.defineProperty(Pi,"relativeValue",{enumerable:!0,get:function(){return $S.relativeValue}});Object.defineProperty(Pi,"checkValuesAgainstBoundaries",{enumerable:!0,get:function(){return $S.checkValuesAgainstBoundaries}});var YUe=JS();Object.defineProperty(Pi,"Direction",{enumerable:!0,get:function(){return YUe.Direction}})});var $He={};J4($He,{boot:()=>qHe});var $4=function(e){return function(n){for(var a=e.length,t=n.length,r=new Array(a*t),u=0,i=0;i=a.length?n:e(a[t])};var K4=function(e,n,a,t){for(var r=0,u=t.length;r=t.length)return n;var r=t.slice();return r.splice(a,1),e(r)};var td=function(e){return e.slice().reverse()};var X4=function(e,n){return n.filter(e)};var Z4=(function(){function e(n,a,t,r,u,i){var l,s,h,p,R,E,w;for(l=u+(i-u>>1),l-u>1&&e(n,a,r,t,u,l),i-l>1&&e(n,a,r,t,l,i),s=u,h=l,p=u;s0?(t[p++]=E,++h):(t[p++]=R,++s);for(;s="0"&&e[r]<="9"?"\\&":"";return"\\"+a.charCodeAt(0).toString(10)+u})+'"'};var ir={show:w8};var b8=function(e){return e.showRecordFields},D_=function(){return function(){return function(e){var n=b8(e);return{show:function(a){return"{"+(n(lt.value)(a)+"}")}}}}};var Y0={show:R8},pn={show:D8},qg={show:y8},id={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])}},oe=function(e){return e.show};var R_=function(e){var n=Vt(e);return function(a){var t=b8(a);return function(r){var u=oe(r);return{showRecordFields:function(i){return function(l){var s=t(lt.value)(l),h=n(lt.value),p=mu(h)(l);return" "+(h+(": "+(u(p)+(","+s))))}}}}}},y_=function(e){var n=Vt(e);return function(a){var t=oe(a);return{showRecordFields:function(r){return function(u){var i=n(lt.value),l=mu(i)(u);return" "+(i+(": "+(t(l)+" ")))}}}}};var Te=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),fe=(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})(),$g=function(e){return e};var ld=function(e){return e.to};var cd=function(e){return e.from};var yoe=hn(En),G=(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 E8=function(e){var n=tn(e);return{append:function(a){return function(t){if(a instanceof G)return t;if(t instanceof G)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 Wn=function(e){return function(n){return function(a){if(a instanceof G)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])}}},Rr=Wn(!0)(gn(!1)),Fr=Wn(!1)(gn(!0));var ue={map:function(e){return function(n){return n instanceof T?new T(e(n.value0)):G.value}}},woe=B(ue);var je=function(e){return Wn(e)(yoe)},lr=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 qr=function(e){var n=we(e);return{eq:function(a){return function(t){return a instanceof G&&t instanceof G?!0:a instanceof T&&t instanceof T?n(a.value0)(t.value0):!1}}}},Di=function(e){var n=We(e),a=qr(e.Eq0());return{compare:function(t){return function(r){if(t instanceof G&&r instanceof G)return Be.value;if(t instanceof G)return ye.value;if(r instanceof G)return De.value;if(t instanceof T&&r instanceof T)return n(t.value0)(r.value0);throw new Error("Failed pattern match at Data.Maybe (line 0, column 0 - line 0, column 0): "+[t.constructor.name,r.constructor.name])}},Eq0:function(){return a}}};var Ro={apply:function(e){return function(n){if(e instanceof T)return woe(e.value0)(n);if(e instanceof G)return G.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 ue}};var nn={bind:function(e){return function(n){if(e instanceof T)return n(e.value0);if(e instanceof G)return G.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 Ro}};var ka=(function(){return{pure:T.create,Apply0:function(){return Ro}}})();var du={alt:function(e){return function(n){return e instanceof G?n:e}},Functor0:function(){return ue}},boe=(function(){return{empty:G.value,Alt0:function(){return du}}})(),hu={Applicative0:function(){return ka},Plus1:function(){return boe}};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 Ac=function(e){return Wn(new Me(e))(Le.create)};var eo={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])}}},Ioe=B(eo);var yr=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])}}},vf=(function(){return yr(gn(G.value))(T.create)})();var Wg={apply:function(e){return function(n){if(e instanceof Me)return new Me(e.value0);if(e instanceof Le)return Ioe(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 eo}};var Ri={bind:yr(function(e){return function(n){return new Me(e)}})(function(e){return function(n){return n(e)}}),Apply0:function(){return Wg}};var uv=(function(){return{pure:Le.create,Apply0:function(){return Wg}}})(),sb={Applicative0:function(){return uv},Bind1:function(){return Ri}};var gl=function(e){return e};var ws={map:function(e){return function(n){return e(n)}}};var I8={apply:function(e){return function(n){return e(n)}},Functor0:function(){return ws}},Toe={bind:function(e){return function(n){return n(e)}},Apply0:function(){return I8}},sd={pure:gl,Apply0:function(){return I8}},Nr={Applicative0:function(){return sd},Bind1:function(){return Toe}};var T8=function(e){return Math.min(Math.abs(e),2147483647)},S8=function(e){return function(n){return n===0?0:n>0?Math.floor(e/n):-Math.floor(e/-n)}},C8=function(e){return function(n){if(n===0)return 0;var a=Math.abs(n);return(e%a+a)%a}};var qF={Ring0:function(){return tv}};var gu=function(e){return e.mod};var ho={degree:T8,div:S8,mod:C8,CommutativeRing0:function(){return qF}},ou=function(e){return e.div};var cr={mempty:"",Semigroup0:function(){return V0}};var Ft=function(e){return e.mempty};var G8=function(e){return function(){return e}},M8=function(e){return function(n){return function(){return n(e())()}}};var $F=function(e){return function(n){return function(){for(var a=0,t=e.length;a=0;u--)t=e(a[u])(t);return t}}},r7=function(e){return function(n){return function(a){for(var t=n,r=a.length,u=0;u":e===void 0?"":e instanceof Date?e.toString():typeof Blob<"u"&&e instanceof Blob?"file["+e.name+"]":JSON.stringify(e)}var fie=Or(Je),O7=Es(I_),_ie=Zt(Je);var Dd=function(e){return e.foldrWithIndex};var Rd=function(e){return e.foldlWithIndex};var pie=function(e){var n=Dd(e);return function(a){var t=tn(a.Semigroup0()),r=Ft(a);return function(u){return n(function(i){return function(l){return function(s){return t(u(i)(l))(s)}}})(r)}}},iD={foldrWithIndex:function(e){return function(n){var a=fie(function(r){return function(u){return e(r.value0)(r.value1)(u)}})(n),t=O7(yn.create);return function(r){return a(t(r))}}},foldlWithIndex:function(e){return function(n){var a=_ie(function(r){return function(u){return e(u.value0)(r)(u.value1)}})(n),t=O7(yn.create);return function(r){return a(t(r))}}},foldMapWithIndex:function(e){return pie(iD)(e)},Foldable0:function(){return Je}};var U7=function(e){var n=Rd(e);return function(a){var t=function(r){return function(u){return function(i){return u instanceof G?a(r)(i):u}}};return n(t)(G.value)}};var k7=function(e){return function(n){return function(a){return(a|0)===a?e(a):n}}},br=function(e){return e},B7=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 r=new RegExp("^[\\+\\-]?"+t+"+$","i");return function(u){if(r.test(u)){var i=parseInt(u,a);return(i|0)===i?e(i):n}else return n}}}};var Mb=isFinite;var pG=Math.abs;var yd=Math.floor,mG=Math.log;var Ab=function(e){return function(n){return Math.pow(e,n)}};var hp=Math.round;var H7=2.302585092994046;var J7=Cr(Jg),q7=Ut(Jg);var yie=(function(){return B7(T.create)(G.value)})(),Ts=yie(10),hf=(function(){return k7(T.create)(G.value)})(),W7=function(e){if(!Mb(e))return 0;if(e>=br(J7))return J7;if(e<=br(q7))return q7;if(Ve)return je(0)(hf(e));throw new Error("Failed pattern match at Data.Int (line 72, column 1 - line 72, column 29): "+[e.constructor.name])},hG=function(e){return W7(hp(e))};var ku=function(e){return W7(yd(e))};function lD(e){return Object.prototype.toString.call(e).slice(8,-1)}function F_(e){return e===null}function G_(e){return e===void 0}var Lb=Array.isArray||function(e){return Object.prototype.toString.call(e)==="[object Array]"};function x7(e){return e.stack||e.toString()}function zi(e){return new Error(e)}function gp(e){return e.message}function Pb(e){return function(){throw e}}var z7=function(e){return Pb(zi(e))};var V7={show:x7};var wo=function(e){return e.throwError};var Mr=function(e){return e.catchError};var M_=function(e){var n=Mr(e),a=e.MonadThrow0().Monad0(),t=B(a.Bind1().Apply0().Functor0()),r=x(a.Applicative0());return function(u){return n(t(Le.create)(u))(function(i){return r(Me.create(i))})}};var Go={liftEffect:hn(En),Monad0:function(){return iv}},Hn=function(e){return e.liftEffect};var Iie=B(eo);var Ub=function(e){return e};var vD=function(e){return e};var kb=function(e){return function(n){return e(n)}},Id=function(e){var n=B(e);return{map:function(a){return kb(n(Iie(a)))}}};var K7=function(e){return{Applicative0:function(){return Xl(e)},Bind1:function(){return Oc(e)}}},Oc=function(e){var n=ae(e.Bind1()),a=x(e.Applicative0());return{bind:function(t){return function(r){return n(t)(yr(function(u){return a(Me.create(u))})(function(u){var i=r(u);return i}))}},Apply0:function(){return Bb(e)}}},Bb=function(e){var n=Id(e.Bind1().Apply0().Functor0());return{apply:ml(K7(e)),Functor0:function(){return n}}},Xl=function(e){return{pure:(function(){var n=x(e.Applicative0());return function(a){return Ub(n(Le.create(a)))}})(),Apply0:function(){return Bb(e)}}};var Hb=function(e){var n=K7(e);return{throwError:(function(){var a=x(e.Applicative0());return function(t){return Ub(a(Me.create(t)))}})(),Monad0:function(){return n}}};var fD=function(e){var n=tn(e);return function(a){var t=a.Bind1(),r=ae(t),u=x(a.Applicative0()),i=Id(t.Apply0().Functor0());return{alt:function(l){return function(s){return r(l)(function(h){if(h instanceof Le)return u(new Le(h.value0));if(h instanceof Me)return r(s)(function(p){if(p instanceof Le)return u(new Le(p.value0));if(p instanceof Me)return u(new Me(n(h.value0)(p.value0)));throw new Error("Failed pattern match at Control.Monad.Except.Trans (line 87, column 9 - line 89, column 49): "+[p.constructor.name])});throw new Error("Failed pattern match at Control.Monad.Except.Trans (line 83, column 5 - line 89, column 49): "+[h.constructor.name])})}},Functor0:function(){return i}}}};var yl=(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 Jb=function(e){var n=Uu(e);return function(a){return new yl(a,n)}};var gG=function(e){var n=B(e);return{map:function(a){return function(t){return new yl(a(t.value0),n(a)(t.value1))}}}};var DG=function(e){var n=Fo(e),a=Zt(e),t=Or(e);return{foldMap:function(r){var u=tn(r.Semigroup0()),i=n(r);return function(l){return function(s){return u(l(s.value0))(i(l)(s.value1))}}},foldl:function(r){return function(u){return function(i){return a(r)(r(u)(i.value0))(i.value1)}}},foldr:function(r){return function(u){return function(i){return r(i.value0)(t(r)(u)(i.value1))}}}}};var Ar=(function(){function e(){}return e.value=new e,e})(),Gt=(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})(),qb=function(e){return e},Pie=function(e){return new Gt(e.value0,e.value1)};var Nie=function(e){var n=function(a){return function(t){var r=a,u=!1,i;function l(s,h){if(h instanceof Gt&&h.value1 instanceof Gt&&h.value1.value1 instanceof Gt){r=new Gt(h,s),t=h.value1.value1.value1;return}var p=function(E){return E instanceof Gt&&E.value1 instanceof Gt&&E.value1.value1 instanceof Ar?new Gt(e(E.value0),new Gt(e(E.value1.value0),Ar.value)):E instanceof Gt&&E.value1 instanceof Ar?new Gt(e(E.value0),Ar.value):Ar.value},R=function(E){return function(w){var I=E,L=!1,U;function V(Q,te){if(Q instanceof Gt&&Q.value0 instanceof Gt&&Q.value0.value1 instanceof Gt&&Q.value0.value1.value1 instanceof Gt){I=Q.value1,w=new Gt(e(Q.value0.value0),new Gt(e(Q.value0.value1.value0),new Gt(e(Q.value0.value1.value1.value0),te)));return}return L=!0,te}for(;!L;)U=V(I,w);return U}};return u=!0,R(s)(p(h))}for(;!u;)i=l(r,t);return i}};return n(Ar.value)},RG={map:Nie};var $b=gG(RG),Vo={foldr:function(e){return function(n){var a=(function(){var r=function(u){return function(i){var l=u,s=!1,h;function p(R,E){if(E instanceof Ar)return s=!0,R;if(E instanceof Gt){l=new Gt(E.value0,R),i=E.value1;return}throw new Error("Failed pattern match at Data.List.Types (line 107, column 7 - line 107, column 23): "+[R.constructor.name,E.constructor.name])}for(;!s;)h=p(l,i);return h}};return r(Ar.value)})(),t=Zt(Vo)(it(e))(n);return function(r){return t(a(r))}}},foldl:function(e){var n=function(a){return function(t){var r=a,u=!1,i;function l(s,h){if(h instanceof Ar)return u=!0,s;if(h instanceof Gt){r=e(s)(h.value0),t=h.value1;return}throw new Error("Failed pattern match at Data.List.Types (line 111, column 12 - line 113, column 30): "+[h.constructor.name])}for(;!u;)i=l(r,t);return i}};return n},foldMap:function(e){var n=tn(e.Semigroup0()),a=Ft(e);return function(t){return Zt(Vo)(function(r){var u=n(r);return function(i){return u(t(i))}})(a)}}};var Oie=Or(Vo);var pD=DG(Vo);var Wb={append:function(e){return function(n){return Oie(Gt.create)(n)(e)}}},eO=tn(Wb);var mD={append:function(e){return function(n){return new yl(e.value0,eO(e.value1)(Pie(n)))}}};var nO={alt:eO,Functor0:function(){return RG}},yG=(function(){return{empty:Ar.value,Alt0:function(){return nO}}})();var Wie=$t(k8);var oO=function(e){return new Gt(e,Ar.value)};var wG=(function(){var e=function(n){return function(a){var t=n,r=!1,u;function i(l,s){if(s instanceof Ar)return r=!0,l;if(s instanceof Gt){t=new Gt(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(;!r;)u=i(t,a);return u}};return e(Ar.value)})();var bG=function(e){var n=ae(e.Monad0().Bind1()),a=ni(e);return function(t){var r=t.Plus1().Alt0(),u=La(r),i=B(r.Functor0()),l=x(t.Applicative0());return function(s){var h=function(p){return n(u(i(Kr.create)(s))(l(new $r(void 0))))(function(R){return l(Wie(function(E){return new Gt(E,p)})(function(E){return wG(p)})(R))})};return a(h)(Ar.value)}}};var Bu=function(e){return Or(e)(Gt.create)(Ar.value)};var uO=function(e){return e()};var iO=function(e){throw new Error(e)};var lO=function(){return iO};var Vie=lO(),Qie=uO,wl=function(e){return Qie(function(){return Vie(e)})};var hD=(function(){var e=Jb(yG);return function(n){return qb(e(n))}})();var vO=function(e){return e.value0};var Sd=function(e){return e.join("")},gD=function(e){return e.split("")},Vi=function(e){return e},fO=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 IO(e,n){var a=GG(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond),t=GG(n.year,n.month-1,n.day,n.hour,n.minute,n.second,n.millisecond);return a-t}function TO(e){return function(n){return function(a){return function(t){var r=GG(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond),u=new Date(r+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 SO=function(e,n,a){var t=new Date(Date.UTC(e,n,a));return e>=0&&e<100&&t.setUTCFullYear(e),t};function CO(e,n,a,t){var r=SO(n,a-1,t);return e(r.getUTCFullYear())(r.getUTCMonth()+1)(r.getUTCDate())}function FO(e,n,a){return SO(e,n-1,a).getUTCDay()}function U_(e){return e.charCodeAt(0)}function GO(e){return String.fromCharCode(e)}var Qo=function(e){var n=x(e.Applicative0()),a=Uu(e.Plus1());return function(t){if(t)return n(void 0);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 MO=Ut(g_),AO=Cr(g_);var Fa=function(e){return e.toEnum};var Yn=function(e){return e.fromEnum},AG=function(e){var n=Fa(e),a=Yn(e),t=Ut(e.Bounded0());return function(r){return function(u){return function(i){var l=n(i);if(l instanceof T)return l.value0;if(l instanceof G){var s=i=U_(MO)&&e<=U_(AO)?new T(GO(e)):G.value},ble={succ:Ip(MG)(U_),pred:Tp(MG)(U_),Ord0:function(){return lb}};var Sp=(function(){return{cardinality:U_(AO)-U_(MO)|0,toEnum:MG,fromEnum:U_,Bounded0:function(){return g_},Enum1:function(){return ble}}})();var Kb=function(e,n,a){var t=0,r;return function(u){if(t===2)return r;if(t===1)throw new ReferenceError(e+" was needed before it finished initializing (module "+n+", line "+u+")",n,u);return t=1,r=a(),t=2,r}},LO=oe(pn);var ec=(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})(),Jc=(function(){function e(){}return e.value=new e,e})(),qc=(function(){function e(){}return e.value=new e,e})(),$c=(function(){function e(){}return e.value=new e,e})(),Gs=(function(){function e(){}return e.value=new e,e})(),Ei=(function(){function e(){}return e.value=new e,e})(),Qi=(function(){function e(){}return e.value=new e,e})(),Ii=(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})(),Ti=(function(){function e(){}return e.value=new e,e})(),Si=(function(){function e(){}return e.value=new e,e})(),Xi=(function(){function e(){}return e.value=new e,e})(),Zi=(function(){function e(){}return e.value=new e,e})(),el=(function(){function e(){}return e.value=new e,e})(),nl=(function(){function e(){}return e.value=new e,e})(),Tl=(function(){function e(){}return e.value=new e,e})();var PO={show:function(e){return"(Year "+(LO(e)+")")}},NO={show:function(e){if(e instanceof ec)return"Monday";if(e instanceof Bc)return"Tuesday";if(e instanceof Hc)return"Wednesday";if(e instanceof Jc)return"Thursday";if(e instanceof qc)return"Friday";if(e instanceof $c)return"Saturday";if(e instanceof Gs)return"Sunday";throw new Error("Failed pattern match at Data.Date.Component (line 184, column 1 - line 191, column 25): "+[e.constructor.name])}},Yb={show:function(e){if(e instanceof Ei)return"January";if(e instanceof Qi)return"February";if(e instanceof Ii)return"March";if(e instanceof Ki)return"April";if(e instanceof Yi)return"May";if(e instanceof Ti)return"June";if(e instanceof Si)return"July";if(e instanceof Xi)return"August";if(e instanceof Zi)return"September";if(e instanceof el)return"October";if(e instanceof nl)return"November";if(e instanceof Tl)return"December";throw new Error("Failed pattern match at Data.Date.Component (line 101, column 1 - line 113, column 29): "+[e.constructor.name])}},OO={show:function(e){return"(Day "+(LO(e)+")")}},Xb=Ca,Zb=Ca,UO=Wt,Ele={eq:function(e){return function(n){return e instanceof ec&&n instanceof ec||e instanceof Bc&&n instanceof Bc||e instanceof Hc&&n instanceof Hc||e instanceof Jc&&n instanceof Jc||e instanceof qc&&n instanceof qc||e instanceof $c&&n instanceof $c||e instanceof Gs&&n instanceof Gs}}},kO={compare:function(e){return function(n){if(e instanceof ec&&n instanceof ec)return Be.value;if(e instanceof ec)return ye.value;if(n instanceof ec)return De.value;if(e instanceof Bc&&n instanceof Bc)return Be.value;if(e instanceof Bc)return ye.value;if(n instanceof Bc)return De.value;if(e instanceof Hc&&n instanceof Hc)return Be.value;if(e instanceof Hc)return ye.value;if(n instanceof Hc)return De.value;if(e instanceof Jc&&n instanceof Jc)return Be.value;if(e instanceof Jc)return ye.value;if(n instanceof Jc)return De.value;if(e instanceof qc&&n instanceof qc)return Be.value;if(e instanceof qc)return ye.value;if(n instanceof qc)return De.value;if(e instanceof $c&&n instanceof $c)return Be.value;if(e instanceof $c)return ye.value;if(n instanceof $c)return De.value;if(e instanceof Gs&&n instanceof Gs)return Be.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 Ele}},LG={eq:function(e){return function(n){return e instanceof Ei&&n instanceof Ei||e instanceof Qi&&n instanceof Qi||e instanceof Ii&&n instanceof Ii||e instanceof Ki&&n instanceof Ki||e instanceof Yi&&n instanceof Yi||e instanceof Ti&&n instanceof Ti||e instanceof Si&&n instanceof Si||e instanceof Xi&&n instanceof Xi||e instanceof Zi&&n instanceof Zi||e instanceof el&&n instanceof el||e instanceof nl&&n instanceof nl||e instanceof Tl&&n instanceof Tl}}},Ad={compare:function(e){return function(n){if(e instanceof Ei&&n instanceof Ei)return Be.value;if(e instanceof Ei)return ye.value;if(n instanceof Ei)return De.value;if(e instanceof Qi&&n instanceof Qi)return Be.value;if(e instanceof Qi)return ye.value;if(n instanceof Qi)return De.value;if(e instanceof Ii&&n instanceof Ii)return Be.value;if(e instanceof Ii)return ye.value;if(n instanceof Ii)return De.value;if(e instanceof Ki&&n instanceof Ki)return Be.value;if(e instanceof Ki)return ye.value;if(n instanceof Ki)return De.value;if(e instanceof Yi&&n instanceof Yi)return Be.value;if(e instanceof Yi)return ye.value;if(n instanceof Yi)return De.value;if(e instanceof Ti&&n instanceof Ti)return Be.value;if(e instanceof Ti)return ye.value;if(n instanceof Ti)return De.value;if(e instanceof Si&&n instanceof Si)return Be.value;if(e instanceof Si)return ye.value;if(n instanceof Si)return De.value;if(e instanceof Xi&&n instanceof Xi)return Be.value;if(e instanceof Xi)return ye.value;if(n instanceof Xi)return De.value;if(e instanceof Zi&&n instanceof Zi)return Be.value;if(e instanceof Zi)return ye.value;if(n instanceof Zi)return De.value;if(e instanceof el&&n instanceof el)return Be.value;if(e instanceof el)return ye.value;if(n instanceof el)return De.value;if(e instanceof nl&&n instanceof nl)return Be.value;if(e instanceof nl)return ye.value;if(n instanceof nl)return De.value;if(e instanceof Tl&&n instanceof Tl)return Be.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 LG}},BO=Wt,e1=(function(){return{bottom:-271820,top:275759,Ord0:function(){return Xb}}})(),Ile=(function(){return{bottom:ec.value,top:Gs.value,Ord0:function(){return kO}}})(),n1=(function(){return{bottom:Ei.value,top:Tl.value,Ord0:function(){return Ad}}})(),cu={cardinality:547580,toEnum:function(e){if(e>=-271820&&e<=275759)return new T(e);if(Ve)return G.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 e1},Enum1:function(){return Tle(0)}},Tle=Kb("enumYear","Data.Date.Component",function(){return{succ:(function(){var e=Fa(cu),n=Yn(cu);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(cu),n=Yn(cu);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return Xb}}});var k_={cardinality:7,toEnum:function(e){return e===1?new T(ec.value):e===2?new T(Bc.value):e===3?new T(Hc.value):e===4?new T(Jc.value):e===5?new T(qc.value):e===6?new T($c.value):e===7?new T(Gs.value):G.value},fromEnum:function(e){if(e instanceof ec)return 1;if(e instanceof Bc)return 2;if(e instanceof Hc)return 3;if(e instanceof Jc)return 4;if(e instanceof qc)return 5;if(e instanceof $c)return 6;if(e instanceof Gs)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 Ile},Enum1:function(){return Sle(0)}},Sle=Kb("enumWeekday","Data.Date.Component",function(){return{succ:(function(){var e=Fa(k_),n=Yn(k_);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(k_),n=Yn(k_);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return kO}}});var go={cardinality:12,toEnum:function(e){return e===1?new T(Ei.value):e===2?new T(Qi.value):e===3?new T(Ii.value):e===4?new T(Ki.value):e===5?new T(Yi.value):e===6?new T(Ti.value):e===7?new T(Si.value):e===8?new T(Xi.value):e===9?new T(Zi.value):e===10?new T(el.value):e===11?new T(nl.value):e===12?new T(Tl.value):G.value},fromEnum:function(e){if(e instanceof Ei)return 1;if(e instanceof Qi)return 2;if(e instanceof Ii)return 3;if(e instanceof Ki)return 4;if(e instanceof Yi)return 5;if(e instanceof Ti)return 6;if(e instanceof Si)return 7;if(e instanceof Xi)return 8;if(e instanceof Zi)return 9;if(e instanceof el)return 10;if(e instanceof nl)return 11;if(e instanceof Tl)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 n1},Enum1:function(){return Cle(0)}},Cle=Kb("enumMonth","Data.Date.Component",function(){return{succ:(function(){var e=Fa(go),n=Yn(go);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(go),n=Yn(go);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return Ad}}});var TD={bottom:1,top:31,Ord0:function(){return Zb}},Il={cardinality:31,toEnum:function(e){if(e>=1&&e<=31)return new T(e);if(Ve)return G.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 TD},Enum1:function(){return Fle(0)}},Fle=Kb("enumDay","Data.Date.Component",function(){return{succ:(function(){var e=Fa(Il),n=Yn(Il);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(Il),n=Yn(Il);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return Zb}}});var Ld=gb()();var HO=hn(En),a1=function(e){return e},JO=function(e){return e},Pd=function(e){return e};var qO=function(e){return e},SD=function(e){return e.toDuration};var $O={append:function(e){return function(n){return e+n}}};var t1={append:function(e){return function(n){return e+n}}};var WO=rv;var xO=rv;var PG=function(e){return e.fromDuration};var If={fromDuration:Ld(a1)(function(e){return e*1e3}),toDuration:Ld(Pd)(function(e){return e/1e3})},Cp={fromDuration:Ld(JO)(function(e){return e*6e4}),toDuration:Ld(Pd)(function(e){return e/6e4})},Nd={fromDuration:HO,toDuration:HO};var NG={fromDuration:Ld(qO)(function(e){return e*864e5}),toDuration:Ld(Pd)(function(e){return e/864e5})};var zO=Yn(go),OG=lr(),jO=Fa(k_),Mle=oe(PO),Ale=oe(Yb),Lle=oe(OO);var Ple=we(UO),Nle=we(LG),Ole=we(BO),Ule=We(Xb),kle=We(Ad),Ble=We(Zb);var Hle=Fa(go);var r1=(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})(),Cl=function(e){return e.value0},CD=function(e){var n=FO(e.value0,zO(e.value1),e.value2),a=n===0;return OG(jO(a?7:n))},VO={show:function(e){return"(Date "+(Mle(e.value0)+(" "+(Ale(e.value1)+(" "+(Lle(e.value2)+")")))))}},Fl=function(e){return e.value1};var o1={eq:function(e){return function(n){return Ple(e.value0)(n.value0)&&Nle(e.value1)(n.value1)&&Ole(e.value2)(n.value2)}}},Jle=we(o1),BG={compare:function(e){return function(n){var a=Ule(e.value0)(n.value0);if(a instanceof ye)return ye.value;if(a instanceof De)return De.value;var t=kle(e.value1)(n.value1);return t instanceof ye?ye.value:t instanceof De?De.value:Ble(e.value2)(n.value2)}},Eq0:function(){return o1}};var hv=function(e){return e.value2},B_=function(e){return function(n){return function(a){var t=function(r){return function(u){return function(i){return new r1(r,OG(Hle(u)),i)}}};return CO(t,e,zO(n),a)}}},u1=function(e){return function(n){return function(a){var t=new r1(e,n,a),r=Jle(B_(e)(n)(a))(t);return r?new T(t):G.value}}},HG=(function(){return{bottom:new r1(Ut(e1),Ut(n1),Ut(TD)),top:new r1(Cr(e1),Cr(n1),Cr(TD)),Ord0:function(){return BG}}})();var i1=function(e,n,a){var t=0,r;return function(u){if(t===2)return r;if(t===1)throw new ReferenceError(e+" was needed before it finished initializing (module "+n+", line "+u+")",n,u);return t=1,r=a(),t=2,r}},l1=oe(pn);var QO={show:function(e){return"(Second "+(l1(e)+")")}},KO={show:function(e){return"(Minute "+(l1(e)+")")}},YO={show:function(e){return"(Millisecond "+(l1(e)+")")}},XO={show:function(e){return"(Hour "+(l1(e)+")")}},c1=Ca,s1=Ca,v1=Ca,f1=Ca,ZO=Wt,e6=Wt,n6=Wt,a6=Wt,FD={bottom:0,top:59,Ord0:function(){return c1}},GD={bottom:0,top:59,Ord0:function(){return s1}},MD={bottom:0,top:999,Ord0:function(){return v1}},AD={bottom:0,top:23,Ord0:function(){return f1}},nc={cardinality:60,toEnum:function(e){if(e>=0&&e<=59)return new T(e);if(Ve)return G.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 FD},Enum1:function(){return qle(0)}},qle=i1("enumSecond","Data.Time.Component",function(){return{succ:(function(){var e=Fa(nc),n=Yn(nc);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(nc),n=Yn(nc);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return c1}}});var ac={cardinality:60,toEnum:function(e){if(e>=0&&e<=59)return new T(e);if(Ve)return G.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 GD},Enum1:function(){return $le(0)}},$le=i1("enumMinute","Data.Time.Component",function(){return{succ:(function(){var e=Fa(ac),n=Yn(ac);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(ac),n=Yn(ac);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return s1}}});var al={cardinality:1e3,toEnum:function(e){if(e>=0&&e<=999)return new T(e);if(Ve)return G.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 MD},Enum1:function(){return Wle(0)}},Wle=i1("enumMillisecond","Data.Time.Component",function(){return{succ:(function(){var e=Fa(al),n=Yn(al);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(al),n=Yn(al);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return v1}}});var tc={cardinality:24,toEnum:function(e){if(e>=0&&e<=23)return new T(e);if(Ve)return G.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 AD},Enum1:function(){return xle(0)}},xle=i1("enumHour","Data.Time.Component",function(){return{succ:(function(){var e=Fa(tc),n=Yn(tc);return function(a){return e((function(t){return t+1|0})(n(a)))}})(),pred:(function(){var e=Fa(tc),n=Yn(tc);return function(a){return e((function(t){return t-1|0})(n(a)))}})(),Ord0:function(){return f1}}});var Vle=oe(XO),Qle=oe(KO),Kle=oe(QO),Yle=oe(YO);var Xle=we(a6),Zle=we(e6),ece=we(ZO),nce=we(n6),ace=We(f1),tce=We(s1),rce=We(c1),oce=We(v1);var gv=(function(){function e(n,a,t,r){this.value0=n,this.value1=a,this.value2=t,this.value3=r}return e.create=function(n){return function(a){return function(t){return function(r){return new e(n,a,t,r)}}}},e})(),t6={show:function(e){return"(Time "+(Vle(e.value0)+(" "+(Qle(e.value1)+(" "+(Kle(e.value2)+(" "+(Yle(e.value3)+")")))))))}};var Sf=function(e){return e.value2},Dv=function(e){return e.value1},Wc=function(e){return e.value3};var Ms=function(e){return e.value0};var JG={eq:function(e){return function(n){return Xle(e.value0)(n.value0)&&Zle(e.value1)(n.value1)&&ece(e.value2)(n.value2)&&nce(e.value3)(n.value3)}}},qG={compare:function(e){return function(n){var a=ace(e.value0)(n.value0);if(a instanceof ye)return ye.value;if(a instanceof De)return De.value;var t=tce(e.value1)(n.value1);if(t instanceof ye)return ye.value;if(t instanceof De)return De.value;var r=rce(e.value2)(n.value2);return r instanceof ye?ye.value:r instanceof De?De.value:oce(e.value3)(n.value3)}},Eq0:function(){return JG}};var Od=(function(){return{bottom:new gv(Ut(AD),Ut(GD),Ut(FD),Ut(MD)),top:new gv(Cr(AD),Cr(GD),Cr(FD),Cr(MD)),Ord0:function(){return qG}}})();var uce=Yn(cu),ice=Yn(go),lce=Yn(Il),cce=Yn(tc),sce=Yn(ac),vce=Yn(nc),fce=Yn(al),_ce=oe(VO),pce=oe(t6),mce=we(o1),dce=we(JG),hce=We(BG),gce=We(qG),Dce=ae(nn),Ud=sa(Ro),$G=B(ue),Rce=Bi(nn),yce=Fa(cu),wce=Fa(go),bce=Fa(Il),Ece=Fa(tc),Ice=Fa(ac),Tce=Fa(nc),Sce=Fa(al),xc=(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})(),WG=function(e){return{year:uce(Cl(e.value0)),month:ice(Fl(e.value0)),day:lce(hv(e.value0)),hour:cce(Ms(e.value1)),minute:sce(Dv(e.value1)),second:vce(Sf(e.value1)),millisecond:fce(Wc(e.value1))}},LD=function(e){return e.value1},r6={show:function(e){return"(DateTime "+(_ce(e.value0)+(" "+(pce(e.value1)+")")))}};var Cce={eq:function(e){return function(n){return mce(e.value0)(n.value0)&&dce(e.value1)(n.value1)}}},Gl={compare:function(e){return function(n){var a=hce(e.value0)(n.value0);return a instanceof ye?ye.value:a instanceof De?De.value:gce(e.value1)(n.value1)}},Eq0:function(){return Cce}},Ml=function(e){var n=SD(e);return function(a){return function(t){return n(IO(WG(a),WG(t)))}}},Ff=function(e){return e.value0},kd=(function(){return{bottom:new xc(Ut(HG),Ut(Od)),top:new xc(Cr(HG),Cr(Od)),Ord0:function(){return Gl}}})(),Rv=function(e){var n=PG(e);return function(a){return function(t){return Dce(TO(T.create)(G.value)(n(a))(WG(t)))(function(r){return Ud($G(xc.create)(Rce(Ud(Ud($G(u1)(yce(r.year)))(wce(r.month)))(bce(r.day)))))(Ud(Ud(Ud($G(gv.create)(Ece(r.hour)))(Ice(r.minute)))(Tce(r.second)))(Sce(r.millisecond)))})}}};var Fi=(function(){var e={},n="Pure",a="Throw",t="Catch",r="Sync",u="Async",i="Bind",l="Bracket",s="Fork",h="Sequential",p="Map",R="Apply",E="Alt",w="Cons",I="Resume",L="Release",U="Finalizer",V="Finalized",Q="Forked",te="Fiber",le="Thunk";function ne(Xe,Wa,Mt,zn){this.tag=Xe,this._1=Wa,this._2=Mt,this._3=zn}function Z(Xe){var Wa=function(Mt,zn,On){return new ne(Xe,Mt,zn,On)};return Wa.tag=Xe,Wa}function ee(Xe){return new ne(n,void 0)}function me(Xe){try{Xe()}catch(Wa){setTimeout(function(){throw Wa},0)}}function $e(Xe,Wa,Mt){try{return Wa(Mt())}catch(zn){return Xe(zn)}}function Qe(Xe,Wa,Mt){try{return Wa(Mt)()}catch(zn){return Mt(Xe(zn))(),ee}}var dn=(function(){var Xe=1024,Wa=0,Mt=0,zn=new Array(Xe),On=!1;function Ze(){var Ma;for(On=!0;Wa!==0;)Wa--,Ma=zn[Mt],zn[Mt]=void 0,Mt=(Mt+1)%Xe,Ma();On=!1}return{isDraining:function(){return On},enqueue:function(Ma){var Ja,pt;Wa===Xe&&(pt=On,Ze(),On=pt),zn[(Mt+Wa)%Xe]=Ma,Wa++,On||Ze()}}})();function qn(Xe){var Wa={},Mt=0,zn=0;return{register:function(On){var Ze=Mt++;On.onComplete({rethrow:!0,handler:function(Ma){return function(){zn--,delete Wa[Ze]}}})(),Wa[Ze]=On,zn++},isEmpty:function(){return zn===0},killAll:function(On,Ze){return function(){if(zn===0)return Ze();var Ma=0,Ja={};function pt(In){Ja[In]=Wa[In].kill(On,function(Oa){return function(){delete Ja[In],Ma--,Xe.isLeft(Oa)&&Xe.fromLeft(Oa)&&setTimeout(function(){throw Xe.fromLeft(Oa)},0),Ma===0&&Ze()}})()}for(var tr in Wa)Wa.hasOwnProperty(tr)&&(Ma++,pt(tr));return Wa={},Mt=0,zn=0,function(In){return new ne(r,function(){for(var Oa in Ja)Ja.hasOwnProperty(Oa)&&Ja[Oa]()})}}}}}var Mn=0,An=1,kn=2,Ia=3,Da=4,da=5,Dt=6;function _t(Xe,Wa,Mt){var zn=0,On=Mn,Ze=Mt,Ma=null,Ja=null,pt=null,tr=null,In=null,Oa=0,dr=0,za=null,jt=!0;function W(P){for(var O,j,K;;)switch(O=null,j=null,K=null,On){case kn:On=An;try{Ze=pt(Ze),tr===null?pt=null:(pt=tr._1,tr=tr._2)}catch(ce){On=da,Ma=Xe.left(ce),Ze=null}break;case Ia:Xe.isLeft(Ze)?(On=da,Ma=Ze,Ze=null):pt===null?On=da:(On=kn,Ze=Xe.fromRight(Ze));break;case An:switch(Ze.tag){case i:pt&&(tr=new ne(w,pt,tr)),pt=Ze._2,On=An,Ze=Ze._1;break;case n:pt===null?(On=da,Ze=Xe.right(Ze._1)):(On=kn,Ze=Ze._1);break;case r:On=Ia,Ze=$e(Xe.left,Xe.right,Ze._1);break;case u:On=Da,Ze=Qe(Xe.left,Ze._1,function(ce){return function(){zn===P&&(zn++,dn.enqueue(function(){zn===P+1&&(On=Ia,Ze=ce,W(zn))}))}});return;case a:On=da,Ma=Xe.left(Ze._1),Ze=null;break;case t:pt===null?In=new ne(w,Ze,In,Ja):In=new ne(w,Ze,new ne(w,new ne(I,pt,tr),In,Ja),Ja),pt=null,tr=null,On=An,Ze=Ze._1;break;case l:Oa++,pt===null?In=new ne(w,Ze,In,Ja):In=new ne(w,Ze,new ne(w,new ne(I,pt,tr),In,Ja),Ja),pt=null,tr=null,On=An,Ze=Ze._1;break;case s:On=Ia,O=_t(Xe,Wa,Ze._2),Wa&&Wa.register(O),Ze._1&&O.run(),Ze=Xe.right(O);break;case h:On=An,Ze=Tr(Xe,Wa,Ze._1);break}break;case da:if(pt=null,tr=null,In===null)On=Dt,Ze=Ja||Ma||Ze;else switch(O=In._3,K=In._1,In=In._2,K.tag){case t:Ja&&Ja!==O&&Oa===0?On=da:Ma&&(On=An,Ze=K._2(Xe.fromLeft(Ma)),Ma=null);break;case I:Ja&&Ja!==O&&Oa===0||Ma?On=da:(pt=K._1,tr=K._2,On=kn,Ze=Xe.fromRight(Ze));break;case l:Oa--,Ma===null&&(j=Xe.fromRight(Ze),In=new ne(w,new ne(L,K._2,j),In,O),(Ja===O||Oa>0)&&(On=An,Ze=K._3(j)));break;case L:In=new ne(w,new ne(V,Ze,Ma),In,Ja),On=An,Ja&&Ja!==O&&Oa===0?Ze=K._1.killed(Xe.fromLeft(Ja))(K._2):Ma?Ze=K._1.failed(Xe.fromLeft(Ma))(K._2):Ze=K._1.completed(Xe.fromRight(Ze))(K._2),Ma=null,Oa++;break;case U:Oa++,In=new ne(w,new ne(V,Ze,Ma),In,Ja),On=An,Ze=K._1;break;case V:Oa--,On=da,Ze=K._1,Ma=K._2;break}break;case Dt:for(var ve in za)za.hasOwnProperty(ve)&&(jt=jt&&za[ve].rethrow,me(za[ve].handler(Ze)));za=null,Ja&&Ma?setTimeout(function(){throw Xe.fromLeft(Ma)},0):Xe.isLeft(Ze)&&jt&&setTimeout(function(){if(jt)throw Xe.fromLeft(Ze)},0);return;case Mn:On=An;break;case Da:return}}function X(P){return function(){if(On===Dt)return jt=jt&&P.rethrow,P.handler(Ze)(),function(){};var O=dr++;return za=za||{},za[O]=P,function(){za!==null&&delete za[O]}}}function k(P,O){return function(){if(On===Dt)return O(Xe.right(void 0))(),function(){};var j=X({rethrow:!1,handler:function(){return O(Xe.right(void 0))}})();switch(On){case Mn:Ja=Xe.left(P),On=Dt,Ze=Ja,W(zn);break;case Da:Ja===null&&(Ja=Xe.left(P)),Oa===0&&(On===Da&&(In=new ne(w,new ne(U,Ze(P)),In,Ja)),On=da,Ze=null,Ma=null,W(++zn));break;default:Ja===null&&(Ja=Xe.left(P)),Oa===0&&(On=da,Ze=null,Ma=null)}return j}}function S(P){return function(){var O=X({rethrow:!1,handler:P})();return On===Mn&&W(zn),O}}return{kill:k,join:S,onComplete:X,isSuspended:function(){return On===Mn},run:function(){On===Mn&&(dn.isDraining()?W(zn):dn.enqueue(function(){W(zn)}))}}}function Ha(Xe,Wa,Mt,zn){var On=0,Ze={},Ma=0,Ja={},pt=new Error("[ParAff] Early exit"),tr=null,In=e;function Oa(X,k,S){var P=k,O=null,j=null,K=0,ve={},ce,Ie;e:for(;;)switch(ce=null,P.tag){case Q:if(P._3===e&&(ce=Ze[P._1],ve[K++]=ce.kill(X,function(Ae){return function(){K--,K===0&&S(Ae)()}})),O===null)break e;P=O._2,j===null?O=null:(O=j._1,j=j._2);break;case p:P=P._2;break;case R:case E:O&&(j=new ne(w,O,j)),O=P,P=P._1;break}if(K===0)S(Xe.right(void 0))();else for(Ie=0,ce=K;Ie()=>e.props.def;function L6(e){class n extends vt.Component{constructor(t){super(t),t.init&&t.init(this)()}render(){return this.props.render(this)()}componentDidMount(){this.props.componentDidMount(this)()}componentWillUnmount(){this.props.componentWillUnmount(this)()}}return n.displayName=e?"Elmish_"+e:"ElmishRoot",n}var h1=typeof module>"u"?void 0:module.require,fVe=(function(){try{return h1===void 0?void 0:h1("util")}catch{return}})();var _Ve=(function(){var e;if(typeof performance<"u")e=performance;else if(h1)try{e=h1("perf_hooks").performance}catch{}return(function(){return(e||Date).now()})})();var P6=(e,n)=>n[e],N6=(e,n,a)=>a[e]=n;var Wd=function(n){return function(a){return n(a)()}};var Ap=function(n){return function(a){return function(){return n(a)}}},$_=function(n){return function(a){return function(t){return function(){return n(a,t)}}}},Lp=function(n){return function(a){return function(t){return function(r){return function(){return n(a,t,r)}}}}};var bse=ge(ca),WD=(function(){function e(){}return e.value=new e,e})(),k6=function(){return function(e){var n=Vt(e);return function(a){return Lp(N6)(n(lt.value))}}},YG=function(e){var n=sr(e);return function(a){var t=Vt(a);return function(r){return function(u){return bse(function(){return P6(t(lt.value),u)})(n)}}}};Et();var oc=window.ReactDOM,{createPortal:B6,findDOMNode:RVe,flushSync:yVe,unstable_batchedUpdates:wVe}=window.ReactDOM;var fM=pl(_U(),1);function pU(e){return e.state&&e.state.s}function mU(e,n,a){return e.setState({s:n},a)}function dU(e,n){return e.state={s:n}}var hU=oc.render,gU=oc.hydrate,_M=fM.default&&fM.default.renderToString||(e=>""),Kse=oc.unmountComponentAtNode,DU=vt.Fragment;function RU(e,n,a){return vt.createElement.apply(null,[e,Yse(e,n)].concat(a))}function Yse(e,n){if(typeof e!="string"||n._data==null)return n;var a={_data:void 0};for(var t in n._data){var r=n._data[t];a["data-"+t]=r}return Object.assign({},n,a)}function yU(e){return n=>e===n}var E1=function(e){return function(n){return function(a){var t=he(a);if(e instanceof G&&t instanceof G)return void 0;if(e instanceof T&&t instanceof G)return void 0;if(e instanceof T&&t instanceof T){if(yU(e.value0)(t.value0))return void 0;if(Ve)return n(new T(t.value0))()}return n(t)()}}};var ie={asReactChildren:function(e){return[e]}},on={asReactChildren:function(e){return[e]}},Se={asReactChildren:hn(En)};var cn=Ke,pM=Lp(mU),wU=$_(hU),bU=$_(gU),EU=Ap(pU),Aa=!1;var IU=$_(dU),KD=function(e){return e.asReactChildren},uc=function(){return function(e){var n=KD(e);return function(a){return function(t){return function(r){return RU(a,t,n(r))}}}}},TU=uc()(Se),wv=function(){return function(e){return function(n){return TU(e)(n)([])}}},Oe=TU(DU)({});var mM=B(ca),nve=x(Nt),SU=function(e){return{initialize:function(n){return IU(n)(e.initialState)},getState:function(n){return function(){var t=mM(he)(EU(n))();return je(e.initialState)(t)}},setState:pM}},CU=(function(){var e=function(n){return function(a){return{initialize:function(t){return ep(new T(a.initialState))(n)},getState:function(t){return mM(je(a.initialState))(Z0(n))},setState:function(t){return function(r){return function(u){return function(){return ep(new T(r))(n)(),pM(t)(r)(nve(void 0))(),u()}}}}}}};return mM(e)(vd(G.value))})();var MU=ge(Ye),AU=tn(gr);var tve=x(Nt),LU=k6(),PU={reflectSymbol:function(){return"__unmounted"}},rve=LU(PU),NU={reflectSymbol:function(){return"__subscriptions"}},ove=LU(NU),I1=ge(ca),uve=YG(ct)(PU),FU=B(ca),ive=YG(ht(bO))(NU),lve=fn(ln),cve=tt(uo),sve=Db(Nt)(Je),vve=lve(Na),OU=Hn(Go),fve=od(iv),_ve=tn(__(xF(tb))),dM=function(e){return e},j_=(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})(),pve={map:function(e){return function(n){return new j_(e(n.value0),n.value1)}}},Lo=function(e){return{bimap:function(n){return function(a){return function(t){return new j_(a(t.value0),MU(t.value1)(function(r){return function(u){return r({dispatch:function(i){return u.dispatch(n(i))},onStop:u.onStop})}}))}}}}},UU={apply:function(e){return function(n){return new j_(e.value0(n.value0),AU(e.value1)(n.value1))}},Functor0:function(){return pve}},ma={bind:function(e){return function(n){var a=n(e.value0);return new j_(a.value0,AU(e.value1)(a.value1))}},Apply0:function(){return UU}},Un={pure:function(e){return new j_(e,[])},Apply0:function(){return UU}};var kU=function(e){var n=ae(e);return function(a){var t=Hn(a);return function(r){return function(u){return new j_(r,MU(u)(function(i){return function(l){return n(i)(function(s){return t(l.dispatch(s))})}}))}}}};var Up=function(e){return new j_(void 0,[e])},Bt=function(e){return Up(gn(e))},z_=function(e){var n=ae(e.Monad0().Bind1()),a=Hn(e);return function(t){return Up(function(r){return n(t)(function(u){return a(Wn(tve(void 0))(r.dispatch)(u))})})}},nt=function(e){var n=kU(e.Monad0().Bind1())(e);return function(a){return n(void 0)([a])}},BU=function(e){return function(n){var a=rve(WD.value),t=ove(WD.value),r=function(w){return function(I){return function(L){return function(){var V=I1(qD(w))(function(Q){return Q.init})();return n({initialState:V.value0}).setState(w)(I)(L)()}}}},u=(function(){var w=FU(je(!1)),I=uve(WD.value);return function(L){return w(I(L))}})(),i=(function(){var w=FU(je([])),I=ive(WD.value);return function(L){return w(I(L))}})(),l=function(w){return function(){return cve(sve)(i(w))(),t([])(w)()}},s=function(w){return function(){var L=I1(qD(w))(function(U){return U.init})();return n({initialState:L.value0}).getState(w)()}},h=function(w){return function(I){return function(){var U=i(w)();return t(wu(Jd(I))(U))(w)()}}},p=function(w){return function(I){var L=function(U){return Jd(vve(Wr(0))(function(){return U({dispatch:(function(){var V=R(I);return function(Q){return OU(V(Q))}})(),onStop:h(I)})}))};return $F(w)(L)}},R=function(w){return function(I){return fve(u(w))(function(){var U=s(w)(),V=I1(qD(w))(function(te){return te.update})(),Q=V(U)(I);return r(w)(Q.value0)(p(Q.value1)(w))()})}},E=function(w){return function(){var L=s(w)(),U=I1(qD(w))(function(V){return V.view})();return U(L)(R(w))}};return function(w){return A6(e,{def:w,init:n({initialState:w.init.value0}).initialize,render:E,componentDidMount:p(w.init.value1),componentWillUnmount:_ve(a(!0))(l)})}}},hM=function(e){return function(){var a=OU(CU)();return M6(function(t){return BU(t)(a)(e)})}},Af=function(e){return function(n){return G6(e,function(a){var t=BU(a)(SU);return function(r){return t(n(r))}})}};function YD(e,n){var a={};for(var t in n)({}).hasOwnProperty.call(n,t)&&(a[t]=n[t]);for(var r in e)({}).hasOwnProperty.call(e,r)&&(a[r]=e[r]);return a}var Ps=function(){return function(){return function(e){return function(n){return YD(e,n)}}}};var T1=function(e){var n=Vt(e);return function(){return function(){return function(a){return function(t){return ab(n(a))(t)}}}}};var JU=wv(),gM=uc(),qU=Ps()();var XD=Ke;var DM=function(e){var n=gM(e);return function(a){return function(t){return n(XD(a))(t)}}},Os=function(e){var n=gM(e);return function(a){return function(t){return function(r){return n(XD(a))(qU(r)({className:t}))}}}},ZD=function(e){return function(n){return function(a){return JU(XD(e))(qU(a)({className:n}))}}},RM=function(e){return function(n){return JU(XD(e))({className:n})}},Xo=function(e){return function(n){var a=gM(n);return function(t){return function(r){return a(XD(e))({className:t})(r)}}}};var Yt=Ke;var jd=function(e){var n=Os(e);return function(){return function(){return n("video")}}},S1=function(e){return Xo("video")(e)};var C1=function(e){return Xo("ul")(e)};var Lf=function(e){return Xo("tr")(e)};var V_=function(e){return Xo("thead")(e)};var Q_=function(e){return Xo("th")(e)};var zd=function(){return function(){return ZD("textarea")}};var F1=function(e){var n=Os(e);return function(){return function(){return n("td")}}},Us=function(e){return Xo("td")(e)};var K_=function(e){return Xo("tbody")(e)};var Y_=function(e){return Xo("table")(e)};var qu=function(e){return Xo("strong")(e)},Vd=function(e){var n=Os(e);return function(){return function(){return n("span")}}},Ct=function(e){return Xo("span")(e)},G1=function(){return function(){return ZD("source")}};var M1=function(e){var n=Os(e);return function(){return function(){return n("select")}}};var Qd=function(e){var n=Os(e);return function(){return function(){return n("p")}}},xr=function(e){return Xo("p")(e)};var A1=function(e){var n=Os(e);return function(){return function(){return n("option")}}};var L1=function(e){return Xo("li")(e)};var X_=function(e){return Xo("label")(e)};var su=function(){return function(){return ZD("input")}};var jc=function(){return function(){return ZD("img")}};var Ht=function(e){return Xo("i")(e)};var ks=RM("hr");var Kd=function(e){return Xo("h6")(e)};var zc=function(e){return Xo("h4")(e)},P1=function(e){var n=Os(e);return function(){return function(){return n("h3")}}},vu=function(e){return Xo("h3")(e)},bv=function(e){var n=Os(e);return function(){return function(){return n("h2")}}},jr=function(e){return Xo("h2")(e)};var Z_=function(e){return Xo("h1")(e)},e0=function(e){var n=Os(e);return function(){return function(){return n("form")}}};var zr=function(e){var n=Os(e);return function(){return function(){return n("div")}}},Pe=function(e){return Xo("div")(e)};var N1=RM("br");var $U=Bd(ND);var dve=x(Nt);var yM={map:function(e){return function(n){return $U($U(e))(n)}}},WU=ge(yM),xU=function(e){var n=ae(e.Monad0().Bind1()),a=Hn(e);return function(t){return Up(function(r){return n(t(r.dispatch))(function(u){return a(r.onStop(u))})})}},Gi=function(e){var n=xU(e);return function(a){return function(t){return n(WU(t)(a))}}};var jU=function(e){return function(n){return e(Wn(dve(void 0))(n))}},Yd=function(e){var n=xU(e);return function(a){return function(t){return n(jU(WU(t)(a)))}}};var Xn=(function(){return{"genericTop'":xe.value}})();var wM=function(e){return e["genericTop'"]},Zn=function(e){return{"genericTop'":wM(e)}};var ea=(function(){return{"genericBottom'":xe.value}})();var eR=function(e){return e["genericBottom'"]},na=function(e){return{"genericBottom'":eR(e)}};var aa=function(e){return{"genericBottom'":new Te(eR(e))}},zU=function(e){var n=ld(e);return function(a){return n(eR(a))}};var n0=B(ue),O1=ut();var bM=function(e){return e["genericToEnum'"]};var U1=function(e){return e["genericSucc'"]},SM=function(e){var n=ld(e),a=cd(e);return function(t){var r=n0(n),u=U1(t);return function(i){return r(u(a(i)))}}},EM=function(e){return e["genericPred'"]};var IM=function(e){return e["genericFromEnum'"]};var ta=function(e){var n=EM(e),a=U1(e);return function(t){var r=wM(t);return function(u){var i=EM(u),l=U1(u);return function(s){var h=eR(s);return{"genericPred'":function(p){if(p instanceof Te)return n0(Te.create)(n(p.value0));if(p instanceof fe){var R=i(p.value0);if(R instanceof G)return new T(new Te(r));if(R instanceof T)return new T(new fe(R.value0));throw new Error("Failed pattern match at Data.Enum.Generic (line 30, column 14 - line 32, column 31): "+[R.constructor.name])}throw new Error("Failed pattern match at Data.Enum.Generic (line 28, column 18 - line 32, column 31): "+[p.constructor.name])},"genericSucc'":function(p){if(p instanceof Te){var R=a(p.value0);if(R instanceof G)return new T(new fe(h));if(R instanceof T)return new T(new Te(R.value0));throw new Error("Failed pattern match at Data.Enum.Generic (line 34, column 14 - line 36, column 31): "+[R.constructor.name])}if(p instanceof fe)return n0(fe.create)(l(p.value0));throw new Error("Failed pattern match at Data.Enum.Generic (line 33, column 18 - line 37, column 36): "+[p.constructor.name])}}}}}};var ra={"genericPred'":function(e){return G.value},"genericSucc'":function(e){return G.value}},oa=function(e){var n=EM(e),a=U1(e);return{"genericPred'":function(t){return n0($g)(n(t))},"genericSucc'":function(t){return n0($g)(a(t))}}};var TM=function(e){return e["genericCardinality'"]};var ua=function(e){var n=TM(e),a=bM(e),t=IM(e);return function(r){var u=bM(r),i=IM(r);return{"genericCardinality'":O1(n)+O1(TM(r))|0,"genericToEnum'":function(l){var s=function(h){if(l>=0&&lt.value0;return r?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 708, column 5 - line 712, column 68): "+[t.constructor.name])}throw new Error("Failed pattern match at Data.Map.Internal (line 700, column 32 - line 712, column 68): "+[a.constructor.name])};var B1=function(e){return function(n){return new ci(1,1,e,n,Qc.value,Qc.value)}},t5=(function(){var e=function(t){if(t instanceof Qc)return 0;if(t instanceof ci)return t.value0;throw new Error("Failed pattern match at Data.Map.Internal (line 757, column 12 - line 759, column 26): "+[t.constructor.name])},n=function(t,r,u,i,l,s,h){return s instanceof ci&&s.value0>e(h)?Vc(s.value2,s.value3,Vc(t,r,u,s.value4),Vc(i,l,s.value5,h)):Vc(i,l,Vc(t,r,u,s),h)},a=function(t,r,u,i,l,s,h){return s instanceof ci&&e(l)<=s.value0?Vc(s.value2,s.value3,Vc(u,i,l,s.value4),Vc(t,r,s.value5,h)):Vc(u,i,l,Vc(t,r,s,h))};return function(t,r,u,i){if(u instanceof Qc)return i instanceof Qc?B1(t)(r):i instanceof ci&&i.value0>1?n(t,r,u,i.value2,i.value3,i.value4,i.value5):Vc(t,r,u,i);if(u instanceof ci){if(i instanceof ci){if(i.value0>(u.value0+1|0))return n(t,r,u,i.value2,i.value3,i.value4,i.value5);if(u.value0>(i.value0+1|0))return a(t,r,u.value2,u.value3,u.value4,u.value5,i)}return i instanceof Qc&&u.value0>1?a(t,r,u.value2,u.value3,u.value4,u.value5,i):Vc(t,r,u,i)}throw new Error("Failed pattern match at Data.Map.Internal (line 717, column 40 - line 738, column 34): "+[u.constructor.name])}})();var Bs=function(e){var n=We(e);return function(a){var t=function(r){var u=!1,i;function l(s){if(s instanceof Qc)return u=!0,G.value;if(s instanceof ci){var h=n(a)(s.value2);if(h instanceof ye){r=s.value4;return}if(h instanceof De){r=s.value5;return}if(h instanceof Be)return u=!0,new T(s.value3);throw new Error("Failed pattern match at Data.Map.Internal (line 283, column 7 - line 286, column 22): "+[h.constructor.name])}throw new Error("Failed pattern match at Data.Map.Internal (line 280, column 8 - line 286, column 22): "+[s.constructor.name])}for(;!u;)i=l(r);return i};return t}};var Xd=function(e){var n=We(e);return function(a){return function(t){var r=function(u){if(u instanceof Qc)return B1(a)(t);if(u instanceof ci){var i=n(a)(u.value2);if(i instanceof ye)return t5(u.value2,u.value3,r(u.value4),u.value5);if(i instanceof De)return t5(u.value2,u.value3,u.value4,r(u.value5));if(i instanceof Be)return new ci(u.value0,u.value1,a,t,u.value4,u.value5);throw new Error("Failed pattern match at Data.Map.Internal (line 471, column 7 - line 474, column 35): "+[i.constructor.name])}throw new Error("Failed pattern match at Data.Map.Internal (line 468, column 8 - line 474, column 35): "+[u.constructor.name])};return r}}};var ic=(function(){return Qc.value})(),si=function(e){var n=Xd(e);return function(a){return Zt(a)(function(t){return function(r){return n(r.value0)(r.value1)(t)}})(ic)}};var Yve=typeof Array.from=="function",i5=typeof Symbol<"u"&&Symbol!=null&&typeof Symbol.iterator<"u"&&typeof String.prototype[Symbol.iterator]=="function",Xve=typeof String.prototype.fromCodePoint=="function",Zve=typeof String.prototype.codePointAt=="function",l5=function(e){return Zve?function(n){return n.codePointAt(0)}:e},c5=function(e){return function(n){return function(a){return function(t){return function(r){return function(u){var i=u.length;if(r<0||r>=i)return a;if(i5)for(var l=u[Symbol.iterator](),s=r;;--s){var h=l.next();if(h.done)return a;if(s===0)return n(t(h.value))}return e(r)(u)}}}}}};var s5=function(e){return Xve?String.fromCodePoint:e},v5=function(e){return function(n){return i5?function(a){for(var t="",r=a[Symbol.iterator](),u=0;u1;if(a){var t=rR(Df(1)(e)),r=m5(t);return r?p5(n)(t):n}return n},OM=l5(vfe),Hp=f5(sfe)(OM),bu=function(e){return Wo(Hp(e))};var H1=function(e){return function(n){return _5(function(a){return bu(Cd(a)(n))})(jb(e)(n))}},NM=(function(){var e=AG(Sp)(Ut(g_))(Cr(g_));return function(n){return Vi(e(n))}})(),ffe=function(e){if(e<=65535)return NM(e);var n=ufe(e-65536|0)(1024)+55296|0,a=ife(e-65536|0)(1024)+56320|0;return NM(n)+NM(a)};var nh=s5(ffe),h5=function(e){return function(n){if(e<1)return"";var a=t0(n);return a instanceof T?nh(a.value0.head)+h5(e-1|0)(a.value0.tail):n}},rl=v5(h5);var J1={eq:function(e){return function(n){return e===n}}},q1={compare:function(e){return function(n){return lfe(e)(n)}},Eq0:function(){return J1}},Nf=function(e){return function(n){return mv(Uc(rl(e)(n)))(n)}};var _fe=function(e){return function(n){var a=e,t=!1,r;function u(i,l){var s=t0(l);if(s instanceof T){var h=i===0;if(h)return t=!0,new T(s.value0.head);a=i-1|0,n=s.value0.tail;return}return t=!0,G.value}for(;!t;)r=u(a,n);return r}},ah=function(e){return function(n){return e<0?G.value:e===0&&n===""?G.value:e===0?new T(OM(n)):c5(_fe)(T.create)(G.value)(OM)(e)(n)}},pfe={bottom:0,top:1114111,Ord0:function(){return q1}},Tv=(function(){return{cardinality:1114112,fromEnum:function(e){return e},toEnum:function(e){if(e>=0&&e<=1114111)return new T(e);if(Ve)return G.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 pfe},Enum1:function(){return mfe(0)}}})(),mfe=rfe("enumCodePoint","Data.String.CodePoints",function(){return{succ:Ip(Fa(Tv))(Yn(Tv)),pred:Tp(Fa(Tv))(Yn(Tv)),Ord0:function(){return q1}}});var Mfe=ut();var F5={show:Mfe};var G5=be;var Lfe=bf(Je),Pfe=ge(Ye),Nfe=vp(GM),Vn=function(e){return function(n){var a=Lfe(Pfe(n)(function(t){return new yn(e(t),t)}));return function(t){return Fs(t)(a)}}},M5=function(e){var n=SM(e),a=zU(e);return function(t){var r=n(t);return function(u){return function(i){return Nfe(function(l){return new yn(l,r(l))})(a(i))}}}},Qn=function(e){var n=M5(e);return function(a){var t=n(a);return function(r){var u=t(r);return function(i){return Ev(u(i))}}}};var Ofe={info:"info",warning:"warn",error:"error"},cc=e=>n=>a=>t=>{let r=Ofe[e];if(typeof console<"u"&&console[r]&&console[r](n,a),typeof window<"u"){let u=new Error(n);typeof window.Sentry<"u"&&window.Sentry.captureException(u,{extra:a})}return t()},A5=(e,n)=>(n.__sentryFingerprint=e,n);var L5=function(e){return Nc(A5)(e)};var Kc="error";var j1={parseOrPanic:function(e){return function(n){var a=e.parse(n);if(a instanceof Le)return a.value0;if(a instanceof Me)return cc(Kc)("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])}}},Ga=function(e){return e.parseOrPanic},kfe=Ga(j1),It=function(e){var n=Ga(e);return function(a){var t=B(a);return function(r){return n({parse:function(u){return t(T.create)(r.parse(u))},default:G.value,diagnosticName:r.diagnosticName})}}},Bfe=It(j1)(eo),o0=function(e){var n=O_(e);return function(a){return Bfe({parse:n,diagnosticName:a})}},sn={parseOrPanic:function(e){return kfe({default:e.default,diagnosticName:e.diagnosticName,parse:(function(){var n=Wn(new Me(""))(Le.create);return function(a){return n(e.parse(a))}})()})}};var P5=oa(ra),N5=na(ea),O5=la(ia),Uf=(function(){function e(){}return e.value=new e,e})(),kf=(function(){function e(){}return e.value=new e,e})(),Hfe={to:function(e){if(e instanceof Te)return Uf.value;if(e instanceof fe)return kf.value;throw new Error("Failed pattern match at Sem.Connections.Types.Actor (line 17, column 1 - line 17, column 32): "+[e.constructor.name])},from:function(e){if(e instanceof Uf)return new Te(xe.value);if(e instanceof kf)return new fe(xe.value);throw new Error("Failed pattern match at Sem.Connections.Types.Actor (line 17, column 1 - line 17, column 32): "+[e.constructor.name])}};var Jfe=function(e){if(e instanceof Uf)return"school";if(e instanceof kf)return"vine";throw new Error("Failed pattern match at Sem.Connections.Types.Actor (line 28, column 1 - line 28, column 29): "+[e.constructor.name])},z1=(function(){return Ga(sn)({parse:Vn(Jfe)(Qn(Hfe)(ta(P5)(Zn(Xn))(P5)(N5))(ua(O5)(O5))(aa(N5))),default:Uf.value,diagnosticName:"Sem.Connections.Types.Actor"})})();var H5=oa(ra),U5=ta(H5)(Zn(Xn)),J5=na(ea),k5=aa(J5),q5=la(ia),B5=ua(q5),qfe=La(du),Hs=(function(){function e(){}return e.value=new e,e})(),u0=(function(){function e(){}return e.value=new e,e})(),Bf=(function(){function e(){}return e.value=new e,e})(),$fe={to:function(e){if(e instanceof Te)return Hs.value;if(e instanceof fe&&e.value0 instanceof Te)return u0.value;if(e instanceof fe&&e.value0 instanceof fe)return Bf.value;throw new Error("Failed pattern match at Sem.Connections.Types.Status (line 18, column 1 - line 18, column 33): "+[e.constructor.name])},from:function(e){if(e instanceof Hs)return new Te(xe.value);if(e instanceof u0)return new fe(new Te(xe.value));if(e instanceof Bf)return new fe(new fe(xe.value));throw new Error("Failed pattern match at Sem.Connections.Types.Status (line 18, column 1 - line 18, column 33): "+[e.constructor.name])}};var Wfe=function(e){if(e instanceof Hs)return"pending";if(e instanceof u0)return"connected";if(e instanceof Bf)return"ignored";throw new Error("Failed pattern match at Sem.Connections.Types.Status (line 35, column 1 - line 35, column 30): "+[e.constructor.name])},BM=(function(){var e=Vn(Wfe)(Qn($fe)(U5(U5(H5)(J5))(k5))(B5(B5(q5)))(k5)),n=function(a){return a==="cold"?new T(Bf.value):G.value};return Ga(sn)({parse:function(a){return qfe(e(a))(n(a))},default:Hs.value,diagnosticName:"Sem.Connections.Types.Status"})})();var xfe=dd(cr),$5=oe(pn),jfe=yo(Je)(cr),zfe=Ct(ie);var W5=function(e){return{initiator:z1(e.initiator),status:BM(e.status),introMessage:je("")(he(e.introMessage))}},x5=25,HM=function(e){return bu(e)>=x5},j5=function(e){var n=bu(e),a=n>0,t=xfe(" ")([(function(){return a?$5(n)+" characters":""})(),jfe(["(",$5(x5),(function(){return a?"":" character"})()," minimum)"])]),r=(function(){var u=HM(e);return u?"text-success":""})();return zfe(r)(t)};var K1=(function(){function e(){}return e.value=new e,e})(),V5=(function(){function e(){}return e.value=new e,e})();var Q5=(function(){var e=Ga(sn)({parse:function(n){return n instanceof T&&n.value0==="paid"?new T(V5.value):n instanceof T&&n.value0==="free"?new T(K1.value):n instanceof T&&n.value0==="churned"?new T(K1.value):n instanceof G?new T(K1.value):G.value},default:K1.value,diagnosticName:"Sem.Types.PartnerStatus"});return function(n){return e(he(n))}})();var K5=function(e){return{allowedToContact:e.allowedToContact,id:e.id,name:e.name,imageUrl:he(e.imageUrl),partnerStatus:Q5(e.partnerStatus)}};var Kfe=ae(nn),JM=dt(),uR=kt(be),Y5=$({reflectSymbol:function(){return"id"}}),Yfe=fn(ln)(nn),Xfe=Qo(hu),Zfe=B(ue);var e_e=(function(){function e(){}return e.value=new e,e})(),n_e=(function(){function e(){}return e.value=new e,e})(),a_e=(function(){function e(){}return e.value=new e,e})(),qM=(function(){function e(){}return e.value=new e,e})(),t_e=(function(){function e(){}return e.value=new e,e})(),Y1=(function(){function e(){}return e.value=new e,e})(),iR=(function(){function e(){}return e.value=new e,e})(),$M=(function(){function e(){}return e.value=new e,e})(),WM=(function(){function e(){}return e.value=new e,e})();var X5={show:ut()};var r_e=be,o_e=o0(JM($({reflectSymbol:function(){return"avatarUrl"}})(uR)($({reflectSymbol:function(){return"bio"}})(uR)($({reflectSymbol:function(){return"connection"}})(kt(JM($({reflectSymbol:function(){return"initiator"}})(be)($({reflectSymbol:function(){return"introMessage"}})(uR)($({reflectSymbol:function(){return"status"}})(be)(mn))))))($({reflectSymbol:function(){return"firstName"}})(be)(Y5(r_e)($({reflectSymbol:function(){return"lastName"}})(be)($({reflectSymbol:function(){return"school"}})(JM($({reflectSymbol:function(){return"allowedToContact"}})(ct)(Y5(G5)($({reflectSymbol:function(){return"imageUrl"}})(uR)($({reflectSymbol:function(){return"name"}})(be)($({reflectSymbol:function(){return"partnerStatus"}})(uR)(mn)))))))($({reflectSymbol:function(){return"title"}})(be)($({reflectSymbol:function(){return"type"}})(be)($({reflectSymbol:function(){return"unreadMessageCountFromSemUser"}})(Dn)(mn))))))))))));var Z5=function(e){if(e instanceof e_e)return"sheet-view";if(e instanceof n_e)return"school-details";if(e instanceof a_e)return"network-gallery";if(e instanceof qM)return"livestream-details";if(e instanceof t_e)return"card-view";throw new Error("Failed pattern match at Sem.Types.User (line 102, column 25 - line 107, column 26): "+[e.constructor.name])},e9=function(e){return Kfe(o_e("SemUser")(e))(function(n){return Yfe(Xfe(n.type==="Sem::User"))(function(){return new T({school:K5(n.school),firstName:n.firstName,lastName:n.lastName,avatarUrl:he(n.avatarUrl),title:n.title,bio:he(n.bio),connection:Zfe(W5)(he(n.connection)),unreadMessageCountFromSemUser:n.unreadMessageCountFromSemUser,id:n.id})})})};var Sv=function(e){var n=null;return function(){return e===void 0||(n=e(),e=void 0),n}},Cv=function(e){return e()};var _9=(function(){function e(){}return e.value=new e,e})(),p9=(function(){function e(){}return e.value=new e,e})(),m9=(function(){function e(){}return e.value=new e,e})();var A_e=function(e){if(e instanceof _9)return"disabled";if(e instanceof p9)return"free-consultation";if(e instanceof m9)return"more-information";throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types.InquiryMode (line 26, column 13 - line 29, column 40): "+[e.constructor.name])};var L_e=(function(){return[_9.value,p9.value,m9.value]})(),d9=It(sn)(ue)({parse:Vn(A_e)(L_e),diagnosticName:"InquiryMode"});var N_e=function(e,n,a,t,r,u,i){var l=new Date(Date.UTC(e,n,a,t,r,u,i));return e>=0&&e<100&&l.setUTCFullYear(e),l};function h9(e,n,a,t,r,u,i){return N_e(e,n-1,a,t,r,u,i).getTime()}function g9(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 U_e=lr(),k_e=Fa(go);var B_e=Yn(go);var D9=function(e){return e},eE=(function(){var e=function(n){return function(a){return function(t){return function(r){return function(u){return function(i){return function(l){return new xc(B_(n)(U_e(k_e(a)))(t),new gv(r,u,i,l))}}}}}}};return g9(e)})();var R9=function(e){return h9(Cl(e.value0),B_e(Fl(e.value0)),hv(e.value0),Ms(e.value1),Dv(e.value1),Sf(e.value1),Wc(e.value1))};var y9=function(e){var n=tn(e.Semigroup0()),a=function(t){return function(r){return function(u){var i=t,l=r,s=!1,h;function p(R,E,w){if(w<1)return s=!0,R;i=n(R)(E),l=E,u=w-1|0}for(;!s;)h=p(i,l,u);return h}}};return a(Ft(e))};var H_e=ut();var qp=(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})(),sR=(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 w9=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),b9=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ZM=(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 rh={defer:function(e){var n=Sv(e);return function(a,t,r,u,i){var l=Cv(n);return l(a,t,r,u,i)}}};var Fv={map:function(e){return function(n){return function(a,t,r,u,i){return t(function(l){return n(a,t,r,u,function(s,h){return t(function(p){return i(s,e(h))})})})}}}};var Gv={apply:function(e){return function(n){return function(a,t,r,u,i){return t(function(l){return e(a,t,r,u,function(s,h){return t(function(p){return n(s,t,r,u,function(R,E){return t(function(w){return i(R,h(E))})})})})})}}},Functor0:function(){return Fv}};var Mv={bind:function(e){return function(n){return function(a,t,r,u,i){return t(function(l){return e(a,t,r,u,function(s,h){return t(function(p){var R=n(h);return R(s,t,r,u,i)})})})}}},Apply0:function(){return Gv}},J_e=tt(Mv);var Yc={pure:function(e){return function(n,a,t,r,u){return u(n,e)}},Apply0:function(){return Gv}};var q_e={Applicative0:function(){return Yc},Bind1:function(){return Mv}};var E9={throwError:function(e){return function(n,a,t,r,u){return r(n,e)}},Monad0:function(){return q_e}},$_e=wo(E9);var $p={alt:function(e){return function(n){return function(a,t,r,u,i){return t(function(l){return e(new qp(a.value0,a.value1,!1),t,r,function(s,h){return t(function(p){return s.value2?u(s,h):n(a,t,r,u,i)})},i)})}}},Functor0:function(){return Fv}},W_e=function(e){return function(n,a,t,r,u){var i=e(n);return u(i.value1,i.value0)}};var x_e=function(e){var n=e.Monad0(),a=B(n.Bind1().Apply0().Functor0()),t=x(n.Applicative0()),r=ni(e);return function(u){return function(i){var l=function(s){var h=!1,p;function R(E){var w=E(void 0);if(w instanceof w9){s=w.value0;return}if(w instanceof b9)return h=!0,a(Kr.create)(w.value0);if(w instanceof ZM)return h=!0,t(new $r(new yn(w.value1,w.value0)));throw new Error("Failed pattern match at Parsing (line 152, column 13 - line 158, column 32): "+[w.constructor.name])}for(;!h;)p=R(s);return p};return r(l)(function(s){return i(u,w9.create,b9.create,function(h,p){return new ZM(h,new Me(p))},function(h,p){return new ZM(h,new Le(p))})})}}};var I9=W_e(function(e){return new yn(e.value1,e)}),eA=function(e){return e.value1},nA=function(e){return e.value0};var j_e={index:0,line:1,column:1},T9=function(e){var n=B(e.Monad0().Bind1().Apply0().Functor0()),a=x_e(e);return function(t){return function(r){var u=new qp(t,j_e,!1);return n(jo)(a(u)(r))}}},z_e=T9(xg),S9=function(e){var n=z_e(e);return function(a){return H_e(n(a))}};var V_e=function(e){return function(n){return $_e(new sR(e,n))}},oh=function(e){return J_e(V_e(e))(I9)};var C9={empty:oh("No alternative"),Alt0:function(){return $p}},Wp={Applicative0:function(){return Yc},Plus1:function(){return C9}};var r0e=La($p);var o0e=x(Yc);var u0e=B(Fv);var Av=function(e){return function(n,a,t,r,u){return e(n,a,t,function(i,l){return r(new qp(i.value0,i.value1,n.value2),l)},u)}};var nE=function(e){return function(n){return r0e(n)(o0e(e))}},xp=function(e){return nE(G.value)(u0e(T.create)(e))};var M9=Yn(Tv),s0e=gu(ho);var v0e=oe(ir);var A9=function(e){return function(n){return function(a){var t=M9(n);if(t===10)return{index:e.index+1|0,line:e.line+1|0,column:1};if(t===13){var r=ah(0)(a);return r instanceof T&&M9(r.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)-s0e(e.column-1|0)(8)|0}:{index:e.index+1|0,line:e.line,column:e.column+1|0}}}},f0e=function(e){return function(n){return function(a){var t=e,r=n,u=!1,i;function l(s,h,p){var R=t0(h);if(R instanceof G)return u=!0,s;if(R instanceof T){var E=(function(){if(lc(R.value0.tail))return A9(s)(R.value0.head)(p);if(Ve)return A9(s)(R.value0.head)(R.value0.tail);throw new Error("Failed pattern match at Parsing.String (line 165, column 7 - line 167, column 52): ")})();t=E,r=R.value0.tail,a=p;return}throw new Error("Failed pattern match at Parsing.String (line 161, column 36 - line 168, column 38): "+[R.constructor.name])}for(;!u;)i=l(t,r,a);return i}}};var tA=yb(function(e){return function(n){return function(a){return function(t){return function(r){var u=lc(e.value0);return u?r(new qp(e.value0,e.value1,!0),void 0):t(e,new sR("Expected EOF",e.value1))}}}}}),P9=function(e){return yb(function(n){return function(a){return function(t){return function(r){return function(u){var i=e(n.value0);if(i instanceof Me)return r(n,new sR(i.value0,n.value1));if(i instanceof Le)return u(new qp(i.value0.remainder,f0e(n.value1)(i.value0.consumed)(i.value0.remainder),!lc(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 Lv=function(e){return P9(function(n){var a=bl(e)(n);return a instanceof T?new Le({value:e,consumed:e,remainder:a.value0}):new Me("Expected "+v0e(e))})};var N9=oe(pn),p0e=wr(Du),m0e=nd(Gv);var d0e=function(e){return"(line "+(N9(e.line)+(", col "+(N9(e.column)+")")))},h0e=function(e){return nA(e)+(" "+d0e(eA(e)))},rA=function(e){return function(n){return p0e(h0e)(S9(n)(m0e(e)(tA)))}};var rE=Fa(Sp);var vi=oe(pn);var M0e=Fo(Vo),A0e=M0e(cr);var L0e=cb(Ca)(tv);var iA=Yn(cu),P0e=oe(Yb),N0e=Yn(go),q9=Yn(Il),O0e=ut(),U0e=Yn(k_),$9=oe(NO),lA=Yn(tc),k0e=gu(ho),W9=Yn(ac),x9=Yn(nc),cA=Yn(al),j9=ou(ho);var Qp=(function(){function e(){}return e.value=new e,e})(),V9=(function(){function e(){}return e.value=new e,e})(),B0e=(function(){function e(){}return e.value=new e,e})(),Js=(function(){function e(){}return e.value=new e,e})(),iE=(function(){function e(){}return e.value=new e,e})(),Q9=(function(){function e(){}return e.value=new e,e})(),K9=(function(){function e(){}return e.value=new e,e})(),Xc=(function(){function e(){}return e.value=new e,e})(),H0e=(function(){function e(){}return e.value=new e,e})(),J0e=(function(){function e(){}return e.value=new e,e})(),qs=(function(){function e(){}return e.value=new e,e})(),q0e=(function(){function e(){}return e.value=new e,e})(),lE=(function(){function e(){}return e.value=new e,e})(),Zc=(function(){function e(){}return e.value=new e,e})(),es=(function(){function e(){}return e.value=new e,e})(),$0e=(function(){function e(){}return e.value=new e,e})(),Al=(function(){function e(){}return e.value=new e,e})(),W0e=(function(){function e(){}return e.value=new e,e})(),cE=(function(){function e(){}return e.value=new e,e})(),x0e=(function(){function e(){}return e.value=new e,e})(),j0e=(function(){function e(){}return e.value=new e,e})(),z0e=(function(){function e(){}return e.value=new e,e})(),ar=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})();var V0e=function(e){if(e instanceof Ei)return"Jan";if(e instanceof Qi)return"Feb";if(e instanceof Ii)return"Mar";if(e instanceof Ki)return"Apr";if(e instanceof Yi)return"May";if(e instanceof Ti)return"Jun";if(e instanceof Si)return"Jul";if(e instanceof Xi)return"Aug";if(e instanceof Zi)return"Sep";if(e instanceof el)return"Oct";if(e instanceof nl)return"Nov";if(e instanceof Tl)return"Dec";throw new Error("Failed pattern match at Data.Formatter.DateTime (line 489, column 19 - line 501, column 22): "+[e.constructor.name])};var c0=function(e){if(e<0)return"-"+c0(-e|0);if(e<10)return"0"+vi(e);if(Ve)return vi(e);throw new Error("Failed pattern match at Data.Formatter.DateTime (line 194, column 1 - line 194, column 32): "+[e.constructor.name])},Y9=function(e){if(e<0)return"-"+Y9(-e|0);if(e<10)return"000"+vi(e);if(e<100)return"00"+vi(e);if(e<1e3)return"0"+vi(e);if(Ve)return vi(e);throw new Error("Failed pattern match at Data.Formatter.DateTime (line 207, column 1 - line 207, column 35): "+[e.constructor.name])},X9=function(e){if(e<0)return"-"+X9(-e|0);if(e<10)return"00"+vi(e);if(e<100)return"0"+vi(e);if(Ve)return vi(e);throw new Error("Failed pattern match at Data.Formatter.DateTime (line 200, column 1 - line 200, column 32): "+[e.constructor.name])};var Q0e=function(e){var n=vi(L0e(e)),a=bu(n);return a===1?"0"+n:a===2?n:Nf(a-2|0)(n)};var K0e=function(e){var n=e===0;return n?12:e},Y0e=function(e){return function(n){if(n instanceof Qp)return Y9(iA(Cl(e.value0)));if(n instanceof V9)return Q0e(iA(Cl(e.value0)));if(n instanceof B0e)return vi(iA(Cl(e.value0)));if(n instanceof Js)return P0e(Fl(e.value0));if(n instanceof iE)return V0e(Fl(e.value0));if(n instanceof Q9)return c0(N0e(Fl(e.value0)));if(n instanceof K9)return c0(q9(hv(e.value0)));if(n instanceof Xc)return vi(q9(hv(e.value0)));if(n instanceof H0e)return vi(ku((function(t){return t/1e3})(O0e(D9(R9(e))))));if(n instanceof J0e)return vi(U0e(CD(e.value0)));if(n instanceof qs)return $9(CD(e.value0));if(n instanceof q0e)return rl(3)($9(CD(e.value0)));if(n instanceof lE)return c0(lA(Ms(e.value1)));if(n instanceof Zc)return c0(K0e(k0e(lA(Ms(e.value1)))(12)));if(n instanceof es){var a=lA(Ms(e.value1))>=12;return a?"PM":"AM"}if(n instanceof $0e)return vi(W9(Dv(e.value1)));if(n instanceof Al)return c0(W9(Dv(e.value1)));if(n instanceof W0e)return vi(x9(Sf(e.value1)));if(n instanceof cE)return c0(x9(Sf(e.value1)));if(n instanceof x0e)return X9(cA(Wc(e.value1)));if(n instanceof j0e)return vi((function(t){return j9(t)(100)})(cA(Wc(e.value1))));if(n instanceof z0e)return c0((function(t){return j9(t)(10)})(cA(Wc(e.value1))));if(n instanceof ar)return n.value0;throw new Error("Failed pattern match at Data.Formatter.DateTime (line 169, column 38 - line 192, column 21): "+[n.constructor.name])}},xu=function(e){return function(n){return A0e(Y0e(n))(e)}};var JZe=new Intl.NumberFormat("en-US",{notation:"compact",compactDisplay:"short",maximumFractionDigits:2});function sE(e){return Math.round(e).toString()}var ih=ae(Mv);var Z0e=x(Yc),epe=gd(Wp)(rh);var npe=vG(Wp)(rh),vE=y9(cr),ape=sp(Yc)(md),tpe=B(ue);var Z9=ys(Ca),rpe=ou(ho),ope=oe(pn),upe=ge(eo),ipe=oe(Y0),lpe=hn(En);var cpe=ih(xp(Av(Lv("+"))))(function(e){return ih(epe(Lv("0")))(function(n){return ih(xp(Av(Lv(",0"))))(function(a){return ih(xp(Av(Lv("."))))(function(t){return ih(ape(t)(function(r){return Av(npe(Lv("0")))}))(function(r){return ih(xp(Av(Lv("a"))))(function(u){return Z0e({sign:Fr(e),before:Wo(n),comma:Fr(a),after:je(0)(tpe(Wo)(r)),abbreviations:Fr(u)})})})})})})}),spe=rA(cpe);var ek=function(e){return function(n){var a=pG(n),t=(function(){if(a>0)return Z9(ku(mG(a)/H7))(0);if(Ve)return 0;throw new Error("Failed pattern match at Data.Formatter.Number (line 100, column 5 - line 102, column 22): ")})();if(e.abbreviations){var r=rpe(t)(3),u=(function(){var V=r<1;return V?n:n/Ab(1e3)(br(r))})(),i=(function(){if(r===0)return"";if(r===1)return"K";if(r===2)return"M";if(r===3)return"G";if(r===4)return"T";if(r===5)return"P";if(r===6)return"E";if(r===7)return"Z";if(r===8)return"Y";if(Ve)return"10e+"+ope(r*3|0);throw new Error("Failed pattern match at Data.Formatter.Number (line 107, column 7 - line 117, column 53): ")})();return ek({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=Ab(10)(br(Z9(0)(e.after))),h=hp(a*s)/s,p=yd(h),R=h-p,E=hp(R*s),w=(function(){var V=sE(E),Q=bu(V),te=vE("0")(e.after-Q|0);return te+V})(),I=(function(){var V=e.after<1;return V?"":"."+((function(){var Q=E===0;return Q?vE("0")(e.after):""})()+(function(){var Q=E>0;return Q?w:""})())})(),L=function(V){return function(Q){return function(te){var le=V,ne=Q,Z=!1,ee;function me($e,Qe,dn){var qn=_p(dn);if(qn instanceof G)return Z=!0,Sd($e);if(qn instanceof T&&Qe<3){le=wu(qn.value0.head)($e),ne=Qe+1|0,te=qn.value0.tail;return}le=wu(",")($e),ne=0,te=dn}for(;!Z;)ee=me(le,ne,te);return ee}}},U=(function(){return e.comma?L([])(0)(td(gD(vE("0")(l)+sE(p)))):vE("0")(l)+sE(p)})();return(function(){var V=n<0;if(V)return"-";var Q=n>0&&e.sign;return Q?"+":""})()+(U+I)}},vpe=function(e){return function(n){return upe(spe(e))(it(ek)(n))}},lh=function(e){return function(n){return yr(gn(ipe(n)))(lpe)(vpe(e)(n))}};var _pe=Ke;var nk=function(e){return G_(e)};var Ll=function(e){var n=nk(e);return n?G.value:new T(_pe(e))};var Za=function(e){return function(n){var a=nk(e);return a?n:e}};var eu=function(){return Ke};var fR=oe(pn),ppe=Yn(cu),mpe=Yn(go),dpe=eu(),hpe=yi(),gpe=Ml(Cp),sA=ou(ho),Dpe=Bu(Je);var Rpe=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 fR(n.minutes)+(" minutes"+e.suffix);if(n.hours<=1)return"an hour"+e.suffix;if(n.hours<24)return fR(n.hours)+(" hours"+e.suffix);if(n.days<=1)return"a day"+e.suffix;if(n.days<30)return fR(n.days)+(" days"+e.suffix);if(n.months<=1)return"a month"+e.suffix;if(n.months<12)return fR(n.months)+(" months"+e.suffix);if(n.years<=1)return"a year"+e.suffix;if(Ve)return fR(n.years)+(" years"+e.suffix);throw new Error("Failed pattern match at Utils.Format (line 158, column 1 - line 158, column 81): "+[e.constructor.name,n.constructor.name])}},_E=function(e){return Rpe({suffix:" "+e,justNow:"just now"})},ak=function(){return function(e){var n=function(h){return(ppe(Cl(Ff(h)))*12|0)+mpe(Fl(Ff(h)))|0},a=dpe(e),t=Za(a.format)(_E("ago")),r=hG(hpe(gpe(a.to)(a.from))),u=sA(r+30|0)(60),i=sA(u+12|0)(24),l=n(a.to)-n(a.from)|0,s=sA(l+6|0)(12);return t({minutes:r,hours:u,days:i,months:l,years:s})}};var tk=function(e){return function(n){return function(a){var t=e===1;return t?n:a}}};var vA=lh("0,0");var rk=function(e){return vA(br(e))},fc=function(e){return function(n){return function(a){return rk(e)+(" "+tk(e)(n)(a))}}};var ok=(function(){return xu(Dpe([qs.value,new ar(", "),Js.value,new ar(" "),Xc.value,new ar(" at "),Zc.value,new ar(":"),Al.value,new ar(" "),es.value]))})();Et();var uk=vt.Fragment,fA=()=>document.visibilityState=="visible",ik=(e,n)=>document.elementFromPoint(e,n);function lk(e){return function(n){return function(){return n.getElementById(e)}}}var bpe=B(ca),pE=function(e){var n=bpe(he),a=lk(e);return function(t){return n(a(t))}};var mE=function(e){return function(n){return function(){return n[e]}}},Epe=mE("children"),Ipe=mE("firstElementChild"),Tpe=mE("lastElementChild"),Spe=mE("childElementCount");var Mi=function(){return window};function sk(e,n,a,t){if(typeof window<"u"){var r=window[a];if(r!=null&&t instanceof r)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 Kn=function(e){return function(n){return sk(G.value,T.create,e,n)}};var vk=Ke;var dE=Ke;var fk=Ke;function _k(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 _A=Ke;var pk=function(e){return _k(G.value,T.create,e)};function mA(e){return function(){return e.seeking}}function _R(e){return function(){return e.currentTime}}function dA(e){return function(){return e.volume}}function hA(e){return function(n){return function(){n.volume=e}}}function gA(e){return function(){return e.muted}}function Yp(e){return function(n){return function(){n.muted=e}}}var dk=Kn("HTMLMediaElement");var hk=Kn("HTMLMediaElement");function RA(e){return function(){return e.hash}}function yA(e){return function(n){return function(){n.hash=e}}}function wA(e){return function(){return e.platform}}function s0(e){return function(){return e.document}}function bA(e){return function(){return e.navigator}}function pR(e){return function(){return e.location}}var Dk=Ke;var wme=B(Ye);var bme=sp(Nt)(md),Rk=ae(uo),wk=ge(ca),Eme=ae(nn);var TA=cn("\xA0");var ja=it(Wn(Aa));var bk=function(e){return function(n){if(e)return Aa;if(Ve)return n(void 0);throw new Error("Failed pattern match at Utils.HTML (line 113, column 1 - line 113, column 65): "+[e.constructor.name,n.constructor.name])}},SA=function(e){return function(n){return bk(e)(gn(n))}};var CA=function(e){return function(n){if(e)return n(void 0);if(Ve)return Aa;throw new Error("Failed pattern match at Utils.HTML (line 100, column 1 - line 100, column 61): "+[e.constructor.name,n.constructor.name])}},Qa=function(e){return function(n){return CA(e)(gn(n))}};var Ime=uc()(Se)(uk),Tme=function(e){return function(n){return Ime({key:e.key})(rD(N1(""))(wme(cn)(Wu(` `)(n))))}},sh=Tme({key:""}),DE=function(e){return bme(hk(e.target))(_R)};var Ek=function(e){return function(){return ik(e.x,e.y)}},Ik=function(e){return Rk(wk(Rk(Mi)(s0))(dE))(pE(e))},RE=function(e){return wk(Ik(e))(function(n){return Eme(n)(pk)})};var mR=Dn;var Sk=({just:e,nothing:n})=>a=>{try{let t=new Date(a);return isNaN(t.getTime())?n:e(t)}catch{return n}},FA=e=>({year:e.getFullYear(),month:e.getMonth(),day:e.getDate(),hour:e.getHours(),minute:e.getMinutes(),second:e.getSeconds(),millisecond:e.getMilliseconds()}),Ck=()=>new Date,Fk=(()=>{let e=new Date;return typeof window<"u"?()=>e:()=>{let n=new Date;return n-e>1e3&&(e=n),e}})();var Xp=(()=>{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:"")})();var Mk={liftAff:hn(En),MonadEffect0:function(){return qe}};var lhn=(function(){function e(){this.head=null,this.last=null,this.size=0}function n(p,R){this.queue=p,this.value=R,this.next=null,this.prev=null}function a(p){this.draining=!1,this.error=null,this.value=p,this.takes=new e,this.reads=new e,this.puts=new e}var t={};function r(p){try{p()}catch(R){setTimeout(function(){throw R},0)}}function u(p,R){var E=new n(p,R);switch(p.size){case 0:p.head=E;break;case 1:E.prev=p.head,p.head.next=E,p.last=E;break;default:E.prev=p.last,p.last.next=E,p.last=E}return p.size++,E}function i(p){var R;switch(p.size){case 0:return null;case 1:R=p.head,p.head=null;break;case 2:R=p.last,p.head.next=null,p.last=null;break;default:R=p.last,p.last=R.prev,p.last.next=null}return R.prev=null,R.queue=null,p.size--,R.value}function l(p){var R;switch(p.size){case 0:return null;case 1:R=p.head,p.head=null;break;case 2:R=p.head,p.last.prev=null,p.head=p.last,p.last=null;break;default:R=p.head,p.head=R.next,p.head.prev=null}return R.next=null,R.queue=null,p.size--,R.value}function s(p){if(p.queue!==null){if(p.queue.last===p){i(p.queue);return}if(p.queue.head===p){l(p.queue);return}p.prev&&(p.prev.next=p.next),p.next&&(p.next.prev=p.prev),p.queue.size--,p.queue=null,p.value=null,p.next=null,p.prev=null}}function h(p,R){if(!R.draining){var E=R.puts,w=R.takes,I=R.reads,L,U,V,Q,te;for(R.draining=!0;;){if(L=null,U=null,V=null,Q=R.value,te=I.size,R.error!==null){for(Q=p.left(R.error);L=l(E);)r(L.cb(Q));for(;U=l(I);)r(U(Q));for(;V=l(w);)r(V(Q));break}if(Q===t&&(L=l(E))&&(R.value=Q=L.value),Q!==t){for(V=l(w);te--&&(U=l(I));)r(U(p.right(Q)));V!==null&&(R.value=t,r(V(p.right(Q))))}if(L!==null&&r(L.cb(p.right(void 0))),R.value===t&&E.size===0||R.value!==t&&w.size===0)break}R.draining=!1}}return a.EMPTY=t,a.putLast=u,a.takeLast=i,a.takeHead=l,a.deleteCell=s,a.drainVar=h,a})();var MA=function(e){return q_(Z0(e))},AA=function(e){return q_(vd(e))};var Yme=x(Nt),_0=ae(nn),Xme=Fa(cu),Zme=Fa(go),ede=Fa(Il),nde=Fa(tc),ade=Fa(ac),tde=Fa(nc),rde=Fa(al),ode=x(ka),Nk=tt(uo),ude=ge(ue);var ide=(function(){return AA(G.value)})();var Ok=function(e){return _0(Xme(e.year))(function(n){return _0(Zme(e.month+1|0))(function(a){return _0(ede(e.day))(function(t){return _0(nde(e.hour))(function(r){return _0(ade(e.minute))(function(u){return _0(tde(e.second))(function(i){return _0(rde(e.millisecond))(function(l){return ode(new xc(B_(n)(a)(t),new gv(r,u,i,l)))})})})})})})})},Uk=function(e){var n=z7("Failed to obtain current time. This should never happen.");return Wn(n)(Yme)(Ok(FA(e)))},p0=Nk(Uk)(Ck),yE=function(e){var n=MA(ide);if(n instanceof T)return n.value0;if(n instanceof G)return q_(Nk(Uk)(Fk));throw new Error("Failed pattern match at Utils.DateTime (line 60, column 3 - line 62, column 76): "+[n.constructor.name])},Ai=function(e){return _0(ude(Sk({just:T.create,nothing:G.value})(e))(FA))(Ok)};var LA=x(ka),lde=B(ue),kk=ae(nn);var qk=oa(ra),Bk=ta(qk)(Zn(Xn)),$k=na(ea),Hk=aa($k),Wk=la(ia),Jk=ua(Wk);var PA=(function(){function e(){}return e.value=new e,e})(),NA=(function(){function e(){}return e.value=new e,e})(),OA=(function(){function e(){}return e.value=new e,e})();var cde={to:function(e){if(e instanceof Te)return PA.value;if(e instanceof fe&&e.value0 instanceof Te)return NA.value;if(e instanceof fe&&e.value0 instanceof fe)return OA.value;throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types (line 175, column 1 - line 175, column 41): "+[e.constructor.name])},from:function(e){if(e instanceof PA)return new Te(xe.value);if(e instanceof NA)return new fe(new Te(xe.value));if(e instanceof OA)return new fe(new fe(xe.value));throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types (line 175, column 1 - line 175, column 41): "+[e.constructor.name])}};var sde=function(e){if(e instanceof PA)return"stuffed";if(e instanceof NA)return"satisfied";if(e instanceof OA)return"hungry";throw new Error("Failed pattern match at ServiceProviders.Retail.Advising.Types (line 235, column 27 - line 238, column 35): "+[e.constructor.name])};var vde=It(sn)(ue)({parse:Vn(sde)(Qn(cde)(Bk(Bk(qk)($k))(Hk))(Jk(Jk(Wk)))(Hk)),diagnosticName:"ClientAppetite"}),xk=function(e){return kk(Wn(LA(G.value))((function(){var n=lde(LA);return function(a){return n(vde(a))}})())(he(e.clientAppetite)))(function(n){return kk(d9(e.inquiryMode))(function(a){return LA({packages:e.packages,pricePerHourCents:e.pricePerHourCents,singleSessionDurationMinutes:e.singleSessionDurationMinutes,singleSessionRefundPeriodLengthDays:e.singleSessionRefundPeriodLengthDays,themes:e.themes,freeConsultationDurationMinutes:he(e.freeConsultationDurationMinutes),canSubmitConsultInquiry:he(e.canSubmitConsultInquiry),clientAppetite:n,inquiryMode:a})})})};var jk=ae(nn),vh=dt(),UA=kt(be),zk=$({reflectSymbol:function(){return"description"}})(be),wE=$({reflectSymbol:function(){return"id"}})(Dn),BA=$({reflectSymbol:function(){return"name"}})(be),Qk=vh(wE(BA($({reflectSymbol:function(){return"slug"}})(be)(mn)))),Vk=ht(Qk),_de=o0(vh($({reflectSymbol:function(){return"advisingConfig"}})(kt(vh($({reflectSymbol:function(){return"canSubmitConsultInquiry"}})(kt(ct))($({reflectSymbol:function(){return"clientAppetite"}})(UA)($({reflectSymbol:function(){return"freeConsultationDurationMinutes"}})(kt(Dn))($({reflectSymbol:function(){return"inquiryMode"}})(be)($({reflectSymbol:function(){return"packages"}})(ht(vh($({reflectSymbol:function(){return"activeForSale"}})(ct)(zk(wE(BA($({reflectSymbol:function(){return"numMinutes"}})(Dn)($({reflectSymbol:function(){return"packageCategories"}})(Vk)($({reflectSymbol:function(){return"refundPeriodLengthDays"}})(Dn)($({reflectSymbol:function(){return"totalPriceCents"}})(mR)(mn)))))))))))($({reflectSymbol:function(){return"pricePerHourCents"}})(mR)($({reflectSymbol:function(){return"singleSessionDurationMinutes"}})(Dn)($({reflectSymbol:function(){return"singleSessionRefundPeriodLengthDays"}})(Dn)($({reflectSymbol:function(){return"themes"}})(ht(vh($({reflectSymbol:function(){return"active"}})(ct)($({reflectSymbol:function(){return"category"}})(Qk)(zk($({reflectSymbol:function(){return"durationMinutes"}})(Dn)(wE($({reflectSymbol:function(){return"priceCents"}})(mR)($({reflectSymbol:function(){return"title"}})(be)(mn))))))))))(mn))))))))))))($({reflectSymbol:function(){return"entity"}})(vh($({reflectSymbol:function(){return"bio"}})(be)(wE($({reflectSymbol:function(){return"imageUrl"}})(UA)(BA($({reflectSymbol:function(){return"organizationId"}})(Dn)($({reflectSymbol:function(){return"organizationName"}})(be)($({reflectSymbol:function(){return"shortEducation"}})(UA)($({reflectSymbol:function(){return"tags"}})(Vk)(mn))))))))))(mn)))),kA=x(ka),HA=B(ue),dR=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),hR=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),pde=function(e){return jk(_de("ServiceProviderPresenter")(e))(function(n){return jk(Wn(kA(G.value))((function(){var a=HA(kA);return function(t){return a(xk(t))}})())(he(n.advisingConfig)))(function(a){return kA({entity:n.entity,advisingConfig:a})})})},Kk=It(sn)(ue)({parse:function(e){return e.type==="Sem::User"?HA(dR.create)(e9(e.presenter)):e.type==="ServiceProviders::Individual"?HA(hR.create)(pde(e.presenter)):G.value},diagnosticName:"Livestream Guest Presenter"});var eB=oa(ra),Yk=ta(eB)(Zn(Xn)),nB=na(ea),Xk=aa(nB),aB=la(ia),Zk=ua(aB),qf=(function(){function e(){}return e.value=new e,e})(),Nv=(function(){function e(){}return e.value=new e,e})(),$f=(function(){function e(){}return e.value=new e,e})(),mde={to:function(e){if(e instanceof Te)return qf.value;if(e instanceof fe&&e.value0 instanceof Te)return Nv.value;if(e instanceof fe&&e.value0 instanceof fe)return $f.value;throw new Error("Failed pattern match at Livestream.Types.Poll (line 39, column 1 - line 39, column 37): "+[e.constructor.name])},from:function(e){if(e instanceof qf)return new Te(xe.value);if(e instanceof Nv)return new fe(new Te(xe.value));if(e instanceof $f)return new fe(new fe(xe.value));throw new Error("Failed pattern match at Livestream.Types.Poll (line 39, column 1 - line 39, column 37): "+[e.constructor.name])}},tB={eq:function(e){return function(n){return e instanceof qf&&n instanceof qf||e instanceof Nv&&n instanceof Nv||e instanceof $f&&n instanceof $f}}},bE=function(e){if(e instanceof qf)return"ready";if(e instanceof Nv)return"live";if(e instanceof $f)return"closed";throw new Error("Failed pattern match at Livestream.Types.Poll (line 64, column 23 - line 67, column 21): "+[e.constructor.name])};var gR=(function(){return Ga(sn)({parse:Vn(bE)(Qn(mde)(Yk(Yk(eB)(nB))(Xk))(Zk(Zk(aB)))(Xk)),default:qf.value,diagnosticName:"livestream poll status"})})(),qA=function(e){return{id:e.id,question:e.question,multiSelect:e.multiSelect,options:e.options,autoDisplayMinutesFromStart:he(e.autoDisplayMinutesFromStart)}};var rB=function(e){return{fullName:e.fullName,firstName:e.firstName,totalStreams:e.totalStreams,undergrad:{college:he(e.undergrad.college),major:he(e.undergrad.major),year:he(e.undergrad.year)},gradCollege:he(e.gradCollege),workExperience:he(e.workExperience),admissionsStory:he(e.admissionsStory),pictureUrl:he(e.pictureUrl),allStreamsUrl:he(e.allStreamsUrl)}};var hde=We(Ca),gde=El(),sB=ge(ue),vB=oa(ra),oB=ta(vB)(Zn(Xn)),fB=na(ea),uB=aa(fB),_B=la(ia),iB=ua(_B),pB=Ga(sn),lB=lv(),cB=tt(nn),Dde=ge(Ye),Rde=B(ue),yde=ae(nn),ol=(function(){function e(){}return e.value=new e,e})(),fu=(function(){function e(){}return e.value=new e,e})(),Uo=(function(){function e(){}return e.value=new e,e})();var $s=pn,wde=oe($s);var bde={to:function(e){if(e instanceof Te)return ol.value;if(e instanceof fe&&e.value0 instanceof Te)return fu.value;if(e instanceof fe&&e.value0 instanceof fe)return Uo.value;throw new Error("Failed pattern match at Livestream.Types.Conference (line 172, column 1 - line 172, column 39): "+[e.constructor.name])},from:function(e){if(e instanceof ol)return new Te(xe.value);if(e instanceof fu)return new fe(new Te(xe.value));if(e instanceof Uo)return new fe(new fe(xe.value));throw new Error("Failed pattern match at Livestream.Types.Conference (line 172, column 1 - line 172, column 39): "+[e.constructor.name])}},m0={eq:function(e){return function(n){return e instanceof ol&&n instanceof ol||e instanceof fu&&n instanceof fu||e instanceof Uo&&n instanceof Uo}}},DR={eq:function(e){return function(n){return e===n}}},mB={compare:function(e){return function(n){return hde(e)(n)}},Eq0:function(){return DR}};var d0=function(e){return gde({livestream_conference_id:wde(e.id),livestream_conference_presenter_name:je("")(sB(e.presenter)(function(n){return n.fullName})),livestream_conference_uid:e.uid,livestream_conference_title:e.title,livestream_conference_partner_type:je("")(e.partnerType)})},dB=(function(){var e=function(n){if(n instanceof ol)return"waiting_room";if(n instanceof fu)return"on_air";if(n instanceof Uo)return"complete";throw new Error("Failed pattern match at Livestream.Types.Conference (line 185, column 15 - line 188, column 33): "+[n.constructor.name])};return Vn(e)(Qn(bde)(oB(oB(vB)(fB))(uB))(iB(iB(_B)))(uB))})(),hB=(function(){return pB({parse:dB,default:ol.value,diagnosticName:"livestream status"})})(),Ede=pB({parse:Ai,default:Ut(kd),diagnosticName:"livestream scheduled start time"}),RR=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:sB(he(e.school))(function(n){return{cityState:n.cityState,name:n.name,id:lB(n.id),slug:lB(n.slug)}}),scheduledStartTime:Ede(e.scheduledStartTime),onAirTime:cB(Ai)(he(e.onAirTime)),streamStatus:hB(e.streamStatus),watchUrl:he(e.watchUrl),streamingStartTime:cB(Ai)(he(e.streamingStartTime)),polls:Dde(e.polls)(function(n){return{poll:qA(n.poll),status:gR(n.status)}}),presenter:Rde(rB)(he(e.presenter)),partnerType:he(e.partnerType),guestPresenter:yde(he(e.guestPresenter))(Kk),zoomJoinUrl:he(e.zoomJoinUrl),zoomStartUrl:he(e.zoomStartUrl)}};var gB=oa(ra),DB=na(ea),RB=la(ia),_c=(function(){function e(){}return e.value=new e,e})(),fh=(function(){function e(){}return e.value=new e,e})(),Ide={to:function(e){if(e instanceof Te)return _c.value;if(e instanceof fe)return fh.value;throw new Error("Failed pattern match at Profile.PublishScope (line 20, column 1 - line 20, column 39): "+[e.constructor.name])},from:function(e){if(e instanceof _c)return new Te(xe.value);if(e instanceof fh)return new fe(xe.value);throw new Error("Failed pattern match at Profile.PublishScope (line 20, column 1 - line 20, column 39): "+[e.constructor.name])}},EE={eq:function(e){return function(n){return e instanceof _c&&n instanceof _c||e instanceof fh&&n instanceof fh}}};var yR=function(e){if(e instanceof fh)return"anonymous-all-schools";if(e instanceof _c)return"all-schools";throw new Error("Failed pattern match at Profile.PublishScope (line 30, column 13 - line 32, column 30): "+[e.constructor.name])},IE=(function(){return Ga(sn)({parse:Vn(yR)(Qn(Ide)(ta(gB)(Zn(Xn))(gB)(DB))(ua(RB)(RB))(aa(DB))),diagnosticName:"Profile.PublishScope",default:fh.value})})();var ns=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),as=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ts=(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})();var WA=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:he(e.description)}},Zp=function(e){return{author:e.author,text:e.text,isFromHQ:e.isFromHQ,isPublic:e.isPublic,id:e.id,time:Ai(e.time)}},yB=function(e){return{autoRequestFromLivestreams:e.autoRequestFromLivestreams,fullName:he(e.fullName),publishScope:IE(e.publishScope)}},xA=function(e){return{id:e.id,title:e.title,url:e.url,buttonText:e.buttonText,autoDisplayMinutesFromStart:he(e.autoDisplayMinutesFromStart)}},pc="overlay-visibility-test";var wB=oa(ra),TE=ta(wB)(Zn(Xn)),bB=na(ea),SE=aa(bB),EB=la(ia),CE=ua(EB),Wf=(function(){function e(){}return e.value=new e,e})(),h0=(function(){function e(){}return e.value=new e,e})(),em=(function(){function e(){}return e.value=new e,e})(),g0=(function(){function e(){}return e.value=new e,e})(),D0=(function(){function e(){}return e.value=new e,e})(),Tde={to:function(e){if(e instanceof Te)return Wf.value;if(e instanceof fe&&e.value0 instanceof Te)return h0.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof Te)return em.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof fe&&e.value0.value0.value0 instanceof Te)return g0.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof fe&&e.value0.value0.value0 instanceof fe)return D0.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 Wf)return new Te(xe.value);if(e instanceof h0)return new fe(new Te(xe.value));if(e instanceof em)return new fe(new fe(new Te(xe.value)));if(e instanceof g0)return new fe(new fe(new fe(new Te(xe.value))));if(e instanceof D0)return new fe(new fe(new fe(new fe(xe.value))));throw new Error("Failed pattern match at Livestream.Types.Reaction (line 20, column 1 - line 20, column 39): "+[e.constructor.name])}},IB=function(e){if(e instanceof Wf)return"love-this";if(e instanceof h0)return"helpful";if(e instanceof em)return"not-helpful";if(e instanceof g0)return"writing-down";if(e instanceof D0)return"funny";throw new Error("Failed pattern match at Livestream.Types.Reaction (line 51, column 17 - line 56, column 19): "+[e.constructor.name])},TB=function(e){return{authorTag:e.authorTag,kind:IB(e.kind)}},Sde=(function(){return Ga(sn)({parse:Vn(IB)(Qn(Tde)(TE(TE(TE(TE(wB)(bB))(SE))(SE))(SE))(CE(CE(CE(CE(EB)))))(SE)),default:Wf.value,diagnosticName:"Livestream Reaction Kind"})})(),SB=function(e){return{authorTag:e.authorTag,kind:Sde(e.kind)}};var FB=typeof CV<"u"&&CV.pathInfo||typeof global<"u"&&global.CV&&global.CV.pathInfo||(e=>null);function GB(e,n){let a=typeof CV<"u"&&CV.apiEndpoint||typeof global<"u"&&global.CV&&global.CV.apiEndpoint;return a||console.error("Missing `CV.apiEndpoint` function"),a&&a(e,n)}function MB(e,n,a,t,r){return function(u,i){var l=e.newXHR(),s=e.fixupUrl(r.url,l);if(l.open(r.method||"GET",s,!0,r.username,r.password),r.headers)try{for(var h=0,p;(p=r.headers[h])!=null;h++)l.setRequestHeader(p.field,p.value)}catch(E){u(E)}var R=function(E){return function(){u(new Error(E))}};return l.onerror=R(a),l.ontimeout=R(n),l.onload=function(){i({status:l.status,statusText:l.statusText,headers:l.getAllResponseHeaders().split(`\r `).filter(function(E){return E.length>0}).map(function(E){var w=E.indexOf(":");return t(E.substring(0,w))(E.substring(w+2))}),body:l.response})},l.responseType=r.responseType,l.withCredentials=r.withCredentials,l.timeout=r.timeout,l.send(r.content),function(E,w,I){try{l.abort()}catch(L){return w(L)}return I()}}}var FE="application/json",AB="application/x-www-form-urlencoded";var PB=(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})(),OB=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),UB=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),kB=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),jA=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),GE=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),BB=function(e){return e instanceof jA?new T(AB):e instanceof GE?new T(FE):G.value};var HB=(function(){return GE.create})();var JB=ut();var ME=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),AE=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),nm=(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})(),qB=function(e){if(e instanceof ME||e instanceof AE)return JB(e.value0);if(e instanceof nm)return e.value1;throw new Error("Failed pattern match at Affjax.RequestHeader (line 26, column 1 - line 26, column 33): "+[e.constructor.name])};var VA=function(e){if(e instanceof ME)return"Accept";if(e instanceof AE)return"Content-Type";if(e instanceof nm)return e.value0;throw new Error("Failed pattern match at Affjax.RequestHeader (line 21, column 1 - line 21, column 32): "+[e.constructor.name])};var WB=hn(En),QA=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),KA=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),YA=(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})(),PE=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),NE=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),xB=function(e){if(e instanceof QA)return"arraybuffer";if(e instanceof KA)return"blob";if(e instanceof YA)return"document";if(e instanceof LE||e instanceof PE)return"text";if(e instanceof NE)return"";throw new Error("Failed pattern match at Affjax.ResponseFormat (line 44, column 3 - line 50, column 19): "+[e.constructor.name])},jB=function(e){return e instanceof LE?new T(FE):G.value},zB=(function(){return new PE(WB)})();var VB=(function(){return new NE(WB)})();var KB=(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 Lde=ut();var am=function(e){return Lde(vD(e))};function YB(e,n,a){try{return n(JSON.parse(a))}catch(t){return e(t.message)}}var UE=function(e){return YB(Me.create,Le.create,e)};function ZB(e){return e.replace(/[!'()*]/g,function(n){return"%"+n.charCodeAt(0).toString(16)})}function eH(e,n,a){try{return n(ZB(encodeURIComponent(a)))}catch(t){return e(t)}}function nH(e,n,a){try{return n(ZB(encodeURIComponent(a)).replace(/%20/g,"+"))}catch(t){return e(t)}}var bR=(function(){return b_(eH)(gn(G.value))(T.create)})();var kE=(function(){return b_(nH)(gn(G.value))(T.create)})();var Ude=sa(Ro),aH=B(ue),kde=lu(Rl)(ka);var Bde=function(e){return e};var tH=(function(){var e=function(t){if(t.value1 instanceof G)return kE(t.value0);if(t.value1 instanceof T)return Ude(aH(function(r){return function(u){return r+("="+u)}})(kE(t.value0)))(kE(t.value1.value0));throw new Error("Failed pattern match at Data.FormURLEncoded (line 37, column 16 - line 39, column 114): "+[t.constructor.name])},n=aH(vo("&")),a=kde(e);return function(t){return n(a(Bde(t)))}})();var XA=(function(){function e(){}return e.value=new e,e})(),tm=(function(){function e(){}return e.value=new e,e})(),ZA=(function(){function e(){}return e.value=new e,e})(),rm=(function(){function e(){}return e.value=new e,e})(),HE=(function(){function e(){}return e.value=new e,e})(),ER=(function(){function e(){}return e.value=new e,e})(),e2=(function(){function e(){}return e.value=new e,e})(),n2=(function(){function e(){}return e.value=new e,e})(),a2=(function(){function e(){}return e.value=new e,e})(),t2=(function(){function e(){}return e.value=new e,e})(),r2=(function(){function e(){}return e.value=new e,e})(),o2=(function(){function e(){}return e.value=new e,e})(),u2=(function(){function e(){}return e.value=new e,e})(),i2=(function(){function e(){}return e.value=new e,e})(),l2=(function(){function e(){}return e.value=new e,e})(),JE=(function(){function e(){}return e.value=new e,e})();var Jde=function(e){return e},qde={show:function(e){if(e instanceof XA)return"OPTIONS";if(e instanceof tm)return"GET";if(e instanceof ZA)return"HEAD";if(e instanceof rm)return"POST";if(e instanceof HE)return"PUT";if(e instanceof ER)return"DELETE";if(e instanceof e2)return"TRACE";if(e instanceof n2)return"CONNECT";if(e instanceof a2)return"PROPFIND";if(e instanceof t2)return"PROPPATCH";if(e instanceof r2)return"MKCOL";if(e instanceof o2)return"COPY";if(e instanceof u2)return"MOVE";if(e instanceof i2)return"LOCK";if(e instanceof l2)return"UNLOCK";if(e instanceof JE)return"PATCH";throw new Error("Failed pattern match at Data.HTTP.Method (line 43, column 1 - line 59, column 23): "+[e.constructor.name])}};var rH=yr(oe(qde))(Jde);var oH={eq:function(e){return function(n){return e instanceof XA&&n instanceof XA||e instanceof tm&&n instanceof tm||e instanceof ZA&&n instanceof ZA||e instanceof rm&&n instanceof rm||e instanceof HE&&n instanceof HE||e instanceof ER&&n instanceof ER||e instanceof e2&&n instanceof e2||e instanceof n2&&n instanceof n2||e instanceof a2&&n instanceof a2||e instanceof t2&&n instanceof t2||e instanceof r2&&n instanceof r2||e instanceof o2&&n instanceof o2||e instanceof u2&&n instanceof u2||e instanceof i2&&n instanceof i2||e instanceof l2&&n instanceof l2||e instanceof JE&&n instanceof JE}}};var uH=function(e){return H_(function(n){return function(){var t=e(function(r){return n(Me.create(r))()},function(r){return n(Le.create(r))()});return function(r){return H_(function(u){return function(){return t(r,function(l){return u(Me.create(l))()},function(l){return u(Le.create(l))()}),zG}})}}})};var s2=x(Xl(Nr)),Wde=wp(Nr),om=yf(Nr),iH=La(fD(mD)(Nr)),xde=Xs(Oc(Nr)),qE=B(ue),jde=Wi(Je)(Ot),zde=we(Dr),Vde=tt(nn),Qde=B(Ye),Kde=ge(st),Yde=M_(Yo),Xde=x(ba);var $E=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),WE=(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})(),xE=(function(){function e(){}return e.value=new e,e})(),jE=(function(){function e(){}return e.value=new e,e})(),zE=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),lH=function(e){return function(n){var a=function(p){return p===""?s2(QU):yr(function(R){return Wde(yp.create(R))})(s2)(UE(p))},t=(function(){if(n.responseFormat instanceof QA)return om("ArrayBuffer");if(n.responseFormat instanceof KA)return om("Blob");if(n.responseFormat instanceof YA)return function(p){return iH(om("Document")(p))(iH(om("XMLDocument")(p))(om("HTMLDocument")(p)))};if(n.responseFormat instanceof LE)return xde(function(p){return n.responseFormat.value0(a(p))})(om("String"));if(n.responseFormat instanceof PE)return om("String");if(n.responseFormat instanceof NE)return gn(n.responseFormat.value0(s2(void 0)));throw new Error("Failed pattern match at Affjax (line 274, column 18 - line 283, column 57): "+[n.responseFormat.constructor.name])})(),r=function(p){if(p instanceof PB)return new Le(p.value0(bo));if(p instanceof NB)return new Le(bo(p.value0));if(p instanceof OB)return new Le(bo(p.value0));if(p instanceof UB)return new Le(bo(p.value0));if(p instanceof kB)return new Le(bo(p.value0));if(p instanceof jA)return Ac("Body contains values that cannot be encoded as application/x-www-form-urlencoded")(qE(bo)(tH(p.value0)));if(p instanceof GE)return new Le(bo(k1(p.value0)));throw new Error("Failed pattern match at Affjax (line 235, column 20 - line 250, column 69): "+[p.constructor.name])},u=function(p){return function(R){return p instanceof T&&!jde(f_(zde)(VA)(p.value0))(R)?pp(R)(p.value0):R}},i=function(p){return u(qE(AE.create)(Vde(BB)(p)))(u(qE(ME.create)(jB(n.responseFormat)))(n.headers))},l=function(p){return{method:rH(n.method),url:n.url,headers:Qde(function(R){return{field:VA(R),value:qB(R)}})(i(n.content)),content:p,responseType:xB(n.responseFormat),username:et(n.username),password:et(n.password),withCredentials:n.withCredentials,timeout:je(0)(qE(function(R){return R})(n.timeout))}},s=function(p){return Kde(Yde(uH(MB(e,"AffjaxTimeoutErrorMessageIdent","AffjaxRequestFailedMessageIdent",KB.create,l(p)))))(function(R){if(R instanceof Le){var E=am(t(R.value0.body));if(E instanceof Me)return new Me(new WE(vO(E.value0),R.value0));if(E instanceof Le)return new Le({headers:R.value0.headers,status:R.value0.status,statusText:R.value0.statusText,body:E.value0});throw new Error("Failed pattern match at Affjax (line 209, column 9 - line 211, column 52): "+[E.constructor.name])}if(R instanceof Me)return new Me((function(){var w=gp(R.value0),I=w==="AffjaxTimeoutErrorMessageIdent";if(I)return xE.value;var L=w==="AffjaxRequestFailedMessageIdent";return L?jE.value:new zE(R.value0)})());throw new Error("Failed pattern match at Affjax (line 207, column 144 - line 219, column 28): "+[R.constructor.name])})};if(n.content instanceof G)return s(et(G.value));if(n.content instanceof T){var h=r(n.content.value0);if(h instanceof Le)return s(et(new T(h.value0)));if(h instanceof Me)return Xde(new Me(new $E(h.value0)));throw new Error("Failed pattern match at Affjax (line 199, column 7 - line 203, column 48): "+[h.constructor.name])}throw new Error("Failed pattern match at Affjax (line 195, column 3 - line 203, column 48): "+[n.content.constructor.name])}};var ph=(function(){return{method:new Me(tm.value),url:"/",headers:[],content:G.value,username:G.value,password:G.value,withCredentials:!1,responseFormat:VB,timeout:G.value}})();var sH={eq:function(e){return function(n){return e===n}}};var v2={newXHR:function(){return new XMLHttpRequest},fixupUrl:function(e){return e||"/"}};var vH=lH(v2);function LH(e){return Buffer.from(e).toString("base64")}function PH(e,n,a){let t;try{t=n(btoa(a))}catch(r){t=e(r)}return t}var m2=typeof btoa=="function";function NH(e){let a=[];for(let t=0;t{let e=null,n=0,a=()=>{if(!Bv||!Bv.key)return Bv||console.error("Pusher config is missing in global context"),new Yhe;let t={auth:{headers:{"X-CSRF-Token":Bv.authToken}},authEndpoint:Bv.authPath,cluster:Bv.cluster};return Bv.dev&&Object.assign(t,{wsHost:Bv.dev.wsHost,wsPort:Bv.dev.wsPort,enabledTransports:["ws"],forceTLS:!1,disableStats:!0}),new YH.default(Bv.key,t)};return{acquireConnection:()=>(e||(e=a(),n=0),n++,e),releaseConnection:()=>{--n<=0&&(e&&e.disconnect(),e=null)}}})(),XH=e=>{let n=Qhe().subscribe(e.channel);return n.bind(e.event,e.handler),()=>{n.unbind(e.event,e.handler),Khe()}};function Yhe(){typeof document<"u"&&(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 Xhe(e);return this.channels.push(a),a},this.channelNames=function(){return this.channels.map(e=>e.name)}}function Xhe(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 ZE=function(e){return e};var oge=function(e){return e},nJ=function(e){var n=We(e),a=oge(e.Eq0());return{compare:function(t){return function(r){return p8(n(t)(r))}},Eq0:function(){return a}}};var nI=function(e){return function(){console.error(e)}};var cJ=function(e){var n=Hn(e);return function(a){return n(nI(a))}};var wge=x(Nt),sJ=ae(uo),bge=B(ca),Ege=cJ(Go),g2=function(e){var n=function(t){var r=e(t);return _M(r.view(r.init.value0)(gn(wge(void 0))))},a=function(t){return function(r){return function(u){return function(){var l=sJ(sJ(Mi)((function(){var h=bge(dE);return function(p){return h(s0(p))}})()))(pE(r))();if(l instanceof G)return Ege("Element #"+(r+" not found"))();if(l instanceof T){var s=hM(e(u))();return t(s)(l.value0)()}throw new Error("Failed pattern match at Elmish.Boot (line 117, column 11 - line 122, column 21): "+[l.constructor.name])}}}};return{mount:a(wU),renderToString:n,hydrate:a(bU)}};var Tge=x(Nt),Sge=yi(),vJ=function(e){return{handleMaybe:function(n){return function(a){return Wd((function(){var t=Wn(Tge(void 0))(n);return function(r){return t(Sge(a(r)))}})())}}}};var Dh={handle:function(e){return function(n){return function(a){return e(n(a))()}}}},fJ={handleEffect:function(e){return Wd(e)}};var Hv={handle:function(e){return function(n){return function(a){return e(n)()}}}},D2=function(e){return e.handleMaybe},R2=function(e){return e.handleEffect},Pl=function(e){return e.handle};var GR="";function pJ(e){var n=e.split(` `);return n.reduce(function(a,t){var r=Gge(t)||Age(t)||Nge(t)||Bge(t)||Uge(t);return r&&a.push(r),a},[])}var Cge=/^\s*at (.*?) ?\(((?:file|https?|blob|chrome-extension|native|eval|webpack||\/|[a-z]:\\|\\\\).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Fge=/\((\S*)(?::(\d+))(?::(\d+))\)/;function Gge(e){var n=Cge.exec(e);if(!n)return null;var a=n[2]&&n[2].indexOf("native")===0,t=n[2]&&n[2].indexOf("eval")===0,r=Fge.exec(n[2]);return t&&r!=null&&(n[2]=r[1],n[3]=r[2],n[4]=r[3]),{file:a?null:n[2],methodName:n[1]||GR,arguments:a?[n[2]]:[],lineNumber:n[3]?+n[3]:null,column:n[4]?+n[4]:null}}var Mge=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i;function Age(e){var n=Mge.exec(e);return n?{file:n[2],methodName:n[1]||GR,arguments:[],lineNumber:+n[3],column:n[4]?+n[4]:null}:null}var Lge=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|\[native).*?|[^@]*bundle)(?::(\d+))?(?::(\d+))?\s*$/i,Pge=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i;function Nge(e){var n=Lge.exec(e);if(!n)return null;var a=n[3]&&n[3].indexOf(" > eval")>-1,t=Pge.exec(n[3]);return a&&t!=null&&(n[3]=t[1],n[4]=t[2],n[5]=null),{file:n[3],methodName:n[1]||GR,arguments:n[2]?n[2].split(","):[],lineNumber:n[4]?+n[4]:null,column:n[5]?+n[5]:null}}var Oge=/^\s*(?:([^@]*)(?:\((.*?)\))?@)?(\S.*?):(\d+)(?::(\d+))?\s*$/i;function Uge(e){var n=Oge.exec(e);return n?{file:n[3],methodName:n[1]||GR,arguments:[],lineNumber:+n[4],column:n[5]?+n[5]:null}:null}var kge=/^\s*at (?:((?:\[object object\])?[^\\/]+(?: \[as \S+\])?) )?\(?(.*?):(\d+)(?::(\d+))?\)?\s*$/i;function Bge(e){var n=kge.exec(e);return n?{file:n[2],methodName:n[1]||GR,arguments:[],lineNumber:+n[3],column:n[4]?+n[4]:null}:null}function dJ({skipFrames:e,prefix:n}){let a=new Error().stack,r=pJ(a)[e],u=mJ(r.file.replace(/^(http(s?):\/\/)?[^\/]+/,"")),i=mJ(r.methodName);return`${n}_${u}_${i}_${r.lineNumber}_${r.column}`}var mJ=e=>e.replace(/[^\d\w]+/g,"_").replace(/(^_|_$)/g,"");var qge=x(Un),$ge=hn(En),aI=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Wge={map:function(e){return function(n){return new aI(function(a){return n.value0(function(t){return a(e(t))})})}}},xge=B(Wge);var hJ=function(e){return dM(dJ(e))},xf=function(e){return new aI(function(n){return n(e)})},lm=function(e){return function(n){return new aI(function(a){return Af(e)(n)(a)})}},gJ=function(e){return function(n){return Af(e)(function(a){return{init:qge(void 0),update:gn(uf),view:gn(gn(n.value0($ge)))}})(void 0)}},DJ=function(e){var n=hJ({skipFrames:3,prefix:"WithHook"});return function(a){return gJ(n)(xge(a)(e))}};var Rh=function(e){var n=hJ({skipFrames:3,prefix:"HooksComponent"});return gJ(n)(e)},Jv=function(){return function(e){return function(n){return new aI(function(a){return e.value0(function(t){var r=n(t);return r.value0(a)})})}}},jge=Jv(),cm=function(e){return function(){return jge}};Et();var y2=class extends vt.Component{componentDidUpdate(n){this.props.componentDidUpdate(n.deps)}render(){return this.props.children}},RJ=y2;var Vge=lr();var yJ=function(e){return"ref:"+Vt(e)(lt.value)},wJ=function(e){var n=yJ(e);return function(a){return Vge(Fs(n)(a))}},bJ=function(e){var n=yJ(e);return function(a){return Qb(n)(a)}};var Kge=uc(),EJ=fn(ln)(ma),IJ=x(Un),Yge=D2(vJ(D6)),TJ={reflectSymbol:function(){return"deps"}},Xge=wJ(TJ),Zge=bJ(TJ),eDe=hn(En);var nDe=function(e){var n=Kge(e);return function(){return function(){return n(RJ)}}},aDe=nDe(on)()(),tDe=function(e){var n=Ou(e);return function(a){return function(t){return function(r){return function(u){return lm(a)(function(i){return t({init:EJ(Bt(u(r)))(function(){return IJ(r)}),update:function(l){return function(s){return EJ(Bt(u(s)))(function(){return IJ(s)})}},view:function(l){return function(s){return aDe({componentDidUpdate:Yge(s)(function(h){var p=n(Xge(h))(r);return p?new T(r):G.value}),deps:Zge(r)})(i(void 0))}}})})}}}}};var yh=function(e){var n=tDe(e);return function(a){return function(t){return n("UseEffectPrime")(eDe)(a)(t)}}};var SJ=x(Un),rDe=hn(En);var oDe=function(e){return function(n){return function(a){return lm(e)(function(t){return n({init:SJ(a),update:function(r){return function(u){return SJ(u)}},view:op(t)})})}}},is=function(e){return oDe("UseState")(rDe)(e)};var w2=(function(){return Jv()(is(G.value))(function(e){return xf(new yn(e.value0,E1(e.value0)(e.value1)))})})();var CJ=fn(ln)(ma),iDe=Gi(qe),lDe=hn(En),FJ=x(Un),MR=function(e){return function(n){return lm("UseSubscription")(function(a){return{init:CJ(iDe(lDe)(e))(function(){return FJ(void 0)}),update:function(t){return function(r){return CJ(Bt(n(r)))(function(){return FJ(void 0)})}},view:function(t){return function(r){return a(void 0)}}}})}};var rI=typeof CV<"u"&&CV.assetsRoot||typeof global<"u"&&global.CV&&global.CV.assetsRoot||"/";var LR=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Nl=(function(){function e(){}return e.value=new e,e})();var NJ=function(e){if(e instanceof LR)return e.value0;if(e instanceof Nl)return"";throw new Error("Failed pattern match at Utils.HTML.Img.Alt (line 23, column 15 - line 25, column 19): "+[e.constructor.name])};var fDe=(function(){function e(){}return e.value=new e,e})(),_De=(function(){function e(){}return e.value=new e,e})();var OJ=function(e){if(e instanceof fDe)return"eager";if(e instanceof _De)return"lazy";throw new Error("Failed pattern match at Utils.HTML.Img.Loading (line 18, column 15 - line 20, column 17): "+[e.constructor.name])};var b2=Lc(uu(Ot)),mDe=eu(),dDe=ge(ue),hDe=jc()(),oI=function(e){var n=bl(e);return function(a){return Fr(n(a))}},UJ=function(e){if(b2(oI("http://"))(b2(oI("https://"))(b2(oI("//"))(oI("blob:"))))(e))return e;if(Ve)return rI+je(e)(bl("/")(e));throw new Error("Failed pattern match at Utils.AppAssets (line 68, column 1 - line 68, column 30): "+[e.constructor.name])},Ol=function(){return function(e){return function(n){var a=mDe(n),t={alt:NJ(a.alt),height:Za(a.height)(void 0),loading:je(void 0)(dDe(Ll(a.loading))(OJ)),onClick:Za(a.onClick)(void 0),src:UJ(a.src),style:Za(a.style)(void 0),width:Za(a.width)(void 0)};return hDe(e)(t)}}};var BJ=x(Un),gDe=Ga(j1),DDe=ae(Ri);var RDe={init:BJ(void 0),update:function(e){return function(n){return BJ(void 0)}},view:function(e){return function(n){return Aa}}},E2=function(e){var n=O_(e);return function(a){return g2(gDe({parse:function(t){return DDe(n(t))(function(r){return Wn(new Me("Component construction failed"))(Le.create)(a.def(r))})},diagnosticName:"Props for "+a.diagnosticName,default:RDe}))}};var Ue=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Jn=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})();var tRe=yo(Je)(cr),rRe=ai(Nt)(iu),oRe=ge(yM);var uRe={show:function(e){return e}},iRe=oe(uRe);var cI=be;var lRe=function(e){var n=o0(e);return function(a){return function(t){return function(r){var u=tRe(["Pusher event ",t," over channel ",iRe(a)]),i=function(l){return rRe(n(u)(l))(r)()};return function(){return XH({channel:a,event:t,handler:i})}}}}},mc=function(e){var n=lRe(e);return function(a){var t=a.Monad0(),r=ae(t.Bind1()),u=Hn(a),i=x(t.Applicative0());return function(l){return function(s){return function(h){return r(u(n(l)(s)(h)))(function(p){return i(u(p))})}}}}},cRe=mc(Ep),sI=function(e){var n=cRe(e);return function(a){return function(t){return oRe(n(a)(t))(gn(void 0))}}};var cq=kv(Ov),il=Ws(cq),ko=ae(Na),NR=Ws(kv(cq)),sq=x(ba),sRe=ge(ue),PR=dt(),vq=$({reflectSymbol:function(){return"pollId"}})(Dn),vRe=$({reflectSymbol:function(){return"status"}})(be)(mn),fRe=sr(ht(PR(vq(vRe)))),fq=B(Ye),_q=B(st),_Re=$({reflectSymbol:function(){return"id"}}),pRe=_Re(Dn),pq=PR($({reflectSymbol:function(){return"author"}})(PR($({reflectSymbol:function(){return"cvid"}})(be)($({reflectSymbol:function(){return"username"}})(be)(mn))))(pRe($({reflectSymbol:function(){return"isFromHQ"}})(ct)($({reflectSymbol:function(){return"isPublic"}})(ct)($({reflectSymbol:function(){return"text"}})(be)($({reflectSymbol:function(){return"time"}})(be)(mn))))))),mRe=gh(pq);var dRe=kt(be);var hRe=gh(ht(PR(vq($({reflectSymbol:function(){return"responses"}})(PR($({reflectSymbol:function(){return"answered"}})(Dn)($({reflectSymbol:function(){return"optionCounts"}})(ht(Dn))($({reflectSymbol:function(){return"seen"}})(Dn)($({reflectSymbol:function(){return"skipped"}})(Dn)(mn))))))(mn))))),gRe=gh(dRe),DRe=gh(ht(pq));var M2=NR("livestreams_polls_status_path")(function(e){return function(n){return function(a){return ko(e({id:n.id,status:bE(a)}))(Uv(function(t){return sq(je([])(sRe(fRe(t))(fq(function(r){return{pollId:r.pollId,status:gR(r.status)}}))))}))}}});var A2=NR("livestreams_polls_answer_path")(function(e){return function(n){return function(a){return ko(e({id:n.id,options:a}))(to)}}}),mq=il("livestreams_conferences_status_on_air_path")(function(e){return function(n){return ko(e({conference_id:n}))(to)}}),dq=il("livestreams_conferences_status_complete_path")(function(e){return function(n){return ko(e({conference_id:n}))(to)}}),hq=il("livestreams_cta_save_referral_path")(function(e){return function(n){return ko(e(n))(to)}}),gq=il("livestreams_polls_report_shown_path")(function(e){return function(n){return ko(e({id:n.id}))(to)}}),Dq=NR("livestreams_client_window_visibility_path")(function(e){return function(n){return function(a){return ko(e({stream_id:n,visible:a.visible}))(to)}}}),Rq=NR("livestreams_recording_watch_event_path")(function(e){return function(n){return function(a){return ko(e({conference_id:n,current_time_minutes:a}))(to)}}}),yq=il("livestreams_questions_visibility_path")(function(e){return function(n){return ko(e({question_id:n.questionId,is_public:n.isPublic}))(to)}}),wq=il("livestreams_questions_post_path")(function(e){return function(n){return ko(e({conference_id:n.conferenceId,question_text:n.text,hq_broadcast:n.hqBroadcast}))(Uv(function(a){return _q(Zp)(mRe("Livestream question")(a))}))}}),bq=il("livestreams_cta_open_path")(function(e){return function(n){return ko(e({is_referral:!0,from_conference_id:n.fromConference,id:n.ctaId}))(to)}}),Eq=il("livestreams_cta_open_path")(function(e){return function(n){return ko(e({is_general:!0,from_conference_id:n.fromConference,id:n.ctaId}))(to)}}),Iq=il("livestreams_cta_open_path")(function(e){return function(n){return ko(e({is_featured_service_providers:!0,from_conference_id:n.fromConference,id:n.ctaId}))(to)}}),Tq=il("livestreams_cta_open_path")(function(e){return function(n){return ko(e({is_event:!0,from_conference_id:n.fromConference,cta_conference_id:n.cta}))(to)}}),vI=il("livestreams_register_path")(function(e){return function(n){return ko(e({from_conference_id:et(n.fromConference),register_for_conference_id:n.registerForConference,utm_cv_source:n.utmSource}))(to)}});var Sq=NR("livestreams_reactions_launch_path")(function(e){return function(n){return function(a){return ko(e({conference_id:n,reaction:TB(a)}))(to)}}}),Cq=il("livestreams_polls_responses_path")(function(e){return function(n){return ko(e({conference_id:n}))(Uv(hRe("livestream poll responses")))}}),Fq=il("livestreams_conferences_download_url_path")(function(e){return function(n){return ko(e({conference_id:n}))(Uv(function(a){return _q(he)(gRe("Livestream download URL")(a))}))}}),fI=Ws(Ov)("livestreams_dismiss_network_settings_modal_path")(function(e){return ko(e({}))(to)});var Gq=il("livestreams_conferences_ban_user_path")(function(e){return function(n){return ko(e({conference_id:n.conferenceId,user_cvid:n.userCvid}))(to)}}),_I=il("livestreams_questions_all_path")(function(e){return function(n){return ko(e({conference_id:n}))(Uv(function(a){return ko(DRe("Livestream questions")(a))(function(t){return sq(fq(Zp)(t))})}))}});var N2=(function(){function e(){}return e.value=new e,e})(),O2=(function(){function e(){}return e.value=new e,e})(),U2=(function(){function e(){}return e.value=new e,e})(),k2=(function(){function e(){}return e.value=new e,e})(),B2=(function(){function e(){}return e.value=new e,e})(),H2=(function(){function e(){}return e.value=new e,e})(),J2=(function(){function e(){}return e.value=new e,e})(),q2=(function(){function e(){}return e.value=new e,e})(),$2=(function(){function e(){}return e.value=new e,e})(),W2=(function(){function e(){}return e.value=new e,e})(),x2=(function(){function e(){}return e.value=new e,e})(),j2=(function(){function e(){}return e.value=new e,e})(),z2=(function(){function e(){}return e.value=new e,e})(),V2=(function(){function e(){}return e.value=new e,e})(),kr=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Q2=(function(){function e(){}return e.value=new e,e})();var mI=function(e){if(e instanceof kr&&e.value0 instanceof N2)return"architecture";if(e instanceof kr&&e.value0 instanceof U2)return"chemistry";if(e instanceof kr&&e.value0 instanceof O2)return"business";if(e instanceof kr&&e.value0 instanceof k2)return"computer-science";if(e instanceof kr&&e.value0 instanceof B2)return"criminal-justice-and-corrections";if(e instanceof kr&&e.value0 instanceof H2)return"economics";if(e instanceof kr&&e.value0 instanceof J2)return"engineering";if(e instanceof kr&&e.value0 instanceof q2)return"english";if(e instanceof kr&&e.value0 instanceof $2)return"film";if(e instanceof kr&&e.value0 instanceof W2)return"finance";if(e instanceof kr&&e.value0 instanceof x2)return"history";if(e instanceof kr&&e.value0 instanceof j2)return"political-science";if(e instanceof kr&&e.value0 instanceof z2)return"pre-med";if(e instanceof kr&&e.value0 instanceof V2)return"psychology";if(e instanceof Q2)return"overall";throw new Error("Failed pattern match at Hub.Ranking (line 97, column 8 - line 112, column 23): "+[e.constructor.name])};var dI=(function(){function e(){}return e.value=new e,e})(),CRe=(function(){function e(){}return e.value=new e,e})(),FRe=(function(){function e(){}return e.value=new e,e})();var Lq=function(e){if(e instanceof dI)return G.value;if(e instanceof FRe)return new T("open");if(e instanceof CRe)return new T("on");throw new Error("Failed pattern match at Hub.Types.WhatificatorPhase (line 21, column 13 - line 24, column 22): "+[e.constructor.name])};var Nq=function(e){var n=DM(e);return function(){return function(){return n("button")}}};var Oq=function(e){var n=DM(e);return function(){return function(){return n("a")}}};var s1e=Yr(uu(Ot)),v1e=function(e){return e},vn=bo(null),f1e=function(e){return s1e(F_)(e)},Uq=function(e){var n=f1e(e);return n?e:""},Vr=function(e){return v1e(bo(e))};var _1e=R2(fJ),kq=Ps()(),un=function(e){return _1e(e)},ga=function(e){var n=Nq(e)()();return function(){return function(){return function(a){return function(t){return function(r){return function(u){return n(kq(r)({className:a,"aria-label":t}))(u)}}}}}}},Bq=function(e){var n=ga(e)()();return function(a){return function(t){return function(r){return n(a)(t)({})(r)}}}},ro=function(e){var n=Oq(e)()();return function(){return function(){return function(a){return function(t){return function(r){return function(u){return n(kq(r)({className:a,"aria-label":t}))(u)}}}}}}};var Vq=lr();var DI=function(e){return function(n){var a=(function(){var u=dv("?")(n);return u?"&":"?"})(),t=Vq(bR(e.value)),r=Vq(bR(e.key));return n+(a+(r+("="+t)))}};var K1e=(function(){function e(){}return e.value=new e,e})(),Y1e=(function(){function e(){}return e.value=new e,e})(),X1e=(function(){function e(){}return e.value=new e,e})(),Z1e=(function(){function e(){}return e.value=new e,e})(),eEe=(function(){function e(){}return e.value=new e,e})(),nEe=(function(){function e(){}return e.value=new e,e})(),aEe=(function(){function e(){}return e.value=new e,e})(),tEe=(function(){function e(){}return e.value=new e,e})(),rEe=(function(){function e(){}return e.value=new e,e})(),oEe=(function(){function e(){}return e.value=new e,e})(),uEe=(function(){function e(){}return e.value=new e,e})(),iEe=(function(){function e(){}return e.value=new e,e})(),lEe=(function(){function e(){}return e.value=new e,e})(),cEe=(function(){function e(){}return e.value=new e,e})(),sEe=(function(){function e(){}return e.value=new e,e})(),vEe=(function(){function e(){}return e.value=new e,e})(),fEe=(function(){function e(){}return e.value=new e,e})(),_Ee=(function(){function e(){}return e.value=new e,e})(),pEe=(function(){function e(){}return e.value=new e,e})(),mEe=(function(){function e(){}return e.value=new e,e})(),dEe=(function(){function e(){}return e.value=new e,e})(),hEe=(function(){function e(){}return e.value=new e,e})(),gEe=(function(){function e(){}return e.value=new e,e})(),DEe=(function(){function e(){}return e.value=new e,e})(),REe=(function(){function e(){}return e.value=new e,e})(),yEe=(function(){function e(){}return e.value=new e,e})(),wEe=(function(){function e(){}return e.value=new e,e})(),bEe=(function(){function e(){}return e.value=new e,e})(),EEe=(function(){function e(){}return e.value=new e,e})(),IEe=(function(){function e(){}return e.value=new e,e})(),TEe=(function(){function e(){}return e.value=new e,e})(),SEe=(function(){function e(){}return e.value=new e,e})(),CEe=(function(){function e(){}return e.value=new e,e})(),FEe=(function(){function e(){}return e.value=new e,e})(),GEe=(function(){function e(){}return e.value=new e,e})(),MEe=(function(){function e(){}return e.value=new e,e})(),AEe=(function(){function e(){}return e.value=new e,e})(),LEe=(function(){function e(){}return e.value=new e,e})(),PEe=(function(){function e(){}return e.value=new e,e})(),NEe=(function(){function e(){}return e.value=new e,e})(),OEe=(function(){function e(){}return e.value=new e,e})(),UEe=(function(){function e(){}return e.value=new e,e})(),kEe=(function(){function e(){}return e.value=new e,e})(),BEe=(function(){function e(){}return e.value=new e,e})(),HEe=(function(){function e(){}return e.value=new e,e})(),JEe=(function(){function e(){}return e.value=new e,e})(),qEe=(function(){function e(){}return e.value=new e,e})(),$Ee=(function(){function e(){}return e.value=new e,e})(),WEe=(function(){function e(){}return e.value=new e,e})(),xEe=(function(){function e(){}return e.value=new e,e})(),jEe=(function(){function e(){}return e.value=new e,e})(),zEe=(function(){function e(){}return e.value=new e,e})(),VEe=(function(){function e(){}return e.value=new e,e})(),QEe=(function(){function e(){}return e.value=new e,e})(),KEe=(function(){function e(){}return e.value=new e,e})(),YEe=(function(){function e(){}return e.value=new e,e})();var Ba=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ll=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})();var Qq=function(e){if(e instanceof Ba&&e.value0 instanceof K1e)return"AcceptanceRate";if(e instanceof Ba&&e.value0 instanceof Y1e)return"AcceptanceRateMen";if(e instanceof Ba&&e.value0 instanceof X1e)return"AcceptanceRateWomen";if(e instanceof Ba&&e.value0 instanceof Z1e)return"Address";if(e instanceof Ba&&e.value0 instanceof eEe)return"AdmissionChances";if(e instanceof Ba&&e.value0 instanceof nEe)return"AdmissionDifficulty";if(e instanceof Ba&&e.value0 instanceof aEe)return"AdmissionsNotificationDate";if(e instanceof Ba&&e.value0 instanceof tEe)return"AdmissionsWebsite";if(e instanceof Ba&&e.value0 instanceof rEe)return"AppDeadlineIsRolling";if(e instanceof Ba&&e.value0 instanceof oEe)return"ApplicationEffort";if(e instanceof Ba&&e.value0 instanceof uEe)return"ApplicationRound";if(e instanceof Ba&&e.value0 instanceof iEe)return"BasketballConference";if(e instanceof Ba&&e.value0 instanceof lEe)return"CampusSetting";if(e instanceof Ba&&e.value0 instanceof cEe)return"City";if(e instanceof Ba&&e.value0 instanceof sEe)return"ClassRank";if(e instanceof Ba&&e.value0 instanceof vEe)return"CoEdSingleSex";if(e instanceof Ba&&e.value0 instanceof fEe)return"CollegeType";if(e instanceof Ba&&e.value0 instanceof _Ee)return"CommuterCollege";if(e instanceof Ba&&e.value0 instanceof pEe)return"Diversity";if(e instanceof Ba&&e.value0 instanceof mEe)return"DropoutRate";if(e instanceof Ba&&e.value0 instanceof hEe)return"FinancialAidWebsite";if(e instanceof Ba&&e.value0 instanceof gEe)return"FirstYearEnrollment";if(e instanceof Ba&&e.value0 instanceof DEe)return"FootballConference";if(e instanceof Ba&&e.value0 instanceof REe)return"FourYearGraduationRate";if(e instanceof Ba&&e.value0 instanceof yEe)return"HasDivisionOneBasketball";if(e instanceof Ba&&e.value0 instanceof wEe)return"HasDivisionOneFootball";if(e instanceof Ba&&e.value0 instanceof bEe)return"HasMedicalSchool";if(e instanceof Ba&&e.value0 instanceof EEe)return"HasStudyAbroad";if(e instanceof Ba&&e.value0 instanceof IEe)return"HBCU";if(e instanceof Ba&&e.value0 instanceof TEe)return"InListStatus";if(e instanceof Ba&&e.value0 instanceof SEe)return"MainWebsite";if(e instanceof Ba&&e.value0 instanceof dEe)return"Majors";if(e instanceof Ba&&e.value0 instanceof CEe)return"Name";if(e instanceof Ba&&e.value0 instanceof FEe)return"NetCostEstimate";if(e instanceof Ba&&e.value0 instanceof GEe)return"Notes";if(e instanceof Ba&&e.value0 instanceof MEe)return"PercentInternationalStudents";if(e instanceof Ba&&e.value0 instanceof AEe)return"Phone";if(e instanceof Ba&&e.value0 instanceof LEe)return"Photo";if(e instanceof Ba&&e.value0 instanceof PEe)return"Prestige";if(e instanceof Ba&&e.value0 instanceof NEe)return"ProgramLength";if(e instanceof Ba&&e.value0 instanceof OEe)return"PublicPrivate";if(e instanceof Ba&&e.value0 instanceof UEe)return"RecommendationLetters";if(e instanceof Ba&&e.value0 instanceof kEe)return"Region";if(e instanceof Ba&&e.value0 instanceof BEe)return"ReligiousAffiliation";if(e instanceof Ba&&e.value0 instanceof HEe)return"SatActDeadline";if(e instanceof Ba&&e.value0 instanceof JEe)return"SatActTestPolicy";if(e instanceof Ba&&e.value0 instanceof qEe)return"SatSubjectTestDeadline";if(e instanceof Ba&&e.value0 instanceof $Ee)return"SixYearGraduationRate";if(e instanceof Ba&&e.value0 instanceof WEe)return"State";if(e instanceof Ba&&e.value0 instanceof xEe)return"StudentFacultyRatio";if(e instanceof Ba&&e.value0 instanceof jEe)return"SubmissionDeadline";if(e instanceof Ba&&e.value0 instanceof zEe)return"TOEFLPolicy";if(e instanceof Ba&&e.value0 instanceof VEe)return"TotalUndergrads";if(e instanceof Ba&&e.value0 instanceof QEe)return"TuitionInState";if(e instanceof Ba&&e.value0 instanceof KEe)return"TuitionOutOfState";if(e instanceof Ba&&e.value0 instanceof YEe)return"YieldRate";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof N2)return"RankingArchitecture";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof O2)return"RankingBusiness";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof U2)return"RankingChemistry";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof k2)return"RankingComputerScience";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof B2)return"RankingCriminalJusticeAndCorrections";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof H2)return"RankingEconomics";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof J2)return"RankingEngineering";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof q2)return"RankingEnglish";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof $2)return"RankingFilm";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof W2)return"RankingFinance";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof x2)return"RankingHistory";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof j2)return"RankingPoliticalScience";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof z2)return"RankingPreMed";if(e instanceof ll&&e.value0 instanceof kr&&e.value0.value0 instanceof V2)return"RankingPsychology";if(e instanceof ll&&e.value0 instanceof Q2)return"OverallRanking";throw new Error("Failed pattern match at Hub.Facet (line 315, column 6 - line 387, column 43): "+[e.constructor.name])};var ZEe=(function(){function e(){}return e.value=new e,e})(),eIe=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),nIe=(function(){function e(){}return e.value=new e,e})();var Kq=function(e){if(e instanceof ZEe)return"filters";if(e instanceof eIe)return"filter:"+Qq(e.value0);if(e instanceof nIe)return"rankings";throw new Error("Failed pattern match at Hub.Visuals.MobileOverlay (line 36, column 26 - line 39, column 39): "+[e.constructor.name])};function Yq(e,n){typeof CV<"u"&&CV.tracking&&CV.tracking.event(e,n)}var rIe=El();var zf=function(e){var n=Hn(e);return function(a){return function(t){return n(function(){return Yq(a,t)})}}},Vf=function(e){var n=zf(e);return function(){return function(a){return function(t){return n(a)(rIe(t))}}}};var UR=(function(){function e(){}return e.value=new e,e})(),I0=(function(){function e(){}return e.value=new e,e})(),kR=(function(){function e(){}return e.value=new e,e})(),KIe=(function(){function e(){}return e.value=new e,e})(),r$=function(e){if(e instanceof UR)return"modal-sm";if(e instanceof I0)return"";if(e instanceof kR)return"modal-lg";if(e instanceof KIe)return"modal-xl";throw new Error("Failed pattern match at Bootstrap.Modal.Size (line 14, column 13 - line 18, column 27): "+[e.constructor.name])};var F$=pl(C$(),1),G$=F$.default;var ATe=uc(),M$=function(e){var n=ATe(e);return function(){return function(){return n(G$)}}};function fL(e){return function(){return function(n){return e(n)()}}}function _L(e){return function(n){return function(a){return function(t){return function(){return t.addEventListener(e,n,a)}}}}}function pL(e){return function(n){return function(a){return function(t){return function(){return t.removeEventListener(e,n,a)}}}}}var A$="message";var L$="hashchange";var P$="popstate";var N$="keyup",O$="keydown";var U$="mouseup";var k$="mousemove";var B$=Hn(qe),H$=B(ca),HTe=tt(uo),qR=(function(){var e=function(t){return function(r){return function(u){return B$(function(){var l=r(),s=fL(function(h){return u(h)})();return _L(t)(s)(!1)(l)(),B$(pL(t)(s)(!1)(l))})}}},n=function(t){return e(t)(H$(Dk)(Mi))},a=function(t){return e(t)(H$(fk)(HTe(s0)(Mi)))};return{hashchange:n(L$),mousemove:n(k$),mouseup:n(U$),popstate:n(P$),resize:n("resize"),message:n(A$),keydown:a(O$),keyup:a(N$),selectionchange:a("selectionchange"),visibilitychange:a("visibilitychange")}})();var TI=function(){return Ke};var SI=Pe(on),hL=eu(),JTe=M$(on)()(),dL=zr(on)()(),qTe=zr(Se)()(),$Te=Pe(Se),WTe=ga(ie)()(),xTe=Sr(ba),jTe=Hn(qe),q$=TI(),xs=function(){return function(e){var n=SI("modal-backdrop fade show")(Aa),a=hL(e),t=a.id+"-description",r=Ll(a.footer),u=Ll(a.header),i=a.id+"-label",l={style:Za(a.dialogStyle)(Yt({})),role:"dialog","aria-modal":"true","aria-labelledby":(function(){if(u instanceof T)return i;if(u instanceof G)return"";throw new Error("Failed pattern match at Bootstrap.Modal (line 71, column 9 - line 73, column 24): "+[u.constructor.name])})(),"aria-describedby":t},s=Za(a.size)(I0.value),h=vo(" ")([(function(){var R=Za(a.scrollable)(!0);return R?"modal-dialog-scrollable":""})(),(function(){var R=Za(a.centered)(!0);return R?"modal-dialog-centered":""})(),r$(s),Za(a.dialogClass)("")]),p=JTe({focusTrapOptions:{escapeDeactivates:!1,fallbackFocus:".modal-content",allowOutsideClick:!0}})(SI("modal fade show d-block")(dL("modal-dialog "+h)(l)(qTe("modal-content "+Za(a.contentClass)(""))({style:Za(a.contentStyle)(Yt({}))})([ja(u)(dL("modal-header "+Za(a.headerClass)(""))({id:i})),dL("modal-body "+Za(a.bodyClass)(""))({id:t})(a.body),ja(r)(SI("modal-footer "+Za(a.footerClass)("")))]))));return Oe([p,n])}},gL=xs(),js=function(){return function(e){var n=hL(e),a=$Te("d-flex w-100 justify-content-between align-items-center")([SI("mr-4")(Za(n.title)(Aa)),WTe("btn btn-link large mr-n3 py-0 fe fe-x t--close "+Za(n.dismissButtonClass)("text-body"))(Vr("Close"))({type:"button",onClick:un(function(r){return n.onDismiss})})("")]),t=function(r){return xTe(r.key==="Escape")(jTe(n.onDismiss))};return DJ(MR(qR.keyup)(t))(function(r){var u=Za(n.bodyScrollable)(!1);return gL(u?(function(){var i=hL(q$(n));return{body:i.body,bodyClass:i.bodyClass,centered:i.centered,contentClass:i.contentClass,contentStyle:i.contentStyle,dialogClass:i.dialogClass,dialogStyle:i.dialogStyle,footer:i.footer,footerClass:i.footerClass,headerClass:i.headerClass,id:i.id,scrollable:i.scrollable,size:i.size,header:a}})():q$({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,id:n.id,onDismiss:n.onDismiss,scrollable:n.scrollable,size:n.size,title:n.title,body:Oe([a,n.body])}))})}},Eh=function(e){var n=KD(e);return function(a){return function(t){return function(r){return gL({id:t.id,bodyClass:a,body:Oe(n(r))})}}}};var VTe=eu(),QTe=hn(En),KTe=e0(Se)()(),YTe=ga(on)()(),XTe=su()();var CI="login",DL=function(){return function(e){var n=VTe(e),a=(function(){var u=Za(n.auth0ActiveTab)(CI);return u})(),t=je({path:"",token:"",impersonationToken:""})(YE("login_path")),r=function(u){return function(i){return Wn(QTe)(function(l){return DI((function(s){return{key:u,value:s}})(l))})(Ll(i))}};return KTe("d-inline")({method:"post",action:r("origin")(n.origin)(r("login_hint")(n.auth0LoginHint)(DI({key:"screen_hint",value:a})(t.path))),target:(function(){var u=Za(n.openInNewTab)(!1);return u?"_blank":""})()})([YTe(Za(n.className)("btn btn-primary px-4"))(vn)({type:"submit",disabled:Za(n.disabled)(!1)})(Za(n.content)(cn(Za(n.text)("Log in")))),XTe("")({type:"hidden",name:"authenticity_token",value:t.token})])}};var _m=function(e){return function(n){return function(){return n[e]}}},aSe=_m("URL"),tSe=_m("documentURI"),rSe=_m("origin"),oSe=_m("compatMode"),uSe=_m("characterSet"),iSe=_m("contentType");var lSe=_m("documentElement");var FI=function(e){return function(n){return n[e]}},fSe=FI("namespaceURI"),_Se=FI("prefix"),pSe=FI("localName"),mSe=FI("tagName");function yL(e){return function(){return e.id}}function wL(e){return function(){return e.classList}}function bL(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 EL=Ke;var W$=Kn("Element");var zs=function(e){return function(n){return function(){return n[e]}}};var RSe=zs("baseURI"),ySe=zs("ownerDocument"),x$=zs("parentNode"),wSe=zs("parentElement");var bSe=zs("childNodes"),ESe=zs("firstChild"),ISe=zs("lastChild"),TSe=zs("previousSibling"),SSe=zs("nextSibling"),CSe=zs("nodeValue");var FSe=zs("textContent");function TL(e){return function(n){return function(){return e.isEqualNode(n)}}}var PSe=B(ca);var j$=(function(){var e=PSe(he);return function(n){return e(x$(n))}})();var mm=(function(){function e(){}return e.value=new e,e})(),V$=(function(){function e(){}return e.value=new e,e})(),Q$=(function(){function e(){}return e.value=new e,e})(),$R=(function(){function e(){}return e.value=new e,e})(),K$=(function(){function e(){}return e.value=new e,e})(),Y$=(function(){function e(){}return e.value=new e,e})(),X$=(function(){function e(){}return e.value=new e,e})();var GI=function(e){if(e instanceof mm)return G.value;if(e instanceof V$)return new T("for-you");if(e instanceof Q$)return new T("chancing");if(e instanceof $R)return new T("finances");if(e instanceof K$)return new T("majors");if(e instanceof Y$)return new T("admission-requirements");if(e instanceof X$)return new T("essay-prompts");throw new Error("Failed pattern match at SchoolDetails.Types (line 98, column 14 - line 105, column 39): "+[e.constructor.name])};var CL=ge(ue);var FL=dd(cr),vCe=ut(),fCe=jl(ue),GL=function(e){return"/schools/"+e.slug},ML="/schools/hub";var Z$=function(e){return function(n){var a=CL(Lq(n.whatificator))(function(l){return"simulator="+l}),t=CL(n.mobileOverlay)(function(l){return"overlay="+Kq(l)}),r=vo("&")(ri([t,a])),u=CL(n.focusedSchool)(function(l){return FL("/")(ri([new T(vCe(l.slug)),GI(l.tab)]))}),i=(function(){return e.knownSeoState instanceof T&&n.seoView?FL("/")(ri([new T(GL({slug:e.knownSeoState.value0.slug})),u])):FL("/")(ri([new T(ML),new T(Wn(e.basePath)(mI)(n.ranking)),fCe(u)("d"),u]))})();return i+((function(){var l=r==="";return l?"":"?"})()+r)}};var nW="/profile";var dCe=ut();var AL=function(e){return function(n){return vo("/")(ri([new T("/schools"),new T(dCe(n)),GI(e)]))}},aW=nW,tW="/livestreams/upcoming";var hCe=function(e){return Z$({basePath:"all",knownSeoState:G.value})({ranking:G.value,focusedSchool:e,mobileOverlay:G.value,seoView:!1,whatificator:dI.value})};var MI=function(e){return function(n){return hCe(new T({tab:e,slug:n}))}};var rW=(function(){function e(){}return e.value=new e,e})(),oW=(function(){function e(){}return e.value=new e,e})(),AI=(function(){function e(){}return e.value=new e,e})(),LI=(function(){function e(){}return e.value=new e,e})(),uW=(function(){function e(){}return e.value=new e,e})(),iW=(function(){function e(){}return e.value=new e,e})(),lW=(function(){function e(){}return e.value=new e,e})(),cW=function(e){if(e instanceof rW)return"avatar-xxs";if(e instanceof oW)return"avatar-xs";if(e instanceof AI)return"avatar-sm";if(e instanceof LI)return"";if(e instanceof uW)return"avatar-lg";if(e instanceof iW)return"avatar-xl";if(e instanceof lW)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 vW={show:ut()};var ICe=Number.MAX_SAFE_INTEGER;var OL=function(e){if(e.first==="")return e.last;if(e.last==="")return e.first;if(Ve)return e.first+(" "+e.last);throw new Error("Failed pattern match at Profile.Types.Name (line 10, column 1 - line 10, column 27): "+[e.constructor.name])};var hFe=we(EE);var DW={show:function(e){return e}};var RW=function(e){return hFe(e.publishScope)(_c.value)};var Ih=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),UL=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),kL=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),BL=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),HL=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),JL=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),qL=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})();var $L=oe(vW);var gFe=oe(X5),wW=oe(F5),DFe=oe(DW);var RFe="/messages";var yFe=function(e){return function(n){return e+("/"+(function(){if(n instanceof Ih)return"admission-officer/"+gFe(n.value0);if(n instanceof UL)return"school/"+wW(n.value0);if(n instanceof kL)return"student/"+DFe(n.value0);if(n instanceof BL)return"high-school/"+$L(n.value0);if(n instanceof HL)return"service-provider/"+$L(n.value0);if(n instanceof JL)return"parent/"+$L(n.value0);if(n instanceof qL)return"recruiter/"+wW(n.value0);throw new Error("Failed pattern match at DirectMessages.Urls (line 29, column 59 - line 36, column 63): "+[n.constructor.name])})())}},WL=yFe(RFe);var bFe=Ws(kv(Ov)),EFe=ae(Na),bW=ge(ue),EW=ut(),IFe=zt(st);var IW=bFe("network_connections_invite_school_path")(function(e){return function(n){return EFe(e({school_id:n.schoolId,message:et(n.introMessage),sem_user_id:et(bW(n.semUserId)(EW)),livestream_id:et(bW(n.livestreamId)(EW))}))(to)}}),TW=function(e){return function(n){return IFe(IW({schoolId:e,introMessage:G.value,semUserId:G.value,livestreamId:new T(n)}))}};var SW=function(e){return function(n){return function(a){return IW({schoolId:e,introMessage:new T(a.introMessage),semUserId:new T(n),livestreamId:G.value})}}};Et();function pi(){return pi=Object.assign?Object.assign.bind():function(e){for(var n=1;n1&&arguments[1]!==void 0?arguments[1]:1;PW+=1;var a=PW;function t(r){if(r===0)UW(a),e();else{var u=NW(function(){t(r-1)});jL.set(a,u)}}return t(n),a}dc.cancel=function(e){var n=jL.get(e);return UW(n),OW(n)};function gm(e,n){return e?e.contains(n):!1}function xR(e){return e instanceof HTMLElement?e:oc.findDOMNode(e)}var qW=pl(JW());Et();function KL(e,n){typeof e=="function"?e(n):To(e)==="object"&&e&&"current"in e&&(e.current=n)}function VI(){for(var e=arguments.length,n=new Array(e),a=0;ae.length)&&(n=e.length);for(var a=0,t=Array(n);a"u"||typeof window>"u")return!1;var e=navigator.userAgent||navigator.vendor||window.opera;return!!(/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(e)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(e==null?void 0:e.substr(0,4)))});Et();var vx=pl(Dm());Et();Et();var cx=pl(Dm());function YW(e,n){var a={};return a[e.toLowerCase()]=n.toLowerCase(),a["Webkit".concat(e)]="webkit".concat(n),a["Moz".concat(e)]="moz".concat(n),a["ms".concat(e)]="MS".concat(n),a["O".concat(e)]="o".concat(n.toLowerCase()),a}function LFe(e,n){var a={animationend:YW("Animation","AnimationEnd"),transitionend:YW("Transition","TransitionEnd")};return e&&("AnimationEvent"in n||delete a.animationend.animation,"TransitionEvent"in n||delete a.transitionend.transition),a}var PFe=LFe(qv(),typeof window<"u"?window:{}),ZW={};qv()&&(XW=document.createElement("div"),ZW=XW.style);var XW,YI={};function ex(e){if(YI[e])return YI[e];var n=PFe[e];if(n)for(var a=Object.keys(n),t=a.length,r=0;r1&&arguments[1]!==void 0?arguments[1]:2;n();var u=dc(function(){r<=1?t({isCanceled:function(){return u!==e.current}}):a(t,r-1)});e.current=u}return Lr(function(){return function(){n()}},[]),[a,n]});Et();var NFe=qv()?HD:Lr,eT=NFe;var rx=[ls,Yf,C0,ZI],a3=!1,ox=!0;function nT(e){return e===C0||e===ZI}var ux=(function(e,n){var a=Xf(n3),t=Hr(a,2),r=t[0],u=t[1],i=tx(),l=Hr(i,2),s=l[0],h=l[1];function p(){u(ls,!0)}return eT(function(){if(r!==n3&&r!==ZI){var R=rx.indexOf(r),E=rx[R+1],w=n(r);w===a3?u(E,!0):s(function(I){function L(){I.isCanceled()||u(E,!0)}w===!0?L():Promise.resolve(w).then(L)})}},[e,r]),Lr(function(){return function(){h()}},[]),[p,r]});Et();Et();var ix=(function(e){var n=Kt(),a=Kt(e);a.current=e;var t=BD(function(i){a.current(i)},[]);function r(i){i&&(i.removeEventListener(ZL,t),i.removeEventListener(XL,t))}function u(i){n.current&&n.current!==i&&r(n.current),i&&i!==n.current&&(i.addEventListener(ZL,t),i.addEventListener(XL,t),n.current=i)}return Lr(function(){return function(){r(n.current)}},[]),[u,r]});function t3(e,n,a,t){var r=t.motionEnter,u=r===void 0?!0:r,i=t.motionAppear,l=i===void 0?!0:i,s=t.motionLeave,h=s===void 0?!0:s,p=t.motionDeadline,R=t.motionLeaveImmediately,E=t.onAppearPrepare,w=t.onEnterPrepare,I=t.onLeavePrepare,L=t.onAppearStart,U=t.onEnterStart,V=t.onLeaveStart,Q=t.onAppearActive,te=t.onEnterActive,le=t.onLeaveActive,ne=t.onAppearEnd,Z=t.onEnterEnd,ee=t.onLeaveEnd,me=t.onVisibleChanged,$e=Xf(),Qe=Hr($e,2),dn=Qe[0],qn=Qe[1],Mn=Xf(S0),An=Hr(Mn,2),kn=An[0],Ia=An[1],Da=Xf(null),da=Hr(Da,2),Dt=da[0],_t=da[1],Ha=Kt(!1),Tr=Kt(null);function Xe(){return a()}var Wa=Kt(!1);function Mt(jt){var W=Xe();if(!(jt&&!jt.deadline&&jt.target!==W)){var X=Wa.current,k;kn===jR&&X?k=ne==null?void 0:ne(W,jt):kn===zR&&X?k=Z==null?void 0:Z(W,jt):kn===VR&&X&&(k=ee==null?void 0:ee(W,jt)),kn!==S0&&X&&k!==!1&&(Ia(S0,!0),_t(null,!0))}}var zn=ix(Mt),On=Hr(zn,1),Ze=On[0],Ma=JD(function(){var jt,W,X;switch(kn){case jR:return jt={},cl(jt,ls,E),cl(jt,Yf,L),cl(jt,C0,Q),jt;case zR:return W={},cl(W,ls,w),cl(W,Yf,U),cl(W,C0,te),W;case VR:return X={},cl(X,ls,I),cl(X,Yf,V),cl(X,C0,le),X;default:return{}}},[kn]),Ja=ux(kn,function(jt){if(jt===ls){var W=Ma[ls];return W?W(Xe()):a3}if(In in Ma){var X;_t(((X=Ma[In])===null||X===void 0?void 0:X.call(Ma,Xe(),null))||null)}return In===C0&&(Ze(Xe()),p>0&&(clearTimeout(Tr.current),Tr.current=setTimeout(function(){Mt({deadline:!0})},p))),ox}),pt=Hr(Ja,2),tr=pt[0],In=pt[1],Oa=nT(In);Wa.current=Oa,eT(function(){qn(n);var jt=Ha.current;if(Ha.current=!0,!!e){var W;!jt&&n&&l&&(W=jR),jt&&n&&u&&(W=zR),(jt&&!n&&h||!jt&&R&&!n&&h)&&(W=VR),W&&(Ia(W),tr())}},[n]),Lr(function(){(kn===jR&&!l||kn===zR&&!u||kn===VR&&!h)&&Ia(S0)},[l,u,h]),Lr(function(){return function(){Ha.current=!1,clearTimeout(Tr.current)}},[]);var dr=Kt(!1);Lr(function(){dn&&(dr.current=!0),dn!==void 0&&kn===S0&&((dr.current||dn)&&(me==null||me(dn)),dr.current=!0)},[dn,kn]);var za=Dt;return Ma[ls]&&In===Yf&&(za=at({transition:"none"},za)),[kn,In,za,dn!=null?dn:n]}Et();var OFe=(function(e){Ch(a,e);var n=Fh(a);function a(){return Th(this,a),n.apply(this,arguments)}return Sh(a,[{key:"render",value:function(){return this.props.children}}]),a})(Mp),lx=OFe;function UFe(e){var n=e;To(e)==="object"&&(n=e.transitionSupport);function a(r){return!!(r.motionName&&n)}var t=rc(function(r,u){var i=r.visible,l=i===void 0?!0:i,s=r.removeOnLeave,h=s===void 0?!0:s,p=r.forceRender,R=r.children,E=r.motionName,w=r.leavedClassName,I=r.eventProps,L=a(r),U=Kt(),V=Kt();function Q(){try{return U.current instanceof HTMLElement?U.current:xR(V.current)}catch{return null}}var te=t3(L,l,Q,r),le=Hr(te,4),ne=le[0],Z=le[1],ee=le[2],me=le[3],$e=Kt(me);me&&($e.current=!0);var Qe=BD(function(Da){U.current=Da,KL(u,Da)},[u]),dn,qn=at(at({},I),{},{visible:l});if(!R)dn=null;else if(ne===S0||!a(r))me?dn=R(at({},qn),Qe):!h&&$e.current?dn=R(at(at({},qn),{},{className:w}),Qe):p?dn=R(at(at({},qn),{},{style:{display:"none"}}),Qe):dn=null;else{var Mn,An;Z===ls?An="prepare":nT(Z)?An="active":Z===Yf&&(An="start"),dn=R(at(at({},qn),{},{className:(0,cx.default)(e3(E,ne),(Mn={},cl(Mn,e3(E,"".concat(ne,"-").concat(An)),An),cl(Mn,E,typeof E=="string"),Mn)),style:ee}),Qe)}if(KG(dn)&&QI(dn)){var kn=dn,Ia=kn.ref;Ia||(dn=kD(dn,{ref:Qe}))}return nr(lx,{ref:V},dn)});return t.displayName="CSSMotion",t}var aT=UFe(XI);Et();var tT="add",rT="keep",oT="remove",iT="removed";function kFe(e){var n;return e&&To(e)==="object"&&"key"in e?n=e:n={key:e},at(at({},n),{},{key:String(n.key)})}function uT(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(kFe)}function sx(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],a=[],t=0,r=n.length,u=uT(e),i=uT(n);u.forEach(function(h){for(var p=!1,R=t;R1});return s.forEach(function(h){a=a.filter(function(p){var R=p.key,E=p.status;return R!==h||E!==oT}),a.forEach(function(p){p.key===h&&(p.status=rT)})}),a}var BFe=["component","children","onVisibleChanged","onAllRemoved"],HFe=["status"],JFe=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function qFe(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:aT,a=(function(t){Ch(u,t);var r=Fh(u);function u(){var i;Th(this,u);for(var l=arguments.length,s=new Array(l),h=0;h=0&&a.left>=0&&a.bottom>a.top&&a.right>a.left?a:null}function fGe(e,n,a,t){var r=Tt.clone(e),u={width:n.width,height:n.height};return t.adjustX&&r.left=a.left&&r.left+u.width>a.right&&(u.width-=r.left+u.width-a.right),t.adjustX&&r.left+u.width>a.right&&(r.left=Math.max(a.right-u.width,a.left)),t.adjustY&&r.top=a.top&&r.top+u.height>a.bottom&&(u.height-=r.top+u.height-a.bottom),t.adjustY&&r.top+u.height>a.bottom&&(r.top=Math.max(a.bottom-u.height,a.top)),Tt.mix(r,u)}function m3(e){var n,a,t;if(!Tt.isWindow(e)&&e.nodeType!==9)n=Tt.offset(e),a=Tt.outerWidth(e),t=Tt.outerHeight(e);else{var r=Tt.getWindow(e);n={left:Tt.getWindowScrollLeft(r),top:Tt.getWindowScrollTop(r)},a=Tt.viewportWidth(r),t=Tt.viewportHeight(r)}return n.width=a,n.height=t,n}function wx(e,n){var a=n.charAt(0),t=n.charAt(1),r=e.width,u=e.height,i=e.left,l=e.top;return a==="c"?l+=u/2:a==="b"&&(l+=u),t==="c"?i+=r/2:t==="r"&&(i+=r),{left:i,top:l}}function sT(e,n,a,t,r){var u=wx(n,a[1]),i=wx(e,a[0]),l=[i.left-u.left,i.top-u.top];return{left:Math.round(e.left-l[0]+t[0]-r[0]),top:Math.round(e.top-l[1]+t[1]-r[1])}}function bx(e,n,a){return e.lefta.right}function Ex(e,n,a){return e.topa.bottom}function _Ge(e,n,a){return e.left>a.right||e.left+n.widtha.bottom||e.top+n.height=a.right||t.top>=a.bottom}function dT(e,n,a){var t=a.target||n,r=m3(t),u=!mGe(t,a.overflow&&a.overflow.alwaysByViewport);return Px(e,r,a,u)}dT.__getOffsetParent=v3;dT.__getVisibleRectForElement=p3;function Nx(e,n,a){var t,r,u=Tt.getDocument(e),i=u.defaultView||u.parentWindow,l=Tt.getWindowScrollLeft(i),s=Tt.getWindowScrollTop(i),h=Tt.viewportWidth(i),p=Tt.viewportHeight(i);"pageX"in n?t=n.pageX:t=l+n.clientX,"pageY"in n?r=n.pageY:r=s+n.clientY;var R={left:t,top:r,width:0,height:0},E=t>=0&&t<=l+h&&r>=0&&r<=s+p,w=[a.points[0],"cc"];return Px(e,R,px(px({},a),{},{points:w}),E)}var wQ=pl(cQ());var vQ=(function(){if(typeof Map<"u")return Map;function e(n,a){var t=-1;return n.some(function(r,u){return r[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),r=this.__entries__[t];return r&&r[1]},n.prototype.set=function(a,t){var r=e(this.__entries__,a);~r?this.__entries__[r][1]=t:this.__entries__.push([a,t])},n.prototype.delete=function(a){var t=this.__entries__,r=e(t,a);~r&&t.splice(r,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 r=0,u=this.__entries__;r0},e.prototype.connect_=function(){!N3||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),q3e?(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(){!N3||!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,r=J3e.some(function(u){return!!~t.indexOf(u)});r&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e})(),fQ=(function(e,n){for(var a=0,t=Object.keys(n);a"u"||!(Element instanceof Object))){if(!(n instanceof Bh(n).Element))throw new TypeError('parameter 1 is not of type "Element".');var a=this.observations_;a.has(n)||(a.set(n,new Y3e(n)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(n){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(n instanceof Bh(n).Element))throw new TypeError('parameter 1 is not of type "Element".');var a=this.observations_;a.has(n)&&(a.delete(n),a.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var n=this;this.clearActive(),this.observations_.forEach(function(a){a.isActive()&&n.activeObservations_.push(a)})},e.prototype.broadcastActive=function(){if(this.hasActive()){var n=this.callbackCtx_,a=this.activeObservations_.map(function(t){return new X3e(t.target,t.broadcastRect())});this.callback_.call(n,a,n),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e})(),pQ=typeof WeakMap<"u"?new WeakMap:new vQ,mQ=(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=$3e.getInstance(),t=new Z3e(n,a,this);pQ.set(this,t)}return e})();["observe","unobserve","disconnect"].forEach(function(e){mQ.prototype[e]=function(){var n;return(n=pQ.get(this))[e].apply(n,arguments)}});var ePe=(function(){return typeof wT.ResizeObserver<"u"?wT.ResizeObserver:mQ})(),dQ=ePe;function hQ(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 gQ(e,n){e!==document.activeElement&&gm(n,e)&&typeof e.focus=="function"&&e.focus()}function O3(e,n){var a=null,t=null;function r(i){var l=Hr(i,1),s=l[0].target;if(document.documentElement.contains(s)){var h=s.getBoundingClientRect(),p=h.width,R=h.height,E=Math.floor(p),w=Math.floor(R);(a!==E||t!==w)&&Promise.resolve().then(function(){n({width:E,height:w})}),a=E,t=w}}var u=new dQ(r);return e&&u.observe(e),function(){u.disconnect()}}Et();var DQ=(function(e,n){var a=vt.useRef(!1),t=vt.useRef(null);function r(){window.clearTimeout(t.current)}function u(i){if(r(),!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,r()}]});function RQ(e){return typeof e!="function"?null:e()}function yQ(e){return To(e)!=="object"||!e?null:e}var nPe=function(n,a){var t=n.children,r=n.disabled,u=n.target,i=n.align,l=n.onAlign,s=n.monitorWindowResize,h=n.monitorBufferTime,p=h===void 0?0:h,R=vt.useRef({}),E=vt.useRef(),w=vt.Children.only(t),I=vt.useRef({});I.current.disabled=r,I.current.target=u,I.current.align=i,I.current.onAlign=l;var L=DQ(function(){var Z=I.current,ee=Z.disabled,me=Z.target,$e=Z.align,Qe=Z.onAlign;if(!ee&&me){var dn=E.current,qn,Mn=RQ(me),An=yQ(me);R.current.element=Mn,R.current.point=An,R.current.align=$e;var kn=document,Ia=kn.activeElement;return Mn&&fx(Mn)?qn=dT(dn,Mn,$e):An&&(qn=Nx(dn,An,$e)),gQ(Ia,dn),Qe&&qn&&Qe(dn,qn),!0}return!1},p),U=Hr(L,2),V=U[0],Q=U[1],te=vt.useRef({cancel:function(){}}),le=vt.useRef({cancel:function(){}});vt.useEffect(function(){var Z=RQ(u),ee=yQ(u);E.current!==le.current.element&&(le.current.cancel(),le.current.element=E.current,le.current.cancel=O3(E.current,V)),(R.current.element!==Z||!hQ(R.current.point,ee)||!(0,wQ.default)(R.current.align,i))&&(V(),te.current.element!==Z&&(te.current.cancel(),te.current.element=Z,te.current.cancel=O3(Z,V)))}),vt.useEffect(function(){r?Q():V()},[r]);var ne=vt.useRef(null);return vt.useEffect(function(){s?ne.current||(ne.current=T0(window,"resize",V)):ne.current&&(ne.current.remove(),ne.current=null)},[s]),vt.useEffect(function(){return function(){te.current.cancel(),le.current.cancel(),ne.current&&ne.current.remove(),Q()}},[]),vt.useImperativeHandle(a,function(){return{forceAlign:function(){return V(!0)}}}),vt.isValidElement(w)&&(w=vt.cloneElement(w,{ref:VI(w.ref,E)})),w},bQ=vt.forwardRef(nPe);bQ.displayName="Align";var EQ=bQ;var IQ=EQ;Et();var aPe=qv()?HD:Lr,U3=aPe;var LQ=pl(Dm());function IT(e,n){this.v=e,this.k=n}function Vu(e,n,a,t){var r=Object.defineProperty;try{r({},"",{})}catch{r=0}Vu=function(i,l,s,h){function p(R,E){Vu(i,R,function(w){return this._invoke(R,E,w)})}l?r?r(i,l,{value:s,enumerable:!h,configurable:!h,writable:!h}):i[l]=s:(p("next",0),p("throw",1),p("return",2))},Vu(e,n,a,t)}function cy(){var e,n,a=typeof Symbol=="function"?Symbol:{},t=a.iterator||"@@iterator",r=a.toStringTag||"@@toStringTag";function u(w,I,L,U){var V=I&&I.prototype instanceof l?I:l,Q=Object.create(V.prototype);return Vu(Q,"_invoke",(function(te,le,ne){var Z,ee,me,$e=0,Qe=ne||[],dn=!1,qn={p:0,n:0,v:e,a:Mn,f:Mn.bind(e,4),d:function(kn,Ia){return Z=kn,ee=0,me=e,qn.n=Ia,i}};function Mn(An,kn){for(ee=An,me=kn,n=0;!dn&&$e&&!Ia&&n3?(Ia=Dt===kn)&&(me=Da[(ee=Da[4])?5:(ee=3,3)],Da[4]=Da[5]=e):Da[0]<=da&&((Ia=An<2&&dakn||kn>Dt)&&(Da[4]=An,Da[5]=kn,qn.n=Dt,ee=0))}if(Ia||An>1)return i;throw dn=!0,kn}return function(An,kn,Ia){if($e>1)throw TypeError("Generator is already running");for(dn&&kn===1&&Mn(kn,Ia),ee=kn,me=Ia;(n=ee<2?e:me)||!dn;){Z||(ee?ee<3?(ee>1&&(qn.n=-1),Mn(ee,me)):qn.n=me:qn.v=me);try{if($e=2,Z){if(ee||(An="next"),n=Z[An]){if(!(n=n.call(Z,me)))throw TypeError("iterator result is not an object");if(!n.done)return n;me=n.value,ee<2&&(ee=0)}else ee===1&&(n=Z.return)&&n.call(Z),ee<2&&(me=TypeError("The iterator does not provide a '"+An+"' method"),ee=1);Z=e}else if((n=(dn=qn.n<0)?me:te.call(le,qn))!==i)break}catch(Da){Z=e,ee=1,me=Da}finally{$e=1}}return{value:n,done:dn}}})(w,L,U),!0),Q}var i={};function l(){}function s(){}function h(){}n=Object.getPrototypeOf;var p=[][t]?n(n([][t]())):(Vu(n={},t,function(){return this}),n),R=h.prototype=l.prototype=Object.create(p);function E(w){return Object.setPrototypeOf?Object.setPrototypeOf(w,h):(w.__proto__=h,Vu(w,r,"GeneratorFunction")),w.prototype=Object.create(R),w}return s.prototype=h,Vu(R,"constructor",h),Vu(h,"constructor",s),s.displayName="GeneratorFunction",Vu(h,r,"GeneratorFunction"),Vu(R),Vu(R,r,"Generator"),Vu(R,t,function(){return this}),Vu(R,"toString",function(){return"[object Generator]"}),(cy=function(){return{w:u,m:E}})()}function Hh(e,n){function a(r,u,i,l){try{var s=e[r](u),h=s.value;return h instanceof IT?n.resolve(h.v).then(function(p){a("next",p,i,l)},function(p){a("throw",p,i,l)}):n.resolve(h).then(function(p){s.value=p,i(s)},function(p){return a("throw",p,i,l)})}catch(p){l(p)}}var t;this.next||(Vu(Hh.prototype),Vu(Hh.prototype,typeof Symbol=="function"&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),Vu(this,"_invoke",function(r,u,i){function l(){return new n(function(s,h){a(r,i,s,h)})}return t=t?t.then(l,l):l()},!0)}function TT(e,n,a,t,r){return new Hh(cy().w(e,n,a,t),r||Promise)}function TQ(e,n,a,t,r){var u=TT(e,n,a,t,r);return u.next().then(function(i){return i.done?i.value:u.next()})}function SQ(e){var n=Object(e),a=[];for(var t in n)a.unshift(t);return function r(){for(;a.length;)if((t=a.pop())in n)return r.value=t,r.done=!1,r;return r.done=!0,r}}function k3(e){if(e!=null){var n=e[typeof Symbol=="function"&&Symbol.iterator||"@@iterator"],a=0;if(n)return n.call(e);if(typeof e.next=="function")return e;if(!isNaN(e.length))return{next:function(){return e&&a>=e.length&&(e=void 0),{value:e&&e[a++],done:!e}}}}throw new TypeError(To(e)+" is not iterable")}function sy(){"use strict";var e=cy(),n=e.m(sy),a=(Object.getPrototypeOf?Object.getPrototypeOf(n):n.__proto__).constructor;function t(i){var l=typeof i=="function"&&i.constructor;return!!l&&(l===a||(l.displayName||l.name)==="GeneratorFunction")}var r={throw:1,return:2,break:3,continue:3};function u(i){var l,s;return function(h){l||(l={stop:function(){return s(h.a,2)},catch:function(){return h.v},abrupt:function(R,E){return s(h.a,r[R],E)},delegateYield:function(R,E,w){return l.resultName=E,s(h.d,k3(R),w)},finish:function(R){return s(h.f,R)}},s=function(R,E,w){h.p=l.prev,h.n=l.next;try{return R(E,w)}finally{l.next=h.n}}),l.resultName&&(l[l.resultName]=h.v,l.resultName=void 0),l.sent=h.v,l.next=h.n;try{return i.call(this,l)}finally{h.p=l.prev,h.n=l.next}}}return(sy=function(){return{wrap:function(s,h,p,R){return e.w(u(s),h,p,R&&R.reverse())},isGeneratorFunction:t,mark:e.m,awrap:function(s,h){return new IT(s,h)},AsyncIterator:Hh,async:function(s,h,p,R,E){return(t(h)?TT:TQ)(u(s),h,p,R,E)},keys:SQ,values:k3}})()}function CQ(e,n,a,t,r,u,i){try{var l=e[u](i),s=l.value}catch(h){return void a(h)}l.done?n(s):Promise.resolve(s).then(t,r)}function FQ(e){return function(){var n=this,a=arguments;return new Promise(function(t,r){var u=e.apply(n,a);function i(s){CQ(u,t,r,i,l,"next",s)}function l(s){CQ(u,t,r,i,l,"throw",s)}i(void 0)})}}Et();var GQ=["measure","alignPre","align",null,"motion"],MQ=(function(e,n){var a=Xf(null),t=Hr(a,2),r=t[0],u=t[1],i=Kt();function l(p){u(p,!0)}function s(){dc.cancel(i.current)}function h(p){s(),i.current=dc(function(){l(function(R){switch(r){case"align":return"motion";case"motion":return"stable";default:}return R}),p==null||p()})}return Lr(function(){l("measure")},[e]),Lr(function(){r==="measure"&&n(),r&&(i.current=dc(FQ(sy().mark(function p(){var R,E;return sy().wrap(function(I){for(;;)switch(I.prev=I.next){case 0:R=GQ.indexOf(r),E=GQ[R+1],E&&R!==-1&&l(E);case 3:case"end":return I.stop()}},p)}))))},[r]),Lr(function(){return function(){s()}},[]),[r,h]});Et();var AQ=(function(e){var n=As({width:0,height:0}),a=Hr(n,2),t=a[0],r=a[1];function u(l){r({width:l.offsetWidth,height:l.offsetHeight})}var i=JD(function(){var l={};if(e){var s=t.width,h=t.height;e.indexOf("height")!==-1&&h?l.height=h:e.indexOf("minHeight")!==-1&&h&&(l.minHeight=h),e.indexOf("width")!==-1&&s?l.width=s:e.indexOf("minWidth")!==-1&&s&&(l.minWidth=s)}return l},[e,t]);return[i,u]});var PQ=rc(function(e,n){var a=e.visible,t=e.prefixCls,r=e.className,u=e.style,i=e.children,l=e.zIndex,s=e.stretch,h=e.destroyPopupOnHide,p=e.forceRender,R=e.align,E=e.point,w=e.getRootDomNode,I=e.getClassNameFromAlign,L=e.onAlign,U=e.onMouseEnter,V=e.onMouseLeave,Q=e.onMouseDown,te=e.onTouchStart,le=e.onClick,ne=Kt(),Z=Kt(),ee=As(),me=Hr(ee,2),$e=me[0],Qe=me[1],dn=AQ(s),qn=Hr(dn,2),Mn=qn[0],An=qn[1];function kn(){s&&An(w())}var Ia=MQ(a,kn),Da=Hr(Ia,2),da=Da[0],Dt=Da[1],_t=As(0),Ha=Hr(_t,2),Tr=Ha[0],Xe=Ha[1],Wa=Kt();U3(function(){da==="alignPre"&&Xe(0)},[da]);function Mt(){return E||w}function zn(){var In;(In=ne.current)===null||In===void 0||In.forceAlign()}function On(In,Oa){var dr=I(Oa);$e!==dr&&Qe(dr),Xe(function(za){return za+1}),da==="align"&&(L==null||L(In,Oa))}U3(function(){da==="align"&&(Tr<2?zn():Dt(function(){var In;(In=Wa.current)===null||In===void 0||In.call(Wa)}))},[Tr]);var Ze=at({},lT(e));["onAppearEnd","onEnterEnd","onLeaveEnd"].forEach(function(In){var Oa=Ze[In];Ze[In]=function(dr,za){return Dt(),Oa==null?void 0:Oa(dr,za)}});function Ma(){return new Promise(function(In){Wa.current=In})}Lr(function(){!Ze.motionName&&da==="motion"&&Dt()},[Ze.motionName,da]),Gf(n,function(){return{forceAlign:zn,getElement:function(){return Z.current}}});var Ja=at(at({},Mn),{},{zIndex:l,opacity:da==="motion"||da==="stable"||!a?void 0:0,pointerEvents:!a&&da!=="stable"?"none":void 0},u),pt=!0;R!=null&&R.points&&(da==="align"||da==="stable")&&(pt=!1);var tr=i;return Gp.count(i)>1&&(tr=nr("div",{className:"".concat(t,"-content")},i)),nr(Gh,pi({visible:a,ref:Z,leavedClassName:"".concat(t,"-hidden")},Ze,{onAppearPrepare:Ma,onEnterPrepare:Ma,removeOnLeave:h,forceRender:p}),function(In,Oa){var dr=In.className,za=In.style,jt=(0,LQ.default)(t,r,$e,dr);return nr(IQ,{target:Mt(),key:"popup",ref:ne,monitorWindowResize:!0,disabled:pt,align:R,onAlign:On},nr("div",{ref:Oa,className:jt,onMouseEnter:U,onMouseLeave:V,onMouseDownCapture:Q,onTouchStartCapture:te,onClick:le,style:at(at({},za),Ja)},tr))})});PQ.displayName="PopupInner";var NQ=PQ;Et();var OQ=pl(Dm()),UQ=rc(function(e,n){var a=e.prefixCls,t=e.visible,r=e.zIndex,u=e.children,i=e.mobile;i=i===void 0?{}:i;var l=i.popupClassName,s=i.popupStyle,h=i.popupMotion,p=h===void 0?{}:h,R=i.popupRender,E=e.onClick,w=Kt();Gf(n,function(){return{forceAlign:function(){},getElement:function(){return w.current}}});var I=at({zIndex:r},s),L=u;return Gp.count(u)>1&&(L=nr("div",{className:"".concat(a,"-content")},u)),R&&(L=R(L)),nr(Gh,pi({visible:t,ref:w,removeOnLeave:!0},p),function(U,V){var Q=U.className,te=U.style,le=(0,OQ.default)(a,l,Q);return nr("div",{ref:V,className:le,onClick:E,style:at(at({},te),I)},L)})});UQ.displayName="MobilePopupInner";var kQ=UQ;var tPe=["visible","mobile"],BQ=rc(function(e,n){var a=e.visible,t=e.mobile,r=hm(e,tPe),u=As(a),i=Hr(u,2),l=i[0],s=i[1],h=As(!1),p=Hr(h,2),R=p[0],E=p[1],w=at(at({},r),{},{visible:l});Lr(function(){s(a),a&&t&&E(KW())},[a,t]);var I=R?nr(kQ,pi({},w,{mobile:t,ref:n})):nr(NQ,pi({},w,{ref:n}));return nr("div",null,nr(r3,w),I)});BQ.displayName="Popup";var HQ=BQ;Et();var rPe=VG(null),B3=rPe;function H3(){}function oPe(){return""}function uPe(e){return e?e.ownerDocument:window.document}var iPe=["onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur","onContextMenu"];function lPe(e){var n=(function(a){Ch(r,a);var t=Fh(r);function r(u){var i;Th(this,r),i=t.call(this,u),i.popupRef=d1(),i.triggerRef=d1(),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 h=i.props.mouseEnterDelay;i.fireEvents("onMouseEnter",s),i.delaySetPopupVisible(!0,h,h?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 h;s.relatedTarget&&!s.relatedTarget.setTimeout&&gm((h=i.popupRef.current)===null||h===void 0?void 0:h.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 h;if(i.preClickTime&&i.preTouchTime?h=Math.min(i.preClickTime,i.preTouchTime):i.preClickTime?h=i.preClickTime:i.preTouchTime&&(h=i.preTouchTime),Math.abs(h-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 p=!i.state.popupVisible;(i.isClickToHide()&&!p||p&&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 h=s.target,p=i.getRootDomNode(),R=i.getPopupDomNode();(!gm(p,h)||i.isContextMenuOnly())&&!gm(R,h)&&!i.hasPopupMouseDown&&i.close()}},i.getRootDomNode=function(){var s=i.props.getTriggerDOMNode;if(s)return s(i.triggerRef.current);try{var h=xR(i.triggerRef.current);if(h)return h}catch{}return oc.findDOMNode(OI(i))},i.getPopupClassNameFromAlign=function(s){var h=[],p=i.props,R=p.popupPlacement,E=p.builtinPlacements,w=p.prefixCls,I=p.alignPoint,L=p.getPopupClassNameFromAlign;return R&&E&&h.push(xW(E,w,s,I)),L&&h.push(L(s)),h.join(" ")},i.getComponent=function(){var s=i.props,h=s.prefixCls,p=s.destroyPopupOnHide,R=s.popupClassName,E=s.onPopupAlign,w=s.popupMotion,I=s.popupAnimation,L=s.popupTransitionName,U=s.popupStyle,V=s.mask,Q=s.maskAnimation,te=s.maskTransitionName,le=s.maskMotion,ne=s.zIndex,Z=s.popup,ee=s.stretch,me=s.alignPoint,$e=s.mobile,Qe=s.forceRender,dn=s.onPopupClick,qn=i.state,Mn=qn.popupVisible,An=qn.point,kn=i.getPopupAlign(),Ia={};return i.isMouseEnterToShow()&&(Ia.onMouseEnter=i.onPopupMouseEnter),i.isMouseLeaveToHide()&&(Ia.onMouseLeave=i.onPopupMouseLeave),Ia.onMouseDown=i.onPopupMouseDown,Ia.onTouchStart=i.onPopupMouseDown,nr(HQ,pi({prefixCls:h,destroyPopupOnHide:p,visible:Mn,point:me&&An,className:R,align:kn,onAlign:E,animation:I,getClassNameFromAlign:i.getPopupClassNameFromAlign},Ia,{stretch:ee,getRootDomNode:i.getRootDomNode,style:U,mask:V,zIndex:ne,transitionName:L,maskAnimation:Q,maskTransitionName:te,maskMotion:le,ref:i.popupRef,motion:w,mobile:$e,forceRender:Qe,onClick:dn}),typeof Z=="function"?Z():Z)},i.attachParent=function(s){dc.cancel(i.attachId);var h=i.props,p=h.getPopupContainer,R=h.getDocument,E=i.getRootDomNode(),w;p?(E||p.length===0)&&(w=p(E)):w=R(i.getRootDomNode()).body,w?w.appendChild(s):i.attachId=dc(function(){i.attachParent(s)})},i.getContainer=function(){if(!i.portalContainer){var s=i.props.getDocument,h=s(i.getRootDomNode()).createElement("div");h.style.position="absolute",h.style.top="0",h.style.left="0",h.style.width="100%",i.portalContainer=h}return i.attachParent(i.portalContainer),i.portalContainer},i.setPoint=function(s){var h=i.props.alignPoint;!h||!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},iPe.forEach(function(s){i["fire".concat(s)]=function(h){i.fireEvents(s,h)}}),i}return Sh(r,[{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=T0(s,"mousedown",this.onDocumentClick)),this.touchOutsideHandler||(s=s||i.getDocument(this.getRootDomNode()),this.touchOutsideHandler=T0(s,"touchstart",this.onDocumentClick)),!this.contextMenuOutsideHandler1&&this.isContextMenuToShow()&&(s=s||i.getDocument(this.getRootDomNode()),this.contextMenuOutsideHandler1=T0(s,"scroll",this.onContextMenuClose)),!this.contextMenuOutsideHandler2&&this.isContextMenuToShow()&&(this.contextMenuOutsideHandler2=T0(window,"blur",this.onContextMenuClose));return}this.clearOutsideHandler()}},{key:"componentWillUnmount",value:function(){this.clearDelayTimer(),this.clearOutsideHandler(),clearTimeout(this.mouseDownTimeout),dc.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,h=i.builtinPlacements;return l&&h?WW(h,l,s):s}},{key:"setPopupVisible",value:function(i,l){var s=this.props.alignPoint,h=this.state.popupVisible;this.clearDelayTimer(),h!==i&&("popupVisible"in this.props||this.setState({popupVisible:i,prevPopupVisible:h}),this.props.onPopupVisibleChange(i)),s&&l&&i&&this.setPoint(l)}},{key:"delaySetPopupVisible",value:function(i,l,s){var h=this,p=l*1e3;if(this.clearDelayTimer(),p){var R=s?{pageX:s.pageX,pageY:s.pageY}:null;this.delayTimer=window.setTimeout(function(){h.setPopupVisible(i,R),h.clearDelayTimer()},p)}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 h=this.props[i];h&&h(l)}},{key:"close",value:function(){this.setPopupVisible(!1)}},{key:"render",value:function(){var i=this.state.popupVisible,l=this.props,s=l.children,h=l.forceRender,p=l.alignPoint,R=l.className,E=l.autoDestroy,w=Gp.only(s),I={key:"trigger"};this.isContextMenuToShow()?I.onContextMenu=this.onContextMenu:I.onContextMenu=this.createTwoChains("onContextMenu"),this.isClickToHide()||this.isClickToShow()?(I.onClick=this.onClick,I.onMouseDown=this.onMouseDown,I.onTouchStart=this.onTouchStart):(I.onClick=this.createTwoChains("onClick"),I.onMouseDown=this.createTwoChains("onMouseDown"),I.onTouchStart=this.createTwoChains("onTouchStart")),this.isMouseEnterToShow()?(I.onMouseEnter=this.onMouseEnter,p&&(I.onMouseMove=this.onMouseMove)):I.onMouseEnter=this.createTwoChains("onMouseEnter"),this.isMouseLeaveToHide()?I.onMouseLeave=this.onMouseLeave:I.onMouseLeave=this.createTwoChains("onMouseLeave"),this.isFocusToShow()||this.isBlurToHide()?(I.onFocus=this.onFocus,I.onBlur=this.onBlur):(I.onFocus=this.createTwoChains("onFocus"),I.onBlur=this.createTwoChains("onBlur"));var L=(0,JQ.default)(w&&w.props&&w.props.className,R);L&&(I.className=L);var U=at({},I);QI(w)&&(U.ref=VI(this.triggerRef,w.ref));var V=kD(w,U),Q;return(i||this.popupRef.current||h)&&(Q=nr(e,{key:"portal",getContainer:this.getContainer,didUpdate:this.handlePortalUpdate},this.getComponent())),!i&&E&&(Q=null),nr(B3.Provider,{value:this.triggerContextValue},V,Q)}}],[{key:"getDerivedStateFromProps",value:function(i,l){var s=i.popupVisible,h={};return s!==void 0&&l.popupVisible!==s&&(h.popupVisible=s,h.prevPopupVisible=l.popupVisible),h}}]),r})(Mp);return n.contextType=B3,n.defaultProps={prefixCls:"rc-trigger-popup",getPopupClassNameFromAlign:oPe,getDocument:uPe,onPopupVisibleChange:H3,afterPopupVisibleChange:H3,onPopupAlign:H3,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 qQ=lPe($W);var cs={adjustX:1,adjustY:1},ss=[0,0],$Q={left:{points:["cr","cl"],overflow:cs,offset:[-4,0],targetOffset:ss},right:{points:["cl","cr"],overflow:cs,offset:[4,0],targetOffset:ss},top:{points:["bc","tc"],overflow:cs,offset:[0,-4],targetOffset:ss},bottom:{points:["tc","bc"],overflow:cs,offset:[0,4],targetOffset:ss},topLeft:{points:["bl","tl"],overflow:cs,offset:[0,-4],targetOffset:ss},leftTop:{points:["tr","tl"],overflow:cs,offset:[-4,0],targetOffset:ss},topRight:{points:["br","tr"],overflow:cs,offset:[0,-4],targetOffset:ss},rightTop:{points:["tl","tr"],overflow:cs,offset:[4,0],targetOffset:ss},bottomRight:{points:["tr","br"],overflow:cs,offset:[0,4],targetOffset:ss},rightBottom:{points:["bl","br"],overflow:cs,offset:[4,0],targetOffset:ss},bottomLeft:{points:["tl","bl"],overflow:cs,offset:[0,4],targetOffset:ss},leftBottom:{points:["br","bl"],overflow:cs,offset:[-4,0],targetOffset:ss}};Et();var WQ=pl(Dm());function ST(e){var n=e.showArrow,a=e.arrowContent,t=e.children,r=e.prefixCls,u=e.id,i=e.overlayInnerStyle,l=e.className,s=e.style;return nr("div",{className:(0,WQ.default)("".concat(r,"-content"),l),style:s},n!==!1&&nr("div",{className:"".concat(r,"-arrow"),key:"arrow"},a),nr("div",{className:"".concat(r,"-inner"),id:u,role:"tooltip",style:i},typeof t=="function"?t():t))}var cPe=function(n,a){var t=n.overlayClassName,r=n.trigger,u=r===void 0?["hover"]:r,i=n.mouseEnterDelay,l=i===void 0?0:i,s=n.mouseLeaveDelay,h=s===void 0?.1:s,p=n.overlayStyle,R=n.prefixCls,E=R===void 0?"rc-tooltip":R,w=n.children,I=n.onVisibleChange,L=n.afterVisibleChange,U=n.transitionName,V=n.animation,Q=n.motion,te=n.placement,le=te===void 0?"right":te,ne=n.align,Z=ne===void 0?{}:ne,ee=n.destroyTooltipOnHide,me=ee===void 0?!1:ee,$e=n.defaultVisible,Qe=n.getTooltipContainer,dn=n.overlayInnerStyle,qn=n.arrowContent,Mn=n.overlay,An=n.id,kn=n.showArrow,Ia=hm(n,["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow"]),Da=Kt(null);Gf(a,function(){return Da.current});var da=at({},Ia);"visible"in n&&(da.popupVisible=n.visible);var Dt=function(){return nr(ST,{showArrow:kn,arrowContent:qn,key:"content",prefixCls:E,id:An,overlayInnerStyle:dn},Mn)},_t=!1,Ha=!1;if(typeof me=="boolean")_t=me;else if(me&&To(me)==="object"){var Tr=me.keepParent;_t=Tr===!0,Ha=Tr===!1}return nr(qQ,pi({popupClassName:t,prefixCls:E,popup:Dt,action:u,builtinPlacements:$Q,popupPlacement:le,ref:Da,popupAlign:Z,getPopupContainer:Qe,onPopupVisibleChange:I,afterPopupVisibleChange:L,popupTransitionName:U,popupAnimation:V,popupMotion:Q,defaultPopupVisible:$e,destroyPopupOnHide:_t,autoDestroy:Ha,mouseLeaveDelay:h,popupStyle:p,mouseEnterDelay:l},da),w)},xQ=rc(cPe);var jQ=xQ;var VQ=e=>vt.createElement(jQ,Object.assign({},e,{overlayClassName:`cv-tooltip ${e.overlayClassName}`,getTooltipContainer:e.tooltipContainerSelector?(()=>document.querySelector(e.tooltipContainerSelector)||document.body):void 0}));if(typeof window<"u"&&typeof global>"u")try{Promise.resolve().then(()=>pl(zQ(),1)).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)}var dPe=uc();var QQ="click";var CT="top",Jh=function(e){var n=dPe(e);return function(){return function(){return n(VQ)}}};var KQ="right";var YQ=e=>()=>e.preventDefault&&e.preventDefault();var q3=function(){return YQ};var DPe=dt();var $3=ae(nn),W3=sr(DPe($({reflectSymbol:function(){return"value"}})(be)(mn))),x3=x(ka);var FT=function(e){return je("")($3(W3(bo(e.target)))(function(n){return x3(n.value)}))},j3=function(e){return je("")($3(W3(bo(e.target)))(function(n){return x3(n.value)}))},Zf=function(e){return je("")($3(W3(bo(e.target)))(function(n){return x3(n.value)}))};var XQ="/network/connections";var ZQ=15;var EPe=Jh(on)()(),IPe=Ct(Se),TPe=(function(){return"You\u2019ve hit the "+(oe(pn)(ZQ)+`-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. `)})(),SPe=qu(on)("text-decoration-underline")(ro(ie)()()("text-dark")(vn)({href:XQ})("Manage my connections")),eK=function(e){return function(n){return EPe({placement:e,trigger:QQ,overlay:IPe("")([cn(TPe),SPe]),overlayStyle:Yt({width:"15rem"}),overlayClassName:"t--connection-limit-tooltip"})(n)}};var nK=ae(nn),qh=function(e){var n=nK(e.guestPresenter)(function(a){if(a instanceof dR)return new T(a.value0);if(a instanceof hR)return G.value;throw new Error("Failed pattern match at Livestream.Utils (line 19, column 29 - line 21, column 38): "+[a.constructor.name])});return nK(n)(function(a){return new T({name:a.school.name,id:a.school.id})})};var FPe=(function(){function e(){}return e.value=new e,e})(),GPe=(function(){function e(){}return e.value=new e,e})(),V3=(function(){function e(){}return e.value=new e,e})(),MPe=(function(){function e(){}return e.value=new e,e})(),APe=(function(){function e(){}return e.value=new e,e})(),LPe=(function(){function e(){}return e.value=new e,e})(),aK=function(e){if(e instanceof FPe)return"account_settings_page";if(e instanceof GPe)return"preference_survey";if(e instanceof V3)return"livestream_registration";if(e instanceof MPe)return"chancing_wizard_network_step";if(e instanceof APe)return"main_profile_page";if(e instanceof LPe)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 $Pe=kv(Ov),Q3=Ws($Pe),K3=ae(Na);var WPe=eu(),rK=ge(ue);var oK=Q3("profile_visibility_path")(function(e){return function(n){return K3(e({visibility:{publish_scope:yR(n)}}))(to)}}),uK=function(){return Q3("profile_network_settings_path")(function(e){return function(n){return(function(a){return K3(e({network_settings:{publish_scope:yR(a.publishScope),publish_context:aK(a.publishContext),automatic_accept_requests_for_school_list:a.autoAcceptForSchoolList,automatic_connection_requests_from_livestreams:a.autoRequestFromLivestreams,livestream:et(rK(Ll(a.livestreamConference))(function(t){return{school_name:et(rK(qh(t))(function(r){return r.name})),title:t.title,id:t.id}}))}}))(to)})(WPe(n))}})},iK=Q3("profile_name_path")(function(e){return function(n){return K3(e({name:n}))(to)}});var xPe=js(),jPe=vu(ie),zPe=jr(ie),Y3=xr(ie),X3=zc(ie),F0=Pe(Se),$h=ga(ie)()(),VPe=fn(ln),Z3=Pl(Hv),bm=Pe(on),cK=Ol(),QPe=Z_(ie),KPe=yo(Je)(cr),sK=su()(),eP=Pl(Dh),YPe=zd()(),vK=Pe(ie),XPe=C1(Se),nP=L1(ie),ZPe=Ct(ie),eNe=Jh(on)()(),nNe=xr(Se),aNe=ro(ie)()(),tNe=Ht(ie),Em=x(Un),fK=VPe(ma),rNe=TI(),fy=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),_K=(function(){function e(){}return e.value=new e,e})(),pK=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),mK=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),dK=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),hK=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),_y=(function(){function e(){}return e.value=new e,e})(),aP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),gK=function(e){return function(n){var a=function(h){return xPe({id:"invite-school-modal",body:h,title:jPe("my-0")((function(){return e.stage instanceof Y1?"Join the CollegeVine network":"Connect with "+e.schoolName})()),headerClass:"pb-0",onDismiss:n(new Jn(_y.value)),size:kR.value})},t=Z5(e.context),r=Oe([zPe("mt-3")("Review your message before you send it"),Y3("mt-2")(` Because this is your first message to the counselor, we want to make sure you\u2019re ready to send. `),X3("mt-4")("Your message"),sh(e.message),F0("d-flex mt-4 justify-content-start")([$h("btn btn-primary btn-lg t--sem-user-connection-modal-confirm-message-"+t)(vn)({onClick:un(function(h){return function(){return n(new Jn(new aP({introMessage:e.message})))(),n(new Ue(new fy(WM.value)))()}})})("Send"),$h("btn btn-lg btn-outline-primary ml-3 text-nowrap")(vn)({onClick:Z3(n)(new Ue(new fy(iR.value)))})("No, I need to edit something")])]),u=Oe([F0("text-center")([bm("")(cK("mt-4")({src:"/img/checkmate-icon.png",alt:Nl.value,height:"80",width:"80"})),QPe("mt-4")("Connection request sent!"),Y3("mx-md-4")(KPe(["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."])),$h("btn btn-lg btn-outline-secondary mt-4")(vn)({onClick:Z3(n)(new Jn(_y.value))})("Close")])]),i=$h("btn btn-outline-secondary ml-3 t--sem-user-connection-modal-close-"+t)(vn)({onClick:Z3(n)(new Jn(_y.value))})("Cancel"),l=(function(){var h=HM(e.message)&&(function(){if(e.profile.fullName instanceof T)return!0;if(e.profile.fullName instanceof G)return!lc(e.firstName)&&!lc(e.lastName);throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 248, column 9 - line 252, column 82): "+[e.profile.fullName.constructor.name])})(),p=(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 G)return!1;throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 241, column 7 - line 244, column 25): "+[e.vineBelowConnectionLimit.constructor.name])})();return Oe([Qa(Rr(e.profile.fullName))(Oe([X3("mt-md-4")("Your preferred name"),F0("form-row mx-1")([sK("col form-control mr-2 t--sem-user-connection-modal-first-name-"+t)({type:"text",value:e.firstName,onChange:eP(n)(function(R){return Ue.create(dK.create(Zf(R)))}),placeholder:"First name"}),sK("col form-control ml-2 t--sem-user-connection-modal-last-name-"+t)({type:"text",value:e.lastName,onChange:eP(n)(function(R){return Ue.create(hK.create(Zf(R)))}),placeholder:"Last name"})])])),X3("mt-md-4")("Your message"),YPe("form-control t--sem-user-connection-modal-text-area-"+t)({rows:7,value:e.message,onChange:eP(n)(function(R){return Ue.create(mK.create(FT(R)))}),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! `}),bm("mt-2")(j5(e.message)),vK("mt-3 mt-md-4 small")("The ideal connection message should include:"),XPe("small")([nP("")("Your name, where you\u2019re from, and a bit about who you are"),nP("")("What you\u2019re interested in studying along with one or two insightful questions"),nP("")("That you\u2019re eager to connect with an admissions counselor and would love to stay in touch")]),F0("d-flex mt-4 justify-content-start")([eK(CT)(bm("")($h("btn btn-primary btn-lg t--sem-user-connection-modal-connect-"+t)(vn)({onClick:un(function(R){return function(){return(function(){if(e.profile.fullName instanceof T)return void 0;if(e.profile.fullName instanceof G)return n(new Ue(new pK({first:e.firstName,last:e.lastName})))();throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 222, column 23 - line 227, column 77): "+[e.profile.fullName.constructor.name])})(),n(new Ue(new fy($M.value)))()}}),disabled:!h||p,style:Yt({pointerEvents:(function(){return p?"none":"auto"})()})})("Connect"))),i])])})(),s=F0("mx-md-7")([bm("border border-success rounded p-4 my-4")(F0("row align-items-center")([bm("col-12 col-md-auto text-center text-md-left")(cK("img-fluid")({src:"/img/network/publish-profile-icon.png",alt:Nl.value,height:"67",width:"143"})),bm("col text-center text-md-left")(ZPe("fw-bold font-weight-bold text-gray-800")("Network with verified admissions counselors on CollegeVine"))])),F0("d-flex flex-nowrap align-items-center")([vK("mr-4")("Publish your profile to join the CollegeVine Network"),eNe({placement:KQ,overlay:nNe("")([cn(` 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 `),aNe("")(vn)({href:aW})("your profile"),cn(".")]),overlayStyle:Yt({width:"15rem"})})(tNe("cursor-default text-secondary fe fe-info large")(""))]),Y3("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."),F0("d-flex mt-4 justify-content-start justify-content-md-center")([$h("btn btn-primary t--sem-user-connection-modal-publish-profile-"+t)(vn)({onClick:un(function(h){return function(){return n(new Ue(_K.value))(),n(new Ue(new fy(iR.value)))()}})})("Publish profile"),i])]);return bm("t--network-sem-user-modal")((function(){if(e.stage instanceof Y1)return a(s);if(e.stage instanceof iR)return a(l);if(e.stage instanceof $M)return a(r);if(e.stage instanceof WM)return a(u);throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 95, column 5 - line 99, column 38): "+[e.stage.constructor.name])})())}},DK=function(e){return function(n){if(n instanceof Ue){if(n.value0 instanceof fy)return Em({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 _K)return fK(Bt(oK(_c.value)))(function(){return Em({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:_c.value}})});if(n.value0 instanceof pK)return fK(Bt(iK(n.value0.value0)))(function(){return Em({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(OL(n.value0.value0))}})});if(n.value0 instanceof mK)return Em({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 dK)return Em({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 hK)return Em({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 74, column 31 - line 88, column 39): "+[n.value0.constructor.name])}if(n instanceof Jn)return Em(e);throw new Error("Failed pattern match at Network.SemVine.InviteSchoolModal (line 73, column 1 - line 73, column 55): "+[e.constructor.name,n.constructor.name])}},oNe=function(e){var n=RW(e);return n?iR.value:Y1.value},RK=function(e){return{firstName:"",lastName:"",message:"",profile:rNe(e.profile),stage:oNe(e.profile),schoolName:e.schoolName,context:e.context,vineBelowConnectionLimit:e.vineBelowConnectionLimit}};var GT=we(qr(Dr)),iNe=eu(),lNe=Pe(on),cNe=Ol(),tP=Ct(ie),rP=zr(on)()(),sNe=Ht(ie),vNe=Jv(),fNe=cm(ln)(),_Ne=Hn(qe),pNe=ga(Se)()(),mNe=q3(),dNe=tt(uo),Wh=(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})(),oP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),uP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),yK=(function(){function e(){}return e.value=new e,e})(),hNe=(function(){function e(){}return e.value=new e,e})(),gNe={eq:function(e){return function(n){return e instanceof Wh&&n instanceof Wh?e.value0.url===n.value0.url:e instanceof py&&n instanceof py?GT(e.value0.backgroundColorClass)(n.value0.backgroundColorClass)&&e.value0.initials===n.value0.initials&>(e.value0.textColorClass)(n.value0.textColorClass):e instanceof oP&&n instanceof oP?GT(e.value0.backgroundColorClass)(n.value0.backgroundColorClass)&&e.value0.iconClass===n.value0.iconClass:e instanceof uP&&n instanceof uP?GT(e.value0.backgroundColorClass)(n.value0.backgroundColorClass)&&e.value0.name===n.value0.name:!1}}},DNe=yh(gNe),wK=function(){return function(e){var n=iNe(e),a=(function(){var r=Za(n.shape)(yK.value);if(r instanceof yK)return"rounded-circle";if(r instanceof hNe)return"rounded";throw new Error("Failed pattern match at Dashkit.Avatar (line 134, column 5 - line 136, column 33): "+[r.constructor.name])})(),t=function(r){return lNe("avatar "+(cW(Za(n.size)(LI.value))+(" "+Za(n.className)(""))))((function(){if(r instanceof Wh)return cNe("avatar-img img-fluid "+(a+(" "+Za(n.borderClassName)(""))))({src:r.value0.url,alt:new LR(Uq(Za(n.ariaLabel)(vn)))});if(r instanceof py)return tP("avatar-title font-weight-bold fw-bold "+(a+(" "+(je("")(r.value0.backgroundColorClass)+(" "+(je("")(r.value0.textColorClass)+(" "+Za(n.borderClassName)(""))))))))(r.value0.initials);if(r instanceof oP)return rP("avatar-title "+(a+(" "+(je("")(r.value0.backgroundColorClass)+(" "+Za(n.borderClassName)(""))))))({"aria-label":Za(n.ariaLabel)(vn)})(sNe(r.value0.iconClass)(""));if(r instanceof uP)return rP("avatar-title "+(a+(" "+(je("")(r.value0.backgroundColorClass)+(" "+Za(n.borderClassName)(""))))))({"aria-label":Za(n.ariaLabel)(vn)})(tP("material-symbol")(r.value0.name));throw new Error("Failed pattern match at Dashkit.Avatar (line 89, column 7 - line 131, column 44): "+[r.constructor.name])})())};return Rh(vNe(is(n.source))(function(r){return fNe(DNe(n.source)(function(u){return _Ne(r.value1(u))}))(function(){return xf(Oe([t(r.value0),(function(){return r.value0 instanceof Wh?ja(Ll(n.hideAvatar))(function(u){return rP("hq-only-menu-item")({style:Yt({marginTop:"-50px",marginLeft:"200px"})})(pNe("btn btn-sm btn-warning mb-4 t--hide-avatar")(vn)({onClick:un(function(i){return function(){return mNe(i)(),dNe(r.value1)(u)()}})})([tP("badge badge-info bg-info text-dark mr-2")("HQ"),cn("Hide")]))}):Aa})()]))})}))}};var yNe=wK();var bK=function(e){return function(n){return yNe({source:(function(){if(e.avatarUrl instanceof T)return new Wh({url:e.avatarUrl.value0});if(e.avatarUrl instanceof G)return new py({initials:e.initials,backgroundColorClass:G.value,textColorClass:G.value});throw new Error("Failed pattern match at Sem.Utils (line 15, column 15 - line 23, column 14): "+[e.avatarUrl.constructor.name])})(),size:n})}};var iP=B(ue),bNe=tn(E8(V0));var EK=function(e){var n=function(a){return je("")(iP(Vi)(RD(0)(a)))};return Iv((function(){var a=Wu(" ")(e);return a.length===2?n(a[0])+n(a[1]):a.length===1?n(a[0]):a.length===0?"":je("?")(bNe(iP(n)(mp(a)))(iP(n)(hd(a))))})())},IK=function(e){return Zd(e.firstName+(" "+e.lastName))};var lP=vu(ie),INe=ro(ie)()(),TNe=ro(Se)()(),TK=Ht(ie),SNe=ga(Se)()(),CNe=$i(Nt)(iu),FNe=ge(ue),GNe=ae(nn),cP=Pe(ie),MT=Pe(Se),SK=Pe(on),MNe=Kd(ie),CK=Ps()(),ANe=zc(ie),LNe=xr(ie),xh=x(Un),AK=fn(ln),PNe=AK(ma),NNe=nt(qe),ONe=AK(Na),UNe=x(ba),kNe=$t(Lo(st)),FK=(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})(),GK=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),MK=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),LK=(function(){var e=function(a){return function(t){return function(r){var u=lP("text-primary")(t.semUser.firstName+(" from "+(t.semUser.school.name+" sent you a connection request!"))),i=lP("text-primary")("Reach out to "+(t.semUser.firstName+" to ask a question or introduce yourself!")),l=[u,INe("btn btn-primary d-flex align-items-center w-50 justify-content-center t--livestream-details-view-pending-invitation-from-sem-user")(vn)({href:WL(new Ih(t.semUser.id))})("View Message")],s=IK(t.semUser),h=EK(s),p=lP("text-primary")("Reach out to "+(t.semUser.firstName+" to ask a question!")),R=[p,TNe("btn btn-primary d-flex align-items-center w-50 justify-content-center t--livestream-details-messages-link")(vn)({href:WL(new Ih(t.semUser.id))})([TK("fe fe-message-square mr-2 large")(""),cn("Send a message to "+t.semUser.firstName)])],E=function(L){return SNe("btn btn-primary d-flex align-items-center justify-content-center t--livestream-details-connect-with-sem-user")(vn)({onClick:un(function(U){return CNe(r)(FNe(GNe(a.currentUser)(function(V){return V.profile}))(GK.create))}),disabled:L.isDisabled})([TK("fe fe-message-square mr-2 large")(""),cn("Connect with "+t.semUser.firstName)])},w=[i,E({isDisabled:!1})],I=[i,E({isDisabled:!0}),cP("mt-4 text-secondary small")("Invitation pending")];return MT("t--livestream-details-guest-presenter-sem-user mb-4")([ja(a.currentUser)(function(L){return Qa(L.hasAccessToNetwork&&t.semUser.school.allowedToContact)(SK("card")(MT("card-body")((function(){if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof u0)return R;if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof Hs&&t.semUser.connection.value0.initiator instanceof kf||t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof Bf&&t.semUser.connection.value0.initiator instanceof kf)return I;if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof Hs&&t.semUser.connection.value0.initiator instanceof Uf)return l;if(t.semUser.connection instanceof T&&t.semUser.connection.value0.status instanceof Bf&&t.semUser.connection.value0.initiator instanceof Uf||t.semUser.connection instanceof G)return w;throw new Error("Failed pattern match at Livestream.GuestPresenter.SemUser (line 95, column 17 - line 105, column 53): "+[t.semUser.connection.constructor.name])})())))}),MNe("text-uppercase text-secondary")("Your guest presenter"),MT("row align-items-center mt-4")([SK("col-auto")(bK(CK(t.semUser)({initials:h}))(AI.value)),MT("col")([ANe("mb-1")(s),cP("text-secondary small")(t.semUser.school.name),cP("text-secondary small")(t.semUser.title)]),ja(t.semUser.bio)(function(L){return LNe("mt-4 mb-2 ml-2")(L)})]),ja(t.modal)(function(L){return gK(L.value0)(function(U){return r(my.create(U))})})])}}},n=function(a){return function(t){return function(r){if(r instanceof my&&r.value0 instanceof Jn){if(r.value0.value0 instanceof _y)return xh({currentUser:t.currentUser,semUser:t.semUser,vineBelowConnectionLimit:t.vineBelowConnectionLimit,modal:G.value});if(r.value0.value0 instanceof aP)return PNe(NNe(ONe(SW(t.semUser.school.id)(t.semUser.id)({introMessage:r.value0.value0.value0.introMessage}))(function(){return UNe(new MK({introMessage:r.value0.value0.value0.introMessage}))})))(function(){return xh(t)});throw new Error("Failed pattern match at Livestream.GuestPresenter.SemUser (line 49, column 53 - line 56, column 17): "+[r.value0.value0.constructor.name])}if(t.modal instanceof T&&r instanceof my&&r.value0 instanceof Ue)return kNe(my.create)(function(u){return{currentUser:t.currentUser,semUser:t.semUser,vineBelowConnectionLimit:t.vineBelowConnectionLimit,modal:new T(new FK(u))}})(DK(t.modal.value0.value0)(new Ue(r.value0.value0)));if(r instanceof my&&r.value0 instanceof Ue)return xh(t);if(r instanceof GK)return xh({currentUser:t.currentUser,semUser:t.semUser,vineBelowConnectionLimit:t.vineBelowConnectionLimit,modal:new T(new FK(RK({schoolName:a.semUser.school.name,context:qM.value,profile:r.value0,vineBelowConnectionLimit:a.vineBelowConnectionLimit})))});if(r instanceof MK)return xh({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:kf.value,introMessage:r.value0.introMessage,status:Hs.value})}});throw new Error("Failed pattern match at Livestream.GuestPresenter.SemUser (line 48, column 3 - line 48, column 65): "+[a.constructor.name,t.constructor.name,r.constructor.name])}}};return Af("Livestream Guest Presenter SEM user")(function(a){return{init:xh(CK(a)({modal:G.value})),view:e(a),update:n(a)}})})();var HNe=Ct(Se),JNe=Ht(ie),dy=Pe(Se),PK=Kd(ie),qNe=B(Ye),sP=Pe(on),$Ne=jc()(),WNe=vu(ie),NK=function(e){return function(n){var a=function(i){return HNe("badge badge-light bg-light text-dark mr-3")([JNe("fe fe-tag mr-2")(""),cn(i.name)])},t=function(i){return function(l){return dy("mb-3")([PK("text-secondary text-uppercase mb-2")(i),l])}},r=dy("mt-4")([ja(he(n.entity.shortEducation))(function(i){return t("Education")(cn(i))}),t("Bio")(sh(n.entity.bio)),SA(xi(n.entity.tags))(t("Specialties")(Oe(qNe(a)(n.entity.tags))))]),u=dy("row")([ja(he(n.entity.imageUrl))(function(i){return sP("p-0 m-0")(sP("col-auto my-auto")(sP("avatar avatar-md")($Ne("avatar-img rounded-circle")({src:i,alt:n.entity.name}))))}),dy("col-auto my-auto")([PK("text-uppercase text-secondary mb-2")("Advisor"),WNe("m-0")(n.entity.name)])]);return dy("mt-4 mt-md-0 t--service-provider-guest-presenter")([u,r])}};var hy=function(e){return function(n){return function(a){return function(t){if(n instanceof dR)return LK({semUser:n.value0,currentUser:a,vineBelowConnectionLimit:t.vineBelowConnectionLimit});if(n instanceof hR)return NK(e)(n.value0);throw new Error("Failed pattern match at Livestream.GuestPresenter.GuestPresenter (line 15, column 1 - line 15, column 78): "+[e.constructor.name,n.constructor.name,a.constructor.name,t.constructor.name])}}}};var jNe=ro(Se)()(),zNe=Ht(ie),jh=Pe(ie),gc=Pe(on),Dc=Pe(Se),kK=vu(ie),BK=jc()(),HK=ge(Ye),VNe=Ct(ie),UK=ge(ue),QNe=xr(Se),JK=qu(ie),qK=ro(ie)()(),KNe=oe(pn),gy=B(ue),YNe=Qd(Se)()(),XNe=oe($s),Dy=function(e){var n=function(a){return function(t){return jNe("mr-3")(vn)({href:t,target:"_blank"})([cn(a),zNe("fe fe-external-link ml-1")("")])}};return Oe([jh("text-uppercase text-muted small mb-2")("School information"),gc("card shadow-none")(Dc("card-body")([kK("mb-1")(e.name),jh("text-uppercase small text-secondary")(e.cityState),Dc("mt-3 d-none d-md-block")([n("Stats")(MI(mm.value)(e.slug)),n("Cost")(MI($R.value)(e.slug)),n("Map")(MI(mm.value)(e.slug))]),Dc("mt-3 d-md-none")([n("Stats")(AL(mm.value)(e.slug)),n("Cost")(AL($R.value)(e.slug))])]))])},ZNe=function(e){var n=function(i){return BK("avatar-img rounded-circle")({src:i,alt:e.fullName})},a=vo(" ")(HK(Wu(" ")(e.fullName))(rl(1))),t=VNe("avatar-title rounded-circle text-uppercase")(a),r=function(i){return je("")(UK(i)(function(l){return" '"+l}))},u=function(i){return function(l){return QNe("")([JK("")(i+": "),cn(l)])}};return Oe([jh("text-uppercase text-muted small mb-2")("Your host"),Dc("row align-items-center mb-4 pr-4")([gc("col-auto")(gc("avatar")(Wn(t)(n)(e.pictureUrl))),gc("col")(Dc("row align-items-center justify-content-between")([jh("col-12 col-md-auto x-large")(e.fullName),gc("col-12 col-md-auto")(ja(e.allStreamsUrl)(function(i){return qK("t--host-streams")(vn)({href:i})("See all "+(KNe(e.totalStreams)+(" streams by "+e.firstName)))}))]))]),Oe(ri([gy(u("Undergrad College"))(UK(e.undergrad.college)(function(i){return i+r(e.undergrad.year)})),gy(u("Major"))(e.undergrad.major),gy(u("Graduate College"))(e.gradCollege),gy(u("Work Experience"))(e.workExperience),gy(u("My Admissions Story"))(e.admissionsStory)]))])},e4e=function(e){return Oe([jh("text-uppercase text-muted small mb-2")("Description"),Dc("")([gc("col-6 col-md-4 float-right")(BK("img-fluid rounded")({src:e.imageUrl,alt:e.title})),Dc("")(HK(Wu(` `)(e.description))(function(n){return YNe("")({dangerouslySetInnerHTML:{__html:n}})([])}))])])},n4e=function(e){var n=e.paths.collegeFair+("?utm_cv_source=banner-livestream-watch-"+XNe(e.conference.id));return gc("card mt-3")(gc("card-body py-3")(Dc("row align-items-center")([gc("col-12 col-md-auto mb-3 mb-md-0")(jh("bg-warning rounded px-3 py-1 small mt-2 mt-md-0")("SPECIAL EVENT")),Dc("col-12 col-md mb-3 mb-md-0")([cn("This livestream was part of the "),JK("")("\u{1F3AA} Student panel college fair"),cn(". Recordings for all 100+ Q&A panels are available.")]),gc("col-12 col-md-auto")(qK("btn btn-sm btn-outline-primary px-3")(vn)({href:n})("See all recordings"))])))},AT=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 G||e.conference.presenter instanceof G&&e.conference.guestPresenter instanceof T)return"col-12 col-md-6";if(e.conference.presenter instanceof G&&e.conference.guestPresenter instanceof G)return"col-12";throw new Error("Failed pattern match at Livestream.AboutLivestream (line 52, column 14 - line 56, column 33): "+[e.conference.presenter.constructor.name,e.conference.guestPresenter.constructor.name])})();return Oe([Qa(e.conference.collegeFair)(n4e(e)),gc("card")(Dc("card-body")([kK("text-center mb-4")("About this livestream"),Dc("row")([Dc(n)([ja(e.conference.school)(function(a){return gc("d-md-none")(Dy(a))}),e4e(e.conference)]),Dc(n)([ja(e.conference.guestPresenter)(function(a){return hy(e.conference.id)(a)(e.user)({vineBelowConnectionLimit:e.vineBelowConnectionLimit})}),ja(e.conference.school)(function(a){return gc("d-none d-md-block")(Dy(a))}),ja(e.conference.presenter)(ZNe)])])]))])};var VK=fn(ln),a4e=VK(ma),t4e=nt(qe),r4e=Mr(Yo),WK=x(ba),JT=x(Un),o4e=VK(Na),LT=x(ka),xK=Pe(ie),PT=zc(ie),NT=Y_(Se),OT=V_(Se),G0=Lf(Se),vs=Q_(ie),UT=K_(Se),kT=ge(Ye),M0=Us(ie),BT=Us(on),HT=ga(ie)()(),u4e=zl(ot),i4e=B(Ye),l4e=tn(__(__(ib))),c4e=zl(Gl),s4e=zl(mB),v4e=oe($s),f4e=jr(ie),_4e=Pe(Se),qT=(function(){function e(){}return e.value=new e,e})(),QK=(function(){function e(){}return e.value=new e,e})(),Ry=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),jK=(function(){function e(){}return e.value=new e,e})(),zK=(function(){function e(){}return e.value=new e,e})(),KK=function(e){return function(n){return function(a){var t=function(u){return a4e(t4e(r4e(u)(function(i){return WK(zK.value)})))(function(){return JT({ctas:n.ctas,stage:QK.value,error:G.value})})},r=function(u){if(u instanceof ns)return Tq({fromConference:e.conference.id,cta:u.value0.conferenceId});if(u instanceof as)return Eq({fromConference:e.conference.id,ctaId:u.value0.id});if(u instanceof ts)return Iq({fromConference:e.conference.id,ctaId:u.value0.id});if(u instanceof rs)return bq({fromConference:e.conference.id,ctaId:u.value0.id});throw new Error("Failed pattern match at Livestream.Ctas.LaunchCtas (line 227, column 13 - line 235, column 81): "+[u.constructor.name])};if(a instanceof Ry)return t(o4e(r(a.value0))(function(){return WK(jK.value)}));if(a instanceof jK)return JT({ctas:n.ctas,error:n.error,stage:qT.value});if(a instanceof zK)return JT({ctas:n.ctas,stage:qT.value,error:new T("That didn't work for some reason, try again")});throw new Error("Failed pattern match at Livestream.Ctas.LaunchCtas (line 210, column 24 - line 220, column 92): "+[a.constructor.name])}}},YK=function(e){return JT({stage:qT.value,error:G.value,ctas:e})},p4e=(function(){return xu(Bu(Je)([Js.value,new ar(" "),Xc.value,new ar(", "),Zc.value,new ar(":"),Al.value,new ar(" "),es.value]))})(),XK=function(e){return function(n){if(e.ctas.length===0)return Aa;var a=function(L){return L instanceof rs?LT(L.value0):G.value},t=function(L){return L instanceof as?LT(L.value0):G.value},r=function(L){return L instanceof ts?LT(L.value0):G.value},u=function(L){return L instanceof ns?LT(L.value0):G.value},i=(function(){if(e.stage instanceof qT)return Aa;if(e.stage instanceof QK)return xK("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 188, column 22 - line 194, column 21): "+[e.stage.constructor.name])})(),l=function(L){return L.length===0?Aa:Oe([PT("")("Referrals"),NT("table table-sm mb-0")([OT("")([G0("")([vs("")("Title"),vs("")("Actions")])]),UT("")(kT(L)(function(U){return G0("t--cta t--cta-referral")([M0("pt-3")(U.title),BT("text-nowrap")(HT("btn btn-white btn-sm px-4 t--open")(vn)({onClick:un(function(V){return n(new Ry(new rs(U)))})})("Launch CTA"))])}))])])},s=function(L){return L.length===0?Aa:Oe([PT("")("General"),NT("table table-sm mb-0")([OT("")([G0("")([vs("")("Title"),vs("")("URL"),vs("")("Link Text"),vs("")("Actions")])]),UT("")(kT(S_(u4e(function(U){return U.title}))(L))(function(U){return G0("t--cta t--cta-general")([M0("pt-3")((function(){var V=Fr(U.autoDisplayMinutesFromStart);return V?"\u23F0 ":""})()+U.title),M0("pt-3")(U.url),M0("pt-3")(U.buttonText),BT("text-nowrap")(HT("btn btn-white btn-sm px-4 t--open")(vn)({onClick:un(function(V){return n(new Ry(new as(U)))})})("Launch CTA"))])}))])])},h=function(L){return L.length===0?Aa:Oe([PT("")("Featured Service Providers"),NT("table table-sm mb-0")([OT("")([G0("")([vs("")("Advisors"),vs("")("Link Text"),vs("")("Actions")])]),UT("")(kT(L)(function(U){return G0("t--cta t--cta-featured-sp")([M0("pt-3")(vo(", ")(i4e(function(V){return V.name})(U.providers))),M0("pt-3")(U.linkText),BT("text-nowrap")(HT("btn btn-white btn-sm px-4 t--open")(vn)({onClick:un(function(V){return n(new Ry(new ts(U)))})})("Launch CTA"))])}))])])},p=function(L){return L.length===0?Aa:Oe([PT("")("Upcoming events"),NT("table table-sm mb-0")([OT("")([G0("")([vs("")("Livestream"),vs("")("Date & Time"),vs("")("Actions")])]),UT("")(kT(S_(l4e(c4e(function(U){return U.startTime}))(s4e(function(U){return U.conferenceId})))(L))(function(U){return G0("t--cta t--cta-stream-"+v4e(U.conferenceId))([M0("pt-3")(U.title),M0("pt-3")(p4e(U.startTime)+(" "+Xp)),BT("text-nowrap")(HT("btn btn-white btn-sm px-4 t--open")(vn)({onClick:un(function(V){return n(new Ry(new ns(U)))})})("Launch CTA"))])}))])])},R=zo(a)(e.ctas),E=zo(t)(e.ctas),w=zo(r)(e.ctas),I=zo(u)(e.ctas);return Oe([f4e("")("Calls to action"),_4e("t--ctas position-relative")([ja(e.error)(function(L){return xK("alert alert-danger")(L)}),p(I),s(E),h(w),l(R),i])])}};var ZK=Ws(kv(Ov)),eY=ae(Na),d4e=d2(be),zh=(function(){function e(){}return e.value=new e,e})(),yy=(function(){function e(){}return e.value=new e,e})(),wy=(function(){function e(){}return e.value=new e,e})(),nY={eq:function(e){return function(n){return e instanceof zh&&n instanceof zh||e instanceof yy&&n instanceof yy||e instanceof wy&&n instanceof wy}}},aY=ZK("profile_validate_username_path")(function(e){return function(n){return eY(e({username:n}))(Uv(function(a){return d4e("username validation result")(a)(function(t){return t==="available"?new T(zh.value):t==="taken"?new T(yy.value):t==="invalid"?new T(wy.value):G.value})}))}}),tY=ZK("profile_set_username_path")(function(e){return function(n){return eY(e({username:n}))(to)}});var g4e=we(qr(nv()(Rs(Rs(ev)()({reflectSymbol:function(){return"username"}})(Dr))()({reflectSymbol:function(){return"result"}})(nY)))),vP=Pe(Se),rY=Pe(on),D4e=xr(ie),R4e=Ol(),by=Pe(ie),y4e=su()(),oY=ga(ie)()(),w4e=Sr(Nt),fP=fn(ln)(ma),b4e=Sr(Un),_P=nt(qe),E4e=jl(st),Im=x(Un),I4e=B(st),T4e=ae(Na),S4e=M_(Yo),uY=x(ba),sY=(function(){function e(){}return e.value=new e,e})(),vY=(function(){function e(){}return e.value=new e,e})(),fY=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),iY=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),lY=(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})(),_Y=(function(){function e(){}return e.value=new e,e})(),cY=(function(){function e(){}return e.value=new e,e})(),pP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),mP=(function(){function e(){}return e.value=new e,e})(),pY=function(e){return function(n){var a=e.username!==""&&Rr(e.updating)&&g4e(e.validated)(new T({username:e.username,result:zh.value}));return Oe([vP("row")([rY("col col-md-6")(D4e("")("This username will keep your identity private in CollegeVine communities, livestreams, and on peer essay review leaderboards.")),rY("col-6 d-none d-md-block")(R4e("img-fluid")({alt:Nl.value,src:"/img/illustrations/clipboards.svg"}))]),by("")("Your username:"),vP("input-group")([y4e("form-control")({autoFocus:!0,type:"text",value:e.username,onChange:un(function(t){return n(new Ue(new fY(Zf(t))))})})]),vP("d-flex mt-3")([oY("btn btn-light mr-3")(vn)({onClick:un(function(t){return n(new Jn(mP.value))})})("Cancel"),oY("btn btn-primary t--submit-username")(vn)({type:"button",disabled:!a,onClick:un(function(t){return w4e(a)(n(new Ue(_Y.value)))})})("Save")]),ja(e.validated)(function(t){if(t.result instanceof zh)return Aa;if(t.result instanceof yy)return by("small text-danger")("Sorry, this username is already taken");if(t.result instanceof wy)return by("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 74, column 39 - line 81, column 99): "+[t.result.constructor.name])}),ja(e.updating)(function(t){if(t instanceof sY)return by("text-success")("Updating your username...");if(t instanceof vY)return by("small text-danger")("There was an error saving your username. Please try again.");throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 82, column 32 - line 86, column 97): "+[t.constructor.name])})])}},mY=function(e){return function(n){if(n instanceof Ue){if(n.value0 instanceof fY)return fP(b4e(n.value0.value0!=="")(_P(E4e(Wr(100))(new Ue(new iY(n.value0.value0))))))(function(){return Im({updating:e.updating,validated:e.validated,username:n.value0.value0})});if(n.value0 instanceof iY){if(n.value0.value0===e.username)return fP(_P(I4e((function(){var a=lY.create(n.value0.value0);return function(t){return Ue.create(a(t))}})())(aY(n.value0.value0))))(function(){return Im({username:e.username,validated:G.value,updating:G.value})});if(Ve)return Im(e)}if(n.value0 instanceof lY)return Im({updating:e.updating,username:e.username,validated:new T({username:n.value0.value0,result:n.value0.value1})});if(n.value0 instanceof _Y)return fP(_P(T4e(S4e(tY(e.username)))(function(a){if(a instanceof Le)return uY(new Jn(new pP(e.username)));if(a instanceof Me)return uY(new Ue(cY.value));throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 114, column 7 - line 118, column 48): "+[a.constructor.name])})))(function(){return Im({username:e.username,validated:G.value,updating:new T(sY.value)})});if(n.value0 instanceof cY)return Im({username:e.username,validated:e.validated,updating:new T(vY.value)});throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 95, column 31 - line 122, column 48): "+[n.value0.constructor.name])}if(n instanceof Jn)return Im(e);throw new Error("Failed pattern match at Community.Profile.UsernameForm (line 94, column 1 - line 94, column 55): "+[e.constructor.name,n.constructor.name])}},dY=function(e){return{username:e,validated:G.value,updating:G.value}};var F4e=eu(),G4e=Jh(on)()(),M4e=Ct(Se),A4e=Ht(ie),L4e=function(e){var n=KD(e);return function(){return function(a){return function(t){var r=F4e(a);return G4e({placement:CT,overlay:Oe(n(t)),overlayStyle:Za(r.overlayStyle)(Yt({width:"15rem"}))})(M4e("d-inline-flex align-items-center text-secondary "+r.className)([A4e("d-inline-block fe fe-help-circle "+(function(){var u=r.anchorText==="";return u?"":"mr-2"})())(""),cn(r.anchorText)]))}}}},$T=function(e){var n=L4e(e)();return function(a){return n({className:a,anchorText:""})}};var gY=oa(ra),Ey=ta(gY)(Zn(Xn)),DY=na(ea),Iy=aa(DY),RY=la(ia),Ty=ua(RY),P4e=B(ue),Vh=(function(){function e(){}return e.value=new e,e})(),Qh=(function(){function e(){}return e.value=new e,e})(),Kh=(function(){function e(){}return e.value=new e,e})(),Yh=(function(){function e(){}return e.value=new e,e})(),Xh=(function(){function e(){}return e.value=new e,e})(),Tm=(function(){function e(){}return e.value=new e,e})(),N4e={to:function(e){if(e instanceof Te)return Vh.value;if(e instanceof fe&&e.value0 instanceof Te)return Qh.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof Te)return Kh.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof fe&&e.value0.value0.value0 instanceof Te)return Yh.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof fe&&e.value0.value0.value0 instanceof fe&&e.value0.value0.value0.value0 instanceof Te)return Xh.value;if(e instanceof fe&&e.value0 instanceof fe&&e.value0.value0 instanceof fe&&e.value0.value0.value0 instanceof fe&&e.value0.value0.value0.value0 instanceof fe)return Tm.value;throw new Error("Failed pattern match at Common.Persona (line 21, column 1 - line 21, column 34): "+[e.constructor.name])},from:function(e){if(e instanceof Vh)return new Te(xe.value);if(e instanceof Qh)return new fe(new Te(xe.value));if(e instanceof Kh)return new fe(new fe(new Te(xe.value)));if(e instanceof Yh)return new fe(new fe(new fe(new Te(xe.value))));if(e instanceof Xh)return new fe(new fe(new fe(new fe(new Te(xe.value)))));if(e instanceof Tm)return new fe(new fe(new fe(new fe(new fe(xe.value)))));throw new Error("Failed pattern match at Common.Persona (line 21, column 1 - line 21, column 34): "+[e.constructor.name])}},yY=Qn(N4e)(Ey(Ey(Ey(Ey(Ey(gY)(DY))(Iy))(Iy))(Iy))(Iy))(Ty(Ty(Ty(Ty(Ty(RY))))))(Iy);var O4e={eq:function(e){return function(n){return e instanceof Vh&&n instanceof Vh||e instanceof Qh&&n instanceof Qh||e instanceof Kh&&n instanceof Kh||e instanceof Yh&&n instanceof Yh||e instanceof Xh&&n instanceof Xh||e instanceof Tm&&n instanceof Tm}}},WT=function(e){if(e instanceof Vh)return"student";if(e instanceof Qh)return"transfer_student";if(e instanceof Kh)return"counselor";if(e instanceof Yh)return"iec";if(e instanceof Xh)return"parent";if(e instanceof Tm)return"sem_user";throw new Error("Failed pattern match at Common.Persona (line 40, column 13 - line 46, column 24): "+[e.constructor.name])},wY=(function(){var e=Vn(WT)(yY);return Ga(sn)({parse:function(n){return n==="unknown"?new T(G.value):P4e(T.create)(e(n))},default:G.value,diagnosticName:"User Persona"})})(),bY=function(e){if(e instanceof Vh)return"Student";if(e instanceof Qh)return"Transfer Student";if(e instanceof Kh)return"High School Counselor";if(e instanceof Yh)return"Independent Educational Counselor (IEC)";if(e instanceof Xh)return"Parent";if(e instanceof Tm)return"SEM User";throw new Error("Failed pattern match at Common.Persona (line 30, column 11 - line 36, column 24): "+[e.constructor.name])},EY=(function(){return C_(O4e)(Tm.value)(yY)})();var hP=B(eo);var dP=ae(Ri),k4e=x(uv),B4e=ni(U8);var IY=function(e){return e},TY=function(e){return function(n){return hP(function(a){return a.result})(e({substring:n,position:0}))}};var xv={map:function(e){return function(n){var a=hP(function(t){return{result:e(t.result),suffix:t.suffix}});return function(t){return a(n(t))}}}},Sm=function(e){return function(n){return new Me({pos:n.position,error:e})}},Cm={apply:function(e){return function(n){return function(a){return dP(e(a))(function(t){return dP(n(t.suffix))(function(r){return k4e({result:t.result(r.result),suffix:r.suffix})})})}}},Functor0:function(){return xv}};var e_={bind:function(e){return function(n){return function(a){return dP(e(a))(function(t){return IY(n(t.result))(t.suffix)})}}},Apply0:function(){return Cm}};var n_={pure:function(e){return function(n){return new Le({result:e,suffix:n})}},Apply0:function(){return Cm}};var H4e={Applicative0:function(){return n_},Bind1:function(){return e_}},SY={tailRecM:function(e){return function(n){var a=function(t){if(t.result instanceof Kr)return new Kr({state:t.result.value0,str:t.suffix});if(t.result instanceof $r)return new $r({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 B4e(function(r){return hP(a)(IY(e(r.state))(r.str))})({state:n,str:t})}}},Monad0:function(){return H4e}};var Fm={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(Ve)return new Me({error:t.value0.error,pos:t.value0.pos})}return t}}},Functor0:function(){return xv}},J4e={empty:Sm("No alternative"),Alt0:function(){return Fm}},CY={Applicative0:function(){return n_},Plus1:function(){return J4e}};var FY=La(Fm),gP=ae(e_),DP=x(n_),$4e=B(xv);var W4e=Nu(Cm),x4e=sa(Cm);var RP=function(e){return function(n){return FY(e)(Sm(n))}},yP=function(e){return function(n){var a=e(n);return a instanceof Me?new Me({pos:n.position,error:a.value0.error}):a}},jv=function(e){return FY(gP(e)(function(n){return DP(void 0)}))(DP(void 0))};var GY=function(e){return function(n){return new yl(e,n)}};var j4e=function(e){return function(n){var a=e(n);if(a instanceof Le){var t=n.position65535;return t?e(n):PY(a.value0)}if(a instanceof G)return e(n);throw new Error("Failed pattern match at StringParser.CodePoints (line 57, column 3 - line 65, column 27): "+[a.constructor.name])})})(),A0=function(e){return yP(LY(Y4e)(function(n){var a=e(n);return a?PY(n):Sm("Character "+(NY(n)+" did not satisfy predicate"))}))},Rc=function(e){return RP(A0(function(n){return n===e}))("Could not match character "+NY(e))};var Z4e=function(e,n,a){var t=0,r;return function(u){if(t===2)return r;if(t===1)throw new ReferenceError(e+" was needed before it finished initializing (module "+n+", line "+u+")",n,u);return t=1,r=a(),t=2,r}},e8e=lr(),EP=B(xv),n8e=yo(pD)(cr),a8e=B($b),Qu=fn(ln)(e_),Li=zt(xv),a_=x(n_),Bl=La(Fm);var Zh=Nu(Cm),L0=ae(e_),kY=yo(Vo)(cr);var Bo=function(e){return e8e(rE(e))},IP=function(e){return EP((function(){var n=a8e(Vi);return function(a){return n8e(n(a))}})())(MY(A0(e)))},BY=function(e){return Qu(Li(e))(function(){return Qu(Li(jT(e)))(function(){return a_(void 0)})})},jT=function(e){return Bl(BY(e))(a_(void 0))},HY=function(e){return Qu(Li(A0(e)))(function(){return Qu(Li(jT(A0(e))))(function(){return a_(void 0)})})},t8e=Rc(Bo(0));var JY=Rc(` `),qY=function(e){return e===" "||e===" "},r8e=A0(qY),bP=HY(qY),o8e=function(e){var n=e>="0"&&e<="9",a=e>="a"&&e<="z"||e>="A"&&e<="Z";return n||a},zv=function(e){return function(n){return function(a){return a>=e&&a<=n}}},u8e=zv(Bo(33))(Bo(126)),i8e=A0(u8e),TP=function(e){return function(n){return dv(Vi(n))(e)}},zT=function(e){return zv(Bo(1))(Bo(8))(e)||zv(Bo(14))(Bo(31))(e)||TP("\v\f\x7F")(e)},l8e=function(e){return zv(Bo(33))(Bo(39))(e)||zv(Bo(42))(Bo(91))(e)||zv(Bo(93))(Bo(126))(e)||zT(e)},c8e=function(e){return zv(Bo(33))(Bo(90))(e)||zv(Bo(94))(Bo(126))(e)||zT(e)},s8e=A0(zT),v8e=function(e){return TP(Vi(Bo(33)))(e)||zv(Bo(35))(Bo(91))(e)||zv(Bo(93))(Bo(126))(e)||zT(e)};var $Y=Rc("\r"),UY=Li(Zh($Y)(JY)),eg=(function(){var e=BY(Zh(UY)(bP)),n=Zh(bP)(jv(Zh(UY)(bP)));return Bl(n)(e)})(),WY=(function(){var e=Qu(Li(Rc("\\")))(function(){return Bl(i8e)(Bl(r8e)(Bl(JY)(Bl($Y)(Bl(s8e)(t8e)))))});return L0(e)(function(n){return a_("\\"+Vi(n))})})(),f8e=Bl(IP(v8e))(WY),_8e=(function(){var e=Qu(Li(Rc('"')))(function(){return L0(Gm(Zh(jv(eg))(f8e)))(function(n){return Qu(Li(jv(eg)))(function(){return Qu(Li(Rc('"')))(function(){return a_(n)})})})});return EP(function(n){return'"'+(kY(n)+'"')})(e)})(),xY=Z4e("comment","Text.Email.Parser",function(){return Qu(Li(Rc("(")))(function(){return Qu(jT(Bl(HY(l8e))(Bl(Li(WY))(Bl(xY(155))(eg)))))(function(){return Qu(Li(Rc(")")))(function(){return a_(void 0)})})})}),p8e=xY(152),xT=jT(Bl(p8e)(eg)),m8e=Qu(jv(xT))(function(){return Qu(Li(Rc("[")))(function(){return L0(Gm(Zh(jv(eg))(IP(c8e))))(function(e){return Qu(jv(eg))(function(){return Qu(Li(Rc("]")))(function(){return Qu(jv(xT))(function(){return a_("["+(kY(e)+"]"))})})})})})}),d8e=(function(){var e=function(n){return o8e(n)||TP("!#$%&'*+/=?^_`{|}~-")(n)};return IP(e)})(),jY=(function(){var e=Qu(Li(jv(xT)))(function(){return L0(Bl(d8e)(_8e))(function(a){return Qu(Li(jv(xT)))(function(){return a_(a)})})}),n=AY(e)(Rc("."));return EP(Pc(pD)(cr)("."))(n)})(),h8e=Bl(jY)(m8e),g8e=jY,SP=L0(g8e)(function(e){return L0(Rc("@"))(function(){return L0(h8e)(function(n){return L0(OY)(function(){return a_({localPart:e,domainPart:n})})})})});var y8e=function(e){return TY(SP)(e)},w8e=(function(){var e=wr(Du)(oe(D_()()(R_({reflectSymbol:function(){return"error"}})(y_({reflectSymbol:function(){return"pos"}})(pn))(ir))));return function(n){return e(y8e(n))}})(),Cy=function(e){var n=w8e(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 CP=qu(ie),VT=su()(),VY=M1(Se)()(),QY=ge(ue),KY=$i(Nt)(iu),YY=B(ue),QT=A1(ie)()(),XY=ge(Ye),Fy=Pe(Se),b8e=DL(),FP=oe(pn),E8e=Rb(Je)(Ot),I8e=e0(Se)()(),Mm=Pe(on),ZY=ga(ie)()(),T8e=oe($s),Gy=x(Un),eX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),nX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),aX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),tX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),rX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ng=function(e){return function(n){return function(a){return function(t){var r=function(p){return function(R){return function(E){return function(w){return function(I){return function(L){return Oe([CP("")(R),VT("form-control")({type:"text",name:"livestream_public_registration_form["+(p+"]"),value:w,placeholder:E,autoFocus:L.autoFocus,onChange:un(function(U){return t(I(Zf(U)))})})])}}}}}},u=[CP("")("I'm a..."),VY("form-control")({name:"livestream_public_registration_form[i_am_a]",value:je("")(QY(a.persona)(WT)),onChange:un(function(p){return KY(t)(YY(rX.create)(wY(j3(p))))})})([Qa(Rr(a.persona))(QT("")({value:""})("Select one...")),Oe(XY(EY)(function(p){return QT("")({value:WT(p)})(bY(p))}))])],i=Fy("d-flex align-items-center")([cn("Already have an account? "),b8e({text:"Log in",className:"btn btn-link px-2",auth0ActiveTab:CI,openInNewTab:!1})]),l=[CP("")("Graduation year"),VY("form-control")({name:"livestream_public_registration_form[high_school_graduation_year]",value:je("")(QY(a.gradYear)(FP)),onChange:un(function(p){return KY(t)(YY(tX.create)(Ts(j3(p))))})})([Qa(Rr(a.gradYear))(QT("")({value:""})("Select one...")),Oe(XY(n.allowedGradYears)(function(p){return QT("")({value:FP(p)})(FP(p))}))])],s=je({path:"",token:"",impersonationToken:""})(YE("livestreams_register_path")),h=E8e([Cy(a.email),a.firstName!=="",a.lastName!=="",Fr(a.gradYear),Fr(a.persona)]);return Oe([i,I8e("")({action:s.path,method:"POST"})([Mm("row")(Mm("col")(r("email")("Email")("Your email")(a.email)(eX.create)({autoFocus:e.autoFocus}))),Mm("row mt-3")(Mm("col")(r("first_name")("First name")("Your first name")(a.firstName)(nX.create)({autoFocus:!1}))),Mm("row mt-3")(Mm("col")(r("last_name")("Last name")("Your last name")(a.lastName)(aX.create)({autoFocus:!1}))),Fy("row mt-3")([Fy("col-6")(l),Fy("col-6")(u)]),Mm("row mt-3")(Fy("col-12")([ZY("btn btn-primary w-100 mt-3 t--register")(vn)({type:"submit",disabled:!h})("Register"),ja(e.cancelButton)(function(p){return ZY("btn btn-outline-primary w-100 mt-3 t--cancel-registration")(vn)({type:"button",onClick:un(function(R){return p.click})})(p.text)})])),VT("")({type:"hidden",name:"authenticity_token",value:s.token}),VT("")({type:"hidden",name:"register_for_conference_id",value:T8e(n.conference.id)}),VT("")({type:"hidden",name:"utm_cv_source",value:n.paths.utmSource})])])}}}},ag=function(e){return function(n){if(n instanceof eX)return Gy({firstName:e.firstName,gradYear:e.gradYear,lastName:e.lastName,persona:e.persona,email:n.value0});if(n instanceof nX)return Gy({email:e.email,gradYear:e.gradYear,lastName:e.lastName,persona:e.persona,firstName:n.value0});if(n instanceof aX)return Gy({email:e.email,firstName:e.firstName,gradYear:e.gradYear,persona:e.persona,lastName:n.value0});if(n instanceof tX)return Gy({email:e.email,firstName:e.firstName,lastName:e.lastName,persona:e.persona,gradYear:new T(n.value0)});if(n instanceof rX)return Gy({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 180, column 16 - line 190, column 36): "+[n.constructor.name])}},tg=(function(){return{email:"",firstName:"",lastName:"",gradYear:G.value,persona:G.value}})();var oX=Pe(Se),S8e=$T(ie),C8e=ro(ie)()(),rg=function(e){return Oe([oX("")([cn(` For college information sessions, we may tell the college that you attended. You can opt out anytime in your profile. `),S8e("")(` 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. `)]),oX("")([cn(` By completing this registration form you agree to CollegeVine\u2019s Website Terms and Conditions, which can be found `),C8e("")(Vr("Open terms and conditions"))({href:e.paths.termsAndConditions})("here"),cn(".")])])};var AP={eq:function(e){return function(n){return e===n}}};var t_=fn(ln)(ma),G8e=Gi(qe),uX=dt(),M8e=mc(uX($({reflectSymbol:function(){return"author"}})(uX($({reflectSymbol:function(){return"cvid"}})(be)($({reflectSymbol:function(){return"username"}})(be)(mn))))($({reflectSymbol:function(){return"id"}})(Dn)($({reflectSymbol:function(){return"isFromHQ"}})(ct)($({reflectSymbol:function(){return"isPublic"}})(ct)($({reflectSymbol:function(){return"text"}})(be)($({reflectSymbol:function(){return"time"}})(be)(mn))))))))(qe),ug=nt(qe),YT=x(ba),Ho=x(Un),LP=js(),A8e=xr(Se),PP=Ct(ie),NP=qu(ie),L8e=Ht(ie),Am=Pe(Se),og=Pe(on),KT=ga(ie)()(),My=Pe(ie),iX=jr(ie),fX=ge(Ye),P8e=zr(Se)()(),N8e=Ct(Se),_X=ae(nn),O8e=zd()(),U8e=$i(Nt)(iu),k8e=X_(Se),B8e=su()(),H8e=$T(ie),J8e=we(qr(Dr)),q8e=ge(ue),lX=ti(nJ(Di(Gl))),$8e=Ou(AP),cX=B(st),W8e=tn(gr),x8e=bs(Je)(AP),sX=$t(Lo(st)),pX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),mX=(function(){function e(){}return e.value=new e,e})(),dX=(function(){function e(){}return e.value=new e,e})(),Lm=(function(){function e(){}return e.value=new e,e})(),XT=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ZT=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),eS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),hX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),gX=(function(){function e(){}return e.value=new e,e})(),OP=(function(){function e(){}return e.value=new e,e})(),UP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),DX=(function(){function e(){}return e.value=new e,e})(),vX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),kP=(function(){function e(){}return e.value=new e,e})(),nS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),aS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),RX=(function(){function e(){}return e.value=new e,e})(),ig=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Ay=(function(){function e(){}return e.value=new e,e})();var yX=function(e){return t_(G8e(function(n){return Ue.create(UP.create(Zp(n)))})(M8e(e.pusher.dataChannel)("question")))(function(){return t_(ug(YT(new Ue(DX.value))))(function(){return Ho({newQuestionText:"",newQuestionBroadcast:!1,questions:[],modal:Lm.value})})})},wX=function(e){if(e.user instanceof G)return new T(new Ue(kP.value));if(e.user instanceof T&&e.user.value0.username instanceof G)return new T(new Ue(RX.value));if(e.user instanceof T&&e.user.value0.username instanceof T)return G.value;throw new Error("Failed pattern match at Livestream.Live.Questions (line 372, column 3 - line 378, column 14): "+[e.user.constructor.name])},j8e=(function(){return xu(Bu(Je)([Zc.value,new ar(":"),Al.value,new ar(" "),es.value]))})(),bX=function(e){return function(n){return function(a){var t=function(s){return a(Ue.create(s))},r=function(s){return LP({id:"question-modal",onDismiss:t(Ay.value),body:Oe([A8e("")([PP("")("By: "),NP("")("@"+s.author.username)]),L8e("")(s.text),ks(""),Am("row align-items-center mb-3")([og("col-4")(KT("btn w-100 btn-"+(function(){return s.isPublic?"secondary":"success"})())(vn)({onClick:un(function(h){return t(new aS(mX.value))})})((function(){return s.isPublic?"Hide from audience":"Show to audience"})())),My("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."})())]),Am("row align-items-center")([og("col-4")(KT("btn w-100 btn-danger")(vn)({onClick:un(function(h){return t(new aS(dX.value))})})("Ban this user")),Am("col")([cn("This user will not be able to ask any more questions "),NP("")("in this livestream. "),PP("text-danger")("There is no way to un-ban a user!")])])]),bodyClass:"t--question-modal",footer:Oe([KT("btn btn-outline-primary px-4")(vn)({onClick:un(function(h){return t(Ay.value)})})("Never mind, close this dialog")])})},u=function(s){return LP({id:"questions-registration-form-modal",onDismiss:t(Ay.value),title:iX("")("Please introduce yourself to participate:"),bodyClass:"t--questions-registration-form",body:Oe([ng({cancelButton:G.value,autoFocus:!0})(e)(s)(function(h){return t(nS.create(h))}),og("small mt-3")(rg(e))])})},i=function(s){return LP({id:"questions-username-modal",onDismiss:t(Ay.value),title:iX("")("Please select a user name"),body:pY(s)(function(h){return t(ig.create(h))}),bodyClass:"t--username-modal"})},l=function(s){var h=function(R){return function(E){return function(w){return Oe([My("ml-2 badge badge-"+E)(R),ja(w)(function(I){return My("ml-2 text-secondary")(j8e(I))})])}}},p=s.isFromHQ&&s.isPublic;return p?h("CollegeVine")("success")(s.time):s.isPublic?h("Question")("warning")(G.value):Aa};return Oe([og("position-relative h-100")(og("d-flex flex-column position-absolute-fullsize")(Am("d-flex flex-column flex-grow-1 min-height-0")([Am("flex-grow-1 min-height-0 overflow-y-auto bg-white border rounded mb-2 p-2 t--questions-list")(fX(n.questions)(function(s){return P8e("p-1 t--question"+(function(){return e.isPrivilegedUser?" cursor-pointer":""})())({onClick:un(function(h){return t(new aS(new pX(s)))})})([N8e("small d-inline-flex align-items-center")([NP("")("@"+s.author.username),l(s),cn(":")]),PP("ml-1")(s.text)])})),Am("")([ja(_X(e.user)(function(s){return s.username}))(function(s){return My("small text-secondary mt-2")("@"+s)}),O8e("form-control t--question-text")({onChange:un(function(s){return t(new hX(FT(s)))}),onClick:un(function(s){return U8e(a)(wX(e))}),placeholder:"Ask a question...",rows:1,value:n.newQuestionText}),Qa(e.isPrivilegedUser)(og("form-check my-2")(k8e("form-check-label d-flex align-items-center t--broadcast-checkbox")([B8e("form-check-input mr-2 mt-0")({type:"checkbox",checked:n.newQuestionBroadcast,onChange:un(function(s){return t(gX.value)})}),My("badge badge-info bg-info text-dark mr-2")("HQ"),cn("Send to all viewers")]))),Am("d-flex justify-content-end align-items-center")([H8e("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. `),KT("mt-2 px-5 btn-sm btn btn-primary t--submit-question")(vn)({onClick:un(function(s){return t(OP.value)}),disabled:n.newQuestionText===""})((function(){return n.newQuestionBroadcast?"Send to all":"Send to host"})())])])]))),(function(){if(n.modal instanceof Lm)return Aa;if(n.modal instanceof ZT)return u(n.modal.value0);if(n.modal instanceof XT)return r(n.modal.value0);if(n.modal instanceof eS)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])})()])}}},z8e=function(e){return function(n){return J8e(q8e(e.user)(function(a){return a.cvid}))(new T(n.author.cvid))||n.isPublic||e.isPrivilegedUser}},EX=function(e){return function(n){return function(a){if(a instanceof Jn)return Ho(n);if(a instanceof Ue){if(a.value0 instanceof hX){var t=wX(e);if(t instanceof T)return t_(ug(YT(t.value0)))(function(){return Ho(n)});if(t instanceof G)return Ho({modal:n.modal,newQuestionBroadcast:n.newQuestionBroadcast,questions:n.questions,newQuestionText:a.value0.value0});throw new Error("Failed pattern match at Livestream.Live.Questions (line 258, column 5 - line 263, column 46): "+[t.constructor.name])}if(a.value0 instanceof gX)return Ho({modal:n.modal,newQuestionText:n.newQuestionText,questions:n.questions,newQuestionBroadcast:!n.newQuestionBroadcast});var t=function(r){if(a.value0 instanceof OP)return t_(ug(YT(new Ue(kP.value))))(function(){return Ho(n)});if(a.value0 instanceof UP)return Ho({modal:n.modal,newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:lX(function(l){return ZE((function(s){return s.time})(l))})(yu(z8e(e))(wu(a.value0.value0)(yu((function(){var l=$8e(a.value0.value0.id);return function(s){return l((function(h){return h.id})(s))}})())(n.questions))))});if(a.value0 instanceof DX)return t_(ug(cX(function(l){return Ue.create(vX.create(l))})(_I(e.conference.id))))(function(){return Ho(n)});if(a.value0 instanceof vX){var u=fX(a.value0.value0)(function(l){return l.id});return Ho({modal:n.modal,newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:lX(function(l){return ZE((function(s){return s.time})(l))})(W8e(a.value0.value0)(yu(function(l){return x8e(l.id)(u)})(n.questions)))})}if(a.value0 instanceof kP)return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new ZT(tg)});var i=function(l){if(a.value0 instanceof nS)return Ho(n);if(a.value0 instanceof RX)return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new eS(dY(je("")(_X(e.user)(function(h){return h.username}))))});if(a.value0 instanceof ig&&a.value0.value0 instanceof Jn&&a.value0.value0.value0 instanceof pP)return t_(ug(YT(new Jn(a.value0.value0.value0.value0))))(function(){return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:Lm.value})});if(a.value0 instanceof ig&&a.value0.value0 instanceof Jn&&a.value0.value0.value0 instanceof mP)return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:Lm.value});var s=function(h){if(a.value0 instanceof ig&&Ve)return Ho(n);if(a.value0 instanceof Ay)return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:Lm.value});if(a.value0 instanceof aS){if(e.isPrivilegedUser){if(a.value0.value0 instanceof pX)return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new XT(a.value0.value0.value0)});var p=function(R){var E=function(w){return Ho(n)};return a.value0.value0 instanceof dX&&n.modal instanceof XT?t_(Bt(Gq({conferenceId:e.conference.id,userCvid:n.modal.value0.author.cvid})))(function(){return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:Lm.value})}):E(!0)};return a.value0.value0 instanceof mX&&n.modal instanceof XT?t_(Bt(yq({questionId:n.modal.value0.id,isPublic:!n.modal.value0.isPublic})))(function(){return Ho({newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:Lm.value})}):p(!0)}if(Ve)return Ho(n)}throw new Error("Failed pattern match at Livestream.Live.Questions (line 254, column 1 - line 254, column 76): "+[a.value0.constructor.name])};return a.value0 instanceof ig&&n.modal instanceof eS?sX(function(h){return Ue.create(ig.create(h))})(function(h){return{newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new eS(h)}})(mY(n.modal.value0)(a.value0.value0)):s(!0)};return a.value0 instanceof nS&&n.modal instanceof ZT?sX(function(l){return Ue.create(nS.create(l))})(function(l){return{newQuestionBroadcast:n.newQuestionBroadcast,newQuestionText:n.newQuestionText,questions:n.questions,modal:new ZT(l)}})(ag(n.modal.value0)(a.value0.value0)):i(!0)};return a.value0 instanceof OP&&e.user instanceof T?t_(ug(cX(function(r){return Ue.create(UP.create(r))})(wq({conferenceId:e.conference.id,text:n.newQuestionText,hqBroadcast:n.newQuestionBroadcast}))))(function(){return Ho({modal:n.modal,questions:n.questions,newQuestionText:"",newQuestionBroadcast:!1})}):t(!0)}throw new Error("Failed pattern match at Livestream.Live.Questions (line 254, column 1 - line 254, column 76): "+[e.constructor.name,n.constructor.name,a.constructor.name])}}};var nu={PRIMARY:"#1557B0",SECONDARY:"#4A5568",SUCCESS:"#007A3D",DANGER:"#C91E3E",WHITE:"#FFF",GRAY_300:"#E3EBF6",GRAY_500:"#6B7C93",GRAY_600:"#5E7290",GRAY_700:"#4A5568"};var Q8e=nu.PRIMARY,K8e=nu.SECONDARY,Y8e=nu.SUCCESS,X8e=nu.DANGER,Z8e=nu.WHITE,e7e=nu.GRAY_300,n7e=nu.GRAY_500,a7e=nu.GRAY_600,BP=nu.GRAY_700;var tS,r7e=new Uint8Array(16);function HP(){if(!tS&&(tS=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),!tS))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return tS(r7e)}var IX=/^(?:[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 o7e(e){return typeof e=="string"&&IX.test(e)}var JP=o7e;var mi=[];for(rS=0;rS<256;++rS)mi.push((rS+256).toString(16).substr(1));var rS;function u7e(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,a=(mi[e[n+0]]+mi[e[n+1]]+mi[e[n+2]]+mi[e[n+3]]+"-"+mi[e[n+4]]+mi[e[n+5]]+"-"+mi[e[n+6]]+mi[e[n+7]]+"-"+mi[e[n+8]]+mi[e[n+9]]+"-"+mi[e[n+10]]+mi[e[n+11]]+mi[e[n+12]]+mi[e[n+13]]+mi[e[n+14]]+mi[e[n+15]]).toLowerCase();if(!JP(a))throw TypeError("Stringified UUID is invalid");return a}var TX=u7e;function i7e(e,n,a){e=e||{};var t=e.random||(e.rng||HP)();if(t[6]=t[6]&15|64,t[8]=t[8]&63|128,n){a=a||0;for(var r=0;r<16;++r)n[a+r]=t[r];return n}return TX(t)}var qP=i7e;var SX=qP;var c7e=function(e){return e},$P=function(e){return e};var WP=ae(uo)(SX)((function(){var e=x(Nt);return function(n){return e(c7e(n))}})());function xP(){return Date.now()}var v7e=B(ca);var Hl=v7e(eE)(xP);var lg=nt(qe),OX=fn(ln),f7e=OX(Na),_7e=tn(t1),p7e=B(st),Py=Hn(qe),m7e=Ht(ie),d7e=Ol(),UX=zr(on)()(),FX=Hg(Gl),h7e=gu(ho),g7e=Yn(al),D7e=oe(r6),GX=oe(Y0),R7e=B(Ye),Vv=OX(ma),y7e=Gi(qe),w7e=mc(dt()($({reflectSymbol:function(){return"authorTag"}})(be)($({reflectSymbol:function(){return"kind"}})(be)(mn))))(qe),iS=B(ca),P0=x(Un),MX=Ut(kd),AX=Bg(Gl),b7e=x(ba),jP=Rv(Nd),E7e=Pe(Se),I7e=ge(Ye),T7e=ga(Se)()(),S7e=Ct(ie),uS=(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})(),Ly=(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})(),kX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),VP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),zP=function(e){return lg(f7e(Wr(_7e(e)(10)))(function(){return p7e(VP.create)(Py(Hl))}))},LX=50,BX=function(e){var n=function(r){return m7e("text-white fe fe-"+r)("")},a=(function(){if(e instanceof Wf)return n("heart");if(e instanceof h0)return n("thumbs-up");if(e instanceof em)return n("thumbs-down");if(e instanceof g0)return n("file-text");if(e instanceof D0)return d7e("")({src:"/img/icons/smile-white.svg",alt:Nl.value,style:Yt({width:"1em"})});throw new Error("Failed pattern match at Livestream.Live.Reactions (line 152, column 10 - line 158, column 100): "+[e.constructor.name])})(),t=(function(){if(e instanceof Wf)return"#F0747B";if(e instanceof h0)return"#008CFD";if(e instanceof em)return BP;if(e instanceof g0)return"#18A668";if(e instanceof D0)return"#F6C343";throw new Error("Failed pattern match at Livestream.Live.Reactions (line 160, column 21 - line 165, column 32): "+[e.constructor.name])})();return UX("d-flex justify-content-center align-items-center rounded-circle")({style:Yt({backgroundColor:t,height:"1.5rem",width:"1.5rem"})})(a)},HX=6,PX=(function(){return HX*1e3})(),JX=function(e){return function(n){var a=function(t){if(FX(t.removeAt)(e.currentTime))return Aa;var r=br(h7e(g7e(Wc(LD(t.startDecayAt))))(10)),u=(function(){var p=r<=3;if(p)return"linear";var R=r<=7;return R?"ease-in":"ease"})(),i=t.reaction.authorTag===e.authorTag,l=1+(r-5)/4,s=FX(t.startDecayAt)(e.currentTime),h=HX+(r-5)/10;return UX("position-absolute mb-4 mt-2")({key:D7e(t.startDecayAt),style:Yt({right:GX(l)+"rem",top:(function(){return s?"0":"90%"})(),opacity:(function(){return s?0:i?1:.6})(),transitionProperty:"top opacity",transitionDuration:GX(h)+"s",transitionTimingFunction:u})})(BX(t.reaction.kind))};return Oe(R7e(a)(e.reactions))}},qX=function(e){return Vv(y7e(function(n){return new Ly(SB(n),G.value)})(w7e(e.pusher.dataChannel)("reaction")))(function(){return Vv(lg(Py(iS(function(n){return kX.create($P(n))})(WP))))(function(){return Vv(lg(Py(iS(VP.create)(Hl))))(function(){return P0({authorTag:"",currentTime:MX,coolDownUntil:MX,reactions:[]})})})})},NX=800,$X=function(e){return function(n){return function(a){if(a instanceof uS&&a.value1 instanceof G)return Vv(lg(Py(iS((function(){var t=uS.create(a.value0);return function(r){return t(T.create(r))}})())(Hl))))(function(){return P0(n)});if(a instanceof uS&&a.value1 instanceof T){if(AX(n.coolDownUntil)(a.value1.value0))return Vv(lg(b7e(new Ly({kind:a.value0,authorTag:n.authorTag},new T(a.value1.value0)))))(function(){return P0(n)});if(Ve)return Vv(Bt(Sq(e.conference.id)({authorTag:n.authorTag,kind:a.value0})))(function(){return Vv(zP(NX))(function(){return P0({authorTag:n.authorTag,currentTime:n.currentTime,reactions:n.reactions,coolDownUntil:je(a.value1.value0)(jP(NX)(a.value1.value0))})})})}if(a instanceof Ly&&a.value1 instanceof G)return Vv(lg(Py(iS((function(){var t=Ly.create(a.value0);return function(r){return t(T.create(r))}})())(Hl))))(function(){return P0(n)});if(a instanceof Ly&&a.value1 instanceof T)return Vv(zP(LX))(function(){return Vv(zP(PX))(function(){var t={reaction:a.value0,startDecayAt:je(a.value1.value0)(jP(LX)(a.value1.value0)),removeAt:je(a.value1.value0)(jP(PX)(a.value1.value0))};return P0({authorTag:n.authorTag,coolDownUntil:n.coolDownUntil,reactions:pp(n.reactions)(t),currentTime:a.value1.value0})})});if(a instanceof kX)return P0({coolDownUntil:n.coolDownUntil,currentTime:n.currentTime,reactions:n.reactions,authorTag:a.value0});if(a instanceof VP)return P0({authorTag:n.authorTag,coolDownUntil:n.coolDownUntil,reactions:yu(function(t){return AX(t.removeAt)(a.value0)})(n.reactions),currentTime:a.value0});throw new Error("Failed pattern match at Livestream.Live.Reactions (line 171, column 22 - line 215, column 8): "+[a.constructor.name])}}},WX=function(e){return function(n){var a=function(t){if(t instanceof Wf)return"love this";if(t instanceof h0)return"helpful";if(t instanceof em)return"not helpful";if(t instanceof g0)return"taking notes";if(t instanceof D0)return"LOL";throw new Error("Failed pattern match at Livestream.Live.Reactions (line 139, column 11 - line 144, column 28): "+[t.constructor.name])};return E7e("d-flex justify-content-end my-2")(I7e([Wf.value,D0.value,h0.value,g0.value])(function(t){return T7e("btn bg-light d-flex align-items-center p-0 ml-3")(Vr(a(t)))({onClick:un(function(r){return n(new uS(t,G.value))}),style:Yt({borderRadius:"1em"})})([BX(t),S7e("d-none d-md-inline text-secondary small ml-2 mr-3")(a(t))])}))}};var eZ=fn(ln),F7e=ae(Na),KP=Hn(qe),lS=x(ba),vS=xr(ie),cS=oe(pn),Ny=eZ(ma),Oy=nt(qe),fs=x(Un),xX=Mr(Yo),jX=Nu(UD),zX=B(st),G7e=ai(Un)(iu),M7e=Ml(If),VX=Pe(ie),A7e=xs(),L7e=jr(ie),QX=ga(ie)()(),KX=Pe(on),P7e=ga(Se)()(),N7e=Ht(ie),O7e=Pe(Se),nZ=(function(){function e(){}return e.value=new e,e})(),aZ=(function(){function e(){}return e.value=new e,e})(),tZ=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),rZ=(function(){function e(){}return e.value=new e,e})(),YX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),oZ=(function(){function e(){}return e.value=new e,e})(),XX=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),YP=(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(){}return e.value=new e,e})(),XP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),QP=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),sS=(function(){function e(){}return e.value=new e,e})(),lZ=eZ(Na)(Wr(1e3))(function(){return F7e(KP(Hl))(function(e){return lS(new XP(e))})}),U7e=function(e){return{header:"Go on-air?",body:Oe([vS("")("Are you sure you want to go on-air?"),vS("mb-0 font-weight-bold fw-bold")(` Watchers will start seeing your stream in `+(cS(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:rZ.value}},ZX=function(e){return function(n){return function(a){return function(t){return Ny(Oy(lZ))(function(){return fs({confirmation:n.confirmation,network:nZ.value,streamStatus:t,transition:new T({since:a,secondsLeft:e.videoLagSeconds})})})}}}},cZ=function(e){return function(n){return function(a){if(a instanceof rZ)return Ny(Oy(xX(jX(mq(e.conference.id))(zX(YX.create)(KP(Hl))))(function(l){return lS(new QP("Error opening the stream. Please try again."))})))(function(){return fs({confirmation:n.confirmation,streamStatus:n.streamStatus,transition:n.transition,network:aZ.value})});if(a instanceof YX)return ZX(e)(n)(a.value0)(fu.value);if(a instanceof oZ)return Ny(Oy(xX(jX(dq(e.conference.id))(zX(XX.create)(KP(Hl))))(function(l){return lS(new QP("Error closing the stream. Please try again."))})))(function(){return fs(n)});if(a instanceof XX)return ZX(e)(n)(a.value0)(Uo.value);if(a instanceof YP)return fs({network:n.network,streamStatus:n.streamStatus,transition:n.transition,confirmation:new T(a.value0)});if(a instanceof uZ)return Ny(G7e(n.confirmation)(function(l){return Oy(lS(l.confirmMsg))}))(function(){return fs({network:n.network,streamStatus:n.streamStatus,transition:n.transition,confirmation:G.value})});if(a instanceof iZ)return fs({network:n.network,streamStatus:n.streamStatus,transition:n.transition,confirmation:G.value});if(a instanceof QP)return fs({confirmation:n.confirmation,streamStatus:n.streamStatus,transition:n.transition,network:new tZ(a.value0)});var t=function(l){if(a instanceof XP||a instanceof sS)return fs(n);throw new Error("Failed pattern match at Livestream.Live.StreamControls (line 191, column 1 - line 191, column 76): "+[a.constructor.name])};if(a instanceof XP){if(n.transition instanceof T){var r=M7e(a.value0)(n.transition.value0.since),u=e.videoLagSeconds-ku(r)|0,i=u>0;return i?Ny(Oy(lZ))(function(){return fs({confirmation:n.confirmation,network:n.network,streamStatus:n.streamStatus,transition:new T({since:n.transition.value0.since,secondsLeft:u})})}):fs({confirmation:n.confirmation,network:n.network,streamStatus:n.streamStatus,transition:G.value})}return t(!0)}return t(!0)}}},sZ=function(e){return fs({streamStatus:e.streamStatus,transition:G.value,network:nZ.value,confirmation:G.value})},k7e=(function(){return{header:"End the stream?",body:Oe([vS("")("Are you sure you want to end the stream?"),vS("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:oZ.value}})(),vZ=function(e){return function(n){return function(a){var t=(function(){return n.network instanceof aZ?VX("position-absolute-fullsize d-flex align-items-center justify-content-center bg-semi-transparent-white")("Switching..."):Aa})(),r=function(h){return A7e({id:"stream-controls-confirmation-modal",header:L7e("my-0")(h.header),bodyClass:"p-5",body:h.body,footerClass:"p-4",footer:Oe([QX("btn btn-primary px-4")(vn)({onClick:un(function(p){return a(uZ.value)})})(h.confirmText),QX("btn btn-outline-primary px-4")(vn)({onClick:un(function(p){return a(iZ.value)})})(h.cancelText)])})},u=function(h){return function(p){return function(R){return function(E){return function(w){return KX("col-auto pr-0")(P7e("btn btn-"+(h+(" px-5 d-flex align-items-center font-size-lg btn-"+E)))(vn)({onClick:un(function(I){return a(w)})})([N7e("fe mr-2 fe-"+p)(""),cn(R)]))}}}}},i=(function(){if(n.streamStatus instanceof ol)return u("lg")("power")("GO ON-AIR")("outline-secondary")(new YP(U7e(e)));var h=function(p){if(n.streamStatus instanceof fu)return Oe([u("lg")("radio")("ON AIR")("success")(sS.value),u("sm")("x-circle")("End stream")("outline-danger")(new YP(k7e))]);if(n.streamStatus instanceof Uo)return u("lg")("slash")("STREAM IS OVER")("outline-secondary")(sS.value);throw new Error("Failed pattern match at Livestream.Live.StreamControls (line 70, column 1 - line 70, column 71): "+[n.streamStatus.constructor.name])};return n.streamStatus instanceof fu&&n.transition instanceof T?u("lg")("radio")("ON AIR")("success")(sS.value):h(!0)})(),l=function(h){return VX("alert small m-0 flex-grow-1 alert-"+h)},s=(function(){if(n.network instanceof tZ)return l("danger")(n.network.value0);if(n.streamStatus instanceof ol)return l("warning")("The stream has not been started yet. To start, click the big 'GO ON-AIR' button on the left.");var h=function(p){if(n.streamStatus instanceof fu)return l("light")(` We're live. The audience should see your video with a `+(cS(e.videoLagSeconds)+`-second delay. If you don't see your face above (give it a few seconds), it means you're not streaming. `));var R=function(E){if(n.streamStatus instanceof Uo)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 70, column 1 - line 70, column 71): "+[n.streamStatus.constructor.name,n.network.constructor.name])};return n.streamStatus instanceof Uo&&n.transition instanceof T?l("info")("You may stop presenting now. The audience will keep seeing the tail of the stream for another "+(cS(n.transition.value0.secondsLeft)+" seconds.")):R(!0)};return n.streamStatus instanceof fu&&n.transition instanceof T?l("info")("Start presenting now. The audience will see the stream in "+(cS(n.transition.value0.secondsLeft)+" seconds...")):h(!0)})();return O7e("position-relative row align-items-center t--stream-controls")([i,KX("col")(s),t,ja(n.confirmation)(r)])}}};var H7e=Rv(Cp),pZ=Ml(Cp),fZ=ak(),J7e=js(),q7e=jr(ie),$7e=Pe(ie),_Z=xr(ie),W7e=ga(ie)()(),mZ=nt(qe),dZ=fn(ln),hZ=B(st),gZ=Hn(qe),DZ=dZ(ma),x7e=wi(Je)(Wt),ZP=x(Un),nN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),eN=(function(){function e(){}return e.value=new e,e})(),j7e=[30,15,5,0],RZ=function(e){return je(e.conference.scheduledStartTime)(H7e(br(e.conference.duration))(e.conference.scheduledStartTime))},yZ=function(e){return function(n){return function(a){if(!n.modal)return Aa;if(n.now instanceof G)return Aa;if(n.now instanceof T){var t=RZ(e),r=pZ(t)(n.now.value0),u=(function(){if(r<1)return" ended "+fZ({from:t,to:n.now.value0,format:_E("ago")});if(Ve)return" ends "+fZ({from:n.now.value0,to:t,format:_E("from now")});throw new Error("Failed pattern match at Livestream.Live.StreamEndWarning (line 77, column 3 - line 80, column 101): ")})();return J7e({id:"stream-end-warning-modal",onDismiss:a(eN.value),body:Oe([q7e("mb-0")("Host-only warning"),$7e("text-secondary mb-4")("You see this because you're the host. The audience doesn't see this."),_Z("font-weight-bold fw-bold")("\u23F0 Scheduled stream time "+u),_Z("")(` You have `+(fc(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. `)),W7e("btn btn-primary px-4")(vn)({onClick:un(function(i){return a(eN.value)})})("Got it")])})}throw new Error("Failed pattern match at Livestream.Live.StreamEndWarning (line 44, column 1 - line 44, column 71): "+[e.constructor.name,n.constructor.name,a.constructor.name])}}},z7e=mZ(dZ(Na)(Wr(60100))(function(){return hZ(nN.create)(gZ(p0))})),wZ=function(e){return function(n){return function(a){if(a instanceof nN)return DZ(z7e)(function(){var t=pZ(RZ(e))(a.value0),r=x7e(ku(t))(j7e);return ZP({now:new T(a.value0),modal:n.modal||r})});if(a instanceof eN)return ZP({now:n.now,modal:!1});throw new Error("Failed pattern match at Livestream.Live.StreamEndWarning (line 83, column 22 - line 95, column 33): "+[a.constructor.name])}}},bZ=(function(){return DZ(mZ(hZ(nN.create)(gZ(p0))))(function(){return ZP({modal:!1,now:G.value})})})();var CZ=fn(ln),Q7e=CZ(Na),EZ=x(ba),K7e=CZ(ma),Y7e=nt(qe),X7e=Mr(Yo),_S=x(Un),Z7e=we(DR),FZ=Bu(Je),aN=Pe(Se),fS=Ht(ie),eOe=ga(ie)()(),nOe=ro(ie)()(),aOe=ga(on)()(),tOe=xs(),IZ=Pe(on),rOe=qu(ie),oOe=bv(ie)()(),uOe=Ct(ie),GZ=(function(){function e(){}return e.value=new e,e})(),MZ=(function(){function e(){}return e.value=new e,e})(),tN=(function(){function e(){}return e.value=new e,e})(),AZ=(function(){function e(){}return e.value=new e,e})(),LZ=(function(){function e(){}return e.value=new e,e})(),TZ=(function(){function e(){}return e.value=new e,e})(),SZ=(function(){function e(){}return e.value=new e,e})(),iOe=(function(){function e(){}return e.value=new e,e})(),PZ=function(e){return function(n){return function(a){var t=Q7e(vI({fromConference:new T(e.conference.id),registerForConference:n.cta.conferenceId,utmSource:e.paths.utmSource}))(function(){return EZ(new Ue(TZ.value))});if(a instanceof LZ)return K7e(Y7e(X7e(t)(function(r){return EZ(new Ue(SZ.value))})))(function(){return _S({cta:n.cta,stage:MZ.value})});if(a instanceof TZ)return _S({cta:n.cta,stage:AZ.value});if(a instanceof SZ)return _S({cta:n.cta,stage:tN.value});throw new Error("Failed pattern match at Livestream.Ctas.Display.Event (line 135, column 24 - line 145, column 44): "+[a.constructor.name])}}},NZ=function(e){return function(n){return Z7e(e.cta.conferenceId)(n.conferenceId)}},OZ=function(e){return _S({cta:e,stage:GZ.value})},lOe=(function(){return xu(FZ([qs.value,new ar(", "),Js.value,new ar(" "),Xc.value,new ar(" at "),Zc.value,new ar(":"),Al.value,new ar(" "),es.value]))})(),cOe=(function(){return xu(FZ([qs.value]))})(),UZ=function(e){return function(n){return function(a){var t=(function(){return n.stage instanceof tN?aN("text-danger small mt-2")([fS("fe fe-x-circle mr-2")(""),cn("Something went wrong. Please try again.")]):Aa})(),r=function(h){return a(Ue.create(h))},u=(function(){if(e.user instanceof T)return eOe("btn btn-primary px-4 t--register-one-click")(Vr("Register for this livestream"))({onClick:un(function(h){return r(LZ.value)})})("Register (one-click)");if(e.user instanceof G)return nOe("btn btn-primary px-4 t--register-new-tab")(Vr("Register for this livestream"))({href:n.cta.registrationPath,target:"_blank",rel:"noopener"})("Register now");throw new Error("Failed pattern match at Livestream.Ctas.Display.Event (line 86, column 20 - line 96, column 23): "+[e.user.constructor.name])})(),i=(function(){if(n.stage instanceof GZ||n.stage instanceof tN)return u;if(n.stage instanceof MZ)return aN("text-secondary")([fS("fe fe-refresh-cw mr-2")(""),cn("Hold on tight...")]);if(n.stage instanceof AZ)return aN("text-success")([fS("fe fe-check-circle mr-2")(""),cn("You\u2019ve registered \u2013\xA0see you "+(cOe(n.cta.startTime)+"!"))]);throw new Error("Failed pattern match at Livestream.Ctas.Display.Event (line 70, column 34 - line 84, column 10): "+[n.stage.constructor.name])})(),l=function(h){return a(Jn.create(h))},s=aOe("btn btn-sm btn-outline-primary d-flex py-1 px-2")(Vr("Close"))({onClick:un(function(h){return l(iOe.value)})})(fS("fe fe-x")(""));return tOe({id:"livestream-event-cta-modal",body:Oe([IZ("row justify-content-end mt-n3")(s),rOe("")("Join us for our upcoming livestream:"),oOe("mt-3")({id:pc})(n.cta.title),uOe("small")(lOe(n.cta.startTime)+(" "+Xp)),IZ("row mt-6 ml-0")(i),t]),bodyClass:"t--cta-active",size:UR.value})}}};var vOe=xs(),pS=Pe(Se),fOe=P1(ie)()(),mS=Pe(on),_Oe=ga(on)()(),pOe=Ht(ie),mOe=ge(Ye),dOe=jc()(),hOe=vu(ie),gOe=xr(ie),DOe=ro(ie)()(),ROe=fn(ln),yOe=ROe(ma),wOe=nt(qe),bOe=Hn(qe),EOe=Vf(Go)(),IOe=oe(pn),kZ=x(Un),TOe=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),BZ=(function(){function e(){}return e.value=new e,e})(),HZ=function(e){return function(n){var a=(function(){var i=Wo(e.cta.providers);return i===1?I0.value:i===2?I0.value:kR.value})(),t=function(i){return n(Ue.create(i))},r=function(i){return n(Jn.create(i))},u=(function(){var i=Wo(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 vOe({id:"featured-service-providers-cta-modal",bodyClass:"bg-gray-900 text-white t--cta-active",body:Oe([pS("row no-gutters g-0 mb-4")([pS("col text-center")([fOe("mb-2")({id:pc})("The admissions process is hard - advisors are here to help!"),cn("Schedule a free consultation to get your questions answered")]),mS("col-auto text-right")(_Oe("btn btn-link p-0 m-0 text-white")(Vr("Close"))({onClick:un(function(i){return r(BZ.value)})})(pOe("fe fe-x")("")))]),pS("row text-center")(mOe(e.cta.providers)(function(i){return pS(u)([mS("row mb-3")(mS("col-auto mx-auto")(mS("avatar avatar-xl")(dOe("avatar-img rounded-circle img-fluid")({src:i.avatarUrl,alt:i.name})))),hOe("mb-2")(i.name),gOe("mb-3")(i.location),DOe("btn btn-primary btn-sm px-3 py-1")(vn)({target:"_blank",href:i.linkUrl,onClick:un(function(l){return t(new TOe(i.avatarUrl))})})(e.cta.linkText)])}))]),size:a})}},JZ=function(e){return function(n){return yOe(wOe(bOe(function(){return EOe("Livestream: CTA Popup Link Clicked")({livestream_cta_id:IOe(e.cta.id),livestream_cta_url:n.value0})(),new Jn(BZ.value)})))(function(){return kZ(e)})}},qZ=function(e){return function(n){return e.cta.id===n.id}},$Z=function(e){return kZ({cta:e})};var COe=ro(ie)()(),FOe=ga(on)()(),GOe=Ht(ie),MOe=xs(),WZ=Pe(on),AOe=bv(ie)()(),LOe=fn(ln),POe=LOe(ma),NOe=nt(qe),OOe=Hn(qe),UOe=Vf(Go)(),kOe=oe(pn),xZ=x(Un),BOe=(function(){function e(){}return e.value=new e,e})(),jZ=(function(){function e(){}return e.value=new e,e})(),zZ=function(e){return function(n){var a=function(i){return n(Ue.create(i))},t=COe("btn btn-primary px-4 t--register-new-tab")(vn)({href:e.cta.url,target:"_blank",rel:"noopener",onClick:un(function(i){return a(BOe.value)})})(e.cta.buttonText),r=function(i){return n(Jn.create(i))},u=FOe("btn btn-sm btn-outline-primary d-flex py-1 px-2")(Vr("Close"))({onClick:un(function(i){return r(jZ.value)})})(GOe("fe fe-x")(""));return MOe({id:"general-cta-modal",body:Oe([WZ("row justify-content-end mt-n3")(u),AOe("mt-3")({id:pc})(e.cta.title),WZ("row mt-6 ml-0")(t)]),bodyClass:"t--cta-active",size:UR.value})}},VZ=function(e){return function(n){return POe(NOe(OOe(function(){return UOe("Livestream: CTA Popup Link Clicked")({livestream_cta_id:kOe(e.cta.id),livestream_cta_title:e.cta.title,livestream_cta_url:e.cta.url})(),new Jn(jZ.value)})))(function(){return xZ(e)})}},QZ=function(e){return function(n){return e.cta.id===n.id}},KZ=function(e){return xZ({cta:e})};var uN=fn(ln),Jl=uN(nn),ql=Qo(hu),cg=x(ka),YZ=Yr(uu(Ot)),Uy=La(du),r_=x(Un),JOe=uN(ma),qOe=nt(qe),$Oe=uN(Na),WOe=x(ba),rN=Pe(Se),xOe=X_(ie),jOe=su()(),zOe=ga(on)()(),VOe=Ht(ie),QOe=xs(),oN=Pe(on),KOe=bv(ie)()(),YOe=xr(ie),XOe=ga(ie)()(),XZ=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ZZ=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),eee=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),nee=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),aee=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),tee=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ree=(function(){function e(){}return e.value=new e,e})(),oee=(function(){function e(){}return e.value=new e,e})(),uee=function(e){return function(n){return e.cta.id===n.id}},iee=function(e){return function(n){var a=Jl(ql(n.cta.requireReferredUserLastName))(function(){return Jl(ql(n.referredUserLastName===""))(function(){return cg("Please enter the other person\u2019s last name")})}),t=Jl(ql(n.cta.requireReferredUserFirstName))(function(){return Jl(ql(n.referredUserFirstName===""))(function(){return cg("Please enter the other person\u2019s first name")})}),r=Jl(ql(YZ(Cy)(n.referredUserEmail)))(function(){return cg("Please enter a valid email address")}),u=Jl(ql(Rr(e.user)))(function(){return Jl(ql(n.cta.requireAnonymousUserLastName))(function(){return Jl(ql(n.anonymousUserLastName===""))(function(){return cg("Please enter your last name")})})}),i=Jl(ql(Rr(e.user)))(function(){return Jl(ql(n.cta.requireAnonymousUserFirstName))(function(){return Jl(ql(n.anonymousUserFirstName===""))(function(){return cg("Please enter your first name")})})}),l=Jl(ql(Rr(e.user)))(function(){return Jl(ql(n.cta.requireAnonymousUserEmail))(function(){return Jl(ql(YZ(Cy)(n.anonymousUserEmail)))(function(){return cg("Please enter a valid email address")})})});return Uy(i)(Uy(u)(Uy(l)(Uy(t)(Uy(a)(r)))))}},lee=function(e){return function(n){return function(a){if(a instanceof XZ)return r_({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 ZZ)return r_({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 eee)return r_({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 nee)return r_({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 aee)return r_({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 tee)return r_({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 ree){var t=Rr(iee(e)(n));return t?JOe(qOe($Oe(hq({ctaId:n.cta.id,anonymousUserFirstName:n.anonymousUserFirstName,anonymousUserLastName:n.anonymousUserLastName,anonymousUserEmail:n.anonymousUserEmail,referredUserFirstName:n.referredUserFirstName,referredUserLastName:n.referredUserLastName,referredUserEmail:n.referredUserEmail}))(function(){return WOe(new Jn(oee.value))})))(function(){return r_(n)}):r_({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 152, column 24 - line 180, column 45): "+[a.constructor.name])}}},cee=function(e){return function(n){return function(a){var t=iee(e)(n),r=function(E){return function(w){return function(I){return function(L){return function(U){return rN(E)([xOe("mb-2")(I),jOe("form-control "+w)({type:"text",value:L,onChange:un(function(V){return a(new Ue(U(Zf(V))))})})])}}}}},u=Qa(Rr(e.user)&&n.cta.requireAnonymousUserEmail)(r("col-12 mb-3")("t--anon-email")("Your email")(n.anonymousUserEmail)(eee.create)),i=Qa(Rr(e.user))(Oe([Qa(n.cta.requireAnonymousUserFirstName)(r("col-12 col-md-6 mb-3")("t--anon-first-name")("Your first name")(n.anonymousUserFirstName)(XZ.create)),Qa(n.cta.requireAnonymousUserLastName)(r("col-12 col-md-6 mb-3")("t--anon-last-name")("Your last name")(n.anonymousUserLastName)(ZZ.create))])),l=r("col-12 mb-3")("t--referred-email")("Other person\u2019s email")(n.referredUserEmail)(tee.create),s=Oe([Qa(n.cta.requireReferredUserFirstName)(r("col-12 col-md-6 mb-3")("t--referred-first-name")("Other person\u2019s first name")(n.referredUserFirstName)(nee.create)),Qa(n.cta.requireReferredUserLastName)(r("col-12 col-md-6 mb-3")("t--referred-last-name")("Other person\u2019s last name")(n.referredUserLastName)(aee.create))]),h=function(E){return a(Ue.create(E))},p=function(E){return a(Jn.create(E))},R=zOe("btn btn-sm btn-outline-primary d-flex py-1 px-2 t--close")(Vr("Close"))({onClick:un(function(E){return p(oee.value)})})(VOe("fe fe-x")(""));return QOe({id:"referral-cta-modal",body:Oe([oN("row justify-content-end mt-n3")(R),KOe("mt-3")({id:pc})(n.cta.title),ja(n.cta.description)(YOe("")),rN("row")([i,u,s,l]),rN("row")([oN("col-auto my-auto")(XOe("btn btn-primary t--save")(vn)({onClick:un(function(E){return h(ree.value)})})("Save")),oN("col my-auto text-danger")(Qa(n.validationActive)(ja(t)(cn)))])]),bodyClass:"t--cta-active",size:I0.value})}}},see=function(e){return r_({cta:e,anonymousUserFirstName:"",anonymousUserLastName:"",anonymousUserEmail:"",referredUserFirstName:"",referredUserLastName:"",referredUserEmail:"",validationActive:!1})};var e6e=nt(qe),n6e=x(ba),N0=$t(Lo(st)),dS=fn(ln)(ma),ky=x(Un),By=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Hy=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Jy=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),qy=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),hS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),gS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),DS=(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})(),a6e=(function(){function e(){}return e.value=new e,e})(),vee=function(e){return function(n){return function(a){var t=function(r){return a(Ue.create(r))};if(n instanceof By)return UZ(e)(n.value0)(function(r){return t(hS.create(r))});if(n instanceof Hy)return HZ(n.value0)(function(r){return t(gS.create(r))});if(n instanceof Jy)return zZ(n.value0)(function(r){return t(DS.create(r))});if(n instanceof qy)return cee(e)(n.value0)(function(r){return t(RS.create(r))});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 57, column 29 - line 65, column 61): "+[n.constructor.name])}}},fee=function(e){return function(n){return function(a){var t=e6e(n6e(new Jn(a6e.value)));if(n instanceof By&&a instanceof hS){if(a.value0 instanceof Ue)return N0(function(r){return Ue.create(hS.create(r))})(By.create)(PZ(e)(n.value0)(a.value0.value0));if(a.value0 instanceof Jn)return dS(t)(function(){return ky(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 72, column 5 - line 77, column 19): "+[a.value0.constructor.name])}if(n instanceof Hy&&a instanceof gS){if(a.value0 instanceof Ue)return N0(function(r){return Ue.create(gS.create(r))})(Hy.create)(JZ(n.value0)(a.value0.value0));if(a.value0 instanceof Jn)return dS(t)(function(){return ky(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 80, column 5 - line 86, column 19): "+[a.value0.constructor.name])}if(n instanceof Jy&&a instanceof DS){if(a.value0 instanceof Ue)return N0(function(r){return Ue.create(DS.create(r))})(Jy.create)(VZ(n.value0)(a.value0.value0));if(a.value0 instanceof Jn)return dS(t)(function(){return ky(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 89, column 5 - line 94, column 19): "+[a.value0.constructor.name])}if(n instanceof qy&&a instanceof RS){if(a.value0 instanceof Ue)return N0(function(r){return Ue.create(RS.create(r))})(qy.create)(lee(e)(n.value0)(a.value0.value0));if(a.value0 instanceof Jn)return dS(t)(function(){return ky(n)});throw new Error("Failed pattern match at Livestream.Ctas.Display (line 97, column 5 - line 103, column 19): "+[a.value0.constructor.name])}return ky(n)}}},_ee=function(e){return function(n){return e instanceof By&&n instanceof ns?NZ(e.value0)(n.value0):e instanceof Jy&&n instanceof as?QZ(e.value0)(n.value0):e instanceof Hy&&n instanceof ts?qZ(e.value0)(n.value0):e instanceof qy&&n instanceof rs?uee(e.value0)(n.value0):!1}},pee=function(e){if(e instanceof ns)return N0(function(n){return Ue.create(hS.create(n))})(By.create)(OZ(e.value0));if(e instanceof ts)return N0(function(n){return Ue.create(gS.create(n))})(Hy.create)($Z(e.value0));if(e instanceof as)return N0(function(n){return Ue.create(DS.create(n))})(Jy.create)(KZ(e.value0));if(e instanceof rs)return N0(function(n){return Ue.create(RS.create(n))})(qy.create)(see(e.value0));throw new Error("Failed pattern match at Livestream.Ctas.Display (line 45, column 8 - line 54, column 66): "+[e.constructor.name])};var mee=jr(ie),yS=Pe(Se),r6e=qu(ie),o6e=bv(ie)()(),gee=Es(I_),u6e=X_(Se),i6e=su()(),lN=wi(Je)(Wt),dee=ga(ie)()(),l6e=Eh(on),c6e=Hn(qe),s6e=zf(Go),v6e=El(),f6e=oe(pn),Pm=x(Un),_6e=C_(Wt),Nm=fn(ln)(ma),p6e=Mr(Yo),iN=x(ba),m6e=ai(ba)(Je),d6e=Sr(ba),hee=nt(qe),h6e=$t(Lo(st)),sg=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),cN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),sN=(function(){function e(){}return e.value=new e,e})(),Dee=(function(){function e(){}return e.value=new e,e})(),vN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Ree=function(e){return function(n){return function(a){var t=Oe([mee("text-center")("The host just asked a poll question!"),mee("text-center")("To participate in live polls, please introduce yourself:"),ng({cancelButton:new T({text:"Not now",click:a(new sg({keepShowingPolls:!1}))}),autoFocus:!0})(e)(n.registration)(function(i){return a(vN.create(i))}),yS("small mt-3")([rg(e),yS("mt-2")([cn("After submitting, you\u2019ll be able to answer all "),r6e("")("future"),cn(" poll questions in this stream!")])])]),r=Oe([o6e("font-weight-bold fw-bold")({id:pc})(n.poll.question),yS("d-flex flex-column ml-4")(gee(function(i){return function(l){return u6e("form-check-label mb-2")([i6e("form-check-input mt-2 t--option")({checked:lN(i)(n.selected),onChange:un(function(s){return a(new cN(i))}),type:(function(){return n.poll.multiSelect?"checkbox":"radio"})()}),cn(l)])}})(n.poll.options)),yS("d-flex justify-content-start mt-6")([dee("btn btn-primary px-4 mr-3 t--submit")(vn)({onClick:un(function(i){return a(sN.value)}),disabled:xi(n.selected)})("Submit answer"),dee("btn btn-outline-primary px-4 d-flex align-items-center t--skip")(vn)({onClick:un(function(i){return a(Dee.value)})})("Do it later")])]),u=(function(){if(e.user instanceof T)return"t--poll-active";if(e.user instanceof G)return"t--poll-registration-form";throw new Error("Failed pattern match at Livestream.Polls.DisplayPoll (line 55, column 16 - line 57, column 43): "+[e.user.constructor.name])})();return l6e(u)({id:"livestream-poll-display-modal"})((function(){if(e.user instanceof T)return r;if(e.user instanceof G)return t;throw new Error("Failed pattern match at Livestream.Polls.DisplayPoll (line 51, column 5 - line 53, column 34): "+[e.user.constructor.name])})())}}},yee=function(e){return function(n){return function(a){var t=function(r){return c6e(s6e("Livestream: Poll Response")(Ef(d0(e.conference))(v6e({livestream_poll_id:f6e(n.poll.id),livestream_poll_question:n.poll.question,livestream_poll_skipped:(function(){return r.skipped?"true":""})(),livestream_poll_multiselect:(function(){return n.poll.multiSelect?"true":"false"})(),livestream_poll_response:r.option}))))};if(a instanceof sg)return Pm(n);if(a instanceof cN&&n.poll.multiSelect)return Pm({poll:n.poll,registration:n.registration,selected:(function(){var r=lN(a.value0)(n.selected);return r?_6e(a.value0)(n.selected):wu(a.value0)(n.selected)})()});if(a instanceof cN)return Pm({poll:n.poll,registration:n.registration,selected:[a.value0]});if(a instanceof sN&&xi(n.selected))return Pm(n);if(a instanceof sN)return Nm(Bt(p6e(A2(n.poll)(n.selected))(function(r){return cc(Kc)("Error answering a Livestream poll")({poll_id:n.poll.id})(function(u){return iN(void 0)})})))(function(){return Nm(Bt(m6e(gee(function(r){return function(u){return{idx:r,opt:u}}})(n.poll.options))(function(r){return d6e(lN(r.idx)(n.selected))(t({skipped:!1,option:r.opt}))})))(function(){return Nm(hee(iN(new sg({keepShowingPolls:!0}))))(function(){return Pm(n)})})});if(a instanceof Dee)return Nm(Bt(A2(n.poll)([])))(function(){return Nm(Bt(t({skipped:!0,option:""})))(function(){return Nm(hee(iN(new sg({keepShowingPolls:!0}))))(function(){return Pm(n)})})});if(a instanceof vN)return h6e(vN.create)(function(r){return{poll:n.poll,selected:n.selected,registration:r}})(ag(n.registration)(a.value0));throw new Error("Failed pattern match at Livestream.Polls.DisplayPoll (line 109, column 24 - line 155, column 57): "+[a.constructor.name])}}},wee=function(e){return Nm(Bt(gq(e)))(function(){return Pm({poll:e,selected:[],registration:tg})})};var Fee=fn(ln),D6e=Fee(Na),R6e=ae(Na),bee=Hn(qe),y6e=ai(ba)(iu),w6e=zf(Go),Eee=El(),b6e=oe(id),E6e=oe($s),wS=oe(pn),_s=x(Un),Gee=Lo(st),Iee=$t(Gee),Tee=ae(ma),See=wr(Gee),U0=Fee(ma),I6e=we(Wt),O0=x(ka),$y=Yd(qe),Wy=B(ue),T6e=B(ki),xy=_f(Je),mN=dt(),Cee=mc(mN($({reflectSymbol:function(){return"poll_id"}})(Dn)(mn)))(qe),S6e=Gi(qe),C6e=we(qr(DR)),F6e=mc(mN($({reflectSymbol:function(){return"conference_id"}})(Dn)(mn)))(qe),fN=we(qr(Wt)),_N=mc(mN($({reflectSymbol:function(){return"id"}})(Dn)(mn)))(qe),jy=(function(){function e(){}return e.value=new e,e})(),vg=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),zy=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),fg=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),bS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ES=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),pN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),_g=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Mee=function(e){return function(n){return function(a){if(n.stage instanceof jy)return Aa;if(n.stage instanceof vg)return Ree(e)(n.stage.value0)(function(t){return a(fg.create(t))});if(n.stage instanceof zy)return vee(e)(n.stage.value0)(function(t){return a(bS.create(t))});throw new Error("Failed pattern match at Livestream.Live.VideoOverlay (line 103, column 3 - line 109, column 59): "+[n.stage.constructor.name])}}},G6e=function(e){return function(n){return e instanceof zy?_ee(e.value0)(n):!1}},M6e=function(){return function(e){return function(n){return function(a){return D6e(Wr(100))(function(){return R6e(bee(RE(pc)))(function(t){return y6e(t)(function(r){return bee(function(){var i=bL(_A(r))(),l=Ek({x:i.left+1,y:i.top+1})(),s=yL(_A(l))();return w6e(n)(Ef(Eee(a))(Ef(d0(e.conference))(Eee({livestream_popup_visible:b6e(s===pc)}))))()})})})})}}}},Aee=M6e(),A6e=function(e){var n=function(){return Aee(e)("Livestream: CTA Popup Shown")},a=n();return function(t){if(t instanceof ns)return a({livestream_cta_target_conference_id:E6e(t.value0.conferenceId)});if(t instanceof ts)return a({livestream_cta_id:wS(t.value0.id)});if(t instanceof as)return a({livestream_cta_id:wS(t.value0.id),livestream_cta_title:t.value0.title,livestream_cta_url:t.value0.url});if(t instanceof rs)return a({livestream_cta_id:wS(t.value0.id),livestream_cta_title:t.value0.title});throw new Error("Failed pattern match at Livestream.Live.VideoOverlay (line 163, column 29 - line 180, column 8): "+[t.constructor.name])}},Lee=function(e){return function(n){return function(a){if(a instanceof fg&&a.value0 instanceof sg)return _s({stage:jy.value,showPolls:a.value0.value0.keepShowingPolls});var t=function(r){if(a instanceof fg)return _s(n);if(a instanceof bS){if(a.value0 instanceof Jn)return _s({showPolls:n.showPolls,stage:jy.value});var u=function(s){return _s(n)};return a.value0 instanceof Ue&&n.stage instanceof zy?Iee(bS.create)(function(s){return{showPolls:n.showPolls,stage:new zy(s)}})(fee(e)(n.stage.value0)(a.value0.value0)):u(!0)}var u=function(l){if(a instanceof ES&&n.showPolls)return Tee(See(fg.create)(wee(a.value0)))(function(p){return U0(Bt(Aee(e)("Livestream: Poll Popup Shown")({livestream_poll_id:wS(a.value0.id)})))(function(){return _s({showPolls:n.showPolls,stage:new vg(p)})})});if(a instanceof ES)return _s(n);var s=function(p){if(a instanceof pN||a instanceof _g&&G6e(n.stage)(a.value0))return _s(n);if(a instanceof _g)return U0(Bt(A6e(e)(a.value0)))(function(){return Tee(See(bS.create)(pee(a.value0)))(function(R){return _s({showPolls:n.showPolls,stage:new zy(R)})})});throw new Error("Failed pattern match at Livestream.Live.VideoOverlay (line 111, column 1 - line 111, column 76): "+[a.constructor.name])};if(a instanceof pN){if(n.stage instanceof vg){var h=n.stage.value0.poll.id===a.value0.pollId;return h?_s({showPolls:n.showPolls,stage:jy.value}):s(!0)}return s(!0)}return s(!0)};if(a instanceof ES){if(n.stage instanceof vg){var i=n.stage.value0.poll.id===a.value0.id;return i?_s(n):u(!0)}return u(!0)}return u(!0)};return a instanceof fg&&n.stage instanceof vg?Iee(fg.create)(function(r){return{showPolls:n.showPolls,stage:new vg(r)}})(yee(e)(n.stage.value0)(a.value0)):t(!0)}}},Pee=function(e){var n=function(u){return u instanceof rs?O0(u.value0.id):G.value},a=function(u){return u instanceof ts?O0(u.value0.id):G.value},t=function(u){return u instanceof as?O0(u.value0.id):G.value},r=function(u){return u instanceof ns?O0(u.value0.conferenceId):G.value};return U0($y(function(u){return Wy(T6e(ES.create)(function(i){return i.poll}))(xy((function(){var i=I6e(u.poll_id);return function(l){return i((function(s){return s.poll.id})(l))}})())(e.conference.polls))})(Cee(e.pusher.dataChannel)("show-poll")))(function(){return U0(S6e(function(u){return new pN({pollId:u.poll_id})})(Cee(e.pusher.dataChannel)("hide-poll")))(function(){return U0($y(function(u){return Wy(_g.create)(xy((function(){var i=C6e(O0(u.conference_id));return function(l){return i(r(l))}})())(e.ctas))})(F6e(e.pusher.dataChannel)("show-event-cta")))(function(){return U0($y(function(u){return Wy(_g.create)(xy((function(){var i=fN(O0(u.id));return function(l){return i(t(l))}})())(e.ctas))})(_N(e.pusher.dataChannel)("show-general-cta")))(function(){return U0($y(function(u){return Wy(_g.create)(xy((function(){var i=fN(O0(u.id));return function(l){return i(a(l))}})())(e.ctas))})(_N(e.pusher.dataChannel)("show-featured-sps-cta")))(function(){return U0($y(function(u){return Wy(_g.create)(xy((function(){var i=fN(O0(u.id));return function(l){return i(n(l))}})())(e.ctas))})(_N(e.pusher.dataChannel)("show-referral-cta")))(function(){return _s({stage:jy.value,showPolls:!0})})})})})})})};var P6e=js(),dN=Pe(Se),N6e=jr(on),O6e=Ct(Se),U6e=Ht(ie),Nee=Ol(),Oee=jr(ie),k6e=xr(ie),IS=ga(ie)()(),B6e=fn(ln),Uee=B6e(ma),H6e=uK(),hN=x(Un),kee=ae(nn),J6e=h_(xO),q6e=Ml(NG),$6e=we(EE),W6e=pf(Je)(Ot),x6e=we(av),j6e=Ps()(),Bee=(function(){function e(){}return e.value=new e,e})(),DN=(function(){function e(){}return e.value=new e,e})(),Hee=(function(){function e(){}return e.value=new e,e})(),RN=(function(){function e(){}return e.value=new e,e})(),gN=(function(){function e(){}return e.value=new e,e})(),TS=function(e){return function(n){return P6e({id:"network-settings-modal",onDismiss:n(new Jn(gN.value)),bodyClass:"t--livestreams-update-network-settings-modal",body:(function(){if(e.modalView instanceof Bee)return dN("text-center")([Qa(e.confirmConferenceRegistration)(N6e("mb-4")(O6e("badge badge-soft-primary bg-primary-soft")([U6e("fe fe-check mr-1")(""),cn("You\u2019re registered!")]))),Nee("my-4")({alt:Nl.value,height:"76",src:"/img/network/counselor.svg",width:"91"}),Oee("")("Connect with colleges when you attend or register for their livestreams?"),k6e("text-secondary")("Connecting with colleges puts you on their radar and introduces you to admissions officers and current students"),dN("mx-md-6 mt-4")([IS("btn btn-primary w-100 t--livestream-opt-into-auto-connect")(vn)({onClick:un(function(a){return function(){return n(new Ue(Hee.value))(),n(new Ue(RN.value))()}})})("Yes, always connect"),IS("btn btn-outline-primary w-100 mt-3 t--livestream-connect-with-school")(vn)({onClick:un(function(a){return n(new Ue(RN.value))})})("Only connect with "+e.school.name),IS("btn btn-link mt-3")(vn)({onClick:un(function(a){return n(new Jn(gN.value))})})("Close")])]);if(e.modalView instanceof DN)return dN("text-center")([Nee("mt-4")({alt:Nl.value,height:"42",src:"/img/livestreams/network-settings-modal/connection-sent.png",width:"42"}),Oee("")("Connection request sent!"),IS("mt-4 btn btn-primary t--livestream-network-settings-modal-close")(vn)({onClick:un(function(a){return n(new Jn(gN.value))})})("Close")]);throw new Error("Failed pattern match at Livestream.NetworkSettingsModal (line 71, column 13 - line 122, column 14): "+[e.modalView.constructor.name])})()})}},SS=function(e){return function(n){if(n instanceof Ue){if(n.value0 instanceof Hee)return Uee(Bt(H6e({publishScope:_c.value,publishContext:V3.value,autoRequestFromLivestreams:!0,livestreamConference:e.conference})))(function(){return hN({conference:e.conference,confirmConferenceRegistration:e.confirmConferenceRegistration,school:e.school,modalView:DN.value})});if(n.value0 instanceof RN)return Uee(Bt(TW(e.school.id)(e.conference.id)))(function(){return hN({conference:e.conference,confirmConferenceRegistration:e.confirmConferenceRegistration,school:e.school,modalView:DN.value})});throw new Error("Failed pattern match at Livestream.NetworkSettingsModal (line 49, column 31 - line 61, column 44): "+[n.value0.constructor.name])}if(n instanceof Jn)return hN(e);throw new Error("Failed pattern match at Livestream.NetworkSettingsModal (line 48, column 1 - line 48, column 55): "+[e.constructor.name,n.constructor.name])}},CS=function(e){return function(n){var a=je(!1)(kee(e.dismissedNetworkSettingsModalAt)(function(r){return new T(J6e(q6e(yE(void 0))(r))(30))})),t=function(r){return[n.rcr834NetworkSettingsModal,$6e(r.publishScope)(_c.value),!r.autoRequestFromLivestreams,e.hasAccessToNetwork,!a]};return je(!1)(kee(e.profile)(function(r){return new T(W6e(x6e(!0))(t(r)))}))}},FS=function(e){return j6e(e)({modalView:Bee.value})};var Vy=(function(){function e(){}return e.value=new e,e})(),pg=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Qy=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),GS=(function(){function e(){}return e.value=new e,e})();var $ee=fn(ln),qee=$ee(ma),yN=nt(qe),V6e=$ee(Na),wN=x(ba),MS=x(Un),Wee=function(e){return function(n){return function(a){return function(t){return a.throttleState instanceof Vy&&t instanceof Qy?qee(yN(V6e(Wr(a.delay))(function(){return wN(e(GS.value))})))(function(){return MS(n({delay:a.delay,throttleState:new pg(t.value0)}))}):a.throttleState instanceof pg&&t instanceof Qy?MS(n({delay:a.delay,throttleState:new pg(t.value0)})):a.throttleState instanceof pg&&t instanceof GS?qee(yN(wN(a.throttleState.value0)))(function(){return MS(n({delay:a.delay,throttleState:Vy.value}))}):MS(n(a))}}}},xee=function(e){return function(n){return yN(wN(e(new Qy(n))))}},jee=function(e){return{throttleState:Vy.value,delay:e}};var AS=Pe(ie),LS=Pe(Se),K6e=jr(ie),o_=oe(pn),Y6e=ou(ho),zee=Pe(on),X6e=zr(ie)()(),Z6e=qu(ie),eUe=Ct(ie),nUe=Lf(on),aUe=F1(Se)()(),Vee=Bs(Ca),PS=ga(ie)()(),Zee=wi(Je)(Wt),Qee=Lf(Se),NS=Us(ie),tUe=Us(on),rUe=Us(Se),oUe=Y_(Se),uUe=V_(Se),mg=Q_(ie),iUe=K_(Se),OS=ge(Ye),lUe=ti(Ca),Ky=fn(ln)(ma),TN=nt(qe),cUe=Mr(Yo),ene=x(ba),k0=x(Un),bN=B(st),sUe=we(tB),Kee=si(Ca)(Je),vUe=tn(gr),fUe=oD(Ca),_Ue=C_(Wt),pUe=Gi(qe),mUe=sI(qe),US=(function(){function e(){}return e.value=new e,e})(),nne=(function(){function e(){}return e.value=new e,e})(),ane=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),tne=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),EN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Yee=(function(){function e(){}return e.value=new e,e})(),rne=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),one=(function(){function e(){}return e.value=new e,e})(),SN=(function(){function e(){}return e.value=new e,e})(),Xee=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),IN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),une=function(e){return function(n){return function(a){if(e.conference.polls.length===0)return Aa;var t=(function(){if(n.stage instanceof US)return Aa;if(n.stage instanceof nne)return AS("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 187, column 22 - line 193, column 23): "+[n.stage.constructor.name])})(),r=LS("d-flex flex-nowrap align-items-baseline")([K6e("")("Polls"),AS("text-muted ml-3 small")("Polls will be shown to viewers "+(o_(e.videoLagSeconds)+" seconds after you launch them, to account for the audio/video delay"))]),u=function(s){return function(h){return function(p){var R=function(E){return function(w){var I=(function(){if(h===0)return"0%";if(Ve)return o_(Y6e(100*w|0)(h))+"%";throw new Error("Failed pattern match at Livestream.Polls.LaunchPolls (line 183, column 7 - line 185, column 63): ")})();return LS("row align-items-center bg-light-grey mb-1 py-2 t--poll-response-option")([AS("col-7 d-flex justify-content-end")(E),zee("col-4")(zee("progress")(X6e("progress-bar")({style:Yt({width:I})})(""))),LS("col-1")([Z6e("")(o_(w)),eUe("text-secondary text-nowrap")(" ("+(I+")"))])])}};return nUe("t--poll-responses-"+o_(s.id))(aUe("py-0")({colSpan:6})(Cb(R)(s.options)(p.optionCounts)))}}},i=function(s){var h=je(s.status)(Vee(s.poll.id)(n.statuses)),p=PS("btn btn-white btn-sm px-4 t--open")(vn)({onClick:un(function(R){return a(new ane(s.poll))})})("Launch poll");if(h instanceof qf)return p;if(h instanceof Nv)return Oe([PS("btn btn-success btn-sm px-4 mr-3")(vn)({disabled:!0})("Poll LIVE"),PS("btn btn-danger btn-sm px-4 t--close")(vn)({onClick:un(function(R){return a(new tne(s.poll))})})("Close poll")]);if(h instanceof $f)return p;throw new Error("Failed pattern match at Livestream.Polls.LaunchPolls (line 141, column 15 - line 154, column 19): "+[h.constructor.name])},l=function(s){var h=Zee(s.poll.id)(n.expandedResponses),p=Vee(s.poll.id)(n.responses),R=Wn(0)(function(I){return I.answered})(p),E=Wn(0)(function(I){return I.seen})(p),w=Wn(0)(function(I){return I.skipped})(p);return Oe([Qee("t--poll t--poll-"+o_(s.poll.id))([NS("pt-3")((function(){var I=Fr(s.poll.autoDisplayMinutesFromStart);return I?"\u23F0 ":""})()+s.poll.question),tUe("text-nowrap")(i(s)),NS("t--shown")(o_(E)),rUe("t--answers")([cn(o_(R)),PS("btn btn-sm btn-white ml-2 py-0 px-1 "+("fe fe-chevron-"+(function(){return h?"up":"down t--expand-responses"})()))(Vr((function(){return h?"Collapse responses":"Expand responses"})()))({onClick:un(function(I){return a(new rne(s.poll.id))})})("")]),NS("t--skipped")(o_(w)),NS("t--pending")(o_((E-R|0)-w|0))]),Qa(h)(ja(p)(u(s.poll)(R)))])};return Oe([r,LS("t--polls position-relative")([ja(n.error)(function(s){return AS("alert alert-danger")(s)}),oUe("table table-sm mb-0")([uUe("")([Qee("")([mg("")("Question"),mg("")("Actions"),mg("")("# saw poll"),mg("")("# answered"),mg("")("# skipped"),mg("")("# not responded")])]),iUe("")(OS(lUe(function(s){return-(function(h){return h.poll.id})(s)|0})(e.conference.polls))(l))]),t])])}}},ine=function(e){return function(n){var a=function(t){return Ky(TN(cUe(t)(function(r){return ene(Yee.value)})))(function(){return k0({expandedResponses:n.expandedResponses,responseThrottle:n.responseThrottle,responses:n.responses,statuses:n.statuses,stage:nne.value,error:G.value})})};return function(t){if(t instanceof ane)return a(bN(EN.create)(M2(t.value0)(Nv.value)));if(t instanceof tne)return a(bN(EN.create)(M2(t.value0)($f.value)));if(t instanceof EN){var r=OS(yu((function(){var u=sUe(Nv.value);return function(i){return u((function(l){return l.status})(i))}})())(t.value0))(function(u){return u.pollId});return k0({error:n.error,responseThrottle:n.responseThrottle,responses:n.responses,statuses:Kee(OS(t.value0)(function(u){return new yn(u.pollId,u.status)})),expandedResponses:vUe(n.expandedResponses)(fUe(r)),stage:US.value})}if(t instanceof Yee)return k0({expandedResponses:n.expandedResponses,responseThrottle:n.responseThrottle,responses:n.responses,statuses:n.statuses,stage:US.value,error:new T("That didn't work for some reason, try again")});if(t instanceof rne)return k0({error:n.error,responseThrottle:n.responseThrottle,responses:n.responses,stage:n.stage,statuses:n.statuses,expandedResponses:(function(){var u=Zee(t.value0)(n.expandedResponses);return u?_Ue(t.value0)(n.expandedResponses):wu(t.value0)(n.expandedResponses)})()});if(t instanceof one)return Ky(xee(IN.create)(SN.value))(function(){return k0(n)});if(t instanceof SN)return Ky(TN(bN(Xee.create)(Cq(e.conference.id))))(function(){return k0(n)});if(t instanceof Xee)return k0({error:n.error,expandedResponses:n.expandedResponses,responseThrottle:n.responseThrottle,stage:n.stage,statuses:n.statuses,responses:Kee(OS(t.value0)(function(u){return new yn(u.pollId,u.responses)}))});if(t instanceof IN)return Wee(IN.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 205, column 22 - line 251, column 98): "+[t.constructor.name])}}},lne=function(e){return Ky(pUe(gn(one.value))(mUe(e.pusher.dataChannel)("poll-responses-changed")))(function(){return Ky(TN(ene(SN.value)))(function(){return k0({statuses:ic,responses:ic,expandedResponses:[],responseThrottle:jee(500),stage:US.value,error:G.value})})})};var cne=Ol(),sne=Pe(Se),vne=jr(ie),fne=vu(ie),_ne=(function(){return cne("img-fluid mb-6")({alt:new LR("CollegeVine"),src:"/img/cv-logo-lilac-on-dark.svg",style:Yt({width:"5em"})})})(),kS=function(e){return sne(e+` t--splashscreen position-absolute-fullsize d-flex flex-column align-items-center justify-content-around bg-dark text-white `)},Yy=function(e){return kS("")([vne("text-center")(e)])},CN=kS("t--splashscreen-intro")([Pe(on)("text-center mt-7")(fne("")("The recording will load in a moment.")),_ne]),BS=(function(){return kS("px-4 px-md-6 t--splashscreen-intro")([cne("img-fluid")({alt:Nl.value,src:"/img/illustrations/livestreams/2022-02-intro.svg"})])})(),pne=kS("t--splashscreen-complete")([sne("text-center mt-7")([fne("")("The event is now over."),vne("")("Thank you for attending!"),zc(ie)("")("A recording will be available to watch shortly.")]),_ne]);var HS=e=>e.play();var B0=pl(dne(),1);Et();var hne=e=>{let[n,a]=vt.useState(),[t,r]=vt.useState(),u=vt.useRef();return u.current=e,Lr(()=>{if(!t)return B0.default.isSupported()?a(gUe(e.videoStreamUrl,e.videoElementId,u)):e.onNotSupported(),r(!0),()=>{n&&n.destroy()}}),null},gUe=(e,n,a)=>{let t=document.getElementById(n);return t?(hls=new B0.default,a.current.onInstanceCreated&&a.current.onInstanceCreated(hls),hls.on(B0.default.Events.ERROR,function(r,u){a.current.onError&&a.current.onError("HLS error: "+u.type,u),u.fatal&&(u.type===B0.default.ErrorTypes.MEDIA_ERROR?hls.recoverMediaError():(hls.destroy(),a.current.onCriticalFail&&a.current.onCriticalFail(u.type)))}),hls.on(B0.default.Events.MEDIA_ATTACHED,()=>hls.loadSource(e)),hls.on(B0.default.Events.MANIFEST_PARSED,()=>a.current.onReady&&a.current.onReady()),hls.on(B0.default.Events.INIT_PTS_FOUND,(r,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 RUe=wv();var gne=function(){return function(){return RUe(hne)}};Et();var nw=pl(Ine(),1),Tne=4,XUe=({trackColor:e,background:n})=>({props:a,children:t})=>vt.createElement("div",Object.assign({},a,{style:Object.assign({},a.style,{height:`${Tne}px`,borderRadius:`${Tne*2}px`,background:n||e})}),...t),ZUe=({horizontal:e})=>({props:n,isDragged:a})=>vt.createElement("svg",Object.assign({},n,{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",fill:"none",viewBox:"0 0 18 18"}),vt.createElement("circle",{cx:"9",cy:"9",r:"8.5",fill:a?nu.SECONDARY:nu.WHITE,stroke:nu.SECONDARY}),vt.createElement("path",{stroke:a?nu.WHITE:nu.SECONDARY,d:e?"M7.5 6L7.5 12":"M6 7.5L12 7.5"}),vt.createElement("path",{stroke:a?nu.WHITE:nu.SECONDARY,d:e?"M10.5 6L10.5 12":"M6 10.5L12 10.5"})),Sne=e=>vt.createElement("div",{"aria-label":e.ariaLabel},vt.createElement(nw.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:XUe({trackColor:e.trackColor||nu.GRAY_300,background:e.fillBefore?(0,nw.getTrackBackground)({values:[e.value],colors:[nu.PRIMARY,nu.GRAY_300],min:e.min,max:e.max,"aria-valuemax":e.max,"aria-valuemin":e.min,"aria-valuenow":e.value}):void 0}),renderThumb:ZUe({horizontal:!0})}));var n5e=wv(),Cne={CanPassToJavaScript0:function(){},CanReceiveFromJavaScript1:function(){return Gd}};var Fne=function(e){return function(){return function(){return n5e(Sne)}}};var t5e=zr(on)()(),r5e=Fne(Cne)()(),o5e=Pl(Dh),u5e=ga(on)()(),i5e=Pl(Hv),Gne=Pe(Se),l5e=Ct(ie),WS=nt(qe),LN=x(ba),One=fn(ln),c5e=Ut(kd),Qv=x(Un),s5e=z_(qe),AN=Hn(qe),v5e=B(ue),f5e=Rv(Nd),_5e=One(Na),H0=One(ma),p5e=Sr(Un),m5e=ae(Na),d5e=ov(Gl),h5e=Sr(Nt),PN=(function(){function e(){}return e.value=new e,e})(),NN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),UN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Mne=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),ON=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Ane=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Lne=(function(){function e(){}return e.value=new e,e})(),g5e=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),Une=function(e){return function(n){if(e.videoState instanceof G)return Aa;if(e.videoState instanceof T){var a=t5e("")({style:Yt({minWidth:"6rem",width:"6rem"})})(r5e({value:(function(){return e.videoState.value0.muted?0:e.videoState.value0.volume})(),min:0,max:1,step:.05,onChange:o5e(n)(function(i){return Ue.create(NN.create(i))}),ariaLabel:"Volume slider"})),t=(function(){if(e.videoState.value0.muted)return"fe-volume-x";if(Ve)return"fe-volume-2";throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 122, column 3 - line 124, column 32): ")})(),r=u5e("btn large px-3 py-1 mr-3 text-white fe "+t)(Vr("Mute the video"))({onClick:i5e(n)(new Ue(PN.value))})(Aa),u=Gne("d-flex align-items-center text-white px-3")([cn("LIVE"),l5e("text-danger x-large ml-2 mt-n1")("\u25CF")]);return Gne("mb-2 w-100 d-flex align-items-center bg-semi-transparent-black "+(function(){return e.visible?"":"hidden"})())([Qa(e.config.liveIndicator)(u),Qa(e.config.mute)(r),Qa(e.config.volume)(a)])}throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 95, column 1 - line 95, column 50): "+[e.constructor.name,n.constructor.name])}},kne=function(e){return Ue.create(UN.create(e))},Pne=function(e){return WS(LN(new Jn(new g5e(function(n){return function(){return e(n)(),new Ue(new UN(n))}}))))},xS=(function(){return new Ue(new ON(!0))})(),Bne=function(e){return{config:e,videoState:G.value,visible:!1,visibilityExpiration:c5e}},Nne=2e3,Hne=function(e){return function(n){if(n instanceof Jn)return Qv(e);if(n instanceof Ue){var a=s5e(AN(function(){var i=Hl();return v5e(function(l){return Ue.create(Ane.create(l))})(f5e(Nne)(i))})),t=_5e(Wr(Nne))(function(){return LN(new Ue(Lne.value))}),r=function(u){if(n.value0 instanceof PN)return Qv(e);var i=function(l){if(n.value0 instanceof NN)return Qv(e);if(n.value0 instanceof UN)return H0(WS(AN(function(){var h=gA(n.value0.value0)(),p=dA(n.value0.value0)();return new Ue(new Mne({muted:h,volume:p}))})))(function(){return Qv(e)});if(n.value0 instanceof Mne)return Qv({config:e.config,visibilityExpiration:e.visibilityExpiration,visible:e.visible,videoState:new T(n.value0.value0)});if(n.value0 instanceof ON)return H0(p5e(n.value0.value0)(a))(function(){return H0(WS(t))(function(){return Qv({config:e.config,videoState:e.videoState,visibilityExpiration:e.visibilityExpiration,visible:n.value0.value0})})});if(n.value0 instanceof Ane)return Qv({config:e.config,videoState:e.videoState,visible:e.visible,visibilityExpiration:n.value0.value0});if(n.value0 instanceof Lne)return H0(WS(m5e(AN(Hl))(function(s){var h=d5e(s)(e.visibilityExpiration);return h?LN(new Ue(new ON(!1))):t})))(function(){return Qv(e)});throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 138, column 1 - line 138, column 55): "+[n.value0.constructor.name])};return n.value0 instanceof NN&&e.videoState instanceof T?H0(a)(function(){return H0(Pne(function(l){return function(){return h5e(n.value0.value0>0)(Yp(!1)(l))(),hA(n.value0.value0)(l)()}}))(function(){return Qv({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 PN&&e.videoState instanceof T?H0(a)(function(){return H0(Pne(Yp(!e.videoState.value0.muted)))(function(){return Qv({config:e.config,visibilityExpiration:e.visibilityExpiration,visible:e.visible,videoState:new T({volume:e.videoState.value0.volume,muted:!e.videoState.value0.muted})})})}):r(!0)}throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 138, column 1 - line 138, column 55): "+[e.constructor.name,n.constructor.name])}},Jne=function(e){if(e instanceof T)return!1;if(e instanceof G)return!0;throw new Error("Failed pattern match at Livestream.VideoPlayer.CustomControls (line 206, column 1 - line 206, column 37): "+[e.constructor.name])};var qne=e=>n=>a=>()=>e.then(a,n),$ne=e=>e instanceof Error,Wne=e=>e===null?"null":typeof e>"u"?"undefined":e.toString();var y5e=x(Xl(Nr)),w5e=wp(Nr),b5e=hn(En),xne=La(fD(mD)(Nr)),E5e=yf(Nr),I5e=B(Id(ws)),T5e=Fd(Nr),S5e=eb(ca),C5e=Ft(F6);var F5e=function(e){var n=function(a){if($ne(a))return y5e(a);if(Ve)return w5e(new yp(""));throw new Error("Failed pattern match at Utils.Promise (line 58, column 3 - line 60, column 41): "+[a.constructor.name])};return yr(function(a){return zi("Promise failed: "+Wne(e))})(b5e)(am(xne(n(e))(xne(E5e("Error")(e))(I5e(zi)(T5e(e))))))},jS=function(e){return H_(function(n){return S5e(C5e)(qne(e)(function(a){return n(Me.create(F5e(a)))()})(function(a){return n(Le.create(a))()}))})};var M5e=ae(nn),A5e=Pe(on),aw=ae(uo),kN=$i(Nt)(iu),Um=Pl(Hv),jne=jd(ie)()(),L5e=gne()(),P5e=x(Nt),zne=Pl(Dh),Vne=zr(on)()(),N5e=ga(Se)()(),O5e=Ht(ie),U5e=Pe(Se),eae=fn(ln),k5e=Vf(qe)(),B5e=Wi(Je)(Ot),H5e=we(qr(Wt)),dg=eae(Na),J5e=Ys(ba),q5e=wo($d),Lu=x(ba),nae=Hn(qe),Qne=Mr(Yo),aae=Og(Na),_u=x(Un),Au=eae(ma),sl=nt(qe),Kne=B(st),Yne=z_(qe),tae=B(ca),$5e=$t(Lo(st)),W5e=B(ue),x5e=ge(ue),Xne=tn($O),rae=(function(){function e(){}return e.value=new e,e})(),oae=(function(){function e(){}return e.value=new e,e})(),rw=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),uae=(function(){function e(){}return e.value=new e,e})(),hg=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),iae=(function(){function e(){}return e.value=new e,e})(),lae=(function(){function e(){}return e.value=new e,e})(),Zne=(function(){function e(){}return e.value=new e,e})(),BN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),HN=(function(){function e(){}return e.value=new e,e})(),VS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),QS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),zS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),cae=(function(){function e(){}return e.value=new e,e})(),JN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),qN=(function(){function e(){}return e.value=new e,e})(),sae=(function(){function e(){}return e.value=new e,e})(),vae=(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})(),Kv=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),KS=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),xN=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),tw=(function(){function e(n){this.value0=n}return e.create=function(n){return new e(n)},e})(),jN=function(e){var n=e.Monad0(),a=ae(n.Bind1()),t=Hn(e),r=x(n.Applicative0());return function(u){return function(i){return function(l){return a(t(RE(u.videoId)))(function(s){return Wn(r(i.whenNotFound))(l)(M5e(s)(dk))})}}}},fae=jN(Go),$N=jN(qe),_ae=function(e){var n=jN(e);return function(a){return n(a)({whenNotFound:void 0})}},j5e=_ae(Go),z5e=_ae(qe),YS=function(e){return function(n){return function(a){var t=(function(){var I=A5e("position-absolute-fullsize py-6 d-flex align-items-center justify-content-around");if(n.stage instanceof uae)return I(e.errorScreen("It appears that video playback is not supported in your browser."));if(n.stage instanceof iae)return I(e.errorScreen("The video didn't load correctly, try refreshing the page."));if(n.stage instanceof rw)return I(e.introScreen);if(n.stage instanceof hg)return Aa;throw new Error("Failed pattern match at Livestream.VideoPlayer (line 246, column 18 - line 258, column 14): "+[n.stage.constructor.name])})(),r=(function(){return n.stage instanceof rw?n.stage.value0.reset:!1})(),u=un(function(I){return aw(DE(I))(kN(function(L){return a(new Ue(new xN({time:L})))}))}),i=un(function(I){return aw(DE(I))(kN(function(L){return a(new Ue(new KS({playing:!0,time:L})))}))}),l=function(I){return a(Jn.create(I))},s=un(function(I){return aw(DE(I))(kN(function(L){return l(new JN(L))}))}),h=Um(l)(cae.value),p=Oe([jne("w-100 t--real-video")({id:n.videoId,controls:Rr(n.customControls),onVolumeChange:h,onTimeUpdate:u,onPlay:i,onPause:s})(""),Qa(!r)(L5e({videoStreamUrl:e.watchUrl,videoElementId:n.videoId,onNotSupported:l(lae.value),onError:function(I,L){return void 0},onCriticalFail:zne(l)(function(I){var L=I==="networkError";return L?HN.value:new VS("HLS player crashed")}),onReady:l(new QS({autoPlay:e.autoPlay})),onInitialPts:zne(l)(function(I){return new vae(I.initPTS)})}))]),R=(function(){return n.stage instanceof hg&&n.stage.value0.unmuteOverlay?Vne("position-absolute-fullsize d-flex align-items-center justify-content-center t--unmute-overlay")({style:Yt({pointerEvents:"none"})})(N5e("btn btn-sm btn-light border-dark px-4 d-flex align-items-center")(vn)({onClick:Um(l)(sae.value),style:Yt({pointerEvents:"all"})})([cn("click for sound"),O5e("fe fe-volume-2 ml-2")("")])):Aa})(),E=function(I){return Vne("position-absolute-fullsize d-flex align-items-end t--controls-overlay")({onMouseMove:Um(l)(new Kv(xS)),onMouseDown:Um(l)(new Kv(xS)),onTouchStart:Um(l)(new Kv(xS))})(Une(I)(function(L){return l(Kv.create(L))}))},w=jne("w-100 t--real-video")({id:n.videoId,controls:Rr(n.customControls),playsInline:!0,onVolumeChange:h,onTimeUpdate:u,onPlay:i,onPause:s,onLoadedMetadata:Um(l)(new QS({autoPlay:e.autoPlay})),onError:Um(l)(HN.value),src:(function(){return r?"":e.watchUrl})()})("");return U5e("position-relative w-100")([(function(){if(n.support instanceof rae)return p;if(n.support instanceof oae)return w;throw new Error("Failed pattern match at Livestream.VideoPlayer (line 165, column 7 - line 167, column 40): "+[n.support.constructor.name])})(),ja(n.customControls)(E),Qa(n.allowSound)(R),t])}}},V5e=function(e){var n=Hn(e.MonadEffect0());return function(a){return n(function(){return j5e(a)(Yp(!1))(),qN.value})}},Q5e=V5e(Mk),WN=function(e){return k5e("Livestream: Error")({livestream_error_message:e})},pae=function(e){return fae(e)({whenNotFound:!1})(mA)},K5e=function(e){return Hn(e)(function(){var a=aw(aw(Mi)(bA))(wA)();return B5e(function(t){return H5e(H1(t)(a))(new T(0))})(["iPad","iPod","iPhone"])})},mae=K5e(qe),Y5e=function(e){var n=function(t){return dg(J5e(e.allowSound)(q5e(zi("Skipping attempt to play unmuted because sound was programmatically disallowed"))))(function(){return dg(jS(HS(t)))(function(){return Lu(new zS({unmuteOverlay:!1}))})})},a=function(t){return dg(nae(Yp(!0)(t)))(function(){return dg(jS(HS(t)))(function(){return Lu(new zS({unmuteOverlay:!0}))})})};return $N(e)({whenNotFound:new VS("