meshy-node 0.10.10 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,336 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-DYIrafIS.js","assets/DashboardShared-CWPKe72D.js","assets/MarkdownPreviewFrame-D4zcHgFW.js","assets/PreviewTab-6cQl06LP.js","assets/DashboardPage-BaHExl1O.css","assets/SharedConversationPage-B9wCWxLh.js"])))=>i.map(i=>d[i]);
2
+ function ZS(t,r){for(var o=0;o<r.length;o++){const s=r[o];if(typeof s!="string"&&!Array.isArray(s)){for(const c in s)if(c!=="default"&&!(c in t)){const u=Object.getOwnPropertyDescriptor(s,c);u&&Object.defineProperty(t,c,u.get?u:{enumerable:!0,get:()=>s[c]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const c of document.querySelectorAll('link[rel="modulepreload"]'))s(c);new MutationObserver(c=>{for(const u of c)if(u.type==="childList")for(const m of u.addedNodes)m.tagName==="LINK"&&m.rel==="modulepreload"&&s(m)}).observe(document,{childList:!0,subtree:!0});function o(c){const u={};return c.integrity&&(u.integrity=c.integrity),c.referrerPolicy&&(u.referrerPolicy=c.referrerPolicy),c.crossOrigin==="use-credentials"?u.credentials="include":c.crossOrigin==="anonymous"?u.credentials="omit":u.credentials="same-origin",u}function s(c){if(c.ep)return;c.ep=!0;const u=o(c);fetch(c.href,u)}})();function Ny(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Cd={exports:{}},Al={};/**
3
+ * @license React
4
+ * react-jsx-runtime.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var lv;function FS(){if(lv)return Al;lv=1;var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function o(s,c,u){var m=null;if(u!==void 0&&(m=""+u),c.key!==void 0&&(m=""+c.key),"key"in c){u={};for(var h in c)h!=="key"&&(u[h]=c[h])}else u=c;return c=u.ref,{$$typeof:t,type:s,key:m,ref:c!==void 0?c:null,props:u}}return Al.Fragment=r,Al.jsx=o,Al.jsxs=o,Al}var sv;function WS(){return sv||(sv=1,Cd.exports=FS()),Cd.exports}var f=WS(),Rd={exports:{}},Ne={};/**
11
+ * @license React
12
+ * react.production.js
13
+ *
14
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
15
+ *
16
+ * This source code is licensed under the MIT license found in the
17
+ * LICENSE file in the root directory of this source tree.
18
+ */var iv;function JS(){if(iv)return Ne;iv=1;var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),c=Symbol.for("react.profiler"),u=Symbol.for("react.consumer"),m=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),v=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),b=Symbol.for("react.lazy"),y=Symbol.iterator;function S(N){return N===null||typeof N!="object"?null:(N=y&&N[y]||N["@@iterator"],typeof N=="function"?N:null)}var A={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},C=Object.assign,T={};function E(N,I,J){this.props=N,this.context=I,this.refs=T,this.updater=J||A}E.prototype.isReactComponent={},E.prototype.setState=function(N,I){if(typeof N!="object"&&typeof N!="function"&&N!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,N,I,"setState")},E.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function R(){}R.prototype=E.prototype;function k(N,I,J){this.props=N,this.context=I,this.refs=T,this.updater=J||A}var O=k.prototype=new R;O.constructor=k,C(O,E.prototype),O.isPureReactComponent=!0;var U=Array.isArray,z={H:null,A:null,T:null,S:null,V:null},G=Object.prototype.hasOwnProperty;function Y(N,I,J,Q,le,te){return J=te.ref,{$$typeof:t,type:N,key:I,ref:J!==void 0?J:null,props:te}}function q(N,I){return Y(N.type,I,void 0,void 0,void 0,N.props)}function re(N){return typeof N=="object"&&N!==null&&N.$$typeof===t}function fe(N){var I={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(J){return I[J]})}var ue=/\/+/g;function de(N,I){return typeof N=="object"&&N!==null&&N.key!=null?fe(""+N.key):I.toString(36)}function W(){}function se(N){switch(N.status){case"fulfilled":return N.value;case"rejected":throw N.reason;default:switch(typeof N.status=="string"?N.then(W,W):(N.status="pending",N.then(function(I){N.status==="pending"&&(N.status="fulfilled",N.value=I)},function(I){N.status==="pending"&&(N.status="rejected",N.reason=I)})),N.status){case"fulfilled":return N.value;case"rejected":throw N.reason}}throw N}function ee(N,I,J,Q,le){var te=typeof N;(te==="undefined"||te==="boolean")&&(N=null);var ae=!1;if(N===null)ae=!0;else switch(te){case"bigint":case"string":case"number":ae=!0;break;case"object":switch(N.$$typeof){case t:case r:ae=!0;break;case b:return ae=N._init,ee(ae(N._payload),I,J,Q,le)}}if(ae)return le=le(N),ae=Q===""?"."+de(N,0):Q,U(le)?(J="",ae!=null&&(J=ae.replace(ue,"$&/")+"/"),ee(le,I,J,"",function(xe){return xe})):le!=null&&(re(le)&&(le=q(le,J+(le.key==null||N&&N.key===le.key?"":(""+le.key).replace(ue,"$&/")+"/")+ae)),I.push(le)),1;ae=0;var ie=Q===""?".":Q+":";if(U(N))for(var ce=0;ce<N.length;ce++)Q=N[ce],te=ie+de(Q,ce),ae+=ee(Q,I,J,te,le);else if(ce=S(N),typeof ce=="function")for(N=ce.call(N),ce=0;!(Q=N.next()).done;)Q=Q.value,te=ie+de(Q,ce++),ae+=ee(Q,I,J,te,le);else if(te==="object"){if(typeof N.then=="function")return ee(se(N),I,J,Q,le);throw I=String(N),Error("Objects are not valid as a React child (found: "+(I==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":I)+"). If you meant to render a collection of children, use an array instead.")}return ae}function j(N,I,J){if(N==null)return N;var Q=[],le=0;return ee(N,Q,"","",function(te){return I.call(J,te,le++)}),Q}function P(N){if(N._status===-1){var I=N._result;I=I(),I.then(function(J){(N._status===0||N._status===-1)&&(N._status=1,N._result=J)},function(J){(N._status===0||N._status===-1)&&(N._status=2,N._result=J)}),N._status===-1&&(N._status=0,N._result=I)}if(N._status===1)return N._result.default;throw N._result}var H=typeof reportError=="function"?reportError:function(N){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var I=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof N=="object"&&N!==null&&typeof N.message=="string"?String(N.message):String(N),error:N});if(!window.dispatchEvent(I))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",N);return}console.error(N)};function F(){}return Ne.Children={map:j,forEach:function(N,I,J){j(N,function(){I.apply(this,arguments)},J)},count:function(N){var I=0;return j(N,function(){I++}),I},toArray:function(N){return j(N,function(I){return I})||[]},only:function(N){if(!re(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},Ne.Component=E,Ne.Fragment=o,Ne.Profiler=c,Ne.PureComponent=k,Ne.StrictMode=s,Ne.Suspense=v,Ne.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=z,Ne.__COMPILER_RUNTIME={__proto__:null,c:function(N){return z.H.useMemoCache(N)}},Ne.cache=function(N){return function(){return N.apply(null,arguments)}},Ne.cloneElement=function(N,I,J){if(N==null)throw Error("The argument must be a React element, but you passed "+N+".");var Q=C({},N.props),le=N.key,te=void 0;if(I!=null)for(ae in I.ref!==void 0&&(te=void 0),I.key!==void 0&&(le=""+I.key),I)!G.call(I,ae)||ae==="key"||ae==="__self"||ae==="__source"||ae==="ref"&&I.ref===void 0||(Q[ae]=I[ae]);var ae=arguments.length-2;if(ae===1)Q.children=J;else if(1<ae){for(var ie=Array(ae),ce=0;ce<ae;ce++)ie[ce]=arguments[ce+2];Q.children=ie}return Y(N.type,le,void 0,void 0,te,Q)},Ne.createContext=function(N){return N={$$typeof:m,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null},N.Provider=N,N.Consumer={$$typeof:u,_context:N},N},Ne.createElement=function(N,I,J){var Q,le={},te=null;if(I!=null)for(Q in I.key!==void 0&&(te=""+I.key),I)G.call(I,Q)&&Q!=="key"&&Q!=="__self"&&Q!=="__source"&&(le[Q]=I[Q]);var ae=arguments.length-2;if(ae===1)le.children=J;else if(1<ae){for(var ie=Array(ae),ce=0;ce<ae;ce++)ie[ce]=arguments[ce+2];le.children=ie}if(N&&N.defaultProps)for(Q in ae=N.defaultProps,ae)le[Q]===void 0&&(le[Q]=ae[Q]);return Y(N,te,void 0,void 0,null,le)},Ne.createRef=function(){return{current:null}},Ne.forwardRef=function(N){return{$$typeof:h,render:N}},Ne.isValidElement=re,Ne.lazy=function(N){return{$$typeof:b,_payload:{_status:-1,_result:N},_init:P}},Ne.memo=function(N,I){return{$$typeof:p,type:N,compare:I===void 0?null:I}},Ne.startTransition=function(N){var I=z.T,J={};z.T=J;try{var Q=N(),le=z.S;le!==null&&le(J,Q),typeof Q=="object"&&Q!==null&&typeof Q.then=="function"&&Q.then(F,H)}catch(te){H(te)}finally{z.T=I}},Ne.unstable_useCacheRefresh=function(){return z.H.useCacheRefresh()},Ne.use=function(N){return z.H.use(N)},Ne.useActionState=function(N,I,J){return z.H.useActionState(N,I,J)},Ne.useCallback=function(N,I){return z.H.useCallback(N,I)},Ne.useContext=function(N){return z.H.useContext(N)},Ne.useDebugValue=function(){},Ne.useDeferredValue=function(N,I){return z.H.useDeferredValue(N,I)},Ne.useEffect=function(N,I,J){var Q=z.H;if(typeof J=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return Q.useEffect(N,I)},Ne.useId=function(){return z.H.useId()},Ne.useImperativeHandle=function(N,I,J){return z.H.useImperativeHandle(N,I,J)},Ne.useInsertionEffect=function(N,I){return z.H.useInsertionEffect(N,I)},Ne.useLayoutEffect=function(N,I){return z.H.useLayoutEffect(N,I)},Ne.useMemo=function(N,I){return z.H.useMemo(N,I)},Ne.useOptimistic=function(N,I){return z.H.useOptimistic(N,I)},Ne.useReducer=function(N,I,J){return z.H.useReducer(N,I,J)},Ne.useRef=function(N){return z.H.useRef(N)},Ne.useState=function(N){return z.H.useState(N)},Ne.useSyncExternalStore=function(N,I,J){return z.H.useSyncExternalStore(N,I,J)},Ne.useTransition=function(){return z.H.useTransition()},Ne.version="19.1.0",Ne}var cv;function Of(){return cv||(cv=1,Rd.exports=JS()),Rd.exports}var g=Of();const oe=Ny(g),Df=ZS({__proto__:null,default:oe},[g]);var Ad={exports:{}},kl={},kd={exports:{}},_d={};/**
19
+ * @license React
20
+ * scheduler.production.js
21
+ *
22
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
23
+ *
24
+ * This source code is licensed under the MIT license found in the
25
+ * LICENSE file in the root directory of this source tree.
26
+ */var uv;function e2(){return uv||(uv=1,(function(t){function r(j,P){var H=j.length;j.push(P);e:for(;0<H;){var F=H-1>>>1,N=j[F];if(0<c(N,P))j[F]=P,j[H]=N,H=F;else break e}}function o(j){return j.length===0?null:j[0]}function s(j){if(j.length===0)return null;var P=j[0],H=j.pop();if(H!==P){j[0]=H;e:for(var F=0,N=j.length,I=N>>>1;F<I;){var J=2*(F+1)-1,Q=j[J],le=J+1,te=j[le];if(0>c(Q,H))le<N&&0>c(te,Q)?(j[F]=te,j[le]=H,F=le):(j[F]=Q,j[J]=H,F=J);else if(le<N&&0>c(te,H))j[F]=te,j[le]=H,F=le;else break e}}return P}function c(j,P){var H=j.sortIndex-P.sortIndex;return H!==0?H:j.id-P.id}if(t.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var u=performance;t.unstable_now=function(){return u.now()}}else{var m=Date,h=m.now();t.unstable_now=function(){return m.now()-h}}var v=[],p=[],b=1,y=null,S=3,A=!1,C=!1,T=!1,E=!1,R=typeof setTimeout=="function"?setTimeout:null,k=typeof clearTimeout=="function"?clearTimeout:null,O=typeof setImmediate<"u"?setImmediate:null;function U(j){for(var P=o(p);P!==null;){if(P.callback===null)s(p);else if(P.startTime<=j)s(p),P.sortIndex=P.expirationTime,r(v,P);else break;P=o(p)}}function z(j){if(T=!1,U(j),!C)if(o(v)!==null)C=!0,G||(G=!0,de());else{var P=o(p);P!==null&&ee(z,P.startTime-j)}}var G=!1,Y=-1,q=5,re=-1;function fe(){return E?!0:!(t.unstable_now()-re<q)}function ue(){if(E=!1,G){var j=t.unstable_now();re=j;var P=!0;try{e:{C=!1,T&&(T=!1,k(Y),Y=-1),A=!0;var H=S;try{t:{for(U(j),y=o(v);y!==null&&!(y.expirationTime>j&&fe());){var F=y.callback;if(typeof F=="function"){y.callback=null,S=y.priorityLevel;var N=F(y.expirationTime<=j);if(j=t.unstable_now(),typeof N=="function"){y.callback=N,U(j),P=!0;break t}y===o(v)&&s(v),U(j)}else s(v);y=o(v)}if(y!==null)P=!0;else{var I=o(p);I!==null&&ee(z,I.startTime-j),P=!1}}break e}finally{y=null,S=H,A=!1}P=void 0}}finally{P?de():G=!1}}}var de;if(typeof O=="function")de=function(){O(ue)};else if(typeof MessageChannel<"u"){var W=new MessageChannel,se=W.port2;W.port1.onmessage=ue,de=function(){se.postMessage(null)}}else de=function(){R(ue,0)};function ee(j,P){Y=R(function(){j(t.unstable_now())},P)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(j){j.callback=null},t.unstable_forceFrameRate=function(j){0>j||125<j?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):q=0<j?Math.floor(1e3/j):5},t.unstable_getCurrentPriorityLevel=function(){return S},t.unstable_next=function(j){switch(S){case 1:case 2:case 3:var P=3;break;default:P=S}var H=S;S=P;try{return j()}finally{S=H}},t.unstable_requestPaint=function(){E=!0},t.unstable_runWithPriority=function(j,P){switch(j){case 1:case 2:case 3:case 4:case 5:break;default:j=3}var H=S;S=j;try{return P()}finally{S=H}},t.unstable_scheduleCallback=function(j,P,H){var F=t.unstable_now();switch(typeof H=="object"&&H!==null?(H=H.delay,H=typeof H=="number"&&0<H?F+H:F):H=F,j){case 1:var N=-1;break;case 2:N=250;break;case 5:N=1073741823;break;case 4:N=1e4;break;default:N=5e3}return N=H+N,j={id:b++,callback:P,priorityLevel:j,startTime:H,expirationTime:N,sortIndex:-1},H>F?(j.sortIndex=H,r(p,j),o(v)===null&&j===o(p)&&(T?(k(Y),Y=-1):T=!0,ee(z,H-F))):(j.sortIndex=N,r(v,j),C||A||(C=!0,G||(G=!0,de()))),j},t.unstable_shouldYield=fe,t.unstable_wrapCallback=function(j){var P=S;return function(){var H=S;S=P;try{return j.apply(this,arguments)}finally{S=H}}}})(_d)),_d}var dv;function t2(){return dv||(dv=1,kd.exports=e2()),kd.exports}var jd={exports:{}},jt={};/**
27
+ * @license React
28
+ * react-dom.production.js
29
+ *
30
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
31
+ *
32
+ * This source code is licensed under the MIT license found in the
33
+ * LICENSE file in the root directory of this source tree.
34
+ */var fv;function n2(){if(fv)return jt;fv=1;var t=Of();function r(v){var p="https://react.dev/errors/"+v;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var b=2;b<arguments.length;b++)p+="&args[]="+encodeURIComponent(arguments[b])}return"Minified React error #"+v+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(){}var s={d:{f:o,r:function(){throw Error(r(522))},D:o,C:o,L:o,m:o,X:o,S:o,M:o},p:0,findDOMNode:null},c=Symbol.for("react.portal");function u(v,p,b){var y=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:c,key:y==null?null:""+y,children:v,containerInfo:p,implementation:b}}var m=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function h(v,p){if(v==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return jt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=s,jt.createPortal=function(v,p){var b=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(r(299));return u(v,p,null,b)},jt.flushSync=function(v){var p=m.T,b=s.p;try{if(m.T=null,s.p=2,v)return v()}finally{m.T=p,s.p=b,s.d.f()}},jt.preconnect=function(v,p){typeof v=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,s.d.C(v,p))},jt.prefetchDNS=function(v){typeof v=="string"&&s.d.D(v)},jt.preinit=function(v,p){if(typeof v=="string"&&p&&typeof p.as=="string"){var b=p.as,y=h(b,p.crossOrigin),S=typeof p.integrity=="string"?p.integrity:void 0,A=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;b==="style"?s.d.S(v,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:y,integrity:S,fetchPriority:A}):b==="script"&&s.d.X(v,{crossOrigin:y,integrity:S,fetchPriority:A,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},jt.preinitModule=function(v,p){if(typeof v=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var b=h(p.as,p.crossOrigin);s.d.M(v,{crossOrigin:b,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&s.d.M(v)},jt.preload=function(v,p){if(typeof v=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var b=p.as,y=h(b,p.crossOrigin);s.d.L(v,b,{crossOrigin:y,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},jt.preloadModule=function(v,p){if(typeof v=="string")if(p){var b=h(p.as,p.crossOrigin);s.d.m(v,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:b,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else s.d.m(v)},jt.requestFormReset=function(v){s.d.r(v)},jt.unstable_batchedUpdates=function(v,p){return v(p)},jt.useFormState=function(v,p,b){return m.H.useFormState(v,p,b)},jt.useFormStatus=function(){return m.H.useHostTransitionStatus()},jt.version="19.1.0",jt}var mv;function Cy(){if(mv)return jd.exports;mv=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(r){console.error(r)}}return t(),jd.exports=n2(),jd.exports}/**
35
+ * @license React
36
+ * react-dom-client.production.js
37
+ *
38
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
39
+ *
40
+ * This source code is licensed under the MIT license found in the
41
+ * LICENSE file in the root directory of this source tree.
42
+ */var hv;function a2(){if(hv)return kl;hv=1;var t=t2(),r=Of(),o=Cy();function s(e){var n="https://react.dev/errors/"+e;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)n+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function c(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function u(e){var n=e,a=e;if(e.alternate)for(;n.return;)n=n.return;else{e=n;do n=e,(n.flags&4098)!==0&&(a=n.return),e=n.return;while(e)}return n.tag===3?a:null}function m(e){if(e.tag===13){var n=e.memoizedState;if(n===null&&(e=e.alternate,e!==null&&(n=e.memoizedState)),n!==null)return n.dehydrated}return null}function h(e){if(u(e)!==e)throw Error(s(188))}function v(e){var n=e.alternate;if(!n){if(n=u(e),n===null)throw Error(s(188));return n!==e?null:e}for(var a=e,l=n;;){var i=a.return;if(i===null)break;var d=i.alternate;if(d===null){if(l=i.return,l!==null){a=l;continue}break}if(i.child===d.child){for(d=i.child;d;){if(d===a)return h(i),e;if(d===l)return h(i),n;d=d.sibling}throw Error(s(188))}if(a.return!==l.return)a=i,l=d;else{for(var x=!1,w=i.child;w;){if(w===a){x=!0,a=i,l=d;break}if(w===l){x=!0,l=i,a=d;break}w=w.sibling}if(!x){for(w=d.child;w;){if(w===a){x=!0,a=d,l=i;break}if(w===l){x=!0,l=d,a=i;break}w=w.sibling}if(!x)throw Error(s(189))}}if(a.alternate!==l)throw Error(s(190))}if(a.tag!==3)throw Error(s(188));return a.stateNode.current===a?e:n}function p(e){var n=e.tag;if(n===5||n===26||n===27||n===6)return e;for(e=e.child;e!==null;){if(n=p(e),n!==null)return n;e=e.sibling}return null}var b=Object.assign,y=Symbol.for("react.element"),S=Symbol.for("react.transitional.element"),A=Symbol.for("react.portal"),C=Symbol.for("react.fragment"),T=Symbol.for("react.strict_mode"),E=Symbol.for("react.profiler"),R=Symbol.for("react.provider"),k=Symbol.for("react.consumer"),O=Symbol.for("react.context"),U=Symbol.for("react.forward_ref"),z=Symbol.for("react.suspense"),G=Symbol.for("react.suspense_list"),Y=Symbol.for("react.memo"),q=Symbol.for("react.lazy"),re=Symbol.for("react.activity"),fe=Symbol.for("react.memo_cache_sentinel"),ue=Symbol.iterator;function de(e){return e===null||typeof e!="object"?null:(e=ue&&e[ue]||e["@@iterator"],typeof e=="function"?e:null)}var W=Symbol.for("react.client.reference");function se(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===W?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case C:return"Fragment";case E:return"Profiler";case T:return"StrictMode";case z:return"Suspense";case G:return"SuspenseList";case re:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case A:return"Portal";case O:return(e.displayName||"Context")+".Provider";case k:return(e._context.displayName||"Context")+".Consumer";case U:var n=e.render;return e=e.displayName,e||(e=n.displayName||n.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Y:return n=e.displayName||null,n!==null?n:se(e.type)||"Memo";case q:n=e._payload,e=e._init;try{return se(e(n))}catch{}}return null}var ee=Array.isArray,j=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,P=o.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,H={pending:!1,data:null,method:null,action:null},F=[],N=-1;function I(e){return{current:e}}function J(e){0>N||(e.current=F[N],F[N]=null,N--)}function Q(e,n){N++,F[N]=e.current,e.current=n}var le=I(null),te=I(null),ae=I(null),ie=I(null);function ce(e,n){switch(Q(ae,n),Q(te,e),Q(le,null),n.nodeType){case 9:case 11:e=(e=n.documentElement)&&(e=e.namespaceURI)?Mg(e):0;break;default:if(e=n.tagName,n=n.namespaceURI)n=Mg(n),e=zg(n,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}J(le),Q(le,e)}function xe(){J(le),J(te),J(ae)}function Re(e){e.memoizedState!==null&&Q(ie,e);var n=le.current,a=zg(n,e.type);n!==a&&(Q(te,e),Q(le,a))}function Te(e){te.current===e&&(J(le),J(te)),ie.current===e&&(J(ie),El._currentValue=H)}var Ae=Object.prototype.hasOwnProperty,Je=t.unstable_scheduleCallback,at=t.unstable_cancelCallback,dn=t.unstable_shouldYield,fn=t.unstable_requestPaint,lt=t.unstable_now,Qa=t.unstable_getCurrentPriorityLevel,ht=t.unstable_ImmediatePriority,Nr=t.unstable_UserBlockingPriority,Un=t.unstable_NormalPriority,st=t.unstable_LowPriority,mn=t.unstable_IdlePriority,Cr=t.log,ca=t.unstable_setDisableYieldValue,$t=null,Ct=null;function Mt(e){if(typeof Cr=="function"&&ca(e),Ct&&typeof Ct.setStrictMode=="function")try{Ct.setStrictMode($t,e)}catch{}}var We=Math.clz32?Math.clz32:Cn,Nn=Math.log,Rr=Math.LN2;function Cn(e){return e>>>=0,e===0?32:31-(Nn(e)/Rr|0)|0}var ua=256,da=4194304;function Jt(e){var n=e&42;if(n!==0)return n;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 Bn(e,n,a){var l=e.pendingLanes;if(l===0)return 0;var i=0,d=e.suspendedLanes,x=e.pingedLanes;e=e.warmLanes;var w=l&134217727;return w!==0?(l=w&~d,l!==0?i=Jt(l):(x&=w,x!==0?i=Jt(x):a||(a=w&~e,a!==0&&(i=Jt(a))))):(w=l&~d,w!==0?i=Jt(w):x!==0?i=Jt(x):a||(a=l&~e,a!==0&&(i=Jt(a)))),i===0?0:n!==0&&n!==i&&(n&d)===0&&(d=i&-i,a=n&-n,d>=a||d===32&&(a&4194048)!==0)?n:i}function Hn(e,n){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&n)===0}function fa(e,n){switch(e){case 1:case 2:case 4:case 8:case 64:return n+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 n+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 zt(){var e=ua;return ua<<=1,(ua&4194048)===0&&(ua=256),e}function Ka(){var e=da;return da<<=1,(da&62914560)===0&&(da=4194304),e}function Za(e){for(var n=[],a=0;31>a;a++)n.push(e);return n}function be(e,n){e.pendingLanes|=n,n!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Xe(e,n,a,l,i,d){var x=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 w=e.entanglements,_=e.expirationTimes,B=e.hiddenUpdates;for(a=x&~a;0<a;){var X=31-We(a),Z=1<<X;w[X]=0,_[X]=-1;var $=B[X];if($!==null)for(B[X]=null,X=0;X<$.length;X++){var V=$[X];V!==null&&(V.lane&=-536870913)}a&=~Z}l!==0&&me(e,l,0),d!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=d&~(x&~n))}function me(e,n,a){e.pendingLanes|=n,e.suspendedLanes&=~n;var l=31-We(n);e.entangledLanes|=n,e.entanglements[l]=e.entanglements[l]|1073741824|a&4194090}function He(e,n){var a=e.entangledLanes|=n;for(e=e.entanglements;a;){var l=31-We(a),i=1<<l;i&n|e[l]&n&&(e[l]|=n),a&=~i}}function Qe(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 pt(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Fa(){var e=P.p;return e!==0?e:(e=window.event,e===void 0?32:ev(e.type))}function gt(e,n){var a=P.p;try{return P.p=e,n()}finally{P.p=a}}var it=Math.random().toString(36).slice(2),ct="__reactFiber$"+it,Ke="__reactProps$"+it,xt="__reactContainer$"+it,Ar="__reactEvents$"+it,Pn="__reactListeners$"+it,wm="__reactHandles$"+it,Sm="__reactResources$"+it,Mo="__reactMarker$"+it;function bc(e){delete e[ct],delete e[Ke],delete e[Ar],delete e[Pn],delete e[wm]}function kr(e){var n=e[ct];if(n)return n;for(var a=e.parentNode;a;){if(n=a[xt]||a[ct]){if(a=n.alternate,n.child!==null||a!==null&&a.child!==null)for(e=Hg(e);e!==null;){if(a=e[ct])return a;e=Hg(e)}return n}e=a,a=e.parentNode}return null}function _r(e){if(e=e[ct]||e[xt]){var n=e.tag;if(n===5||n===6||n===13||n===26||n===27||n===3)return e}return null}function zo(e){var n=e.tag;if(n===5||n===26||n===27||n===6)return e.stateNode;throw Error(s(33))}function jr(e){var n=e[Sm];return n||(n=e[Sm]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function wt(e){e[Mo]=!0}var Em=new Set,Tm={};function Wa(e,n){Or(e,n),Or(e+"Capture",n)}function Or(e,n){for(Tm[e]=n,e=0;e<n.length;e++)Em.add(n[e])}var q1=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]*$"),Nm={},Cm={};function V1(e){return Ae.call(Cm,e)?!0:Ae.call(Nm,e)?!1:q1.test(e)?Cm[e]=!0:(Nm[e]=!0,!1)}function Jl(e,n,a){if(V1(n))if(a===null)e.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":e.removeAttribute(n);return;case"boolean":var l=n.toLowerCase().slice(0,5);if(l!=="data-"&&l!=="aria-"){e.removeAttribute(n);return}}e.setAttribute(n,""+a)}}function es(e,n,a){if(a===null)e.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(n);return}e.setAttribute(n,""+a)}}function $n(e,n,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(n,a,""+l)}}var xc,Rm;function Dr(e){if(xc===void 0)try{throw Error()}catch(a){var n=a.stack.trim().match(/\n( *(at )?)/);xc=n&&n[1]||"",Rm=-1<a.stack.indexOf(`
43
+ at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
44
+ `+xc+e+Rm}var wc=!1;function Sc(e,n){if(!e||wc)return"";wc=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var l={DetermineComponentFrameRoot:function(){try{if(n){var Z=function(){throw Error()};if(Object.defineProperty(Z.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Z,[])}catch(V){var $=V}Reflect.construct(e,[],Z)}else{try{Z.call()}catch(V){$=V}e.call(Z.prototype)}}else{try{throw Error()}catch(V){$=V}(Z=e())&&typeof Z.catch=="function"&&Z.catch(function(){})}}catch(V){if(V&&$&&typeof V.stack=="string")return[V.stack,$.stack]}return[null,null]}};l.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var i=Object.getOwnPropertyDescriptor(l.DetermineComponentFrameRoot,"name");i&&i.configurable&&Object.defineProperty(l.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var d=l.DetermineComponentFrameRoot(),x=d[0],w=d[1];if(x&&w){var _=x.split(`
45
+ `),B=w.split(`
46
+ `);for(i=l=0;l<_.length&&!_[l].includes("DetermineComponentFrameRoot");)l++;for(;i<B.length&&!B[i].includes("DetermineComponentFrameRoot");)i++;if(l===_.length||i===B.length)for(l=_.length-1,i=B.length-1;1<=l&&0<=i&&_[l]!==B[i];)i--;for(;1<=l&&0<=i;l--,i--)if(_[l]!==B[i]){if(l!==1||i!==1)do if(l--,i--,0>i||_[l]!==B[i]){var X=`
47
+ `+_[l].replace(" at new "," at ");return e.displayName&&X.includes("<anonymous>")&&(X=X.replace("<anonymous>",e.displayName)),X}while(1<=l&&0<=i);break}}}finally{wc=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?Dr(a):""}function I1(e){switch(e.tag){case 26:case 27:case 5:return Dr(e.type);case 16:return Dr("Lazy");case 13:return Dr("Suspense");case 19:return Dr("SuspenseList");case 0:case 15:return Sc(e.type,!1);case 11:return Sc(e.type.render,!1);case 1:return Sc(e.type,!0);case 31:return Dr("Activity");default:return""}}function Am(e){try{var n="";do n+=I1(e),e=e.return;while(e);return n}catch(a){return`
48
+ Error generating stack: `+a.message+`
49
+ `+a.stack}}function en(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function km(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function Y1(e){var n=km(e)?"checked":"value",a=Object.getOwnPropertyDescriptor(e.constructor.prototype,n),l=""+e[n];if(!e.hasOwnProperty(n)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var i=a.get,d=a.set;return Object.defineProperty(e,n,{configurable:!0,get:function(){return i.call(this)},set:function(x){l=""+x,d.call(this,x)}}),Object.defineProperty(e,n,{enumerable:a.enumerable}),{getValue:function(){return l},setValue:function(x){l=""+x},stopTracking:function(){e._valueTracker=null,delete e[n]}}}}function ts(e){e._valueTracker||(e._valueTracker=Y1(e))}function _m(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var a=n.getValue(),l="";return e&&(l=km(e)?e.checked?"true":"false":e.value),e=l,e!==a?(n.setValue(e),!0):!1}function ns(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 G1=/[\n"\\]/g;function tn(e){return e.replace(G1,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function Ec(e,n,a,l,i,d,x,w){e.name="",x!=null&&typeof x!="function"&&typeof x!="symbol"&&typeof x!="boolean"?e.type=x:e.removeAttribute("type"),n!=null?x==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+en(n)):e.value!==""+en(n)&&(e.value=""+en(n)):x!=="submit"&&x!=="reset"||e.removeAttribute("value"),n!=null?Tc(e,x,en(n)):a!=null?Tc(e,x,en(a)):l!=null&&e.removeAttribute("value"),i==null&&d!=null&&(e.defaultChecked=!!d),i!=null&&(e.checked=i&&typeof i!="function"&&typeof i!="symbol"),w!=null&&typeof w!="function"&&typeof w!="symbol"&&typeof w!="boolean"?e.name=""+en(w):e.removeAttribute("name")}function jm(e,n,a,l,i,d,x,w){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),n!=null||a!=null){if(!(d!=="submit"&&d!=="reset"||n!=null))return;a=a!=null?""+en(a):"",n=n!=null?""+en(n):a,w||n===e.value||(e.value=n),e.defaultValue=n}l=l??i,l=typeof l!="function"&&typeof l!="symbol"&&!!l,e.checked=w?e.checked:!!l,e.defaultChecked=!!l,x!=null&&typeof x!="function"&&typeof x!="symbol"&&typeof x!="boolean"&&(e.name=x)}function Tc(e,n,a){n==="number"&&ns(e.ownerDocument)===e||e.defaultValue===""+a||(e.defaultValue=""+a)}function Mr(e,n,a,l){if(e=e.options,n){n={};for(var i=0;i<a.length;i++)n["$"+a[i]]=!0;for(a=0;a<e.length;a++)i=n.hasOwnProperty("$"+e[a].value),e[a].selected!==i&&(e[a].selected=i),i&&l&&(e[a].defaultSelected=!0)}else{for(a=""+en(a),n=null,i=0;i<e.length;i++){if(e[i].value===a){e[i].selected=!0,l&&(e[i].defaultSelected=!0);return}n!==null||e[i].disabled||(n=e[i])}n!==null&&(n.selected=!0)}}function Om(e,n,a){if(n!=null&&(n=""+en(n),n!==e.value&&(e.value=n),a==null)){e.defaultValue!==n&&(e.defaultValue=n);return}e.defaultValue=a!=null?""+en(a):""}function Dm(e,n,a,l){if(n==null){if(l!=null){if(a!=null)throw Error(s(92));if(ee(l)){if(1<l.length)throw Error(s(93));l=l[0]}a=l}a==null&&(a=""),n=a}a=en(n),e.defaultValue=a,l=e.textContent,l===a&&l!==""&&l!==null&&(e.value=l)}function zr(e,n){if(n){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=n;return}}e.textContent=n}var X1=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 Mm(e,n,a){var l=n.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?l?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="":l?e.setProperty(n,a):typeof a!="number"||a===0||X1.has(n)?n==="float"?e.cssFloat=a:e[n]=(""+a).trim():e[n]=a+"px"}function zm(e,n,a){if(n!=null&&typeof n!="object")throw Error(s(62));if(e=e.style,a!=null){for(var l in a)!a.hasOwnProperty(l)||n!=null&&n.hasOwnProperty(l)||(l.indexOf("--")===0?e.setProperty(l,""):l==="float"?e.cssFloat="":e[l]="");for(var i in n)l=n[i],n.hasOwnProperty(i)&&a[i]!==l&&Mm(e,i,l)}else for(var d in n)n.hasOwnProperty(d)&&Mm(e,d,n[d])}function Nc(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 Q1=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"]]),K1=/^[\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 as(e){return K1.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Cc=null;function Rc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Lr=null,Ur=null;function Lm(e){var n=_r(e);if(n&&(e=n.stateNode)){var a=e[Ke]||null;e:switch(e=n.stateNode,n.type){case"input":if(Ec(e,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),n=a.name,a.type==="radio"&&n!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+tn(""+n)+'"][type="radio"]'),n=0;n<a.length;n++){var l=a[n];if(l!==e&&l.form===e.form){var i=l[Ke]||null;if(!i)throw Error(s(90));Ec(l,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(n=0;n<a.length;n++)l=a[n],l.form===e.form&&_m(l)}break e;case"textarea":Om(e,a.value,a.defaultValue);break e;case"select":n=a.value,n!=null&&Mr(e,!!a.multiple,n,!1)}}}var Ac=!1;function Um(e,n,a){if(Ac)return e(n,a);Ac=!0;try{var l=e(n);return l}finally{if(Ac=!1,(Lr!==null||Ur!==null)&&(qs(),Lr&&(n=Lr,e=Ur,Ur=Lr=null,Lm(n),e)))for(n=0;n<e.length;n++)Lm(e[n])}}function Lo(e,n){var a=e.stateNode;if(a===null)return null;var l=a[Ke]||null;if(l===null)return null;a=l[n];e:switch(n){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(s(231,n,typeof a));return a}var qn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),kc=!1;if(qn)try{var Uo={};Object.defineProperty(Uo,"passive",{get:function(){kc=!0}}),window.addEventListener("test",Uo,Uo),window.removeEventListener("test",Uo,Uo)}catch{kc=!1}var ma=null,_c=null,rs=null;function Bm(){if(rs)return rs;var e,n=_c,a=n.length,l,i="value"in ma?ma.value:ma.textContent,d=i.length;for(e=0;e<a&&n[e]===i[e];e++);var x=a-e;for(l=1;l<=x&&n[a-l]===i[d-l];l++);return rs=i.slice(e,1<l?1-l:void 0)}function os(e){var n=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&n===13&&(e=13)):e=n,e===10&&(e=13),32<=e||e===13?e:0}function ls(){return!0}function Hm(){return!1}function Lt(e){function n(a,l,i,d,x){this._reactName=a,this._targetInst=i,this.type=l,this.nativeEvent=d,this.target=x,this.currentTarget=null;for(var w in e)e.hasOwnProperty(w)&&(a=e[w],this[w]=a?a(d):d[w]);return this.isDefaultPrevented=(d.defaultPrevented!=null?d.defaultPrevented:d.returnValue===!1)?ls:Hm,this.isPropagationStopped=Hm,this}return b(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=ls)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=ls)},persist:function(){},isPersistent:ls}),n}var Ja={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ss=Lt(Ja),Bo=b({},Ja,{view:0,detail:0}),Z1=Lt(Bo),jc,Oc,Ho,is=b({},Bo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Mc,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!==Ho&&(Ho&&e.type==="mousemove"?(jc=e.screenX-Ho.screenX,Oc=e.screenY-Ho.screenY):Oc=jc=0,Ho=e),jc)},movementY:function(e){return"movementY"in e?e.movementY:Oc}}),Pm=Lt(is),F1=b({},is,{dataTransfer:0}),W1=Lt(F1),J1=b({},Bo,{relatedTarget:0}),Dc=Lt(J1),ew=b({},Ja,{animationName:0,elapsedTime:0,pseudoElement:0}),tw=Lt(ew),nw=b({},Ja,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),aw=Lt(nw),rw=b({},Ja,{data:0}),$m=Lt(rw),ow={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},lw={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"},sw={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function iw(e){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(e):(e=sw[e])?!!n[e]:!1}function Mc(){return iw}var cw=b({},Bo,{key:function(e){if(e.key){var n=ow[e.key]||e.key;if(n!=="Unidentified")return n}return e.type==="keypress"?(e=os(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?lw[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Mc,charCode:function(e){return e.type==="keypress"?os(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?os(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),uw=Lt(cw),dw=b({},is,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),qm=Lt(dw),fw=b({},Bo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Mc}),mw=Lt(fw),hw=b({},Ja,{propertyName:0,elapsedTime:0,pseudoElement:0}),pw=Lt(hw),gw=b({},is,{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}),vw=Lt(gw),yw=b({},Ja,{newState:0,oldState:0}),bw=Lt(yw),xw=[9,13,27,32],zc=qn&&"CompositionEvent"in window,Po=null;qn&&"documentMode"in document&&(Po=document.documentMode);var ww=qn&&"TextEvent"in window&&!Po,Vm=qn&&(!zc||Po&&8<Po&&11>=Po),Im=" ",Ym=!1;function Gm(e,n){switch(e){case"keyup":return xw.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Xm(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Br=!1;function Sw(e,n){switch(e){case"compositionend":return Xm(n);case"keypress":return n.which!==32?null:(Ym=!0,Im);case"textInput":return e=n.data,e===Im&&Ym?null:e;default:return null}}function Ew(e,n){if(Br)return e==="compositionend"||!zc&&Gm(e,n)?(e=Bm(),rs=_c=ma=null,Br=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return Vm&&n.locale!=="ko"?null:n.data;default:return null}}var Tw={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 Qm(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n==="input"?!!Tw[e.type]:n==="textarea"}function Km(e,n,a,l){Lr?Ur?Ur.push(l):Ur=[l]:Lr=l,n=Qs(n,"onChange"),0<n.length&&(a=new ss("onChange","change",null,a,l),e.push({event:a,listeners:n}))}var $o=null,qo=null;function Nw(e){kg(e,0)}function cs(e){var n=zo(e);if(_m(n))return e}function Zm(e,n){if(e==="change")return n}var Fm=!1;if(qn){var Lc;if(qn){var Uc="oninput"in document;if(!Uc){var Wm=document.createElement("div");Wm.setAttribute("oninput","return;"),Uc=typeof Wm.oninput=="function"}Lc=Uc}else Lc=!1;Fm=Lc&&(!document.documentMode||9<document.documentMode)}function Jm(){$o&&($o.detachEvent("onpropertychange",eh),qo=$o=null)}function eh(e){if(e.propertyName==="value"&&cs(qo)){var n=[];Km(n,qo,e,Rc(e)),Um(Nw,n)}}function Cw(e,n,a){e==="focusin"?(Jm(),$o=n,qo=a,$o.attachEvent("onpropertychange",eh)):e==="focusout"&&Jm()}function Rw(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return cs(qo)}function Aw(e,n){if(e==="click")return cs(n)}function kw(e,n){if(e==="input"||e==="change")return cs(n)}function _w(e,n){return e===n&&(e!==0||1/e===1/n)||e!==e&&n!==n}var qt=typeof Object.is=="function"?Object.is:_w;function Vo(e,n){if(qt(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;var a=Object.keys(e),l=Object.keys(n);if(a.length!==l.length)return!1;for(l=0;l<a.length;l++){var i=a[l];if(!Ae.call(n,i)||!qt(e[i],n[i]))return!1}return!0}function th(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function nh(e,n){var a=th(e);e=0;for(var l;a;){if(a.nodeType===3){if(l=e+a.textContent.length,e<=n&&l>=n)return{node:a,offset:n-e};e=l}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=th(a)}}function ah(e,n){return e&&n?e===n?!0:e&&e.nodeType===3?!1:n&&n.nodeType===3?ah(e,n.parentNode):"contains"in e?e.contains(n):e.compareDocumentPosition?!!(e.compareDocumentPosition(n)&16):!1:!1}function rh(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var n=ns(e.document);n instanceof e.HTMLIFrameElement;){try{var a=typeof n.contentWindow.location.href=="string"}catch{a=!1}if(a)e=n.contentWindow;else break;n=ns(e.document)}return n}function Bc(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n&&(n==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||n==="textarea"||e.contentEditable==="true")}var jw=qn&&"documentMode"in document&&11>=document.documentMode,Hr=null,Hc=null,Io=null,Pc=!1;function oh(e,n,a){var l=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;Pc||Hr==null||Hr!==ns(l)||(l=Hr,"selectionStart"in l&&Bc(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}),Io&&Vo(Io,l)||(Io=l,l=Qs(Hc,"onSelect"),0<l.length&&(n=new ss("onSelect","select",null,n,a),e.push({event:n,listeners:l}),n.target=Hr)))}function er(e,n){var a={};return a[e.toLowerCase()]=n.toLowerCase(),a["Webkit"+e]="webkit"+n,a["Moz"+e]="moz"+n,a}var Pr={animationend:er("Animation","AnimationEnd"),animationiteration:er("Animation","AnimationIteration"),animationstart:er("Animation","AnimationStart"),transitionrun:er("Transition","TransitionRun"),transitionstart:er("Transition","TransitionStart"),transitioncancel:er("Transition","TransitionCancel"),transitionend:er("Transition","TransitionEnd")},$c={},lh={};qn&&(lh=document.createElement("div").style,"AnimationEvent"in window||(delete Pr.animationend.animation,delete Pr.animationiteration.animation,delete Pr.animationstart.animation),"TransitionEvent"in window||delete Pr.transitionend.transition);function tr(e){if($c[e])return $c[e];if(!Pr[e])return e;var n=Pr[e],a;for(a in n)if(n.hasOwnProperty(a)&&a in lh)return $c[e]=n[a];return e}var sh=tr("animationend"),ih=tr("animationiteration"),ch=tr("animationstart"),Ow=tr("transitionrun"),Dw=tr("transitionstart"),Mw=tr("transitioncancel"),uh=tr("transitionend"),dh=new Map,qc="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(" ");qc.push("scrollEnd");function hn(e,n){dh.set(e,n),Wa(n,[e])}var fh=new WeakMap;function nn(e,n){if(typeof e=="object"&&e!==null){var a=fh.get(e);return a!==void 0?a:(n={value:e,source:n,stack:Am(n)},fh.set(e,n),n)}return{value:e,source:n,stack:Am(n)}}var an=[],$r=0,Vc=0;function us(){for(var e=$r,n=Vc=$r=0;n<e;){var a=an[n];an[n++]=null;var l=an[n];an[n++]=null;var i=an[n];an[n++]=null;var d=an[n];if(an[n++]=null,l!==null&&i!==null){var x=l.pending;x===null?i.next=i:(i.next=x.next,x.next=i),l.pending=i}d!==0&&mh(a,i,d)}}function ds(e,n,a,l){an[$r++]=e,an[$r++]=n,an[$r++]=a,an[$r++]=l,Vc|=l,e.lanes|=l,e=e.alternate,e!==null&&(e.lanes|=l)}function Ic(e,n,a,l){return ds(e,n,a,l),fs(e)}function qr(e,n){return ds(e,null,null,n),fs(e)}function mh(e,n,a){e.lanes|=a;var l=e.alternate;l!==null&&(l.lanes|=a);for(var i=!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||(i=!0)),e=d,d=d.return;return e.tag===3?(d=e.stateNode,i&&n!==null&&(i=31-We(a),e=d.hiddenUpdates,l=e[i],l===null?e[i]=[n]:l.push(n),n.lane=a|536870912),d):null}function fs(e){if(50<pl)throw pl=0,Zu=null,Error(s(185));for(var n=e.return;n!==null;)e=n,n=e.return;return e.tag===3?e.stateNode:null}var Vr={};function zw(e,n,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=n,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 Vt(e,n,a,l){return new zw(e,n,a,l)}function Yc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Vn(e,n){var a=e.alternate;return a===null?(a=Vt(e.tag,n,e.key,e.mode),a.elementType=e.elementType,a.type=e.type,a.stateNode=e.stateNode,a.alternate=e,e.alternate=a):(a.pendingProps=n,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,n=e.dependencies,a.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},a.sibling=e.sibling,a.index=e.index,a.ref=e.ref,a.refCleanup=e.refCleanup,a}function hh(e,n){e.flags&=65011714;var a=e.alternate;return a===null?(e.childLanes=0,e.lanes=n,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,n=a.dependencies,e.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),e}function ms(e,n,a,l,i,d){var x=0;if(l=e,typeof e=="function")Yc(e)&&(x=1);else if(typeof e=="string")x=US(e,a,le.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case re:return e=Vt(31,a,n,i),e.elementType=re,e.lanes=d,e;case C:return nr(a.children,i,d,n);case T:x=8,i|=24;break;case E:return e=Vt(12,a,n,i|2),e.elementType=E,e.lanes=d,e;case z:return e=Vt(13,a,n,i),e.elementType=z,e.lanes=d,e;case G:return e=Vt(19,a,n,i),e.elementType=G,e.lanes=d,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case R:case O:x=10;break e;case k:x=9;break e;case U:x=11;break e;case Y:x=14;break e;case q:x=16,l=null;break e}x=29,a=Error(s(130,e===null?"null":typeof e,"")),l=null}return n=Vt(x,a,n,i),n.elementType=e,n.type=l,n.lanes=d,n}function nr(e,n,a,l){return e=Vt(7,e,l,n),e.lanes=a,e}function Gc(e,n,a){return e=Vt(6,e,null,n),e.lanes=a,e}function Xc(e,n,a){return n=Vt(4,e.children!==null?e.children:[],e.key,n),n.lanes=a,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}var Ir=[],Yr=0,hs=null,ps=0,rn=[],on=0,ar=null,In=1,Yn="";function rr(e,n){Ir[Yr++]=ps,Ir[Yr++]=hs,hs=e,ps=n}function ph(e,n,a){rn[on++]=In,rn[on++]=Yn,rn[on++]=ar,ar=e;var l=In;e=Yn;var i=32-We(l)-1;l&=~(1<<i),a+=1;var d=32-We(n)+i;if(30<d){var x=i-i%5;d=(l&(1<<x)-1).toString(32),l>>=x,i-=x,In=1<<32-We(n)+i|a<<i|l,Yn=d+e}else In=1<<d|a<<i|l,Yn=e}function Qc(e){e.return!==null&&(rr(e,1),ph(e,1,0))}function Kc(e){for(;e===hs;)hs=Ir[--Yr],Ir[Yr]=null,ps=Ir[--Yr],Ir[Yr]=null;for(;e===ar;)ar=rn[--on],rn[on]=null,Yn=rn[--on],rn[on]=null,In=rn[--on],rn[on]=null}var Dt=null,rt=null,Pe=!1,or=null,Rn=!1,Zc=Error(s(519));function lr(e){var n=Error(s(418,""));throw Xo(nn(n,e)),Zc}function gh(e){var n=e.stateNode,a=e.type,l=e.memoizedProps;switch(n[ct]=e,n[Ke]=l,a){case"dialog":Me("cancel",n),Me("close",n);break;case"iframe":case"object":case"embed":Me("load",n);break;case"video":case"audio":for(a=0;a<vl.length;a++)Me(vl[a],n);break;case"source":Me("error",n);break;case"img":case"image":case"link":Me("error",n),Me("load",n);break;case"details":Me("toggle",n);break;case"input":Me("invalid",n),jm(n,l.value,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name,!0),ts(n);break;case"select":Me("invalid",n);break;case"textarea":Me("invalid",n),Dm(n,l.value,l.defaultValue,l.children),ts(n)}a=l.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||n.textContent===""+a||l.suppressHydrationWarning===!0||Dg(n.textContent,a)?(l.popover!=null&&(Me("beforetoggle",n),Me("toggle",n)),l.onScroll!=null&&Me("scroll",n),l.onScrollEnd!=null&&Me("scrollend",n),l.onClick!=null&&(n.onclick=Ks),n=!0):n=!1,n||lr(e)}function vh(e){for(Dt=e.return;Dt;)switch(Dt.tag){case 5:case 13:Rn=!1;return;case 27:case 3:Rn=!0;return;default:Dt=Dt.return}}function Yo(e){if(e!==Dt)return!1;if(!Pe)return vh(e),Pe=!0,!1;var n=e.tag,a;if((a=n!==3&&n!==27)&&((a=n===5)&&(a=e.type,a=!(a!=="form"&&a!=="button")||fd(e.type,e.memoizedProps)),a=!a),a&&rt&&lr(e),vh(e),n===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(s(317));e:{for(e=e.nextSibling,n=0;e;){if(e.nodeType===8)if(a=e.data,a==="/$"){if(n===0){rt=gn(e.nextSibling);break e}n--}else a!=="$"&&a!=="$!"&&a!=="$?"||n++;e=e.nextSibling}rt=null}}else n===27?(n=rt,ka(e.type)?(e=gd,gd=null,rt=e):rt=n):rt=Dt?gn(e.stateNode.nextSibling):null;return!0}function Go(){rt=Dt=null,Pe=!1}function yh(){var e=or;return e!==null&&(Ht===null?Ht=e:Ht.push.apply(Ht,e),or=null),e}function Xo(e){or===null?or=[e]:or.push(e)}var Fc=I(null),sr=null,Gn=null;function ha(e,n,a){Q(Fc,n._currentValue),n._currentValue=a}function Xn(e){e._currentValue=Fc.current,J(Fc)}function Wc(e,n,a){for(;e!==null;){var l=e.alternate;if((e.childLanes&n)!==n?(e.childLanes|=n,l!==null&&(l.childLanes|=n)):l!==null&&(l.childLanes&n)!==n&&(l.childLanes|=n),e===a)break;e=e.return}}function Jc(e,n,a,l){var i=e.child;for(i!==null&&(i.return=e);i!==null;){var d=i.dependencies;if(d!==null){var x=i.child;d=d.firstContext;e:for(;d!==null;){var w=d;d=i;for(var _=0;_<n.length;_++)if(w.context===n[_]){d.lanes|=a,w=d.alternate,w!==null&&(w.lanes|=a),Wc(d.return,a,e),l||(x=null);break e}d=w.next}}else if(i.tag===18){if(x=i.return,x===null)throw Error(s(341));x.lanes|=a,d=x.alternate,d!==null&&(d.lanes|=a),Wc(x,a,e),x=null}else x=i.child;if(x!==null)x.return=i;else for(x=i;x!==null;){if(x===e){x=null;break}if(i=x.sibling,i!==null){i.return=x.return,x=i;break}x=x.return}i=x}}function Qo(e,n,a,l){e=null;for(var i=n,d=!1;i!==null;){if(!d){if((i.flags&524288)!==0)d=!0;else if((i.flags&262144)!==0)break}if(i.tag===10){var x=i.alternate;if(x===null)throw Error(s(387));if(x=x.memoizedProps,x!==null){var w=i.type;qt(i.pendingProps.value,x.value)||(e!==null?e.push(w):e=[w])}}else if(i===ie.current){if(x=i.alternate,x===null)throw Error(s(387));x.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e!==null?e.push(El):e=[El])}i=i.return}e!==null&&Jc(n,e,a,l),n.flags|=262144}function gs(e){for(e=e.firstContext;e!==null;){if(!qt(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function ir(e){sr=e,Gn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function _t(e){return bh(sr,e)}function vs(e,n){return sr===null&&ir(e),bh(e,n)}function bh(e,n){var a=n._currentValue;if(n={context:n,memoizedValue:a,next:null},Gn===null){if(e===null)throw Error(s(308));Gn=n,e.dependencies={lanes:0,firstContext:n},e.flags|=524288}else Gn=Gn.next=n;return a}var Lw=typeof AbortController<"u"?AbortController:function(){var e=[],n=this.signal={aborted:!1,addEventListener:function(a,l){e.push(l)}};this.abort=function(){n.aborted=!0,e.forEach(function(a){return a()})}},Uw=t.unstable_scheduleCallback,Bw=t.unstable_NormalPriority,vt={$$typeof:O,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function eu(){return{controller:new Lw,data:new Map,refCount:0}}function Ko(e){e.refCount--,e.refCount===0&&Uw(Bw,function(){e.controller.abort()})}var Zo=null,tu=0,Gr=0,Xr=null;function Hw(e,n){if(Zo===null){var a=Zo=[];tu=0,Gr=ad(),Xr={status:"pending",value:void 0,then:function(l){a.push(l)}}}return tu++,n.then(xh,xh),n}function xh(){if(--tu===0&&Zo!==null){Xr!==null&&(Xr.status="fulfilled");var e=Zo;Zo=null,Gr=0,Xr=null;for(var n=0;n<e.length;n++)(0,e[n])()}}function Pw(e,n){var a=[],l={status:"pending",value:null,reason:null,then:function(i){a.push(i)}};return e.then(function(){l.status="fulfilled",l.value=n;for(var i=0;i<a.length;i++)(0,a[i])(n)},function(i){for(l.status="rejected",l.reason=i,i=0;i<a.length;i++)(0,a[i])(void 0)}),l}var wh=j.S;j.S=function(e,n){typeof n=="object"&&n!==null&&typeof n.then=="function"&&Hw(e,n),wh!==null&&wh(e,n)};var cr=I(null);function nu(){var e=cr.current;return e!==null?e:Ze.pooledCache}function ys(e,n){n===null?Q(cr,cr.current):Q(cr,n.pool)}function Sh(){var e=nu();return e===null?null:{parent:vt._currentValue,pool:e}}var Fo=Error(s(460)),Eh=Error(s(474)),bs=Error(s(542)),au={then:function(){}};function Th(e){return e=e.status,e==="fulfilled"||e==="rejected"}function xs(){}function Nh(e,n,a){switch(a=e[a],a===void 0?e.push(n):a!==n&&(n.then(xs,xs),n=a),n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,Rh(e),e;default:if(typeof n.status=="string")n.then(xs,xs);else{if(e=Ze,e!==null&&100<e.shellSuspendCounter)throw Error(s(482));e=n,e.status="pending",e.then(function(l){if(n.status==="pending"){var i=n;i.status="fulfilled",i.value=l}},function(l){if(n.status==="pending"){var i=n;i.status="rejected",i.reason=l}})}switch(n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,Rh(e),e}throw Wo=n,Fo}}var Wo=null;function Ch(){if(Wo===null)throw Error(s(459));var e=Wo;return Wo=null,e}function Rh(e){if(e===Fo||e===bs)throw Error(s(483))}var pa=!1;function ru(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function ou(e,n){e=e.updateQueue,n.updateQueue===e&&(n.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function ga(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function va(e,n,a){var l=e.updateQueue;if(l===null)return null;if(l=l.shared,($e&2)!==0){var i=l.pending;return i===null?n.next=n:(n.next=i.next,i.next=n),l.pending=n,n=fs(e),mh(e,null,a),n}return ds(e,l,n,a),fs(e)}function Jo(e,n,a){if(n=n.updateQueue,n!==null&&(n=n.shared,(a&4194048)!==0)){var l=n.lanes;l&=e.pendingLanes,a|=l,n.lanes=a,He(e,a)}}function lu(e,n){var a=e.updateQueue,l=e.alternate;if(l!==null&&(l=l.updateQueue,a===l)){var i=null,d=null;if(a=a.firstBaseUpdate,a!==null){do{var x={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};d===null?i=d=x:d=d.next=x,a=a.next}while(a!==null);d===null?i=d=n:d=d.next=n}else i=d=n;a={baseState:l.baseState,firstBaseUpdate:i,lastBaseUpdate:d,shared:l.shared,callbacks:l.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=n:e.next=n,a.lastBaseUpdate=n}var su=!1;function el(){if(su){var e=Xr;if(e!==null)throw e}}function tl(e,n,a,l){su=!1;var i=e.updateQueue;pa=!1;var d=i.firstBaseUpdate,x=i.lastBaseUpdate,w=i.shared.pending;if(w!==null){i.shared.pending=null;var _=w,B=_.next;_.next=null,x===null?d=B:x.next=B,x=_;var X=e.alternate;X!==null&&(X=X.updateQueue,w=X.lastBaseUpdate,w!==x&&(w===null?X.firstBaseUpdate=B:w.next=B,X.lastBaseUpdate=_))}if(d!==null){var Z=i.baseState;x=0,X=B=_=null,w=d;do{var $=w.lane&-536870913,V=$!==w.lane;if(V?(Ue&$)===$:(l&$)===$){$!==0&&$===Gr&&(su=!0),X!==null&&(X=X.next={lane:0,tag:w.tag,payload:w.payload,callback:null,next:null});e:{var Ee=e,we=w;$=n;var Ye=a;switch(we.tag){case 1:if(Ee=we.payload,typeof Ee=="function"){Z=Ee.call(Ye,Z,$);break e}Z=Ee;break e;case 3:Ee.flags=Ee.flags&-65537|128;case 0:if(Ee=we.payload,$=typeof Ee=="function"?Ee.call(Ye,Z,$):Ee,$==null)break e;Z=b({},Z,$);break e;case 2:pa=!0}}$=w.callback,$!==null&&(e.flags|=64,V&&(e.flags|=8192),V=i.callbacks,V===null?i.callbacks=[$]:V.push($))}else V={lane:$,tag:w.tag,payload:w.payload,callback:w.callback,next:null},X===null?(B=X=V,_=Z):X=X.next=V,x|=$;if(w=w.next,w===null){if(w=i.shared.pending,w===null)break;V=w,w=V.next,V.next=null,i.lastBaseUpdate=V,i.shared.pending=null}}while(!0);X===null&&(_=Z),i.baseState=_,i.firstBaseUpdate=B,i.lastBaseUpdate=X,d===null&&(i.shared.lanes=0),Na|=x,e.lanes=x,e.memoizedState=Z}}function Ah(e,n){if(typeof e!="function")throw Error(s(191,e));e.call(n)}function kh(e,n){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;e<a.length;e++)Ah(a[e],n)}var Qr=I(null),ws=I(0);function _h(e,n){e=ea,Q(ws,e),Q(Qr,n),ea=e|n.baseLanes}function iu(){Q(ws,ea),Q(Qr,Qr.current)}function cu(){ea=ws.current,J(Qr),J(ws)}var ya=0,ke=null,Ve=null,ft=null,Ss=!1,Kr=!1,ur=!1,Es=0,nl=0,Zr=null,$w=0;function ut(){throw Error(s(321))}function uu(e,n){if(n===null)return!1;for(var a=0;a<n.length&&a<e.length;a++)if(!qt(e[a],n[a]))return!1;return!0}function du(e,n,a,l,i,d){return ya=d,ke=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,j.H=e===null||e.memoizedState===null?mp:hp,ur=!1,d=a(l,i),ur=!1,Kr&&(d=Oh(n,a,l,i)),jh(e),d}function jh(e){j.H=ks;var n=Ve!==null&&Ve.next!==null;if(ya=0,ft=Ve=ke=null,Ss=!1,nl=0,Zr=null,n)throw Error(s(300));e===null||St||(e=e.dependencies,e!==null&&gs(e)&&(St=!0))}function Oh(e,n,a,l){ke=e;var i=0;do{if(Kr&&(Zr=null),nl=0,Kr=!1,25<=i)throw Error(s(301));if(i+=1,ft=Ve=null,e.updateQueue!=null){var d=e.updateQueue;d.lastEffect=null,d.events=null,d.stores=null,d.memoCache!=null&&(d.memoCache.index=0)}j.H=Qw,d=n(a,l)}while(Kr);return d}function qw(){var e=j.H,n=e.useState()[0];return n=typeof n.then=="function"?al(n):n,e=e.useState()[0],(Ve!==null?Ve.memoizedState:null)!==e&&(ke.flags|=1024),n}function fu(){var e=Es!==0;return Es=0,e}function mu(e,n,a){n.updateQueue=e.updateQueue,n.flags&=-2053,e.lanes&=~a}function hu(e){if(Ss){for(e=e.memoizedState;e!==null;){var n=e.queue;n!==null&&(n.pending=null),e=e.next}Ss=!1}ya=0,ft=Ve=ke=null,Kr=!1,nl=Es=0,Zr=null}function Ut(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ft===null?ke.memoizedState=ft=e:ft=ft.next=e,ft}function mt(){if(Ve===null){var e=ke.alternate;e=e!==null?e.memoizedState:null}else e=Ve.next;var n=ft===null?ke.memoizedState:ft.next;if(n!==null)ft=n,Ve=e;else{if(e===null)throw ke.alternate===null?Error(s(467)):Error(s(310));Ve=e,e={memoizedState:Ve.memoizedState,baseState:Ve.baseState,baseQueue:Ve.baseQueue,queue:Ve.queue,next:null},ft===null?ke.memoizedState=ft=e:ft=ft.next=e}return ft}function pu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function al(e){var n=nl;return nl+=1,Zr===null&&(Zr=[]),e=Nh(Zr,e,n),n=ke,(ft===null?n.memoizedState:ft.next)===null&&(n=n.alternate,j.H=n===null||n.memoizedState===null?mp:hp),e}function Ts(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return al(e);if(e.$$typeof===O)return _t(e)}throw Error(s(438,String(e)))}function gu(e){var n=null,a=ke.updateQueue;if(a!==null&&(n=a.memoCache),n==null){var l=ke.alternate;l!==null&&(l=l.updateQueue,l!==null&&(l=l.memoCache,l!=null&&(n={data:l.data.map(function(i){return i.slice()}),index:0})))}if(n==null&&(n={data:[],index:0}),a===null&&(a=pu(),ke.updateQueue=a),a.memoCache=n,a=n.data[n.index],a===void 0)for(a=n.data[n.index]=Array(e),l=0;l<e;l++)a[l]=fe;return n.index++,a}function Qn(e,n){return typeof n=="function"?n(e):n}function Ns(e){var n=mt();return vu(n,Ve,e)}function vu(e,n,a){var l=e.queue;if(l===null)throw Error(s(311));l.lastRenderedReducer=a;var i=e.baseQueue,d=l.pending;if(d!==null){if(i!==null){var x=i.next;i.next=d.next,d.next=x}n.baseQueue=i=d,l.pending=null}if(d=e.baseState,i===null)e.memoizedState=d;else{n=i.next;var w=x=null,_=null,B=n,X=!1;do{var Z=B.lane&-536870913;if(Z!==B.lane?(Ue&Z)===Z:(ya&Z)===Z){var $=B.revertLane;if($===0)_!==null&&(_=_.next={lane:0,revertLane:0,action:B.action,hasEagerState:B.hasEagerState,eagerState:B.eagerState,next:null}),Z===Gr&&(X=!0);else if((ya&$)===$){B=B.next,$===Gr&&(X=!0);continue}else Z={lane:0,revertLane:B.revertLane,action:B.action,hasEagerState:B.hasEagerState,eagerState:B.eagerState,next:null},_===null?(w=_=Z,x=d):_=_.next=Z,ke.lanes|=$,Na|=$;Z=B.action,ur&&a(d,Z),d=B.hasEagerState?B.eagerState:a(d,Z)}else $={lane:Z,revertLane:B.revertLane,action:B.action,hasEagerState:B.hasEagerState,eagerState:B.eagerState,next:null},_===null?(w=_=$,x=d):_=_.next=$,ke.lanes|=Z,Na|=Z;B=B.next}while(B!==null&&B!==n);if(_===null?x=d:_.next=w,!qt(d,e.memoizedState)&&(St=!0,X&&(a=Xr,a!==null)))throw a;e.memoizedState=d,e.baseState=x,e.baseQueue=_,l.lastRenderedState=d}return i===null&&(l.lanes=0),[e.memoizedState,l.dispatch]}function yu(e){var n=mt(),a=n.queue;if(a===null)throw Error(s(311));a.lastRenderedReducer=e;var l=a.dispatch,i=a.pending,d=n.memoizedState;if(i!==null){a.pending=null;var x=i=i.next;do d=e(d,x.action),x=x.next;while(x!==i);qt(d,n.memoizedState)||(St=!0),n.memoizedState=d,n.baseQueue===null&&(n.baseState=d),a.lastRenderedState=d}return[d,l]}function Dh(e,n,a){var l=ke,i=mt(),d=Pe;if(d){if(a===void 0)throw Error(s(407));a=a()}else a=n();var x=!qt((Ve||i).memoizedState,a);x&&(i.memoizedState=a,St=!0),i=i.queue;var w=Lh.bind(null,l,i,e);if(rl(2048,8,w,[e]),i.getSnapshot!==n||x||ft!==null&&ft.memoizedState.tag&1){if(l.flags|=2048,Fr(9,Cs(),zh.bind(null,l,i,a,n),null),Ze===null)throw Error(s(349));d||(ya&124)!==0||Mh(l,n,a)}return a}function Mh(e,n,a){e.flags|=16384,e={getSnapshot:n,value:a},n=ke.updateQueue,n===null?(n=pu(),ke.updateQueue=n,n.stores=[e]):(a=n.stores,a===null?n.stores=[e]:a.push(e))}function zh(e,n,a,l){n.value=a,n.getSnapshot=l,Uh(n)&&Bh(e)}function Lh(e,n,a){return a(function(){Uh(n)&&Bh(e)})}function Uh(e){var n=e.getSnapshot;e=e.value;try{var a=n();return!qt(e,a)}catch{return!0}}function Bh(e){var n=qr(e,2);n!==null&&Qt(n,e,2)}function bu(e){var n=Ut();if(typeof e=="function"){var a=e;if(e=a(),ur){Mt(!0);try{a()}finally{Mt(!1)}}}return n.memoizedState=n.baseState=e,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Qn,lastRenderedState:e},n}function Hh(e,n,a,l){return e.baseState=a,vu(e,Ve,typeof l=="function"?l:Qn)}function Vw(e,n,a,l,i){if(As(e))throw Error(s(485));if(e=n.action,e!==null){var d={payload:i,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(x){d.listeners.push(x)}};j.T!==null?a(!0):d.isTransition=!1,l(d),a=n.pending,a===null?(d.next=n.pending=d,Ph(n,d)):(d.next=a.next,n.pending=a.next=d)}}function Ph(e,n){var a=n.action,l=n.payload,i=e.state;if(n.isTransition){var d=j.T,x={};j.T=x;try{var w=a(i,l),_=j.S;_!==null&&_(x,w),$h(e,n,w)}catch(B){xu(e,n,B)}finally{j.T=d}}else try{d=a(i,l),$h(e,n,d)}catch(B){xu(e,n,B)}}function $h(e,n,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(l){qh(e,n,l)},function(l){return xu(e,n,l)}):qh(e,n,a)}function qh(e,n,a){n.status="fulfilled",n.value=a,Vh(n),e.state=a,n=e.pending,n!==null&&(a=n.next,a===n?e.pending=null:(a=a.next,n.next=a,Ph(e,a)))}function xu(e,n,a){var l=e.pending;if(e.pending=null,l!==null){l=l.next;do n.status="rejected",n.reason=a,Vh(n),n=n.next;while(n!==l)}e.action=null}function Vh(e){e=e.listeners;for(var n=0;n<e.length;n++)(0,e[n])()}function Ih(e,n){return n}function Yh(e,n){if(Pe){var a=Ze.formState;if(a!==null){e:{var l=ke;if(Pe){if(rt){t:{for(var i=rt,d=Rn;i.nodeType!==8;){if(!d){i=null;break t}if(i=gn(i.nextSibling),i===null){i=null;break t}}d=i.data,i=d==="F!"||d==="F"?i:null}if(i){rt=gn(i.nextSibling),l=i.data==="F!";break e}}lr(l)}l=!1}l&&(n=a[0])}}return a=Ut(),a.memoizedState=a.baseState=n,l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ih,lastRenderedState:n},a.queue=l,a=up.bind(null,ke,l),l.dispatch=a,l=bu(!1),d=Nu.bind(null,ke,!1,l.queue),l=Ut(),i={state:n,dispatch:null,action:e,pending:null},l.queue=i,a=Vw.bind(null,ke,i,d,a),i.dispatch=a,l.memoizedState=e,[n,a,!1]}function Gh(e){var n=mt();return Xh(n,Ve,e)}function Xh(e,n,a){if(n=vu(e,n,Ih)[0],e=Ns(Qn)[0],typeof n=="object"&&n!==null&&typeof n.then=="function")try{var l=al(n)}catch(x){throw x===Fo?bs:x}else l=n;n=mt();var i=n.queue,d=i.dispatch;return a!==n.memoizedState&&(ke.flags|=2048,Fr(9,Cs(),Iw.bind(null,i,a),null)),[l,d,e]}function Iw(e,n){e.action=n}function Qh(e){var n=mt(),a=Ve;if(a!==null)return Xh(n,a,e);mt(),n=n.memoizedState,a=mt();var l=a.queue.dispatch;return a.memoizedState=e,[n,l,!1]}function Fr(e,n,a,l){return e={tag:e,create:a,deps:l,inst:n,next:null},n=ke.updateQueue,n===null&&(n=pu(),ke.updateQueue=n),a=n.lastEffect,a===null?n.lastEffect=e.next=e:(l=a.next,a.next=e,e.next=l,n.lastEffect=e),e}function Cs(){return{destroy:void 0,resource:void 0}}function Kh(){return mt().memoizedState}function Rs(e,n,a,l){var i=Ut();l=l===void 0?null:l,ke.flags|=e,i.memoizedState=Fr(1|n,Cs(),a,l)}function rl(e,n,a,l){var i=mt();l=l===void 0?null:l;var d=i.memoizedState.inst;Ve!==null&&l!==null&&uu(l,Ve.memoizedState.deps)?i.memoizedState=Fr(n,d,a,l):(ke.flags|=e,i.memoizedState=Fr(1|n,d,a,l))}function Zh(e,n){Rs(8390656,8,e,n)}function Fh(e,n){rl(2048,8,e,n)}function Wh(e,n){return rl(4,2,e,n)}function Jh(e,n){return rl(4,4,e,n)}function ep(e,n){if(typeof n=="function"){e=e();var a=n(e);return function(){typeof a=="function"?a():n(null)}}if(n!=null)return e=e(),n.current=e,function(){n.current=null}}function tp(e,n,a){a=a!=null?a.concat([e]):null,rl(4,4,ep.bind(null,n,e),a)}function wu(){}function np(e,n){var a=mt();n=n===void 0?null:n;var l=a.memoizedState;return n!==null&&uu(n,l[1])?l[0]:(a.memoizedState=[e,n],e)}function ap(e,n){var a=mt();n=n===void 0?null:n;var l=a.memoizedState;if(n!==null&&uu(n,l[1]))return l[0];if(l=e(),ur){Mt(!0);try{e()}finally{Mt(!1)}}return a.memoizedState=[l,n],l}function Su(e,n,a){return a===void 0||(ya&1073741824)!==0?e.memoizedState=n:(e.memoizedState=a,e=lg(),ke.lanes|=e,Na|=e,a)}function rp(e,n,a,l){return qt(a,n)?a:Qr.current!==null?(e=Su(e,a,l),qt(e,n)||(St=!0),e):(ya&42)===0?(St=!0,e.memoizedState=a):(e=lg(),ke.lanes|=e,Na|=e,n)}function op(e,n,a,l,i){var d=P.p;P.p=d!==0&&8>d?d:8;var x=j.T,w={};j.T=w,Nu(e,!1,n,a);try{var _=i(),B=j.S;if(B!==null&&B(w,_),_!==null&&typeof _=="object"&&typeof _.then=="function"){var X=Pw(_,l);ol(e,n,X,Xt(e))}else ol(e,n,l,Xt(e))}catch(Z){ol(e,n,{then:function(){},status:"rejected",reason:Z},Xt())}finally{P.p=d,j.T=x}}function Yw(){}function Eu(e,n,a,l){if(e.tag!==5)throw Error(s(476));var i=lp(e).queue;op(e,i,n,H,a===null?Yw:function(){return sp(e),a(l)})}function lp(e){var n=e.memoizedState;if(n!==null)return n;n={memoizedState:H,baseState:H,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Qn,lastRenderedState:H},next:null};var a={};return n.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Qn,lastRenderedState:a},next:null},e.memoizedState=n,e=e.alternate,e!==null&&(e.memoizedState=n),n}function sp(e){var n=lp(e).next.queue;ol(e,n,{},Xt())}function Tu(){return _t(El)}function ip(){return mt().memoizedState}function cp(){return mt().memoizedState}function Gw(e){for(var n=e.return;n!==null;){switch(n.tag){case 24:case 3:var a=Xt();e=ga(a);var l=va(n,e,a);l!==null&&(Qt(l,n,a),Jo(l,n,a)),n={cache:eu()},e.payload=n;return}n=n.return}}function Xw(e,n,a){var l=Xt();a={lane:l,revertLane:0,action:a,hasEagerState:!1,eagerState:null,next:null},As(e)?dp(n,a):(a=Ic(e,n,a,l),a!==null&&(Qt(a,e,l),fp(a,n,l)))}function up(e,n,a){var l=Xt();ol(e,n,a,l)}function ol(e,n,a,l){var i={lane:l,revertLane:0,action:a,hasEagerState:!1,eagerState:null,next:null};if(As(e))dp(n,i);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=n.lastRenderedReducer,d!==null))try{var x=n.lastRenderedState,w=d(x,a);if(i.hasEagerState=!0,i.eagerState=w,qt(w,x))return ds(e,n,i,0),Ze===null&&us(),!1}catch{}if(a=Ic(e,n,i,l),a!==null)return Qt(a,e,l),fp(a,n,l),!0}return!1}function Nu(e,n,a,l){if(l={lane:2,revertLane:ad(),action:l,hasEagerState:!1,eagerState:null,next:null},As(e)){if(n)throw Error(s(479))}else n=Ic(e,a,l,2),n!==null&&Qt(n,e,2)}function As(e){var n=e.alternate;return e===ke||n!==null&&n===ke}function dp(e,n){Kr=Ss=!0;var a=e.pending;a===null?n.next=n:(n.next=a.next,a.next=n),e.pending=n}function fp(e,n,a){if((a&4194048)!==0){var l=n.lanes;l&=e.pendingLanes,a|=l,n.lanes=a,He(e,a)}}var ks={readContext:_t,use:Ts,useCallback:ut,useContext:ut,useEffect:ut,useImperativeHandle:ut,useLayoutEffect:ut,useInsertionEffect:ut,useMemo:ut,useReducer:ut,useRef:ut,useState:ut,useDebugValue:ut,useDeferredValue:ut,useTransition:ut,useSyncExternalStore:ut,useId:ut,useHostTransitionStatus:ut,useFormState:ut,useActionState:ut,useOptimistic:ut,useMemoCache:ut,useCacheRefresh:ut},mp={readContext:_t,use:Ts,useCallback:function(e,n){return Ut().memoizedState=[e,n===void 0?null:n],e},useContext:_t,useEffect:Zh,useImperativeHandle:function(e,n,a){a=a!=null?a.concat([e]):null,Rs(4194308,4,ep.bind(null,n,e),a)},useLayoutEffect:function(e,n){return Rs(4194308,4,e,n)},useInsertionEffect:function(e,n){Rs(4,2,e,n)},useMemo:function(e,n){var a=Ut();n=n===void 0?null:n;var l=e();if(ur){Mt(!0);try{e()}finally{Mt(!1)}}return a.memoizedState=[l,n],l},useReducer:function(e,n,a){var l=Ut();if(a!==void 0){var i=a(n);if(ur){Mt(!0);try{a(n)}finally{Mt(!1)}}}else i=n;return l.memoizedState=l.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},l.queue=e,e=e.dispatch=Xw.bind(null,ke,e),[l.memoizedState,e]},useRef:function(e){var n=Ut();return e={current:e},n.memoizedState=e},useState:function(e){e=bu(e);var n=e.queue,a=up.bind(null,ke,n);return n.dispatch=a,[e.memoizedState,a]},useDebugValue:wu,useDeferredValue:function(e,n){var a=Ut();return Su(a,e,n)},useTransition:function(){var e=bu(!1);return e=op.bind(null,ke,e.queue,!0,!1),Ut().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,n,a){var l=ke,i=Ut();if(Pe){if(a===void 0)throw Error(s(407));a=a()}else{if(a=n(),Ze===null)throw Error(s(349));(Ue&124)!==0||Mh(l,n,a)}i.memoizedState=a;var d={value:a,getSnapshot:n};return i.queue=d,Zh(Lh.bind(null,l,d,e),[e]),l.flags|=2048,Fr(9,Cs(),zh.bind(null,l,d,a,n),null),a},useId:function(){var e=Ut(),n=Ze.identifierPrefix;if(Pe){var a=Yn,l=In;a=(l&~(1<<32-We(l)-1)).toString(32)+a,n="«"+n+"R"+a,a=Es++,0<a&&(n+="H"+a.toString(32)),n+="»"}else a=$w++,n="«"+n+"r"+a.toString(32)+"»";return e.memoizedState=n},useHostTransitionStatus:Tu,useFormState:Yh,useActionState:Yh,useOptimistic:function(e){var n=Ut();n.memoizedState=n.baseState=e;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=a,n=Nu.bind(null,ke,!0,a),a.dispatch=n,[e,n]},useMemoCache:gu,useCacheRefresh:function(){return Ut().memoizedState=Gw.bind(null,ke)}},hp={readContext:_t,use:Ts,useCallback:np,useContext:_t,useEffect:Fh,useImperativeHandle:tp,useInsertionEffect:Wh,useLayoutEffect:Jh,useMemo:ap,useReducer:Ns,useRef:Kh,useState:function(){return Ns(Qn)},useDebugValue:wu,useDeferredValue:function(e,n){var a=mt();return rp(a,Ve.memoizedState,e,n)},useTransition:function(){var e=Ns(Qn)[0],n=mt().memoizedState;return[typeof e=="boolean"?e:al(e),n]},useSyncExternalStore:Dh,useId:ip,useHostTransitionStatus:Tu,useFormState:Gh,useActionState:Gh,useOptimistic:function(e,n){var a=mt();return Hh(a,Ve,e,n)},useMemoCache:gu,useCacheRefresh:cp},Qw={readContext:_t,use:Ts,useCallback:np,useContext:_t,useEffect:Fh,useImperativeHandle:tp,useInsertionEffect:Wh,useLayoutEffect:Jh,useMemo:ap,useReducer:yu,useRef:Kh,useState:function(){return yu(Qn)},useDebugValue:wu,useDeferredValue:function(e,n){var a=mt();return Ve===null?Su(a,e,n):rp(a,Ve.memoizedState,e,n)},useTransition:function(){var e=yu(Qn)[0],n=mt().memoizedState;return[typeof e=="boolean"?e:al(e),n]},useSyncExternalStore:Dh,useId:ip,useHostTransitionStatus:Tu,useFormState:Qh,useActionState:Qh,useOptimistic:function(e,n){var a=mt();return Ve!==null?Hh(a,Ve,e,n):(a.baseState=e,[e,a.queue.dispatch])},useMemoCache:gu,useCacheRefresh:cp},Wr=null,ll=0;function _s(e){var n=ll;return ll+=1,Wr===null&&(Wr=[]),Nh(Wr,e,n)}function sl(e,n){n=n.props.ref,e.ref=n!==void 0?n:null}function js(e,n){throw n.$$typeof===y?Error(s(525)):(e=Object.prototype.toString.call(n),Error(s(31,e==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":e)))}function pp(e){var n=e._init;return n(e._payload)}function gp(e){function n(M,D){if(e){var L=M.deletions;L===null?(M.deletions=[D],M.flags|=16):L.push(D)}}function a(M,D){if(!e)return null;for(;D!==null;)n(M,D),D=D.sibling;return null}function l(M){for(var D=new Map;M!==null;)M.key!==null?D.set(M.key,M):D.set(M.index,M),M=M.sibling;return D}function i(M,D){return M=Vn(M,D),M.index=0,M.sibling=null,M}function d(M,D,L){return M.index=L,e?(L=M.alternate,L!==null?(L=L.index,L<D?(M.flags|=67108866,D):L):(M.flags|=67108866,D)):(M.flags|=1048576,D)}function x(M){return e&&M.alternate===null&&(M.flags|=67108866),M}function w(M,D,L,K){return D===null||D.tag!==6?(D=Gc(L,M.mode,K),D.return=M,D):(D=i(D,L),D.return=M,D)}function _(M,D,L,K){var he=L.type;return he===C?X(M,D,L.props.children,K,L.key):D!==null&&(D.elementType===he||typeof he=="object"&&he!==null&&he.$$typeof===q&&pp(he)===D.type)?(D=i(D,L.props),sl(D,L),D.return=M,D):(D=ms(L.type,L.key,L.props,null,M.mode,K),sl(D,L),D.return=M,D)}function B(M,D,L,K){return D===null||D.tag!==4||D.stateNode.containerInfo!==L.containerInfo||D.stateNode.implementation!==L.implementation?(D=Xc(L,M.mode,K),D.return=M,D):(D=i(D,L.children||[]),D.return=M,D)}function X(M,D,L,K,he){return D===null||D.tag!==7?(D=nr(L,M.mode,K,he),D.return=M,D):(D=i(D,L),D.return=M,D)}function Z(M,D,L){if(typeof D=="string"&&D!==""||typeof D=="number"||typeof D=="bigint")return D=Gc(""+D,M.mode,L),D.return=M,D;if(typeof D=="object"&&D!==null){switch(D.$$typeof){case S:return L=ms(D.type,D.key,D.props,null,M.mode,L),sl(L,D),L.return=M,L;case A:return D=Xc(D,M.mode,L),D.return=M,D;case q:var K=D._init;return D=K(D._payload),Z(M,D,L)}if(ee(D)||de(D))return D=nr(D,M.mode,L,null),D.return=M,D;if(typeof D.then=="function")return Z(M,_s(D),L);if(D.$$typeof===O)return Z(M,vs(M,D),L);js(M,D)}return null}function $(M,D,L,K){var he=D!==null?D.key:null;if(typeof L=="string"&&L!==""||typeof L=="number"||typeof L=="bigint")return he!==null?null:w(M,D,""+L,K);if(typeof L=="object"&&L!==null){switch(L.$$typeof){case S:return L.key===he?_(M,D,L,K):null;case A:return L.key===he?B(M,D,L,K):null;case q:return he=L._init,L=he(L._payload),$(M,D,L,K)}if(ee(L)||de(L))return he!==null?null:X(M,D,L,K,null);if(typeof L.then=="function")return $(M,D,_s(L),K);if(L.$$typeof===O)return $(M,D,vs(M,L),K);js(M,L)}return null}function V(M,D,L,K,he){if(typeof K=="string"&&K!==""||typeof K=="number"||typeof K=="bigint")return M=M.get(L)||null,w(D,M,""+K,he);if(typeof K=="object"&&K!==null){switch(K.$$typeof){case S:return M=M.get(K.key===null?L:K.key)||null,_(D,M,K,he);case A:return M=M.get(K.key===null?L:K.key)||null,B(D,M,K,he);case q:var je=K._init;return K=je(K._payload),V(M,D,L,K,he)}if(ee(K)||de(K))return M=M.get(L)||null,X(D,M,K,he,null);if(typeof K.then=="function")return V(M,D,L,_s(K),he);if(K.$$typeof===O)return V(M,D,L,vs(D,K),he);js(D,K)}return null}function Ee(M,D,L,K){for(var he=null,je=null,ye=D,Se=D=0,Tt=null;ye!==null&&Se<L.length;Se++){ye.index>Se?(Tt=ye,ye=null):Tt=ye.sibling;var Be=$(M,ye,L[Se],K);if(Be===null){ye===null&&(ye=Tt);break}e&&ye&&Be.alternate===null&&n(M,ye),D=d(Be,D,Se),je===null?he=Be:je.sibling=Be,je=Be,ye=Tt}if(Se===L.length)return a(M,ye),Pe&&rr(M,Se),he;if(ye===null){for(;Se<L.length;Se++)ye=Z(M,L[Se],K),ye!==null&&(D=d(ye,D,Se),je===null?he=ye:je.sibling=ye,je=ye);return Pe&&rr(M,Se),he}for(ye=l(ye);Se<L.length;Se++)Tt=V(ye,M,Se,L[Se],K),Tt!==null&&(e&&Tt.alternate!==null&&ye.delete(Tt.key===null?Se:Tt.key),D=d(Tt,D,Se),je===null?he=Tt:je.sibling=Tt,je=Tt);return e&&ye.forEach(function(Ma){return n(M,Ma)}),Pe&&rr(M,Se),he}function we(M,D,L,K){if(L==null)throw Error(s(151));for(var he=null,je=null,ye=D,Se=D=0,Tt=null,Be=L.next();ye!==null&&!Be.done;Se++,Be=L.next()){ye.index>Se?(Tt=ye,ye=null):Tt=ye.sibling;var Ma=$(M,ye,Be.value,K);if(Ma===null){ye===null&&(ye=Tt);break}e&&ye&&Ma.alternate===null&&n(M,ye),D=d(Ma,D,Se),je===null?he=Ma:je.sibling=Ma,je=Ma,ye=Tt}if(Be.done)return a(M,ye),Pe&&rr(M,Se),he;if(ye===null){for(;!Be.done;Se++,Be=L.next())Be=Z(M,Be.value,K),Be!==null&&(D=d(Be,D,Se),je===null?he=Be:je.sibling=Be,je=Be);return Pe&&rr(M,Se),he}for(ye=l(ye);!Be.done;Se++,Be=L.next())Be=V(ye,M,Se,Be.value,K),Be!==null&&(e&&Be.alternate!==null&&ye.delete(Be.key===null?Se:Be.key),D=d(Be,D,Se),je===null?he=Be:je.sibling=Be,je=Be);return e&&ye.forEach(function(KS){return n(M,KS)}),Pe&&rr(M,Se),he}function Ye(M,D,L,K){if(typeof L=="object"&&L!==null&&L.type===C&&L.key===null&&(L=L.props.children),typeof L=="object"&&L!==null){switch(L.$$typeof){case S:e:{for(var he=L.key;D!==null;){if(D.key===he){if(he=L.type,he===C){if(D.tag===7){a(M,D.sibling),K=i(D,L.props.children),K.return=M,M=K;break e}}else if(D.elementType===he||typeof he=="object"&&he!==null&&he.$$typeof===q&&pp(he)===D.type){a(M,D.sibling),K=i(D,L.props),sl(K,L),K.return=M,M=K;break e}a(M,D);break}else n(M,D);D=D.sibling}L.type===C?(K=nr(L.props.children,M.mode,K,L.key),K.return=M,M=K):(K=ms(L.type,L.key,L.props,null,M.mode,K),sl(K,L),K.return=M,M=K)}return x(M);case A:e:{for(he=L.key;D!==null;){if(D.key===he)if(D.tag===4&&D.stateNode.containerInfo===L.containerInfo&&D.stateNode.implementation===L.implementation){a(M,D.sibling),K=i(D,L.children||[]),K.return=M,M=K;break e}else{a(M,D);break}else n(M,D);D=D.sibling}K=Xc(L,M.mode,K),K.return=M,M=K}return x(M);case q:return he=L._init,L=he(L._payload),Ye(M,D,L,K)}if(ee(L))return Ee(M,D,L,K);if(de(L)){if(he=de(L),typeof he!="function")throw Error(s(150));return L=he.call(L),we(M,D,L,K)}if(typeof L.then=="function")return Ye(M,D,_s(L),K);if(L.$$typeof===O)return Ye(M,D,vs(M,L),K);js(M,L)}return typeof L=="string"&&L!==""||typeof L=="number"||typeof L=="bigint"?(L=""+L,D!==null&&D.tag===6?(a(M,D.sibling),K=i(D,L),K.return=M,M=K):(a(M,D),K=Gc(L,M.mode,K),K.return=M,M=K),x(M)):a(M,D)}return function(M,D,L,K){try{ll=0;var he=Ye(M,D,L,K);return Wr=null,he}catch(ye){if(ye===Fo||ye===bs)throw ye;var je=Vt(29,ye,null,M.mode);return je.lanes=K,je.return=M,je}}}var Jr=gp(!0),vp=gp(!1),ln=I(null),An=null;function ba(e){var n=e.alternate;Q(yt,yt.current&1),Q(ln,e),An===null&&(n===null||Qr.current!==null||n.memoizedState!==null)&&(An=e)}function yp(e){if(e.tag===22){if(Q(yt,yt.current),Q(ln,e),An===null){var n=e.alternate;n!==null&&n.memoizedState!==null&&(An=e)}}else xa()}function xa(){Q(yt,yt.current),Q(ln,ln.current)}function Kn(e){J(ln),An===e&&(An=null),J(yt)}var yt=I(0);function Os(e){for(var n=e;n!==null;){if(n.tag===13){var a=n.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||a.data==="$?"||pd(a)))return n}else if(n.tag===19&&n.memoizedProps.revealOrder!==void 0){if((n.flags&128)!==0)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}function Cu(e,n,a,l){n=e.memoizedState,a=a(l,n),a=a==null?n:b({},n,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var Ru={enqueueSetState:function(e,n,a){e=e._reactInternals;var l=Xt(),i=ga(l);i.payload=n,a!=null&&(i.callback=a),n=va(e,i,l),n!==null&&(Qt(n,e,l),Jo(n,e,l))},enqueueReplaceState:function(e,n,a){e=e._reactInternals;var l=Xt(),i=ga(l);i.tag=1,i.payload=n,a!=null&&(i.callback=a),n=va(e,i,l),n!==null&&(Qt(n,e,l),Jo(n,e,l))},enqueueForceUpdate:function(e,n){e=e._reactInternals;var a=Xt(),l=ga(a);l.tag=2,n!=null&&(l.callback=n),n=va(e,l,a),n!==null&&(Qt(n,e,a),Jo(n,e,a))}};function bp(e,n,a,l,i,d,x){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(l,d,x):n.prototype&&n.prototype.isPureReactComponent?!Vo(a,l)||!Vo(i,d):!0}function xp(e,n,a,l){e=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(a,l),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(a,l),n.state!==e&&Ru.enqueueReplaceState(n,n.state,null)}function dr(e,n){var a=n;if("ref"in n){a={};for(var l in n)l!=="ref"&&(a[l]=n[l])}if(e=e.defaultProps){a===n&&(a=b({},a));for(var i in e)a[i]===void 0&&(a[i]=e[i])}return a}var Ds=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var n=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(n))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function wp(e){Ds(e)}function Sp(e){console.error(e)}function Ep(e){Ds(e)}function Ms(e,n){try{var a=e.onUncaughtError;a(n.value,{componentStack:n.stack})}catch(l){setTimeout(function(){throw l})}}function Tp(e,n,a){try{var l=e.onCaughtError;l(a.value,{componentStack:a.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(i){setTimeout(function(){throw i})}}function Au(e,n,a){return a=ga(a),a.tag=3,a.payload={element:null},a.callback=function(){Ms(e,n)},a}function Np(e){return e=ga(e),e.tag=3,e}function Cp(e,n,a,l){var i=a.type.getDerivedStateFromError;if(typeof i=="function"){var d=l.value;e.payload=function(){return i(d)},e.callback=function(){Tp(n,a,l)}}var x=a.stateNode;x!==null&&typeof x.componentDidCatch=="function"&&(e.callback=function(){Tp(n,a,l),typeof i!="function"&&(Ca===null?Ca=new Set([this]):Ca.add(this));var w=l.stack;this.componentDidCatch(l.value,{componentStack:w!==null?w:""})})}function Kw(e,n,a,l,i){if(a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){if(n=a.alternate,n!==null&&Qo(n,a,i,!0),a=ln.current,a!==null){switch(a.tag){case 13:return An===null?Wu():a.alternate===null&&ot===0&&(ot=3),a.flags&=-257,a.flags|=65536,a.lanes=i,l===au?a.flags|=16384:(n=a.updateQueue,n===null?a.updateQueue=new Set([l]):n.add(l),ed(e,l,i)),!1;case 22:return a.flags|=65536,l===au?a.flags|=16384:(n=a.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([l])},a.updateQueue=n):(a=n.retryQueue,a===null?n.retryQueue=new Set([l]):a.add(l)),ed(e,l,i)),!1}throw Error(s(435,a.tag))}return ed(e,l,i),Wu(),!1}if(Pe)return n=ln.current,n!==null?((n.flags&65536)===0&&(n.flags|=256),n.flags|=65536,n.lanes=i,l!==Zc&&(e=Error(s(422),{cause:l}),Xo(nn(e,a)))):(l!==Zc&&(n=Error(s(423),{cause:l}),Xo(nn(n,a))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,l=nn(l,a),i=Au(e.stateNode,l,i),lu(e,i),ot!==4&&(ot=2)),!1;var d=Error(s(520),{cause:l});if(d=nn(d,a),hl===null?hl=[d]:hl.push(d),ot!==4&&(ot=2),n===null)return!0;l=nn(l,a),a=n;do{switch(a.tag){case 3:return a.flags|=65536,e=i&-i,a.lanes|=e,e=Au(a.stateNode,l,e),lu(a,e),!1;case 1:if(n=a.type,d=a.stateNode,(a.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||d!==null&&typeof d.componentDidCatch=="function"&&(Ca===null||!Ca.has(d))))return a.flags|=65536,i&=-i,a.lanes|=i,i=Np(i),Cp(i,e,a,l),lu(a,i),!1}a=a.return}while(a!==null);return!1}var Rp=Error(s(461)),St=!1;function Rt(e,n,a,l){n.child=e===null?vp(n,null,a,l):Jr(n,e.child,a,l)}function Ap(e,n,a,l,i){a=a.render;var d=n.ref;if("ref"in l){var x={};for(var w in l)w!=="ref"&&(x[w]=l[w])}else x=l;return ir(n),l=du(e,n,a,x,d,i),w=fu(),e!==null&&!St?(mu(e,n,i),Zn(e,n,i)):(Pe&&w&&Qc(n),n.flags|=1,Rt(e,n,l,i),n.child)}function kp(e,n,a,l,i){if(e===null){var d=a.type;return typeof d=="function"&&!Yc(d)&&d.defaultProps===void 0&&a.compare===null?(n.tag=15,n.type=d,_p(e,n,d,l,i)):(e=ms(a.type,null,l,n,n.mode,i),e.ref=n.ref,e.return=n,n.child=e)}if(d=e.child,!Lu(e,i)){var x=d.memoizedProps;if(a=a.compare,a=a!==null?a:Vo,a(x,l)&&e.ref===n.ref)return Zn(e,n,i)}return n.flags|=1,e=Vn(d,l),e.ref=n.ref,e.return=n,n.child=e}function _p(e,n,a,l,i){if(e!==null){var d=e.memoizedProps;if(Vo(d,l)&&e.ref===n.ref)if(St=!1,n.pendingProps=l=d,Lu(e,i))(e.flags&131072)!==0&&(St=!0);else return n.lanes=e.lanes,Zn(e,n,i)}return ku(e,n,a,l,i)}function jp(e,n,a){var l=n.pendingProps,i=l.children,d=e!==null?e.memoizedState:null;if(l.mode==="hidden"){if((n.flags&128)!==0){if(l=d!==null?d.baseLanes|a:a,e!==null){for(i=n.child=e.child,d=0;i!==null;)d=d|i.lanes|i.childLanes,i=i.sibling;n.childLanes=d&~l}else n.childLanes=0,n.child=null;return Op(e,n,l,a)}if((a&536870912)!==0)n.memoizedState={baseLanes:0,cachePool:null},e!==null&&ys(n,d!==null?d.cachePool:null),d!==null?_h(n,d):iu(),yp(n);else return n.lanes=n.childLanes=536870912,Op(e,n,d!==null?d.baseLanes|a:a,a)}else d!==null?(ys(n,d.cachePool),_h(n,d),xa(),n.memoizedState=null):(e!==null&&ys(n,null),iu(),xa());return Rt(e,n,i,a),n.child}function Op(e,n,a,l){var i=nu();return i=i===null?null:{parent:vt._currentValue,pool:i},n.memoizedState={baseLanes:a,cachePool:i},e!==null&&ys(n,null),iu(),yp(n),e!==null&&Qo(e,n,l,!0),null}function zs(e,n){var a=n.ref;if(a===null)e!==null&&e.ref!==null&&(n.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(s(284));(e===null||e.ref!==a)&&(n.flags|=4194816)}}function ku(e,n,a,l,i){return ir(n),a=du(e,n,a,l,void 0,i),l=fu(),e!==null&&!St?(mu(e,n,i),Zn(e,n,i)):(Pe&&l&&Qc(n),n.flags|=1,Rt(e,n,a,i),n.child)}function Dp(e,n,a,l,i,d){return ir(n),n.updateQueue=null,a=Oh(n,l,a,i),jh(e),l=fu(),e!==null&&!St?(mu(e,n,d),Zn(e,n,d)):(Pe&&l&&Qc(n),n.flags|=1,Rt(e,n,a,d),n.child)}function Mp(e,n,a,l,i){if(ir(n),n.stateNode===null){var d=Vr,x=a.contextType;typeof x=="object"&&x!==null&&(d=_t(x)),d=new a(l,d),n.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,d.updater=Ru,n.stateNode=d,d._reactInternals=n,d=n.stateNode,d.props=l,d.state=n.memoizedState,d.refs={},ru(n),x=a.contextType,d.context=typeof x=="object"&&x!==null?_t(x):Vr,d.state=n.memoizedState,x=a.getDerivedStateFromProps,typeof x=="function"&&(Cu(n,a,x,l),d.state=n.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof d.getSnapshotBeforeUpdate=="function"||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(x=d.state,typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount(),x!==d.state&&Ru.enqueueReplaceState(d,d.state,null),tl(n,l,d,i),el(),d.state=n.memoizedState),typeof d.componentDidMount=="function"&&(n.flags|=4194308),l=!0}else if(e===null){d=n.stateNode;var w=n.memoizedProps,_=dr(a,w);d.props=_;var B=d.context,X=a.contextType;x=Vr,typeof X=="object"&&X!==null&&(x=_t(X));var Z=a.getDerivedStateFromProps;X=typeof Z=="function"||typeof d.getSnapshotBeforeUpdate=="function",w=n.pendingProps!==w,X||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(w||B!==x)&&xp(n,d,l,x),pa=!1;var $=n.memoizedState;d.state=$,tl(n,l,d,i),el(),B=n.memoizedState,w||$!==B||pa?(typeof Z=="function"&&(Cu(n,a,Z,l),B=n.memoizedState),(_=pa||bp(n,a,_,l,$,B,x))?(X||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"&&(n.flags|=4194308)):(typeof d.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=l,n.memoizedState=B),d.props=l,d.state=B,d.context=x,l=_):(typeof d.componentDidMount=="function"&&(n.flags|=4194308),l=!1)}else{d=n.stateNode,ou(e,n),x=n.memoizedProps,X=dr(a,x),d.props=X,Z=n.pendingProps,$=d.context,B=a.contextType,_=Vr,typeof B=="object"&&B!==null&&(_=_t(B)),w=a.getDerivedStateFromProps,(B=typeof w=="function"||typeof d.getSnapshotBeforeUpdate=="function")||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(x!==Z||$!==_)&&xp(n,d,l,_),pa=!1,$=n.memoizedState,d.state=$,tl(n,l,d,i),el();var V=n.memoizedState;x!==Z||$!==V||pa||e!==null&&e.dependencies!==null&&gs(e.dependencies)?(typeof w=="function"&&(Cu(n,a,w,l),V=n.memoizedState),(X=pa||bp(n,a,X,l,$,V,_)||e!==null&&e.dependencies!==null&&gs(e.dependencies))?(B||typeof d.UNSAFE_componentWillUpdate!="function"&&typeof d.componentWillUpdate!="function"||(typeof d.componentWillUpdate=="function"&&d.componentWillUpdate(l,V,_),typeof d.UNSAFE_componentWillUpdate=="function"&&d.UNSAFE_componentWillUpdate(l,V,_)),typeof d.componentDidUpdate=="function"&&(n.flags|=4),typeof d.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof d.componentDidUpdate!="function"||x===e.memoizedProps&&$===e.memoizedState||(n.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||x===e.memoizedProps&&$===e.memoizedState||(n.flags|=1024),n.memoizedProps=l,n.memoizedState=V),d.props=l,d.state=V,d.context=_,l=X):(typeof d.componentDidUpdate!="function"||x===e.memoizedProps&&$===e.memoizedState||(n.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||x===e.memoizedProps&&$===e.memoizedState||(n.flags|=1024),l=!1)}return d=l,zs(e,n),l=(n.flags&128)!==0,d||l?(d=n.stateNode,a=l&&typeof a.getDerivedStateFromError!="function"?null:d.render(),n.flags|=1,e!==null&&l?(n.child=Jr(n,e.child,null,i),n.child=Jr(n,null,a,i)):Rt(e,n,a,i),n.memoizedState=d.state,e=n.child):e=Zn(e,n,i),e}function zp(e,n,a,l){return Go(),n.flags|=256,Rt(e,n,a,l),n.child}var _u={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function ju(e){return{baseLanes:e,cachePool:Sh()}}function Ou(e,n,a){return e=e!==null?e.childLanes&~a:0,n&&(e|=sn),e}function Lp(e,n,a){var l=n.pendingProps,i=!1,d=(n.flags&128)!==0,x;if((x=d)||(x=e!==null&&e.memoizedState===null?!1:(yt.current&2)!==0),x&&(i=!0,n.flags&=-129),x=(n.flags&32)!==0,n.flags&=-33,e===null){if(Pe){if(i?ba(n):xa(),Pe){var w=rt,_;if(_=w){e:{for(_=w,w=Rn;_.nodeType!==8;){if(!w){w=null;break e}if(_=gn(_.nextSibling),_===null){w=null;break e}}w=_}w!==null?(n.memoizedState={dehydrated:w,treeContext:ar!==null?{id:In,overflow:Yn}:null,retryLane:536870912,hydrationErrors:null},_=Vt(18,null,null,0),_.stateNode=w,_.return=n,n.child=_,Dt=n,rt=null,_=!0):_=!1}_||lr(n)}if(w=n.memoizedState,w!==null&&(w=w.dehydrated,w!==null))return pd(w)?n.lanes=32:n.lanes=536870912,null;Kn(n)}return w=l.children,l=l.fallback,i?(xa(),i=n.mode,w=Ls({mode:"hidden",children:w},i),l=nr(l,i,a,null),w.return=n,l.return=n,w.sibling=l,n.child=w,i=n.child,i.memoizedState=ju(a),i.childLanes=Ou(e,x,a),n.memoizedState=_u,l):(ba(n),Du(n,w))}if(_=e.memoizedState,_!==null&&(w=_.dehydrated,w!==null)){if(d)n.flags&256?(ba(n),n.flags&=-257,n=Mu(e,n,a)):n.memoizedState!==null?(xa(),n.child=e.child,n.flags|=128,n=null):(xa(),i=l.fallback,w=n.mode,l=Ls({mode:"visible",children:l.children},w),i=nr(i,w,a,null),i.flags|=2,l.return=n,i.return=n,l.sibling=i,n.child=l,Jr(n,e.child,null,a),l=n.child,l.memoizedState=ju(a),l.childLanes=Ou(e,x,a),n.memoizedState=_u,n=i);else if(ba(n),pd(w)){if(x=w.nextSibling&&w.nextSibling.dataset,x)var B=x.dgst;x=B,l=Error(s(419)),l.stack="",l.digest=x,Xo({value:l,source:null,stack:null}),n=Mu(e,n,a)}else if(St||Qo(e,n,a,!1),x=(a&e.childLanes)!==0,St||x){if(x=Ze,x!==null&&(l=a&-a,l=(l&42)!==0?1:Qe(l),l=(l&(x.suspendedLanes|a))!==0?0:l,l!==0&&l!==_.retryLane))throw _.retryLane=l,qr(e,l),Qt(x,e,l),Rp;w.data==="$?"||Wu(),n=Mu(e,n,a)}else w.data==="$?"?(n.flags|=192,n.child=e.child,n=null):(e=_.treeContext,rt=gn(w.nextSibling),Dt=n,Pe=!0,or=null,Rn=!1,e!==null&&(rn[on++]=In,rn[on++]=Yn,rn[on++]=ar,In=e.id,Yn=e.overflow,ar=n),n=Du(n,l.children),n.flags|=4096);return n}return i?(xa(),i=l.fallback,w=n.mode,_=e.child,B=_.sibling,l=Vn(_,{mode:"hidden",children:l.children}),l.subtreeFlags=_.subtreeFlags&65011712,B!==null?i=Vn(B,i):(i=nr(i,w,a,null),i.flags|=2),i.return=n,l.return=n,l.sibling=i,n.child=l,l=i,i=n.child,w=e.child.memoizedState,w===null?w=ju(a):(_=w.cachePool,_!==null?(B=vt._currentValue,_=_.parent!==B?{parent:B,pool:B}:_):_=Sh(),w={baseLanes:w.baseLanes|a,cachePool:_}),i.memoizedState=w,i.childLanes=Ou(e,x,a),n.memoizedState=_u,l):(ba(n),a=e.child,e=a.sibling,a=Vn(a,{mode:"visible",children:l.children}),a.return=n,a.sibling=null,e!==null&&(x=n.deletions,x===null?(n.deletions=[e],n.flags|=16):x.push(e)),n.child=a,n.memoizedState=null,a)}function Du(e,n){return n=Ls({mode:"visible",children:n},e.mode),n.return=e,e.child=n}function Ls(e,n){return e=Vt(22,e,null,n),e.lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function Mu(e,n,a){return Jr(n,e.child,null,a),e=Du(n,n.pendingProps.children),e.flags|=2,n.memoizedState=null,e}function Up(e,n,a){e.lanes|=n;var l=e.alternate;l!==null&&(l.lanes|=n),Wc(e.return,n,a)}function zu(e,n,a,l,i){var d=e.memoizedState;d===null?e.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:l,tail:a,tailMode:i}:(d.isBackwards=n,d.rendering=null,d.renderingStartTime=0,d.last=l,d.tail=a,d.tailMode=i)}function Bp(e,n,a){var l=n.pendingProps,i=l.revealOrder,d=l.tail;if(Rt(e,n,l.children,a),l=yt.current,(l&2)!==0)l=l&1|2,n.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=n.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Up(e,a,n);else if(e.tag===19)Up(e,a,n);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===n)break e;for(;e.sibling===null;){if(e.return===null||e.return===n)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}l&=1}switch(Q(yt,l),i){case"forwards":for(a=n.child,i=null;a!==null;)e=a.alternate,e!==null&&Os(e)===null&&(i=a),a=a.sibling;a=i,a===null?(i=n.child,n.child=null):(i=a.sibling,a.sibling=null),zu(n,!1,i,a,d);break;case"backwards":for(a=null,i=n.child,n.child=null;i!==null;){if(e=i.alternate,e!==null&&Os(e)===null){n.child=i;break}e=i.sibling,i.sibling=a,a=i,i=e}zu(n,!0,a,null,d);break;case"together":zu(n,!1,null,null,void 0);break;default:n.memoizedState=null}return n.child}function Zn(e,n,a){if(e!==null&&(n.dependencies=e.dependencies),Na|=n.lanes,(a&n.childLanes)===0)if(e!==null){if(Qo(e,n,a,!1),(a&n.childLanes)===0)return null}else return null;if(e!==null&&n.child!==e.child)throw Error(s(153));if(n.child!==null){for(e=n.child,a=Vn(e,e.pendingProps),n.child=a,a.return=n;e.sibling!==null;)e=e.sibling,a=a.sibling=Vn(e,e.pendingProps),a.return=n;a.sibling=null}return n.child}function Lu(e,n){return(e.lanes&n)!==0?!0:(e=e.dependencies,!!(e!==null&&gs(e)))}function Zw(e,n,a){switch(n.tag){case 3:ce(n,n.stateNode.containerInfo),ha(n,vt,e.memoizedState.cache),Go();break;case 27:case 5:Re(n);break;case 4:ce(n,n.stateNode.containerInfo);break;case 10:ha(n,n.type,n.memoizedProps.value);break;case 13:var l=n.memoizedState;if(l!==null)return l.dehydrated!==null?(ba(n),n.flags|=128,null):(a&n.child.childLanes)!==0?Lp(e,n,a):(ba(n),e=Zn(e,n,a),e!==null?e.sibling:null);ba(n);break;case 19:var i=(e.flags&128)!==0;if(l=(a&n.childLanes)!==0,l||(Qo(e,n,a,!1),l=(a&n.childLanes)!==0),i){if(l)return Bp(e,n,a);n.flags|=128}if(i=n.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Q(yt,yt.current),l)break;return null;case 22:case 23:return n.lanes=0,jp(e,n,a);case 24:ha(n,vt,e.memoizedState.cache)}return Zn(e,n,a)}function Hp(e,n,a){if(e!==null)if(e.memoizedProps!==n.pendingProps)St=!0;else{if(!Lu(e,a)&&(n.flags&128)===0)return St=!1,Zw(e,n,a);St=(e.flags&131072)!==0}else St=!1,Pe&&(n.flags&1048576)!==0&&ph(n,ps,n.index);switch(n.lanes=0,n.tag){case 16:e:{e=n.pendingProps;var l=n.elementType,i=l._init;if(l=i(l._payload),n.type=l,typeof l=="function")Yc(l)?(e=dr(l,e),n.tag=1,n=Mp(null,n,l,e,a)):(n.tag=0,n=ku(null,n,l,e,a));else{if(l!=null){if(i=l.$$typeof,i===U){n.tag=11,n=Ap(null,n,l,e,a);break e}else if(i===Y){n.tag=14,n=kp(null,n,l,e,a);break e}}throw n=se(l)||l,Error(s(306,n,""))}}return n;case 0:return ku(e,n,n.type,n.pendingProps,a);case 1:return l=n.type,i=dr(l,n.pendingProps),Mp(e,n,l,i,a);case 3:e:{if(ce(n,n.stateNode.containerInfo),e===null)throw Error(s(387));l=n.pendingProps;var d=n.memoizedState;i=d.element,ou(e,n),tl(n,l,null,a);var x=n.memoizedState;if(l=x.cache,ha(n,vt,l),l!==d.cache&&Jc(n,[vt],a,!0),el(),l=x.element,d.isDehydrated)if(d={element:l,isDehydrated:!1,cache:x.cache},n.updateQueue.baseState=d,n.memoizedState=d,n.flags&256){n=zp(e,n,l,a);break e}else if(l!==i){i=nn(Error(s(424)),n),Xo(i),n=zp(e,n,l,a);break e}else for(e=n.stateNode.containerInfo,e.nodeType===9?e=e.body:e=e.nodeName==="HTML"?e.ownerDocument.body:e,rt=gn(e.firstChild),Dt=n,Pe=!0,or=null,Rn=!0,a=vp(n,null,l,a),n.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling;else{if(Go(),l===i){n=Zn(e,n,a);break e}Rt(e,n,l,a)}n=n.child}return n;case 26:return zs(e,n),e===null?(a=Vg(n.type,null,n.pendingProps,null))?n.memoizedState=a:Pe||(a=n.type,e=n.pendingProps,l=Zs(ae.current).createElement(a),l[ct]=n,l[Ke]=e,kt(l,a,e),wt(l),n.stateNode=l):n.memoizedState=Vg(n.type,e.memoizedProps,n.pendingProps,e.memoizedState),null;case 27:return Re(n),e===null&&Pe&&(l=n.stateNode=Pg(n.type,n.pendingProps,ae.current),Dt=n,Rn=!0,i=rt,ka(n.type)?(gd=i,rt=gn(l.firstChild)):rt=i),Rt(e,n,n.pendingProps.children,a),zs(e,n),e===null&&(n.flags|=4194304),n.child;case 5:return e===null&&Pe&&((i=l=rt)&&(l=TS(l,n.type,n.pendingProps,Rn),l!==null?(n.stateNode=l,Dt=n,rt=gn(l.firstChild),Rn=!1,i=!0):i=!1),i||lr(n)),Re(n),i=n.type,d=n.pendingProps,x=e!==null?e.memoizedProps:null,l=d.children,fd(i,d)?l=null:x!==null&&fd(i,x)&&(n.flags|=32),n.memoizedState!==null&&(i=du(e,n,qw,null,null,a),El._currentValue=i),zs(e,n),Rt(e,n,l,a),n.child;case 6:return e===null&&Pe&&((e=a=rt)&&(a=NS(a,n.pendingProps,Rn),a!==null?(n.stateNode=a,Dt=n,rt=null,e=!0):e=!1),e||lr(n)),null;case 13:return Lp(e,n,a);case 4:return ce(n,n.stateNode.containerInfo),l=n.pendingProps,e===null?n.child=Jr(n,null,l,a):Rt(e,n,l,a),n.child;case 11:return Ap(e,n,n.type,n.pendingProps,a);case 7:return Rt(e,n,n.pendingProps,a),n.child;case 8:return Rt(e,n,n.pendingProps.children,a),n.child;case 12:return Rt(e,n,n.pendingProps.children,a),n.child;case 10:return l=n.pendingProps,ha(n,n.type,l.value),Rt(e,n,l.children,a),n.child;case 9:return i=n.type._context,l=n.pendingProps.children,ir(n),i=_t(i),l=l(i),n.flags|=1,Rt(e,n,l,a),n.child;case 14:return kp(e,n,n.type,n.pendingProps,a);case 15:return _p(e,n,n.type,n.pendingProps,a);case 19:return Bp(e,n,a);case 31:return l=n.pendingProps,a=n.mode,l={mode:l.mode,children:l.children},e===null?(a=Ls(l,a),a.ref=n.ref,n.child=a,a.return=n,n=a):(a=Vn(e.child,l),a.ref=n.ref,n.child=a,a.return=n,n=a),n;case 22:return jp(e,n,a);case 24:return ir(n),l=_t(vt),e===null?(i=nu(),i===null&&(i=Ze,d=eu(),i.pooledCache=d,d.refCount++,d!==null&&(i.pooledCacheLanes|=a),i=d),n.memoizedState={parent:l,cache:i},ru(n),ha(n,vt,i)):((e.lanes&a)!==0&&(ou(e,n),tl(n,null,null,a),el()),i=e.memoizedState,d=n.memoizedState,i.parent!==l?(i={parent:l,cache:l},n.memoizedState=i,n.lanes===0&&(n.memoizedState=n.updateQueue.baseState=i),ha(n,vt,l)):(l=d.cache,ha(n,vt,l),l!==i.cache&&Jc(n,[vt],a,!0))),Rt(e,n,n.pendingProps.children,a),n.child;case 29:throw n.pendingProps}throw Error(s(156,n.tag))}function Fn(e){e.flags|=4}function Pp(e,n){if(n.type!=="stylesheet"||(n.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Qg(n)){if(n=ln.current,n!==null&&((Ue&4194048)===Ue?An!==null:(Ue&62914560)!==Ue&&(Ue&536870912)===0||n!==An))throw Wo=au,Eh;e.flags|=8192}}function Us(e,n){n!==null&&(e.flags|=4),e.flags&16384&&(n=e.tag!==22?Ka():536870912,e.lanes|=n,ao|=n)}function il(e,n){if(!Pe)switch(e.tailMode){case"hidden":n=e.tail;for(var a=null;n!==null;)n.alternate!==null&&(a=n),n=n.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?n||e.tail===null?e.tail=null:e.tail.sibling=null:l.sibling=null}}function nt(e){var n=e.alternate!==null&&e.alternate.child===e.child,a=0,l=0;if(n)for(var i=e.child;i!==null;)a|=i.lanes|i.childLanes,l|=i.subtreeFlags&65011712,l|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)a|=i.lanes|i.childLanes,l|=i.subtreeFlags,l|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=l,e.childLanes=a,n}function Fw(e,n,a){var l=n.pendingProps;switch(Kc(n),n.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return nt(n),null;case 1:return nt(n),null;case 3:return a=n.stateNode,l=null,e!==null&&(l=e.memoizedState.cache),n.memoizedState.cache!==l&&(n.flags|=2048),Xn(vt),xe(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(Yo(n)?Fn(n):e===null||e.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,yh())),nt(n),null;case 26:return a=n.memoizedState,e===null?(Fn(n),a!==null?(nt(n),Pp(n,a)):(nt(n),n.flags&=-16777217)):a?a!==e.memoizedState?(Fn(n),nt(n),Pp(n,a)):(nt(n),n.flags&=-16777217):(e.memoizedProps!==l&&Fn(n),nt(n),n.flags&=-16777217),null;case 27:Te(n),a=ae.current;var i=n.type;if(e!==null&&n.stateNode!=null)e.memoizedProps!==l&&Fn(n);else{if(!l){if(n.stateNode===null)throw Error(s(166));return nt(n),null}e=le.current,Yo(n)?gh(n):(e=Pg(i,l,a),n.stateNode=e,Fn(n))}return nt(n),null;case 5:if(Te(n),a=n.type,e!==null&&n.stateNode!=null)e.memoizedProps!==l&&Fn(n);else{if(!l){if(n.stateNode===null)throw Error(s(166));return nt(n),null}if(e=le.current,Yo(n))gh(n);else{switch(i=Zs(ae.current),e){case 1:e=i.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:e=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":e=i.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":e=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":e=i.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild);break;case"select":e=typeof l.is=="string"?i.createElement("select",{is:l.is}):i.createElement("select"),l.multiple?e.multiple=!0:l.size&&(e.size=l.size);break;default:e=typeof l.is=="string"?i.createElement(a,{is:l.is}):i.createElement(a)}}e[ct]=n,e[Ke]=l;e:for(i=n.child;i!==null;){if(i.tag===5||i.tag===6)e.appendChild(i.stateNode);else if(i.tag!==4&&i.tag!==27&&i.child!==null){i.child.return=i,i=i.child;continue}if(i===n)break e;for(;i.sibling===null;){if(i.return===null||i.return===n)break e;i=i.return}i.sibling.return=i.return,i=i.sibling}n.stateNode=e;e:switch(kt(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&&Fn(n)}}return nt(n),n.flags&=-16777217,null;case 6:if(e&&n.stateNode!=null)e.memoizedProps!==l&&Fn(n);else{if(typeof l!="string"&&n.stateNode===null)throw Error(s(166));if(e=ae.current,Yo(n)){if(e=n.stateNode,a=n.memoizedProps,l=null,i=Dt,i!==null)switch(i.tag){case 27:case 5:l=i.memoizedProps}e[ct]=n,e=!!(e.nodeValue===a||l!==null&&l.suppressHydrationWarning===!0||Dg(e.nodeValue,a)),e||lr(n)}else e=Zs(e).createTextNode(l),e[ct]=n,n.stateNode=e}return nt(n),null;case 13:if(l=n.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Yo(n),l!==null&&l.dehydrated!==null){if(e===null){if(!i)throw Error(s(318));if(i=n.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(s(317));i[ct]=n}else Go(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;nt(n),i=!1}else i=yh(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return n.flags&256?(Kn(n),n):(Kn(n),null)}if(Kn(n),(n.flags&128)!==0)return n.lanes=a,n;if(a=l!==null,e=e!==null&&e.memoizedState!==null,a){l=n.child,i=null,l.alternate!==null&&l.alternate.memoizedState!==null&&l.alternate.memoizedState.cachePool!==null&&(i=l.alternate.memoizedState.cachePool.pool);var d=null;l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(d=l.memoizedState.cachePool.pool),d!==i&&(l.flags|=2048)}return a!==e&&a&&(n.child.flags|=8192),Us(n,n.updateQueue),nt(n),null;case 4:return xe(),e===null&&sd(n.stateNode.containerInfo),nt(n),null;case 10:return Xn(n.type),nt(n),null;case 19:if(J(yt),i=n.memoizedState,i===null)return nt(n),null;if(l=(n.flags&128)!==0,d=i.rendering,d===null)if(l)il(i,!1);else{if(ot!==0||e!==null&&(e.flags&128)!==0)for(e=n.child;e!==null;){if(d=Os(e),d!==null){for(n.flags|=128,il(i,!1),e=d.updateQueue,n.updateQueue=e,Us(n,e),n.subtreeFlags=0,e=a,a=n.child;a!==null;)hh(a,e),a=a.sibling;return Q(yt,yt.current&1|2),n.child}e=e.sibling}i.tail!==null&&lt()>Ps&&(n.flags|=128,l=!0,il(i,!1),n.lanes=4194304)}else{if(!l)if(e=Os(d),e!==null){if(n.flags|=128,l=!0,e=e.updateQueue,n.updateQueue=e,Us(n,e),il(i,!0),i.tail===null&&i.tailMode==="hidden"&&!d.alternate&&!Pe)return nt(n),null}else 2*lt()-i.renderingStartTime>Ps&&a!==536870912&&(n.flags|=128,l=!0,il(i,!1),n.lanes=4194304);i.isBackwards?(d.sibling=n.child,n.child=d):(e=i.last,e!==null?e.sibling=d:n.child=d,i.last=d)}return i.tail!==null?(n=i.tail,i.rendering=n,i.tail=n.sibling,i.renderingStartTime=lt(),n.sibling=null,e=yt.current,Q(yt,l?e&1|2:e&1),n):(nt(n),null);case 22:case 23:return Kn(n),cu(),l=n.memoizedState!==null,e!==null?e.memoizedState!==null!==l&&(n.flags|=8192):l&&(n.flags|=8192),l?(a&536870912)!==0&&(n.flags&128)===0&&(nt(n),n.subtreeFlags&6&&(n.flags|=8192)):nt(n),a=n.updateQueue,a!==null&&Us(n,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),l=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(l=n.memoizedState.cachePool.pool),l!==a&&(n.flags|=2048),e!==null&&J(cr),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),n.memoizedState.cache!==a&&(n.flags|=2048),Xn(vt),nt(n),null;case 25:return null;case 30:return null}throw Error(s(156,n.tag))}function Ww(e,n){switch(Kc(n),n.tag){case 1:return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 3:return Xn(vt),xe(),e=n.flags,(e&65536)!==0&&(e&128)===0?(n.flags=e&-65537|128,n):null;case 26:case 27:case 5:return Te(n),null;case 13:if(Kn(n),e=n.memoizedState,e!==null&&e.dehydrated!==null){if(n.alternate===null)throw Error(s(340));Go()}return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 19:return J(yt),null;case 4:return xe(),null;case 10:return Xn(n.type),null;case 22:case 23:return Kn(n),cu(),e!==null&&J(cr),e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 24:return Xn(vt),null;case 25:return null;default:return null}}function $p(e,n){switch(Kc(n),n.tag){case 3:Xn(vt),xe();break;case 26:case 27:case 5:Te(n);break;case 4:xe();break;case 13:Kn(n);break;case 19:J(yt);break;case 10:Xn(n.type);break;case 22:case 23:Kn(n),cu(),e!==null&&J(cr);break;case 24:Xn(vt)}}function cl(e,n){try{var a=n.updateQueue,l=a!==null?a.lastEffect:null;if(l!==null){var i=l.next;a=i;do{if((a.tag&e)===e){l=void 0;var d=a.create,x=a.inst;l=d(),x.destroy=l}a=a.next}while(a!==i)}}catch(w){Ge(n,n.return,w)}}function wa(e,n,a){try{var l=n.updateQueue,i=l!==null?l.lastEffect:null;if(i!==null){var d=i.next;l=d;do{if((l.tag&e)===e){var x=l.inst,w=x.destroy;if(w!==void 0){x.destroy=void 0,i=n;var _=a,B=w;try{B()}catch(X){Ge(i,_,X)}}}l=l.next}while(l!==d)}}catch(X){Ge(n,n.return,X)}}function qp(e){var n=e.updateQueue;if(n!==null){var a=e.stateNode;try{kh(n,a)}catch(l){Ge(e,e.return,l)}}}function Vp(e,n,a){a.props=dr(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(l){Ge(e,n,l)}}function ul(e,n){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(i){Ge(e,n,i)}}function kn(e,n){var a=e.ref,l=e.refCleanup;if(a!==null)if(typeof l=="function")try{l()}catch(i){Ge(e,n,i)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(i){Ge(e,n,i)}else a.current=null}function Ip(e){var n=e.type,a=e.memoizedProps,l=e.stateNode;try{e:switch(n){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(i){Ge(e,e.return,i)}}function Uu(e,n,a){try{var l=e.stateNode;bS(l,e.type,a,n),l[Ke]=n}catch(i){Ge(e,e.return,i)}}function Yp(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&ka(e.type)||e.tag===4}function Bu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Yp(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&&ka(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 Hu(e,n,a){var l=e.tag;if(l===5||l===6)e=e.stateNode,n?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(e,n):(n=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,n.appendChild(e),a=a._reactRootContainer,a!=null||n.onclick!==null||(n.onclick=Ks));else if(l!==4&&(l===27&&ka(e.type)&&(a=e.stateNode,n=null),e=e.child,e!==null))for(Hu(e,n,a),e=e.sibling;e!==null;)Hu(e,n,a),e=e.sibling}function Bs(e,n,a){var l=e.tag;if(l===5||l===6)e=e.stateNode,n?a.insertBefore(e,n):a.appendChild(e);else if(l!==4&&(l===27&&ka(e.type)&&(a=e.stateNode),e=e.child,e!==null))for(Bs(e,n,a),e=e.sibling;e!==null;)Bs(e,n,a),e=e.sibling}function Gp(e){var n=e.stateNode,a=e.memoizedProps;try{for(var l=e.type,i=n.attributes;i.length;)n.removeAttributeNode(i[0]);kt(n,l,a),n[ct]=e,n[Ke]=a}catch(d){Ge(e,e.return,d)}}var Wn=!1,dt=!1,Pu=!1,Xp=typeof WeakSet=="function"?WeakSet:Set,Et=null;function Jw(e,n){if(e=e.containerInfo,ud=ni,e=rh(e),Bc(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 i=l.anchorOffset,d=l.focusNode;l=l.focusOffset;try{a.nodeType,d.nodeType}catch{a=null;break e}var x=0,w=-1,_=-1,B=0,X=0,Z=e,$=null;t:for(;;){for(var V;Z!==a||i!==0&&Z.nodeType!==3||(w=x+i),Z!==d||l!==0&&Z.nodeType!==3||(_=x+l),Z.nodeType===3&&(x+=Z.nodeValue.length),(V=Z.firstChild)!==null;)$=Z,Z=V;for(;;){if(Z===e)break t;if($===a&&++B===i&&(w=x),$===d&&++X===l&&(_=x),(V=Z.nextSibling)!==null)break;Z=$,$=Z.parentNode}Z=V}a=w===-1||_===-1?null:{start:w,end:_}}else a=null}a=a||{start:0,end:0}}else a=null;for(dd={focusedElem:e,selectionRange:a},ni=!1,Et=n;Et!==null;)if(n=Et,e=n.child,(n.subtreeFlags&1024)!==0&&e!==null)e.return=n,Et=e;else for(;Et!==null;){switch(n=Et,d=n.alternate,e=n.flags,n.tag){case 0:break;case 11:case 15:break;case 1:if((e&1024)!==0&&d!==null){e=void 0,a=n,i=d.memoizedProps,d=d.memoizedState,l=a.stateNode;try{var Ee=dr(a.type,i,a.elementType===a.type);e=l.getSnapshotBeforeUpdate(Ee,d),l.__reactInternalSnapshotBeforeUpdate=e}catch(we){Ge(a,a.return,we)}}break;case 3:if((e&1024)!==0){if(e=n.stateNode.containerInfo,a=e.nodeType,a===9)hd(e);else if(a===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":hd(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(s(163))}if(e=n.sibling,e!==null){e.return=n.return,Et=e;break}Et=n.return}}function Qp(e,n,a){var l=a.flags;switch(a.tag){case 0:case 11:case 15:Sa(e,a),l&4&&cl(5,a);break;case 1:if(Sa(e,a),l&4)if(e=a.stateNode,n===null)try{e.componentDidMount()}catch(x){Ge(a,a.return,x)}else{var i=dr(a.type,n.memoizedProps);n=n.memoizedState;try{e.componentDidUpdate(i,n,e.__reactInternalSnapshotBeforeUpdate)}catch(x){Ge(a,a.return,x)}}l&64&&qp(a),l&512&&ul(a,a.return);break;case 3:if(Sa(e,a),l&64&&(e=a.updateQueue,e!==null)){if(n=null,a.child!==null)switch(a.child.tag){case 27:case 5:n=a.child.stateNode;break;case 1:n=a.child.stateNode}try{kh(e,n)}catch(x){Ge(a,a.return,x)}}break;case 27:n===null&&l&4&&Gp(a);case 26:case 5:Sa(e,a),n===null&&l&4&&Ip(a),l&512&&ul(a,a.return);break;case 12:Sa(e,a);break;case 13:Sa(e,a),l&4&&Fp(e,a),l&64&&(e=a.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(a=iS.bind(null,a),CS(e,a))));break;case 22:if(l=a.memoizedState!==null||Wn,!l){n=n!==null&&n.memoizedState!==null||dt,i=Wn;var d=dt;Wn=l,(dt=n)&&!d?Ea(e,a,(a.subtreeFlags&8772)!==0):Sa(e,a),Wn=i,dt=d}break;case 30:break;default:Sa(e,a)}}function Kp(e){var n=e.alternate;n!==null&&(e.alternate=null,Kp(n)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(n=e.stateNode,n!==null&&bc(n)),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 et=null,Bt=!1;function Jn(e,n,a){for(a=a.child;a!==null;)Zp(e,n,a),a=a.sibling}function Zp(e,n,a){if(Ct&&typeof Ct.onCommitFiberUnmount=="function")try{Ct.onCommitFiberUnmount($t,a)}catch{}switch(a.tag){case 26:dt||kn(a,n),Jn(e,n,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:dt||kn(a,n);var l=et,i=Bt;ka(a.type)&&(et=a.stateNode,Bt=!1),Jn(e,n,a),bl(a.stateNode),et=l,Bt=i;break;case 5:dt||kn(a,n);case 6:if(l=et,i=Bt,et=null,Jn(e,n,a),et=l,Bt=i,et!==null)if(Bt)try{(et.nodeType===9?et.body:et.nodeName==="HTML"?et.ownerDocument.body:et).removeChild(a.stateNode)}catch(d){Ge(a,n,d)}else try{et.removeChild(a.stateNode)}catch(d){Ge(a,n,d)}break;case 18:et!==null&&(Bt?(e=et,Bg(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,a.stateNode),Rl(e)):Bg(et,a.stateNode));break;case 4:l=et,i=Bt,et=a.stateNode.containerInfo,Bt=!0,Jn(e,n,a),et=l,Bt=i;break;case 0:case 11:case 14:case 15:dt||wa(2,a,n),dt||wa(4,a,n),Jn(e,n,a);break;case 1:dt||(kn(a,n),l=a.stateNode,typeof l.componentWillUnmount=="function"&&Vp(a,n,l)),Jn(e,n,a);break;case 21:Jn(e,n,a);break;case 22:dt=(l=dt)||a.memoizedState!==null,Jn(e,n,a),dt=l;break;default:Jn(e,n,a)}}function Fp(e,n){if(n.memoizedState===null&&(e=n.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Rl(e)}catch(a){Ge(n,n.return,a)}}function eS(e){switch(e.tag){case 13:case 19:var n=e.stateNode;return n===null&&(n=e.stateNode=new Xp),n;case 22:return e=e.stateNode,n=e._retryCache,n===null&&(n=e._retryCache=new Xp),n;default:throw Error(s(435,e.tag))}}function $u(e,n){var a=eS(e);n.forEach(function(l){var i=cS.bind(null,e,l);a.has(l)||(a.add(l),l.then(i,i))})}function It(e,n){var a=n.deletions;if(a!==null)for(var l=0;l<a.length;l++){var i=a[l],d=e,x=n,w=x;e:for(;w!==null;){switch(w.tag){case 27:if(ka(w.type)){et=w.stateNode,Bt=!1;break e}break;case 5:et=w.stateNode,Bt=!1;break e;case 3:case 4:et=w.stateNode.containerInfo,Bt=!0;break e}w=w.return}if(et===null)throw Error(s(160));Zp(d,x,i),et=null,Bt=!1,d=i.alternate,d!==null&&(d.return=null),i.return=null}if(n.subtreeFlags&13878)for(n=n.child;n!==null;)Wp(n,e),n=n.sibling}var pn=null;function Wp(e,n){var a=e.alternate,l=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:It(n,e),Yt(e),l&4&&(wa(3,e,e.return),cl(3,e),wa(5,e,e.return));break;case 1:It(n,e),Yt(e),l&512&&(dt||a===null||kn(a,a.return)),l&64&&Wn&&(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 i=pn;if(It(n,e),Yt(e),l&512&&(dt||a===null||kn(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,i=i.ownerDocument||i;t:switch(l){case"title":d=i.getElementsByTagName("title")[0],(!d||d[Mo]||d[ct]||d.namespaceURI==="http://www.w3.org/2000/svg"||d.hasAttribute("itemprop"))&&(d=i.createElement(l),i.head.insertBefore(d,i.querySelector("head > title"))),kt(d,l,a),d[ct]=e,wt(d),l=d;break e;case"link":var x=Gg("link","href",i).get(l+(a.href||""));if(x){for(var w=0;w<x.length;w++)if(d=x[w],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)){x.splice(w,1);break t}}d=i.createElement(l),kt(d,l,a),i.head.appendChild(d);break;case"meta":if(x=Gg("meta","content",i).get(l+(a.content||""))){for(w=0;w<x.length;w++)if(d=x[w],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)){x.splice(w,1);break t}}d=i.createElement(l),kt(d,l,a),i.head.appendChild(d);break;default:throw Error(s(468,l))}d[ct]=e,wt(d),l=d}e.stateNode=l}else Xg(i,e.type,e.stateNode);else e.stateNode=Yg(i,l,e.memoizedProps);else d!==l?(d===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):d.count--,l===null?Xg(i,e.type,e.stateNode):Yg(i,l,e.memoizedProps)):l===null&&e.stateNode!==null&&Uu(e,e.memoizedProps,a.memoizedProps)}break;case 27:It(n,e),Yt(e),l&512&&(dt||a===null||kn(a,a.return)),a!==null&&l&4&&Uu(e,e.memoizedProps,a.memoizedProps);break;case 5:if(It(n,e),Yt(e),l&512&&(dt||a===null||kn(a,a.return)),e.flags&32){i=e.stateNode;try{zr(i,"")}catch(V){Ge(e,e.return,V)}}l&4&&e.stateNode!=null&&(i=e.memoizedProps,Uu(e,i,a!==null?a.memoizedProps:i)),l&1024&&(Pu=!0);break;case 6:if(It(n,e),Yt(e),l&4){if(e.stateNode===null)throw Error(s(162));l=e.memoizedProps,a=e.stateNode;try{a.nodeValue=l}catch(V){Ge(e,e.return,V)}}break;case 3:if(Js=null,i=pn,pn=Fs(n.containerInfo),It(n,e),pn=i,Yt(e),l&4&&a!==null&&a.memoizedState.isDehydrated)try{Rl(n.containerInfo)}catch(V){Ge(e,e.return,V)}Pu&&(Pu=!1,Jp(e));break;case 4:l=pn,pn=Fs(e.stateNode.containerInfo),It(n,e),Yt(e),pn=l;break;case 12:It(n,e),Yt(e);break;case 13:It(n,e),Yt(e),e.child.flags&8192&&e.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(Xu=lt()),l&4&&(l=e.updateQueue,l!==null&&(e.updateQueue=null,$u(e,l)));break;case 22:i=e.memoizedState!==null;var _=a!==null&&a.memoizedState!==null,B=Wn,X=dt;if(Wn=B||i,dt=X||_,It(n,e),dt=X,Wn=B,Yt(e),l&8192)e:for(n=e.stateNode,n._visibility=i?n._visibility&-2:n._visibility|1,i&&(a===null||_||Wn||dt||fr(e)),a=null,n=e;;){if(n.tag===5||n.tag===26){if(a===null){_=a=n;try{if(d=_.stateNode,i)x=d.style,typeof x.setProperty=="function"?x.setProperty("display","none","important"):x.display="none";else{w=_.stateNode;var Z=_.memoizedProps.style,$=Z!=null&&Z.hasOwnProperty("display")?Z.display:null;w.style.display=$==null||typeof $=="boolean"?"":(""+$).trim()}}catch(V){Ge(_,_.return,V)}}}else if(n.tag===6){if(a===null){_=n;try{_.stateNode.nodeValue=i?"":_.memoizedProps}catch(V){Ge(_,_.return,V)}}}else if((n.tag!==22&&n.tag!==23||n.memoizedState===null||n===e)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break e;for(;n.sibling===null;){if(n.return===null||n.return===e)break e;a===n&&(a=null),n=n.return}a===n&&(a=null),n.sibling.return=n.return,n=n.sibling}l&4&&(l=e.updateQueue,l!==null&&(a=l.retryQueue,a!==null&&(l.retryQueue=null,$u(e,a))));break;case 19:It(n,e),Yt(e),l&4&&(l=e.updateQueue,l!==null&&(e.updateQueue=null,$u(e,l)));break;case 30:break;case 21:break;default:It(n,e),Yt(e)}}function Yt(e){var n=e.flags;if(n&2){try{for(var a,l=e.return;l!==null;){if(Yp(l)){a=l;break}l=l.return}if(a==null)throw Error(s(160));switch(a.tag){case 27:var i=a.stateNode,d=Bu(e);Bs(e,d,i);break;case 5:var x=a.stateNode;a.flags&32&&(zr(x,""),a.flags&=-33);var w=Bu(e);Bs(e,w,x);break;case 3:case 4:var _=a.stateNode.containerInfo,B=Bu(e);Hu(e,B,_);break;default:throw Error(s(161))}}catch(X){Ge(e,e.return,X)}e.flags&=-3}n&4096&&(e.flags&=-4097)}function Jp(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var n=e;Jp(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),e=e.sibling}}function Sa(e,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)Qp(e,n.alternate,n),n=n.sibling}function fr(e){for(e=e.child;e!==null;){var n=e;switch(n.tag){case 0:case 11:case 14:case 15:wa(4,n,n.return),fr(n);break;case 1:kn(n,n.return);var a=n.stateNode;typeof a.componentWillUnmount=="function"&&Vp(n,n.return,a),fr(n);break;case 27:bl(n.stateNode);case 26:case 5:kn(n,n.return),fr(n);break;case 22:n.memoizedState===null&&fr(n);break;case 30:fr(n);break;default:fr(n)}e=e.sibling}}function Ea(e,n,a){for(a=a&&(n.subtreeFlags&8772)!==0,n=n.child;n!==null;){var l=n.alternate,i=e,d=n,x=d.flags;switch(d.tag){case 0:case 11:case 15:Ea(i,d,a),cl(4,d);break;case 1:if(Ea(i,d,a),l=d,i=l.stateNode,typeof i.componentDidMount=="function")try{i.componentDidMount()}catch(B){Ge(l,l.return,B)}if(l=d,i=l.updateQueue,i!==null){var w=l.stateNode;try{var _=i.shared.hiddenCallbacks;if(_!==null)for(i.shared.hiddenCallbacks=null,i=0;i<_.length;i++)Ah(_[i],w)}catch(B){Ge(l,l.return,B)}}a&&x&64&&qp(d),ul(d,d.return);break;case 27:Gp(d);case 26:case 5:Ea(i,d,a),a&&l===null&&x&4&&Ip(d),ul(d,d.return);break;case 12:Ea(i,d,a);break;case 13:Ea(i,d,a),a&&x&4&&Fp(i,d);break;case 22:d.memoizedState===null&&Ea(i,d,a),ul(d,d.return);break;case 30:break;default:Ea(i,d,a)}n=n.sibling}}function qu(e,n){var a=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),e=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(e=n.memoizedState.cachePool.pool),e!==a&&(e!=null&&e.refCount++,a!=null&&Ko(a))}function Vu(e,n){e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Ko(e))}function _n(e,n,a,l){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)eg(e,n,a,l),n=n.sibling}function eg(e,n,a,l){var i=n.flags;switch(n.tag){case 0:case 11:case 15:_n(e,n,a,l),i&2048&&cl(9,n);break;case 1:_n(e,n,a,l);break;case 3:_n(e,n,a,l),i&2048&&(e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Ko(e)));break;case 12:if(i&2048){_n(e,n,a,l),e=n.stateNode;try{var d=n.memoizedProps,x=d.id,w=d.onPostCommit;typeof w=="function"&&w(x,n.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(_){Ge(n,n.return,_)}}else _n(e,n,a,l);break;case 13:_n(e,n,a,l);break;case 23:break;case 22:d=n.stateNode,x=n.alternate,n.memoizedState!==null?d._visibility&2?_n(e,n,a,l):dl(e,n):d._visibility&2?_n(e,n,a,l):(d._visibility|=2,eo(e,n,a,l,(n.subtreeFlags&10256)!==0)),i&2048&&qu(x,n);break;case 24:_n(e,n,a,l),i&2048&&Vu(n.alternate,n);break;default:_n(e,n,a,l)}}function eo(e,n,a,l,i){for(i=i&&(n.subtreeFlags&10256)!==0,n=n.child;n!==null;){var d=e,x=n,w=a,_=l,B=x.flags;switch(x.tag){case 0:case 11:case 15:eo(d,x,w,_,i),cl(8,x);break;case 23:break;case 22:var X=x.stateNode;x.memoizedState!==null?X._visibility&2?eo(d,x,w,_,i):dl(d,x):(X._visibility|=2,eo(d,x,w,_,i)),i&&B&2048&&qu(x.alternate,x);break;case 24:eo(d,x,w,_,i),i&&B&2048&&Vu(x.alternate,x);break;default:eo(d,x,w,_,i)}n=n.sibling}}function dl(e,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var a=e,l=n,i=l.flags;switch(l.tag){case 22:dl(a,l),i&2048&&qu(l.alternate,l);break;case 24:dl(a,l),i&2048&&Vu(l.alternate,l);break;default:dl(a,l)}n=n.sibling}}var fl=8192;function to(e){if(e.subtreeFlags&fl)for(e=e.child;e!==null;)tg(e),e=e.sibling}function tg(e){switch(e.tag){case 26:to(e),e.flags&fl&&e.memoizedState!==null&&HS(pn,e.memoizedState,e.memoizedProps);break;case 5:to(e);break;case 3:case 4:var n=pn;pn=Fs(e.stateNode.containerInfo),to(e),pn=n;break;case 22:e.memoizedState===null&&(n=e.alternate,n!==null&&n.memoizedState!==null?(n=fl,fl=16777216,to(e),fl=n):to(e));break;default:to(e)}}function ng(e){var n=e.alternate;if(n!==null&&(e=n.child,e!==null)){n.child=null;do n=e.sibling,e.sibling=null,e=n;while(e!==null)}}function ml(e){var n=e.deletions;if((e.flags&16)!==0){if(n!==null)for(var a=0;a<n.length;a++){var l=n[a];Et=l,rg(l,e)}ng(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)ag(e),e=e.sibling}function ag(e){switch(e.tag){case 0:case 11:case 15:ml(e),e.flags&2048&&wa(9,e,e.return);break;case 3:ml(e);break;case 12:ml(e);break;case 22:var n=e.stateNode;e.memoizedState!==null&&n._visibility&2&&(e.return===null||e.return.tag!==13)?(n._visibility&=-3,Hs(e)):ml(e);break;default:ml(e)}}function Hs(e){var n=e.deletions;if((e.flags&16)!==0){if(n!==null)for(var a=0;a<n.length;a++){var l=n[a];Et=l,rg(l,e)}ng(e)}for(e=e.child;e!==null;){switch(n=e,n.tag){case 0:case 11:case 15:wa(8,n,n.return),Hs(n);break;case 22:a=n.stateNode,a._visibility&2&&(a._visibility&=-3,Hs(n));break;default:Hs(n)}e=e.sibling}}function rg(e,n){for(;Et!==null;){var a=Et;switch(a.tag){case 0:case 11:case 15:wa(8,a,n);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:Ko(a.memoizedState.cache)}if(l=a.child,l!==null)l.return=a,Et=l;else e:for(a=e;Et!==null;){l=Et;var i=l.sibling,d=l.return;if(Kp(l),l===a){Et=null;break e}if(i!==null){i.return=d,Et=i;break e}Et=d}}}var tS={getCacheForType:function(e){var n=_t(vt),a=n.data.get(e);return a===void 0&&(a=e(),n.data.set(e,a)),a}},nS=typeof WeakMap=="function"?WeakMap:Map,$e=0,Ze=null,De=null,Ue=0,qe=0,Gt=null,Ta=!1,no=!1,Iu=!1,ea=0,ot=0,Na=0,mr=0,Yu=0,sn=0,ao=0,hl=null,Ht=null,Gu=!1,Xu=0,Ps=1/0,$s=null,Ca=null,At=0,Ra=null,ro=null,oo=0,Qu=0,Ku=null,og=null,pl=0,Zu=null;function Xt(){if(($e&2)!==0&&Ue!==0)return Ue&-Ue;if(j.T!==null){var e=Gr;return e!==0?e:ad()}return Fa()}function lg(){sn===0&&(sn=(Ue&536870912)===0||Pe?zt():536870912);var e=ln.current;return e!==null&&(e.flags|=32),sn}function Qt(e,n,a){(e===Ze&&(qe===2||qe===9)||e.cancelPendingCommit!==null)&&(lo(e,0),Aa(e,Ue,sn,!1)),be(e,a),(($e&2)===0||e!==Ze)&&(e===Ze&&(($e&2)===0&&(mr|=a),ot===4&&Aa(e,Ue,sn,!1)),jn(e))}function sg(e,n,a){if(($e&6)!==0)throw Error(s(327));var l=!a&&(n&124)===0&&(n&e.expiredLanes)===0||Hn(e,n),i=l?oS(e,n):Ju(e,n,!0),d=l;do{if(i===0){no&&!l&&Aa(e,n,0,!1);break}else{if(a=e.current.alternate,d&&!aS(a)){i=Ju(e,n,!1),d=!1;continue}if(i===2){if(d=n,e.errorRecoveryDisabledLanes&d)var x=0;else x=e.pendingLanes&-536870913,x=x!==0?x:x&536870912?536870912:0;if(x!==0){n=x;e:{var w=e;i=hl;var _=w.current.memoizedState.isDehydrated;if(_&&(lo(w,x).flags|=256),x=Ju(w,x,!1),x!==2){if(Iu&&!_){w.errorRecoveryDisabledLanes|=d,mr|=d,i=4;break e}d=Ht,Ht=i,d!==null&&(Ht===null?Ht=d:Ht.push.apply(Ht,d))}i=x}if(d=!1,i!==2)continue}}if(i===1){lo(e,0),Aa(e,n,0,!0);break}e:{switch(l=e,d=i,d){case 0:case 1:throw Error(s(345));case 4:if((n&4194048)!==n)break;case 6:Aa(l,n,sn,!Ta);break e;case 2:Ht=null;break;case 3:case 5:break;default:throw Error(s(329))}if((n&62914560)===n&&(i=Xu+300-lt(),10<i)){if(Aa(l,n,sn,!Ta),Bn(l,0,!0)!==0)break e;l.timeoutHandle=Lg(ig.bind(null,l,a,Ht,$s,Gu,n,sn,mr,ao,Ta,d,2,-0,0),i);break e}ig(l,a,Ht,$s,Gu,n,sn,mr,ao,Ta,d,0,-0,0)}}break}while(!0);jn(e)}function ig(e,n,a,l,i,d,x,w,_,B,X,Z,$,V){if(e.timeoutHandle=-1,Z=n.subtreeFlags,(Z&8192||(Z&16785408)===16785408)&&(Sl={stylesheets:null,count:0,unsuspend:BS},tg(n),Z=PS(),Z!==null)){e.cancelPendingCommit=Z(pg.bind(null,e,n,d,a,l,i,x,w,_,X,1,$,V)),Aa(e,d,x,!B);return}pg(e,n,d,a,l,i,x,w,_)}function aS(e){for(var n=e;;){var a=n.tag;if((a===0||a===11||a===15)&&n.flags&16384&&(a=n.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var l=0;l<a.length;l++){var i=a[l],d=i.getSnapshot;i=i.value;try{if(!qt(d(),i))return!1}catch{return!1}}if(a=n.child,n.subtreeFlags&16384&&a!==null)a.return=n,n=a;else{if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}function Aa(e,n,a,l){n&=~Yu,n&=~mr,e.suspendedLanes|=n,e.pingedLanes&=~n,l&&(e.warmLanes|=n),l=e.expirationTimes;for(var i=n;0<i;){var d=31-We(i),x=1<<d;l[d]=-1,i&=~x}a!==0&&me(e,a,n)}function qs(){return($e&6)===0?(gl(0),!1):!0}function Fu(){if(De!==null){if(qe===0)var e=De.return;else e=De,Gn=sr=null,hu(e),Wr=null,ll=0,e=De;for(;e!==null;)$p(e.alternate,e),e=e.return;De=null}}function lo(e,n){var a=e.timeoutHandle;a!==-1&&(e.timeoutHandle=-1,wS(a)),a=e.cancelPendingCommit,a!==null&&(e.cancelPendingCommit=null,a()),Fu(),Ze=e,De=a=Vn(e.current,null),Ue=n,qe=0,Gt=null,Ta=!1,no=Hn(e,n),Iu=!1,ao=sn=Yu=mr=Na=ot=0,Ht=hl=null,Gu=!1,(n&8)!==0&&(n|=n&32);var l=e.entangledLanes;if(l!==0)for(e=e.entanglements,l&=n;0<l;){var i=31-We(l),d=1<<i;n|=e[i],l&=~d}return ea=n,us(),a}function cg(e,n){ke=null,j.H=ks,n===Fo||n===bs?(n=Ch(),qe=3):n===Eh?(n=Ch(),qe=4):qe=n===Rp?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,Gt=n,De===null&&(ot=1,Ms(e,nn(n,e.current)))}function ug(){var e=j.H;return j.H=ks,e===null?ks:e}function dg(){var e=j.A;return j.A=tS,e}function Wu(){ot=4,Ta||(Ue&4194048)!==Ue&&ln.current!==null||(no=!0),(Na&134217727)===0&&(mr&134217727)===0||Ze===null||Aa(Ze,Ue,sn,!1)}function Ju(e,n,a){var l=$e;$e|=2;var i=ug(),d=dg();(Ze!==e||Ue!==n)&&($s=null,lo(e,n)),n=!1;var x=ot;e:do try{if(qe!==0&&De!==null){var w=De,_=Gt;switch(qe){case 8:Fu(),x=6;break e;case 3:case 2:case 9:case 6:ln.current===null&&(n=!0);var B=qe;if(qe=0,Gt=null,so(e,w,_,B),a&&no){x=0;break e}break;default:B=qe,qe=0,Gt=null,so(e,w,_,B)}}rS(),x=ot;break}catch(X){cg(e,X)}while(!0);return n&&e.shellSuspendCounter++,Gn=sr=null,$e=l,j.H=i,j.A=d,De===null&&(Ze=null,Ue=0,us()),x}function rS(){for(;De!==null;)fg(De)}function oS(e,n){var a=$e;$e|=2;var l=ug(),i=dg();Ze!==e||Ue!==n?($s=null,Ps=lt()+500,lo(e,n)):no=Hn(e,n);e:do try{if(qe!==0&&De!==null){n=De;var d=Gt;t:switch(qe){case 1:qe=0,Gt=null,so(e,n,d,1);break;case 2:case 9:if(Th(d)){qe=0,Gt=null,mg(n);break}n=function(){qe!==2&&qe!==9||Ze!==e||(qe=7),jn(e)},d.then(n,n);break e;case 3:qe=7;break e;case 4:qe=5;break e;case 7:Th(d)?(qe=0,Gt=null,mg(n)):(qe=0,Gt=null,so(e,n,d,7));break;case 5:var x=null;switch(De.tag){case 26:x=De.memoizedState;case 5:case 27:var w=De;if(!x||Qg(x)){qe=0,Gt=null;var _=w.sibling;if(_!==null)De=_;else{var B=w.return;B!==null?(De=B,Vs(B)):De=null}break t}}qe=0,Gt=null,so(e,n,d,5);break;case 6:qe=0,Gt=null,so(e,n,d,6);break;case 8:Fu(),ot=6;break e;default:throw Error(s(462))}}lS();break}catch(X){cg(e,X)}while(!0);return Gn=sr=null,j.H=l,j.A=i,$e=a,De!==null?0:(Ze=null,Ue=0,us(),ot)}function lS(){for(;De!==null&&!dn();)fg(De)}function fg(e){var n=Hp(e.alternate,e,ea);e.memoizedProps=e.pendingProps,n===null?Vs(e):De=n}function mg(e){var n=e,a=n.alternate;switch(n.tag){case 15:case 0:n=Dp(a,n,n.pendingProps,n.type,void 0,Ue);break;case 11:n=Dp(a,n,n.pendingProps,n.type.render,n.ref,Ue);break;case 5:hu(n);default:$p(a,n),n=De=hh(n,ea),n=Hp(a,n,ea)}e.memoizedProps=e.pendingProps,n===null?Vs(e):De=n}function so(e,n,a,l){Gn=sr=null,hu(n),Wr=null,ll=0;var i=n.return;try{if(Kw(e,i,n,a,Ue)){ot=1,Ms(e,nn(a,e.current)),De=null;return}}catch(d){if(i!==null)throw De=i,d;ot=1,Ms(e,nn(a,e.current)),De=null;return}n.flags&32768?(Pe||l===1?e=!0:no||(Ue&536870912)!==0?e=!1:(Ta=e=!0,(l===2||l===9||l===3||l===6)&&(l=ln.current,l!==null&&l.tag===13&&(l.flags|=16384))),hg(n,e)):Vs(n)}function Vs(e){var n=e;do{if((n.flags&32768)!==0){hg(n,Ta);return}e=n.return;var a=Fw(n.alternate,n,ea);if(a!==null){De=a;return}if(n=n.sibling,n!==null){De=n;return}De=n=e}while(n!==null);ot===0&&(ot=5)}function hg(e,n){do{var a=Ww(e.alternate,e);if(a!==null){a.flags&=32767,De=a;return}if(a=e.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!n&&(e=e.sibling,e!==null)){De=e;return}De=e=a}while(e!==null);ot=6,De=null}function pg(e,n,a,l,i,d,x,w,_){e.cancelPendingCommit=null;do Is();while(At!==0);if(($e&6)!==0)throw Error(s(327));if(n!==null){if(n===e.current)throw Error(s(177));if(d=n.lanes|n.childLanes,d|=Vc,Xe(e,a,d,x,w,_),e===Ze&&(De=Ze=null,Ue=0),ro=n,Ra=e,oo=a,Qu=d,Ku=i,og=l,(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,uS(Un,function(){return xg(),null})):(e.callbackNode=null,e.callbackPriority=0),l=(n.flags&13878)!==0,(n.subtreeFlags&13878)!==0||l){l=j.T,j.T=null,i=P.p,P.p=2,x=$e,$e|=4;try{Jw(e,n,a)}finally{$e=x,P.p=i,j.T=l}}At=1,gg(),vg(),yg()}}function gg(){if(At===1){At=0;var e=Ra,n=ro,a=(n.flags&13878)!==0;if((n.subtreeFlags&13878)!==0||a){a=j.T,j.T=null;var l=P.p;P.p=2;var i=$e;$e|=4;try{Wp(n,e);var d=dd,x=rh(e.containerInfo),w=d.focusedElem,_=d.selectionRange;if(x!==w&&w&&w.ownerDocument&&ah(w.ownerDocument.documentElement,w)){if(_!==null&&Bc(w)){var B=_.start,X=_.end;if(X===void 0&&(X=B),"selectionStart"in w)w.selectionStart=B,w.selectionEnd=Math.min(X,w.value.length);else{var Z=w.ownerDocument||document,$=Z&&Z.defaultView||window;if($.getSelection){var V=$.getSelection(),Ee=w.textContent.length,we=Math.min(_.start,Ee),Ye=_.end===void 0?we:Math.min(_.end,Ee);!V.extend&&we>Ye&&(x=Ye,Ye=we,we=x);var M=nh(w,we),D=nh(w,Ye);if(M&&D&&(V.rangeCount!==1||V.anchorNode!==M.node||V.anchorOffset!==M.offset||V.focusNode!==D.node||V.focusOffset!==D.offset)){var L=Z.createRange();L.setStart(M.node,M.offset),V.removeAllRanges(),we>Ye?(V.addRange(L),V.extend(D.node,D.offset)):(L.setEnd(D.node,D.offset),V.addRange(L))}}}}for(Z=[],V=w;V=V.parentNode;)V.nodeType===1&&Z.push({element:V,left:V.scrollLeft,top:V.scrollTop});for(typeof w.focus=="function"&&w.focus(),w=0;w<Z.length;w++){var K=Z[w];K.element.scrollLeft=K.left,K.element.scrollTop=K.top}}ni=!!ud,dd=ud=null}finally{$e=i,P.p=l,j.T=a}}e.current=n,At=2}}function vg(){if(At===2){At=0;var e=Ra,n=ro,a=(n.flags&8772)!==0;if((n.subtreeFlags&8772)!==0||a){a=j.T,j.T=null;var l=P.p;P.p=2;var i=$e;$e|=4;try{Qp(e,n.alternate,n)}finally{$e=i,P.p=l,j.T=a}}At=3}}function yg(){if(At===4||At===3){At=0,fn();var e=Ra,n=ro,a=oo,l=og;(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?At=5:(At=0,ro=Ra=null,bg(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(Ca=null),pt(a),n=n.stateNode,Ct&&typeof Ct.onCommitFiberRoot=="function")try{Ct.onCommitFiberRoot($t,n,void 0,(n.current.flags&128)===128)}catch{}if(l!==null){n=j.T,i=P.p,P.p=2,j.T=null;try{for(var d=e.onRecoverableError,x=0;x<l.length;x++){var w=l[x];d(w.value,{componentStack:w.stack})}}finally{j.T=n,P.p=i}}(oo&3)!==0&&Is(),jn(e),i=e.pendingLanes,(a&4194090)!==0&&(i&42)!==0?e===Zu?pl++:(pl=0,Zu=e):pl=0,gl(0)}}function bg(e,n){(e.pooledCacheLanes&=n)===0&&(n=e.pooledCache,n!=null&&(e.pooledCache=null,Ko(n)))}function Is(e){return gg(),vg(),yg(),xg()}function xg(){if(At!==5)return!1;var e=Ra,n=Qu;Qu=0;var a=pt(oo),l=j.T,i=P.p;try{P.p=32>a?32:a,j.T=null,a=Ku,Ku=null;var d=Ra,x=oo;if(At=0,ro=Ra=null,oo=0,($e&6)!==0)throw Error(s(331));var w=$e;if($e|=4,ag(d.current),eg(d,d.current,x,a),$e=w,gl(0,!1),Ct&&typeof Ct.onPostCommitFiberRoot=="function")try{Ct.onPostCommitFiberRoot($t,d)}catch{}return!0}finally{P.p=i,j.T=l,bg(e,n)}}function wg(e,n,a){n=nn(a,n),n=Au(e.stateNode,n,2),e=va(e,n,2),e!==null&&(be(e,2),jn(e))}function Ge(e,n,a){if(e.tag===3)wg(e,e,a);else for(;n!==null;){if(n.tag===3){wg(n,e,a);break}else if(n.tag===1){var l=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof l.componentDidCatch=="function"&&(Ca===null||!Ca.has(l))){e=nn(a,e),a=Np(2),l=va(n,a,2),l!==null&&(Cp(a,l,n,e),be(l,2),jn(l));break}}n=n.return}}function ed(e,n,a){var l=e.pingCache;if(l===null){l=e.pingCache=new nS;var i=new Set;l.set(n,i)}else i=l.get(n),i===void 0&&(i=new Set,l.set(n,i));i.has(a)||(Iu=!0,i.add(a),e=sS.bind(null,e,n,a),n.then(e,e))}function sS(e,n,a){var l=e.pingCache;l!==null&&l.delete(n),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,Ze===e&&(Ue&a)===a&&(ot===4||ot===3&&(Ue&62914560)===Ue&&300>lt()-Xu?($e&2)===0&&lo(e,0):Yu|=a,ao===Ue&&(ao=0)),jn(e)}function Sg(e,n){n===0&&(n=Ka()),e=qr(e,n),e!==null&&(be(e,n),jn(e))}function iS(e){var n=e.memoizedState,a=0;n!==null&&(a=n.retryLane),Sg(e,a)}function cS(e,n){var a=0;switch(e.tag){case 13:var l=e.stateNode,i=e.memoizedState;i!==null&&(a=i.retryLane);break;case 19:l=e.stateNode;break;case 22:l=e.stateNode._retryCache;break;default:throw Error(s(314))}l!==null&&l.delete(n),Sg(e,a)}function uS(e,n){return Je(e,n)}var Ys=null,io=null,td=!1,Gs=!1,nd=!1,hr=0;function jn(e){e!==io&&e.next===null&&(io===null?Ys=io=e:io=io.next=e),Gs=!0,td||(td=!0,fS())}function gl(e,n){if(!nd&&Gs){nd=!0;do for(var a=!1,l=Ys;l!==null;){if(e!==0){var i=l.pendingLanes;if(i===0)var d=0;else{var x=l.suspendedLanes,w=l.pingedLanes;d=(1<<31-We(42|e)+1)-1,d&=i&~(x&~w),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(a=!0,Cg(l,d))}else d=Ue,d=Bn(l,l===Ze?d:0,l.cancelPendingCommit!==null||l.timeoutHandle!==-1),(d&3)===0||Hn(l,d)||(a=!0,Cg(l,d));l=l.next}while(a);nd=!1}}function dS(){Eg()}function Eg(){Gs=td=!1;var e=0;hr!==0&&(xS()&&(e=hr),hr=0);for(var n=lt(),a=null,l=Ys;l!==null;){var i=l.next,d=Tg(l,n);d===0?(l.next=null,a===null?Ys=i:a.next=i,i===null&&(io=a)):(a=l,(e!==0||(d&3)!==0)&&(Gs=!0)),l=i}gl(e)}function Tg(e,n){for(var a=e.suspendedLanes,l=e.pingedLanes,i=e.expirationTimes,d=e.pendingLanes&-62914561;0<d;){var x=31-We(d),w=1<<x,_=i[x];_===-1?((w&a)===0||(w&l)!==0)&&(i[x]=fa(w,n)):_<=n&&(e.expiredLanes|=w),d&=~w}if(n=Ze,a=Ue,a=Bn(e,e===n?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),l=e.callbackNode,a===0||e===n&&(qe===2||qe===9)||e.cancelPendingCommit!==null)return l!==null&&l!==null&&at(l),e.callbackNode=null,e.callbackPriority=0;if((a&3)===0||Hn(e,a)){if(n=a&-a,n===e.callbackPriority)return n;switch(l!==null&&at(l),pt(a)){case 2:case 8:a=Nr;break;case 32:a=Un;break;case 268435456:a=mn;break;default:a=Un}return l=Ng.bind(null,e),a=Je(a,l),e.callbackPriority=n,e.callbackNode=a,n}return l!==null&&l!==null&&at(l),e.callbackPriority=2,e.callbackNode=null,2}function Ng(e,n){if(At!==0&&At!==5)return e.callbackNode=null,e.callbackPriority=0,null;var a=e.callbackNode;if(Is()&&e.callbackNode!==a)return null;var l=Ue;return l=Bn(e,e===Ze?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),l===0?null:(sg(e,l,n),Tg(e,lt()),e.callbackNode!=null&&e.callbackNode===a?Ng.bind(null,e):null)}function Cg(e,n){if(Is())return null;sg(e,n,!0)}function fS(){SS(function(){($e&6)!==0?Je(ht,dS):Eg()})}function ad(){return hr===0&&(hr=zt()),hr}function Rg(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:as(""+e)}function Ag(e,n){var a=n.ownerDocument.createElement("input");return a.name=n.name,a.value=n.value,e.id&&a.setAttribute("form",e.id),n.parentNode.insertBefore(a,n),e=new FormData(e),a.parentNode.removeChild(a),e}function mS(e,n,a,l,i){if(n==="submit"&&a&&a.stateNode===i){var d=Rg((i[Ke]||null).action),x=l.submitter;x&&(n=(n=x[Ke]||null)?Rg(n.formAction):x.getAttribute("formAction"),n!==null&&(d=n,x=null));var w=new ss("action","action",null,l,i);e.push({event:w,listeners:[{instance:null,listener:function(){if(l.defaultPrevented){if(hr!==0){var _=x?Ag(i,x):new FormData(i);Eu(a,{pending:!0,data:_,method:i.method,action:d},null,_)}}else typeof d=="function"&&(w.preventDefault(),_=x?Ag(i,x):new FormData(i),Eu(a,{pending:!0,data:_,method:i.method,action:d},d,_))},currentTarget:i}]})}}for(var rd=0;rd<qc.length;rd++){var od=qc[rd],hS=od.toLowerCase(),pS=od[0].toUpperCase()+od.slice(1);hn(hS,"on"+pS)}hn(sh,"onAnimationEnd"),hn(ih,"onAnimationIteration"),hn(ch,"onAnimationStart"),hn("dblclick","onDoubleClick"),hn("focusin","onFocus"),hn("focusout","onBlur"),hn(Ow,"onTransitionRun"),hn(Dw,"onTransitionStart"),hn(Mw,"onTransitionCancel"),hn(uh,"onTransitionEnd"),Or("onMouseEnter",["mouseout","mouseover"]),Or("onMouseLeave",["mouseout","mouseover"]),Or("onPointerEnter",["pointerout","pointerover"]),Or("onPointerLeave",["pointerout","pointerover"]),Wa("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Wa("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Wa("onBeforeInput",["compositionend","keypress","textInput","paste"]),Wa("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Wa("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Wa("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var vl="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(" "),gS=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(vl));function kg(e,n){n=(n&4)!==0;for(var a=0;a<e.length;a++){var l=e[a],i=l.event;l=l.listeners;e:{var d=void 0;if(n)for(var x=l.length-1;0<=x;x--){var w=l[x],_=w.instance,B=w.currentTarget;if(w=w.listener,_!==d&&i.isPropagationStopped())break e;d=w,i.currentTarget=B;try{d(i)}catch(X){Ds(X)}i.currentTarget=null,d=_}else for(x=0;x<l.length;x++){if(w=l[x],_=w.instance,B=w.currentTarget,w=w.listener,_!==d&&i.isPropagationStopped())break e;d=w,i.currentTarget=B;try{d(i)}catch(X){Ds(X)}i.currentTarget=null,d=_}}}}function Me(e,n){var a=n[Ar];a===void 0&&(a=n[Ar]=new Set);var l=e+"__bubble";a.has(l)||(_g(n,e,2,!1),a.add(l))}function ld(e,n,a){var l=0;n&&(l|=4),_g(a,e,l,n)}var Xs="_reactListening"+Math.random().toString(36).slice(2);function sd(e){if(!e[Xs]){e[Xs]=!0,Em.forEach(function(a){a!=="selectionchange"&&(gS.has(a)||ld(a,!1,e),ld(a,!0,e))});var n=e.nodeType===9?e:e.ownerDocument;n===null||n[Xs]||(n[Xs]=!0,ld("selectionchange",!1,n))}}function _g(e,n,a,l){switch(ev(n)){case 2:var i=VS;break;case 8:i=IS;break;default:i=wd}a=i.bind(null,n,a,e),i=void 0,!kc||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(i=!0),l?i!==void 0?e.addEventListener(n,a,{capture:!0,passive:i}):e.addEventListener(n,a,!0):i!==void 0?e.addEventListener(n,a,{passive:i}):e.addEventListener(n,a,!1)}function id(e,n,a,l,i){var d=l;if((n&1)===0&&(n&2)===0&&l!==null)e:for(;;){if(l===null)return;var x=l.tag;if(x===3||x===4){var w=l.stateNode.containerInfo;if(w===i)break;if(x===4)for(x=l.return;x!==null;){var _=x.tag;if((_===3||_===4)&&x.stateNode.containerInfo===i)return;x=x.return}for(;w!==null;){if(x=kr(w),x===null)return;if(_=x.tag,_===5||_===6||_===26||_===27){l=d=x;continue e}w=w.parentNode}}l=l.return}Um(function(){var B=d,X=Rc(a),Z=[];e:{var $=dh.get(e);if($!==void 0){var V=ss,Ee=e;switch(e){case"keypress":if(os(a)===0)break e;case"keydown":case"keyup":V=uw;break;case"focusin":Ee="focus",V=Dc;break;case"focusout":Ee="blur",V=Dc;break;case"beforeblur":case"afterblur":V=Dc;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":V=Pm;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":V=W1;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":V=mw;break;case sh:case ih:case ch:V=tw;break;case uh:V=pw;break;case"scroll":case"scrollend":V=Z1;break;case"wheel":V=vw;break;case"copy":case"cut":case"paste":V=aw;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":V=qm;break;case"toggle":case"beforetoggle":V=bw}var we=(n&4)!==0,Ye=!we&&(e==="scroll"||e==="scrollend"),M=we?$!==null?$+"Capture":null:$;we=[];for(var D=B,L;D!==null;){var K=D;if(L=K.stateNode,K=K.tag,K!==5&&K!==26&&K!==27||L===null||M===null||(K=Lo(D,M),K!=null&&we.push(yl(D,K,L))),Ye)break;D=D.return}0<we.length&&($=new V($,Ee,null,a,X),Z.push({event:$,listeners:we}))}}if((n&7)===0){e:{if($=e==="mouseover"||e==="pointerover",V=e==="mouseout"||e==="pointerout",$&&a!==Cc&&(Ee=a.relatedTarget||a.fromElement)&&(kr(Ee)||Ee[xt]))break e;if((V||$)&&($=X.window===X?X:($=X.ownerDocument)?$.defaultView||$.parentWindow:window,V?(Ee=a.relatedTarget||a.toElement,V=B,Ee=Ee?kr(Ee):null,Ee!==null&&(Ye=u(Ee),we=Ee.tag,Ee!==Ye||we!==5&&we!==27&&we!==6)&&(Ee=null)):(V=null,Ee=B),V!==Ee)){if(we=Pm,K="onMouseLeave",M="onMouseEnter",D="mouse",(e==="pointerout"||e==="pointerover")&&(we=qm,K="onPointerLeave",M="onPointerEnter",D="pointer"),Ye=V==null?$:zo(V),L=Ee==null?$:zo(Ee),$=new we(K,D+"leave",V,a,X),$.target=Ye,$.relatedTarget=L,K=null,kr(X)===B&&(we=new we(M,D+"enter",Ee,a,X),we.target=L,we.relatedTarget=Ye,K=we),Ye=K,V&&Ee)t:{for(we=V,M=Ee,D=0,L=we;L;L=co(L))D++;for(L=0,K=M;K;K=co(K))L++;for(;0<D-L;)we=co(we),D--;for(;0<L-D;)M=co(M),L--;for(;D--;){if(we===M||M!==null&&we===M.alternate)break t;we=co(we),M=co(M)}we=null}else we=null;V!==null&&jg(Z,$,V,we,!1),Ee!==null&&Ye!==null&&jg(Z,Ye,Ee,we,!0)}}e:{if($=B?zo(B):window,V=$.nodeName&&$.nodeName.toLowerCase(),V==="select"||V==="input"&&$.type==="file")var he=Zm;else if(Qm($))if(Fm)he=kw;else{he=Rw;var je=Cw}else V=$.nodeName,!V||V.toLowerCase()!=="input"||$.type!=="checkbox"&&$.type!=="radio"?B&&Nc(B.elementType)&&(he=Zm):he=Aw;if(he&&(he=he(e,B))){Km(Z,he,a,X);break e}je&&je(e,$,B),e==="focusout"&&B&&$.type==="number"&&B.memoizedProps.value!=null&&Tc($,"number",$.value)}switch(je=B?zo(B):window,e){case"focusin":(Qm(je)||je.contentEditable==="true")&&(Hr=je,Hc=B,Io=null);break;case"focusout":Io=Hc=Hr=null;break;case"mousedown":Pc=!0;break;case"contextmenu":case"mouseup":case"dragend":Pc=!1,oh(Z,a,X);break;case"selectionchange":if(jw)break;case"keydown":case"keyup":oh(Z,a,X)}var ye;if(zc)e:{switch(e){case"compositionstart":var Se="onCompositionStart";break e;case"compositionend":Se="onCompositionEnd";break e;case"compositionupdate":Se="onCompositionUpdate";break e}Se=void 0}else Br?Gm(e,a)&&(Se="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(Se="onCompositionStart");Se&&(Vm&&a.locale!=="ko"&&(Br||Se!=="onCompositionStart"?Se==="onCompositionEnd"&&Br&&(ye=Bm()):(ma=X,_c="value"in ma?ma.value:ma.textContent,Br=!0)),je=Qs(B,Se),0<je.length&&(Se=new $m(Se,e,null,a,X),Z.push({event:Se,listeners:je}),ye?Se.data=ye:(ye=Xm(a),ye!==null&&(Se.data=ye)))),(ye=ww?Sw(e,a):Ew(e,a))&&(Se=Qs(B,"onBeforeInput"),0<Se.length&&(je=new $m("onBeforeInput","beforeinput",null,a,X),Z.push({event:je,listeners:Se}),je.data=ye)),mS(Z,e,B,a,X)}kg(Z,n)})}function yl(e,n,a){return{instance:e,listener:n,currentTarget:a}}function Qs(e,n){for(var a=n+"Capture",l=[];e!==null;){var i=e,d=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||d===null||(i=Lo(e,a),i!=null&&l.unshift(yl(e,i,d)),i=Lo(e,n),i!=null&&l.push(yl(e,i,d))),e.tag===3)return l;e=e.return}return[]}function co(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function jg(e,n,a,l,i){for(var d=n._reactName,x=[];a!==null&&a!==l;){var w=a,_=w.alternate,B=w.stateNode;if(w=w.tag,_!==null&&_===l)break;w!==5&&w!==26&&w!==27||B===null||(_=B,i?(B=Lo(a,d),B!=null&&x.unshift(yl(a,B,_))):i||(B=Lo(a,d),B!=null&&x.push(yl(a,B,_)))),a=a.return}x.length!==0&&e.push({event:n,listeners:x})}var vS=/\r\n?/g,yS=/\u0000|\uFFFD/g;function Og(e){return(typeof e=="string"?e:""+e).replace(vS,`
50
+ `).replace(yS,"")}function Dg(e,n){return n=Og(n),Og(e)===n}function Ks(){}function Ie(e,n,a,l,i,d){switch(a){case"children":typeof l=="string"?n==="body"||n==="textarea"&&l===""||zr(e,l):(typeof l=="number"||typeof l=="bigint")&&n!=="body"&&zr(e,""+l);break;case"className":es(e,"class",l);break;case"tabIndex":es(e,"tabindex",l);break;case"dir":case"role":case"viewBox":case"width":case"height":es(e,a,l);break;case"style":zm(e,l,d);break;case"data":if(n!=="object"){es(e,"data",l);break}case"src":case"href":if(l===""&&(n!=="a"||a!=="href")){e.removeAttribute(a);break}if(l==null||typeof l=="function"||typeof l=="symbol"||typeof l=="boolean"){e.removeAttribute(a);break}l=as(""+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"?(n!=="input"&&Ie(e,n,"name",i.name,i,null),Ie(e,n,"formEncType",i.formEncType,i,null),Ie(e,n,"formMethod",i.formMethod,i,null),Ie(e,n,"formTarget",i.formTarget,i,null)):(Ie(e,n,"encType",i.encType,i,null),Ie(e,n,"method",i.method,i,null),Ie(e,n,"target",i.target,i,null)));if(l==null||typeof l=="symbol"||typeof l=="boolean"){e.removeAttribute(a);break}l=as(""+l),e.setAttribute(a,l);break;case"onClick":l!=null&&(e.onclick=Ks);break;case"onScroll":l!=null&&Me("scroll",e);break;case"onScrollEnd":l!=null&&Me("scrollend",e);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!="object"||!("__html"in l))throw Error(s(61));if(a=l.__html,a!=null){if(i.children!=null)throw Error(s(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=as(""+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":Me("beforetoggle",e),Me("toggle",e),Jl(e,"popover",l);break;case"xlinkActuate":$n(e,"http://www.w3.org/1999/xlink","xlink:actuate",l);break;case"xlinkArcrole":$n(e,"http://www.w3.org/1999/xlink","xlink:arcrole",l);break;case"xlinkRole":$n(e,"http://www.w3.org/1999/xlink","xlink:role",l);break;case"xlinkShow":$n(e,"http://www.w3.org/1999/xlink","xlink:show",l);break;case"xlinkTitle":$n(e,"http://www.w3.org/1999/xlink","xlink:title",l);break;case"xlinkType":$n(e,"http://www.w3.org/1999/xlink","xlink:type",l);break;case"xmlBase":$n(e,"http://www.w3.org/XML/1998/namespace","xml:base",l);break;case"xmlLang":$n(e,"http://www.w3.org/XML/1998/namespace","xml:lang",l);break;case"xmlSpace":$n(e,"http://www.w3.org/XML/1998/namespace","xml:space",l);break;case"is":Jl(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=Q1.get(a)||a,Jl(e,a,l))}}function cd(e,n,a,l,i,d){switch(a){case"style":zm(e,l,d);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!="object"||!("__html"in l))throw Error(s(61));if(a=l.__html,a!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=a}}break;case"children":typeof l=="string"?zr(e,l):(typeof l=="number"||typeof l=="bigint")&&zr(e,""+l);break;case"onScroll":l!=null&&Me("scroll",e);break;case"onScrollEnd":l!=null&&Me("scrollend",e);break;case"onClick":l!=null&&(e.onclick=Ks);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Tm.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(i=a.endsWith("Capture"),n=a.slice(2,i?a.length-7:void 0),d=e[Ke]||null,d=d!=null?d[a]:null,typeof d=="function"&&e.removeEventListener(n,d,i),typeof l=="function")){typeof d!="function"&&d!==null&&(a in e?e[a]=null:e.hasAttribute(a)&&e.removeAttribute(a)),e.addEventListener(n,l,i);break e}a in e?e[a]=l:l===!0?e.setAttribute(a,""):Jl(e,a,l)}}}function kt(e,n,a){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Me("error",e),Me("load",e);var l=!1,i=!1,d;for(d in a)if(a.hasOwnProperty(d)){var x=a[d];if(x!=null)switch(d){case"src":l=!0;break;case"srcSet":i=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s(137,n));default:Ie(e,n,d,x,a,null)}}i&&Ie(e,n,"srcSet",a.srcSet,a,null),l&&Ie(e,n,"src",a.src,a,null);return;case"input":Me("invalid",e);var w=d=x=i=null,_=null,B=null;for(l in a)if(a.hasOwnProperty(l)){var X=a[l];if(X!=null)switch(l){case"name":i=X;break;case"type":x=X;break;case"checked":_=X;break;case"defaultChecked":B=X;break;case"value":d=X;break;case"defaultValue":w=X;break;case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(s(137,n));break;default:Ie(e,n,l,X,a,null)}}jm(e,d,w,_,B,x,i,!1),ts(e);return;case"select":Me("invalid",e),l=x=d=null;for(i in a)if(a.hasOwnProperty(i)&&(w=a[i],w!=null))switch(i){case"value":d=w;break;case"defaultValue":x=w;break;case"multiple":l=w;default:Ie(e,n,i,w,a,null)}n=d,a=x,e.multiple=!!l,n!=null?Mr(e,!!l,n,!1):a!=null&&Mr(e,!!l,a,!0);return;case"textarea":Me("invalid",e),d=i=l=null;for(x in a)if(a.hasOwnProperty(x)&&(w=a[x],w!=null))switch(x){case"value":l=w;break;case"defaultValue":i=w;break;case"children":d=w;break;case"dangerouslySetInnerHTML":if(w!=null)throw Error(s(91));break;default:Ie(e,n,x,w,a,null)}Dm(e,l,i,d),ts(e);return;case"option":for(_ in a)a.hasOwnProperty(_)&&(l=a[_],l!=null)&&(_==="selected"?e.selected=l&&typeof l!="function"&&typeof l!="symbol":Ie(e,n,_,l,a,null));return;case"dialog":Me("beforetoggle",e),Me("toggle",e),Me("cancel",e),Me("close",e);break;case"iframe":case"object":Me("load",e);break;case"video":case"audio":for(l=0;l<vl.length;l++)Me(vl[l],e);break;case"image":Me("error",e),Me("load",e);break;case"details":Me("toggle",e);break;case"embed":case"source":case"link":Me("error",e),Me("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(B in a)if(a.hasOwnProperty(B)&&(l=a[B],l!=null))switch(B){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,n));default:Ie(e,n,B,l,a,null)}return;default:if(Nc(n)){for(X in a)a.hasOwnProperty(X)&&(l=a[X],l!==void 0&&cd(e,n,X,l,a,void 0));return}}for(w in a)a.hasOwnProperty(w)&&(l=a[w],l!=null&&Ie(e,n,w,l,a,null))}function bS(e,n,a,l){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var i=null,d=null,x=null,w=null,_=null,B=null,X=null;for(V in a){var Z=a[V];if(a.hasOwnProperty(V)&&Z!=null)switch(V){case"checked":break;case"value":break;case"defaultValue":_=Z;default:l.hasOwnProperty(V)||Ie(e,n,V,null,l,Z)}}for(var $ in l){var V=l[$];if(Z=a[$],l.hasOwnProperty($)&&(V!=null||Z!=null))switch($){case"type":d=V;break;case"name":i=V;break;case"checked":B=V;break;case"defaultChecked":X=V;break;case"value":x=V;break;case"defaultValue":w=V;break;case"children":case"dangerouslySetInnerHTML":if(V!=null)throw Error(s(137,n));break;default:V!==Z&&Ie(e,n,$,V,l,Z)}}Ec(e,x,w,_,B,X,d,i);return;case"select":V=x=w=$=null;for(d in a)if(_=a[d],a.hasOwnProperty(d)&&_!=null)switch(d){case"value":break;case"multiple":V=_;default:l.hasOwnProperty(d)||Ie(e,n,d,null,l,_)}for(i in l)if(d=l[i],_=a[i],l.hasOwnProperty(i)&&(d!=null||_!=null))switch(i){case"value":$=d;break;case"defaultValue":w=d;break;case"multiple":x=d;default:d!==_&&Ie(e,n,i,d,l,_)}n=w,a=x,l=V,$!=null?Mr(e,!!a,$,!1):!!l!=!!a&&(n!=null?Mr(e,!!a,n,!0):Mr(e,!!a,a?[]:"",!1));return;case"textarea":V=$=null;for(w in a)if(i=a[w],a.hasOwnProperty(w)&&i!=null&&!l.hasOwnProperty(w))switch(w){case"value":break;case"children":break;default:Ie(e,n,w,null,l,i)}for(x in l)if(i=l[x],d=a[x],l.hasOwnProperty(x)&&(i!=null||d!=null))switch(x){case"value":$=i;break;case"defaultValue":V=i;break;case"children":break;case"dangerouslySetInnerHTML":if(i!=null)throw Error(s(91));break;default:i!==d&&Ie(e,n,x,i,l,d)}Om(e,$,V);return;case"option":for(var Ee in a)$=a[Ee],a.hasOwnProperty(Ee)&&$!=null&&!l.hasOwnProperty(Ee)&&(Ee==="selected"?e.selected=!1:Ie(e,n,Ee,null,l,$));for(_ in l)$=l[_],V=a[_],l.hasOwnProperty(_)&&$!==V&&($!=null||V!=null)&&(_==="selected"?e.selected=$&&typeof $!="function"&&typeof $!="symbol":Ie(e,n,_,$,l,V));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 we in a)$=a[we],a.hasOwnProperty(we)&&$!=null&&!l.hasOwnProperty(we)&&Ie(e,n,we,null,l,$);for(B in l)if($=l[B],V=a[B],l.hasOwnProperty(B)&&$!==V&&($!=null||V!=null))switch(B){case"children":case"dangerouslySetInnerHTML":if($!=null)throw Error(s(137,n));break;default:Ie(e,n,B,$,l,V)}return;default:if(Nc(n)){for(var Ye in a)$=a[Ye],a.hasOwnProperty(Ye)&&$!==void 0&&!l.hasOwnProperty(Ye)&&cd(e,n,Ye,void 0,l,$);for(X in l)$=l[X],V=a[X],!l.hasOwnProperty(X)||$===V||$===void 0&&V===void 0||cd(e,n,X,$,l,V);return}}for(var M in a)$=a[M],a.hasOwnProperty(M)&&$!=null&&!l.hasOwnProperty(M)&&Ie(e,n,M,null,l,$);for(Z in l)$=l[Z],V=a[Z],!l.hasOwnProperty(Z)||$===V||$==null&&V==null||Ie(e,n,Z,$,l,V)}var ud=null,dd=null;function Zs(e){return e.nodeType===9?e:e.ownerDocument}function Mg(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 zg(e,n){if(e===0)switch(n){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&n==="foreignObject"?0:e}function fd(e,n){return e==="textarea"||e==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.children=="bigint"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var md=null;function xS(){var e=window.event;return e&&e.type==="popstate"?e===md?!1:(md=e,!0):(md=null,!1)}var Lg=typeof setTimeout=="function"?setTimeout:void 0,wS=typeof clearTimeout=="function"?clearTimeout:void 0,Ug=typeof Promise=="function"?Promise:void 0,SS=typeof queueMicrotask=="function"?queueMicrotask:typeof Ug<"u"?function(e){return Ug.resolve(null).then(e).catch(ES)}:Lg;function ES(e){setTimeout(function(){throw e})}function ka(e){return e==="head"}function Bg(e,n){var a=n,l=0,i=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 x=e.ownerDocument;if(a&1&&bl(x.documentElement),a&2&&bl(x.body),a&4)for(a=x.head,bl(a),x=a.firstChild;x;){var w=x.nextSibling,_=x.nodeName;x[Mo]||_==="SCRIPT"||_==="STYLE"||_==="LINK"&&x.rel.toLowerCase()==="stylesheet"||a.removeChild(x),x=w}}if(i===0){e.removeChild(d),Rl(n);return}i--}else a==="$"||a==="$?"||a==="$!"?i++:l=a.charCodeAt(0)-48;else l=0;a=d}while(a);Rl(n)}function hd(e){var n=e.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var a=n;switch(n=n.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":hd(a),bc(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}e.removeChild(a)}}function TS(e,n,a,l){for(;e.nodeType===1;){var i=a;if(e.nodeName.toLowerCase()!==n.toLowerCase()){if(!l&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(l){if(!e[Mo])switch(n){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!==i.rel||e.getAttribute("href")!==(i.href==null||i.href===""?null:i.href)||e.getAttribute("crossorigin")!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute("title")!==(i.title==null?null:i.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(d=e.getAttribute("src"),(d!==(i.src==null?null:i.src)||e.getAttribute("type")!==(i.type==null?null:i.type)||e.getAttribute("crossorigin")!==(i.crossOrigin==null?null:i.crossOrigin))&&d&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(n==="input"&&e.type==="hidden"){var d=i.name==null?null:""+i.name;if(i.type==="hidden"&&e.getAttribute("name")===d)return e}else return e;if(e=gn(e.nextSibling),e===null)break}return null}function NS(e,n,a){if(n==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=gn(e.nextSibling),e===null))return null;return e}function pd(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState==="complete"}function CS(e,n){var a=e.ownerDocument;if(e.data!=="$?"||a.readyState==="complete")n();else{var l=function(){n(),a.removeEventListener("DOMContentLoaded",l)};a.addEventListener("DOMContentLoaded",l),e._reactRetry=l}}function gn(e){for(;e!=null;e=e.nextSibling){var n=e.nodeType;if(n===1||n===3)break;if(n===8){if(n=e.data,n==="$"||n==="$!"||n==="$?"||n==="F!"||n==="F")break;if(n==="/$")return null}}return e}var gd=null;function Hg(e){e=e.previousSibling;for(var n=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"){if(n===0)return e;n--}else a==="/$"&&n++}e=e.previousSibling}return null}function Pg(e,n,a){switch(n=Zs(a),e){case"html":if(e=n.documentElement,!e)throw Error(s(452));return e;case"head":if(e=n.head,!e)throw Error(s(453));return e;case"body":if(e=n.body,!e)throw Error(s(454));return e;default:throw Error(s(451))}}function bl(e){for(var n=e.attributes;n.length;)e.removeAttributeNode(n[0]);bc(e)}var cn=new Map,$g=new Set;function Fs(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var ta=P.d;P.d={f:RS,r:AS,D:kS,C:_S,L:jS,m:OS,X:MS,S:DS,M:zS};function RS(){var e=ta.f(),n=qs();return e||n}function AS(e){var n=_r(e);n!==null&&n.tag===5&&n.type==="form"?sp(n):ta.r(e)}var uo=typeof document>"u"?null:document;function qg(e,n,a){var l=uo;if(l&&typeof n=="string"&&n){var i=tn(n);i='link[rel="'+e+'"][href="'+i+'"]',typeof a=="string"&&(i+='[crossorigin="'+a+'"]'),$g.has(i)||($g.add(i),e={rel:e,crossOrigin:a,href:n},l.querySelector(i)===null&&(n=l.createElement("link"),kt(n,"link",e),wt(n),l.head.appendChild(n)))}}function kS(e){ta.D(e),qg("dns-prefetch",e,null)}function _S(e,n){ta.C(e,n),qg("preconnect",e,n)}function jS(e,n,a){ta.L(e,n,a);var l=uo;if(l&&e&&n){var i='link[rel="preload"][as="'+tn(n)+'"]';n==="image"&&a&&a.imageSrcSet?(i+='[imagesrcset="'+tn(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(i+='[imagesizes="'+tn(a.imageSizes)+'"]')):i+='[href="'+tn(e)+'"]';var d=i;switch(n){case"style":d=fo(e);break;case"script":d=mo(e)}cn.has(d)||(e=b({rel:"preload",href:n==="image"&&a&&a.imageSrcSet?void 0:e,as:n},a),cn.set(d,e),l.querySelector(i)!==null||n==="style"&&l.querySelector(xl(d))||n==="script"&&l.querySelector(wl(d))||(n=l.createElement("link"),kt(n,"link",e),wt(n),l.head.appendChild(n)))}}function OS(e,n){ta.m(e,n);var a=uo;if(a&&e){var l=n&&typeof n.as=="string"?n.as:"script",i='link[rel="modulepreload"][as="'+tn(l)+'"][href="'+tn(e)+'"]',d=i;switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=mo(e)}if(!cn.has(d)&&(e=b({rel:"modulepreload",href:e},n),cn.set(d,e),a.querySelector(i)===null)){switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(wl(d)))return}l=a.createElement("link"),kt(l,"link",e),wt(l),a.head.appendChild(l)}}}function DS(e,n,a){ta.S(e,n,a);var l=uo;if(l&&e){var i=jr(l).hoistableStyles,d=fo(e);n=n||"default";var x=i.get(d);if(!x){var w={loading:0,preload:null};if(x=l.querySelector(xl(d)))w.loading=5;else{e=b({rel:"stylesheet",href:e,"data-precedence":n},a),(a=cn.get(d))&&vd(e,a);var _=x=l.createElement("link");wt(_),kt(_,"link",e),_._p=new Promise(function(B,X){_.onload=B,_.onerror=X}),_.addEventListener("load",function(){w.loading|=1}),_.addEventListener("error",function(){w.loading|=2}),w.loading|=4,Ws(x,n,l)}x={type:"stylesheet",instance:x,count:1,state:w},i.set(d,x)}}}function MS(e,n){ta.X(e,n);var a=uo;if(a&&e){var l=jr(a).hoistableScripts,i=mo(e),d=l.get(i);d||(d=a.querySelector(wl(i)),d||(e=b({src:e,async:!0},n),(n=cn.get(i))&&yd(e,n),d=a.createElement("script"),wt(d),kt(d,"link",e),a.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},l.set(i,d))}}function zS(e,n){ta.M(e,n);var a=uo;if(a&&e){var l=jr(a).hoistableScripts,i=mo(e),d=l.get(i);d||(d=a.querySelector(wl(i)),d||(e=b({src:e,async:!0,type:"module"},n),(n=cn.get(i))&&yd(e,n),d=a.createElement("script"),wt(d),kt(d,"link",e),a.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},l.set(i,d))}}function Vg(e,n,a,l){var i=(i=ae.current)?Fs(i):null;if(!i)throw Error(s(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(n=fo(a.href),a=jr(i).hoistableStyles,l=a.get(n),l||(l={type:"style",instance:null,count:0,state:null},a.set(n,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=fo(a.href);var d=jr(i).hoistableStyles,x=d.get(e);if(x||(i=i.ownerDocument||i,x={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,x),(d=i.querySelector(xl(e)))&&!d._p&&(x.instance=d,x.state.loading=5),cn.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},cn.set(e,a),d||LS(i,e,a,x.state))),n&&l===null)throw Error(s(528,""));return x}if(n&&l!==null)throw Error(s(529,""));return null;case"script":return n=a.async,a=a.src,typeof a=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=mo(a),a=jr(i).hoistableScripts,l=a.get(n),l||(l={type:"script",instance:null,count:0,state:null},a.set(n,l)),l):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,e))}}function fo(e){return'href="'+tn(e)+'"'}function xl(e){return'link[rel="stylesheet"]['+e+"]"}function Ig(e){return b({},e,{"data-precedence":e.precedence,precedence:null})}function LS(e,n,a,l){e.querySelector('link[rel="preload"][as="style"]['+n+"]")?l.loading=1:(n=e.createElement("link"),l.preload=n,n.addEventListener("load",function(){return l.loading|=1}),n.addEventListener("error",function(){return l.loading|=2}),kt(n,"link",a),wt(n),e.head.appendChild(n))}function mo(e){return'[src="'+tn(e)+'"]'}function wl(e){return"script[async]"+e}function Yg(e,n,a){if(n.count++,n.instance===null)switch(n.type){case"style":var l=e.querySelector('style[data-href~="'+tn(a.href)+'"]');if(l)return n.instance=l,wt(l),l;var i=b({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return l=(e.ownerDocument||e).createElement("style"),wt(l),kt(l,"style",i),Ws(l,a.precedence,e),n.instance=l;case"stylesheet":i=fo(a.href);var d=e.querySelector(xl(i));if(d)return n.state.loading|=4,n.instance=d,wt(d),d;l=Ig(a),(i=cn.get(i))&&vd(l,i),d=(e.ownerDocument||e).createElement("link"),wt(d);var x=d;return x._p=new Promise(function(w,_){x.onload=w,x.onerror=_}),kt(d,"link",l),n.state.loading|=4,Ws(d,a.precedence,e),n.instance=d;case"script":return d=mo(a.src),(i=e.querySelector(wl(d)))?(n.instance=i,wt(i),i):(l=a,(i=cn.get(d))&&(l=b({},a),yd(l,i)),e=e.ownerDocument||e,i=e.createElement("script"),wt(i),kt(i,"link",l),e.head.appendChild(i),n.instance=i);case"void":return null;default:throw Error(s(443,n.type))}else n.type==="stylesheet"&&(n.state.loading&4)===0&&(l=n.instance,n.state.loading|=4,Ws(l,a.precedence,e));return n.instance}function Ws(e,n,a){for(var l=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),i=l.length?l[l.length-1]:null,d=i,x=0;x<l.length;x++){var w=l[x];if(w.dataset.precedence===n)d=w;else if(d!==i)break}d?d.parentNode.insertBefore(e,d.nextSibling):(n=a.nodeType===9?a.head:a,n.insertBefore(e,n.firstChild))}function vd(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.title==null&&(e.title=n.title)}function yd(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.integrity==null&&(e.integrity=n.integrity)}var Js=null;function Gg(e,n,a){if(Js===null){var l=new Map,i=Js=new Map;i.set(a,l)}else i=Js,l=i.get(a),l||(l=new Map,i.set(a,l));if(l.has(e))return l;for(l.set(e,null),a=a.getElementsByTagName(e),i=0;i<a.length;i++){var d=a[i];if(!(d[Mo]||d[ct]||e==="link"&&d.getAttribute("rel")==="stylesheet")&&d.namespaceURI!=="http://www.w3.org/2000/svg"){var x=d.getAttribute(n)||"";x=e+x;var w=l.get(x);w?w.push(d):l.set(x,[d])}}return l}function Xg(e,n,a){e=e.ownerDocument||e,e.head.insertBefore(a,n==="title"?e.querySelector("head > title"):null)}function US(e,n,a){if(a===1||n.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof n.precedence!="string"||typeof n.href!="string"||n.href==="")break;return!0;case"link":if(typeof n.rel!="string"||typeof n.href!="string"||n.href===""||n.onLoad||n.onError)break;return n.rel==="stylesheet"?(e=n.disabled,typeof n.precedence=="string"&&e==null):!0;case"script":if(n.async&&typeof n.async!="function"&&typeof n.async!="symbol"&&!n.onLoad&&!n.onError&&n.src&&typeof n.src=="string")return!0}return!1}function Qg(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}var Sl=null;function BS(){}function HS(e,n,a){if(Sl===null)throw Error(s(475));var l=Sl;if(n.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(n.state.loading&4)===0){if(n.instance===null){var i=fo(a.href),d=e.querySelector(xl(i));if(d){e=d._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(l.count++,l=ei.bind(l),e.then(l,l)),n.state.loading|=4,n.instance=d,wt(d);return}d=e.ownerDocument||e,a=Ig(a),(i=cn.get(i))&&vd(a,i),d=d.createElement("link"),wt(d);var x=d;x._p=new Promise(function(w,_){x.onload=w,x.onerror=_}),kt(d,"link",a),n.instance=d}l.stylesheets===null&&(l.stylesheets=new Map),l.stylesheets.set(n,e),(e=n.state.preload)&&(n.state.loading&3)===0&&(l.count++,n=ei.bind(l),e.addEventListener("load",n),e.addEventListener("error",n))}}function PS(){if(Sl===null)throw Error(s(475));var e=Sl;return e.stylesheets&&e.count===0&&bd(e,e.stylesheets),0<e.count?function(n){var a=setTimeout(function(){if(e.stylesheets&&bd(e,e.stylesheets),e.unsuspend){var l=e.unsuspend;e.unsuspend=null,l()}},6e4);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(a)}}:null}function ei(){if(this.count--,this.count===0){if(this.stylesheets)bd(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var ti=null;function bd(e,n){e.stylesheets=null,e.unsuspend!==null&&(e.count++,ti=new Map,n.forEach($S,e),ti=null,ei.call(e))}function $S(e,n){if(!(n.state.loading&4)){var a=ti.get(e);if(a)var l=a.get(null);else{a=new Map,ti.set(e,a);for(var i=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d<i.length;d++){var x=i[d];(x.nodeName==="LINK"||x.getAttribute("media")!=="not all")&&(a.set(x.dataset.precedence,x),l=x)}l&&a.set(null,l)}i=n.instance,x=i.getAttribute("data-precedence"),d=a.get(x)||l,d===l&&a.set(null,i),a.set(x,i),this.count++,l=ei.bind(this),i.addEventListener("load",l),i.addEventListener("error",l),d?d.parentNode.insertBefore(i,d.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),n.state.loading|=4}}var El={$$typeof:O,Provider:null,Consumer:null,_currentValue:H,_currentValue2:H,_threadCount:0};function qS(e,n,a,l,i,d,x,w){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=Za(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Za(0),this.hiddenUpdates=Za(null),this.identifierPrefix=l,this.onUncaughtError=i,this.onCaughtError=d,this.onRecoverableError=x,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=w,this.incompleteTransitions=new Map}function Kg(e,n,a,l,i,d,x,w,_,B,X,Z){return e=new qS(e,n,a,x,w,_,B,Z),n=1,d===!0&&(n|=24),d=Vt(3,null,null,n),e.current=d,d.stateNode=e,n=eu(),n.refCount++,e.pooledCache=n,n.refCount++,d.memoizedState={element:l,isDehydrated:a,cache:n},ru(d),e}function Zg(e){return e?(e=Vr,e):Vr}function Fg(e,n,a,l,i,d){i=Zg(i),l.context===null?l.context=i:l.pendingContext=i,l=ga(n),l.payload={element:a},d=d===void 0?null:d,d!==null&&(l.callback=d),a=va(e,l,n),a!==null&&(Qt(a,e,n),Jo(a,e,n))}function Wg(e,n){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<n?a:n}}function xd(e,n){Wg(e,n),(e=e.alternate)&&Wg(e,n)}function Jg(e){if(e.tag===13){var n=qr(e,67108864);n!==null&&Qt(n,e,67108864),xd(e,67108864)}}var ni=!0;function VS(e,n,a,l){var i=j.T;j.T=null;var d=P.p;try{P.p=2,wd(e,n,a,l)}finally{P.p=d,j.T=i}}function IS(e,n,a,l){var i=j.T;j.T=null;var d=P.p;try{P.p=8,wd(e,n,a,l)}finally{P.p=d,j.T=i}}function wd(e,n,a,l){if(ni){var i=Sd(l);if(i===null)id(e,n,l,ai,a),tv(e,l);else if(GS(i,e,n,a,l))l.stopPropagation();else if(tv(e,l),n&4&&-1<YS.indexOf(e)){for(;i!==null;){var d=_r(i);if(d!==null)switch(d.tag){case 3:if(d=d.stateNode,d.current.memoizedState.isDehydrated){var x=Jt(d.pendingLanes);if(x!==0){var w=d;for(w.pendingLanes|=2,w.entangledLanes|=2;x;){var _=1<<31-We(x);w.entanglements[1]|=_,x&=~_}jn(d),($e&6)===0&&(Ps=lt()+500,gl(0))}}break;case 13:w=qr(d,2),w!==null&&Qt(w,d,2),qs(),xd(d,2)}if(d=Sd(l),d===null&&id(e,n,l,ai,a),d===i)break;i=d}i!==null&&l.stopPropagation()}else id(e,n,l,null,a)}}function Sd(e){return e=Rc(e),Ed(e)}var ai=null;function Ed(e){if(ai=null,e=kr(e),e!==null){var n=u(e);if(n===null)e=null;else{var a=n.tag;if(a===13){if(e=m(n),e!==null)return e;e=null}else if(a===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;e=null}else n!==e&&(e=null)}}return ai=e,null}function ev(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(Qa()){case ht:return 2;case Nr:return 8;case Un:case st:return 32;case mn:return 268435456;default:return 32}default:return 32}}var Td=!1,_a=null,ja=null,Oa=null,Tl=new Map,Nl=new Map,Da=[],YS="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 tv(e,n){switch(e){case"focusin":case"focusout":_a=null;break;case"dragenter":case"dragleave":ja=null;break;case"mouseover":case"mouseout":Oa=null;break;case"pointerover":case"pointerout":Tl.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":Nl.delete(n.pointerId)}}function Cl(e,n,a,l,i,d){return e===null||e.nativeEvent!==d?(e={blockedOn:n,domEventName:a,eventSystemFlags:l,nativeEvent:d,targetContainers:[i]},n!==null&&(n=_r(n),n!==null&&Jg(n)),e):(e.eventSystemFlags|=l,n=e.targetContainers,i!==null&&n.indexOf(i)===-1&&n.push(i),e)}function GS(e,n,a,l,i){switch(n){case"focusin":return _a=Cl(_a,e,n,a,l,i),!0;case"dragenter":return ja=Cl(ja,e,n,a,l,i),!0;case"mouseover":return Oa=Cl(Oa,e,n,a,l,i),!0;case"pointerover":var d=i.pointerId;return Tl.set(d,Cl(Tl.get(d)||null,e,n,a,l,i)),!0;case"gotpointercapture":return d=i.pointerId,Nl.set(d,Cl(Nl.get(d)||null,e,n,a,l,i)),!0}return!1}function nv(e){var n=kr(e.target);if(n!==null){var a=u(n);if(a!==null){if(n=a.tag,n===13){if(n=m(a),n!==null){e.blockedOn=n,gt(e.priority,function(){if(a.tag===13){var l=Xt();l=Qe(l);var i=qr(a,l);i!==null&&Qt(i,a,l),xd(a,l)}});return}}else if(n===3&&a.stateNode.current.memoizedState.isDehydrated){e.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ri(e){if(e.blockedOn!==null)return!1;for(var n=e.targetContainers;0<n.length;){var a=Sd(e.nativeEvent);if(a===null){a=e.nativeEvent;var l=new a.constructor(a.type,a);Cc=l,a.target.dispatchEvent(l),Cc=null}else return n=_r(a),n!==null&&Jg(n),e.blockedOn=a,!1;n.shift()}return!0}function av(e,n,a){ri(e)&&a.delete(n)}function XS(){Td=!1,_a!==null&&ri(_a)&&(_a=null),ja!==null&&ri(ja)&&(ja=null),Oa!==null&&ri(Oa)&&(Oa=null),Tl.forEach(av),Nl.forEach(av)}function oi(e,n){e.blockedOn===n&&(e.blockedOn=null,Td||(Td=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,XS)))}var li=null;function rv(e){li!==e&&(li=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){li===e&&(li=null);for(var n=0;n<e.length;n+=3){var a=e[n],l=e[n+1],i=e[n+2];if(typeof l!="function"){if(Ed(l||a)===null)continue;break}var d=_r(a);d!==null&&(e.splice(n,3),n-=3,Eu(d,{pending:!0,data:i,method:a.method,action:l},l,i))}}))}function Rl(e){function n(_){return oi(_,e)}_a!==null&&oi(_a,e),ja!==null&&oi(ja,e),Oa!==null&&oi(Oa,e),Tl.forEach(n),Nl.forEach(n);for(var a=0;a<Da.length;a++){var l=Da[a];l.blockedOn===e&&(l.blockedOn=null)}for(;0<Da.length&&(a=Da[0],a.blockedOn===null);)nv(a),a.blockedOn===null&&Da.shift();if(a=(e.ownerDocument||e).$$reactFormReplay,a!=null)for(l=0;l<a.length;l+=3){var i=a[l],d=a[l+1],x=i[Ke]||null;if(typeof d=="function")x||rv(a);else if(x){var w=null;if(d&&d.hasAttribute("formAction")){if(i=d,x=d[Ke]||null)w=x.formAction;else if(Ed(i)!==null)continue}else w=x.action;typeof w=="function"?a[l+1]=w:(a.splice(l,3),l-=3),rv(a)}}}function Nd(e){this._internalRoot=e}si.prototype.render=Nd.prototype.render=function(e){var n=this._internalRoot;if(n===null)throw Error(s(409));var a=n.current,l=Xt();Fg(a,l,e,n,null,null)},si.prototype.unmount=Nd.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var n=e.containerInfo;Fg(e.current,2,null,e,null,null),qs(),n[xt]=null}};function si(e){this._internalRoot=e}si.prototype.unstable_scheduleHydration=function(e){if(e){var n=Fa();e={blockedOn:null,target:e,priority:n};for(var a=0;a<Da.length&&n!==0&&n<Da[a].priority;a++);Da.splice(a,0,e),a===0&&nv(e)}};var ov=r.version;if(ov!=="19.1.0")throw Error(s(527,ov,"19.1.0"));P.findDOMNode=function(e){var n=e._reactInternals;if(n===void 0)throw typeof e.render=="function"?Error(s(188)):(e=Object.keys(e).join(","),Error(s(268,e)));return e=v(n),e=e!==null?p(e):null,e=e===null?null:e.stateNode,e};var QS={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:j,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ii=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ii.isDisabled&&ii.supportsFiber)try{$t=ii.inject(QS),Ct=ii}catch{}}return kl.createRoot=function(e,n){if(!c(e))throw Error(s(299));var a=!1,l="",i=wp,d=Sp,x=Ep,w=null;return n!=null&&(n.unstable_strictMode===!0&&(a=!0),n.identifierPrefix!==void 0&&(l=n.identifierPrefix),n.onUncaughtError!==void 0&&(i=n.onUncaughtError),n.onCaughtError!==void 0&&(d=n.onCaughtError),n.onRecoverableError!==void 0&&(x=n.onRecoverableError),n.unstable_transitionCallbacks!==void 0&&(w=n.unstable_transitionCallbacks)),n=Kg(e,1,!1,null,null,a,l,i,d,x,w,null),e[xt]=n.current,sd(e),new Nd(n)},kl.hydrateRoot=function(e,n,a){if(!c(e))throw Error(s(299));var l=!1,i="",d=wp,x=Sp,w=Ep,_=null,B=null;return a!=null&&(a.unstable_strictMode===!0&&(l=!0),a.identifierPrefix!==void 0&&(i=a.identifierPrefix),a.onUncaughtError!==void 0&&(d=a.onUncaughtError),a.onCaughtError!==void 0&&(x=a.onCaughtError),a.onRecoverableError!==void 0&&(w=a.onRecoverableError),a.unstable_transitionCallbacks!==void 0&&(_=a.unstable_transitionCallbacks),a.formState!==void 0&&(B=a.formState)),n=Kg(e,1,!0,n,a??null,l,i,d,x,w,_,B),n.context=Zg(null),a=n.current,l=Xt(),l=Qe(l),i=ga(l),i.callback=null,va(a,i,l),a=l,n.current.lanes=a,be(n,a),jn(n),e[xt]=n.current,sd(e),new si(n)},kl.version="19.1.0",kl}var pv;function r2(){if(pv)return Ad.exports;pv=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(r){console.error(r)}}return t(),Ad.exports=a2(),Ad.exports}var o2=r2();const l2="modulepreload",s2=function(t){return"/"+t},gv={},Ry=function(r,o,s){let c=Promise.resolve();if(o&&o.length>0){let m=function(p){return Promise.all(p.map(b=>Promise.resolve(b).then(y=>({status:"fulfilled",value:y}),y=>({status:"rejected",reason:y}))))};document.getElementsByTagName("link");const h=document.querySelector("meta[property=csp-nonce]"),v=h?.nonce||h?.getAttribute("nonce");c=m(o.map(p=>{if(p=s2(p),p in gv)return;gv[p]=!0;const b=p.endsWith(".css"),y=b?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${y}`))return;const S=document.createElement("link");if(S.rel=b?"stylesheet":l2,b||(S.as="script"),S.crossOrigin="",S.href=p,v&&S.setAttribute("nonce",v),document.head.appendChild(S),b)return new Promise((A,C)=>{S.addEventListener("load",A),S.addEventListener("error",()=>C(new Error(`Unable to preload CSS for ${p}`)))})}))}function u(m){const h=new Event("vite:preloadError",{cancelable:!0});if(h.payload=m,window.dispatchEvent(h),!h.defaultPrevented)throw m}return c.then(m=>{for(const h of m||[])h.status==="rejected"&&u(h.reason);return r().catch(u)})};/**
51
+ * react-router v7.18.0
52
+ *
53
+ * Copyright (c) Remix Software Inc.
54
+ *
55
+ * This source code is licensed under the MIT license found in the
56
+ * LICENSE.md file in the root directory of this source tree.
57
+ *
58
+ * @license MIT
59
+ */var Mf=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,Ay=/^[\\/]{2}/;function i2(t,r){return r+t.replace(/\\/g,"/")}var vv="popstate";function yv(t){return typeof t=="object"&&t!=null&&"pathname"in t&&"search"in t&&"hash"in t&&"state"in t&&"key"in t}function c2(t={}){function r(s,c){let u=c.state?.masked,{pathname:m,search:h,hash:v}=u||s.location;return nf("",{pathname:m,search:h,hash:v},c.state&&c.state.usr||null,c.state&&c.state.key||"default",u?{pathname:s.location.pathname,search:s.location.search,hash:s.location.hash}:void 0)}function o(s,c){return typeof c=="string"?c:Hl(c)}return d2(r,o,null,t)}function tt(t,r){if(t===!1||t===null||typeof t>"u")throw new Error(r)}function bn(t,r){if(!t){typeof console<"u"&&console.warn(r);try{throw new Error(r)}catch{}}}function u2(){return Math.random().toString(36).substring(2,10)}function bv(t,r){return{usr:t.state,key:t.key,idx:r,masked:t.mask?{pathname:t.pathname,search:t.search,hash:t.hash}:void 0}}function nf(t,r,o=null,s,c){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof r=="string"?Co(r):r,state:o,key:r&&r.key||s||u2(),mask:c}}function Hl({pathname:t="/",search:r="",hash:o=""}){return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),o&&o!=="#"&&(t+=o.charAt(0)==="#"?o:"#"+o),t}function Co(t){let r={};if(t){let o=t.indexOf("#");o>=0&&(r.hash=t.substring(o),t=t.substring(0,o));let s=t.indexOf("?");s>=0&&(r.search=t.substring(s),t=t.substring(0,s)),t&&(r.pathname=t)}return r}function d2(t,r,o,s={}){let{window:c=document.defaultView,v5Compat:u=!1}=s,m=c.history,h="POP",v=null,p=b();p==null&&(p=0,m.replaceState({...m.state,idx:p},""));function b(){return(m.state||{idx:null}).idx}function y(){h="POP";let E=b(),R=E==null?null:E-p;p=E,v&&v({action:h,location:T.location,delta:R})}function S(E,R){h="PUSH";let k=yv(E)?E:nf(T.location,E,R);p=b()+1;let O=bv(k,p),U=T.createHref(k.mask||k);try{m.pushState(O,"",U)}catch(z){if(z instanceof DOMException&&z.name==="DataCloneError")throw z;c.location.assign(U)}u&&v&&v({action:h,location:T.location,delta:1})}function A(E,R){h="REPLACE";let k=yv(E)?E:nf(T.location,E,R);p=b();let O=bv(k,p),U=T.createHref(k.mask||k);m.replaceState(O,"",U),u&&v&&v({action:h,location:T.location,delta:0})}function C(E){return f2(c,E)}let T={get action(){return h},get location(){return t(c,m)},listen(E){if(v)throw new Error("A history only accepts one active listener");return c.addEventListener(vv,y),v=E,()=>{c.removeEventListener(vv,y),v=null}},createHref(E){return r(c,E)},createURL:C,encodeLocation(E){let R=C(E);return{pathname:R.pathname,search:R.search,hash:R.hash}},push:S,replace:A,go(E){return m.go(E)}};return T}function f2(t,r,o=!1){let s="http://localhost";t&&(s=t.location.origin!=="null"?t.location.origin:t.location.href),tt(s,"No window.location.(origin|href) available to create URL");let c=typeof r=="string"?r:Hl(r);return c=c.replace(/ $/,"%20"),!o&&Ay.test(c)&&(c=s+c),new URL(c,s)}function ky(t,r,o="/"){return m2(t,r,o,!1)}function m2(t,r,o,s,c){let u=typeof r=="string"?Co(r):r,m=ra(u.pathname||"/",o);if(m==null)return null;let h=h2(t),v=null,p=N2(m);for(let b=0;v==null&&b<h.length;++b)v=T2(h[b],p,s);return v}function h2(t){let r=_y(t);return p2(r),r}function _y(t,r=[],o=[],s="",c=!1){let u=(m,h,v=c,p)=>{let b={relativePath:p===void 0?m.path||"":p,caseSensitive:m.caseSensitive===!0,childrenIndex:h,route:m};if(b.relativePath.startsWith("/")){if(!b.relativePath.startsWith(s)&&v)return;tt(b.relativePath.startsWith(s),`Absolute route path "${b.relativePath}" nested under path "${s}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),b.relativePath=b.relativePath.slice(s.length)}let y=yn([s,b.relativePath]),S=o.concat(b);m.children&&m.children.length>0&&(tt(m.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${y}".`),_y(m.children,r,S,y,v)),!(m.path==null&&!m.index)&&r.push({path:y,score:S2(y,m.index),routesMeta:S.map((A,C)=>{let[T,E]=Dy(A.relativePath,A.caseSensitive,C===S.length-1);return{...A,matcher:T,compiledParams:E}})})};return t.forEach((m,h)=>{if(m.path===""||!m.path?.includes("?"))u(m,h);else for(let v of jy(m.path))u(m,h,!0,v)}),r}function jy(t){let r=t.split("/");if(r.length===0)return[];let[o,...s]=r,c=o.endsWith("?"),u=o.replace(/\?$/,"");if(s.length===0)return c?[u,""]:[u];let m=jy(s.join("/")),h=[];return h.push(...m.map(v=>v===""?u:[u,v].join("/"))),c&&h.push(...m),h.map(v=>t.startsWith("/")&&v===""?"/":v)}function p2(t){t.sort((r,o)=>r.score!==o.score?o.score-r.score:E2(r.routesMeta.map(s=>s.childrenIndex),o.routesMeta.map(s=>s.childrenIndex)))}var g2=/^:[\w-]+$/,v2=3,y2=2,b2=1,x2=10,w2=-2,xv=t=>t==="*";function S2(t,r){let o=t.split("/"),s=o.length;return o.some(xv)&&(s+=w2),r&&(s+=y2),o.filter(c=>!xv(c)).reduce((c,u)=>c+(g2.test(u)?v2:u===""?b2:x2),s)}function E2(t,r){return t.length===r.length&&t.slice(0,-1).every((s,c)=>s===r[c])?t[t.length-1]-r[r.length-1]:0}function T2(t,r,o=!1){let{routesMeta:s}=t,c={},u="/",m=[];for(let h=0;h<s.length;++h){let v=s[h],p=h===s.length-1,b=u==="/"?r:r.slice(u.length)||"/",y={path:v.relativePath,caseSensitive:v.caseSensitive,end:p},S=v.matcher&&v.compiledParams?Oy(y,b,v.matcher,v.compiledParams):_i(y,b),A=v.route;if(!S&&p&&o&&!s[s.length-1].route.index&&(S=_i({path:v.relativePath,caseSensitive:v.caseSensitive,end:!1},b)),!S)return null;Object.assign(c,S.params),m.push({params:c,pathname:yn([u,S.pathname]),pathnameBase:A2(yn([u,S.pathnameBase])),route:A}),S.pathnameBase!=="/"&&(u=yn([u,S.pathnameBase]))}return m}function _i(t,r){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[o,s]=Dy(t.path,t.caseSensitive,t.end);return Oy(t,r,o,s)}function Oy(t,r,o,s){let c=r.match(o);if(!c)return null;let u=c[0],m=u.replace(/(.)\/+$/,"$1"),h=c.slice(1);return{params:s.reduce((p,{paramName:b,isOptional:y},S)=>{if(b==="*"){let C=h[S]||"";m=u.slice(0,u.length-C.length).replace(/(.)\/+$/,"$1")}const A=h[S];return y&&!A?p[b]=void 0:p[b]=(A||"").replace(/%2F/g,"/"),p},{}),pathname:u,pathnameBase:m,pattern:t}}function Dy(t,r=!1,o=!0){bn(t==="*"||!t.endsWith("*")||t.endsWith("/*"),`Route path "${t}" will be treated as if it were "${t.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${t.replace(/\*$/,"/*")}".`);let s=[],c="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(m,h,v,p,b)=>{if(s.push({paramName:h,isOptional:v!=null}),v){let y=b.charAt(p+m.length);return y&&y!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return t.endsWith("*")?(s.push({paramName:"*"}),c+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):o?c+="\\/*$":t!==""&&t!=="/"&&(c+="(?:(?=\\/|$))"),[new RegExp(c,r?void 0:"i"),s]}function N2(t){try{return t.split("/").map(r=>decodeURIComponent(r).replace(/\//g,"%2F")).join("/")}catch(r){return bn(!1,`The URL path "${t}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${r}).`),t}}function ra(t,r){if(r==="/")return t;if(!t.toLowerCase().startsWith(r.toLowerCase()))return null;let o=r.endsWith("/")?r.length-1:r.length,s=t.charAt(o);return s&&s!=="/"?null:t.slice(o)||"/"}function C2(t,r="/"){let{pathname:o,search:s="",hash:c=""}=typeof t=="string"?Co(t):t,u;return o?(o=My(o),o.startsWith("/")?u=wv(o.substring(1),"/"):u=wv(o,r)):u=r,{pathname:u,search:k2(s),hash:_2(c)}}function wv(t,r){let o=ji(r).split("/");return t.split("/").forEach(c=>{c===".."?o.length>1&&o.pop():c!=="."&&o.push(c)}),o.length>1?o.join("/"):"/"}function Od(t,r,o,s){return`Cannot include a '${t}' character in a manually specified \`to.${r}\` field [${JSON.stringify(s)}]. Please separate it out to the \`to.${o}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function R2(t){return t.filter((r,o)=>o===0||r.route.path&&r.route.path.length>0)}function zf(t){let r=R2(t);return r.map((o,s)=>s===r.length-1?o.pathname:o.pathnameBase)}function tc(t,r,o,s=!1){let c;typeof t=="string"?c=Co(t):(c={...t},tt(!c.pathname||!c.pathname.includes("?"),Od("?","pathname","search",c)),tt(!c.pathname||!c.pathname.includes("#"),Od("#","pathname","hash",c)),tt(!c.search||!c.search.includes("#"),Od("#","search","hash",c)));let u=t===""||c.pathname==="",m=u?"/":c.pathname,h;if(m==null)h=o;else{let y=r.length-1;if(!s&&m.startsWith("..")){let S=m.split("/");for(;S[0]==="..";)S.shift(),y-=1;c.pathname=S.join("/")}h=y>=0?r[y]:"/"}let v=C2(c,h),p=m&&m!=="/"&&m.endsWith("/"),b=(u||m===".")&&o.endsWith("/");return!v.pathname.endsWith("/")&&(p||b)&&(v.pathname+="/"),v}var My=t=>t.replace(/[\\/]{2,}/g,"/"),yn=t=>My(t.join("/")),ji=t=>t.replace(/\/+$/,""),A2=t=>ji(t).replace(/^\/*/,"/"),k2=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,_2=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t,j2=class{constructor(t,r,o,s=!1){this.status=t,this.statusText=r||"",this.internal=s,o instanceof Error?(this.data=o.toString(),this.error=o):this.data=o}};function O2(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}function D2(t){let r=t.map(o=>o.route.path).filter(Boolean);return yn(r)||"/"}var zy=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Ly(t,r){let o=t;if(typeof o!="string"||!Mf.test(o))return{absoluteURL:void 0,isExternal:!1,to:o};let s=o,c=!1;if(zy)try{let u=new URL(window.location.href),m=Ay.test(o)?new URL(i2(o,u.protocol)):new URL(o),h=ra(m.pathname,r);m.origin===u.origin&&h!=null?o=h+m.search+m.hash:c=!0}catch{bn(!1,`<Link to="${o}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:s,isExternal:c,to:o}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Uy=["POST","PUT","PATCH","DELETE"];new Set(Uy);var M2=["GET",...Uy];new Set(M2);var z2=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function L2(t){try{return z2.includes(new URL(t).protocol)}catch{return!1}}var Ro=g.createContext(null);Ro.displayName="DataRouter";var nc=g.createContext(null);nc.displayName="DataRouterState";var By=g.createContext(!1);function U2(){return g.useContext(By)}var Hy=g.createContext({isTransitioning:!1});Hy.displayName="ViewTransition";var B2=g.createContext(new Map);B2.displayName="Fetchers";var H2=g.createContext(null);H2.displayName="Await";var Wt=g.createContext(null);Wt.displayName="Navigation";var Ql=g.createContext(null);Ql.displayName="Location";var un=g.createContext({outlet:null,matches:[],isDataRoute:!1});un.displayName="Route";var Lf=g.createContext(null);Lf.displayName="RouteError";var Py="REACT_ROUTER_ERROR",P2="REDIRECT",$2="ROUTE_ERROR_RESPONSE";function q2(t){if(t.startsWith(`${Py}:${P2}:{`))try{let r=JSON.parse(t.slice(28));if(typeof r=="object"&&r&&typeof r.status=="number"&&typeof r.statusText=="string"&&typeof r.location=="string"&&typeof r.reloadDocument=="boolean"&&typeof r.replace=="boolean")return r}catch{}}function V2(t){if(t.startsWith(`${Py}:${$2}:{`))try{let r=JSON.parse(t.slice(40));if(typeof r=="object"&&r&&typeof r.status=="number"&&typeof r.statusText=="string")return new j2(r.status,r.statusText,r.data)}catch{}}function I2(t,{relative:r}={}){tt(Ao(),"useHref() may be used only in the context of a <Router> component.");let{basename:o,navigator:s}=g.useContext(Wt),{hash:c,pathname:u,search:m}=Kl(t,{relative:r}),h=u;return o!=="/"&&(h=u==="/"?o:yn([o,u])),s.createHref({pathname:h,search:m,hash:c})}function Ao(){return g.useContext(Ql)!=null}function En(){return tt(Ao(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(Ql).location}var $y="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function qy(t){g.useContext(Wt).static||g.useLayoutEffect(t)}function Vy(){let{isDataRoute:t}=g.useContext(un);return t?rE():Y2()}function Y2(){tt(Ao(),"useNavigate() may be used only in the context of a <Router> component.");let t=g.useContext(Ro),{basename:r,navigator:o}=g.useContext(Wt),{matches:s}=g.useContext(un),{pathname:c}=En(),u=JSON.stringify(zf(s)),m=g.useRef(!1);return qy(()=>{m.current=!0}),g.useCallback((v,p={})=>{if(bn(m.current,$y),!m.current)return;if(typeof v=="number"){o.go(v);return}let b=tc(v,JSON.parse(u),c,p.relative==="path");t==null&&r!=="/"&&(b.pathname=b.pathname==="/"?r:yn([r,b.pathname])),(p.replace?o.replace:o.push)(b,p.state,p)},[r,o,u,c,t])}var Iy=g.createContext(null);function YO(){return g.useContext(Iy)}function G2(t){let r=g.useContext(un).outlet;return g.useMemo(()=>r&&g.createElement(Iy.Provider,{value:t},r),[r,t])}function GO(){let{matches:t}=g.useContext(un);return t[t.length-1]?.params??{}}function Kl(t,{relative:r}={}){let{matches:o}=g.useContext(un),{pathname:s}=En(),c=JSON.stringify(zf(o));return g.useMemo(()=>tc(t,JSON.parse(c),s,r==="path"),[t,c,s,r])}function X2(t,r){return Yy(t,r)}function Yy(t,r,o){tt(Ao(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:s}=g.useContext(Wt),{matches:c}=g.useContext(un),u=c[c.length-1],m=u?u.params:{},h=u?u.pathname:"/",v=u?u.pathnameBase:"/",p=u&&u.route;{let E=p&&p.path||"";Xy(h,!p||E.endsWith("*")||E.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${h}" (under <Route path="${E}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
60
+
61
+ Please change the parent <Route path="${E}"> to <Route path="${E==="/"?"*":`${E}/*`}">.`)}let b=En(),y;if(r){let E=typeof r=="string"?Co(r):r;tt(v==="/"||E.pathname?.startsWith(v),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${v}" but pathname "${E.pathname}" was given in the \`location\` prop.`),y=E}else y=b;let S=y.pathname||"/",A=S;if(v!=="/"){let E=v.replace(/^\//,"").split("/");A="/"+S.replace(/^\//,"").split("/").slice(E.length).join("/")}let C=o&&o.state.matches.length?o.state.matches.map(E=>Object.assign(E,{route:o.manifest[E.route.id]||E.route})):ky(t,{pathname:A});bn(p||C!=null,`No routes matched location "${y.pathname}${y.search}${y.hash}" `),bn(C==null||C[C.length-1].route.element!==void 0||C[C.length-1].route.Component!==void 0||C[C.length-1].route.lazy!==void 0,`Matched leaf route at location "${y.pathname}${y.search}${y.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let T=W2(C&&C.map(E=>Object.assign({},E,{params:Object.assign({},m,E.params),pathname:yn([v,s.encodeLocation?s.encodeLocation(E.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:E.pathname]),pathnameBase:E.pathnameBase==="/"?v:yn([v,s.encodeLocation?s.encodeLocation(E.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:E.pathnameBase])})),c,o);return r&&T?g.createElement(Ql.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...y},navigationType:"POP"}},T):T}function Q2(){let t=aE(),r=O2(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),o=t instanceof Error?t.stack:null,s="rgba(200,200,200, 0.5)",c={padding:"0.5rem",backgroundColor:s},u={padding:"2px 4px",backgroundColor:s},m=null;return console.error("Error handled by React Router default ErrorBoundary:",t),m=g.createElement(g.Fragment,null,g.createElement("p",null,"💿 Hey developer 👋"),g.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",g.createElement("code",{style:u},"ErrorBoundary")," or"," ",g.createElement("code",{style:u},"errorElement")," prop on your route.")),g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},r),o?g.createElement("pre",{style:c},o):null,m)}var K2=g.createElement(Q2,null),Gy=class extends g.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){this.props.onError?this.props.onError(t,r):console.error("React Router caught the following error during render",t)}render(){let t=this.state.error;if(this.context&&typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){const o=V2(t.digest);o&&(t=o)}let r=t!==void 0?g.createElement(un.Provider,{value:this.props.routeContext},g.createElement(Lf.Provider,{value:t,children:this.props.component})):this.props.children;return this.context?g.createElement(Z2,{error:t},r):r}};Gy.contextType=By;var Dd=new WeakMap;function Z2({children:t,error:r}){let{basename:o}=g.useContext(Wt);if(typeof r=="object"&&r&&"digest"in r&&typeof r.digest=="string"){let s=q2(r.digest);if(s){let c=Dd.get(r);if(c)throw c;let u=Ly(s.location,o),m=u.absoluteURL||u.to;if(L2(m))throw new Error("Invalid redirect location");if(zy&&!Dd.get(r))if(u.isExternal||s.reloadDocument)window.location.href=m;else{const h=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(u.to,{replace:s.replace}));throw Dd.set(r,h),h}return g.createElement("meta",{httpEquiv:"refresh",content:`0;url=${m}`})}}return t}function F2({routeContext:t,match:r,children:o}){let s=g.useContext(Ro);return s&&s.static&&s.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=r.route.id),g.createElement(un.Provider,{value:t},o)}function W2(t,r=[],o){let s=o?.state;if(t==null){if(!s)return null;if(s.errors)t=s.matches;else if(r.length===0&&!s.initialized&&s.matches.length>0)t=s.matches;else return null}let c=t,u=s?.errors;if(u!=null){let b=c.findIndex(y=>y.route.id&&u?.[y.route.id]!==void 0);tt(b>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(u).join(",")}`),c=c.slice(0,Math.min(c.length,b+1))}let m=!1,h=-1;if(o&&s){m=s.renderFallback;for(let b=0;b<c.length;b++){let y=c[b];if((y.route.HydrateFallback||y.route.hydrateFallbackElement)&&(h=b),y.route.id){let{loaderData:S,errors:A}=s,C=y.route.loader&&!S.hasOwnProperty(y.route.id)&&(!A||A[y.route.id]===void 0);if(y.route.lazy||C){o.isStatic&&(m=!0),h>=0?c=c.slice(0,h+1):c=[c[0]];break}}}}let v=o?.onError,p=s&&v?(b,y)=>{v(b,{location:s.location,params:s.matches?.[0]?.params??{},pattern:D2(s.matches),errorInfo:y})}:void 0;return c.reduceRight((b,y,S)=>{let A,C=!1,T=null,E=null;s&&(A=u&&y.route.id?u[y.route.id]:void 0,T=y.route.errorElement||K2,m&&(h<0&&S===0?(Xy("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),C=!0,E=null):h===S&&(C=!0,E=y.route.hydrateFallbackElement||null)));let R=r.concat(c.slice(0,S+1)),k=()=>{let O;return A?O=T:C?O=E:y.route.Component?O=g.createElement(y.route.Component,null):y.route.element?O=y.route.element:O=b,g.createElement(F2,{match:y,routeContext:{outlet:b,matches:R,isDataRoute:s!=null},children:O})};return s&&(y.route.ErrorBoundary||y.route.errorElement||S===0)?g.createElement(Gy,{location:s.location,revalidation:s.revalidation,component:T,error:A,children:k(),routeContext:{outlet:null,matches:R,isDataRoute:!0},onError:p}):k()},null)}function Uf(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function J2(t){let r=g.useContext(Ro);return tt(r,Uf(t)),r}function eE(t){let r=g.useContext(nc);return tt(r,Uf(t)),r}function tE(t){let r=g.useContext(un);return tt(r,Uf(t)),r}function Bf(t){let r=tE(t),o=r.matches[r.matches.length-1];return tt(o.route.id,`${t} can only be used on routes that contain a unique "id"`),o.route.id}function nE(){return Bf("useRouteId")}function aE(){let t=g.useContext(Lf),r=eE("useRouteError"),o=Bf("useRouteError");return t!==void 0?t:r.errors?.[o]}function rE(){let{router:t}=J2("useNavigate"),r=Bf("useNavigate"),o=g.useRef(!1);return qy(()=>{o.current=!0}),g.useCallback(async(c,u={})=>{bn(o.current,$y),o.current&&(typeof c=="number"?await t.navigate(c):await t.navigate(c,{fromRouteId:r,...u}))},[t,r])}var Sv={};function Xy(t,r,o){!r&&!Sv[t]&&(Sv[t]=!0,bn(!1,o))}g.memo(oE);function oE({routes:t,manifest:r,future:o,state:s,isStatic:c,onError:u}){return Yy(t,void 0,{manifest:r,state:s,isStatic:c,onError:u})}function Ev({to:t,replace:r,state:o,relative:s}){tt(Ao(),"<Navigate> may be used only in the context of a <Router> component.");let{static:c}=g.useContext(Wt);bn(!c,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:u}=g.useContext(un),{pathname:m}=En(),h=Vy(),v=tc(t,zf(u),m,s==="path"),p=JSON.stringify(v);return g.useEffect(()=>{h(JSON.parse(p),{replace:r,state:o,relative:s})},[h,p,s,r,o]),null}function lE(t){return G2(t.context)}function yr(t){tt(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function sE({basename:t="/",children:r=null,location:o,navigationType:s="POP",navigator:c,static:u=!1,useTransitions:m}){tt(!Ao(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let h=t.replace(/^\/*/,"/"),v=g.useMemo(()=>({basename:h,navigator:c,static:u,useTransitions:m,future:{}}),[h,c,u,m]);typeof o=="string"&&(o=Co(o));let{pathname:p="/",search:b="",hash:y="",state:S=null,key:A="default",mask:C}=o,T=g.useMemo(()=>{let E=ra(p,h);return E==null?null:{location:{pathname:E,search:b,hash:y,state:S,key:A,mask:C},navigationType:s}},[h,p,b,y,S,A,s,C]);return bn(T!=null,`<Router basename="${h}"> is not able to match the URL "${p}${b}${y}" because it does not start with the basename, so the <Router> won't render anything.`),T==null?null:g.createElement(Wt.Provider,{value:v},g.createElement(Ql.Provider,{children:r,value:T}))}function iE({children:t,location:r}){return X2(af(t),r)}function af(t,r=[]){let o=[];return g.Children.forEach(t,(s,c)=>{if(!g.isValidElement(s))return;let u=[...r,c];if(s.type===g.Fragment){o.push.apply(o,af(s.props.children,u));return}tt(s.type===yr,`[${typeof s.type=="string"?s.type:s.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),tt(!s.props.index||!s.props.children,"An index route cannot have child routes.");let m={id:s.props.id||u.join("-"),caseSensitive:s.props.caseSensitive,element:s.props.element,Component:s.props.Component,index:s.props.index,path:s.props.path,middleware:s.props.middleware,loader:s.props.loader,action:s.props.action,hydrateFallbackElement:s.props.hydrateFallbackElement,HydrateFallback:s.props.HydrateFallback,errorElement:s.props.errorElement,ErrorBoundary:s.props.ErrorBoundary,hasErrorBoundary:s.props.hasErrorBoundary===!0||s.props.ErrorBoundary!=null||s.props.errorElement!=null,shouldRevalidate:s.props.shouldRevalidate,handle:s.props.handle,lazy:s.props.lazy};s.props.children&&(m.children=af(s.props.children,u)),o.push(m)}),o}var wi="get",Si="application/x-www-form-urlencoded";function ac(t){return typeof HTMLElement<"u"&&t instanceof HTMLElement}function cE(t){return ac(t)&&t.tagName.toLowerCase()==="button"}function uE(t){return ac(t)&&t.tagName.toLowerCase()==="form"}function dE(t){return ac(t)&&t.tagName.toLowerCase()==="input"}function fE(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function mE(t,r){return t.button===0&&(!r||r==="_self")&&!fE(t)}var ci=null;function hE(){if(ci===null)try{new FormData(document.createElement("form"),0),ci=!1}catch{ci=!0}return ci}var pE=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Md(t){return t!=null&&!pE.has(t)?(bn(!1,`"${t}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Si}"`),null):t}function gE(t,r){let o,s,c,u,m;if(uE(t)){let h=t.getAttribute("action");s=h?ra(h,r):null,o=t.getAttribute("method")||wi,c=Md(t.getAttribute("enctype"))||Si,u=new FormData(t)}else if(cE(t)||dE(t)&&(t.type==="submit"||t.type==="image")){let h=t.form;if(h==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let v=t.getAttribute("formaction")||h.getAttribute("action");if(s=v?ra(v,r):null,o=t.getAttribute("formmethod")||h.getAttribute("method")||wi,c=Md(t.getAttribute("formenctype"))||Md(h.getAttribute("enctype"))||Si,u=new FormData(h,t),!hE()){let{name:p,type:b,value:y}=t;if(b==="image"){let S=p?`${p}.`:"";u.append(`${S}x`,"0"),u.append(`${S}y`,"0")}else p&&u.append(p,y)}}else{if(ac(t))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');o=wi,s=null,c=Si,m=t}return u&&c==="text/plain"&&(m=u,u=void 0),{action:s,method:o.toLowerCase(),encType:c,formData:u,body:m}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Hf(t,r){if(t===!1||t===null||typeof t>"u")throw new Error(r)}function Qy(t,r,o,s){let c=typeof t=="string"?new URL(t,typeof window>"u"?"server://singlefetch/":window.location.origin):t;return o?c.pathname.endsWith("/")?c.pathname=`${c.pathname}_.${s}`:c.pathname=`${c.pathname}.${s}`:c.pathname==="/"?c.pathname=`_root.${s}`:r&&ra(c.pathname,r)==="/"?c.pathname=`${ji(r)}/_root.${s}`:c.pathname=`${ji(c.pathname)}.${s}`,c}async function vE(t,r){if(t.id in r)return r[t.id];try{let o=await import(t.module);return r[t.id]=o,o}catch(o){return console.error(`Error loading route module \`${t.module}\`, reloading page...`),console.error(o),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function yE(t){return t==null?!1:t.href==null?t.rel==="preload"&&typeof t.imageSrcSet=="string"&&typeof t.imageSizes=="string":typeof t.rel=="string"&&typeof t.href=="string"}async function bE(t,r,o){let s=await Promise.all(t.map(async c=>{let u=r.routes[c.route.id];if(u){let m=await vE(u,o);return m.links?m.links():[]}return[]}));return EE(s.flat(1).filter(yE).filter(c=>c.rel==="stylesheet"||c.rel==="preload").map(c=>c.rel==="stylesheet"?{...c,rel:"prefetch",as:"style"}:{...c,rel:"prefetch"}))}function Tv(t,r,o,s,c,u){let m=(v,p)=>o[p]?v.route.id!==o[p].route.id:!0,h=(v,p)=>o[p].pathname!==v.pathname||o[p].route.path?.endsWith("*")&&o[p].params["*"]!==v.params["*"];return u==="assets"?r.filter((v,p)=>m(v,p)||h(v,p)):u==="data"?r.filter((v,p)=>{let b=s.routes[v.route.id];if(!b||!b.hasLoader)return!1;if(m(v,p)||h(v,p))return!0;if(v.route.shouldRevalidate){let y=v.route.shouldRevalidate({currentUrl:new URL(c.pathname+c.search+c.hash,window.origin),currentParams:o[0]?.params||{},nextUrl:new URL(t,window.origin),nextParams:v.params,defaultShouldRevalidate:!0});if(typeof y=="boolean")return y}return!0}):[]}function xE(t,r,{includeHydrateFallback:o}={}){return wE(t.map(s=>{let c=r.routes[s.route.id];if(!c)return[];let u=[c.module];return c.clientActionModule&&(u=u.concat(c.clientActionModule)),c.clientLoaderModule&&(u=u.concat(c.clientLoaderModule)),o&&c.hydrateFallbackModule&&(u=u.concat(c.hydrateFallbackModule)),c.imports&&(u=u.concat(c.imports)),u}).flat(1))}function wE(t){return[...new Set(t)]}function SE(t){let r={},o=Object.keys(t).sort();for(let s of o)r[s]=t[s];return r}function EE(t,r){let o=new Set;return new Set(r),t.reduce((s,c)=>{let u=JSON.stringify(SE(c));return o.has(u)||(o.add(u),s.push({key:u,link:c})),s},[])}function Pf(){let t=g.useContext(Ro);return Hf(t,"You must render this element inside a <DataRouterContext.Provider> element"),t}function TE(){let t=g.useContext(nc);return Hf(t,"You must render this element inside a <DataRouterStateContext.Provider> element"),t}var $f=g.createContext(void 0);$f.displayName="FrameworkContext";function rc(){let t=g.useContext($f);return Hf(t,"You must render this element inside a <HydratedRouter> element"),t}function NE(t,r){let o=g.useContext($f),[s,c]=g.useState(!1),[u,m]=g.useState(!1),{onFocus:h,onBlur:v,onMouseEnter:p,onMouseLeave:b,onTouchStart:y}=r,S=g.useRef(null);g.useEffect(()=>{if(t==="render"&&m(!0),t==="viewport"){let T=R=>{R.forEach(k=>{m(k.isIntersecting)})},E=new IntersectionObserver(T,{threshold:.5});return S.current&&E.observe(S.current),()=>{E.disconnect()}}},[t]),g.useEffect(()=>{if(s){let T=setTimeout(()=>{m(!0)},100);return()=>{clearTimeout(T)}}},[s]);let A=()=>{c(!0)},C=()=>{c(!1),m(!1)};return o?t!=="intent"?[u,S,{}]:[u,S,{onFocus:_l(h,A),onBlur:_l(v,C),onMouseEnter:_l(p,A),onMouseLeave:_l(b,C),onTouchStart:_l(y,A)}]:[!1,S,{}]}function _l(t,r){return o=>{t&&t(o),o.defaultPrevented||r(o)}}function CE({page:t,...r}){let o=U2(),{nonce:s}=rc(),{router:c}=Pf(),u=g.useMemo(()=>ky(c.routes,t,c.basename),[c.routes,t,c.basename]);return u?(r.nonce==null&&s&&(r={...r,nonce:s}),o?g.createElement(AE,{page:t,matches:u,...r}):g.createElement(kE,{page:t,matches:u,...r})):null}function RE(t){let{manifest:r,routeModules:o}=rc(),[s,c]=g.useState([]);return g.useEffect(()=>{let u=!1;return bE(t,r,o).then(m=>{u||c(m)}),()=>{u=!0}},[t,r,o]),s}function AE({page:t,matches:r,...o}){let s=En(),{future:c}=rc(),{basename:u}=Pf(),m=g.useMemo(()=>{if(t===s.pathname+s.search+s.hash)return[];let h=Qy(t,u,c.v8_trailingSlashAwareDataRequests,"rsc"),v=!1,p=[];for(let b of r)typeof b.route.shouldRevalidate=="function"?v=!0:p.push(b.route.id);return v&&p.length>0&&h.searchParams.set("_routes",p.join(",")),[h.pathname+h.search]},[u,c.v8_trailingSlashAwareDataRequests,t,s,r]);return g.createElement(g.Fragment,null,m.map(h=>g.createElement("link",{key:h,rel:"prefetch",as:"fetch",href:h,...o})))}function kE({page:t,matches:r,...o}){let s=En(),{future:c,manifest:u,routeModules:m}=rc(),{basename:h}=Pf(),{loaderData:v,matches:p}=TE(),b=g.useMemo(()=>Tv(t,r,p,u,s,"data"),[t,r,p,u,s]),y=g.useMemo(()=>Tv(t,r,p,u,s,"assets"),[t,r,p,u,s]),S=g.useMemo(()=>{if(t===s.pathname+s.search+s.hash)return[];let T=new Set,E=!1;if(r.forEach(k=>{let O=u.routes[k.route.id];!O||!O.hasLoader||(!b.some(U=>U.route.id===k.route.id)&&k.route.id in v&&m[k.route.id]?.shouldRevalidate||O.hasClientLoader?E=!0:T.add(k.route.id))}),T.size===0)return[];let R=Qy(t,h,c.v8_trailingSlashAwareDataRequests,"data");return E&&T.size>0&&R.searchParams.set("_routes",r.filter(k=>T.has(k.route.id)).map(k=>k.route.id).join(",")),[R.pathname+R.search]},[h,c.v8_trailingSlashAwareDataRequests,v,s,u,b,r,t,m]),A=g.useMemo(()=>xE(y,u),[y,u]),C=RE(y);return g.createElement(g.Fragment,null,S.map(T=>g.createElement("link",{key:T,rel:"prefetch",as:"fetch",href:T,...o})),A.map(T=>g.createElement("link",{key:T,rel:"modulepreload",href:T,...o})),C.map(({key:T,link:E})=>g.createElement("link",{key:T,nonce:o.nonce,...E,crossOrigin:E.crossOrigin??o.crossOrigin})))}function _E(...t){return r=>{t.forEach(o=>{typeof o=="function"?o(r):o!=null&&(o.current=r)})}}var jE=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{jE&&(window.__reactRouterVersion="7.18.0")}catch{}function OE({basename:t,children:r,useTransitions:o,window:s}){let c=g.useRef();c.current==null&&(c.current=c2({window:s,v5Compat:!0}));let u=c.current,[m,h]=g.useState({action:u.action,location:u.location}),v=g.useCallback(p=>{o===!1?h(p):g.startTransition(()=>h(p))},[o]);return g.useLayoutEffect(()=>u.listen(v),[u,v]),g.createElement(sE,{basename:t,children:r,location:m.location,navigationType:m.action,navigator:u,useTransitions:o})}var Ky=g.forwardRef(function({onClick:r,discover:o="render",prefetch:s="none",relative:c,reloadDocument:u,replace:m,mask:h,state:v,target:p,to:b,preventScrollReset:y,viewTransition:S,defaultShouldRevalidate:A,...C},T){let{basename:E,navigator:R,useTransitions:k}=g.useContext(Wt),O=typeof b=="string"&&Mf.test(b),U=Ly(b,E);b=U.to;let z=I2(b,{relative:c}),G=En(),Y=null;if(h){let ee=tc(h,[],G.mask?G.mask.pathname:"/",!0);E!=="/"&&(ee.pathname=ee.pathname==="/"?E:yn([E,ee.pathname])),Y=R.createHref(ee)}let[q,re,fe]=NE(s,C),ue=zE(b,{replace:m,mask:h,state:v,target:p,preventScrollReset:y,relative:c,viewTransition:S,defaultShouldRevalidate:A,useTransitions:k});function de(ee){r&&r(ee),ee.defaultPrevented||ue(ee)}let W=!(U.isExternal||u),se=g.createElement("a",{...C,...fe,href:(W?Y:void 0)||U.absoluteURL||z,onClick:W?de:r,ref:_E(T,re),target:p,"data-discover":!O&&o==="render"?"true":void 0});return q&&!O?g.createElement(g.Fragment,null,se,g.createElement(CE,{page:z})):se});Ky.displayName="Link";var rf=g.forwardRef(function({"aria-current":r="page",caseSensitive:o=!1,className:s="",end:c=!1,style:u,to:m,viewTransition:h,children:v,...p},b){let y=Kl(m,{relative:p.relative}),S=En(),A=g.useContext(nc),{navigator:C,basename:T}=g.useContext(Wt),E=A!=null&&PE(y)&&h===!0,R=C.encodeLocation?C.encodeLocation(y).pathname:y.pathname,k=S.pathname,O=A&&A.navigation&&A.navigation.location?A.navigation.location.pathname:null;o||(k=k.toLowerCase(),O=O?O.toLowerCase():null,R=R.toLowerCase()),O&&T&&(O=ra(O,T)||O);const U=R!=="/"&&R.endsWith("/")?R.length-1:R.length;let z=k===R||!c&&k.startsWith(R)&&k.charAt(U)==="/",G=O!=null&&(O===R||!c&&O.startsWith(R)&&O.charAt(R.length)==="/"),Y={isActive:z,isPending:G,isTransitioning:E},q=z?r:void 0,re;typeof s=="function"?re=s(Y):re=[s,z?"active":null,G?"pending":null,E?"transitioning":null].filter(Boolean).join(" ");let fe=typeof u=="function"?u(Y):u;return g.createElement(Ky,{...p,"aria-current":q,className:re,ref:b,style:fe,to:m,viewTransition:h},typeof v=="function"?v(Y):v)});rf.displayName="NavLink";var DE=g.forwardRef(({discover:t="render",fetcherKey:r,navigate:o,reloadDocument:s,replace:c,state:u,method:m=wi,action:h,onSubmit:v,relative:p,preventScrollReset:b,viewTransition:y,defaultShouldRevalidate:S,...A},C)=>{let{useTransitions:T}=g.useContext(Wt),E=BE(),R=HE(h,{relative:p}),k=m.toLowerCase()==="get"?"get":"post",O=typeof h=="string"&&Mf.test(h),U=z=>{if(v&&v(z),z.defaultPrevented)return;z.preventDefault();let G=z.nativeEvent.submitter,Y=G?.getAttribute("formmethod")||m,q=()=>E(G||z.currentTarget,{fetcherKey:r,method:Y,navigate:o,replace:c,state:u,relative:p,preventScrollReset:b,viewTransition:y,defaultShouldRevalidate:S});T&&o!==!1?g.startTransition(()=>q()):q()};return g.createElement("form",{ref:C,method:k,action:R,onSubmit:s?v:U,...A,"data-discover":!O&&t==="render"?"true":void 0})});DE.displayName="Form";function ME(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Zy(t){let r=g.useContext(Ro);return tt(r,ME(t)),r}function zE(t,{target:r,replace:o,mask:s,state:c,preventScrollReset:u,relative:m,viewTransition:h,defaultShouldRevalidate:v,useTransitions:p}={}){let b=Vy(),y=En(),S=Kl(t,{relative:m});return g.useCallback(A=>{if(mE(A,r)){A.preventDefault();let C=o!==void 0?o:Hl(y)===Hl(S),T=()=>b(t,{replace:C,mask:s,state:c,preventScrollReset:u,relative:m,viewTransition:h,defaultShouldRevalidate:v});p?g.startTransition(()=>T()):T()}},[y,b,S,o,s,c,r,t,u,m,h,v,p])}var LE=0,UE=()=>`__${String(++LE)}__`;function BE(){let{router:t}=Zy("useSubmit"),{basename:r}=g.useContext(Wt),o=nE(),s=t.fetch,c=t.navigate;return g.useCallback(async(u,m={})=>{let{action:h,method:v,encType:p,formData:b,body:y}=gE(u,r);if(m.navigate===!1){let S=m.fetcherKey||UE();await s(S,o,m.action||h,{defaultShouldRevalidate:m.defaultShouldRevalidate,preventScrollReset:m.preventScrollReset,formData:b,body:y,formMethod:m.method||v,formEncType:m.encType||p,flushSync:m.flushSync})}else await c(m.action||h,{defaultShouldRevalidate:m.defaultShouldRevalidate,preventScrollReset:m.preventScrollReset,formData:b,body:y,formMethod:m.method||v,formEncType:m.encType||p,replace:m.replace,state:m.state,fromRouteId:o,flushSync:m.flushSync,viewTransition:m.viewTransition})},[s,c,r,o])}function HE(t,{relative:r}={}){let{basename:o}=g.useContext(Wt),s=g.useContext(un);tt(s,"useFormAction must be used inside a RouteContext");let[c]=s.matches.slice(-1),u={...Kl(t||".",{relative:r})},m=En();if(t==null){u.search=m.search;let h=new URLSearchParams(u.search),v=h.getAll("index");if(v.some(b=>b==="")){h.delete("index"),v.filter(y=>y).forEach(y=>h.append("index",y));let b=h.toString();u.search=b?`?${b}`:""}}return(!t||t===".")&&c.route.index&&(u.search=u.search?u.search.replace(/^\?/,"?index&"):"?index"),o!=="/"&&(u.pathname=u.pathname==="/"?o:yn([o,u.pathname])),Hl(u)}function PE(t,{relative:r}={}){let o=g.useContext(Hy);tt(o!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:s}=Zy("useViewTransitionState"),c=Kl(t,{relative:r});if(!o.isTransitioning)return!1;let u=ra(o.currentLocation.pathname,s)||o.currentLocation.pathname,m=ra(o.nextLocation.pathname,s)||o.nextLocation.pathname;return _i(c.pathname,m)!=null||_i(c.pathname,u)!=null}var Zl=Cy();const Fy=Ny(Zl),$E="/api";function qE(t){const r=new Headers(t?.headers);return t?.body!==void 0&&t.body!==null&&!r.has("Content-Type")&&r.set("Content-Type","application/json"),r}function VE(t,r){if(typeof t=="string"&&t)return t;if(t&&typeof t=="object"){const o=t,s=typeof o.error=="object"&&o.error!==null?o.error:void 0;if(typeof o.error=="string"&&o.error)return o.error;if(typeof s?.message=="string"&&s.message)return s.message;if(typeof o.message=="string"&&o.message)return o.message}return r}async function ve(t,r){const o=await fetch(`${$E}${t}`,{...r,headers:qE(r)});if(!o.ok){const s=await o.json().catch(()=>o.statusText);throw new Error(VE(s,`HTTP ${o.status}`))}return o.json()}function ko(t,r){return ve(t,{...r,cache:"no-store"})}function Wy(t){return ve(`/node-operations/${t}`)}async function Jy(t={}){const r=new URLSearchParams;t.nodeId&&r.set("nodeId",t.nodeId),t.status&&r.set("status",t.status),t.kind&&r.set("kind",t.kind);const o=r.toString();return(await ve(`/node-operations${o?`?${o}`:""}`)).operations}function IE(t){return ve(`/nodes/${t}/copilot-tunnel/enable`,{method:"POST"})}function Nv(t){return ve(`/nodes/${t}/copilot-tunnel/status`,{method:"POST"})}function YE(t){return ve(`/nodes/${t}/copilot-tunnel/disable`,{method:"POST"})}function GE(){return ve("/system/info")}function XE(t){return ve("/system/default-task-agent",{method:"PUT",body:JSON.stringify({defaultTaskAgent:t})})}function XO(t){return ve("/system/transport",{method:"POST",body:JSON.stringify({type:t})})}function eb(t){return ve("/system/runtime/restart",{method:"POST",body:JSON.stringify(t)})}function QE(){return ve("/system/runtime/stop",{method:"POST"})}function KE(){return ve("/cluster/state")}function QO(){return ve("/cluster/promote",{method:"POST"})}function KO(t){return ve("/cluster/connect",{method:"POST",body:JSON.stringify(t)})}function ZO(){return ve("/cluster/disconnect",{method:"POST"})}function FO(t={}){return ve("/mobile/pairings",{method:"POST",body:JSON.stringify(t)})}function WO(t){return ve(`/mobile/pairings/${encodeURIComponent(t)}`)}function ZE(t,r){return ve(`/nodes/${t}/agents/${r}/upgrade`,{method:"POST"})}function FE(t,r){return ve(`/nodes/${t}/runtime/restart`,{method:"POST",body:JSON.stringify(r)})}async function JO(){return(await ve("/devboxes")).devboxes}function eD(t,r){return ve(`/nodes/${t}/devbox/configure`,{method:"POST",body:JSON.stringify({devbox:r})})}function tD(t){return ve(`/nodes/${t}/devbox/status`)}function nD(t){return ve(`/nodes/${t}/devbox/start`,{method:"POST"})}function aD(t,r){return ve(`/nodes/${t}/devtunnel`,{method:"POST",body:JSON.stringify({enabled:r})})}function rD(t,r={}){const o=new URLSearchParams;r.path&&o.set("path",r.path),r.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,r.limit),100))),r.offset!==void 0&&o.set("offset",String(Math.max(0,r.offset))),r.directoriesOnly!==void 0&&o.set("directoriesOnly",String(r.directoriesOnly)),r.allowAbsolute!==void 0&&o.set("allowAbsolute",String(r.allowAbsolute));const s=o.toString();return ve(`/nodes/${t}/workdir/tree${s?`?${s}`:""}`)}function oD(t,r={}){const o=new URLSearchParams;r.path&&o.set("path",r.path),r.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,r.limit),20))),r.offset!==void 0&&o.set("offset",String(Math.max(0,r.offset))),r.allowAbsolute!==void 0&&o.set("allowAbsolute",String(r.allowAbsolute));const s=o.toString();return ve(`/nodes/${t}/workdir/branch${s?`?${s}`:""}`)}function lD(t,r){const o=new URLSearchParams;return o.set("agent",r.agent),o.set("limit",String(Math.min(Math.max(1,r.limit),100))),ve(`/nodes/${t}/native-sessions?${o.toString()}`)}function sD(t,r){return ve(`/nodes/${t}/workdir/branch`,{method:"POST",body:JSON.stringify({path:r.path,branchName:r.branchName,startPoint:r.startPoint,limit:r.limit,offset:r.offset,allowAbsolute:r.allowAbsolute})})}function iD(t,r){return ve(`/nodes/${t}/terminal/sessions`,{method:"POST",body:JSON.stringify(r)})}function cD(t){return ve(`/nodes/${t}/terminal/sessions`)}function uD(t,r){return ve(`/nodes/${t}/terminal/sessions/${r}`)}function dD(t,r){return ve(`/nodes/${t}/terminal/sessions/${r}/stop`,{method:"POST"})}function qf(t,r){t.set("scope",r.kind),r.kind==="project"&&t.set("projectPath",r.projectPath)}function fD(t,r){const o=new URLSearchParams;return qf(o,r.scope),r.agents?.length&&o.set("agents",r.agents.join(",")),ve(`/nodes/${encodeURIComponent(t)}/capabilities?${o.toString()}`)}function mD(t,r,o){const s=new URLSearchParams;o&&qf(s,o);const c=s.toString();return ve(`/nodes/${encodeURIComponent(t)}/capabilities/${encodeURIComponent(r)}${c?`?${c}`:""}`)}function hD(t,r,o){const s=new URLSearchParams;o&&qf(s,o);const c=s.toString();return ve(`/nodes/${encodeURIComponent(t)}/capabilities/${encodeURIComponent(r)}${c?`?${c}`:""}`,{method:"DELETE"})}function pD(t){return ve("/capabilities/conflict-check",{method:"POST",body:JSON.stringify(t)})}function gD(t){return ve("/capabilities/share",{method:"POST",body:JSON.stringify(t)})}async function vD(t){const r=new URLSearchParams;if(t?.status&&r.set("status",t.status),t?.assignedTo&&r.set("assignedTo",t.assignedTo),t?.priority&&r.set("priority",t.priority),t?.limit){const s=Math.min(Math.max(1,t.limit),100);r.set("limit",String(s))}if(t?.offset&&r.set("offset",String(t.offset)),t?.projectPath&&r.set("projectPath",t.projectPath),t?.cursor&&r.set("cursor",t.cursor),t?.completedLimitPerProject!==void 0){const s=Math.min(Math.max(1,t.completedLimitPerProject),100);r.set("completedLimitPerProject",String(s))}const o=r.toString();return ve(`/tasks${o?`?${o}`:""}`)}function yD(t){return ve(`/tasks/${t}`)}function bD(t){return ve("/tasks",{method:"POST",body:JSON.stringify(t)})}function xD(t){return ve("/tasks/import-session",{method:"POST",body:JSON.stringify(t)})}function wD(t){return ve(`/tasks/${t}`,{method:"DELETE"})}function SD(t,r){return ve(`/tasks/${t}`,{method:"PATCH",body:JSON.stringify(r)})}function ED(t){return ve("/tasks/batch/delete",{method:"POST",body:JSON.stringify({ids:t})})}function TD(t){return ve("/tasks/batch/archive",{method:"POST",body:JSON.stringify({ids:t})})}function ND(t){return ve(`/tasks/${t}`,{method:"PATCH",body:JSON.stringify({status:"archived"})})}function CD(t){return ve(`/tasks/${t}/cancel`,{method:"POST"})}function RD(t){return ve(`/tasks/${t}/retry`,{method:"POST"})}function AD(t,r,o={}){const s=new URLSearchParams;r!==void 0&&s.set("after",String(r)),o.minTotal!==void 0&&s.set("minTotal",String(o.minTotal));const c=s.size>0?`?${s.toString()}`:"";return ve(`/tasks/${t}/logs${c}`)}function kD(t,r,o){return ve(`/tasks/${t}/message`,{method:"POST",body:JSON.stringify({content:r,...o?{targetAgent:o}:{}})})}function _D(t,r){return ve(`/tasks/${t}/queued-messages/${encodeURIComponent(r)}`,{method:"DELETE"})}function jD(t,r){return ve(`/tasks/${t}/share`,{method:"POST",body:JSON.stringify(r)})}function OD(t){return ve(`/tasks/${t}/share`,{method:"DELETE"})}function DD(t){return ko(`/shared/conversations/${encodeURIComponent(t)}`)}function MD(t,r){return ko(`/shared/conversations/${encodeURIComponent(t)}/logs`)}function zD(t){return ko(`/shared/conversations/${encodeURIComponent(t)}/output`)}function LD(t,r="."){return ko(`/shared/conversations/${encodeURIComponent(t)}/output/tree?path=${encodeURIComponent(r)}`)}function UD(t,r){return ko(`/shared/conversations/${encodeURIComponent(t)}/output/content?path=${encodeURIComponent(r)}`)}function BD(t,r){return ko(`/shared/conversations/${encodeURIComponent(t)}/output/preview-sessions`,{method:"POST",body:JSON.stringify(r?{path:r}:{})})}function tb(t){return t?typeof t=="string"?{path:t}:{...t.path?{path:t.path}:{},...t.port!==void 0?{port:t.port}:{}}:{}}function HD(t){return ve(`/tasks/${t}/output`)}function PD(t,r="."){return ve(`/tasks/${t}/output/tree?path=${encodeURIComponent(r)}`)}function $D(t,r){return ve(`/tasks/${t}/output/content?path=${encodeURIComponent(r)}`)}function qD(t,r){return ve(`/tasks/${t}/output/preview-sessions`,{method:"POST",body:JSON.stringify(tb(r))})}function VD(t,r){return ve(`/nodes/${t}/preview-sessions`,{method:"POST",body:JSON.stringify(tb(r))})}function ID(t){return ve(`/tasks/${t}/output/diff`)}function WE({hasStarted:t,enabled:r}){return r&&!t}function JE(t,r,o=!0){const s=g.useRef(t),c=g.useRef(!1);g.useEffect(()=>{s.current=t},[t]),g.useEffect(()=>{if(!o)return;const u=()=>s.current();WE({hasStarted:c.current,enabled:o})&&(c.current=!0,u());const m=setInterval(u,r);return()=>clearInterval(m)},[r,o])}function eT(t){return t?t.replace(/\/+$/,""):""}function tT(t){const r=t??"/api";return r?r.startsWith("/")?r.replace(/\/+$/,""):`/${r.replace(/\/+$/,"")}`:""}function zd(...t){const r=new Headers;for(const o of t){if(!o)continue;new Headers(o).forEach((c,u)=>r.set(u,c))}return r}var nT=class extends Error{status;statusText;code;details;body;constructor(t,r){super(t),this.name="MeshyApiError",this.status=r.status,this.statusText=r.statusText,this.code=r.code,this.details=r.details,this.body=r.body}};function aT(t,r){if(typeof t=="string"&&t)return{message:t};if(t&&typeof t=="object"){const o=t,s=typeof o.error=="object"&&o.error!==null?o.error:void 0;if(typeof o.error=="string"&&o.error)return{message:o.error};if(typeof s?.message=="string"&&s.message)return{message:s.message,code:s.code,details:s.details};if(typeof o.message=="string"&&o.message)return{message:o.message}}return{message:r}}function jl(t,r){const o=r.toString();return o?`${t}?${o}`:t}function Kt(t,r,o){o!==void 0&&t.set(r,String(o))}function ui(t){return t===null||Array.isArray(t)||typeof t=="object"&&t!==null&&!(t instanceof ArrayBuffer)}function Cv(t){return t?typeof t=="string"?{path:t}:{...t.path?{path:t.path}:{},...t.port!==void 0?{port:t.port}:{}}:{}}var rT=class{baseUrl;apiPrefix;defaultHeaders;credentials;fetchImpl;config;constructor(t={}){const r=t.fetchImpl??((o,s)=>globalThis.fetch(o,s));if(!r)throw new Error("MeshyClient requires a fetch implementation");this.fetchImpl=r,this.baseUrl=eT(t.baseUrl),this.apiPrefix=tT(t.apiPrefix),this.defaultHeaders=zd(t.defaultHeaders),this.credentials=t.credentials,this.config=t}buildApiUrl(t){const r=t.startsWith("/")?t:`/${t}`;return`${this.baseUrl}${this.apiPrefix}${r}`}buildApiurl(t){return this.buildApiUrl(t)}async buildRequestHeaders(t={}){const r=await this.config.tokenProvider?.(),o=await this.config.headersProvider?.();return zd(t.accept?{Accept:t.accept}:{Accept:"application/json"},t.json?{"Content-Type":"application/json"}:void 0,this.config.defaultHeaders,o,r?{Authorization:`Bearer ${r}`}:void 0,t.headers)}async fetchApi(t,r={}){const o=r.timeoutMs??this.config.timeoutMs,s=o?new AbortController:null;let c=null;s&&(c=setTimeout(()=>s.abort(),o));const u=await this.buildRequestHeaders({json:ui(r.body),headers:r.headers}),m=ui(r.body)?JSON.stringify(r.body):r.body;try{return await this.fetchImpl(this.buildApiUrl(t),{...r,headers:u,body:m,credentials:r.credentials??this.config.credentials,signal:r.signal??s?.signal})}finally{c&&clearTimeout(c)}}async request(t,r={}){const o=r.timeoutMs??this.config.timeoutMs,s=o?new AbortController:null;let c=null;s&&(c=setTimeout(()=>s.abort(),o));const u=await this.config.tokenProvider?.(),m=await this.config.headersProvider?.(),h=r.credentials??this.config.credentials,v=zd({Accept:"application/json"},ui(r.body)?{"Content-Type":"application/json"}:void 0,this.config.defaultHeaders,m,u?{Authorization:`Bearer ${u}`}:void 0,r.headers),p=ui(r.body)?JSON.stringify(r.body):r.body;try{const b=await this.fetchImpl(this.buildApiUrl(t),{...r,headers:v,body:p,credentials:h,signal:r.signal??s?.signal});if(!b.ok){const y=await b.json().catch(()=>b.statusText),S=aT(y,`HTTP ${b.status}`);throw new nT(S.message,{status:b.status,statusText:b.statusText,code:S.code,details:S.details,body:y})}return b.status===204?void 0:await b.json()}finally{c&&clearTimeout(c)}}getSystemInfo(){return this.request("/system/info")}getSystemMetrics(){return this.request("/system/metrics")}switchTransport(t){return this.request("/system/transport",{method:"POST",body:{type:t}})}restartRuntime(t){return this.request("/system/runtime/restart",{method:"POST",body:t})}stopRuntime(){return this.request("/system/runtime/stop",{method:"POST"})}getClusterState(){return this.request("/cluster/state")}promoteToLeader(){return this.request("/cluster/promote",{method:"POST"})}joinCluster(t){return this.request("/cluster/join",{method:"POST",body:t})}connectToCluster(t){return this.request("/cluster/connect",{method:"POST",body:t})}disconnectFromCluster(){return this.request("/cluster/disconnect",{method:"POST"})}async getNodes(t={}){const r=new URLSearchParams;return Kt(r,"status",t.status),Kt(r,"capability",t.capability),(await this.request(jl("/nodes",r))).nodes}getNode(t){return this.request(`/nodes/${encodeURIComponent(t)}`)}getNodeStatus(t){return this.request(`/nodes/${encodeURIComponent(t)}/status`)}removeNode(t){return this.request(`/nodes/${encodeURIComponent(t)}`,{method:"DELETE"})}leaveCluster(t){return this.request("/cluster/leave",{method:"POST",body:{nodeId:t}})}updateNode(t,r){return this.request(`/nodes/${encodeURIComponent(t)}`,{method:"PATCH",body:r})}toggleNodeDevTunnel(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/devtunnel`,{method:"POST",body:{enabled:r}})}getNodeOperation(t){return this.request(`/node-operations/${encodeURIComponent(t)}`)}async listNodeOperations(t={}){const r=new URLSearchParams;return Kt(r,"nodeId",t.nodeId),Kt(r,"status",t.status),Kt(r,"kind",t.kind),(await this.request(jl("/node-operations",r))).operations}upgradeNodeAgent(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/agents/${r}/upgrade`,{method:"POST"})}restartNodeRuntime(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/runtime/restart`,{method:"POST",body:r})}getNodeWorkDirTree(t,r={}){const o=new URLSearchParams;return Kt(o,"path",r.path),r.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,r.limit),100))),r.offset!==void 0&&o.set("offset",String(Math.max(0,r.offset))),Kt(o,"directoriesOnly",r.directoriesOnly),Kt(o,"allowAbsolute",r.allowAbsolute),this.request(jl(`/nodes/${encodeURIComponent(t)}/workdir/tree`,o))}getNodeWorkDirBranchInfo(t,r={}){const o=new URLSearchParams;return Kt(o,"path",r.path),r.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,r.limit),20))),r.offset!==void 0&&o.set("offset",String(Math.max(0,r.offset))),Kt(o,"allowAbsolute",r.allowAbsolute),this.request(jl(`/nodes/${encodeURIComponent(t)}/workdir/branch`,o))}createNodeWorkDirBranch(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/workdir/branch`,{method:"POST",body:r})}createNodePreviewSession(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/preview-sessions`,{method:"POST",body:Cv(r)})}getNodeNativeSessions(t,r){const o=new URLSearchParams;return o.set("agent",r.agent),r.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,r.limit),100))),this.request(`/nodes/${encodeURIComponent(t)}/native-sessions?${o.toString()}`)}hideNodeNativeSession(t,r,o){return this.request(`/nodes/${encodeURIComponent(t)}/native-sessions/${encodeURIComponent(r)}/${encodeURIComponent(o)}`,{method:"DELETE"})}hideNodeNativeSessionFolder(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/native-sessions/folders/hide`,{method:"POST",body:r})}startNodeTerminalSession(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions`,{method:"POST",body:r})}listNodeTerminalSessions(t){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions`)}getNodeTerminalSession(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions/${encodeURIComponent(r)}`)}stopNodeTerminalSession(t,r){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions/${encodeURIComponent(r)}/stop`,{method:"POST"})}async getTasks(t={}){const r=new URLSearchParams;return Kt(r,"status",t.status),Kt(r,"assignedTo",t.assignedTo),Kt(r,"priority",t.priority),t.limit&&r.set("limit",String(Math.min(Math.max(1,t.limit),100))),t.offset&&r.set("offset",String(t.offset)),(await this.request(jl("/tasks",r))).tasks}getTask(t){return this.request(`/tasks/${encodeURIComponent(t)}`)}createTask(t){return this.request("/tasks",{method:"POST",body:t})}attachNativeSession(t){return this.request("/tasks/import-session",{method:"POST",body:t})}deleteTask(t){return this.request(`/tasks/${encodeURIComponent(t)}`,{method:"DELETE"})}batchDeleteTasks(t){return this.request("/tasks/batch/delete",{method:"POST",body:{ids:t}})}batchArchiveTasks(t){return this.request("/tasks/batch/archive",{method:"POST",body:{ids:t}})}archiveTask(t){return this.request(`/tasks/${encodeURIComponent(t)}`,{method:"PATCH",body:{status:"archived"}})}updateTaskTitle(t,r){return this.request(`/tasks/${encodeURIComponent(t)}`,{method:"PATCH",body:{title:r}})}cancelTask(t){return this.request(`/tasks/${encodeURIComponent(t)}/cancel`,{method:"POST"})}retryTask(t){return this.request(`/tasks/${encodeURIComponent(t)}/retry`,{method:"POST"})}assignTask(t,r){return this.request(`/tasks/${encodeURIComponent(t)}/assign`,{method:"POST",body:{nodeId:r}})}getTaskLogs(t,r){return this.request(`/tasks/${encodeURIComponent(t)}/logs${r!==void 0?`?after=${r}`:""}`)}sendTaskMessage(t,r){return this.request(`/tasks/${encodeURIComponent(t)}/message`,{method:"POST",body:{content:r}})}createTaskShare(t,r){return this.request(`/tasks/${encodeURIComponent(t)}/share`,{method:"POST",body:r})}deleteTaskShare(t){return this.request(`/tasks/${encodeURIComponent(t)}/share`,{method:"DELETE"})}getSharedConversation(t){return this.request(`/shared/conversations/${encodeURIComponent(t)}`)}getSharedConversationLogs(t,r){return this.request(`/shared/conversations/${encodeURIComponent(t)}/logs${r!==void 0?`?after=${r}`:""}`)}getSharedTaskOutput(t){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output`)}getSharedTaskOutputTree(t,r="."){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output/tree?path=${encodeURIComponent(r)}`)}getSharedTaskOutputContent(t,r){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output/content?path=${encodeURIComponent(r)}`)}createSharedTaskPreviewSession(t,r){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output/preview-sessions`,{method:"POST",body:r?{path:r}:{}})}getTaskOutput(t){return this.request(`/tasks/${encodeURIComponent(t)}/output`)}getTaskOutputTree(t,r="."){return this.request(`/tasks/${encodeURIComponent(t)}/output/tree?path=${encodeURIComponent(r)}`)}getTaskOutputContent(t,r){return this.request(`/tasks/${encodeURIComponent(t)}/output/content?path=${encodeURIComponent(r)}`)}createTaskPreviewSession(t,r){return this.request(`/tasks/${encodeURIComponent(t)}/output/preview-sessions`,{method:"POST",body:Cv(r)})}getTaskOutputDiff(t){return this.request(`/tasks/${encodeURIComponent(t)}/output/diff`)}},oT=new rT,lT=["node.joined","node.left","node.status","node.operation.created","node.operation.updated","node.nativeSessions.changed","task.created","task.assigned","task.status","task.updated","task.deleted","task.output","task.logs.ready","election.started","election.complete","cluster.state","transport.changed"],sT=0,iT=class{client;eventTypes;eventSourceFactory;pollIntervalMs;poll;eventSource=null;pollTimer=null;listeners=new Map;connectionListeners=new Map;listenerId=0;connected=!1;constructor(t){this.client=t.client,this.eventTypes=t.eventTypes??lT,this.eventSourceFactory=t.eventSourceFactory??(cT(t.client)?void 0:dT()),this.pollIntervalMs=t.pollIntervalMs??1e4,this.poll=t.poll}start(){if(!(this.eventSource||this.pollTimer)){if(this.eventSourceFactory){const t=new this.eventSourceFactory(uT(this.client,"/events"),this.client.credentials==="include"?{withCredentials:!0}:void 0);this.eventSource=t,t.onopen=()=>this.setConnected(!0),t.onerror=()=>{this.setConnected(!1),this.startPolling()};for(const r of this.eventTypes)t.addEventListener(r,o=>this.emit({id:String(++sT),type:r,data:JSON.parse(o.data),timestamp:Date.now()}));return}this.startPolling()}}stop(){this.eventSource?.close(),this.eventSource=null,this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null),this.setConnected(!1)}subscribe(t,r){const o=++this.listenerId;return this.listeners.set(o,{pattern:t,callback:r}),()=>this.listeners.delete(o)}onConnectionChange(t){const r=++this.listenerId;return this.connectionListeners.set(r,t),t(this.connected),()=>this.connectionListeners.delete(r)}isConnected(){return this.connected}emit(t){for(const{pattern:r,callback:o}of this.listeners.values())t.type.startsWith(r)&&o(t)}setConnected(t){if(this.connected!==t){this.connected=t;for(const r of this.connectionListeners.values())r(t)}}startPolling(){!this.poll||this.pollTimer||(this.pollTimer=setInterval(()=>{this.poll?.().then(()=>this.setConnected(!0)).catch(()=>{this.setConnected(!1)})},this.pollIntervalMs))}};function cT(t){return t.defaultHeaders.has("x-tunnel-authorization")}function uT(t,r){const o=t.buildApiUrl??t.buildApiurl;if(!o)throw new Error("MeshyClient is missing buildApiUrl");return o.call(t,r)}function dT(){return globalThis.EventSource}var fT=3,mT="mmp";function YD(t){return JSON.stringify({t:mT,v:fT,n:t.nodeId,N:t.nodeName,u:t.apiBaseUrl,p:t.pairingId,e:t.expiresAt,m:t.maxUses,a:{t:t.aad.tenantId,c:t.aad.clientId,s:t.aad.scopes}})}function hT(t=50){const[r,o]=g.useState([]),[s,c]=g.useState(!1),u=g.useRef(null),m=g.useRef(0),h=g.useRef(new Map);g.useEffect(()=>{const b=new iT({client:oT});u.current=b;const y=b.subscribe("",A=>{const C=A;o(T=>[C,...T].slice(0,t));for(const[,{pattern:T,callback:E}]of h.current)C.type.startsWith(T)&&E(C)}),S=b.onConnectionChange(c);return b.start(),()=>{y(),S(),b.stop(),u.current=null}},[t]);const v=g.useCallback((b,y)=>{const S=++m.current;return h.current.set(S,{pattern:b,callback:y}),()=>{h.current.delete(S)}},[]),p=g.useCallback(()=>o([]),[]);return{events:r,connected:s,subscribe:v,clearEvents:p}}const pT=1e4,gT=6e4,vT=pT,yT=250,bT=new Set(["node.joined","node.left","task.created","task.assigned","task.deleted"]),xT=new Set(["task.created","task.assigned","task.status","task.deleted"]);function wT(t){return t?gT:vT}function GD(t){return bT.has(t)}function ST(t){return xT.has(t)}function ET(t,r){if(!r)return!0;const o=t.leaderId,s=t.term,c=t.nodeCount;return typeof o!="string"&&o!==null||typeof s!="number"||typeof c!="number"?!0:r.leaderId!==o||r.term!==s||r.nodeCount!==c}function TT(t,r,o){if(t==="node.joined"||t==="node.left"||t!=="node.status")return!0;const s=r.nodeId,c=r.status;return typeof s!="string"||typeof c!="string"?!0:o.get(s)!==c}function XD(t,r){const o=r.taskId,s=r.status;if(typeof o!="string"||typeof s!="string")return t;let c=!1;const u=t.map(m=>{if(m.id!==o)return m;c=!0;const h="result"in r?r.result:s==="completed"?null:m.result,v="error"in r?r.error:s==="completed"?null:m.error;return{...m,status:s,result:h,error:v}});return c?u:t}function QD(t,r){const o=r.taskId;if(typeof o!="string")return t;const s=t.filter(c=>c.id!==o);return s.length===t.length?t:s}const Vf=g.createContext(null);function NT({children:t}){const[r,o]=g.useState(null),[s,c]=g.useState(null),[u,m]=g.useState(!0),[h,v]=g.useState(null),p=g.useRef(null),b=g.useRef(null),y=g.useRef(new Map),{events:S,connected:A,subscribe:C}=hT(),T=g.useCallback(async()=>{try{const[R,k]=await Promise.all([KE(),GE()]),O=R,U=k.nodeId??k.id,z=O.nodes??[],G=z.find(re=>re.id===U)??{id:U,name:k.name,endpoint:k.endpoint,role:k.role,status:k.status,capabilities:k.capabilities,joinedAt:k.joinedAt,lastHeartbeat:k.lastHeartbeat},Y=O.leaderId?z.find(re=>re.id===O.leaderId)??null:null,q={leader:Y?{id:Y.id,name:Y.name,endpoint:Y.endpoint,...Y.dashboardOrigin?{dashboardOrigin:Y.dashboardOrigin}:{}}:null,term:O.term??0,nodes:z,self:G,taskSummary:O.taskSummary??{total:0,pending:0,running:0,completed:0,failed:0}};b.current={leaderId:q.leader?.id??null,term:q.term,nodeCount:q.nodes.length},y.current=new Map(q.nodes.map(re=>[re.id,re.status])),y.current.set(q.self.id,q.self.status),o(q),c(k),v(null)}catch(R){v(R instanceof Error?R.message:"Failed to fetch cluster state")}finally{m(!1)}},[]),E=g.useCallback(()=>{p.current===null&&(p.current=window.setTimeout(()=>{p.current=null,T()},yT))},[T]);return JE(T,wT(A)),g.useEffect(()=>()=>{p.current!==null&&(window.clearTimeout(p.current),p.current=null)},[]),g.useEffect(()=>{const R=[C("cluster",k=>{ET(k.data,b.current)&&E()}),C("election",E),C("node",k=>{TT(k.type,k.data,y.current)&&E()}),C("transport",E),C("task",k=>{ST(k.type)&&E()})];return()=>R.forEach(k=>k())},[C,E]),f.jsx(Vf.Provider,{value:{cluster:r,systemInfo:s,events:S,sseConnected:A,subscribe:C,refresh:T,loading:u,error:h},children:t})}function nb(){const t=g.useContext(Vf);if(!t)throw new Error("useCluster must be used within ClusterProvider");return t}function KD(){return g.useContext(Vf)}/**
62
+ * @license lucide-react v1.7.0 - ISC
63
+ *
64
+ * This source code is licensed under the ISC license.
65
+ * See the LICENSE file in the root directory of this source tree.
66
+ */const ab=(...t)=>t.filter((r,o,s)=>!!r&&r.trim()!==""&&s.indexOf(r)===o).join(" ").trim();/**
67
+ * @license lucide-react v1.7.0 - ISC
68
+ *
69
+ * This source code is licensed under the ISC license.
70
+ * See the LICENSE file in the root directory of this source tree.
71
+ */const CT=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
72
+ * @license lucide-react v1.7.0 - ISC
73
+ *
74
+ * This source code is licensed under the ISC license.
75
+ * See the LICENSE file in the root directory of this source tree.
76
+ */const RT=t=>t.replace(/^([A-Z])|[\s-_]+(\w)/g,(r,o,s)=>s?s.toUpperCase():o.toLowerCase());/**
77
+ * @license lucide-react v1.7.0 - ISC
78
+ *
79
+ * This source code is licensed under the ISC license.
80
+ * See the LICENSE file in the root directory of this source tree.
81
+ */const Rv=t=>{const r=RT(t);return r.charAt(0).toUpperCase()+r.slice(1)};/**
82
+ * @license lucide-react v1.7.0 - ISC
83
+ *
84
+ * This source code is licensed under the ISC license.
85
+ * See the LICENSE file in the root directory of this source tree.
86
+ */var Ld={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
87
+ * @license lucide-react v1.7.0 - ISC
88
+ *
89
+ * This source code is licensed under the ISC license.
90
+ * See the LICENSE file in the root directory of this source tree.
91
+ */const AT=t=>{for(const r in t)if(r.startsWith("aria-")||r==="role"||r==="title")return!0;return!1},kT=g.createContext({}),_T=()=>g.useContext(kT),jT=g.forwardRef(({color:t,size:r,strokeWidth:o,absoluteStrokeWidth:s,className:c="",children:u,iconNode:m,...h},v)=>{const{size:p=24,strokeWidth:b=2,absoluteStrokeWidth:y=!1,color:S="currentColor",className:A=""}=_T()??{},C=s??y?Number(o??b)*24/Number(r??p):o??b;return g.createElement("svg",{ref:v,...Ld,width:r??p??Ld.width,height:r??p??Ld.height,stroke:t??S,strokeWidth:C,className:ab("lucide",A,c),...!u&&!AT(h)&&{"aria-hidden":"true"},...h},[...m.map(([T,E])=>g.createElement(T,E)),...Array.isArray(u)?u:[u]])});/**
92
+ * @license lucide-react v1.7.0 - ISC
93
+ *
94
+ * This source code is licensed under the ISC license.
95
+ * See the LICENSE file in the root directory of this source tree.
96
+ */const Oe=(t,r)=>{const o=g.forwardRef(({className:s,...c},u)=>g.createElement(jT,{ref:u,iconNode:r,className:ab(`lucide-${CT(Rv(t))}`,`lucide-${t}`,s),...c}));return o.displayName=Rv(t),o};/**
97
+ * @license lucide-react v1.7.0 - ISC
98
+ *
99
+ * This source code is licensed under the ISC license.
100
+ * See the LICENSE file in the root directory of this source tree.
101
+ */const OT=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],of=Oe("activity",OT);/**
102
+ * @license lucide-react v1.7.0 - ISC
103
+ *
104
+ * This source code is licensed under the ISC license.
105
+ * See the LICENSE file in the root directory of this source tree.
106
+ */const DT=[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]],MT=Oe("book-open",DT);/**
107
+ * @license lucide-react v1.7.0 - ISC
108
+ *
109
+ * This source code is licensed under the ISC license.
110
+ * See the LICENSE file in the root directory of this source tree.
111
+ */const zT=[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]],If=Oe("bot",zT);/**
112
+ * @license lucide-react v1.7.0 - ISC
113
+ *
114
+ * This source code is licensed under the ISC license.
115
+ * See the LICENSE file in the root directory of this source tree.
116
+ */const LT=[["path",{d:"M17 19a1 1 0 0 1-1-1v-2a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2a1 1 0 0 1-1 1z",key:"trhst0"}],["path",{d:"M17 21v-2",key:"ds4u3f"}],["path",{d:"M19 14V6.5a1 1 0 0 0-7 0v11a1 1 0 0 1-7 0V10",key:"1mo9zo"}],["path",{d:"M21 21v-2",key:"eo0ou"}],["path",{d:"M3 5V3",key:"1k5hjh"}],["path",{d:"M4 10a2 2 0 0 1-2-2V6a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2a2 2 0 0 1-2 2z",key:"1dd30t"}],["path",{d:"M7 5V3",key:"1t1388"}]],UT=Oe("cable",LT);/**
117
+ * @license lucide-react v1.7.0 - ISC
118
+ *
119
+ * This source code is licensed under the ISC license.
120
+ * See the LICENSE file in the root directory of this source tree.
121
+ */const BT=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],Oi=Oe("check",BT);/**
122
+ * @license lucide-react v1.7.0 - ISC
123
+ *
124
+ * This source code is licensed under the ISC license.
125
+ * See the LICENSE file in the root directory of this source tree.
126
+ */const HT=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Pl=Oe("chevron-down",HT);/**
127
+ * @license lucide-react v1.7.0 - ISC
128
+ *
129
+ * This source code is licensed under the ISC license.
130
+ * See the LICENSE file in the root directory of this source tree.
131
+ */const PT=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],lf=Oe("chevron-right",PT);/**
132
+ * @license lucide-react v1.7.0 - ISC
133
+ *
134
+ * This source code is licensed under the ISC license.
135
+ * See the LICENSE file in the root directory of this source tree.
136
+ */const $T=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],qT=Oe("chevron-up",$T);/**
137
+ * @license lucide-react v1.7.0 - ISC
138
+ *
139
+ * This source code is licensed under the ISC license.
140
+ * See the LICENSE file in the root directory of this source tree.
141
+ */const VT=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],di=Oe("circle-alert",VT);/**
142
+ * @license lucide-react v1.7.0 - ISC
143
+ *
144
+ * This source code is licensed under the ISC license.
145
+ * See the LICENSE file in the root directory of this source tree.
146
+ */const IT=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],xo=Oe("circle-check",IT);/**
147
+ * @license lucide-react v1.7.0 - ISC
148
+ *
149
+ * This source code is licensed under the ISC license.
150
+ * See the LICENSE file in the root directory of this source tree.
151
+ */const YT=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]],Av=Oe("circle-dot",YT);/**
152
+ * @license lucide-react v1.7.0 - ISC
153
+ *
154
+ * This source code is licensed under the ISC license.
155
+ * See the LICENSE file in the root directory of this source tree.
156
+ */const GT=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],sf=Oe("circle-x",GT);/**
157
+ * @license lucide-react v1.7.0 - ISC
158
+ *
159
+ * This source code is licensed under the ISC license.
160
+ * See the LICENSE file in the root directory of this source tree.
161
+ */const XT=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],rb=Oe("copy",XT);/**
162
+ * @license lucide-react v1.7.0 - ISC
163
+ *
164
+ * This source code is licensed under the ISC license.
165
+ * See the LICENSE file in the root directory of this source tree.
166
+ */const QT=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],ob=Oe("external-link",QT);/**
167
+ * @license lucide-react v1.7.0 - ISC
168
+ *
169
+ * This source code is licensed under the ISC license.
170
+ * See the LICENSE file in the root directory of this source tree.
171
+ */const KT=[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],ZT=Oe("folder",KT);/**
172
+ * @license lucide-react v1.7.0 - ISC
173
+ *
174
+ * This source code is licensed under the ISC license.
175
+ * See the LICENSE file in the root directory of this source tree.
176
+ */const FT=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],WT=Oe("info",FT);/**
177
+ * @license lucide-react v1.7.0 - ISC
178
+ *
179
+ * This source code is licensed under the ISC license.
180
+ * See the LICENSE file in the root directory of this source tree.
181
+ */const JT=[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]],eN=Oe("key-round",JT);/**
182
+ * @license lucide-react v1.7.0 - ISC
183
+ *
184
+ * This source code is licensed under the ISC license.
185
+ * See the LICENSE file in the root directory of this source tree.
186
+ */const tN=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],lb=Oe("loader-circle",tN);/**
187
+ * @license lucide-react v1.7.0 - ISC
188
+ *
189
+ * This source code is licensed under the ISC license.
190
+ * See the LICENSE file in the root directory of this source tree.
191
+ */const nN=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}],["path",{d:"M7 11h10",key:"1twpyw"}],["path",{d:"M7 15h6",key:"d9of3u"}],["path",{d:"M7 7h8",key:"af5zfr"}]],sb=Oe("message-square-text",nN);/**
192
+ * @license lucide-react v1.7.0 - ISC
193
+ *
194
+ * This source code is licensed under the ISC license.
195
+ * See the LICENSE file in the root directory of this source tree.
196
+ */const aN=[["path",{d:"M5 12h14",key:"1ays0h"}]],rN=Oe("minus",aN);/**
197
+ * @license lucide-react v1.7.0 - ISC
198
+ *
199
+ * This source code is licensed under the ISC license.
200
+ * See the LICENSE file in the root directory of this source tree.
201
+ */const oN=[["path",{d:"M12 17v4",key:"1riwvh"}],["path",{d:"m14.305 7.53.923-.382",key:"1mlnsw"}],["path",{d:"m15.228 4.852-.923-.383",key:"82mpwg"}],["path",{d:"m16.852 3.228-.383-.924",key:"ln4sir"}],["path",{d:"m16.852 8.772-.383.923",key:"1dejw0"}],["path",{d:"m19.148 3.228.383-.924",key:"192kgf"}],["path",{d:"m19.53 9.696-.382-.924",key:"fiavlr"}],["path",{d:"m20.772 4.852.924-.383",key:"1j8mgp"}],["path",{d:"m20.772 7.148.924.383",key:"zix9be"}],["path",{d:"M22 13v2a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7",key:"1tnzv8"}],["path",{d:"M8 21h8",key:"1ev6f3"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}]],lN=Oe("monitor-cog",oN);/**
202
+ * @license lucide-react v1.7.0 - ISC
203
+ *
204
+ * This source code is licensed under the ISC license.
205
+ * See the LICENSE file in the root directory of this source tree.
206
+ */const sN=[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]],ib=Oe("monitor",sN);/**
207
+ * @license lucide-react v1.7.0 - ISC
208
+ *
209
+ * This source code is licensed under the ISC license.
210
+ * See the LICENSE file in the root directory of this source tree.
211
+ */const iN=[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]],cb=Oe("moon",iN);/**
212
+ * @license lucide-react v1.7.0 - ISC
213
+ *
214
+ * This source code is licensed under the ISC license.
215
+ * See the LICENSE file in the root directory of this source tree.
216
+ */const cN=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],uN=Oe("plus",cN);/**
217
+ * @license lucide-react v1.7.0 - ISC
218
+ *
219
+ * This source code is licensed under the ISC license.
220
+ * See the LICENSE file in the root directory of this source tree.
221
+ */const dN=[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]],fN=Oe("power",dN);/**
222
+ * @license lucide-react v1.7.0 - ISC
223
+ *
224
+ * This source code is licensed under the ISC license.
225
+ * See the LICENSE file in the root directory of this source tree.
226
+ */const mN=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],Ei=Oe("refresh-cw",mN);/**
227
+ * @license lucide-react v1.7.0 - ISC
228
+ *
229
+ * This source code is licensed under the ISC license.
230
+ * See the LICENSE file in the root directory of this source tree.
231
+ */const hN=[["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}],["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09",key:"u4xsad"}],["path",{d:"M9 12a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.4 22.4 0 0 1-4 2z",key:"676m9"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 .05 5 .05",key:"92ym6u"}]],kv=Oe("rocket",hN);/**
232
+ * @license lucide-react v1.7.0 - ISC
233
+ *
234
+ * This source code is licensed under the ISC license.
235
+ * See the LICENSE file in the root directory of this source tree.
236
+ */const pN=[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]],gN=Oe("save",pN);/**
237
+ * @license lucide-react v1.7.0 - ISC
238
+ *
239
+ * This source code is licensed under the ISC license.
240
+ * See the LICENSE file in the root directory of this source tree.
241
+ */const vN=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],yN=Oe("search",vN);/**
242
+ * @license lucide-react v1.7.0 - ISC
243
+ *
244
+ * This source code is licensed under the ISC license.
245
+ * See the LICENSE file in the root directory of this source tree.
246
+ */const bN=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]],xN=Oe("server",bN);/**
247
+ * @license lucide-react v1.7.0 - ISC
248
+ *
249
+ * This source code is licensed under the ISC license.
250
+ * See the LICENSE file in the root directory of this source tree.
251
+ */const wN=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],SN=Oe("settings",wN);/**
252
+ * @license lucide-react v1.7.0 - ISC
253
+ *
254
+ * This source code is licensed under the ISC license.
255
+ * See the LICENSE file in the root directory of this source tree.
256
+ */const EN=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],TN=Oe("sparkles",EN);/**
257
+ * @license lucide-react v1.7.0 - ISC
258
+ *
259
+ * This source code is licensed under the ISC license.
260
+ * See the LICENSE file in the root directory of this source tree.
261
+ */const NN=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]],CN=Oe("square",NN);/**
262
+ * @license lucide-react v1.7.0 - ISC
263
+ *
264
+ * This source code is licensed under the ISC license.
265
+ * See the LICENSE file in the root directory of this source tree.
266
+ */const RN=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]],ub=Oe("sun",RN);/**
267
+ * @license lucide-react v1.7.0 - ISC
268
+ *
269
+ * This source code is licensed under the ISC license.
270
+ * See the LICENSE file in the root directory of this source tree.
271
+ */const AN=[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]],db=Oe("terminal",AN);/**
272
+ * @license lucide-react v1.7.0 - ISC
273
+ *
274
+ * This source code is licensed under the ISC license.
275
+ * See the LICENSE file in the root directory of this source tree.
276
+ */const kN=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],_N=Oe("trash-2",kN);/**
277
+ * @license lucide-react v1.7.0 - ISC
278
+ *
279
+ * This source code is licensed under the ISC license.
280
+ * See the LICENSE file in the root directory of this source tree.
281
+ */const jN=[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}],["path",{d:"M5 12.859a10 10 0 0 1 5.17-2.69",key:"1dl1wf"}],["path",{d:"M19 12.859a10 10 0 0 0-2.007-1.523",key:"4k23kn"}],["path",{d:"M2 8.82a15 15 0 0 1 4.177-2.643",key:"1grhjp"}],["path",{d:"M22 8.82a15 15 0 0 0-11.288-3.764",key:"z3jwby"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],ON=Oe("wifi-off",jN);/**
282
+ * @license lucide-react v1.7.0 - ISC
283
+ *
284
+ * This source code is licensed under the ISC license.
285
+ * See the LICENSE file in the root directory of this source tree.
286
+ */const DN=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Yf=Oe("x",DN);function fb(t){var r,o,s="";if(typeof t=="string"||typeof t=="number")s+=t;else if(typeof t=="object")if(Array.isArray(t)){var c=t.length;for(r=0;r<c;r++)t[r]&&(o=fb(t[r]))&&(s&&(s+=" "),s+=o)}else for(o in t)t[o]&&(s&&(s+=" "),s+=o);return s}function mb(){for(var t,r,o=0,s="",c=arguments.length;o<c;o++)(t=arguments[o])&&(r=fb(t))&&(s&&(s+=" "),s+=r);return s}const MN=(t,r)=>{const o=new Array(t.length+r.length);for(let s=0;s<t.length;s++)o[s]=t[s];for(let s=0;s<r.length;s++)o[t.length+s]=r[s];return o},zN=(t,r)=>({classGroupId:t,validator:r}),hb=(t=new Map,r=null,o)=>({nextPart:t,validators:r,classGroupId:o}),Di="-",_v=[],LN="arbitrary..",UN=t=>{const r=HN(t),{conflictingClassGroups:o,conflictingClassGroupModifiers:s}=t;return{getClassGroupId:m=>{if(m.startsWith("[")&&m.endsWith("]"))return BN(m);const h=m.split(Di),v=h[0]===""&&h.length>1?1:0;return pb(h,v,r)},getConflictingClassGroupIds:(m,h)=>{if(h){const v=s[m],p=o[m];return v?p?MN(p,v):v:p||_v}return o[m]||_v}}},pb=(t,r,o)=>{if(t.length-r===0)return o.classGroupId;const c=t[r],u=o.nextPart.get(c);if(u){const p=pb(t,r+1,u);if(p)return p}const m=o.validators;if(m===null)return;const h=r===0?t.join(Di):t.slice(r).join(Di),v=m.length;for(let p=0;p<v;p++){const b=m[p];if(b.validator(h))return b.classGroupId}},BN=t=>t.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const r=t.slice(1,-1),o=r.indexOf(":"),s=r.slice(0,o);return s?LN+s:void 0})(),HN=t=>{const{theme:r,classGroups:o}=t;return PN(o,r)},PN=(t,r)=>{const o=hb();for(const s in t){const c=t[s];Gf(c,o,s,r)}return o},Gf=(t,r,o,s)=>{const c=t.length;for(let u=0;u<c;u++){const m=t[u];$N(m,r,o,s)}},$N=(t,r,o,s)=>{if(typeof t=="string"){qN(t,r,o);return}if(typeof t=="function"){VN(t,r,o,s);return}IN(t,r,o,s)},qN=(t,r,o)=>{const s=t===""?r:gb(r,t);s.classGroupId=o},VN=(t,r,o,s)=>{if(YN(t)){Gf(t(s),r,o,s);return}r.validators===null&&(r.validators=[]),r.validators.push(zN(o,t))},IN=(t,r,o,s)=>{const c=Object.entries(t),u=c.length;for(let m=0;m<u;m++){const[h,v]=c[m];Gf(v,gb(r,h),o,s)}},gb=(t,r)=>{let o=t;const s=r.split(Di),c=s.length;for(let u=0;u<c;u++){const m=s[u];let h=o.nextPart.get(m);h||(h=hb(),o.nextPart.set(m,h)),o=h}return o},YN=t=>"isThemeGetter"in t&&t.isThemeGetter===!0,GN=t=>{if(t<1)return{get:()=>{},set:()=>{}};let r=0,o=Object.create(null),s=Object.create(null);const c=(u,m)=>{o[u]=m,r++,r>t&&(r=0,s=o,o=Object.create(null))};return{get(u){let m=o[u];if(m!==void 0)return m;if((m=s[u])!==void 0)return c(u,m),m},set(u,m){u in o?o[u]=m:c(u,m)}}},cf="!",jv=":",XN=[],Ov=(t,r,o,s,c)=>({modifiers:t,hasImportantModifier:r,baseClassName:o,maybePostfixModifierPosition:s,isExternal:c}),QN=t=>{const{prefix:r,experimentalParseClassName:o}=t;let s=c=>{const u=[];let m=0,h=0,v=0,p;const b=c.length;for(let T=0;T<b;T++){const E=c[T];if(m===0&&h===0){if(E===jv){u.push(c.slice(v,T)),v=T+1;continue}if(E==="/"){p=T;continue}}E==="["?m++:E==="]"?m--:E==="("?h++:E===")"&&h--}const y=u.length===0?c:c.slice(v);let S=y,A=!1;y.endsWith(cf)?(S=y.slice(0,-1),A=!0):y.startsWith(cf)&&(S=y.slice(1),A=!0);const C=p&&p>v?p-v:void 0;return Ov(u,A,S,C)};if(r){const c=r+jv,u=s;s=m=>m.startsWith(c)?u(m.slice(c.length)):Ov(XN,!1,m,void 0,!0)}if(o){const c=s;s=u=>o({className:u,parseClassName:c})}return s},KN=t=>{const r=new Map;return t.orderSensitiveModifiers.forEach((o,s)=>{r.set(o,1e6+s)}),o=>{const s=[];let c=[];for(let u=0;u<o.length;u++){const m=o[u],h=m[0]==="[",v=r.has(m);h||v?(c.length>0&&(c.sort(),s.push(...c),c=[]),s.push(m)):c.push(m)}return c.length>0&&(c.sort(),s.push(...c)),s}},ZN=t=>({cache:GN(t.cacheSize),parseClassName:QN(t),sortModifiers:KN(t),...UN(t)}),FN=/\s+/,WN=(t,r)=>{const{parseClassName:o,getClassGroupId:s,getConflictingClassGroupIds:c,sortModifiers:u}=r,m=[],h=t.trim().split(FN);let v="";for(let p=h.length-1;p>=0;p-=1){const b=h[p],{isExternal:y,modifiers:S,hasImportantModifier:A,baseClassName:C,maybePostfixModifierPosition:T}=o(b);if(y){v=b+(v.length>0?" "+v:v);continue}let E=!!T,R=s(E?C.substring(0,T):C);if(!R){if(!E){v=b+(v.length>0?" "+v:v);continue}if(R=s(C),!R){v=b+(v.length>0?" "+v:v);continue}E=!1}const k=S.length===0?"":S.length===1?S[0]:u(S).join(":"),O=A?k+cf:k,U=O+R;if(m.indexOf(U)>-1)continue;m.push(U);const z=c(R,E);for(let G=0;G<z.length;++G){const Y=z[G];m.push(O+Y)}v=b+(v.length>0?" "+v:v)}return v},JN=(...t)=>{let r=0,o,s,c="";for(;r<t.length;)(o=t[r++])&&(s=vb(o))&&(c&&(c+=" "),c+=s);return c},vb=t=>{if(typeof t=="string")return t;let r,o="";for(let s=0;s<t.length;s++)t[s]&&(r=vb(t[s]))&&(o&&(o+=" "),o+=r);return o},eC=(t,...r)=>{let o,s,c,u;const m=v=>{const p=r.reduce((b,y)=>y(b),t());return o=ZN(p),s=o.cache.get,c=o.cache.set,u=h,h(v)},h=v=>{const p=s(v);if(p)return p;const b=WN(v,o);return c(v,b),b};return u=m,(...v)=>u(JN(...v))},tC=[],bt=t=>{const r=o=>o[t]||tC;return r.isThemeGetter=!0,r},yb=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,bb=/^\((?:(\w[\w-]*):)?(.+)\)$/i,nC=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,aC=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,rC=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,oC=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,lC=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,sC=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,za=t=>nC.test(t),_e=t=>!!t&&!Number.isNaN(Number(t)),La=t=>!!t&&Number.isInteger(Number(t)),Ud=t=>t.endsWith("%")&&_e(t.slice(0,-1)),na=t=>aC.test(t),xb=()=>!0,iC=t=>rC.test(t)&&!oC.test(t),Xf=()=>!1,cC=t=>lC.test(t),uC=t=>sC.test(t),dC=t=>!pe(t)&&!ge(t),fC=t=>Ia(t,Eb,Xf),pe=t=>yb.test(t),pr=t=>Ia(t,Tb,iC),Dv=t=>Ia(t,xC,_e),mC=t=>Ia(t,Cb,xb),hC=t=>Ia(t,Nb,Xf),Mv=t=>Ia(t,wb,Xf),pC=t=>Ia(t,Sb,uC),fi=t=>Ia(t,Rb,cC),ge=t=>bb.test(t),Ol=t=>Tr(t,Tb),gC=t=>Tr(t,Nb),zv=t=>Tr(t,wb),vC=t=>Tr(t,Eb),yC=t=>Tr(t,Sb),mi=t=>Tr(t,Rb,!0),bC=t=>Tr(t,Cb,!0),Ia=(t,r,o)=>{const s=yb.exec(t);return s?s[1]?r(s[1]):o(s[2]):!1},Tr=(t,r,o=!1)=>{const s=bb.exec(t);return s?s[1]?r(s[1]):o:!1},wb=t=>t==="position"||t==="percentage",Sb=t=>t==="image"||t==="url",Eb=t=>t==="length"||t==="size"||t==="bg-size",Tb=t=>t==="length",xC=t=>t==="number",Nb=t=>t==="family-name",Cb=t=>t==="number"||t==="weight",Rb=t=>t==="shadow",wC=()=>{const t=bt("color"),r=bt("font"),o=bt("text"),s=bt("font-weight"),c=bt("tracking"),u=bt("leading"),m=bt("breakpoint"),h=bt("container"),v=bt("spacing"),p=bt("radius"),b=bt("shadow"),y=bt("inset-shadow"),S=bt("text-shadow"),A=bt("drop-shadow"),C=bt("blur"),T=bt("perspective"),E=bt("aspect"),R=bt("ease"),k=bt("animate"),O=()=>["auto","avoid","all","avoid-page","page","left","right","column"],U=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],z=()=>[...U(),ge,pe],G=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto","contain","none"],q=()=>[ge,pe,v],re=()=>[za,"full","auto",...q()],fe=()=>[La,"none","subgrid",ge,pe],ue=()=>["auto",{span:["full",La,ge,pe]},La,ge,pe],de=()=>[La,"auto",ge,pe],W=()=>["auto","min","max","fr",ge,pe],se=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],ee=()=>["start","end","center","stretch","center-safe","end-safe"],j=()=>["auto",...q()],P=()=>[za,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...q()],H=()=>[za,"screen","full","dvw","lvw","svw","min","max","fit",...q()],F=()=>[za,"screen","full","lh","dvh","lvh","svh","min","max","fit",...q()],N=()=>[t,ge,pe],I=()=>[...U(),zv,Mv,{position:[ge,pe]}],J=()=>["no-repeat",{repeat:["","x","y","space","round"]}],Q=()=>["auto","cover","contain",vC,fC,{size:[ge,pe]}],le=()=>[Ud,Ol,pr],te=()=>["","none","full",p,ge,pe],ae=()=>["",_e,Ol,pr],ie=()=>["solid","dashed","dotted","double"],ce=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],xe=()=>[_e,Ud,zv,Mv],Re=()=>["","none",C,ge,pe],Te=()=>["none",_e,ge,pe],Ae=()=>["none",_e,ge,pe],Je=()=>[_e,ge,pe],at=()=>[za,"full",...q()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[na],breakpoint:[na],color:[xb],container:[na],"drop-shadow":[na],ease:["in","out","in-out"],font:[dC],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[na],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[na],shadow:[na],spacing:["px",_e],text:[na],"text-shadow":[na],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",za,pe,ge,E]}],container:["container"],columns:[{columns:[_e,pe,ge,h]}],"break-after":[{"break-after":O()}],"break-before":[{"break-before":O()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:z()}],overflow:[{overflow:G()}],"overflow-x":[{"overflow-x":G()}],"overflow-y":[{"overflow-y":G()}],overscroll:[{overscroll:Y()}],"overscroll-x":[{"overscroll-x":Y()}],"overscroll-y":[{"overscroll-y":Y()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:re()}],"inset-x":[{"inset-x":re()}],"inset-y":[{"inset-y":re()}],start:[{"inset-s":re(),start:re()}],end:[{"inset-e":re(),end:re()}],"inset-bs":[{"inset-bs":re()}],"inset-be":[{"inset-be":re()}],top:[{top:re()}],right:[{right:re()}],bottom:[{bottom:re()}],left:[{left:re()}],visibility:["visible","invisible","collapse"],z:[{z:[La,"auto",ge,pe]}],basis:[{basis:[za,"full","auto",h,...q()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[_e,za,"auto","initial","none",pe]}],grow:[{grow:["",_e,ge,pe]}],shrink:[{shrink:["",_e,ge,pe]}],order:[{order:[La,"first","last","none",ge,pe]}],"grid-cols":[{"grid-cols":fe()}],"col-start-end":[{col:ue()}],"col-start":[{"col-start":de()}],"col-end":[{"col-end":de()}],"grid-rows":[{"grid-rows":fe()}],"row-start-end":[{row:ue()}],"row-start":[{"row-start":de()}],"row-end":[{"row-end":de()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":W()}],"auto-rows":[{"auto-rows":W()}],gap:[{gap:q()}],"gap-x":[{"gap-x":q()}],"gap-y":[{"gap-y":q()}],"justify-content":[{justify:[...se(),"normal"]}],"justify-items":[{"justify-items":[...ee(),"normal"]}],"justify-self":[{"justify-self":["auto",...ee()]}],"align-content":[{content:["normal",...se()]}],"align-items":[{items:[...ee(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...ee(),{baseline:["","last"]}]}],"place-content":[{"place-content":se()}],"place-items":[{"place-items":[...ee(),"baseline"]}],"place-self":[{"place-self":["auto",...ee()]}],p:[{p:q()}],px:[{px:q()}],py:[{py:q()}],ps:[{ps:q()}],pe:[{pe:q()}],pbs:[{pbs:q()}],pbe:[{pbe:q()}],pt:[{pt:q()}],pr:[{pr:q()}],pb:[{pb:q()}],pl:[{pl:q()}],m:[{m:j()}],mx:[{mx:j()}],my:[{my:j()}],ms:[{ms:j()}],me:[{me:j()}],mbs:[{mbs:j()}],mbe:[{mbe:j()}],mt:[{mt:j()}],mr:[{mr:j()}],mb:[{mb:j()}],ml:[{ml:j()}],"space-x":[{"space-x":q()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":q()}],"space-y-reverse":["space-y-reverse"],size:[{size:P()}],"inline-size":[{inline:["auto",...H()]}],"min-inline-size":[{"min-inline":["auto",...H()]}],"max-inline-size":[{"max-inline":["none",...H()]}],"block-size":[{block:["auto",...F()]}],"min-block-size":[{"min-block":["auto",...F()]}],"max-block-size":[{"max-block":["none",...F()]}],w:[{w:[h,"screen",...P()]}],"min-w":[{"min-w":[h,"screen","none",...P()]}],"max-w":[{"max-w":[h,"screen","none","prose",{screen:[m]},...P()]}],h:[{h:["screen","lh",...P()]}],"min-h":[{"min-h":["screen","lh","none",...P()]}],"max-h":[{"max-h":["screen","lh",...P()]}],"font-size":[{text:["base",o,Ol,pr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[s,bC,mC]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Ud,pe]}],"font-family":[{font:[gC,hC,r]}],"font-features":[{"font-features":[pe]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[c,ge,pe]}],"line-clamp":[{"line-clamp":[_e,"none",ge,Dv]}],leading:[{leading:[u,...q()]}],"list-image":[{"list-image":["none",ge,pe]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",ge,pe]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:N()}],"text-color":[{text:N()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ie(),"wavy"]}],"text-decoration-thickness":[{decoration:[_e,"from-font","auto",ge,pr]}],"text-decoration-color":[{decoration:N()}],"underline-offset":[{"underline-offset":[_e,"auto",ge,pe]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:q()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ge,pe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ge,pe]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:I()}],"bg-repeat":[{bg:J()}],"bg-size":[{bg:Q()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},La,ge,pe],radial:["",ge,pe],conic:[La,ge,pe]},yC,pC]}],"bg-color":[{bg:N()}],"gradient-from-pos":[{from:le()}],"gradient-via-pos":[{via:le()}],"gradient-to-pos":[{to:le()}],"gradient-from":[{from:N()}],"gradient-via":[{via:N()}],"gradient-to":[{to:N()}],rounded:[{rounded:te()}],"rounded-s":[{"rounded-s":te()}],"rounded-e":[{"rounded-e":te()}],"rounded-t":[{"rounded-t":te()}],"rounded-r":[{"rounded-r":te()}],"rounded-b":[{"rounded-b":te()}],"rounded-l":[{"rounded-l":te()}],"rounded-ss":[{"rounded-ss":te()}],"rounded-se":[{"rounded-se":te()}],"rounded-ee":[{"rounded-ee":te()}],"rounded-es":[{"rounded-es":te()}],"rounded-tl":[{"rounded-tl":te()}],"rounded-tr":[{"rounded-tr":te()}],"rounded-br":[{"rounded-br":te()}],"rounded-bl":[{"rounded-bl":te()}],"border-w":[{border:ae()}],"border-w-x":[{"border-x":ae()}],"border-w-y":[{"border-y":ae()}],"border-w-s":[{"border-s":ae()}],"border-w-e":[{"border-e":ae()}],"border-w-bs":[{"border-bs":ae()}],"border-w-be":[{"border-be":ae()}],"border-w-t":[{"border-t":ae()}],"border-w-r":[{"border-r":ae()}],"border-w-b":[{"border-b":ae()}],"border-w-l":[{"border-l":ae()}],"divide-x":[{"divide-x":ae()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ae()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ie(),"hidden","none"]}],"divide-style":[{divide:[...ie(),"hidden","none"]}],"border-color":[{border:N()}],"border-color-x":[{"border-x":N()}],"border-color-y":[{"border-y":N()}],"border-color-s":[{"border-s":N()}],"border-color-e":[{"border-e":N()}],"border-color-bs":[{"border-bs":N()}],"border-color-be":[{"border-be":N()}],"border-color-t":[{"border-t":N()}],"border-color-r":[{"border-r":N()}],"border-color-b":[{"border-b":N()}],"border-color-l":[{"border-l":N()}],"divide-color":[{divide:N()}],"outline-style":[{outline:[...ie(),"none","hidden"]}],"outline-offset":[{"outline-offset":[_e,ge,pe]}],"outline-w":[{outline:["",_e,Ol,pr]}],"outline-color":[{outline:N()}],shadow:[{shadow:["","none",b,mi,fi]}],"shadow-color":[{shadow:N()}],"inset-shadow":[{"inset-shadow":["none",y,mi,fi]}],"inset-shadow-color":[{"inset-shadow":N()}],"ring-w":[{ring:ae()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:N()}],"ring-offset-w":[{"ring-offset":[_e,pr]}],"ring-offset-color":[{"ring-offset":N()}],"inset-ring-w":[{"inset-ring":ae()}],"inset-ring-color":[{"inset-ring":N()}],"text-shadow":[{"text-shadow":["none",S,mi,fi]}],"text-shadow-color":[{"text-shadow":N()}],opacity:[{opacity:[_e,ge,pe]}],"mix-blend":[{"mix-blend":[...ce(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ce()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[_e]}],"mask-image-linear-from-pos":[{"mask-linear-from":xe()}],"mask-image-linear-to-pos":[{"mask-linear-to":xe()}],"mask-image-linear-from-color":[{"mask-linear-from":N()}],"mask-image-linear-to-color":[{"mask-linear-to":N()}],"mask-image-t-from-pos":[{"mask-t-from":xe()}],"mask-image-t-to-pos":[{"mask-t-to":xe()}],"mask-image-t-from-color":[{"mask-t-from":N()}],"mask-image-t-to-color":[{"mask-t-to":N()}],"mask-image-r-from-pos":[{"mask-r-from":xe()}],"mask-image-r-to-pos":[{"mask-r-to":xe()}],"mask-image-r-from-color":[{"mask-r-from":N()}],"mask-image-r-to-color":[{"mask-r-to":N()}],"mask-image-b-from-pos":[{"mask-b-from":xe()}],"mask-image-b-to-pos":[{"mask-b-to":xe()}],"mask-image-b-from-color":[{"mask-b-from":N()}],"mask-image-b-to-color":[{"mask-b-to":N()}],"mask-image-l-from-pos":[{"mask-l-from":xe()}],"mask-image-l-to-pos":[{"mask-l-to":xe()}],"mask-image-l-from-color":[{"mask-l-from":N()}],"mask-image-l-to-color":[{"mask-l-to":N()}],"mask-image-x-from-pos":[{"mask-x-from":xe()}],"mask-image-x-to-pos":[{"mask-x-to":xe()}],"mask-image-x-from-color":[{"mask-x-from":N()}],"mask-image-x-to-color":[{"mask-x-to":N()}],"mask-image-y-from-pos":[{"mask-y-from":xe()}],"mask-image-y-to-pos":[{"mask-y-to":xe()}],"mask-image-y-from-color":[{"mask-y-from":N()}],"mask-image-y-to-color":[{"mask-y-to":N()}],"mask-image-radial":[{"mask-radial":[ge,pe]}],"mask-image-radial-from-pos":[{"mask-radial-from":xe()}],"mask-image-radial-to-pos":[{"mask-radial-to":xe()}],"mask-image-radial-from-color":[{"mask-radial-from":N()}],"mask-image-radial-to-color":[{"mask-radial-to":N()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":U()}],"mask-image-conic-pos":[{"mask-conic":[_e]}],"mask-image-conic-from-pos":[{"mask-conic-from":xe()}],"mask-image-conic-to-pos":[{"mask-conic-to":xe()}],"mask-image-conic-from-color":[{"mask-conic-from":N()}],"mask-image-conic-to-color":[{"mask-conic-to":N()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:I()}],"mask-repeat":[{mask:J()}],"mask-size":[{mask:Q()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",ge,pe]}],filter:[{filter:["","none",ge,pe]}],blur:[{blur:Re()}],brightness:[{brightness:[_e,ge,pe]}],contrast:[{contrast:[_e,ge,pe]}],"drop-shadow":[{"drop-shadow":["","none",A,mi,fi]}],"drop-shadow-color":[{"drop-shadow":N()}],grayscale:[{grayscale:["",_e,ge,pe]}],"hue-rotate":[{"hue-rotate":[_e,ge,pe]}],invert:[{invert:["",_e,ge,pe]}],saturate:[{saturate:[_e,ge,pe]}],sepia:[{sepia:["",_e,ge,pe]}],"backdrop-filter":[{"backdrop-filter":["","none",ge,pe]}],"backdrop-blur":[{"backdrop-blur":Re()}],"backdrop-brightness":[{"backdrop-brightness":[_e,ge,pe]}],"backdrop-contrast":[{"backdrop-contrast":[_e,ge,pe]}],"backdrop-grayscale":[{"backdrop-grayscale":["",_e,ge,pe]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[_e,ge,pe]}],"backdrop-invert":[{"backdrop-invert":["",_e,ge,pe]}],"backdrop-opacity":[{"backdrop-opacity":[_e,ge,pe]}],"backdrop-saturate":[{"backdrop-saturate":[_e,ge,pe]}],"backdrop-sepia":[{"backdrop-sepia":["",_e,ge,pe]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":q()}],"border-spacing-x":[{"border-spacing-x":q()}],"border-spacing-y":[{"border-spacing-y":q()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",ge,pe]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[_e,"initial",ge,pe]}],ease:[{ease:["linear","initial",R,ge,pe]}],delay:[{delay:[_e,ge,pe]}],animate:[{animate:["none",k,ge,pe]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[T,ge,pe]}],"perspective-origin":[{"perspective-origin":z()}],rotate:[{rotate:Te()}],"rotate-x":[{"rotate-x":Te()}],"rotate-y":[{"rotate-y":Te()}],"rotate-z":[{"rotate-z":Te()}],scale:[{scale:Ae()}],"scale-x":[{"scale-x":Ae()}],"scale-y":[{"scale-y":Ae()}],"scale-z":[{"scale-z":Ae()}],"scale-3d":["scale-3d"],skew:[{skew:Je()}],"skew-x":[{"skew-x":Je()}],"skew-y":[{"skew-y":Je()}],transform:[{transform:[ge,pe,"","none","gpu","cpu"]}],"transform-origin":[{origin:z()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:at()}],"translate-x":[{"translate-x":at()}],"translate-y":[{"translate-y":at()}],"translate-z":[{"translate-z":at()}],"translate-none":["translate-none"],accent:[{accent:N()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:N()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",ge,pe]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":q()}],"scroll-mx":[{"scroll-mx":q()}],"scroll-my":[{"scroll-my":q()}],"scroll-ms":[{"scroll-ms":q()}],"scroll-me":[{"scroll-me":q()}],"scroll-mbs":[{"scroll-mbs":q()}],"scroll-mbe":[{"scroll-mbe":q()}],"scroll-mt":[{"scroll-mt":q()}],"scroll-mr":[{"scroll-mr":q()}],"scroll-mb":[{"scroll-mb":q()}],"scroll-ml":[{"scroll-ml":q()}],"scroll-p":[{"scroll-p":q()}],"scroll-px":[{"scroll-px":q()}],"scroll-py":[{"scroll-py":q()}],"scroll-ps":[{"scroll-ps":q()}],"scroll-pe":[{"scroll-pe":q()}],"scroll-pbs":[{"scroll-pbs":q()}],"scroll-pbe":[{"scroll-pbe":q()}],"scroll-pt":[{"scroll-pt":q()}],"scroll-pr":[{"scroll-pr":q()}],"scroll-pb":[{"scroll-pb":q()}],"scroll-pl":[{"scroll-pl":q()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",ge,pe]}],fill:[{fill:["none",...N()]}],"stroke-w":[{stroke:[_e,Ol,pr,Dv]}],stroke:[{stroke:["none",...N()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},SC=eC(wC);function ne(...t){return SC(mb(t))}function EC(t){if(typeof document>"u")return;let r=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",r.appendChild(o),o.styleSheet?o.styleSheet.cssText=t:o.appendChild(document.createTextNode(t))}const TC=t=>{switch(t){case"success":return RC;case"info":return kC;case"warning":return AC;case"error":return _C;default:return null}},NC=Array(12).fill(0),CC=({visible:t,className:r})=>oe.createElement("div",{className:["sonner-loading-wrapper",r].filter(Boolean).join(" "),"data-visible":t},oe.createElement("div",{className:"sonner-spinner"},NC.map((o,s)=>oe.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${s}`})))),RC=oe.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},oe.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),AC=oe.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},oe.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),kC=oe.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},oe.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),_C=oe.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},oe.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),jC=oe.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},oe.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),oe.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),OC=()=>{const[t,r]=oe.useState(document.hidden);return oe.useEffect(()=>{const o=()=>{r(document.hidden)};return document.addEventListener("visibilitychange",o),()=>window.removeEventListener("visibilitychange",o)},[]),t};let uf=1;class DC{constructor(){this.subscribe=r=>(this.subscribers.push(r),()=>{const o=this.subscribers.indexOf(r);this.subscribers.splice(o,1)}),this.publish=r=>{this.subscribers.forEach(o=>o(r))},this.addToast=r=>{this.publish(r),this.toasts=[...this.toasts,r]},this.create=r=>{var o;const{message:s,...c}=r,u=typeof r?.id=="number"||((o=r.id)==null?void 0:o.length)>0?r.id:uf++,m=this.toasts.find(v=>v.id===u),h=r.dismissible===void 0?!0:r.dismissible;return this.dismissedToasts.has(u)&&this.dismissedToasts.delete(u),m?this.toasts=this.toasts.map(v=>v.id===u?(this.publish({...v,...r,id:u,title:s}),{...v,...r,id:u,dismissible:h,title:s}):v):this.addToast({title:s,...c,dismissible:h,id:u}),u},this.dismiss=r=>(r?(this.dismissedToasts.add(r),requestAnimationFrame(()=>this.subscribers.forEach(o=>o({id:r,dismiss:!0})))):this.toasts.forEach(o=>{this.subscribers.forEach(s=>s({id:o.id,dismiss:!0}))}),r),this.message=(r,o)=>this.create({...o,message:r}),this.error=(r,o)=>this.create({...o,message:r,type:"error"}),this.success=(r,o)=>this.create({...o,type:"success",message:r}),this.info=(r,o)=>this.create({...o,type:"info",message:r}),this.warning=(r,o)=>this.create({...o,type:"warning",message:r}),this.loading=(r,o)=>this.create({...o,type:"loading",message:r}),this.promise=(r,o)=>{if(!o)return;let s;o.loading!==void 0&&(s=this.create({...o,promise:r,type:"loading",message:o.loading,description:typeof o.description!="function"?o.description:void 0}));const c=Promise.resolve(r instanceof Function?r():r);let u=s!==void 0,m;const h=c.then(async p=>{if(m=["resolve",p],oe.isValidElement(p))u=!1,this.create({id:s,type:"default",message:p});else if(zC(p)&&!p.ok){u=!1;const y=typeof o.error=="function"?await o.error(`HTTP error! status: ${p.status}`):o.error,S=typeof o.description=="function"?await o.description(`HTTP error! status: ${p.status}`):o.description,C=typeof y=="object"&&!oe.isValidElement(y)?y:{message:y};this.create({id:s,type:"error",description:S,...C})}else if(p instanceof Error){u=!1;const y=typeof o.error=="function"?await o.error(p):o.error,S=typeof o.description=="function"?await o.description(p):o.description,C=typeof y=="object"&&!oe.isValidElement(y)?y:{message:y};this.create({id:s,type:"error",description:S,...C})}else if(o.success!==void 0){u=!1;const y=typeof o.success=="function"?await o.success(p):o.success,S=typeof o.description=="function"?await o.description(p):o.description,C=typeof y=="object"&&!oe.isValidElement(y)?y:{message:y};this.create({id:s,type:"success",description:S,...C})}}).catch(async p=>{if(m=["reject",p],o.error!==void 0){u=!1;const b=typeof o.error=="function"?await o.error(p):o.error,y=typeof o.description=="function"?await o.description(p):o.description,A=typeof b=="object"&&!oe.isValidElement(b)?b:{message:b};this.create({id:s,type:"error",description:y,...A})}}).finally(()=>{u&&(this.dismiss(s),s=void 0),o.finally==null||o.finally.call(o)}),v=()=>new Promise((p,b)=>h.then(()=>m[0]==="reject"?b(m[1]):p(m[1])).catch(b));return typeof s!="string"&&typeof s!="number"?{unwrap:v}:Object.assign(s,{unwrap:v})},this.custom=(r,o)=>{const s=o?.id||uf++;return this.create({jsx:r(s),id:s,...o}),s},this.getActiveToasts=()=>this.toasts.filter(r=>!this.dismissedToasts.has(r.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const Pt=new DC,MC=(t,r)=>{const o=r?.id||uf++;return Pt.addToast({title:t,...r,id:o}),o},zC=t=>t&&typeof t=="object"&&"ok"in t&&typeof t.ok=="boolean"&&"status"in t&&typeof t.status=="number",LC=MC,UC=()=>Pt.toasts,BC=()=>Pt.getActiveToasts(),Ce=Object.assign(LC,{success:Pt.success,info:Pt.info,warning:Pt.warning,error:Pt.error,custom:Pt.custom,message:Pt.message,promise:Pt.promise,dismiss:Pt.dismiss,loading:Pt.loading},{getHistory:UC,getToasts:BC});EC("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function hi(t){return t.label!==void 0}const HC=3,PC="24px",$C="16px",Lv=4e3,qC=356,VC=14,IC=45,YC=200;function On(...t){return t.filter(Boolean).join(" ")}function GC(t){const[r,o]=t.split("-"),s=[];return r&&s.push(r),o&&s.push(o),s}const XC=t=>{var r,o,s,c,u,m,h,v,p;const{invert:b,toast:y,unstyled:S,interacting:A,setHeights:C,visibleToasts:T,heights:E,index:R,toasts:k,expanded:O,removeToast:U,defaultRichColors:z,closeButton:G,style:Y,cancelButtonStyle:q,actionButtonStyle:re,className:fe="",descriptionClassName:ue="",duration:de,position:W,gap:se,expandByDefault:ee,classNames:j,icons:P,closeButtonAriaLabel:H="Close toast"}=t,[F,N]=oe.useState(null),[I,J]=oe.useState(null),[Q,le]=oe.useState(!1),[te,ae]=oe.useState(!1),[ie,ce]=oe.useState(!1),[xe,Re]=oe.useState(!1),[Te,Ae]=oe.useState(!1),[Je,at]=oe.useState(0),[dn,fn]=oe.useState(0),lt=oe.useRef(y.duration||de||Lv),Qa=oe.useRef(null),ht=oe.useRef(null),Nr=R===0,Un=R+1<=T,st=y.type,mn=y.dismissible!==!1,Cr=y.className||"",ca=y.descriptionClassName||"",$t=oe.useMemo(()=>E.findIndex(me=>me.toastId===y.id)||0,[E,y.id]),Ct=oe.useMemo(()=>{var me;return(me=y.closeButton)!=null?me:G},[y.closeButton,G]),Mt=oe.useMemo(()=>y.duration||de||Lv,[y.duration,de]),We=oe.useRef(0),Nn=oe.useRef(0),Rr=oe.useRef(0),Cn=oe.useRef(null),[ua,da]=W.split("-"),Jt=oe.useMemo(()=>E.reduce((me,He,Qe)=>Qe>=$t?me:me+He.height,0),[E,$t]),Bn=OC(),Hn=y.invert||b,fa=st==="loading";Nn.current=oe.useMemo(()=>$t*se+Jt,[$t,Jt]),oe.useEffect(()=>{lt.current=Mt},[Mt]),oe.useEffect(()=>{le(!0)},[]),oe.useEffect(()=>{const me=ht.current;if(me){const He=me.getBoundingClientRect().height;return fn(He),C(Qe=>[{toastId:y.id,height:He,position:y.position},...Qe]),()=>C(Qe=>Qe.filter(pt=>pt.toastId!==y.id))}},[C,y.id]),oe.useLayoutEffect(()=>{if(!Q)return;const me=ht.current,He=me.style.height;me.style.height="auto";const Qe=me.getBoundingClientRect().height;me.style.height=He,fn(Qe),C(pt=>pt.find(gt=>gt.toastId===y.id)?pt.map(gt=>gt.toastId===y.id?{...gt,height:Qe}:gt):[{toastId:y.id,height:Qe,position:y.position},...pt])},[Q,y.title,y.description,C,y.id,y.jsx,y.action,y.cancel]);const zt=oe.useCallback(()=>{ae(!0),at(Nn.current),C(me=>me.filter(He=>He.toastId!==y.id)),setTimeout(()=>{U(y)},YC)},[y,U,C,Nn]);oe.useEffect(()=>{if(y.promise&&st==="loading"||y.duration===1/0||y.type==="loading")return;let me;return O||A||Bn?(()=>{if(Rr.current<We.current){const pt=new Date().getTime()-We.current;lt.current=lt.current-pt}Rr.current=new Date().getTime()})():lt.current!==1/0&&(We.current=new Date().getTime(),me=setTimeout(()=>{y.onAutoClose==null||y.onAutoClose.call(y,y),zt()},lt.current)),()=>clearTimeout(me)},[O,A,y,st,Bn,zt]),oe.useEffect(()=>{y.delete&&(zt(),y.onDismiss==null||y.onDismiss.call(y,y))},[zt,y.delete]);function Ka(){var me;if(P?.loading){var He;return oe.createElement("div",{className:On(j?.loader,y==null||(He=y.classNames)==null?void 0:He.loader,"sonner-loader"),"data-visible":st==="loading"},P.loading)}return oe.createElement(CC,{className:On(j?.loader,y==null||(me=y.classNames)==null?void 0:me.loader),visible:st==="loading"})}const Za=y.icon||P?.[st]||TC(st);var be,Xe;return oe.createElement("li",{tabIndex:0,ref:ht,className:On(fe,Cr,j?.toast,y==null||(r=y.classNames)==null?void 0:r.toast,j?.default,j?.[st],y==null||(o=y.classNames)==null?void 0:o[st]),"data-sonner-toast":"","data-rich-colors":(be=y.richColors)!=null?be:z,"data-styled":!(y.jsx||y.unstyled||S),"data-mounted":Q,"data-promise":!!y.promise,"data-swiped":Te,"data-removed":te,"data-visible":Un,"data-y-position":ua,"data-x-position":da,"data-index":R,"data-front":Nr,"data-swiping":ie,"data-dismissible":mn,"data-type":st,"data-invert":Hn,"data-swipe-out":xe,"data-swipe-direction":I,"data-expanded":!!(O||ee&&Q),"data-testid":y.testId,style:{"--index":R,"--toasts-before":R,"--z-index":k.length-R,"--offset":`${te?Je:Nn.current}px`,"--initial-height":ee?"auto":`${dn}px`,...Y,...y.style},onDragEnd:()=>{ce(!1),N(null),Cn.current=null},onPointerDown:me=>{me.button!==2&&(fa||!mn||(Qa.current=new Date,at(Nn.current),me.target.setPointerCapture(me.pointerId),me.target.tagName!=="BUTTON"&&(ce(!0),Cn.current={x:me.clientX,y:me.clientY})))},onPointerUp:()=>{var me,He,Qe;if(xe||!mn)return;Cn.current=null;const pt=Number(((me=ht.current)==null?void 0:me.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Fa=Number(((He=ht.current)==null?void 0:He.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),gt=new Date().getTime()-((Qe=Qa.current)==null?void 0:Qe.getTime()),it=F==="x"?pt:Fa,ct=Math.abs(it)/gt;if(Math.abs(it)>=IC||ct>.11){at(Nn.current),y.onDismiss==null||y.onDismiss.call(y,y),J(F==="x"?pt>0?"right":"left":Fa>0?"down":"up"),zt(),Re(!0);return}else{var Ke,xt;(Ke=ht.current)==null||Ke.style.setProperty("--swipe-amount-x","0px"),(xt=ht.current)==null||xt.style.setProperty("--swipe-amount-y","0px")}Ae(!1),ce(!1),N(null)},onPointerMove:me=>{var He,Qe,pt;if(!Cn.current||!mn||((He=window.getSelection())==null?void 0:He.toString().length)>0)return;const gt=me.clientY-Cn.current.y,it=me.clientX-Cn.current.x;var ct;const Ke=(ct=t.swipeDirections)!=null?ct:GC(W);!F&&(Math.abs(it)>1||Math.abs(gt)>1)&&N(Math.abs(it)>Math.abs(gt)?"x":"y");let xt={x:0,y:0};const Ar=Pn=>1/(1.5+Math.abs(Pn)/20);if(F==="y"){if(Ke.includes("top")||Ke.includes("bottom"))if(Ke.includes("top")&&gt<0||Ke.includes("bottom")&&gt>0)xt.y=gt;else{const Pn=gt*Ar(gt);xt.y=Math.abs(Pn)<Math.abs(gt)?Pn:gt}}else if(F==="x"&&(Ke.includes("left")||Ke.includes("right")))if(Ke.includes("left")&&it<0||Ke.includes("right")&&it>0)xt.x=it;else{const Pn=it*Ar(it);xt.x=Math.abs(Pn)<Math.abs(it)?Pn:it}(Math.abs(xt.x)>0||Math.abs(xt.y)>0)&&Ae(!0),(Qe=ht.current)==null||Qe.style.setProperty("--swipe-amount-x",`${xt.x}px`),(pt=ht.current)==null||pt.style.setProperty("--swipe-amount-y",`${xt.y}px`)}},Ct&&!y.jsx&&st!=="loading"?oe.createElement("button",{"aria-label":H,"data-disabled":fa,"data-close-button":!0,onClick:fa||!mn?()=>{}:()=>{zt(),y.onDismiss==null||y.onDismiss.call(y,y)},className:On(j?.closeButton,y==null||(s=y.classNames)==null?void 0:s.closeButton)},(Xe=P?.close)!=null?Xe:jC):null,(st||y.icon||y.promise)&&y.icon!==null&&(P?.[st]!==null||y.icon)?oe.createElement("div",{"data-icon":"",className:On(j?.icon,y==null||(c=y.classNames)==null?void 0:c.icon)},y.promise||y.type==="loading"&&!y.icon?y.icon||Ka():null,y.type!=="loading"?Za:null):null,oe.createElement("div",{"data-content":"",className:On(j?.content,y==null||(u=y.classNames)==null?void 0:u.content)},oe.createElement("div",{"data-title":"",className:On(j?.title,y==null||(m=y.classNames)==null?void 0:m.title)},y.jsx?y.jsx:typeof y.title=="function"?y.title():y.title),y.description?oe.createElement("div",{"data-description":"",className:On(ue,ca,j?.description,y==null||(h=y.classNames)==null?void 0:h.description)},typeof y.description=="function"?y.description():y.description):null),oe.isValidElement(y.cancel)?y.cancel:y.cancel&&hi(y.cancel)?oe.createElement("button",{"data-button":!0,"data-cancel":!0,style:y.cancelButtonStyle||q,onClick:me=>{hi(y.cancel)&&mn&&(y.cancel.onClick==null||y.cancel.onClick.call(y.cancel,me),zt())},className:On(j?.cancelButton,y==null||(v=y.classNames)==null?void 0:v.cancelButton)},y.cancel.label):null,oe.isValidElement(y.action)?y.action:y.action&&hi(y.action)?oe.createElement("button",{"data-button":!0,"data-action":!0,style:y.actionButtonStyle||re,onClick:me=>{hi(y.action)&&(y.action.onClick==null||y.action.onClick.call(y.action,me),!me.defaultPrevented&&zt())},className:On(j?.actionButton,y==null||(p=y.classNames)==null?void 0:p.actionButton)},y.action.label):null)};function Uv(){if(typeof window>"u"||typeof document>"u")return"ltr";const t=document.documentElement.getAttribute("dir");return t==="auto"||!t?window.getComputedStyle(document.documentElement).direction:t}function QC(t,r){const o={};return[t,r].forEach((s,c)=>{const u=c===1,m=u?"--mobile-offset":"--offset",h=u?$C:PC;function v(p){["top","right","bottom","left"].forEach(b=>{o[`${m}-${b}`]=typeof p=="number"?`${p}px`:p})}typeof s=="number"||typeof s=="string"?v(s):typeof s=="object"?["top","right","bottom","left"].forEach(p=>{s[p]===void 0?o[`${m}-${p}`]=h:o[`${m}-${p}`]=typeof s[p]=="number"?`${s[p]}px`:s[p]}):v(h)}),o}const KC=oe.forwardRef(function(r,o){const{id:s,invert:c,position:u="bottom-right",hotkey:m=["altKey","KeyT"],expand:h,closeButton:v,className:p,offset:b,mobileOffset:y,theme:S="light",richColors:A,duration:C,style:T,visibleToasts:E=HC,toastOptions:R,dir:k=Uv(),gap:O=VC,icons:U,containerAriaLabel:z="Notifications"}=r,[G,Y]=oe.useState([]),q=oe.useMemo(()=>s?G.filter(Q=>Q.toasterId===s):G.filter(Q=>!Q.toasterId),[G,s]),re=oe.useMemo(()=>Array.from(new Set([u].concat(q.filter(Q=>Q.position).map(Q=>Q.position)))),[q,u]),[fe,ue]=oe.useState([]),[de,W]=oe.useState(!1),[se,ee]=oe.useState(!1),[j,P]=oe.useState(S!=="system"?S:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),H=oe.useRef(null),F=m.join("+").replace(/Key/g,"").replace(/Digit/g,""),N=oe.useRef(null),I=oe.useRef(!1),J=oe.useCallback(Q=>{Y(le=>{var te;return(te=le.find(ae=>ae.id===Q.id))!=null&&te.delete||Pt.dismiss(Q.id),le.filter(({id:ae})=>ae!==Q.id)})},[]);return oe.useEffect(()=>Pt.subscribe(Q=>{if(Q.dismiss){requestAnimationFrame(()=>{Y(le=>le.map(te=>te.id===Q.id?{...te,delete:!0}:te))});return}setTimeout(()=>{Fy.flushSync(()=>{Y(le=>{const te=le.findIndex(ae=>ae.id===Q.id);return te!==-1?[...le.slice(0,te),{...le[te],...Q},...le.slice(te+1)]:[Q,...le]})})})}),[G]),oe.useEffect(()=>{if(S!=="system"){P(S);return}if(S==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?P("dark"):P("light")),typeof window>"u")return;const Q=window.matchMedia("(prefers-color-scheme: dark)");try{Q.addEventListener("change",({matches:le})=>{P(le?"dark":"light")})}catch{Q.addListener(({matches:te})=>{try{P(te?"dark":"light")}catch(ae){console.error(ae)}})}},[S]),oe.useEffect(()=>{G.length<=1&&W(!1)},[G]),oe.useEffect(()=>{const Q=le=>{var te;if(m.every(ce=>le[ce]||le.code===ce)){var ie;W(!0),(ie=H.current)==null||ie.focus()}le.code==="Escape"&&(document.activeElement===H.current||(te=H.current)!=null&&te.contains(document.activeElement))&&W(!1)};return document.addEventListener("keydown",Q),()=>document.removeEventListener("keydown",Q)},[m]),oe.useEffect(()=>{if(H.current)return()=>{N.current&&(N.current.focus({preventScroll:!0}),N.current=null,I.current=!1)}},[H.current]),oe.createElement("section",{ref:o,"aria-label":`${z} ${F}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},re.map((Q,le)=>{var te;const[ae,ie]=Q.split("-");return q.length?oe.createElement("ol",{key:Q,dir:k==="auto"?Uv():k,tabIndex:-1,ref:H,className:p,"data-sonner-toaster":!0,"data-sonner-theme":j,"data-y-position":ae,"data-x-position":ie,style:{"--front-toast-height":`${((te=fe[0])==null?void 0:te.height)||0}px`,"--width":`${qC}px`,"--gap":`${O}px`,...T,...QC(b,y)},onBlur:ce=>{I.current&&!ce.currentTarget.contains(ce.relatedTarget)&&(I.current=!1,N.current&&(N.current.focus({preventScroll:!0}),N.current=null))},onFocus:ce=>{ce.target instanceof HTMLElement&&ce.target.dataset.dismissible==="false"||I.current||(I.current=!0,N.current=ce.relatedTarget)},onMouseEnter:()=>W(!0),onMouseMove:()=>W(!0),onMouseLeave:()=>{se||W(!1)},onDragEnd:()=>W(!1),onPointerDown:ce=>{ce.target instanceof HTMLElement&&ce.target.dataset.dismissible==="false"||ee(!0)},onPointerUp:()=>ee(!1)},q.filter(ce=>!ce.position&&le===0||ce.position===Q).map((ce,xe)=>{var Re,Te;return oe.createElement(XC,{key:ce.id,icons:U,index:xe,toast:ce,defaultRichColors:A,duration:(Re=R?.duration)!=null?Re:C,className:R?.className,descriptionClassName:R?.descriptionClassName,invert:c,visibleToasts:E,closeButton:(Te=R?.closeButton)!=null?Te:v,interacting:se,position:Q,style:R?.style,unstyled:R?.unstyled,classNames:R?.classNames,cancelButtonStyle:R?.cancelButtonStyle,actionButtonStyle:R?.actionButtonStyle,closeButtonAriaLabel:R?.closeButtonAriaLabel,removeToast:J,toasts:q.filter(Ae=>Ae.position==ce.position),heights:fe.filter(Ae=>Ae.position==ce.position),setHeights:ue,expandByDefault:h,gap:O,expanded:de,swipeDirections:r.swipeDirections})})):null}))}),Bv=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,Hv=mb,Ab=(t,r)=>o=>{var s;if(r?.variants==null)return Hv(t,o?.class,o?.className);const{variants:c,defaultVariants:u}=r,m=Object.keys(c).map(p=>{const b=o?.[p],y=u?.[p];if(b===null)return null;const S=Bv(b)||Bv(y);return c[p][S]}),h=o&&Object.entries(o).reduce((p,b)=>{let[y,S]=b;return S===void 0||(p[y]=S),p},{}),v=r==null||(s=r.compoundVariants)===null||s===void 0?void 0:s.reduce((p,b)=>{let{class:y,className:S,...A}=b;return Object.entries(A).every(C=>{let[T,E]=C;return Array.isArray(E)?E.includes({...u,...h}[T]):{...u,...h}[T]===E})?[...p,y,S]:p},[]);return Hv(t,m,v,o?.class,o?.className)},ZC=Ab("inline-flex items-center rounded-sm border px-1.5 py-0 text-[10px] font-semibold leading-4 transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function xn({className:t,variant:r,...o}){return f.jsx("div",{className:ne(ZC({variant:r}),t),...o})}const $l=g.forwardRef(({className:t,...r},o)=>f.jsx("div",{ref:o,className:ne("rounded-sm border border-border/70 bg-card/80 text-card-foreground shadow-none",t),...r}));$l.displayName="Card";const ql=g.forwardRef(({className:t,...r},o)=>f.jsx("div",{ref:o,className:ne("flex flex-col space-y-1 p-3",t),...r}));ql.displayName="CardHeader";const Vl=g.forwardRef(({className:t,...r},o)=>f.jsx("div",{ref:o,className:ne("text-[12px] font-semibold leading-none tracking-tight",t),...r}));Vl.displayName="CardTitle";const Il=g.forwardRef(({className:t,...r},o)=>f.jsx("div",{ref:o,className:ne("text-[10px] text-muted-foreground",t),...r}));Il.displayName="CardDescription";const Yl=g.forwardRef(({className:t,...r},o)=>f.jsx("div",{ref:o,className:ne("p-3 pt-0",t),...r}));Yl.displayName="CardContent";const FC=g.forwardRef(({className:t,...r},o)=>f.jsx("div",{ref:o,className:ne("flex items-center p-3 pt-0",t),...r}));FC.displayName="CardFooter";function Pv(t,r){if(typeof t=="function")return t(r);t!=null&&(t.current=r)}function Qf(...t){return r=>{let o=!1;const s=t.map(c=>{const u=Pv(c,r);return!o&&typeof u=="function"&&(o=!0),u});if(o)return()=>{for(let c=0;c<s.length;c++){const u=s[c];typeof u=="function"?u():Pv(t[c],null)}}}}function Fe(...t){return g.useCallback(Qf(...t),t)}var WC=Symbol.for("react.lazy"),Mi=Df[" use ".trim().toString()];function JC(t){return typeof t=="object"&&t!==null&&"then"in t}function kb(t){return t!=null&&typeof t=="object"&&"$$typeof"in t&&t.$$typeof===WC&&"_payload"in t&&JC(t._payload)}function eR(t){const r=nR(t),o=g.forwardRef((s,c)=>{let{children:u,...m}=s;kb(u)&&typeof Mi=="function"&&(u=Mi(u._payload));const h=g.Children.toArray(u),v=h.find(rR);if(v){const p=v.props.children,b=h.map(y=>y===v?g.Children.count(p)>1?g.Children.only(null):g.isValidElement(p)?p.props.children:null:y);return f.jsx(r,{...m,ref:c,children:g.isValidElement(p)?g.cloneElement(p,void 0,b):null})}return f.jsx(r,{...m,ref:c,children:u})});return o.displayName=`${t}.Slot`,o}var tR=eR("Slot");function nR(t){const r=g.forwardRef((o,s)=>{let{children:c,...u}=o;if(kb(c)&&typeof Mi=="function"&&(c=Mi(c._payload)),g.isValidElement(c)){const m=lR(c),h=oR(u,c.props);return c.type!==g.Fragment&&(h.ref=s?Qf(s,m):m),g.cloneElement(c,h)}return g.Children.count(c)>1?g.Children.only(null):null});return r.displayName=`${t}.SlotClone`,r}var aR=Symbol("radix.slottable");function rR(t){return g.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===aR}function oR(t,r){const o={...r};for(const s in r){const c=t[s],u=r[s];/^on[A-Z]/.test(s)?c&&u?o[s]=(...h)=>{const v=u(...h);return c(...h),v}:c&&(o[s]=c):s==="style"?o[s]={...c,...u}:s==="className"&&(o[s]=[c,u].filter(Boolean).join(" "))}return{...t,...o}}function lR(t){let r=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?t.ref:(r=Object.getOwnPropertyDescriptor(t,"ref")?.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?t.props.ref:t.props.ref||t.ref)}const Kf=Ab("inline-flex items-center justify-center gap-1.5 whitespace-nowrap rounded-sm border-0 text-[11px] font-semibold shadow-none transition-colors duration-150 ease-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/70 focus-visible:ring-offset-2 active:bg-muted/70 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"bg-muted/55 text-foreground hover:bg-muted/75 hover:text-foreground",secondary:"bg-muted/55 text-foreground hover:bg-muted/75",ghost:"bg-transparent text-muted-foreground hover:bg-muted/55 hover:text-foreground",link:"bg-transparent text-primary underline-offset-4 hover:underline"},size:{default:"h-8 px-3 py-1.5",sm:"h-7 rounded-sm px-2 text-[10px]",lg:"h-8 rounded-sm px-4 text-[11px]",icon:"h-8 w-8 rounded-sm"}},defaultVariants:{variant:"default",size:"default"}}),Nt=g.forwardRef(({className:t,variant:r,size:o,asChild:s=!1,...c},u)=>{const m=s?tR:"button";return f.jsx(m,{className:ne(Kf({variant:r,size:o,className:t})),ref:u,...c})});Nt.displayName="Button";async function sR(t,r={}){try{await ve("/telemetry/events",{method:"POST",body:JSON.stringify({name:`feature.${t}`,appType:"browser",dimensions:r})})}catch{}}function ze(t,r,{checkForDefaultPrevented:o=!0}={}){return function(c){if(t?.(c),o===!1||!c.defaultPrevented)return r?.(c)}}function iR(t,r){const o=g.createContext(r),s=u=>{const{children:m,...h}=u,v=g.useMemo(()=>h,Object.values(h));return f.jsx(o.Provider,{value:v,children:m})};s.displayName=t+"Provider";function c(u){const m=g.useContext(o);if(m)return m;if(r!==void 0)return r;throw new Error(`\`${u}\` must be used within \`${t}\``)}return[s,c]}function Ya(t,r=[]){let o=[];function s(u,m){const h=g.createContext(m),v=o.length;o=[...o,m];const p=y=>{const{scope:S,children:A,...C}=y,T=S?.[t]?.[v]||h,E=g.useMemo(()=>C,Object.values(C));return f.jsx(T.Provider,{value:E,children:A})};p.displayName=u+"Provider";function b(y,S){const A=S?.[t]?.[v]||h,C=g.useContext(A);if(C)return C;if(m!==void 0)return m;throw new Error(`\`${y}\` must be used within \`${u}\``)}return[p,b]}const c=()=>{const u=o.map(m=>g.createContext(m));return function(h){const v=h?.[t]||u;return g.useMemo(()=>({[`__scope${t}`]:{...h,[t]:v}}),[h,v])}};return c.scopeName=t,[s,cR(c,...r)]}function cR(...t){const r=t[0];if(t.length===1)return r;const o=()=>{const s=t.map(c=>({useScope:c(),scopeName:c.scopeName}));return function(u){const m=s.reduce((h,{useScope:v,scopeName:p})=>{const y=v(u)[`__scope${p}`];return{...h,...y}},{});return g.useMemo(()=>({[`__scope${r.scopeName}`]:m}),[m])}};return o.scopeName=r.scopeName,o}var Ot=globalThis?.document?g.useLayoutEffect:()=>{},uR=Df[" useId ".trim().toString()]||(()=>{}),dR=0;function Ha(t){const[r,o]=g.useState(uR());return Ot(()=>{o(s=>s??String(dR++))},[t]),r?`radix-${r}`:""}var fR=Df[" useInsertionEffect ".trim().toString()]||Ot;function To({prop:t,defaultProp:r,onChange:o=()=>{},caller:s}){const[c,u,m]=mR({defaultProp:r,onChange:o}),h=t!==void 0,v=h?t:c;{const b=g.useRef(t!==void 0);g.useEffect(()=>{const y=b.current;y!==h&&console.warn(`${s} is changing from ${y?"controlled":"uncontrolled"} to ${h?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),b.current=h},[h,s])}const p=g.useCallback(b=>{if(h){const y=hR(b)?b(t):b;y!==t&&m.current?.(y)}else u(b)},[h,t,u,m]);return[v,p]}function mR({defaultProp:t,onChange:r}){const[o,s]=g.useState(t),c=g.useRef(o),u=g.useRef(r);return fR(()=>{u.current=r},[r]),g.useEffect(()=>{c.current!==o&&(u.current?.(o),c.current=o)},[o,c]),[o,s,u]}function hR(t){return typeof t=="function"}function Gl(t){const r=pR(t),o=g.forwardRef((s,c)=>{const{children:u,...m}=s,h=g.Children.toArray(u),v=h.find(vR);if(v){const p=v.props.children,b=h.map(y=>y===v?g.Children.count(p)>1?g.Children.only(null):g.isValidElement(p)?p.props.children:null:y);return f.jsx(r,{...m,ref:c,children:g.isValidElement(p)?g.cloneElement(p,void 0,b):null})}return f.jsx(r,{...m,ref:c,children:u})});return o.displayName=`${t}.Slot`,o}function pR(t){const r=g.forwardRef((o,s)=>{const{children:c,...u}=o;if(g.isValidElement(c)){const m=bR(c),h=yR(u,c.props);return c.type!==g.Fragment&&(h.ref=s?Qf(s,m):m),g.cloneElement(c,h)}return g.Children.count(c)>1?g.Children.only(null):null});return r.displayName=`${t}.SlotClone`,r}var _b=Symbol("radix.slottable");function gR(t){const r=({children:o})=>f.jsx(f.Fragment,{children:o});return r.displayName=`${t}.Slottable`,r.__radixId=_b,r}function vR(t){return g.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===_b}function yR(t,r){const o={...r};for(const s in r){const c=t[s],u=r[s];/^on[A-Z]/.test(s)?c&&u?o[s]=(...h)=>{const v=u(...h);return c(...h),v}:c&&(o[s]=c):s==="style"?o[s]={...c,...u}:s==="className"&&(o[s]=[c,u].filter(Boolean).join(" "))}return{...t,...o}}function bR(t){let r=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?t.ref:(r=Object.getOwnPropertyDescriptor(t,"ref")?.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?t.props.ref:t.props.ref||t.ref)}var xR=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Le=xR.reduce((t,r)=>{const o=Gl(`Primitive.${r}`),s=g.forwardRef((c,u)=>{const{asChild:m,...h}=c,v=m?o:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(v,{...h,ref:u})});return s.displayName=`Primitive.${r}`,{...t,[r]:s}},{});function wR(t,r){t&&Zl.flushSync(()=>t.dispatchEvent(r))}function $a(t){const r=g.useRef(t);return g.useEffect(()=>{r.current=t}),g.useMemo(()=>(...o)=>r.current?.(...o),[])}function SR(t,r=globalThis?.document){const o=$a(t);g.useEffect(()=>{const s=c=>{c.key==="Escape"&&o(c)};return r.addEventListener("keydown",s,{capture:!0}),()=>r.removeEventListener("keydown",s,{capture:!0})},[o,r])}var ER="DismissableLayer",df="dismissableLayer.update",TR="dismissableLayer.pointerDownOutside",NR="dismissableLayer.focusOutside",$v,jb=g.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Zf=g.forwardRef((t,r)=>{const{disableOutsidePointerEvents:o=!1,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:u,onInteractOutside:m,onDismiss:h,...v}=t,p=g.useContext(jb),[b,y]=g.useState(null),S=b?.ownerDocument??globalThis?.document,[,A]=g.useState({}),C=Fe(r,Y=>y(Y)),T=Array.from(p.layers),[E]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),R=T.indexOf(E),k=b?T.indexOf(b):-1,O=p.layersWithOutsidePointerEventsDisabled.size>0,U=k>=R,z=AR(Y=>{const q=Y.target,re=[...p.branches].some(fe=>fe.contains(q));!U||re||(c?.(Y),m?.(Y),Y.defaultPrevented||h?.())},S),G=kR(Y=>{const q=Y.target;[...p.branches].some(fe=>fe.contains(q))||(u?.(Y),m?.(Y),Y.defaultPrevented||h?.())},S);return SR(Y=>{k===p.layers.size-1&&(s?.(Y),!Y.defaultPrevented&&h&&(Y.preventDefault(),h()))},S),g.useEffect(()=>{if(b)return o&&(p.layersWithOutsidePointerEventsDisabled.size===0&&($v=S.body.style.pointerEvents,S.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(b)),p.layers.add(b),qv(),()=>{o&&p.layersWithOutsidePointerEventsDisabled.size===1&&(S.body.style.pointerEvents=$v)}},[b,S,o,p]),g.useEffect(()=>()=>{b&&(p.layers.delete(b),p.layersWithOutsidePointerEventsDisabled.delete(b),qv())},[b,p]),g.useEffect(()=>{const Y=()=>A({});return document.addEventListener(df,Y),()=>document.removeEventListener(df,Y)},[]),f.jsx(Le.div,{...v,ref:C,style:{pointerEvents:O?U?"auto":"none":void 0,...t.style},onFocusCapture:ze(t.onFocusCapture,G.onFocusCapture),onBlurCapture:ze(t.onBlurCapture,G.onBlurCapture),onPointerDownCapture:ze(t.onPointerDownCapture,z.onPointerDownCapture)})});Zf.displayName=ER;var CR="DismissableLayerBranch",RR=g.forwardRef((t,r)=>{const o=g.useContext(jb),s=g.useRef(null),c=Fe(r,s);return g.useEffect(()=>{const u=s.current;if(u)return o.branches.add(u),()=>{o.branches.delete(u)}},[o.branches]),f.jsx(Le.div,{...t,ref:c})});RR.displayName=CR;function AR(t,r=globalThis?.document){const o=$a(t),s=g.useRef(!1),c=g.useRef(()=>{});return g.useEffect(()=>{const u=h=>{if(h.target&&!s.current){let v=function(){Ob(TR,o,p,{discrete:!0})};const p={originalEvent:h};h.pointerType==="touch"?(r.removeEventListener("click",c.current),c.current=v,r.addEventListener("click",c.current,{once:!0})):v()}else r.removeEventListener("click",c.current);s.current=!1},m=window.setTimeout(()=>{r.addEventListener("pointerdown",u)},0);return()=>{window.clearTimeout(m),r.removeEventListener("pointerdown",u),r.removeEventListener("click",c.current)}},[r,o]),{onPointerDownCapture:()=>s.current=!0}}function kR(t,r=globalThis?.document){const o=$a(t),s=g.useRef(!1);return g.useEffect(()=>{const c=u=>{u.target&&!s.current&&Ob(NR,o,{originalEvent:u},{discrete:!1})};return r.addEventListener("focusin",c),()=>r.removeEventListener("focusin",c)},[r,o]),{onFocusCapture:()=>s.current=!0,onBlurCapture:()=>s.current=!1}}function qv(){const t=new CustomEvent(df);document.dispatchEvent(t)}function Ob(t,r,o,{discrete:s}){const c=o.originalEvent.target,u=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:o});r&&c.addEventListener(t,r,{once:!0}),s?wR(c,u):c.dispatchEvent(u)}var Bd="focusScope.autoFocusOnMount",Hd="focusScope.autoFocusOnUnmount",Vv={bubbles:!1,cancelable:!0},_R="FocusScope",Ff=g.forwardRef((t,r)=>{const{loop:o=!1,trapped:s=!1,onMountAutoFocus:c,onUnmountAutoFocus:u,...m}=t,[h,v]=g.useState(null),p=$a(c),b=$a(u),y=g.useRef(null),S=Fe(r,T=>v(T)),A=g.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;g.useEffect(()=>{if(s){let T=function(O){if(A.paused||!h)return;const U=O.target;h.contains(U)?y.current=U:Ua(y.current,{select:!0})},E=function(O){if(A.paused||!h)return;const U=O.relatedTarget;U!==null&&(h.contains(U)||Ua(y.current,{select:!0}))},R=function(O){if(document.activeElement===document.body)for(const z of O)z.removedNodes.length>0&&Ua(h)};document.addEventListener("focusin",T),document.addEventListener("focusout",E);const k=new MutationObserver(R);return h&&k.observe(h,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",T),document.removeEventListener("focusout",E),k.disconnect()}}},[s,h,A.paused]),g.useEffect(()=>{if(h){Yv.add(A);const T=document.activeElement;if(!h.contains(T)){const R=new CustomEvent(Bd,Vv);h.addEventListener(Bd,p),h.dispatchEvent(R),R.defaultPrevented||(jR(LR(Db(h)),{select:!0}),document.activeElement===T&&Ua(h))}return()=>{h.removeEventListener(Bd,p),setTimeout(()=>{const R=new CustomEvent(Hd,Vv);h.addEventListener(Hd,b),h.dispatchEvent(R),R.defaultPrevented||Ua(T??document.body,{select:!0}),h.removeEventListener(Hd,b),Yv.remove(A)},0)}}},[h,p,b,A]);const C=g.useCallback(T=>{if(!o&&!s||A.paused)return;const E=T.key==="Tab"&&!T.altKey&&!T.ctrlKey&&!T.metaKey,R=document.activeElement;if(E&&R){const k=T.currentTarget,[O,U]=OR(k);O&&U?!T.shiftKey&&R===U?(T.preventDefault(),o&&Ua(O,{select:!0})):T.shiftKey&&R===O&&(T.preventDefault(),o&&Ua(U,{select:!0})):R===k&&T.preventDefault()}},[o,s,A.paused]);return f.jsx(Le.div,{tabIndex:-1,...m,ref:S,onKeyDown:C})});Ff.displayName=_R;function jR(t,{select:r=!1}={}){const o=document.activeElement;for(const s of t)if(Ua(s,{select:r}),document.activeElement!==o)return}function OR(t){const r=Db(t),o=Iv(r,t),s=Iv(r.reverse(),t);return[o,s]}function Db(t){const r=[],o=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:s=>{const c=s.tagName==="INPUT"&&s.type==="hidden";return s.disabled||s.hidden||c?NodeFilter.FILTER_SKIP:s.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;o.nextNode();)r.push(o.currentNode);return r}function Iv(t,r){for(const o of t)if(!DR(o,{upTo:r}))return o}function DR(t,{upTo:r}){if(getComputedStyle(t).visibility==="hidden")return!0;for(;t;){if(r!==void 0&&t===r)return!1;if(getComputedStyle(t).display==="none")return!0;t=t.parentElement}return!1}function MR(t){return t instanceof HTMLInputElement&&"select"in t}function Ua(t,{select:r=!1}={}){if(t&&t.focus){const o=document.activeElement;t.focus({preventScroll:!0}),t!==o&&MR(t)&&r&&t.select()}}var Yv=zR();function zR(){let t=[];return{add(r){const o=t[0];r!==o&&o?.pause(),t=Gv(t,r),t.unshift(r)},remove(r){t=Gv(t,r),t[0]?.resume()}}}function Gv(t,r){const o=[...t],s=o.indexOf(r);return s!==-1&&o.splice(s,1),o}function LR(t){return t.filter(r=>r.tagName!=="A")}var UR="Portal",Wf=g.forwardRef((t,r)=>{const{container:o,...s}=t,[c,u]=g.useState(!1);Ot(()=>u(!0),[]);const m=o||c&&globalThis?.document?.body;return m?Fy.createPortal(f.jsx(Le.div,{...s,ref:r}),m):null});Wf.displayName=UR;function BR(t,r){return g.useReducer((o,s)=>r[o][s]??o,t)}var _o=t=>{const{present:r,children:o}=t,s=HR(r),c=typeof o=="function"?o({present:s.isPresent}):g.Children.only(o),u=Fe(s.ref,PR(c));return typeof o=="function"||s.isPresent?g.cloneElement(c,{ref:u}):null};_o.displayName="Presence";function HR(t){const[r,o]=g.useState(),s=g.useRef(null),c=g.useRef(t),u=g.useRef("none"),m=t?"mounted":"unmounted",[h,v]=BR(m,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return g.useEffect(()=>{const p=pi(s.current);u.current=h==="mounted"?p:"none"},[h]),Ot(()=>{const p=s.current,b=c.current;if(b!==t){const S=u.current,A=pi(p);t?v("MOUNT"):A==="none"||p?.display==="none"?v("UNMOUNT"):v(b&&S!==A?"ANIMATION_OUT":"UNMOUNT"),c.current=t}},[t,v]),Ot(()=>{if(r){let p;const b=r.ownerDocument.defaultView??window,y=A=>{const T=pi(s.current).includes(CSS.escape(A.animationName));if(A.target===r&&T&&(v("ANIMATION_END"),!c.current)){const E=r.style.animationFillMode;r.style.animationFillMode="forwards",p=b.setTimeout(()=>{r.style.animationFillMode==="forwards"&&(r.style.animationFillMode=E)})}},S=A=>{A.target===r&&(u.current=pi(s.current))};return r.addEventListener("animationstart",S),r.addEventListener("animationcancel",y),r.addEventListener("animationend",y),()=>{b.clearTimeout(p),r.removeEventListener("animationstart",S),r.removeEventListener("animationcancel",y),r.removeEventListener("animationend",y)}}else v("ANIMATION_END")},[r,v]),{isPresent:["mounted","unmountSuspended"].includes(h),ref:g.useCallback(p=>{s.current=p?getComputedStyle(p):null,o(p)},[])}}function pi(t){return t?.animationName||"none"}function PR(t){let r=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?t.ref:(r=Object.getOwnPropertyDescriptor(t,"ref")?.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?t.props.ref:t.props.ref||t.ref)}var Pd=0;function Mb(){g.useEffect(()=>{const t=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",t[0]??Xv()),document.body.insertAdjacentElement("beforeend",t[1]??Xv()),Pd++,()=>{Pd===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),Pd--}},[])}function Xv(){const t=document.createElement("span");return t.setAttribute("data-radix-focus-guard",""),t.tabIndex=0,t.style.outline="none",t.style.opacity="0",t.style.position="fixed",t.style.pointerEvents="none",t}var Dn=function(){return Dn=Object.assign||function(r){for(var o,s=1,c=arguments.length;s<c;s++){o=arguments[s];for(var u in o)Object.prototype.hasOwnProperty.call(o,u)&&(r[u]=o[u])}return r},Dn.apply(this,arguments)};function zb(t,r){var o={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&r.indexOf(s)<0&&(o[s]=t[s]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var c=0,s=Object.getOwnPropertySymbols(t);c<s.length;c++)r.indexOf(s[c])<0&&Object.prototype.propertyIsEnumerable.call(t,s[c])&&(o[s[c]]=t[s[c]]);return o}function $R(t,r,o){if(o||arguments.length===2)for(var s=0,c=r.length,u;s<c;s++)(u||!(s in r))&&(u||(u=Array.prototype.slice.call(r,0,s)),u[s]=r[s]);return t.concat(u||Array.prototype.slice.call(r))}var Ti="right-scroll-bar-position",Ni="width-before-scroll-bar",qR="with-scroll-bars-hidden",VR="--removed-body-scroll-bar-size";function $d(t,r){return typeof t=="function"?t(r):t&&(t.current=r),t}function IR(t,r){var o=g.useState(function(){return{value:t,callback:r,facade:{get current(){return o.value},set current(s){var c=o.value;c!==s&&(o.value=s,o.callback(s,c))}}}})[0];return o.callback=r,o.facade}var YR=typeof window<"u"?g.useLayoutEffect:g.useEffect,Qv=new WeakMap;function GR(t,r){var o=IR(null,function(s){return t.forEach(function(c){return $d(c,s)})});return YR(function(){var s=Qv.get(o);if(s){var c=new Set(s),u=new Set(t),m=o.current;c.forEach(function(h){u.has(h)||$d(h,null)}),u.forEach(function(h){c.has(h)||$d(h,m)})}Qv.set(o,t)},[t]),o}function XR(t){return t}function QR(t,r){r===void 0&&(r=XR);var o=[],s=!1,c={read:function(){if(s)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return o.length?o[o.length-1]:t},useMedium:function(u){var m=r(u,s);return o.push(m),function(){o=o.filter(function(h){return h!==m})}},assignSyncMedium:function(u){for(s=!0;o.length;){var m=o;o=[],m.forEach(u)}o={push:function(h){return u(h)},filter:function(){return o}}},assignMedium:function(u){s=!0;var m=[];if(o.length){var h=o;o=[],h.forEach(u),m=o}var v=function(){var b=m;m=[],b.forEach(u)},p=function(){return Promise.resolve().then(v)};p(),o={push:function(b){m.push(b),p()},filter:function(b){return m=m.filter(b),o}}}};return c}function KR(t){t===void 0&&(t={});var r=QR(null);return r.options=Dn({async:!0,ssr:!1},t),r}var Lb=function(t){var r=t.sideCar,o=zb(t,["sideCar"]);if(!r)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var s=r.read();if(!s)throw new Error("Sidecar medium not found");return g.createElement(s,Dn({},o))};Lb.isSideCarExport=!0;function ZR(t,r){return t.useMedium(r),Lb}var Ub=KR(),qd=function(){},oc=g.forwardRef(function(t,r){var o=g.useRef(null),s=g.useState({onScrollCapture:qd,onWheelCapture:qd,onTouchMoveCapture:qd}),c=s[0],u=s[1],m=t.forwardProps,h=t.children,v=t.className,p=t.removeScrollBar,b=t.enabled,y=t.shards,S=t.sideCar,A=t.noRelative,C=t.noIsolation,T=t.inert,E=t.allowPinchZoom,R=t.as,k=R===void 0?"div":R,O=t.gapMode,U=zb(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),z=S,G=GR([o,r]),Y=Dn(Dn({},U),c);return g.createElement(g.Fragment,null,b&&g.createElement(z,{sideCar:Ub,removeScrollBar:p,shards:y,noRelative:A,noIsolation:C,inert:T,setCallbacks:u,allowPinchZoom:!!E,lockRef:o,gapMode:O}),m?g.cloneElement(g.Children.only(h),Dn(Dn({},Y),{ref:G})):g.createElement(k,Dn({},Y,{className:v,ref:G}),h))});oc.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};oc.classNames={fullWidth:Ni,zeroRight:Ti};var FR=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function WR(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var r=FR();return r&&t.setAttribute("nonce",r),t}function JR(t,r){t.styleSheet?t.styleSheet.cssText=r:t.appendChild(document.createTextNode(r))}function eA(t){var r=document.head||document.getElementsByTagName("head")[0];r.appendChild(t)}var tA=function(){var t=0,r=null;return{add:function(o){t==0&&(r=WR())&&(JR(r,o),eA(r)),t++},remove:function(){t--,!t&&r&&(r.parentNode&&r.parentNode.removeChild(r),r=null)}}},nA=function(){var t=tA();return function(r,o){g.useEffect(function(){return t.add(r),function(){t.remove()}},[r&&o])}},Bb=function(){var t=nA(),r=function(o){var s=o.styles,c=o.dynamic;return t(s,c),null};return r},aA={left:0,top:0,right:0,gap:0},Vd=function(t){return parseInt(t||"",10)||0},rA=function(t){var r=window.getComputedStyle(document.body),o=r[t==="padding"?"paddingLeft":"marginLeft"],s=r[t==="padding"?"paddingTop":"marginTop"],c=r[t==="padding"?"paddingRight":"marginRight"];return[Vd(o),Vd(s),Vd(c)]},oA=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return aA;var r=rA(t),o=document.documentElement.clientWidth,s=window.innerWidth;return{left:r[0],top:r[1],right:r[2],gap:Math.max(0,s-o+r[2]-r[0])}},lA=Bb(),wo="data-scroll-locked",sA=function(t,r,o,s){var c=t.left,u=t.top,m=t.right,h=t.gap;return o===void 0&&(o="margin"),`
287
+ .`.concat(qR,` {
288
+ overflow: hidden `).concat(s,`;
289
+ padding-right: `).concat(h,"px ").concat(s,`;
290
+ }
291
+ body[`).concat(wo,`] {
292
+ overflow: hidden `).concat(s,`;
293
+ overscroll-behavior: contain;
294
+ `).concat([r&&"position: relative ".concat(s,";"),o==="margin"&&`
295
+ padding-left: `.concat(c,`px;
296
+ padding-top: `).concat(u,`px;
297
+ padding-right: `).concat(m,`px;
298
+ margin-left:0;
299
+ margin-top:0;
300
+ margin-right: `).concat(h,"px ").concat(s,`;
301
+ `),o==="padding"&&"padding-right: ".concat(h,"px ").concat(s,";")].filter(Boolean).join(""),`
302
+ }
303
+
304
+ .`).concat(Ti,` {
305
+ right: `).concat(h,"px ").concat(s,`;
306
+ }
307
+
308
+ .`).concat(Ni,` {
309
+ margin-right: `).concat(h,"px ").concat(s,`;
310
+ }
311
+
312
+ .`).concat(Ti," .").concat(Ti,` {
313
+ right: 0 `).concat(s,`;
314
+ }
315
+
316
+ .`).concat(Ni," .").concat(Ni,` {
317
+ margin-right: 0 `).concat(s,`;
318
+ }
319
+
320
+ body[`).concat(wo,`] {
321
+ `).concat(VR,": ").concat(h,`px;
322
+ }
323
+ `)},Kv=function(){var t=parseInt(document.body.getAttribute(wo)||"0",10);return isFinite(t)?t:0},iA=function(){g.useEffect(function(){return document.body.setAttribute(wo,(Kv()+1).toString()),function(){var t=Kv()-1;t<=0?document.body.removeAttribute(wo):document.body.setAttribute(wo,t.toString())}},[])},cA=function(t){var r=t.noRelative,o=t.noImportant,s=t.gapMode,c=s===void 0?"margin":s;iA();var u=g.useMemo(function(){return oA(c)},[c]);return g.createElement(lA,{styles:sA(u,!r,c,o?"":"!important")})},ff=!1;if(typeof window<"u")try{var gi=Object.defineProperty({},"passive",{get:function(){return ff=!0,!0}});window.addEventListener("test",gi,gi),window.removeEventListener("test",gi,gi)}catch{ff=!1}var ho=ff?{passive:!1}:!1,uA=function(t){return t.tagName==="TEXTAREA"},Hb=function(t,r){if(!(t instanceof Element))return!1;var o=window.getComputedStyle(t);return o[r]!=="hidden"&&!(o.overflowY===o.overflowX&&!uA(t)&&o[r]==="visible")},dA=function(t){return Hb(t,"overflowY")},fA=function(t){return Hb(t,"overflowX")},Zv=function(t,r){var o=r.ownerDocument,s=r;do{typeof ShadowRoot<"u"&&s instanceof ShadowRoot&&(s=s.host);var c=Pb(t,s);if(c){var u=$b(t,s),m=u[1],h=u[2];if(m>h)return!0}s=s.parentNode}while(s&&s!==o.body);return!1},mA=function(t){var r=t.scrollTop,o=t.scrollHeight,s=t.clientHeight;return[r,o,s]},hA=function(t){var r=t.scrollLeft,o=t.scrollWidth,s=t.clientWidth;return[r,o,s]},Pb=function(t,r){return t==="v"?dA(r):fA(r)},$b=function(t,r){return t==="v"?mA(r):hA(r)},pA=function(t,r){return t==="h"&&r==="rtl"?-1:1},gA=function(t,r,o,s,c){var u=pA(t,window.getComputedStyle(r).direction),m=u*s,h=o.target,v=r.contains(h),p=!1,b=m>0,y=0,S=0;do{if(!h)break;var A=$b(t,h),C=A[0],T=A[1],E=A[2],R=T-E-u*C;(C||R)&&Pb(t,h)&&(y+=R,S+=C);var k=h.parentNode;h=k&&k.nodeType===Node.DOCUMENT_FRAGMENT_NODE?k.host:k}while(!v&&h!==document.body||v&&(r.contains(h)||r===h));return(b&&Math.abs(y)<1||!b&&Math.abs(S)<1)&&(p=!0),p},vi=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},Fv=function(t){return[t.deltaX,t.deltaY]},Wv=function(t){return t&&"current"in t?t.current:t},vA=function(t,r){return t[0]===r[0]&&t[1]===r[1]},yA=function(t){return`
324
+ .block-interactivity-`.concat(t,` {pointer-events: none;}
325
+ .allow-interactivity-`).concat(t,` {pointer-events: all;}
326
+ `)},bA=0,po=[];function xA(t){var r=g.useRef([]),o=g.useRef([0,0]),s=g.useRef(),c=g.useState(bA++)[0],u=g.useState(Bb)[0],m=g.useRef(t);g.useEffect(function(){m.current=t},[t]),g.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(c));var T=$R([t.lockRef.current],(t.shards||[]).map(Wv),!0).filter(Boolean);return T.forEach(function(E){return E.classList.add("allow-interactivity-".concat(c))}),function(){document.body.classList.remove("block-interactivity-".concat(c)),T.forEach(function(E){return E.classList.remove("allow-interactivity-".concat(c))})}}},[t.inert,t.lockRef.current,t.shards]);var h=g.useCallback(function(T,E){if("touches"in T&&T.touches.length===2||T.type==="wheel"&&T.ctrlKey)return!m.current.allowPinchZoom;var R=vi(T),k=o.current,O="deltaX"in T?T.deltaX:k[0]-R[0],U="deltaY"in T?T.deltaY:k[1]-R[1],z,G=T.target,Y=Math.abs(O)>Math.abs(U)?"h":"v";if("touches"in T&&Y==="h"&&G.type==="range")return!1;var q=window.getSelection(),re=q&&q.anchorNode,fe=re?re===G||re.contains(G):!1;if(fe)return!1;var ue=Zv(Y,G);if(!ue)return!0;if(ue?z=Y:(z=Y==="v"?"h":"v",ue=Zv(Y,G)),!ue)return!1;if(!s.current&&"changedTouches"in T&&(O||U)&&(s.current=z),!z)return!0;var de=s.current||z;return gA(de,E,T,de==="h"?O:U)},[]),v=g.useCallback(function(T){var E=T;if(!(!po.length||po[po.length-1]!==u)){var R="deltaY"in E?Fv(E):vi(E),k=r.current.filter(function(z){return z.name===E.type&&(z.target===E.target||E.target===z.shadowParent)&&vA(z.delta,R)})[0];if(k&&k.should){E.cancelable&&E.preventDefault();return}if(!k){var O=(m.current.shards||[]).map(Wv).filter(Boolean).filter(function(z){return z.contains(E.target)}),U=O.length>0?h(E,O[0]):!m.current.noIsolation;U&&E.cancelable&&E.preventDefault()}}},[]),p=g.useCallback(function(T,E,R,k){var O={name:T,delta:E,target:R,should:k,shadowParent:wA(R)};r.current.push(O),setTimeout(function(){r.current=r.current.filter(function(U){return U!==O})},1)},[]),b=g.useCallback(function(T){o.current=vi(T),s.current=void 0},[]),y=g.useCallback(function(T){p(T.type,Fv(T),T.target,h(T,t.lockRef.current))},[]),S=g.useCallback(function(T){p(T.type,vi(T),T.target,h(T,t.lockRef.current))},[]);g.useEffect(function(){return po.push(u),t.setCallbacks({onScrollCapture:y,onWheelCapture:y,onTouchMoveCapture:S}),document.addEventListener("wheel",v,ho),document.addEventListener("touchmove",v,ho),document.addEventListener("touchstart",b,ho),function(){po=po.filter(function(T){return T!==u}),document.removeEventListener("wheel",v,ho),document.removeEventListener("touchmove",v,ho),document.removeEventListener("touchstart",b,ho)}},[]);var A=t.removeScrollBar,C=t.inert;return g.createElement(g.Fragment,null,C?g.createElement(u,{styles:yA(c)}):null,A?g.createElement(cA,{noRelative:t.noRelative,gapMode:t.gapMode}):null)}function wA(t){for(var r=null;t!==null;)t instanceof ShadowRoot&&(r=t.host,t=t.host),t=t.parentNode;return r}const SA=ZR(Ub,xA);var Jf=g.forwardRef(function(t,r){return g.createElement(oc,Dn({},t,{ref:r,sideCar:SA}))});Jf.classNames=oc.classNames;var EA=function(t){if(typeof document>"u")return null;var r=Array.isArray(t)?t[0]:t;return r.ownerDocument.body},go=new WeakMap,yi=new WeakMap,bi={},Id=0,qb=function(t){return t&&(t.host||qb(t.parentNode))},TA=function(t,r){return r.map(function(o){if(t.contains(o))return o;var s=qb(o);return s&&t.contains(s)?s:(console.error("aria-hidden",o,"in not contained inside",t,". Doing nothing"),null)}).filter(function(o){return!!o})},NA=function(t,r,o,s){var c=TA(r,Array.isArray(t)?t:[t]);bi[o]||(bi[o]=new WeakMap);var u=bi[o],m=[],h=new Set,v=new Set(c),p=function(y){!y||h.has(y)||(h.add(y),p(y.parentNode))};c.forEach(p);var b=function(y){!y||v.has(y)||Array.prototype.forEach.call(y.children,function(S){if(h.has(S))b(S);else try{var A=S.getAttribute(s),C=A!==null&&A!=="false",T=(go.get(S)||0)+1,E=(u.get(S)||0)+1;go.set(S,T),u.set(S,E),m.push(S),T===1&&C&&yi.set(S,!0),E===1&&S.setAttribute(o,"true"),C||S.setAttribute(s,"true")}catch(R){console.error("aria-hidden: cannot operate on ",S,R)}})};return b(r),h.clear(),Id++,function(){m.forEach(function(y){var S=go.get(y)-1,A=u.get(y)-1;go.set(y,S),u.set(y,A),S||(yi.has(y)||y.removeAttribute(s),yi.delete(y)),A||y.removeAttribute(o)}),Id--,Id||(go=new WeakMap,go=new WeakMap,yi=new WeakMap,bi={})}},Vb=function(t,r,o){o===void 0&&(o="data-aria-hidden");var s=Array.from(Array.isArray(t)?t:[t]),c=EA(t);return c?(s.push.apply(s,Array.from(c.querySelectorAll("[aria-live], script"))),NA(s,c,o,"aria-hidden")):function(){return null}},lc="Dialog",[Ib,Yb]=Ya(lc),[CA,Tn]=Ib(lc),Gb=t=>{const{__scopeDialog:r,children:o,open:s,defaultOpen:c,onOpenChange:u,modal:m=!0}=t,h=g.useRef(null),v=g.useRef(null),[p,b]=To({prop:s,defaultProp:c??!1,onChange:u,caller:lc});return f.jsx(CA,{scope:r,triggerRef:h,contentRef:v,contentId:Ha(),titleId:Ha(),descriptionId:Ha(),open:p,onOpenChange:b,onOpenToggle:g.useCallback(()=>b(y=>!y),[b]),modal:m,children:o})};Gb.displayName=lc;var Xb="DialogTrigger",Qb=g.forwardRef((t,r)=>{const{__scopeDialog:o,...s}=t,c=Tn(Xb,o),u=Fe(r,c.triggerRef);return f.jsx(Le.button,{type:"button","aria-haspopup":"dialog","aria-expanded":c.open,"aria-controls":c.contentId,"data-state":nm(c.open),...s,ref:u,onClick:ze(t.onClick,c.onOpenToggle)})});Qb.displayName=Xb;var em="DialogPortal",[RA,Kb]=Ib(em,{forceMount:void 0}),Zb=t=>{const{__scopeDialog:r,forceMount:o,children:s,container:c}=t,u=Tn(em,r);return f.jsx(RA,{scope:r,forceMount:o,children:g.Children.map(s,m=>f.jsx(_o,{present:o||u.open,children:f.jsx(Wf,{asChild:!0,container:c,children:m})}))})};Zb.displayName=em;var zi="DialogOverlay",Fb=g.forwardRef((t,r)=>{const o=Kb(zi,t.__scopeDialog),{forceMount:s=o.forceMount,...c}=t,u=Tn(zi,t.__scopeDialog);return u.modal?f.jsx(_o,{present:s||u.open,children:f.jsx(kA,{...c,ref:r})}):null});Fb.displayName=zi;var AA=Gl("DialogOverlay.RemoveScroll"),kA=g.forwardRef((t,r)=>{const{__scopeDialog:o,...s}=t,c=Tn(zi,o);return f.jsx(Jf,{as:AA,allowPinchZoom:!0,shards:[c.contentRef],children:f.jsx(Le.div,{"data-state":nm(c.open),...s,ref:r,style:{pointerEvents:"auto",...s.style}})})}),br="DialogContent",Wb=g.forwardRef((t,r)=>{const o=Kb(br,t.__scopeDialog),{forceMount:s=o.forceMount,...c}=t,u=Tn(br,t.__scopeDialog);return f.jsx(_o,{present:s||u.open,children:u.modal?f.jsx(_A,{...c,ref:r}):f.jsx(jA,{...c,ref:r})})});Wb.displayName=br;var _A=g.forwardRef((t,r)=>{const o=Tn(br,t.__scopeDialog),s=g.useRef(null),c=Fe(r,o.contentRef,s);return g.useEffect(()=>{const u=s.current;if(u)return Vb(u)},[]),f.jsx(Jb,{...t,ref:c,trapFocus:o.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ze(t.onCloseAutoFocus,u=>{u.preventDefault(),o.triggerRef.current?.focus()}),onPointerDownOutside:ze(t.onPointerDownOutside,u=>{const m=u.detail.originalEvent,h=m.button===0&&m.ctrlKey===!0;(m.button===2||h)&&u.preventDefault()}),onFocusOutside:ze(t.onFocusOutside,u=>u.preventDefault())})}),jA=g.forwardRef((t,r)=>{const o=Tn(br,t.__scopeDialog),s=g.useRef(!1),c=g.useRef(!1);return f.jsx(Jb,{...t,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:u=>{t.onCloseAutoFocus?.(u),u.defaultPrevented||(s.current||o.triggerRef.current?.focus(),u.preventDefault()),s.current=!1,c.current=!1},onInteractOutside:u=>{t.onInteractOutside?.(u),u.defaultPrevented||(s.current=!0,u.detail.originalEvent.type==="pointerdown"&&(c.current=!0));const m=u.target;o.triggerRef.current?.contains(m)&&u.preventDefault(),u.detail.originalEvent.type==="focusin"&&c.current&&u.preventDefault()}})}),Jb=g.forwardRef((t,r)=>{const{__scopeDialog:o,trapFocus:s,onOpenAutoFocus:c,onCloseAutoFocus:u,...m}=t,h=Tn(br,o),v=g.useRef(null),p=Fe(r,v);return Mb(),f.jsxs(f.Fragment,{children:[f.jsx(Ff,{asChild:!0,loop:!0,trapped:s,onMountAutoFocus:c,onUnmountAutoFocus:u,children:f.jsx(Zf,{role:"dialog",id:h.contentId,"aria-describedby":h.descriptionId,"aria-labelledby":h.titleId,"data-state":nm(h.open),...m,ref:p,onDismiss:()=>h.onOpenChange(!1)})}),f.jsxs(f.Fragment,{children:[f.jsx(DA,{titleId:h.titleId}),f.jsx(zA,{contentRef:v,descriptionId:h.descriptionId})]})]})}),tm="DialogTitle",e0=g.forwardRef((t,r)=>{const{__scopeDialog:o,...s}=t,c=Tn(tm,o);return f.jsx(Le.h2,{id:c.titleId,...s,ref:r})});e0.displayName=tm;var t0="DialogDescription",n0=g.forwardRef((t,r)=>{const{__scopeDialog:o,...s}=t,c=Tn(t0,o);return f.jsx(Le.p,{id:c.descriptionId,...s,ref:r})});n0.displayName=t0;var a0="DialogClose",r0=g.forwardRef((t,r)=>{const{__scopeDialog:o,...s}=t,c=Tn(a0,o);return f.jsx(Le.button,{type:"button",...s,ref:r,onClick:ze(t.onClick,()=>c.onOpenChange(!1))})});r0.displayName=a0;function nm(t){return t?"open":"closed"}var o0="DialogTitleWarning",[OA,l0]=iR(o0,{contentName:br,titleName:tm,docsSlug:"dialog"}),DA=({titleId:t})=>{const r=l0(o0),o=`\`${r.contentName}\` requires a \`${r.titleName}\` for the component to be accessible for screen reader users.
327
+
328
+ If you want to hide the \`${r.titleName}\`, you can wrap it with our VisuallyHidden component.
329
+
330
+ For more information, see https://radix-ui.com/primitives/docs/components/${r.docsSlug}`;return g.useEffect(()=>{t&&(document.getElementById(t)||console.error(o))},[o,t]),null},MA="DialogDescriptionWarning",zA=({contentRef:t,descriptionId:r})=>{const s=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${l0(MA).contentName}}.`;return g.useEffect(()=>{const c=t.current?.getAttribute("aria-describedby");r&&c&&(document.getElementById(r)||console.warn(s))},[s,t,r]),null},s0=Gb,i0=Qb,c0=Zb,am=Fb,rm=Wb,om=e0,lm=n0,sc=r0;const LA=s0,UA=i0,BA=c0,ZD=sc,u0=g.forwardRef(({className:t,...r},o)=>f.jsx(am,{ref:o,className:ne("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",t),...r}));u0.displayName=am.displayName;const d0=g.forwardRef(({className:t,children:r,...o},s)=>f.jsxs(BA,{children:[f.jsx(u0,{}),f.jsxs(rm,{ref:s,className:ne("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-3 rounded-sm border bg-background p-4 shadow-[0_24px_84px_-54px_rgba(0,0,0,0.55)] duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]",t),...o,children:[r,f.jsxs(sc,{className:"absolute right-2.5 top-2.5 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[f.jsx(Yf,{className:"h-3.5 w-3.5"}),f.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));d0.displayName=rm.displayName;const f0=({className:t,...r})=>f.jsx("div",{className:ne("flex flex-col space-y-1.5 text-center sm:text-left",t),...r});f0.displayName="DialogHeader";const HA=({className:t,...r})=>f.jsx("div",{className:ne("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",t),...r});HA.displayName="DialogFooter";const m0=g.forwardRef(({className:t,...r},o)=>f.jsx(om,{ref:o,className:ne("text-sm font-semibold leading-none tracking-tight",t),...r}));m0.displayName=om.displayName;const h0=g.forwardRef(({className:t,...r},o)=>f.jsx(lm,{ref:o,className:ne("text-[11px] text-muted-foreground",t),...r}));h0.displayName=lm.displayName;function PA({children:t,open:r,onOpenChange:o,showTrigger:s=!0}){const[c,u]=g.useState(!1),m=r??c,h=g.useCallback(v=>{v&&sR("settings.opened",{surface:"settings"}),r===void 0&&u(v),o?.(v)},[r,o]);return f.jsxs(LA,{open:m,onOpenChange:h,children:[s&&f.jsx(UA,{asChild:!0,children:f.jsx(Nt,{variant:"ghost",size:"icon","aria-label":"Settings",title:"Settings",className:"h-8 w-8 rounded-sm text-muted-foreground hover:bg-muted/50 hover:text-foreground",children:f.jsx(SN,{className:"h-4 w-4"})})}),f.jsxs(d0,{className:"settings-dialog-content grid h-[min(78vh,38rem)] max-h-[78vh] max-w-[min(86vw,50rem)] grid-rows-[auto_minmax(0,1fr)] gap-0 overflow-hidden rounded-sm border-border/70 bg-background/96 p-0 shadow-[0_28px_90px_-58px_rgba(15,23,42,0.75)] backdrop-blur-xl",children:[f.jsxs(f0,{className:"shrink-0 border-b border-border/60 px-3 py-1.5 sm:px-3.5",children:[f.jsxs(m0,{className:"flex items-center gap-1.5 text-[11px]",children:[f.jsx(lN,{className:"h-3.5 w-3.5 text-primary"}),"Settings"]}),f.jsx(h0,{className:"sr-only",children:"Runtime, agents, and quick chats for the current Meshy node. For host and access diagnostics, open node Properties."})]}),f.jsx("div",{className:"min-h-0 overflow-y-auto px-2.5 pb-2 pt-1 sm:px-3 sm:pb-2.5",children:t})]})]})}function Jv(t,[r,o]){return Math.min(o,Math.max(r,t))}function p0(t){const r=t+"CollectionProvider",[o,s]=Ya(r),[c,u]=o(r,{collectionRef:{current:null},itemMap:new Map}),m=T=>{const{scope:E,children:R}=T,k=oe.useRef(null),O=oe.useRef(new Map).current;return f.jsx(c,{scope:E,itemMap:O,collectionRef:k,children:R})};m.displayName=r;const h=t+"CollectionSlot",v=Gl(h),p=oe.forwardRef((T,E)=>{const{scope:R,children:k}=T,O=u(h,R),U=Fe(E,O.collectionRef);return f.jsx(v,{ref:U,children:k})});p.displayName=h;const b=t+"CollectionItemSlot",y="data-radix-collection-item",S=Gl(b),A=oe.forwardRef((T,E)=>{const{scope:R,children:k,...O}=T,U=oe.useRef(null),z=Fe(E,U),G=u(b,R);return oe.useEffect(()=>(G.itemMap.set(U,{ref:U,...O}),()=>{G.itemMap.delete(U)})),f.jsx(S,{[y]:"",ref:z,children:k})});A.displayName=b;function C(T){const E=u(t+"CollectionConsumer",T);return oe.useCallback(()=>{const k=E.collectionRef.current;if(!k)return[];const O=Array.from(k.querySelectorAll(`[${y}]`));return Array.from(E.itemMap.values()).sort((G,Y)=>O.indexOf(G.ref.current)-O.indexOf(Y.ref.current))},[E.collectionRef,E.itemMap])}return[{Provider:m,Slot:p,ItemSlot:A},C,s]}var $A=g.createContext(void 0);function sm(t){const r=g.useContext($A);return t||r||"ltr"}const qA=["top","right","bottom","left"],qa=Math.min,Zt=Math.max,Li=Math.round,xi=Math.floor,zn=t=>({x:t,y:t}),VA={left:"right",right:"left",bottom:"top",top:"bottom"};function mf(t,r,o){return Zt(t,qa(r,o))}function oa(t,r){return typeof t=="function"?t(r):t}function la(t){return t.split("-")[0]}function jo(t){return t.split("-")[1]}function im(t){return t==="x"?"y":"x"}function cm(t){return t==="y"?"height":"width"}function Mn(t){const r=t[0];return r==="t"||r==="b"?"y":"x"}function um(t){return im(Mn(t))}function IA(t,r,o){o===void 0&&(o=!1);const s=jo(t),c=um(t),u=cm(c);let m=c==="x"?s===(o?"end":"start")?"right":"left":s==="start"?"bottom":"top";return r.reference[u]>r.floating[u]&&(m=Ui(m)),[m,Ui(m)]}function YA(t){const r=Ui(t);return[hf(t),r,hf(r)]}function hf(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}const ey=["left","right"],ty=["right","left"],GA=["top","bottom"],XA=["bottom","top"];function QA(t,r,o){switch(t){case"top":case"bottom":return o?r?ty:ey:r?ey:ty;case"left":case"right":return r?GA:XA;default:return[]}}function KA(t,r,o,s){const c=jo(t);let u=QA(la(t),o==="start",s);return c&&(u=u.map(m=>m+"-"+c),r&&(u=u.concat(u.map(hf)))),u}function Ui(t){const r=la(t);return VA[r]+t.slice(r.length)}function ZA(t){return{top:0,right:0,bottom:0,left:0,...t}}function g0(t){return typeof t!="number"?ZA(t):{top:t,right:t,bottom:t,left:t}}function Bi(t){const{x:r,y:o,width:s,height:c}=t;return{width:s,height:c,top:o,left:r,right:r+s,bottom:o+c,x:r,y:o}}function ny(t,r,o){let{reference:s,floating:c}=t;const u=Mn(r),m=um(r),h=cm(m),v=la(r),p=u==="y",b=s.x+s.width/2-c.width/2,y=s.y+s.height/2-c.height/2,S=s[h]/2-c[h]/2;let A;switch(v){case"top":A={x:b,y:s.y-c.height};break;case"bottom":A={x:b,y:s.y+s.height};break;case"right":A={x:s.x+s.width,y};break;case"left":A={x:s.x-c.width,y};break;default:A={x:s.x,y:s.y}}switch(jo(r)){case"start":A[m]-=S*(o&&p?-1:1);break;case"end":A[m]+=S*(o&&p?-1:1);break}return A}async function FA(t,r){var o;r===void 0&&(r={});const{x:s,y:c,platform:u,rects:m,elements:h,strategy:v}=t,{boundary:p="clippingAncestors",rootBoundary:b="viewport",elementContext:y="floating",altBoundary:S=!1,padding:A=0}=oa(r,t),C=g0(A),E=h[S?y==="floating"?"reference":"floating":y],R=Bi(await u.getClippingRect({element:(o=await(u.isElement==null?void 0:u.isElement(E)))==null||o?E:E.contextElement||await(u.getDocumentElement==null?void 0:u.getDocumentElement(h.floating)),boundary:p,rootBoundary:b,strategy:v})),k=y==="floating"?{x:s,y:c,width:m.floating.width,height:m.floating.height}:m.reference,O=await(u.getOffsetParent==null?void 0:u.getOffsetParent(h.floating)),U=await(u.isElement==null?void 0:u.isElement(O))?await(u.getScale==null?void 0:u.getScale(O))||{x:1,y:1}:{x:1,y:1},z=Bi(u.convertOffsetParentRelativeRectToViewportRelativeRect?await u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:h,rect:k,offsetParent:O,strategy:v}):k);return{top:(R.top-z.top+C.top)/U.y,bottom:(z.bottom-R.bottom+C.bottom)/U.y,left:(R.left-z.left+C.left)/U.x,right:(z.right-R.right+C.right)/U.x}}const WA=50,JA=async(t,r,o)=>{const{placement:s="bottom",strategy:c="absolute",middleware:u=[],platform:m}=o,h=m.detectOverflow?m:{...m,detectOverflow:FA},v=await(m.isRTL==null?void 0:m.isRTL(r));let p=await m.getElementRects({reference:t,floating:r,strategy:c}),{x:b,y}=ny(p,s,v),S=s,A=0;const C={};for(let T=0;T<u.length;T++){const E=u[T];if(!E)continue;const{name:R,fn:k}=E,{x:O,y:U,data:z,reset:G}=await k({x:b,y,initialPlacement:s,placement:S,strategy:c,middlewareData:C,rects:p,platform:h,elements:{reference:t,floating:r}});b=O??b,y=U??y,C[R]={...C[R],...z},G&&A<WA&&(A++,typeof G=="object"&&(G.placement&&(S=G.placement),G.rects&&(p=G.rects===!0?await m.getElementRects({reference:t,floating:r,strategy:c}):G.rects),{x:b,y}=ny(p,S,v)),T=-1)}return{x:b,y,placement:S,strategy:c,middlewareData:C}},ek=t=>({name:"arrow",options:t,async fn(r){const{x:o,y:s,placement:c,rects:u,platform:m,elements:h,middlewareData:v}=r,{element:p,padding:b=0}=oa(t,r)||{};if(p==null)return{};const y=g0(b),S={x:o,y:s},A=um(c),C=cm(A),T=await m.getDimensions(p),E=A==="y",R=E?"top":"left",k=E?"bottom":"right",O=E?"clientHeight":"clientWidth",U=u.reference[C]+u.reference[A]-S[A]-u.floating[C],z=S[A]-u.reference[A],G=await(m.getOffsetParent==null?void 0:m.getOffsetParent(p));let Y=G?G[O]:0;(!Y||!await(m.isElement==null?void 0:m.isElement(G)))&&(Y=h.floating[O]||u.floating[C]);const q=U/2-z/2,re=Y/2-T[C]/2-1,fe=qa(y[R],re),ue=qa(y[k],re),de=fe,W=Y-T[C]-ue,se=Y/2-T[C]/2+q,ee=mf(de,se,W),j=!v.arrow&&jo(c)!=null&&se!==ee&&u.reference[C]/2-(se<de?fe:ue)-T[C]/2<0,P=j?se<de?se-de:se-W:0;return{[A]:S[A]+P,data:{[A]:ee,centerOffset:se-ee-P,...j&&{alignmentOffset:P}},reset:j}}}),tk=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(r){var o,s;const{placement:c,middlewareData:u,rects:m,initialPlacement:h,platform:v,elements:p}=r,{mainAxis:b=!0,crossAxis:y=!0,fallbackPlacements:S,fallbackStrategy:A="bestFit",fallbackAxisSideDirection:C="none",flipAlignment:T=!0,...E}=oa(t,r);if((o=u.arrow)!=null&&o.alignmentOffset)return{};const R=la(c),k=Mn(h),O=la(h)===h,U=await(v.isRTL==null?void 0:v.isRTL(p.floating)),z=S||(O||!T?[Ui(h)]:YA(h)),G=C!=="none";!S&&G&&z.push(...KA(h,T,C,U));const Y=[h,...z],q=await v.detectOverflow(r,E),re=[];let fe=((s=u.flip)==null?void 0:s.overflows)||[];if(b&&re.push(q[R]),y){const se=IA(c,m,U);re.push(q[se[0]],q[se[1]])}if(fe=[...fe,{placement:c,overflows:re}],!re.every(se=>se<=0)){var ue,de;const se=(((ue=u.flip)==null?void 0:ue.index)||0)+1,ee=Y[se];if(ee&&(!(y==="alignment"?k!==Mn(ee):!1)||fe.every(H=>Mn(H.placement)===k?H.overflows[0]>0:!0)))return{data:{index:se,overflows:fe},reset:{placement:ee}};let j=(de=fe.filter(P=>P.overflows[0]<=0).sort((P,H)=>P.overflows[1]-H.overflows[1])[0])==null?void 0:de.placement;if(!j)switch(A){case"bestFit":{var W;const P=(W=fe.filter(H=>{if(G){const F=Mn(H.placement);return F===k||F==="y"}return!0}).map(H=>[H.placement,H.overflows.filter(F=>F>0).reduce((F,N)=>F+N,0)]).sort((H,F)=>H[1]-F[1])[0])==null?void 0:W[0];P&&(j=P);break}case"initialPlacement":j=h;break}if(c!==j)return{reset:{placement:j}}}return{}}}};function ay(t,r){return{top:t.top-r.height,right:t.right-r.width,bottom:t.bottom-r.height,left:t.left-r.width}}function ry(t){return qA.some(r=>t[r]>=0)}const nk=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(r){const{rects:o,platform:s}=r,{strategy:c="referenceHidden",...u}=oa(t,r);switch(c){case"referenceHidden":{const m=await s.detectOverflow(r,{...u,elementContext:"reference"}),h=ay(m,o.reference);return{data:{referenceHiddenOffsets:h,referenceHidden:ry(h)}}}case"escaped":{const m=await s.detectOverflow(r,{...u,altBoundary:!0}),h=ay(m,o.floating);return{data:{escapedOffsets:h,escaped:ry(h)}}}default:return{}}}}},v0=new Set(["left","top"]);async function ak(t,r){const{placement:o,platform:s,elements:c}=t,u=await(s.isRTL==null?void 0:s.isRTL(c.floating)),m=la(o),h=jo(o),v=Mn(o)==="y",p=v0.has(m)?-1:1,b=u&&v?-1:1,y=oa(r,t);let{mainAxis:S,crossAxis:A,alignmentAxis:C}=typeof y=="number"?{mainAxis:y,crossAxis:0,alignmentAxis:null}:{mainAxis:y.mainAxis||0,crossAxis:y.crossAxis||0,alignmentAxis:y.alignmentAxis};return h&&typeof C=="number"&&(A=h==="end"?C*-1:C),v?{x:A*b,y:S*p}:{x:S*p,y:A*b}}const rk=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(r){var o,s;const{x:c,y:u,placement:m,middlewareData:h}=r,v=await ak(r,t);return m===((o=h.offset)==null?void 0:o.placement)&&(s=h.arrow)!=null&&s.alignmentOffset?{}:{x:c+v.x,y:u+v.y,data:{...v,placement:m}}}}},ok=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(r){const{x:o,y:s,placement:c,platform:u}=r,{mainAxis:m=!0,crossAxis:h=!1,limiter:v={fn:R=>{let{x:k,y:O}=R;return{x:k,y:O}}},...p}=oa(t,r),b={x:o,y:s},y=await u.detectOverflow(r,p),S=Mn(la(c)),A=im(S);let C=b[A],T=b[S];if(m){const R=A==="y"?"top":"left",k=A==="y"?"bottom":"right",O=C+y[R],U=C-y[k];C=mf(O,C,U)}if(h){const R=S==="y"?"top":"left",k=S==="y"?"bottom":"right",O=T+y[R],U=T-y[k];T=mf(O,T,U)}const E=v.fn({...r,[A]:C,[S]:T});return{...E,data:{x:E.x-o,y:E.y-s,enabled:{[A]:m,[S]:h}}}}}},lk=function(t){return t===void 0&&(t={}),{options:t,fn(r){const{x:o,y:s,placement:c,rects:u,middlewareData:m}=r,{offset:h=0,mainAxis:v=!0,crossAxis:p=!0}=oa(t,r),b={x:o,y:s},y=Mn(c),S=im(y);let A=b[S],C=b[y];const T=oa(h,r),E=typeof T=="number"?{mainAxis:T,crossAxis:0}:{mainAxis:0,crossAxis:0,...T};if(v){const O=S==="y"?"height":"width",U=u.reference[S]-u.floating[O]+E.mainAxis,z=u.reference[S]+u.reference[O]-E.mainAxis;A<U?A=U:A>z&&(A=z)}if(p){var R,k;const O=S==="y"?"width":"height",U=v0.has(la(c)),z=u.reference[y]-u.floating[O]+(U&&((R=m.offset)==null?void 0:R[y])||0)+(U?0:E.crossAxis),G=u.reference[y]+u.reference[O]+(U?0:((k=m.offset)==null?void 0:k[y])||0)-(U?E.crossAxis:0);C<z?C=z:C>G&&(C=G)}return{[S]:A,[y]:C}}}},sk=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(r){var o,s;const{placement:c,rects:u,platform:m,elements:h}=r,{apply:v=()=>{},...p}=oa(t,r),b=await m.detectOverflow(r,p),y=la(c),S=jo(c),A=Mn(c)==="y",{width:C,height:T}=u.floating;let E,R;y==="top"||y==="bottom"?(E=y,R=S===(await(m.isRTL==null?void 0:m.isRTL(h.floating))?"start":"end")?"left":"right"):(R=y,E=S==="end"?"top":"bottom");const k=T-b.top-b.bottom,O=C-b.left-b.right,U=qa(T-b[E],k),z=qa(C-b[R],O),G=!r.middlewareData.shift;let Y=U,q=z;if((o=r.middlewareData.shift)!=null&&o.enabled.x&&(q=O),(s=r.middlewareData.shift)!=null&&s.enabled.y&&(Y=k),G&&!S){const fe=Zt(b.left,0),ue=Zt(b.right,0),de=Zt(b.top,0),W=Zt(b.bottom,0);A?q=C-2*(fe!==0||ue!==0?fe+ue:Zt(b.left,b.right)):Y=T-2*(de!==0||W!==0?de+W:Zt(b.top,b.bottom))}await v({...r,availableWidth:q,availableHeight:Y});const re=await m.getDimensions(h.floating);return C!==re.width||T!==re.height?{reset:{rects:!0}}:{}}}};function ic(){return typeof window<"u"}function Oo(t){return y0(t)?(t.nodeName||"").toLowerCase():"#document"}function Ft(t){var r;return(t==null||(r=t.ownerDocument)==null?void 0:r.defaultView)||window}function Ln(t){var r;return(r=(y0(t)?t.ownerDocument:t.document)||window.document)==null?void 0:r.documentElement}function y0(t){return ic()?t instanceof Node||t instanceof Ft(t).Node:!1}function wn(t){return ic()?t instanceof Element||t instanceof Ft(t).Element:!1}function sa(t){return ic()?t instanceof HTMLElement||t instanceof Ft(t).HTMLElement:!1}function oy(t){return!ic()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof Ft(t).ShadowRoot}function Fl(t){const{overflow:r,overflowX:o,overflowY:s,display:c}=Sn(t);return/auto|scroll|overlay|hidden|clip/.test(r+s+o)&&c!=="inline"&&c!=="contents"}function ik(t){return/^(table|td|th)$/.test(Oo(t))}function cc(t){try{if(t.matches(":popover-open"))return!0}catch{}try{return t.matches(":modal")}catch{return!1}}const ck=/transform|translate|scale|rotate|perspective|filter/,uk=/paint|layout|strict|content/,gr=t=>!!t&&t!=="none";let Yd;function dm(t){const r=wn(t)?Sn(t):t;return gr(r.transform)||gr(r.translate)||gr(r.scale)||gr(r.rotate)||gr(r.perspective)||!fm()&&(gr(r.backdropFilter)||gr(r.filter))||ck.test(r.willChange||"")||uk.test(r.contain||"")}function dk(t){let r=Va(t);for(;sa(r)&&!No(r);){if(dm(r))return r;if(cc(r))return null;r=Va(r)}return null}function fm(){return Yd==null&&(Yd=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Yd}function No(t){return/^(html|body|#document)$/.test(Oo(t))}function Sn(t){return Ft(t).getComputedStyle(t)}function uc(t){return wn(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Va(t){if(Oo(t)==="html")return t;const r=t.assignedSlot||t.parentNode||oy(t)&&t.host||Ln(t);return oy(r)?r.host:r}function b0(t){const r=Va(t);return No(r)?t.ownerDocument?t.ownerDocument.body:t.body:sa(r)&&Fl(r)?r:b0(r)}function Xl(t,r,o){var s;r===void 0&&(r=[]),o===void 0&&(o=!0);const c=b0(t),u=c===((s=t.ownerDocument)==null?void 0:s.body),m=Ft(c);if(u){const h=pf(m);return r.concat(m,m.visualViewport||[],Fl(c)?c:[],h&&o?Xl(h):[])}else return r.concat(c,Xl(c,[],o))}function pf(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function x0(t){const r=Sn(t);let o=parseFloat(r.width)||0,s=parseFloat(r.height)||0;const c=sa(t),u=c?t.offsetWidth:o,m=c?t.offsetHeight:s,h=Li(o)!==u||Li(s)!==m;return h&&(o=u,s=m),{width:o,height:s,$:h}}function mm(t){return wn(t)?t:t.contextElement}function So(t){const r=mm(t);if(!sa(r))return zn(1);const o=r.getBoundingClientRect(),{width:s,height:c,$:u}=x0(r);let m=(u?Li(o.width):o.width)/s,h=(u?Li(o.height):o.height)/c;return(!m||!Number.isFinite(m))&&(m=1),(!h||!Number.isFinite(h))&&(h=1),{x:m,y:h}}const fk=zn(0);function w0(t){const r=Ft(t);return!fm()||!r.visualViewport?fk:{x:r.visualViewport.offsetLeft,y:r.visualViewport.offsetTop}}function mk(t,r,o){return r===void 0&&(r=!1),!o||r&&o!==Ft(t)?!1:r}function xr(t,r,o,s){r===void 0&&(r=!1),o===void 0&&(o=!1);const c=t.getBoundingClientRect(),u=mm(t);let m=zn(1);r&&(s?wn(s)&&(m=So(s)):m=So(t));const h=mk(u,o,s)?w0(u):zn(0);let v=(c.left+h.x)/m.x,p=(c.top+h.y)/m.y,b=c.width/m.x,y=c.height/m.y;if(u){const S=Ft(u),A=s&&wn(s)?Ft(s):s;let C=S,T=pf(C);for(;T&&s&&A!==C;){const E=So(T),R=T.getBoundingClientRect(),k=Sn(T),O=R.left+(T.clientLeft+parseFloat(k.paddingLeft))*E.x,U=R.top+(T.clientTop+parseFloat(k.paddingTop))*E.y;v*=E.x,p*=E.y,b*=E.x,y*=E.y,v+=O,p+=U,C=Ft(T),T=pf(C)}}return Bi({width:b,height:y,x:v,y:p})}function dc(t,r){const o=uc(t).scrollLeft;return r?r.left+o:xr(Ln(t)).left+o}function S0(t,r){const o=t.getBoundingClientRect(),s=o.left+r.scrollLeft-dc(t,o),c=o.top+r.scrollTop;return{x:s,y:c}}function hk(t){let{elements:r,rect:o,offsetParent:s,strategy:c}=t;const u=c==="fixed",m=Ln(s),h=r?cc(r.floating):!1;if(s===m||h&&u)return o;let v={scrollLeft:0,scrollTop:0},p=zn(1);const b=zn(0),y=sa(s);if((y||!y&&!u)&&((Oo(s)!=="body"||Fl(m))&&(v=uc(s)),y)){const A=xr(s);p=So(s),b.x=A.x+s.clientLeft,b.y=A.y+s.clientTop}const S=m&&!y&&!u?S0(m,v):zn(0);return{width:o.width*p.x,height:o.height*p.y,x:o.x*p.x-v.scrollLeft*p.x+b.x+S.x,y:o.y*p.y-v.scrollTop*p.y+b.y+S.y}}function pk(t){return Array.from(t.getClientRects())}function gk(t){const r=Ln(t),o=uc(t),s=t.ownerDocument.body,c=Zt(r.scrollWidth,r.clientWidth,s.scrollWidth,s.clientWidth),u=Zt(r.scrollHeight,r.clientHeight,s.scrollHeight,s.clientHeight);let m=-o.scrollLeft+dc(t);const h=-o.scrollTop;return Sn(s).direction==="rtl"&&(m+=Zt(r.clientWidth,s.clientWidth)-c),{width:c,height:u,x:m,y:h}}const ly=25;function vk(t,r){const o=Ft(t),s=Ln(t),c=o.visualViewport;let u=s.clientWidth,m=s.clientHeight,h=0,v=0;if(c){u=c.width,m=c.height;const b=fm();(!b||b&&r==="fixed")&&(h=c.offsetLeft,v=c.offsetTop)}const p=dc(s);if(p<=0){const b=s.ownerDocument,y=b.body,S=getComputedStyle(y),A=b.compatMode==="CSS1Compat"&&parseFloat(S.marginLeft)+parseFloat(S.marginRight)||0,C=Math.abs(s.clientWidth-y.clientWidth-A);C<=ly&&(u-=C)}else p<=ly&&(u+=p);return{width:u,height:m,x:h,y:v}}function yk(t,r){const o=xr(t,!0,r==="fixed"),s=o.top+t.clientTop,c=o.left+t.clientLeft,u=sa(t)?So(t):zn(1),m=t.clientWidth*u.x,h=t.clientHeight*u.y,v=c*u.x,p=s*u.y;return{width:m,height:h,x:v,y:p}}function sy(t,r,o){let s;if(r==="viewport")s=vk(t,o);else if(r==="document")s=gk(Ln(t));else if(wn(r))s=yk(r,o);else{const c=w0(t);s={x:r.x-c.x,y:r.y-c.y,width:r.width,height:r.height}}return Bi(s)}function E0(t,r){const o=Va(t);return o===r||!wn(o)||No(o)?!1:Sn(o).position==="fixed"||E0(o,r)}function bk(t,r){const o=r.get(t);if(o)return o;let s=Xl(t,[],!1).filter(h=>wn(h)&&Oo(h)!=="body"),c=null;const u=Sn(t).position==="fixed";let m=u?Va(t):t;for(;wn(m)&&!No(m);){const h=Sn(m),v=dm(m);!v&&h.position==="fixed"&&(c=null),(u?!v&&!c:!v&&h.position==="static"&&!!c&&(c.position==="absolute"||c.position==="fixed")||Fl(m)&&!v&&E0(t,m))?s=s.filter(b=>b!==m):c=h,m=Va(m)}return r.set(t,s),s}function xk(t){let{element:r,boundary:o,rootBoundary:s,strategy:c}=t;const m=[...o==="clippingAncestors"?cc(r)?[]:bk(r,this._c):[].concat(o),s],h=sy(r,m[0],c);let v=h.top,p=h.right,b=h.bottom,y=h.left;for(let S=1;S<m.length;S++){const A=sy(r,m[S],c);v=Zt(A.top,v),p=qa(A.right,p),b=qa(A.bottom,b),y=Zt(A.left,y)}return{width:p-y,height:b-v,x:y,y:v}}function wk(t){const{width:r,height:o}=x0(t);return{width:r,height:o}}function Sk(t,r,o){const s=sa(r),c=Ln(r),u=o==="fixed",m=xr(t,!0,u,r);let h={scrollLeft:0,scrollTop:0};const v=zn(0);function p(){v.x=dc(c)}if(s||!s&&!u)if((Oo(r)!=="body"||Fl(c))&&(h=uc(r)),s){const A=xr(r,!0,u,r);v.x=A.x+r.clientLeft,v.y=A.y+r.clientTop}else c&&p();u&&!s&&c&&p();const b=c&&!s&&!u?S0(c,h):zn(0),y=m.left+h.scrollLeft-v.x-b.x,S=m.top+h.scrollTop-v.y-b.y;return{x:y,y:S,width:m.width,height:m.height}}function Gd(t){return Sn(t).position==="static"}function iy(t,r){if(!sa(t)||Sn(t).position==="fixed")return null;if(r)return r(t);let o=t.offsetParent;return Ln(t)===o&&(o=o.ownerDocument.body),o}function T0(t,r){const o=Ft(t);if(cc(t))return o;if(!sa(t)){let c=Va(t);for(;c&&!No(c);){if(wn(c)&&!Gd(c))return c;c=Va(c)}return o}let s=iy(t,r);for(;s&&ik(s)&&Gd(s);)s=iy(s,r);return s&&No(s)&&Gd(s)&&!dm(s)?o:s||dk(t)||o}const Ek=async function(t){const r=this.getOffsetParent||T0,o=this.getDimensions,s=await o(t.floating);return{reference:Sk(t.reference,await r(t.floating),t.strategy),floating:{x:0,y:0,width:s.width,height:s.height}}};function Tk(t){return Sn(t).direction==="rtl"}const Nk={convertOffsetParentRelativeRectToViewportRelativeRect:hk,getDocumentElement:Ln,getClippingRect:xk,getOffsetParent:T0,getElementRects:Ek,getClientRects:pk,getDimensions:wk,getScale:So,isElement:wn,isRTL:Tk};function N0(t,r){return t.x===r.x&&t.y===r.y&&t.width===r.width&&t.height===r.height}function Ck(t,r){let o=null,s;const c=Ln(t);function u(){var h;clearTimeout(s),(h=o)==null||h.disconnect(),o=null}function m(h,v){h===void 0&&(h=!1),v===void 0&&(v=1),u();const p=t.getBoundingClientRect(),{left:b,top:y,width:S,height:A}=p;if(h||r(),!S||!A)return;const C=xi(y),T=xi(c.clientWidth-(b+S)),E=xi(c.clientHeight-(y+A)),R=xi(b),O={rootMargin:-C+"px "+-T+"px "+-E+"px "+-R+"px",threshold:Zt(0,qa(1,v))||1};let U=!0;function z(G){const Y=G[0].intersectionRatio;if(Y!==v){if(!U)return m();Y?m(!1,Y):s=setTimeout(()=>{m(!1,1e-7)},1e3)}Y===1&&!N0(p,t.getBoundingClientRect())&&m(),U=!1}try{o=new IntersectionObserver(z,{...O,root:c.ownerDocument})}catch{o=new IntersectionObserver(z,O)}o.observe(t)}return m(!0),u}function Rk(t,r,o,s){s===void 0&&(s={});const{ancestorScroll:c=!0,ancestorResize:u=!0,elementResize:m=typeof ResizeObserver=="function",layoutShift:h=typeof IntersectionObserver=="function",animationFrame:v=!1}=s,p=mm(t),b=c||u?[...p?Xl(p):[],...r?Xl(r):[]]:[];b.forEach(R=>{c&&R.addEventListener("scroll",o,{passive:!0}),u&&R.addEventListener("resize",o)});const y=p&&h?Ck(p,o):null;let S=-1,A=null;m&&(A=new ResizeObserver(R=>{let[k]=R;k&&k.target===p&&A&&r&&(A.unobserve(r),cancelAnimationFrame(S),S=requestAnimationFrame(()=>{var O;(O=A)==null||O.observe(r)})),o()}),p&&!v&&A.observe(p),r&&A.observe(r));let C,T=v?xr(t):null;v&&E();function E(){const R=xr(t);T&&!N0(T,R)&&o(),T=R,C=requestAnimationFrame(E)}return o(),()=>{var R;b.forEach(k=>{c&&k.removeEventListener("scroll",o),u&&k.removeEventListener("resize",o)}),y?.(),(R=A)==null||R.disconnect(),A=null,v&&cancelAnimationFrame(C)}}const Ak=rk,kk=ok,_k=tk,jk=sk,Ok=nk,cy=ek,Dk=lk,Mk=(t,r,o)=>{const s=new Map,c={platform:Nk,...o},u={...c.platform,_c:s};return JA(t,r,{...c,platform:u})};var zk=typeof document<"u",Lk=function(){},Ci=zk?g.useLayoutEffect:Lk;function Hi(t,r){if(t===r)return!0;if(typeof t!=typeof r)return!1;if(typeof t=="function"&&t.toString()===r.toString())return!0;let o,s,c;if(t&&r&&typeof t=="object"){if(Array.isArray(t)){if(o=t.length,o!==r.length)return!1;for(s=o;s--!==0;)if(!Hi(t[s],r[s]))return!1;return!0}if(c=Object.keys(t),o=c.length,o!==Object.keys(r).length)return!1;for(s=o;s--!==0;)if(!{}.hasOwnProperty.call(r,c[s]))return!1;for(s=o;s--!==0;){const u=c[s];if(!(u==="_owner"&&t.$$typeof)&&!Hi(t[u],r[u]))return!1}return!0}return t!==t&&r!==r}function C0(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function uy(t,r){const o=C0(t);return Math.round(r*o)/o}function Xd(t){const r=g.useRef(t);return Ci(()=>{r.current=t}),r}function Uk(t){t===void 0&&(t={});const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:c,elements:{reference:u,floating:m}={},transform:h=!0,whileElementsMounted:v,open:p}=t,[b,y]=g.useState({x:0,y:0,strategy:o,placement:r,middlewareData:{},isPositioned:!1}),[S,A]=g.useState(s);Hi(S,s)||A(s);const[C,T]=g.useState(null),[E,R]=g.useState(null),k=g.useCallback(H=>{H!==G.current&&(G.current=H,T(H))},[]),O=g.useCallback(H=>{H!==Y.current&&(Y.current=H,R(H))},[]),U=u||C,z=m||E,G=g.useRef(null),Y=g.useRef(null),q=g.useRef(b),re=v!=null,fe=Xd(v),ue=Xd(c),de=Xd(p),W=g.useCallback(()=>{if(!G.current||!Y.current)return;const H={placement:r,strategy:o,middleware:S};ue.current&&(H.platform=ue.current),Mk(G.current,Y.current,H).then(F=>{const N={...F,isPositioned:de.current!==!1};se.current&&!Hi(q.current,N)&&(q.current=N,Zl.flushSync(()=>{y(N)}))})},[S,r,o,ue,de]);Ci(()=>{p===!1&&q.current.isPositioned&&(q.current.isPositioned=!1,y(H=>({...H,isPositioned:!1})))},[p]);const se=g.useRef(!1);Ci(()=>(se.current=!0,()=>{se.current=!1}),[]),Ci(()=>{if(U&&(G.current=U),z&&(Y.current=z),U&&z){if(fe.current)return fe.current(U,z,W);W()}},[U,z,W,fe,re]);const ee=g.useMemo(()=>({reference:G,floating:Y,setReference:k,setFloating:O}),[k,O]),j=g.useMemo(()=>({reference:U,floating:z}),[U,z]),P=g.useMemo(()=>{const H={position:o,left:0,top:0};if(!j.floating)return H;const F=uy(j.floating,b.x),N=uy(j.floating,b.y);return h?{...H,transform:"translate("+F+"px, "+N+"px)",...C0(j.floating)>=1.5&&{willChange:"transform"}}:{position:o,left:F,top:N}},[o,h,j.floating,b.x,b.y]);return g.useMemo(()=>({...b,update:W,refs:ee,elements:j,floatingStyles:P}),[b,W,ee,j,P])}const Bk=t=>{function r(o){return{}.hasOwnProperty.call(o,"current")}return{name:"arrow",options:t,fn(o){const{element:s,padding:c}=typeof t=="function"?t(o):t;return s&&r(s)?s.current!=null?cy({element:s.current,padding:c}).fn(o):{}:s?cy({element:s,padding:c}).fn(o):{}}}},Hk=(t,r)=>{const o=Ak(t);return{name:o.name,fn:o.fn,options:[t,r]}},Pk=(t,r)=>{const o=kk(t);return{name:o.name,fn:o.fn,options:[t,r]}},$k=(t,r)=>({fn:Dk(t).fn,options:[t,r]}),qk=(t,r)=>{const o=_k(t);return{name:o.name,fn:o.fn,options:[t,r]}},Vk=(t,r)=>{const o=jk(t);return{name:o.name,fn:o.fn,options:[t,r]}},Ik=(t,r)=>{const o=Ok(t);return{name:o.name,fn:o.fn,options:[t,r]}},Yk=(t,r)=>{const o=Bk(t);return{name:o.name,fn:o.fn,options:[t,r]}};var Gk="Arrow",R0=g.forwardRef((t,r)=>{const{children:o,width:s=10,height:c=5,...u}=t;return f.jsx(Le.svg,{...u,ref:r,width:s,height:c,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?o:f.jsx("polygon",{points:"0,0 30,0 15,10"})})});R0.displayName=Gk;var Xk=R0;function A0(t){const[r,o]=g.useState(void 0);return Ot(()=>{if(t){o({width:t.offsetWidth,height:t.offsetHeight});const s=new ResizeObserver(c=>{if(!Array.isArray(c)||!c.length)return;const u=c[0];let m,h;if("borderBoxSize"in u){const v=u.borderBoxSize,p=Array.isArray(v)?v[0]:v;m=p.inlineSize,h=p.blockSize}else m=t.offsetWidth,h=t.offsetHeight;o({width:m,height:h})});return s.observe(t,{box:"border-box"}),()=>s.unobserve(t)}else o(void 0)},[t]),r}var hm="Popper",[k0,_0]=Ya(hm),[Qk,j0]=k0(hm),O0=t=>{const{__scopePopper:r,children:o}=t,[s,c]=g.useState(null);return f.jsx(Qk,{scope:r,anchor:s,onAnchorChange:c,children:o})};O0.displayName=hm;var D0="PopperAnchor",M0=g.forwardRef((t,r)=>{const{__scopePopper:o,virtualRef:s,...c}=t,u=j0(D0,o),m=g.useRef(null),h=Fe(r,m),v=g.useRef(null);return g.useEffect(()=>{const p=v.current;v.current=s?.current||m.current,p!==v.current&&u.onAnchorChange(v.current)}),s?null:f.jsx(Le.div,{...c,ref:h})});M0.displayName=D0;var pm="PopperContent",[Kk,Zk]=k0(pm),z0=g.forwardRef((t,r)=>{const{__scopePopper:o,side:s="bottom",sideOffset:c=0,align:u="center",alignOffset:m=0,arrowPadding:h=0,avoidCollisions:v=!0,collisionBoundary:p=[],collisionPadding:b=0,sticky:y="partial",hideWhenDetached:S=!1,updatePositionStrategy:A="optimized",onPlaced:C,...T}=t,E=j0(pm,o),[R,k]=g.useState(null),O=Fe(r,ie=>k(ie)),[U,z]=g.useState(null),G=A0(U),Y=G?.width??0,q=G?.height??0,re=s+(u!=="center"?"-"+u:""),fe=typeof b=="number"?b:{top:0,right:0,bottom:0,left:0,...b},ue=Array.isArray(p)?p:[p],de=ue.length>0,W={padding:fe,boundary:ue.filter(Wk),altBoundary:de},{refs:se,floatingStyles:ee,placement:j,isPositioned:P,middlewareData:H}=Uk({strategy:"fixed",placement:re,whileElementsMounted:(...ie)=>Rk(...ie,{animationFrame:A==="always"}),elements:{reference:E.anchor},middleware:[Hk({mainAxis:c+q,alignmentAxis:m}),v&&Pk({mainAxis:!0,crossAxis:!1,limiter:y==="partial"?$k():void 0,...W}),v&&qk({...W}),Vk({...W,apply:({elements:ie,rects:ce,availableWidth:xe,availableHeight:Re})=>{const{width:Te,height:Ae}=ce.reference,Je=ie.floating.style;Je.setProperty("--radix-popper-available-width",`${xe}px`),Je.setProperty("--radix-popper-available-height",`${Re}px`),Je.setProperty("--radix-popper-anchor-width",`${Te}px`),Je.setProperty("--radix-popper-anchor-height",`${Ae}px`)}}),U&&Yk({element:U,padding:h}),Jk({arrowWidth:Y,arrowHeight:q}),S&&Ik({strategy:"referenceHidden",...W})]}),[F,N]=B0(j),I=$a(C);Ot(()=>{P&&I?.()},[P,I]);const J=H.arrow?.x,Q=H.arrow?.y,le=H.arrow?.centerOffset!==0,[te,ae]=g.useState();return Ot(()=>{R&&ae(window.getComputedStyle(R).zIndex)},[R]),f.jsx("div",{ref:se.setFloating,"data-radix-popper-content-wrapper":"",style:{...ee,transform:P?ee.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:te,"--radix-popper-transform-origin":[H.transformOrigin?.x,H.transformOrigin?.y].join(" "),...H.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:t.dir,children:f.jsx(Kk,{scope:o,placedSide:F,onArrowChange:z,arrowX:J,arrowY:Q,shouldHideArrow:le,children:f.jsx(Le.div,{"data-side":F,"data-align":N,...T,ref:O,style:{...T.style,animation:P?void 0:"none"}})})})});z0.displayName=pm;var L0="PopperArrow",Fk={top:"bottom",right:"left",bottom:"top",left:"right"},U0=g.forwardRef(function(r,o){const{__scopePopper:s,...c}=r,u=Zk(L0,s),m=Fk[u.placedSide];return f.jsx("span",{ref:u.onArrowChange,style:{position:"absolute",left:u.arrowX,top:u.arrowY,[m]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[u.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[u.placedSide],visibility:u.shouldHideArrow?"hidden":void 0},children:f.jsx(Xk,{...c,ref:o,style:{...c.style,display:"block"}})})});U0.displayName=L0;function Wk(t){return t!==null}var Jk=t=>({name:"transformOrigin",options:t,fn(r){const{placement:o,rects:s,middlewareData:c}=r,m=c.arrow?.centerOffset!==0,h=m?0:t.arrowWidth,v=m?0:t.arrowHeight,[p,b]=B0(o),y={start:"0%",center:"50%",end:"100%"}[b],S=(c.arrow?.x??0)+h/2,A=(c.arrow?.y??0)+v/2;let C="",T="";return p==="bottom"?(C=m?y:`${S}px`,T=`${-v}px`):p==="top"?(C=m?y:`${S}px`,T=`${s.floating.height+v}px`):p==="right"?(C=`${-v}px`,T=m?y:`${A}px`):p==="left"&&(C=`${s.floating.width+v}px`,T=m?y:`${A}px`),{data:{x:C,y:T}}}});function B0(t){const[r,o="center"]=t.split("-");return[r,o]}var e5=O0,t5=M0,n5=z0,a5=U0;function H0(t){const r=g.useRef({value:t,previous:t});return g.useMemo(()=>(r.current.value!==t&&(r.current.previous=r.current.value,r.current.value=t),r.current.previous),[t])}var P0=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),r5="VisuallyHidden",o5=g.forwardRef((t,r)=>f.jsx(Le.span,{...t,ref:r,style:{...P0,...t.style}}));o5.displayName=r5;var l5=[" ","Enter","ArrowUp","ArrowDown"],s5=[" ","Enter"],wr="Select",[fc,mc,i5]=p0(wr),[Do]=Ya(wr,[i5,_0]),hc=_0(),[c5,Ga]=Do(wr),[u5,d5]=Do(wr),$0=t=>{const{__scopeSelect:r,children:o,open:s,defaultOpen:c,onOpenChange:u,value:m,defaultValue:h,onValueChange:v,dir:p,name:b,autoComplete:y,disabled:S,required:A,form:C}=t,T=hc(r),[E,R]=g.useState(null),[k,O]=g.useState(null),[U,z]=g.useState(!1),G=sm(p),[Y,q]=To({prop:s,defaultProp:c??!1,onChange:u,caller:wr}),[re,fe]=To({prop:m,defaultProp:h,onChange:v,caller:wr}),ue=g.useRef(null),de=E?C||!!E.closest("form"):!0,[W,se]=g.useState(new Set),ee=Array.from(W).map(j=>j.props.value).join(";");return f.jsx(e5,{...T,children:f.jsxs(c5,{required:A,scope:r,trigger:E,onTriggerChange:R,valueNode:k,onValueNodeChange:O,valueNodeHasChildren:U,onValueNodeHasChildrenChange:z,contentId:Ha(),value:re,onValueChange:fe,open:Y,onOpenChange:q,dir:G,triggerPointerDownPosRef:ue,disabled:S,children:[f.jsx(fc.Provider,{scope:r,children:f.jsx(u5,{scope:t.__scopeSelect,onNativeOptionAdd:g.useCallback(j=>{se(P=>new Set(P).add(j))},[]),onNativeOptionRemove:g.useCallback(j=>{se(P=>{const H=new Set(P);return H.delete(j),H})},[]),children:o})}),de?f.jsxs(fx,{"aria-hidden":!0,required:A,tabIndex:-1,name:b,autoComplete:y,value:re,onChange:j=>fe(j.target.value),disabled:S,form:C,children:[re===void 0?f.jsx("option",{value:""}):null,Array.from(W)]},ee):null]})})};$0.displayName=wr;var q0="SelectTrigger",V0=g.forwardRef((t,r)=>{const{__scopeSelect:o,disabled:s=!1,...c}=t,u=hc(o),m=Ga(q0,o),h=m.disabled||s,v=Fe(r,m.onTriggerChange),p=mc(o),b=g.useRef("touch"),[y,S,A]=hx(T=>{const E=p().filter(O=>!O.disabled),R=E.find(O=>O.value===m.value),k=px(E,T,R);k!==void 0&&m.onValueChange(k.value)}),C=T=>{h||(m.onOpenChange(!0),A()),T&&(m.triggerPointerDownPosRef.current={x:Math.round(T.pageX),y:Math.round(T.pageY)})};return f.jsx(t5,{asChild:!0,...u,children:f.jsx(Le.button,{type:"button",role:"combobox","aria-controls":m.contentId,"aria-expanded":m.open,"aria-required":m.required,"aria-autocomplete":"none",dir:m.dir,"data-state":m.open?"open":"closed",disabled:h,"data-disabled":h?"":void 0,"data-placeholder":mx(m.value)?"":void 0,...c,ref:v,onClick:ze(c.onClick,T=>{T.currentTarget.focus(),b.current!=="mouse"&&C(T)}),onPointerDown:ze(c.onPointerDown,T=>{b.current=T.pointerType;const E=T.target;E.hasPointerCapture(T.pointerId)&&E.releasePointerCapture(T.pointerId),T.button===0&&T.ctrlKey===!1&&T.pointerType==="mouse"&&(C(T),T.preventDefault())}),onKeyDown:ze(c.onKeyDown,T=>{const E=y.current!=="";!(T.ctrlKey||T.altKey||T.metaKey)&&T.key.length===1&&S(T.key),!(E&&T.key===" ")&&l5.includes(T.key)&&(C(),T.preventDefault())})})})});V0.displayName=q0;var I0="SelectValue",Y0=g.forwardRef((t,r)=>{const{__scopeSelect:o,className:s,style:c,children:u,placeholder:m="",...h}=t,v=Ga(I0,o),{onValueNodeHasChildrenChange:p}=v,b=u!==void 0,y=Fe(r,v.onValueNodeChange);return Ot(()=>{p(b)},[p,b]),f.jsx(Le.span,{...h,ref:y,style:{pointerEvents:"none"},children:mx(v.value)?f.jsx(f.Fragment,{children:m}):u})});Y0.displayName=I0;var f5="SelectIcon",G0=g.forwardRef((t,r)=>{const{__scopeSelect:o,children:s,...c}=t;return f.jsx(Le.span,{"aria-hidden":!0,...c,ref:r,children:s||"▼"})});G0.displayName=f5;var m5="SelectPortal",X0=t=>f.jsx(Wf,{asChild:!0,...t});X0.displayName=m5;var Sr="SelectContent",Q0=g.forwardRef((t,r)=>{const o=Ga(Sr,t.__scopeSelect),[s,c]=g.useState();if(Ot(()=>{c(new DocumentFragment)},[]),!o.open){const u=s;return u?Zl.createPortal(f.jsx(K0,{scope:t.__scopeSelect,children:f.jsx(fc.Slot,{scope:t.__scopeSelect,children:f.jsx("div",{children:t.children})})}),u):null}return f.jsx(Z0,{...t,ref:r})});Q0.displayName=Sr;var vn=10,[K0,Xa]=Do(Sr),h5="SelectContentImpl",p5=Gl("SelectContent.RemoveScroll"),Z0=g.forwardRef((t,r)=>{const{__scopeSelect:o,position:s="item-aligned",onCloseAutoFocus:c,onEscapeKeyDown:u,onPointerDownOutside:m,side:h,sideOffset:v,align:p,alignOffset:b,arrowPadding:y,collisionBoundary:S,collisionPadding:A,sticky:C,hideWhenDetached:T,avoidCollisions:E,...R}=t,k=Ga(Sr,o),[O,U]=g.useState(null),[z,G]=g.useState(null),Y=Fe(r,ie=>U(ie)),[q,re]=g.useState(null),[fe,ue]=g.useState(null),de=mc(o),[W,se]=g.useState(!1),ee=g.useRef(!1);g.useEffect(()=>{if(O)return Vb(O)},[O]),Mb();const j=g.useCallback(ie=>{const[ce,...xe]=de().map(Ae=>Ae.ref.current),[Re]=xe.slice(-1),Te=document.activeElement;for(const Ae of ie)if(Ae===Te||(Ae?.scrollIntoView({block:"nearest"}),Ae===ce&&z&&(z.scrollTop=0),Ae===Re&&z&&(z.scrollTop=z.scrollHeight),Ae?.focus(),document.activeElement!==Te))return},[de,z]),P=g.useCallback(()=>j([q,O]),[j,q,O]);g.useEffect(()=>{W&&P()},[W,P]);const{onOpenChange:H,triggerPointerDownPosRef:F}=k;g.useEffect(()=>{if(O){let ie={x:0,y:0};const ce=Re=>{ie={x:Math.abs(Math.round(Re.pageX)-(F.current?.x??0)),y:Math.abs(Math.round(Re.pageY)-(F.current?.y??0))}},xe=Re=>{ie.x<=10&&ie.y<=10?Re.preventDefault():O.contains(Re.target)||H(!1),document.removeEventListener("pointermove",ce),F.current=null};return F.current!==null&&(document.addEventListener("pointermove",ce),document.addEventListener("pointerup",xe,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",ce),document.removeEventListener("pointerup",xe,{capture:!0})}}},[O,H,F]),g.useEffect(()=>{const ie=()=>H(!1);return window.addEventListener("blur",ie),window.addEventListener("resize",ie),()=>{window.removeEventListener("blur",ie),window.removeEventListener("resize",ie)}},[H]);const[N,I]=hx(ie=>{const ce=de().filter(Te=>!Te.disabled),xe=ce.find(Te=>Te.ref.current===document.activeElement),Re=px(ce,ie,xe);Re&&setTimeout(()=>Re.ref.current.focus())}),J=g.useCallback((ie,ce,xe)=>{const Re=!ee.current&&!xe;(k.value!==void 0&&k.value===ce||Re)&&(re(ie),Re&&(ee.current=!0))},[k.value]),Q=g.useCallback(()=>O?.focus(),[O]),le=g.useCallback((ie,ce,xe)=>{const Re=!ee.current&&!xe;(k.value!==void 0&&k.value===ce||Re)&&ue(ie)},[k.value]),te=s==="popper"?gf:F0,ae=te===gf?{side:h,sideOffset:v,align:p,alignOffset:b,arrowPadding:y,collisionBoundary:S,collisionPadding:A,sticky:C,hideWhenDetached:T,avoidCollisions:E}:{};return f.jsx(K0,{scope:o,content:O,viewport:z,onViewportChange:G,itemRefCallback:J,selectedItem:q,onItemLeave:Q,itemTextRefCallback:le,focusSelectedItem:P,selectedItemText:fe,position:s,isPositioned:W,searchRef:N,children:f.jsx(Jf,{as:p5,allowPinchZoom:!0,children:f.jsx(Ff,{asChild:!0,trapped:k.open,onMountAutoFocus:ie=>{ie.preventDefault()},onUnmountAutoFocus:ze(c,ie=>{k.trigger?.focus({preventScroll:!0}),ie.preventDefault()}),children:f.jsx(Zf,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:u,onPointerDownOutside:m,onFocusOutside:ie=>ie.preventDefault(),onDismiss:()=>k.onOpenChange(!1),children:f.jsx(te,{role:"listbox",id:k.contentId,"data-state":k.open?"open":"closed",dir:k.dir,onContextMenu:ie=>ie.preventDefault(),...R,...ae,onPlaced:()=>se(!0),ref:Y,style:{display:"flex",flexDirection:"column",outline:"none",...R.style},onKeyDown:ze(R.onKeyDown,ie=>{const ce=ie.ctrlKey||ie.altKey||ie.metaKey;if(ie.key==="Tab"&&ie.preventDefault(),!ce&&ie.key.length===1&&I(ie.key),["ArrowUp","ArrowDown","Home","End"].includes(ie.key)){let Re=de().filter(Te=>!Te.disabled).map(Te=>Te.ref.current);if(["ArrowUp","End"].includes(ie.key)&&(Re=Re.slice().reverse()),["ArrowUp","ArrowDown"].includes(ie.key)){const Te=ie.target,Ae=Re.indexOf(Te);Re=Re.slice(Ae+1)}setTimeout(()=>j(Re)),ie.preventDefault()}})})})})})})});Z0.displayName=h5;var g5="SelectItemAlignedPosition",F0=g.forwardRef((t,r)=>{const{__scopeSelect:o,onPlaced:s,...c}=t,u=Ga(Sr,o),m=Xa(Sr,o),[h,v]=g.useState(null),[p,b]=g.useState(null),y=Fe(r,Y=>b(Y)),S=mc(o),A=g.useRef(!1),C=g.useRef(!0),{viewport:T,selectedItem:E,selectedItemText:R,focusSelectedItem:k}=m,O=g.useCallback(()=>{if(u.trigger&&u.valueNode&&h&&p&&T&&E&&R){const Y=u.trigger.getBoundingClientRect(),q=p.getBoundingClientRect(),re=u.valueNode.getBoundingClientRect(),fe=R.getBoundingClientRect();if(u.dir!=="rtl"){const Te=fe.left-q.left,Ae=re.left-Te,Je=Y.left-Ae,at=Y.width+Je,dn=Math.max(at,q.width),fn=window.innerWidth-vn,lt=Jv(Ae,[vn,Math.max(vn,fn-dn)]);h.style.minWidth=at+"px",h.style.left=lt+"px"}else{const Te=q.right-fe.right,Ae=window.innerWidth-re.right-Te,Je=window.innerWidth-Y.right-Ae,at=Y.width+Je,dn=Math.max(at,q.width),fn=window.innerWidth-vn,lt=Jv(Ae,[vn,Math.max(vn,fn-dn)]);h.style.minWidth=at+"px",h.style.right=lt+"px"}const ue=S(),de=window.innerHeight-vn*2,W=T.scrollHeight,se=window.getComputedStyle(p),ee=parseInt(se.borderTopWidth,10),j=parseInt(se.paddingTop,10),P=parseInt(se.borderBottomWidth,10),H=parseInt(se.paddingBottom,10),F=ee+j+W+H+P,N=Math.min(E.offsetHeight*5,F),I=window.getComputedStyle(T),J=parseInt(I.paddingTop,10),Q=parseInt(I.paddingBottom,10),le=Y.top+Y.height/2-vn,te=de-le,ae=E.offsetHeight/2,ie=E.offsetTop+ae,ce=ee+j+ie,xe=F-ce;if(ce<=le){const Te=ue.length>0&&E===ue[ue.length-1].ref.current;h.style.bottom="0px";const Ae=p.clientHeight-T.offsetTop-T.offsetHeight,Je=Math.max(te,ae+(Te?Q:0)+Ae+P),at=ce+Je;h.style.height=at+"px"}else{const Te=ue.length>0&&E===ue[0].ref.current;h.style.top="0px";const Je=Math.max(le,ee+T.offsetTop+(Te?J:0)+ae)+xe;h.style.height=Je+"px",T.scrollTop=ce-le+T.offsetTop}h.style.margin=`${vn}px 0`,h.style.minHeight=N+"px",h.style.maxHeight=de+"px",s?.(),requestAnimationFrame(()=>A.current=!0)}},[S,u.trigger,u.valueNode,h,p,T,E,R,u.dir,s]);Ot(()=>O(),[O]);const[U,z]=g.useState();Ot(()=>{p&&z(window.getComputedStyle(p).zIndex)},[p]);const G=g.useCallback(Y=>{Y&&C.current===!0&&(O(),k?.(),C.current=!1)},[O,k]);return f.jsx(y5,{scope:o,contentWrapper:h,shouldExpandOnScrollRef:A,onScrollButtonChange:G,children:f.jsx("div",{ref:v,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:U},children:f.jsx(Le.div,{...c,ref:y,style:{boxSizing:"border-box",maxHeight:"100%",...c.style}})})})});F0.displayName=g5;var v5="SelectPopperPosition",gf=g.forwardRef((t,r)=>{const{__scopeSelect:o,align:s="start",collisionPadding:c=vn,...u}=t,m=hc(o);return f.jsx(n5,{...m,...u,ref:r,align:s,collisionPadding:c,style:{boxSizing:"border-box",...u.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});gf.displayName=v5;var[y5,gm]=Do(Sr,{}),vf="SelectViewport",W0=g.forwardRef((t,r)=>{const{__scopeSelect:o,nonce:s,...c}=t,u=Xa(vf,o),m=gm(vf,o),h=Fe(r,u.onViewportChange),v=g.useRef(0);return f.jsxs(f.Fragment,{children:[f.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:s}),f.jsx(fc.Slot,{scope:o,children:f.jsx(Le.div,{"data-radix-select-viewport":"",role:"presentation",...c,ref:h,style:{position:"relative",flex:1,overflow:"hidden auto",...c.style},onScroll:ze(c.onScroll,p=>{const b=p.currentTarget,{contentWrapper:y,shouldExpandOnScrollRef:S}=m;if(S?.current&&y){const A=Math.abs(v.current-b.scrollTop);if(A>0){const C=window.innerHeight-vn*2,T=parseFloat(y.style.minHeight),E=parseFloat(y.style.height),R=Math.max(T,E);if(R<C){const k=R+A,O=Math.min(C,k),U=k-O;y.style.height=O+"px",y.style.bottom==="0px"&&(b.scrollTop=U>0?U:0,y.style.justifyContent="flex-end")}}}v.current=b.scrollTop})})})]})});W0.displayName=vf;var J0="SelectGroup",[b5,x5]=Do(J0),ex=g.forwardRef((t,r)=>{const{__scopeSelect:o,...s}=t,c=Ha();return f.jsx(b5,{scope:o,id:c,children:f.jsx(Le.div,{role:"group","aria-labelledby":c,...s,ref:r})})});ex.displayName=J0;var tx="SelectLabel",nx=g.forwardRef((t,r)=>{const{__scopeSelect:o,...s}=t,c=x5(tx,o);return f.jsx(Le.div,{id:c.id,...s,ref:r})});nx.displayName=tx;var Pi="SelectItem",[w5,ax]=Do(Pi),rx=g.forwardRef((t,r)=>{const{__scopeSelect:o,value:s,disabled:c=!1,textValue:u,...m}=t,h=Ga(Pi,o),v=Xa(Pi,o),p=h.value===s,[b,y]=g.useState(u??""),[S,A]=g.useState(!1),C=Fe(r,k=>v.itemRefCallback?.(k,s,c)),T=Ha(),E=g.useRef("touch"),R=()=>{c||(h.onValueChange(s),h.onOpenChange(!1))};if(s==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return f.jsx(w5,{scope:o,value:s,disabled:c,textId:T,isSelected:p,onItemTextChange:g.useCallback(k=>{y(O=>O||(k?.textContent??"").trim())},[]),children:f.jsx(fc.ItemSlot,{scope:o,value:s,disabled:c,textValue:b,children:f.jsx(Le.div,{role:"option","aria-labelledby":T,"data-highlighted":S?"":void 0,"aria-selected":p&&S,"data-state":p?"checked":"unchecked","aria-disabled":c||void 0,"data-disabled":c?"":void 0,tabIndex:c?void 0:-1,...m,ref:C,onFocus:ze(m.onFocus,()=>A(!0)),onBlur:ze(m.onBlur,()=>A(!1)),onClick:ze(m.onClick,()=>{E.current!=="mouse"&&R()}),onPointerUp:ze(m.onPointerUp,()=>{E.current==="mouse"&&R()}),onPointerDown:ze(m.onPointerDown,k=>{E.current=k.pointerType}),onPointerMove:ze(m.onPointerMove,k=>{E.current=k.pointerType,c?v.onItemLeave?.():E.current==="mouse"&&k.currentTarget.focus({preventScroll:!0})}),onPointerLeave:ze(m.onPointerLeave,k=>{k.currentTarget===document.activeElement&&v.onItemLeave?.()}),onKeyDown:ze(m.onKeyDown,k=>{v.searchRef?.current!==""&&k.key===" "||(s5.includes(k.key)&&R(),k.key===" "&&k.preventDefault())})})})})});rx.displayName=Pi;var zl="SelectItemText",ox=g.forwardRef((t,r)=>{const{__scopeSelect:o,className:s,style:c,...u}=t,m=Ga(zl,o),h=Xa(zl,o),v=ax(zl,o),p=d5(zl,o),[b,y]=g.useState(null),S=Fe(r,R=>y(R),v.onItemTextChange,R=>h.itemTextRefCallback?.(R,v.value,v.disabled)),A=b?.textContent,C=g.useMemo(()=>f.jsx("option",{value:v.value,disabled:v.disabled,children:A},v.value),[v.disabled,v.value,A]),{onNativeOptionAdd:T,onNativeOptionRemove:E}=p;return Ot(()=>(T(C),()=>E(C)),[T,E,C]),f.jsxs(f.Fragment,{children:[f.jsx(Le.span,{id:v.textId,...u,ref:S}),v.isSelected&&m.valueNode&&!m.valueNodeHasChildren?Zl.createPortal(u.children,m.valueNode):null]})});ox.displayName=zl;var lx="SelectItemIndicator",sx=g.forwardRef((t,r)=>{const{__scopeSelect:o,...s}=t;return ax(lx,o).isSelected?f.jsx(Le.span,{"aria-hidden":!0,...s,ref:r}):null});sx.displayName=lx;var yf="SelectScrollUpButton",ix=g.forwardRef((t,r)=>{const o=Xa(yf,t.__scopeSelect),s=gm(yf,t.__scopeSelect),[c,u]=g.useState(!1),m=Fe(r,s.onScrollButtonChange);return Ot(()=>{if(o.viewport&&o.isPositioned){let h=function(){const p=v.scrollTop>0;u(p)};const v=o.viewport;return h(),v.addEventListener("scroll",h),()=>v.removeEventListener("scroll",h)}},[o.viewport,o.isPositioned]),c?f.jsx(ux,{...t,ref:m,onAutoScroll:()=>{const{viewport:h,selectedItem:v}=o;h&&v&&(h.scrollTop=h.scrollTop-v.offsetHeight)}}):null});ix.displayName=yf;var bf="SelectScrollDownButton",cx=g.forwardRef((t,r)=>{const o=Xa(bf,t.__scopeSelect),s=gm(bf,t.__scopeSelect),[c,u]=g.useState(!1),m=Fe(r,s.onScrollButtonChange);return Ot(()=>{if(o.viewport&&o.isPositioned){let h=function(){const p=v.scrollHeight-v.clientHeight,b=Math.ceil(v.scrollTop)<p;u(b)};const v=o.viewport;return h(),v.addEventListener("scroll",h),()=>v.removeEventListener("scroll",h)}},[o.viewport,o.isPositioned]),c?f.jsx(ux,{...t,ref:m,onAutoScroll:()=>{const{viewport:h,selectedItem:v}=o;h&&v&&(h.scrollTop=h.scrollTop+v.offsetHeight)}}):null});cx.displayName=bf;var ux=g.forwardRef((t,r)=>{const{__scopeSelect:o,onAutoScroll:s,...c}=t,u=Xa("SelectScrollButton",o),m=g.useRef(null),h=mc(o),v=g.useCallback(()=>{m.current!==null&&(window.clearInterval(m.current),m.current=null)},[]);return g.useEffect(()=>()=>v(),[v]),Ot(()=>{h().find(b=>b.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[h]),f.jsx(Le.div,{"aria-hidden":!0,...c,ref:r,style:{flexShrink:0,...c.style},onPointerDown:ze(c.onPointerDown,()=>{m.current===null&&(m.current=window.setInterval(s,50))}),onPointerMove:ze(c.onPointerMove,()=>{u.onItemLeave?.(),m.current===null&&(m.current=window.setInterval(s,50))}),onPointerLeave:ze(c.onPointerLeave,()=>{v()})})}),S5="SelectSeparator",dx=g.forwardRef((t,r)=>{const{__scopeSelect:o,...s}=t;return f.jsx(Le.div,{"aria-hidden":!0,...s,ref:r})});dx.displayName=S5;var xf="SelectArrow",E5=g.forwardRef((t,r)=>{const{__scopeSelect:o,...s}=t,c=hc(o),u=Ga(xf,o),m=Xa(xf,o);return u.open&&m.position==="popper"?f.jsx(a5,{...c,...s,ref:r}):null});E5.displayName=xf;var T5="SelectBubbleInput",fx=g.forwardRef(({__scopeSelect:t,value:r,...o},s)=>{const c=g.useRef(null),u=Fe(s,c),m=H0(r);return g.useEffect(()=>{const h=c.current;if(!h)return;const v=window.HTMLSelectElement.prototype,b=Object.getOwnPropertyDescriptor(v,"value").set;if(m!==r&&b){const y=new Event("change",{bubbles:!0});b.call(h,r),h.dispatchEvent(y)}},[m,r]),f.jsx(Le.select,{...o,style:{...P0,...o.style},ref:u,defaultValue:r})});fx.displayName=T5;function mx(t){return t===""||t===void 0}function hx(t){const r=$a(t),o=g.useRef(""),s=g.useRef(0),c=g.useCallback(m=>{const h=o.current+m;r(h),(function v(p){o.current=p,window.clearTimeout(s.current),p!==""&&(s.current=window.setTimeout(()=>v(""),1e3))})(h)},[r]),u=g.useCallback(()=>{o.current="",window.clearTimeout(s.current)},[]);return g.useEffect(()=>()=>window.clearTimeout(s.current),[]),[o,c,u]}function px(t,r,o){const c=r.length>1&&Array.from(r).every(p=>p===r[0])?r[0]:r,u=o?t.indexOf(o):-1;let m=N5(t,Math.max(u,0));c.length===1&&(m=m.filter(p=>p!==o));const v=m.find(p=>p.textValue.toLowerCase().startsWith(c.toLowerCase()));return v!==o?v:void 0}function N5(t,r){return t.map((o,s)=>t[(r+s)%t.length])}var C5=$0,gx=V0,R5=Y0,A5=G0,k5=X0,vx=Q0,_5=W0,j5=ex,yx=nx,bx=rx,O5=ox,D5=sx,xx=ix,wx=cx,Sx=dx;const wf=C5,FD=j5,Sf=R5,$i=g.forwardRef(({className:t,children:r,...o},s)=>f.jsxs(gx,{ref:s,className:ne("flex h-8 w-full items-center justify-between rounded-sm border border-input/85 bg-background/72 px-2.5 py-1.5 text-[11px] shadow-sm ring-offset-background transition-all duration-200 placeholder:text-muted-foreground focus:border-primary/45 focus:bg-background/90 focus:outline-none focus:ring-2 focus:ring-ring/45 focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",t),...o,children:[r,f.jsx(A5,{asChild:!0,children:f.jsx(Pl,{className:"h-4 w-4 opacity-50"})})]}));$i.displayName=gx.displayName;const Ex=g.forwardRef(({className:t,...r},o)=>f.jsx(xx,{ref:o,className:ne("flex cursor-default items-center justify-center py-1",t),...r,children:f.jsx(qT,{className:"h-4 w-4"})}));Ex.displayName=xx.displayName;const Tx=g.forwardRef(({className:t,...r},o)=>f.jsx(wx,{ref:o,className:ne("flex cursor-default items-center justify-center py-1",t),...r,children:f.jsx(Pl,{className:"h-4 w-4"})}));Tx.displayName=wx.displayName;const qi=g.forwardRef(({className:t,children:r,position:o="popper",viewportClassName:s,...c},u)=>f.jsx(k5,{children:f.jsxs(vx,{ref:u,className:ne("relative z-50 max-h-80 min-w-[8rem] overflow-hidden rounded-sm border border-border/70 bg-popover/96 text-popover-foreground shadow-[0_16px_48px_-34px_rgba(0,0,0,0.45)] backdrop-blur-xl data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",o==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",t),position:o,...c,children:[f.jsx(Ex,{}),f.jsx(_5,{className:ne("p-1",o==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]",s),children:r}),f.jsx(Tx,{})]})}));qi.displayName=vx.displayName;const M5=g.forwardRef(({className:t,...r},o)=>f.jsx(yx,{ref:o,className:ne("py-1 pl-6 pr-2 text-[10px] font-semibold",t),...r}));M5.displayName=yx.displayName;const aa=g.forwardRef(({className:t,children:r,...o},s)=>f.jsxs(bx,{ref:s,className:ne("relative flex w-full cursor-default select-none items-center rounded-sm py-1 pl-6 pr-2 text-[11px] outline-none transition-colors focus:bg-accent/80 focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t),...o,children:[f.jsx("span",{className:"absolute left-1.5 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(D5,{children:f.jsx(Oi,{className:"h-3.5 w-3.5"})})}),f.jsx(O5,{children:r})]}));aa.displayName=bx.displayName;const z5=g.forwardRef(({className:t,...r},o)=>f.jsx(Sx,{ref:o,className:ne("-mx-1 my-1 h-px bg-muted",t),...r}));z5.displayName=Sx.displayName;var Qd="rovingFocusGroup.onEntryFocus",L5={bubbles:!1,cancelable:!0},Wl="RovingFocusGroup",[Ef,Nx,U5]=p0(Wl),[B5,Cx]=Ya(Wl,[U5]),[H5,P5]=B5(Wl),Rx=g.forwardRef((t,r)=>f.jsx(Ef.Provider,{scope:t.__scopeRovingFocusGroup,children:f.jsx(Ef.Slot,{scope:t.__scopeRovingFocusGroup,children:f.jsx($5,{...t,ref:r})})}));Rx.displayName=Wl;var $5=g.forwardRef((t,r)=>{const{__scopeRovingFocusGroup:o,orientation:s,loop:c=!1,dir:u,currentTabStopId:m,defaultCurrentTabStopId:h,onCurrentTabStopIdChange:v,onEntryFocus:p,preventScrollOnEntryFocus:b=!1,...y}=t,S=g.useRef(null),A=Fe(r,S),C=sm(u),[T,E]=To({prop:m,defaultProp:h??null,onChange:v,caller:Wl}),[R,k]=g.useState(!1),O=$a(p),U=Nx(o),z=g.useRef(!1),[G,Y]=g.useState(0);return g.useEffect(()=>{const q=S.current;if(q)return q.addEventListener(Qd,O),()=>q.removeEventListener(Qd,O)},[O]),f.jsx(H5,{scope:o,orientation:s,dir:C,loop:c,currentTabStopId:T,onItemFocus:g.useCallback(q=>E(q),[E]),onItemShiftTab:g.useCallback(()=>k(!0),[]),onFocusableItemAdd:g.useCallback(()=>Y(q=>q+1),[]),onFocusableItemRemove:g.useCallback(()=>Y(q=>q-1),[]),children:f.jsx(Le.div,{tabIndex:R||G===0?-1:0,"data-orientation":s,...y,ref:A,style:{outline:"none",...t.style},onMouseDown:ze(t.onMouseDown,()=>{z.current=!0}),onFocus:ze(t.onFocus,q=>{const re=!z.current;if(q.target===q.currentTarget&&re&&!R){const fe=new CustomEvent(Qd,L5);if(q.currentTarget.dispatchEvent(fe),!fe.defaultPrevented){const ue=U().filter(j=>j.focusable),de=ue.find(j=>j.active),W=ue.find(j=>j.id===T),ee=[de,W,...ue].filter(Boolean).map(j=>j.ref.current);_x(ee,b)}}z.current=!1}),onBlur:ze(t.onBlur,()=>k(!1))})})}),Ax="RovingFocusGroupItem",kx=g.forwardRef((t,r)=>{const{__scopeRovingFocusGroup:o,focusable:s=!0,active:c=!1,tabStopId:u,children:m,...h}=t,v=Ha(),p=u||v,b=P5(Ax,o),y=b.currentTabStopId===p,S=Nx(o),{onFocusableItemAdd:A,onFocusableItemRemove:C,currentTabStopId:T}=b;return g.useEffect(()=>{if(s)return A(),()=>C()},[s,A,C]),f.jsx(Ef.ItemSlot,{scope:o,id:p,focusable:s,active:c,children:f.jsx(Le.span,{tabIndex:y?0:-1,"data-orientation":b.orientation,...h,ref:r,onMouseDown:ze(t.onMouseDown,E=>{s?b.onItemFocus(p):E.preventDefault()}),onFocus:ze(t.onFocus,()=>b.onItemFocus(p)),onKeyDown:ze(t.onKeyDown,E=>{if(E.key==="Tab"&&E.shiftKey){b.onItemShiftTab();return}if(E.target!==E.currentTarget)return;const R=I5(E,b.orientation,b.dir);if(R!==void 0){if(E.metaKey||E.ctrlKey||E.altKey||E.shiftKey)return;E.preventDefault();let O=S().filter(U=>U.focusable).map(U=>U.ref.current);if(R==="last")O.reverse();else if(R==="prev"||R==="next"){R==="prev"&&O.reverse();const U=O.indexOf(E.currentTarget);O=b.loop?Y5(O,U+1):O.slice(U+1)}setTimeout(()=>_x(O))}}),children:typeof m=="function"?m({isCurrentTabStop:y,hasTabStop:T!=null}):m})})});kx.displayName=Ax;var q5={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function V5(t,r){return r!=="rtl"?t:t==="ArrowLeft"?"ArrowRight":t==="ArrowRight"?"ArrowLeft":t}function I5(t,r,o){const s=V5(t.key,o);if(!(r==="vertical"&&["ArrowLeft","ArrowRight"].includes(s))&&!(r==="horizontal"&&["ArrowUp","ArrowDown"].includes(s)))return q5[s]}function _x(t,r=!1){const o=document.activeElement;for(const s of t)if(s===o||(s.focus({preventScroll:r}),document.activeElement!==o))return}function Y5(t,r){return t.map((o,s)=>t[(r+s)%t.length])}var G5=Rx,X5=kx,pc="Tabs",[Q5]=Ya(pc,[Cx]),jx=Cx(),[K5,vm]=Q5(pc),Ox=g.forwardRef((t,r)=>{const{__scopeTabs:o,value:s,onValueChange:c,defaultValue:u,orientation:m="horizontal",dir:h,activationMode:v="automatic",...p}=t,b=sm(h),[y,S]=To({prop:s,onChange:c,defaultProp:u??"",caller:pc});return f.jsx(K5,{scope:o,baseId:Ha(),value:y,onValueChange:S,orientation:m,dir:b,activationMode:v,children:f.jsx(Le.div,{dir:b,"data-orientation":m,...p,ref:r})})});Ox.displayName=pc;var Dx="TabsList",Mx=g.forwardRef((t,r)=>{const{__scopeTabs:o,loop:s=!0,...c}=t,u=vm(Dx,o),m=jx(o);return f.jsx(G5,{asChild:!0,...m,orientation:u.orientation,dir:u.dir,loop:s,children:f.jsx(Le.div,{role:"tablist","aria-orientation":u.orientation,...c,ref:r})})});Mx.displayName=Dx;var zx="TabsTrigger",Lx=g.forwardRef((t,r)=>{const{__scopeTabs:o,value:s,disabled:c=!1,...u}=t,m=vm(zx,o),h=jx(o),v=Hx(m.baseId,s),p=Px(m.baseId,s),b=s===m.value;return f.jsx(X5,{asChild:!0,...h,focusable:!c,active:b,children:f.jsx(Le.button,{type:"button",role:"tab","aria-selected":b,"aria-controls":p,"data-state":b?"active":"inactive","data-disabled":c?"":void 0,disabled:c,id:v,...u,ref:r,onMouseDown:ze(t.onMouseDown,y=>{!c&&y.button===0&&y.ctrlKey===!1?m.onValueChange(s):y.preventDefault()}),onKeyDown:ze(t.onKeyDown,y=>{[" ","Enter"].includes(y.key)&&m.onValueChange(s)}),onFocus:ze(t.onFocus,()=>{const y=m.activationMode!=="manual";!b&&!c&&y&&m.onValueChange(s)})})})});Lx.displayName=zx;var Ux="TabsContent",Bx=g.forwardRef((t,r)=>{const{__scopeTabs:o,value:s,forceMount:c,children:u,...m}=t,h=vm(Ux,o),v=Hx(h.baseId,s),p=Px(h.baseId,s),b=s===h.value,y=g.useRef(b);return g.useEffect(()=>{const S=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(S)},[]),f.jsx(_o,{present:c||b,children:({present:S})=>f.jsx(Le.div,{"data-state":b?"active":"inactive","data-orientation":h.orientation,role:"tabpanel","aria-labelledby":v,hidden:!S,id:p,tabIndex:0,...m,ref:r,style:{...t.style,animationDuration:y.current?"0s":void 0},children:S&&u})})});Bx.displayName=Ux;function Hx(t,r){return`${t}-trigger-${r}`}function Px(t,r){return`${t}-content-${r}`}var Z5=Ox,$x=Mx,qx=Lx,Vx=Bx;const F5=Z5,Ix=g.forwardRef(({className:t,...r},o)=>f.jsx($x,{ref:o,className:ne("inline-flex h-8 items-center justify-center rounded-sm bg-muted/72 p-0.5 text-muted-foreground shadow-inner shadow-background/40",t),...r}));Ix.displayName=$x.displayName;const Ri=g.forwardRef(({className:t,...r},o)=>f.jsx(qx,{ref:o,className:ne("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-2 py-0.5 text-[11px] font-semibold ring-offset-background transition-all duration-200 hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/60 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-primary/12 data-[state=active]:text-primary data-[state=active]:shadow-[0_10px_28px_-18px_hsl(var(--primary)/0.85)]",t),...r}));Ri.displayName=qx.displayName;const Vi=g.forwardRef(({className:t,...r},o)=>f.jsx(Vx,{ref:o,className:ne("mt-2 ring-offset-background data-[state=inactive]:hidden focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",t),...r}));Vi.displayName=Vx.displayName;var Yx="AlertDialog",[W5]=Ya(Yx,[Yb]),ia=Yb(),Gx=t=>{const{__scopeAlertDialog:r,...o}=t,s=ia(r);return f.jsx(s0,{...s,...o,modal:!0})};Gx.displayName=Yx;var J5="AlertDialogTrigger",Xx=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,...s}=t,c=ia(o);return f.jsx(i0,{...c,...s,ref:r})});Xx.displayName=J5;var e_="AlertDialogPortal",Qx=t=>{const{__scopeAlertDialog:r,...o}=t,s=ia(r);return f.jsx(c0,{...s,...o})};Qx.displayName=e_;var t_="AlertDialogOverlay",Kx=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,...s}=t,c=ia(o);return f.jsx(am,{...c,...s,ref:r})});Kx.displayName=t_;var Eo="AlertDialogContent",[n_,a_]=W5(Eo),r_=gR("AlertDialogContent"),Zx=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,children:s,...c}=t,u=ia(o),m=g.useRef(null),h=Fe(r,m),v=g.useRef(null);return f.jsx(OA,{contentName:Eo,titleName:Fx,docsSlug:"alert-dialog",children:f.jsx(n_,{scope:o,cancelRef:v,children:f.jsxs(rm,{role:"alertdialog",...u,...c,ref:h,onOpenAutoFocus:ze(c.onOpenAutoFocus,p=>{p.preventDefault(),v.current?.focus({preventScroll:!0})}),onPointerDownOutside:p=>p.preventDefault(),onInteractOutside:p=>p.preventDefault(),children:[f.jsx(r_,{children:s}),f.jsx(l_,{contentRef:m})]})})})});Zx.displayName=Eo;var Fx="AlertDialogTitle",Wx=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,...s}=t,c=ia(o);return f.jsx(om,{...c,...s,ref:r})});Wx.displayName=Fx;var Jx="AlertDialogDescription",e1=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,...s}=t,c=ia(o);return f.jsx(lm,{...c,...s,ref:r})});e1.displayName=Jx;var o_="AlertDialogAction",t1=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,...s}=t,c=ia(o);return f.jsx(sc,{...c,...s,ref:r})});t1.displayName=o_;var n1="AlertDialogCancel",a1=g.forwardRef((t,r)=>{const{__scopeAlertDialog:o,...s}=t,{cancelRef:c}=a_(n1,o),u=ia(o),m=Fe(r,c);return f.jsx(sc,{...u,...s,ref:m})});a1.displayName=n1;var l_=({contentRef:t})=>{const r=`\`${Eo}\` requires a description for the component to be accessible for screen reader users.
331
+
332
+ You can add a description to the \`${Eo}\` by passing a \`${Jx}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
333
+
334
+ Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${Eo}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
335
+
336
+ For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return g.useEffect(()=>{document.getElementById(t.current?.getAttribute("aria-describedby"))||console.warn(r)},[r,t]),null},s_=Gx,i_=Xx,c_=Qx,r1=Kx,o1=Zx,l1=t1,s1=a1,i1=Wx,c1=e1;const Tf=s_,Nf=i_,u_=c_,u1=g.forwardRef(({className:t,...r},o)=>f.jsx(r1,{className:ne("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",t),...r,ref:o}));u1.displayName=r1.displayName;const Ii=g.forwardRef(({className:t,...r},o)=>f.jsxs(u_,{children:[f.jsx(u1,{}),f.jsx(o1,{ref:o,className:ne("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-3 rounded-sm border bg-background p-4 shadow-[0_24px_84px_-54px_rgba(0,0,0,0.55)] duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]",t),...r})]}));Ii.displayName=o1.displayName;const Yi=({className:t,...r})=>f.jsx("div",{className:ne("flex flex-col space-y-1.5 text-center sm:text-left",t),...r});Yi.displayName="AlertDialogHeader";const Gi=({className:t,...r})=>f.jsx("div",{className:ne("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",t),...r});Gi.displayName="AlertDialogFooter";const Xi=g.forwardRef(({className:t,...r},o)=>f.jsx(i1,{ref:o,className:ne("text-sm font-semibold",t),...r}));Xi.displayName=i1.displayName;const Qi=g.forwardRef(({className:t,...r},o)=>f.jsx(c1,{ref:o,className:ne("text-[11px] text-muted-foreground",t),...r}));Qi.displayName=c1.displayName;const Ki=g.forwardRef(({className:t,...r},o)=>f.jsx(l1,{ref:o,className:ne(Kf(),t),...r}));Ki.displayName=l1.displayName;const Zi=g.forwardRef(({className:t,...r},o)=>f.jsx(s1,{ref:o,className:ne(Kf({variant:"outline"}),"mt-2 sm:mt-0",t),...r}));Zi.displayName=s1.displayName;const d_={online:"bg-emerald-500",busy:"bg-amber-500",offline:"bg-destructive"},f_={online:"Online",busy:"Busy",offline:"Offline"},m_={default:"h-2.5 w-2.5",compact:"h-2 w-2"};function d1({className:t,pulse:r=!0,size:o="default",status:s}){const c=m_[o],u=f_[s];return f.jsxs("span",{role:"img","aria-label":u,title:u,className:ne("relative inline-flex shrink-0",c,t),children:[r&&s==="online"&&f.jsx("span",{"aria-hidden":"true",className:"absolute inline-flex h-full w-full animate-ping rounded-full bg-emerald-500 opacity-30"}),f.jsx("span",{"aria-hidden":"true",className:ne("relative inline-flex rounded-full",c,d_[s])})]})}function h_({role:t,size:r="default"}){return f.jsx(xn,{variant:t==="leader"?"default":"secondary",className:ne(r==="compact"?"px-1.5 py-0 text-[9px] leading-4":"text-[11px]"),children:t})}const f1={pending:{variant:"secondary",dotClass:"bg-muted-foreground",className:"border-transparent bg-muted/55 text-muted-foreground"},assigned:{variant:"outline",dotClass:"bg-teal-500",className:"border-teal-500/20 bg-teal-500/8 text-teal-700 dark:text-teal-300"},running:{variant:"outline",dotClass:"bg-amber-500",className:"border-amber-500/22 bg-amber-500/9 text-amber-700 dark:text-amber-300"},completed:{variant:"outline",dotClass:"bg-emerald-500",className:"border-emerald-500/18 bg-emerald-500/8 text-emerald-700 dark:text-emerald-300"},failed:{variant:"destructive",dotClass:"bg-destructive-foreground",className:"border-destructive/20 bg-destructive/90 text-destructive-foreground"},cancelled:{variant:"secondary",dotClass:"bg-muted-foreground",className:"border-transparent bg-muted/55 text-muted-foreground"},archived:{variant:"secondary",dotClass:"bg-slate-400",className:"border-transparent bg-muted/50 text-muted-foreground"}};function WD({status:t,size:r="default"}){const o=f1[t],s=r==="compact"?"gap-0.5 px-1 py-0 text-[8px] leading-3 [&>span]:h-[3px] [&>span]:w-[3px]":"gap-1 px-1.5 py-0 text-[10px] leading-4 [&>span]:h-[5px] [&>span]:w-[5px]";return f.jsxs(xn,{variant:o.variant,className:ne("rounded-sm font-medium shadow-none",s,o.className),children:[f.jsx("span",{className:ne("rounded-full",o.dotClass)}),t]})}function JD({status:t,isNative:r=!1,size:o="default",className:s}){const c=f1[t],u=[t,r?"native":null].filter(Boolean).join(", "),m=o==="compact"?"h-1.5 w-1.5":"h-2 w-2";return f.jsxs("span",{className:ne("inline-flex shrink-0 items-center gap-1",s),title:u,"aria-label":u,children:[f.jsx("span",{className:ne("rounded-full",m,c.dotClass),title:t}),r&&f.jsx("span",{className:ne("rounded-full bg-sky-500",m),title:"native"})]})}const p_={critical:{variant:"destructive",label:"Critical"},high:{variant:"outline",label:"High"},normal:{variant:"secondary",label:"Normal"},low:{variant:"secondary",label:"Low"}};function e3({priority:t}){const r=p_[t];return f.jsx(xn,{variant:r.variant,className:"rounded-sm px-1.5 py-0 text-[10px] leading-4 shadow-none",children:r.label})}function g_(t){return[{key:"workspace",label:"Workspace",value:t?.workspace},{key:"node",label:"Node app",value:t?.node},{key:"core",label:"Core",value:t?.core},{key:"dashboard",label:"Dashboard",value:t?.dashboard},{key:"api",label:"API",value:t?.api}].filter(o=>o.value)}function vo({label:t,value:r,mono:o=!1}){return f.jsxs("div",{className:"min-w-0 rounded-sm border border-border/60 bg-background/65 px-2.5 py-1.5",children:[f.jsx("div",{className:"text-[9px] uppercase tracking-[0.16em] text-muted-foreground",children:t}),f.jsx("div",{className:o?"mt-0.5 break-all font-mono text-[11px] text-foreground":"mt-0.5 break-all text-[11px] text-foreground",children:r})]})}function v_({formatDateTime:t,viewInfo:r}){const o=g_(r.packages);return f.jsxs(Vi,{value:"about","data-about-layout":"compact",className:"mt-0 space-y-2",children:[f.jsxs($l,{className:"rounded-sm border-border/70 bg-background/75 shadow-none",children:[f.jsxs(ql,{className:"pb-1.5 pt-2.5 px-3",children:[f.jsxs(Vl,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(MT,{className:"h-3.5 w-3.5 text-primary"}),"Repository & runtime"]}),f.jsx(Il,{className:"text-[10px]",children:"Build source and runtime identity for this node."})]}),f.jsxs(Yl,{className:"space-y-2 px-3 pb-2.5",children:[r.repository?.url?f.jsxs("a",{href:r.repository.url,target:"_blank",rel:"noreferrer",className:"group flex min-w-0 items-center justify-between gap-2 rounded-sm border border-border/70 bg-background/70 px-2.5 py-1.5 text-[11px] text-foreground transition-colors hover:border-primary/40 hover:bg-primary/5",children:[f.jsx("span",{className:"truncate font-mono text-[10px]",children:r.repository.url}),f.jsx(ob,{className:"h-3.5 w-3.5 shrink-0 text-muted-foreground transition-transform group-hover:-translate-y-0.5 group-hover:translate-x-0.5"})]}):f.jsx("div",{className:"rounded-sm border border-dashed border-border/70 bg-muted/20 px-2.5 py-1.5 text-[11px] text-muted-foreground",children:"Repository URL is unavailable in this runtime."}),f.jsxs("div",{className:"grid gap-1.5 sm:grid-cols-2 lg:grid-cols-3",children:[f.jsx(vo,{label:"Branch",value:r.repository?.branch??"Unavailable",mono:!!r.repository?.branch}),f.jsx(vo,{label:"Commit",value:r.repository?.commit??"Unavailable",mono:!!r.repository?.commit}),f.jsx(vo,{label:"Runtime",value:`${r.packageName??"meshy"} ${r.version}`,mono:!0}),f.jsx(vo,{label:"Node.js",value:r.runtime?.nodeVersion??"Unavailable",mono:!!r.runtime?.nodeVersion}),f.jsx(vo,{label:"PID",value:r.runtime?String(r.runtime.pid):"Unavailable",mono:!!r.runtime}),f.jsx(vo,{label:"Started",value:t(r.runtime?.startedAt)})]})]})]}),f.jsxs($l,{className:"rounded-sm border-border/70 bg-background/75 shadow-none",children:[f.jsxs(ql,{className:"pb-1.5 pt-2.5 px-3",children:[f.jsxs(Vl,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(WT,{className:"h-3.5 w-3.5 text-primary"}),"Package versions"]}),f.jsx(Il,{className:"text-[10px]",children:"Version snapshot for the packages most relevant to this dashboard session."})]}),f.jsx(Yl,{"data-package-layout":"list",className:"space-y-1.5 px-3 pb-2.5",children:o.map(s=>f.jsxs("div",{className:"grid gap-1.5 rounded-sm border border-border/60 bg-background/65 px-2.5 py-1.5 sm:grid-cols-[9rem_minmax(0,1fr)_auto] sm:items-center",children:[f.jsx("div",{className:"text-[11px] font-medium text-foreground",children:s.label}),f.jsx("div",{className:"min-w-0 truncate text-[10px] text-muted-foreground",children:s.value?.name}),f.jsx(xn,{variant:"outline",className:"w-fit rounded-sm border-border/70 bg-background/60 font-mono text-[10px]",children:s.value?.version})]},s.key))})]})]})}const y_="codex",t3="bypass",m1=[{value:"codex",label:"Codex",supportsFollowUp:!0},{value:"claudecode",label:"Claude Code",supportsFollowUp:!0},{value:"copilot",label:"Copilot",supportsFollowUp:!0},{value:"mars",label:"mars",disabled:!0,description:"coming soon"},{value:"eureka",label:"eureka",disabled:!0,description:"coming soon"}],h1=m1.filter(t=>t.value==="codex"||t.value==="claudecode"||t.value==="copilot");function Cf(t){return h1.some(r=>r.value===t)?t:y_}const n3=[{value:"bypass",label:"Bypass"},{value:"plan",label:"Plan"},{value:"edit",label:"Edit"},{value:"dangerous",label:"Dangerous"}],b_=new Set(m1.filter(t=>t.supportsFollowUp).map(t=>t.value));function a3(t){const r=s=>typeof s=="string"&&b_.has(s),o=(t.nodeSupportedAgents??[]).filter(r);return o.length>0?Array.from(new Set(o)):Array.from(new Set([t.taskAgent,t.activeAgent].filter(r)))}const r3=[{value:"active",label:"Active"},{value:"running",label:"Running"},{value:"waiting",label:"Waiting"},{value:"closed",label:"Closed"},{value:"shared",label:"Shared"},{value:"archived",label:"Archived"}],o3=[{value:"all",label:"All task types"},{value:"native",label:"Native sessions"},{value:"meshy",label:"Meshy chats"}],x_=new Set(["pending","assigned"]),w_=new Set(["running"]),S_=new Set(["completed","failed","cancelled"]),l3=10;function s3(t,r){switch(r){case"running":return w_.has(t.status);case"waiting":return x_.has(t.status);case"closed":return S_.has(t.status);case"shared":return!!t.activeShare;case"archived":return t.status==="archived";default:return t.status!=="archived"}}function i3(t,r){if(r==="all")return!0;const o=t.conversationKind==="nativeSession";return r==="native"?o:!o}function c3(t,r){const o=r.trim().toLowerCase();return o?[t.title,t.description,t.id,t.agent,t.assignedTo??"",t.assignedNodeName??"",t.project??"",t.effectiveProjectPath??"",t.conversationKind==="nativeSession"?"native session":"meshy chat",t.activeShare?"shared conversation":""].some(s=>s.toLowerCase().includes(o)):!0}function E_(t,r,o){return t?r?.find(c=>c.id===t)?.name??o??t.slice(0,8):"unassigned"}function u3(t,r,o){return E_(t,r,o).toLowerCase()}function d3(t){return t.type!=="node.status"&&t.type!=="cluster.state"}function f3(t,r,o){return!t.assignedTo||o?.id===t.assignedTo?!0:r?.some(s=>s.id===t.assignedTo)??!1}function m3(t,r){return[...t].sort((o,s)=>o.id===r?-1:s.id===r?1:o.name.localeCompare(s.name))}function h3(t){if(!t||typeof t!="object")return null;const r=t,o=r.createMode,s=o==="chat"||o==="native"?o:void 0,c=r.createDefaults,u=c&&typeof c=="object"&&!Array.isArray(c)?c:null,m=u?{assignTo:typeof u.assignTo=="string"||u.assignTo===null?u.assignTo:void 0,project:typeof u.project=="string"||u.project===null?u.project:void 0}:void 0;return{draftNewTask:r.draftNewTask===!0,returnRoute:typeof r.returnRoute=="string"?r.returnRoute:void 0,returnTaskId:typeof r.returnTaskId=="string"||r.returnTaskId===null?r.returnTaskId:void 0,createMode:s,createDefaults:m}}function p3(t){return t==="default workspace"?t:t.replace(/\\/g,"/").split("/").filter(Boolean).at(-1)??t}function g3(t){const r=Date.now()-t;return r<6e4?"just now":r<36e5?`${Math.floor(r/6e4)}m`:r<864e5?`${Math.floor(r/36e5)}h`:`${Math.floor(r/864e5)}d`}function v3(t){return new Date(t).toLocaleString()}function y3(t){const r=Math.floor(t/1e3),o=Math.floor(r/3600),s=Math.floor(r%3600/60),c=r%60;return`${String(o).padStart(2,"0")}:${String(s).padStart(2,"0")}:${String(c).padStart(2,"0")}`}async function p1(t,r="Copied to clipboard"){try{if(globalThis.navigator?.clipboard?.writeText)return await globalThis.navigator.clipboard.writeText(t),Ce.success(r),!0;const o=globalThis.document,s=o?.execCommand?.bind(o);if(!o?.body||typeof o.createElement!="function"||typeof s!="function")throw new Error("Clipboard access is unavailable");const c=o.createElement("textarea"),u=o.activeElement,m=u&&typeof u.focus=="function"?u:null;c.value=t,c.setAttribute("readonly","true"),c.style.position="fixed",c.style.opacity="0",c.style.pointerEvents="none",o.body.appendChild(c),c.select(),c.setSelectionRange(0,c.value.length);const h=s("copy");if(o.body.removeChild(c),m?.focus(),!h)throw new Error("Clipboard access is unavailable");return Ce.success(r),!0}catch(o){return Ce.error(o instanceof Error?o.message:"Failed to copy"),!1}}const T_="default workspace";function Ai(t){const r=t.replace(/\\/g,"/");return r==="/"||/^[A-Za-z]:\/$/.test(r)?r:r.replace(/\/+$/g,"")||r}function N_(t){const r=t.replace(/\\/g,"/");return r.startsWith("/")||r.startsWith("//")||/^[A-Za-z]:\//.test(r)}function C_(t,r){const o=Ai(t),s=r.replace(/\\/g,"/").replace(/^\/+|\/+$/g,"");return!s||s==="."?o:o==="/"||/^[A-Za-z]:\/$/.test(o)?`${o}${s}`:`${o}/${s}`}function R_(t,r){const o=t.effectiveProjectPath?.trim();if(o)return Ai(o);const s=t.project?.trim();if(!s)return T_;if(N_(s)||!t.assignedTo)return Ai(s);const c=r?.get(t.assignedTo)?.trim();return c?C_(c,s):Ai(s)}function b3({nodeStatusById:t,nodeNameById:r,nodeFilter:o,searchQuery:s,nodeWorkDirById:c}){const u=o.trim().toLowerCase(),m=s.trim().toLowerCase(),h=[];for(const[v,p]of t){if(p==="offline"||u==="unassigned")continue;const b=r.get(v)??v.slice(0,8);if(!(u&&u!=="all"&&b.toLowerCase()!==u)){if(m){const y=c?.get(v)??"";if(![v,b,y].some(A=>A.toLowerCase().includes(m)))continue}h.push(v)}}return h}function x3(t,r,o,s,c){const u=new Map;for(const h of t){const v=h.assignedTo??null,p=v??"__unassigned__",b=v?r.get(v)??h.assignedNodeName??v.slice(0,8):"Unassigned",y=R_(h,s);u.has(p)||u.set(p,{nodeId:v,nodeName:b,dirMap:new Map});const S=u.get(p);S.dirMap.has(y)||S.dirMap.set(y,[]),S.dirMap.get(y).push(h)}for(const h of c??[])u.has(h)||u.set(h,{nodeId:h,nodeName:r.get(h)??h.slice(0,8),dirMap:new Map});const m=Array.from(u.values()).map(({nodeId:h,nodeName:v,dirMap:p})=>{const b=Array.from(p.entries()).map(([y,S])=>({path:y,tasks:S})).sort((y,S)=>S.tasks.length-y.tasks.length||y.path.localeCompare(S.path));return{nodeId:h,nodeName:v,dirs:b}});return m.sort((h,v)=>{if(o){if(h.nodeId===o)return-1;if(v.nodeId===o)return 1}return h.nodeId===null?1:v.nodeId===null?-1:h.nodeName.localeCompare(v.nodeName)}),m}const A_=["queued","running"],k_=["copilot.tunnel","copilot.tunnel.disable"],__=1e4;function dy(t){return t?.status==="succeeded"||t?.status==="failed"}function j_(t){return t.reduce((r,o)=>!r||o.updatedAt>r.updatedAt?o:r,null)}async function O_(t,r=Jy){const o=await Promise.all(k_.flatMap(s=>A_.map(c=>r({kind:s,status:c,nodeId:t}))));return j_(o.flat())}function fy(t){return t?.split(/\r?\n/).map(r=>r.trim()).filter(Boolean).at(-1)??null}function D_(t,r){return[t,...r].join(" ")}function M_(t,r,o){return r&&!t?"Checking port 8314":t?t.status==="queued"?"Queued":t.status==="running"?t.kind==="copilot.tunnel.disable"?"Stopping Meshy-managed tunnel":t.kind==="copilot.tunnel"?t.result?.status==="auth-required"?"Waiting for GitHub device authorization":"Starting Copilot tunnel":"Checking port 8314":t.status==="succeeded"?t.result?.available?t.result.status==="already-running"?"Port 8314 is already reachable":"Proxy is listening on 8314":t.result?.status==="stopped"?"Meshy-managed tunnel stopped":"Port 8314 is not listening":o??"Tunnel operation failed":"Port 8314 status has not been checked"}function z_(t,r){return r||t?.status==="queued"||t?.status==="running"?f.jsx(lb,{className:"h-3.5 w-3.5 animate-spin text-primary"}):t?.result?.available?f.jsx(xo,{className:"h-3.5 w-3.5 text-emerald-500"}):t?.status==="failed"?f.jsx(sf,{className:"h-3.5 w-3.5 text-destructive"}):f.jsx(sf,{className:"h-3.5 w-3.5 text-muted-foreground"})}function L_({checked:t,disabled:r,onCheckedChange:o}){return f.jsx("button",{type:"button",role:"switch","aria-checked":t,"aria-label":"Toggle GitHub Copilot Tunnel",title:t?"Disable GitHub Copilot Tunnel":"Enable GitHub Copilot Tunnel","data-copilot-tunnel-switch":"true",disabled:r,onClick:()=>o(!t),className:ne("relative h-5 w-9 shrink-0 rounded-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/70 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",t?"bg-primary/85":"bg-muted"),children:f.jsx("span",{className:ne("absolute left-0.5 top-1/2 h-3.5 w-3.5 -translate-y-1/2 rounded-sm bg-background shadow-sm transition-transform",t?"translate-x-4":"translate-x-0")})})}function U_({nodeId:t,nodeName:r}){const[o,s]=g.useState(null),[c,u]=g.useState(!1),[m,h]=g.useState(!1),v=o?.status==="queued"||o?.status==="running",p=o?.result,b=p?.auth??null,y=o?.error??p?.detail??fy(p?.stderr)??fy(p?.stdout),S=p?D_(p.command,p.args):"npx -y ghc-tunnel@latest -d",A=!!p?.available||v&&o?.kind==="copilot.tunnel",C=c||m||v,T=g.useMemo(()=>M_(o,c,y),[c,y,o]);g.useEffect(()=>{let R=!1;async function k(){u(!0);try{const O=await O_(t);if(R)return;if(O){s(O);return}const U=await Nv(t);R||s(U)}catch(O){R||Ce.error(O instanceof Error?O.message:"Failed to check Copilot tunnel")}finally{R||u(!1)}}return s(null),k(),()=>{R=!0}},[t]),g.useEffect(()=>{if(!o||dy(o))return;let R=!1;const k=o.id;async function O(){try{const z=await Wy(k);if(R)return;if(z.kind==="copilot.tunnel.status"&&!dy(z)&&Date.now()-z.createdAt>__){const G=await Nv(t);R||s(G);return}s(z),z.status==="succeeded"&&z.kind==="copilot.tunnel"&&Ce.success(`Copilot tunnel is available on ${r}`),z.status==="succeeded"&&z.kind==="copilot.tunnel.disable"&&Ce.success(`Copilot tunnel stopped on ${r}`),z.status==="failed"&&z.kind!=="copilot.tunnel.status"&&Ce.error(z.error??"Copilot tunnel failed")}catch(z){R||Ce.error(z instanceof Error?z.message:"Failed to refresh Copilot tunnel")}}O();const U=window.setInterval(O,2e3);return()=>{R=!0,window.clearInterval(U)}},[t,r,o?.id,o?.status]);const E=g.useCallback(async R=>{h(!0);try{const k=R?await IE(t):await YE(t);s(k),Ce.info(R?`Copilot tunnel enable requested on ${r}`:`Copilot tunnel stop requested on ${r}`)}catch(k){Ce.error(k instanceof Error?k.message:"Failed to update Copilot tunnel")}finally{h(!1)}},[t,r]);return f.jsxs($l,{"data-copilot-tunnel-section":"true",className:"rounded-sm border-border/70 bg-background/75 shadow-none xl:col-span-2",children:[f.jsx(ql,{className:"pb-1.5 pt-2.5 px-3",children:f.jsxs("div",{className:"flex items-start justify-between gap-3",children:[f.jsxs("div",{className:"min-w-0",children:[f.jsxs(Vl,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(UT,{className:"h-3.5 w-3.5 text-primary"}),"GitHub Copilot Tunnel"]}),f.jsx(Il,{className:"text-[10px]",children:"Node-local Copilot proxy model provider."})]}),f.jsxs("div",{className:"flex shrink-0 items-center gap-2",children:[f.jsx("span",{"aria-label":T,title:T,className:"inline-flex h-5 w-5 items-center justify-center",children:z_(o,c)}),f.jsx(L_,{checked:A,disabled:C,onCheckedChange:R=>{E(R)}})]})]})}),f.jsxs(Yl,{className:"space-y-2 px-3 pb-2.5",children:[f.jsxs("div",{className:"space-y-1.5 rounded-sm bg-background/55 px-2.5 py-2",children:[f.jsxs("div",{className:"flex items-center gap-1.5 text-[11px] font-medium text-foreground",children:[f.jsx("span",{className:ne("h-1.5 w-1.5 rounded-sm",p?.available?"bg-emerald-500":v||c?"animate-pulse bg-amber-500":o?.status==="failed"?"bg-destructive":"bg-muted-foreground/50")}),T]}),f.jsx("div",{className:"truncate font-mono text-[10px] text-muted-foreground",children:S}),(v||c||m)&&f.jsx("div",{className:"h-0.5 overflow-hidden rounded-sm bg-muted",children:f.jsx("div",{className:"h-full w-1/3 animate-indeterminate-bar bg-primary/70"})})]}),b&&v&&f.jsxs("div",{className:"grid gap-2 rounded-sm border border-primary/35 bg-primary/8 px-2.5 py-2 sm:grid-cols-[minmax(0,1fr)_auto] sm:items-center",children:[f.jsxs("div",{className:"min-w-0 space-y-1",children:[f.jsxs("div",{className:"flex items-center gap-1.5 text-[11px] font-medium text-foreground",children:[f.jsx(eN,{className:"h-3.5 w-3.5 animate-pulse text-primary"}),"GitHub device login"]}),f.jsxs("div",{className:"flex flex-wrap items-center gap-1.5 text-[10px] text-muted-foreground",children:[f.jsx("span",{className:"font-mono text-[11px] text-foreground",children:b.code}),b.expiresInSeconds?f.jsxs("span",{children:[Math.ceil(b.expiresInSeconds/60),"m expiry"]}):null]})]}),f.jsxs("div",{className:"flex items-center gap-1",children:[f.jsx(Nt,{type:"button",variant:"outline",size:"icon",className:"h-7 w-7 rounded-sm",title:"Copy device code","aria-label":"Copy device code",onClick:()=>{p1(b.code,"Device code copied")},children:f.jsx(rb,{className:"h-3.5 w-3.5"})}),f.jsx(Nt,{asChild:!0,variant:"outline",size:"icon",className:"h-7 w-7 rounded-sm",title:"Open GitHub device login","aria-label":"Open GitHub device login",children:f.jsx("a",{href:b.url,target:"_blank",rel:"noreferrer",children:f.jsx(ob,{className:"h-3.5 w-3.5"})})})]})]}),y&&o?.status!=="succeeded"&&f.jsx("div",{className:"rounded-sm border border-border/60 bg-muted/35 px-2 py-1 text-[10px] text-muted-foreground",children:y})]})]})}function B_({value:t,disabled:r=!1,saving:o=!1,onChange:s}){const c=Cf(t);return f.jsxs("div",{"data-default-task-agent-selector":"true",className:"flex shrink-0 flex-col gap-1 sm:items-end",children:[f.jsxs("div",{className:"flex items-center gap-1 text-[9px] uppercase tracking-[0.16em] text-muted-foreground",children:[f.jsx(If,{className:"h-3 w-3"}),"Default agent"]}),f.jsx("div",{className:"flex h-7 items-center gap-0.5 rounded-sm border border-border/60 bg-background/60 p-0.5",children:h1.map(u=>{const m=u.value===c;return f.jsx("button",{type:"button","data-default-task-agent-option":u.value,"aria-pressed":m,disabled:r||o,onClick:()=>s(u.value),className:ne("h-6 rounded-sm border-0 px-2 text-[10px] font-medium shadow-none transition-colors disabled:cursor-not-allowed disabled:opacity-60",m?"bg-primary text-primary-foreground":"bg-muted/45 text-muted-foreground hover:bg-muted/65 hover:text-foreground"),children:u.label},u.value)})})]})}const gc=g.forwardRef(({className:t,type:r,...o},s)=>f.jsx("input",{type:r,className:ne("flex h-8 w-full rounded-sm border border-input/85 bg-background/72 px-2.5 py-1.5 text-[11px] shadow-sm ring-offset-background transition-all duration-200 file:border-0 file:bg-transparent file:text-[11px] file:font-medium file:text-foreground placeholder:text-muted-foreground/75 focus-visible:border-primary/45 focus-visible:bg-background/90 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/45 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",t),ref:s,...o}));gc.displayName="Input";function H_(){return ve("/system/quick-chats")}function P_(t){return ve("/system/quick-chats",{method:"PUT",body:JSON.stringify({quickChats:t})})}const Rf="quick-chats:updated";function $_(){typeof window>"u"||window.dispatchEvent(new CustomEvent(Rf))}function q_(){const[t,r]=g.useState([]),[o,s]=g.useState(!0),[c,u]=g.useState(!1),[m,h]=g.useState(null),v=g.useCallback(async()=>{s(!0);try{const b=await H_();r(b.quickChats),h(null)}catch(b){h(b instanceof Error?b.message:"Failed to load quick chats")}finally{s(!1)}},[]),p=g.useCallback(async b=>{u(!0);try{const y=await P_(b);return r(y.quickChats),h(null),$_(),y.quickChats}catch(y){const S=y instanceof Error?y.message:"Failed to save quick chats";throw h(S),y}finally{u(!1)}},[]);return g.useEffect(()=>{v()},[v]),g.useEffect(()=>{if(typeof window>"u")return;const b=()=>{v()};return window.addEventListener(Rf,b),()=>window.removeEventListener(Rf,b)},[v]),{error:m,loading:o,quickChats:t,refresh:v,save:p,saving:c}}function g1(t){return t.trim().replace(/^\/+/,"").toLowerCase()}function v1(t,r){const o=t.trim();if(!o.startsWith("/"))return[];const s=g1(o);return r.filter(c=>c.alias.startsWith(s))}function Fi(t,r){return r<=0?-1:(t%r+r)%r}function w3(t,r,o=0){const s=v1(t,r),c=Fi(o,s.length);return c>=0?s[c]??null:null}function S3(t,r,o){const s=Fi(t,r);return s<0?0:Fi(s+o,r)}function E3({query:t,quickChats:r,selectedIndex:o=0,onSelect:s,onActiveIndexChange:c}){const u=v1(t,r);if(u.length===0)return null;const m=Fi(o,u.length);return f.jsxs("div",{"data-quick-chat-menu":"true",className:"mx-2 mb-0.5 rounded-sm bg-background/70 p-0.5 shadow-none sm:mx-5",children:[f.jsxs("div",{className:"flex items-center gap-1 px-1 py-0.5 text-[8px] uppercase tracking-[0.14em] text-muted-foreground/75",children:[f.jsx(sb,{className:"h-2.5 w-2.5 text-primary/55"}),"Quick chats"]}),f.jsx("div",{className:"max-h-24 overflow-y-auto",role:"listbox","aria-label":"Quick chats",children:u.map((h,v)=>f.jsxs("button",{type:"button",role:"option","aria-selected":v===m,"data-selected":v===m?"true":void 0,onMouseEnter:()=>c?.(v),onClick:()=>s(h),className:ne("flex w-full min-w-0 items-start gap-1.5 rounded-sm px-1 py-1 text-left text-[9px] transition-colors hover:bg-muted/50 hover:text-foreground"),children:[f.jsxs("span",{"data-quick-chat-alias":"true",className:ne("shrink-0 font-mono text-[9px] leading-3 text-primary/70",v===m&&"text-primary"),children:["/",h.alias]}),f.jsx("span",{"data-quick-chat-prompt":"true",className:ne("line-clamp-1 min-w-0 text-[9px] leading-3 text-muted-foreground",v===m&&"text-primary/90"),children:h.prompt})]},h.alias))})]})}const V_="h-14 w-full resize-none rounded-sm border border-border/70 bg-background/80 px-2 py-1.5 text-[11px] leading-4 ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50";let I_=0;function ki(t,r=0){return{id:t?`${t.alias}:${r}`:`new:${I_++}`,alias:t?.alias??"",prompt:t?.prompt??""}}function Af(t){return{quickChats:t.map(r=>({alias:g1(r.alias),prompt:r.prompt.trim()})).filter(r=>r.alias.length>0&&r.prompt.length>0)}}function Y_(t,r){const o=Af(t).quickChats,s=r.map((u,m)=>ki(u,m)),c=Af(s).quickChats;return JSON.stringify(o)!==JSON.stringify(c)}function G_(){const{error:t,loading:r,quickChats:o,save:s,saving:c}=q_(),[u,m]=g.useState(()=>o.map((y,S)=>ki(y,S))),h=u.length>0,v=g.useMemo(()=>Af(u),[u]),p=g.useMemo(()=>Y_(u,o),[u,o]);g.useEffect(()=>{m(o.map((y,S)=>ki(y,S)))},[o]);async function b(){try{await s(v.quickChats),Ce.success("Quick chats saved")}catch(y){Ce.error(y instanceof Error?y.message:"Failed to save quick chats")}}return f.jsxs("div",{className:"space-y-2",children:[f.jsx("div",{className:"rounded-sm border border-border/70 bg-background/75 px-3 py-2.5",children:f.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[f.jsxs("div",{className:"min-w-0",children:[f.jsxs("div",{className:"flex items-center gap-1.5 text-[12px] font-semibold text-foreground",children:[f.jsx(sb,{className:"h-3.5 w-3.5 text-primary"}),"Quick chats"]}),f.jsx("div",{className:"mt-0.5 text-[10px] text-muted-foreground",children:"Reusable slash aliases for chat composers on this leader."})]}),f.jsxs("div",{className:"flex items-center gap-1.5",children:[f.jsxs(Nt,{type:"button",variant:"outline",onClick:()=>m(y=>[...y,ki(void 0,y.length)]),className:"h-7 rounded-sm px-2 text-[10px]",children:[f.jsx(uN,{className:"h-3.5 w-3.5"}),"Add"]}),f.jsxs(Nt,{type:"button",onClick:b,disabled:c||!p,className:"h-7 rounded-sm px-2 text-[10px]",children:[c?f.jsx(lb,{className:"h-3.5 w-3.5 animate-spin"}):f.jsx(gN,{className:"h-3.5 w-3.5"}),"Save"]})]})]})}),r&&!h?f.jsx("div",{className:"rounded-sm border border-dashed border-border/70 bg-muted/20 px-3 py-4 text-[11px] text-muted-foreground",children:"Loading quick chats..."}):h?f.jsx("div",{className:"space-y-1.5",children:u.map((y,S)=>f.jsxs("div",{className:"grid gap-1.5 rounded-sm border border-border/60 bg-background/70 px-2 py-2 md:grid-cols-[12rem_minmax(0,1fr)_auto]",children:[f.jsx(gc,{"aria-label":`Quick chat ${S+1} alias`,value:y.alias,onChange:A=>m(C=>C.map(T=>T.id===y.id?{...T,alias:A.target.value}:T)),placeholder:"alias",className:"h-7 rounded-sm border-border/70 bg-background/80 px-2 font-mono text-[11px]"}),f.jsx("textarea",{"aria-label":`Quick chat ${S+1} prompt`,value:y.prompt,onChange:A=>m(C=>C.map(T=>T.id===y.id?{...T,prompt:A.target.value}:T)),placeholder:"Prompt text",className:V_}),f.jsx(Nt,{type:"button",variant:"ghost",size:"icon",onClick:()=>m(A=>A.filter(C=>C.id!==y.id)),"aria-label":`Remove quick chat ${S+1}`,className:"h-7 w-7 rounded-sm text-muted-foreground hover:bg-destructive/10 hover:text-destructive",children:f.jsx(_N,{className:"h-3.5 w-3.5"})})]},y.id))}):f.jsx("div",{className:"rounded-sm border border-dashed border-border/70 bg-muted/20 px-3 py-4 text-[11px] text-muted-foreground",children:"No quick chats configured."}),t&&f.jsx("div",{className:"rounded-sm border border-destructive/20 bg-destructive/10 px-3 py-2 text-[11px] text-destructive",children:t})]})}var vc="Checkbox",[X_]=Ya(vc),[Q_,ym]=X_(vc);function K_(t){const{__scopeCheckbox:r,checked:o,children:s,defaultChecked:c,disabled:u,form:m,name:h,onCheckedChange:v,required:p,value:b="on",internal_do_not_use_render:y}=t,[S,A]=To({prop:o,defaultProp:c??!1,onChange:v,caller:vc}),[C,T]=g.useState(null),[E,R]=g.useState(null),k=g.useRef(!1),O=C?!!m||!!C.closest("form"):!0,U={checked:S,disabled:u,setChecked:A,control:C,setControl:T,name:h,form:m,value:b,hasConsumerStoppedPropagationRef:k,required:p,defaultChecked:Pa(c)?!1:c,isFormControl:O,bubbleInput:E,setBubbleInput:R};return f.jsx(Q_,{scope:r,...U,children:Z_(y)?y(U):s})}var y1="CheckboxTrigger",b1=g.forwardRef(({__scopeCheckbox:t,onKeyDown:r,onClick:o,...s},c)=>{const{control:u,value:m,disabled:h,checked:v,required:p,setControl:b,setChecked:y,hasConsumerStoppedPropagationRef:S,isFormControl:A,bubbleInput:C}=ym(y1,t),T=Fe(c,b),E=g.useRef(v);return g.useEffect(()=>{const R=u?.form;if(R){const k=()=>y(E.current);return R.addEventListener("reset",k),()=>R.removeEventListener("reset",k)}},[u,y]),f.jsx(Le.button,{type:"button",role:"checkbox","aria-checked":Pa(v)?"mixed":v,"aria-required":p,"data-state":T1(v),"data-disabled":h?"":void 0,disabled:h,value:m,...s,ref:T,onKeyDown:ze(r,R=>{R.key==="Enter"&&R.preventDefault()}),onClick:ze(o,R=>{y(k=>Pa(k)?!0:!k),C&&A&&(S.current=R.isPropagationStopped(),S.current||R.stopPropagation())})})});b1.displayName=y1;var bm=g.forwardRef((t,r)=>{const{__scopeCheckbox:o,name:s,checked:c,defaultChecked:u,required:m,disabled:h,value:v,onCheckedChange:p,form:b,...y}=t;return f.jsx(K_,{__scopeCheckbox:o,checked:c,defaultChecked:u,disabled:h,required:m,onCheckedChange:p,name:s,form:b,value:v,internal_do_not_use_render:({isFormControl:S})=>f.jsxs(f.Fragment,{children:[f.jsx(b1,{...y,ref:r,__scopeCheckbox:o}),S&&f.jsx(E1,{__scopeCheckbox:o})]})})});bm.displayName=vc;var x1="CheckboxIndicator",w1=g.forwardRef((t,r)=>{const{__scopeCheckbox:o,forceMount:s,...c}=t,u=ym(x1,o);return f.jsx(_o,{present:s||Pa(u.checked)||u.checked===!0,children:f.jsx(Le.span,{"data-state":T1(u.checked),"data-disabled":u.disabled?"":void 0,...c,ref:r,style:{pointerEvents:"none",...t.style}})})});w1.displayName=x1;var S1="CheckboxBubbleInput",E1=g.forwardRef(({__scopeCheckbox:t,...r},o)=>{const{control:s,hasConsumerStoppedPropagationRef:c,checked:u,defaultChecked:m,required:h,disabled:v,name:p,value:b,form:y,bubbleInput:S,setBubbleInput:A}=ym(S1,t),C=Fe(o,A),T=H0(u),E=A0(s);g.useEffect(()=>{const k=S;if(!k)return;const O=window.HTMLInputElement.prototype,z=Object.getOwnPropertyDescriptor(O,"checked").set,G=!c.current;if(T!==u&&z){const Y=new Event("click",{bubbles:G});k.indeterminate=Pa(u),z.call(k,Pa(u)?!1:u),k.dispatchEvent(Y)}},[S,T,u,c]);const R=g.useRef(Pa(u)?!1:u);return f.jsx(Le.input,{type:"checkbox","aria-hidden":!0,defaultChecked:m??R.current,required:h,disabled:v,name:p,value:b,form:y,...r,tabIndex:-1,ref:C,style:{...r.style,...E,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});E1.displayName=S1;function Z_(t){return typeof t=="function"}function Pa(t){return t==="indeterminate"}function T1(t){return Pa(t)?"indeterminate":t?"checked":"unchecked"}const N1=g.forwardRef(({className:t,...r},o)=>f.jsx(bm,{ref:o,className:ne("peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",t),...r,children:f.jsx(w1,{className:ne("flex items-center justify-center text-current"),children:f.jsx(Oi,{className:"h-3.5 w-3.5"})})}));N1.displayName=bm.displayName;const my=["queued","running"];function F_(t){return t.map(r=>`${r.id}:${r.name}`).join("\0")}function W_(t){return t==="claude"||t==="codex"||t==="copilot"}function C1(t){if(t.kind!=="agent.upgrade")return null;const r=t.payload?.agent;return W_(r)?`${t.nodeId}:${r}`:null}function J_(t){return t.status==="succeeded"||t.status==="failed"}async function R1(t,r={}){const o=r.getOperation??Wy,s=r.pollIntervalMs??2e3,c=r.timeoutMs??24e4,u=Date.now()+c;let m=t;for(;!J_(m)&&Date.now()<u;)await tj(s),m=await o(t.id);return m}async function ej(t,r=Jy){const o=new Set(t),s=await Promise.all(my.map(u=>r({kind:"agent.upgrade",status:u}))),c=new Map;for(const u of s.flat()){if(!my.includes(u.status)||o.size>0&&!o.has(u.nodeId))continue;const m=C1(u);if(!m)continue;const h=c.get(m);(!h||u.updatedAt>h.updatedAt)&&c.set(m,u)}return c}function tj(t){return new Promise(r=>setTimeout(r,t))}const nj=1500,aj=1e3,rj=9e4;async function A1(t={}){const r=t.fetchHealth??oj,o=t.initialDelayMs??nj,s=t.pollIntervalMs??aj,c=t.previousPid,u=t.reload??(()=>window.location.reload()),m=t.sleep??sj,h=t.timeoutMs??rj,v=Date.now()+h;let p=!1;for(o>0&&await m(o);Date.now()<=v;){const b=lj(await r());if(!b.ok){p=!0,await m(s);continue}if(c===void 0||b.pid!==void 0&&b.pid!==c||p)return u(),!0;await m(s)}return!1}async function oj(){try{const t=await fetch("/api/system/health",{cache:"no-store"}),r=await t.json().catch(()=>null),o=r&&typeof r=="object"&&typeof r.pid=="number"?r.pid:void 0;return{ok:t.ok,pid:o}}catch{return!1}}function lj(t){return typeof t=="boolean"?{ok:t}:t}function sj(t){return new Promise(r=>window.setTimeout(r,t))}function ij(t,r=!0){return r?t?.restartMode==="development"?"Restart dev runtime":t?.updateAvailable?"Restart to update":"Restart":t?.updateAvailable?"Restart follower to update":"Restart follower"}const hy="h-7 rounded-sm border-0 bg-muted/55 px-2 text-[11px] text-muted-foreground shadow-none hover:bg-muted/75 hover:text-foreground";function cj({checkedLabel:t,disableAuthDefault:r,endpoint:o,isLiveLocalNode:s,nodeId:c,nodeName:u,onRefresh:m,pid:h,transportType:v,update:p,workDir:b}){const y=ij(p,s),[S,A]=g.useState(null),[C,T]=g.useState(()=>py({disableAuthDefault:r,endpoint:o,nodeName:u,transportType:v,workDir:b})),[E,R]=g.useState(!1),[k,O]=g.useState(!1),[U,z]=g.useState(!1);g.useEffect(()=>{T(py({disableAuthDefault:r,endpoint:o,nodeName:u,transportType:v,workDir:b}))},[r,o,u,v,b]);async function G(){if(!c||E||k)return;const ue=p.updateAvailable?"update":"restart",de=fj(C);if(C.port.trim()&&de?.port===void 0){Ce.error("Runtime restart port must be a positive integer");return}const W=de?{reason:ue,startArgs:de}:{reason:ue};R(!0);try{if(s){const P=await eb(W);A({...P,pid:P.pid??h,status:"accepted"}),Ce.info(`Restarting ${u} from a detached helper. PID ${P.pid??h??"unknown"} will not stay attached to the original terminal window; follow ${P.logPath} for launch output.`),A1({previousPid:P.pid??h}).then(H=>{H||(R(!1),Ce.error("Runtime restart was accepted, but the dashboard did not reconnect before the timeout. Refresh the page after the node finishes starting."))}).catch(H=>{R(!1),Ce.error(H instanceof Error?H.message:"Runtime restart recovery failed")});return}const se=await FE(c,W);A({operationId:se.id,pid:h,status:se.status}),Ce.info(`Restart requested on ${u}. Operation ${Kd(se.id)} will hand off to a detached process, so the new runtime will not stay attached to the original terminal window.`);const ee=await R1(se,{timeoutMs:6e4}),j=dj(ee);A({command:j?.command,logPath:j?.logPath,mode:j?.mode,operationId:ee.id,pid:j?.pid??h,status:ee.status}),ee.status==="succeeded"?(await m?.(),Ce.success(`Restart handoff accepted on ${u}. Follow ${j?.logPath??"the node restart log"} for launch output.`)):ee.status==="failed"?Ce.error(ee.error??`Restart failed on ${u}`):Ce.info(`Restart operation ${Kd(ee.id)} is still ${ee.status}. More details will update after the node reports back.`),R(!1)}catch(se){R(!1),Ce.error(se instanceof Error?se.message:"Runtime restart failed")}}async function Y(){if(!(!s||E||k)){O(!0);try{const ue=await QE();Ce.info(`Stopping Meshy process ${ue.pid}`)}catch(ue){O(!1),Ce.error(ue instanceof Error?ue.message:"Runtime stop failed")}}}const q=E?"restarting":k?"stopping":S?.status??"idle",re=p.restartMode==="development",fe=re?"dev":p.updateAvailable?`→ ${p.latestVersion}`:s?"Current":null;return f.jsxs("div",{className:"overflow-hidden rounded-sm border border-border/70 bg-background/70",children:[f.jsxs("div",{className:"flex items-center justify-between gap-2 px-3 py-2 border-b border-border/50",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(of,{className:"h-3.5 w-3.5 text-primary shrink-0"}),f.jsxs("div",{children:[f.jsx("div",{className:"text-[11px] font-semibold text-foreground leading-tight",children:"Runtime"}),f.jsx("div",{className:"text-[10px] text-muted-foreground leading-tight",children:re?"Development launcher":`Latest ${p.latestVersion??"—"}`})]})]}),fe&&f.jsx("div",{className:"flex items-center gap-1.5",children:f.jsx(xn,{variant:p.updateAvailable?"default":"outline",className:ne("rounded-sm px-1.5 py-0 font-mono text-[10px]",fe==="Current"?"border-0 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300":"border-border/70 bg-background/60"),children:fe})})]}),f.jsxs("div",{className:"grid grid-cols-2 divide-x divide-border/50 border-b border-border/50",children:[f.jsxs("div",{className:"px-3 py-1.5",children:[f.jsx("div",{className:"text-[9px] uppercase tracking-[0.16em] text-muted-foreground",children:"PID"}),f.jsx("div",{className:"mt-0.5 font-mono text-[11px] text-foreground",children:h??"—"})]}),f.jsxs("div",{className:"px-3 py-1.5",children:[f.jsx("div",{className:"text-[9px] uppercase tracking-[0.16em] text-muted-foreground",children:"Status"}),f.jsx("div",{className:"mt-0.5 text-[11px] text-foreground capitalize",children:q})]})]}),f.jsxs("div",{className:"flex items-center justify-between gap-2 px-3 py-2",children:[f.jsxs("div",{className:"text-[10px] text-muted-foreground",children:["Checked ",t]}),f.jsxs("div",{className:"flex items-center gap-1.5",children:[s&&f.jsxs(Tf,{children:[f.jsx(Nf,{asChild:!0,children:f.jsxs(Nt,{type:"button",size:"sm",variant:"ghost",disabled:E||k,className:"h-7 rounded-sm px-2 text-[11px] text-muted-foreground hover:bg-destructive/10 hover:text-destructive",children:[f.jsx(fN,{className:ne("mr-1 h-3.5 w-3.5",k&&"animate-pulse")}),k?"Stopping":"Stop"]})}),f.jsxs(Ii,{className:"max-w-[22rem] gap-2 rounded-sm p-4",children:[f.jsxs(Yi,{className:"space-y-1",children:[f.jsx(Xi,{className:"text-[12px]",children:"Stop runtime?"}),f.jsx(Qi,{className:"text-[11px] leading-4",children:"Gracefully stops the current Meshy process without launching a replacement. The dashboard will disconnect until the node is started again."})]}),f.jsxs(Gi,{className:"gap-1 pt-0 sm:space-x-1",children:[f.jsx(Zi,{className:hy,children:"Cancel"}),f.jsx(Ki,{className:"h-7 rounded-sm bg-destructive px-2 text-[11px] text-destructive-foreground hover:bg-destructive/90",onClick:()=>{Y()},children:"Stop runtime"})]})]})]}),f.jsxs(Tf,{children:[f.jsx(Nf,{asChild:!0,children:f.jsxs(Nt,{type:"button",size:"sm",variant:"ghost",disabled:!c||E||k,className:"h-7 rounded-sm border-0 bg-primary/10 px-2 text-[11px] text-primary shadow-none hover:translate-y-0 hover:bg-primary/15 hover:text-primary active:scale-100 disabled:bg-muted/35 disabled:text-muted-foreground",children:[f.jsx(Ei,{className:ne("mr-1 h-3.5 w-3.5",E&&"animate-spin")}),E?"Restarting…":y]})}),f.jsxs(Ii,{className:"max-w-[28rem] gap-3 rounded-sm p-4",children:[f.jsxs(Yi,{className:"space-y-1",children:[f.jsxs(Xi,{className:"text-[12px]",children:[y,"?"]}),f.jsxs(Qi,{className:"text-[11px] leading-4",children:["Starts a detached restart helper, shuts down ",s?"the current node":u,", and brings it back with the configured launcher. The new process will not stay attached to the original terminal window."]})]}),f.jsx(uj,{value:C,onChange:T}),f.jsxs(Gi,{className:"gap-1 pt-0 sm:space-x-1",children:[f.jsx(Zi,{className:hy,children:"Cancel"}),f.jsx(Ki,{className:"h-7 rounded-sm px-2 text-[11px]",onClick:()=>{G()},children:y})]})]})]})]})]}),f.jsxs("div",{className:"border-t border-border/50",children:[f.jsxs("button",{type:"button",onClick:()=>z(ue=>!ue),className:"flex w-full items-center justify-between px-3 py-1.5 text-[10px] text-muted-foreground hover:text-foreground hover:bg-muted/30 transition-colors",children:[f.jsxs("span",{className:"flex items-center gap-1.5",children:[f.jsx(db,{className:"h-3 w-3"}),"Restart details"]}),f.jsx(Pl,{className:ne("h-3 w-3 transition-transform duration-150",U&&"rotate-180")})]}),U&&f.jsxs("div",{className:"border-t border-border/50 bg-muted/20 px-3 py-2 space-y-1",children:[f.jsx(vr,{label:"Current PID",value:h===void 0?"—":String(h),mono:h!==void 0}),f.jsx(vr,{label:"Restart PID",value:S?.pid===void 0?"Pending":String(S.pid),mono:S?.pid!==void 0}),f.jsx(vr,{label:"Operation",value:S?.operationId?Kd(S.operationId):"Local direct request",mono:!!S?.operationId}),f.jsx(vr,{label:"Status",value:S?.status??(E?"requested":"idle")}),f.jsx(vr,{label:"Launcher",value:S?.command??"Available after restart",mono:!!S?.command}),f.jsx(vr,{label:"Log",value:S?.logPath??"Available after restart",mono:!!S?.logPath}),f.jsx(vr,{label:"Terminal",value:"New process is detached from original terminal"})]})]}),p.detail&&f.jsx("div",{className:"border-t border-border/50 px-3 py-1.5 text-[10px] text-muted-foreground bg-muted/20",children:p.detail})]})}function uj({onChange:t,value:r}){const o=(s,c)=>{t({...r,[s]:c})};return f.jsxs("div",{className:"rounded-sm border border-border/70 bg-muted/30 p-3 space-y-3",children:[f.jsx("div",{className:"text-[10px] font-semibold uppercase tracking-[0.16em] text-muted-foreground",children:"Startup arguments"}),f.jsxs("div",{className:"grid gap-2 sm:grid-cols-2",children:[f.jsx(Dl,{label:"HTTP port",value:r.port,onChange:s=>o("port",s),inputMode:"numeric"}),f.jsx(Dl,{label:"Node name",value:r.name,onChange:s=>o("name",s)}),f.jsx(Dl,{label:"Join endpoint",value:r.join,onChange:s=>o("join",s),className:"sm:col-span-2"}),f.jsxs("div",{className:"space-y-1",children:[f.jsx("label",{className:"text-[9px] uppercase tracking-[0.14em] text-muted-foreground",children:"Transport"}),f.jsxs(wf,{value:r.transport,onValueChange:s=>o("transport",k1(s)),children:[f.jsx($i,{className:"h-7 rounded-sm border-border/70 bg-background/70 px-2 text-[10px]",children:f.jsx(Sf,{placeholder:"Transport"})}),f.jsxs(qi,{children:[f.jsx(aa,{className:"py-1 text-[11px]",value:"inherit",children:"current / default"}),f.jsx(aa,{className:"py-1 text-[11px]",value:"direct",children:"direct"}),f.jsx(aa,{className:"py-1 text-[11px]",value:"devtunnel",children:"devtunnel"}),f.jsx(aa,{className:"py-1 text-[11px]",value:"tailscale",children:"tailscale"})]})]})]}),f.jsx(Dl,{label:"Working directory",value:r.workDir,onChange:s=>o("workDir",s)}),f.jsx(Dl,{label:"Config path",value:r.config,onChange:s=>o("config",s),className:"sm:col-span-2"}),f.jsxs("div",{className:"space-y-1 sm:col-span-2",children:[f.jsx("label",{className:"text-[9px] uppercase tracking-[0.14em] text-muted-foreground",children:"GHC tunnel"}),f.jsxs(wf,{value:r.ghcTunnel,onValueChange:s=>o("ghcTunnel",mj(s)),children:[f.jsx($i,{className:"h-7 rounded-sm border-border/70 bg-background/70 px-2 text-[10px]",children:f.jsx(Sf,{placeholder:"GHC tunnel"})}),f.jsxs(qi,{children:[f.jsx(aa,{className:"py-1 text-[11px]",value:"inherit",children:"current / remembered"}),f.jsx(aa,{className:"py-1 text-[11px]",value:"enable",children:"enable"}),f.jsx(aa,{className:"py-1 text-[11px]",value:"disable",children:"disable"})]})]})]}),f.jsxs("label",{className:"flex items-center gap-2 rounded-sm border border-border/60 bg-background/60 px-2 py-1.5 text-[10px] text-foreground sm:col-span-2 cursor-pointer hover:bg-muted/40 transition-colors",children:[f.jsx(N1,{className:"h-3.5 w-3.5",checked:r.disableAuth,onCheckedChange:s=>t({...r,disableAuth:s===!0,disableAuthKnown:!0})}),"Disable auth"]})]})]})}function Dl({className:t,inputMode:r,label:o,onChange:s,value:c}){return f.jsxs("label",{className:ne("space-y-1",t),children:[f.jsx("span",{className:"text-[9px] uppercase tracking-[0.14em] text-muted-foreground",children:o}),f.jsx(gc,{className:"h-7 rounded-sm px-2 text-[10px]",inputMode:r,value:c,onChange:u=>s(u.target.value)})]})}function vr({label:t,value:r,mono:o=!1}){return f.jsxs("div",{className:"flex items-start justify-between gap-3 text-[10px]",children:[f.jsx("span",{className:"shrink-0 uppercase tracking-[0.14em] text-muted-foreground",children:t}),f.jsx("span",{className:ne("break-all text-right text-foreground",o&&"font-mono"),children:r})]})}function dj(t){const r=t.result;if(!r||typeof r!="object")return null;const o=r;return o.ok!==!0||typeof o.command!="string"||typeof o.logPath!="string"?null:{ok:!0,mode:o.mode==="package"?"package":"development",command:o.command,logPath:o.logPath,pid:typeof o.pid=="number"?o.pid:void 0}}function py(t){return{port:hj(t.endpoint),name:t.nodeName,join:"",transport:k1(t.transportType),workDir:t.workDir??"",config:"",disableAuth:t.disableAuthDefault===!0,disableAuthKnown:t.disableAuthDefault!==void 0,ghcTunnel:"inherit"}}function fj(t){const r={},o=Number(t.port.trim());return t.port.trim()&&Number.isInteger(o)&&o>0&&(r.port=o),t.name.trim()&&(r.name=t.name.trim()),t.join.trim()&&(r.join=t.join.trim()),t.transport!=="inherit"&&(r.transport=t.transport),t.workDir.trim()&&(r.workDir=t.workDir.trim()),t.config.trim()&&(r.config=t.config.trim()),t.disableAuthKnown&&(r.disableAuth=t.disableAuth),t.ghcTunnel==="enable"&&(r.ghcTunnel=!0),t.ghcTunnel==="disable"&&(r.ghcTunnel=!1),Object.keys(r).length>0?r:void 0}function k1(t){return t==="direct"||t==="devtunnel"||t==="tailscale"?t:"inherit"}function mj(t){return t==="enable"||t==="disable"?t:"inherit"}function hj(t){if(!t)return"";try{return new URL(t).port||""}catch{return""}}function Kd(t){return t.length<=8?t:t.slice(0,8)}function Ll(t){if(t==null||t==="")return"Unavailable";const r=new Date(t);return Number.isNaN(r.getTime())?"Unavailable":new Intl.DateTimeFormat(void 0,{dateStyle:"medium",timeStyle:"short"}).format(r)}function T3(t){const r=Math.max(0,Math.floor(t)),o=Math.floor(r/86400),s=Math.floor(r%86400/3600),c=Math.floor(r%3600/60);return o>0?`${o}d ${s}h`:s>0?`${s}h ${c}m`:`${c}m`}function N3(t){if(t==null||Number.isNaN(t))return"Unavailable";const r=["B","KB","MB","GB","TB"];let o=t,s=0;for(;o>=1024&&s<r.length-1;)o/=1024,s+=1;return`${o.toFixed(o>=10||s===0?0:1)} ${r[s]}`}function pj(t){return t==="ok"?"default":t==="missing"||t==="install-failed"||t==="login-failed"?"destructive":t==="not-authenticated"||t==="unsupported-platform"?"outline":"secondary"}function gj(t,r){return t?.nodes?.length?t.nodes:r?[r]:[]}function vj(t,r){if(r&&t.id===r.nodeId)return r;const o=t.settingsSnapshot;return{...t,nodeId:t.id,version:o?.version??"Unavailable",packageName:o?.packageName,uptime:o?.uptime??0,defaultTaskAgent:o?.defaultTaskAgent,localDashboardOrigin:o?.runtime?.localDashboardOrigin??void 0,auth:o?.auth,os:o?.os,runtime:o?.runtime,runtimeUpdate:o?.runtimeUpdate,agents:o?.agents,startupRequirements:o?.startupRequirements,components:o?.components,repository:o?.repository,packages:o?.packages}}function yj(t){return t.available?f.jsx("span",{"data-agent-availability":"available","aria-label":"Available",title:"Available",className:"inline-flex h-5 w-5 items-center justify-center text-emerald-500",children:f.jsx(xo,{className:"h-3.5 w-3.5"})}):f.jsx("span",{"data-agent-availability":"unavailable","aria-label":"Unavailable",title:"Unavailable",className:"inline-flex h-5 w-5 items-center justify-center text-destructive",children:f.jsx(sf,{className:"h-3.5 w-3.5"})})}function bj(t){return t.update?t.update.updateAvailable?f.jsxs(xn,{variant:"outline",className:"rounded-sm px-1.5 py-0 text-[10px] uppercase tracking-[0.14em]",children:["Update ",t.update.latestVersion]}):f.jsx(xn,{variant:"secondary",className:"rounded-sm px-1.5 py-0 text-[10px] uppercase tracking-[0.14em]",children:"Up to date"}):null}function xj(t){return t.available?null:t.metadataStatus??null}function wj(t){const r=`npm install -g ${t.update?.packageName}@latest`;return t.id==="claude"?`${r} --include=optional --ignore-scripts=false`:r}function Sj(t){return t.error?t.error:t.result?.detail??null}function Ml({label:t,value:r,mono:o=!1,className:s}){return f.jsxs("div",{className:ne("min-w-0 space-y-0.5",s),children:[f.jsx("div",{className:"text-[9px] uppercase tracking-[0.16em] text-muted-foreground",children:t}),f.jsx("div",{className:ne("truncate text-[11px] text-foreground",o&&"font-mono",t==="Path"&&"break-all whitespace-normal"),children:r})]})}function Ej({agent:t,nodeName:r,activeOperation:o,onUpgrade:s}){const c=t.update?.updateAvailable===!0,u=bj(t),m=!!o,h=xj(t);return f.jsxs("div",{className:"rounded-sm border border-border/60 bg-background/65 px-3 py-2.5 transition-colors hover:bg-background/85",children:[f.jsxs("div",{className:"grid gap-3 lg:grid-cols-[12rem_minmax(0,1fr)_auto] lg:items-start",children:[f.jsxs("div",{className:"min-w-0 space-y-1.5",children:[f.jsxs("div",{className:"flex items-center gap-1.5 text-[12px] font-semibold text-foreground",children:[f.jsx(If,{className:"h-3.5 w-3.5 shrink-0 text-primary"}),f.jsx("span",{className:"truncate",children:t.label})]}),f.jsxs("div",{className:"truncate text-[10px] text-muted-foreground",children:["Command: ",f.jsx("span",{className:"font-mono text-[10px]",children:t.command})]}),f.jsxs("div",{className:"flex flex-wrap items-center gap-1.5",children:[yj(t),h&&f.jsx(xn,{variant:pj(h),className:"rounded-sm px-1.5 py-0 text-[10px] uppercase tracking-[0.14em]",children:h})]})]}),f.jsxs("div",{className:"grid min-w-0 gap-x-4 gap-y-1.5 sm:grid-cols-2",children:[f.jsx(Ml,{label:"Version",value:t.version??"Unavailable",mono:!!t.version}),t.update&&f.jsx(Ml,{label:"Latest",value:t.update.latestVersion??"Unavailable",mono:!!t.update.latestVersion}),f.jsx(Ml,{label:"Checked",value:Ll(t.checkedAt)}),t.update&&f.jsx(Ml,{label:"Update check",value:Ll(t.update.checkedAt)}),f.jsx(Ml,{label:"Path",value:t.path??"Not on PATH",mono:!!t.path,className:"sm:col-span-2"})]}),f.jsx("div",{className:"flex items-start justify-start lg:justify-end",children:o?f.jsxs(xn,{variant:"outline",className:"rounded-sm px-1.5 py-0 text-[10px] uppercase tracking-[0.14em]",children:["Upgrade ",o.status]}):c?f.jsxs(Tf,{children:[f.jsx(Nf,{asChild:!0,children:f.jsx("button",{type:"button",disabled:m,className:"rounded-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/45 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-60",children:u})}),f.jsxs(Ii,{children:[f.jsxs(Yi,{children:[f.jsxs(Xi,{children:["Upgrade ",t.label,"?"]}),f.jsxs(Qi,{children:["This runs ",wj(t)," on ",r,". Remote nodes execute the command on the remote machine."]})]}),f.jsxs(Gi,{children:[f.jsx(Zi,{children:"Cancel"}),f.jsx(Ki,{onClick:()=>s(t),children:"Upgrade"})]})]})]}):u})]}),t.update?.detail&&f.jsx("div",{className:"mt-2 rounded-sm border border-border/60 bg-muted/40 px-2 py-1 text-[10px] text-muted-foreground",children:t.update.detail}),t.detail&&f.jsx("div",{className:"mt-2 rounded-sm border border-border/60 bg-muted/40 px-2 py-1 text-[10px] text-muted-foreground",children:t.detail})]})}function Tj(t){return t==="claude"?"Claude Code":t==="copilot"?"Copilot CLI":"Codex"}function Nj(t){const r=t.payload?.agent;return r==="claude"||r==="codex"||r==="copilot"?r:null}function Cj({node:t}){return f.jsxs("span",{className:"flex min-w-0 flex-1 items-center gap-1.5",children:[f.jsx(d1,{status:t.status,size:"compact",pulse:!1}),f.jsx("span",{className:"min-w-0 flex-1 truncate",children:t.name})]})}function Rj({cluster:t,systemInfo:r,initialSelectedNodeId:o,onRefresh:s}){const c=g.useMemo(()=>gj(t,r),[t,r]),[u,m]=g.useState(()=>o??r?.nodeId??t?.self?.id??""),[h,v]=g.useState(()=>new Map),[p,b]=g.useState("codex"),[y,S]=g.useState(!1),A=g.useRef(new Set),C=g.useRef(new Set),T=t?.self??r??c[0]??null,E=c.find(W=>W.id===u)??T,R=E?vj(E,r):null,k=!!(r&&E&&E.id===r.nodeId),O=k||!!E?.settingsSnapshot,U=R?.runtimeUpdate,z=Cf(R?.defaultTaskAgent),G=g.useMemo(()=>c.map(W=>W.id),[c]),Y=G.join("\0"),q=F_(c),re=g.useMemo(()=>new Map(c.map(W=>[W.id,W.name])),[q]);g.useEffect(()=>{o&&G.includes(o)&&m(o)},[o,Y]),g.useEffect(()=>{b(z)},[E?.id,z]);const fe=g.useCallback(async(W,se)=>{const ee=C1(W);if(!ee||A.current.has(W.id))return;const j=Nj(W),P=se?.agentLabel??(j?Tj(j):"Agent"),H=se?.nodeName??re.get(W.nodeId)??W.nodeId;A.current.add(W.id),v(F=>new Map(F).set(ee,W));try{const F=await R1(W);if(F.status==="succeeded")await s?.(),C.current.has(F.id)||(Ce.success(`${P} upgrade finished on ${H}`),C.current.add(F.id));else if(F.status==="failed")C.current.has(F.id)||(Ce.error(Sj(F)??`${P} upgrade failed`),C.current.add(F.id));else{v(N=>new Map(N).set(ee,F)),Ce.info(`${P} upgrade is still ${F.status} on ${H}`);return}v(N=>{const I=new Map(N),J=I.get(ee);return(!J||J.id===F.id)&&I.delete(ee),I})}catch(F){v(N=>{const I=new Map(N),J=I.get(ee);return(!J||J.id===W.id)&&I.delete(ee),I}),Ce.error(F instanceof Error?F.message:`${P} upgrade failed`)}finally{A.current.delete(W.id)}},[s,re]);g.useEffect(()=>{if(G.length===0)return;let W=!1;async function se(){let ee;try{ee=await ej(G)}catch{return}if(!W){v(j=>{const P=new Map(j);for(const[H,F]of ee)P.set(H,F);return P});for(const j of ee.values())fe(j)}}return se(),()=>{W=!0}},[fe,Y]);async function ue(W){if(E)try{const se=await ZE(E.id,W.id);Ce.info(`${W.label} upgrade started on ${E.name}`),await fe(se,{agentLabel:W.label,nodeName:E.name})}catch(se){Ce.error(se instanceof Error?se.message:`${W.label} upgrade failed`)}}async function de(W){if(!k||W===z)return;const se=p;b(W),S(!0);try{const ee=await XE(W);b(Cf(ee.defaultTaskAgent)),await s?.(),Ce.success("Default agent updated")}catch(ee){b(se),Ce.error(ee instanceof Error?ee.message:"Failed to update default agent")}finally{S(!1)}}return!E||!R?f.jsx("div",{className:"rounded-sm border border-dashed border-border/70 bg-muted/20 px-3 py-5 text-center text-[11px] text-muted-foreground",children:"Loading session metadata..."}):f.jsxs("div",{className:"space-y-2.5 pt-1",children:[!O&&f.jsx("div",{className:"rounded-sm border border-dashed border-border/70 bg-muted/20 px-3 py-2 text-[11px] text-muted-foreground",children:"This node has not synced its settings snapshot to the leader yet. Wait for the next keepalive and reopen the dialog if needed."}),f.jsxs(F5,{defaultValue:"runtime",className:"space-y-2",children:[f.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between",children:[f.jsxs(Ix,{className:"h-auto flex-wrap rounded-sm border border-border/60 bg-muted/40 p-0.5",children:[f.jsx(Ri,{value:"runtime",className:"rounded-sm px-2.5 py-0.5 text-[11px]",children:"Runtime"}),f.jsx(Ri,{value:"quick-chats",className:"rounded-sm px-2.5 py-0.5 text-[11px]",children:"Quick chats"}),f.jsx(Ri,{value:"about",className:"rounded-sm px-2.5 py-0.5 text-[11px]",children:"About"})]}),f.jsxs("div",{className:"flex flex-wrap items-center justify-start gap-1.5 sm:justify-end",children:[!k&&f.jsx(xn,{variant:"outline",title:`Updated ${Ll(E.settingsSnapshot?.collectedAt)}`,className:"rounded-sm border-border/70 bg-background/60 px-1.5 py-0 text-[10px] uppercase tracking-[0.16em] whitespace-nowrap",children:"Leader-synced snapshot"}),f.jsx(h_,{role:E.role,size:"compact"}),c.length>1?f.jsxs(wf,{value:E.id,onValueChange:m,children:[f.jsx($i,{className:"h-7 w-48 rounded-sm border-0 bg-primary/10 px-2 text-left text-[11px] text-foreground !shadow-none hover:bg-primary/15 focus:bg-primary/12 focus:ring-primary/25 [&>span:first-child]:!flex [&>span:first-child]:!min-w-0 [&>span:first-child]:!flex-1 [&>span:first-child]:!items-center",children:f.jsx("span",{className:"flex min-w-0 items-center gap-1.5",children:f.jsx(Sf,{className:"min-w-0 flex-1 truncate",placeholder:"Choose a node"})})}),f.jsx(qi,{className:"settings-node-select-content w-48 rounded-sm border-border/70 bg-popover/96 text-[9px] leading-4 !shadow-none",viewportClassName:"h-auto max-h-56 min-w-0 p-1",children:c.map(W=>f.jsx(aa,{value:W.id,className:"settings-node-select-item py-1 !pl-4 pr-2 text-[9px] leading-4 whitespace-nowrap focus:bg-primary/10 focus:text-foreground [&>span:first-child]:left-0.5 [&>span:first-child]:h-3 [&>span:first-child]:w-3 [&_svg]:h-3 [&_svg]:w-3",children:f.jsx(Cj,{node:W})},W.id))})]}):f.jsxs("span",{className:"flex h-7 items-center gap-1.5 rounded-sm border border-border/70 bg-background/75 px-2 text-[11px] text-muted-foreground",children:[f.jsx(d1,{status:E.status}),f.jsx("span",{className:"font-medium text-foreground",children:E.name})]})]})]}),f.jsxs(Vi,{value:"runtime",className:"mt-0 grid gap-2 xl:grid-cols-2",children:[U&&f.jsx("div",{className:"xl:col-span-2",children:f.jsx(cj,{checkedLabel:Ll(U.checkedAt),disableAuthDefault:R.auth?.enabled===void 0?void 0:R.auth.enabled===!1,endpoint:E.endpoint,isLiveLocalNode:k,nodeId:E.id,nodeName:E.name,onRefresh:s,pid:R.runtime?.pid,transportType:E.transportType,update:U,workDir:R.runtime?.workDir??E.workDir})}),f.jsx(U_,{nodeId:E.id,nodeName:E.name}),f.jsxs($l,{className:"rounded-sm border-border/70 bg-background/75 shadow-none xl:col-span-2",children:[f.jsx(ql,{className:"pb-1.5 pt-2.5 px-3",children:f.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-start sm:justify-between",children:[f.jsxs("div",{className:"min-w-0 space-y-1",children:[f.jsxs(Vl,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(If,{className:"h-3.5 w-3.5 text-primary"}),"Available agents"]}),f.jsx(Il,{className:"text-[10px]",children:k?"Live command availability for runtime agents on this node.":"Most recent agent availability snapshot synced from this node."})]}),f.jsx(B_,{value:y?p:z,disabled:!k,saving:y,onChange:de})]})}),f.jsx(Yl,{"data-agent-layout":"list",className:"space-y-1.5 px-3 pb-2.5",children:(R.agents??[]).map(W=>f.jsx(Ej,{agent:W,nodeName:E.name,activeOperation:h.get(`${E.id}:${W.id}`),onUpgrade:ue},W.id))})]})]}),f.jsx(Vi,{value:"quick-chats",className:"mt-0",children:f.jsx(G_,{})}),f.jsx(v_,{formatDateTime:Ll,viewInfo:R})]})]})}function Aj({initialSelectedNodeId:t,open:r,onOpenChange:o,showTrigger:s=!0}={}){const{cluster:c,systemInfo:u,refresh:m}=nb();return f.jsx(PA,{open:r,onOpenChange:o,showTrigger:s,children:f.jsx(Rj,{cluster:c,systemInfo:u,initialSelectedNodeId:t,onRefresh:m})})}const Wi="meshy:show-live-events";function _1(){const t=globalThis.window;if(!t)return;const r=typeof t.CustomEvent=="function"?new t.CustomEvent(Wi):new t.Event(Wi);t.dispatchEvent(r)}function C3(t){const r=globalThis.window;return r?(r.addEventListener(Wi,t),()=>r.removeEventListener(Wi,t)):()=>{}}const kj={node:"border-teal-500/30 bg-teal-500/10 text-teal-700 dark:text-teal-300",task:"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300",election:"border-indigo-500/30 bg-indigo-500/10 text-indigo-700 dark:text-indigo-300",cluster:"border-emerald-500/30 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300",transport:"border-sky-500/30 bg-sky-500/10 text-sky-700 dark:text-sky-300"},_j={node:"text-teal-700/70 dark:text-teal-300/70",task:"text-amber-700/70 dark:text-amber-300/70",election:"text-indigo-700/70 dark:text-indigo-300/70",cluster:"text-emerald-700/70 dark:text-emerald-300/70",transport:"text-sky-700/70 dark:text-sky-300/70"};function jj(t){return t.split(".")[0]??"unknown"}function Oj(t){return new Date(t).toLocaleTimeString("en-US",{hour12:!1})}function yo(t,r,o){return typeof o=="string"&&o.length>0?o:r?.get(t)??t}function j1(t,r){const o=t.data,s=o.operation;switch(t.type){case"node.joined":return`${o.name} joined the cluster`;case"node.left":return`${yo(o.nodeId,r,o.name)} left (${o.reason})`;case"node.status":return`${yo(o.nodeId,r)} is now ${o.status}`;case"node.operation.created":return`${s?.kind} ${s?.status} on ${yo(s?.nodeId,r)}`;case"node.operation.updated":return`${s?.kind} ${s?.status} on ${yo(s?.nodeId,r)}`;case"transport.changed":return`${yo(o.nodeId,r)} transport switched to ${o.transportType}`;case"task.created":return`"${o.title}" created`;case"task.assigned":return`task assigned to ${yo(o.nodeId,r)}`;case"task.status":return`task ${o.taskId.slice(0,8)} -> ${o.status}`;case"election.started":return`candidate ${o.candidateId.slice(0,8)} term ${o.term}`;case"election.complete":return`leader elected, term ${o.term}`;case"cluster.state":return`${o.nodeCount} nodes, term ${o.term}`;default:return JSON.stringify(o)}}function Dj(t){return JSON.stringify(t,null,2)}function Mj({events:t,maxHeight:r="400px",nodeNameById:o,onDismiss:s,onSelect:c,density:u="default"}){if(t.length===0)return null;const m=u==="compact";return f.jsx("div",{className:"overflow-y-auto pr-1",style:{maxHeight:r},children:f.jsx("div",{className:"space-y-1.5",children:t.map(h=>{const v=jj(h.type);return f.jsx("div",{onClick:c?()=>c(h.id):void 0,onKeyDown:c?p=>{p.target===p.currentTarget&&(p.key!=="Enter"&&p.key!==" "||(p.preventDefault(),c(h.id)))}:void 0,"data-click-open-live-events":c?"true":void 0,role:c?"button":void 0,tabIndex:c?0:void 0,title:c?"Open in Live events":void 0,className:ne("transition-colors hover:bg-muted/30",c&&"cursor-pointer",m?"rounded-sm px-1 py-0.5":"rounded-sm px-1.5 py-1"),children:f.jsxs("div",{className:"space-y-1",children:[f.jsxs("div",{className:"flex items-start justify-between gap-1.5",children:[f.jsxs("div",{className:"flex flex-wrap items-center gap-1.5",children:[f.jsx("div",{className:ne("font-mono text-muted-foreground",m?"text-[8px]":"text-[9px]"),children:Oj(h.timestamp)}),m?f.jsx("span",{className:ne("max-w-[8.5rem] truncate text-[7px] font-medium uppercase tracking-[0.08em] text-muted-foreground/70",_j[v]),children:h.type}):f.jsx(xn,{variant:"outline",className:ne("w-fit text-[9px] font-medium uppercase tracking-[0.14em] px-1.5 py-0",kj[v]),children:h.type})]}),f.jsxs("div",{className:ne("flex shrink-0 items-center",m?"gap-px":"gap-0.5"),children:[f.jsx(Nt,{type:"button",variant:"ghost",size:"icon",className:ne("rounded-sm text-muted-foreground hover:text-foreground",m?"h-3.5 w-3.5 p-0 opacity-65 hover:bg-muted/40 hover:opacity-100 [&_svg]:size-2.5":"h-5 w-5"),onClick:p=>{p.stopPropagation(),p1(Dj(h),"Event copied")},"aria-label":`Copy ${h.type} event`,title:"Copy event",children:f.jsx(rb,{className:m?"h-2.5 w-2.5":"h-3 w-3"})}),s&&f.jsx(Nt,{type:"button",variant:"ghost",size:"icon",className:ne("rounded-sm text-muted-foreground hover:text-foreground",m?"h-3.5 w-3.5 p-0 opacity-65 hover:bg-muted/40 hover:opacity-100 [&_svg]:size-2.5":"h-5 w-5"),onClick:p=>{p.stopPropagation(),s(h.id)},"aria-label":`Dismiss ${h.type} event`,title:"Dismiss event",children:f.jsx(Yf,{className:m?"h-2.5 w-2.5":"h-3 w-3"})})]})]}),f.jsx("div",{className:"text-[9px] leading-snug text-foreground/85",children:j1(h,o)})]})},h.id)})})})}function O1(t){return t!==null}function D1(t){return t==="click"?t:"hover"}function kf(t){return t==="hover"?null:t}function M1(t){return t==="click"?null:"click"}const zj=["node.","election.","transport."],Lj="cluster.state";function Uj(t){return t.type==="node.status"?!1:zj.some(r=>t.type.startsWith(r))}function Bj(t){return new Date(t).toLocaleTimeString("en-US",{hour12:!1})}function Hj(t,r){return t?{time:Bj(t.timestamp),text:j1(t,r)}:null}function Pj(t){return t.transportType==="devtunnel"||!!t.devtunnelEndpoint}function $j(t){if(t.length===0)return"No node tunnel";const r=t.filter(c=>c.status==="offline").length;if(r>0)return`${r} offline`;const o=t.filter(c=>c.devtunnelHealth?.status==="failed").length;if(o>0)return`${o} failed`;const s=t.filter(c=>c.status!=="offline"&&c.devtunnelHealth?.status!=="healthy").length;return s>0?`${s} checking`:"Healthy"}function qj(t,r){const o=r?.get(t.id)??t.name??t.id;if(t.status==="offline")return{label:o,status:"offline"};const s=t.devtunnelHealth?.status??"checking";return{label:o,status:s}}function Vj(t){if(t.length===0)return"No nodes";const r=t.filter(s=>s.status==="offline").length;if(r>0)return`${r} offline`;const o=t.filter(s=>s.status==="busy").length;return o>0?`${o} busy`:"Healthy"}function Ij(t,r){return{label:r?.get(t.id)??t.name??t.id,status:t.status}}function Yj({connected:t,events:r,nodes:o=[],currentNode:s=null,nodeNameById:c,desktopUpdate:u=null,desktopUpdateCheckPending:m=!1,desktopUpdateProgress:h=null,defaultOpen:v=!1,defaultActionMenuOpen:p=!1,onDesktopUpdateCheck:b,onDesktopUpdate:y,onDesktopRestart:S,onReload:A,onRestart:C}){const[T,E]=g.useState(v?"click":null),[R,k]=g.useState(p),[O,U]=g.useState(!0),[z,G]=g.useState(new Set),[Y,q]=g.useState(!1),[re,fe]=g.useState(!1),ue=O1(T),de=g.useRef(null),W=g.useRef(null),se=g.useMemo(()=>r.filter(be=>Uj(be)&&!z.has(be.id)),[r,z]),ee=g.useMemo(()=>r.find(be=>be.type===Lj)??se[0],[r,se]),j=g.useMemo(()=>Hj(ee,c),[ee,c]),P=g.useMemo(()=>{const be=new Map(o.map(Xe=>[Xe.id,Xe]));return s&&be.set(s.id,s),Array.from(be.values())},[s,o]),H=g.useMemo(()=>P.filter(Pj),[P]),F=H.some(be=>be.status==="offline"||be.devtunnelHealth?.status==="failed"),N=P.some(be=>be.status==="offline"),I=P.some(be=>be.status==="busy"),J=P.length>0,Q=s?.name??"offline",le=s?.role==="leader"?"Leader":s?.role==="follower"?"Follower":"Node",te=u!==null,ae=!!(te&&u?.updateAvailable&&u.latestVersion),ie=u?.latestVersion??null,ce=!!(te&&!ae&&ie),xe=!!(te&&u?.detail==="Checking desktop update..."),Re=!!(te&&!ae&&!ie&&u?.detail&&!xe),Te=h?.percent??null,Ae=Te===null?null:`${Te}%`,Je=Y?"Relaunching runtime...":"Relaunch to apply update",at=Ae?`Downloading ${Ae}`:re?"Downloading and installing desktop update...":ae&&ie?`Available version ${ie}`:Re?u?.detail??"Desktop update unavailable":"Desktop is current",dn=!!A,fn=!!(te&&S),Qa=!!(te&&b)||dn||fn,ht=te||!!C,Nr=te||!!C||dn,Un=ht?te?ae?"Update":ce?"Latest":"Check":"Relaunch":"Reload",st=te&&!ae,mn=st?"Check":Un,Cr=ht?te?at:Je:"Reload dashboard page",ca=ht?te?re||h!==null:Y:!1,$t=ht?te?ca||!ae||!y:ca:!1,Ct=m||re||!b,Mt=te?ae&&ie?`Install desktop update ${ie}`:Re?"Desktop update unavailable":"Desktop is current":ht?Y?"Relaunching runtime":"Relaunch runtime":"Reload dashboard page";function We(){W.current&&(clearTimeout(W.current),W.current=null)}function Nn(){We(),E(be=>D1(be))}function Rr(){We(),W.current=setTimeout(()=>{E(be=>kf(be)),W.current=null},180)}function Cn(){We()}function ua(){We(),E(be=>kf(be))}async function da(){if(!(!C||Y)){q(!0);try{await C()}finally{q(!1)}}}async function Jt(){if(!(!ae||!y||re)){fe(!0);try{await y()}finally{fe(!1)}}}async function Bn(){!b||m||re||await b()}async function Hn(){if(!(!S||Y)){k(!1),q(!0);try{await S()}finally{q(!1)}}}async function fa(){if(!ht){await zt();return}if(te){await Jt();return}await da()}async function zt(){A&&(k(!1),await A())}function Ka(){G(be=>{const Xe=new Set(be);return se.forEach(me=>Xe.add(me.id)),Xe})}function Za(){_1(),E(null)}return g.useEffect(()=>()=>{We()},[]),g.useEffect(()=>{G(be=>{if(be.size===0)return be;const Xe=new Set(r.map(He=>He.id)),me=new Set(Array.from(be).filter(He=>Xe.has(He)));return me.size===be.size?be:me})},[r]),g.useEffect(()=>{ue||k(!1)},[ue]),g.useEffect(()=>{if(!ue)return;const be=me=>{de.current?.contains(me.target)||(We(),k(!1),E(null))},Xe=me=>{me.key==="Escape"&&(We(),k(!1),E(null))};return document.addEventListener("pointerdown",be),document.addEventListener("keydown",Xe),()=>{document.removeEventListener("pointerdown",be),document.removeEventListener("keydown",Xe)}},[ue]),f.jsxs("div",{ref:de,className:"relative",children:[f.jsxs("button",{type:"button","aria-label":t?"Cluster link connected":"Cluster link reconnecting","aria-expanded":ue,"aria-haspopup":"dialog",onClick:()=>E(be=>M1(be)),onMouseEnter:Nn,onMouseLeave:Rr,className:ne("flex h-8 max-w-[18rem] items-center gap-1.5 rounded-sm px-2 text-[10px] transition-all sm:gap-2 sm:px-2.5 sm:text-[11px]",t?"bg-muted/40 text-muted-foreground hover:bg-muted/60 hover:text-foreground":"bg-destructive/8 text-destructive hover:bg-destructive/12",ue&&(t?"bg-muted/60 text-foreground":"bg-destructive/12")),title:t?"Cluster link connected":"Cluster link reconnecting",children:[f.jsxs("span",{className:ne("relative flex h-2 w-2 shrink-0"),children:[t&&f.jsx("span",{className:"absolute inline-flex h-full w-full animate-ping rounded-full bg-emerald-400 opacity-60"}),f.jsx("span",{className:ne("relative inline-flex h-2 w-2 rounded-full",t?"bg-emerald-500":"bg-destructive")})]}),f.jsxs("span",{className:"hidden min-w-0 items-center gap-2 sm:flex",children:[f.jsx("span",{className:"truncate font-medium text-foreground",children:Q}),f.jsx("span",{className:ne("shrink-0 rounded border px-1 py-px text-[8px] font-semibold uppercase tracking-[0.1em]",t?"border-emerald-500/25 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300":"border-destructive/30 bg-destructive/10 text-destructive"),children:le})]})]}),ue&&f.jsxs("div",{role:"dialog","aria-label":"Live link connection events",onMouseEnter:Cn,onMouseLeave:ua,className:"absolute right-0 top-[calc(100%+0.35rem)] z-50 w-[17rem] max-w-[calc(100vw-1.5rem)] overflow-hidden rounded-sm border border-border/60 bg-popover/98 shadow-[0_16px_44px_-34px_rgba(0,0,0,var(--panel-shadow-alpha))] backdrop-blur-sm max-sm:fixed max-sm:right-3 max-sm:top-[3.75rem] max-sm:w-[calc(100vw-1.5rem)]",children:[f.jsx("div",{className:"border-b border-border/60 bg-muted/25 px-2.5 py-1.5",children:f.jsxs("div",{className:"flex items-center justify-between gap-2",children:[f.jsxs("div",{className:"flex items-center gap-1.5",children:[t?f.jsx(of,{className:"h-3 w-3 text-emerald-500"}):f.jsx(ON,{className:"h-3 w-3 text-destructive"}),f.jsx("span",{className:"text-[10px] font-semibold text-foreground",children:"Live link"}),f.jsx("span",{className:"text-[9px] text-muted-foreground",children:t?"· SSE connected":"· reconnecting"})]}),f.jsx("div",{className:ne("rounded-sm border px-1.5 py-0.5 text-[8px] font-medium uppercase tracking-[0.12em]",t?"border-emerald-500/30 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300":"border-destructive/30 bg-destructive/10 text-destructive"),children:t?"Connected":"Retrying"})]})}),f.jsxs("div",{className:"grid grid-cols-2 border-b border-border/60",children:[f.jsxs("div",{className:"border-r border-border/60 px-2.5 py-1.5",children:[f.jsx("div",{className:"text-[8px] font-medium uppercase tracking-[0.14em] text-muted-foreground",children:"Events"}),f.jsx("div",{className:"mt-0.5 text-base font-semibold tracking-tight text-foreground",children:se.length})]}),f.jsxs("div",{className:"min-w-0 px-2.5 py-1.5",children:[f.jsx("div",{className:"text-[8px] font-medium uppercase tracking-[0.14em] text-muted-foreground",children:"Latest"}),j?f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"mt-0.5 truncate text-[9px] leading-snug text-foreground/80",children:j.text}),f.jsx("div",{className:"font-mono text-[8px] text-muted-foreground/60",children:j.time})]}):f.jsx("div",{className:"mt-0.5 text-[8px] text-muted-foreground/50",children:"—"})]})]}),f.jsxs("div",{className:"border-b border-border/60 px-2.5 py-1.5",children:[f.jsxs("div",{className:"flex items-center justify-between gap-2",children:[f.jsxs("div",{className:"flex min-w-0 items-center gap-1",children:[N?f.jsx(di,{className:"h-3 w-3 shrink-0 text-destructive"}):I?f.jsx(of,{className:"h-3 w-3 shrink-0 text-amber-500"}):f.jsx(xo,{className:ne("h-3 w-3 shrink-0",J?"text-emerald-500":"text-muted-foreground")}),f.jsx("span",{className:"text-[9px] font-medium uppercase tracking-[0.14em] text-muted-foreground",children:"Node health"})]}),f.jsx("span",{className:ne("shrink-0 rounded-sm border px-1.5 py-0.5 text-[8px] font-medium uppercase tracking-[0.1em]",N?"border-destructive/30 bg-destructive/10 text-destructive":I?"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300":J?"border-emerald-500/30 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300":"border-border/70 bg-background/60 text-muted-foreground"),children:Vj(P)})]}),P.length>0&&f.jsx("div",{className:"mt-1.5 flex flex-col gap-0.5",children:P.map(be=>{const{label:Xe,status:me}=Ij(be,c),He=me==="offline",Qe=me==="busy";return f.jsxs("div",{"aria-label":`${Xe} ${me}`,className:ne("flex items-center justify-between gap-2 rounded-sm px-2 py-0.5",He?"bg-destructive/6":Qe?"bg-amber-500/6":"bg-emerald-500/5"),title:`${Xe} ${me}`,children:[f.jsx("span",{className:"truncate text-[9px] text-foreground/70",children:Xe}),He?f.jsx(di,{className:"h-3 w-3 shrink-0 text-destructive"}):Qe?f.jsx(Av,{className:"h-3 w-3 shrink-0 text-amber-500"}):f.jsx(xo,{className:"h-3 w-3 shrink-0 text-emerald-500"})]},be.id)})})]}),H.length>0&&f.jsxs("div",{className:"border-b border-border/60 px-2.5 py-1.5",children:[f.jsxs("div",{className:"flex items-center justify-between gap-2",children:[f.jsxs("div",{className:"flex min-w-0 items-center gap-1",children:[F?f.jsx(di,{className:"h-3 w-3 shrink-0 text-destructive"}):f.jsx(xo,{className:"h-3 w-3 shrink-0 text-emerald-500"}),f.jsx("span",{className:"text-[9px] font-medium uppercase tracking-[0.14em] text-muted-foreground",children:"DevTunnel"})]}),f.jsx("span",{className:ne("shrink-0 rounded-sm border px-1.5 py-0.5 text-[8px] font-medium uppercase tracking-[0.1em]",F?"border-destructive/30 bg-destructive/10 text-destructive":"border-emerald-500/30 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300"),children:$j(H)})]}),f.jsx("div",{className:"mt-1.5 flex flex-col gap-0.5",children:H.map(be=>{const{label:Xe,status:me}=qj(be,c),He=me==="failed"||me==="offline",Qe=me!=="healthy"&&me!=="failed"&&me!=="offline",pt=be.devtunnelHealth?.reason?`${Xe} ${me}: ${be.devtunnelHealth.reason}`:`${Xe} ${me}`;return f.jsxs("div",{"aria-label":`${Xe} ${me}`,className:ne("flex items-center justify-between gap-2 rounded-sm px-2 py-0.5",He?"bg-destructive/6":Qe?"bg-muted/30":"bg-emerald-500/5"),title:pt,children:[f.jsx("span",{className:"truncate text-[9px] text-foreground/70",children:Xe}),He?f.jsx(di,{className:"h-3 w-3 shrink-0 text-destructive"}):Qe?f.jsx(Av,{className:"h-3 w-3 shrink-0 text-muted-foreground"}):f.jsx(xo,{className:"h-3 w-3 shrink-0 text-emerald-500"})]},be.id)})})]}),f.jsxs("div",{children:[f.jsxs("div",{className:"flex items-center gap-1 px-2 py-1",children:[f.jsxs("button",{type:"button",onClick:()=>U(be=>!be),className:"flex min-w-0 flex-1 items-center justify-between rounded-sm px-0.5 py-0.5 text-left hover:bg-muted/25",children:[f.jsxs("span",{className:"truncate text-[8px] font-medium uppercase tracking-[0.14em] text-muted-foreground",children:["Notifications ",se.length>0&&`(${se.length})`]}),O?f.jsx(Pl,{className:"h-3 w-3 shrink-0 text-muted-foreground"}):f.jsx(lf,{className:"h-3 w-3 shrink-0 text-muted-foreground"})]}),!O&&se.length>0&&f.jsx(Nt,{type:"button",variant:"ghost",size:"sm",className:"h-5 rounded-sm px-1.5 text-[9px] font-medium text-muted-foreground hover:text-foreground",onClick:Ka,title:"Clear all notifications",children:"Clear all"})]}),O&&f.jsx("div",{className:"px-2 pb-1.5",children:f.jsx(Mj,{events:se,maxHeight:"10rem",density:"compact",emptyTitle:"No connection events yet",emptyDescription:"Node, election, and system events will appear here.",nodeNameById:c,onSelect:Za,onDismiss:be=>G(Xe=>new Set(Xe).add(be))})})]}),te&&u?.detail&&!xe&&f.jsxs("div",{className:"flex items-center gap-1.5 border-t border-border/60 px-2.5 py-1 text-[8px] text-muted-foreground",children:[f.jsx("span",{className:"shrink-0 font-medium uppercase tracking-[0.12em]",children:"Desktop update"}),f.jsx("span",{className:"truncate",title:u.detail,children:u.detail})]}),f.jsxs("div",{className:"flex items-center justify-between gap-1 border-t border-border/60 px-2.5 py-1",children:[f.jsx("div",{children:Nr&&f.jsxs("div",{className:"group/restart relative flex items-center",children:[f.jsxs("div",{className:"flex items-center overflow-hidden rounded-sm border border-border/50",children:[f.jsxs(Nt,{type:"button",variant:"ghost",size:"sm",className:ne("relative h-5 overflow-hidden rounded-none border-0 px-1.5 text-[9px] font-medium hover:text-foreground [&_svg]:size-2.5",ae?"bg-primary/12 text-primary hover:bg-primary/18":"bg-background/45 text-muted-foreground hover:bg-emerald-500/10"),onClick:()=>{fa()},disabled:$t,"aria-label":Mt,"aria-describedby":"live-link-restart-hint",title:Cr,children:[Te!==null&&f.jsx("span",{role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":Te,className:"pointer-events-none absolute inset-y-0 left-0 bg-primary/24",style:{width:`${Te}%`}}),Te===null&&f.jsx(kv,{className:ne("relative z-10 h-2.5 w-2.5",ca&&"animate-pulse")}),f.jsx("span",{className:"relative z-10",children:Ae??Un})]}),Qa&&f.jsx(Nt,{type:"button",variant:"ghost",size:"sm",className:ne("h-5 rounded-none border-l border-border/50 px-1 text-[9px] hover:text-foreground [&_svg]:size-2.5",ae?"bg-primary/12 text-primary hover:bg-primary/18":"bg-background/45 text-muted-foreground hover:bg-emerald-500/10"),onClick:()=>k(be=>!be),"aria-label":"Open live link actions","aria-expanded":R,title:"Live link actions",children:f.jsx(Pl,{className:"h-2.5 w-2.5"})})]}),Qa&&R&&f.jsxs("div",{className:"absolute bottom-[calc(100%+0.25rem)] left-0 z-20 min-w-28 overflow-hidden rounded-sm border border-border/70 bg-background text-[9px] shadow-sm",children:[f.jsxs("button",{type:"button",className:"flex w-full items-center gap-1.5 px-2 py-1 text-left text-muted-foreground hover:bg-muted/55 hover:text-foreground disabled:opacity-45 disabled:hover:bg-transparent disabled:hover:text-muted-foreground",onClick:()=>{st?Bn():fa()},disabled:st?Ct:$t,"aria-label":st?"Check for desktop updates":Mt,children:[st?f.jsx(Ei,{className:ne("h-2.5 w-2.5",m&&"animate-spin")}):f.jsx(kv,{className:ne("h-2.5 w-2.5",ca&&"animate-pulse")}),f.jsx("span",{children:mn})]}),dn&&f.jsxs("button",{type:"button",className:"flex w-full items-center gap-1.5 border-t border-border/50 px-2 py-1 text-left text-muted-foreground hover:bg-muted/55 hover:text-foreground disabled:opacity-45 disabled:hover:bg-transparent disabled:hover:text-muted-foreground",onClick:()=>{zt()},"aria-label":"Reload dashboard page",children:[f.jsx(Ei,{className:"h-2.5 w-2.5"}),f.jsx("span",{children:"Reload"})]}),fn&&f.jsxs("button",{type:"button",className:"flex w-full items-center gap-1.5 border-t border-border/50 px-2 py-1 text-left text-muted-foreground hover:bg-muted/55 hover:text-foreground",onClick:()=>{Hn()},disabled:Y,"aria-label":"Restart Meshy Desktop",children:[f.jsx(Ei,{className:ne("h-2.5 w-2.5",Y&&"animate-spin")}),f.jsx("span",{children:"Restart"})]})]}),f.jsx("span",{id:"live-link-restart-hint",role:"tooltip",className:"pointer-events-none absolute left-6 top-1/2 z-10 -translate-y-1/2 whitespace-nowrap rounded-sm border border-border/70 bg-background px-1.5 py-0.5 text-[8px] text-muted-foreground opacity-0 shadow-sm transition-opacity group-hover/restart:opacity-100 group-focus-within/restart:opacity-100",children:Cr})]})}),f.jsxs("div",{className:"flex items-center gap-1",children:[O&&f.jsx(Nt,{type:"button",variant:"ghost",size:"sm",className:"h-5 rounded-sm px-1.5 text-[9px]",onClick:Ka,disabled:se.length===0,title:"Clear all notifications",children:"Clear all"}),f.jsx(Nt,{type:"button",variant:"ghost",size:"sm",className:"h-5 rounded-sm px-1.5 text-[9px]",onClick:()=>E(null),children:"Close"})]})]})]})]})}const gy="dark",Er="fluent",Gj="clean",Zd="meshy-layout-default-migrated-to-compact",_f="true",Xj="compact",Qj=new Set(["airy","clean","fluent"]);function Kj(t){return t!==null&&Qj.has(t)}function yc(t){return t===Xj?"fluent":Kj(t)?t:null}function Zj(t,r){const o=yc(t);return o===Gj&&r!==_f?Er:o??Er}const Ji="symphony",z1="default",Fj=new Set(["light","dark","system"]),Wj=new Set(["porcelain","warm","finsight","edge","symphony","launcher"]),L1=g.createContext(null);function Jj(t){const r=new URLSearchParams(t).get("theme");return U1(r)?r:null}function eO(t){const r=new URLSearchParams(t).get("palette");return xm(r)}function tO(t){const r=new URLSearchParams(t).get("layout");return yc(r)}function nO(){if(typeof document>"u")return null;const t=document.documentElement;return{theme:t.classList.contains("dark")?"dark":"light",palette:xm(t.getAttribute("data-palette"))??Ji,layout:yc(t.getAttribute("data-layout"))??Er}}function R3(t,r=nO()){if(!r)return t;try{const o=/^[a-z][a-z\d+\-.]*:/i.test(t),s=typeof window<"u"?window.location.href:"http://localhost",c=new URL(t,s);return c.searchParams.set("theme",r.theme),c.searchParams.set("palette",r.palette),c.searchParams.set("layout",r.layout),o?c.toString():`${c.pathname}${c.search}${c.hash}`}catch{return t}}const Fd=.9;function vy(t){const r=t.trim().match(/^(-?\d+(?:\.\d+)?)\s+(-?\d+(?:\.\d+)?)%\s+(-?\d+(?:\.\d+)?)%$/);if(!r)return null;const o=(Number(r[1])%360+360)%360/60,s=ec(Number(r[2])/100,0,1),c=ec(Number(r[3])/100,0,1),u=(1-Math.abs(2*c-1))*s,m=u*(1-Math.abs(o%2-1)),h=c-u/2,[v,p,b]=o<1?[u,m,0]:o<2?[m,u,0]:o<3?[0,u,m]:o<4?[0,m,u]:o<5?[m,0,u]:[u,0,m];return[Math.round((v+h)*255),Math.round((p+h)*255),Math.round((b+h)*255),255]}function aO(t){const r=t.trim();if(!r||r==="transparent")return null;const o=r.match(/^rgba?\(\s*([+-]?\d+(?:\.\d+)?)\s*,\s*([+-]?\d+(?:\.\d+)?)\s*,\s*([+-]?\d+(?:\.\d+)?)(?:\s*,\s*([+-]?\d+(?:\.\d+)?))?\s*\)$/i);if(o)return[bo(Number(o[1])),bo(Number(o[2])),bo(Number(o[3])),xy(o[4])];const s=r.match(/^rgba?\(\s*([+-]?\d+(?:\.\d+)?)\s+([+-]?\d+(?:\.\d+)?)\s+([+-]?\d+(?:\.\d+)?)(?:\s*\/\s*([+-]?\d+(?:\.\d+)?%?))?\s*\)$/i);return s?[bo(Number(s[1])),bo(Number(s[2])),bo(Number(s[3])),xy(s[4])]:null}function rO(t,r,o){const s=vy(t);if(!s)return null;if(o==="clean"||o==="fluent")return s;const c=vy(r);return c?[Wd(s[0],c[0],Fd),Wd(s[1],c[1],Fd),Wd(s[2],c[2],Fd),255]:null}function oO(){const t=document.querySelector(".dashboard-shell-header-panel");if(!t)return null;const r=aO(getComputedStyle(t).backgroundColor);return!r||r[3]===0?null:r}function yy(){if(typeof window>"u"||typeof document>"u")return;const t=window.__TAURI__?.core?.invoke??null;if(!t)return;const r=document.documentElement,o=r.classList.contains("dark")?"dark":"light",s=getComputedStyle(r),c=yc(r.getAttribute("data-layout"))??Er,u=oO()??rO(s.getPropertyValue("--card"),s.getPropertyValue("--background"),c);t("sync_desktop_theme",{theme:o,backgroundColor:u}).catch(()=>{})}function by(){if(typeof window>"u")return()=>{};if(yy(),typeof window.requestAnimationFrame!="function")return()=>{};const t=window.requestAnimationFrame(()=>yy());return()=>window.cancelAnimationFrame(t)}function Wd(t,r,o){return Math.round(t*o+r*(1-o))}function ec(t,r,o){return Math.min(Math.max(t,r),o)}function bo(t){return Math.round(ec(t,0,255))}function xy(t){if(t==null||t==="")return 255;const r=t.endsWith("%")?Number(t.slice(0,-1))/100:Number(t);return Math.round(ec(r,0,1)*255)}function lO({children:t}){const[r,o]=g.useState(()=>typeof window<"u"?Jj(window.location.search)??cO(localStorage.getItem("meshy-theme"))??gy:gy),[s,c]=g.useState(()=>typeof window<"u"?eO(window.location.search)??uO(localStorage.getItem("meshy-palette"))??Ji:Ji),[u,m]=g.useState(()=>{if(typeof window<"u"){const h=tO(window.location.search);if(h)return localStorage.setItem(Zd,_f),h;const v=Zj(localStorage.getItem("meshy-layout"),localStorage.getItem(Zd));return localStorage.setItem(Zd,_f),v}return Er});return g.useEffect(()=>{const h=document.documentElement,v=p=>{if(p==="system"){const b=window.matchMedia("(prefers-color-scheme: dark)").matches;h.classList.toggle("dark",b)}else h.classList.toggle("dark",p==="dark")};if(v(r),localStorage.setItem("meshy-theme",r),r==="system"){const p=window.matchMedia("(prefers-color-scheme: dark)"),b=()=>{v("system"),by()};return p.addEventListener("change",b),()=>p.removeEventListener("change",b)}},[r]),g.useEffect(()=>{document.documentElement.setAttribute("data-palette",s),localStorage.setItem("meshy-palette",s)},[s]),g.useEffect(()=>{const h=document.documentElement;u===Er?h.removeAttribute("data-layout"):h.setAttribute("data-layout",u),localStorage.setItem("meshy-layout",u)},[u]),g.useEffect(()=>by(),[r,s,u]),f.jsx(L1.Provider,{value:{theme:r,setTheme:o,palette:s,setPalette:c,layout:u,setLayout:m},children:t})}function sO(){const t=g.useContext(L1);if(!t)throw new Error("useTheme must be used within ThemeProvider");return t}function U1(t){return t!==null&&Fj.has(t)}function iO(t){return t!==null&&Wj.has(t)}function cO(t){return U1(t)?t:null}function xm(t){return t===z1?"porcelain":iO(t)?t:null}function uO(t){return t===z1?null:xm(t)}const dO=[{value:"light",label:"Light",icon:ub},{value:"dark",label:"Dark",icon:cb},{value:"system",label:"System",icon:ib}],B1=[{value:"finsight",label:"FinSight",hint:"Cool sage green"},{value:"porcelain",label:"Porcelain",hint:"Blue workspace"},{value:"warm",label:"Warm",hint:"Cream + amber"},{value:"edge",label:"Edge",hint:"Rounded violet panels"},{value:"symphony",label:"Symphony",hint:"Near-black rose accent"},{value:"launcher",label:"Launcher",hint:"Desktop startup blue"}],H1=[{value:"airy",label:"Airy",hint:"Gradients, blur, spacious"},{value:"clean",label:"Clean",hint:"Flat, borders, high density"},{value:"fluent",label:"Fluent",hint:"Compact neutral"}];function fO(){const{theme:t,setTheme:r,palette:o,setPalette:s,layout:c,setLayout:u}=sO(),[m,h]=g.useState(null),v=g.useRef(null),p=g.useRef(null),b=O1(m),y=t==="dark"?cb:t==="light"?ub:ib,S=()=>{v.current&&(clearTimeout(v.current),v.current=null)},A=()=>{S(),v.current=setTimeout(()=>h(C=>kf(C)),180)};return g.useEffect(()=>{if(!b)return;const C=T=>{p.current&&!p.current.contains(T.target)&&h(null)};return document.addEventListener("mousedown",C),()=>document.removeEventListener("mousedown",C)},[b]),g.useEffect(()=>()=>S(),[]),f.jsxs("div",{ref:p,className:"relative",onMouseEnter:()=>{S(),h(C=>D1(C))},onMouseLeave:A,children:[f.jsx(Nt,{variant:"ghost",size:"icon",onClick:()=>h(C=>M1(C)),className:ne("h-8 w-8 rounded-sm",o!==Ji||c!==Er?"text-primary":"text-muted-foreground hover:bg-muted/50 hover:text-foreground"),title:"Appearance","aria-haspopup":"menu","aria-expanded":b,children:f.jsx(y,{className:"h-4 w-4"})}),b&&f.jsxs("div",{role:"menu",className:"fixed left-2 right-2 top-[4.25rem] z-50 w-auto max-w-none rounded-md border border-border/70 bg-popover/95 p-2 text-popover-foreground shadow-[0_24px_70px_-32px_rgba(0,0,0,0.45)] backdrop-blur-xl sm:absolute sm:left-auto sm:right-0 sm:top-[calc(100%+6px)] sm:w-[23rem] sm:max-w-[23rem]",children:[f.jsxs("div",{className:"mb-2 flex items-end justify-between gap-2",children:[f.jsxs("div",{children:[f.jsx("div",{className:"text-[8px] font-semibold uppercase tracking-[0.18em] text-muted-foreground",children:"Appearance"}),f.jsxs("div",{className:"text-[10px] font-medium text-foreground",children:[mO(c)," / ",hO(o)]})]}),f.jsx("div",{className:"rounded-sm border border-border/60 bg-background/70 px-1.5 py-0.5 text-[8px] font-medium capitalize text-muted-foreground",children:t})]}),f.jsx("div",{className:"px-0.5 pb-1 text-[8px] font-semibold uppercase tracking-[0.18em] text-muted-foreground",children:"Theme"}),f.jsx("div",{className:"mb-2 grid grid-cols-3 gap-1 rounded-sm bg-muted/35 p-0.5",children:dO.map(({value:C,label:T,icon:E})=>{const R=t===C;return f.jsxs("button",{type:"button",onClick:()=>r(C),role:"menuitemradio","aria-checked":R,className:ne("flex min-h-[2.1rem] flex-col items-center justify-center gap-0.5 rounded-sm border px-1.5 py-1 text-[9px] font-medium transition-colors",R?"border-primary/55 bg-background text-primary shadow-sm":"border-transparent text-muted-foreground hover:border-border/70 hover:bg-background/80 hover:text-foreground"),children:[f.jsx(E,{className:"h-3 w-3"}),T]},C)})}),f.jsxs("div",{className:"grid gap-2 sm:grid-cols-2",children:[f.jsxs("div",{children:[f.jsx("div",{className:"px-0.5 pb-1 text-[8px] font-semibold uppercase tracking-[0.18em] text-muted-foreground",children:"Layout"}),f.jsx("div",{className:"space-y-1",children:H1.map(({value:C,label:T,hint:E})=>{const R=c===C;return f.jsxs("button",{type:"button",onClick:()=>u(C),role:"menuitemradio","aria-checked":R,className:ne("flex min-h-[2.25rem] w-full items-center gap-1.5 rounded-sm border px-1.5 py-1 text-left transition-colors",R?"border-primary/55 bg-primary/10":"border-border/45 bg-background/45 hover:border-border hover:bg-muted/55"),children:[f.jsxs("div",{className:"min-w-0 flex-1",children:[f.jsx("div",{className:ne("text-[10px] font-medium leading-tight",R?"text-primary":"text-foreground"),children:T}),f.jsx("div",{className:"mt-0.5 text-[8px] leading-tight text-muted-foreground",children:E})]}),R&&f.jsx(Oi,{className:"h-3 w-3 text-primary"})]},C)})})]}),f.jsxs("div",{children:[f.jsxs("div",{className:"flex items-center gap-1.5 px-0.5 pb-1 text-[8px] font-semibold uppercase tracking-[0.18em] text-muted-foreground",children:[f.jsx(TN,{className:"h-2.5 w-2.5"}),"Palette"]}),f.jsx("div",{className:"space-y-1",children:B1.map(({value:C,label:T,hint:E})=>{const R=o===C;return f.jsxs("button",{type:"button",onClick:()=>s(C),role:"menuitemradio","aria-checked":R,className:ne("flex min-h-[2.25rem] w-full items-center gap-1.5 rounded-sm border px-1.5 py-1 text-left transition-colors",R?"border-primary/55 bg-primary/10":"border-border/45 bg-background/45 hover:border-border hover:bg-muted/55"),children:[f.jsx(pO,{value:C}),f.jsxs("div",{className:"min-w-0 flex-1",children:[f.jsx("div",{className:ne("text-[10px] font-medium leading-tight",R?"text-primary":"text-foreground"),children:T}),f.jsx("div",{className:"mt-0.5 text-[8px] leading-tight text-muted-foreground",children:E})]}),R&&f.jsx(Oi,{className:"h-3 w-3 text-primary"})]},C)})})]})]})]})]})}function mO(t){return H1.find(r=>r.value===t)?.label??t}function hO(t){return B1.find(r=>r.value===t)?.label??t}function pO({value:t}){const r={porcelain:["hsl(212 76% 44%)","hsl(210 22% 98%)","hsl(174 42% 61%)"],warm:["hsl(35 88% 56%)","hsl(42 22% 97%)","hsl(160 60% 45%)"],finsight:["hsl(152 38% 32%)","hsl(150 14% 97%)","hsl(142 55% 58%)"],edge:["hsl(265 75% 55%)","hsl(260 12% 98%)","hsl(285 70% 65%)"],symphony:["hsl(348 100% 71%)","hsl(0 0% 6%)","hsl(240 2% 9%)"],launcher:["hsl(213 77% 49%)","hsl(60 10% 96%)","hsl(0 0% 100%)"]},[o,s,c]=r[t];return f.jsxs("div",{className:ne("flex h-5 w-5 shrink-0 overflow-hidden border border-border/60 shadow-sm","rounded-sm"),children:[f.jsx("div",{className:"h-full w-1/3",style:{background:o}}),f.jsx("div",{className:"h-full w-1/3",style:{background:s}}),f.jsx("div",{className:"h-full w-1/3",style:{background:c}})]})}const Ul={tasks:{defaultSize:20,min:16,max:36,wheelStep:1},operations:{defaultSize:20,min:18,max:38,wheelStep:1},terminal:{defaultSize:18,min:10,max:30,wheelStep:1}},P1="meshy-dashboard-panel-state-v2",$1="meshy-dashboard-terminal-open-v1";function A3({operationsOpen:t}){return{layout:{desktopTasksOpen:!0,operationsOpen:t},sizes:{tasks:Ul.tasks.defaultSize,operations:Ul.operations.defaultSize,terminal:Ul.terminal.defaultSize}}}function Jd(t){return typeof t=="object"&&t!==null}function wy(t,r){return typeof t=="boolean"?t:r}function ef(t,r,o){return typeof r=="number"&&Number.isFinite(r)?Bl(t,r):o}function Bl(t,r){const o=Ul[t];return Math.min(o.max,Math.max(o.min,r))}function k3(t,r){if(!t)return r;try{const o=t.getItem(P1);if(!o)return r;const s=JSON.parse(o);if(!Jd(s))return r;const c=Jd(s.layout)?s.layout:{},u=Jd(s.sizes)?s.sizes:{};return{layout:{desktopTasksOpen:wy(c.desktopTasksOpen,r.layout.desktopTasksOpen),operationsOpen:wy(c.operationsOpen,r.layout.operationsOpen)},sizes:{tasks:ef("tasks",u.tasks,r.sizes.tasks),operations:ef("operations",u.operations,r.sizes.operations),terminal:ef("terminal",u.terminal,r.sizes.terminal)}}}catch{return r}}function _3(t,r){if(t)try{t.setItem(P1,JSON.stringify(r))}catch{}}function gO(t,r){if(!t)return r;try{const o=t.getItem($1);return o==="true"?!0:o==="false"?!1:r}catch{return r}}function vO(t,r){if(t)try{t.setItem($1,String(r))}catch{}}function Sy(){try{return globalThis.window?.localStorage??globalThis.localStorage??null}catch{return null}}function j3(t){return`${Number(t.toFixed(2))}rem`}function O3(t,r,o,s,c,u,m){const h=Number.isFinite(m)&&m>0?m:16;return t==="tasks"?Bl(t,r+(c-o)/h):t==="operations"?Bl(t,r+(o-c)/h):Bl(t,r+(s-u)/h)}function D3(t,r,o){const s=o===0?0:o>0?-1:1;return Bl(t,r+s*Ul[t].wheelStep)}const yO=7200*1e3,bO=15*1e3,xO="meshy://desktop-update-progress",wO="start_desktop_window_drag",SO="enable_windows_dashboard_titlebar",EO="minimize_desktop_window",TO="toggle_desktop_window_maximize",NO="close_desktop_window",CO="Desktop update check timed out",RO='a,button,input,textarea,select,[role="button"],[role="menu"],[role="dialog"],[contenteditable="true"]';function AO(t){const r=t?.closest;return typeof r!="function"?!1:!r.call(t,RO)}function kO(t,r=Ba()){if(!r||t.button!==void 0&&t.button!==0||t.isPrimary===!1||!AO(t.target))return!1;t.preventDefault?.();try{return r(wO).catch(()=>{}),!0}catch{return!1}}function _O(){return f.jsxs("svg",{"data-meshy-app-icon":"header",viewBox:"0 0 1024 1024",className:"h-7 w-7","aria-hidden":"true",children:[f.jsx("defs",{children:f.jsxs("linearGradient",{id:"meshy-header-icon-edge",x1:"260",y1:"244",x2:"768",y2:"780",gradientUnits:"userSpaceOnUse",children:[f.jsx("stop",{offset:"0",stopColor:"#66e3ff"}),f.jsx("stop",{offset:"0.52",stopColor:"#8fd56b"}),f.jsx("stop",{offset:"1",stopColor:"#ffcb5b"})]})}),f.jsx("path",{d:"M308 652V372l204 174 204-174v280",fill:"none",stroke:"url(#meshy-header-icon-edge)",strokeWidth:"86",strokeLinecap:"round",strokeLinejoin:"round"}),f.jsx("circle",{cx:"308",cy:"372",r:"58",fill:"#66e3ff"}),f.jsx("circle",{cx:"512",cy:"546",r:"58",fill:"#8fd56b"}),f.jsx("circle",{cx:"716",cy:"372",r:"58",fill:"#ffcb5b"}),f.jsx("circle",{cx:"308",cy:"652",r:"58",fill:"#66e3ff"}),f.jsx("circle",{cx:"716",cy:"652",r:"58",fill:"#ffcb5b"})]})}function Ba(){return typeof window>"u"?null:window.__TAURI__?.core?.invoke??null}function jO(){return typeof window>"u"?null:window.__TAURI__?.event?.listen??null}function OO(t){const r=typeof window>"u"?void 0:window;if(!r?.__TAURI__)return!1;const o=r.navigator?.platform??"",s=r.navigator?.userAgent??"";return/Mac/i.test(o)||/Macintosh/i.test(s)}function DO(t){const r=typeof window>"u"?void 0:window;if(!r?.__TAURI__)return!1;const o=r.navigator?.platform??"",s=r.navigator?.userAgent??"";return/Win/i.test(o)||/Windows/i.test(s)}function tf(t){const r=Ba();r&&r(t).catch(()=>{})}function MO(){return f.jsxs("div",{className:"dashboard-window-controls--windows flex shrink-0 items-stretch","data-window-control-set":"windows",children:[f.jsx("button",{type:"button",className:"dashboard-window-control flex w-10 items-center justify-center border-0 bg-transparent p-0 text-muted-foreground transition-colors hover:bg-muted/65 hover:text-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring","aria-label":"Minimize window",title:"Minimize window","data-window-control":"minimize",onClick:()=>tf(EO),children:f.jsx(rN,{className:"h-3.5 w-3.5"})}),f.jsx("button",{type:"button",className:"dashboard-window-control flex w-10 items-center justify-center border-0 bg-transparent p-0 text-muted-foreground transition-colors hover:bg-muted/65 hover:text-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring","aria-label":"Maximize or restore window",title:"Maximize or restore window","data-window-control":"maximize",onClick:()=>tf(TO),children:f.jsx(CN,{className:"h-3 w-3"})}),f.jsx("button",{type:"button",className:"dashboard-window-control flex w-10 items-center justify-center border-0 bg-transparent p-0 text-muted-foreground transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring","aria-label":"Close window",title:"Close window","data-window-control":"close",onClick:()=>tf(NO),children:f.jsx(Yf,{className:"h-3.5 w-3.5"})})]})}function zO(t){if(!t||typeof t!="object")return null;const r=t;return r.phase!=="downloading"&&r.phase!=="installing"&&r.phase!=="complete"?null:{phase:r.phase,receivedBytes:typeof r.receivedBytes=="number"?r.receivedBytes:0,totalBytes:typeof r.totalBytes=="number"?r.totalBytes:null,percent:typeof r.percent=="number"?Math.max(0,Math.min(100,Math.round(r.percent))):null}}function Ey(t){return{currentVersion:null,latestVersion:null,updateAvailable:!1,checkedAt:new Date().toISOString(),releaseUrl:null,assetName:null,installable:!1,detail:t}}async function LO(t,r,o){let s;const c=new Promise((u,m)=>{s=setTimeout(()=>{m(new Error(CO))},r)});try{return await Promise.race([t,c])}finally{s!==void 0&&clearTimeout(s)}}async function UO({activeCheck:t,startCheck:r,timeoutMs:o,shouldApply:s,applyUpdate:c,applyFailure:u,failureFallback:m="Desktop update check failed"}){let h=t.current;if(!h){let v;try{v=r()}catch(p){v=Promise.reject(p)}h=LO(v,o),t.current=h}try{const v=await h;return s()&&c(v),v}catch(v){return s()&&u(jf(v,m)),null}finally{t.current===h&&(t.current=null)}}function jf(t,r){if(t instanceof Error&&t.message.trim())return t.message;if(typeof t=="string"&&t.trim())return t;if(t&&typeof t=="object"&&"message"in t){const o=t.message;if(typeof o=="string"&&o.trim())return o}return r}function BO(t){return t.openedRelease?"Opened the latest Meshy release page.":t.installMethod==="tauri-updater"?"Installing desktop update. Meshy will relaunch to finish updating.":(t.assetName??"desktop update").toLowerCase().endsWith(".dmg")?"Downloaded desktop update. Open the DMG and drag Meshy to Applications to finish updating.":"Downloaded desktop update. Follow the installer to finish updating."}function HO(){const{cluster:t,events:r,sseConnected:o,systemInfo:s}=nb(),c=En(),[u,m]=g.useState(()=>gO(Sy(),!1)),[h,v]=g.useState(""),[p,b]=g.useState(null),[y,S]=g.useState(null),[A,C]=g.useState(!1),[T,E]=g.useState(null),R=g.useRef(null),k=!!Ba(),O=OO(),U=DO(),z=O||U,G=z?{"data-tauri-drag-region":!0}:{},Y=z?{...G,"data-meshy-desktop-titlebar":"dashboard"}:{},q=g.useCallback(H=>{z&&kO(H)},[z]),re=k?"max-w-none":"max-w-[1760px]",fe=c.pathname==="/"||/^\/tasks\/[^/]+$/.test(c.pathname),ue=g.useMemo(()=>{const H=new Map;for(const F of t?.nodes??[])H.set(F.id,F.name);return t?.self&&H.set(t.self.id,t.self.name),H},[t?.nodes,t?.self]),de=g.useCallback(H=>{m(F=>typeof H=="function"?H(F):H)},[]);g.useEffect(()=>{vO(Sy(),u)},[u]),g.useEffect(()=>{if(!U)return;const H=Ba();H&&H(SO).catch(()=>{})},[U]);const W=g.useCallback(async(H=!0,F=()=>!0)=>{const N=Ba();return N?(H&&F()&&S(Ey("Checking desktop update...")),UO({activeCheck:R,startCheck:()=>N("check_desktop_update"),timeoutMs:bO,shouldApply:F,applyUpdate:I=>S(I),applyFailure:I=>S(J=>J?.updateAvailable?J:Ey(I))})):(F()&&S(null),null)},[]);async function se(){C(!0);try{await W(!1)}finally{C(!1)}}g.useEffect(()=>{if(!Ba()){S(null);return}let H=!1;const F=()=>!H;W(!0,F);const N=window.setInterval(()=>{W(!1,F)},yO);return()=>{H=!0,window.clearInterval(N)}},[W,s?.version]),g.useEffect(()=>{const H=jO();if(!H)return;let F=!1,N;return H(xO,I=>{const J=zO(I.payload);J&&E(J)}).then(I=>{if(F){I();return}N=I}).catch(()=>{}),()=>{F=!0,N?.()}},[]);async function ee(){try{const H=await eb({reason:"restart"});Ce.info(`Restarting runtime. Follow ${H.logPath} for launch output.`),await A1({previousPid:H.pid})||Ce.error("Runtime restart was accepted, but the dashboard did not reconnect before the timeout.")}catch(H){Ce.error(H instanceof Error?H.message:"Runtime restart failed")}}async function j(){const H=Ba();if(!H){Ce.error("Desktop updater is not available in this window");return}try{Ce.info("Downloading desktop update..."),E({phase:"downloading",receivedBytes:0,totalBytes:null,percent:0});const F=await H("install_desktop_update");E({phase:"complete",receivedBytes:1,totalBytes:1,percent:100}),Ce.info(BO(F))}catch(F){Ce.error(jf(F,"Desktop update failed"))}finally{E(null)}}async function P(){const H=Ba();if(!H){Ce.error("Desktop restart is not available in this window");return}try{Ce.info("Restarting Meshy Desktop..."),await H("restart_desktop_app")}catch(F){Ce.error(jf(F,"Desktop restart failed"))}}return f.jsxs("div",{className:ne("relative h-full overflow-hidden bg-background text-foreground",O&&"dashboard-shell--macos-titlebar",U&&"dashboard-shell--windows-titlebar"),children:[f.jsx("div",{className:"mesh-grid pointer-events-none absolute inset-0"}),f.jsxs("div",{className:"relative z-10 flex h-full min-h-0 flex-col",children:[f.jsx("header",{className:ne("dashboard-shell-header relative z-50 shrink-0 px-2 py-2",O&&"dashboard-shell-header--macos-titlebar",U&&"dashboard-shell-header--windows-titlebar"),onPointerDownCapture:z?q:void 0,...G,children:f.jsxs("div",{className:ne("dashboard-shell-header-panel dashboard-panel dashboard-panel-muted animate-panel-settle mx-auto flex items-center gap-0 rounded-lg px-3 py-2",re,O&&"dashboard-shell-header-panel--macos-titlebar",U&&"dashboard-shell-header-panel--windows-titlebar"),...Y,children:[f.jsx("div",{className:"flex shrink-0 items-center gap-3 pr-3",...G,children:f.jsxs(rf,{to:"/","aria-label":"Meshy home",className:"flex items-center gap-2",children:[f.jsx(_O,{}),f.jsxs("div",{className:"hidden min-w-0 items-baseline gap-1.5 sm:flex",children:[f.jsx("span",{className:"text-[10px] font-semibold uppercase tracking-[0.24em] text-muted-foreground",children:"MESHY"}),f.jsx("span",{className:"text-[10px] font-semibold uppercase tracking-[0.24em] text-muted-foreground",children:"Workspace"})]})]})}),f.jsx("div",{className:"mx-0 hidden h-4 w-px shrink-0 bg-border/50 md:block",...G}),fe&&f.jsxs("div",{className:"hidden min-w-0 flex-1 items-center px-3 md:flex",...G,children:[p&&f.jsxs("nav",{"aria-label":"Current task location",className:"flex min-w-0 max-w-[38rem] items-center gap-1 rounded-sm bg-background/55 px-2 py-1 text-[10px] text-muted-foreground",children:[f.jsxs("button",{type:"button",onClick:()=>v(p.nodeName),className:"flex min-w-0 items-center gap-1 rounded-sm px-1 py-0.5 hover:bg-muted/60 hover:text-foreground",title:`Filter by ${p.nodeName}`,children:[f.jsx(xN,{className:"h-3 w-3 shrink-0 text-primary/70"}),f.jsx("span",{className:"max-w-[9rem] truncate",children:p.nodeName})]}),f.jsx(lf,{className:"h-3 w-3 shrink-0 text-border/80"}),f.jsxs("button",{type:"button",onClick:()=>v(p.projectLabel),className:"flex min-w-0 items-center gap-1 rounded-sm px-1 py-0.5 hover:bg-muted/60 hover:text-foreground",title:p.projectPath,children:[f.jsx(ZT,{className:"h-3 w-3 shrink-0 text-muted-foreground/70"}),f.jsx("span",{className:"max-w-[9rem] truncate",children:p.projectLabel})]}),f.jsx(lf,{className:"h-3 w-3 shrink-0 text-border/80"}),f.jsx(rf,{to:`/tasks/${p.taskId}`,className:"min-w-0 truncate px-1 font-medium text-foreground/85 hover:text-foreground",title:p.taskTitle,children:p.taskTitle})]}),f.jsxs("div",{className:"dashboard-header-search relative ml-auto w-[18rem] max-w-[28rem]",children:[f.jsx(yN,{className:"pointer-events-none absolute left-2.5 top-1/2 h-3.5 w-3.5 -translate-y-1/2 text-muted-foreground/60"}),f.jsx(gc,{"aria-label":"Search tasks",value:h,onChange:H=>v(H.target.value),placeholder:"Search tasks, nodes, workspaces",className:"h-8 rounded-sm border-0 bg-background/62 pl-8 pr-2 text-[11px] shadow-none focus-visible:ring-0 focus-visible:ring-offset-0"})]})]}),f.jsx("div",{className:"mx-0 hidden h-4 w-px shrink-0 bg-border/50 md:block",...G}),f.jsxs("div",{className:"ml-auto flex shrink-0 items-center gap-1.5 pl-3 sm:gap-2 md:ml-0",...G,children:[fe&&f.jsx(Nt,{variant:"ghost",size:"icon",onClick:()=>de(H=>!H),"aria-label":u?"Close terminal":"Open terminal",title:u?"Close terminal":"Open terminal",className:ne("h-8 w-8 rounded-sm text-muted-foreground hover:bg-muted/50 hover:text-foreground",u&&"bg-primary/8 text-primary"),children:f.jsx(db,{className:"h-4 w-4"})}),f.jsx(Aj,{}),f.jsx(fO,{}),f.jsx("div",{className:"mx-0 h-4 w-px shrink-0 bg-border/50",...G}),f.jsx(Yj,{connected:o,events:r,nodes:t?.nodes??[],currentNode:t?.self??null,nodeNameById:ue,desktopUpdate:y,desktopUpdateCheckPending:A,desktopUpdateProgress:T,onDesktopUpdateCheck:k?se:void 0,onDesktopUpdate:y?.updateAvailable?j:void 0,onDesktopRestart:k?P:void 0,onReload:k?()=>window.location.reload():void 0,onRestart:ee}),U&&f.jsx(MO,{})]})]})}),f.jsx("main",{className:ne("dashboard-shell-main min-h-0 flex-1 px-2 pb-2",fe?"overflow-hidden":"overflow-y-auto"),children:f.jsx("div",{className:ne("dashboard-shell-content mx-auto h-full min-h-0",re),children:f.jsx(lE,{context:{terminalOpen:u,setTerminalOpen:de,headerSearchQuery:h,setHeaderSearchQuery:v,setHeaderTaskContext:b}})})})]})]})}const Ty=g.lazy(async()=>({default:(await Ry(()=>import("./DashboardPage-DYIrafIS.js").then(r=>r.D),__vite__mapDeps([0,1,2,3,4]))).DashboardPage})),PO=g.lazy(async()=>({default:(await Ry(()=>import("./SharedConversationPage-B9wCWxLh.js"),__vite__mapDeps([5,1]))).SharedConversationPage}));function $O(){return f.jsx(OE,{children:f.jsx(g.Suspense,{fallback:f.jsx(qO,{}),children:f.jsxs(iE,{children:[f.jsx(yr,{path:"/shared/tasks/:shareId",element:f.jsx(PO,{})}),f.jsxs(yr,{element:f.jsx(NT,{children:f.jsx(HO,{})}),children:[f.jsx(yr,{path:"/",element:f.jsx(Ty,{})}),f.jsx(yr,{path:"/nodes",element:f.jsx(Ev,{to:"/",replace:!0})}),f.jsx(yr,{path:"/tasks",element:f.jsx(Ev,{to:"/",replace:!0})}),f.jsx(yr,{path:"/tasks/:id",element:f.jsx(Ty,{})})]})]})})})}function qO(){return f.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background text-sm text-muted-foreground",children:"Loading workspace..."})}function VO(t){const r=t??(typeof window>"u"?void 0:window);r?.__TAURI__&&r.addEventListener("contextmenu",o=>{o.preventDefault()})}function IO(t){const{className:r,style:o,toastOptions:s,...c}=t;function u(m){const h=m.target;if(!(h instanceof Element)||h.closest("button, a, input, textarea, select, [data-close-button], [data-button]"))return;const v=h.closest("[data-sonner-toast]");v&&v.dataset.type!=="loading"&&_1()}return f.jsx("div",{onClick:u,children:f.jsx(KC,{className:["toaster group",r].filter(Boolean).join(" "),closeButton:!0,gap:6,offset:{right:"0.6rem",bottom:"0.6rem"},mobileOffset:{right:"0.5rem",bottom:"0.5rem",left:"0.5rem"},position:"bottom-right",visibleToasts:3,style:{"--normal-bg":"hsl(var(--popover))","--normal-text":"hsl(var(--popover-foreground))","--normal-border":"hsl(var(--border) / 0.7)","--width":"17rem",...o},toastOptions:{duration:3e3,closeButton:!0,...s,classNames:{toast:"meshy-toast",title:"meshy-toast__title",description:"meshy-toast__description",content:"meshy-toast__content",icon:"meshy-toast__icon",closeButton:"meshy-toast__close",actionButton:"meshy-toast__action",cancelButton:"meshy-toast__cancel",success:"meshy-toast--success",error:"meshy-toast--error",info:"meshy-toast--info",warning:"meshy-toast--warning",...s?.classNames}},...c})})}VO();o2.createRoot(document.getElementById("root")).render(f.jsx(g.StrictMode,{children:f.jsxs(lO,{children:[f.jsx($O,{}),f.jsx(IO,{})]})}));export{e3 as $,bD as A,Nt as B,Oi as C,t3 as D,LA as E,ZT as F,d0 as G,m0 as H,gc as I,R3 as J,rb as K,lb as L,p1 as M,Ix as N,sb as O,uN as P,E3 as Q,Ri as R,xN as S,n3 as T,qT as U,E_ as V,a3 as W,Yf as X,If as Y,F5 as Z,JD as _,w3 as a,OD as a$,xn as a0,v3 as a1,Vi as a2,Tf as a3,Ii as a4,Yi as a5,Xi as a6,Qi as a7,Gi as a8,Zi as a9,UT as aA,pj as aB,of as aC,ON as aD,Zl as aE,SN as aF,MT as aG,lN as aH,WT as aI,m3 as aJ,Mj as aK,ob as aL,y3 as aM,x_ as aN,VD as aO,sR as aP,l3 as aQ,_N as aR,b3 as aS,x3 as aT,r3 as aU,o3 as aV,p3 as aW,N1 as aX,g3 as aY,Nf as aZ,jD as a_,Ki as aa,Ry as ab,KO as ac,f0 as ad,HA as ae,uD as af,db as ag,xo as ah,sf as ai,CN as aj,cD as ak,dD as al,iD as am,YD as an,FO as ao,WO as ap,UA as aq,h0 as ar,Ei as as,KD as at,vj as au,Ll as av,d1 as aw,h_ as ax,T3 as ay,N3 as az,eR as b,m1 as b$,k3 as b0,A3 as b1,Sy as b2,_3 as b3,D3 as b4,j3 as b5,O3 as b6,vD as b7,yT as b8,JE as b9,h3 as bA,q_ as bB,C3 as bC,f3 as bD,s3 as bE,i3 as bF,u3 as bG,c3 as bH,d3 as bI,yD as bJ,b_ as bK,w_ as bL,CD as bM,RD as bN,TD as bO,ED as bP,QO as bQ,ZO as bR,XO as bS,aD as bT,WD as bU,UD as bV,LD as bW,zD as bX,DD as bY,MD as bZ,BD as b_,XD as ba,GD as bb,QD as bc,wT as bd,AD as be,tD as bf,JO as bg,Jy as bh,eD as bi,nD as bj,Aj as bk,kD as bl,_D as bm,pD as bn,fD as bo,mD as bp,hD as bq,gD as br,SD as bs,ND as bt,wD as bu,GO as bv,En as bw,Vy as bx,YO as by,nb as bz,Oe as c,z5 as c0,FD as c1,M5 as c2,Ny as c3,$D as c4,PD as c5,HD as c6,qD as c7,ZD as c8,ID as c9,ne as d,Ab as e,v1 as f,oD as g,sD as h,Wy as i,f as j,rD as k,lf as l,S3 as m,aa as n,lD as o,xD as p,wf as q,g as r,$i as s,Ce as t,Sf as u,qi as v,yN as w,Pl as x,TN as y,Cf as z};