Zweite Etappe. Kern: das Frontend traegt kein Geheimnis mehr, und es laeuft
nicht laenger als einziger Teil des Stacks ungeprueft durchs Gate.
## B-01 — Box-Sudo-Passwort: ersatzlos entfernt
Das Passwort lag im localStorage und reiste bei JEDEM mutierenden Request mit —
als Header `X-Sudo-Password` UND im JSON-Rumpf. Da /etc/sudoers den Dienst-Nutzer
mit `NOPASSWD: ALL` fuehrt, waere ein einziger XSS in der SPA Root auf der Box
gewesen.
AUF DER BOX GEMESSEN: `sudo -n true` laeuft durch. Das Passwort wurde also nie
gebraucht — es war reines Risiko ohne Gegenwert. Darum keine Umkonstruktion
(Sitzungs-Cookie o. AE.), sondern Loeschung, quer durch den ganzen Pfad:
frontend/src/lib/api.ts kein localStorage-Zugriff mehr
frontend/.../SettingsTab.tsx Eingabefeld weg, dafuer die Erklaerung warum
backend/routers/maintenance.py SudoReq entfaellt, 8 Endpunkte entschlackt
backend/services/maintenance.py _run() nutzt immer `sudo -n`
backend/services/jobengine.py keine stdin-Pipe mehr (DEVNULL)
`password_required` bleibt als ehrliches Signal: Verlangt sudo je doch ein
Passwort, ist das eine Konfigurations-Frage auf der Box — nichts, was man mit
einem im Browser geparkten Geheimnis uebertuencht.
## HuggingFace-Token: liegt jetzt auf der Box
Derselbe Fehler, kleinerer Radius. Neu: backend/services/geheimnisse.py — Datei
neben den anderen mc2-*.json, Rechte 0600, atomar geschrieben. Die Oberflaeche
erfaehrt nur, OB ein Token gesetzt ist, nie seinen Wert. Ein Schluessel-Allowlist
verhindert, dass ein fehlgeleiteter Request beliebige Felder hineinschreibt.
Prozess-Env (HF_TOKEN) hat Vorrang und wird als solche angezeigt.
Verifiziert gegen das lokale Backend: setzen/lesen/loeschen ok, unerlaubter
Schluessel wird mit Klartext-Grund abgewiesen, der Wert kommt nie zurueck.
## B-14 — Fehlermeldungen sagen jetzt, was los ist
api() warf `new Error("500 Internal Server Error")` und verwarf den Rumpf; der
eigentliche Grund aus FastAPIs `detail` erreichte die Oberflaeche nie. Neu:
ApiError mit status + detail, inklusive Validierungslisten und HTML-Fehlerseiten
(ein kaputter Rumpf darf die Meldung nicht in einen zweiten Fehler verwandeln).
Zwei Aufrufstellen zeigen den Grund jetzt statt "Fehler" (Discover, ModelBrowse).
## B-07 — Tests und Linter, ehrlich eingeordnet
Praezisierung gegenueber dem Audit: Die MC2-Ampel fuehrt bewusst GAR KEINE Tests
aus (dokumentiert: die Python-Dienste haengen an ML-Wheels, die echten Tests sind
Pruefstand + Box). Das ist fuer die Dienste richtig — fuer Frontend-Unit-Tests
nicht: die laufen in jsdom, brauchen weder Modell noch GPU, und sind in 1,3 s durch.
Vitest + Testing Library, 17 Tests in 3 Dateien
ESLint (flat config) + Prettier
Beides jetzt Teil der Ampel
Die Tests sind kein Feigenblatt: acht davon sind der Zaun um B-01 — sie beweisen,
dass api() weder Kopfzeilen noch Rumpf aus dem localStorage anreichert. Dazu eine
ESLint-Regel, die localStorage-Zugriffe auf Schluessel mit password/token/secret
im Namen hart abweist (an einer Probe verifiziert; harmlose Schluessel wie
mc_sidebar_collapsed bleiben erlaubt).
ESLint meldet 0 Fehler / 93 Warnungen. Die 18 Treffer der neuen React-Compiler-
Regeln (setState im Effekt, Ref-Zugriff im Render) sind ECHT, aber quer durch
10 500 Zeilen zu beheben ist P5-Arbeit. Sie stehen als sichtbare Warn-Liste statt
abgeschaltet — ein ab Tag eins rotes Gate ist kein Gate mehr.
## Nebenbefund, im Browser reproduziert: veraltetes Buendel nach Deploy
Ein Deploy ersetzt dist und startet den Dienst neu; offene Tabs behalten aber ihr
altes Start-Buendel, dessen Nachlade-Chunks nun fehlen — der naechste
Ansichtswechsel wirft. Galt schon fuer die 10 lazy Views, traf durch P0 nun auch
die Startseite. lib/veralteteVersion.ts faengt Vites `vite:preloadError` ab und
laedt EINMAL neu (Sperre in sessionStorage gegen Endlosschleife).
## Nachgemessen
Start-Chunk gzip 111 411 B · dist gesamt 1 480 097 B (beide im Ampel-Budget)
tsc --noEmit sauber · 17/17 Tests gruen · ESLint 0 Fehler
Im echten Browser gegen das lokale Backend geprueft: Einstellungen holen den
Token-Zustand von der Box, kein Passwort-Feld mehr, Knoepfe korrekt gesperrt,
beide Cockpit-Diagramme rendern (Achsen + Zeitachse sichtbar).
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
361 lines
359 KiB
JavaScript
361 lines
359 KiB
JavaScript
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/LiveAreaChartImpl-Bb72EW29.js","assets/string-DoZi9Vij.js","assets/ModelsView-BYDzvdzC.js","assets/JobsBar-B1nmMx5i.js","assets/code-xml-DZ6lLr-w.js","assets/rotate-ccw-Dx0bZ_kA.js","assets/zap-B_VSdjfC.js","assets/chevron-down-D5zhK_UQ.js","assets/layers-DCwnbkXd.js","assets/ConnectView-Cz-npKrg.js","assets/GuideView-CP1Y1rbp.js","assets/AuftragsbuchView-C0bzCKZ0.js","assets/SectionLabel-R1yae0WQ.js","assets/IdeenView-wVxyfCCm.js","assets/SkillsView-C5MWeKc5.js","assets/ChronikView-Bz_yVFvS.js","assets/WissenView-DOJLqZxA.js"])))=>i.map(i=>d[i]);
|
||
var Nv=Object.defineProperty;var ih=r=>{throw TypeError(r)};var jv=(r,s,o)=>s in r?Nv(r,s,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[s]=o;var Qo=(r,s,o)=>jv(r,typeof s!="symbol"?s+"":s,o),au=(r,s,o)=>s.has(r)||ih("Cannot "+o);var E=(r,s,o)=>(au(r,s,"read from private field"),o?o.call(r):s.get(r)),pe=(r,s,o)=>s.has(r)?ih("Cannot add the same private member more than once"):s instanceof WeakSet?s.add(r):s.set(r,o),J=(r,s,o,a)=>(au(r,s,"write to private field"),a?a.call(r,o):s.set(r,o),o),_e=(r,s,o)=>(au(r,s,"access private method"),o);var Ko=(r,s,o,a)=>({set _(u){J(r,s,u,o)},get _(){return E(r,s,a)}});function Cv(r,s){for(var o=0;o<s.length;o++){const a=s[o];if(typeof a!="string"&&!Array.isArray(a)){for(const u in a)if(u!=="default"&&!(u in r)){const f=Object.getOwnPropertyDescriptor(a,u);f&&Object.defineProperty(r,u,f.get?f:{enumerable:!0,get:()=>a[u]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}(function(){const s=document.createElement("link").relList;if(s&&s.supports&&s.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))a(u);new MutationObserver(u=>{for(const f of u)if(f.type==="childList")for(const m of f.addedNodes)m.tagName==="LINK"&&m.rel==="modulepreload"&&a(m)}).observe(document,{childList:!0,subtree:!0});function o(u){const f={};return u.integrity&&(f.integrity=u.integrity),u.referrerPolicy&&(f.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?f.credentials="include":u.crossOrigin==="anonymous"?f.credentials="omit":f.credentials="same-origin",f}function a(u){if(u.ep)return;u.ep=!0;const f=o(u);fetch(u.href,f)}})();function ap(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var uu={exports:{}},fi={},cu={exports:{}},je={};/**
|
||
* @license React
|
||
* react.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var oh;function _v(){if(oh)return je;oh=1;var r=Symbol.for("react.element"),s=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),f=Symbol.for("react.provider"),m=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),k=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),x=Symbol.iterator;function P(C){return C===null||typeof C!="object"?null:(C=x&&C[x]||C["@@iterator"],typeof C=="function"?C:null)}var _={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},D=Object.assign,b={};function R(C,N,q){this.props=C,this.context=N,this.refs=b,this.updater=q||_}R.prototype.isReactComponent={},R.prototype.setState=function(C,N){if(typeof C!="object"&&typeof C!="function"&&C!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,C,N,"setState")},R.prototype.forceUpdate=function(C){this.updater.enqueueForceUpdate(this,C,"forceUpdate")};function A(){}A.prototype=R.prototype;function I(C,N,q){this.props=C,this.context=N,this.refs=b,this.updater=q||_}var V=I.prototype=new A;V.constructor=I,D(V,R.prototype),V.isPureReactComponent=!0;var z=Array.isArray,K=Object.prototype.hasOwnProperty,G={current:null},ue={key:!0,ref:!0,__self:!0,__source:!0};function oe(C,N,q){var Y,W={},se=null,de=null;if(N!=null)for(Y in N.ref!==void 0&&(de=N.ref),N.key!==void 0&&(se=""+N.key),N)K.call(N,Y)&&!ue.hasOwnProperty(Y)&&(W[Y]=N[Y]);var ye=arguments.length-2;if(ye===1)W.children=q;else if(1<ye){for(var we=Array(ye),Ge=0;Ge<ye;Ge++)we[Ge]=arguments[Ge+2];W.children=we}if(C&&C.defaultProps)for(Y in ye=C.defaultProps,ye)W[Y]===void 0&&(W[Y]=ye[Y]);return{$$typeof:r,type:C,key:se,ref:de,props:W,_owner:G.current}}function ee(C,N){return{$$typeof:r,type:C.type,key:N,ref:C.ref,props:C.props,_owner:C._owner}}function me(C){return typeof C=="object"&&C!==null&&C.$$typeof===r}function ke(C){var N={"=":"=0",":":"=2"};return"$"+C.replace(/[=:]/g,function(q){return N[q]})}var le=/\/+/g;function Le(C,N){return typeof C=="object"&&C!==null&&C.key!=null?ke(""+C.key):N.toString(36)}function Z(C,N,q,Y,W){var se=typeof C;(se==="undefined"||se==="boolean")&&(C=null);var de=!1;if(C===null)de=!0;else switch(se){case"string":case"number":de=!0;break;case"object":switch(C.$$typeof){case r:case s:de=!0}}if(de)return de=C,W=W(de),C=Y===""?"."+Le(de,0):Y,z(W)?(q="",C!=null&&(q=C.replace(le,"$&/")+"/"),Z(W,N,q,"",function(Ge){return Ge})):W!=null&&(me(W)&&(W=ee(W,q+(!W.key||de&&de.key===W.key?"":(""+W.key).replace(le,"$&/")+"/")+C)),N.push(W)),1;if(de=0,Y=Y===""?".":Y+":",z(C))for(var ye=0;ye<C.length;ye++){se=C[ye];var we=Y+Le(se,ye);de+=Z(se,N,q,we,W)}else if(we=P(C),typeof we=="function")for(C=we.call(C),ye=0;!(se=C.next()).done;)se=se.value,we=Y+Le(se,ye++),de+=Z(se,N,q,we,W);else if(se==="object")throw N=String(C),Error("Objects are not valid as a React child (found: "+(N==="[object Object]"?"object with keys {"+Object.keys(C).join(", ")+"}":N)+"). If you meant to render a collection of children, use an array instead.");return de}function ce(C,N,q){if(C==null)return C;var Y=[],W=0;return Z(C,Y,"","",function(se){return N.call(q,se,W++)}),Y}function Ce(C){if(C._status===-1){var N=C._result;N=N(),N.then(function(q){(C._status===0||C._status===-1)&&(C._status=1,C._result=q)},function(q){(C._status===0||C._status===-1)&&(C._status=2,C._result=q)}),C._status===-1&&(C._status=0,C._result=N)}if(C._status===1)return C._result.default;throw C._result}var Ne={current:null},F={transition:null},ne={ReactCurrentDispatcher:Ne,ReactCurrentBatchConfig:F,ReactCurrentOwner:G};function Q(){throw Error("act(...) is not supported in production builds of React.")}return je.Children={map:ce,forEach:function(C,N,q){ce(C,function(){N.apply(this,arguments)},q)},count:function(C){var N=0;return ce(C,function(){N++}),N},toArray:function(C){return ce(C,function(N){return N})||[]},only:function(C){if(!me(C))throw Error("React.Children.only expected to receive a single React element child.");return C}},je.Component=R,je.Fragment=o,je.Profiler=u,je.PureComponent=I,je.StrictMode=a,je.Suspense=y,je.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ne,je.act=Q,je.cloneElement=function(C,N,q){if(C==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+C+".");var Y=D({},C.props),W=C.key,se=C.ref,de=C._owner;if(N!=null){if(N.ref!==void 0&&(se=N.ref,de=G.current),N.key!==void 0&&(W=""+N.key),C.type&&C.type.defaultProps)var ye=C.type.defaultProps;for(we in N)K.call(N,we)&&!ue.hasOwnProperty(we)&&(Y[we]=N[we]===void 0&&ye!==void 0?ye[we]:N[we])}var we=arguments.length-2;if(we===1)Y.children=q;else if(1<we){ye=Array(we);for(var Ge=0;Ge<we;Ge++)ye[Ge]=arguments[Ge+2];Y.children=ye}return{$$typeof:r,type:C.type,key:W,ref:se,props:Y,_owner:de}},je.createContext=function(C){return C={$$typeof:m,_currentValue:C,_currentValue2:C,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},C.Provider={$$typeof:f,_context:C},C.Consumer=C},je.createElement=oe,je.createFactory=function(C){var N=oe.bind(null,C);return N.type=C,N},je.createRef=function(){return{current:null}},je.forwardRef=function(C){return{$$typeof:h,render:C}},je.isValidElement=me,je.lazy=function(C){return{$$typeof:w,_payload:{_status:-1,_result:C},_init:Ce}},je.memo=function(C,N){return{$$typeof:k,type:C,compare:N===void 0?null:N}},je.startTransition=function(C){var N=F.transition;F.transition={};try{C()}finally{F.transition=N}},je.unstable_act=Q,je.useCallback=function(C,N){return Ne.current.useCallback(C,N)},je.useContext=function(C){return Ne.current.useContext(C)},je.useDebugValue=function(){},je.useDeferredValue=function(C){return Ne.current.useDeferredValue(C)},je.useEffect=function(C,N){return Ne.current.useEffect(C,N)},je.useId=function(){return Ne.current.useId()},je.useImperativeHandle=function(C,N,q){return Ne.current.useImperativeHandle(C,N,q)},je.useInsertionEffect=function(C,N){return Ne.current.useInsertionEffect(C,N)},je.useLayoutEffect=function(C,N){return Ne.current.useLayoutEffect(C,N)},je.useMemo=function(C,N){return Ne.current.useMemo(C,N)},je.useReducer=function(C,N,q){return Ne.current.useReducer(C,N,q)},je.useRef=function(C){return Ne.current.useRef(C)},je.useState=function(C){return Ne.current.useState(C)},je.useSyncExternalStore=function(C,N,q){return Ne.current.useSyncExternalStore(C,N,q)},je.useTransition=function(){return Ne.current.useTransition()},je.version="18.3.1",je}var lh;function Xu(){return lh||(lh=1,cu.exports=_v()),cu.exports}/**
|
||
* @license React
|
||
* react-jsx-runtime.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var ah;function Pv(){if(ah)return fi;ah=1;var r=Xu(),s=Symbol.for("react.element"),o=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,u=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,f={key:!0,ref:!0,__self:!0,__source:!0};function m(h,y,k){var w,x={},P=null,_=null;k!==void 0&&(P=""+k),y.key!==void 0&&(P=""+y.key),y.ref!==void 0&&(_=y.ref);for(w in y)a.call(y,w)&&!f.hasOwnProperty(w)&&(x[w]=y[w]);if(h&&h.defaultProps)for(w in y=h.defaultProps,y)x[w]===void 0&&(x[w]=y[w]);return{$$typeof:s,type:h,key:P,ref:_,props:x,_owner:u.current}}return fi.Fragment=o,fi.jsx=m,fi.jsxs=m,fi}var uh;function Rv(){return uh||(uh=1,uu.exports=Pv()),uu.exports}var d=Rv(),g=Xu();const Ju=ap(g),ec=Cv({__proto__:null,default:Ju},[g]);var qo={},du={exports:{}},wt={},fu={exports:{}},hu={};/**
|
||
* @license React
|
||
* scheduler.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var ch;function Mv(){return ch||(ch=1,(function(r){function s(F,ne){var Q=F.length;F.push(ne);e:for(;0<Q;){var C=Q-1>>>1,N=F[C];if(0<u(N,ne))F[C]=ne,F[Q]=N,Q=C;else break e}}function o(F){return F.length===0?null:F[0]}function a(F){if(F.length===0)return null;var ne=F[0],Q=F.pop();if(Q!==ne){F[0]=Q;e:for(var C=0,N=F.length,q=N>>>1;C<q;){var Y=2*(C+1)-1,W=F[Y],se=Y+1,de=F[se];if(0>u(W,Q))se<N&&0>u(de,W)?(F[C]=de,F[se]=Q,C=se):(F[C]=W,F[Y]=Q,C=Y);else if(se<N&&0>u(de,Q))F[C]=de,F[se]=Q,C=se;else break e}}return ne}function u(F,ne){var Q=F.sortIndex-ne.sortIndex;return Q!==0?Q:F.id-ne.id}if(typeof performance=="object"&&typeof performance.now=="function"){var f=performance;r.unstable_now=function(){return f.now()}}else{var m=Date,h=m.now();r.unstable_now=function(){return m.now()-h}}var y=[],k=[],w=1,x=null,P=3,_=!1,D=!1,b=!1,R=typeof setTimeout=="function"?setTimeout:null,A=typeof clearTimeout=="function"?clearTimeout:null,I=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function V(F){for(var ne=o(k);ne!==null;){if(ne.callback===null)a(k);else if(ne.startTime<=F)a(k),ne.sortIndex=ne.expirationTime,s(y,ne);else break;ne=o(k)}}function z(F){if(b=!1,V(F),!D)if(o(y)!==null)D=!0,Ce(K);else{var ne=o(k);ne!==null&&Ne(z,ne.startTime-F)}}function K(F,ne){D=!1,b&&(b=!1,A(oe),oe=-1),_=!0;var Q=P;try{for(V(ne),x=o(y);x!==null&&(!(x.expirationTime>ne)||F&&!ke());){var C=x.callback;if(typeof C=="function"){x.callback=null,P=x.priorityLevel;var N=C(x.expirationTime<=ne);ne=r.unstable_now(),typeof N=="function"?x.callback=N:x===o(y)&&a(y),V(ne)}else a(y);x=o(y)}if(x!==null)var q=!0;else{var Y=o(k);Y!==null&&Ne(z,Y.startTime-ne),q=!1}return q}finally{x=null,P=Q,_=!1}}var G=!1,ue=null,oe=-1,ee=5,me=-1;function ke(){return!(r.unstable_now()-me<ee)}function le(){if(ue!==null){var F=r.unstable_now();me=F;var ne=!0;try{ne=ue(!0,F)}finally{ne?Le():(G=!1,ue=null)}}else G=!1}var Le;if(typeof I=="function")Le=function(){I(le)};else if(typeof MessageChannel<"u"){var Z=new MessageChannel,ce=Z.port2;Z.port1.onmessage=le,Le=function(){ce.postMessage(null)}}else Le=function(){R(le,0)};function Ce(F){ue=F,G||(G=!0,Le())}function Ne(F,ne){oe=R(function(){F(r.unstable_now())},ne)}r.unstable_IdlePriority=5,r.unstable_ImmediatePriority=1,r.unstable_LowPriority=4,r.unstable_NormalPriority=3,r.unstable_Profiling=null,r.unstable_UserBlockingPriority=2,r.unstable_cancelCallback=function(F){F.callback=null},r.unstable_continueExecution=function(){D||_||(D=!0,Ce(K))},r.unstable_forceFrameRate=function(F){0>F||125<F?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ee=0<F?Math.floor(1e3/F):5},r.unstable_getCurrentPriorityLevel=function(){return P},r.unstable_getFirstCallbackNode=function(){return o(y)},r.unstable_next=function(F){switch(P){case 1:case 2:case 3:var ne=3;break;default:ne=P}var Q=P;P=ne;try{return F()}finally{P=Q}},r.unstable_pauseExecution=function(){},r.unstable_requestPaint=function(){},r.unstable_runWithPriority=function(F,ne){switch(F){case 1:case 2:case 3:case 4:case 5:break;default:F=3}var Q=P;P=F;try{return ne()}finally{P=Q}},r.unstable_scheduleCallback=function(F,ne,Q){var C=r.unstable_now();switch(typeof Q=="object"&&Q!==null?(Q=Q.delay,Q=typeof Q=="number"&&0<Q?C+Q:C):Q=C,F){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=Q+N,F={id:w++,callback:ne,priorityLevel:F,startTime:Q,expirationTime:N,sortIndex:-1},Q>C?(F.sortIndex=Q,s(k,F),o(y)===null&&F===o(k)&&(b?(A(oe),oe=-1):b=!0,Ne(z,Q-C))):(F.sortIndex=N,s(y,F),D||_||(D=!0,Ce(K))),F},r.unstable_shouldYield=ke,r.unstable_wrapCallback=function(F){var ne=P;return function(){var Q=P;P=ne;try{return F.apply(this,arguments)}finally{P=Q}}}})(hu)),hu}var dh;function Ov(){return dh||(dh=1,fu.exports=Mv()),fu.exports}/**
|
||
* @license React
|
||
* react-dom.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var fh;function Tv(){if(fh)return wt;fh=1;var r=Xu(),s=Ov();function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var a=new Set,u={};function f(e,t){m(e,t),m(e+"Capture",t)}function m(e,t){for(u[e]=t,e=0;e<t.length;e++)a.add(t[e])}var h=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),y=Object.prototype.hasOwnProperty,k=/^[: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]*$/,w={},x={};function P(e){return y.call(x,e)?!0:y.call(w,e)?!1:k.test(e)?x[e]=!0:(w[e]=!0,!1)}function _(e,t,n,i){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return i?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function D(e,t,n,i){if(t===null||typeof t>"u"||_(e,t,n,i))return!0;if(i)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function b(e,t,n,i,l,c,p){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=i,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=c,this.removeEmptyString=p}var R={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){R[e]=new b(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];R[t]=new b(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){R[e]=new b(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){R[e]=new b(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){R[e]=new b(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){R[e]=new b(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){R[e]=new b(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){R[e]=new b(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){R[e]=new b(e,5,!1,e.toLowerCase(),null,!1,!1)});var A=/[\-:]([a-z])/g;function I(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(A,I);R[t]=new b(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(A,I);R[t]=new b(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(A,I);R[t]=new b(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){R[e]=new b(e,1,!1,e.toLowerCase(),null,!1,!1)}),R.xlinkHref=new b("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){R[e]=new b(e,1,!1,e.toLowerCase(),null,!0,!0)});function V(e,t,n,i){var l=R.hasOwnProperty(t)?R[t]:null;(l!==null?l.type!==0:i||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(D(t,n,l,i)&&(n=null),i||l===null?P(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):l.mustUseProperty?e[l.propertyName]=n===null?l.type===3?!1:"":n:(t=l.attributeName,i=l.attributeNamespace,n===null?e.removeAttribute(t):(l=l.type,n=l===3||l===4&&n===!0?"":""+n,i?e.setAttributeNS(i,t,n):e.setAttribute(t,n))))}var z=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,K=Symbol.for("react.element"),G=Symbol.for("react.portal"),ue=Symbol.for("react.fragment"),oe=Symbol.for("react.strict_mode"),ee=Symbol.for("react.profiler"),me=Symbol.for("react.provider"),ke=Symbol.for("react.context"),le=Symbol.for("react.forward_ref"),Le=Symbol.for("react.suspense"),Z=Symbol.for("react.suspense_list"),ce=Symbol.for("react.memo"),Ce=Symbol.for("react.lazy"),Ne=Symbol.for("react.offscreen"),F=Symbol.iterator;function ne(e){return e===null||typeof e!="object"?null:(e=F&&e[F]||e["@@iterator"],typeof e=="function"?e:null)}var Q=Object.assign,C;function N(e){if(C===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);C=t&&t[1]||""}return`
|
||
`+C+e}var q=!1;function Y(e,t){if(!e||q)return"";q=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(T){var i=T}Reflect.construct(e,[],t)}else{try{t.call()}catch(T){i=T}e.call(t.prototype)}else{try{throw Error()}catch(T){i=T}e()}}catch(T){if(T&&i&&typeof T.stack=="string"){for(var l=T.stack.split(`
|
||
`),c=i.stack.split(`
|
||
`),p=l.length-1,v=c.length-1;1<=p&&0<=v&&l[p]!==c[v];)v--;for(;1<=p&&0<=v;p--,v--)if(l[p]!==c[v]){if(p!==1||v!==1)do if(p--,v--,0>v||l[p]!==c[v]){var S=`
|
||
`+l[p].replace(" at new "," at ");return e.displayName&&S.includes("<anonymous>")&&(S=S.replace("<anonymous>",e.displayName)),S}while(1<=p&&0<=v);break}}}finally{q=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?N(e):""}function W(e){switch(e.tag){case 5:return N(e.type);case 16:return N("Lazy");case 13:return N("Suspense");case 19:return N("SuspenseList");case 0:case 2:case 15:return e=Y(e.type,!1),e;case 11:return e=Y(e.type.render,!1),e;case 1:return e=Y(e.type,!0),e;default:return""}}function se(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ue:return"Fragment";case G:return"Portal";case ee:return"Profiler";case oe:return"StrictMode";case Le:return"Suspense";case Z:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case ke:return(e.displayName||"Context")+".Consumer";case me:return(e._context.displayName||"Context")+".Provider";case le:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ce:return t=e.displayName||null,t!==null?t:se(e.type)||"Memo";case Ce:t=e._payload,e=e._init;try{return se(e(t))}catch{}}return null}function de(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return se(t);case 8:return t===oe?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function ye(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function we(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Ge(e){var t=we(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),i=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,c=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(p){i=""+p,c.call(this,p)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(p){i=""+p},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Sr(e){e._valueTracker||(e._valueTracker=Ge(e))}function Ns(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=we(e)?e.checked?"true":"false":e.value),e=i,e!==n?(t.setValue(e),!0):!1}function Er(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}}function rn(e,t){var n=t.checked;return Q({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function js(e,t){var n=t.defaultValue==null?"":t.defaultValue,i=t.checked!=null?t.checked:t.defaultChecked;n=ye(t.value!=null?t.value:n),e._wrapperState={initialChecked:i,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Nr(e,t){t=t.checked,t!=null&&V(e,"checked",t,!1)}function jr(e,t){Nr(e,t);var n=ye(t.value),i=t.type;if(n!=null)i==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(i==="submit"||i==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?L(e,t.type,n):t.hasOwnProperty("defaultValue")&&L(e,t.type,ye(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Cs(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var i=t.type;if(!(i!=="submit"&&i!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function L(e,t,n){(t!=="number"||Er(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var xe=Array.isArray;function ze(e,t,n,i){if(e=e.options,t){t={};for(var l=0;l<n.length;l++)t["$"+n[l]]=!0;for(n=0;n<e.length;n++)l=t.hasOwnProperty("$"+e[n].value),e[n].selected!==l&&(e[n].selected=l),l&&i&&(e[n].defaultSelected=!0)}else{for(n=""+ye(n),t=null,l=0;l<e.length;l++){if(e[l].value===n){e[l].selected=!0,i&&(e[l].defaultSelected=!0);return}t!==null||e[l].disabled||(t=e[l])}t!==null&&(t.selected=!0)}}function yl(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(o(91));return Q({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function pc(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(o(92));if(xe(n)){if(1<n.length)throw Error(o(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:ye(n)}}function mc(e,t){var n=ye(t.value),i=ye(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),i!=null&&(e.defaultValue=""+i)}function gc(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function vc(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function xl(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?vc(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var zi,yc=(function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,i,l){MSApp.execUnsafeLocalFunction(function(){return e(t,n,i,l)})}:e})(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(zi=zi||document.createElement("div"),zi.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=zi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function _s(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ps={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Pm=["Webkit","ms","Moz","O"];Object.keys(Ps).forEach(function(e){Pm.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ps[t]=Ps[e]})});function xc(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Ps.hasOwnProperty(e)&&Ps[e]?(""+t).trim():t+"px"}function wc(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var i=n.indexOf("--")===0,l=xc(n,t[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,l):e[n]=l}}var Rm=Q({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function wl(e,t){if(t){if(Rm[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(o(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(o(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(o(61))}if(t.style!=null&&typeof t.style!="object")throw Error(o(62))}}function kl(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 bl=null;function Sl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var El=null,Cr=null,_r=null;function kc(e){if(e=Ys(e)){if(typeof El!="function")throw Error(o(280));var t=e.stateNode;t&&(t=oo(t),El(e.stateNode,e.type,t))}}function bc(e){Cr?_r?_r.push(e):_r=[e]:Cr=e}function Sc(){if(Cr){var e=Cr,t=_r;if(_r=Cr=null,kc(e),t)for(e=0;e<t.length;e++)kc(t[e])}}function Ec(e,t){return e(t)}function Nc(){}var Nl=!1;function jc(e,t,n){if(Nl)return e(t,n);Nl=!0;try{return Ec(e,t,n)}finally{Nl=!1,(Cr!==null||_r!==null)&&(Nc(),Sc())}}function Rs(e,t){var n=e.stateNode;if(n===null)return null;var i=oo(n);if(i===null)return null;n=i[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(i=!i.disabled)||(e=e.type,i=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!i;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(o(231,t,typeof n));return n}var jl=!1;if(h)try{var Ms={};Object.defineProperty(Ms,"passive",{get:function(){jl=!0}}),window.addEventListener("test",Ms,Ms),window.removeEventListener("test",Ms,Ms)}catch{jl=!1}function Mm(e,t,n,i,l,c,p,v,S){var T=Array.prototype.slice.call(arguments,3);try{t.apply(n,T)}catch($){this.onError($)}}var Os=!1,Fi=null,Ii=!1,Cl=null,Om={onError:function(e){Os=!0,Fi=e}};function Tm(e,t,n,i,l,c,p,v,S){Os=!1,Fi=null,Mm.apply(Om,arguments)}function Lm(e,t,n,i,l,c,p,v,S){if(Tm.apply(this,arguments),Os){if(Os){var T=Fi;Os=!1,Fi=null}else throw Error(o(198));Ii||(Ii=!0,Cl=T)}}function Xn(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function Cc(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function _c(e){if(Xn(e)!==e)throw Error(o(188))}function Dm(e){var t=e.alternate;if(!t){if(t=Xn(e),t===null)throw Error(o(188));return t!==e?null:e}for(var n=e,i=t;;){var l=n.return;if(l===null)break;var c=l.alternate;if(c===null){if(i=l.return,i!==null){n=i;continue}break}if(l.child===c.child){for(c=l.child;c;){if(c===n)return _c(l),e;if(c===i)return _c(l),t;c=c.sibling}throw Error(o(188))}if(n.return!==i.return)n=l,i=c;else{for(var p=!1,v=l.child;v;){if(v===n){p=!0,n=l,i=c;break}if(v===i){p=!0,i=l,n=c;break}v=v.sibling}if(!p){for(v=c.child;v;){if(v===n){p=!0,n=c,i=l;break}if(v===i){p=!0,i=c,n=l;break}v=v.sibling}if(!p)throw Error(o(189))}}if(n.alternate!==i)throw Error(o(190))}if(n.tag!==3)throw Error(o(188));return n.stateNode.current===n?e:t}function Pc(e){return e=Dm(e),e!==null?Rc(e):null}function Rc(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=Rc(e);if(t!==null)return t;e=e.sibling}return null}var Mc=s.unstable_scheduleCallback,Oc=s.unstable_cancelCallback,Am=s.unstable_shouldYield,zm=s.unstable_requestPaint,Ke=s.unstable_now,Fm=s.unstable_getCurrentPriorityLevel,_l=s.unstable_ImmediatePriority,Tc=s.unstable_UserBlockingPriority,Ui=s.unstable_NormalPriority,Im=s.unstable_LowPriority,Lc=s.unstable_IdlePriority,$i=null,Kt=null;function Um(e){if(Kt&&typeof Kt.onCommitFiberRoot=="function")try{Kt.onCommitFiberRoot($i,e,void 0,(e.current.flags&128)===128)}catch{}}var zt=Math.clz32?Math.clz32:Vm,$m=Math.log,Bm=Math.LN2;function Vm(e){return e>>>=0,e===0?32:31-($m(e)/Bm|0)|0}var Bi=64,Vi=4194304;function Ts(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Hi(e,t){var n=e.pendingLanes;if(n===0)return 0;var i=0,l=e.suspendedLanes,c=e.pingedLanes,p=n&268435455;if(p!==0){var v=p&~l;v!==0?i=Ts(v):(c&=p,c!==0&&(i=Ts(c)))}else p=n&~l,p!==0?i=Ts(p):c!==0&&(i=Ts(c));if(i===0)return 0;if(t!==0&&t!==i&&(t&l)===0&&(l=i&-i,c=t&-t,l>=c||l===16&&(c&4194240)!==0))return t;if((i&4)!==0&&(i|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=i;0<t;)n=31-zt(t),l=1<<n,i|=e[n],t&=~l;return i}function Hm(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Wm(e,t){for(var n=e.suspendedLanes,i=e.pingedLanes,l=e.expirationTimes,c=e.pendingLanes;0<c;){var p=31-zt(c),v=1<<p,S=l[p];S===-1?((v&n)===0||(v&i)!==0)&&(l[p]=Hm(v,t)):S<=t&&(e.expiredLanes|=v),c&=~v}}function Pl(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Dc(){var e=Bi;return Bi<<=1,(Bi&4194240)===0&&(Bi=64),e}function Rl(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ls(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-zt(t),e[t]=n}function Qm(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var i=e.eventTimes;for(e=e.expirationTimes;0<n;){var l=31-zt(n),c=1<<l;t[l]=0,i[l]=-1,e[l]=-1,n&=~c}}function Ml(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var i=31-zt(n),l=1<<i;l&t|e[i]&t&&(e[i]|=t),n&=~l}}var De=0;function Ac(e){return e&=-e,1<e?4<e?(e&268435455)!==0?16:536870912:4:1}var zc,Ol,Fc,Ic,Uc,Tl=!1,Wi=[],yn=null,xn=null,wn=null,Ds=new Map,As=new Map,kn=[],Km="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 submit".split(" ");function $c(e,t){switch(e){case"focusin":case"focusout":yn=null;break;case"dragenter":case"dragleave":xn=null;break;case"mouseover":case"mouseout":wn=null;break;case"pointerover":case"pointerout":Ds.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":As.delete(t.pointerId)}}function zs(e,t,n,i,l,c){return e===null||e.nativeEvent!==c?(e={blockedOn:t,domEventName:n,eventSystemFlags:i,nativeEvent:c,targetContainers:[l]},t!==null&&(t=Ys(t),t!==null&&Ol(t)),e):(e.eventSystemFlags|=i,t=e.targetContainers,l!==null&&t.indexOf(l)===-1&&t.push(l),e)}function qm(e,t,n,i,l){switch(t){case"focusin":return yn=zs(yn,e,t,n,i,l),!0;case"dragenter":return xn=zs(xn,e,t,n,i,l),!0;case"mouseover":return wn=zs(wn,e,t,n,i,l),!0;case"pointerover":var c=l.pointerId;return Ds.set(c,zs(Ds.get(c)||null,e,t,n,i,l)),!0;case"gotpointercapture":return c=l.pointerId,As.set(c,zs(As.get(c)||null,e,t,n,i,l)),!0}return!1}function Bc(e){var t=Jn(e.target);if(t!==null){var n=Xn(t);if(n!==null){if(t=n.tag,t===13){if(t=Cc(n),t!==null){e.blockedOn=t,Uc(e.priority,function(){Fc(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Qi(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Dl(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var i=new n.constructor(n.type,n);bl=i,n.target.dispatchEvent(i),bl=null}else return t=Ys(n),t!==null&&Ol(t),e.blockedOn=n,!1;t.shift()}return!0}function Vc(e,t,n){Qi(e)&&n.delete(t)}function Gm(){Tl=!1,yn!==null&&Qi(yn)&&(yn=null),xn!==null&&Qi(xn)&&(xn=null),wn!==null&&Qi(wn)&&(wn=null),Ds.forEach(Vc),As.forEach(Vc)}function Fs(e,t){e.blockedOn===t&&(e.blockedOn=null,Tl||(Tl=!0,s.unstable_scheduleCallback(s.unstable_NormalPriority,Gm)))}function Is(e){function t(l){return Fs(l,e)}if(0<Wi.length){Fs(Wi[0],e);for(var n=1;n<Wi.length;n++){var i=Wi[n];i.blockedOn===e&&(i.blockedOn=null)}}for(yn!==null&&Fs(yn,e),xn!==null&&Fs(xn,e),wn!==null&&Fs(wn,e),Ds.forEach(t),As.forEach(t),n=0;n<kn.length;n++)i=kn[n],i.blockedOn===e&&(i.blockedOn=null);for(;0<kn.length&&(n=kn[0],n.blockedOn===null);)Bc(n),n.blockedOn===null&&kn.shift()}var Pr=z.ReactCurrentBatchConfig,Ki=!0;function Zm(e,t,n,i){var l=De,c=Pr.transition;Pr.transition=null;try{De=1,Ll(e,t,n,i)}finally{De=l,Pr.transition=c}}function Ym(e,t,n,i){var l=De,c=Pr.transition;Pr.transition=null;try{De=4,Ll(e,t,n,i)}finally{De=l,Pr.transition=c}}function Ll(e,t,n,i){if(Ki){var l=Dl(e,t,n,i);if(l===null)Xl(e,t,i,qi,n),$c(e,i);else if(qm(l,e,t,n,i))i.stopPropagation();else if($c(e,i),t&4&&-1<Km.indexOf(e)){for(;l!==null;){var c=Ys(l);if(c!==null&&zc(c),c=Dl(e,t,n,i),c===null&&Xl(e,t,i,qi,n),c===l)break;l=c}l!==null&&i.stopPropagation()}else Xl(e,t,i,null,n)}}var qi=null;function Dl(e,t,n,i){if(qi=null,e=Sl(i),e=Jn(e),e!==null)if(t=Xn(e),t===null)e=null;else if(n=t.tag,n===13){if(e=Cc(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return qi=e,null}function Hc(e){switch(e){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"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 1;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"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(Fm()){case _l:return 1;case Tc:return 4;case Ui:case Im:return 16;case Lc:return 536870912;default:return 16}default:return 16}}var bn=null,Al=null,Gi=null;function Wc(){if(Gi)return Gi;var e,t=Al,n=t.length,i,l="value"in bn?bn.value:bn.textContent,c=l.length;for(e=0;e<n&&t[e]===l[e];e++);var p=n-e;for(i=1;i<=p&&t[n-i]===l[c-i];i++);return Gi=l.slice(e,1<i?1-i:void 0)}function Zi(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Yi(){return!0}function Qc(){return!1}function Et(e){function t(n,i,l,c,p){this._reactName=n,this._targetInst=l,this.type=i,this.nativeEvent=c,this.target=p,this.currentTarget=null;for(var v in e)e.hasOwnProperty(v)&&(n=e[v],this[v]=n?n(c):c[v]);return this.isDefaultPrevented=(c.defaultPrevented!=null?c.defaultPrevented:c.returnValue===!1)?Yi:Qc,this.isPropagationStopped=Qc,this}return Q(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Yi)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Yi)},persist:function(){},isPersistent:Yi}),t}var Rr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},zl=Et(Rr),Us=Q({},Rr,{view:0,detail:0}),Xm=Et(Us),Fl,Il,$s,Xi=Q({},Us,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:$l,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!==$s&&($s&&e.type==="mousemove"?(Fl=e.screenX-$s.screenX,Il=e.screenY-$s.screenY):Il=Fl=0,$s=e),Fl)},movementY:function(e){return"movementY"in e?e.movementY:Il}}),Kc=Et(Xi),Jm=Q({},Xi,{dataTransfer:0}),eg=Et(Jm),tg=Q({},Us,{relatedTarget:0}),Ul=Et(tg),ng=Q({},Rr,{animationName:0,elapsedTime:0,pseudoElement:0}),rg=Et(ng),sg=Q({},Rr,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),ig=Et(sg),og=Q({},Rr,{data:0}),qc=Et(og),lg={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},ag={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"},ug={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function cg(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=ug[e])?!!t[e]:!1}function $l(){return cg}var dg=Q({},Us,{key:function(e){if(e.key){var t=lg[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Zi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?ag[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:$l,charCode:function(e){return e.type==="keypress"?Zi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Zi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),fg=Et(dg),hg=Q({},Xi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Gc=Et(hg),pg=Q({},Us,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:$l}),mg=Et(pg),gg=Q({},Rr,{propertyName:0,elapsedTime:0,pseudoElement:0}),vg=Et(gg),yg=Q({},Xi,{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}),xg=Et(yg),wg=[9,13,27,32],Bl=h&&"CompositionEvent"in window,Bs=null;h&&"documentMode"in document&&(Bs=document.documentMode);var kg=h&&"TextEvent"in window&&!Bs,Zc=h&&(!Bl||Bs&&8<Bs&&11>=Bs),Yc=" ",Xc=!1;function Jc(e,t){switch(e){case"keyup":return wg.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ed(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Mr=!1;function bg(e,t){switch(e){case"compositionend":return ed(t);case"keypress":return t.which!==32?null:(Xc=!0,Yc);case"textInput":return e=t.data,e===Yc&&Xc?null:e;default:return null}}function Sg(e,t){if(Mr)return e==="compositionend"||!Bl&&Jc(e,t)?(e=Wc(),Gi=Al=bn=null,Mr=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Zc&&t.locale!=="ko"?null:t.data;default:return null}}var Eg={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 td(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Eg[e.type]:t==="textarea"}function nd(e,t,n,i){bc(i),t=ro(t,"onChange"),0<t.length&&(n=new zl("onChange","change",null,n,i),e.push({event:n,listeners:t}))}var Vs=null,Hs=null;function Ng(e){wd(e,0)}function Ji(e){var t=Ar(e);if(Ns(t))return e}function jg(e,t){if(e==="change")return t}var rd=!1;if(h){var Vl;if(h){var Hl="oninput"in document;if(!Hl){var sd=document.createElement("div");sd.setAttribute("oninput","return;"),Hl=typeof sd.oninput=="function"}Vl=Hl}else Vl=!1;rd=Vl&&(!document.documentMode||9<document.documentMode)}function id(){Vs&&(Vs.detachEvent("onpropertychange",od),Hs=Vs=null)}function od(e){if(e.propertyName==="value"&&Ji(Hs)){var t=[];nd(t,Hs,e,Sl(e)),jc(Ng,t)}}function Cg(e,t,n){e==="focusin"?(id(),Vs=t,Hs=n,Vs.attachEvent("onpropertychange",od)):e==="focusout"&&id()}function _g(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Ji(Hs)}function Pg(e,t){if(e==="click")return Ji(t)}function Rg(e,t){if(e==="input"||e==="change")return Ji(t)}function Mg(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Ft=typeof Object.is=="function"?Object.is:Mg;function Ws(e,t){if(Ft(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),i=Object.keys(t);if(n.length!==i.length)return!1;for(i=0;i<n.length;i++){var l=n[i];if(!y.call(t,l)||!Ft(e[l],t[l]))return!1}return!0}function ld(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function ad(e,t){var n=ld(e);e=0;for(var i;n;){if(n.nodeType===3){if(i=e+n.textContent.length,e<=t&&i>=t)return{node:n,offset:t-e};e=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=ld(n)}}function ud(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?ud(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function cd(){for(var e=window,t=Er();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Er(e.document)}return t}function Wl(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function Og(e){var t=cd(),n=e.focusedElem,i=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&ud(n.ownerDocument.documentElement,n)){if(i!==null&&Wl(n)){if(t=i.start,e=i.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var l=n.textContent.length,c=Math.min(i.start,l);i=i.end===void 0?c:Math.min(i.end,l),!e.extend&&c>i&&(l=i,i=c,c=l),l=ad(n,c);var p=ad(n,i);l&&p&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==p.node||e.focusOffset!==p.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),c>i?(e.addRange(t),e.extend(p.node,p.offset)):(t.setEnd(p.node,p.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Tg=h&&"documentMode"in document&&11>=document.documentMode,Or=null,Ql=null,Qs=null,Kl=!1;function dd(e,t,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Kl||Or==null||Or!==Er(i)||(i=Or,"selectionStart"in i&&Wl(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),Qs&&Ws(Qs,i)||(Qs=i,i=ro(Ql,"onSelect"),0<i.length&&(t=new zl("onSelect","select",null,t,n),e.push({event:t,listeners:i}),t.target=Or)))}function eo(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Tr={animationend:eo("Animation","AnimationEnd"),animationiteration:eo("Animation","AnimationIteration"),animationstart:eo("Animation","AnimationStart"),transitionend:eo("Transition","TransitionEnd")},ql={},fd={};h&&(fd=document.createElement("div").style,"AnimationEvent"in window||(delete Tr.animationend.animation,delete Tr.animationiteration.animation,delete Tr.animationstart.animation),"TransitionEvent"in window||delete Tr.transitionend.transition);function to(e){if(ql[e])return ql[e];if(!Tr[e])return e;var t=Tr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in fd)return ql[e]=t[n];return e}var hd=to("animationend"),pd=to("animationiteration"),md=to("animationstart"),gd=to("transitionend"),vd=new Map,yd="abort auxClick 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(" ");function Sn(e,t){vd.set(e,t),f(t,[e])}for(var Gl=0;Gl<yd.length;Gl++){var Zl=yd[Gl],Lg=Zl.toLowerCase(),Dg=Zl[0].toUpperCase()+Zl.slice(1);Sn(Lg,"on"+Dg)}Sn(hd,"onAnimationEnd"),Sn(pd,"onAnimationIteration"),Sn(md,"onAnimationStart"),Sn("dblclick","onDoubleClick"),Sn("focusin","onFocus"),Sn("focusout","onBlur"),Sn(gd,"onTransitionEnd"),m("onMouseEnter",["mouseout","mouseover"]),m("onMouseLeave",["mouseout","mouseover"]),m("onPointerEnter",["pointerout","pointerover"]),m("onPointerLeave",["pointerout","pointerover"]),f("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),f("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),f("onBeforeInput",["compositionend","keypress","textInput","paste"]),f("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),f("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),f("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ks="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(" "),Ag=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ks));function xd(e,t,n){var i=e.type||"unknown-event";e.currentTarget=n,Lm(i,t,void 0,e),e.currentTarget=null}function wd(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var i=e[n],l=i.event;i=i.listeners;e:{var c=void 0;if(t)for(var p=i.length-1;0<=p;p--){var v=i[p],S=v.instance,T=v.currentTarget;if(v=v.listener,S!==c&&l.isPropagationStopped())break e;xd(l,v,T),c=S}else for(p=0;p<i.length;p++){if(v=i[p],S=v.instance,T=v.currentTarget,v=v.listener,S!==c&&l.isPropagationStopped())break e;xd(l,v,T),c=S}}}if(Ii)throw e=Cl,Ii=!1,Cl=null,e}function Fe(e,t){var n=t[sa];n===void 0&&(n=t[sa]=new Set);var i=e+"__bubble";n.has(i)||(kd(t,e,2,!1),n.add(i))}function Yl(e,t,n){var i=0;t&&(i|=4),kd(n,e,i,t)}var no="_reactListening"+Math.random().toString(36).slice(2);function qs(e){if(!e[no]){e[no]=!0,a.forEach(function(n){n!=="selectionchange"&&(Ag.has(n)||Yl(n,!1,e),Yl(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[no]||(t[no]=!0,Yl("selectionchange",!1,t))}}function kd(e,t,n,i){switch(Hc(t)){case 1:var l=Zm;break;case 4:l=Ym;break;default:l=Ll}n=l.bind(null,t,n,e),l=void 0,!jl||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(l=!0),i?l!==void 0?e.addEventListener(t,n,{capture:!0,passive:l}):e.addEventListener(t,n,!0):l!==void 0?e.addEventListener(t,n,{passive:l}):e.addEventListener(t,n,!1)}function Xl(e,t,n,i,l){var c=i;if((t&1)===0&&(t&2)===0&&i!==null)e:for(;;){if(i===null)return;var p=i.tag;if(p===3||p===4){var v=i.stateNode.containerInfo;if(v===l||v.nodeType===8&&v.parentNode===l)break;if(p===4)for(p=i.return;p!==null;){var S=p.tag;if((S===3||S===4)&&(S=p.stateNode.containerInfo,S===l||S.nodeType===8&&S.parentNode===l))return;p=p.return}for(;v!==null;){if(p=Jn(v),p===null)return;if(S=p.tag,S===5||S===6){i=c=p;continue e}v=v.parentNode}}i=i.return}jc(function(){var T=c,$=Sl(n),B=[];e:{var U=vd.get(e);if(U!==void 0){var X=zl,re=e;switch(e){case"keypress":if(Zi(n)===0)break e;case"keydown":case"keyup":X=fg;break;case"focusin":re="focus",X=Ul;break;case"focusout":re="blur",X=Ul;break;case"beforeblur":case"afterblur":X=Ul;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":X=Kc;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":X=eg;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":X=mg;break;case hd:case pd:case md:X=rg;break;case gd:X=vg;break;case"scroll":X=Xm;break;case"wheel":X=xg;break;case"copy":case"cut":case"paste":X=ig;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":X=Gc}var ie=(t&4)!==0,qe=!ie&&e==="scroll",M=ie?U!==null?U+"Capture":null:U;ie=[];for(var j=T,O;j!==null;){O=j;var H=O.stateNode;if(O.tag===5&&H!==null&&(O=H,M!==null&&(H=Rs(j,M),H!=null&&ie.push(Gs(j,H,O)))),qe)break;j=j.return}0<ie.length&&(U=new X(U,re,null,n,$),B.push({event:U,listeners:ie}))}}if((t&7)===0){e:{if(U=e==="mouseover"||e==="pointerover",X=e==="mouseout"||e==="pointerout",U&&n!==bl&&(re=n.relatedTarget||n.fromElement)&&(Jn(re)||re[sn]))break e;if((X||U)&&(U=$.window===$?$:(U=$.ownerDocument)?U.defaultView||U.parentWindow:window,X?(re=n.relatedTarget||n.toElement,X=T,re=re?Jn(re):null,re!==null&&(qe=Xn(re),re!==qe||re.tag!==5&&re.tag!==6)&&(re=null)):(X=null,re=T),X!==re)){if(ie=Kc,H="onMouseLeave",M="onMouseEnter",j="mouse",(e==="pointerout"||e==="pointerover")&&(ie=Gc,H="onPointerLeave",M="onPointerEnter",j="pointer"),qe=X==null?U:Ar(X),O=re==null?U:Ar(re),U=new ie(H,j+"leave",X,n,$),U.target=qe,U.relatedTarget=O,H=null,Jn($)===T&&(ie=new ie(M,j+"enter",re,n,$),ie.target=O,ie.relatedTarget=qe,H=ie),qe=H,X&&re)t:{for(ie=X,M=re,j=0,O=ie;O;O=Lr(O))j++;for(O=0,H=M;H;H=Lr(H))O++;for(;0<j-O;)ie=Lr(ie),j--;for(;0<O-j;)M=Lr(M),O--;for(;j--;){if(ie===M||M!==null&&ie===M.alternate)break t;ie=Lr(ie),M=Lr(M)}ie=null}else ie=null;X!==null&&bd(B,U,X,ie,!1),re!==null&&qe!==null&&bd(B,qe,re,ie,!0)}}e:{if(U=T?Ar(T):window,X=U.nodeName&&U.nodeName.toLowerCase(),X==="select"||X==="input"&&U.type==="file")var ae=jg;else if(td(U))if(rd)ae=Rg;else{ae=_g;var fe=Cg}else(X=U.nodeName)&&X.toLowerCase()==="input"&&(U.type==="checkbox"||U.type==="radio")&&(ae=Pg);if(ae&&(ae=ae(e,T))){nd(B,ae,n,$);break e}fe&&fe(e,U,T),e==="focusout"&&(fe=U._wrapperState)&&fe.controlled&&U.type==="number"&&L(U,"number",U.value)}switch(fe=T?Ar(T):window,e){case"focusin":(td(fe)||fe.contentEditable==="true")&&(Or=fe,Ql=T,Qs=null);break;case"focusout":Qs=Ql=Or=null;break;case"mousedown":Kl=!0;break;case"contextmenu":case"mouseup":case"dragend":Kl=!1,dd(B,n,$);break;case"selectionchange":if(Tg)break;case"keydown":case"keyup":dd(B,n,$)}var he;if(Bl)e:{switch(e){case"compositionstart":var ve="onCompositionStart";break e;case"compositionend":ve="onCompositionEnd";break e;case"compositionupdate":ve="onCompositionUpdate";break e}ve=void 0}else Mr?Jc(e,n)&&(ve="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(ve="onCompositionStart");ve&&(Zc&&n.locale!=="ko"&&(Mr||ve!=="onCompositionStart"?ve==="onCompositionEnd"&&Mr&&(he=Wc()):(bn=$,Al="value"in bn?bn.value:bn.textContent,Mr=!0)),fe=ro(T,ve),0<fe.length&&(ve=new qc(ve,e,null,n,$),B.push({event:ve,listeners:fe}),he?ve.data=he:(he=ed(n),he!==null&&(ve.data=he)))),(he=kg?bg(e,n):Sg(e,n))&&(T=ro(T,"onBeforeInput"),0<T.length&&($=new qc("onBeforeInput","beforeinput",null,n,$),B.push({event:$,listeners:T}),$.data=he))}wd(B,t)})}function Gs(e,t,n){return{instance:e,listener:t,currentTarget:n}}function ro(e,t){for(var n=t+"Capture",i=[];e!==null;){var l=e,c=l.stateNode;l.tag===5&&c!==null&&(l=c,c=Rs(e,n),c!=null&&i.unshift(Gs(e,c,l)),c=Rs(e,t),c!=null&&i.push(Gs(e,c,l))),e=e.return}return i}function Lr(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function bd(e,t,n,i,l){for(var c=t._reactName,p=[];n!==null&&n!==i;){var v=n,S=v.alternate,T=v.stateNode;if(S!==null&&S===i)break;v.tag===5&&T!==null&&(v=T,l?(S=Rs(n,c),S!=null&&p.unshift(Gs(n,S,v))):l||(S=Rs(n,c),S!=null&&p.push(Gs(n,S,v)))),n=n.return}p.length!==0&&e.push({event:t,listeners:p})}var zg=/\r\n?/g,Fg=/\u0000|\uFFFD/g;function Sd(e){return(typeof e=="string"?e:""+e).replace(zg,`
|
||
`).replace(Fg,"")}function so(e,t,n){if(t=Sd(t),Sd(e)!==t&&n)throw Error(o(425))}function io(){}var Jl=null,ea=null;function ta(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var na=typeof setTimeout=="function"?setTimeout:void 0,Ig=typeof clearTimeout=="function"?clearTimeout:void 0,Ed=typeof Promise=="function"?Promise:void 0,Ug=typeof queueMicrotask=="function"?queueMicrotask:typeof Ed<"u"?function(e){return Ed.resolve(null).then(e).catch($g)}:na;function $g(e){setTimeout(function(){throw e})}function ra(e,t){var n=t,i=0;do{var l=n.nextSibling;if(e.removeChild(n),l&&l.nodeType===8)if(n=l.data,n==="/$"){if(i===0){e.removeChild(l),Is(t);return}i--}else n!=="$"&&n!=="$?"&&n!=="$!"||i++;n=l}while(n);Is(t)}function En(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Nd(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var Dr=Math.random().toString(36).slice(2),qt="__reactFiber$"+Dr,Zs="__reactProps$"+Dr,sn="__reactContainer$"+Dr,sa="__reactEvents$"+Dr,Bg="__reactListeners$"+Dr,Vg="__reactHandles$"+Dr;function Jn(e){var t=e[qt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[sn]||n[qt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Nd(e);e!==null;){if(n=e[qt])return n;e=Nd(e)}return t}e=n,n=e.parentNode}return null}function Ys(e){return e=e[qt]||e[sn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Ar(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(o(33))}function oo(e){return e[Zs]||null}var ia=[],zr=-1;function Nn(e){return{current:e}}function Ie(e){0>zr||(e.current=ia[zr],ia[zr]=null,zr--)}function Ae(e,t){zr++,ia[zr]=e.current,e.current=t}var jn={},lt=Nn(jn),mt=Nn(!1),er=jn;function Fr(e,t){var n=e.type.contextTypes;if(!n)return jn;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===t)return i.__reactInternalMemoizedMaskedChildContext;var l={},c;for(c in n)l[c]=t[c];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function gt(e){return e=e.childContextTypes,e!=null}function lo(){Ie(mt),Ie(lt)}function jd(e,t,n){if(lt.current!==jn)throw Error(o(168));Ae(lt,t),Ae(mt,n)}function Cd(e,t,n){var i=e.stateNode;if(t=t.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var l in i)if(!(l in t))throw Error(o(108,de(e)||"Unknown",l));return Q({},n,i)}function ao(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||jn,er=lt.current,Ae(lt,e),Ae(mt,mt.current),!0}function _d(e,t,n){var i=e.stateNode;if(!i)throw Error(o(169));n?(e=Cd(e,t,er),i.__reactInternalMemoizedMergedChildContext=e,Ie(mt),Ie(lt),Ae(lt,e)):Ie(mt),Ae(mt,n)}var on=null,uo=!1,oa=!1;function Pd(e){on===null?on=[e]:on.push(e)}function Hg(e){uo=!0,Pd(e)}function Cn(){if(!oa&&on!==null){oa=!0;var e=0,t=De;try{var n=on;for(De=1;e<n.length;e++){var i=n[e];do i=i(!0);while(i!==null)}on=null,uo=!1}catch(l){throw on!==null&&(on=on.slice(e+1)),Mc(_l,Cn),l}finally{De=t,oa=!1}}return null}var Ir=[],Ur=0,co=null,fo=0,Rt=[],Mt=0,tr=null,ln=1,an="";function nr(e,t){Ir[Ur++]=fo,Ir[Ur++]=co,co=e,fo=t}function Rd(e,t,n){Rt[Mt++]=ln,Rt[Mt++]=an,Rt[Mt++]=tr,tr=e;var i=ln;e=an;var l=32-zt(i)-1;i&=~(1<<l),n+=1;var c=32-zt(t)+l;if(30<c){var p=l-l%5;c=(i&(1<<p)-1).toString(32),i>>=p,l-=p,ln=1<<32-zt(t)+l|n<<l|i,an=c+e}else ln=1<<c|n<<l|i,an=e}function la(e){e.return!==null&&(nr(e,1),Rd(e,1,0))}function aa(e){for(;e===co;)co=Ir[--Ur],Ir[Ur]=null,fo=Ir[--Ur],Ir[Ur]=null;for(;e===tr;)tr=Rt[--Mt],Rt[Mt]=null,an=Rt[--Mt],Rt[Mt]=null,ln=Rt[--Mt],Rt[Mt]=null}var Nt=null,jt=null,$e=!1,It=null;function Md(e,t){var n=Dt(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function Od(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Nt=e,jt=En(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Nt=e,jt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=tr!==null?{id:ln,overflow:an}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=Dt(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Nt=e,jt=null,!0):!1;default:return!1}}function ua(e){return(e.mode&1)!==0&&(e.flags&128)===0}function ca(e){if($e){var t=jt;if(t){var n=t;if(!Od(e,t)){if(ua(e))throw Error(o(418));t=En(n.nextSibling);var i=Nt;t&&Od(e,t)?Md(i,n):(e.flags=e.flags&-4097|2,$e=!1,Nt=e)}}else{if(ua(e))throw Error(o(418));e.flags=e.flags&-4097|2,$e=!1,Nt=e}}}function Td(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Nt=e}function ho(e){if(e!==Nt)return!1;if(!$e)return Td(e),$e=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!ta(e.type,e.memoizedProps)),t&&(t=jt)){if(ua(e))throw Ld(),Error(o(418));for(;t;)Md(e,t),t=En(t.nextSibling)}if(Td(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){jt=En(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}jt=null}}else jt=Nt?En(e.stateNode.nextSibling):null;return!0}function Ld(){for(var e=jt;e;)e=En(e.nextSibling)}function $r(){jt=Nt=null,$e=!1}function da(e){It===null?It=[e]:It.push(e)}var Wg=z.ReactCurrentBatchConfig;function Xs(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(o(309));var i=n.stateNode}if(!i)throw Error(o(147,e));var l=i,c=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===c?t.ref:(t=function(p){var v=l.refs;p===null?delete v[c]:v[c]=p},t._stringRef=c,t)}if(typeof e!="string")throw Error(o(284));if(!n._owner)throw Error(o(290,e))}return e}function po(e,t){throw e=Object.prototype.toString.call(t),Error(o(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Dd(e){var t=e._init;return t(e._payload)}function Ad(e){function t(M,j){if(e){var O=M.deletions;O===null?(M.deletions=[j],M.flags|=16):O.push(j)}}function n(M,j){if(!e)return null;for(;j!==null;)t(M,j),j=j.sibling;return null}function i(M,j){for(M=new Map;j!==null;)j.key!==null?M.set(j.key,j):M.set(j.index,j),j=j.sibling;return M}function l(M,j){return M=Dn(M,j),M.index=0,M.sibling=null,M}function c(M,j,O){return M.index=O,e?(O=M.alternate,O!==null?(O=O.index,O<j?(M.flags|=2,j):O):(M.flags|=2,j)):(M.flags|=1048576,j)}function p(M){return e&&M.alternate===null&&(M.flags|=2),M}function v(M,j,O,H){return j===null||j.tag!==6?(j=nu(O,M.mode,H),j.return=M,j):(j=l(j,O),j.return=M,j)}function S(M,j,O,H){var ae=O.type;return ae===ue?$(M,j,O.props.children,H,O.key):j!==null&&(j.elementType===ae||typeof ae=="object"&&ae!==null&&ae.$$typeof===Ce&&Dd(ae)===j.type)?(H=l(j,O.props),H.ref=Xs(M,j,O),H.return=M,H):(H=Fo(O.type,O.key,O.props,null,M.mode,H),H.ref=Xs(M,j,O),H.return=M,H)}function T(M,j,O,H){return j===null||j.tag!==4||j.stateNode.containerInfo!==O.containerInfo||j.stateNode.implementation!==O.implementation?(j=ru(O,M.mode,H),j.return=M,j):(j=l(j,O.children||[]),j.return=M,j)}function $(M,j,O,H,ae){return j===null||j.tag!==7?(j=cr(O,M.mode,H,ae),j.return=M,j):(j=l(j,O),j.return=M,j)}function B(M,j,O){if(typeof j=="string"&&j!==""||typeof j=="number")return j=nu(""+j,M.mode,O),j.return=M,j;if(typeof j=="object"&&j!==null){switch(j.$$typeof){case K:return O=Fo(j.type,j.key,j.props,null,M.mode,O),O.ref=Xs(M,null,j),O.return=M,O;case G:return j=ru(j,M.mode,O),j.return=M,j;case Ce:var H=j._init;return B(M,H(j._payload),O)}if(xe(j)||ne(j))return j=cr(j,M.mode,O,null),j.return=M,j;po(M,j)}return null}function U(M,j,O,H){var ae=j!==null?j.key:null;if(typeof O=="string"&&O!==""||typeof O=="number")return ae!==null?null:v(M,j,""+O,H);if(typeof O=="object"&&O!==null){switch(O.$$typeof){case K:return O.key===ae?S(M,j,O,H):null;case G:return O.key===ae?T(M,j,O,H):null;case Ce:return ae=O._init,U(M,j,ae(O._payload),H)}if(xe(O)||ne(O))return ae!==null?null:$(M,j,O,H,null);po(M,O)}return null}function X(M,j,O,H,ae){if(typeof H=="string"&&H!==""||typeof H=="number")return M=M.get(O)||null,v(j,M,""+H,ae);if(typeof H=="object"&&H!==null){switch(H.$$typeof){case K:return M=M.get(H.key===null?O:H.key)||null,S(j,M,H,ae);case G:return M=M.get(H.key===null?O:H.key)||null,T(j,M,H,ae);case Ce:var fe=H._init;return X(M,j,O,fe(H._payload),ae)}if(xe(H)||ne(H))return M=M.get(O)||null,$(j,M,H,ae,null);po(j,H)}return null}function re(M,j,O,H){for(var ae=null,fe=null,he=j,ve=j=0,tt=null;he!==null&&ve<O.length;ve++){he.index>ve?(tt=he,he=null):tt=he.sibling;var Oe=U(M,he,O[ve],H);if(Oe===null){he===null&&(he=tt);break}e&&he&&Oe.alternate===null&&t(M,he),j=c(Oe,j,ve),fe===null?ae=Oe:fe.sibling=Oe,fe=Oe,he=tt}if(ve===O.length)return n(M,he),$e&&nr(M,ve),ae;if(he===null){for(;ve<O.length;ve++)he=B(M,O[ve],H),he!==null&&(j=c(he,j,ve),fe===null?ae=he:fe.sibling=he,fe=he);return $e&&nr(M,ve),ae}for(he=i(M,he);ve<O.length;ve++)tt=X(he,M,ve,O[ve],H),tt!==null&&(e&&tt.alternate!==null&&he.delete(tt.key===null?ve:tt.key),j=c(tt,j,ve),fe===null?ae=tt:fe.sibling=tt,fe=tt);return e&&he.forEach(function(An){return t(M,An)}),$e&&nr(M,ve),ae}function ie(M,j,O,H){var ae=ne(O);if(typeof ae!="function")throw Error(o(150));if(O=ae.call(O),O==null)throw Error(o(151));for(var fe=ae=null,he=j,ve=j=0,tt=null,Oe=O.next();he!==null&&!Oe.done;ve++,Oe=O.next()){he.index>ve?(tt=he,he=null):tt=he.sibling;var An=U(M,he,Oe.value,H);if(An===null){he===null&&(he=tt);break}e&&he&&An.alternate===null&&t(M,he),j=c(An,j,ve),fe===null?ae=An:fe.sibling=An,fe=An,he=tt}if(Oe.done)return n(M,he),$e&&nr(M,ve),ae;if(he===null){for(;!Oe.done;ve++,Oe=O.next())Oe=B(M,Oe.value,H),Oe!==null&&(j=c(Oe,j,ve),fe===null?ae=Oe:fe.sibling=Oe,fe=Oe);return $e&&nr(M,ve),ae}for(he=i(M,he);!Oe.done;ve++,Oe=O.next())Oe=X(he,M,ve,Oe.value,H),Oe!==null&&(e&&Oe.alternate!==null&&he.delete(Oe.key===null?ve:Oe.key),j=c(Oe,j,ve),fe===null?ae=Oe:fe.sibling=Oe,fe=Oe);return e&&he.forEach(function(Ev){return t(M,Ev)}),$e&&nr(M,ve),ae}function qe(M,j,O,H){if(typeof O=="object"&&O!==null&&O.type===ue&&O.key===null&&(O=O.props.children),typeof O=="object"&&O!==null){switch(O.$$typeof){case K:e:{for(var ae=O.key,fe=j;fe!==null;){if(fe.key===ae){if(ae=O.type,ae===ue){if(fe.tag===7){n(M,fe.sibling),j=l(fe,O.props.children),j.return=M,M=j;break e}}else if(fe.elementType===ae||typeof ae=="object"&&ae!==null&&ae.$$typeof===Ce&&Dd(ae)===fe.type){n(M,fe.sibling),j=l(fe,O.props),j.ref=Xs(M,fe,O),j.return=M,M=j;break e}n(M,fe);break}else t(M,fe);fe=fe.sibling}O.type===ue?(j=cr(O.props.children,M.mode,H,O.key),j.return=M,M=j):(H=Fo(O.type,O.key,O.props,null,M.mode,H),H.ref=Xs(M,j,O),H.return=M,M=H)}return p(M);case G:e:{for(fe=O.key;j!==null;){if(j.key===fe)if(j.tag===4&&j.stateNode.containerInfo===O.containerInfo&&j.stateNode.implementation===O.implementation){n(M,j.sibling),j=l(j,O.children||[]),j.return=M,M=j;break e}else{n(M,j);break}else t(M,j);j=j.sibling}j=ru(O,M.mode,H),j.return=M,M=j}return p(M);case Ce:return fe=O._init,qe(M,j,fe(O._payload),H)}if(xe(O))return re(M,j,O,H);if(ne(O))return ie(M,j,O,H);po(M,O)}return typeof O=="string"&&O!==""||typeof O=="number"?(O=""+O,j!==null&&j.tag===6?(n(M,j.sibling),j=l(j,O),j.return=M,M=j):(n(M,j),j=nu(O,M.mode,H),j.return=M,M=j),p(M)):n(M,j)}return qe}var Br=Ad(!0),zd=Ad(!1),mo=Nn(null),go=null,Vr=null,fa=null;function ha(){fa=Vr=go=null}function pa(e){var t=mo.current;Ie(mo),e._currentValue=t}function ma(e,t,n){for(;e!==null;){var i=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,i!==null&&(i.childLanes|=t)):i!==null&&(i.childLanes&t)!==t&&(i.childLanes|=t),e===n)break;e=e.return}}function Hr(e,t){go=e,fa=Vr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&((e.lanes&t)!==0&&(vt=!0),e.firstContext=null)}function Ot(e){var t=e._currentValue;if(fa!==e)if(e={context:e,memoizedValue:t,next:null},Vr===null){if(go===null)throw Error(o(308));Vr=e,go.dependencies={lanes:0,firstContext:e}}else Vr=Vr.next=e;return t}var rr=null;function ga(e){rr===null?rr=[e]:rr.push(e)}function Fd(e,t,n,i){var l=t.interleaved;return l===null?(n.next=n,ga(t)):(n.next=l.next,l.next=n),t.interleaved=n,un(e,i)}function un(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var _n=!1;function va(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Id(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function cn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Pn(e,t,n){var i=e.updateQueue;if(i===null)return null;if(i=i.shared,(Me&2)!==0){var l=i.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),i.pending=t,un(e,n)}return l=i.interleaved,l===null?(t.next=t,ga(i)):(t.next=l.next,l.next=t),i.interleaved=t,un(e,n)}function vo(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Ml(e,n)}}function Ud(e,t){var n=e.updateQueue,i=e.alternate;if(i!==null&&(i=i.updateQueue,n===i)){var l=null,c=null;if(n=n.firstBaseUpdate,n!==null){do{var p={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};c===null?l=c=p:c=c.next=p,n=n.next}while(n!==null);c===null?l=c=t:c=c.next=t}else l=c=t;n={baseState:i.baseState,firstBaseUpdate:l,lastBaseUpdate:c,shared:i.shared,effects:i.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function yo(e,t,n,i){var l=e.updateQueue;_n=!1;var c=l.firstBaseUpdate,p=l.lastBaseUpdate,v=l.shared.pending;if(v!==null){l.shared.pending=null;var S=v,T=S.next;S.next=null,p===null?c=T:p.next=T,p=S;var $=e.alternate;$!==null&&($=$.updateQueue,v=$.lastBaseUpdate,v!==p&&(v===null?$.firstBaseUpdate=T:v.next=T,$.lastBaseUpdate=S))}if(c!==null){var B=l.baseState;p=0,$=T=S=null,v=c;do{var U=v.lane,X=v.eventTime;if((i&U)===U){$!==null&&($=$.next={eventTime:X,lane:0,tag:v.tag,payload:v.payload,callback:v.callback,next:null});e:{var re=e,ie=v;switch(U=t,X=n,ie.tag){case 1:if(re=ie.payload,typeof re=="function"){B=re.call(X,B,U);break e}B=re;break e;case 3:re.flags=re.flags&-65537|128;case 0:if(re=ie.payload,U=typeof re=="function"?re.call(X,B,U):re,U==null)break e;B=Q({},B,U);break e;case 2:_n=!0}}v.callback!==null&&v.lane!==0&&(e.flags|=64,U=l.effects,U===null?l.effects=[v]:U.push(v))}else X={eventTime:X,lane:U,tag:v.tag,payload:v.payload,callback:v.callback,next:null},$===null?(T=$=X,S=B):$=$.next=X,p|=U;if(v=v.next,v===null){if(v=l.shared.pending,v===null)break;U=v,v=U.next,U.next=null,l.lastBaseUpdate=U,l.shared.pending=null}}while(!0);if($===null&&(S=B),l.baseState=S,l.firstBaseUpdate=T,l.lastBaseUpdate=$,t=l.shared.interleaved,t!==null){l=t;do p|=l.lane,l=l.next;while(l!==t)}else c===null&&(l.shared.lanes=0);or|=p,e.lanes=p,e.memoizedState=B}}function $d(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var i=e[t],l=i.callback;if(l!==null){if(i.callback=null,i=n,typeof l!="function")throw Error(o(191,l));l.call(i)}}}var Js={},Gt=Nn(Js),ei=Nn(Js),ti=Nn(Js);function sr(e){if(e===Js)throw Error(o(174));return e}function ya(e,t){switch(Ae(ti,t),Ae(ei,e),Ae(Gt,Js),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:xl(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=xl(t,e)}Ie(Gt),Ae(Gt,t)}function Wr(){Ie(Gt),Ie(ei),Ie(ti)}function Bd(e){sr(ti.current);var t=sr(Gt.current),n=xl(t,e.type);t!==n&&(Ae(ei,e),Ae(Gt,n))}function xa(e){ei.current===e&&(Ie(Gt),Ie(ei))}var Ve=Nn(0);function xo(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var wa=[];function ka(){for(var e=0;e<wa.length;e++)wa[e]._workInProgressVersionPrimary=null;wa.length=0}var wo=z.ReactCurrentDispatcher,ba=z.ReactCurrentBatchConfig,ir=0,He=null,Ye=null,Je=null,ko=!1,ni=!1,ri=0,Qg=0;function at(){throw Error(o(321))}function Sa(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Ft(e[n],t[n]))return!1;return!0}function Ea(e,t,n,i,l,c){if(ir=c,He=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,wo.current=e===null||e.memoizedState===null?Zg:Yg,e=n(i,l),ni){c=0;do{if(ni=!1,ri=0,25<=c)throw Error(o(301));c+=1,Je=Ye=null,t.updateQueue=null,wo.current=Xg,e=n(i,l)}while(ni)}if(wo.current=Eo,t=Ye!==null&&Ye.next!==null,ir=0,Je=Ye=He=null,ko=!1,t)throw Error(o(300));return e}function Na(){var e=ri!==0;return ri=0,e}function Zt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Je===null?He.memoizedState=Je=e:Je=Je.next=e,Je}function Tt(){if(Ye===null){var e=He.alternate;e=e!==null?e.memoizedState:null}else e=Ye.next;var t=Je===null?He.memoizedState:Je.next;if(t!==null)Je=t,Ye=e;else{if(e===null)throw Error(o(310));Ye=e,e={memoizedState:Ye.memoizedState,baseState:Ye.baseState,baseQueue:Ye.baseQueue,queue:Ye.queue,next:null},Je===null?He.memoizedState=Je=e:Je=Je.next=e}return Je}function si(e,t){return typeof t=="function"?t(e):t}function ja(e){var t=Tt(),n=t.queue;if(n===null)throw Error(o(311));n.lastRenderedReducer=e;var i=Ye,l=i.baseQueue,c=n.pending;if(c!==null){if(l!==null){var p=l.next;l.next=c.next,c.next=p}i.baseQueue=l=c,n.pending=null}if(l!==null){c=l.next,i=i.baseState;var v=p=null,S=null,T=c;do{var $=T.lane;if((ir&$)===$)S!==null&&(S=S.next={lane:0,action:T.action,hasEagerState:T.hasEagerState,eagerState:T.eagerState,next:null}),i=T.hasEagerState?T.eagerState:e(i,T.action);else{var B={lane:$,action:T.action,hasEagerState:T.hasEagerState,eagerState:T.eagerState,next:null};S===null?(v=S=B,p=i):S=S.next=B,He.lanes|=$,or|=$}T=T.next}while(T!==null&&T!==c);S===null?p=i:S.next=v,Ft(i,t.memoizedState)||(vt=!0),t.memoizedState=i,t.baseState=p,t.baseQueue=S,n.lastRenderedState=i}if(e=n.interleaved,e!==null){l=e;do c=l.lane,He.lanes|=c,or|=c,l=l.next;while(l!==e)}else l===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Ca(e){var t=Tt(),n=t.queue;if(n===null)throw Error(o(311));n.lastRenderedReducer=e;var i=n.dispatch,l=n.pending,c=t.memoizedState;if(l!==null){n.pending=null;var p=l=l.next;do c=e(c,p.action),p=p.next;while(p!==l);Ft(c,t.memoizedState)||(vt=!0),t.memoizedState=c,t.baseQueue===null&&(t.baseState=c),n.lastRenderedState=c}return[c,i]}function Vd(){}function Hd(e,t){var n=He,i=Tt(),l=t(),c=!Ft(i.memoizedState,l);if(c&&(i.memoizedState=l,vt=!0),i=i.queue,_a(Kd.bind(null,n,i,e),[e]),i.getSnapshot!==t||c||Je!==null&&Je.memoizedState.tag&1){if(n.flags|=2048,ii(9,Qd.bind(null,n,i,l,t),void 0,null),et===null)throw Error(o(349));(ir&30)!==0||Wd(n,t,l)}return l}function Wd(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=He.updateQueue,t===null?(t={lastEffect:null,stores:null},He.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Qd(e,t,n,i){t.value=n,t.getSnapshot=i,qd(t)&&Gd(e)}function Kd(e,t,n){return n(function(){qd(t)&&Gd(e)})}function qd(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Ft(e,n)}catch{return!0}}function Gd(e){var t=un(e,1);t!==null&&Vt(t,e,1,-1)}function Zd(e){var t=Zt();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:si,lastRenderedState:e},t.queue=e,e=e.dispatch=Gg.bind(null,He,e),[t.memoizedState,e]}function ii(e,t,n,i){return e={tag:e,create:t,destroy:n,deps:i,next:null},t=He.updateQueue,t===null?(t={lastEffect:null,stores:null},He.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(i=n.next,n.next=e,e.next=i,t.lastEffect=e)),e}function Yd(){return Tt().memoizedState}function bo(e,t,n,i){var l=Zt();He.flags|=e,l.memoizedState=ii(1|t,n,void 0,i===void 0?null:i)}function So(e,t,n,i){var l=Tt();i=i===void 0?null:i;var c=void 0;if(Ye!==null){var p=Ye.memoizedState;if(c=p.destroy,i!==null&&Sa(i,p.deps)){l.memoizedState=ii(t,n,c,i);return}}He.flags|=e,l.memoizedState=ii(1|t,n,c,i)}function Xd(e,t){return bo(8390656,8,e,t)}function _a(e,t){return So(2048,8,e,t)}function Jd(e,t){return So(4,2,e,t)}function ef(e,t){return So(4,4,e,t)}function tf(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function nf(e,t,n){return n=n!=null?n.concat([e]):null,So(4,4,tf.bind(null,t,e),n)}function Pa(){}function rf(e,t){var n=Tt();t=t===void 0?null:t;var i=n.memoizedState;return i!==null&&t!==null&&Sa(t,i[1])?i[0]:(n.memoizedState=[e,t],e)}function sf(e,t){var n=Tt();t=t===void 0?null:t;var i=n.memoizedState;return i!==null&&t!==null&&Sa(t,i[1])?i[0]:(e=e(),n.memoizedState=[e,t],e)}function of(e,t,n){return(ir&21)===0?(e.baseState&&(e.baseState=!1,vt=!0),e.memoizedState=n):(Ft(n,t)||(n=Dc(),He.lanes|=n,or|=n,e.baseState=!0),t)}function Kg(e,t){var n=De;De=n!==0&&4>n?n:4,e(!0);var i=ba.transition;ba.transition={};try{e(!1),t()}finally{De=n,ba.transition=i}}function lf(){return Tt().memoizedState}function qg(e,t,n){var i=Tn(e);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},af(e))uf(t,n);else if(n=Fd(e,t,n,i),n!==null){var l=ht();Vt(n,e,i,l),cf(n,t,i)}}function Gg(e,t,n){var i=Tn(e),l={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(af(e))uf(t,l);else{var c=e.alternate;if(e.lanes===0&&(c===null||c.lanes===0)&&(c=t.lastRenderedReducer,c!==null))try{var p=t.lastRenderedState,v=c(p,n);if(l.hasEagerState=!0,l.eagerState=v,Ft(v,p)){var S=t.interleaved;S===null?(l.next=l,ga(t)):(l.next=S.next,S.next=l),t.interleaved=l;return}}catch{}finally{}n=Fd(e,t,l,i),n!==null&&(l=ht(),Vt(n,e,i,l),cf(n,t,i))}}function af(e){var t=e.alternate;return e===He||t!==null&&t===He}function uf(e,t){ni=ko=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function cf(e,t,n){if((n&4194240)!==0){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Ml(e,n)}}var Eo={readContext:Ot,useCallback:at,useContext:at,useEffect:at,useImperativeHandle:at,useInsertionEffect:at,useLayoutEffect:at,useMemo:at,useReducer:at,useRef:at,useState:at,useDebugValue:at,useDeferredValue:at,useTransition:at,useMutableSource:at,useSyncExternalStore:at,useId:at,unstable_isNewReconciler:!1},Zg={readContext:Ot,useCallback:function(e,t){return Zt().memoizedState=[e,t===void 0?null:t],e},useContext:Ot,useEffect:Xd,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,bo(4194308,4,tf.bind(null,t,e),n)},useLayoutEffect:function(e,t){return bo(4194308,4,e,t)},useInsertionEffect:function(e,t){return bo(4,2,e,t)},useMemo:function(e,t){var n=Zt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var i=Zt();return t=n!==void 0?n(t):t,i.memoizedState=i.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},i.queue=e,e=e.dispatch=qg.bind(null,He,e),[i.memoizedState,e]},useRef:function(e){var t=Zt();return e={current:e},t.memoizedState=e},useState:Zd,useDebugValue:Pa,useDeferredValue:function(e){return Zt().memoizedState=e},useTransition:function(){var e=Zd(!1),t=e[0];return e=Kg.bind(null,e[1]),Zt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var i=He,l=Zt();if($e){if(n===void 0)throw Error(o(407));n=n()}else{if(n=t(),et===null)throw Error(o(349));(ir&30)!==0||Wd(i,t,n)}l.memoizedState=n;var c={value:n,getSnapshot:t};return l.queue=c,Xd(Kd.bind(null,i,c,e),[e]),i.flags|=2048,ii(9,Qd.bind(null,i,c,n,t),void 0,null),n},useId:function(){var e=Zt(),t=et.identifierPrefix;if($e){var n=an,i=ln;n=(i&~(1<<32-zt(i)-1)).toString(32)+n,t=":"+t+"R"+n,n=ri++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=Qg++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Yg={readContext:Ot,useCallback:rf,useContext:Ot,useEffect:_a,useImperativeHandle:nf,useInsertionEffect:Jd,useLayoutEffect:ef,useMemo:sf,useReducer:ja,useRef:Yd,useState:function(){return ja(si)},useDebugValue:Pa,useDeferredValue:function(e){var t=Tt();return of(t,Ye.memoizedState,e)},useTransition:function(){var e=ja(si)[0],t=Tt().memoizedState;return[e,t]},useMutableSource:Vd,useSyncExternalStore:Hd,useId:lf,unstable_isNewReconciler:!1},Xg={readContext:Ot,useCallback:rf,useContext:Ot,useEffect:_a,useImperativeHandle:nf,useInsertionEffect:Jd,useLayoutEffect:ef,useMemo:sf,useReducer:Ca,useRef:Yd,useState:function(){return Ca(si)},useDebugValue:Pa,useDeferredValue:function(e){var t=Tt();return Ye===null?t.memoizedState=e:of(t,Ye.memoizedState,e)},useTransition:function(){var e=Ca(si)[0],t=Tt().memoizedState;return[e,t]},useMutableSource:Vd,useSyncExternalStore:Hd,useId:lf,unstable_isNewReconciler:!1};function Ut(e,t){if(e&&e.defaultProps){t=Q({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Ra(e,t,n,i){t=e.memoizedState,n=n(i,t),n=n==null?t:Q({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var No={isMounted:function(e){return(e=e._reactInternals)?Xn(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var i=ht(),l=Tn(e),c=cn(i,l);c.payload=t,n!=null&&(c.callback=n),t=Pn(e,c,l),t!==null&&(Vt(t,e,l,i),vo(t,e,l))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var i=ht(),l=Tn(e),c=cn(i,l);c.tag=1,c.payload=t,n!=null&&(c.callback=n),t=Pn(e,c,l),t!==null&&(Vt(t,e,l,i),vo(t,e,l))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ht(),i=Tn(e),l=cn(n,i);l.tag=2,t!=null&&(l.callback=t),t=Pn(e,l,i),t!==null&&(Vt(t,e,i,n),vo(t,e,i))}};function df(e,t,n,i,l,c,p){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(i,c,p):t.prototype&&t.prototype.isPureReactComponent?!Ws(n,i)||!Ws(l,c):!0}function ff(e,t,n){var i=!1,l=jn,c=t.contextType;return typeof c=="object"&&c!==null?c=Ot(c):(l=gt(t)?er:lt.current,i=t.contextTypes,c=(i=i!=null)?Fr(e,l):jn),t=new t(n,c),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=No,e.stateNode=t,t._reactInternals=e,i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=l,e.__reactInternalMemoizedMaskedChildContext=c),t}function hf(e,t,n,i){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,i),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,i),t.state!==e&&No.enqueueReplaceState(t,t.state,null)}function Ma(e,t,n,i){var l=e.stateNode;l.props=n,l.state=e.memoizedState,l.refs={},va(e);var c=t.contextType;typeof c=="object"&&c!==null?l.context=Ot(c):(c=gt(t)?er:lt.current,l.context=Fr(e,c)),l.state=e.memoizedState,c=t.getDerivedStateFromProps,typeof c=="function"&&(Ra(e,t,c,n),l.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof l.getSnapshotBeforeUpdate=="function"||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(t=l.state,typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount(),t!==l.state&&No.enqueueReplaceState(l,l.state,null),yo(e,n,l,i),l.state=e.memoizedState),typeof l.componentDidMount=="function"&&(e.flags|=4194308)}function Qr(e,t){try{var n="",i=t;do n+=W(i),i=i.return;while(i);var l=n}catch(c){l=`
|
||
Error generating stack: `+c.message+`
|
||
`+c.stack}return{value:e,source:t,stack:l,digest:null}}function Oa(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Ta(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Jg=typeof WeakMap=="function"?WeakMap:Map;function pf(e,t,n){n=cn(-1,n),n.tag=3,n.payload={element:null};var i=t.value;return n.callback=function(){Oo||(Oo=!0,qa=i),Ta(e,t)},n}function mf(e,t,n){n=cn(-1,n),n.tag=3;var i=e.type.getDerivedStateFromError;if(typeof i=="function"){var l=t.value;n.payload=function(){return i(l)},n.callback=function(){Ta(e,t)}}var c=e.stateNode;return c!==null&&typeof c.componentDidCatch=="function"&&(n.callback=function(){Ta(e,t),typeof i!="function"&&(Mn===null?Mn=new Set([this]):Mn.add(this));var p=t.stack;this.componentDidCatch(t.value,{componentStack:p!==null?p:""})}),n}function gf(e,t,n){var i=e.pingCache;if(i===null){i=e.pingCache=new Jg;var l=new Set;i.set(t,l)}else l=i.get(t),l===void 0&&(l=new Set,i.set(t,l));l.has(n)||(l.add(n),e=hv.bind(null,e,t,n),t.then(e,e))}function vf(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function yf(e,t,n,i,l){return(e.mode&1)===0?(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=cn(-1,1),t.tag=2,Pn(n,t,1))),n.lanes|=1),e):(e.flags|=65536,e.lanes=l,e)}var ev=z.ReactCurrentOwner,vt=!1;function ft(e,t,n,i){t.child=e===null?zd(t,null,n,i):Br(t,e.child,n,i)}function xf(e,t,n,i,l){n=n.render;var c=t.ref;return Hr(t,l),i=Ea(e,t,n,i,c,l),n=Na(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,dn(e,t,l)):($e&&n&&la(t),t.flags|=1,ft(e,t,i,l),t.child)}function wf(e,t,n,i,l){if(e===null){var c=n.type;return typeof c=="function"&&!tu(c)&&c.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=c,kf(e,t,c,i,l)):(e=Fo(n.type,null,i,t,t.mode,l),e.ref=t.ref,e.return=t,t.child=e)}if(c=e.child,(e.lanes&l)===0){var p=c.memoizedProps;if(n=n.compare,n=n!==null?n:Ws,n(p,i)&&e.ref===t.ref)return dn(e,t,l)}return t.flags|=1,e=Dn(c,i),e.ref=t.ref,e.return=t,t.child=e}function kf(e,t,n,i,l){if(e!==null){var c=e.memoizedProps;if(Ws(c,i)&&e.ref===t.ref)if(vt=!1,t.pendingProps=i=c,(e.lanes&l)!==0)(e.flags&131072)!==0&&(vt=!0);else return t.lanes=e.lanes,dn(e,t,l)}return La(e,t,n,i,l)}function bf(e,t,n){var i=t.pendingProps,l=i.children,c=e!==null?e.memoizedState:null;if(i.mode==="hidden")if((t.mode&1)===0)t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ae(qr,Ct),Ct|=n;else{if((n&1073741824)===0)return e=c!==null?c.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Ae(qr,Ct),Ct|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},i=c!==null?c.baseLanes:n,Ae(qr,Ct),Ct|=i}else c!==null?(i=c.baseLanes|n,t.memoizedState=null):i=n,Ae(qr,Ct),Ct|=i;return ft(e,t,l,n),t.child}function Sf(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function La(e,t,n,i,l){var c=gt(n)?er:lt.current;return c=Fr(t,c),Hr(t,l),n=Ea(e,t,n,i,c,l),i=Na(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,dn(e,t,l)):($e&&i&&la(t),t.flags|=1,ft(e,t,n,l),t.child)}function Ef(e,t,n,i,l){if(gt(n)){var c=!0;ao(t)}else c=!1;if(Hr(t,l),t.stateNode===null)Co(e,t),ff(t,n,i),Ma(t,n,i,l),i=!0;else if(e===null){var p=t.stateNode,v=t.memoizedProps;p.props=v;var S=p.context,T=n.contextType;typeof T=="object"&&T!==null?T=Ot(T):(T=gt(n)?er:lt.current,T=Fr(t,T));var $=n.getDerivedStateFromProps,B=typeof $=="function"||typeof p.getSnapshotBeforeUpdate=="function";B||typeof p.UNSAFE_componentWillReceiveProps!="function"&&typeof p.componentWillReceiveProps!="function"||(v!==i||S!==T)&&hf(t,p,i,T),_n=!1;var U=t.memoizedState;p.state=U,yo(t,i,p,l),S=t.memoizedState,v!==i||U!==S||mt.current||_n?(typeof $=="function"&&(Ra(t,n,$,i),S=t.memoizedState),(v=_n||df(t,n,v,i,U,S,T))?(B||typeof p.UNSAFE_componentWillMount!="function"&&typeof p.componentWillMount!="function"||(typeof p.componentWillMount=="function"&&p.componentWillMount(),typeof p.UNSAFE_componentWillMount=="function"&&p.UNSAFE_componentWillMount()),typeof p.componentDidMount=="function"&&(t.flags|=4194308)):(typeof p.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=i,t.memoizedState=S),p.props=i,p.state=S,p.context=T,i=v):(typeof p.componentDidMount=="function"&&(t.flags|=4194308),i=!1)}else{p=t.stateNode,Id(e,t),v=t.memoizedProps,T=t.type===t.elementType?v:Ut(t.type,v),p.props=T,B=t.pendingProps,U=p.context,S=n.contextType,typeof S=="object"&&S!==null?S=Ot(S):(S=gt(n)?er:lt.current,S=Fr(t,S));var X=n.getDerivedStateFromProps;($=typeof X=="function"||typeof p.getSnapshotBeforeUpdate=="function")||typeof p.UNSAFE_componentWillReceiveProps!="function"&&typeof p.componentWillReceiveProps!="function"||(v!==B||U!==S)&&hf(t,p,i,S),_n=!1,U=t.memoizedState,p.state=U,yo(t,i,p,l);var re=t.memoizedState;v!==B||U!==re||mt.current||_n?(typeof X=="function"&&(Ra(t,n,X,i),re=t.memoizedState),(T=_n||df(t,n,T,i,U,re,S)||!1)?($||typeof p.UNSAFE_componentWillUpdate!="function"&&typeof p.componentWillUpdate!="function"||(typeof p.componentWillUpdate=="function"&&p.componentWillUpdate(i,re,S),typeof p.UNSAFE_componentWillUpdate=="function"&&p.UNSAFE_componentWillUpdate(i,re,S)),typeof p.componentDidUpdate=="function"&&(t.flags|=4),typeof p.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof p.componentDidUpdate!="function"||v===e.memoizedProps&&U===e.memoizedState||(t.flags|=4),typeof p.getSnapshotBeforeUpdate!="function"||v===e.memoizedProps&&U===e.memoizedState||(t.flags|=1024),t.memoizedProps=i,t.memoizedState=re),p.props=i,p.state=re,p.context=S,i=T):(typeof p.componentDidUpdate!="function"||v===e.memoizedProps&&U===e.memoizedState||(t.flags|=4),typeof p.getSnapshotBeforeUpdate!="function"||v===e.memoizedProps&&U===e.memoizedState||(t.flags|=1024),i=!1)}return Da(e,t,n,i,c,l)}function Da(e,t,n,i,l,c){Sf(e,t);var p=(t.flags&128)!==0;if(!i&&!p)return l&&_d(t,n,!1),dn(e,t,c);i=t.stateNode,ev.current=t;var v=p&&typeof n.getDerivedStateFromError!="function"?null:i.render();return t.flags|=1,e!==null&&p?(t.child=Br(t,e.child,null,c),t.child=Br(t,null,v,c)):ft(e,t,v,c),t.memoizedState=i.state,l&&_d(t,n,!0),t.child}function Nf(e){var t=e.stateNode;t.pendingContext?jd(e,t.pendingContext,t.pendingContext!==t.context):t.context&&jd(e,t.context,!1),ya(e,t.containerInfo)}function jf(e,t,n,i,l){return $r(),da(l),t.flags|=256,ft(e,t,n,i),t.child}var Aa={dehydrated:null,treeContext:null,retryLane:0};function za(e){return{baseLanes:e,cachePool:null,transitions:null}}function Cf(e,t,n){var i=t.pendingProps,l=Ve.current,c=!1,p=(t.flags&128)!==0,v;if((v=p)||(v=e!==null&&e.memoizedState===null?!1:(l&2)!==0),v?(c=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(l|=1),Ae(Ve,l&1),e===null)return ca(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?((t.mode&1)===0?t.lanes=1:e.data==="$!"?t.lanes=8:t.lanes=1073741824,null):(p=i.children,e=i.fallback,c?(i=t.mode,c=t.child,p={mode:"hidden",children:p},(i&1)===0&&c!==null?(c.childLanes=0,c.pendingProps=p):c=Io(p,i,0,null),e=cr(e,i,n,null),c.return=t,e.return=t,c.sibling=e,t.child=c,t.child.memoizedState=za(n),t.memoizedState=Aa,e):Fa(t,p));if(l=e.memoizedState,l!==null&&(v=l.dehydrated,v!==null))return tv(e,t,p,i,v,l,n);if(c){c=i.fallback,p=t.mode,l=e.child,v=l.sibling;var S={mode:"hidden",children:i.children};return(p&1)===0&&t.child!==l?(i=t.child,i.childLanes=0,i.pendingProps=S,t.deletions=null):(i=Dn(l,S),i.subtreeFlags=l.subtreeFlags&14680064),v!==null?c=Dn(v,c):(c=cr(c,p,n,null),c.flags|=2),c.return=t,i.return=t,i.sibling=c,t.child=i,i=c,c=t.child,p=e.child.memoizedState,p=p===null?za(n):{baseLanes:p.baseLanes|n,cachePool:null,transitions:p.transitions},c.memoizedState=p,c.childLanes=e.childLanes&~n,t.memoizedState=Aa,i}return c=e.child,e=c.sibling,i=Dn(c,{mode:"visible",children:i.children}),(t.mode&1)===0&&(i.lanes=n),i.return=t,i.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=i,t.memoizedState=null,i}function Fa(e,t){return t=Io({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function jo(e,t,n,i){return i!==null&&da(i),Br(t,e.child,null,n),e=Fa(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function tv(e,t,n,i,l,c,p){if(n)return t.flags&256?(t.flags&=-257,i=Oa(Error(o(422))),jo(e,t,p,i)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(c=i.fallback,l=t.mode,i=Io({mode:"visible",children:i.children},l,0,null),c=cr(c,l,p,null),c.flags|=2,i.return=t,c.return=t,i.sibling=c,t.child=i,(t.mode&1)!==0&&Br(t,e.child,null,p),t.child.memoizedState=za(p),t.memoizedState=Aa,c);if((t.mode&1)===0)return jo(e,t,p,null);if(l.data==="$!"){if(i=l.nextSibling&&l.nextSibling.dataset,i)var v=i.dgst;return i=v,c=Error(o(419)),i=Oa(c,i,void 0),jo(e,t,p,i)}if(v=(p&e.childLanes)!==0,vt||v){if(i=et,i!==null){switch(p&-p){case 4:l=2;break;case 16:l=8;break;case 64: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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:l=32;break;case 536870912:l=268435456;break;default:l=0}l=(l&(i.suspendedLanes|p))!==0?0:l,l!==0&&l!==c.retryLane&&(c.retryLane=l,un(e,l),Vt(i,e,l,-1))}return eu(),i=Oa(Error(o(421))),jo(e,t,p,i)}return l.data==="$?"?(t.flags|=128,t.child=e.child,t=pv.bind(null,e),l._reactRetry=t,null):(e=c.treeContext,jt=En(l.nextSibling),Nt=t,$e=!0,It=null,e!==null&&(Rt[Mt++]=ln,Rt[Mt++]=an,Rt[Mt++]=tr,ln=e.id,an=e.overflow,tr=t),t=Fa(t,i.children),t.flags|=4096,t)}function _f(e,t,n){e.lanes|=t;var i=e.alternate;i!==null&&(i.lanes|=t),ma(e.return,t,n)}function Ia(e,t,n,i,l){var c=e.memoizedState;c===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:i,tail:n,tailMode:l}:(c.isBackwards=t,c.rendering=null,c.renderingStartTime=0,c.last=i,c.tail=n,c.tailMode=l)}function Pf(e,t,n){var i=t.pendingProps,l=i.revealOrder,c=i.tail;if(ft(e,t,i.children,n),i=Ve.current,(i&2)!==0)i=i&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&_f(e,n,t);else if(e.tag===19)_f(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}i&=1}if(Ae(Ve,i),(t.mode&1)===0)t.memoizedState=null;else switch(l){case"forwards":for(n=t.child,l=null;n!==null;)e=n.alternate,e!==null&&xo(e)===null&&(l=n),n=n.sibling;n=l,n===null?(l=t.child,t.child=null):(l=n.sibling,n.sibling=null),Ia(t,!1,l,n,c);break;case"backwards":for(n=null,l=t.child,t.child=null;l!==null;){if(e=l.alternate,e!==null&&xo(e)===null){t.child=l;break}e=l.sibling,l.sibling=n,n=l,l=e}Ia(t,!0,n,null,c);break;case"together":Ia(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Co(e,t){(t.mode&1)===0&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function dn(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),or|=t.lanes,(n&t.childLanes)===0)return null;if(e!==null&&t.child!==e.child)throw Error(o(153));if(t.child!==null){for(e=t.child,n=Dn(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Dn(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function nv(e,t,n){switch(t.tag){case 3:Nf(t),$r();break;case 5:Bd(t);break;case 1:gt(t.type)&&ao(t);break;case 4:ya(t,t.stateNode.containerInfo);break;case 10:var i=t.type._context,l=t.memoizedProps.value;Ae(mo,i._currentValue),i._currentValue=l;break;case 13:if(i=t.memoizedState,i!==null)return i.dehydrated!==null?(Ae(Ve,Ve.current&1),t.flags|=128,null):(n&t.child.childLanes)!==0?Cf(e,t,n):(Ae(Ve,Ve.current&1),e=dn(e,t,n),e!==null?e.sibling:null);Ae(Ve,Ve.current&1);break;case 19:if(i=(n&t.childLanes)!==0,(e.flags&128)!==0){if(i)return Pf(e,t,n);t.flags|=128}if(l=t.memoizedState,l!==null&&(l.rendering=null,l.tail=null,l.lastEffect=null),Ae(Ve,Ve.current),i)break;return null;case 22:case 23:return t.lanes=0,bf(e,t,n)}return dn(e,t,n)}var Rf,Ua,Mf,Of;Rf=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},Ua=function(){},Mf=function(e,t,n,i){var l=e.memoizedProps;if(l!==i){e=t.stateNode,sr(Gt.current);var c=null;switch(n){case"input":l=rn(e,l),i=rn(e,i),c=[];break;case"select":l=Q({},l,{value:void 0}),i=Q({},i,{value:void 0}),c=[];break;case"textarea":l=yl(e,l),i=yl(e,i),c=[];break;default:typeof l.onClick!="function"&&typeof i.onClick=="function"&&(e.onclick=io)}wl(n,i);var p;n=null;for(T in l)if(!i.hasOwnProperty(T)&&l.hasOwnProperty(T)&&l[T]!=null)if(T==="style"){var v=l[T];for(p in v)v.hasOwnProperty(p)&&(n||(n={}),n[p]="")}else T!=="dangerouslySetInnerHTML"&&T!=="children"&&T!=="suppressContentEditableWarning"&&T!=="suppressHydrationWarning"&&T!=="autoFocus"&&(u.hasOwnProperty(T)?c||(c=[]):(c=c||[]).push(T,null));for(T in i){var S=i[T];if(v=l!=null?l[T]:void 0,i.hasOwnProperty(T)&&S!==v&&(S!=null||v!=null))if(T==="style")if(v){for(p in v)!v.hasOwnProperty(p)||S&&S.hasOwnProperty(p)||(n||(n={}),n[p]="");for(p in S)S.hasOwnProperty(p)&&v[p]!==S[p]&&(n||(n={}),n[p]=S[p])}else n||(c||(c=[]),c.push(T,n)),n=S;else T==="dangerouslySetInnerHTML"?(S=S?S.__html:void 0,v=v?v.__html:void 0,S!=null&&v!==S&&(c=c||[]).push(T,S)):T==="children"?typeof S!="string"&&typeof S!="number"||(c=c||[]).push(T,""+S):T!=="suppressContentEditableWarning"&&T!=="suppressHydrationWarning"&&(u.hasOwnProperty(T)?(S!=null&&T==="onScroll"&&Fe("scroll",e),c||v===S||(c=[])):(c=c||[]).push(T,S))}n&&(c=c||[]).push("style",n);var T=c;(t.updateQueue=T)&&(t.flags|=4)}},Of=function(e,t,n,i){n!==i&&(t.flags|=4)};function oi(e,t){if(!$e)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var i=null;n!==null;)n.alternate!==null&&(i=n),n=n.sibling;i===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:i.sibling=null}}function ut(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,i=0;if(t)for(var l=e.child;l!==null;)n|=l.lanes|l.childLanes,i|=l.subtreeFlags&14680064,i|=l.flags&14680064,l.return=e,l=l.sibling;else for(l=e.child;l!==null;)n|=l.lanes|l.childLanes,i|=l.subtreeFlags,i|=l.flags,l.return=e,l=l.sibling;return e.subtreeFlags|=i,e.childLanes=n,t}function rv(e,t,n){var i=t.pendingProps;switch(aa(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ut(t),null;case 1:return gt(t.type)&&lo(),ut(t),null;case 3:return i=t.stateNode,Wr(),Ie(mt),Ie(lt),ka(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),(e===null||e.child===null)&&(ho(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,It!==null&&(Ya(It),It=null))),Ua(e,t),ut(t),null;case 5:xa(t);var l=sr(ti.current);if(n=t.type,e!==null&&t.stateNode!=null)Mf(e,t,n,i,l),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!i){if(t.stateNode===null)throw Error(o(166));return ut(t),null}if(e=sr(Gt.current),ho(t)){i=t.stateNode,n=t.type;var c=t.memoizedProps;switch(i[qt]=t,i[Zs]=c,e=(t.mode&1)!==0,n){case"dialog":Fe("cancel",i),Fe("close",i);break;case"iframe":case"object":case"embed":Fe("load",i);break;case"video":case"audio":for(l=0;l<Ks.length;l++)Fe(Ks[l],i);break;case"source":Fe("error",i);break;case"img":case"image":case"link":Fe("error",i),Fe("load",i);break;case"details":Fe("toggle",i);break;case"input":js(i,c),Fe("invalid",i);break;case"select":i._wrapperState={wasMultiple:!!c.multiple},Fe("invalid",i);break;case"textarea":pc(i,c),Fe("invalid",i)}wl(n,c),l=null;for(var p in c)if(c.hasOwnProperty(p)){var v=c[p];p==="children"?typeof v=="string"?i.textContent!==v&&(c.suppressHydrationWarning!==!0&&so(i.textContent,v,e),l=["children",v]):typeof v=="number"&&i.textContent!==""+v&&(c.suppressHydrationWarning!==!0&&so(i.textContent,v,e),l=["children",""+v]):u.hasOwnProperty(p)&&v!=null&&p==="onScroll"&&Fe("scroll",i)}switch(n){case"input":Sr(i),Cs(i,c,!0);break;case"textarea":Sr(i),gc(i);break;case"select":case"option":break;default:typeof c.onClick=="function"&&(i.onclick=io)}i=l,t.updateQueue=i,i!==null&&(t.flags|=4)}else{p=l.nodeType===9?l:l.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=vc(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=p.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof i.is=="string"?e=p.createElement(n,{is:i.is}):(e=p.createElement(n),n==="select"&&(p=e,i.multiple?p.multiple=!0:i.size&&(p.size=i.size))):e=p.createElementNS(e,n),e[qt]=t,e[Zs]=i,Rf(e,t,!1,!1),t.stateNode=e;e:{switch(p=kl(n,i),n){case"dialog":Fe("cancel",e),Fe("close",e),l=i;break;case"iframe":case"object":case"embed":Fe("load",e),l=i;break;case"video":case"audio":for(l=0;l<Ks.length;l++)Fe(Ks[l],e);l=i;break;case"source":Fe("error",e),l=i;break;case"img":case"image":case"link":Fe("error",e),Fe("load",e),l=i;break;case"details":Fe("toggle",e),l=i;break;case"input":js(e,i),l=rn(e,i),Fe("invalid",e);break;case"option":l=i;break;case"select":e._wrapperState={wasMultiple:!!i.multiple},l=Q({},i,{value:void 0}),Fe("invalid",e);break;case"textarea":pc(e,i),l=yl(e,i),Fe("invalid",e);break;default:l=i}wl(n,l),v=l;for(c in v)if(v.hasOwnProperty(c)){var S=v[c];c==="style"?wc(e,S):c==="dangerouslySetInnerHTML"?(S=S?S.__html:void 0,S!=null&&yc(e,S)):c==="children"?typeof S=="string"?(n!=="textarea"||S!=="")&&_s(e,S):typeof S=="number"&&_s(e,""+S):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(u.hasOwnProperty(c)?S!=null&&c==="onScroll"&&Fe("scroll",e):S!=null&&V(e,c,S,p))}switch(n){case"input":Sr(e),Cs(e,i,!1);break;case"textarea":Sr(e),gc(e);break;case"option":i.value!=null&&e.setAttribute("value",""+ye(i.value));break;case"select":e.multiple=!!i.multiple,c=i.value,c!=null?ze(e,!!i.multiple,c,!1):i.defaultValue!=null&&ze(e,!!i.multiple,i.defaultValue,!0);break;default:typeof l.onClick=="function"&&(e.onclick=io)}switch(n){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}}i&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return ut(t),null;case 6:if(e&&t.stateNode!=null)Of(e,t,e.memoizedProps,i);else{if(typeof i!="string"&&t.stateNode===null)throw Error(o(166));if(n=sr(ti.current),sr(Gt.current),ho(t)){if(i=t.stateNode,n=t.memoizedProps,i[qt]=t,(c=i.nodeValue!==n)&&(e=Nt,e!==null))switch(e.tag){case 3:so(i.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&so(i.nodeValue,n,(e.mode&1)!==0)}c&&(t.flags|=4)}else i=(n.nodeType===9?n:n.ownerDocument).createTextNode(i),i[qt]=t,t.stateNode=i}return ut(t),null;case 13:if(Ie(Ve),i=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if($e&&jt!==null&&(t.mode&1)!==0&&(t.flags&128)===0)Ld(),$r(),t.flags|=98560,c=!1;else if(c=ho(t),i!==null&&i.dehydrated!==null){if(e===null){if(!c)throw Error(o(318));if(c=t.memoizedState,c=c!==null?c.dehydrated:null,!c)throw Error(o(317));c[qt]=t}else $r(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;ut(t),c=!1}else It!==null&&(Ya(It),It=null),c=!0;if(!c)return t.flags&65536?t:null}return(t.flags&128)!==0?(t.lanes=n,t):(i=i!==null,i!==(e!==null&&e.memoizedState!==null)&&i&&(t.child.flags|=8192,(t.mode&1)!==0&&(e===null||(Ve.current&1)!==0?Xe===0&&(Xe=3):eu())),t.updateQueue!==null&&(t.flags|=4),ut(t),null);case 4:return Wr(),Ua(e,t),e===null&&qs(t.stateNode.containerInfo),ut(t),null;case 10:return pa(t.type._context),ut(t),null;case 17:return gt(t.type)&&lo(),ut(t),null;case 19:if(Ie(Ve),c=t.memoizedState,c===null)return ut(t),null;if(i=(t.flags&128)!==0,p=c.rendering,p===null)if(i)oi(c,!1);else{if(Xe!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(p=xo(e),p!==null){for(t.flags|=128,oi(c,!1),i=p.updateQueue,i!==null&&(t.updateQueue=i,t.flags|=4),t.subtreeFlags=0,i=n,n=t.child;n!==null;)c=n,e=i,c.flags&=14680066,p=c.alternate,p===null?(c.childLanes=0,c.lanes=e,c.child=null,c.subtreeFlags=0,c.memoizedProps=null,c.memoizedState=null,c.updateQueue=null,c.dependencies=null,c.stateNode=null):(c.childLanes=p.childLanes,c.lanes=p.lanes,c.child=p.child,c.subtreeFlags=0,c.deletions=null,c.memoizedProps=p.memoizedProps,c.memoizedState=p.memoizedState,c.updateQueue=p.updateQueue,c.type=p.type,e=p.dependencies,c.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Ae(Ve,Ve.current&1|2),t.child}e=e.sibling}c.tail!==null&&Ke()>Gr&&(t.flags|=128,i=!0,oi(c,!1),t.lanes=4194304)}else{if(!i)if(e=xo(p),e!==null){if(t.flags|=128,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),oi(c,!0),c.tail===null&&c.tailMode==="hidden"&&!p.alternate&&!$e)return ut(t),null}else 2*Ke()-c.renderingStartTime>Gr&&n!==1073741824&&(t.flags|=128,i=!0,oi(c,!1),t.lanes=4194304);c.isBackwards?(p.sibling=t.child,t.child=p):(n=c.last,n!==null?n.sibling=p:t.child=p,c.last=p)}return c.tail!==null?(t=c.tail,c.rendering=t,c.tail=t.sibling,c.renderingStartTime=Ke(),t.sibling=null,n=Ve.current,Ae(Ve,i?n&1|2:n&1),t):(ut(t),null);case 22:case 23:return Ja(),i=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(t.flags|=8192),i&&(t.mode&1)!==0?(Ct&1073741824)!==0&&(ut(t),t.subtreeFlags&6&&(t.flags|=8192)):ut(t),null;case 24:return null;case 25:return null}throw Error(o(156,t.tag))}function sv(e,t){switch(aa(t),t.tag){case 1:return gt(t.type)&&lo(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Wr(),Ie(mt),Ie(lt),ka(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 5:return xa(t),null;case 13:if(Ie(Ve),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(o(340));$r()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Ie(Ve),null;case 4:return Wr(),null;case 10:return pa(t.type._context),null;case 22:case 23:return Ja(),null;case 24:return null;default:return null}}var _o=!1,ct=!1,iv=typeof WeakSet=="function"?WeakSet:Set,te=null;function Kr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){We(e,t,i)}else n.current=null}function $a(e,t,n){try{n()}catch(i){We(e,t,i)}}var Tf=!1;function ov(e,t){if(Jl=Ki,e=cd(),Wl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var l=i.anchorOffset,c=i.focusNode;i=i.focusOffset;try{n.nodeType,c.nodeType}catch{n=null;break e}var p=0,v=-1,S=-1,T=0,$=0,B=e,U=null;t:for(;;){for(var X;B!==n||l!==0&&B.nodeType!==3||(v=p+l),B!==c||i!==0&&B.nodeType!==3||(S=p+i),B.nodeType===3&&(p+=B.nodeValue.length),(X=B.firstChild)!==null;)U=B,B=X;for(;;){if(B===e)break t;if(U===n&&++T===l&&(v=p),U===c&&++$===i&&(S=p),(X=B.nextSibling)!==null)break;B=U,U=B.parentNode}B=X}n=v===-1||S===-1?null:{start:v,end:S}}else n=null}n=n||{start:0,end:0}}else n=null;for(ea={focusedElem:e,selectionRange:n},Ki=!1,te=t;te!==null;)if(t=te,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,te=e;else for(;te!==null;){t=te;try{var re=t.alternate;if((t.flags&1024)!==0)switch(t.tag){case 0:case 11:case 15:break;case 1:if(re!==null){var ie=re.memoizedProps,qe=re.memoizedState,M=t.stateNode,j=M.getSnapshotBeforeUpdate(t.elementType===t.type?ie:Ut(t.type,ie),qe);M.__reactInternalSnapshotBeforeUpdate=j}break;case 3:var O=t.stateNode.containerInfo;O.nodeType===1?O.textContent="":O.nodeType===9&&O.documentElement&&O.removeChild(O.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(o(163))}}catch(H){We(t,t.return,H)}if(e=t.sibling,e!==null){e.return=t.return,te=e;break}te=t.return}return re=Tf,Tf=!1,re}function li(e,t,n){var i=t.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var l=i=i.next;do{if((l.tag&e)===e){var c=l.destroy;l.destroy=void 0,c!==void 0&&$a(t,n,c)}l=l.next}while(l!==i)}}function Po(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var i=n.create;n.destroy=i()}n=n.next}while(n!==t)}}function Ba(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Lf(e){var t=e.alternate;t!==null&&(e.alternate=null,Lf(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[qt],delete t[Zs],delete t[sa],delete t[Bg],delete t[Vg])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Df(e){return e.tag===5||e.tag===3||e.tag===4}function Af(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Df(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.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 Va(e,t,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=io));else if(i!==4&&(e=e.child,e!==null))for(Va(e,t,n),e=e.sibling;e!==null;)Va(e,t,n),e=e.sibling}function Ha(e,t,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(i!==4&&(e=e.child,e!==null))for(Ha(e,t,n),e=e.sibling;e!==null;)Ha(e,t,n),e=e.sibling}var rt=null,$t=!1;function Rn(e,t,n){for(n=n.child;n!==null;)zf(e,t,n),n=n.sibling}function zf(e,t,n){if(Kt&&typeof Kt.onCommitFiberUnmount=="function")try{Kt.onCommitFiberUnmount($i,n)}catch{}switch(n.tag){case 5:ct||Kr(n,t);case 6:var i=rt,l=$t;rt=null,Rn(e,t,n),rt=i,$t=l,rt!==null&&($t?(e=rt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):rt.removeChild(n.stateNode));break;case 18:rt!==null&&($t?(e=rt,n=n.stateNode,e.nodeType===8?ra(e.parentNode,n):e.nodeType===1&&ra(e,n),Is(e)):ra(rt,n.stateNode));break;case 4:i=rt,l=$t,rt=n.stateNode.containerInfo,$t=!0,Rn(e,t,n),rt=i,$t=l;break;case 0:case 11:case 14:case 15:if(!ct&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){l=i=i.next;do{var c=l,p=c.destroy;c=c.tag,p!==void 0&&((c&2)!==0||(c&4)!==0)&&$a(n,t,p),l=l.next}while(l!==i)}Rn(e,t,n);break;case 1:if(!ct&&(Kr(n,t),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(v){We(n,t,v)}Rn(e,t,n);break;case 21:Rn(e,t,n);break;case 22:n.mode&1?(ct=(i=ct)||n.memoizedState!==null,Rn(e,t,n),ct=i):Rn(e,t,n);break;default:Rn(e,t,n)}}function Ff(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new iv),t.forEach(function(i){var l=mv.bind(null,e,i);n.has(i)||(n.add(i),i.then(l,l))})}}function Bt(e,t){var n=t.deletions;if(n!==null)for(var i=0;i<n.length;i++){var l=n[i];try{var c=e,p=t,v=p;e:for(;v!==null;){switch(v.tag){case 5:rt=v.stateNode,$t=!1;break e;case 3:rt=v.stateNode.containerInfo,$t=!0;break e;case 4:rt=v.stateNode.containerInfo,$t=!0;break e}v=v.return}if(rt===null)throw Error(o(160));zf(c,p,l),rt=null,$t=!1;var S=l.alternate;S!==null&&(S.return=null),l.return=null}catch(T){We(l,t,T)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)If(t,e),t=t.sibling}function If(e,t){var n=e.alternate,i=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Bt(t,e),Yt(e),i&4){try{li(3,e,e.return),Po(3,e)}catch(ie){We(e,e.return,ie)}try{li(5,e,e.return)}catch(ie){We(e,e.return,ie)}}break;case 1:Bt(t,e),Yt(e),i&512&&n!==null&&Kr(n,n.return);break;case 5:if(Bt(t,e),Yt(e),i&512&&n!==null&&Kr(n,n.return),e.flags&32){var l=e.stateNode;try{_s(l,"")}catch(ie){We(e,e.return,ie)}}if(i&4&&(l=e.stateNode,l!=null)){var c=e.memoizedProps,p=n!==null?n.memoizedProps:c,v=e.type,S=e.updateQueue;if(e.updateQueue=null,S!==null)try{v==="input"&&c.type==="radio"&&c.name!=null&&Nr(l,c),kl(v,p);var T=kl(v,c);for(p=0;p<S.length;p+=2){var $=S[p],B=S[p+1];$==="style"?wc(l,B):$==="dangerouslySetInnerHTML"?yc(l,B):$==="children"?_s(l,B):V(l,$,B,T)}switch(v){case"input":jr(l,c);break;case"textarea":mc(l,c);break;case"select":var U=l._wrapperState.wasMultiple;l._wrapperState.wasMultiple=!!c.multiple;var X=c.value;X!=null?ze(l,!!c.multiple,X,!1):U!==!!c.multiple&&(c.defaultValue!=null?ze(l,!!c.multiple,c.defaultValue,!0):ze(l,!!c.multiple,c.multiple?[]:"",!1))}l[Zs]=c}catch(ie){We(e,e.return,ie)}}break;case 6:if(Bt(t,e),Yt(e),i&4){if(e.stateNode===null)throw Error(o(162));l=e.stateNode,c=e.memoizedProps;try{l.nodeValue=c}catch(ie){We(e,e.return,ie)}}break;case 3:if(Bt(t,e),Yt(e),i&4&&n!==null&&n.memoizedState.isDehydrated)try{Is(t.containerInfo)}catch(ie){We(e,e.return,ie)}break;case 4:Bt(t,e),Yt(e);break;case 13:Bt(t,e),Yt(e),l=e.child,l.flags&8192&&(c=l.memoizedState!==null,l.stateNode.isHidden=c,!c||l.alternate!==null&&l.alternate.memoizedState!==null||(Ka=Ke())),i&4&&Ff(e);break;case 22:if($=n!==null&&n.memoizedState!==null,e.mode&1?(ct=(T=ct)||$,Bt(t,e),ct=T):Bt(t,e),Yt(e),i&8192){if(T=e.memoizedState!==null,(e.stateNode.isHidden=T)&&!$&&(e.mode&1)!==0)for(te=e,$=e.child;$!==null;){for(B=te=$;te!==null;){switch(U=te,X=U.child,U.tag){case 0:case 11:case 14:case 15:li(4,U,U.return);break;case 1:Kr(U,U.return);var re=U.stateNode;if(typeof re.componentWillUnmount=="function"){i=U,n=U.return;try{t=i,re.props=t.memoizedProps,re.state=t.memoizedState,re.componentWillUnmount()}catch(ie){We(i,n,ie)}}break;case 5:Kr(U,U.return);break;case 22:if(U.memoizedState!==null){Bf(B);continue}}X!==null?(X.return=U,te=X):Bf(B)}$=$.sibling}e:for($=null,B=e;;){if(B.tag===5){if($===null){$=B;try{l=B.stateNode,T?(c=l.style,typeof c.setProperty=="function"?c.setProperty("display","none","important"):c.display="none"):(v=B.stateNode,S=B.memoizedProps.style,p=S!=null&&S.hasOwnProperty("display")?S.display:null,v.style.display=xc("display",p))}catch(ie){We(e,e.return,ie)}}}else if(B.tag===6){if($===null)try{B.stateNode.nodeValue=T?"":B.memoizedProps}catch(ie){We(e,e.return,ie)}}else if((B.tag!==22&&B.tag!==23||B.memoizedState===null||B===e)&&B.child!==null){B.child.return=B,B=B.child;continue}if(B===e)break e;for(;B.sibling===null;){if(B.return===null||B.return===e)break e;$===B&&($=null),B=B.return}$===B&&($=null),B.sibling.return=B.return,B=B.sibling}}break;case 19:Bt(t,e),Yt(e),i&4&&Ff(e);break;case 21:break;default:Bt(t,e),Yt(e)}}function Yt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Df(n)){var i=n;break e}n=n.return}throw Error(o(160))}switch(i.tag){case 5:var l=i.stateNode;i.flags&32&&(_s(l,""),i.flags&=-33);var c=Af(e);Ha(e,c,l);break;case 3:case 4:var p=i.stateNode.containerInfo,v=Af(e);Va(e,v,p);break;default:throw Error(o(161))}}catch(S){We(e,e.return,S)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function lv(e,t,n){te=e,Uf(e)}function Uf(e,t,n){for(var i=(e.mode&1)!==0;te!==null;){var l=te,c=l.child;if(l.tag===22&&i){var p=l.memoizedState!==null||_o;if(!p){var v=l.alternate,S=v!==null&&v.memoizedState!==null||ct;v=_o;var T=ct;if(_o=p,(ct=S)&&!T)for(te=l;te!==null;)p=te,S=p.child,p.tag===22&&p.memoizedState!==null?Vf(l):S!==null?(S.return=p,te=S):Vf(l);for(;c!==null;)te=c,Uf(c),c=c.sibling;te=l,_o=v,ct=T}$f(e)}else(l.subtreeFlags&8772)!==0&&c!==null?(c.return=l,te=c):$f(e)}}function $f(e){for(;te!==null;){var t=te;if((t.flags&8772)!==0){var n=t.alternate;try{if((t.flags&8772)!==0)switch(t.tag){case 0:case 11:case 15:ct||Po(5,t);break;case 1:var i=t.stateNode;if(t.flags&4&&!ct)if(n===null)i.componentDidMount();else{var l=t.elementType===t.type?n.memoizedProps:Ut(t.type,n.memoizedProps);i.componentDidUpdate(l,n.memoizedState,i.__reactInternalSnapshotBeforeUpdate)}var c=t.updateQueue;c!==null&&$d(t,c,i);break;case 3:var p=t.updateQueue;if(p!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}$d(t,p,n)}break;case 5:var v=t.stateNode;if(n===null&&t.flags&4){n=v;var S=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":S.autoFocus&&n.focus();break;case"img":S.src&&(n.src=S.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var T=t.alternate;if(T!==null){var $=T.memoizedState;if($!==null){var B=$.dehydrated;B!==null&&Is(B)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(o(163))}ct||t.flags&512&&Ba(t)}catch(U){We(t,t.return,U)}}if(t===e){te=null;break}if(n=t.sibling,n!==null){n.return=t.return,te=n;break}te=t.return}}function Bf(e){for(;te!==null;){var t=te;if(t===e){te=null;break}var n=t.sibling;if(n!==null){n.return=t.return,te=n;break}te=t.return}}function Vf(e){for(;te!==null;){var t=te;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Po(4,t)}catch(S){We(t,n,S)}break;case 1:var i=t.stateNode;if(typeof i.componentDidMount=="function"){var l=t.return;try{i.componentDidMount()}catch(S){We(t,l,S)}}var c=t.return;try{Ba(t)}catch(S){We(t,c,S)}break;case 5:var p=t.return;try{Ba(t)}catch(S){We(t,p,S)}}}catch(S){We(t,t.return,S)}if(t===e){te=null;break}var v=t.sibling;if(v!==null){v.return=t.return,te=v;break}te=t.return}}var av=Math.ceil,Ro=z.ReactCurrentDispatcher,Wa=z.ReactCurrentOwner,Lt=z.ReactCurrentBatchConfig,Me=0,et=null,Ze=null,st=0,Ct=0,qr=Nn(0),Xe=0,ai=null,or=0,Mo=0,Qa=0,ui=null,yt=null,Ka=0,Gr=1/0,fn=null,Oo=!1,qa=null,Mn=null,To=!1,On=null,Lo=0,ci=0,Ga=null,Do=-1,Ao=0;function ht(){return(Me&6)!==0?Ke():Do!==-1?Do:Do=Ke()}function Tn(e){return(e.mode&1)===0?1:(Me&2)!==0&&st!==0?st&-st:Wg.transition!==null?(Ao===0&&(Ao=Dc()),Ao):(e=De,e!==0||(e=window.event,e=e===void 0?16:Hc(e.type)),e)}function Vt(e,t,n,i){if(50<ci)throw ci=0,Ga=null,Error(o(185));Ls(e,n,i),((Me&2)===0||e!==et)&&(e===et&&((Me&2)===0&&(Mo|=n),Xe===4&&Ln(e,st)),xt(e,i),n===1&&Me===0&&(t.mode&1)===0&&(Gr=Ke()+500,uo&&Cn()))}function xt(e,t){var n=e.callbackNode;Wm(e,t);var i=Hi(e,e===et?st:0);if(i===0)n!==null&&Oc(n),e.callbackNode=null,e.callbackPriority=0;else if(t=i&-i,e.callbackPriority!==t){if(n!=null&&Oc(n),t===1)e.tag===0?Hg(Wf.bind(null,e)):Pd(Wf.bind(null,e)),Ug(function(){(Me&6)===0&&Cn()}),n=null;else{switch(Ac(i)){case 1:n=_l;break;case 4:n=Tc;break;case 16:n=Ui;break;case 536870912:n=Lc;break;default:n=Ui}n=Jf(n,Hf.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Hf(e,t){if(Do=-1,Ao=0,(Me&6)!==0)throw Error(o(327));var n=e.callbackNode;if(Zr()&&e.callbackNode!==n)return null;var i=Hi(e,e===et?st:0);if(i===0)return null;if((i&30)!==0||(i&e.expiredLanes)!==0||t)t=zo(e,i);else{t=i;var l=Me;Me|=2;var c=Kf();(et!==e||st!==t)&&(fn=null,Gr=Ke()+500,ar(e,t));do try{dv();break}catch(v){Qf(e,v)}while(!0);ha(),Ro.current=c,Me=l,Ze!==null?t=0:(et=null,st=0,t=Xe)}if(t!==0){if(t===2&&(l=Pl(e),l!==0&&(i=l,t=Za(e,l))),t===1)throw n=ai,ar(e,0),Ln(e,i),xt(e,Ke()),n;if(t===6)Ln(e,i);else{if(l=e.current.alternate,(i&30)===0&&!uv(l)&&(t=zo(e,i),t===2&&(c=Pl(e),c!==0&&(i=c,t=Za(e,c))),t===1))throw n=ai,ar(e,0),Ln(e,i),xt(e,Ke()),n;switch(e.finishedWork=l,e.finishedLanes=i,t){case 0:case 1:throw Error(o(345));case 2:ur(e,yt,fn);break;case 3:if(Ln(e,i),(i&130023424)===i&&(t=Ka+500-Ke(),10<t)){if(Hi(e,0)!==0)break;if(l=e.suspendedLanes,(l&i)!==i){ht(),e.pingedLanes|=e.suspendedLanes&l;break}e.timeoutHandle=na(ur.bind(null,e,yt,fn),t);break}ur(e,yt,fn);break;case 4:if(Ln(e,i),(i&4194240)===i)break;for(t=e.eventTimes,l=-1;0<i;){var p=31-zt(i);c=1<<p,p=t[p],p>l&&(l=p),i&=~c}if(i=l,i=Ke()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*av(i/1960))-i,10<i){e.timeoutHandle=na(ur.bind(null,e,yt,fn),i);break}ur(e,yt,fn);break;case 5:ur(e,yt,fn);break;default:throw Error(o(329))}}}return xt(e,Ke()),e.callbackNode===n?Hf.bind(null,e):null}function Za(e,t){var n=ui;return e.current.memoizedState.isDehydrated&&(ar(e,t).flags|=256),e=zo(e,t),e!==2&&(t=yt,yt=n,t!==null&&Ya(t)),e}function Ya(e){yt===null?yt=e:yt.push.apply(yt,e)}function uv(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var i=0;i<n.length;i++){var l=n[i],c=l.getSnapshot;l=l.value;try{if(!Ft(c(),l))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ln(e,t){for(t&=~Qa,t&=~Mo,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-zt(t),i=1<<n;e[n]=-1,t&=~i}}function Wf(e){if((Me&6)!==0)throw Error(o(327));Zr();var t=Hi(e,0);if((t&1)===0)return xt(e,Ke()),null;var n=zo(e,t);if(e.tag!==0&&n===2){var i=Pl(e);i!==0&&(t=i,n=Za(e,i))}if(n===1)throw n=ai,ar(e,0),Ln(e,t),xt(e,Ke()),n;if(n===6)throw Error(o(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,ur(e,yt,fn),xt(e,Ke()),null}function Xa(e,t){var n=Me;Me|=1;try{return e(t)}finally{Me=n,Me===0&&(Gr=Ke()+500,uo&&Cn())}}function lr(e){On!==null&&On.tag===0&&(Me&6)===0&&Zr();var t=Me;Me|=1;var n=Lt.transition,i=De;try{if(Lt.transition=null,De=1,e)return e()}finally{De=i,Lt.transition=n,Me=t,(Me&6)===0&&Cn()}}function Ja(){Ct=qr.current,Ie(qr)}function ar(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,Ig(n)),Ze!==null)for(n=Ze.return;n!==null;){var i=n;switch(aa(i),i.tag){case 1:i=i.type.childContextTypes,i!=null&&lo();break;case 3:Wr(),Ie(mt),Ie(lt),ka();break;case 5:xa(i);break;case 4:Wr();break;case 13:Ie(Ve);break;case 19:Ie(Ve);break;case 10:pa(i.type._context);break;case 22:case 23:Ja()}n=n.return}if(et=e,Ze=e=Dn(e.current,null),st=Ct=t,Xe=0,ai=null,Qa=Mo=or=0,yt=ui=null,rr!==null){for(t=0;t<rr.length;t++)if(n=rr[t],i=n.interleaved,i!==null){n.interleaved=null;var l=i.next,c=n.pending;if(c!==null){var p=c.next;c.next=l,i.next=p}n.pending=i}rr=null}return e}function Qf(e,t){do{var n=Ze;try{if(ha(),wo.current=Eo,ko){for(var i=He.memoizedState;i!==null;){var l=i.queue;l!==null&&(l.pending=null),i=i.next}ko=!1}if(ir=0,Je=Ye=He=null,ni=!1,ri=0,Wa.current=null,n===null||n.return===null){Xe=1,ai=t,Ze=null;break}e:{var c=e,p=n.return,v=n,S=t;if(t=st,v.flags|=32768,S!==null&&typeof S=="object"&&typeof S.then=="function"){var T=S,$=v,B=$.tag;if(($.mode&1)===0&&(B===0||B===11||B===15)){var U=$.alternate;U?($.updateQueue=U.updateQueue,$.memoizedState=U.memoizedState,$.lanes=U.lanes):($.updateQueue=null,$.memoizedState=null)}var X=vf(p);if(X!==null){X.flags&=-257,yf(X,p,v,c,t),X.mode&1&&gf(c,T,t),t=X,S=T;var re=t.updateQueue;if(re===null){var ie=new Set;ie.add(S),t.updateQueue=ie}else re.add(S);break e}else{if((t&1)===0){gf(c,T,t),eu();break e}S=Error(o(426))}}else if($e&&v.mode&1){var qe=vf(p);if(qe!==null){(qe.flags&65536)===0&&(qe.flags|=256),yf(qe,p,v,c,t),da(Qr(S,v));break e}}c=S=Qr(S,v),Xe!==4&&(Xe=2),ui===null?ui=[c]:ui.push(c),c=p;do{switch(c.tag){case 3:c.flags|=65536,t&=-t,c.lanes|=t;var M=pf(c,S,t);Ud(c,M);break e;case 1:v=S;var j=c.type,O=c.stateNode;if((c.flags&128)===0&&(typeof j.getDerivedStateFromError=="function"||O!==null&&typeof O.componentDidCatch=="function"&&(Mn===null||!Mn.has(O)))){c.flags|=65536,t&=-t,c.lanes|=t;var H=mf(c,v,t);Ud(c,H);break e}}c=c.return}while(c!==null)}Gf(n)}catch(ae){t=ae,Ze===n&&n!==null&&(Ze=n=n.return);continue}break}while(!0)}function Kf(){var e=Ro.current;return Ro.current=Eo,e===null?Eo:e}function eu(){(Xe===0||Xe===3||Xe===2)&&(Xe=4),et===null||(or&268435455)===0&&(Mo&268435455)===0||Ln(et,st)}function zo(e,t){var n=Me;Me|=2;var i=Kf();(et!==e||st!==t)&&(fn=null,ar(e,t));do try{cv();break}catch(l){Qf(e,l)}while(!0);if(ha(),Me=n,Ro.current=i,Ze!==null)throw Error(o(261));return et=null,st=0,Xe}function cv(){for(;Ze!==null;)qf(Ze)}function dv(){for(;Ze!==null&&!Am();)qf(Ze)}function qf(e){var t=Xf(e.alternate,e,Ct);e.memoizedProps=e.pendingProps,t===null?Gf(e):Ze=t,Wa.current=null}function Gf(e){var t=e;do{var n=t.alternate;if(e=t.return,(t.flags&32768)===0){if(n=rv(n,t,Ct),n!==null){Ze=n;return}}else{if(n=sv(n,t),n!==null){n.flags&=32767,Ze=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Xe=6,Ze=null;return}}if(t=t.sibling,t!==null){Ze=t;return}Ze=t=e}while(t!==null);Xe===0&&(Xe=5)}function ur(e,t,n){var i=De,l=Lt.transition;try{Lt.transition=null,De=1,fv(e,t,n,i)}finally{Lt.transition=l,De=i}return null}function fv(e,t,n,i){do Zr();while(On!==null);if((Me&6)!==0)throw Error(o(327));n=e.finishedWork;var l=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(o(177));e.callbackNode=null,e.callbackPriority=0;var c=n.lanes|n.childLanes;if(Qm(e,c),e===et&&(Ze=et=null,st=0),(n.subtreeFlags&2064)===0&&(n.flags&2064)===0||To||(To=!0,Jf(Ui,function(){return Zr(),null})),c=(n.flags&15990)!==0,(n.subtreeFlags&15990)!==0||c){c=Lt.transition,Lt.transition=null;var p=De;De=1;var v=Me;Me|=4,Wa.current=null,ov(e,n),If(n,e),Og(ea),Ki=!!Jl,ea=Jl=null,e.current=n,lv(n),zm(),Me=v,De=p,Lt.transition=c}else e.current=n;if(To&&(To=!1,On=e,Lo=l),c=e.pendingLanes,c===0&&(Mn=null),Um(n.stateNode),xt(e,Ke()),t!==null)for(i=e.onRecoverableError,n=0;n<t.length;n++)l=t[n],i(l.value,{componentStack:l.stack,digest:l.digest});if(Oo)throw Oo=!1,e=qa,qa=null,e;return(Lo&1)!==0&&e.tag!==0&&Zr(),c=e.pendingLanes,(c&1)!==0?e===Ga?ci++:(ci=0,Ga=e):ci=0,Cn(),null}function Zr(){if(On!==null){var e=Ac(Lo),t=Lt.transition,n=De;try{if(Lt.transition=null,De=16>e?16:e,On===null)var i=!1;else{if(e=On,On=null,Lo=0,(Me&6)!==0)throw Error(o(331));var l=Me;for(Me|=4,te=e.current;te!==null;){var c=te,p=c.child;if((te.flags&16)!==0){var v=c.deletions;if(v!==null){for(var S=0;S<v.length;S++){var T=v[S];for(te=T;te!==null;){var $=te;switch($.tag){case 0:case 11:case 15:li(8,$,c)}var B=$.child;if(B!==null)B.return=$,te=B;else for(;te!==null;){$=te;var U=$.sibling,X=$.return;if(Lf($),$===T){te=null;break}if(U!==null){U.return=X,te=U;break}te=X}}}var re=c.alternate;if(re!==null){var ie=re.child;if(ie!==null){re.child=null;do{var qe=ie.sibling;ie.sibling=null,ie=qe}while(ie!==null)}}te=c}}if((c.subtreeFlags&2064)!==0&&p!==null)p.return=c,te=p;else e:for(;te!==null;){if(c=te,(c.flags&2048)!==0)switch(c.tag){case 0:case 11:case 15:li(9,c,c.return)}var M=c.sibling;if(M!==null){M.return=c.return,te=M;break e}te=c.return}}var j=e.current;for(te=j;te!==null;){p=te;var O=p.child;if((p.subtreeFlags&2064)!==0&&O!==null)O.return=p,te=O;else e:for(p=j;te!==null;){if(v=te,(v.flags&2048)!==0)try{switch(v.tag){case 0:case 11:case 15:Po(9,v)}}catch(ae){We(v,v.return,ae)}if(v===p){te=null;break e}var H=v.sibling;if(H!==null){H.return=v.return,te=H;break e}te=v.return}}if(Me=l,Cn(),Kt&&typeof Kt.onPostCommitFiberRoot=="function")try{Kt.onPostCommitFiberRoot($i,e)}catch{}i=!0}return i}finally{De=n,Lt.transition=t}}return!1}function Zf(e,t,n){t=Qr(n,t),t=pf(e,t,1),e=Pn(e,t,1),t=ht(),e!==null&&(Ls(e,1,t),xt(e,t))}function We(e,t,n){if(e.tag===3)Zf(e,e,n);else for(;t!==null;){if(t.tag===3){Zf(t,e,n);break}else if(t.tag===1){var i=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof i.componentDidCatch=="function"&&(Mn===null||!Mn.has(i))){e=Qr(n,e),e=mf(t,e,1),t=Pn(t,e,1),e=ht(),t!==null&&(Ls(t,1,e),xt(t,e));break}}t=t.return}}function hv(e,t,n){var i=e.pingCache;i!==null&&i.delete(t),t=ht(),e.pingedLanes|=e.suspendedLanes&n,et===e&&(st&n)===n&&(Xe===4||Xe===3&&(st&130023424)===st&&500>Ke()-Ka?ar(e,0):Qa|=n),xt(e,t)}function Yf(e,t){t===0&&((e.mode&1)===0?t=1:(t=Vi,Vi<<=1,(Vi&130023424)===0&&(Vi=4194304)));var n=ht();e=un(e,t),e!==null&&(Ls(e,t,n),xt(e,n))}function pv(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Yf(e,n)}function mv(e,t){var n=0;switch(e.tag){case 13:var i=e.stateNode,l=e.memoizedState;l!==null&&(n=l.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(o(314))}i!==null&&i.delete(t),Yf(e,n)}var Xf;Xf=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||mt.current)vt=!0;else{if((e.lanes&n)===0&&(t.flags&128)===0)return vt=!1,nv(e,t,n);vt=(e.flags&131072)!==0}else vt=!1,$e&&(t.flags&1048576)!==0&&Rd(t,fo,t.index);switch(t.lanes=0,t.tag){case 2:var i=t.type;Co(e,t),e=t.pendingProps;var l=Fr(t,lt.current);Hr(t,n),l=Ea(null,t,i,e,l,n);var c=Na();return t.flags|=1,typeof l=="object"&&l!==null&&typeof l.render=="function"&&l.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,gt(i)?(c=!0,ao(t)):c=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,va(t),l.updater=No,t.stateNode=l,l._reactInternals=t,Ma(t,i,e,n),t=Da(null,t,i,!0,c,n)):(t.tag=0,$e&&c&&la(t),ft(null,t,l,n),t=t.child),t;case 16:i=t.elementType;e:{switch(Co(e,t),e=t.pendingProps,l=i._init,i=l(i._payload),t.type=i,l=t.tag=vv(i),e=Ut(i,e),l){case 0:t=La(null,t,i,e,n);break e;case 1:t=Ef(null,t,i,e,n);break e;case 11:t=xf(null,t,i,e,n);break e;case 14:t=wf(null,t,i,Ut(i.type,e),n);break e}throw Error(o(306,i,""))}return t;case 0:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:Ut(i,l),La(e,t,i,l,n);case 1:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:Ut(i,l),Ef(e,t,i,l,n);case 3:e:{if(Nf(t),e===null)throw Error(o(387));i=t.pendingProps,c=t.memoizedState,l=c.element,Id(e,t),yo(t,i,null,n);var p=t.memoizedState;if(i=p.element,c.isDehydrated)if(c={element:i,isDehydrated:!1,cache:p.cache,pendingSuspenseBoundaries:p.pendingSuspenseBoundaries,transitions:p.transitions},t.updateQueue.baseState=c,t.memoizedState=c,t.flags&256){l=Qr(Error(o(423)),t),t=jf(e,t,i,n,l);break e}else if(i!==l){l=Qr(Error(o(424)),t),t=jf(e,t,i,n,l);break e}else for(jt=En(t.stateNode.containerInfo.firstChild),Nt=t,$e=!0,It=null,n=zd(t,null,i,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if($r(),i===l){t=dn(e,t,n);break e}ft(e,t,i,n)}t=t.child}return t;case 5:return Bd(t),e===null&&ca(t),i=t.type,l=t.pendingProps,c=e!==null?e.memoizedProps:null,p=l.children,ta(i,l)?p=null:c!==null&&ta(i,c)&&(t.flags|=32),Sf(e,t),ft(e,t,p,n),t.child;case 6:return e===null&&ca(t),null;case 13:return Cf(e,t,n);case 4:return ya(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=Br(t,null,i,n):ft(e,t,i,n),t.child;case 11:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:Ut(i,l),xf(e,t,i,l,n);case 7:return ft(e,t,t.pendingProps,n),t.child;case 8:return ft(e,t,t.pendingProps.children,n),t.child;case 12:return ft(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(i=t.type._context,l=t.pendingProps,c=t.memoizedProps,p=l.value,Ae(mo,i._currentValue),i._currentValue=p,c!==null)if(Ft(c.value,p)){if(c.children===l.children&&!mt.current){t=dn(e,t,n);break e}}else for(c=t.child,c!==null&&(c.return=t);c!==null;){var v=c.dependencies;if(v!==null){p=c.child;for(var S=v.firstContext;S!==null;){if(S.context===i){if(c.tag===1){S=cn(-1,n&-n),S.tag=2;var T=c.updateQueue;if(T!==null){T=T.shared;var $=T.pending;$===null?S.next=S:(S.next=$.next,$.next=S),T.pending=S}}c.lanes|=n,S=c.alternate,S!==null&&(S.lanes|=n),ma(c.return,n,t),v.lanes|=n;break}S=S.next}}else if(c.tag===10)p=c.type===t.type?null:c.child;else if(c.tag===18){if(p=c.return,p===null)throw Error(o(341));p.lanes|=n,v=p.alternate,v!==null&&(v.lanes|=n),ma(p,n,t),p=c.sibling}else p=c.child;if(p!==null)p.return=c;else for(p=c;p!==null;){if(p===t){p=null;break}if(c=p.sibling,c!==null){c.return=p.return,p=c;break}p=p.return}c=p}ft(e,t,l.children,n),t=t.child}return t;case 9:return l=t.type,i=t.pendingProps.children,Hr(t,n),l=Ot(l),i=i(l),t.flags|=1,ft(e,t,i,n),t.child;case 14:return i=t.type,l=Ut(i,t.pendingProps),l=Ut(i.type,l),wf(e,t,i,l,n);case 15:return kf(e,t,t.type,t.pendingProps,n);case 17:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:Ut(i,l),Co(e,t),t.tag=1,gt(i)?(e=!0,ao(t)):e=!1,Hr(t,n),ff(t,i,l),Ma(t,i,l,n),Da(null,t,i,!0,e,n);case 19:return Pf(e,t,n);case 22:return bf(e,t,n)}throw Error(o(156,t.tag))};function Jf(e,t){return Mc(e,t)}function gv(e,t,n,i){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Dt(e,t,n,i){return new gv(e,t,n,i)}function tu(e){return e=e.prototype,!(!e||!e.isReactComponent)}function vv(e){if(typeof e=="function")return tu(e)?1:0;if(e!=null){if(e=e.$$typeof,e===le)return 11;if(e===ce)return 14}return 2}function Dn(e,t){var n=e.alternate;return n===null?(n=Dt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Fo(e,t,n,i,l,c){var p=2;if(i=e,typeof e=="function")tu(e)&&(p=1);else if(typeof e=="string")p=5;else e:switch(e){case ue:return cr(n.children,l,c,t);case oe:p=8,l|=8;break;case ee:return e=Dt(12,n,t,l|2),e.elementType=ee,e.lanes=c,e;case Le:return e=Dt(13,n,t,l),e.elementType=Le,e.lanes=c,e;case Z:return e=Dt(19,n,t,l),e.elementType=Z,e.lanes=c,e;case Ne:return Io(n,l,c,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case me:p=10;break e;case ke:p=9;break e;case le:p=11;break e;case ce:p=14;break e;case Ce:p=16,i=null;break e}throw Error(o(130,e==null?e:typeof e,""))}return t=Dt(p,n,t,l),t.elementType=e,t.type=i,t.lanes=c,t}function cr(e,t,n,i){return e=Dt(7,e,i,t),e.lanes=n,e}function Io(e,t,n,i){return e=Dt(22,e,i,t),e.elementType=Ne,e.lanes=n,e.stateNode={isHidden:!1},e}function nu(e,t,n){return e=Dt(6,e,null,t),e.lanes=n,e}function ru(e,t,n){return t=Dt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function yv(e,t,n,i,l){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Rl(0),this.expirationTimes=Rl(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Rl(0),this.identifierPrefix=i,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function su(e,t,n,i,l,c,p,v,S){return e=new yv(e,t,n,v,S),t===1?(t=1,c===!0&&(t|=8)):t=0,c=Dt(3,null,null,t),e.current=c,c.stateNode=e,c.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},va(c),e}function xv(e,t,n){var i=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:G,key:i==null?null:""+i,children:e,containerInfo:t,implementation:n}}function eh(e){if(!e)return jn;e=e._reactInternals;e:{if(Xn(e)!==e||e.tag!==1)throw Error(o(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(gt(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(o(171))}if(e.tag===1){var n=e.type;if(gt(n))return Cd(e,n,t)}return t}function th(e,t,n,i,l,c,p,v,S){return e=su(n,i,!0,e,l,c,p,v,S),e.context=eh(null),n=e.current,i=ht(),l=Tn(n),c=cn(i,l),c.callback=t??null,Pn(n,c,l),e.current.lanes=l,Ls(e,l,i),xt(e,i),e}function Uo(e,t,n,i){var l=t.current,c=ht(),p=Tn(l);return n=eh(n),t.context===null?t.context=n:t.pendingContext=n,t=cn(c,p),t.payload={element:e},i=i===void 0?null:i,i!==null&&(t.callback=i),e=Pn(l,t,p),e!==null&&(Vt(e,l,p,c),vo(e,l,p)),p}function $o(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function nh(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function iu(e,t){nh(e,t),(e=e.alternate)&&nh(e,t)}function wv(){return null}var rh=typeof reportError=="function"?reportError:function(e){console.error(e)};function ou(e){this._internalRoot=e}Bo.prototype.render=ou.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(o(409));Uo(e,t,null,null)},Bo.prototype.unmount=ou.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;lr(function(){Uo(null,e,null,null)}),t[sn]=null}};function Bo(e){this._internalRoot=e}Bo.prototype.unstable_scheduleHydration=function(e){if(e){var t=Ic();e={blockedOn:null,target:e,priority:t};for(var n=0;n<kn.length&&t!==0&&t<kn[n].priority;n++);kn.splice(n,0,e),n===0&&Bc(e)}};function lu(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Vo(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function sh(){}function kv(e,t,n,i,l){if(l){if(typeof i=="function"){var c=i;i=function(){var T=$o(p);c.call(T)}}var p=th(t,i,e,0,null,!1,!1,"",sh);return e._reactRootContainer=p,e[sn]=p.current,qs(e.nodeType===8?e.parentNode:e),lr(),p}for(;l=e.lastChild;)e.removeChild(l);if(typeof i=="function"){var v=i;i=function(){var T=$o(S);v.call(T)}}var S=su(e,0,!1,null,null,!1,!1,"",sh);return e._reactRootContainer=S,e[sn]=S.current,qs(e.nodeType===8?e.parentNode:e),lr(function(){Uo(t,S,n,i)}),S}function Ho(e,t,n,i,l){var c=n._reactRootContainer;if(c){var p=c;if(typeof l=="function"){var v=l;l=function(){var S=$o(p);v.call(S)}}Uo(t,p,e,l)}else p=kv(n,t,e,l,i);return $o(p)}zc=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Ts(t.pendingLanes);n!==0&&(Ml(t,n|1),xt(t,Ke()),(Me&6)===0&&(Gr=Ke()+500,Cn()))}break;case 13:lr(function(){var i=un(e,1);if(i!==null){var l=ht();Vt(i,e,1,l)}}),iu(e,1)}},Ol=function(e){if(e.tag===13){var t=un(e,134217728);if(t!==null){var n=ht();Vt(t,e,134217728,n)}iu(e,134217728)}},Fc=function(e){if(e.tag===13){var t=Tn(e),n=un(e,t);if(n!==null){var i=ht();Vt(n,e,t,i)}iu(e,t)}},Ic=function(){return De},Uc=function(e,t){var n=De;try{return De=e,t()}finally{De=n}},El=function(e,t,n){switch(t){case"input":if(jr(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var i=n[t];if(i!==e&&i.form===e.form){var l=oo(i);if(!l)throw Error(o(90));Ns(i),jr(i,l)}}}break;case"textarea":mc(e,n);break;case"select":t=n.value,t!=null&&ze(e,!!n.multiple,t,!1)}},Ec=Xa,Nc=lr;var bv={usingClientEntryPoint:!1,Events:[Ys,Ar,oo,bc,Sc,Xa]},di={findFiberByHostInstance:Jn,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Sv={bundleType:di.bundleType,version:di.version,rendererPackageName:di.rendererPackageName,rendererConfig:di.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:z.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Pc(e),e===null?null:e.stateNode},findFiberByHostInstance:di.findFiberByHostInstance||wv,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Wo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Wo.isDisabled&&Wo.supportsFiber)try{$i=Wo.inject(Sv),Kt=Wo}catch{}}return wt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=bv,wt.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!lu(t))throw Error(o(200));return xv(e,t,null,n)},wt.createRoot=function(e,t){if(!lu(e))throw Error(o(299));var n=!1,i="",l=rh;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(i=t.identifierPrefix),t.onRecoverableError!==void 0&&(l=t.onRecoverableError)),t=su(e,1,!1,null,null,n,!1,i,l),e[sn]=t.current,qs(e.nodeType===8?e.parentNode:e),new ou(t)},wt.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(o(188)):(e=Object.keys(e).join(","),Error(o(268,e)));return e=Pc(t),e=e===null?null:e.stateNode,e},wt.flushSync=function(e){return lr(e)},wt.hydrate=function(e,t,n){if(!Vo(t))throw Error(o(200));return Ho(null,e,t,!0,n)},wt.hydrateRoot=function(e,t,n){if(!lu(e))throw Error(o(405));var i=n!=null&&n.hydratedSources||null,l=!1,c="",p=rh;if(n!=null&&(n.unstable_strictMode===!0&&(l=!0),n.identifierPrefix!==void 0&&(c=n.identifierPrefix),n.onRecoverableError!==void 0&&(p=n.onRecoverableError)),t=th(t,null,e,1,n??null,l,!1,c,p),e[sn]=t.current,qs(e),i)for(e=0;e<i.length;e++)n=i[e],l=n._getVersion,l=l(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,l]:t.mutableSourceEagerHydrationData.push(n,l);return new Bo(t)},wt.render=function(e,t,n){if(!Vo(t))throw Error(o(200));return Ho(null,e,t,!1,n)},wt.unmountComponentAtNode=function(e){if(!Vo(e))throw Error(o(40));return e._reactRootContainer?(lr(function(){Ho(null,null,e,!1,function(){e._reactRootContainer=null,e[sn]=null})}),!0):!1},wt.unstable_batchedUpdates=Xa,wt.unstable_renderSubtreeIntoContainer=function(e,t,n,i){if(!Vo(n))throw Error(o(200));if(e==null||e._reactInternals===void 0)throw Error(o(38));return Ho(e,t,n,!1,i)},wt.version="18.3.1-next-f1338f8080-20240426",wt}var hh;function up(){if(hh)return du.exports;hh=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(s){console.error(s)}}return r(),du.exports=Tv(),du.exports}var ph;function Lv(){if(ph)return qo;ph=1;var r=up();return qo.createRoot=r.createRoot,qo.hydrateRoot=r.hydrateRoot,qo}var Dv=Lv();const Av=ap(Dv);var Di=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(r){return this.listeners.add(r),this.onSubscribe(),()=>{this.listeners.delete(r),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},fr,$n,as,Xh,zv=(Xh=class extends Di{constructor(){super();pe(this,fr);pe(this,$n);pe(this,as);J(this,as,s=>{if(typeof window<"u"&&window.addEventListener){const o=()=>s();return window.addEventListener("visibilitychange",o,!1),()=>{window.removeEventListener("visibilitychange",o)}}})}onSubscribe(){E(this,$n)||this.setEventListener(E(this,as))}onUnsubscribe(){var s;this.hasListeners()||((s=E(this,$n))==null||s.call(this),J(this,$n,void 0))}setEventListener(s){var o;J(this,as,s),(o=E(this,$n))==null||o.call(this),J(this,$n,s(a=>{typeof a=="boolean"?this.setFocused(a):this.onFocus()}))}setFocused(s){E(this,fr)!==s&&(J(this,fr,s),this.onFocus())}onFocus(){const s=this.isFocused();this.listeners.forEach(o=>{o(s)})}isFocused(){var s;return typeof E(this,fr)=="boolean"?E(this,fr):((s=globalThis.document)==null?void 0:s.visibilityState)!=="hidden"}},fr=new WeakMap,$n=new WeakMap,as=new WeakMap,Xh),tc=new zv,Fv={setTimeout:(r,s)=>setTimeout(r,s),clearTimeout:r=>clearTimeout(r),setInterval:(r,s)=>setInterval(r,s),clearInterval:r=>clearInterval(r)},Bn,Yu,Jh,Iv=(Jh=class{constructor(){pe(this,Bn,Fv);pe(this,Yu,!1)}setTimeoutProvider(r){J(this,Bn,r)}setTimeout(r,s){return E(this,Bn).setTimeout(r,s)}clearTimeout(r){E(this,Bn).clearTimeout(r)}setInterval(r,s){return E(this,Bn).setInterval(r,s)}clearInterval(r){E(this,Bn).clearInterval(r)}},Bn=new WeakMap,Yu=new WeakMap,Jh),dr=new Iv;function Uv(r){setTimeout(r,0)}var $v=typeof window>"u"||"Deno"in globalThis;function bt(){}function Bv(r,s){return typeof r=="function"?r(s):r}function Cu(r){return typeof r=="number"&&r>=0&&r!==1/0}function cp(r,s){return Math.max(r+(s||0)-Date.now(),0)}function Gn(r,s){return typeof r=="function"?r(s):r}function Pt(r,s){return typeof r=="function"?r(s):r}function mh(r,s){const{type:o="all",exact:a,fetchStatus:u,predicate:f,queryKey:m,stale:h}=r;if(m){if(a){if(s.queryHash!==nc(m,s.options))return!1}else if(!Si(s.queryKey,m))return!1}if(o!=="all"){const y=s.isActive();if(o==="active"&&!y||o==="inactive"&&y)return!1}return!(typeof h=="boolean"&&s.isStale()!==h||u&&u!==s.state.fetchStatus||f&&!f(s))}function gh(r,s){const{exact:o,status:a,predicate:u,mutationKey:f}=r;if(f){if(!s.options.mutationKey)return!1;if(o){if(bi(s.options.mutationKey)!==bi(f))return!1}else if(!Si(s.options.mutationKey,f))return!1}return!(a&&s.state.status!==a||u&&!u(s))}function nc(r,s){return((s==null?void 0:s.queryKeyHashFn)||bi)(r)}function bi(r){return JSON.stringify(r,(s,o)=>Pu(o)?Object.keys(o).sort().reduce((a,u)=>(a[u]=o[u],a),{}):o)}function Si(r,s){return r===s?!0:typeof r!=typeof s?!1:r&&s&&typeof r=="object"&&typeof s=="object"?Object.keys(s).every(o=>Si(r[o],s[o])):!1}var Vv=Object.prototype.hasOwnProperty;function dp(r,s,o=0){if(r===s)return r;if(o>500)return s;const a=vh(r)&&vh(s);if(!a&&!(Pu(r)&&Pu(s)))return s;const f=(a?r:Object.keys(r)).length,m=a?s:Object.keys(s),h=m.length,y=a?new Array(h):{};let k=0;for(let w=0;w<h;w++){const x=a?w:m[w],P=r[x],_=s[x];if(P===_){y[x]=P,(a?w<f:Vv.call(r,x))&&k++;continue}if(P===null||_===null||typeof P!="object"||typeof _!="object"){y[x]=_;continue}const D=dp(P,_,o+1);y[x]=D,D===P&&k++}return f===h&&k===f?r:y}function _u(r,s){if(!s||Object.keys(r).length!==Object.keys(s).length)return!1;for(const o in r)if(r[o]!==s[o])return!1;return!0}function vh(r){return Array.isArray(r)&&r.length===Object.keys(r).length}function Pu(r){if(!yh(r))return!1;const s=r.constructor;if(s===void 0)return!0;const o=s.prototype;return!(!yh(o)||!o.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(r)!==Object.prototype)}function yh(r){return Object.prototype.toString.call(r)==="[object Object]"}function Hv(r){return new Promise(s=>{dr.setTimeout(s,r)})}function Ru(r,s,o){return typeof o.structuralSharing=="function"?o.structuralSharing(r,s):o.structuralSharing!==!1?dp(r,s):s}function Wv(r,s,o=0){const a=[...r,s];return o&&a.length>o?a.slice(1):a}function Qv(r,s,o=0){const a=[s,...r];return o&&a.length>o?a.slice(0,-1):a}var rc=Symbol();function fp(r,s){return!r.queryFn&&(s!=null&&s.initialPromise)?()=>s.initialPromise:!r.queryFn||r.queryFn===rc?()=>Promise.reject(new Error(`Missing queryFn: '${r.queryHash}'`)):r.queryFn}function hp(r,s){return typeof r=="function"?r(...s):!!r}function Kv(r,s,o){let a=!1,u;return Object.defineProperty(r,"signal",{enumerable:!0,get:()=>(u??(u=s()),a||(a=!0,u.aborted?o():u.addEventListener("abort",o,{once:!0})),u)}),r}var Ei=(()=>{let r=()=>$v;return{isServer(){return r()},setIsServer(s){r=s}}})();function Mu(){let r,s;const o=new Promise((u,f)=>{r=u,s=f});o.status="pending",o.catch(()=>{});function a(u){Object.assign(o,u),delete o.resolve,delete o.reject}return o.resolve=u=>{a({status:"fulfilled",value:u}),r(u)},o.reject=u=>{a({status:"rejected",reason:u}),s(u)},o}var qv=Uv;function Gv(){let r=[],s=0,o=h=>{h()},a=h=>{h()},u=qv;const f=h=>{s?r.push(h):u(()=>{o(h)})},m=()=>{const h=r;r=[],h.length&&u(()=>{a(()=>{h.forEach(y=>{o(y)})})})};return{batch:h=>{let y;s++;try{y=h()}finally{s--,s||m()}return y},batchCalls:h=>(...y)=>{f(()=>{h(...y)})},schedule:f,setNotifyFunction:h=>{o=h},setBatchNotifyFunction:h=>{a=h},setScheduler:h=>{u=h}}}var it=Gv(),us,Vn,cs,ep,Zv=(ep=class extends Di{constructor(){super();pe(this,us,!0);pe(this,Vn);pe(this,cs);J(this,cs,s=>{if(typeof window<"u"&&window.addEventListener){const o=()=>s(!0),a=()=>s(!1);return window.addEventListener("online",o,!1),window.addEventListener("offline",a,!1),()=>{window.removeEventListener("online",o),window.removeEventListener("offline",a)}}})}onSubscribe(){E(this,Vn)||this.setEventListener(E(this,cs))}onUnsubscribe(){var s;this.hasListeners()||((s=E(this,Vn))==null||s.call(this),J(this,Vn,void 0))}setEventListener(s){var o;J(this,cs,s),(o=E(this,Vn))==null||o.call(this),J(this,Vn,s(this.setOnline.bind(this)))}setOnline(s){E(this,us)!==s&&(J(this,us,s),this.listeners.forEach(a=>{a(s)}))}isOnline(){return E(this,us)}},us=new WeakMap,Vn=new WeakMap,cs=new WeakMap,ep),ol=new Zv;function Yv(r){return Math.min(1e3*2**r,3e4)}function pp(r){return(r??"online")==="online"?ol.isOnline():!0}var Ou=class extends Error{constructor(r){super("CancelledError"),this.revert=r==null?void 0:r.revert,this.silent=r==null?void 0:r.silent}};function mp(r){let s=!1,o=0,a;const u=Mu(),f=()=>u.status!=="pending",m=b=>{var R;if(!f()){const A=new Ou(b);P(A),(R=r.onCancel)==null||R.call(r,A)}},h=()=>{s=!0},y=()=>{s=!1},k=()=>tc.isFocused()&&(r.networkMode==="always"||ol.isOnline())&&r.canRun(),w=()=>pp(r.networkMode)&&r.canRun(),x=b=>{f()||(a==null||a(),u.resolve(b))},P=b=>{f()||(a==null||a(),u.reject(b))},_=()=>new Promise(b=>{var R;a=A=>{(f()||k())&&b(A)},(R=r.onPause)==null||R.call(r)}).then(()=>{var b;a=void 0,f()||(b=r.onContinue)==null||b.call(r)}),D=()=>{if(f())return;let b;const R=o===0?r.initialPromise:void 0;try{b=R??r.fn()}catch(A){b=Promise.reject(A)}Promise.resolve(b).then(x).catch(A=>{var G;if(f())return;const I=r.retry??(Ei.isServer()?0:3),V=r.retryDelay??Yv,z=typeof V=="function"?V(o,A):V,K=I===!0||typeof I=="number"&&o<I||typeof I=="function"&&I(o,A);if(s||!K){P(A);return}o++,(G=r.onFail)==null||G.call(r,o,A),Hv(z).then(()=>k()?void 0:_()).then(()=>{s?P(A):D()})})};return{promise:u,status:()=>u.status,cancel:m,continue:()=>(a==null||a(),u),cancelRetry:h,continueRetry:y,canStart:w,start:()=>(w()?D():_().then(D),u)}}var hr,tp,gp=(tp=class{constructor(){pe(this,hr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Cu(this.gcTime)&&J(this,hr,dr.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(r){this.gcTime=Math.max(this.gcTime||0,r??(Ei.isServer()?1/0:300*1e3))}clearGcTimeout(){E(this,hr)!==void 0&&(dr.clearTimeout(E(this,hr)),J(this,hr,void 0))}},hr=new WeakMap,tp);function Xv(r){return{onFetch:(s,o)=>{var w,x,P,_,D;const a=s.options,u=(P=(x=(w=s.fetchOptions)==null?void 0:w.meta)==null?void 0:x.fetchMore)==null?void 0:P.direction,f=((_=s.state.data)==null?void 0:_.pages)||[],m=((D=s.state.data)==null?void 0:D.pageParams)||[];let h={pages:[],pageParams:[]},y=0;const k=async()=>{let b=!1;const R=V=>{Kv(V,()=>s.signal,()=>b=!0)},A=fp(s.options,s.fetchOptions),I=async(V,z,K)=>{if(b)return Promise.reject(s.signal.reason);if(z==null&&V.pages.length)return Promise.resolve(V);const ue=(()=>{const ke={client:s.client,queryKey:s.queryKey,pageParam:z,direction:K?"backward":"forward",meta:s.options.meta};return R(ke),ke})(),oe=await A(ue),{maxPages:ee}=s.options,me=K?Qv:Wv;return{pages:me(V.pages,oe,ee),pageParams:me(V.pageParams,z,ee)}};if(u&&f.length){const V=u==="backward",z=V?Jv:xh,K={pages:f,pageParams:m},G=z(a,K);h=await I(K,G,V)}else{const V=r??f.length;do{const z=y===0?m[0]??a.initialPageParam:xh(a,h);if(y>0&&z==null)break;h=await I(h,z),y++}while(y<V)}return h};s.options.persister?s.fetchFn=()=>{var b,R;return(R=(b=s.options).persister)==null?void 0:R.call(b,k,{client:s.client,queryKey:s.queryKey,meta:s.options.meta,signal:s.signal},o)}:s.fetchFn=k}}}function xh(r,{pages:s,pageParams:o}){const a=s.length-1;return s.length>0?r.getNextPageParam(s[a],s,o[a],o):void 0}function Jv(r,{pages:s,pageParams:o}){var a;return s.length>0?(a=r.getPreviousPageParam)==null?void 0:a.call(r,s[0],s,o[0],o):void 0}var ds,pr,fs,At,mr,nt,Ri,gr,_t,vp,pn,np,ey=(np=class extends gp{constructor(s){super();pe(this,_t);pe(this,ds);pe(this,pr);pe(this,fs);pe(this,At);pe(this,mr);pe(this,nt);pe(this,Ri);pe(this,gr);J(this,gr,!1),J(this,Ri,s.defaultOptions),this.setOptions(s.options),this.observers=[],J(this,mr,s.client),J(this,At,E(this,mr).getQueryCache()),this.queryKey=s.queryKey,this.queryHash=s.queryHash,J(this,pr,kh(this.options)),this.state=s.state??E(this,pr),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return E(this,ds)}get promise(){var s;return(s=E(this,nt))==null?void 0:s.promise}setOptions(s){if(this.options={...E(this,Ri),...s},s!=null&&s._type&&J(this,ds,s._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const o=kh(this.options);o.data!==void 0&&(this.setState(wh(o.data,o.dataUpdatedAt)),J(this,pr,o))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&E(this,At).remove(this)}setData(s,o){const a=Ru(this.state.data,s,this.options);return _e(this,_t,pn).call(this,{data:a,type:"success",dataUpdatedAt:o==null?void 0:o.updatedAt,manual:o==null?void 0:o.manual}),a}setState(s){_e(this,_t,pn).call(this,{type:"setState",state:s})}cancel(s){var a,u;const o=(a=E(this,nt))==null?void 0:a.promise;return(u=E(this,nt))==null||u.cancel(s),o?o.then(bt).catch(bt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return E(this,pr)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(s=>Pt(s.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===rc||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(s=>Gn(s.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(s=>s.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(s=0){return this.state.data===void 0?!0:s==="static"?!1:this.state.isInvalidated?!0:!cp(this.state.dataUpdatedAt,s)}onFocus(){var o;const s=this.observers.find(a=>a.shouldFetchOnWindowFocus());s==null||s.refetch({cancelRefetch:!1}),(o=E(this,nt))==null||o.continue()}onOnline(){var o;const s=this.observers.find(a=>a.shouldFetchOnReconnect());s==null||s.refetch({cancelRefetch:!1}),(o=E(this,nt))==null||o.continue()}addObserver(s){this.observers.includes(s)||(this.observers.push(s),this.clearGcTimeout(),E(this,At).notify({type:"observerAdded",query:this,observer:s}))}removeObserver(s){this.observers.includes(s)&&(this.observers=this.observers.filter(o=>o!==s),this.observers.length||(E(this,nt)&&(E(this,gr)||_e(this,_t,vp).call(this)?E(this,nt).cancel({revert:!0}):E(this,nt).cancelRetry()),this.scheduleGc()),E(this,At).notify({type:"observerRemoved",query:this,observer:s}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||_e(this,_t,pn).call(this,{type:"invalidate"})}async fetch(s,o){var k,w,x,P,_,D,b,R,A,I,V;if(this.state.fetchStatus!=="idle"&&((k=E(this,nt))==null?void 0:k.status())!=="rejected"){if(this.state.data!==void 0&&(o!=null&&o.cancelRefetch))this.cancel({silent:!0});else if(E(this,nt))return E(this,nt).continueRetry(),E(this,nt).promise}if(s&&this.setOptions(s),!this.options.queryFn){const z=this.observers.find(K=>K.options.queryFn);z&&this.setOptions(z.options)}const a=new AbortController,u=z=>{Object.defineProperty(z,"signal",{enumerable:!0,get:()=>(J(this,gr,!0),a.signal)})},f=()=>{const z=fp(this.options,o),G=(()=>{const ue={client:E(this,mr),queryKey:this.queryKey,meta:this.meta};return u(ue),ue})();return J(this,gr,!1),this.options.persister?this.options.persister(z,G,this):z(G)},h=(()=>{const z={fetchOptions:o,options:this.options,queryKey:this.queryKey,client:E(this,mr),state:this.state,fetchFn:f};return u(z),z})(),y=E(this,ds)==="infinite"?Xv(this.options.pages):this.options.behavior;y==null||y.onFetch(h,this),J(this,fs,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((w=h.fetchOptions)==null?void 0:w.meta))&&_e(this,_t,pn).call(this,{type:"fetch",meta:(x=h.fetchOptions)==null?void 0:x.meta}),J(this,nt,mp({initialPromise:o==null?void 0:o.initialPromise,fn:h.fetchFn,onCancel:z=>{z instanceof Ou&&z.revert&&this.setState({...E(this,fs),fetchStatus:"idle"}),a.abort()},onFail:(z,K)=>{_e(this,_t,pn).call(this,{type:"failed",failureCount:z,error:K})},onPause:()=>{_e(this,_t,pn).call(this,{type:"pause"})},onContinue:()=>{_e(this,_t,pn).call(this,{type:"continue"})},retry:h.options.retry,retryDelay:h.options.retryDelay,networkMode:h.options.networkMode,canRun:()=>!0}));try{const z=await E(this,nt).start();if(z===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(z),(_=(P=E(this,At).config).onSuccess)==null||_.call(P,z,this),(b=(D=E(this,At).config).onSettled)==null||b.call(D,z,this.state.error,this),z}catch(z){if(z instanceof Ou){if(z.silent)return E(this,nt).promise;if(z.revert){if(this.state.data===void 0)throw z;return this.state.data}}throw _e(this,_t,pn).call(this,{type:"error",error:z}),(A=(R=E(this,At).config).onError)==null||A.call(R,z,this),(V=(I=E(this,At).config).onSettled)==null||V.call(I,this.state.data,z,this),z}finally{this.scheduleGc()}}},ds=new WeakMap,pr=new WeakMap,fs=new WeakMap,At=new WeakMap,mr=new WeakMap,nt=new WeakMap,Ri=new WeakMap,gr=new WeakMap,_t=new WeakSet,vp=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},pn=function(s){const o=a=>{switch(s.type){case"failed":return{...a,fetchFailureCount:s.failureCount,fetchFailureReason:s.error};case"pause":return{...a,fetchStatus:"paused"};case"continue":return{...a,fetchStatus:"fetching"};case"fetch":return{...a,...yp(a.data,this.options),fetchMeta:s.meta??null};case"success":const u={...a,...wh(s.data,s.dataUpdatedAt),dataUpdateCount:a.dataUpdateCount+1,...!s.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return J(this,fs,s.manual?u:void 0),u;case"error":const f=s.error;return{...a,error:f,errorUpdateCount:a.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:a.fetchFailureCount+1,fetchFailureReason:f,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...a,isInvalidated:!0};case"setState":return{...a,...s.state}}};this.state=o(this.state),it.batch(()=>{this.observers.forEach(a=>{a.onQueryUpdate()}),E(this,At).notify({query:this,type:"updated",action:s})})},np);function yp(r,s){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:pp(s.networkMode)?"fetching":"paused",...r===void 0&&{error:null,status:"pending"}}}function wh(r,s){return{data:r,dataUpdatedAt:s??Date.now(),error:null,isInvalidated:!1,status:"success"}}function kh(r){const s=typeof r.initialData=="function"?r.initialData():r.initialData,o=s!==void 0,a=o?typeof r.initialDataUpdatedAt=="function"?r.initialDataUpdatedAt():r.initialDataUpdatedAt:0;return{data:s,dataUpdateCount:0,dataUpdatedAt:o?a??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:o?"success":"pending",fetchStatus:"idle"}}var kt,Re,Mi,pt,vr,hs,mn,Hn,Oi,ps,ms,yr,xr,Wn,gs,Te,xi,Tu,Lu,Du,Au,zu,Fu,Iu,xp,rp,ty=(rp=class extends Di{constructor(s,o){super();pe(this,Te);pe(this,kt);pe(this,Re);pe(this,Mi);pe(this,pt);pe(this,vr);pe(this,hs);pe(this,mn);pe(this,Hn);pe(this,Oi);pe(this,ps);pe(this,ms);pe(this,yr);pe(this,xr);pe(this,Wn);pe(this,gs,new Set);this.options=o,J(this,kt,s),J(this,Hn,null),J(this,mn,Mu()),this.bindMethods(),this.setOptions(o)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(E(this,Re).addObserver(this),bh(E(this,Re),this.options)?_e(this,Te,xi).call(this):this.updateResult(),_e(this,Te,Au).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Uu(E(this,Re),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Uu(E(this,Re),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,_e(this,Te,zu).call(this),_e(this,Te,Fu).call(this),E(this,Re).removeObserver(this)}setOptions(s){const o=this.options,a=E(this,Re);if(this.options=E(this,kt).defaultQueryOptions(s),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Pt(this.options.enabled,E(this,Re))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");_e(this,Te,Iu).call(this),E(this,Re).setOptions(this.options),o._defaulted&&!_u(this.options,o)&&E(this,kt).getQueryCache().notify({type:"observerOptionsUpdated",query:E(this,Re),observer:this});const u=this.hasListeners();u&&Sh(E(this,Re),a,this.options,o)&&_e(this,Te,xi).call(this),this.updateResult(),u&&(E(this,Re)!==a||Pt(this.options.enabled,E(this,Re))!==Pt(o.enabled,E(this,Re))||Gn(this.options.staleTime,E(this,Re))!==Gn(o.staleTime,E(this,Re)))&&_e(this,Te,Tu).call(this);const f=_e(this,Te,Lu).call(this);u&&(E(this,Re)!==a||Pt(this.options.enabled,E(this,Re))!==Pt(o.enabled,E(this,Re))||f!==E(this,Wn))&&_e(this,Te,Du).call(this,f)}getOptimisticResult(s){const o=E(this,kt).getQueryCache().build(E(this,kt),s),a=this.createResult(o,s);return ry(this,a)&&(J(this,pt,a),J(this,hs,this.options),J(this,vr,E(this,Re).state)),a}getCurrentResult(){return E(this,pt)}trackResult(s,o){return new Proxy(s,{get:(a,u)=>(this.trackProp(u),o==null||o(u),u==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&E(this,mn).status==="pending"&&E(this,mn).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(a,u))})}trackProp(s){E(this,gs).add(s)}getCurrentQuery(){return E(this,Re)}refetch({...s}={}){return this.fetch({...s})}fetchOptimistic(s){const o=E(this,kt).defaultQueryOptions(s),a=E(this,kt).getQueryCache().build(E(this,kt),o);return a.fetch().then(()=>this.createResult(a,o))}fetch(s){return _e(this,Te,xi).call(this,{...s,cancelRefetch:s.cancelRefetch??!0}).then(()=>(this.updateResult(),E(this,pt)))}createResult(s,o){var ee;const a=E(this,Re),u=this.options,f=E(this,pt),m=E(this,vr),h=E(this,hs),k=s!==a?s.state:E(this,Mi),{state:w}=s;let x={...w},P=!1,_;if(o._optimisticResults){const me=this.hasListeners(),ke=!me&&bh(s,o),le=me&&Sh(s,a,o,u);(ke||le)&&(x={...x,...yp(w.data,s.options)}),o._optimisticResults==="isRestoring"&&(x.fetchStatus="idle")}let{error:D,errorUpdatedAt:b,status:R}=x;_=x.data;let A=!1;if(o.placeholderData!==void 0&&_===void 0&&R==="pending"){let me;f!=null&&f.isPlaceholderData&&o.placeholderData===(h==null?void 0:h.placeholderData)?(me=f.data,A=!0):me=typeof o.placeholderData=="function"?o.placeholderData((ee=E(this,ms))==null?void 0:ee.state.data,E(this,ms)):o.placeholderData,me!==void 0&&(R="success",_=Ru(f==null?void 0:f.data,me,o),P=!0)}if(o.select&&_!==void 0&&!A)if(f&&_===(m==null?void 0:m.data)&&o.select===E(this,Oi))_=E(this,ps);else try{J(this,Oi,o.select),_=o.select(_),_=Ru(f==null?void 0:f.data,_,o),J(this,ps,_),J(this,Hn,null)}catch(me){J(this,Hn,me)}E(this,Hn)&&(D=E(this,Hn),_=E(this,ps),b=Date.now(),R="error");const I=x.fetchStatus==="fetching",V=R==="pending",z=R==="error",K=V&&I,G=_!==void 0,oe={status:R,fetchStatus:x.fetchStatus,isPending:V,isSuccess:R==="success",isError:z,isInitialLoading:K,isLoading:K,data:_,dataUpdatedAt:x.dataUpdatedAt,error:D,errorUpdatedAt:b,failureCount:x.fetchFailureCount,failureReason:x.fetchFailureReason,errorUpdateCount:x.errorUpdateCount,isFetched:s.isFetched(),isFetchedAfterMount:x.dataUpdateCount>k.dataUpdateCount||x.errorUpdateCount>k.errorUpdateCount,isFetching:I,isRefetching:I&&!V,isLoadingError:z&&!G,isPaused:x.fetchStatus==="paused",isPlaceholderData:P,isRefetchError:z&&G,isStale:sc(s,o),refetch:this.refetch,promise:E(this,mn),isEnabled:Pt(o.enabled,s)!==!1};if(this.options.experimental_prefetchInRender){const me=oe.data!==void 0,ke=oe.status==="error"&&!me,le=ce=>{ke?ce.reject(oe.error):me&&ce.resolve(oe.data)},Le=()=>{const ce=J(this,mn,oe.promise=Mu());le(ce)},Z=E(this,mn);switch(Z.status){case"pending":s.queryHash===a.queryHash&&le(Z);break;case"fulfilled":(ke||oe.data!==Z.value)&&Le();break;case"rejected":(!ke||oe.error!==Z.reason)&&Le();break}}return oe}updateResult(){const s=E(this,pt),o=this.createResult(E(this,Re),this.options);if(J(this,vr,E(this,Re).state),J(this,hs,this.options),E(this,vr).data!==void 0&&J(this,ms,E(this,Re)),_u(o,s))return;J(this,pt,o);const a=()=>{if(!s)return!0;const{notifyOnChangeProps:u}=this.options,f=typeof u=="function"?u():u;if(f==="all"||!f&&!E(this,gs).size)return!0;const m=new Set(f??E(this,gs));return this.options.throwOnError&&m.add("error"),Object.keys(E(this,pt)).some(h=>{const y=h;return E(this,pt)[y]!==s[y]&&m.has(y)})};_e(this,Te,xp).call(this,{listeners:a()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&_e(this,Te,Au).call(this)}},kt=new WeakMap,Re=new WeakMap,Mi=new WeakMap,pt=new WeakMap,vr=new WeakMap,hs=new WeakMap,mn=new WeakMap,Hn=new WeakMap,Oi=new WeakMap,ps=new WeakMap,ms=new WeakMap,yr=new WeakMap,xr=new WeakMap,Wn=new WeakMap,gs=new WeakMap,Te=new WeakSet,xi=function(s){_e(this,Te,Iu).call(this);let o=E(this,Re).fetch(this.options,s);return s!=null&&s.throwOnError||(o=o.catch(bt)),o},Tu=function(){_e(this,Te,zu).call(this);const s=Gn(this.options.staleTime,E(this,Re));if(Ei.isServer()||E(this,pt).isStale||!Cu(s))return;const a=cp(E(this,pt).dataUpdatedAt,s)+1;J(this,yr,dr.setTimeout(()=>{E(this,pt).isStale||this.updateResult()},a))},Lu=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(E(this,Re)):this.options.refetchInterval)??!1},Du=function(s){_e(this,Te,Fu).call(this),J(this,Wn,s),!(Ei.isServer()||Pt(this.options.enabled,E(this,Re))===!1||!Cu(E(this,Wn))||E(this,Wn)===0)&&J(this,xr,dr.setInterval(()=>{(this.options.refetchIntervalInBackground||tc.isFocused())&&_e(this,Te,xi).call(this)},E(this,Wn)))},Au=function(){_e(this,Te,Tu).call(this),_e(this,Te,Du).call(this,_e(this,Te,Lu).call(this))},zu=function(){E(this,yr)!==void 0&&(dr.clearTimeout(E(this,yr)),J(this,yr,void 0))},Fu=function(){E(this,xr)!==void 0&&(dr.clearInterval(E(this,xr)),J(this,xr,void 0))},Iu=function(){const s=E(this,kt).getQueryCache().build(E(this,kt),this.options);if(s===E(this,Re))return;const o=E(this,Re);J(this,Re,s),J(this,Mi,s.state),this.hasListeners()&&(o==null||o.removeObserver(this),s.addObserver(this))},xp=function(s){it.batch(()=>{s.listeners&&this.listeners.forEach(o=>{o(E(this,pt))}),E(this,kt).getQueryCache().notify({query:E(this,Re),type:"observerResultsUpdated"})})},rp);function ny(r,s){return Pt(s.enabled,r)!==!1&&r.state.data===void 0&&!(r.state.status==="error"&&Pt(s.retryOnMount,r)===!1)}function bh(r,s){return ny(r,s)||r.state.data!==void 0&&Uu(r,s,s.refetchOnMount)}function Uu(r,s,o){if(Pt(s.enabled,r)!==!1&&Gn(s.staleTime,r)!=="static"){const a=typeof o=="function"?o(r):o;return a==="always"||a!==!1&&sc(r,s)}return!1}function Sh(r,s,o,a){return(r!==s||Pt(a.enabled,r)===!1)&&(!o.suspense||r.state.status!=="error")&&sc(r,o)}function sc(r,s){return Pt(s.enabled,r)!==!1&&r.isStaleByTime(Gn(s.staleTime,r))}function ry(r,s){return!_u(r.getCurrentResult(),s)}var Ti,Jt,dt,wr,en,In,sp,sy=(sp=class extends gp{constructor(s){super();pe(this,en);pe(this,Ti);pe(this,Jt);pe(this,dt);pe(this,wr);J(this,Ti,s.client),this.mutationId=s.mutationId,J(this,dt,s.mutationCache),J(this,Jt,[]),this.state=s.state||iy(),this.setOptions(s.options),this.scheduleGc()}setOptions(s){this.options=s,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(s){E(this,Jt).includes(s)||(E(this,Jt).push(s),this.clearGcTimeout(),E(this,dt).notify({type:"observerAdded",mutation:this,observer:s}))}removeObserver(s){J(this,Jt,E(this,Jt).filter(o=>o!==s)),this.scheduleGc(),E(this,dt).notify({type:"observerRemoved",mutation:this,observer:s})}optionalRemove(){E(this,Jt).length||(this.state.status==="pending"?this.scheduleGc():E(this,dt).remove(this))}continue(){var s;return((s=E(this,wr))==null?void 0:s.continue())??this.execute(this.state.variables)}async execute(s){var m,h,y,k,w,x,P,_,D,b,R,A,I,V,z,K,G,ue;const o=()=>{_e(this,en,In).call(this,{type:"continue"})},a={client:E(this,Ti),meta:this.options.meta,mutationKey:this.options.mutationKey};J(this,wr,mp({fn:()=>this.options.mutationFn?this.options.mutationFn(s,a):Promise.reject(new Error("No mutationFn found")),onFail:(oe,ee)=>{_e(this,en,In).call(this,{type:"failed",failureCount:oe,error:ee})},onPause:()=>{_e(this,en,In).call(this,{type:"pause"})},onContinue:o,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>E(this,dt).canRun(this)}));const u=this.state.status==="pending",f=!E(this,wr).canStart();try{if(u)o();else{_e(this,en,In).call(this,{type:"pending",variables:s,isPaused:f}),E(this,dt).config.onMutate&&await E(this,dt).config.onMutate(s,this,a);const ee=await((h=(m=this.options).onMutate)==null?void 0:h.call(m,s,a));ee!==this.state.context&&_e(this,en,In).call(this,{type:"pending",context:ee,variables:s,isPaused:f})}const oe=await E(this,wr).start();return await((k=(y=E(this,dt).config).onSuccess)==null?void 0:k.call(y,oe,s,this.state.context,this,a)),await((x=(w=this.options).onSuccess)==null?void 0:x.call(w,oe,s,this.state.context,a)),await((_=(P=E(this,dt).config).onSettled)==null?void 0:_.call(P,oe,null,this.state.variables,this.state.context,this,a)),await((b=(D=this.options).onSettled)==null?void 0:b.call(D,oe,null,s,this.state.context,a)),_e(this,en,In).call(this,{type:"success",data:oe}),oe}catch(oe){try{await((A=(R=E(this,dt).config).onError)==null?void 0:A.call(R,oe,s,this.state.context,this,a))}catch(ee){Promise.reject(ee)}try{await((V=(I=this.options).onError)==null?void 0:V.call(I,oe,s,this.state.context,a))}catch(ee){Promise.reject(ee)}try{await((K=(z=E(this,dt).config).onSettled)==null?void 0:K.call(z,void 0,oe,this.state.variables,this.state.context,this,a))}catch(ee){Promise.reject(ee)}try{await((ue=(G=this.options).onSettled)==null?void 0:ue.call(G,void 0,oe,s,this.state.context,a))}catch(ee){Promise.reject(ee)}throw _e(this,en,In).call(this,{type:"error",error:oe}),oe}finally{E(this,dt).runNext(this)}}},Ti=new WeakMap,Jt=new WeakMap,dt=new WeakMap,wr=new WeakMap,en=new WeakSet,In=function(s){const o=a=>{switch(s.type){case"failed":return{...a,failureCount:s.failureCount,failureReason:s.error};case"pause":return{...a,isPaused:!0};case"continue":return{...a,isPaused:!1};case"pending":return{...a,context:s.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:s.isPaused,status:"pending",variables:s.variables,submittedAt:Date.now()};case"success":return{...a,data:s.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...a,data:void 0,error:s.error,failureCount:a.failureCount+1,failureReason:s.error,isPaused:!1,status:"error"}}};this.state=o(this.state),it.batch(()=>{E(this,Jt).forEach(a=>{a.onMutationUpdate(s)}),E(this,dt).notify({mutation:this,type:"updated",action:s})})},sp);function iy(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var gn,Ht,Li,ip,oy=(ip=class extends Di{constructor(s={}){super();pe(this,gn);pe(this,Ht);pe(this,Li);this.config=s,J(this,gn,new Set),J(this,Ht,new Map),J(this,Li,0)}build(s,o,a){const u=new sy({client:s,mutationCache:this,mutationId:++Ko(this,Li)._,options:s.defaultMutationOptions(o),state:a});return this.add(u),u}add(s){E(this,gn).add(s);const o=Go(s);if(typeof o=="string"){const a=E(this,Ht).get(o);a?a.push(s):E(this,Ht).set(o,[s])}this.notify({type:"added",mutation:s})}remove(s){if(E(this,gn).delete(s)){const o=Go(s);if(typeof o=="string"){const a=E(this,Ht).get(o);if(a)if(a.length>1){const u=a.indexOf(s);u!==-1&&a.splice(u,1)}else a[0]===s&&E(this,Ht).delete(o)}}this.notify({type:"removed",mutation:s})}canRun(s){const o=Go(s);if(typeof o=="string"){const a=E(this,Ht).get(o),u=a==null?void 0:a.find(f=>f.state.status==="pending");return!u||u===s}else return!0}runNext(s){var a;const o=Go(s);if(typeof o=="string"){const u=(a=E(this,Ht).get(o))==null?void 0:a.find(f=>f!==s&&f.state.isPaused);return(u==null?void 0:u.continue())??Promise.resolve()}else return Promise.resolve()}clear(){it.batch(()=>{E(this,gn).forEach(s=>{this.notify({type:"removed",mutation:s})}),E(this,gn).clear(),E(this,Ht).clear()})}getAll(){return Array.from(E(this,gn))}find(s){const o={exact:!0,...s};return this.getAll().find(a=>gh(o,a))}findAll(s={}){return this.getAll().filter(o=>gh(s,o))}notify(s){it.batch(()=>{this.listeners.forEach(o=>{o(s)})})}resumePausedMutations(){const s=this.getAll().filter(o=>o.state.isPaused);return it.batch(()=>Promise.all(s.map(o=>o.continue().catch(bt))))}},gn=new WeakMap,Ht=new WeakMap,Li=new WeakMap,ip);function Go(r){var s;return(s=r.options.scope)==null?void 0:s.id}var tn,op,ly=(op=class extends Di{constructor(s={}){super();pe(this,tn);this.config=s,J(this,tn,new Map)}build(s,o,a){const u=o.queryKey,f=o.queryHash??nc(u,o);let m=this.get(f);return m||(m=new ey({client:s,queryKey:u,queryHash:f,options:s.defaultQueryOptions(o),state:a,defaultOptions:s.getQueryDefaults(u)}),this.add(m)),m}add(s){E(this,tn).has(s.queryHash)||(E(this,tn).set(s.queryHash,s),this.notify({type:"added",query:s}))}remove(s){const o=E(this,tn).get(s.queryHash);o&&(s.destroy(),o===s&&E(this,tn).delete(s.queryHash),this.notify({type:"removed",query:s}))}clear(){it.batch(()=>{this.getAll().forEach(s=>{this.remove(s)})})}get(s){return E(this,tn).get(s)}getAll(){return[...E(this,tn).values()]}find(s){const o={exact:!0,...s};return this.getAll().find(a=>mh(o,a))}findAll(s={}){const o=this.getAll();return Object.keys(s).length>0?o.filter(a=>mh(s,a)):o}notify(s){it.batch(()=>{this.listeners.forEach(o=>{o(s)})})}onFocus(){it.batch(()=>{this.getAll().forEach(s=>{s.onFocus()})})}onOnline(){it.batch(()=>{this.getAll().forEach(s=>{s.onOnline()})})}},tn=new WeakMap,op),Qe,Qn,Kn,vs,ys,qn,xs,ws,lp,ay=(lp=class{constructor(r={}){pe(this,Qe);pe(this,Qn);pe(this,Kn);pe(this,vs);pe(this,ys);pe(this,qn);pe(this,xs);pe(this,ws);J(this,Qe,r.queryCache||new ly),J(this,Qn,r.mutationCache||new oy),J(this,Kn,r.defaultOptions||{}),J(this,vs,new Map),J(this,ys,new Map),J(this,qn,0)}mount(){Ko(this,qn)._++,E(this,qn)===1&&(J(this,xs,tc.subscribe(async r=>{r&&(await this.resumePausedMutations(),E(this,Qe).onFocus())})),J(this,ws,ol.subscribe(async r=>{r&&(await this.resumePausedMutations(),E(this,Qe).onOnline())})))}unmount(){var r,s;Ko(this,qn)._--,E(this,qn)===0&&((r=E(this,xs))==null||r.call(this),J(this,xs,void 0),(s=E(this,ws))==null||s.call(this),J(this,ws,void 0))}isFetching(r){return E(this,Qe).findAll({...r,fetchStatus:"fetching"}).length}isMutating(r){return E(this,Qn).findAll({...r,status:"pending"}).length}getQueryData(r){var o;const s=this.defaultQueryOptions({queryKey:r});return(o=E(this,Qe).get(s.queryHash))==null?void 0:o.state.data}ensureQueryData(r){const s=this.defaultQueryOptions(r),o=E(this,Qe).build(this,s),a=o.state.data;return a===void 0?this.fetchQuery(r):(r.revalidateIfStale&&o.isStaleByTime(Gn(s.staleTime,o))&&this.prefetchQuery(s),Promise.resolve(a))}getQueriesData(r){return E(this,Qe).findAll(r).map(({queryKey:s,state:o})=>{const a=o.data;return[s,a]})}setQueryData(r,s,o){const a=this.defaultQueryOptions({queryKey:r}),u=E(this,Qe).get(a.queryHash),f=u==null?void 0:u.state.data,m=Bv(s,f);if(m!==void 0)return E(this,Qe).build(this,a).setData(m,{...o,manual:!0})}setQueriesData(r,s,o){return it.batch(()=>E(this,Qe).findAll(r).map(({queryKey:a})=>[a,this.setQueryData(a,s,o)]))}getQueryState(r){var o;const s=this.defaultQueryOptions({queryKey:r});return(o=E(this,Qe).get(s.queryHash))==null?void 0:o.state}removeQueries(r){const s=E(this,Qe);it.batch(()=>{s.findAll(r).forEach(o=>{s.remove(o)})})}resetQueries(r,s){const o=E(this,Qe);return it.batch(()=>(o.findAll(r).forEach(a=>{a.reset()}),this.refetchQueries({type:"active",...r},s)))}cancelQueries(r,s={}){const o={revert:!0,...s},a=it.batch(()=>E(this,Qe).findAll(r).map(u=>u.cancel(o)));return Promise.all(a).then(bt).catch(bt)}invalidateQueries(r,s={}){return it.batch(()=>(E(this,Qe).findAll(r).forEach(o=>{o.invalidate()}),(r==null?void 0:r.refetchType)==="none"?Promise.resolve():this.refetchQueries({...r,type:(r==null?void 0:r.refetchType)??(r==null?void 0:r.type)??"active"},s)))}refetchQueries(r,s={}){const o={...s,cancelRefetch:s.cancelRefetch??!0},a=it.batch(()=>E(this,Qe).findAll(r).filter(u=>!u.isDisabled()&&!u.isStatic()).map(u=>{let f=u.fetch(void 0,o);return o.throwOnError||(f=f.catch(bt)),u.state.fetchStatus==="paused"?Promise.resolve():f}));return Promise.all(a).then(bt)}fetchQuery(r){const s=this.defaultQueryOptions(r);s.retry===void 0&&(s.retry=!1);const o=E(this,Qe).build(this,s);return o.isStaleByTime(Gn(s.staleTime,o))?o.fetch(s):Promise.resolve(o.state.data)}prefetchQuery(r){return this.fetchQuery(r).then(bt).catch(bt)}fetchInfiniteQuery(r){return r._type="infinite",this.fetchQuery(r)}prefetchInfiniteQuery(r){return this.fetchInfiniteQuery(r).then(bt).catch(bt)}ensureInfiniteQueryData(r){return r._type="infinite",this.ensureQueryData(r)}resumePausedMutations(){return ol.isOnline()?E(this,Qn).resumePausedMutations():Promise.resolve()}getQueryCache(){return E(this,Qe)}getMutationCache(){return E(this,Qn)}getDefaultOptions(){return E(this,Kn)}setDefaultOptions(r){J(this,Kn,r)}setQueryDefaults(r,s){E(this,vs).set(bi(r),{queryKey:r,defaultOptions:s})}getQueryDefaults(r){const s=[...E(this,vs).values()],o={};return s.forEach(a=>{Si(r,a.queryKey)&&Object.assign(o,a.defaultOptions)}),o}setMutationDefaults(r,s){E(this,ys).set(bi(r),{mutationKey:r,defaultOptions:s})}getMutationDefaults(r){const s=[...E(this,ys).values()],o={};return s.forEach(a=>{Si(r,a.mutationKey)&&Object.assign(o,a.defaultOptions)}),o}defaultQueryOptions(r){if(r._defaulted)return r;const s={...E(this,Kn).queries,...this.getQueryDefaults(r.queryKey),...r,_defaulted:!0};return s.queryHash||(s.queryHash=nc(s.queryKey,s)),s.refetchOnReconnect===void 0&&(s.refetchOnReconnect=s.networkMode!=="always"),s.throwOnError===void 0&&(s.throwOnError=!!s.suspense),!s.networkMode&&s.persister&&(s.networkMode="offlineFirst"),s.queryFn===rc&&(s.enabled=!1),s}defaultMutationOptions(r){return r!=null&&r._defaulted?r:{...E(this,Kn).mutations,...(r==null?void 0:r.mutationKey)&&this.getMutationDefaults(r.mutationKey),...r,_defaulted:!0}}clear(){E(this,Qe).clear(),E(this,Qn).clear()}},Qe=new WeakMap,Qn=new WeakMap,Kn=new WeakMap,vs=new WeakMap,ys=new WeakMap,qn=new WeakMap,xs=new WeakMap,ws=new WeakMap,lp),wp=g.createContext(void 0),ul=r=>{const s=g.useContext(wp);if(!s)throw new Error("No QueryClient set, use QueryClientProvider to set one");return s},uy=({client:r,children:s})=>(g.useEffect(()=>(r.mount(),()=>{r.unmount()}),[r]),d.jsx(wp.Provider,{value:r,children:s})),kp=g.createContext(!1),cy=()=>g.useContext(kp);kp.Provider;function dy(){let r=!1;return{clearReset:()=>{r=!1},reset:()=>{r=!0},isReset:()=>r}}var fy=g.createContext(dy()),hy=()=>g.useContext(fy),py=(r,s,o)=>{const a=o!=null&&o.state.error&&typeof r.throwOnError=="function"?hp(r.throwOnError,[o.state.error,o]):r.throwOnError;(r.suspense||r.experimental_prefetchInRender||a)&&(s.isReset()||(r.retryOnMount=!1))},my=r=>{g.useEffect(()=>{r.clearReset()},[r])},gy=({result:r,errorResetBoundary:s,throwOnError:o,query:a,suspense:u})=>r.isError&&!s.isReset()&&!r.isFetching&&a&&(u&&r.data===void 0||hp(o,[r.error,a])),vy=r=>{if(r.suspense){const o=u=>u==="static"?u:Math.max(u??1e3,1e3),a=r.staleTime;r.staleTime=typeof a=="function"?(...u)=>o(a(...u)):o(a),typeof r.gcTime=="number"&&(r.gcTime=Math.max(r.gcTime,1e3))}},yy=(r,s)=>r.isLoading&&r.isFetching&&!s,xy=(r,s)=>(r==null?void 0:r.suspense)&&s.isPending,Eh=(r,s,o)=>s.fetchOptimistic(r).catch(()=>{o.clearReset()});function wy(r,s,o){var _,D,b,R;const a=cy(),u=hy(),f=ul(),m=f.defaultQueryOptions(r);(D=(_=f.getDefaultOptions().queries)==null?void 0:_._experimental_beforeQuery)==null||D.call(_,m);const h=f.getQueryCache().get(m.queryHash),y=r.subscribed!==!1;m._optimisticResults=a?"isRestoring":y?"optimistic":void 0,vy(m),py(m,u,h),my(u);const k=!f.getQueryCache().get(m.queryHash),[w]=g.useState(()=>new s(f,m)),x=w.getOptimisticResult(m),P=!a&&y;if(g.useSyncExternalStore(g.useCallback(A=>{const I=P?w.subscribe(it.batchCalls(A)):bt;return w.updateResult(),I},[w,P]),()=>w.getCurrentResult(),()=>w.getCurrentResult()),g.useEffect(()=>{w.setOptions(m)},[m,w]),xy(m,x))throw Eh(m,w,u);if(gy({result:x,errorResetBoundary:u,throwOnError:m.throwOnError,query:h,suspense:m.suspense}))throw x.error;if((R=(b=f.getDefaultOptions().queries)==null?void 0:b._experimental_afterQuery)==null||R.call(b,m,x),m.experimental_prefetchInRender&&!Ei.isServer()&&yy(x,a)){const A=k?Eh(m,w,u):h==null?void 0:h.promise;A==null||A.catch(bt).finally(()=>{w.updateResult()})}return m.notifyOnChangeProps?x:w.trackResult(x)}function Be(r,s){return wy(r,ty)}const ky="modulepreload",by=function(r){return"/"+r},Nh={},Wt=function(s,o,a){let u=Promise.resolve();if(o&&o.length>0){let m=function(k){return Promise.all(k.map(w=>Promise.resolve(w).then(x=>({status:"fulfilled",value:x}),x=>({status:"rejected",reason:x}))))};document.getElementsByTagName("link");const h=document.querySelector("meta[property=csp-nonce]"),y=(h==null?void 0:h.nonce)||(h==null?void 0:h.getAttribute("nonce"));u=m(o.map(k=>{if(k=by(k),k in Nh)return;Nh[k]=!0;const w=k.endsWith(".css"),x=w?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${k}"]${x}`))return;const P=document.createElement("link");if(P.rel=w?"stylesheet":ky,w||(P.as="script"),P.crossOrigin="",P.href=k,y&&P.setAttribute("nonce",y),document.head.appendChild(P),w)return new Promise((_,D)=>{P.addEventListener("load",_),P.addEventListener("error",()=>D(new Error(`Unable to preload CSS for ${k}`)))})}))}function f(m){const h=new Event("vite:preloadError",{cancelable:!0});if(h.payload=m,window.dispatchEvent(h),!h.defaultPrevented)throw m}return u.then(m=>{for(const h of m||[])h.status==="rejected"&&f(h.reason);return s().catch(f)})};/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Sy=r=>r.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),bp=(...r)=>r.filter((s,o,a)=>!!s&&s.trim()!==""&&a.indexOf(s)===o).join(" ").trim();/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/var Ey={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"};/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ny=g.forwardRef(({color:r="currentColor",size:s=24,strokeWidth:o=2,absoluteStrokeWidth:a,className:u="",children:f,iconNode:m,...h},y)=>g.createElement("svg",{ref:y,...Ey,width:s,height:s,stroke:r,strokeWidth:a?Number(o)*24/Number(s):o,className:bp("lucide",u),...h},[...m.map(([k,w])=>g.createElement(k,w)),...Array.isArray(f)?f:[f]]));/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ge=(r,s)=>{const o=g.forwardRef(({className:a,...u},f)=>g.createElement(Ny,{ref:f,iconNode:s,className:bp(`lucide-${Sy(r)}`,a),...u}));return o.displayName=`${r}`,o};/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const jy=ge("Activity",[["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"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const jh=ge("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Cy=ge("BookMarked",[["path",{d:"M10 2v8l3-3 3 3V2",key:"sqw3rj"}],["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ni=ge("Bot",[["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"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const _y=ge("Box",[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Sp=ge("Boxes",[["path",{d:"M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z",key:"lc1i9w"}],["path",{d:"m7 16.5-4.74-2.85",key:"1o9zyk"}],["path",{d:"m7 16.5 5-3",key:"va8pkn"}],["path",{d:"M7 16.5v5.17",key:"jnp8gn"}],["path",{d:"M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z",key:"8zsnat"}],["path",{d:"m17 16.5-5-3",key:"8arw3v"}],["path",{d:"m17 16.5 4.74-2.85",key:"8rfmw"}],["path",{d:"M17 16.5v5.17",key:"k6z78m"}],["path",{d:"M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z",key:"1xygjf"}],["path",{d:"M12 8 7.26 5.15",key:"1vbdud"}],["path",{d:"m12 8 4.74-2.85",key:"3rx089"}],["path",{d:"M12 13.5V8",key:"1io7kd"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Py=ge("Brain",[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z",key:"l5xja"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z",key:"ep3f8r"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4",key:"1p4c4q"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375",key:"tmeiqw"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5",key:"105sqy"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396",key:"ql3yin"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396",key:"1qfode"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18",key:"159ez6"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ry=ge("Camera",[["path",{d:"M14.5 4h-5L7 7H4a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-3l-2.5-3z",key:"1tc9qg"}],["circle",{cx:"12",cy:"13",r:"3",key:"1vg3eu"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const My=ge("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Oy=ge("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const wi=ge("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ty=ge("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ep=ge("CircleHelp",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ly=ge("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Dy=ge("CloudDownload",[["path",{d:"M12 13v8l-4-4",key:"1f5nwf"}],["path",{d:"m12 21 4-4",key:"1lfcce"}],["path",{d:"M4.393 15.269A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.436 8.284",key:"ui1hmy"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ay=ge("Command",[["path",{d:"M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3",key:"11bfej"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Np=ge("Cpu",[["rect",{width:"16",height:"16",x:"4",y:"4",rx:"2",key:"14l7u7"}],["rect",{width:"6",height:"6",x:"9",y:"9",rx:"1",key:"5aljv4"}],["path",{d:"M15 2v2",key:"13l42r"}],["path",{d:"M15 20v2",key:"15mkzm"}],["path",{d:"M2 15h2",key:"1gxd5l"}],["path",{d:"M2 9h2",key:"1bbxkp"}],["path",{d:"M20 15h2",key:"19e6y8"}],["path",{d:"M20 9h2",key:"19tzq7"}],["path",{d:"M9 2v2",key:"165o2o"}],["path",{d:"M9 20v2",key:"i2bqo8"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const zy=ge("ExternalLink",[["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"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Fy=ge("EyeOff",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const jp=ge("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Iy=ge("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Uy=ge("Gauge",[["path",{d:"m12 14 4-4",key:"9kzdfg"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0",key:"19p75a"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const $y=ge("GitCommitHorizontal",[["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["line",{x1:"3",x2:"9",y1:"12",y2:"12",key:"1dyftd"}],["line",{x1:"15",x2:"21",y1:"12",y2:"12",key:"oup4p8"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const By=ge("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Vy=ge("HeartPulse",[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z",key:"c3ymky"}],["path",{d:"M3.22 12H9.5l.5-1 2 4.5 2-7 1.5 3.5h5.27",key:"1uw2ng"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Hy=ge("History",[["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"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ic=ge("Inbox",[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Wy=ge("Key",[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Qy=ge("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ky=ge("Library",[["path",{d:"m16 6 4 14",key:"ji33uf"}],["path",{d:"M12 6v14",key:"1n7gus"}],["path",{d:"M8 8v12",key:"1gg7y9"}],["path",{d:"M4 4v16",key:"6qkkli"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const qy=ge("Lightbulb",[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ji=ge("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Gy=ge("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Zy=ge("Mic",[["path",{d:"M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z",key:"131961"}],["path",{d:"M19 10v2a7 7 0 0 1-14 0v-2",key:"1vc78b"}],["line",{x1:"12",x2:"12",y1:"19",y2:"22",key:"x3vr5v"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ch=ge("Package",[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["path",{d:"m3.3 7 7.703 4.734a2 2 0 0 0 1.994 0L20.7 7",key:"yx3hmr"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const oc=ge("Plug",[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M9 8V2",key:"14iosj"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M18 8v5a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V8Z",key:"osxo6l"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Yy=ge("Power",[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ss=ge("RefreshCw",[["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"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Xy=ge("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const cl=ge("Server",[["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"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const lc=ge("ShieldAlert",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Cp=ge("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const _p=ge("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Pp=ge("Shuffle",[["path",{d:"M2 18h1.4c1.3 0 2.5-.6 3.3-1.7l6.1-8.6c.7-1.1 2-1.7 3.3-1.7H22",key:"1wmou1"}],["path",{d:"m18 2 4 4-4 4",key:"pucp1d"}],["path",{d:"M2 6h1.9c1.5 0 2.9.9 3.6 2.2",key:"10bdb2"}],["path",{d:"M22 18h-5.9c-1.3 0-2.6-.7-3.3-1.8l-.5-.8",key:"vgxac0"}],["path",{d:"m18 14 4 4-4 4",key:"10pe0f"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Jy=ge("SlidersHorizontal",[["line",{x1:"21",x2:"14",y1:"4",y2:"4",key:"obuewd"}],["line",{x1:"10",x2:"3",y1:"4",y2:"4",key:"1q6298"}],["line",{x1:"21",x2:"12",y1:"12",y2:"12",key:"1iu8h1"}],["line",{x1:"8",x2:"3",y1:"12",y2:"12",key:"ntss68"}],["line",{x1:"21",x2:"16",y1:"20",y2:"20",key:"14d8ph"}],["line",{x1:"12",x2:"3",y1:"20",y2:"20",key:"m0wm8r"}],["line",{x1:"14",x2:"14",y1:"2",y2:"6",key:"14e1ph"}],["line",{x1:"8",x2:"8",y1:"10",y2:"14",key:"1i6ji0"}],["line",{x1:"16",x2:"16",y1:"18",y2:"22",key:"1lctlv"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const e0=ge("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const t0=ge("SquareTerminal",[["path",{d:"m7 11 2-2-2-2",key:"1lz0vl"}],["path",{d:"M11 13h4",key:"1p7l4v"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const n0=ge("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ci=ge("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const r0=ge("Wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z",key:"cbrjhi"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const dl=ge("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),is=[{id:"dashboard",label:"Cockpit",hint:"Deine Box auf einen Blick",icon:Qy,group:"Operativ"},{id:"ideen",label:"Ideen",hint:"Schreib hin, was entstehen soll",icon:qy,group:"Operativ"},{id:"auftraege",label:"Auftragsbuch",hint:"Vorschläge der Box — annehmen oder ablehnen",icon:ic,group:"Operativ"},{id:"skills",label:"Skills & Jobs",hint:"Autonome Skills manuell auslösen",icon:Ni,group:"Operativ"},{id:"chronik",label:"Chronik",hint:"Was die Box von allein getan hat + Zeitmaschine",icon:Hy,group:"Operativ"},{id:"wissen",label:"Wissen",hint:"Lucys Wissens-Vault (Traum-Notizen)",icon:Ky,group:"Wissen"},{id:"connect",label:"Verbinden",hint:"IDE-/Agent-Configs erzeugen",icon:oc,group:"Werkzeuge"},{id:"konsole",label:"Konsole",hint:"Direkte Box-Shell (SSH-artig)",icon:t0,group:"Werkzeuge"},{id:"guide",label:"Anleitung",hint:"Einrichten & Vibe-Coding",icon:Ep,group:"Werkzeuge"},{id:"models",label:"Modelle",hint:"Speicher, laden & Rollen",icon:Sp,group:"Wartung"},{id:"agent",label:"Hermes",hint:"Agent-Status & Verdrahtung",icon:Ni,group:"Wartung"}];var _h=1,s0=.9,i0=.8,o0=.17,pu=.1,mu=.999,l0=.9999,a0=.99,u0=/[\\\/_+.#"@\[\(\{&]/,c0=/[\\\/_+.#"@\[\(\{&]/g,d0=/[\s-]/,Rp=/[\s-]/g;function $u(r,s,o,a,u,f,m){if(f===s.length)return u===r.length?_h:a0;var h=`${u},${f}`;if(m[h]!==void 0)return m[h];for(var y=a.charAt(f),k=o.indexOf(y,u),w=0,x,P,_,D;k>=0;)x=$u(r,s,o,a,k+1,f+1,m),x>w&&(k===u?x*=_h:u0.test(r.charAt(k-1))?(x*=i0,_=r.slice(u,k-1).match(c0),_&&u>0&&(x*=Math.pow(mu,_.length))):d0.test(r.charAt(k-1))?(x*=s0,D=r.slice(u,k-1).match(Rp),D&&u>0&&(x*=Math.pow(mu,D.length))):(x*=o0,u>0&&(x*=Math.pow(mu,k-u))),r.charAt(k)!==s.charAt(f)&&(x*=l0)),(x<pu&&o.charAt(k-1)===a.charAt(f+1)||a.charAt(f+1)===a.charAt(f)&&o.charAt(k-1)!==a.charAt(f))&&(P=$u(r,s,o,a,k+1,f+2,m),P*pu>x&&(x=P*pu)),x>w&&(w=x),k=o.indexOf(y,k+1);return m[h]=w,w}function Ph(r){return r.toLowerCase().replace(Rp," ")}function f0(r,s,o){return r=o&&o.length>0?`${r+" "+o.join(" ")}`:r,$u(r,s,Ph(r),Ph(s),0,0,{})}function Zn(r,s,{checkForDefaultPrevented:o=!0}={}){return function(u){if(r==null||r(u),o===!1||!u.defaultPrevented)return s==null?void 0:s(u)}}function Rh(r,s){if(typeof r=="function")return r(s);r!=null&&(r.current=s)}function ks(...r){return s=>{let o=!1;const a=r.map(u=>{const f=Rh(u,s);return!o&&typeof f=="function"&&(o=!0),f});if(o)return()=>{for(let u=0;u<a.length;u++){const f=a[u];typeof f=="function"?f():Rh(r[u],null)}}}}function br(...r){return g.useCallback(ks(...r),r)}function h0(r,s=[]){let o=[];function a(f,m){const h=g.createContext(m);h.displayName=f+"Context";const y=o.length;o=[...o,m];const k=x=>{var A;const{scope:P,children:_,...D}=x,b=((A=P==null?void 0:P[r])==null?void 0:A[y])||h,R=g.useMemo(()=>D,Object.values(D));return d.jsx(b.Provider,{value:R,children:_})};k.displayName=f+"Provider";function w(x,P){var b;const _=((b=P==null?void 0:P[r])==null?void 0:b[y])||h,D=g.useContext(_);if(D)return D;if(m!==void 0)return m;throw new Error(`\`${x}\` must be used within \`${f}\``)}return[k,w]}const u=()=>{const f=o.map(m=>g.createContext(m));return function(h){const y=(h==null?void 0:h[r])||f;return g.useMemo(()=>({[`__scope${r}`]:{...h,[r]:y}}),[h,y])}};return u.scopeName=r,[a,p0(u,...s)]}function p0(...r){const s=r[0];if(r.length===1)return s;const o=()=>{const a=r.map(u=>({useScope:u(),scopeName:u.scopeName}));return function(f){const m=a.reduce((h,{useScope:y,scopeName:k})=>{const x=y(f)[`__scope${k}`];return{...h,...x}},{});return g.useMemo(()=>({[`__scope${s.scopeName}`]:m}),[m])}};return o.scopeName=s.scopeName,o}var _i=globalThis!=null&&globalThis.document?g.useLayoutEffect:()=>{},m0=ec[" useId ".trim().toString()]||(()=>{}),g0=0;function vn(r){const[s,o]=g.useState(m0());return _i(()=>{o(a=>a??String(g0++))},[r]),s?`radix-${s}`:""}var v0=ec[" useInsertionEffect ".trim().toString()]||_i;function y0({prop:r,defaultProp:s,onChange:o=()=>{},caller:a}){const[u,f,m]=x0({defaultProp:s,onChange:o}),h=r!==void 0,y=h?r:u;{const w=g.useRef(r!==void 0);g.useEffect(()=>{const x=w.current;x!==h&&console.warn(`${a} is changing from ${x?"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.`),w.current=h},[h,a])}const k=g.useCallback(w=>{var x;if(h){const P=w0(w)?w(r):w;P!==r&&((x=m.current)==null||x.call(m,P))}else f(w)},[h,r,f,m]);return[y,k]}function x0({defaultProp:r,onChange:s}){const[o,a]=g.useState(r),u=g.useRef(o),f=g.useRef(s);return v0(()=>{f.current=s},[s]),g.useEffect(()=>{var m;u.current!==o&&((m=f.current)==null||m.call(f,o),u.current=o)},[o,u]),[o,a,f]}function w0(r){return typeof r=="function"}var Mp=up();function Op(r){const s=g.forwardRef((o,a)=>{let{children:u,...f}=o,m=null,h=!1;const y=[];Mh(u)&&typeof Zo=="function"&&(u=Zo(u._payload)),g.Children.forEach(u,P=>{var _;if(N0(P)){h=!0;const D=P;let b="child"in D.props?D.props.child:D.props.children;Mh(b)&&typeof Zo=="function"&&(b=Zo(b._payload)),m=b0(D,b),y.push((_=m==null?void 0:m.props)==null?void 0:_.children)}else y.push(P)}),m?m=g.cloneElement(m,void 0,y):!h&&g.Children.count(u)===1&&g.isValidElement(u)&&(m=u);const k=m?E0(m):void 0,w=br(a,k);if(!m){if(u||u===0)throw new Error(h?P0(r):_0(r));return u}const x=S0(f,m.props??{});return m.type!==g.Fragment&&(x.ref=a?w:k),g.cloneElement(m,x)});return s.displayName=`${r}.Slot`,s}var k0=Symbol.for("radix.slottable"),b0=(r,s)=>{if("child"in r.props){const o=r.props.child;return g.isValidElement(o)?g.cloneElement(o,void 0,r.props.children(o.props.children)):null}return g.isValidElement(s)?s:null};function S0(r,s){const o={...s};for(const a in s){const u=r[a],f=s[a];/^on[A-Z]/.test(a)?u&&f?o[a]=(...h)=>{const y=f(...h);return u(...h),y}:u&&(o[a]=u):a==="style"?o[a]={...u,...f}:a==="className"&&(o[a]=[u,f].filter(Boolean).join(" "))}return{...r,...o}}function E0(r){var a,u;let s=(a=Object.getOwnPropertyDescriptor(r.props,"ref"))==null?void 0:a.get,o=s&&"isReactWarning"in s&&s.isReactWarning;return o?r.ref:(s=(u=Object.getOwnPropertyDescriptor(r,"ref"))==null?void 0:u.get,o=s&&"isReactWarning"in s&&s.isReactWarning,o?r.props.ref:r.props.ref||r.ref)}function N0(r){return g.isValidElement(r)&&typeof r.type=="function"&&"__radixId"in r.type&&r.type.__radixId===k0}var j0=Symbol.for("react.lazy");function Mh(r){return r!=null&&typeof r=="object"&&"$$typeof"in r&&r.$$typeof===j0&&"_payload"in r&&C0(r._payload)}function C0(r){return typeof r=="object"&&r!==null&&"then"in r}var _0=r=>`${r} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,P0=r=>`${r} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,Zo=ec[" use ".trim().toString()],R0=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ot=R0.reduce((r,s)=>{const o=Op(`Primitive.${s}`),a=g.forwardRef((u,f)=>{const{asChild:m,...h}=u,y=m?o:s;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(y,{...h,ref:f})});return a.displayName=`Primitive.${s}`,{...r,[s]:a}},{});function M0(r,s){r&&Mp.flushSync(()=>r.dispatchEvent(s))}function Pi(r){const s=g.useRef(r);return g.useEffect(()=>{s.current=r}),g.useMemo(()=>((...o)=>{var a;return(a=s.current)==null?void 0:a.call(s,...o)}),[])}function O0(r,s=globalThis==null?void 0:globalThis.document){const o=Pi(r);g.useEffect(()=>{const a=u=>{u.key==="Escape"&&o(u)};return s.addEventListener("keydown",a,{capture:!0}),()=>s.removeEventListener("keydown",a,{capture:!0})},[o,s])}var T0="DismissableLayer",Bu="dismissableLayer.update",L0="dismissableLayer.pointerDownOutside",D0="dismissableLayer.focusOutside",Oh,ac=g.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),Tp=g.forwardRef((r,s)=>{const{disableOutsidePointerEvents:o=!1,deferPointerDownOutside:a=!1,onEscapeKeyDown:u,onPointerDownOutside:f,onFocusOutside:m,onInteractOutside:h,onDismiss:y,...k}=r,w=g.useContext(ac),[x,P]=g.useState(null),_=(x==null?void 0:x.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,D]=g.useState({}),b=br(s,ee=>P(ee)),R=Array.from(w.layers),[A]=[...w.layersWithOutsidePointerEventsDisabled].slice(-1),I=R.indexOf(A),V=x?R.indexOf(x):-1,z=w.layersWithOutsidePointerEventsDisabled.size>0,K=V>=I,G=g.useRef(!1),ue=I0(ee=>{const me=ee.target;if(!(me instanceof Node))return;const ke=[...w.branches].some(le=>le.contains(me));!K||ke||(f==null||f(ee),h==null||h(ee),ee.defaultPrevented||y==null||y())},{ownerDocument:_,deferPointerDownOutside:a,isDeferredPointerDownOutsideRef:G,dismissableSurfaces:w.dismissableSurfaces}),oe=U0(ee=>{if(a&&G.current)return;const me=ee.target;[...w.branches].some(le=>le.contains(me))||(m==null||m(ee),h==null||h(ee),ee.defaultPrevented||y==null||y())},_);return O0(ee=>{V===w.layers.size-1&&(u==null||u(ee),!ee.defaultPrevented&&y&&(ee.preventDefault(),y()))},_),g.useEffect(()=>{if(x)return o&&(w.layersWithOutsidePointerEventsDisabled.size===0&&(Oh=_.body.style.pointerEvents,_.body.style.pointerEvents="none"),w.layersWithOutsidePointerEventsDisabled.add(x)),w.layers.add(x),Th(),()=>{o&&(w.layersWithOutsidePointerEventsDisabled.delete(x),w.layersWithOutsidePointerEventsDisabled.size===0&&(_.body.style.pointerEvents=Oh))}},[x,_,o,w]),g.useEffect(()=>()=>{x&&(w.layers.delete(x),w.layersWithOutsidePointerEventsDisabled.delete(x),Th())},[x,w]),g.useEffect(()=>{const ee=()=>D({});return document.addEventListener(Bu,ee),()=>document.removeEventListener(Bu,ee)},[]),d.jsx(ot.div,{...k,ref:b,style:{pointerEvents:z?K?"auto":"none":void 0,...r.style},onFocusCapture:Zn(r.onFocusCapture,oe.onFocusCapture),onBlurCapture:Zn(r.onBlurCapture,oe.onBlurCapture),onPointerDownCapture:Zn(r.onPointerDownCapture,ue.onPointerDownCapture)})});Tp.displayName=T0;var A0="DismissableLayerBranch",z0=g.forwardRef((r,s)=>{const o=g.useContext(ac),a=g.useRef(null),u=br(s,a);return g.useEffect(()=>{const f=a.current;if(f)return o.branches.add(f),()=>{o.branches.delete(f)}},[o.branches]),d.jsx(ot.div,{...r,ref:u})});z0.displayName=A0;function F0(){const r=g.useContext(ac),[s,o]=g.useState(null);return g.useEffect(()=>{if(s)return r.dismissableSurfaces.add(s),()=>{r.dismissableSurfaces.delete(s)}},[s,r.dismissableSurfaces]),o}function I0(r,s){const{ownerDocument:o=globalThis==null?void 0:globalThis.document,deferPointerDownOutside:a=!1,isDeferredPointerDownOutsideRef:u,dismissableSurfaces:f}=s,m=Pi(r),h=g.useRef(!1),y=g.useRef(!1),k=g.useRef(new Map),w=g.useRef(()=>{});return g.useEffect(()=>{function x(){y.current=!1,u.current=!1,k.current.clear()}function P(){return Array.from(k.current.values()).some(Boolean)}function _(I){if(!y.current)return;const V=I.target;V instanceof Node&&[...f].some(K=>K.contains(V))||k.current.set(I.type,!0),I.type==="click"&&window.setTimeout(()=>{y.current&&w.current()},0)}function D(I){y.current&&k.current.set(I.type,!1)}const b=I=>{if(I.target&&!h.current){let V=function(){o.removeEventListener("click",w.current);const K=P();x(),K||Lp(L0,m,z,{discrete:!0})};const z={originalEvent:I};y.current=!0,u.current=a&&I.button===0,k.current.clear(),!a||I.button!==0?V():(o.removeEventListener("click",w.current),w.current=V,o.addEventListener("click",w.current,{once:!0}))}else o.removeEventListener("click",w.current),x();h.current=!1},R=["pointerup","mousedown","mouseup","touchstart","touchend","click"];for(const I of R)o.addEventListener(I,_,!0),o.addEventListener(I,D);const A=window.setTimeout(()=>{o.addEventListener("pointerdown",b)},0);return()=>{window.clearTimeout(A),o.removeEventListener("pointerdown",b),o.removeEventListener("click",w.current);for(const I of R)o.removeEventListener(I,_,!0),o.removeEventListener(I,D)}},[o,m,a,u,f]),{onPointerDownCapture:()=>h.current=!0}}function U0(r,s=globalThis==null?void 0:globalThis.document){const o=Pi(r),a=g.useRef(!1);return g.useEffect(()=>{const u=f=>{f.target&&!a.current&&Lp(D0,o,{originalEvent:f},{discrete:!1})};return s.addEventListener("focusin",u),()=>s.removeEventListener("focusin",u)},[s,o]),{onFocusCapture:()=>a.current=!0,onBlurCapture:()=>a.current=!1}}function Th(){const r=new CustomEvent(Bu);document.dispatchEvent(r)}function Lp(r,s,o,{discrete:a}){const u=o.originalEvent.target,f=new CustomEvent(r,{bubbles:!1,cancelable:!0,detail:o});s&&u.addEventListener(r,s,{once:!0}),a?M0(u,f):u.dispatchEvent(f)}var gu="focusScope.autoFocusOnMount",vu="focusScope.autoFocusOnUnmount",Lh={bubbles:!1,cancelable:!0},$0="FocusScope",Dp=g.forwardRef((r,s)=>{const{loop:o=!1,trapped:a=!1,onMountAutoFocus:u,onUnmountAutoFocus:f,...m}=r,[h,y]=g.useState(null),k=Pi(u),w=Pi(f),x=g.useRef(null),P=br(s,b=>y(b)),_=g.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;g.useEffect(()=>{if(a){let b=function(V){if(_.paused||!h)return;const z=V.target;h.contains(z)?x.current=z:Un(x.current,{select:!0})},R=function(V){if(_.paused||!h)return;const z=V.relatedTarget;z!==null&&(h.contains(z)||Un(x.current,{select:!0}))},A=function(V){if(document.activeElement===document.body)for(const K of V)K.removedNodes.length>0&&Un(h)};document.addEventListener("focusin",b),document.addEventListener("focusout",R);const I=new MutationObserver(A);return h&&I.observe(h,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",b),document.removeEventListener("focusout",R),I.disconnect()}}},[a,h,_.paused]),g.useEffect(()=>{if(h){Ah.add(_);const b=document.activeElement;if(!h.contains(b)){const A=new CustomEvent(gu,Lh);h.addEventListener(gu,k),h.dispatchEvent(A),A.defaultPrevented||(B0(K0(Ap(h)),{select:!0}),document.activeElement===b&&Un(h))}return()=>{h.removeEventListener(gu,k),setTimeout(()=>{const A=new CustomEvent(vu,Lh);h.addEventListener(vu,w),h.dispatchEvent(A),A.defaultPrevented||Un(b??document.body,{select:!0}),h.removeEventListener(vu,w),Ah.remove(_)},0)}}},[h,k,w,_]);const D=g.useCallback(b=>{if(!o&&!a||_.paused)return;const R=b.key==="Tab"&&!b.altKey&&!b.ctrlKey&&!b.metaKey,A=document.activeElement;if(R&&A){const I=b.currentTarget,[V,z]=V0(I);V&&z?!b.shiftKey&&A===z?(b.preventDefault(),o&&Un(V,{select:!0})):b.shiftKey&&A===V&&(b.preventDefault(),o&&Un(z,{select:!0})):A===I&&b.preventDefault()}},[o,a,_.paused]);return d.jsx(ot.div,{tabIndex:-1,...m,ref:P,onKeyDown:D})});Dp.displayName=$0;function B0(r,{select:s=!1}={}){const o=document.activeElement;for(const a of r)if(Un(a,{select:s}),document.activeElement!==o)return}function V0(r){const s=Ap(r),o=Dh(s,r),a=Dh(s.reverse(),r);return[o,a]}function Ap(r){const s=[],o=document.createTreeWalker(r,NodeFilter.SHOW_ELEMENT,{acceptNode:a=>{const u=a.tagName==="INPUT"&&a.type==="hidden";return a.disabled||a.hidden||u?NodeFilter.FILTER_SKIP:a.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;o.nextNode();)s.push(o.currentNode);return s}function Dh(r,s){for(const o of r)if(!H0(o,{upTo:s}))return o}function H0(r,{upTo:s}){if(getComputedStyle(r).visibility==="hidden")return!0;for(;r;){if(s!==void 0&&r===s)return!1;if(getComputedStyle(r).display==="none")return!0;r=r.parentElement}return!1}function W0(r){return r instanceof HTMLInputElement&&"select"in r}function Un(r,{select:s=!1}={}){if(r&&r.focus){const o=document.activeElement;r.focus({preventScroll:!0}),r!==o&&W0(r)&&s&&r.select()}}var Ah=Q0();function Q0(){let r=[];return{add(s){const o=r[0];s!==o&&(o==null||o.pause()),r=zh(r,s),r.unshift(s)},remove(s){var o;r=zh(r,s),(o=r[0])==null||o.resume()}}}function zh(r,s){const o=[...r],a=o.indexOf(s);return a!==-1&&o.splice(a,1),o}function K0(r){return r.filter(s=>s.tagName!=="A")}var q0="Portal",zp=g.forwardRef((r,s)=>{var h;const{container:o,...a}=r,[u,f]=g.useState(!1);_i(()=>f(!0),[]);const m=o||u&&((h=globalThis==null?void 0:globalThis.document)==null?void 0:h.body);return m?Mp.createPortal(d.jsx(ot.div,{...a,ref:s}),m):null});zp.displayName=q0;function G0(r,s){return g.useReducer((o,a)=>s[o][a]??o,r)}var fl=r=>{const{present:s,children:o}=r,a=Z0(s),u=typeof o=="function"?o({present:a.isPresent}):g.Children.only(o),f=Y0(a.ref,X0(u));return typeof o=="function"||a.isPresent?g.cloneElement(u,{ref:f}):null};fl.displayName="Presence";function Z0(r){const[s,o]=g.useState(),a=g.useRef(null),u=g.useRef(r),f=g.useRef("none"),m=r?"mounted":"unmounted",[h,y]=G0(m,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return g.useEffect(()=>{const k=Yo(a.current);f.current=h==="mounted"?k:"none"},[h]),_i(()=>{const k=a.current,w=u.current;if(w!==r){const P=f.current,_=Yo(k);r?y("MOUNT"):_==="none"||(k==null?void 0:k.display)==="none"?y("UNMOUNT"):y(w&&P!==_?"ANIMATION_OUT":"UNMOUNT"),u.current=r}},[r,y]),_i(()=>{if(s){let k;const w=s.ownerDocument.defaultView??window,x=_=>{const b=Yo(a.current).includes(CSS.escape(_.animationName));if(_.target===s&&b&&(y("ANIMATION_END"),!u.current)){const R=s.style.animationFillMode;s.style.animationFillMode="forwards",k=w.setTimeout(()=>{s.style.animationFillMode==="forwards"&&(s.style.animationFillMode=R)})}},P=_=>{_.target===s&&(f.current=Yo(a.current))};return s.addEventListener("animationstart",P),s.addEventListener("animationcancel",x),s.addEventListener("animationend",x),()=>{w.clearTimeout(k),s.removeEventListener("animationstart",P),s.removeEventListener("animationcancel",x),s.removeEventListener("animationend",x)}}else y("ANIMATION_END")},[s,y]),{isPresent:["mounted","unmountSuspended"].includes(h),ref:g.useCallback(k=>{a.current=k?getComputedStyle(k):null,o(k)},[])}}function Fh(r,s){if(typeof r=="function")return r(s);r!=null&&(r.current=s)}function Y0(...r){const s=g.useRef(r);return s.current=r,g.useCallback(o=>{const a=s.current;let u=!1;const f=a.map(m=>{const h=Fh(m,o);return!u&&typeof h=="function"&&(u=!0),h});if(u)return()=>{for(let m=0;m<f.length;m++){const h=f[m];typeof h=="function"?h():Fh(a[m],null)}}},[])}function Yo(r){return(r==null?void 0:r.animationName)||"none"}function X0(r){var a,u;let s=(a=Object.getOwnPropertyDescriptor(r.props,"ref"))==null?void 0:a.get,o=s&&"isReactWarning"in s&&s.isReactWarning;return o?r.ref:(s=(u=Object.getOwnPropertyDescriptor(r,"ref"))==null?void 0:u.get,o=s&&"isReactWarning"in s&&s.isReactWarning,o?r.props.ref:r.props.ref||r.ref)}var Xo=0,Xt=null;function J0(){g.useEffect(()=>{Xt||(Xt={start:Ih(),end:Ih()});const{start:r,end:s}=Xt;return document.body.firstElementChild!==r&&document.body.insertAdjacentElement("afterbegin",r),document.body.lastElementChild!==s&&document.body.insertAdjacentElement("beforeend",s),Xo++,()=>{Xo===1&&(Xt==null||Xt.start.remove(),Xt==null||Xt.end.remove(),Xt=null),Xo=Math.max(0,Xo-1)}},[])}function Ih(){const r=document.createElement("span");return r.setAttribute("data-radix-focus-guard",""),r.tabIndex=0,r.style.outline="none",r.style.opacity="0",r.style.position="fixed",r.style.pointerEvents="none",r}var nn=function(){return nn=Object.assign||function(s){for(var o,a=1,u=arguments.length;a<u;a++){o=arguments[a];for(var f in o)Object.prototype.hasOwnProperty.call(o,f)&&(s[f]=o[f])}return s},nn.apply(this,arguments)};function Fp(r,s){var o={};for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&s.indexOf(a)<0&&(o[a]=r[a]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var u=0,a=Object.getOwnPropertySymbols(r);u<a.length;u++)s.indexOf(a[u])<0&&Object.prototype.propertyIsEnumerable.call(r,a[u])&&(o[a[u]]=r[a[u]]);return o}function ex(r,s,o){if(o||arguments.length===2)for(var a=0,u=s.length,f;a<u;a++)(f||!(a in s))&&(f||(f=Array.prototype.slice.call(s,0,a)),f[a]=s[a]);return r.concat(f||Array.prototype.slice.call(s))}var rl="right-scroll-bar-position",sl="width-before-scroll-bar",tx="with-scroll-bars-hidden",nx="--removed-body-scroll-bar-size";function yu(r,s){return typeof r=="function"?r(s):r&&(r.current=s),r}function rx(r,s){var o=g.useState(function(){return{value:r,callback:s,facade:{get current(){return o.value},set current(a){var u=o.value;u!==a&&(o.value=a,o.callback(a,u))}}}})[0];return o.callback=s,o.facade}var sx=typeof window<"u"?g.useLayoutEffect:g.useEffect,Uh=new WeakMap;function ix(r,s){var o=rx(null,function(a){return r.forEach(function(u){return yu(u,a)})});return sx(function(){var a=Uh.get(o);if(a){var u=new Set(a),f=new Set(r),m=o.current;u.forEach(function(h){f.has(h)||yu(h,null)}),f.forEach(function(h){u.has(h)||yu(h,m)})}Uh.set(o,r)},[r]),o}function ox(r){return r}function lx(r,s){s===void 0&&(s=ox);var o=[],a=!1,u={read:function(){if(a)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]:r},useMedium:function(f){var m=s(f,a);return o.push(m),function(){o=o.filter(function(h){return h!==m})}},assignSyncMedium:function(f){for(a=!0;o.length;){var m=o;o=[],m.forEach(f)}o={push:function(h){return f(h)},filter:function(){return o}}},assignMedium:function(f){a=!0;var m=[];if(o.length){var h=o;o=[],h.forEach(f),m=o}var y=function(){var w=m;m=[],w.forEach(f)},k=function(){return Promise.resolve().then(y)};k(),o={push:function(w){m.push(w),k()},filter:function(w){return m=m.filter(w),o}}}};return u}function ax(r){r===void 0&&(r={});var s=lx(null);return s.options=nn({async:!0,ssr:!1},r),s}var Ip=function(r){var s=r.sideCar,o=Fp(r,["sideCar"]);if(!s)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var a=s.read();if(!a)throw new Error("Sidecar medium not found");return g.createElement(a,nn({},o))};Ip.isSideCarExport=!0;function ux(r,s){return r.useMedium(s),Ip}var Up=ax(),xu=function(){},hl=g.forwardRef(function(r,s){var o=g.useRef(null),a=g.useState({onScrollCapture:xu,onWheelCapture:xu,onTouchMoveCapture:xu}),u=a[0],f=a[1],m=r.forwardProps,h=r.children,y=r.className,k=r.removeScrollBar,w=r.enabled,x=r.shards,P=r.sideCar,_=r.noRelative,D=r.noIsolation,b=r.inert,R=r.allowPinchZoom,A=r.as,I=A===void 0?"div":A,V=r.gapMode,z=Fp(r,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),K=P,G=ix([o,s]),ue=nn(nn({},z),u);return g.createElement(g.Fragment,null,w&&g.createElement(K,{sideCar:Up,removeScrollBar:k,shards:x,noRelative:_,noIsolation:D,inert:b,setCallbacks:f,allowPinchZoom:!!R,lockRef:o,gapMode:V}),m?g.cloneElement(g.Children.only(h),nn(nn({},ue),{ref:G})):g.createElement(I,nn({},ue,{className:y,ref:G}),h))});hl.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};hl.classNames={fullWidth:sl,zeroRight:rl};var cx=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function dx(){if(!document)return null;var r=document.createElement("style");r.type="text/css";var s=cx();return s&&r.setAttribute("nonce",s),r}function fx(r,s){r.styleSheet?r.styleSheet.cssText=s:r.appendChild(document.createTextNode(s))}function hx(r){var s=document.head||document.getElementsByTagName("head")[0];s.appendChild(r)}var px=function(){var r=0,s=null;return{add:function(o){r==0&&(s=dx())&&(fx(s,o),hx(s)),r++},remove:function(){r--,!r&&s&&(s.parentNode&&s.parentNode.removeChild(s),s=null)}}},mx=function(){var r=px();return function(s,o){g.useEffect(function(){return r.add(s),function(){r.remove()}},[s&&o])}},$p=function(){var r=mx(),s=function(o){var a=o.styles,u=o.dynamic;return r(a,u),null};return s},gx={left:0,top:0,right:0,gap:0},wu=function(r){return parseInt(r||"",10)||0},vx=function(r){var s=window.getComputedStyle(document.body),o=s[r==="padding"?"paddingLeft":"marginLeft"],a=s[r==="padding"?"paddingTop":"marginTop"],u=s[r==="padding"?"paddingRight":"marginRight"];return[wu(o),wu(a),wu(u)]},yx=function(r){if(r===void 0&&(r="margin"),typeof window>"u")return gx;var s=vx(r),o=document.documentElement.clientWidth,a=window.innerWidth;return{left:s[0],top:s[1],right:s[2],gap:Math.max(0,a-o+s[2]-s[0])}},xx=$p(),os="data-scroll-locked",wx=function(r,s,o,a){var u=r.left,f=r.top,m=r.right,h=r.gap;return o===void 0&&(o="margin"),`
|
||
.`.concat(tx,` {
|
||
overflow: hidden `).concat(a,`;
|
||
padding-right: `).concat(h,"px ").concat(a,`;
|
||
}
|
||
body[`).concat(os,`] {
|
||
overflow: hidden `).concat(a,`;
|
||
overscroll-behavior: contain;
|
||
`).concat([s&&"position: relative ".concat(a,";"),o==="margin"&&`
|
||
padding-left: `.concat(u,`px;
|
||
padding-top: `).concat(f,`px;
|
||
padding-right: `).concat(m,`px;
|
||
margin-left:0;
|
||
margin-top:0;
|
||
margin-right: `).concat(h,"px ").concat(a,`;
|
||
`),o==="padding"&&"padding-right: ".concat(h,"px ").concat(a,";")].filter(Boolean).join(""),`
|
||
}
|
||
|
||
.`).concat(rl,` {
|
||
right: `).concat(h,"px ").concat(a,`;
|
||
}
|
||
|
||
.`).concat(sl,` {
|
||
margin-right: `).concat(h,"px ").concat(a,`;
|
||
}
|
||
|
||
.`).concat(rl," .").concat(rl,` {
|
||
right: 0 `).concat(a,`;
|
||
}
|
||
|
||
.`).concat(sl," .").concat(sl,` {
|
||
margin-right: 0 `).concat(a,`;
|
||
}
|
||
|
||
body[`).concat(os,`] {
|
||
`).concat(nx,": ").concat(h,`px;
|
||
}
|
||
`)},$h=function(){var r=parseInt(document.body.getAttribute(os)||"0",10);return isFinite(r)?r:0},kx=function(){g.useEffect(function(){return document.body.setAttribute(os,($h()+1).toString()),function(){var r=$h()-1;r<=0?document.body.removeAttribute(os):document.body.setAttribute(os,r.toString())}},[])},bx=function(r){var s=r.noRelative,o=r.noImportant,a=r.gapMode,u=a===void 0?"margin":a;kx();var f=g.useMemo(function(){return yx(u)},[u]);return g.createElement(xx,{styles:wx(f,!s,u,o?"":"!important")})},Vu=!1;if(typeof window<"u")try{var Jo=Object.defineProperty({},"passive",{get:function(){return Vu=!0,!0}});window.addEventListener("test",Jo,Jo),window.removeEventListener("test",Jo,Jo)}catch{Vu=!1}var Yr=Vu?{passive:!1}:!1,Sx=function(r){return r.tagName==="TEXTAREA"},Bp=function(r,s){if(!(r instanceof Element))return!1;var o=window.getComputedStyle(r);return o[s]!=="hidden"&&!(o.overflowY===o.overflowX&&!Sx(r)&&o[s]==="visible")},Ex=function(r){return Bp(r,"overflowY")},Nx=function(r){return Bp(r,"overflowX")},Bh=function(r,s){var o=s.ownerDocument,a=s;do{typeof ShadowRoot<"u"&&a instanceof ShadowRoot&&(a=a.host);var u=Vp(r,a);if(u){var f=Hp(r,a),m=f[1],h=f[2];if(m>h)return!0}a=a.parentNode}while(a&&a!==o.body);return!1},jx=function(r){var s=r.scrollTop,o=r.scrollHeight,a=r.clientHeight;return[s,o,a]},Cx=function(r){var s=r.scrollLeft,o=r.scrollWidth,a=r.clientWidth;return[s,o,a]},Vp=function(r,s){return r==="v"?Ex(s):Nx(s)},Hp=function(r,s){return r==="v"?jx(s):Cx(s)},_x=function(r,s){return r==="h"&&s==="rtl"?-1:1},Px=function(r,s,o,a,u){var f=_x(r,window.getComputedStyle(s).direction),m=f*a,h=o.target,y=s.contains(h),k=!1,w=m>0,x=0,P=0;do{if(!h)break;var _=Hp(r,h),D=_[0],b=_[1],R=_[2],A=b-R-f*D;(D||A)&&Vp(r,h)&&(x+=A,P+=D);var I=h.parentNode;h=I&&I.nodeType===Node.DOCUMENT_FRAGMENT_NODE?I.host:I}while(!y&&h!==document.body||y&&(s.contains(h)||s===h));return(w&&Math.abs(x)<1||!w&&Math.abs(P)<1)&&(k=!0),k},el=function(r){return"changedTouches"in r?[r.changedTouches[0].clientX,r.changedTouches[0].clientY]:[0,0]},Vh=function(r){return[r.deltaX,r.deltaY]},Hh=function(r){return r&&"current"in r?r.current:r},Rx=function(r,s){return r[0]===s[0]&&r[1]===s[1]},Mx=function(r){return`
|
||
.block-interactivity-`.concat(r,` {pointer-events: none;}
|
||
.allow-interactivity-`).concat(r,` {pointer-events: all;}
|
||
`)},Ox=0,Xr=[];function Tx(r){var s=g.useRef([]),o=g.useRef([0,0]),a=g.useRef(),u=g.useState(Ox++)[0],f=g.useState($p)[0],m=g.useRef(r);g.useEffect(function(){m.current=r},[r]),g.useEffect(function(){if(r.inert){document.body.classList.add("block-interactivity-".concat(u));var b=ex([r.lockRef.current],(r.shards||[]).map(Hh),!0).filter(Boolean);return b.forEach(function(R){return R.classList.add("allow-interactivity-".concat(u))}),function(){document.body.classList.remove("block-interactivity-".concat(u)),b.forEach(function(R){return R.classList.remove("allow-interactivity-".concat(u))})}}},[r.inert,r.lockRef.current,r.shards]);var h=g.useCallback(function(b,R){if("touches"in b&&b.touches.length===2||b.type==="wheel"&&b.ctrlKey)return!m.current.allowPinchZoom;var A=el(b),I=o.current,V="deltaX"in b?b.deltaX:I[0]-A[0],z="deltaY"in b?b.deltaY:I[1]-A[1],K,G=b.target,ue=Math.abs(V)>Math.abs(z)?"h":"v";if("touches"in b&&ue==="h"&&G.type==="range")return!1;var oe=window.getSelection(),ee=oe&&oe.anchorNode,me=ee?ee===G||ee.contains(G):!1;if(me)return!1;var ke=Bh(ue,G);if(!ke)return!0;if(ke?K=ue:(K=ue==="v"?"h":"v",ke=Bh(ue,G)),!ke)return!1;if(!a.current&&"changedTouches"in b&&(V||z)&&(a.current=K),!K)return!0;var le=a.current||K;return Px(le,R,b,le==="h"?V:z)},[]),y=g.useCallback(function(b){var R=b;if(!(!Xr.length||Xr[Xr.length-1]!==f)){var A="deltaY"in R?Vh(R):el(R),I=s.current.filter(function(K){return K.name===R.type&&(K.target===R.target||R.target===K.shadowParent)&&Rx(K.delta,A)})[0];if(I&&I.should){R.cancelable&&R.preventDefault();return}if(!I){var V=(m.current.shards||[]).map(Hh).filter(Boolean).filter(function(K){return K.contains(R.target)}),z=V.length>0?h(R,V[0]):!m.current.noIsolation;z&&R.cancelable&&R.preventDefault()}}},[]),k=g.useCallback(function(b,R,A,I){var V={name:b,delta:R,target:A,should:I,shadowParent:Lx(A)};s.current.push(V),setTimeout(function(){s.current=s.current.filter(function(z){return z!==V})},1)},[]),w=g.useCallback(function(b){o.current=el(b),a.current=void 0},[]),x=g.useCallback(function(b){k(b.type,Vh(b),b.target,h(b,r.lockRef.current))},[]),P=g.useCallback(function(b){k(b.type,el(b),b.target,h(b,r.lockRef.current))},[]);g.useEffect(function(){return Xr.push(f),r.setCallbacks({onScrollCapture:x,onWheelCapture:x,onTouchMoveCapture:P}),document.addEventListener("wheel",y,Yr),document.addEventListener("touchmove",y,Yr),document.addEventListener("touchstart",w,Yr),function(){Xr=Xr.filter(function(b){return b!==f}),document.removeEventListener("wheel",y,Yr),document.removeEventListener("touchmove",y,Yr),document.removeEventListener("touchstart",w,Yr)}},[]);var _=r.removeScrollBar,D=r.inert;return g.createElement(g.Fragment,null,D?g.createElement(f,{styles:Mx(u)}):null,_?g.createElement(bx,{noRelative:r.noRelative,gapMode:r.gapMode}):null)}function Lx(r){for(var s=null;r!==null;)r instanceof ShadowRoot&&(s=r.host,r=r.host),r=r.parentNode;return s}const Dx=ux(Up,Tx);var Wp=g.forwardRef(function(r,s){return g.createElement(hl,nn({},r,{ref:s,sideCar:Dx}))});Wp.classNames=hl.classNames;var Ax=function(r){if(typeof document>"u")return null;var s=Array.isArray(r)?r[0]:r;return s.ownerDocument.body},Jr=new WeakMap,tl=new WeakMap,nl={},ku=0,Qp=function(r){return r&&(r.host||Qp(r.parentNode))},zx=function(r,s){return s.map(function(o){if(r.contains(o))return o;var a=Qp(o);return a&&r.contains(a)?a:(console.error("aria-hidden",o,"in not contained inside",r,". Doing nothing"),null)}).filter(function(o){return!!o})},Fx=function(r,s,o,a){var u=zx(s,Array.isArray(r)?r:[r]);nl[o]||(nl[o]=new WeakMap);var f=nl[o],m=[],h=new Set,y=new Set(u),k=function(x){!x||h.has(x)||(h.add(x),k(x.parentNode))};u.forEach(k);var w=function(x){!x||y.has(x)||Array.prototype.forEach.call(x.children,function(P){if(h.has(P))w(P);else try{var _=P.getAttribute(a),D=_!==null&&_!=="false",b=(Jr.get(P)||0)+1,R=(f.get(P)||0)+1;Jr.set(P,b),f.set(P,R),m.push(P),b===1&&D&&tl.set(P,!0),R===1&&P.setAttribute(o,"true"),D||P.setAttribute(a,"true")}catch(A){console.error("aria-hidden: cannot operate on ",P,A)}})};return w(s),h.clear(),ku++,function(){m.forEach(function(x){var P=Jr.get(x)-1,_=f.get(x)-1;Jr.set(x,P),f.set(x,_),P||(tl.has(x)||x.removeAttribute(a),tl.delete(x)),_||x.removeAttribute(o)}),ku--,ku||(Jr=new WeakMap,Jr=new WeakMap,tl=new WeakMap,nl={})}},Ix=function(r,s,o){o===void 0&&(o="data-aria-hidden");var a=Array.from(Array.isArray(r)?r:[r]),u=Ax(r);return u?(a.push.apply(a,Array.from(u.querySelectorAll("[aria-live], script"))),Fx(a,u,o,"aria-hidden")):function(){return null}},pl="Dialog",[Kp]=h0(pl),[Ux,Qt]=Kp(pl),qp=r=>{const{__scopeDialog:s,children:o,open:a,defaultOpen:u,onOpenChange:f,modal:m=!0}=r,h=g.useRef(null),y=g.useRef(null),[k,w]=y0({prop:a,defaultProp:u??!1,onChange:f,caller:pl});return d.jsx(Ux,{scope:s,triggerRef:h,contentRef:y,contentId:vn(),titleId:vn(),descriptionId:vn(),open:k,onOpenChange:w,onOpenToggle:g.useCallback(()=>w(x=>!x),[w]),modal:m,children:o})};qp.displayName=pl;var Gp="DialogTrigger",$x=g.forwardRef((r,s)=>{const{__scopeDialog:o,...a}=r,u=Qt(Gp,o),f=br(s,u.triggerRef);return d.jsx(ot.button,{type:"button","aria-haspopup":"dialog","aria-expanded":u.open,"aria-controls":u.open?u.contentId:void 0,"data-state":cc(u.open),...a,ref:f,onClick:Zn(r.onClick,u.onOpenToggle)})});$x.displayName=Gp;var uc="DialogPortal",[Bx,Zp]=Kp(uc,{forceMount:void 0}),Yp=r=>{const{__scopeDialog:s,forceMount:o,children:a,container:u}=r,f=Qt(uc,s);return d.jsx(Bx,{scope:s,forceMount:o,children:g.Children.map(a,m=>d.jsx(fl,{present:o||f.open,children:d.jsx(zp,{asChild:!0,container:u,children:m})}))})};Yp.displayName=uc;var ll="DialogOverlay",Xp=g.forwardRef((r,s)=>{const o=Zp(ll,r.__scopeDialog),{forceMount:a=o.forceMount,...u}=r,f=Qt(ll,r.__scopeDialog);return f.modal?d.jsx(fl,{present:a||f.open,children:d.jsx(Hx,{...u,ref:s})}):null});Xp.displayName=ll;var Vx=Op("DialogOverlay.RemoveScroll"),Hx=g.forwardRef((r,s)=>{const{__scopeDialog:o,...a}=r,u=Qt(ll,o),f=F0(),m=br(s,f);return d.jsx(Wp,{as:Vx,allowPinchZoom:!0,shards:[u.contentRef],children:d.jsx(ot.div,{"data-state":cc(u.open),...a,ref:m,style:{pointerEvents:"auto",...a.style}})})}),bs="DialogContent",Jp=g.forwardRef((r,s)=>{const o=Zp(bs,r.__scopeDialog),{forceMount:a=o.forceMount,...u}=r,f=Qt(bs,r.__scopeDialog);return d.jsx(fl,{present:a||f.open,children:f.modal?d.jsx(Wx,{...u,ref:s}):d.jsx(Qx,{...u,ref:s})})});Jp.displayName=bs;var Wx=g.forwardRef((r,s)=>{const o=Qt(bs,r.__scopeDialog),a=g.useRef(null),u=br(s,o.contentRef,a);return g.useEffect(()=>{const f=a.current;if(f)return Ix(f)},[]),d.jsx(em,{...r,ref:u,trapFocus:o.open,disableOutsidePointerEvents:o.open,onCloseAutoFocus:Zn(r.onCloseAutoFocus,f=>{var m;f.preventDefault(),(m=o.triggerRef.current)==null||m.focus()}),onPointerDownOutside:Zn(r.onPointerDownOutside,f=>{const m=f.detail.originalEvent,h=m.button===0&&m.ctrlKey===!0;(m.button===2||h)&&f.preventDefault()}),onFocusOutside:Zn(r.onFocusOutside,f=>f.preventDefault())})}),Qx=g.forwardRef((r,s)=>{const o=Qt(bs,r.__scopeDialog),a=g.useRef(!1),u=g.useRef(!1);return d.jsx(em,{...r,ref:s,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:f=>{var m,h;(m=r.onCloseAutoFocus)==null||m.call(r,f),f.defaultPrevented||(a.current||(h=o.triggerRef.current)==null||h.focus(),f.preventDefault()),a.current=!1,u.current=!1},onInteractOutside:f=>{var y,k;(y=r.onInteractOutside)==null||y.call(r,f),f.defaultPrevented||(a.current=!0,f.detail.originalEvent.type==="pointerdown"&&(u.current=!0));const m=f.target;((k=o.triggerRef.current)==null?void 0:k.contains(m))&&f.preventDefault(),f.detail.originalEvent.type==="focusin"&&u.current&&f.preventDefault()}})}),em=g.forwardRef((r,s)=>{const{__scopeDialog:o,trapFocus:a,onOpenAutoFocus:u,onCloseAutoFocus:f,...m}=r,h=Qt(bs,o);return J0(),d.jsx(d.Fragment,{children:d.jsx(Dp,{asChild:!0,loop:!0,trapped:a,onMountAutoFocus:u,onUnmountAutoFocus:f,children:d.jsx(Tp,{role:"dialog",id:h.contentId,"aria-describedby":h.descriptionId,"aria-labelledby":h.titleId,"data-state":cc(h.open),...m,ref:s,deferPointerDownOutside:!0,onDismiss:()=>h.onOpenChange(!1)})})})}),tm="DialogTitle",Kx=g.forwardRef((r,s)=>{const{__scopeDialog:o,...a}=r,u=Qt(tm,o);return d.jsx(ot.h2,{id:u.titleId,...a,ref:s})});Kx.displayName=tm;var nm="DialogDescription",qx=g.forwardRef((r,s)=>{const{__scopeDialog:o,...a}=r,u=Qt(nm,o);return d.jsx(ot.p,{id:u.descriptionId,...a,ref:s})});qx.displayName=nm;var rm="DialogClose",Gx=g.forwardRef((r,s)=>{const{__scopeDialog:o,...a}=r,u=Qt(rm,o);return d.jsx(ot.button,{type:"button",...a,ref:s,onClick:Zn(r.onClick,()=>u.onOpenChange(!1))})});Gx.displayName=rm;function cc(r){return r?"open":"closed"}var hi='[cmdk-group=""]',bu='[cmdk-group-items=""]',Zx='[cmdk-group-heading=""]',sm='[cmdk-item=""]',Wh=`${sm}:not([aria-disabled="true"])`,Hu="cmdk-item-select",ns="data-value",Yx=(r,s,o)=>f0(r,s,o),im=g.createContext(void 0),Ai=()=>g.useContext(im),om=g.createContext(void 0),dc=()=>g.useContext(om),lm=g.createContext(void 0),am=g.forwardRef((r,s)=>{let o=rs(()=>{var N,q;return{search:"",value:(q=(N=r.value)!=null?N:r.defaultValue)!=null?q:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),a=rs(()=>new Set),u=rs(()=>new Map),f=rs(()=>new Map),m=rs(()=>new Set),h=um(r),{label:y,children:k,value:w,onValueChange:x,filter:P,shouldFilter:_,loop:D,disablePointerSelection:b=!1,vimBindings:R=!0,...A}=r,I=vn(),V=vn(),z=vn(),K=g.useRef(null),G=a1();kr(()=>{if(w!==void 0){let N=w.trim();o.current.value=N,ue.emit()}},[w]),kr(()=>{G(6,Le)},[]);let ue=g.useMemo(()=>({subscribe:N=>(m.current.add(N),()=>m.current.delete(N)),snapshot:()=>o.current,setState:(N,q,Y)=>{var W,se,de,ye;if(!Object.is(o.current[N],q)){if(o.current[N]=q,N==="search")le(),me(),G(1,ke);else if(N==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let we=document.getElementById(z);we?we.focus():(W=document.getElementById(I))==null||W.focus()}if(G(7,()=>{var we;o.current.selectedItemId=(we=Z())==null?void 0:we.id,ue.emit()}),Y||G(5,Le),((se=h.current)==null?void 0:se.value)!==void 0){let we=q??"";(ye=(de=h.current).onValueChange)==null||ye.call(de,we);return}}ue.emit()}},emit:()=>{m.current.forEach(N=>N())}}),[]),oe=g.useMemo(()=>({value:(N,q,Y)=>{var W;q!==((W=f.current.get(N))==null?void 0:W.value)&&(f.current.set(N,{value:q,keywords:Y}),o.current.filtered.items.set(N,ee(q,Y)),G(2,()=>{me(),ue.emit()}))},item:(N,q)=>(a.current.add(N),q&&(u.current.has(q)?u.current.get(q).add(N):u.current.set(q,new Set([N]))),G(3,()=>{le(),me(),o.current.value||ke(),ue.emit()}),()=>{f.current.delete(N),a.current.delete(N),o.current.filtered.items.delete(N);let Y=Z();G(4,()=>{le(),(Y==null?void 0:Y.getAttribute("id"))===N&&ke(),ue.emit()})}),group:N=>(u.current.has(N)||u.current.set(N,new Set),()=>{f.current.delete(N),u.current.delete(N)}),filter:()=>h.current.shouldFilter,label:y||r["aria-label"],getDisablePointerSelection:()=>h.current.disablePointerSelection,listId:I,inputId:z,labelId:V,listInnerRef:K}),[]);function ee(N,q){var Y,W;let se=(W=(Y=h.current)==null?void 0:Y.filter)!=null?W:Yx;return N?se(N,o.current.search,q):0}function me(){if(!o.current.search||h.current.shouldFilter===!1)return;let N=o.current.filtered.items,q=[];o.current.filtered.groups.forEach(W=>{let se=u.current.get(W),de=0;se.forEach(ye=>{let we=N.get(ye);de=Math.max(we,de)}),q.push([W,de])});let Y=K.current;ce().sort((W,se)=>{var de,ye;let we=W.getAttribute("id"),Ge=se.getAttribute("id");return((de=N.get(Ge))!=null?de:0)-((ye=N.get(we))!=null?ye:0)}).forEach(W=>{let se=W.closest(bu);se?se.appendChild(W.parentElement===se?W:W.closest(`${bu} > *`)):Y.appendChild(W.parentElement===Y?W:W.closest(`${bu} > *`))}),q.sort((W,se)=>se[1]-W[1]).forEach(W=>{var se;let de=(se=K.current)==null?void 0:se.querySelector(`${hi}[${ns}="${encodeURIComponent(W[0])}"]`);de==null||de.parentElement.appendChild(de)})}function ke(){let N=ce().find(Y=>Y.getAttribute("aria-disabled")!=="true"),q=N==null?void 0:N.getAttribute(ns);ue.setState("value",q||void 0)}function le(){var N,q,Y,W;if(!o.current.search||h.current.shouldFilter===!1){o.current.filtered.count=a.current.size;return}o.current.filtered.groups=new Set;let se=0;for(let de of a.current){let ye=(q=(N=f.current.get(de))==null?void 0:N.value)!=null?q:"",we=(W=(Y=f.current.get(de))==null?void 0:Y.keywords)!=null?W:[],Ge=ee(ye,we);o.current.filtered.items.set(de,Ge),Ge>0&&se++}for(let[de,ye]of u.current)for(let we of ye)if(o.current.filtered.items.get(we)>0){o.current.filtered.groups.add(de);break}o.current.filtered.count=se}function Le(){var N,q,Y;let W=Z();W&&(((N=W.parentElement)==null?void 0:N.firstChild)===W&&((Y=(q=W.closest(hi))==null?void 0:q.querySelector(Zx))==null||Y.scrollIntoView({block:"nearest"})),W.scrollIntoView({block:"nearest"}))}function Z(){var N;return(N=K.current)==null?void 0:N.querySelector(`${sm}[aria-selected="true"]`)}function ce(){var N;return Array.from(((N=K.current)==null?void 0:N.querySelectorAll(Wh))||[])}function Ce(N){let q=ce()[N];q&&ue.setState("value",q.getAttribute(ns))}function Ne(N){var q;let Y=Z(),W=ce(),se=W.findIndex(ye=>ye===Y),de=W[se+N];(q=h.current)!=null&&q.loop&&(de=se+N<0?W[W.length-1]:se+N===W.length?W[0]:W[se+N]),de&&ue.setState("value",de.getAttribute(ns))}function F(N){let q=Z(),Y=q==null?void 0:q.closest(hi),W;for(;Y&&!W;)Y=N>0?o1(Y,hi):l1(Y,hi),W=Y==null?void 0:Y.querySelector(Wh);W?ue.setState("value",W.getAttribute(ns)):Ne(N)}let ne=()=>Ce(ce().length-1),Q=N=>{N.preventDefault(),N.metaKey?ne():N.altKey?F(1):Ne(1)},C=N=>{N.preventDefault(),N.metaKey?Ce(0):N.altKey?F(-1):Ne(-1)};return g.createElement(ot.div,{ref:s,tabIndex:-1,...A,"cmdk-root":"",onKeyDown:N=>{var q;(q=A.onKeyDown)==null||q.call(A,N);let Y=N.nativeEvent.isComposing||N.keyCode===229;if(!(N.defaultPrevented||Y))switch(N.key){case"n":case"j":{R&&N.ctrlKey&&Q(N);break}case"ArrowDown":{Q(N);break}case"p":case"k":{R&&N.ctrlKey&&C(N);break}case"ArrowUp":{C(N);break}case"Home":{N.preventDefault(),Ce(0);break}case"End":{N.preventDefault(),ne();break}case"Enter":{N.preventDefault();let W=Z();if(W){let se=new Event(Hu);W.dispatchEvent(se)}}}}},g.createElement("label",{"cmdk-label":"",htmlFor:oe.inputId,id:oe.labelId,style:c1},y),ml(r,N=>g.createElement(om.Provider,{value:ue},g.createElement(im.Provider,{value:oe},N))))}),Xx=g.forwardRef((r,s)=>{var o,a;let u=vn(),f=g.useRef(null),m=g.useContext(lm),h=Ai(),y=um(r),k=(a=(o=y.current)==null?void 0:o.forceMount)!=null?a:m==null?void 0:m.forceMount;kr(()=>{if(!k)return h.item(u,m==null?void 0:m.id)},[k]);let w=cm(u,f,[r.value,r.children,f],r.keywords),x=dc(),P=Yn(G=>G.value&&G.value===w.current),_=Yn(G=>k||h.filter()===!1?!0:G.search?G.filtered.items.get(u)>0:!0);g.useEffect(()=>{let G=f.current;if(!(!G||r.disabled))return G.addEventListener(Hu,D),()=>G.removeEventListener(Hu,D)},[_,r.onSelect,r.disabled]);function D(){var G,ue;b(),(ue=(G=y.current).onSelect)==null||ue.call(G,w.current)}function b(){x.setState("value",w.current,!0)}if(!_)return null;let{disabled:R,value:A,onSelect:I,forceMount:V,keywords:z,...K}=r;return g.createElement(ot.div,{ref:ks(f,s),...K,id:u,"cmdk-item":"",role:"option","aria-disabled":!!R,"aria-selected":!!P,"data-disabled":!!R,"data-selected":!!P,onPointerMove:R||h.getDisablePointerSelection()?void 0:b,onClick:R?void 0:D},r.children)}),Jx=g.forwardRef((r,s)=>{let{heading:o,children:a,forceMount:u,...f}=r,m=vn(),h=g.useRef(null),y=g.useRef(null),k=vn(),w=Ai(),x=Yn(_=>u||w.filter()===!1?!0:_.search?_.filtered.groups.has(m):!0);kr(()=>w.group(m),[]),cm(m,h,[r.value,r.heading,y]);let P=g.useMemo(()=>({id:m,forceMount:u}),[u]);return g.createElement(ot.div,{ref:ks(h,s),...f,"cmdk-group":"",role:"presentation",hidden:x?void 0:!0},o&&g.createElement("div",{ref:y,"cmdk-group-heading":"","aria-hidden":!0,id:k},o),ml(r,_=>g.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":o?k:void 0},g.createElement(lm.Provider,{value:P},_))))}),e1=g.forwardRef((r,s)=>{let{alwaysRender:o,...a}=r,u=g.useRef(null),f=Yn(m=>!m.search);return!o&&!f?null:g.createElement(ot.div,{ref:ks(u,s),...a,"cmdk-separator":"",role:"separator"})}),t1=g.forwardRef((r,s)=>{let{onValueChange:o,...a}=r,u=r.value!=null,f=dc(),m=Yn(k=>k.search),h=Yn(k=>k.selectedItemId),y=Ai();return g.useEffect(()=>{r.value!=null&&f.setState("search",r.value)},[r.value]),g.createElement(ot.input,{ref:s,...a,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":y.listId,"aria-labelledby":y.labelId,"aria-activedescendant":h,id:y.inputId,type:"text",value:u?r.value:m,onChange:k=>{u||f.setState("search",k.target.value),o==null||o(k.target.value)}})}),n1=g.forwardRef((r,s)=>{let{children:o,label:a="Suggestions",...u}=r,f=g.useRef(null),m=g.useRef(null),h=Yn(k=>k.selectedItemId),y=Ai();return g.useEffect(()=>{if(m.current&&f.current){let k=m.current,w=f.current,x,P=new ResizeObserver(()=>{x=requestAnimationFrame(()=>{let _=k.offsetHeight;w.style.setProperty("--cmdk-list-height",_.toFixed(1)+"px")})});return P.observe(k),()=>{cancelAnimationFrame(x),P.unobserve(k)}}},[]),g.createElement(ot.div,{ref:ks(f,s),...u,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":h,"aria-label":a,id:y.listId},ml(r,k=>g.createElement("div",{ref:ks(m,y.listInnerRef),"cmdk-list-sizer":""},k)))}),r1=g.forwardRef((r,s)=>{let{open:o,onOpenChange:a,overlayClassName:u,contentClassName:f,container:m,...h}=r;return g.createElement(qp,{open:o,onOpenChange:a},g.createElement(Yp,{container:m},g.createElement(Xp,{"cmdk-overlay":"",className:u}),g.createElement(Jp,{"aria-label":r.label,"cmdk-dialog":"",className:f},g.createElement(am,{ref:s,...h}))))}),s1=g.forwardRef((r,s)=>Yn(o=>o.filtered.count===0)?g.createElement(ot.div,{ref:s,...r,"cmdk-empty":"",role:"presentation"}):null),i1=g.forwardRef((r,s)=>{let{progress:o,children:a,label:u="Loading...",...f}=r;return g.createElement(ot.div,{ref:s,...f,"cmdk-loading":"",role:"progressbar","aria-valuenow":o,"aria-valuemin":0,"aria-valuemax":100,"aria-label":u},ml(r,m=>g.createElement("div",{"aria-hidden":!0},m)))}),es=Object.assign(am,{List:n1,Item:Xx,Input:t1,Group:Jx,Separator:e1,Dialog:r1,Empty:s1,Loading:i1});function o1(r,s){let o=r.nextElementSibling;for(;o;){if(o.matches(s))return o;o=o.nextElementSibling}}function l1(r,s){let o=r.previousElementSibling;for(;o;){if(o.matches(s))return o;o=o.previousElementSibling}}function um(r){let s=g.useRef(r);return kr(()=>{s.current=r}),s}var kr=typeof window>"u"?g.useEffect:g.useLayoutEffect;function rs(r){let s=g.useRef();return s.current===void 0&&(s.current=r()),s}function Yn(r){let s=dc(),o=()=>r(s.snapshot());return g.useSyncExternalStore(s.subscribe,o,o)}function cm(r,s,o,a=[]){let u=g.useRef(),f=Ai();return kr(()=>{var m;let h=(()=>{var k;for(let w of o){if(typeof w=="string")return w.trim();if(typeof w=="object"&&"current"in w)return w.current?(k=w.current.textContent)==null?void 0:k.trim():u.current}})(),y=a.map(k=>k.trim());f.value(r,h,y),(m=s.current)==null||m.setAttribute(ns,h),u.current=h}),u}var a1=()=>{let[r,s]=g.useState(),o=rs(()=>new Map);return kr(()=>{o.current.forEach(a=>a()),o.current=new Map},[r]),(a,u)=>{o.current.set(a,u),s({})}};function u1(r){let s=r.type;return typeof s=="function"?s(r.props):"render"in s?s.render(r.props):r}function ml({asChild:r,children:s},o){return r&&g.isValidElement(s)?g.cloneElement(u1(s),{ref:s.ref},o(s.props.children)):o(s)}var c1={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function d1({onNavigate:r}){const[s,o]=g.useState(!1);return g.useEffect(()=>{const a=u=>{(u.metaKey||u.ctrlKey)&&u.key.toLowerCase()==="k"&&(u.preventDefault(),o(f=>!f))};return document.addEventListener("keydown",a),()=>document.removeEventListener("keydown",a)},[]),d.jsx(es.Dialog,{open:s,onOpenChange:o,label:"Befehlspalette",className:"fixed inset-0 z-50 flex items-start justify-center bg-black/50 p-4 pt-[12vh] overscroll-contain",onClick:()=>o(!1),children:d.jsxs("div",{className:"w-full max-w-lg overflow-hidden rounded-xl border border-border bg-popover text-popover-foreground shadow-2xl",onClick:a=>a.stopPropagation(),children:[d.jsx(es.Input,{autoFocus:!0,placeholder:"Springe zu… (Modelle, Routing, System …)",className:"w-full border-b border-border bg-transparent px-4 py-3 text-sm outline-none placeholder:text-muted-foreground"}),d.jsxs(es.List,{className:"max-h-80 overflow-y-auto p-2",children:[d.jsx(es.Empty,{className:"px-3 py-6 text-center text-sm text-muted-foreground",children:"Nichts gefunden."}),d.jsx(es.Group,{heading:"Bereiche",className:"px-1 py-1 text-xs text-muted-foreground",children:is.map(a=>d.jsxs(es.Item,{value:`${a.label} ${a.hint}`,onSelect:()=>{r(a.id),o(!1)},className:"flex cursor-pointer items-center gap-3 rounded-md px-3 py-2 text-sm text-foreground aria-selected:bg-accent aria-selected:text-accent-foreground",children:[d.jsx(a.icon,{className:"h-4 w-4 text-primary"}),d.jsx("span",{children:a.label}),d.jsx("span",{className:"ml-auto truncate text-xs text-muted-foreground",children:a.hint})]},a.id))})]})]})})}const dm="mc_expert_mode",Wu="mc-expert-mode-change",f1=()=>{try{return localStorage.getItem(dm)==="true"}catch{return!1}};function h1(r){return window.addEventListener(Wu,r),window.addEventListener("storage",r),()=>{window.removeEventListener(Wu,r),window.removeEventListener("storage",r)}}function Qh(r){localStorage.setItem(dm,String(r)),window.dispatchEvent(new Event(Wu))}function p1(){return g.useSyncExternalStore(h1,f1,()=>!1)}function fm(r){var s,o,a="";if(typeof r=="string"||typeof r=="number")a+=r;else if(typeof r=="object")if(Array.isArray(r)){var u=r.length;for(s=0;s<u;s++)r[s]&&(o=fm(r[s]))&&(a&&(a+=" "),a+=o)}else for(o in r)r[o]&&(a&&(a+=" "),a+=o);return a}function m1(){for(var r,s,o=0,a="",u=arguments.length;o<u;o++)(r=arguments[o])&&(s=fm(r))&&(a&&(a+=" "),a+=s);return a}const fc="-",g1=r=>{const s=y1(r),{conflictingClassGroups:o,conflictingClassGroupModifiers:a}=r;return{getClassGroupId:m=>{const h=m.split(fc);return h[0]===""&&h.length!==1&&h.shift(),hm(h,s)||v1(m)},getConflictingClassGroupIds:(m,h)=>{const y=o[m]||[];return h&&a[m]?[...y,...a[m]]:y}}},hm=(r,s)=>{var m;if(r.length===0)return s.classGroupId;const o=r[0],a=s.nextPart.get(o),u=a?hm(r.slice(1),a):void 0;if(u)return u;if(s.validators.length===0)return;const f=r.join(fc);return(m=s.validators.find(({validator:h})=>h(f)))==null?void 0:m.classGroupId},Kh=/^\[(.+)\]$/,v1=r=>{if(Kh.test(r)){const s=Kh.exec(r)[1],o=s==null?void 0:s.substring(0,s.indexOf(":"));if(o)return"arbitrary.."+o}},y1=r=>{const{theme:s,prefix:o}=r,a={nextPart:new Map,validators:[]};return w1(Object.entries(r.classGroups),o).forEach(([f,m])=>{Qu(m,a,f,s)}),a},Qu=(r,s,o,a)=>{r.forEach(u=>{if(typeof u=="string"){const f=u===""?s:qh(s,u);f.classGroupId=o;return}if(typeof u=="function"){if(x1(u)){Qu(u(a),s,o,a);return}s.validators.push({validator:u,classGroupId:o});return}Object.entries(u).forEach(([f,m])=>{Qu(m,qh(s,f),o,a)})})},qh=(r,s)=>{let o=r;return s.split(fc).forEach(a=>{o.nextPart.has(a)||o.nextPart.set(a,{nextPart:new Map,validators:[]}),o=o.nextPart.get(a)}),o},x1=r=>r.isThemeGetter,w1=(r,s)=>s?r.map(([o,a])=>{const u=a.map(f=>typeof f=="string"?s+f:typeof f=="object"?Object.fromEntries(Object.entries(f).map(([m,h])=>[s+m,h])):f);return[o,u]}):r,k1=r=>{if(r<1)return{get:()=>{},set:()=>{}};let s=0,o=new Map,a=new Map;const u=(f,m)=>{o.set(f,m),s++,s>r&&(s=0,a=o,o=new Map)};return{get(f){let m=o.get(f);if(m!==void 0)return m;if((m=a.get(f))!==void 0)return u(f,m),m},set(f,m){o.has(f)?o.set(f,m):u(f,m)}}},pm="!",b1=r=>{const{separator:s,experimentalParseClassName:o}=r,a=s.length===1,u=s[0],f=s.length,m=h=>{const y=[];let k=0,w=0,x;for(let R=0;R<h.length;R++){let A=h[R];if(k===0){if(A===u&&(a||h.slice(R,R+f)===s)){y.push(h.slice(w,R)),w=R+f;continue}if(A==="/"){x=R;continue}}A==="["?k++:A==="]"&&k--}const P=y.length===0?h:h.substring(w),_=P.startsWith(pm),D=_?P.substring(1):P,b=x&&x>w?x-w:void 0;return{modifiers:y,hasImportantModifier:_,baseClassName:D,maybePostfixModifierPosition:b}};return o?h=>o({className:h,parseClassName:m}):m},S1=r=>{if(r.length<=1)return r;const s=[];let o=[];return r.forEach(a=>{a[0]==="["?(s.push(...o.sort(),a),o=[]):o.push(a)}),s.push(...o.sort()),s},E1=r=>({cache:k1(r.cacheSize),parseClassName:b1(r),...g1(r)}),N1=/\s+/,j1=(r,s)=>{const{parseClassName:o,getClassGroupId:a,getConflictingClassGroupIds:u}=s,f=[],m=r.trim().split(N1);let h="";for(let y=m.length-1;y>=0;y-=1){const k=m[y],{modifiers:w,hasImportantModifier:x,baseClassName:P,maybePostfixModifierPosition:_}=o(k);let D=!!_,b=a(D?P.substring(0,_):P);if(!b){if(!D){h=k+(h.length>0?" "+h:h);continue}if(b=a(P),!b){h=k+(h.length>0?" "+h:h);continue}D=!1}const R=S1(w).join(":"),A=x?R+pm:R,I=A+b;if(f.includes(I))continue;f.push(I);const V=u(b,D);for(let z=0;z<V.length;++z){const K=V[z];f.push(A+K)}h=k+(h.length>0?" "+h:h)}return h};function C1(){let r=0,s,o,a="";for(;r<arguments.length;)(s=arguments[r++])&&(o=mm(s))&&(a&&(a+=" "),a+=o);return a}const mm=r=>{if(typeof r=="string")return r;let s,o="";for(let a=0;a<r.length;a++)r[a]&&(s=mm(r[a]))&&(o&&(o+=" "),o+=s);return o};function _1(r,...s){let o,a,u,f=m;function m(y){const k=s.reduce((w,x)=>x(w),r());return o=E1(k),a=o.cache.get,u=o.cache.set,f=h,h(y)}function h(y){const k=a(y);if(k)return k;const w=j1(y,o);return u(y,w),w}return function(){return f(C1.apply(null,arguments))}}const Ue=r=>{const s=o=>o[r]||[];return s.isThemeGetter=!0,s},gm=/^\[(?:([a-z-]+):)?(.+)\]$/i,P1=/^\d+\/\d+$/,R1=new Set(["px","full","screen"]),M1=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,O1=/\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$/,T1=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,L1=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,D1=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,hn=r=>ls(r)||R1.has(r)||P1.test(r),zn=r=>Es(r,"length",V1),ls=r=>!!r&&!Number.isNaN(Number(r)),Su=r=>Es(r,"number",ls),pi=r=>!!r&&Number.isInteger(Number(r)),A1=r=>r.endsWith("%")&&ls(r.slice(0,-1)),be=r=>gm.test(r),Fn=r=>M1.test(r),z1=new Set(["length","size","percentage"]),F1=r=>Es(r,z1,vm),I1=r=>Es(r,"position",vm),U1=new Set(["image","url"]),$1=r=>Es(r,U1,W1),B1=r=>Es(r,"",H1),mi=()=>!0,Es=(r,s,o)=>{const a=gm.exec(r);return a?a[1]?typeof s=="string"?a[1]===s:s.has(a[1]):o(a[2]):!1},V1=r=>O1.test(r)&&!T1.test(r),vm=()=>!1,H1=r=>L1.test(r),W1=r=>D1.test(r),Q1=()=>{const r=Ue("colors"),s=Ue("spacing"),o=Ue("blur"),a=Ue("brightness"),u=Ue("borderColor"),f=Ue("borderRadius"),m=Ue("borderSpacing"),h=Ue("borderWidth"),y=Ue("contrast"),k=Ue("grayscale"),w=Ue("hueRotate"),x=Ue("invert"),P=Ue("gap"),_=Ue("gradientColorStops"),D=Ue("gradientColorStopPositions"),b=Ue("inset"),R=Ue("margin"),A=Ue("opacity"),I=Ue("padding"),V=Ue("saturate"),z=Ue("scale"),K=Ue("sepia"),G=Ue("skew"),ue=Ue("space"),oe=Ue("translate"),ee=()=>["auto","contain","none"],me=()=>["auto","hidden","clip","visible","scroll"],ke=()=>["auto",be,s],le=()=>[be,s],Le=()=>["",hn,zn],Z=()=>["auto",ls,be],ce=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],Ce=()=>["solid","dashed","dotted","double","none"],Ne=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],F=()=>["start","end","center","between","around","evenly","stretch"],ne=()=>["","0",be],Q=()=>["auto","avoid","all","avoid-page","page","left","right","column"],C=()=>[ls,be];return{cacheSize:500,separator:":",theme:{colors:[mi],spacing:[hn,zn],blur:["none","",Fn,be],brightness:C(),borderColor:[r],borderRadius:["none","","full",Fn,be],borderSpacing:le(),borderWidth:Le(),contrast:C(),grayscale:ne(),hueRotate:C(),invert:ne(),gap:le(),gradientColorStops:[r],gradientColorStopPositions:[A1,zn],inset:ke(),margin:ke(),opacity:C(),padding:le(),saturate:C(),scale:C(),sepia:ne(),skew:C(),space:le(),translate:le()},classGroups:{aspect:[{aspect:["auto","square","video",be]}],container:["container"],columns:[{columns:[Fn]}],"break-after":[{"break-after":Q()}],"break-before":[{"break-before":Q()}],"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"],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:[...ce(),be]}],overflow:[{overflow:me()}],"overflow-x":[{"overflow-x":me()}],"overflow-y":[{"overflow-y":me()}],overscroll:[{overscroll:ee()}],"overscroll-x":[{"overscroll-x":ee()}],"overscroll-y":[{"overscroll-y":ee()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[b]}],"inset-x":[{"inset-x":[b]}],"inset-y":[{"inset-y":[b]}],start:[{start:[b]}],end:[{end:[b]}],top:[{top:[b]}],right:[{right:[b]}],bottom:[{bottom:[b]}],left:[{left:[b]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",pi,be]}],basis:[{basis:ke()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",be]}],grow:[{grow:ne()}],shrink:[{shrink:ne()}],order:[{order:["first","last","none",pi,be]}],"grid-cols":[{"grid-cols":[mi]}],"col-start-end":[{col:["auto",{span:["full",pi,be]},be]}],"col-start":[{"col-start":Z()}],"col-end":[{"col-end":Z()}],"grid-rows":[{"grid-rows":[mi]}],"row-start-end":[{row:["auto",{span:[pi,be]},be]}],"row-start":[{"row-start":Z()}],"row-end":[{"row-end":Z()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",be]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",be]}],gap:[{gap:[P]}],"gap-x":[{"gap-x":[P]}],"gap-y":[{"gap-y":[P]}],"justify-content":[{justify:["normal",...F()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...F(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...F(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[I]}],px:[{px:[I]}],py:[{py:[I]}],ps:[{ps:[I]}],pe:[{pe:[I]}],pt:[{pt:[I]}],pr:[{pr:[I]}],pb:[{pb:[I]}],pl:[{pl:[I]}],m:[{m:[R]}],mx:[{mx:[R]}],my:[{my:[R]}],ms:[{ms:[R]}],me:[{me:[R]}],mt:[{mt:[R]}],mr:[{mr:[R]}],mb:[{mb:[R]}],ml:[{ml:[R]}],"space-x":[{"space-x":[ue]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[ue]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",be,s]}],"min-w":[{"min-w":[be,s,"min","max","fit"]}],"max-w":[{"max-w":[be,s,"none","full","min","max","fit","prose",{screen:[Fn]},Fn]}],h:[{h:[be,s,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[be,s,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[be,s,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[be,s,"auto","min","max","fit"]}],"font-size":[{text:["base",Fn,zn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Su]}],"font-family":[{font:[mi]}],"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:["tighter","tight","normal","wide","wider","widest",be]}],"line-clamp":[{"line-clamp":["none",ls,Su]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",hn,be]}],"list-image":[{"list-image":["none",be]}],"list-style-type":[{list:["none","disc","decimal",be]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[r]}],"placeholder-opacity":[{"placeholder-opacity":[A]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[r]}],"text-opacity":[{"text-opacity":[A]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Ce(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",hn,zn]}],"underline-offset":[{"underline-offset":["auto",hn,be]}],"text-decoration-color":[{decoration:[r]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:le()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",be]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",be]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[A]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ce(),I1]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",F1]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},$1]}],"bg-color":[{bg:[r]}],"gradient-from-pos":[{from:[D]}],"gradient-via-pos":[{via:[D]}],"gradient-to-pos":[{to:[D]}],"gradient-from":[{from:[_]}],"gradient-via":[{via:[_]}],"gradient-to":[{to:[_]}],rounded:[{rounded:[f]}],"rounded-s":[{"rounded-s":[f]}],"rounded-e":[{"rounded-e":[f]}],"rounded-t":[{"rounded-t":[f]}],"rounded-r":[{"rounded-r":[f]}],"rounded-b":[{"rounded-b":[f]}],"rounded-l":[{"rounded-l":[f]}],"rounded-ss":[{"rounded-ss":[f]}],"rounded-se":[{"rounded-se":[f]}],"rounded-ee":[{"rounded-ee":[f]}],"rounded-es":[{"rounded-es":[f]}],"rounded-tl":[{"rounded-tl":[f]}],"rounded-tr":[{"rounded-tr":[f]}],"rounded-br":[{"rounded-br":[f]}],"rounded-bl":[{"rounded-bl":[f]}],"border-w":[{border:[h]}],"border-w-x":[{"border-x":[h]}],"border-w-y":[{"border-y":[h]}],"border-w-s":[{"border-s":[h]}],"border-w-e":[{"border-e":[h]}],"border-w-t":[{"border-t":[h]}],"border-w-r":[{"border-r":[h]}],"border-w-b":[{"border-b":[h]}],"border-w-l":[{"border-l":[h]}],"border-opacity":[{"border-opacity":[A]}],"border-style":[{border:[...Ce(),"hidden"]}],"divide-x":[{"divide-x":[h]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[h]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[A]}],"divide-style":[{divide:Ce()}],"border-color":[{border:[u]}],"border-color-x":[{"border-x":[u]}],"border-color-y":[{"border-y":[u]}],"border-color-s":[{"border-s":[u]}],"border-color-e":[{"border-e":[u]}],"border-color-t":[{"border-t":[u]}],"border-color-r":[{"border-r":[u]}],"border-color-b":[{"border-b":[u]}],"border-color-l":[{"border-l":[u]}],"divide-color":[{divide:[u]}],"outline-style":[{outline:["",...Ce()]}],"outline-offset":[{"outline-offset":[hn,be]}],"outline-w":[{outline:[hn,zn]}],"outline-color":[{outline:[r]}],"ring-w":[{ring:Le()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[r]}],"ring-opacity":[{"ring-opacity":[A]}],"ring-offset-w":[{"ring-offset":[hn,zn]}],"ring-offset-color":[{"ring-offset":[r]}],shadow:[{shadow:["","inner","none",Fn,B1]}],"shadow-color":[{shadow:[mi]}],opacity:[{opacity:[A]}],"mix-blend":[{"mix-blend":[...Ne(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":Ne()}],filter:[{filter:["","none"]}],blur:[{blur:[o]}],brightness:[{brightness:[a]}],contrast:[{contrast:[y]}],"drop-shadow":[{"drop-shadow":["","none",Fn,be]}],grayscale:[{grayscale:[k]}],"hue-rotate":[{"hue-rotate":[w]}],invert:[{invert:[x]}],saturate:[{saturate:[V]}],sepia:[{sepia:[K]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[o]}],"backdrop-brightness":[{"backdrop-brightness":[a]}],"backdrop-contrast":[{"backdrop-contrast":[y]}],"backdrop-grayscale":[{"backdrop-grayscale":[k]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[w]}],"backdrop-invert":[{"backdrop-invert":[x]}],"backdrop-opacity":[{"backdrop-opacity":[A]}],"backdrop-saturate":[{"backdrop-saturate":[V]}],"backdrop-sepia":[{"backdrop-sepia":[K]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[m]}],"border-spacing-x":[{"border-spacing-x":[m]}],"border-spacing-y":[{"border-spacing-y":[m]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",be]}],duration:[{duration:C()}],ease:[{ease:["linear","in","out","in-out",be]}],delay:[{delay:C()}],animate:[{animate:["none","spin","ping","pulse","bounce",be]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[z]}],"scale-x":[{"scale-x":[z]}],"scale-y":[{"scale-y":[z]}],rotate:[{rotate:[pi,be]}],"translate-x":[{"translate-x":[oe]}],"translate-y":[{"translate-y":[oe]}],"skew-x":[{"skew-x":[G]}],"skew-y":[{"skew-y":[G]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",be]}],accent:[{accent:["auto",r]}],appearance:[{appearance:["none","auto"]}],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",be]}],"caret-color":[{caret:[r]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":le()}],"scroll-mx":[{"scroll-mx":le()}],"scroll-my":[{"scroll-my":le()}],"scroll-ms":[{"scroll-ms":le()}],"scroll-me":[{"scroll-me":le()}],"scroll-mt":[{"scroll-mt":le()}],"scroll-mr":[{"scroll-mr":le()}],"scroll-mb":[{"scroll-mb":le()}],"scroll-ml":[{"scroll-ml":le()}],"scroll-p":[{"scroll-p":le()}],"scroll-px":[{"scroll-px":le()}],"scroll-py":[{"scroll-py":le()}],"scroll-ps":[{"scroll-ps":le()}],"scroll-pe":[{"scroll-pe":le()}],"scroll-pt":[{"scroll-pt":le()}],"scroll-pr":[{"scroll-pr":le()}],"scroll-pb":[{"scroll-pb":le()}],"scroll-pl":[{"scroll-pl":le()}],"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",be]}],fill:[{fill:[r,"none"]}],"stroke-w":[{stroke:[hn,zn,Su]}],stroke:[{stroke:[r,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","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","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","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-s","border-w-e","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-s","border-color-e","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"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","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-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"]}}},K1=_1(Q1);function Ee(...r){return K1(m1(r))}function tk(r){return r?r.replace(/127\.0\.0\.1|localhost/g,"192.168.178.151"):""}function q1(){const r=p1();return d.jsxs("div",{className:"flex items-center rounded-md border border-border/40 bg-background/40 p-0.5",role:"group","aria-label":"Ansichtsmodus",title:"Einfach zeigt nur das Wichtigste. Experte zeigt alle technischen Details.",children:[d.jsxs("button",{onClick:()=>Qh(!1),"aria-pressed":!r,className:Ee("flex items-center gap-1 rounded px-2 py-1 text-xs font-semibold transition-all cursor-pointer",r?"text-muted-foreground hover:text-foreground":"bg-primary/15 text-primary shadow-sm"),children:[d.jsx(e0,{className:"h-3.5 w-3.5"})," Einfach"]}),d.jsxs("button",{onClick:()=>Qh(!0),"aria-pressed":r,className:Ee("flex items-center gap-1 rounded px-2 py-1 text-xs font-semibold transition-all cursor-pointer",r?"bg-primary/15 text-primary shadow-sm":"text-muted-foreground hover:text-foreground"),children:[d.jsx(Jy,{className:"h-3.5 w-3.5"})," Experte"]})]})}class G1 extends Error{constructor(o,a,u){super(u||`${o} ${a}`);Qo(this,"status");Qo(this,"detail");this.name="ApiError",this.status=o,this.detail=u}}async function Z1(r){try{const s=await r.text();if(!s)return null;try{const o=JSON.parse(s),a=(o==null?void 0:o.detail)??(o==null?void 0:o.err)??(o==null?void 0:o.message);return typeof a=="string"&&a.trim()?a.trim():Array.isArray(a)&&a.length&&a.map(u=>u==null?void 0:u.msg).filter(Boolean).join("; ")||null}catch{return s.slice(0,200).split(`
|
||
`)[0].trim()||null}}catch{return null}}async function Se(r,s){const o=await fetch(r,{...s,headers:{"Content-Type":"application/json",...s==null?void 0:s.headers}});if(!o.ok)throw new G1(o.status,o.statusText,await Z1(o));return o.json()}const nk=(r,s,o=!1,a=!0)=>Se("/api/groups",{method:"PUT",body:JSON.stringify({group:r,members:s,swap:o,persist:a})}),rk=r=>Se("/api/routing/policy",{method:"PUT",body:JSON.stringify(r)});function Y1({type:r,title:s,message:o,defaultValue:a,autoValue:u,autoLabel:f,onConfirm:m,onCancel:h}){const y=g.useRef(null);return d.jsx("div",{className:"fixed inset-0 z-[99] bg-black/60 backdrop-blur-sm flex items-center justify-center p-4 overscroll-contain",role:"dialog","aria-modal":"true","aria-label":s,children:d.jsxs("div",{className:"w-full max-w-sm rounded-2xl border border-border/80 bg-card p-6 shadow-2xl space-y-4 animate-in fade-in zoom-in-95 duration-200",children:[d.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary",children:s}),d.jsx("button",{onClick:h||(()=>m()),"aria-label":"Schließen",className:"p-1 rounded hover:bg-accent text-muted-foreground hover:text-foreground cursor-pointer",children:d.jsx(dl,{className:"h-4 w-4","aria-hidden":"true"})})]}),d.jsx("p",{className:"max-h-72 overflow-y-auto whitespace-pre-line text-xs text-muted-foreground leading-relaxed scrollbar-thin",children:o}),r==="prompt"&&d.jsxs("div",{className:"flex gap-2",children:[d.jsx("input",{ref:y,type:"text",defaultValue:a,"aria-label":s,className:"flex-1 h-9 px-3 text-xs bg-background/40 border border-border/60 rounded-lg outline-none focus:border-primary transition-colors text-foreground",autoFocus:!0,onKeyDown:k=>{var w;k.key==="Enter"&&m((w=y.current)==null?void 0:w.value)}}),u!==void 0&&d.jsx("button",{type:"button",onClick:()=>{y.current&&(y.current.value=u)},title:"Setup-bewussten Optimalwert eintragen",className:"h-9 px-3 shrink-0 text-xs font-semibold text-primary border border-primary/50 bg-primary/10 hover:bg-primary/20 rounded-lg transition-colors cursor-pointer",children:f||"Auto"})]}),d.jsxs("div",{className:"flex justify-end gap-3 pt-2",children:[(r==="confirm"||r==="prompt")&&d.jsx("button",{onClick:h,className:"h-8 px-4 flex items-center justify-center text-xs font-semibold text-muted-foreground border border-border/60 bg-background/20 hover:bg-accent rounded-lg transition-colors cursor-pointer",children:"Abbrechen"}),d.jsx("button",{onClick:()=>{var w;const k=r==="prompt"?(w=y.current)==null?void 0:w.value:void 0;m(k)},className:"h-8 px-4 flex items-center justify-center text-xs font-semibold text-primary-foreground bg-primary hover:bg-primary/95 rounded-lg transition-colors cursor-pointer",children:r==="confirm"?"Ja, fortfahren":r==="prompt"?"Übernehmen":"OK"})]})]})})}function ym(){const[r,s]=g.useState(null),o=g.useCallback(()=>s(null),[]),a=g.useCallback((h,y,k)=>{s({type:"alert",title:h,message:y,onConfirm:()=>{s(null),k==null||k()}})},[]),u=g.useCallback((h,y,k,w)=>{s({type:"confirm",title:h,message:y,onConfirm:()=>{s(null),k()},onCancel:()=>{s(null),w==null||w()}})},[]),f=g.useCallback((h,y,k,w,x,P)=>{s({type:"prompt",title:h,message:y,defaultValue:k,autoValue:P==null?void 0:P.autoValue,autoLabel:P==null?void 0:P.autoLabel,onConfirm:_=>{s(null),w(_)},onCancel:()=>{s(null),x==null||x()}})},[]),m=r?d.jsx(Y1,{...r}):null;return{showAlert:a,showConfirm:u,showPrompt:f,close:o,dialogElement:m}}let il=!1;const X1=()=>il;function J1(){const r=ul();g.useEffect(()=>{const s=new EventSource("/api/events");return s.onopen=()=>{il=!0},s.onerror=()=>{il=!1},s.addEventListener("invalidate",o=>{var a;try{const u=((a=JSON.parse(o.data))==null?void 0:a.keys)??[];for(const f of u)r.invalidateQueries({queryKey:[f]})}catch{}}),()=>{il=!1,s.close()}},[r])}const Pe={health:["health"],systemStatus:["system-status"],services:["services"],models:["models"],groups:["groups"],routing:["routing"],routingPolicy:["routing-policy"],jobs:["jobs"],tokenStats:["token-stats"],agentStatus:["agent-status"],hermesBrain:["hermes-brain"],updates:["updates"],discover:["discover"],drafts:r=>["drafts",r??""],connect:r=>["connect",r??""],connectHealth:["connect-health"],memoryGraph:["memory-graph"],voiceTrace:["voice-trace"],auftragsbuch:["auftragsbuch"],ideen:["ideen"],chronik:["chronik"],wissen:["wissen"],zeitmaschine:["zeitmaschine"],reminders:["reminders"]},St={graph:3e3,schnell:8e3,normal:1e4,gemuetlich:3e4,traege:6e4},gl=r=>()=>X1()?r*5:r,ew=(r=St.schnell)=>Be({queryKey:Pe.auftragsbuch,queryFn:()=>Se("/api/auftragsbuch"),refetchInterval:gl(r)}),tw=(r=St.gemuetlich)=>Be({queryKey:Pe.ideen,queryFn:()=>Se("/api/ideen"),refetchInterval:gl(r)}),sk=(r,s=!1)=>Be({queryKey:["ideen-log",r],queryFn:()=>Se(`/api/ideen/${r}/log`),enabled:s,refetchInterval:4e3,staleTime:0}),ik=(r=150,s=St.gemuetlich)=>Be({queryKey:[...Pe.chronik,r],queryFn:()=>Se(`/api/chronik?limit=${r}`),refetchInterval:gl(s),select:o=>o.items??[]}),ok=()=>Be({queryKey:Pe.wissen,queryFn:()=>Se("/api/wissen")}),nw=(r=St.traege,s=!0)=>Be({queryKey:Pe.zeitmaschine,queryFn:()=>Se("/api/zeitmaschine"),refetchInterval:r,enabled:s}),rw=(r=12,s=St.schnell)=>Be({queryKey:Pe.voiceTrace,queryFn:()=>Se(`/api/voice/trace?limit=${r}`),refetchInterval:s,select:o=>o.turns??[]}),lk=(r=!0)=>Be({queryKey:Pe.memoryGraph,queryFn:()=>Se("/api/wissen/graph"),enabled:r,staleTime:60*1e3}),xm=()=>Be({queryKey:Pe.health,queryFn:()=>Se("/api/health"),refetchInterval:St.normal}),vl=(r=St.graph)=>Be({queryKey:Pe.systemStatus,queryFn:()=>Se("/api/system/status"),refetchInterval:r}),wm=(r,s=!0)=>Be({queryKey:["metrics-history",r],queryFn:()=>Se(`/api/system/history?minutes=${r}`),enabled:s,refetchInterval:6e4}),hc=(r=St.normal)=>Be({queryKey:Pe.services,queryFn:()=>Se("/api/system/services"),refetchInterval:r}),km=(r=St.schnell)=>Be({queryKey:Pe.models,queryFn:()=>Se("/api/models"),refetchInterval:gl(r)}),ak=(r=St.normal)=>Be({queryKey:Pe.groups,queryFn:()=>Se("/api/groups"),refetchInterval:r}),uk=()=>Be({queryKey:Pe.routingPolicy,queryFn:()=>Se("/api/routing/policy")}),sw=(r=3e3,s=!0)=>Be({queryKey:Pe.jobs,queryFn:()=>Se("/api/jobs"),refetchInterval:r,enabled:s,select:o=>o.jobs??[]}),bm=(r=St.graph)=>Be({queryKey:Pe.tokenStats,queryFn:()=>Se("/api/system/token-stats"),refetchInterval:r}),iw=(r=St.normal)=>Be({queryKey:Pe.agentStatus,queryFn:()=>Se("/api/agent/status"),refetchInterval:r}),ck=(r=St.traege)=>Be({queryKey:Pe.hermesBrain,queryFn:()=>Se("/api/agent/brain"),refetchInterval:r}),Sm=(r=St.traege)=>Be({queryKey:Pe.updates,queryFn:()=>Se("/api/maintenance/updates"),refetchInterval:r}),dk=()=>Be({queryKey:Pe.discover,queryFn:()=>Se("/api/discover")}),fk=r=>Be({queryKey:Pe.drafts(r),queryFn:()=>Se(`/api/models/drafts?target=${encodeURIComponent(r??"")}`),enabled:!!r}),hk=r=>Be({queryKey:Pe.connect(r),queryFn:()=>Se(r?`/api/connect?${r}`:"/api/connect")}),ow=()=>Be({queryKey:Pe.connectHealth,queryFn:()=>Se("/api/connect/health"),refetchInterval:15e3});function gi(r,...s){for(const o of s)r.invalidateQueries({queryKey:o})}function ts(r){return(r/1024**3).toFixed(1)}function Eu(r){return r?r>1024**3?`${(r/1024**3).toFixed(1)} GB`:`${(r/1024**2).toFixed(0)} MB`:""}function pk(r){if(!r)return"—";const s=r/1024**3;return s>=1?`${s.toFixed(1)} GB`:`${(r/1024**2).toFixed(0)} MB`}function mk(r){if(!r)return"";const s=Math.floor(r/60);return s>0?`${s} min`:`${r} s`}function gk(r){return r?`${Math.round(r/1024)}k`:"—"}function vk(r){return r?new Date(r*1e3).toLocaleString("de-DE",{day:"2-digit",month:"2-digit",hour:"2-digit",minute:"2-digit"}):"—"}function vi({icon:r,iconClass:s,name:o,status:a,available:u,busy:f,actionLabel:m,onAction:h}){return d.jsxs("div",{className:Ee("flex items-center gap-3 rounded-lg border px-3 py-2",u?"border-amber-500/30 bg-amber-500/5":"border-border/50 bg-background/20"),children:[d.jsx(r,{className:Ee("h-4 w-4 shrink-0",s)}),d.jsxs("div",{className:"flex-1 min-w-0",children:[d.jsx("div",{className:"text-xs text-foreground truncate",children:o}),d.jsx("div",{className:Ee("text-[10px] truncate",u?"text-amber-400/90":"text-muted-foreground"),children:a})]}),d.jsx("button",{onClick:h,disabled:!u||f,className:Ee("text-[11px] font-semibold rounded-lg px-2.5 py-1 transition-colors shrink-0",u?"bg-primary text-primary-foreground hover:opacity-90 cursor-pointer":"border border-border/50 text-muted-foreground/40 cursor-default"),children:f?"…":m})]})}function lw({label:r,ok:s,system:o,busy:a,onRestart:u,onLogs:f}){return d.jsxs("div",{className:"flex items-center gap-2.5 rounded-lg border border-border/50 bg-background/20 px-3 py-2",children:[d.jsx("span",{className:Ee("w-1.5 h-1.5 rounded-full shrink-0",s===!0?"bg-emerald-500":s===!1?"bg-red-500":"bg-muted-foreground/40")}),d.jsxs("span",{className:"flex-1 text-xs text-foreground truncate",children:[r,o&&d.jsx("span",{className:"text-[9px] text-muted-foreground",children:" (root)"})]}),d.jsx("button",{onClick:u,disabled:a,title:"Neu starten",className:"text-muted-foreground hover:text-primary transition-colors disabled:opacity-50",children:d.jsx(ss,{className:Ee("h-3.5 w-3.5",a&&"animate-spin")})}),d.jsx("button",{onClick:f,title:"Logs ansehen",className:"text-muted-foreground hover:text-primary transition-colors",children:d.jsx(Iy,{className:"h-3.5 w-3.5"})})]})}const aw=/\b(error|fehler|fail(ed|ure)?|fatal|critical|crit|panic|traceback|exception|denied|refused|unable|emerg|alert|oom|killed)\b/i,uw=/\b(warn(ing)?|deprecat\w*|retry(ing)?|timeout|timed out|degraded|missing|not found|nicht gefunden)\b/i;function cw(r){return aw.test(r)?"error":uw.test(r)?"warn":"info"}const dw={error:"text-red-400",warn:"text-amber-300",info:"text-cyan-300/80"};function fw({service:r,text:s,loading:o,logStatus:a,onRefresh:u,onOpenSettings:f}){const[m,h]=g.useState(!1),[y,k]=g.useState(""),w=g.useRef(null),x=g.useMemo(()=>s?s.split(`
|
||
`).map(R=>({t:R,level:cw(R)})):[],[s]),P=g.useMemo(()=>x.filter(R=>R.level!=="info").length,[x]),_=y.trim().toLowerCase(),D=x.filter(R=>(!m||R.level!=="info")&&(!_||R.t.toLowerCase().includes(_))),b=a==="password_required"||a==="incorrect_password";return d.jsxs("div",{className:"flex-1 flex flex-col min-h-[300px] border border-border/60 bg-black/50 rounded-xl overflow-hidden shadow-inner",children:[d.jsxs("div",{className:"flex h-10 items-center justify-between gap-2 px-3 border-b border-border/40 bg-black/30 shrink-0",children:[d.jsxs("div",{className:"flex items-center gap-1.5 text-[10px] font-mono text-muted-foreground shrink-0",children:[d.jsx(n0,{className:"h-3 w-3 text-primary"}),d.jsx("span",{className:"hidden sm:inline",children:"stdout/stderr —"})," ",r]}),d.jsxs("div",{className:"flex items-center gap-1.5",children:[d.jsxs("div",{className:"relative",children:[d.jsx(Xy,{className:"pointer-events-none absolute left-2 top-1/2 h-3 w-3 -translate-y-1/2 text-muted-foreground"}),d.jsx("input",{value:y,onChange:R=>k(R.target.value),placeholder:"filtern…",className:"h-7 w-24 sm:w-36 rounded-md border border-border/50 bg-background/40 pl-6 pr-2 text-[10px] text-foreground outline-none focus:border-primary/50"})]}),d.jsxs("button",{onClick:()=>h(R=>!R),title:"Nur Fehler und Warnungen zeigen",className:Ee("flex h-7 items-center gap-1 rounded-md border px-2 text-[10px] font-semibold transition-colors",m?"border-amber-500/50 bg-amber-500/15 text-amber-300":"border-border/50 bg-background/20 text-muted-foreground hover:text-foreground"),children:[d.jsx(Ci,{className:"h-3 w-3"}),"Nur Probleme",P>0?` (${P})`:""]}),d.jsx("button",{onClick:u,disabled:o,title:"Neu laden",className:"flex h-7 w-7 items-center justify-center rounded-md border border-border/50 bg-background/20 text-muted-foreground hover:text-foreground transition-colors disabled:opacity-50",children:d.jsx(ss,{className:Ee("h-3 w-3",o&&"animate-spin")})})]})]}),d.jsx("div",{ref:w,className:"flex-1 overflow-y-auto p-3 text-[10px] font-mono leading-relaxed scrollbar-thin select-text",children:b?d.jsxs("div",{className:"flex h-full flex-col items-center justify-center space-y-3 p-6 text-center",children:[d.jsx(Ci,{className:"h-8 w-8 text-amber-400 animate-pulse animate-duration-1000"}),d.jsx("div",{className:"text-xs font-semibold text-amber-300",children:a==="incorrect_password"?"Falsches Sudo-Passwort hinterlegt.":"Sudo-Passwort für systemd-Dienste erforderlich."}),d.jsxs("p",{className:"max-w-xs text-[10px] leading-normal text-muted-foreground",children:["Für das Auslesen der systemd-Logs von ",r," werden Root-Rechte benötigt. Hinterlege dein Passwort in den Einstellungen."]}),d.jsx("button",{onClick:f,className:"mt-2 rounded-md bg-primary px-3 py-1.5 text-[10px] font-semibold text-primary-foreground transition-colors hover:bg-primary/95",children:"Sudo-Passwort eintragen"})]}):o&&!s?d.jsx("span",{className:"text-muted-foreground",children:"Lade Logs…"}):x.length===0?d.jsx("span",{className:"text-muted-foreground",children:"Keine Logeinträge vorhanden."}):D.length===0?d.jsx("span",{className:"text-muted-foreground",children:m?"Keine Fehler oder Warnungen — der Dienst läuft sauber. ✓":"Kein Treffer für den Filter."}):D.map((R,A)=>d.jsx("div",{className:Ee("whitespace-pre-wrap",dw[R.level]),children:R.t||" "},A))})]})}function hw({open:r,showAlert:s}){const[o,a]=g.useState(null),[u,f]=g.useState(""),[m,h]=g.useState(!1),[y,k]=g.useState(!1),[w,x]=g.useState(!1);async function P(){k(!0);try{a(await Se("/api/maintenance/geheimnisse"))}catch(D){s("Nicht erreichbar",`Der Geheimnis-Zustand konnte nicht geladen werden: ${(D==null?void 0:D.message)||D}`)}finally{k(!1)}}g.useEffect(()=>{r&&(f(""),h(!1),P())},[r]);async function _(D){x(!0);try{const b=await Se("/api/maintenance/geheimnisse",{method:"POST",body:JSON.stringify({schluessel:"hf_token",wert:D})});a(b),f(""),s(D?"Gespeichert":"Gelöscht",D?"Der Token liegt jetzt auf der Box — der Browser behält ihn nicht.":"Der Token wurde von der Box entfernt.")}catch(b){s("Fehlgeschlagen",(b==null?void 0:b.message)||String(b))}finally{x(!1)}}return d.jsxs("div",{className:"space-y-6",children:[d.jsxs("div",{className:"space-y-2",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Zugangsdaten & Schlüssel"}),d.jsx("p",{className:"text-[10px] leading-normal text-muted-foreground",children:"Geheimnisse liegen auf der Box (Datei mit Rechten 0600), nicht im Browser. Diese Seite zeigt nur, ob etwas gesetzt ist — den Wert bekommt sie nie zurück."})]}),d.jsxs("div",{className:"mc-card-sm space-y-1.5 p-3",children:[d.jsxs("div",{className:"flex items-center gap-1.5 text-xs font-semibold",children:[d.jsx(Cp,{className:"h-4 w-4 text-emerald-400","aria-hidden":"true"}),"Box-Sudo-Passwort — nicht mehr nötig"]}),d.jsxs("p",{className:"text-[10px] leading-normal text-muted-foreground",children:["Systemdienste, OS-Update und Neustart laufen passwortlos (",d.jsx("code",{className:"font-mono text-primary",children:"NOPASSWD"})," in",d.jsx("code",{className:"font-mono",children:" /etc/sudoers"}),"). Das frühere Feld hat nie etwas bewirkt und lag dabei im Browser-Speicher — es ist am 28.08.2026 ersatzlos entfallen. Verlangt ",d.jsx("code",{className:"font-mono",children:"sudo"})," auf der Box je doch ein Passwort, sagt die Wartung das im Klartext; das ist dann dort zu lösen."]})]}),d.jsxs("div",{className:"space-y-2",children:[d.jsxs("label",{htmlFor:"hf-token",className:"flex items-center gap-1.5 text-xs font-semibold",children:[d.jsx(Wy,{className:"h-4 w-4 text-violet-400","aria-hidden":"true"}),"HuggingFace-Token"]}),d.jsx("div",{className:"flex items-center gap-2 text-[11px]",children:y?d.jsxs("span",{className:"flex items-center gap-1.5 text-muted-foreground",children:[d.jsx(ji,{className:"h-3 w-3 animate-spin","aria-hidden":"true"})," Zustand wird geladen …"]}):o!=null&&o.hf_token_gesetzt?d.jsxs("span",{className:"flex items-center gap-1.5 font-semibold text-emerald-400",children:[d.jsx("span",{className:"h-2 w-2 rounded-full bg-emerald-500","aria-hidden":"true"}),"Gesetzt",o.hf_token_aus_env?" (aus der Dienst-Umgebung)":""]}):d.jsxs("span",{className:"flex items-center gap-1.5 text-muted-foreground",children:[d.jsx("span",{className:"h-2 w-2 rounded-full bg-muted-foreground/50","aria-hidden":"true"}),"Nicht gesetzt"]})}),(o==null?void 0:o.hf_token_aus_env)&&d.jsxs("p",{className:"text-[9px] leading-normal text-amber-400/90",children:["Der Token kommt aus der Umgebung des Dienstes und hat Vorrang. Hier gespeicherte Werte bleiben wirkungslos, solange ",d.jsx("code",{className:"font-mono",children:"HF_TOKEN"})," gesetzt ist."]}),o&&!o.schreibbar&&d.jsx("p",{className:"text-[9px] leading-normal text-amber-400/90",children:"Die Ablage ist nicht beschreibbar — auf einem Entwicklungsrechner ohne den Modell-Ordner der Box ist das normal. Speichern würde hier ins Leere laufen."}),d.jsxs("div",{className:"relative",children:[d.jsx("input",{id:"hf-token",type:m?"text":"password",value:u,onChange:D=>f(D.target.value),autoComplete:"off",spellCheck:!1,placeholder:o!=null&&o.hf_token_gesetzt?"Neuen Token eingeben, um zu ersetzen":"hf_…",className:"h-10 w-full rounded-lg border border-border/60 bg-background/40 pl-3 pr-10 text-xs text-foreground outline-none transition-colors focus:border-primary"}),d.jsx("button",{type:"button",onClick:()=>h(!m),"aria-label":m?"Token verbergen":"Token anzeigen",className:"absolute inset-y-0 right-0 flex items-center pr-3 text-muted-foreground transition-colors hover:text-foreground",children:m?d.jsx(Fy,{className:"h-4 w-4","aria-hidden":"true"}):d.jsx(jp,{className:"h-4 w-4","aria-hidden":"true"})})]}),d.jsxs("p",{className:"text-[9px] leading-normal text-muted-foreground",children:["Nötig für Modelle mit Zugangsschranke. Wird beim Download als",d.jsx("code",{className:"font-mono",children:" HF_TOKEN"})," an den Job gereicht und verlässt die Box nicht."]})]}),d.jsxs("div",{className:"flex gap-3 pt-2",children:[d.jsxs("button",{onClick:()=>_(u.trim()),disabled:w||!u.trim(),className:"flex h-9 flex-1 cursor-pointer items-center justify-center gap-1.5 rounded-lg bg-primary text-xs font-semibold text-primary-foreground shadow shadow-primary/10 transition-colors hover:bg-primary/90 disabled:cursor-not-allowed disabled:opacity-40",children:[w&&d.jsx(ji,{className:"h-3.5 w-3.5 animate-spin","aria-hidden":"true"}),"Auf der Box speichern"]}),d.jsx("button",{onClick:()=>_(null),disabled:w||!(o!=null&&o.hf_token_gesetzt),className:"flex h-9 cursor-pointer items-center justify-center rounded-lg border border-border/60 bg-background/20 px-4 text-xs font-semibold text-muted-foreground transition-colors hover:bg-accent disabled:cursor-not-allowed disabled:opacity-40",children:"Löschen"})]})]})}function pw({detail:r,maintenanceJob:s,onClose:o,onApply:a}){var y,k;const u=r.data,f={os:{icon:_p,cls:"text-cyan-400",title:"OS-Pakete (apt)"},engine:{icon:cl,cls:"text-violet-400",title:"Inferenz-Engine (llama.cpp)"},swap:{icon:Pp,cls:"text-fuchsia-400",title:"Router (llama-swap)"},hermes:{icon:Ni,cls:"text-amber-400",title:"Hermes-Agent"}}[r.kind],m=f.icon,h=u?r.kind==="os"?(u.count??0)===0:r.kind==="hermes"?(u.behind??0)===0:u.installed_build!=null&&u.latest_build!=null&&u.latest_build<=u.installed_build:!0;return d.jsxs("div",{className:"fixed inset-0 z-[60] flex items-center justify-center p-4",children:[d.jsx("div",{className:"absolute inset-0 bg-black/70 backdrop-blur-sm",onClick:o}),d.jsxs("div",{className:"relative w-full max-w-lg max-h-[80vh] flex flex-col rounded-2xl border border-border/60 bg-card shadow-2xl font-sans text-foreground",children:[d.jsxs("div",{className:"flex h-14 shrink-0 items-center justify-between border-b border-border/40 px-5",children:[d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx(m,{className:Ee("h-4.5 w-4.5",f.cls)}),d.jsx("h3",{className:"text-sm font-semibold",children:f.title})]}),d.jsx("button",{onClick:o,className:"flex h-7 w-7 items-center justify-center rounded-lg border border-border/40 text-muted-foreground hover:bg-accent transition-colors",children:d.jsx(dl,{className:"h-4 w-4"})})]}),d.jsx("div",{className:"flex-1 overflow-y-auto p-5 text-xs space-y-3 scrollbar-thin",children:r.loading?d.jsxs("div",{className:"flex h-24 items-center justify-center gap-2 text-muted-foreground",children:[d.jsx(ss,{className:"h-4 w-4 animate-spin"})," Details werden geladen…"]}):u!=null&&u.error?d.jsx("div",{className:"rounded-lg border border-red-500/30 bg-red-500/5 p-3 text-red-400",children:u.error}):d.jsxs(d.Fragment,{children:[(u==null?void 0:u.action_needed)!=null&&d.jsxs("div",{className:Ee("flex items-start gap-2 rounded-lg border p-3",u.action_needed?"border-amber-500/40 bg-amber-500/10":"border-emerald-500/40 bg-emerald-500/10"),children:[u.action_needed?d.jsx(Ci,{className:"h-4 w-4 text-amber-400 shrink-0 mt-0.5"}):d.jsx(Ty,{className:"h-4 w-4 text-emerald-400 shrink-0 mt-0.5"}),d.jsxs("div",{className:"min-w-0",children:[d.jsxs("div",{className:Ee("text-xs font-semibold",u.action_needed?"text-amber-300":"text-emerald-300"),children:["Musst du etwas tun? ",u.action_needed?"Ja":"Nein — die Box regelt das (Fangnetz)"]}),u.action_needed&&u.action_text&&d.jsx("div",{className:"mt-0.5 text-[11px] text-foreground/90",children:u.action_text})]})]}),(u==null?void 0:u.summary)&&d.jsxs("div",{className:"rounded-lg border border-primary/25 bg-primary/5 p-3 space-y-1",children:[d.jsx("div",{className:"text-[10px] font-bold uppercase tracking-wider text-primary",children:"Was dieses Update bedeutet (Zusammenfassung der Box)"}),d.jsx("pre",{className:"whitespace-pre-wrap text-[11px] leading-relaxed text-foreground/90 font-sans",children:u.summary})]}),r.kind==="os"?d.jsxs(d.Fragment,{children:[((u==null?void 0:u.count)??0)===0?d.jsx("div",{className:"text-muted-foreground",children:"Keine Pakete zu aktualisieren — System ist aktuell."}):d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:"text-muted-foreground",children:[u.count," Paket(e) werden aktualisiert:"]}),d.jsx("div",{className:"space-y-1",children:u.packages.map(w=>d.jsxs("div",{className:"flex items-center justify-between gap-2 rounded-md border border-border/40 bg-background/30 px-2.5 py-1.5",children:[d.jsxs("span",{className:"flex items-center gap-1.5 font-mono text-[11px] truncate",children:[d.jsx(Ch,{className:"h-3 w-3 text-cyan-400 shrink-0"}),w.name]}),d.jsxs("span",{className:"flex items-center gap-1 font-mono text-[10px] text-muted-foreground shrink-0",children:[d.jsx("span",{children:w.current}),d.jsx(jh,{className:"h-3 w-3"}),d.jsx("span",{className:"text-emerald-400",children:w.candidate})]})]},w.name))})]}),(((y=u==null?void 0:u.held_back)==null?void 0:y.length)??0)>0&&d.jsxs("div",{className:"space-y-1.5 rounded-lg border border-border/40 bg-background/20 p-3",children:[d.jsxs("div",{className:"flex items-center gap-1.5 text-[11px] font-semibold text-muted-foreground",children:[d.jsx(Ly,{className:"h-3.5 w-3.5"})," Vom Hersteller zurückgestellt — kein Handeln nötig"]}),d.jsx("p",{className:"text-[10px] text-muted-foreground leading-normal",children:"Diese Pakete gäbe es bereits, Ubuntu spielt sie aber gestaffelt aus (Phasen-Rollout) bzw. hält sie kurz zurück. Sie kommen bei einem der nächsten automatischen Läufe von selbst — das ist kein Fehler und nichts hängt fest."}),d.jsx("div",{className:"space-y-1",children:u.held_back.map(w=>d.jsxs("div",{className:"flex items-center justify-between gap-2 rounded-md border border-border/30 bg-background/30 px-2.5 py-1.5",children:[d.jsxs("span",{className:"flex items-center gap-1.5 font-mono text-[11px] truncate",children:[d.jsx(Ch,{className:"h-3 w-3 text-muted-foreground shrink-0"}),w.name]}),d.jsx("span",{className:"text-[9px] text-muted-foreground shrink-0",children:w.reason==="phasing"?"Phasen-Rollout":"vorerst zurückgehalten"})]},w.name))})]})]}):r.kind==="engine"||r.kind==="swap"?d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:"flex items-center gap-2 font-mono text-[11px]",children:[d.jsxs("span",{className:"rounded-md border border-border/40 bg-background/30 px-2 py-1",children:["Build ",(u==null?void 0:u.installed_build)??"?"]}),d.jsx(jh,{className:"h-3.5 w-3.5 text-muted-foreground"}),d.jsxs("span",{className:"rounded-md border border-emerald-500/30 bg-emerald-500/5 px-2 py-1 text-emerald-400",children:["Build ",(u==null?void 0:u.latest_build)??"?"]})]}),((u==null?void 0:u.name)||(u==null?void 0:u.latest_tag))&&d.jsxs("div",{className:"text-muted-foreground",children:["Release: ",d.jsx("span",{className:"text-foreground",children:u==null?void 0:u.name}),u!=null&&u.latest_tag?` (${u.latest_tag})`:""]}),(u==null?void 0:u.url)&&d.jsxs("a",{href:u.url,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-1 text-primary hover:underline",children:["Original-Release-Notes auf GitHub ",d.jsx(zy,{className:"h-3 w-3"})]}),(u==null?void 0:u.body)&&d.jsxs("details",{className:"group",children:[d.jsx("summary",{className:"cursor-pointer text-[10px] text-muted-foreground hover:text-foreground",children:"Original-Notizen (englisch) anzeigen"}),d.jsx("pre",{className:"mt-1.5 whitespace-pre-wrap rounded-lg border border-border/40 bg-background/30 p-3 text-[10px] leading-relaxed text-muted-foreground max-h-60 overflow-y-auto scrollbar-thin",children:u.body})]})]}):(((k=u==null?void 0:u.commits)==null?void 0:k.length)??0)===0?d.jsx("div",{className:"text-muted-foreground",children:"Keine neuen Commits — Hermes-Agent ist bereits aktuell."}):d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:"text-muted-foreground",children:[u.behind," neue Commit(s) auf ",d.jsxs("span",{className:"font-mono text-foreground",children:["origin/",u.branch]}),":"]}),d.jsx("div",{className:"space-y-1",children:u.commits.map(w=>d.jsxs("div",{className:"flex items-start gap-2 rounded-md border border-border/40 bg-background/30 px-2.5 py-1.5",children:[d.jsx($y,{className:"h-3.5 w-3.5 text-primary shrink-0 mt-0.5"}),d.jsxs("div",{className:"min-w-0",children:[d.jsx("div",{className:"text-[11px] truncate",children:w.subject}),d.jsxs("div",{className:"font-mono text-[9px] text-muted-foreground",children:[w.hash," · ",w.when]})]})]},w.hash))})]}),r.kind!=="os"&&!h&&d.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-border/40 bg-background/20 p-2.5",children:[d.jsx(Cp,{className:"h-3.5 w-3.5 text-emerald-400 shrink-0 mt-0.5"}),d.jsxs("p",{className:"text-[10px] text-muted-foreground leading-normal",children:["Vor dem Update sichert die Box automatisch den alten Stand. Danach prüft sie den ganzen Stack per echter Anfrage — läuft etwas nicht, rollt sie von selbst zurück",r.kind==="hermes"?" und startet den Gateway neu":"","."]})]})]})}),d.jsxs("div",{className:"flex gap-3 border-t border-border/40 p-4 shrink-0",children:[d.jsx("button",{onClick:o,className:"h-9 flex-1 rounded-lg border border-border/60 bg-background/20 text-xs font-semibold text-muted-foreground hover:bg-accent transition-colors cursor-pointer",children:"Schließen"}),d.jsx("button",{onClick:a,disabled:r.loading||h||!!s,title:s?`Update läuft bereits: ${s.label}`:void 0,className:"h-9 flex-1 rounded-lg bg-primary text-xs font-semibold text-primary-foreground hover:opacity-90 transition-all cursor-pointer disabled:opacity-40 disabled:cursor-default",children:s?"Update läuft…":"Jetzt aktualisieren"})]})]})]})}function mw({open:r,onClose:s,defaultTab:o="maintenance"}){var jr,Cs;const a=ul(),{showAlert:u,showConfirm:f,dialogElement:m}=ym(),{data:h}=Sm(),{data:y}=hc(),k=sw(3e3,r).data??[],{data:w}=nw(void 0,r),[x,P]=g.useState("llama-swap"),[_,D]=g.useState(""),[b,R]=g.useState(!1),[A,I]=g.useState(null),[V,z]=g.useState({}),[K,G]=g.useState("maintenance"),[ue,oe]=g.useState(!1),[ee,me]=g.useState(""),[ke,le]=g.useState(!1),[Le,Z]=g.useState(!1),[ce,Ce]=g.useState(null),Ne=(y==null?void 0:y.services)??[],F=()=>gi(a,Pe.jobs);function ne(L){return L?new Date(L*1e3).toLocaleString("de-DE",{day:"2-digit",month:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):"Nie"}g.useEffect(()=>{r&&o&&G(o)},[r,o]),g.useEffect(()=>{r&&gi(a,Pe.updates,Pe.services,Pe.jobs,Pe.zeitmaschine)},[r]);function Q(L){R(!0),I(null),Se(`/api/maintenance/logs?service=${L}&lines=150`).then(xe=>{xe.ok?D(xe.text):(D(`Fehler beim Laden der Logs: ${xe.err||"Unbekannter Fehler"}`),(xe.status==="incorrect_password"||xe.status==="password_required")&&I(xe.status))}).catch(xe=>D(`Fehler: ${xe.message}`)).finally(()=>R(!1))}g.useEffect(()=>{!r||K!=="logs"||Q(x)},[r,K,x]);function C(L){return(L==null?void 0:L.status)==="busy"?(u("Update läuft bereits",`Es läuft gerade „${L.running}". Bitte warte, bis es fertig ist.`),F(),!0):!1}function N(L){return(L==null?void 0:L.status)==="password_required"||(L==null?void 0:L.status)==="incorrect_password"?(u("Box-Passwort nötig",(L.status==="incorrect_password"?"Das gespeicherte Box-Passwort stimmt nicht. ":"Für dieses Update braucht die Box dein Passwort. ")+"Bitte oben im Reiter „Einstellungen“ setzen bzw. korrigieren."),!0):L&&L.ok===!1?(u("Update fehlgeschlagen",L.err||"Unbekannter Fehler."),!0):!1}async function q(L){const xe={os:"os-update",engine:"engine-update",swap:"swap-update"}[L];try{const ze=await Se(`/api/maintenance/${xe}`,{method:"POST"});if(C(ze)||N(ze))return;F(),G("maintenance")}catch(ze){u("Fehler",`Update konnte nicht starten: ${ze.message}`)}}async function Y(){Z(!0);try{const L=await Se("/api/maintenance/hermes-update",{method:"POST"});if(C(L))return;F()}catch(L){u("Fehler",`Hermes-Update fehlgeschlagen: ${L.message}`)}finally{Z(!1)}}async function W(L){Ce({kind:L,loading:!0,data:null});try{const xe=await Se(`/api/maintenance/update-details?kind=${L}`);Ce({kind:L,loading:!1,data:xe})}catch(xe){Ce({kind:L,loading:!1,data:{kind:L,error:xe.message}})}}function se(){const L=ce==null?void 0:ce.kind;Ce(null),L==="os"||L==="engine"||L==="swap"?q(L):L==="hermes"&&Y()}function de(){var xe;const L=[h!=null&&h.engine?"Engine":null,h!=null&&h.swap?"Router":null,(xe=h==null?void 0:h.components)!=null&&xe.some(ze=>ze.update===!0)?"Hermes-Agent":null,h!=null&&h.os?`OS (${h.os} Pakete)`:null].filter(Boolean);f("Alle Updates einspielen?",`Nacheinander in einem Job: ${L.join(" → ")}. Jeder Schritt sichert und prüft sich selbst; schlägt einer fehl, stoppt der Rest. (OS braucht das Box-Passwort aus den Einstellungen — fehlt es, wird OS übersprungen.)`,async()=>{try{const ze=await Se("/api/maintenance/update-all",{method:"POST"});if(C(ze)||N(ze))return;if((ze==null?void 0:ze.status)==="nothing"){u("Nichts zu tun","Es stehen keine Updates aus.");return}F(),G("maintenance")}catch(ze){u("Fehler",`„Alle aktualisieren" konnte nicht starten: ${ze.message}`)}})}async function ye(){oe(!0);try{await Se("/api/maintenance/check-updates",{method:"POST"}),gi(a,Pe.jobs,Pe.updates),G("maintenance")}catch(L){u("Fehler",`Fehler bei der Update-Suche: ${L.message}`)}finally{oe(!1)}}async function we(L,xe){try{await Se("/api/models/install",{method:"POST",body:JSON.stringify({repo:L,role:xe})}),u("Gestartet",`Modell-Upgrade für '${xe}' (${L}) gestartet.`),F(),G("maintenance")}catch(ze){u("Fehler",`Fehler beim Starten des Modell-Upgrades: ${ze.message}`)}}async function Ge(){f("Reboot bestätigen","Bist du sicher, dass du das gesamte Host-System neu starten willst?",async()=>{try{await Se("/api/maintenance/reboot",{method:"POST"}),u("Reboot","Reboot ausgelöst. System startet neu...",()=>s())}catch(L){u("Fehler",`Fehler beim Reboot: ${L.message}`)}})}async function Sr(){le(!0),me("Snapshot wird erzeugt...");try{const L=await Se("/api/system/backup",{method:"POST"});me(L.ok?`Snapshot erzeugt: ${L.snapshot} (${L.files.length} Komponenten)`:"Backup fehlgeschlagen."),gi(a,Pe.zeitmaschine)}catch(L){me(`Fehler: ${L.message}`)}finally{le(!1)}}async function Ns(L){z(xe=>({...xe,[L]:!0}));try{const xe=await Se("/api/maintenance/restart",{method:"POST",body:JSON.stringify({service:L})});xe.ok?(u("Dienst neu gestartet",`Dienst ${L} wurde erfolgreich neu gestartet.`,()=>{K==="logs"&&x===L&&Q(L)}),gi(a,Pe.services,Pe.health,Pe.models)):u("Fehler",`Fehler beim Neustart: ${xe.err||"Unbekannter Fehler"}`)}catch(xe){u("Fehler",`Fehler beim Neustart: ${xe.message}`)}finally{z(xe=>({...xe,[L]:!1}))}}async function Er(L){try{await Se(`/api/jobs/${L}/cancel`,{method:"POST"}),F()}catch(xe){u("Fehler",`Fehler beim Abbrechen: ${xe.message}`)}}const rn=k.find(L=>(L.state==="running"||L.state==="queued")&&L.group==="maintenance"),js=(h?(h.os>0?1:0)+(h.engine?1:0)+(h.swap?1:0):0)+(((jr=h==null?void 0:h.components)==null?void 0:jr.filter(L=>L.update===!0).length)??0),Nr=(w==null?void 0:w.backups)??[];return d.jsxs(d.Fragment,{children:[d.jsx("div",{className:Ee("fixed inset-0 bg-black/60 backdrop-blur-sm z-50 transition-opacity duration-300",r?"opacity-100 pointer-events-auto":"opacity-0 pointer-events-none"),onClick:s}),d.jsxs("div",{className:Ee("fixed inset-y-0 right-0 w-full sm:w-[640px] bg-card/85 backdrop-blur-xl border-l border-border/60 shadow-2xl z-50 flex flex-col transform transition-transform duration-300 ease-in-out font-sans text-foreground",r?"translate-x-0":"translate-x-full"),children:[d.jsxs("div",{className:"flex h-16 shrink-0 items-center justify-between border-b border-border/40 px-6",children:[d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx(Np,{className:"h-4.5 w-4.5 text-primary"}),d.jsx("h2",{className:"text-sm font-semibold tracking-wide uppercase font-space",children:"OS-Zentrale & Pflege"})]}),d.jsx("button",{onClick:s,className:"flex h-8 w-8 items-center justify-center rounded-lg border border-border/40 text-muted-foreground hover:bg-accent transition-colors",children:d.jsx(dl,{className:"h-4 w-4"})})]}),d.jsx("div",{className:"flex border-b border-border/40 px-6",children:["maintenance","logs","settings"].map(L=>d.jsx("button",{onClick:()=>G(L),className:Ee("flex-1 py-3 text-xs font-semibold uppercase tracking-wider border-b-2 text-center transition-all",K===L?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground"),children:L==="maintenance"?"System-Wartung":L==="logs"?"System-Logs":"Einstellungen"},L))}),d.jsxs("div",{className:"flex-1 overflow-y-auto p-6 space-y-6",children:[K==="maintenance"&&d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:"space-y-2.5",children:[d.jsxs("div",{className:"flex items-center justify-between",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Updates"}),d.jsxs("div",{className:"flex items-center gap-3",children:[js>0&&d.jsxs("button",{onClick:de,disabled:!!rn,className:"flex items-center gap-1 rounded-md border border-primary/40 bg-primary/10 px-2 py-1 text-[10px] font-bold text-primary transition-colors hover:bg-primary/20 disabled:opacity-50",children:[d.jsx(Dy,{className:"h-3 w-3"})," Alle aktualisieren (",js,")"]}),d.jsxs("button",{onClick:ye,disabled:ue||!!rn,className:"flex items-center gap-1 text-[10px] font-semibold text-primary hover:text-primary/80 transition-colors disabled:opacity-50",children:[d.jsx(ss,{className:Ee("h-3 w-3",ue&&"animate-spin")})," Nach Updates suchen"]})]})]}),(h==null?void 0:h.last_check)&&d.jsxs("div",{className:"text-[9px] text-muted-foreground -mt-1",children:["Zuletzt gesucht: ",ne(h.last_check)]}),rn&&d.jsxs("div",{className:"flex items-center gap-2 rounded-lg border border-amber-500/30 bg-amber-500/10 px-3 py-2 text-[11px] text-amber-300",children:[d.jsx(ss,{className:"h-3.5 w-3.5 shrink-0 animate-spin"}),d.jsxs("span",{children:["Update läuft: ",d.jsx("span",{className:"font-semibold",children:rn.label})," — bitte warten. Weitere Updates sind solange gesperrt."]})]}),d.jsxs("div",{className:"space-y-1.5",children:[d.jsx(vi,{icon:_p,iconClass:"text-cyan-400",name:"OS-Pakete (apt)",available:!!(h!=null&&h.os),status:h!=null&&h.os?`${h.os} verfügbar`:"aktuell",actionLabel:"Anzeigen",onAction:()=>W("os")}),d.jsx(vi,{icon:cl,iconClass:"text-violet-400",name:"Inferenz-Engine (llama.cpp)",available:!!(h!=null&&h.engine),status:h!=null&&h.engine?"Update verfügbar":"aktuell",actionLabel:"Anzeigen",onAction:()=>W("engine")}),d.jsx(vi,{icon:Pp,iconClass:"text-fuchsia-400",name:"Router (llama-swap)",available:!!(h!=null&&h.swap),status:h!=null&&h.swap?"Update verfügbar":"aktuell",actionLabel:"Anzeigen",onAction:()=>W("swap")}),(()=>{var xe;const L=(xe=h==null?void 0:h.components)==null?void 0:xe.find(ze=>ze.key==="hermes_agent");return d.jsx(vi,{icon:Ni,iconClass:"text-amber-400",name:"Hermes-Agent",available:(L==null?void 0:L.update)===!0,busy:Le,status:(L==null?void 0:L.update)===!0?`Update: ${L.latest}`:(L==null?void 0:L.reachable)===!1?"offline":"aktuell",actionLabel:"Anzeigen",onAction:()=>W("hermes")})})(),(Cs=h==null?void 0:h.model_list)==null?void 0:Cs.map(L=>d.jsx(vi,{icon:_y,iconClass:"text-emerald-400",name:`Modell · ${L.role}`,available:!0,status:L.title,actionLabel:"Upgrade",onAction:()=>we(L.repo,L.role)},L.role))]})]}),d.jsxs("div",{className:"space-y-2.5",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Dienste"}),d.jsxs("div",{className:"space-y-1.5",children:[Ne.length===0&&d.jsx("div",{className:"rounded-lg border border-dashed border-border/50 p-4 text-center text-xs text-muted-foreground",children:"Dienste-Liste wird geladen …"}),Ne.map(L=>d.jsx(lw,{label:L.name,system:L.scope==="system",ok:L.ok,busy:V[L.unit],onRestart:()=>Ns(L.unit),onLogs:()=>{P(L.unit),G("logs")}},L.unit))]})]}),d.jsxs("div",{className:"space-y-2.5",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Backup"}),d.jsxs("div",{className:"rounded-lg border border-border/50 bg-background/20 px-3 py-2.5 flex items-center gap-3",children:[d.jsxs("div",{className:"flex-1 min-w-0",children:[d.jsx("div",{className:"text-xs text-foreground truncate",children:Nr[0]?`Letztes: ${Nr[0].snapshot}`:"Noch kein Backup"}),d.jsxs("div",{className:"text-[10px] text-muted-foreground",children:[Nr.length," Snapshots · Wiederherstellen: Chronik → Zeitmaschine"]})]}),d.jsxs("button",{onClick:Sr,disabled:ke,className:"flex items-center gap-1.5 text-[11px] font-semibold rounded-lg px-2.5 py-1 bg-primary text-primary-foreground hover:opacity-90 transition-all cursor-pointer disabled:opacity-50 shrink-0",children:[d.jsx(Ry,{className:Ee("h-3.5 w-3.5",ke&&"animate-pulse")})," Snapshot"]})]}),ee&&d.jsx("div",{className:"text-[10px] font-mono text-primary bg-primary/5 p-2 rounded-lg border border-primary/20 break-all leading-normal",children:ee})]}),d.jsxs("div",{className:"space-y-2.5",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-red-400/80",children:"Gefahrenzone"}),d.jsxs("button",{onClick:Ge,className:"flex w-full items-center gap-3 p-3 rounded-lg border border-red-500/20 bg-red-500/5 hover:bg-red-500/10 text-red-400 transition-all text-left text-xs font-semibold",children:[d.jsx(Yy,{className:"h-4.5 w-4.5"}),d.jsxs("div",{children:[d.jsx("div",{children:"Host-System neu starten"}),d.jsx("div",{className:"text-[10px] text-red-400/80 font-normal",children:"Startet die ganze Box neu"})]})]})]}),d.jsxs("div",{className:"space-y-3",children:[d.jsxs("div",{className:"flex items-center justify-between",children:[d.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Hintergrund-Aufgaben"}),d.jsxs("span",{className:"text-[10px] font-mono bg-primary/10 text-primary px-1.5 py-0.5 rounded-full",children:[k.filter(L=>L.state==="running"||L.state==="queued").length," Aktiv"]})]}),d.jsx("div",{className:"space-y-3",children:k.length===0?d.jsx("div",{className:"text-xs text-muted-foreground border border-dashed border-border/60 rounded-xl p-6 text-center",children:"Aktuell keine aktiven Hintergrund-Jobs."}):k.map(L=>{const xe=L.state==="running"||L.state==="queued";return d.jsxs("div",{className:Ee("p-3 rounded-xl border transition-all duration-300",xe?"border-primary/40 bg-primary/5 shadow-md shadow-primary/5":"border-border/40 bg-background/20 opacity-80"),children:[d.jsxs("div",{className:"flex items-start justify-between gap-3",children:[d.jsxs("div",{className:"space-y-1",children:[d.jsxs("div",{className:"text-xs font-semibold flex items-center gap-1.5",children:[xe&&d.jsxs("span",{className:"flex h-2 w-2 relative",children:[d.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-primary opacity-75"}),d.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-primary"})]}),L.label]}),d.jsxs("div",{className:"text-[10px] font-mono text-muted-foreground uppercase flex items-center gap-2",children:[d.jsxs("span",{children:["ID: ",L.id]}),d.jsx("span",{children:"•"}),d.jsx("span",{className:Ee(L.state==="done"&&"text-emerald-400",L.state==="failed"&&"text-red-400",L.state==="running"&&"text-primary",L.state==="queued"&&"text-amber-400",L.state==="canceled"&&"text-muted-foreground"),children:L.state})]})]}),xe&&d.jsx("button",{onClick:()=>Er(L.id),className:"text-[10px] font-semibold text-red-400 hover:text-red-300 border border-red-500/20 bg-red-500/5 hover:bg-red-500/10 px-2 py-0.5 rounded transition-colors",children:"Abbrechen"})]}),L.state==="running"&&d.jsxs("div",{className:"mt-3 space-y-1",children:[d.jsx("div",{className:"w-full h-1.5 bg-muted rounded-full overflow-hidden",children:d.jsx("div",{className:"h-full bg-primary transition-all duration-500",style:{width:`${L.progress??0}%`}})}),d.jsxs("div",{className:"flex justify-between items-center text-[9px] font-mono text-muted-foreground",children:[d.jsxs("span",{children:[L.progress??0,"%"]}),L.done_bytes!=null&&L.total_bytes!=null&&d.jsxs("span",{children:[Eu(L.done_bytes)," / ",Eu(L.total_bytes),L.rate_bps!=null&&` (${Eu(L.rate_bps)}/s)`]}),L.eta_s!=null&&d.jsxs("span",{children:["ETA: ",L.eta_s,"s"]})]})]})]},L.id)})})]})]}),K==="logs"&&d.jsxs("div",{className:"flex flex-col h-full space-y-4",children:[d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx("select",{value:x,onChange:L=>P(L.target.value),className:"flex-1 h-9 px-3 text-xs bg-background/40 border border-border/60 rounded-lg outline-none text-foreground font-semibold",children:Ne.map(L=>d.jsxs("option",{value:L.unit,children:[L.name," (",L.scope==="system"?"systemd-root":"user",")"]},L.unit))}),d.jsxs("button",{onClick:()=>Ns(x),disabled:V[x],className:"flex h-9 px-3 items-center gap-1.5 text-xs font-semibold rounded-lg border border-border/60 bg-background/20 hover:border-primary/50 transition-colors disabled:opacity-50",title:"Dienst neu starten",children:[d.jsx(ss,{className:Ee("h-3.5 w-3.5",V[x]&&"animate-spin")}),"Restart"]})]}),d.jsx(fw,{service:x,text:_,loading:b,logStatus:A,onRefresh:()=>Q(x),onOpenSettings:()=>G("settings")})]}),K==="settings"&&d.jsx(hw,{open:r,showAlert:u})]})]}),ce&&d.jsx(pw,{detail:ce,maintenanceJob:rn,onClose:()=>Ce(null),onApply:se}),m]})}let Ku=[],qu=[];const Gu=new Set,Em=()=>Gu.forEach(r=>r());function Nm(r){return Gu.add(r),()=>{Gu.delete(r)}}function gw(r){Ku=[...Ku,r].slice(-40),Em()}function vw(r){qu=[...qu,r].slice(-40),Em()}const yw=()=>g.useSyncExternalStore(Nm,()=>Ku),xw=()=>g.useSyncExternalStore(Nm,()=>qu);function ww(){const{data:r,dataUpdatedAt:s}=vl(),{data:o,dataUpdatedAt:a}=bm(),u=g.useRef(null);g.useEffect(()=>{var f,m,h,y;r&&gw({t:Date.now(),cpu:((f=r.cpu)==null?void 0:f.percent)??0,ram:((m=r.ram)==null?void 0:m.percent)??0,gpu:((h=r.gpu)==null?void 0:h.busy_percent)??null,disk:((y=r.disk)==null?void 0:y.percent)??null})},[s]),g.useEffect(()=>{if(!o)return;const f=Date.now(),m=o.prompt_tokens,h=o.completion_tokens;if(u.current){const y=Math.max((f-u.current.t)/1e3,.001);vw({t:f,prompt:Math.max(0,(m-u.current.p)/y),completion:Math.max(0,(h-u.current.c)/y)})}u.current={p:m,c:h,t:f}},[a])}function kw(){var oe,ee,me,ke,le,Le;const{data:r,isError:s}=xm(),{data:o,isError:a}=hc(),{data:u}=km(),{data:f}=vl(),m=s||a,h=!!r&&!!o,y=Z=>{var ce;return(ce=o==null?void 0:o.services.find(Ce=>Ce.unit===Z))==null?void 0:ce.ok},k=Z=>!!(o!=null&&o.services.some(ce=>ce.unit===Z)),w=r==null?void 0:r.engine_reachable,x=(oe=r==null?void 0:r.brain)==null?void 0:oe.ready,P=((ee=r==null?void 0:r.brain)==null?void 0:ee.model)||((me=u==null?void 0:u.models.find(Z=>Z.role==="hermes"))==null?void 0:me.name)||"",_=[];m&&_.push({id:"mc2",label:"Steuerpult (MC2)",icon:cl,critical:!0,status:"down",detail:"Die Zentrale antwortet nicht — alle Anzeigen hier können veraltet sein. Läuft die Box? Deploy aktiv?"}),_.push((()=>{const Z={id:"brain",label:"Lucys Hirn",icon:Py,critical:!0};return h?w===!1?{...Z,status:"down",detail:"Die Motor-Maschine (Engine) läuft nicht — Lucy kann gerade gar nicht denken.",repair:{kind:"restart",service:"llama-swap",label:"Motor neu starten",needsSudo:!0}}:x===!1?{...Z,status:"down",detail:"Lucys Hirn ist gerade eingeschlafen — einmal aufwecken.",repair:P?{kind:"loadModel",model:P,label:"Hirn aufwecken"}:void 0}:{...Z,status:"ok",detail:"Wach und ansprechbar."}:{...Z,status:"loading",detail:"Wird geprüft …"}})()),_.push((()=>{const Z={id:"vision",label:"Lucys Augen",icon:jp,critical:!1};if(!h||!u)return{...Z,status:"loading",detail:"Wird geprüft …"};const ce=u.models.find(Ne=>Ne.role==="vision");return ce?(u.running??[]).includes(ce.name)?{...Z,status:"ok",detail:"Sieht gerade zu (geladen, solange Lucy sie nutzt)."}:{...Z,status:"ok",detail:"Augen ruhen — sie laden von selbst, sobald Lucy startet oder ein Bild kommt.",repair:{kind:"loadModel",model:ce.name,label:"Augen wecken"}}:{...Z,status:"warn",detail:"Kein Augen-Modell eingerichtet — Lucy kann keine Bilder ansehen."}})()),_.push((()=>{const Z={id:"memory",label:"Lucys Gedächtnis",icon:Cy,critical:!0},ce=y("hermes-gateway");return!h||ce===void 0?{...Z,status:"loading",detail:"Wird geprüft …"}:ce?{...Z,status:"ok",detail:"Hermes-Natives Gedächtnis aktiv (SQLite & Embeddings)."}:{...Z,status:"down",detail:"Lucy kann sich gerade nichts merken — das Gateway antwortet nicht.",repair:{kind:"restart",service:"hermes-gateway",label:"Gateway neu starten"}}})()),_.push((()=>{const Z={id:"gateway",label:"Verbindung (Gateway)",icon:oc,critical:!0},ce=r?r.gateway_reachable:y("mc2-gateway");if(!h||ce===void 0)return{...Z,status:"loading",detail:"Wird geprüft …"};const Ce=k("mc2-gateway")?"mc2-gateway":"mission-control-2";return ce?{...Z,status:"ok",detail:"Apps und IDEs können Lucy erreichen."}:{...Z,status:"down",detail:"Der Modell-Gateway antwortet nicht — Lucy und die IDEs erreichen kein Modell.",repair:{kind:"restart",service:Ce,label:"Gateway neu starten"}}})()),_.push((()=>{const Z={id:"steward",label:"Wächter (Steward)",icon:lc,critical:!1};return h?k("mc2-steward")?y("mc2-steward")?{...Z,status:"ok",detail:"Wacht über Warm-Set, Dienste und Gedächtnis."}:{...Z,status:"warn",detail:"Der Wächter schläft — niemand meldet gerade Ausfälle oder wärmt Modelle nach.",repair:{kind:"restart",service:"mc2-steward",label:"Wächter neu starten"}}:{...Z,status:"ok",detail:"Auf dieser Installation nicht eingerichtet."}:{...Z,status:"loading",detail:"Wird geprüft …"}})()),_.push((()=>{const Z={id:"agent",label:"Lucys Agent (Hermes)",icon:Ni,critical:!0},ce=y("hermes-gateway");return!h||ce===void 0?{...Z,status:"loading",detail:"Wird geprüft …"}:ce?{...Z,status:"ok",detail:"Lucy ist bereit zu reden und zu handeln."}:{...Z,status:"down",detail:"Lucys Agent ist offline — sie reagiert gerade nicht.",repair:{kind:"restart",service:"hermes-gateway",label:"Agent neu starten"}}})()),_.push((()=>{const Z={id:"voice",label:"Lucys Stimme",icon:Zy,critical:!1},ce=y("voice-service");return!h||ce===void 0?{...Z,status:"loading",detail:"Wird geprüft …"}:ce?{...Z,status:"ok",detail:"Lucy kann hören und sprechen."}:{...Z,status:"warn",detail:"Sprechen ist gerade aus — Tippen geht weiter normal.",repair:{kind:"restart",service:"voice-service",label:"Stimme neu starten"}}})());const D=((ke=f==null?void 0:f.ram)==null?void 0:ke.total)??0,b=((le=f==null?void 0:f.ram)==null?void 0:le.used)??0,R=((Le=f==null?void 0:f.ram)==null?void 0:Le.percent)??(D>0?Math.min(100,b/D*100):0),A=1024**3,I=D?R>=93?{status:"full",usedGb:b/A,totalGb:D/A,pct:R,text:"Speicher fast voll — Lucy könnte langsamer werden."}:R>=85?{status:"warn",usedGb:b/A,totalGb:D/A,pct:R,text:"Speicher gut gefüllt — noch okay."}:{status:"ok",usedGb:b/A,totalGb:D/A,pct:R,text:"Genug Speicher frei."}:{status:"unknown",usedGb:0,totalGb:0,pct:0,text:"Speicher-Auslastung unbekannt."},V=_.some(Z=>Z.status==="loading"),z=_.filter(Z=>Z.critical&&Z.status==="down"),K=_.filter(Z=>Z.status==="warn"||!Z.critical&&Z.status==="down"),G=I.status==="full";return{verdict:V&&!z.length?"loading":z.length?"problem":K.length||G?"warn":"gut",checks:_,memory:I,problems:z,warns:K,unreachable:m}}const bw={ok:"bg-emerald-500",warn:"bg-amber-500",alert:"bg-red-500",muted:"bg-muted-foreground/40",loading:"bg-muted-foreground/40 animate-pulse"},Sw={ok:"hover:border-emerald-500/40",warn:"hover:border-amber-500/50",alert:"hover:border-red-500/50",muted:"hover:border-primary/40",loading:"hover:border-border/60"};function yi({icon:r,title:s,value:o,unit:a,tone:u="muted",hint:f,onClick:m}){return d.jsxs("button",{onClick:m,className:Ee("group relative flex flex-col items-start mc-card p-5 text-left cursor-pointer",Sw[u]),children:[d.jsxs("div",{className:"mb-4 flex w-full items-center justify-between",children:[d.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-xl border border-border/40 bg-background/30 text-foreground/80 transition-colors group-hover:text-primary",children:d.jsx(r,{className:"h-5 w-5"})}),d.jsx("span",{className:Ee("h-2.5 w-2.5 rounded-full ring-2 ring-black/40",bw[u]),title:f})]}),d.jsxs("div",{className:"flex items-baseline gap-1.5",children:[d.jsx("span",{className:"text-2xl font-bold tracking-tight text-foreground font-space tabular-nums",children:o}),a&&d.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:a})]}),d.jsxs("div",{className:"mt-1 flex w-full items-center justify-between",children:[d.jsx("span",{className:"text-sm font-semibold text-foreground/90",children:s}),d.jsx(wi,{className:"h-4 w-4 text-muted-foreground/40 transition-all group-hover:translate-x-0.5 group-hover:text-primary"})]}),f&&d.jsx("span",{className:"mt-0.5 text-[11px] text-muted-foreground",children:f})]})}function Ew(){const{data:r,error:s}=vl(),o=yw();return{sys:r,hist:o,error:s}}const Nw=g.lazy(()=>Wt(()=>import("./LiveAreaChartImpl-Bb72EW29.js"),__vite__mapDeps([0,1])));function jm(r){return d.jsx(g.Suspense,{fallback:d.jsx(jw,{height:r.height??176}),children:d.jsx(Nw,{...r})})}function jw({height:r}){return d.jsx("div",{style:{height:r},className:"flex w-full items-end","aria-hidden":"true",children:d.jsx("div",{className:"h-px w-full bg-border/40"})})}const Cm={"1h":60,"24h":1440},Gh={live:"Live","1h":"1 h","24h":"24 h"};function _m({value:r,onChange:s}){return d.jsx("div",{className:"flex rounded-lg border border-border/40 bg-background/30 p-0.5",children:Object.keys(Gh).map(o=>d.jsx("button",{onClick:()=>s(o),className:Ee("rounded-md px-2 py-0.5 text-[9px] font-bold uppercase tracking-wide transition-all cursor-pointer",r===o?"bg-primary text-primary-foreground":"text-muted-foreground hover:text-foreground"),children:Gh[o]},o))})}const Cw=[{key:"cpu",label:"CPU",color:"#2dd4bf"},{key:"ram",label:"RAM",color:"#38bdf8"},{key:"gpu",label:"GPU",color:"#a78bfa"},{key:"disk",label:"Disk",color:"#fbbf24"}];function _w(){var w,x,P,_;const{sys:r,hist:s}=Ew(),[o,a]=g.useState("live"),u=wm(o==="live"?60:Cm[o],o!=="live"),f=g.useMemo(()=>{var D;return o==="live"?s:(((D=u.data)==null?void 0:D.points)??[]).map(b=>({t:b.t*1e3,cpu:b.cpu,ram:b.ram,gpu:b.gpu,disk:b.disk}))},[o,s,u.data]),m=!!(r!=null&&r.gpu&&r.gpu.busy_percent!=null&&r.gpu.gtt_used!=null&&r.gpu.gtt_total!=null),h=Cw.filter(D=>D.key!=="gpu"||m),y={cpu:(w=r==null?void 0:r.cpu)==null?void 0:w.percent,ram:(x=r==null?void 0:r.ram)==null?void 0:x.percent,gpu:m?r.gpu.busy_percent:null,disk:(P=r==null?void 0:r.disk)==null?void 0:P.percent},k={cpu:(_=r==null?void 0:r.cpu)!=null&&_.cores?`${r.cpu.cores} Cores`:"",ram:r?`${ts(r.ram.used)}/${ts(r.ram.total)} GB`:"",gpu:m?`${ts(r.gpu.gtt_used)}/${ts(r.gpu.gtt_total)} GB`:"",disk:r!=null&&r.disk?`${ts(r.disk.used)}/${ts(r.disk.total)} GB`:""};return d.jsxs("div",{className:"flex flex-col justify-between mc-card p-5",children:[d.jsxs("div",{children:[d.jsxs("div",{className:"mb-3 flex items-center gap-2",children:[d.jsx(Np,{className:"h-4.5 w-4.5 text-primary"}),d.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"System-Status"}),o==="live"&&d.jsxs("span",{className:"ml-1 inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground/70",children:[d.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"})," live"]}),d.jsx("div",{className:"ml-auto",children:d.jsx(_m,{value:o,onChange:a})})]}),r?d.jsxs(d.Fragment,{children:[d.jsx("div",{className:"mb-2 grid grid-cols-2 gap-x-4 gap-y-1.5",children:h.map(D=>d.jsxs("div",{className:"flex min-w-0 items-center gap-1.5",children:[d.jsx("span",{className:"h-2 w-2 shrink-0 rounded-full",style:{background:D.color}}),d.jsx("span",{className:"shrink-0 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",children:D.label}),d.jsxs("span",{className:"shrink-0 font-mono text-xs font-bold tabular-nums text-foreground",children:[Math.round(y[D.key]??0),"%"]}),k[D.key]&&d.jsx("span",{className:"truncate font-mono text-[10px] text-muted-foreground/60",children:k[D.key]})]},D.key))}),o!=="live"&&f.length===0&&d.jsx("div",{className:"flex h-44 items-center justify-center text-xs text-muted-foreground",children:u.isLoading?"Verlauf wird geladen …":"Noch kein Verlauf — der Sammler baut die Historie gerade erst auf."}),(o==="live"||f.length>0)&&d.jsx(jm,{data:f,series:h,unit:"%",yMode:"percent",height:176,showTime:!0})]}):d.jsx("div",{className:"flex h-44 items-center justify-center text-xs text-muted-foreground",children:"Lade Systemdaten…"})]}),(r==null?void 0:r.temp)&&(r.temp.cpu||r.temp.gpu)&&d.jsxs("div",{className:"mt-3 flex gap-4 border-t border-border/30 pt-3 font-mono text-xs text-muted-foreground/80",children:[r.temp.cpu!=null&&d.jsxs("span",{children:["CPU Temp: ",r.temp.cpu," °C"]}),r.temp.gpu!=null&&d.jsxs("span",{children:["GPU Temp: ",r.temp.gpu," °C"]})]})]})}const Ss=[{key:"stt_ms",label:"STT",color:"#f59e0b"},{key:"vision_ms",label:"Sehen",color:"#a78bfa"},{key:"hirn_ms",label:"Hirn",color:"#2dd4bf"},{key:"gen_ms",label:"Antwort",color:"#60a5fa"}],ki=r=>r==null?"–":`${(r/1e3).toLocaleString("de-DE",{minimumFractionDigits:1,maximumFractionDigits:1})} s`;function Pw(r){const s=Math.max(0,Date.now()/1e3-r);return s<60?`vor ${Math.round(s)} s`:s<3600?`vor ${Math.round(s/60)} min`:`vor ${Math.round(s/3600)} h`}function Zu(r){return Ss.reduce((s,o)=>s+(r[o.key]??0),0)}function Rw(r){let s=null;for(const o of Ss){const a=r[o.key];a!=null&&(s==null||a>s.ms)&&(s={label:o.label,color:o.color,ms:a})}return s}function Mw({t:r,scale:s}){const o=Ss.map(a=>`${a.label} ${ki(r[a.key])}`).join(" · ");return d.jsxs("div",{className:"flex items-center gap-2.5",children:[d.jsx("span",{className:"w-14 shrink-0 text-right font-mono text-[10px] text-muted-foreground/60",children:Pw(r.ts)}),d.jsxs("div",{className:"relative h-4 flex-1 overflow-hidden rounded-sm bg-muted/25",title:o,children:[d.jsx("div",{className:"absolute inset-0 flex",children:Ss.map(a=>{const u=r[a.key];return!u||u<=0?null:d.jsx("div",{style:{width:`${u/s*100}%`,background:a.color},className:"h-full first:rounded-l-sm"},a.key)})}),r.error&&d.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-rose-500/15 text-[10px] font-semibold text-rose-300",children:"Fehler"})]}),d.jsx("span",{className:"w-12 shrink-0 text-right font-mono text-[11px] font-semibold tabular-nums text-foreground",children:r.error?"–":ki(Zu(r))})]})}function Ow(){const{data:r}=rw(12),s=r??[],o=Math.max(1,...s.map(f=>Zu(f))),a=s[0],u=a?Rw(a):null;return d.jsxs("div",{className:"mc-card p-5",children:[d.jsxs("div",{className:"mb-3 flex items-start justify-between gap-3",children:[d.jsxs("div",{children:[d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx(Uy,{className:"h-4.5 w-4.5 text-primary"}),d.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"Latenz je Turn"}),d.jsxs("span",{className:"ml-1 inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground/70",children:[d.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"})," live"]})]}),a?d.jsxs("div",{className:"mt-2 flex items-baseline gap-2",children:[d.jsx("span",{className:`font-space text-3xl font-bold tracking-tight tabular-nums ${a.error?"text-rose-400":"text-foreground"}`,children:a.error?"Fehler":ki(Zu(a))}),d.jsxs("span",{className:"text-xs text-muted-foreground",children:["letzter Turn",!a.error&&u&&d.jsxs(d.Fragment,{children:[" · Täter: ",d.jsx("span",{style:{color:u.color},className:"font-semibold",children:u.label})," ",ki(u.ms)]})]})]}):d.jsx("div",{className:"mt-2 text-xs text-muted-foreground",children:"Noch kein Voice-Turn aufgezeichnet."}),a&&!a.error&&d.jsx("div",{className:"mt-0.5 font-mono text-[11px] text-muted-foreground/70",children:Ss.filter(f=>a[f.key]!=null).map(f=>`${f.label} ${ki(a[f.key])}`).join(" · ")})]}),d.jsx("div",{className:"flex shrink-0 flex-col items-end gap-1 pt-1",children:Ss.map(f=>d.jsxs("div",{className:"flex items-center gap-1.5",children:[d.jsx("span",{className:"h-2 w-2 rounded-full",style:{background:f.color}}),d.jsx("span",{className:"text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",children:f.label})]},f.key))})]}),s.length>0?d.jsx("div",{className:"space-y-1.5",children:s.map(f=>d.jsx(Mw,{t:f,scale:o},f.id))}):d.jsx("div",{className:"flex h-[120px] items-center justify-center px-6 text-center text-xs text-muted-foreground",children:"Sprich einmal mit Lucy — dann erscheint hier der Zeit-Wasserfall pro Turn, damit man den einen Hänger sofort sieht."}),d.jsx("div",{className:"mt-3 border-t border-border/30 pt-2 text-[10px] leading-relaxed text-muted-foreground/70",children:'„Hirn" = Zeit bis zum ersten Wort (Agent + Gedächtnis-Suche + Modell); Tool-Runden stecken in „Antwort". Reine Telegram-Turns laufen an MC2 vorbei und erscheinen hier nicht.'})]})}const Zh=[{key:"prompt",label:"Prompt",color:"#f59e0b"},{key:"completion",label:"Antwort",color:"#2dd4bf"}];function Tw(){const{data:r}=bm(),s=xw(),[o,a]=g.useState("live"),u=wm(o==="live"?60:Cm[o],o!=="live"),f=g.useMemo(()=>{var w;if(o==="live")return s;const y=((w=u.data)==null?void 0:w.points)??[],k=[];for(let x=1;x<y.length;x++){const P=y[x-1],_=y[x];if(P.tp==null||_.tp==null||P.tc==null||_.tc==null)continue;const D=Math.max(_.t-P.t,1);k.push({t:_.t*1e3,prompt:Math.max(0,(_.tp-P.tp)/D),completion:Math.max(0,(_.tc-P.tc)/D)})}return k},[o,s,u.data]),m=s[s.length-1],h=m?Math.round(m.prompt+m.completion):0;return d.jsxs("div",{className:"mc-card p-5",children:[d.jsxs("div",{className:"mb-3 flex items-start justify-between gap-3",children:[d.jsxs("div",{children:[d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx(jy,{className:"h-4.5 w-4.5 text-primary"}),d.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"Token-Durchsatz"}),o==="live"&&d.jsxs("span",{className:"ml-1 inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground/70",children:[d.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"})," live"]})]}),r&&d.jsxs("div",{className:"mt-2 flex items-baseline gap-2",children:[d.jsx("span",{className:"font-space text-3xl font-bold tracking-tight text-foreground tabular-nums",children:h.toLocaleString("de-DE")}),d.jsx("span",{className:"text-xs text-muted-foreground",children:"tok/s aktuell"})]}),r&&d.jsxs("div",{className:"mt-0.5 space-y-0.5 font-mono text-[11px] text-muted-foreground/70",children:[d.jsxs("div",{children:[r.total_tokens.toLocaleString("de-DE")," Tokens gesamt · ",d.jsxs("span",{className:"text-emerald-400/90",children:[r.saved_eur.toLocaleString("de-DE",{minimumFractionDigits:2})," € gespart"]})]}),d.jsxs("div",{className:"text-muted-foreground/55",children:["Input ",r.prompt_tokens.toLocaleString("de-DE")," · Output ",r.completion_tokens.toLocaleString("de-DE")]})]})]}),d.jsxs("div",{className:"flex shrink-0 flex-col items-end gap-2 pt-1",children:[d.jsx(_m,{value:o,onChange:a}),d.jsx("div",{className:"flex flex-col items-end gap-1.5",children:Zh.map(y=>d.jsxs("div",{className:"flex items-center gap-1.5",children:[d.jsx("span",{className:"h-2 w-2 rounded-full",style:{background:y.color}}),d.jsx("span",{className:"text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",children:y.label}),d.jsx("span",{className:"font-mono text-xs font-bold tabular-nums text-foreground",children:Math.round((m==null?void 0:m[y.key])??0)})]},y.key))})]})]}),o!=="live"&&f.length===0?d.jsx("div",{className:"flex h-[150px] items-center justify-center text-xs text-muted-foreground",children:u.isLoading?"Verlauf wird geladen …":"Noch kein Verlauf — der Sammler baut die Historie gerade erst auf."}):r?d.jsx(jm,{data:f,series:Zh,unit:" tok/s",yMode:"auto",height:150,showTime:!0}):d.jsx("div",{className:"flex h-[150px] items-center justify-center text-xs text-muted-foreground",children:"Lade Durchsatz…"}),d.jsx("div",{className:"mt-2 border-t border-border/30 pt-2 text-[10px] text-muted-foreground/70",children:"Durchsatz aus dem Gateway abgeleitet (Prefill vs. Generierung). Flach bei Leerlauf."})]})}const al=r=>window.dispatchEvent(new CustomEvent("open-system-drawer",{detail:{tab:r}}));function Lw({onNavigate:r}){var Z,ce,Ce,Ne;const{data:s}=km(),{data:o}=hc(),{data:a}=Sm(),{data:u}=iw(),{data:f}=ow(),{data:m}=ew(),{data:h}=tw(),y=kw(),{showAlert:k,dialogElement:w}=ym(),x=ul(),[P,_]=g.useState({});async function D(F,ne){_(Q=>({...Q,[F]:!0}));try{if(ne.kind==="loadModel")await Se(`/api/models/${encodeURIComponent(ne.model)}/load`,{method:"POST"});else{const Q=await Se("/api/maintenance/restart",{method:"POST",body:JSON.stringify({service:ne.service})});Q.ok||k("Reparatur nicht ganz geklappt",(Q.err||"Unbekannter Fehler")+(ne.needsSudo?`
|
||
|
||
Tipp: Dafür wird evtl. das Box-Passwort gebraucht (oben rechts hinterlegen).`:""))}x.invalidateQueries({queryKey:Pe.health}),x.invalidateQueries({queryKey:Pe.services}),x.invalidateQueries({queryKey:Pe.models})}catch(Q){k("Reparatur fehlgeschlagen",String((Q==null?void 0:Q.message)||Q))}finally{_(Q=>({...Q,[F]:!1}))}}const b=((Z=s==null?void 0:s.running)==null?void 0:Z.length)??0,R=(o==null?void 0:o.services.filter(F=>F.ok).length)??0,A=(o==null?void 0:o.services.length)??0,I=A-R,V=(a?(a.os>0?1:0)+(a.engine>0?1:0)+(a.swap>0?1:0)+(a.models>0?1:0):0)+(((ce=a==null?void 0:a.components)==null?void 0:ce.filter(F=>F.update===!0).length)??0),z=m!=null&&m.available?m.open_count:0,K=h!=null&&h.available?h.items.filter(F=>F.status==="blocked").length:0,G=f?[f.gateway,f.memory,f.desktop_gateway]:[],ue=G.filter(F=>F==null?void 0:F.ok).length,oe=f?f.gateway.ok?f.memory.ok?f.desktop_gateway.ok?"":"Desktop-Gateway":"Gedächtnis-Leitung":"Modell-Leitung":"",ee=(Ce=s==null?void 0:s.models)==null?void 0:Ce.find(F=>F.role==="hermes"),me=ee!=null&&ee.name?(Ne=ee.name.split("/").pop())==null?void 0:Ne.replace(/\.gguf$/i,""):"",ke=o==null?void 0:o.services.filter(F=>!F.ok).map(F=>F.name).join(", "),le=a?[a.os>0&&"OS",a.engine>0&&"Engine",a.swap>0&&"Swap",a.models>0&&"Modelle"].filter(Boolean):[],Le=le.length>0?le.join(" + "):"";return d.jsxs("div",{className:"space-y-6",children:[d.jsxs("div",{children:[d.jsx("h1",{className:"bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text font-space text-2xl font-bold tracking-tight text-transparent",children:"Cockpit"}),d.jsx("p",{className:"text-sm text-muted-foreground",children:"Deine Box auf einen Blick — Details hinter jeder Kachel."})]}),d.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6 items-start",children:[d.jsxs("div",{className:"lg:col-span-2 space-y-6",children:[d.jsx(Dw,{verdict:y.verdict,memory:y.memory,warns:y.warns,problems:y.problems}),d.jsxs("section",{children:[d.jsx(Nu,{children:"Leistung"}),d.jsx("div",{className:"grid gap-4 md:grid-cols-1",children:d.jsx(_w,{})}),d.jsx("div",{className:"mt-4",children:d.jsx(Ow,{})}),d.jsx("div",{className:"mt-4",children:d.jsx(Tw,{})})]}),d.jsxs("section",{children:[d.jsx(Nu,{children:"Bereiche"}),d.jsxs("div",{className:"grid gap-4 grid-cols-2 md:grid-cols-3",children:[d.jsx(yi,{icon:ic,title:"Auftragsbuch",value:m!=null&&m.available?z:"—",unit:z===1?"Vorschlag":"Vorschläge",tone:m?K>0||z>0?"warn":"ok":"loading",hint:K>0?`${K} Karte${K===1?"":"n"} wartet auf deine Antwort`:z>0?`${z} offene Patches`:"Keine ausstehenden Vorschläge",onClick:()=>r("auftraege")}),d.jsx(yi,{icon:Sp,title:"Modelle",value:b,unit:"warm",tone:b>0?"ok":"muted",hint:me?`Hirn: ${me}`:"Kein Hermes-Modell geladen",onClick:()=>r("models")}),d.jsx(yi,{icon:cl,title:"Dienste",value:o?`${R}/${A}`:"…",unit:"laufen",tone:o?I>0?"warn":"ok":"loading",hint:ke?`Ausfall: ${ke}`:"Alle Dienste online",onClick:()=>al("maintenance")}),d.jsx(yi,{icon:lc,title:"Updates",value:a?V>0?V:"0":"…",unit:V>0?"bereit":"aktuell",tone:a?V>0?"warn":"ok":"loading",hint:V>0?`Verfügbar: ${Le}`:"Alles auf dem neuesten Stand",onClick:()=>al("maintenance")}),d.jsx(yi,{icon:oc,title:"Verbinden",value:f?`${ue}/${G.length}`:"…",unit:"Leitungen",tone:f?ue===G.length?"ok":"warn":"loading",hint:oe?`Gestört: ${oe}`:"Hermes Desktop & IDEs bereit",onClick:()=>r("connect")})]})]})]}),d.jsxs("div",{className:"space-y-6",children:[d.jsx(Aw,{problems:y.problems,pendingCount:V,openAuftraege:z,blockedIdeen:K,busy:P,onRepair:D,onNavigate:r}),d.jsxs("section",{children:[d.jsx(Nu,{children:"Werkzeuge & Diagnose"}),d.jsx(zw,{agent:u,svcErrors:I,onNavigate:r})]})]})]}),w]})}function Nu({children:r}){return d.jsx("p",{className:"mb-2 ml-0.5 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground/60",children:r})}function Dw({verdict:r,memory:s,warns:o,problems:a}){const u=o.length?`${o[0].label}: ${o[0].detail}${o.length>1?` (+${o.length-1} weitere)`:""}`:s.status==="full"?s.text:"Nichts Schlimmes — nur ein Hinweis.",f=a.length?`${a[0].label}: ${a[0].detail}${a.length>1?` (+${a.length-1} weitere)`:""}`:"Ein wichtiger Dienst hakt.",m={loading:{ring:"border-border/60 bg-card/45",icon:ji,iconCls:"text-muted-foreground animate-spin",title:"Box wird geprüft …",sub:"Einen Moment."},gut:{ring:"border-emerald-500/40 bg-emerald-500/5",icon:Vy,iconCls:"text-emerald-400",title:"Box gesund",sub:"Alle wichtigen Dienste laufen."},warn:{ring:"border-amber-500/40 bg-amber-500/5",icon:Ci,iconCls:"text-amber-400",title:"Kleinigkeit an der Box",sub:u},problem:{ring:"border-red-500/50 bg-red-500/5",icon:Ci,iconCls:"text-red-400",title:"Box braucht Hilfe",sub:f}}[r],h=m.icon,y={ok:"text-emerald-400",warn:"text-amber-400",full:"text-red-400",unknown:"text-muted-foreground"}[s.status],k={ok:"bg-emerald-500",warn:"bg-amber-500",full:"bg-red-500",unknown:"bg-muted-foreground/40"}[s.status];return d.jsxs("div",{className:Ee("flex flex-col gap-4 rounded-2xl border p-5 shadow-lg shadow-black/15 backdrop-blur-md transition-colors sm:flex-row sm:items-center sm:justify-between h-full",m.ring),children:[d.jsxs("div",{className:"flex items-center gap-3",children:[d.jsx("div",{className:"flex h-11 w-11 shrink-0 items-center justify-center rounded-xl border border-border/40 bg-background/30",children:d.jsx(h,{className:Ee("h-6 w-6",m.iconCls)})}),d.jsxs("div",{className:"min-w-0",children:[d.jsx("h2",{className:"text-base font-bold tracking-tight text-foreground",children:m.title}),d.jsx("p",{className:"text-xs text-muted-foreground",children:m.sub})]})]}),d.jsxs("div",{className:"w-full max-w-[16rem] rounded-xl border border-border/30 bg-background/20 p-3",children:[d.jsxs("div",{className:"mb-1.5 flex items-center justify-between text-[11px]",children:[d.jsxs("span",{className:"flex items-center gap-1.5 font-semibold uppercase tracking-wider text-muted-foreground",children:[d.jsx(By,{className:"h-3.5 w-3.5"})," Speicher"]}),d.jsx("span",{className:Ee("font-mono font-bold",y),children:s.status==="unknown"?"—":`${s.usedGb.toFixed(1)} / ${s.totalGb.toFixed(1)} GB`})]}),d.jsx("div",{className:"h-2 w-full overflow-hidden rounded-full border border-border/30 bg-background/50",children:d.jsx("div",{className:Ee("h-full rounded-full transition-all duration-500",k),style:{width:`${s.pct}%`}})})]})]})}function Aw({problems:r,pendingCount:s,openAuftraege:o,blockedIdeen:a,busy:u,onRepair:f,onNavigate:m}){const h=s>0,y=o>0,k=a>0,w=r.length===0&&!h&&!y&&!k;return d.jsx("div",{className:"h-full flex flex-col justify-between",children:w?d.jsxs("div",{className:"flex items-center gap-3 rounded-2xl border border-emerald-500/25 bg-emerald-500/5 p-4 h-full",children:[d.jsx(My,{className:"h-5 w-5 shrink-0 text-emerald-400"}),d.jsxs("div",{children:[d.jsx("p",{className:"text-sm font-semibold text-foreground",children:"Nichts zu tun"}),d.jsx("p",{className:"text-xs text-muted-foreground",children:"Alles läuft. Du musst gerade nichts abnicken."})]})]}):d.jsxs("div",{className:"space-y-2 h-full flex flex-col justify-center",children:[r.map(x=>d.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-3 rounded-2xl border border-red-500/25 bg-red-500/5 p-4",children:[d.jsxs("div",{className:"flex min-w-0 items-center gap-3 w-full",children:[d.jsx("span",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-lg border border-red-500/30 bg-background/30 text-red-300",children:d.jsx(x.icon,{className:"h-4.5 w-4.5"})}),d.jsxs("div",{className:"min-w-0 flex-1",children:[d.jsx("p",{className:"text-sm font-bold text-foreground",children:x.label}),d.jsx("p",{className:"truncate text-xs text-muted-foreground",children:x.detail})]})]}),x.repair&&d.jsxs("button",{onClick:()=>x.repair&&f(x.id,x.repair),disabled:!!u[x.id],className:"flex h-9 shrink-0 items-center gap-1.5 rounded-lg border border-red-500/40 bg-red-500/10 px-3 text-[11px] font-bold uppercase tracking-wide text-red-300 transition-all hover:bg-red-500/20 cursor-pointer disabled:opacity-60 w-full sm:w-auto justify-center",children:[u[x.id]?d.jsx(ji,{className:"h-3.5 w-3.5 animate-spin"}):d.jsx(r0,{className:"h-3.5 w-3.5"}),x.repair.label]})]},x.id)),k&&d.jsxs("button",{onClick:()=>m("auftraege"),className:"flex w-full items-center justify-between gap-3 rounded-2xl border border-red-500/30 bg-red-500/5 p-4 text-left transition-all hover:bg-red-500/10 cursor-pointer",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[d.jsx("span",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-lg border border-red-500/30 bg-background/30 text-red-300",children:d.jsx(Ep,{className:"h-4.5 w-4.5"})}),d.jsxs("div",{children:[d.jsxs("p",{className:"text-sm font-bold text-foreground",children:[a," Karte",a===1?"":"n"," braucht deine Antwort"]}),d.jsx("p",{className:"text-xs text-muted-foreground",children:"Die Box hängt an einer Frage und wartet auf dich."})]})]}),d.jsx(wi,{className:"h-4 w-4 shrink-0 text-red-300/70"})]}),y&&d.jsxs("button",{onClick:()=>m("auftraege"),className:"flex w-full items-center justify-between gap-3 rounded-2xl border border-primary/30 bg-primary/5 p-4 text-left transition-all hover:bg-primary/10 cursor-pointer",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[d.jsx("span",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-lg border border-primary/30 bg-background/30 text-primary",children:d.jsx(ic,{className:"h-4.5 w-4.5"})}),d.jsxs("div",{children:[d.jsxs("p",{className:"text-sm font-bold text-foreground",children:[o," Vorschl",o===1?"ag":"äge"," im Auftragsbuch"]}),d.jsx("p",{className:"text-xs text-muted-foreground",children:"Annehmen oder ablehnen."})]})]}),d.jsx(wi,{className:"h-4 w-4 shrink-0 text-primary/70"})]}),h&&d.jsxs("button",{onClick:()=>al("maintenance"),className:"flex w-full items-center justify-between gap-3 rounded-2xl border border-amber-500/30 bg-amber-500/5 p-4 text-left transition-all hover:bg-amber-500/10 cursor-pointer",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[d.jsx("span",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-lg border border-amber-500/30 bg-background/30 text-amber-300",children:d.jsx(lc,{className:"h-4.5 w-4.5"})}),d.jsxs("div",{children:[d.jsxs("p",{className:"text-sm font-bold text-foreground",children:[s," Update",s===1?"":"s"," bereit"]}),d.jsx("p",{className:"text-xs text-muted-foreground",children:"Ansehen und entscheiden."})]})]}),d.jsx(wi,{className:"h-4 w-4 shrink-0 text-amber-300/70"})]})]})})}function zw({agent:r,svcErrors:s,onNavigate:o}){const a=[{label:"Hermes Agent",status:r?r.gateway_reachable?"Bereit":"Offline":"…",tone:r?r.gateway_reachable?"ok":"alert":"loading",action:()=>o("agent")},{label:"Konsole (Box-Shell)",status:r?r.box_console_reachable?"Bereit":"Offline":"…",tone:r?r.box_console_reachable?"ok":"warn":"loading",action:()=>o("konsole")},{label:"Systemlogs & Diagnose",status:s>0?`${s} Fehler`:"Keine Fehler",tone:s>0?"alert":"ok",action:()=>al("logs")},{label:"Wissens-Vault",status:"Öffnen",tone:"muted",action:()=>o("wissen")},{label:"Chronik & Zeitmaschine",status:"Öffnen",tone:"muted",action:()=>o("chronik")}];return d.jsx("div",{className:"rounded-2xl border border-border/60 bg-card/30 p-4 space-y-3 shadow-sm",children:d.jsx("div",{className:"divide-y divide-border/20",children:a.map((u,f)=>{const m={loading:"bg-muted-foreground/45 animate-pulse",ok:"bg-emerald-500 shadow-[0_0_8px_rgba(16,185,129,0.4)]",warn:"bg-amber-500 shadow-[0_0_8px_rgba(245,158,11,0.4)]",alert:"bg-red-500 shadow-[0_0_8px_rgba(239,68,68,0.4)]",muted:"bg-muted-foreground/30"}[u.tone];return d.jsxs("button",{onClick:u.action,className:"w-full py-2.5 px-1.5 flex items-center justify-between text-left hover:bg-card/45 rounded-lg transition-all group cursor-pointer text-xs",children:[d.jsx("span",{className:"text-muted-foreground group-hover:text-foreground transition-colors font-medium",children:u.label}),d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx("span",{className:Ee("text-[10px] font-semibold font-mono",u.tone==="ok"?"text-emerald-400":u.tone==="warn"?"text-amber-400":u.tone==="alert"?"text-red-400":"text-muted-foreground/60"),children:u.status}),d.jsx("span",{className:Ee("h-1.5 w-1.5 rounded-full",m)})]})]},f)})})})}const Fw=g.lazy(()=>Wt(()=>import("./ModelsView-BYDzvdzC.js"),__vite__mapDeps([2,3,4,5,6,7,8])).then(r=>({default:r.ModelsView}))),Iw=g.lazy(()=>Wt(()=>import("./ConnectView-Cz-npKrg.js"),__vite__mapDeps([9,7])).then(r=>({default:r.ConnectView}))),Uw=g.lazy(()=>Wt(()=>import("./AgentView-BgTBq7Qa.js"),[]).then(r=>({default:r.AgentView}))),$w=g.lazy(()=>Wt(()=>import("./KonsoleView-pXiZKOZ7.js"),[]).then(r=>({default:r.KonsoleView}))),Bw=g.lazy(()=>Wt(()=>import("./GuideView-CP1Y1rbp.js"),__vite__mapDeps([10,6,8])).then(r=>({default:r.GuideView}))),Vw=g.lazy(()=>Wt(()=>import("./AuftragsbuchView-C0bzCKZ0.js"),__vite__mapDeps([11,12,7])).then(r=>({default:r.AuftragsbuchView}))),Hw=g.lazy(()=>Wt(()=>import("./IdeenView-wVxyfCCm.js"),__vite__mapDeps([13,12,4,8,7,5])).then(r=>({default:r.IdeenView}))),Ww=g.lazy(()=>Wt(()=>import("./SkillsView-C5MWeKc5.js"),__vite__mapDeps([14,3])).then(r=>({default:r.SkillsView}))),Qw=g.lazy(()=>Wt(()=>import("./ChronikView-Bz_yVFvS.js"),__vite__mapDeps([15,5])).then(r=>({default:r.ChronikView}))),Kw=g.lazy(()=>Wt(()=>import("./WissenView-DOJLqZxA.js"),__vite__mapDeps([16,1])).then(r=>({default:r.WissenView})));function qw(){return d.jsx("div",{className:"flex h-64 items-center justify-center text-muted-foreground",children:d.jsx(ji,{className:"h-5 w-5 animate-spin","aria-label":"Lädt …"})})}const Gw=/Mac|iPhone|iPad/.test(navigator.platform);function Zw(){ww(),J1();const[r,s]=g.useState(()=>{const b=window.location.hash.slice(1);return is.some(R=>R.id===b)?b:"dashboard"}),o=g.useCallback(b=>{window.location.hash.slice(1)===b?s(b):window.location.hash=b},[]),[a,u]=g.useState(()=>localStorage.getItem("mc_sidebar_collapsed")==="true"),[f,m]=g.useState(!1),[h,y]=g.useState(!1),[k,w]=g.useState("maintenance"),{data:x,isError:P}=xm(),{data:_}=vl();g.useEffect(()=>{document.documentElement.classList.add("dark")},[]),g.useEffect(()=>{const b=R=>{var I;w(((I=R.detail)==null?void 0:I.tab)||"maintenance"),y(!0)};return window.addEventListener("open-system-drawer",b),()=>window.removeEventListener("open-system-drawer",b)},[]),g.useEffect(()=>{const b=R=>{var I;const A=(I=R.detail)==null?void 0:I.view;A&&o(A)};return window.addEventListener("mc-navigate",b),()=>window.removeEventListener("mc-navigate",b)},[o]),g.useEffect(()=>{const b=()=>{const R=window.location.hash.slice(1);is.some(A=>A.id===R)&&s(R)};return window.addEventListener("hashchange",b),()=>window.removeEventListener("hashchange",b)},[]),g.useEffect(()=>{m(!1)},[r]);const D=is.find(b=>b.id===r);return d.jsxs("div",{className:"flex h-full relative",children:[d.jsx("div",{className:"fixed inset-0 -z-50 pointer-events-none",style:{backgroundColor:"hsl(224,30%,6%)",backgroundImage:["radial-gradient(45% 40% at 12% 8%, hsl(172 72% 50% / 0.10), transparent 70%)","radial-gradient(50% 45% at 88% 92%, hsl(270 70% 60% / 0.10), transparent 70%)","radial-gradient(40% 35% at 75% 30%, hsl(239 70% 62% / 0.07), transparent 70%)"].join(", ")}}),d.jsx(d1,{onNavigate:o}),d.jsx(mw,{open:h,onClose:()=>y(!1),defaultTab:k}),d.jsx("aside",{className:Ee("hidden md:flex shrink-0 flex-col border-r border-border/40 bg-card/45 backdrop-blur-md transition-all duration-300 ease-in-out",a?"w-16":"w-60"),children:d.jsx(Yh,{collapsed:a,onToggleCollapse:()=>{u(b=>{const R=!b;return localStorage.setItem("mc_sidebar_collapsed",R.toString()),R})},view:r,health:x,backendDown:P,sysStatus:_})}),d.jsxs("div",{className:Ee("md:hidden fixed inset-0 z-50 transition-opacity duration-200",f?"opacity-100":"pointer-events-none opacity-0"),"aria-hidden":!f,children:[d.jsx("div",{className:"absolute inset-0 bg-black/60",onClick:()=>m(!1)}),d.jsx("aside",{className:Ee("absolute inset-y-0 left-0 flex w-72 max-w-[85vw] flex-col border-r border-border/40 bg-[hsl(224,28%,8%)] transition-transform duration-300 ease-in-out",f?"translate-x-0":"-translate-x-full"),children:d.jsx(Yh,{collapsed:!1,onClose:()=>m(!1),view:r,health:x,backendDown:P,sysStatus:_})})]}),d.jsxs("div",{className:"flex min-w-0 flex-1 flex-col",children:[d.jsxs("header",{className:"flex h-14 shrink-0 items-center justify-between gap-3 border-b border-border/40 px-4 md:px-6 bg-card/20 backdrop-blur-sm",children:[d.jsxs("div",{className:"flex min-w-0 items-center gap-3",children:[d.jsx("button",{onClick:()=>m(!0),className:"md:hidden p-1.5 -ml-1 rounded-md hover:bg-accent text-muted-foreground transition-colors cursor-pointer","aria-label":"Navigation öffnen",children:d.jsx(Gy,{className:"h-5 w-5","aria-hidden":"true"})}),d.jsx("div",{className:"truncate text-xs font-medium text-muted-foreground tracking-wide uppercase font-sans",children:D.hint})]}),d.jsxs("div",{className:"flex shrink-0 items-center gap-2",children:[d.jsx(q1,{}),d.jsx("a",{href:"https://git.tobisniceshomelab.ddnsfree.com/Hitonabi/mission-control-v2/src/branch/main/docs/BEDIENUNG.md",target:"_blank",rel:"noopener",className:"hidden sm:flex h-8 items-center rounded-md border border-border/40 bg-background/40 px-2.5 text-xs text-muted-foreground hover:bg-accent hover:text-accent-foreground transition-all cursor-pointer font-semibold",title:"Bedien-Anleitung",children:"Hilfe"}),d.jsxs("button",{onClick:()=>{const b=new KeyboardEvent("keydown",{key:"k",metaKey:!0});document.dispatchEvent(b)},className:"flex items-center gap-2 rounded-md border border-border/40 bg-background/40 px-2.5 py-1.5 text-xs text-muted-foreground hover:bg-accent hover:text-accent-foreground transition-all cursor-pointer",children:[d.jsx(Ay,{className:"h-3.5 w-3.5"}),d.jsx("span",{className:"hidden sm:inline",children:"Suchen"}),d.jsx("kbd",{className:"hidden sm:inline rounded bg-muted px-1.5 py-0.5 font-mono text-[9px]",children:Gw?"⌘K":"Strg+K"})]})]})]}),d.jsx("main",{className:"flex-1 overflow-y-auto p-4 md:p-6 scrollbar-thin",children:d.jsxs(g.Suspense,{fallback:d.jsx(qw,{}),children:[r==="dashboard"&&d.jsx(Lw,{onNavigate:b=>o(b)}),r==="ideen"&&d.jsx(Hw,{}),r==="auftraege"&&d.jsx(Vw,{}),r==="skills"&&d.jsx(Ww,{}),r==="models"&&d.jsx(Fw,{}),r==="connect"&&d.jsx(Iw,{}),r==="wissen"&&d.jsx(Kw,{}),r==="chronik"&&d.jsx(Qw,{}),r==="agent"&&d.jsx(Uw,{}),r==="konsole"&&d.jsx($w,{}),r==="guide"&&d.jsx(Bw,{})]})})]})]})}function Yh({collapsed:r,onToggleCollapse:s,onClose:o,view:a,health:u,backendDown:f,sysStatus:m}){var h,y,k,w,x;return d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:Ee("flex items-center py-4 border-b border-border/40 shrink-0",r?"flex-col gap-3 px-2":"justify-between px-5"),children:[d.jsxs("div",{className:"flex items-center gap-2 overflow-hidden",children:[d.jsx("div",{className:"h-7 w-7 rounded-lg bg-primary shadow-md shadow-primary/20 shrink-0"}),!r&&d.jsxs("div",{className:"leading-tight",children:[d.jsx("div",{className:"text-sm font-semibold tracking-wide font-space",children:"Mission Control"}),d.jsx("div",{className:"text-xs text-muted-foreground",children:"2.0"})]})]}),s&&d.jsx("button",{onClick:s,className:"p-1 rounded-md hover:bg-accent text-muted-foreground transition-colors cursor-pointer","aria-label":r?"Seitenleiste ausklappen":"Seitenleiste einklappen",title:r?"Maximieren":"Minimieren",children:r?d.jsx(wi,{className:"h-4 w-4","aria-hidden":"true"}):d.jsx(Oy,{className:"h-4 w-4","aria-hidden":"true"})}),o&&d.jsx("button",{onClick:o,className:"p-1 rounded-md hover:bg-accent text-muted-foreground transition-colors cursor-pointer","aria-label":"Navigation schließen",children:d.jsx(dl,{className:"h-4 w-4","aria-hidden":"true"})})]}),d.jsx("nav",{className:"flex-1 space-y-1 px-3 py-4 overflow-y-auto",children:(()=>{let P=null;return is.map(_=>{const D=_.group!==P;return P=_.group,d.jsxs("div",{className:"space-y-1",children:[D&&(r?P!==is[0].group&&d.jsx("div",{className:"my-3 border-t border-border/30"}):d.jsx("div",{className:"mt-5 mb-1.5 px-3 text-[10px] font-bold uppercase tracking-widest text-muted-foreground/40 first:mt-0 select-none",children:_.group})),d.jsxs("a",{href:`#${_.id}`,onClick:o,"aria-current":a===_.id?"page":void 0,className:Ee("flex w-full items-center rounded-md text-sm transition-all cursor-pointer",r?"justify-center p-2.5":"gap-3 px-3 py-2",a===_.id?r?"nav-active-collapsed":"nav-active":"text-muted-foreground hover:bg-accent hover:text-accent-foreground"),title:r?_.label:void 0,"aria-label":r?_.label:void 0,children:[d.jsx(_.icon,{className:"h-4.5 w-4.5 shrink-0","aria-hidden":"true"}),!r&&d.jsx("span",{className:"truncate",children:_.label})]})]},_.id)})})()}),d.jsx("div",{className:Ee("py-3 text-xs text-muted-foreground border-t border-border/40 shrink-0",r?"px-2 text-center":"px-5"),children:r?d.jsx("div",{className:"flex justify-center",children:d.jsx("span",{className:Ee("h-2.5 w-2.5 rounded-full ring-2 ring-black/40",f||!u?"bg-red-500":u.engine_reachable?u.brain&&!u.brain.ready?"bg-amber-500 animate-pulse":"bg-emerald-500 animate-pulse":"bg-amber-500"),title:f?"Zentrale antwortet nicht — Anzeigen evtl. veraltet":u?u.engine_reachable?u.brain&&!u.brain.ready?`Hirn offline (${u.brain.model??"fast"})`:"Engine + Hirn online":"Engine offline":"Backend offline"})}):d.jsxs("div",{className:"space-y-2 text-left",children:[f?d.jsxs("span",{className:"flex items-center gap-2 text-red-400",children:[d.jsx("span",{className:"h-2 w-2 rounded-full bg-red-500 animate-pulse"}),d.jsx("span",{className:"truncate",children:"Zentrale antwortet nicht"})]}):u?d.jsxs(d.Fragment,{children:[d.jsxs("span",{className:"flex items-center gap-2",children:[d.jsx("span",{className:Ee("h-2 w-2 rounded-full animate-pulse",u.engine_reachable?"bg-emerald-500":"bg-amber-500")}),d.jsxs("span",{className:"truncate",children:["Engine ",u.engine_reachable?"online":"offline"]})]}),u.brain&&!u.brain.ready&&d.jsxs("span",{className:"flex items-center gap-2 text-amber-400",title:`Agent-Hirn '${u.brain.model??"fast"}' lädt nicht/abgestürzt`,children:[d.jsx("span",{className:"h-2 w-2 rounded-full bg-amber-500 animate-pulse"}),d.jsxs("span",{className:"truncate",children:["Hirn offline",u.brain.model?` (${u.brain.model})`:""]})]})]}):d.jsxs("span",{className:"flex items-center gap-2",children:[d.jsx("span",{className:"h-2 w-2 rounded-full bg-red-500"})," ",d.jsx("span",{className:"truncate",children:"Backend offline"})]}),(m==null?void 0:m.versions)&&d.jsxs("div",{className:"space-y-1 text-[9px] text-muted-foreground/60 mt-2 pt-2 border-t border-border/30",children:[d.jsxs("div",{className:"truncate",title:m.versions.mc2?`${m.versions.mc2.branch}-${m.versions.mc2.hash}${m.versions.mc2.dirty?"*":""} (${m.versions.mc2.date})`:"nicht gefunden",children:[d.jsx("strong",{children:"MC2:"})," ",m.versions.mc2?`${m.versions.mc2.hash}${m.versions.mc2.dirty?"*":""}`:"—"]}),d.jsxs("div",{className:"truncate",title:((h=m.versions.engine)==null?void 0:h.type)==="git"?`${m.versions.engine.branch}-${m.versions.engine.hash}${m.versions.engine.dirty?"*":""} (${m.versions.engine.date})`:((y=m.versions.engine)==null?void 0:y.version_text)||"unbekannt",children:[d.jsx("strong",{children:"Engine:"})," ",((k=m.versions.engine)==null?void 0:k.type)==="git"?`${m.versions.engine.hash}${m.versions.engine.dirty?"*":""}`:((x=(w=m.versions.engine)==null?void 0:w.version_text)==null?void 0:x.split(" ").pop())||"—"]}),d.jsxs("div",{className:"truncate",title:m.versions.hermes_agent?`${m.versions.hermes_agent.branch}-${m.versions.hermes_agent.hash}${m.versions.hermes_agent.dirty?"*":""} (${m.versions.hermes_agent.date})`:"nicht gefunden",children:[d.jsx("strong",{children:"Hermes Agent:"})," ",m.versions.hermes_agent?`${m.versions.hermes_agent.hash}${m.versions.hermes_agent.dirty?"*":""}`:"—"]})]})]})})]})}class Yw extends Ju.Component{constructor(){super(...arguments);Qo(this,"state",{error:null})}static getDerivedStateFromError(o){return{error:o}}componentDidCatch(o,a){console.error("Unbehandelter UI-Fehler:",o,a.componentStack)}render(){return this.state.error?d.jsx("div",{className:"min-h-screen flex items-center justify-center bg-neutral-950 text-neutral-200 p-8",children:d.jsxs("div",{className:"max-w-lg space-y-4 text-center",children:[d.jsx("div",{className:"text-2xl",children:"Da ist etwas schiefgelaufen."}),d.jsx("div",{className:"text-sm text-neutral-400 break-all",children:this.state.error.message}),d.jsx("button",{className:"px-4 py-2 rounded-lg bg-neutral-800 hover:bg-neutral-700 border border-neutral-700",onClick:()=>window.location.reload(),children:"Neu laden"})]})}):this.props.children}}const ju="mc_neuladen_wegen_version";function Xw(){window.addEventListener("vite:preloadError",r=>{sessionStorage.getItem(ju)||(r.preventDefault(),sessionStorage.setItem(ju,"1"),window.location.reload())}),window.addEventListener("load",()=>{window.setTimeout(()=>sessionStorage.removeItem(ju),5e3)})}Xw();const Jw=new ay({defaultOptions:{queries:{retry:1,refetchOnWindowFocus:!1,staleTime:5e3}}});Av.createRoot(document.getElementById("root")).render(d.jsx(Ju.StrictMode,{children:d.jsx(Yw,{children:d.jsx(uy,{client:Jw,children:d.jsx(Zw,{})})})}));export{Uy as $,ow as A,Py as B,My as C,jh as D,jp as E,wi as F,Ty as G,By as H,iw as I,zy as J,tk as K,ji as L,Ni as M,jy as N,_p as O,Yy as P,t0 as Q,ss as R,Xy as S,Ci as T,gi as U,cl as V,r0 as W,dl as X,Sp as Y,oc as Z,qy as _,uk as a,e0 as a0,ew as a1,tw as a2,Ly as a3,vk as a4,ic as a5,sk as a6,Ep as a7,Iy as a8,Di as a9,_u as aa,bi as ab,iy as ac,it as ad,bt as ae,hp as af,Be as ag,sw as ah,mk as ai,ik as aj,Hy as ak,lc as al,Vy as am,nw as an,Ju as ao,ap,ok as aq,lk as ar,Ky as as,m1 as at,Xu as au,Mp as av,ec as aw,Ee as b,ge as c,rk as d,Cy as e,km as f,ak as g,vl as h,ck as i,d as j,ym as k,pk as l,fk as m,Se as n,ts as o,p1 as p,Pe as q,g as r,nk as s,Np as t,ul as u,gk as v,dk as w,Sm as x,Eu as y,hk as z};
|