var Pv=Object.defineProperty;var Iv=(n,i,r)=>i in n?Pv(n,i,{enumerable:!0,configurable:!0,writable:!0,value:r}):n[i]=r;var Fu=(n,i,r)=>Iv(n,typeof i!="symbol"?i+"":i,r);import{j as s,L as gc,M as Ig,N as Ot,u as An,J as e1,X as t1,C as n1,R as xc,a as yc,b as a1,c as i1,d as Ce,B as l1,e as s1}from"./@react-libs-Be4_VkjC.js";import{P as ex,g as r1,d as A,r as S,R as J,Q as c1,l as o1,_ as ye,T as ni,U as tx,V as u1,W as d1,X as f1,Y as h1,Z as m1,$ as p1,a0 as g1,a1 as x1,a2 as y1,a3 as v1,a4 as b1,a5 as j1,a6 as S1,a7 as od,a8 as nx,a9 as w1,aa as _1,O as T1}from"./@app-libs-BSBCEBGY.js";import{F as fe,f as As,a as A1,b as C1,c as E1,d as O1,e as D1,g as _d,h as M1,i as ax,j as z1,k as ix,l as lx,m as R1,n as k1,o as sx,p as B1,q as N1,r as rx,s as U1,t as L1,u as vc,v as H1,w as q1,x as $1,y as G1,z as V1,A as cx,B as ox,C as ux}from"./@fontawesome-libs-ClsHSSio.js";import{u as $,w as Y1,i as X1,B as Q1,a as Z1,b as K1}from"./@lang-libs-xI_kOUGH.js";(function(){const i=document.createElement("link").relList;if(i&&i.supports&&i.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))c(u);new MutationObserver(u=>{for(const f of u)if(f.type==="childList")for(const h of f.addedNodes)h.tagName==="LINK"&&h.rel==="modulepreload"&&c(h)}).observe(document,{childList:!0,subtree:!0});function r(u){const f={};return u.integrity&&(f.integrity=u.integrity),u.referrerPolicy&&(f.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?f.credentials="include":u.crossOrigin==="anonymous"?f.credentials="omit":f.credentials="same-origin",f}function c(u){if(u.ep)return;u.ep=!0;const f=r(u);fetch(u.href,f)}})();var Ju={exports:{}},Il={},Wu={exports:{}},Pu={};/**
 * @license React
 * scheduler.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var Kp;function F1(){return Kp||(Kp=1,function(n){function i(U,Y){var te=U.length;U.push(Y);e:for(;0<te;){var Ee=te-1>>>1,Oe=U[Ee];if(0<u(Oe,Y))U[Ee]=Y,U[te]=Oe,te=Ee;else break e}}function r(U){return U.length===0?null:U[0]}function c(U){if(U.length===0)return null;var Y=U[0],te=U.pop();if(te!==Y){U[0]=te;e:for(var Ee=0,Oe=U.length,vt=Oe>>>1;Ee<vt;){var Re=2*(Ee+1)-1,je=U[Re],at=Re+1,fn=U[at];if(0>u(je,te))at<Oe&&0>u(fn,je)?(U[Ee]=fn,U[at]=te,Ee=at):(U[Ee]=je,U[Re]=te,Ee=Re);else if(at<Oe&&0>u(fn,te))U[Ee]=fn,U[at]=te,Ee=at;else break e}}return Y}function u(U,Y){var te=U.sortIndex-Y.sortIndex;return te!==0?te:U.id-Y.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var f=performance;n.unstable_now=function(){return f.now()}}else{var h=Date,m=h.now();n.unstable_now=function(){return h.now()-m}}var x=[],g=[],v=1,w=null,j=3,E=!1,R=!1,B=!1,z=!1,H=typeof setTimeout=="function"?setTimeout:null,q=typeof clearTimeout=="function"?clearTimeout:null,V=typeof setImmediate<"u"?setImmediate:null;function X(U){for(var Y=r(g);Y!==null;){if(Y.callback===null)c(g);else if(Y.startTime<=U)c(g),Y.sortIndex=Y.expirationTime,i(x,Y);else break;Y=r(g)}}function Z(U){if(B=!1,X(U),!R)if(r(x)!==null)R=!0,ee||(ee=!0,Je());else{var Y=r(g);Y!==null&&Cn(Z,Y.startTime-U)}}var ee=!1,de=-1,tt=5,oe=-1;function Mt(){return z?!0:!(n.unstable_now()-oe<tt)}function nt(){if(z=!1,ee){var U=n.unstable_now();oe=U;var Y=!0;try{e:{R=!1,B&&(B=!1,q(de),de=-1),E=!0;var te=j;try{t:{for(X(U),w=r(x);w!==null&&!(w.expirationTime>U&&Mt());){var Ee=w.callback;if(typeof Ee=="function"){w.callback=null,j=w.priorityLevel;var Oe=Ee(w.expirationTime<=U);if(U=n.unstable_now(),typeof Oe=="function"){w.callback=Oe,X(U),Y=!0;break t}w===r(x)&&c(x),X(U)}else c(x);w=r(x)}if(w!==null)Y=!0;else{var vt=r(g);vt!==null&&Cn(Z,vt.startTime-U),Y=!1}}break e}finally{w=null,j=te,E=!1}Y=void 0}}finally{Y?Je():ee=!1}}}var Je;if(typeof V=="function")Je=function(){V(nt)};else if(typeof MessageChannel<"u"){var nn=new MessageChannel,Ma=nn.port2;nn.port1.onmessage=nt,Je=function(){Ma.postMessage(null)}}else Je=function(){H(nt,0)};function Cn(U,Y){de=H(function(){U(n.unstable_now())},Y)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(U){U.callback=null},n.unstable_forceFrameRate=function(U){0>U||125<U?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):tt=0<U?Math.floor(1e3/U):5},n.unstable_getCurrentPriorityLevel=function(){return j},n.unstable_next=function(U){switch(j){case 1:case 2:case 3:var Y=3;break;default:Y=j}var te=j;j=Y;try{return U()}finally{j=te}},n.unstable_requestPaint=function(){z=!0},n.unstable_runWithPriority=function(U,Y){switch(U){case 1:case 2:case 3:case 4:case 5:break;default:U=3}var te=j;j=U;try{return Y()}finally{j=te}},n.unstable_scheduleCallback=function(U,Y,te){var Ee=n.unstable_now();switch(typeof te=="object"&&te!==null?(te=te.delay,te=typeof te=="number"&&0<te?Ee+te:Ee):te=Ee,U){case 1:var Oe=-1;break;case 2:Oe=250;break;case 5:Oe=1073741823;break;case 4:Oe=1e4;break;default:Oe=5e3}return Oe=te+Oe,U={id:v++,callback:Y,priorityLevel:U,startTime:te,expirationTime:Oe,sortIndex:-1},te>Ee?(U.sortIndex=te,i(g,U),r(x)===null&&U===r(g)&&(B?(q(de),de=-1):B=!0,Cn(Z,te-Ee))):(U.sortIndex=Oe,i(x,U),R||E||(R=!0,ee||(ee=!0,Je()))),U},n.unstable_shouldYield=Mt,n.unstable_wrapCallback=function(U){var Y=j;return function(){var te=j;j=Y;try{return U.apply(this,arguments)}finally{j=te}}}}(Pu)),Pu}var Fp;function J1(){return Fp||(Fp=1,Wu.exports=F1()),Wu.exports}var Iu={exports:{}},gt={};/**
 * @license React
 * react-dom.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var Jp;function W1(){if(Jp)return gt;Jp=1;var n=ex();function i(x){var g="https://react.dev/errors/"+x;if(1<arguments.length){g+="?args[]="+encodeURIComponent(arguments[1]);for(var v=2;v<arguments.length;v++)g+="&args[]="+encodeURIComponent(arguments[v])}return"Minified React error #"+x+"; visit "+g+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function r(){}var c={d:{f:r,r:function(){throw Error(i(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},u=Symbol.for("react.portal");function f(x,g,v){var w=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:u,key:w==null?null:""+w,children:x,containerInfo:g,implementation:v}}var h=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function m(x,g){if(x==="font")return"";if(typeof g=="string")return g==="use-credentials"?g:""}return gt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=c,gt.createPortal=function(x,g){var v=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!g||g.nodeType!==1&&g.nodeType!==9&&g.nodeType!==11)throw Error(i(299));return f(x,g,null,v)},gt.flushSync=function(x){var g=h.T,v=c.p;try{if(h.T=null,c.p=2,x)return x()}finally{h.T=g,c.p=v,c.d.f()}},gt.preconnect=function(x,g){typeof x=="string"&&(g?(g=g.crossOrigin,g=typeof g=="string"?g==="use-credentials"?g:"":void 0):g=null,c.d.C(x,g))},gt.prefetchDNS=function(x){typeof x=="string"&&c.d.D(x)},gt.preinit=function(x,g){if(typeof x=="string"&&g&&typeof g.as=="string"){var v=g.as,w=m(v,g.crossOrigin),j=typeof g.integrity=="string"?g.integrity:void 0,E=typeof g.fetchPriority=="string"?g.fetchPriority:void 0;v==="style"?c.d.S(x,typeof g.precedence=="string"?g.precedence:void 0,{crossOrigin:w,integrity:j,fetchPriority:E}):v==="script"&&c.d.X(x,{crossOrigin:w,integrity:j,fetchPriority:E,nonce:typeof g.nonce=="string"?g.nonce:void 0})}},gt.preinitModule=function(x,g){if(typeof x=="string")if(typeof g=="object"&&g!==null){if(g.as==null||g.as==="script"){var v=m(g.as,g.crossOrigin);c.d.M(x,{crossOrigin:v,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0})}}else g==null&&c.d.M(x)},gt.preload=function(x,g){if(typeof x=="string"&&typeof g=="object"&&g!==null&&typeof g.as=="string"){var v=g.as,w=m(v,g.crossOrigin);c.d.L(x,v,{crossOrigin:w,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0,type:typeof g.type=="string"?g.type:void 0,fetchPriority:typeof g.fetchPriority=="string"?g.fetchPriority:void 0,referrerPolicy:typeof g.referrerPolicy=="string"?g.referrerPolicy:void 0,imageSrcSet:typeof g.imageSrcSet=="string"?g.imageSrcSet:void 0,imageSizes:typeof g.imageSizes=="string"?g.imageSizes:void 0,media:typeof g.media=="string"?g.media:void 0})}},gt.preloadModule=function(x,g){if(typeof x=="string")if(g){var v=m(g.as,g.crossOrigin);c.d.m(x,{as:typeof g.as=="string"&&g.as!=="script"?g.as:void 0,crossOrigin:v,integrity:typeof g.integrity=="string"?g.integrity:void 0})}else c.d.m(x)},gt.requestFormReset=function(x){c.d.r(x)},gt.unstable_batchedUpdates=function(x,g){return x(g)},gt.useFormState=function(x,g,v){return h.H.useFormState(x,g,v)},gt.useFormStatus=function(){return h.H.useHostTransitionStatus()},gt.version="19.1.0",gt}var Wp;function dx(){if(Wp)return Iu.exports;Wp=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(i){console.error(i)}}return n(),Iu.exports=W1(),Iu.exports}/**
 * @license React
 * react-dom-client.production.js
 *
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var Pp;function P1(){if(Pp)return Il;Pp=1;var n=J1(),i=ex(),r=dx();function c(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)t+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function u(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function f(e){var t=e,a=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(a=t.return),e=t.return;while(e)}return t.tag===3?a:null}function h(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function m(e){if(f(e)!==e)throw Error(c(188))}function x(e){var t=e.alternate;if(!t){if(t=f(e),t===null)throw Error(c(188));return t!==e?null:e}for(var a=e,l=t;;){var o=a.return;if(o===null)break;var d=o.alternate;if(d===null){if(l=o.return,l!==null){a=l;continue}break}if(o.child===d.child){for(d=o.child;d;){if(d===a)return m(o),e;if(d===l)return m(o),t;d=d.sibling}throw Error(c(188))}if(a.return!==l.return)a=o,l=d;else{for(var p=!1,y=o.child;y;){if(y===a){p=!0,a=o,l=d;break}if(y===l){p=!0,l=o,a=d;break}y=y.sibling}if(!p){for(y=d.child;y;){if(y===a){p=!0,a=d,l=o;break}if(y===l){p=!0,l=d,a=o;break}y=y.sibling}if(!p)throw Error(c(189))}}if(a.alternate!==l)throw Error(c(190))}if(a.tag!==3)throw Error(c(188));return a.stateNode.current===a?e:t}function g(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=g(e),t!==null)return t;e=e.sibling}return null}var v=Object.assign,w=Symbol.for("react.element"),j=Symbol.for("react.transitional.element"),E=Symbol.for("react.portal"),R=Symbol.for("react.fragment"),B=Symbol.for("react.strict_mode"),z=Symbol.for("react.profiler"),H=Symbol.for("react.provider"),q=Symbol.for("react.consumer"),V=Symbol.for("react.context"),X=Symbol.for("react.forward_ref"),Z=Symbol.for("react.suspense"),ee=Symbol.for("react.suspense_list"),de=Symbol.for("react.memo"),tt=Symbol.for("react.lazy"),oe=Symbol.for("react.activity"),Mt=Symbol.for("react.memo_cache_sentinel"),nt=Symbol.iterator;function Je(e){return e===null||typeof e!="object"?null:(e=nt&&e[nt]||e["@@iterator"],typeof e=="function"?e:null)}var nn=Symbol.for("react.client.reference");function Ma(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===nn?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case R:return"Fragment";case z:return"Profiler";case B:return"StrictMode";case Z:return"Suspense";case ee:return"SuspenseList";case oe:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case E:return"Portal";case V:return(e.displayName||"Context")+".Provider";case q:return(e._context.displayName||"Context")+".Consumer";case X:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case de:return t=e.displayName||null,t!==null?t:Ma(e.type)||"Memo";case tt:t=e._payload,e=e._init;try{return Ma(e(t))}catch{}}return null}var Cn=Array.isArray,U=i.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Y=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,te={pending:!1,data:null,method:null,action:null},Ee=[],Oe=-1;function vt(e){return{current:e}}function Re(e){0>Oe||(e.current=Ee[Oe],Ee[Oe]=null,Oe--)}function je(e,t){Oe++,Ee[Oe]=e.current,e.current=t}var at=vt(null),fn=vt(null),Wn=vt(null),Bs=vt(null);function Ns(e,t){switch(je(Wn,t),je(fn,e),je(at,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Sp(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Sp(t),e=wp(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}Re(at),je(at,e)}function ii(){Re(at),Re(fn),Re(Wn)}function Rc(e){e.memoizedState!==null&&je(Bs,e);var t=at.current,a=wp(t,e.type);t!==a&&(je(fn,e),je(at,a))}function Us(e){fn.current===e&&(Re(at),Re(fn)),Bs.current===e&&(Re(Bs),Kl._currentValue=te)}var kc=Object.prototype.hasOwnProperty,Bc=n.unstable_scheduleCallback,Nc=n.unstable_cancelCallback,D0=n.unstable_shouldYield,M0=n.unstable_requestPaint,hn=n.unstable_now,z0=n.unstable_getCurrentPriorityLevel,tf=n.unstable_ImmediatePriority,nf=n.unstable_UserBlockingPriority,Ls=n.unstable_NormalPriority,R0=n.unstable_LowPriority,af=n.unstable_IdlePriority,k0=n.log,B0=n.unstable_setDisableYieldValue,nl=null,zt=null;function Pn(e){if(typeof k0=="function"&&B0(e),zt&&typeof zt.setStrictMode=="function")try{zt.setStrictMode(nl,e)}catch{}}var Rt=Math.clz32?Math.clz32:L0,N0=Math.log,U0=Math.LN2;function L0(e){return e>>>=0,e===0?32:31-(N0(e)/U0|0)|0}var Hs=256,qs=4194304;function za(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function $s(e,t,a){var l=e.pendingLanes;if(l===0)return 0;var o=0,d=e.suspendedLanes,p=e.pingedLanes;e=e.warmLanes;var y=l&134217727;return y!==0?(l=y&~d,l!==0?o=za(l):(p&=y,p!==0?o=za(p):a||(a=y&~e,a!==0&&(o=za(a))))):(y=l&~d,y!==0?o=za(y):p!==0?o=za(p):a||(a=l&~e,a!==0&&(o=za(a)))),o===0?0:t!==0&&t!==o&&(t&d)===0&&(d=o&-o,a=t&-t,d>=a||d===32&&(a&4194048)!==0)?t:o}function al(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function H0(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function lf(){var e=Hs;return Hs<<=1,(Hs&4194048)===0&&(Hs=256),e}function sf(){var e=qs;return qs<<=1,(qs&62914560)===0&&(qs=4194304),e}function Uc(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function il(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function q0(e,t,a,l,o,d){var p=e.pendingLanes;e.pendingLanes=a,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=a,e.entangledLanes&=a,e.errorRecoveryDisabledLanes&=a,e.shellSuspendCounter=0;var y=e.entanglements,b=e.expirationTimes,O=e.hiddenUpdates;for(a=p&~a;0<a;){var k=31-Rt(a),L=1<<k;y[k]=0,b[k]=-1;var D=O[k];if(D!==null)for(O[k]=null,k=0;k<D.length;k++){var M=D[k];M!==null&&(M.lane&=-536870913)}a&=~L}l!==0&&rf(e,l,0),d!==0&&o===0&&e.tag!==0&&(e.suspendedLanes|=d&~(p&~t))}function rf(e,t,a){e.pendingLanes|=t,e.suspendedLanes&=~t;var l=31-Rt(t);e.entangledLanes|=t,e.entanglements[l]=e.entanglements[l]|1073741824|a&4194090}function cf(e,t){var a=e.entangledLanes|=t;for(e=e.entanglements;a;){var l=31-Rt(a),o=1<<l;o&t|e[l]&t&&(e[l]|=t),a&=~o}}function Lc(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Hc(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function of(){var e=Y.p;return e!==0?e:(e=window.event,e===void 0?32:Gp(e.type))}function $0(e,t){var a=Y.p;try{return Y.p=e,t()}finally{Y.p=a}}var In=Math.random().toString(36).slice(2),mt="__reactFiber$"+In,jt="__reactProps$"+In,li="__reactContainer$"+In,qc="__reactEvents$"+In,G0="__reactListeners$"+In,V0="__reactHandles$"+In,uf="__reactResources$"+In,ll="__reactMarker$"+In;function $c(e){delete e[mt],delete e[jt],delete e[qc],delete e[G0],delete e[V0]}function si(e){var t=e[mt];if(t)return t;for(var a=e.parentNode;a;){if(t=a[li]||a[mt]){if(a=t.alternate,t.child!==null||a!==null&&a.child!==null)for(e=Cp(e);e!==null;){if(a=e[mt])return a;e=Cp(e)}return t}e=a,a=e.parentNode}return null}function ri(e){if(e=e[mt]||e[li]){var t=e.tag;if(t===5||t===6||t===13||t===26||t===27||t===3)return e}return null}function sl(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(c(33))}function ci(e){var t=e[uf];return t||(t=e[uf]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function it(e){e[ll]=!0}var df=new Set,ff={};function Ra(e,t){oi(e,t),oi(e+"Capture",t)}function oi(e,t){for(ff[e]=t,e=0;e<t.length;e++)df.add(t[e])}var Y0=RegExp("^[: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]*$"),hf={},mf={};function X0(e){return kc.call(mf,e)?!0:kc.call(hf,e)?!1:Y0.test(e)?mf[e]=!0:(hf[e]=!0,!1)}function Gs(e,t,a){if(X0(t))if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var l=t.toLowerCase().slice(0,5);if(l!=="data-"&&l!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+a)}}function Vs(e,t,a){if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+a)}}function En(e,t,a,l){if(l===null)e.removeAttribute(a);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(a);return}e.setAttributeNS(t,a,""+l)}}var Gc,pf;function ui(e){if(Gc===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);Gc=t&&t[1]||"",pf=-1<a.stack.indexOf(`
    at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
`+Gc+e+pf}var Vc=!1;function Yc(e,t){if(!e||Vc)return"";Vc=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var l={DetermineComponentFrameRoot:function(){try{if(t){var L=function(){throw Error()};if(Object.defineProperty(L.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(L,[])}catch(M){var D=M}Reflect.construct(e,[],L)}else{try{L.call()}catch(M){D=M}e.call(L.prototype)}}else{try{throw Error()}catch(M){D=M}(L=e())&&typeof L.catch=="function"&&L.catch(function(){})}}catch(M){if(M&&D&&typeof M.stack=="string")return[M.stack,D.stack]}return[null,null]}};l.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var o=Object.getOwnPropertyDescriptor(l.DetermineComponentFrameRoot,"name");o&&o.configurable&&Object.defineProperty(l.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var d=l.DetermineComponentFrameRoot(),p=d[0],y=d[1];if(p&&y){var b=p.split(`
`),O=y.split(`
`);for(o=l=0;l<b.length&&!b[l].includes("DetermineComponentFrameRoot");)l++;for(;o<O.length&&!O[o].includes("DetermineComponentFrameRoot");)o++;if(l===b.length||o===O.length)for(l=b.length-1,o=O.length-1;1<=l&&0<=o&&b[l]!==O[o];)o--;for(;1<=l&&0<=o;l--,o--)if(b[l]!==O[o]){if(l!==1||o!==1)do if(l--,o--,0>o||b[l]!==O[o]){var k=`
`+b[l].replace(" at new "," at ");return e.displayName&&k.includes("<anonymous>")&&(k=k.replace("<anonymous>",e.displayName)),k}while(1<=l&&0<=o);break}}}finally{Vc=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?ui(a):""}function Q0(e){switch(e.tag){case 26:case 27:case 5:return ui(e.type);case 16:return ui("Lazy");case 13:return ui("Suspense");case 19:return ui("SuspenseList");case 0:case 15:return Yc(e.type,!1);case 11:return Yc(e.type.render,!1);case 1:return Yc(e.type,!0);case 31:return ui("Activity");default:return""}}function gf(e){try{var t="";do t+=Q0(e),e=e.return;while(e);return t}catch(a){return`
Error generating stack: `+a.message+`
`+a.stack}}function Vt(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function xf(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Z0(e){var t=xf(e)?"checked":"value",a=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),l=""+e[t];if(!e.hasOwnProperty(t)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var o=a.get,d=a.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(p){l=""+p,d.call(this,p)}}),Object.defineProperty(e,t,{enumerable:a.enumerable}),{getValue:function(){return l},setValue:function(p){l=""+p},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Ys(e){e._valueTracker||(e._valueTracker=Z0(e))}function yf(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var a=t.getValue(),l="";return e&&(l=xf(e)?e.checked?"true":"false":e.value),e=l,e!==a?(t.setValue(e),!0):!1}function Xs(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var K0=/[\n"\\]/g;function Yt(e){return e.replace(K0,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Xc(e,t,a,l,o,d,p,y){e.name="",p!=null&&typeof p!="function"&&typeof p!="symbol"&&typeof p!="boolean"?e.type=p:e.removeAttribute("type"),t!=null?p==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+Vt(t)):e.value!==""+Vt(t)&&(e.value=""+Vt(t)):p!=="submit"&&p!=="reset"||e.removeAttribute("value"),t!=null?Qc(e,p,Vt(t)):a!=null?Qc(e,p,Vt(a)):l!=null&&e.removeAttribute("value"),o==null&&d!=null&&(e.defaultChecked=!!d),o!=null&&(e.checked=o&&typeof o!="function"&&typeof o!="symbol"),y!=null&&typeof y!="function"&&typeof y!="symbol"&&typeof y!="boolean"?e.name=""+Vt(y):e.removeAttribute("name")}function vf(e,t,a,l,o,d,p,y){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),t!=null||a!=null){if(!(d!=="submit"&&d!=="reset"||t!=null))return;a=a!=null?""+Vt(a):"",t=t!=null?""+Vt(t):a,y||t===e.value||(e.value=t),e.defaultValue=t}l=l??o,l=typeof l!="function"&&typeof l!="symbol"&&!!l,e.checked=y?e.checked:!!l,e.defaultChecked=!!l,p!=null&&typeof p!="function"&&typeof p!="symbol"&&typeof p!="boolean"&&(e.name=p)}function Qc(e,t,a){t==="number"&&Xs(e.ownerDocument)===e||e.defaultValue===""+a||(e.defaultValue=""+a)}function di(e,t,a,l){if(e=e.options,t){t={};for(var o=0;o<a.length;o++)t["$"+a[o]]=!0;for(a=0;a<e.length;a++)o=t.hasOwnProperty("$"+e[a].value),e[a].selected!==o&&(e[a].selected=o),o&&l&&(e[a].defaultSelected=!0)}else{for(a=""+Vt(a),t=null,o=0;o<e.length;o++){if(e[o].value===a){e[o].selected=!0,l&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function bf(e,t,a){if(t!=null&&(t=""+Vt(t),t!==e.value&&(e.value=t),a==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=a!=null?""+Vt(a):""}function jf(e,t,a,l){if(t==null){if(l!=null){if(a!=null)throw Error(c(92));if(Cn(l)){if(1<l.length)throw Error(c(93));l=l[0]}a=l}a==null&&(a=""),t=a}a=Vt(t),e.defaultValue=a,l=e.textContent,l===a&&l!==""&&l!==null&&(e.value=l)}function fi(e,t){if(t){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=t;return}}e.textContent=t}var F0=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Sf(e,t,a){var l=t.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?l?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":l?e.setProperty(t,a):typeof a!="number"||a===0||F0.has(t)?t==="float"?e.cssFloat=a:e[t]=(""+a).trim():e[t]=a+"px"}function wf(e,t,a){if(t!=null&&typeof t!="object")throw Error(c(62));if(e=e.style,a!=null){for(var l in a)!a.hasOwnProperty(l)||t!=null&&t.hasOwnProperty(l)||(l.indexOf("--")===0?e.setProperty(l,""):l==="float"?e.cssFloat="":e[l]="");for(var o in t)l=t[o],t.hasOwnProperty(o)&&a[o]!==l&&Sf(e,o,l)}else for(var d in t)t.hasOwnProperty(d)&&Sf(e,d,t[d])}function Zc(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var J0=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),W0=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Qs(e){return W0.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Kc=null;function Fc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var hi=null,mi=null;function _f(e){var t=ri(e);if(t&&(e=t.stateNode)){var a=e[jt]||null;e:switch(e=t.stateNode,t.type){case"input":if(Xc(e,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),t=a.name,a.type==="radio"&&t!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+Yt(""+t)+'"][type="radio"]'),t=0;t<a.length;t++){var l=a[t];if(l!==e&&l.form===e.form){var o=l[jt]||null;if(!o)throw Error(c(90));Xc(l,o.value,o.defaultValue,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name)}}for(t=0;t<a.length;t++)l=a[t],l.form===e.form&&yf(l)}break e;case"textarea":bf(e,a.value,a.defaultValue);break e;case"select":t=a.value,t!=null&&di(e,!!a.multiple,t,!1)}}}var Jc=!1;function Tf(e,t,a){if(Jc)return e(t,a);Jc=!0;try{var l=e(t);return l}finally{if(Jc=!1,(hi!==null||mi!==null)&&(Mr(),hi&&(t=hi,e=mi,mi=hi=null,_f(t),e)))for(t=0;t<e.length;t++)_f(e[t])}}function rl(e,t){var a=e.stateNode;if(a===null)return null;var l=a[jt]||null;if(l===null)return null;a=l[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(l=!l.disabled)||(e=e.type,l=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!l;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(c(231,t,typeof a));return a}var On=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Wc=!1;if(On)try{var cl={};Object.defineProperty(cl,"passive",{get:function(){Wc=!0}}),window.addEventListener("test",cl,cl),window.removeEventListener("test",cl,cl)}catch{Wc=!1}var ea=null,Pc=null,Zs=null;function Af(){if(Zs)return Zs;var e,t=Pc,a=t.length,l,o="value"in ea?ea.value:ea.textContent,d=o.length;for(e=0;e<a&&t[e]===o[e];e++);var p=a-e;for(l=1;l<=p&&t[a-l]===o[d-l];l++);return Zs=o.slice(e,1<l?1-l:void 0)}function Ks(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Fs(){return!0}function Cf(){return!1}function St(e){function t(a,l,o,d,p){this._reactName=a,this._targetInst=o,this.type=l,this.nativeEvent=d,this.target=p,this.currentTarget=null;for(var y in e)e.hasOwnProperty(y)&&(a=e[y],this[y]=a?a(d):d[y]);return this.isDefaultPrevented=(d.defaultPrevented!=null?d.defaultPrevented:d.returnValue===!1)?Fs:Cf,this.isPropagationStopped=Cf,this}return v(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=Fs)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=Fs)},persist:function(){},isPersistent:Fs}),t}var ka={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Js=St(ka),ol=v({},ka,{view:0,detail:0}),P0=St(ol),Ic,eo,ul,Ws=v({},ol,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:no,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==ul&&(ul&&e.type==="mousemove"?(Ic=e.screenX-ul.screenX,eo=e.screenY-ul.screenY):eo=Ic=0,ul=e),Ic)},movementY:function(e){return"movementY"in e?e.movementY:eo}}),Ef=St(Ws),I0=v({},Ws,{dataTransfer:0}),ey=St(I0),ty=v({},ol,{relatedTarget:0}),to=St(ty),ny=v({},ka,{animationName:0,elapsedTime:0,pseudoElement:0}),ay=St(ny),iy=v({},ka,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),ly=St(iy),sy=v({},ka,{data:0}),Of=St(sy),ry={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},cy={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},oy={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function uy(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=oy[e])?!!t[e]:!1}function no(){return uy}var dy=v({},ol,{key:function(e){if(e.key){var t=ry[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Ks(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?cy[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:no,charCode:function(e){return e.type==="keypress"?Ks(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Ks(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),fy=St(dy),hy=v({},Ws,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Df=St(hy),my=v({},ol,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:no}),py=St(my),gy=v({},ka,{propertyName:0,elapsedTime:0,pseudoElement:0}),xy=St(gy),yy=v({},Ws,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),vy=St(yy),by=v({},ka,{newState:0,oldState:0}),jy=St(by),Sy=[9,13,27,32],ao=On&&"CompositionEvent"in window,dl=null;On&&"documentMode"in document&&(dl=document.documentMode);var wy=On&&"TextEvent"in window&&!dl,Mf=On&&(!ao||dl&&8<dl&&11>=dl),zf=" ",Rf=!1;function kf(e,t){switch(e){case"keyup":return Sy.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Bf(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var pi=!1;function _y(e,t){switch(e){case"compositionend":return Bf(t);case"keypress":return t.which!==32?null:(Rf=!0,zf);case"textInput":return e=t.data,e===zf&&Rf?null:e;default:return null}}function Ty(e,t){if(pi)return e==="compositionend"||!ao&&kf(e,t)?(e=Af(),Zs=Pc=ea=null,pi=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Mf&&t.locale!=="ko"?null:t.data;default:return null}}var Ay={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Nf(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Ay[e.type]:t==="textarea"}function Uf(e,t,a,l){hi?mi?mi.push(l):mi=[l]:hi=l,t=Ur(t,"onChange"),0<t.length&&(a=new Js("onChange","change",null,a,l),e.push({event:a,listeners:t}))}var fl=null,hl=null;function Cy(e){xp(e,0)}function Ps(e){var t=sl(e);if(yf(t))return e}function Lf(e,t){if(e==="change")return t}var Hf=!1;if(On){var io;if(On){var lo="oninput"in document;if(!lo){var qf=document.createElement("div");qf.setAttribute("oninput","return;"),lo=typeof qf.oninput=="function"}io=lo}else io=!1;Hf=io&&(!document.documentMode||9<document.documentMode)}function $f(){fl&&(fl.detachEvent("onpropertychange",Gf),hl=fl=null)}function Gf(e){if(e.propertyName==="value"&&Ps(hl)){var t=[];Uf(t,hl,e,Fc(e)),Tf(Cy,t)}}function Ey(e,t,a){e==="focusin"?($f(),fl=t,hl=a,fl.attachEvent("onpropertychange",Gf)):e==="focusout"&&$f()}function Oy(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Ps(hl)}function Dy(e,t){if(e==="click")return Ps(t)}function My(e,t){if(e==="input"||e==="change")return Ps(t)}function zy(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var kt=typeof Object.is=="function"?Object.is:zy;function ml(e,t){if(kt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var a=Object.keys(e),l=Object.keys(t);if(a.length!==l.length)return!1;for(l=0;l<a.length;l++){var o=a[l];if(!kc.call(t,o)||!kt(e[o],t[o]))return!1}return!0}function Vf(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Yf(e,t){var a=Vf(e);e=0;for(var l;a;){if(a.nodeType===3){if(l=e+a.textContent.length,e<=t&&l>=t)return{node:a,offset:t-e};e=l}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=Vf(a)}}function Xf(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Xf(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Qf(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Xs(e.document);t instanceof e.HTMLIFrameElement;){try{var a=typeof t.contentWindow.location.href=="string"}catch{a=!1}if(a)e=t.contentWindow;else break;t=Xs(e.document)}return t}function so(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var Ry=On&&"documentMode"in document&&11>=document.documentMode,gi=null,ro=null,pl=null,co=!1;function Zf(e,t,a){var l=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;co||gi==null||gi!==Xs(l)||(l=gi,"selectionStart"in l&&so(l)?l={start:l.selectionStart,end:l.selectionEnd}:(l=(l.ownerDocument&&l.ownerDocument.defaultView||window).getSelection(),l={anchorNode:l.anchorNode,anchorOffset:l.anchorOffset,focusNode:l.focusNode,focusOffset:l.focusOffset}),pl&&ml(pl,l)||(pl=l,l=Ur(ro,"onSelect"),0<l.length&&(t=new Js("onSelect","select",null,t,a),e.push({event:t,listeners:l}),t.target=gi)))}function Ba(e,t){var a={};return a[e.toLowerCase()]=t.toLowerCase(),a["Webkit"+e]="webkit"+t,a["Moz"+e]="moz"+t,a}var xi={animationend:Ba("Animation","AnimationEnd"),animationiteration:Ba("Animation","AnimationIteration"),animationstart:Ba("Animation","AnimationStart"),transitionrun:Ba("Transition","TransitionRun"),transitionstart:Ba("Transition","TransitionStart"),transitioncancel:Ba("Transition","TransitionCancel"),transitionend:Ba("Transition","TransitionEnd")},oo={},Kf={};On&&(Kf=document.createElement("div").style,"AnimationEvent"in window||(delete xi.animationend.animation,delete xi.animationiteration.animation,delete xi.animationstart.animation),"TransitionEvent"in window||delete xi.transitionend.transition);function Na(e){if(oo[e])return oo[e];if(!xi[e])return e;var t=xi[e],a;for(a in t)if(t.hasOwnProperty(a)&&a in Kf)return oo[e]=t[a];return e}var Ff=Na("animationend"),Jf=Na("animationiteration"),Wf=Na("animationstart"),ky=Na("transitionrun"),By=Na("transitionstart"),Ny=Na("transitioncancel"),Pf=Na("transitionend"),If=new Map,uo="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");uo.push("scrollEnd");function an(e,t){If.set(e,t),Ra(t,[e])}var eh=new WeakMap;function Xt(e,t){if(typeof e=="object"&&e!==null){var a=eh.get(e);return a!==void 0?a:(t={value:e,source:t,stack:gf(t)},eh.set(e,t),t)}return{value:e,source:t,stack:gf(t)}}var Qt=[],yi=0,fo=0;function Is(){for(var e=yi,t=fo=yi=0;t<e;){var a=Qt[t];Qt[t++]=null;var l=Qt[t];Qt[t++]=null;var o=Qt[t];Qt[t++]=null;var d=Qt[t];if(Qt[t++]=null,l!==null&&o!==null){var p=l.pending;p===null?o.next=o:(o.next=p.next,p.next=o),l.pending=o}d!==0&&th(a,o,d)}}function er(e,t,a,l){Qt[yi++]=e,Qt[yi++]=t,Qt[yi++]=a,Qt[yi++]=l,fo|=l,e.lanes|=l,e=e.alternate,e!==null&&(e.lanes|=l)}function ho(e,t,a,l){return er(e,t,a,l),tr(e)}function vi(e,t){return er(e,null,null,t),tr(e)}function th(e,t,a){e.lanes|=a;var l=e.alternate;l!==null&&(l.lanes|=a);for(var o=!1,d=e.return;d!==null;)d.childLanes|=a,l=d.alternate,l!==null&&(l.childLanes|=a),d.tag===22&&(e=d.stateNode,e===null||e._visibility&1||(o=!0)),e=d,d=d.return;return e.tag===3?(d=e.stateNode,o&&t!==null&&(o=31-Rt(a),e=d.hiddenUpdates,l=e[o],l===null?e[o]=[t]:l.push(t),t.lane=a|536870912),d):null}function tr(e){if(50<ql)throw ql=0,vu=null,Error(c(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var bi={};function Uy(e,t,a,l){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=l,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bt(e,t,a,l){return new Uy(e,t,a,l)}function mo(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Dn(e,t){var a=e.alternate;return a===null?(a=Bt(e.tag,t,e.key,e.mode),a.elementType=e.elementType,a.type=e.type,a.stateNode=e.stateNode,a.alternate=e,e.alternate=a):(a.pendingProps=t,a.type=e.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=e.flags&65011712,a.childLanes=e.childLanes,a.lanes=e.lanes,a.child=e.child,a.memoizedProps=e.memoizedProps,a.memoizedState=e.memoizedState,a.updateQueue=e.updateQueue,t=e.dependencies,a.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},a.sibling=e.sibling,a.index=e.index,a.ref=e.ref,a.refCleanup=e.refCleanup,a}function nh(e,t){e.flags&=65011714;var a=e.alternate;return a===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=a.childLanes,e.lanes=a.lanes,e.child=a.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=a.memoizedProps,e.memoizedState=a.memoizedState,e.updateQueue=a.updateQueue,e.type=a.type,t=a.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function nr(e,t,a,l,o,d){var p=0;if(l=e,typeof e=="function")mo(e)&&(p=1);else if(typeof e=="string")p=Hv(e,a,at.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case oe:return e=Bt(31,a,t,o),e.elementType=oe,e.lanes=d,e;case R:return Ua(a.children,o,d,t);case B:p=8,o|=24;break;case z:return e=Bt(12,a,t,o|2),e.elementType=z,e.lanes=d,e;case Z:return e=Bt(13,a,t,o),e.elementType=Z,e.lanes=d,e;case ee:return e=Bt(19,a,t,o),e.elementType=ee,e.lanes=d,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case H:case V:p=10;break e;case q:p=9;break e;case X:p=11;break e;case de:p=14;break e;case tt:p=16,l=null;break e}p=29,a=Error(c(130,e===null?"null":typeof e,"")),l=null}return t=Bt(p,a,t,o),t.elementType=e,t.type=l,t.lanes=d,t}function Ua(e,t,a,l){return e=Bt(7,e,l,t),e.lanes=a,e}function po(e,t,a){return e=Bt(6,e,null,t),e.lanes=a,e}function go(e,t,a){return t=Bt(4,e.children!==null?e.children:[],e.key,t),t.lanes=a,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var ji=[],Si=0,ar=null,ir=0,Zt=[],Kt=0,La=null,Mn=1,zn="";function Ha(e,t){ji[Si++]=ir,ji[Si++]=ar,ar=e,ir=t}function ah(e,t,a){Zt[Kt++]=Mn,Zt[Kt++]=zn,Zt[Kt++]=La,La=e;var l=Mn;e=zn;var o=32-Rt(l)-1;l&=~(1<<o),a+=1;var d=32-Rt(t)+o;if(30<d){var p=o-o%5;d=(l&(1<<p)-1).toString(32),l>>=p,o-=p,Mn=1<<32-Rt(t)+o|a<<o|l,zn=d+e}else Mn=1<<d|a<<o|l,zn=e}function xo(e){e.return!==null&&(Ha(e,1),ah(e,1,0))}function yo(e){for(;e===ar;)ar=ji[--Si],ji[Si]=null,ir=ji[--Si],ji[Si]=null;for(;e===La;)La=Zt[--Kt],Zt[Kt]=null,zn=Zt[--Kt],Zt[Kt]=null,Mn=Zt[--Kt],Zt[Kt]=null}var bt=null,qe=null,ge=!1,qa=null,mn=!1,vo=Error(c(519));function $a(e){var t=Error(c(418,""));throw yl(Xt(t,e)),vo}function ih(e){var t=e.stateNode,a=e.type,l=e.memoizedProps;switch(t[mt]=e,t[jt]=l,a){case"dialog":re("cancel",t),re("close",t);break;case"iframe":case"object":case"embed":re("load",t);break;case"video":case"audio":for(a=0;a<Gl.length;a++)re(Gl[a],t);break;case"source":re("error",t);break;case"img":case"image":case"link":re("error",t),re("load",t);break;case"details":re("toggle",t);break;case"input":re("invalid",t),vf(t,l.value,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name,!0),Ys(t);break;case"select":re("invalid",t);break;case"textarea":re("invalid",t),jf(t,l.value,l.defaultValue,l.children),Ys(t)}a=l.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||t.textContent===""+a||l.suppressHydrationWarning===!0||jp(t.textContent,a)?(l.popover!=null&&(re("beforetoggle",t),re("toggle",t)),l.onScroll!=null&&re("scroll",t),l.onScrollEnd!=null&&re("scrollend",t),l.onClick!=null&&(t.onclick=Lr),t=!0):t=!1,t||$a(e)}function lh(e){for(bt=e.return;bt;)switch(bt.tag){case 5:case 13:mn=!1;return;case 27:case 3:mn=!0;return;default:bt=bt.return}}function gl(e){if(e!==bt)return!1;if(!ge)return lh(e),ge=!0,!1;var t=e.tag,a;if((a=t!==3&&t!==27)&&((a=t===5)&&(a=e.type,a=!(a!=="form"&&a!=="button")||Bu(e.type,e.memoizedProps)),a=!a),a&&qe&&$a(e),lh(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(c(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8)if(a=e.data,a==="/$"){if(t===0){qe=sn(e.nextSibling);break e}t--}else a!=="$"&&a!=="$!"&&a!=="$?"||t++;e=e.nextSibling}qe=null}}else t===27?(t=qe,ga(e.type)?(e=Hu,Hu=null,qe=e):qe=t):qe=bt?sn(e.stateNode.nextSibling):null;return!0}function xl(){qe=bt=null,ge=!1}function sh(){var e=qa;return e!==null&&(Tt===null?Tt=e:Tt.push.apply(Tt,e),qa=null),e}function yl(e){qa===null?qa=[e]:qa.push(e)}var bo=vt(null),Ga=null,Rn=null;function ta(e,t,a){je(bo,t._currentValue),t._currentValue=a}function kn(e){e._currentValue=bo.current,Re(bo)}function jo(e,t,a){for(;e!==null;){var l=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,l!==null&&(l.childLanes|=t)):l!==null&&(l.childLanes&t)!==t&&(l.childLanes|=t),e===a)break;e=e.return}}function So(e,t,a,l){var o=e.child;for(o!==null&&(o.return=e);o!==null;){var d=o.dependencies;if(d!==null){var p=o.child;d=d.firstContext;e:for(;d!==null;){var y=d;d=o;for(var b=0;b<t.length;b++)if(y.context===t[b]){d.lanes|=a,y=d.alternate,y!==null&&(y.lanes|=a),jo(d.return,a,e),l||(p=null);break e}d=y.next}}else if(o.tag===18){if(p=o.return,p===null)throw Error(c(341));p.lanes|=a,d=p.alternate,d!==null&&(d.lanes|=a),jo(p,a,e),p=null}else p=o.child;if(p!==null)p.return=o;else for(p=o;p!==null;){if(p===e){p=null;break}if(o=p.sibling,o!==null){o.return=p.return,p=o;break}p=p.return}o=p}}function vl(e,t,a,l){e=null;for(var o=t,d=!1;o!==null;){if(!d){if((o.flags&524288)!==0)d=!0;else if((o.flags&262144)!==0)break}if(o.tag===10){var p=o.alternate;if(p===null)throw Error(c(387));if(p=p.memoizedProps,p!==null){var y=o.type;kt(o.pendingProps.value,p.value)||(e!==null?e.push(y):e=[y])}}else if(o===Bs.current){if(p=o.alternate,p===null)throw Error(c(387));p.memoizedState.memoizedState!==o.memoizedState.memoizedState&&(e!==null?e.push(Kl):e=[Kl])}o=o.return}e!==null&&So(t,e,a,l),t.flags|=262144}function lr(e){for(e=e.firstContext;e!==null;){if(!kt(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Va(e){Ga=e,Rn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function pt(e){return rh(Ga,e)}function sr(e,t){return Ga===null&&Va(e),rh(e,t)}function rh(e,t){var a=t._currentValue;if(t={context:t,memoizedValue:a,next:null},Rn===null){if(e===null)throw Error(c(308));Rn=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Rn=Rn.next=t;return a}var Ly=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(a,l){e.push(l)}};this.abort=function(){t.aborted=!0,e.forEach(function(a){return a()})}},Hy=n.unstable_scheduleCallback,qy=n.unstable_NormalPriority,We={$$typeof:V,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function wo(){return{controller:new Ly,data:new Map,refCount:0}}function bl(e){e.refCount--,e.refCount===0&&Hy(qy,function(){e.controller.abort()})}var jl=null,_o=0,wi=0,_i=null;function $y(e,t){if(jl===null){var a=jl=[];_o=0,wi=Au(),_i={status:"pending",value:void 0,then:function(l){a.push(l)}}}return _o++,t.then(ch,ch),t}function ch(){if(--_o===0&&jl!==null){_i!==null&&(_i.status="fulfilled");var e=jl;jl=null,wi=0,_i=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function Gy(e,t){var a=[],l={status:"pending",value:null,reason:null,then:function(o){a.push(o)}};return e.then(function(){l.status="fulfilled",l.value=t;for(var o=0;o<a.length;o++)(0,a[o])(t)},function(o){for(l.status="rejected",l.reason=o,o=0;o<a.length;o++)(0,a[o])(void 0)}),l}var oh=U.S;U.S=function(e,t){typeof t=="object"&&t!==null&&typeof t.then=="function"&&$y(e,t),oh!==null&&oh(e,t)};var Ya=vt(null);function To(){var e=Ya.current;return e!==null?e:Ae.pooledCache}function rr(e,t){t===null?je(Ya,Ya.current):je(Ya,t.pool)}function uh(){var e=To();return e===null?null:{parent:We._currentValue,pool:e}}var Sl=Error(c(460)),dh=Error(c(474)),cr=Error(c(542)),Ao={then:function(){}};function fh(e){return e=e.status,e==="fulfilled"||e==="rejected"}function or(){}function hh(e,t,a){switch(a=e[a],a===void 0?e.push(t):a!==t&&(t.then(or,or),t=a),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,ph(e),e;default:if(typeof t.status=="string")t.then(or,or);else{if(e=Ae,e!==null&&100<e.shellSuspendCounter)throw Error(c(482));e=t,e.status="pending",e.then(function(l){if(t.status==="pending"){var o=t;o.status="fulfilled",o.value=l}},function(l){if(t.status==="pending"){var o=t;o.status="rejected",o.reason=l}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,ph(e),e}throw wl=t,Sl}}var wl=null;function mh(){if(wl===null)throw Error(c(459));var e=wl;return wl=null,e}function ph(e){if(e===Sl||e===cr)throw Error(c(483))}var na=!1;function Co(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Eo(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function aa(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function ia(e,t,a){var l=e.updateQueue;if(l===null)return null;if(l=l.shared,(ve&2)!==0){var o=l.pending;return o===null?t.next=t:(t.next=o.next,o.next=t),l.pending=t,t=tr(e),th(e,null,a),t}return er(e,l,t,a),tr(e)}function _l(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194048)!==0)){var l=t.lanes;l&=e.pendingLanes,a|=l,t.lanes=a,cf(e,a)}}function Oo(e,t){var a=e.updateQueue,l=e.alternate;if(l!==null&&(l=l.updateQueue,a===l)){var o=null,d=null;if(a=a.firstBaseUpdate,a!==null){do{var p={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};d===null?o=d=p:d=d.next=p,a=a.next}while(a!==null);d===null?o=d=t:d=d.next=t}else o=d=t;a={baseState:l.baseState,firstBaseUpdate:o,lastBaseUpdate:d,shared:l.shared,callbacks:l.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}var Do=!1;function Tl(){if(Do){var e=_i;if(e!==null)throw e}}function Al(e,t,a,l){Do=!1;var o=e.updateQueue;na=!1;var d=o.firstBaseUpdate,p=o.lastBaseUpdate,y=o.shared.pending;if(y!==null){o.shared.pending=null;var b=y,O=b.next;b.next=null,p===null?d=O:p.next=O,p=b;var k=e.alternate;k!==null&&(k=k.updateQueue,y=k.lastBaseUpdate,y!==p&&(y===null?k.firstBaseUpdate=O:y.next=O,k.lastBaseUpdate=b))}if(d!==null){var L=o.baseState;p=0,k=O=b=null,y=d;do{var D=y.lane&-536870913,M=D!==y.lane;if(M?(ue&D)===D:(l&D)===D){D!==0&&D===wi&&(Do=!0),k!==null&&(k=k.next={lane:0,tag:y.tag,payload:y.payload,callback:null,next:null});e:{var I=e,W=y;D=t;var _e=a;switch(W.tag){case 1:if(I=W.payload,typeof I=="function"){L=I.call(_e,L,D);break e}L=I;break e;case 3:I.flags=I.flags&-65537|128;case 0:if(I=W.payload,D=typeof I=="function"?I.call(_e,L,D):I,D==null)break e;L=v({},L,D);break e;case 2:na=!0}}D=y.callback,D!==null&&(e.flags|=64,M&&(e.flags|=8192),M=o.callbacks,M===null?o.callbacks=[D]:M.push(D))}else M={lane:D,tag:y.tag,payload:y.payload,callback:y.callback,next:null},k===null?(O=k=M,b=L):k=k.next=M,p|=D;if(y=y.next,y===null){if(y=o.shared.pending,y===null)break;M=y,y=M.next,M.next=null,o.lastBaseUpdate=M,o.shared.pending=null}}while(!0);k===null&&(b=L),o.baseState=b,o.firstBaseUpdate=O,o.lastBaseUpdate=k,d===null&&(o.shared.lanes=0),fa|=p,e.lanes=p,e.memoizedState=L}}function gh(e,t){if(typeof e!="function")throw Error(c(191,e));e.call(t)}function xh(e,t){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;e<a.length;e++)gh(a[e],t)}var Ti=vt(null),ur=vt(0);function yh(e,t){e=$n,je(ur,e),je(Ti,t),$n=e|t.baseLanes}function Mo(){je(ur,$n),je(Ti,Ti.current)}function zo(){$n=ur.current,Re(Ti),Re(ur)}var la=0,ie=null,Se=null,Ze=null,dr=!1,Ai=!1,Xa=!1,fr=0,Cl=0,Ci=null,Vy=0;function Ve(){throw Error(c(321))}function Ro(e,t){if(t===null)return!1;for(var a=0;a<t.length&&a<e.length;a++)if(!kt(e[a],t[a]))return!1;return!0}function ko(e,t,a,l,o,d){return la=d,ie=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,U.H=e===null||e.memoizedState===null?tm:nm,Xa=!1,d=a(l,o),Xa=!1,Ai&&(d=bh(t,a,l,o)),vh(e),d}function vh(e){U.H=yr;var t=Se!==null&&Se.next!==null;if(la=0,Ze=Se=ie=null,dr=!1,Cl=0,Ci=null,t)throw Error(c(300));e===null||lt||(e=e.dependencies,e!==null&&lr(e)&&(lt=!0))}function bh(e,t,a,l){ie=e;var o=0;do{if(Ai&&(Ci=null),Cl=0,Ai=!1,25<=o)throw Error(c(301));if(o+=1,Ze=Se=null,e.updateQueue!=null){var d=e.updateQueue;d.lastEffect=null,d.events=null,d.stores=null,d.memoCache!=null&&(d.memoCache.index=0)}U.H=Jy,d=t(a,l)}while(Ai);return d}function Yy(){var e=U.H,t=e.useState()[0];return t=typeof t.then=="function"?El(t):t,e=e.useState()[0],(Se!==null?Se.memoizedState:null)!==e&&(ie.flags|=1024),t}function Bo(){var e=fr!==0;return fr=0,e}function No(e,t,a){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~a}function Uo(e){if(dr){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}dr=!1}la=0,Ze=Se=ie=null,Ai=!1,Cl=fr=0,Ci=null}function wt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ze===null?ie.memoizedState=Ze=e:Ze=Ze.next=e,Ze}function Ke(){if(Se===null){var e=ie.alternate;e=e!==null?e.memoizedState:null}else e=Se.next;var t=Ze===null?ie.memoizedState:Ze.next;if(t!==null)Ze=t,Se=e;else{if(e===null)throw ie.alternate===null?Error(c(467)):Error(c(310));Se=e,e={memoizedState:Se.memoizedState,baseState:Se.baseState,baseQueue:Se.baseQueue,queue:Se.queue,next:null},Ze===null?ie.memoizedState=Ze=e:Ze=Ze.next=e}return Ze}function Lo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function El(e){var t=Cl;return Cl+=1,Ci===null&&(Ci=[]),e=hh(Ci,e,t),t=ie,(Ze===null?t.memoizedState:Ze.next)===null&&(t=t.alternate,U.H=t===null||t.memoizedState===null?tm:nm),e}function hr(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return El(e);if(e.$$typeof===V)return pt(e)}throw Error(c(438,String(e)))}function Ho(e){var t=null,a=ie.updateQueue;if(a!==null&&(t=a.memoCache),t==null){var l=ie.alternate;l!==null&&(l=l.updateQueue,l!==null&&(l=l.memoCache,l!=null&&(t={data:l.data.map(function(o){return o.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),a===null&&(a=Lo(),ie.updateQueue=a),a.memoCache=t,a=t.data[t.index],a===void 0)for(a=t.data[t.index]=Array(e),l=0;l<e;l++)a[l]=Mt;return t.index++,a}function Bn(e,t){return typeof t=="function"?t(e):t}function mr(e){var t=Ke();return qo(t,Se,e)}function qo(e,t,a){var l=e.queue;if(l===null)throw Error(c(311));l.lastRenderedReducer=a;var o=e.baseQueue,d=l.pending;if(d!==null){if(o!==null){var p=o.next;o.next=d.next,d.next=p}t.baseQueue=o=d,l.pending=null}if(d=e.baseState,o===null)e.memoizedState=d;else{t=o.next;var y=p=null,b=null,O=t,k=!1;do{var L=O.lane&-536870913;if(L!==O.lane?(ue&L)===L:(la&L)===L){var D=O.revertLane;if(D===0)b!==null&&(b=b.next={lane:0,revertLane:0,action:O.action,hasEagerState:O.hasEagerState,eagerState:O.eagerState,next:null}),L===wi&&(k=!0);else if((la&D)===D){O=O.next,D===wi&&(k=!0);continue}else L={lane:0,revertLane:O.revertLane,action:O.action,hasEagerState:O.hasEagerState,eagerState:O.eagerState,next:null},b===null?(y=b=L,p=d):b=b.next=L,ie.lanes|=D,fa|=D;L=O.action,Xa&&a(d,L),d=O.hasEagerState?O.eagerState:a(d,L)}else D={lane:L,revertLane:O.revertLane,action:O.action,hasEagerState:O.hasEagerState,eagerState:O.eagerState,next:null},b===null?(y=b=D,p=d):b=b.next=D,ie.lanes|=L,fa|=L;O=O.next}while(O!==null&&O!==t);if(b===null?p=d:b.next=y,!kt(d,e.memoizedState)&&(lt=!0,k&&(a=_i,a!==null)))throw a;e.memoizedState=d,e.baseState=p,e.baseQueue=b,l.lastRenderedState=d}return o===null&&(l.lanes=0),[e.memoizedState,l.dispatch]}function $o(e){var t=Ke(),a=t.queue;if(a===null)throw Error(c(311));a.lastRenderedReducer=e;var l=a.dispatch,o=a.pending,d=t.memoizedState;if(o!==null){a.pending=null;var p=o=o.next;do d=e(d,p.action),p=p.next;while(p!==o);kt(d,t.memoizedState)||(lt=!0),t.memoizedState=d,t.baseQueue===null&&(t.baseState=d),a.lastRenderedState=d}return[d,l]}function jh(e,t,a){var l=ie,o=Ke(),d=ge;if(d){if(a===void 0)throw Error(c(407));a=a()}else a=t();var p=!kt((Se||o).memoizedState,a);p&&(o.memoizedState=a,lt=!0),o=o.queue;var y=_h.bind(null,l,o,e);if(Ol(2048,8,y,[e]),o.getSnapshot!==t||p||Ze!==null&&Ze.memoizedState.tag&1){if(l.flags|=2048,Ei(9,pr(),wh.bind(null,l,o,a,t),null),Ae===null)throw Error(c(349));d||(la&124)!==0||Sh(l,t,a)}return a}function Sh(e,t,a){e.flags|=16384,e={getSnapshot:t,value:a},t=ie.updateQueue,t===null?(t=Lo(),ie.updateQueue=t,t.stores=[e]):(a=t.stores,a===null?t.stores=[e]:a.push(e))}function wh(e,t,a,l){t.value=a,t.getSnapshot=l,Th(t)&&Ah(e)}function _h(e,t,a){return a(function(){Th(t)&&Ah(e)})}function Th(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!kt(e,a)}catch{return!0}}function Ah(e){var t=vi(e,2);t!==null&&qt(t,e,2)}function Go(e){var t=wt();if(typeof e=="function"){var a=e;if(e=a(),Xa){Pn(!0);try{a()}finally{Pn(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bn,lastRenderedState:e},t}function Ch(e,t,a,l){return e.baseState=a,qo(e,Se,typeof l=="function"?l:Bn)}function Xy(e,t,a,l,o){if(xr(e))throw Error(c(485));if(e=t.action,e!==null){var d={payload:o,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(p){d.listeners.push(p)}};U.T!==null?a(!0):d.isTransition=!1,l(d),a=t.pending,a===null?(d.next=t.pending=d,Eh(t,d)):(d.next=a.next,t.pending=a.next=d)}}function Eh(e,t){var a=t.action,l=t.payload,o=e.state;if(t.isTransition){var d=U.T,p={};U.T=p;try{var y=a(o,l),b=U.S;b!==null&&b(p,y),Oh(e,t,y)}catch(O){Vo(e,t,O)}finally{U.T=d}}else try{d=a(o,l),Oh(e,t,d)}catch(O){Vo(e,t,O)}}function Oh(e,t,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(l){Dh(e,t,l)},function(l){return Vo(e,t,l)}):Dh(e,t,a)}function Dh(e,t,a){t.status="fulfilled",t.value=a,Mh(t),e.state=a,t=e.pending,t!==null&&(a=t.next,a===t?e.pending=null:(a=a.next,t.next=a,Eh(e,a)))}function Vo(e,t,a){var l=e.pending;if(e.pending=null,l!==null){l=l.next;do t.status="rejected",t.reason=a,Mh(t),t=t.next;while(t!==l)}e.action=null}function Mh(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function zh(e,t){return t}function Rh(e,t){if(ge){var a=Ae.formState;if(a!==null){e:{var l=ie;if(ge){if(qe){t:{for(var o=qe,d=mn;o.nodeType!==8;){if(!d){o=null;break t}if(o=sn(o.nextSibling),o===null){o=null;break t}}d=o.data,o=d==="F!"||d==="F"?o:null}if(o){qe=sn(o.nextSibling),l=o.data==="F!";break e}}$a(l)}l=!1}l&&(t=a[0])}}return a=wt(),a.memoizedState=a.baseState=t,l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:zh,lastRenderedState:t},a.queue=l,a=Ph.bind(null,ie,l),l.dispatch=a,l=Go(!1),d=Ko.bind(null,ie,!1,l.queue),l=wt(),o={state:t,dispatch:null,action:e,pending:null},l.queue=o,a=Xy.bind(null,ie,o,d,a),o.dispatch=a,l.memoizedState=e,[t,a,!1]}function kh(e){var t=Ke();return Bh(t,Se,e)}function Bh(e,t,a){if(t=qo(e,t,zh)[0],e=mr(Bn)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var l=El(t)}catch(p){throw p===Sl?cr:p}else l=t;t=Ke();var o=t.queue,d=o.dispatch;return a!==t.memoizedState&&(ie.flags|=2048,Ei(9,pr(),Qy.bind(null,o,a),null)),[l,d,e]}function Qy(e,t){e.action=t}function Nh(e){var t=Ke(),a=Se;if(a!==null)return Bh(t,a,e);Ke(),t=t.memoizedState,a=Ke();var l=a.queue.dispatch;return a.memoizedState=e,[t,l,!1]}function Ei(e,t,a,l){return e={tag:e,create:a,deps:l,inst:t,next:null},t=ie.updateQueue,t===null&&(t=Lo(),ie.updateQueue=t),a=t.lastEffect,a===null?t.lastEffect=e.next=e:(l=a.next,a.next=e,e.next=l,t.lastEffect=e),e}function pr(){return{destroy:void 0,resource:void 0}}function Uh(){return Ke().memoizedState}function gr(e,t,a,l){var o=wt();l=l===void 0?null:l,ie.flags|=e,o.memoizedState=Ei(1|t,pr(),a,l)}function Ol(e,t,a,l){var o=Ke();l=l===void 0?null:l;var d=o.memoizedState.inst;Se!==null&&l!==null&&Ro(l,Se.memoizedState.deps)?o.memoizedState=Ei(t,d,a,l):(ie.flags|=e,o.memoizedState=Ei(1|t,d,a,l))}function Lh(e,t){gr(8390656,8,e,t)}function Hh(e,t){Ol(2048,8,e,t)}function qh(e,t){return Ol(4,2,e,t)}function $h(e,t){return Ol(4,4,e,t)}function Gh(e,t){if(typeof t=="function"){e=e();var a=t(e);return function(){typeof a=="function"?a():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Vh(e,t,a){a=a!=null?a.concat([e]):null,Ol(4,4,Gh.bind(null,t,e),a)}function Yo(){}function Yh(e,t){var a=Ke();t=t===void 0?null:t;var l=a.memoizedState;return t!==null&&Ro(t,l[1])?l[0]:(a.memoizedState=[e,t],e)}function Xh(e,t){var a=Ke();t=t===void 0?null:t;var l=a.memoizedState;if(t!==null&&Ro(t,l[1]))return l[0];if(l=e(),Xa){Pn(!0);try{e()}finally{Pn(!1)}}return a.memoizedState=[l,t],l}function Xo(e,t,a){return a===void 0||(la&1073741824)!==0?e.memoizedState=t:(e.memoizedState=a,e=Km(),ie.lanes|=e,fa|=e,a)}function Qh(e,t,a,l){return kt(a,t)?a:Ti.current!==null?(e=Xo(e,a,l),kt(e,t)||(lt=!0),e):(la&42)===0?(lt=!0,e.memoizedState=a):(e=Km(),ie.lanes|=e,fa|=e,t)}function Zh(e,t,a,l,o){var d=Y.p;Y.p=d!==0&&8>d?d:8;var p=U.T,y={};U.T=y,Ko(e,!1,t,a);try{var b=o(),O=U.S;if(O!==null&&O(y,b),b!==null&&typeof b=="object"&&typeof b.then=="function"){var k=Gy(b,l);Dl(e,t,k,Ht(e))}else Dl(e,t,l,Ht(e))}catch(L){Dl(e,t,{then:function(){},status:"rejected",reason:L},Ht())}finally{Y.p=d,U.T=p}}function Zy(){}function Qo(e,t,a,l){if(e.tag!==5)throw Error(c(476));var o=Kh(e).queue;Zh(e,o,t,te,a===null?Zy:function(){return Fh(e),a(l)})}function Kh(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:te,baseState:te,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bn,lastRenderedState:te},next:null};var a={};return t.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bn,lastRenderedState:a},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Fh(e){var t=Kh(e).next.queue;Dl(e,t,{},Ht())}function Zo(){return pt(Kl)}function Jh(){return Ke().memoizedState}function Wh(){return Ke().memoizedState}function Ky(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var a=Ht();e=aa(a);var l=ia(t,e,a);l!==null&&(qt(l,t,a),_l(l,t,a)),t={cache:wo()},e.payload=t;return}t=t.return}}function Fy(e,t,a){var l=Ht();a={lane:l,revertLane:0,action:a,hasEagerState:!1,eagerState:null,next:null},xr(e)?Ih(t,a):(a=ho(e,t,a,l),a!==null&&(qt(a,e,l),em(a,t,l)))}function Ph(e,t,a){var l=Ht();Dl(e,t,a,l)}function Dl(e,t,a,l){var o={lane:l,revertLane:0,action:a,hasEagerState:!1,eagerState:null,next:null};if(xr(e))Ih(t,o);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=t.lastRenderedReducer,d!==null))try{var p=t.lastRenderedState,y=d(p,a);if(o.hasEagerState=!0,o.eagerState=y,kt(y,p))return er(e,t,o,0),Ae===null&&Is(),!1}catch{}finally{}if(a=ho(e,t,o,l),a!==null)return qt(a,e,l),em(a,t,l),!0}return!1}function Ko(e,t,a,l){if(l={lane:2,revertLane:Au(),action:l,hasEagerState:!1,eagerState:null,next:null},xr(e)){if(t)throw Error(c(479))}else t=ho(e,a,l,2),t!==null&&qt(t,e,2)}function xr(e){var t=e.alternate;return e===ie||t!==null&&t===ie}function Ih(e,t){Ai=dr=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function em(e,t,a){if((a&4194048)!==0){var l=t.lanes;l&=e.pendingLanes,a|=l,t.lanes=a,cf(e,a)}}var yr={readContext:pt,use:hr,useCallback:Ve,useContext:Ve,useEffect:Ve,useImperativeHandle:Ve,useLayoutEffect:Ve,useInsertionEffect:Ve,useMemo:Ve,useReducer:Ve,useRef:Ve,useState:Ve,useDebugValue:Ve,useDeferredValue:Ve,useTransition:Ve,useSyncExternalStore:Ve,useId:Ve,useHostTransitionStatus:Ve,useFormState:Ve,useActionState:Ve,useOptimistic:Ve,useMemoCache:Ve,useCacheRefresh:Ve},tm={readContext:pt,use:hr,useCallback:function(e,t){return wt().memoizedState=[e,t===void 0?null:t],e},useContext:pt,useEffect:Lh,useImperativeHandle:function(e,t,a){a=a!=null?a.concat([e]):null,gr(4194308,4,Gh.bind(null,t,e),a)},useLayoutEffect:function(e,t){return gr(4194308,4,e,t)},useInsertionEffect:function(e,t){gr(4,2,e,t)},useMemo:function(e,t){var a=wt();t=t===void 0?null:t;var l=e();if(Xa){Pn(!0);try{e()}finally{Pn(!1)}}return a.memoizedState=[l,t],l},useReducer:function(e,t,a){var l=wt();if(a!==void 0){var o=a(t);if(Xa){Pn(!0);try{a(t)}finally{Pn(!1)}}}else o=t;return l.memoizedState=l.baseState=o,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:o},l.queue=e,e=e.dispatch=Fy.bind(null,ie,e),[l.memoizedState,e]},useRef:function(e){var t=wt();return e={current:e},t.memoizedState=e},useState:function(e){e=Go(e);var t=e.queue,a=Ph.bind(null,ie,t);return t.dispatch=a,[e.memoizedState,a]},useDebugValue:Yo,useDeferredValue:function(e,t){var a=wt();return Xo(a,e,t)},useTransition:function(){var e=Go(!1);return e=Zh.bind(null,ie,e.queue,!0,!1),wt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,a){var l=ie,o=wt();if(ge){if(a===void 0)throw Error(c(407));a=a()}else{if(a=t(),Ae===null)throw Error(c(349));(ue&124)!==0||Sh(l,t,a)}o.memoizedState=a;var d={value:a,getSnapshot:t};return o.queue=d,Lh(_h.bind(null,l,d,e),[e]),l.flags|=2048,Ei(9,pr(),wh.bind(null,l,d,a,t),null),a},useId:function(){var e=wt(),t=Ae.identifierPrefix;if(ge){var a=zn,l=Mn;a=(l&~(1<<32-Rt(l)-1)).toString(32)+a,t="«"+t+"R"+a,a=fr++,0<a&&(t+="H"+a.toString(32)),t+="»"}else a=Vy++,t="«"+t+"r"+a.toString(32)+"»";return e.memoizedState=t},useHostTransitionStatus:Zo,useFormState:Rh,useActionState:Rh,useOptimistic:function(e){var t=wt();t.memoizedState=t.baseState=e;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=a,t=Ko.bind(null,ie,!0,a),a.dispatch=t,[e,t]},useMemoCache:Ho,useCacheRefresh:function(){return wt().memoizedState=Ky.bind(null,ie)}},nm={readContext:pt,use:hr,useCallback:Yh,useContext:pt,useEffect:Hh,useImperativeHandle:Vh,useInsertionEffect:qh,useLayoutEffect:$h,useMemo:Xh,useReducer:mr,useRef:Uh,useState:function(){return mr(Bn)},useDebugValue:Yo,useDeferredValue:function(e,t){var a=Ke();return Qh(a,Se.memoizedState,e,t)},useTransition:function(){var e=mr(Bn)[0],t=Ke().memoizedState;return[typeof e=="boolean"?e:El(e),t]},useSyncExternalStore:jh,useId:Jh,useHostTransitionStatus:Zo,useFormState:kh,useActionState:kh,useOptimistic:function(e,t){var a=Ke();return Ch(a,Se,e,t)},useMemoCache:Ho,useCacheRefresh:Wh},Jy={readContext:pt,use:hr,useCallback:Yh,useContext:pt,useEffect:Hh,useImperativeHandle:Vh,useInsertionEffect:qh,useLayoutEffect:$h,useMemo:Xh,useReducer:$o,useRef:Uh,useState:function(){return $o(Bn)},useDebugValue:Yo,useDeferredValue:function(e,t){var a=Ke();return Se===null?Xo(a,e,t):Qh(a,Se.memoizedState,e,t)},useTransition:function(){var e=$o(Bn)[0],t=Ke().memoizedState;return[typeof e=="boolean"?e:El(e),t]},useSyncExternalStore:jh,useId:Jh,useHostTransitionStatus:Zo,useFormState:Nh,useActionState:Nh,useOptimistic:function(e,t){var a=Ke();return Se!==null?Ch(a,Se,e,t):(a.baseState=e,[e,a.queue.dispatch])},useMemoCache:Ho,useCacheRefresh:Wh},Oi=null,Ml=0;function vr(e){var t=Ml;return Ml+=1,Oi===null&&(Oi=[]),hh(Oi,e,t)}function zl(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function br(e,t){throw t.$$typeof===w?Error(c(525)):(e=Object.prototype.toString.call(t),Error(c(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function am(e){var t=e._init;return t(e._payload)}function im(e){function t(T,_){if(e){var C=T.deletions;C===null?(T.deletions=[_],T.flags|=16):C.push(_)}}function a(T,_){if(!e)return null;for(;_!==null;)t(T,_),_=_.sibling;return null}function l(T){for(var _=new Map;T!==null;)T.key!==null?_.set(T.key,T):_.set(T.index,T),T=T.sibling;return _}function o(T,_){return T=Dn(T,_),T.index=0,T.sibling=null,T}function d(T,_,C){return T.index=C,e?(C=T.alternate,C!==null?(C=C.index,C<_?(T.flags|=67108866,_):C):(T.flags|=67108866,_)):(T.flags|=1048576,_)}function p(T){return e&&T.alternate===null&&(T.flags|=67108866),T}function y(T,_,C,N){return _===null||_.tag!==6?(_=po(C,T.mode,N),_.return=T,_):(_=o(_,C),_.return=T,_)}function b(T,_,C,N){var Q=C.type;return Q===R?k(T,_,C.props.children,N,C.key):_!==null&&(_.elementType===Q||typeof Q=="object"&&Q!==null&&Q.$$typeof===tt&&am(Q)===_.type)?(_=o(_,C.props),zl(_,C),_.return=T,_):(_=nr(C.type,C.key,C.props,null,T.mode,N),zl(_,C),_.return=T,_)}function O(T,_,C,N){return _===null||_.tag!==4||_.stateNode.containerInfo!==C.containerInfo||_.stateNode.implementation!==C.implementation?(_=go(C,T.mode,N),_.return=T,_):(_=o(_,C.children||[]),_.return=T,_)}function k(T,_,C,N,Q){return _===null||_.tag!==7?(_=Ua(C,T.mode,N,Q),_.return=T,_):(_=o(_,C),_.return=T,_)}function L(T,_,C){if(typeof _=="string"&&_!==""||typeof _=="number"||typeof _=="bigint")return _=po(""+_,T.mode,C),_.return=T,_;if(typeof _=="object"&&_!==null){switch(_.$$typeof){case j:return C=nr(_.type,_.key,_.props,null,T.mode,C),zl(C,_),C.return=T,C;case E:return _=go(_,T.mode,C),_.return=T,_;case tt:var N=_._init;return _=N(_._payload),L(T,_,C)}if(Cn(_)||Je(_))return _=Ua(_,T.mode,C,null),_.return=T,_;if(typeof _.then=="function")return L(T,vr(_),C);if(_.$$typeof===V)return L(T,sr(T,_),C);br(T,_)}return null}function D(T,_,C,N){var Q=_!==null?_.key:null;if(typeof C=="string"&&C!==""||typeof C=="number"||typeof C=="bigint")return Q!==null?null:y(T,_,""+C,N);if(typeof C=="object"&&C!==null){switch(C.$$typeof){case j:return C.key===Q?b(T,_,C,N):null;case E:return C.key===Q?O(T,_,C,N):null;case tt:return Q=C._init,C=Q(C._payload),D(T,_,C,N)}if(Cn(C)||Je(C))return Q!==null?null:k(T,_,C,N,null);if(typeof C.then=="function")return D(T,_,vr(C),N);if(C.$$typeof===V)return D(T,_,sr(T,C),N);br(T,C)}return null}function M(T,_,C,N,Q){if(typeof N=="string"&&N!==""||typeof N=="number"||typeof N=="bigint")return T=T.get(C)||null,y(_,T,""+N,Q);if(typeof N=="object"&&N!==null){switch(N.$$typeof){case j:return T=T.get(N.key===null?C:N.key)||null,b(_,T,N,Q);case E:return T=T.get(N.key===null?C:N.key)||null,O(_,T,N,Q);case tt:var le=N._init;return N=le(N._payload),M(T,_,C,N,Q)}if(Cn(N)||Je(N))return T=T.get(C)||null,k(_,T,N,Q,null);if(typeof N.then=="function")return M(T,_,C,vr(N),Q);if(N.$$typeof===V)return M(T,_,C,sr(_,N),Q);br(_,N)}return null}function I(T,_,C,N){for(var Q=null,le=null,F=_,P=_=0,rt=null;F!==null&&P<C.length;P++){F.index>P?(rt=F,F=null):rt=F.sibling;var he=D(T,F,C[P],N);if(he===null){F===null&&(F=rt);break}e&&F&&he.alternate===null&&t(T,F),_=d(he,_,P),le===null?Q=he:le.sibling=he,le=he,F=rt}if(P===C.length)return a(T,F),ge&&Ha(T,P),Q;if(F===null){for(;P<C.length;P++)F=L(T,C[P],N),F!==null&&(_=d(F,_,P),le===null?Q=F:le.sibling=F,le=F);return ge&&Ha(T,P),Q}for(F=l(F);P<C.length;P++)rt=M(F,T,P,C[P],N),rt!==null&&(e&&rt.alternate!==null&&F.delete(rt.key===null?P:rt.key),_=d(rt,_,P),le===null?Q=rt:le.sibling=rt,le=rt);return e&&F.forEach(function(ja){return t(T,ja)}),ge&&Ha(T,P),Q}function W(T,_,C,N){if(C==null)throw Error(c(151));for(var Q=null,le=null,F=_,P=_=0,rt=null,he=C.next();F!==null&&!he.done;P++,he=C.next()){F.index>P?(rt=F,F=null):rt=F.sibling;var ja=D(T,F,he.value,N);if(ja===null){F===null&&(F=rt);break}e&&F&&ja.alternate===null&&t(T,F),_=d(ja,_,P),le===null?Q=ja:le.sibling=ja,le=ja,F=rt}if(he.done)return a(T,F),ge&&Ha(T,P),Q;if(F===null){for(;!he.done;P++,he=C.next())he=L(T,he.value,N),he!==null&&(_=d(he,_,P),le===null?Q=he:le.sibling=he,le=he);return ge&&Ha(T,P),Q}for(F=l(F);!he.done;P++,he=C.next())he=M(F,T,P,he.value,N),he!==null&&(e&&he.alternate!==null&&F.delete(he.key===null?P:he.key),_=d(he,_,P),le===null?Q=he:le.sibling=he,le=he);return e&&F.forEach(function(Wv){return t(T,Wv)}),ge&&Ha(T,P),Q}function _e(T,_,C,N){if(typeof C=="object"&&C!==null&&C.type===R&&C.key===null&&(C=C.props.children),typeof C=="object"&&C!==null){switch(C.$$typeof){case j:e:{for(var Q=C.key;_!==null;){if(_.key===Q){if(Q=C.type,Q===R){if(_.tag===7){a(T,_.sibling),N=o(_,C.props.children),N.return=T,T=N;break e}}else if(_.elementType===Q||typeof Q=="object"&&Q!==null&&Q.$$typeof===tt&&am(Q)===_.type){a(T,_.sibling),N=o(_,C.props),zl(N,C),N.return=T,T=N;break e}a(T,_);break}else t(T,_);_=_.sibling}C.type===R?(N=Ua(C.props.children,T.mode,N,C.key),N.return=T,T=N):(N=nr(C.type,C.key,C.props,null,T.mode,N),zl(N,C),N.return=T,T=N)}return p(T);case E:e:{for(Q=C.key;_!==null;){if(_.key===Q)if(_.tag===4&&_.stateNode.containerInfo===C.containerInfo&&_.stateNode.implementation===C.implementation){a(T,_.sibling),N=o(_,C.children||[]),N.return=T,T=N;break e}else{a(T,_);break}else t(T,_);_=_.sibling}N=go(C,T.mode,N),N.return=T,T=N}return p(T);case tt:return Q=C._init,C=Q(C._payload),_e(T,_,C,N)}if(Cn(C))return I(T,_,C,N);if(Je(C)){if(Q=Je(C),typeof Q!="function")throw Error(c(150));return C=Q.call(C),W(T,_,C,N)}if(typeof C.then=="function")return _e(T,_,vr(C),N);if(C.$$typeof===V)return _e(T,_,sr(T,C),N);br(T,C)}return typeof C=="string"&&C!==""||typeof C=="number"||typeof C=="bigint"?(C=""+C,_!==null&&_.tag===6?(a(T,_.sibling),N=o(_,C),N.return=T,T=N):(a(T,_),N=po(C,T.mode,N),N.return=T,T=N),p(T)):a(T,_)}return function(T,_,C,N){try{Ml=0;var Q=_e(T,_,C,N);return Oi=null,Q}catch(F){if(F===Sl||F===cr)throw F;var le=Bt(29,F,null,T.mode);return le.lanes=N,le.return=T,le}finally{}}}var Di=im(!0),lm=im(!1),Ft=vt(null),pn=null;function sa(e){var t=e.alternate;je(Pe,Pe.current&1),je(Ft,e),pn===null&&(t===null||Ti.current!==null||t.memoizedState!==null)&&(pn=e)}function sm(e){if(e.tag===22){if(je(Pe,Pe.current),je(Ft,e),pn===null){var t=e.alternate;t!==null&&t.memoizedState!==null&&(pn=e)}}else ra()}function ra(){je(Pe,Pe.current),je(Ft,Ft.current)}function Nn(e){Re(Ft),pn===e&&(pn=null),Re(Pe)}var Pe=vt(0);function jr(e){for(var t=e;t!==null;){if(t.tag===13){var a=t.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||a.data==="$?"||Lu(a)))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}function Fo(e,t,a,l){t=e.memoizedState,a=a(l,t),a=a==null?t:v({},t,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var Jo={enqueueSetState:function(e,t,a){e=e._reactInternals;var l=Ht(),o=aa(l);o.payload=t,a!=null&&(o.callback=a),t=ia(e,o,l),t!==null&&(qt(t,e,l),_l(t,e,l))},enqueueReplaceState:function(e,t,a){e=e._reactInternals;var l=Ht(),o=aa(l);o.tag=1,o.payload=t,a!=null&&(o.callback=a),t=ia(e,o,l),t!==null&&(qt(t,e,l),_l(t,e,l))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var a=Ht(),l=aa(a);l.tag=2,t!=null&&(l.callback=t),t=ia(e,l,a),t!==null&&(qt(t,e,a),_l(t,e,a))}};function rm(e,t,a,l,o,d,p){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(l,d,p):t.prototype&&t.prototype.isPureReactComponent?!ml(a,l)||!ml(o,d):!0}function cm(e,t,a,l){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(a,l),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(a,l),t.state!==e&&Jo.enqueueReplaceState(t,t.state,null)}function Qa(e,t){var a=t;if("ref"in t){a={};for(var l in t)l!=="ref"&&(a[l]=t[l])}if(e=e.defaultProps){a===t&&(a=v({},a));for(var o in e)a[o]===void 0&&(a[o]=e[o])}return a}var Sr=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function om(e){Sr(e)}function um(e){console.error(e)}function dm(e){Sr(e)}function wr(e,t){try{var a=e.onUncaughtError;a(t.value,{componentStack:t.stack})}catch(l){setTimeout(function(){throw l})}}function fm(e,t,a){try{var l=e.onCaughtError;l(a.value,{componentStack:a.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(o){setTimeout(function(){throw o})}}function Wo(e,t,a){return a=aa(a),a.tag=3,a.payload={element:null},a.callback=function(){wr(e,t)},a}function hm(e){return e=aa(e),e.tag=3,e}function mm(e,t,a,l){var o=a.type.getDerivedStateFromError;if(typeof o=="function"){var d=l.value;e.payload=function(){return o(d)},e.callback=function(){fm(t,a,l)}}var p=a.stateNode;p!==null&&typeof p.componentDidCatch=="function"&&(e.callback=function(){fm(t,a,l),typeof o!="function"&&(ha===null?ha=new Set([this]):ha.add(this));var y=l.stack;this.componentDidCatch(l.value,{componentStack:y!==null?y:""})})}function Wy(e,t,a,l,o){if(a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){if(t=a.alternate,t!==null&&vl(t,a,o,!0),a=Ft.current,a!==null){switch(a.tag){case 13:return pn===null?ju():a.alternate===null&&$e===0&&($e=3),a.flags&=-257,a.flags|=65536,a.lanes=o,l===Ao?a.flags|=16384:(t=a.updateQueue,t===null?a.updateQueue=new Set([l]):t.add(l),wu(e,l,o)),!1;case 22:return a.flags|=65536,l===Ao?a.flags|=16384:(t=a.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([l])},a.updateQueue=t):(a=t.retryQueue,a===null?t.retryQueue=new Set([l]):a.add(l)),wu(e,l,o)),!1}throw Error(c(435,a.tag))}return wu(e,l,o),ju(),!1}if(ge)return t=Ft.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=o,l!==vo&&(e=Error(c(422),{cause:l}),yl(Xt(e,a)))):(l!==vo&&(t=Error(c(423),{cause:l}),yl(Xt(t,a))),e=e.current.alternate,e.flags|=65536,o&=-o,e.lanes|=o,l=Xt(l,a),o=Wo(e.stateNode,l,o),Oo(e,o),$e!==4&&($e=2)),!1;var d=Error(c(520),{cause:l});if(d=Xt(d,a),Hl===null?Hl=[d]:Hl.push(d),$e!==4&&($e=2),t===null)return!0;l=Xt(l,a),a=t;do{switch(a.tag){case 3:return a.flags|=65536,e=o&-o,a.lanes|=e,e=Wo(a.stateNode,l,e),Oo(a,e),!1;case 1:if(t=a.type,d=a.stateNode,(a.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||d!==null&&typeof d.componentDidCatch=="function"&&(ha===null||!ha.has(d))))return a.flags|=65536,o&=-o,a.lanes|=o,o=hm(o),mm(o,e,a,l),Oo(a,o),!1}a=a.return}while(a!==null);return!1}var pm=Error(c(461)),lt=!1;function ut(e,t,a,l){t.child=e===null?lm(t,null,a,l):Di(t,e.child,a,l)}function gm(e,t,a,l,o){a=a.render;var d=t.ref;if("ref"in l){var p={};for(var y in l)y!=="ref"&&(p[y]=l[y])}else p=l;return Va(t),l=ko(e,t,a,p,d,o),y=Bo(),e!==null&&!lt?(No(e,t,o),Un(e,t,o)):(ge&&y&&xo(t),t.flags|=1,ut(e,t,l,o),t.child)}function xm(e,t,a,l,o){if(e===null){var d=a.type;return typeof d=="function"&&!mo(d)&&d.defaultProps===void 0&&a.compare===null?(t.tag=15,t.type=d,ym(e,t,d,l,o)):(e=nr(a.type,null,l,t,t.mode,o),e.ref=t.ref,e.return=t,t.child=e)}if(d=e.child,!lu(e,o)){var p=d.memoizedProps;if(a=a.compare,a=a!==null?a:ml,a(p,l)&&e.ref===t.ref)return Un(e,t,o)}return t.flags|=1,e=Dn(d,l),e.ref=t.ref,e.return=t,t.child=e}function ym(e,t,a,l,o){if(e!==null){var d=e.memoizedProps;if(ml(d,l)&&e.ref===t.ref)if(lt=!1,t.pendingProps=l=d,lu(e,o))(e.flags&131072)!==0&&(lt=!0);else return t.lanes=e.lanes,Un(e,t,o)}return Po(e,t,a,l,o)}function vm(e,t,a){var l=t.pendingProps,o=l.children,d=e!==null?e.memoizedState:null;if(l.mode==="hidden"){if((t.flags&128)!==0){if(l=d!==null?d.baseLanes|a:a,e!==null){for(o=t.child=e.child,d=0;o!==null;)d=d|o.lanes|o.childLanes,o=o.sibling;t.childLanes=d&~l}else t.childLanes=0,t.child=null;return bm(e,t,l,a)}if((a&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&rr(t,d!==null?d.cachePool:null),d!==null?yh(t,d):Mo(),sm(t);else return t.lanes=t.childLanes=536870912,bm(e,t,d!==null?d.baseLanes|a:a,a)}else d!==null?(rr(t,d.cachePool),yh(t,d),ra(),t.memoizedState=null):(e!==null&&rr(t,null),Mo(),ra());return ut(e,t,o,a),t.child}function bm(e,t,a,l){var o=To();return o=o===null?null:{parent:We._currentValue,pool:o},t.memoizedState={baseLanes:a,cachePool:o},e!==null&&rr(t,null),Mo(),sm(t),e!==null&&vl(e,t,l,!0),null}function _r(e,t){var a=t.ref;if(a===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(c(284));(e===null||e.ref!==a)&&(t.flags|=4194816)}}function Po(e,t,a,l,o){return Va(t),a=ko(e,t,a,l,void 0,o),l=Bo(),e!==null&&!lt?(No(e,t,o),Un(e,t,o)):(ge&&l&&xo(t),t.flags|=1,ut(e,t,a,o),t.child)}function jm(e,t,a,l,o,d){return Va(t),t.updateQueue=null,a=bh(t,l,a,o),vh(e),l=Bo(),e!==null&&!lt?(No(e,t,d),Un(e,t,d)):(ge&&l&&xo(t),t.flags|=1,ut(e,t,a,d),t.child)}function Sm(e,t,a,l,o){if(Va(t),t.stateNode===null){var d=bi,p=a.contextType;typeof p=="object"&&p!==null&&(d=pt(p)),d=new a(l,d),t.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,d.updater=Jo,t.stateNode=d,d._reactInternals=t,d=t.stateNode,d.props=l,d.state=t.memoizedState,d.refs={},Co(t),p=a.contextType,d.context=typeof p=="object"&&p!==null?pt(p):bi,d.state=t.memoizedState,p=a.getDerivedStateFromProps,typeof p=="function"&&(Fo(t,a,p,l),d.state=t.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof d.getSnapshotBeforeUpdate=="function"||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(p=d.state,typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount(),p!==d.state&&Jo.enqueueReplaceState(d,d.state,null),Al(t,l,d,o),Tl(),d.state=t.memoizedState),typeof d.componentDidMount=="function"&&(t.flags|=4194308),l=!0}else if(e===null){d=t.stateNode;var y=t.memoizedProps,b=Qa(a,y);d.props=b;var O=d.context,k=a.contextType;p=bi,typeof k=="object"&&k!==null&&(p=pt(k));var L=a.getDerivedStateFromProps;k=typeof L=="function"||typeof d.getSnapshotBeforeUpdate=="function",y=t.pendingProps!==y,k||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(y||O!==p)&&cm(t,d,l,p),na=!1;var D=t.memoizedState;d.state=D,Al(t,l,d,o),Tl(),O=t.memoizedState,y||D!==O||na?(typeof L=="function"&&(Fo(t,a,L,l),O=t.memoizedState),(b=na||rm(t,a,b,l,D,O,p))?(k||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount()),typeof d.componentDidMount=="function"&&(t.flags|=4194308)):(typeof d.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=l,t.memoizedState=O),d.props=l,d.state=O,d.context=p,l=b):(typeof d.componentDidMount=="function"&&(t.flags|=4194308),l=!1)}else{d=t.stateNode,Eo(e,t),p=t.memoizedProps,k=Qa(a,p),d.props=k,L=t.pendingProps,D=d.context,O=a.contextType,b=bi,typeof O=="object"&&O!==null&&(b=pt(O)),y=a.getDerivedStateFromProps,(O=typeof y=="function"||typeof d.getSnapshotBeforeUpdate=="function")||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(p!==L||D!==b)&&cm(t,d,l,b),na=!1,D=t.memoizedState,d.state=D,Al(t,l,d,o),Tl();var M=t.memoizedState;p!==L||D!==M||na||e!==null&&e.dependencies!==null&&lr(e.dependencies)?(typeof y=="function"&&(Fo(t,a,y,l),M=t.memoizedState),(k=na||rm(t,a,k,l,D,M,b)||e!==null&&e.dependencies!==null&&lr(e.dependencies))?(O||typeof d.UNSAFE_componentWillUpdate!="function"&&typeof d.componentWillUpdate!="function"||(typeof d.componentWillUpdate=="function"&&d.componentWillUpdate(l,M,b),typeof d.UNSAFE_componentWillUpdate=="function"&&d.UNSAFE_componentWillUpdate(l,M,b)),typeof d.componentDidUpdate=="function"&&(t.flags|=4),typeof d.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof d.componentDidUpdate!="function"||p===e.memoizedProps&&D===e.memoizedState||(t.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||p===e.memoizedProps&&D===e.memoizedState||(t.flags|=1024),t.memoizedProps=l,t.memoizedState=M),d.props=l,d.state=M,d.context=b,l=k):(typeof d.componentDidUpdate!="function"||p===e.memoizedProps&&D===e.memoizedState||(t.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||p===e.memoizedProps&&D===e.memoizedState||(t.flags|=1024),l=!1)}return d=l,_r(e,t),l=(t.flags&128)!==0,d||l?(d=t.stateNode,a=l&&typeof a.getDerivedStateFromError!="function"?null:d.render(),t.flags|=1,e!==null&&l?(t.child=Di(t,e.child,null,o),t.child=Di(t,null,a,o)):ut(e,t,a,o),t.memoizedState=d.state,e=t.child):e=Un(e,t,o),e}function wm(e,t,a,l){return xl(),t.flags|=256,ut(e,t,a,l),t.child}var Io={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function eu(e){return{baseLanes:e,cachePool:uh()}}function tu(e,t,a){return e=e!==null?e.childLanes&~a:0,t&&(e|=Jt),e}function _m(e,t,a){var l=t.pendingProps,o=!1,d=(t.flags&128)!==0,p;if((p=d)||(p=e!==null&&e.memoizedState===null?!1:(Pe.current&2)!==0),p&&(o=!0,t.flags&=-129),p=(t.flags&32)!==0,t.flags&=-33,e===null){if(ge){if(o?sa(t):ra(),ge){var y=qe,b;if(b=y){e:{for(b=y,y=mn;b.nodeType!==8;){if(!y){y=null;break e}if(b=sn(b.nextSibling),b===null){y=null;break e}}y=b}y!==null?(t.memoizedState={dehydrated:y,treeContext:La!==null?{id:Mn,overflow:zn}:null,retryLane:536870912,hydrationErrors:null},b=Bt(18,null,null,0),b.stateNode=y,b.return=t,t.child=b,bt=t,qe=null,b=!0):b=!1}b||$a(t)}if(y=t.memoizedState,y!==null&&(y=y.dehydrated,y!==null))return Lu(y)?t.lanes=32:t.lanes=536870912,null;Nn(t)}return y=l.children,l=l.fallback,o?(ra(),o=t.mode,y=Tr({mode:"hidden",children:y},o),l=Ua(l,o,a,null),y.return=t,l.return=t,y.sibling=l,t.child=y,o=t.child,o.memoizedState=eu(a),o.childLanes=tu(e,p,a),t.memoizedState=Io,l):(sa(t),nu(t,y))}if(b=e.memoizedState,b!==null&&(y=b.dehydrated,y!==null)){if(d)t.flags&256?(sa(t),t.flags&=-257,t=au(e,t,a)):t.memoizedState!==null?(ra(),t.child=e.child,t.flags|=128,t=null):(ra(),o=l.fallback,y=t.mode,l=Tr({mode:"visible",children:l.children},y),o=Ua(o,y,a,null),o.flags|=2,l.return=t,o.return=t,l.sibling=o,t.child=l,Di(t,e.child,null,a),l=t.child,l.memoizedState=eu(a),l.childLanes=tu(e,p,a),t.memoizedState=Io,t=o);else if(sa(t),Lu(y)){if(p=y.nextSibling&&y.nextSibling.dataset,p)var O=p.dgst;p=O,l=Error(c(419)),l.stack="",l.digest=p,yl({value:l,source:null,stack:null}),t=au(e,t,a)}else if(lt||vl(e,t,a,!1),p=(a&e.childLanes)!==0,lt||p){if(p=Ae,p!==null&&(l=a&-a,l=(l&42)!==0?1:Lc(l),l=(l&(p.suspendedLanes|a))!==0?0:l,l!==0&&l!==b.retryLane))throw b.retryLane=l,vi(e,l),qt(p,e,l),pm;y.data==="$?"||ju(),t=au(e,t,a)}else y.data==="$?"?(t.flags|=192,t.child=e.child,t=null):(e=b.treeContext,qe=sn(y.nextSibling),bt=t,ge=!0,qa=null,mn=!1,e!==null&&(Zt[Kt++]=Mn,Zt[Kt++]=zn,Zt[Kt++]=La,Mn=e.id,zn=e.overflow,La=t),t=nu(t,l.children),t.flags|=4096);return t}return o?(ra(),o=l.fallback,y=t.mode,b=e.child,O=b.sibling,l=Dn(b,{mode:"hidden",children:l.children}),l.subtreeFlags=b.subtreeFlags&65011712,O!==null?o=Dn(O,o):(o=Ua(o,y,a,null),o.flags|=2),o.return=t,l.return=t,l.sibling=o,t.child=l,l=o,o=t.child,y=e.child.memoizedState,y===null?y=eu(a):(b=y.cachePool,b!==null?(O=We._currentValue,b=b.parent!==O?{parent:O,pool:O}:b):b=uh(),y={baseLanes:y.baseLanes|a,cachePool:b}),o.memoizedState=y,o.childLanes=tu(e,p,a),t.memoizedState=Io,l):(sa(t),a=e.child,e=a.sibling,a=Dn(a,{mode:"visible",children:l.children}),a.return=t,a.sibling=null,e!==null&&(p=t.deletions,p===null?(t.deletions=[e],t.flags|=16):p.push(e)),t.child=a,t.memoizedState=null,a)}function nu(e,t){return t=Tr({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function Tr(e,t){return e=Bt(22,e,null,t),e.lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function au(e,t,a){return Di(t,e.child,null,a),e=nu(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Tm(e,t,a){e.lanes|=t;var l=e.alternate;l!==null&&(l.lanes|=t),jo(e.return,t,a)}function iu(e,t,a,l,o){var d=e.memoizedState;d===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:l,tail:a,tailMode:o}:(d.isBackwards=t,d.rendering=null,d.renderingStartTime=0,d.last=l,d.tail=a,d.tailMode=o)}function Am(e,t,a){var l=t.pendingProps,o=l.revealOrder,d=l.tail;if(ut(e,t,l.children,a),l=Pe.current,(l&2)!==0)l=l&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Tm(e,a,t);else if(e.tag===19)Tm(e,a,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}l&=1}switch(je(Pe,l),o){case"forwards":for(a=t.child,o=null;a!==null;)e=a.alternate,e!==null&&jr(e)===null&&(o=a),a=a.sibling;a=o,a===null?(o=t.child,t.child=null):(o=a.sibling,a.sibling=null),iu(t,!1,o,a,d);break;case"backwards":for(a=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&jr(e)===null){t.child=o;break}e=o.sibling,o.sibling=a,a=o,o=e}iu(t,!0,a,null,d);break;case"together":iu(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Un(e,t,a){if(e!==null&&(t.dependencies=e.dependencies),fa|=t.lanes,(a&t.childLanes)===0)if(e!==null){if(vl(e,t,a,!1),(a&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(c(153));if(t.child!==null){for(e=t.child,a=Dn(e,e.pendingProps),t.child=a,a.return=t;e.sibling!==null;)e=e.sibling,a=a.sibling=Dn(e,e.pendingProps),a.return=t;a.sibling=null}return t.child}function lu(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&lr(e)))}function Py(e,t,a){switch(t.tag){case 3:Ns(t,t.stateNode.containerInfo),ta(t,We,e.memoizedState.cache),xl();break;case 27:case 5:Rc(t);break;case 4:Ns(t,t.stateNode.containerInfo);break;case 10:ta(t,t.type,t.memoizedProps.value);break;case 13:var l=t.memoizedState;if(l!==null)return l.dehydrated!==null?(sa(t),t.flags|=128,null):(a&t.child.childLanes)!==0?_m(e,t,a):(sa(t),e=Un(e,t,a),e!==null?e.sibling:null);sa(t);break;case 19:var o=(e.flags&128)!==0;if(l=(a&t.childLanes)!==0,l||(vl(e,t,a,!1),l=(a&t.childLanes)!==0),o){if(l)return Am(e,t,a);t.flags|=128}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),je(Pe,Pe.current),l)break;return null;case 22:case 23:return t.lanes=0,vm(e,t,a);case 24:ta(t,We,e.memoizedState.cache)}return Un(e,t,a)}function Cm(e,t,a){if(e!==null)if(e.memoizedProps!==t.pendingProps)lt=!0;else{if(!lu(e,a)&&(t.flags&128)===0)return lt=!1,Py(e,t,a);lt=(e.flags&131072)!==0}else lt=!1,ge&&(t.flags&1048576)!==0&&ah(t,ir,t.index);switch(t.lanes=0,t.tag){case 16:e:{e=t.pendingProps;var l=t.elementType,o=l._init;if(l=o(l._payload),t.type=l,typeof l=="function")mo(l)?(e=Qa(l,e),t.tag=1,t=Sm(null,t,l,e,a)):(t.tag=0,t=Po(null,t,l,e,a));else{if(l!=null){if(o=l.$$typeof,o===X){t.tag=11,t=gm(null,t,l,e,a);break e}else if(o===de){t.tag=14,t=xm(null,t,l,e,a);break e}}throw t=Ma(l)||l,Error(c(306,t,""))}}return t;case 0:return Po(e,t,t.type,t.pendingProps,a);case 1:return l=t.type,o=Qa(l,t.pendingProps),Sm(e,t,l,o,a);case 3:e:{if(Ns(t,t.stateNode.containerInfo),e===null)throw Error(c(387));l=t.pendingProps;var d=t.memoizedState;o=d.element,Eo(e,t),Al(t,l,null,a);var p=t.memoizedState;if(l=p.cache,ta(t,We,l),l!==d.cache&&So(t,[We],a,!0),Tl(),l=p.element,d.isDehydrated)if(d={element:l,isDehydrated:!1,cache:p.cache},t.updateQueue.baseState=d,t.memoizedState=d,t.flags&256){t=wm(e,t,l,a);break e}else if(l!==o){o=Xt(Error(c(424)),t),yl(o),t=wm(e,t,l,a);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(qe=sn(e.firstChild),bt=t,ge=!0,qa=null,mn=!0,a=lm(t,null,l,a),t.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling}else{if(xl(),l===o){t=Un(e,t,a);break e}ut(e,t,l,a)}t=t.child}return t;case 26:return _r(e,t),e===null?(a=Mp(t.type,null,t.pendingProps,null))?t.memoizedState=a:ge||(a=t.type,e=t.pendingProps,l=Hr(Wn.current).createElement(a),l[mt]=t,l[jt]=e,ft(l,a,e),it(l),t.stateNode=l):t.memoizedState=Mp(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Rc(t),e===null&&ge&&(l=t.stateNode=Ep(t.type,t.pendingProps,Wn.current),bt=t,mn=!0,o=qe,ga(t.type)?(Hu=o,qe=sn(l.firstChild)):qe=o),ut(e,t,t.pendingProps.children,a),_r(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&ge&&((o=l=qe)&&(l=Av(l,t.type,t.pendingProps,mn),l!==null?(t.stateNode=l,bt=t,qe=sn(l.firstChild),mn=!1,o=!0):o=!1),o||$a(t)),Rc(t),o=t.type,d=t.pendingProps,p=e!==null?e.memoizedProps:null,l=d.children,Bu(o,d)?l=null:p!==null&&Bu(o,p)&&(t.flags|=32),t.memoizedState!==null&&(o=ko(e,t,Yy,null,null,a),Kl._currentValue=o),_r(e,t),ut(e,t,l,a),t.child;case 6:return e===null&&ge&&((e=a=qe)&&(a=Cv(a,t.pendingProps,mn),a!==null?(t.stateNode=a,bt=t,qe=null,e=!0):e=!1),e||$a(t)),null;case 13:return _m(e,t,a);case 4:return Ns(t,t.stateNode.containerInfo),l=t.pendingProps,e===null?t.child=Di(t,null,l,a):ut(e,t,l,a),t.child;case 11:return gm(e,t,t.type,t.pendingProps,a);case 7:return ut(e,t,t.pendingProps,a),t.child;case 8:return ut(e,t,t.pendingProps.children,a),t.child;case 12:return ut(e,t,t.pendingProps.children,a),t.child;case 10:return l=t.pendingProps,ta(t,t.type,l.value),ut(e,t,l.children,a),t.child;case 9:return o=t.type._context,l=t.pendingProps.children,Va(t),o=pt(o),l=l(o),t.flags|=1,ut(e,t,l,a),t.child;case 14:return xm(e,t,t.type,t.pendingProps,a);case 15:return ym(e,t,t.type,t.pendingProps,a);case 19:return Am(e,t,a);case 31:return l=t.pendingProps,a=t.mode,l={mode:l.mode,children:l.children},e===null?(a=Tr(l,a),a.ref=t.ref,t.child=a,a.return=t,t=a):(a=Dn(e.child,l),a.ref=t.ref,t.child=a,a.return=t,t=a),t;case 22:return vm(e,t,a);case 24:return Va(t),l=pt(We),e===null?(o=To(),o===null&&(o=Ae,d=wo(),o.pooledCache=d,d.refCount++,d!==null&&(o.pooledCacheLanes|=a),o=d),t.memoizedState={parent:l,cache:o},Co(t),ta(t,We,o)):((e.lanes&a)!==0&&(Eo(e,t),Al(t,null,null,a),Tl()),o=e.memoizedState,d=t.memoizedState,o.parent!==l?(o={parent:l,cache:l},t.memoizedState=o,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=o),ta(t,We,l)):(l=d.cache,ta(t,We,l),l!==o.cache&&So(t,[We],a,!0))),ut(e,t,t.pendingProps.children,a),t.child;case 29:throw t.pendingProps}throw Error(c(156,t.tag))}function Ln(e){e.flags|=4}function Em(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Np(t)){if(t=Ft.current,t!==null&&((ue&4194048)===ue?pn!==null:(ue&62914560)!==ue&&(ue&536870912)===0||t!==pn))throw wl=Ao,dh;e.flags|=8192}}function Ar(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?sf():536870912,e.lanes|=t,ki|=t)}function Rl(e,t){if(!ge)switch(e.tailMode){case"hidden":t=e.tail;for(var a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?e.tail=null:a.sibling=null;break;case"collapsed":a=e.tail;for(var l=null;a!==null;)a.alternate!==null&&(l=a),a=a.sibling;l===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:l.sibling=null}}function ke(e){var t=e.alternate!==null&&e.alternate.child===e.child,a=0,l=0;if(t)for(var o=e.child;o!==null;)a|=o.lanes|o.childLanes,l|=o.subtreeFlags&65011712,l|=o.flags&65011712,o.return=e,o=o.sibling;else for(o=e.child;o!==null;)a|=o.lanes|o.childLanes,l|=o.subtreeFlags,l|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=l,e.childLanes=a,t}function Iy(e,t,a){var l=t.pendingProps;switch(yo(t),t.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ke(t),null;case 1:return ke(t),null;case 3:return a=t.stateNode,l=null,e!==null&&(l=e.memoizedState.cache),t.memoizedState.cache!==l&&(t.flags|=2048),kn(We),ii(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(gl(t)?Ln(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,sh())),ke(t),null;case 26:return a=t.memoizedState,e===null?(Ln(t),a!==null?(ke(t),Em(t,a)):(ke(t),t.flags&=-16777217)):a?a!==e.memoizedState?(Ln(t),ke(t),Em(t,a)):(ke(t),t.flags&=-16777217):(e.memoizedProps!==l&&Ln(t),ke(t),t.flags&=-16777217),null;case 27:Us(t),a=Wn.current;var o=t.type;if(e!==null&&t.stateNode!=null)e.memoizedProps!==l&&Ln(t);else{if(!l){if(t.stateNode===null)throw Error(c(166));return ke(t),null}e=at.current,gl(t)?ih(t):(e=Ep(o,l,a),t.stateNode=e,Ln(t))}return ke(t),null;case 5:if(Us(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==l&&Ln(t);else{if(!l){if(t.stateNode===null)throw Error(c(166));return ke(t),null}if(e=at.current,gl(t))ih(t);else{switch(o=Hr(Wn.current),e){case 1:e=o.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:e=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":e=o.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":e=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild);break;case"select":e=typeof l.is=="string"?o.createElement("select",{is:l.is}):o.createElement("select"),l.multiple?e.multiple=!0:l.size&&(e.size=l.size);break;default:e=typeof l.is=="string"?o.createElement(a,{is:l.is}):o.createElement(a)}}e[mt]=t,e[jt]=l;e:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)e.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break e;for(;o.sibling===null;){if(o.return===null||o.return===t)break e;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=e;e:switch(ft(e,a,l),a){case"button":case"input":case"select":case"textarea":e=!!l.autoFocus;break e;case"img":e=!0;break e;default:e=!1}e&&Ln(t)}}return ke(t),t.flags&=-16777217,null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==l&&Ln(t);else{if(typeof l!="string"&&t.stateNode===null)throw Error(c(166));if(e=Wn.current,gl(t)){if(e=t.stateNode,a=t.memoizedProps,l=null,o=bt,o!==null)switch(o.tag){case 27:case 5:l=o.memoizedProps}e[mt]=t,e=!!(e.nodeValue===a||l!==null&&l.suppressHydrationWarning===!0||jp(e.nodeValue,a)),e||$a(t)}else e=Hr(e).createTextNode(l),e[mt]=t,t.stateNode=e}return ke(t),null;case 13:if(l=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(o=gl(t),l!==null&&l.dehydrated!==null){if(e===null){if(!o)throw Error(c(318));if(o=t.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(c(317));o[mt]=t}else xl(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;ke(t),o=!1}else o=sh(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=o),o=!0;if(!o)return t.flags&256?(Nn(t),t):(Nn(t),null)}if(Nn(t),(t.flags&128)!==0)return t.lanes=a,t;if(a=l!==null,e=e!==null&&e.memoizedState!==null,a){l=t.child,o=null,l.alternate!==null&&l.alternate.memoizedState!==null&&l.alternate.memoizedState.cachePool!==null&&(o=l.alternate.memoizedState.cachePool.pool);var d=null;l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(d=l.memoizedState.cachePool.pool),d!==o&&(l.flags|=2048)}return a!==e&&a&&(t.child.flags|=8192),Ar(t,t.updateQueue),ke(t),null;case 4:return ii(),e===null&&Du(t.stateNode.containerInfo),ke(t),null;case 10:return kn(t.type),ke(t),null;case 19:if(Re(Pe),o=t.memoizedState,o===null)return ke(t),null;if(l=(t.flags&128)!==0,d=o.rendering,d===null)if(l)Rl(o,!1);else{if($e!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(d=jr(e),d!==null){for(t.flags|=128,Rl(o,!1),e=d.updateQueue,t.updateQueue=e,Ar(t,e),t.subtreeFlags=0,e=a,a=t.child;a!==null;)nh(a,e),a=a.sibling;return je(Pe,Pe.current&1|2),t.child}e=e.sibling}o.tail!==null&&hn()>Or&&(t.flags|=128,l=!0,Rl(o,!1),t.lanes=4194304)}else{if(!l)if(e=jr(d),e!==null){if(t.flags|=128,l=!0,e=e.updateQueue,t.updateQueue=e,Ar(t,e),Rl(o,!0),o.tail===null&&o.tailMode==="hidden"&&!d.alternate&&!ge)return ke(t),null}else 2*hn()-o.renderingStartTime>Or&&a!==536870912&&(t.flags|=128,l=!0,Rl(o,!1),t.lanes=4194304);o.isBackwards?(d.sibling=t.child,t.child=d):(e=o.last,e!==null?e.sibling=d:t.child=d,o.last=d)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=hn(),t.sibling=null,e=Pe.current,je(Pe,l?e&1|2:e&1),t):(ke(t),null);case 22:case 23:return Nn(t),zo(),l=t.memoizedState!==null,e!==null?e.memoizedState!==null!==l&&(t.flags|=8192):l&&(t.flags|=8192),l?(a&536870912)!==0&&(t.flags&128)===0&&(ke(t),t.subtreeFlags&6&&(t.flags|=8192)):ke(t),a=t.updateQueue,a!==null&&Ar(t,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),l=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),l!==a&&(t.flags|=2048),e!==null&&Re(Ya),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),kn(We),ke(t),null;case 25:return null;case 30:return null}throw Error(c(156,t.tag))}function ev(e,t){switch(yo(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return kn(We),ii(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Us(t),null;case 13:if(Nn(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(c(340));xl()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Re(Pe),null;case 4:return ii(),null;case 10:return kn(t.type),null;case 22:case 23:return Nn(t),zo(),e!==null&&Re(Ya),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return kn(We),null;case 25:return null;default:return null}}function Om(e,t){switch(yo(t),t.tag){case 3:kn(We),ii();break;case 26:case 27:case 5:Us(t);break;case 4:ii();break;case 13:Nn(t);break;case 19:Re(Pe);break;case 10:kn(t.type);break;case 22:case 23:Nn(t),zo(),e!==null&&Re(Ya);break;case 24:kn(We)}}function kl(e,t){try{var a=t.updateQueue,l=a!==null?a.lastEffect:null;if(l!==null){var o=l.next;a=o;do{if((a.tag&e)===e){l=void 0;var d=a.create,p=a.inst;l=d(),p.destroy=l}a=a.next}while(a!==o)}}catch(y){Te(t,t.return,y)}}function ca(e,t,a){try{var l=t.updateQueue,o=l!==null?l.lastEffect:null;if(o!==null){var d=o.next;l=d;do{if((l.tag&e)===e){var p=l.inst,y=p.destroy;if(y!==void 0){p.destroy=void 0,o=t;var b=a,O=y;try{O()}catch(k){Te(o,b,k)}}}l=l.next}while(l!==d)}}catch(k){Te(t,t.return,k)}}function Dm(e){var t=e.updateQueue;if(t!==null){var a=e.stateNode;try{xh(t,a)}catch(l){Te(e,e.return,l)}}}function Mm(e,t,a){a.props=Qa(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(l){Te(e,t,l)}}function Bl(e,t){try{var a=e.ref;if(a!==null){switch(e.tag){case 26:case 27:case 5:var l=e.stateNode;break;case 30:l=e.stateNode;break;default:l=e.stateNode}typeof a=="function"?e.refCleanup=a(l):a.current=l}}catch(o){Te(e,t,o)}}function gn(e,t){var a=e.ref,l=e.refCleanup;if(a!==null)if(typeof l=="function")try{l()}catch(o){Te(e,t,o)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(o){Te(e,t,o)}else a.current=null}function zm(e){var t=e.type,a=e.memoizedProps,l=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":a.autoFocus&&l.focus();break e;case"img":a.src?l.src=a.src:a.srcSet&&(l.srcset=a.srcSet)}}catch(o){Te(e,e.return,o)}}function su(e,t,a){try{var l=e.stateNode;jv(l,e.type,a,t),l[jt]=t}catch(o){Te(e,e.return,o)}}function Rm(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&ga(e.type)||e.tag===4}function ru(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Rm(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&ga(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function cu(e,t,a){var l=e.tag;if(l===5||l===6)e=e.stateNode,t?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(e,t):(t=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,t.appendChild(e),a=a._reactRootContainer,a!=null||t.onclick!==null||(t.onclick=Lr));else if(l!==4&&(l===27&&ga(e.type)&&(a=e.stateNode,t=null),e=e.child,e!==null))for(cu(e,t,a),e=e.sibling;e!==null;)cu(e,t,a),e=e.sibling}function Cr(e,t,a){var l=e.tag;if(l===5||l===6)e=e.stateNode,t?a.insertBefore(e,t):a.appendChild(e);else if(l!==4&&(l===27&&ga(e.type)&&(a=e.stateNode),e=e.child,e!==null))for(Cr(e,t,a),e=e.sibling;e!==null;)Cr(e,t,a),e=e.sibling}function km(e){var t=e.stateNode,a=e.memoizedProps;try{for(var l=e.type,o=t.attributes;o.length;)t.removeAttributeNode(o[0]);ft(t,l,a),t[mt]=e,t[jt]=a}catch(d){Te(e,e.return,d)}}var Hn=!1,Ye=!1,ou=!1,Bm=typeof WeakSet=="function"?WeakSet:Set,st=null;function tv(e,t){if(e=e.containerInfo,Ru=Xr,e=Qf(e),so(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var l=a.getSelection&&a.getSelection();if(l&&l.rangeCount!==0){a=l.anchorNode;var o=l.anchorOffset,d=l.focusNode;l=l.focusOffset;try{a.nodeType,d.nodeType}catch{a=null;break e}var p=0,y=-1,b=-1,O=0,k=0,L=e,D=null;t:for(;;){for(var M;L!==a||o!==0&&L.nodeType!==3||(y=p+o),L!==d||l!==0&&L.nodeType!==3||(b=p+l),L.nodeType===3&&(p+=L.nodeValue.length),(M=L.firstChild)!==null;)D=L,L=M;for(;;){if(L===e)break t;if(D===a&&++O===o&&(y=p),D===d&&++k===l&&(b=p),(M=L.nextSibling)!==null)break;L=D,D=L.parentNode}L=M}a=y===-1||b===-1?null:{start:y,end:b}}else a=null}a=a||{start:0,end:0}}else a=null;for(ku={focusedElem:e,selectionRange:a},Xr=!1,st=t;st!==null;)if(t=st,e=t.child,(t.subtreeFlags&1024)!==0&&e!==null)e.return=t,st=e;else for(;st!==null;){switch(t=st,d=t.alternate,e=t.flags,t.tag){case 0:break;case 11:case 15:break;case 1:if((e&1024)!==0&&d!==null){e=void 0,a=t,o=d.memoizedProps,d=d.memoizedState,l=a.stateNode;try{var I=Qa(a.type,o,a.elementType===a.type);e=l.getSnapshotBeforeUpdate(I,d),l.__reactInternalSnapshotBeforeUpdate=e}catch(W){Te(a,a.return,W)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,a=e.nodeType,a===9)Uu(e);else if(a===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Uu(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(c(163))}if(e=t.sibling,e!==null){e.return=t.return,st=e;break}st=t.return}}function Nm(e,t,a){var l=a.flags;switch(a.tag){case 0:case 11:case 15:oa(e,a),l&4&&kl(5,a);break;case 1:if(oa(e,a),l&4)if(e=a.stateNode,t===null)try{e.componentDidMount()}catch(p){Te(a,a.return,p)}else{var o=Qa(a.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(o,t,e.__reactInternalSnapshotBeforeUpdate)}catch(p){Te(a,a.return,p)}}l&64&&Dm(a),l&512&&Bl(a,a.return);break;case 3:if(oa(e,a),l&64&&(e=a.updateQueue,e!==null)){if(t=null,a.child!==null)switch(a.child.tag){case 27:case 5:t=a.child.stateNode;break;case 1:t=a.child.stateNode}try{xh(e,t)}catch(p){Te(a,a.return,p)}}break;case 27:t===null&&l&4&&km(a);case 26:case 5:oa(e,a),t===null&&l&4&&zm(a),l&512&&Bl(a,a.return);break;case 12:oa(e,a);break;case 13:oa(e,a),l&4&&Hm(e,a),l&64&&(e=a.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(a=uv.bind(null,a),Ev(e,a))));break;case 22:if(l=a.memoizedState!==null||Hn,!l){t=t!==null&&t.memoizedState!==null||Ye,o=Hn;var d=Ye;Hn=l,(Ye=t)&&!d?ua(e,a,(a.subtreeFlags&8772)!==0):oa(e,a),Hn=o,Ye=d}break;case 30:break;default:oa(e,a)}}function Um(e){var t=e.alternate;t!==null&&(e.alternate=null,Um(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&$c(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Me=null,_t=!1;function qn(e,t,a){for(a=a.child;a!==null;)Lm(e,t,a),a=a.sibling}function Lm(e,t,a){if(zt&&typeof zt.onCommitFiberUnmount=="function")try{zt.onCommitFiberUnmount(nl,a)}catch{}switch(a.tag){case 26:Ye||gn(a,t),qn(e,t,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:Ye||gn(a,t);var l=Me,o=_t;ga(a.type)&&(Me=a.stateNode,_t=!1),qn(e,t,a),Yl(a.stateNode),Me=l,_t=o;break;case 5:Ye||gn(a,t);case 6:if(l=Me,o=_t,Me=null,qn(e,t,a),Me=l,_t=o,Me!==null)if(_t)try{(Me.nodeType===9?Me.body:Me.nodeName==="HTML"?Me.ownerDocument.body:Me).removeChild(a.stateNode)}catch(d){Te(a,t,d)}else try{Me.removeChild(a.stateNode)}catch(d){Te(a,t,d)}break;case 18:Me!==null&&(_t?(e=Me,Ap(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,a.stateNode),Pl(e)):Ap(Me,a.stateNode));break;case 4:l=Me,o=_t,Me=a.stateNode.containerInfo,_t=!0,qn(e,t,a),Me=l,_t=o;break;case 0:case 11:case 14:case 15:Ye||ca(2,a,t),Ye||ca(4,a,t),qn(e,t,a);break;case 1:Ye||(gn(a,t),l=a.stateNode,typeof l.componentWillUnmount=="function"&&Mm(a,t,l)),qn(e,t,a);break;case 21:qn(e,t,a);break;case 22:Ye=(l=Ye)||a.memoizedState!==null,qn(e,t,a),Ye=l;break;default:qn(e,t,a)}}function Hm(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Pl(e)}catch(a){Te(t,t.return,a)}}function nv(e){switch(e.tag){case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Bm),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Bm),t;default:throw Error(c(435,e.tag))}}function uu(e,t){var a=nv(e);t.forEach(function(l){var o=dv.bind(null,e,l);a.has(l)||(a.add(l),l.then(o,o))})}function Nt(e,t){var a=t.deletions;if(a!==null)for(var l=0;l<a.length;l++){var o=a[l],d=e,p=t,y=p;e:for(;y!==null;){switch(y.tag){case 27:if(ga(y.type)){Me=y.stateNode,_t=!1;break e}break;case 5:Me=y.stateNode,_t=!1;break e;case 3:case 4:Me=y.stateNode.containerInfo,_t=!0;break e}y=y.return}if(Me===null)throw Error(c(160));Lm(d,p,o),Me=null,_t=!1,d=o.alternate,d!==null&&(d.return=null),o.return=null}if(t.subtreeFlags&13878)for(t=t.child;t!==null;)qm(t,e),t=t.sibling}var ln=null;function qm(e,t){var a=e.alternate,l=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Nt(t,e),Ut(e),l&4&&(ca(3,e,e.return),kl(3,e),ca(5,e,e.return));break;case 1:Nt(t,e),Ut(e),l&512&&(Ye||a===null||gn(a,a.return)),l&64&&Hn&&(e=e.updateQueue,e!==null&&(l=e.callbacks,l!==null&&(a=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=a===null?l:a.concat(l))));break;case 26:var o=ln;if(Nt(t,e),Ut(e),l&512&&(Ye||a===null||gn(a,a.return)),l&4){var d=a!==null?a.memoizedState:null;if(l=e.memoizedState,a===null)if(l===null)if(e.stateNode===null){e:{l=e.type,a=e.memoizedProps,o=o.ownerDocument||o;t:switch(l){case"title":d=o.getElementsByTagName("title")[0],(!d||d[ll]||d[mt]||d.namespaceURI==="http://www.w3.org/2000/svg"||d.hasAttribute("itemprop"))&&(d=o.createElement(l),o.head.insertBefore(d,o.querySelector("head > title"))),ft(d,l,a),d[mt]=e,it(d),l=d;break e;case"link":var p=kp("link","href",o).get(l+(a.href||""));if(p){for(var y=0;y<p.length;y++)if(d=p[y],d.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&d.getAttribute("rel")===(a.rel==null?null:a.rel)&&d.getAttribute("title")===(a.title==null?null:a.title)&&d.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){p.splice(y,1);break t}}d=o.createElement(l),ft(d,l,a),o.head.appendChild(d);break;case"meta":if(p=kp("meta","content",o).get(l+(a.content||""))){for(y=0;y<p.length;y++)if(d=p[y],d.getAttribute("content")===(a.content==null?null:""+a.content)&&d.getAttribute("name")===(a.name==null?null:a.name)&&d.getAttribute("property")===(a.property==null?null:a.property)&&d.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&d.getAttribute("charset")===(a.charSet==null?null:a.charSet)){p.splice(y,1);break t}}d=o.createElement(l),ft(d,l,a),o.head.appendChild(d);break;default:throw Error(c(468,l))}d[mt]=e,it(d),l=d}e.stateNode=l}else Bp(o,e.type,e.stateNode);else e.stateNode=Rp(o,l,e.memoizedProps);else d!==l?(d===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):d.count--,l===null?Bp(o,e.type,e.stateNode):Rp(o,l,e.memoizedProps)):l===null&&e.stateNode!==null&&su(e,e.memoizedProps,a.memoizedProps)}break;case 27:Nt(t,e),Ut(e),l&512&&(Ye||a===null||gn(a,a.return)),a!==null&&l&4&&su(e,e.memoizedProps,a.memoizedProps);break;case 5:if(Nt(t,e),Ut(e),l&512&&(Ye||a===null||gn(a,a.return)),e.flags&32){o=e.stateNode;try{fi(o,"")}catch(M){Te(e,e.return,M)}}l&4&&e.stateNode!=null&&(o=e.memoizedProps,su(e,o,a!==null?a.memoizedProps:o)),l&1024&&(ou=!0);break;case 6:if(Nt(t,e),Ut(e),l&4){if(e.stateNode===null)throw Error(c(162));l=e.memoizedProps,a=e.stateNode;try{a.nodeValue=l}catch(M){Te(e,e.return,M)}}break;case 3:if(Gr=null,o=ln,ln=qr(t.containerInfo),Nt(t,e),ln=o,Ut(e),l&4&&a!==null&&a.memoizedState.isDehydrated)try{Pl(t.containerInfo)}catch(M){Te(e,e.return,M)}ou&&(ou=!1,$m(e));break;case 4:l=ln,ln=qr(e.stateNode.containerInfo),Nt(t,e),Ut(e),ln=l;break;case 12:Nt(t,e),Ut(e);break;case 13:Nt(t,e),Ut(e),e.child.flags&8192&&e.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(gu=hn()),l&4&&(l=e.updateQueue,l!==null&&(e.updateQueue=null,uu(e,l)));break;case 22:o=e.memoizedState!==null;var b=a!==null&&a.memoizedState!==null,O=Hn,k=Ye;if(Hn=O||o,Ye=k||b,Nt(t,e),Ye=k,Hn=O,Ut(e),l&8192)e:for(t=e.stateNode,t._visibility=o?t._visibility&-2:t._visibility|1,o&&(a===null||b||Hn||Ye||Za(e)),a=null,t=e;;){if(t.tag===5||t.tag===26){if(a===null){b=a=t;try{if(d=b.stateNode,o)p=d.style,typeof p.setProperty=="function"?p.setProperty("display","none","important"):p.display="none";else{y=b.stateNode;var L=b.memoizedProps.style,D=L!=null&&L.hasOwnProperty("display")?L.display:null;y.style.display=D==null||typeof D=="boolean"?"":(""+D).trim()}}catch(M){Te(b,b.return,M)}}}else if(t.tag===6){if(a===null){b=t;try{b.stateNode.nodeValue=o?"":b.memoizedProps}catch(M){Te(b,b.return,M)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;a===t&&(a=null),t=t.return}a===t&&(a=null),t.sibling.return=t.return,t=t.sibling}l&4&&(l=e.updateQueue,l!==null&&(a=l.retryQueue,a!==null&&(l.retryQueue=null,uu(e,a))));break;case 19:Nt(t,e),Ut(e),l&4&&(l=e.updateQueue,l!==null&&(e.updateQueue=null,uu(e,l)));break;case 30:break;case 21:break;default:Nt(t,e),Ut(e)}}function Ut(e){var t=e.flags;if(t&2){try{for(var a,l=e.return;l!==null;){if(Rm(l)){a=l;break}l=l.return}if(a==null)throw Error(c(160));switch(a.tag){case 27:var o=a.stateNode,d=ru(e);Cr(e,d,o);break;case 5:var p=a.stateNode;a.flags&32&&(fi(p,""),a.flags&=-33);var y=ru(e);Cr(e,y,p);break;case 3:case 4:var b=a.stateNode.containerInfo,O=ru(e);cu(e,O,b);break;default:throw Error(c(161))}}catch(k){Te(e,e.return,k)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function $m(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;$m(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function oa(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Nm(e,t.alternate,t),t=t.sibling}function Za(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:ca(4,t,t.return),Za(t);break;case 1:gn(t,t.return);var a=t.stateNode;typeof a.componentWillUnmount=="function"&&Mm(t,t.return,a),Za(t);break;case 27:Yl(t.stateNode);case 26:case 5:gn(t,t.return),Za(t);break;case 22:t.memoizedState===null&&Za(t);break;case 30:Za(t);break;default:Za(t)}e=e.sibling}}function ua(e,t,a){for(a=a&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var l=t.alternate,o=e,d=t,p=d.flags;switch(d.tag){case 0:case 11:case 15:ua(o,d,a),kl(4,d);break;case 1:if(ua(o,d,a),l=d,o=l.stateNode,typeof o.componentDidMount=="function")try{o.componentDidMount()}catch(O){Te(l,l.return,O)}if(l=d,o=l.updateQueue,o!==null){var y=l.stateNode;try{var b=o.shared.hiddenCallbacks;if(b!==null)for(o.shared.hiddenCallbacks=null,o=0;o<b.length;o++)gh(b[o],y)}catch(O){Te(l,l.return,O)}}a&&p&64&&Dm(d),Bl(d,d.return);break;case 27:km(d);case 26:case 5:ua(o,d,a),a&&l===null&&p&4&&zm(d),Bl(d,d.return);break;case 12:ua(o,d,a);break;case 13:ua(o,d,a),a&&p&4&&Hm(o,d);break;case 22:d.memoizedState===null&&ua(o,d,a),Bl(d,d.return);break;case 30:break;default:ua(o,d,a)}t=t.sibling}}function du(e,t){var a=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==a&&(e!=null&&e.refCount++,a!=null&&bl(a))}function fu(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&bl(e))}function xn(e,t,a,l){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Gm(e,t,a,l),t=t.sibling}function Gm(e,t,a,l){var o=t.flags;switch(t.tag){case 0:case 11:case 15:xn(e,t,a,l),o&2048&&kl(9,t);break;case 1:xn(e,t,a,l);break;case 3:xn(e,t,a,l),o&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&bl(e)));break;case 12:if(o&2048){xn(e,t,a,l),e=t.stateNode;try{var d=t.memoizedProps,p=d.id,y=d.onPostCommit;typeof y=="function"&&y(p,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(b){Te(t,t.return,b)}}else xn(e,t,a,l);break;case 13:xn(e,t,a,l);break;case 23:break;case 22:d=t.stateNode,p=t.alternate,t.memoizedState!==null?d._visibility&2?xn(e,t,a,l):Nl(e,t):d._visibility&2?xn(e,t,a,l):(d._visibility|=2,Mi(e,t,a,l,(t.subtreeFlags&10256)!==0)),o&2048&&du(p,t);break;case 24:xn(e,t,a,l),o&2048&&fu(t.alternate,t);break;default:xn(e,t,a,l)}}function Mi(e,t,a,l,o){for(o=o&&(t.subtreeFlags&10256)!==0,t=t.child;t!==null;){var d=e,p=t,y=a,b=l,O=p.flags;switch(p.tag){case 0:case 11:case 15:Mi(d,p,y,b,o),kl(8,p);break;case 23:break;case 22:var k=p.stateNode;p.memoizedState!==null?k._visibility&2?Mi(d,p,y,b,o):Nl(d,p):(k._visibility|=2,Mi(d,p,y,b,o)),o&&O&2048&&du(p.alternate,p);break;case 24:Mi(d,p,y,b,o),o&&O&2048&&fu(p.alternate,p);break;default:Mi(d,p,y,b,o)}t=t.sibling}}function Nl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var a=e,l=t,o=l.flags;switch(l.tag){case 22:Nl(a,l),o&2048&&du(l.alternate,l);break;case 24:Nl(a,l),o&2048&&fu(l.alternate,l);break;default:Nl(a,l)}t=t.sibling}}var Ul=8192;function zi(e){if(e.subtreeFlags&Ul)for(e=e.child;e!==null;)Vm(e),e=e.sibling}function Vm(e){switch(e.tag){case 26:zi(e),e.flags&Ul&&e.memoizedState!==null&&$v(ln,e.memoizedState,e.memoizedProps);break;case 5:zi(e);break;case 3:case 4:var t=ln;ln=qr(e.stateNode.containerInfo),zi(e),ln=t;break;case 22:e.memoizedState===null&&(t=e.alternate,t!==null&&t.memoizedState!==null?(t=Ul,Ul=16777216,zi(e),Ul=t):zi(e));break;default:zi(e)}}function Ym(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Ll(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var l=t[a];st=l,Qm(l,e)}Ym(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Xm(e),e=e.sibling}function Xm(e){switch(e.tag){case 0:case 11:case 15:Ll(e),e.flags&2048&&ca(9,e,e.return);break;case 3:Ll(e);break;case 12:Ll(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Er(e)):Ll(e);break;default:Ll(e)}}function Er(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var l=t[a];st=l,Qm(l,e)}Ym(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:ca(8,t,t.return),Er(t);break;case 22:a=t.stateNode,a._visibility&2&&(a._visibility&=-3,Er(t));break;default:Er(t)}e=e.sibling}}function Qm(e,t){for(;st!==null;){var a=st;switch(a.tag){case 0:case 11:case 15:ca(8,a,t);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var l=a.memoizedState.cachePool.pool;l!=null&&l.refCount++}break;case 24:bl(a.memoizedState.cache)}if(l=a.child,l!==null)l.return=a,st=l;else e:for(a=e;st!==null;){l=st;var o=l.sibling,d=l.return;if(Um(l),l===a){st=null;break e}if(o!==null){o.return=d,st=o;break e}st=d}}}var av={getCacheForType:function(e){var t=pt(We),a=t.data.get(e);return a===void 0&&(a=e(),t.data.set(e,a)),a}},iv=typeof WeakMap=="function"?WeakMap:Map,ve=0,Ae=null,se=null,ue=0,be=0,Lt=null,da=!1,Ri=!1,hu=!1,$n=0,$e=0,fa=0,Ka=0,mu=0,Jt=0,ki=0,Hl=null,Tt=null,pu=!1,gu=0,Or=1/0,Dr=null,ha=null,dt=0,ma=null,Bi=null,Ni=0,xu=0,yu=null,Zm=null,ql=0,vu=null;function Ht(){if((ve&2)!==0&&ue!==0)return ue&-ue;if(U.T!==null){var e=wi;return e!==0?e:Au()}return of()}function Km(){Jt===0&&(Jt=(ue&536870912)===0||ge?lf():536870912);var e=Ft.current;return e!==null&&(e.flags|=32),Jt}function qt(e,t,a){(e===Ae&&(be===2||be===9)||e.cancelPendingCommit!==null)&&(Ui(e,0),pa(e,ue,Jt,!1)),il(e,a),((ve&2)===0||e!==Ae)&&(e===Ae&&((ve&2)===0&&(Ka|=a),$e===4&&pa(e,ue,Jt,!1)),yn(e))}function Fm(e,t,a){if((ve&6)!==0)throw Error(c(327));var l=!a&&(t&124)===0&&(t&e.expiredLanes)===0||al(e,t),o=l?rv(e,t):Su(e,t,!0),d=l;do{if(o===0){Ri&&!l&&pa(e,t,0,!1);break}else{if(a=e.current.alternate,d&&!lv(a)){o=Su(e,t,!1),d=!1;continue}if(o===2){if(d=t,e.errorRecoveryDisabledLanes&d)var p=0;else p=e.pendingLanes&-536870913,p=p!==0?p:p&536870912?536870912:0;if(p!==0){t=p;e:{var y=e;o=Hl;var b=y.current.memoizedState.isDehydrated;if(b&&(Ui(y,p).flags|=256),p=Su(y,p,!1),p!==2){if(hu&&!b){y.errorRecoveryDisabledLanes|=d,Ka|=d,o=4;break e}d=Tt,Tt=o,d!==null&&(Tt===null?Tt=d:Tt.push.apply(Tt,d))}o=p}if(d=!1,o!==2)continue}}if(o===1){Ui(e,0),pa(e,t,0,!0);break}e:{switch(l=e,d=o,d){case 0:case 1:throw Error(c(345));case 4:if((t&4194048)!==t)break;case 6:pa(l,t,Jt,!da);break e;case 2:Tt=null;break;case 3:case 5:break;default:throw Error(c(329))}if((t&62914560)===t&&(o=gu+300-hn(),10<o)){if(pa(l,t,Jt,!da),$s(l,0,!0)!==0)break e;l.timeoutHandle=_p(Jm.bind(null,l,a,Tt,Dr,pu,t,Jt,Ka,ki,da,d,2,-0,0),o);break e}Jm(l,a,Tt,Dr,pu,t,Jt,Ka,ki,da,d,0,-0,0)}}break}while(!0);yn(e)}function Jm(e,t,a,l,o,d,p,y,b,O,k,L,D,M){if(e.timeoutHandle=-1,L=t.subtreeFlags,(L&8192||(L&16785408)===16785408)&&(Zl={stylesheets:null,count:0,unsuspend:qv},Vm(t),L=Gv(),L!==null)){e.cancelPendingCommit=L(ap.bind(null,e,t,d,a,l,o,p,y,b,k,1,D,M)),pa(e,d,p,!O);return}ap(e,t,d,a,l,o,p,y,b)}function lv(e){for(var t=e;;){var a=t.tag;if((a===0||a===11||a===15)&&t.flags&16384&&(a=t.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var l=0;l<a.length;l++){var o=a[l],d=o.getSnapshot;o=o.value;try{if(!kt(d(),o))return!1}catch{return!1}}if(a=t.child,t.subtreeFlags&16384&&a!==null)a.return=t,t=a;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function pa(e,t,a,l){t&=~mu,t&=~Ka,e.suspendedLanes|=t,e.pingedLanes&=~t,l&&(e.warmLanes|=t),l=e.expirationTimes;for(var o=t;0<o;){var d=31-Rt(o),p=1<<d;l[d]=-1,o&=~p}a!==0&&rf(e,a,t)}function Mr(){return(ve&6)===0?($l(0),!1):!0}function bu(){if(se!==null){if(be===0)var e=se.return;else e=se,Rn=Ga=null,Uo(e),Oi=null,Ml=0,e=se;for(;e!==null;)Om(e.alternate,e),e=e.return;se=null}}function Ui(e,t){var a=e.timeoutHandle;a!==-1&&(e.timeoutHandle=-1,wv(a)),a=e.cancelPendingCommit,a!==null&&(e.cancelPendingCommit=null,a()),bu(),Ae=e,se=a=Dn(e.current,null),ue=t,be=0,Lt=null,da=!1,Ri=al(e,t),hu=!1,ki=Jt=mu=Ka=fa=$e=0,Tt=Hl=null,pu=!1,(t&8)!==0&&(t|=t&32);var l=e.entangledLanes;if(l!==0)for(e=e.entanglements,l&=t;0<l;){var o=31-Rt(l),d=1<<o;t|=e[o],l&=~d}return $n=t,Is(),a}function Wm(e,t){ie=null,U.H=yr,t===Sl||t===cr?(t=mh(),be=3):t===dh?(t=mh(),be=4):be=t===pm?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,Lt=t,se===null&&($e=1,wr(e,Xt(t,e.current)))}function Pm(){var e=U.H;return U.H=yr,e===null?yr:e}function Im(){var e=U.A;return U.A=av,e}function ju(){$e=4,da||(ue&4194048)!==ue&&Ft.current!==null||(Ri=!0),(fa&134217727)===0&&(Ka&134217727)===0||Ae===null||pa(Ae,ue,Jt,!1)}function Su(e,t,a){var l=ve;ve|=2;var o=Pm(),d=Im();(Ae!==e||ue!==t)&&(Dr=null,Ui(e,t)),t=!1;var p=$e;e:do try{if(be!==0&&se!==null){var y=se,b=Lt;switch(be){case 8:bu(),p=6;break e;case 3:case 2:case 9:case 6:Ft.current===null&&(t=!0);var O=be;if(be=0,Lt=null,Li(e,y,b,O),a&&Ri){p=0;break e}break;default:O=be,be=0,Lt=null,Li(e,y,b,O)}}sv(),p=$e;break}catch(k){Wm(e,k)}while(!0);return t&&e.shellSuspendCounter++,Rn=Ga=null,ve=l,U.H=o,U.A=d,se===null&&(Ae=null,ue=0,Is()),p}function sv(){for(;se!==null;)ep(se)}function rv(e,t){var a=ve;ve|=2;var l=Pm(),o=Im();Ae!==e||ue!==t?(Dr=null,Or=hn()+500,Ui(e,t)):Ri=al(e,t);e:do try{if(be!==0&&se!==null){t=se;var d=Lt;t:switch(be){case 1:be=0,Lt=null,Li(e,t,d,1);break;case 2:case 9:if(fh(d)){be=0,Lt=null,tp(t);break}t=function(){be!==2&&be!==9||Ae!==e||(be=7),yn(e)},d.then(t,t);break e;case 3:be=7;break e;case 4:be=5;break e;case 7:fh(d)?(be=0,Lt=null,tp(t)):(be=0,Lt=null,Li(e,t,d,7));break;case 5:var p=null;switch(se.tag){case 26:p=se.memoizedState;case 5:case 27:var y=se;if(!p||Np(p)){be=0,Lt=null;var b=y.sibling;if(b!==null)se=b;else{var O=y.return;O!==null?(se=O,zr(O)):se=null}break t}}be=0,Lt=null,Li(e,t,d,5);break;case 6:be=0,Lt=null,Li(e,t,d,6);break;case 8:bu(),$e=6;break e;default:throw Error(c(462))}}cv();break}catch(k){Wm(e,k)}while(!0);return Rn=Ga=null,U.H=l,U.A=o,ve=a,se!==null?0:(Ae=null,ue=0,Is(),$e)}function cv(){for(;se!==null&&!D0();)ep(se)}function ep(e){var t=Cm(e.alternate,e,$n);e.memoizedProps=e.pendingProps,t===null?zr(e):se=t}function tp(e){var t=e,a=t.alternate;switch(t.tag){case 15:case 0:t=jm(a,t,t.pendingProps,t.type,void 0,ue);break;case 11:t=jm(a,t,t.pendingProps,t.type.render,t.ref,ue);break;case 5:Uo(t);default:Om(a,t),t=se=nh(t,$n),t=Cm(a,t,$n)}e.memoizedProps=e.pendingProps,t===null?zr(e):se=t}function Li(e,t,a,l){Rn=Ga=null,Uo(t),Oi=null,Ml=0;var o=t.return;try{if(Wy(e,o,t,a,ue)){$e=1,wr(e,Xt(a,e.current)),se=null;return}}catch(d){if(o!==null)throw se=o,d;$e=1,wr(e,Xt(a,e.current)),se=null;return}t.flags&32768?(ge||l===1?e=!0:Ri||(ue&536870912)!==0?e=!1:(da=e=!0,(l===2||l===9||l===3||l===6)&&(l=Ft.current,l!==null&&l.tag===13&&(l.flags|=16384))),np(t,e)):zr(t)}function zr(e){var t=e;do{if((t.flags&32768)!==0){np(t,da);return}e=t.return;var a=Iy(t.alternate,t,$n);if(a!==null){se=a;return}if(t=t.sibling,t!==null){se=t;return}se=t=e}while(t!==null);$e===0&&($e=5)}function np(e,t){do{var a=ev(e.alternate,e);if(a!==null){a.flags&=32767,se=a;return}if(a=e.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!t&&(e=e.sibling,e!==null)){se=e;return}se=e=a}while(e!==null);$e=6,se=null}function ap(e,t,a,l,o,d,p,y,b){e.cancelPendingCommit=null;do Rr();while(dt!==0);if((ve&6)!==0)throw Error(c(327));if(t!==null){if(t===e.current)throw Error(c(177));if(d=t.lanes|t.childLanes,d|=fo,q0(e,a,d,p,y,b),e===Ae&&(se=Ae=null,ue=0),Bi=t,ma=e,Ni=a,xu=d,yu=o,Zm=l,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,fv(Ls,function(){return cp(),null})):(e.callbackNode=null,e.callbackPriority=0),l=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||l){l=U.T,U.T=null,o=Y.p,Y.p=2,p=ve,ve|=4;try{tv(e,t,a)}finally{ve=p,Y.p=o,U.T=l}}dt=1,ip(),lp(),sp()}}function ip(){if(dt===1){dt=0;var e=ma,t=Bi,a=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||a){a=U.T,U.T=null;var l=Y.p;Y.p=2;var o=ve;ve|=4;try{qm(t,e);var d=ku,p=Qf(e.containerInfo),y=d.focusedElem,b=d.selectionRange;if(p!==y&&y&&y.ownerDocument&&Xf(y.ownerDocument.documentElement,y)){if(b!==null&&so(y)){var O=b.start,k=b.end;if(k===void 0&&(k=O),"selectionStart"in y)y.selectionStart=O,y.selectionEnd=Math.min(k,y.value.length);else{var L=y.ownerDocument||document,D=L&&L.defaultView||window;if(D.getSelection){var M=D.getSelection(),I=y.textContent.length,W=Math.min(b.start,I),_e=b.end===void 0?W:Math.min(b.end,I);!M.extend&&W>_e&&(p=_e,_e=W,W=p);var T=Yf(y,W),_=Yf(y,_e);if(T&&_&&(M.rangeCount!==1||M.anchorNode!==T.node||M.anchorOffset!==T.offset||M.focusNode!==_.node||M.focusOffset!==_.offset)){var C=L.createRange();C.setStart(T.node,T.offset),M.removeAllRanges(),W>_e?(M.addRange(C),M.extend(_.node,_.offset)):(C.setEnd(_.node,_.offset),M.addRange(C))}}}}for(L=[],M=y;M=M.parentNode;)M.nodeType===1&&L.push({element:M,left:M.scrollLeft,top:M.scrollTop});for(typeof y.focus=="function"&&y.focus(),y=0;y<L.length;y++){var N=L[y];N.element.scrollLeft=N.left,N.element.scrollTop=N.top}}Xr=!!Ru,ku=Ru=null}finally{ve=o,Y.p=l,U.T=a}}e.current=t,dt=2}}function lp(){if(dt===2){dt=0;var e=ma,t=Bi,a=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||a){a=U.T,U.T=null;var l=Y.p;Y.p=2;var o=ve;ve|=4;try{Nm(e,t.alternate,t)}finally{ve=o,Y.p=l,U.T=a}}dt=3}}function sp(){if(dt===4||dt===3){dt=0,M0();var e=ma,t=Bi,a=Ni,l=Zm;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?dt=5:(dt=0,Bi=ma=null,rp(e,e.pendingLanes));var o=e.pendingLanes;if(o===0&&(ha=null),Hc(a),t=t.stateNode,zt&&typeof zt.onCommitFiberRoot=="function")try{zt.onCommitFiberRoot(nl,t,void 0,(t.current.flags&128)===128)}catch{}if(l!==null){t=U.T,o=Y.p,Y.p=2,U.T=null;try{for(var d=e.onRecoverableError,p=0;p<l.length;p++){var y=l[p];d(y.value,{componentStack:y.stack})}}finally{U.T=t,Y.p=o}}(Ni&3)!==0&&Rr(),yn(e),o=e.pendingLanes,(a&4194090)!==0&&(o&42)!==0?e===vu?ql++:(ql=0,vu=e):ql=0,$l(0)}}function rp(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,bl(t)))}function Rr(e){return ip(),lp(),sp(),cp()}function cp(){if(dt!==5)return!1;var e=ma,t=xu;xu=0;var a=Hc(Ni),l=U.T,o=Y.p;try{Y.p=32>a?32:a,U.T=null,a=yu,yu=null;var d=ma,p=Ni;if(dt=0,Bi=ma=null,Ni=0,(ve&6)!==0)throw Error(c(331));var y=ve;if(ve|=4,Xm(d.current),Gm(d,d.current,p,a),ve=y,$l(0,!1),zt&&typeof zt.onPostCommitFiberRoot=="function")try{zt.onPostCommitFiberRoot(nl,d)}catch{}return!0}finally{Y.p=o,U.T=l,rp(e,t)}}function op(e,t,a){t=Xt(a,t),t=Wo(e.stateNode,t,2),e=ia(e,t,2),e!==null&&(il(e,2),yn(e))}function Te(e,t,a){if(e.tag===3)op(e,e,a);else for(;t!==null;){if(t.tag===3){op(t,e,a);break}else if(t.tag===1){var l=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof l.componentDidCatch=="function"&&(ha===null||!ha.has(l))){e=Xt(a,e),a=hm(2),l=ia(t,a,2),l!==null&&(mm(a,l,t,e),il(l,2),yn(l));break}}t=t.return}}function wu(e,t,a){var l=e.pingCache;if(l===null){l=e.pingCache=new iv;var o=new Set;l.set(t,o)}else o=l.get(t),o===void 0&&(o=new Set,l.set(t,o));o.has(a)||(hu=!0,o.add(a),e=ov.bind(null,e,t,a),t.then(e,e))}function ov(e,t,a){var l=e.pingCache;l!==null&&l.delete(t),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,Ae===e&&(ue&a)===a&&($e===4||$e===3&&(ue&62914560)===ue&&300>hn()-gu?(ve&2)===0&&Ui(e,0):mu|=a,ki===ue&&(ki=0)),yn(e)}function up(e,t){t===0&&(t=sf()),e=vi(e,t),e!==null&&(il(e,t),yn(e))}function uv(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),up(e,a)}function dv(e,t){var a=0;switch(e.tag){case 13:var l=e.stateNode,o=e.memoizedState;o!==null&&(a=o.retryLane);break;case 19:l=e.stateNode;break;case 22:l=e.stateNode._retryCache;break;default:throw Error(c(314))}l!==null&&l.delete(t),up(e,a)}function fv(e,t){return Bc(e,t)}var kr=null,Hi=null,_u=!1,Br=!1,Tu=!1,Fa=0;function yn(e){e!==Hi&&e.next===null&&(Hi===null?kr=Hi=e:Hi=Hi.next=e),Br=!0,_u||(_u=!0,mv())}function $l(e,t){if(!Tu&&Br){Tu=!0;do for(var a=!1,l=kr;l!==null;){if(e!==0){var o=l.pendingLanes;if(o===0)var d=0;else{var p=l.suspendedLanes,y=l.pingedLanes;d=(1<<31-Rt(42|e)+1)-1,d&=o&~(p&~y),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(a=!0,mp(l,d))}else d=ue,d=$s(l,l===Ae?d:0,l.cancelPendingCommit!==null||l.timeoutHandle!==-1),(d&3)===0||al(l,d)||(a=!0,mp(l,d));l=l.next}while(a);Tu=!1}}function hv(){dp()}function dp(){Br=_u=!1;var e=0;Fa!==0&&(Sv()&&(e=Fa),Fa=0);for(var t=hn(),a=null,l=kr;l!==null;){var o=l.next,d=fp(l,t);d===0?(l.next=null,a===null?kr=o:a.next=o,o===null&&(Hi=a)):(a=l,(e!==0||(d&3)!==0)&&(Br=!0)),l=o}$l(e)}function fp(e,t){for(var a=e.suspendedLanes,l=e.pingedLanes,o=e.expirationTimes,d=e.pendingLanes&-62914561;0<d;){var p=31-Rt(d),y=1<<p,b=o[p];b===-1?((y&a)===0||(y&l)!==0)&&(o[p]=H0(y,t)):b<=t&&(e.expiredLanes|=y),d&=~y}if(t=Ae,a=ue,a=$s(e,e===t?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),l=e.callbackNode,a===0||e===t&&(be===2||be===9)||e.cancelPendingCommit!==null)return l!==null&&l!==null&&Nc(l),e.callbackNode=null,e.callbackPriority=0;if((a&3)===0||al(e,a)){if(t=a&-a,t===e.callbackPriority)return t;switch(l!==null&&Nc(l),Hc(a)){case 2:case 8:a=nf;break;case 32:a=Ls;break;case 268435456:a=af;break;default:a=Ls}return l=hp.bind(null,e),a=Bc(a,l),e.callbackPriority=t,e.callbackNode=a,t}return l!==null&&l!==null&&Nc(l),e.callbackPriority=2,e.callbackNode=null,2}function hp(e,t){if(dt!==0&&dt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var a=e.callbackNode;if(Rr()&&e.callbackNode!==a)return null;var l=ue;return l=$s(e,e===Ae?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),l===0?null:(Fm(e,l,t),fp(e,hn()),e.callbackNode!=null&&e.callbackNode===a?hp.bind(null,e):null)}function mp(e,t){if(Rr())return null;Fm(e,t,!0)}function mv(){_v(function(){(ve&6)!==0?Bc(tf,hv):dp()})}function Au(){return Fa===0&&(Fa=lf()),Fa}function pp(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Qs(""+e)}function gp(e,t){var a=t.ownerDocument.createElement("input");return a.name=t.name,a.value=t.value,e.id&&a.setAttribute("form",e.id),t.parentNode.insertBefore(a,t),e=new FormData(e),a.parentNode.removeChild(a),e}function pv(e,t,a,l,o){if(t==="submit"&&a&&a.stateNode===o){var d=pp((o[jt]||null).action),p=l.submitter;p&&(t=(t=p[jt]||null)?pp(t.formAction):p.getAttribute("formAction"),t!==null&&(d=t,p=null));var y=new Js("action","action",null,l,o);e.push({event:y,listeners:[{instance:null,listener:function(){if(l.defaultPrevented){if(Fa!==0){var b=p?gp(o,p):new FormData(o);Qo(a,{pending:!0,data:b,method:o.method,action:d},null,b)}}else typeof d=="function"&&(y.preventDefault(),b=p?gp(o,p):new FormData(o),Qo(a,{pending:!0,data:b,method:o.method,action:d},d,b))},currentTarget:o}]})}}for(var Cu=0;Cu<uo.length;Cu++){var Eu=uo[Cu],gv=Eu.toLowerCase(),xv=Eu[0].toUpperCase()+Eu.slice(1);an(gv,"on"+xv)}an(Ff,"onAnimationEnd"),an(Jf,"onAnimationIteration"),an(Wf,"onAnimationStart"),an("dblclick","onDoubleClick"),an("focusin","onFocus"),an("focusout","onBlur"),an(ky,"onTransitionRun"),an(By,"onTransitionStart"),an(Ny,"onTransitionCancel"),an(Pf,"onTransitionEnd"),oi("onMouseEnter",["mouseout","mouseover"]),oi("onMouseLeave",["mouseout","mouseover"]),oi("onPointerEnter",["pointerout","pointerover"]),oi("onPointerLeave",["pointerout","pointerover"]),Ra("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ra("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ra("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ra("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ra("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ra("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Gl="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),yv=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Gl));function xp(e,t){t=(t&4)!==0;for(var a=0;a<e.length;a++){var l=e[a],o=l.event;l=l.listeners;e:{var d=void 0;if(t)for(var p=l.length-1;0<=p;p--){var y=l[p],b=y.instance,O=y.currentTarget;if(y=y.listener,b!==d&&o.isPropagationStopped())break e;d=y,o.currentTarget=O;try{d(o)}catch(k){Sr(k)}o.currentTarget=null,d=b}else for(p=0;p<l.length;p++){if(y=l[p],b=y.instance,O=y.currentTarget,y=y.listener,b!==d&&o.isPropagationStopped())break e;d=y,o.currentTarget=O;try{d(o)}catch(k){Sr(k)}o.currentTarget=null,d=b}}}}function re(e,t){var a=t[qc];a===void 0&&(a=t[qc]=new Set);var l=e+"__bubble";a.has(l)||(yp(t,e,2,!1),a.add(l))}function Ou(e,t,a){var l=0;t&&(l|=4),yp(a,e,l,t)}var Nr="_reactListening"+Math.random().toString(36).slice(2);function Du(e){if(!e[Nr]){e[Nr]=!0,df.forEach(function(a){a!=="selectionchange"&&(yv.has(a)||Ou(a,!1,e),Ou(a,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Nr]||(t[Nr]=!0,Ou("selectionchange",!1,t))}}function yp(e,t,a,l){switch(Gp(t)){case 2:var o=Xv;break;case 8:o=Qv;break;default:o=Yu}a=o.bind(null,t,a,e),o=void 0,!Wc||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),l?o!==void 0?e.addEventListener(t,a,{capture:!0,passive:o}):e.addEventListener(t,a,!0):o!==void 0?e.addEventListener(t,a,{passive:o}):e.addEventListener(t,a,!1)}function Mu(e,t,a,l,o){var d=l;if((t&1)===0&&(t&2)===0&&l!==null)e:for(;;){if(l===null)return;var p=l.tag;if(p===3||p===4){var y=l.stateNode.containerInfo;if(y===o)break;if(p===4)for(p=l.return;p!==null;){var b=p.tag;if((b===3||b===4)&&p.stateNode.containerInfo===o)return;p=p.return}for(;y!==null;){if(p=si(y),p===null)return;if(b=p.tag,b===5||b===6||b===26||b===27){l=d=p;continue e}y=y.parentNode}}l=l.return}Tf(function(){var O=d,k=Fc(a),L=[];e:{var D=If.get(e);if(D!==void 0){var M=Js,I=e;switch(e){case"keypress":if(Ks(a)===0)break e;case"keydown":case"keyup":M=fy;break;case"focusin":I="focus",M=to;break;case"focusout":I="blur",M=to;break;case"beforeblur":case"afterblur":M=to;break;case"click":if(a.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":M=Ef;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":M=ey;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":M=py;break;case Ff:case Jf:case Wf:M=ay;break;case Pf:M=xy;break;case"scroll":case"scrollend":M=P0;break;case"wheel":M=vy;break;case"copy":case"cut":case"paste":M=ly;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":M=Df;break;case"toggle":case"beforetoggle":M=jy}var W=(t&4)!==0,_e=!W&&(e==="scroll"||e==="scrollend"),T=W?D!==null?D+"Capture":null:D;W=[];for(var _=O,C;_!==null;){var N=_;if(C=N.stateNode,N=N.tag,N!==5&&N!==26&&N!==27||C===null||T===null||(N=rl(_,T),N!=null&&W.push(Vl(_,N,C))),_e)break;_=_.return}0<W.length&&(D=new M(D,I,null,a,k),L.push({event:D,listeners:W}))}}if((t&7)===0){e:{if(D=e==="mouseover"||e==="pointerover",M=e==="mouseout"||e==="pointerout",D&&a!==Kc&&(I=a.relatedTarget||a.fromElement)&&(si(I)||I[li]))break e;if((M||D)&&(D=k.window===k?k:(D=k.ownerDocument)?D.defaultView||D.parentWindow:window,M?(I=a.relatedTarget||a.toElement,M=O,I=I?si(I):null,I!==null&&(_e=f(I),W=I.tag,I!==_e||W!==5&&W!==27&&W!==6)&&(I=null)):(M=null,I=O),M!==I)){if(W=Ef,N="onMouseLeave",T="onMouseEnter",_="mouse",(e==="pointerout"||e==="pointerover")&&(W=Df,N="onPointerLeave",T="onPointerEnter",_="pointer"),_e=M==null?D:sl(M),C=I==null?D:sl(I),D=new W(N,_+"leave",M,a,k),D.target=_e,D.relatedTarget=C,N=null,si(k)===O&&(W=new W(T,_+"enter",I,a,k),W.target=C,W.relatedTarget=_e,N=W),_e=N,M&&I)t:{for(W=M,T=I,_=0,C=W;C;C=qi(C))_++;for(C=0,N=T;N;N=qi(N))C++;for(;0<_-C;)W=qi(W),_--;for(;0<C-_;)T=qi(T),C--;for(;_--;){if(W===T||T!==null&&W===T.alternate)break t;W=qi(W),T=qi(T)}W=null}else W=null;M!==null&&vp(L,D,M,W,!1),I!==null&&_e!==null&&vp(L,_e,I,W,!0)}}e:{if(D=O?sl(O):window,M=D.nodeName&&D.nodeName.toLowerCase(),M==="select"||M==="input"&&D.type==="file")var Q=Lf;else if(Nf(D))if(Hf)Q=My;else{Q=Oy;var le=Ey}else M=D.nodeName,!M||M.toLowerCase()!=="input"||D.type!=="checkbox"&&D.type!=="radio"?O&&Zc(O.elementType)&&(Q=Lf):Q=Dy;if(Q&&(Q=Q(e,O))){Uf(L,Q,a,k);break e}le&&le(e,D,O),e==="focusout"&&O&&D.type==="number"&&O.memoizedProps.value!=null&&Qc(D,"number",D.value)}switch(le=O?sl(O):window,e){case"focusin":(Nf(le)||le.contentEditable==="true")&&(gi=le,ro=O,pl=null);break;case"focusout":pl=ro=gi=null;break;case"mousedown":co=!0;break;case"contextmenu":case"mouseup":case"dragend":co=!1,Zf(L,a,k);break;case"selectionchange":if(Ry)break;case"keydown":case"keyup":Zf(L,a,k)}var F;if(ao)e:{switch(e){case"compositionstart":var P="onCompositionStart";break e;case"compositionend":P="onCompositionEnd";break e;case"compositionupdate":P="onCompositionUpdate";break e}P=void 0}else pi?kf(e,a)&&(P="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(P="onCompositionStart");P&&(Mf&&a.locale!=="ko"&&(pi||P!=="onCompositionStart"?P==="onCompositionEnd"&&pi&&(F=Af()):(ea=k,Pc="value"in ea?ea.value:ea.textContent,pi=!0)),le=Ur(O,P),0<le.length&&(P=new Of(P,e,null,a,k),L.push({event:P,listeners:le}),F?P.data=F:(F=Bf(a),F!==null&&(P.data=F)))),(F=wy?_y(e,a):Ty(e,a))&&(P=Ur(O,"onBeforeInput"),0<P.length&&(le=new Of("onBeforeInput","beforeinput",null,a,k),L.push({event:le,listeners:P}),le.data=F)),pv(L,e,O,a,k)}xp(L,t)})}function Vl(e,t,a){return{instance:e,listener:t,currentTarget:a}}function Ur(e,t){for(var a=t+"Capture",l=[];e!==null;){var o=e,d=o.stateNode;if(o=o.tag,o!==5&&o!==26&&o!==27||d===null||(o=rl(e,a),o!=null&&l.unshift(Vl(e,o,d)),o=rl(e,t),o!=null&&l.push(Vl(e,o,d))),e.tag===3)return l;e=e.return}return[]}function qi(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function vp(e,t,a,l,o){for(var d=t._reactName,p=[];a!==null&&a!==l;){var y=a,b=y.alternate,O=y.stateNode;if(y=y.tag,b!==null&&b===l)break;y!==5&&y!==26&&y!==27||O===null||(b=O,o?(O=rl(a,d),O!=null&&p.unshift(Vl(a,O,b))):o||(O=rl(a,d),O!=null&&p.push(Vl(a,O,b)))),a=a.return}p.length!==0&&e.push({event:t,listeners:p})}var vv=/\r\n?/g,bv=/\u0000|\uFFFD/g;function bp(e){return(typeof e=="string"?e:""+e).replace(vv,`
`).replace(bv,"")}function jp(e,t){return t=bp(t),bp(e)===t}function Lr(){}function we(e,t,a,l,o,d){switch(a){case"children":typeof l=="string"?t==="body"||t==="textarea"&&l===""||fi(e,l):(typeof l=="number"||typeof l=="bigint")&&t!=="body"&&fi(e,""+l);break;case"className":Vs(e,"class",l);break;case"tabIndex":Vs(e,"tabindex",l);break;case"dir":case"role":case"viewBox":case"width":case"height":Vs(e,a,l);break;case"style":wf(e,l,d);break;case"data":if(t!=="object"){Vs(e,"data",l);break}case"src":case"href":if(l===""&&(t!=="a"||a!=="href")){e.removeAttribute(a);break}if(l==null||typeof l=="function"||typeof l=="symbol"||typeof l=="boolean"){e.removeAttribute(a);break}l=Qs(""+l),e.setAttribute(a,l);break;case"action":case"formAction":if(typeof l=="function"){e.setAttribute(a,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof d=="function"&&(a==="formAction"?(t!=="input"&&we(e,t,"name",o.name,o,null),we(e,t,"formEncType",o.formEncType,o,null),we(e,t,"formMethod",o.formMethod,o,null),we(e,t,"formTarget",o.formTarget,o,null)):(we(e,t,"encType",o.encType,o,null),we(e,t,"method",o.method,o,null),we(e,t,"target",o.target,o,null)));if(l==null||typeof l=="symbol"||typeof l=="boolean"){e.removeAttribute(a);break}l=Qs(""+l),e.setAttribute(a,l);break;case"onClick":l!=null&&(e.onclick=Lr);break;case"onScroll":l!=null&&re("scroll",e);break;case"onScrollEnd":l!=null&&re("scrollend",e);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!="object"||!("__html"in l))throw Error(c(61));if(a=l.__html,a!=null){if(o.children!=null)throw Error(c(60));e.innerHTML=a}}break;case"multiple":e.multiple=l&&typeof l!="function"&&typeof l!="symbol";break;case"muted":e.muted=l&&typeof l!="function"&&typeof l!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(l==null||typeof l=="function"||typeof l=="boolean"||typeof l=="symbol"){e.removeAttribute("xlink:href");break}a=Qs(""+l),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":l!=null&&typeof l!="function"&&typeof l!="symbol"?e.setAttribute(a,""+l):e.removeAttribute(a);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":l&&typeof l!="function"&&typeof l!="symbol"?e.setAttribute(a,""):e.removeAttribute(a);break;case"capture":case"download":l===!0?e.setAttribute(a,""):l!==!1&&l!=null&&typeof l!="function"&&typeof l!="symbol"?e.setAttribute(a,l):e.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":l!=null&&typeof l!="function"&&typeof l!="symbol"&&!isNaN(l)&&1<=l?e.setAttribute(a,l):e.removeAttribute(a);break;case"rowSpan":case"start":l==null||typeof l=="function"||typeof l=="symbol"||isNaN(l)?e.removeAttribute(a):e.setAttribute(a,l);break;case"popover":re("beforetoggle",e),re("toggle",e),Gs(e,"popover",l);break;case"xlinkActuate":En(e,"http://www.w3.org/1999/xlink","xlink:actuate",l);break;case"xlinkArcrole":En(e,"http://www.w3.org/1999/xlink","xlink:arcrole",l);break;case"xlinkRole":En(e,"http://www.w3.org/1999/xlink","xlink:role",l);break;case"xlinkShow":En(e,"http://www.w3.org/1999/xlink","xlink:show",l);break;case"xlinkTitle":En(e,"http://www.w3.org/1999/xlink","xlink:title",l);break;case"xlinkType":En(e,"http://www.w3.org/1999/xlink","xlink:type",l);break;case"xmlBase":En(e,"http://www.w3.org/XML/1998/namespace","xml:base",l);break;case"xmlLang":En(e,"http://www.w3.org/XML/1998/namespace","xml:lang",l);break;case"xmlSpace":En(e,"http://www.w3.org/XML/1998/namespace","xml:space",l);break;case"is":Gs(e,"is",l);break;case"innerText":case"textContent":break;default:(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=J0.get(a)||a,Gs(e,a,l))}}function zu(e,t,a,l,o,d){switch(a){case"style":wf(e,l,d);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!="object"||!("__html"in l))throw Error(c(61));if(a=l.__html,a!=null){if(o.children!=null)throw Error(c(60));e.innerHTML=a}}break;case"children":typeof l=="string"?fi(e,l):(typeof l=="number"||typeof l=="bigint")&&fi(e,""+l);break;case"onScroll":l!=null&&re("scroll",e);break;case"onScrollEnd":l!=null&&re("scrollend",e);break;case"onClick":l!=null&&(e.onclick=Lr);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!ff.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(o=a.endsWith("Capture"),t=a.slice(2,o?a.length-7:void 0),d=e[jt]||null,d=d!=null?d[a]:null,typeof d=="function"&&e.removeEventListener(t,d,o),typeof l=="function")){typeof d!="function"&&d!==null&&(a in e?e[a]=null:e.hasAttribute(a)&&e.removeAttribute(a)),e.addEventListener(t,l,o);break e}a in e?e[a]=l:l===!0?e.setAttribute(a,""):Gs(e,a,l)}}}function ft(e,t,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":re("error",e),re("load",e);var l=!1,o=!1,d;for(d in a)if(a.hasOwnProperty(d)){var p=a[d];if(p!=null)switch(d){case"src":l=!0;break;case"srcSet":o=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(c(137,t));default:we(e,t,d,p,a,null)}}o&&we(e,t,"srcSet",a.srcSet,a,null),l&&we(e,t,"src",a.src,a,null);return;case"input":re("invalid",e);var y=d=p=o=null,b=null,O=null;for(l in a)if(a.hasOwnProperty(l)){var k=a[l];if(k!=null)switch(l){case"name":o=k;break;case"type":p=k;break;case"checked":b=k;break;case"defaultChecked":O=k;break;case"value":d=k;break;case"defaultValue":y=k;break;case"children":case"dangerouslySetInnerHTML":if(k!=null)throw Error(c(137,t));break;default:we(e,t,l,k,a,null)}}vf(e,d,y,b,O,p,o,!1),Ys(e);return;case"select":re("invalid",e),l=p=d=null;for(o in a)if(a.hasOwnProperty(o)&&(y=a[o],y!=null))switch(o){case"value":d=y;break;case"defaultValue":p=y;break;case"multiple":l=y;default:we(e,t,o,y,a,null)}t=d,a=p,e.multiple=!!l,t!=null?di(e,!!l,t,!1):a!=null&&di(e,!!l,a,!0);return;case"textarea":re("invalid",e),d=o=l=null;for(p in a)if(a.hasOwnProperty(p)&&(y=a[p],y!=null))switch(p){case"value":l=y;break;case"defaultValue":o=y;break;case"children":d=y;break;case"dangerouslySetInnerHTML":if(y!=null)throw Error(c(91));break;default:we(e,t,p,y,a,null)}jf(e,l,o,d),Ys(e);return;case"option":for(b in a)if(a.hasOwnProperty(b)&&(l=a[b],l!=null))switch(b){case"selected":e.selected=l&&typeof l!="function"&&typeof l!="symbol";break;default:we(e,t,b,l,a,null)}return;case"dialog":re("beforetoggle",e),re("toggle",e),re("cancel",e),re("close",e);break;case"iframe":case"object":re("load",e);break;case"video":case"audio":for(l=0;l<Gl.length;l++)re(Gl[l],e);break;case"image":re("error",e),re("load",e);break;case"details":re("toggle",e);break;case"embed":case"source":case"link":re("error",e),re("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(O in a)if(a.hasOwnProperty(O)&&(l=a[O],l!=null))switch(O){case"children":case"dangerouslySetInnerHTML":throw Error(c(137,t));default:we(e,t,O,l,a,null)}return;default:if(Zc(t)){for(k in a)a.hasOwnProperty(k)&&(l=a[k],l!==void 0&&zu(e,t,k,l,a,void 0));return}}for(y in a)a.hasOwnProperty(y)&&(l=a[y],l!=null&&we(e,t,y,l,a,null))}function jv(e,t,a,l){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var o=null,d=null,p=null,y=null,b=null,O=null,k=null;for(M in a){var L=a[M];if(a.hasOwnProperty(M)&&L!=null)switch(M){case"checked":break;case"value":break;case"defaultValue":b=L;default:l.hasOwnProperty(M)||we(e,t,M,null,l,L)}}for(var D in l){var M=l[D];if(L=a[D],l.hasOwnProperty(D)&&(M!=null||L!=null))switch(D){case"type":d=M;break;case"name":o=M;break;case"checked":O=M;break;case"defaultChecked":k=M;break;case"value":p=M;break;case"defaultValue":y=M;break;case"children":case"dangerouslySetInnerHTML":if(M!=null)throw Error(c(137,t));break;default:M!==L&&we(e,t,D,M,l,L)}}Xc(e,p,y,b,O,k,d,o);return;case"select":M=p=y=D=null;for(d in a)if(b=a[d],a.hasOwnProperty(d)&&b!=null)switch(d){case"value":break;case"multiple":M=b;default:l.hasOwnProperty(d)||we(e,t,d,null,l,b)}for(o in l)if(d=l[o],b=a[o],l.hasOwnProperty(o)&&(d!=null||b!=null))switch(o){case"value":D=d;break;case"defaultValue":y=d;break;case"multiple":p=d;default:d!==b&&we(e,t,o,d,l,b)}t=y,a=p,l=M,D!=null?di(e,!!a,D,!1):!!l!=!!a&&(t!=null?di(e,!!a,t,!0):di(e,!!a,a?[]:"",!1));return;case"textarea":M=D=null;for(y in a)if(o=a[y],a.hasOwnProperty(y)&&o!=null&&!l.hasOwnProperty(y))switch(y){case"value":break;case"children":break;default:we(e,t,y,null,l,o)}for(p in l)if(o=l[p],d=a[p],l.hasOwnProperty(p)&&(o!=null||d!=null))switch(p){case"value":D=o;break;case"defaultValue":M=o;break;case"children":break;case"dangerouslySetInnerHTML":if(o!=null)throw Error(c(91));break;default:o!==d&&we(e,t,p,o,l,d)}bf(e,D,M);return;case"option":for(var I in a)if(D=a[I],a.hasOwnProperty(I)&&D!=null&&!l.hasOwnProperty(I))switch(I){case"selected":e.selected=!1;break;default:we(e,t,I,null,l,D)}for(b in l)if(D=l[b],M=a[b],l.hasOwnProperty(b)&&D!==M&&(D!=null||M!=null))switch(b){case"selected":e.selected=D&&typeof D!="function"&&typeof D!="symbol";break;default:we(e,t,b,D,l,M)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var W in a)D=a[W],a.hasOwnProperty(W)&&D!=null&&!l.hasOwnProperty(W)&&we(e,t,W,null,l,D);for(O in l)if(D=l[O],M=a[O],l.hasOwnProperty(O)&&D!==M&&(D!=null||M!=null))switch(O){case"children":case"dangerouslySetInnerHTML":if(D!=null)throw Error(c(137,t));break;default:we(e,t,O,D,l,M)}return;default:if(Zc(t)){for(var _e in a)D=a[_e],a.hasOwnProperty(_e)&&D!==void 0&&!l.hasOwnProperty(_e)&&zu(e,t,_e,void 0,l,D);for(k in l)D=l[k],M=a[k],!l.hasOwnProperty(k)||D===M||D===void 0&&M===void 0||zu(e,t,k,D,l,M);return}}for(var T in a)D=a[T],a.hasOwnProperty(T)&&D!=null&&!l.hasOwnProperty(T)&&we(e,t,T,null,l,D);for(L in l)D=l[L],M=a[L],!l.hasOwnProperty(L)||D===M||D==null&&M==null||we(e,t,L,D,l,M)}var Ru=null,ku=null;function Hr(e){return e.nodeType===9?e:e.ownerDocument}function Sp(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function wp(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Bu(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Nu=null;function Sv(){var e=window.event;return e&&e.type==="popstate"?e===Nu?!1:(Nu=e,!0):(Nu=null,!1)}var _p=typeof setTimeout=="function"?setTimeout:void 0,wv=typeof clearTimeout=="function"?clearTimeout:void 0,Tp=typeof Promise=="function"?Promise:void 0,_v=typeof queueMicrotask=="function"?queueMicrotask:typeof Tp<"u"?function(e){return Tp.resolve(null).then(e).catch(Tv)}:_p;function Tv(e){setTimeout(function(){throw e})}function ga(e){return e==="head"}function Ap(e,t){var a=t,l=0,o=0;do{var d=a.nextSibling;if(e.removeChild(a),d&&d.nodeType===8)if(a=d.data,a==="/$"){if(0<l&&8>l){a=l;var p=e.ownerDocument;if(a&1&&Yl(p.documentElement),a&2&&Yl(p.body),a&4)for(a=p.head,Yl(a),p=a.firstChild;p;){var y=p.nextSibling,b=p.nodeName;p[ll]||b==="SCRIPT"||b==="STYLE"||b==="LINK"&&p.rel.toLowerCase()==="stylesheet"||a.removeChild(p),p=y}}if(o===0){e.removeChild(d),Pl(t);return}o--}else a==="$"||a==="$?"||a==="$!"?o++:l=a.charCodeAt(0)-48;else l=0;a=d}while(a);Pl(t)}function Uu(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var a=t;switch(t=t.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":Uu(a),$c(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}e.removeChild(a)}}function Av(e,t,a,l){for(;e.nodeType===1;){var o=a;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!l&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(l){if(!e[ll])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(d=e.getAttribute("rel"),d==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(d!==o.rel||e.getAttribute("href")!==(o.href==null||o.href===""?null:o.href)||e.getAttribute("crossorigin")!==(o.crossOrigin==null?null:o.crossOrigin)||e.getAttribute("title")!==(o.title==null?null:o.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(d=e.getAttribute("src"),(d!==(o.src==null?null:o.src)||e.getAttribute("type")!==(o.type==null?null:o.type)||e.getAttribute("crossorigin")!==(o.crossOrigin==null?null:o.crossOrigin))&&d&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var d=o.name==null?null:""+o.name;if(o.type==="hidden"&&e.getAttribute("name")===d)return e}else return e;if(e=sn(e.nextSibling),e===null)break}return null}function Cv(e,t,a){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=sn(e.nextSibling),e===null))return null;return e}function Lu(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState==="complete"}function Ev(e,t){var a=e.ownerDocument;if(e.data!=="$?"||a.readyState==="complete")t();else{var l=function(){t(),a.removeEventListener("DOMContentLoaded",l)};a.addEventListener("DOMContentLoaded",l),e._reactRetry=l}}function sn(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="F!"||t==="F")break;if(t==="/$")return null}}return e}var Hu=null;function Cp(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"){if(t===0)return e;t--}else a==="/$"&&t++}e=e.previousSibling}return null}function Ep(e,t,a){switch(t=Hr(a),e){case"html":if(e=t.documentElement,!e)throw Error(c(452));return e;case"head":if(e=t.head,!e)throw Error(c(453));return e;case"body":if(e=t.body,!e)throw Error(c(454));return e;default:throw Error(c(451))}}function Yl(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);$c(e)}var Wt=new Map,Op=new Set;function qr(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Gn=Y.d;Y.d={f:Ov,r:Dv,D:Mv,C:zv,L:Rv,m:kv,X:Nv,S:Bv,M:Uv};function Ov(){var e=Gn.f(),t=Mr();return e||t}function Dv(e){var t=ri(e);t!==null&&t.tag===5&&t.type==="form"?Fh(t):Gn.r(e)}var $i=typeof document>"u"?null:document;function Dp(e,t,a){var l=$i;if(l&&typeof t=="string"&&t){var o=Yt(t);o='link[rel="'+e+'"][href="'+o+'"]',typeof a=="string"&&(o+='[crossorigin="'+a+'"]'),Op.has(o)||(Op.add(o),e={rel:e,crossOrigin:a,href:t},l.querySelector(o)===null&&(t=l.createElement("link"),ft(t,"link",e),it(t),l.head.appendChild(t)))}}function Mv(e){Gn.D(e),Dp("dns-prefetch",e,null)}function zv(e,t){Gn.C(e,t),Dp("preconnect",e,t)}function Rv(e,t,a){Gn.L(e,t,a);var l=$i;if(l&&e&&t){var o='link[rel="preload"][as="'+Yt(t)+'"]';t==="image"&&a&&a.imageSrcSet?(o+='[imagesrcset="'+Yt(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(o+='[imagesizes="'+Yt(a.imageSizes)+'"]')):o+='[href="'+Yt(e)+'"]';var d=o;switch(t){case"style":d=Gi(e);break;case"script":d=Vi(e)}Wt.has(d)||(e=v({rel:"preload",href:t==="image"&&a&&a.imageSrcSet?void 0:e,as:t},a),Wt.set(d,e),l.querySelector(o)!==null||t==="style"&&l.querySelector(Xl(d))||t==="script"&&l.querySelector(Ql(d))||(t=l.createElement("link"),ft(t,"link",e),it(t),l.head.appendChild(t)))}}function kv(e,t){Gn.m(e,t);var a=$i;if(a&&e){var l=t&&typeof t.as=="string"?t.as:"script",o='link[rel="modulepreload"][as="'+Yt(l)+'"][href="'+Yt(e)+'"]',d=o;switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=Vi(e)}if(!Wt.has(d)&&(e=v({rel:"modulepreload",href:e},t),Wt.set(d,e),a.querySelector(o)===null)){switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(Ql(d)))return}l=a.createElement("link"),ft(l,"link",e),it(l),a.head.appendChild(l)}}}function Bv(e,t,a){Gn.S(e,t,a);var l=$i;if(l&&e){var o=ci(l).hoistableStyles,d=Gi(e);t=t||"default";var p=o.get(d);if(!p){var y={loading:0,preload:null};if(p=l.querySelector(Xl(d)))y.loading=5;else{e=v({rel:"stylesheet",href:e,"data-precedence":t},a),(a=Wt.get(d))&&qu(e,a);var b=p=l.createElement("link");it(b),ft(b,"link",e),b._p=new Promise(function(O,k){b.onload=O,b.onerror=k}),b.addEventListener("load",function(){y.loading|=1}),b.addEventListener("error",function(){y.loading|=2}),y.loading|=4,$r(p,t,l)}p={type:"stylesheet",instance:p,count:1,state:y},o.set(d,p)}}}function Nv(e,t){Gn.X(e,t);var a=$i;if(a&&e){var l=ci(a).hoistableScripts,o=Vi(e),d=l.get(o);d||(d=a.querySelector(Ql(o)),d||(e=v({src:e,async:!0},t),(t=Wt.get(o))&&$u(e,t),d=a.createElement("script"),it(d),ft(d,"link",e),a.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},l.set(o,d))}}function Uv(e,t){Gn.M(e,t);var a=$i;if(a&&e){var l=ci(a).hoistableScripts,o=Vi(e),d=l.get(o);d||(d=a.querySelector(Ql(o)),d||(e=v({src:e,async:!0,type:"module"},t),(t=Wt.get(o))&&$u(e,t),d=a.createElement("script"),it(d),ft(d,"link",e),a.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},l.set(o,d))}}function Mp(e,t,a,l){var o=(o=Wn.current)?qr(o):null;if(!o)throw Error(c(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(t=Gi(a.href),a=ci(o).hoistableStyles,l=a.get(t),l||(l={type:"style",instance:null,count:0,state:null},a.set(t,l)),l):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){e=Gi(a.href);var d=ci(o).hoistableStyles,p=d.get(e);if(p||(o=o.ownerDocument||o,p={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,p),(d=o.querySelector(Xl(e)))&&!d._p&&(p.instance=d,p.state.loading=5),Wt.has(e)||(a={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},Wt.set(e,a),d||Lv(o,e,a,p.state))),t&&l===null)throw Error(c(528,""));return p}if(t&&l!==null)throw Error(c(529,""));return null;case"script":return t=a.async,a=a.src,typeof a=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Vi(a),a=ci(o).hoistableScripts,l=a.get(t),l||(l={type:"script",instance:null,count:0,state:null},a.set(t,l)),l):{type:"void",instance:null,count:0,state:null};default:throw Error(c(444,e))}}function Gi(e){return'href="'+Yt(e)+'"'}function Xl(e){return'link[rel="stylesheet"]['+e+"]"}function zp(e){return v({},e,{"data-precedence":e.precedence,precedence:null})}function Lv(e,t,a,l){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?l.loading=1:(t=e.createElement("link"),l.preload=t,t.addEventListener("load",function(){return l.loading|=1}),t.addEventListener("error",function(){return l.loading|=2}),ft(t,"link",a),it(t),e.head.appendChild(t))}function Vi(e){return'[src="'+Yt(e)+'"]'}function Ql(e){return"script[async]"+e}function Rp(e,t,a){if(t.count++,t.instance===null)switch(t.type){case"style":var l=e.querySelector('style[data-href~="'+Yt(a.href)+'"]');if(l)return t.instance=l,it(l),l;var o=v({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return l=(e.ownerDocument||e).createElement("style"),it(l),ft(l,"style",o),$r(l,a.precedence,e),t.instance=l;case"stylesheet":o=Gi(a.href);var d=e.querySelector(Xl(o));if(d)return t.state.loading|=4,t.instance=d,it(d),d;l=zp(a),(o=Wt.get(o))&&qu(l,o),d=(e.ownerDocument||e).createElement("link"),it(d);var p=d;return p._p=new Promise(function(y,b){p.onload=y,p.onerror=b}),ft(d,"link",l),t.state.loading|=4,$r(d,a.precedence,e),t.instance=d;case"script":return d=Vi(a.src),(o=e.querySelector(Ql(d)))?(t.instance=o,it(o),o):(l=a,(o=Wt.get(d))&&(l=v({},a),$u(l,o)),e=e.ownerDocument||e,o=e.createElement("script"),it(o),ft(o,"link",l),e.head.appendChild(o),t.instance=o);case"void":return null;default:throw Error(c(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(l=t.instance,t.state.loading|=4,$r(l,a.precedence,e));return t.instance}function $r(e,t,a){for(var l=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),o=l.length?l[l.length-1]:null,d=o,p=0;p<l.length;p++){var y=l[p];if(y.dataset.precedence===t)d=y;else if(d!==o)break}d?d.parentNode.insertBefore(e,d.nextSibling):(t=a.nodeType===9?a.head:a,t.insertBefore(e,t.firstChild))}function qu(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function $u(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var Gr=null;function kp(e,t,a){if(Gr===null){var l=new Map,o=Gr=new Map;o.set(a,l)}else o=Gr,l=o.get(a),l||(l=new Map,o.set(a,l));if(l.has(e))return l;for(l.set(e,null),a=a.getElementsByTagName(e),o=0;o<a.length;o++){var d=a[o];if(!(d[ll]||d[mt]||e==="link"&&d.getAttribute("rel")==="stylesheet")&&d.namespaceURI!=="http://www.w3.org/2000/svg"){var p=d.getAttribute(t)||"";p=e+p;var y=l.get(p);y?y.push(d):l.set(p,[d])}}return l}function Bp(e,t,a){e=e.ownerDocument||e,e.head.insertBefore(a,t==="title"?e.querySelector("head > title"):null)}function Hv(e,t,a){if(a===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function Np(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}var Zl=null;function qv(){}function $v(e,t,a){if(Zl===null)throw Error(c(475));var l=Zl;if(t.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(t.state.loading&4)===0){if(t.instance===null){var o=Gi(a.href),d=e.querySelector(Xl(o));if(d){e=d._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(l.count++,l=Vr.bind(l),e.then(l,l)),t.state.loading|=4,t.instance=d,it(d);return}d=e.ownerDocument||e,a=zp(a),(o=Wt.get(o))&&qu(a,o),d=d.createElement("link"),it(d);var p=d;p._p=new Promise(function(y,b){p.onload=y,p.onerror=b}),ft(d,"link",a),t.instance=d}l.stylesheets===null&&(l.stylesheets=new Map),l.stylesheets.set(t,e),(e=t.state.preload)&&(t.state.loading&3)===0&&(l.count++,t=Vr.bind(l),e.addEventListener("load",t),e.addEventListener("error",t))}}function Gv(){if(Zl===null)throw Error(c(475));var e=Zl;return e.stylesheets&&e.count===0&&Gu(e,e.stylesheets),0<e.count?function(t){var a=setTimeout(function(){if(e.stylesheets&&Gu(e,e.stylesheets),e.unsuspend){var l=e.unsuspend;e.unsuspend=null,l()}},6e4);return e.unsuspend=t,function(){e.unsuspend=null,clearTimeout(a)}}:null}function Vr(){if(this.count--,this.count===0){if(this.stylesheets)Gu(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yr=null;function Gu(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yr=new Map,t.forEach(Vv,e),Yr=null,Vr.call(e))}function Vv(e,t){if(!(t.state.loading&4)){var a=Yr.get(e);if(a)var l=a.get(null);else{a=new Map,Yr.set(e,a);for(var o=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d<o.length;d++){var p=o[d];(p.nodeName==="LINK"||p.getAttribute("media")!=="not all")&&(a.set(p.dataset.precedence,p),l=p)}l&&a.set(null,l)}o=t.instance,p=o.getAttribute("data-precedence"),d=a.get(p)||l,d===l&&a.set(null,o),a.set(p,o),this.count++,l=Vr.bind(this),o.addEventListener("load",l),o.addEventListener("error",l),d?d.parentNode.insertBefore(o,d.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(o,e.firstChild)),t.state.loading|=4}}var Kl={$$typeof:V,Provider:null,Consumer:null,_currentValue:te,_currentValue2:te,_threadCount:0};function Yv(e,t,a,l,o,d,p,y){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Uc(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Uc(0),this.hiddenUpdates=Uc(null),this.identifierPrefix=l,this.onUncaughtError=o,this.onCaughtError=d,this.onRecoverableError=p,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=y,this.incompleteTransitions=new Map}function Up(e,t,a,l,o,d,p,y,b,O,k,L){return e=new Yv(e,t,a,p,y,b,O,L),t=1,d===!0&&(t|=24),d=Bt(3,null,null,t),e.current=d,d.stateNode=e,t=wo(),t.refCount++,e.pooledCache=t,t.refCount++,d.memoizedState={element:l,isDehydrated:a,cache:t},Co(d),e}function Lp(e){return e?(e=bi,e):bi}function Hp(e,t,a,l,o,d){o=Lp(o),l.context===null?l.context=o:l.pendingContext=o,l=aa(t),l.payload={element:a},d=d===void 0?null:d,d!==null&&(l.callback=d),a=ia(e,l,t),a!==null&&(qt(a,e,t),_l(a,e,t))}function qp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<t?a:t}}function Vu(e,t){qp(e,t),(e=e.alternate)&&qp(e,t)}function $p(e){if(e.tag===13){var t=vi(e,67108864);t!==null&&qt(t,e,67108864),Vu(e,67108864)}}var Xr=!0;function Xv(e,t,a,l){var o=U.T;U.T=null;var d=Y.p;try{Y.p=2,Yu(e,t,a,l)}finally{Y.p=d,U.T=o}}function Qv(e,t,a,l){var o=U.T;U.T=null;var d=Y.p;try{Y.p=8,Yu(e,t,a,l)}finally{Y.p=d,U.T=o}}function Yu(e,t,a,l){if(Xr){var o=Xu(l);if(o===null)Mu(e,t,l,Qr,a),Vp(e,l);else if(Kv(o,e,t,a,l))l.stopPropagation();else if(Vp(e,l),t&4&&-1<Zv.indexOf(e)){for(;o!==null;){var d=ri(o);if(d!==null)switch(d.tag){case 3:if(d=d.stateNode,d.current.memoizedState.isDehydrated){var p=za(d.pendingLanes);if(p!==0){var y=d;for(y.pendingLanes|=2,y.entangledLanes|=2;p;){var b=1<<31-Rt(p);y.entanglements[1]|=b,p&=~b}yn(d),(ve&6)===0&&(Or=hn()+500,$l(0))}}break;case 13:y=vi(d,2),y!==null&&qt(y,d,2),Mr(),Vu(d,2)}if(d=Xu(l),d===null&&Mu(e,t,l,Qr,a),d===o)break;o=d}o!==null&&l.stopPropagation()}else Mu(e,t,l,null,a)}}function Xu(e){return e=Fc(e),Qu(e)}var Qr=null;function Qu(e){if(Qr=null,e=si(e),e!==null){var t=f(e);if(t===null)e=null;else{var a=t.tag;if(a===13){if(e=h(t),e!==null)return e;e=null}else if(a===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Qr=e,null}function Gp(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(z0()){case tf:return 2;case nf:return 8;case Ls:case R0:return 32;case af:return 268435456;default:return 32}default:return 32}}var Zu=!1,xa=null,ya=null,va=null,Fl=new Map,Jl=new Map,ba=[],Zv="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Vp(e,t){switch(e){case"focusin":case"focusout":xa=null;break;case"dragenter":case"dragleave":ya=null;break;case"mouseover":case"mouseout":va=null;break;case"pointerover":case"pointerout":Fl.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Jl.delete(t.pointerId)}}function Wl(e,t,a,l,o,d){return e===null||e.nativeEvent!==d?(e={blockedOn:t,domEventName:a,eventSystemFlags:l,nativeEvent:d,targetContainers:[o]},t!==null&&(t=ri(t),t!==null&&$p(t)),e):(e.eventSystemFlags|=l,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function Kv(e,t,a,l,o){switch(t){case"focusin":return xa=Wl(xa,e,t,a,l,o),!0;case"dragenter":return ya=Wl(ya,e,t,a,l,o),!0;case"mouseover":return va=Wl(va,e,t,a,l,o),!0;case"pointerover":var d=o.pointerId;return Fl.set(d,Wl(Fl.get(d)||null,e,t,a,l,o)),!0;case"gotpointercapture":return d=o.pointerId,Jl.set(d,Wl(Jl.get(d)||null,e,t,a,l,o)),!0}return!1}function Yp(e){var t=si(e.target);if(t!==null){var a=f(t);if(a!==null){if(t=a.tag,t===13){if(t=h(a),t!==null){e.blockedOn=t,$0(e.priority,function(){if(a.tag===13){var l=Ht();l=Lc(l);var o=vi(a,l);o!==null&&qt(o,a,l),Vu(a,l)}});return}}else if(t===3&&a.stateNode.current.memoizedState.isDehydrated){e.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Zr(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var a=Xu(e.nativeEvent);if(a===null){a=e.nativeEvent;var l=new a.constructor(a.type,a);Kc=l,a.target.dispatchEvent(l),Kc=null}else return t=ri(a),t!==null&&$p(t),e.blockedOn=a,!1;t.shift()}return!0}function Xp(e,t,a){Zr(e)&&a.delete(t)}function Fv(){Zu=!1,xa!==null&&Zr(xa)&&(xa=null),ya!==null&&Zr(ya)&&(ya=null),va!==null&&Zr(va)&&(va=null),Fl.forEach(Xp),Jl.forEach(Xp)}function Kr(e,t){e.blockedOn===t&&(e.blockedOn=null,Zu||(Zu=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,Fv)))}var Fr=null;function Qp(e){Fr!==e&&(Fr=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Fr===e&&(Fr=null);for(var t=0;t<e.length;t+=3){var a=e[t],l=e[t+1],o=e[t+2];if(typeof l!="function"){if(Qu(l||a)===null)continue;break}var d=ri(a);d!==null&&(e.splice(t,3),t-=3,Qo(d,{pending:!0,data:o,method:a.method,action:l},l,o))}}))}function Pl(e){function t(b){return Kr(b,e)}xa!==null&&Kr(xa,e),ya!==null&&Kr(ya,e),va!==null&&Kr(va,e),Fl.forEach(t),Jl.forEach(t);for(var a=0;a<ba.length;a++){var l=ba[a];l.blockedOn===e&&(l.blockedOn=null)}for(;0<ba.length&&(a=ba[0],a.blockedOn===null);)Yp(a),a.blockedOn===null&&ba.shift();if(a=(e.ownerDocument||e).$$reactFormReplay,a!=null)for(l=0;l<a.length;l+=3){var o=a[l],d=a[l+1],p=o[jt]||null;if(typeof d=="function")p||Qp(a);else if(p){var y=null;if(d&&d.hasAttribute("formAction")){if(o=d,p=d[jt]||null)y=p.formAction;else if(Qu(o)!==null)continue}else y=p.action;typeof y=="function"?a[l+1]=y:(a.splice(l,3),l-=3),Qp(a)}}}function Ku(e){this._internalRoot=e}Jr.prototype.render=Ku.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(c(409));var a=t.current,l=Ht();Hp(a,l,e,t,null,null)},Jr.prototype.unmount=Ku.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Hp(e.current,2,null,e,null,null),Mr(),t[li]=null}};function Jr(e){this._internalRoot=e}Jr.prototype.unstable_scheduleHydration=function(e){if(e){var t=of();e={blockedOn:null,target:e,priority:t};for(var a=0;a<ba.length&&t!==0&&t<ba[a].priority;a++);ba.splice(a,0,e),a===0&&Yp(e)}};var Zp=i.version;if(Zp!=="19.1.0")throw Error(c(527,Zp,"19.1.0"));Y.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(c(188)):(e=Object.keys(e).join(","),Error(c(268,e)));return e=x(t),e=e!==null?g(e):null,e=e===null?null:e.stateNode,e};var Jv={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:U,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Wr=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Wr.isDisabled&&Wr.supportsFiber)try{nl=Wr.inject(Jv),zt=Wr}catch{}}return Il.createRoot=function(e,t){if(!u(e))throw Error(c(299));var a=!1,l="",o=om,d=um,p=dm,y=null;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(l=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(d=t.onCaughtError),t.onRecoverableError!==void 0&&(p=t.onRecoverableError),t.unstable_transitionCallbacks!==void 0&&(y=t.unstable_transitionCallbacks)),t=Up(e,1,!1,null,null,a,l,o,d,p,y,null),e[li]=t.current,Du(e),new Ku(t)},Il.hydrateRoot=function(e,t,a){if(!u(e))throw Error(c(299));var l=!1,o="",d=om,p=um,y=dm,b=null,O=null;return a!=null&&(a.unstable_strictMode===!0&&(l=!0),a.identifierPrefix!==void 0&&(o=a.identifierPrefix),a.onUncaughtError!==void 0&&(d=a.onUncaughtError),a.onCaughtError!==void 0&&(p=a.onCaughtError),a.onRecoverableError!==void 0&&(y=a.onRecoverableError),a.unstable_transitionCallbacks!==void 0&&(b=a.unstable_transitionCallbacks),a.formState!==void 0&&(O=a.formState)),t=Up(e,1,!0,t,a??null,l,o,d,p,y,b,O),t.context=Lp(null),a=t.current,l=Ht(),l=Lc(l),o=aa(l),o.callback=null,ia(a,o,l),a=l,t.current.lanes=a,il(t,a),yn(t),e[li]=t.current,Du(e),new Jr(t)},Il.version="19.1.0",Il}var Ip;function I1(){if(Ip)return Ju.exports;Ip=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(i){console.error(i)}}return n(),Ju.exports=P1(),Ju.exports}var eb=I1();function Ta(n){var i=[],r=Math.floor(n/3600);r>0&&i.push(`${r}h`);var c=Math.floor(n%3600/60);c>0&&i.push(`${c}min`);var u=n%60;return u>0&&i.push(`${u}s`),i?i.length>1?`${i[0]} ${i[1]}`:i[0]:"-"}function Ii(n){return n.toLocaleString("en-GB",{timeZone:"UTC"})}function bc(n){const i=(f,h,m=!1)=>{f=Math.trunc(f),f>1&&(h+="s");let x="";return m||(x+="in "),x+=`${f.toLocaleString()} ${h}`,m&&(x+=" ago"),x};if(!(n instanceof Date))return`expected date saw ${typeof n}`;const r=new Date,c=n<r;var u=Math.abs(r-n)/1e3;return u<60?c?"just now":"less than one minute":(u=u/60,u<60?i(u,"minute",c):(u=u/60,u<24?i(u,"hour",c):(u=u/24,u<365?i(u,"day",c):n.toLocaleDateString("en-GB",{timeZone:"UTC"}))))}function ps(n){return n.toLocaleString("en-GB",{timeZone:"UTC",dateStyle:"short"})}/*! js-cookie v3.0.5 | MIT */function Pr(n){for(var i=1;i<arguments.length;i++){var r=arguments[i];for(var c in r)n[c]=r[c]}return n}var tb={read:function(n){return n[0]==='"'&&(n=n.slice(1,-1)),n.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(n){return encodeURIComponent(n).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function ud(n,i){function r(u,f,h){if(!(typeof document>"u")){h=Pr({},i,h),typeof h.expires=="number"&&(h.expires=new Date(Date.now()+h.expires*864e5)),h.expires&&(h.expires=h.expires.toUTCString()),u=encodeURIComponent(u).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var m="";for(var x in h)h[x]&&(m+="; "+x,h[x]!==!0&&(m+="="+h[x].split(";")[0]));return document.cookie=u+"="+n.write(f,u)+m}}function c(u){if(!(typeof document>"u"||arguments.length&&!u)){for(var f=document.cookie?document.cookie.split("; "):[],h={},m=0;m<f.length;m++){var x=f[m].split("="),g=x.slice(1).join("=");try{var v=decodeURIComponent(x[0]);if(h[v]=n.read(g,v),u===v)break}catch{}}return u?h[u]:h}}return Object.create({set:r,get:c,remove:function(u,f){r(u,"",Pr({},f,{expires:-1}))},withAttributes:function(u){return ud(this.converter,Pr({},this.attributes,u))},withConverter:function(u){return ud(Pr({},this.converter,u),this.attributes)}},{attributes:{value:Object.freeze(i)},converter:{value:Object.freeze(n)}})}var fx=ud(tb,{path:"/"}),hx=dx();const mx=r1(hx),Xn=A.div`
  position: fixed;
  background-color: ${({theme:n,$variant:i})=>n.colors[i].color};
  color: ${({theme:n,$variant:i})=>n.colors[i].text};
  border-radius: 15px;
  padding: 20px;
  max-width: 400px;
  transition:
    bottom 0.3s ease-in-out,
    right 0.3s ease-in-out,
    opacity 0.3s ease-in-out,
    padding 0.3s ease-in-out;
  box-sizing: content-box;
  z-index: 101;
`;Xn.Container=A.div`
  > ${Xn} {
    display: none;
  }

  > ${Xn}:nth-last-child(1) {
    display: block;
    padding: 20px;
    bottom: 50px;
    right: 50px;
    opacity: 1;
  }

  > ${Xn}:nth-last-child(2) {
    display: block;
    padding: 15px;
    bottom: 90px;
    right: 55px;
    opacity: 0.8;
  }

  > ${Xn}:nth-last-child(3) {
    display: block;
    padding: 10px;
    bottom: 130px;
    right: 60px;
    opacity: 0.6;
  }
`;Xn.Title=A.strong`
  font-weight: bold;
`;function nb({title:n,message:i,variant:r}){return s.jsxs(Xn,{$variant:r,children:[n&&s.jsxs(Xn.Title,{children:[n," "]}),i]})}function ab({toasts:n,setToasts:i}){return S.useEffect(()=>{const r=setInterval(()=>{const c=new Date,u=n.filter(f=>f.expire>c);u.length!==n.length&&i(u)},1e3);return()=>clearInterval(r)},[n,i]),mx.createPortal(s.jsx(Xn.Container,{children:n.map(({id:r,...c})=>s.jsx(nb,{...c},`toast-${r}`))}),document.body)}function _n(n,{title:i="",message:r,variant:c,time:u=1e4}){const f=Math.random().toString(36),h=new Date(Date.now()+u);n({id:f,title:i,message:r,variant:c,expire:h})}async function Zn(n,i){var r,c;try{const u=await i;let f="Action completed successfully";if(typeof u=="string")f=u;else if(typeof(u==null?void 0:u.status)=="string")f=u.status;else try{f=JSON.stringify(u)}catch{f=((r=u==null?void 0:u.toString)==null?void 0:r.call(u))??"Success"}return _n(n,{message:f,variant:"success"}),u}catch(u){throw console.error(u),_n(n,{message:((c=u==null?void 0:u.toString)==null?void 0:c.call(u))??"Unknown error",variant:"danger"}),u}}async function me(n,i){var r,c,u;try{return await i}catch(f){console.error(f);let h="An unknown error occurred";if((c=(r=f==null?void 0:f.response)==null?void 0:r.data)!=null&&c.detail)h=f.response.data.detail;else if(f!=null&&f.detail)h=f.detail;else if(f!=null&&f.message)h=f.message;else if(typeof f=="string")h=f;else try{h=JSON.stringify(f)}catch{h=(u=f.toString)==null?void 0:u.call(f)}_n(n,{title:"Error",message:h,variant:"danger"})}}const He=J.createContext(null),pe=J.createContext(()=>{}),el=J.createContext(null);async function ct(n,{json:i,...r}){var c={...r};c.headers||(c.headers={});const u=fx.get("csrftoken");u&&(c.headers["x-csrftoken"]=u),i&&(c.method||(c.method="POST"),c.headers["Content-Type"]="application/json",c.body=JSON.stringify(i));const f=await fetch(n,c);var h;if((f.headers.get("Content-Type")||"").match(/json/)?h=await f.json():h=await f.text(),f.status>=400)throw h;return h}async function ib(n,i){var r;try{const c=await i;let u="Action completed successfully";if(typeof c=="string")u=c;else if(typeof(c==null?void 0:c.status)=="string")u=c.status;else try{u=JSON.stringify(c)}catch{u=((r=c==null?void 0:c.toString)==null?void 0:r.call(c))??"Success"}return _n(n,{message:u,variant:"success"}),c}catch(c){throw console.error(c),_n(n,{message:c.toString(),variant:"danger"}),c}}async function lb(n,i){var r,c;try{await i}catch(u){console.error(u);let f="An unknown error occurred";if((c=(r=u==null?void 0:u.response)==null?void 0:r.data)!=null&&c.detail)f=u.response.data.detail;else if(u!=null&&u.detail)f=u.detail;else if(u!=null&&u.message)f=u.message;else if(typeof u=="string")f=u;else try{f=JSON.stringify(u)}catch{f=u.toString()}_n(n,{title:"Error",message:f,variant:"danger"})}}function Dt(n){const i=J.useContext(pe),[r,c]=J.useState(null),u=J.useCallback(()=>{n&&lb(i,ct(n,{}).then(c,f=>{throw c(null),f}))},[i,n]);return J.useEffect(()=>{c(null),u()},[u]),[r,u]}async function xe(n,i,r={}){let c=n;if(r.params){for(const[w,j]of Object.entries(r.params)){const E=`{${w}}`;c.includes(E)&&(c=c.replace(E,encodeURIComponent(String(j))))}if(i==="get"){const w=new Set;for(const[j,E]of Object.entries(r.params)){const R=`{${j}}`;c.includes(R)&&(c=c.replace(R,encodeURIComponent(String(E))),w.add(j))}if(i==="get"){const j=new URLSearchParams;for(const[E,R]of Object.entries(r.params))w.has(E)||j.append(E,String(R));j.toString()&&(c+=c.includes("?")?"&"+j.toString():"?"+j.toString())}}}const f={"x-csrftoken":fx.get("csrftoken")??"",Accept:"application/json",...r.headers||{}},h={method:i.toUpperCase(),headers:f};r.body&&(f["Content-Type"]="application/json",h.body=JSON.stringify(r.body));const m=await fetch(c,h),v=(m.headers.get("Content-Type")||"").includes("json")?await m.json():await m.text();if(!m.ok)throw v;return v}function Td(n){const i=S.useContext(pe),[r,c]=S.useState(null),u=S.useCallback(()=>{n&&me(i,fetch(n).then(async f=>{if(!f.ok)throw await f.json();return await f.json()}).then(c).catch(f=>{throw c(null),f}))},[i,n]);return S.useEffect(()=>{c(null),u()},[u]),[r,u]}function px(n){return xe("/incursions/api/open_window","post",{body:n})}function sb(n){return xe("/incursions/api/pilot/info","get",{params:{character_id:n}})}async function rb(n,i){await xe("/incursions/api/notes/add","post",{body:{character_id:n,note:i}})}const Ad=A.img`
  border-radius: 25%;
  margin-right: 10px;
  vertical-align: middle;

  @media (max-width: 450px) {
    display: none;
  }
`;function yt({avatar:n=!0,avatarSize:i=32,character_id:r=1,character_name:c,noLink:u=!1}){return s.jsxs(s.Fragment,{children:[n&&s.jsx(Ad,{src:`https://images.evetech.net/characters/${r}/portrait?size=${i}`,loading:"lazy"}),u?c:s.jsx(gc,{to:`/fc/search?query=${c}`,children:c})]})}function Cd({avatar:n=!0,avatarSize:i=32,corporation_id:r=1,corporation_name:c,noLink:u=!1}){const f=S.useContext(pe),h=S.useContext(He),m=()=>{me(f,px({character_id:h.current.character_id,target_id:r}))};return s.jsxs(s.Fragment,{children:[n&&s.jsx(Ad,{src:`https://images.evetech.net/corporations/${r}/logo?size=${i}`,loading:"lazy"}),u?c:s.jsxs(s.Fragment,{children:[s.jsx(gc,{to:"#",onClick:m,children:c}),s.jsx(fe,{fixedWidth:!0,icon:As})]})]})}function Ed({avatar:n=!0,avatarSize:i=32,alliance_id:r=1,alliance_name:c,noLink:u=!1}){const f=S.useContext(pe),h=S.useContext(He),m=()=>{me(f,px({character_id:h.current.character_id,target_id:r}))};return s.jsxs(s.Fragment,{children:[n&&s.jsx(Ad,{src:`https://images.evetech.net/alliances/${r}/logo?size=${i}`,loading:"lazy"}),u?c:s.jsxs(s.Fragment,{children:[s.jsx(gc,{to:"#",onClick:m,children:c}),s.jsx(fe,{fixedWidth:!0,icon:As})]})]})}const Fn=A.table.withConfig({shouldForwardProp:n=>!["fullWidth","edgeLine"].includes(n)})`
  table-layout: fixed;
  ${({fullWidth:n})=>n&&"width: 100%;"}
  ${({edgeLine:n,theme:i})=>n&&`
    border-top: solid 1px ${i.colors.accent2};
    border-bottom: solid 1px ${i.colors.accent2};
  `}

  @media (max-width: 480px) {
    width: 100%;
    font-size: 3.4vw;
  }
`,ai=A.thead`
  border-bottom: solid 2px ${({theme:n})=>n.colors.accent2};
`,Jn=A.tbody``,Ue=A.tr`
  background-color: ${({theme:n})=>n.colors.background};

  ${({background:n,theme:i})=>n&&`
      background-color: ${i.colors.accent1};
      box-shadow: 2px 2px 5px ${i.colors.shadow};
    `}

  &:last-child {
    border-bottom: none;
  }

  ${({noAlternating:n,theme:i})=>!n&&`
      border-bottom: solid 1px ${i.colors.accent2};
      &:nth-child(odd) {
        background-color: ${i.colors.accent1};
      }
    `}
`,Fe=A.th`
  text-align: left;
  padding: 0.5em;
  font-weight: 600;
`,cb=A.th`
  text-align: left;
  padding: 0.5em;
  font-weight: 600;
  width: 75px;

  @media (max-width: 480px) {
    width: 60px;
  }
`,ae=A.td`
  padding: 0.5em;
  color: ${({theme:n})=>n.colors.text};

  a {
    color: ${({theme:n})=>n.colors.text};
  }

  @media (max-width: 480px) {
    padding: 0.3em;
  }
`,Qn=A.td`
  color: ${({theme:n})=>n.colors.text};

  a {
    color: ${({theme:n})=>n.colors.text};
  }

  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding-right: 0.3em;

  @media (max-width: 480px) {
    padding: 0.3em;
  }
`,ob=A.td`
  position: relative;
  text-align: end;
  padding: 0 0.5em;

  &::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: ${({theme:n})=>n.colors.accent2};
  }

  ${({warn:n})=>n&&`
      &::after {
        content: '';
        position: absolute;
        left: 40%;
        top: 0;
        bottom: 0;
        width: 10%;
        background: ${n};
      }
    `}
`,ub=A.span`
  a {
    color: ${n=>n.theme.colors.highlight.text};
    text-decoration: none;
    font-weight: bold;

    &:hover:not(:disabled):not(.static) {
      cursor: pointer;
      color: ${n=>n.theme.colors.highlight.active};
    }
  }
`,db=A.div`
  h2,
  h3,
  h4,
  h5,
  h6 {
    display: inline;
    &:hover a {
      visibility: visible;
      opacity: 1;
    }

    a {
      margin-left: 10px;
      font-size: smaller;
      text-decoration: none;
      visibility: hidden;
      opacity: 0;
      transition:
        visibility 0.05s,
        opacity 0.05s linear;

      &:after {
        content: '#';
      }

      &:hover {
        color: ${n=>n.theme.colors.highlight.active};
      }
    }
  }
`,fb=A.ul`
  padding-left: 1.2em;
  list-style-type: none;
  font-size: 0.9em;
  margin-bottom: 1em;

  li {
    margin: 0.3em 0;
  }

  a {
    text-decoration: none;
    color: ${n=>n.theme.colors.text};
    &:hover {
      color: ${n=>n.theme.colors.highlight.text};
    }
  }
`;function hb({href:n,children:i,...r}){return s.jsx(ub,{children:n.startsWith("/")?s.jsx(Ot,{to:n,end:!0,...r,children:i}):s.jsx("a",{href:n,target:"_blank",rel:"noopener noreferrer",...r,children:i})})}function mb({headings:n}){return n.length?s.jsx(fb,{children:n.map(({text:i,slug:r},c)=>s.jsx("li",{children:s.jsx("a",{href:`#${r}-${c}`,children:i})},c))}):null}function Cs({...n}){const[i,r]=S.useState([]),c=({level:f,children:h})=>{const m=h.map(v=>{var w;return typeof v=="string"?v:((w=v==null?void 0:v.props)==null?void 0:w.children)??""}).flat().join(" "),x=encodeURIComponent(m.replace(/[^a-zA-Z0-9 ]/g,"").replace(/\s+/g,"-").toLowerCase()),g=`${x}-${i.length}`;return r(v=>v.some(w=>w.slug===x)?v:[...v,{text:m,slug:x}]),s.jsx(db,{children:J.createElement(`h${f}`,{id:g},s.jsxs(s.Fragment,{children:[h,s.jsx("a",{href:`#${g}`,"aria-label":`Link to heading ${m}`})]}))})};S.useEffect(()=>{var h;const{hash:f}=window.location;f&&((h=document.getElementById(f.substring(1)))==null||h.scrollIntoView())},[]);const u={h2:c,h3:c,h4:c,h5:c,h6:c,a:hb,table:Fn,thead:ai,tbody:Jn,th:Fe,td:ae,tr:Ue};return s.jsxs(s.Fragment,{children:[s.jsx(mb,{headings:i}),s.jsx(Ig,{components:u,remarkPlugins:[c1],...n})]})}const ot=A.div`
  color: ${({theme:n})=>n.colors.text};

  p,
  ul,
  ol {
    margin-bottom: 1em;
    line-height: 1.5em;
  }

  a {
    font-weight: bold;
    text-decoration: none;
    color: ${({theme:n})=>n.colors.highlight.text};

    &:hover:not(:disabled):not(.static) {
      cursor: pointer;
      color: ${({theme:n})=>n.colors.highlight.active};
    }
  }

  i,
  em {
    font-style: italic;
  }

  b,
  strong {
    font-weight: bold;
  }

  h1,
  h2,
  h3,
  h4,
  h5,
  h6 {
    margin-top: 1em;
  }

  h1 + h2,
  h2 + h3,
  h3 + h4,
  h4 + h5,
  h5 + h6 {
    margin-top: 0;
  }

  h1 {
    margin-top: 0;
    font-size: 3em;
  }

  h2 {
    font-size: 2em;
  }

  h3 {
    font-size: 1.5em;
    font-weight: 600;
  }

  h4 {
    font-size: 1.2em;
    font-weight: 500;
  }

  ul {
    list-style-type: disc;
    padding-left: 2em;
  }

  ol {
    list-style-type: number;
    padding-left: 2em;
  }

  pre {
    font-family: ${({theme:n})=>n.font.monospaceFamily};
    font-size: 0.8em;
    padding: 1em;
    margin-bottom: 1em;
    border-radius: 5px;
    background-color: ${({theme:n})=>n.colors.accent1};
  }

  img {
    max-width: 100%;
  }
`,Da=A.h1`
  font-size: 3em;
  margin-bottom: 0.5em;

  @media (max-width: 480px) {
    font-size: 2em;
  }
`,Ge=A.h2`
  font-size: 1.5em;
`,gx=[{name:"Fits",value:"/fits"},{name:"Guides",value:"/guide"},{name:"Skills",value:"/skills"},{name:"Profile",value:"/pilot"},{name:"Waitlist",value:"/waitlist"}],pb=A.div`
  background: ${n=>n.theme.colors.secondary.color};
  box-shadow: 0px 3px ${n=>n.theme.colors.shadow};
  color: ${n=>n.theme.colors.text};
  margin-bottom: 3.5px;
  padding: 12px;
  position: relative;

  &[data-alert='true'] {
    background: ${n=>n.theme.colors.danger.color};
    color: ${n=>n.theme.colors.danger.text};
  }

  small {
    font-style: italic;
    font-size: small;
  }

  .close {
    position: absolute;
    right: 15px;
    top: 15px;
    width: 32px;
    height: 32px;
    opacity: 0.6;
  }

  .close:hover {
    opacity: 1;
    transition: ease-in-out 0.2s;
    cursor: pointer;
  }

  .close:before,
  .close:after {
    position: absolute;
    left: 15px;
    content: ' ';
    height: 15px;
    width: 2px;
    background-color: ${n=>n.theme.colors.secondary.text};
  }

  .close:before {
    transform: rotate(45deg);
  }

  .close:after {
    transform: rotate(-45deg);
  }
`,gb=A(ot)`
  padding-left: 42px;

  p {
    margin-bottom: 0em;
  }

  h1,
  h2,
  h3,
  h4 {
    margin-top: 0em;
  }
`,xb=(n,i)=>{const r=S.useRef();S.useEffect(()=>{r.current=n},[n]),S.useEffect(()=>{function c(){var u;(u=r.current)==null||u.call(r)}{const u=setInterval(c,i);return()=>clearInterval(u)}},[i])},yb=()=>{const n=S.useContext(He),i=S.useContext(el),[,r]=S.useReducer(E=>E+1,0),{t:c}=$(),u=An(),[f,h]=S.useState([]),[m,x]=S.useState({}),[g,v]=S.useState(window.location.pathname);S.useEffect(()=>{v(u.pathname)},[u]);const w=E=>{try{const R=JSON.parse(E.data);Array.isArray(R)&&h(R)}catch{}};S.useEffect(()=>{if(i)return i.addEventListener("announcement;new",w),i.addEventListener("announcement;updated",w),()=>{i.removeEventListener("announcement;new",w),i.removeEventListener("announcement;updated",w)}},[i]);const j=E=>{const R=JSON.parse(localStorage.getItem("ignore-announcements")||"{}"),B=new Date;Object.keys(R).forEach(z=>{R[z]<B.getTime()&&delete R[z]}),R[E]=new Date().setDate(B.getDate()+30),localStorage.setItem("ignore-announcements",JSON.stringify(R)),x(R)};return S.useEffect(()=>{(async()=>{const R=JSON.parse(localStorage.getItem("ignore-announcements")||"{}");x(R);const B=await ct("/incursions/api/announcements",{});h(Array.isArray(B)?B:[])})()},[]),xb(()=>r(),6e4),f.length===0?null:s.jsx("div",{style:{marginBottom:"10px"},children:f.map(E=>{var z,H;if(E.id in m)return null;const R=E.pages?JSON.parse(E.pages):[];if(R.length>0&&!gx.filter(X=>R.includes(X.name.toLowerCase())).some(X=>g.startsWith(X.value.toLowerCase())))return null;const B=new Date(E.created_at);return s.jsxs(pb,{"data-alert":E.is_alert,children:[s.jsx(yt,{...E.created_by,noLink:!((z=n==null?void 0:n.access)!=null&&z["incursions.waitlist_announcements_manage"])}),", ",c("{{time}}",{time:bc(B)}),s.jsx("span",{className:"close",onClick:()=>j(E.id)}),s.jsx(gb,{children:s.jsx(Cs,{children:E.message})}),((H=n==null?void 0:n.access)==null?void 0:H["incursions.waitlist_announcements_manage"])&&s.jsxs("small",{style:{paddingLeft:"42px"},children:[c("Displayed on"),": ",R.length>0?R.join(", "):c("all pages"),"."]})]},E.id)})})};async function vb(n){try{const i=await xe("/incursions/api/auth/whoami","get"),r={};i.access.forEach(f=>{r[f]=!0});const c=window.localStorage?parseInt(window.localStorage.getItem("selectedCharacter")||"",10):null;let u=0;if(c){const f=i.characters.findIndex(h=>h.character_id===c);u=f!==-1?f:0}n({...i,current:i.characters[u],access:r})}catch(i){console.error("Error fetching whoami:",i),n(null)}}class bb extends S.Component{constructor(i){super(i),this.state={hasError:!1,message:"",trace:""}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(i,r){console.error("ErrorBoundary caught an error:",i,r),this.setState({message:i.message,trace:String(r.componentStack)})}render(){const{t:i}=this.props;return this.state.hasError?s.jsxs(s.Fragment,{children:[s.jsx("p",{className:"text-center",children:i("errorBoundary.fallbackMessage","You should not be seeing this message, please report this error to your Administrators.")}),s.jsx("div",{style:{justifyContent:"center"},className:"d-flex",children:s.jsx("pre",{style:{maxWidth:"1000px"},className:"border",children:this.state.trace})})]}):this.props.children}}const Wa=Y1()(bb),De=A.div`
  background-color: ${({theme:n})=>n.colors.background};
  padding: 1.5em;
  border-radius: 5px;

  @media (max-width: 480px) {
    padding: ${({mpadding:n})=>n??"0.6em"};
    width: 100%;
  }
`,dn=o1`
  position: relative;
  padding: 0 1em;
  font-size: 1em;
  border: solid ${({$variant:n})=>n?"0px":"1px"};
  border-color: ${({theme:n})=>n.colors.accent2};
  border-radius: 20px;
  background-color: ${({theme:n,$variant:i})=>n.colors[i||"input"].color};
  color: ${({theme:n,$variant:i})=>n.colors[i||"input"].text} !important;
  display: inline-block;
  font: inherit;

  &.active {
    border-color: ${({theme:n})=>n.colors.accent2};
  }

  &:hover:not(:disabled):not(.static) {
    color: ${({theme:n,$variant:i})=>n.colors[i||"input"].text};
    border-color: ${({theme:n})=>n.colors.accent3};
    background-color: ${({theme:n,$variant:i})=>n.colors[i||"input"].accent};

    &.active {
      border-color: ${({theme:n})=>n.colors.active};
    }
  }

  &:focus:not(:disabled):not(.static) {
    outline: none;
  }

  &:disabled {
    cursor: not-allowed;
  }

  &.static {
    cursor: default;
  }

  &:disabled,
  &.static {
    color: ${({theme:n,$variant:i})=>n.colors[i||"input"].disabled};
  }

  @media (max-width: 480px) {
    padding: 0 0.8em;
  }
`,K=A.button.attrs(n=>({className:`${n.$active?"active":""} ${n.static?"static":""}`}))`
  ${dn}
  min-height: 2.5em;
  height: 2.5em;
  cursor: pointer;

  &:disabled {
    opacity: 0.6;
  }

  border-color: ${({theme:n,$variant:i})=>n.colors[i||"input"].color};

  @media (max-width: 700px) {
    height: max-content;
  }
`,jb=A.button.attrs(n=>({className:`${n.$active?"active":""} ${n.static?"static":""}`}))`
  ${dn}
  height: 2.5em;
  width: 3.35em;
  background-color: #00000063;
  align-self: center;
  cursor: pointer;
  border: unset;

  @media (min-width: 481px) {
    display: none;
  }

  &:hover:not(:disabled):not(.static) {
    background-color: #000000a3;
  }

  color: #cccccc !important;
`,xx=A.a.attrs(n=>({className:`${n.$active?"active":""} ${n.static?"static":""}`}))`
  ${dn}
  height: 2.5em;
  text-decoration: none;
  line-height: 2.5em;

  &:hover:not(:disabled):not(.static) {
    cursor: pointer;
  }

  border-color: ${({theme:n,$variant:i})=>n.colors[i||"input"].color};
`,yx=A.a.attrs(n=>({className:`${n.$active?"active":""} ${n.static?"static":""}`}))`
  ${dn}
  height: 2.5em;
  text-decoration: none;
  line-height: 2.5em;
  border: unset;
  background-color: #ffffff0a;
  color: #cccccc !important;

  &:hover:not(:disabled):not(.static) {
    background-color: #f9f9f921;
  }
`,et=A.label`
  display: block;
  margin-bottom: 10px;

  &[required]::after {
    content: '  *';
    color: red;
    font-size: 15px;
    font-weight: bolder;
  }
`,Sn=A(Ot).attrs(n=>({className:`${n.$active?"active":""} ${n.static?"static":""}`}))`
  ${dn}
  height: 2.5em;
  text-decoration: none;
  line-height: 2.5em;

  border-color: ${({theme:n,$variant:i})=>n.colors[i||"input"].color};
`,Sb=A(Ot).attrs(n=>({className:`${n.$active?"active":""} ${n.static?"static":""}`}))`
  ${dn}
  height: 2.5em;
  text-decoration: none;
  line-height: 2.5em;
  border: unset;
  background-color: #ffffff0a;
  color: #cccccc !important;

  &:hover:not(:disabled):not(.static) {
    background-color: #f9f9f921;
  }
`,Kn=A.input`
  ${dn}
  height: 2.5em;
`,wb=A.input.attrs({type:"radio"})`
  ${dn}
`,ei=A.select`
  ${dn}
  height: 2.5em;
  appearance: none;

  > option {
    background-color: ${({theme:n})=>n.colors.background};
    color: ${({theme:n})=>n.colors.text};
  }
`,_b=A.select`
  ${dn}
  height: 2.5em;
  appearance: listbox;
  background-color: #ffffff0a;
  color: #cccccc !important;

  &:hover:not(:disabled):not(.static) {
    background-color: #f9f9f921;
  }

  > option {
    color: black;
  }
`,on=A.textarea`
  ${dn}
  padding: 1em;

  &:focus::placeholder {
    color: transparent;
  }
`,ze=A.div`
  display: flex;
  flex-wrap: nowrap;

  > * {
    z-index: 1;
    margin: 0;
  }

  > :not(:last-child) {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
  }

  > :not(:first-child) {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    margin-left: -1px;
  }

  > .active:hover {
    z-index: 4;
  }

  > .active {
    z-index: 3;
  }

  > :hover {
    z-index: 2;
  }

  @media (max-width: 480px) {
    ${({$fixed:n})=>!n&&`
        * {
          padding-right: 0.4em;
          padding-left: 0.4em;
          font-size: 0.85em;
          svg {
            padding: 0;
            margin: 0 0.3em;
          }
        }
      `}
  }

  box-shadow: 3px 3px 1px ${({theme:n})=>n.colors.shadow};
  border-radius: 20px;
  width: fit-content;
  height: fit-content;
`,eg=A(ze)`
  box-shadow: none;
`,Gt=A.div`
  display: flex;
  flex-wrap: wrap;

  > * {
    margin-bottom: ${({marginb:n})=>n??"0.5em"};
    margin-right: 0.5em;
  }

  > :not(:last-child) {
    @media (max-width: 480px) {
      margin-bottom: 0.4em;
      margin-right: 0.3em;
    }
  }
`,jc=A.div`
  display: flex;
  justify-content: center;

  > * {
    width: ${({size:n})=>n??"inherit"};
    margin: 0.2em;
  }
`,Tb=A.b`
  color: ${({theme:n})=>n.colors.highlight.text};

  &:hover:not(:disabled):not(.static) {
    cursor: pointer;
    color: ${({theme:n})=>n.colors.highlight.active};
  }
`,bn=A.div`
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
`;bn.Head=A.h3`
  font-weight: bold;
  font-size: 1.5em;
  text-decoration: underline;
`;bn.Paragraph=A.div`
  margin: 0;
  border-top: 2px solid;
  padding: 2em 5em;

  @media (max-width: 720px) {
    padding: 1em;
  }

  border-color: ${({theme:n})=>n.colors.accent2};
`;bn.ParagraphALT=A.div`
  margin: 0;
  padding: 2em 5em;

  @media (max-width: 720px) {
    padding: 1em;
  }

  b {
    display: block;
  }

  border-color: ${({theme:n})=>n.colors.accent2};
`;var Od=Os(),ne=n=>Es(n,Od),Dd=Os();ne.write=n=>Es(n,Dd);var Sc=Os();ne.onStart=n=>Es(n,Sc);var Md=Os();ne.onFrame=n=>Es(n,Md);var zd=Os();ne.onFinish=n=>Es(n,zd);var Ki=[];ne.setTimeout=(n,i)=>{const r=ne.now()+i,c=()=>{const f=Ki.findIndex(h=>h.cancel==c);~f&&Ki.splice(f,1),Ca-=~f?1:0},u={time:r,handler:n,cancel:c};return Ki.splice(vx(r),0,u),Ca+=1,bx(),u};var vx=n=>~(~Ki.findIndex(i=>i.time>n)||~Ki.length);ne.cancel=n=>{Sc.delete(n),Md.delete(n),zd.delete(n),Od.delete(n),Dd.delete(n)};ne.sync=n=>{dd=!0,ne.batchedUpdates(n),dd=!1};ne.throttle=n=>{let i;function r(){try{n(...i)}finally{i=null}}function c(...u){i=u,ne.onStart(r)}return c.handler=n,c.cancel=()=>{Sc.delete(r),i=null},c};var Rd=typeof window<"u"?window.requestAnimationFrame:()=>{};ne.use=n=>Rd=n;ne.now=typeof performance<"u"?()=>performance.now():Date.now;ne.batchedUpdates=n=>n();ne.catch=console.error;ne.frameLoop="always";ne.advance=()=>{ne.frameLoop!=="demand"?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):Sx()};var Aa=-1,Ca=0,dd=!1;function Es(n,i){dd?(i.delete(n),n(0)):(i.add(n),bx())}function bx(){Aa<0&&(Aa=0,ne.frameLoop!=="demand"&&Rd(jx))}function Ab(){Aa=-1}function jx(){~Aa&&(Rd(jx),ne.batchedUpdates(Sx))}function Sx(){const n=Aa;Aa=ne.now();const i=vx(Aa);if(i&&(wx(Ki.splice(0,i),r=>r.handler()),Ca-=i),!Ca){Ab();return}Sc.flush(),Od.flush(n?Math.min(64,Aa-n):16.667),Md.flush(),Dd.flush(),zd.flush()}function Os(){let n=new Set,i=n;return{add(r){Ca+=i==n&&!n.has(r)?1:0,n.add(r)},delete(r){return Ca-=i==n&&n.has(r)?1:0,n.delete(r)},flush(r){i.size&&(n=new Set,Ca-=i.size,wx(i,c=>c(r)&&n.add(c)),Ca+=n.size,i=n)}}}function wx(n,i){n.forEach(r=>{try{i(r)}catch(c){ne.catch(c)}})}var Cb=Object.defineProperty,Eb=(n,i)=>{for(var r in i)Cb(n,r,{get:i[r],enumerable:!0})},un={};Eb(un,{assign:()=>Db,colors:()=>Ea,createStringInterpolator:()=>Bd,skipAnimation:()=>Tx,to:()=>_x,willAdvance:()=>Nd});function fd(){}var Ob=(n,i,r)=>Object.defineProperty(n,i,{value:r,writable:!0,configurable:!0}),G={arr:Array.isArray,obj:n=>!!n&&n.constructor.name==="Object",fun:n=>typeof n=="function",str:n=>typeof n=="string",num:n=>typeof n=="number",und:n=>n===void 0};function Yn(n,i){if(G.arr(n)){if(!G.arr(i)||n.length!==i.length)return!1;for(let r=0;r<n.length;r++)if(n[r]!==i[r])return!1;return!0}return n===i}var ce=(n,i)=>n.forEach(i);function Tn(n,i,r){if(G.arr(n)){for(let c=0;c<n.length;c++)i.call(r,n[c],`${c}`);return}for(const c in n)n.hasOwnProperty(c)&&i.call(r,n[c],c)}var $t=n=>G.und(n)?[]:G.arr(n)?n:[n];function cs(n,i){if(n.size){const r=Array.from(n);n.clear(),ce(r,i)}}var rs=(n,...i)=>cs(n,r=>r(...i)),kd=()=>typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),Bd,_x,Ea=null,Tx=!1,Nd=fd,Db=n=>{n.to&&(_x=n.to),n.now&&(ne.now=n.now),n.colors!==void 0&&(Ea=n.colors),n.skipAnimation!=null&&(Tx=n.skipAnimation),n.createStringInterpolator&&(Bd=n.createStringInterpolator),n.requestAnimationFrame&&ne.use(n.requestAnimationFrame),n.batchedUpdates&&(ne.batchedUpdates=n.batchedUpdates),n.willAdvance&&(Nd=n.willAdvance),n.frameLoop&&(ne.frameLoop=n.frameLoop)},os=new Set,en=[],ed=[],cc=0,wc={get idle(){return!os.size&&!en.length},start(n){cc>n.priority?(os.add(n),ne.onStart(Mb)):(Ax(n),ne(hd))},advance:hd,sort(n){if(cc)ne.onFrame(()=>wc.sort(n));else{const i=en.indexOf(n);~i&&(en.splice(i,1),Cx(n))}},clear(){en=[],os.clear()}};function Mb(){os.forEach(Ax),os.clear(),ne(hd)}function Ax(n){en.includes(n)||Cx(n)}function Cx(n){en.splice(zb(en,i=>i.priority>n.priority),0,n)}function hd(n){const i=ed;for(let r=0;r<en.length;r++){const c=en[r];cc=c.priority,c.idle||(Nd(c),c.advance(n),c.idle||i.push(c))}return cc=0,ed=en,ed.length=0,en=i,en.length>0}function zb(n,i){const r=n.findIndex(i);return r<0?n.length:r}var Rb={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},cn="[-+]?\\d*\\.?\\d+",oc=cn+"%";function _c(...n){return"\\(\\s*("+n.join(")\\s*,\\s*(")+")\\s*\\)"}var kb=new RegExp("rgb"+_c(cn,cn,cn)),Bb=new RegExp("rgba"+_c(cn,cn,cn,cn)),Nb=new RegExp("hsl"+_c(cn,oc,oc)),Ub=new RegExp("hsla"+_c(cn,oc,oc,cn)),Lb=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,Hb=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,qb=/^#([0-9a-fA-F]{6})$/,$b=/^#([0-9a-fA-F]{8})$/;function Gb(n){let i;return typeof n=="number"?n>>>0===n&&n>=0&&n<=4294967295?n:null:(i=qb.exec(n))?parseInt(i[1]+"ff",16)>>>0:Ea&&Ea[n]!==void 0?Ea[n]:(i=kb.exec(n))?(Yi(i[1])<<24|Yi(i[2])<<16|Yi(i[3])<<8|255)>>>0:(i=Bb.exec(n))?(Yi(i[1])<<24|Yi(i[2])<<16|Yi(i[3])<<8|ag(i[4]))>>>0:(i=Lb.exec(n))?parseInt(i[1]+i[1]+i[2]+i[2]+i[3]+i[3]+"ff",16)>>>0:(i=$b.exec(n))?parseInt(i[1],16)>>>0:(i=Hb.exec(n))?parseInt(i[1]+i[1]+i[2]+i[2]+i[3]+i[3]+i[4]+i[4],16)>>>0:(i=Nb.exec(n))?(tg(ng(i[1]),Ir(i[2]),Ir(i[3]))|255)>>>0:(i=Ub.exec(n))?(tg(ng(i[1]),Ir(i[2]),Ir(i[3]))|ag(i[4]))>>>0:null}function td(n,i,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?n+(i-n)*6*r:r<1/2?i:r<2/3?n+(i-n)*(2/3-r)*6:n}function tg(n,i,r){const c=r<.5?r*(1+i):r+i-r*i,u=2*r-c,f=td(u,c,n+1/3),h=td(u,c,n),m=td(u,c,n-1/3);return Math.round(f*255)<<24|Math.round(h*255)<<16|Math.round(m*255)<<8}function Yi(n){const i=parseInt(n,10);return i<0?0:i>255?255:i}function ng(n){return(parseFloat(n)%360+360)%360/360}function ag(n){const i=parseFloat(n);return i<0?0:i>1?255:Math.round(i*255)}function Ir(n){const i=parseFloat(n);return i<0?0:i>100?1:i/100}function ig(n){let i=Gb(n);if(i===null)return n;i=i||0;const r=(i&4278190080)>>>24,c=(i&16711680)>>>16,u=(i&65280)>>>8,f=(i&255)/255;return`rgba(${r}, ${c}, ${u}, ${f})`}var gs=(n,i,r)=>{if(G.fun(n))return n;if(G.arr(n))return gs({range:n,output:i,extrapolate:r});if(G.str(n.output[0]))return Bd(n);const c=n,u=c.output,f=c.range||[0,1],h=c.extrapolateLeft||c.extrapolate||"extend",m=c.extrapolateRight||c.extrapolate||"extend",x=c.easing||(g=>g);return g=>{const v=Yb(g,f);return Vb(g,f[v],f[v+1],u[v],u[v+1],x,h,m,c.map)}};function Vb(n,i,r,c,u,f,h,m,x){let g=x?x(n):n;if(g<i){if(h==="identity")return g;h==="clamp"&&(g=i)}if(g>r){if(m==="identity")return g;m==="clamp"&&(g=r)}return c===u?c:i===r?n<=i?c:u:(i===-1/0?g=-g:r===1/0?g=g-i:g=(g-i)/(r-i),g=f(g),c===-1/0?g=-g:u===1/0?g=g+c:g=g*(u-c)+c,g)}function Yb(n,i){for(var r=1;r<i.length-1&&!(i[r]>=n);++r);return r-1}var Xb={linear:n=>n},xs=Symbol.for("FluidValue.get"),Wi=Symbol.for("FluidValue.observers"),Pt=n=>!!(n&&n[xs]),Et=n=>n&&n[xs]?n[xs]():n,lg=n=>n[Wi]||null;function Qb(n,i){n.eventObserved?n.eventObserved(i):n(i)}function ys(n,i){const r=n[Wi];r&&r.forEach(c=>{Qb(c,i)})}var Ex=class{constructor(n){if(!n&&!(n=this.get))throw Error("Unknown getter");Zb(this,n)}},Zb=(n,i)=>Ox(n,xs,i);function tl(n,i){if(n[xs]){let r=n[Wi];r||Ox(n,Wi,r=new Set),r.has(i)||(r.add(i),n.observerAdded&&n.observerAdded(r.size,i))}return i}function vs(n,i){const r=n[Wi];if(r&&r.has(i)){const c=r.size-1;c?r.delete(i):n[Wi]=null,n.observerRemoved&&n.observerRemoved(c,i)}}var Ox=(n,i,r)=>Object.defineProperty(n,i,{value:r,writable:!0,configurable:!0}),ic=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,Kb=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,sg=new RegExp(`(${ic.source})(%|[a-z]+)`,"i"),Fb=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,Tc=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,Dx=n=>{const[i,r]=Jb(n);if(!i||kd())return n;const c=window.getComputedStyle(document.documentElement).getPropertyValue(i);if(c)return c.trim();if(r&&r.startsWith("--")){const u=window.getComputedStyle(document.documentElement).getPropertyValue(r);return u||n}else{if(r&&Tc.test(r))return Dx(r);if(r)return r}return n},Jb=n=>{const i=Tc.exec(n);if(!i)return[,];const[,r,c]=i;return[r,c]},nd,Wb=(n,i,r,c,u)=>`rgba(${Math.round(i)}, ${Math.round(r)}, ${Math.round(c)}, ${u})`,Mx=n=>{nd||(nd=Ea?new RegExp(`(${Object.keys(Ea).join("|")})(?!\\w)`,"g"):/^\b$/);const i=n.output.map(f=>Et(f).replace(Tc,Dx).replace(Kb,ig).replace(nd,ig)),r=i.map(f=>f.match(ic).map(Number)),u=r[0].map((f,h)=>r.map(m=>{if(!(h in m))throw Error('The arity of each "output" value must be equal');return m[h]})).map(f=>gs({...n,output:f}));return f=>{var x;const h=!sg.test(i[0])&&((x=i.find(g=>sg.test(g)))==null?void 0:x.replace(ic,""));let m=0;return i[0].replace(ic,()=>`${u[m++](f)}${h||""}`).replace(Fb,Wb)}},Ud="react-spring: ",zx=n=>{const i=n;let r=!1;if(typeof i!="function")throw new TypeError(`${Ud}once requires a function parameter`);return(...c)=>{r||(i(...c),r=!0)}},Pb=zx(console.warn);function Ib(){Pb(`${Ud}The "interpolate" function is deprecated in v9 (use "to" instead)`)}var ej=zx(console.warn);function tj(){ej(`${Ud}Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions`)}function Ac(n){return G.str(n)&&(n[0]=="#"||/\d/.test(n)||!kd()&&Tc.test(n)||n in(Ea||{}))}var Ld=kd()?S.useEffect:S.useLayoutEffect,nj=()=>{const n=S.useRef(!1);return Ld(()=>(n.current=!0,()=>{n.current=!1}),[]),n};function Rx(){const n=S.useState()[1],i=nj();return()=>{i.current&&n(Math.random())}}function aj(n,i){const[r]=S.useState(()=>({inputs:i,result:n()})),c=S.useRef(),u=c.current;let f=u;return f?i&&f.inputs&&ij(i,f.inputs)||(f={inputs:i,result:n()}):f=r,S.useEffect(()=>{c.current=f,u==r&&(r.inputs=r.result=void 0)},[f]),f.result}function ij(n,i){if(n.length!==i.length)return!1;for(let r=0;r<n.length;r++)if(n[r]!==i[r])return!1;return!0}var kx=n=>S.useEffect(n,lj),lj=[];function rg(n){const i=S.useRef();return S.useEffect(()=>{i.current=n}),i.current}var bs=Symbol.for("Animated:node"),sj=n=>!!n&&n[bs]===n,vn=n=>n&&n[bs],Hd=(n,i)=>Ob(n,bs,i),Cc=n=>n&&n[bs]&&n[bs].getPayload(),Bx=class{constructor(){Hd(this,this)}getPayload(){return this.payload||[]}},Ds=class extends Bx{constructor(n){super(),this._value=n,this.done=!0,this.durationProgress=0,G.num(this._value)&&(this.lastPosition=this._value)}static create(n){return new Ds(n)}getPayload(){return[this]}getValue(){return this._value}setValue(n,i){return G.num(n)&&(this.lastPosition=n,i&&(n=Math.round(n/i)*i,this.done&&(this.lastPosition=n))),this._value===n?!1:(this._value=n,!0)}reset(){const{done:n}=this;this.done=!1,G.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,n&&(this.lastVelocity=null),this.v0=null)}},js=class extends Ds{constructor(n){super(0),this._string=null,this._toString=gs({output:[n,n]})}static create(n){return new js(n)}getValue(){const n=this._string;return n??(this._string=this._toString(this._value))}setValue(n){if(G.str(n)){if(n==this._string)return!1;this._string=n,this._value=1}else if(super.setValue(n))this._string=null;else return!1;return!0}reset(n){n&&(this._toString=gs({output:[this.getValue(),n]})),this._value=0,super.reset()}},uc={dependencies:null},Ec=class extends Bx{constructor(n){super(),this.source=n,this.setValue(n)}getValue(n){const i={};return Tn(this.source,(r,c)=>{sj(r)?i[c]=r.getValue(n):Pt(r)?i[c]=Et(r):n||(i[c]=r)}),i}setValue(n){this.source=n,this.payload=this._makePayload(n)}reset(){this.payload&&ce(this.payload,n=>n.reset())}_makePayload(n){if(n){const i=new Set;return Tn(n,this._addToPayload,i),Array.from(i)}}_addToPayload(n){uc.dependencies&&Pt(n)&&uc.dependencies.add(n);const i=Cc(n);i&&ce(i,r=>this.add(r))}},Nx=class extends Ec{constructor(n){super(n)}static create(n){return new Nx(n)}getValue(){return this.source.map(n=>n.getValue())}setValue(n){const i=this.getPayload();return n.length==i.length?i.map((r,c)=>r.setValue(n[c])).some(Boolean):(super.setValue(n.map(rj)),!0)}};function rj(n){return(Ac(n)?js:Ds).create(n)}function md(n){const i=vn(n);return i?i.constructor:G.arr(n)?Nx:Ac(n)?js:Ds}var cg=(n,i)=>{const r=!G.fun(n)||n.prototype&&n.prototype.isReactComponent;return S.forwardRef((c,u)=>{const f=S.useRef(null),h=r&&S.useCallback(R=>{f.current=uj(u,R)},[u]),[m,x]=oj(c,i),g=Rx(),v=()=>{const R=f.current;if(r&&!R)return;(R?i.applyAnimatedValues(R,m.getValue(!0)):!1)===!1&&g()},w=new cj(v,x),j=S.useRef();Ld(()=>(j.current=w,ce(x,R=>tl(R,w)),()=>{j.current&&(ce(j.current.deps,R=>vs(R,j.current)),ne.cancel(j.current.update))})),S.useEffect(v,[]),kx(()=>()=>{const R=j.current;ce(R.deps,B=>vs(B,R))});const E=i.getComponentProps(m.getValue());return S.createElement(n,{...E,ref:h})})},cj=class{constructor(n,i){this.update=n,this.deps=i}eventObserved(n){n.type=="change"&&ne.write(this.update)}};function oj(n,i){const r=new Set;return uc.dependencies=r,n.style&&(n={...n,style:i.createAnimatedStyle(n.style)}),n=new Ec(n),uc.dependencies=null,[n,r]}function uj(n,i){return n&&(G.fun(n)?n(i):n.current=i),i}var og=Symbol.for("AnimatedComponent"),dj=(n,{applyAnimatedValues:i=()=>!1,createAnimatedStyle:r=u=>new Ec(u),getComponentProps:c=u=>u}={})=>{const u={applyAnimatedValues:i,createAnimatedStyle:r,getComponentProps:c},f=h=>{const m=ug(h)||"Anonymous";return G.str(h)?h=f[h]||(f[h]=cg(h,u)):h=h[og]||(h[og]=cg(h,u)),h.displayName=`Animated(${m})`,h};return Tn(n,(h,m)=>{G.arr(n)&&(m=ug(h)),f[m]=f(h)}),{animated:f}},ug=n=>G.str(n)?n:n&&G.str(n.displayName)?n.displayName:G.fun(n)&&n.name||null;function Ja(n,...i){return G.fun(n)?n(...i):n}var us=(n,i)=>n===!0||!!(i&&n&&(G.fun(n)?n(i):$t(n).includes(i))),Ux=(n,i)=>G.obj(n)?i&&n[i]:n,Lx=(n,i)=>n.default===!0?n[i]:n.default?n.default[i]:void 0,fj=n=>n,qd=(n,i=fj)=>{let r=hj;n.default&&n.default!==!0&&(n=n.default,r=Object.keys(n));const c={};for(const u of r){const f=i(n[u],u);G.und(f)||(c[u]=f)}return c},hj=["config","onProps","onStart","onChange","onPause","onResume","onRest"],mj={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function pj(n){const i={};let r=0;if(Tn(n,(c,u)=>{mj[u]||(i[u]=c,r++)}),r)return i}function Hx(n){const i=pj(n);if(i){const r={to:i};return Tn(n,(c,u)=>u in i||(r[u]=c)),r}return{...n}}function Ss(n){return n=Et(n),G.arr(n)?n.map(Ss):Ac(n)?un.createStringInterpolator({range:[0,1],output:[n,n]})(1):n}function gj(n){for(const i in n)return!0;return!1}function pd(n){return G.fun(n)||G.arr(n)&&G.obj(n[0])}function xj(n,i){var r;(r=n.ref)==null||r.delete(n),i==null||i.delete(n)}function yj(n,i){var r;i&&n.ref!==i&&((r=n.ref)==null||r.delete(n),i.add(n),n.ref=i)}var vj={default:{tension:170,friction:26}},gd={...vj.default,mass:1,damping:1,easing:Xb.linear,clamp:!1},bj=class{constructor(){this.velocity=0,Object.assign(this,gd)}};function jj(n,i,r){r&&(r={...r},dg(r,i),i={...r,...i}),dg(n,i),Object.assign(n,i);for(const h in gd)n[h]==null&&(n[h]=gd[h]);let{frequency:c,damping:u}=n;const{mass:f}=n;return G.und(c)||(c<.01&&(c=.01),u<0&&(u=0),n.tension=Math.pow(2*Math.PI/c,2)*f,n.friction=4*Math.PI*u*f/c),n}function dg(n,i){if(!G.und(i.decay))n.duration=void 0;else{const r=!G.und(i.tension)||!G.und(i.friction);(r||!G.und(i.frequency)||!G.und(i.damping)||!G.und(i.mass))&&(n.duration=void 0,n.decay=void 0),r&&(n.frequency=void 0)}}var fg=[],Sj=class{constructor(){this.changed=!1,this.values=fg,this.toValues=null,this.fromValues=fg,this.config=new bj,this.immediate=!1}};function qx(n,{key:i,props:r,defaultProps:c,state:u,actions:f}){return new Promise((h,m)=>{let x,g,v=us(r.cancel??(c==null?void 0:c.cancel),i);if(v)E();else{G.und(r.pause)||(u.paused=us(r.pause,i));let R=c==null?void 0:c.pause;R!==!0&&(R=u.paused||us(R,i)),x=Ja(r.delay||0,i),R?(u.resumeQueue.add(j),f.pause()):(f.resume(),j())}function w(){u.resumeQueue.add(j),u.timeouts.delete(g),g.cancel(),x=g.time-ne.now()}function j(){x>0&&!un.skipAnimation?(u.delayed=!0,g=ne.setTimeout(E,x),u.pauseQueue.add(w),u.timeouts.add(g)):E()}function E(){u.delayed&&(u.delayed=!1),u.pauseQueue.delete(w),u.timeouts.delete(g),n<=(u.cancelId||0)&&(v=!0);try{f.start({...r,callId:n,cancel:v},h)}catch(R){m(R)}}})}var $d=(n,i)=>i.length==1?i[0]:i.some(r=>r.cancelled)?Fi(n.get()):i.every(r=>r.noop)?$x(n.get()):rn(n.get(),i.every(r=>r.finished)),$x=n=>({value:n,noop:!0,finished:!0,cancelled:!1}),rn=(n,i,r=!1)=>({value:n,finished:i,cancelled:r}),Fi=n=>({value:n,cancelled:!0,finished:!1});function Gx(n,i,r,c){const{callId:u,parentId:f,onRest:h}=i,{asyncTo:m,promise:x}=r;return!f&&n===m&&!i.reset?x:r.promise=(async()=>{r.asyncId=u,r.asyncTo=n;const g=qd(i,(z,H)=>H==="onRest"?void 0:z);let v,w;const j=new Promise((z,H)=>(v=z,w=H)),E=z=>{const H=u<=(r.cancelId||0)&&Fi(c)||u!==r.asyncId&&rn(c,!1);if(H)throw z.result=H,w(z),z},R=(z,H)=>{const q=new hg,V=new mg;return(async()=>{if(un.skipAnimation)throw ws(r),V.result=rn(c,!1),w(V),V;E(q);const X=G.obj(z)?{...z}:{...H,to:z};X.parentId=u,Tn(g,(ee,de)=>{G.und(X[de])&&(X[de]=ee)});const Z=await c.start(X);return E(q),r.paused&&await new Promise(ee=>{r.resumeQueue.add(ee)}),Z})()};let B;if(un.skipAnimation)return ws(r),rn(c,!1);try{let z;G.arr(n)?z=(async H=>{for(const q of H)await R(q)})(n):z=Promise.resolve(n(R,c.stop.bind(c))),await Promise.all([z.then(v),j]),B=rn(c.get(),!0,!1)}catch(z){if(z instanceof hg)B=z.result;else if(z instanceof mg)B=z.result;else throw z}finally{u==r.asyncId&&(r.asyncId=f,r.asyncTo=f?m:void 0,r.promise=f?x:void 0)}return G.fun(h)&&ne.batchedUpdates(()=>{h(B,c,c.item)}),B})()}function ws(n,i){cs(n.timeouts,r=>r.cancel()),n.pauseQueue.clear(),n.resumeQueue.clear(),n.asyncId=n.asyncTo=n.promise=void 0,i&&(n.cancelId=i)}var hg=class extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise.")}},mg=class extends Error{constructor(){super("SkipAnimationSignal")}},xd=n=>n instanceof Gd,wj=1,Gd=class extends Ex{constructor(){super(...arguments),this.id=wj++,this._priority=0}get priority(){return this._priority}set priority(n){this._priority!=n&&(this._priority=n,this._onPriorityChange(n))}get(){const n=vn(this);return n&&n.getValue()}to(...n){return un.to(this,n)}interpolate(...n){return Ib(),un.to(this,n)}toJSON(){return this.get()}observerAdded(n){n==1&&this._attach()}observerRemoved(n){n==0&&this._detach()}_attach(){}_detach(){}_onChange(n,i=!1){ys(this,{type:"change",parent:this,value:n,idle:i})}_onPriorityChange(n){this.idle||wc.sort(this),ys(this,{type:"priority",parent:this,priority:n})}},ti=Symbol.for("SpringPhase"),Vx=1,Yx=2,Xx=4,ad=n=>(n[ti]&Vx)>0,Sa=n=>(n[ti]&Yx)>0,es=n=>(n[ti]&Xx)>0,pg=(n,i)=>i?n[ti]|=Yx|Vx:n[ti]&=-3,gg=(n,i)=>i?n[ti]|=Xx:n[ti]&=-5,_j=class extends Gd{constructor(n,i){if(super(),this.animation=new Sj,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!G.und(n)||!G.und(i)){const r=G.obj(n)?{...n}:{...i,from:n};G.und(r.default)&&(r.default=!0),this.start(r)}}get idle(){return!(Sa(this)||this._state.asyncTo)||es(this)}get goal(){return Et(this.animation.to)}get velocity(){const n=vn(this);return n instanceof Ds?n.lastVelocity||0:n.getPayload().map(i=>i.lastVelocity||0)}get hasAnimated(){return ad(this)}get isAnimating(){return Sa(this)}get isPaused(){return es(this)}get isDelayed(){return this._state.delayed}advance(n){let i=!0,r=!1;const c=this.animation;let{toValues:u}=c;const{config:f}=c,h=Cc(c.to);!h&&Pt(c.to)&&(u=$t(Et(c.to))),c.values.forEach((g,v)=>{if(g.done)return;const w=g.constructor==js?1:h?h[v].lastPosition:u[v];let j=c.immediate,E=w;if(!j){if(E=g.lastPosition,f.tension<=0){g.done=!0;return}let R=g.elapsedTime+=n;const B=c.fromValues[v],z=g.v0!=null?g.v0:g.v0=G.arr(f.velocity)?f.velocity[v]:f.velocity;let H;const q=f.precision||(B==w?.005:Math.min(1,Math.abs(w-B)*.001));if(G.und(f.duration))if(f.decay){const V=f.decay===!0?.998:f.decay,X=Math.exp(-(1-V)*R);E=B+z/(1-V)*(1-X),j=Math.abs(g.lastPosition-E)<=q,H=z*X}else{H=g.lastVelocity==null?z:g.lastVelocity;const V=f.restVelocity||q/10,X=f.clamp?0:f.bounce,Z=!G.und(X),ee=B==w?g.v0>0:B<w;let de,tt=!1;const oe=1,Mt=Math.ceil(n/oe);for(let nt=0;nt<Mt&&(de=Math.abs(H)>V,!(!de&&(j=Math.abs(w-E)<=q,j)));++nt){Z&&(tt=E==w||E>w==ee,tt&&(H=-H*X,E=w));const Je=-f.tension*1e-6*(E-w),nn=-f.friction*.001*H,Ma=(Je+nn)/f.mass;H=H+Ma*oe,E=E+H*oe}}else{let V=1;f.duration>0&&(this._memoizedDuration!==f.duration&&(this._memoizedDuration=f.duration,g.durationProgress>0&&(g.elapsedTime=f.duration*g.durationProgress,R=g.elapsedTime+=n)),V=(f.progress||0)+R/this._memoizedDuration,V=V>1?1:V<0?0:V,g.durationProgress=V),E=B+f.easing(V)*(w-B),H=(E-g.lastPosition)/n,j=V==1}g.lastVelocity=H,Number.isNaN(E)&&(console.warn("Got NaN while animating:",this),j=!0)}h&&!h[v].done&&(j=!1),j?g.done=!0:i=!1,g.setValue(E,f.round)&&(r=!0)});const m=vn(this),x=m.getValue();if(i){const g=Et(c.to);(x!==g||r)&&!f.decay?(m.setValue(g),this._onChange(g)):r&&f.decay&&this._onChange(x),this._stop()}else r&&this._onChange(x)}set(n){return ne.batchedUpdates(()=>{this._stop(),this._focus(n),this._set(n)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(Sa(this)){const{to:n,config:i}=this.animation;ne.batchedUpdates(()=>{this._onStart(),i.decay||this._set(n,!1),this._stop()})}return this}update(n){return(this.queue||(this.queue=[])).push(n),this}start(n,i){let r;return G.und(n)?(r=this.queue||[],this.queue=[]):r=[G.obj(n)?n:{...i,to:n}],Promise.all(r.map(c=>this._update(c))).then(c=>$d(this,c))}stop(n){const{to:i}=this.animation;return this._focus(this.get()),ws(this._state,n&&this._lastCallId),ne.batchedUpdates(()=>this._stop(i,n)),this}reset(){this._update({reset:!0})}eventObserved(n){n.type=="change"?this._start():n.type=="priority"&&(this.priority=n.priority+1)}_prepareNode(n){const i=this.key||"";let{to:r,from:c}=n;r=G.obj(r)?r[i]:r,(r==null||pd(r))&&(r=void 0),c=G.obj(c)?c[i]:c,c==null&&(c=void 0);const u={to:r,from:c};return ad(this)||(n.reverse&&([r,c]=[c,r]),c=Et(c),G.und(c)?vn(this)||this._set(r):this._set(c)),u}_update({...n},i){const{key:r,defaultProps:c}=this;n.default&&Object.assign(c,qd(n,(h,m)=>/^on/.test(m)?Ux(h,r):h)),yg(this,n,"onProps"),ns(this,"onProps",n,this);const u=this._prepareNode(n);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");const f=this._state;return qx(++this._lastCallId,{key:r,props:n,defaultProps:c,state:f,actions:{pause:()=>{es(this)||(gg(this,!0),rs(f.pauseQueue),ns(this,"onPause",rn(this,ts(this,this.animation.to)),this))},resume:()=>{es(this)&&(gg(this,!1),Sa(this)&&this._resume(),rs(f.resumeQueue),ns(this,"onResume",rn(this,ts(this,this.animation.to)),this))},start:this._merge.bind(this,u)}}).then(h=>{if(n.loop&&h.finished&&!(i&&h.noop)){const m=Qx(n);if(m)return this._update(m,!0)}return h})}_merge(n,i,r){if(i.cancel)return this.stop(!0),r(Fi(this));const c=!G.und(n.to),u=!G.und(n.from);if(c||u)if(i.callId>this._lastToId)this._lastToId=i.callId;else return r(Fi(this));const{key:f,defaultProps:h,animation:m}=this,{to:x,from:g}=m;let{to:v=x,from:w=g}=n;u&&!c&&(!i.default||G.und(v))&&(v=w),i.reverse&&([v,w]=[w,v]);const j=!Yn(w,g);j&&(m.from=w),w=Et(w);const E=!Yn(v,x);E&&this._focus(v);const R=pd(i.to),{config:B}=m,{decay:z,velocity:H}=B;(c||u)&&(B.velocity=0),i.config&&!R&&jj(B,Ja(i.config,f),i.config!==h.config?Ja(h.config,f):void 0);let q=vn(this);if(!q||G.und(v))return r(rn(this,!0));const V=G.und(i.reset)?u&&!i.default:!G.und(w)&&us(i.reset,f),X=V?w:this.get(),Z=Ss(v),ee=G.num(Z)||G.arr(Z)||Ac(Z),de=!R&&(!ee||us(h.immediate||i.immediate,f));if(E){const nt=md(v);if(nt!==q.constructor)if(de)q=this._set(Z);else throw Error(`Cannot animate between ${q.constructor.name} and ${nt.name}, as the "to" prop suggests`)}const tt=q.constructor;let oe=Pt(v),Mt=!1;if(!oe){const nt=V||!ad(this)&&j;(E||nt)&&(Mt=Yn(Ss(X),Z),oe=!Mt),(!Yn(m.immediate,de)&&!de||!Yn(B.decay,z)||!Yn(B.velocity,H))&&(oe=!0)}if(Mt&&Sa(this)&&(m.changed&&!V?oe=!0:oe||this._stop(x)),!R&&((oe||Pt(x))&&(m.values=q.getPayload(),m.toValues=Pt(v)?null:tt==js?[1]:$t(Z)),m.immediate!=de&&(m.immediate=de,!de&&!V&&this._set(x)),oe)){const{onRest:nt}=m;ce(Aj,nn=>yg(this,i,nn));const Je=rn(this,ts(this,x));rs(this._pendingCalls,Je),this._pendingCalls.add(r),m.changed&&ne.batchedUpdates(()=>{var nn;m.changed=!V,nt==null||nt(Je,this),V?Ja(h.onRest,Je):(nn=m.onStart)==null||nn.call(m,Je,this)})}V&&this._set(X),R?r(Gx(i.to,i,this._state,this)):oe?this._start():Sa(this)&&!E?this._pendingCalls.add(r):r($x(X))}_focus(n){const i=this.animation;n!==i.to&&(lg(this)&&this._detach(),i.to=n,lg(this)&&this._attach())}_attach(){let n=0;const{to:i}=this.animation;Pt(i)&&(tl(i,this),xd(i)&&(n=i.priority+1)),this.priority=n}_detach(){const{to:n}=this.animation;Pt(n)&&vs(n,this)}_set(n,i=!0){const r=Et(n);if(!G.und(r)){const c=vn(this);if(!c||!Yn(r,c.getValue())){const u=md(r);!c||c.constructor!=u?Hd(this,u.create(r)):c.setValue(r),c&&ne.batchedUpdates(()=>{this._onChange(r,i)})}}return vn(this)}_onStart(){const n=this.animation;n.changed||(n.changed=!0,ns(this,"onStart",rn(this,ts(this,n.to)),this))}_onChange(n,i){i||(this._onStart(),Ja(this.animation.onChange,n,this)),Ja(this.defaultProps.onChange,n,this),super._onChange(n,i)}_start(){const n=this.animation;vn(this).reset(Et(n.to)),n.immediate||(n.fromValues=n.values.map(i=>i.lastPosition)),Sa(this)||(pg(this,!0),es(this)||this._resume())}_resume(){un.skipAnimation?this.finish():wc.start(this)}_stop(n,i){if(Sa(this)){pg(this,!1);const r=this.animation;ce(r.values,u=>{u.done=!0}),r.toValues&&(r.onChange=r.onPause=r.onResume=void 0),ys(this,{type:"idle",parent:this});const c=i?Fi(this.get()):rn(this.get(),ts(this,n??r.to));rs(this._pendingCalls,c),r.changed&&(r.changed=!1,ns(this,"onRest",c,this))}}};function ts(n,i){const r=Ss(i),c=Ss(n.get());return Yn(c,r)}function Qx(n,i=n.loop,r=n.to){const c=Ja(i);if(c){const u=c!==!0&&Hx(c),f=(u||n).reverse,h=!u||u.reset;return _s({...n,loop:i,default:!1,pause:void 0,to:!f||pd(r)?r:void 0,from:h?n.from:void 0,reset:h,...u})}}function _s(n){const{to:i,from:r}=n=Hx(n),c=new Set;return G.obj(i)&&xg(i,c),G.obj(r)&&xg(r,c),n.keys=c.size?Array.from(c):null,n}function Tj(n){const i=_s(n);return G.und(i.default)&&(i.default=qd(i)),i}function xg(n,i){Tn(n,(r,c)=>r!=null&&i.add(c))}var Aj=["onStart","onRest","onChange","onPause","onResume"];function yg(n,i,r){n.animation[r]=i[r]!==Lx(i,r)?Ux(i[r],n.key):void 0}function ns(n,i,...r){var c,u,f,h;(u=(c=n.animation)[i])==null||u.call(c,...r),(h=(f=n.defaultProps)[i])==null||h.call(f,...r)}var Cj=["onStart","onChange","onRest"],Ej=1,Oj=class{constructor(i,r){this.id=Ej++,this.springs={},this.queue=[],this._lastAsyncId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),r&&(this._flush=r),i&&this.start({default:!0,...i})}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(i=>i.idle&&!i.isDelayed&&!i.isPaused)}get item(){return this._item}set item(i){this._item=i}get(){const i={};return this.each((r,c)=>i[c]=r.get()),i}set(i){for(const r in i){const c=i[r];G.und(c)||this.springs[r].set(c)}}update(i){return i&&this.queue.push(_s(i)),this}start(i){let{queue:r}=this;return i?r=$t(i).map(_s):this.queue=[],this._flush?this._flush(this,r):(Wx(this,r),yd(this,r))}stop(i,r){if(i!==!!i&&(r=i),r){const c=this.springs;ce($t(r),u=>c[u].stop(!!i))}else ws(this._state,this._lastAsyncId),this.each(c=>c.stop(!!i));return this}pause(i){if(G.und(i))this.start({pause:!0});else{const r=this.springs;ce($t(i),c=>r[c].pause())}return this}resume(i){if(G.und(i))this.start({pause:!1});else{const r=this.springs;ce($t(i),c=>r[c].resume())}return this}each(i){Tn(this.springs,i)}_onFrame(){const{onStart:i,onChange:r,onRest:c}=this._events,u=this._active.size>0,f=this._changed.size>0;(u&&!this._started||f&&!this._started)&&(this._started=!0,cs(i,([x,g])=>{g.value=this.get(),x(g,this,this._item)}));const h=!u&&this._started,m=f||h&&c.size?this.get():null;f&&r.size&&cs(r,([x,g])=>{g.value=m,x(g,this,this._item)}),h&&(this._started=!1,cs(c,([x,g])=>{g.value=m,x(g,this,this._item)}))}eventObserved(i){if(i.type=="change")this._changed.add(i.parent),i.idle||this._active.add(i.parent);else if(i.type=="idle")this._active.delete(i.parent);else return;ne.onFrame(this._onFrame)}};function yd(n,i){return Promise.all(i.map(r=>Zx(n,r))).then(r=>$d(n,r))}async function Zx(n,i,r){const{keys:c,to:u,from:f,loop:h,onRest:m,onResolve:x}=i,g=G.obj(i.default)&&i.default;h&&(i.loop=!1),u===!1&&(i.to=null),f===!1&&(i.from=null);const v=G.arr(u)||G.fun(u)?u:void 0;v?(i.to=void 0,i.onRest=void 0,g&&(g.onRest=void 0)):ce(Cj,B=>{const z=i[B];if(G.fun(z)){const H=n._events[B];i[B]=({finished:q,cancelled:V})=>{const X=H.get(z);X?(q||(X.finished=!1),V&&(X.cancelled=!0)):H.set(z,{value:null,finished:q||!1,cancelled:V||!1})},g&&(g[B]=i[B])}});const w=n._state;i.pause===!w.paused?(w.paused=i.pause,rs(i.pause?w.pauseQueue:w.resumeQueue)):w.paused&&(i.pause=!0);const j=(c||Object.keys(n.springs)).map(B=>n.springs[B].start(i)),E=i.cancel===!0||Lx(i,"cancel")===!0;(v||E&&w.asyncId)&&j.push(qx(++n._lastAsyncId,{props:i,state:w,actions:{pause:fd,resume:fd,start(B,z){E?(ws(w,n._lastAsyncId),z(Fi(n))):(B.onRest=m,z(Gx(v,B,w,n)))}}})),w.paused&&await new Promise(B=>{w.resumeQueue.add(B)});const R=$d(n,await Promise.all(j));if(h&&R.finished&&!(r&&R.noop)){const B=Qx(i,h,u);if(B)return Wx(n,[B]),Zx(n,B,!0)}return x&&ne.batchedUpdates(()=>x(R,n,n.item)),R}function vg(n,i){const r={...n.springs};return i&&ce($t(i),c=>{G.und(c.keys)&&(c=_s(c)),G.obj(c.to)||(c={...c,to:void 0}),Jx(r,c,u=>Fx(u))}),Kx(n,r),r}function Kx(n,i){Tn(i,(r,c)=>{n.springs[c]||(n.springs[c]=r,tl(r,n))})}function Fx(n,i){const r=new _j;return r.key=n,i&&tl(r,i),r}function Jx(n,i,r){i.keys&&ce(i.keys,c=>{(n[c]||(n[c]=r(c)))._prepareNode(i)})}function Wx(n,i){ce(i,r=>{Jx(n.springs,r,c=>Fx(c,n))})}var Oc=({children:n,...i})=>{const r=S.useContext(dc),c=i.pause||!!r.pause,u=i.immediate||!!r.immediate;i=aj(()=>({pause:c,immediate:u}),[c,u]);const{Provider:f}=dc;return S.createElement(f,{value:i},n)},dc=Dj(Oc,{});Oc.Provider=dc.Provider;Oc.Consumer=dc.Consumer;function Dj(n,i){return Object.assign(n,S.createContext(i)),n.Provider._context=n,n.Consumer._context=n,n}var Mj=()=>{const n=[],i=function(c){tj();const u=[];return ce(n,(f,h)=>{if(G.und(c))u.push(f.start());else{const m=r(c,f,h);m&&u.push(f.start(m))}}),u};i.current=n,i.add=function(c){n.includes(c)||n.push(c)},i.delete=function(c){const u=n.indexOf(c);~u&&n.splice(u,1)},i.pause=function(){return ce(n,c=>c.pause(...arguments)),this},i.resume=function(){return ce(n,c=>c.resume(...arguments)),this},i.set=function(c){ce(n,(u,f)=>{const h=G.fun(c)?c(f,u):c;h&&u.set(h)})},i.start=function(c){const u=[];return ce(n,(f,h)=>{if(G.und(c))u.push(f.start());else{const m=this._getProps(c,f,h);m&&u.push(f.start(m))}}),u},i.stop=function(){return ce(n,c=>c.stop(...arguments)),this},i.update=function(c){return ce(n,(u,f)=>u.update(this._getProps(c,u,f))),this};const r=function(c,u,f){return G.fun(c)?c(f,u):c};return i._getProps=r,i};function zj(n,i,r){const c=G.fun(i)&&i;c&&!r&&(r=[]);const u=S.useMemo(()=>c||arguments.length==3?Mj():void 0,[]),f=S.useRef(0),h=Rx(),m=S.useMemo(()=>({ctrls:[],queue:[],flush(H,q){const V=vg(H,q);return f.current>0&&!m.queue.length&&!Object.keys(V).some(Z=>!H.springs[Z])?yd(H,q):new Promise(Z=>{Kx(H,V),m.queue.push(()=>{Z(yd(H,q))}),h()})}}),[]),x=S.useRef([...m.ctrls]),g=[],v=rg(n)||0;S.useMemo(()=>{ce(x.current.slice(n,v),H=>{xj(H,u),H.stop(!0)}),x.current.length=n,w(v,n)},[n]),S.useMemo(()=>{w(0,Math.min(v,n))},r);function w(H,q){for(let V=H;V<q;V++){const X=x.current[V]||(x.current[V]=new Oj(null,m.flush)),Z=c?c(V,X):i[V];Z&&(g[V]=Tj(Z))}}const j=x.current.map((H,q)=>vg(H,g[q])),E=S.useContext(Oc),R=rg(E),B=E!==R&&gj(E);Ld(()=>{f.current++,m.ctrls=x.current;const{queue:H}=m;H.length&&(m.queue=[],ce(H,q=>q())),ce(x.current,(q,V)=>{u==null||u.add(q),B&&q.start({default:E});const X=g[V];X&&(yj(q,X.ref),q.ref?q.queue.push(X):q.start(X))})}),kx(()=>()=>{ce(m.ctrls,H=>H.stop(!0))});const z=j.map(H=>({...H}));return u?[z,u]:z}function Rj(n,i){const r=G.fun(n),[[c],u]=zj(1,r?n:[n],r?[]:i);return r||arguments.length==2?[c,u]:c}var kj=class extends Gd{constructor(n,i){super(),this.source=n,this.idle=!0,this._active=new Set,this.calc=gs(...i);const r=this._get(),c=md(r);Hd(this,c.create(r))}advance(n){const i=this._get(),r=this.get();Yn(i,r)||(vn(this).setValue(i),this._onChange(i,this.idle)),!this.idle&&bg(this._active)&&id(this)}_get(){const n=G.arr(this.source)?this.source.map(Et):$t(Et(this.source));return this.calc(...n)}_start(){this.idle&&!bg(this._active)&&(this.idle=!1,ce(Cc(this),n=>{n.done=!1}),un.skipAnimation?(ne.batchedUpdates(()=>this.advance()),id(this)):wc.start(this))}_attach(){let n=1;ce($t(this.source),i=>{Pt(i)&&tl(i,this),xd(i)&&(i.idle||this._active.add(i),n=Math.max(n,i.priority+1))}),this.priority=n,this._start()}_detach(){ce($t(this.source),n=>{Pt(n)&&vs(n,this)}),this._active.clear(),id(this)}eventObserved(n){n.type=="change"?n.idle?this.advance():(this._active.add(n.parent),this._start()):n.type=="idle"?this._active.delete(n.parent):n.type=="priority"&&(this.priority=$t(this.source).reduce((i,r)=>Math.max(i,(xd(r)?r.priority:0)+1),0))}};function Bj(n){return n.idle!==!1}function bg(n){return!n.size||Array.from(n).every(Bj)}function id(n){n.idle||(n.idle=!0,ce(Cc(n),i=>{i.done=!0}),ys(n,{type:"idle",parent:n}))}un.assign({createStringInterpolator:Mx,to:(n,i)=>new kj(n,i)});var Px=/^--/;function Nj(n,i){return i==null||typeof i=="boolean"||i===""?"":typeof i=="number"&&i!==0&&!Px.test(n)&&!(ds.hasOwnProperty(n)&&ds[n])?i+"px":(""+i).trim()}var jg={};function Uj(n,i){if(!n.nodeType||!n.setAttribute)return!1;const r=n.nodeName==="filter"||n.parentNode&&n.parentNode.nodeName==="filter",{className:c,style:u,children:f,scrollTop:h,scrollLeft:m,viewBox:x,...g}=i,v=Object.values(g),w=Object.keys(g).map(j=>r||n.hasAttribute(j)?j:jg[j]||(jg[j]=j.replace(/([A-Z])/g,E=>"-"+E.toLowerCase())));f!==void 0&&(n.textContent=f);for(const j in u)if(u.hasOwnProperty(j)){const E=Nj(j,u[j]);Px.test(j)?n.style.setProperty(j,E):n.style[j]=E}w.forEach((j,E)=>{n.setAttribute(j,v[E])}),c!==void 0&&(n.className=c),h!==void 0&&(n.scrollTop=h),m!==void 0&&(n.scrollLeft=m),x!==void 0&&n.setAttribute("viewBox",x)}var ds={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,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},Lj=(n,i)=>n+i.charAt(0).toUpperCase()+i.substring(1),Hj=["Webkit","Ms","Moz","O"];ds=Object.keys(ds).reduce((n,i)=>(Hj.forEach(r=>n[Lj(r,i)]=n[i]),n),ds);var qj=/^(matrix|translate|scale|rotate|skew)/,$j=/^(translate)/,Gj=/^(rotate|skew)/,ld=(n,i)=>G.num(n)&&n!==0?n+i:n,lc=(n,i)=>G.arr(n)?n.every(r=>lc(r,i)):G.num(n)?n===i:parseFloat(n)===i,Vj=class extends Ec{constructor({x:n,y:i,z:r,...c}){const u=[],f=[];(n||i||r)&&(u.push([n||0,i||0,r||0]),f.push(h=>[`translate3d(${h.map(m=>ld(m,"px")).join(",")})`,lc(h,0)])),Tn(c,(h,m)=>{if(m==="transform")u.push([h||""]),f.push(x=>[x,x===""]);else if(qj.test(m)){if(delete c[m],G.und(h))return;const x=$j.test(m)?"px":Gj.test(m)?"deg":"";u.push($t(h)),f.push(m==="rotate3d"?([g,v,w,j])=>[`rotate3d(${g},${v},${w},${ld(j,x)})`,lc(j,0)]:g=>[`${m}(${g.map(v=>ld(v,x)).join(",")})`,lc(g,m.startsWith("scale")?1:0)])}}),u.length&&(c.transform=new Yj(u,f)),super(c)}},Yj=class extends Ex{constructor(n,i){super(),this.inputs=n,this.transforms=i,this._value=null}get(){return this._value||(this._value=this._get())}_get(){let n="",i=!0;return ce(this.inputs,(r,c)=>{const u=Et(r[0]),[f,h]=this.transforms[c](G.arr(u)?u:r.map(Et));n+=" "+f,i=i&&h}),i?"none":n}observerAdded(n){n==1&&ce(this.inputs,i=>ce(i,r=>Pt(r)&&tl(r,this)))}observerRemoved(n){n==0&&ce(this.inputs,i=>ce(i,r=>Pt(r)&&vs(r,this)))}eventObserved(n){n.type=="change"&&(this._value=null),ys(this,n)}},Xj=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"];un.assign({batchedUpdates:hx.unstable_batchedUpdates,createStringInterpolator:Mx,colors:Rb});var Qj=dj(Xj,{applyAnimatedValues:Uj,createAnimatedStyle:n=>new Vj(n),getComponentProps:({scrollTop:n,scrollLeft:i,...r})=>r}),Zj=Qj.animated;function Kj(n,i,r){return Math.max(i,Math.min(n,r))}const xt={toVector(n,i){return n===void 0&&(n=i),Array.isArray(n)?n:[n,n]},add(n,i){return[n[0]+i[0],n[1]+i[1]]},sub(n,i){return[n[0]-i[0],n[1]-i[1]]},addTo(n,i){n[0]+=i[0],n[1]+=i[1]},subTo(n,i){n[0]-=i[0],n[1]-=i[1]}};function Sg(n,i,r){return i===0||Math.abs(i)===1/0?Math.pow(n,r*5):n*i*r/(i+r*n)}function wg(n,i,r,c=.15){return c===0?Kj(n,i,r):n<i?-Sg(i-n,r-i,c)+i:n>r?+Sg(n-r,r-i,c)+r:n}function Fj(n,[i,r],[c,u]){const[[f,h],[m,x]]=n;return[wg(i,f,h,c),wg(r,m,x,u)]}function Jj(n,i){if(typeof n!="object"||n===null)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var c=r.call(n,i);if(typeof c!="object")return c;throw new TypeError("@@toPrimitive must return a primitive value.")}return(i==="string"?String:Number)(n)}function Wj(n){var i=Jj(n,"string");return typeof i=="symbol"?i:String(i)}function Ct(n,i,r){return i=Wj(i),i in n?Object.defineProperty(n,i,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[i]=r,n}function _g(n,i){var r=Object.keys(n);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(n);i&&(c=c.filter(function(u){return Object.getOwnPropertyDescriptor(n,u).enumerable})),r.push.apply(r,c)}return r}function Le(n){for(var i=1;i<arguments.length;i++){var r=arguments[i]!=null?arguments[i]:{};i%2?_g(Object(r),!0).forEach(function(c){Ct(n,c,r[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(r)):_g(Object(r)).forEach(function(c){Object.defineProperty(n,c,Object.getOwnPropertyDescriptor(r,c))})}return n}const Ix={pointer:{start:"down",change:"move",end:"up"},mouse:{start:"down",change:"move",end:"up"},touch:{start:"start",change:"move",end:"end"},gesture:{start:"start",change:"change",end:"end"}};function Tg(n){return n?n[0].toUpperCase()+n.slice(1):""}const Pj=["enter","leave"];function Ij(n=!1,i){return n&&!Pj.includes(i)}function eS(n,i="",r=!1){const c=Ix[n],u=c&&c[i]||i;return"on"+Tg(n)+Tg(u)+(Ij(r,u)?"Capture":"")}const tS=["gotpointercapture","lostpointercapture"];function nS(n){let i=n.substring(2).toLowerCase();const r=!!~i.indexOf("passive");r&&(i=i.replace("passive",""));const c=tS.includes(i)?"capturecapture":"capture",u=!!~i.indexOf(c);return u&&(i=i.replace("capture","")),{device:i,capture:u,passive:r}}function aS(n,i=""){const r=Ix[n],c=r&&r[i]||i;return n+c}function Dc(n){return"touches"in n}function e0(n){return Dc(n)?"touch":"pointerType"in n?n.pointerType:"mouse"}function iS(n){return Array.from(n.touches).filter(i=>{var r,c;return i.target===n.currentTarget||((r=n.currentTarget)===null||r===void 0||(c=r.contains)===null||c===void 0?void 0:c.call(r,i.target))})}function lS(n){return n.type==="touchend"||n.type==="touchcancel"?n.changedTouches:n.targetTouches}function t0(n){return Dc(n)?lS(n)[0]:n}function sS(n){return iS(n).map(i=>i.identifier)}function sd(n){const i=t0(n);return Dc(n)?i.identifier:i.pointerId}function Ag(n){const i=t0(n);return[i.clientX,i.clientY]}function rS(n){const i={};if("buttons"in n&&(i.buttons=n.buttons),"shiftKey"in n){const{shiftKey:r,altKey:c,metaKey:u,ctrlKey:f}=n;Object.assign(i,{shiftKey:r,altKey:c,metaKey:u,ctrlKey:f})}return i}function fc(n,...i){return typeof n=="function"?n(...i):n}function cS(){}function oS(...n){return n.length===0?cS:n.length===1?n[0]:function(){let i;for(const r of n)i=r.apply(this,arguments)||i;return i}}function Cg(n,i){return Object.assign({},i,n||{})}const uS=32;class dS{constructor(i,r,c){this.ctrl=i,this.args=r,this.key=c,this.state||(this.state={},this.computeValues([0,0]),this.computeInitial(),this.init&&this.init(),this.reset())}get state(){return this.ctrl.state[this.key]}set state(i){this.ctrl.state[this.key]=i}get shared(){return this.ctrl.state.shared}get eventStore(){return this.ctrl.gestureEventStores[this.key]}get timeoutStore(){return this.ctrl.gestureTimeoutStores[this.key]}get config(){return this.ctrl.config[this.key]}get sharedConfig(){return this.ctrl.config.shared}get handler(){return this.ctrl.handlers[this.key]}reset(){const{state:i,shared:r,ingKey:c,args:u}=this;r[c]=i._active=i.active=i._blocked=i._force=!1,i._step=[!1,!1],i.intentional=!1,i._movement=[0,0],i._distance=[0,0],i._direction=[0,0],i._delta=[0,0],i._bounds=[[-1/0,1/0],[-1/0,1/0]],i.args=u,i.axis=void 0,i.memo=void 0,i.elapsedTime=i.timeDelta=0,i.direction=[0,0],i.distance=[0,0],i.overflow=[0,0],i._movementBound=[!1,!1],i.velocity=[0,0],i.movement=[0,0],i.delta=[0,0],i.timeStamp=0}start(i){const r=this.state,c=this.config;r._active||(this.reset(),this.computeInitial(),r._active=!0,r.target=i.target,r.currentTarget=i.currentTarget,r.lastOffset=c.from?fc(c.from,r):r.offset,r.offset=r.lastOffset,r.startTime=r.timeStamp=i.timeStamp)}computeValues(i){const r=this.state;r._values=i,r.values=this.config.transform(i)}computeInitial(){const i=this.state;i._initial=i._values,i.initial=i.values}compute(i){const{state:r,config:c,shared:u}=this;r.args=this.args;let f=0;if(i&&(r.event=i,c.preventDefault&&i.cancelable&&r.event.preventDefault(),r.type=i.type,u.touches=this.ctrl.pointerIds.size||this.ctrl.touchIds.size,u.locked=!!document.pointerLockElement,Object.assign(u,rS(i)),u.down=u.pressed=u.buttons%2===1||u.touches>0,f=i.timeStamp-r.timeStamp,r.timeStamp=i.timeStamp,r.elapsedTime=r.timeStamp-r.startTime),r._active){const ee=r._delta.map(Math.abs);xt.addTo(r._distance,ee)}this.axisIntent&&this.axisIntent(i);const[h,m]=r._movement,[x,g]=c.threshold,{_step:v,values:w}=r;if(c.hasCustomTransform?(v[0]===!1&&(v[0]=Math.abs(h)>=x&&w[0]),v[1]===!1&&(v[1]=Math.abs(m)>=g&&w[1])):(v[0]===!1&&(v[0]=Math.abs(h)>=x&&Math.sign(h)*x),v[1]===!1&&(v[1]=Math.abs(m)>=g&&Math.sign(m)*g)),r.intentional=v[0]!==!1||v[1]!==!1,!r.intentional)return;const j=[0,0];if(c.hasCustomTransform){const[ee,de]=w;j[0]=v[0]!==!1?ee-v[0]:0,j[1]=v[1]!==!1?de-v[1]:0}else j[0]=v[0]!==!1?h-v[0]:0,j[1]=v[1]!==!1?m-v[1]:0;this.restrictToAxis&&!r._blocked&&this.restrictToAxis(j);const E=r.offset,R=r._active&&!r._blocked||r.active;R&&(r.first=r._active&&!r.active,r.last=!r._active&&r.active,r.active=u[this.ingKey]=r._active,i&&(r.first&&("bounds"in c&&(r._bounds=fc(c.bounds,r)),this.setup&&this.setup()),r.movement=j,this.computeOffset()));const[B,z]=r.offset,[[H,q],[V,X]]=r._bounds;r.overflow=[B<H?-1:B>q?1:0,z<V?-1:z>X?1:0],r._movementBound[0]=r.overflow[0]?r._movementBound[0]===!1?r._movement[0]:r._movementBound[0]:!1,r._movementBound[1]=r.overflow[1]?r._movementBound[1]===!1?r._movement[1]:r._movementBound[1]:!1;const Z=r._active?c.rubberband||[0,0]:[0,0];if(r.offset=Fj(r._bounds,r.offset,Z),r.delta=xt.sub(r.offset,E),this.computeMovement(),R&&(!r.last||f>uS)){r.delta=xt.sub(r.offset,E);const ee=r.delta.map(Math.abs);xt.addTo(r.distance,ee),r.direction=r.delta.map(Math.sign),r._direction=r._delta.map(Math.sign),!r.first&&f>0&&(r.velocity=[ee[0]/f,ee[1]/f],r.timeDelta=f)}}emit(){const i=this.state,r=this.shared,c=this.config;if(i._active||this.clean(),(i._blocked||!i.intentional)&&!i._force&&!c.triggerAllEvents)return;const u=this.handler(Le(Le(Le({},r),i),{},{[this.aliasKey]:i.values}));u!==void 0&&(i.memo=u)}clean(){this.eventStore.clean(),this.timeoutStore.clean()}}function fS([n,i],r){const c=Math.abs(n),u=Math.abs(i);if(c>u&&c>r)return"x";if(u>c&&u>r)return"y"}class hS extends dS{constructor(...i){super(...i),Ct(this,"aliasKey","xy")}reset(){super.reset(),this.state.axis=void 0}init(){this.state.offset=[0,0],this.state.lastOffset=[0,0]}computeOffset(){this.state.offset=xt.add(this.state.lastOffset,this.state.movement)}computeMovement(){this.state.movement=xt.sub(this.state.offset,this.state.lastOffset)}axisIntent(i){const r=this.state,c=this.config;if(!r.axis&&i){const u=typeof c.axisThreshold=="object"?c.axisThreshold[e0(i)]:c.axisThreshold;r.axis=fS(r._movement,u)}r._blocked=(c.lockDirection||!!c.axis)&&!r.axis||!!c.axis&&c.axis!==r.axis}restrictToAxis(i){if(this.config.axis||this.config.lockDirection)switch(this.state.axis){case"x":i[1]=0;break;case"y":i[0]=0;break}}}const mS=n=>n,Eg=.15,n0={enabled(n=!0){return n},eventOptions(n,i,r){return Le(Le({},r.shared.eventOptions),n)},preventDefault(n=!1){return n},triggerAllEvents(n=!1){return n},rubberband(n=0){switch(n){case!0:return[Eg,Eg];case!1:return[0,0];default:return xt.toVector(n)}},from(n){if(typeof n=="function")return n;if(n!=null)return xt.toVector(n)},transform(n,i,r){const c=n||r.shared.transform;return this.hasCustomTransform=!!c,c||mS},threshold(n){return xt.toVector(n,0)}},pS=0,Ms=Le(Le({},n0),{},{axis(n,i,{axis:r}){if(this.lockDirection=r==="lock",!this.lockDirection)return r},axisThreshold(n=pS){return n},bounds(n={}){if(typeof n=="function")return f=>Ms.bounds(n(f));if("current"in n)return()=>n.current;if(typeof HTMLElement=="function"&&n instanceof HTMLElement)return n;const{left:i=-1/0,right:r=1/0,top:c=-1/0,bottom:u=1/0}=n;return[[i,r],[c,u]]}}),Og={ArrowRight:(n,i=1)=>[n*i,0],ArrowLeft:(n,i=1)=>[-1*n*i,0],ArrowUp:(n,i=1)=>[0,-1*n*i],ArrowDown:(n,i=1)=>[0,n*i]};class gS extends hS{constructor(...i){super(...i),Ct(this,"ingKey","dragging")}reset(){super.reset();const i=this.state;i._pointerId=void 0,i._pointerActive=!1,i._keyboardActive=!1,i._preventScroll=!1,i._delayed=!1,i.swipe=[0,0],i.tap=!1,i.canceled=!1,i.cancel=this.cancel.bind(this)}setup(){const i=this.state;if(i._bounds instanceof HTMLElement){const r=i._bounds.getBoundingClientRect(),c=i.currentTarget.getBoundingClientRect(),u={left:r.left-c.left+i.offset[0],right:r.right-c.right+i.offset[0],top:r.top-c.top+i.offset[1],bottom:r.bottom-c.bottom+i.offset[1]};i._bounds=Ms.bounds(u)}}cancel(){const i=this.state;i.canceled||(i.canceled=!0,i._active=!1,setTimeout(()=>{this.compute(),this.emit()},0))}setActive(){this.state._active=this.state._pointerActive||this.state._keyboardActive}clean(){this.pointerClean(),this.state._pointerActive=!1,this.state._keyboardActive=!1,super.clean()}pointerDown(i){const r=this.config,c=this.state;if(i.buttons!=null&&(Array.isArray(r.pointerButtons)?!r.pointerButtons.includes(i.buttons):r.pointerButtons!==-1&&r.pointerButtons!==i.buttons))return;const u=this.ctrl.setEventIds(i);r.pointerCapture&&i.target.setPointerCapture(i.pointerId),!(u&&u.size>1&&c._pointerActive)&&(this.start(i),this.setupPointer(i),c._pointerId=sd(i),c._pointerActive=!0,this.computeValues(Ag(i)),this.computeInitial(),r.preventScrollAxis&&e0(i)!=="mouse"?(c._active=!1,this.setupScrollPrevention(i)):r.delay>0?(this.setupDelayTrigger(i),r.triggerAllEvents&&(this.compute(i),this.emit())):this.startPointerDrag(i))}startPointerDrag(i){const r=this.state;r._active=!0,r._preventScroll=!0,r._delayed=!1,this.compute(i),this.emit()}pointerMove(i){const r=this.state,c=this.config;if(!r._pointerActive)return;const u=sd(i);if(r._pointerId!==void 0&&u!==r._pointerId)return;const f=Ag(i);if(document.pointerLockElement===i.target?r._delta=[i.movementX,i.movementY]:(r._delta=xt.sub(f,r._values),this.computeValues(f)),xt.addTo(r._movement,r._delta),this.compute(i),r._delayed&&r.intentional){this.timeoutStore.remove("dragDelay"),r.active=!1,this.startPointerDrag(i);return}if(c.preventScrollAxis&&!r._preventScroll)if(r.axis)if(r.axis===c.preventScrollAxis||c.preventScrollAxis==="xy"){r._active=!1,this.clean();return}else{this.timeoutStore.remove("startPointerDrag"),this.startPointerDrag(i);return}else return;this.emit()}pointerUp(i){this.ctrl.setEventIds(i);try{this.config.pointerCapture&&i.target.hasPointerCapture(i.pointerId)&&i.target.releasePointerCapture(i.pointerId)}catch{}const r=this.state,c=this.config;if(!r._active||!r._pointerActive)return;const u=sd(i);if(r._pointerId!==void 0&&u!==r._pointerId)return;this.state._pointerActive=!1,this.setActive(),this.compute(i);const[f,h]=r._distance;if(r.tap=f<=c.tapsThreshold&&h<=c.tapsThreshold,r.tap&&c.filterTaps)r._force=!0;else{const[m,x]=r._delta,[g,v]=r._movement,[w,j]=c.swipe.velocity,[E,R]=c.swipe.distance,B=c.swipe.duration;if(r.elapsedTime<B){const z=Math.abs(m/r.timeDelta),H=Math.abs(x/r.timeDelta);z>w&&Math.abs(g)>E&&(r.swipe[0]=Math.sign(m)),H>j&&Math.abs(v)>R&&(r.swipe[1]=Math.sign(x))}}this.emit()}pointerClick(i){!this.state.tap&&i.detail>0&&(i.preventDefault(),i.stopPropagation())}setupPointer(i){const r=this.config,c=r.device;r.pointerLock&&i.currentTarget.requestPointerLock(),r.pointerCapture||(this.eventStore.add(this.sharedConfig.window,c,"change",this.pointerMove.bind(this)),this.eventStore.add(this.sharedConfig.window,c,"end",this.pointerUp.bind(this)),this.eventStore.add(this.sharedConfig.window,c,"cancel",this.pointerUp.bind(this)))}pointerClean(){this.config.pointerLock&&document.pointerLockElement===this.state.currentTarget&&document.exitPointerLock()}preventScroll(i){this.state._preventScroll&&i.cancelable&&i.preventDefault()}setupScrollPrevention(i){this.state._preventScroll=!1,xS(i);const r=this.eventStore.add(this.sharedConfig.window,"touch","change",this.preventScroll.bind(this),{passive:!1});this.eventStore.add(this.sharedConfig.window,"touch","end",r),this.eventStore.add(this.sharedConfig.window,"touch","cancel",r),this.timeoutStore.add("startPointerDrag",this.startPointerDrag.bind(this),this.config.preventScrollDelay,i)}setupDelayTrigger(i){this.state._delayed=!0,this.timeoutStore.add("dragDelay",()=>{this.state._step=[0,0],this.startPointerDrag(i)},this.config.delay)}keyDown(i){const r=Og[i.key];if(r){const c=this.state,u=i.shiftKey?10:i.altKey?.1:1;this.start(i),c._delta=r(this.config.keyboardDisplacement,u),c._keyboardActive=!0,xt.addTo(c._movement,c._delta),this.compute(i),this.emit()}}keyUp(i){i.key in Og&&(this.state._keyboardActive=!1,this.setActive(),this.compute(i),this.emit())}bind(i){const r=this.config.device;i(r,"start",this.pointerDown.bind(this)),this.config.pointerCapture&&(i(r,"change",this.pointerMove.bind(this)),i(r,"end",this.pointerUp.bind(this)),i(r,"cancel",this.pointerUp.bind(this)),i("lostPointerCapture","",this.pointerUp.bind(this))),this.config.keys&&(i("key","down",this.keyDown.bind(this)),i("key","up",this.keyUp.bind(this))),this.config.filterTaps&&i("click","",this.pointerClick.bind(this),{capture:!0,passive:!1})}}function xS(n){"persist"in n&&typeof n.persist=="function"&&n.persist()}const zs=typeof window<"u"&&window.document&&window.document.createElement;function a0(){return zs&&"ontouchstart"in window}function yS(){return a0()||zs&&window.navigator.maxTouchPoints>1}function vS(){return zs&&"onpointerdown"in window}function bS(){return zs&&"exitPointerLock"in window.document}function jS(){try{return"constructor"in GestureEvent}catch{return!1}}const It={isBrowser:zs,gesture:jS(),touch:a0(),touchscreen:yS(),pointer:vS(),pointerLock:bS()},SS=250,wS=180,_S=.5,TS=50,AS=250,CS=10,Dg={mouse:0,touch:0,pen:8},ES=Le(Le({},Ms),{},{device(n,i,{pointer:{touch:r=!1,lock:c=!1,mouse:u=!1}={}}){return this.pointerLock=c&&It.pointerLock,It.touch&&r?"touch":this.pointerLock?"mouse":It.pointer&&!u?"pointer":It.touch?"touch":"mouse"},preventScrollAxis(n,i,{preventScroll:r}){if(this.preventScrollDelay=typeof r=="number"?r:r||r===void 0&&n?SS:void 0,!(!It.touchscreen||r===!1))return n||(r!==void 0?"y":void 0)},pointerCapture(n,i,{pointer:{capture:r=!0,buttons:c=1,keys:u=!0}={}}){return this.pointerButtons=c,this.keys=u,!this.pointerLock&&this.device==="pointer"&&r},threshold(n,i,{filterTaps:r=!1,tapsThreshold:c=3,axis:u=void 0}){const f=xt.toVector(n,r?c:u?1:0);return this.filterTaps=r,this.tapsThreshold=c,f},swipe({velocity:n=_S,distance:i=TS,duration:r=AS}={}){return{velocity:this.transform(xt.toVector(n)),distance:this.transform(xt.toVector(i)),duration:r}},delay(n=0){switch(n){case!0:return wS;case!1:return 0;default:return n}},axisThreshold(n){return n?Le(Le({},Dg),n):Dg},keyboardDisplacement(n=CS){return n}});Le(Le({},n0),{},{device(n,i,{shared:r,pointer:{touch:c=!1}={}}){if(r.target&&!It.touch&&It.gesture)return"gesture";if(It.touch&&c)return"touch";if(It.touchscreen){if(It.pointer)return"pointer";if(It.touch)return"touch"}},bounds(n,i,{scaleBounds:r={},angleBounds:c={}}){const u=h=>{const m=Cg(fc(r,h),{min:-1/0,max:1/0});return[m.min,m.max]},f=h=>{const m=Cg(fc(c,h),{min:-1/0,max:1/0});return[m.min,m.max]};return typeof r!="function"&&typeof c!="function"?[u(),f()]:h=>[u(h),f(h)]},threshold(n,i,r){return this.lockDirection=r.axis==="lock",xt.toVector(n,this.lockDirection?[.1,3]:0)},modifierKey(n){return n===void 0?"ctrlKey":n},pinchOnWheel(n=!0){return n}});Le(Le({},Ms),{},{mouseOnly:(n=!0)=>n});Le(Le({},Ms),{},{mouseOnly:(n=!0)=>n});const i0=new Map,vd=new Map;function OS(n){i0.set(n.key,n.engine),vd.set(n.key,n.resolver)}const DS={key:"drag",engine:gS,resolver:ES};function MS(n,i){if(n==null)return{};var r={},c=Object.keys(n),u,f;for(f=0;f<c.length;f++)u=c[f],!(i.indexOf(u)>=0)&&(r[u]=n[u]);return r}function zS(n,i){if(n==null)return{};var r=MS(n,i),c,u;if(Object.getOwnPropertySymbols){var f=Object.getOwnPropertySymbols(n);for(u=0;u<f.length;u++)c=f[u],!(i.indexOf(c)>=0)&&Object.prototype.propertyIsEnumerable.call(n,c)&&(r[c]=n[c])}return r}const RS={target(n){if(n)return()=>"current"in n?n.current:n},enabled(n=!0){return n},window(n=It.isBrowser?window:void 0){return n},eventOptions({passive:n=!0,capture:i=!1}={}){return{passive:n,capture:i}},transform(n){return n}},kS=["target","eventOptions","window","enabled","transform"];function sc(n={},i){const r={};for(const[c,u]of Object.entries(i))switch(typeof u){case"function":r[c]=u.call(r,n[c],c,n);break;case"object":r[c]=sc(n[c],u);break;case"boolean":u&&(r[c]=n[c]);break}return r}function BS(n,i,r={}){const c=n,{target:u,eventOptions:f,window:h,enabled:m,transform:x}=c,g=zS(c,kS);if(r.shared=sc({target:u,eventOptions:f,window:h,enabled:m,transform:x},RS),i){const v=vd.get(i);r[i]=sc(Le({shared:r.shared},g),v)}else for(const v in g){const w=vd.get(v);w&&(r[v]=sc(Le({shared:r.shared},g[v]),w))}return r}class l0{constructor(i,r){Ct(this,"_listeners",new Set),this._ctrl=i,this._gestureKey=r}add(i,r,c,u,f){const h=this._listeners,m=aS(r,c),x=this._gestureKey?this._ctrl.config[this._gestureKey].eventOptions:{},g=Le(Le({},x),f);i.addEventListener(m,u,g);const v=()=>{i.removeEventListener(m,u,g),h.delete(v)};return h.add(v),v}clean(){this._listeners.forEach(i=>i()),this._listeners.clear()}}class NS{constructor(){Ct(this,"_timeouts",new Map)}add(i,r,c=140,...u){this.remove(i),this._timeouts.set(i,window.setTimeout(r,c,...u))}remove(i){const r=this._timeouts.get(i);r&&window.clearTimeout(r)}clean(){this._timeouts.forEach(i=>void window.clearTimeout(i)),this._timeouts.clear()}}class US{constructor(i){Ct(this,"gestures",new Set),Ct(this,"_targetEventStore",new l0(this)),Ct(this,"gestureEventStores",{}),Ct(this,"gestureTimeoutStores",{}),Ct(this,"handlers",{}),Ct(this,"config",{}),Ct(this,"pointerIds",new Set),Ct(this,"touchIds",new Set),Ct(this,"state",{shared:{shiftKey:!1,metaKey:!1,ctrlKey:!1,altKey:!1}}),LS(this,i)}setEventIds(i){if(Dc(i))return this.touchIds=new Set(sS(i)),this.touchIds;if("pointerId"in i)return i.type==="pointerup"||i.type==="pointercancel"?this.pointerIds.delete(i.pointerId):i.type==="pointerdown"&&this.pointerIds.add(i.pointerId),this.pointerIds}applyHandlers(i,r){this.handlers=i,this.nativeHandlers=r}applyConfig(i,r){this.config=BS(i,r,this.config)}clean(){this._targetEventStore.clean();for(const i of this.gestures)this.gestureEventStores[i].clean(),this.gestureTimeoutStores[i].clean()}effect(){return this.config.shared.target&&this.bind(),()=>this._targetEventStore.clean()}bind(...i){const r=this.config.shared,c={};let u;if(!(r.target&&(u=r.target(),!u))){if(r.enabled){for(const h of this.gestures){const m=this.config[h],x=Mg(c,m.eventOptions,!!u);if(m.enabled){const g=i0.get(h);new g(this,i,h).bind(x)}}const f=Mg(c,r.eventOptions,!!u);for(const h in this.nativeHandlers)f(h,"",m=>this.nativeHandlers[h](Le(Le({},this.state.shared),{},{event:m,args:i})),void 0,!0)}for(const f in c)c[f]=oS(...c[f]);if(!u)return c;for(const f in c){const{device:h,capture:m,passive:x}=nS(f);this._targetEventStore.add(u,h,"",c[f],{capture:m,passive:x})}}}}function Xi(n,i){n.gestures.add(i),n.gestureEventStores[i]=new l0(n,i),n.gestureTimeoutStores[i]=new NS}function LS(n,i){i.drag&&Xi(n,"drag"),i.wheel&&Xi(n,"wheel"),i.scroll&&Xi(n,"scroll"),i.move&&Xi(n,"move"),i.pinch&&Xi(n,"pinch"),i.hover&&Xi(n,"hover")}const Mg=(n,i,r)=>(c,u,f,h={},m=!1)=>{var x,g;const v=(x=h.capture)!==null&&x!==void 0?x:i.capture,w=(g=h.passive)!==null&&g!==void 0?g:i.passive;let j=m?c:eS(c,u,v);r&&w&&(j+="Passive"),n[j]=n[j]||[],n[j].push(f)};function HS(n,i={},r,c){const u=J.useMemo(()=>new US(n),[]);if(u.applyHandlers(n,c),u.applyConfig(i,r),J.useEffect(u.effect.bind(u)),J.useEffect(()=>u.clean.bind(u),[]),i.target===void 0)return u.bind.bind(u)}function qS(n,i){return OS(DS),HS({drag:n},i||{},"drag")}const $S=A(Zj.div)`
  position: relative;
  margin: auto;
  max-height: 100%;
  overflow-y: auto;
  width: ${({fill:n})=>n?"70%":"auto"};
  touch-action: pan-y;

  > ${De} {
    min-width: 200px;
    min-height: 200px;
    max-width: 1300px;
  }

  ${({fill:n})=>n&&`@media (max-width: 900px) {
      width: 100%;
    }`}
`,hc=A.div`
  display: ${({open:n})=>n?"flex":"none"};
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  padding: 20px;
  z-index: 50;
  min-width: 100%;
`;hc.Background=A.div`
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: ${({theme:n})=>n.colors.modal};
`;hc.Content=A.div`
  position: relative;
  margin: auto;
  max-height: 100%;
  overflow-y: auto;
  width: ${({fill:n})=>n?"70%":"auto"};

  > ${De} {
    min-width: 200px;
    min-height: 200px;
    max-width: 1300px;
  }

  ${({fill:n})=>n&&`
    @media (max-width: 900px) {
      width: 100%;
    }
  `}
`;const GS=A.button`
  position: absolute;
  top: 0.3em;
  right: 0.5em;
  background: none;
  border: none;
  font-size: 2rem;
  color: ${({theme:n})=>n.colors.text};
  z-index: 10;
  cursor: pointer;
`;function Xe({children:n,open:i=!1,setOpen:r,fill:c}){const[{y:u},f]=Rj(()=>({y:0})),h=qS(({down:m,movement:[,x],cancel:g,last:v})=>{if(x>100&&!m){r(!1),f.start({y:0});return}x<-30&&(g==null||g()),f.start({y:m?x:0,immediate:m})},{axis:"y",filterTaps:!0,bounds:{top:0},rubberband:!0});return S.useEffect(()=>{const m=x=>{x.key==="Escape"&&r(!1)};return window.addEventListener("keydown",m),()=>window.removeEventListener("keydown",m)},[r]),mx.createPortal(s.jsxs(hc,{open:i,children:[s.jsx(hc.Background,{onClick:()=>r(!1)}),s.jsxs($S,{fill:c,...h(),style:{y:u},children:[s.jsx(GS,{onClick:()=>r(!1),children:"×"}),n]})]}),document.body)}function zg({children:n,onConfirm:i,title:r,setOpen:c,...u}){const{t:f}=$();return s.jsx(Xe,{setOpen:c,...u,children:s.jsxs(De,{children:[s.jsx("h2",{style:{fontWeight:"bolder"},children:r||f("Please confirm!")}),n,s.jsxs(ze,{children:[s.jsx(K,{$variant:"danger",onClick:i,children:f("Yes")}),s.jsx(K,{$variant:"secondary",onClick:()=>c(!1),children:f("No")})]})]})})}const VS="/static/incursions/waitlist/bell-ringing-04.mp3",YS="/static/incursions/waitlist/notification-icon.png",Rg="EventNotifierSettings";function XS(){const{t:n}=$(),i=S.useContext(el),[r,c]=S.useState(!1),[u,f]=S.useState(!1),h=S.useRef(null),[m,x]=S.useState(()=>{try{const w=localStorage.getItem(Rg);return w?JSON.parse(w):{enableSound:!1}}catch{return{enableSound:!1}}});S.useEffect(()=>{localStorage.setItem(Rg,JSON.stringify(m))},[m]),S.useEffect(()=>{h.current&&(u?h.current.play().catch(console.warn):h.current.pause())},[u]);const g=S.useCallback(w=>{const j=w.data;Notification.permission==="granted"?new Notification("TLA",{body:j,icon:YS,tag:j,renotify:!0,timestamp:Date.now()}):Notification.permission==="default"&&Notification.requestPermission().catch(console.warn),m.enableSound&&h.current&&f(j)},[m]),v=S.useCallback(w=>{const j=JSON.parse(w.data);Notification.permission==="granted"?new Notification(j.message,{silent:!0}):Notification.permission==="default"&&Notification.requestPermission().catch(console.warn)},[]);return S.useEffect(()=>{if(i)return i.addEventListener("wakeup",g),i.addEventListener("message",v),()=>{i.removeEventListener("wakeup",g),i.removeEventListener("message",v)}},[i,g,v]),s.jsxs(s.Fragment,{children:[s.jsx(Xe,{open:r,setOpen:c,children:s.jsxs(De,{children:[s.jsx("p",{children:s.jsxs("label",{children:[s.jsx("input",{type:"checkbox",checked:m.enableSound,onChange:w=>x(j=>({...j,enableSound:!!w.target.checked}))})," ",n("Enable sound notifications")]})}),s.jsx(K,{onClick:()=>g({data:n("This is a test alert")}),children:n("Send test notification")})]})}),s.jsx(Xe,{open:!!u,setOpen:()=>f(!1),children:s.jsxs(De,{style:{minHeight:"50px"},children:[s.jsx("p",{style:{marginBottom:"20px"},children:u}),s.jsx(K,{onClick:()=>f(!1),$variant:"success",children:n("OK")}),s.jsx("audio",{ref:h,loop:!0,children:s.jsx("source",{src:VS,type:"audio/mp3"})})]})}),s.jsx(yx,{onClick:()=>c(!0),title:m.enableSound?n("Sound alerts are currently enabled"):n("Sound alerts are currently disabled"),children:s.jsx(fe,{fixedWidth:!0,icon:m.enableSound?A1:C1})})]})}const kg={font:{family:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',monospaceFamily:'SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace'},logo:{}},ht={Light:ye.merge({},kg,{base:"light",colors:{background:"#ffffff",text:"#4a4a4a",active:"#000000",lumFactor:1,outline:"hsla(213, 100%, 40%, 0.2)",modal:"hsla(0, 0%, 0%, 0.80)",shadow:"hsla(0, 0%, 0%, 0.2)",input:{color:"#2020200d",text:"#4a4a4a",accent:"2020200d",disabled:"#cccccc"},success:{color:"#48c774",text:"white",accent:"#3ec46d",disabled:"#92ddac"},warning:{color:"#ffdd57",text:"#4a4a4a",accent:"#ffda47",disabled:"#cccccc"},danger:{color:"#f14668",text:"white",accent:"#f03a5f",disabled:"#f8a5b6"},primary:{color:"#47afff",text:"white",accent:"#38a9ff",disabled:"#addcff"},secondary:{color:"#e6e6e6",text:"#4a4a4a",accent:"#dbdbdb",disabled:"#cccccc"},highlight:{text:"#fc9936",active:"#ffad5c"},accent1:"#fafafa",accent2:"#dbdbdb",accent3:"#999999",accent4:"#666666",tdfShields:{red:"#d60015",green:"#19b915",blue:"#0076c2",yellow:"#d2bd00",purple:"#820082",neutral:"#4b4b4b",cyan:"#1eabaa",text:"#ffffff"}}}),Dark:ye.merge({},kg,{base:"dark",logo:{filter:"invert(1)"},colors:{background:"#1f1f1f",text:"#cccccc",active:"#eeeeee",lumFactor:.6,outline:"hsla(213, 100%, 40%, 0.2)",modal:"hsla(0, 0%, 0%, 0.80)",shadow:"hsla(0, 0%, 0%, 0.5)",input:{color:"#ffffff0a",text:"#cccccc",accent:"#ffffff0a",disabled:"#999999"},success:{color:"#1f6538",text:"white",accent:"#226d3c",disabled:"#133e22"},warning:{color:"#977c0b",text:"white",accent:"#b89300",disabled:"#574500"},danger:{color:"#661425",text:"white",accent:"#6f1628",disabled:"#330a12"},primary:{color:"#005ca3",text:"white",disabled:"#cccccc",accent:"#002e52"},secondary:{color:"#404040",text:"white",accent:"#454545",disabled:"#202020"},highlight:{text:"#fc9936",active:"#ffad5c"},accent1:"#2e2e2e",accent2:"#454545",accent3:"#757575",accent4:"#ababab",tdfShields:{red:"#9a121f",green:"#21861e",blue:"#105b8b",yellow:"#968912",purple:"#820082",neutral:"#777777",cyan:"#1c9493",text:"#cccccc"}}})};ht.AMOLED=ye.merge({},ht.Dark,{colors:{text:"#f0f0f0",background:"#000000",modal:"hsla(55, 0%, 13%, 0.83)"}});ht["Midnight Blue"]=ye.merge({},ht.Dark,{colors:{background:"#0a0a2c",accent1:"#1e1e40"}});ht.Specialist=ye.merge({},ht.Light,{colors:{text:"#666666",background:"#fdf3f9",accent1:"#ffcbe9",accent2:"#ffbcdf",accent3:"#d55f9d",active:"#e11891",outline:"hsla(306, 100%, 75%, 0.2)",modal:"hsla(0, 0%, 0%, 0.50)",shadow:"hsla(315, 100%, 90%, 0.4)",input:{color:"#ffc3e536",text:"#4a4a4a",accent:"#ffc3e536",disabled:"#757575"},primary:{color:"#d36ab9",text:"white",accent:"#b64a9b",disabled:"#e8e8e8"},secondary:{color:"#f1abd6",text:"white",accent:"#e58ac2",disabled:"#e8e8e8"},warning:{color:"#ffeb9f",text:"#363636",accent:"#ffda47",disabled:"#e8e8e8"},danger:{color:"#ff889f",text:"white",accent:"#f35e7b",disabled:"#f35e7b"},success:{color:"#d673af",text:"white",accent:"#c15496",disabled:"#e8e8e8"},tdfShields:{red:"#ff5676",yellow:"#f2d56d",green:"#50df4d",blue:"#2e91d1"}},logo:{filter:"hue-rotate(-55deg) drop-shadow(1px 2px 0.5px #ff8fc9) contrast(90%)"}});ht.Chocola=ye.merge({},ht.Dark,{colors:{background:"#30292c",active:"#FF357C",shadow:"hsla(0, 0%, 0%, 0.2)",outline:"hsla(339, 100%, 60%, 0.2)",secondary:{color:"#AE3F69",text:"white",accent:"#bc577d",disabled:"#e8e8e8"},input:{color:"#4f3d44",text:"#cccccc",accent:"#4f3d44",disabled:"#999999"},success:{color:"#1f6538",text:"white",accent:"#226d3c",disabled:"#133e22"},danger:{color:"#711818",text:"white",accent:"#6f1628",disabled:"#330a12"},accent1:"#4f3d44",accent2:"#5b4453",accent3:"#d15886"},logo:{filter:"invert(1) drop-shadow(1px 2px 0.5px #80173E)"},sticker:"https://i.imgur.com/ohDedR4.png"});ht.Vanilla=ye.merge({},ht.Dark,{colors:{background:"#2d2f43",active:"#9bf8ff",shadow:"rgba(0, 0, 0, .2)",outline:"hsla(203, 69%, 25%, 0.2)",text:"#6a96e9",secondary:{color:"#4b598a",text:"#e6e6e6",accent:"#5e6faa",disabled:"#b0a17f"},success:{color:"#1f6538",text:"#e4eff9 ",accent:"#226d3c",disabled:"#cccccc"},input:{color:"#3a425e",text:"#b0a17f",accent:"#3a425e",disabled:"#999999"},warning:{color:"#b79718",text:"white",accent:"#c8a51c",disabled:"#cccccc"},danger:{color:"#752626",text:"#cdcdcd ",accent:"#842c2c",disabled:"#330a12"},accent1:"#333557",accent2:"#3d5d86",accent3:"#9bf8ff",accent4:"#b0a17f",highlight:{text:"#fc9936",active:"#ffad5c"}},logo:{filter:"invert(62%) sepia(28%) saturate(325%) hue-rotate(4deg) brightness(100%) contrast(84%) drop-shadow(1px 1px 0.3px #000000)"},sticker:"https://i.imgur.com/8JN6udB.png"});Object.keys(ht).forEach(n=>{ht[n].name=n});const QS=Object.keys(ht);function ZS({theme:n,setTheme:i,sticker:r,setSticker:c}){var g;const{t:u}=$(),[f,h]=S.useState(!1),m=()=>{c(!r)},x=()=>["dark","AMOLED"].includes(n)?E1:n==="Specialist"?O1:D1;return s.jsxs(s.Fragment,{children:[s.jsx(Xe,{open:f,setOpen:h,children:s.jsxs(De,{children:[s.jsx(Ge,{children:u("Theme select")}),QS.map(v=>s.jsx("div",{children:s.jsxs("label",{children:[s.jsx(wb,{value:v,checked:n===v,onChange:w=>i(w.target.value)})," ",u(v)]})},v)),((g=ht[n])==null?void 0:g.sticker)&&s.jsx(K,{style:{marginTop:"0.5em"},onClick:m,children:u(r?"Disable Sticker":"Enable Sticker")})]})}),s.jsx(yx,{onClick:()=>h(!0),children:s.jsx(fe,{fixedWidth:!0,icon:x()})})]})}const Vn=A(Ot)`
  padding: 0 1em;
  color: #bbb;
  text-decoration: none;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  &:hover {
    color: #cccccc;
    border-radius: 2px;
  }
  &.active {
    color: #eeeeee;
    text-shadow: 0px 0px 5px rgba(255, 255, 255, 0.5);
  }

  @media (max-width: 480px) {
    padding: 1em;
    &.active {
      background-color: #454545;
      border-radius: 4px;
    }
  }
`,KS=A.div`
  display: ${({$open:n})=>n?"flex":"none"};
  flex-wrap: wrap;
  flex-direction: column;
`,FS=A.div`
  padding: 0.3em;
  width: 100%;
  transition: all 0.3s;
  opacity: ${({$open:n})=>n?"1":"0"};
  height: ${({$open:n})=>n?"100%":"0"};
  background-color: #2e2e2e;
  border-radius: 0 0 5px 5px;
`,JS=({isOpen:n,whoami:i})=>s.jsx(FS,{$open:n,children:s.jsx(KS,{$open:n,children:s.jsx(s0,{whoami:i})})}),WS=({isOpen:n,setIsOpen:i})=>{const r=An();return S.useEffect(()=>{i(!1)},[r,i]),s.jsx(jb,{onClick:()=>i(!n),children:s.jsx(fe,{icon:n?_d:M1})})},s0=({whoami:n})=>{var r,c;const{t:i}=$();return s.jsxs(s.Fragment,{children:[s.jsx(Vn,{to:"/",end:!0,className:({isActive:u})=>u?"active":"",children:i("Home")}),n&&s.jsx(Vn,{to:"/waitlist",end:!0,className:({isActive:u})=>u?"active":"",children:i("Waitlist")}),s.jsx(Vn,{to:"/guide",end:!0,className:({isActive:u})=>u?"active":"",children:i("Guides")}),s.jsx(Vn,{to:"/fits?Tier=Mainline",end:!0,className:({isActive:u})=>u?"active":"",children:i("Fits")}),s.jsx(Vn,{to:"/skills?ship=Paladin",end:!0,className:({isActive:u})=>u?"active":"",children:i("Skills")}),s.jsx(Vn,{to:"/isk-h/calc",end:!0,className:({isActive:u})=>u?"active":"",children:i("ISK/h")}),((r=n==null?void 0:n.access)==null?void 0:r["incursions.waitlist_manage_waitlist"])&&s.jsxs(s.Fragment,{children:[s.jsx(Vn,{to:"/fc/fleet",end:!0,className:({isActive:u})=>u?"active":"",children:i("Fleet")}),s.jsx(Vn,{to:"/fc",end:!0,className:({isActive:u})=>u?"active":"",children:i("FC")})]}),((c=n==null?void 0:n.access)==null?void 0:c["incursions.waitlist_search"])&&s.jsx(Vn,{to:"/fc/search",end:!0,className:({isActive:u})=>u?"active":"",children:i("Search")})]})},PS="/static/incursions/waitlist/banner.png",IS=A.div`
  background-image: url(${PS});
  background-size: 100% auto;
  background-repeat: no-repeat;
  padding: 0.5em;
  border-radius: 0 0 20px 20px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
  transition: border-radius 0.1s ease-in-out;
  padding-top: 6.5em;

  @media (max-width: 700px) {
    background-size: auto 100%;
    border-radius: ${({$mobileopen:n})=>n?"unset":"0 0 20px 20px"};
  }
`,e2=A(Ot)`
  height: 2.5em;

  img {
    &:hover {
      opacity: 0.7;
    }
  }

  &.active {
    font-weight: bold;
  }
`,tn=A.div`
  margin-bottom: 2em;
`;tn.LogoLink=A(Ot)`
  margin-right: 2em;
  flex-grow: 0;
  line-height: 0;

  @media (max-width: 480px) {
    margin-right: unset;
    margin-left: auto;
  }

  &.active {
    font-weight: bold;
  }
`;tn.Logo=A.img`
  width: 150px;
  filter: ${n=>n.theme.logo.filter};
`;tn.Menu=A.div`
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  flex-grow: 1;
`;tn.Link=A(Ot)`
  padding: 1em;
  color: ${n=>n.theme.colors.accent4};
  text-decoration: none;

  &.active {
    color: ${n=>n.theme.colors.active};
    font-weight: bold;
  }
`;tn.End=A.div`
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;

  > :not(:last-child) {
    @media (max-width: 480px) {
      margin-bottom: 0.4em;
    }
  }
`;tn.Main=A.div`
  display: flex;
  flex-wrap: wrap;

  @media (max-width: 480px) {
    display: none;
  }
`;tn.Name=A.div`
  margin-right: 2em;

  @media (max-width: 480px) {
    margin-right: 0;
    width: 100%;
  }
`;function t2({onChangeCharacter:n,theme:i,setTheme:r,sticker:c,setSticker:u}){const[f,h]=S.useState(!1),[m,x]=S.useState(window.innerWidth),{t:g}=$(),v=S.useContext(He);return S.useEffect(()=>{const w=()=>x(window.innerWidth);return window.addEventListener("resize",w),()=>window.removeEventListener("resize",w)},[]),s.jsxs(tn,{children:[s.jsx(IS,{$mobileopen:f,children:s.jsxs(tn.Menu,{children:[s.jsx(tn.Main,{children:s.jsx(s0,{whoami:v})}),s.jsxs(tn.End,{children:[v&&s.jsx(tn.Name,{children:s.jsxs(eg,{$fixed:!0,children:[s.jsx(e2,{to:"/pilot",end:!0,className:({isActive:w})=>w?"active":"",children:s.jsx("img",{style:{maxHeight:"100%",borderRadius:"20px 0 0 20px"},src:`https://images.evetech.net/characters/${v.current.character_id}/portrait?size=128`,alt:"Character Portrait"})}),s.jsx(_b,{value:v.current.character_id,onChange:w=>n==null?void 0:n(parseInt(w.target.value)),style:{flexGrow:1,border:"unset"},children:v.characters.map(w=>s.jsx("option",{value:w.character_id,children:w.character_name},w.character_id))}),s.jsx(Sn,{as:"a",href:"/incursions/char/add",children:"+"})]})}),s.jsxs(eg,{children:[m<481&&s.jsx(WS,{isOpen:f,setIsOpen:h}),s.jsx(XS,{}),s.jsx(ZS,{theme:i,setTheme:r,sticker:c,setSticker:u}),v?s.jsx(Sb,{as:"button",onClick:()=>window.location.href="/incursions/waitlist/auth/logout",children:g("Logout")}):s.jsx(Sn,{as:"a",href:"/incursions/char/add",$variant:"primary",children:g("Login")})]})]})]})}),s.jsx(JS,{isOpen:f,whoami:v})]})}X1.use(Q1).use(Z1).use(K1).init({detection:{order:["htmlTag","querystring","cookie","localStorage","sessionStorage","navigator","path","subdomain"],htmlTag:document.documentElement},fallbackLng:"en",interpolation:{escapeValue:!1},react:{useSuspense:!1},backend:{loadPath:"/static/incursions/waitlist/i18n/{{lng}}/{{ns}}.json"}});const n2=A.a`
  color: ${({theme:n})=>n.colors.highlight.text};
  text-decoration: none;

  &:hover {
    cursor: pointer;
    color: ${({theme:n})=>n.colors.highlight.active};
    transition: color 0.15s ease-in-out;
  }

  & + svg {
    margin-left: 5px;
    font-size: small;
  }
`;function Qe(n){S.useEffect(()=>{let i=document.title;return Vd(n),()=>document.title=i})}function Vd(n){document.title=`AA: ${n}`}function r0(n){const i=n.split(`
`)[0];return i.substring(i.indexOf(" "))}function a2(n){return n.split(" ").map(i=>i[0].toUpperCase()+i.substr(1).toLowerCase()).join(" ")}const i2=A.div`
  padding: 10px 20px;
  font-weight: 600;

  h1 {
    font-size: 30px;
  }
`,Yd=({title:n,children:i})=>(Qe(n),s.jsx(i2,{children:i})),l2=()=>{const{t:n}=$();return s.jsx(Yd,{title:n("Login Required"),children:s.jsxs("p",{children:[n("You must")," ",s.jsx(n2,{href:"/incursions/char/add",children:n("Login")})," ",n("to view this page.")]})})},s2=()=>{const{t:n}=$();return s.jsxs(Yd,{title:n("Forbidden"),children:[s.jsx("h1",{children:n("403 Error")}),s.jsx("p",{children:n("You are not allowed to view this page. Contact leadership to request access.")})]})},r2=()=>{const{t:n}=$();return s.jsxs(Yd,{title:n("Page Not Found"),children:[s.jsx("h1",{children:n("404 Error")}),s.jsx("p",{children:n("I warped to the FC twice, and all I got was this '404: page not found' error.")})]})};function Xd(n){const r=S.useContext(ni).name;return Object.entries(ht).forEach(([c,u])=>{e1(`TDF-${c}`,{text:{primary:u.colors.primary,secondary:u.colors.secondary},background:{default:u.colors.background}},u.base??"dark")}),s.jsx(t1,{...n,theme:`TDF-${r}`})}const c2=(n,i)=>n.localeCompare(i,{sensitivity:"base"}),Bg=new Date(864e13),o2=(n,i)=>{const r=n?n instanceof Date?n:new Date(n):Bg,c=i?i instanceof Date?i:new Date(i):Bg;return r.getTime()-c.getTime()},Ng=["Character","Corporation","Alliance"],u2=(n,i)=>Ng.indexOf(n.category)-Ng.indexOf(i.category),Ji=A.div`
  margin: 15px 0px;
  padding: 5px 10px;
  flex-grow: 2;
`,c0=A.div`
  font-style: italic;
`,d2={marginRight:"20px",marginBottom:"15px",display:"inline-block"},Ug={"Use in game channel":{content:"Join the TLA Incursions channel to x-up for the fleet.",alert:!1},"Gankers in Focus":{content:"GANKERS ARE IN FOCUS! Stay docked and read the fleet MOTD for instructions.",alert:!0}},o0=({idPrefix:n="",selectedFilters:i=[],onChange:r})=>{const{t:c}=$(),u=f=>{const{dataset:h,checked:m}=f.target,x=h.value;if(!x)return;const g=m?[...i,x]:i.filter(v=>v!==x);r(g)};return s.jsxs(Ji,{children:[s.jsxs(et,{children:[c("Display on:")," (",c("leave blank for site-wide"),")"]}),gx.map((f,h)=>{const m=f.name.toLowerCase(),x=i.includes(m),g=`${n}-${m}`;return s.jsxs("label",{htmlFor:g,style:d2,children:[s.jsx("input",{id:g,"data-value":m,type:"checkbox",checked:x,onChange:u})," ",c(f.name)]},h)})]})},f2=({isOpen:n,setOpen:i,refreshFunction:r})=>{const{t:c}=$(),u=S.useContext(pe),[f,h]=S.useState(!1),[m,x]=S.useState(void 0),[g,v]=S.useState([]),[w,j]=S.useState(!1),E=()=>{h(!1),x(void 0),v([])},R=z=>{if(z.preventDefault(),w)return;j(!0);const H=g.length>0?JSON.stringify(g):null;me(u,ct("/incursions/api/announcements",{method:"POST",json:{message:m,is_alert:f,pages:H}}).then(()=>{i(!1),r(),E()}).finally(()=>j(!1)))},B=z=>{const H=Ug[z.target.value];h((H==null?void 0:H.alert)??!1),x((H==null?void 0:H.content)??"")};return s.jsx(Xe,{open:n,setOpen:i,fill:void 0,children:s.jsxs(De,{children:[s.jsx(Ge,{children:c("New Announcement")}),s.jsxs("form",{onSubmit:R,children:[s.jsxs(Ji,{children:[s.jsxs(et,{htmlFor:"content",children:[c("Content"),":"]}),s.jsx(on,{id:"content",value:m??"",style:{maxWidth:"450px",width:"80vw",height:"250px",resize:"vertical"},onChange:z=>x(z.target.value),required:!0,minLength:0,maxLength:512}),s.jsx(c0,{children:c("Maximum 512 characters.")})]}),s.jsxs(Ji,{children:[s.jsx("input",{id:"important",type:"checkbox",checked:f,onChange:()=>h(!f)}),s.jsxs("label",{htmlFor:"important",title:c("Banner has a red background."),children:[c("This is a")," ",s.jsx("b",{children:s.jsx("u",{children:c("REALLY")})})," ",c("important announcement!")]})]}),s.jsx(o0,{selectedFilters:g,onChange:v}),s.jsxs(Ji,{children:[s.jsx(et,{children:c("or select a template")}),s.jsxs(ei,{style:{width:"100%",appearance:"auto"},onChange:B,children:[s.jsx("option",{children:c("Select...")}),Object.entries(Ug).map(([z],H)=>s.jsx("option",{value:z,children:c(z)},H))]})]}),s.jsxs(Gt,{style:{paddingLeft:"8px"},children:[s.jsx(K,{$variant:"danger",type:"submit",disabled:w,children:c("Confirm")}),s.jsx(K,{$variant:"secondary",type:"button",onClick:()=>i(!1),children:c("Cancel")})]})]})]})})},h2=({data:n,refreshFunction:i})=>{const{t:r}=$(),[c,u]=S.useState(!1),f=({data:h,refreshFunction:m,isOpen:x,setOpen:g})=>{const v=S.useContext(pe),[w,j]=S.useState(),[E,R]=S.useState(!1),[B,z]=S.useState([]),[H,q]=S.useState(!1),V=Z=>{try{return Z?JSON.parse(Z):[]}catch{return[]}};S.useEffect(()=>{j(h.message),R(h.is_alert),z(V(h.pages))},[h.id,h.message,h.is_alert,h.pages]);const X=Z=>{if(Z.preventDefault(),H)return;q(!0);const ee=B.length>0?JSON.stringify(B):null;me(v,ct(`/incursions/api/announcements/${h.id}`,{method:"PUT",json:{message:w,is_alert:E,pages:ee}}).then(()=>{g(!1),m()}).finally(()=>q(!1)))};return s.jsx(Xe,{open:x,setOpen:g,fill:void 0,children:s.jsxs(De,{children:[s.jsxs(Ge,{children:[r("Update Announcement")," #",h.id]}),s.jsxs("form",{onSubmit:X,children:[s.jsxs(Ji,{children:[s.jsxs(et,{htmlFor:`content-${h.id}`,children:[r("Content"),":"]}),s.jsx(on,{id:`content-${h.id}`,value:w??"",style:{maxWidth:"450px",width:"80vw",height:"250px",resize:"vertical"},onChange:Z=>j(Z.target.value),required:!0,minLength:0,maxLength:512}),s.jsx(c0,{children:r("Maximum 512 characters.")})]}),s.jsxs(Ji,{children:[s.jsx("input",{id:`important-${h.id}`,type:"checkbox",checked:E,onChange:()=>R(!E)}),s.jsxs("label",{htmlFor:`important-${h.id}`,title:r("Banner has a red background."),children:[r("This is a")," ",s.jsx("b",{children:s.jsx("u",{children:r("REALLY")})})," ",r("important announcement!")]})]}),s.jsx(o0,{idPrefix:h.id.toString(),selectedFilters:h!=null&&h.pages?JSON.parse(h.pages):[],onChange:z}),s.jsxs(Gt,{style:{paddingLeft:"8px"},children:[s.jsx(K,{$variant:"danger",type:"submit",disabled:H,children:r("Confirm")}),s.jsx(K,{$variant:"secondary",type:"button",onClick:()=>g(!1),children:r("Cancel")})]})]})]})})};return s.jsxs(s.Fragment,{children:[s.jsx(K,{onClick:()=>u(!0),children:r("Update")}),s.jsx(f,{isOpen:c,setOpen:u,data:n,refreshFunction:i})]})},m2=A.div`
  padding-bottom: 10px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-content: space-between;

  h1 {
    font-size: 32px;
  }
`;async function p2(n){await ct(`/incursions/api/announcements/${n}`,{method:"DELETE",json:null})}const g2=()=>{const[n,i]=Dt("/incursions/api/announcements"),[r,c]=S.useState(!1),u=S.useContext(pe),{t:f}=$(),h=[{name:f("Content"),grow:5,selector:m=>m.message,wrap:!0},{name:f("Pages"),selector:m=>{if(!m.pages)return f("table.pages.all","All");try{return JSON.parse(m.pages).map(x=>f(`pages.${x}`,x)).join(", ")}catch{return m.pages}},wrap:!0},{name:f("Created By"),selector:m=>s.jsx(yt,{...m.created_by})},{name:"",maxWidth:"115px",selector:m=>s.jsx(h2,{data:m,refreshFunction:i??(()=>{})})},{name:"",maxWidth:"110px",selector:m=>s.jsx(K,{$variant:"danger",onClick:()=>me(u,p2(m.id).then(i)),children:f("Delete")})}];return Qe(f("Announcements")),s.jsxs(s.Fragment,{children:[s.jsxs(m2,{children:[s.jsx("h1",{children:f("Announcements")}),s.jsxs(K,{variant:"primary",onClick:()=>c(!0),style:{marginTop:"15px"},children:[s.jsx(fe,{fixedWidth:!0,icon:ax,style:{marginRight:"10px"}}),f("New")]})]}),s.jsx(Xd,{columns:h,data:n??[],pagination:!1,progressPending:!n}),s.jsx(f2,{isOpen:r,setOpen:c,refreshFunction:i??(()=>{})})]})},Lg={width:"100%",resize:"vertical",minWidth:"250px"},as=A.div`
  margin: 15px 0px;
  padding: 5px 10px;
  flex-grow: 2;
`,x2=A.form`
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;

  & label::selection,
  div::selection,
  button::selection {
    background: none;
  }
`,Hg=A.div`
  font-style: italic;
`,y2=({entity_type:n,entity_character:i,entity_corporation:r,entity_alliance:c,entity_name:u})=>{switch(n){case"Character":return s.jsx(yt,{...i,noLink:!0});case"Corporation":return s.jsx(Cd,{...r,noLink:!0});case"Alliance":return s.jsx(Ed,{...c,noLink:!0});default:return u}},v2=({isOpen:n,setOpen:i,refreshFunction:r})=>{const{t:c}=$(),u=S.useContext(pe),[f,h]=S.useState(!1),[m,x]=S.useState(!1),[g,v]=S.useState(void 0),[w,j]=S.useState("Character"),[E,R]=S.useState({id:null,name:""}),[B,z]=S.useState(""),[H,q]=S.useState(!1),[V,X]=S.useState(void 0),[Z,ee]=S.useState(void 0),de=oe=>{if(oe.preventDefault(),!f){if(!E.id){_n(u,{variant:"danger",message:c("You need to provide a {{category}} name.",{category:w.toLowerCase()})});return}h(!0),me(u,ct("/incursions/api/bans",{method:"POST",json:{entity:{...E,category:w},reason:V,public_reason:Z,revoked_at:m?null:g}}).then(()=>{i(!1),r(),tt()}).finally(()=>h(!1)))}},tt=()=>{x(!1),v(void 0),j("Character"),R({id:null,name:""}),z(""),q(!1),X(void 0),ee(void 0)};return S.useEffect(()=>{const oe=()=>R({id:null,name:""});if(B.length<3)return oe();q(!0),me(u,ct("/incursions/api/search",{method:"POST",json:{search:B,category:w.toLowerCase(),strict:!0}}).then(Mt=>{q(!1),Mt.length>0?R({id:Mt[0],name:B}):oe()}))},[B,w,u]),s.jsx(Xe,{open:n,setOpen:i,children:s.jsxs(De,{children:[s.jsx(Ge,{children:c("Issue a Ban","Issue a Ban")}),s.jsxs(x2,{onSubmit:de,children:[s.jsxs("div",{children:[s.jsxs(as,{style:{paddingBottom:"40px"},children:[s.jsx(et,{htmlFor:"select-type",required:!0,children:c("Type:","Type:")}),s.jsxs(ei,{id:"select-type",value:w,onChange:oe=>{z(""),j(oe.target.value)},style:{width:"100%",appearance:"auto"},children:[s.jsx("option",{disabled:!0,children:c("Account","Account")}),s.jsx("option",{children:c("Character","Character")}),s.jsx("option",{children:c("Corporation","Corporation")}),s.jsx("option",{children:c("Alliance","Alliance")})]})]}),s.jsxs(as,{children:[s.jsx(et,{htmlFor:"entity-name",required:!0,children:c("{{category}} Name:","{{category}} Name:",{category:w})}),s.jsx(Kn,{id:"entity-name",type:"text",value:B,required:!0,tabIndex:2,onChange:oe=>z(oe.target.value)}),s.jsx("div",{style:{paddingTop:"10px"},children:H?c("Searching...","Searching..."):(E==null?void 0:E.id)&&s.jsx(y2,{category:w,...E})})]})]}),s.jsxs("div",{children:[s.jsxs(as,{children:[s.jsx(et,{htmlFor:"expires_at",required:!0,children:c("Expires:","Expires:")}),s.jsx(Kn,{id:"expires_at",type:"date",value:g?new Date(g*1e3).toISOString().substring(0,10):"",onChange:oe=>v(new Date(oe.target.value).getTime()/1e3),min:new Date(Date.now()+3600*1e3*24).toISOString().substring(0,10),required:!0,disabled:m}),s.jsx("span",{style:{margin:"0 5px"},children:c("or","or")}),s.jsxs("label",{style:{marginRight:"20px",marginBottom:"15px",display:"inline-block"},children:[s.jsx("input",{type:"checkbox",checked:m,onChange:()=>x(!m)}),c("Permanent","Permanent")]}),s.jsx(Hg,{children:c("Bans expire at downtime","Bans expire at downtime")})]}),s.jsxs(as,{children:[s.jsx(et,{htmlFor:"reason",required:!0,children:c("Reason:","Reason:")}),s.jsx(on,{id:"reason",value:V??"",style:Lg,required:!0,onChange:oe=>X(oe.target.value)})]}),s.jsxs(as,{children:[s.jsx(et,{htmlFor:"public_reason",children:c("Public Reason:","Public Reason:")}),s.jsx(on,{id:"public_reason",value:Z??"",style:Lg,onChange:oe=>ee(oe.target.value)}),s.jsx(Hg,{children:c("This reason will be shown to the pilot on the ban page.","This reason will be shown to the pilot on the ban page.")})]}),s.jsxs(Gt,{style:{paddingLeft:"8px"},children:[s.jsx(K,{$variant:"secondary",onClick:()=>i(!1),children:c("Cancel","Cancel")}),s.jsx(K,{$variant:"danger",type:"submit",disabled:f,children:c("Confirm","Confirm")})]})]})]})]})})},qg={width:"100%",resize:"vertical",minWidth:"250px"},_a=A.div`
  margin: 15px 0px;
  padding: 5px 10px;
  flex-grow: 2;
`,b2=A.div`
  font-style: italic;
`,u0=n=>{switch(n.entity_type){case"Character":return n.entity_character?s.jsx(yt,{...n.entity_character}):n.entity_name;case"Corporation":return n.entity_corporation?s.jsx(Cd,{...n.entity_corporation}):n.entity_name;case"Alliance":return n.entity_alliance?s.jsx(Ed,{...n.entity_alliance}):n.entity_name;default:return n.entity_name}},j2=({ban:n,isOpen:i,setOpen:r,refreshFunction:c})=>{const{t:u}=$(),[f,h]=S.useState(!1),m=S.useContext(pe),x=()=>{f||(h(!0),me(m,ct(`/incursions/api/bans/${n.id}`,{method:"DELETE"}).then(()=>{r(!1),c()}).finally(()=>h(!1))))};return s.jsx(Xe,{open:i,setOpen:r,children:s.jsxs(De,{children:[s.jsx(Ge,{children:u("Revoke {{type}} Ban?","Revoke {{type}} Ban?",{type:n.entity_type})}),s.jsxs("div",{style:{maxWidth:"500px",display:"flex"},children:[s.jsxs(_a,{children:[s.jsx(et,{children:u("{{type}}:","{{type}}:",{type:n.entity_type})}),s.jsx(u0,{...n})]}),s.jsxs(_a,{children:[s.jsx(et,{children:u("Issued By:","Issued By:")}),n.issued_by&&s.jsx(yt,{...n.issued_by})]})]}),s.jsxs(_a,{children:[s.jsx(et,{children:u("Reason:","Reason:")}),s.jsx("p",{style:{maxWidth:"500px"},children:n.reason})]}),s.jsxs(jc,{size:"90px",children:[s.jsx(K,{$variant:"secondary",onClick:()=>r(!1),children:u("Cancel","Cancel")}),s.jsx(K,{$variant:"danger",onClick:x,disabled:f,children:u("Confirm","Confirm")})]})]})})},S2=({ban:n,isOpen:i,setOpen:r,refreshFunction:c})=>{const{t:u}=$(),[f,h]=S.useState(),[m,x]=S.useState(""),[g,v]=S.useState(""),[w,j]=S.useState(!1),[E,R]=S.useState(!1),B=S.useContext(pe),z=H=>{H.preventDefault(),!E&&(R(!0),me(B,ct(`/incursions/api/bans/${n.id}`,{method:"PATCH",json:{reason:m,public_reason:g,revoked_at:w?null:f}}).then(()=>{r(!1),c()}).finally(()=>R(!1))))};return S.useEffect(()=>{h(n.revoked_at??void 0),j(n.revoked_at==null),x(n.reason??""),v(n.public_reason??"")},[n]),s.jsx(Xe,{open:i,setOpen:r,children:s.jsxs(De,{children:[s.jsx(Ge,{children:u("Update {{type}} Ban:","Update {{type}} Ban:",{type:n.entity_type})}),s.jsxs("div",{style:{maxWidth:"500px",display:"flex"},children:[s.jsxs(_a,{children:[s.jsx(et,{children:u("{{type}}:","{{type}}:",{type:n.entity_type})}),s.jsx(u0,{...n})]}),s.jsxs(_a,{children:[s.jsx(et,{children:u("Issued By:","Issued By:")}),n.issued_by&&s.jsx(yt,{...n.issued_by})]})]}),s.jsxs("form",{onSubmit:z,children:[s.jsxs(_a,{children:[s.jsx(et,{required:!0,children:u("Expires:","Expires:")}),s.jsx(Kn,{type:"date",value:f?new Date(f*1e3).toISOString().substring(0,10):"",onChange:H=>h(new Date(H.target.value).getTime()/1e3),min:new Date(Date.now()+3600*1e3*24).toISOString().substring(0,10),disabled:w,required:!0}),s.jsx("span",{style:{margin:"0 5px"},children:u("or","or")}),s.jsxs("label",{style:{marginRight:"20px",marginBottom:"15px",display:"inline-block"},children:[s.jsx("input",{type:"checkbox",checked:w,onChange:()=>j(!w)}),u("Permanent","Permanent")]})]}),s.jsxs(_a,{children:[s.jsx(et,{htmlFor:`reason-${n.id}`,required:!0,children:u("Reason:","Reason:")}),s.jsx(on,{id:`reason-${n.id}`,value:m,onChange:H=>x(H.target.value),style:qg,required:!0})]}),s.jsxs(_a,{children:[s.jsx(et,{htmlFor:`public_reason-${n.id}`,children:u("Public Reason:","Public Reason:")}),s.jsx(on,{id:`public_reason-${n.id}`,value:g,onChange:H=>v(H.target.value),style:qg}),s.jsx(b2,{children:u("This reason will be shown to the pilot on the ban page.","This reason will be shown to the pilot on the ban page.")})]}),s.jsxs(jc,{size:"90px",children:[s.jsx(K,{$variant:"secondary",type:"button",onClick:()=>r(!1),children:u("Cancel","Cancel")}),s.jsx(K,{$variant:"danger",type:"submit",disabled:E,children:u("Confirm","Confirm")})]})]})]})})},$g={marginRight:"10px",marginBottom:"10px",appearance:"auto"},w2=({filters:n,onChange:i,onClear:r})=>{const{t:c}=$(),u={type:[{text:c("any duration","any duration"),value:"-1"},{text:c("permanent","permanent")},{text:c("temporary","temporary")}],entity_type:[{text:c("any type","any type"),value:"-1"},{text:c("account","account")},{text:c("alliance","alliance")},{text:c("character","character")},{text:c("corporation","corporation")}]},f=(m,x)=>{const g=m.target.value==="-1"?null:m.target.value;i({...n,[x]:g})},h=m=>{i({...n,name:m.target.value})};return s.jsxs("div",{id:"filters",children:[s.jsx("span",{children:c("Filter results by...","Filter results by...")}),s.jsx(ei,{value:n.entity_type??"",onChange:m=>f(m,"entity_type"),style:$g,children:u.entity_type.map((m,x)=>s.jsx("option",{value:m.value??m.text,disabled:m.text===c("account"),children:m.text},x))}),s.jsx(ei,{value:n.type??"",onChange:m=>f(m,"type"),style:$g,children:u.type.map((m,x)=>s.jsx("option",{value:m.value??m.text,children:m.text},x))}),s.jsx(Kn,{value:n.name??"",onChange:h,placeholder:c("name","name"),style:{marginRight:"10px",marginBottom:"10px"}}),s.jsx(K,{$variant:"primary",onClick:r,style:{marginBottom:"10px"},children:c("Clear","Clear")})]})},_2=n=>{const{t:i}=$(),[r,c]=S.useState(!1);return s.jsxs(s.Fragment,{children:[s.jsxs(K,{$variant:"primary",onClick:()=>c(!0),children:[s.jsx(fe,{fixedWidth:!0,icon:z1,style:{marginRight:"10px"}}),i("Issue Ban","Issue Ban")]}),s.jsx(v2,{isOpen:r,setOpen:c,...n})]})},T2=n=>{const{t:i}=$(),[r,c]=S.useState(!1);return s.jsxs(s.Fragment,{children:[s.jsx(K,{$variant:"danger",onClick:()=>c(!0),children:i("Revoke","Revoke")}),s.jsx(j2,{isOpen:r,setOpen:c,...n})]})},A2=n=>{const{t:i}=$(),[r,c]=S.useState(!1);return s.jsxs(s.Fragment,{children:[s.jsx(K,{onClick:()=>c(!0),children:i("Update","Update")}),s.jsx(S2,{isOpen:r,setOpen:c,...n})]})},C2=A.div`
  display: flex;
  flex-flow: column wrap;
  justify-content: space-around;
  padding-top: 10px;
  padding-bottom: 15px;

  p {
    padding-bottom: 5px;
    font-weight: bold;

    span {
      font-weight: normal;
      font-style: italic;
      font-size: small;
      color: ${n=>n.theme.colors.active};
    }
  }

  div {
    padding-bottom: 20px;

    &[mode='wide'] {
      display: flex;
      flex-flow: row wrap;

      div {
        min-width: 120px;
        width: 20vw;
      }
    }
  }
`,E2=({data:n,refreshFunction:i})=>{const{t:r}=$(),c=new Date,u=new Date(n.issued_at),f=n.revoked_at?new Date(n.revoked_at):null;return s.jsxs(C2,{children:[s.jsxs("div",{style:{paddingBottom:"0"},children:[s.jsxs("div",{children:[s.jsx("p",{children:r("Issued by:","Issued by:")}),s.jsx(yt,{...n.issued_by})]}),n.revoked_by&&s.jsxs("div",{children:[s.jsx("p",{children:r("Revoked by:","Revoked by:")}),s.jsx(yt,{...n.revoked_by})]})]}),s.jsxs("div",{style:{paddingBottom:"0"},children:[s.jsxs("div",{children:[s.jsx("p",{children:r("Issued at:","Issued at:")}),Ii(u)]}),f&&f<c&&s.jsxs("div",{children:[s.jsx("p",{children:r("Revoked at:","Revoked at:")}),ps(f)]})]}),f&&f>c&&s.jsxs("div",{children:[s.jsx("p",{children:r("Expires In:","Expires In:")}),s.jsx("span",{title:ps(f),children:bc(f)})]}),s.jsxs("div",{style:{wordWrap:"break-word",maxWidth:"70vw"},children:[s.jsxs("p",{children:[r("Reason:","Reason:")," ",s.jsx("span",{children:r("(this reason can ONLY be seen by the FC team)","(this reason can ONLY be seen by the FC team)")})]}),n.reason]}),n.public_reason&&s.jsxs("div",{style:{wordWrap:"break-word",maxWidth:"70vw"},children:[s.jsxs("p",{children:[r("Public Reason:","Public Reason:")," ",s.jsx("span",{children:r("(this reason can be seen by the pilot)","(this reason can be seen by the pilot)")})]}),n.public_reason]}),s.jsxs(Gt,{children:[s.jsx(A2,{ban:n,refreshFunction:i}),s.jsx(T2,{ban:n,refreshFunction:i})]})]})},O2=A.div`
  padding-bottom: 10px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-content: space-between;

  h1 {
    font-size: 32px;
  }
`,D2=A.div`
  align-content: space-between;
  display: flex;
  width: 100%;
  flex-wrap: wrap;

  > button {
    @media (max-width: 800px) {
      width: 100%;
    }
  }

  #filters {
    flex-grow: 1;

    span:first-of-type {
      font-style: italic;
      margin-right: 10px;

      @media (max-width: 800px) {
        display: block;
        margin-bottom: 5px;
      }
    }

    @media (max-width: 800px) {
      input,
      select {
        width: calc(calc(100vw - 158px) / 2);
      }
    }

    @media (max-width: 500px) {
      input,
      select {
        width: 100%;
      }
      button {
        display: block;
        width: 100%;
      }
    }
  }
`,M2=()=>{const[n,i]=Dt("/incursions/api/bans"),[r,c]=S.useState({type:null,name:"",entity_type:""}),u=[{name:"Name",sortable:!0,sortFunction:(m,x)=>c2(m.entity_name,x.entity_name),grow:3,selector:m=>{switch(m.entity_type){case"Character":return m.entity_character?s.jsx(yt,{...m.entity_character}):m.entity_name;case"Corporation":return m.entity_corporation?s.jsx(Cd,{...m.entity_corporation}):m.entity_name;case"Alliance":return m.entity_alliance?s.jsx(Ed,{...m.entity_alliance}):m.entity_name;default:return m.entity_name}}},{name:"Entity Type",sortable:!0,sortFunction:(m,x)=>u2(m.entity_type,x.entity_type),grow:1,selector:m=>m.entity_type},{name:"Expires",sortable:!0,hide:"sm",sortFunction:(m,x)=>o2(m.revoked_at,x.revoked_at),grow:1,selector:m=>m.revoked_at?ps(new Date(m.revoked_at)):"Never"},{name:"Reason",hide:"sm",grow:6,wrap:!0,selector:m=>m.reason}],f=S.useMemo(()=>(n??[]).filter(m=>(!r.entity_type||m.entity_type.toLowerCase()===r.entity_type)&&(!r.type||r.type==="permanent"&&!m.revoked_at||r.type==="temporary"&&m.revoked_at)&&m.entity_name.toLowerCase().includes(r.name.toLowerCase())),[n,r]),h=S.useMemo(()=>s.jsxs(D2,{children:[s.jsx(w2,{filters:r,onChange:m=>c({...m}),onClear:()=>c({type:null,name:"",entity_type:""})}),s.jsx(_2,{refreshFunction:i})]}),[r,i]);return Qe("Bans"),s.jsxs(s.Fragment,{children:[s.jsx(O2,{children:s.jsx("h1",{children:"System Bans"})}),s.jsx("p",{style:{marginBottom:"10px"},children:"Players who are banned or are in a banned corporation or alliance will be prevented from authenticating or joining the waitlist."}),s.jsx(Xd,{textAlign:"center",verticalAlign:"middle",columns:u,data:f,defaultSortFieldId:1,expandableRows:!0,expandableRowsComponent:E2,expandableRowsComponentProps:{refreshFunction:i},subHeader:!0,subHeaderComponent:h,progressPending:!n})]})},z2="/static/incursions/waitlist/static/img/fleetcomp-BQGhOhZ8.png",jn=A.span`
  background-color: ${n=>(n.theme.colors[n.$variant??""]||{}).color||"transparent"};
  color: ${n=>(n.theme.colors[n.$variant??""]||{}).text||n.theme.colors.text};
  filter: drop-shadow(0px 1px 1px ${n=>n.theme.colors.shadow});
  padding: 0 0.74em;
  border-radius: 4px;
  height: 2em;
  font-size: 0.75em;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
`,R2=A.span`
  display: flex;
  align-items: center;
`,Oa=A.div`
  margin: 0em 0.5em 0.5em 0;
  border: solid 2px ${n=>n.theme.colors.accent2};
  border-radius: 5px;
  background-color: ${n=>n.theme.colors.background};
  font-size: 1em;
  filter: drop-shadow(0px 3px 4px ${n=>n.theme.colors.shadow});
  width: 220px;
  height: 2.6em;
  &:hover:not(:disabled):not(.static) {
    border-color: ${n=>n.theme.colors.accent3};
    cursor: pointer;
  }
  @media (max-width: 480px) {
    width: 100%;
    height: 4em;
    margin: 0em 0.5em 1em 0;
  }
`;Oa.Content=A.div`
  display: flex;
  height: 100%;
  align-items: center;
  color: ${n=>n.theme.colors.text};
  img {
    border-radius: 3px 0px 0px 3px;
    margin-right: 0.5em;
    align-self: flex-start;
  }
`;Oa.Icon=A.div`
  display: flex;
  flex-wrap: wrap;
  margin-right: 0.2em;
  width: fit-content;
  padding: 0em 0.4em 0em;
  @media (max-width: 480px) {
    font-size: 1.3em;
  }
`;const Ts=A.div`
  width: 480px;
  @media (max-width: 580px) {
    width: 100%;
  }
`;Ts.Title=A.div`
  border-bottom: 3px solid;
  padding-bottom: 5px;
  margin-bottom: 1em;
  display: flex;
  border-color: ${n=>n.theme.colors.accent3};
`;const wn=({type:n="shield",color:i="neutral",letter:r="?",name:c="Unknown",height:u="1.2em"})=>{if(n==="shield")return s.jsx(bd,{color:i,letter:r,h:u,title:c})};function bd({color:n,letter:i,title:r,h:c="1.2em"}){const u=S.useContext(ni);return s.jsx(R2,{title:r,children:s.jsx("svg",{style:{height:c,filter:`drop-shadow(0px 1px 1px ${u.colors.shadow})`},viewBox:"0 0 26.5 27.8",xmlns:"http://www.w3.org/2000/svg",children:s.jsxs("g",{children:[s.jsx("path",{style:{fill:u.colors.tdfShields[n]},d:"m 13.229167,0 c 0,0 6.085417,0.79375 13.229167,3.96875 0,0 -0.79375,10.054167 -3.961217,15.955009 -2.275956,4.239997 -6.622116,7.857491 -9.26795,7.857491 M 13.229167,0 C 13.229167,0 7.14375,0.79375 0,3.96875 c 0,0 0.79375,10.054167 3.9612174,15.955009 2.2759552,4.239997 6.6221156,7.857491 9.2679496,7.857491"}),s.jsx("text",{style:{fontSize:"20px",fontWeight:"700",textAnchor:"middle",fill:u.colors.tdfShields.text,textRendering:"geometricPrecision"},x:"13.25",y:"20.5",children:i})]})})})}function d0({badges:n,height:i="40px"}){const c=ye.sortBy(n,u=>u.order??0).map(u=>s.jsx("div",{style:{marginRight:"0.2em"},children:s.jsx(wn,{type:u.type,letter:u.letter,name:u.name,color:u.color,order:u.order,height:i})},u.name));return s.jsx("div",{style:{display:"flex",marginBottom:"0.6em",flexWrap:"wrap"},children:c})}const rc=A.div`
  margin: 0 0 0.5em;
  display: flex;
  background-color: ${({theme:n,$variant:i})=>{var r;return(r=n.colors[i])==null?void 0:r.color}};
  color: ${({theme:n,$variant:i})=>{var r;return((r=n.colors[i])==null?void 0:r.text)??n.colors.text}};
  border-radius: 5px;
  width: ${({width:n})=>n??"fit-content"};
  filter: drop-shadow(0px 4px 5px ${({theme:n})=>n.colors.shadow});
  padding: 0.1em 0.5em 0.2em;
  vertical-align: middle;
  word-break: break-word;
`,ec=A.div`
  background-color: ${({theme:n})=>n.colors.accent1};
  border-radius: 20px;
  border: solid 1px ${({theme:n})=>n.colors.accent2};
  padding: 0.4em;
  font-size: min(calc(9px + 0.4vw), 14px);
`;function k2({variant:n="secondary",width:i="fit-content",children:r}){return s.jsxs(rc,{$variant:n,width:i,children:[s.jsx("div",{style:{marginRight:"0.5em"},children:s.jsx(fe,{icon:ix})}),r]})}const f0=["high","medium","low","rig","other","drone","cargo"],tc={};let nc=null;A.div`
  display: flex;
  @media (max-width: 480px) {
    flex-wrap: wrap;
  }
`;const Pa=A.div`
  display: flex;
  align-items: center;
  font-size: 1.2em;
  font-weight: 600;
  margin-bottom: 0.5em;

  @media (max-width: 480px) {
    font-size: 1em;
  }
`;Pa.Image=A.img`
  height: 2em;
  width: 2em;
  margin-right: 2em;

  @media (max-width: 480px) {
    margin-right: 0.5em;
  }
`;Pa.Name=A.span`
  @media (max-width: 480px) {
    overflow-wrap: anywhere;
  }
`;Pa.Copy=A.div`
  margin-left: auto;
  margin-right: 2em;
  cursor: pointer;
  font-size: 0.8em;
`;A.div`
  margin: 1em 0;
`;const B2=A.div`
  margin-bottom: 1em;
`,Be=A.div`
  display: flex;

  ${({group:n,theme:i})=>({have:"",missing:`
        background-color: ${i.colors.danger.color};
        color: ${i.colors.danger.text};
        text-decoration: line-through;
      `,extra:`
        background-color: ${i.colors.success.color};
        color: ${i.colors.success.text};
      `,downgraded_orig:`
        background-color: ${i.colors.warning.color};
        color: ${i.colors.warning.text};
        text-decoration: line-through;
      `,downgraded_new:`
        background-color: ${i.colors.warning.color};
        color: ${i.colors.warning.text};
      `,upgraded_orig:`
        background-color: ${i.colors.success.color};
        color: ${i.colors.success.text};
        text-decoration: line-through;
      `,upgraded_new:`
        background-color: ${i.colors.success.color};
        color: ${i.colors.success.text};
      `})[n||"have"]}

  > * {
    margin-right: 0.5em;
  }
`;Be.Image=A.img`
  height: 1.5em;
  width: 1.5em;
`;Be.Count=A.span`
  min-width: 1em;

  @media (max-width: 480px) {
    font-size: 0.7em;
  }
`;Be.ModuleName=A.span`
  @media (max-width: 480px) {
    font-size: 0.8em;
  }
`;async function N2(n){const i=n.split(",");nc||(nc=xe("/incursions/api/module/preload","get").then(u=>u).catch(()=>(nc=null,{})));const r=await nc;Object.entries(r).forEach(([u,f])=>{tc[u]=f});const c=i.filter(u=>!(u in tc)&&/^\d+_?$/.test(u)).map(u=>parseInt(u.replace(/_+$/,"")));if(c.length>0){const f=await xe("/incursions/api/module/info","post",{body:{ids:c}});Object.entries(f).forEach(([h,m])=>{tc[h]=m})}return Object.fromEntries(i.map(u=>[u,tc[u]??null]))}function U2(n){const[i,r]=S.useState({}),c=n.sort().join(",");return S.useEffect(()=>{let u=!1;return N2(c).then(f=>{u||r(f)}),()=>{u=!0}},[c]),i}function L2(n){const[i,...r]=n.split(":"),c=new Set,u={};return c.add(i),r.forEach(f=>{if(!f)return;const[h,m]=f.split(";");c.add(h),u[h]=(u[h]||0)+parseInt(m)}),[i,Array.from(c),u]}function H2(n){if(!n)return[];const i=new Set;return["missing","extra","cargo_missing"].forEach(r=>Object.keys(n[r]||{}).forEach(c=>i.add(c))),["downgraded","upgraded"].forEach(r=>Object.entries(n[r]||{}).forEach(([c,u])=>{i.add(c),Object.keys(u).forEach(f=>i.add(f))})),Array.from(i)}function is(n,i){var r;return n.endsWith("_")?"cargo":((r=i[n])==null?void 0:r.slot)??"cargo"}function q2(n,i,r){const c=Object.fromEntries(f0.map(u=>[u,{have:{},match:{},missing:{},extra:{},downgraded:{},upgraded:{}}]));if(Object.entries(n).forEach(([u,f])=>{const h=is(u,r);c[h].have[u]=f,c[h].match[u]=f}),i){for(const[u,f]of Object.entries((i==null?void 0:i.missing)||{}))c[is(u,r)].missing[u]=f;for(const[u,f]of Object.entries((i==null?void 0:i.extra)||{})){const h=is(u,r);h!=="drone"&&(c[h].match[u]=(c[h].match[u]||0)-f),c[h].extra[u]=f}for(const[u,f]of Object.entries((i==null?void 0:i.downgraded)||{})){const h=is(u,r);for(const[m,x]of Object.entries(f))c[h].match[m]=(c[h].match[m]||0)-x,c[h].downgraded[u]||(c[h].downgraded[u]={}),c[h].downgraded[u][m]=x}for(const[u,f]of Object.entries((i==null?void 0:i.upgraded)||{})){const h=is(u,r);for(const[m,x]of Object.entries(f))c[h].match[m]=(c[h].match[m]||0)-x,c[h].upgraded[u]||(c[h].upgraded[u]={}),c[h].upgraded[u][m]=x}}return c}const $2=({isDiff:n,groups:i,moduleInfo:r})=>{const c=n?["match","missing","extra"]:["have"];function u(f){return f.replace(/_+$/,"")}return s.jsxs(B2,{children:[c.map(f=>Object.entries(i[f]||{}).filter(([h,m])=>{if(f!=="match"||m!==0)return!0;const x=Object.values(i.downgraded).some(v=>h in v),g=Object.values(i.upgraded||{}).some(v=>h in v);return!(x||g)}).map(([h,m])=>{const x=u(h),g=r[x];return s.jsxs(Be,{group:f,children:[s.jsx(Be.Image,{src:`https://images.evetech.net/types/${x}/icon?size=64`,alt:(g==null?void 0:g.name)||h}),s.jsx(Be.Count,{children:m}),s.jsx(Be.ModuleName,{children:(g==null?void 0:g.name)||h})]},`${f}-${h}`)})),n&&Object.entries(i.downgraded).flatMap(([f,h])=>Object.entries(h).map(([m,x])=>{var g,v,w,j;return s.jsxs(J.Fragment,{children:[s.jsxs(Be,{group:"downgraded_orig",children:[s.jsx(Be.Image,{src:`https://images.evetech.net/types/${f.replace(/_+$/,"")}/icon?size=64`,alt:((g=r[f])==null?void 0:g.name)||f}),s.jsx(Be.Count,{children:x}),s.jsx(Be.ModuleName,{children:((v=r[f])==null?void 0:v.name)||f})]}),s.jsxs(Be,{group:"downgraded_new",children:[s.jsx(Be.Image,{src:`https://images.evetech.net/types/${m.replace(/_+$/,"")}/icon?size=64`,alt:((w=r[m])==null?void 0:w.name)||m}),s.jsx(Be.Count,{children:x}),s.jsx(Be.ModuleName,{children:((j=r[m])==null?void 0:j.name)||m})]})]},`${f}-${m}`)})),n&&Object.entries(i.upgraded||{}).flatMap(([f,h])=>Object.entries(h).map(([m,x])=>{var g,v,w,j;return s.jsxs(J.Fragment,{children:[s.jsxs(Be,{group:"downgraded_orig",children:[s.jsx(Be.Image,{src:`https://images.evetech.net/types/${f.replace(/_+$/,"")}/icon?size=64`,alt:((g=r[f])==null?void 0:g.name)||f}),s.jsx(Be.Count,{children:x}),s.jsx(Be.ModuleName,{children:((v=r[f])==null?void 0:v.name)||f})]}),s.jsxs(Be,{group:"downgraded_new",children:[s.jsx(Be.Image,{src:`https://images.evetech.net/types/${m.replace(/_+$/,"")}/icon?size=64`,alt:((w=r[m])==null?void 0:w.name)||m}),s.jsx(Be.Count,{children:x}),s.jsx(Be.ModuleName,{children:((j=r[m])==null?void 0:j.name)||m})]})]},`upgrade-${f}-${m}`)}))]})},Qd=({dna:n,analysis:i=null,name:r})=>{const{t:c}=$(),u=S.useContext(pe),[f,h,m]=S.useMemo(()=>L2(n),[n]),x=U2([...h,...H2(i)]),g=S.useMemo(()=>q2(m,i,x),[m,i,x]);if(!x[f])return s.jsx("em",{children:c("Loading fit info")});const v=()=>{const w=`[${x[f].name}, ${x[f].name}]

`+f0.map(j=>Object.entries(g[j].have).map(([E,R])=>{var B,z;return j==="cargo"||j==="drone"?`${((B=x[E])==null?void 0:B.name)??E} x${R}`:Array(R).fill(((z=x[E])==null?void 0:z.name)??E).join(`
`)}).join(`
`)).filter(Boolean).join(`

`);Zn(u,navigator.clipboard.writeText(w).then(()=>c("Copied to clipboard")))};return s.jsxs("div",{children:[s.jsxs(Pa,{children:[s.jsx(Pa.Image,{src:`https://images.evetech.net/types/${f}/icon?size=64`,alt:x[f].name}),s.jsx(Pa.Name,{children:r||(i==null?void 0:i.name)}),s.jsx(Pa.Copy,{onClick:v,title:c("Copy to clipboard"),children:s.jsx(fe,{icon:lx})})]}),i&&!i.name&&s.jsx("div",{children:s.jsx(jn,{$variant:"danger",children:c("Fit could not be automatically checked!")})}),Object.entries(g).map(([w,j])=>s.jsx("div",{children:s.jsx($2,{isDiff:!!i,groups:j,moduleInfo:x})},w))]})},h0=({implants:n,character_name:i,...r})=>{const c=`670:${n.map(u=>`${u};1`).join(":")}::`;return s.jsx(Qd,{dna:c,name:i,...r})},Zd=({fit:n})=>{var i;return s.jsxs("div",{style:{display:"flex",flexWrap:"wrap"},children:[s.jsx(Qd,{dna:n.dna,analysis:n.fit_analysis||{}}),n.implants&&s.jsx(h0,{implants:n.implants,character_name:((i=n.character)==null?void 0:i.character_name)??"Implants"})]})},G2=["xs","sm","md","lg","xl","offset"],Pi=A(({xs:n,sm:i,md:r,lg:c,xl:u,offset:f,children:h,...m})=>s.jsx(n1,{xs:n,sm:i,md:r,lg:c,xl:u,offset:f,...m,children:h})).withConfig({shouldForwardProp:(n,i)=>!G2.includes(n)&&i(n)})``,fs={Table:A.div`
    margin-bottom: 2em;
  `};fs.Table.Name=A.h3`
  border-bottom: solid 2px ${({theme:n})=>n.colors.accent2};
  font-weight: bolder;
  padding: 0.75em;
`;fs.Table.Row=A.div`
  display: flex;
  padding: 0.5em 0.75em;
  border-bottom: solid 1px ${({theme:n})=>n.colors.accent2};

  &:last-child {
    border-bottom: none;
  }
  &:nth-child(odd) {
    background-color: ${({theme:n})=>n.colors.accent1};
  }
  > :last-child {
    margin-left: auto;
  }
`;const V2=A.div`
  height: 36px;
`,m0=["Gunnery","Missiles","Drones","Spaceship Command","Subsystems","Armor","Shields","Navigation","Engineering","Electronic Systems","Fleet Support","Targeting","Neural Enhancement","Rigging"],Y2=new Set(m0),X2=({current:n,skill:i})=>{if(n===5)return s.jsx(jn,{$variant:"success",children:n});let r=null;for(const[c,u]of[["gold","success"],["elite","primary"],["min","secondary"]])if(c in i){if(n>=i[c])return s.jsxs(jn,{$variant:u,children:[n,r]});r=` / ${i[c]}`}for(const[c,u]of[["min","danger"],["elite","warning"],["gold","secondary"]])if(c in i)return s.jsxs(jn,{$variant:u,children:[n,r]});return null};function Q2({title:n,current:i,requirements:r,ids:c,category:u,filterMin:f}){const h=u.flatMap(m=>{if(!(m in r))return[];const x=r[m],g=i[m]??0;return f&&(!x.min||x.min<=g)?[]:s.jsxs(fs.Table.Row,{children:[c[m]," ",s.jsx(X2,{current:g,skill:x})]},m)});return h.length?s.jsx(Pi,{xs:4,sm:4,md:2,children:s.jsxs(fs.Table,{children:[s.jsx(fs.Table.Name,{children:n}),h]})}):null}function Z2({mySkills:n,shipName:i,filterMin:r}){const{t:c}=$();if(!n||!n.requirements||!n.categories||!n.ids)return s.jsx("em",{children:c("Loading skill information")});const u=ye.invert(n.ids);if(!(i in n.requirements))return s.jsx("em",{children:c("No skill information found")});const f=[...m0];return ye.forEach(ye.keys(n.categories),h=>{Y2.has(h)||f.push(h)}),s.jsx(xc,{children:f.map(h=>s.jsx(Q2,{title:c(h),current:n.current,requirements:n.requirements[i],category:n.categories[h],ids:u,filterMin:r},h))})}function p0({characterId:n,ship:i,setShip:r=null,filterMin:c=!1}){const{t:u}=$(),[f]=Dt(`/incursions/api/skills/${n}`);return s.jsxs(s.Fragment,{children:[r&&s.jsxs(Gt,{style:{marginBottom:"1em"},children:[s.jsx(ze,{children:["Vindicator","Kronos","Paladin"].map(h=>s.jsx(K,{$active:i===h,onClick:()=>r(h),children:u(h)},h))}),s.jsx(ze,{children:["Guardian","Nestor"].map(h=>s.jsx(K,{$active:i===h,onClick:()=>r(h),children:u(h)},h))}),s.jsx(ze,{children:["Eos","Damnation"].map(h=>s.jsx(K,{$active:i===h,onClick:()=>r(h),children:u(h)},h))})]}),s.jsxs("div",{style:{marginBottom:"1em"},children:[u("Legend"),":",s.jsx(jn,{$variant:"danger",children:u("Does Not Meet Requirements")}),s.jsx(jn,{$variant:"secondary",children:u("Minimum")}),s.jsx(jn,{$variant:"primary",children:u("Suggested")}),s.jsx(jn,{$variant:"success",children:u("#Swag")})]}),s.jsx(V2,{children:(i==="Nestor"||i==="Guardian"||i==="Oneiros")&&s.jsx(k2,{children:u("Basic tier skills are required for logistics.")})}),f?s.jsx(Z2,{mySkills:f,shipName:i,filterMin:c}):s.jsx("p",{children:u("Loading skill information")})]})}const K2=({relativeTo:n,isAlt:i})=>{const[r,c]=S.useState(Date.now());S.useEffect(()=>{const h=setInterval(()=>{c(Date.now())},6e4);return()=>clearInterval(h)},[]);const u=new Date(n).getTime(),f=Math.round((r-u)/1e3/60);return i?s.jsx("span",{title:`${f} min`,children:s.jsx(jn,{variant:"danger",children:"ALT"})}):s.jsxs(jn,{variant:"secondary",children:[f," min"]})},g0=n=>ct("/incursions/api/waitlist/approve",{json:{id:n}}),x0=(n,i)=>ct("/incursions/api/waitlist/reject",{json:{id:n,review_comment:i}}),F2=n=>ct("/incursions/api/waitlist/remove_waitlistentryfit",{json:{id:n}}),J2=(n,i)=>ct("/incursions/api/open_window",{json:{target_id:n,character_id:i}}),Ne=A.div`
  border: solid 2px ${n=>n.theme.colors[n.$variant].color};
  background-color: ${n=>n.theme.colors[n.$variant].color};
  color: ${n=>n.theme.colors[n.$variant].text};
  border-radius: 5px;
  font-size: 0.9em;
  filter: drop-shadow(0px 4px 5px ${n=>n.theme.colors.shadow});
  min-width: 245px;

  a {
    color: inherit;
    text-decoration: none;
  }
`;Ne.Head=A.div`
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: nowrap;
  padding: 0.2em 0.5em 0.3em 0.5em;
  gap: 0.5em;
`;Ne.Head.Left=A.div`
  white-space: nowrap;
  font-weight: 600;
`;Ne.Head.Center=A.div`
  flex: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25em;
  justify-content: center;
`;Ne.Head.Right=A.div`
  white-space: nowrap;
  font-size: 0.85em;
  display: flex;
  align-items: center;
`;Ne.Content=A.div`
  display: flex;
  background-color: ${n=>n.theme.colors.background};
  align-items: center;
  color: ${n=>n.theme.colors.text};

  img {
    margin-right: 0.5em;
    align-self: flex-start;
  }

  a {
    align-items: center;
    display: flex;
    cursor: pointer;
    width: 100%;
  }
`;Ne.FooterGroup=A.div`
  > *:last-child {
    border-radius: 0 0 4px 4px;
  }
`;Ne.Footer=A.div`
  display: flex;
  background-color: ${n=>n.theme.colors.accent1};
  color: ${n=>n.theme.colors.text};
  text-align: center;

  a:hover {
    background-color: ${n=>n.theme.colors.accent2};
    cursor: pointer;
  }

  > * {
    flex-grow: 1;
    flex-basis: 0;
  }
`;Ne.ReviewComment=A.div`
  padding: 0.5em;
  margin: 0.5em;
  width: 100%;
  text-align: center;
  background-color: ${n=>n.theme.colors.secondary.color};
  border-radius: 5px;
  color: ${n=>n.theme.colors.secondary.text};
  word-break: break-word;
`;Ne.ReviewComment.Header=A.div`
  border-bottom: 1px solid;
  margin-bottom: 1em;
  font-weight: bold;
`;function W2({fit:n,onAction:i}){var h,m;const r=J.useContext(He),c=J.useContext(pe),[u,f]=J.useState(!1);return n.dna?s.jsxs(s.Fragment,{children:[u?s.jsx(Xe,{open:!0,setOpen:f,children:s.jsxs(De,{children:[(r.access["incursions.waitlist_manage_waitlist"]||r.access["incursions.waitlist_manage_waitlist_approve_fits"])&&s.jsxs(Gt,{style:{marginBlock:"1em",marginTop:"0px"},children:[s.jsx(K,{$variant:"success",style:{minWidth:"95px"},onClick:()=>{f(!1),me(c,g0(n.id)).then(i)},children:"Approve"}),s.jsx(K,{$variant:"danger",style:{minWidth:"95px"},onClick:()=>{var x=prompt("Why is the fit being rejected? (Will be displayed to pilot)");x&&(f(!1),me(c,x0(n.id,x)).then(i))},children:"Reject"})]}),s.jsx(Zd,{fit:n})]})}):null,s.jsxs("a",{onClick:()=>f(!0),children:[s.jsx("img",{style:{height:"44px"},src:`https://images.evetech.net/types/${n.ship.id}/icon?size=64`,alt:n.ship.name}),s.jsxs("span",{style:{flexShrink:1},children:[(h=n.character)==null?void 0:h.character_name,": ",n.ship.name]})]})]}):s.jsxs(s.Fragment,{children:[s.jsx("img",{style:{height:"44px"},src:`https://images.evetech.net/types/${n.ship.id}/icon?size=64`,alt:n.ship.name}),s.jsxs("span",{style:{flexShrink:1},children:[(m=n.character)==null?void 0:m.character_name,": ",n.ship.name]})]})}function P2({characterId:n,ship:i}){const{t:r}=$(),[c,u]=S.useState(!1),[f,h]=S.useState(i);return s.jsxs(s.Fragment,{children:[s.jsx("a",{title:r("View Skills"),onClick:()=>u(!0),children:s.jsx(fe,{icon:N1})}),c&&s.jsx(Xe,{open:!0,setOpen:u,children:s.jsx(De,{children:s.jsx(J.Suspense,{fallback:s.jsx("p",{children:r("Loading skill information")}),children:s.jsx(p0,{characterId:n,ship:f,setShip:h})})})})]})}function jd({number:n}){const i=S.useContext(ni);return s.jsx("span",{style:{verticalAlign:"middle"},children:s.jsx("svg",{style:{height:"1em"},viewBox:"0 0 50 50",xmlns:"http://www.w3.org/2000/svg",children:s.jsxs("g",{children:[s.jsx("circle",{style:{verticalAlign:"middle",fill:i.colors.text},cy:"25",cx:"25",r:"24"}),s.jsx("text",{style:{fontSize:"2.6em",fontWeight:"600",textAnchor:"middle",fill:i.colors.accent1,textRendering:"geometricPrecision"},x:"25",y:"38",children:n})]})})})}function I2({fit:n}){const i=S.useContext(pe),{t:r}=$(),[c,u]=S.useState(null),[f,h]=S.useState(!1),m=n.character.character_id,x=()=>{f||(c?navigator.clipboard.writeText(c).then(()=>i(r("Copied to clipboard"))).catch(()=>i(r("Failed to copy to clipboard"))):(h(!0),me(i,xe("/incursions/api/pilot/discord","get",{params:{character_id:m}}).then(async g=>{const v=g.discord_username??null;u(v),h(!1),v?(await navigator.clipboard.writeText(v),i(r("Copied to clipboard"))):i(r("Discord not set"))}).catch(g=>{throw h(!1),g}))))};return s.jsx("a",{title:r("Copy Discord Username"),onClick:x,children:s.jsx(fe,{icon:B1,spin:f})})}function ew({fitId:n,onAction:i}){var w,j,E,R;const r=S.useContext(ni),c=S.useContext(pe),[u,f]=S.useState(),[h,m]=S.useReducer(B=>B+1,0),{t:x}=$(),g={success:(j=(w=r==null?void 0:r.colors)==null?void 0:w.success)==null?void 0:j.color,failed:(R=(E=r==null?void 0:r.colors)==null?void 0:E.danger)==null?void 0:R.color},v=async()=>{f("pending"),m(),me(c,ct("/incursions/api/waitlist/invite",{json:{fit:n}}).then(()=>{f("success"),i()}).catch(B=>{throw f("failed"),B}))};return s.jsx("a",{title:x("Invite to Fleet"),onClick:v,style:{cursor:u==="pending"?"not-allowed":void 0,backgroundColor:g[u??""]??void 0,transition:"background-color 300ms linear"},children:h<2?s.jsx(fe,{fixedWidth:!0,icon:u!=="pending"?rx:U1,spin:u==="pending"}):s.jsx(jd,{number:h})})}function Gg({from:n,message:i}){return s.jsxs(s.Fragment,{children:[s.jsx(Ne.ReviewComment.Header,{children:n}),s.jsx("div",{children:i})]})}function tw({characterId:n,id:i}){const{t:r}=$(),[c]=Dt(`/incursions/api/notes?character_id=${n}`);return!c||!c.notes?s.jsx(Ot,{to:`/pilot?character_id=${i}`,children:s.jsx(jd,{number:0})}):s.jsx(Ot,{to:`/pilot?character_id=${i}`,children:s.jsx(jd,{number:c.notes.length})})}function Rs({entry:n,fit:i,onAction:r}){var j,E,R;const{t:c}=$(),u=S.useContext(He),f=S.useContext(pe),h=i.is_alt,m=((j=n.main_character)==null?void 0:j.character_id)===(u==null?void 0:u.main_character_id)||i.character.character_id===u.current.character_id,g=ye.sortBy(i.badges,B=>B.order??0).map(B=>s.jsx(wn,{type:B.type,color:B.color,letter:B.letter,name:B.name,order:B.order})),v=i.approved?null:s.jsx("span",{title:c("Pending Approval"),children:s.jsx(fe,{icon:R1})}),w=i.approved?m?"success":"secondary":i.review_comment?"danger":m||u.access["incursions.waitlist_manage_waitlist"]||u.access["incursions.waitlist_manage_waitlist_approve_fits"]?"warning":"secondary";return s.jsxs(Ne,{$variant:w,children:[s.jsxs(Ne.Head,{children:[s.jsx(Ne.Head.Left,{children:(E=n.main_character)==null?void 0:E.character_name}),s.jsxs(Ne.Head.Center,{children:[g,v]}),s.jsx(Ne.Head.Right,{children:s.jsx(K2,{relativeTo:n.joined_at,isAlt:h})})]}),s.jsx(Ne.Content,{children:s.jsx(W2,{fit:i,onAction:r})}),i.review_comment&&s.jsx(Ne.Content,{children:s.jsx(Ne.ReviewComment,{children:s.jsx(Gg,{from:c("FC"),message:i.review_comment})})}),i.messagexup&&s.jsx(Ne.Content,{children:s.jsx(Ne.ReviewComment,{children:s.jsx(Gg,{from:c("Pilot"),message:i.messagexup})})}),s.jsxs(Ne.FooterGroup,{children:[s.jsxs(Ne.Footer,{children:[n.can_remove&&s.jsx("a",{title:c("Remove from Waitlist"),onClick:()=>me(f,F2(i.id)).then(r),children:s.jsx(fe,{icon:k1})}),u.access["incursions.waitlist_esi_show_info"]&&s.jsx("a",{title:c("Show Info In-Game"),onClick:()=>me(f,J2(i.character.character_id,u.current.character_id)),children:s.jsx(fe,{icon:As})}),u.access["incursions.waitlist_pilot_view"]&&s.jsx(I2,{fit:i}),u.access["incursions.waitlist_skills_view"]&&s.jsx(P2,{characterId:i.character.character_id,ship:((R=i.ship)==null?void 0:R.name)??""}),(u.access["incursions.waitlist_pilot_view"]||u.access["incursions.waitlist_notes_view"]||u.access["incursions.waitlist_notes_manage"])&&s.jsx(tw,{characterId:i.character.character_id,authContext:u,id:i.character.character_id}),ye.isFinite(i.hours_in_fleet)&&s.jsxs("span",{title:c("Hours in Fleet"),children:[i.hours_in_fleet,"h"]}),(u.access["incursions.waitlist_manage_waitlist"]||u.access["incursions.waitlist_manage_waitlist_approve_fits"])&&s.jsxs(s.Fragment,{children:[!i.approved&&s.jsx("a",{title:c("Reject Fit"),onClick:()=>{const B=prompt(c("Rejection Reason"));B&&me(f,x0(i.id,B)).then(r)},children:s.jsx(fe,{icon:_d})}),i.approved?s.jsx(ew,{fitId:i.id,onAction:r}):s.jsx("a",{title:c("Approve Fit"),onClick:()=>me(f,g0(i.id)).then(r),children:s.jsx(fe,{icon:sx})})]})]}),!h&&ye.isFinite(i.hours_in_fleet)&&i.hours_in_fleet<1&&s.jsx(Ne.Footer,{children:s.jsx("span",{children:c("NEW")})})]})]})}const mc=A.div`
  background-color: ${n=>n.theme.colors.accent1};
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 0 1em;
  border-radius: 10px;
  box-shadow: 2px 2px 3px ${n=>n.theme.colors.shadow};
  > h2 {
    font-size: 1.2em;
    font-weight: 600;
    padding: 0.2em;
  }
  > div {
    display: flex;
    opacity: 0.7;
    > span {
      flex: 1;
      display: inline-flex;
      align-items: center;
      padding: 0.2em;
      img {
        width: 1.5em;
        height: 1.5em;
        border-radius: 2px;
        margin-right: 0.2em;
      }
    }
  }
`,nw=A(mc)`
  border-radius: 5px;
  border: solid 1px ${n=>n.theme.colors.accent2};
  padding: 0 0.2em;
  > h2 {
    font-size: initial;
    font-weight: initial;
  }
`;function aw({name:n,shipCountsArr:i}){return s.jsxs(s.Fragment,{children:[s.jsx("h2",{children:n}),s.jsx("div",{children:i.map(([r,c])=>s.jsxs("span",{children:[s.jsx("img",{src:`https://images.evetech.net/types/${c.id}/icon?size=64`,alt:c.name}),r]},c.id))})]})}function Kd({name:n,fleetComposition:i,altCol:r=!0}){if(!(i!=null&&i.members))return!r&&n==="Alts"?null:s.jsx(mc,{children:s.jsx("h2",{children:n})});const c=i.members.filter(x=>x.wl_category===n);if(!r&&n==="Alts"&&c.length===0)return null;const u={},f={};for(const x of c)u[x.ship.id]=x.ship,f[x.ship.id]=(f[x.ship.id]||0)+1;const h=Object.entries(f).map(([x,g])=>[g,u[parseInt(x)]]).sort((x,g)=>g[0]-x[0]),m=!r&&n==="Alts"?nw:mc;return s.jsx(m,{children:s.jsx(aw,{name:n,shipCountsArr:h})})}const pc=A.div`
  display: flex;
  @media (max-width: 480px) {
    flex-wrap: wrap;
    width: 100%;
  }
`;pc.Category=A.div`
  flex-grow: 1;
  flex-basis: 0;
  padding: 0.5em;
  > div {
    margin-bottom: 1.5em;
  }
  @media (max-width: 480px) {
    width: 100%;
    flex-basis: unset;
  }
`;function iw({waitlist:n,onAction:i,fleetComposition:r,altCol:c=!1}){const u=[],f={};return n.categories.forEach(h=>{h==="Alts"&&!c||(f[h]=u.length,u.push([h,[]]))}),n.waitlist.forEach(h=>{h.fits.forEach(m=>{const x=c&&m.is_alt?"Alts":m.category,g=f[x];g!==void 0&&u[g][1].push(s.jsx("div",{children:s.jsx(Rs,{entry:h,fit:m,onAction:i})},m.id))})}),s.jsx(pc,{children:u.map(([h,m])=>s.jsxs(pc.Category,{children:[s.jsx(Kd,{name:h,fleetComposition:r,altCol:c}),m]},h))})}const lw=A.div`
  display: flex;
  flex-wrap: wrap;
  > div {
    padding: 0.5em;
  }
`;function sw({waitlist:n,onAction:i}){return s.jsx(lw,{children:n.waitlist.map(r=>r.fits.map(c=>s.jsx("div",{children:s.jsx(Rs,{entry:r,fit:c,onAction:i})},c.id)))})}const Sd=A.div``;Sd.Entry=A.div`
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 1em;
  > div {
    padding: 0.5em;
  }
`;function rw({waitlist:n,onAction:i}){return s.jsx(Sd,{children:n.waitlist.map(r=>s.jsx(Sd.Entry,{children:r.fits.map(c=>s.jsx("div",{children:s.jsx(Rs,{entry:r,fit:c,onAction:i})},c.id))},r.id))})}const cw=A.table`
  width: 100%;
  table-layout: fixed;
  text-align: left;
  > thead > tr > th {
    width: 1%;
  }
  th,
  td {
    padding: 0.5em;
  }
`;function ow({waitlist:n,onAction:i,fleetComposition:r}){const c=[],u={};return n.categories.forEach(f=>{u[f]=c.length,c.push([f,[]])}),s.jsx(cw,{children:s.jsxs("thead",{children:[s.jsx("tr",{children:c.map(([f])=>s.jsx("th",{children:s.jsx(Kd,{name:f,fleetComposition:r})},f))}),n.waitlist.map(f=>{const h=c.map(()=>[]);return f.fits.forEach(m=>{const x=m.is_alt?"Alts":m.category,g=u[x];g!==void 0&&h[g].push(s.jsx("div",{children:s.jsx(Rs,{entry:f,fit:m,onAction:i})},m.id))}),s.jsx("tr",{children:h.map((m,x)=>s.jsx("td",{children:m},x))},f.id)})]})})}const wd=A.div`
  overflow-x: auto;
`;wd.Category=A.div`
  padding: 0.5em 0.5em;
  display: flex;
  > div {
    margin: 0 0.75em;
  }
`;function uw({waitlist:n,onAction:i,fleetComposition:r}){const c=[],u={};return n.categories.forEach(f=>{u[f]=c.length,c.push([f,[]])}),n.waitlist.forEach(f=>{f.fits.forEach(h=>{const m=h.is_alt?"Alts":h.category,x=u[m];x!==void 0&&c[x][1].push(s.jsx("div",{children:s.jsx(Rs,{entry:f,fit:h,onAction:i})},h.id))})}),s.jsx(wd,{children:c.map(([f,h])=>s.jsxs("div",{children:[s.jsx(Kd,{name:f,fleetComposition:r}),s.jsx(wd.Category,{children:h})]},f))})}const dw=["Paladin","Kronos","Golem","Vargur"],y0=["Eos","Damnation","Claymore","Vulture","Sleipnir","Astarte"];function fw({characterId:n}){const[i]=Td(`/incursions/api/pilot/info?character_id=${n}`);return s.jsx(d0,{badges:i==null?void 0:i.tags,height:"14px"})}function hw({members:n,warnActive:i}){const{t:r}=$(),c=n.map(u=>u.ship.name).filter(u=>!y0.includes(u));return s.jsx(s.Fragment,{children:n.map(u=>s.jsxs(Ue,{noAlternating:!0,children:[s.jsx(Qn,{}),s.jsx(ob,{warn:c.length>2&&i?"yellow":void 0,children:u.role==="squad_commander"&&"★"}),s.jsx(Qn,{children:s.jsx(Ot,{exact:!0,to:`/pilot?character_id=${u.character_id}`,children:u.character_name})}),s.jsx(Qn,{children:r(u.ship.name)}),s.jsx(Qn,{children:s.jsx("div",{style:{display:"flex",justifyContent:"space-between"},children:s.jsx(fw,{characterId:u.character_id})})})]},u.character_id))})}function mw({members:n,squadname:i,warnActive:r}){const{t:c}=$();return n.sort((u,f)=>u.role==="squad_commander"?-1:f.role==="squad_commander"?1:0),s.jsxs(s.Fragment,{children:[s.jsxs(Ue,{noAlternating:!0,children:[s.jsx(Qn,{}),s.jsxs(Qn,{children:[c(i),n.length>0&&` (${n.length})`]}),s.jsx(Qn,{}),s.jsx(Qn,{}),s.jsx(Qn,{})]},i),s.jsx(hw,{members:n,warnActive:r})]})}function Vg({characterId:n,memberlist:i,showFull:r=!0}){const{t:c}=$(),u={Marauder:0,LogiNestor:0,LogiLoki:0,LogiGuardian:0,LogiBasilisk:0,Vindicator:0,Booster:0},f={};return i==null||i.forEach(h=>{f[h.ship.name]=(f[h.ship.name]||0)+1,y0.includes(h.ship.name)&&u.Booster++,dw.includes(h.ship.name)&&u.Marauder++,h.ship.name==="Vindicator"&&u.Vindicator++,h.ship.name==="Nestor"&&u.LogiNestor++,h.ship.name==="Loki"&&u.LogiLoki++,h.ship.name==="Guardian"&&u.LogiGuardian++,h.ship.name==="Basilisk"&&u.LogiBasilisk++}),s.jsxs("div",{style:r?{}:{display:"flex",justifyContent:"center"},children:[r&&s.jsx(Ge,{children:c("Fleet Summary")}),s.jsxs(ze,{style:{marginBottom:"1em"},children:[s.jsxs(ec,{children:[c("Marauders"),":",s.jsx("br",{}),u.Marauder]}),s.jsxs(ec,{children:[c("Logi N/L + G/B"),":",s.jsx("br",{}),u.LogiNestor,"/",u.LogiLoki," + ",u.LogiGuardian,"/",u.LogiBasilisk]}),s.jsxs(ec,{children:[c("Vindicators"),":",s.jsx("br",{}),u.Vindicator]}),s.jsxs(ec,{children:[c("Boosters"),":",s.jsx("br",{}),u.Booster]})]}),r&&s.jsxs(Fn,{children:[s.jsx(ai,{children:s.jsxs(Ue,{children:[s.jsx(Fe,{children:c("Ship")}),s.jsx(Fe,{children:"#"})]})}),s.jsx(Jn,{children:ye.sortBy(ye.entries(f),[1]).map(([h,m])=>s.jsxs(Ue,{children:[s.jsx(ae,{children:c(h)}),s.jsx(ae,{children:m})]},h))})]})]})}function pw(n,i,r,c){const u=J.useContext(el),{t:f}=$(),h=J.useContext(pe);J.useEffect(()=>{if(!u)return;const m=()=>{xe("/incursions/api/fleet/fleetcomp","get",{params:{character_id:n}}).then(i).catch(g=>{r(v=>v+1),c&&typeof g=="string"&&g.toLowerCase().includes("fleet")&&(c(!1),_n(h,{title:f("Error"),message:f("Failed to update fleet data. Fleet stats disabled."),variant:"danger"}))})},x=g=>{const v=JSON.parse(g.data);(v==null?void 0:v.event)==="fleet_comp"&&m()};return u.addEventListener("fleet_comp",x),u.addEventListener("open",m),()=>{u.removeEventListener("fleet_comp",x),u.removeEventListener("open",m)}},[n,u,h,f,i,r,c])}function gw(n){let i=n.boss?1:0;for(const r of n.squads)i+=r.members.length;return i}function v0({fleetpage:n=!0,setStatTempActive:i=null}){const{t:r}=$(),u=J.useContext(He).current.character_id,[f,h]=J.useState(null),[m,x]=J.useState(0);return pw(u,h,x,n?null:i),f?(f.wings.forEach(g=>{g.squads.sort((v,w)=>v.id-w.id)}),s.jsxs(pc.Category,{children:[!n&&s.jsx(mc,{children:s.jsx("h2",{children:r("Members")})}),s.jsxs("div",{style:{display:"flex",flexWrap:"wrap"},children:[s.jsxs("div",{children:[n&&s.jsx(Ge,{children:r("Members")}),!n&&s.jsx(Vg,{characterId:u,showFull:!1,memberlist:f.members}),s.jsx(Fn,{style:{fontSize:"12px"},fullWidth:!n,children:s.jsx(Jn,{children:f.wings.map((g,v)=>s.jsxs(J.Fragment,{children:[s.jsxs(Ue,{background:!0,noAlternating:!0,children:[s.jsxs(ae,{style:{fontWeight:"bold",width:"40px",whiteSpace:"nowrap"},children:[r(g.name.toUpperCase())," (",gw(g),")"]}),s.jsx(ae,{style:{width:"80px"}}),s.jsx(ae,{}),s.jsx(ae,{style:{width:"70px"}}),s.jsx(ae,{style:{width:"75px"}})]}),g.squads.map((w,j)=>s.jsx(mw,{squadname:w.name,members:w.members,warnActive:j>2&&v===0},w.name))]},g.name))})})]}),n&&s.jsx("div",{style:{marginLeft:"4em"},children:s.jsx(Vg,{characterId:u,showFull:!0,memberlist:f.members})})]})]})):null}function xw(){const[n,i]=S.useState(!1),[r,c]=S.useState(!1),u=S.useContext(He),f=S.useContext(pe),[h,m]=S.useState(null),{t:x}=$();return S.useEffect(()=>{xe("/incursions/api/fleet/status","get").then(m).catch(g=>me(f,Promise.reject(g)))},[f]),S.useEffect(()=>{window.Notification&&Notification.permission==="default"&&Notification.requestPermission()},[]),Qe(x("Fleet")),s.jsxs(s.Fragment,{children:[s.jsxs(Gt,{children:[s.jsx(ze,{children:s.jsx(Sn,{to:"/fc/fleet/register",children:x("Configure fleet")})}),s.jsx(ze,{children:s.jsx(Sn,{as:"a",href:"/incursions/char/add_fc",children:x("ESI re-auth as FC")})}),s.jsxs(ze,{children:[s.jsx(K,{$variant:"success",onClick:()=>Zn(f,xe("/incursions/api/waitlist/set_open","post",{body:{waitlist_id:1,open:!0}})),children:x("Open waitlist")}),s.jsx(K,{onClick:()=>Zn(f,xe("/incursions/api/waitlist/set_open","post",{body:{waitlist_id:1,open:!1}})),children:x("Close waitlist")}),s.jsx(K,{onClick:()=>c(!0),children:x("Empty waitlist")})]}),s.jsx(ze,{children:s.jsx(K,{$variant:"danger",onClick:()=>i(!0),children:x("Kick everyone from fleet")})})]}),s.jsxs(ot,{children:[s.jsx("p",{children:x("Make sure you re-auth via ESI, then create an in-game fleet with your comp. Click the 'Configure fleet' button, and select the five squads that the tool will invite people into. Then open the waitlist, allowing people to X up.")}),s.jsx("p",{children:x("To hand over the fleet, transfer the star (Boss role). Then the new FC should go via 'Configure fleet' again, as if it was a new fleet.")}),((h==null?void 0:h.fleets)??[]).map(g=>s.jsxs("div",{children:["STATUS: Fleet ",g.id,", boss ",g.boss.character_name]},g.id))]}),u.access["incursions.waitlist_history_view"]&&s.jsx(Gt,{children:s.jsx(ze,{children:s.jsx(Sn,{to:"/fc/fleet/history",children:x("Fleet comp history")})})}),s.jsx(v0,{}),s.jsx(zg,{open:n,setOpen:i,title:x("Kick everyone from fleet"),onConfirm:()=>Zn(f,xe("/incursions/api/fleet/close","post",{body:{character_id:u.current.character_id}})).finally(()=>i(!1)),children:x("Are you sure?")}),s.jsx(zg,{open:r,setOpen:c,title:x("Empty waitlist"),onConfirm:()=>Zn(f,xe("/incursions/api/waitlist/empty","post",{body:{waitlist_id:1}})).finally(()=>c(!1)),children:x("Are you sure?")})]})}function yw(){const n=S.useContext(He),i=S.useContext(pe),[r,c]=S.useState(null),[u,f]=S.useState(null),[h,m]=S.useState({}),{t:x}=$(),g=n.current.character_id;S.useEffect(()=>{c(null),xe("/incursions/api/fleet/info","get",{params:{character_id:g}}).then(c).catch(w=>me(i,Promise.reject(w))),f(null),xe("/incursions/api/categories","get").then(w=>f(w.categories)).catch(w=>me(i,Promise.reject(w)))},[g,i]),S.useEffect(()=>{if(!u||!r)return;const w={...h};let j=!1;for(const E of u)if(!(E.id in h))for(const R of r.wings)for(const B of R.squads){const z=B.name.toLowerCase();(z.includes(E.name.toLowerCase())||z.includes(String(E.id)))&&(w[E.id]=[R.id,B.id],j=!0)}j&&m(w)},[r,u,h]);const v=()=>{const w={character_id:g,fleet_id:r.fleet_id,assignments:h};Zn(i,xe("/incursions/api/fleet/register","post",{body:w}))};return!r||!u?s.jsx("em",{children:x("Loading fleet information.., Please be patient, this can take up to a minute")}):s.jsxs(s.Fragment,{children:[s.jsx("div",{style:{marginBottom:"1em"},children:x("Will be automatically filled if the squad names in your fleet match.")}),s.jsxs("div",{style:{display:"flex"},children:[s.jsx(vw,{categories:u,wings:r.wings,value:h,onChange:m}),s.jsx("img",{style:{marginLeft:"3em"},src:z2,alt:x("For auto filling, make sure the squad names match!")})]}),s.jsx(K,{$variant:"primary",onClick:v,children:x("Continue")})]})}function vw({categories:n,wings:i,value:r,onChange:c}){const{t:u}=$(),f=i.flatMap(h=>h.squads.map(m=>({name:`${h.name} - ${m.name}`,id:`${h.id},${m.id}`})));return s.jsx(ot,{children:n.map(h=>{var m;return s.jsxs("p",{children:[s.jsxs("label",{className:"label",children:[u(h.name),s.jsx("br",{})]}),s.jsxs(ei,{value:((m=r[h.id])==null?void 0:m.join(","))??"",onChange:x=>{const[g,v]=x.target.value.split(",").map(Number);c({...r,[h.id]:[g,v]})},children:[s.jsx("option",{}),f.map(x=>s.jsx("option",{value:x.id,children:x.name},x.id))]})]},h.id)})})}function bw(){const[n,i]=J.useState(""),[r,c]=J.useState(""),{t:u}=$(),f=n&&r?new Date(`${n}T${r}Z`):null,h=f?f.getTime()/1e3:null,[m]=Dt(h?`/incursions/api/history/fleet-comp?time=${h}`:null);return Qe(u("Fleet History")),s.jsxs(ot,{children:[s.jsx("h2",{children:u("Fleet history lookup")}),s.jsxs(ze,{children:[s.jsx(Kn,{type:"date",value:n,onChange:x=>i(x.target.value)}),s.jsx(Kn,{type:"time",value:r,onChange:x=>c(x.target.value)})]}),f?s.jsx("div",{children:s.jsx("em",{children:f.toString()})}):null,m&&s.jsx("h2",{children:u("Results")}),m&&ye.map(m.fleets,(x,g)=>s.jsxs("div",{children:[s.jsxs("h3",{children:[u("Fleet")," ",g]}),s.jsxs(Fn,{fullWidth:!0,children:[s.jsx(ai,{children:s.jsxs(Ue,{children:[s.jsx(Fe,{children:u("Pilot")}),s.jsx(Fe,{children:u("Ship")}),s.jsx(Fe,{children:u("Time")})]})}),s.jsx(Jn,{children:x.map(v=>s.jsxs(Ue,{children:[s.jsxs(ae,{children:[v.character_name,v.is_boss&&s.jsxs(s.Fragment,{children:[" ",s.jsx(fe,{icon:L1})]})]}),s.jsx(ae,{children:v.ship.name}),s.jsxs(ae,{children:[Ii(new Date(v.logged_at))," (",Ta(v.time_in_fleet),")"]})]},v.character_id))})]})]},g)),m&&ye.isEmpty(m.fleets)&&s.jsx("em",{children:u("Nothing found!")})]})}const Fd=A.div`
  margin: 0.4em 0;
  margin-right: 1em;
  width: 330px;

  @media (max-width: 480px) {
    width: 100%;
    margin-right: 0;
  }
`,jw=A.div`
  padding-bottom: 0.5em;
  background-color: ${({theme:n})=>n.colors.accent1};
  filter: drop-shadow(0px 1px 1px ${({theme:n})=>n.colors.shadow});
  border-radius: 5px;
  height: 100%;
  border: solid 1px ${({theme:n,$variant:i})=>{var r;return((r=n.colors[i])==null?void 0:r.color)??"transparent"}};

  &:hover {
    border: solid 1px ${({theme:n})=>n.colors.accent2};
  }
`,Sw=A.h3`
  font-weight: 600;
  padding: 0.2em 0.5em;
`,ww=A.div`
  padding: 0.5em 0.5em 0em;
`,b0=A.div`
  display: flex;
  align-items: stretch;
  flex-wrap: wrap;
`;function j0({variant:n,title:i,size:r,children:c,...u}){return s.jsxs(jw,{$variant:n,size:r,...u,children:[s.jsx(Sw,{children:i}),s.jsx(ww,{children:c})]})}const ls={},_w=A(ot)`
  max-width: 800px;
`;function Tw(n){return n.split("/").pop()}function Yg(){const n=J.useContext(pe),i=An(),r=Tw(i.pathname),[c,u]=J.useState(null),f=`./${r}`,h=`${f}/guide.md`,{t:m}=$();J.useEffect(()=>{if(u(null),!(h in ls))return;const g=document.title;return me(n,fetch(ls[h]).then(v=>v.text()).then(v=>{u(v),Vd(r0(v))})),()=>document.title=g},[n,h]);const x=g=>{const v=`${f}/${g}`;return v in ls?ls[v].default:g};return ls[h]?c?s.jsx(_w,{style:{maxWidth:"800px"},children:s.jsx(Cs,{transformImageUri:x,transformLinkUri:null,children:c})}):s.jsx(s.Fragment,{children:s.jsx("em",{children:m("Loading...")})}):s.jsx("div",{children:m("client : a{{loc}}a",{loc:r})})}function Qi({icon:n,slug:i,name:r,children:c}){const{t:u}=$();return s.jsx(Fd,{children:s.jsx(Ot,{style:{textDecoration:"inherit",color:"inherit"},exact:!0,to:`/fc/${i}`,children:s.jsx(j0,{title:s.jsxs(s.Fragment,{children:[s.jsx(fe,{fixedWidth:!0,icon:n})," ",u(r)]}),children:s.jsx("p",{children:u(c)})})})})}function Aw(){const n=J.useContext(He),{t:i}=$();return Qe(i("FC Menu")),s.jsxs(s.Fragment,{children:[s.jsx(Da,{children:i("FC Dashboard")}),s.jsxs(b0,{children:[n&&n.access["incursions.waitlist_announcements_manage"]&&s.jsx(Qi,{slug:"announcements",name:i("Announcements"),icon:ax}),n&&(n.access["incursions.waitlist_bans_view"]||n.access["incursions.waitlist_bans_manage"])&&s.jsx(Qi,{slug:"bans",name:i("Bans"),icon:vc}),n&&(n.access["incursions.waitlist_badges_view"]||n.access["incursions.waitlist_badges_manage"])&&s.jsx(Qi,{slug:"badges",name:i("Badges"),icon:H1}),n&&n.access["incursions.waitlist_documentation_view"]&&s.jsx(Qi,{slug:"documentation",name:i("FC Documentation"),icon:q1}),n&&n.access["incursions.waitlist_documentation_view"]&&s.jsx(Qi,{slug:"trainee",name:i("FC Training"),icon:$1}),n&&n.access["incursions.waitlist_stats_view"]&&s.jsx(Qi,{slug:"stats",name:i("Statistics"),icon:G1})]})]})}function Cw(){const{t:n}=$();Qe(n("Add Note"));const i=S.useContext(pe),[r,c]=S.useState(""),[u,f]=S.useState(!1),[h,m]=S.useState(null),x=new URLSearchParams(An().search),g=parseInt(x.get("character_id")??"",10),v=yc();if(S.useEffect(()=>{g&&me(i,sb(g).then(m))},[g,i]),!g)return s.jsx("em",{children:n("Missing character ID")});const w=R=>{c(R.target.value)},j=async R=>{R.preventDefault(),f(!0),me(i,rb(g,r).then(()=>v(`/pilot?character_id=${g}`)).finally(()=>f(!1)))},E=()=>{v(-1)};return s.jsxs(s.Fragment,{children:[s.jsxs(Da,{children:[n("Add note"),h&&`: ${h.character.character_name}`]}),s.jsx(on,{style:{width:"100%"},onChange:w,value:r,rows:5,cols:60}),s.jsx("p",{children:s.jsx("em",{children:n("Remember that notes cannot be removed!")})}),s.jsxs(ze,{children:[s.jsx(K,{$variant:"success",disabled:r.length<20||r.length>5e3||u,onClick:j,children:n("Save")}),s.jsx(K,{onClick:E,children:n("Never mind")})]})]})}function Jd(){const n=An(),i=yc(),r=n.search,c=S.useMemo(()=>{const f=new URLSearchParams(r),h={};for(const[m,x]of f.entries())h[m]=x;return h},[r]),u=S.useCallback((f,h,m=!1)=>{const x=new URLSearchParams(r);h===null?x.delete(f):x.set(f,h),i({search:`?${x.toString()}`},{replace:m})},[r,i]);return[c,u]}const Xg=A.div`
  margin-left: 40px;
  margin-bottom: 5px;
  &:first-of-type {
    min-height: 50px;
  }
  &:nth-of-type(2) {
    min-height: 100px;
  }
  @media (min-width: 400px) {
    min-width: 310px;
  }
  @media (max-width: 451px) {
    margin-left: 3px;
    span {
      display: block;
    }
    br {
      display: none;
    }
  }
`;function S0({character:n,refreshData:i}){const[r,c]=S.useState(!1);return s.jsxs(s.Fragment,{children:[s.jsx(K,{onClick:()=>c(!0),children:"Badges"}),r&&s.jsx(Ew,{character:n,isOpen:r,setOpen:c,refreshData:i})]})}const Ew=({character:n,isOpen:i,setOpen:r,refreshData:c})=>{const{t:u}=$(),f=S.useContext(pe),[h,m]=S.useState(),[x,g]=S.useState(!1),v=async()=>{try{const[z,H]=await Promise.all([xe("/incursions/api/badges","get"),xe("/incursions/api/pilot/info","get",{params:{character_id:n.character_id}})]),q=H.badges.map(X=>X.id),V=z.map(X=>({...X,default:q.includes(X.id),checked:q.includes(X.id)}));m(V)}catch(z){me(f,Promise.reject(z))}};S.useEffect(()=>{i&&v()},[i]);const w=z=>xe("/incursions/api/badges/{badge_id}/members","post",{params:{badge_id:z},body:{character_id:n.character_id}}),j=z=>xe("/incursions/api/badges/{badge_id}/members/{character_id}","delete",{params:{badge_id:z,character_id:n.character_id}}),E=async()=>{if(!h)return;g(!0);const z=h.filter(q=>q.default&&!q.checked).map(q=>Zn(f,j(q.id))),H=h.filter(q=>!q.default&&q.checked).map(q=>Zn(f,w(q.id)));await Promise.all([...z,...H]),g(!1),v(),c&&c()},R=(z,H)=>{if(!h)return;const q=[...h];q[H]={...q[H],checked:z.target.checked},m(q)},B=()=>{const z=(h==null?void 0:h.filter(q=>q.default))??[];return ye.sortBy(z,q=>q.order??0).map(q=>s.jsx("span",{style:{marginRight:"5px",display:"inline-block"},children:s.jsx(wn,{type:q.type,color:q.color,letter:q.letter,name:q.name,order:q.order})},q.id))};return s.jsx(Xe,{open:i,setOpen:r,children:s.jsxs(De,{children:[s.jsx(Ge,{style:{marginBottom:"5px"},children:s.jsx(yt,{...n,avatarSize:32,noLink:!0})}),s.jsx(Xg,{children:h?s.jsxs(s.Fragment,{children:[s.jsx("p",{children:u("badge.current","Current Badges:")}),s.jsx("span",{children:B()})]}):s.jsx("small",{style:{fontStyle:"italic",fontSize:"smaller"},children:u("badge.loading","Loading...")})}),s.jsx(Xg,{children:h==null?void 0:h.map((z,H)=>s.jsxs("span",{children:[H%3===0&&s.jsx("br",{}),s.jsxs("label",{style:{marginRight:"20px",marginBottom:"15px",display:"inline-flex",alignItems:"center",gap:"6px"},htmlFor:`badge-${H}`,children:[s.jsx("input",{id:`badge-${H}`,type:"checkbox",checked:z.checked,onChange:q=>R(q,H)}),s.jsx(wn,{type:z.type,color:z.color,letter:z.letter,name:z.name,order:z.order}),s.jsx("span",{children:z.name})]})]},H))}),s.jsxs(jc,{children:[s.jsx(K,{$variant:"success",onClick:E,disabled:x,children:u("form.confirm","Confirm")}),s.jsx(K,{onClick:()=>r(!1),children:u("form.close","Close")})]})]})})};function Ow(){const n=J.useContext(He),{t:i}=$();var[{query:r},c]=Jd();const u=h=>{c("query",h||null,!0)},[f]=Dt(r&&r.length>=3?"/incursions/api/search?"+new URLSearchParams({query:r}):null);return Qe(i("Search")),s.jsxs(s.Fragment,{children:[s.jsx("div",{style:{marginBottom:"1em"},children:s.jsxs("label",{children:[s.jsx("strong",{children:i("Search term:")}),s.jsx("br",{}),s.jsx(Kn,{value:r??"",onChange:h=>u(h.target.value)})]})}),f==null?null:f.results.length?s.jsxs(Fn,{fullWidth:!0,children:[s.jsx(ai,{children:s.jsxs(Ue,{children:[s.jsx(Fe,{children:i("Name")}),s.jsx(Fe,{children:i("Character ID")}),s.jsx(Fe,{style:{width:"50%"}})]})}),s.jsx(Jn,{children:f.results.map(h=>s.jsxs(Ue,{children:[s.jsx(ae,{children:h.character_name}),s.jsx(ae,{children:h.character_id}),s.jsx(ae,{children:s.jsxs(Gt,{marginb:"0em",children:[s.jsxs(ze,{children:[s.jsx(Sn,{to:"/skills?character_id="+h.character_id,children:i("Skills")}),s.jsx(Sn,{to:"/pilot?character_id="+h.character_id,children:i("Information")})]}),s.jsx(ze,{children:(n.access["incursions.waitlist_badges_view"]||n.access["incursions.waitlist_badges_manage"])&&s.jsx(S0,{character:h})})]})})]},h.character_id))})]}):s.jsx("em",{children:i("No results")})]})}tx.register(u1,d1,f1,h1,m1,p1,g1,x1,y1);tx.register(...v1);const wa=A(Pi).attrs({md:4})`
  max-height: 350px;
`;function Qg(n,i){let r=1546047137;for(let h=0;h<i.length;h++)r=i.charCodeAt(h)+((r<<5)-r);r=r&2147483647;const c=r%360,u=(r>>10)%60+30,f=Math.round(n.colors.lumFactor*50);return`hsla(${c}, ${u}%, ${f}%, 1)`}function Wd(n,i){return ye.merge({},{maintainAspectRatio:!1,animation:!1,color:n.colors.text,backgroundColor:n.colors.accent1,borderColor:n.colors.accent2,plugins:{title:{color:n.colors.text}},scales:{x:{ticks:{color:n.colors.text},grid:{color:n.colors.accent2}},y:{ticks:{color:n.colors.text},grid:{color:n.colors.accent2}}}},i||{})}function Pd(n,i,r){const c=ye.cloneDeep(i);if(c.datasets)for(const u of c.datasets){for(const f of["backgroundColor","borderColor"])u[f]||(r?u[f]=c.labels.map(h=>Qg(n,h)):u[f]=Qg(n,u.label||""));u.fill===void 0&&(u.fill=!0)}return c}function Id({options:n,data:i,...r}){const c=J.useContext(ni);return s.jsx(j1,{options:Wd(c,n),data:Pd(c,i,!1),...r})}function ef({options:n,data:i,...r}){const c=J.useContext(ni);return s.jsx(b1,{options:Wd(c,n),data:Pd(c,i,!1),...r})}function w0({options:n,data:i,...r}){const c=J.useContext(ni);return s.jsx(S1,{options:Wd(c,n),data:Pd(c,i,!0),...r})}function ks(n){const i=Object.keys(n).sort(),r=i.map(c=>n[c]);return{labels:i,data:r}}function Mc(n){const i=ks(n),r={};for(let c=0;c<i.labels.length;c++)for(const[u,f]of Object.entries(i.data[c]))r[u]||(r[u]=new Array(i.labels.length).fill(null)),r[u][c]=f;return{labels:i.labels,series:r}}function Dw({data:n}){const{t:i}=$(),r=ks(n);return s.jsx(ef,{data:{labels:r.labels,datasets:[{label:i("Hours"),data:r.data.map(c=>Math.round(c/3600))}]},options:{plugins:{title:{display:!0,text:i("Total fleet time")}}}})}function Mw({data:n}){const{t:i}=$(),r=ks(n);return s.jsx(ef,{data:{labels:r.labels,datasets:[{label:i("Pilots"),data:r.data}]},options:{plugins:{title:{display:!0,text:i("Pilots seen in fleet")}}}})}function zw({data:n}){const{t:i}=$(),r=Mc(n);return s.jsx(Id,{data:{labels:r.labels,datasets:Object.entries(r.series).map(([c,u])=>({label:i(c),data:u.map(f=>Math.round(f/3600))}))},options:{scales:{x:{stacked:!0},y:{stacked:!0}},plugins:{title:{display:!0,text:i("Time in fleet by ship")}}}})}function Rw({data:n}){const{t:i}=$(),r=Mc(n);return s.jsx(ef,{data:{labels:r.labels,datasets:Object.entries(r.series).map(([c,u])=>({label:i(c),data:u.map(f=>f||0)}))},options:{plugins:{title:{display:!0,text:i("X'es by ship")}}}})}function kw({data:n}){const{t:i}=$(),r=Mc(n);return s.jsx(Id,{data:{labels:r.labels,datasets:Object.entries(r.series).map(([c,u])=>({label:i(c),data:u.map(f=>f||0)}))},options:{plugins:{title:{display:!0,text:i("Distribution of time in fleet")}}}})}function Bw({data:n}){const{t:i}=$(),r=Mc(n);return s.jsx(Id,{data:{labels:r.labels,datasets:Object.entries(r.series).map(([c,u])=>({label:i(c),data:u.map(f=>Math.round((f||0)*1e3)/10)}))},options:{plugins:{title:{display:!0,text:i("Time vs X'es in percentages (28d)")}}}})}function Nw({data:n}){const{t:i}=$(),r=ks(n);return s.jsx(w0,{data:{labels:r.labels.map(c=>i(c)),datasets:[{data:r.data}]},options:{plugins:{title:{display:!0,text:i("X'es by ship (28d)")}}}})}function Uw({data:n}){const{t:i}=$(),r=ks(n);return s.jsx(w0,{data:{labels:r.labels.map(c=>i(c)),datasets:[{data:r.data.map(c=>Math.round((c||0)/3600))}]},options:{plugins:{title:{display:!0,text:i("Time in fleet by ship (28d)")}}}})}function Lw(){const{t:n}=$();Qe(n("Statistics"));const[i]=Dt("/incursions/api/stats");return i?s.jsxs(xc,{children:[s.jsx(wa,{children:s.jsx(Dw,{data:i.fleet_seconds_by_month})}),s.jsx(wa,{children:s.jsx(Mw,{data:i.pilots_by_month})}),s.jsx(wa,{children:s.jsx(zw,{data:i.fleet_seconds_by_ship_by_month})}),s.jsx(wa,{children:s.jsx(Rw,{data:i.xes_by_ship_by_month})}),s.jsx(wa,{children:s.jsx(kw,{data:i.time_spent_in_fleet_by_month})}),s.jsx(wa,{children:s.jsx(Bw,{data:i.x_vs_time_by_ship_28d})}),s.jsx(wa,{children:s.jsx(Nw,{data:i.xes_by_ship_28d})}),s.jsx(wa,{children:s.jsx(Uw,{data:i.fleet_seconds_by_ship_28d})})]}):s.jsx("em",{children:n("Loading statistics...")})}const Hw=A.ul`
  position: absolute;
  width: 100%;
  background: ${({theme:n})=>{var i;return(i=n.colors)==null?void 0:i.accent1}};
  z-index: 500;
  border: 1px solid #999;
  border-top-width: 0;
  list-style: none;
  margin-top: 0;
  overflow-y: auto;
  padding-left: 0;

  > li {
    padding: 0.5rem;

    &.active,
    &:hover {
      color: ${({theme:n})=>{var i;return(i=n.active)==null?void 0:i.text}};
      cursor: pointer;
      font-weight: 700;
    }
  }
`,qw=A.div`
  color: ${({theme:n})=>{var i,r;return(r=(i=n.colors)==null?void 0:i.secondary)==null?void 0:r.text}};
  padding: 0.5rem;
  font-style: italic;
`,$w=({id:n="pilot-search",onChange:i,style:r,resetSearch:c,hideNotFound:u=!1})=>{const{t:f}=$(),[h,m]=S.useState(0),[x,g]=S.useState(!1),[v,w]=S.useState([]),[j,E]=S.useState(""),[R,B]=S.useState(""),z=Z=>{B(Z),E(Z)},[H]=Dt(R&&R.length>=3?`/incursions/api/search?${new URLSearchParams({query:R})}`:null);S.useEffect(()=>{let Z=!1;const ee=(H==null?void 0:H.results.filter(de=>(de.character_name.toLowerCase()===j.toLowerCase()&&(i(de),E(de.character_name),m(0),Z=!0),de.character_name.toLowerCase().includes(j.toLowerCase()))))??[];w(ee),g(!Z)},[H,j,i]),S.useEffect(()=>{E(""),w([]),g(!1),m(0)},[c]);const q=Z=>{m(0),g(!1),E(Z.currentTarget.innerText);const ee=v.find(de=>de.character_name.toLowerCase()===Z.currentTarget.innerText.toLowerCase());ee&&i(ee)},V=Z=>{if(v.length)if(Z.key==="Enter"){Z.preventDefault();const ee=v[h];ee&&(i(ee),E(ee.character_name),m(0),g(!1))}else Z.key==="ArrowUp"?(Z.preventDefault(),m(ee=>Math.max(0,ee-1))):Z.key==="ArrowDown"&&(Z.preventDefault(),m(ee=>Math.min(v.length-1,ee+1)))},X=()=>!x||!j?null:v.length?s.jsx(Hw,{children:v.map((Z,ee)=>s.jsx("li",{className:ee===h?"active":void 0,onClick:q,children:Z.character_name},Z.character_id))}):u?null:s.jsx(qw,{children:f("Could not find {{character_name}} in the database, sorry.",{character_name:j})});return s.jsxs("div",{style:{position:"relative"},children:[s.jsx(Kn,{id:n,type:"text",value:j,onChange:Z=>z(Z.target.value),onKeyDown:V,style:r,autoComplete:"off"}),X()]})},Zg=A.div`
  margin: 15px 0px;
`,Gw=A.p`
  margin-bottom: 20px;
`,Vw=({badgeOptions:n=[],isOpen:i,setOpen:r,refreshFunction:c})=>{const{t:u}=$(),f=S.useContext(pe),[h,m]=S.useState(0),[x,g]=S.useState(void 0),[v,w]=S.useState(void 0),[j,E]=S.useState(!1),R=async z=>{if(z.preventDefault(),!v||isNaN(v))return _n(f,{title:u("Error:"),message:u("You need to search for a pilot..."),variant:"danger"});E(!0),await me(f,ct(`/incursions/api/badges/${x}/members`,{method:"POST",json:{character_id:v}}).then(()=>{c(),B()}).finally(()=>E(!1)))},B=()=>{var z;g(((z=n==null?void 0:n[0])==null?void 0:z.id)??void 0),w(void 0),r(!1),m(H=>H+1)};return S.useEffect(()=>{!x&&n.length>0&&g(n[0].id)},[n,x]),s.jsx(Xe,{open:i,setOpen:r,children:s.jsxs(De,{style:{overflowY:"hidden"},children:[s.jsx(Ge,{children:u("Assign a Specialist Badge")}),s.jsxs("form",{onSubmit:R,children:[s.jsxs(Zg,{children:[s.jsx(et,{htmlFor:"pilot-search",required:!0,children:u("Search for a pilot:")}),s.jsx($w,{required:!0,resetSearch:h,style:{width:"100%"},onChange:z=>w(z.character_id),hideNotFound:!0})]}),s.jsxs(Zg,{children:[s.jsx(et,{htmlFor:"badge-select",required:!0,children:u("Select badge type:")}),s.jsx(ei,{id:"badge-select",value:x,onChange:z=>g(parseInt(z.target.value)),style:{width:"100%",appearance:"auto"},required:!0,children:n.map(z=>s.jsx("option",{value:z.id,children:z.name},z.id))})]}),s.jsx(K,{$variant:"success",disabled:j,children:u("Confirm")})]})]})})},Yw=n=>{const{t:i}=$(),[r,c]=S.useState(!1);return s.jsxs(s.Fragment,{children:[s.jsx(K,{$variant:"danger",onClick:()=>c(!0),children:i("Revoke")}),s.jsx(Xw,{isOpen:r,setOpen:c,...n})]})},Xw=({badge:n,character:i,isOpen:r,setOpen:c,refreshFunction:u})=>{const{t:f}=$(),h=S.useContext(pe),[m,x]=S.useState(!1),g=async()=>{m||(x(!0),await me(h,ct(`/incursions/api/badges/${n.id}/members/${i.character_id}`,{method:"DELETE"}).then(()=>{u(),c(!1)}).finally(()=>x(!1))))};return s.jsx(Xe,{open:r,setOpen:c,children:s.jsxs(De,{children:[s.jsx(Ge,{children:f("Revoke {{badge}}",{badge:n.name})}),s.jsxs(Gw,{children:[f("From"),": ",s.jsx(yt,{...i,noLink:!0,avatar:!1})]}),s.jsxs(jc,{size:"90px",children:[s.jsx(K,{$variant:"secondary",onClick:()=>c(!1),children:f("Cancel")}),s.jsx(K,{$variant:"danger",onClick:g,disabled:m,children:f("Confirm")})]})]})})},Qw=A.div`
  padding-bottom: 10px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-content: space-between;

  h1 {
    font-size: 32px;
  }
`,Zw=A.div`
  align-content: space-between;
  display: flex;
  width: 100%;
  flex-wrap: wrap;

  > button {
    @media (max-width: 800px) {
      width: 100%;
    }
  }

  #filters {
    flex-grow: 1;

    span:first-of-type {
      font-style: italic;
      margin-right: 10px;

      @media (max-width: 800px) {
        display: block;
        margin-bottom: 5px;
      }
    }

    @media (max-width: 800px) {
      input,
      select {
        width: calc(calc(100vw - 158px) / 2);
      }
    }

    @media (max-width: 500px) {
      input,
      select {
        width: 100%;
      }
      button {
        display: block;
        width: 100%;
      }
    }
  }
`,rd=(n,i)=>n.character_name.toLowerCase().localeCompare(i.character_name.toLowerCase()),Kw=({badgeOptions:n,filters:i,onChange:r,onClear:c})=>{const{t:u}=$();return s.jsxs("div",{id:"filters",children:[s.jsx("span",{children:u("Filter results by...")}),s.jsxs(ei,{value:(i==null?void 0:i.type)??"",onChange:f=>r({...i,type:f.target.value==="-1"?null:parseInt(f.target.value)}),style:{marginRight:"10px",marginBottom:"10px",appearance:"auto"},children:[s.jsx("option",{value:-1,children:u("any type...")}),n.map(f=>s.jsxs("option",{value:f.id,children:[f.name," (",f.member_count.toLocaleString(),")"]},f.id))]}),s.jsx(Kn,{value:i.name??"",onChange:f=>r({...i,name:f.target.value}),placeholder:u("pilot name"),style:{marginRight:"10px",marginBottom:"10px"}}),s.jsx(K,{$variant:"primary",onClick:c,style:{marginBottom:"10px"},children:u("Clear")})]})},Fw=()=>{const[n,i]=Dt("/incursions/api/badges"),[r,c]=S.useState(null),[u,f]=S.useState(!1),[h,m]=S.useState({type:null,name:""}),{t:x}=$();S.useEffect(()=>{n&&Promise.all(n.map(j=>ct(`/incursions/api/badges/${j.id}/members`,{}).catch(()=>[]))).then(j=>{c(j.flat().filter(Boolean))})},[n]);const g=[{name:x("Pilot Name"),sortable:!0,sortFunction:(j,E)=>rd(j.character,E.character),grow:2,selector:j=>s.jsx(yt,{...j.character})},{name:x("Badge"),sortable:!0,sortFunction:(j,E)=>rd(j.badge,E.badge),grow:1,selector:j=>s.jsx(wn,{type:j.badge.name,height:"1.8em"})},{name:x("Granted By"),sortable:!0,sortFunction:(j,E)=>rd(j.granted_by,E.granted_by),hide:"md",grow:2,selector:j=>s.jsx(yt,{...j.granted_by})},{name:x("Granted At"),hide:"sm",grow:2,selector:j=>Ii(new Date(j.granted_at))},{name:"",grow:1,minWidth:"95",selector:j=>s.jsx(Yw,{badge:j.badge,character:j.character,refreshFunction:i})}],v=S.useMemo(()=>s.jsxs(Zw,{children:[s.jsx(Kw,{badgeOptions:n??[],filters:h,onChange:j=>m(j),onClear:()=>m({type:null,name:""})}),s.jsxs(K,{$variant:"primary",onClick:()=>f(!0),style:{marginBottom:"10px"},children:[s.jsx(fe,{fixedWidth:!0,icon:rx,style:{marginRight:"10px"}}),x("Assign Badge")]})]}),[h,n,x]),w=(r??[]).filter(j=>j&&j.character&&(!h.type||j.badge.id===h.type)&&j.character.character_name.toLowerCase().includes(h.name.toLowerCase()));return Qe(x("Specialist Badges")),s.jsxs(s.Fragment,{children:[s.jsx(Qw,{children:s.jsx("h1",{children:x("Specialist Badges")})}),s.jsxs("p",{style:{marginBottom:"10px"},children:[x("You can find the badge guide")," ",s.jsx(gc,{to:"/badges",children:x("here")}),"."]}),s.jsx(Xd,{columns:g,data:w,defaultSortFieldId:1,subHeader:!0,subHeaderComponent:v,progressPending:!r}),s.jsx(Vw,{badgeOptions:n??[],isOpen:u,setOpen:f,refreshFunction:i})]})},Kg="/static/incursions/waitlist/static/img/w-S0yXGjWr.png";function _0(n,i){Zn(n,navigator.clipboard.writeText(i).then(()=>"Copied to clipboard"))}function Jw({type:n}){const i=J.useContext(pe),{t:r}=$();var c;switch(n){case"Amulet":c=["Mid-grade Amulet Alpha","Mid-grade Amulet Beta","Mid-grade Amulet Gamma","Mid-grade Amulet Delta","Mid-grade Amulet Epsilon"];break;case"Ascendancy":c=["High-grade Ascendancy Alpha","High-grade Ascendancy Beta","High-grade Ascendancy Gamma","High-grade Ascendancy Delta","High-grade Ascendancy Epsilon"];break;case"None":c=[];break;default:c=[]}return s.jsx(s.Fragment,{children:s.jsxs(Fn,{style:{width:"100%"},children:[s.jsx(ai,{children:s.jsxs(Ue,{children:[s.jsx(cb,{}),s.jsx(Fe,{children:r("DEFAULT")}),s.jsx(Fe,{children:r("ALTERNATIVE (not required)")})]})}),s.jsxs(Jn,{children:[c.map((u,f)=>s.jsx(Ww,{toast:i,slot:f+1,implant:u},f)),s.jsxs(Ue,{children:[s.jsx(ae,{children:s.jsx("b",{children:r("Slot 6")})}),n==="Amulet"?s.jsx(ae,{children:s.jsx(Ie,{toast:i,item:"Mid-Grade Amulet Omega"})}):n==="Ascendancy"?s.jsxs(ae,{children:[s.jsx(Ie,{toast:i,item:"WS-518"})," ",r("+18% warp speed")]}):s.jsxs(ae,{children:[s.jsx(Ie,{toast:i,item:"High-grade Ascendancy Omega"})," ",r("+21% warp speed")]})]}),s.jsx(Pw,{toastContext:i})]})]})})}function Ww({toast:n,slot:i,implant:r}){const{t:c}=$();return s.jsxs(Ue,{children:[s.jsx(ae,{children:s.jsxs("b",{children:[c("Slot")," ",i]})}),s.jsx(ae,{children:s.jsx(Ie,{toast:n,item:r})}),s.jsx(ae,{})]})}function Ie({toast:n,item:i}){return s.jsx(Tb,{onClick:()=>{_0(n,i)},children:i})}function Pw({toastContext:n}){const{t:i}=$();return s.jsxs(s.Fragment,{children:[s.jsxs(Ue,{children:[s.jsx(ae,{children:s.jsx("b",{children:i("Slot 7")})}),s.jsxs(ae,{children:[s.jsx(Ie,{toast:n,item:"Ogdin's Eye Coordination Enhancer"})," ",i("+6% Tracking (Often Cheaper!)")]}),s.jsxs(ae,{children:[s.jsx(Ie,{toast:n,item:"MR-705"})," ",i("+5% Tracking"),s.jsx("br",{}),s.jsx("b",{children:i("Logi:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"RA-705"})," ",i("-5% Cap use for remote reps")]})]}),s.jsxs(Ue,{children:[s.jsx(ae,{children:s.jsx("b",{children:i("Slot 8")})}),s.jsxs(ae,{children:[s.jsx(Ie,{toast:n,item:"EM-805"})," ",i("+5% Capacitor")]}),s.jsxs(ae,{children:[s.jsx(Ie,{toast:n,item:"Zor's Custom Navigation Hyper-Link"})," ",i("+5% MWD/AB Speed"),s.jsx("br",{}),s.jsx("b",{children:i("Vindicator:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"MR-805"})," ",i("+5% Web range")]})]}),s.jsxs(Ue,{children:[s.jsx(ae,{children:s.jsx("b",{children:i("Slot 9")})}),s.jsxs(ae,{children:[s.jsx(Ie,{toast:n,item:"RF-905"})," ",i("+5% rate of fire for all turrets")]}),s.jsxs(ae,{children:[s.jsx(Ie,{toast:n,item:"SS-905"})," ",i("+5% damage for all turrets"),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"Pashan's Turret Customization Mindlink"})," ",i("+7% rate of fire for all turrets")]})]}),s.jsxs(Ue,{children:[s.jsx(ae,{children:s.jsx("b",{children:i("Slot 10")})}),s.jsxs(ae,{children:[s.jsx("b",{children:i("Kronos/Vindicator:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"LH-1005"})," ",i("+5% Hybrid weapon damage"),s.jsx("br",{}),s.jsx("b",{children:i("Paladin:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"LE-1005"})," ",i("+5% Energy weapon damage"),s.jsx("br",{}),s.jsx("b",{children:i("Vargur:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"LP-1005"})," ",i("+5% Projectile weapon damage")]}),s.jsxs(ae,{children:[s.jsx("b",{children:i("Paladin:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"Pashan's Turret Handling Mindlink"})," ",i("+7% energy weapon damage"),s.jsx("br",{}),s.jsx("b",{children:i("Logi:")}),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"HG-1005"})," ",i("+5% Armor hitpoints"),s.jsx("br",{}),s.jsx(Ie,{toast:n,item:"HG-1008"})," ",i("+8% Armor hitpoints"),s.jsx("br",{})]})]})]})}const hs=A.div`
  border: solid 2px ${n=>n.theme.colors.accent2};
  background-color: ${n=>n.theme.colors.background};
  border-radius: 5px;
  font-size: 0.9em;
  filter: drop-shadow(0px 3px 4px ${n=>n.theme.colors.shadow});
  width: 380px;
  &:hover:not(:disabled):not(.static) {
    border-color: ${n=>n.theme.colors.accent3};
    cursor: pointer;
  }
  @media (max-width: 480px) {
    width: 100%;
  }
`;hs.Content=A.div`
  display: flex;
  align-items: center;
  color: ${n=>n.theme.colors.text};
  p {
    @media (max-width: 480px) {
      font-size: 3.1vw;
    }
  }
  img {
    border-radius: 3px 0px 0px 3px;
    margin-right: 0.5em;
    align-self: flex-start;
  }
`;hs.Content.Badges=A.div`
  margin-left: auto;
  display: flex;
  align-items: center;
  > *:last-child {
    margin-right: 0.5em;
  }
  img {
    height: 1.3em;
  }
  @media (max-width: 480px) {
    font-size: 1em;
    > *:last-child {
      margin-right: 0.4em;
    }
  }
`;const ms=A.div`
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  @media (max-width: 480px) {
    justify-content: center;
  }
`;function ac({data:n,tier:i}){const{t:r}=$();var c=[],u=[],f=[],h={},m,x;return i==="Antigank"?x=n.fittingdata:x=ye.sortBy(n.fittingdata,function(g){return g.name.indexOf("HYBRID")}),ye.forEach(n.logi_rules,g=>{f.push(g)}),ye.forEach(n.notes,g=>{h[g.name]=g.description??""}),x.forEach(g=>{if(g.dna&&g.name&&g.tier===i&&!(i!=="Antigank"&&g.name.toLowerCase().indexOf("antigank")!==-1)){const v=g.dna.split(":",1)[0];g.name in h?m=h[g.name]:m=null,f.includes(parseInt(v))?u.push(s.jsx(Fg,{fit:g,id:v,note:m},g.name)):c.push(s.jsx(Fg,{fit:g,id:v,note:m},g.name))}}),i==="Other"?s.jsx(s.Fragment,{children:s.jsxs("div",{children:[s.jsx("div",{style:{padding:"1em 0 0.4em"},children:s.jsx("p",{children:r("These ships are never used as main characters in fleet.")})}),s.jsx(Ge,{children:r("Secondary Support Ships")}),s.jsx(ms,{children:c})]})}):s.jsx(s.Fragment,{children:s.jsxs("div",{children:[s.jsx("div",{style:{padding:"1em 0 0.4em"},children:i in h?s.jsx(Cs,{children:h[i]}):s.jsx("br",{})}),c.length!==0&&s.jsxs(s.Fragment,{children:[s.jsx(Ge,{children:r("DPS")}),s.jsx(ms,{children:c})]}),s.jsx("br",{}),u.length!==0&&s.jsxs(s.Fragment,{children:[s.jsx(Ge,{children:r("LOGISTICS")}),s.jsx(ms,{children:u})]})]})})}function Fg({fit:n,id:i,note:r}){const[c,u]=J.useState(!1),{t:f}=$();return s.jsxs(s.Fragment,{children:[c?s.jsx(Xe,{open:!0,setOpen:u,children:s.jsxs(De,{style:{maxWidth:"500px"},children:[s.jsx("div",{style:{display:"flex"},children:s.jsx("div",{style:{margin:"0 0.5em"},children:s.jsx(Qd,{dna:n.dna,name:n.name})})}),r?s.jsx(rc,{$variant:"secondary",children:s.jsx(Cs,{children:r})}):null,n.implant_set==="Amulet"?s.jsx(rc,{$variant:"danger",children:s.jsx("p",{children:f("HYBRID FIT! This fit requires at least Amulet 1 - 5. See implants above")})}):n.implant_set==="Ascendancy "?s.jsx(rc,{$variant:"danger",children:s.jsx("p",{children:f("ASCENDANCY FIT! This fit requires at least Ascendancy 1 - 5 & WS-618. See implants above")})}):null]})}):null,s.jsx(De,{mpadding:"0.2em",style:{margin:"0.5em 0"},children:s.jsx(hs,{$variant:"input",children:s.jsx("a",{onClick:()=>u(!0),children:s.jsxs(hs.Content,{children:[s.jsx("img",{style:{height:"64px"},src:`https://images.evetech.net/types/${i}/icon`,alt:n.name}),s.jsx("p",{children:n.name}),s.jsxs(hs.Content.Badges,{children:[r?s.jsx(fe,{icon:ix}):null,n.implant_set==="Amulet"?s.jsx(bd,{color:"red",letter:"A",title:f("Amulet Implants")}):n.implant_set==="Ascendancy "?s.jsx(bd,{color:"red",letter:"W",title:f("Ascendancy Implants")}):null]})]})})})})]})}function Iw(){return s.jsxs(s.Fragment,{children:[s.jsx(ms,{style:{justifyContent:"initial"},children:s.jsx(Jg,{name:"Amulet",img:Kg})}),s.jsx(ms,{style:{justifyContent:"initial"},children:s.jsx(Jg,{name:"Ascendancy",img:Kg})})]})}function Jg({name:n,img:i}){const[r,c]=J.useState(!1),{t:u}=$();return s.jsxs(s.Fragment,{children:[r?s.jsx(Xe,{open:!0,setOpen:c,children:s.jsxs(De,{style:{width:"100%"},children:[s.jsx(Ts,{style:{width:"100%"},children:s.jsxs(Ts.Title,{children:[s.jsx("div",{children:s.jsx("img",{src:i,alt:n,style:{width:"1.8em",marginRight:"0.5em"}})}),s.jsxs(Ge,{children:[u(n),"  "]})]})}),s.jsx("br",{}),s.jsx("br",{}),s.jsx(Jw,{type:n})]})}):null,s.jsx(Oa,{children:s.jsx("a",{onClick:()=>c(!0),children:s.jsxs(Oa.Content,{children:[s.jsx(Oa.Icon,{children:s.jsx("img",{src:i,alt:n,style:{width:"1.5em"}})}),u(n)]})})})]})}function e_(){const n=new URLSearchParams(An().search),i=yc(),r=n.get("Tier")||"Armor",c=u=>{n.set("Tier",u),i({search:`?${n.toString()}`})};return s.jsx(t_,{tier:r,setTier:c})}function t_({tier:n,setTier:i=null}){const{t:r}=$();Qe(r(`${n} Fits`));const[c]=Dt("/incursions/api/fittings");return c===null?s.jsx("em",{children:r("Loading fits...")}):s.jsxs(s.Fragment,{children:[s.jsx(Da,{children:r("FITS")}),i!=null&&s.jsx(Gt,{style:{marginBottom:"0.5em"},children:s.jsxs(ze,{children:[s.jsx(K,{$active:n==="Basic",onClick:()=>i("Basic"),children:r("Basic")}),s.jsx(K,{$active:n==="Mainline",onClick:()=>i("Mainline"),children:r("Mainline")}),s.jsx(K,{$active:n==="Alt",onClick:()=>i("Alt"),children:r("Alt")}),s.jsx(K,{$active:n==="Other",onClick:()=>i("Other"),children:r("Other")})]})}),s.jsx(Iw,{}),n==="Basic"?s.jsx(ac,{data:c,tier:"Basic"}):n==="Mainline"?s.jsx(ac,{data:c,tier:"Mainline"}):n==="Alt"?s.jsx(ac,{data:c,tier:"Alt"}):n==="Other"?s.jsx(ac,{data:c,tier:"Other"}):null]})}const Wg=A.div`
  display: flex;
  flex-wrap: wrap;
  margin-top: 1em;
`,n_={};function Zi({name:n,icon:i,children:r}){const[c,u]=J.useState(!1);return s.jsxs(s.Fragment,{children:[c?s.jsx(Xe,{open:!0,setOpen:u,children:s.jsx(De,{children:s.jsxs(Ts,{children:[s.jsxs(Ts.Title,{children:[s.jsx("div",{style:{display:"flex",alignItems:"center"},children:s.jsx(wn,{type:i,height:"40px"})}),s.jsxs(Ge,{children:[n,"  "]})]}),r]})})}):null,s.jsx(Oa,{children:s.jsx("a",{onClick:()=>u(!0),children:s.jsxs(Oa.Content,{children:[s.jsx(Oa.Icon,{children:s.jsx(wn,{type:i,height:"50px"})}),n]})})})]})}function a_(){Qe("Badges");const[n,i]=J.useState(!1);return s.jsxs(s.Fragment,{children:[n?s.jsx(Xe,{open:!0,setOpen:i,children:s.jsx(De,{style:{width:"100%"},children:s.jsx("img",{src:n_["./examplediscord.png"],alt:"examplediscord",style:{width:"100%"}})})}):null,s.jsxs(ot,{style:{marginBottom:"2em"},children:[s.jsx("h1",{children:"Badges"}),s.jsxs("p",{children:["To get the T, A, or ! badge, use the",s.jsx("a",{href:"https://discord.com/channels/930000021083005028/930014112635826196/1287232984495423570",target:"_blank",rel:"noopener noreferrer",style:{marginLeft:"0.5em"},children:"ticket"})," ","system on Discord. Make sure your screenshot is saved on an image hosting website & shows the highlighted areas as per the",s.jsx(xx,{onClick:()=>i(!0),style:{marginLeft:"0.5em"},children:"example"})]}),s.jsx(Ge,{children:"Pilot Badge"}),s.jsxs(Wg,{children:[s.jsx(Zi,{name:"DPS",icon:"DPS",children:"The DPS Badge is given to a pilot that has met the main DPS Values on the fitting page. You must have implant slots 9 & 10 to get this badge."}),s.jsx(Zi,{name:"Logi",icon:"LOGI",children:"The Logi Badge is given out by an FC that has vouched for your logi performance. It is not required to fly Logi."}),s.jsxs(Zi,{name:"Alt Approved",icon:"ALT",children:["The Alt Approved Badge is given to a pilot that has met the DPS Values for alts on the fitting page. Your main or T badge must have a ",s.jsx("b",{children:"full"})," implant set before you can apply for this badge and recieve your guaranteed alt spot."]}),s.jsx(Zi,{name:"VINDICATION!",icon:"VINDI",children:"The VINDICATION badge is given to a pilot that has met the DPS and Web values on the fitting page."})]}),s.jsx(Ge,{children:"Commander Badges"}),s.jsxs(Wg,{children:[s.jsx(Zi,{name:"Training FC",icon:"TRAINEE",children:"Trainee isk bringers"}),s.jsx(Zi,{name:"Fleet Commander",icon:"HQ-FC",children:"Isk bringers"})]})]})]})}const ss={},i_=A(ot)`
  max-width: 800px;
`,l_=A.div`
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 150px;
  background-color: ${n=>n.theme.colors.accent1};
  border-radius: 5px;
  cursor: pointer;
  &:hover {
    border: solid 1px ${n=>n.theme.colors.accent2};
  }
  @media (max-width: 600px) {
    width: 100%;
  }
  box-shadow: 3px 3px 1px ${n=>n.theme.colors.shadow};
`,s_=A.img`
  height: 40px;
  margin-bottom: 5px;
`,r_=A.span`
  font-size: 20px;
`,c_=A.span`
  font-size: 14px;
  color: gray;
`,o_=A.div`
  display: flex;
  align-items: stretch;
  flex-wrap: wrap;
  border-top: 2px solid;
  padding-top: 5em;
  border-color: ${n=>n.theme.colors.accent2};
`,cd=({imageSrc:n,slug:i,title:r,subtitle:c,children:u})=>s.jsx(Fd,{children:s.jsx(Ot,{style:{textDecoration:"inherit",color:"inherit"},to:`${i}`,children:s.jsxs(l_,{children:[s.jsxs("div",{style:{display:"flex",height:"40px"},children:[u,n&&s.jsx(s_,{src:n})]}),s.jsx(r_,{children:r}),s.jsx(c_,{children:c})]})})});function u_(){const n=J.useContext(pe),{guideName:i}=a1(),[r,c]=J.useState(null),u=`./${i}`,f=`${u}/guide.md`;J.useEffect(()=>{if(c(null),!(f in ss))return;let m=document.title;return me(n,fetch(ss[f]).then(x=>x.text()).then(x=>{c(x),Vd(r0(x))})),()=>document.title=m},[n,f]);const h=m=>{const x=`${u}/${m}`;return x in ss?ss[x]:m};return ss[f]?r?s.jsx(i_,{style:{maxWidth:"800px"},children:s.jsx(Cs,{transformImageUri:h,transformLinkUri:null,children:r})}):s.jsx(s.Fragment,{children:s.jsx("em",{children:"Loading..."})}):s.jsxs(s.Fragment,{children:[s.jsx("strong",{children:"Not found!"})," The guide could not be loaded."]})}function d_(){return Qe("Guides"),s.jsxs(s.Fragment,{children:[s.jsx(Da,{style:{marginLeft:"40%",marginBottom:"1em"},children:"Guides"}),s.jsxs(o_,{style:{justifyContent:"space-around"},children:[s.jsx(cd,{imageSrc:"https://images.evetech.net/types/14268/icon",title:"DDD Guide",subtitle:"get GUD & Read",slug:"guide/ddd"}),s.jsxs(cd,{title:"Badges",subtitle:"Showing off u GUD",slug:"badges",children:[s.jsx(wn,{type:"DPS",height:"30px"}),s.jsx(wn,{type:"LOGI",height:"30px"}),s.jsx(wn,{type:"ALT",height:"30px"})]}),s.jsx(cd,{imageSrc:"https://images.evetech.net/types/33400/icon",title:"Marauder Guide",subtitle:"Count to 2 and you gucci",slug:"guide/marauder"})]})]})}function f_(){return s.jsx(a_,{})}const h_=()=>{const{t:n}=$();return s.jsxs(s.Fragment,{children:[s.jsx(ze,{style:{marginTop:"5em"},children:s.jsx(Sn,{to:"/legal",children:n("nav.legal","Legal")})}),s.jsx(ot,{children:s.jsxs(bn,{children:[s.jsx(bn.Head,{style:{marginBottom:"1em"},children:n("home.welcomeMessage","Welcome to a fork of TLA Waitlist, embedded into Alliance Auth. This App is still a work in progress and not every API call is implemented yet.")}),s.jsx(bn.Paragraph,{})]})})]})};function T0(n){const{i18n:i}=$();return r=>r==null?null:r.toLocaleString(i.language,{maximumFractionDigits:2,...n})}const m_=A(Ue)`
  ${n=>n.$clamped&&`
    background-color: ${n.theme.colors.errorBackground||"rgba(255, 0, 0, 0.08)"} !important;
    color: ${n.theme.colors.error||"red"} !important;
    font-weight: 600;
  `}
`;function p_(n){const i=[];for(const c of n)od.encode(Math.round(c),i,i.length);let r=85;for(const c of i)r^=c;return i.push(r),nx.Buffer.from(i).toString("base64").replaceAll("+","-").replaceAll("/","_").replaceAll("=","")}function g_(n){const i=nx.Buffer.from(n,"base64");let r=0,c=0;for(const f of i)c^=f;if(c!==85)throw new Error("Checksum mismatch!");const u=[];for(;r<i.byteLength-1;)u.push(od.decode(i,r)),r+=od.decode.bytes;return u}function x_(n){return"1"+p_([n.isk,n.lp,n.sites,n.startTime,n.endTime-n.startTime,n.minTime,n.maxTime,n.chars,n.firstSitePayout,n.clampedTime])}function y_(n){if(n[0]==="1"){const i=g_(n.slice(1));return{isk:i[0],lp:i[1],sites:i[2],startTime:i[3],endTime:i[3]+i[4],minTime:i[5],maxTime:i[6],chars:i[7],firstSitePayout:i[8]||315e5,clampedTime:i[9]||0,raw:[]}}throw new Error("Cannot decode input")}function v_(){const n={};for(const[i,r,c,u]of[["Mothership (HS)",63e6,14e3,80],["Mothership (LS/NS)",9e7,2e4,120],["HQ (HS)",315e5,7e3,40],["HQ (LS/NS)",45e6,1e4,60],["AS (HS)",182e5,3500,20],["AS (LS/NS)",26e6,5e3,30],["VG (HS)",10395e3,1400,10],["VG (LS/NS)",15e6,2e3,15],["Scout",35e5,400,5]])for(let f=0;f<11;f++){const h=1-.0725*f-.0025*f**2,m=Math.round(r*h);if(n[m])throw new Error("Two sites give the same payout?!");n[m]={siteType:i,payout:m,lp:Math.round(c*h),normalPayout:r,normalLp:c,onGrid:f?u+f:null}}return n}const b_=v_();function j_(n,i=1200){var x;let r=[];for(const g of n.split(`
`)){const[v,w,j,,E]=g.split(/\t|\s{2,}/);if(!w||!E||!j||!j.match(/ISK/)||!(w.match(/reward payout/i)&&E.match(/concord/i)))continue;let R=j.replace(/[.,]\d{2} /," ").replace(/\D/g,"");const B=Math.round(parseFloat(R)),[z,H]=v.split(/ /),q=`${z.replaceAll(".","-")}T${H}Z`,V=new Date(q);r.push({time:V,value:B})}r=ye.sortBy(r,["time","value"]);const c={};let u=null;const f=[];let h=0;const m={isk:0,lp:0,sites:0,chars:1,raw:[],minTime:0,maxTime:0,startTime:0,endTime:0,firstSitePayout:0};for(const g of r){const v=b_[g.value],w=g.time.getTime()/1e3;if(c[w]=(c[w]||0)+1,m.isk+=g.value,v&&(m.lp+=v.lp),!u||g.time.getTime()!==u.getTime()){if(u){const j=(g.time.getTime()-u.getTime())/1e3,E=i?Math.min(j,i):j,R=i?j>i:!1;f.push(E),h+=E,m.sites+=1,m.raw.push({time:w,isk:g.value,lp:v?v.lp:null,onGrid:v?v.onGrid:null,siteType:(v==null?void 0:v.siteType)??null,clamped:R})}else m.sites+=1,m.raw.push({time:w,isk:g.value,lp:v?v.lp:null,onGrid:v?v.onGrid:null,siteType:(v==null?void 0:v.siteType)??null,clamped:!1});u=g.time}else m.raw.push({time:w,isk:g.value,lp:v?v.lp:null,onGrid:v?v.onGrid:null,siteType:(v==null?void 0:v.siteType)??null,clamped:!1}),m.chars+=1}return m.chars=Math.max(...Object.values(c)),f.length<1?null:(m.minTime=Math.min(...f),m.maxTime=Math.max(...f),m.startTime=Math.min(...m.raw.map(g=>g.time)),m.endTime=Math.max(...m.raw.map(g=>g.time)),m.firstSitePayout=((x=m.raw.find(g=>g.time===m.startTime))==null?void 0:x.isk)??0,m.clampedTime=h,m)}const S_=A.div`
  ${n=>`
    max-width: 500px;
    border-radius: 10px;
    text-align: center;
    border: solid 1px ${n.theme.colors.accent4};
    > h1 {
      margin-top: 0.5em;
      font-size: 2em;
      font-weight: 600;
      filter: drop-shadow(0px 1px 1px ${n.theme.colors.shadow});
    }
    > h2 {
      font-size: 1.5em;
      font-weight: 600;
    }
    > * {
      padding-left: 1em;
      padding-right: 1em;
    }
    hr {
      border: 0;
      margin-top: 0.75em;
    }
    p:last-child {
      border-top: solid 1px ${n.theme.colors.accent3};
      font-size: 0.8em;
      margin-top: 1em;
      margin-bottom: 0.3em;
      padding-top: 0.3em;
      &:hover:not(:disabled):not(.static) {
        color: ${n.theme.colors.accent4};
        cursor: pointer;
      }
    }
    a {
      color: ${n.theme.colors.text};
      text-decoration: none;
    }
  `}
`;function A0({dataStr:n,clampMinutes:i}){const r=J.useContext(pe),{t:c}=$(),u=T0();if(!n)return null;let f;try{f=y_(n)}catch{return s.jsx("em",{children:c("Failed to load results")})}const h=f.endTime-f.startTime,m=f.sites>1?f.clampedTime/(f.sites-1):0,x=h>0?Math.round((f.isk-f.firstSitePayout)/(h/3600)):0,g=f.clampedTime>0?Math.round((f.isk-f.firstSitePayout)/(f.clampedTime/3600)):0,v=`${window.location.origin}/incursions/waitlist/isk-h?d=${encodeURIComponent(n)}`;return s.jsxs(S_,{children:[i&&i>0?s.jsxs(s.Fragment,{children:[s.jsxs("h1",{children:[u(g)," ",c("ISK/h")]}),s.jsxs("h2",{style:{fontSize:"1.2em",fontWeight:400,marginBottom:"0.5em"},children:[u(x)," ",c("ISK/h")," ",s.jsxs("small",{style:{fontSize:"0.6em"},children:["(",c("unadjusted"),")"]})]})]}):s.jsxs("h1",{children:[u(x)," ",c("ISK/h")]}),s.jsxs("h2",{children:[u(f.isk)," ISK + ",u(f.lp)," LP"]}),s.jsx("hr",{}),s.jsxs("p",{children:[u(f.sites)," ",c("sites completed")]}),f.chars>1&&s.jsxs("p",{children:[u(f.chars)," ",c("characters included in payout calculation")]}),s.jsx("hr",{}),f.sites>1&&s.jsxs("p",{children:[Ta(f.minTime)," ~ ",Ta(f.maxTime)," (",c("average")," ",m>0?Ta(Math.round(m)):"-",")"]}),s.jsxs("p",{children:[Ii(new Date(f.startTime*1e3))," ++ ",Ta(h)]}),s.jsx("p",{onClick:()=>_0(r,v),children:v})]})}function w_(){const[n,i]=J.useState(""),[r,c]=J.useState(20),u=j_(n,r>0?r*60:null),f=u?x_(u):null,{t:h}=$(),m=T0();return Qe(h("ISK/h")),s.jsxs(s.Fragment,{children:[s.jsx(Da,{children:h("ISK/h calculator")}),s.jsxs("div",{style:{display:"flex"},children:[s.jsxs("div",{style:{flex:1,padding:"0.5em"},children:[s.jsx("em",{children:h("Go to your in-game wallet, select all incursion payouts, and hit Ctrl-C. Then, paste them here. Note: this calculator currently only works for English EVE clients.")}),s.jsx(on,{value:n,onChange:x=>i(x.target.value),rows:10,style:{width:"100%"}}),s.jsx("div",{style:{marginTop:"1em"},children:s.jsxs("label",{children:["Clamp site durations (minutes):"," ",s.jsx("input",{type:"number",value:r,min:0,max:120,step:1,onChange:x=>c(parseInt(x.target.value||"0")),style:{width:"4em",marginLeft:"0.5em"}}),s.jsx("small",{style:{fontSize:"0.8em",display:"block",marginTop:"0.3em"},children:"Set to 0 to disable clamping."})]})}),s.jsx("div",{style:{padding:"1em"},children:s.jsx(A0,{dataStr:f,clampMinutes:r})})]}),u&&s.jsx("div",{style:{flex:2,padding:"0.5em"},children:s.jsxs(Fn,{fullWidth:!0,children:[s.jsx(ai,{children:s.jsxs(Ue,{children:[s.jsx(Fe,{children:h("Time")}),s.jsx(Fe,{children:h("ISK")}),s.jsx(Fe,{children:h("LP")}),s.jsx(Fe,{children:h("On grid")}),s.jsx(Fe,{children:h("Site type")})]})}),s.jsx(Jn,{children:u.raw.map((x,g)=>s.jsxs(m_,{$clamped:x.clamped,children:[s.jsxs(ae,{children:[Ii(new Date(x.time*1e3))," ",x.clamped&&" ⚠ >20m"]}),s.jsx(ae,{children:m(x.isk)}),s.jsx(ae,{children:m(x.lp)}),s.jsx(ae,{children:m(x.onGrid)}),s.jsx(ae,{children:x.siteType??"-"})]},g))})]})})]})]})}function __(){const i=new URLSearchParams(An().search).get("d")||"",{t:r}=$();return s.jsxs(s.Fragment,{children:[s.jsx("div",{children:s.jsx(Sn,{exact:!0,to:"/isk-h/calc",children:r("Calculator")})}),s.jsx("div",{style:{display:"flex",justifyContent:"center"},children:s.jsx(A0,{dataStr:i,clampMinutes})})]})}const T_=()=>{const{t:n}=$();return Qe(n("legal.title","Legal Notice")),s.jsxs(ot,{children:[s.jsx("h2",{children:n("legal.ccpTitle","CCP Copyright Notice")}),s.jsx("p",{children:n("legal.ccpText","EVE Online and the EVE logo are the registered trademarks of CCP hf. All rights are reserved worldwide. All other trademarks are the property of their respective owners. EVE Online, the EVE logo, EVE and all associated logos and designs are the intellectual property of CCP hf. All artwork, screenshots, characters, vehicles, storylines, world facts or other recognizable features of the intellectual property relating to these trademarks are likewise the intellectual property of CCP hf. CCP hf. has granted permission to the Alliance Auth team to use EVE Online and all associated logos and designs for promotional and information purposes on its website but does not endorse, and is not in any way affiliated with, the Alliance Auth team. CCP is in no way responsible for the content on or functioning of this website, nor can it be liable for any damage arising from the use of this website.")}),s.jsxs("p",{children:[n("legal.aaNotice","The source code for AA Incursions and this Waitlist Module is available under the MIT license. The source code and full text for this license can be found "),s.jsx("a",{href:"https://gitlab.com/tactical-supremacy/aa-incursions",children:n("legal.aaLinkText","here")}),"."]}),s.jsxs("p",{children:[n("legal.tlaNotice","This Waitlist Module is a fork of TLA Waitlist, which is also available under the MIT license. The source code and full text for this license can be found "),s.jsx("a",{href:"https://github.com/luna-duclos/tla-waitlist",children:n("legal.tlaLinkText","here")}),"."]})]})},A_="/static/incursions/waitlist/media/dead.jpg",C_=A.div`
  margin: 0 0 0.5em;
  display: flex;
  background-color: ${n=>n.theme.colors.secondary.color};
  color: ${n=>n.theme.colors.secondary.text};
  width: 100%;
  filter: drop-shadow(0px 4px 5px ${n=>n.theme.colors.shadow});
  padding: 0.1em 0.5em 0.5em;
  align-items: center;
  word-break: break-word;

  svg {
    font-size: 32px;
    margin: 5px;
    flex-shrink: 1;
  }

  div {
    flex-grow: 3;

    h3 {
      font-size: 1.5em;
      font-weight: 600;
    }
  }

  a {
    color: white;
  }
`;A.div`
  svg:first-of-type {
    font-size: 50px;
    display: block;
    margin: 10vh auto 20px auto;
  }
  h1 {
    font-size: 1.6em;
    text-align: center;
    margin-bottom: 12px;
  }
  p {
    display: block;
    margin: 0 auto 15px auto;
    max-width: 500px;
    text-align: center;
  }
`;A.div`
  position: absolute;
  height: 100vh;
  width: 100vw;
  top: 0;
  left: 0;
  z-index: 10;
  background: url(${A_}) no-repeat;
  background-size: cover;
  color: #d5d5d5;

  h1 {
    text-align: center;
    margin-top: 30vh;
    font-size: revert;
    font-weight: bolder;
  }

  p {
    text-align: center;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
  }
`;const E_=({bans:n})=>{var f,h,m,x;const{t:i}=$(),r=S.useContext(He),c=n==null?void 0:n.find(g=>!g.revoked_at||new Date(g.revoked_at)>new Date);return!(((f=r==null?void 0:r.access)==null?void 0:f["incursions.waitlist_bans_view"])||((h=r==null?void 0:r.access)==null?void 0:h["incursions.waitlist_bans_manage"]))||!c?null:s.jsxs(C_,{children:[s.jsx(fe,{fixedWidth:!0,icon:vc}),s.jsxs("div",{children:[s.jsx("h3",{children:i("{{category}} Suspended",{category:(m=c.entity)==null?void 0:m.category})}),s.jsx("p",{children:i("Issued on: {{date}} by {{issuer}}.",{date:ps(new Date(c.issued_at)),issuer:((x=c.issued_by)==null?void 0:x.name)??""})}),c.revoked_at&&s.jsx("p",{children:i("Expires in {{time}}.",{time:bc(new Date(c.revoked_at))})}),s.jsx("p",{children:c.reason})]})]})};function O_({summary:n}){const{t:i}=$();if(!n)return null;if(!n.length)return s.jsx("em",{children:i("Never seen before")});const r=ye.sum(n.map(({time_in_fleet:c})=>c));return s.jsx(Fn,{fullWidth:!0,edgeLine:!0,style:{marginBottom:"2em"},children:s.jsxs(Jn,{children:[s.jsxs(Ue,{children:[s.jsx(Fe,{children:i("Total")}),s.jsx(Fe,{children:Ta(r)})]}),n.map(({ship:c,time_in_fleet:u})=>s.jsxs(Ue,{children:[s.jsx(ae,{children:i(c.name)}),s.jsx(ae,{children:Ta(u)})]},c.id))]})})}const D_=A.div`
  span {
    display: none;
  }

  div {
    display: inline-block;
    height: 2rem;
    width: 2rem !important;
    vertical-align: text-bottom;
    margin: 15px auto;

    background-color: ${({theme:n})=>n.colors.accent3};
    border-radius: 50%;
    opacity: 0;
    animation: spinner-grow 0.75s linear infinite;
    -webkit-animation: spinner-grow 0.75s linear infinite;
  }

  @keyframes spinner-grow {
    0% {
      transform: scale(0);
    }
    50% {
      opacity: 1;
      transform: none;
    }
  }
`,M_=()=>{const{t:n}=$();return s.jsxs(D_,{children:[s.jsx("div",{}),s.jsx("span",{children:n("Loading...")})]})},Pg=A.div`
  margin-bottom: 25px;

  div {
    padding: 5px;
    width: 100%;
  }

  button {
    padding: 5px;
    font-size: 10px;
    margin-left: 5px;
  }
`;async function z_(n,i){return await ct("/incursions/api/open_window",{json:{target_id:n,character_id:i}})}const R_=n=>{const i=S.useContext(He);return i!=null&&i.access["incursions.waitlist_alts_view"]?s.jsx(k_,{characterId:n.character}):null},k_=({characterId:n=0})=>{const i=S.useContext(He),{t:r}=$(),c=n!==0?`/incursions/api/pilot/alts?character_id=${n}`:null,[u]=Dt(c);return n===0?s.jsxs(Pg,{children:[s.jsx(Ge,{children:r("Known Alt Characters")}),s.jsx("em",{style:{fontSize:"smaller"},children:r("No character selected.")})]}):s.jsxs(Pg,{children:[s.jsxs(Ge,{children:[r("Known Alt Characters"),s.jsx(fe,{fixedWidth:!0,icon:V1,style:{marginLeft:"5px"},title:r("Only characters that the pilot has linked are shown below. Characters are unlinked when the user clicks logout.")})]}),u?u.length>0?u.map((f,h)=>s.jsxs("div",{children:[s.jsx(yt,{...f}),s.jsx(K,{title:r("Open Show Info Window"),onClick:()=>me(pe,z_(f.character_id,i.current.character_id)),children:s.jsx(fe,{fixedWidth:!0,icon:As})})]},h)):s.jsx("em",{style:{fontSize:"smaller"},children:r("Pilot has no known alts.")}):s.jsx(M_,{})]})},B_=A.a`
  cursor: pointer;
  text-decoration: underline;
`,Ia=A.div`
  display: flex;

  border-bottom: solid 1px ${n=>n.theme.colors.accent2};
  &:first-child {
    border-top: solid 1px ${n=>n.theme.colors.accent2};
  }
  &:nth-child(odd) {
    background-color: ${n=>n.theme.colors.accent1};
  }
`;Ia.Time=A.div`
  flex: 0 0 200px;
  padding: 0.5em;
  @media (max-width: 480px) {
    width: 40%;
    flex: unset;
  }
`;Ia.Icon=A.div`
  flex: 0 0 auto;
  padding: 0.5em;
`;Ia.Content=A.div`
  flex: 1;
  padding: 0.5em;
`;function zc({time:n,icon:i,children:r}){return s.jsxs(Ia,{children:[s.jsx(Ia.Icon,{children:i&&s.jsx(fe,{fixedWidth:!0,icon:i})}),s.jsx(Ia.Time,{children:Ii(new Date(n*1e3))}),s.jsx(Ia.Content,{children:r})]})}function N_({issued_at:n,issued_by:i,reason:r,public_reason:c,revoked_at:u,revoked_by:f}){const{t:h}=$(),m=!u;return s.jsx(zc,{time:n,icon:vc,children:s.jsxs(ot,{children:[s.jsxs("p",{children:[h(m?"Permanent":"Temporary")," ",h("ban"),", ",h("issued by"),":"," ",s.jsx(yt,{...i,avatar:!1}),"."]}),!m&&!f&&s.jsxs("p",{children:[h("Expires"),": ",bc(new Date(u*1e3)),"."]}),!m&&f&&s.jsxs("p",{children:[h("Revoked by"),": ",s.jsx(yt,{...f,avatar:!1})," ",h("on the")," ",ps(new Date(u*1e3)),"."]}),s.jsxs("p",{style:{marginBottom:"2px",fontWeight:"600"},children:[h("Reason"),":"]}),s.jsx("p",{children:r}),c&&s.jsxs(s.Fragment,{children:[s.jsx("p",{style:{marginBottom:"2px",fontWeight:"600"},children:h("Public Reason")}),s.jsx("p",{children:c})]})]})})}function U_({logged_at:n,ship:i,dna:r,implants:c}){const[u,f]=J.useState(!1);return s.jsxs(zc,{time:n,icon:cx,children:[u&&s.jsx(Xe,{open:!0,setOpen:f,children:s.jsx(De,{style:{display:"flex"},children:s.jsx(Zd,{fit:{dna:r,implants:c,fit_analysis:{name:i.name}}})})}),s.jsx(B_,{onClick:()=>f(!0),children:i.name})]})}function L_({logged_at:n,ship:i,time_in_fleet:r}){return s.jsxs(zc,{time:n,icon:ox,children:[s.jsx("span",{style:{display:"inline-block",minWidth:"40%",marginRight:"0.5em"},children:i.name}),s.jsx("span",{children:Ta(r)})]})}function H_({logged_at:n,author:i,note:r}){const{t:c}=$();return s.jsx(zc,{time:n,icon:ux,children:s.jsxs(ot,{children:[s.jsxs("p",{children:[c("Note written by")," ",s.jsx("strong",{children:i.name})]}),s.jsx(Ig,{children:r})]})})}const q_=A.div`
  margin-bottom: 2em;
`;function $_({filter:n,banHistory:i,fleetHistory:r,xupHistory:c,notes:u}){const{t:f}=$();var h=[],m=0;for(const j of i||[])m++,h.push({key:`ban-${m}`,entry:j,time:j.issued_at,type:"ban"});m=0;for(const j of c||[])m++,h.push({time:j.logged_at,type:"fit",entry:j,key:`fit-${m}`});m=0;for(const j of r||[])m++,h.push({time:j.logged_at,endTime:j.logged_at+j.time_in_fleet,type:"fleet",entry:j,key:`fleet-${m}`});m=0;for(const j of u||[])m++,h.push({time:j.logged_at,type:"note",entry:j,key:`note-${m}`});n!==null&&(h=h.filter(j=>n(j.type))),h=ye.sortBy(h,["time"]);var x=[],g=null,v=null;for(const{time:j,entry:E,type:R,endTime:B,key:z}of h)(g===null||v<j)&&(g=[],x.push({key:j,group:g})),v=(B||j)+3*3600,R==="ban"?g.push(s.jsx(N_,{...E},z)):R==="fit"?g.push(s.jsx(U_,{...E},z)):R==="fleet"?g.push(s.jsx(L_,{...E},z)):R==="note"&&g.push(s.jsx(H_,{...E},z));var w=[];x.reverse();for(const{group:j,key:E}of x)j.reverse(),w.push(s.jsx(q_,{children:j},E));return w.length?s.jsx("div",{children:w}):s.jsx("div",{children:s.jsx("em",{children:f("No logged history")})})}function G_({filter:n,banHistory:i,fleetHistory:r,xupHistory:c,notes:u}){return s.jsx($_,{filter:n,banHistory:i,fleetHistory:r,xupHistory:c,notes:u})}const V_=A.span`
  font-size: 0.75em;
  margin-left: 2em;

  a {
    cursor: pointer;
    padding: 0 0.2em;
  }
`;async function Y_(n,i){return xe("/incursions/api/open_window","post",{body:{target_id:n,character_id:i}})}function X_(){const n=S.useContext(He),{t:i}=$();return n?s.jsx(Z_,{authContext:n}):s.jsxs(ot,{children:[s.jsx("b",{children:i("Login Required!")}),s.jsx("p",{children:i("This page will show you your own Fleet statistics like x-up's, fleet times and skill changes.")})]})}const Q_=A.div`
  display: flex;
  align-items: center;
  padding-bottom: 30px;

  @media (max-width: 400px) {
    flex-direction: column;
  }

  img {
    border-radius: 50%;
    height: 100px;
    width: 100px;
    margin-right: 10px;
    vertical-align: bottom;

    @media (max-width: 400px) {
      margin-right: 0px;
    }
  }

  div:first-of-type {
    display: flex;
    flex-direction: column;

    div:first-of-type {
      display: flex;
      flex-direction: row;

      @media (max-width: 400px) {
        flex-direction: column;
        padding-bottom: 15px;

        h1 {
          text-align: center;
        }
      }

      h1 {
        font-size: 1.9em;
        margin-right: 10px;
      }
    }
  }
`;function Z_({authContext:n}){const{t:i}=$(),r=An(),c=parseInt(new URLSearchParams(r.search).get("character_id")||`${n.current.character_id}`),[u,f]=S.useState(null),[h,m]=S.useState(null),[x,g]=S.useState(null),[v,w]=S.useState(null),[j,E]=S.useState(null),[R,B]=S.useState(null);return Qe(i("Pilot")),S.useEffect(()=>{xe("/incursions/api/pilot/info","get",{params:{character_id:c}}).then(m),xe("/incursions/api/history/fleet","get",{params:{character_id:c}}).then(g),xe("/incursions/api/history/xup","get",{params:{character_id:c}}).then(E),(n.access["incursions.waitlist_bans_view"]||n.access["incursions.waitlist_bans_manage"])&&xe("/incursions/api/bans/{character_id}","get",{params:{character_id:c}}).then(w),(n.access["incursions.waitlist_notes_view"]||n.access["incursions.waitlist_notes_manage"])&&xe("/incursions/api/notes","get",{params:{character_id:c}}).then(B)},[c,n.access]),h?s.jsxs(s.Fragment,{children:[(n.access["incursions.waitlist_bans_view"]||n.access["incursions.waitlist_bans_manage"])&&s.jsx(E_,{bans:v}),s.jsxs(Q_,{children:[(h==null?void 0:h.character.character_id)!==1&&s.jsx("img",{src:`https://images.evetech.net/characters/${h.character.character_id}/portrait?size=128`,alt:i("Character Portrait")}),s.jsxs("div",{children:[s.jsx("div",{children:s.jsx("h1",{children:h==null?void 0:h.character.character_name})}),s.jsx(d0,{badges:(h==null?void 0:h.badges)??[]})]})]}),n.main_character_id!==c&&s.jsxs(ze,{style:{marginBottom:"20px"},children:[n.access["incursions.waitlist_notes_manage"]&&s.jsx(Sn,{to:`/fc/notes/add?character_id=${c}`,children:i("Write note")}),n.access["incursions.waitlist_badges_manage"]&&s.jsx(S0,{character:h.character,refreshData:()=>xe("/incursions/api/pilot/info","get",{params:{character_id:c}}).then(m)}),n.access["incursions.waitlist_esi_show_info"]&&s.jsxs(K,{title:i("Open Show Info Window"),onClick:()=>me(pe,Y_((h==null?void 0:h.id)??c,n.current.character_id)),children:[i("Show Info")," ",s.jsx(fe,{fixedWidth:!0,icon:As})]})]}),s.jsxs(xc,{children:[s.jsxs(Pi,{xs:4,md:6,children:[s.jsxs(Ge,{children:[i("History"),s.jsxs(V_,{children:[s.jsx("a",{onClick:()=>f(null),style:{marginRight:"0.5em"},title:i("Clear Filters"),children:s.jsx(fe,{fixedWidth:!0,icon:_d})}),s.jsx("a",{onClick:()=>f("fit"),title:i("X-UP History"),children:s.jsx(fe,{fixedWidth:!0,icon:cx})}),s.jsx("a",{onClick:()=>f("fleet"),title:i("Fleet History"),children:s.jsx(fe,{fixedWidth:!0,icon:ox})}),(n.access["incursions.waitlist_notes_view"]||n.access["incursions.waitlist_notes_manage"])&&s.jsx("a",{onClick:()=>f("note"),title:i("Pilot Notes"),children:s.jsx(fe,{fixedWidth:!0,icon:ux})}),(n.access["incursions.waitlist_bans_view"]||n.access["incursions.waitlist_bans_manage"])&&s.jsx("a",{onClick:()=>f("ban"),title:i("Character Ban History"),children:s.jsx(fe,{fixedWidth:!0,icon:vc})})]})]}),s.jsx(G_,{filter:u?z=>z===u:null,banHistory:v,fleetHistory:x==null?void 0:x.activity,xupHistory:j==null?void 0:j.xups,notes:R==null?void 0:R.notes})]}),s.jsxs(Pi,{xs:4,md:2,children:[s.jsx(Ge,{children:i("Time in fleet")}),s.jsx(O_,{summary:x==null?void 0:x.summary}),s.jsx(R_,{character:h==null?void 0:h.character.character_id})]})]})]}):s.jsx(ot,{children:s.jsx("p",{children:i("Loading pilot info...")})})}const K_="/static/incursions/waitlist/media/skillqueue.png";function F_(){const n=J.useContext(He),{t:i}=$();return n?s.jsx(J_,{authContext:n}):s.jsxs(ot,{children:[s.jsx("b",{children:i("Login Required!")}),s.jsx("p",{children:i("This page will show copyable skill plan tables comparing to your current skills with checkmarks next to already completed skills.")})]})}function J_({authContext:n}){const[{plan:i}]=Jd(),[r]=Dt("/incursions/api/skills/plans"),[c]=Dt(`/incursions/api/skills/${n.current.character_id}`),{t:u}=$();if(!r||!c)return s.jsx("em",{children:u("Loading...")});if(i){const f=ye.find(r.plans,h=>h.source.name===i);return f?s.jsx(P_,{plan:f,mySkills:c}):s.jsx("em",{children:u("Plan not found")})}return s.jsx(e3,{plans:r.plans,mySkills:c})}function C0(n){if(n===1)return"I";if(n===2)return"II";if(n===3)return"III";if(n===4)return"IV";if(n===5)return"V";throw new Error("Unlikely skill numeral")}function W_(n,i){return n.map(([r,c])=>`${i[r]||"MISSING SKILL"} ${C0(c)}`).join(`
`)}function P_({plan:n,mySkills:i}){const r=J.useContext(pe),[c,u]=J.useState(!1),{t:f}=$();var h=[],m=ye.invert(i.ids);return ye.forEach(n.levels,([x,g])=>{const v=m[x],w=i.current[x];h.push(s.jsxs(Ue,{children:[s.jsxs(ae,{children:[v||f("MISSING SKILL")," ",C0(g)]}),s.jsx(ae,{children:w>=g?s.jsx(fe,{icon:sx}):null})]},`${x} ${g}`))}),Qe(a2(n.source.name)),s.jsxs(xc,{children:[s.jsxs(Pi,{xs:4,md:4,children:[s.jsx(Gt,{children:s.jsx(Ot,{exact:!0,to:"/skills/plans",style:{textDecoration:"inherit",color:"inherit"},children:s.jsx(K,{children:f("Back")})})}),s.jsxs(ot,{children:[s.jsx("h2",{children:n.source.name}),s.jsx("p",{children:n.source.description}),s.jsx("div",{style:{marginTop:"2em"},children:n.ships.map(x=>s.jsx("img",{src:`https://images.evetech.net/types/${x.id}/render?size=128`,style:{maxWidth:"128px",margin:"0.5em"},alt:x.name,title:x.name},x.id))})]})]}),s.jsxs(Pi,{xs:4,md:4,children:[s.jsxs("p",{style:{marginBottom:"1em"},children:[s.jsx(K,{onClick:()=>{ib(r,navigator.clipboard.writeText(W_(n.levels,m)).then(()=>f("Copied to clipboard")))},children:s.jsx(fe,{icon:lx})})," ",s.jsx("a",{style:{textDecoration:"underline",cursor:"pointer"},onClick:()=>u(!0),children:f("How do I use this?")})]}),s.jsxs(Fn,{children:[s.jsx(ai,{children:s.jsxs(Ue,{children:[s.jsx(Fe,{children:f("Skill")}),s.jsx(Fe,{})]})}),s.jsx(Jn,{children:h})]})]}),s.jsx(Xe,{open:c,setOpen:u,children:s.jsx("img",{alt:f("Explanation for using the skill queue"),src:K_})})]})}const I_=A.div`
  border: solid 2px ${n=>n.theme.colors.secondary.color};
  line-height: 0;
  padding: 0.1em;
  justify-content: center;
  border-radius: 5px;
  max-width: fit-content;
  img {
    margin: 1px;
    border-radius: 3px;
    max-width: 31px;
  }
`;function e3({plans:n,mySkills:i}){const{t:r}=$();return Qe(r("Skill Plans")),s.jsxs(s.Fragment,{children:[s.jsx(Da,{children:r("Skill plans")}),s.jsx(b0,{children:n.map(c=>s.jsx(Fd,{children:s.jsx(Ot,{exact:!0,to:`/skills/plans?plan=${c.source.name}`,style:{textDecoration:"inherit",color:"inherit"},children:s.jsxs(j0,{title:c.source.name,children:[s.jsx(I_,{children:c.ships.map(u=>s.jsx("img",{src:`https://images.evetech.net/types/${u.id}/icon?size=64`,alt:u.name,title:u.name},u.id))}),s.jsx("p",{children:c.source.description})]})})},c.source.name))})]})}function t3(){const{t:n}=$(),i=J.useContext(He);return i?s.jsx(n3,{authContext:i}):s.jsxs(ot,{children:[s.jsx("b",{children:n("Login Required!")}),s.jsx("p",{children:n("This page will show tables with TDF related skills comparing to your current skills with a color indicating the progres tier that skill is at.")})]})}function n3({authContext:n}){const{t:i}=$(),r=new URLSearchParams(An().search),c=yc();var u=r.get("character_id")||n.current.character_id,f=r.get("ship")||"Vindicator";const[h]=Dt(`/incursions/api/pilot/info?character_id=${u}`),m=x=>{r.set("ship",x),c({search:`?${r.toString()}`})};return Qe(i("{{ship}} Skills",{ship:f})),s.jsxs(s.Fragment,{children:[s.jsx(Da,{children:h?i("Skills for {{name}}",{name:h.character.character_name}):i("Skills")}),s.jsx(p0,{characterId:u,ship:f,setShip:m})]})}const a3="[Paladin, Paladin]...".trim(),i3="bringing 1 alt".trim(),l3=A.div`
  display: flex;
  @media (max-width: 1100px) {
    display: block;
  }
`,E0=({setXupOpen:n})=>{Qe("X-up");const{t:i}=$(),r=S.useContext(pe),c=S.useContext(He),f=new URLSearchParams(An().search).get("wl"),[h,m]=S.useState(""),[x,g]=S.useState(""),[v,w]=S.useState(!1),[j,E]=S.useState(!1),[R]=Td(`/incursions/api/implants?character_id=${c.current.character_id}`),B=!1,z=S.useMemo(()=>100-x.length,[x]),H=S.useCallback(async()=>{w(!0),me(r,r3({character:c.current.character_id,eft:h,toastContext:r,waitlistId:f,alt:B,messagexup:x}).then(()=>E(!0))).finally(()=>w(!1))},[h,x,c,r,f,B]);return f?j?s.jsx(s3,{waitlistId:f,setOpen:E,setXupOpen:n}):s.jsxs(l3,{children:[s.jsxs(ot,{style:{flex:1},children:[s.jsx("h2",{children:i("X-up with fit(s)")}),s.jsx(on,{placeholder:a3,rows:15,onChange:q=>m(q.target.value),value:h,style:{width:"100%",marginBottom:"1em"}}),s.jsxs("div",{style:{marginBottom:"1em"},children:[s.jsx("h2",{children:i("X-up message (optional)")}),s.jsx(on,{placeholder:i3,rows:1,onChange:q=>g(q.target.value),value:x,style:{width:"100%"}}),s.jsxs("div",{children:[i("Characters left"),": ",z>=0?z:i("Too long")]})]}),s.jsxs(ze,{children:[s.jsx(K,{static:!0,children:c.current.character_name}),s.jsx(K,{$variant:"success",onClick:H,disabled:h.trim().length<50||!h.startsWith("[")||v||x.length>100,children:i("X-up")})]})]}),s.jsx(De,{style:{flex:1,marginTop:"1em"},children:R&&s.jsx(h0,{implants:R.implants,name:`${c.current.character_name}'s capsule`})})]}):s.jsx("em",{children:i("Missing waitlist information")})},s3=({waitlistId:n,setOpen:i,setXupOpen:r})=>{const{t:c}=$(),u=S.useContext(He),[f]=Td("/incursions/api/waitlist");if(!f)return s.jsx("em",{children:c("Loading")});const h=f.waitlist.find(m=>{var x;return((x=m.character)==null?void 0:x.character_id)===u.current.character_id});return s.jsxs(s.Fragment,{children:[s.jsx(Da,{children:c("Fit review")}),s.jsx("em",{children:c("You are now on the waitlist! These are the fits you x-ed up with, please check to make sure you have everything and adjust your fit if needed.")}),h==null?void 0:h.fits.map(m=>s.jsx(De,{children:s.jsx(Zd,{fit:m})},m.id)),s.jsxs(Gt,{children:[s.jsx(K,{$variant:"primary",onClick:()=>r(!1),children:c("Yes, looks good")}),s.jsx(K,{$variant:"secondary",onClick:()=>i(!1),children:c("No, go back to update my fit")})]})]})};async function r3({character:n,eft:i,toastContext:r,waitlistId:c,alt:u,messagexup:f}){const h={eft:i,character_id:n,waitlist_id:parseInt(c),is_alt:u,messagexup:f};await xe("/incursions/api/waitlist/xup","post",{body:h}),_n(r,{title:"Added to waitlist.",message:"Your X has been added to the waitlist!",variant:"success"}),window.Notification&&Notification.requestPermission()}function c3(n){return n.waitlist.map(i=>{const r=[],c={};if(!i.main_character)return"";for(const u of i.fits){if(!u.character)continue;let f=c[u.character.character_id];f||(f={character:u.character,fits:[]},r.push(f),c[u.character.character_id]=f),f.fits.push(u)}return r.map(u=>{const f=`<a href="showinfo:1377//${u.character.character_id}">${u.character.name}</a>`,h=u.fits.map(m=>{const x=m.approved?"":", CHECK FIT";return`${m.ship.name[0]}${x}`});return f+" "+h.join(", ")}).join(" | ")}).join(`
`)}function o3({waitlist:n}){const{t:i}=$();return s.jsxs(ot,{children:[s.jsx("h2",{children:i("Notepad waitlist")}),s.jsxs("p",{children:[s.jsx("strong",{children:i("What is this?!")})," ",i("When ESI is having trouble, the Invite button may not always work. To invite manually, or to switch to a channel-based waitlist, you can copy the existing waitlist into a notepad or channel MOTD by copying the code below. It will make the names linkable so that they can be invited by dragging into the fleet composition.")]}),s.jsx(on,{readOnly:!0,style:{width:"100%"},rows:15,children:c3(n)})]})}const u3=w1`
  to {
    transform: rotate(360deg);
  }
`,d3=A.div`
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
`,f3=A.div`
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  border: 0.2rem solid ${n=>n.theme.colors.accent1};
  border-top-color: ${n=>n.theme.colors.text};
  animation: ${u3} 1.5s linear infinite;
  box-shadow: 0px -12px 8px -5px ${n=>n.theme.colors.text}40;
`,h3=()=>{const[n,i]=S.useState(!1),{t:r}=$();return s.jsxs(bn,{style:{width:"100%"},children:[s.jsx(bn.Head,{style:{marginBottom:"1em"},children:r("We apologize, the waitlist is currently closed.")}),s.jsx(bn.Paragraph,{style:{width:"50%"},children:r("Thank you for your patience. A fleet commander will be available shortly. Please stand by...")}),s.jsxs(bn.Paragraph,{style:{width:"50%"},children:[s.jsx(d3,{children:s.jsx(f3,{})}),s.jsx("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",marginTop:"1.5em"},children:s.jsx(ze,{children:s.jsx(K,{onClick:()=>i(!0),children:r("Click here to Ping FC's for Fleet")})})})]}),n&&s.jsx("iframe",{title:"Never Gonna Give You Up",width:"560",height:"315",src:"https://www.youtube-nocookie.com/embed/dQw4w9WgXcQ?autoplay=1&controls=0",frameBorder:"0",allow:"autoplay; encrypted-media; picture-in-picture",allowFullScreen:!0})]})},m3=A.div`
  width: 100%;
`,p3=A.div`
  display: flex;
  width: 100%;
  justify-content: center;
  margin-top: 1em;
  @media (max-width: 1100px) {
    flex-wrap: wrap;
  }
`,g3=A.div`
  width: 70%;
  @media (max-width: 970px) {
    width: 100%;
  }
`;function O0(n,i){let r=null,c=null;const u=()=>{if(c=setTimeout(u,i),r){const[f,h]=r;r=null,n.apply(f,h)}};return c=setTimeout(u,i*Math.random()),[function(...f){r=[this,arguments]},()=>{c&&clearTimeout(c)}]}async function x3(n){await xe("/incursions/api/waitlist/remove_waitlistentry","post",{body:{id:n}})}function y3(n){const i=S.useContext(el),[r,c]=S.useState(null),u=S.useCallback(()=>{xe("/incursions/api/waitlist","get").then(c).catch(()=>c(null))},[]);return S.useEffect(()=>{if(!i)return;const[f,h]=O0(u,2e3),m=x=>{JSON.parse(x.data).waitlist_id===n&&f()};return i.addEventListener("waitlist_update",m),i.addEventListener("open",f),()=>{h(),i.removeEventListener("waitlist_update",m),i.removeEventListener("open",f)}},[u,i,n]),S.useEffect(()=>{u()},[u]),[r,u]}function v3(){const n=S.useContext(He),i=S.useContext(el),[r,c]=S.useState(null),u=S.useCallback(()=>{if(!n.access["incursions.waitlist_fleet_view"]){c(null);return}xe("/incursions/api/fleet/members","get",{params:{character_id:n.current.character_id}}).then(c).catch(()=>c(null))},[n]);return S.useEffect(()=>{u()},[u]),S.useEffect(()=>{if(!i)return;const[f,h]=O0(u,2e3);return i.addEventListener("comp_update",f),i.addEventListener("open",f),()=>{h(),i.removeEventListener("comp_update",f),i.removeEventListener("open",f)}},[u,i]),r}function b3(){var V;const{t:n}=$(),i=S.useContext(He),r=S.useContext(pe),[c,u]=Jd(),[f,h]=S.useState(((V=window.localStorage)==null?void 0:V.getItem("FleetStat"))==="true"),[m,x]=S.useState(!0),[g,v]=S.useState(!1),w=S.useMemo(()=>parseInt(c.wl),[c.wl]),[j,E]=y3(w),R=v3(),B=c.mode||"columns";if(Qe(n("Waitlist")),S.useEffect(()=>{w||u("wl",1)},[w,u]),S.useEffect(()=>{x(!0)},[i.current.character_id]),!w)return null;if(j===null)return s.jsx("em",{children:n("Loading waitlist information.")});if(!j.open)return s.jsx(h3,{});const z=ye.find(j.waitlist,X=>X.main_character.character_id===i.main_character_id),H=()=>{var Z;const X=!f;h(X),(Z=window.localStorage)==null||Z.setItem("FleetStat",JSON.stringify(X))},q=X=>{u("mode",X)};return s.jsxs(s.Fragment,{children:[s.jsx(Wa,{children:s.jsxs(Gt,{children:[s.jsxs(ze,{children:[g&&s.jsx(Xe,{open:!0,setOpen:v,fill:"true",children:s.jsx(m3,{children:s.jsx(De,{children:s.jsx(E0,{setXupOpen:v})})})}),s.jsx(xx,{$variant:z?void 0:"primary",onClick:()=>v(!0),children:n(z?"Update fit(s)":"Join waitlist")}),s.jsx(K,{$variant:z?"danger":void 0,onClick:()=>z&&me(r,x3(z.id)),disabled:!z,children:n("Leave waitlist")})]}),i.access["incursions.waitlist_manage_waitlist"]&&s.jsxs(s.Fragment,{children:[s.jsx(ze,{children:["columns","matrix","compact","linear","rows"].map(X=>s.jsx(K,{active:B===X,onClick:()=>q(X),children:n(X.charAt(0).toUpperCase()+X.slice(1))},X))}),s.jsx(ze,{children:s.jsx(K,{active:B==="notepad",onClick:()=>q("notepad"),children:n("Notepad")})}),s.jsx(ze,{children:s.jsx(K,{onClick:H,children:n(f?"Close Fleet Stats":"Open Fleet Stats")})})]})]})}),s.jsx(Wa,{children:s.jsxs(p3,{children:[s.jsxs(g3,{children:[B==="columns"&&s.jsx(iw,{waitlist:j,onAction:E,fleetComposition:R,authContext:i,showMembers:f}),B==="compact"&&s.jsx(sw,{waitlist:j,onAction:E}),B==="linear"&&s.jsx(rw,{waitlist:j,onAction:E}),B==="matrix"&&s.jsx(ow,{waitlist:j,onAction:E,fleetComposition:R}),B==="rows"&&s.jsx(uw,{waitlist:j,onAction:E,fleetComposition:R}),B==="notepad"&&s.jsx(o3,{waitlist:j,onAction:E})]}),f&&m&&i.access["incursions.waitlist_fleet_view"]&&s.jsx(v0,{fleetpage:!1,setStatTempActive:x})]})})]})}const At=({component:n,loginRequired:i=!1,access:r=null})=>{const c=S.useContext(He);return!i&&!r?n:c?r&&!(Array.isArray(r)?r:[r]).some(h=>{var m;return(m=c.access)==null?void 0:m[h]})?s.jsx(s2,{}):n:s.jsx(l2,{})};function j3(){return s.jsxs(i1,{children:[s.jsx(Ce,{path:"/",element:s.jsx(h_,{})}),s.jsx(Ce,{path:"/fits",element:s.jsx(e_,{})}),s.jsx(Ce,{path:"/isk-h",element:s.jsx(__,{})}),s.jsx(Ce,{path:"/isk-h/calc",element:s.jsx(w_,{})}),s.jsx(Ce,{path:"/pilot",element:s.jsx(X_,{})}),s.jsx(Ce,{path:"/skills",element:s.jsx(t3,{})}),s.jsx(Ce,{path:"/skills/plans",element:s.jsx(F_,{})}),s.jsx(Ce,{path:"/badges",element:s.jsx(f_,{})}),s.jsx(Ce,{path:"/guide",element:s.jsx(d_,{})}),s.jsx(Ce,{path:"/guide/:guideName",element:s.jsx(u_,{})}),s.jsx(Ce,{path:"/legal",element:s.jsx(T_,{})}),s.jsx(Ce,{path:"/waitlist",element:s.jsx(At,{component:s.jsx(b3,{}),loginRequired:!0})}),s.jsx(Ce,{path:"/xup",element:s.jsx(At,{component:s.jsx(E0,{}),loginRequired:!0})}),s.jsx(Ce,{path:"/fc",element:s.jsx(At,{component:s.jsx(Aw,{}),access:["incursions.waitlist_manage_waitlist","incursions.waitlist_badges_view","incursions.waitlist_badges_manage","incursions.waitlist_bans_view","incursions.waitlist_bans_manage","incursions.waitlist_documentation_view","incursions.waitlist_history_view","incursions.waitlist_stats_view","incursions.waitlist_search","incursions.waitlist_notes_manage"]})}),s.jsx(Ce,{path:"/fc/announcements",element:s.jsx(At,{component:s.jsx(g2,{}),access:"incursions.waitlist_announcements_manage"})}),s.jsx(Ce,{path:"/fc/badges",element:s.jsx(At,{component:s.jsx(Fw,{}),access:["incursions.waitlist_badges_view","incursions.waitlist_badges_manage"]})}),s.jsx(Ce,{path:"/fc/bans",element:s.jsx(At,{component:s.jsx(M2,{}),access:["incursions.waitlist_bans_view","incursions.waitlist_bans_manage"]})}),s.jsx(Ce,{path:"/fc/documentation",element:s.jsx(At,{component:s.jsx(Yg,{}),access:"incursions.waitlist_documentation_view"})}),s.jsx(Ce,{path:"/fc/fleet",element:s.jsx(At,{component:s.jsx(xw,{}),access:"incursions.waitlist_manage_waitlist"})}),s.jsx(Ce,{path:"/fc/fleet/register",element:s.jsx(At,{component:s.jsx(yw,{}),access:"incursions.waitlist_manage_waitlist"})}),s.jsx(Ce,{path:"/fc/fleet/history",element:s.jsx(At,{component:s.jsx(bw,{}),access:"incursions.waitlist_history_view"})}),s.jsx(Ce,{path:"/fc/notes/add",element:s.jsx(At,{component:s.jsx(Cw,{}),access:"incursions.waitlist_notes_manage"})}),s.jsx(Ce,{path:"/fc/search",element:s.jsx(At,{component:s.jsx(Ow,{}),access:"incursions.waitlist_search"})}),s.jsx(Ce,{path:"/fc/stats",element:s.jsx(At,{component:s.jsx(Lw,{}),access:"incursions.waitlist_stats_view"})}),s.jsx(Ce,{path:"/fc/trainee",element:s.jsx(At,{component:s.jsx(Yg,{}),access:"incursions.waitlist_documentation_view"})}),s.jsx(Ce,{path:"*",element:s.jsx(r2,{})})]})}const S3=_1`
  html {
    text-rendering: optimizeLegibility;
    font-size: 16px;
    min-width: 300px;
  }
  body {
    min-height: 100vh;
    background-color: ${n=>n.theme.colors.background};
    color: ${n=>n.theme.colors.text};
    font-family: ${n=>n.theme.font.family};
    line-height: 1.5;
    font-weight: 400;
    overflow-y: scroll;

    ${n=>n.sticker&&n.theme.sticker&&`
        &:before {
          content: '';
          pointer-events: none;
          position: fixed;
          z-index: 100;
          width: 100%;
          height: 100%;
          background-position: 100% 100%;
          background-repeat: no-repeat;
          opacity: 1;
          background-size: 18%;
          background-image: url(${n.theme.sticker});
        }
    `}
  }

  em, i {
    font-style: italic;
  }
  strong, b {
    font-weight: bold;
  }
`;class w3 extends S.Component{constructor(r){var f,h;super(r);Fu(this,"addToast",r=>{this.setState({toasts:[...this.state.toasts,r]})});Fu(this,"changeCharacter",r=>{if(!this.state.auth)return;const c={...this.state.auth},u=c.characters.find(f=>f.character_id===r);u&&(c.current=u,this.setState({auth:c}),localStorage.setItem("selectedCharacter",r.toString()))});const c=(f=window.localStorage)==null?void 0:f.getItem("theme"),u=(h=window.localStorage)==null?void 0:h.getItem("Sticker");this.state={auth:null,toasts:[],events:null,eventErrors:0,theme:c&&ht[c]?c:"Light",sticker:u!=="false"}}componentDidMount(){vb(r=>this.setState({auth:r}))}componentDidUpdate(){if(this.state.auth&&!this.state.events){const r=new EventSource("/incursions/api/sse/stream");r.addEventListener("open",()=>{this.setState({eventErrors:0})}),r.addEventListener("error",()=>{r.close(),setTimeout(()=>{this.setState(c=>({events:null,eventErrors:c.eventErrors+1}))},this.state.eventErrors*5e3+Math.random()*1e4)}),this.setState({events:r})}}render(){return s.jsx(J.StrictMode,{children:s.jsxs(T1,{theme:ht[this.state.theme],children:[s.jsx(S3,{sticker:this.state.sticker}),s.jsx(pe.Provider,{value:this.addToast,children:s.jsx(el.Provider,{value:this.state.events,children:s.jsx(He.Provider,{value:this.state.auth,children:s.jsx(l1,{basename:"/incursions/waitlist",children:s.jsxs(s1,{children:[s.jsx(Wa,{children:s.jsx(t2,{onChangeCharacter:this.changeCharacter,theme:this.state.theme,setTheme:r=>{this.setState({theme:r}),localStorage.setItem("theme",r)},sticker:this.state.sticker,setSticker:r=>{this.setState({sticker:r}),localStorage.setItem("Sticker",r.toString())}})}),s.jsx(Wa,{children:s.jsx(yb,{})}),s.jsx(Wa,{children:s.jsx(j3,{})}),s.jsx(Wa,{children:s.jsx(ab,{toasts:this.state.toasts,setToasts:r=>this.setState({toasts:r})})})]})})})})})]})})}}const _3=document.getElementById("root"),T3=eb.createRoot(_3);T3.render(s.jsx(J.StrictMode,{children:s.jsx(Wa,{children:s.jsx(w3,{})})}));
//# sourceMappingURL=index-D99b_G5I.js.map
