meshy-node 1.0.2 → 1.0.4
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.
- package/README.md +1 -1
- package/dashboard/assets/{DashboardPage-TE6tsOBU.js → DashboardPage-D5cStRjL.js} +46 -51
- package/dashboard/assets/{DashboardShared-B6YLnjis.js → DashboardShared-Cl2J-iJd.js} +1 -1
- package/dashboard/assets/{DiffTab-B4hRGo1c.js → DiffTab-Bf9BAMpM.js} +1 -1
- package/dashboard/assets/{FilesTab-By5MpB3q.js → FilesTab-CH1lwzT9.js} +1 -1
- package/dashboard/assets/{MarkdownPreviewFrame-C094uLQB.js → MarkdownPreviewFrame-DEZT2HNE.js} +1 -1
- package/dashboard/assets/{PreviewTab-C_SvaL2_.js → PreviewTab-T_Y0AhqI.js} +5 -5
- package/dashboard/assets/{SharedConversationPage-8XehjzT5.js → SharedConversationPage-C2p4_D8K.js} +2 -2
- package/dashboard/assets/{file-C7Gl-F2G.js → file-By_WHjZd.js} +1 -1
- package/dashboard/assets/index-B75j0Sjk.js +351 -0
- package/dashboard/assets/index-BRrkswqR.css +1 -0
- package/dashboard/index.html +2 -2
- package/main.cjs +1799 -1057
- package/package.json +1 -1
- package/runtime-metadata.json +4 -4
- package/dashboard/assets/index-Cw9E6sQy.js +0 -341
- package/dashboard/assets/index-DPc1_Q2V.css +0 -1
|
@@ -0,0 +1,351 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-D5cStRjL.js","assets/DashboardShared-Cl2J-iJd.js","assets/MarkdownPreviewFrame-DEZT2HNE.js","assets/PreviewTab-T_Y0AhqI.js","assets/DashboardPage-BaHExl1O.css","assets/SharedConversationPage-C2p4_D8K.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
function LS(t,a){for(var o=0;o<a.length;o++){const s=a[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 a=document.createElement("link").relList;if(a&&a.supports&&a.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 Ry(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Nd={exports:{}},Rl={};/**
|
|
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 Wg;function US(){if(Wg)return Rl;Wg=1;var t=Symbol.for("react.transitional.element"),a=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 Rl.Fragment=a,Rl.jsx=o,Rl.jsxs=o,Rl}var Fg;function HS(){return Fg||(Fg=1,Nd.exports=US()),Nd.exports}var f=HS(),Td={exports:{}},Ce={};/**
|
|
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 Jg;function BS(){if(Jg)return Ce;Jg=1;var t=Symbol.for("react.transitional.element"),a=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 C={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},R=Object.assign,E={};function T(N,Y,ne){this.props=N,this.context=Y,this.refs=E,this.updater=ne||C}T.prototype.isReactComponent={},T.prototype.setState=function(N,Y){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,Y,"setState")},T.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function k(){}k.prototype=T.prototype;function A(N,Y,ne){this.props=N,this.context=Y,this.refs=E,this.updater=ne||C}var M=A.prototype=new k;M.constructor=A,R(M,T.prototype),M.isPureReactComponent=!0;var L=Array.isArray,H={H:null,A:null,T:null,S:null,V:null},I=Object.prototype.hasOwnProperty;function G(N,Y,ne,X,F,ee){return ne=ee.ref,{$$typeof:t,type:N,key:Y,ref:ne!==void 0?ne:null,props:ee}}function V(N,Y){return G(N.type,Y,void 0,void 0,void 0,N.props)}function oe(N){return typeof N=="object"&&N!==null&&N.$$typeof===t}function fe(N){var Y={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(ne){return Y[ne]})}var ae=/\/+/g;function ie(N,Y){return typeof N=="object"&&N!==null&&N.key!=null?fe(""+N.key):Y.toString(36)}function ce(){}function ue(N){switch(N.status){case"fulfilled":return N.value;case"rejected":throw N.reason;default:switch(typeof N.status=="string"?N.then(ce,ce):(N.status="pending",N.then(function(Y){N.status==="pending"&&(N.status="fulfilled",N.value=Y)},function(Y){N.status==="pending"&&(N.status="rejected",N.reason=Y)})),N.status){case"fulfilled":return N.value;case"rejected":throw N.reason}}throw N}function re(N,Y,ne,X,F){var ee=typeof N;(ee==="undefined"||ee==="boolean")&&(N=null);var te=!1;if(N===null)te=!0;else switch(ee){case"bigint":case"string":case"number":te=!0;break;case"object":switch(N.$$typeof){case t:case a:te=!0;break;case b:return te=N._init,re(te(N._payload),Y,ne,X,F)}}if(te)return F=F(N),te=X===""?"."+ie(N,0):X,L(F)?(ne="",te!=null&&(ne=te.replace(ae,"$&/")+"/"),re(F,Y,ne,"",function(xe){return xe})):F!=null&&(oe(F)&&(F=V(F,ne+(F.key==null||N&&N.key===F.key?"":(""+F.key).replace(ae,"$&/")+"/")+te)),Y.push(F)),1;te=0;var se=X===""?".":X+":";if(L(N))for(var de=0;de<N.length;de++)X=N[de],ee=se+ie(X,de),te+=re(X,Y,ne,ee,F);else if(de=S(N),typeof de=="function")for(N=de.call(N),de=0;!(X=N.next()).done;)X=X.value,ee=se+ie(X,de++),te+=re(X,Y,ne,ee,F);else if(ee==="object"){if(typeof N.then=="function")return re(ue(N),Y,ne,X,F);throw Y=String(N),Error("Objects are not valid as a React child (found: "+(Y==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":Y)+"). If you meant to render a collection of children, use an array instead.")}return te}function _(N,Y,ne){if(N==null)return N;var X=[],F=0;return re(N,X,"","",function(ee){return Y.call(ne,ee,F++)}),X}function $(N){if(N._status===-1){var Y=N._result;Y=Y(),Y.then(function(ne){(N._status===0||N._status===-1)&&(N._status=1,N._result=ne)},function(ne){(N._status===0||N._status===-1)&&(N._status=2,N._result=ne)}),N._status===-1&&(N._status=0,N._result=Y)}if(N._status===1)return N._result.default;throw N._result}var O=typeof reportError=="function"?reportError:function(N){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var Y=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(Y))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",N);return}console.error(N)};function W(){}return Ce.Children={map:_,forEach:function(N,Y,ne){_(N,function(){Y.apply(this,arguments)},ne)},count:function(N){var Y=0;return _(N,function(){Y++}),Y},toArray:function(N){return _(N,function(Y){return Y})||[]},only:function(N){if(!oe(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},Ce.Component=T,Ce.Fragment=o,Ce.Profiler=c,Ce.PureComponent=A,Ce.StrictMode=s,Ce.Suspense=v,Ce.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=H,Ce.__COMPILER_RUNTIME={__proto__:null,c:function(N){return H.H.useMemoCache(N)}},Ce.cache=function(N){return function(){return N.apply(null,arguments)}},Ce.cloneElement=function(N,Y,ne){if(N==null)throw Error("The argument must be a React element, but you passed "+N+".");var X=R({},N.props),F=N.key,ee=void 0;if(Y!=null)for(te in Y.ref!==void 0&&(ee=void 0),Y.key!==void 0&&(F=""+Y.key),Y)!I.call(Y,te)||te==="key"||te==="__self"||te==="__source"||te==="ref"&&Y.ref===void 0||(X[te]=Y[te]);var te=arguments.length-2;if(te===1)X.children=ne;else if(1<te){for(var se=Array(te),de=0;de<te;de++)se[de]=arguments[de+2];X.children=se}return G(N.type,F,void 0,void 0,ee,X)},Ce.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},Ce.createElement=function(N,Y,ne){var X,F={},ee=null;if(Y!=null)for(X in Y.key!==void 0&&(ee=""+Y.key),Y)I.call(Y,X)&&X!=="key"&&X!=="__self"&&X!=="__source"&&(F[X]=Y[X]);var te=arguments.length-2;if(te===1)F.children=ne;else if(1<te){for(var se=Array(te),de=0;de<te;de++)se[de]=arguments[de+2];F.children=se}if(N&&N.defaultProps)for(X in te=N.defaultProps,te)F[X]===void 0&&(F[X]=te[X]);return G(N,ee,void 0,void 0,null,F)},Ce.createRef=function(){return{current:null}},Ce.forwardRef=function(N){return{$$typeof:h,render:N}},Ce.isValidElement=oe,Ce.lazy=function(N){return{$$typeof:b,_payload:{_status:-1,_result:N},_init:$}},Ce.memo=function(N,Y){return{$$typeof:p,type:N,compare:Y===void 0?null:Y}},Ce.startTransition=function(N){var Y=H.T,ne={};H.T=ne;try{var X=N(),F=H.S;F!==null&&F(ne,X),typeof X=="object"&&X!==null&&typeof X.then=="function"&&X.then(W,O)}catch(ee){O(ee)}finally{H.T=Y}},Ce.unstable_useCacheRefresh=function(){return H.H.useCacheRefresh()},Ce.use=function(N){return H.H.use(N)},Ce.useActionState=function(N,Y,ne){return H.H.useActionState(N,Y,ne)},Ce.useCallback=function(N,Y){return H.H.useCallback(N,Y)},Ce.useContext=function(N){return H.H.useContext(N)},Ce.useDebugValue=function(){},Ce.useDeferredValue=function(N,Y){return H.H.useDeferredValue(N,Y)},Ce.useEffect=function(N,Y,ne){var X=H.H;if(typeof ne=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return X.useEffect(N,Y)},Ce.useId=function(){return H.H.useId()},Ce.useImperativeHandle=function(N,Y,ne){return H.H.useImperativeHandle(N,Y,ne)},Ce.useInsertionEffect=function(N,Y){return H.H.useInsertionEffect(N,Y)},Ce.useLayoutEffect=function(N,Y){return H.H.useLayoutEffect(N,Y)},Ce.useMemo=function(N,Y){return H.H.useMemo(N,Y)},Ce.useOptimistic=function(N,Y){return H.H.useOptimistic(N,Y)},Ce.useReducer=function(N,Y,ne){return H.H.useReducer(N,Y,ne)},Ce.useRef=function(N){return H.H.useRef(N)},Ce.useState=function(N){return H.H.useState(N)},Ce.useSyncExternalStore=function(N,Y,ne){return H.H.useSyncExternalStore(N,Y,ne)},Ce.useTransition=function(){return H.H.useTransition()},Ce.version="19.1.0",Ce}var ev;function Tf(){return ev||(ev=1,Td.exports=BS()),Td.exports}var g=Tf();const le=Ry(g),Cf=LS({__proto__:null,default:le},[g]);var Cd={exports:{}},Al={},Rd={exports:{}},Ad={};/**
|
|
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 tv;function PS(){return tv||(tv=1,(function(t){function a(_,$){var O=_.length;_.push($);e:for(;0<O;){var W=O-1>>>1,N=_[W];if(0<c(N,$))_[W]=$,_[O]=N,O=W;else break e}}function o(_){return _.length===0?null:_[0]}function s(_){if(_.length===0)return null;var $=_[0],O=_.pop();if(O!==$){_[0]=O;e:for(var W=0,N=_.length,Y=N>>>1;W<Y;){var ne=2*(W+1)-1,X=_[ne],F=ne+1,ee=_[F];if(0>c(X,O))F<N&&0>c(ee,X)?(_[W]=ee,_[F]=O,W=F):(_[W]=X,_[ne]=O,W=ne);else if(F<N&&0>c(ee,O))_[W]=ee,_[F]=O,W=F;else break e}}return $}function c(_,$){var O=_.sortIndex-$.sortIndex;return O!==0?O:_.id-$.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,C=!1,R=!1,E=!1,T=!1,k=typeof setTimeout=="function"?setTimeout:null,A=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate<"u"?setImmediate:null;function L(_){for(var $=o(p);$!==null;){if($.callback===null)s(p);else if($.startTime<=_)s(p),$.sortIndex=$.expirationTime,a(v,$);else break;$=o(p)}}function H(_){if(E=!1,L(_),!R)if(o(v)!==null)R=!0,I||(I=!0,ie());else{var $=o(p);$!==null&&re(H,$.startTime-_)}}var I=!1,G=-1,V=5,oe=-1;function fe(){return T?!0:!(t.unstable_now()-oe<V)}function ae(){if(T=!1,I){var _=t.unstable_now();oe=_;var $=!0;try{e:{R=!1,E&&(E=!1,A(G),G=-1),C=!0;var O=S;try{t:{for(L(_),y=o(v);y!==null&&!(y.expirationTime>_&&fe());){var W=y.callback;if(typeof W=="function"){y.callback=null,S=y.priorityLevel;var N=W(y.expirationTime<=_);if(_=t.unstable_now(),typeof N=="function"){y.callback=N,L(_),$=!0;break t}y===o(v)&&s(v),L(_)}else s(v);y=o(v)}if(y!==null)$=!0;else{var Y=o(p);Y!==null&&re(H,Y.startTime-_),$=!1}}break e}finally{y=null,S=O,C=!1}$=void 0}}finally{$?ie():I=!1}}}var ie;if(typeof M=="function")ie=function(){M(ae)};else if(typeof MessageChannel<"u"){var ce=new MessageChannel,ue=ce.port2;ce.port1.onmessage=ae,ie=function(){ue.postMessage(null)}}else ie=function(){k(ae,0)};function re(_,$){G=k(function(){_(t.unstable_now())},$)}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(_){_.callback=null},t.unstable_forceFrameRate=function(_){0>_||125<_?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):V=0<_?Math.floor(1e3/_):5},t.unstable_getCurrentPriorityLevel=function(){return S},t.unstable_next=function(_){switch(S){case 1:case 2:case 3:var $=3;break;default:$=S}var O=S;S=$;try{return _()}finally{S=O}},t.unstable_requestPaint=function(){T=!0},t.unstable_runWithPriority=function(_,$){switch(_){case 1:case 2:case 3:case 4:case 5:break;default:_=3}var O=S;S=_;try{return $()}finally{S=O}},t.unstable_scheduleCallback=function(_,$,O){var W=t.unstable_now();switch(typeof O=="object"&&O!==null?(O=O.delay,O=typeof O=="number"&&0<O?W+O:W):O=W,_){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=O+N,_={id:b++,callback:$,priorityLevel:_,startTime:O,expirationTime:N,sortIndex:-1},O>W?(_.sortIndex=O,a(p,_),o(v)===null&&_===o(p)&&(E?(A(G),G=-1):E=!0,re(H,O-W))):(_.sortIndex=N,a(v,_),R||C||(R=!0,I||(I=!0,ie()))),_},t.unstable_shouldYield=fe,t.unstable_wrapCallback=function(_){var $=S;return function(){var O=S;S=$;try{return _.apply(this,arguments)}finally{S=O}}}})(Ad)),Ad}var nv;function $S(){return nv||(nv=1,Rd.exports=PS()),Rd.exports}var kd={exports:{}},_t={};/**
|
|
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 av;function qS(){if(av)return _t;av=1;var t=Tf();function a(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(a(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 _t.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=s,_t.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(a(299));return u(v,p,null,b)},_t.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()}},_t.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))},_t.prefetchDNS=function(v){typeof v=="string"&&s.d.D(v)},_t.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,C=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:C}):b==="script"&&s.d.X(v,{crossOrigin:y,integrity:S,fetchPriority:C,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},_t.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)},_t.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})}},_t.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)},_t.requestFormReset=function(v){s.d.r(v)},_t.unstable_batchedUpdates=function(v,p){return v(p)},_t.useFormState=function(v,p,b){return m.H.useFormState(v,p,b)},_t.useFormStatus=function(){return m.H.useHostTransitionStatus()},_t.version="19.1.0",_t}var rv;function Ay(){if(rv)return kd.exports;rv=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(a){console.error(a)}}return t(),kd.exports=qS(),kd.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 ov;function VS(){if(ov)return Al;ov=1;var t=$S(),a=Tf(),o=Ay();function s(e){var n="https://react.dev/errors/"+e;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var r=2;r<arguments.length;r++)n+="&args[]="+encodeURIComponent(arguments[r])}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,r=e;if(e.alternate)for(;n.return;)n=n.return;else{e=n;do n=e,(n.flags&4098)!==0&&(r=n.return),e=n.return;while(e)}return n.tag===3?r: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 r=e,l=n;;){var i=r.return;if(i===null)break;var d=i.alternate;if(d===null){if(l=i.return,l!==null){r=l;continue}break}if(i.child===d.child){for(d=i.child;d;){if(d===r)return h(i),e;if(d===l)return h(i),n;d=d.sibling}throw Error(s(188))}if(r.return!==l.return)r=i,l=d;else{for(var x=!1,w=i.child;w;){if(w===r){x=!0,r=i,l=d;break}if(w===l){x=!0,l=i,r=d;break}w=w.sibling}if(!x){for(w=d.child;w;){if(w===r){x=!0,r=d,l=i;break}if(w===l){x=!0,l=d,r=i;break}w=w.sibling}if(!x)throw Error(s(189))}}if(r.alternate!==l)throw Error(s(190))}if(r.tag!==3)throw Error(s(188));return r.stateNode.current===r?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"),C=Symbol.for("react.portal"),R=Symbol.for("react.fragment"),E=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),k=Symbol.for("react.provider"),A=Symbol.for("react.consumer"),M=Symbol.for("react.context"),L=Symbol.for("react.forward_ref"),H=Symbol.for("react.suspense"),I=Symbol.for("react.suspense_list"),G=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),oe=Symbol.for("react.activity"),fe=Symbol.for("react.memo_cache_sentinel"),ae=Symbol.iterator;function ie(e){return e===null||typeof e!="object"?null:(e=ae&&e[ae]||e["@@iterator"],typeof e=="function"?e:null)}var ce=Symbol.for("react.client.reference");function ue(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===ce?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case R:return"Fragment";case T:return"Profiler";case E:return"StrictMode";case H:return"Suspense";case I:return"SuspenseList";case oe:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case C:return"Portal";case M:return(e.displayName||"Context")+".Provider";case A:return(e._context.displayName||"Context")+".Consumer";case L:var n=e.render;return e=e.displayName,e||(e=n.displayName||n.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case G:return n=e.displayName||null,n!==null?n:ue(e.type)||"Memo";case V:n=e._payload,e=e._init;try{return ue(e(n))}catch{}}return null}var re=Array.isArray,_=a.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,$=o.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,O={pending:!1,data:null,method:null,action:null},W=[],N=-1;function Y(e){return{current:e}}function ne(e){0>N||(e.current=W[N],W[N]=null,N--)}function X(e,n){N++,W[N]=e.current,e.current=n}var F=Y(null),ee=Y(null),te=Y(null),se=Y(null);function de(e,n){switch(X(te,n),X(ee,e),X(F,null),n.nodeType){case 9:case 11:e=(e=n.documentElement)&&(e=e.namespaceURI)?Tg(e):0;break;default:if(e=n.tagName,n=n.namespaceURI)n=Tg(n),e=Cg(n,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}ne(F),X(F,e)}function xe(){ne(F),ne(ee),ne(te)}function Ae(e){e.memoizedState!==null&&X(se,e);var n=F.current,r=Cg(n,e.type);n!==r&&(X(ee,e),X(F,r))}function Ne(e){ee.current===e&&(ne(F),ne(ee)),se.current===e&&(ne(se),Sl._currentValue=O)}var ke=Object.prototype.hasOwnProperty,Je=t.unstable_scheduleCallback,at=t.unstable_cancelCallback,fn=t.unstable_shouldYield,mn=t.unstable_requestPaint,lt=t.unstable_now,Ga=t.unstable_getCurrentPriorityLevel,ht=t.unstable_ImmediatePriority,Nr=t.unstable_UserBlockingPriority,Ln=t.unstable_NormalPriority,st=t.unstable_LowPriority,hn=t.unstable_IdlePriority,Tr=t.log,sa=t.unstable_setDisableYieldValue,$t=null,Ct=null;function Mt(e){if(typeof Tr=="function"&&sa(e),Ct&&typeof Ct.setStrictMode=="function")try{Ct.setStrictMode($t,e)}catch{}}var We=Math.clz32?Math.clz32:Tn,Nn=Math.log,Cr=Math.LN2;function Tn(e){return e>>>=0,e===0?32:31-(Nn(e)/Cr|0)|0}var ia=256,ca=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 Un(e,n,r){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):r||(r=w&~e,r!==0&&(i=Jt(r))))):(w=l&~d,w!==0?i=Jt(w):x!==0?i=Jt(x):r||(r=l&~e,r!==0&&(i=Jt(r)))),i===0?0:n!==0&&n!==i&&(n&d)===0&&(d=i&-i,r=n&-n,d>=r||d===32&&(r&4194048)!==0)?n:i}function Hn(e,n){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&n)===0}function ua(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=ia;return ia<<=1,(ia&4194048)===0&&(ia=256),e}function Ia(){var e=ca;return ca<<=1,(ca&62914560)===0&&(ca=4194304),e}function Xa(e){for(var n=[],r=0;31>r;r++)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,r,l,i,d){var x=e.pendingLanes;e.pendingLanes=r,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=r,e.entangledLanes&=r,e.errorRecoveryDisabledLanes&=r,e.shellSuspendCounter=0;var w=e.entanglements,j=e.expirationTimes,B=e.hiddenUpdates;for(r=x&~r;0<r;){var Q=31-We(r),Z=1<<Q;w[Q]=0,j[Q]=-1;var P=B[Q];if(P!==null)for(B[Q]=null,Q=0;Q<P.length;Q++){var q=P[Q];q!==null&&(q.lane&=-536870913)}r&=~Z}l!==0&&me(e,l,0),d!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=d&~(x&~n))}function me(e,n,r){e.pendingLanes|=n,e.suspendedLanes&=~n;var l=31-We(n);e.entangledLanes|=n,e.entanglements[l]=e.entanglements[l]|1073741824|r&4194090}function Ue(e,n){var r=e.entangledLanes|=n;for(e=e.entanglements;r;){var l=31-We(r),i=1<<l;i&n|e[l]&n&&(e[l]|=n),r&=~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 Qa(){var e=$.p;return e!==0?e:(e=window.event,e===void 0?32:Gg(e.type))}function gt(e,n){var r=$.p;try{return $.p=e,n()}finally{$.p=r}}var it=Math.random().toString(36).slice(2),ct="__reactFiber$"+it,Ke="__reactProps$"+it,wt="__reactContainer$"+it,Rr="__reactEvents$"+it,Bn="__reactListeners$"+it,fm="__reactHandles$"+it,mm="__reactResources$"+it,Do="__reactMarker$"+it;function vc(e){delete e[ct],delete e[Ke],delete e[Rr],delete e[Bn],delete e[fm]}function Ar(e){var n=e[ct];if(n)return n;for(var r=e.parentNode;r;){if(n=r[wt]||r[ct]){if(r=n.alternate,n.child!==null||r!==null&&r.child!==null)for(e=jg(e);e!==null;){if(r=e[ct])return r;e=jg(e)}return n}e=r,r=e.parentNode}return null}function kr(e){if(e=e[ct]||e[wt]){var n=e.tag;if(n===5||n===6||n===13||n===26||n===27||n===3)return e}return null}function Mo(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[mm];return n||(n=e[mm]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function St(e){e[Do]=!0}var hm=new Set,pm={};function Ka(e,n){_r(e,n),_r(e+"Capture",n)}function _r(e,n){for(pm[e]=n,e=0;e<n.length;e++)hm.add(n[e])}var A1=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]*$"),gm={},vm={};function k1(e){return ke.call(vm,e)?!0:ke.call(gm,e)?!1:A1.test(e)?vm[e]=!0:(gm[e]=!0,!1)}function Fl(e,n,r){if(k1(n))if(r===null)e.removeAttribute(n);else{switch(typeof r){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,""+r)}}function Jl(e,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(n);return}e.setAttribute(n,""+r)}}function Pn(e,n,r,l){if(l===null)e.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(r);return}e.setAttributeNS(n,r,""+l)}}var yc,ym;function Or(e){if(yc===void 0)try{throw Error()}catch(r){var n=r.stack.trim().match(/\n( *(at )?)/);yc=n&&n[1]||"",ym=-1<r.stack.indexOf(`
|
|
43
|
+
at`)?" (<anonymous>)":-1<r.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
44
|
+
`+yc+e+ym}var bc=!1;function xc(e,n){if(!e||bc)return"";bc=!0;var r=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(q){var P=q}Reflect.construct(e,[],Z)}else{try{Z.call()}catch(q){P=q}e.call(Z.prototype)}}else{try{throw Error()}catch(q){P=q}(Z=e())&&typeof Z.catch=="function"&&Z.catch(function(){})}}catch(q){if(q&&P&&typeof q.stack=="string")return[q.stack,P.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 j=x.split(`
|
|
45
|
+
`),B=w.split(`
|
|
46
|
+
`);for(i=l=0;l<j.length&&!j[l].includes("DetermineComponentFrameRoot");)l++;for(;i<B.length&&!B[i].includes("DetermineComponentFrameRoot");)i++;if(l===j.length||i===B.length)for(l=j.length-1,i=B.length-1;1<=l&&0<=i&&j[l]!==B[i];)i--;for(;1<=l&&0<=i;l--,i--)if(j[l]!==B[i]){if(l!==1||i!==1)do if(l--,i--,0>i||j[l]!==B[i]){var Q=`
|
|
47
|
+
`+j[l].replace(" at new "," at ");return e.displayName&&Q.includes("<anonymous>")&&(Q=Q.replace("<anonymous>",e.displayName)),Q}while(1<=l&&0<=i);break}}}finally{bc=!1,Error.prepareStackTrace=r}return(r=e?e.displayName||e.name:"")?Or(r):""}function j1(e){switch(e.tag){case 26:case 27:case 5:return Or(e.type);case 16:return Or("Lazy");case 13:return Or("Suspense");case 19:return Or("SuspenseList");case 0:case 15:return xc(e.type,!1);case 11:return xc(e.type.render,!1);case 1:return xc(e.type,!0);case 31:return Or("Activity");default:return""}}function bm(e){try{var n="";do n+=j1(e),e=e.return;while(e);return n}catch(r){return`
|
|
48
|
+
Error generating stack: `+r.message+`
|
|
49
|
+
`+r.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 xm(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function _1(e){var n=xm(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,n),l=""+e[n];if(!e.hasOwnProperty(n)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,d=r.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:r.enumerable}),{getValue:function(){return l},setValue:function(x){l=""+x},stopTracking:function(){e._valueTracker=null,delete e[n]}}}}function es(e){e._valueTracker||(e._valueTracker=_1(e))}function wm(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var r=n.getValue(),l="";return e&&(l=xm(e)?e.checked?"true":"false":e.value),e=l,e!==r?(n.setValue(e),!0):!1}function ts(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 O1=/[\n"\\]/g;function tn(e){return e.replace(O1,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function wc(e,n,r,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?Sc(e,x,en(n)):r!=null?Sc(e,x,en(r)):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 Sm(e,n,r,l,i,d,x,w){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),n!=null||r!=null){if(!(d!=="submit"&&d!=="reset"||n!=null))return;r=r!=null?""+en(r):"",n=n!=null?""+en(n):r,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 Sc(e,n,r){n==="number"&&ts(e.ownerDocument)===e||e.defaultValue===""+r||(e.defaultValue=""+r)}function Dr(e,n,r,l){if(e=e.options,n){n={};for(var i=0;i<r.length;i++)n["$"+r[i]]=!0;for(r=0;r<e.length;r++)i=n.hasOwnProperty("$"+e[r].value),e[r].selected!==i&&(e[r].selected=i),i&&l&&(e[r].defaultSelected=!0)}else{for(r=""+en(r),n=null,i=0;i<e.length;i++){if(e[i].value===r){e[i].selected=!0,l&&(e[i].defaultSelected=!0);return}n!==null||e[i].disabled||(n=e[i])}n!==null&&(n.selected=!0)}}function Em(e,n,r){if(n!=null&&(n=""+en(n),n!==e.value&&(e.value=n),r==null)){e.defaultValue!==n&&(e.defaultValue=n);return}e.defaultValue=r!=null?""+en(r):""}function Nm(e,n,r,l){if(n==null){if(l!=null){if(r!=null)throw Error(s(92));if(re(l)){if(1<l.length)throw Error(s(93));l=l[0]}r=l}r==null&&(r=""),n=r}r=en(n),e.defaultValue=r,l=e.textContent,l===r&&l!==""&&l!==null&&(e.value=l)}function Mr(e,n){if(n){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=n;return}}e.textContent=n}var D1=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 Tm(e,n,r){var l=n.indexOf("--")===0;r==null||typeof r=="boolean"||r===""?l?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="":l?e.setProperty(n,r):typeof r!="number"||r===0||D1.has(n)?n==="float"?e.cssFloat=r:e[n]=(""+r).trim():e[n]=r+"px"}function Cm(e,n,r){if(n!=null&&typeof n!="object")throw Error(s(62));if(e=e.style,r!=null){for(var l in r)!r.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)&&r[i]!==l&&Tm(e,i,l)}else for(var d in n)n.hasOwnProperty(d)&&Tm(e,d,n[d])}function Ec(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 M1=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"]]),z1=/^[\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 ns(e){return z1.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Nc=null;function Tc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var zr=null,Lr=null;function Rm(e){var n=kr(e);if(n&&(e=n.stateNode)){var r=e[Ke]||null;e:switch(e=n.stateNode,n.type){case"input":if(wc(e,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name),n=r.name,r.type==="radio"&&n!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll('input[name="'+tn(""+n)+'"][type="radio"]'),n=0;n<r.length;n++){var l=r[n];if(l!==e&&l.form===e.form){var i=l[Ke]||null;if(!i)throw Error(s(90));wc(l,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(n=0;n<r.length;n++)l=r[n],l.form===e.form&&wm(l)}break e;case"textarea":Em(e,r.value,r.defaultValue);break e;case"select":n=r.value,n!=null&&Dr(e,!!r.multiple,n,!1)}}}var Cc=!1;function Am(e,n,r){if(Cc)return e(n,r);Cc=!0;try{var l=e(n);return l}finally{if(Cc=!1,(zr!==null||Lr!==null)&&($s(),zr&&(n=zr,e=Lr,Lr=zr=null,Rm(n),e)))for(n=0;n<e.length;n++)Rm(e[n])}}function zo(e,n){var r=e.stateNode;if(r===null)return null;var l=r[Ke]||null;if(l===null)return null;r=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(r&&typeof r!="function")throw Error(s(231,n,typeof r));return r}var $n=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Rc=!1;if($n)try{var Lo={};Object.defineProperty(Lo,"passive",{get:function(){Rc=!0}}),window.addEventListener("test",Lo,Lo),window.removeEventListener("test",Lo,Lo)}catch{Rc=!1}var da=null,Ac=null,as=null;function km(){if(as)return as;var e,n=Ac,r=n.length,l,i="value"in da?da.value:da.textContent,d=i.length;for(e=0;e<r&&n[e]===i[e];e++);var x=r-e;for(l=1;l<=x&&n[r-l]===i[d-l];l++);return as=i.slice(e,1<l?1-l:void 0)}function rs(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 os(){return!0}function jm(){return!1}function Lt(e){function n(r,l,i,d,x){this._reactName=r,this._targetInst=i,this.type=l,this.nativeEvent=d,this.target=x,this.currentTarget=null;for(var w in e)e.hasOwnProperty(w)&&(r=e[w],this[w]=r?r(d):d[w]);return this.isDefaultPrevented=(d.defaultPrevented!=null?d.defaultPrevented:d.returnValue===!1)?os:jm,this.isPropagationStopped=jm,this}return b(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=os)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=os)},persist:function(){},isPersistent:os}),n}var Za={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ls=Lt(Za),Uo=b({},Za,{view:0,detail:0}),L1=Lt(Uo),kc,jc,Ho,ss=b({},Uo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Oc,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"?(kc=e.screenX-Ho.screenX,jc=e.screenY-Ho.screenY):jc=kc=0,Ho=e),kc)},movementY:function(e){return"movementY"in e?e.movementY:jc}}),_m=Lt(ss),U1=b({},ss,{dataTransfer:0}),H1=Lt(U1),B1=b({},Uo,{relatedTarget:0}),_c=Lt(B1),P1=b({},Za,{animationName:0,elapsedTime:0,pseudoElement:0}),$1=Lt(P1),q1=b({},Za,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),V1=Lt(q1),Y1=b({},Za,{data:0}),Om=Lt(Y1),G1={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},I1={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"},X1={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Q1(e){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(e):(e=X1[e])?!!n[e]:!1}function Oc(){return Q1}var K1=b({},Uo,{key:function(e){if(e.key){var n=G1[e.key]||e.key;if(n!=="Unidentified")return n}return e.type==="keypress"?(e=rs(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?I1[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Oc,charCode:function(e){return e.type==="keypress"?rs(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?rs(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Z1=Lt(K1),W1=b({},ss,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Dm=Lt(W1),F1=b({},Uo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Oc}),J1=Lt(F1),ew=b({},Za,{propertyName:0,elapsedTime:0,pseudoElement:0}),tw=Lt(ew),nw=b({},ss,{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}),aw=Lt(nw),rw=b({},Za,{newState:0,oldState:0}),ow=Lt(rw),lw=[9,13,27,32],Dc=$n&&"CompositionEvent"in window,Bo=null;$n&&"documentMode"in document&&(Bo=document.documentMode);var sw=$n&&"TextEvent"in window&&!Bo,Mm=$n&&(!Dc||Bo&&8<Bo&&11>=Bo),zm=" ",Lm=!1;function Um(e,n){switch(e){case"keyup":return lw.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Hm(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ur=!1;function iw(e,n){switch(e){case"compositionend":return Hm(n);case"keypress":return n.which!==32?null:(Lm=!0,zm);case"textInput":return e=n.data,e===zm&&Lm?null:e;default:return null}}function cw(e,n){if(Ur)return e==="compositionend"||!Dc&&Um(e,n)?(e=km(),as=Ac=da=null,Ur=!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 Mm&&n.locale!=="ko"?null:n.data;default:return null}}var uw={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 Bm(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n==="input"?!!uw[e.type]:n==="textarea"}function Pm(e,n,r,l){zr?Lr?Lr.push(l):Lr=[l]:zr=l,n=Xs(n,"onChange"),0<n.length&&(r=new ls("onChange","change",null,r,l),e.push({event:r,listeners:n}))}var Po=null,$o=null;function dw(e){xg(e,0)}function is(e){var n=Mo(e);if(wm(n))return e}function $m(e,n){if(e==="change")return n}var qm=!1;if($n){var Mc;if($n){var zc="oninput"in document;if(!zc){var Vm=document.createElement("div");Vm.setAttribute("oninput","return;"),zc=typeof Vm.oninput=="function"}Mc=zc}else Mc=!1;qm=Mc&&(!document.documentMode||9<document.documentMode)}function Ym(){Po&&(Po.detachEvent("onpropertychange",Gm),$o=Po=null)}function Gm(e){if(e.propertyName==="value"&&is($o)){var n=[];Pm(n,$o,e,Tc(e)),Am(dw,n)}}function fw(e,n,r){e==="focusin"?(Ym(),Po=n,$o=r,Po.attachEvent("onpropertychange",Gm)):e==="focusout"&&Ym()}function mw(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return is($o)}function hw(e,n){if(e==="click")return is(n)}function pw(e,n){if(e==="input"||e==="change")return is(n)}function gw(e,n){return e===n&&(e!==0||1/e===1/n)||e!==e&&n!==n}var qt=typeof Object.is=="function"?Object.is:gw;function qo(e,n){if(qt(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;var r=Object.keys(e),l=Object.keys(n);if(r.length!==l.length)return!1;for(l=0;l<r.length;l++){var i=r[l];if(!ke.call(n,i)||!qt(e[i],n[i]))return!1}return!0}function Im(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Xm(e,n){var r=Im(e);e=0;for(var l;r;){if(r.nodeType===3){if(l=e+r.textContent.length,e<=n&&l>=n)return{node:r,offset:n-e};e=l}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Im(r)}}function Qm(e,n){return e&&n?e===n?!0:e&&e.nodeType===3?!1:n&&n.nodeType===3?Qm(e,n.parentNode):"contains"in e?e.contains(n):e.compareDocumentPosition?!!(e.compareDocumentPosition(n)&16):!1:!1}function Km(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var n=ts(e.document);n instanceof e.HTMLIFrameElement;){try{var r=typeof n.contentWindow.location.href=="string"}catch{r=!1}if(r)e=n.contentWindow;else break;n=ts(e.document)}return n}function Lc(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 vw=$n&&"documentMode"in document&&11>=document.documentMode,Hr=null,Uc=null,Vo=null,Hc=!1;function Zm(e,n,r){var l=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Hc||Hr==null||Hr!==ts(l)||(l=Hr,"selectionStart"in l&&Lc(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}),Vo&&qo(Vo,l)||(Vo=l,l=Xs(Uc,"onSelect"),0<l.length&&(n=new ls("onSelect","select",null,n,r),e.push({event:n,listeners:l}),n.target=Hr)))}function Wa(e,n){var r={};return r[e.toLowerCase()]=n.toLowerCase(),r["Webkit"+e]="webkit"+n,r["Moz"+e]="moz"+n,r}var Br={animationend:Wa("Animation","AnimationEnd"),animationiteration:Wa("Animation","AnimationIteration"),animationstart:Wa("Animation","AnimationStart"),transitionrun:Wa("Transition","TransitionRun"),transitionstart:Wa("Transition","TransitionStart"),transitioncancel:Wa("Transition","TransitionCancel"),transitionend:Wa("Transition","TransitionEnd")},Bc={},Wm={};$n&&(Wm=document.createElement("div").style,"AnimationEvent"in window||(delete Br.animationend.animation,delete Br.animationiteration.animation,delete Br.animationstart.animation),"TransitionEvent"in window||delete Br.transitionend.transition);function Fa(e){if(Bc[e])return Bc[e];if(!Br[e])return e;var n=Br[e],r;for(r in n)if(n.hasOwnProperty(r)&&r in Wm)return Bc[e]=n[r];return e}var Fm=Fa("animationend"),Jm=Fa("animationiteration"),eh=Fa("animationstart"),yw=Fa("transitionrun"),bw=Fa("transitionstart"),xw=Fa("transitioncancel"),th=Fa("transitionend"),nh=new Map,Pc="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(" ");Pc.push("scrollEnd");function pn(e,n){nh.set(e,n),Ka(n,[e])}var ah=new WeakMap;function nn(e,n){if(typeof e=="object"&&e!==null){var r=ah.get(e);return r!==void 0?r:(n={value:e,source:n,stack:bm(n)},ah.set(e,n),n)}return{value:e,source:n,stack:bm(n)}}var an=[],Pr=0,$c=0;function cs(){for(var e=Pr,n=$c=Pr=0;n<e;){var r=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&&rh(r,i,d)}}function us(e,n,r,l){an[Pr++]=e,an[Pr++]=n,an[Pr++]=r,an[Pr++]=l,$c|=l,e.lanes|=l,e=e.alternate,e!==null&&(e.lanes|=l)}function qc(e,n,r,l){return us(e,n,r,l),ds(e)}function $r(e,n){return us(e,null,null,n),ds(e)}function rh(e,n,r){e.lanes|=r;var l=e.alternate;l!==null&&(l.lanes|=r);for(var i=!1,d=e.return;d!==null;)d.childLanes|=r,l=d.alternate,l!==null&&(l.childLanes|=r),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(r),e=d.hiddenUpdates,l=e[i],l===null?e[i]=[n]:l.push(n),n.lane=r|536870912),d):null}function ds(e){if(50<hl)throw hl=0,Qu=null,Error(s(185));for(var n=e.return;n!==null;)e=n,n=e.return;return e.tag===3?e.stateNode:null}var qr={};function ww(e,n,r,l){this.tag=e,this.key=r,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,r,l){return new ww(e,n,r,l)}function Vc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function qn(e,n){var r=e.alternate;return r===null?(r=Vt(e.tag,n,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=n,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&65011712,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,n=e.dependencies,r.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r.refCleanup=e.refCleanup,r}function oh(e,n){e.flags&=65011714;var r=e.alternate;return r===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=r.childLanes,e.lanes=r.lanes,e.child=r.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=r.memoizedProps,e.memoizedState=r.memoizedState,e.updateQueue=r.updateQueue,e.type=r.type,n=r.dependencies,e.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),e}function fs(e,n,r,l,i,d){var x=0;if(l=e,typeof e=="function")Vc(e)&&(x=1);else if(typeof e=="string")x=ES(e,r,F.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case oe:return e=Vt(31,r,n,i),e.elementType=oe,e.lanes=d,e;case R:return Ja(r.children,i,d,n);case E:x=8,i|=24;break;case T:return e=Vt(12,r,n,i|2),e.elementType=T,e.lanes=d,e;case H:return e=Vt(13,r,n,i),e.elementType=H,e.lanes=d,e;case I:return e=Vt(19,r,n,i),e.elementType=I,e.lanes=d,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case k:case M:x=10;break e;case A:x=9;break e;case L:x=11;break e;case G:x=14;break e;case V:x=16,l=null;break e}x=29,r=Error(s(130,e===null?"null":typeof e,"")),l=null}return n=Vt(x,r,n,i),n.elementType=e,n.type=l,n.lanes=d,n}function Ja(e,n,r,l){return e=Vt(7,e,l,n),e.lanes=r,e}function Yc(e,n,r){return e=Vt(6,e,null,n),e.lanes=r,e}function Gc(e,n,r){return n=Vt(4,e.children!==null?e.children:[],e.key,n),n.lanes=r,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}var Vr=[],Yr=0,ms=null,hs=0,rn=[],on=0,er=null,Vn=1,Yn="";function tr(e,n){Vr[Yr++]=hs,Vr[Yr++]=ms,ms=e,hs=n}function lh(e,n,r){rn[on++]=Vn,rn[on++]=Yn,rn[on++]=er,er=e;var l=Vn;e=Yn;var i=32-We(l)-1;l&=~(1<<i),r+=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,Vn=1<<32-We(n)+i|r<<i|l,Yn=d+e}else Vn=1<<d|r<<i|l,Yn=e}function Ic(e){e.return!==null&&(tr(e,1),lh(e,1,0))}function Xc(e){for(;e===ms;)ms=Vr[--Yr],Vr[Yr]=null,hs=Vr[--Yr],Vr[Yr]=null;for(;e===er;)er=rn[--on],rn[on]=null,Yn=rn[--on],rn[on]=null,Vn=rn[--on],rn[on]=null}var Dt=null,rt=null,He=!1,nr=null,Cn=!1,Qc=Error(s(519));function ar(e){var n=Error(s(418,""));throw Io(nn(n,e)),Qc}function sh(e){var n=e.stateNode,r=e.type,l=e.memoizedProps;switch(n[ct]=e,n[Ke]=l,r){case"dialog":Me("cancel",n),Me("close",n);break;case"iframe":case"object":case"embed":Me("load",n);break;case"video":case"audio":for(r=0;r<gl.length;r++)Me(gl[r],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),Sm(n,l.value,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name,!0),es(n);break;case"select":Me("invalid",n);break;case"textarea":Me("invalid",n),Nm(n,l.value,l.defaultValue,l.children),es(n)}r=l.children,typeof r!="string"&&typeof r!="number"&&typeof r!="bigint"||n.textContent===""+r||l.suppressHydrationWarning===!0||Ng(n.textContent,r)?(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=Qs),n=!0):n=!1,n||ar(e)}function ih(e){for(Dt=e.return;Dt;)switch(Dt.tag){case 5:case 13:Cn=!1;return;case 27:case 3:Cn=!0;return;default:Dt=Dt.return}}function Yo(e){if(e!==Dt)return!1;if(!He)return ih(e),He=!0,!1;var n=e.tag,r;if((r=n!==3&&n!==27)&&((r=n===5)&&(r=e.type,r=!(r!=="form"&&r!=="button")||ud(e.type,e.memoizedProps)),r=!r),r&&rt&&ar(e),ih(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(r=e.data,r==="/$"){if(n===0){rt=vn(e.nextSibling);break e}n--}else r!=="$"&&r!=="$!"&&r!=="$?"||n++;e=e.nextSibling}rt=null}}else n===27?(n=rt,Ra(e.type)?(e=hd,hd=null,rt=e):rt=n):rt=Dt?vn(e.stateNode.nextSibling):null;return!0}function Go(){rt=Dt=null,He=!1}function ch(){var e=nr;return e!==null&&(Bt===null?Bt=e:Bt.push.apply(Bt,e),nr=null),e}function Io(e){nr===null?nr=[e]:nr.push(e)}var Kc=Y(null),rr=null,Gn=null;function fa(e,n,r){X(Kc,n._currentValue),n._currentValue=r}function In(e){e._currentValue=Kc.current,ne(Kc)}function Zc(e,n,r){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===r)break;e=e.return}}function Wc(e,n,r,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 j=0;j<n.length;j++)if(w.context===n[j]){d.lanes|=r,w=d.alternate,w!==null&&(w.lanes|=r),Zc(d.return,r,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|=r,d=x.alternate,d!==null&&(d.lanes|=r),Zc(x,r,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 Xo(e,n,r,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===se.current){if(x=i.alternate,x===null)throw Error(s(387));x.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e!==null?e.push(Sl):e=[Sl])}i=i.return}e!==null&&Wc(n,e,r,l),n.flags|=262144}function ps(e){for(e=e.firstContext;e!==null;){if(!qt(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function or(e){rr=e,Gn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function jt(e){return uh(rr,e)}function gs(e,n){return rr===null&&or(e),uh(e,n)}function uh(e,n){var r=n._currentValue;if(n={context:n,memoizedValue:r,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 r}var Sw=typeof AbortController<"u"?AbortController:function(){var e=[],n=this.signal={aborted:!1,addEventListener:function(r,l){e.push(l)}};this.abort=function(){n.aborted=!0,e.forEach(function(r){return r()})}},Ew=t.unstable_scheduleCallback,Nw=t.unstable_NormalPriority,vt={$$typeof:M,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Fc(){return{controller:new Sw,data:new Map,refCount:0}}function Qo(e){e.refCount--,e.refCount===0&&Ew(Nw,function(){e.controller.abort()})}var Ko=null,Jc=0,Gr=0,Ir=null;function Tw(e,n){if(Ko===null){var r=Ko=[];Jc=0,Gr=td(),Ir={status:"pending",value:void 0,then:function(l){r.push(l)}}}return Jc++,n.then(dh,dh),n}function dh(){if(--Jc===0&&Ko!==null){Ir!==null&&(Ir.status="fulfilled");var e=Ko;Ko=null,Gr=0,Ir=null;for(var n=0;n<e.length;n++)(0,e[n])()}}function Cw(e,n){var r=[],l={status:"pending",value:null,reason:null,then:function(i){r.push(i)}};return e.then(function(){l.status="fulfilled",l.value=n;for(var i=0;i<r.length;i++)(0,r[i])(n)},function(i){for(l.status="rejected",l.reason=i,i=0;i<r.length;i++)(0,r[i])(void 0)}),l}var fh=_.S;_.S=function(e,n){typeof n=="object"&&n!==null&&typeof n.then=="function"&&Tw(e,n),fh!==null&&fh(e,n)};var lr=Y(null);function eu(){var e=lr.current;return e!==null?e:Ze.pooledCache}function vs(e,n){n===null?X(lr,lr.current):X(lr,n.pool)}function mh(){var e=eu();return e===null?null:{parent:vt._currentValue,pool:e}}var Zo=Error(s(460)),hh=Error(s(474)),ys=Error(s(542)),tu={then:function(){}};function ph(e){return e=e.status,e==="fulfilled"||e==="rejected"}function bs(){}function gh(e,n,r){switch(r=e[r],r===void 0?e.push(n):r!==n&&(n.then(bs,bs),n=r),n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,yh(e),e;default:if(typeof n.status=="string")n.then(bs,bs);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,yh(e),e}throw Wo=n,Zo}}var Wo=null;function vh(){if(Wo===null)throw Error(s(459));var e=Wo;return Wo=null,e}function yh(e){if(e===Zo||e===ys)throw Error(s(483))}var ma=!1;function nu(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function au(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 ha(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function pa(e,n,r){var l=e.updateQueue;if(l===null)return null;if(l=l.shared,(Be&2)!==0){var i=l.pending;return i===null?n.next=n:(n.next=i.next,i.next=n),l.pending=n,n=ds(e),rh(e,null,r),n}return us(e,l,n,r),ds(e)}function Fo(e,n,r){if(n=n.updateQueue,n!==null&&(n=n.shared,(r&4194048)!==0)){var l=n.lanes;l&=e.pendingLanes,r|=l,n.lanes=r,Ue(e,r)}}function ru(e,n){var r=e.updateQueue,l=e.alternate;if(l!==null&&(l=l.updateQueue,r===l)){var i=null,d=null;if(r=r.firstBaseUpdate,r!==null){do{var x={lane:r.lane,tag:r.tag,payload:r.payload,callback:null,next:null};d===null?i=d=x:d=d.next=x,r=r.next}while(r!==null);d===null?i=d=n:d=d.next=n}else i=d=n;r={baseState:l.baseState,firstBaseUpdate:i,lastBaseUpdate:d,shared:l.shared,callbacks:l.callbacks},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=n:e.next=n,r.lastBaseUpdate=n}var ou=!1;function Jo(){if(ou){var e=Ir;if(e!==null)throw e}}function el(e,n,r,l){ou=!1;var i=e.updateQueue;ma=!1;var d=i.firstBaseUpdate,x=i.lastBaseUpdate,w=i.shared.pending;if(w!==null){i.shared.pending=null;var j=w,B=j.next;j.next=null,x===null?d=B:x.next=B,x=j;var Q=e.alternate;Q!==null&&(Q=Q.updateQueue,w=Q.lastBaseUpdate,w!==x&&(w===null?Q.firstBaseUpdate=B:w.next=B,Q.lastBaseUpdate=j))}if(d!==null){var Z=i.baseState;x=0,Q=B=j=null,w=d;do{var P=w.lane&-536870913,q=P!==w.lane;if(q?(ze&P)===P:(l&P)===P){P!==0&&P===Gr&&(ou=!0),Q!==null&&(Q=Q.next={lane:0,tag:w.tag,payload:w.payload,callback:null,next:null});e:{var Ee=e,we=w;P=n;var Ye=r;switch(we.tag){case 1:if(Ee=we.payload,typeof Ee=="function"){Z=Ee.call(Ye,Z,P);break e}Z=Ee;break e;case 3:Ee.flags=Ee.flags&-65537|128;case 0:if(Ee=we.payload,P=typeof Ee=="function"?Ee.call(Ye,Z,P):Ee,P==null)break e;Z=b({},Z,P);break e;case 2:ma=!0}}P=w.callback,P!==null&&(e.flags|=64,q&&(e.flags|=8192),q=i.callbacks,q===null?i.callbacks=[P]:q.push(P))}else q={lane:P,tag:w.tag,payload:w.payload,callback:w.callback,next:null},Q===null?(B=Q=q,j=Z):Q=Q.next=q,x|=P;if(w=w.next,w===null){if(w=i.shared.pending,w===null)break;q=w,w=q.next,q.next=null,i.lastBaseUpdate=q,i.shared.pending=null}}while(!0);Q===null&&(j=Z),i.baseState=j,i.firstBaseUpdate=B,i.lastBaseUpdate=Q,d===null&&(i.shared.lanes=0),Ea|=x,e.lanes=x,e.memoizedState=Z}}function bh(e,n){if(typeof e!="function")throw Error(s(191,e));e.call(n)}function xh(e,n){var r=e.callbacks;if(r!==null)for(e.callbacks=null,e=0;e<r.length;e++)bh(r[e],n)}var Xr=Y(null),xs=Y(0);function wh(e,n){e=Jn,X(xs,e),X(Xr,n),Jn=e|n.baseLanes}function lu(){X(xs,Jn),X(Xr,Xr.current)}function su(){Jn=xs.current,ne(Xr),ne(xs)}var ga=0,je=null,qe=null,ft=null,ws=!1,Qr=!1,sr=!1,Ss=0,tl=0,Kr=null,Rw=0;function ut(){throw Error(s(321))}function iu(e,n){if(n===null)return!1;for(var r=0;r<n.length&&r<e.length;r++)if(!qt(e[r],n[r]))return!1;return!0}function cu(e,n,r,l,i,d){return ga=d,je=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,_.H=e===null||e.memoizedState===null?rp:op,sr=!1,d=r(l,i),sr=!1,Qr&&(d=Eh(n,r,l,i)),Sh(e),d}function Sh(e){_.H=As;var n=qe!==null&&qe.next!==null;if(ga=0,ft=qe=je=null,ws=!1,tl=0,Kr=null,n)throw Error(s(300));e===null||Et||(e=e.dependencies,e!==null&&ps(e)&&(Et=!0))}function Eh(e,n,r,l){je=e;var i=0;do{if(Qr&&(Kr=null),tl=0,Qr=!1,25<=i)throw Error(s(301));if(i+=1,ft=qe=null,e.updateQueue!=null){var d=e.updateQueue;d.lastEffect=null,d.events=null,d.stores=null,d.memoCache!=null&&(d.memoCache.index=0)}_.H=Mw,d=n(r,l)}while(Qr);return d}function Aw(){var e=_.H,n=e.useState()[0];return n=typeof n.then=="function"?nl(n):n,e=e.useState()[0],(qe!==null?qe.memoizedState:null)!==e&&(je.flags|=1024),n}function uu(){var e=Ss!==0;return Ss=0,e}function du(e,n,r){n.updateQueue=e.updateQueue,n.flags&=-2053,e.lanes&=~r}function fu(e){if(ws){for(e=e.memoizedState;e!==null;){var n=e.queue;n!==null&&(n.pending=null),e=e.next}ws=!1}ga=0,ft=qe=je=null,Qr=!1,tl=Ss=0,Kr=null}function Ut(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ft===null?je.memoizedState=ft=e:ft=ft.next=e,ft}function mt(){if(qe===null){var e=je.alternate;e=e!==null?e.memoizedState:null}else e=qe.next;var n=ft===null?je.memoizedState:ft.next;if(n!==null)ft=n,qe=e;else{if(e===null)throw je.alternate===null?Error(s(467)):Error(s(310));qe=e,e={memoizedState:qe.memoizedState,baseState:qe.baseState,baseQueue:qe.baseQueue,queue:qe.queue,next:null},ft===null?je.memoizedState=ft=e:ft=ft.next=e}return ft}function mu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function nl(e){var n=tl;return tl+=1,Kr===null&&(Kr=[]),e=gh(Kr,e,n),n=je,(ft===null?n.memoizedState:ft.next)===null&&(n=n.alternate,_.H=n===null||n.memoizedState===null?rp:op),e}function Es(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return nl(e);if(e.$$typeof===M)return jt(e)}throw Error(s(438,String(e)))}function hu(e){var n=null,r=je.updateQueue;if(r!==null&&(n=r.memoCache),n==null){var l=je.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}),r===null&&(r=mu(),je.updateQueue=r),r.memoCache=n,r=n.data[n.index],r===void 0)for(r=n.data[n.index]=Array(e),l=0;l<e;l++)r[l]=fe;return n.index++,r}function Xn(e,n){return typeof n=="function"?n(e):n}function Ns(e){var n=mt();return pu(n,qe,e)}function pu(e,n,r){var l=e.queue;if(l===null)throw Error(s(311));l.lastRenderedReducer=r;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,j=null,B=n,Q=!1;do{var Z=B.lane&-536870913;if(Z!==B.lane?(ze&Z)===Z:(ga&Z)===Z){var P=B.revertLane;if(P===0)j!==null&&(j=j.next={lane:0,revertLane:0,action:B.action,hasEagerState:B.hasEagerState,eagerState:B.eagerState,next:null}),Z===Gr&&(Q=!0);else if((ga&P)===P){B=B.next,P===Gr&&(Q=!0);continue}else Z={lane:0,revertLane:B.revertLane,action:B.action,hasEagerState:B.hasEagerState,eagerState:B.eagerState,next:null},j===null?(w=j=Z,x=d):j=j.next=Z,je.lanes|=P,Ea|=P;Z=B.action,sr&&r(d,Z),d=B.hasEagerState?B.eagerState:r(d,Z)}else P={lane:Z,revertLane:B.revertLane,action:B.action,hasEagerState:B.hasEagerState,eagerState:B.eagerState,next:null},j===null?(w=j=P,x=d):j=j.next=P,je.lanes|=Z,Ea|=Z;B=B.next}while(B!==null&&B!==n);if(j===null?x=d:j.next=w,!qt(d,e.memoizedState)&&(Et=!0,Q&&(r=Ir,r!==null)))throw r;e.memoizedState=d,e.baseState=x,e.baseQueue=j,l.lastRenderedState=d}return i===null&&(l.lanes=0),[e.memoizedState,l.dispatch]}function gu(e){var n=mt(),r=n.queue;if(r===null)throw Error(s(311));r.lastRenderedReducer=e;var l=r.dispatch,i=r.pending,d=n.memoizedState;if(i!==null){r.pending=null;var x=i=i.next;do d=e(d,x.action),x=x.next;while(x!==i);qt(d,n.memoizedState)||(Et=!0),n.memoizedState=d,n.baseQueue===null&&(n.baseState=d),r.lastRenderedState=d}return[d,l]}function Nh(e,n,r){var l=je,i=mt(),d=He;if(d){if(r===void 0)throw Error(s(407));r=r()}else r=n();var x=!qt((qe||i).memoizedState,r);x&&(i.memoizedState=r,Et=!0),i=i.queue;var w=Rh.bind(null,l,i,e);if(al(2048,8,w,[e]),i.getSnapshot!==n||x||ft!==null&&ft.memoizedState.tag&1){if(l.flags|=2048,Zr(9,Ts(),Ch.bind(null,l,i,r,n),null),Ze===null)throw Error(s(349));d||(ga&124)!==0||Th(l,n,r)}return r}function Th(e,n,r){e.flags|=16384,e={getSnapshot:n,value:r},n=je.updateQueue,n===null?(n=mu(),je.updateQueue=n,n.stores=[e]):(r=n.stores,r===null?n.stores=[e]:r.push(e))}function Ch(e,n,r,l){n.value=r,n.getSnapshot=l,Ah(n)&&kh(e)}function Rh(e,n,r){return r(function(){Ah(n)&&kh(e)})}function Ah(e){var n=e.getSnapshot;e=e.value;try{var r=n();return!qt(e,r)}catch{return!0}}function kh(e){var n=$r(e,2);n!==null&&Qt(n,e,2)}function vu(e){var n=Ut();if(typeof e=="function"){var r=e;if(e=r(),sr){Mt(!0);try{r()}finally{Mt(!1)}}}return n.memoizedState=n.baseState=e,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xn,lastRenderedState:e},n}function jh(e,n,r,l){return e.baseState=r,pu(e,qe,typeof l=="function"?l:Xn)}function kw(e,n,r,l,i){if(Rs(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)}};_.T!==null?r(!0):d.isTransition=!1,l(d),r=n.pending,r===null?(d.next=n.pending=d,_h(n,d)):(d.next=r.next,n.pending=r.next=d)}}function _h(e,n){var r=n.action,l=n.payload,i=e.state;if(n.isTransition){var d=_.T,x={};_.T=x;try{var w=r(i,l),j=_.S;j!==null&&j(x,w),Oh(e,n,w)}catch(B){yu(e,n,B)}finally{_.T=d}}else try{d=r(i,l),Oh(e,n,d)}catch(B){yu(e,n,B)}}function Oh(e,n,r){r!==null&&typeof r=="object"&&typeof r.then=="function"?r.then(function(l){Dh(e,n,l)},function(l){return yu(e,n,l)}):Dh(e,n,r)}function Dh(e,n,r){n.status="fulfilled",n.value=r,Mh(n),e.state=r,n=e.pending,n!==null&&(r=n.next,r===n?e.pending=null:(r=r.next,n.next=r,_h(e,r)))}function yu(e,n,r){var l=e.pending;if(e.pending=null,l!==null){l=l.next;do n.status="rejected",n.reason=r,Mh(n),n=n.next;while(n!==l)}e.action=null}function Mh(e){e=e.listeners;for(var n=0;n<e.length;n++)(0,e[n])()}function zh(e,n){return n}function Lh(e,n){if(He){var r=Ze.formState;if(r!==null){e:{var l=je;if(He){if(rt){t:{for(var i=rt,d=Cn;i.nodeType!==8;){if(!d){i=null;break t}if(i=vn(i.nextSibling),i===null){i=null;break t}}d=i.data,i=d==="F!"||d==="F"?i:null}if(i){rt=vn(i.nextSibling),l=i.data==="F!";break e}}ar(l)}l=!1}l&&(n=r[0])}}return r=Ut(),r.memoizedState=r.baseState=n,l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:zh,lastRenderedState:n},r.queue=l,r=tp.bind(null,je,l),l.dispatch=r,l=vu(!1),d=Eu.bind(null,je,!1,l.queue),l=Ut(),i={state:n,dispatch:null,action:e,pending:null},l.queue=i,r=kw.bind(null,je,i,d,r),i.dispatch=r,l.memoizedState=e,[n,r,!1]}function Uh(e){var n=mt();return Hh(n,qe,e)}function Hh(e,n,r){if(n=pu(e,n,zh)[0],e=Ns(Xn)[0],typeof n=="object"&&n!==null&&typeof n.then=="function")try{var l=nl(n)}catch(x){throw x===Zo?ys:x}else l=n;n=mt();var i=n.queue,d=i.dispatch;return r!==n.memoizedState&&(je.flags|=2048,Zr(9,Ts(),jw.bind(null,i,r),null)),[l,d,e]}function jw(e,n){e.action=n}function Bh(e){var n=mt(),r=qe;if(r!==null)return Hh(n,r,e);mt(),n=n.memoizedState,r=mt();var l=r.queue.dispatch;return r.memoizedState=e,[n,l,!1]}function Zr(e,n,r,l){return e={tag:e,create:r,deps:l,inst:n,next:null},n=je.updateQueue,n===null&&(n=mu(),je.updateQueue=n),r=n.lastEffect,r===null?n.lastEffect=e.next=e:(l=r.next,r.next=e,e.next=l,n.lastEffect=e),e}function Ts(){return{destroy:void 0,resource:void 0}}function Ph(){return mt().memoizedState}function Cs(e,n,r,l){var i=Ut();l=l===void 0?null:l,je.flags|=e,i.memoizedState=Zr(1|n,Ts(),r,l)}function al(e,n,r,l){var i=mt();l=l===void 0?null:l;var d=i.memoizedState.inst;qe!==null&&l!==null&&iu(l,qe.memoizedState.deps)?i.memoizedState=Zr(n,d,r,l):(je.flags|=e,i.memoizedState=Zr(1|n,d,r,l))}function $h(e,n){Cs(8390656,8,e,n)}function qh(e,n){al(2048,8,e,n)}function Vh(e,n){return al(4,2,e,n)}function Yh(e,n){return al(4,4,e,n)}function Gh(e,n){if(typeof n=="function"){e=e();var r=n(e);return function(){typeof r=="function"?r():n(null)}}if(n!=null)return e=e(),n.current=e,function(){n.current=null}}function Ih(e,n,r){r=r!=null?r.concat([e]):null,al(4,4,Gh.bind(null,n,e),r)}function bu(){}function Xh(e,n){var r=mt();n=n===void 0?null:n;var l=r.memoizedState;return n!==null&&iu(n,l[1])?l[0]:(r.memoizedState=[e,n],e)}function Qh(e,n){var r=mt();n=n===void 0?null:n;var l=r.memoizedState;if(n!==null&&iu(n,l[1]))return l[0];if(l=e(),sr){Mt(!0);try{e()}finally{Mt(!1)}}return r.memoizedState=[l,n],l}function xu(e,n,r){return r===void 0||(ga&1073741824)!==0?e.memoizedState=n:(e.memoizedState=r,e=Wp(),je.lanes|=e,Ea|=e,r)}function Kh(e,n,r,l){return qt(r,n)?r:Xr.current!==null?(e=xu(e,r,l),qt(e,n)||(Et=!0),e):(ga&42)===0?(Et=!0,e.memoizedState=r):(e=Wp(),je.lanes|=e,Ea|=e,n)}function Zh(e,n,r,l,i){var d=$.p;$.p=d!==0&&8>d?d:8;var x=_.T,w={};_.T=w,Eu(e,!1,n,r);try{var j=i(),B=_.S;if(B!==null&&B(w,j),j!==null&&typeof j=="object"&&typeof j.then=="function"){var Q=Cw(j,l);rl(e,n,Q,Xt(e))}else rl(e,n,l,Xt(e))}catch(Z){rl(e,n,{then:function(){},status:"rejected",reason:Z},Xt())}finally{$.p=d,_.T=x}}function _w(){}function wu(e,n,r,l){if(e.tag!==5)throw Error(s(476));var i=Wh(e).queue;Zh(e,i,n,O,r===null?_w:function(){return Fh(e),r(l)})}function Wh(e){var n=e.memoizedState;if(n!==null)return n;n={memoizedState:O,baseState:O,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xn,lastRenderedState:O},next:null};var r={};return n.next={memoizedState:r,baseState:r,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xn,lastRenderedState:r},next:null},e.memoizedState=n,e=e.alternate,e!==null&&(e.memoizedState=n),n}function Fh(e){var n=Wh(e).next.queue;rl(e,n,{},Xt())}function Su(){return jt(Sl)}function Jh(){return mt().memoizedState}function ep(){return mt().memoizedState}function Ow(e){for(var n=e.return;n!==null;){switch(n.tag){case 24:case 3:var r=Xt();e=ha(r);var l=pa(n,e,r);l!==null&&(Qt(l,n,r),Fo(l,n,r)),n={cache:Fc()},e.payload=n;return}n=n.return}}function Dw(e,n,r){var l=Xt();r={lane:l,revertLane:0,action:r,hasEagerState:!1,eagerState:null,next:null},Rs(e)?np(n,r):(r=qc(e,n,r,l),r!==null&&(Qt(r,e,l),ap(r,n,l)))}function tp(e,n,r){var l=Xt();rl(e,n,r,l)}function rl(e,n,r,l){var i={lane:l,revertLane:0,action:r,hasEagerState:!1,eagerState:null,next:null};if(Rs(e))np(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,r);if(i.hasEagerState=!0,i.eagerState=w,qt(w,x))return us(e,n,i,0),Ze===null&&cs(),!1}catch{}if(r=qc(e,n,i,l),r!==null)return Qt(r,e,l),ap(r,n,l),!0}return!1}function Eu(e,n,r,l){if(l={lane:2,revertLane:td(),action:l,hasEagerState:!1,eagerState:null,next:null},Rs(e)){if(n)throw Error(s(479))}else n=qc(e,r,l,2),n!==null&&Qt(n,e,2)}function Rs(e){var n=e.alternate;return e===je||n!==null&&n===je}function np(e,n){Qr=ws=!0;var r=e.pending;r===null?n.next=n:(n.next=r.next,r.next=n),e.pending=n}function ap(e,n,r){if((r&4194048)!==0){var l=n.lanes;l&=e.pendingLanes,r|=l,n.lanes=r,Ue(e,r)}}var As={readContext:jt,use:Es,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},rp={readContext:jt,use:Es,useCallback:function(e,n){return Ut().memoizedState=[e,n===void 0?null:n],e},useContext:jt,useEffect:$h,useImperativeHandle:function(e,n,r){r=r!=null?r.concat([e]):null,Cs(4194308,4,Gh.bind(null,n,e),r)},useLayoutEffect:function(e,n){return Cs(4194308,4,e,n)},useInsertionEffect:function(e,n){Cs(4,2,e,n)},useMemo:function(e,n){var r=Ut();n=n===void 0?null:n;var l=e();if(sr){Mt(!0);try{e()}finally{Mt(!1)}}return r.memoizedState=[l,n],l},useReducer:function(e,n,r){var l=Ut();if(r!==void 0){var i=r(n);if(sr){Mt(!0);try{r(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=Dw.bind(null,je,e),[l.memoizedState,e]},useRef:function(e){var n=Ut();return e={current:e},n.memoizedState=e},useState:function(e){e=vu(e);var n=e.queue,r=tp.bind(null,je,n);return n.dispatch=r,[e.memoizedState,r]},useDebugValue:bu,useDeferredValue:function(e,n){var r=Ut();return xu(r,e,n)},useTransition:function(){var e=vu(!1);return e=Zh.bind(null,je,e.queue,!0,!1),Ut().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,n,r){var l=je,i=Ut();if(He){if(r===void 0)throw Error(s(407));r=r()}else{if(r=n(),Ze===null)throw Error(s(349));(ze&124)!==0||Th(l,n,r)}i.memoizedState=r;var d={value:r,getSnapshot:n};return i.queue=d,$h(Rh.bind(null,l,d,e),[e]),l.flags|=2048,Zr(9,Ts(),Ch.bind(null,l,d,r,n),null),r},useId:function(){var e=Ut(),n=Ze.identifierPrefix;if(He){var r=Yn,l=Vn;r=(l&~(1<<32-We(l)-1)).toString(32)+r,n="«"+n+"R"+r,r=Ss++,0<r&&(n+="H"+r.toString(32)),n+="»"}else r=Rw++,n="«"+n+"r"+r.toString(32)+"»";return e.memoizedState=n},useHostTransitionStatus:Su,useFormState:Lh,useActionState:Lh,useOptimistic:function(e){var n=Ut();n.memoizedState=n.baseState=e;var r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=r,n=Eu.bind(null,je,!0,r),r.dispatch=n,[e,n]},useMemoCache:hu,useCacheRefresh:function(){return Ut().memoizedState=Ow.bind(null,je)}},op={readContext:jt,use:Es,useCallback:Xh,useContext:jt,useEffect:qh,useImperativeHandle:Ih,useInsertionEffect:Vh,useLayoutEffect:Yh,useMemo:Qh,useReducer:Ns,useRef:Ph,useState:function(){return Ns(Xn)},useDebugValue:bu,useDeferredValue:function(e,n){var r=mt();return Kh(r,qe.memoizedState,e,n)},useTransition:function(){var e=Ns(Xn)[0],n=mt().memoizedState;return[typeof e=="boolean"?e:nl(e),n]},useSyncExternalStore:Nh,useId:Jh,useHostTransitionStatus:Su,useFormState:Uh,useActionState:Uh,useOptimistic:function(e,n){var r=mt();return jh(r,qe,e,n)},useMemoCache:hu,useCacheRefresh:ep},Mw={readContext:jt,use:Es,useCallback:Xh,useContext:jt,useEffect:qh,useImperativeHandle:Ih,useInsertionEffect:Vh,useLayoutEffect:Yh,useMemo:Qh,useReducer:gu,useRef:Ph,useState:function(){return gu(Xn)},useDebugValue:bu,useDeferredValue:function(e,n){var r=mt();return qe===null?xu(r,e,n):Kh(r,qe.memoizedState,e,n)},useTransition:function(){var e=gu(Xn)[0],n=mt().memoizedState;return[typeof e=="boolean"?e:nl(e),n]},useSyncExternalStore:Nh,useId:Jh,useHostTransitionStatus:Su,useFormState:Bh,useActionState:Bh,useOptimistic:function(e,n){var r=mt();return qe!==null?jh(r,qe,e,n):(r.baseState=e,[e,r.queue.dispatch])},useMemoCache:hu,useCacheRefresh:ep},Wr=null,ol=0;function ks(e){var n=ol;return ol+=1,Wr===null&&(Wr=[]),gh(Wr,e,n)}function ll(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 lp(e){var n=e._init;return n(e._payload)}function sp(e){function n(z,D){if(e){var U=z.deletions;U===null?(z.deletions=[D],z.flags|=16):U.push(D)}}function r(z,D){if(!e)return null;for(;D!==null;)n(z,D),D=D.sibling;return null}function l(z){for(var D=new Map;z!==null;)z.key!==null?D.set(z.key,z):D.set(z.index,z),z=z.sibling;return D}function i(z,D){return z=qn(z,D),z.index=0,z.sibling=null,z}function d(z,D,U){return z.index=U,e?(U=z.alternate,U!==null?(U=U.index,U<D?(z.flags|=67108866,D):U):(z.flags|=67108866,D)):(z.flags|=1048576,D)}function x(z){return e&&z.alternate===null&&(z.flags|=67108866),z}function w(z,D,U,K){return D===null||D.tag!==6?(D=Yc(U,z.mode,K),D.return=z,D):(D=i(D,U),D.return=z,D)}function j(z,D,U,K){var he=U.type;return he===R?Q(z,D,U.props.children,K,U.key):D!==null&&(D.elementType===he||typeof he=="object"&&he!==null&&he.$$typeof===V&&lp(he)===D.type)?(D=i(D,U.props),ll(D,U),D.return=z,D):(D=fs(U.type,U.key,U.props,null,z.mode,K),ll(D,U),D.return=z,D)}function B(z,D,U,K){return D===null||D.tag!==4||D.stateNode.containerInfo!==U.containerInfo||D.stateNode.implementation!==U.implementation?(D=Gc(U,z.mode,K),D.return=z,D):(D=i(D,U.children||[]),D.return=z,D)}function Q(z,D,U,K,he){return D===null||D.tag!==7?(D=Ja(U,z.mode,K,he),D.return=z,D):(D=i(D,U),D.return=z,D)}function Z(z,D,U){if(typeof D=="string"&&D!==""||typeof D=="number"||typeof D=="bigint")return D=Yc(""+D,z.mode,U),D.return=z,D;if(typeof D=="object"&&D!==null){switch(D.$$typeof){case S:return U=fs(D.type,D.key,D.props,null,z.mode,U),ll(U,D),U.return=z,U;case C:return D=Gc(D,z.mode,U),D.return=z,D;case V:var K=D._init;return D=K(D._payload),Z(z,D,U)}if(re(D)||ie(D))return D=Ja(D,z.mode,U,null),D.return=z,D;if(typeof D.then=="function")return Z(z,ks(D),U);if(D.$$typeof===M)return Z(z,gs(z,D),U);js(z,D)}return null}function P(z,D,U,K){var he=D!==null?D.key:null;if(typeof U=="string"&&U!==""||typeof U=="number"||typeof U=="bigint")return he!==null?null:w(z,D,""+U,K);if(typeof U=="object"&&U!==null){switch(U.$$typeof){case S:return U.key===he?j(z,D,U,K):null;case C:return U.key===he?B(z,D,U,K):null;case V:return he=U._init,U=he(U._payload),P(z,D,U,K)}if(re(U)||ie(U))return he!==null?null:Q(z,D,U,K,null);if(typeof U.then=="function")return P(z,D,ks(U),K);if(U.$$typeof===M)return P(z,D,gs(z,U),K);js(z,U)}return null}function q(z,D,U,K,he){if(typeof K=="string"&&K!==""||typeof K=="number"||typeof K=="bigint")return z=z.get(U)||null,w(D,z,""+K,he);if(typeof K=="object"&&K!==null){switch(K.$$typeof){case S:return z=z.get(K.key===null?U:K.key)||null,j(D,z,K,he);case C:return z=z.get(K.key===null?U:K.key)||null,B(D,z,K,he);case V:var Oe=K._init;return K=Oe(K._payload),q(z,D,U,K,he)}if(re(K)||ie(K))return z=z.get(U)||null,Q(D,z,K,he,null);if(typeof K.then=="function")return q(z,D,U,ks(K),he);if(K.$$typeof===M)return q(z,D,U,gs(D,K),he);js(D,K)}return null}function Ee(z,D,U,K){for(var he=null,Oe=null,ye=D,Se=D=0,Tt=null;ye!==null&&Se<U.length;Se++){ye.index>Se?(Tt=ye,ye=null):Tt=ye.sibling;var Le=P(z,ye,U[Se],K);if(Le===null){ye===null&&(ye=Tt);break}e&&ye&&Le.alternate===null&&n(z,ye),D=d(Le,D,Se),Oe===null?he=Le:Oe.sibling=Le,Oe=Le,ye=Tt}if(Se===U.length)return r(z,ye),He&&tr(z,Se),he;if(ye===null){for(;Se<U.length;Se++)ye=Z(z,U[Se],K),ye!==null&&(D=d(ye,D,Se),Oe===null?he=ye:Oe.sibling=ye,Oe=ye);return He&&tr(z,Se),he}for(ye=l(ye);Se<U.length;Se++)Tt=q(ye,z,Se,U[Se],K),Tt!==null&&(e&&Tt.alternate!==null&&ye.delete(Tt.key===null?Se:Tt.key),D=d(Tt,D,Se),Oe===null?he=Tt:Oe.sibling=Tt,Oe=Tt);return e&&ye.forEach(function(Oa){return n(z,Oa)}),He&&tr(z,Se),he}function we(z,D,U,K){if(U==null)throw Error(s(151));for(var he=null,Oe=null,ye=D,Se=D=0,Tt=null,Le=U.next();ye!==null&&!Le.done;Se++,Le=U.next()){ye.index>Se?(Tt=ye,ye=null):Tt=ye.sibling;var Oa=P(z,ye,Le.value,K);if(Oa===null){ye===null&&(ye=Tt);break}e&&ye&&Oa.alternate===null&&n(z,ye),D=d(Oa,D,Se),Oe===null?he=Oa:Oe.sibling=Oa,Oe=Oa,ye=Tt}if(Le.done)return r(z,ye),He&&tr(z,Se),he;if(ye===null){for(;!Le.done;Se++,Le=U.next())Le=Z(z,Le.value,K),Le!==null&&(D=d(Le,D,Se),Oe===null?he=Le:Oe.sibling=Le,Oe=Le);return He&&tr(z,Se),he}for(ye=l(ye);!Le.done;Se++,Le=U.next())Le=q(ye,z,Se,Le.value,K),Le!==null&&(e&&Le.alternate!==null&&ye.delete(Le.key===null?Se:Le.key),D=d(Le,D,Se),Oe===null?he=Le:Oe.sibling=Le,Oe=Le);return e&&ye.forEach(function(zS){return n(z,zS)}),He&&tr(z,Se),he}function Ye(z,D,U,K){if(typeof U=="object"&&U!==null&&U.type===R&&U.key===null&&(U=U.props.children),typeof U=="object"&&U!==null){switch(U.$$typeof){case S:e:{for(var he=U.key;D!==null;){if(D.key===he){if(he=U.type,he===R){if(D.tag===7){r(z,D.sibling),K=i(D,U.props.children),K.return=z,z=K;break e}}else if(D.elementType===he||typeof he=="object"&&he!==null&&he.$$typeof===V&&lp(he)===D.type){r(z,D.sibling),K=i(D,U.props),ll(K,U),K.return=z,z=K;break e}r(z,D);break}else n(z,D);D=D.sibling}U.type===R?(K=Ja(U.props.children,z.mode,K,U.key),K.return=z,z=K):(K=fs(U.type,U.key,U.props,null,z.mode,K),ll(K,U),K.return=z,z=K)}return x(z);case C:e:{for(he=U.key;D!==null;){if(D.key===he)if(D.tag===4&&D.stateNode.containerInfo===U.containerInfo&&D.stateNode.implementation===U.implementation){r(z,D.sibling),K=i(D,U.children||[]),K.return=z,z=K;break e}else{r(z,D);break}else n(z,D);D=D.sibling}K=Gc(U,z.mode,K),K.return=z,z=K}return x(z);case V:return he=U._init,U=he(U._payload),Ye(z,D,U,K)}if(re(U))return Ee(z,D,U,K);if(ie(U)){if(he=ie(U),typeof he!="function")throw Error(s(150));return U=he.call(U),we(z,D,U,K)}if(typeof U.then=="function")return Ye(z,D,ks(U),K);if(U.$$typeof===M)return Ye(z,D,gs(z,U),K);js(z,U)}return typeof U=="string"&&U!==""||typeof U=="number"||typeof U=="bigint"?(U=""+U,D!==null&&D.tag===6?(r(z,D.sibling),K=i(D,U),K.return=z,z=K):(r(z,D),K=Yc(U,z.mode,K),K.return=z,z=K),x(z)):r(z,D)}return function(z,D,U,K){try{ol=0;var he=Ye(z,D,U,K);return Wr=null,he}catch(ye){if(ye===Zo||ye===ys)throw ye;var Oe=Vt(29,ye,null,z.mode);return Oe.lanes=K,Oe.return=z,Oe}}}var Fr=sp(!0),ip=sp(!1),ln=Y(null),Rn=null;function va(e){var n=e.alternate;X(yt,yt.current&1),X(ln,e),Rn===null&&(n===null||Xr.current!==null||n.memoizedState!==null)&&(Rn=e)}function cp(e){if(e.tag===22){if(X(yt,yt.current),X(ln,e),Rn===null){var n=e.alternate;n!==null&&n.memoizedState!==null&&(Rn=e)}}else ya()}function ya(){X(yt,yt.current),X(ln,ln.current)}function Qn(e){ne(ln),Rn===e&&(Rn=null),ne(yt)}var yt=Y(0);function _s(e){for(var n=e;n!==null;){if(n.tag===13){var r=n.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||md(r)))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 Nu(e,n,r,l){n=e.memoizedState,r=r(l,n),r=r==null?n:b({},n,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var Tu={enqueueSetState:function(e,n,r){e=e._reactInternals;var l=Xt(),i=ha(l);i.payload=n,r!=null&&(i.callback=r),n=pa(e,i,l),n!==null&&(Qt(n,e,l),Fo(n,e,l))},enqueueReplaceState:function(e,n,r){e=e._reactInternals;var l=Xt(),i=ha(l);i.tag=1,i.payload=n,r!=null&&(i.callback=r),n=pa(e,i,l),n!==null&&(Qt(n,e,l),Fo(n,e,l))},enqueueForceUpdate:function(e,n){e=e._reactInternals;var r=Xt(),l=ha(r);l.tag=2,n!=null&&(l.callback=n),n=pa(e,l,r),n!==null&&(Qt(n,e,r),Fo(n,e,r))}};function up(e,n,r,l,i,d,x){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(l,d,x):n.prototype&&n.prototype.isPureReactComponent?!qo(r,l)||!qo(i,d):!0}function dp(e,n,r,l){e=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(r,l),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(r,l),n.state!==e&&Tu.enqueueReplaceState(n,n.state,null)}function ir(e,n){var r=n;if("ref"in n){r={};for(var l in n)l!=="ref"&&(r[l]=n[l])}if(e=e.defaultProps){r===n&&(r=b({},r));for(var i in e)r[i]===void 0&&(r[i]=e[i])}return r}var Os=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 fp(e){Os(e)}function mp(e){console.error(e)}function hp(e){Os(e)}function Ds(e,n){try{var r=e.onUncaughtError;r(n.value,{componentStack:n.stack})}catch(l){setTimeout(function(){throw l})}}function pp(e,n,r){try{var l=e.onCaughtError;l(r.value,{componentStack:r.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(i){setTimeout(function(){throw i})}}function Cu(e,n,r){return r=ha(r),r.tag=3,r.payload={element:null},r.callback=function(){Ds(e,n)},r}function gp(e){return e=ha(e),e.tag=3,e}function vp(e,n,r,l){var i=r.type.getDerivedStateFromError;if(typeof i=="function"){var d=l.value;e.payload=function(){return i(d)},e.callback=function(){pp(n,r,l)}}var x=r.stateNode;x!==null&&typeof x.componentDidCatch=="function"&&(e.callback=function(){pp(n,r,l),typeof i!="function"&&(Na===null?Na=new Set([this]):Na.add(this));var w=l.stack;this.componentDidCatch(l.value,{componentStack:w!==null?w:""})})}function zw(e,n,r,l,i){if(r.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){if(n=r.alternate,n!==null&&Xo(n,r,i,!0),r=ln.current,r!==null){switch(r.tag){case 13:return Rn===null?Zu():r.alternate===null&&ot===0&&(ot=3),r.flags&=-257,r.flags|=65536,r.lanes=i,l===tu?r.flags|=16384:(n=r.updateQueue,n===null?r.updateQueue=new Set([l]):n.add(l),Fu(e,l,i)),!1;case 22:return r.flags|=65536,l===tu?r.flags|=16384:(n=r.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([l])},r.updateQueue=n):(r=n.retryQueue,r===null?n.retryQueue=new Set([l]):r.add(l)),Fu(e,l,i)),!1}throw Error(s(435,r.tag))}return Fu(e,l,i),Zu(),!1}if(He)return n=ln.current,n!==null?((n.flags&65536)===0&&(n.flags|=256),n.flags|=65536,n.lanes=i,l!==Qc&&(e=Error(s(422),{cause:l}),Io(nn(e,r)))):(l!==Qc&&(n=Error(s(423),{cause:l}),Io(nn(n,r))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,l=nn(l,r),i=Cu(e.stateNode,l,i),ru(e,i),ot!==4&&(ot=2)),!1;var d=Error(s(520),{cause:l});if(d=nn(d,r),ml===null?ml=[d]:ml.push(d),ot!==4&&(ot=2),n===null)return!0;l=nn(l,r),r=n;do{switch(r.tag){case 3:return r.flags|=65536,e=i&-i,r.lanes|=e,e=Cu(r.stateNode,l,e),ru(r,e),!1;case 1:if(n=r.type,d=r.stateNode,(r.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||d!==null&&typeof d.componentDidCatch=="function"&&(Na===null||!Na.has(d))))return r.flags|=65536,i&=-i,r.lanes|=i,i=gp(i),vp(i,e,r,l),ru(r,i),!1}r=r.return}while(r!==null);return!1}var yp=Error(s(461)),Et=!1;function Rt(e,n,r,l){n.child=e===null?ip(n,null,r,l):Fr(n,e.child,r,l)}function bp(e,n,r,l,i){r=r.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 or(n),l=cu(e,n,r,x,d,i),w=uu(),e!==null&&!Et?(du(e,n,i),Kn(e,n,i)):(He&&w&&Ic(n),n.flags|=1,Rt(e,n,l,i),n.child)}function xp(e,n,r,l,i){if(e===null){var d=r.type;return typeof d=="function"&&!Vc(d)&&d.defaultProps===void 0&&r.compare===null?(n.tag=15,n.type=d,wp(e,n,d,l,i)):(e=fs(r.type,null,l,n,n.mode,i),e.ref=n.ref,e.return=n,n.child=e)}if(d=e.child,!Mu(e,i)){var x=d.memoizedProps;if(r=r.compare,r=r!==null?r:qo,r(x,l)&&e.ref===n.ref)return Kn(e,n,i)}return n.flags|=1,e=qn(d,l),e.ref=n.ref,e.return=n,n.child=e}function wp(e,n,r,l,i){if(e!==null){var d=e.memoizedProps;if(qo(d,l)&&e.ref===n.ref)if(Et=!1,n.pendingProps=l=d,Mu(e,i))(e.flags&131072)!==0&&(Et=!0);else return n.lanes=e.lanes,Kn(e,n,i)}return Ru(e,n,r,l,i)}function Sp(e,n,r){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|r:r,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 Ep(e,n,l,r)}if((r&536870912)!==0)n.memoizedState={baseLanes:0,cachePool:null},e!==null&&vs(n,d!==null?d.cachePool:null),d!==null?wh(n,d):lu(),cp(n);else return n.lanes=n.childLanes=536870912,Ep(e,n,d!==null?d.baseLanes|r:r,r)}else d!==null?(vs(n,d.cachePool),wh(n,d),ya(),n.memoizedState=null):(e!==null&&vs(n,null),lu(),ya());return Rt(e,n,i,r),n.child}function Ep(e,n,r,l){var i=eu();return i=i===null?null:{parent:vt._currentValue,pool:i},n.memoizedState={baseLanes:r,cachePool:i},e!==null&&vs(n,null),lu(),cp(n),e!==null&&Xo(e,n,l,!0),null}function Ms(e,n){var r=n.ref;if(r===null)e!==null&&e.ref!==null&&(n.flags|=4194816);else{if(typeof r!="function"&&typeof r!="object")throw Error(s(284));(e===null||e.ref!==r)&&(n.flags|=4194816)}}function Ru(e,n,r,l,i){return or(n),r=cu(e,n,r,l,void 0,i),l=uu(),e!==null&&!Et?(du(e,n,i),Kn(e,n,i)):(He&&l&&Ic(n),n.flags|=1,Rt(e,n,r,i),n.child)}function Np(e,n,r,l,i,d){return or(n),n.updateQueue=null,r=Eh(n,l,r,i),Sh(e),l=uu(),e!==null&&!Et?(du(e,n,d),Kn(e,n,d)):(He&&l&&Ic(n),n.flags|=1,Rt(e,n,r,d),n.child)}function Tp(e,n,r,l,i){if(or(n),n.stateNode===null){var d=qr,x=r.contextType;typeof x=="object"&&x!==null&&(d=jt(x)),d=new r(l,d),n.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,d.updater=Tu,n.stateNode=d,d._reactInternals=n,d=n.stateNode,d.props=l,d.state=n.memoizedState,d.refs={},nu(n),x=r.contextType,d.context=typeof x=="object"&&x!==null?jt(x):qr,d.state=n.memoizedState,x=r.getDerivedStateFromProps,typeof x=="function"&&(Nu(n,r,x,l),d.state=n.memoizedState),typeof r.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&&Tu.enqueueReplaceState(d,d.state,null),el(n,l,d,i),Jo(),d.state=n.memoizedState),typeof d.componentDidMount=="function"&&(n.flags|=4194308),l=!0}else if(e===null){d=n.stateNode;var w=n.memoizedProps,j=ir(r,w);d.props=j;var B=d.context,Q=r.contextType;x=qr,typeof Q=="object"&&Q!==null&&(x=jt(Q));var Z=r.getDerivedStateFromProps;Q=typeof Z=="function"||typeof d.getSnapshotBeforeUpdate=="function",w=n.pendingProps!==w,Q||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(w||B!==x)&&dp(n,d,l,x),ma=!1;var P=n.memoizedState;d.state=P,el(n,l,d,i),Jo(),B=n.memoizedState,w||P!==B||ma?(typeof Z=="function"&&(Nu(n,r,Z,l),B=n.memoizedState),(j=ma||up(n,r,j,l,P,B,x))?(Q||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=j):(typeof d.componentDidMount=="function"&&(n.flags|=4194308),l=!1)}else{d=n.stateNode,au(e,n),x=n.memoizedProps,Q=ir(r,x),d.props=Q,Z=n.pendingProps,P=d.context,B=r.contextType,j=qr,typeof B=="object"&&B!==null&&(j=jt(B)),w=r.getDerivedStateFromProps,(B=typeof w=="function"||typeof d.getSnapshotBeforeUpdate=="function")||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(x!==Z||P!==j)&&dp(n,d,l,j),ma=!1,P=n.memoizedState,d.state=P,el(n,l,d,i),Jo();var q=n.memoizedState;x!==Z||P!==q||ma||e!==null&&e.dependencies!==null&&ps(e.dependencies)?(typeof w=="function"&&(Nu(n,r,w,l),q=n.memoizedState),(Q=ma||up(n,r,Q,l,P,q,j)||e!==null&&e.dependencies!==null&&ps(e.dependencies))?(B||typeof d.UNSAFE_componentWillUpdate!="function"&&typeof d.componentWillUpdate!="function"||(typeof d.componentWillUpdate=="function"&&d.componentWillUpdate(l,q,j),typeof d.UNSAFE_componentWillUpdate=="function"&&d.UNSAFE_componentWillUpdate(l,q,j)),typeof d.componentDidUpdate=="function"&&(n.flags|=4),typeof d.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof d.componentDidUpdate!="function"||x===e.memoizedProps&&P===e.memoizedState||(n.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||x===e.memoizedProps&&P===e.memoizedState||(n.flags|=1024),n.memoizedProps=l,n.memoizedState=q),d.props=l,d.state=q,d.context=j,l=Q):(typeof d.componentDidUpdate!="function"||x===e.memoizedProps&&P===e.memoizedState||(n.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||x===e.memoizedProps&&P===e.memoizedState||(n.flags|=1024),l=!1)}return d=l,Ms(e,n),l=(n.flags&128)!==0,d||l?(d=n.stateNode,r=l&&typeof r.getDerivedStateFromError!="function"?null:d.render(),n.flags|=1,e!==null&&l?(n.child=Fr(n,e.child,null,i),n.child=Fr(n,null,r,i)):Rt(e,n,r,i),n.memoizedState=d.state,e=n.child):e=Kn(e,n,i),e}function Cp(e,n,r,l){return Go(),n.flags|=256,Rt(e,n,r,l),n.child}var Au={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function ku(e){return{baseLanes:e,cachePool:mh()}}function ju(e,n,r){return e=e!==null?e.childLanes&~r:0,n&&(e|=sn),e}function Rp(e,n,r){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(He){if(i?va(n):ya(),He){var w=rt,j;if(j=w){e:{for(j=w,w=Cn;j.nodeType!==8;){if(!w){w=null;break e}if(j=vn(j.nextSibling),j===null){w=null;break e}}w=j}w!==null?(n.memoizedState={dehydrated:w,treeContext:er!==null?{id:Vn,overflow:Yn}:null,retryLane:536870912,hydrationErrors:null},j=Vt(18,null,null,0),j.stateNode=w,j.return=n,n.child=j,Dt=n,rt=null,j=!0):j=!1}j||ar(n)}if(w=n.memoizedState,w!==null&&(w=w.dehydrated,w!==null))return md(w)?n.lanes=32:n.lanes=536870912,null;Qn(n)}return w=l.children,l=l.fallback,i?(ya(),i=n.mode,w=zs({mode:"hidden",children:w},i),l=Ja(l,i,r,null),w.return=n,l.return=n,w.sibling=l,n.child=w,i=n.child,i.memoizedState=ku(r),i.childLanes=ju(e,x,r),n.memoizedState=Au,l):(va(n),_u(n,w))}if(j=e.memoizedState,j!==null&&(w=j.dehydrated,w!==null)){if(d)n.flags&256?(va(n),n.flags&=-257,n=Ou(e,n,r)):n.memoizedState!==null?(ya(),n.child=e.child,n.flags|=128,n=null):(ya(),i=l.fallback,w=n.mode,l=zs({mode:"visible",children:l.children},w),i=Ja(i,w,r,null),i.flags|=2,l.return=n,i.return=n,l.sibling=i,n.child=l,Fr(n,e.child,null,r),l=n.child,l.memoizedState=ku(r),l.childLanes=ju(e,x,r),n.memoizedState=Au,n=i);else if(va(n),md(w)){if(x=w.nextSibling&&w.nextSibling.dataset,x)var B=x.dgst;x=B,l=Error(s(419)),l.stack="",l.digest=x,Io({value:l,source:null,stack:null}),n=Ou(e,n,r)}else if(Et||Xo(e,n,r,!1),x=(r&e.childLanes)!==0,Et||x){if(x=Ze,x!==null&&(l=r&-r,l=(l&42)!==0?1:Qe(l),l=(l&(x.suspendedLanes|r))!==0?0:l,l!==0&&l!==j.retryLane))throw j.retryLane=l,$r(e,l),Qt(x,e,l),yp;w.data==="$?"||Zu(),n=Ou(e,n,r)}else w.data==="$?"?(n.flags|=192,n.child=e.child,n=null):(e=j.treeContext,rt=vn(w.nextSibling),Dt=n,He=!0,nr=null,Cn=!1,e!==null&&(rn[on++]=Vn,rn[on++]=Yn,rn[on++]=er,Vn=e.id,Yn=e.overflow,er=n),n=_u(n,l.children),n.flags|=4096);return n}return i?(ya(),i=l.fallback,w=n.mode,j=e.child,B=j.sibling,l=qn(j,{mode:"hidden",children:l.children}),l.subtreeFlags=j.subtreeFlags&65011712,B!==null?i=qn(B,i):(i=Ja(i,w,r,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=ku(r):(j=w.cachePool,j!==null?(B=vt._currentValue,j=j.parent!==B?{parent:B,pool:B}:j):j=mh(),w={baseLanes:w.baseLanes|r,cachePool:j}),i.memoizedState=w,i.childLanes=ju(e,x,r),n.memoizedState=Au,l):(va(n),r=e.child,e=r.sibling,r=qn(r,{mode:"visible",children:l.children}),r.return=n,r.sibling=null,e!==null&&(x=n.deletions,x===null?(n.deletions=[e],n.flags|=16):x.push(e)),n.child=r,n.memoizedState=null,r)}function _u(e,n){return n=zs({mode:"visible",children:n},e.mode),n.return=e,e.child=n}function zs(e,n){return e=Vt(22,e,null,n),e.lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function Ou(e,n,r){return Fr(n,e.child,null,r),e=_u(n,n.pendingProps.children),e.flags|=2,n.memoizedState=null,e}function Ap(e,n,r){e.lanes|=n;var l=e.alternate;l!==null&&(l.lanes|=n),Zc(e.return,n,r)}function Du(e,n,r,l,i){var d=e.memoizedState;d===null?e.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:l,tail:r,tailMode:i}:(d.isBackwards=n,d.rendering=null,d.renderingStartTime=0,d.last=l,d.tail=r,d.tailMode=i)}function kp(e,n,r){var l=n.pendingProps,i=l.revealOrder,d=l.tail;if(Rt(e,n,l.children,r),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&&Ap(e,r,n);else if(e.tag===19)Ap(e,r,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(X(yt,l),i){case"forwards":for(r=n.child,i=null;r!==null;)e=r.alternate,e!==null&&_s(e)===null&&(i=r),r=r.sibling;r=i,r===null?(i=n.child,n.child=null):(i=r.sibling,r.sibling=null),Du(n,!1,i,r,d);break;case"backwards":for(r=null,i=n.child,n.child=null;i!==null;){if(e=i.alternate,e!==null&&_s(e)===null){n.child=i;break}e=i.sibling,i.sibling=r,r=i,i=e}Du(n,!0,r,null,d);break;case"together":Du(n,!1,null,null,void 0);break;default:n.memoizedState=null}return n.child}function Kn(e,n,r){if(e!==null&&(n.dependencies=e.dependencies),Ea|=n.lanes,(r&n.childLanes)===0)if(e!==null){if(Xo(e,n,r,!1),(r&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,r=qn(e,e.pendingProps),n.child=r,r.return=n;e.sibling!==null;)e=e.sibling,r=r.sibling=qn(e,e.pendingProps),r.return=n;r.sibling=null}return n.child}function Mu(e,n){return(e.lanes&n)!==0?!0:(e=e.dependencies,!!(e!==null&&ps(e)))}function Lw(e,n,r){switch(n.tag){case 3:de(n,n.stateNode.containerInfo),fa(n,vt,e.memoizedState.cache),Go();break;case 27:case 5:Ae(n);break;case 4:de(n,n.stateNode.containerInfo);break;case 10:fa(n,n.type,n.memoizedProps.value);break;case 13:var l=n.memoizedState;if(l!==null)return l.dehydrated!==null?(va(n),n.flags|=128,null):(r&n.child.childLanes)!==0?Rp(e,n,r):(va(n),e=Kn(e,n,r),e!==null?e.sibling:null);va(n);break;case 19:var i=(e.flags&128)!==0;if(l=(r&n.childLanes)!==0,l||(Xo(e,n,r,!1),l=(r&n.childLanes)!==0),i){if(l)return kp(e,n,r);n.flags|=128}if(i=n.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),X(yt,yt.current),l)break;return null;case 22:case 23:return n.lanes=0,Sp(e,n,r);case 24:fa(n,vt,e.memoizedState.cache)}return Kn(e,n,r)}function jp(e,n,r){if(e!==null)if(e.memoizedProps!==n.pendingProps)Et=!0;else{if(!Mu(e,r)&&(n.flags&128)===0)return Et=!1,Lw(e,n,r);Et=(e.flags&131072)!==0}else Et=!1,He&&(n.flags&1048576)!==0&&lh(n,hs,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")Vc(l)?(e=ir(l,e),n.tag=1,n=Tp(null,n,l,e,r)):(n.tag=0,n=Ru(null,n,l,e,r));else{if(l!=null){if(i=l.$$typeof,i===L){n.tag=11,n=bp(null,n,l,e,r);break e}else if(i===G){n.tag=14,n=xp(null,n,l,e,r);break e}}throw n=ue(l)||l,Error(s(306,n,""))}}return n;case 0:return Ru(e,n,n.type,n.pendingProps,r);case 1:return l=n.type,i=ir(l,n.pendingProps),Tp(e,n,l,i,r);case 3:e:{if(de(n,n.stateNode.containerInfo),e===null)throw Error(s(387));l=n.pendingProps;var d=n.memoizedState;i=d.element,au(e,n),el(n,l,null,r);var x=n.memoizedState;if(l=x.cache,fa(n,vt,l),l!==d.cache&&Wc(n,[vt],r,!0),Jo(),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=Cp(e,n,l,r);break e}else if(l!==i){i=nn(Error(s(424)),n),Io(i),n=Cp(e,n,l,r);break e}else for(e=n.stateNode.containerInfo,e.nodeType===9?e=e.body:e=e.nodeName==="HTML"?e.ownerDocument.body:e,rt=vn(e.firstChild),Dt=n,He=!0,nr=null,Cn=!0,r=ip(n,null,l,r),n.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Go(),l===i){n=Kn(e,n,r);break e}Rt(e,n,l,r)}n=n.child}return n;case 26:return Ms(e,n),e===null?(r=Mg(n.type,null,n.pendingProps,null))?n.memoizedState=r:He||(r=n.type,e=n.pendingProps,l=Ks(te.current).createElement(r),l[ct]=n,l[Ke]=e,kt(l,r,e),St(l),n.stateNode=l):n.memoizedState=Mg(n.type,e.memoizedProps,n.pendingProps,e.memoizedState),null;case 27:return Ae(n),e===null&&He&&(l=n.stateNode=_g(n.type,n.pendingProps,te.current),Dt=n,Cn=!0,i=rt,Ra(n.type)?(hd=i,rt=vn(l.firstChild)):rt=i),Rt(e,n,n.pendingProps.children,r),Ms(e,n),e===null&&(n.flags|=4194304),n.child;case 5:return e===null&&He&&((i=l=rt)&&(l=uS(l,n.type,n.pendingProps,Cn),l!==null?(n.stateNode=l,Dt=n,rt=vn(l.firstChild),Cn=!1,i=!0):i=!1),i||ar(n)),Ae(n),i=n.type,d=n.pendingProps,x=e!==null?e.memoizedProps:null,l=d.children,ud(i,d)?l=null:x!==null&&ud(i,x)&&(n.flags|=32),n.memoizedState!==null&&(i=cu(e,n,Aw,null,null,r),Sl._currentValue=i),Ms(e,n),Rt(e,n,l,r),n.child;case 6:return e===null&&He&&((e=r=rt)&&(r=dS(r,n.pendingProps,Cn),r!==null?(n.stateNode=r,Dt=n,rt=null,e=!0):e=!1),e||ar(n)),null;case 13:return Rp(e,n,r);case 4:return de(n,n.stateNode.containerInfo),l=n.pendingProps,e===null?n.child=Fr(n,null,l,r):Rt(e,n,l,r),n.child;case 11:return bp(e,n,n.type,n.pendingProps,r);case 7:return Rt(e,n,n.pendingProps,r),n.child;case 8:return Rt(e,n,n.pendingProps.children,r),n.child;case 12:return Rt(e,n,n.pendingProps.children,r),n.child;case 10:return l=n.pendingProps,fa(n,n.type,l.value),Rt(e,n,l.children,r),n.child;case 9:return i=n.type._context,l=n.pendingProps.children,or(n),i=jt(i),l=l(i),n.flags|=1,Rt(e,n,l,r),n.child;case 14:return xp(e,n,n.type,n.pendingProps,r);case 15:return wp(e,n,n.type,n.pendingProps,r);case 19:return kp(e,n,r);case 31:return l=n.pendingProps,r=n.mode,l={mode:l.mode,children:l.children},e===null?(r=zs(l,r),r.ref=n.ref,n.child=r,r.return=n,n=r):(r=qn(e.child,l),r.ref=n.ref,n.child=r,r.return=n,n=r),n;case 22:return Sp(e,n,r);case 24:return or(n),l=jt(vt),e===null?(i=eu(),i===null&&(i=Ze,d=Fc(),i.pooledCache=d,d.refCount++,d!==null&&(i.pooledCacheLanes|=r),i=d),n.memoizedState={parent:l,cache:i},nu(n),fa(n,vt,i)):((e.lanes&r)!==0&&(au(e,n),el(n,null,null,r),Jo()),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),fa(n,vt,l)):(l=d.cache,fa(n,vt,l),l!==i.cache&&Wc(n,[vt],r,!0))),Rt(e,n,n.pendingProps.children,r),n.child;case 29:throw n.pendingProps}throw Error(s(156,n.tag))}function Zn(e){e.flags|=4}function _p(e,n){if(n.type!=="stylesheet"||(n.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Bg(n)){if(n=ln.current,n!==null&&((ze&4194048)===ze?Rn!==null:(ze&62914560)!==ze&&(ze&536870912)===0||n!==Rn))throw Wo=tu,hh;e.flags|=8192}}function Ls(e,n){n!==null&&(e.flags|=4),e.flags&16384&&(n=e.tag!==22?Ia():536870912,e.lanes|=n,no|=n)}function sl(e,n){if(!He)switch(e.tailMode){case"hidden":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var l=null;r!==null;)r.alternate!==null&&(l=r),r=r.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,r=0,l=0;if(n)for(var i=e.child;i!==null;)r|=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;)r|=i.lanes|i.childLanes,l|=i.subtreeFlags,l|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=l,e.childLanes=r,n}function Uw(e,n,r){var l=n.pendingProps;switch(Xc(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 r=n.stateNode,l=null,e!==null&&(l=e.memoizedState.cache),n.memoizedState.cache!==l&&(n.flags|=2048),In(vt),xe(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Yo(n)?Zn(n):e===null||e.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,ch())),nt(n),null;case 26:return r=n.memoizedState,e===null?(Zn(n),r!==null?(nt(n),_p(n,r)):(nt(n),n.flags&=-16777217)):r?r!==e.memoizedState?(Zn(n),nt(n),_p(n,r)):(nt(n),n.flags&=-16777217):(e.memoizedProps!==l&&Zn(n),nt(n),n.flags&=-16777217),null;case 27:Ne(n),r=te.current;var i=n.type;if(e!==null&&n.stateNode!=null)e.memoizedProps!==l&&Zn(n);else{if(!l){if(n.stateNode===null)throw Error(s(166));return nt(n),null}e=F.current,Yo(n)?sh(n):(e=_g(i,l,r),n.stateNode=e,Zn(n))}return nt(n),null;case 5:if(Ne(n),r=n.type,e!==null&&n.stateNode!=null)e.memoizedProps!==l&&Zn(n);else{if(!l){if(n.stateNode===null)throw Error(s(166));return nt(n),null}if(e=F.current,Yo(n))sh(n);else{switch(i=Ks(te.current),e){case 1:e=i.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:e=i.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":e=i.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":e=i.createElementNS("http://www.w3.org/1998/Math/MathML",r);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(r,{is:l.is}):i.createElement(r)}}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,r,l),r){case"button":case"input":case"select":case"textarea":e=!!l.autoFocus;break e;case"img":e=!0;break e;default:e=!1}e&&Zn(n)}}return nt(n),n.flags&=-16777217,null;case 6:if(e&&n.stateNode!=null)e.memoizedProps!==l&&Zn(n);else{if(typeof l!="string"&&n.stateNode===null)throw Error(s(166));if(e=te.current,Yo(n)){if(e=n.stateNode,r=n.memoizedProps,l=null,i=Dt,i!==null)switch(i.tag){case 27:case 5:l=i.memoizedProps}e[ct]=n,e=!!(e.nodeValue===r||l!==null&&l.suppressHydrationWarning===!0||Ng(e.nodeValue,r)),e||ar(n)}else e=Ks(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=ch(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return n.flags&256?(Qn(n),n):(Qn(n),null)}if(Qn(n),(n.flags&128)!==0)return n.lanes=r,n;if(r=l!==null,e=e!==null&&e.memoizedState!==null,r){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 r!==e&&r&&(n.child.flags|=8192),Ls(n,n.updateQueue),nt(n),null;case 4:return xe(),e===null&&od(n.stateNode.containerInfo),nt(n),null;case 10:return In(n.type),nt(n),null;case 19:if(ne(yt),i=n.memoizedState,i===null)return nt(n),null;if(l=(n.flags&128)!==0,d=i.rendering,d===null)if(l)sl(i,!1);else{if(ot!==0||e!==null&&(e.flags&128)!==0)for(e=n.child;e!==null;){if(d=_s(e),d!==null){for(n.flags|=128,sl(i,!1),e=d.updateQueue,n.updateQueue=e,Ls(n,e),n.subtreeFlags=0,e=r,r=n.child;r!==null;)oh(r,e),r=r.sibling;return X(yt,yt.current&1|2),n.child}e=e.sibling}i.tail!==null&<()>Bs&&(n.flags|=128,l=!0,sl(i,!1),n.lanes=4194304)}else{if(!l)if(e=_s(d),e!==null){if(n.flags|=128,l=!0,e=e.updateQueue,n.updateQueue=e,Ls(n,e),sl(i,!0),i.tail===null&&i.tailMode==="hidden"&&!d.alternate&&!He)return nt(n),null}else 2*lt()-i.renderingStartTime>Bs&&r!==536870912&&(n.flags|=128,l=!0,sl(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,X(yt,l?e&1|2:e&1),n):(nt(n),null);case 22:case 23:return Qn(n),su(),l=n.memoizedState!==null,e!==null?e.memoizedState!==null!==l&&(n.flags|=8192):l&&(n.flags|=8192),l?(r&536870912)!==0&&(n.flags&128)===0&&(nt(n),n.subtreeFlags&6&&(n.flags|=8192)):nt(n),r=n.updateQueue,r!==null&&Ls(n,r.retryQueue),r=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(r=e.memoizedState.cachePool.pool),l=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(l=n.memoizedState.cachePool.pool),l!==r&&(n.flags|=2048),e!==null&&ne(lr),null;case 24:return r=null,e!==null&&(r=e.memoizedState.cache),n.memoizedState.cache!==r&&(n.flags|=2048),In(vt),nt(n),null;case 25:return null;case 30:return null}throw Error(s(156,n.tag))}function Hw(e,n){switch(Xc(n),n.tag){case 1:return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 3:return In(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 Ne(n),null;case 13:if(Qn(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 ne(yt),null;case 4:return xe(),null;case 10:return In(n.type),null;case 22:case 23:return Qn(n),su(),e!==null&&ne(lr),e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 24:return In(vt),null;case 25:return null;default:return null}}function Op(e,n){switch(Xc(n),n.tag){case 3:In(vt),xe();break;case 26:case 27:case 5:Ne(n);break;case 4:xe();break;case 13:Qn(n);break;case 19:ne(yt);break;case 10:In(n.type);break;case 22:case 23:Qn(n),su(),e!==null&&ne(lr);break;case 24:In(vt)}}function il(e,n){try{var r=n.updateQueue,l=r!==null?r.lastEffect:null;if(l!==null){var i=l.next;r=i;do{if((r.tag&e)===e){l=void 0;var d=r.create,x=r.inst;l=d(),x.destroy=l}r=r.next}while(r!==i)}}catch(w){Ie(n,n.return,w)}}function ba(e,n,r){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 j=r,B=w;try{B()}catch(Q){Ie(i,j,Q)}}}l=l.next}while(l!==d)}}catch(Q){Ie(n,n.return,Q)}}function Dp(e){var n=e.updateQueue;if(n!==null){var r=e.stateNode;try{xh(n,r)}catch(l){Ie(e,e.return,l)}}}function Mp(e,n,r){r.props=ir(e.type,e.memoizedProps),r.state=e.memoizedState;try{r.componentWillUnmount()}catch(l){Ie(e,n,l)}}function cl(e,n){try{var r=e.ref;if(r!==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 r=="function"?e.refCleanup=r(l):r.current=l}}catch(i){Ie(e,n,i)}}function An(e,n){var r=e.ref,l=e.refCleanup;if(r!==null)if(typeof l=="function")try{l()}catch(i){Ie(e,n,i)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof r=="function")try{r(null)}catch(i){Ie(e,n,i)}else r.current=null}function zp(e){var n=e.type,r=e.memoizedProps,l=e.stateNode;try{e:switch(n){case"button":case"input":case"select":case"textarea":r.autoFocus&&l.focus();break e;case"img":r.src?l.src=r.src:r.srcSet&&(l.srcset=r.srcSet)}}catch(i){Ie(e,e.return,i)}}function zu(e,n,r){try{var l=e.stateNode;oS(l,e.type,r,n),l[Ke]=n}catch(i){Ie(e,e.return,i)}}function Lp(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Ra(e.type)||e.tag===4}function Lu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Lp(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&&Ra(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 Uu(e,n,r){var l=e.tag;if(l===5||l===6)e=e.stateNode,n?(r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r).insertBefore(e,n):(n=r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r,n.appendChild(e),r=r._reactRootContainer,r!=null||n.onclick!==null||(n.onclick=Qs));else if(l!==4&&(l===27&&Ra(e.type)&&(r=e.stateNode,n=null),e=e.child,e!==null))for(Uu(e,n,r),e=e.sibling;e!==null;)Uu(e,n,r),e=e.sibling}function Us(e,n,r){var l=e.tag;if(l===5||l===6)e=e.stateNode,n?r.insertBefore(e,n):r.appendChild(e);else if(l!==4&&(l===27&&Ra(e.type)&&(r=e.stateNode),e=e.child,e!==null))for(Us(e,n,r),e=e.sibling;e!==null;)Us(e,n,r),e=e.sibling}function Up(e){var n=e.stateNode,r=e.memoizedProps;try{for(var l=e.type,i=n.attributes;i.length;)n.removeAttributeNode(i[0]);kt(n,l,r),n[ct]=e,n[Ke]=r}catch(d){Ie(e,e.return,d)}}var Wn=!1,dt=!1,Hu=!1,Hp=typeof WeakSet=="function"?WeakSet:Set,Nt=null;function Bw(e,n){if(e=e.containerInfo,id=ti,e=Km(e),Lc(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var l=r.getSelection&&r.getSelection();if(l&&l.rangeCount!==0){r=l.anchorNode;var i=l.anchorOffset,d=l.focusNode;l=l.focusOffset;try{r.nodeType,d.nodeType}catch{r=null;break e}var x=0,w=-1,j=-1,B=0,Q=0,Z=e,P=null;t:for(;;){for(var q;Z!==r||i!==0&&Z.nodeType!==3||(w=x+i),Z!==d||l!==0&&Z.nodeType!==3||(j=x+l),Z.nodeType===3&&(x+=Z.nodeValue.length),(q=Z.firstChild)!==null;)P=Z,Z=q;for(;;){if(Z===e)break t;if(P===r&&++B===i&&(w=x),P===d&&++Q===l&&(j=x),(q=Z.nextSibling)!==null)break;Z=P,P=Z.parentNode}Z=q}r=w===-1||j===-1?null:{start:w,end:j}}else r=null}r=r||{start:0,end:0}}else r=null;for(cd={focusedElem:e,selectionRange:r},ti=!1,Nt=n;Nt!==null;)if(n=Nt,e=n.child,(n.subtreeFlags&1024)!==0&&e!==null)e.return=n,Nt=e;else for(;Nt!==null;){switch(n=Nt,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,r=n,i=d.memoizedProps,d=d.memoizedState,l=r.stateNode;try{var Ee=ir(r.type,i,r.elementType===r.type);e=l.getSnapshotBeforeUpdate(Ee,d),l.__reactInternalSnapshotBeforeUpdate=e}catch(we){Ie(r,r.return,we)}}break;case 3:if((e&1024)!==0){if(e=n.stateNode.containerInfo,r=e.nodeType,r===9)fd(e);else if(r===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":fd(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,Nt=e;break}Nt=n.return}}function Bp(e,n,r){var l=r.flags;switch(r.tag){case 0:case 11:case 15:xa(e,r),l&4&&il(5,r);break;case 1:if(xa(e,r),l&4)if(e=r.stateNode,n===null)try{e.componentDidMount()}catch(x){Ie(r,r.return,x)}else{var i=ir(r.type,n.memoizedProps);n=n.memoizedState;try{e.componentDidUpdate(i,n,e.__reactInternalSnapshotBeforeUpdate)}catch(x){Ie(r,r.return,x)}}l&64&&Dp(r),l&512&&cl(r,r.return);break;case 3:if(xa(e,r),l&64&&(e=r.updateQueue,e!==null)){if(n=null,r.child!==null)switch(r.child.tag){case 27:case 5:n=r.child.stateNode;break;case 1:n=r.child.stateNode}try{xh(e,n)}catch(x){Ie(r,r.return,x)}}break;case 27:n===null&&l&4&&Up(r);case 26:case 5:xa(e,r),n===null&&l&4&&zp(r),l&512&&cl(r,r.return);break;case 12:xa(e,r);break;case 13:xa(e,r),l&4&&qp(e,r),l&64&&(e=r.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(r=Qw.bind(null,r),fS(e,r))));break;case 22:if(l=r.memoizedState!==null||Wn,!l){n=n!==null&&n.memoizedState!==null||dt,i=Wn;var d=dt;Wn=l,(dt=n)&&!d?wa(e,r,(r.subtreeFlags&8772)!==0):xa(e,r),Wn=i,dt=d}break;case 30:break;default:xa(e,r)}}function Pp(e){var n=e.alternate;n!==null&&(e.alternate=null,Pp(n)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(n=e.stateNode,n!==null&&vc(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,Ht=!1;function Fn(e,n,r){for(r=r.child;r!==null;)$p(e,n,r),r=r.sibling}function $p(e,n,r){if(Ct&&typeof Ct.onCommitFiberUnmount=="function")try{Ct.onCommitFiberUnmount($t,r)}catch{}switch(r.tag){case 26:dt||An(r,n),Fn(e,n,r),r.memoizedState?r.memoizedState.count--:r.stateNode&&(r=r.stateNode,r.parentNode.removeChild(r));break;case 27:dt||An(r,n);var l=et,i=Ht;Ra(r.type)&&(et=r.stateNode,Ht=!1),Fn(e,n,r),yl(r.stateNode),et=l,Ht=i;break;case 5:dt||An(r,n);case 6:if(l=et,i=Ht,et=null,Fn(e,n,r),et=l,Ht=i,et!==null)if(Ht)try{(et.nodeType===9?et.body:et.nodeName==="HTML"?et.ownerDocument.body:et).removeChild(r.stateNode)}catch(d){Ie(r,n,d)}else try{et.removeChild(r.stateNode)}catch(d){Ie(r,n,d)}break;case 18:et!==null&&(Ht?(e=et,kg(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,r.stateNode),Cl(e)):kg(et,r.stateNode));break;case 4:l=et,i=Ht,et=r.stateNode.containerInfo,Ht=!0,Fn(e,n,r),et=l,Ht=i;break;case 0:case 11:case 14:case 15:dt||ba(2,r,n),dt||ba(4,r,n),Fn(e,n,r);break;case 1:dt||(An(r,n),l=r.stateNode,typeof l.componentWillUnmount=="function"&&Mp(r,n,l)),Fn(e,n,r);break;case 21:Fn(e,n,r);break;case 22:dt=(l=dt)||r.memoizedState!==null,Fn(e,n,r),dt=l;break;default:Fn(e,n,r)}}function qp(e,n){if(n.memoizedState===null&&(e=n.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Cl(e)}catch(r){Ie(n,n.return,r)}}function Pw(e){switch(e.tag){case 13:case 19:var n=e.stateNode;return n===null&&(n=e.stateNode=new Hp),n;case 22:return e=e.stateNode,n=e._retryCache,n===null&&(n=e._retryCache=new Hp),n;default:throw Error(s(435,e.tag))}}function Bu(e,n){var r=Pw(e);n.forEach(function(l){var i=Kw.bind(null,e,l);r.has(l)||(r.add(l),l.then(i,i))})}function Yt(e,n){var r=n.deletions;if(r!==null)for(var l=0;l<r.length;l++){var i=r[l],d=e,x=n,w=x;e:for(;w!==null;){switch(w.tag){case 27:if(Ra(w.type)){et=w.stateNode,Ht=!1;break e}break;case 5:et=w.stateNode,Ht=!1;break e;case 3:case 4:et=w.stateNode.containerInfo,Ht=!0;break e}w=w.return}if(et===null)throw Error(s(160));$p(d,x,i),et=null,Ht=!1,d=i.alternate,d!==null&&(d.return=null),i.return=null}if(n.subtreeFlags&13878)for(n=n.child;n!==null;)Vp(n,e),n=n.sibling}var gn=null;function Vp(e,n){var r=e.alternate,l=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Yt(n,e),Gt(e),l&4&&(ba(3,e,e.return),il(3,e),ba(5,e,e.return));break;case 1:Yt(n,e),Gt(e),l&512&&(dt||r===null||An(r,r.return)),l&64&&Wn&&(e=e.updateQueue,e!==null&&(l=e.callbacks,l!==null&&(r=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=r===null?l:r.concat(l))));break;case 26:var i=gn;if(Yt(n,e),Gt(e),l&512&&(dt||r===null||An(r,r.return)),l&4){var d=r!==null?r.memoizedState:null;if(l=e.memoizedState,r===null)if(l===null)if(e.stateNode===null){e:{l=e.type,r=e.memoizedProps,i=i.ownerDocument||i;t:switch(l){case"title":d=i.getElementsByTagName("title")[0],(!d||d[Do]||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,r),d[ct]=e,St(d),l=d;break e;case"link":var x=Ug("link","href",i).get(l+(r.href||""));if(x){for(var w=0;w<x.length;w++)if(d=x[w],d.getAttribute("href")===(r.href==null||r.href===""?null:r.href)&&d.getAttribute("rel")===(r.rel==null?null:r.rel)&&d.getAttribute("title")===(r.title==null?null:r.title)&&d.getAttribute("crossorigin")===(r.crossOrigin==null?null:r.crossOrigin)){x.splice(w,1);break t}}d=i.createElement(l),kt(d,l,r),i.head.appendChild(d);break;case"meta":if(x=Ug("meta","content",i).get(l+(r.content||""))){for(w=0;w<x.length;w++)if(d=x[w],d.getAttribute("content")===(r.content==null?null:""+r.content)&&d.getAttribute("name")===(r.name==null?null:r.name)&&d.getAttribute("property")===(r.property==null?null:r.property)&&d.getAttribute("http-equiv")===(r.httpEquiv==null?null:r.httpEquiv)&&d.getAttribute("charset")===(r.charSet==null?null:r.charSet)){x.splice(w,1);break t}}d=i.createElement(l),kt(d,l,r),i.head.appendChild(d);break;default:throw Error(s(468,l))}d[ct]=e,St(d),l=d}e.stateNode=l}else Hg(i,e.type,e.stateNode);else e.stateNode=Lg(i,l,e.memoizedProps);else d!==l?(d===null?r.stateNode!==null&&(r=r.stateNode,r.parentNode.removeChild(r)):d.count--,l===null?Hg(i,e.type,e.stateNode):Lg(i,l,e.memoizedProps)):l===null&&e.stateNode!==null&&zu(e,e.memoizedProps,r.memoizedProps)}break;case 27:Yt(n,e),Gt(e),l&512&&(dt||r===null||An(r,r.return)),r!==null&&l&4&&zu(e,e.memoizedProps,r.memoizedProps);break;case 5:if(Yt(n,e),Gt(e),l&512&&(dt||r===null||An(r,r.return)),e.flags&32){i=e.stateNode;try{Mr(i,"")}catch(q){Ie(e,e.return,q)}}l&4&&e.stateNode!=null&&(i=e.memoizedProps,zu(e,i,r!==null?r.memoizedProps:i)),l&1024&&(Hu=!0);break;case 6:if(Yt(n,e),Gt(e),l&4){if(e.stateNode===null)throw Error(s(162));l=e.memoizedProps,r=e.stateNode;try{r.nodeValue=l}catch(q){Ie(e,e.return,q)}}break;case 3:if(Fs=null,i=gn,gn=Zs(n.containerInfo),Yt(n,e),gn=i,Gt(e),l&4&&r!==null&&r.memoizedState.isDehydrated)try{Cl(n.containerInfo)}catch(q){Ie(e,e.return,q)}Hu&&(Hu=!1,Yp(e));break;case 4:l=gn,gn=Zs(e.stateNode.containerInfo),Yt(n,e),Gt(e),gn=l;break;case 12:Yt(n,e),Gt(e);break;case 13:Yt(n,e),Gt(e),e.child.flags&8192&&e.memoizedState!==null!=(r!==null&&r.memoizedState!==null)&&(Gu=lt()),l&4&&(l=e.updateQueue,l!==null&&(e.updateQueue=null,Bu(e,l)));break;case 22:i=e.memoizedState!==null;var j=r!==null&&r.memoizedState!==null,B=Wn,Q=dt;if(Wn=B||i,dt=Q||j,Yt(n,e),dt=Q,Wn=B,Gt(e),l&8192)e:for(n=e.stateNode,n._visibility=i?n._visibility&-2:n._visibility|1,i&&(r===null||j||Wn||dt||cr(e)),r=null,n=e;;){if(n.tag===5||n.tag===26){if(r===null){j=r=n;try{if(d=j.stateNode,i)x=d.style,typeof x.setProperty=="function"?x.setProperty("display","none","important"):x.display="none";else{w=j.stateNode;var Z=j.memoizedProps.style,P=Z!=null&&Z.hasOwnProperty("display")?Z.display:null;w.style.display=P==null||typeof P=="boolean"?"":(""+P).trim()}}catch(q){Ie(j,j.return,q)}}}else if(n.tag===6){if(r===null){j=n;try{j.stateNode.nodeValue=i?"":j.memoizedProps}catch(q){Ie(j,j.return,q)}}}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;r===n&&(r=null),n=n.return}r===n&&(r=null),n.sibling.return=n.return,n=n.sibling}l&4&&(l=e.updateQueue,l!==null&&(r=l.retryQueue,r!==null&&(l.retryQueue=null,Bu(e,r))));break;case 19:Yt(n,e),Gt(e),l&4&&(l=e.updateQueue,l!==null&&(e.updateQueue=null,Bu(e,l)));break;case 30:break;case 21:break;default:Yt(n,e),Gt(e)}}function Gt(e){var n=e.flags;if(n&2){try{for(var r,l=e.return;l!==null;){if(Lp(l)){r=l;break}l=l.return}if(r==null)throw Error(s(160));switch(r.tag){case 27:var i=r.stateNode,d=Lu(e);Us(e,d,i);break;case 5:var x=r.stateNode;r.flags&32&&(Mr(x,""),r.flags&=-33);var w=Lu(e);Us(e,w,x);break;case 3:case 4:var j=r.stateNode.containerInfo,B=Lu(e);Uu(e,B,j);break;default:throw Error(s(161))}}catch(Q){Ie(e,e.return,Q)}e.flags&=-3}n&4096&&(e.flags&=-4097)}function Yp(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var n=e;Yp(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),e=e.sibling}}function xa(e,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)Bp(e,n.alternate,n),n=n.sibling}function cr(e){for(e=e.child;e!==null;){var n=e;switch(n.tag){case 0:case 11:case 14:case 15:ba(4,n,n.return),cr(n);break;case 1:An(n,n.return);var r=n.stateNode;typeof r.componentWillUnmount=="function"&&Mp(n,n.return,r),cr(n);break;case 27:yl(n.stateNode);case 26:case 5:An(n,n.return),cr(n);break;case 22:n.memoizedState===null&&cr(n);break;case 30:cr(n);break;default:cr(n)}e=e.sibling}}function wa(e,n,r){for(r=r&&(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:wa(i,d,r),il(4,d);break;case 1:if(wa(i,d,r),l=d,i=l.stateNode,typeof i.componentDidMount=="function")try{i.componentDidMount()}catch(B){Ie(l,l.return,B)}if(l=d,i=l.updateQueue,i!==null){var w=l.stateNode;try{var j=i.shared.hiddenCallbacks;if(j!==null)for(i.shared.hiddenCallbacks=null,i=0;i<j.length;i++)bh(j[i],w)}catch(B){Ie(l,l.return,B)}}r&&x&64&&Dp(d),cl(d,d.return);break;case 27:Up(d);case 26:case 5:wa(i,d,r),r&&l===null&&x&4&&zp(d),cl(d,d.return);break;case 12:wa(i,d,r);break;case 13:wa(i,d,r),r&&x&4&&qp(i,d);break;case 22:d.memoizedState===null&&wa(i,d,r),cl(d,d.return);break;case 30:break;default:wa(i,d,r)}n=n.sibling}}function Pu(e,n){var r=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(r=e.memoizedState.cachePool.pool),e=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(e=n.memoizedState.cachePool.pool),e!==r&&(e!=null&&e.refCount++,r!=null&&Qo(r))}function $u(e,n){e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Qo(e))}function kn(e,n,r,l){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)Gp(e,n,r,l),n=n.sibling}function Gp(e,n,r,l){var i=n.flags;switch(n.tag){case 0:case 11:case 15:kn(e,n,r,l),i&2048&&il(9,n);break;case 1:kn(e,n,r,l);break;case 3:kn(e,n,r,l),i&2048&&(e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Qo(e)));break;case 12:if(i&2048){kn(e,n,r,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(j){Ie(n,n.return,j)}}else kn(e,n,r,l);break;case 13:kn(e,n,r,l);break;case 23:break;case 22:d=n.stateNode,x=n.alternate,n.memoizedState!==null?d._visibility&2?kn(e,n,r,l):ul(e,n):d._visibility&2?kn(e,n,r,l):(d._visibility|=2,Jr(e,n,r,l,(n.subtreeFlags&10256)!==0)),i&2048&&Pu(x,n);break;case 24:kn(e,n,r,l),i&2048&&$u(n.alternate,n);break;default:kn(e,n,r,l)}}function Jr(e,n,r,l,i){for(i=i&&(n.subtreeFlags&10256)!==0,n=n.child;n!==null;){var d=e,x=n,w=r,j=l,B=x.flags;switch(x.tag){case 0:case 11:case 15:Jr(d,x,w,j,i),il(8,x);break;case 23:break;case 22:var Q=x.stateNode;x.memoizedState!==null?Q._visibility&2?Jr(d,x,w,j,i):ul(d,x):(Q._visibility|=2,Jr(d,x,w,j,i)),i&&B&2048&&Pu(x.alternate,x);break;case 24:Jr(d,x,w,j,i),i&&B&2048&&$u(x.alternate,x);break;default:Jr(d,x,w,j,i)}n=n.sibling}}function ul(e,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var r=e,l=n,i=l.flags;switch(l.tag){case 22:ul(r,l),i&2048&&Pu(l.alternate,l);break;case 24:ul(r,l),i&2048&&$u(l.alternate,l);break;default:ul(r,l)}n=n.sibling}}var dl=8192;function eo(e){if(e.subtreeFlags&dl)for(e=e.child;e!==null;)Ip(e),e=e.sibling}function Ip(e){switch(e.tag){case 26:eo(e),e.flags&dl&&e.memoizedState!==null&&TS(gn,e.memoizedState,e.memoizedProps);break;case 5:eo(e);break;case 3:case 4:var n=gn;gn=Zs(e.stateNode.containerInfo),eo(e),gn=n;break;case 22:e.memoizedState===null&&(n=e.alternate,n!==null&&n.memoizedState!==null?(n=dl,dl=16777216,eo(e),dl=n):eo(e));break;default:eo(e)}}function Xp(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 fl(e){var n=e.deletions;if((e.flags&16)!==0){if(n!==null)for(var r=0;r<n.length;r++){var l=n[r];Nt=l,Kp(l,e)}Xp(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Qp(e),e=e.sibling}function Qp(e){switch(e.tag){case 0:case 11:case 15:fl(e),e.flags&2048&&ba(9,e,e.return);break;case 3:fl(e);break;case 12:fl(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)):fl(e);break;default:fl(e)}}function Hs(e){var n=e.deletions;if((e.flags&16)!==0){if(n!==null)for(var r=0;r<n.length;r++){var l=n[r];Nt=l,Kp(l,e)}Xp(e)}for(e=e.child;e!==null;){switch(n=e,n.tag){case 0:case 11:case 15:ba(8,n,n.return),Hs(n);break;case 22:r=n.stateNode,r._visibility&2&&(r._visibility&=-3,Hs(n));break;default:Hs(n)}e=e.sibling}}function Kp(e,n){for(;Nt!==null;){var r=Nt;switch(r.tag){case 0:case 11:case 15:ba(8,r,n);break;case 23:case 22:if(r.memoizedState!==null&&r.memoizedState.cachePool!==null){var l=r.memoizedState.cachePool.pool;l!=null&&l.refCount++}break;case 24:Qo(r.memoizedState.cache)}if(l=r.child,l!==null)l.return=r,Nt=l;else e:for(r=e;Nt!==null;){l=Nt;var i=l.sibling,d=l.return;if(Pp(l),l===r){Nt=null;break e}if(i!==null){i.return=d,Nt=i;break e}Nt=d}}}var $w={getCacheForType:function(e){var n=jt(vt),r=n.data.get(e);return r===void 0&&(r=e(),n.data.set(e,r)),r}},qw=typeof WeakMap=="function"?WeakMap:Map,Be=0,Ze=null,De=null,ze=0,Pe=0,It=null,Sa=!1,to=!1,qu=!1,Jn=0,ot=0,Ea=0,ur=0,Vu=0,sn=0,no=0,ml=null,Bt=null,Yu=!1,Gu=0,Bs=1/0,Ps=null,Na=null,At=0,Ta=null,ao=null,ro=0,Iu=0,Xu=null,Zp=null,hl=0,Qu=null;function Xt(){if((Be&2)!==0&&ze!==0)return ze&-ze;if(_.T!==null){var e=Gr;return e!==0?e:td()}return Qa()}function Wp(){sn===0&&(sn=(ze&536870912)===0||He?zt():536870912);var e=ln.current;return e!==null&&(e.flags|=32),sn}function Qt(e,n,r){(e===Ze&&(Pe===2||Pe===9)||e.cancelPendingCommit!==null)&&(oo(e,0),Ca(e,ze,sn,!1)),be(e,r),((Be&2)===0||e!==Ze)&&(e===Ze&&((Be&2)===0&&(ur|=r),ot===4&&Ca(e,ze,sn,!1)),jn(e))}function Fp(e,n,r){if((Be&6)!==0)throw Error(s(327));var l=!r&&(n&124)===0&&(n&e.expiredLanes)===0||Hn(e,n),i=l?Gw(e,n):Wu(e,n,!0),d=l;do{if(i===0){to&&!l&&Ca(e,n,0,!1);break}else{if(r=e.current.alternate,d&&!Vw(r)){i=Wu(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=ml;var j=w.current.memoizedState.isDehydrated;if(j&&(oo(w,x).flags|=256),x=Wu(w,x,!1),x!==2){if(qu&&!j){w.errorRecoveryDisabledLanes|=d,ur|=d,i=4;break e}d=Bt,Bt=i,d!==null&&(Bt===null?Bt=d:Bt.push.apply(Bt,d))}i=x}if(d=!1,i!==2)continue}}if(i===1){oo(e,0),Ca(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:Ca(l,n,sn,!Sa);break e;case 2:Bt=null;break;case 3:case 5:break;default:throw Error(s(329))}if((n&62914560)===n&&(i=Gu+300-lt(),10<i)){if(Ca(l,n,sn,!Sa),Un(l,0,!0)!==0)break e;l.timeoutHandle=Rg(Jp.bind(null,l,r,Bt,Ps,Yu,n,sn,ur,no,Sa,d,2,-0,0),i);break e}Jp(l,r,Bt,Ps,Yu,n,sn,ur,no,Sa,d,0,-0,0)}}break}while(!0);jn(e)}function Jp(e,n,r,l,i,d,x,w,j,B,Q,Z,P,q){if(e.timeoutHandle=-1,Z=n.subtreeFlags,(Z&8192||(Z&16785408)===16785408)&&(wl={stylesheets:null,count:0,unsuspend:NS},Ip(n),Z=CS(),Z!==null)){e.cancelPendingCommit=Z(lg.bind(null,e,n,d,r,l,i,x,w,j,Q,1,P,q)),Ca(e,d,x,!B);return}lg(e,n,d,r,l,i,x,w,j)}function Vw(e){for(var n=e;;){var r=n.tag;if((r===0||r===11||r===15)&&n.flags&16384&&(r=n.updateQueue,r!==null&&(r=r.stores,r!==null)))for(var l=0;l<r.length;l++){var i=r[l],d=i.getSnapshot;i=i.value;try{if(!qt(d(),i))return!1}catch{return!1}}if(r=n.child,n.subtreeFlags&16384&&r!==null)r.return=n,n=r;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 Ca(e,n,r,l){n&=~Vu,n&=~ur,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}r!==0&&me(e,r,n)}function $s(){return(Be&6)===0?(pl(0),!1):!0}function Ku(){if(De!==null){if(Pe===0)var e=De.return;else e=De,Gn=rr=null,fu(e),Wr=null,ol=0,e=De;for(;e!==null;)Op(e.alternate,e),e=e.return;De=null}}function oo(e,n){var r=e.timeoutHandle;r!==-1&&(e.timeoutHandle=-1,sS(r)),r=e.cancelPendingCommit,r!==null&&(e.cancelPendingCommit=null,r()),Ku(),Ze=e,De=r=qn(e.current,null),ze=n,Pe=0,It=null,Sa=!1,to=Hn(e,n),qu=!1,no=sn=Vu=ur=Ea=ot=0,Bt=ml=null,Yu=!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 Jn=n,cs(),r}function eg(e,n){je=null,_.H=As,n===Zo||n===ys?(n=vh(),Pe=3):n===hh?(n=vh(),Pe=4):Pe=n===yp?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,It=n,De===null&&(ot=1,Ds(e,nn(n,e.current)))}function tg(){var e=_.H;return _.H=As,e===null?As:e}function ng(){var e=_.A;return _.A=$w,e}function Zu(){ot=4,Sa||(ze&4194048)!==ze&&ln.current!==null||(to=!0),(Ea&134217727)===0&&(ur&134217727)===0||Ze===null||Ca(Ze,ze,sn,!1)}function Wu(e,n,r){var l=Be;Be|=2;var i=tg(),d=ng();(Ze!==e||ze!==n)&&(Ps=null,oo(e,n)),n=!1;var x=ot;e:do try{if(Pe!==0&&De!==null){var w=De,j=It;switch(Pe){case 8:Ku(),x=6;break e;case 3:case 2:case 9:case 6:ln.current===null&&(n=!0);var B=Pe;if(Pe=0,It=null,lo(e,w,j,B),r&&to){x=0;break e}break;default:B=Pe,Pe=0,It=null,lo(e,w,j,B)}}Yw(),x=ot;break}catch(Q){eg(e,Q)}while(!0);return n&&e.shellSuspendCounter++,Gn=rr=null,Be=l,_.H=i,_.A=d,De===null&&(Ze=null,ze=0,cs()),x}function Yw(){for(;De!==null;)ag(De)}function Gw(e,n){var r=Be;Be|=2;var l=tg(),i=ng();Ze!==e||ze!==n?(Ps=null,Bs=lt()+500,oo(e,n)):to=Hn(e,n);e:do try{if(Pe!==0&&De!==null){n=De;var d=It;t:switch(Pe){case 1:Pe=0,It=null,lo(e,n,d,1);break;case 2:case 9:if(ph(d)){Pe=0,It=null,rg(n);break}n=function(){Pe!==2&&Pe!==9||Ze!==e||(Pe=7),jn(e)},d.then(n,n);break e;case 3:Pe=7;break e;case 4:Pe=5;break e;case 7:ph(d)?(Pe=0,It=null,rg(n)):(Pe=0,It=null,lo(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||Bg(x)){Pe=0,It=null;var j=w.sibling;if(j!==null)De=j;else{var B=w.return;B!==null?(De=B,qs(B)):De=null}break t}}Pe=0,It=null,lo(e,n,d,5);break;case 6:Pe=0,It=null,lo(e,n,d,6);break;case 8:Ku(),ot=6;break e;default:throw Error(s(462))}}Iw();break}catch(Q){eg(e,Q)}while(!0);return Gn=rr=null,_.H=l,_.A=i,Be=r,De!==null?0:(Ze=null,ze=0,cs(),ot)}function Iw(){for(;De!==null&&!fn();)ag(De)}function ag(e){var n=jp(e.alternate,e,Jn);e.memoizedProps=e.pendingProps,n===null?qs(e):De=n}function rg(e){var n=e,r=n.alternate;switch(n.tag){case 15:case 0:n=Np(r,n,n.pendingProps,n.type,void 0,ze);break;case 11:n=Np(r,n,n.pendingProps,n.type.render,n.ref,ze);break;case 5:fu(n);default:Op(r,n),n=De=oh(n,Jn),n=jp(r,n,Jn)}e.memoizedProps=e.pendingProps,n===null?qs(e):De=n}function lo(e,n,r,l){Gn=rr=null,fu(n),Wr=null,ol=0;var i=n.return;try{if(zw(e,i,n,r,ze)){ot=1,Ds(e,nn(r,e.current)),De=null;return}}catch(d){if(i!==null)throw De=i,d;ot=1,Ds(e,nn(r,e.current)),De=null;return}n.flags&32768?(He||l===1?e=!0:to||(ze&536870912)!==0?e=!1:(Sa=e=!0,(l===2||l===9||l===3||l===6)&&(l=ln.current,l!==null&&l.tag===13&&(l.flags|=16384))),og(n,e)):qs(n)}function qs(e){var n=e;do{if((n.flags&32768)!==0){og(n,Sa);return}e=n.return;var r=Uw(n.alternate,n,Jn);if(r!==null){De=r;return}if(n=n.sibling,n!==null){De=n;return}De=n=e}while(n!==null);ot===0&&(ot=5)}function og(e,n){do{var r=Hw(e.alternate,e);if(r!==null){r.flags&=32767,De=r;return}if(r=e.return,r!==null&&(r.flags|=32768,r.subtreeFlags=0,r.deletions=null),!n&&(e=e.sibling,e!==null)){De=e;return}De=e=r}while(e!==null);ot=6,De=null}function lg(e,n,r,l,i,d,x,w,j){e.cancelPendingCommit=null;do Vs();while(At!==0);if((Be&6)!==0)throw Error(s(327));if(n!==null){if(n===e.current)throw Error(s(177));if(d=n.lanes|n.childLanes,d|=$c,Xe(e,r,d,x,w,j),e===Ze&&(De=Ze=null,ze=0),ao=n,Ta=e,ro=r,Iu=d,Xu=i,Zp=l,(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,Zw(Ln,function(){return dg(),null})):(e.callbackNode=null,e.callbackPriority=0),l=(n.flags&13878)!==0,(n.subtreeFlags&13878)!==0||l){l=_.T,_.T=null,i=$.p,$.p=2,x=Be,Be|=4;try{Bw(e,n,r)}finally{Be=x,$.p=i,_.T=l}}At=1,sg(),ig(),cg()}}function sg(){if(At===1){At=0;var e=Ta,n=ao,r=(n.flags&13878)!==0;if((n.subtreeFlags&13878)!==0||r){r=_.T,_.T=null;var l=$.p;$.p=2;var i=Be;Be|=4;try{Vp(n,e);var d=cd,x=Km(e.containerInfo),w=d.focusedElem,j=d.selectionRange;if(x!==w&&w&&w.ownerDocument&&Qm(w.ownerDocument.documentElement,w)){if(j!==null&&Lc(w)){var B=j.start,Q=j.end;if(Q===void 0&&(Q=B),"selectionStart"in w)w.selectionStart=B,w.selectionEnd=Math.min(Q,w.value.length);else{var Z=w.ownerDocument||document,P=Z&&Z.defaultView||window;if(P.getSelection){var q=P.getSelection(),Ee=w.textContent.length,we=Math.min(j.start,Ee),Ye=j.end===void 0?we:Math.min(j.end,Ee);!q.extend&&we>Ye&&(x=Ye,Ye=we,we=x);var z=Xm(w,we),D=Xm(w,Ye);if(z&&D&&(q.rangeCount!==1||q.anchorNode!==z.node||q.anchorOffset!==z.offset||q.focusNode!==D.node||q.focusOffset!==D.offset)){var U=Z.createRange();U.setStart(z.node,z.offset),q.removeAllRanges(),we>Ye?(q.addRange(U),q.extend(D.node,D.offset)):(U.setEnd(D.node,D.offset),q.addRange(U))}}}}for(Z=[],q=w;q=q.parentNode;)q.nodeType===1&&Z.push({element:q,left:q.scrollLeft,top:q.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}}ti=!!id,cd=id=null}finally{Be=i,$.p=l,_.T=r}}e.current=n,At=2}}function ig(){if(At===2){At=0;var e=Ta,n=ao,r=(n.flags&8772)!==0;if((n.subtreeFlags&8772)!==0||r){r=_.T,_.T=null;var l=$.p;$.p=2;var i=Be;Be|=4;try{Bp(e,n.alternate,n)}finally{Be=i,$.p=l,_.T=r}}At=3}}function cg(){if(At===4||At===3){At=0,mn();var e=Ta,n=ao,r=ro,l=Zp;(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?At=5:(At=0,ao=Ta=null,ug(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(Na=null),pt(r),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=_.T,i=$.p,$.p=2,_.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{_.T=n,$.p=i}}(ro&3)!==0&&Vs(),jn(e),i=e.pendingLanes,(r&4194090)!==0&&(i&42)!==0?e===Qu?hl++:(hl=0,Qu=e):hl=0,pl(0)}}function ug(e,n){(e.pooledCacheLanes&=n)===0&&(n=e.pooledCache,n!=null&&(e.pooledCache=null,Qo(n)))}function Vs(e){return sg(),ig(),cg(),dg()}function dg(){if(At!==5)return!1;var e=Ta,n=Iu;Iu=0;var r=pt(ro),l=_.T,i=$.p;try{$.p=32>r?32:r,_.T=null,r=Xu,Xu=null;var d=Ta,x=ro;if(At=0,ao=Ta=null,ro=0,(Be&6)!==0)throw Error(s(331));var w=Be;if(Be|=4,Qp(d.current),Gp(d,d.current,x,r),Be=w,pl(0,!1),Ct&&typeof Ct.onPostCommitFiberRoot=="function")try{Ct.onPostCommitFiberRoot($t,d)}catch{}return!0}finally{$.p=i,_.T=l,ug(e,n)}}function fg(e,n,r){n=nn(r,n),n=Cu(e.stateNode,n,2),e=pa(e,n,2),e!==null&&(be(e,2),jn(e))}function Ie(e,n,r){if(e.tag===3)fg(e,e,r);else for(;n!==null;){if(n.tag===3){fg(n,e,r);break}else if(n.tag===1){var l=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof l.componentDidCatch=="function"&&(Na===null||!Na.has(l))){e=nn(r,e),r=gp(2),l=pa(n,r,2),l!==null&&(vp(r,l,n,e),be(l,2),jn(l));break}}n=n.return}}function Fu(e,n,r){var l=e.pingCache;if(l===null){l=e.pingCache=new qw;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(r)||(qu=!0,i.add(r),e=Xw.bind(null,e,n,r),n.then(e,e))}function Xw(e,n,r){var l=e.pingCache;l!==null&&l.delete(n),e.pingedLanes|=e.suspendedLanes&r,e.warmLanes&=~r,Ze===e&&(ze&r)===r&&(ot===4||ot===3&&(ze&62914560)===ze&&300>lt()-Gu?(Be&2)===0&&oo(e,0):Vu|=r,no===ze&&(no=0)),jn(e)}function mg(e,n){n===0&&(n=Ia()),e=$r(e,n),e!==null&&(be(e,n),jn(e))}function Qw(e){var n=e.memoizedState,r=0;n!==null&&(r=n.retryLane),mg(e,r)}function Kw(e,n){var r=0;switch(e.tag){case 13:var l=e.stateNode,i=e.memoizedState;i!==null&&(r=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),mg(e,r)}function Zw(e,n){return Je(e,n)}var Ys=null,so=null,Ju=!1,Gs=!1,ed=!1,dr=0;function jn(e){e!==so&&e.next===null&&(so===null?Ys=so=e:so=so.next=e),Gs=!0,Ju||(Ju=!0,Fw())}function pl(e,n){if(!ed&&Gs){ed=!0;do for(var r=!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&&(r=!0,vg(l,d))}else d=ze,d=Un(l,l===Ze?d:0,l.cancelPendingCommit!==null||l.timeoutHandle!==-1),(d&3)===0||Hn(l,d)||(r=!0,vg(l,d));l=l.next}while(r);ed=!1}}function Ww(){hg()}function hg(){Gs=Ju=!1;var e=0;dr!==0&&(lS()&&(e=dr),dr=0);for(var n=lt(),r=null,l=Ys;l!==null;){var i=l.next,d=pg(l,n);d===0?(l.next=null,r===null?Ys=i:r.next=i,i===null&&(so=r)):(r=l,(e!==0||(d&3)!==0)&&(Gs=!0)),l=i}pl(e)}function pg(e,n){for(var r=e.suspendedLanes,l=e.pingedLanes,i=e.expirationTimes,d=e.pendingLanes&-62914561;0<d;){var x=31-We(d),w=1<<x,j=i[x];j===-1?((w&r)===0||(w&l)!==0)&&(i[x]=ua(w,n)):j<=n&&(e.expiredLanes|=w),d&=~w}if(n=Ze,r=ze,r=Un(e,e===n?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),l=e.callbackNode,r===0||e===n&&(Pe===2||Pe===9)||e.cancelPendingCommit!==null)return l!==null&&l!==null&&at(l),e.callbackNode=null,e.callbackPriority=0;if((r&3)===0||Hn(e,r)){if(n=r&-r,n===e.callbackPriority)return n;switch(l!==null&&at(l),pt(r)){case 2:case 8:r=Nr;break;case 32:r=Ln;break;case 268435456:r=hn;break;default:r=Ln}return l=gg.bind(null,e),r=Je(r,l),e.callbackPriority=n,e.callbackNode=r,n}return l!==null&&l!==null&&at(l),e.callbackPriority=2,e.callbackNode=null,2}function gg(e,n){if(At!==0&&At!==5)return e.callbackNode=null,e.callbackPriority=0,null;var r=e.callbackNode;if(Vs()&&e.callbackNode!==r)return null;var l=ze;return l=Un(e,e===Ze?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),l===0?null:(Fp(e,l,n),pg(e,lt()),e.callbackNode!=null&&e.callbackNode===r?gg.bind(null,e):null)}function vg(e,n){if(Vs())return null;Fp(e,n,!0)}function Fw(){iS(function(){(Be&6)!==0?Je(ht,Ww):hg()})}function td(){return dr===0&&(dr=zt()),dr}function yg(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:ns(""+e)}function bg(e,n){var r=n.ownerDocument.createElement("input");return r.name=n.name,r.value=n.value,e.id&&r.setAttribute("form",e.id),n.parentNode.insertBefore(r,n),e=new FormData(e),r.parentNode.removeChild(r),e}function Jw(e,n,r,l,i){if(n==="submit"&&r&&r.stateNode===i){var d=yg((i[Ke]||null).action),x=l.submitter;x&&(n=(n=x[Ke]||null)?yg(n.formAction):x.getAttribute("formAction"),n!==null&&(d=n,x=null));var w=new ls("action","action",null,l,i);e.push({event:w,listeners:[{instance:null,listener:function(){if(l.defaultPrevented){if(dr!==0){var j=x?bg(i,x):new FormData(i);wu(r,{pending:!0,data:j,method:i.method,action:d},null,j)}}else typeof d=="function"&&(w.preventDefault(),j=x?bg(i,x):new FormData(i),wu(r,{pending:!0,data:j,method:i.method,action:d},d,j))},currentTarget:i}]})}}for(var nd=0;nd<Pc.length;nd++){var ad=Pc[nd],eS=ad.toLowerCase(),tS=ad[0].toUpperCase()+ad.slice(1);pn(eS,"on"+tS)}pn(Fm,"onAnimationEnd"),pn(Jm,"onAnimationIteration"),pn(eh,"onAnimationStart"),pn("dblclick","onDoubleClick"),pn("focusin","onFocus"),pn("focusout","onBlur"),pn(yw,"onTransitionRun"),pn(bw,"onTransitionStart"),pn(xw,"onTransitionCancel"),pn(th,"onTransitionEnd"),_r("onMouseEnter",["mouseout","mouseover"]),_r("onMouseLeave",["mouseout","mouseover"]),_r("onPointerEnter",["pointerout","pointerover"]),_r("onPointerLeave",["pointerout","pointerover"]),Ka("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ka("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ka("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ka("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ka("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ka("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var gl="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),nS=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(gl));function xg(e,n){n=(n&4)!==0;for(var r=0;r<e.length;r++){var l=e[r],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],j=w.instance,B=w.currentTarget;if(w=w.listener,j!==d&&i.isPropagationStopped())break e;d=w,i.currentTarget=B;try{d(i)}catch(Q){Os(Q)}i.currentTarget=null,d=j}else for(x=0;x<l.length;x++){if(w=l[x],j=w.instance,B=w.currentTarget,w=w.listener,j!==d&&i.isPropagationStopped())break e;d=w,i.currentTarget=B;try{d(i)}catch(Q){Os(Q)}i.currentTarget=null,d=j}}}}function Me(e,n){var r=n[Rr];r===void 0&&(r=n[Rr]=new Set);var l=e+"__bubble";r.has(l)||(wg(n,e,2,!1),r.add(l))}function rd(e,n,r){var l=0;n&&(l|=4),wg(r,e,l,n)}var Is="_reactListening"+Math.random().toString(36).slice(2);function od(e){if(!e[Is]){e[Is]=!0,hm.forEach(function(r){r!=="selectionchange"&&(nS.has(r)||rd(r,!1,e),rd(r,!0,e))});var n=e.nodeType===9?e:e.ownerDocument;n===null||n[Is]||(n[Is]=!0,rd("selectionchange",!1,n))}}function wg(e,n,r,l){switch(Gg(n)){case 2:var i=kS;break;case 8:i=jS;break;default:i=bd}r=i.bind(null,n,r,e),i=void 0,!Rc||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(i=!0),l?i!==void 0?e.addEventListener(n,r,{capture:!0,passive:i}):e.addEventListener(n,r,!0):i!==void 0?e.addEventListener(n,r,{passive:i}):e.addEventListener(n,r,!1)}function ld(e,n,r,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 j=x.tag;if((j===3||j===4)&&x.stateNode.containerInfo===i)return;x=x.return}for(;w!==null;){if(x=Ar(w),x===null)return;if(j=x.tag,j===5||j===6||j===26||j===27){l=d=x;continue e}w=w.parentNode}}l=l.return}Am(function(){var B=d,Q=Tc(r),Z=[];e:{var P=nh.get(e);if(P!==void 0){var q=ls,Ee=e;switch(e){case"keypress":if(rs(r)===0)break e;case"keydown":case"keyup":q=Z1;break;case"focusin":Ee="focus",q=_c;break;case"focusout":Ee="blur",q=_c;break;case"beforeblur":case"afterblur":q=_c;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":q=_m;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":q=H1;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":q=J1;break;case Fm:case Jm:case eh:q=$1;break;case th:q=tw;break;case"scroll":case"scrollend":q=L1;break;case"wheel":q=aw;break;case"copy":case"cut":case"paste":q=V1;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":q=Dm;break;case"toggle":case"beforetoggle":q=ow}var we=(n&4)!==0,Ye=!we&&(e==="scroll"||e==="scrollend"),z=we?P!==null?P+"Capture":null:P;we=[];for(var D=B,U;D!==null;){var K=D;if(U=K.stateNode,K=K.tag,K!==5&&K!==26&&K!==27||U===null||z===null||(K=zo(D,z),K!=null&&we.push(vl(D,K,U))),Ye)break;D=D.return}0<we.length&&(P=new q(P,Ee,null,r,Q),Z.push({event:P,listeners:we}))}}if((n&7)===0){e:{if(P=e==="mouseover"||e==="pointerover",q=e==="mouseout"||e==="pointerout",P&&r!==Nc&&(Ee=r.relatedTarget||r.fromElement)&&(Ar(Ee)||Ee[wt]))break e;if((q||P)&&(P=Q.window===Q?Q:(P=Q.ownerDocument)?P.defaultView||P.parentWindow:window,q?(Ee=r.relatedTarget||r.toElement,q=B,Ee=Ee?Ar(Ee):null,Ee!==null&&(Ye=u(Ee),we=Ee.tag,Ee!==Ye||we!==5&&we!==27&&we!==6)&&(Ee=null)):(q=null,Ee=B),q!==Ee)){if(we=_m,K="onMouseLeave",z="onMouseEnter",D="mouse",(e==="pointerout"||e==="pointerover")&&(we=Dm,K="onPointerLeave",z="onPointerEnter",D="pointer"),Ye=q==null?P:Mo(q),U=Ee==null?P:Mo(Ee),P=new we(K,D+"leave",q,r,Q),P.target=Ye,P.relatedTarget=U,K=null,Ar(Q)===B&&(we=new we(z,D+"enter",Ee,r,Q),we.target=U,we.relatedTarget=Ye,K=we),Ye=K,q&&Ee)t:{for(we=q,z=Ee,D=0,U=we;U;U=io(U))D++;for(U=0,K=z;K;K=io(K))U++;for(;0<D-U;)we=io(we),D--;for(;0<U-D;)z=io(z),U--;for(;D--;){if(we===z||z!==null&&we===z.alternate)break t;we=io(we),z=io(z)}we=null}else we=null;q!==null&&Sg(Z,P,q,we,!1),Ee!==null&&Ye!==null&&Sg(Z,Ye,Ee,we,!0)}}e:{if(P=B?Mo(B):window,q=P.nodeName&&P.nodeName.toLowerCase(),q==="select"||q==="input"&&P.type==="file")var he=$m;else if(Bm(P))if(qm)he=pw;else{he=mw;var Oe=fw}else q=P.nodeName,!q||q.toLowerCase()!=="input"||P.type!=="checkbox"&&P.type!=="radio"?B&&Ec(B.elementType)&&(he=$m):he=hw;if(he&&(he=he(e,B))){Pm(Z,he,r,Q);break e}Oe&&Oe(e,P,B),e==="focusout"&&B&&P.type==="number"&&B.memoizedProps.value!=null&&Sc(P,"number",P.value)}switch(Oe=B?Mo(B):window,e){case"focusin":(Bm(Oe)||Oe.contentEditable==="true")&&(Hr=Oe,Uc=B,Vo=null);break;case"focusout":Vo=Uc=Hr=null;break;case"mousedown":Hc=!0;break;case"contextmenu":case"mouseup":case"dragend":Hc=!1,Zm(Z,r,Q);break;case"selectionchange":if(vw)break;case"keydown":case"keyup":Zm(Z,r,Q)}var ye;if(Dc)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 Ur?Um(e,r)&&(Se="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(Se="onCompositionStart");Se&&(Mm&&r.locale!=="ko"&&(Ur||Se!=="onCompositionStart"?Se==="onCompositionEnd"&&Ur&&(ye=km()):(da=Q,Ac="value"in da?da.value:da.textContent,Ur=!0)),Oe=Xs(B,Se),0<Oe.length&&(Se=new Om(Se,e,null,r,Q),Z.push({event:Se,listeners:Oe}),ye?Se.data=ye:(ye=Hm(r),ye!==null&&(Se.data=ye)))),(ye=sw?iw(e,r):cw(e,r))&&(Se=Xs(B,"onBeforeInput"),0<Se.length&&(Oe=new Om("onBeforeInput","beforeinput",null,r,Q),Z.push({event:Oe,listeners:Se}),Oe.data=ye)),Jw(Z,e,B,r,Q)}xg(Z,n)})}function vl(e,n,r){return{instance:e,listener:n,currentTarget:r}}function Xs(e,n){for(var r=n+"Capture",l=[];e!==null;){var i=e,d=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||d===null||(i=zo(e,r),i!=null&&l.unshift(vl(e,i,d)),i=zo(e,n),i!=null&&l.push(vl(e,i,d))),e.tag===3)return l;e=e.return}return[]}function io(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Sg(e,n,r,l,i){for(var d=n._reactName,x=[];r!==null&&r!==l;){var w=r,j=w.alternate,B=w.stateNode;if(w=w.tag,j!==null&&j===l)break;w!==5&&w!==26&&w!==27||B===null||(j=B,i?(B=zo(r,d),B!=null&&x.unshift(vl(r,B,j))):i||(B=zo(r,d),B!=null&&x.push(vl(r,B,j)))),r=r.return}x.length!==0&&e.push({event:n,listeners:x})}var aS=/\r\n?/g,rS=/\u0000|\uFFFD/g;function Eg(e){return(typeof e=="string"?e:""+e).replace(aS,`
|
|
50
|
+
`).replace(rS,"")}function Ng(e,n){return n=Eg(n),Eg(e)===n}function Qs(){}function Ve(e,n,r,l,i,d){switch(r){case"children":typeof l=="string"?n==="body"||n==="textarea"&&l===""||Mr(e,l):(typeof l=="number"||typeof l=="bigint")&&n!=="body"&&Mr(e,""+l);break;case"className":Jl(e,"class",l);break;case"tabIndex":Jl(e,"tabindex",l);break;case"dir":case"role":case"viewBox":case"width":case"height":Jl(e,r,l);break;case"style":Cm(e,l,d);break;case"data":if(n!=="object"){Jl(e,"data",l);break}case"src":case"href":if(l===""&&(n!=="a"||r!=="href")){e.removeAttribute(r);break}if(l==null||typeof l=="function"||typeof l=="symbol"||typeof l=="boolean"){e.removeAttribute(r);break}l=ns(""+l),e.setAttribute(r,l);break;case"action":case"formAction":if(typeof l=="function"){e.setAttribute(r,"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"&&(r==="formAction"?(n!=="input"&&Ve(e,n,"name",i.name,i,null),Ve(e,n,"formEncType",i.formEncType,i,null),Ve(e,n,"formMethod",i.formMethod,i,null),Ve(e,n,"formTarget",i.formTarget,i,null)):(Ve(e,n,"encType",i.encType,i,null),Ve(e,n,"method",i.method,i,null),Ve(e,n,"target",i.target,i,null)));if(l==null||typeof l=="symbol"||typeof l=="boolean"){e.removeAttribute(r);break}l=ns(""+l),e.setAttribute(r,l);break;case"onClick":l!=null&&(e.onclick=Qs);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(r=l.__html,r!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=r}}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}r=ns(""+l),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",r);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(r,""+l):e.removeAttribute(r);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(r,""):e.removeAttribute(r);break;case"capture":case"download":l===!0?e.setAttribute(r,""):l!==!1&&l!=null&&typeof l!="function"&&typeof l!="symbol"?e.setAttribute(r,l):e.removeAttribute(r);break;case"cols":case"rows":case"size":case"span":l!=null&&typeof l!="function"&&typeof l!="symbol"&&!isNaN(l)&&1<=l?e.setAttribute(r,l):e.removeAttribute(r);break;case"rowSpan":case"start":l==null||typeof l=="function"||typeof l=="symbol"||isNaN(l)?e.removeAttribute(r):e.setAttribute(r,l);break;case"popover":Me("beforetoggle",e),Me("toggle",e),Fl(e,"popover",l);break;case"xlinkActuate":Pn(e,"http://www.w3.org/1999/xlink","xlink:actuate",l);break;case"xlinkArcrole":Pn(e,"http://www.w3.org/1999/xlink","xlink:arcrole",l);break;case"xlinkRole":Pn(e,"http://www.w3.org/1999/xlink","xlink:role",l);break;case"xlinkShow":Pn(e,"http://www.w3.org/1999/xlink","xlink:show",l);break;case"xlinkTitle":Pn(e,"http://www.w3.org/1999/xlink","xlink:title",l);break;case"xlinkType":Pn(e,"http://www.w3.org/1999/xlink","xlink:type",l);break;case"xmlBase":Pn(e,"http://www.w3.org/XML/1998/namespace","xml:base",l);break;case"xmlLang":Pn(e,"http://www.w3.org/XML/1998/namespace","xml:lang",l);break;case"xmlSpace":Pn(e,"http://www.w3.org/XML/1998/namespace","xml:space",l);break;case"is":Fl(e,"is",l);break;case"innerText":case"textContent":break;default:(!(2<r.length)||r[0]!=="o"&&r[0]!=="O"||r[1]!=="n"&&r[1]!=="N")&&(r=M1.get(r)||r,Fl(e,r,l))}}function sd(e,n,r,l,i,d){switch(r){case"style":Cm(e,l,d);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!="object"||!("__html"in l))throw Error(s(61));if(r=l.__html,r!=null){if(i.children!=null)throw Error(s(60));e.innerHTML=r}}break;case"children":typeof l=="string"?Mr(e,l):(typeof l=="number"||typeof l=="bigint")&&Mr(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=Qs);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!pm.hasOwnProperty(r))e:{if(r[0]==="o"&&r[1]==="n"&&(i=r.endsWith("Capture"),n=r.slice(2,i?r.length-7:void 0),d=e[Ke]||null,d=d!=null?d[r]:null,typeof d=="function"&&e.removeEventListener(n,d,i),typeof l=="function")){typeof d!="function"&&d!==null&&(r in e?e[r]=null:e.hasAttribute(r)&&e.removeAttribute(r)),e.addEventListener(n,l,i);break e}r in e?e[r]=l:l===!0?e.setAttribute(r,""):Fl(e,r,l)}}}function kt(e,n,r){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 r)if(r.hasOwnProperty(d)){var x=r[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:Ve(e,n,d,x,r,null)}}i&&Ve(e,n,"srcSet",r.srcSet,r,null),l&&Ve(e,n,"src",r.src,r,null);return;case"input":Me("invalid",e);var w=d=x=i=null,j=null,B=null;for(l in r)if(r.hasOwnProperty(l)){var Q=r[l];if(Q!=null)switch(l){case"name":i=Q;break;case"type":x=Q;break;case"checked":j=Q;break;case"defaultChecked":B=Q;break;case"value":d=Q;break;case"defaultValue":w=Q;break;case"children":case"dangerouslySetInnerHTML":if(Q!=null)throw Error(s(137,n));break;default:Ve(e,n,l,Q,r,null)}}Sm(e,d,w,j,B,x,i,!1),es(e);return;case"select":Me("invalid",e),l=x=d=null;for(i in r)if(r.hasOwnProperty(i)&&(w=r[i],w!=null))switch(i){case"value":d=w;break;case"defaultValue":x=w;break;case"multiple":l=w;default:Ve(e,n,i,w,r,null)}n=d,r=x,e.multiple=!!l,n!=null?Dr(e,!!l,n,!1):r!=null&&Dr(e,!!l,r,!0);return;case"textarea":Me("invalid",e),d=i=l=null;for(x in r)if(r.hasOwnProperty(x)&&(w=r[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:Ve(e,n,x,w,r,null)}Nm(e,l,i,d),es(e);return;case"option":for(j in r)r.hasOwnProperty(j)&&(l=r[j],l!=null)&&(j==="selected"?e.selected=l&&typeof l!="function"&&typeof l!="symbol":Ve(e,n,j,l,r,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<gl.length;l++)Me(gl[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 r)if(r.hasOwnProperty(B)&&(l=r[B],l!=null))switch(B){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,n));default:Ve(e,n,B,l,r,null)}return;default:if(Ec(n)){for(Q in r)r.hasOwnProperty(Q)&&(l=r[Q],l!==void 0&&sd(e,n,Q,l,r,void 0));return}}for(w in r)r.hasOwnProperty(w)&&(l=r[w],l!=null&&Ve(e,n,w,l,r,null))}function oS(e,n,r,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,j=null,B=null,Q=null;for(q in r){var Z=r[q];if(r.hasOwnProperty(q)&&Z!=null)switch(q){case"checked":break;case"value":break;case"defaultValue":j=Z;default:l.hasOwnProperty(q)||Ve(e,n,q,null,l,Z)}}for(var P in l){var q=l[P];if(Z=r[P],l.hasOwnProperty(P)&&(q!=null||Z!=null))switch(P){case"type":d=q;break;case"name":i=q;break;case"checked":B=q;break;case"defaultChecked":Q=q;break;case"value":x=q;break;case"defaultValue":w=q;break;case"children":case"dangerouslySetInnerHTML":if(q!=null)throw Error(s(137,n));break;default:q!==Z&&Ve(e,n,P,q,l,Z)}}wc(e,x,w,j,B,Q,d,i);return;case"select":q=x=w=P=null;for(d in r)if(j=r[d],r.hasOwnProperty(d)&&j!=null)switch(d){case"value":break;case"multiple":q=j;default:l.hasOwnProperty(d)||Ve(e,n,d,null,l,j)}for(i in l)if(d=l[i],j=r[i],l.hasOwnProperty(i)&&(d!=null||j!=null))switch(i){case"value":P=d;break;case"defaultValue":w=d;break;case"multiple":x=d;default:d!==j&&Ve(e,n,i,d,l,j)}n=w,r=x,l=q,P!=null?Dr(e,!!r,P,!1):!!l!=!!r&&(n!=null?Dr(e,!!r,n,!0):Dr(e,!!r,r?[]:"",!1));return;case"textarea":q=P=null;for(w in r)if(i=r[w],r.hasOwnProperty(w)&&i!=null&&!l.hasOwnProperty(w))switch(w){case"value":break;case"children":break;default:Ve(e,n,w,null,l,i)}for(x in l)if(i=l[x],d=r[x],l.hasOwnProperty(x)&&(i!=null||d!=null))switch(x){case"value":P=i;break;case"defaultValue":q=i;break;case"children":break;case"dangerouslySetInnerHTML":if(i!=null)throw Error(s(91));break;default:i!==d&&Ve(e,n,x,i,l,d)}Em(e,P,q);return;case"option":for(var Ee in r)P=r[Ee],r.hasOwnProperty(Ee)&&P!=null&&!l.hasOwnProperty(Ee)&&(Ee==="selected"?e.selected=!1:Ve(e,n,Ee,null,l,P));for(j in l)P=l[j],q=r[j],l.hasOwnProperty(j)&&P!==q&&(P!=null||q!=null)&&(j==="selected"?e.selected=P&&typeof P!="function"&&typeof P!="symbol":Ve(e,n,j,P,l,q));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 r)P=r[we],r.hasOwnProperty(we)&&P!=null&&!l.hasOwnProperty(we)&&Ve(e,n,we,null,l,P);for(B in l)if(P=l[B],q=r[B],l.hasOwnProperty(B)&&P!==q&&(P!=null||q!=null))switch(B){case"children":case"dangerouslySetInnerHTML":if(P!=null)throw Error(s(137,n));break;default:Ve(e,n,B,P,l,q)}return;default:if(Ec(n)){for(var Ye in r)P=r[Ye],r.hasOwnProperty(Ye)&&P!==void 0&&!l.hasOwnProperty(Ye)&&sd(e,n,Ye,void 0,l,P);for(Q in l)P=l[Q],q=r[Q],!l.hasOwnProperty(Q)||P===q||P===void 0&&q===void 0||sd(e,n,Q,P,l,q);return}}for(var z in r)P=r[z],r.hasOwnProperty(z)&&P!=null&&!l.hasOwnProperty(z)&&Ve(e,n,z,null,l,P);for(Z in l)P=l[Z],q=r[Z],!l.hasOwnProperty(Z)||P===q||P==null&&q==null||Ve(e,n,Z,P,l,q)}var id=null,cd=null;function Ks(e){return e.nodeType===9?e:e.ownerDocument}function Tg(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 Cg(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 ud(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 dd=null;function lS(){var e=window.event;return e&&e.type==="popstate"?e===dd?!1:(dd=e,!0):(dd=null,!1)}var Rg=typeof setTimeout=="function"?setTimeout:void 0,sS=typeof clearTimeout=="function"?clearTimeout:void 0,Ag=typeof Promise=="function"?Promise:void 0,iS=typeof queueMicrotask=="function"?queueMicrotask:typeof Ag<"u"?function(e){return Ag.resolve(null).then(e).catch(cS)}:Rg;function cS(e){setTimeout(function(){throw e})}function Ra(e){return e==="head"}function kg(e,n){var r=n,l=0,i=0;do{var d=r.nextSibling;if(e.removeChild(r),d&&d.nodeType===8)if(r=d.data,r==="/$"){if(0<l&&8>l){r=l;var x=e.ownerDocument;if(r&1&&yl(x.documentElement),r&2&&yl(x.body),r&4)for(r=x.head,yl(r),x=r.firstChild;x;){var w=x.nextSibling,j=x.nodeName;x[Do]||j==="SCRIPT"||j==="STYLE"||j==="LINK"&&x.rel.toLowerCase()==="stylesheet"||r.removeChild(x),x=w}}if(i===0){e.removeChild(d),Cl(n);return}i--}else r==="$"||r==="$?"||r==="$!"?i++:l=r.charCodeAt(0)-48;else l=0;r=d}while(r);Cl(n)}function fd(e){var n=e.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var r=n;switch(n=n.nextSibling,r.nodeName){case"HTML":case"HEAD":case"BODY":fd(r),vc(r);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(r.rel.toLowerCase()==="stylesheet")continue}e.removeChild(r)}}function uS(e,n,r,l){for(;e.nodeType===1;){var i=r;if(e.nodeName.toLowerCase()!==n.toLowerCase()){if(!l&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(l){if(!e[Do])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=vn(e.nextSibling),e===null)break}return null}function dS(e,n,r){if(n==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!r||(e=vn(e.nextSibling),e===null))return null;return e}function md(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState==="complete"}function fS(e,n){var r=e.ownerDocument;if(e.data!=="$?"||r.readyState==="complete")n();else{var l=function(){n(),r.removeEventListener("DOMContentLoaded",l)};r.addEventListener("DOMContentLoaded",l),e._reactRetry=l}}function vn(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 hd=null;function jg(e){e=e.previousSibling;for(var n=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(n===0)return e;n--}else r==="/$"&&n++}e=e.previousSibling}return null}function _g(e,n,r){switch(n=Ks(r),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 yl(e){for(var n=e.attributes;n.length;)e.removeAttributeNode(n[0]);vc(e)}var cn=new Map,Og=new Set;function Zs(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var ea=$.d;$.d={f:mS,r:hS,D:pS,C:gS,L:vS,m:yS,X:xS,S:bS,M:wS};function mS(){var e=ea.f(),n=$s();return e||n}function hS(e){var n=kr(e);n!==null&&n.tag===5&&n.type==="form"?Fh(n):ea.r(e)}var co=typeof document>"u"?null:document;function Dg(e,n,r){var l=co;if(l&&typeof n=="string"&&n){var i=tn(n);i='link[rel="'+e+'"][href="'+i+'"]',typeof r=="string"&&(i+='[crossorigin="'+r+'"]'),Og.has(i)||(Og.add(i),e={rel:e,crossOrigin:r,href:n},l.querySelector(i)===null&&(n=l.createElement("link"),kt(n,"link",e),St(n),l.head.appendChild(n)))}}function pS(e){ea.D(e),Dg("dns-prefetch",e,null)}function gS(e,n){ea.C(e,n),Dg("preconnect",e,n)}function vS(e,n,r){ea.L(e,n,r);var l=co;if(l&&e&&n){var i='link[rel="preload"][as="'+tn(n)+'"]';n==="image"&&r&&r.imageSrcSet?(i+='[imagesrcset="'+tn(r.imageSrcSet)+'"]',typeof r.imageSizes=="string"&&(i+='[imagesizes="'+tn(r.imageSizes)+'"]')):i+='[href="'+tn(e)+'"]';var d=i;switch(n){case"style":d=uo(e);break;case"script":d=fo(e)}cn.has(d)||(e=b({rel:"preload",href:n==="image"&&r&&r.imageSrcSet?void 0:e,as:n},r),cn.set(d,e),l.querySelector(i)!==null||n==="style"&&l.querySelector(bl(d))||n==="script"&&l.querySelector(xl(d))||(n=l.createElement("link"),kt(n,"link",e),St(n),l.head.appendChild(n)))}}function yS(e,n){ea.m(e,n);var r=co;if(r&&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=fo(e)}if(!cn.has(d)&&(e=b({rel:"modulepreload",href:e},n),cn.set(d,e),r.querySelector(i)===null)){switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(r.querySelector(xl(d)))return}l=r.createElement("link"),kt(l,"link",e),St(l),r.head.appendChild(l)}}}function bS(e,n,r){ea.S(e,n,r);var l=co;if(l&&e){var i=jr(l).hoistableStyles,d=uo(e);n=n||"default";var x=i.get(d);if(!x){var w={loading:0,preload:null};if(x=l.querySelector(bl(d)))w.loading=5;else{e=b({rel:"stylesheet",href:e,"data-precedence":n},r),(r=cn.get(d))&&pd(e,r);var j=x=l.createElement("link");St(j),kt(j,"link",e),j._p=new Promise(function(B,Q){j.onload=B,j.onerror=Q}),j.addEventListener("load",function(){w.loading|=1}),j.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 xS(e,n){ea.X(e,n);var r=co;if(r&&e){var l=jr(r).hoistableScripts,i=fo(e),d=l.get(i);d||(d=r.querySelector(xl(i)),d||(e=b({src:e,async:!0},n),(n=cn.get(i))&&gd(e,n),d=r.createElement("script"),St(d),kt(d,"link",e),r.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},l.set(i,d))}}function wS(e,n){ea.M(e,n);var r=co;if(r&&e){var l=jr(r).hoistableScripts,i=fo(e),d=l.get(i);d||(d=r.querySelector(xl(i)),d||(e=b({src:e,async:!0,type:"module"},n),(n=cn.get(i))&&gd(e,n),d=r.createElement("script"),St(d),kt(d,"link",e),r.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},l.set(i,d))}}function Mg(e,n,r,l){var i=(i=te.current)?Zs(i):null;if(!i)throw Error(s(446));switch(e){case"meta":case"title":return null;case"style":return typeof r.precedence=="string"&&typeof r.href=="string"?(n=uo(r.href),r=jr(i).hoistableStyles,l=r.get(n),l||(l={type:"style",instance:null,count:0,state:null},r.set(n,l)),l):{type:"void",instance:null,count:0,state:null};case"link":if(r.rel==="stylesheet"&&typeof r.href=="string"&&typeof r.precedence=="string"){e=uo(r.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(bl(e)))&&!d._p&&(x.instance=d,x.state.loading=5),cn.has(e)||(r={rel:"preload",as:"style",href:r.href,crossOrigin:r.crossOrigin,integrity:r.integrity,media:r.media,hrefLang:r.hrefLang,referrerPolicy:r.referrerPolicy},cn.set(e,r),d||SS(i,e,r,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=r.async,r=r.src,typeof r=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=fo(r),r=jr(i).hoistableScripts,l=r.get(n),l||(l={type:"script",instance:null,count:0,state:null},r.set(n,l)),l):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,e))}}function uo(e){return'href="'+tn(e)+'"'}function bl(e){return'link[rel="stylesheet"]['+e+"]"}function zg(e){return b({},e,{"data-precedence":e.precedence,precedence:null})}function SS(e,n,r,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",r),St(n),e.head.appendChild(n))}function fo(e){return'[src="'+tn(e)+'"]'}function xl(e){return"script[async]"+e}function Lg(e,n,r){if(n.count++,n.instance===null)switch(n.type){case"style":var l=e.querySelector('style[data-href~="'+tn(r.href)+'"]');if(l)return n.instance=l,St(l),l;var i=b({},r,{"data-href":r.href,"data-precedence":r.precedence,href:null,precedence:null});return l=(e.ownerDocument||e).createElement("style"),St(l),kt(l,"style",i),Ws(l,r.precedence,e),n.instance=l;case"stylesheet":i=uo(r.href);var d=e.querySelector(bl(i));if(d)return n.state.loading|=4,n.instance=d,St(d),d;l=zg(r),(i=cn.get(i))&&pd(l,i),d=(e.ownerDocument||e).createElement("link"),St(d);var x=d;return x._p=new Promise(function(w,j){x.onload=w,x.onerror=j}),kt(d,"link",l),n.state.loading|=4,Ws(d,r.precedence,e),n.instance=d;case"script":return d=fo(r.src),(i=e.querySelector(xl(d)))?(n.instance=i,St(i),i):(l=r,(i=cn.get(d))&&(l=b({},r),gd(l,i)),e=e.ownerDocument||e,i=e.createElement("script"),St(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,r.precedence,e));return n.instance}function Ws(e,n,r){for(var l=r.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=r.nodeType===9?r.head:r,n.insertBefore(e,n.firstChild))}function pd(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.title==null&&(e.title=n.title)}function gd(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.integrity==null&&(e.integrity=n.integrity)}var Fs=null;function Ug(e,n,r){if(Fs===null){var l=new Map,i=Fs=new Map;i.set(r,l)}else i=Fs,l=i.get(r),l||(l=new Map,i.set(r,l));if(l.has(e))return l;for(l.set(e,null),r=r.getElementsByTagName(e),i=0;i<r.length;i++){var d=r[i];if(!(d[Do]||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 Hg(e,n,r){e=e.ownerDocument||e,e.head.insertBefore(r,n==="title"?e.querySelector("head > title"):null)}function ES(e,n,r){if(r===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 Bg(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}var wl=null;function NS(){}function TS(e,n,r){if(wl===null)throw Error(s(475));var l=wl;if(n.type==="stylesheet"&&(typeof r.media!="string"||matchMedia(r.media).matches!==!1)&&(n.state.loading&4)===0){if(n.instance===null){var i=uo(r.href),d=e.querySelector(bl(i));if(d){e=d._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(l.count++,l=Js.bind(l),e.then(l,l)),n.state.loading|=4,n.instance=d,St(d);return}d=e.ownerDocument||e,r=zg(r),(i=cn.get(i))&&pd(r,i),d=d.createElement("link"),St(d);var x=d;x._p=new Promise(function(w,j){x.onload=w,x.onerror=j}),kt(d,"link",r),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=Js.bind(l),e.addEventListener("load",n),e.addEventListener("error",n))}}function CS(){if(wl===null)throw Error(s(475));var e=wl;return e.stylesheets&&e.count===0&&vd(e,e.stylesheets),0<e.count?function(n){var r=setTimeout(function(){if(e.stylesheets&&vd(e,e.stylesheets),e.unsuspend){var l=e.unsuspend;e.unsuspend=null,l()}},6e4);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r)}}:null}function Js(){if(this.count--,this.count===0){if(this.stylesheets)vd(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var ei=null;function vd(e,n){e.stylesheets=null,e.unsuspend!==null&&(e.count++,ei=new Map,n.forEach(RS,e),ei=null,Js.call(e))}function RS(e,n){if(!(n.state.loading&4)){var r=ei.get(e);if(r)var l=r.get(null);else{r=new Map,ei.set(e,r);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")&&(r.set(x.dataset.precedence,x),l=x)}l&&r.set(null,l)}i=n.instance,x=i.getAttribute("data-precedence"),d=r.get(x)||l,d===l&&r.set(null,i),r.set(x,i),this.count++,l=Js.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 Sl={$$typeof:M,Provider:null,Consumer:null,_currentValue:O,_currentValue2:O,_threadCount:0};function AS(e,n,r,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=Xa(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Xa(0),this.hiddenUpdates=Xa(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 Pg(e,n,r,l,i,d,x,w,j,B,Q,Z){return e=new AS(e,n,r,x,w,j,B,Z),n=1,d===!0&&(n|=24),d=Vt(3,null,null,n),e.current=d,d.stateNode=e,n=Fc(),n.refCount++,e.pooledCache=n,n.refCount++,d.memoizedState={element:l,isDehydrated:r,cache:n},nu(d),e}function $g(e){return e?(e=qr,e):qr}function qg(e,n,r,l,i,d){i=$g(i),l.context===null?l.context=i:l.pendingContext=i,l=ha(n),l.payload={element:r},d=d===void 0?null:d,d!==null&&(l.callback=d),r=pa(e,l,n),r!==null&&(Qt(r,e,n),Fo(r,e,n))}function Vg(e,n){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<n?r:n}}function yd(e,n){Vg(e,n),(e=e.alternate)&&Vg(e,n)}function Yg(e){if(e.tag===13){var n=$r(e,67108864);n!==null&&Qt(n,e,67108864),yd(e,67108864)}}var ti=!0;function kS(e,n,r,l){var i=_.T;_.T=null;var d=$.p;try{$.p=2,bd(e,n,r,l)}finally{$.p=d,_.T=i}}function jS(e,n,r,l){var i=_.T;_.T=null;var d=$.p;try{$.p=8,bd(e,n,r,l)}finally{$.p=d,_.T=i}}function bd(e,n,r,l){if(ti){var i=xd(l);if(i===null)ld(e,n,l,ni,r),Ig(e,l);else if(OS(i,e,n,r,l))l.stopPropagation();else if(Ig(e,l),n&4&&-1<_S.indexOf(e)){for(;i!==null;){var d=kr(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 j=1<<31-We(x);w.entanglements[1]|=j,x&=~j}jn(d),(Be&6)===0&&(Bs=lt()+500,pl(0))}}break;case 13:w=$r(d,2),w!==null&&Qt(w,d,2),$s(),yd(d,2)}if(d=xd(l),d===null&&ld(e,n,l,ni,r),d===i)break;i=d}i!==null&&l.stopPropagation()}else ld(e,n,l,null,r)}}function xd(e){return e=Tc(e),wd(e)}var ni=null;function wd(e){if(ni=null,e=Ar(e),e!==null){var n=u(e);if(n===null)e=null;else{var r=n.tag;if(r===13){if(e=m(n),e!==null)return e;e=null}else if(r===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;e=null}else n!==e&&(e=null)}}return ni=e,null}function Gg(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(Ga()){case ht:return 2;case Nr:return 8;case Ln:case st:return 32;case hn:return 268435456;default:return 32}default:return 32}}var Sd=!1,Aa=null,ka=null,ja=null,El=new Map,Nl=new Map,_a=[],_S="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 Ig(e,n){switch(e){case"focusin":case"focusout":Aa=null;break;case"dragenter":case"dragleave":ka=null;break;case"mouseover":case"mouseout":ja=null;break;case"pointerover":case"pointerout":El.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":Nl.delete(n.pointerId)}}function Tl(e,n,r,l,i,d){return e===null||e.nativeEvent!==d?(e={blockedOn:n,domEventName:r,eventSystemFlags:l,nativeEvent:d,targetContainers:[i]},n!==null&&(n=kr(n),n!==null&&Yg(n)),e):(e.eventSystemFlags|=l,n=e.targetContainers,i!==null&&n.indexOf(i)===-1&&n.push(i),e)}function OS(e,n,r,l,i){switch(n){case"focusin":return Aa=Tl(Aa,e,n,r,l,i),!0;case"dragenter":return ka=Tl(ka,e,n,r,l,i),!0;case"mouseover":return ja=Tl(ja,e,n,r,l,i),!0;case"pointerover":var d=i.pointerId;return El.set(d,Tl(El.get(d)||null,e,n,r,l,i)),!0;case"gotpointercapture":return d=i.pointerId,Nl.set(d,Tl(Nl.get(d)||null,e,n,r,l,i)),!0}return!1}function Xg(e){var n=Ar(e.target);if(n!==null){var r=u(n);if(r!==null){if(n=r.tag,n===13){if(n=m(r),n!==null){e.blockedOn=n,gt(e.priority,function(){if(r.tag===13){var l=Xt();l=Qe(l);var i=$r(r,l);i!==null&&Qt(i,r,l),yd(r,l)}});return}}else if(n===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ai(e){if(e.blockedOn!==null)return!1;for(var n=e.targetContainers;0<n.length;){var r=xd(e.nativeEvent);if(r===null){r=e.nativeEvent;var l=new r.constructor(r.type,r);Nc=l,r.target.dispatchEvent(l),Nc=null}else return n=kr(r),n!==null&&Yg(n),e.blockedOn=r,!1;n.shift()}return!0}function Qg(e,n,r){ai(e)&&r.delete(n)}function DS(){Sd=!1,Aa!==null&&ai(Aa)&&(Aa=null),ka!==null&&ai(ka)&&(ka=null),ja!==null&&ai(ja)&&(ja=null),El.forEach(Qg),Nl.forEach(Qg)}function ri(e,n){e.blockedOn===n&&(e.blockedOn=null,Sd||(Sd=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,DS)))}var oi=null;function Kg(e){oi!==e&&(oi=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){oi===e&&(oi=null);for(var n=0;n<e.length;n+=3){var r=e[n],l=e[n+1],i=e[n+2];if(typeof l!="function"){if(wd(l||r)===null)continue;break}var d=kr(r);d!==null&&(e.splice(n,3),n-=3,wu(d,{pending:!0,data:i,method:r.method,action:l},l,i))}}))}function Cl(e){function n(j){return ri(j,e)}Aa!==null&&ri(Aa,e),ka!==null&&ri(ka,e),ja!==null&&ri(ja,e),El.forEach(n),Nl.forEach(n);for(var r=0;r<_a.length;r++){var l=_a[r];l.blockedOn===e&&(l.blockedOn=null)}for(;0<_a.length&&(r=_a[0],r.blockedOn===null);)Xg(r),r.blockedOn===null&&_a.shift();if(r=(e.ownerDocument||e).$$reactFormReplay,r!=null)for(l=0;l<r.length;l+=3){var i=r[l],d=r[l+1],x=i[Ke]||null;if(typeof d=="function")x||Kg(r);else if(x){var w=null;if(d&&d.hasAttribute("formAction")){if(i=d,x=d[Ke]||null)w=x.formAction;else if(wd(i)!==null)continue}else w=x.action;typeof w=="function"?r[l+1]=w:(r.splice(l,3),l-=3),Kg(r)}}}function Ed(e){this._internalRoot=e}li.prototype.render=Ed.prototype.render=function(e){var n=this._internalRoot;if(n===null)throw Error(s(409));var r=n.current,l=Xt();qg(r,l,e,n,null,null)},li.prototype.unmount=Ed.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var n=e.containerInfo;qg(e.current,2,null,e,null,null),$s(),n[wt]=null}};function li(e){this._internalRoot=e}li.prototype.unstable_scheduleHydration=function(e){if(e){var n=Qa();e={blockedOn:null,target:e,priority:n};for(var r=0;r<_a.length&&n!==0&&n<_a[r].priority;r++);_a.splice(r,0,e),r===0&&Xg(e)}};var Zg=a.version;if(Zg!=="19.1.0")throw Error(s(527,Zg,"19.1.0"));$.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 MS={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:_,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var si=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!si.isDisabled&&si.supportsFiber)try{$t=si.inject(MS),Ct=si}catch{}}return Al.createRoot=function(e,n){if(!c(e))throw Error(s(299));var r=!1,l="",i=fp,d=mp,x=hp,w=null;return n!=null&&(n.unstable_strictMode===!0&&(r=!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=Pg(e,1,!1,null,null,r,l,i,d,x,w,null),e[wt]=n.current,od(e),new Ed(n)},Al.hydrateRoot=function(e,n,r){if(!c(e))throw Error(s(299));var l=!1,i="",d=fp,x=mp,w=hp,j=null,B=null;return r!=null&&(r.unstable_strictMode===!0&&(l=!0),r.identifierPrefix!==void 0&&(i=r.identifierPrefix),r.onUncaughtError!==void 0&&(d=r.onUncaughtError),r.onCaughtError!==void 0&&(x=r.onCaughtError),r.onRecoverableError!==void 0&&(w=r.onRecoverableError),r.unstable_transitionCallbacks!==void 0&&(j=r.unstable_transitionCallbacks),r.formState!==void 0&&(B=r.formState)),n=Pg(e,1,!0,n,r??null,l,i,d,x,w,j,B),n.context=$g(null),r=n.current,l=Xt(),l=Qe(l),i=ha(l),i.callback=null,pa(r,i,l),r=l,n.current.lanes=r,be(n,r),jn(n),e[wt]=n.current,od(e),new li(n)},Al.version="19.1.0",Al}var lv;function YS(){if(lv)return Cd.exports;lv=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(a){console.error(a)}}return t(),Cd.exports=VS(),Cd.exports}var GS=YS();const IS="modulepreload",XS=function(t){return"/"+t},sv={},ky=function(a,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=XS(p),p in sv)return;sv[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":IS,b||(S.as="script"),S.crossOrigin="",S.href=p,v&&S.setAttribute("nonce",v),document.head.appendChild(S),b)return new Promise((C,R)=>{S.addEventListener("load",C),S.addEventListener("error",()=>R(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 a().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 Rf=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,jy=/^[\\/]{2}/;function QS(t,a){return a+t.replace(/\\/g,"/")}var iv="popstate";function cv(t){return typeof t=="object"&&t!=null&&"pathname"in t&&"search"in t&&"hash"in t&&"state"in t&&"key"in t}function KS(t={}){function a(s,c){let u=c.state?.masked,{pathname:m,search:h,hash:v}=u||s.location;return Jd("",{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:Bl(c)}return WS(a,o,null,t)}function tt(t,a){if(t===!1||t===null||typeof t>"u")throw new Error(a)}function xn(t,a){if(!t){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function ZS(){return Math.random().toString(36).substring(2,10)}function uv(t,a){return{usr:t.state,key:t.key,idx:a,masked:t.mask?{pathname:t.pathname,search:t.search,hash:t.hash}:void 0}}function Jd(t,a,o=null,s,c){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof a=="string"?To(a):a,state:o,key:a&&a.key||s||ZS(),mask:c}}function Bl({pathname:t="/",search:a="",hash:o=""}){return a&&a!=="?"&&(t+=a.charAt(0)==="?"?a:"?"+a),o&&o!=="#"&&(t+=o.charAt(0)==="#"?o:"#"+o),t}function To(t){let a={};if(t){let o=t.indexOf("#");o>=0&&(a.hash=t.substring(o),t=t.substring(0,o));let s=t.indexOf("?");s>=0&&(a.search=t.substring(s),t=t.substring(0,s)),t&&(a.pathname=t)}return a}function WS(t,a,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 T=b(),k=T==null?null:T-p;p=T,v&&v({action:h,location:E.location,delta:k})}function S(T,k){h="PUSH";let A=cv(T)?T:Jd(E.location,T,k);p=b()+1;let M=uv(A,p),L=E.createHref(A.mask||A);try{m.pushState(M,"",L)}catch(H){if(H instanceof DOMException&&H.name==="DataCloneError")throw H;c.location.assign(L)}u&&v&&v({action:h,location:E.location,delta:1})}function C(T,k){h="REPLACE";let A=cv(T)?T:Jd(E.location,T,k);p=b();let M=uv(A,p),L=E.createHref(A.mask||A);m.replaceState(M,"",L),u&&v&&v({action:h,location:E.location,delta:0})}function R(T){return FS(c,T)}let E={get action(){return h},get location(){return t(c,m)},listen(T){if(v)throw new Error("A history only accepts one active listener");return c.addEventListener(iv,y),v=T,()=>{c.removeEventListener(iv,y),v=null}},createHref(T){return a(c,T)},createURL:R,encodeLocation(T){let k=R(T);return{pathname:k.pathname,search:k.search,hash:k.hash}},push:S,replace:C,go(T){return m.go(T)}};return E}function FS(t,a,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 a=="string"?a:Bl(a);return c=c.replace(/ $/,"%20"),!o&&jy.test(c)&&(c=s+c),new URL(c,s)}function _y(t,a,o="/"){return JS(t,a,o,!1)}function JS(t,a,o,s,c){let u=typeof a=="string"?To(a):a,m=na(u.pathname||"/",o);if(m==null)return null;let h=e2(t),v=null,p=d2(m);for(let b=0;v==null&&b<h.length;++b)v=u2(h[b],p,s);return v}function e2(t){let a=Oy(t);return t2(a),a}function Oy(t,a=[],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=bn([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}".`),Oy(m.children,a,S,y,v)),!(m.path==null&&!m.index)&&a.push({path:y,score:i2(y,m.index),routesMeta:S.map((C,R)=>{let[E,T]=zy(C.relativePath,C.caseSensitive,R===S.length-1);return{...C,matcher:E,compiledParams:T}})})};return t.forEach((m,h)=>{if(m.path===""||!m.path?.includes("?"))u(m,h);else for(let v of Dy(m.path))u(m,h,!0,v)}),a}function Dy(t){let a=t.split("/");if(a.length===0)return[];let[o,...s]=a,c=o.endsWith("?"),u=o.replace(/\?$/,"");if(s.length===0)return c?[u,""]:[u];let m=Dy(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 t2(t){t.sort((a,o)=>a.score!==o.score?o.score-a.score:c2(a.routesMeta.map(s=>s.childrenIndex),o.routesMeta.map(s=>s.childrenIndex)))}var n2=/^:[\w-]+$/,a2=3,r2=2,o2=1,l2=10,s2=-2,dv=t=>t==="*";function i2(t,a){let o=t.split("/"),s=o.length;return o.some(dv)&&(s+=s2),a&&(s+=r2),o.filter(c=>!dv(c)).reduce((c,u)=>c+(n2.test(u)?a2:u===""?o2:l2),s)}function c2(t,a){return t.length===a.length&&t.slice(0,-1).every((s,c)=>s===a[c])?t[t.length-1]-a[a.length-1]:0}function u2(t,a,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==="/"?a:a.slice(u.length)||"/",y={path:v.relativePath,caseSensitive:v.caseSensitive,end:p},S=v.matcher&&v.compiledParams?My(y,b,v.matcher,v.compiledParams):Ri(y,b),C=v.route;if(!S&&p&&o&&!s[s.length-1].route.index&&(S=Ri({path:v.relativePath,caseSensitive:v.caseSensitive,end:!1},b)),!S)return null;Object.assign(c,S.params),m.push({params:c,pathname:bn([u,S.pathname]),pathnameBase:h2(bn([u,S.pathnameBase])),route:C}),S.pathnameBase!=="/"&&(u=bn([u,S.pathnameBase]))}return m}function Ri(t,a){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[o,s]=zy(t.path,t.caseSensitive,t.end);return My(t,a,o,s)}function My(t,a,o,s){let c=a.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 R=h[S]||"";m=u.slice(0,u.length-R.length).replace(/(.)\/+$/,"$1")}const C=h[S];return y&&!C?p[b]=void 0:p[b]=(C||"").replace(/%2F/g,"/"),p},{}),pathname:u,pathnameBase:m,pattern:t}}function zy(t,a=!1,o=!0){xn(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,a?void 0:"i"),s]}function d2(t){try{return t.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return xn(!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 (${a}).`),t}}function na(t,a){if(a==="/")return t;if(!t.toLowerCase().startsWith(a.toLowerCase()))return null;let o=a.endsWith("/")?a.length-1:a.length,s=t.charAt(o);return s&&s!=="/"?null:t.slice(o)||"/"}function f2(t,a="/"){let{pathname:o,search:s="",hash:c=""}=typeof t=="string"?To(t):t,u;return o?(o=Ly(o),o.startsWith("/")?u=fv(o.substring(1),"/"):u=fv(o,a)):u=a,{pathname:u,search:p2(s),hash:g2(c)}}function fv(t,a){let o=Ai(a).split("/");return t.split("/").forEach(c=>{c===".."?o.length>1&&o.pop():c!=="."&&o.push(c)}),o.length>1?o.join("/"):"/"}function jd(t,a,o,s){return`Cannot include a '${t}' character in a manually specified \`to.${a}\` 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 m2(t){return t.filter((a,o)=>o===0||a.route.path&&a.route.path.length>0)}function Af(t){let a=m2(t);return a.map((o,s)=>s===a.length-1?o.pathname:o.pathnameBase)}function Ji(t,a,o,s=!1){let c;typeof t=="string"?c=To(t):(c={...t},tt(!c.pathname||!c.pathname.includes("?"),jd("?","pathname","search",c)),tt(!c.pathname||!c.pathname.includes("#"),jd("#","pathname","hash",c)),tt(!c.search||!c.search.includes("#"),jd("#","search","hash",c)));let u=t===""||c.pathname==="",m=u?"/":c.pathname,h;if(m==null)h=o;else{let y=a.length-1;if(!s&&m.startsWith("..")){let S=m.split("/");for(;S[0]==="..";)S.shift(),y-=1;c.pathname=S.join("/")}h=y>=0?a[y]:"/"}let v=f2(c,h),p=m&&m!=="/"&&m.endsWith("/"),b=(u||m===".")&&o.endsWith("/");return!v.pathname.endsWith("/")&&(p||b)&&(v.pathname+="/"),v}var Ly=t=>t.replace(/[\\/]{2,}/g,"/"),bn=t=>Ly(t.join("/")),Ai=t=>t.replace(/\/+$/,""),h2=t=>Ai(t).replace(/^\/*/,"/"),p2=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,g2=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t,v2=class{constructor(t,a,o,s=!1){this.status=t,this.statusText=a||"",this.internal=s,o instanceof Error?(this.data=o.toString(),this.error=o):this.data=o}};function y2(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}function b2(t){let a=t.map(o=>o.route.path).filter(Boolean);return bn(a)||"/"}var Uy=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Hy(t,a){let o=t;if(typeof o!="string"||!Rf.test(o))return{absoluteURL:void 0,isExternal:!1,to:o};let s=o,c=!1;if(Uy)try{let u=new URL(window.location.href),m=jy.test(o)?new URL(QS(o,u.protocol)):new URL(o),h=na(m.pathname,a);m.origin===u.origin&&h!=null?o=h+m.search+m.hash:c=!0}catch{xn(!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 By=["POST","PUT","PATCH","DELETE"];new Set(By);var x2=["GET",...By];new Set(x2);var w2=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function S2(t){try{return w2.includes(new URL(t).protocol)}catch{return!1}}var Co=g.createContext(null);Co.displayName="DataRouter";var ec=g.createContext(null);ec.displayName="DataRouterState";var Py=g.createContext(!1);function E2(){return g.useContext(Py)}var $y=g.createContext({isTransitioning:!1});$y.displayName="ViewTransition";var N2=g.createContext(new Map);N2.displayName="Fetchers";var T2=g.createContext(null);T2.displayName="Await";var Ft=g.createContext(null);Ft.displayName="Navigation";var Xl=g.createContext(null);Xl.displayName="Location";var un=g.createContext({outlet:null,matches:[],isDataRoute:!1});un.displayName="Route";var kf=g.createContext(null);kf.displayName="RouteError";var qy="REACT_ROUTER_ERROR",C2="REDIRECT",R2="ROUTE_ERROR_RESPONSE";function A2(t){if(t.startsWith(`${qy}:${C2}:{`))try{let a=JSON.parse(t.slice(28));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string"&&typeof a.location=="string"&&typeof a.reloadDocument=="boolean"&&typeof a.replace=="boolean")return a}catch{}}function k2(t){if(t.startsWith(`${qy}:${R2}:{`))try{let a=JSON.parse(t.slice(40));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string")return new v2(a.status,a.statusText,a.data)}catch{}}function j2(t,{relative:a}={}){tt(Ro(),"useHref() may be used only in the context of a <Router> component.");let{basename:o,navigator:s}=g.useContext(Ft),{hash:c,pathname:u,search:m}=Ql(t,{relative:a}),h=u;return o!=="/"&&(h=u==="/"?o:bn([o,u])),s.createHref({pathname:h,search:m,hash:c})}function Ro(){return g.useContext(Xl)!=null}function dn(){return tt(Ro(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(Xl).location}var Vy="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Yy(t){g.useContext(Ft).static||g.useLayoutEffect(t)}function Gy(){let{isDataRoute:t}=g.useContext(un);return t?Y2():_2()}function _2(){tt(Ro(),"useNavigate() may be used only in the context of a <Router> component.");let t=g.useContext(Co),{basename:a,navigator:o}=g.useContext(Ft),{matches:s}=g.useContext(un),{pathname:c}=dn(),u=JSON.stringify(Af(s)),m=g.useRef(!1);return Yy(()=>{m.current=!0}),g.useCallback((v,p={})=>{if(xn(m.current,Vy),!m.current)return;if(typeof v=="number"){o.go(v);return}let b=Ji(v,JSON.parse(u),c,p.relative==="path");t==null&&a!=="/"&&(b.pathname=b.pathname==="/"?a:bn([a,b.pathname])),(p.replace?o.replace:o.push)(b,p.state,p)},[a,o,u,c,t])}var Iy=g.createContext(null);function O3(){return g.useContext(Iy)}function O2(t){let a=g.useContext(un).outlet;return g.useMemo(()=>a&&g.createElement(Iy.Provider,{value:t},a),[a,t])}function D3(){let{matches:t}=g.useContext(un);return t[t.length-1]?.params??{}}function Ql(t,{relative:a}={}){let{matches:o}=g.useContext(un),{pathname:s}=dn(),c=JSON.stringify(Af(o));return g.useMemo(()=>Ji(t,JSON.parse(c),s,a==="path"),[t,c,s,a])}function D2(t,a){return Xy(t,a)}function Xy(t,a,o){tt(Ro(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:s}=g.useContext(Ft),{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 T=p&&p.path||"";Ky(h,!p||T.endsWith("*")||T.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${h}" (under <Route path="${T}">) 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="${T}"> to <Route path="${T==="/"?"*":`${T}/*`}">.`)}let b=dn(),y;if(a){let T=typeof a=="string"?To(a):a;tt(v==="/"||T.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 "${T.pathname}" was given in the \`location\` prop.`),y=T}else y=b;let S=y.pathname||"/",C=S;if(v!=="/"){let T=v.replace(/^\//,"").split("/");C="/"+S.replace(/^\//,"").split("/").slice(T.length).join("/")}let R=o&&o.state.matches.length?o.state.matches.map(T=>Object.assign(T,{route:o.manifest[T.route.id]||T.route})):_y(t,{pathname:C});xn(p||R!=null,`No routes matched location "${y.pathname}${y.search}${y.hash}" `),xn(R==null||R[R.length-1].route.element!==void 0||R[R.length-1].route.Component!==void 0||R[R.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 E=H2(R&&R.map(T=>Object.assign({},T,{params:Object.assign({},m,T.params),pathname:bn([v,s.encodeLocation?s.encodeLocation(T.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:T.pathname]),pathnameBase:T.pathnameBase==="/"?v:bn([v,s.encodeLocation?s.encodeLocation(T.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:T.pathnameBase])})),c,o);return a&&E?g.createElement(Xl.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...y},navigationType:"POP"}},E):E}function M2(){let t=V2(),a=y2(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"}},a),o?g.createElement("pre",{style:c},o):null,m)}var z2=g.createElement(M2,null),Qy=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,a){return a.location!==t.location||a.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:a.error,location:a.location,revalidation:t.revalidation||a.revalidation}}componentDidCatch(t,a){this.props.onError?this.props.onError(t,a):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=k2(t.digest);o&&(t=o)}let a=t!==void 0?g.createElement(un.Provider,{value:this.props.routeContext},g.createElement(kf.Provider,{value:t,children:this.props.component})):this.props.children;return this.context?g.createElement(L2,{error:t},a):a}};Qy.contextType=Py;var _d=new WeakMap;function L2({children:t,error:a}){let{basename:o}=g.useContext(Ft);if(typeof a=="object"&&a&&"digest"in a&&typeof a.digest=="string"){let s=A2(a.digest);if(s){let c=_d.get(a);if(c)throw c;let u=Hy(s.location,o),m=u.absoluteURL||u.to;if(S2(m))throw new Error("Invalid redirect location");if(Uy&&!_d.get(a))if(u.isExternal||s.reloadDocument)window.location.href=m;else{const h=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(u.to,{replace:s.replace}));throw _d.set(a,h),h}return g.createElement("meta",{httpEquiv:"refresh",content:`0;url=${m}`})}}return t}function U2({routeContext:t,match:a,children:o}){let s=g.useContext(Co);return s&&s.static&&s.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=a.route.id),g.createElement(un.Provider,{value:t},o)}function H2(t,a=[],o){let s=o?.state;if(t==null){if(!s)return null;if(s.errors)t=s.matches;else if(a.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:C}=s,R=y.route.loader&&!S.hasOwnProperty(y.route.id)&&(!C||C[y.route.id]===void 0);if(y.route.lazy||R){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:b2(s.matches),errorInfo:y})}:void 0;return c.reduceRight((b,y,S)=>{let C,R=!1,E=null,T=null;s&&(C=u&&y.route.id?u[y.route.id]:void 0,E=y.route.errorElement||z2,m&&(h<0&&S===0?(Ky("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),R=!0,T=null):h===S&&(R=!0,T=y.route.hydrateFallbackElement||null)));let k=a.concat(c.slice(0,S+1)),A=()=>{let M;return C?M=E:R?M=T:y.route.Component?M=g.createElement(y.route.Component,null):y.route.element?M=y.route.element:M=b,g.createElement(U2,{match:y,routeContext:{outlet:b,matches:k,isDataRoute:s!=null},children:M})};return s&&(y.route.ErrorBoundary||y.route.errorElement||S===0)?g.createElement(Qy,{location:s.location,revalidation:s.revalidation,component:E,error:C,children:A(),routeContext:{outlet:null,matches:k,isDataRoute:!0},onError:p}):A()},null)}function jf(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function B2(t){let a=g.useContext(Co);return tt(a,jf(t)),a}function P2(t){let a=g.useContext(ec);return tt(a,jf(t)),a}function $2(t){let a=g.useContext(un);return tt(a,jf(t)),a}function _f(t){let a=$2(t),o=a.matches[a.matches.length-1];return tt(o.route.id,`${t} can only be used on routes that contain a unique "id"`),o.route.id}function q2(){return _f("useRouteId")}function V2(){let t=g.useContext(kf),a=P2("useRouteError"),o=_f("useRouteError");return t!==void 0?t:a.errors?.[o]}function Y2(){let{router:t}=B2("useNavigate"),a=_f("useNavigate"),o=g.useRef(!1);return Yy(()=>{o.current=!0}),g.useCallback(async(c,u={})=>{xn(o.current,Vy),o.current&&(typeof c=="number"?await t.navigate(c):await t.navigate(c,{fromRouteId:a,...u}))},[t,a])}var mv={};function Ky(t,a,o){!a&&!mv[t]&&(mv[t]=!0,xn(!1,o))}g.memo(G2);function G2({routes:t,manifest:a,future:o,state:s,isStatic:c,onError:u}){return Xy(t,void 0,{manifest:a,state:s,isStatic:c,onError:u})}function hv({to:t,replace:a,state:o,relative:s}){tt(Ro(),"<Navigate> may be used only in the context of a <Router> component.");let{static:c}=g.useContext(Ft);xn(!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}=dn(),h=Gy(),v=Ji(t,Af(u),m,s==="path"),p=JSON.stringify(v);return g.useEffect(()=>{h(JSON.parse(p),{replace:a,state:o,relative:s})},[h,p,s,a,o]),null}function I2(t){return O2(t.context)}function pr(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 X2({basename:t="/",children:a=null,location:o,navigationType:s="POP",navigator:c,static:u=!1,useTransitions:m}){tt(!Ro(),"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=To(o));let{pathname:p="/",search:b="",hash:y="",state:S=null,key:C="default",mask:R}=o,E=g.useMemo(()=>{let T=na(p,h);return T==null?null:{location:{pathname:T,search:b,hash:y,state:S,key:C,mask:R},navigationType:s}},[h,p,b,y,S,C,s,R]);return xn(E!=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.`),E==null?null:g.createElement(Ft.Provider,{value:v},g.createElement(Xl.Provider,{children:a,value:E}))}function Q2({children:t,location:a}){return D2(ef(t),a)}function ef(t,a=[]){let o=[];return g.Children.forEach(t,(s,c)=>{if(!g.isValidElement(s))return;let u=[...a,c];if(s.type===g.Fragment){o.push.apply(o,ef(s.props.children,u));return}tt(s.type===pr,`[${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=ef(s.props.children,u)),o.push(m)}),o}var bi="get",xi="application/x-www-form-urlencoded";function tc(t){return typeof HTMLElement<"u"&&t instanceof HTMLElement}function K2(t){return tc(t)&&t.tagName.toLowerCase()==="button"}function Z2(t){return tc(t)&&t.tagName.toLowerCase()==="form"}function W2(t){return tc(t)&&t.tagName.toLowerCase()==="input"}function F2(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function J2(t,a){return t.button===0&&(!a||a==="_self")&&!F2(t)}var ii=null;function eE(){if(ii===null)try{new FormData(document.createElement("form"),0),ii=!1}catch{ii=!0}return ii}var tE=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Od(t){return t!=null&&!tE.has(t)?(xn(!1,`"${t}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${xi}"`),null):t}function nE(t,a){let o,s,c,u,m;if(Z2(t)){let h=t.getAttribute("action");s=h?na(h,a):null,o=t.getAttribute("method")||bi,c=Od(t.getAttribute("enctype"))||xi,u=new FormData(t)}else if(K2(t)||W2(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?na(v,a):null,o=t.getAttribute("formmethod")||h.getAttribute("method")||bi,c=Od(t.getAttribute("formenctype"))||Od(h.getAttribute("enctype"))||xi,u=new FormData(h,t),!eE()){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(tc(t))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');o=bi,s=null,c=xi,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 Of(t,a){if(t===!1||t===null||typeof t>"u")throw new Error(a)}function Zy(t,a,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}`:a&&na(c.pathname,a)==="/"?c.pathname=`${Ai(a)}/_root.${s}`:c.pathname=`${Ai(c.pathname)}.${s}`,c}async function aE(t,a){if(t.id in a)return a[t.id];try{let o=await import(t.module);return a[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 rE(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 oE(t,a,o){let s=await Promise.all(t.map(async c=>{let u=a.routes[c.route.id];if(u){let m=await aE(u,o);return m.links?m.links():[]}return[]}));return cE(s.flat(1).filter(rE).filter(c=>c.rel==="stylesheet"||c.rel==="preload").map(c=>c.rel==="stylesheet"?{...c,rel:"prefetch",as:"style"}:{...c,rel:"prefetch"}))}function pv(t,a,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"?a.filter((v,p)=>m(v,p)||h(v,p)):u==="data"?a.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 lE(t,a,{includeHydrateFallback:o}={}){return sE(t.map(s=>{let c=a.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 sE(t){return[...new Set(t)]}function iE(t){let a={},o=Object.keys(t).sort();for(let s of o)a[s]=t[s];return a}function cE(t,a){let o=new Set;return new Set(a),t.reduce((s,c)=>{let u=JSON.stringify(iE(c));return o.has(u)||(o.add(u),s.push({key:u,link:c})),s},[])}function Df(){let t=g.useContext(Co);return Of(t,"You must render this element inside a <DataRouterContext.Provider> element"),t}function uE(){let t=g.useContext(ec);return Of(t,"You must render this element inside a <DataRouterStateContext.Provider> element"),t}var Mf=g.createContext(void 0);Mf.displayName="FrameworkContext";function nc(){let t=g.useContext(Mf);return Of(t,"You must render this element inside a <HydratedRouter> element"),t}function dE(t,a){let o=g.useContext(Mf),[s,c]=g.useState(!1),[u,m]=g.useState(!1),{onFocus:h,onBlur:v,onMouseEnter:p,onMouseLeave:b,onTouchStart:y}=a,S=g.useRef(null);g.useEffect(()=>{if(t==="render"&&m(!0),t==="viewport"){let E=k=>{k.forEach(A=>{m(A.isIntersecting)})},T=new IntersectionObserver(E,{threshold:.5});return S.current&&T.observe(S.current),()=>{T.disconnect()}}},[t]),g.useEffect(()=>{if(s){let E=setTimeout(()=>{m(!0)},100);return()=>{clearTimeout(E)}}},[s]);let C=()=>{c(!0)},R=()=>{c(!1),m(!1)};return o?t!=="intent"?[u,S,{}]:[u,S,{onFocus:kl(h,C),onBlur:kl(v,R),onMouseEnter:kl(p,C),onMouseLeave:kl(b,R),onTouchStart:kl(y,C)}]:[!1,S,{}]}function kl(t,a){return o=>{t&&t(o),o.defaultPrevented||a(o)}}function fE({page:t,...a}){let o=E2(),{nonce:s}=nc(),{router:c}=Df(),u=g.useMemo(()=>_y(c.routes,t,c.basename),[c.routes,t,c.basename]);return u?(a.nonce==null&&s&&(a={...a,nonce:s}),o?g.createElement(hE,{page:t,matches:u,...a}):g.createElement(pE,{page:t,matches:u,...a})):null}function mE(t){let{manifest:a,routeModules:o}=nc(),[s,c]=g.useState([]);return g.useEffect(()=>{let u=!1;return oE(t,a,o).then(m=>{u||c(m)}),()=>{u=!0}},[t,a,o]),s}function hE({page:t,matches:a,...o}){let s=dn(),{future:c}=nc(),{basename:u}=Df(),m=g.useMemo(()=>{if(t===s.pathname+s.search+s.hash)return[];let h=Zy(t,u,c.v8_trailingSlashAwareDataRequests,"rsc"),v=!1,p=[];for(let b of a)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,a]);return g.createElement(g.Fragment,null,m.map(h=>g.createElement("link",{key:h,rel:"prefetch",as:"fetch",href:h,...o})))}function pE({page:t,matches:a,...o}){let s=dn(),{future:c,manifest:u,routeModules:m}=nc(),{basename:h}=Df(),{loaderData:v,matches:p}=uE(),b=g.useMemo(()=>pv(t,a,p,u,s,"data"),[t,a,p,u,s]),y=g.useMemo(()=>pv(t,a,p,u,s,"assets"),[t,a,p,u,s]),S=g.useMemo(()=>{if(t===s.pathname+s.search+s.hash)return[];let E=new Set,T=!1;if(a.forEach(A=>{let M=u.routes[A.route.id];!M||!M.hasLoader||(!b.some(L=>L.route.id===A.route.id)&&A.route.id in v&&m[A.route.id]?.shouldRevalidate||M.hasClientLoader?T=!0:E.add(A.route.id))}),E.size===0)return[];let k=Zy(t,h,c.v8_trailingSlashAwareDataRequests,"data");return T&&E.size>0&&k.searchParams.set("_routes",a.filter(A=>E.has(A.route.id)).map(A=>A.route.id).join(",")),[k.pathname+k.search]},[h,c.v8_trailingSlashAwareDataRequests,v,s,u,b,a,t,m]),C=g.useMemo(()=>lE(y,u),[y,u]),R=mE(y);return g.createElement(g.Fragment,null,S.map(E=>g.createElement("link",{key:E,rel:"prefetch",as:"fetch",href:E,...o})),C.map(E=>g.createElement("link",{key:E,rel:"modulepreload",href:E,...o})),R.map(({key:E,link:T})=>g.createElement("link",{key:E,nonce:o.nonce,...T,crossOrigin:T.crossOrigin??o.crossOrigin})))}function gE(...t){return a=>{t.forEach(o=>{typeof o=="function"?o(a):o!=null&&(o.current=a)})}}var vE=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{vE&&(window.__reactRouterVersion="7.18.0")}catch{}function yE({basename:t,children:a,useTransitions:o,window:s}){let c=g.useRef();c.current==null&&(c.current=KS({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(X2,{basename:t,children:a,location:m.location,navigationType:m.action,navigator:u,useTransitions:o})}var Wy=g.forwardRef(function({onClick:a,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:C,...R},E){let{basename:T,navigator:k,useTransitions:A}=g.useContext(Ft),M=typeof b=="string"&&Rf.test(b),L=Hy(b,T);b=L.to;let H=j2(b,{relative:c}),I=dn(),G=null;if(h){let re=Ji(h,[],I.mask?I.mask.pathname:"/",!0);T!=="/"&&(re.pathname=re.pathname==="/"?T:bn([T,re.pathname])),G=k.createHref(re)}let[V,oe,fe]=dE(s,R),ae=wE(b,{replace:m,mask:h,state:v,target:p,preventScrollReset:y,relative:c,viewTransition:S,defaultShouldRevalidate:C,useTransitions:A});function ie(re){a&&a(re),re.defaultPrevented||ae(re)}let ce=!(L.isExternal||u),ue=g.createElement("a",{...R,...fe,href:(ce?G:void 0)||L.absoluteURL||H,onClick:ce?ie:a,ref:gE(E,oe),target:p,"data-discover":!M&&o==="render"?"true":void 0});return V&&!M?g.createElement(g.Fragment,null,ue,g.createElement(fE,{page:H})):ue});Wy.displayName="Link";var tf=g.forwardRef(function({"aria-current":a="page",caseSensitive:o=!1,className:s="",end:c=!1,style:u,to:m,viewTransition:h,children:v,...p},b){let y=Ql(m,{relative:p.relative}),S=dn(),C=g.useContext(ec),{navigator:R,basename:E}=g.useContext(Ft),T=C!=null&&CE(y)&&h===!0,k=R.encodeLocation?R.encodeLocation(y).pathname:y.pathname,A=S.pathname,M=C&&C.navigation&&C.navigation.location?C.navigation.location.pathname:null;o||(A=A.toLowerCase(),M=M?M.toLowerCase():null,k=k.toLowerCase()),M&&E&&(M=na(M,E)||M);const L=k!=="/"&&k.endsWith("/")?k.length-1:k.length;let H=A===k||!c&&A.startsWith(k)&&A.charAt(L)==="/",I=M!=null&&(M===k||!c&&M.startsWith(k)&&M.charAt(k.length)==="/"),G={isActive:H,isPending:I,isTransitioning:T},V=H?a:void 0,oe;typeof s=="function"?oe=s(G):oe=[s,H?"active":null,I?"pending":null,T?"transitioning":null].filter(Boolean).join(" ");let fe=typeof u=="function"?u(G):u;return g.createElement(Wy,{...p,"aria-current":V,className:oe,ref:b,style:fe,to:m,viewTransition:h},typeof v=="function"?v(G):v)});tf.displayName="NavLink";var bE=g.forwardRef(({discover:t="render",fetcherKey:a,navigate:o,reloadDocument:s,replace:c,state:u,method:m=bi,action:h,onSubmit:v,relative:p,preventScrollReset:b,viewTransition:y,defaultShouldRevalidate:S,...C},R)=>{let{useTransitions:E}=g.useContext(Ft),T=NE(),k=TE(h,{relative:p}),A=m.toLowerCase()==="get"?"get":"post",M=typeof h=="string"&&Rf.test(h),L=H=>{if(v&&v(H),H.defaultPrevented)return;H.preventDefault();let I=H.nativeEvent.submitter,G=I?.getAttribute("formmethod")||m,V=()=>T(I||H.currentTarget,{fetcherKey:a,method:G,navigate:o,replace:c,state:u,relative:p,preventScrollReset:b,viewTransition:y,defaultShouldRevalidate:S});E&&o!==!1?g.startTransition(()=>V()):V()};return g.createElement("form",{ref:R,method:A,action:k,onSubmit:s?v:L,...C,"data-discover":!M&&t==="render"?"true":void 0})});bE.displayName="Form";function xE(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Fy(t){let a=g.useContext(Co);return tt(a,xE(t)),a}function wE(t,{target:a,replace:o,mask:s,state:c,preventScrollReset:u,relative:m,viewTransition:h,defaultShouldRevalidate:v,useTransitions:p}={}){let b=Gy(),y=dn(),S=Ql(t,{relative:m});return g.useCallback(C=>{if(J2(C,a)){C.preventDefault();let R=o!==void 0?o:Bl(y)===Bl(S),E=()=>b(t,{replace:R,mask:s,state:c,preventScrollReset:u,relative:m,viewTransition:h,defaultShouldRevalidate:v});p?g.startTransition(()=>E()):E()}},[y,b,S,o,s,c,a,t,u,m,h,v,p])}var SE=0,EE=()=>`__${String(++SE)}__`;function NE(){let{router:t}=Fy("useSubmit"),{basename:a}=g.useContext(Ft),o=q2(),s=t.fetch,c=t.navigate;return g.useCallback(async(u,m={})=>{let{action:h,method:v,encType:p,formData:b,body:y}=nE(u,a);if(m.navigate===!1){let S=m.fetcherKey||EE();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,a,o])}function TE(t,{relative:a}={}){let{basename:o}=g.useContext(Ft),s=g.useContext(un);tt(s,"useFormAction must be used inside a RouteContext");let[c]=s.matches.slice(-1),u={...Ql(t||".",{relative:a})},m=dn();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:bn([o,u.pathname])),Bl(u)}function CE(t,{relative:a}={}){let o=g.useContext($y);tt(o!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:s}=Fy("useViewTransitionState"),c=Ql(t,{relative:a});if(!o.isTransitioning)return!1;let u=na(o.currentLocation.pathname,s)||o.currentLocation.pathname,m=na(o.nextLocation.pathname,s)||o.nextLocation.pathname;return Ri(c.pathname,m)!=null||Ri(c.pathname,u)!=null}var Kl=Ay();const Jy=Ry(Kl),RE="/api";function e0(t){const a=new Headers(t?.headers);return t?.body!==void 0&&t.body!==null&&!a.has("Content-Type")&&a.set("Content-Type","application/json"),a}function t0(t,a){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 a}async function ve(t,a){const o=await fetch(`${RE}${t}`,{credentials:"include",...a,headers:e0(a)});if(!o.ok){const s=await o.json().catch(()=>o.statusText);throw new Error(t0(s,`HTTP ${o.status}`))}return o.json()}async function AE(t,a){const o=await fetch(t,{credentials:"include",...a,headers:e0(a)});if(!o.ok){const s=await o.json().catch(()=>o.statusText);throw new Error(t0(s,`HTTP ${o.status}`))}return o.json()}function Ao(t,a){return ve(t,{...a,cache:"no-store"})}function n0(t){return ve(`/node-operations/${t}`)}async function a0(t={}){const a=new URLSearchParams;t.nodeId&&a.set("nodeId",t.nodeId),t.status&&a.set("status",t.status),t.kind&&a.set("kind",t.kind);const o=a.toString();return(await ve(`/node-operations${o?`?${o}`:""}`)).operations}function kE(t,a){return ve(`/node-operations/${encodeURIComponent(t)}/terminate`,{method:"POST",body:JSON.stringify({reason:a})})}function gv(t){return ve(`/nodes/${t}/copilot-tunnel/enable`,{method:"POST"})}function vv(t){return ve(`/nodes/${t}/copilot-tunnel/status`,{method:"POST"})}function yv(t){return ve(`/nodes/${t}/copilot-tunnel/disable`,{method:"POST"})}function jE(){return AE("/_auth/session")}function _E(){return ve("/system/info")}function OE(t){return ve("/system/default-task-agent",{method:"PUT",body:JSON.stringify({defaultTaskAgent:t})})}function M3(t){return ve("/system/transport",{method:"POST",body:JSON.stringify({type:t})})}function r0(t){return ve("/system/runtime/restart",{method:"POST",body:JSON.stringify(t)})}function DE(){return ve("/system/runtime/stop",{method:"POST"})}function ME(){return ve("/cluster/state")}function z3(){return ve("/cluster/promote",{method:"POST"})}function L3(t){return ve("/cluster/connect",{method:"POST",body:JSON.stringify(t)})}function U3(){return ve("/cluster/disconnect",{method:"POST"})}function H3(t={}){return ve("/mobile/pairings",{method:"POST",body:JSON.stringify(t)})}function B3(t){return ve(`/mobile/pairings/${encodeURIComponent(t)}`)}function zE(t,a){return ve(`/nodes/${t}/agents/${a}/upgrade`,{method:"POST"})}function LE(t,a){return ve(`/nodes/${t}/runtime/restart`,{method:"POST",body:JSON.stringify(a)})}async function P3(){return(await ve("/devboxes")).devboxes}function $3(t,a){return ve(`/nodes/${t}/devbox/configure`,{method:"POST",body:JSON.stringify({devbox:a})})}function q3(t){return ve(`/nodes/${t}/devbox/status`)}function V3(t){return ve(`/nodes/${t}/devbox/start`,{method:"POST"})}function Y3(t,a){return ve(`/nodes/${t}/devtunnel`,{method:"POST",body:JSON.stringify({enabled:a})})}function G3(t,a={}){const o=new URLSearchParams;a.path&&o.set("path",a.path),a.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,a.limit),100))),a.offset!==void 0&&o.set("offset",String(Math.max(0,a.offset))),a.directoriesOnly!==void 0&&o.set("directoriesOnly",String(a.directoriesOnly)),a.allowAbsolute!==void 0&&o.set("allowAbsolute",String(a.allowAbsolute));const s=o.toString();return ve(`/nodes/${t}/workdir/tree${s?`?${s}`:""}`)}function I3(t,a={}){const o=new URLSearchParams;a.path&&o.set("path",a.path),a.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,a.limit),20))),a.offset!==void 0&&o.set("offset",String(Math.max(0,a.offset))),a.allowAbsolute!==void 0&&o.set("allowAbsolute",String(a.allowAbsolute));const s=o.toString();return ve(`/nodes/${t}/workdir/branch${s?`?${s}`:""}`)}function X3(t,a){const o=new URLSearchParams;return o.set("agent",a.agent),o.set("limit",String(Math.min(Math.max(1,a.limit),100))),ve(`/nodes/${t}/native-sessions?${o.toString()}`)}function Q3(t,a){return ve(`/nodes/${t}/workdir/branch`,{method:"POST",body:JSON.stringify({path:a.path,branchName:a.branchName,startPoint:a.startPoint,limit:a.limit,offset:a.offset,allowAbsolute:a.allowAbsolute})})}function K3(t,a){return ve(`/nodes/${t}/terminal/sessions`,{method:"POST",body:JSON.stringify(a)})}function Z3(t){return ve(`/nodes/${t}/terminal/sessions`)}function W3(t,a){return ve(`/nodes/${t}/terminal/sessions/${a}`)}function F3(t,a){return ve(`/nodes/${t}/terminal/sessions/${a}/stop`,{method:"POST"})}function zf(t,a){t.set("scope",a.kind),a.kind==="project"&&t.set("projectPath",a.projectPath)}function J3(t,a){const o=new URLSearchParams;return zf(o,a.scope),a.agents?.length&&o.set("agents",a.agents.join(",")),ve(`/nodes/${encodeURIComponent(t)}/capabilities?${o.toString()}`)}function eO(t,a,o){const s=new URLSearchParams;o&&zf(s,o);const c=s.toString();return ve(`/nodes/${encodeURIComponent(t)}/capabilities/${encodeURIComponent(a)}${c?`?${c}`:""}`)}function tO(t,a,o){const s=new URLSearchParams;o&&zf(s,o);const c=s.toString();return ve(`/nodes/${encodeURIComponent(t)}/capabilities/${encodeURIComponent(a)}${c?`?${c}`:""}`,{method:"DELETE"})}function nO(t){return ve("/capabilities/conflict-check",{method:"POST",body:JSON.stringify(t)})}function aO(t){return ve("/capabilities/share",{method:"POST",body:JSON.stringify(t)})}async function rO(t){const a=new URLSearchParams;if(t?.status&&a.set("status",t.status),t?.assignedTo&&a.set("assignedTo",t.assignedTo),t?.priority&&a.set("priority",t.priority),t?.limit){const s=Math.min(Math.max(1,t.limit),100);a.set("limit",String(s))}if(t?.offset&&a.set("offset",String(t.offset)),t?.projectPath&&a.set("projectPath",t.projectPath),t?.cursor&&a.set("cursor",t.cursor),t?.completedLimitPerProject!==void 0){const s=Math.min(Math.max(1,t.completedLimitPerProject),100);a.set("completedLimitPerProject",String(s))}const o=a.toString();return ve(`/tasks${o?`?${o}`:""}`)}function oO(t){return ve(`/tasks/${t}`)}function lO(t){return ve("/tasks",{method:"POST",body:JSON.stringify(t)})}function sO(t){return ve("/tasks/import-session",{method:"POST",body:JSON.stringify(t)})}function iO(t){return ve(`/tasks/${t}`,{method:"DELETE"})}function cO(t,a){return ve(`/tasks/${t}`,{method:"PATCH",body:JSON.stringify(a)})}function uO(t){return ve("/tasks/batch/delete",{method:"POST",body:JSON.stringify({ids:t})})}function dO(t){return ve("/tasks/batch/archive",{method:"POST",body:JSON.stringify({ids:t})})}function fO(t){return ve(`/tasks/${t}`,{method:"PATCH",body:JSON.stringify({status:"archived"})})}function mO(t){return ve(`/tasks/${t}/cancel`,{method:"POST"})}function hO(t){return ve(`/tasks/${t}/retry`,{method:"POST"})}function pO(t,a,o={}){const s=new URLSearchParams;a!==void 0&&s.set("after",String(a)),o.minTotal!==void 0&&s.set("minTotal",String(o.minTotal));const c=s.size>0?`?${s.toString()}`:"";return ve(`/tasks/${t}/logs${c}`)}function gO(t,a,o){return ve(`/tasks/${t}/message`,{method:"POST",body:JSON.stringify({content:a,...o?{targetAgent:o}:{}})})}function vO(t,a){return ve(`/tasks/${t}/queued-messages/${encodeURIComponent(a)}`,{method:"DELETE"})}function yO(t,a){return ve(`/tasks/${t}/share`,{method:"POST",body:JSON.stringify(a)})}function bO(t){return ve(`/tasks/${t}/share`,{method:"DELETE"})}function xO(t){return Ao(`/shared/conversations/${encodeURIComponent(t)}`)}function wO(t,a){return Ao(`/shared/conversations/${encodeURIComponent(t)}/logs`)}function SO(t){return Ao(`/shared/conversations/${encodeURIComponent(t)}/output`)}function EO(t,a="."){return Ao(`/shared/conversations/${encodeURIComponent(t)}/output/tree?path=${encodeURIComponent(a)}`)}function NO(t,a){return Ao(`/shared/conversations/${encodeURIComponent(t)}/output/content?path=${encodeURIComponent(a)}`)}function TO(t,a){return Ao(`/shared/conversations/${encodeURIComponent(t)}/output/preview-sessions`,{method:"POST",body:JSON.stringify(a?{path:a}:{})})}function o0(t){return t?typeof t=="string"?{path:t}:{...t.path?{path:t.path}:{},...t.port!==void 0?{port:t.port}:{}}:{}}function CO(t){return ve(`/tasks/${t}/output`)}function RO(t,a="."){return ve(`/tasks/${t}/output/tree?path=${encodeURIComponent(a)}`)}function AO(t,a){return ve(`/tasks/${t}/output/content?path=${encodeURIComponent(a)}`)}function kO(t,a){return ve(`/tasks/${t}/output/preview-sessions`,{method:"POST",body:JSON.stringify(o0(a))})}function jO(t,a){return ve(`/nodes/${t}/preview-sessions`,{method:"POST",body:JSON.stringify(o0(a))})}function _O(t){return ve(`/tasks/${t}/output/diff`)}function UE({hasStarted:t,enabled:a}){return a&&!t}function HE(t,a,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();UE({hasStarted:c.current,enabled:o})&&(c.current=!0,u());const m=setInterval(u,a);return()=>clearInterval(m)},[a,o])}function BE(t){return t?t.replace(/\/+$/,""):""}function PE(t){const a=t??"/api";return a?a.startsWith("/")?a.replace(/\/+$/,""):`/${a.replace(/\/+$/,"")}`:""}function Dd(...t){const a=new Headers;for(const o of t){if(!o)continue;new Headers(o).forEach((c,u)=>a.set(u,c))}return a}var $E=class extends Error{status;statusText;code;details;body;constructor(t,a){super(t),this.name="MeshyApiError",this.status=a.status,this.statusText=a.statusText,this.code=a.code,this.details=a.details,this.body=a.body}};function qE(t,a){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:a}}function jl(t,a){const o=a.toString();return o?`${t}?${o}`:t}function Kt(t,a,o){o!==void 0&&t.set(a,String(o))}function ci(t){return t===null||Array.isArray(t)||typeof t=="object"&&t!==null&&!(t instanceof ArrayBuffer)}function bv(t){return t?typeof t=="string"?{path:t}:{...t.path?{path:t.path}:{},...t.port!==void 0?{port:t.port}:{}}:{}}var VE=class{baseUrl;apiPrefix;defaultHeaders;credentials;fetchImpl;config;constructor(t={}){const a=t.fetchImpl??((o,s)=>globalThis.fetch(o,s));if(!a)throw new Error("MeshyClient requires a fetch implementation");this.fetchImpl=a,this.baseUrl=BE(t.baseUrl),this.apiPrefix=PE(t.apiPrefix),this.defaultHeaders=Dd(t.defaultHeaders),this.credentials=t.credentials,this.config=t}buildApiUrl(t){const a=t.startsWith("/")?t:`/${t}`;return`${this.baseUrl}${this.apiPrefix}${a}`}buildApiurl(t){return this.buildApiUrl(t)}async buildRequestHeaders(t={}){const a=await this.config.tokenProvider?.(),o=await this.config.headersProvider?.();return Dd(t.accept?{Accept:t.accept}:{Accept:"application/json"},t.json?{"Content-Type":"application/json"}:void 0,this.config.defaultHeaders,o,a?{Authorization:`Bearer ${a}`}:void 0,t.headers)}async fetchApi(t,a={}){const o=a.timeoutMs??this.config.timeoutMs,s=o?new AbortController:null;let c=null;s&&(c=setTimeout(()=>s.abort(),o));const u=await this.buildRequestHeaders({json:ci(a.body),headers:a.headers}),m=ci(a.body)?JSON.stringify(a.body):a.body;try{return await this.fetchImpl(this.buildApiUrl(t),{...a,headers:u,body:m,credentials:a.credentials??this.config.credentials,signal:a.signal??s?.signal})}finally{c&&clearTimeout(c)}}async request(t,a={}){const o=a.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=a.credentials??this.config.credentials,v=Dd({Accept:"application/json"},ci(a.body)?{"Content-Type":"application/json"}:void 0,this.config.defaultHeaders,m,u?{Authorization:`Bearer ${u}`}:void 0,a.headers),p=ci(a.body)?JSON.stringify(a.body):a.body;try{const b=await this.fetchImpl(this.buildApiUrl(t),{...a,headers:v,body:p,credentials:h,signal:a.signal??s?.signal});if(!b.ok){const y=await b.json().catch(()=>b.statusText),S=qE(y,`HTTP ${b.status}`);throw new $E(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 a=new URLSearchParams;return Kt(a,"status",t.status),Kt(a,"capability",t.capability),(await this.request(jl("/nodes",a))).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,a){return this.request(`/nodes/${encodeURIComponent(t)}`,{method:"PATCH",body:a})}toggleNodeDevTunnel(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/devtunnel`,{method:"POST",body:{enabled:a}})}getNodeOperation(t){return this.request(`/node-operations/${encodeURIComponent(t)}`)}async listNodeOperations(t={}){const a=new URLSearchParams;return Kt(a,"nodeId",t.nodeId),Kt(a,"status",t.status),Kt(a,"kind",t.kind),(await this.request(jl("/node-operations",a))).operations}upgradeNodeAgent(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/agents/${a}/upgrade`,{method:"POST"})}restartNodeRuntime(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/runtime/restart`,{method:"POST",body:a})}getNodeWorkDirTree(t,a={}){const o=new URLSearchParams;return Kt(o,"path",a.path),a.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,a.limit),100))),a.offset!==void 0&&o.set("offset",String(Math.max(0,a.offset))),Kt(o,"directoriesOnly",a.directoriesOnly),Kt(o,"allowAbsolute",a.allowAbsolute),this.request(jl(`/nodes/${encodeURIComponent(t)}/workdir/tree`,o))}getNodeWorkDirBranchInfo(t,a={}){const o=new URLSearchParams;return Kt(o,"path",a.path),a.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,a.limit),20))),a.offset!==void 0&&o.set("offset",String(Math.max(0,a.offset))),Kt(o,"allowAbsolute",a.allowAbsolute),this.request(jl(`/nodes/${encodeURIComponent(t)}/workdir/branch`,o))}createNodeWorkDirBranch(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/workdir/branch`,{method:"POST",body:a})}createNodePreviewSession(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/preview-sessions`,{method:"POST",body:bv(a)})}getNodeNativeSessions(t,a){const o=new URLSearchParams;return o.set("agent",a.agent),a.limit!==void 0&&o.set("limit",String(Math.min(Math.max(1,a.limit),100))),this.request(`/nodes/${encodeURIComponent(t)}/native-sessions?${o.toString()}`)}hideNodeNativeSession(t,a,o){return this.request(`/nodes/${encodeURIComponent(t)}/native-sessions/${encodeURIComponent(a)}/${encodeURIComponent(o)}`,{method:"DELETE"})}hideNodeNativeSessionFolder(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/native-sessions/folders/hide`,{method:"POST",body:a})}startNodeTerminalSession(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions`,{method:"POST",body:a})}listNodeTerminalSessions(t){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions`)}getNodeTerminalSession(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions/${encodeURIComponent(a)}`)}stopNodeTerminalSession(t,a){return this.request(`/nodes/${encodeURIComponent(t)}/terminal/sessions/${encodeURIComponent(a)}/stop`,{method:"POST"})}async getTasks(t={}){const a=new URLSearchParams;return Kt(a,"status",t.status),Kt(a,"assignedTo",t.assignedTo),Kt(a,"priority",t.priority),t.limit&&a.set("limit",String(Math.min(Math.max(1,t.limit),100))),t.offset&&a.set("offset",String(t.offset)),(await this.request(jl("/tasks",a))).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,a){return this.request(`/tasks/${encodeURIComponent(t)}`,{method:"PATCH",body:{title:a}})}cancelTask(t){return this.request(`/tasks/${encodeURIComponent(t)}/cancel`,{method:"POST"})}retryTask(t){return this.request(`/tasks/${encodeURIComponent(t)}/retry`,{method:"POST"})}assignTask(t,a){return this.request(`/tasks/${encodeURIComponent(t)}/assign`,{method:"POST",body:{nodeId:a}})}getTaskLogs(t,a){return this.request(`/tasks/${encodeURIComponent(t)}/logs${a!==void 0?`?after=${a}`:""}`)}sendTaskMessage(t,a){return this.request(`/tasks/${encodeURIComponent(t)}/message`,{method:"POST",body:{content:a}})}createTaskShare(t,a){return this.request(`/tasks/${encodeURIComponent(t)}/share`,{method:"POST",body:a})}deleteTaskShare(t){return this.request(`/tasks/${encodeURIComponent(t)}/share`,{method:"DELETE"})}getSharedConversation(t){return this.request(`/shared/conversations/${encodeURIComponent(t)}`)}getSharedConversationLogs(t,a){return this.request(`/shared/conversations/${encodeURIComponent(t)}/logs${a!==void 0?`?after=${a}`:""}`)}getSharedTaskOutput(t){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output`)}getSharedTaskOutputTree(t,a="."){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output/tree?path=${encodeURIComponent(a)}`)}getSharedTaskOutputContent(t,a){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output/content?path=${encodeURIComponent(a)}`)}createSharedTaskPreviewSession(t,a){return this.request(`/shared/conversations/${encodeURIComponent(t)}/output/preview-sessions`,{method:"POST",body:a?{path:a}:{}})}getTaskOutput(t){return this.request(`/tasks/${encodeURIComponent(t)}/output`)}getTaskOutputTree(t,a="."){return this.request(`/tasks/${encodeURIComponent(t)}/output/tree?path=${encodeURIComponent(a)}`)}getTaskOutputContent(t,a){return this.request(`/tasks/${encodeURIComponent(t)}/output/content?path=${encodeURIComponent(a)}`)}createTaskPreviewSession(t,a){return this.request(`/tasks/${encodeURIComponent(t)}/output/preview-sessions`,{method:"POST",body:bv(a)})}getTaskOutputDiff(t){return this.request(`/tasks/${encodeURIComponent(t)}/output/diff`)}},YE=new VE,GE=["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"],IE=0,XE=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??GE,this.eventSourceFactory=t.eventSourceFactory??(QE(t.client)?void 0:ZE()),this.pollIntervalMs=t.pollIntervalMs??1e4,this.poll=t.poll}start(){if(!(this.eventSource||this.pollTimer)){if(this.eventSourceFactory){const t=new this.eventSourceFactory(KE(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 a of this.eventTypes)t.addEventListener(a,o=>this.emit({id:String(++IE),type:a,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,a){const o=++this.listenerId;return this.listeners.set(o,{pattern:t,callback:a}),()=>this.listeners.delete(o)}onConnectionChange(t){const a=++this.listenerId;return this.connectionListeners.set(a,t),t(this.connected),()=>this.connectionListeners.delete(a)}isConnected(){return this.connected}emit(t){for(const{pattern:a,callback:o}of this.listeners.values())t.type.startsWith(a)&&o(t)}setConnected(t){if(this.connected!==t){this.connected=t;for(const a of this.connectionListeners.values())a(t)}}startPolling(){!this.poll||this.pollTimer||(this.pollTimer=setInterval(()=>{this.poll?.().then(()=>this.setConnected(!0)).catch(()=>{this.setConnected(!1)})},this.pollIntervalMs))}};function QE(t){return t.defaultHeaders.has("x-tunnel-authorization")}function KE(t,a){const o=t.buildApiUrl??t.buildApiurl;if(!o)throw new Error("MeshyClient is missing buildApiUrl");return o.call(t,a)}function ZE(){return globalThis.EventSource}var WE=3,FE="mmp";function OO(t){return JSON.stringify({t:FE,v:WE,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 JE(t=50){const[a,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 XE({client:YE});u.current=b;const y=b.subscribe("",C=>{const R=C;o(E=>[R,...E].slice(0,t));for(const[,{pattern:E,callback:T}]of h.current)R.type.startsWith(E)&&T(R)}),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:a,connected:s,subscribe:v,clearEvents:p}}const eN=1e4,tN=6e4,nN=eN,aN=250,rN=new Set(["node.joined","node.left","task.created","task.assigned","task.deleted"]),oN=new Set(["task.created","task.assigned","task.status","task.deleted"]);function lN(t){return t?tN:nN}function DO(t){return rN.has(t)}function sN(t){return oN.has(t)}function iN(t,a){if(!a)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:a.leaderId!==o||a.term!==s||a.nodeCount!==c}function cN(t,a,o){if(t==="node.joined"||t==="node.left"||t!=="node.status")return!0;const s=a.nodeId,c=a.status;return typeof s!="string"||typeof c!="string"?!0:o.get(s)!==c}function MO(t,a){const o=a.taskId,s=a.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 a?a.result:s==="completed"?null:m.result,v="error"in a?a.error:s==="completed"?null:m.error;return{...m,status:s,result:h,error:v}});return c?u:t}function zO(t,a){const o=a.taskId;if(typeof o!="string")return t;const s=t.filter(c=>c.id!==o);return s.length===t.length?t:s}const Lf=g.createContext(null);function uN({children:t}){const[a,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:C,subscribe:R}=JE(),E=g.useCallback(async()=>{try{const[k,A]=await Promise.all([ME(),_E()]),M=k,L=A.nodeId??A.id,H=M.nodes??[],I=H.find(oe=>oe.id===L)??{id:L,name:A.name,endpoint:A.endpoint,role:A.role,status:A.status,capabilities:A.capabilities,joinedAt:A.joinedAt,lastHeartbeat:A.lastHeartbeat},G=M.leaderId?H.find(oe=>oe.id===M.leaderId)??null:null,V={leader:G?{id:G.id,name:G.name,endpoint:G.endpoint,...G.dashboardOrigin?{dashboardOrigin:G.dashboardOrigin}:{}}:null,term:M.term??0,nodes:H,self:I,taskSummary:M.taskSummary??{total:0,pending:0,running:0,completed:0,failed:0}};b.current={leaderId:V.leader?.id??null,term:V.term,nodeCount:V.nodes.length},y.current=new Map(V.nodes.map(oe=>[oe.id,oe.status])),y.current.set(V.self.id,V.self.status),o(V),c(A),v(null)}catch(k){v(k instanceof Error?k.message:"Failed to fetch cluster state")}finally{m(!1)}},[]),T=g.useCallback(()=>{p.current===null&&(p.current=window.setTimeout(()=>{p.current=null,E()},aN))},[E]);return HE(E,lN(C)),g.useEffect(()=>()=>{p.current!==null&&(window.clearTimeout(p.current),p.current=null)},[]),g.useEffect(()=>{const k=[R("cluster",A=>{iN(A.data,b.current)&&T()}),R("election",T),R("node",A=>{cN(A.type,A.data,y.current)&&T()}),R("transport",T),R("task",A=>{sN(A.type)&&T()})];return()=>k.forEach(A=>A())},[R,T]),f.jsx(Lf.Provider,{value:{cluster:a,systemInfo:s,events:S,sseConnected:C,subscribe:R,refresh:E,loading:u,error:h},children:t})}function l0(){const t=g.useContext(Lf);if(!t)throw new Error("useCluster must be used within ClusterProvider");return t}function LO(){return g.useContext(Lf)}/**
|
|
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 s0=(...t)=>t.filter((a,o,s)=>!!a&&a.trim()!==""&&s.indexOf(a)===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 dN=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 fN=t=>t.replace(/^([A-Z])|[\s-_]+(\w)/g,(a,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 xv=t=>{const a=fN(t);return a.charAt(0).toUpperCase()+a.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 Md={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 mN=t=>{for(const a in t)if(a.startsWith("aria-")||a==="role"||a==="title")return!0;return!1},hN=g.createContext({}),pN=()=>g.useContext(hN),gN=g.forwardRef(({color:t,size:a,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:C=""}=pN()??{},R=s??y?Number(o??b)*24/Number(a??p):o??b;return g.createElement("svg",{ref:v,...Md,width:a??p??Md.width,height:a??p??Md.height,stroke:t??S,strokeWidth:R,className:s0("lucide",C,c),...!u&&!mN(h)&&{"aria-hidden":"true"},...h},[...m.map(([E,T])=>g.createElement(E,T)),...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 Re=(t,a)=>{const o=g.forwardRef(({className:s,...c},u)=>g.createElement(gN,{ref:u,iconNode:a,className:s0(`lucide-${dN(xv(t))}`,`lucide-${t}`,s),...c}));return o.displayName=xv(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 vN=[["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"}]],ki=Re("activity",vN);/**
|
|
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 yN=[["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"}]],bN=Re("book-open",yN);/**
|
|
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 xN=[["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"}]],ji=Re("bot",xN);/**
|
|
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 wN=[["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"}]],i0=Re("cable",wN);/**
|
|
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 SN=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],_i=Re("check",SN);/**
|
|
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 EN=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],gr=Re("chevron-down",EN);/**
|
|
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 NN=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],TN=Re("chevron-left",NN);/**
|
|
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 CN=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],Oi=Re("chevron-right",CN);/**
|
|
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 RN=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],AN=Re("chevron-up",RN);/**
|
|
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 kN=[["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"}]],Ml=Re("circle-alert",kN);/**
|
|
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 jN=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],bo=Re("circle-check",jN);/**
|
|
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 _N=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]],wv=Re("circle-dot",_N);/**
|
|
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 ON=[["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"}]],Sv=Re("circle-x",ON);/**
|
|
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 DN=[["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"}]],c0=Re("copy",DN);/**
|
|
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 MN=[["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"}]],u0=Re("external-link",MN);/**
|
|
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 zN=[["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"}]],LN=Re("folder",zN);/**
|
|
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 UN=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],d0=Re("info",UN);/**
|
|
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 HN=[["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"}]],BN=Re("key-round",HN);/**
|
|
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 PN=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],ac=Re("loader-circle",PN);/**
|
|
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 $N=[["path",{d:"m10 17 5-5-5-5",key:"1bsop3"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}]],qN=Re("log-in",$N);/**
|
|
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 VN=[["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"}]],Uf=Re("message-square-text",VN);/**
|
|
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 YN=[["path",{d:"M5 12h14",key:"1ays0h"}]],GN=Re("minus",YN);/**
|
|
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:"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"}]],XN=Re("monitor-cog",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 QN=[["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"}]],f0=Re("monitor",QN);/**
|
|
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 KN=[["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"}]],m0=Re("moon",KN);/**
|
|
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 ZN=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],WN=Re("plus",ZN);/**
|
|
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 FN=[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]],JN=Re("power",FN);/**
|
|
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 eT=[["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"}]],wi=Re("refresh-cw",eT);/**
|
|
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 tT=[["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"}]],Ev=Re("rocket",tT);/**
|
|
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 nT=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],aT=Re("rotate-ccw",nT);/**
|
|
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 rT=[["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"}]],oT=Re("save",rT);/**
|
|
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 lT=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],sT=Re("search",lT);/**
|
|
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 iT=[["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"}]],cT=Re("server",iT);/**
|
|
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 uT=[["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"}]],dT=Re("settings",uT);/**
|
|
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 fT=[["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"}]],mT=Re("sparkles",fT);/**
|
|
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 hT=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]],pT=Re("square",hT);/**
|
|
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 gT=[["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"}]],h0=Re("sun",gT);/**
|
|
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 vT=[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]],p0=Re("terminal",vT);/**
|
|
287
|
+
* @license lucide-react v1.7.0 - ISC
|
|
288
|
+
*
|
|
289
|
+
* This source code is licensed under the ISC license.
|
|
290
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
291
|
+
*/const yT=[["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"}]],bT=Re("trash-2",yT);/**
|
|
292
|
+
* @license lucide-react v1.7.0 - ISC
|
|
293
|
+
*
|
|
294
|
+
* This source code is licensed under the ISC license.
|
|
295
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
296
|
+
*/const xT=[["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"}]],wT=Re("wifi-off",xT);/**
|
|
297
|
+
* @license lucide-react v1.7.0 - ISC
|
|
298
|
+
*
|
|
299
|
+
* This source code is licensed under the ISC license.
|
|
300
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
301
|
+
*/const ST=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Hf=Re("x",ST);function g0(t){var a,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(a=0;a<c;a++)t[a]&&(o=g0(t[a]))&&(s&&(s+=" "),s+=o)}else for(o in t)t[o]&&(s&&(s+=" "),s+=o);return s}function v0(){for(var t,a,o=0,s="",c=arguments.length;o<c;o++)(t=arguments[o])&&(a=g0(t))&&(s&&(s+=" "),s+=a);return s}const ET=(t,a)=>{const o=new Array(t.length+a.length);for(let s=0;s<t.length;s++)o[s]=t[s];for(let s=0;s<a.length;s++)o[t.length+s]=a[s];return o},NT=(t,a)=>({classGroupId:t,validator:a}),y0=(t=new Map,a=null,o)=>({nextPart:t,validators:a,classGroupId:o}),Di="-",Nv=[],TT="arbitrary..",CT=t=>{const a=AT(t),{conflictingClassGroups:o,conflictingClassGroupModifiers:s}=t;return{getClassGroupId:m=>{if(m.startsWith("[")&&m.endsWith("]"))return RT(m);const h=m.split(Di),v=h[0]===""&&h.length>1?1:0;return b0(h,v,a)},getConflictingClassGroupIds:(m,h)=>{if(h){const v=s[m],p=o[m];return v?p?ET(p,v):v:p||Nv}return o[m]||Nv}}},b0=(t,a,o)=>{if(t.length-a===0)return o.classGroupId;const c=t[a],u=o.nextPart.get(c);if(u){const p=b0(t,a+1,u);if(p)return p}const m=o.validators;if(m===null)return;const h=a===0?t.join(Di):t.slice(a).join(Di),v=m.length;for(let p=0;p<v;p++){const b=m[p];if(b.validator(h))return b.classGroupId}},RT=t=>t.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const a=t.slice(1,-1),o=a.indexOf(":"),s=a.slice(0,o);return s?TT+s:void 0})(),AT=t=>{const{theme:a,classGroups:o}=t;return kT(o,a)},kT=(t,a)=>{const o=y0();for(const s in t){const c=t[s];Bf(c,o,s,a)}return o},Bf=(t,a,o,s)=>{const c=t.length;for(let u=0;u<c;u++){const m=t[u];jT(m,a,o,s)}},jT=(t,a,o,s)=>{if(typeof t=="string"){_T(t,a,o);return}if(typeof t=="function"){OT(t,a,o,s);return}DT(t,a,o,s)},_T=(t,a,o)=>{const s=t===""?a:x0(a,t);s.classGroupId=o},OT=(t,a,o,s)=>{if(MT(t)){Bf(t(s),a,o,s);return}a.validators===null&&(a.validators=[]),a.validators.push(NT(o,t))},DT=(t,a,o,s)=>{const c=Object.entries(t),u=c.length;for(let m=0;m<u;m++){const[h,v]=c[m];Bf(v,x0(a,h),o,s)}},x0=(t,a)=>{let o=t;const s=a.split(Di),c=s.length;for(let u=0;u<c;u++){const m=s[u];let h=o.nextPart.get(m);h||(h=y0(),o.nextPart.set(m,h)),o=h}return o},MT=t=>"isThemeGetter"in t&&t.isThemeGetter===!0,zT=t=>{if(t<1)return{get:()=>{},set:()=>{}};let a=0,o=Object.create(null),s=Object.create(null);const c=(u,m)=>{o[u]=m,a++,a>t&&(a=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)}}},nf="!",Tv=":",LT=[],Cv=(t,a,o,s,c)=>({modifiers:t,hasImportantModifier:a,baseClassName:o,maybePostfixModifierPosition:s,isExternal:c}),UT=t=>{const{prefix:a,experimentalParseClassName:o}=t;let s=c=>{const u=[];let m=0,h=0,v=0,p;const b=c.length;for(let E=0;E<b;E++){const T=c[E];if(m===0&&h===0){if(T===Tv){u.push(c.slice(v,E)),v=E+1;continue}if(T==="/"){p=E;continue}}T==="["?m++:T==="]"?m--:T==="("?h++:T===")"&&h--}const y=u.length===0?c:c.slice(v);let S=y,C=!1;y.endsWith(nf)?(S=y.slice(0,-1),C=!0):y.startsWith(nf)&&(S=y.slice(1),C=!0);const R=p&&p>v?p-v:void 0;return Cv(u,C,S,R)};if(a){const c=a+Tv,u=s;s=m=>m.startsWith(c)?u(m.slice(c.length)):Cv(LT,!1,m,void 0,!0)}if(o){const c=s;s=u=>o({className:u,parseClassName:c})}return s},HT=t=>{const a=new Map;return t.orderSensitiveModifiers.forEach((o,s)=>{a.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=a.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}},BT=t=>({cache:zT(t.cacheSize),parseClassName:UT(t),sortModifiers:HT(t),...CT(t)}),PT=/\s+/,$T=(t,a)=>{const{parseClassName:o,getClassGroupId:s,getConflictingClassGroupIds:c,sortModifiers:u}=a,m=[],h=t.trim().split(PT);let v="";for(let p=h.length-1;p>=0;p-=1){const b=h[p],{isExternal:y,modifiers:S,hasImportantModifier:C,baseClassName:R,maybePostfixModifierPosition:E}=o(b);if(y){v=b+(v.length>0?" "+v:v);continue}let T=!!E,k=s(T?R.substring(0,E):R);if(!k){if(!T){v=b+(v.length>0?" "+v:v);continue}if(k=s(R),!k){v=b+(v.length>0?" "+v:v);continue}T=!1}const A=S.length===0?"":S.length===1?S[0]:u(S).join(":"),M=C?A+nf:A,L=M+k;if(m.indexOf(L)>-1)continue;m.push(L);const H=c(k,T);for(let I=0;I<H.length;++I){const G=H[I];m.push(M+G)}v=b+(v.length>0?" "+v:v)}return v},qT=(...t)=>{let a=0,o,s,c="";for(;a<t.length;)(o=t[a++])&&(s=w0(o))&&(c&&(c+=" "),c+=s);return c},w0=t=>{if(typeof t=="string")return t;let a,o="";for(let s=0;s<t.length;s++)t[s]&&(a=w0(t[s]))&&(o&&(o+=" "),o+=a);return o},VT=(t,...a)=>{let o,s,c,u;const m=v=>{const p=a.reduce((b,y)=>y(b),t());return o=BT(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=$T(v,o);return c(v,b),b};return u=m,(...v)=>u(qT(...v))},YT=[],bt=t=>{const a=o=>o[t]||YT;return a.isThemeGetter=!0,a},S0=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,E0=/^\((?:(\w[\w-]*):)?(.+)\)$/i,GT=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,IT=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,XT=/\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$/,QT=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,KT=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,ZT=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Da=t=>GT.test(t),_e=t=>!!t&&!Number.isNaN(Number(t)),Ma=t=>!!t&&Number.isInteger(Number(t)),zd=t=>t.endsWith("%")&&_e(t.slice(0,-1)),ta=t=>IT.test(t),N0=()=>!0,WT=t=>XT.test(t)&&!QT.test(t),Pf=()=>!1,FT=t=>KT.test(t),JT=t=>ZT.test(t),eC=t=>!pe(t)&&!ge(t),tC=t=>$a(t,R0,Pf),pe=t=>S0.test(t),fr=t=>$a(t,A0,WT),Rv=t=>$a(t,cC,_e),nC=t=>$a(t,j0,N0),aC=t=>$a(t,k0,Pf),Av=t=>$a(t,T0,Pf),rC=t=>$a(t,C0,JT),ui=t=>$a(t,_0,FT),ge=t=>E0.test(t),_l=t=>Er(t,A0),oC=t=>Er(t,k0),kv=t=>Er(t,T0),lC=t=>Er(t,R0),sC=t=>Er(t,C0),di=t=>Er(t,_0,!0),iC=t=>Er(t,j0,!0),$a=(t,a,o)=>{const s=S0.exec(t);return s?s[1]?a(s[1]):o(s[2]):!1},Er=(t,a,o=!1)=>{const s=E0.exec(t);return s?s[1]?a(s[1]):o:!1},T0=t=>t==="position"||t==="percentage",C0=t=>t==="image"||t==="url",R0=t=>t==="length"||t==="size"||t==="bg-size",A0=t=>t==="length",cC=t=>t==="number",k0=t=>t==="family-name",j0=t=>t==="number"||t==="weight",_0=t=>t==="shadow",uC=()=>{const t=bt("color"),a=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"),C=bt("drop-shadow"),R=bt("blur"),E=bt("perspective"),T=bt("aspect"),k=bt("ease"),A=bt("animate"),M=()=>["auto","avoid","all","avoid-page","page","left","right","column"],L=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],H=()=>[...L(),ge,pe],I=()=>["auto","hidden","clip","visible","scroll"],G=()=>["auto","contain","none"],V=()=>[ge,pe,v],oe=()=>[Da,"full","auto",...V()],fe=()=>[Ma,"none","subgrid",ge,pe],ae=()=>["auto",{span:["full",Ma,ge,pe]},Ma,ge,pe],ie=()=>[Ma,"auto",ge,pe],ce=()=>["auto","min","max","fr",ge,pe],ue=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],re=()=>["start","end","center","stretch","center-safe","end-safe"],_=()=>["auto",...V()],$=()=>[Da,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...V()],O=()=>[Da,"screen","full","dvw","lvw","svw","min","max","fit",...V()],W=()=>[Da,"screen","full","lh","dvh","lvh","svh","min","max","fit",...V()],N=()=>[t,ge,pe],Y=()=>[...L(),kv,Av,{position:[ge,pe]}],ne=()=>["no-repeat",{repeat:["","x","y","space","round"]}],X=()=>["auto","cover","contain",lC,tC,{size:[ge,pe]}],F=()=>[zd,_l,fr],ee=()=>["","none","full",p,ge,pe],te=()=>["",_e,_l,fr],se=()=>["solid","dashed","dotted","double"],de=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],xe=()=>[_e,zd,kv,Av],Ae=()=>["","none",R,ge,pe],Ne=()=>["none",_e,ge,pe],ke=()=>["none",_e,ge,pe],Je=()=>[_e,ge,pe],at=()=>[Da,"full",...V()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ta],breakpoint:[ta],color:[N0],container:[ta],"drop-shadow":[ta],ease:["in","out","in-out"],font:[eC],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ta],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ta],shadow:[ta],spacing:["px",_e],text:[ta],"text-shadow":[ta],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Da,pe,ge,T]}],container:["container"],columns:[{columns:[_e,pe,ge,h]}],"break-after":[{"break-after":M()}],"break-before":[{"break-before":M()}],"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:H()}],overflow:[{overflow:I()}],"overflow-x":[{"overflow-x":I()}],"overflow-y":[{"overflow-y":I()}],overscroll:[{overscroll:G()}],"overscroll-x":[{"overscroll-x":G()}],"overscroll-y":[{"overscroll-y":G()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:oe()}],"inset-x":[{"inset-x":oe()}],"inset-y":[{"inset-y":oe()}],start:[{"inset-s":oe(),start:oe()}],end:[{"inset-e":oe(),end:oe()}],"inset-bs":[{"inset-bs":oe()}],"inset-be":[{"inset-be":oe()}],top:[{top:oe()}],right:[{right:oe()}],bottom:[{bottom:oe()}],left:[{left:oe()}],visibility:["visible","invisible","collapse"],z:[{z:[Ma,"auto",ge,pe]}],basis:[{basis:[Da,"full","auto",h,...V()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[_e,Da,"auto","initial","none",pe]}],grow:[{grow:["",_e,ge,pe]}],shrink:[{shrink:["",_e,ge,pe]}],order:[{order:[Ma,"first","last","none",ge,pe]}],"grid-cols":[{"grid-cols":fe()}],"col-start-end":[{col:ae()}],"col-start":[{"col-start":ie()}],"col-end":[{"col-end":ie()}],"grid-rows":[{"grid-rows":fe()}],"row-start-end":[{row:ae()}],"row-start":[{"row-start":ie()}],"row-end":[{"row-end":ie()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":ce()}],"auto-rows":[{"auto-rows":ce()}],gap:[{gap:V()}],"gap-x":[{"gap-x":V()}],"gap-y":[{"gap-y":V()}],"justify-content":[{justify:[...ue(),"normal"]}],"justify-items":[{"justify-items":[...re(),"normal"]}],"justify-self":[{"justify-self":["auto",...re()]}],"align-content":[{content:["normal",...ue()]}],"align-items":[{items:[...re(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...re(),{baseline:["","last"]}]}],"place-content":[{"place-content":ue()}],"place-items":[{"place-items":[...re(),"baseline"]}],"place-self":[{"place-self":["auto",...re()]}],p:[{p:V()}],px:[{px:V()}],py:[{py:V()}],ps:[{ps:V()}],pe:[{pe:V()}],pbs:[{pbs:V()}],pbe:[{pbe:V()}],pt:[{pt:V()}],pr:[{pr:V()}],pb:[{pb:V()}],pl:[{pl:V()}],m:[{m:_()}],mx:[{mx:_()}],my:[{my:_()}],ms:[{ms:_()}],me:[{me:_()}],mbs:[{mbs:_()}],mbe:[{mbe:_()}],mt:[{mt:_()}],mr:[{mr:_()}],mb:[{mb:_()}],ml:[{ml:_()}],"space-x":[{"space-x":V()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":V()}],"space-y-reverse":["space-y-reverse"],size:[{size:$()}],"inline-size":[{inline:["auto",...O()]}],"min-inline-size":[{"min-inline":["auto",...O()]}],"max-inline-size":[{"max-inline":["none",...O()]}],"block-size":[{block:["auto",...W()]}],"min-block-size":[{"min-block":["auto",...W()]}],"max-block-size":[{"max-block":["none",...W()]}],w:[{w:[h,"screen",...$()]}],"min-w":[{"min-w":[h,"screen","none",...$()]}],"max-w":[{"max-w":[h,"screen","none","prose",{screen:[m]},...$()]}],h:[{h:["screen","lh",...$()]}],"min-h":[{"min-h":["screen","lh","none",...$()]}],"max-h":[{"max-h":["screen","lh",...$()]}],"font-size":[{text:["base",o,_l,fr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[s,iC,nC]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",zd,pe]}],"font-family":[{font:[oC,aC,a]}],"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,Rv]}],leading:[{leading:[u,...V()]}],"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:[...se(),"wavy"]}],"text-decoration-thickness":[{decoration:[_e,"from-font","auto",ge,fr]}],"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:V()}],"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:Y()}],"bg-repeat":[{bg:ne()}],"bg-size":[{bg:X()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ma,ge,pe],radial:["",ge,pe],conic:[Ma,ge,pe]},sC,rC]}],"bg-color":[{bg:N()}],"gradient-from-pos":[{from:F()}],"gradient-via-pos":[{via:F()}],"gradient-to-pos":[{to:F()}],"gradient-from":[{from:N()}],"gradient-via":[{via:N()}],"gradient-to":[{to:N()}],rounded:[{rounded:ee()}],"rounded-s":[{"rounded-s":ee()}],"rounded-e":[{"rounded-e":ee()}],"rounded-t":[{"rounded-t":ee()}],"rounded-r":[{"rounded-r":ee()}],"rounded-b":[{"rounded-b":ee()}],"rounded-l":[{"rounded-l":ee()}],"rounded-ss":[{"rounded-ss":ee()}],"rounded-se":[{"rounded-se":ee()}],"rounded-ee":[{"rounded-ee":ee()}],"rounded-es":[{"rounded-es":ee()}],"rounded-tl":[{"rounded-tl":ee()}],"rounded-tr":[{"rounded-tr":ee()}],"rounded-br":[{"rounded-br":ee()}],"rounded-bl":[{"rounded-bl":ee()}],"border-w":[{border:te()}],"border-w-x":[{"border-x":te()}],"border-w-y":[{"border-y":te()}],"border-w-s":[{"border-s":te()}],"border-w-e":[{"border-e":te()}],"border-w-bs":[{"border-bs":te()}],"border-w-be":[{"border-be":te()}],"border-w-t":[{"border-t":te()}],"border-w-r":[{"border-r":te()}],"border-w-b":[{"border-b":te()}],"border-w-l":[{"border-l":te()}],"divide-x":[{"divide-x":te()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":te()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...se(),"hidden","none"]}],"divide-style":[{divide:[...se(),"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:[...se(),"none","hidden"]}],"outline-offset":[{"outline-offset":[_e,ge,pe]}],"outline-w":[{outline:["",_e,_l,fr]}],"outline-color":[{outline:N()}],shadow:[{shadow:["","none",b,di,ui]}],"shadow-color":[{shadow:N()}],"inset-shadow":[{"inset-shadow":["none",y,di,ui]}],"inset-shadow-color":[{"inset-shadow":N()}],"ring-w":[{ring:te()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:N()}],"ring-offset-w":[{"ring-offset":[_e,fr]}],"ring-offset-color":[{"ring-offset":N()}],"inset-ring-w":[{"inset-ring":te()}],"inset-ring-color":[{"inset-ring":N()}],"text-shadow":[{"text-shadow":["none",S,di,ui]}],"text-shadow-color":[{"text-shadow":N()}],opacity:[{opacity:[_e,ge,pe]}],"mix-blend":[{"mix-blend":[...de(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":de()}],"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":L()}],"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:Y()}],"mask-repeat":[{mask:ne()}],"mask-size":[{mask:X()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",ge,pe]}],filter:[{filter:["","none",ge,pe]}],blur:[{blur:Ae()}],brightness:[{brightness:[_e,ge,pe]}],contrast:[{contrast:[_e,ge,pe]}],"drop-shadow":[{"drop-shadow":["","none",C,di,ui]}],"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":Ae()}],"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":V()}],"border-spacing-x":[{"border-spacing-x":V()}],"border-spacing-y":[{"border-spacing-y":V()}],"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",k,ge,pe]}],delay:[{delay:[_e,ge,pe]}],animate:[{animate:["none",A,ge,pe]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[E,ge,pe]}],"perspective-origin":[{"perspective-origin":H()}],rotate:[{rotate:Ne()}],"rotate-x":[{"rotate-x":Ne()}],"rotate-y":[{"rotate-y":Ne()}],"rotate-z":[{"rotate-z":Ne()}],scale:[{scale:ke()}],"scale-x":[{"scale-x":ke()}],"scale-y":[{"scale-y":ke()}],"scale-z":[{"scale-z":ke()}],"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:H()}],"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":V()}],"scroll-mx":[{"scroll-mx":V()}],"scroll-my":[{"scroll-my":V()}],"scroll-ms":[{"scroll-ms":V()}],"scroll-me":[{"scroll-me":V()}],"scroll-mbs":[{"scroll-mbs":V()}],"scroll-mbe":[{"scroll-mbe":V()}],"scroll-mt":[{"scroll-mt":V()}],"scroll-mr":[{"scroll-mr":V()}],"scroll-mb":[{"scroll-mb":V()}],"scroll-ml":[{"scroll-ml":V()}],"scroll-p":[{"scroll-p":V()}],"scroll-px":[{"scroll-px":V()}],"scroll-py":[{"scroll-py":V()}],"scroll-ps":[{"scroll-ps":V()}],"scroll-pe":[{"scroll-pe":V()}],"scroll-pbs":[{"scroll-pbs":V()}],"scroll-pbe":[{"scroll-pbe":V()}],"scroll-pt":[{"scroll-pt":V()}],"scroll-pr":[{"scroll-pr":V()}],"scroll-pb":[{"scroll-pb":V()}],"scroll-pl":[{"scroll-pl":V()}],"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,_l,fr,Rv]}],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"]}},dC=VT(uC);function J(...t){return dC(v0(t))}function fC(t){if(typeof document>"u")return;let a=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",a.appendChild(o),o.styleSheet?o.styleSheet.cssText=t:o.appendChild(document.createTextNode(t))}const mC=t=>{switch(t){case"success":return gC;case"info":return yC;case"warning":return vC;case"error":return bC;default:return null}},hC=Array(12).fill(0),pC=({visible:t,className:a})=>le.createElement("div",{className:["sonner-loading-wrapper",a].filter(Boolean).join(" "),"data-visible":t},le.createElement("div",{className:"sonner-spinner"},hC.map((o,s)=>le.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${s}`})))),gC=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},le.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"})),vC=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},le.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"})),yC=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},le.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"})),bC=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},le.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"})),xC=le.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"},le.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),le.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),wC=()=>{const[t,a]=le.useState(document.hidden);return le.useEffect(()=>{const o=()=>{a(document.hidden)};return document.addEventListener("visibilitychange",o),()=>window.removeEventListener("visibilitychange",o)},[]),t};let af=1;class SC{constructor(){this.subscribe=a=>(this.subscribers.push(a),()=>{const o=this.subscribers.indexOf(a);this.subscribers.splice(o,1)}),this.publish=a=>{this.subscribers.forEach(o=>o(a))},this.addToast=a=>{this.publish(a),this.toasts=[...this.toasts,a]},this.create=a=>{var o;const{message:s,...c}=a,u=typeof a?.id=="number"||((o=a.id)==null?void 0:o.length)>0?a.id:af++,m=this.toasts.find(v=>v.id===u),h=a.dismissible===void 0?!0:a.dismissible;return this.dismissedToasts.has(u)&&this.dismissedToasts.delete(u),m?this.toasts=this.toasts.map(v=>v.id===u?(this.publish({...v,...a,id:u,title:s}),{...v,...a,id:u,dismissible:h,title:s}):v):this.addToast({title:s,...c,dismissible:h,id:u}),u},this.dismiss=a=>(a?(this.dismissedToasts.add(a),requestAnimationFrame(()=>this.subscribers.forEach(o=>o({id:a,dismiss:!0})))):this.toasts.forEach(o=>{this.subscribers.forEach(s=>s({id:o.id,dismiss:!0}))}),a),this.message=(a,o)=>this.create({...o,message:a}),this.error=(a,o)=>this.create({...o,message:a,type:"error"}),this.success=(a,o)=>this.create({...o,type:"success",message:a}),this.info=(a,o)=>this.create({...o,type:"info",message:a}),this.warning=(a,o)=>this.create({...o,type:"warning",message:a}),this.loading=(a,o)=>this.create({...o,type:"loading",message:a}),this.promise=(a,o)=>{if(!o)return;let s;o.loading!==void 0&&(s=this.create({...o,promise:a,type:"loading",message:o.loading,description:typeof o.description!="function"?o.description:void 0}));const c=Promise.resolve(a instanceof Function?a():a);let u=s!==void 0,m;const h=c.then(async p=>{if(m=["resolve",p],le.isValidElement(p))u=!1,this.create({id:s,type:"default",message:p});else if(NC(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,R=typeof y=="object"&&!le.isValidElement(y)?y:{message:y};this.create({id:s,type:"error",description:S,...R})}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,R=typeof y=="object"&&!le.isValidElement(y)?y:{message:y};this.create({id:s,type:"error",description:S,...R})}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,R=typeof y=="object"&&!le.isValidElement(y)?y:{message:y};this.create({id:s,type:"success",description:S,...R})}}).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,C=typeof b=="object"&&!le.isValidElement(b)?b:{message:b};this.create({id:s,type:"error",description:y,...C})}}).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=(a,o)=>{const s=o?.id||af++;return this.create({jsx:a(s),id:s,...o}),s},this.getActiveToasts=()=>this.toasts.filter(a=>!this.dismissedToasts.has(a.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const Pt=new SC,EC=(t,a)=>{const o=a?.id||af++;return Pt.addToast({title:t,...a,id:o}),o},NC=t=>t&&typeof t=="object"&&"ok"in t&&typeof t.ok=="boolean"&&"status"in t&&typeof t.status=="number",TC=EC,CC=()=>Pt.toasts,RC=()=>Pt.getActiveToasts(),Te=Object.assign(TC,{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:CC,getToasts:RC});fC("[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 fi(t){return t.label!==void 0}const AC=3,kC="24px",jC="16px",jv=4e3,_C=356,OC=14,DC=45,MC=200;function _n(...t){return t.filter(Boolean).join(" ")}function zC(t){const[a,o]=t.split("-"),s=[];return a&&s.push(a),o&&s.push(o),s}const LC=t=>{var a,o,s,c,u,m,h,v,p;const{invert:b,toast:y,unstyled:S,interacting:C,setHeights:R,visibleToasts:E,heights:T,index:k,toasts:A,expanded:M,removeToast:L,defaultRichColors:H,closeButton:I,style:G,cancelButtonStyle:V,actionButtonStyle:oe,className:fe="",descriptionClassName:ae="",duration:ie,position:ce,gap:ue,expandByDefault:re,classNames:_,icons:$,closeButtonAriaLabel:O="Close toast"}=t,[W,N]=le.useState(null),[Y,ne]=le.useState(null),[X,F]=le.useState(!1),[ee,te]=le.useState(!1),[se,de]=le.useState(!1),[xe,Ae]=le.useState(!1),[Ne,ke]=le.useState(!1),[Je,at]=le.useState(0),[fn,mn]=le.useState(0),lt=le.useRef(y.duration||ie||jv),Ga=le.useRef(null),ht=le.useRef(null),Nr=k===0,Ln=k+1<=E,st=y.type,hn=y.dismissible!==!1,Tr=y.className||"",sa=y.descriptionClassName||"",$t=le.useMemo(()=>T.findIndex(me=>me.toastId===y.id)||0,[T,y.id]),Ct=le.useMemo(()=>{var me;return(me=y.closeButton)!=null?me:I},[y.closeButton,I]),Mt=le.useMemo(()=>y.duration||ie||jv,[y.duration,ie]),We=le.useRef(0),Nn=le.useRef(0),Cr=le.useRef(0),Tn=le.useRef(null),[ia,ca]=ce.split("-"),Jt=le.useMemo(()=>T.reduce((me,Ue,Qe)=>Qe>=$t?me:me+Ue.height,0),[T,$t]),Un=wC(),Hn=y.invert||b,ua=st==="loading";Nn.current=le.useMemo(()=>$t*ue+Jt,[$t,Jt]),le.useEffect(()=>{lt.current=Mt},[Mt]),le.useEffect(()=>{F(!0)},[]),le.useEffect(()=>{const me=ht.current;if(me){const Ue=me.getBoundingClientRect().height;return mn(Ue),R(Qe=>[{toastId:y.id,height:Ue,position:y.position},...Qe]),()=>R(Qe=>Qe.filter(pt=>pt.toastId!==y.id))}},[R,y.id]),le.useLayoutEffect(()=>{if(!X)return;const me=ht.current,Ue=me.style.height;me.style.height="auto";const Qe=me.getBoundingClientRect().height;me.style.height=Ue,mn(Qe),R(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])},[X,y.title,y.description,R,y.id,y.jsx,y.action,y.cancel]);const zt=le.useCallback(()=>{te(!0),at(Nn.current),R(me=>me.filter(Ue=>Ue.toastId!==y.id)),setTimeout(()=>{L(y)},MC)},[y,L,R,Nn]);le.useEffect(()=>{if(y.promise&&st==="loading"||y.duration===1/0||y.type==="loading")return;let me;return M||C||Un?(()=>{if(Cr.current<We.current){const pt=new Date().getTime()-We.current;lt.current=lt.current-pt}Cr.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)},[M,C,y,st,Un,zt]),le.useEffect(()=>{y.delete&&(zt(),y.onDismiss==null||y.onDismiss.call(y,y))},[zt,y.delete]);function Ia(){var me;if($?.loading){var Ue;return le.createElement("div",{className:_n(_?.loader,y==null||(Ue=y.classNames)==null?void 0:Ue.loader,"sonner-loader"),"data-visible":st==="loading"},$.loading)}return le.createElement(pC,{className:_n(_?.loader,y==null||(me=y.classNames)==null?void 0:me.loader),visible:st==="loading"})}const Xa=y.icon||$?.[st]||mC(st);var be,Xe;return le.createElement("li",{tabIndex:0,ref:ht,className:_n(fe,Tr,_?.toast,y==null||(a=y.classNames)==null?void 0:a.toast,_?.default,_?.[st],y==null||(o=y.classNames)==null?void 0:o[st]),"data-sonner-toast":"","data-rich-colors":(be=y.richColors)!=null?be:H,"data-styled":!(y.jsx||y.unstyled||S),"data-mounted":X,"data-promise":!!y.promise,"data-swiped":Ne,"data-removed":ee,"data-visible":Ln,"data-y-position":ia,"data-x-position":ca,"data-index":k,"data-front":Nr,"data-swiping":se,"data-dismissible":hn,"data-type":st,"data-invert":Hn,"data-swipe-out":xe,"data-swipe-direction":Y,"data-expanded":!!(M||re&&X),"data-testid":y.testId,style:{"--index":k,"--toasts-before":k,"--z-index":A.length-k,"--offset":`${ee?Je:Nn.current}px`,"--initial-height":re?"auto":`${fn}px`,...G,...y.style},onDragEnd:()=>{de(!1),N(null),Tn.current=null},onPointerDown:me=>{me.button!==2&&(ua||!hn||(Ga.current=new Date,at(Nn.current),me.target.setPointerCapture(me.pointerId),me.target.tagName!=="BUTTON"&&(de(!0),Tn.current={x:me.clientX,y:me.clientY})))},onPointerUp:()=>{var me,Ue,Qe;if(xe||!hn)return;Tn.current=null;const pt=Number(((me=ht.current)==null?void 0:me.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Qa=Number(((Ue=ht.current)==null?void 0:Ue.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),gt=new Date().getTime()-((Qe=Ga.current)==null?void 0:Qe.getTime()),it=W==="x"?pt:Qa,ct=Math.abs(it)/gt;if(Math.abs(it)>=DC||ct>.11){at(Nn.current),y.onDismiss==null||y.onDismiss.call(y,y),ne(W==="x"?pt>0?"right":"left":Qa>0?"down":"up"),zt(),Ae(!0);return}else{var Ke,wt;(Ke=ht.current)==null||Ke.style.setProperty("--swipe-amount-x","0px"),(wt=ht.current)==null||wt.style.setProperty("--swipe-amount-y","0px")}ke(!1),de(!1),N(null)},onPointerMove:me=>{var Ue,Qe,pt;if(!Tn.current||!hn||((Ue=window.getSelection())==null?void 0:Ue.toString().length)>0)return;const gt=me.clientY-Tn.current.y,it=me.clientX-Tn.current.x;var ct;const Ke=(ct=t.swipeDirections)!=null?ct:zC(ce);!W&&(Math.abs(it)>1||Math.abs(gt)>1)&&N(Math.abs(it)>Math.abs(gt)?"x":"y");let wt={x:0,y:0};const Rr=Bn=>1/(1.5+Math.abs(Bn)/20);if(W==="y"){if(Ke.includes("top")||Ke.includes("bottom"))if(Ke.includes("top")&><0||Ke.includes("bottom")&>>0)wt.y=gt;else{const Bn=gt*Rr(gt);wt.y=Math.abs(Bn)<Math.abs(gt)?Bn:gt}}else if(W==="x"&&(Ke.includes("left")||Ke.includes("right")))if(Ke.includes("left")&&it<0||Ke.includes("right")&&it>0)wt.x=it;else{const Bn=it*Rr(it);wt.x=Math.abs(Bn)<Math.abs(it)?Bn:it}(Math.abs(wt.x)>0||Math.abs(wt.y)>0)&&ke(!0),(Qe=ht.current)==null||Qe.style.setProperty("--swipe-amount-x",`${wt.x}px`),(pt=ht.current)==null||pt.style.setProperty("--swipe-amount-y",`${wt.y}px`)}},Ct&&!y.jsx&&st!=="loading"?le.createElement("button",{"aria-label":O,"data-disabled":ua,"data-close-button":!0,onClick:ua||!hn?()=>{}:()=>{zt(),y.onDismiss==null||y.onDismiss.call(y,y)},className:_n(_?.closeButton,y==null||(s=y.classNames)==null?void 0:s.closeButton)},(Xe=$?.close)!=null?Xe:xC):null,(st||y.icon||y.promise)&&y.icon!==null&&($?.[st]!==null||y.icon)?le.createElement("div",{"data-icon":"",className:_n(_?.icon,y==null||(c=y.classNames)==null?void 0:c.icon)},y.promise||y.type==="loading"&&!y.icon?y.icon||Ia():null,y.type!=="loading"?Xa:null):null,le.createElement("div",{"data-content":"",className:_n(_?.content,y==null||(u=y.classNames)==null?void 0:u.content)},le.createElement("div",{"data-title":"",className:_n(_?.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?le.createElement("div",{"data-description":"",className:_n(ae,sa,_?.description,y==null||(h=y.classNames)==null?void 0:h.description)},typeof y.description=="function"?y.description():y.description):null),le.isValidElement(y.cancel)?y.cancel:y.cancel&&fi(y.cancel)?le.createElement("button",{"data-button":!0,"data-cancel":!0,style:y.cancelButtonStyle||V,onClick:me=>{fi(y.cancel)&&hn&&(y.cancel.onClick==null||y.cancel.onClick.call(y.cancel,me),zt())},className:_n(_?.cancelButton,y==null||(v=y.classNames)==null?void 0:v.cancelButton)},y.cancel.label):null,le.isValidElement(y.action)?y.action:y.action&&fi(y.action)?le.createElement("button",{"data-button":!0,"data-action":!0,style:y.actionButtonStyle||oe,onClick:me=>{fi(y.action)&&(y.action.onClick==null||y.action.onClick.call(y.action,me),!me.defaultPrevented&&zt())},className:_n(_?.actionButton,y==null||(p=y.classNames)==null?void 0:p.actionButton)},y.action.label):null)};function _v(){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 UC(t,a){const o={};return[t,a].forEach((s,c)=>{const u=c===1,m=u?"--mobile-offset":"--offset",h=u?jC:kC;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 HC=le.forwardRef(function(a,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:C,duration:R,style:E,visibleToasts:T=AC,toastOptions:k,dir:A=_v(),gap:M=OC,icons:L,containerAriaLabel:H="Notifications"}=a,[I,G]=le.useState([]),V=le.useMemo(()=>s?I.filter(X=>X.toasterId===s):I.filter(X=>!X.toasterId),[I,s]),oe=le.useMemo(()=>Array.from(new Set([u].concat(V.filter(X=>X.position).map(X=>X.position)))),[V,u]),[fe,ae]=le.useState([]),[ie,ce]=le.useState(!1),[ue,re]=le.useState(!1),[_,$]=le.useState(S!=="system"?S:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),O=le.useRef(null),W=m.join("+").replace(/Key/g,"").replace(/Digit/g,""),N=le.useRef(null),Y=le.useRef(!1),ne=le.useCallback(X=>{G(F=>{var ee;return(ee=F.find(te=>te.id===X.id))!=null&&ee.delete||Pt.dismiss(X.id),F.filter(({id:te})=>te!==X.id)})},[]);return le.useEffect(()=>Pt.subscribe(X=>{if(X.dismiss){requestAnimationFrame(()=>{G(F=>F.map(ee=>ee.id===X.id?{...ee,delete:!0}:ee))});return}setTimeout(()=>{Jy.flushSync(()=>{G(F=>{const ee=F.findIndex(te=>te.id===X.id);return ee!==-1?[...F.slice(0,ee),{...F[ee],...X},...F.slice(ee+1)]:[X,...F]})})})}),[I]),le.useEffect(()=>{if(S!=="system"){$(S);return}if(S==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?$("dark"):$("light")),typeof window>"u")return;const X=window.matchMedia("(prefers-color-scheme: dark)");try{X.addEventListener("change",({matches:F})=>{$(F?"dark":"light")})}catch{X.addListener(({matches:ee})=>{try{$(ee?"dark":"light")}catch(te){console.error(te)}})}},[S]),le.useEffect(()=>{I.length<=1&&ce(!1)},[I]),le.useEffect(()=>{const X=F=>{var ee;if(m.every(de=>F[de]||F.code===de)){var se;ce(!0),(se=O.current)==null||se.focus()}F.code==="Escape"&&(document.activeElement===O.current||(ee=O.current)!=null&&ee.contains(document.activeElement))&&ce(!1)};return document.addEventListener("keydown",X),()=>document.removeEventListener("keydown",X)},[m]),le.useEffect(()=>{if(O.current)return()=>{N.current&&(N.current.focus({preventScroll:!0}),N.current=null,Y.current=!1)}},[O.current]),le.createElement("section",{ref:o,"aria-label":`${H} ${W}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},oe.map((X,F)=>{var ee;const[te,se]=X.split("-");return V.length?le.createElement("ol",{key:X,dir:A==="auto"?_v():A,tabIndex:-1,ref:O,className:p,"data-sonner-toaster":!0,"data-sonner-theme":_,"data-y-position":te,"data-x-position":se,style:{"--front-toast-height":`${((ee=fe[0])==null?void 0:ee.height)||0}px`,"--width":`${_C}px`,"--gap":`${M}px`,...E,...UC(b,y)},onBlur:de=>{Y.current&&!de.currentTarget.contains(de.relatedTarget)&&(Y.current=!1,N.current&&(N.current.focus({preventScroll:!0}),N.current=null))},onFocus:de=>{de.target instanceof HTMLElement&&de.target.dataset.dismissible==="false"||Y.current||(Y.current=!0,N.current=de.relatedTarget)},onMouseEnter:()=>ce(!0),onMouseMove:()=>ce(!0),onMouseLeave:()=>{ue||ce(!1)},onDragEnd:()=>ce(!1),onPointerDown:de=>{de.target instanceof HTMLElement&&de.target.dataset.dismissible==="false"||re(!0)},onPointerUp:()=>re(!1)},V.filter(de=>!de.position&&F===0||de.position===X).map((de,xe)=>{var Ae,Ne;return le.createElement(LC,{key:de.id,icons:L,index:xe,toast:de,defaultRichColors:C,duration:(Ae=k?.duration)!=null?Ae:R,className:k?.className,descriptionClassName:k?.descriptionClassName,invert:c,visibleToasts:T,closeButton:(Ne=k?.closeButton)!=null?Ne:v,interacting:ue,position:X,style:k?.style,unstyled:k?.unstyled,classNames:k?.classNames,cancelButtonStyle:k?.cancelButtonStyle,actionButtonStyle:k?.actionButtonStyle,closeButtonAriaLabel:k?.closeButtonAriaLabel,removeToast:ne,toasts:V.filter(ke=>ke.position==de.position),heights:fe.filter(ke=>ke.position==de.position),setHeights:ae,expandByDefault:h,gap:M,expanded:ie,swipeDirections:a.swipeDirections})})):null}))}),Ov=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,Dv=v0,O0=(t,a)=>o=>{var s;if(a?.variants==null)return Dv(t,o?.class,o?.className);const{variants:c,defaultVariants:u}=a,m=Object.keys(c).map(p=>{const b=o?.[p],y=u?.[p];if(b===null)return null;const S=Ov(b)||Ov(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=a==null||(s=a.compoundVariants)===null||s===void 0?void 0:s.reduce((p,b)=>{let{class:y,className:S,...C}=b;return Object.entries(C).every(R=>{let[E,T]=R;return Array.isArray(T)?T.includes({...u,...h}[E]):{...u,...h}[E]===T})?[...p,y,S]:p},[]);return Dv(t,m,v,o?.class,o?.className)},BC=O0("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 qa({className:t,variant:a,...o}){return f.jsx("div",{className:J(BC({variant:a}),t),...o})}const Pl=g.forwardRef(({className:t,...a},o)=>f.jsx("div",{ref:o,className:J("rounded-sm border border-border/70 bg-card/80 text-card-foreground shadow-none",t),...a}));Pl.displayName="Card";const $l=g.forwardRef(({className:t,...a},o)=>f.jsx("div",{ref:o,className:J("flex flex-col space-y-1 p-3",t),...a}));$l.displayName="CardHeader";const ql=g.forwardRef(({className:t,...a},o)=>f.jsx("div",{ref:o,className:J("text-[12px] font-semibold leading-none tracking-tight",t),...a}));ql.displayName="CardTitle";const Vl=g.forwardRef(({className:t,...a},o)=>f.jsx("div",{ref:o,className:J("text-[10px] text-muted-foreground",t),...a}));Vl.displayName="CardDescription";const Yl=g.forwardRef(({className:t,...a},o)=>f.jsx("div",{ref:o,className:J("p-3 pt-0",t),...a}));Yl.displayName="CardContent";const PC=g.forwardRef(({className:t,...a},o)=>f.jsx("div",{ref:o,className:J("flex items-center p-3 pt-0",t),...a}));PC.displayName="CardFooter";function Mv(t,a){if(typeof t=="function")return t(a);t!=null&&(t.current=a)}function $f(...t){return a=>{let o=!1;const s=t.map(c=>{const u=Mv(c,a);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():Mv(t[c],null)}}}}function Fe(...t){return g.useCallback($f(...t),t)}var $C=Symbol.for("react.lazy"),Mi=Cf[" use ".trim().toString()];function qC(t){return typeof t=="object"&&t!==null&&"then"in t}function D0(t){return t!=null&&typeof t=="object"&&"$$typeof"in t&&t.$$typeof===$C&&"_payload"in t&&qC(t._payload)}function VC(t){const a=GC(t),o=g.forwardRef((s,c)=>{let{children:u,...m}=s;D0(u)&&typeof Mi=="function"&&(u=Mi(u._payload));const h=g.Children.toArray(u),v=h.find(XC);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(a,{...m,ref:c,children:g.isValidElement(p)?g.cloneElement(p,void 0,b):null})}return f.jsx(a,{...m,ref:c,children:u})});return o.displayName=`${t}.Slot`,o}var YC=VC("Slot");function GC(t){const a=g.forwardRef((o,s)=>{let{children:c,...u}=o;if(D0(c)&&typeof Mi=="function"&&(c=Mi(c._payload)),g.isValidElement(c)){const m=KC(c),h=QC(u,c.props);return c.type!==g.Fragment&&(h.ref=s?$f(s,m):m),g.cloneElement(c,h)}return g.Children.count(c)>1?g.Children.only(null):null});return a.displayName=`${t}.SlotClone`,a}var IC=Symbol("radix.slottable");function XC(t){return g.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===IC}function QC(t,a){const o={...a};for(const s in a){const c=t[s],u=a[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 KC(t){let a=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,o=a&&"isReactWarning"in a&&a.isReactWarning;return o?t.ref:(a=Object.getOwnPropertyDescriptor(t,"ref")?.get,o=a&&"isReactWarning"in a&&a.isReactWarning,o?t.props.ref:t.props.ref||t.ref)}const qf=O0("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"}}),xt=g.forwardRef(({className:t,variant:a,size:o,asChild:s=!1,...c},u)=>{const m=s?YC:"button";return f.jsx(m,{className:J(qf({variant:a,size:o,className:t})),ref:u,...c})});xt.displayName="Button";async function ZC(t,a={}){try{await ve("/telemetry/events",{method:"POST",body:JSON.stringify({name:`feature.${t}`,appType:"browser",dimensions:a})})}catch{}}function Ge(t,a,{checkForDefaultPrevented:o=!0}={}){return function(c){if(t?.(c),o===!1||!c.defaultPrevented)return a?.(c)}}function WC(t,a){const o=g.createContext(a),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(a!==void 0)return a;throw new Error(`\`${u}\` must be used within \`${t}\``)}return[s,c]}function ko(t,a=[]){let o=[];function s(u,m){const h=g.createContext(m),v=o.length;o=[...o,m];const p=y=>{const{scope:S,children:C,...R}=y,E=S?.[t]?.[v]||h,T=g.useMemo(()=>R,Object.values(R));return f.jsx(E.Provider,{value:T,children:C})};p.displayName=u+"Provider";function b(y,S){const C=S?.[t]?.[v]||h,R=g.useContext(C);if(R)return R;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,FC(c,...a)]}function FC(...t){const a=t[0];if(t.length===1)return a;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${a.scopeName}`]:m}),[m])}};return o.scopeName=a.scopeName,o}var Ot=globalThis?.document?g.useLayoutEffect:()=>{},JC=Cf[" useId ".trim().toString()]||(()=>{}),eR=0;function xo(t){const[a,o]=g.useState(JC());return Ot(()=>{o(s=>s??String(eR++))},[t]),a?`radix-${a}`:""}var tR=Cf[" useInsertionEffect ".trim().toString()]||Ot;function zi({prop:t,defaultProp:a,onChange:o=()=>{},caller:s}){const[c,u,m]=nR({defaultProp:a,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=aR(b)?b(t):b;y!==t&&m.current?.(y)}else u(b)},[h,t,u,m]);return[v,p]}function nR({defaultProp:t,onChange:a}){const[o,s]=g.useState(t),c=g.useRef(o),u=g.useRef(a);return tR(()=>{u.current=a},[a]),g.useEffect(()=>{c.current!==o&&(u.current?.(o),c.current=o)},[o,c]),[o,s,u]}function aR(t){return typeof t=="function"}function Gl(t){const a=rR(t),o=g.forwardRef((s,c)=>{const{children:u,...m}=s,h=g.Children.toArray(u),v=h.find(lR);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(a,{...m,ref:c,children:g.isValidElement(p)?g.cloneElement(p,void 0,b):null})}return f.jsx(a,{...m,ref:c,children:u})});return o.displayName=`${t}.Slot`,o}function rR(t){const a=g.forwardRef((o,s)=>{const{children:c,...u}=o;if(g.isValidElement(c)){const m=iR(c),h=sR(u,c.props);return c.type!==g.Fragment&&(h.ref=s?$f(s,m):m),g.cloneElement(c,h)}return g.Children.count(c)>1?g.Children.only(null):null});return a.displayName=`${t}.SlotClone`,a}var M0=Symbol("radix.slottable");function oR(t){const a=({children:o})=>f.jsx(f.Fragment,{children:o});return a.displayName=`${t}.Slottable`,a.__radixId=M0,a}function lR(t){return g.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===M0}function sR(t,a){const o={...a};for(const s in a){const c=t[s],u=a[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 iR(t){let a=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,o=a&&"isReactWarning"in a&&a.isReactWarning;return o?t.ref:(a=Object.getOwnPropertyDescriptor(t,"ref")?.get,o=a&&"isReactWarning"in a&&a.isReactWarning,o?t.props.ref:t.props.ref||t.ref)}var cR=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],$e=cR.reduce((t,a)=>{const o=Gl(`Primitive.${a}`),s=g.forwardRef((c,u)=>{const{asChild:m,...h}=c,v=m?o:a;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(v,{...h,ref:u})});return s.displayName=`Primitive.${a}`,{...t,[a]:s}},{});function uR(t,a){t&&Kl.flushSync(()=>t.dispatchEvent(a))}function vr(t){const a=g.useRef(t);return g.useEffect(()=>{a.current=t}),g.useMemo(()=>(...o)=>a.current?.(...o),[])}function dR(t,a=globalThis?.document){const o=vr(t);g.useEffect(()=>{const s=c=>{c.key==="Escape"&&o(c)};return a.addEventListener("keydown",s,{capture:!0}),()=>a.removeEventListener("keydown",s,{capture:!0})},[o,a])}var fR="DismissableLayer",rf="dismissableLayer.update",mR="dismissableLayer.pointerDownOutside",hR="dismissableLayer.focusOutside",zv,z0=g.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Vf=g.forwardRef((t,a)=>{const{disableOutsidePointerEvents:o=!1,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:u,onInteractOutside:m,onDismiss:h,...v}=t,p=g.useContext(z0),[b,y]=g.useState(null),S=b?.ownerDocument??globalThis?.document,[,C]=g.useState({}),R=Fe(a,G=>y(G)),E=Array.from(p.layers),[T]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),k=E.indexOf(T),A=b?E.indexOf(b):-1,M=p.layersWithOutsidePointerEventsDisabled.size>0,L=A>=k,H=vR(G=>{const V=G.target,oe=[...p.branches].some(fe=>fe.contains(V));!L||oe||(c?.(G),m?.(G),G.defaultPrevented||h?.())},S),I=yR(G=>{const V=G.target;[...p.branches].some(fe=>fe.contains(V))||(u?.(G),m?.(G),G.defaultPrevented||h?.())},S);return dR(G=>{A===p.layers.size-1&&(s?.(G),!G.defaultPrevented&&h&&(G.preventDefault(),h()))},S),g.useEffect(()=>{if(b)return o&&(p.layersWithOutsidePointerEventsDisabled.size===0&&(zv=S.body.style.pointerEvents,S.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(b)),p.layers.add(b),Lv(),()=>{o&&p.layersWithOutsidePointerEventsDisabled.size===1&&(S.body.style.pointerEvents=zv)}},[b,S,o,p]),g.useEffect(()=>()=>{b&&(p.layers.delete(b),p.layersWithOutsidePointerEventsDisabled.delete(b),Lv())},[b,p]),g.useEffect(()=>{const G=()=>C({});return document.addEventListener(rf,G),()=>document.removeEventListener(rf,G)},[]),f.jsx($e.div,{...v,ref:R,style:{pointerEvents:M?L?"auto":"none":void 0,...t.style},onFocusCapture:Ge(t.onFocusCapture,I.onFocusCapture),onBlurCapture:Ge(t.onBlurCapture,I.onBlurCapture),onPointerDownCapture:Ge(t.onPointerDownCapture,H.onPointerDownCapture)})});Vf.displayName=fR;var pR="DismissableLayerBranch",gR=g.forwardRef((t,a)=>{const o=g.useContext(z0),s=g.useRef(null),c=Fe(a,s);return g.useEffect(()=>{const u=s.current;if(u)return o.branches.add(u),()=>{o.branches.delete(u)}},[o.branches]),f.jsx($e.div,{...t,ref:c})});gR.displayName=pR;function vR(t,a=globalThis?.document){const o=vr(t),s=g.useRef(!1),c=g.useRef(()=>{});return g.useEffect(()=>{const u=h=>{if(h.target&&!s.current){let v=function(){L0(mR,o,p,{discrete:!0})};const p={originalEvent:h};h.pointerType==="touch"?(a.removeEventListener("click",c.current),c.current=v,a.addEventListener("click",c.current,{once:!0})):v()}else a.removeEventListener("click",c.current);s.current=!1},m=window.setTimeout(()=>{a.addEventListener("pointerdown",u)},0);return()=>{window.clearTimeout(m),a.removeEventListener("pointerdown",u),a.removeEventListener("click",c.current)}},[a,o]),{onPointerDownCapture:()=>s.current=!0}}function yR(t,a=globalThis?.document){const o=vr(t),s=g.useRef(!1);return g.useEffect(()=>{const c=u=>{u.target&&!s.current&&L0(hR,o,{originalEvent:u},{discrete:!1})};return a.addEventListener("focusin",c),()=>a.removeEventListener("focusin",c)},[a,o]),{onFocusCapture:()=>s.current=!0,onBlurCapture:()=>s.current=!1}}function Lv(){const t=new CustomEvent(rf);document.dispatchEvent(t)}function L0(t,a,o,{discrete:s}){const c=o.originalEvent.target,u=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:o});a&&c.addEventListener(t,a,{once:!0}),s?uR(c,u):c.dispatchEvent(u)}var Ld="focusScope.autoFocusOnMount",Ud="focusScope.autoFocusOnUnmount",Uv={bubbles:!1,cancelable:!0},bR="FocusScope",Yf=g.forwardRef((t,a)=>{const{loop:o=!1,trapped:s=!1,onMountAutoFocus:c,onUnmountAutoFocus:u,...m}=t,[h,v]=g.useState(null),p=vr(c),b=vr(u),y=g.useRef(null),S=Fe(a,E=>v(E)),C=g.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;g.useEffect(()=>{if(s){let E=function(M){if(C.paused||!h)return;const L=M.target;h.contains(L)?y.current=L:za(y.current,{select:!0})},T=function(M){if(C.paused||!h)return;const L=M.relatedTarget;L!==null&&(h.contains(L)||za(y.current,{select:!0}))},k=function(M){if(document.activeElement===document.body)for(const H of M)H.removedNodes.length>0&&za(h)};document.addEventListener("focusin",E),document.addEventListener("focusout",T);const A=new MutationObserver(k);return h&&A.observe(h,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",E),document.removeEventListener("focusout",T),A.disconnect()}}},[s,h,C.paused]),g.useEffect(()=>{if(h){Bv.add(C);const E=document.activeElement;if(!h.contains(E)){const k=new CustomEvent(Ld,Uv);h.addEventListener(Ld,p),h.dispatchEvent(k),k.defaultPrevented||(xR(TR(U0(h)),{select:!0}),document.activeElement===E&&za(h))}return()=>{h.removeEventListener(Ld,p),setTimeout(()=>{const k=new CustomEvent(Ud,Uv);h.addEventListener(Ud,b),h.dispatchEvent(k),k.defaultPrevented||za(E??document.body,{select:!0}),h.removeEventListener(Ud,b),Bv.remove(C)},0)}}},[h,p,b,C]);const R=g.useCallback(E=>{if(!o&&!s||C.paused)return;const T=E.key==="Tab"&&!E.altKey&&!E.ctrlKey&&!E.metaKey,k=document.activeElement;if(T&&k){const A=E.currentTarget,[M,L]=wR(A);M&&L?!E.shiftKey&&k===L?(E.preventDefault(),o&&za(M,{select:!0})):E.shiftKey&&k===M&&(E.preventDefault(),o&&za(L,{select:!0})):k===A&&E.preventDefault()}},[o,s,C.paused]);return f.jsx($e.div,{tabIndex:-1,...m,ref:S,onKeyDown:R})});Yf.displayName=bR;function xR(t,{select:a=!1}={}){const o=document.activeElement;for(const s of t)if(za(s,{select:a}),document.activeElement!==o)return}function wR(t){const a=U0(t),o=Hv(a,t),s=Hv(a.reverse(),t);return[o,s]}function U0(t){const a=[],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();)a.push(o.currentNode);return a}function Hv(t,a){for(const o of t)if(!SR(o,{upTo:a}))return o}function SR(t,{upTo:a}){if(getComputedStyle(t).visibility==="hidden")return!0;for(;t;){if(a!==void 0&&t===a)return!1;if(getComputedStyle(t).display==="none")return!0;t=t.parentElement}return!1}function ER(t){return t instanceof HTMLInputElement&&"select"in t}function za(t,{select:a=!1}={}){if(t&&t.focus){const o=document.activeElement;t.focus({preventScroll:!0}),t!==o&&ER(t)&&a&&t.select()}}var Bv=NR();function NR(){let t=[];return{add(a){const o=t[0];a!==o&&o?.pause(),t=Pv(t,a),t.unshift(a)},remove(a){t=Pv(t,a),t[0]?.resume()}}}function Pv(t,a){const o=[...t],s=o.indexOf(a);return s!==-1&&o.splice(s,1),o}function TR(t){return t.filter(a=>a.tagName!=="A")}var CR="Portal",Gf=g.forwardRef((t,a)=>{const{container:o,...s}=t,[c,u]=g.useState(!1);Ot(()=>u(!0),[]);const m=o||c&&globalThis?.document?.body;return m?Jy.createPortal(f.jsx($e.div,{...s,ref:a}),m):null});Gf.displayName=CR;function RR(t,a){return g.useReducer((o,s)=>a[o][s]??o,t)}var Zl=t=>{const{present:a,children:o}=t,s=AR(a),c=typeof o=="function"?o({present:s.isPresent}):g.Children.only(o),u=Fe(s.ref,kR(c));return typeof o=="function"||s.isPresent?g.cloneElement(c,{ref:u}):null};Zl.displayName="Presence";function AR(t){const[a,o]=g.useState(),s=g.useRef(null),c=g.useRef(t),u=g.useRef("none"),m=t?"mounted":"unmounted",[h,v]=RR(m,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return g.useEffect(()=>{const p=mi(s.current);u.current=h==="mounted"?p:"none"},[h]),Ot(()=>{const p=s.current,b=c.current;if(b!==t){const S=u.current,C=mi(p);t?v("MOUNT"):C==="none"||p?.display==="none"?v("UNMOUNT"):v(b&&S!==C?"ANIMATION_OUT":"UNMOUNT"),c.current=t}},[t,v]),Ot(()=>{if(a){let p;const b=a.ownerDocument.defaultView??window,y=C=>{const E=mi(s.current).includes(CSS.escape(C.animationName));if(C.target===a&&E&&(v("ANIMATION_END"),!c.current)){const T=a.style.animationFillMode;a.style.animationFillMode="forwards",p=b.setTimeout(()=>{a.style.animationFillMode==="forwards"&&(a.style.animationFillMode=T)})}},S=C=>{C.target===a&&(u.current=mi(s.current))};return a.addEventListener("animationstart",S),a.addEventListener("animationcancel",y),a.addEventListener("animationend",y),()=>{b.clearTimeout(p),a.removeEventListener("animationstart",S),a.removeEventListener("animationcancel",y),a.removeEventListener("animationend",y)}}else v("ANIMATION_END")},[a,v]),{isPresent:["mounted","unmountSuspended"].includes(h),ref:g.useCallback(p=>{s.current=p?getComputedStyle(p):null,o(p)},[])}}function mi(t){return t?.animationName||"none"}function kR(t){let a=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,o=a&&"isReactWarning"in a&&a.isReactWarning;return o?t.ref:(a=Object.getOwnPropertyDescriptor(t,"ref")?.get,o=a&&"isReactWarning"in a&&a.isReactWarning,o?t.props.ref:t.props.ref||t.ref)}var Hd=0;function H0(){g.useEffect(()=>{const t=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",t[0]??$v()),document.body.insertAdjacentElement("beforeend",t[1]??$v()),Hd++,()=>{Hd===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(a=>a.remove()),Hd--}},[])}function $v(){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 On=function(){return On=Object.assign||function(a){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)&&(a[u]=o[u])}return a},On.apply(this,arguments)};function B0(t,a){var o={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&a.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++)a.indexOf(s[c])<0&&Object.prototype.propertyIsEnumerable.call(t,s[c])&&(o[s[c]]=t[s[c]]);return o}function jR(t,a,o){if(o||arguments.length===2)for(var s=0,c=a.length,u;s<c;s++)(u||!(s in a))&&(u||(u=Array.prototype.slice.call(a,0,s)),u[s]=a[s]);return t.concat(u||Array.prototype.slice.call(a))}var Si="right-scroll-bar-position",Ei="width-before-scroll-bar",_R="with-scroll-bars-hidden",OR="--removed-body-scroll-bar-size";function Bd(t,a){return typeof t=="function"?t(a):t&&(t.current=a),t}function DR(t,a){var o=g.useState(function(){return{value:t,callback:a,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=a,o.facade}var MR=typeof window<"u"?g.useLayoutEffect:g.useEffect,qv=new WeakMap;function zR(t,a){var o=DR(null,function(s){return t.forEach(function(c){return Bd(c,s)})});return MR(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)||Bd(h,null)}),u.forEach(function(h){c.has(h)||Bd(h,m)})}qv.set(o,t)},[t]),o}function LR(t){return t}function UR(t,a){a===void 0&&(a=LR);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=a(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 HR(t){t===void 0&&(t={});var a=UR(null);return a.options=On({async:!0,ssr:!1},t),a}var P0=function(t){var a=t.sideCar,o=B0(t,["sideCar"]);if(!a)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var s=a.read();if(!s)throw new Error("Sidecar medium not found");return g.createElement(s,On({},o))};P0.isSideCarExport=!0;function BR(t,a){return t.useMedium(a),P0}var $0=HR(),Pd=function(){},rc=g.forwardRef(function(t,a){var o=g.useRef(null),s=g.useState({onScrollCapture:Pd,onWheelCapture:Pd,onTouchMoveCapture:Pd}),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,C=t.noRelative,R=t.noIsolation,E=t.inert,T=t.allowPinchZoom,k=t.as,A=k===void 0?"div":k,M=t.gapMode,L=B0(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),H=S,I=zR([o,a]),G=On(On({},L),c);return g.createElement(g.Fragment,null,b&&g.createElement(H,{sideCar:$0,removeScrollBar:p,shards:y,noRelative:C,noIsolation:R,inert:E,setCallbacks:u,allowPinchZoom:!!T,lockRef:o,gapMode:M}),m?g.cloneElement(g.Children.only(h),On(On({},G),{ref:I})):g.createElement(A,On({},G,{className:v,ref:I}),h))});rc.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};rc.classNames={fullWidth:Ei,zeroRight:Si};var PR=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function $R(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var a=PR();return a&&t.setAttribute("nonce",a),t}function qR(t,a){t.styleSheet?t.styleSheet.cssText=a:t.appendChild(document.createTextNode(a))}function VR(t){var a=document.head||document.getElementsByTagName("head")[0];a.appendChild(t)}var YR=function(){var t=0,a=null;return{add:function(o){t==0&&(a=$R())&&(qR(a,o),VR(a)),t++},remove:function(){t--,!t&&a&&(a.parentNode&&a.parentNode.removeChild(a),a=null)}}},GR=function(){var t=YR();return function(a,o){g.useEffect(function(){return t.add(a),function(){t.remove()}},[a&&o])}},q0=function(){var t=GR(),a=function(o){var s=o.styles,c=o.dynamic;return t(s,c),null};return a},IR={left:0,top:0,right:0,gap:0},$d=function(t){return parseInt(t||"",10)||0},XR=function(t){var a=window.getComputedStyle(document.body),o=a[t==="padding"?"paddingLeft":"marginLeft"],s=a[t==="padding"?"paddingTop":"marginTop"],c=a[t==="padding"?"paddingRight":"marginRight"];return[$d(o),$d(s),$d(c)]},QR=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return IR;var a=XR(t),o=document.documentElement.clientWidth,s=window.innerWidth;return{left:a[0],top:a[1],right:a[2],gap:Math.max(0,s-o+a[2]-a[0])}},KR=q0(),wo="data-scroll-locked",ZR=function(t,a,o,s){var c=t.left,u=t.top,m=t.right,h=t.gap;return o===void 0&&(o="margin"),`
|
|
302
|
+
.`.concat(_R,` {
|
|
303
|
+
overflow: hidden `).concat(s,`;
|
|
304
|
+
padding-right: `).concat(h,"px ").concat(s,`;
|
|
305
|
+
}
|
|
306
|
+
body[`).concat(wo,`] {
|
|
307
|
+
overflow: hidden `).concat(s,`;
|
|
308
|
+
overscroll-behavior: contain;
|
|
309
|
+
`).concat([a&&"position: relative ".concat(s,";"),o==="margin"&&`
|
|
310
|
+
padding-left: `.concat(c,`px;
|
|
311
|
+
padding-top: `).concat(u,`px;
|
|
312
|
+
padding-right: `).concat(m,`px;
|
|
313
|
+
margin-left:0;
|
|
314
|
+
margin-top:0;
|
|
315
|
+
margin-right: `).concat(h,"px ").concat(s,`;
|
|
316
|
+
`),o==="padding"&&"padding-right: ".concat(h,"px ").concat(s,";")].filter(Boolean).join(""),`
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
.`).concat(Si,` {
|
|
320
|
+
right: `).concat(h,"px ").concat(s,`;
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
.`).concat(Ei,` {
|
|
324
|
+
margin-right: `).concat(h,"px ").concat(s,`;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
.`).concat(Si," .").concat(Si,` {
|
|
328
|
+
right: 0 `).concat(s,`;
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
.`).concat(Ei," .").concat(Ei,` {
|
|
332
|
+
margin-right: 0 `).concat(s,`;
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
body[`).concat(wo,`] {
|
|
336
|
+
`).concat(OR,": ").concat(h,`px;
|
|
337
|
+
}
|
|
338
|
+
`)},Vv=function(){var t=parseInt(document.body.getAttribute(wo)||"0",10);return isFinite(t)?t:0},WR=function(){g.useEffect(function(){return document.body.setAttribute(wo,(Vv()+1).toString()),function(){var t=Vv()-1;t<=0?document.body.removeAttribute(wo):document.body.setAttribute(wo,t.toString())}},[])},FR=function(t){var a=t.noRelative,o=t.noImportant,s=t.gapMode,c=s===void 0?"margin":s;WR();var u=g.useMemo(function(){return QR(c)},[c]);return g.createElement(KR,{styles:ZR(u,!a,c,o?"":"!important")})},of=!1;if(typeof window<"u")try{var hi=Object.defineProperty({},"passive",{get:function(){return of=!0,!0}});window.addEventListener("test",hi,hi),window.removeEventListener("test",hi,hi)}catch{of=!1}var mo=of?{passive:!1}:!1,JR=function(t){return t.tagName==="TEXTAREA"},V0=function(t,a){if(!(t instanceof Element))return!1;var o=window.getComputedStyle(t);return o[a]!=="hidden"&&!(o.overflowY===o.overflowX&&!JR(t)&&o[a]==="visible")},eA=function(t){return V0(t,"overflowY")},tA=function(t){return V0(t,"overflowX")},Yv=function(t,a){var o=a.ownerDocument,s=a;do{typeof ShadowRoot<"u"&&s instanceof ShadowRoot&&(s=s.host);var c=Y0(t,s);if(c){var u=G0(t,s),m=u[1],h=u[2];if(m>h)return!0}s=s.parentNode}while(s&&s!==o.body);return!1},nA=function(t){var a=t.scrollTop,o=t.scrollHeight,s=t.clientHeight;return[a,o,s]},aA=function(t){var a=t.scrollLeft,o=t.scrollWidth,s=t.clientWidth;return[a,o,s]},Y0=function(t,a){return t==="v"?eA(a):tA(a)},G0=function(t,a){return t==="v"?nA(a):aA(a)},rA=function(t,a){return t==="h"&&a==="rtl"?-1:1},oA=function(t,a,o,s,c){var u=rA(t,window.getComputedStyle(a).direction),m=u*s,h=o.target,v=a.contains(h),p=!1,b=m>0,y=0,S=0;do{if(!h)break;var C=G0(t,h),R=C[0],E=C[1],T=C[2],k=E-T-u*R;(R||k)&&Y0(t,h)&&(y+=k,S+=R);var A=h.parentNode;h=A&&A.nodeType===Node.DOCUMENT_FRAGMENT_NODE?A.host:A}while(!v&&h!==document.body||v&&(a.contains(h)||a===h));return(b&&Math.abs(y)<1||!b&&Math.abs(S)<1)&&(p=!0),p},pi=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},Gv=function(t){return[t.deltaX,t.deltaY]},Iv=function(t){return t&&"current"in t?t.current:t},lA=function(t,a){return t[0]===a[0]&&t[1]===a[1]},sA=function(t){return`
|
|
339
|
+
.block-interactivity-`.concat(t,` {pointer-events: none;}
|
|
340
|
+
.allow-interactivity-`).concat(t,` {pointer-events: all;}
|
|
341
|
+
`)},iA=0,ho=[];function cA(t){var a=g.useRef([]),o=g.useRef([0,0]),s=g.useRef(),c=g.useState(iA++)[0],u=g.useState(q0)[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 E=jR([t.lockRef.current],(t.shards||[]).map(Iv),!0).filter(Boolean);return E.forEach(function(T){return T.classList.add("allow-interactivity-".concat(c))}),function(){document.body.classList.remove("block-interactivity-".concat(c)),E.forEach(function(T){return T.classList.remove("allow-interactivity-".concat(c))})}}},[t.inert,t.lockRef.current,t.shards]);var h=g.useCallback(function(E,T){if("touches"in E&&E.touches.length===2||E.type==="wheel"&&E.ctrlKey)return!m.current.allowPinchZoom;var k=pi(E),A=o.current,M="deltaX"in E?E.deltaX:A[0]-k[0],L="deltaY"in E?E.deltaY:A[1]-k[1],H,I=E.target,G=Math.abs(M)>Math.abs(L)?"h":"v";if("touches"in E&&G==="h"&&I.type==="range")return!1;var V=window.getSelection(),oe=V&&V.anchorNode,fe=oe?oe===I||oe.contains(I):!1;if(fe)return!1;var ae=Yv(G,I);if(!ae)return!0;if(ae?H=G:(H=G==="v"?"h":"v",ae=Yv(G,I)),!ae)return!1;if(!s.current&&"changedTouches"in E&&(M||L)&&(s.current=H),!H)return!0;var ie=s.current||H;return oA(ie,T,E,ie==="h"?M:L)},[]),v=g.useCallback(function(E){var T=E;if(!(!ho.length||ho[ho.length-1]!==u)){var k="deltaY"in T?Gv(T):pi(T),A=a.current.filter(function(H){return H.name===T.type&&(H.target===T.target||T.target===H.shadowParent)&&lA(H.delta,k)})[0];if(A&&A.should){T.cancelable&&T.preventDefault();return}if(!A){var M=(m.current.shards||[]).map(Iv).filter(Boolean).filter(function(H){return H.contains(T.target)}),L=M.length>0?h(T,M[0]):!m.current.noIsolation;L&&T.cancelable&&T.preventDefault()}}},[]),p=g.useCallback(function(E,T,k,A){var M={name:E,delta:T,target:k,should:A,shadowParent:uA(k)};a.current.push(M),setTimeout(function(){a.current=a.current.filter(function(L){return L!==M})},1)},[]),b=g.useCallback(function(E){o.current=pi(E),s.current=void 0},[]),y=g.useCallback(function(E){p(E.type,Gv(E),E.target,h(E,t.lockRef.current))},[]),S=g.useCallback(function(E){p(E.type,pi(E),E.target,h(E,t.lockRef.current))},[]);g.useEffect(function(){return ho.push(u),t.setCallbacks({onScrollCapture:y,onWheelCapture:y,onTouchMoveCapture:S}),document.addEventListener("wheel",v,mo),document.addEventListener("touchmove",v,mo),document.addEventListener("touchstart",b,mo),function(){ho=ho.filter(function(E){return E!==u}),document.removeEventListener("wheel",v,mo),document.removeEventListener("touchmove",v,mo),document.removeEventListener("touchstart",b,mo)}},[]);var C=t.removeScrollBar,R=t.inert;return g.createElement(g.Fragment,null,R?g.createElement(u,{styles:sA(c)}):null,C?g.createElement(FR,{noRelative:t.noRelative,gapMode:t.gapMode}):null)}function uA(t){for(var a=null;t!==null;)t instanceof ShadowRoot&&(a=t.host,t=t.host),t=t.parentNode;return a}const dA=BR($0,cA);var If=g.forwardRef(function(t,a){return g.createElement(rc,On({},t,{ref:a,sideCar:dA}))});If.classNames=rc.classNames;var fA=function(t){if(typeof document>"u")return null;var a=Array.isArray(t)?t[0]:t;return a.ownerDocument.body},po=new WeakMap,gi=new WeakMap,vi={},qd=0,I0=function(t){return t&&(t.host||I0(t.parentNode))},mA=function(t,a){return a.map(function(o){if(t.contains(o))return o;var s=I0(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})},hA=function(t,a,o,s){var c=mA(a,Array.isArray(t)?t:[t]);vi[o]||(vi[o]=new WeakMap);var u=vi[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 C=S.getAttribute(s),R=C!==null&&C!=="false",E=(po.get(S)||0)+1,T=(u.get(S)||0)+1;po.set(S,E),u.set(S,T),m.push(S),E===1&&R&&gi.set(S,!0),T===1&&S.setAttribute(o,"true"),R||S.setAttribute(s,"true")}catch(k){console.error("aria-hidden: cannot operate on ",S,k)}})};return b(a),h.clear(),qd++,function(){m.forEach(function(y){var S=po.get(y)-1,C=u.get(y)-1;po.set(y,S),u.set(y,C),S||(gi.has(y)||y.removeAttribute(s),gi.delete(y)),C||y.removeAttribute(o)}),qd--,qd||(po=new WeakMap,po=new WeakMap,gi=new WeakMap,vi={})}},X0=function(t,a,o){o===void 0&&(o="data-aria-hidden");var s=Array.from(Array.isArray(t)?t:[t]),c=fA(t);return c?(s.push.apply(s,Array.from(c.querySelectorAll("[aria-live], script"))),hA(s,c,o,"aria-hidden")):function(){return null}},oc="Dialog",[Q0,K0]=ko(oc),[pA,En]=Q0(oc),Z0=t=>{const{__scopeDialog:a,children:o,open:s,defaultOpen:c,onOpenChange:u,modal:m=!0}=t,h=g.useRef(null),v=g.useRef(null),[p,b]=zi({prop:s,defaultProp:c??!1,onChange:u,caller:oc});return f.jsx(pA,{scope:a,triggerRef:h,contentRef:v,contentId:xo(),titleId:xo(),descriptionId:xo(),open:p,onOpenChange:b,onOpenToggle:g.useCallback(()=>b(y=>!y),[b]),modal:m,children:o})};Z0.displayName=oc;var W0="DialogTrigger",F0=g.forwardRef((t,a)=>{const{__scopeDialog:o,...s}=t,c=En(W0,o),u=Fe(a,c.triggerRef);return f.jsx($e.button,{type:"button","aria-haspopup":"dialog","aria-expanded":c.open,"aria-controls":c.contentId,"data-state":Kf(c.open),...s,ref:u,onClick:Ge(t.onClick,c.onOpenToggle)})});F0.displayName=W0;var Xf="DialogPortal",[gA,J0]=Q0(Xf,{forceMount:void 0}),eb=t=>{const{__scopeDialog:a,forceMount:o,children:s,container:c}=t,u=En(Xf,a);return f.jsx(gA,{scope:a,forceMount:o,children:g.Children.map(s,m=>f.jsx(Zl,{present:o||u.open,children:f.jsx(Gf,{asChild:!0,container:c,children:m})}))})};eb.displayName=Xf;var Li="DialogOverlay",tb=g.forwardRef((t,a)=>{const o=J0(Li,t.__scopeDialog),{forceMount:s=o.forceMount,...c}=t,u=En(Li,t.__scopeDialog);return u.modal?f.jsx(Zl,{present:s||u.open,children:f.jsx(yA,{...c,ref:a})}):null});tb.displayName=Li;var vA=Gl("DialogOverlay.RemoveScroll"),yA=g.forwardRef((t,a)=>{const{__scopeDialog:o,...s}=t,c=En(Li,o);return f.jsx(If,{as:vA,allowPinchZoom:!0,shards:[c.contentRef],children:f.jsx($e.div,{"data-state":Kf(c.open),...s,ref:a,style:{pointerEvents:"auto",...s.style}})})}),yr="DialogContent",nb=g.forwardRef((t,a)=>{const o=J0(yr,t.__scopeDialog),{forceMount:s=o.forceMount,...c}=t,u=En(yr,t.__scopeDialog);return f.jsx(Zl,{present:s||u.open,children:u.modal?f.jsx(bA,{...c,ref:a}):f.jsx(xA,{...c,ref:a})})});nb.displayName=yr;var bA=g.forwardRef((t,a)=>{const o=En(yr,t.__scopeDialog),s=g.useRef(null),c=Fe(a,o.contentRef,s);return g.useEffect(()=>{const u=s.current;if(u)return X0(u)},[]),f.jsx(ab,{...t,ref:c,trapFocus:o.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Ge(t.onCloseAutoFocus,u=>{u.preventDefault(),o.triggerRef.current?.focus()}),onPointerDownOutside:Ge(t.onPointerDownOutside,u=>{const m=u.detail.originalEvent,h=m.button===0&&m.ctrlKey===!0;(m.button===2||h)&&u.preventDefault()}),onFocusOutside:Ge(t.onFocusOutside,u=>u.preventDefault())})}),xA=g.forwardRef((t,a)=>{const o=En(yr,t.__scopeDialog),s=g.useRef(!1),c=g.useRef(!1);return f.jsx(ab,{...t,ref:a,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()}})}),ab=g.forwardRef((t,a)=>{const{__scopeDialog:o,trapFocus:s,onOpenAutoFocus:c,onCloseAutoFocus:u,...m}=t,h=En(yr,o),v=g.useRef(null),p=Fe(a,v);return H0(),f.jsxs(f.Fragment,{children:[f.jsx(Yf,{asChild:!0,loop:!0,trapped:s,onMountAutoFocus:c,onUnmountAutoFocus:u,children:f.jsx(Vf,{role:"dialog",id:h.contentId,"aria-describedby":h.descriptionId,"aria-labelledby":h.titleId,"data-state":Kf(h.open),...m,ref:p,onDismiss:()=>h.onOpenChange(!1)})}),f.jsxs(f.Fragment,{children:[f.jsx(SA,{titleId:h.titleId}),f.jsx(NA,{contentRef:v,descriptionId:h.descriptionId})]})]})}),Qf="DialogTitle",rb=g.forwardRef((t,a)=>{const{__scopeDialog:o,...s}=t,c=En(Qf,o);return f.jsx($e.h2,{id:c.titleId,...s,ref:a})});rb.displayName=Qf;var ob="DialogDescription",lb=g.forwardRef((t,a)=>{const{__scopeDialog:o,...s}=t,c=En(ob,o);return f.jsx($e.p,{id:c.descriptionId,...s,ref:a})});lb.displayName=ob;var sb="DialogClose",ib=g.forwardRef((t,a)=>{const{__scopeDialog:o,...s}=t,c=En(sb,o);return f.jsx($e.button,{type:"button",...s,ref:a,onClick:Ge(t.onClick,()=>c.onOpenChange(!1))})});ib.displayName=sb;function Kf(t){return t?"open":"closed"}var cb="DialogTitleWarning",[wA,ub]=WC(cb,{contentName:yr,titleName:Qf,docsSlug:"dialog"}),SA=({titleId:t})=>{const a=ub(cb),o=`\`${a.contentName}\` requires a \`${a.titleName}\` for the component to be accessible for screen reader users.
|
|
342
|
+
|
|
343
|
+
If you want to hide the \`${a.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
344
|
+
|
|
345
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${a.docsSlug}`;return g.useEffect(()=>{t&&(document.getElementById(t)||console.error(o))},[o,t]),null},EA="DialogDescriptionWarning",NA=({contentRef:t,descriptionId:a})=>{const s=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${ub(EA).contentName}}.`;return g.useEffect(()=>{const c=t.current?.getAttribute("aria-describedby");a&&c&&(document.getElementById(a)||console.warn(s))},[s,t,a]),null},db=Z0,fb=F0,mb=eb,Zf=tb,Wf=nb,Ff=rb,Jf=lb,lc=ib;const TA=db,CA=fb,RA=mb,UO=lc,hb=g.forwardRef(({className:t,...a},o)=>f.jsx(Zf,{ref:o,className:J("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),...a}));hb.displayName=Zf.displayName;const pb=g.forwardRef(({className:t,children:a,...o},s)=>f.jsxs(RA,{children:[f.jsx(hb,{}),f.jsxs(Wf,{ref:s,className:J("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:[a,f.jsxs(lc,{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(Hf,{className:"h-3.5 w-3.5"}),f.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));pb.displayName=Wf.displayName;const gb=({className:t,...a})=>f.jsx("div",{className:J("flex flex-col space-y-1.5 text-center sm:text-left",t),...a});gb.displayName="DialogHeader";const AA=({className:t,...a})=>f.jsx("div",{className:J("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",t),...a});AA.displayName="DialogFooter";const vb=g.forwardRef(({className:t,...a},o)=>f.jsx(Ff,{ref:o,className:J("text-sm font-semibold leading-none tracking-tight",t),...a}));vb.displayName=Ff.displayName;const yb=g.forwardRef(({className:t,...a},o)=>f.jsx(Jf,{ref:o,className:J("text-[11px] text-muted-foreground",t),...a}));yb.displayName=Jf.displayName;function kA({children:t,open:a,onOpenChange:o,showTrigger:s=!0}){const[c,u]=g.useState(!1),m=a??c,h=g.useCallback(v=>{v&&ZC("settings.opened",{surface:"settings"}),a===void 0&&u(v),o?.(v)},[a,o]);return f.jsxs(TA,{open:m,onOpenChange:h,children:[s&&f.jsx(CA,{asChild:!0,children:f.jsx(xt,{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(dT,{className:"h-4 w-4"})})}),f.jsxs(pb,{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(gb,{className:"shrink-0 border-b border-border/60 px-3 py-1.5 sm:px-3.5",children:[f.jsxs(vb,{className:"flex items-center gap-1.5 text-[11px]",children:[f.jsx(XN,{className:"h-3.5 w-3.5 text-primary"}),"Settings"]}),f.jsx(yb,{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})]})]})}var bb="AlertDialog",[jA]=ko(bb,[K0]),oa=K0(),xb=t=>{const{__scopeAlertDialog:a,...o}=t,s=oa(a);return f.jsx(db,{...s,...o,modal:!0})};xb.displayName=bb;var _A="AlertDialogTrigger",wb=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,...s}=t,c=oa(o);return f.jsx(fb,{...c,...s,ref:a})});wb.displayName=_A;var OA="AlertDialogPortal",Sb=t=>{const{__scopeAlertDialog:a,...o}=t,s=oa(a);return f.jsx(mb,{...s,...o})};Sb.displayName=OA;var DA="AlertDialogOverlay",Eb=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,...s}=t,c=oa(o);return f.jsx(Zf,{...c,...s,ref:a})});Eb.displayName=DA;var So="AlertDialogContent",[MA,zA]=jA(So),LA=oR("AlertDialogContent"),Nb=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,children:s,...c}=t,u=oa(o),m=g.useRef(null),h=Fe(a,m),v=g.useRef(null);return f.jsx(wA,{contentName:So,titleName:Tb,docsSlug:"alert-dialog",children:f.jsx(MA,{scope:o,cancelRef:v,children:f.jsxs(Wf,{role:"alertdialog",...u,...c,ref:h,onOpenAutoFocus:Ge(c.onOpenAutoFocus,p=>{p.preventDefault(),v.current?.focus({preventScroll:!0})}),onPointerDownOutside:p=>p.preventDefault(),onInteractOutside:p=>p.preventDefault(),children:[f.jsx(LA,{children:s}),f.jsx(HA,{contentRef:m})]})})})});Nb.displayName=So;var Tb="AlertDialogTitle",Cb=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,...s}=t,c=oa(o);return f.jsx(Ff,{...c,...s,ref:a})});Cb.displayName=Tb;var Rb="AlertDialogDescription",Ab=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,...s}=t,c=oa(o);return f.jsx(Jf,{...c,...s,ref:a})});Ab.displayName=Rb;var UA="AlertDialogAction",kb=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,...s}=t,c=oa(o);return f.jsx(lc,{...c,...s,ref:a})});kb.displayName=UA;var jb="AlertDialogCancel",_b=g.forwardRef((t,a)=>{const{__scopeAlertDialog:o,...s}=t,{cancelRef:c}=zA(jb,o),u=oa(o),m=Fe(a,c);return f.jsx(lc,{...u,...s,ref:m})});_b.displayName=jb;var HA=({contentRef:t})=>{const a=`\`${So}\` requires a description for the component to be accessible for screen reader users.
|
|
346
|
+
|
|
347
|
+
You can add a description to the \`${So}\` by passing a \`${Rb}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
|
|
348
|
+
|
|
349
|
+
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 \`${So}\`. 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.
|
|
350
|
+
|
|
351
|
+
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(a)},[a,t]),null},BA=xb,PA=wb,$A=Sb,Ob=Eb,Db=Nb,Mb=kb,zb=_b,Lb=Cb,Ub=Ab;const lf=BA,sf=PA,qA=$A,Hb=g.forwardRef(({className:t,...a},o)=>f.jsx(Ob,{className:J("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),...a,ref:o}));Hb.displayName=Ob.displayName;const Ui=g.forwardRef(({className:t,...a},o)=>f.jsxs(qA,{children:[f.jsx(Hb,{}),f.jsx(Db,{ref:o,className:J("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),...a})]}));Ui.displayName=Db.displayName;const Hi=({className:t,...a})=>f.jsx("div",{className:J("flex flex-col space-y-1.5 text-center sm:text-left",t),...a});Hi.displayName="AlertDialogHeader";const Bi=({className:t,...a})=>f.jsx("div",{className:J("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",t),...a});Bi.displayName="AlertDialogFooter";const Pi=g.forwardRef(({className:t,...a},o)=>f.jsx(Lb,{ref:o,className:J("text-sm font-semibold",t),...a}));Pi.displayName=Lb.displayName;const $i=g.forwardRef(({className:t,...a},o)=>f.jsx(Ub,{ref:o,className:J("text-[11px] text-muted-foreground",t),...a}));$i.displayName=Ub.displayName;const qi=g.forwardRef(({className:t,...a},o)=>f.jsx(Mb,{ref:o,className:J(qf(),t),...a}));qi.displayName=Mb.displayName;const Vi=g.forwardRef(({className:t,...a},o)=>f.jsx(zb,{ref:o,className:J(qf({variant:"outline"}),"mt-2 sm:mt-0",t),...a}));Vi.displayName=zb.displayName;function VA(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 go({label:t,value:a,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:a})]})}function YA({formatDateTime:t,viewInfo:a}){const o=VA(a.packages);return f.jsxs("div",{"data-about-layout":"compact",className:"space-y-2",children:[f.jsxs(Pl,{className:"rounded-sm border-border/70 bg-background/75 shadow-none",children:[f.jsxs($l,{className:"pb-1.5 pt-2.5 px-3",children:[f.jsxs(ql,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(bN,{className:"h-3.5 w-3.5 text-primary"}),"Repository & runtime"]}),f.jsx(Vl,{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:[a.repository?.url?f.jsxs("a",{href:a.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:a.repository.url}),f.jsx(u0,{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(go,{label:"Branch",value:a.repository?.branch??"Unavailable",mono:!!a.repository?.branch}),f.jsx(go,{label:"Commit",value:a.repository?.commit??"Unavailable",mono:!!a.repository?.commit}),f.jsx(go,{label:"Runtime",value:`${a.packageName??"meshy"} ${a.version}`,mono:!0}),f.jsx(go,{label:"Node.js",value:a.runtime?.nodeVersion??"Unavailable",mono:!!a.runtime?.nodeVersion}),f.jsx(go,{label:"PID",value:a.runtime?String(a.runtime.pid):"Unavailable",mono:!!a.runtime}),f.jsx(go,{label:"Started",value:t(a.runtime?.startedAt)})]})]})]}),f.jsxs(Pl,{className:"rounded-sm border-border/70 bg-background/75 shadow-none",children:[f.jsxs($l,{className:"pb-1.5 pt-2.5 px-3",children:[f.jsxs(ql,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(d0,{className:"h-3.5 w-3.5 text-primary"}),"Package versions"]}),f.jsx(Vl,{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(qa,{variant:"outline",className:"w-fit rounded-sm border-border/70 bg-background/60 font-mono text-[10px]",children:s.value?.version})]},s.key))})]})]})}const GA="codex",HO="bypass",Bb=[{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"}],Pb=Bb.filter(t=>t.value==="codex"||t.value==="claudecode"||t.value==="copilot");function cf(t){return Pb.some(a=>a.value===t)?t:GA}const BO=[{value:"bypass",label:"Bypass"},{value:"plan",label:"Plan"},{value:"edit",label:"Edit"},{value:"dangerous",label:"Dangerous"}],IA=new Set(Bb.filter(t=>t.supportsFollowUp).map(t=>t.value));function PO(t){const a=s=>typeof s=="string"&&IA.has(s),o=(t.nodeSupportedAgents??[]).filter(a);return o.length>0?Array.from(new Set(o)):Array.from(new Set([t.taskAgent,t.activeAgent].filter(a)))}const $O=[{value:"active",label:"Active"},{value:"running",label:"Running"},{value:"waiting",label:"Waiting"},{value:"closed",label:"Closed"},{value:"shared",label:"Shared"},{value:"archived",label:"Archived"}],qO=[{value:"all",label:"All task types"},{value:"native",label:"Native sessions"},{value:"meshy",label:"Meshy chats"}],XA=new Set(["pending","assigned"]),QA=new Set(["running"]),KA=new Set(["completed","failed","cancelled"]),VO=10;function YO(t,a){switch(a){case"running":return QA.has(t.status);case"waiting":return XA.has(t.status);case"closed":return KA.has(t.status);case"shared":return!!t.activeShare;case"archived":return t.status==="archived";default:return t.status!=="archived"}}function GO(t,a){if(a==="all")return!0;const o=t.conversationKind==="nativeSession";return a==="native"?o:!o}function IO(t,a){const o=a.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 ZA(t,a,o){return t?a?.find(c=>c.id===t)?.name??o??t.slice(0,8):"unassigned"}function XO(t,a,o){return ZA(t,a,o).toLowerCase()}function QO(t){return t.type!=="node.status"&&t.type!=="cluster.state"}function KO(t,a,o){return!t.assignedTo||o?.id===t.assignedTo?!0:a?.some(s=>s.id===t.assignedTo)??!1}function ZO(t,a){return[...t].sort((o,s)=>o.id===a?-1:s.id===a?1:o.name.localeCompare(s.name))}function WO(t){if(!t||typeof t!="object")return null;const a=t,o=a.createMode,s=o==="chat"||o==="native"?o:void 0,c=a.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:a.draftNewTask===!0,returnRoute:typeof a.returnRoute=="string"?a.returnRoute:void 0,returnTaskId:typeof a.returnTaskId=="string"||a.returnTaskId===null?a.returnTaskId:void 0,createMode:s,createDefaults:m}}function FO(t){return t==="default workspace"?t:t.replace(/\\/g,"/").split("/").filter(Boolean).at(-1)??t}function JO(t){const a=Date.now()-t;return a<6e4?"just now":a<36e5?`${Math.floor(a/6e4)}m`:a<864e5?`${Math.floor(a/36e5)}h`:`${Math.floor(a/864e5)}d`}function eD(t){return new Date(t).toLocaleString()}function tD(t){const a=Math.floor(t/1e3),o=Math.floor(a/3600),s=Math.floor(a%3600/60),c=a%60;return`${String(o).padStart(2,"0")}:${String(s).padStart(2,"0")}:${String(c).padStart(2,"0")}`}async function $b(t,a="Copied to clipboard"){try{if(globalThis.navigator?.clipboard?.writeText)return await globalThis.navigator.clipboard.writeText(t),Te.success(a),!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 Te.success(a),!0}catch(o){return Te.error(o instanceof Error?o.message:"Failed to copy"),!1}}const WA="default workspace";function Ni(t){const a=t.replace(/\\/g,"/");return a==="/"||/^[A-Za-z]:\/$/.test(a)?a:a.replace(/\/+$/g,"")||a}function FA(t){const a=t.replace(/\\/g,"/");return a.startsWith("/")||a.startsWith("//")||/^[A-Za-z]:\//.test(a)}function JA(t,a){const o=Ni(t),s=a.replace(/\\/g,"/").replace(/^\/+|\/+$/g,"");return!s||s==="."?o:o==="/"||/^[A-Za-z]:\/$/.test(o)?`${o}${s}`:`${o}/${s}`}function e5(t,a){const o=t.effectiveProjectPath?.trim();if(o)return Ni(o);const s=t.project?.trim();if(!s)return WA;if(FA(s)||!t.assignedTo)return Ni(s);const c=a?.get(t.assignedTo)?.trim();return c?JA(c,s):Ni(s)}function nD({nodeStatusById:t,nodeNameById:a,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=a.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(C=>C.toLowerCase().includes(m)))continue}h.push(v)}}return h}function aD(t,a,o,s,c){const u=new Map;for(const h of t){const v=h.assignedTo??null,p=v??"__unassigned__",b=v?a.get(v)??h.assignedNodeName??v.slice(0,8):"Unassigned",y=e5(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:a.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 t5=["queued","running"],n5=["copilot.tunnel","copilot.tunnel.disable"],a5=1e4;function Xv(t){return t?.status==="succeeded"||t?.status==="failed"}function Qv(t){return t?.kind==="copilot.tunnel"||t?.kind==="copilot.tunnel.disable"}function r5(t){return t.reduce((a,o)=>!a||o.updatedAt>a.updatedAt?o:a,null)}async function o5(t,a=a0){const o=await Promise.all(n5.flatMap(s=>t5.map(c=>a({kind:s,status:c,nodeId:t}))));return r5(o.flat())}function Kv(t){return t?.split(/\r?\n/).map(a=>a.trim()).filter(Boolean).at(-1)??null}function l5(t,a){return[t,...a].join(" ")}function s5(t,a){return t?typeof t.expiresAt=="number"?t.expiresAt:typeof t.expiresInSeconds=="number"?(a?.updatedAt??Date.now())+t.expiresInSeconds*1e3:null:null}function i5(t,a){if(!t)return null;const o=t-a;return o<=0?"expired":`${Math.ceil(o/6e4)}m expiry`}function c5(t,a,o){return a&&!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 u5(t,a){return a||t?.status==="queued"||t?.status==="running"?f.jsx(ac,{className:"h-3.5 w-3.5 animate-spin text-primary"}):t?.result?.available?f.jsx(bo,{className:"h-3.5 w-3.5 text-emerald-500"}):t?.status==="failed"?f.jsx(Sv,{className:"h-3.5 w-3.5 text-destructive"}):f.jsx(Sv,{className:"h-3.5 w-3.5 text-muted-foreground"})}function d5({checked:t,disabled:a,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:a,onClick:()=>o(!t),className:J("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:J("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 f5({nodeId:t,nodeName:a}){const[o,s]=g.useState(null),[c,u]=g.useState(!1),[m,h]=g.useState(!1),[v,p]=g.useState(!1),[b,y]=g.useState(()=>Date.now()),S=o?.status==="queued"||o?.status==="running",C=o?.result,R=C?.auth??null,E=s5(R,o),T=!!(S&&C?.status==="auth-required"&&E&&b>=E),k=i5(E,b),A=o?.error??C?.detail??Kv(C?.stderr)??Kv(C?.stdout),M=C?l5(C.command,C.args):"npx -y ghc-tunnel@latest -d",L=!!C?.available||S&&o?.kind==="copilot.tunnel",H=S&&Qv(o),I=o?.kind==="copilot.tunnel.disable"?"Retry stopping Copilot tunnel":"Retry enabling Copilot tunnel",G=c||m||v||S&&!T,V=g.useMemo(()=>T?"GitHub device authorization expired":c5(o,c,A),[T,c,A,o]);g.useEffect(()=>{if(!S||!E)return;y(Date.now());const ae=window.setInterval(()=>y(Date.now()),1e3);return()=>window.clearInterval(ae)},[E,S]),g.useEffect(()=>{let ae=!1;async function ie(){u(!0);try{const ce=await o5(t);if(ae)return;if(ce){s(ce);return}const ue=await vv(t);ae||s(ue)}catch(ce){ae||Te.error(ce instanceof Error?ce.message:"Failed to check Copilot tunnel")}finally{ae||u(!1)}}return s(null),ie(),()=>{ae=!0}},[t]),g.useEffect(()=>{if(!o||Xv(o))return;let ae=!1;const ie=o.id;async function ce(){try{const re=await n0(ie);if(ae)return;if(re.kind==="copilot.tunnel.status"&&!Xv(re)&&Date.now()-re.createdAt>a5){const _=await vv(t);ae||s(_);return}s(re),re.status==="succeeded"&&re.kind==="copilot.tunnel"&&Te.success(`Copilot tunnel is available on ${a}`),re.status==="succeeded"&&re.kind==="copilot.tunnel.disable"&&Te.success(`Copilot tunnel stopped on ${a}`),re.status==="failed"&&re.kind!=="copilot.tunnel.status"&&Te.error(re.error??"Copilot tunnel failed")}catch(re){ae||Te.error(re instanceof Error?re.message:"Failed to refresh Copilot tunnel")}}ce();const ue=window.setInterval(ce,2e3);return()=>{ae=!0,window.clearInterval(ue)}},[t,a,o?.id,o?.status]);const oe=g.useCallback(async ae=>{h(!0);try{const ie=ae?await gv(t):await yv(t);s(ie),Te.info(ae?`Copilot tunnel enable requested on ${a}`:`Copilot tunnel stop requested on ${a}`)}catch(ie){Te.error(ie instanceof Error?ie.message:"Failed to update Copilot tunnel")}finally{h(!1)}},[t,a]),fe=g.useCallback(async()=>{if(!Qv(o))return;const ae=o.kind==="copilot.tunnel.disable";p(!0);try{await kE(o.id,`Retry requested for ${o.kind}`);const ie=ae?await yv(t):await gv(t);s(ie),Te.info(ae?`Copilot tunnel stop retry requested on ${a}`:`Copilot tunnel enable retry requested on ${a}`)}catch(ie){Te.error(ie instanceof Error?ie.message:"Failed to retry Copilot tunnel")}finally{p(!1)}},[t,a,o]);return f.jsxs(Pl,{"data-copilot-tunnel-section":"true",className:"rounded-sm border-border/70 bg-background/75 shadow-none xl:col-span-2",children:[f.jsx($l,{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(ql,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(i0,{className:"h-3.5 w-3.5 text-primary"}),"GitHub Copilot Tunnel"]}),f.jsx(Vl,{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":V,title:V,className:"inline-flex h-5 w-5 items-center justify-center",children:u5(o,c)}),H&&f.jsx(xt,{type:"button",variant:"outline",size:"icon",className:"h-7 w-7 rounded-sm",title:I,"aria-label":I,"data-copilot-tunnel-retry":"true",disabled:c||m||v,onClick:()=>{fe()},children:v?f.jsx(ac,{className:"h-3.5 w-3.5 animate-spin"}):f.jsx(aT,{className:"h-3.5 w-3.5"})}),f.jsx(d5,{checked:L,disabled:G,onCheckedChange:ae=>{oe(ae)}})]})]})}),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:J("h-1.5 w-1.5 rounded-sm",C?.available?"bg-emerald-500":S||c?"animate-pulse bg-amber-500":o?.status==="failed"?"bg-destructive":"bg-muted-foreground/50")}),V]}),f.jsx("div",{className:"truncate font-mono text-[10px] text-muted-foreground",children:M}),(S||c||m||v)&&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"})})]}),R&&S&&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(BN,{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:R.code}),k?f.jsx("span",{className:T?"text-destructive":void 0,children:k}):null]})]}),f.jsxs("div",{className:"flex items-center gap-1",children:[f.jsx(xt,{type:"button",variant:"outline",size:"icon",className:"h-7 w-7 rounded-sm",title:"Copy device code","aria-label":"Copy device code",onClick:()=>{$b(R.code,"Device code copied")},children:f.jsx(c0,{className:"h-3.5 w-3.5"})}),f.jsx(xt,{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:R.url,target:"_blank",rel:"noreferrer",children:f.jsx(u0,{className:"h-3.5 w-3.5"})})})]})]}),A&&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:A})]})]})}function m5({value:t,disabled:a=!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(ji,{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:Pb.map(u=>{const m=u.value===c;return f.jsx("button",{type:"button","data-default-task-agent-option":u.value,"aria-pressed":m,disabled:a||o,onClick:()=>s(u.value),className:J("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 h5={online:"bg-emerald-500",busy:"bg-amber-500",offline:"bg-destructive"},p5={online:"Online",busy:"Busy",offline:"Offline"},g5={default:"h-2.5 w-2.5",compact:"h-2 w-2"};function qb({className:t,pulse:a=!0,size:o="default",status:s}){const c=g5[o],u=p5[s];return f.jsxs("span",{role:"img","aria-label":u,title:u,className:J("relative inline-flex shrink-0",c,t),children:[a&&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:J("relative inline-flex rounded-full",c,h5[s])})]})}function v5({role:t,size:a="default"}){return f.jsx(qa,{variant:t==="leader"?"default":"secondary",className:J(a==="compact"?"px-1.5 py-0 text-[9px] leading-4":"text-[11px]"),children:t})}const Vb={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 rD({status:t,size:a="default"}){const o=Vb[t],s=a==="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(qa,{variant:o.variant,className:J("rounded-sm font-medium shadow-none",s,o.className),children:[f.jsx("span",{className:J("rounded-full",o.dotClass)}),t]})}function oD({status:t,isNative:a=!1,size:o="default",className:s}){const c=Vb[t],u=[t,a?"native":null].filter(Boolean).join(", "),m=o==="compact"?"h-1.5 w-1.5":"h-2 w-2";return f.jsxs("span",{className:J("inline-flex shrink-0 items-center gap-1",s),title:u,"aria-label":u,children:[f.jsx("span",{className:J("rounded-full",m,c.dotClass),title:t}),a&&f.jsx("span",{className:J("rounded-full bg-sky-500",m),title:"native"})]})}const y5={critical:{variant:"destructive",label:"Critical"},high:{variant:"outline",label:"High"},normal:{variant:"secondary",label:"Normal"},low:{variant:"secondary",label:"Low"}};function lD({priority:t}){const a=y5[t];return f.jsx(qa,{variant:a.variant,className:"rounded-sm px-1.5 py-0 text-[10px] leading-4 shadow-none",children:a.label})}const b5={busy:"bg-amber-500",offline:"bg-destructive",online:"bg-emerald-500"},Zv="settings-node-selector-listbox";function Wv(t){return`settings-node-option-${t}`}function x5({decorative:t,node:a}){return t?f.jsx("span",{"aria-hidden":"true",className:"relative inline-flex h-2 w-2 shrink-0",children:f.jsx("span",{className:J("relative inline-flex h-2 w-2 rounded-full",b5[a.status])})}):f.jsx(qb,{status:a.status,size:"compact",pulse:!1})}function Fv({decorativeStatus:t=!1,node:a}){return f.jsxs("span",{className:"flex min-w-0 flex-1 items-center gap-1.5",children:[f.jsx(x5,{decorative:t,node:a}),f.jsx("span",{className:"min-w-0 flex-1 truncate",children:a.name})]})}function w5({formatDateTime:t,isLiveLocalNode:a,onSelectedNodeChange:o,selectableNodes:s,selectedNode:c}){const[u,m]=g.useState(!1),[h,v]=g.useState(0),p=g.useRef(null),b=Math.max(0,s.findIndex(A=>A.id===c.id)),y=Math.min(h,Math.max(s.length-1,0)),S=s[y]??s[b]??c,C=s.map(A=>A.id).join("\0");g.useEffect(()=>{if(!u)return;const A=L=>{const H=L.target,I=p.current;!I||!(H instanceof Node)||I.contains(H)||m(!1)},M=L=>{L.key==="Escape"&&m(!1)};return document.addEventListener("pointerdown",A),document.addEventListener("keydown",M),()=>{document.removeEventListener("pointerdown",A),document.removeEventListener("keydown",M)}},[u]),g.useEffect(()=>{v(b),m(!1)},[C,c.id,b]);function R(A){s.length!==0&&(m(!0),v(M=>((u?M:b)+A+s.length)%s.length))}function E(){S&&T(S.id)}function T(A){o(A),m(!1)}function k(A){if(s.length!==0){if(A.key==="ArrowDown"){A.preventDefault(),R(1);return}if(A.key==="ArrowUp"){A.preventDefault(),R(-1);return}if(A.key==="Home"||A.key==="End"){A.preventDefault(),m(!0),v(A.key==="Home"?0:s.length-1);return}if(A.key==="Enter"||A.key===" "){if(!u)return;A.preventDefault(),E();return}A.key==="Escape"&&(A.preventDefault(),m(!1))}}return f.jsxs("div",{"data-settings-node-selector":"true",className:"flex flex-wrap items-center justify-between gap-1.5",children:[s.length>1?f.jsxs("div",{ref:p,"data-settings-node-control":"true",className:"relative w-40 sm:w-44",children:[f.jsxs("button",{type:"button","aria-haspopup":"listbox","aria-controls":Zv,"aria-expanded":u,"aria-activedescendant":u?Wv(S.id):void 0,className:"flex h-7 w-full items-center justify-between 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:outline-none focus:ring-1 focus:ring-primary/25 [&>span:first-child]:!flex [&>span:first-child]:!min-w-0 [&>span:first-child]:!flex-1 [&>span:first-child]:!items-center",onClick:()=>{v(b),m(A=>!A)},onKeyDown:k,children:[f.jsx("span",{className:"flex min-w-0 items-center gap-1.5",children:f.jsx(Fv,{decorativeStatus:!0,node:c})}),f.jsx(gr,{className:J("ml-1 h-3.5 w-3.5 shrink-0 opacity-50 transition-transform",u&&"rotate-180")})]}),f.jsx("div",{id:Zv,role:"listbox","aria-label":"Choose settings node",hidden:!u,className:"settings-node-select-content z-[80] w-full rounded-sm border-border/70 bg-popover/96 text-[9px] leading-4 !shadow-none absolute left-0 top-full mt-1 max-h-56 overflow-y-auto border p-1",children:s.map((A,M)=>{const L=A.id===S.id;return f.jsx("button",{id:Wv(A.id),type:"button",role:"option","aria-selected":A.id===c.id,"data-active":L?"true":void 0,"data-settings-node-option":A.id,"data-settings-node-option-active":L?"true":void 0,className:J("settings-node-select-item flex w-full items-center rounded-sm py-1 pl-2 pr-2 text-left text-[9px] leading-4 whitespace-nowrap data-[active=true]:bg-primary/10 hover:bg-primary/10 hover:text-foreground focus:bg-primary/10 focus:text-foreground focus:outline-none",A.id===c.id?"bg-primary/10 text-foreground":"text-popover-foreground"),onClick:()=>T(A.id),onMouseEnter:()=>v(M),children:f.jsx(Fv,{node:A})},A.id)})})]}):f.jsxs("span",{"data-settings-node-control":"true",className:"flex h-7 w-40 items-center gap-1.5 rounded-sm border border-border/70 bg-background/75 px-2 text-[11px] text-muted-foreground sm:w-44",children:[f.jsx(qb,{status:c.status}),f.jsx("span",{className:"font-medium text-foreground",children:c.name})]}),f.jsxs("div",{"data-settings-node-badges":"true",className:"ml-auto flex flex-wrap items-center justify-end gap-1.5",children:[f.jsx(v5,{role:c.role,size:"compact"}),!a&&f.jsx(qa,{variant:"outline",title:`Updated ${t(c.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"})]})]})}const sc=g.forwardRef(({className:t,type:a,...o},s)=>f.jsx("input",{type:a,className:J("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}));sc.displayName="Input";function S5(){return ve("/system/quick-chats")}function E5(t){return ve("/system/quick-chats",{method:"PUT",body:JSON.stringify({quickChats:t})})}const uf="quick-chats:updated";function N5(){typeof window>"u"||window.dispatchEvent(new CustomEvent(uf))}function T5(){const[t,a]=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 S5();a(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 E5(b);return a(y.quickChats),h(null),N5(),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(uf,b),()=>window.removeEventListener(uf,b)},[v]),{error:m,loading:o,quickChats:t,refresh:v,save:p,saving:c}}function Yb(t){return t.trim().replace(/^\/+/,"").toLowerCase()}function Gb(t,a){const o=t.trim();if(!o.startsWith("/"))return[];const s=Yb(o);return a.filter(c=>c.alias.startsWith(s))}function Yi(t,a){return a<=0?-1:(t%a+a)%a}function sD(t,a,o=0){const s=Gb(t,a),c=Yi(o,s.length);return c>=0?s[c]??null:null}function iD(t,a,o){const s=Yi(t,a);return s<0?0:Yi(s+o,a)}function cD({query:t,quickChats:a,selectedIndex:o=0,onSelect:s,onActiveIndexChange:c}){const u=Gb(t,a);if(u.length===0)return null;const m=Yi(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 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(Uf,{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:J("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:J("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:J("line-clamp-1 min-w-0 text-[9px] leading-3 text-muted-foreground",v===m&&"text-primary/90"),children:h.prompt})]},h.alias))})]})}const C5="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 R5=0;function Ti(t,a=0){return{id:t?`${t.alias}:${a}`:`new:${R5++}`,alias:t?.alias??"",prompt:t?.prompt??""}}function df(t){return{quickChats:t.map(a=>({alias:Yb(a.alias),prompt:a.prompt.trim()})).filter(a=>a.alias.length>0&&a.prompt.length>0)}}function A5(t,a){const o=df(t).quickChats,s=a.map((u,m)=>Ti(u,m)),c=df(s).quickChats;return JSON.stringify(o)!==JSON.stringify(c)}function k5(){const{error:t,loading:a,quickChats:o,save:s,saving:c}=T5(),[u,m]=g.useState(()=>o.map((y,S)=>Ti(y,S))),h=u.length>0,v=g.useMemo(()=>df(u),[u]),p=g.useMemo(()=>A5(u,o),[u,o]);g.useEffect(()=>{m(o.map((y,S)=>Ti(y,S)))},[o]);async function b(){try{await s(v.quickChats),Te.success("Quick chats saved")}catch(y){Te.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(Uf,{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(xt,{type:"button",variant:"outline",onClick:()=>m(y=>[...y,Ti(void 0,y.length)]),className:"h-7 rounded-sm px-2 text-[10px]",children:[f.jsx(WN,{className:"h-3.5 w-3.5"}),"Add"]}),f.jsxs(xt,{type:"button",onClick:b,disabled:c||!p,className:"h-7 rounded-sm px-2 text-[10px]",children:[c?f.jsx(ac,{className:"h-3.5 w-3.5 animate-spin"}):f.jsx(oT,{className:"h-3.5 w-3.5"}),"Save"]})]})]})}),a&&!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(sc,{"aria-label":`Quick chat ${S+1} alias`,value:y.alias,onChange:C=>m(R=>R.map(E=>E.id===y.id?{...E,alias:C.target.value}:E)),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:C=>m(R=>R.map(E=>E.id===y.id?{...E,prompt:C.target.value}:E)),placeholder:"Prompt text",className:C5}),f.jsx(xt,{type:"button",variant:"ghost",size:"icon",onClick:()=>m(C=>C.filter(R=>R.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(bT,{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})]})}function Ib(t){const a=g.useRef({value:t,previous:t});return g.useMemo(()=>(a.current.value!==t&&(a.current.previous=a.current.value,a.current.value=t),a.current.previous),[t])}function Xb(t){const[a,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]),a}var ic="Checkbox",[j5]=ko(ic),[_5,em]=j5(ic);function O5(t){const{__scopeCheckbox:a,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,C]=zi({prop:o,defaultProp:c??!1,onChange:v,caller:ic}),[R,E]=g.useState(null),[T,k]=g.useState(null),A=g.useRef(!1),M=R?!!m||!!R.closest("form"):!0,L={checked:S,disabled:u,setChecked:C,control:R,setControl:E,name:h,form:m,value:b,hasConsumerStoppedPropagationRef:A,required:p,defaultChecked:Ha(c)?!1:c,isFormControl:M,bubbleInput:T,setBubbleInput:k};return f.jsx(_5,{scope:a,...L,children:D5(y)?y(L):s})}var Qb="CheckboxTrigger",Kb=g.forwardRef(({__scopeCheckbox:t,onKeyDown:a,onClick:o,...s},c)=>{const{control:u,value:m,disabled:h,checked:v,required:p,setControl:b,setChecked:y,hasConsumerStoppedPropagationRef:S,isFormControl:C,bubbleInput:R}=em(Qb,t),E=Fe(c,b),T=g.useRef(v);return g.useEffect(()=>{const k=u?.form;if(k){const A=()=>y(T.current);return k.addEventListener("reset",A),()=>k.removeEventListener("reset",A)}},[u,y]),f.jsx($e.button,{type:"button",role:"checkbox","aria-checked":Ha(v)?"mixed":v,"aria-required":p,"data-state":ex(v),"data-disabled":h?"":void 0,disabled:h,value:m,...s,ref:E,onKeyDown:Ge(a,k=>{k.key==="Enter"&&k.preventDefault()}),onClick:Ge(o,k=>{y(A=>Ha(A)?!0:!A),R&&C&&(S.current=k.isPropagationStopped(),S.current||k.stopPropagation())})})});Kb.displayName=Qb;var tm=g.forwardRef((t,a)=>{const{__scopeCheckbox:o,name:s,checked:c,defaultChecked:u,required:m,disabled:h,value:v,onCheckedChange:p,form:b,...y}=t;return f.jsx(O5,{__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(Kb,{...y,ref:a,__scopeCheckbox:o}),S&&f.jsx(Jb,{__scopeCheckbox:o})]})})});tm.displayName=ic;var Zb="CheckboxIndicator",Wb=g.forwardRef((t,a)=>{const{__scopeCheckbox:o,forceMount:s,...c}=t,u=em(Zb,o);return f.jsx(Zl,{present:s||Ha(u.checked)||u.checked===!0,children:f.jsx($e.span,{"data-state":ex(u.checked),"data-disabled":u.disabled?"":void 0,...c,ref:a,style:{pointerEvents:"none",...t.style}})})});Wb.displayName=Zb;var Fb="CheckboxBubbleInput",Jb=g.forwardRef(({__scopeCheckbox:t,...a},o)=>{const{control:s,hasConsumerStoppedPropagationRef:c,checked:u,defaultChecked:m,required:h,disabled:v,name:p,value:b,form:y,bubbleInput:S,setBubbleInput:C}=em(Fb,t),R=Fe(o,C),E=Ib(u),T=Xb(s);g.useEffect(()=>{const A=S;if(!A)return;const M=window.HTMLInputElement.prototype,H=Object.getOwnPropertyDescriptor(M,"checked").set,I=!c.current;if(E!==u&&H){const G=new Event("click",{bubbles:I});A.indeterminate=Ha(u),H.call(A,Ha(u)?!1:u),A.dispatchEvent(G)}},[S,E,u,c]);const k=g.useRef(Ha(u)?!1:u);return f.jsx($e.input,{type:"checkbox","aria-hidden":!0,defaultChecked:m??k.current,required:h,disabled:v,name:p,value:b,form:y,...a,tabIndex:-1,ref:R,style:{...a.style,...T,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});Jb.displayName=Fb;function D5(t){return typeof t=="function"}function Ha(t){return t==="indeterminate"}function ex(t){return Ha(t)?"indeterminate":t?"checked":"unchecked"}const tx=g.forwardRef(({className:t,...a},o)=>f.jsx(tm,{ref:o,className:J("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),...a,children:f.jsx(Wb,{className:J("flex items-center justify-center text-current"),children:f.jsx(_i,{className:"h-3.5 w-3.5"})})}));tx.displayName=tm.displayName;function Jv(t,[a,o]){return Math.min(o,Math.max(a,t))}function M5(t){const a=t+"CollectionProvider",[o,s]=ko(a),[c,u]=o(a,{collectionRef:{current:null},itemMap:new Map}),m=E=>{const{scope:T,children:k}=E,A=le.useRef(null),M=le.useRef(new Map).current;return f.jsx(c,{scope:T,itemMap:M,collectionRef:A,children:k})};m.displayName=a;const h=t+"CollectionSlot",v=Gl(h),p=le.forwardRef((E,T)=>{const{scope:k,children:A}=E,M=u(h,k),L=Fe(T,M.collectionRef);return f.jsx(v,{ref:L,children:A})});p.displayName=h;const b=t+"CollectionItemSlot",y="data-radix-collection-item",S=Gl(b),C=le.forwardRef((E,T)=>{const{scope:k,children:A,...M}=E,L=le.useRef(null),H=Fe(T,L),I=u(b,k);return le.useEffect(()=>(I.itemMap.set(L,{ref:L,...M}),()=>{I.itemMap.delete(L)})),f.jsx(S,{[y]:"",ref:H,children:A})});C.displayName=b;function R(E){const T=u(t+"CollectionConsumer",E);return le.useCallback(()=>{const A=T.collectionRef.current;if(!A)return[];const M=Array.from(A.querySelectorAll(`[${y}]`));return Array.from(T.itemMap.values()).sort((I,G)=>M.indexOf(I.ref.current)-M.indexOf(G.ref.current))},[T.collectionRef,T.itemMap])}return[{Provider:m,Slot:p,ItemSlot:C},R,s]}var z5=g.createContext(void 0);function L5(t){const a=g.useContext(z5);return t||a||"ltr"}const U5=["top","right","bottom","left"],Ba=Math.min,Zt=Math.max,Gi=Math.round,yi=Math.floor,Mn=t=>({x:t,y:t}),H5={left:"right",right:"left",bottom:"top",top:"bottom"};function ff(t,a,o){return Zt(t,Ba(a,o))}function aa(t,a){return typeof t=="function"?t(a):t}function ra(t){return t.split("-")[0]}function jo(t){return t.split("-")[1]}function nm(t){return t==="x"?"y":"x"}function am(t){return t==="y"?"height":"width"}function Dn(t){const a=t[0];return a==="t"||a==="b"?"y":"x"}function rm(t){return nm(Dn(t))}function B5(t,a,o){o===void 0&&(o=!1);const s=jo(t),c=rm(t),u=am(c);let m=c==="x"?s===(o?"end":"start")?"right":"left":s==="start"?"bottom":"top";return a.reference[u]>a.floating[u]&&(m=Ii(m)),[m,Ii(m)]}function P5(t){const a=Ii(t);return[mf(t),a,mf(a)]}function mf(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}const ey=["left","right"],ty=["right","left"],$5=["top","bottom"],q5=["bottom","top"];function V5(t,a,o){switch(t){case"top":case"bottom":return o?a?ty:ey:a?ey:ty;case"left":case"right":return a?$5:q5;default:return[]}}function Y5(t,a,o,s){const c=jo(t);let u=V5(ra(t),o==="start",s);return c&&(u=u.map(m=>m+"-"+c),a&&(u=u.concat(u.map(mf)))),u}function Ii(t){const a=ra(t);return H5[a]+t.slice(a.length)}function G5(t){return{top:0,right:0,bottom:0,left:0,...t}}function nx(t){return typeof t!="number"?G5(t):{top:t,right:t,bottom:t,left:t}}function Xi(t){const{x:a,y:o,width:s,height:c}=t;return{width:s,height:c,top:o,left:a,right:a+s,bottom:o+c,x:a,y:o}}function ny(t,a,o){let{reference:s,floating:c}=t;const u=Dn(a),m=rm(a),h=am(m),v=ra(a),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 C;switch(v){case"top":C={x:b,y:s.y-c.height};break;case"bottom":C={x:b,y:s.y+s.height};break;case"right":C={x:s.x+s.width,y};break;case"left":C={x:s.x-c.width,y};break;default:C={x:s.x,y:s.y}}switch(jo(a)){case"start":C[m]-=S*(o&&p?-1:1);break;case"end":C[m]+=S*(o&&p?-1:1);break}return C}async function I5(t,a){var o;a===void 0&&(a={});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:C=0}=aa(a,t),R=nx(C),T=h[S?y==="floating"?"reference":"floating":y],k=Xi(await u.getClippingRect({element:(o=await(u.isElement==null?void 0:u.isElement(T)))==null||o?T:T.contextElement||await(u.getDocumentElement==null?void 0:u.getDocumentElement(h.floating)),boundary:p,rootBoundary:b,strategy:v})),A=y==="floating"?{x:s,y:c,width:m.floating.width,height:m.floating.height}:m.reference,M=await(u.getOffsetParent==null?void 0:u.getOffsetParent(h.floating)),L=await(u.isElement==null?void 0:u.isElement(M))?await(u.getScale==null?void 0:u.getScale(M))||{x:1,y:1}:{x:1,y:1},H=Xi(u.convertOffsetParentRelativeRectToViewportRelativeRect?await u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:h,rect:A,offsetParent:M,strategy:v}):A);return{top:(k.top-H.top+R.top)/L.y,bottom:(H.bottom-k.bottom+R.bottom)/L.y,left:(k.left-H.left+R.left)/L.x,right:(H.right-k.right+R.right)/L.x}}const X5=50,Q5=async(t,a,o)=>{const{placement:s="bottom",strategy:c="absolute",middleware:u=[],platform:m}=o,h=m.detectOverflow?m:{...m,detectOverflow:I5},v=await(m.isRTL==null?void 0:m.isRTL(a));let p=await m.getElementRects({reference:t,floating:a,strategy:c}),{x:b,y}=ny(p,s,v),S=s,C=0;const R={};for(let E=0;E<u.length;E++){const T=u[E];if(!T)continue;const{name:k,fn:A}=T,{x:M,y:L,data:H,reset:I}=await A({x:b,y,initialPlacement:s,placement:S,strategy:c,middlewareData:R,rects:p,platform:h,elements:{reference:t,floating:a}});b=M??b,y=L??y,R[k]={...R[k],...H},I&&C<X5&&(C++,typeof I=="object"&&(I.placement&&(S=I.placement),I.rects&&(p=I.rects===!0?await m.getElementRects({reference:t,floating:a,strategy:c}):I.rects),{x:b,y}=ny(p,S,v)),E=-1)}return{x:b,y,placement:S,strategy:c,middlewareData:R}},K5=t=>({name:"arrow",options:t,async fn(a){const{x:o,y:s,placement:c,rects:u,platform:m,elements:h,middlewareData:v}=a,{element:p,padding:b=0}=aa(t,a)||{};if(p==null)return{};const y=nx(b),S={x:o,y:s},C=rm(c),R=am(C),E=await m.getDimensions(p),T=C==="y",k=T?"top":"left",A=T?"bottom":"right",M=T?"clientHeight":"clientWidth",L=u.reference[R]+u.reference[C]-S[C]-u.floating[R],H=S[C]-u.reference[C],I=await(m.getOffsetParent==null?void 0:m.getOffsetParent(p));let G=I?I[M]:0;(!G||!await(m.isElement==null?void 0:m.isElement(I)))&&(G=h.floating[M]||u.floating[R]);const V=L/2-H/2,oe=G/2-E[R]/2-1,fe=Ba(y[k],oe),ae=Ba(y[A],oe),ie=fe,ce=G-E[R]-ae,ue=G/2-E[R]/2+V,re=ff(ie,ue,ce),_=!v.arrow&&jo(c)!=null&&ue!==re&&u.reference[R]/2-(ue<ie?fe:ae)-E[R]/2<0,$=_?ue<ie?ue-ie:ue-ce:0;return{[C]:S[C]+$,data:{[C]:re,centerOffset:ue-re-$,..._&&{alignmentOffset:$}},reset:_}}}),Z5=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(a){var o,s;const{placement:c,middlewareData:u,rects:m,initialPlacement:h,platform:v,elements:p}=a,{mainAxis:b=!0,crossAxis:y=!0,fallbackPlacements:S,fallbackStrategy:C="bestFit",fallbackAxisSideDirection:R="none",flipAlignment:E=!0,...T}=aa(t,a);if((o=u.arrow)!=null&&o.alignmentOffset)return{};const k=ra(c),A=Dn(h),M=ra(h)===h,L=await(v.isRTL==null?void 0:v.isRTL(p.floating)),H=S||(M||!E?[Ii(h)]:P5(h)),I=R!=="none";!S&&I&&H.push(...Y5(h,E,R,L));const G=[h,...H],V=await v.detectOverflow(a,T),oe=[];let fe=((s=u.flip)==null?void 0:s.overflows)||[];if(b&&oe.push(V[k]),y){const ue=B5(c,m,L);oe.push(V[ue[0]],V[ue[1]])}if(fe=[...fe,{placement:c,overflows:oe}],!oe.every(ue=>ue<=0)){var ae,ie;const ue=(((ae=u.flip)==null?void 0:ae.index)||0)+1,re=G[ue];if(re&&(!(y==="alignment"?A!==Dn(re):!1)||fe.every(O=>Dn(O.placement)===A?O.overflows[0]>0:!0)))return{data:{index:ue,overflows:fe},reset:{placement:re}};let _=(ie=fe.filter($=>$.overflows[0]<=0).sort(($,O)=>$.overflows[1]-O.overflows[1])[0])==null?void 0:ie.placement;if(!_)switch(C){case"bestFit":{var ce;const $=(ce=fe.filter(O=>{if(I){const W=Dn(O.placement);return W===A||W==="y"}return!0}).map(O=>[O.placement,O.overflows.filter(W=>W>0).reduce((W,N)=>W+N,0)]).sort((O,W)=>O[1]-W[1])[0])==null?void 0:ce[0];$&&(_=$);break}case"initialPlacement":_=h;break}if(c!==_)return{reset:{placement:_}}}return{}}}};function ay(t,a){return{top:t.top-a.height,right:t.right-a.width,bottom:t.bottom-a.height,left:t.left-a.width}}function ry(t){return U5.some(a=>t[a]>=0)}const W5=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(a){const{rects:o,platform:s}=a,{strategy:c="referenceHidden",...u}=aa(t,a);switch(c){case"referenceHidden":{const m=await s.detectOverflow(a,{...u,elementContext:"reference"}),h=ay(m,o.reference);return{data:{referenceHiddenOffsets:h,referenceHidden:ry(h)}}}case"escaped":{const m=await s.detectOverflow(a,{...u,altBoundary:!0}),h=ay(m,o.floating);return{data:{escapedOffsets:h,escaped:ry(h)}}}default:return{}}}}},ax=new Set(["left","top"]);async function F5(t,a){const{placement:o,platform:s,elements:c}=t,u=await(s.isRTL==null?void 0:s.isRTL(c.floating)),m=ra(o),h=jo(o),v=Dn(o)==="y",p=ax.has(m)?-1:1,b=u&&v?-1:1,y=aa(a,t);let{mainAxis:S,crossAxis:C,alignmentAxis:R}=typeof y=="number"?{mainAxis:y,crossAxis:0,alignmentAxis:null}:{mainAxis:y.mainAxis||0,crossAxis:y.crossAxis||0,alignmentAxis:y.alignmentAxis};return h&&typeof R=="number"&&(C=h==="end"?R*-1:R),v?{x:C*b,y:S*p}:{x:S*p,y:C*b}}const J5=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(a){var o,s;const{x:c,y:u,placement:m,middlewareData:h}=a,v=await F5(a,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}}}}},ek=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(a){const{x:o,y:s,placement:c,platform:u}=a,{mainAxis:m=!0,crossAxis:h=!1,limiter:v={fn:k=>{let{x:A,y:M}=k;return{x:A,y:M}}},...p}=aa(t,a),b={x:o,y:s},y=await u.detectOverflow(a,p),S=Dn(ra(c)),C=nm(S);let R=b[C],E=b[S];if(m){const k=C==="y"?"top":"left",A=C==="y"?"bottom":"right",M=R+y[k],L=R-y[A];R=ff(M,R,L)}if(h){const k=S==="y"?"top":"left",A=S==="y"?"bottom":"right",M=E+y[k],L=E-y[A];E=ff(M,E,L)}const T=v.fn({...a,[C]:R,[S]:E});return{...T,data:{x:T.x-o,y:T.y-s,enabled:{[C]:m,[S]:h}}}}}},tk=function(t){return t===void 0&&(t={}),{options:t,fn(a){const{x:o,y:s,placement:c,rects:u,middlewareData:m}=a,{offset:h=0,mainAxis:v=!0,crossAxis:p=!0}=aa(t,a),b={x:o,y:s},y=Dn(c),S=nm(y);let C=b[S],R=b[y];const E=aa(h,a),T=typeof E=="number"?{mainAxis:E,crossAxis:0}:{mainAxis:0,crossAxis:0,...E};if(v){const M=S==="y"?"height":"width",L=u.reference[S]-u.floating[M]+T.mainAxis,H=u.reference[S]+u.reference[M]-T.mainAxis;C<L?C=L:C>H&&(C=H)}if(p){var k,A;const M=S==="y"?"width":"height",L=ax.has(ra(c)),H=u.reference[y]-u.floating[M]+(L&&((k=m.offset)==null?void 0:k[y])||0)+(L?0:T.crossAxis),I=u.reference[y]+u.reference[M]+(L?0:((A=m.offset)==null?void 0:A[y])||0)-(L?T.crossAxis:0);R<H?R=H:R>I&&(R=I)}return{[S]:C,[y]:R}}}},nk=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(a){var o,s;const{placement:c,rects:u,platform:m,elements:h}=a,{apply:v=()=>{},...p}=aa(t,a),b=await m.detectOverflow(a,p),y=ra(c),S=jo(c),C=Dn(c)==="y",{width:R,height:E}=u.floating;let T,k;y==="top"||y==="bottom"?(T=y,k=S===(await(m.isRTL==null?void 0:m.isRTL(h.floating))?"start":"end")?"left":"right"):(k=y,T=S==="end"?"top":"bottom");const A=E-b.top-b.bottom,M=R-b.left-b.right,L=Ba(E-b[T],A),H=Ba(R-b[k],M),I=!a.middlewareData.shift;let G=L,V=H;if((o=a.middlewareData.shift)!=null&&o.enabled.x&&(V=M),(s=a.middlewareData.shift)!=null&&s.enabled.y&&(G=A),I&&!S){const fe=Zt(b.left,0),ae=Zt(b.right,0),ie=Zt(b.top,0),ce=Zt(b.bottom,0);C?V=R-2*(fe!==0||ae!==0?fe+ae:Zt(b.left,b.right)):G=E-2*(ie!==0||ce!==0?ie+ce:Zt(b.top,b.bottom))}await v({...a,availableWidth:V,availableHeight:G});const oe=await m.getDimensions(h.floating);return R!==oe.width||E!==oe.height?{reset:{rects:!0}}:{}}}};function cc(){return typeof window<"u"}function _o(t){return rx(t)?(t.nodeName||"").toLowerCase():"#document"}function Wt(t){var a;return(t==null||(a=t.ownerDocument)==null?void 0:a.defaultView)||window}function zn(t){var a;return(a=(rx(t)?t.ownerDocument:t.document)||window.document)==null?void 0:a.documentElement}function rx(t){return cc()?t instanceof Node||t instanceof Wt(t).Node:!1}function wn(t){return cc()?t instanceof Element||t instanceof Wt(t).Element:!1}function la(t){return cc()?t instanceof HTMLElement||t instanceof Wt(t).HTMLElement:!1}function oy(t){return!cc()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof Wt(t).ShadowRoot}function Wl(t){const{overflow:a,overflowX:o,overflowY:s,display:c}=Sn(t);return/auto|scroll|overlay|hidden|clip/.test(a+s+o)&&c!=="inline"&&c!=="contents"}function ak(t){return/^(table|td|th)$/.test(_o(t))}function uc(t){try{if(t.matches(":popover-open"))return!0}catch{}try{return t.matches(":modal")}catch{return!1}}const rk=/transform|translate|scale|rotate|perspective|filter/,ok=/paint|layout|strict|content/,mr=t=>!!t&&t!=="none";let Vd;function om(t){const a=wn(t)?Sn(t):t;return mr(a.transform)||mr(a.translate)||mr(a.scale)||mr(a.rotate)||mr(a.perspective)||!lm()&&(mr(a.backdropFilter)||mr(a.filter))||rk.test(a.willChange||"")||ok.test(a.contain||"")}function lk(t){let a=Pa(t);for(;la(a)&&!No(a);){if(om(a))return a;if(uc(a))return null;a=Pa(a)}return null}function lm(){return Vd==null&&(Vd=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Vd}function No(t){return/^(html|body|#document)$/.test(_o(t))}function Sn(t){return Wt(t).getComputedStyle(t)}function dc(t){return wn(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Pa(t){if(_o(t)==="html")return t;const a=t.assignedSlot||t.parentNode||oy(t)&&t.host||zn(t);return oy(a)?a.host:a}function ox(t){const a=Pa(t);return No(a)?t.ownerDocument?t.ownerDocument.body:t.body:la(a)&&Wl(a)?a:ox(a)}function Il(t,a,o){var s;a===void 0&&(a=[]),o===void 0&&(o=!0);const c=ox(t),u=c===((s=t.ownerDocument)==null?void 0:s.body),m=Wt(c);if(u){const h=hf(m);return a.concat(m,m.visualViewport||[],Wl(c)?c:[],h&&o?Il(h):[])}else return a.concat(c,Il(c,[],o))}function hf(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function lx(t){const a=Sn(t);let o=parseFloat(a.width)||0,s=parseFloat(a.height)||0;const c=la(t),u=c?t.offsetWidth:o,m=c?t.offsetHeight:s,h=Gi(o)!==u||Gi(s)!==m;return h&&(o=u,s=m),{width:o,height:s,$:h}}function sm(t){return wn(t)?t:t.contextElement}function Eo(t){const a=sm(t);if(!la(a))return Mn(1);const o=a.getBoundingClientRect(),{width:s,height:c,$:u}=lx(a);let m=(u?Gi(o.width):o.width)/s,h=(u?Gi(o.height):o.height)/c;return(!m||!Number.isFinite(m))&&(m=1),(!h||!Number.isFinite(h))&&(h=1),{x:m,y:h}}const sk=Mn(0);function sx(t){const a=Wt(t);return!lm()||!a.visualViewport?sk:{x:a.visualViewport.offsetLeft,y:a.visualViewport.offsetTop}}function ik(t,a,o){return a===void 0&&(a=!1),!o||a&&o!==Wt(t)?!1:a}function br(t,a,o,s){a===void 0&&(a=!1),o===void 0&&(o=!1);const c=t.getBoundingClientRect(),u=sm(t);let m=Mn(1);a&&(s?wn(s)&&(m=Eo(s)):m=Eo(t));const h=ik(u,o,s)?sx(u):Mn(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=Wt(u),C=s&&wn(s)?Wt(s):s;let R=S,E=hf(R);for(;E&&s&&C!==R;){const T=Eo(E),k=E.getBoundingClientRect(),A=Sn(E),M=k.left+(E.clientLeft+parseFloat(A.paddingLeft))*T.x,L=k.top+(E.clientTop+parseFloat(A.paddingTop))*T.y;v*=T.x,p*=T.y,b*=T.x,y*=T.y,v+=M,p+=L,R=Wt(E),E=hf(R)}}return Xi({width:b,height:y,x:v,y:p})}function fc(t,a){const o=dc(t).scrollLeft;return a?a.left+o:br(zn(t)).left+o}function ix(t,a){const o=t.getBoundingClientRect(),s=o.left+a.scrollLeft-fc(t,o),c=o.top+a.scrollTop;return{x:s,y:c}}function ck(t){let{elements:a,rect:o,offsetParent:s,strategy:c}=t;const u=c==="fixed",m=zn(s),h=a?uc(a.floating):!1;if(s===m||h&&u)return o;let v={scrollLeft:0,scrollTop:0},p=Mn(1);const b=Mn(0),y=la(s);if((y||!y&&!u)&&((_o(s)!=="body"||Wl(m))&&(v=dc(s)),y)){const C=br(s);p=Eo(s),b.x=C.x+s.clientLeft,b.y=C.y+s.clientTop}const S=m&&!y&&!u?ix(m,v):Mn(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 uk(t){return Array.from(t.getClientRects())}function dk(t){const a=zn(t),o=dc(t),s=t.ownerDocument.body,c=Zt(a.scrollWidth,a.clientWidth,s.scrollWidth,s.clientWidth),u=Zt(a.scrollHeight,a.clientHeight,s.scrollHeight,s.clientHeight);let m=-o.scrollLeft+fc(t);const h=-o.scrollTop;return Sn(s).direction==="rtl"&&(m+=Zt(a.clientWidth,s.clientWidth)-c),{width:c,height:u,x:m,y:h}}const ly=25;function fk(t,a){const o=Wt(t),s=zn(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=lm();(!b||b&&a==="fixed")&&(h=c.offsetLeft,v=c.offsetTop)}const p=fc(s);if(p<=0){const b=s.ownerDocument,y=b.body,S=getComputedStyle(y),C=b.compatMode==="CSS1Compat"&&parseFloat(S.marginLeft)+parseFloat(S.marginRight)||0,R=Math.abs(s.clientWidth-y.clientWidth-C);R<=ly&&(u-=R)}else p<=ly&&(u+=p);return{width:u,height:m,x:h,y:v}}function mk(t,a){const o=br(t,!0,a==="fixed"),s=o.top+t.clientTop,c=o.left+t.clientLeft,u=la(t)?Eo(t):Mn(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,a,o){let s;if(a==="viewport")s=fk(t,o);else if(a==="document")s=dk(zn(t));else if(wn(a))s=mk(a,o);else{const c=sx(t);s={x:a.x-c.x,y:a.y-c.y,width:a.width,height:a.height}}return Xi(s)}function cx(t,a){const o=Pa(t);return o===a||!wn(o)||No(o)?!1:Sn(o).position==="fixed"||cx(o,a)}function hk(t,a){const o=a.get(t);if(o)return o;let s=Il(t,[],!1).filter(h=>wn(h)&&_o(h)!=="body"),c=null;const u=Sn(t).position==="fixed";let m=u?Pa(t):t;for(;wn(m)&&!No(m);){const h=Sn(m),v=om(m);!v&&h.position==="fixed"&&(c=null),(u?!v&&!c:!v&&h.position==="static"&&!!c&&(c.position==="absolute"||c.position==="fixed")||Wl(m)&&!v&&cx(t,m))?s=s.filter(b=>b!==m):c=h,m=Pa(m)}return a.set(t,s),s}function pk(t){let{element:a,boundary:o,rootBoundary:s,strategy:c}=t;const m=[...o==="clippingAncestors"?uc(a)?[]:hk(a,this._c):[].concat(o),s],h=sy(a,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 C=sy(a,m[S],c);v=Zt(C.top,v),p=Ba(C.right,p),b=Ba(C.bottom,b),y=Zt(C.left,y)}return{width:p-y,height:b-v,x:y,y:v}}function gk(t){const{width:a,height:o}=lx(t);return{width:a,height:o}}function vk(t,a,o){const s=la(a),c=zn(a),u=o==="fixed",m=br(t,!0,u,a);let h={scrollLeft:0,scrollTop:0};const v=Mn(0);function p(){v.x=fc(c)}if(s||!s&&!u)if((_o(a)!=="body"||Wl(c))&&(h=dc(a)),s){const C=br(a,!0,u,a);v.x=C.x+a.clientLeft,v.y=C.y+a.clientTop}else c&&p();u&&!s&&c&&p();const b=c&&!s&&!u?ix(c,h):Mn(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 Yd(t){return Sn(t).position==="static"}function iy(t,a){if(!la(t)||Sn(t).position==="fixed")return null;if(a)return a(t);let o=t.offsetParent;return zn(t)===o&&(o=o.ownerDocument.body),o}function ux(t,a){const o=Wt(t);if(uc(t))return o;if(!la(t)){let c=Pa(t);for(;c&&!No(c);){if(wn(c)&&!Yd(c))return c;c=Pa(c)}return o}let s=iy(t,a);for(;s&&ak(s)&&Yd(s);)s=iy(s,a);return s&&No(s)&&Yd(s)&&!om(s)?o:s||lk(t)||o}const yk=async function(t){const a=this.getOffsetParent||ux,o=this.getDimensions,s=await o(t.floating);return{reference:vk(t.reference,await a(t.floating),t.strategy),floating:{x:0,y:0,width:s.width,height:s.height}}};function bk(t){return Sn(t).direction==="rtl"}const xk={convertOffsetParentRelativeRectToViewportRelativeRect:ck,getDocumentElement:zn,getClippingRect:pk,getOffsetParent:ux,getElementRects:yk,getClientRects:uk,getDimensions:gk,getScale:Eo,isElement:wn,isRTL:bk};function dx(t,a){return t.x===a.x&&t.y===a.y&&t.width===a.width&&t.height===a.height}function wk(t,a){let o=null,s;const c=zn(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:C}=p;if(h||a(),!S||!C)return;const R=yi(y),E=yi(c.clientWidth-(b+S)),T=yi(c.clientHeight-(y+C)),k=yi(b),M={rootMargin:-R+"px "+-E+"px "+-T+"px "+-k+"px",threshold:Zt(0,Ba(1,v))||1};let L=!0;function H(I){const G=I[0].intersectionRatio;if(G!==v){if(!L)return m();G?m(!1,G):s=setTimeout(()=>{m(!1,1e-7)},1e3)}G===1&&!dx(p,t.getBoundingClientRect())&&m(),L=!1}try{o=new IntersectionObserver(H,{...M,root:c.ownerDocument})}catch{o=new IntersectionObserver(H,M)}o.observe(t)}return m(!0),u}function Sk(t,a,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=sm(t),b=c||u?[...p?Il(p):[],...a?Il(a):[]]:[];b.forEach(k=>{c&&k.addEventListener("scroll",o,{passive:!0}),u&&k.addEventListener("resize",o)});const y=p&&h?wk(p,o):null;let S=-1,C=null;m&&(C=new ResizeObserver(k=>{let[A]=k;A&&A.target===p&&C&&a&&(C.unobserve(a),cancelAnimationFrame(S),S=requestAnimationFrame(()=>{var M;(M=C)==null||M.observe(a)})),o()}),p&&!v&&C.observe(p),a&&C.observe(a));let R,E=v?br(t):null;v&&T();function T(){const k=br(t);E&&!dx(E,k)&&o(),E=k,R=requestAnimationFrame(T)}return o(),()=>{var k;b.forEach(A=>{c&&A.removeEventListener("scroll",o),u&&A.removeEventListener("resize",o)}),y?.(),(k=C)==null||k.disconnect(),C=null,v&&cancelAnimationFrame(R)}}const Ek=J5,Nk=ek,Tk=Z5,Ck=nk,Rk=W5,cy=K5,Ak=tk,kk=(t,a,o)=>{const s=new Map,c={platform:xk,...o},u={...c.platform,_c:s};return Q5(t,a,{...c,platform:u})};var jk=typeof document<"u",_k=function(){},Ci=jk?g.useLayoutEffect:_k;function Qi(t,a){if(t===a)return!0;if(typeof t!=typeof a)return!1;if(typeof t=="function"&&t.toString()===a.toString())return!0;let o,s,c;if(t&&a&&typeof t=="object"){if(Array.isArray(t)){if(o=t.length,o!==a.length)return!1;for(s=o;s--!==0;)if(!Qi(t[s],a[s]))return!1;return!0}if(c=Object.keys(t),o=c.length,o!==Object.keys(a).length)return!1;for(s=o;s--!==0;)if(!{}.hasOwnProperty.call(a,c[s]))return!1;for(s=o;s--!==0;){const u=c[s];if(!(u==="_owner"&&t.$$typeof)&&!Qi(t[u],a[u]))return!1}return!0}return t!==t&&a!==a}function fx(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function uy(t,a){const o=fx(t);return Math.round(a*o)/o}function Gd(t){const a=g.useRef(t);return Ci(()=>{a.current=t}),a}function Ok(t){t===void 0&&(t={});const{placement:a="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:a,middlewareData:{},isPositioned:!1}),[S,C]=g.useState(s);Qi(S,s)||C(s);const[R,E]=g.useState(null),[T,k]=g.useState(null),A=g.useCallback(O=>{O!==I.current&&(I.current=O,E(O))},[]),M=g.useCallback(O=>{O!==G.current&&(G.current=O,k(O))},[]),L=u||R,H=m||T,I=g.useRef(null),G=g.useRef(null),V=g.useRef(b),oe=v!=null,fe=Gd(v),ae=Gd(c),ie=Gd(p),ce=g.useCallback(()=>{if(!I.current||!G.current)return;const O={placement:a,strategy:o,middleware:S};ae.current&&(O.platform=ae.current),kk(I.current,G.current,O).then(W=>{const N={...W,isPositioned:ie.current!==!1};ue.current&&!Qi(V.current,N)&&(V.current=N,Kl.flushSync(()=>{y(N)}))})},[S,a,o,ae,ie]);Ci(()=>{p===!1&&V.current.isPositioned&&(V.current.isPositioned=!1,y(O=>({...O,isPositioned:!1})))},[p]);const ue=g.useRef(!1);Ci(()=>(ue.current=!0,()=>{ue.current=!1}),[]),Ci(()=>{if(L&&(I.current=L),H&&(G.current=H),L&&H){if(fe.current)return fe.current(L,H,ce);ce()}},[L,H,ce,fe,oe]);const re=g.useMemo(()=>({reference:I,floating:G,setReference:A,setFloating:M}),[A,M]),_=g.useMemo(()=>({reference:L,floating:H}),[L,H]),$=g.useMemo(()=>{const O={position:o,left:0,top:0};if(!_.floating)return O;const W=uy(_.floating,b.x),N=uy(_.floating,b.y);return h?{...O,transform:"translate("+W+"px, "+N+"px)",...fx(_.floating)>=1.5&&{willChange:"transform"}}:{position:o,left:W,top:N}},[o,h,_.floating,b.x,b.y]);return g.useMemo(()=>({...b,update:ce,refs:re,elements:_,floatingStyles:$}),[b,ce,re,_,$])}const Dk=t=>{function a(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&&a(s)?s.current!=null?cy({element:s.current,padding:c}).fn(o):{}:s?cy({element:s,padding:c}).fn(o):{}}}},Mk=(t,a)=>{const o=Ek(t);return{name:o.name,fn:o.fn,options:[t,a]}},zk=(t,a)=>{const o=Nk(t);return{name:o.name,fn:o.fn,options:[t,a]}},Lk=(t,a)=>({fn:Ak(t).fn,options:[t,a]}),Uk=(t,a)=>{const o=Tk(t);return{name:o.name,fn:o.fn,options:[t,a]}},Hk=(t,a)=>{const o=Ck(t);return{name:o.name,fn:o.fn,options:[t,a]}},Bk=(t,a)=>{const o=Rk(t);return{name:o.name,fn:o.fn,options:[t,a]}},Pk=(t,a)=>{const o=Dk(t);return{name:o.name,fn:o.fn,options:[t,a]}};var $k="Arrow",mx=g.forwardRef((t,a)=>{const{children:o,width:s=10,height:c=5,...u}=t;return f.jsx($e.svg,{...u,ref:a,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"})})});mx.displayName=$k;var qk=mx,im="Popper",[hx,px]=ko(im),[Vk,gx]=hx(im),vx=t=>{const{__scopePopper:a,children:o}=t,[s,c]=g.useState(null);return f.jsx(Vk,{scope:a,anchor:s,onAnchorChange:c,children:o})};vx.displayName=im;var yx="PopperAnchor",bx=g.forwardRef((t,a)=>{const{__scopePopper:o,virtualRef:s,...c}=t,u=gx(yx,o),m=g.useRef(null),h=Fe(a,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($e.div,{...c,ref:h})});bx.displayName=yx;var cm="PopperContent",[Yk,Gk]=hx(cm),xx=g.forwardRef((t,a)=>{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:C="optimized",onPlaced:R,...E}=t,T=gx(cm,o),[k,A]=g.useState(null),M=Fe(a,se=>A(se)),[L,H]=g.useState(null),I=Xb(L),G=I?.width??0,V=I?.height??0,oe=s+(u!=="center"?"-"+u:""),fe=typeof b=="number"?b:{top:0,right:0,bottom:0,left:0,...b},ae=Array.isArray(p)?p:[p],ie=ae.length>0,ce={padding:fe,boundary:ae.filter(Xk),altBoundary:ie},{refs:ue,floatingStyles:re,placement:_,isPositioned:$,middlewareData:O}=Ok({strategy:"fixed",placement:oe,whileElementsMounted:(...se)=>Sk(...se,{animationFrame:C==="always"}),elements:{reference:T.anchor},middleware:[Mk({mainAxis:c+V,alignmentAxis:m}),v&&zk({mainAxis:!0,crossAxis:!1,limiter:y==="partial"?Lk():void 0,...ce}),v&&Uk({...ce}),Hk({...ce,apply:({elements:se,rects:de,availableWidth:xe,availableHeight:Ae})=>{const{width:Ne,height:ke}=de.reference,Je=se.floating.style;Je.setProperty("--radix-popper-available-width",`${xe}px`),Je.setProperty("--radix-popper-available-height",`${Ae}px`),Je.setProperty("--radix-popper-anchor-width",`${Ne}px`),Je.setProperty("--radix-popper-anchor-height",`${ke}px`)}}),L&&Pk({element:L,padding:h}),Qk({arrowWidth:G,arrowHeight:V}),S&&Bk({strategy:"referenceHidden",...ce})]}),[W,N]=Ex(_),Y=vr(R);Ot(()=>{$&&Y?.()},[$,Y]);const ne=O.arrow?.x,X=O.arrow?.y,F=O.arrow?.centerOffset!==0,[ee,te]=g.useState();return Ot(()=>{k&&te(window.getComputedStyle(k).zIndex)},[k]),f.jsx("div",{ref:ue.setFloating,"data-radix-popper-content-wrapper":"",style:{...re,transform:$?re.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ee,"--radix-popper-transform-origin":[O.transformOrigin?.x,O.transformOrigin?.y].join(" "),...O.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:t.dir,children:f.jsx(Yk,{scope:o,placedSide:W,onArrowChange:H,arrowX:ne,arrowY:X,shouldHideArrow:F,children:f.jsx($e.div,{"data-side":W,"data-align":N,...E,ref:M,style:{...E.style,animation:$?void 0:"none"}})})})});xx.displayName=cm;var wx="PopperArrow",Ik={top:"bottom",right:"left",bottom:"top",left:"right"},Sx=g.forwardRef(function(a,o){const{__scopePopper:s,...c}=a,u=Gk(wx,s),m=Ik[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(qk,{...c,ref:o,style:{...c.style,display:"block"}})})});Sx.displayName=wx;function Xk(t){return t!==null}var Qk=t=>({name:"transformOrigin",options:t,fn(a){const{placement:o,rects:s,middlewareData:c}=a,m=c.arrow?.centerOffset!==0,h=m?0:t.arrowWidth,v=m?0:t.arrowHeight,[p,b]=Ex(o),y={start:"0%",center:"50%",end:"100%"}[b],S=(c.arrow?.x??0)+h/2,C=(c.arrow?.y??0)+v/2;let R="",E="";return p==="bottom"?(R=m?y:`${S}px`,E=`${-v}px`):p==="top"?(R=m?y:`${S}px`,E=`${s.floating.height+v}px`):p==="right"?(R=`${-v}px`,E=m?y:`${C}px`):p==="left"&&(R=`${s.floating.width+v}px`,E=m?y:`${C}px`),{data:{x:R,y:E}}}});function Ex(t){const[a,o="center"]=t.split("-");return[a,o]}var Kk=vx,Zk=bx,Wk=xx,Fk=Sx,Nx=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"}),Jk="VisuallyHidden",ej=g.forwardRef((t,a)=>f.jsx($e.span,{...t,ref:a,style:{...Nx,...t.style}}));ej.displayName=Jk;var tj=[" ","Enter","ArrowUp","ArrowDown"],nj=[" ","Enter"],xr="Select",[mc,hc,aj]=M5(xr),[Oo]=ko(xr,[aj,px]),pc=px(),[rj,Va]=Oo(xr),[oj,lj]=Oo(xr),Tx=t=>{const{__scopeSelect:a,children:o,open:s,defaultOpen:c,onOpenChange:u,value:m,defaultValue:h,onValueChange:v,dir:p,name:b,autoComplete:y,disabled:S,required:C,form:R}=t,E=pc(a),[T,k]=g.useState(null),[A,M]=g.useState(null),[L,H]=g.useState(!1),I=L5(p),[G,V]=zi({prop:s,defaultProp:c??!1,onChange:u,caller:xr}),[oe,fe]=zi({prop:m,defaultProp:h,onChange:v,caller:xr}),ae=g.useRef(null),ie=T?R||!!T.closest("form"):!0,[ce,ue]=g.useState(new Set),re=Array.from(ce).map(_=>_.props.value).join(";");return f.jsx(Kk,{...E,children:f.jsxs(rj,{required:C,scope:a,trigger:T,onTriggerChange:k,valueNode:A,onValueNodeChange:M,valueNodeHasChildren:L,onValueNodeHasChildrenChange:H,contentId:xo(),value:oe,onValueChange:fe,open:G,onOpenChange:V,dir:I,triggerPointerDownPosRef:ae,disabled:S,children:[f.jsx(mc.Provider,{scope:a,children:f.jsx(oj,{scope:t.__scopeSelect,onNativeOptionAdd:g.useCallback(_=>{ue($=>new Set($).add(_))},[]),onNativeOptionRemove:g.useCallback(_=>{ue($=>{const O=new Set($);return O.delete(_),O})},[]),children:o})}),ie?f.jsxs(Zx,{"aria-hidden":!0,required:C,tabIndex:-1,name:b,autoComplete:y,value:oe,onChange:_=>fe(_.target.value),disabled:S,form:R,children:[oe===void 0?f.jsx("option",{value:""}):null,Array.from(ce)]},re):null]})})};Tx.displayName=xr;var Cx="SelectTrigger",Rx=g.forwardRef((t,a)=>{const{__scopeSelect:o,disabled:s=!1,...c}=t,u=pc(o),m=Va(Cx,o),h=m.disabled||s,v=Fe(a,m.onTriggerChange),p=hc(o),b=g.useRef("touch"),[y,S,C]=Fx(E=>{const T=p().filter(M=>!M.disabled),k=T.find(M=>M.value===m.value),A=Jx(T,E,k);A!==void 0&&m.onValueChange(A.value)}),R=E=>{h||(m.onOpenChange(!0),C()),E&&(m.triggerPointerDownPosRef.current={x:Math.round(E.pageX),y:Math.round(E.pageY)})};return f.jsx(Zk,{asChild:!0,...u,children:f.jsx($e.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":Wx(m.value)?"":void 0,...c,ref:v,onClick:Ge(c.onClick,E=>{E.currentTarget.focus(),b.current!=="mouse"&&R(E)}),onPointerDown:Ge(c.onPointerDown,E=>{b.current=E.pointerType;const T=E.target;T.hasPointerCapture(E.pointerId)&&T.releasePointerCapture(E.pointerId),E.button===0&&E.ctrlKey===!1&&E.pointerType==="mouse"&&(R(E),E.preventDefault())}),onKeyDown:Ge(c.onKeyDown,E=>{const T=y.current!=="";!(E.ctrlKey||E.altKey||E.metaKey)&&E.key.length===1&&S(E.key),!(T&&E.key===" ")&&tj.includes(E.key)&&(R(),E.preventDefault())})})})});Rx.displayName=Cx;var Ax="SelectValue",kx=g.forwardRef((t,a)=>{const{__scopeSelect:o,className:s,style:c,children:u,placeholder:m="",...h}=t,v=Va(Ax,o),{onValueNodeHasChildrenChange:p}=v,b=u!==void 0,y=Fe(a,v.onValueNodeChange);return Ot(()=>{p(b)},[p,b]),f.jsx($e.span,{...h,ref:y,style:{pointerEvents:"none"},children:Wx(v.value)?f.jsx(f.Fragment,{children:m}):u})});kx.displayName=Ax;var sj="SelectIcon",jx=g.forwardRef((t,a)=>{const{__scopeSelect:o,children:s,...c}=t;return f.jsx($e.span,{"aria-hidden":!0,...c,ref:a,children:s||"▼"})});jx.displayName=sj;var ij="SelectPortal",_x=t=>f.jsx(Gf,{asChild:!0,...t});_x.displayName=ij;var wr="SelectContent",Ox=g.forwardRef((t,a)=>{const o=Va(wr,t.__scopeSelect),[s,c]=g.useState();if(Ot(()=>{c(new DocumentFragment)},[]),!o.open){const u=s;return u?Kl.createPortal(f.jsx(Dx,{scope:t.__scopeSelect,children:f.jsx(mc.Slot,{scope:t.__scopeSelect,children:f.jsx("div",{children:t.children})})}),u):null}return f.jsx(Mx,{...t,ref:a})});Ox.displayName=wr;var yn=10,[Dx,Ya]=Oo(wr),cj="SelectContentImpl",uj=Gl("SelectContent.RemoveScroll"),Mx=g.forwardRef((t,a)=>{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:C,sticky:R,hideWhenDetached:E,avoidCollisions:T,...k}=t,A=Va(wr,o),[M,L]=g.useState(null),[H,I]=g.useState(null),G=Fe(a,se=>L(se)),[V,oe]=g.useState(null),[fe,ae]=g.useState(null),ie=hc(o),[ce,ue]=g.useState(!1),re=g.useRef(!1);g.useEffect(()=>{if(M)return X0(M)},[M]),H0();const _=g.useCallback(se=>{const[de,...xe]=ie().map(ke=>ke.ref.current),[Ae]=xe.slice(-1),Ne=document.activeElement;for(const ke of se)if(ke===Ne||(ke?.scrollIntoView({block:"nearest"}),ke===de&&H&&(H.scrollTop=0),ke===Ae&&H&&(H.scrollTop=H.scrollHeight),ke?.focus(),document.activeElement!==Ne))return},[ie,H]),$=g.useCallback(()=>_([V,M]),[_,V,M]);g.useEffect(()=>{ce&&$()},[ce,$]);const{onOpenChange:O,triggerPointerDownPosRef:W}=A;g.useEffect(()=>{if(M){let se={x:0,y:0};const de=Ae=>{se={x:Math.abs(Math.round(Ae.pageX)-(W.current?.x??0)),y:Math.abs(Math.round(Ae.pageY)-(W.current?.y??0))}},xe=Ae=>{se.x<=10&&se.y<=10?Ae.preventDefault():M.contains(Ae.target)||O(!1),document.removeEventListener("pointermove",de),W.current=null};return W.current!==null&&(document.addEventListener("pointermove",de),document.addEventListener("pointerup",xe,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",de),document.removeEventListener("pointerup",xe,{capture:!0})}}},[M,O,W]),g.useEffect(()=>{const se=()=>O(!1);return window.addEventListener("blur",se),window.addEventListener("resize",se),()=>{window.removeEventListener("blur",se),window.removeEventListener("resize",se)}},[O]);const[N,Y]=Fx(se=>{const de=ie().filter(Ne=>!Ne.disabled),xe=de.find(Ne=>Ne.ref.current===document.activeElement),Ae=Jx(de,se,xe);Ae&&setTimeout(()=>Ae.ref.current.focus())}),ne=g.useCallback((se,de,xe)=>{const Ae=!re.current&&!xe;(A.value!==void 0&&A.value===de||Ae)&&(oe(se),Ae&&(re.current=!0))},[A.value]),X=g.useCallback(()=>M?.focus(),[M]),F=g.useCallback((se,de,xe)=>{const Ae=!re.current&&!xe;(A.value!==void 0&&A.value===de||Ae)&&ae(se)},[A.value]),ee=s==="popper"?pf:zx,te=ee===pf?{side:h,sideOffset:v,align:p,alignOffset:b,arrowPadding:y,collisionBoundary:S,collisionPadding:C,sticky:R,hideWhenDetached:E,avoidCollisions:T}:{};return f.jsx(Dx,{scope:o,content:M,viewport:H,onViewportChange:I,itemRefCallback:ne,selectedItem:V,onItemLeave:X,itemTextRefCallback:F,focusSelectedItem:$,selectedItemText:fe,position:s,isPositioned:ce,searchRef:N,children:f.jsx(If,{as:uj,allowPinchZoom:!0,children:f.jsx(Yf,{asChild:!0,trapped:A.open,onMountAutoFocus:se=>{se.preventDefault()},onUnmountAutoFocus:Ge(c,se=>{A.trigger?.focus({preventScroll:!0}),se.preventDefault()}),children:f.jsx(Vf,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:u,onPointerDownOutside:m,onFocusOutside:se=>se.preventDefault(),onDismiss:()=>A.onOpenChange(!1),children:f.jsx(ee,{role:"listbox",id:A.contentId,"data-state":A.open?"open":"closed",dir:A.dir,onContextMenu:se=>se.preventDefault(),...k,...te,onPlaced:()=>ue(!0),ref:G,style:{display:"flex",flexDirection:"column",outline:"none",...k.style},onKeyDown:Ge(k.onKeyDown,se=>{const de=se.ctrlKey||se.altKey||se.metaKey;if(se.key==="Tab"&&se.preventDefault(),!de&&se.key.length===1&&Y(se.key),["ArrowUp","ArrowDown","Home","End"].includes(se.key)){let Ae=ie().filter(Ne=>!Ne.disabled).map(Ne=>Ne.ref.current);if(["ArrowUp","End"].includes(se.key)&&(Ae=Ae.slice().reverse()),["ArrowUp","ArrowDown"].includes(se.key)){const Ne=se.target,ke=Ae.indexOf(Ne);Ae=Ae.slice(ke+1)}setTimeout(()=>_(Ae)),se.preventDefault()}})})})})})})});Mx.displayName=cj;var dj="SelectItemAlignedPosition",zx=g.forwardRef((t,a)=>{const{__scopeSelect:o,onPlaced:s,...c}=t,u=Va(wr,o),m=Ya(wr,o),[h,v]=g.useState(null),[p,b]=g.useState(null),y=Fe(a,G=>b(G)),S=hc(o),C=g.useRef(!1),R=g.useRef(!0),{viewport:E,selectedItem:T,selectedItemText:k,focusSelectedItem:A}=m,M=g.useCallback(()=>{if(u.trigger&&u.valueNode&&h&&p&&E&&T&&k){const G=u.trigger.getBoundingClientRect(),V=p.getBoundingClientRect(),oe=u.valueNode.getBoundingClientRect(),fe=k.getBoundingClientRect();if(u.dir!=="rtl"){const Ne=fe.left-V.left,ke=oe.left-Ne,Je=G.left-ke,at=G.width+Je,fn=Math.max(at,V.width),mn=window.innerWidth-yn,lt=Jv(ke,[yn,Math.max(yn,mn-fn)]);h.style.minWidth=at+"px",h.style.left=lt+"px"}else{const Ne=V.right-fe.right,ke=window.innerWidth-oe.right-Ne,Je=window.innerWidth-G.right-ke,at=G.width+Je,fn=Math.max(at,V.width),mn=window.innerWidth-yn,lt=Jv(ke,[yn,Math.max(yn,mn-fn)]);h.style.minWidth=at+"px",h.style.right=lt+"px"}const ae=S(),ie=window.innerHeight-yn*2,ce=E.scrollHeight,ue=window.getComputedStyle(p),re=parseInt(ue.borderTopWidth,10),_=parseInt(ue.paddingTop,10),$=parseInt(ue.borderBottomWidth,10),O=parseInt(ue.paddingBottom,10),W=re+_+ce+O+$,N=Math.min(T.offsetHeight*5,W),Y=window.getComputedStyle(E),ne=parseInt(Y.paddingTop,10),X=parseInt(Y.paddingBottom,10),F=G.top+G.height/2-yn,ee=ie-F,te=T.offsetHeight/2,se=T.offsetTop+te,de=re+_+se,xe=W-de;if(de<=F){const Ne=ae.length>0&&T===ae[ae.length-1].ref.current;h.style.bottom="0px";const ke=p.clientHeight-E.offsetTop-E.offsetHeight,Je=Math.max(ee,te+(Ne?X:0)+ke+$),at=de+Je;h.style.height=at+"px"}else{const Ne=ae.length>0&&T===ae[0].ref.current;h.style.top="0px";const Je=Math.max(F,re+E.offsetTop+(Ne?ne:0)+te)+xe;h.style.height=Je+"px",E.scrollTop=de-F+E.offsetTop}h.style.margin=`${yn}px 0`,h.style.minHeight=N+"px",h.style.maxHeight=ie+"px",s?.(),requestAnimationFrame(()=>C.current=!0)}},[S,u.trigger,u.valueNode,h,p,E,T,k,u.dir,s]);Ot(()=>M(),[M]);const[L,H]=g.useState();Ot(()=>{p&&H(window.getComputedStyle(p).zIndex)},[p]);const I=g.useCallback(G=>{G&&R.current===!0&&(M(),A?.(),R.current=!1)},[M,A]);return f.jsx(mj,{scope:o,contentWrapper:h,shouldExpandOnScrollRef:C,onScrollButtonChange:I,children:f.jsx("div",{ref:v,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:L},children:f.jsx($e.div,{...c,ref:y,style:{boxSizing:"border-box",maxHeight:"100%",...c.style}})})})});zx.displayName=dj;var fj="SelectPopperPosition",pf=g.forwardRef((t,a)=>{const{__scopeSelect:o,align:s="start",collisionPadding:c=yn,...u}=t,m=pc(o);return f.jsx(Wk,{...m,...u,ref:a,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)"}})});pf.displayName=fj;var[mj,um]=Oo(wr,{}),gf="SelectViewport",Lx=g.forwardRef((t,a)=>{const{__scopeSelect:o,nonce:s,...c}=t,u=Ya(gf,o),m=um(gf,o),h=Fe(a,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(mc.Slot,{scope:o,children:f.jsx($e.div,{"data-radix-select-viewport":"",role:"presentation",...c,ref:h,style:{position:"relative",flex:1,overflow:"hidden auto",...c.style},onScroll:Ge(c.onScroll,p=>{const b=p.currentTarget,{contentWrapper:y,shouldExpandOnScrollRef:S}=m;if(S?.current&&y){const C=Math.abs(v.current-b.scrollTop);if(C>0){const R=window.innerHeight-yn*2,E=parseFloat(y.style.minHeight),T=parseFloat(y.style.height),k=Math.max(E,T);if(k<R){const A=k+C,M=Math.min(R,A),L=A-M;y.style.height=M+"px",y.style.bottom==="0px"&&(b.scrollTop=L>0?L:0,y.style.justifyContent="flex-end")}}}v.current=b.scrollTop})})})]})});Lx.displayName=gf;var Ux="SelectGroup",[hj,pj]=Oo(Ux),Hx=g.forwardRef((t,a)=>{const{__scopeSelect:o,...s}=t,c=xo();return f.jsx(hj,{scope:o,id:c,children:f.jsx($e.div,{role:"group","aria-labelledby":c,...s,ref:a})})});Hx.displayName=Ux;var Bx="SelectLabel",Px=g.forwardRef((t,a)=>{const{__scopeSelect:o,...s}=t,c=pj(Bx,o);return f.jsx($e.div,{id:c.id,...s,ref:a})});Px.displayName=Bx;var Ki="SelectItem",[gj,$x]=Oo(Ki),qx=g.forwardRef((t,a)=>{const{__scopeSelect:o,value:s,disabled:c=!1,textValue:u,...m}=t,h=Va(Ki,o),v=Ya(Ki,o),p=h.value===s,[b,y]=g.useState(u??""),[S,C]=g.useState(!1),R=Fe(a,A=>v.itemRefCallback?.(A,s,c)),E=xo(),T=g.useRef("touch"),k=()=>{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(gj,{scope:o,value:s,disabled:c,textId:E,isSelected:p,onItemTextChange:g.useCallback(A=>{y(M=>M||(A?.textContent??"").trim())},[]),children:f.jsx(mc.ItemSlot,{scope:o,value:s,disabled:c,textValue:b,children:f.jsx($e.div,{role:"option","aria-labelledby":E,"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:R,onFocus:Ge(m.onFocus,()=>C(!0)),onBlur:Ge(m.onBlur,()=>C(!1)),onClick:Ge(m.onClick,()=>{T.current!=="mouse"&&k()}),onPointerUp:Ge(m.onPointerUp,()=>{T.current==="mouse"&&k()}),onPointerDown:Ge(m.onPointerDown,A=>{T.current=A.pointerType}),onPointerMove:Ge(m.onPointerMove,A=>{T.current=A.pointerType,c?v.onItemLeave?.():T.current==="mouse"&&A.currentTarget.focus({preventScroll:!0})}),onPointerLeave:Ge(m.onPointerLeave,A=>{A.currentTarget===document.activeElement&&v.onItemLeave?.()}),onKeyDown:Ge(m.onKeyDown,A=>{v.searchRef?.current!==""&&A.key===" "||(nj.includes(A.key)&&k(),A.key===" "&&A.preventDefault())})})})})});qx.displayName=Ki;var zl="SelectItemText",Vx=g.forwardRef((t,a)=>{const{__scopeSelect:o,className:s,style:c,...u}=t,m=Va(zl,o),h=Ya(zl,o),v=$x(zl,o),p=lj(zl,o),[b,y]=g.useState(null),S=Fe(a,k=>y(k),v.onItemTextChange,k=>h.itemTextRefCallback?.(k,v.value,v.disabled)),C=b?.textContent,R=g.useMemo(()=>f.jsx("option",{value:v.value,disabled:v.disabled,children:C},v.value),[v.disabled,v.value,C]),{onNativeOptionAdd:E,onNativeOptionRemove:T}=p;return Ot(()=>(E(R),()=>T(R)),[E,T,R]),f.jsxs(f.Fragment,{children:[f.jsx($e.span,{id:v.textId,...u,ref:S}),v.isSelected&&m.valueNode&&!m.valueNodeHasChildren?Kl.createPortal(u.children,m.valueNode):null]})});Vx.displayName=zl;var Yx="SelectItemIndicator",Gx=g.forwardRef((t,a)=>{const{__scopeSelect:o,...s}=t;return $x(Yx,o).isSelected?f.jsx($e.span,{"aria-hidden":!0,...s,ref:a}):null});Gx.displayName=Yx;var vf="SelectScrollUpButton",Ix=g.forwardRef((t,a)=>{const o=Ya(vf,t.__scopeSelect),s=um(vf,t.__scopeSelect),[c,u]=g.useState(!1),m=Fe(a,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(Qx,{...t,ref:m,onAutoScroll:()=>{const{viewport:h,selectedItem:v}=o;h&&v&&(h.scrollTop=h.scrollTop-v.offsetHeight)}}):null});Ix.displayName=vf;var yf="SelectScrollDownButton",Xx=g.forwardRef((t,a)=>{const o=Ya(yf,t.__scopeSelect),s=um(yf,t.__scopeSelect),[c,u]=g.useState(!1),m=Fe(a,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(Qx,{...t,ref:m,onAutoScroll:()=>{const{viewport:h,selectedItem:v}=o;h&&v&&(h.scrollTop=h.scrollTop+v.offsetHeight)}}):null});Xx.displayName=yf;var Qx=g.forwardRef((t,a)=>{const{__scopeSelect:o,onAutoScroll:s,...c}=t,u=Ya("SelectScrollButton",o),m=g.useRef(null),h=hc(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($e.div,{"aria-hidden":!0,...c,ref:a,style:{flexShrink:0,...c.style},onPointerDown:Ge(c.onPointerDown,()=>{m.current===null&&(m.current=window.setInterval(s,50))}),onPointerMove:Ge(c.onPointerMove,()=>{u.onItemLeave?.(),m.current===null&&(m.current=window.setInterval(s,50))}),onPointerLeave:Ge(c.onPointerLeave,()=>{v()})})}),vj="SelectSeparator",Kx=g.forwardRef((t,a)=>{const{__scopeSelect:o,...s}=t;return f.jsx($e.div,{"aria-hidden":!0,...s,ref:a})});Kx.displayName=vj;var bf="SelectArrow",yj=g.forwardRef((t,a)=>{const{__scopeSelect:o,...s}=t,c=pc(o),u=Va(bf,o),m=Ya(bf,o);return u.open&&m.position==="popper"?f.jsx(Fk,{...c,...s,ref:a}):null});yj.displayName=bf;var bj="SelectBubbleInput",Zx=g.forwardRef(({__scopeSelect:t,value:a,...o},s)=>{const c=g.useRef(null),u=Fe(s,c),m=Ib(a);return g.useEffect(()=>{const h=c.current;if(!h)return;const v=window.HTMLSelectElement.prototype,b=Object.getOwnPropertyDescriptor(v,"value").set;if(m!==a&&b){const y=new Event("change",{bubbles:!0});b.call(h,a),h.dispatchEvent(y)}},[m,a]),f.jsx($e.select,{...o,style:{...Nx,...o.style},ref:u,defaultValue:a})});Zx.displayName=bj;function Wx(t){return t===""||t===void 0}function Fx(t){const a=vr(t),o=g.useRef(""),s=g.useRef(0),c=g.useCallback(m=>{const h=o.current+m;a(h),(function v(p){o.current=p,window.clearTimeout(s.current),p!==""&&(s.current=window.setTimeout(()=>v(""),1e3))})(h)},[a]),u=g.useCallback(()=>{o.current="",window.clearTimeout(s.current)},[]);return g.useEffect(()=>()=>window.clearTimeout(s.current),[]),[o,c,u]}function Jx(t,a,o){const c=a.length>1&&Array.from(a).every(p=>p===a[0])?a[0]:a,u=o?t.indexOf(o):-1;let m=xj(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 xj(t,a){return t.map((o,s)=>t[(a+s)%t.length])}var wj=Tx,e1=Rx,Sj=kx,Ej=jx,Nj=_x,t1=Ox,Tj=Lx,Cj=Hx,n1=Px,a1=qx,Rj=Vx,Aj=Gx,r1=Ix,o1=Xx,l1=Kx;const dy=wj,uD=Cj,fy=Sj,xf=g.forwardRef(({className:t,children:a,...o},s)=>f.jsxs(e1,{ref:s,className:J("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:[a,f.jsx(Ej,{asChild:!0,children:f.jsx(gr,{className:"h-4 w-4 opacity-50"})})]}));xf.displayName=e1.displayName;const s1=g.forwardRef(({className:t,...a},o)=>f.jsx(r1,{ref:o,className:J("flex cursor-default items-center justify-center py-1",t),...a,children:f.jsx(AN,{className:"h-4 w-4"})}));s1.displayName=r1.displayName;const i1=g.forwardRef(({className:t,...a},o)=>f.jsx(o1,{ref:o,className:J("flex cursor-default items-center justify-center py-1",t),...a,children:f.jsx(gr,{className:"h-4 w-4"})}));i1.displayName=o1.displayName;const wf=g.forwardRef(({className:t,children:a,position:o="popper",viewportClassName:s,...c},u)=>f.jsx(Nj,{children:f.jsxs(t1,{ref:u,className:J("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(s1,{}),f.jsx(Tj,{className:J("p-1",o==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]",s),children:a}),f.jsx(i1,{})]})}));wf.displayName=t1.displayName;const kj=g.forwardRef(({className:t,...a},o)=>f.jsx(n1,{ref:o,className:J("py-1 pl-6 pr-2 text-[10px] font-semibold",t),...a}));kj.displayName=n1.displayName;const La=g.forwardRef(({className:t,children:a,...o},s)=>f.jsxs(a1,{ref:s,className:J("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(Aj,{children:f.jsx(_i,{className:"h-3.5 w-3.5"})})}),f.jsx(Rj,{children:a})]}));La.displayName=a1.displayName;const jj=g.forwardRef(({className:t,...a},o)=>f.jsx(l1,{ref:o,className:J("-mx-1 my-1 h-px bg-muted",t),...a}));jj.displayName=l1.displayName;const my=["queued","running"];function _j(t){return t.map(a=>`${a.id}:${a.name}`).join("\0")}function Oj(t){return t==="claude"||t==="codex"||t==="copilot"}function c1(t){if(t.kind!=="agent.upgrade")return null;const a=t.payload?.agent;return Oj(a)?`${t.nodeId}:${a}`:null}function Dj(t){return t.status==="succeeded"||t.status==="failed"}async function u1(t,a={}){const o=a.getOperation??n0,s=a.pollIntervalMs??2e3,c=a.timeoutMs??24e4,u=Date.now()+c;let m=t;for(;!Dj(m)&&Date.now()<u;)await zj(s),m=await o(t.id);return m}async function Mj(t,a=a0){const o=new Set(t),s=await Promise.all(my.map(u=>a({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 zj(t){return new Promise(a=>setTimeout(a,t))}const Lj=1500,Uj=1e3,Hj=9e4;async function d1(t={}){const a=t.fetchHealth??Bj,o=t.initialDelayMs??Lj,s=t.pollIntervalMs??Uj,c=t.previousPid,u=t.reload??(()=>window.location.reload()),m=t.sleep??$j,h=t.timeoutMs??Hj,v=Date.now()+h;let p=!1;for(o>0&&await m(o);Date.now()<=v;){const b=Pj(await a());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 Bj(){try{const t=await fetch("/api/system/health",{cache:"no-store"}),a=await t.json().catch(()=>null),o=a&&typeof a=="object"&&typeof a.pid=="number"?a.pid:void 0;return{ok:t.ok,pid:o}}catch{return!1}}function Pj(t){return typeof t=="boolean"?{ok:t}:t}function $j(t){return new Promise(a=>window.setTimeout(a,t))}function qj(t,a=!0){return a?t?.restartMode==="development"?"Restart dev runtime":t?.updateAvailable?"Restart to update":"Restart":t?.updateAvailable?"Restart follower to update":"Restart follower"}const hy="h-6 rounded-sm border-0 bg-muted/55 px-2 text-[10px] text-muted-foreground shadow-none hover:bg-muted/75 hover:text-foreground";function Vj({checkedLabel:t,disableAuthDefault:a,endpoint:o,isLiveLocalNode:s,nodeId:c,nodeName:u,onRefresh:m,pid:h,transportType:v,update:p,workDir:b}){const y=qj(p,s),[S,C]=g.useState(null),[R,E]=g.useState(()=>py({disableAuthDefault:a,endpoint:o,nodeName:u,transportType:v,workDir:b})),[T,k]=g.useState(!1),[A,M]=g.useState(!1),[L,H]=g.useState(!1);g.useEffect(()=>{E(py({disableAuthDefault:a,endpoint:o,nodeName:u,transportType:v,workDir:b}))},[a,o,u,v,b]);async function I(){if(!c||T||A)return;const ae=p.updateAvailable?"update":"restart",ie=Ij(R);if(R.port.trim()&&ie?.port===void 0){Te.error("Runtime restart port must be a positive integer");return}const ce=ie?{reason:ae,startArgs:ie}:{reason:ae};k(!0);try{if(s){const $=await r0(ce);C({...$,pid:$.pid??h,status:"accepted"}),Te.info(`Restarting ${u} from a detached helper. PID ${$.pid??h??"unknown"} will not stay attached to the original terminal window; follow ${$.logPath} for launch output.`),d1({previousPid:$.pid??h}).then(O=>{O||(k(!1),Te.error("Runtime restart was accepted, but the dashboard did not reconnect before the timeout. Refresh the page after the node finishes starting."))}).catch(O=>{k(!1),Te.error(O instanceof Error?O.message:"Runtime restart recovery failed")});return}const ue=await LE(c,ce);C({operationId:ue.id,pid:h,status:ue.status}),Te.info(`Restart requested on ${u}. Operation ${Id(ue.id)} will hand off to a detached process, so the new runtime will not stay attached to the original terminal window.`);const re=await u1(ue,{timeoutMs:6e4}),_=Gj(re);C({command:_?.command,logPath:_?.logPath,mode:_?.mode,operationId:re.id,pid:_?.pid??h,status:re.status}),re.status==="succeeded"?(await m?.(),Te.success(`Restart handoff accepted on ${u}. Follow ${_?.logPath??"the node restart log"} for launch output.`)):re.status==="failed"?Te.error(re.error??`Restart failed on ${u}`):Te.info(`Restart operation ${Id(re.id)} is still ${re.status}. More details will update after the node reports back.`),k(!1)}catch(ue){k(!1),Te.error(ue instanceof Error?ue.message:"Runtime restart failed")}}async function G(){if(!(!s||T||A)){M(!0);try{const ae=await DE();Te.info(`Stopping Meshy process ${ae.pid}`)}catch(ae){M(!1),Te.error(ae instanceof Error?ae.message:"Runtime stop failed")}}}const V=T?"restarting":A?"stopping":S?.status??"idle",oe=p.restartMode==="development",fe=oe?"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(ki,{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:oe?"Development launcher":`Latest ${p.latestVersion??"—"}`})]})]}),fe&&f.jsx("div",{className:"flex items-center gap-1.5",children:f.jsx(qa,{variant:p.updateAvailable?"default":"outline",className:J("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:V})]})]}),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(lf,{children:[f.jsx(sf,{asChild:!0,children:f.jsxs(xt,{type:"button",size:"sm",variant:"ghost",disabled:T||A,className:"h-7 rounded-sm px-2 text-[11px] text-muted-foreground hover:bg-destructive/10 hover:text-destructive",children:[f.jsx(JN,{className:J("mr-1 h-3.5 w-3.5",A&&"animate-pulse")}),A?"Stopping":"Stop"]})}),f.jsxs(Ui,{className:"max-w-[22rem] gap-2 rounded-sm p-4",children:[f.jsxs(Hi,{className:"space-y-1",children:[f.jsx(Pi,{className:"text-[12px]",children:"Stop runtime?"}),f.jsx($i,{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(Bi,{className:"gap-1 pt-0 sm:space-x-1",children:[f.jsx(Vi,{className:hy,children:"Cancel"}),f.jsx(qi,{className:"h-7 rounded-sm bg-destructive px-2 text-[11px] text-destructive-foreground hover:bg-destructive/90",onClick:()=>{G()},children:"Stop runtime"})]})]})]}),f.jsxs(lf,{children:[f.jsx(sf,{asChild:!0,children:f.jsxs(xt,{type:"button",size:"sm",variant:"ghost",disabled:!c||T||A,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(wi,{className:J("mr-1 h-3.5 w-3.5",T&&"animate-spin")}),T?"Restarting…":y]})}),f.jsxs(Ui,{className:"max-w-[26rem] gap-2 rounded-sm p-3",children:[f.jsxs(Hi,{className:"space-y-1",children:[f.jsxs(Pi,{className:"text-[12px]",children:[y,"?"]}),f.jsxs($i,{className:"text-[10px] 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(Yj,{value:R,onChange:E}),f.jsxs(Bi,{className:"gap-1 pt-0 sm:space-x-1",children:[f.jsx(Vi,{className:hy,children:"Cancel"}),f.jsx(qi,{className:"h-6 rounded-sm px-2 text-[10px]",onClick:()=>{I()},children:y})]})]})]})]})]}),f.jsxs("div",{className:"border-t border-border/50",children:[f.jsxs("button",{type:"button",onClick:()=>H(ae=>!ae),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(p0,{className:"h-3 w-3"}),"Restart details"]}),f.jsx(gr,{className:J("h-3 w-3 transition-transform duration-150",L&&"rotate-180")})]}),L&&f.jsxs("div",{className:"border-t border-border/50 bg-muted/20 px-3 py-2 space-y-1",children:[f.jsx(hr,{label:"Current PID",value:h===void 0?"—":String(h),mono:h!==void 0}),f.jsx(hr,{label:"Restart PID",value:S?.pid===void 0?"Pending":String(S.pid),mono:S?.pid!==void 0}),f.jsx(hr,{label:"Operation",value:S?.operationId?Id(S.operationId):"Local direct request",mono:!!S?.operationId}),f.jsx(hr,{label:"Status",value:S?.status??(T?"requested":"idle")}),f.jsx(hr,{label:"Launcher",value:S?.command??"Available after restart",mono:!!S?.command}),f.jsx(hr,{label:"Log",value:S?.logPath??"Available after restart",mono:!!S?.logPath}),f.jsx(hr,{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 Yj({onChange:t,value:a}){const o=(s,c)=>{t({...a,[s]:c})};return f.jsxs("div",{className:"space-y-2 rounded-sm border border-border/70 bg-muted/25 p-2.5 shadow-none",children:[f.jsx("div",{className:"text-[9px] font-semibold uppercase tracking-[0.14em] text-muted-foreground",children:"Startup arguments"}),f.jsxs("div",{className:"grid gap-1.5 sm:grid-cols-2",children:[f.jsx(Ol,{label:"HTTP port",value:a.port,onChange:s=>o("port",s),inputMode:"numeric"}),f.jsx(Ol,{label:"Node name",value:a.name,onChange:s=>o("name",s)}),f.jsx(Ol,{label:"Join endpoint",value:a.join,onChange:s=>o("join",s),className:"sm:col-span-2"}),f.jsxs("div",{className:"space-y-0.5",children:[f.jsx("label",{className:"text-[8px] uppercase tracking-[0.14em] text-muted-foreground",children:"Transport"}),f.jsxs(dy,{value:a.transport,onValueChange:s=>o("transport",f1(s)),children:[f.jsx(xf,{className:"h-6 rounded-sm border-border/60 bg-background/70 px-1.5 text-[9px] shadow-none focus:ring-1 focus:ring-offset-0 [&>svg]:h-3 [&>svg]:w-3",children:f.jsx(fy,{placeholder:"Transport"})}),f.jsxs(wf,{children:[f.jsx(La,{className:"py-0.5 text-[10px]",value:"inherit",children:"current / default"}),f.jsx(La,{className:"py-0.5 text-[10px]",value:"direct",children:"direct"}),f.jsx(La,{className:"py-0.5 text-[10px]",value:"devtunnel",children:"devtunnel"}),f.jsx(La,{className:"py-0.5 text-[10px]",value:"tailscale",children:"tailscale"})]})]})]}),f.jsx(Ol,{label:"Working directory",value:a.workDir,onChange:s=>o("workDir",s)}),f.jsx(Ol,{label:"Config path",value:a.config,onChange:s=>o("config",s),className:"sm:col-span-2"}),f.jsxs("div",{className:"space-y-0.5 sm:col-span-2",children:[f.jsx("label",{className:"text-[8px] uppercase tracking-[0.14em] text-muted-foreground",children:"GHC tunnel"}),f.jsxs(dy,{value:a.ghcTunnel,onValueChange:s=>o("ghcTunnel",Xj(s)),children:[f.jsx(xf,{className:"h-6 rounded-sm border-border/60 bg-background/70 px-1.5 text-[9px] shadow-none focus:ring-1 focus:ring-offset-0 [&>svg]:h-3 [&>svg]:w-3",children:f.jsx(fy,{placeholder:"GHC tunnel"})}),f.jsxs(wf,{children:[f.jsx(La,{className:"py-0.5 text-[10px]",value:"inherit",children:"current / remembered"}),f.jsx(La,{className:"py-0.5 text-[10px]",value:"enable",children:"enable"}),f.jsx(La,{className:"py-0.5 text-[10px]",value:"disable",children:"disable"})]})]})]}),f.jsxs("label",{className:"flex cursor-pointer items-center gap-1.5 rounded-sm border border-border/60 bg-background/55 px-1.5 py-1 text-[9px] text-foreground shadow-none transition-colors hover:bg-muted/40 sm:col-span-2",children:[f.jsx(tx,{className:"h-3 w-3",checked:a.disableAuth,onCheckedChange:s=>t({...a,disableAuth:s===!0,disableAuthKnown:!0})}),"Disable auth"]})]})]})}function Ol({className:t,inputMode:a,label:o,onChange:s,value:c}){return f.jsxs("label",{className:J("space-y-0.5",t),children:[f.jsx("span",{className:"text-[8px] uppercase tracking-[0.14em] text-muted-foreground",children:o}),f.jsx(sc,{className:"h-6 rounded-sm border-border/60 bg-background/70 px-1.5 py-0.5 text-[9px] shadow-none focus-visible:ring-1 focus-visible:ring-offset-0",inputMode:a,value:c,onChange:u=>s(u.target.value)})]})}function hr({label:t,value:a,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:J("break-all text-right text-foreground",o&&"font-mono"),children:a})]})}function Gj(t){const a=t.result;if(!a||typeof a!="object")return null;const o=a;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:Qj(t.endpoint),name:t.nodeName,join:"",transport:f1(t.transportType),workDir:t.workDir??"",config:"",disableAuth:t.disableAuthDefault===!0,disableAuthKnown:t.disableAuthDefault!==void 0,ghcTunnel:"inherit"}}function Ij(t){const a={},o=Number(t.port.trim());return t.port.trim()&&Number.isInteger(o)&&o>0&&(a.port=o),t.name.trim()&&(a.name=t.name.trim()),t.join.trim()&&(a.join=t.join.trim()),t.transport!=="inherit"&&(a.transport=t.transport),t.workDir.trim()&&(a.workDir=t.workDir.trim()),t.config.trim()&&(a.config=t.config.trim()),t.disableAuthKnown&&(a.disableAuth=t.disableAuth),t.ghcTunnel==="enable"&&(a.ghcTunnel=!0),t.ghcTunnel==="disable"&&(a.ghcTunnel=!1),Object.keys(a).length>0?a:void 0}function f1(t){return t==="direct"||t==="devtunnel"||t==="tailscale"?t:"inherit"}function Xj(t){return t==="enable"||t==="disable"?t:"inherit"}function Qj(t){if(!t)return"";try{return new URL(t).port||""}catch{return""}}function Id(t){return t.length<=8?t:t.slice(0,8)}function Ll(t){if(t==null||t==="")return"Unavailable";const a=new Date(t);return Number.isNaN(a.getTime())?"Unavailable":new Intl.DateTimeFormat(void 0,{dateStyle:"medium",timeStyle:"short"}).format(a)}function dD(t){const a=Math.max(0,Math.floor(t)),o=Math.floor(a/86400),s=Math.floor(a%86400/3600),c=Math.floor(a%3600/60);return o>0?`${o}d ${s}h`:s>0?`${s}h ${c}m`:`${c}m`}function fD(t){if(t==null||Number.isNaN(t))return"Unavailable";const a=["B","KB","MB","GB","TB"];let o=t,s=0;for(;o>=1024&&s<a.length-1;)o/=1024,s+=1;return`${o.toFixed(o>=10||s===0?0:1)} ${a[s]}`}function mD(t){return t==="ok"?"default":t==="missing"||t==="install-failed"||t==="login-failed"?"destructive":t==="not-authenticated"||t==="unsupported-platform"?"outline":"secondary"}function Kj(t,a){return t?.nodes?.length?t.nodes:a?[a]:[]}function Zj(t,a){if(a&&t.id===a.nodeId)return a;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 m1(t){return t.available?"available":t.metadataStatus??"unavailable"}function Wj(t){if(t.available)return"Available";const a=t.metadataStatus;return a?a.split(/[-_\s]+/).filter(Boolean).map((o,s)=>s===0?o.charAt(0).toUpperCase()+o.slice(1):o).join(" "):"Unavailable"}const h1="grid grid-cols-[minmax(0,1.3fr)_5.75rem_minmax(0,1fr)_3.5rem] items-center gap-x-2",Fj="h-6 rounded-sm border-0 bg-muted/55 px-2 text-[10px] text-muted-foreground shadow-none hover:bg-muted/75 hover:text-foreground";function Jj({agent:t}){const a=m1(t),o=t.available;return f.jsx("span",{"data-agent-availability":o?"available":"unavailable","data-agent-status":a,"aria-hidden":"true",className:J("inline-flex h-1.5 w-1.5 shrink-0 rounded-full",o?"bg-emerald-500":a==="missing"?"bg-destructive":"bg-amber-500")})}function e_({activeOperation:t,agent:a,nodeName:o,onUpgrade:s,upgrading:c}){return t?f.jsxs(qa,{"data-agent-update-state":"upgrading",variant:"outline",className:"h-6 gap-1 rounded-sm border-amber-500/30 bg-amber-500/10 px-1.5 py-0 text-[10px] font-medium uppercase tracking-[0.1em] text-amber-700 dark:text-amber-300",children:[f.jsx(ac,{className:"h-3 w-3 animate-spin"}),t.status]}):a.update?a.update.updateAvailable?f.jsxs(lf,{children:[f.jsx(sf,{asChild:!0,children:f.jsx("button",{type:"button","data-agent-update-state":"available",disabled:c,"aria-label":`Update available — ${a.update.latestVersion}`,title:`Update available — ${a.update.latestVersion}`,onClick:u=>u.stopPropagation(),className:"inline-flex h-7 w-7 items-center justify-center rounded-sm border-0 bg-amber-500/10 text-amber-600 shadow-none transition-colors hover:bg-amber-500/15 hover:text-amber-600 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-amber-500/45 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-60 dark:text-amber-400 dark:hover:text-amber-400",children:f.jsx(Ml,{className:"h-4 w-4"})})}),f.jsxs(Ui,{className:"max-w-[24rem] gap-2 rounded-sm p-3",children:[f.jsxs(Hi,{className:"space-y-1",children:[f.jsxs(Pi,{className:"text-[12px]",children:["Upgrade ",a.label,"?"]}),f.jsxs($i,{className:"text-[10px] leading-4",children:["Runs the command below on ",o,". Remote nodes execute it on the remote machine."]})]}),f.jsx("div",{className:"rounded-sm border border-border/60 bg-muted/30 px-2 py-1.5 font-mono text-[10px] leading-4 text-foreground break-all",children:t_(a)}),f.jsxs(Bi,{className:"gap-1 pt-0 sm:space-x-1",children:[f.jsx(Vi,{className:Fj,children:"Cancel"}),f.jsx(qi,{className:"h-6 rounded-sm px-2 text-[10px]",onClick:()=>s(a),children:"Upgrade"})]})]})]}):f.jsx("span",{"data-agent-update-state":"current","aria-label":"Up to date",title:"Up to date",className:"inline-flex h-7 w-7 items-center justify-center text-emerald-600 dark:text-emerald-400",children:f.jsx(bo,{className:"h-3.5 w-3.5"})}):f.jsx("span",{"data-agent-update-state":"none",className:"text-[10px] text-muted-foreground/70",children:"—"})}function t_(t){const a=`npm install -g ${t.update?.packageName}@latest`;return t.id==="claude"?`${a} --include=optional --ignore-scripts=false`:a}function n_(t){return t.error?t.error:t.result?.detail??null}function a_(t){return t?.match(/\d+\.\d+\.\d+(?:[-+][0-9A-Za-z.-]+)?/)?.[0]??null}function p1(t){const a=t.version?.trim()||null,s=(t.id==="copilot"?t.update?.currentVersion??a_(a):null)??a;return a&&s&&a!==s?{value:s,title:a}:{value:s}}function r_(t){const a=t.update?.currentVersion??p1(t).value,o=t.update?.latestVersion?.trim()||null,s=t.update?.updateAvailable===!0&&a&&o&&a!==o?o:void 0,c=t.version?.trim()||null,u=c&&a&&c!==a?c:void 0;return a&&u?{value:a,updateValue:s,title:u}:{value:a,updateValue:s}}function o_(t){const a=p1(t),o=[],s=t.update?.currentVersion??a.value,c=t.version?.trim()||null;return s&&o.push({label:"Current version",value:s,mono:!0}),t.update?.latestVersion&&o.push({label:"Latest version",value:t.update.latestVersion,mono:!0}),c&&s&&c!==s&&o.push({label:"Raw version",value:c,mono:!0}),t.update?.checkedAt&&o.push({label:"Update checked",value:Ll(t.update.checkedAt)}),o}function l_({agent:t}){const a=r_(t);if(a.value){const o=a.title??(a.updateValue?`${a.value} -> ${a.updateValue}`:a.value);return f.jsxs("span",{title:o,className:"block truncate font-mono text-foreground",children:[f.jsx("span",{children:a.value}),a.updateValue&&f.jsxs("span",{"data-agent-version-update":"true",className:"ml-1 text-amber-600 dark:text-amber-400",children:["-> ",a.updateValue]})]})}return f.jsx("span",{className:"text-muted-foreground/60",children:"—"})}function Dl({label:t,value:a,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:J("min-w-0 break-all text-right text-foreground/90",o&&"font-mono"),children:a})]})}function s_({agent:t,nodeName:a,activeOperation:o,onUpgrade:s}){const[c,u]=g.useState(!1),m=t.update?.updateAvailable===!0,h=!!o,v=t.available,p=m1(t),b=o_(t),y=[t.detail,t.update?.detail].filter(C=>!!C),S=()=>u(C=>!C);return f.jsxs("div",{"data-agent-row":t.id,children:[f.jsxs("div",{role:"button",tabIndex:0,"aria-expanded":c,"aria-label":`Toggle ${t.label} details`,onClick:S,onKeyDown:C=>{C.target===C.currentTarget&&(C.key==="Enter"||C.key===" ")&&(C.preventDefault(),S())},className:J(h1,"cursor-pointer px-2 py-1.5 transition-colors hover:bg-muted/40"),children:[f.jsxs("div",{className:"flex min-w-0 items-center gap-1.5",children:[f.jsx(gr,{"aria-hidden":"true",className:J("h-3 w-3 shrink-0 text-muted-foreground transition-transform duration-150",c&&"rotate-180")}),f.jsx(ji,{className:"h-3.5 w-3.5 shrink-0 text-primary"}),f.jsx("span",{className:"truncate text-[12px] font-medium leading-4 text-foreground",children:t.label})]}),f.jsxs("div",{className:"flex min-w-0 items-center gap-1.5 text-[10px]",children:[f.jsx(Jj,{agent:t}),f.jsx("span",{className:J("truncate",v?"text-foreground/75":p==="missing"?"text-destructive":"text-amber-600 dark:text-amber-400"),children:Wj(t)})]}),f.jsx("div",{className:"min-w-0 overflow-hidden text-[10px]",children:f.jsx(l_,{agent:t})}),f.jsx("div",{className:"flex items-center justify-end",children:f.jsx(e_,{activeOperation:o,agent:t,nodeName:a,onUpgrade:s,upgrading:h||m===!1})})]}),c&&f.jsxs("div",{"data-agent-row-details":t.id,className:"space-y-1 border-t border-border/45 bg-muted/20 px-3 py-2",children:[f.jsx(Dl,{label:"Command",value:t.command,mono:!0}),f.jsx(Dl,{label:"Path",value:t.path??"Not on PATH",mono:!!t.path}),f.jsx(Dl,{label:"Last checked",value:Ll(t.checkedAt)}),b.map(C=>f.jsx(Dl,{label:C.label,value:C.value,mono:C.mono},C.label)),y.map((C,R)=>f.jsx(Dl,{label:R===0?"Detail":"",value:C},R))]})]})}function i_({agents:t,nodeName:a,activeUpgradeFor:o,onUpgrade:s}){return f.jsxs("div",{"data-agent-table":"true",className:"overflow-hidden rounded-sm border border-border/60 bg-background/40",children:[f.jsxs("div",{className:J(h1,"border-b border-border/60 bg-muted/30 px-2 py-1 text-[9px] font-medium uppercase tracking-[0.16em] text-muted-foreground"),children:[f.jsx("span",{children:"Agent"}),f.jsx("span",{children:"Status"}),f.jsx("span",{children:"Version"}),f.jsx("span",{className:"text-right",children:"Update"})]}),f.jsx("div",{className:"divide-y divide-border/40",children:t.map(c=>f.jsx(s_,{agent:c,nodeName:a,activeOperation:o(c),onUpgrade:s},c.id))})]})}function c_(t){return t==="claude"?"Claude Code":t==="copilot"?"Copilot CLI":"Codex"}function u_(t){const a=t.payload?.agent;return a==="claude"||a==="codex"||a==="copilot"?a:null}function d_({cluster:t,systemInfo:a,initialSelectedNodeId:o,onRefresh:s}){const c=g.useMemo(()=>Kj(t,a),[t,a]),[u,m]=g.useState(()=>o??a?.nodeId??t?.self?.id??""),[h,v]=g.useState(()=>new Map),[p,b]=g.useState("codex"),[y,S]=g.useState(!1),[C,R]=g.useState("runtime"),[E,T]=g.useState(!1),k=g.useRef(new Set),A=g.useRef(new Set),M=t?.self??a??c[0]??null,L=c.find(O=>O.id===u)??M,H=L?Zj(L,a):null,I=!!(a&&L&&L.id===a.nodeId),G=I||!!L?.settingsSnapshot,V=H?.runtimeUpdate,oe=cf(H?.defaultTaskAgent),fe=g.useMemo(()=>c.map(O=>O.id),[c]),ae=fe.join("\0"),ie=_j(c),ce=g.useMemo(()=>new Map(c.map(O=>[O.id,O.name])),[ie]);g.useEffect(()=>{o&&fe.includes(o)&&m(o)},[o,ae]),g.useEffect(()=>{b(oe)},[L?.id,oe]);const ue=g.useCallback(async(O,W)=>{const N=c1(O);if(!N||k.current.has(O.id))return;const Y=u_(O),ne=W?.agentLabel??(Y?c_(Y):"Agent"),X=W?.nodeName??ce.get(O.nodeId)??O.nodeId;k.current.add(O.id),v(F=>new Map(F).set(N,O));try{const F=await u1(O);if(F.status==="succeeded")await s?.(),A.current.has(F.id)||(Te.success(`${ne} upgrade finished on ${X}`),A.current.add(F.id));else if(F.status==="failed")A.current.has(F.id)||(Te.error(n_(F)??`${ne} upgrade failed`),A.current.add(F.id));else{v(ee=>new Map(ee).set(N,F)),Te.info(`${ne} upgrade is still ${F.status} on ${X}`);return}v(ee=>{const te=new Map(ee),se=te.get(N);return(!se||se.id===F.id)&&te.delete(N),te})}catch(F){v(ee=>{const te=new Map(ee),se=te.get(N);return(!se||se.id===O.id)&&te.delete(N),te}),Te.error(F instanceof Error?F.message:`${ne} upgrade failed`)}finally{k.current.delete(O.id)}},[s,ce]);g.useEffect(()=>{if(fe.length===0)return;let O=!1;async function W(){let N;try{N=await Mj(fe)}catch{return}if(!O){v(Y=>{const ne=new Map(Y);for(const[X,F]of N)ne.set(X,F);return ne});for(const Y of N.values())ue(Y)}}return W(),()=>{O=!0}},[ue,ae]);async function re(O){if(L)try{const W=await zE(L.id,O.id);Te.info(`${O.label} upgrade started on ${L.name}`),await ue(W,{agentLabel:O.label,nodeName:L.name})}catch(W){Te.error(W instanceof Error?W.message:`${O.label} upgrade failed`)}}async function _(O){if(!I||O===oe)return;const W=p;b(O),S(!0);try{const N=await OE(O);b(cf(N.defaultTaskAgent)),await s?.(),Te.success("Default agent updated")}catch(N){b(W),Te.error(N instanceof Error?N.message:"Failed to update default agent")}finally{S(!1)}}if(!L||!H)return 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..."});const $=[{id:"runtime",icon:f.jsx(ki,{className:"h-3.5 w-3.5"}),title:"Runtime",description:"Runtime package, process state, and restart controls.",content:V?f.jsx(Vj,{checkedLabel:Ll(V.checkedAt),disableAuthDefault:H.auth?.enabled===void 0?void 0:H.auth.enabled===!1,endpoint:L.endpoint,isLiveLocalNode:I,nodeId:L.id,nodeName:L.name,onRefresh:s,pid:H.runtime?.pid,transportType:L.transportType,update:V,workDir:H.runtime?.workDir??L.workDir}):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:"Runtime update metadata is unavailable for this node."})},{id:"copilot-tunnel",icon:f.jsx(i0,{className:"h-3.5 w-3.5"}),title:"GitHub Copilot Tunnel",description:"Node-local Copilot proxy provider on port 8314.",content:f.jsx(f5,{nodeId:L.id,nodeName:L.name})},{id:"agents",icon:f.jsx(ji,{className:"h-3.5 w-3.5"}),title:"Available Agents",description:"Agent availability, upgrades, and the default task agent.",content:f.jsxs(Pl,{className:"rounded-sm border-border/70 bg-background/75 shadow-none",children:[f.jsx($l,{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(ql,{className:"flex items-center gap-1.5 text-[12px]",children:[f.jsx(ji,{className:"h-3.5 w-3.5 text-primary"}),"Available agents"]}),f.jsx(Vl,{className:"text-[10px]",children:I?"Live command availability for runtime agents on this node.":"Most recent agent availability snapshot synced from this node."})]}),f.jsx(m5,{value:y?p:oe,disabled:!I,saving:y,onChange:_})]})}),f.jsx(Yl,{"data-agent-layout":"table",className:"px-3 pb-2.5",children:f.jsx(i_,{agents:H.agents??[],nodeName:L.name,activeUpgradeFor:O=>h.get(`${L.id}:${O.id}`),onUpgrade:re})})]})},{id:"quick-chat",icon:f.jsx(Uf,{className:"h-3.5 w-3.5"}),title:"Quick Chat",description:"Reusable slash aliases for chat composers.",content:f.jsx(k5,{})},{id:"about",icon:f.jsx(d0,{className:"h-3.5 w-3.5"}),title:"About",description:"Repository, runtime identity, and package versions.",content:f.jsx(YA,{formatDateTime:Ll,viewInfo:H})}];return f.jsxs("div",{className:"flex h-full min-h-0 flex-col gap-2 pt-1",children:[f.jsx(w5,{formatDateTime:Ll,isLiveLocalNode:I,onSelectedNodeChange:m,selectableNodes:c,selectedNode:L}),!G&&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("div",{"data-settings-layout":"menu-details",className:"flex min-h-0 flex-1 items-stretch gap-2",children:[f.jsxs("aside",{"data-settings-menu-collapsed":String(E),className:J("group/settings-menu flex shrink-0 flex-col overflow-hidden rounded-sm border border-border/60 bg-background/70 shadow-none transition-[width] duration-150",E?"w-9":"w-40 sm:w-44"),children:[f.jsxs("div",{className:J("flex items-center gap-1.5 border-b border-border/45 py-1",E?"justify-center px-1":"justify-between px-1.5"),children:[!E&&f.jsx("span",{className:"min-w-0 truncate text-[8px] font-semibold uppercase tracking-[0.14em] text-muted-foreground",children:"Settings"}),f.jsx("button",{type:"button",className:"settings-menu-toggle flex h-6 w-6 shrink-0 items-center justify-center rounded-sm text-muted-foreground transition-colors hover:bg-muted/45 hover:text-foreground focus:outline-none focus-visible:ring-1 focus-visible:ring-primary/45","aria-label":E?"Expand settings menu":"Collapse settings menu",title:E?"Expand settings menu":"Collapse settings menu",onClick:()=>T(O=>!O),children:E?f.jsx(Oi,{className:"h-3 w-3"}):f.jsx(TN,{className:"h-3 w-3"})})]}),f.jsx("nav",{"aria-label":"Settings sections",className:"space-y-1 p-1",children:$.map(O=>{const W=O.id===C;return f.jsxs("button",{type:"button","data-settings-menu-item":O.title,"aria-current":W?"page":void 0,"aria-label":`Show ${O.title} settings`,"aria-pressed":W,title:E?O.title:void 0,onClick:()=>R(O.id),className:J("flex h-7 w-full items-center gap-1.5 rounded-sm px-1.5 text-[10px] leading-3.5 transition-colors hover:bg-muted/45 hover:text-foreground focus:outline-none focus-visible:ring-1 focus-visible:ring-primary/45",E&&"justify-center px-0",W?"bg-primary/10 text-foreground":"text-muted-foreground"),children:[f.jsx("span",{className:"shrink-0 text-primary/90 [&_svg]:h-3 [&_svg]:w-3",children:O.icon}),f.jsx("span",{className:J("settings-menu-label min-w-0 flex-1 truncate text-left",E&&"hidden"),children:O.title})]},O.id)})})]}),f.jsx("section",{"data-settings-details-pane":"true",className:"min-w-0 flex-1 rounded-sm border border-border/60 bg-background/70 p-1.5 shadow-none",children:f.jsx("div",{className:"space-y-2",children:$.map(O=>f.jsx("div",{"data-settings-details":O.title,hidden:O.id!==C,children:O.content},O.id))})})]})]})}function f_({initialSelectedNodeId:t,open:a,onOpenChange:o,showTrigger:s=!0}={}){const{cluster:c,systemInfo:u,refresh:m}=l0();return f.jsx(kA,{open:a,onOpenChange:o,showTrigger:s,children:f.jsx(d_,{cluster:c,systemInfo:u,initialSelectedNodeId:t,onRefresh:m})})}const Zi="meshy:show-live-events";function g1(){const t=globalThis.window;if(!t)return;const a=typeof t.CustomEvent=="function"?new t.CustomEvent(Zi):new t.Event(Zi);t.dispatchEvent(a)}function hD(t){const a=globalThis.window;return a?(a.addEventListener(Zi,t),()=>a.removeEventListener(Zi,t)):()=>{}}const m_={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"},h_={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 p_(t){return t.split(".")[0]??"unknown"}function g_(t){return new Date(t).toLocaleTimeString("en-US",{hour12:!1})}function vo(t,a,o){return typeof o=="string"&&o.length>0?o:a?.get(t)??t}function v1(t,a){const o=t.data,s=o.operation;switch(t.type){case"node.joined":return`${o.name} joined the cluster`;case"node.left":return`${vo(o.nodeId,a,o.name)} left (${o.reason})`;case"node.status":return`${vo(o.nodeId,a)} is now ${o.status}`;case"node.operation.created":return`${s?.kind} ${s?.status} on ${vo(s?.nodeId,a)}`;case"node.operation.updated":return`${s?.kind} ${s?.status} on ${vo(s?.nodeId,a)}`;case"transport.changed":return`${vo(o.nodeId,a)} transport switched to ${o.transportType}`;case"task.created":return`"${o.title}" created`;case"task.assigned":return`task assigned to ${vo(o.nodeId,a)}`;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 v_(t){return JSON.stringify(t,null,2)}function y_({events:t,maxHeight:a="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:a},children:f.jsx("div",{className:"space-y-1.5",children:t.map(h=>{const v=p_(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:J("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:J("font-mono text-muted-foreground",m?"text-[8px]":"text-[9px]"),children:g_(h.timestamp)}),m?f.jsx("span",{className:J("max-w-[8.5rem] truncate text-[7px] font-medium uppercase tracking-[0.08em] text-muted-foreground/70",h_[v]),children:h.type}):f.jsx(qa,{variant:"outline",className:J("w-fit text-[9px] font-medium uppercase tracking-[0.14em] px-1.5 py-0",m_[v]),children:h.type})]}),f.jsxs("div",{className:J("flex shrink-0 items-center",m?"gap-px":"gap-0.5"),children:[f.jsx(xt,{type:"button",variant:"ghost",size:"icon",className:J("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(),$b(v_(h),"Event copied")},"aria-label":`Copy ${h.type} event`,title:"Copy event",children:f.jsx(c0,{className:m?"h-2.5 w-2.5":"h-3 w-3"})}),s&&f.jsx(xt,{type:"button",variant:"ghost",size:"icon",className:J("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(Hf,{className:m?"h-2.5 w-2.5":"h-3 w-3"})})]})]}),f.jsx("div",{className:"text-[9px] leading-snug text-foreground/85",children:v1(h,o)})]})},h.id)})})})}function y1(t){return t!==null}function b1(t){return t==="click"?t:"hover"}function Sf(t){return t==="hover"?null:t}function x1(t){return t==="click"?null:"click"}const b_=["node.","election.","transport."],x_="cluster.state";function w_(t){return t.type==="node.status"?!1:b_.some(a=>t.type.startsWith(a))}function S_(t){return new Date(t).toLocaleTimeString("en-US",{hour12:!1})}function E_(t,a){return t?{time:S_(t.timestamp),text:v1(t,a)}:null}function N_(t){return t.transportType==="devtunnel"||!!t.devtunnelEndpoint}function T_(t){if(t.length===0)return"No node tunnel";const a=t.filter(c=>c.status==="offline").length;if(a>0)return`${a} 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 C_(t,a){const o=a?.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 R_(t){if(t.length===0)return"No nodes";const a=t.filter(s=>s.status==="offline").length;if(a>0)return`${a} offline`;const o=t.filter(s=>s.status==="busy").length;return o>0?`${o} busy`:"Healthy"}function A_(t,a){return{label:a?.get(t.id)??t.name??t.id,status:t.status}}function k_({connected:t,events:a,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:C,onRestart:R}){const[E,T]=g.useState(v?"click":null),[k,A]=g.useState(p),[M,L]=g.useState(!0),[H,I]=g.useState(new Set),[G,V]=g.useState(!1),[oe,fe]=g.useState(!1),ae=y1(E),ie=g.useRef(null),ce=g.useRef(null),ue=g.useMemo(()=>a.filter(be=>w_(be)&&!H.has(be.id)),[a,H]),re=g.useMemo(()=>a.find(be=>be.type===x_)??ue[0],[a,ue]),_=g.useMemo(()=>E_(re,c),[re,c]),$=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]),O=g.useMemo(()=>$.filter(N_),[$]),W=O.some(be=>be.status==="offline"||be.devtunnelHealth?.status==="failed"),N=$.some(be=>be.status==="offline"),Y=$.some(be=>be.status==="busy"),ne=$.length>0,X=s?.name??"offline",F=s?.role==="leader"?"Leader":s?.role==="follower"?"Follower":"Node",ee=u!==null,te=!!(ee&&u?.updateAvailable&&u.latestVersion),se=u?.latestVersion??null,de=!!(ee&&!te&&se),xe=!!(ee&&u?.detail==="Checking desktop update..."),Ae=!!(ee&&!te&&!se&&u?.detail&&!xe),Ne=h?.percent??null,ke=Ne===null?null:`${Ne}%`,Je=G?"Relaunching runtime...":"Relaunch to apply update",at=ke?`Downloading ${ke}`:oe?"Downloading and installing desktop update...":te&&se?`Available version ${se}`:Ae?u?.detail??"Desktop update unavailable":"Desktop is current",fn=!!C,mn=!!(ee&&S),Ga=!!(ee&&b)||fn||mn,ht=ee||!!R,Nr=ee||!!R||fn,Ln=ht?ee?te?"Update":de?"Latest":"Check":"Relaunch":"Reload",st=ee&&!te,hn=st?"Check":Ln,Tr=ht?ee?at:Je:"Reload dashboard page",sa=ht?ee?oe||h!==null:G:!1,$t=ht?ee?sa||!te||!y:sa:!1,Ct=m||oe||!b,Mt=ee?te&&se?`Install desktop update ${se}`:Ae?"Desktop update unavailable":"Desktop is current":ht?G?"Relaunching runtime":"Relaunch runtime":"Reload dashboard page";function We(){ce.current&&(clearTimeout(ce.current),ce.current=null)}function Nn(){We(),T(be=>b1(be))}function Cr(){We(),ce.current=setTimeout(()=>{T(be=>Sf(be)),ce.current=null},180)}function Tn(){We()}function ia(){We(),T(be=>Sf(be))}async function ca(){if(!(!R||G)){V(!0);try{await R()}finally{V(!1)}}}async function Jt(){if(!(!te||!y||oe)){fe(!0);try{await y()}finally{fe(!1)}}}async function Un(){!b||m||oe||await b()}async function Hn(){if(!(!S||G)){A(!1),V(!0);try{await S()}finally{V(!1)}}}async function ua(){if(!ht){await zt();return}if(ee){await Jt();return}await ca()}async function zt(){C&&(A(!1),await C())}function Ia(){I(be=>{const Xe=new Set(be);return ue.forEach(me=>Xe.add(me.id)),Xe})}function Xa(){g1(),T(null)}return g.useEffect(()=>()=>{We()},[]),g.useEffect(()=>{I(be=>{if(be.size===0)return be;const Xe=new Set(a.map(Ue=>Ue.id)),me=new Set(Array.from(be).filter(Ue=>Xe.has(Ue)));return me.size===be.size?be:me})},[a]),g.useEffect(()=>{ae||A(!1)},[ae]),g.useEffect(()=>{if(!ae)return;const be=me=>{ie.current?.contains(me.target)||(We(),A(!1),T(null))},Xe=me=>{me.key==="Escape"&&(We(),A(!1),T(null))};return document.addEventListener("pointerdown",be),document.addEventListener("keydown",Xe),()=>{document.removeEventListener("pointerdown",be),document.removeEventListener("keydown",Xe)}},[ae]),f.jsxs("div",{ref:ie,className:"relative",children:[f.jsxs("button",{type:"button","aria-label":t?"Cluster link connected":"Cluster link reconnecting","aria-expanded":ae,"aria-haspopup":"dialog",onClick:()=>T(be=>x1(be)),onMouseEnter:Nn,onMouseLeave:Cr,className:J("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",ae&&(t?"bg-muted/60 text-foreground":"bg-destructive/12")),title:t?"Cluster link connected":"Cluster link reconnecting",children:[f.jsxs("span",{className:J("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:J("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:X}),f.jsx("span",{className:J("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:F})]})]}),ae&&f.jsxs("div",{role:"dialog","aria-label":"Live link connection events",onMouseEnter:Tn,onMouseLeave:ia,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(ki,{className:"h-3 w-3 text-emerald-500"}):f.jsx(wT,{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:J("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:ue.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"}),_?f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"mt-0.5 truncate text-[9px] leading-snug text-foreground/80",children:_.text}),f.jsx("div",{className:"font-mono text-[8px] text-muted-foreground/60",children:_.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(Ml,{className:"h-3 w-3 shrink-0 text-destructive"}):Y?f.jsx(ki,{className:"h-3 w-3 shrink-0 text-amber-500"}):f.jsx(bo,{className:J("h-3 w-3 shrink-0",ne?"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:J("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":Y?"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300":ne?"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:R_($)})]}),$.length>0&&f.jsx("div",{className:"mt-1.5 flex flex-col gap-0.5",children:$.map(be=>{const{label:Xe,status:me}=A_(be,c),Ue=me==="offline",Qe=me==="busy";return f.jsxs("div",{"aria-label":`${Xe} ${me}`,className:J("flex items-center justify-between gap-2 rounded-sm px-2 py-0.5",Ue?"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}),Ue?f.jsx(Ml,{className:"h-3 w-3 shrink-0 text-destructive"}):Qe?f.jsx(wv,{className:"h-3 w-3 shrink-0 text-amber-500"}):f.jsx(bo,{className:"h-3 w-3 shrink-0 text-emerald-500"})]},be.id)})})]}),O.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:[W?f.jsx(Ml,{className:"h-3 w-3 shrink-0 text-destructive"}):f.jsx(bo,{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:J("shrink-0 rounded-sm border px-1.5 py-0.5 text-[8px] font-medium uppercase tracking-[0.1em]",W?"border-destructive/30 bg-destructive/10 text-destructive":"border-emerald-500/30 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300"),children:T_(O)})]}),f.jsx("div",{className:"mt-1.5 flex flex-col gap-0.5",children:O.map(be=>{const{label:Xe,status:me}=C_(be,c),Ue=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:J("flex items-center justify-between gap-2 rounded-sm px-2 py-0.5",Ue?"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}),Ue?f.jsx(Ml,{className:"h-3 w-3 shrink-0 text-destructive"}):Qe?f.jsx(wv,{className:"h-3 w-3 shrink-0 text-muted-foreground"}):f.jsx(bo,{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:()=>L(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 ",ue.length>0&&`(${ue.length})`]}),M?f.jsx(gr,{className:"h-3 w-3 shrink-0 text-muted-foreground"}):f.jsx(Oi,{className:"h-3 w-3 shrink-0 text-muted-foreground"})]}),!M&&ue.length>0&&f.jsx(xt,{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:Ia,title:"Clear all notifications",children:"Clear all"})]}),M&&f.jsx("div",{className:"px-2 pb-1.5",children:f.jsx(y_,{events:ue,maxHeight:"10rem",density:"compact",emptyTitle:"No connection events yet",emptyDescription:"Node, election, and system events will appear here.",nodeNameById:c,onSelect:Xa,onDismiss:be=>I(Xe=>new Set(Xe).add(be))})})]}),ee&&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(xt,{type:"button",variant:"ghost",size:"sm",className:J("relative h-5 overflow-hidden rounded-none border-0 px-1.5 text-[9px] font-medium hover:text-foreground [&_svg]:size-2.5",te?"bg-primary/12 text-primary hover:bg-primary/18":"bg-background/45 text-muted-foreground hover:bg-emerald-500/10"),onClick:()=>{ua()},disabled:$t,"aria-label":Mt,"aria-describedby":"live-link-restart-hint",title:Tr,children:[Ne!==null&&f.jsx("span",{role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":Ne,className:"pointer-events-none absolute inset-y-0 left-0 bg-primary/24",style:{width:`${Ne}%`}}),Ne===null&&f.jsx(Ev,{className:J("relative z-10 h-2.5 w-2.5",sa&&"animate-pulse")}),f.jsx("span",{className:"relative z-10",children:ke??Ln})]}),Ga&&f.jsx(xt,{type:"button",variant:"ghost",size:"sm",className:J("h-5 rounded-none border-l border-border/50 px-1 text-[9px] hover:text-foreground [&_svg]:size-2.5",te?"bg-primary/12 text-primary hover:bg-primary/18":"bg-background/45 text-muted-foreground hover:bg-emerald-500/10"),onClick:()=>A(be=>!be),"aria-label":"Open live link actions","aria-expanded":k,title:"Live link actions",children:f.jsx(gr,{className:"h-2.5 w-2.5"})})]}),Ga&&k&&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?Un():ua()},disabled:st?Ct:$t,"aria-label":st?"Check for desktop updates":Mt,children:[st?f.jsx(wi,{className:J("h-2.5 w-2.5",m&&"animate-spin")}):f.jsx(Ev,{className:J("h-2.5 w-2.5",sa&&"animate-pulse")}),f.jsx("span",{children:hn})]}),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 disabled:opacity-45 disabled:hover:bg-transparent disabled:hover:text-muted-foreground",onClick:()=>{zt()},"aria-label":"Reload dashboard page",children:[f.jsx(wi,{className:"h-2.5 w-2.5"}),f.jsx("span",{children:"Reload"})]}),mn&&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:G,"aria-label":"Restart Meshy Desktop",children:[f.jsx(wi,{className:J("h-2.5 w-2.5",G&&"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:Tr})]})}),f.jsxs("div",{className:"flex items-center gap-1",children:[M&&f.jsx(xt,{type:"button",variant:"ghost",size:"sm",className:"h-5 rounded-sm px-1.5 text-[9px]",onClick:Ia,disabled:ue.length===0,title:"Clear all notifications",children:"Clear all"}),f.jsx(xt,{type:"button",variant:"ghost",size:"sm",className:"h-5 rounded-sm px-1.5 text-[9px]",onClick:()=>T(null),children:"Close"})]})]})]})]})}const gy="dark",Sr="fluent",j_="clean",Xd="meshy-layout-default-migrated-to-compact",Ef="true",__="compact",O_=new Set(["airy","clean","fluent"]);function D_(t){return t!==null&&O_.has(t)}function gc(t){return t===__?"fluent":D_(t)?t:null}function M_(t,a){const o=gc(t);return o===j_&&a!==Ef?Sr:o??Sr}const Wi="symphony",w1="default",z_=new Set(["light","dark","system"]),L_=new Set(["porcelain","warm","finsight","edge","symphony","launcher"]),S1=g.createContext(null);function U_(t){const a=new URLSearchParams(t).get("theme");return E1(a)?a:null}function H_(t){const a=new URLSearchParams(t).get("palette");return dm(a)}function B_(t){const a=new URLSearchParams(t).get("layout");return gc(a)}function P_(){if(typeof document>"u")return null;const t=document.documentElement;return{theme:t.classList.contains("dark")?"dark":"light",palette:dm(t.getAttribute("data-palette"))??Wi,layout:gc(t.getAttribute("data-layout"))??Sr}}function pD(t,a=P_()){if(!a)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",a.theme),c.searchParams.set("palette",a.palette),c.searchParams.set("layout",a.layout),o?c.toString():`${c.pathname}${c.search}${c.hash}`}catch{return t}}const Qd=.9;function vy(t){const a=t.trim().match(/^(-?\d+(?:\.\d+)?)\s+(-?\d+(?:\.\d+)?)%\s+(-?\d+(?:\.\d+)?)%$/);if(!a)return null;const o=(Number(a[1])%360+360)%360/60,s=Fi(Number(a[2])/100,0,1),c=Fi(Number(a[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 $_(t){const a=t.trim();if(!a||a==="transparent")return null;const o=a.match(/^rgba?\(\s*([+-]?\d+(?:\.\d+)?)\s*,\s*([+-]?\d+(?:\.\d+)?)\s*,\s*([+-]?\d+(?:\.\d+)?)(?:\s*,\s*([+-]?\d+(?:\.\d+)?))?\s*\)$/i);if(o)return[yo(Number(o[1])),yo(Number(o[2])),yo(Number(o[3])),xy(o[4])];const s=a.match(/^rgba?\(\s*([+-]?\d+(?:\.\d+)?)\s+([+-]?\d+(?:\.\d+)?)\s+([+-]?\d+(?:\.\d+)?)(?:\s*\/\s*([+-]?\d+(?:\.\d+)?%?))?\s*\)$/i);return s?[yo(Number(s[1])),yo(Number(s[2])),yo(Number(s[3])),xy(s[4])]:null}function q_(t,a,o){const s=vy(t);if(!s)return null;if(o==="clean"||o==="fluent")return s;const c=vy(a);return c?[Kd(s[0],c[0],Qd),Kd(s[1],c[1],Qd),Kd(s[2],c[2],Qd),255]:null}function V_(){const t=document.querySelector(".dashboard-shell-header-panel");if(!t)return null;const a=$_(getComputedStyle(t).backgroundColor);return!a||a[3]===0?null:a}function yy(){if(typeof window>"u"||typeof document>"u")return;const t=window.__TAURI__?.core?.invoke??null;if(!t)return;const a=document.documentElement,o=a.classList.contains("dark")?"dark":"light",s=getComputedStyle(a),c=gc(a.getAttribute("data-layout"))??Sr,u=V_()??q_(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 Kd(t,a,o){return Math.round(t*o+a*(1-o))}function Fi(t,a,o){return Math.min(Math.max(t,a),o)}function yo(t){return Math.round(Fi(t,0,255))}function xy(t){if(t==null||t==="")return 255;const a=t.endsWith("%")?Number(t.slice(0,-1))/100:Number(t);return Math.round(Fi(a,0,1)*255)}function Y_({children:t}){const[a,o]=g.useState(()=>typeof window<"u"?U_(window.location.search)??X_(localStorage.getItem("meshy-theme"))??gy:gy),[s,c]=g.useState(()=>typeof window<"u"?H_(window.location.search)??Q_(localStorage.getItem("meshy-palette"))??Wi:Wi),[u,m]=g.useState(()=>{if(typeof window<"u"){const h=B_(window.location.search);if(h)return localStorage.setItem(Xd,Ef),h;const v=M_(localStorage.getItem("meshy-layout"),localStorage.getItem(Xd));return localStorage.setItem(Xd,Ef),v}return Sr});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(a),localStorage.setItem("meshy-theme",a),a==="system"){const p=window.matchMedia("(prefers-color-scheme: dark)"),b=()=>{v("system"),by()};return p.addEventListener("change",b),()=>p.removeEventListener("change",b)}},[a]),g.useEffect(()=>{document.documentElement.setAttribute("data-palette",s),localStorage.setItem("meshy-palette",s)},[s]),g.useEffect(()=>{const h=document.documentElement;u===Sr?h.removeAttribute("data-layout"):h.setAttribute("data-layout",u),localStorage.setItem("meshy-layout",u)},[u]),g.useEffect(()=>by(),[a,s,u]),f.jsx(S1.Provider,{value:{theme:a,setTheme:o,palette:s,setPalette:c,layout:u,setLayout:m},children:t})}function G_(){const t=g.useContext(S1);if(!t)throw new Error("useTheme must be used within ThemeProvider");return t}function E1(t){return t!==null&&z_.has(t)}function I_(t){return t!==null&&L_.has(t)}function X_(t){return E1(t)?t:null}function dm(t){return t===w1?"porcelain":I_(t)?t:null}function Q_(t){return t===w1?null:dm(t)}const K_=[{value:"light",label:"Light",icon:h0},{value:"dark",label:"Dark",icon:m0},{value:"system",label:"System",icon:f0}],N1=[{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"}],T1=[{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 Z_(){const{theme:t,setTheme:a,palette:o,setPalette:s,layout:c,setLayout:u}=G_(),[m,h]=g.useState(null),v=g.useRef(null),p=g.useRef(null),b=y1(m),y=t==="dark"?m0:t==="light"?h0:f0,S=()=>{v.current&&(clearTimeout(v.current),v.current=null)},C=()=>{S(),v.current=setTimeout(()=>h(R=>Sf(R)),180)};return g.useEffect(()=>{if(!b)return;const R=E=>{p.current&&!p.current.contains(E.target)&&h(null)};return document.addEventListener("mousedown",R),()=>document.removeEventListener("mousedown",R)},[b]),g.useEffect(()=>()=>S(),[]),f.jsxs("div",{ref:p,className:"relative",onMouseEnter:()=>{S(),h(R=>b1(R))},onMouseLeave:C,children:[f.jsx(xt,{variant:"ghost",size:"icon",onClick:()=>h(R=>x1(R)),className:J("h-8 w-8 rounded-sm",o!==Wi||c!==Sr?"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:[W_(c)," / ",F_(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:K_.map(({value:R,label:E,icon:T})=>{const k=t===R;return f.jsxs("button",{type:"button",onClick:()=>a(R),role:"menuitemradio","aria-checked":k,className:J("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",k?"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(T,{className:"h-3 w-3"}),E]},R)})}),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:T1.map(({value:R,label:E,hint:T})=>{const k=c===R;return f.jsxs("button",{type:"button",onClick:()=>u(R),role:"menuitemradio","aria-checked":k,className:J("flex min-h-[2.25rem] w-full items-center gap-1.5 rounded-sm border px-1.5 py-1 text-left transition-colors",k?"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:J("text-[10px] font-medium leading-tight",k?"text-primary":"text-foreground"),children:E}),f.jsx("div",{className:"mt-0.5 text-[8px] leading-tight text-muted-foreground",children:T})]}),k&&f.jsx(_i,{className:"h-3 w-3 text-primary"})]},R)})})]}),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(mT,{className:"h-2.5 w-2.5"}),"Palette"]}),f.jsx("div",{className:"space-y-1",children:N1.map(({value:R,label:E,hint:T})=>{const k=o===R;return f.jsxs("button",{type:"button",onClick:()=>s(R),role:"menuitemradio","aria-checked":k,className:J("flex min-h-[2.25rem] w-full items-center gap-1.5 rounded-sm border px-1.5 py-1 text-left transition-colors",k?"border-primary/55 bg-primary/10":"border-border/45 bg-background/45 hover:border-border hover:bg-muted/55"),children:[f.jsx(J_,{value:R}),f.jsxs("div",{className:"min-w-0 flex-1",children:[f.jsx("div",{className:J("text-[10px] font-medium leading-tight",k?"text-primary":"text-foreground"),children:E}),f.jsx("div",{className:"mt-0.5 text-[8px] leading-tight text-muted-foreground",children:T})]}),k&&f.jsx(_i,{className:"h-3 w-3 text-primary"})]},R)})})]})]})]})]})}function W_(t){return T1.find(a=>a.value===t)?.label??t}function F_(t){return N1.find(a=>a.value===t)?.label??t}function J_({value:t}){const a={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]=a[t];return f.jsxs("div",{className:J("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}},C1="meshy-dashboard-panel-state-v2",R1="meshy-dashboard-terminal-open-v1";function gD({operationsOpen:t}){return{layout:{desktopTasksOpen:!0,operationsOpen:t},sizes:{tasks:Ul.tasks.defaultSize,operations:Ul.operations.defaultSize,terminal:Ul.terminal.defaultSize}}}function Zd(t){return typeof t=="object"&&t!==null}function wy(t,a){return typeof t=="boolean"?t:a}function Wd(t,a,o){return typeof a=="number"&&Number.isFinite(a)?Hl(t,a):o}function Hl(t,a){const o=Ul[t];return Math.min(o.max,Math.max(o.min,a))}function vD(t,a){if(!t)return a;try{const o=t.getItem(C1);if(!o)return a;const s=JSON.parse(o);if(!Zd(s))return a;const c=Zd(s.layout)?s.layout:{},u=Zd(s.sizes)?s.sizes:{};return{layout:{desktopTasksOpen:wy(c.desktopTasksOpen,a.layout.desktopTasksOpen),operationsOpen:wy(c.operationsOpen,a.layout.operationsOpen)},sizes:{tasks:Wd("tasks",u.tasks,a.sizes.tasks),operations:Wd("operations",u.operations,a.sizes.operations),terminal:Wd("terminal",u.terminal,a.sizes.terminal)}}}catch{return a}}function yD(t,a){if(t)try{t.setItem(C1,JSON.stringify(a))}catch{}}function e3(t,a){if(!t)return a;try{const o=t.getItem(R1);return o==="true"?!0:o==="false"?!1:a}catch{return a}}function t3(t,a){if(t)try{t.setItem(R1,String(a))}catch{}}function Sy(){try{return globalThis.window?.localStorage??globalThis.localStorage??null}catch{return null}}function bD(t){return`${Number(t.toFixed(2))}rem`}function xD(t,a,o,s,c,u,m){const h=Number.isFinite(m)&&m>0?m:16;return t==="tasks"?Hl(t,a+(c-o)/h):t==="operations"?Hl(t,a+(o-c)/h):Hl(t,a+(s-u)/h)}function wD(t,a,o){const s=o===0?0:o>0?-1:1;return Hl(t,a+s*Ul[t].wheelStep)}const n3=7200*1e3,a3=15*1e3,r3="meshy://desktop-update-progress",o3="start_desktop_window_drag",l3="enable_windows_dashboard_titlebar",s3="minimize_desktop_window",i3="toggle_desktop_window_maximize",c3="close_desktop_window",u3="Desktop update check timed out",d3='a,button,input,textarea,select,[role="button"],[role="menu"],[role="dialog"],[contenteditable="true"]';function f3(t){const a=t?.closest;return typeof a!="function"?!1:!a.call(t,d3)}function m3(t,a=Ua()){if(!a||t.button!==void 0&&t.button!==0||t.isPrimary===!1||!f3(t.target))return!1;t.preventDefault?.();try{return a(o3).catch(()=>{}),!0}catch{return!1}}function h3(){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 Ua(){return typeof window>"u"?null:window.__TAURI__?.core?.invoke??null}function p3(){return typeof window>"u"?null:window.__TAURI__?.event?.listen??null}function g3(t){const a=typeof window>"u"?void 0:window;if(!a?.__TAURI__)return!1;const o=a.navigator?.platform??"",s=a.navigator?.userAgent??"";return/Mac/i.test(o)||/Macintosh/i.test(s)}function v3(t){const a=typeof window>"u"?void 0:window;if(!a?.__TAURI__)return!1;const o=a.navigator?.platform??"",s=a.navigator?.userAgent??"";return/Win/i.test(o)||/Windows/i.test(s)}function Fd(t){const a=Ua();a&&a(t).catch(()=>{})}function y3(){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:()=>Fd(s3),children:f.jsx(GN,{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:()=>Fd(i3),children:f.jsx(pT,{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:()=>Fd(c3),children:f.jsx(Hf,{className:"h-3.5 w-3.5"})})]})}function b3(t){if(!t||typeof t!="object")return null;const a=t;return a.phase!=="downloading"&&a.phase!=="installing"&&a.phase!=="complete"?null:{phase:a.phase,receivedBytes:typeof a.receivedBytes=="number"?a.receivedBytes:0,totalBytes:typeof a.totalBytes=="number"?a.totalBytes:null,percent:typeof a.percent=="number"?Math.max(0,Math.min(100,Math.round(a.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 x3(t,a,o){let s;const c=new Promise((u,m)=>{s=setTimeout(()=>{m(new Error(u3))},a)});try{return await Promise.race([t,c])}finally{s!==void 0&&clearTimeout(s)}}async function w3({activeCheck:t,startCheck:a,timeoutMs:o,shouldApply:s,applyUpdate:c,applyFailure:u,failureFallback:m="Desktop update check failed"}){let h=t.current;if(!h){let v;try{v=a()}catch(p){v=Promise.reject(p)}h=x3(v,o),t.current=h}try{const v=await h;return s()&&c(v),v}catch(v){return s()&&u(Nf(v,m)),null}finally{t.current===h&&(t.current=null)}}function Nf(t,a){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 a}function S3(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 E3(){const{cluster:t,events:a,sseConnected:o,systemInfo:s}=l0(),c=dn(),[u,m]=g.useState(()=>e3(Sy(),!1)),[h,v]=g.useState(""),[p,b]=g.useState(null),[y,S]=g.useState(null),[C,R]=g.useState(!1),[E,T]=g.useState(null),k=g.useRef(null),A=!!Ua(),M=g3(),L=v3(),H=M||L,I=H?{"data-tauri-drag-region":!0}:{},G=H?{...I,"data-meshy-desktop-titlebar":"dashboard"}:{},V=g.useCallback(O=>{H&&m3(O)},[H]),oe=A?"max-w-none":"max-w-[1760px]",fe=c.pathname==="/"||/^\/tasks\/[^/]+$/.test(c.pathname),ae=g.useMemo(()=>{const O=new Map;for(const W of t?.nodes??[])O.set(W.id,W.name);return t?.self&&O.set(t.self.id,t.self.name),O},[t?.nodes,t?.self]),ie=g.useCallback(O=>{m(W=>typeof O=="function"?O(W):O)},[]);g.useEffect(()=>{t3(Sy(),u)},[u]),g.useEffect(()=>{if(!L)return;const O=Ua();O&&O(l3).catch(()=>{})},[L]);const ce=g.useCallback(async(O=!0,W=()=>!0)=>{const N=Ua();return N?(O&&W()&&S(Ey("Checking desktop update...")),w3({activeCheck:k,startCheck:()=>N("check_desktop_update"),timeoutMs:a3,shouldApply:W,applyUpdate:Y=>S(Y),applyFailure:Y=>S(ne=>ne?.updateAvailable?ne:Ey(Y))})):(W()&&S(null),null)},[]);async function ue(){R(!0);try{await ce(!1)}finally{R(!1)}}g.useEffect(()=>{if(!Ua()){S(null);return}let O=!1;const W=()=>!O;ce(!0,W);const N=window.setInterval(()=>{ce(!1,W)},n3);return()=>{O=!0,window.clearInterval(N)}},[ce,s?.version]),g.useEffect(()=>{const O=p3();if(!O)return;let W=!1,N;return O(r3,Y=>{const ne=b3(Y.payload);ne&&T(ne)}).then(Y=>{if(W){Y();return}N=Y}).catch(()=>{}),()=>{W=!0,N?.()}},[]);async function re(){try{const O=await r0({reason:"restart"});Te.info(`Restarting runtime. Follow ${O.logPath} for launch output.`),await d1({previousPid:O.pid})||Te.error("Runtime restart was accepted, but the dashboard did not reconnect before the timeout.")}catch(O){Te.error(O instanceof Error?O.message:"Runtime restart failed")}}async function _(){const O=Ua();if(!O){Te.error("Desktop updater is not available in this window");return}try{Te.info("Downloading desktop update..."),T({phase:"downloading",receivedBytes:0,totalBytes:null,percent:0});const W=await O("install_desktop_update");T({phase:"complete",receivedBytes:1,totalBytes:1,percent:100}),Te.info(S3(W))}catch(W){Te.error(Nf(W,"Desktop update failed"))}finally{T(null)}}async function $(){const O=Ua();if(!O){Te.error("Desktop restart is not available in this window");return}try{Te.info("Restarting Meshy Desktop..."),await O("restart_desktop_app")}catch(W){Te.error(Nf(W,"Desktop restart failed"))}}return f.jsxs("div",{className:J("relative h-full overflow-hidden bg-background text-foreground",M&&"dashboard-shell--macos-titlebar",L&&"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:J("dashboard-shell-header relative z-50 shrink-0 px-2 py-2",M&&"dashboard-shell-header--macos-titlebar",L&&"dashboard-shell-header--windows-titlebar"),onPointerDownCapture:H?V:void 0,...I,children:f.jsxs("div",{className:J("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",oe,M&&"dashboard-shell-header-panel--macos-titlebar",L&&"dashboard-shell-header-panel--windows-titlebar"),...G,children:[f.jsx("div",{className:"flex shrink-0 items-center gap-3 pr-3",...I,children:f.jsxs(tf,{to:"/","aria-label":"Meshy home",className:"flex items-center gap-2",children:[f.jsx(h3,{}),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",...I}),fe&&f.jsxs("div",{className:"hidden min-w-0 flex-1 items-center px-3 md:flex",...I,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(cT,{className:"h-3 w-3 shrink-0 text-primary/70"}),f.jsx("span",{className:"max-w-[9rem] truncate",children:p.nodeName})]}),f.jsx(Oi,{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(LN,{className:"h-3 w-3 shrink-0 text-muted-foreground/70"}),f.jsx("span",{className:"max-w-[9rem] truncate",children:p.projectLabel})]}),f.jsx(Oi,{className:"h-3 w-3 shrink-0 text-border/80"}),f.jsx(tf,{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(sT,{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(sc,{"aria-label":"Search tasks",value:h,onChange:O=>v(O.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",...I}),f.jsxs("div",{className:"ml-auto flex shrink-0 items-center gap-1.5 pl-3 sm:gap-2 md:ml-0",...I,children:[fe&&f.jsx(xt,{variant:"ghost",size:"icon",onClick:()=>ie(O=>!O),"aria-label":u?"Close terminal":"Open terminal",title:u?"Close terminal":"Open terminal",className:J("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(p0,{className:"h-4 w-4"})}),f.jsx(f_,{}),f.jsx(Z_,{}),f.jsx("div",{className:"mx-0 h-4 w-px shrink-0 bg-border/50",...I}),f.jsx(k_,{connected:o,events:a,nodes:t?.nodes??[],currentNode:t?.self??null,nodeNameById:ae,desktopUpdate:y,desktopUpdateCheckPending:C,desktopUpdateProgress:E,onDesktopUpdateCheck:A?ue:void 0,onDesktopUpdate:y?.updateAvailable?_:void 0,onDesktopRestart:A?$:void 0,onReload:A?()=>window.location.reload():void 0,onRestart:re}),L&&f.jsx(y3,{})]})]})}),f.jsx("main",{className:J("dashboard-shell-main min-h-0 flex-1 px-2 pb-2",fe?"overflow-hidden":"overflow-y-auto"),children:f.jsx("div",{className:J("dashboard-shell-content mx-auto h-full min-h-0",oe),children:f.jsx(I2,{context:{terminalOpen:u,setTerminalOpen:ie,headerSearchQuery:h,setHeaderSearchQuery:v,setHeaderTaskContext:b}})})})]})]})}function Ny(t){return`/_auth/start?returnTo=${encodeURIComponent(t)}`}function N3(t){try{const{pathname:a}=new URL(t,"http://meshy.local");return a==="/shared"||a.startsWith("/shared/")}catch{return!1}}function T3(t,a){return t?.local?!0:t?.authenticated?t.identity?.access==="shared"?N3(a):!0:!1}function C3({children:t,returnTo:a,session:o}){return T3(o,a)?f.jsx(f.Fragment,{children:t}):o?f.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-3 text-[11px] text-foreground",children:f.jsxs("div",{className:"dashboard-panel dashboard-panel-muted flex w-full max-w-[22rem] flex-col gap-3 rounded-sm border p-3",children:[f.jsxs("div",{className:"flex flex-col gap-1",children:[f.jsx("div",{className:"text-[11px] font-semibold",children:"Microsoft sign-in required"}),f.jsx("div",{className:"text-[10px] leading-4 text-muted-foreground",children:"Remote dashboard access requires a Meshy Node session."})]}),f.jsxs("a",{className:"inline-flex h-8 items-center justify-center gap-1.5 rounded-sm bg-primary px-2 text-[11px] font-medium text-primary-foreground shadow-none",href:Ny(a),onClick:s=>{typeof window>"u"||(s.preventDefault(),window.top?.location.assign(Ny(a)))},children:[f.jsx(qN,{className:"h-3.5 w-3.5","aria-hidden":"true"}),"Sign in with Microsoft"]})]})}):f.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-3 text-[11px] text-muted-foreground",children:f.jsx("div",{className:"dashboard-panel dashboard-panel-muted rounded-sm border px-3 py-2",children:"Checking session..."})})}function Ty({children:t}){const a=dn(),o=g.useMemo(()=>`${a.pathname}${a.search}${a.hash}`,[a.hash,a.pathname,a.search]),[s,c]=g.useState(null);return g.useEffect(()=>{let u=!0;return jE().then(m=>{u&&c(m)}).catch(()=>{u&&c({authenticated:!1,local:!1})}),()=>{u=!1}},[]),f.jsx(C3,{session:s,returnTo:o,children:t})}const Cy=g.lazy(async()=>({default:(await ky(()=>import("./DashboardPage-D5cStRjL.js").then(a=>a.D),__vite__mapDeps([0,1,2,3,4]))).DashboardPage})),R3=g.lazy(async()=>({default:(await ky(()=>import("./SharedConversationPage-C2p4_D8K.js"),__vite__mapDeps([5,1]))).SharedConversationPage}));function A3(){return f.jsx(yE,{children:f.jsx(g.Suspense,{fallback:f.jsx(k3,{}),children:f.jsxs(Q2,{children:[f.jsx(pr,{path:"/shared/tasks/:shareId",element:f.jsx(Ty,{children:f.jsx(R3,{})})}),f.jsxs(pr,{element:f.jsx(Ty,{children:f.jsx(uN,{children:f.jsx(E3,{})})}),children:[f.jsx(pr,{path:"/",element:f.jsx(Cy,{})}),f.jsx(pr,{path:"/nodes",element:f.jsx(hv,{to:"/",replace:!0})}),f.jsx(pr,{path:"/tasks",element:f.jsx(hv,{to:"/",replace:!0})}),f.jsx(pr,{path:"/tasks/:id",element:f.jsx(Cy,{})})]})]})})})}function k3(){return f.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background text-sm text-muted-foreground",children:"Loading workspace..."})}function j3(t){const a=t??(typeof window>"u"?void 0:window);a?.__TAURI__&&a.addEventListener("contextmenu",o=>{o.preventDefault()})}function _3(t){const{className:a,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"&&g1()}return f.jsx("div",{onClick:u,children:f.jsx(HC,{className:["toaster group",a].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})})}j3();GS.createRoot(document.getElementById("root")).render(f.jsx(g.StrictMode,{children:f.jsxs(Y_,{children:[f.jsx(A3,{}),f.jsx(_3,{})]})}));export{$b as $,sO as A,xt as B,_i as C,HO as D,Te as E,LN as F,dy as G,xf as H,sc as I,fy as J,wf as K,ac as L,sT as M,gr as N,mT as O,$e as P,cD as Q,cf as R,cT as S,BO as T,lO as U,TA as V,pb as W,Hf as X,vb as Y,pD as Z,c0 as _,sD as a,aD as a$,Uf as a0,TN as a1,AN as a2,ZA as a3,PO as a4,ji as a5,oD as a6,lD as a7,qa as a8,eD as a9,wi as aA,LO as aB,Zj as aC,Ll as aD,fD as aE,i0 as aF,mD as aG,ki as aH,qb as aI,v5 as aJ,dD as aK,wT as aL,Kl as aM,dT as aN,bN as aO,XN as aP,d0 as aQ,ZO as aR,y_ as aS,u0 as aT,tD as aU,XA as aV,jO as aW,ZC as aX,VO as aY,bT as aZ,nD as a_,aT as aa,lf as ab,Ui as ac,Hi as ad,Pi as ae,$i as af,Bi as ag,Vi as ah,qi as ai,ky as aj,L3 as ak,gb as al,AA as am,W3 as an,p0 as ao,bo as ap,Sv as aq,pT as ar,Z3 as as,F3 as at,K3 as au,OO as av,H3 as aw,B3 as ax,CA as ay,yb as az,Ge as b,Y3 as b$,$O as b0,qO as b1,FO as b2,tx as b3,JO as b4,sf as b5,yO as b6,bO as b7,vD as b8,gD as b9,cO as bA,fO as bB,iO as bC,D3 as bD,dn as bE,Gy as bF,O3 as bG,l0 as bH,WO as bI,T5 as bJ,hD as bK,KO as bL,YO as bM,GO as bN,XO as bO,IO as bP,QO as bQ,oO as bR,IA as bS,QA as bT,mO as bU,hO as bV,dO as bW,uO as bX,z3 as bY,U3 as bZ,M3 as b_,Sy as ba,yD as bb,wD as bc,bD as bd,xD as be,rO as bf,aN as bg,HE as bh,MO as bi,DO as bj,zO as bk,lN as bl,pO as bm,q3 as bn,P3 as bo,a0 as bp,$3 as bq,V3 as br,f_ as bs,gO as bt,vO as bu,nO as bv,J3 as bw,eO as bx,tO as by,aO as bz,Re as c,rD as c0,NO as c1,EO as c2,SO as c3,xO as c4,wO as c5,TO as c6,Bb as c7,jj as c8,uD as c9,kj as ca,Ry as cb,AO as cc,RO as cd,CO as ce,kO as cf,UO as cg,_O as ch,ko as d,M5 as e,Gb as f,Fe as g,L5 as h,zi as i,f as j,vr as k,Zl as l,iD as m,J as n,VC as o,O0 as p,I3 as q,g as r,Q3 as s,WN as t,xo as u,n0 as v,G3 as w,Oi as x,La as y,X3 as z};
|