8e4aca9f5c
Katalog-Daten (models_catalog.json) waren teil-stale (Stand 27.06.): - vision: Qwen3-VL-30B-A3B-Instruct ergaenzt (neue Augen, MoE 30B-A3B) — sonst empfahl der "Modelle finden"-Tab weiter das aeltere VL-8B (Downgrade). - scout: gemma-4-26B/31B (laengst entfernt) durch das live genutzte GLM-4.6V-Flash ersetzt. - version 2026-06-27 -> 2026-07-03. Bewusst NICHT aufgenommen: Qwen3.6-27B dense — im 3-Wege-Bench (tg 12,7 vs 60-91 der MoE-Coder) als Coder-Worker unterlegen, keine Empfehlung. Badge-Fix (Discover.tsx): installedModel matchte nur das primaere role-Feld; ein Modell kann eine Kategorie aber ueber einen Alias bedienen (Qwen3.6 = role "hermes" + Alias "fast") -> Fast-Karte zeigte faelschlich "Frei". Jetzt Match per Rolle ODER Alias. Live gegen die Box verifiziert: alle 5 Rollen-Karten "Aktiviert". Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
665 lines
885 KiB
JavaScript
665 lines
885 KiB
JavaScript
var V3=Object.defineProperty;var K1=e=>{throw TypeError(e)};var q3=(e,t,r)=>t in e?V3(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var qo=(e,t,r)=>q3(e,typeof t!="symbol"?t+"":t,r),Fp=(e,t,r)=>t.has(e)||K1("Cannot "+r);var L=(e,t,r)=>(Fp(e,t,"read from private field"),r?r.call(e):t.get(e)),Re=(e,t,r)=>t.has(e)?K1("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),ye=(e,t,r,n)=>(Fp(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),Ue=(e,t,r)=>(Fp(e,t,"access private method"),r);var md=(e,t,r,n)=>({set _(a){ye(e,t,a,r)},get _(){return L(e,t,n)}});function Q3(e,t){for(var r=0;r<t.length;r++){const n=t[r];if(typeof n!="string"&&!Array.isArray(n)){for(const a in n)if(a!=="default"&&!(a in e)){const o=Object.getOwnPropertyDescriptor(n,a);o&&Object.defineProperty(e,a,o.get?o:{enumerable:!0,get:()=>n[a]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))n(a);new MutationObserver(a=>{for(const o of a)if(o.type==="childList")for(const u of o.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&n(u)}).observe(document,{childList:!0,subtree:!0});function r(a){const o={};return a.integrity&&(o.integrity=a.integrity),a.referrerPolicy&&(o.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?o.credentials="include":a.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(a){if(a.ep)return;a.ep=!0;const o=r(a);fetch(a.href,o)}})();function ly(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Bp={exports:{}},Hl={},Up={exports:{}},Fe={};/**
|
||
* @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 G1;function Y3(){if(G1)return Fe;G1=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),u=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.iterator;function v(I){return I===null||typeof I!="object"?null:(I=g&&I[g]||I["@@iterator"],typeof I=="function"?I:null)}var b={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},j=Object.assign,k={};function S(I,M,H){this.props=I,this.context=M,this.refs=k,this.updater=H||b}S.prototype.isReactComponent={},S.prototype.setState=function(I,M){if(typeof I!="object"&&typeof I!="function"&&I!=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,I,M,"setState")},S.prototype.forceUpdate=function(I){this.updater.enqueueForceUpdate(this,I,"forceUpdate")};function N(){}N.prototype=S.prototype;function E(I,M,H){this.props=I,this.context=M,this.refs=k,this.updater=H||b}var A=E.prototype=new N;A.constructor=E,j(A,S.prototype),A.isPureReactComponent=!0;var P=Array.isArray,_=Object.prototype.hasOwnProperty,O={current:null},D={key:!0,ref:!0,__self:!0,__source:!0};function B(I,M,H){var ne,Z={},me=null,pe=null;if(M!=null)for(ne in M.ref!==void 0&&(pe=M.ref),M.key!==void 0&&(me=""+M.key),M)_.call(M,ne)&&!D.hasOwnProperty(ne)&&(Z[ne]=M[ne]);var Oe=arguments.length-2;if(Oe===1)Z.children=H;else if(1<Oe){for(var re=Array(Oe),we=0;we<Oe;we++)re[we]=arguments[we+2];Z.children=re}if(I&&I.defaultProps)for(ne in Oe=I.defaultProps,Oe)Z[ne]===void 0&&(Z[ne]=Oe[ne]);return{$$typeof:e,type:I,key:me,ref:pe,props:Z,_owner:O.current}}function F(I,M){return{$$typeof:e,type:I.type,key:M,ref:I.ref,props:I.props,_owner:I._owner}}function z(I){return typeof I=="object"&&I!==null&&I.$$typeof===e}function Y(I){var M={"=":"=0",":":"=2"};return"$"+I.replace(/[=:]/g,function(H){return M[H]})}var U=/\/+/g;function he(I,M){return typeof I=="object"&&I!==null&&I.key!=null?Y(""+I.key):M.toString(36)}function ue(I,M,H,ne,Z){var me=typeof I;(me==="undefined"||me==="boolean")&&(I=null);var pe=!1;if(I===null)pe=!0;else switch(me){case"string":case"number":pe=!0;break;case"object":switch(I.$$typeof){case e:case t:pe=!0}}if(pe)return pe=I,Z=Z(pe),I=ne===""?"."+he(pe,0):ne,P(Z)?(H="",I!=null&&(H=I.replace(U,"$&/")+"/"),ue(Z,M,H,"",function(we){return we})):Z!=null&&(z(Z)&&(Z=F(Z,H+(!Z.key||pe&&pe.key===Z.key?"":(""+Z.key).replace(U,"$&/")+"/")+I)),M.push(Z)),1;if(pe=0,ne=ne===""?".":ne+":",P(I))for(var Oe=0;Oe<I.length;Oe++){me=I[Oe];var re=ne+he(me,Oe);pe+=ue(me,M,H,re,Z)}else if(re=v(I),typeof re=="function")for(I=re.call(I),Oe=0;!(me=I.next()).done;)me=me.value,re=ne+he(me,Oe++),pe+=ue(me,M,H,re,Z);else if(me==="object")throw M=String(I),Error("Objects are not valid as a React child (found: "+(M==="[object Object]"?"object with keys {"+Object.keys(I).join(", ")+"}":M)+"). If you meant to render a collection of children, use an array instead.");return pe}function ge(I,M,H){if(I==null)return I;var ne=[],Z=0;return ue(I,ne,"","",function(me){return M.call(H,me,Z++)}),ne}function ie(I){if(I._status===-1){var M=I._result;M=M(),M.then(function(H){(I._status===0||I._status===-1)&&(I._status=1,I._result=H)},function(H){(I._status===0||I._status===-1)&&(I._status=2,I._result=H)}),I._status===-1&&(I._status=0,I._result=M)}if(I._status===1)return I._result.default;throw I._result}var se={current:null},X={transition:null},te={ReactCurrentDispatcher:se,ReactCurrentBatchConfig:X,ReactCurrentOwner:O};function J(){throw Error("act(...) is not supported in production builds of React.")}return Fe.Children={map:ge,forEach:function(I,M,H){ge(I,function(){M.apply(this,arguments)},H)},count:function(I){var M=0;return ge(I,function(){M++}),M},toArray:function(I){return ge(I,function(M){return M})||[]},only:function(I){if(!z(I))throw Error("React.Children.only expected to receive a single React element child.");return I}},Fe.Component=S,Fe.Fragment=r,Fe.Profiler=a,Fe.PureComponent=E,Fe.StrictMode=n,Fe.Suspense=f,Fe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=te,Fe.act=J,Fe.cloneElement=function(I,M,H){if(I==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+I+".");var ne=j({},I.props),Z=I.key,me=I.ref,pe=I._owner;if(M!=null){if(M.ref!==void 0&&(me=M.ref,pe=O.current),M.key!==void 0&&(Z=""+M.key),I.type&&I.type.defaultProps)var Oe=I.type.defaultProps;for(re in M)_.call(M,re)&&!D.hasOwnProperty(re)&&(ne[re]=M[re]===void 0&&Oe!==void 0?Oe[re]:M[re])}var re=arguments.length-2;if(re===1)ne.children=H;else if(1<re){Oe=Array(re);for(var we=0;we<re;we++)Oe[we]=arguments[we+2];ne.children=Oe}return{$$typeof:e,type:I.type,key:Z,ref:me,props:ne,_owner:pe}},Fe.createContext=function(I){return I={$$typeof:u,_currentValue:I,_currentValue2:I,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},I.Provider={$$typeof:o,_context:I},I.Consumer=I},Fe.createElement=B,Fe.createFactory=function(I){var M=B.bind(null,I);return M.type=I,M},Fe.createRef=function(){return{current:null}},Fe.forwardRef=function(I){return{$$typeof:c,render:I}},Fe.isValidElement=z,Fe.lazy=function(I){return{$$typeof:m,_payload:{_status:-1,_result:I},_init:ie}},Fe.memo=function(I,M){return{$$typeof:h,type:I,compare:M===void 0?null:M}},Fe.startTransition=function(I){var M=X.transition;X.transition={};try{I()}finally{X.transition=M}},Fe.unstable_act=J,Fe.useCallback=function(I,M){return se.current.useCallback(I,M)},Fe.useContext=function(I){return se.current.useContext(I)},Fe.useDebugValue=function(){},Fe.useDeferredValue=function(I){return se.current.useDeferredValue(I)},Fe.useEffect=function(I,M){return se.current.useEffect(I,M)},Fe.useId=function(){return se.current.useId()},Fe.useImperativeHandle=function(I,M,H){return se.current.useImperativeHandle(I,M,H)},Fe.useInsertionEffect=function(I,M){return se.current.useInsertionEffect(I,M)},Fe.useLayoutEffect=function(I,M){return se.current.useLayoutEffect(I,M)},Fe.useMemo=function(I,M){return se.current.useMemo(I,M)},Fe.useReducer=function(I,M,H){return se.current.useReducer(I,M,H)},Fe.useRef=function(I){return se.current.useRef(I)},Fe.useState=function(I){return se.current.useState(I)},Fe.useSyncExternalStore=function(I,M,H){return se.current.useSyncExternalStore(I,M,H)},Fe.useTransition=function(){return se.current.useTransition()},Fe.version="18.3.1",Fe}var V1;function Ws(){return V1||(V1=1,Up.exports=Y3()),Up.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 q1;function X3(){if(q1)return Hl;q1=1;var e=Ws(),t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,a=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,o={key:!0,ref:!0,__self:!0,__source:!0};function u(c,f,h){var m,g={},v=null,b=null;h!==void 0&&(v=""+h),f.key!==void 0&&(v=""+f.key),f.ref!==void 0&&(b=f.ref);for(m in f)n.call(f,m)&&!o.hasOwnProperty(m)&&(g[m]=f[m]);if(c&&c.defaultProps)for(m in f=c.defaultProps,f)g[m]===void 0&&(g[m]=f[m]);return{$$typeof:t,type:c,key:v,ref:b,props:g,_owner:a.current}}return Hl.Fragment=r,Hl.jsx=u,Hl.jsxs=u,Hl}var Q1;function Z3(){return Q1||(Q1=1,Bp.exports=X3()),Bp.exports}var l=Z3(),y=Ws();const uy=ly(y),Xf=Q3({__proto__:null,default:uy},[y]);var pd={},Hp={exports:{}},br={},Wp={exports:{}},Kp={};/**
|
||
* @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 Y1;function J3(){return Y1||(Y1=1,(function(e){function t(X,te){var J=X.length;X.push(te);e:for(;0<J;){var I=J-1>>>1,M=X[I];if(0<a(M,te))X[I]=te,X[J]=M,J=I;else break e}}function r(X){return X.length===0?null:X[0]}function n(X){if(X.length===0)return null;var te=X[0],J=X.pop();if(J!==te){X[0]=J;e:for(var I=0,M=X.length,H=M>>>1;I<H;){var ne=2*(I+1)-1,Z=X[ne],me=ne+1,pe=X[me];if(0>a(Z,J))me<M&&0>a(pe,Z)?(X[I]=pe,X[me]=J,I=me):(X[I]=Z,X[ne]=J,I=ne);else if(me<M&&0>a(pe,J))X[I]=pe,X[me]=J,I=me;else break e}}return te}function a(X,te){var J=X.sortIndex-te.sortIndex;return J!==0?J:X.id-te.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var u=Date,c=u.now();e.unstable_now=function(){return u.now()-c}}var f=[],h=[],m=1,g=null,v=3,b=!1,j=!1,k=!1,S=typeof setTimeout=="function"?setTimeout:null,N=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function A(X){for(var te=r(h);te!==null;){if(te.callback===null)n(h);else if(te.startTime<=X)n(h),te.sortIndex=te.expirationTime,t(f,te);else break;te=r(h)}}function P(X){if(k=!1,A(X),!j)if(r(f)!==null)j=!0,ie(_);else{var te=r(h);te!==null&&se(P,te.startTime-X)}}function _(X,te){j=!1,k&&(k=!1,N(B),B=-1),b=!0;var J=v;try{for(A(te),g=r(f);g!==null&&(!(g.expirationTime>te)||X&&!Y());){var I=g.callback;if(typeof I=="function"){g.callback=null,v=g.priorityLevel;var M=I(g.expirationTime<=te);te=e.unstable_now(),typeof M=="function"?g.callback=M:g===r(f)&&n(f),A(te)}else n(f);g=r(f)}if(g!==null)var H=!0;else{var ne=r(h);ne!==null&&se(P,ne.startTime-te),H=!1}return H}finally{g=null,v=J,b=!1}}var O=!1,D=null,B=-1,F=5,z=-1;function Y(){return!(e.unstable_now()-z<F)}function U(){if(D!==null){var X=e.unstable_now();z=X;var te=!0;try{te=D(!0,X)}finally{te?he():(O=!1,D=null)}}else O=!1}var he;if(typeof E=="function")he=function(){E(U)};else if(typeof MessageChannel<"u"){var ue=new MessageChannel,ge=ue.port2;ue.port1.onmessage=U,he=function(){ge.postMessage(null)}}else he=function(){S(U,0)};function ie(X){D=X,O||(O=!0,he())}function se(X,te){B=S(function(){X(e.unstable_now())},te)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(X){X.callback=null},e.unstable_continueExecution=function(){j||b||(j=!0,ie(_))},e.unstable_forceFrameRate=function(X){0>X||125<X?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):F=0<X?Math.floor(1e3/X):5},e.unstable_getCurrentPriorityLevel=function(){return v},e.unstable_getFirstCallbackNode=function(){return r(f)},e.unstable_next=function(X){switch(v){case 1:case 2:case 3:var te=3;break;default:te=v}var J=v;v=te;try{return X()}finally{v=J}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(X,te){switch(X){case 1:case 2:case 3:case 4:case 5:break;default:X=3}var J=v;v=X;try{return te()}finally{v=J}},e.unstable_scheduleCallback=function(X,te,J){var I=e.unstable_now();switch(typeof J=="object"&&J!==null?(J=J.delay,J=typeof J=="number"&&0<J?I+J:I):J=I,X){case 1:var M=-1;break;case 2:M=250;break;case 5:M=1073741823;break;case 4:M=1e4;break;default:M=5e3}return M=J+M,X={id:m++,callback:te,priorityLevel:X,startTime:J,expirationTime:M,sortIndex:-1},J>I?(X.sortIndex=J,t(h,X),r(f)===null&&X===r(h)&&(k?(N(B),B=-1):k=!0,se(P,J-I))):(X.sortIndex=M,t(f,X),j||b||(j=!0,ie(_))),X},e.unstable_shouldYield=Y,e.unstable_wrapCallback=function(X){var te=v;return function(){var J=v;v=te;try{return X.apply(this,arguments)}finally{v=J}}}})(Kp)),Kp}var X1;function eM(){return X1||(X1=1,Wp.exports=J3()),Wp.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 Z1;function tM(){if(Z1)return br;Z1=1;var e=Ws(),t=eM();function r(i){for(var s="https://reactjs.org/docs/error-decoder.html?invariant="+i,d=1;d<arguments.length;d++)s+="&args[]="+encodeURIComponent(arguments[d]);return"Minified React error #"+i+"; visit "+s+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var n=new Set,a={};function o(i,s){u(i,s),u(i+"Capture",s)}function u(i,s){for(a[i]=s,i=0;i<s.length;i++)n.add(s[i])}var c=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),f=Object.prototype.hasOwnProperty,h=/^[: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]*$/,m={},g={};function v(i){return f.call(g,i)?!0:f.call(m,i)?!1:h.test(i)?g[i]=!0:(m[i]=!0,!1)}function b(i,s,d,p){if(d!==null&&d.type===0)return!1;switch(typeof s){case"function":case"symbol":return!0;case"boolean":return p?!1:d!==null?!d.acceptsBooleans:(i=i.toLowerCase().slice(0,5),i!=="data-"&&i!=="aria-");default:return!1}}function j(i,s,d,p){if(s===null||typeof s>"u"||b(i,s,d,p))return!0;if(p)return!1;if(d!==null)switch(d.type){case 3:return!s;case 4:return s===!1;case 5:return isNaN(s);case 6:return isNaN(s)||1>s}return!1}function k(i,s,d,p,x,w,C){this.acceptsBooleans=s===2||s===3||s===4,this.attributeName=p,this.attributeNamespace=x,this.mustUseProperty=d,this.propertyName=i,this.type=s,this.sanitizeURL=w,this.removeEmptyString=C}var S={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){S[i]=new k(i,0,!1,i,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(i){var s=i[0];S[s]=new k(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){S[i]=new k(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){S[i]=new k(i,2,!1,i,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(i){S[i]=new k(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){S[i]=new k(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){S[i]=new k(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){S[i]=new k(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){S[i]=new k(i,5,!1,i.toLowerCase(),null,!1,!1)});var N=/[\-:]([a-z])/g;function E(i){return i[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(i){var s=i.replace(N,E);S[s]=new k(s,1,!1,i,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(i){var s=i.replace(N,E);S[s]=new k(s,1,!1,i,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(i){var s=i.replace(N,E);S[s]=new k(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){S[i]=new k(i,1,!1,i.toLowerCase(),null,!1,!1)}),S.xlinkHref=new k("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){S[i]=new k(i,1,!1,i.toLowerCase(),null,!0,!0)});function A(i,s,d,p){var x=S.hasOwnProperty(s)?S[s]:null;(x!==null?x.type!==0:p||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(j(s,d,x,p)&&(d=null),p||x===null?v(s)&&(d===null?i.removeAttribute(s):i.setAttribute(s,""+d)):x.mustUseProperty?i[x.propertyName]=d===null?x.type===3?!1:"":d:(s=x.attributeName,p=x.attributeNamespace,d===null?i.removeAttribute(s):(x=x.type,d=x===3||x===4&&d===!0?"":""+d,p?i.setAttributeNS(p,s,d):i.setAttribute(s,d))))}var P=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,_=Symbol.for("react.element"),O=Symbol.for("react.portal"),D=Symbol.for("react.fragment"),B=Symbol.for("react.strict_mode"),F=Symbol.for("react.profiler"),z=Symbol.for("react.provider"),Y=Symbol.for("react.context"),U=Symbol.for("react.forward_ref"),he=Symbol.for("react.suspense"),ue=Symbol.for("react.suspense_list"),ge=Symbol.for("react.memo"),ie=Symbol.for("react.lazy"),se=Symbol.for("react.offscreen"),X=Symbol.iterator;function te(i){return i===null||typeof i!="object"?null:(i=X&&i[X]||i["@@iterator"],typeof i=="function"?i:null)}var J=Object.assign,I;function M(i){if(I===void 0)try{throw Error()}catch(d){var s=d.stack.trim().match(/\n( *(at )?)/);I=s&&s[1]||""}return`
|
||
`+I+i}var H=!1;function ne(i,s){if(!i||H)return"";H=!0;var d=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(s)if(s=function(){throw Error()},Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(s,[])}catch(Q){var p=Q}Reflect.construct(i,[],s)}else{try{s.call()}catch(Q){p=Q}i.call(s.prototype)}else{try{throw Error()}catch(Q){p=Q}i()}}catch(Q){if(Q&&p&&typeof Q.stack=="string"){for(var x=Q.stack.split(`
|
||
`),w=p.stack.split(`
|
||
`),C=x.length-1,T=w.length-1;1<=C&&0<=T&&x[C]!==w[T];)T--;for(;1<=C&&0<=T;C--,T--)if(x[C]!==w[T]){if(C!==1||T!==1)do if(C--,T--,0>T||x[C]!==w[T]){var R=`
|
||
`+x[C].replace(" at new "," at ");return i.displayName&&R.includes("<anonymous>")&&(R=R.replace("<anonymous>",i.displayName)),R}while(1<=C&&0<=T);break}}}finally{H=!1,Error.prepareStackTrace=d}return(i=i?i.displayName||i.name:"")?M(i):""}function Z(i){switch(i.tag){case 5:return M(i.type);case 16:return M("Lazy");case 13:return M("Suspense");case 19:return M("SuspenseList");case 0:case 2:case 15:return i=ne(i.type,!1),i;case 11:return i=ne(i.type.render,!1),i;case 1:return i=ne(i.type,!0),i;default:return""}}function me(i){if(i==null)return null;if(typeof i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case D:return"Fragment";case O:return"Portal";case F:return"Profiler";case B:return"StrictMode";case he:return"Suspense";case ue:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case Y:return(i.displayName||"Context")+".Consumer";case z:return(i._context.displayName||"Context")+".Provider";case U:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case ge:return s=i.displayName||null,s!==null?s:me(i.type)||"Memo";case ie:s=i._payload,i=i._init;try{return me(i(s))}catch{}}return null}function pe(i){var s=i.type;switch(i.tag){case 24:return"Cache";case 9:return(s.displayName||"Context")+".Consumer";case 10:return(s._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return i=s.render,i=i.displayName||i.name||"",s.displayName||(i!==""?"ForwardRef("+i+")":"ForwardRef");case 7:return"Fragment";case 5:return s;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return me(s);case 8:return s===B?"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 s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function Oe(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function re(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function we(i){var s=re(i)?"checked":"value",d=Object.getOwnPropertyDescriptor(i.constructor.prototype,s),p=""+i[s];if(!i.hasOwnProperty(s)&&typeof d<"u"&&typeof d.get=="function"&&typeof d.set=="function"){var x=d.get,w=d.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return x.call(this)},set:function(C){p=""+C,w.call(this,C)}}),Object.defineProperty(i,s,{enumerable:d.enumerable}),{getValue:function(){return p},setValue:function(C){p=""+C},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function _e(i){i._valueTracker||(i._valueTracker=we(i))}function ae(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var d=s.getValue(),p="";return i&&(p=re(i)?i.checked?"true":"false":i.value),i=p,i!==d?(s.setValue(i),!0):!1}function et(i){if(i=i||(typeof document<"u"?document:void 0),typeof i>"u")return null;try{return i.activeElement||i.body}catch{return i.body}}function Be(i,s){var d=s.checked;return J({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:d??i._wrapperState.initialChecked})}function Pe(i,s){var d=s.defaultValue==null?"":s.defaultValue,p=s.checked!=null?s.checked:s.defaultChecked;d=Oe(s.value!=null?s.value:d),i._wrapperState={initialChecked:p,initialValue:d,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function vt(i,s){s=s.checked,s!=null&&A(i,"checked",s,!1)}function Yt(i,s){vt(i,s);var d=Oe(s.value),p=s.type;if(d!=null)p==="number"?(d===0&&i.value===""||i.value!=d)&&(i.value=""+d):i.value!==""+d&&(i.value=""+d);else if(p==="submit"||p==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?Ae(i,s.type,d):s.hasOwnProperty("defaultValue")&&Ae(i,s.type,Oe(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function K(i,s,d){if(s.hasOwnProperty("value")||s.hasOwnProperty("defaultValue")){var p=s.type;if(!(p!=="submit"&&p!=="reset"||s.value!==void 0&&s.value!==null))return;s=""+i._wrapperState.initialValue,d||s===i.value||(i.value=s),i.defaultValue=s}d=i.name,d!==""&&(i.name=""),i.defaultChecked=!!i._wrapperState.initialChecked,d!==""&&(i.name=d)}function Ae(i,s,d){(s!=="number"||et(i.ownerDocument)!==i)&&(d==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+d&&(i.defaultValue=""+d))}var Se=Array.isArray;function qe(i,s,d,p){if(i=i.options,s){s={};for(var x=0;x<d.length;x++)s["$"+d[x]]=!0;for(d=0;d<i.length;d++)x=s.hasOwnProperty("$"+i[d].value),i[d].selected!==x&&(i[d].selected=x),x&&p&&(i[d].defaultSelected=!0)}else{for(d=""+Oe(d),s=null,x=0;x<i.length;x++){if(i[x].value===d){i[x].selected=!0,p&&(i[x].defaultSelected=!0);return}s!==null||i[x].disabled||(s=i[x])}s!==null&&(s.selected=!0)}}function G(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(r(91));return J({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function Ie(i,s){var d=s.value;if(d==null){if(d=s.children,s=s.defaultValue,d!=null){if(s!=null)throw Error(r(92));if(Se(d)){if(1<d.length)throw Error(r(93));d=d[0]}s=d}s==null&&(s=""),d=s}i._wrapperState={initialValue:Oe(d)}}function Xt(i,s){var d=Oe(s.value),p=Oe(s.defaultValue);d!=null&&(d=""+d,d!==i.value&&(i.value=d),s.defaultValue==null&&i.defaultValue!==d&&(i.defaultValue=d)),p!=null&&(i.defaultValue=""+p)}function nx(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function ix(i){switch(i){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 Xh(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?ix(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var oc,ax=(function(i){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(s,d,p,x){MSApp.execUnsafeLocalFunction(function(){return i(s,d,p,x)})}:i})(function(i,s){if(i.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in i)i.innerHTML=s;else{for(oc=oc||document.createElement("div"),oc.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=oc.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function al(i,s){if(s){var d=i.firstChild;if(d&&d===i.lastChild&&d.nodeType===3){d.nodeValue=s;return}}i.textContent=s}var ol={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},XO=["Webkit","ms","Moz","O"];Object.keys(ol).forEach(function(i){XO.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),ol[s]=ol[i]})});function ox(i,s,d){return s==null||typeof s=="boolean"||s===""?"":d||typeof s!="number"||s===0||ol.hasOwnProperty(i)&&ol[i]?(""+s).trim():s+"px"}function sx(i,s){i=i.style;for(var d in s)if(s.hasOwnProperty(d)){var p=d.indexOf("--")===0,x=ox(d,s[d],p);d==="float"&&(d="cssFloat"),p?i.setProperty(d,x):i[d]=x}}var ZO=J({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 Zh(i,s){if(s){if(ZO[i]&&(s.children!=null||s.dangerouslySetInnerHTML!=null))throw Error(r(137,i));if(s.dangerouslySetInnerHTML!=null){if(s.children!=null)throw Error(r(60));if(typeof s.dangerouslySetInnerHTML!="object"||!("__html"in s.dangerouslySetInnerHTML))throw Error(r(61))}if(s.style!=null&&typeof s.style!="object")throw Error(r(62))}}function Jh(i,s){if(i.indexOf("-")===-1)return typeof s.is=="string";switch(i){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 em=null;function tm(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var rm=null,So=null,No=null;function lx(i){if(i=Cl(i)){if(typeof rm!="function")throw Error(r(280));var s=i.stateNode;s&&(s=Pc(s),rm(i.stateNode,i.type,s))}}function ux(i){So?No?No.push(i):No=[i]:So=i}function cx(){if(So){var i=So,s=No;if(No=So=null,lx(i),s)for(i=0;i<s.length;i++)lx(s[i])}}function dx(i,s){return i(s)}function fx(){}var nm=!1;function hx(i,s,d){if(nm)return i(s,d);nm=!0;try{return dx(i,s,d)}finally{nm=!1,(So!==null||No!==null)&&(fx(),cx())}}function sl(i,s){var d=i.stateNode;if(d===null)return null;var p=Pc(d);if(p===null)return null;d=p[s];e:switch(s){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(p=!p.disabled)||(i=i.type,p=!(i==="button"||i==="input"||i==="select"||i==="textarea")),i=!p;break e;default:i=!1}if(i)return null;if(d&&typeof d!="function")throw Error(r(231,s,typeof d));return d}var im=!1;if(c)try{var ll={};Object.defineProperty(ll,"passive",{get:function(){im=!0}}),window.addEventListener("test",ll,ll),window.removeEventListener("test",ll,ll)}catch{im=!1}function JO(i,s,d,p,x,w,C,T,R){var Q=Array.prototype.slice.call(arguments,3);try{s.apply(d,Q)}catch(le){this.onError(le)}}var ul=!1,sc=null,lc=!1,am=null,e_={onError:function(i){ul=!0,sc=i}};function t_(i,s,d,p,x,w,C,T,R){ul=!1,sc=null,JO.apply(e_,arguments)}function r_(i,s,d,p,x,w,C,T,R){if(t_.apply(this,arguments),ul){if(ul){var Q=sc;ul=!1,sc=null}else throw Error(r(198));lc||(lc=!0,am=Q)}}function xa(i){var s=i,d=i;if(i.alternate)for(;s.return;)s=s.return;else{i=s;do s=i,(s.flags&4098)!==0&&(d=s.return),i=s.return;while(i)}return s.tag===3?d:null}function mx(i){if(i.tag===13){var s=i.memoizedState;if(s===null&&(i=i.alternate,i!==null&&(s=i.memoizedState)),s!==null)return s.dehydrated}return null}function px(i){if(xa(i)!==i)throw Error(r(188))}function n_(i){var s=i.alternate;if(!s){if(s=xa(i),s===null)throw Error(r(188));return s!==i?null:i}for(var d=i,p=s;;){var x=d.return;if(x===null)break;var w=x.alternate;if(w===null){if(p=x.return,p!==null){d=p;continue}break}if(x.child===w.child){for(w=x.child;w;){if(w===d)return px(x),i;if(w===p)return px(x),s;w=w.sibling}throw Error(r(188))}if(d.return!==p.return)d=x,p=w;else{for(var C=!1,T=x.child;T;){if(T===d){C=!0,d=x,p=w;break}if(T===p){C=!0,p=x,d=w;break}T=T.sibling}if(!C){for(T=w.child;T;){if(T===d){C=!0,d=w,p=x;break}if(T===p){C=!0,p=w,d=x;break}T=T.sibling}if(!C)throw Error(r(189))}}if(d.alternate!==p)throw Error(r(190))}if(d.tag!==3)throw Error(r(188));return d.stateNode.current===d?i:s}function gx(i){return i=n_(i),i!==null?vx(i):null}function vx(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=vx(i);if(s!==null)return s;i=i.sibling}return null}var yx=t.unstable_scheduleCallback,xx=t.unstable_cancelCallback,i_=t.unstable_shouldYield,a_=t.unstable_requestPaint,yt=t.unstable_now,o_=t.unstable_getCurrentPriorityLevel,om=t.unstable_ImmediatePriority,bx=t.unstable_UserBlockingPriority,uc=t.unstable_NormalPriority,s_=t.unstable_LowPriority,wx=t.unstable_IdlePriority,cc=null,wn=null;function l_(i){if(wn&&typeof wn.onCommitFiberRoot=="function")try{wn.onCommitFiberRoot(cc,i,void 0,(i.current.flags&128)===128)}catch{}}var rn=Math.clz32?Math.clz32:d_,u_=Math.log,c_=Math.LN2;function d_(i){return i>>>=0,i===0?32:31-(u_(i)/c_|0)|0}var dc=64,fc=4194304;function cl(i){switch(i&-i){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 i&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return i&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return i}}function hc(i,s){var d=i.pendingLanes;if(d===0)return 0;var p=0,x=i.suspendedLanes,w=i.pingedLanes,C=d&268435455;if(C!==0){var T=C&~x;T!==0?p=cl(T):(w&=C,w!==0&&(p=cl(w)))}else C=d&~x,C!==0?p=cl(C):w!==0&&(p=cl(w));if(p===0)return 0;if(s!==0&&s!==p&&(s&x)===0&&(x=p&-p,w=s&-s,x>=w||x===16&&(w&4194240)!==0))return s;if((p&4)!==0&&(p|=d&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=p;0<s;)d=31-rn(s),x=1<<d,p|=i[d],s&=~x;return p}function f_(i,s){switch(i){case 1:case 2:case 4:return s+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 s+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 h_(i,s){for(var d=i.suspendedLanes,p=i.pingedLanes,x=i.expirationTimes,w=i.pendingLanes;0<w;){var C=31-rn(w),T=1<<C,R=x[C];R===-1?((T&d)===0||(T&p)!==0)&&(x[C]=f_(T,s)):R<=s&&(i.expiredLanes|=T),w&=~T}}function sm(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function kx(){var i=dc;return dc<<=1,(dc&4194240)===0&&(dc=64),i}function lm(i){for(var s=[],d=0;31>d;d++)s.push(i);return s}function dl(i,s,d){i.pendingLanes|=s,s!==536870912&&(i.suspendedLanes=0,i.pingedLanes=0),i=i.eventTimes,s=31-rn(s),i[s]=d}function m_(i,s){var d=i.pendingLanes&~s;i.pendingLanes=s,i.suspendedLanes=0,i.pingedLanes=0,i.expiredLanes&=s,i.mutableReadLanes&=s,i.entangledLanes&=s,s=i.entanglements;var p=i.eventTimes;for(i=i.expirationTimes;0<d;){var x=31-rn(d),w=1<<x;s[x]=0,p[x]=-1,i[x]=-1,d&=~w}}function um(i,s){var d=i.entangledLanes|=s;for(i=i.entanglements;d;){var p=31-rn(d),x=1<<p;x&s|i[p]&s&&(i[p]|=s),d&=~x}}var Ze=0;function jx(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var Sx,cm,Nx,Ex,Ax,dm=!1,mc=[],Ei=null,Ai=null,Ci=null,fl=new Map,hl=new Map,Pi=[],p_="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 Cx(i,s){switch(i){case"focusin":case"focusout":Ei=null;break;case"dragenter":case"dragleave":Ai=null;break;case"mouseover":case"mouseout":Ci=null;break;case"pointerover":case"pointerout":fl.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":hl.delete(s.pointerId)}}function ml(i,s,d,p,x,w){return i===null||i.nativeEvent!==w?(i={blockedOn:s,domEventName:d,eventSystemFlags:p,nativeEvent:w,targetContainers:[x]},s!==null&&(s=Cl(s),s!==null&&cm(s)),i):(i.eventSystemFlags|=p,s=i.targetContainers,x!==null&&s.indexOf(x)===-1&&s.push(x),i)}function g_(i,s,d,p,x){switch(s){case"focusin":return Ei=ml(Ei,i,s,d,p,x),!0;case"dragenter":return Ai=ml(Ai,i,s,d,p,x),!0;case"mouseover":return Ci=ml(Ci,i,s,d,p,x),!0;case"pointerover":var w=x.pointerId;return fl.set(w,ml(fl.get(w)||null,i,s,d,p,x)),!0;case"gotpointercapture":return w=x.pointerId,hl.set(w,ml(hl.get(w)||null,i,s,d,p,x)),!0}return!1}function Px(i){var s=ba(i.target);if(s!==null){var d=xa(s);if(d!==null){if(s=d.tag,s===13){if(s=mx(d),s!==null){i.blockedOn=s,Ax(i.priority,function(){Nx(d)});return}}else if(s===3&&d.stateNode.current.memoizedState.isDehydrated){i.blockedOn=d.tag===3?d.stateNode.containerInfo:null;return}}}i.blockedOn=null}function pc(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var d=hm(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(d===null){d=i.nativeEvent;var p=new d.constructor(d.type,d);em=p,d.target.dispatchEvent(p),em=null}else return s=Cl(d),s!==null&&cm(s),i.blockedOn=d,!1;s.shift()}return!0}function Ox(i,s,d){pc(i)&&d.delete(s)}function v_(){dm=!1,Ei!==null&&pc(Ei)&&(Ei=null),Ai!==null&&pc(Ai)&&(Ai=null),Ci!==null&&pc(Ci)&&(Ci=null),fl.forEach(Ox),hl.forEach(Ox)}function pl(i,s){i.blockedOn===s&&(i.blockedOn=null,dm||(dm=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,v_)))}function gl(i){function s(x){return pl(x,i)}if(0<mc.length){pl(mc[0],i);for(var d=1;d<mc.length;d++){var p=mc[d];p.blockedOn===i&&(p.blockedOn=null)}}for(Ei!==null&&pl(Ei,i),Ai!==null&&pl(Ai,i),Ci!==null&&pl(Ci,i),fl.forEach(s),hl.forEach(s),d=0;d<Pi.length;d++)p=Pi[d],p.blockedOn===i&&(p.blockedOn=null);for(;0<Pi.length&&(d=Pi[0],d.blockedOn===null);)Px(d),d.blockedOn===null&&Pi.shift()}var Eo=P.ReactCurrentBatchConfig,gc=!0;function y_(i,s,d,p){var x=Ze,w=Eo.transition;Eo.transition=null;try{Ze=1,fm(i,s,d,p)}finally{Ze=x,Eo.transition=w}}function x_(i,s,d,p){var x=Ze,w=Eo.transition;Eo.transition=null;try{Ze=4,fm(i,s,d,p)}finally{Ze=x,Eo.transition=w}}function fm(i,s,d,p){if(gc){var x=hm(i,s,d,p);if(x===null)Om(i,s,p,vc,d),Cx(i,p);else if(g_(x,i,s,d,p))p.stopPropagation();else if(Cx(i,p),s&4&&-1<p_.indexOf(i)){for(;x!==null;){var w=Cl(x);if(w!==null&&Sx(w),w=hm(i,s,d,p),w===null&&Om(i,s,p,vc,d),w===x)break;x=w}x!==null&&p.stopPropagation()}else Om(i,s,p,null,d)}}var vc=null;function hm(i,s,d,p){if(vc=null,i=tm(p),i=ba(i),i!==null)if(s=xa(i),s===null)i=null;else if(d=s.tag,d===13){if(i=mx(s),i!==null)return i;i=null}else if(d===3){if(s.stateNode.current.memoizedState.isDehydrated)return s.tag===3?s.stateNode.containerInfo:null;i=null}else s!==i&&(i=null);return vc=i,null}function _x(i){switch(i){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(o_()){case om:return 1;case bx:return 4;case uc:case s_:return 16;case wx:return 536870912;default:return 16}default:return 16}}var Oi=null,mm=null,yc=null;function Mx(){if(yc)return yc;var i,s=mm,d=s.length,p,x="value"in Oi?Oi.value:Oi.textContent,w=x.length;for(i=0;i<d&&s[i]===x[i];i++);var C=d-i;for(p=1;p<=C&&s[d-p]===x[w-p];p++);return yc=x.slice(i,1<p?1-p:void 0)}function xc(i){var s=i.keyCode;return"charCode"in i?(i=i.charCode,i===0&&s===13&&(i=13)):i=s,i===10&&(i=13),32<=i||i===13?i:0}function bc(){return!0}function Ix(){return!1}function Er(i){function s(d,p,x,w,C){this._reactName=d,this._targetInst=x,this.type=p,this.nativeEvent=w,this.target=C,this.currentTarget=null;for(var T in i)i.hasOwnProperty(T)&&(d=i[T],this[T]=d?d(w):w[T]);return this.isDefaultPrevented=(w.defaultPrevented!=null?w.defaultPrevented:w.returnValue===!1)?bc:Ix,this.isPropagationStopped=Ix,this}return J(s.prototype,{preventDefault:function(){this.defaultPrevented=!0;var d=this.nativeEvent;d&&(d.preventDefault?d.preventDefault():typeof d.returnValue!="unknown"&&(d.returnValue=!1),this.isDefaultPrevented=bc)},stopPropagation:function(){var d=this.nativeEvent;d&&(d.stopPropagation?d.stopPropagation():typeof d.cancelBubble!="unknown"&&(d.cancelBubble=!0),this.isPropagationStopped=bc)},persist:function(){},isPersistent:bc}),s}var Ao={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},pm=Er(Ao),vl=J({},Ao,{view:0,detail:0}),b_=Er(vl),gm,vm,yl,wc=J({},vl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:xm,button:0,buttons:0,relatedTarget:function(i){return i.relatedTarget===void 0?i.fromElement===i.srcElement?i.toElement:i.fromElement:i.relatedTarget},movementX:function(i){return"movementX"in i?i.movementX:(i!==yl&&(yl&&i.type==="mousemove"?(gm=i.screenX-yl.screenX,vm=i.screenY-yl.screenY):vm=gm=0,yl=i),gm)},movementY:function(i){return"movementY"in i?i.movementY:vm}}),Tx=Er(wc),w_=J({},wc,{dataTransfer:0}),k_=Er(w_),j_=J({},vl,{relatedTarget:0}),ym=Er(j_),S_=J({},Ao,{animationName:0,elapsedTime:0,pseudoElement:0}),N_=Er(S_),E_=J({},Ao,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),A_=Er(E_),C_=J({},Ao,{data:0}),Dx=Er(C_),P_={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},O_={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"},__={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function M_(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=__[i])?!!s[i]:!1}function xm(){return M_}var I_=J({},vl,{key:function(i){if(i.key){var s=P_[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=xc(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?O_[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:xm,charCode:function(i){return i.type==="keypress"?xc(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?xc(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),T_=Er(I_),D_=J({},wc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Rx=Er(D_),R_=J({},vl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:xm}),L_=Er(R_),$_=J({},Ao,{propertyName:0,elapsedTime:0,pseudoElement:0}),z_=Er($_),F_=J({},wc,{deltaX:function(i){return"deltaX"in i?i.deltaX:"wheelDeltaX"in i?-i.wheelDeltaX:0},deltaY:function(i){return"deltaY"in i?i.deltaY:"wheelDeltaY"in i?-i.wheelDeltaY:"wheelDelta"in i?-i.wheelDelta:0},deltaZ:0,deltaMode:0}),B_=Er(F_),U_=[9,13,27,32],bm=c&&"CompositionEvent"in window,xl=null;c&&"documentMode"in document&&(xl=document.documentMode);var H_=c&&"TextEvent"in window&&!xl,Lx=c&&(!bm||xl&&8<xl&&11>=xl),$x=" ",zx=!1;function Fx(i,s){switch(i){case"keyup":return U_.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Bx(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var Co=!1;function W_(i,s){switch(i){case"compositionend":return Bx(s);case"keypress":return s.which!==32?null:(zx=!0,$x);case"textInput":return i=s.data,i===$x&&zx?null:i;default:return null}}function K_(i,s){if(Co)return i==="compositionend"||!bm&&Fx(i,s)?(i=Mx(),yc=mm=Oi=null,Co=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return Lx&&s.locale!=="ko"?null:s.data;default:return null}}var G_={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 Ux(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!G_[i.type]:s==="textarea"}function Hx(i,s,d,p){ux(p),s=Ec(s,"onChange"),0<s.length&&(d=new pm("onChange","change",null,d,p),i.push({event:d,listeners:s}))}var bl=null,wl=null;function V_(i){sb(i,0)}function kc(i){var s=Io(i);if(ae(s))return i}function q_(i,s){if(i==="change")return s}var Wx=!1;if(c){var wm;if(c){var km="oninput"in document;if(!km){var Kx=document.createElement("div");Kx.setAttribute("oninput","return;"),km=typeof Kx.oninput=="function"}wm=km}else wm=!1;Wx=wm&&(!document.documentMode||9<document.documentMode)}function Gx(){bl&&(bl.detachEvent("onpropertychange",Vx),wl=bl=null)}function Vx(i){if(i.propertyName==="value"&&kc(wl)){var s=[];Hx(s,wl,i,tm(i)),hx(V_,s)}}function Q_(i,s,d){i==="focusin"?(Gx(),bl=s,wl=d,bl.attachEvent("onpropertychange",Vx)):i==="focusout"&&Gx()}function Y_(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return kc(wl)}function X_(i,s){if(i==="click")return kc(s)}function Z_(i,s){if(i==="input"||i==="change")return kc(s)}function J_(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var nn=typeof Object.is=="function"?Object.is:J_;function kl(i,s){if(nn(i,s))return!0;if(typeof i!="object"||i===null||typeof s!="object"||s===null)return!1;var d=Object.keys(i),p=Object.keys(s);if(d.length!==p.length)return!1;for(p=0;p<d.length;p++){var x=d[p];if(!f.call(s,x)||!nn(i[x],s[x]))return!1}return!0}function qx(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function Qx(i,s){var d=qx(i);i=0;for(var p;d;){if(d.nodeType===3){if(p=i+d.textContent.length,i<=s&&p>=s)return{node:d,offset:s-i};i=p}e:{for(;d;){if(d.nextSibling){d=d.nextSibling;break e}d=d.parentNode}d=void 0}d=qx(d)}}function Yx(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?Yx(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function Xx(){for(var i=window,s=et();s instanceof i.HTMLIFrameElement;){try{var d=typeof s.contentWindow.location.href=="string"}catch{d=!1}if(d)i=s.contentWindow;else break;s=et(i.document)}return s}function jm(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s&&(s==="input"&&(i.type==="text"||i.type==="search"||i.type==="tel"||i.type==="url"||i.type==="password")||s==="textarea"||i.contentEditable==="true")}function e3(i){var s=Xx(),d=i.focusedElem,p=i.selectionRange;if(s!==d&&d&&d.ownerDocument&&Yx(d.ownerDocument.documentElement,d)){if(p!==null&&jm(d)){if(s=p.start,i=p.end,i===void 0&&(i=s),"selectionStart"in d)d.selectionStart=s,d.selectionEnd=Math.min(i,d.value.length);else if(i=(s=d.ownerDocument||document)&&s.defaultView||window,i.getSelection){i=i.getSelection();var x=d.textContent.length,w=Math.min(p.start,x);p=p.end===void 0?w:Math.min(p.end,x),!i.extend&&w>p&&(x=p,p=w,w=x),x=Qx(d,w);var C=Qx(d,p);x&&C&&(i.rangeCount!==1||i.anchorNode!==x.node||i.anchorOffset!==x.offset||i.focusNode!==C.node||i.focusOffset!==C.offset)&&(s=s.createRange(),s.setStart(x.node,x.offset),i.removeAllRanges(),w>p?(i.addRange(s),i.extend(C.node,C.offset)):(s.setEnd(C.node,C.offset),i.addRange(s)))}}for(s=[],i=d;i=i.parentNode;)i.nodeType===1&&s.push({element:i,left:i.scrollLeft,top:i.scrollTop});for(typeof d.focus=="function"&&d.focus(),d=0;d<s.length;d++)i=s[d],i.element.scrollLeft=i.left,i.element.scrollTop=i.top}}var t3=c&&"documentMode"in document&&11>=document.documentMode,Po=null,Sm=null,jl=null,Nm=!1;function Zx(i,s,d){var p=d.window===d?d.document:d.nodeType===9?d:d.ownerDocument;Nm||Po==null||Po!==et(p)||(p=Po,"selectionStart"in p&&jm(p)?p={start:p.selectionStart,end:p.selectionEnd}:(p=(p.ownerDocument&&p.ownerDocument.defaultView||window).getSelection(),p={anchorNode:p.anchorNode,anchorOffset:p.anchorOffset,focusNode:p.focusNode,focusOffset:p.focusOffset}),jl&&kl(jl,p)||(jl=p,p=Ec(Sm,"onSelect"),0<p.length&&(s=new pm("onSelect","select",null,s,d),i.push({event:s,listeners:p}),s.target=Po)))}function jc(i,s){var d={};return d[i.toLowerCase()]=s.toLowerCase(),d["Webkit"+i]="webkit"+s,d["Moz"+i]="moz"+s,d}var Oo={animationend:jc("Animation","AnimationEnd"),animationiteration:jc("Animation","AnimationIteration"),animationstart:jc("Animation","AnimationStart"),transitionend:jc("Transition","TransitionEnd")},Em={},Jx={};c&&(Jx=document.createElement("div").style,"AnimationEvent"in window||(delete Oo.animationend.animation,delete Oo.animationiteration.animation,delete Oo.animationstart.animation),"TransitionEvent"in window||delete Oo.transitionend.transition);function Sc(i){if(Em[i])return Em[i];if(!Oo[i])return i;var s=Oo[i],d;for(d in s)if(s.hasOwnProperty(d)&&d in Jx)return Em[i]=s[d];return i}var eb=Sc("animationend"),tb=Sc("animationiteration"),rb=Sc("animationstart"),nb=Sc("transitionend"),ib=new Map,ab="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 _i(i,s){ib.set(i,s),o(s,[i])}for(var Am=0;Am<ab.length;Am++){var Cm=ab[Am],r3=Cm.toLowerCase(),n3=Cm[0].toUpperCase()+Cm.slice(1);_i(r3,"on"+n3)}_i(eb,"onAnimationEnd"),_i(tb,"onAnimationIteration"),_i(rb,"onAnimationStart"),_i("dblclick","onDoubleClick"),_i("focusin","onFocus"),_i("focusout","onBlur"),_i(nb,"onTransitionEnd"),u("onMouseEnter",["mouseout","mouseover"]),u("onMouseLeave",["mouseout","mouseover"]),u("onPointerEnter",["pointerout","pointerover"]),u("onPointerLeave",["pointerout","pointerover"]),o("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),o("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),o("onBeforeInput",["compositionend","keypress","textInput","paste"]),o("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),o("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),o("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Sl="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(" "),i3=new Set("cancel close invalid load scroll toggle".split(" ").concat(Sl));function ob(i,s,d){var p=i.type||"unknown-event";i.currentTarget=d,r_(p,s,void 0,i),i.currentTarget=null}function sb(i,s){s=(s&4)!==0;for(var d=0;d<i.length;d++){var p=i[d],x=p.event;p=p.listeners;e:{var w=void 0;if(s)for(var C=p.length-1;0<=C;C--){var T=p[C],R=T.instance,Q=T.currentTarget;if(T=T.listener,R!==w&&x.isPropagationStopped())break e;ob(x,T,Q),w=R}else for(C=0;C<p.length;C++){if(T=p[C],R=T.instance,Q=T.currentTarget,T=T.listener,R!==w&&x.isPropagationStopped())break e;ob(x,T,Q),w=R}}}if(lc)throw i=am,lc=!1,am=null,i}function nt(i,s){var d=s[Rm];d===void 0&&(d=s[Rm]=new Set);var p=i+"__bubble";d.has(p)||(lb(s,i,2,!1),d.add(p))}function Pm(i,s,d){var p=0;s&&(p|=4),lb(d,i,p,s)}var Nc="_reactListening"+Math.random().toString(36).slice(2);function Nl(i){if(!i[Nc]){i[Nc]=!0,n.forEach(function(d){d!=="selectionchange"&&(i3.has(d)||Pm(d,!1,i),Pm(d,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[Nc]||(s[Nc]=!0,Pm("selectionchange",!1,s))}}function lb(i,s,d,p){switch(_x(s)){case 1:var x=y_;break;case 4:x=x_;break;default:x=fm}d=x.bind(null,s,d,i),x=void 0,!im||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(x=!0),p?x!==void 0?i.addEventListener(s,d,{capture:!0,passive:x}):i.addEventListener(s,d,!0):x!==void 0?i.addEventListener(s,d,{passive:x}):i.addEventListener(s,d,!1)}function Om(i,s,d,p,x){var w=p;if((s&1)===0&&(s&2)===0&&p!==null)e:for(;;){if(p===null)return;var C=p.tag;if(C===3||C===4){var T=p.stateNode.containerInfo;if(T===x||T.nodeType===8&&T.parentNode===x)break;if(C===4)for(C=p.return;C!==null;){var R=C.tag;if((R===3||R===4)&&(R=C.stateNode.containerInfo,R===x||R.nodeType===8&&R.parentNode===x))return;C=C.return}for(;T!==null;){if(C=ba(T),C===null)return;if(R=C.tag,R===5||R===6){p=w=C;continue e}T=T.parentNode}}p=p.return}hx(function(){var Q=w,le=tm(d),ce=[];e:{var oe=ib.get(i);if(oe!==void 0){var ve=pm,ke=i;switch(i){case"keypress":if(xc(d)===0)break e;case"keydown":case"keyup":ve=T_;break;case"focusin":ke="focus",ve=ym;break;case"focusout":ke="blur",ve=ym;break;case"beforeblur":case"afterblur":ve=ym;break;case"click":if(d.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ve=Tx;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ve=k_;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ve=L_;break;case eb:case tb:case rb:ve=N_;break;case nb:ve=z_;break;case"scroll":ve=b_;break;case"wheel":ve=B_;break;case"copy":case"cut":case"paste":ve=A_;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ve=Rx}var Ne=(s&4)!==0,xt=!Ne&&i==="scroll",W=Ne?oe!==null?oe+"Capture":null:oe;Ne=[];for(var $=Q,V;$!==null;){V=$;var fe=V.stateNode;if(V.tag===5&&fe!==null&&(V=fe,W!==null&&(fe=sl($,W),fe!=null&&Ne.push(El($,fe,V)))),xt)break;$=$.return}0<Ne.length&&(oe=new ve(oe,ke,null,d,le),ce.push({event:oe,listeners:Ne}))}}if((s&7)===0){e:{if(oe=i==="mouseover"||i==="pointerover",ve=i==="mouseout"||i==="pointerout",oe&&d!==em&&(ke=d.relatedTarget||d.fromElement)&&(ba(ke)||ke[qn]))break e;if((ve||oe)&&(oe=le.window===le?le:(oe=le.ownerDocument)?oe.defaultView||oe.parentWindow:window,ve?(ke=d.relatedTarget||d.toElement,ve=Q,ke=ke?ba(ke):null,ke!==null&&(xt=xa(ke),ke!==xt||ke.tag!==5&&ke.tag!==6)&&(ke=null)):(ve=null,ke=Q),ve!==ke)){if(Ne=Tx,fe="onMouseLeave",W="onMouseEnter",$="mouse",(i==="pointerout"||i==="pointerover")&&(Ne=Rx,fe="onPointerLeave",W="onPointerEnter",$="pointer"),xt=ve==null?oe:Io(ve),V=ke==null?oe:Io(ke),oe=new Ne(fe,$+"leave",ve,d,le),oe.target=xt,oe.relatedTarget=V,fe=null,ba(le)===Q&&(Ne=new Ne(W,$+"enter",ke,d,le),Ne.target=V,Ne.relatedTarget=xt,fe=Ne),xt=fe,ve&&ke)t:{for(Ne=ve,W=ke,$=0,V=Ne;V;V=_o(V))$++;for(V=0,fe=W;fe;fe=_o(fe))V++;for(;0<$-V;)Ne=_o(Ne),$--;for(;0<V-$;)W=_o(W),V--;for(;$--;){if(Ne===W||W!==null&&Ne===W.alternate)break t;Ne=_o(Ne),W=_o(W)}Ne=null}else Ne=null;ve!==null&&ub(ce,oe,ve,Ne,!1),ke!==null&&xt!==null&&ub(ce,xt,ke,Ne,!0)}}e:{if(oe=Q?Io(Q):window,ve=oe.nodeName&&oe.nodeName.toLowerCase(),ve==="select"||ve==="input"&&oe.type==="file")var Ce=q_;else if(Ux(oe))if(Wx)Ce=Z_;else{Ce=Y_;var Te=Q_}else(ve=oe.nodeName)&&ve.toLowerCase()==="input"&&(oe.type==="checkbox"||oe.type==="radio")&&(Ce=X_);if(Ce&&(Ce=Ce(i,Q))){Hx(ce,Ce,d,le);break e}Te&&Te(i,oe,Q),i==="focusout"&&(Te=oe._wrapperState)&&Te.controlled&&oe.type==="number"&&Ae(oe,"number",oe.value)}switch(Te=Q?Io(Q):window,i){case"focusin":(Ux(Te)||Te.contentEditable==="true")&&(Po=Te,Sm=Q,jl=null);break;case"focusout":jl=Sm=Po=null;break;case"mousedown":Nm=!0;break;case"contextmenu":case"mouseup":case"dragend":Nm=!1,Zx(ce,d,le);break;case"selectionchange":if(t3)break;case"keydown":case"keyup":Zx(ce,d,le)}var De;if(bm)e:{switch(i){case"compositionstart":var Le="onCompositionStart";break e;case"compositionend":Le="onCompositionEnd";break e;case"compositionupdate":Le="onCompositionUpdate";break e}Le=void 0}else Co?Fx(i,d)&&(Le="onCompositionEnd"):i==="keydown"&&d.keyCode===229&&(Le="onCompositionStart");Le&&(Lx&&d.locale!=="ko"&&(Co||Le!=="onCompositionStart"?Le==="onCompositionEnd"&&Co&&(De=Mx()):(Oi=le,mm="value"in Oi?Oi.value:Oi.textContent,Co=!0)),Te=Ec(Q,Le),0<Te.length&&(Le=new Dx(Le,i,null,d,le),ce.push({event:Le,listeners:Te}),De?Le.data=De:(De=Bx(d),De!==null&&(Le.data=De)))),(De=H_?W_(i,d):K_(i,d))&&(Q=Ec(Q,"onBeforeInput"),0<Q.length&&(le=new Dx("onBeforeInput","beforeinput",null,d,le),ce.push({event:le,listeners:Q}),le.data=De))}sb(ce,s)})}function El(i,s,d){return{instance:i,listener:s,currentTarget:d}}function Ec(i,s){for(var d=s+"Capture",p=[];i!==null;){var x=i,w=x.stateNode;x.tag===5&&w!==null&&(x=w,w=sl(i,d),w!=null&&p.unshift(El(i,w,x)),w=sl(i,s),w!=null&&p.push(El(i,w,x))),i=i.return}return p}function _o(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function ub(i,s,d,p,x){for(var w=s._reactName,C=[];d!==null&&d!==p;){var T=d,R=T.alternate,Q=T.stateNode;if(R!==null&&R===p)break;T.tag===5&&Q!==null&&(T=Q,x?(R=sl(d,w),R!=null&&C.unshift(El(d,R,T))):x||(R=sl(d,w),R!=null&&C.push(El(d,R,T)))),d=d.return}C.length!==0&&i.push({event:s,listeners:C})}var a3=/\r\n?/g,o3=/\u0000|\uFFFD/g;function cb(i){return(typeof i=="string"?i:""+i).replace(a3,`
|
||
`).replace(o3,"")}function Ac(i,s,d){if(s=cb(s),cb(i)!==s&&d)throw Error(r(425))}function Cc(){}var _m=null,Mm=null;function Im(i,s){return i==="textarea"||i==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}var Tm=typeof setTimeout=="function"?setTimeout:void 0,s3=typeof clearTimeout=="function"?clearTimeout:void 0,db=typeof Promise=="function"?Promise:void 0,l3=typeof queueMicrotask=="function"?queueMicrotask:typeof db<"u"?function(i){return db.resolve(null).then(i).catch(u3)}:Tm;function u3(i){setTimeout(function(){throw i})}function Dm(i,s){var d=s,p=0;do{var x=d.nextSibling;if(i.removeChild(d),x&&x.nodeType===8)if(d=x.data,d==="/$"){if(p===0){i.removeChild(x),gl(s);return}p--}else d!=="$"&&d!=="$?"&&d!=="$!"||p++;d=x}while(d);gl(s)}function Mi(i){for(;i!=null;i=i.nextSibling){var s=i.nodeType;if(s===1||s===3)break;if(s===8){if(s=i.data,s==="$"||s==="$!"||s==="$?")break;if(s==="/$")return null}}return i}function fb(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var d=i.data;if(d==="$"||d==="$!"||d==="$?"){if(s===0)return i;s--}else d==="/$"&&s++}i=i.previousSibling}return null}var Mo=Math.random().toString(36).slice(2),kn="__reactFiber$"+Mo,Al="__reactProps$"+Mo,qn="__reactContainer$"+Mo,Rm="__reactEvents$"+Mo,c3="__reactListeners$"+Mo,d3="__reactHandles$"+Mo;function ba(i){var s=i[kn];if(s)return s;for(var d=i.parentNode;d;){if(s=d[qn]||d[kn]){if(d=s.alternate,s.child!==null||d!==null&&d.child!==null)for(i=fb(i);i!==null;){if(d=i[kn])return d;i=fb(i)}return s}i=d,d=i.parentNode}return null}function Cl(i){return i=i[kn]||i[qn],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function Io(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(r(33))}function Pc(i){return i[Al]||null}var Lm=[],To=-1;function Ii(i){return{current:i}}function it(i){0>To||(i.current=Lm[To],Lm[To]=null,To--)}function tt(i,s){To++,Lm[To]=i.current,i.current=s}var Ti={},Zt=Ii(Ti),pr=Ii(!1),wa=Ti;function Do(i,s){var d=i.type.contextTypes;if(!d)return Ti;var p=i.stateNode;if(p&&p.__reactInternalMemoizedUnmaskedChildContext===s)return p.__reactInternalMemoizedMaskedChildContext;var x={},w;for(w in d)x[w]=s[w];return p&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=x),x}function gr(i){return i=i.childContextTypes,i!=null}function Oc(){it(pr),it(Zt)}function hb(i,s,d){if(Zt.current!==Ti)throw Error(r(168));tt(Zt,s),tt(pr,d)}function mb(i,s,d){var p=i.stateNode;if(s=s.childContextTypes,typeof p.getChildContext!="function")return d;p=p.getChildContext();for(var x in p)if(!(x in s))throw Error(r(108,pe(i)||"Unknown",x));return J({},d,p)}function _c(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||Ti,wa=Zt.current,tt(Zt,i),tt(pr,pr.current),!0}function pb(i,s,d){var p=i.stateNode;if(!p)throw Error(r(169));d?(i=mb(i,s,wa),p.__reactInternalMemoizedMergedChildContext=i,it(pr),it(Zt),tt(Zt,i)):it(pr),tt(pr,d)}var Qn=null,Mc=!1,$m=!1;function gb(i){Qn===null?Qn=[i]:Qn.push(i)}function f3(i){Mc=!0,gb(i)}function Di(){if(!$m&&Qn!==null){$m=!0;var i=0,s=Ze;try{var d=Qn;for(Ze=1;i<d.length;i++){var p=d[i];do p=p(!0);while(p!==null)}Qn=null,Mc=!1}catch(x){throw Qn!==null&&(Qn=Qn.slice(i+1)),yx(om,Di),x}finally{Ze=s,$m=!1}}return null}var Ro=[],Lo=0,Ic=null,Tc=0,zr=[],Fr=0,ka=null,Yn=1,Xn="";function ja(i,s){Ro[Lo++]=Tc,Ro[Lo++]=Ic,Ic=i,Tc=s}function vb(i,s,d){zr[Fr++]=Yn,zr[Fr++]=Xn,zr[Fr++]=ka,ka=i;var p=Yn;i=Xn;var x=32-rn(p)-1;p&=~(1<<x),d+=1;var w=32-rn(s)+x;if(30<w){var C=x-x%5;w=(p&(1<<C)-1).toString(32),p>>=C,x-=C,Yn=1<<32-rn(s)+x|d<<x|p,Xn=w+i}else Yn=1<<w|d<<x|p,Xn=i}function zm(i){i.return!==null&&(ja(i,1),vb(i,1,0))}function Fm(i){for(;i===Ic;)Ic=Ro[--Lo],Ro[Lo]=null,Tc=Ro[--Lo],Ro[Lo]=null;for(;i===ka;)ka=zr[--Fr],zr[Fr]=null,Xn=zr[--Fr],zr[Fr]=null,Yn=zr[--Fr],zr[Fr]=null}var Ar=null,Cr=null,lt=!1,an=null;function yb(i,s){var d=Wr(5,null,null,0);d.elementType="DELETED",d.stateNode=s,d.return=i,s=i.deletions,s===null?(i.deletions=[d],i.flags|=16):s.push(d)}function xb(i,s){switch(i.tag){case 5:var d=i.type;return s=s.nodeType!==1||d.toLowerCase()!==s.nodeName.toLowerCase()?null:s,s!==null?(i.stateNode=s,Ar=i,Cr=Mi(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Ar=i,Cr=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(d=ka!==null?{id:Yn,overflow:Xn}:null,i.memoizedState={dehydrated:s,treeContext:d,retryLane:1073741824},d=Wr(18,null,null,0),d.stateNode=s,d.return=i,i.child=d,Ar=i,Cr=null,!0):!1;default:return!1}}function Bm(i){return(i.mode&1)!==0&&(i.flags&128)===0}function Um(i){if(lt){var s=Cr;if(s){var d=s;if(!xb(i,s)){if(Bm(i))throw Error(r(418));s=Mi(d.nextSibling);var p=Ar;s&&xb(i,s)?yb(p,d):(i.flags=i.flags&-4097|2,lt=!1,Ar=i)}}else{if(Bm(i))throw Error(r(418));i.flags=i.flags&-4097|2,lt=!1,Ar=i}}}function bb(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Ar=i}function Dc(i){if(i!==Ar)return!1;if(!lt)return bb(i),lt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!Im(i.type,i.memoizedProps)),s&&(s=Cr)){if(Bm(i))throw wb(),Error(r(418));for(;s;)yb(i,s),s=Mi(s.nextSibling)}if(bb(i),i.tag===13){if(i=i.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(r(317));e:{for(i=i.nextSibling,s=0;i;){if(i.nodeType===8){var d=i.data;if(d==="/$"){if(s===0){Cr=Mi(i.nextSibling);break e}s--}else d!=="$"&&d!=="$!"&&d!=="$?"||s++}i=i.nextSibling}Cr=null}}else Cr=Ar?Mi(i.stateNode.nextSibling):null;return!0}function wb(){for(var i=Cr;i;)i=Mi(i.nextSibling)}function $o(){Cr=Ar=null,lt=!1}function Hm(i){an===null?an=[i]:an.push(i)}var h3=P.ReactCurrentBatchConfig;function Pl(i,s,d){if(i=d.ref,i!==null&&typeof i!="function"&&typeof i!="object"){if(d._owner){if(d=d._owner,d){if(d.tag!==1)throw Error(r(309));var p=d.stateNode}if(!p)throw Error(r(147,i));var x=p,w=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===w?s.ref:(s=function(C){var T=x.refs;C===null?delete T[w]:T[w]=C},s._stringRef=w,s)}if(typeof i!="string")throw Error(r(284));if(!d._owner)throw Error(r(290,i))}return i}function Rc(i,s){throw i=Object.prototype.toString.call(s),Error(r(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function kb(i){var s=i._init;return s(i._payload)}function jb(i){function s(W,$){if(i){var V=W.deletions;V===null?(W.deletions=[$],W.flags|=16):V.push($)}}function d(W,$){if(!i)return null;for(;$!==null;)s(W,$),$=$.sibling;return null}function p(W,$){for(W=new Map;$!==null;)$.key!==null?W.set($.key,$):W.set($.index,$),$=$.sibling;return W}function x(W,$){return W=Hi(W,$),W.index=0,W.sibling=null,W}function w(W,$,V){return W.index=V,i?(V=W.alternate,V!==null?(V=V.index,V<$?(W.flags|=2,$):V):(W.flags|=2,$)):(W.flags|=1048576,$)}function C(W){return i&&W.alternate===null&&(W.flags|=2),W}function T(W,$,V,fe){return $===null||$.tag!==6?($=Tp(V,W.mode,fe),$.return=W,$):($=x($,V),$.return=W,$)}function R(W,$,V,fe){var Ce=V.type;return Ce===D?le(W,$,V.props.children,fe,V.key):$!==null&&($.elementType===Ce||typeof Ce=="object"&&Ce!==null&&Ce.$$typeof===ie&&kb(Ce)===$.type)?(fe=x($,V.props),fe.ref=Pl(W,$,V),fe.return=W,fe):(fe=od(V.type,V.key,V.props,null,W.mode,fe),fe.ref=Pl(W,$,V),fe.return=W,fe)}function Q(W,$,V,fe){return $===null||$.tag!==4||$.stateNode.containerInfo!==V.containerInfo||$.stateNode.implementation!==V.implementation?($=Dp(V,W.mode,fe),$.return=W,$):($=x($,V.children||[]),$.return=W,$)}function le(W,$,V,fe,Ce){return $===null||$.tag!==7?($=_a(V,W.mode,fe,Ce),$.return=W,$):($=x($,V),$.return=W,$)}function ce(W,$,V){if(typeof $=="string"&&$!==""||typeof $=="number")return $=Tp(""+$,W.mode,V),$.return=W,$;if(typeof $=="object"&&$!==null){switch($.$$typeof){case _:return V=od($.type,$.key,$.props,null,W.mode,V),V.ref=Pl(W,null,$),V.return=W,V;case O:return $=Dp($,W.mode,V),$.return=W,$;case ie:var fe=$._init;return ce(W,fe($._payload),V)}if(Se($)||te($))return $=_a($,W.mode,V,null),$.return=W,$;Rc(W,$)}return null}function oe(W,$,V,fe){var Ce=$!==null?$.key:null;if(typeof V=="string"&&V!==""||typeof V=="number")return Ce!==null?null:T(W,$,""+V,fe);if(typeof V=="object"&&V!==null){switch(V.$$typeof){case _:return V.key===Ce?R(W,$,V,fe):null;case O:return V.key===Ce?Q(W,$,V,fe):null;case ie:return Ce=V._init,oe(W,$,Ce(V._payload),fe)}if(Se(V)||te(V))return Ce!==null?null:le(W,$,V,fe,null);Rc(W,V)}return null}function ve(W,$,V,fe,Ce){if(typeof fe=="string"&&fe!==""||typeof fe=="number")return W=W.get(V)||null,T($,W,""+fe,Ce);if(typeof fe=="object"&&fe!==null){switch(fe.$$typeof){case _:return W=W.get(fe.key===null?V:fe.key)||null,R($,W,fe,Ce);case O:return W=W.get(fe.key===null?V:fe.key)||null,Q($,W,fe,Ce);case ie:var Te=fe._init;return ve(W,$,V,Te(fe._payload),Ce)}if(Se(fe)||te(fe))return W=W.get(V)||null,le($,W,fe,Ce,null);Rc($,fe)}return null}function ke(W,$,V,fe){for(var Ce=null,Te=null,De=$,Le=$=0,Mt=null;De!==null&&Le<V.length;Le++){De.index>Le?(Mt=De,De=null):Mt=De.sibling;var Qe=oe(W,De,V[Le],fe);if(Qe===null){De===null&&(De=Mt);break}i&&De&&Qe.alternate===null&&s(W,De),$=w(Qe,$,Le),Te===null?Ce=Qe:Te.sibling=Qe,Te=Qe,De=Mt}if(Le===V.length)return d(W,De),lt&&ja(W,Le),Ce;if(De===null){for(;Le<V.length;Le++)De=ce(W,V[Le],fe),De!==null&&($=w(De,$,Le),Te===null?Ce=De:Te.sibling=De,Te=De);return lt&&ja(W,Le),Ce}for(De=p(W,De);Le<V.length;Le++)Mt=ve(De,W,Le,V[Le],fe),Mt!==null&&(i&&Mt.alternate!==null&&De.delete(Mt.key===null?Le:Mt.key),$=w(Mt,$,Le),Te===null?Ce=Mt:Te.sibling=Mt,Te=Mt);return i&&De.forEach(function(Wi){return s(W,Wi)}),lt&&ja(W,Le),Ce}function Ne(W,$,V,fe){var Ce=te(V);if(typeof Ce!="function")throw Error(r(150));if(V=Ce.call(V),V==null)throw Error(r(151));for(var Te=Ce=null,De=$,Le=$=0,Mt=null,Qe=V.next();De!==null&&!Qe.done;Le++,Qe=V.next()){De.index>Le?(Mt=De,De=null):Mt=De.sibling;var Wi=oe(W,De,Qe.value,fe);if(Wi===null){De===null&&(De=Mt);break}i&&De&&Wi.alternate===null&&s(W,De),$=w(Wi,$,Le),Te===null?Ce=Wi:Te.sibling=Wi,Te=Wi,De=Mt}if(Qe.done)return d(W,De),lt&&ja(W,Le),Ce;if(De===null){for(;!Qe.done;Le++,Qe=V.next())Qe=ce(W,Qe.value,fe),Qe!==null&&($=w(Qe,$,Le),Te===null?Ce=Qe:Te.sibling=Qe,Te=Qe);return lt&&ja(W,Le),Ce}for(De=p(W,De);!Qe.done;Le++,Qe=V.next())Qe=ve(De,W,Le,Qe.value,fe),Qe!==null&&(i&&Qe.alternate!==null&&De.delete(Qe.key===null?Le:Qe.key),$=w(Qe,$,Le),Te===null?Ce=Qe:Te.sibling=Qe,Te=Qe);return i&&De.forEach(function(G3){return s(W,G3)}),lt&&ja(W,Le),Ce}function xt(W,$,V,fe){if(typeof V=="object"&&V!==null&&V.type===D&&V.key===null&&(V=V.props.children),typeof V=="object"&&V!==null){switch(V.$$typeof){case _:e:{for(var Ce=V.key,Te=$;Te!==null;){if(Te.key===Ce){if(Ce=V.type,Ce===D){if(Te.tag===7){d(W,Te.sibling),$=x(Te,V.props.children),$.return=W,W=$;break e}}else if(Te.elementType===Ce||typeof Ce=="object"&&Ce!==null&&Ce.$$typeof===ie&&kb(Ce)===Te.type){d(W,Te.sibling),$=x(Te,V.props),$.ref=Pl(W,Te,V),$.return=W,W=$;break e}d(W,Te);break}else s(W,Te);Te=Te.sibling}V.type===D?($=_a(V.props.children,W.mode,fe,V.key),$.return=W,W=$):(fe=od(V.type,V.key,V.props,null,W.mode,fe),fe.ref=Pl(W,$,V),fe.return=W,W=fe)}return C(W);case O:e:{for(Te=V.key;$!==null;){if($.key===Te)if($.tag===4&&$.stateNode.containerInfo===V.containerInfo&&$.stateNode.implementation===V.implementation){d(W,$.sibling),$=x($,V.children||[]),$.return=W,W=$;break e}else{d(W,$);break}else s(W,$);$=$.sibling}$=Dp(V,W.mode,fe),$.return=W,W=$}return C(W);case ie:return Te=V._init,xt(W,$,Te(V._payload),fe)}if(Se(V))return ke(W,$,V,fe);if(te(V))return Ne(W,$,V,fe);Rc(W,V)}return typeof V=="string"&&V!==""||typeof V=="number"?(V=""+V,$!==null&&$.tag===6?(d(W,$.sibling),$=x($,V),$.return=W,W=$):(d(W,$),$=Tp(V,W.mode,fe),$.return=W,W=$),C(W)):d(W,$)}return xt}var zo=jb(!0),Sb=jb(!1),Lc=Ii(null),$c=null,Fo=null,Wm=null;function Km(){Wm=Fo=$c=null}function Gm(i){var s=Lc.current;it(Lc),i._currentValue=s}function Vm(i,s,d){for(;i!==null;){var p=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,p!==null&&(p.childLanes|=s)):p!==null&&(p.childLanes&s)!==s&&(p.childLanes|=s),i===d)break;i=i.return}}function Bo(i,s){$c=i,Wm=Fo=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(vr=!0),i.firstContext=null)}function Br(i){var s=i._currentValue;if(Wm!==i)if(i={context:i,memoizedValue:s,next:null},Fo===null){if($c===null)throw Error(r(308));Fo=i,$c.dependencies={lanes:0,firstContext:i}}else Fo=Fo.next=i;return s}var Sa=null;function qm(i){Sa===null?Sa=[i]:Sa.push(i)}function Nb(i,s,d,p){var x=s.interleaved;return x===null?(d.next=d,qm(s)):(d.next=x.next,x.next=d),s.interleaved=d,Zn(i,p)}function Zn(i,s){i.lanes|=s;var d=i.alternate;for(d!==null&&(d.lanes|=s),d=i,i=i.return;i!==null;)i.childLanes|=s,d=i.alternate,d!==null&&(d.childLanes|=s),d=i,i=i.return;return d.tag===3?d.stateNode:null}var Ri=!1;function Qm(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Eb(i,s){i=i.updateQueue,s.updateQueue===i&&(s.updateQueue={baseState:i.baseState,firstBaseUpdate:i.firstBaseUpdate,lastBaseUpdate:i.lastBaseUpdate,shared:i.shared,effects:i.effects})}function Jn(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function Li(i,s,d){var p=i.updateQueue;if(p===null)return null;if(p=p.shared,(Ge&2)!==0){var x=p.pending;return x===null?s.next=s:(s.next=x.next,x.next=s),p.pending=s,Zn(i,d)}return x=p.interleaved,x===null?(s.next=s,qm(p)):(s.next=x.next,x.next=s),p.interleaved=s,Zn(i,d)}function zc(i,s,d){if(s=s.updateQueue,s!==null&&(s=s.shared,(d&4194240)!==0)){var p=s.lanes;p&=i.pendingLanes,d|=p,s.lanes=d,um(i,d)}}function Ab(i,s){var d=i.updateQueue,p=i.alternate;if(p!==null&&(p=p.updateQueue,d===p)){var x=null,w=null;if(d=d.firstBaseUpdate,d!==null){do{var C={eventTime:d.eventTime,lane:d.lane,tag:d.tag,payload:d.payload,callback:d.callback,next:null};w===null?x=w=C:w=w.next=C,d=d.next}while(d!==null);w===null?x=w=s:w=w.next=s}else x=w=s;d={baseState:p.baseState,firstBaseUpdate:x,lastBaseUpdate:w,shared:p.shared,effects:p.effects},i.updateQueue=d;return}i=d.lastBaseUpdate,i===null?d.firstBaseUpdate=s:i.next=s,d.lastBaseUpdate=s}function Fc(i,s,d,p){var x=i.updateQueue;Ri=!1;var w=x.firstBaseUpdate,C=x.lastBaseUpdate,T=x.shared.pending;if(T!==null){x.shared.pending=null;var R=T,Q=R.next;R.next=null,C===null?w=Q:C.next=Q,C=R;var le=i.alternate;le!==null&&(le=le.updateQueue,T=le.lastBaseUpdate,T!==C&&(T===null?le.firstBaseUpdate=Q:T.next=Q,le.lastBaseUpdate=R))}if(w!==null){var ce=x.baseState;C=0,le=Q=R=null,T=w;do{var oe=T.lane,ve=T.eventTime;if((p&oe)===oe){le!==null&&(le=le.next={eventTime:ve,lane:0,tag:T.tag,payload:T.payload,callback:T.callback,next:null});e:{var ke=i,Ne=T;switch(oe=s,ve=d,Ne.tag){case 1:if(ke=Ne.payload,typeof ke=="function"){ce=ke.call(ve,ce,oe);break e}ce=ke;break e;case 3:ke.flags=ke.flags&-65537|128;case 0:if(ke=Ne.payload,oe=typeof ke=="function"?ke.call(ve,ce,oe):ke,oe==null)break e;ce=J({},ce,oe);break e;case 2:Ri=!0}}T.callback!==null&&T.lane!==0&&(i.flags|=64,oe=x.effects,oe===null?x.effects=[T]:oe.push(T))}else ve={eventTime:ve,lane:oe,tag:T.tag,payload:T.payload,callback:T.callback,next:null},le===null?(Q=le=ve,R=ce):le=le.next=ve,C|=oe;if(T=T.next,T===null){if(T=x.shared.pending,T===null)break;oe=T,T=oe.next,oe.next=null,x.lastBaseUpdate=oe,x.shared.pending=null}}while(!0);if(le===null&&(R=ce),x.baseState=R,x.firstBaseUpdate=Q,x.lastBaseUpdate=le,s=x.shared.interleaved,s!==null){x=s;do C|=x.lane,x=x.next;while(x!==s)}else w===null&&(x.shared.lanes=0);Aa|=C,i.lanes=C,i.memoizedState=ce}}function Cb(i,s,d){if(i=s.effects,s.effects=null,i!==null)for(s=0;s<i.length;s++){var p=i[s],x=p.callback;if(x!==null){if(p.callback=null,p=d,typeof x!="function")throw Error(r(191,x));x.call(p)}}}var Ol={},jn=Ii(Ol),_l=Ii(Ol),Ml=Ii(Ol);function Na(i){if(i===Ol)throw Error(r(174));return i}function Ym(i,s){switch(tt(Ml,s),tt(_l,i),tt(jn,Ol),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:Xh(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=Xh(s,i)}it(jn),tt(jn,s)}function Uo(){it(jn),it(_l),it(Ml)}function Pb(i){Na(Ml.current);var s=Na(jn.current),d=Xh(s,i.type);s!==d&&(tt(_l,i),tt(jn,d))}function Xm(i){_l.current===i&&(it(jn),it(_l))}var dt=Ii(0);function Bc(i){for(var s=i;s!==null;){if(s.tag===13){var d=s.memoizedState;if(d!==null&&(d=d.dehydrated,d===null||d.data==="$?"||d.data==="$!"))return s}else if(s.tag===19&&s.memoizedProps.revealOrder!==void 0){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var Zm=[];function Jm(){for(var i=0;i<Zm.length;i++)Zm[i]._workInProgressVersionPrimary=null;Zm.length=0}var Uc=P.ReactCurrentDispatcher,ep=P.ReactCurrentBatchConfig,Ea=0,ft=null,St=null,Ot=null,Hc=!1,Il=!1,Tl=0,m3=0;function Jt(){throw Error(r(321))}function tp(i,s){if(s===null)return!1;for(var d=0;d<s.length&&d<i.length;d++)if(!nn(i[d],s[d]))return!1;return!0}function rp(i,s,d,p,x,w){if(Ea=w,ft=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,Uc.current=i===null||i.memoizedState===null?y3:x3,i=d(p,x),Il){w=0;do{if(Il=!1,Tl=0,25<=w)throw Error(r(301));w+=1,Ot=St=null,s.updateQueue=null,Uc.current=b3,i=d(p,x)}while(Il)}if(Uc.current=Gc,s=St!==null&&St.next!==null,Ea=0,Ot=St=ft=null,Hc=!1,s)throw Error(r(300));return i}function np(){var i=Tl!==0;return Tl=0,i}function Sn(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ot===null?ft.memoizedState=Ot=i:Ot=Ot.next=i,Ot}function Ur(){if(St===null){var i=ft.alternate;i=i!==null?i.memoizedState:null}else i=St.next;var s=Ot===null?ft.memoizedState:Ot.next;if(s!==null)Ot=s,St=i;else{if(i===null)throw Error(r(310));St=i,i={memoizedState:St.memoizedState,baseState:St.baseState,baseQueue:St.baseQueue,queue:St.queue,next:null},Ot===null?ft.memoizedState=Ot=i:Ot=Ot.next=i}return Ot}function Dl(i,s){return typeof s=="function"?s(i):s}function ip(i){var s=Ur(),d=s.queue;if(d===null)throw Error(r(311));d.lastRenderedReducer=i;var p=St,x=p.baseQueue,w=d.pending;if(w!==null){if(x!==null){var C=x.next;x.next=w.next,w.next=C}p.baseQueue=x=w,d.pending=null}if(x!==null){w=x.next,p=p.baseState;var T=C=null,R=null,Q=w;do{var le=Q.lane;if((Ea&le)===le)R!==null&&(R=R.next={lane:0,action:Q.action,hasEagerState:Q.hasEagerState,eagerState:Q.eagerState,next:null}),p=Q.hasEagerState?Q.eagerState:i(p,Q.action);else{var ce={lane:le,action:Q.action,hasEagerState:Q.hasEagerState,eagerState:Q.eagerState,next:null};R===null?(T=R=ce,C=p):R=R.next=ce,ft.lanes|=le,Aa|=le}Q=Q.next}while(Q!==null&&Q!==w);R===null?C=p:R.next=T,nn(p,s.memoizedState)||(vr=!0),s.memoizedState=p,s.baseState=C,s.baseQueue=R,d.lastRenderedState=p}if(i=d.interleaved,i!==null){x=i;do w=x.lane,ft.lanes|=w,Aa|=w,x=x.next;while(x!==i)}else x===null&&(d.lanes=0);return[s.memoizedState,d.dispatch]}function ap(i){var s=Ur(),d=s.queue;if(d===null)throw Error(r(311));d.lastRenderedReducer=i;var p=d.dispatch,x=d.pending,w=s.memoizedState;if(x!==null){d.pending=null;var C=x=x.next;do w=i(w,C.action),C=C.next;while(C!==x);nn(w,s.memoizedState)||(vr=!0),s.memoizedState=w,s.baseQueue===null&&(s.baseState=w),d.lastRenderedState=w}return[w,p]}function Ob(){}function _b(i,s){var d=ft,p=Ur(),x=s(),w=!nn(p.memoizedState,x);if(w&&(p.memoizedState=x,vr=!0),p=p.queue,op(Tb.bind(null,d,p,i),[i]),p.getSnapshot!==s||w||Ot!==null&&Ot.memoizedState.tag&1){if(d.flags|=2048,Rl(9,Ib.bind(null,d,p,x,s),void 0,null),_t===null)throw Error(r(349));(Ea&30)!==0||Mb(d,s,x)}return x}function Mb(i,s,d){i.flags|=16384,i={getSnapshot:s,value:d},s=ft.updateQueue,s===null?(s={lastEffect:null,stores:null},ft.updateQueue=s,s.stores=[i]):(d=s.stores,d===null?s.stores=[i]:d.push(i))}function Ib(i,s,d,p){s.value=d,s.getSnapshot=p,Db(s)&&Rb(i)}function Tb(i,s,d){return d(function(){Db(s)&&Rb(i)})}function Db(i){var s=i.getSnapshot;i=i.value;try{var d=s();return!nn(i,d)}catch{return!0}}function Rb(i){var s=Zn(i,1);s!==null&&un(s,i,1,-1)}function Lb(i){var s=Sn();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Dl,lastRenderedState:i},s.queue=i,i=i.dispatch=v3.bind(null,ft,i),[s.memoizedState,i]}function Rl(i,s,d,p){return i={tag:i,create:s,destroy:d,deps:p,next:null},s=ft.updateQueue,s===null?(s={lastEffect:null,stores:null},ft.updateQueue=s,s.lastEffect=i.next=i):(d=s.lastEffect,d===null?s.lastEffect=i.next=i:(p=d.next,d.next=i,i.next=p,s.lastEffect=i)),i}function $b(){return Ur().memoizedState}function Wc(i,s,d,p){var x=Sn();ft.flags|=i,x.memoizedState=Rl(1|s,d,void 0,p===void 0?null:p)}function Kc(i,s,d,p){var x=Ur();p=p===void 0?null:p;var w=void 0;if(St!==null){var C=St.memoizedState;if(w=C.destroy,p!==null&&tp(p,C.deps)){x.memoizedState=Rl(s,d,w,p);return}}ft.flags|=i,x.memoizedState=Rl(1|s,d,w,p)}function zb(i,s){return Wc(8390656,8,i,s)}function op(i,s){return Kc(2048,8,i,s)}function Fb(i,s){return Kc(4,2,i,s)}function Bb(i,s){return Kc(4,4,i,s)}function Ub(i,s){if(typeof s=="function")return i=i(),s(i),function(){s(null)};if(s!=null)return i=i(),s.current=i,function(){s.current=null}}function Hb(i,s,d){return d=d!=null?d.concat([i]):null,Kc(4,4,Ub.bind(null,s,i),d)}function sp(){}function Wb(i,s){var d=Ur();s=s===void 0?null:s;var p=d.memoizedState;return p!==null&&s!==null&&tp(s,p[1])?p[0]:(d.memoizedState=[i,s],i)}function Kb(i,s){var d=Ur();s=s===void 0?null:s;var p=d.memoizedState;return p!==null&&s!==null&&tp(s,p[1])?p[0]:(i=i(),d.memoizedState=[i,s],i)}function Gb(i,s,d){return(Ea&21)===0?(i.baseState&&(i.baseState=!1,vr=!0),i.memoizedState=d):(nn(d,s)||(d=kx(),ft.lanes|=d,Aa|=d,i.baseState=!0),s)}function p3(i,s){var d=Ze;Ze=d!==0&&4>d?d:4,i(!0);var p=ep.transition;ep.transition={};try{i(!1),s()}finally{Ze=d,ep.transition=p}}function Vb(){return Ur().memoizedState}function g3(i,s,d){var p=Bi(i);if(d={lane:p,action:d,hasEagerState:!1,eagerState:null,next:null},qb(i))Qb(s,d);else if(d=Nb(i,s,d,p),d!==null){var x=ur();un(d,i,p,x),Yb(d,s,p)}}function v3(i,s,d){var p=Bi(i),x={lane:p,action:d,hasEagerState:!1,eagerState:null,next:null};if(qb(i))Qb(s,x);else{var w=i.alternate;if(i.lanes===0&&(w===null||w.lanes===0)&&(w=s.lastRenderedReducer,w!==null))try{var C=s.lastRenderedState,T=w(C,d);if(x.hasEagerState=!0,x.eagerState=T,nn(T,C)){var R=s.interleaved;R===null?(x.next=x,qm(s)):(x.next=R.next,R.next=x),s.interleaved=x;return}}catch{}finally{}d=Nb(i,s,x,p),d!==null&&(x=ur(),un(d,i,p,x),Yb(d,s,p))}}function qb(i){var s=i.alternate;return i===ft||s!==null&&s===ft}function Qb(i,s){Il=Hc=!0;var d=i.pending;d===null?s.next=s:(s.next=d.next,d.next=s),i.pending=s}function Yb(i,s,d){if((d&4194240)!==0){var p=s.lanes;p&=i.pendingLanes,d|=p,s.lanes=d,um(i,d)}}var Gc={readContext:Br,useCallback:Jt,useContext:Jt,useEffect:Jt,useImperativeHandle:Jt,useInsertionEffect:Jt,useLayoutEffect:Jt,useMemo:Jt,useReducer:Jt,useRef:Jt,useState:Jt,useDebugValue:Jt,useDeferredValue:Jt,useTransition:Jt,useMutableSource:Jt,useSyncExternalStore:Jt,useId:Jt,unstable_isNewReconciler:!1},y3={readContext:Br,useCallback:function(i,s){return Sn().memoizedState=[i,s===void 0?null:s],i},useContext:Br,useEffect:zb,useImperativeHandle:function(i,s,d){return d=d!=null?d.concat([i]):null,Wc(4194308,4,Ub.bind(null,s,i),d)},useLayoutEffect:function(i,s){return Wc(4194308,4,i,s)},useInsertionEffect:function(i,s){return Wc(4,2,i,s)},useMemo:function(i,s){var d=Sn();return s=s===void 0?null:s,i=i(),d.memoizedState=[i,s],i},useReducer:function(i,s,d){var p=Sn();return s=d!==void 0?d(s):s,p.memoizedState=p.baseState=s,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:i,lastRenderedState:s},p.queue=i,i=i.dispatch=g3.bind(null,ft,i),[p.memoizedState,i]},useRef:function(i){var s=Sn();return i={current:i},s.memoizedState=i},useState:Lb,useDebugValue:sp,useDeferredValue:function(i){return Sn().memoizedState=i},useTransition:function(){var i=Lb(!1),s=i[0];return i=p3.bind(null,i[1]),Sn().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,d){var p=ft,x=Sn();if(lt){if(d===void 0)throw Error(r(407));d=d()}else{if(d=s(),_t===null)throw Error(r(349));(Ea&30)!==0||Mb(p,s,d)}x.memoizedState=d;var w={value:d,getSnapshot:s};return x.queue=w,zb(Tb.bind(null,p,w,i),[i]),p.flags|=2048,Rl(9,Ib.bind(null,p,w,d,s),void 0,null),d},useId:function(){var i=Sn(),s=_t.identifierPrefix;if(lt){var d=Xn,p=Yn;d=(p&~(1<<32-rn(p)-1)).toString(32)+d,s=":"+s+"R"+d,d=Tl++,0<d&&(s+="H"+d.toString(32)),s+=":"}else d=m3++,s=":"+s+"r"+d.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},x3={readContext:Br,useCallback:Wb,useContext:Br,useEffect:op,useImperativeHandle:Hb,useInsertionEffect:Fb,useLayoutEffect:Bb,useMemo:Kb,useReducer:ip,useRef:$b,useState:function(){return ip(Dl)},useDebugValue:sp,useDeferredValue:function(i){var s=Ur();return Gb(s,St.memoizedState,i)},useTransition:function(){var i=ip(Dl)[0],s=Ur().memoizedState;return[i,s]},useMutableSource:Ob,useSyncExternalStore:_b,useId:Vb,unstable_isNewReconciler:!1},b3={readContext:Br,useCallback:Wb,useContext:Br,useEffect:op,useImperativeHandle:Hb,useInsertionEffect:Fb,useLayoutEffect:Bb,useMemo:Kb,useReducer:ap,useRef:$b,useState:function(){return ap(Dl)},useDebugValue:sp,useDeferredValue:function(i){var s=Ur();return St===null?s.memoizedState=i:Gb(s,St.memoizedState,i)},useTransition:function(){var i=ap(Dl)[0],s=Ur().memoizedState;return[i,s]},useMutableSource:Ob,useSyncExternalStore:_b,useId:Vb,unstable_isNewReconciler:!1};function on(i,s){if(i&&i.defaultProps){s=J({},s),i=i.defaultProps;for(var d in i)s[d]===void 0&&(s[d]=i[d]);return s}return s}function lp(i,s,d,p){s=i.memoizedState,d=d(p,s),d=d==null?s:J({},s,d),i.memoizedState=d,i.lanes===0&&(i.updateQueue.baseState=d)}var Vc={isMounted:function(i){return(i=i._reactInternals)?xa(i)===i:!1},enqueueSetState:function(i,s,d){i=i._reactInternals;var p=ur(),x=Bi(i),w=Jn(p,x);w.payload=s,d!=null&&(w.callback=d),s=Li(i,w,x),s!==null&&(un(s,i,x,p),zc(s,i,x))},enqueueReplaceState:function(i,s,d){i=i._reactInternals;var p=ur(),x=Bi(i),w=Jn(p,x);w.tag=1,w.payload=s,d!=null&&(w.callback=d),s=Li(i,w,x),s!==null&&(un(s,i,x,p),zc(s,i,x))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var d=ur(),p=Bi(i),x=Jn(d,p);x.tag=2,s!=null&&(x.callback=s),s=Li(i,x,p),s!==null&&(un(s,i,p,d),zc(s,i,p))}};function Xb(i,s,d,p,x,w,C){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(p,w,C):s.prototype&&s.prototype.isPureReactComponent?!kl(d,p)||!kl(x,w):!0}function Zb(i,s,d){var p=!1,x=Ti,w=s.contextType;return typeof w=="object"&&w!==null?w=Br(w):(x=gr(s)?wa:Zt.current,p=s.contextTypes,w=(p=p!=null)?Do(i,x):Ti),s=new s(d,w),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=Vc,i.stateNode=s,s._reactInternals=i,p&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=x,i.__reactInternalMemoizedMaskedChildContext=w),s}function Jb(i,s,d,p){i=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(d,p),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(d,p),s.state!==i&&Vc.enqueueReplaceState(s,s.state,null)}function up(i,s,d,p){var x=i.stateNode;x.props=d,x.state=i.memoizedState,x.refs={},Qm(i);var w=s.contextType;typeof w=="object"&&w!==null?x.context=Br(w):(w=gr(s)?wa:Zt.current,x.context=Do(i,w)),x.state=i.memoizedState,w=s.getDerivedStateFromProps,typeof w=="function"&&(lp(i,s,w,d),x.state=i.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof x.getSnapshotBeforeUpdate=="function"||typeof x.UNSAFE_componentWillMount!="function"&&typeof x.componentWillMount!="function"||(s=x.state,typeof x.componentWillMount=="function"&&x.componentWillMount(),typeof x.UNSAFE_componentWillMount=="function"&&x.UNSAFE_componentWillMount(),s!==x.state&&Vc.enqueueReplaceState(x,x.state,null),Fc(i,d,x,p),x.state=i.memoizedState),typeof x.componentDidMount=="function"&&(i.flags|=4194308)}function Ho(i,s){try{var d="",p=s;do d+=Z(p),p=p.return;while(p);var x=d}catch(w){x=`
|
||
Error generating stack: `+w.message+`
|
||
`+w.stack}return{value:i,source:s,stack:x,digest:null}}function cp(i,s,d){return{value:i,source:null,stack:d??null,digest:s??null}}function dp(i,s){try{console.error(s.value)}catch(d){setTimeout(function(){throw d})}}var w3=typeof WeakMap=="function"?WeakMap:Map;function e1(i,s,d){d=Jn(-1,d),d.tag=3,d.payload={element:null};var p=s.value;return d.callback=function(){ed||(ed=!0,Ep=p),dp(i,s)},d}function t1(i,s,d){d=Jn(-1,d),d.tag=3;var p=i.type.getDerivedStateFromError;if(typeof p=="function"){var x=s.value;d.payload=function(){return p(x)},d.callback=function(){dp(i,s)}}var w=i.stateNode;return w!==null&&typeof w.componentDidCatch=="function"&&(d.callback=function(){dp(i,s),typeof p!="function"&&(zi===null?zi=new Set([this]):zi.add(this));var C=s.stack;this.componentDidCatch(s.value,{componentStack:C!==null?C:""})}),d}function r1(i,s,d){var p=i.pingCache;if(p===null){p=i.pingCache=new w3;var x=new Set;p.set(s,x)}else x=p.get(s),x===void 0&&(x=new Set,p.set(s,x));x.has(d)||(x.add(d),i=D3.bind(null,i,s,d),s.then(i,i))}function n1(i){do{var s;if((s=i.tag===13)&&(s=i.memoizedState,s=s!==null?s.dehydrated!==null:!0),s)return i;i=i.return}while(i!==null);return null}function i1(i,s,d,p,x){return(i.mode&1)===0?(i===s?i.flags|=65536:(i.flags|=128,d.flags|=131072,d.flags&=-52805,d.tag===1&&(d.alternate===null?d.tag=17:(s=Jn(-1,1),s.tag=2,Li(d,s,1))),d.lanes|=1),i):(i.flags|=65536,i.lanes=x,i)}var k3=P.ReactCurrentOwner,vr=!1;function lr(i,s,d,p){s.child=i===null?Sb(s,null,d,p):zo(s,i.child,d,p)}function a1(i,s,d,p,x){d=d.render;var w=s.ref;return Bo(s,x),p=rp(i,s,d,p,w,x),d=np(),i!==null&&!vr?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~x,ei(i,s,x)):(lt&&d&&zm(s),s.flags|=1,lr(i,s,p,x),s.child)}function o1(i,s,d,p,x){if(i===null){var w=d.type;return typeof w=="function"&&!Ip(w)&&w.defaultProps===void 0&&d.compare===null&&d.defaultProps===void 0?(s.tag=15,s.type=w,s1(i,s,w,p,x)):(i=od(d.type,null,p,s,s.mode,x),i.ref=s.ref,i.return=s,s.child=i)}if(w=i.child,(i.lanes&x)===0){var C=w.memoizedProps;if(d=d.compare,d=d!==null?d:kl,d(C,p)&&i.ref===s.ref)return ei(i,s,x)}return s.flags|=1,i=Hi(w,p),i.ref=s.ref,i.return=s,s.child=i}function s1(i,s,d,p,x){if(i!==null){var w=i.memoizedProps;if(kl(w,p)&&i.ref===s.ref)if(vr=!1,s.pendingProps=p=w,(i.lanes&x)!==0)(i.flags&131072)!==0&&(vr=!0);else return s.lanes=i.lanes,ei(i,s,x)}return fp(i,s,d,p,x)}function l1(i,s,d){var p=s.pendingProps,x=p.children,w=i!==null?i.memoizedState:null;if(p.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},tt(Ko,Pr),Pr|=d;else{if((d&1073741824)===0)return i=w!==null?w.baseLanes|d:d,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,tt(Ko,Pr),Pr|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},p=w!==null?w.baseLanes:d,tt(Ko,Pr),Pr|=p}else w!==null?(p=w.baseLanes|d,s.memoizedState=null):p=d,tt(Ko,Pr),Pr|=p;return lr(i,s,x,d),s.child}function u1(i,s){var d=s.ref;(i===null&&d!==null||i!==null&&i.ref!==d)&&(s.flags|=512,s.flags|=2097152)}function fp(i,s,d,p,x){var w=gr(d)?wa:Zt.current;return w=Do(s,w),Bo(s,x),d=rp(i,s,d,p,w,x),p=np(),i!==null&&!vr?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~x,ei(i,s,x)):(lt&&p&&zm(s),s.flags|=1,lr(i,s,d,x),s.child)}function c1(i,s,d,p,x){if(gr(d)){var w=!0;_c(s)}else w=!1;if(Bo(s,x),s.stateNode===null)Qc(i,s),Zb(s,d,p),up(s,d,p,x),p=!0;else if(i===null){var C=s.stateNode,T=s.memoizedProps;C.props=T;var R=C.context,Q=d.contextType;typeof Q=="object"&&Q!==null?Q=Br(Q):(Q=gr(d)?wa:Zt.current,Q=Do(s,Q));var le=d.getDerivedStateFromProps,ce=typeof le=="function"||typeof C.getSnapshotBeforeUpdate=="function";ce||typeof C.UNSAFE_componentWillReceiveProps!="function"&&typeof C.componentWillReceiveProps!="function"||(T!==p||R!==Q)&&Jb(s,C,p,Q),Ri=!1;var oe=s.memoizedState;C.state=oe,Fc(s,p,C,x),R=s.memoizedState,T!==p||oe!==R||pr.current||Ri?(typeof le=="function"&&(lp(s,d,le,p),R=s.memoizedState),(T=Ri||Xb(s,d,T,p,oe,R,Q))?(ce||typeof C.UNSAFE_componentWillMount!="function"&&typeof C.componentWillMount!="function"||(typeof C.componentWillMount=="function"&&C.componentWillMount(),typeof C.UNSAFE_componentWillMount=="function"&&C.UNSAFE_componentWillMount()),typeof C.componentDidMount=="function"&&(s.flags|=4194308)):(typeof C.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=p,s.memoizedState=R),C.props=p,C.state=R,C.context=Q,p=T):(typeof C.componentDidMount=="function"&&(s.flags|=4194308),p=!1)}else{C=s.stateNode,Eb(i,s),T=s.memoizedProps,Q=s.type===s.elementType?T:on(s.type,T),C.props=Q,ce=s.pendingProps,oe=C.context,R=d.contextType,typeof R=="object"&&R!==null?R=Br(R):(R=gr(d)?wa:Zt.current,R=Do(s,R));var ve=d.getDerivedStateFromProps;(le=typeof ve=="function"||typeof C.getSnapshotBeforeUpdate=="function")||typeof C.UNSAFE_componentWillReceiveProps!="function"&&typeof C.componentWillReceiveProps!="function"||(T!==ce||oe!==R)&&Jb(s,C,p,R),Ri=!1,oe=s.memoizedState,C.state=oe,Fc(s,p,C,x);var ke=s.memoizedState;T!==ce||oe!==ke||pr.current||Ri?(typeof ve=="function"&&(lp(s,d,ve,p),ke=s.memoizedState),(Q=Ri||Xb(s,d,Q,p,oe,ke,R)||!1)?(le||typeof C.UNSAFE_componentWillUpdate!="function"&&typeof C.componentWillUpdate!="function"||(typeof C.componentWillUpdate=="function"&&C.componentWillUpdate(p,ke,R),typeof C.UNSAFE_componentWillUpdate=="function"&&C.UNSAFE_componentWillUpdate(p,ke,R)),typeof C.componentDidUpdate=="function"&&(s.flags|=4),typeof C.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof C.componentDidUpdate!="function"||T===i.memoizedProps&&oe===i.memoizedState||(s.flags|=4),typeof C.getSnapshotBeforeUpdate!="function"||T===i.memoizedProps&&oe===i.memoizedState||(s.flags|=1024),s.memoizedProps=p,s.memoizedState=ke),C.props=p,C.state=ke,C.context=R,p=Q):(typeof C.componentDidUpdate!="function"||T===i.memoizedProps&&oe===i.memoizedState||(s.flags|=4),typeof C.getSnapshotBeforeUpdate!="function"||T===i.memoizedProps&&oe===i.memoizedState||(s.flags|=1024),p=!1)}return hp(i,s,d,p,w,x)}function hp(i,s,d,p,x,w){u1(i,s);var C=(s.flags&128)!==0;if(!p&&!C)return x&&pb(s,d,!1),ei(i,s,w);p=s.stateNode,k3.current=s;var T=C&&typeof d.getDerivedStateFromError!="function"?null:p.render();return s.flags|=1,i!==null&&C?(s.child=zo(s,i.child,null,w),s.child=zo(s,null,T,w)):lr(i,s,T,w),s.memoizedState=p.state,x&&pb(s,d,!0),s.child}function d1(i){var s=i.stateNode;s.pendingContext?hb(i,s.pendingContext,s.pendingContext!==s.context):s.context&&hb(i,s.context,!1),Ym(i,s.containerInfo)}function f1(i,s,d,p,x){return $o(),Hm(x),s.flags|=256,lr(i,s,d,p),s.child}var mp={dehydrated:null,treeContext:null,retryLane:0};function pp(i){return{baseLanes:i,cachePool:null,transitions:null}}function h1(i,s,d){var p=s.pendingProps,x=dt.current,w=!1,C=(s.flags&128)!==0,T;if((T=C)||(T=i!==null&&i.memoizedState===null?!1:(x&2)!==0),T?(w=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(x|=1),tt(dt,x&1),i===null)return Um(s),i=s.memoizedState,i!==null&&(i=i.dehydrated,i!==null)?((s.mode&1)===0?s.lanes=1:i.data==="$!"?s.lanes=8:s.lanes=1073741824,null):(C=p.children,i=p.fallback,w?(p=s.mode,w=s.child,C={mode:"hidden",children:C},(p&1)===0&&w!==null?(w.childLanes=0,w.pendingProps=C):w=sd(C,p,0,null),i=_a(i,p,d,null),w.return=s,i.return=s,w.sibling=i,s.child=w,s.child.memoizedState=pp(d),s.memoizedState=mp,i):gp(s,C));if(x=i.memoizedState,x!==null&&(T=x.dehydrated,T!==null))return j3(i,s,C,p,T,x,d);if(w){w=p.fallback,C=s.mode,x=i.child,T=x.sibling;var R={mode:"hidden",children:p.children};return(C&1)===0&&s.child!==x?(p=s.child,p.childLanes=0,p.pendingProps=R,s.deletions=null):(p=Hi(x,R),p.subtreeFlags=x.subtreeFlags&14680064),T!==null?w=Hi(T,w):(w=_a(w,C,d,null),w.flags|=2),w.return=s,p.return=s,p.sibling=w,s.child=p,p=w,w=s.child,C=i.child.memoizedState,C=C===null?pp(d):{baseLanes:C.baseLanes|d,cachePool:null,transitions:C.transitions},w.memoizedState=C,w.childLanes=i.childLanes&~d,s.memoizedState=mp,p}return w=i.child,i=w.sibling,p=Hi(w,{mode:"visible",children:p.children}),(s.mode&1)===0&&(p.lanes=d),p.return=s,p.sibling=null,i!==null&&(d=s.deletions,d===null?(s.deletions=[i],s.flags|=16):d.push(i)),s.child=p,s.memoizedState=null,p}function gp(i,s){return s=sd({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function qc(i,s,d,p){return p!==null&&Hm(p),zo(s,i.child,null,d),i=gp(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function j3(i,s,d,p,x,w,C){if(d)return s.flags&256?(s.flags&=-257,p=cp(Error(r(422))),qc(i,s,C,p)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(w=p.fallback,x=s.mode,p=sd({mode:"visible",children:p.children},x,0,null),w=_a(w,x,C,null),w.flags|=2,p.return=s,w.return=s,p.sibling=w,s.child=p,(s.mode&1)!==0&&zo(s,i.child,null,C),s.child.memoizedState=pp(C),s.memoizedState=mp,w);if((s.mode&1)===0)return qc(i,s,C,null);if(x.data==="$!"){if(p=x.nextSibling&&x.nextSibling.dataset,p)var T=p.dgst;return p=T,w=Error(r(419)),p=cp(w,p,void 0),qc(i,s,C,p)}if(T=(C&i.childLanes)!==0,vr||T){if(p=_t,p!==null){switch(C&-C){case 4:x=2;break;case 16:x=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:x=32;break;case 536870912:x=268435456;break;default:x=0}x=(x&(p.suspendedLanes|C))!==0?0:x,x!==0&&x!==w.retryLane&&(w.retryLane=x,Zn(i,x),un(p,i,x,-1))}return Mp(),p=cp(Error(r(421))),qc(i,s,C,p)}return x.data==="$?"?(s.flags|=128,s.child=i.child,s=R3.bind(null,i),x._reactRetry=s,null):(i=w.treeContext,Cr=Mi(x.nextSibling),Ar=s,lt=!0,an=null,i!==null&&(zr[Fr++]=Yn,zr[Fr++]=Xn,zr[Fr++]=ka,Yn=i.id,Xn=i.overflow,ka=s),s=gp(s,p.children),s.flags|=4096,s)}function m1(i,s,d){i.lanes|=s;var p=i.alternate;p!==null&&(p.lanes|=s),Vm(i.return,s,d)}function vp(i,s,d,p,x){var w=i.memoizedState;w===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:p,tail:d,tailMode:x}:(w.isBackwards=s,w.rendering=null,w.renderingStartTime=0,w.last=p,w.tail=d,w.tailMode=x)}function p1(i,s,d){var p=s.pendingProps,x=p.revealOrder,w=p.tail;if(lr(i,s,p.children,d),p=dt.current,(p&2)!==0)p=p&1|2,s.flags|=128;else{if(i!==null&&(i.flags&128)!==0)e:for(i=s.child;i!==null;){if(i.tag===13)i.memoizedState!==null&&m1(i,d,s);else if(i.tag===19)m1(i,d,s);else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===s)break e;for(;i.sibling===null;){if(i.return===null||i.return===s)break e;i=i.return}i.sibling.return=i.return,i=i.sibling}p&=1}if(tt(dt,p),(s.mode&1)===0)s.memoizedState=null;else switch(x){case"forwards":for(d=s.child,x=null;d!==null;)i=d.alternate,i!==null&&Bc(i)===null&&(x=d),d=d.sibling;d=x,d===null?(x=s.child,s.child=null):(x=d.sibling,d.sibling=null),vp(s,!1,x,d,w);break;case"backwards":for(d=null,x=s.child,s.child=null;x!==null;){if(i=x.alternate,i!==null&&Bc(i)===null){s.child=x;break}i=x.sibling,x.sibling=d,d=x,x=i}vp(s,!0,d,null,w);break;case"together":vp(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function Qc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function ei(i,s,d){if(i!==null&&(s.dependencies=i.dependencies),Aa|=s.lanes,(d&s.childLanes)===0)return null;if(i!==null&&s.child!==i.child)throw Error(r(153));if(s.child!==null){for(i=s.child,d=Hi(i,i.pendingProps),s.child=d,d.return=s;i.sibling!==null;)i=i.sibling,d=d.sibling=Hi(i,i.pendingProps),d.return=s;d.sibling=null}return s.child}function S3(i,s,d){switch(s.tag){case 3:d1(s),$o();break;case 5:Pb(s);break;case 1:gr(s.type)&&_c(s);break;case 4:Ym(s,s.stateNode.containerInfo);break;case 10:var p=s.type._context,x=s.memoizedProps.value;tt(Lc,p._currentValue),p._currentValue=x;break;case 13:if(p=s.memoizedState,p!==null)return p.dehydrated!==null?(tt(dt,dt.current&1),s.flags|=128,null):(d&s.child.childLanes)!==0?h1(i,s,d):(tt(dt,dt.current&1),i=ei(i,s,d),i!==null?i.sibling:null);tt(dt,dt.current&1);break;case 19:if(p=(d&s.childLanes)!==0,(i.flags&128)!==0){if(p)return p1(i,s,d);s.flags|=128}if(x=s.memoizedState,x!==null&&(x.rendering=null,x.tail=null,x.lastEffect=null),tt(dt,dt.current),p)break;return null;case 22:case 23:return s.lanes=0,l1(i,s,d)}return ei(i,s,d)}var g1,yp,v1,y1;g1=function(i,s){for(var d=s.child;d!==null;){if(d.tag===5||d.tag===6)i.appendChild(d.stateNode);else if(d.tag!==4&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===s)break;for(;d.sibling===null;){if(d.return===null||d.return===s)return;d=d.return}d.sibling.return=d.return,d=d.sibling}},yp=function(){},v1=function(i,s,d,p){var x=i.memoizedProps;if(x!==p){i=s.stateNode,Na(jn.current);var w=null;switch(d){case"input":x=Be(i,x),p=Be(i,p),w=[];break;case"select":x=J({},x,{value:void 0}),p=J({},p,{value:void 0}),w=[];break;case"textarea":x=G(i,x),p=G(i,p),w=[];break;default:typeof x.onClick!="function"&&typeof p.onClick=="function"&&(i.onclick=Cc)}Zh(d,p);var C;d=null;for(Q in x)if(!p.hasOwnProperty(Q)&&x.hasOwnProperty(Q)&&x[Q]!=null)if(Q==="style"){var T=x[Q];for(C in T)T.hasOwnProperty(C)&&(d||(d={}),d[C]="")}else Q!=="dangerouslySetInnerHTML"&&Q!=="children"&&Q!=="suppressContentEditableWarning"&&Q!=="suppressHydrationWarning"&&Q!=="autoFocus"&&(a.hasOwnProperty(Q)?w||(w=[]):(w=w||[]).push(Q,null));for(Q in p){var R=p[Q];if(T=x!=null?x[Q]:void 0,p.hasOwnProperty(Q)&&R!==T&&(R!=null||T!=null))if(Q==="style")if(T){for(C in T)!T.hasOwnProperty(C)||R&&R.hasOwnProperty(C)||(d||(d={}),d[C]="");for(C in R)R.hasOwnProperty(C)&&T[C]!==R[C]&&(d||(d={}),d[C]=R[C])}else d||(w||(w=[]),w.push(Q,d)),d=R;else Q==="dangerouslySetInnerHTML"?(R=R?R.__html:void 0,T=T?T.__html:void 0,R!=null&&T!==R&&(w=w||[]).push(Q,R)):Q==="children"?typeof R!="string"&&typeof R!="number"||(w=w||[]).push(Q,""+R):Q!=="suppressContentEditableWarning"&&Q!=="suppressHydrationWarning"&&(a.hasOwnProperty(Q)?(R!=null&&Q==="onScroll"&&nt("scroll",i),w||T===R||(w=[])):(w=w||[]).push(Q,R))}d&&(w=w||[]).push("style",d);var Q=w;(s.updateQueue=Q)&&(s.flags|=4)}},y1=function(i,s,d,p){d!==p&&(s.flags|=4)};function Ll(i,s){if(!lt)switch(i.tailMode){case"hidden":s=i.tail;for(var d=null;s!==null;)s.alternate!==null&&(d=s),s=s.sibling;d===null?i.tail=null:d.sibling=null;break;case"collapsed":d=i.tail;for(var p=null;d!==null;)d.alternate!==null&&(p=d),d=d.sibling;p===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:p.sibling=null}}function er(i){var s=i.alternate!==null&&i.alternate.child===i.child,d=0,p=0;if(s)for(var x=i.child;x!==null;)d|=x.lanes|x.childLanes,p|=x.subtreeFlags&14680064,p|=x.flags&14680064,x.return=i,x=x.sibling;else for(x=i.child;x!==null;)d|=x.lanes|x.childLanes,p|=x.subtreeFlags,p|=x.flags,x.return=i,x=x.sibling;return i.subtreeFlags|=p,i.childLanes=d,s}function N3(i,s,d){var p=s.pendingProps;switch(Fm(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return er(s),null;case 1:return gr(s.type)&&Oc(),er(s),null;case 3:return p=s.stateNode,Uo(),it(pr),it(Zt),Jm(),p.pendingContext&&(p.context=p.pendingContext,p.pendingContext=null),(i===null||i.child===null)&&(Dc(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,an!==null&&(Pp(an),an=null))),yp(i,s),er(s),null;case 5:Xm(s);var x=Na(Ml.current);if(d=s.type,i!==null&&s.stateNode!=null)v1(i,s,d,p,x),i.ref!==s.ref&&(s.flags|=512,s.flags|=2097152);else{if(!p){if(s.stateNode===null)throw Error(r(166));return er(s),null}if(i=Na(jn.current),Dc(s)){p=s.stateNode,d=s.type;var w=s.memoizedProps;switch(p[kn]=s,p[Al]=w,i=(s.mode&1)!==0,d){case"dialog":nt("cancel",p),nt("close",p);break;case"iframe":case"object":case"embed":nt("load",p);break;case"video":case"audio":for(x=0;x<Sl.length;x++)nt(Sl[x],p);break;case"source":nt("error",p);break;case"img":case"image":case"link":nt("error",p),nt("load",p);break;case"details":nt("toggle",p);break;case"input":Pe(p,w),nt("invalid",p);break;case"select":p._wrapperState={wasMultiple:!!w.multiple},nt("invalid",p);break;case"textarea":Ie(p,w),nt("invalid",p)}Zh(d,w),x=null;for(var C in w)if(w.hasOwnProperty(C)){var T=w[C];C==="children"?typeof T=="string"?p.textContent!==T&&(w.suppressHydrationWarning!==!0&&Ac(p.textContent,T,i),x=["children",T]):typeof T=="number"&&p.textContent!==""+T&&(w.suppressHydrationWarning!==!0&&Ac(p.textContent,T,i),x=["children",""+T]):a.hasOwnProperty(C)&&T!=null&&C==="onScroll"&&nt("scroll",p)}switch(d){case"input":_e(p),K(p,w,!0);break;case"textarea":_e(p),nx(p);break;case"select":case"option":break;default:typeof w.onClick=="function"&&(p.onclick=Cc)}p=x,s.updateQueue=p,p!==null&&(s.flags|=4)}else{C=x.nodeType===9?x:x.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=ix(d)),i==="http://www.w3.org/1999/xhtml"?d==="script"?(i=C.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof p.is=="string"?i=C.createElement(d,{is:p.is}):(i=C.createElement(d),d==="select"&&(C=i,p.multiple?C.multiple=!0:p.size&&(C.size=p.size))):i=C.createElementNS(i,d),i[kn]=s,i[Al]=p,g1(i,s,!1,!1),s.stateNode=i;e:{switch(C=Jh(d,p),d){case"dialog":nt("cancel",i),nt("close",i),x=p;break;case"iframe":case"object":case"embed":nt("load",i),x=p;break;case"video":case"audio":for(x=0;x<Sl.length;x++)nt(Sl[x],i);x=p;break;case"source":nt("error",i),x=p;break;case"img":case"image":case"link":nt("error",i),nt("load",i),x=p;break;case"details":nt("toggle",i),x=p;break;case"input":Pe(i,p),x=Be(i,p),nt("invalid",i);break;case"option":x=p;break;case"select":i._wrapperState={wasMultiple:!!p.multiple},x=J({},p,{value:void 0}),nt("invalid",i);break;case"textarea":Ie(i,p),x=G(i,p),nt("invalid",i);break;default:x=p}Zh(d,x),T=x;for(w in T)if(T.hasOwnProperty(w)){var R=T[w];w==="style"?sx(i,R):w==="dangerouslySetInnerHTML"?(R=R?R.__html:void 0,R!=null&&ax(i,R)):w==="children"?typeof R=="string"?(d!=="textarea"||R!=="")&&al(i,R):typeof R=="number"&&al(i,""+R):w!=="suppressContentEditableWarning"&&w!=="suppressHydrationWarning"&&w!=="autoFocus"&&(a.hasOwnProperty(w)?R!=null&&w==="onScroll"&&nt("scroll",i):R!=null&&A(i,w,R,C))}switch(d){case"input":_e(i),K(i,p,!1);break;case"textarea":_e(i),nx(i);break;case"option":p.value!=null&&i.setAttribute("value",""+Oe(p.value));break;case"select":i.multiple=!!p.multiple,w=p.value,w!=null?qe(i,!!p.multiple,w,!1):p.defaultValue!=null&&qe(i,!!p.multiple,p.defaultValue,!0);break;default:typeof x.onClick=="function"&&(i.onclick=Cc)}switch(d){case"button":case"input":case"select":case"textarea":p=!!p.autoFocus;break e;case"img":p=!0;break e;default:p=!1}}p&&(s.flags|=4)}s.ref!==null&&(s.flags|=512,s.flags|=2097152)}return er(s),null;case 6:if(i&&s.stateNode!=null)y1(i,s,i.memoizedProps,p);else{if(typeof p!="string"&&s.stateNode===null)throw Error(r(166));if(d=Na(Ml.current),Na(jn.current),Dc(s)){if(p=s.stateNode,d=s.memoizedProps,p[kn]=s,(w=p.nodeValue!==d)&&(i=Ar,i!==null))switch(i.tag){case 3:Ac(p.nodeValue,d,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Ac(p.nodeValue,d,(i.mode&1)!==0)}w&&(s.flags|=4)}else p=(d.nodeType===9?d:d.ownerDocument).createTextNode(p),p[kn]=s,s.stateNode=p}return er(s),null;case 13:if(it(dt),p=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(lt&&Cr!==null&&(s.mode&1)!==0&&(s.flags&128)===0)wb(),$o(),s.flags|=98560,w=!1;else if(w=Dc(s),p!==null&&p.dehydrated!==null){if(i===null){if(!w)throw Error(r(318));if(w=s.memoizedState,w=w!==null?w.dehydrated:null,!w)throw Error(r(317));w[kn]=s}else $o(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;er(s),w=!1}else an!==null&&(Pp(an),an=null),w=!0;if(!w)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=d,s):(p=p!==null,p!==(i!==null&&i.memoizedState!==null)&&p&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(dt.current&1)!==0?Nt===0&&(Nt=3):Mp())),s.updateQueue!==null&&(s.flags|=4),er(s),null);case 4:return Uo(),yp(i,s),i===null&&Nl(s.stateNode.containerInfo),er(s),null;case 10:return Gm(s.type._context),er(s),null;case 17:return gr(s.type)&&Oc(),er(s),null;case 19:if(it(dt),w=s.memoizedState,w===null)return er(s),null;if(p=(s.flags&128)!==0,C=w.rendering,C===null)if(p)Ll(w,!1);else{if(Nt!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(C=Bc(i),C!==null){for(s.flags|=128,Ll(w,!1),p=C.updateQueue,p!==null&&(s.updateQueue=p,s.flags|=4),s.subtreeFlags=0,p=d,d=s.child;d!==null;)w=d,i=p,w.flags&=14680066,C=w.alternate,C===null?(w.childLanes=0,w.lanes=i,w.child=null,w.subtreeFlags=0,w.memoizedProps=null,w.memoizedState=null,w.updateQueue=null,w.dependencies=null,w.stateNode=null):(w.childLanes=C.childLanes,w.lanes=C.lanes,w.child=C.child,w.subtreeFlags=0,w.deletions=null,w.memoizedProps=C.memoizedProps,w.memoizedState=C.memoizedState,w.updateQueue=C.updateQueue,w.type=C.type,i=C.dependencies,w.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),d=d.sibling;return tt(dt,dt.current&1|2),s.child}i=i.sibling}w.tail!==null&&yt()>Go&&(s.flags|=128,p=!0,Ll(w,!1),s.lanes=4194304)}else{if(!p)if(i=Bc(C),i!==null){if(s.flags|=128,p=!0,d=i.updateQueue,d!==null&&(s.updateQueue=d,s.flags|=4),Ll(w,!0),w.tail===null&&w.tailMode==="hidden"&&!C.alternate&&!lt)return er(s),null}else 2*yt()-w.renderingStartTime>Go&&d!==1073741824&&(s.flags|=128,p=!0,Ll(w,!1),s.lanes=4194304);w.isBackwards?(C.sibling=s.child,s.child=C):(d=w.last,d!==null?d.sibling=C:s.child=C,w.last=C)}return w.tail!==null?(s=w.tail,w.rendering=s,w.tail=s.sibling,w.renderingStartTime=yt(),s.sibling=null,d=dt.current,tt(dt,p?d&1|2:d&1),s):(er(s),null);case 22:case 23:return _p(),p=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==p&&(s.flags|=8192),p&&(s.mode&1)!==0?(Pr&1073741824)!==0&&(er(s),s.subtreeFlags&6&&(s.flags|=8192)):er(s),null;case 24:return null;case 25:return null}throw Error(r(156,s.tag))}function E3(i,s){switch(Fm(s),s.tag){case 1:return gr(s.type)&&Oc(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return Uo(),it(pr),it(Zt),Jm(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return Xm(s),null;case 13:if(it(dt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(r(340));$o()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return it(dt),null;case 4:return Uo(),null;case 10:return Gm(s.type._context),null;case 22:case 23:return _p(),null;case 24:return null;default:return null}}var Yc=!1,tr=!1,A3=typeof WeakSet=="function"?WeakSet:Set,xe=null;function Wo(i,s){var d=i.ref;if(d!==null)if(typeof d=="function")try{d(null)}catch(p){ht(i,s,p)}else d.current=null}function xp(i,s,d){try{d()}catch(p){ht(i,s,p)}}var x1=!1;function C3(i,s){if(_m=gc,i=Xx(),jm(i)){if("selectionStart"in i)var d={start:i.selectionStart,end:i.selectionEnd};else e:{d=(d=i.ownerDocument)&&d.defaultView||window;var p=d.getSelection&&d.getSelection();if(p&&p.rangeCount!==0){d=p.anchorNode;var x=p.anchorOffset,w=p.focusNode;p=p.focusOffset;try{d.nodeType,w.nodeType}catch{d=null;break e}var C=0,T=-1,R=-1,Q=0,le=0,ce=i,oe=null;t:for(;;){for(var ve;ce!==d||x!==0&&ce.nodeType!==3||(T=C+x),ce!==w||p!==0&&ce.nodeType!==3||(R=C+p),ce.nodeType===3&&(C+=ce.nodeValue.length),(ve=ce.firstChild)!==null;)oe=ce,ce=ve;for(;;){if(ce===i)break t;if(oe===d&&++Q===x&&(T=C),oe===w&&++le===p&&(R=C),(ve=ce.nextSibling)!==null)break;ce=oe,oe=ce.parentNode}ce=ve}d=T===-1||R===-1?null:{start:T,end:R}}else d=null}d=d||{start:0,end:0}}else d=null;for(Mm={focusedElem:i,selectionRange:d},gc=!1,xe=s;xe!==null;)if(s=xe,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,xe=i;else for(;xe!==null;){s=xe;try{var ke=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(ke!==null){var Ne=ke.memoizedProps,xt=ke.memoizedState,W=s.stateNode,$=W.getSnapshotBeforeUpdate(s.elementType===s.type?Ne:on(s.type,Ne),xt);W.__reactInternalSnapshotBeforeUpdate=$}break;case 3:var V=s.stateNode.containerInfo;V.nodeType===1?V.textContent="":V.nodeType===9&&V.documentElement&&V.removeChild(V.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(r(163))}}catch(fe){ht(s,s.return,fe)}if(i=s.sibling,i!==null){i.return=s.return,xe=i;break}xe=s.return}return ke=x1,x1=!1,ke}function $l(i,s,d){var p=s.updateQueue;if(p=p!==null?p.lastEffect:null,p!==null){var x=p=p.next;do{if((x.tag&i)===i){var w=x.destroy;x.destroy=void 0,w!==void 0&&xp(s,d,w)}x=x.next}while(x!==p)}}function Xc(i,s){if(s=s.updateQueue,s=s!==null?s.lastEffect:null,s!==null){var d=s=s.next;do{if((d.tag&i)===i){var p=d.create;d.destroy=p()}d=d.next}while(d!==s)}}function bp(i){var s=i.ref;if(s!==null){var d=i.stateNode;switch(i.tag){case 5:i=d;break;default:i=d}typeof s=="function"?s(i):s.current=i}}function b1(i){var s=i.alternate;s!==null&&(i.alternate=null,b1(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[kn],delete s[Al],delete s[Rm],delete s[c3],delete s[d3])),i.stateNode=null,i.return=null,i.dependencies=null,i.memoizedProps=null,i.memoizedState=null,i.pendingProps=null,i.stateNode=null,i.updateQueue=null}function w1(i){return i.tag===5||i.tag===3||i.tag===4}function k1(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||w1(i.return))return null;i=i.return}for(i.sibling.return=i.return,i=i.sibling;i.tag!==5&&i.tag!==6&&i.tag!==18;){if(i.flags&2||i.child===null||i.tag===4)continue e;i.child.return=i,i=i.child}if(!(i.flags&2))return i.stateNode}}function wp(i,s,d){var p=i.tag;if(p===5||p===6)i=i.stateNode,s?d.nodeType===8?d.parentNode.insertBefore(i,s):d.insertBefore(i,s):(d.nodeType===8?(s=d.parentNode,s.insertBefore(i,d)):(s=d,s.appendChild(i)),d=d._reactRootContainer,d!=null||s.onclick!==null||(s.onclick=Cc));else if(p!==4&&(i=i.child,i!==null))for(wp(i,s,d),i=i.sibling;i!==null;)wp(i,s,d),i=i.sibling}function kp(i,s,d){var p=i.tag;if(p===5||p===6)i=i.stateNode,s?d.insertBefore(i,s):d.appendChild(i);else if(p!==4&&(i=i.child,i!==null))for(kp(i,s,d),i=i.sibling;i!==null;)kp(i,s,d),i=i.sibling}var zt=null,sn=!1;function $i(i,s,d){for(d=d.child;d!==null;)j1(i,s,d),d=d.sibling}function j1(i,s,d){if(wn&&typeof wn.onCommitFiberUnmount=="function")try{wn.onCommitFiberUnmount(cc,d)}catch{}switch(d.tag){case 5:tr||Wo(d,s);case 6:var p=zt,x=sn;zt=null,$i(i,s,d),zt=p,sn=x,zt!==null&&(sn?(i=zt,d=d.stateNode,i.nodeType===8?i.parentNode.removeChild(d):i.removeChild(d)):zt.removeChild(d.stateNode));break;case 18:zt!==null&&(sn?(i=zt,d=d.stateNode,i.nodeType===8?Dm(i.parentNode,d):i.nodeType===1&&Dm(i,d),gl(i)):Dm(zt,d.stateNode));break;case 4:p=zt,x=sn,zt=d.stateNode.containerInfo,sn=!0,$i(i,s,d),zt=p,sn=x;break;case 0:case 11:case 14:case 15:if(!tr&&(p=d.updateQueue,p!==null&&(p=p.lastEffect,p!==null))){x=p=p.next;do{var w=x,C=w.destroy;w=w.tag,C!==void 0&&((w&2)!==0||(w&4)!==0)&&xp(d,s,C),x=x.next}while(x!==p)}$i(i,s,d);break;case 1:if(!tr&&(Wo(d,s),p=d.stateNode,typeof p.componentWillUnmount=="function"))try{p.props=d.memoizedProps,p.state=d.memoizedState,p.componentWillUnmount()}catch(T){ht(d,s,T)}$i(i,s,d);break;case 21:$i(i,s,d);break;case 22:d.mode&1?(tr=(p=tr)||d.memoizedState!==null,$i(i,s,d),tr=p):$i(i,s,d);break;default:$i(i,s,d)}}function S1(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var d=i.stateNode;d===null&&(d=i.stateNode=new A3),s.forEach(function(p){var x=L3.bind(null,i,p);d.has(p)||(d.add(p),p.then(x,x))})}}function ln(i,s){var d=s.deletions;if(d!==null)for(var p=0;p<d.length;p++){var x=d[p];try{var w=i,C=s,T=C;e:for(;T!==null;){switch(T.tag){case 5:zt=T.stateNode,sn=!1;break e;case 3:zt=T.stateNode.containerInfo,sn=!0;break e;case 4:zt=T.stateNode.containerInfo,sn=!0;break e}T=T.return}if(zt===null)throw Error(r(160));j1(w,C,x),zt=null,sn=!1;var R=x.alternate;R!==null&&(R.return=null),x.return=null}catch(Q){ht(x,s,Q)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)N1(s,i),s=s.sibling}function N1(i,s){var d=i.alternate,p=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(ln(s,i),Nn(i),p&4){try{$l(3,i,i.return),Xc(3,i)}catch(Ne){ht(i,i.return,Ne)}try{$l(5,i,i.return)}catch(Ne){ht(i,i.return,Ne)}}break;case 1:ln(s,i),Nn(i),p&512&&d!==null&&Wo(d,d.return);break;case 5:if(ln(s,i),Nn(i),p&512&&d!==null&&Wo(d,d.return),i.flags&32){var x=i.stateNode;try{al(x,"")}catch(Ne){ht(i,i.return,Ne)}}if(p&4&&(x=i.stateNode,x!=null)){var w=i.memoizedProps,C=d!==null?d.memoizedProps:w,T=i.type,R=i.updateQueue;if(i.updateQueue=null,R!==null)try{T==="input"&&w.type==="radio"&&w.name!=null&&vt(x,w),Jh(T,C);var Q=Jh(T,w);for(C=0;C<R.length;C+=2){var le=R[C],ce=R[C+1];le==="style"?sx(x,ce):le==="dangerouslySetInnerHTML"?ax(x,ce):le==="children"?al(x,ce):A(x,le,ce,Q)}switch(T){case"input":Yt(x,w);break;case"textarea":Xt(x,w);break;case"select":var oe=x._wrapperState.wasMultiple;x._wrapperState.wasMultiple=!!w.multiple;var ve=w.value;ve!=null?qe(x,!!w.multiple,ve,!1):oe!==!!w.multiple&&(w.defaultValue!=null?qe(x,!!w.multiple,w.defaultValue,!0):qe(x,!!w.multiple,w.multiple?[]:"",!1))}x[Al]=w}catch(Ne){ht(i,i.return,Ne)}}break;case 6:if(ln(s,i),Nn(i),p&4){if(i.stateNode===null)throw Error(r(162));x=i.stateNode,w=i.memoizedProps;try{x.nodeValue=w}catch(Ne){ht(i,i.return,Ne)}}break;case 3:if(ln(s,i),Nn(i),p&4&&d!==null&&d.memoizedState.isDehydrated)try{gl(s.containerInfo)}catch(Ne){ht(i,i.return,Ne)}break;case 4:ln(s,i),Nn(i);break;case 13:ln(s,i),Nn(i),x=i.child,x.flags&8192&&(w=x.memoizedState!==null,x.stateNode.isHidden=w,!w||x.alternate!==null&&x.alternate.memoizedState!==null||(Np=yt())),p&4&&S1(i);break;case 22:if(le=d!==null&&d.memoizedState!==null,i.mode&1?(tr=(Q=tr)||le,ln(s,i),tr=Q):ln(s,i),Nn(i),p&8192){if(Q=i.memoizedState!==null,(i.stateNode.isHidden=Q)&&!le&&(i.mode&1)!==0)for(xe=i,le=i.child;le!==null;){for(ce=xe=le;xe!==null;){switch(oe=xe,ve=oe.child,oe.tag){case 0:case 11:case 14:case 15:$l(4,oe,oe.return);break;case 1:Wo(oe,oe.return);var ke=oe.stateNode;if(typeof ke.componentWillUnmount=="function"){p=oe,d=oe.return;try{s=p,ke.props=s.memoizedProps,ke.state=s.memoizedState,ke.componentWillUnmount()}catch(Ne){ht(p,d,Ne)}}break;case 5:Wo(oe,oe.return);break;case 22:if(oe.memoizedState!==null){C1(ce);continue}}ve!==null?(ve.return=oe,xe=ve):C1(ce)}le=le.sibling}e:for(le=null,ce=i;;){if(ce.tag===5){if(le===null){le=ce;try{x=ce.stateNode,Q?(w=x.style,typeof w.setProperty=="function"?w.setProperty("display","none","important"):w.display="none"):(T=ce.stateNode,R=ce.memoizedProps.style,C=R!=null&&R.hasOwnProperty("display")?R.display:null,T.style.display=ox("display",C))}catch(Ne){ht(i,i.return,Ne)}}}else if(ce.tag===6){if(le===null)try{ce.stateNode.nodeValue=Q?"":ce.memoizedProps}catch(Ne){ht(i,i.return,Ne)}}else if((ce.tag!==22&&ce.tag!==23||ce.memoizedState===null||ce===i)&&ce.child!==null){ce.child.return=ce,ce=ce.child;continue}if(ce===i)break e;for(;ce.sibling===null;){if(ce.return===null||ce.return===i)break e;le===ce&&(le=null),ce=ce.return}le===ce&&(le=null),ce.sibling.return=ce.return,ce=ce.sibling}}break;case 19:ln(s,i),Nn(i),p&4&&S1(i);break;case 21:break;default:ln(s,i),Nn(i)}}function Nn(i){var s=i.flags;if(s&2){try{e:{for(var d=i.return;d!==null;){if(w1(d)){var p=d;break e}d=d.return}throw Error(r(160))}switch(p.tag){case 5:var x=p.stateNode;p.flags&32&&(al(x,""),p.flags&=-33);var w=k1(i);kp(i,w,x);break;case 3:case 4:var C=p.stateNode.containerInfo,T=k1(i);wp(i,T,C);break;default:throw Error(r(161))}}catch(R){ht(i,i.return,R)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function P3(i,s,d){xe=i,E1(i)}function E1(i,s,d){for(var p=(i.mode&1)!==0;xe!==null;){var x=xe,w=x.child;if(x.tag===22&&p){var C=x.memoizedState!==null||Yc;if(!C){var T=x.alternate,R=T!==null&&T.memoizedState!==null||tr;T=Yc;var Q=tr;if(Yc=C,(tr=R)&&!Q)for(xe=x;xe!==null;)C=xe,R=C.child,C.tag===22&&C.memoizedState!==null?P1(x):R!==null?(R.return=C,xe=R):P1(x);for(;w!==null;)xe=w,E1(w),w=w.sibling;xe=x,Yc=T,tr=Q}A1(i)}else(x.subtreeFlags&8772)!==0&&w!==null?(w.return=x,xe=w):A1(i)}}function A1(i){for(;xe!==null;){var s=xe;if((s.flags&8772)!==0){var d=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:tr||Xc(5,s);break;case 1:var p=s.stateNode;if(s.flags&4&&!tr)if(d===null)p.componentDidMount();else{var x=s.elementType===s.type?d.memoizedProps:on(s.type,d.memoizedProps);p.componentDidUpdate(x,d.memoizedState,p.__reactInternalSnapshotBeforeUpdate)}var w=s.updateQueue;w!==null&&Cb(s,w,p);break;case 3:var C=s.updateQueue;if(C!==null){if(d=null,s.child!==null)switch(s.child.tag){case 5:d=s.child.stateNode;break;case 1:d=s.child.stateNode}Cb(s,C,d)}break;case 5:var T=s.stateNode;if(d===null&&s.flags&4){d=T;var R=s.memoizedProps;switch(s.type){case"button":case"input":case"select":case"textarea":R.autoFocus&&d.focus();break;case"img":R.src&&(d.src=R.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(s.memoizedState===null){var Q=s.alternate;if(Q!==null){var le=Q.memoizedState;if(le!==null){var ce=le.dehydrated;ce!==null&&gl(ce)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(r(163))}tr||s.flags&512&&bp(s)}catch(oe){ht(s,s.return,oe)}}if(s===i){xe=null;break}if(d=s.sibling,d!==null){d.return=s.return,xe=d;break}xe=s.return}}function C1(i){for(;xe!==null;){var s=xe;if(s===i){xe=null;break}var d=s.sibling;if(d!==null){d.return=s.return,xe=d;break}xe=s.return}}function P1(i){for(;xe!==null;){var s=xe;try{switch(s.tag){case 0:case 11:case 15:var d=s.return;try{Xc(4,s)}catch(R){ht(s,d,R)}break;case 1:var p=s.stateNode;if(typeof p.componentDidMount=="function"){var x=s.return;try{p.componentDidMount()}catch(R){ht(s,x,R)}}var w=s.return;try{bp(s)}catch(R){ht(s,w,R)}break;case 5:var C=s.return;try{bp(s)}catch(R){ht(s,C,R)}}}catch(R){ht(s,s.return,R)}if(s===i){xe=null;break}var T=s.sibling;if(T!==null){T.return=s.return,xe=T;break}xe=s.return}}var O3=Math.ceil,Zc=P.ReactCurrentDispatcher,jp=P.ReactCurrentOwner,Hr=P.ReactCurrentBatchConfig,Ge=0,_t=null,wt=null,Ft=0,Pr=0,Ko=Ii(0),Nt=0,zl=null,Aa=0,Jc=0,Sp=0,Fl=null,yr=null,Np=0,Go=1/0,ti=null,ed=!1,Ep=null,zi=null,td=!1,Fi=null,rd=0,Bl=0,Ap=null,nd=-1,id=0;function ur(){return(Ge&6)!==0?yt():nd!==-1?nd:nd=yt()}function Bi(i){return(i.mode&1)===0?1:(Ge&2)!==0&&Ft!==0?Ft&-Ft:h3.transition!==null?(id===0&&(id=kx()),id):(i=Ze,i!==0||(i=window.event,i=i===void 0?16:_x(i.type)),i)}function un(i,s,d,p){if(50<Bl)throw Bl=0,Ap=null,Error(r(185));dl(i,d,p),((Ge&2)===0||i!==_t)&&(i===_t&&((Ge&2)===0&&(Jc|=d),Nt===4&&Ui(i,Ft)),xr(i,p),d===1&&Ge===0&&(s.mode&1)===0&&(Go=yt()+500,Mc&&Di()))}function xr(i,s){var d=i.callbackNode;h_(i,s);var p=hc(i,i===_t?Ft:0);if(p===0)d!==null&&xx(d),i.callbackNode=null,i.callbackPriority=0;else if(s=p&-p,i.callbackPriority!==s){if(d!=null&&xx(d),s===1)i.tag===0?f3(_1.bind(null,i)):gb(_1.bind(null,i)),l3(function(){(Ge&6)===0&&Di()}),d=null;else{switch(jx(p)){case 1:d=om;break;case 4:d=bx;break;case 16:d=uc;break;case 536870912:d=wx;break;default:d=uc}d=z1(d,O1.bind(null,i))}i.callbackPriority=s,i.callbackNode=d}}function O1(i,s){if(nd=-1,id=0,(Ge&6)!==0)throw Error(r(327));var d=i.callbackNode;if(Vo()&&i.callbackNode!==d)return null;var p=hc(i,i===_t?Ft:0);if(p===0)return null;if((p&30)!==0||(p&i.expiredLanes)!==0||s)s=ad(i,p);else{s=p;var x=Ge;Ge|=2;var w=I1();(_t!==i||Ft!==s)&&(ti=null,Go=yt()+500,Pa(i,s));do try{I3();break}catch(T){M1(i,T)}while(!0);Km(),Zc.current=w,Ge=x,wt!==null?s=0:(_t=null,Ft=0,s=Nt)}if(s!==0){if(s===2&&(x=sm(i),x!==0&&(p=x,s=Cp(i,x))),s===1)throw d=zl,Pa(i,0),Ui(i,p),xr(i,yt()),d;if(s===6)Ui(i,p);else{if(x=i.current.alternate,(p&30)===0&&!_3(x)&&(s=ad(i,p),s===2&&(w=sm(i),w!==0&&(p=w,s=Cp(i,w))),s===1))throw d=zl,Pa(i,0),Ui(i,p),xr(i,yt()),d;switch(i.finishedWork=x,i.finishedLanes=p,s){case 0:case 1:throw Error(r(345));case 2:Oa(i,yr,ti);break;case 3:if(Ui(i,p),(p&130023424)===p&&(s=Np+500-yt(),10<s)){if(hc(i,0)!==0)break;if(x=i.suspendedLanes,(x&p)!==p){ur(),i.pingedLanes|=i.suspendedLanes&x;break}i.timeoutHandle=Tm(Oa.bind(null,i,yr,ti),s);break}Oa(i,yr,ti);break;case 4:if(Ui(i,p),(p&4194240)===p)break;for(s=i.eventTimes,x=-1;0<p;){var C=31-rn(p);w=1<<C,C=s[C],C>x&&(x=C),p&=~w}if(p=x,p=yt()-p,p=(120>p?120:480>p?480:1080>p?1080:1920>p?1920:3e3>p?3e3:4320>p?4320:1960*O3(p/1960))-p,10<p){i.timeoutHandle=Tm(Oa.bind(null,i,yr,ti),p);break}Oa(i,yr,ti);break;case 5:Oa(i,yr,ti);break;default:throw Error(r(329))}}}return xr(i,yt()),i.callbackNode===d?O1.bind(null,i):null}function Cp(i,s){var d=Fl;return i.current.memoizedState.isDehydrated&&(Pa(i,s).flags|=256),i=ad(i,s),i!==2&&(s=yr,yr=d,s!==null&&Pp(s)),i}function Pp(i){yr===null?yr=i:yr.push.apply(yr,i)}function _3(i){for(var s=i;;){if(s.flags&16384){var d=s.updateQueue;if(d!==null&&(d=d.stores,d!==null))for(var p=0;p<d.length;p++){var x=d[p],w=x.getSnapshot;x=x.value;try{if(!nn(w(),x))return!1}catch{return!1}}}if(d=s.child,s.subtreeFlags&16384&&d!==null)d.return=s,s=d;else{if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return!0;s=s.return}s.sibling.return=s.return,s=s.sibling}}return!0}function Ui(i,s){for(s&=~Sp,s&=~Jc,i.suspendedLanes|=s,i.pingedLanes&=~s,i=i.expirationTimes;0<s;){var d=31-rn(s),p=1<<d;i[d]=-1,s&=~p}}function _1(i){if((Ge&6)!==0)throw Error(r(327));Vo();var s=hc(i,0);if((s&1)===0)return xr(i,yt()),null;var d=ad(i,s);if(i.tag!==0&&d===2){var p=sm(i);p!==0&&(s=p,d=Cp(i,p))}if(d===1)throw d=zl,Pa(i,0),Ui(i,s),xr(i,yt()),d;if(d===6)throw Error(r(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,Oa(i,yr,ti),xr(i,yt()),null}function Op(i,s){var d=Ge;Ge|=1;try{return i(s)}finally{Ge=d,Ge===0&&(Go=yt()+500,Mc&&Di())}}function Ca(i){Fi!==null&&Fi.tag===0&&(Ge&6)===0&&Vo();var s=Ge;Ge|=1;var d=Hr.transition,p=Ze;try{if(Hr.transition=null,Ze=1,i)return i()}finally{Ze=p,Hr.transition=d,Ge=s,(Ge&6)===0&&Di()}}function _p(){Pr=Ko.current,it(Ko)}function Pa(i,s){i.finishedWork=null,i.finishedLanes=0;var d=i.timeoutHandle;if(d!==-1&&(i.timeoutHandle=-1,s3(d)),wt!==null)for(d=wt.return;d!==null;){var p=d;switch(Fm(p),p.tag){case 1:p=p.type.childContextTypes,p!=null&&Oc();break;case 3:Uo(),it(pr),it(Zt),Jm();break;case 5:Xm(p);break;case 4:Uo();break;case 13:it(dt);break;case 19:it(dt);break;case 10:Gm(p.type._context);break;case 22:case 23:_p()}d=d.return}if(_t=i,wt=i=Hi(i.current,null),Ft=Pr=s,Nt=0,zl=null,Sp=Jc=Aa=0,yr=Fl=null,Sa!==null){for(s=0;s<Sa.length;s++)if(d=Sa[s],p=d.interleaved,p!==null){d.interleaved=null;var x=p.next,w=d.pending;if(w!==null){var C=w.next;w.next=x,p.next=C}d.pending=p}Sa=null}return i}function M1(i,s){do{var d=wt;try{if(Km(),Uc.current=Gc,Hc){for(var p=ft.memoizedState;p!==null;){var x=p.queue;x!==null&&(x.pending=null),p=p.next}Hc=!1}if(Ea=0,Ot=St=ft=null,Il=!1,Tl=0,jp.current=null,d===null||d.return===null){Nt=1,zl=s,wt=null;break}e:{var w=i,C=d.return,T=d,R=s;if(s=Ft,T.flags|=32768,R!==null&&typeof R=="object"&&typeof R.then=="function"){var Q=R,le=T,ce=le.tag;if((le.mode&1)===0&&(ce===0||ce===11||ce===15)){var oe=le.alternate;oe?(le.updateQueue=oe.updateQueue,le.memoizedState=oe.memoizedState,le.lanes=oe.lanes):(le.updateQueue=null,le.memoizedState=null)}var ve=n1(C);if(ve!==null){ve.flags&=-257,i1(ve,C,T,w,s),ve.mode&1&&r1(w,Q,s),s=ve,R=Q;var ke=s.updateQueue;if(ke===null){var Ne=new Set;Ne.add(R),s.updateQueue=Ne}else ke.add(R);break e}else{if((s&1)===0){r1(w,Q,s),Mp();break e}R=Error(r(426))}}else if(lt&&T.mode&1){var xt=n1(C);if(xt!==null){(xt.flags&65536)===0&&(xt.flags|=256),i1(xt,C,T,w,s),Hm(Ho(R,T));break e}}w=R=Ho(R,T),Nt!==4&&(Nt=2),Fl===null?Fl=[w]:Fl.push(w),w=C;do{switch(w.tag){case 3:w.flags|=65536,s&=-s,w.lanes|=s;var W=e1(w,R,s);Ab(w,W);break e;case 1:T=R;var $=w.type,V=w.stateNode;if((w.flags&128)===0&&(typeof $.getDerivedStateFromError=="function"||V!==null&&typeof V.componentDidCatch=="function"&&(zi===null||!zi.has(V)))){w.flags|=65536,s&=-s,w.lanes|=s;var fe=t1(w,T,s);Ab(w,fe);break e}}w=w.return}while(w!==null)}D1(d)}catch(Ce){s=Ce,wt===d&&d!==null&&(wt=d=d.return);continue}break}while(!0)}function I1(){var i=Zc.current;return Zc.current=Gc,i===null?Gc:i}function Mp(){(Nt===0||Nt===3||Nt===2)&&(Nt=4),_t===null||(Aa&268435455)===0&&(Jc&268435455)===0||Ui(_t,Ft)}function ad(i,s){var d=Ge;Ge|=2;var p=I1();(_t!==i||Ft!==s)&&(ti=null,Pa(i,s));do try{M3();break}catch(x){M1(i,x)}while(!0);if(Km(),Ge=d,Zc.current=p,wt!==null)throw Error(r(261));return _t=null,Ft=0,Nt}function M3(){for(;wt!==null;)T1(wt)}function I3(){for(;wt!==null&&!i_();)T1(wt)}function T1(i){var s=$1(i.alternate,i,Pr);i.memoizedProps=i.pendingProps,s===null?D1(i):wt=s,jp.current=null}function D1(i){var s=i;do{var d=s.alternate;if(i=s.return,(s.flags&32768)===0){if(d=N3(d,s,Pr),d!==null){wt=d;return}}else{if(d=E3(d,s),d!==null){d.flags&=32767,wt=d;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{Nt=6,wt=null;return}}if(s=s.sibling,s!==null){wt=s;return}wt=s=i}while(s!==null);Nt===0&&(Nt=5)}function Oa(i,s,d){var p=Ze,x=Hr.transition;try{Hr.transition=null,Ze=1,T3(i,s,d,p)}finally{Hr.transition=x,Ze=p}return null}function T3(i,s,d,p){do Vo();while(Fi!==null);if((Ge&6)!==0)throw Error(r(327));d=i.finishedWork;var x=i.finishedLanes;if(d===null)return null;if(i.finishedWork=null,i.finishedLanes=0,d===i.current)throw Error(r(177));i.callbackNode=null,i.callbackPriority=0;var w=d.lanes|d.childLanes;if(m_(i,w),i===_t&&(wt=_t=null,Ft=0),(d.subtreeFlags&2064)===0&&(d.flags&2064)===0||td||(td=!0,z1(uc,function(){return Vo(),null})),w=(d.flags&15990)!==0,(d.subtreeFlags&15990)!==0||w){w=Hr.transition,Hr.transition=null;var C=Ze;Ze=1;var T=Ge;Ge|=4,jp.current=null,C3(i,d),N1(d,i),e3(Mm),gc=!!_m,Mm=_m=null,i.current=d,P3(d),a_(),Ge=T,Ze=C,Hr.transition=w}else i.current=d;if(td&&(td=!1,Fi=i,rd=x),w=i.pendingLanes,w===0&&(zi=null),l_(d.stateNode),xr(i,yt()),s!==null)for(p=i.onRecoverableError,d=0;d<s.length;d++)x=s[d],p(x.value,{componentStack:x.stack,digest:x.digest});if(ed)throw ed=!1,i=Ep,Ep=null,i;return(rd&1)!==0&&i.tag!==0&&Vo(),w=i.pendingLanes,(w&1)!==0?i===Ap?Bl++:(Bl=0,Ap=i):Bl=0,Di(),null}function Vo(){if(Fi!==null){var i=jx(rd),s=Hr.transition,d=Ze;try{if(Hr.transition=null,Ze=16>i?16:i,Fi===null)var p=!1;else{if(i=Fi,Fi=null,rd=0,(Ge&6)!==0)throw Error(r(331));var x=Ge;for(Ge|=4,xe=i.current;xe!==null;){var w=xe,C=w.child;if((xe.flags&16)!==0){var T=w.deletions;if(T!==null){for(var R=0;R<T.length;R++){var Q=T[R];for(xe=Q;xe!==null;){var le=xe;switch(le.tag){case 0:case 11:case 15:$l(8,le,w)}var ce=le.child;if(ce!==null)ce.return=le,xe=ce;else for(;xe!==null;){le=xe;var oe=le.sibling,ve=le.return;if(b1(le),le===Q){xe=null;break}if(oe!==null){oe.return=ve,xe=oe;break}xe=ve}}}var ke=w.alternate;if(ke!==null){var Ne=ke.child;if(Ne!==null){ke.child=null;do{var xt=Ne.sibling;Ne.sibling=null,Ne=xt}while(Ne!==null)}}xe=w}}if((w.subtreeFlags&2064)!==0&&C!==null)C.return=w,xe=C;else e:for(;xe!==null;){if(w=xe,(w.flags&2048)!==0)switch(w.tag){case 0:case 11:case 15:$l(9,w,w.return)}var W=w.sibling;if(W!==null){W.return=w.return,xe=W;break e}xe=w.return}}var $=i.current;for(xe=$;xe!==null;){C=xe;var V=C.child;if((C.subtreeFlags&2064)!==0&&V!==null)V.return=C,xe=V;else e:for(C=$;xe!==null;){if(T=xe,(T.flags&2048)!==0)try{switch(T.tag){case 0:case 11:case 15:Xc(9,T)}}catch(Ce){ht(T,T.return,Ce)}if(T===C){xe=null;break e}var fe=T.sibling;if(fe!==null){fe.return=T.return,xe=fe;break e}xe=T.return}}if(Ge=x,Di(),wn&&typeof wn.onPostCommitFiberRoot=="function")try{wn.onPostCommitFiberRoot(cc,i)}catch{}p=!0}return p}finally{Ze=d,Hr.transition=s}}return!1}function R1(i,s,d){s=Ho(d,s),s=e1(i,s,1),i=Li(i,s,1),s=ur(),i!==null&&(dl(i,1,s),xr(i,s))}function ht(i,s,d){if(i.tag===3)R1(i,i,d);else for(;s!==null;){if(s.tag===3){R1(s,i,d);break}else if(s.tag===1){var p=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof p.componentDidCatch=="function"&&(zi===null||!zi.has(p))){i=Ho(d,i),i=t1(s,i,1),s=Li(s,i,1),i=ur(),s!==null&&(dl(s,1,i),xr(s,i));break}}s=s.return}}function D3(i,s,d){var p=i.pingCache;p!==null&&p.delete(s),s=ur(),i.pingedLanes|=i.suspendedLanes&d,_t===i&&(Ft&d)===d&&(Nt===4||Nt===3&&(Ft&130023424)===Ft&&500>yt()-Np?Pa(i,0):Sp|=d),xr(i,s)}function L1(i,s){s===0&&((i.mode&1)===0?s=1:(s=fc,fc<<=1,(fc&130023424)===0&&(fc=4194304)));var d=ur();i=Zn(i,s),i!==null&&(dl(i,s,d),xr(i,d))}function R3(i){var s=i.memoizedState,d=0;s!==null&&(d=s.retryLane),L1(i,d)}function L3(i,s){var d=0;switch(i.tag){case 13:var p=i.stateNode,x=i.memoizedState;x!==null&&(d=x.retryLane);break;case 19:p=i.stateNode;break;default:throw Error(r(314))}p!==null&&p.delete(s),L1(i,d)}var $1;$1=function(i,s,d){if(i!==null)if(i.memoizedProps!==s.pendingProps||pr.current)vr=!0;else{if((i.lanes&d)===0&&(s.flags&128)===0)return vr=!1,S3(i,s,d);vr=(i.flags&131072)!==0}else vr=!1,lt&&(s.flags&1048576)!==0&&vb(s,Tc,s.index);switch(s.lanes=0,s.tag){case 2:var p=s.type;Qc(i,s),i=s.pendingProps;var x=Do(s,Zt.current);Bo(s,d),x=rp(null,s,p,i,x,d);var w=np();return s.flags|=1,typeof x=="object"&&x!==null&&typeof x.render=="function"&&x.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,gr(p)?(w=!0,_c(s)):w=!1,s.memoizedState=x.state!==null&&x.state!==void 0?x.state:null,Qm(s),x.updater=Vc,s.stateNode=x,x._reactInternals=s,up(s,p,i,d),s=hp(null,s,p,!0,w,d)):(s.tag=0,lt&&w&&zm(s),lr(null,s,x,d),s=s.child),s;case 16:p=s.elementType;e:{switch(Qc(i,s),i=s.pendingProps,x=p._init,p=x(p._payload),s.type=p,x=s.tag=z3(p),i=on(p,i),x){case 0:s=fp(null,s,p,i,d);break e;case 1:s=c1(null,s,p,i,d);break e;case 11:s=a1(null,s,p,i,d);break e;case 14:s=o1(null,s,p,on(p.type,i),d);break e}throw Error(r(306,p,""))}return s;case 0:return p=s.type,x=s.pendingProps,x=s.elementType===p?x:on(p,x),fp(i,s,p,x,d);case 1:return p=s.type,x=s.pendingProps,x=s.elementType===p?x:on(p,x),c1(i,s,p,x,d);case 3:e:{if(d1(s),i===null)throw Error(r(387));p=s.pendingProps,w=s.memoizedState,x=w.element,Eb(i,s),Fc(s,p,null,d);var C=s.memoizedState;if(p=C.element,w.isDehydrated)if(w={element:p,isDehydrated:!1,cache:C.cache,pendingSuspenseBoundaries:C.pendingSuspenseBoundaries,transitions:C.transitions},s.updateQueue.baseState=w,s.memoizedState=w,s.flags&256){x=Ho(Error(r(423)),s),s=f1(i,s,p,d,x);break e}else if(p!==x){x=Ho(Error(r(424)),s),s=f1(i,s,p,d,x);break e}else for(Cr=Mi(s.stateNode.containerInfo.firstChild),Ar=s,lt=!0,an=null,d=Sb(s,null,p,d),s.child=d;d;)d.flags=d.flags&-3|4096,d=d.sibling;else{if($o(),p===x){s=ei(i,s,d);break e}lr(i,s,p,d)}s=s.child}return s;case 5:return Pb(s),i===null&&Um(s),p=s.type,x=s.pendingProps,w=i!==null?i.memoizedProps:null,C=x.children,Im(p,x)?C=null:w!==null&&Im(p,w)&&(s.flags|=32),u1(i,s),lr(i,s,C,d),s.child;case 6:return i===null&&Um(s),null;case 13:return h1(i,s,d);case 4:return Ym(s,s.stateNode.containerInfo),p=s.pendingProps,i===null?s.child=zo(s,null,p,d):lr(i,s,p,d),s.child;case 11:return p=s.type,x=s.pendingProps,x=s.elementType===p?x:on(p,x),a1(i,s,p,x,d);case 7:return lr(i,s,s.pendingProps,d),s.child;case 8:return lr(i,s,s.pendingProps.children,d),s.child;case 12:return lr(i,s,s.pendingProps.children,d),s.child;case 10:e:{if(p=s.type._context,x=s.pendingProps,w=s.memoizedProps,C=x.value,tt(Lc,p._currentValue),p._currentValue=C,w!==null)if(nn(w.value,C)){if(w.children===x.children&&!pr.current){s=ei(i,s,d);break e}}else for(w=s.child,w!==null&&(w.return=s);w!==null;){var T=w.dependencies;if(T!==null){C=w.child;for(var R=T.firstContext;R!==null;){if(R.context===p){if(w.tag===1){R=Jn(-1,d&-d),R.tag=2;var Q=w.updateQueue;if(Q!==null){Q=Q.shared;var le=Q.pending;le===null?R.next=R:(R.next=le.next,le.next=R),Q.pending=R}}w.lanes|=d,R=w.alternate,R!==null&&(R.lanes|=d),Vm(w.return,d,s),T.lanes|=d;break}R=R.next}}else if(w.tag===10)C=w.type===s.type?null:w.child;else if(w.tag===18){if(C=w.return,C===null)throw Error(r(341));C.lanes|=d,T=C.alternate,T!==null&&(T.lanes|=d),Vm(C,d,s),C=w.sibling}else C=w.child;if(C!==null)C.return=w;else for(C=w;C!==null;){if(C===s){C=null;break}if(w=C.sibling,w!==null){w.return=C.return,C=w;break}C=C.return}w=C}lr(i,s,x.children,d),s=s.child}return s;case 9:return x=s.type,p=s.pendingProps.children,Bo(s,d),x=Br(x),p=p(x),s.flags|=1,lr(i,s,p,d),s.child;case 14:return p=s.type,x=on(p,s.pendingProps),x=on(p.type,x),o1(i,s,p,x,d);case 15:return s1(i,s,s.type,s.pendingProps,d);case 17:return p=s.type,x=s.pendingProps,x=s.elementType===p?x:on(p,x),Qc(i,s),s.tag=1,gr(p)?(i=!0,_c(s)):i=!1,Bo(s,d),Zb(s,p,x),up(s,p,x,d),hp(null,s,p,!0,i,d);case 19:return p1(i,s,d);case 22:return l1(i,s,d)}throw Error(r(156,s.tag))};function z1(i,s){return yx(i,s)}function $3(i,s,d,p){this.tag=i,this.key=d,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=s,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=p,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Wr(i,s,d,p){return new $3(i,s,d,p)}function Ip(i){return i=i.prototype,!(!i||!i.isReactComponent)}function z3(i){if(typeof i=="function")return Ip(i)?1:0;if(i!=null){if(i=i.$$typeof,i===U)return 11;if(i===ge)return 14}return 2}function Hi(i,s){var d=i.alternate;return d===null?(d=Wr(i.tag,s,i.key,i.mode),d.elementType=i.elementType,d.type=i.type,d.stateNode=i.stateNode,d.alternate=i,i.alternate=d):(d.pendingProps=s,d.type=i.type,d.flags=0,d.subtreeFlags=0,d.deletions=null),d.flags=i.flags&14680064,d.childLanes=i.childLanes,d.lanes=i.lanes,d.child=i.child,d.memoizedProps=i.memoizedProps,d.memoizedState=i.memoizedState,d.updateQueue=i.updateQueue,s=i.dependencies,d.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext},d.sibling=i.sibling,d.index=i.index,d.ref=i.ref,d}function od(i,s,d,p,x,w){var C=2;if(p=i,typeof i=="function")Ip(i)&&(C=1);else if(typeof i=="string")C=5;else e:switch(i){case D:return _a(d.children,x,w,s);case B:C=8,x|=8;break;case F:return i=Wr(12,d,s,x|2),i.elementType=F,i.lanes=w,i;case he:return i=Wr(13,d,s,x),i.elementType=he,i.lanes=w,i;case ue:return i=Wr(19,d,s,x),i.elementType=ue,i.lanes=w,i;case se:return sd(d,x,w,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case z:C=10;break e;case Y:C=9;break e;case U:C=11;break e;case ge:C=14;break e;case ie:C=16,p=null;break e}throw Error(r(130,i==null?i:typeof i,""))}return s=Wr(C,d,s,x),s.elementType=i,s.type=p,s.lanes=w,s}function _a(i,s,d,p){return i=Wr(7,i,p,s),i.lanes=d,i}function sd(i,s,d,p){return i=Wr(22,i,p,s),i.elementType=se,i.lanes=d,i.stateNode={isHidden:!1},i}function Tp(i,s,d){return i=Wr(6,i,null,s),i.lanes=d,i}function Dp(i,s,d){return s=Wr(4,i.children!==null?i.children:[],i.key,s),s.lanes=d,s.stateNode={containerInfo:i.containerInfo,pendingChildren:null,implementation:i.implementation},s}function F3(i,s,d,p,x){this.tag=s,this.containerInfo=i,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=lm(0),this.expirationTimes=lm(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=lm(0),this.identifierPrefix=p,this.onRecoverableError=x,this.mutableSourceEagerHydrationData=null}function Rp(i,s,d,p,x,w,C,T,R){return i=new F3(i,s,d,T,R),s===1?(s=1,w===!0&&(s|=8)):s=0,w=Wr(3,null,null,s),i.current=w,w.stateNode=i,w.memoizedState={element:p,isDehydrated:d,cache:null,transitions:null,pendingSuspenseBoundaries:null},Qm(w),i}function B3(i,s,d){var p=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:O,key:p==null?null:""+p,children:i,containerInfo:s,implementation:d}}function F1(i){if(!i)return Ti;i=i._reactInternals;e:{if(xa(i)!==i||i.tag!==1)throw Error(r(170));var s=i;do{switch(s.tag){case 3:s=s.stateNode.context;break e;case 1:if(gr(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break e}}s=s.return}while(s!==null);throw Error(r(171))}if(i.tag===1){var d=i.type;if(gr(d))return mb(i,d,s)}return s}function B1(i,s,d,p,x,w,C,T,R){return i=Rp(d,p,!0,i,x,w,C,T,R),i.context=F1(null),d=i.current,p=ur(),x=Bi(d),w=Jn(p,x),w.callback=s??null,Li(d,w,x),i.current.lanes=x,dl(i,x,p),xr(i,p),i}function ld(i,s,d,p){var x=s.current,w=ur(),C=Bi(x);return d=F1(d),s.context===null?s.context=d:s.pendingContext=d,s=Jn(w,C),s.payload={element:i},p=p===void 0?null:p,p!==null&&(s.callback=p),i=Li(x,s,C),i!==null&&(un(i,x,C,w),zc(i,x,C)),C}function ud(i){if(i=i.current,!i.child)return null;switch(i.child.tag){case 5:return i.child.stateNode;default:return i.child.stateNode}}function U1(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var d=i.retryLane;i.retryLane=d!==0&&d<s?d:s}}function Lp(i,s){U1(i,s),(i=i.alternate)&&U1(i,s)}function U3(){return null}var H1=typeof reportError=="function"?reportError:function(i){console.error(i)};function $p(i){this._internalRoot=i}cd.prototype.render=$p.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(r(409));ld(i,s,null,null)},cd.prototype.unmount=$p.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;Ca(function(){ld(null,i,null,null)}),s[qn]=null}};function cd(i){this._internalRoot=i}cd.prototype.unstable_scheduleHydration=function(i){if(i){var s=Ex();i={blockedOn:null,target:i,priority:s};for(var d=0;d<Pi.length&&s!==0&&s<Pi[d].priority;d++);Pi.splice(d,0,i),d===0&&Px(i)}};function zp(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function dd(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function W1(){}function H3(i,s,d,p,x){if(x){if(typeof p=="function"){var w=p;p=function(){var Q=ud(C);w.call(Q)}}var C=B1(s,p,i,0,null,!1,!1,"",W1);return i._reactRootContainer=C,i[qn]=C.current,Nl(i.nodeType===8?i.parentNode:i),Ca(),C}for(;x=i.lastChild;)i.removeChild(x);if(typeof p=="function"){var T=p;p=function(){var Q=ud(R);T.call(Q)}}var R=Rp(i,0,!1,null,null,!1,!1,"",W1);return i._reactRootContainer=R,i[qn]=R.current,Nl(i.nodeType===8?i.parentNode:i),Ca(function(){ld(s,R,d,p)}),R}function fd(i,s,d,p,x){var w=d._reactRootContainer;if(w){var C=w;if(typeof x=="function"){var T=x;x=function(){var R=ud(C);T.call(R)}}ld(s,C,i,x)}else C=H3(d,s,i,x,p);return ud(C)}Sx=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var d=cl(s.pendingLanes);d!==0&&(um(s,d|1),xr(s,yt()),(Ge&6)===0&&(Go=yt()+500,Di()))}break;case 13:Ca(function(){var p=Zn(i,1);if(p!==null){var x=ur();un(p,i,1,x)}}),Lp(i,1)}},cm=function(i){if(i.tag===13){var s=Zn(i,134217728);if(s!==null){var d=ur();un(s,i,134217728,d)}Lp(i,134217728)}},Nx=function(i){if(i.tag===13){var s=Bi(i),d=Zn(i,s);if(d!==null){var p=ur();un(d,i,s,p)}Lp(i,s)}},Ex=function(){return Ze},Ax=function(i,s){var d=Ze;try{return Ze=i,s()}finally{Ze=d}},rm=function(i,s,d){switch(s){case"input":if(Yt(i,d),s=d.name,d.type==="radio"&&s!=null){for(d=i;d.parentNode;)d=d.parentNode;for(d=d.querySelectorAll("input[name="+JSON.stringify(""+s)+'][type="radio"]'),s=0;s<d.length;s++){var p=d[s];if(p!==i&&p.form===i.form){var x=Pc(p);if(!x)throw Error(r(90));ae(p),Yt(p,x)}}}break;case"textarea":Xt(i,d);break;case"select":s=d.value,s!=null&&qe(i,!!d.multiple,s,!1)}},dx=Op,fx=Ca;var W3={usingClientEntryPoint:!1,Events:[Cl,Io,Pc,ux,cx,Op]},Ul={findFiberByHostInstance:ba,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},K3={bundleType:Ul.bundleType,version:Ul.version,rendererPackageName:Ul.rendererPackageName,rendererConfig:Ul.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:P.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=gx(i),i===null?null:i.stateNode},findFiberByHostInstance:Ul.findFiberByHostInstance||U3,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 hd=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!hd.isDisabled&&hd.supportsFiber)try{cc=hd.inject(K3),wn=hd}catch{}}return br.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=W3,br.createPortal=function(i,s){var d=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!zp(s))throw Error(r(200));return B3(i,s,null,d)},br.createRoot=function(i,s){if(!zp(i))throw Error(r(299));var d=!1,p="",x=H1;return s!=null&&(s.unstable_strictMode===!0&&(d=!0),s.identifierPrefix!==void 0&&(p=s.identifierPrefix),s.onRecoverableError!==void 0&&(x=s.onRecoverableError)),s=Rp(i,1,!1,null,null,d,!1,p,x),i[qn]=s.current,Nl(i.nodeType===8?i.parentNode:i),new $p(s)},br.findDOMNode=function(i){if(i==null)return null;if(i.nodeType===1)return i;var s=i._reactInternals;if(s===void 0)throw typeof i.render=="function"?Error(r(188)):(i=Object.keys(i).join(","),Error(r(268,i)));return i=gx(s),i=i===null?null:i.stateNode,i},br.flushSync=function(i){return Ca(i)},br.hydrate=function(i,s,d){if(!dd(s))throw Error(r(200));return fd(null,i,s,!0,d)},br.hydrateRoot=function(i,s,d){if(!zp(i))throw Error(r(405));var p=d!=null&&d.hydratedSources||null,x=!1,w="",C=H1;if(d!=null&&(d.unstable_strictMode===!0&&(x=!0),d.identifierPrefix!==void 0&&(w=d.identifierPrefix),d.onRecoverableError!==void 0&&(C=d.onRecoverableError)),s=B1(s,null,i,1,d??null,x,!1,w,C),i[qn]=s.current,Nl(i),p)for(i=0;i<p.length;i++)d=p[i],x=d._getVersion,x=x(d._source),s.mutableSourceEagerHydrationData==null?s.mutableSourceEagerHydrationData=[d,x]:s.mutableSourceEagerHydrationData.push(d,x);return new cd(s)},br.render=function(i,s,d){if(!dd(s))throw Error(r(200));return fd(null,i,s,!1,d)},br.unmountComponentAtNode=function(i){if(!dd(i))throw Error(r(40));return i._reactRootContainer?(Ca(function(){fd(null,null,i,!1,function(){i._reactRootContainer=null,i[qn]=null})}),!0):!1},br.unstable_batchedUpdates=Op,br.unstable_renderSubtreeIntoContainer=function(i,s,d,p){if(!dd(d))throw Error(r(200));if(i==null||i._reactInternals===void 0)throw Error(r(38));return fd(i,s,d,!1,p)},br.version="18.3.1-next-f1338f8080-20240426",br}var J1;function cN(){if(J1)return Hp.exports;J1=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),Hp.exports=tM(),Hp.exports}var ew;function rM(){if(ew)return pd;ew=1;var e=cN();return pd.createRoot=e.createRoot,pd.hydrateRoot=e.hydrateRoot,pd}var nM=rM();const iM=ly(nM);var Bu=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Va,ea,vs,eN,aM=(eN=class extends Bu{constructor(){super();Re(this,Va);Re(this,ea);Re(this,vs);ye(this,vs,t=>{if(typeof window<"u"&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){L(this,ea)||this.setEventListener(L(this,vs))}onUnsubscribe(){var t;this.hasListeners()||((t=L(this,ea))==null||t.call(this),ye(this,ea,void 0))}setEventListener(t){var r;ye(this,vs,t),(r=L(this,ea))==null||r.call(this),ye(this,ea,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){L(this,Va)!==t&&(ye(this,Va,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof L(this,Va)=="boolean"?L(this,Va):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Va=new WeakMap,ea=new WeakMap,vs=new WeakMap,eN),cy=new aM,oM={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},ta,sy,tN,sM=(tN=class{constructor(){Re(this,ta,oM);Re(this,sy,!1)}setTimeoutProvider(e){ye(this,ta,e)}setTimeout(e,t){return L(this,ta).setTimeout(e,t)}clearTimeout(e){L(this,ta).clearTimeout(e)}setInterval(e,t){return L(this,ta).setInterval(e,t)}clearInterval(e){L(this,ta).clearInterval(e)}},ta=new WeakMap,sy=new WeakMap,tN),Ba=new sM;function lM(e){setTimeout(e,0)}var uM=typeof window>"u"||"Deno"in globalThis;function kr(){}function cM(e,t){return typeof e=="function"?e(t):e}function $g(e){return typeof e=="number"&&e>=0&&e!==1/0}function dN(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ua(e,t){return typeof e=="function"?e(t):e}function Ir(e,t){return typeof e=="function"?e(t):e}function tw(e,t){const{type:r="all",exact:n,fetchStatus:a,predicate:o,queryKey:u,stale:c}=e;if(u){if(n){if(t.queryHash!==dy(u,t.options))return!1}else if(!pu(t.queryKey,u))return!1}if(r!=="all"){const f=t.isActive();if(r==="active"&&!f||r==="inactive"&&f)return!1}return!(typeof c=="boolean"&&t.isStale()!==c||a&&a!==t.state.fetchStatus||o&&!o(t))}function rw(e,t){const{exact:r,status:n,predicate:a,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(r){if(mu(t.options.mutationKey)!==mu(o))return!1}else if(!pu(t.options.mutationKey,o))return!1}return!(n&&t.state.status!==n||a&&!a(t))}function dy(e,t){return((t==null?void 0:t.queryKeyHashFn)||mu)(e)}function mu(e){return JSON.stringify(e,(t,r)=>Fg(r)?Object.keys(r).sort().reduce((n,a)=>(n[a]=r[a],n),{}):r)}function pu(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>pu(e[r],t[r])):!1}var dM=Object.prototype.hasOwnProperty;function fN(e,t,r=0){if(e===t)return e;if(r>500)return t;const n=nw(e)&&nw(t);if(!n&&!(Fg(e)&&Fg(t)))return t;const o=(n?e:Object.keys(e)).length,u=n?t:Object.keys(t),c=u.length,f=n?new Array(c):{};let h=0;for(let m=0;m<c;m++){const g=n?m:u[m],v=e[g],b=t[g];if(v===b){f[g]=v,(n?m<o:dM.call(e,g))&&h++;continue}if(v===null||b===null||typeof v!="object"||typeof b!="object"){f[g]=b;continue}const j=fN(v,b,r+1);f[g]=j,j===v&&h++}return o===c&&h===o?e:f}function zg(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function nw(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Fg(e){if(!iw(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!iw(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function iw(e){return Object.prototype.toString.call(e)==="[object Object]"}function fM(e){return new Promise(t=>{Ba.setTimeout(t,e)})}function Bg(e,t,r){return typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?fN(e,t):t}function hM(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function mM(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var fy=Symbol();function hN(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===fy?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function mN(e,t){return typeof e=="function"?e(...t):!!e}function pM(e,t,r){let n=!1,a;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(a??(a=t()),n||(n=!0,a.aborted?r():a.addEventListener("abort",r,{once:!0})),a)}),e}var gu=(()=>{let e=()=>uM;return{isServer(){return e()},setIsServer(t){e=t}}})();function Ug(){let e,t;const r=new Promise((a,o)=>{e=a,t=o});r.status="pending",r.catch(()=>{});function n(a){Object.assign(r,a),delete r.resolve,delete r.reject}return r.resolve=a=>{n({status:"fulfilled",value:a}),e(a)},r.reject=a=>{n({status:"rejected",reason:a}),t(a)},r}var gM=lM;function vM(){let e=[],t=0,r=c=>{c()},n=c=>{c()},a=gM;const o=c=>{t?e.push(c):a(()=>{r(c)})},u=()=>{const c=e;e=[],c.length&&a(()=>{n(()=>{c.forEach(f=>{r(f)})})})};return{batch:c=>{let f;t++;try{f=c()}finally{t--,t||u()}return f},batchCalls:c=>(...f)=>{o(()=>{c(...f)})},schedule:o,setNotifyFunction:c=>{r=c},setBatchNotifyFunction:c=>{n=c},setScheduler:c=>{a=c}}}var Wt=vM(),ys,ra,xs,rN,yM=(rN=class extends Bu{constructor(){super();Re(this,ys,!0);Re(this,ra);Re(this,xs);ye(this,xs,t=>{if(typeof window<"u"&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){L(this,ra)||this.setEventListener(L(this,xs))}onUnsubscribe(){var t;this.hasListeners()||((t=L(this,ra))==null||t.call(this),ye(this,ra,void 0))}setEventListener(t){var r;ye(this,xs,t),(r=L(this,ra))==null||r.call(this),ye(this,ra,t(this.setOnline.bind(this)))}setOnline(t){L(this,ys)!==t&&(ye(this,ys,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return L(this,ys)}},ys=new WeakMap,ra=new WeakMap,xs=new WeakMap,rN),Yd=new yM;function xM(e){return Math.min(1e3*2**e,3e4)}function pN(e){return(e??"online")==="online"?Yd.isOnline():!0}var Hg=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function gN(e){let t=!1,r=0,n;const a=Ug(),o=()=>a.status!=="pending",u=k=>{var S;if(!o()){const N=new Hg(k);v(N),(S=e.onCancel)==null||S.call(e,N)}},c=()=>{t=!0},f=()=>{t=!1},h=()=>cy.isFocused()&&(e.networkMode==="always"||Yd.isOnline())&&e.canRun(),m=()=>pN(e.networkMode)&&e.canRun(),g=k=>{o()||(n==null||n(),a.resolve(k))},v=k=>{o()||(n==null||n(),a.reject(k))},b=()=>new Promise(k=>{var S;n=N=>{(o()||h())&&k(N)},(S=e.onPause)==null||S.call(e)}).then(()=>{var k;n=void 0,o()||(k=e.onContinue)==null||k.call(e)}),j=()=>{if(o())return;let k;const S=r===0?e.initialPromise:void 0;try{k=S??e.fn()}catch(N){k=Promise.reject(N)}Promise.resolve(k).then(g).catch(N=>{var O;if(o())return;const E=e.retry??(gu.isServer()?0:3),A=e.retryDelay??xM,P=typeof A=="function"?A(r,N):A,_=E===!0||typeof E=="number"&&r<E||typeof E=="function"&&E(r,N);if(t||!_){v(N);return}r++,(O=e.onFail)==null||O.call(e,r,N),fM(P).then(()=>h()?void 0:b()).then(()=>{t?v(N):j()})})};return{promise:a,status:()=>a.status,cancel:u,continue:()=>(n==null||n(),a),cancelRetry:c,continueRetry:f,canStart:m,start:()=>(m()?j():b().then(j),a)}}var qa,nN,vN=(nN=class{constructor(){Re(this,qa)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),$g(this.gcTime)&&ye(this,qa,Ba.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(gu.isServer()?1/0:300*1e3))}clearGcTimeout(){L(this,qa)!==void 0&&(Ba.clearTimeout(L(this,qa)),ye(this,qa,void 0))}},qa=new WeakMap,nN);function bM(e){return{onFetch:(t,r)=>{var m,g,v,b,j;const n=t.options,a=(v=(g=(m=t.fetchOptions)==null?void 0:m.meta)==null?void 0:g.fetchMore)==null?void 0:v.direction,o=((b=t.state.data)==null?void 0:b.pages)||[],u=((j=t.state.data)==null?void 0:j.pageParams)||[];let c={pages:[],pageParams:[]},f=0;const h=async()=>{let k=!1;const S=A=>{pM(A,()=>t.signal,()=>k=!0)},N=hN(t.options,t.fetchOptions),E=async(A,P,_)=>{if(k)return Promise.reject(t.signal.reason);if(P==null&&A.pages.length)return Promise.resolve(A);const D=(()=>{const Y={client:t.client,queryKey:t.queryKey,pageParam:P,direction:_?"backward":"forward",meta:t.options.meta};return S(Y),Y})(),B=await N(D),{maxPages:F}=t.options,z=_?mM:hM;return{pages:z(A.pages,B,F),pageParams:z(A.pageParams,P,F)}};if(a&&o.length){const A=a==="backward",P=A?wM:aw,_={pages:o,pageParams:u},O=P(n,_);c=await E(_,O,A)}else{const A=e??o.length;do{const P=f===0?u[0]??n.initialPageParam:aw(n,c);if(f>0&&P==null)break;c=await E(c,P),f++}while(f<A)}return c};t.options.persister?t.fetchFn=()=>{var k,S;return(S=(k=t.options).persister)==null?void 0:S.call(k,h,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=h}}}function aw(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function wM(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}var bs,Qa,ws,Gr,Ya,It,Ru,Xa,Mr,yN,ni,iN,kM=(iN=class extends vN{constructor(t){super();Re(this,Mr);Re(this,bs);Re(this,Qa);Re(this,ws);Re(this,Gr);Re(this,Ya);Re(this,It);Re(this,Ru);Re(this,Xa);ye(this,Xa,!1),ye(this,Ru,t.defaultOptions),this.setOptions(t.options),this.observers=[],ye(this,Ya,t.client),ye(this,Gr,L(this,Ya).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,ye(this,Qa,sw(this.options)),this.state=t.state??L(this,Qa),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return L(this,bs)}get promise(){var t;return(t=L(this,It))==null?void 0:t.promise}setOptions(t){if(this.options={...L(this,Ru),...t},t!=null&&t._type&&ye(this,bs,t._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const r=sw(this.options);r.data!==void 0&&(this.setState(ow(r.data,r.dataUpdatedAt)),ye(this,Qa,r))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&L(this,Gr).remove(this)}setData(t,r){const n=Bg(this.state.data,t,this.options);return Ue(this,Mr,ni).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t){Ue(this,Mr,ni).call(this,{type:"setState",state:t})}cancel(t){var n,a;const r=(n=L(this,It))==null?void 0:n.promise;return(a=L(this,It))==null||a.cancel(t),r?r.then(kr).catch(kr):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return L(this,Qa)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(t=>Ir(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===fy||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>ua(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!dN(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=L(this,It))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=L(this,It))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),L(this,Gr).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(L(this,It)&&(L(this,Xa)||Ue(this,Mr,yN).call(this)?L(this,It).cancel({revert:!0}):L(this,It).cancelRetry()),this.scheduleGc()),L(this,Gr).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Ue(this,Mr,ni).call(this,{type:"invalidate"})}async fetch(t,r){var h,m,g,v,b,j,k,S,N,E,A;if(this.state.fetchStatus!=="idle"&&((h=L(this,It))==null?void 0:h.status())!=="rejected"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(L(this,It))return L(this,It).continueRetry(),L(this,It).promise}if(t&&this.setOptions(t),!this.options.queryFn){const P=this.observers.find(_=>_.options.queryFn);P&&this.setOptions(P.options)}const n=new AbortController,a=P=>{Object.defineProperty(P,"signal",{enumerable:!0,get:()=>(ye(this,Xa,!0),n.signal)})},o=()=>{const P=hN(this.options,r),O=(()=>{const D={client:L(this,Ya),queryKey:this.queryKey,meta:this.meta};return a(D),D})();return ye(this,Xa,!1),this.options.persister?this.options.persister(P,O,this):P(O)},c=(()=>{const P={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:L(this,Ya),state:this.state,fetchFn:o};return a(P),P})(),f=L(this,bs)==="infinite"?bM(this.options.pages):this.options.behavior;f==null||f.onFetch(c,this),ye(this,ws,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((m=c.fetchOptions)==null?void 0:m.meta))&&Ue(this,Mr,ni).call(this,{type:"fetch",meta:(g=c.fetchOptions)==null?void 0:g.meta}),ye(this,It,gN({initialPromise:r==null?void 0:r.initialPromise,fn:c.fetchFn,onCancel:P=>{P instanceof Hg&&P.revert&&this.setState({...L(this,ws),fetchStatus:"idle"}),n.abort()},onFail:(P,_)=>{Ue(this,Mr,ni).call(this,{type:"failed",failureCount:P,error:_})},onPause:()=>{Ue(this,Mr,ni).call(this,{type:"pause"})},onContinue:()=>{Ue(this,Mr,ni).call(this,{type:"continue"})},retry:c.options.retry,retryDelay:c.options.retryDelay,networkMode:c.options.networkMode,canRun:()=>!0}));try{const P=await L(this,It).start();if(P===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(P),(b=(v=L(this,Gr).config).onSuccess)==null||b.call(v,P,this),(k=(j=L(this,Gr).config).onSettled)==null||k.call(j,P,this.state.error,this),P}catch(P){if(P instanceof Hg){if(P.silent)return L(this,It).promise;if(P.revert){if(this.state.data===void 0)throw P;return this.state.data}}throw Ue(this,Mr,ni).call(this,{type:"error",error:P}),(N=(S=L(this,Gr).config).onError)==null||N.call(S,P,this),(A=(E=L(this,Gr).config).onSettled)==null||A.call(E,this.state.data,P,this),P}finally{this.scheduleGc()}}},bs=new WeakMap,Qa=new WeakMap,ws=new WeakMap,Gr=new WeakMap,Ya=new WeakMap,It=new WeakMap,Ru=new WeakMap,Xa=new WeakMap,Mr=new WeakSet,yN=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},ni=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...xN(n.data,this.options),fetchMeta:t.meta??null};case"success":const a={...n,...ow(t.data,t.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return ye(this,ws,t.manual?a:void 0),a;case"error":const o=t.error;return{...n,error:o,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=r(this.state),Wt.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),L(this,Gr).notify({query:this,type:"updated",action:t})})},iN);function xN(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:pN(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function ow(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function sw(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var wr,We,Lu,cr,Za,ks,ai,na,$u,js,Ss,Ja,eo,ia,Ns,Xe,au,Wg,Kg,Gg,Vg,qg,Qg,Yg,bN,aN,jM=(aN=class extends Bu{constructor(t,r){super();Re(this,Xe);Re(this,wr);Re(this,We);Re(this,Lu);Re(this,cr);Re(this,Za);Re(this,ks);Re(this,ai);Re(this,na);Re(this,$u);Re(this,js);Re(this,Ss);Re(this,Ja);Re(this,eo);Re(this,ia);Re(this,Ns,new Set);this.options=r,ye(this,wr,t),ye(this,na,null),ye(this,ai,Ug()),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(L(this,We).addObserver(this),lw(L(this,We),this.options)?Ue(this,Xe,au).call(this):this.updateResult(),Ue(this,Xe,Vg).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Xg(L(this,We),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Xg(L(this,We),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Ue(this,Xe,qg).call(this),Ue(this,Xe,Qg).call(this),L(this,We).removeObserver(this)}setOptions(t){const r=this.options,n=L(this,We);if(this.options=L(this,wr).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Ir(this.options.enabled,L(this,We))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Ue(this,Xe,Yg).call(this),L(this,We).setOptions(this.options),r._defaulted&&!zg(this.options,r)&&L(this,wr).getQueryCache().notify({type:"observerOptionsUpdated",query:L(this,We),observer:this});const a=this.hasListeners();a&&uw(L(this,We),n,this.options,r)&&Ue(this,Xe,au).call(this),this.updateResult(),a&&(L(this,We)!==n||Ir(this.options.enabled,L(this,We))!==Ir(r.enabled,L(this,We))||ua(this.options.staleTime,L(this,We))!==ua(r.staleTime,L(this,We)))&&Ue(this,Xe,Wg).call(this);const o=Ue(this,Xe,Kg).call(this);a&&(L(this,We)!==n||Ir(this.options.enabled,L(this,We))!==Ir(r.enabled,L(this,We))||o!==L(this,ia))&&Ue(this,Xe,Gg).call(this,o)}getOptimisticResult(t){const r=L(this,wr).getQueryCache().build(L(this,wr),t),n=this.createResult(r,t);return NM(this,n)&&(ye(this,cr,n),ye(this,ks,this.options),ye(this,Za,L(this,We).state)),n}getCurrentResult(){return L(this,cr)}trackResult(t,r){return new Proxy(t,{get:(n,a)=>(this.trackProp(a),r==null||r(a),a==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&L(this,ai).status==="pending"&&L(this,ai).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(n,a))})}trackProp(t){L(this,Ns).add(t)}getCurrentQuery(){return L(this,We)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=L(this,wr).defaultQueryOptions(t),n=L(this,wr).getQueryCache().build(L(this,wr),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return Ue(this,Xe,au).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),L(this,cr)))}createResult(t,r){var F;const n=L(this,We),a=this.options,o=L(this,cr),u=L(this,Za),c=L(this,ks),h=t!==n?t.state:L(this,Lu),{state:m}=t;let g={...m},v=!1,b;if(r._optimisticResults){const z=this.hasListeners(),Y=!z&&lw(t,r),U=z&&uw(t,n,r,a);(Y||U)&&(g={...g,...xN(m.data,t.options)}),r._optimisticResults==="isRestoring"&&(g.fetchStatus="idle")}let{error:j,errorUpdatedAt:k,status:S}=g;b=g.data;let N=!1;if(r.placeholderData!==void 0&&b===void 0&&S==="pending"){let z;o!=null&&o.isPlaceholderData&&r.placeholderData===(c==null?void 0:c.placeholderData)?(z=o.data,N=!0):z=typeof r.placeholderData=="function"?r.placeholderData((F=L(this,Ss))==null?void 0:F.state.data,L(this,Ss)):r.placeholderData,z!==void 0&&(S="success",b=Bg(o==null?void 0:o.data,z,r),v=!0)}if(r.select&&b!==void 0&&!N)if(o&&b===(u==null?void 0:u.data)&&r.select===L(this,$u))b=L(this,js);else try{ye(this,$u,r.select),b=r.select(b),b=Bg(o==null?void 0:o.data,b,r),ye(this,js,b),ye(this,na,null)}catch(z){ye(this,na,z)}L(this,na)&&(j=L(this,na),b=L(this,js),k=Date.now(),S="error");const E=g.fetchStatus==="fetching",A=S==="pending",P=S==="error",_=A&&E,O=b!==void 0,B={status:S,fetchStatus:g.fetchStatus,isPending:A,isSuccess:S==="success",isError:P,isInitialLoading:_,isLoading:_,data:b,dataUpdatedAt:g.dataUpdatedAt,error:j,errorUpdatedAt:k,failureCount:g.fetchFailureCount,failureReason:g.fetchFailureReason,errorUpdateCount:g.errorUpdateCount,isFetched:t.isFetched(),isFetchedAfterMount:g.dataUpdateCount>h.dataUpdateCount||g.errorUpdateCount>h.errorUpdateCount,isFetching:E,isRefetching:E&&!A,isLoadingError:P&&!O,isPaused:g.fetchStatus==="paused",isPlaceholderData:v,isRefetchError:P&&O,isStale:hy(t,r),refetch:this.refetch,promise:L(this,ai),isEnabled:Ir(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const z=B.data!==void 0,Y=B.status==="error"&&!z,U=ge=>{Y?ge.reject(B.error):z&&ge.resolve(B.data)},he=()=>{const ge=ye(this,ai,B.promise=Ug());U(ge)},ue=L(this,ai);switch(ue.status){case"pending":t.queryHash===n.queryHash&&U(ue);break;case"fulfilled":(Y||B.data!==ue.value)&&he();break;case"rejected":(!Y||B.error!==ue.reason)&&he();break}}return B}updateResult(){const t=L(this,cr),r=this.createResult(L(this,We),this.options);if(ye(this,Za,L(this,We).state),ye(this,ks,this.options),L(this,Za).data!==void 0&&ye(this,Ss,L(this,We)),zg(r,t))return;ye(this,cr,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:a}=this.options,o=typeof a=="function"?a():a;if(o==="all"||!o&&!L(this,Ns).size)return!0;const u=new Set(o??L(this,Ns));return this.options.throwOnError&&u.add("error"),Object.keys(L(this,cr)).some(c=>{const f=c;return L(this,cr)[f]!==t[f]&&u.has(f)})};Ue(this,Xe,bN).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Ue(this,Xe,Vg).call(this)}},wr=new WeakMap,We=new WeakMap,Lu=new WeakMap,cr=new WeakMap,Za=new WeakMap,ks=new WeakMap,ai=new WeakMap,na=new WeakMap,$u=new WeakMap,js=new WeakMap,Ss=new WeakMap,Ja=new WeakMap,eo=new WeakMap,ia=new WeakMap,Ns=new WeakMap,Xe=new WeakSet,au=function(t){Ue(this,Xe,Yg).call(this);let r=L(this,We).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(kr)),r},Wg=function(){Ue(this,Xe,qg).call(this);const t=ua(this.options.staleTime,L(this,We));if(gu.isServer()||L(this,cr).isStale||!$g(t))return;const n=dN(L(this,cr).dataUpdatedAt,t)+1;ye(this,Ja,Ba.setTimeout(()=>{L(this,cr).isStale||this.updateResult()},n))},Kg=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(L(this,We)):this.options.refetchInterval)??!1},Gg=function(t){Ue(this,Xe,Qg).call(this),ye(this,ia,t),!(gu.isServer()||Ir(this.options.enabled,L(this,We))===!1||!$g(L(this,ia))||L(this,ia)===0)&&ye(this,eo,Ba.setInterval(()=>{(this.options.refetchIntervalInBackground||cy.isFocused())&&Ue(this,Xe,au).call(this)},L(this,ia)))},Vg=function(){Ue(this,Xe,Wg).call(this),Ue(this,Xe,Gg).call(this,Ue(this,Xe,Kg).call(this))},qg=function(){L(this,Ja)!==void 0&&(Ba.clearTimeout(L(this,Ja)),ye(this,Ja,void 0))},Qg=function(){L(this,eo)!==void 0&&(Ba.clearInterval(L(this,eo)),ye(this,eo,void 0))},Yg=function(){const t=L(this,wr).getQueryCache().build(L(this,wr),this.options);if(t===L(this,We))return;const r=L(this,We);ye(this,We,t),ye(this,Lu,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},bN=function(t){Wt.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(L(this,cr))}),L(this,wr).getQueryCache().notify({query:L(this,We),type:"observerResultsUpdated"})})},aN);function SM(e,t){return Ir(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&Ir(t.retryOnMount,e)===!1)}function lw(e,t){return SM(e,t)||e.state.data!==void 0&&Xg(e,t,t.refetchOnMount)}function Xg(e,t,r){if(Ir(t.enabled,e)!==!1&&ua(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&hy(e,t)}return!1}function uw(e,t,r,n){return(e!==t||Ir(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&hy(e,r)}function hy(e,t){return Ir(t.enabled,e)!==!1&&e.isStaleByTime(ua(t.staleTime,e))}function NM(e,t){return!zg(e.getCurrentResult(),t)}var zu,On,rr,to,_n,qi,oN,EM=(oN=class extends vN{constructor(t){super();Re(this,_n);Re(this,zu);Re(this,On);Re(this,rr);Re(this,to);ye(this,zu,t.client),this.mutationId=t.mutationId,ye(this,rr,t.mutationCache),ye(this,On,[]),this.state=t.state||AM(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){L(this,On).includes(t)||(L(this,On).push(t),this.clearGcTimeout(),L(this,rr).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){ye(this,On,L(this,On).filter(r=>r!==t)),this.scheduleGc(),L(this,rr).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){L(this,On).length||(this.state.status==="pending"?this.scheduleGc():L(this,rr).remove(this))}continue(){var t;return((t=L(this,to))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var u,c,f,h,m,g,v,b,j,k,S,N,E,A,P,_,O,D;const r=()=>{Ue(this,_n,qi).call(this,{type:"continue"})},n={client:L(this,zu),meta:this.options.meta,mutationKey:this.options.mutationKey};ye(this,to,gN({fn:()=>this.options.mutationFn?this.options.mutationFn(t,n):Promise.reject(new Error("No mutationFn found")),onFail:(B,F)=>{Ue(this,_n,qi).call(this,{type:"failed",failureCount:B,error:F})},onPause:()=>{Ue(this,_n,qi).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>L(this,rr).canRun(this)}));const a=this.state.status==="pending",o=!L(this,to).canStart();try{if(a)r();else{Ue(this,_n,qi).call(this,{type:"pending",variables:t,isPaused:o}),L(this,rr).config.onMutate&&await L(this,rr).config.onMutate(t,this,n);const F=await((c=(u=this.options).onMutate)==null?void 0:c.call(u,t,n));F!==this.state.context&&Ue(this,_n,qi).call(this,{type:"pending",context:F,variables:t,isPaused:o})}const B=await L(this,to).start();return await((h=(f=L(this,rr).config).onSuccess)==null?void 0:h.call(f,B,t,this.state.context,this,n)),await((g=(m=this.options).onSuccess)==null?void 0:g.call(m,B,t,this.state.context,n)),await((b=(v=L(this,rr).config).onSettled)==null?void 0:b.call(v,B,null,this.state.variables,this.state.context,this,n)),await((k=(j=this.options).onSettled)==null?void 0:k.call(j,B,null,t,this.state.context,n)),Ue(this,_n,qi).call(this,{type:"success",data:B}),B}catch(B){try{await((N=(S=L(this,rr).config).onError)==null?void 0:N.call(S,B,t,this.state.context,this,n))}catch(F){Promise.reject(F)}try{await((A=(E=this.options).onError)==null?void 0:A.call(E,B,t,this.state.context,n))}catch(F){Promise.reject(F)}try{await((_=(P=L(this,rr).config).onSettled)==null?void 0:_.call(P,void 0,B,this.state.variables,this.state.context,this,n))}catch(F){Promise.reject(F)}try{await((D=(O=this.options).onSettled)==null?void 0:D.call(O,void 0,B,t,this.state.context,n))}catch(F){Promise.reject(F)}throw Ue(this,_n,qi).call(this,{type:"error",error:B}),B}finally{L(this,rr).runNext(this)}}},zu=new WeakMap,On=new WeakMap,rr=new WeakMap,to=new WeakMap,_n=new WeakSet,qi=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Wt.batch(()=>{L(this,On).forEach(n=>{n.onMutationUpdate(t)}),L(this,rr).notify({mutation:this,type:"updated",action:t})})},oN);function AM(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var oi,dn,Fu,sN,CM=(sN=class extends Bu{constructor(t={}){super();Re(this,oi);Re(this,dn);Re(this,Fu);this.config=t,ye(this,oi,new Set),ye(this,dn,new Map),ye(this,Fu,0)}build(t,r,n){const a=new EM({client:t,mutationCache:this,mutationId:++md(this,Fu)._,options:t.defaultMutationOptions(r),state:n});return this.add(a),a}add(t){L(this,oi).add(t);const r=gd(t);if(typeof r=="string"){const n=L(this,dn).get(r);n?n.push(t):L(this,dn).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(L(this,oi).delete(t)){const r=gd(t);if(typeof r=="string"){const n=L(this,dn).get(r);if(n)if(n.length>1){const a=n.indexOf(t);a!==-1&&n.splice(a,1)}else n[0]===t&&L(this,dn).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=gd(t);if(typeof r=="string"){const n=L(this,dn).get(r),a=n==null?void 0:n.find(o=>o.state.status==="pending");return!a||a===t}else return!0}runNext(t){var n;const r=gd(t);if(typeof r=="string"){const a=(n=L(this,dn).get(r))==null?void 0:n.find(o=>o!==t&&o.state.isPaused);return(a==null?void 0:a.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Wt.batch(()=>{L(this,oi).forEach(t=>{this.notify({type:"removed",mutation:t})}),L(this,oi).clear(),L(this,dn).clear()})}getAll(){return Array.from(L(this,oi))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>rw(r,n))}findAll(t={}){return this.getAll().filter(r=>rw(t,r))}notify(t){Wt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Wt.batch(()=>Promise.all(t.map(r=>r.continue().catch(kr))))}},oi=new WeakMap,dn=new WeakMap,Fu=new WeakMap,sN);function gd(e){var t;return(t=e.options.scope)==null?void 0:t.id}var Mn,lN,PM=(lN=class extends Bu{constructor(t={}){super();Re(this,Mn);this.config=t,ye(this,Mn,new Map)}build(t,r,n){const a=r.queryKey,o=r.queryHash??dy(a,r);let u=this.get(o);return u||(u=new kM({client:t,queryKey:a,queryHash:o,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(a)}),this.add(u)),u}add(t){L(this,Mn).has(t.queryHash)||(L(this,Mn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=L(this,Mn).get(t.queryHash);r&&(t.destroy(),r===t&&L(this,Mn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Wt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return L(this,Mn).get(t)}getAll(){return[...L(this,Mn).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>tw(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>tw(t,n)):r}notify(t){Wt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Wt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Wt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Mn=new WeakMap,lN),mt,aa,oa,Es,As,sa,Cs,Ps,uN,OM=(uN=class{constructor(e={}){Re(this,mt);Re(this,aa);Re(this,oa);Re(this,Es);Re(this,As);Re(this,sa);Re(this,Cs);Re(this,Ps);ye(this,mt,e.queryCache||new PM),ye(this,aa,e.mutationCache||new CM),ye(this,oa,e.defaultOptions||{}),ye(this,Es,new Map),ye(this,As,new Map),ye(this,sa,0)}mount(){md(this,sa)._++,L(this,sa)===1&&(ye(this,Cs,cy.subscribe(async e=>{e&&(await this.resumePausedMutations(),L(this,mt).onFocus())})),ye(this,Ps,Yd.subscribe(async e=>{e&&(await this.resumePausedMutations(),L(this,mt).onOnline())})))}unmount(){var e,t;md(this,sa)._--,L(this,sa)===0&&((e=L(this,Cs))==null||e.call(this),ye(this,Cs,void 0),(t=L(this,Ps))==null||t.call(this),ye(this,Ps,void 0))}isFetching(e){return L(this,mt).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return L(this,aa).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=L(this,mt).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=L(this,mt).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(ua(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return L(this,mt).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),a=L(this,mt).get(n.queryHash),o=a==null?void 0:a.state.data,u=cM(t,o);if(u!==void 0)return L(this,mt).build(this,n).setData(u,{...r,manual:!0})}setQueriesData(e,t,r){return Wt.batch(()=>L(this,mt).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=L(this,mt).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=L(this,mt);Wt.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=L(this,mt);return Wt.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Wt.batch(()=>L(this,mt).findAll(e).map(a=>a.cancel(r)));return Promise.all(n).then(kr).catch(kr)}invalidateQueries(e,t={}){return Wt.batch(()=>(L(this,mt).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Wt.batch(()=>L(this,mt).findAll(e).filter(a=>!a.isDisabled()&&!a.isStatic()).map(a=>{let o=a.fetch(void 0,r);return r.throwOnError||(o=o.catch(kr)),a.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(n).then(kr)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=L(this,mt).build(this,t);return r.isStaleByTime(ua(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(kr).catch(kr)}fetchInfiniteQuery(e){return e._type="infinite",this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(kr).catch(kr)}ensureInfiniteQueryData(e){return e._type="infinite",this.ensureQueryData(e)}resumePausedMutations(){return Yd.isOnline()?L(this,aa).resumePausedMutations():Promise.resolve()}getQueryCache(){return L(this,mt)}getMutationCache(){return L(this,aa)}getDefaultOptions(){return L(this,oa)}setDefaultOptions(e){ye(this,oa,e)}setQueryDefaults(e,t){L(this,Es).set(mu(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...L(this,Es).values()],r={};return t.forEach(n=>{pu(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){L(this,As).set(mu(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...L(this,As).values()],r={};return t.forEach(n=>{pu(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...L(this,oa).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=dy(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===fy&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...L(this,oa).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){L(this,mt).clear(),L(this,aa).clear()}},mt=new WeakMap,aa=new WeakMap,oa=new WeakMap,Es=new WeakMap,As=new WeakMap,sa=new WeakMap,Cs=new WeakMap,Ps=new WeakMap,uN),wN=y.createContext(void 0),Kn=e=>{const t=y.useContext(wN);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},_M=({client:e,children:t})=>(y.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),l.jsx(wN.Provider,{value:e,children:t})),kN=y.createContext(!1),MM=()=>y.useContext(kN);kN.Provider;function IM(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var TM=y.createContext(IM()),DM=()=>y.useContext(TM),RM=(e,t,r)=>{const n=r!=null&&r.state.error&&typeof e.throwOnError=="function"?mN(e.throwOnError,[r.state.error,r]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||n)&&(t.isReset()||(e.retryOnMount=!1))},LM=e=>{y.useEffect(()=>{e.clearReset()},[e])},$M=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:a})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(a&&e.data===void 0||mN(r,[e.error,n])),zM=e=>{if(e.suspense){const r=a=>a==="static"?a:Math.max(a??1e3,1e3),n=e.staleTime;e.staleTime=typeof n=="function"?(...a)=>r(n(...a)):r(n),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},FM=(e,t)=>e.isLoading&&e.isFetching&&!t,BM=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,cw=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function UM(e,t,r){var b,j,k,S;const n=MM(),a=DM(),o=Kn(),u=o.defaultQueryOptions(e);(j=(b=o.getDefaultOptions().queries)==null?void 0:b._experimental_beforeQuery)==null||j.call(b,u);const c=o.getQueryCache().get(u.queryHash),f=e.subscribed!==!1;u._optimisticResults=n?"isRestoring":f?"optimistic":void 0,zM(u),RM(u,a,c),LM(a);const h=!o.getQueryCache().get(u.queryHash),[m]=y.useState(()=>new t(o,u)),g=m.getOptimisticResult(u),v=!n&&f;if(y.useSyncExternalStore(y.useCallback(N=>{const E=v?m.subscribe(Wt.batchCalls(N)):kr;return m.updateResult(),E},[m,v]),()=>m.getCurrentResult(),()=>m.getCurrentResult()),y.useEffect(()=>{m.setOptions(u)},[u,m]),BM(u,g))throw cw(u,m,a);if($M({result:g,errorResetBoundary:a,throwOnError:u.throwOnError,query:c,suspense:u.suspense}))throw g.error;if((S=(k=o.getDefaultOptions().queries)==null?void 0:k._experimental_afterQuery)==null||S.call(k,u,g),u.experimental_prefetchInRender&&!gu.isServer()&&FM(g,n)){const N=h?cw(u,m,a):c==null?void 0:c.promise;N==null||N.catch(kr).finally(()=>{m.updateResult()})}return u.notifyOnChangeProps?g:m.trackResult(g)}function Vt(e,t){return UM(e,jM)}/**
|
||
* @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 HM=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),jN=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).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 WM={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 KM=y.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:a="",children:o,iconNode:u,...c},f)=>y.createElement("svg",{ref:f,...WM,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:jN("lucide",a),...c},[...u.map(([h,m])=>y.createElement(h,m)),...Array.isArray(o)?o:[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 de=(e,t)=>{const r=y.forwardRef(({className:n,...a},o)=>y.createElement(KM,{ref:o,iconNode:t,className:jN(`lucide-${HM(e)}`,n),...a}));return r.displayName=`${e}`,r};/**
|
||
* @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 Zf=de("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 SN=de("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
|
||
* @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 Xd=de("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 GM=de("ArrowUpRight",[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]]);/**
|
||
* @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 NN=de("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 Zg=de("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);/**
|
||
* @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 VM=de("Bookmark",[["path",{d:"m19 21-7-4-7 4V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v16z",key:"1fy3hk"}]]);/**
|
||
* @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 pn=de("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 qM=de("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 Zd=de("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 QM=de("BrainCircuit",[["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:"M9 13a4.5 4.5 0 0 0 3-4",key:"10igwf"}],["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:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M12 13h4",key:"1ku699"}],["path",{d:"M12 18h6a2 2 0 0 1 2 2v1",key:"105ag5"}],["path",{d:"M12 8h8",key:"1lhi5i"}],["path",{d:"M16 8V5a2 2 0 0 1 2-2",key:"u6izg6"}],["circle",{cx:"16",cy:"13",r:".5",key:"ry7gng"}],["circle",{cx:"18",cy:"3",r:".5",key:"1aiba7"}],["circle",{cx:"20",cy:"21",r:".5",key:"yhc1fs"}],["circle",{cx:"20",cy:"8",r:".5",key:"1e43v0"}]]);/**
|
||
* @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 YM=de("BrainCog",[["path",{d:"M12 5a3 3 0 1 0-5.997.142 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588 4 4 0 0 0 7.636 2.106 3.2 3.2 0 0 0 .164-.546c.028-.13.306-.13.335 0a3.2 3.2 0 0 0 .163.546 4 4 0 0 0 7.636-2.106 4 4 0 0 0 .556-6.588 4 4 0 0 0-2.526-5.77A3 3 0 1 0 12 5",key:"1kgmhc"}],["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"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["path",{d:"m15.7 10.4-.9.4",key:"ayzo6p"}],["path",{d:"m9.2 13.2-.9.4",key:"1uzb3g"}],["path",{d:"m13.6 15.7-.4-.9",key:"11ifqf"}],["path",{d:"m10.8 9.2-.4-.9",key:"1pmk2v"}],["path",{d:"m15.7 13.5-.9-.4",key:"7ng02m"}],["path",{d:"m9.2 10.9-.9-.4",key:"1x66zd"}],["path",{d:"m10.5 15.7.4-.9",key:"3js94g"}],["path",{d:"m13.1 9.2.4-.9",key:"18n7mc"}]]);/**
|
||
* @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 vo=de("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 XM=de("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 or=de("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 EN=de("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
|
||
* @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 ZM=de("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 Jf=de("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 AN=de("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
|
||
* @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 JM=de("CircleArrowUp",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16 12-4-4-4 4",key:"177agl"}],["path",{d:"M12 16V8",key:"1sbj14"}]]);/**
|
||
* @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 CN=de("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 e4=de("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 t4=de("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
|
||
* @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 PN=de("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 r4=de("CodeXml",[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]]);/**
|
||
* @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 Os=de("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);/**
|
||
* @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 n4=de("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 Jg=de("Compass",[["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
|
||
* @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 i4=de("Construction",[["rect",{x:"2",y:"6",width:"20",height:"8",rx:"1",key:"1estib"}],["path",{d:"M17 14v7",key:"7m2elx"}],["path",{d:"M7 14v7",key:"1cm7wv"}],["path",{d:"M17 3v3",key:"1v4jwn"}],["path",{d:"M7 3v3",key:"7o6guu"}],["path",{d:"M10 14 2.3 6.3",key:"1023jk"}],["path",{d:"m14 6 7.7 7.7",key:"1s8pl2"}],["path",{d:"m8 6 8 8",key:"hl96qh"}]]);/**
|
||
* @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 ev=de("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
|
||
* @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 $n=de("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 a4=de("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/**
|
||
* @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 _s=de("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/**
|
||
* @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 Ms=de("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 dw=de("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 vu=de("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 o4=de("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 s4=de("Flame",[["path",{d:"M8.5 14.5A2.5 2.5 0 0 0 11 12c0-1.38-.5-2-1-3-1.072-2.143-.224-4.054 2-6 .5 2.5 2 4.9 4 6.5 2 1.6 3 3.5 3 5.5a7 7 0 1 1-14 0c0-1.153.433-2.294 1-3a2.5 2.5 0 0 0 2.5 2.5z",key:"96xj49"}]]);/**
|
||
* @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 l4=de("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/**
|
||
* @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 u4=de("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 c4=de("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 d4=de("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);/**
|
||
* @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 cu=de("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 f4=de("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 h4=de("Heart",[["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"}]]);/**
|
||
* @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 fw=de("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
|
||
* @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 m4=de("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 p4=de("Laptop",[["path",{d:"M20 16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v9m16 0H4m16 0 1.28 2.55a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45L4 16",key:"tarvll"}]]);/**
|
||
* @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=de("Layers",[["path",{d:"m12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83Z",key:"8b97xw"}],["path",{d:"m22 17.65-9.17 4.16a2 2 0 0 1-1.66 0L2 17.65",key:"dd6zsq"}],["path",{d:"m22 12.65-9.17 4.16a2 2 0 0 1-1.66 0L2 12.65",key:"ep9fru"}]]);/**
|
||
* @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 g4=de("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 v4=de("LifeBuoy",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m4.93 4.93 4.24 4.24",key:"1ymg45"}],["path",{d:"m14.83 9.17 4.24-4.24",key:"1cb5xl"}],["path",{d:"m14.83 14.83 4.24 4.24",key:"q42g0n"}],["path",{d:"m9.17 14.83-4.24 4.24",key:"bqpfvv"}],["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}]]);/**
|
||
* @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 y4=de("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 x4=de("List",[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]]);/**
|
||
* @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 eh=de("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 b4=de("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
|
||
* @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 w4=de("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
|
||
* @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 k4=de("MessagesSquare",[["path",{d:"M14 9a2 2 0 0 1-2 2H6l-4 4V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2z",key:"p1xzt8"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v11l-4-4h-6a2 2 0 0 1-2-2v-1",key:"1cx29u"}]]);/**
|
||
* @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 j4=de("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 hw=de("Monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);/**
|
||
* @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 S4=de("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
|
||
* @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 N4=de("Network",[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]]);/**
|
||
* @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 mw=de("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 E4=de("PenLine",[["path",{d:"M12 20h9",key:"t2du7b"}],["path",{d:"M16.376 3.622a1 1 0 0 1 3.002 3.002L7.368 18.635a2 2 0 0 1-.855.506l-2.872.838a.5.5 0 0 1-.62-.62l.838-2.872a2 2 0 0 1 .506-.854z",key:"1ykcvy"}]]);/**
|
||
* @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 Jd=de("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 ef=de("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
|
||
* @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 A4=de("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 C4=de("Puzzle",[["path",{d:"M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",key:"w46dr5"}]]);/**
|
||
* @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 ro=de("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 P4=de("RotateCcw",[["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"}]]);/**
|
||
* @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 O4=de("Scroll",[["path",{d:"M19 17V5a2 2 0 0 0-2-2H4",key:"zz82l3"}],["path",{d:"M8 21h12a2 2 0 0 0 2-2v-1a1 1 0 0 0-1-1H11a1 1 0 0 0-1 1v1a2 2 0 1 1-4 0V5a2 2 0 1 0-4 0v2a1 1 0 0 0 1 1h3",key:"1ph1d7"}]]);/**
|
||
* @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=de("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 _4=de("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/**
|
||
* @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 th=de("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 M4=de("Share2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]);/**
|
||
* @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 I4=de("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 ON=de("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 T4=de("ShieldQuestion",[["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.1 9a3 3 0 0 1 5.82 1c0 2-3 3-3 3",key:"mhlwft"}],["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 Ks=de("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 _N=de("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 D4=de("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 R4=de("SlidersVertical",[["line",{x1:"4",x2:"4",y1:"21",y2:"14",key:"1p332r"}],["line",{x1:"4",x2:"4",y1:"10",y2:"3",key:"gb41h5"}],["line",{x1:"12",x2:"12",y1:"21",y2:"12",key:"hf2csr"}],["line",{x1:"12",x2:"12",y1:"8",y2:"3",key:"1kfi7u"}],["line",{x1:"20",x2:"20",y1:"21",y2:"16",key:"1lhrwl"}],["line",{x1:"20",x2:"20",y1:"12",y2:"3",key:"16vvfq"}],["line",{x1:"2",x2:"6",y1:"14",y2:"14",key:"1uebub"}],["line",{x1:"10",x2:"14",y1:"8",y2:"8",key:"1yglbp"}],["line",{x1:"18",x2:"22",y1:"16",y2:"16",key:"1jxqpz"}]]);/**
|
||
* @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 us=de("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 MN=de("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 L4=de("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]);/**
|
||
* @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 $4=de("Telescope",[["path",{d:"m10.065 12.493-6.18 1.318a.934.934 0 0 1-1.108-.702l-.537-2.15a1.07 1.07 0 0 1 .691-1.265l13.504-4.44",key:"k4qptu"}],["path",{d:"m13.56 11.747 4.332-.924",key:"19l80z"}],["path",{d:"m16 21-3.105-6.21",key:"7oh9d"}],["path",{d:"M16.485 5.94a2 2 0 0 1 1.455-2.425l1.09-.272a1 1 0 0 1 1.212.727l1.515 6.06a1 1 0 0 1-.727 1.213l-1.09.272a2 2 0 0 1-2.425-1.455z",key:"m7xp4m"}],["path",{d:"m6.158 8.633 1.114 4.456",key:"74o979"}],["path",{d:"m8 21 3.105-6.21",key:"1fvxut"}],["circle",{cx:"12",cy:"13",r:"2",key:"1c1ljs"}]]);/**
|
||
* @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 IN=de("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 tv=de("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
|
||
* @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 gn=de("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 z4=de("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
|
||
* @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 Uu=de("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 zn=de("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
|
||
* @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 ha=de("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),ou=[{id:"dashboard",label:"Zentrale",hint:"System- & Stack-Status",icon:g4},{id:"models",label:"Modell-Manager",hint:"Verwalten, laden & Gateway-Routing",icon:Zd},{id:"memory",label:"Gedächtnis",hint:"Geteiltes Memory verwalten",icon:vo},{id:"connect",label:"Verbinden",hint:"IDE-/Agent-Configs erzeugen",icon:Jd},{id:"agent",label:"Hermes",hint:"Agent-Status & Verdrahtung",icon:pn},{id:"terminal",label:"Terminal",hint:"Interaktives Hermes-Agent-Terminal",icon:MN},{id:"guide",label:"Anleitung",hint:"Einrichten & Vibe-Coding",icon:e4}];var pw=1,F4=.9,B4=.8,U4=.17,Gp=.1,Vp=.999,H4=.9999,W4=.99,K4=/[\\\/_+.#"@\[\(\{&]/,G4=/[\\\/_+.#"@\[\(\{&]/g,V4=/[\s-]/,TN=/[\s-]/g;function rv(e,t,r,n,a,o,u){if(o===t.length)return a===e.length?pw:W4;var c=`${a},${o}`;if(u[c]!==void 0)return u[c];for(var f=n.charAt(o),h=r.indexOf(f,a),m=0,g,v,b,j;h>=0;)g=rv(e,t,r,n,h+1,o+1,u),g>m&&(h===a?g*=pw:K4.test(e.charAt(h-1))?(g*=B4,b=e.slice(a,h-1).match(G4),b&&a>0&&(g*=Math.pow(Vp,b.length))):V4.test(e.charAt(h-1))?(g*=F4,j=e.slice(a,h-1).match(TN),j&&a>0&&(g*=Math.pow(Vp,j.length))):(g*=U4,a>0&&(g*=Math.pow(Vp,h-a))),e.charAt(h)!==t.charAt(o)&&(g*=H4)),(g<Gp&&r.charAt(h-1)===n.charAt(o+1)||n.charAt(o+1)===n.charAt(o)&&r.charAt(h-1)!==n.charAt(o))&&(v=rv(e,t,r,n,h+1,o+2,u),v*Gp>g&&(g=v*Gp)),g>m&&(m=g),h=r.indexOf(f,h+1);return u[c]=m,m}function gw(e){return e.toLowerCase().replace(TN," ")}function q4(e,t,r){return e=r&&r.length>0?`${e+" "+r.join(" ")}`:e,rv(e,t,gw(e),gw(t),0,0,{})}function ca(e,t,{checkForDefaultPrevented:r=!0}={}){return function(a){if(e==null||e(a),r===!1||!a.defaultPrevented)return t==null?void 0:t(a)}}function vw(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Is(...e){return t=>{let r=!1;const n=e.map(a=>{const o=vw(a,t);return!r&&typeof o=="function"&&(r=!0),o});if(r)return()=>{for(let a=0;a<n.length;a++){const o=n[a];typeof o=="function"?o():vw(e[a],null)}}}}function yo(...e){return y.useCallback(Is(...e),e)}function Q4(e,t=[]){let r=[];function n(o,u){const c=y.createContext(u);c.displayName=o+"Context";const f=r.length;r=[...r,u];const h=g=>{var N;const{scope:v,children:b,...j}=g,k=((N=v==null?void 0:v[e])==null?void 0:N[f])||c,S=y.useMemo(()=>j,Object.values(j));return l.jsx(k.Provider,{value:S,children:b})};h.displayName=o+"Provider";function m(g,v){var k;const b=((k=v==null?void 0:v[e])==null?void 0:k[f])||c,j=y.useContext(b);if(j)return j;if(u!==void 0)return u;throw new Error(`\`${g}\` must be used within \`${o}\``)}return[h,m]}const a=()=>{const o=r.map(u=>y.createContext(u));return function(c){const f=(c==null?void 0:c[e])||o;return y.useMemo(()=>({[`__scope${e}`]:{...c,[e]:f}}),[c,f])}};return a.scopeName=e,[n,Y4(a,...t)]}function Y4(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(a=>({useScope:a(),scopeName:a.scopeName}));return function(o){const u=n.reduce((c,{useScope:f,scopeName:h})=>{const g=f(o)[`__scope${h}`];return{...c,...g}},{});return y.useMemo(()=>({[`__scope${t.scopeName}`]:u}),[u])}};return r.scopeName=t.scopeName,r}var yu=globalThis!=null&&globalThis.document?y.useLayoutEffect:()=>{},X4=Xf[" useId ".trim().toString()]||(()=>{}),Z4=0;function di(e){const[t,r]=y.useState(X4());return yu(()=>{r(n=>n??String(Z4++))},[e]),t?`radix-${t}`:""}var J4=Xf[" useInsertionEffect ".trim().toString()]||yu;function eI({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[a,o,u]=tI({defaultProp:t,onChange:r}),c=e!==void 0,f=c?e:a;{const m=y.useRef(e!==void 0);y.useEffect(()=>{const g=m.current;g!==c&&console.warn(`${n} is changing from ${g?"controlled":"uncontrolled"} to ${c?"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.`),m.current=c},[c,n])}const h=y.useCallback(m=>{var g;if(c){const v=rI(m)?m(e):m;v!==e&&((g=u.current)==null||g.call(u,v))}else o(m)},[c,e,o,u]);return[f,h]}function tI({defaultProp:e,onChange:t}){const[r,n]=y.useState(e),a=y.useRef(r),o=y.useRef(t);return J4(()=>{o.current=t},[t]),y.useEffect(()=>{var u;a.current!==r&&((u=o.current)==null||u.call(o,r),a.current=r)},[r,a]),[r,n,o]}function rI(e){return typeof e=="function"}var rh=cN();function DN(e){const t=y.forwardRef((r,n)=>{let{children:a,...o}=r,u=null,c=!1;const f=[];yw(a)&&typeof vd=="function"&&(a=vd(a._payload)),y.Children.forEach(a,v=>{var b;if(sI(v)){c=!0;const j=v;let k="child"in j.props?j.props.child:j.props.children;yw(k)&&typeof vd=="function"&&(k=vd(k._payload)),u=iI(j,k),f.push((b=u==null?void 0:u.props)==null?void 0:b.children)}else f.push(v)}),u?u=y.cloneElement(u,void 0,f):!c&&y.Children.count(a)===1&&y.isValidElement(a)&&(u=a);const h=u?oI(u):void 0,m=yo(n,h);if(!u){if(a||a===0)throw new Error(c?dI(e):cI(e));return a}const g=aI(o,u.props??{});return u.type!==y.Fragment&&(g.ref=n?m:h),y.cloneElement(u,g)});return t.displayName=`${e}.Slot`,t}var nI=Symbol.for("radix.slottable"),iI=(e,t)=>{if("child"in e.props){const r=e.props.child;return y.isValidElement(r)?y.cloneElement(r,void 0,e.props.children(r.props.children)):null}return y.isValidElement(t)?t:null};function aI(e,t){const r={...t};for(const n in t){const a=e[n],o=t[n];/^on[A-Z]/.test(n)?a&&o?r[n]=(...c)=>{const f=o(...c);return a(...c),f}:a&&(r[n]=a):n==="style"?r[n]={...a,...o}:n==="className"&&(r[n]=[a,o].filter(Boolean).join(" "))}return{...e,...r}}function oI(e){var n,a;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(a=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:a.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function sI(e){return y.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===nI}var lI=Symbol.for("react.lazy");function yw(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===lI&&"_payload"in e&&uI(e._payload)}function uI(e){return typeof e=="object"&&e!==null&&"then"in e}var cI=e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,dI=e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,vd=Xf[" use ".trim().toString()],fI=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],qt=fI.reduce((e,t)=>{const r=DN(`Primitive.${t}`),n=y.forwardRef((a,o)=>{const{asChild:u,...c}=a,f=u?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),l.jsx(f,{...c,ref:o})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function hI(e,t){e&&rh.flushSync(()=>e.dispatchEvent(t))}function xu(e){const t=y.useRef(e);return y.useEffect(()=>{t.current=e}),y.useMemo(()=>((...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)}),[])}function mI(e,t=globalThis==null?void 0:globalThis.document){const r=xu(e);y.useEffect(()=>{const n=a=>{a.key==="Escape"&&r(a)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var pI="DismissableLayer",nv="dismissableLayer.update",gI="dismissableLayer.pointerDownOutside",vI="dismissableLayer.focusOutside",xw,gy=y.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),RN=y.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,deferPointerDownOutside:n=!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:u,onInteractOutside:c,onDismiss:f,...h}=e,m=y.useContext(gy),[g,v]=y.useState(null),b=(g==null?void 0:g.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,j]=y.useState({}),k=yo(t,F=>v(F)),S=Array.from(m.layers),[N]=[...m.layersWithOutsidePointerEventsDisabled].slice(-1),E=S.indexOf(N),A=g?S.indexOf(g):-1,P=m.layersWithOutsidePointerEventsDisabled.size>0,_=A>=E,O=y.useRef(!1),D=wI(F=>{const z=F.target;if(!(z instanceof Node))return;const Y=[...m.branches].some(U=>U.contains(z));!_||Y||(o==null||o(F),c==null||c(F),F.defaultPrevented||f==null||f())},{ownerDocument:b,deferPointerDownOutside:n,isDeferredPointerDownOutsideRef:O,dismissableSurfaces:m.dismissableSurfaces}),B=kI(F=>{if(n&&O.current)return;const z=F.target;[...m.branches].some(U=>U.contains(z))||(u==null||u(F),c==null||c(F),F.defaultPrevented||f==null||f())},b);return mI(F=>{A===m.layers.size-1&&(a==null||a(F),!F.defaultPrevented&&f&&(F.preventDefault(),f()))},b),y.useEffect(()=>{if(g)return r&&(m.layersWithOutsidePointerEventsDisabled.size===0&&(xw=b.body.style.pointerEvents,b.body.style.pointerEvents="none"),m.layersWithOutsidePointerEventsDisabled.add(g)),m.layers.add(g),bw(),()=>{r&&(m.layersWithOutsidePointerEventsDisabled.delete(g),m.layersWithOutsidePointerEventsDisabled.size===0&&(b.body.style.pointerEvents=xw))}},[g,b,r,m]),y.useEffect(()=>()=>{g&&(m.layers.delete(g),m.layersWithOutsidePointerEventsDisabled.delete(g),bw())},[g,m]),y.useEffect(()=>{const F=()=>j({});return document.addEventListener(nv,F),()=>document.removeEventListener(nv,F)},[]),l.jsx(qt.div,{...h,ref:k,style:{pointerEvents:P?_?"auto":"none":void 0,...e.style},onFocusCapture:ca(e.onFocusCapture,B.onFocusCapture),onBlurCapture:ca(e.onBlurCapture,B.onBlurCapture),onPointerDownCapture:ca(e.onPointerDownCapture,D.onPointerDownCapture)})});RN.displayName=pI;var yI="DismissableLayerBranch",xI=y.forwardRef((e,t)=>{const r=y.useContext(gy),n=y.useRef(null),a=yo(t,n);return y.useEffect(()=>{const o=n.current;if(o)return r.branches.add(o),()=>{r.branches.delete(o)}},[r.branches]),l.jsx(qt.div,{...e,ref:a})});xI.displayName=yI;function bI(){const e=y.useContext(gy),[t,r]=y.useState(null);return y.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),r}function wI(e,t){const{ownerDocument:r=globalThis==null?void 0:globalThis.document,deferPointerDownOutside:n=!1,isDeferredPointerDownOutsideRef:a,dismissableSurfaces:o}=t,u=xu(e),c=y.useRef(!1),f=y.useRef(!1),h=y.useRef(new Map),m=y.useRef(()=>{});return y.useEffect(()=>{function g(){f.current=!1,a.current=!1,h.current.clear()}function v(){return Array.from(h.current.values()).some(Boolean)}function b(E){if(!f.current)return;const A=E.target;A instanceof Node&&[...o].some(_=>_.contains(A))||h.current.set(E.type,!0),E.type==="click"&&window.setTimeout(()=>{f.current&&m.current()},0)}function j(E){f.current&&h.current.set(E.type,!1)}const k=E=>{if(E.target&&!c.current){let A=function(){r.removeEventListener("click",m.current);const _=v();g(),_||LN(gI,u,P,{discrete:!0})};const P={originalEvent:E};f.current=!0,a.current=n&&E.button===0,h.current.clear(),!n||E.button!==0?A():(r.removeEventListener("click",m.current),m.current=A,r.addEventListener("click",m.current,{once:!0}))}else r.removeEventListener("click",m.current),g();c.current=!1},S=["pointerup","mousedown","mouseup","touchstart","touchend","click"];for(const E of S)r.addEventListener(E,b,!0),r.addEventListener(E,j);const N=window.setTimeout(()=>{r.addEventListener("pointerdown",k)},0);return()=>{window.clearTimeout(N),r.removeEventListener("pointerdown",k),r.removeEventListener("click",m.current);for(const E of S)r.removeEventListener(E,b,!0),r.removeEventListener(E,j)}},[r,u,n,a,o]),{onPointerDownCapture:()=>c.current=!0}}function kI(e,t=globalThis==null?void 0:globalThis.document){const r=xu(e),n=y.useRef(!1);return y.useEffect(()=>{const a=o=>{o.target&&!n.current&&LN(vI,r,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",a),()=>t.removeEventListener("focusin",a)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function bw(){const e=new CustomEvent(nv);document.dispatchEvent(e)}function LN(e,t,r,{discrete:n}){const a=r.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&a.addEventListener(e,t,{once:!0}),n?hI(a,o):a.dispatchEvent(o)}var qp="focusScope.autoFocusOnMount",Qp="focusScope.autoFocusOnUnmount",ww={bubbles:!1,cancelable:!0},jI="FocusScope",$N=y.forwardRef((e,t)=>{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:a,onUnmountAutoFocus:o,...u}=e,[c,f]=y.useState(null),h=xu(a),m=xu(o),g=y.useRef(null),v=yo(t,k=>f(k)),b=y.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;y.useEffect(()=>{if(n){let k=function(A){if(b.paused||!c)return;const P=A.target;c.contains(P)?g.current=P:Qi(g.current,{select:!0})},S=function(A){if(b.paused||!c)return;const P=A.relatedTarget;P!==null&&(c.contains(P)||Qi(g.current,{select:!0}))},N=function(A){if(document.activeElement===document.body)for(const _ of A)_.removedNodes.length>0&&Qi(c)};document.addEventListener("focusin",k),document.addEventListener("focusout",S);const E=new MutationObserver(N);return c&&E.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",k),document.removeEventListener("focusout",S),E.disconnect()}}},[n,c,b.paused]),y.useEffect(()=>{if(c){jw.add(b);const k=document.activeElement;if(!c.contains(k)){const N=new CustomEvent(qp,ww);c.addEventListener(qp,h),c.dispatchEvent(N),N.defaultPrevented||(SI(PI(zN(c)),{select:!0}),document.activeElement===k&&Qi(c))}return()=>{c.removeEventListener(qp,h),setTimeout(()=>{const N=new CustomEvent(Qp,ww);c.addEventListener(Qp,m),c.dispatchEvent(N),N.defaultPrevented||Qi(k??document.body,{select:!0}),c.removeEventListener(Qp,m),jw.remove(b)},0)}}},[c,h,m,b]);const j=y.useCallback(k=>{if(!r&&!n||b.paused)return;const S=k.key==="Tab"&&!k.altKey&&!k.ctrlKey&&!k.metaKey,N=document.activeElement;if(S&&N){const E=k.currentTarget,[A,P]=NI(E);A&&P?!k.shiftKey&&N===P?(k.preventDefault(),r&&Qi(A,{select:!0})):k.shiftKey&&N===A&&(k.preventDefault(),r&&Qi(P,{select:!0})):N===E&&k.preventDefault()}},[r,n,b.paused]);return l.jsx(qt.div,{tabIndex:-1,...u,ref:v,onKeyDown:j})});$N.displayName=jI;function SI(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(Qi(n,{select:t}),document.activeElement!==r)return}function NI(e){const t=zN(e),r=kw(t,e),n=kw(t.reverse(),e);return[r,n]}function zN(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const a=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||a?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function kw(e,t){for(const r of e)if(!EI(r,{upTo:t}))return r}function EI(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function AI(e){return e instanceof HTMLInputElement&&"select"in e}function Qi(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&AI(e)&&t&&e.select()}}var jw=CI();function CI(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=Sw(e,t),e.unshift(t)},remove(t){var r;e=Sw(e,t),(r=e[0])==null||r.resume()}}}function Sw(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function PI(e){return e.filter(t=>t.tagName!=="A")}var OI="Portal",FN=y.forwardRef((e,t)=>{var c;const{container:r,...n}=e,[a,o]=y.useState(!1);yu(()=>o(!0),[]);const u=r||a&&((c=globalThis==null?void 0:globalThis.document)==null?void 0:c.body);return u?rh.createPortal(l.jsx(qt.div,{...n,ref:t}),u):null});FN.displayName=OI;function _I(e,t){return y.useReducer((r,n)=>t[r][n]??r,e)}var nh=e=>{const{present:t,children:r}=e,n=MI(t),a=typeof r=="function"?r({present:n.isPresent}):y.Children.only(r),o=II(n.ref,TI(a));return typeof r=="function"||n.isPresent?y.cloneElement(a,{ref:o}):null};nh.displayName="Presence";function MI(e){const[t,r]=y.useState(),n=y.useRef(null),a=y.useRef(e),o=y.useRef("none"),u=e?"mounted":"unmounted",[c,f]=_I(u,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return y.useEffect(()=>{const h=yd(n.current);o.current=c==="mounted"?h:"none"},[c]),yu(()=>{const h=n.current,m=a.current;if(m!==e){const v=o.current,b=yd(h);e?f("MOUNT"):b==="none"||(h==null?void 0:h.display)==="none"?f("UNMOUNT"):f(m&&v!==b?"ANIMATION_OUT":"UNMOUNT"),a.current=e}},[e,f]),yu(()=>{if(t){let h;const m=t.ownerDocument.defaultView??window,g=b=>{const k=yd(n.current).includes(CSS.escape(b.animationName));if(b.target===t&&k&&(f("ANIMATION_END"),!a.current)){const S=t.style.animationFillMode;t.style.animationFillMode="forwards",h=m.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=S)})}},v=b=>{b.target===t&&(o.current=yd(n.current))};return t.addEventListener("animationstart",v),t.addEventListener("animationcancel",g),t.addEventListener("animationend",g),()=>{m.clearTimeout(h),t.removeEventListener("animationstart",v),t.removeEventListener("animationcancel",g),t.removeEventListener("animationend",g)}}else f("ANIMATION_END")},[t,f]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:y.useCallback(h=>{n.current=h?getComputedStyle(h):null,r(h)},[])}}function Nw(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function II(...e){const t=y.useRef(e);return t.current=e,y.useCallback(r=>{const n=t.current;let a=!1;const o=n.map(u=>{const c=Nw(u,r);return!a&&typeof c=="function"&&(a=!0),c});if(a)return()=>{for(let u=0;u<o.length;u++){const c=o[u];typeof c=="function"?c():Nw(n[u],null)}}},[])}function yd(e){return(e==null?void 0:e.animationName)||"none"}function TI(e){var n,a;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(a=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:a.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var xd=0,En=null;function DI(){y.useEffect(()=>{En||(En={start:Ew(),end:Ew()});const{start:e,end:t}=En;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement("afterbegin",e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement("beforeend",t),xd++,()=>{xd===1&&(En==null||En.start.remove(),En==null||En.end.remove(),En=null),xd=Math.max(0,xd-1)}},[])}function Ew(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var In=function(){return In=Object.assign||function(t){for(var r,n=1,a=arguments.length;n<a;n++){r=arguments[n];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o])}return t},In.apply(this,arguments)};function BN(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(e);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(e,n[a])&&(r[n[a]]=e[n[a]]);return r}function RI(e,t,r){if(r||arguments.length===2)for(var n=0,a=t.length,o;n<a;n++)(o||!(n in t))&&(o||(o=Array.prototype.slice.call(t,0,n)),o[n]=t[n]);return e.concat(o||Array.prototype.slice.call(t))}var Bd="right-scroll-bar-position",Ud="width-before-scroll-bar",LI="with-scroll-bars-hidden",$I="--removed-body-scroll-bar-size";function Yp(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function zI(e,t){var r=y.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var a=r.value;a!==n&&(r.value=n,r.callback(n,a))}}}})[0];return r.callback=t,r.facade}var FI=typeof window<"u"?y.useLayoutEffect:y.useEffect,Aw=new WeakMap;function BI(e,t){var r=zI(null,function(n){return e.forEach(function(a){return Yp(a,n)})});return FI(function(){var n=Aw.get(r);if(n){var a=new Set(n),o=new Set(e),u=r.current;a.forEach(function(c){o.has(c)||Yp(c,null)}),o.forEach(function(c){a.has(c)||Yp(c,u)})}Aw.set(r,e)},[e]),r}function UI(e){return e}function HI(e,t){t===void 0&&(t=UI);var r=[],n=!1,a={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(o){var u=t(o,n);return r.push(u),function(){r=r.filter(function(c){return c!==u})}},assignSyncMedium:function(o){for(n=!0;r.length;){var u=r;r=[],u.forEach(o)}r={push:function(c){return o(c)},filter:function(){return r}}},assignMedium:function(o){n=!0;var u=[];if(r.length){var c=r;r=[],c.forEach(o),u=r}var f=function(){var m=u;u=[],m.forEach(o)},h=function(){return Promise.resolve().then(f)};h(),r={push:function(m){u.push(m),h()},filter:function(m){return u=u.filter(m),r}}}};return a}function WI(e){e===void 0&&(e={});var t=HI(null);return t.options=In({async:!0,ssr:!1},e),t}var UN=function(e){var t=e.sideCar,r=BN(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return y.createElement(n,In({},r))};UN.isSideCarExport=!0;function KI(e,t){return e.useMedium(t),UN}var HN=WI(),Xp=function(){},ih=y.forwardRef(function(e,t){var r=y.useRef(null),n=y.useState({onScrollCapture:Xp,onWheelCapture:Xp,onTouchMoveCapture:Xp}),a=n[0],o=n[1],u=e.forwardProps,c=e.children,f=e.className,h=e.removeScrollBar,m=e.enabled,g=e.shards,v=e.sideCar,b=e.noRelative,j=e.noIsolation,k=e.inert,S=e.allowPinchZoom,N=e.as,E=N===void 0?"div":N,A=e.gapMode,P=BN(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),_=v,O=BI([r,t]),D=In(In({},P),a);return y.createElement(y.Fragment,null,m&&y.createElement(_,{sideCar:HN,removeScrollBar:h,shards:g,noRelative:b,noIsolation:j,inert:k,setCallbacks:o,allowPinchZoom:!!S,lockRef:r,gapMode:A}),u?y.cloneElement(y.Children.only(c),In(In({},D),{ref:O})):y.createElement(E,In({},D,{className:f,ref:O}),c))});ih.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};ih.classNames={fullWidth:Ud,zeroRight:Bd};var GI=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function VI(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=GI();return t&&e.setAttribute("nonce",t),e}function qI(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function QI(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var YI=function(){var e=0,t=null;return{add:function(r){e==0&&(t=VI())&&(qI(t,r),QI(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},XI=function(){var e=YI();return function(t,r){y.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},WN=function(){var e=XI(),t=function(r){var n=r.styles,a=r.dynamic;return e(n,a),null};return t},ZI={left:0,top:0,right:0,gap:0},Zp=function(e){return parseInt(e||"",10)||0},JI=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],a=t[e==="padding"?"paddingRight":"marginRight"];return[Zp(r),Zp(n),Zp(a)]},eT=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return ZI;var t=JI(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},tT=WN(),fs="data-scroll-locked",rT=function(e,t,r,n){var a=e.left,o=e.top,u=e.right,c=e.gap;return r===void 0&&(r="margin"),`
|
||
.`.concat(LI,` {
|
||
overflow: hidden `).concat(n,`;
|
||
padding-right: `).concat(c,"px ").concat(n,`;
|
||
}
|
||
body[`).concat(fs,`] {
|
||
overflow: hidden `).concat(n,`;
|
||
overscroll-behavior: contain;
|
||
`).concat([t&&"position: relative ".concat(n,";"),r==="margin"&&`
|
||
padding-left: `.concat(a,`px;
|
||
padding-top: `).concat(o,`px;
|
||
padding-right: `).concat(u,`px;
|
||
margin-left:0;
|
||
margin-top:0;
|
||
margin-right: `).concat(c,"px ").concat(n,`;
|
||
`),r==="padding"&&"padding-right: ".concat(c,"px ").concat(n,";")].filter(Boolean).join(""),`
|
||
}
|
||
|
||
.`).concat(Bd,` {
|
||
right: `).concat(c,"px ").concat(n,`;
|
||
}
|
||
|
||
.`).concat(Ud,` {
|
||
margin-right: `).concat(c,"px ").concat(n,`;
|
||
}
|
||
|
||
.`).concat(Bd," .").concat(Bd,` {
|
||
right: 0 `).concat(n,`;
|
||
}
|
||
|
||
.`).concat(Ud," .").concat(Ud,` {
|
||
margin-right: 0 `).concat(n,`;
|
||
}
|
||
|
||
body[`).concat(fs,`] {
|
||
`).concat($I,": ").concat(c,`px;
|
||
}
|
||
`)},Cw=function(){var e=parseInt(document.body.getAttribute(fs)||"0",10);return isFinite(e)?e:0},nT=function(){y.useEffect(function(){return document.body.setAttribute(fs,(Cw()+1).toString()),function(){var e=Cw()-1;e<=0?document.body.removeAttribute(fs):document.body.setAttribute(fs,e.toString())}},[])},iT=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,a=n===void 0?"margin":n;nT();var o=y.useMemo(function(){return eT(a)},[a]);return y.createElement(tT,{styles:rT(o,!t,a,r?"":"!important")})},iv=!1;if(typeof window<"u")try{var bd=Object.defineProperty({},"passive",{get:function(){return iv=!0,!0}});window.addEventListener("test",bd,bd),window.removeEventListener("test",bd,bd)}catch{iv=!1}var Qo=iv?{passive:!1}:!1,aT=function(e){return e.tagName==="TEXTAREA"},KN=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!aT(e)&&r[t]==="visible")},oT=function(e){return KN(e,"overflowY")},sT=function(e){return KN(e,"overflowX")},Pw=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var a=GN(e,n);if(a){var o=VN(e,n),u=o[1],c=o[2];if(u>c)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},lT=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},uT=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},GN=function(e,t){return e==="v"?oT(t):sT(t)},VN=function(e,t){return e==="v"?lT(t):uT(t)},cT=function(e,t){return e==="h"&&t==="rtl"?-1:1},dT=function(e,t,r,n,a){var o=cT(e,window.getComputedStyle(t).direction),u=o*n,c=r.target,f=t.contains(c),h=!1,m=u>0,g=0,v=0;do{if(!c)break;var b=VN(e,c),j=b[0],k=b[1],S=b[2],N=k-S-o*j;(j||N)&&GN(e,c)&&(g+=N,v+=j);var E=c.parentNode;c=E&&E.nodeType===Node.DOCUMENT_FRAGMENT_NODE?E.host:E}while(!f&&c!==document.body||f&&(t.contains(c)||t===c));return(m&&Math.abs(g)<1||!m&&Math.abs(v)<1)&&(h=!0),h},wd=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Ow=function(e){return[e.deltaX,e.deltaY]},_w=function(e){return e&&"current"in e?e.current:e},fT=function(e,t){return e[0]===t[0]&&e[1]===t[1]},hT=function(e){return`
|
||
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
||
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
||
`)},mT=0,Yo=[];function pT(e){var t=y.useRef([]),r=y.useRef([0,0]),n=y.useRef(),a=y.useState(mT++)[0],o=y.useState(WN)[0],u=y.useRef(e);y.useEffect(function(){u.current=e},[e]),y.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var k=RI([e.lockRef.current],(e.shards||[]).map(_w),!0).filter(Boolean);return k.forEach(function(S){return S.classList.add("allow-interactivity-".concat(a))}),function(){document.body.classList.remove("block-interactivity-".concat(a)),k.forEach(function(S){return S.classList.remove("allow-interactivity-".concat(a))})}}},[e.inert,e.lockRef.current,e.shards]);var c=y.useCallback(function(k,S){if("touches"in k&&k.touches.length===2||k.type==="wheel"&&k.ctrlKey)return!u.current.allowPinchZoom;var N=wd(k),E=r.current,A="deltaX"in k?k.deltaX:E[0]-N[0],P="deltaY"in k?k.deltaY:E[1]-N[1],_,O=k.target,D=Math.abs(A)>Math.abs(P)?"h":"v";if("touches"in k&&D==="h"&&O.type==="range")return!1;var B=window.getSelection(),F=B&&B.anchorNode,z=F?F===O||F.contains(O):!1;if(z)return!1;var Y=Pw(D,O);if(!Y)return!0;if(Y?_=D:(_=D==="v"?"h":"v",Y=Pw(D,O)),!Y)return!1;if(!n.current&&"changedTouches"in k&&(A||P)&&(n.current=_),!_)return!0;var U=n.current||_;return dT(U,S,k,U==="h"?A:P)},[]),f=y.useCallback(function(k){var S=k;if(!(!Yo.length||Yo[Yo.length-1]!==o)){var N="deltaY"in S?Ow(S):wd(S),E=t.current.filter(function(_){return _.name===S.type&&(_.target===S.target||S.target===_.shadowParent)&&fT(_.delta,N)})[0];if(E&&E.should){S.cancelable&&S.preventDefault();return}if(!E){var A=(u.current.shards||[]).map(_w).filter(Boolean).filter(function(_){return _.contains(S.target)}),P=A.length>0?c(S,A[0]):!u.current.noIsolation;P&&S.cancelable&&S.preventDefault()}}},[]),h=y.useCallback(function(k,S,N,E){var A={name:k,delta:S,target:N,should:E,shadowParent:gT(N)};t.current.push(A),setTimeout(function(){t.current=t.current.filter(function(P){return P!==A})},1)},[]),m=y.useCallback(function(k){r.current=wd(k),n.current=void 0},[]),g=y.useCallback(function(k){h(k.type,Ow(k),k.target,c(k,e.lockRef.current))},[]),v=y.useCallback(function(k){h(k.type,wd(k),k.target,c(k,e.lockRef.current))},[]);y.useEffect(function(){return Yo.push(o),e.setCallbacks({onScrollCapture:g,onWheelCapture:g,onTouchMoveCapture:v}),document.addEventListener("wheel",f,Qo),document.addEventListener("touchmove",f,Qo),document.addEventListener("touchstart",m,Qo),function(){Yo=Yo.filter(function(k){return k!==o}),document.removeEventListener("wheel",f,Qo),document.removeEventListener("touchmove",f,Qo),document.removeEventListener("touchstart",m,Qo)}},[]);var b=e.removeScrollBar,j=e.inert;return y.createElement(y.Fragment,null,j?y.createElement(o,{styles:hT(a)}):null,b?y.createElement(iT,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function gT(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const vT=KI(HN,pT);var qN=y.forwardRef(function(e,t){return y.createElement(ih,In({},e,{ref:t,sideCar:vT}))});qN.classNames=ih.classNames;var yT=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Xo=new WeakMap,kd=new WeakMap,jd={},Jp=0,QN=function(e){return e&&(e.host||QN(e.parentNode))},xT=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=QN(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},bT=function(e,t,r,n){var a=xT(t,Array.isArray(e)?e:[e]);jd[r]||(jd[r]=new WeakMap);var o=jd[r],u=[],c=new Set,f=new Set(a),h=function(g){!g||c.has(g)||(c.add(g),h(g.parentNode))};a.forEach(h);var m=function(g){!g||f.has(g)||Array.prototype.forEach.call(g.children,function(v){if(c.has(v))m(v);else try{var b=v.getAttribute(n),j=b!==null&&b!=="false",k=(Xo.get(v)||0)+1,S=(o.get(v)||0)+1;Xo.set(v,k),o.set(v,S),u.push(v),k===1&&j&&kd.set(v,!0),S===1&&v.setAttribute(r,"true"),j||v.setAttribute(n,"true")}catch(N){console.error("aria-hidden: cannot operate on ",v,N)}})};return m(t),c.clear(),Jp++,function(){u.forEach(function(g){var v=Xo.get(g)-1,b=o.get(g)-1;Xo.set(g,v),o.set(g,b),v||(kd.has(g)||g.removeAttribute(n),kd.delete(g)),b||g.removeAttribute(r)}),Jp--,Jp||(Xo=new WeakMap,Xo=new WeakMap,kd=new WeakMap,jd={})}},wT=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),a=yT(e);return a?(n.push.apply(n,Array.from(a.querySelectorAll("[aria-live], script"))),bT(n,a,r,"aria-hidden")):function(){return null}},ah="Dialog",[YN]=Q4(ah),[kT,xn]=YN(ah),XN=e=>{const{__scopeDialog:t,children:r,open:n,defaultOpen:a,onOpenChange:o,modal:u=!0}=e,c=y.useRef(null),f=y.useRef(null),[h,m]=eI({prop:n,defaultProp:a??!1,onChange:o,caller:ah});return l.jsx(kT,{scope:t,triggerRef:c,contentRef:f,contentId:di(),titleId:di(),descriptionId:di(),open:h,onOpenChange:m,onOpenToggle:y.useCallback(()=>m(g=>!g),[m]),modal:u,children:r})};XN.displayName=ah;var ZN="DialogTrigger",jT=y.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,a=xn(ZN,r),o=yo(t,a.triggerRef);return l.jsx(qt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":yy(a.open),...n,ref:o,onClick:ca(e.onClick,a.onOpenToggle)})});jT.displayName=ZN;var vy="DialogPortal",[ST,JN]=YN(vy,{forceMount:void 0}),eE=e=>{const{__scopeDialog:t,forceMount:r,children:n,container:a}=e,o=xn(vy,t);return l.jsx(ST,{scope:t,forceMount:r,children:y.Children.map(n,u=>l.jsx(nh,{present:r||o.open,children:l.jsx(FN,{asChild:!0,container:a,children:u})}))})};eE.displayName=vy;var tf="DialogOverlay",tE=y.forwardRef((e,t)=>{const r=JN(tf,e.__scopeDialog),{forceMount:n=r.forceMount,...a}=e,o=xn(tf,e.__scopeDialog);return o.modal?l.jsx(nh,{present:n||o.open,children:l.jsx(ET,{...a,ref:t})}):null});tE.displayName=tf;var NT=DN("DialogOverlay.RemoveScroll"),ET=y.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,a=xn(tf,r),o=bI(),u=yo(t,o);return l.jsx(qN,{as:NT,allowPinchZoom:!0,shards:[a.contentRef],children:l.jsx(qt.div,{"data-state":yy(a.open),...n,ref:u,style:{pointerEvents:"auto",...n.style}})})}),Ts="DialogContent",rE=y.forwardRef((e,t)=>{const r=JN(Ts,e.__scopeDialog),{forceMount:n=r.forceMount,...a}=e,o=xn(Ts,e.__scopeDialog);return l.jsx(nh,{present:n||o.open,children:o.modal?l.jsx(AT,{...a,ref:t}):l.jsx(CT,{...a,ref:t})})});rE.displayName=Ts;var AT=y.forwardRef((e,t)=>{const r=xn(Ts,e.__scopeDialog),n=y.useRef(null),a=yo(t,r.contentRef,n);return y.useEffect(()=>{const o=n.current;if(o)return wT(o)},[]),l.jsx(nE,{...e,ref:a,trapFocus:r.open,disableOutsidePointerEvents:r.open,onCloseAutoFocus:ca(e.onCloseAutoFocus,o=>{var u;o.preventDefault(),(u=r.triggerRef.current)==null||u.focus()}),onPointerDownOutside:ca(e.onPointerDownOutside,o=>{const u=o.detail.originalEvent,c=u.button===0&&u.ctrlKey===!0;(u.button===2||c)&&o.preventDefault()}),onFocusOutside:ca(e.onFocusOutside,o=>o.preventDefault())})}),CT=y.forwardRef((e,t)=>{const r=xn(Ts,e.__scopeDialog),n=y.useRef(!1),a=y.useRef(!1);return l.jsx(nE,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var u,c;(u=e.onCloseAutoFocus)==null||u.call(e,o),o.defaultPrevented||(n.current||(c=r.triggerRef.current)==null||c.focus(),o.preventDefault()),n.current=!1,a.current=!1},onInteractOutside:o=>{var f,h;(f=e.onInteractOutside)==null||f.call(e,o),o.defaultPrevented||(n.current=!0,o.detail.originalEvent.type==="pointerdown"&&(a.current=!0));const u=o.target;((h=r.triggerRef.current)==null?void 0:h.contains(u))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&a.current&&o.preventDefault()}})}),nE=y.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:a,onCloseAutoFocus:o,...u}=e,c=xn(Ts,r);return DI(),l.jsx(l.Fragment,{children:l.jsx($N,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:a,onUnmountAutoFocus:o,children:l.jsx(RN,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":yy(c.open),...u,ref:t,deferPointerDownOutside:!0,onDismiss:()=>c.onOpenChange(!1)})})})}),iE="DialogTitle",PT=y.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,a=xn(iE,r);return l.jsx(qt.h2,{id:a.titleId,...n,ref:t})});PT.displayName=iE;var aE="DialogDescription",OT=y.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,a=xn(aE,r);return l.jsx(qt.p,{id:a.descriptionId,...n,ref:t})});OT.displayName=aE;var oE="DialogClose",_T=y.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,a=xn(oE,r);return l.jsx(qt.button,{type:"button",...n,ref:t,onClick:ca(e.onClick,()=>a.onOpenChange(!1))})});_T.displayName=oE;function yy(e){return e?"open":"closed"}var Wl='[cmdk-group=""]',eg='[cmdk-group-items=""]',MT='[cmdk-group-heading=""]',sE='[cmdk-item=""]',Mw=`${sE}:not([aria-disabled="true"])`,av="cmdk-item-select",os="data-value",IT=(e,t,r)=>q4(e,t,r),lE=y.createContext(void 0),Hu=()=>y.useContext(lE),uE=y.createContext(void 0),xy=()=>y.useContext(uE),cE=y.createContext(void 0),dE=y.forwardRef((e,t)=>{let r=ss(()=>{var M,H;return{search:"",value:(H=(M=e.value)!=null?M:e.defaultValue)!=null?H:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),n=ss(()=>new Set),a=ss(()=>new Map),o=ss(()=>new Map),u=ss(()=>new Set),c=fE(e),{label:f,children:h,value:m,onValueChange:g,filter:v,shouldFilter:b,loop:j,disablePointerSelection:k=!1,vimBindings:S=!0,...N}=e,E=di(),A=di(),P=di(),_=y.useRef(null),O=WT();so(()=>{if(m!==void 0){let M=m.trim();r.current.value=M,D.emit()}},[m]),so(()=>{O(6,he)},[]);let D=y.useMemo(()=>({subscribe:M=>(u.current.add(M),()=>u.current.delete(M)),snapshot:()=>r.current,setState:(M,H,ne)=>{var Z,me,pe,Oe;if(!Object.is(r.current[M],H)){if(r.current[M]=H,M==="search")U(),z(),O(1,Y);else if(M==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let re=document.getElementById(P);re?re.focus():(Z=document.getElementById(E))==null||Z.focus()}if(O(7,()=>{var re;r.current.selectedItemId=(re=ue())==null?void 0:re.id,D.emit()}),ne||O(5,he),((me=c.current)==null?void 0:me.value)!==void 0){let re=H??"";(Oe=(pe=c.current).onValueChange)==null||Oe.call(pe,re);return}}D.emit()}},emit:()=>{u.current.forEach(M=>M())}}),[]),B=y.useMemo(()=>({value:(M,H,ne)=>{var Z;H!==((Z=o.current.get(M))==null?void 0:Z.value)&&(o.current.set(M,{value:H,keywords:ne}),r.current.filtered.items.set(M,F(H,ne)),O(2,()=>{z(),D.emit()}))},item:(M,H)=>(n.current.add(M),H&&(a.current.has(H)?a.current.get(H).add(M):a.current.set(H,new Set([M]))),O(3,()=>{U(),z(),r.current.value||Y(),D.emit()}),()=>{o.current.delete(M),n.current.delete(M),r.current.filtered.items.delete(M);let ne=ue();O(4,()=>{U(),(ne==null?void 0:ne.getAttribute("id"))===M&&Y(),D.emit()})}),group:M=>(a.current.has(M)||a.current.set(M,new Set),()=>{o.current.delete(M),a.current.delete(M)}),filter:()=>c.current.shouldFilter,label:f||e["aria-label"],getDisablePointerSelection:()=>c.current.disablePointerSelection,listId:E,inputId:P,labelId:A,listInnerRef:_}),[]);function F(M,H){var ne,Z;let me=(Z=(ne=c.current)==null?void 0:ne.filter)!=null?Z:IT;return M?me(M,r.current.search,H):0}function z(){if(!r.current.search||c.current.shouldFilter===!1)return;let M=r.current.filtered.items,H=[];r.current.filtered.groups.forEach(Z=>{let me=a.current.get(Z),pe=0;me.forEach(Oe=>{let re=M.get(Oe);pe=Math.max(re,pe)}),H.push([Z,pe])});let ne=_.current;ge().sort((Z,me)=>{var pe,Oe;let re=Z.getAttribute("id"),we=me.getAttribute("id");return((pe=M.get(we))!=null?pe:0)-((Oe=M.get(re))!=null?Oe:0)}).forEach(Z=>{let me=Z.closest(eg);me?me.appendChild(Z.parentElement===me?Z:Z.closest(`${eg} > *`)):ne.appendChild(Z.parentElement===ne?Z:Z.closest(`${eg} > *`))}),H.sort((Z,me)=>me[1]-Z[1]).forEach(Z=>{var me;let pe=(me=_.current)==null?void 0:me.querySelector(`${Wl}[${os}="${encodeURIComponent(Z[0])}"]`);pe==null||pe.parentElement.appendChild(pe)})}function Y(){let M=ge().find(ne=>ne.getAttribute("aria-disabled")!=="true"),H=M==null?void 0:M.getAttribute(os);D.setState("value",H||void 0)}function U(){var M,H,ne,Z;if(!r.current.search||c.current.shouldFilter===!1){r.current.filtered.count=n.current.size;return}r.current.filtered.groups=new Set;let me=0;for(let pe of n.current){let Oe=(H=(M=o.current.get(pe))==null?void 0:M.value)!=null?H:"",re=(Z=(ne=o.current.get(pe))==null?void 0:ne.keywords)!=null?Z:[],we=F(Oe,re);r.current.filtered.items.set(pe,we),we>0&&me++}for(let[pe,Oe]of a.current)for(let re of Oe)if(r.current.filtered.items.get(re)>0){r.current.filtered.groups.add(pe);break}r.current.filtered.count=me}function he(){var M,H,ne;let Z=ue();Z&&(((M=Z.parentElement)==null?void 0:M.firstChild)===Z&&((ne=(H=Z.closest(Wl))==null?void 0:H.querySelector(MT))==null||ne.scrollIntoView({block:"nearest"})),Z.scrollIntoView({block:"nearest"}))}function ue(){var M;return(M=_.current)==null?void 0:M.querySelector(`${sE}[aria-selected="true"]`)}function ge(){var M;return Array.from(((M=_.current)==null?void 0:M.querySelectorAll(Mw))||[])}function ie(M){let H=ge()[M];H&&D.setState("value",H.getAttribute(os))}function se(M){var H;let ne=ue(),Z=ge(),me=Z.findIndex(Oe=>Oe===ne),pe=Z[me+M];(H=c.current)!=null&&H.loop&&(pe=me+M<0?Z[Z.length-1]:me+M===Z.length?Z[0]:Z[me+M]),pe&&D.setState("value",pe.getAttribute(os))}function X(M){let H=ue(),ne=H==null?void 0:H.closest(Wl),Z;for(;ne&&!Z;)ne=M>0?UT(ne,Wl):HT(ne,Wl),Z=ne==null?void 0:ne.querySelector(Mw);Z?D.setState("value",Z.getAttribute(os)):se(M)}let te=()=>ie(ge().length-1),J=M=>{M.preventDefault(),M.metaKey?te():M.altKey?X(1):se(1)},I=M=>{M.preventDefault(),M.metaKey?ie(0):M.altKey?X(-1):se(-1)};return y.createElement(qt.div,{ref:t,tabIndex:-1,...N,"cmdk-root":"",onKeyDown:M=>{var H;(H=N.onKeyDown)==null||H.call(N,M);let ne=M.nativeEvent.isComposing||M.keyCode===229;if(!(M.defaultPrevented||ne))switch(M.key){case"n":case"j":{S&&M.ctrlKey&&J(M);break}case"ArrowDown":{J(M);break}case"p":case"k":{S&&M.ctrlKey&&I(M);break}case"ArrowUp":{I(M);break}case"Home":{M.preventDefault(),ie(0);break}case"End":{M.preventDefault(),te();break}case"Enter":{M.preventDefault();let Z=ue();if(Z){let me=new Event(av);Z.dispatchEvent(me)}}}}},y.createElement("label",{"cmdk-label":"",htmlFor:B.inputId,id:B.labelId,style:GT},f),oh(e,M=>y.createElement(uE.Provider,{value:D},y.createElement(lE.Provider,{value:B},M))))}),TT=y.forwardRef((e,t)=>{var r,n;let a=di(),o=y.useRef(null),u=y.useContext(cE),c=Hu(),f=fE(e),h=(n=(r=f.current)==null?void 0:r.forceMount)!=null?n:u==null?void 0:u.forceMount;so(()=>{if(!h)return c.item(a,u==null?void 0:u.id)},[h]);let m=hE(a,o,[e.value,e.children,o],e.keywords),g=xy(),v=ma(O=>O.value&&O.value===m.current),b=ma(O=>h||c.filter()===!1?!0:O.search?O.filtered.items.get(a)>0:!0);y.useEffect(()=>{let O=o.current;if(!(!O||e.disabled))return O.addEventListener(av,j),()=>O.removeEventListener(av,j)},[b,e.onSelect,e.disabled]);function j(){var O,D;k(),(D=(O=f.current).onSelect)==null||D.call(O,m.current)}function k(){g.setState("value",m.current,!0)}if(!b)return null;let{disabled:S,value:N,onSelect:E,forceMount:A,keywords:P,..._}=e;return y.createElement(qt.div,{ref:Is(o,t),..._,id:a,"cmdk-item":"",role:"option","aria-disabled":!!S,"aria-selected":!!v,"data-disabled":!!S,"data-selected":!!v,onPointerMove:S||c.getDisablePointerSelection()?void 0:k,onClick:S?void 0:j},e.children)}),DT=y.forwardRef((e,t)=>{let{heading:r,children:n,forceMount:a,...o}=e,u=di(),c=y.useRef(null),f=y.useRef(null),h=di(),m=Hu(),g=ma(b=>a||m.filter()===!1?!0:b.search?b.filtered.groups.has(u):!0);so(()=>m.group(u),[]),hE(u,c,[e.value,e.heading,f]);let v=y.useMemo(()=>({id:u,forceMount:a}),[a]);return y.createElement(qt.div,{ref:Is(c,t),...o,"cmdk-group":"",role:"presentation",hidden:g?void 0:!0},r&&y.createElement("div",{ref:f,"cmdk-group-heading":"","aria-hidden":!0,id:h},r),oh(e,b=>y.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":r?h:void 0},y.createElement(cE.Provider,{value:v},b))))}),RT=y.forwardRef((e,t)=>{let{alwaysRender:r,...n}=e,a=y.useRef(null),o=ma(u=>!u.search);return!r&&!o?null:y.createElement(qt.div,{ref:Is(a,t),...n,"cmdk-separator":"",role:"separator"})}),LT=y.forwardRef((e,t)=>{let{onValueChange:r,...n}=e,a=e.value!=null,o=xy(),u=ma(h=>h.search),c=ma(h=>h.selectedItemId),f=Hu();return y.useEffect(()=>{e.value!=null&&o.setState("search",e.value)},[e.value]),y.createElement(qt.input,{ref:t,...n,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":f.listId,"aria-labelledby":f.labelId,"aria-activedescendant":c,id:f.inputId,type:"text",value:a?e.value:u,onChange:h=>{a||o.setState("search",h.target.value),r==null||r(h.target.value)}})}),$T=y.forwardRef((e,t)=>{let{children:r,label:n="Suggestions",...a}=e,o=y.useRef(null),u=y.useRef(null),c=ma(h=>h.selectedItemId),f=Hu();return y.useEffect(()=>{if(u.current&&o.current){let h=u.current,m=o.current,g,v=new ResizeObserver(()=>{g=requestAnimationFrame(()=>{let b=h.offsetHeight;m.style.setProperty("--cmdk-list-height",b.toFixed(1)+"px")})});return v.observe(h),()=>{cancelAnimationFrame(g),v.unobserve(h)}}},[]),y.createElement(qt.div,{ref:Is(o,t),...a,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":c,"aria-label":n,id:f.listId},oh(e,h=>y.createElement("div",{ref:Is(u,f.listInnerRef),"cmdk-list-sizer":""},h)))}),zT=y.forwardRef((e,t)=>{let{open:r,onOpenChange:n,overlayClassName:a,contentClassName:o,container:u,...c}=e;return y.createElement(XN,{open:r,onOpenChange:n},y.createElement(eE,{container:u},y.createElement(tE,{"cmdk-overlay":"",className:a}),y.createElement(rE,{"aria-label":e.label,"cmdk-dialog":"",className:o},y.createElement(dE,{ref:t,...c}))))}),FT=y.forwardRef((e,t)=>ma(r=>r.filtered.count===0)?y.createElement(qt.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null),BT=y.forwardRef((e,t)=>{let{progress:r,children:n,label:a="Loading...",...o}=e;return y.createElement(qt.div,{ref:t,...o,"cmdk-loading":"",role:"progressbar","aria-valuenow":r,"aria-valuemin":0,"aria-valuemax":100,"aria-label":a},oh(e,u=>y.createElement("div",{"aria-hidden":!0},u)))}),Zo=Object.assign(dE,{List:$T,Item:TT,Input:LT,Group:DT,Separator:RT,Dialog:zT,Empty:FT,Loading:BT});function UT(e,t){let r=e.nextElementSibling;for(;r;){if(r.matches(t))return r;r=r.nextElementSibling}}function HT(e,t){let r=e.previousElementSibling;for(;r;){if(r.matches(t))return r;r=r.previousElementSibling}}function fE(e){let t=y.useRef(e);return so(()=>{t.current=e}),t}var so=typeof window>"u"?y.useEffect:y.useLayoutEffect;function ss(e){let t=y.useRef();return t.current===void 0&&(t.current=e()),t}function ma(e){let t=xy(),r=()=>e(t.snapshot());return y.useSyncExternalStore(t.subscribe,r,r)}function hE(e,t,r,n=[]){let a=y.useRef(),o=Hu();return so(()=>{var u;let c=(()=>{var h;for(let m of r){if(typeof m=="string")return m.trim();if(typeof m=="object"&&"current"in m)return m.current?(h=m.current.textContent)==null?void 0:h.trim():a.current}})(),f=n.map(h=>h.trim());o.value(e,c,f),(u=t.current)==null||u.setAttribute(os,c),a.current=c}),a}var WT=()=>{let[e,t]=y.useState(),r=ss(()=>new Map);return so(()=>{r.current.forEach(n=>n()),r.current=new Map},[e]),(n,a)=>{r.current.set(n,a),t({})}};function KT(e){let t=e.type;return typeof t=="function"?t(e.props):"render"in t?t.render(e.props):e}function oh({asChild:e,children:t},r){return e&&y.isValidElement(t)?y.cloneElement(KT(t),{ref:t.ref},r(t.props.children)):r(t)}var GT={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function VT({onNavigate:e}){const[t,r]=y.useState(!1);return y.useEffect(()=>{const n=a=>{(a.metaKey||a.ctrlKey)&&a.key.toLowerCase()==="k"&&(a.preventDefault(),r(o=>!o))};return document.addEventListener("keydown",n),()=>document.removeEventListener("keydown",n)},[]),l.jsx(Zo.Dialog,{open:t,onOpenChange:r,label:"Befehlspalette",className:"fixed inset-0 z-50 flex items-start justify-center bg-black/50 p-4 pt-[12vh] overscroll-contain",onClick:()=>r(!1),children:l.jsxs("div",{className:"w-full max-w-lg overflow-hidden rounded-xl border border-border bg-popover text-popover-foreground shadow-2xl",onClick:n=>n.stopPropagation(),children:[l.jsx(Zo.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"}),l.jsxs(Zo.List,{className:"max-h-80 overflow-y-auto p-2",children:[l.jsx(Zo.Empty,{className:"px-3 py-6 text-center text-sm text-muted-foreground",children:"Nichts gefunden."}),l.jsx(Zo.Group,{heading:"Bereiche",className:"px-1 py-1 text-xs text-muted-foreground",children:ou.map(n=>l.jsxs(Zo.Item,{value:`${n.label} ${n.hint}`,onSelect:()=>{e(n.id),r(!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:[l.jsx(n.icon,{className:"h-4 w-4 text-primary"}),l.jsx("span",{children:n.label}),l.jsx("span",{className:"ml-auto truncate text-xs text-muted-foreground",children:n.hint})]},n.id))})]})]})})}const mE="mc_expert_mode",ov="mc-expert-mode-change",qT=()=>{try{return localStorage.getItem(mE)==="true"}catch{return!1}};function QT(e){return window.addEventListener(ov,e),window.addEventListener("storage",e),()=>{window.removeEventListener(ov,e),window.removeEventListener("storage",e)}}function Iw(e){localStorage.setItem(mE,String(e)),window.dispatchEvent(new Event(ov))}function pE(){return y.useSyncExternalStore(QT,qT,()=>!1)}function gE(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(r=gE(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function rt(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=gE(e))&&(n&&(n+=" "),n+=t);return n}const by="-",YT=e=>{const t=ZT(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:u=>{const c=u.split(by);return c[0]===""&&c.length!==1&&c.shift(),vE(c,t)||XT(u)},getConflictingClassGroupIds:(u,c)=>{const f=r[u]||[];return c&&n[u]?[...f,...n[u]]:f}}},vE=(e,t)=>{var u;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),a=n?vE(e.slice(1),n):void 0;if(a)return a;if(t.validators.length===0)return;const o=e.join(by);return(u=t.validators.find(({validator:c})=>c(o)))==null?void 0:u.classGroupId},Tw=/^\[(.+)\]$/,XT=e=>{if(Tw.test(e)){const t=Tw.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},ZT=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return eD(Object.entries(e.classGroups),r).forEach(([o,u])=>{sv(u,n,o,t)}),n},sv=(e,t,r,n)=>{e.forEach(a=>{if(typeof a=="string"){const o=a===""?t:Dw(t,a);o.classGroupId=r;return}if(typeof a=="function"){if(JT(a)){sv(a(n),t,r,n);return}t.validators.push({validator:a,classGroupId:r});return}Object.entries(a).forEach(([o,u])=>{sv(u,Dw(t,o),r,n)})})},Dw=(e,t)=>{let r=e;return t.split(by).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},JT=e=>e.isThemeGetter,eD=(e,t)=>t?e.map(([r,n])=>{const a=n.map(o=>typeof o=="string"?t+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([u,c])=>[t+u,c])):o);return[r,a]}):e,tD=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const a=(o,u)=>{r.set(o,u),t++,t>e&&(t=0,n=r,r=new Map)};return{get(o){let u=r.get(o);if(u!==void 0)return u;if((u=n.get(o))!==void 0)return a(o,u),u},set(o,u){r.has(o)?r.set(o,u):a(o,u)}}},yE="!",rD=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,a=t[0],o=t.length,u=c=>{const f=[];let h=0,m=0,g;for(let S=0;S<c.length;S++){let N=c[S];if(h===0){if(N===a&&(n||c.slice(S,S+o)===t)){f.push(c.slice(m,S)),m=S+o;continue}if(N==="/"){g=S;continue}}N==="["?h++:N==="]"&&h--}const v=f.length===0?c:c.substring(m),b=v.startsWith(yE),j=b?v.substring(1):v,k=g&&g>m?g-m:void 0;return{modifiers:f,hasImportantModifier:b,baseClassName:j,maybePostfixModifierPosition:k}};return r?c=>r({className:c,parseClassName:u}):u},nD=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},iD=e=>({cache:tD(e.cacheSize),parseClassName:rD(e),...YT(e)}),aD=/\s+/,oD=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:a}=t,o=[],u=e.trim().split(aD);let c="";for(let f=u.length-1;f>=0;f-=1){const h=u[f],{modifiers:m,hasImportantModifier:g,baseClassName:v,maybePostfixModifierPosition:b}=r(h);let j=!!b,k=n(j?v.substring(0,b):v);if(!k){if(!j){c=h+(c.length>0?" "+c:c);continue}if(k=n(v),!k){c=h+(c.length>0?" "+c:c);continue}j=!1}const S=nD(m).join(":"),N=g?S+yE:S,E=N+k;if(o.includes(E))continue;o.push(E);const A=a(k,j);for(let P=0;P<A.length;++P){const _=A[P];o.push(N+_)}c=h+(c.length>0?" "+c:c)}return c};function sD(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=xE(t))&&(n&&(n+=" "),n+=r);return n}const xE=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=xE(e[n]))&&(r&&(r+=" "),r+=t);return r};function lD(e,...t){let r,n,a,o=u;function u(f){const h=t.reduce((m,g)=>g(m),e());return r=iD(h),n=r.cache.get,a=r.cache.set,o=c,c(f)}function c(f){const h=n(f);if(h)return h;const m=oD(f,r);return a(f,m),m}return function(){return o(sD.apply(null,arguments))}}const at=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},bE=/^\[(?:([a-z-]+):)?(.+)\]$/i,uD=/^\d+\/\d+$/,cD=new Set(["px","full","screen"]),dD=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,fD=/\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$/,hD=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,mD=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,pD=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ri=e=>hs(e)||cD.has(e)||uD.test(e),Ki=e=>Gs(e,"length",jD),hs=e=>!!e&&!Number.isNaN(Number(e)),tg=e=>Gs(e,"number",hs),Kl=e=>!!e&&Number.isInteger(Number(e)),gD=e=>e.endsWith("%")&&hs(e.slice(0,-1)),$e=e=>bE.test(e),Gi=e=>dD.test(e),vD=new Set(["length","size","percentage"]),yD=e=>Gs(e,vD,wE),xD=e=>Gs(e,"position",wE),bD=new Set(["image","url"]),wD=e=>Gs(e,bD,ND),kD=e=>Gs(e,"",SD),Gl=()=>!0,Gs=(e,t,r)=>{const n=bE.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},jD=e=>fD.test(e)&&!hD.test(e),wE=()=>!1,SD=e=>mD.test(e),ND=e=>pD.test(e),ED=()=>{const e=at("colors"),t=at("spacing"),r=at("blur"),n=at("brightness"),a=at("borderColor"),o=at("borderRadius"),u=at("borderSpacing"),c=at("borderWidth"),f=at("contrast"),h=at("grayscale"),m=at("hueRotate"),g=at("invert"),v=at("gap"),b=at("gradientColorStops"),j=at("gradientColorStopPositions"),k=at("inset"),S=at("margin"),N=at("opacity"),E=at("padding"),A=at("saturate"),P=at("scale"),_=at("sepia"),O=at("skew"),D=at("space"),B=at("translate"),F=()=>["auto","contain","none"],z=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto",$e,t],U=()=>[$e,t],he=()=>["",ri,Ki],ue=()=>["auto",hs,$e],ge=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],ie=()=>["solid","dashed","dotted","double","none"],se=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],X=()=>["start","end","center","between","around","evenly","stretch"],te=()=>["","0",$e],J=()=>["auto","avoid","all","avoid-page","page","left","right","column"],I=()=>[hs,$e];return{cacheSize:500,separator:":",theme:{colors:[Gl],spacing:[ri,Ki],blur:["none","",Gi,$e],brightness:I(),borderColor:[e],borderRadius:["none","","full",Gi,$e],borderSpacing:U(),borderWidth:he(),contrast:I(),grayscale:te(),hueRotate:I(),invert:te(),gap:U(),gradientColorStops:[e],gradientColorStopPositions:[gD,Ki],inset:Y(),margin:Y(),opacity:I(),padding:U(),saturate:I(),scale:I(),sepia:te(),skew:I(),space:U(),translate:U()},classGroups:{aspect:[{aspect:["auto","square","video",$e]}],container:["container"],columns:[{columns:[Gi]}],"break-after":[{"break-after":J()}],"break-before":[{"break-before":J()}],"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:[...ge(),$e]}],overflow:[{overflow:z()}],"overflow-x":[{"overflow-x":z()}],"overflow-y":[{"overflow-y":z()}],overscroll:[{overscroll:F()}],"overscroll-x":[{"overscroll-x":F()}],"overscroll-y":[{"overscroll-y":F()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[k]}],"inset-x":[{"inset-x":[k]}],"inset-y":[{"inset-y":[k]}],start:[{start:[k]}],end:[{end:[k]}],top:[{top:[k]}],right:[{right:[k]}],bottom:[{bottom:[k]}],left:[{left:[k]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Kl,$e]}],basis:[{basis:Y()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",$e]}],grow:[{grow:te()}],shrink:[{shrink:te()}],order:[{order:["first","last","none",Kl,$e]}],"grid-cols":[{"grid-cols":[Gl]}],"col-start-end":[{col:["auto",{span:["full",Kl,$e]},$e]}],"col-start":[{"col-start":ue()}],"col-end":[{"col-end":ue()}],"grid-rows":[{"grid-rows":[Gl]}],"row-start-end":[{row:["auto",{span:[Kl,$e]},$e]}],"row-start":[{"row-start":ue()}],"row-end":[{"row-end":ue()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",$e]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",$e]}],gap:[{gap:[v]}],"gap-x":[{"gap-x":[v]}],"gap-y":[{"gap-y":[v]}],"justify-content":[{justify:["normal",...X()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...X(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...X(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[E]}],px:[{px:[E]}],py:[{py:[E]}],ps:[{ps:[E]}],pe:[{pe:[E]}],pt:[{pt:[E]}],pr:[{pr:[E]}],pb:[{pb:[E]}],pl:[{pl:[E]}],m:[{m:[S]}],mx:[{mx:[S]}],my:[{my:[S]}],ms:[{ms:[S]}],me:[{me:[S]}],mt:[{mt:[S]}],mr:[{mr:[S]}],mb:[{mb:[S]}],ml:[{ml:[S]}],"space-x":[{"space-x":[D]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[D]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",$e,t]}],"min-w":[{"min-w":[$e,t,"min","max","fit"]}],"max-w":[{"max-w":[$e,t,"none","full","min","max","fit","prose",{screen:[Gi]},Gi]}],h:[{h:[$e,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[$e,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[$e,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[$e,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Gi,Ki]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",tg]}],"font-family":[{font:[Gl]}],"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",$e]}],"line-clamp":[{"line-clamp":["none",hs,tg]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",ri,$e]}],"list-image":[{"list-image":["none",$e]}],"list-style-type":[{list:["none","disc","decimal",$e]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[N]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[N]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ie(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",ri,Ki]}],"underline-offset":[{"underline-offset":["auto",ri,$e]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:U()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",$e]}],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",$e]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[N]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ge(),xD]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",yD]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},wD]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[j]}],"gradient-via-pos":[{via:[j]}],"gradient-to-pos":[{to:[j]}],"gradient-from":[{from:[b]}],"gradient-via":[{via:[b]}],"gradient-to":[{to:[b]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[c]}],"border-w-x":[{"border-x":[c]}],"border-w-y":[{"border-y":[c]}],"border-w-s":[{"border-s":[c]}],"border-w-e":[{"border-e":[c]}],"border-w-t":[{"border-t":[c]}],"border-w-r":[{"border-r":[c]}],"border-w-b":[{"border-b":[c]}],"border-w-l":[{"border-l":[c]}],"border-opacity":[{"border-opacity":[N]}],"border-style":[{border:[...ie(),"hidden"]}],"divide-x":[{"divide-x":[c]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[c]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[N]}],"divide-style":[{divide:ie()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...ie()]}],"outline-offset":[{"outline-offset":[ri,$e]}],"outline-w":[{outline:[ri,Ki]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:he()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[N]}],"ring-offset-w":[{"ring-offset":[ri,Ki]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Gi,kD]}],"shadow-color":[{shadow:[Gl]}],opacity:[{opacity:[N]}],"mix-blend":[{"mix-blend":[...se(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":se()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[f]}],"drop-shadow":[{"drop-shadow":["","none",Gi,$e]}],grayscale:[{grayscale:[h]}],"hue-rotate":[{"hue-rotate":[m]}],invert:[{invert:[g]}],saturate:[{saturate:[A]}],sepia:[{sepia:[_]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[f]}],"backdrop-grayscale":[{"backdrop-grayscale":[h]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[m]}],"backdrop-invert":[{"backdrop-invert":[g]}],"backdrop-opacity":[{"backdrop-opacity":[N]}],"backdrop-saturate":[{"backdrop-saturate":[A]}],"backdrop-sepia":[{"backdrop-sepia":[_]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[u]}],"border-spacing-x":[{"border-spacing-x":[u]}],"border-spacing-y":[{"border-spacing-y":[u]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",$e]}],duration:[{duration:I()}],ease:[{ease:["linear","in","out","in-out",$e]}],delay:[{delay:I()}],animate:[{animate:["none","spin","ping","pulse","bounce",$e]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[P]}],"scale-x":[{"scale-x":[P]}],"scale-y":[{"scale-y":[P]}],rotate:[{rotate:[Kl,$e]}],"translate-x":[{"translate-x":[B]}],"translate-y":[{"translate-y":[B]}],"skew-x":[{"skew-x":[O]}],"skew-y":[{"skew-y":[O]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",$e]}],accent:[{accent:["auto",e]}],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",$e]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":U()}],"scroll-mx":[{"scroll-mx":U()}],"scroll-my":[{"scroll-my":U()}],"scroll-ms":[{"scroll-ms":U()}],"scroll-me":[{"scroll-me":U()}],"scroll-mt":[{"scroll-mt":U()}],"scroll-mr":[{"scroll-mr":U()}],"scroll-mb":[{"scroll-mb":U()}],"scroll-ml":[{"scroll-ml":U()}],"scroll-p":[{"scroll-p":U()}],"scroll-px":[{"scroll-px":U()}],"scroll-py":[{"scroll-py":U()}],"scroll-ps":[{"scroll-ps":U()}],"scroll-pe":[{"scroll-pe":U()}],"scroll-pt":[{"scroll-pt":U()}],"scroll-pr":[{"scroll-pr":U()}],"scroll-pb":[{"scroll-pb":U()}],"scroll-pl":[{"scroll-pl":U()}],"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",$e]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[ri,Ki,tg]}],stroke:[{stroke:[e,"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"]}}},AD=lD(ED);function ee(...e){return AD(rt(e))}function Ds(e){return e?e.replace(/127\.0\.0\.1|localhost/g,"192.168.178.151"):""}function kE(){const e=pE();return l.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:[l.jsxs("button",{onClick:()=>Iw(!1),"aria-pressed":!e,className:ee("flex items-center gap-1 rounded px-2 py-1 text-xs font-semibold transition-all cursor-pointer",e?"text-muted-foreground hover:text-foreground":"bg-primary/15 text-primary shadow-sm"),children:[l.jsx(us,{className:"h-3.5 w-3.5"})," Einfach"]}),l.jsxs("button",{onClick:()=>Iw(!0),"aria-pressed":e,className:ee("flex items-center gap-1 rounded px-2 py-1 text-xs font-semibold transition-all cursor-pointer",e?"bg-primary/15 text-primary shadow-sm":"text-muted-foreground hover:text-foreground"),children:[l.jsx(D4,{className:"h-3.5 w-3.5"})," Experte"]})]})}async function je(e,t){var f;const r={"Content-Type":"application/json",...t==null?void 0:t.headers},n=localStorage.getItem("mc_sudo_password"),a=localStorage.getItem("mc_hf_token");n&&(r["X-Sudo-Password"]=n);let o=t==null?void 0:t.body;if((((f=t==null?void 0:t.method)==null?void 0:f.toUpperCase())||"GET")==="POST"){if(typeof o=="string")try{const h=JSON.parse(o);let m=!1;n&&!("sudo_password"in h)&&(h.sudo_password=n,m=!0),a&&!("hf_token"in h)&&(h.hf_token=a,m=!0),m&&(o=JSON.stringify(h))}catch{}else if(!o){const h={};n&&(h.sudo_password=n),a&&(h.hf_token=a),Object.keys(h).length>0&&(o=JSON.stringify(h))}}const c=await fetch(e,{...t,headers:r,body:o});if(!c.ok)throw new Error(`${c.status} ${c.statusText}`);return c.json()}const jE=(e,t,r=!1,n=!0)=>je("/api/groups",{method:"PUT",body:JSON.stringify({group:e,members:t,swap:r,persist:n})}),CD=e=>je("/api/routing/policy",{method:"PUT",body:JSON.stringify(e)}),Ve={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:e=>["drafts",e??""],connect:e=>["connect",e??""],connectHealth:["connect-health"],memory:(e,t)=>["memory",e??"",t??""],memoryGraph:["memory-graph"]},PD=(e=!0)=>Vt({queryKey:Ve.memoryGraph,queryFn:()=>je("/api/memory/graph"),enabled:e}),wy=()=>Vt({queryKey:Ve.health,queryFn:()=>je("/api/health"),refetchInterval:1e4}),xo=(e=5e3)=>Vt({queryKey:Ve.systemStatus,queryFn:()=>je("/api/system/status"),refetchInterval:e}),SE=(e=3e3)=>Vt({queryKey:Ve.services,queryFn:()=>je("/api/system/services"),refetchInterval:e}),yi=(e=4e3)=>Vt({queryKey:Ve.models,queryFn:()=>je("/api/models"),refetchInterval:e}),NE=(e=8e3)=>Vt({queryKey:Ve.groups,queryFn:()=>je("/api/groups"),refetchInterval:e}),OD=()=>Vt({queryKey:Ve.routingPolicy,queryFn:()=>je("/api/routing/policy")}),_D=(e=2e3)=>Vt({queryKey:Ve.jobs,queryFn:()=>je("/api/jobs"),refetchInterval:e,select:t=>t.jobs??[]}),ky=(e=3e3)=>Vt({queryKey:Ve.tokenStats,queryFn:()=>je("/api/system/token-stats"),refetchInterval:e}),jy=(e=5e3)=>Vt({queryKey:Ve.agentStatus,queryFn:()=>je("/api/agent/status"),refetchInterval:e}),EE=(e=6e4)=>Vt({queryKey:Ve.hermesBrain,queryFn:()=>je("/api/agent/brain"),refetchInterval:e}),sh=e=>Vt({queryKey:Ve.updates,queryFn:()=>je("/api/maintenance/updates"),refetchInterval:e}),MD=()=>Vt({queryKey:Ve.discover,queryFn:()=>je("/api/discover")}),ID=e=>Vt({queryKey:Ve.drafts(e),queryFn:()=>je(`/api/models/drafts?target=${encodeURIComponent(e??"")}`),enabled:!!e}),TD=e=>Vt({queryKey:Ve.connect(e),queryFn:()=>je(e?`/api/connect?${e}`:"/api/connect")}),DD=()=>Vt({queryKey:Ve.connectHealth,queryFn:()=>je("/api/connect/health"),refetchInterval:15e3}),lv=e=>Vt({queryKey:Ve.memory(e==null?void 0:e.q,e==null?void 0:e.category),queryFn:()=>{const t=new URLSearchParams;return e!=null&&e.q&&t.set("q",e.q),e!=null&&e.category&&t.set("category",e.category),je(`/api/memory?${t}`)},select:t=>e!=null&&e.limit?t.slice(0,e.limit):t});let uv=[],cv=[];const dv=new Set,AE=()=>dv.forEach(e=>e());function CE(e){return dv.add(e),()=>{dv.delete(e)}}function RD(e){uv=[...uv,e].slice(-40),AE()}function LD(e){cv=[...cv,e].slice(-40),AE()}const $D=()=>y.useSyncExternalStore(CE,()=>uv),zD=()=>y.useSyncExternalStore(CE,()=>cv);function FD(){const{data:e,dataUpdatedAt:t}=xo(3e3),{data:r,dataUpdatedAt:n}=ky(3e3),a=y.useRef(null);y.useEffect(()=>{var o,u,c,f;e&&RD({t:Date.now(),cpu:((o=e.cpu)==null?void 0:o.percent)??0,ram:((u=e.ram)==null?void 0:u.percent)??0,gpu:((c=e.gpu)==null?void 0:c.busy_percent)??null,disk:((f=e.disk)==null?void 0:f.percent)??null})},[t]),y.useEffect(()=>{if(!r)return;const o=Date.now(),u=r.prompt_tokens,c=r.completion_tokens;if(a.current){const f=Math.max((o-a.current.t)/1e3,.001);LD({t:o,prompt:Math.max(0,(u-a.current.p)/f),completion:Math.max(0,(c-a.current.c)/f)})}a.current={p:u,c,t:o}},[n])}function BD(){const{data:e,error:t}=xo(3e3),r=$D();return{sys:e,hist:r,error:t}}function Yi(e){return(e/1024**3).toFixed(1)}function fv(e){return e?e>1024**3?`${(e/1024**3).toFixed(1)} GB`:`${(e/1024**2).toFixed(0)} MB`:""}function _r(e){if(!e)return"—";const t=e/1024**3;return t>=1?`${t.toFixed(1)} GB`:`${(e/1024**2).toFixed(0)} MB`}function UD(e){if(!e)return"";const t=Math.floor(e/60);return t>0?`${t} min`:`${e} s`}function Rw(e){return e?`${Math.round(e/1024)}k`:"—"}var HD=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"];function Sy(e){if(typeof e!="string")return!1;var t=HD;return t.includes(e)}var WD=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],KD=new Set(WD);function PE(e){return typeof e!="string"?!1:KD.has(e)}function OE(e){return typeof e=="string"&&e.startsWith("data-")}function vn(e){if(typeof e!="object"||e===null)return{};var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(PE(r)||OE(r))&&(t[r]=e[r]);return t}function lh(e){if(e==null)return null;if(y.isValidElement(e)&&typeof e.props=="object"&&e.props!==null){var t=e.props;return vn(t)}return typeof e=="object"&&!Array.isArray(e)?vn(e):null}function Yr(e){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(PE(r)||OE(r)||Sy(r))&&(t[r]=e[r]);return t}function GD(e){return e==null?null:y.isValidElement(e)?Yr(e.props):typeof e=="object"&&!Array.isArray(e)?Yr(e):null}var VD=["children","width","height","viewBox","className","style","title","desc"];function hv(){return hv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},hv.apply(null,arguments)}function qD(e,t){if(e==null)return{};var r,n,a=QD(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function QD(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var _E=y.forwardRef((e,t)=>{var r=e.children,n=e.width,a=e.height,o=e.viewBox,u=e.className,c=e.style,f=e.title,h=e.desc,m=qD(e,VD),g=o||{width:n,height:a,x:0,y:0},v=rt("recharts-surface",u);return y.createElement("svg",hv({},Yr(m),{className:v,width:n,height:a,style:c,viewBox:"".concat(g.x," ").concat(g.y," ").concat(g.width," ").concat(g.height),ref:t}),y.createElement("title",null,f),y.createElement("desc",null,h),r)}),YD=["children","className"];function mv(){return mv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},mv.apply(null,arguments)}function XD(e,t){if(e==null)return{};var r,n,a=ZD(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function ZD(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var Xr=y.forwardRef((e,t)=>{var r=e.children,n=e.className,a=XD(e,YD),o=rt("recharts-layer",n);return y.createElement("g",mv({className:o},Yr(a),{ref:t}),r)}),JD=y.createContext(null);function pt(e){return function(){return e}}const pv=Math.PI,gv=2*pv,$a=1e-6,eR=gv-$a;function ME(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function tR(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return ME;const r=10**t;return function(n){this._+=n[0];for(let a=1,o=n.length;a<o;++a)this._+=Math.round(arguments[a]*r)/r+n[a]}}class rR{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?ME:tR(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,n,a){this._append`Q${+t},${+r},${this._x1=+n},${this._y1=+a}`}bezierCurveTo(t,r,n,a,o,u){this._append`C${+t},${+r},${+n},${+a},${this._x1=+o},${this._y1=+u}`}arcTo(t,r,n,a,o){if(t=+t,r=+r,n=+n,a=+a,o=+o,o<0)throw new Error(`negative radius: ${o}`);let u=this._x1,c=this._y1,f=n-t,h=a-r,m=u-t,g=c-r,v=m*m+g*g;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(v>$a)if(!(Math.abs(g*f-h*m)>$a)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let b=n-u,j=a-c,k=f*f+h*h,S=b*b+j*j,N=Math.sqrt(k),E=Math.sqrt(v),A=o*Math.tan((pv-Math.acos((k+v-S)/(2*N*E)))/2),P=A/E,_=A/N;Math.abs(P-1)>$a&&this._append`L${t+P*m},${r+P*g}`,this._append`A${o},${o},0,0,${+(g*b>m*j)},${this._x1=t+_*f},${this._y1=r+_*h}`}}arc(t,r,n,a,o,u){if(t=+t,r=+r,n=+n,u=!!u,n<0)throw new Error(`negative radius: ${n}`);let c=n*Math.cos(a),f=n*Math.sin(a),h=t+c,m=r+f,g=1^u,v=u?a-o:o-a;this._x1===null?this._append`M${h},${m}`:(Math.abs(this._x1-h)>$a||Math.abs(this._y1-m)>$a)&&this._append`L${h},${m}`,n&&(v<0&&(v=v%gv+gv),v>eR?this._append`A${n},${n},0,1,${g},${t-c},${r-f}A${n},${n},0,1,${g},${this._x1=h},${this._y1=m}`:v>$a&&this._append`A${n},${n},0,${+(v>=pv)},${g},${this._x1=t+n*Math.cos(o)},${this._y1=r+n*Math.sin(o)}`)}rect(t,r,n,a){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+a}h${-n}Z`}toString(){return this._}}function IE(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new rR(t)}function Ny(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function TE(e){this._context=e}TE.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function uh(e){return new TE(e)}function DE(e){return e[0]}function RE(e){return e[1]}function LE(e,t){var r=pt(!0),n=null,a=uh,o=null,u=IE(c);e=typeof e=="function"?e:e===void 0?DE:pt(e),t=typeof t=="function"?t:t===void 0?RE:pt(t);function c(f){var h,m=(f=Ny(f)).length,g,v=!1,b;for(n==null&&(o=a(b=u())),h=0;h<=m;++h)!(h<m&&r(g=f[h],h,f))===v&&((v=!v)?o.lineStart():o.lineEnd()),v&&o.point(+e(g,h,f),+t(g,h,f));if(b)return o=null,b+""||null}return c.x=function(f){return arguments.length?(e=typeof f=="function"?f:pt(+f),c):e},c.y=function(f){return arguments.length?(t=typeof f=="function"?f:pt(+f),c):t},c.defined=function(f){return arguments.length?(r=typeof f=="function"?f:pt(!!f),c):r},c.curve=function(f){return arguments.length?(a=f,n!=null&&(o=a(n)),c):a},c.context=function(f){return arguments.length?(f==null?n=o=null:o=a(n=f),c):n},c}function Sd(e,t,r){var n=null,a=pt(!0),o=null,u=uh,c=null,f=IE(h);e=typeof e=="function"?e:e===void 0?DE:pt(+e),t=typeof t=="function"?t:pt(t===void 0?0:+t),r=typeof r=="function"?r:r===void 0?RE:pt(+r);function h(g){var v,b,j,k=(g=Ny(g)).length,S,N=!1,E,A=new Array(k),P=new Array(k);for(o==null&&(c=u(E=f())),v=0;v<=k;++v){if(!(v<k&&a(S=g[v],v,g))===N)if(N=!N)b=v,c.areaStart(),c.lineStart();else{for(c.lineEnd(),c.lineStart(),j=v-1;j>=b;--j)c.point(A[j],P[j]);c.lineEnd(),c.areaEnd()}N&&(A[v]=+e(S,v,g),P[v]=+t(S,v,g),c.point(n?+n(S,v,g):A[v],r?+r(S,v,g):P[v]))}if(E)return c=null,E+""||null}function m(){return LE().defined(a).curve(u).context(o)}return h.x=function(g){return arguments.length?(e=typeof g=="function"?g:pt(+g),n=null,h):e},h.x0=function(g){return arguments.length?(e=typeof g=="function"?g:pt(+g),h):e},h.x1=function(g){return arguments.length?(n=g==null?null:typeof g=="function"?g:pt(+g),h):n},h.y=function(g){return arguments.length?(t=typeof g=="function"?g:pt(+g),r=null,h):t},h.y0=function(g){return arguments.length?(t=typeof g=="function"?g:pt(+g),h):t},h.y1=function(g){return arguments.length?(r=g==null?null:typeof g=="function"?g:pt(+g),h):r},h.lineX0=h.lineY0=function(){return m().x(e).y(t)},h.lineY1=function(){return m().x(e).y(r)},h.lineX1=function(){return m().x(n).y(t)},h.defined=function(g){return arguments.length?(a=typeof g=="function"?g:pt(!!g),h):a},h.curve=function(g){return arguments.length?(u=g,o!=null&&(c=u(o)),h):u},h.context=function(g){return arguments.length?(g==null?o=c=null:c=u(o=g),h):o},h}class $E{constructor(t,r){this._context=t,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function nR(e){return new $E(e,!0)}function iR(e){return new $E(e,!1)}function rf(){}function nf(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function zE(e){this._context=e}zE.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:nf(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:nf(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function aR(e){return new zE(e)}function FE(e){this._context=e}FE.prototype={areaStart:rf,areaEnd:rf,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:nf(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function oR(e){return new FE(e)}function BE(e){this._context=e}BE.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,n=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:nf(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function sR(e){return new BE(e)}function UE(e){this._context=e}UE.prototype={areaStart:rf,areaEnd:rf,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function lR(e){return new UE(e)}function Lw(e){return e<0?-1:1}function $w(e,t,r){var n=e._x1-e._x0,a=t-e._x1,o=(e._y1-e._y0)/(n||a<0&&-0),u=(r-e._y1)/(a||n<0&&-0),c=(o*a+u*n)/(n+a);return(Lw(o)+Lw(u))*Math.min(Math.abs(o),Math.abs(u),.5*Math.abs(c))||0}function zw(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function rg(e,t,r){var n=e._x0,a=e._y0,o=e._x1,u=e._y1,c=(o-n)/3;e._context.bezierCurveTo(n+c,a+c*t,o-c,u-c*r,o,u)}function af(e){this._context=e}af.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:rg(this,this._t0,zw(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,rg(this,zw(this,r=$w(this,e,t)),r);break;default:rg(this,this._t0,r=$w(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function HE(e){this._context=new WE(e)}(HE.prototype=Object.create(af.prototype)).point=function(e,t){af.prototype.point.call(this,t,e)};function WE(e){this._context=e}WE.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,n,a,o){this._context.bezierCurveTo(t,e,n,r,o,a)}};function uR(e){return new af(e)}function cR(e){return new HE(e)}function KE(e){this._context=e}KE.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var n=Fw(e),a=Fw(t),o=0,u=1;u<r;++o,++u)this._context.bezierCurveTo(n[0][o],a[0][o],n[1][o],a[1][o],e[u],t[u]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function Fw(e){var t,r=e.length-1,n,a=new Array(r),o=new Array(r),u=new Array(r);for(a[0]=0,o[0]=2,u[0]=e[0]+2*e[1],t=1;t<r-1;++t)a[t]=1,o[t]=4,u[t]=4*e[t]+2*e[t+1];for(a[r-1]=2,o[r-1]=7,u[r-1]=8*e[r-1]+e[r],t=1;t<r;++t)n=a[t]/o[t-1],o[t]-=n,u[t]-=n*u[t-1];for(a[r-1]=u[r-1]/o[r-1],t=r-2;t>=0;--t)a[t]=(u[t]-a[t+1])/o[t];for(o[r-1]=(e[r]+a[r-1])/2,t=0;t<r-1;++t)o[t]=2*e[t+1]-a[t+1];return[a,o]}function dR(e){return new KE(e)}function ch(e,t){this._context=e,this._t=t}ch.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function fR(e){return new ch(e,.5)}function hR(e){return new ch(e,0)}function mR(e){return new ch(e,1)}function lo(e,t){if((u=e.length)>1)for(var r=1,n,a,o=e[t[0]],u,c=o.length;r<u;++r)for(a=o,o=e[t[r]],n=0;n<c;++n)o[n][1]+=o[n][0]=isNaN(a[n][1])?a[n][0]:a[n][1]}function vv(e){for(var t=e.length,r=new Array(t);--t>=0;)r[t]=t;return r}function pR(e,t){return e[t]}function gR(e){const t=[];return t.key=e,t}function vR(){var e=pt([]),t=vv,r=lo,n=pR;function a(o){var u=Array.from(e.apply(this,arguments),gR),c,f=u.length,h=-1,m;for(const g of o)for(c=0,++h;c<f;++c)(u[c][h]=[0,+n(g,u[c].key,h,o)]).data=g;for(c=0,m=Ny(t(u));c<f;++c)u[m[c]].index=c;return r(u,m),u}return a.keys=function(o){return arguments.length?(e=typeof o=="function"?o:pt(Array.from(o)),a):e},a.value=function(o){return arguments.length?(n=typeof o=="function"?o:pt(+o),a):n},a.order=function(o){return arguments.length?(t=o==null?vv:typeof o=="function"?o:pt(Array.from(o)),a):t},a.offset=function(o){return arguments.length?(r=o??lo,a):r},a}function yR(e,t){if((n=e.length)>0){for(var r,n,a=0,o=e[0].length,u;a<o;++a){for(u=r=0;r<n;++r)u+=e[r][a][1]||0;if(u)for(r=0;r<n;++r)e[r][a][1]/=u}lo(e,t)}}function xR(e,t){if((a=e.length)>0){for(var r=0,n=e[t[0]],a,o=n.length;r<o;++r){for(var u=0,c=0;u<a;++u)c+=e[u][r][1]||0;n[r][1]+=n[r][0]=-c/2}lo(e,t)}}function bR(e,t){if(!(!((u=e.length)>0)||!((o=(a=e[t[0]]).length)>0))){for(var r=0,n=1,a,o,u;n<o;++n){for(var c=0,f=0,h=0;c<u;++c){for(var m=e[t[c]],g=m[n][1]||0,v=m[n-1][1]||0,b=(g-v)/2,j=0;j<c;++j){var k=e[t[j]],S=k[n][1]||0,N=k[n-1][1]||0;b+=S-N}f+=g,h+=b*g}a[n-1][1]+=a[n-1][0]=r,f&&(r-=h/f)}a[n-1][1]+=a[n-1][0]=r,lo(e,t)}}function yv(e){return e==="__proto__"}function GE(e){switch(typeof e){case"number":case"symbol":return!1;case"string":return e.includes(".")||e.includes("[")||e.includes("]")}}function Ey(e){var t;return typeof e=="string"||typeof e=="symbol"?e:Object.is((t=e==null?void 0:e.valueOf)==null?void 0:t.call(e),-0)?"-0":String(e)}function VE(e){if(e==null)return"";if(typeof e=="string")return e;if(Array.isArray(e))return e.map(VE).join(",");const t=String(e);return t==="0"&&Object.is(Number(e),-0)?"-0":t}function Ay(e){if(Array.isArray(e))return e.map(Ey);if(typeof e=="symbol")return[e];e=VE(e);const t=[],r=e.length;if(r===0)return t;let n=0,a="",o="",u=!1;for(e.charCodeAt(0)===46&&t.push("");n<r;){const c=e[n];if(o)c==="\\"&&n+1<r?(n++,a+=e[n]):c===o?o="":a+=c;else if(u)c==='"'||c==="'"?o=c:c==="]"?(u=!1,t.push(a),a=""):a+=c;else if(c==="[")u=!0,a&&(t.push(a),a="");else if(c==="."){a&&(t.push(a),a="");const f=e[n+1];(f===void 0||f===".")&&t.push("")}else a+=c;n++}return a&&t.push(a),t}function bo(e,t,r){if(e==null)return r;switch(typeof t){case"string":{if(yv(t))return r;const n=e[t];return n===void 0?GE(t)&&!Object.hasOwn(e,t)?bo(e,Ay(t),r):r:n}case"number":case"symbol":{typeof t=="number"&&(t=Ey(t));const n=e[t];return n===void 0?r:n}default:{if(Array.isArray(t))return wR(e,t,r);if(Object.is(t==null?void 0:t.valueOf(),-0)?t="-0":t=String(t),yv(t))return r;const n=e[t];return n===void 0?r:n}}}function wR(e,t,r){if(t.length===0)return r;let n=e;for(let a=0;a<t.length;a++){if(n==null||yv(t[a]))return r;n=n[t[a]]}return n===void 0?r:n}var kR=4;function la(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:kR,r=10**t,n=Math.round(e*r)/r;return Object.is(n,-0)?0:n}function Ut(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return e.reduce((a,o,u)=>{var c=r[u-1];return typeof c=="string"?a+c+o:c!==void 0?a+la(c)+o:a+o},"")}var Vr=e=>e===0?0:e>0?1:-1,Fn=e=>typeof e=="number"&&e!=+e,uo=e=>typeof e=="string"&&e.length>1&&e.indexOf("%")===e.length-1,Ee=e=>(typeof e=="number"||e instanceof Number)&&!Fn(e),Bn=e=>Ee(e)||typeof e=="string",jR=0,bu=e=>{var t=++jR;return"".concat(e||"").concat(t)},pa=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!Ee(t)&&typeof t!="string")return n;var o;if(uo(t)){if(r==null)return n;var u=t.indexOf("%");o=r*parseFloat(t.slice(0,u))/100}else o=+t;return Fn(o)&&(o=n),a&&r!=null&&o>r&&(o=r),o},qE=e=>{if(!Array.isArray(e))return!1;for(var t=e.length,r={},n=0;n<t;n++)if(!r[String(e[n])])r[String(e[n])]=!0;else return!0;return!1};function li(e,t,r){return Ee(e)&&Ee(t)?la(e+r*(t-e)):t}function QE(e,t,r){if(!(!e||!e.length))return e.find(n=>n&&(typeof t=="function"?t(n):bo(n,t))===r)}var Gt=e=>e===null||typeof e>"u",Cy=e=>Gt(e)?e:"".concat(e.charAt(0).toUpperCase()).concat(e.slice(1));function jr(e){return e!=null}function Vs(){}var YE=e=>"radius"in e&&"startAngle"in e&&"endAngle"in e,Py=(e,t)=>{if(!e||typeof e=="function"||typeof e=="boolean")return null;var r=e;if(y.isValidElement(e)&&(r=e.props),typeof r!="object"&&typeof r!="function")return null;var n={};return Object.keys(r).forEach(a=>{Sy(a)&&typeof r[a]=="function"&&(n[a]=(o=>r[a](r,o)))}),n},SR=(e,t,r)=>n=>(e(t,r,n),null),NR=(e,t,r)=>{if(e===null||typeof e!="object"&&typeof e!="function")return null;var n=null;return Object.keys(e).forEach(a=>{var o=e[a];Sy(a)&&typeof o=="function"&&(n||(n={}),n[a]=SR(o,t,r))}),n};function Bw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ER(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Bw(Object(r),!0).forEach(function(n){AR(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Bw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function AR(e,t,r){return(t=CR(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function CR(e){var t=PR(e,"string");return typeof t=="symbol"?t:t+""}function PR(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Jr(e,t){var r=ER({},e),n=t,a=Object.keys(t),o=a.reduce((u,c)=>(u[c]===void 0&&n[c]!==void 0&&(u[c]=n[c]),u),r);return o}function OR(e,t){const r=new Map;for(let n=0;n<e.length;n++){const a=e[n],o=t(a,n,e);r.has(o)||r.set(o,a)}return Array.from(r.values())}function _R(e,t){return function(...r){return e.apply(this,r.slice(0,t))}}function XE(e){return e}function MR(e){return function(t){return bo(t,e)}}function xv(e){return e==null||typeof e!="object"&&typeof e!="function"}function IR(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function TR(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}function Oy(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const DR="[object RegExp]",ZE="[object String]",JE="[object Number]",e5="[object Boolean]",t5="[object Arguments]",RR="[object Symbol]",LR="[object Date]",$R="[object Map]",zR="[object Set]",FR="[object Array]",BR="[object ArrayBuffer]",UR="[object Object]",HR="[object DataView]",WR="[object Uint8Array]",KR="[object Uint8ClampedArray]",GR="[object Uint16Array]",VR="[object Uint32Array]",qR="[object Int8Array]",QR="[object Int16Array]",YR="[object Int32Array]",XR="[object Float32Array]",ZR="[object Float64Array]",Uw=typeof globalThis=="object"&&globalThis||typeof window=="object"&&window||typeof self=="object"&&self||typeof global=="object"&&global||(function(){return this})();function JR(e){return typeof Uw.Buffer<"u"&&Uw.Buffer.isBuffer(e)}function eL(e,t){return Ua(e,void 0,e,new Map,t)}function Ua(e,t,r,n=new Map,a=void 0){const o=a==null?void 0:a(e,t,r,n);if(o!==void 0)return o;if(xv(e))return e;if(n.has(e))return n.get(e);if(Array.isArray(e)){const u=new Array(e.length);n.set(e,u);for(let c=0;c<e.length;c++)u[c]=Ua(e[c],c,r,n,a);return Object.hasOwn(e,"index")&&(u.index=e.index),Object.hasOwn(e,"input")&&(u.input=e.input),u}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){const u=new RegExp(e.source,e.flags);return u.lastIndex=e.lastIndex,u}if(e instanceof Map){const u=new Map;n.set(e,u);for(const[c,f]of e)u.set(c,Ua(f,c,r,n,a));return u}if(e instanceof Set){const u=new Set;n.set(e,u);for(const c of e)u.add(Ua(c,void 0,r,n,a));return u}if(JR(e))return e.subarray();if(IR(e)){const u=new(Object.getPrototypeOf(e)).constructor(e.length);n.set(e,u);for(let c=0;c<e.length;c++)u[c]=Ua(e[c],c,r,n,a);return u}if(e instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&e instanceof SharedArrayBuffer)return e.slice(0);if(e instanceof DataView){const u=new DataView(e.buffer.slice(0),e.byteOffset,e.byteLength);return n.set(e,u),cn(u,e,r,n,a),u}if(typeof File<"u"&&e instanceof File){const u=new File([e],e.name,{type:e.type});return n.set(e,u),cn(u,e,r,n,a),u}if(typeof Blob<"u"&&e instanceof Blob){const u=new Blob([e],{type:e.type});return n.set(e,u),cn(u,e,r,n,a),u}if(e instanceof Error){const u=structuredClone(e);return n.set(e,u),u.message=e.message,u.name=e.name,u.stack=e.stack,u.cause=e.cause,u.constructor=e.constructor,cn(u,e,r,n,a),u}if(e instanceof Boolean){const u=new Boolean(e.valueOf());return n.set(e,u),cn(u,e,r,n,a),u}if(e instanceof Number){const u=new Number(e.valueOf());return n.set(e,u),cn(u,e,r,n,a),u}if(e instanceof String){const u=new String(e.valueOf());return n.set(e,u),cn(u,e,r,n,a),u}if(typeof e=="object"&&tL(e)){const u=Object.create(Object.getPrototypeOf(e));return n.set(e,u),cn(u,e,r,n,a),u}return e}function cn(e,t,r=e,n,a){const o=[...Object.keys(t),...TR(t)];for(let u=0;u<o.length;u++){const c=o[u],f=Object.getOwnPropertyDescriptor(e,c);(f==null||f.writable)&&(e[c]=Ua(t[c],c,r,n,a))}}function tL(e){switch(Oy(e)){case t5:case FR:case BR:case HR:case e5:case LR:case XR:case ZR:case qR:case QR:case YR:case $R:case JE:case UR:case DR:case zR:case ZE:case RR:case WR:case KR:case GR:case VR:return!0;default:return!1}}function rL(e){return Ua(e,void 0,e,new Map,void 0)}function Hd(e,t){return e===t||Number.isNaN(e)&&Number.isNaN(t)}function r5(e){return e!==null&&(typeof e=="object"||typeof e=="function")}function n5(e,t,r){return typeof r!="function"?n5(e,t,()=>{}):bv(e,t,function n(a,o,u,c,f,h){const m=r(a,o,u,c,f,h);return m!==void 0?!!m:bv(a,o,n,h,!1)},new Map,!0)}function bv(e,t,r,n,a=!1){if(t===e)return!0;switch(typeof t){case"object":return nL(e,t,r,n);case"function":return Object.keys(t).length>0?bv(e,{...t},r,n,a):Hd(e,t);default:return r5(e)&&a?typeof t=="string"?t==="":!0:Hd(e,t)}}function nL(e,t,r,n){if(t==null)return!0;if(Array.isArray(t))return i5(e,t,r,n);if(t instanceof Map)return iL(e,t,r,n);if(t instanceof Set)return aL(e,t,r,n);const a=Object.keys(t);if(e==null||xv(e))return a.length===0;if(a.length===0)return!0;if(n!=null&&n.has(t))return n.get(t)===e;n==null||n.set(t,e);try{for(let o=0;o<a.length;o++){const u=a[o];if(!xv(e)&&!(u in e)||t[u]===void 0&&e[u]!==void 0||t[u]===null&&e[u]!==null||!r(e[u],t[u],u,e,t,n))return!1}return!0}finally{n==null||n.delete(t)}}function iL(e,t,r,n){if(t.size===0)return!0;if(!(e instanceof Map))return!1;for(const[a,o]of t.entries())if(r(e.get(a),o,a,e,t,n)===!1)return!1;return!0}function i5(e,t,r,n){if(t.length===0)return!0;if(!Array.isArray(e))return!1;const a=new Set;for(let o=0;o<t.length;o++){const u=t[o];let c=!1;for(let f=0;f<e.length;f++){if(a.has(f))continue;const h=e[f];let m=!1;if(r(h,u,o,e,t,n)&&(m=!0),m){a.add(f),c=!0;break}}if(!c)return!1}return!0}function aL(e,t,r,n){return t.size===0?!0:e instanceof Set?i5([...e],[...t],r,n):!1}function a5(e,t){return n5(e,t,()=>{})}function oL(e){return e=rL(e),t=>a5(t,e)}function sL(e,t){return eL(e,(r,n,a,o)=>{if(typeof e=="object"){if(Oy(e)==="[object Object]"&&typeof e.constructor!="function"){const u={};return o.set(e,u),cn(u,e,a,o),u}switch(Object.prototype.toString.call(e)){case JE:case ZE:case e5:{const u=new e.constructor(e==null?void 0:e.valueOf());return cn(u,e),u}case t5:{const u={};return cn(u,e),u.length=e.length,u[Symbol.iterator]=e[Symbol.iterator],u}default:return}}})}function lL(e){return sL(e)}const uL=/^(?:0|[1-9]\d*)$/;function o5(e,t=Number.MAX_SAFE_INTEGER){switch(typeof e){case"number":return Number.isInteger(e)&&e>=0&&e<t;case"symbol":return!1;case"string":return uL.test(e)}}function cL(e){return e!==null&&typeof e=="object"&&Oy(e)==="[object Arguments]"}function dL(e,t){let r;if(Array.isArray(t)?r=t:typeof t=="string"&&GE(t)&&(e==null?void 0:e[t])==null?r=Ay(t):r=[t],r.length===0)return!1;let n=e;for(let a=0;a<r.length;a++){const o=r[a];if((n==null||!Object.hasOwn(n,o))&&!((Array.isArray(n)||cL(n))&&o5(o)&&o<n.length))return!1;n=n[o]}return!0}function fL(e,t){switch(typeof e){case"object":Object.is(e==null?void 0:e.valueOf(),-0)&&(e="-0");break;case"number":e=Ey(e);break}return t=lL(t),function(r){const n=bo(r,e);return n===void 0?dL(r,e):t===void 0?n===void 0:a5(n,t)}}function hL(e){if(e==null)return XE;switch(typeof e){case"function":return e;case"object":return Array.isArray(e)&&e.length===2?fL(e[0],e[1]):oL(e);case"string":case"symbol":case"number":return MR(e)}}function mL(e){return Number.isSafeInteger(e)&&e>=0}function s5(e){return e!=null&&typeof e!="function"&&mL(e.length)}function pL(e){return typeof e=="object"&&e!==null}function gL(e){return pL(e)&&s5(e)}function Hw(e,t=XE){return gL(e)?OR(Array.from(e),_R(hL(t),1)):[]}function vL(e,t,r){return t===!0?Hw(e,r):typeof t=="function"?Hw(e,t):e}var ng={exports:{}},ig={},ag={exports:{}},og={};/**
|
||
* @license React
|
||
* use-sync-external-store-shim.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var Ww;function yL(){if(Ww)return og;Ww=1;var e=Ws();function t(g,v){return g===v&&(g!==0||1/g===1/v)||g!==g&&v!==v}var r=typeof Object.is=="function"?Object.is:t,n=e.useState,a=e.useEffect,o=e.useLayoutEffect,u=e.useDebugValue;function c(g,v){var b=v(),j=n({inst:{value:b,getSnapshot:v}}),k=j[0].inst,S=j[1];return o(function(){k.value=b,k.getSnapshot=v,f(k)&&S({inst:k})},[g,b,v]),a(function(){return f(k)&&S({inst:k}),g(function(){f(k)&&S({inst:k})})},[g]),u(b),b}function f(g){var v=g.getSnapshot;g=g.value;try{var b=v();return!r(g,b)}catch{return!0}}function h(g,v){return v()}var m=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?h:c;return og.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:m,og}var Kw;function xL(){return Kw||(Kw=1,ag.exports=yL()),ag.exports}/**
|
||
* @license React
|
||
* use-sync-external-store-shim/with-selector.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var Gw;function bL(){if(Gw)return ig;Gw=1;var e=Ws(),t=xL();function r(h,m){return h===m&&(h!==0||1/h===1/m)||h!==h&&m!==m}var n=typeof Object.is=="function"?Object.is:r,a=t.useSyncExternalStore,o=e.useRef,u=e.useEffect,c=e.useMemo,f=e.useDebugValue;return ig.useSyncExternalStoreWithSelector=function(h,m,g,v,b){var j=o(null);if(j.current===null){var k={hasValue:!1,value:null};j.current=k}else k=j.current;j=c(function(){function N(O){if(!E){if(E=!0,A=O,O=v(O),b!==void 0&&k.hasValue){var D=k.value;if(b(D,O))return P=D}return P=O}if(D=P,n(A,O))return D;var B=v(O);return b!==void 0&&b(D,B)?(A=O,D):(A=O,P=B)}var E=!1,A,P,_=g===void 0?null:g;return[function(){return N(m())},_===null?void 0:function(){return N(_())}]},[m,g,v,b]);var S=a(h,j[0],j[1]);return u(function(){k.hasValue=!0,k.value=S},[S]),f(S),S},ig}var Vw;function wL(){return Vw||(Vw=1,ng.exports=bL()),ng.exports}var kL=wL(),_y=y.createContext(null),jL=e=>e,jt=()=>{var e=y.useContext(_y);return e?e.store.dispatch:jL},Wd=()=>{},SL=()=>Wd,NL=(e,t)=>e===t;function Me(e){var t=y.useContext(_y),r=y.useMemo(()=>t?n=>{if(n!=null)return e(n)}:Wd,[t,e]);return kL.useSyncExternalStoreWithSelector(t?t.subscription.addNestedSub:SL,t?t.store.getState:Wd,t?t.store.getState:Wd,r,NL)}function EL(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function AL(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(r=>typeof r=="function")){const r=e.map(n=>typeof n=="function"?`function ${n.name||"unnamed"}()`:typeof n).join(", ");throw new TypeError(`${t}[${r}]`)}}var qw=e=>Array.isArray(e)?e:[e];function CL(e){const t=Array.isArray(e[0])?e[0]:e;return AL(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function PL(e,t){const r=[],{length:n}=e;for(let a=0;a<n;a++)r.push(e[a].apply(null,t));return r}var OL=class{constructor(e){this.value=e}deref(){return this.value}},_L=()=>typeof WeakRef>"u"?OL:WeakRef,l5=_L(),ML=0,Qw=1;function Nd(){return{s:ML,v:void 0,o:null,p:null}}function IL(e){return e instanceof l5?e.deref():e}function u5(e,t={}){let r=Nd();const{resultEqualityCheck:n}=t;let a,o=0;function u(){let c=r;const{length:f}=arguments;for(let g=0,v=f;g<v;g++){const b=arguments[g];if(typeof b=="function"||typeof b=="object"&&b!==null){let j=c.o;j===null&&(c.o=j=new WeakMap);const k=j.get(b);k===void 0?(c=Nd(),j.set(b,c)):c=k}else{let j=c.p;j===null&&(c.p=j=new Map);const k=j.get(b);k===void 0?(c=Nd(),j.set(b,c)):c=k}}const h=c;let m;if(c.s===Qw)m=c.v;else if(m=e.apply(null,arguments),o++,n){const g=IL(a);g!=null&&n(g,m)&&(m=g,o!==0&&o--),a=typeof m=="object"&&m!==null||typeof m=="function"?new l5(m):m}return h.s=Qw,h.v=m,m}return u.clearCache=()=>{r=Nd(),u.resetResultsCount()},u.resultsCount=()=>o,u.resetResultsCount=()=>{o=0},u}function TL(e,...t){const r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,n=(...a)=>{let o=0,u=0,c,f={},h=a.pop();typeof h=="object"&&(f=h,h=a.pop()),EL(h,`createSelector expects an output function after the inputs, but received: [${typeof h}]`);const m={...r,...f},{memoize:g,memoizeOptions:v=[],argsMemoize:b=u5,argsMemoizeOptions:j=[]}=m,k=qw(v),S=qw(j),N=CL(a),E=g(function(){return o++,h.apply(null,arguments)},...k),A=b(function(){u++;const _=PL(N,arguments);return c=E.apply(null,_),c},...S);return Object.assign(A,{resultFunc:h,memoizedResultFunc:E,dependencies:N,dependencyRecomputations:()=>u,resetDependencyRecomputations:()=>{u=0},lastResult:()=>c,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:g,argsMemoize:b})};return Object.assign(n,{withTypes:()=>n}),n}var q=TL(u5);function DL(e,t=1){const r=[],n=Math.floor(t),a=(o,u)=>{for(let c=0;c<o.length;c++){const f=o[c];Array.isArray(f)&&u<n?a(f,u+1):r.push(f)}};return a(e,0),r}function wv(e,t,r){return r5(r)&&(typeof t=="number"&&s5(r)&&o5(t)&&t<r.length||typeof t=="string"&&t in r)?Hd(r[t],e):!1}function Yw(e){return typeof e=="symbol"?1:e===null?2:e===void 0?3:e!==e?4:0}const RL=(e,t,r)=>{if(e!==t){const n=Yw(e),a=Yw(t);if(n===a&&n===0){if(e<t)return r==="desc"?1:-1;if(e>t)return r==="desc"?-1:1}return r==="desc"?a-n:n-a}return 0};function c5(e){return typeof e=="symbol"||e instanceof Symbol}const LL=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,$L=/^\w*$/;function zL(e,t){return Array.isArray(e)?!1:typeof e=="number"||typeof e=="boolean"||e==null||c5(e)?!0:typeof e=="string"&&($L.test(e)||!LL.test(e))||t!=null}function FL(e,t,r,n){if(e==null)return[];r=r,Array.isArray(e)||(e=Object.values(e)),Array.isArray(t)||(t=t==null?[null]:[t]),t.length===0&&(t=[null]),Array.isArray(r)||(r=r==null?[]:[r]),r=r.map(c=>String(c));const a=(c,f)=>{let h=c;for(let m=0;m<f.length&&h!=null;++m)h=h[f[m]];return h},o=(c,f)=>f==null||c==null?f:typeof c=="object"&&"key"in c?Object.hasOwn(f,c.key)?f[c.key]:a(f,c.path):typeof c=="function"?c(f):Array.isArray(c)?a(f,c):typeof f=="object"?f[c]:f,u=t.map(c=>(Array.isArray(c)&&c.length===1&&(c=c[0]),c==null||typeof c=="function"||Array.isArray(c)||zL(c)?c:{key:c,path:Ay(c)}));return e.map(c=>({original:c,criteria:u.map(f=>o(f,c))})).slice().sort((c,f)=>{for(let h=0;h<u.length;h++){const m=RL(c.criteria[h],f.criteria[h],r[h]);if(m!==0)return m}return 0}).map(c=>c.original)}function dh(e,...t){const r=t.length;return r>1&&wv(e,t[0],t[1])?t=[]:r>2&&wv(t[0],t[1],t[2])&&(t=[t[0]]),FL(e,DL(t),["asc"])}var d5=e=>e.legend.settings,BL=e=>e.legend.size,UL=e=>e.legend.payload;q([UL,d5],(e,t)=>{var r=t.itemSorter,n=e.flat(1);return r?dh(n,r):n});function HL(e,t){return VL(e)||GL(e,t)||KL(e,t)||WL()}function WL(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function KL(e,t){if(e){if(typeof e=="string")return Xw(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Xw(e,t):void 0}}function Xw(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function GL(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function VL(e){if(Array.isArray(e))return e}var Ed=1;function Zw(e,t){return Math.abs(e.height-t.height)>Ed||Math.abs(e.left-t.left)>Ed||Math.abs(e.top-t.top)>Ed||Math.abs(e.width-t.width)>Ed}function Jw(e){var t=e.getBoundingClientRect();return{height:t.height,left:t.left,top:t.top,width:t.width}}function qL(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=y.useState({height:0,left:0,top:0,width:0}),r=HL(t,2),n=r[0],a=r[1],o=y.useRef(null),u=y.useRef(n);u.current=n;var c=y.useCallback(f=>{if(o.current!=null&&(o.current.disconnect(),o.current=null),f!=null){var h=Jw(f);if(Zw(h,u.current)&&a(h),typeof ResizeObserver<"u"){var m=new ResizeObserver(()=>{var g=Jw(f);Zw(g,u.current)&&a(g)});m.observe(f),o.current=m}}},[...e]);return y.useEffect(()=>()=>{var f;(f=o.current)===null||f===void 0||f.disconnect()},[]),[n,c]}function Bt(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var QL=typeof Symbol=="function"&&Symbol.observable||"@@observable",ek=QL,sg=()=>Math.random().toString(36).substring(7).split("").join("."),YL={INIT:`@@redux/INIT${sg()}`,REPLACE:`@@redux/REPLACE${sg()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${sg()}`},of=YL;function My(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function f5(e,t,r){if(typeof e!="function")throw new Error(Bt(2));if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(Bt(0));if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(Bt(1));return r(f5)(e,t)}let n=e,a=t,o=new Map,u=o,c=0,f=!1;function h(){u===o&&(u=new Map,o.forEach((S,N)=>{u.set(N,S)}))}function m(){if(f)throw new Error(Bt(3));return a}function g(S){if(typeof S!="function")throw new Error(Bt(4));if(f)throw new Error(Bt(5));let N=!0;h();const E=c++;return u.set(E,S),function(){if(N){if(f)throw new Error(Bt(6));N=!1,h(),u.delete(E),o=null}}}function v(S){if(!My(S))throw new Error(Bt(7));if(typeof S.type>"u")throw new Error(Bt(8));if(typeof S.type!="string")throw new Error(Bt(17));if(f)throw new Error(Bt(9));try{f=!0,a=n(a,S)}finally{f=!1}return(o=u).forEach(E=>{E()}),S}function b(S){if(typeof S!="function")throw new Error(Bt(10));n=S,v({type:of.REPLACE})}function j(){const S=g;return{subscribe(N){if(typeof N!="object"||N===null)throw new Error(Bt(11));function E(){const P=N;P.next&&P.next(m())}return E(),{unsubscribe:S(E)}},[ek](){return this}}}return v({type:of.INIT}),{dispatch:v,subscribe:g,getState:m,replaceReducer:b,[ek]:j}}function XL(e){Object.keys(e).forEach(t=>{const r=e[t];if(typeof r(void 0,{type:of.INIT})>"u")throw new Error(Bt(12));if(typeof r(void 0,{type:of.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Bt(13))})}function h5(e){const t=Object.keys(e),r={};for(let o=0;o<t.length;o++){const u=t[o];typeof e[u]=="function"&&(r[u]=e[u])}const n=Object.keys(r);let a;try{XL(r)}catch(o){a=o}return function(u={},c){if(a)throw a;let f=!1;const h={};for(let m=0;m<n.length;m++){const g=n[m],v=r[g],b=u[g],j=v(b,c);if(typeof j>"u")throw c&&c.type,new Error(Bt(14));h[g]=j,f=f||j!==b}return f=f||n.length!==Object.keys(u).length,f?h:u}}function sf(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...n)=>t(r(...n)))}function ZL(...e){return t=>(r,n)=>{const a=t(r,n);let o=()=>{throw new Error(Bt(15))};const u={getState:a.getState,dispatch:(f,...h)=>o(f,...h)},c=e.map(f=>f(u));return o=sf(...c)(a.dispatch),{...a,dispatch:o}}}function m5(e){return My(e)&&"type"in e&&typeof e.type=="string"}var p5=Symbol.for("immer-nothing"),tk=Symbol.for("immer-draftable"),hr=Symbol.for("immer-state");function fn(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Dr=Object,Rs=Dr.getPrototypeOf,lf="constructor",fh="prototype",kv="configurable",uf="enumerable",Kd="writable",wu="value",mi=e=>!!e&&!!e[hr];function yn(e){var t;return e?g5(e)||mh(e)||!!e[tk]||!!((t=e[lf])!=null&&t[tk])||ph(e)||gh(e):!1}var JL=Dr[fh][lf].toString(),rk=new WeakMap;function g5(e){if(!e||!Iy(e))return!1;const t=Rs(e);if(t===null||t===Dr[fh])return!0;const r=Dr.hasOwnProperty.call(t,lf)&&t[lf];if(r===Object)return!0;if(!ls(r))return!1;let n=rk.get(r);return n===void 0&&(n=Function.toString.call(r),rk.set(r,n)),n===JL}function hh(e,t,r=!0){Wu(e)===0?(r?Reflect.ownKeys(e):Dr.keys(e)).forEach(a=>{t(a,e[a],e)}):e.forEach((n,a)=>t(a,n,e))}function Wu(e){const t=e[hr];return t?t.type_:mh(e)?1:ph(e)?2:gh(e)?3:0}var nk=(e,t,r=Wu(e))=>r===2?e.has(t):Dr[fh].hasOwnProperty.call(e,t),jv=(e,t,r=Wu(e))=>r===2?e.get(t):e[t],cf=(e,t,r,n=Wu(e))=>{n===2?e.set(t,r):n===3?e.add(r):e[t]=r};function e$(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}var mh=Array.isArray,ph=e=>e instanceof Map,gh=e=>e instanceof Set,Iy=e=>typeof e=="object",ls=e=>typeof e=="function",lg=e=>typeof e=="boolean";function t$(e){const t=+e;return Number.isInteger(t)&&String(t)===e}var ii=e=>e.copy_||e.base_,Ty=e=>e.modified_?e.copy_:e.base_;function Sv(e,t){if(ph(e))return new Map(e);if(gh(e))return new Set(e);if(mh(e))return Array[fh].slice.call(e);const r=g5(e);if(t===!0||t==="class_only"&&!r){const n=Dr.getOwnPropertyDescriptors(e);delete n[hr];let a=Reflect.ownKeys(n);for(let o=0;o<a.length;o++){const u=a[o],c=n[u];c[Kd]===!1&&(c[Kd]=!0,c[kv]=!0),(c.get||c.set)&&(n[u]={[kv]:!0,[Kd]:!0,[uf]:c[uf],[wu]:e[u]})}return Dr.create(Rs(e),n)}else{const n=Rs(e);if(n!==null&&r)return{...e};const a=Dr.create(n);return Dr.assign(a,e)}}function Dy(e,t=!1){return vh(e)||mi(e)||!yn(e)||(Wu(e)>1&&Dr.defineProperties(e,{set:Ad,add:Ad,clear:Ad,delete:Ad}),Dr.freeze(e),t&&hh(e,(r,n)=>{Dy(n,!0)},!1)),e}function r$(){fn(2)}var Ad={[wu]:r$};function vh(e){return e===null||!Iy(e)?!0:Dr.isFrozen(e)}var df="MapSet",Nv="Patches",ik="ArrayMethods",v5={};function co(e){const t=v5[e];return t||fn(0,e),t}var ak=e=>!!v5[e],ku,y5=()=>ku,n$=(e,t)=>({drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:ak(df)?co(df):void 0,arrayMethodsPlugin_:ak(ik)?co(ik):void 0});function ok(e,t){t&&(e.patchPlugin_=co(Nv),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Ev(e){Av(e),e.drafts_.forEach(i$),e.drafts_=null}function Av(e){e===ku&&(ku=e.parent_)}var sk=e=>ku=n$(ku,e);function i$(e){const t=e[hr];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function lk(e,t){t.unfinalizedDrafts_=t.drafts_.length;const r=t.drafts_[0];if(e!==void 0&&e!==r){r[hr].modified_&&(Ev(t),fn(4)),yn(e)&&(e=uk(t,e));const{patchPlugin_:a}=t;a&&a.generateReplacementPatches_(r[hr].base_,e,t)}else e=uk(t,r);return a$(t,e,!0),Ev(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==p5?e:void 0}function uk(e,t){if(vh(t))return t;const r=t[hr];if(!r)return ff(t,e.handledSet_,e);if(!yh(r,e))return t;if(!r.modified_)return r.base_;if(!r.finalized_){const{callbacks_:n}=r;if(n)for(;n.length>0;)n.pop()(e);w5(r,e)}return r.copy_}function a$(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Dy(t,r)}function x5(e){e.finalized_=!0,e.scope_.unfinalizedDrafts_--}var yh=(e,t)=>e.scope_===t,o$=[];function b5(e,t,r,n){const a=ii(e),o=e.type_;if(n!==void 0&&jv(a,n,o)===t){cf(a,n,r,o);return}if(!e.draftLocations_){const c=e.draftLocations_=new Map;hh(a,(f,h)=>{if(mi(h)){const m=c.get(h)||[];m.push(f),c.set(h,m)}})}const u=e.draftLocations_.get(t)??o$;for(const c of u)cf(a,c,r,o)}function s$(e,t,r){e.callbacks_.push(function(a){var c;const o=t;if(!o||!yh(o,a))return;(c=a.mapSetPlugin_)==null||c.fixSetContents(o);const u=Ty(o);b5(e,o.draft_??o,u,r),w5(o,a)})}function w5(e,t){var n;if(e.modified_&&!e.finalized_&&(e.type_===3||e.type_===1&&e.allIndicesReassigned_||(((n=e.assigned_)==null?void 0:n.size)??0)>0)){const{patchPlugin_:a}=t;if(a){const o=a.getPath(e);o&&a.generatePatches_(e,o,t)}x5(e)}}function l$(e,t,r){const{scope_:n}=e;if(mi(r)){const a=r[hr];yh(a,n)&&a.callbacks_.push(function(){Gd(e);const u=Ty(a);b5(e,r,u,t)})}else yn(r)&&e.callbacks_.push(function(){const o=ii(e);e.type_===3?o.has(r)&&ff(r,n.handledSet_,n):jv(o,t,e.type_)===r&&n.drafts_.length>1&&(e.assigned_.get(t)??!1)===!0&&e.copy_&&ff(jv(e.copy_,t,e.type_),n.handledSet_,n)})}function ff(e,t,r){return!r.immer_.autoFreeze_&&r.unfinalizedDrafts_<1||mi(e)||t.has(e)||!yn(e)||vh(e)||(t.add(e),hh(e,(n,a)=>{if(mi(a)){const o=a[hr];if(yh(o,r)){const u=Ty(o);cf(e,n,u,e.type_),x5(o)}}else yn(a)&&ff(a,t,r)})),e}function u$(e,t){const r=mh(e),n={type_:r?1:0,scope_:t?t.scope_:y5(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0};let a=n,o=hf;r&&(a=[n],o=ju);const{revoke:u,proxy:c}=Proxy.revocable(a,o);return n.draft_=c,n.revoke_=u,[c,n]}var hf={get(e,t){if(t===hr)return e;let r=e.scope_.arrayMethodsPlugin_;const n=e.type_===1&&typeof t=="string";if(n&&r!=null&&r.isArrayOperationMethod(t))return r.createMethodInterceptor(e,t);const a=ii(e);if(!nk(a,t,e.type_))return c$(e,a,t);const o=a[t];if(e.finalized_||!yn(o)||n&&e.operationMethod&&(r!=null&&r.isMutatingArrayMethod(e.operationMethod))&&t$(t))return o;if(o===ug(e.base_,t)){Gd(e);const u=e.type_===1?+t:t,c=Pv(e.scope_,o,e,u);return e.copy_[u]=c}return o},has(e,t){return t in ii(e)},ownKeys(e){return Reflect.ownKeys(ii(e))},set(e,t,r){const n=k5(ii(e),t);if(n!=null&&n.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){const a=ug(ii(e),t),o=a==null?void 0:a[hr];if(o&&o.base_===r)return e.copy_[t]=r,e.assigned_.set(t,!1),!0;if(e$(r,a)&&(r!==void 0||nk(e.base_,t,e.type_)))return!0;Gd(e),Cv(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_.set(t,!0),l$(e,t,r)),!0},deleteProperty(e,t){return Gd(e),ug(e.base_,t)!==void 0||t in e.base_?(e.assigned_.set(t,!1),Cv(e)):e.assigned_.delete(t),e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const r=ii(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{[Kd]:!0,[kv]:e.type_!==1||t!=="length",[uf]:n[uf],[wu]:r[t]}},defineProperty(){fn(11)},getPrototypeOf(e){return Rs(e.base_)},setPrototypeOf(){fn(12)}},ju={};for(let e in hf){let t=hf[e];ju[e]=function(){const r=arguments;return r[0]=r[0][0],t.apply(this,r)}}ju.deleteProperty=function(e,t){return ju.set.call(this,e,t,void 0)};ju.set=function(e,t,r){return hf.set.call(this,e[0],t,r,e[0])};function ug(e,t){const r=e[hr];return(r?ii(r):e)[t]}function c$(e,t,r){var a;const n=k5(t,r);return n?wu in n?n[wu]:(a=n.get)==null?void 0:a.call(e.draft_):void 0}function k5(e,t){if(!(t in e))return;let r=Rs(e);for(;r;){const n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Rs(r)}}function Cv(e){e.modified_||(e.modified_=!0,e.parent_&&Cv(e.parent_))}function Gd(e){e.copy_||(e.assigned_=new Map,e.copy_=Sv(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var d$=class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(r,n,a)=>{if(ls(r)&&!ls(n)){const u=n;n=r;const c=this;return function(h=u,...m){return c.produce(h,g=>n.call(this,g,...m))}}ls(n)||fn(6),a!==void 0&&!ls(a)&&fn(7);let o;if(yn(r)){const u=sk(this),c=Pv(u,r,void 0);let f=!0;try{o=n(c),f=!1}finally{f?Ev(u):Av(u)}return ok(u,a),lk(o,u)}else if(!r||!Iy(r)){if(o=n(r),o===void 0&&(o=r),o===p5&&(o=void 0),this.autoFreeze_&&Dy(o,!0),a){const u=[],c=[];co(Nv).generateReplacementPatches_(r,o,{patches_:u,inversePatches_:c}),a(u,c)}return o}else fn(1,r)},this.produceWithPatches=(r,n)=>{if(ls(r))return(c,...f)=>this.produceWithPatches(c,h=>r(h,...f));let a,o;return[this.produce(r,n,(c,f)=>{a=c,o=f}),a,o]},lg(t==null?void 0:t.autoFreeze)&&this.setAutoFreeze(t.autoFreeze),lg(t==null?void 0:t.useStrictShallowCopy)&&this.setUseStrictShallowCopy(t.useStrictShallowCopy),lg(t==null?void 0:t.useStrictIteration)&&this.setUseStrictIteration(t.useStrictIteration)}createDraft(t){yn(t)||fn(8),mi(t)&&(t=qr(t));const r=sk(this),n=Pv(r,t,void 0);return n[hr].isManual_=!0,Av(r),n}finishDraft(t,r){const n=t&&t[hr];(!n||!n.isManual_)&&fn(9);const{scope_:a}=n;return ok(a,r),lk(void 0,a)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}setUseStrictIteration(t){this.useStrictIteration_=t}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(t,r){let n;for(n=r.length-1;n>=0;n--){const o=r[n];if(o.path.length===0&&o.op==="replace"){t=o.value;break}}n>-1&&(r=r.slice(n+1));const a=co(Nv).applyPatches_;return mi(t)?a(t,r):this.produce(t,o=>a(o,r))}};function Pv(e,t,r,n){const[a,o]=ph(t)?co(df).proxyMap_(t,r):gh(t)?co(df).proxySet_(t,r):u$(t,r);return((r==null?void 0:r.scope_)??y5()).drafts_.push(a),o.callbacks_=(r==null?void 0:r.callbacks_)??[],o.key_=n,r&&n!==void 0?s$(r,o,n):o.callbacks_.push(function(f){var m;(m=f.mapSetPlugin_)==null||m.fixSetContents(o);const{patchPlugin_:h}=f;o.modified_&&h&&h.generatePatches_(o,[],f)}),a}function qr(e){return mi(e)||fn(10,e),j5(e)}function j5(e){if(!yn(e)||vh(e))return e;const t=e[hr];let r,n=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Sv(e,t.scope_.immer_.useStrictShallowCopy_),n=t.scope_.immer_.shouldUseStrictIteration()}else r=Sv(e,!0);return hh(r,(a,o)=>{cf(r,a,j5(o))},n),t&&(t.finalized_=!1),r}var f$=new d$,S5=f$.produce;function N5(e){return({dispatch:r,getState:n})=>a=>o=>typeof o=="function"?o(r,n,e):a(o)}var h$=N5(),m$=N5,p$=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?sf:sf.apply(null,arguments)};function Lr(e,t){function r(...n){if(t){let a=t(...n);if(!a)throw new Error(Rr(0));return{type:e,payload:a.payload,..."meta"in a&&{meta:a.meta},..."error"in a&&{error:a.error}}}return{type:e,payload:n[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=n=>m5(n)&&n.type===e,r}var E5=class su extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,su.prototype)}static get[Symbol.species](){return su}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new su(...t[0].concat(this)):new su(...t.concat(this))}};function ck(e){return yn(e)?S5(e,()=>{}):e}function Cd(e,t,r){return e.has(t)?e.get(t):e.set(t,r(t)).get(t)}function g$(e){return typeof e=="boolean"}var v$=()=>function(t){const{thunk:r=!0,immutableCheck:n=!0,serializableCheck:a=!0,actionCreatorCheck:o=!0}=t??{};let u=new E5;return r&&(g$(r)?u.push(h$):u.push(m$(r.extraArgument))),u},A5="RTK_autoBatch",ot=()=>e=>({payload:e,meta:{[A5]:!0}}),dk=e=>t=>{setTimeout(t,e)},y$=(e,t)=>r=>{let n=!1;const a=()=>{n||(n=!0,cancelAnimationFrame(o),clearTimeout(u),r())},o=e(a),u=setTimeout(a,t)},C5=(e={type:"raf"})=>t=>(...r)=>{const n=t(...r);let a=!0,o=!1,u=!1;const c=new Set,f=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?y$(window.requestAnimationFrame,100):dk(10):e.type==="callback"?e.queueNotification:dk(e.timeout),h=()=>{u=!1,o&&(o=!1,c.forEach(m=>m()))};return Object.assign({},n,{subscribe(m){const g=()=>a&&m(),v=n.subscribe(g);return c.add(m),()=>{v(),c.delete(m)}},dispatch(m){var g;try{return a=!((g=m==null?void 0:m.meta)!=null&&g[A5]),o=!a,o&&(u||(u=!0,f(h))),n.dispatch(m)}finally{a=!0}}})},x$=e=>function(r){const{autoBatch:n=!0}=r??{};let a=new E5(e);return n&&a.push(C5(typeof n=="object"?n:void 0)),a};function b$(e){const t=v$(),{reducer:r=void 0,middleware:n,devTools:a=!0,preloadedState:o=void 0,enhancers:u=void 0}=e||{};let c;if(typeof r=="function")c=r;else if(My(r))c=h5(r);else throw new Error(Rr(1));let f;typeof n=="function"?f=n(t):f=t();let h=sf;a&&(h=p$({trace:!1,...typeof a=="object"&&a}));const m=ZL(...f),g=x$(m);let v=typeof u=="function"?u(g):g();const b=h(...v);return f5(c,o,b)}function P5(e){const t={},r=[];let n;const a={addCase(o,u){const c=typeof o=="string"?o:o.type;if(!c)throw new Error(Rr(28));if(c in t)throw new Error(Rr(29));return t[c]=u,a},addAsyncThunk(o,u){return u.pending&&(t[o.pending.type]=u.pending),u.rejected&&(t[o.rejected.type]=u.rejected),u.fulfilled&&(t[o.fulfilled.type]=u.fulfilled),u.settled&&r.push({matcher:o.settled,reducer:u.settled}),a},addMatcher(o,u){return r.push({matcher:o,reducer:u}),a},addDefaultCase(o){return n=o,a}};return e(a),[t,r,n]}function w$(e){return typeof e=="function"}function k$(e,t){let[r,n,a]=P5(t),o;if(w$(e))o=()=>ck(e());else{const c=ck(e);o=()=>c}function u(c=o(),f){let h=[r[f.type],...n.filter(({matcher:m})=>m(f)).map(({reducer:m})=>m)];return h.filter(m=>!!m).length===0&&(h=[a]),h.reduce((m,g)=>{if(g)if(mi(m)){const b=g(m,f);return b===void 0?m:b}else{if(yn(m))return S5(m,v=>g(v,f));{const v=g(m,f);if(v===void 0){if(m===null)return m;throw Error("A case reducer on a non-draftable value must not return undefined")}return v}}return m},c)}return u.getInitialState=o,u}var j$="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",S$=(e=21)=>{let t="",r=e;for(;r--;)t+=j$[Math.random()*64|0];return t},N$=Symbol.for("rtk-slice-createasyncthunk");function E$(e,t){return`${e}/${t}`}function A$({creators:e}={}){var r;const t=(r=e==null?void 0:e.asyncThunk)==null?void 0:r[N$];return function(a){const{name:o,reducerPath:u=o}=a;if(!o)throw new Error(Rr(11));const c=(typeof a.reducers=="function"?a.reducers(P$()):a.reducers)||{},f=Object.keys(c),h={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},m={addCase(P,_){const O=typeof P=="string"?P:P.type;if(!O)throw new Error(Rr(12));if(O in h.sliceCaseReducersByType)throw new Error(Rr(13));return h.sliceCaseReducersByType[O]=_,m},addMatcher(P,_){return h.sliceMatchers.push({matcher:P,reducer:_}),m},exposeAction(P,_){return h.actionCreators[P]=_,m},exposeCaseReducer(P,_){return h.sliceCaseReducersByName[P]=_,m}};f.forEach(P=>{const _=c[P],O={reducerName:P,type:E$(o,P),createNotation:typeof a.reducers=="function"};_$(_)?I$(O,_,m,t):O$(O,_,m)});function g(){const[P={},_=[],O=void 0]=typeof a.extraReducers=="function"?P5(a.extraReducers):[a.extraReducers],D={...P,...h.sliceCaseReducersByType};return k$(a.initialState,B=>{for(let F in D)B.addCase(F,D[F]);for(let F of h.sliceMatchers)B.addMatcher(F.matcher,F.reducer);for(let F of _)B.addMatcher(F.matcher,F.reducer);O&&B.addDefaultCase(O)})}const v=P=>P,b=new Map,j=new WeakMap;let k;function S(P,_){return k||(k=g()),k(P,_)}function N(){return k||(k=g()),k.getInitialState()}function E(P,_=!1){function O(B){let F=B[P];return typeof F>"u"&&_&&(F=Cd(j,O,N)),F}function D(B=v){const F=Cd(b,_,()=>new WeakMap);return Cd(F,B,()=>{const z={};for(const[Y,U]of Object.entries(a.selectors??{}))z[Y]=C$(U,B,()=>Cd(j,B,N),_);return z})}return{reducerPath:P,getSelectors:D,get selectors(){return D(O)},selectSlice:O}}const A={name:o,reducer:S,actions:h.actionCreators,caseReducers:h.sliceCaseReducersByName,getInitialState:N,...E(u),injectInto(P,{reducerPath:_,...O}={}){const D=_??u;return P.inject({reducerPath:D,reducer:S},O),{...A,...E(D,!0)}}};return A}}function C$(e,t,r,n){function a(o,...u){let c=t(o);return typeof c>"u"&&n&&(c=r()),e(c,...u)}return a.unwrapped=e,a}var sr=A$();function P$(){function e(t,r){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...r}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...r){return t(...r)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,r){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:r}},asyncThunk:e}}function O$({type:e,reducerName:t,createNotation:r},n,a){let o,u;if("reducer"in n){if(r&&!M$(n))throw new Error(Rr(17));o=n.reducer,u=n.prepare}else o=n;a.addCase(e,o).exposeCaseReducer(t,o).exposeAction(t,u?Lr(e,u):Lr(e))}function _$(e){return e._reducerDefinitionType==="asyncThunk"}function M$(e){return e._reducerDefinitionType==="reducerWithPrepare"}function I$({type:e,reducerName:t},r,n,a){if(!a)throw new Error(Rr(18));const{payloadCreator:o,fulfilled:u,pending:c,rejected:f,settled:h,options:m}=r,g=a(e,o,m);n.exposeAction(t,g),u&&n.addCase(g.fulfilled,u),c&&n.addCase(g.pending,c),f&&n.addCase(g.rejected,f),h&&n.addMatcher(g.settled,h),n.exposeCaseReducer(t,{fulfilled:u||Pd,pending:c||Pd,rejected:f||Pd,settled:h||Pd})}function Pd(){}var T$="task",O5="listener",_5="completed",Ry="cancelled",D$=`task-${Ry}`,R$=`task-${_5}`,Ov=`${O5}-${Ry}`,L$=`${O5}-${_5}`,xh=class{constructor(e){qo(this,"code");qo(this,"name","TaskAbortError");qo(this,"message");this.code=e,this.message=`${T$} ${Ry} (reason: ${e})`}},Ly=(e,t)=>{if(typeof e!="function")throw new TypeError(Rr(32))},mf=()=>{},M5=(e,t=mf)=>(e.catch(t),e),I5=(e,t)=>(e.addEventListener("abort",t,{once:!0}),()=>e.removeEventListener("abort",t)),no=e=>{if(e.aborted)throw new xh(e.reason)};function T5(e,t){let r=mf;return new Promise((n,a)=>{const o=()=>a(new xh(e.reason));if(e.aborted){o();return}r=I5(e,o),t.finally(()=>r()).then(n,a)}).finally(()=>{r=mf})}var $$=async(e,t)=>{try{return await Promise.resolve(),{status:"ok",value:await e()}}catch(r){return{status:r instanceof xh?"cancelled":"rejected",error:r}}finally{t==null||t()}},pf=e=>t=>M5(T5(e,t).then(r=>(no(e),r))),D5=e=>{const t=pf(e);return r=>t(new Promise(n=>setTimeout(n,r)))},{assign:ms}=Object,fk={},bh="listenerMiddleware",z$=(e,t)=>{const r=n=>I5(e,()=>n.abort(e.reason));return(n,a)=>{Ly(n);const o=new AbortController;r(o);const u=$$(async()=>{no(e),no(o.signal);const c=await n({pause:pf(o.signal),delay:D5(o.signal),signal:o.signal});return no(o.signal),c},()=>o.abort(R$));return a!=null&&a.autoJoin&&t.push(u.catch(mf)),{result:pf(e)(u),cancel(){o.abort(D$)}}}},F$=(e,t)=>{const r=async(n,a)=>{no(t);let o=()=>{};const c=[new Promise((f,h)=>{let m=e({predicate:n,effect:(g,v)=>{v.unsubscribe(),f([g,v.getState(),v.getOriginalState()])}});o=()=>{m(),h()}})];a!=null&&c.push(new Promise(f=>setTimeout(f,a,null)));try{const f=await T5(t,Promise.race(c));return no(t),f}finally{o()}};return((n,a)=>M5(r(n,a)))},R5=e=>{let{type:t,actionCreator:r,matcher:n,predicate:a,effect:o}=e;if(t)a=Lr(t).match;else if(r)t=r.type,a=r.match;else if(n)a=n;else if(!a)throw new Error(Rr(21));return Ly(o),{predicate:a,type:t,effect:o}},L5=ms(e=>{const{type:t,predicate:r,effect:n}=R5(e);return{id:S$(),effect:n,type:t,predicate:r,pending:new Set,unsubscribe:()=>{throw new Error(Rr(22))}}},{withTypes:()=>L5}),hk=(e,t)=>{const{type:r,effect:n,predicate:a}=R5(t);return Array.from(e.values()).find(o=>(typeof r=="string"?o.type===r:o.predicate===a)&&o.effect===n)},_v=e=>{e.pending.forEach(t=>{t.abort(Ov)})},B$=(e,t)=>()=>{for(const r of t.keys())_v(r);e.clear()},mk=(e,t,r)=>{try{e(t,r)}catch(n){setTimeout(()=>{throw n},0)}},$5=ms(Lr(`${bh}/add`),{withTypes:()=>$5}),U$=Lr(`${bh}/removeAll`),z5=ms(Lr(`${bh}/remove`),{withTypes:()=>z5}),H$=(...e)=>{console.error(`${bh}/error`,...e)},Ku=(e={})=>{const t=new Map,r=new Map,n=b=>{const j=r.get(b)??0;r.set(b,j+1)},a=b=>{const j=r.get(b)??1;j===1?r.delete(b):r.set(b,j-1)},{extra:o,onError:u=H$}=e;Ly(u);const c=b=>(b.unsubscribe=()=>t.delete(b.id),t.set(b.id,b),j=>{b.unsubscribe(),j!=null&&j.cancelActive&&_v(b)}),f=(b=>{const j=hk(t,b)??L5(b);return c(j)});ms(f,{withTypes:()=>f});const h=b=>{const j=hk(t,b);return j&&(j.unsubscribe(),b.cancelActive&&_v(j)),!!j};ms(h,{withTypes:()=>h});const m=async(b,j,k,S)=>{const N=new AbortController,E=F$(f,N.signal),A=[];try{b.pending.add(N),n(b),await Promise.resolve(b.effect(j,ms({},k,{getOriginalState:S,condition:(P,_)=>E(P,_).then(Boolean),take:E,delay:D5(N.signal),pause:pf(N.signal),extra:o,signal:N.signal,fork:z$(N.signal,A),unsubscribe:b.unsubscribe,subscribe:()=>{t.set(b.id,b)},cancelActiveListeners:()=>{b.pending.forEach((P,_,O)=>{P!==N&&(P.abort(Ov),O.delete(P))})},cancel:()=>{N.abort(Ov),b.pending.delete(N)},throwIfCancelled:()=>{no(N.signal)}})))}catch(P){P instanceof xh||mk(u,P,{raisedBy:"effect"})}finally{await Promise.all(A),N.abort(L$),a(b),b.pending.delete(N)}},g=B$(t,r);return{middleware:b=>j=>k=>{if(!m5(k))return j(k);if($5.match(k))return f(k.payload);if(U$.match(k)){g();return}if(z5.match(k))return h(k.payload);let S=b.getState();const N=()=>{if(S===fk)throw new Error(Rr(23));return S};let E;try{if(E=j(k),t.size>0){const A=b.getState(),P=Array.from(t.values());for(const _ of P){let O=!1;try{O=_.predicate(k,A,S)}catch(D){O=!1,mk(u,D,{raisedBy:"predicate"})}O&&m(_,k,b,N)}}}finally{S=fk}return E},startListening:f,stopListening:h,clearListeners:g}};function Rr(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var W$={layoutType:"horizontal",width:0,height:0,margin:{top:5,right:5,bottom:5,left:5},scale:1},F5=sr({name:"chartLayout",initialState:W$,reducers:{setLayout(e,t){e.layoutType=t.payload},setChartSize(e,t){e.width=t.payload.width,e.height=t.payload.height},setMargin(e,t){var r,n,a,o;e.margin.top=(r=t.payload.top)!==null&&r!==void 0?r:0,e.margin.right=(n=t.payload.right)!==null&&n!==void 0?n:0,e.margin.bottom=(a=t.payload.bottom)!==null&&a!==void 0?a:0,e.margin.left=(o=t.payload.left)!==null&&o!==void 0?o:0},setScale(e,t){e.scale=t.payload}}}),wh=F5.actions,K$=wh.setMargin,G$=wh.setLayout,V$=wh.setChartSize,q$=wh.setScale,Q$=F5.reducer;function B5(e,t,r){return Array.isArray(e)&&e&&t+r!==0?e.slice(t,r+1):e}function He(e){return Number.isFinite(e)}function Un(e){return typeof e=="number"&&e>0&&Number.isFinite(e)}function pk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function cs(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pk(Object(r),!0).forEach(function(n){Y$(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Y$(e,t,r){return(t=X$(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function X$(e){var t=Z$(e,"string");return typeof t=="symbol"?t:t+""}function Z$(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Dt(e,t,r){return Gt(e)||Gt(t)?r:Bn(t)?bo(e,t,r):typeof t=="function"?t(e):r}var J$=(e,t,r)=>{if(t&&r){var n=r.width,a=r.height,o=t.align,u=t.verticalAlign,c=t.layout;if((c==="vertical"||c==="horizontal"&&u==="middle")&&o!=="center"&&Ee(e[o]))return cs(cs({},e),{},{[o]:e[o]+(n||0)});if((c==="horizontal"||c==="vertical"&&o==="center")&&u!=="middle"&&Ee(e[u]))return cs(cs({},e),{},{[u]:e[u]+(a||0)})}return e},Gn=(e,t)=>e==="horizontal"&&t==="xAxis"||e==="vertical"&&t==="yAxis"||e==="centric"&&t==="angleAxis"||e==="radial"&&t==="radiusAxis",U5=(e,t,r,n)=>{if(n)return e.map(c=>c.coordinate);var a,o,u=e.map(c=>(c.coordinate===t&&(a=!0),c.coordinate===r&&(o=!0),c.coordinate));return a||u.push(t),o||u.push(r),u},H5=(e,t,r)=>{if(!e)return null;var n=e.duplicateDomain,a=e.type,o=e.range,u=e.scale,c=e.realScaleType,f=e.isCategorical,h=e.categoricalDomain,m=e.tickCount,g=e.ticks,v=e.niceTicks,b=e.axisType;if(!u)return null;var j=c==="scaleBand"&&u.bandwidth?u.bandwidth()/2:2,k=a==="category"&&u.bandwidth?u.bandwidth()/j:0;if(k=b==="angleAxis"&&o&&o.length>=2?Vr(o[0]-o[1])*2*k:k,g||v){var S=(g||v||[]).map((N,E)=>{var A=n?n.indexOf(N):N,P=u.map(A);return He(P)?{coordinate:P+k,value:N,offset:k,index:E}:null}).filter(jr);return S}return f&&h?h.map((N,E)=>{var A=u.map(N);return He(A)?{coordinate:A+k,value:N,index:E,offset:k}:null}).filter(jr):u.ticks&&m!=null?u.ticks(m).map((N,E)=>{var A=u.map(N);return He(A)?{coordinate:A+k,value:N,index:E,offset:k}:null}).filter(jr):u.domain().map((N,E)=>{var A=u.map(N);return He(A)?{coordinate:A+k,value:n?n[N]:N,index:E,offset:k}:null}).filter(jr)},ez=e=>{var t,r=e.length;if(!(r<=0)){var n=(t=e[0])===null||t===void 0?void 0:t.length;if(!(n==null||n<=0))for(var a=0;a<n;++a)for(var o=0,u=0,c=0;c<r;++c){var f=e[c],h=f==null?void 0:f[a];if(h!=null){var m=h[1],g=h[0],v=Fn(m)?g:m;v>=0?(h[0]=o,o+=v,h[1]=o):(h[0]=u,u+=v,h[1]=u)}}}},tz=e=>{var t,r=e.length;if(!(r<=0)){var n=(t=e[0])===null||t===void 0?void 0:t.length;if(!(n==null||n<=0))for(var a=0;a<n;++a)for(var o=0,u=0;u<r;++u){var c=e[u],f=c==null?void 0:c[a];if(f!=null){var h=Fn(f[1])?f[0]:f[1];h>=0?(f[0]=o,o+=h,f[1]=o):(f[0]=0,f[1]=0)}}}},rz={sign:ez,expand:yR,none:lo,silhouette:xR,wiggle:bR,positive:tz},nz=(e,t,r)=>{var n,a=(n=rz[r])!==null&&n!==void 0?n:lo,o=vR().keys(t).value((c,f)=>Number(Dt(c,f,0))).order(vv).offset(a),u=o(e);return u.forEach((c,f)=>{c.forEach((h,m)=>{var g=Dt(e[m],t[f],0);Array.isArray(g)&&g.length===2&&Ee(g[0])&&Ee(g[1])&&(h[0]=g[0],h[1]=g[1])})}),u};function iz(e){return e==null?void 0:String(e)}function gk(e){var t=e.axis,r=e.ticks,n=e.bandSize,a=e.entry,o=e.index,u=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Gt(a[t.dataKey])){var c=QE(r,"value",a[t.dataKey]);if(c)return c.coordinate+n/2}return r!=null&&r[o]?r[o].coordinate+n/2:null}var f=Dt(a,Gt(u)?t.dataKey:u),h=t.scale.map(f);return Ee(h)?h:null}var az=e=>{var t=e.flat(2).filter(Ee);return[Math.min(...t),Math.max(...t)]},oz=e=>[e[0]===1/0?0:e[0],e[1]===-1/0?0:e[1]],sz=(e,t,r)=>{if(!(e==null||Object.keys(e).length===0))return oz(Object.keys(e).reduce((n,a)=>{var o=e[a];if(!o)return n;var u=o.stackedData,c=u.reduce((f,h)=>{var m=B5(h,t,r),g=az(m);return!He(g[0])||!He(g[1])?f:[Math.min(f[0],g[0]),Math.max(f[1],g[1])]},[1/0,-1/0]);return[Math.min(c[0],n[0]),Math.max(c[1],n[1])]},[1/0,-1/0]))},vk=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,yk=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,gf=(e,t,r)=>{if(e&&e.scale&&e.scale.bandwidth){var n=e.scale.bandwidth();if(!r||n>0)return n}if(e&&t&&t.length>=2){for(var a=dh(t,m=>m.coordinate),o=1/0,u=1,c=a.length;u<c;u++){var f=a[u],h=a[u-1];o=Math.min(((f==null?void 0:f.coordinate)||0)-((h==null?void 0:h.coordinate)||0),o)}return o===1/0?0:o}return r?void 0:0};function xk(e){var t=e.tooltipEntrySettings,r=e.dataKey,n=e.payload,a=e.value,o=e.name;return cs(cs({},t),{},{dataKey:r,payload:n,value:a,name:o})}function W5(e,t){if(e!=null)return String(e);if(typeof t=="string")return t}var lz=(e,t)=>{if(t==="horizontal")return e.relativeX;if(t==="vertical")return e.relativeY},uz=(e,t)=>t==="centric"?e.angle:e.radius,xi=e=>e.layout.width,bi=e=>e.layout.height,cz=e=>e.layout.scale,K5=e=>e.layout.margin,kh=q(e=>e.cartesianAxis.xAxis,e=>Object.values(e)),jh=q(e=>e.cartesianAxis.yAxis,e=>Object.values(e)),dz="data-recharts-item-index",fz="data-recharts-item-id",Gu=60;function bk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Od(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?bk(Object(r),!0).forEach(function(n){hz(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):bk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function hz(e,t,r){return(t=mz(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function mz(e){var t=pz(e,"string");return typeof t=="symbol"?t:t+""}function pz(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var gz=e=>e.brush.height;function vz(e){var t=jh(e);return t.reduce((r,n)=>{if(n.orientation==="left"&&!n.mirror&&!n.hide){var a=typeof n.width=="number"?n.width:Gu;return r+a}return r},0)}function yz(e){var t=jh(e);return t.reduce((r,n)=>{if(n.orientation==="right"&&!n.mirror&&!n.hide){var a=typeof n.width=="number"?n.width:Gu;return r+a}return r},0)}function xz(e){var t=kh(e);return t.reduce((r,n)=>n.orientation==="top"&&!n.mirror&&!n.hide?r+n.height:r,0)}function bz(e){var t=kh(e);return t.reduce((r,n)=>n.orientation==="bottom"&&!n.mirror&&!n.hide?r+n.height:r,0)}var Qt=q([xi,bi,K5,gz,vz,yz,xz,bz,d5,BL],(e,t,r,n,a,o,u,c,f,h)=>{var m={left:(r.left||0)+a,right:(r.right||0)+o},g={top:(r.top||0)+u,bottom:(r.bottom||0)+c},v=Od(Od({},g),m),b=v.bottom;v.bottom+=n,v=J$(v,f,h);var j=e-v.left-v.right,k=t-v.top-v.bottom;return Od(Od({brushBottom:b},v),{},{width:Math.max(j,0),height:Math.max(k,0)})}),wz=q(Qt,e=>({x:e.left,y:e.top,width:e.width,height:e.height})),G5=q(xi,bi,(e,t)=>({x:0,y:0,width:e,height:t})),kz=y.createContext(null),Nr=()=>y.useContext(kz)!=null,Sh=e=>e.brush,Nh=q([Sh,Qt,K5],(e,t,r)=>({height:e.height,x:Ee(e.x)?e.x:t.left,y:Ee(e.y)?e.y:t.top+t.height+t.brushBottom-((r==null?void 0:r.bottom)||0),width:Ee(e.width)?e.width:t.width}));function jz(e,t,{signal:r,edges:n}={}){let a,o=null;const u=n!=null&&n.includes("leading"),c=n==null||n.includes("trailing"),f=()=>{o!==null&&(e.apply(a,o),a=void 0,o=null)},h=()=>{c&&f(),b()};let m=null;const g=()=>{m!=null&&clearTimeout(m),m=setTimeout(()=>{m=null,h()},t)},v=()=>{m!==null&&(clearTimeout(m),m=null)},b=()=>{v(),a=void 0,o=null},j=()=>{f()},k=function(...S){if(r!=null&&r.aborted)return;a=this,o=S;const N=m==null;g(),u&&N&&f()};return k.schedule=g,k.cancel=b,k.flush=j,r==null||r.addEventListener("abort",b,{once:!0}),k}function Sz(e,t=0,r={}){typeof r!="object"&&(r={});const{leading:n=!1,trailing:a=!0,maxWait:o}=r,u=Array(2);n&&(u[0]="leading"),a&&(u[1]="trailing");let c,f=null;const h=jz(function(...v){c=e.apply(this,v),f=null},t,{edges:u}),m=function(...v){return o!=null&&(f===null&&(f=Date.now()),Date.now()-f>=o)?(c=e.apply(this,v),f=Date.now(),h.cancel(),h.schedule(),c):(h.apply(this,v),c)},g=()=>(h.flush(),c);return m.cancel=h.cancel,m.flush=g,m}function Nz(e,t=0,r={}){const{leading:n=!0,trailing:a=!0}=r;return Sz(e,t,{leading:n,maxWait:t,trailing:a})}var vf=function(t,r){for(var n=arguments.length,a=new Array(n>2?n-2:0),o=2;o<n;o++)a[o-2]=arguments[o];if(typeof console<"u"&&console.warn&&(r===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(r===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var u=0;console.warn(r.replace(/%s/g,()=>a[u++]))}},Tn={width:"100%",height:"100%",debounce:0,minWidth:0,initialDimension:{width:-1,height:-1}},V5=(e,t,r)=>{var n=r.width,a=n===void 0?Tn.width:n,o=r.height,u=o===void 0?Tn.height:o,c=r.aspect,f=r.maxHeight,h=uo(a)?e:Number(a),m=uo(u)?t:Number(u);return c&&c>0&&(h?m=h/c:m&&(h=m*c),f&&m!=null&&m>f&&(m=f)),{calculatedWidth:h,calculatedHeight:m}},Ez={width:0,height:0,overflow:"visible"},Az={width:0,overflowX:"visible"},Cz={height:0,overflowY:"visible"},Pz={},Oz=e=>{var t=e.width,r=e.height,n=uo(t),a=uo(r);return n&&a?Ez:n?Az:a?Cz:Pz};function _z(e){var t=e.width,r=e.height,n=e.aspect,a=t,o=r;return a===void 0&&o===void 0?(a=Tn.width,o=Tn.height):a===void 0?a=n&&n>0?void 0:Tn.width:o===void 0&&(o=n&&n>0?void 0:Tn.height),{width:a,height:o}}var Mz=["aspect","initialDimension","width","height","minWidth","minHeight","maxHeight","children","debounce","id","className","onResize","style"];function yf(){return yf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yf.apply(null,arguments)}function wk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function kk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?wk(Object(r),!0).forEach(function(n){Iz(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):wk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Iz(e,t,r){return(t=Tz(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Tz(e){var t=Dz(e,"string");return typeof t=="symbol"?t:t+""}function Dz(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Rz(e,t){return Fz(e)||zz(e,t)||$z(e,t)||Lz()}function Lz(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $z(e,t){if(e){if(typeof e=="string")return jk(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?jk(e,t):void 0}}function jk(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function zz(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function Fz(e){if(Array.isArray(e))return e}function Bz(e,t){if(e==null)return{};var r,n,a=Uz(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function Uz(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var q5=y.createContext(Tn.initialDimension);function Hz(e){return Un(e.width)&&Un(e.height)}function Q5(e){var t=e.children,r=e.width,n=e.height,a=y.useMemo(()=>({width:r,height:n}),[r,n]);return Hz(a)?y.createElement(q5.Provider,{value:a},t):null}var $y=()=>y.useContext(q5),Wz=y.forwardRef((e,t)=>{var r=e.aspect,n=e.initialDimension,a=n===void 0?Tn.initialDimension:n,o=e.width,u=e.height,c=e.minWidth,f=c===void 0?Tn.minWidth:c,h=e.minHeight,m=e.maxHeight,g=e.children,v=e.debounce,b=v===void 0?Tn.debounce:v,j=e.id,k=e.className,S=e.onResize,N=e.style,E=N===void 0?{}:N,A=Bz(e,Mz),P=y.useRef(null),_=y.useRef();_.current=S,y.useImperativeHandle(t,()=>P.current);var O=y.useState({containerWidth:a.width,containerHeight:a.height}),D=Rz(O,2),B=D[0],F=D[1],z=y.useCallback((ie,se)=>{F(X=>{var te=Math.round(ie),J=Math.round(se);return X.containerWidth===te&&X.containerHeight===J?X:{containerWidth:te,containerHeight:J}})},[]);y.useEffect(()=>{if(P.current==null||typeof ResizeObserver>"u")return Vs;var ie=I=>{var M,H=I[0];if(H!=null){var ne=H.contentRect,Z=ne.width,me=ne.height;z(Z,me),(M=_.current)===null||M===void 0||M.call(_,Z,me)}};b>0&&(ie=Nz(ie,b,{trailing:!0,leading:!1}));var se=new ResizeObserver(ie),X=P.current.getBoundingClientRect(),te=X.width,J=X.height;return z(te,J),se.observe(P.current),()=>{se.disconnect()}},[z,b]);var Y=B.containerWidth,U=B.containerHeight;vf(!r||r>0,"The aspect(%s) must be greater than zero.",r);var he=V5(Y,U,{width:o,height:u,aspect:r,maxHeight:m}),ue=he.calculatedWidth,ge=he.calculatedHeight;return vf(Y<0||U<0||ue!=null&&ue>0||ge!=null&&ge>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
||
please check the style of container, or the props width(%s) and height(%s),
|
||
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
||
height and width.`,ue,ge,o,u,f,h,r),y.createElement("div",yf({id:j?"".concat(j):void 0,className:rt("recharts-responsive-container",k),style:kk(kk({},E),{},{width:o,height:u,minWidth:f,minHeight:h,maxHeight:m}),ref:P},A),y.createElement("div",{style:Oz({width:o,height:u})},y.createElement(Q5,{width:ue,height:ge},g)))}),Kz=y.forwardRef((e,t)=>{var r=$y();if(Un(r.width)&&Un(r.height))return e.children;var n=_z({width:e.width,height:e.height,aspect:e.aspect}),a=n.width,o=n.height,u=V5(void 0,void 0,{width:a,height:o,aspect:e.aspect,maxHeight:e.maxHeight}),c=u.calculatedWidth,f=u.calculatedHeight;return Ee(c)&&Ee(f)?y.createElement(Q5,{width:c,height:f},e.children):y.createElement(Wz,yf({},e,{width:a,height:o,ref:t}))});function zy(e){if(e)return{x:e.x,y:e.y,upperWidth:"upperWidth"in e?e.upperWidth:e.width,lowerWidth:"lowerWidth"in e?e.lowerWidth:e.width,width:e.width,height:e.height}}var Eh=()=>{var e,t=Nr(),r=Me(wz),n=Me(Nh),a=(e=Me(Sh))===null||e===void 0?void 0:e.padding;return!t||!n||!a?r:{width:n.width-a.left-a.right,height:n.height-a.top-a.bottom,x:a.left,y:a.top}},Gz={top:0,bottom:0,left:0,right:0,width:0,height:0,brushBottom:0},Y5=()=>{var e;return(e=Me(Qt))!==null&&e!==void 0?e:Gz},X5=()=>Me(xi),Z5=()=>Me(bi),ct=e=>e.layout.layoutType,qs=()=>Me(ct),Fy=()=>{var e=qs();if(e==="horizontal"||e==="vertical")return e},J5=e=>{var t=e.layout.layoutType;if(t==="centric"||t==="radial")return t},Vz=()=>{var e=qs();return e!==void 0},Vu=e=>{var t=jt(),r=Nr(),n=e.width,a=e.height,o=$y(),u=n,c=a;return o&&(u=o.width>0?o.width:n,c=o.height>0?o.height:a),y.useEffect(()=>{!r&&Un(u)&&Un(c)&&t(V$({width:u,height:c}))},[t,r,u,c]),null},eA=Symbol.for("immer-nothing"),Sk=Symbol.for("immer-draftable"),$r=Symbol.for("immer-state");function hn(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Su=Object.getPrototypeOf;function Ls(e){return!!e&&!!e[$r]}function fo(e){var t;return e?tA(e)||Array.isArray(e)||!!e[Sk]||!!((t=e.constructor)!=null&&t[Sk])||qu(e)||Ch(e):!1}var qz=Object.prototype.constructor.toString(),Nk=new WeakMap;function tA(e){if(!e||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);if(t===null||t===Object.prototype)return!0;const r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;if(r===Object)return!0;if(typeof r!="function")return!1;let n=Nk.get(r);return n===void 0&&(n=Function.toString.call(r),Nk.set(r,n)),n===qz}function xf(e,t,r=!0){Ah(e)===0?(r?Reflect.ownKeys(e):Object.keys(e)).forEach(a=>{t(a,e[a],e)}):e.forEach((n,a)=>t(a,n,e))}function Ah(e){const t=e[$r];return t?t.type_:Array.isArray(e)?1:qu(e)?2:Ch(e)?3:0}function Mv(e,t){return Ah(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function rA(e,t,r){const n=Ah(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function Qz(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function qu(e){return e instanceof Map}function Ch(e){return e instanceof Set}function za(e){return e.copy_||e.base_}function Iv(e,t){if(qu(e))return new Map(e);if(Ch(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const r=tA(e);if(t===!0||t==="class_only"&&!r){const n=Object.getOwnPropertyDescriptors(e);delete n[$r];let a=Reflect.ownKeys(n);for(let o=0;o<a.length;o++){const u=a[o],c=n[u];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(n[u]={configurable:!0,writable:!0,enumerable:c.enumerable,value:e[u]})}return Object.create(Su(e),n)}else{const n=Su(e);if(n!==null&&r)return{...e};const a=Object.create(n);return Object.assign(a,e)}}function By(e,t=!1){return Ph(e)||Ls(e)||!fo(e)||(Ah(e)>1&&Object.defineProperties(e,{set:_d,add:_d,clear:_d,delete:_d}),Object.freeze(e),t&&Object.values(e).forEach(r=>By(r,!0))),e}function Yz(){hn(2)}var _d={value:Yz};function Ph(e){return e===null||typeof e!="object"?!0:Object.isFrozen(e)}var Xz={};function ho(e){const t=Xz[e];return t||hn(0,e),t}var Nu;function nA(){return Nu}function Zz(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Ek(e,t){t&&(ho("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Tv(e){Dv(e),e.drafts_.forEach(Jz),e.drafts_=null}function Dv(e){e===Nu&&(Nu=e.parent_)}function Ak(e){return Nu=Zz(Nu,e)}function Jz(e){const t=e[$r];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function Ck(e,t){t.unfinalizedDrafts_=t.drafts_.length;const r=t.drafts_[0];return e!==void 0&&e!==r?(r[$r].modified_&&(Tv(t),hn(4)),fo(e)&&(e=bf(t,e),t.parent_||wf(t,e)),t.patches_&&ho("Patches").generateReplacementPatches_(r[$r].base_,e,t.patches_,t.inversePatches_)):e=bf(t,r,[]),Tv(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==eA?e:void 0}function bf(e,t,r){if(Ph(t))return t;const n=e.immer_.shouldUseStrictIteration(),a=t[$r];if(!a)return xf(t,(o,u)=>Pk(e,a,t,o,u,r),n),t;if(a.scope_!==e)return t;if(!a.modified_)return wf(e,a.base_,!0),a.base_;if(!a.finalized_){a.finalized_=!0,a.scope_.unfinalizedDrafts_--;const o=a.copy_;let u=o,c=!1;a.type_===3&&(u=new Set(o),o.clear(),c=!0),xf(u,(f,h)=>Pk(e,a,o,f,h,r,c),n),wf(e,o,!1),r&&e.patches_&&ho("Patches").generatePatches_(a,r,e.patches_,e.inversePatches_)}return a.copy_}function Pk(e,t,r,n,a,o,u){if(a==null||typeof a!="object"&&!u)return;const c=Ph(a);if(!(c&&!u)){if(Ls(a)){const f=o&&t&&t.type_!==3&&!Mv(t.assigned_,n)?o.concat(n):void 0,h=bf(e,a,f);if(rA(r,n,h),Ls(h))e.canAutoFreeze_=!1;else return}else u&&r.add(a);if(fo(a)&&!c){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1||t&&t.base_&&t.base_[n]===a&&c)return;bf(e,a),(!t||!t.scope_.parent_)&&typeof n!="symbol"&&(qu(r)?r.has(n):Object.prototype.propertyIsEnumerable.call(r,n))&&wf(e,a)}}}function wf(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&By(t,r)}function e6(e,t){const r=Array.isArray(e),n={type_:r?1:0,scope_:t?t.scope_:nA(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let a=n,o=Uy;r&&(a=[n],o=Eu);const{revoke:u,proxy:c}=Proxy.revocable(a,o);return n.draft_=c,n.revoke_=u,c}var Uy={get(e,t){if(t===$r)return e;const r=za(e);if(!Mv(r,t))return t6(e,r,t);const n=r[t];return e.finalized_||!fo(n)?n:n===cg(e.base_,t)?(dg(e),e.copy_[t]=Lv(n,e)):n},has(e,t){return t in za(e)},ownKeys(e){return Reflect.ownKeys(za(e))},set(e,t,r){const n=iA(za(e),t);if(n!=null&&n.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){const a=cg(za(e),t),o=a==null?void 0:a[$r];if(o&&o.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if(Qz(r,a)&&(r!==void 0||Mv(e.base_,t)))return!0;dg(e),Rv(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_[t]=!0),!0},deleteProperty(e,t){return cg(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,dg(e),Rv(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const r=za(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty(){hn(11)},getPrototypeOf(e){return Su(e.base_)},setPrototypeOf(){hn(12)}},Eu={};xf(Uy,(e,t)=>{Eu[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});Eu.deleteProperty=function(e,t){return Eu.set.call(this,e,t,void 0)};Eu.set=function(e,t,r){return Uy.set.call(this,e[0],t,r,e[0])};function cg(e,t){const r=e[$r];return(r?za(r):e)[t]}function t6(e,t,r){var a;const n=iA(t,r);return n?"value"in n?n.value:(a=n.get)==null?void 0:a.call(e.draft_):void 0}function iA(e,t){if(!(t in e))return;let r=Su(e);for(;r;){const n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Su(r)}}function Rv(e){e.modified_||(e.modified_=!0,e.parent_&&Rv(e.parent_))}function dg(e){e.copy_||(e.copy_=Iv(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var r6=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!0,this.produce=(t,r,n)=>{if(typeof t=="function"&&typeof r!="function"){const o=r;r=t;const u=this;return function(f=o,...h){return u.produce(f,m=>r.call(this,m,...h))}}typeof r!="function"&&hn(6),n!==void 0&&typeof n!="function"&&hn(7);let a;if(fo(t)){const o=Ak(this),u=Lv(t,void 0);let c=!0;try{a=r(u),c=!1}finally{c?Tv(o):Dv(o)}return Ek(o,n),Ck(a,o)}else if(!t||typeof t!="object"){if(a=r(t),a===void 0&&(a=t),a===eA&&(a=void 0),this.autoFreeze_&&By(a,!0),n){const o=[],u=[];ho("Patches").generateReplacementPatches_(t,a,o,u),n(o,u)}return a}else hn(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(u,...c)=>this.produceWithPatches(u,f=>t(f,...c));let n,a;return[this.produce(t,r,(u,c)=>{n=u,a=c}),n,a]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),typeof(e==null?void 0:e.useStrictIteration)=="boolean"&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){fo(e)||hn(8),Ls(e)&&(e=n6(e));const t=Ak(this),r=Lv(e,void 0);return r[$r].isManual_=!0,Dv(t),r}finishDraft(e,t){const r=e&&e[$r];(!r||!r.isManual_)&&hn(9);const{scope_:n}=r;return Ek(n,t),Ck(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){const a=t[r];if(a.path.length===0&&a.op==="replace"){e=a.value;break}}r>-1&&(t=t.slice(r+1));const n=ho("Patches").applyPatches_;return Ls(e)?n(e,t):this.produce(e,a=>n(a,t))}};function Lv(e,t){const r=qu(e)?ho("MapSet").proxyMap_(e,t):Ch(e)?ho("MapSet").proxySet_(e,t):e6(e,t);return(t?t.scope_:nA()).drafts_.push(r),r}function n6(e){return Ls(e)||hn(10,e),aA(e)}function aA(e){if(!fo(e)||Ph(e))return e;const t=e[$r];let r,n=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Iv(e,t.scope_.immer_.useStrictShallowCopy_),n=t.scope_.immer_.shouldUseStrictIteration()}else r=Iv(e,!0);return xf(r,(a,o)=>{rA(r,a,aA(o))},n),t&&(t.finalized_=!1),r}var i6=new r6;i6.produce;var a6={settings:{layout:"horizontal",align:"center",verticalAlign:"bottom",itemSorter:"value"},size:{width:0,height:0},payload:[]},oA=sr({name:"legend",initialState:a6,reducers:{setLegendSize(e,t){e.size.width=t.payload.width,e.size.height=t.payload.height},setLegendSettings(e,t){e.settings.align=t.payload.align,e.settings.layout=t.payload.layout,e.settings.verticalAlign=t.payload.verticalAlign,e.settings.itemSorter=t.payload.itemSorter},addLegendPayload:{reducer(e,t){e.payload.push(t.payload)},prepare:ot()},replaceLegendPayload:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next,o=qr(e).payload.indexOf(n);o>-1&&(e.payload[o]=a)},prepare:ot()},removeLegendPayload:{reducer(e,t){var r=qr(e).payload.indexOf(t.payload);r>-1&&e.payload.splice(r,1)},prepare:ot()}}}),Qu=oA.actions;Qu.setLegendSize;Qu.setLegendSettings;var o6=Qu.addLegendPayload,s6=Qu.replaceLegendPayload,l6=Qu.removeLegendPayload,u6=oA.reducer,fg={exports:{}},hg={};/**
|
||
* @license React
|
||
* use-sync-external-store-with-selector.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var Ok;function c6(){if(Ok)return hg;Ok=1;var e=Ws();function t(f,h){return f===h&&(f!==0||1/f===1/h)||f!==f&&h!==h}var r=typeof Object.is=="function"?Object.is:t,n=e.useSyncExternalStore,a=e.useRef,o=e.useEffect,u=e.useMemo,c=e.useDebugValue;return hg.useSyncExternalStoreWithSelector=function(f,h,m,g,v){var b=a(null);if(b.current===null){var j={hasValue:!1,value:null};b.current=j}else j=b.current;b=u(function(){function S(_){if(!N){if(N=!0,E=_,_=g(_),v!==void 0&&j.hasValue){var O=j.value;if(v(O,_))return A=O}return A=_}if(O=A,r(E,_))return O;var D=g(_);return v!==void 0&&v(O,D)?(E=_,O):(E=_,A=D)}var N=!1,E,A,P=m===void 0?null:m;return[function(){return S(h())},P===null?void 0:function(){return S(P())}]},[h,m,g,v]);var k=n(f,b[0],b[1]);return o(function(){j.hasValue=!0,j.value=k},[k]),c(k),k},hg}var _k;function d6(){return _k||(_k=1,fg.exports=c6()),fg.exports}d6();function f6(e){e()}function h6(){let e=null,t=null;return{clear(){e=null,t=null},notify(){f6(()=>{let r=e;for(;r;)r.callback(),r=r.next})},get(){const r=[];let n=e;for(;n;)r.push(n),n=n.next;return r},subscribe(r){let n=!0;const a=t={callback:r,next:null,prev:t};return a.prev?a.prev.next=a:e=a,function(){!n||e===null||(n=!1,a.next?a.next.prev=a.prev:t=a.prev,a.prev?a.prev.next=a.next:e=a.next)}}}}var Mk={notify(){},get:()=>[]};function m6(e,t){let r,n=Mk,a=0,o=!1;function u(k){m();const S=n.subscribe(k);let N=!1;return()=>{N||(N=!0,S(),g())}}function c(){n.notify()}function f(){j.onStateChange&&j.onStateChange()}function h(){return o}function m(){a++,r||(r=e.subscribe(f),n=h6())}function g(){a--,r&&a===0&&(r(),r=void 0,n.clear(),n=Mk)}function v(){o||(o=!0,m())}function b(){o&&(o=!1,g())}const j={addNestedSub:u,notifyNestedSubs:c,handleChangeWrapper:f,isSubscribed:h,trySubscribe:v,tryUnsubscribe:b,getListeners:()=>n};return j}var p6=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",g6=p6(),v6=()=>typeof navigator<"u"&&navigator.product==="ReactNative",y6=v6(),x6=()=>g6||y6?y.useLayoutEffect:y.useEffect,b6=x6();function Ik(e,t){return e===t?e!==0||t!==0||1/e===1/t:e!==e&&t!==t}function w6(e,t){if(Ik(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(let a=0;a<r.length;a++)if(!Object.prototype.hasOwnProperty.call(t,r[a])||!Ik(e[r[a]],t[r[a]]))return!1;return!0}var mg=Symbol.for("react-redux-context"),pg=typeof globalThis<"u"?globalThis:{};function k6(){if(!y.createContext)return{};const e=pg[mg]??(pg[mg]=new Map);let t=e.get(y.createContext);return t||(t=y.createContext(null),e.set(y.createContext,t)),t}var j6=k6();function S6(e){const{children:t,context:r,serverState:n,store:a}=e,o=y.useMemo(()=>{const f=m6(a);return{store:a,subscription:f,getServerState:n?()=>n:void 0}},[a,n]),u=y.useMemo(()=>a.getState(),[a]);b6(()=>{const{subscription:f}=o;return f.onStateChange=f.notifyNestedSubs,f.trySubscribe(),u!==a.getState()&&f.notifyNestedSubs(),()=>{f.tryUnsubscribe(),f.onStateChange=void 0}},[o,u]);const c=r||j6;return y.createElement(c.Provider,{value:o},t)}var N6=S6,E6=new Set(["axisLine","tickLine","activeBar","activeDot","activeLabel","activeShape","allowEscapeViewBox","background","cursor","dot","label","line","margin","padding","position","shape","style","tick","wrapperStyle","radius","throttledEvents"]);function A6(e,t){return e==null&&t==null?!0:typeof e=="number"&&typeof t=="number"?e===t||e!==e&&t!==t:e===t}function Oh(e,t){var r=new Set([...Object.keys(e),...Object.keys(t)]);for(var n of r)if(E6.has(n)){if(e[n]==null&&t[n]==null)continue;if(!w6(e[n],t[n]))return!1}else if(!A6(e[n],t[n]))return!1;return!0}function $v(){return $v=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},$v.apply(null,arguments)}function Tk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Vl(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Tk(Object(r),!0).forEach(function(n){C6(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Tk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function C6(e,t,r){return(t=P6(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function P6(e){var t=O6(e,"string");return typeof t=="symbol"?t:t+""}function O6(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function _6(e,t){return D6(e)||T6(e,t)||I6(e,t)||M6()}function M6(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function I6(e,t){if(e){if(typeof e=="string")return Dk(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Dk(e,t):void 0}}function Dk(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function T6(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function D6(e){if(Array.isArray(e))return e}function R6(e){return Array.isArray(e)&&Bn(e[0])&&Bn(e[1])?e.join(" ~ "):e}var Jo={separator:" : ",contentStyle:{margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},itemStyle:{display:"block",paddingTop:4,paddingBottom:4,color:"#000"},labelStyle:{},accessibilityLayer:!1};function L6(e,t){return t==null?e:dh(e,t)}var $6=e=>{var t=e.separator,r=t===void 0?Jo.separator:t,n=e.contentStyle,a=e.itemStyle,o=e.labelStyle,u=o===void 0?Jo.labelStyle:o,c=e.payload,f=e.formatter,h=e.itemSorter,m=e.wrapperClassName,g=e.labelClassName,v=e.label,b=e.labelFormatter,j=e.accessibilityLayer,k=j===void 0?Jo.accessibilityLayer:j,S=()=>{if(c&&c.length){var B={padding:0,margin:0},F=L6(c,h),z=F.map((Y,U)=>{if(!Y||Y.type==="none")return null;var he=Y.formatter||f||R6,ue=Y.value,ge=Y.name,ie=ue,se=ge;if(he){var X=he(ue,ge,Y,U,c);if(Array.isArray(X)){var te=_6(X,2);ie=te[0],se=te[1]}else if(X!=null)ie=X;else return null}var J=Vl(Vl({},Jo.itemStyle),{},{color:Y.color||Jo.itemStyle.color},a);return y.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(U),style:J},Bn(se)?y.createElement("span",{className:"recharts-tooltip-item-name"},se):null,Bn(se)?y.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,y.createElement("span",{className:"recharts-tooltip-item-value"},ie),y.createElement("span",{className:"recharts-tooltip-item-unit"},Y.unit||""))});return y.createElement("ul",{className:"recharts-tooltip-item-list",style:B},z)}return null},N=Vl(Vl({},Jo.contentStyle),n),E=Vl({margin:0},u),A=!Gt(v),P=A?v:"",_=rt("recharts-default-tooltip",m),O=rt("recharts-tooltip-label",g);A&&b&&c!==void 0&&c!==null&&(P=b(v,c));var D=k?{role:"status","aria-live":"assertive"}:{};return y.createElement("div",$v({className:_,style:N},D),y.createElement("p",{className:O,style:E},y.isValidElement(P)?P:"".concat(P)),S())},ql="recharts-tooltip-wrapper",z6={visibility:"hidden"};function F6(e){var t=e.coordinate,r=e.translateX,n=e.translateY;return rt(ql,{["".concat(ql,"-right")]:Ee(r)&&t&&Ee(t.x)&&r>=t.x,["".concat(ql,"-left")]:Ee(r)&&t&&Ee(t.x)&&r<t.x,["".concat(ql,"-bottom")]:Ee(n)&&t&&Ee(t.y)&&n>=t.y,["".concat(ql,"-top")]:Ee(n)&&t&&Ee(t.y)&&n<t.y})}function Rk(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.key,a=e.offset,o=e.position,u=e.reverseDirection,c=e.tooltipDimension,f=e.viewBox,h=e.viewBoxDimension;if(o&&Ee(o[n]))return o[n];var m=r[n]-c-(a>0?a:0),g=r[n]+a;if(t[n])return u[n]?m:g;var v=f[n];if(v==null)return 0;if(u[n]){var b=m,j=v;return b<j?Math.max(g,v):Math.max(m,v)}if(h==null)return 0;var k=g+c,S=v+h;return k>S?Math.max(m,v):Math.max(g,v)}function B6(e){var t=e.translateX,r=e.translateY,n=e.useTranslate3d;return{transform:n?"translate3d(".concat(t,"px, ").concat(r,"px, 0)"):"translate(".concat(t,"px, ").concat(r,"px)")}}function U6(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.offsetTop,a=e.offsetLeft,o=e.position,u=e.reverseDirection,c=e.tooltipBox,f=e.useTranslate3d,h=e.viewBox,m,g,v;return c.height>0&&c.width>0&&r?(g=Rk({allowEscapeViewBox:t,coordinate:r,key:"x",offset:a,position:o,reverseDirection:u,tooltipDimension:c.width,viewBox:h,viewBoxDimension:h.width}),v=Rk({allowEscapeViewBox:t,coordinate:r,key:"y",offset:n,position:o,reverseDirection:u,tooltipDimension:c.height,viewBox:h,viewBoxDimension:h.height}),m=B6({translateX:g,translateY:v,useTranslate3d:f})):m=z6,{cssProperties:m,cssClasses:F6({translateX:g,translateY:v,coordinate:r})}}var H6=()=>!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout),Yu={isSsr:H6()};function W6(e,t){return q6(e)||V6(e,t)||G6(e,t)||K6()}function K6(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function G6(e,t){if(e){if(typeof e=="string")return Lk(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Lk(e,t):void 0}}function Lk(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function V6(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function q6(e){if(Array.isArray(e))return e}function sA(){var e=y.useState(()=>Yu.isSsr||!window.matchMedia?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches),t=W6(e,2),r=t[0],n=t[1];return y.useEffect(()=>{if(window.matchMedia){var a=window.matchMedia("(prefers-reduced-motion: reduce)"),o=()=>{n(a.matches)};return a.addEventListener("change",o),()=>{a.removeEventListener("change",o)}}},[]),r}function $k(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function es(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?$k(Object(r),!0).forEach(function(n){Q6(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):$k(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Q6(e,t,r){return(t=Y6(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Y6(e){var t=X6(e,"string");return typeof t=="symbol"?t:t+""}function X6(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Z6(e,t){return r8(e)||t8(e,t)||e8(e,t)||J6()}function J6(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function e8(e,t){if(e){if(typeof e=="string")return zk(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?zk(e,t):void 0}}function zk(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function t8(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function r8(e){if(Array.isArray(e))return e}function n8(e){if(!(e.prefersReducedMotion&&e.isAnimationActive==="auto")&&e.isAnimationActive&&e.active){var t=typeof e.animationEasing=="string"?e.animationEasing:"ease";return"transform ".concat(e.animationDuration,"ms ").concat(t)}}function i8(e){var t,r,n,a,o,u,c=sA(),f=y.useState(()=>({dismissed:!1,dismissedAtCoordinate:{x:0,y:0}})),h=Z6(f,2),m=h[0],g=h[1];y.useEffect(()=>{var N=E=>{if(E.key==="Escape"){var A,P,_,O;g({dismissed:!0,dismissedAtCoordinate:{x:(A=(P=e.coordinate)===null||P===void 0?void 0:P.x)!==null&&A!==void 0?A:0,y:(_=(O=e.coordinate)===null||O===void 0?void 0:O.y)!==null&&_!==void 0?_:0}})}};return document.addEventListener("keydown",N),()=>{document.removeEventListener("keydown",N)}},[(t=e.coordinate)===null||t===void 0?void 0:t.x,(r=e.coordinate)===null||r===void 0?void 0:r.y]),m.dismissed&&(((n=(a=e.coordinate)===null||a===void 0?void 0:a.x)!==null&&n!==void 0?n:0)!==m.dismissedAtCoordinate.x||((o=(u=e.coordinate)===null||u===void 0?void 0:u.y)!==null&&o!==void 0?o:0)!==m.dismissedAtCoordinate.y)&&g(es(es({},m),{},{dismissed:!1}));var v=U6({allowEscapeViewBox:e.allowEscapeViewBox,coordinate:e.coordinate,offsetLeft:typeof e.offset=="number"?e.offset:e.offset.x,offsetTop:typeof e.offset=="number"?e.offset:e.offset.y,position:e.position,reverseDirection:e.reverseDirection,tooltipBox:{height:e.lastBoundingBox.height,width:e.lastBoundingBox.width},useTranslate3d:e.useTranslate3d,viewBox:e.viewBox}),b=v.cssClasses,j=v.cssProperties,k=e.hasPortalFromProps?{}:es(es({transition:n8({prefersReducedMotion:c,isAnimationActive:e.isAnimationActive,active:e.active,animationDuration:e.animationDuration,animationEasing:e.animationEasing})},j),{},{pointerEvents:"none",position:"absolute",top:0,left:0}),S=es(es({},k),{},{visibility:!m.dismissed&&e.active&&e.hasPayload?"visible":"hidden"},e.wrapperStyle);return y.createElement("div",{xmlns:"http://www.w3.org/1999/xhtml",tabIndex:-1,className:b,style:S,ref:e.innerRef},e.children)}var a8=y.memo(i8),lA=()=>{var e;return(e=Me(t=>t.rootProps.accessibilityLayer))!==null&&e!==void 0?e:!0};function zv(){return zv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},zv.apply(null,arguments)}function Fk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Bk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Fk(Object(r),!0).forEach(function(n){o8(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Fk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function o8(e,t,r){return(t=s8(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function s8(e){var t=l8(e,"string");return typeof t=="symbol"?t:t+""}function l8(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Uk={curveBasisClosed:oR,curveBasisOpen:sR,curveBasis:aR,curveBumpX:nR,curveBumpY:iR,curveLinearClosed:lR,curveLinear:uh,curveMonotoneX:uR,curveMonotoneY:cR,curveNatural:dR,curveStep:fR,curveStepAfter:mR,curveStepBefore:hR},kf=e=>He(e.x)&&He(e.y),Hk=e=>e.base!=null&&kf(e.base)&&kf(e),Ql=e=>e.x,Yl=e=>e.y,u8=(e,t)=>{if(typeof e=="function")return e;var r="curve".concat(Cy(e));if((r==="curveMonotone"||r==="curveBump")&&t){var n=Uk["".concat(r).concat(t==="vertical"?"Y":"X")];if(n)return n}return Uk[r]||uh},Wk={connectNulls:!1,type:"linear"},c8=e=>{var t=e.type,r=t===void 0?Wk.type:t,n=e.points,a=n===void 0?[]:n,o=e.baseLine,u=e.layout,c=e.connectNulls,f=c===void 0?Wk.connectNulls:c,h=u8(r,u),m=f?a.filter(kf):a;if(Array.isArray(o)){var g,v=a.map((N,E)=>Bk(Bk({},N),{},{base:o[E]}));u==="vertical"?g=Sd().y(Yl).x1(Ql).x0(N=>N.base.x):g=Sd().x(Ql).y1(Yl).y0(N=>N.base.y);var b=g.defined(Hk).curve(h),j=f?v.filter(Hk):v;return b(j)}var k;u==="vertical"&&Ee(o)?k=Sd().y(Yl).x1(Ql).x0(o):Ee(o)?k=Sd().x(Ql).y1(Yl).y0(o):k=LE().x(Ql).y(Yl);var S=k.defined(kf).curve(h);return S(m)},Vd=e=>{var t=e.className,r=e.points,n=e.path,a=e.pathRef,o=qs();if((!r||!r.length)&&!n)return null;var u={type:e.type,points:e.points,baseLine:e.baseLine,layout:e.layout||o,connectNulls:e.connectNulls},c=r&&r.length?c8(u):n;return y.createElement("path",zv({},vn(e),Py(e),{className:rt("recharts-curve",t),d:c===null?void 0:c,ref:a}))},d8=["x","y","top","left","width","height","className"];function Fv(){return Fv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Fv.apply(null,arguments)}function Kk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function f8(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Kk(Object(r),!0).forEach(function(n){h8(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Kk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function h8(e,t,r){return(t=m8(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function m8(e){var t=p8(e,"string");return typeof t=="symbol"?t:t+""}function p8(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function g8(e,t){if(e==null)return{};var r,n,a=v8(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function v8(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var y8=(e,t,r,n,a,o)=>"M".concat(e,",").concat(a,"v").concat(n,"M").concat(o,",").concat(t,"h").concat(r),x8=e=>{var t=e.x,r=t===void 0?0:t,n=e.y,a=n===void 0?0:n,o=e.top,u=o===void 0?0:o,c=e.left,f=c===void 0?0:c,h=e.width,m=h===void 0?0:h,g=e.height,v=g===void 0?0:g,b=e.className,j=g8(e,d8),k=f8({x:r,y:a,top:u,left:f,width:m,height:v},j);return!Ee(r)||!Ee(a)||!Ee(m)||!Ee(v)||!Ee(u)||!Ee(f)?null:y.createElement("path",Fv({},Yr(k),{className:rt("recharts-cross",b),d:y8(r,a,m,v,u,f)}))};function b8(e,t,r,n){var a=n/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-a:r.left+.5,y:e==="horizontal"?r.top+.5:t.y-a,width:e==="horizontal"?n:r.width-1,height:e==="horizontal"?r.height-1:n}}var jf=1e-4,uA=(e,t)=>[0,3*e,3*t-6*e,3*e-3*t+1],cA=(e,t)=>e.map((r,n)=>r*t**n).reduce((r,n)=>r+n),Gk=(e,t)=>r=>{var n=uA(e,t);return cA(n,r)},w8=(e,t)=>r=>{var n=uA(e,t),a=[...n.map((o,u)=>o*u).slice(1),0];return cA(a,r)},k8=e=>{var t,r=e.split("(");if(r.length!==2||r[0]!=="cubic-bezier")return null;var n=(t=r[1])===null||t===void 0||(t=t.split(")")[0])===null||t===void 0?void 0:t.split(",");if(n==null||n.length!==4)return null;var a=n.map(o=>parseFloat(o));return[a[0],a[1],a[2],a[3]]},j8=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];if(r.length===1)switch(r[0]){case"linear":return[0,0,1,1];case"ease":return[.25,.1,.25,1];case"ease-in":return[.42,0,1,1];case"ease-out":return[.42,0,.58,1];case"ease-in-out":return[0,0,.58,1];default:{var a=k8(r[0]);if(a)return a}}return r.length===4?r:[0,0,1,1]},S8=(e,t,r,n)=>{var a=Gk(e,r),o=Gk(t,n),u=w8(e,r),c=h=>h>1?1:h<0?0:h,f=h=>{for(var m=h>1?1:h,g=m,v=0;v<8;++v){var b=a(g)-m,j=u(g);if(Math.abs(b-m)<jf||j<jf)return o(g);g=c(g-b/j)}return o(g)};return f.isStepper=!1,f},Vk=function(){return S8(...j8(...arguments))},N8=function(){for(var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=t.stiff,n=r===void 0?100:r,a=t.damping,o=a===void 0?8:a,u=t.dt,c=u===void 0?16.67:u,f=1,h=[0],m=0,g=0,v=1e4,b=0;b<v;){var j=-(m-f)*n,k=g*o;if(g+=(j-k)*c/1e3,m+=g*c/1e3,h.push(m),Math.abs(m-f)<jf&&Math.abs(g)<jf)break;b++}h[h.length-1]=f;var S=h.length-1;return N=>{var E,A,P;if(N<=0)return 0;if(N>=1)return f;var _=N*S,O=Math.floor(_),D=_-O;return((E=h[O])!==null&&E!==void 0?E:0)+(((A=h[O+1])!==null&&A!==void 0?A:0)-((P=h[O])!==null&&P!==void 0?P:0))*D}},E8=e=>{if(typeof e=="string")switch(e){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return Vk(e);case"spring":return N8();default:if(e.split("(")[0]==="cubic-bezier")return Vk(e)}return typeof e=="function"?e:null},A8=(e,t,r)=>{var n,a=o=>{var u=t.tick(o);if(t.getState()==="active"){if(r(t.getInterpolated()),t.getProgress()===1){t.complete(),n=void 0;return}n=e.setTimeout(a,u);return}n=e.setTimeout(a,u)};return n=e.setTimeout(a,0),()=>{var o;return(o=n)===null||o===void 0?void 0:o()}},dA=y.createContext(A8);dA.Provider;function C8(e){var t=y.useContext(dA);return y.useMemo(()=>e??t,[e,t])}function P8(e,t,r){return(t=O8(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function O8(e){var t=_8(e,"string");return typeof t=="symbol"?t:t+""}function _8(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var qk="init",Qk="pending",Yk="active",M8="completed";function gg(e){return Math.max(0,e)}class I8{getAnimationStartedTime(){return this.animationStartedTime}getBeginStartedTime(){return this.beginStartedTime}constructor(t){var r;P8(this,"state",qk),this.animationId=t.animationId,this.onAnimationEnd=t.onAnimationEnd,this.animationDuration=gg(t.animationDuration),this.animationBegin=gg(t.animationBegin),this.progress=0,this.from=t.from,this.to=t.to,this.easing=t.easing,(r=t.onAnimationStart)===null||r===void 0||r.call(t)}getState(){return this.state}getEasing(){return this.easing}getAnimationDuration(){return this.animationDuration}tick(t){if(this.getState()===qk)return this.state=Qk,this.beginStartedTime=t,this.animationBegin;if(this.getState()===Qk){if(this.beginStartedTime==null)throw new Error;var r=t-this.beginStartedTime;return r>=this.animationBegin?(this.state=Yk,this.animationStartedTime=t,this.nextAnimationUpdate(0)):gg(this.animationBegin-r)}if(this.getState()===Yk){if(this.animationStartedTime==null)throw new Error;var n=t-this.animationStartedTime;return this.setProgress(n/this.animationDuration),this.nextAnimationUpdate(n)}return 0}setProgress(t){this.progress=Math.min(1,Math.max(0,t))}getProgress(){return this.progress}complete(){if(this.progress=1,this.state==="active"){var t;(t=this.onAnimationEnd)===null||t===void 0||t.call(this)}this.state=M8}getFrom(){return this.from}getTo(){return this.to}getAnimationId(){return this.animationId}getAnimationBegin(){return this.animationBegin}}class T8 extends I8{nextAnimationUpdate(){return 0}getInterpolated(){return this.easing(li(this.getFrom(),this.getTo(),this.getProgress()))}}class D8{setTimeout(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=performance.now(),a=null,o=u=>{u-n>=r?t(u):a=requestAnimationFrame(o)};return a=requestAnimationFrame(o),()=>{a!=null&&cancelAnimationFrame(a)}}}function R8(e,t){return F8(e)||z8(e,t)||$8(e,t)||L8()}function L8(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $8(e,t){if(e){if(typeof e=="string")return Xk(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Xk(e,t):void 0}}function Xk(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function z8(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function F8(e){if(Array.isArray(e))return e}var B8={begin:0,duration:1e3,easing:"ease",isActive:!0,canBegin:!0,onAnimationEnd:()=>{},onAnimationStart:()=>{}},Zk=0,vg=1;function fA(e){var t=Jr(e,B8),r=t.animationId,n=t.isActive,a=t.canBegin,o=t.duration,u=t.easing,c=t.begin,f=t.onAnimationEnd,h=t.onAnimationStart,m=t.children,g=sA(),v=n==="auto"?!Yu.isSsr&&!g:n,b=C8(t.animationController),j=y.useState(v?Zk:vg),k=R8(j,2),S=k[0],N=k[1];return y.useEffect(()=>{v||N(vg)},[v]),y.useEffect(()=>{var E=E8(u);if(!v||!a||E==null)return Vs;var A=new D8,P=new T8({animationId:r,easing:E,animationDuration:o,animationBegin:c,onAnimationStart:h,onAnimationEnd:f,from:Zk,to:vg});return b(A,P,N)},[b,r,v,a,o,u,c,h,f]),m(Number(S))}function hA(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"animation-",r=y.useRef(bu(t)),n=y.useRef(e);return n.current!==e&&(r.current=bu(t),n.current=e),r.current}var U8=e=>e.replace(/([A-Z])/g,t=>"-".concat(t.toLowerCase())),H8=(e,t,r)=>e.map(n=>"".concat(U8(n)," ").concat(t,"ms ").concat(r)).join(","),W8=["radius"],K8=["radius"],Jk,ej,tj,rj,nj,ij,aj,oj,sj,lj;function uj(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function cj(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?uj(Object(r),!0).forEach(function(n){G8(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):uj(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function G8(e,t,r){return(t=V8(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function V8(e){var t=q8(e,"string");return typeof t=="symbol"?t:t+""}function q8(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Sf(){return Sf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Sf.apply(null,arguments)}function dj(e,t){if(e==null)return{};var r,n,a=Q8(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function Q8(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function Y8(e,t){return eF(e)||J8(e,t)||Z8(e,t)||X8()}function X8(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Z8(e,t){if(e){if(typeof e=="string")return fj(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?fj(e,t):void 0}}function fj(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function J8(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function eF(e){if(Array.isArray(e))return e}function An(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var hj=(e,t,r,n,a)=>{var o=la(r),u=la(n),c=Math.min(Math.abs(o)/2,Math.abs(u)/2),f=u>=0?1:-1,h=o>=0?1:-1,m=u>=0&&o>=0||u<0&&o<0?1:0,g;if(c>0&&Array.isArray(a)){for(var v=[0,0,0,0],b=0,j=4;b<j;b++){var k,S=(k=a[b])!==null&&k!==void 0?k:0;v[b]=S>c?c:S}g=Ut(Jk||(Jk=An(["M",",",""])),e,t+f*v[0]),v[0]>0&&(g+=Ut(ej||(ej=An(["A ",",",",0,0,",",",",",""])),v[0],v[0],m,e+h*v[0],t)),g+=Ut(tj||(tj=An(["L ",",",""])),e+r-h*v[1],t),v[1]>0&&(g+=Ut(rj||(rj=An(["A ",",",",0,0,",`,
|
||
`,",",""])),v[1],v[1],m,e+r,t+f*v[1])),g+=Ut(nj||(nj=An(["L ",",",""])),e+r,t+n-f*v[2]),v[2]>0&&(g+=Ut(ij||(ij=An(["A ",",",",0,0,",`,
|
||
`,",",""])),v[2],v[2],m,e+r-h*v[2],t+n)),g+=Ut(aj||(aj=An(["L ",",",""])),e+h*v[3],t+n),v[3]>0&&(g+=Ut(oj||(oj=An(["A ",",",",0,0,",`,
|
||
`,",",""])),v[3],v[3],m,e,t+n-f*v[3])),g+="Z"}else if(c>0&&a===+a&&a>0){var N=Math.min(c,a);g=Ut(sj||(sj=An(["M ",",",`
|
||
A `,",",",0,0,",",",",",`
|
||
L `,",",`
|
||
A `,",",",0,0,",",",",",`
|
||
L `,",",`
|
||
A `,",",",0,0,",",",",",`
|
||
L `,",",`
|
||
A `,",",",0,0,",",",","," Z"])),e,t+f*N,N,N,m,e+h*N,t,e+r-h*N,t,N,N,m,e+r,t+f*N,e+r,t+n-f*N,N,N,m,e+r-h*N,t+n,e+h*N,t+n,N,N,m,e,t+n-f*N)}else g=Ut(lj||(lj=An(["M ",","," h "," v "," h "," Z"])),e,t,r,n,-r);return g},mj={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},tF=e=>{var t=Jr(e,mj),r=y.useRef(null),n=y.useState(-1),a=Y8(n,2),o=a[0],u=a[1];y.useEffect(()=>{if(r.current&&r.current.getTotalLength)try{var X=r.current.getTotalLength();X&&u(X)}catch{}},[]);var c=t.x,f=t.y,h=t.width,m=t.height,g=t.radius,v=t.className,b=t.animationEasing,j=t.animationDuration,k=t.animationBegin,S=t.isAnimationActive,N=t.isUpdateAnimationActive,E=y.useRef(h),A=y.useRef(m),P=y.useRef(c),_=y.useRef(f),O=y.useMemo(()=>({x:c,y:f,width:h,height:m,radius:g}),[c,f,h,m,g]),D=hA(O,"rectangle-");if(c!==+c||f!==+f||h!==+h||m!==+m||h===0||m===0)return null;var B=rt("recharts-rectangle",v);if(!N){var F=Yr(t);F.radius;var z=dj(F,W8);return y.createElement("path",Sf({},z,{x:la(c),y:la(f),width:la(h),height:la(m),radius:typeof g=="number"?g:void 0,className:B,d:hj(c,f,h,m,g)}))}var Y=E.current,U=A.current,he=P.current,ue=_.current,ge="0px ".concat(o===-1?1:o,"px"),ie="".concat(o,"px ").concat(o,"px"),se=H8(["strokeDasharray"],j,typeof b=="string"?b:mj.animationEasing);return y.createElement(fA,{animationId:D,key:D,canBegin:o>0,duration:j,easing:b,isActive:N,begin:k},X=>{var te=li(Y,h,X),J=li(U,m,X),I=li(he,c,X),M=li(ue,f,X);r.current&&(E.current=te,A.current=J,P.current=I,_.current=M);var H;S?X>0?H={transition:se,strokeDasharray:ie}:H={strokeDasharray:ge}:H={strokeDasharray:ie};var ne=Yr(t);ne.radius;var Z=dj(ne,K8);return y.createElement("path",Sf({},Z,{radius:typeof g=="number"?g:void 0,className:B,d:hj(I,M,te,J,g),ref:r,style:cj(cj({},H),t.style)}))})};function pj(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function gj(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pj(Object(r),!0).forEach(function(n){rF(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pj(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function rF(e,t,r){return(t=nF(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function nF(e){var t=iF(e,"string");return typeof t=="symbol"?t:t+""}function iF(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Nf=Math.PI/180,aF=e=>e*180/Math.PI,Kt=(e,t,r,n)=>({x:e+Math.cos(-Nf*n)*r,y:t+Math.sin(-Nf*n)*r}),oF=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(t-(n.left||0)-(n.right||0)),Math.abs(r-(n.top||0)-(n.bottom||0)))/2},sF=(e,t)=>{var r=e.x,n=e.y,a=t.x,o=t.y;return Math.sqrt((r-a)**2+(n-o)**2)},lF=(e,t)=>{var r=e.x,n=e.y,a=t.cx,o=t.cy,u=sF({x:r,y:n},{x:a,y:o});if(u<=0)return{radius:u,angle:0};var c=(r-a)/u,f=Math.acos(c);return n>o&&(f=2*Math.PI-f),{radius:u,angle:aF(f),angleInRadian:f}},uF=e=>{var t=e.startAngle,r=e.endAngle,n=Math.floor(t/360),a=Math.floor(r/360),o=Math.min(n,a);return{startAngle:t-o*360,endAngle:r-o*360}},cF=(e,t)=>{var r=t.startAngle,n=t.endAngle,a=Math.floor(r/360),o=Math.floor(n/360),u=Math.min(a,o);return e+u*360},dF=(e,t)=>{var r=e.relativeX,n=e.relativeY,a=lF({x:r,y:n},t),o=a.radius,u=a.angle,c=t.innerRadius,f=t.outerRadius;if(o<c||o>f||o===0)return null;var h=uF(t),m=h.startAngle,g=h.endAngle,v=u,b;if(m<=g){for(;v>g;)v-=360;for(;v<m;)v+=360;b=v>=m&&v<=g}else{for(;v>m;)v-=360;for(;v<g;)v+=360;b=v>=g&&v<=m}return b?gj(gj({},t),{},{radius:o,angle:cF(v,t)}):null};function mA(e){var t=e.cx,r=e.cy,n=e.radius,a=e.startAngle,o=e.endAngle,u=Kt(t,r,n,a),c=Kt(t,r,n,o);return{points:[u,c],cx:t,cy:r,radius:n,startAngle:a,endAngle:o}}var vj,yj,xj,bj,wj,kj,jj;function Bv(){return Bv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Bv.apply(null,arguments)}function Ha(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var fF=(e,t)=>{var r=Vr(t-e),n=Math.min(Math.abs(t-e),359.999);return r*n},Md=e=>{var t=e.cx,r=e.cy,n=e.radius,a=e.angle,o=e.sign,u=e.isExternal,c=e.cornerRadius,f=e.cornerIsExternal,h=c*(u?1:-1)+n,m=Math.asin(c/h)/Nf,g=f?a:a+o*m,v=Kt(t,r,h,g),b=Kt(t,r,n,g),j=f?a-o*m:a,k=Kt(t,r,h*Math.cos(m*Nf),j);return{center:v,circleTangency:b,lineTangency:k,theta:m}},pA=e=>{var t=e.cx,r=e.cy,n=e.innerRadius,a=e.outerRadius,o=e.startAngle,u=e.endAngle,c=fF(o,u),f=o+c,h=Kt(t,r,a,o),m=Kt(t,r,a,f),g=Ut(vj||(vj=Ha(["M ",",",`
|
||
A `,",",`,0,
|
||
`,",",`,
|
||
`,",",`
|
||
`])),h.x,h.y,a,a,+(Math.abs(c)>180),+(o>f),m.x,m.y);if(n>0){var v=Kt(t,r,n,o),b=Kt(t,r,n,f);g+=Ut(yj||(yj=Ha(["L ",",",`
|
||
A `,",",`,0,
|
||
`,",",`,
|
||
`,","," Z"])),b.x,b.y,n,n,+(Math.abs(c)>180),+(o<=f),v.x,v.y)}else g+=Ut(xj||(xj=Ha(["L ",","," Z"])),t,r);return g},hF=e=>{var t=e.cx,r=e.cy,n=e.innerRadius,a=e.outerRadius,o=e.cornerRadius,u=e.forceCornerRadius,c=e.cornerIsExternal,f=e.startAngle,h=e.endAngle,m=Vr(h-f),g=Md({cx:t,cy:r,radius:a,angle:f,sign:m,cornerRadius:o,cornerIsExternal:c}),v=g.circleTangency,b=g.lineTangency,j=g.theta,k=Md({cx:t,cy:r,radius:a,angle:h,sign:-m,cornerRadius:o,cornerIsExternal:c}),S=k.circleTangency,N=k.lineTangency,E=k.theta,A=c?Math.abs(f-h):Math.abs(f-h)-j-E;if(A<0)return u?Ut(bj||(bj=Ha(["M ",",",`
|
||
a`,",",",0,0,1,",`,0
|
||
a`,",",",0,0,1,",`,0
|
||
`])),b.x,b.y,o,o,o*2,o,o,-o*2):pA({cx:t,cy:r,innerRadius:n,outerRadius:a,startAngle:f,endAngle:h});var P=Ut(wj||(wj=Ha(["M ",",",`
|
||
A`,",",",0,0,",",",",",`
|
||
A`,",",",0,",",",",",",",`
|
||
A`,",",",0,0,",",",",",`
|
||
`])),b.x,b.y,o,o,+(m<0),v.x,v.y,a,a,+(A>180),+(m<0),S.x,S.y,o,o,+(m<0),N.x,N.y);if(n>0){var _=Md({cx:t,cy:r,radius:n,angle:f,sign:m,isExternal:!0,cornerRadius:o,cornerIsExternal:c}),O=_.circleTangency,D=_.lineTangency,B=_.theta,F=Md({cx:t,cy:r,radius:n,angle:h,sign:-m,isExternal:!0,cornerRadius:o,cornerIsExternal:c}),z=F.circleTangency,Y=F.lineTangency,U=F.theta,he=c?Math.abs(f-h):Math.abs(f-h)-B-U;if(he<0&&o===0)return"".concat(P,"L").concat(t,",").concat(r,"Z");P+=Ut(kj||(kj=Ha(["L",",",`
|
||
A`,",",",0,0,",",",",",`
|
||
A`,",",",0,",",",",",",",`
|
||
A`,",",",0,0,",",",",","Z"])),Y.x,Y.y,o,o,+(m<0),z.x,z.y,n,n,+(he>180),+(m>0),O.x,O.y,o,o,+(m<0),D.x,D.y)}else P+=Ut(jj||(jj=Ha(["L",",","Z"])),t,r);return P},mF={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},pF=e=>{var t=Jr(e,mF),r=t.cx,n=t.cy,a=t.innerRadius,o=t.outerRadius,u=t.cornerRadius,c=t.forceCornerRadius,f=t.cornerIsExternal,h=t.startAngle,m=t.endAngle,g=t.className;if(o<a||h===m)return null;var v=rt("recharts-sector",g),b=o-a,j=pa(u,b,0,!0),k;return j>0&&Math.abs(h-m)<360?k=hF({cx:r,cy:n,innerRadius:a,outerRadius:o,cornerRadius:Math.min(j,b/2),forceCornerRadius:c,cornerIsExternal:f,startAngle:h,endAngle:m}):k=pA({cx:r,cy:n,innerRadius:a,outerRadius:o,startAngle:h,endAngle:m}),y.createElement("path",Bv({},Yr(t),{className:v,d:k}))};function gF(e,t,r){if(e==="horizontal")return[{x:t.x,y:r.top},{x:t.x,y:r.top+r.height}];if(e==="vertical")return[{x:r.left,y:t.y},{x:r.left+r.width,y:t.y}];if(YE(t)){if(e==="centric"){var n=t.cx,a=t.cy,o=t.innerRadius,u=t.outerRadius,c=t.angle,f=Kt(n,a,o,c),h=Kt(n,a,u,c);return[{x:f.x,y:f.y},{x:h.x,y:h.y}]}return mA(t)}}function vF(e){return c5(e)?NaN:Number(e)}function yg(e){return e?(e=vF(e),e===1/0||e===-1/0?(e<0?-1:1)*Number.MAX_VALUE:e===e?e:0):e===0?e:0}function gA(e,t,r){r&&typeof r!="number"&&wv(e,t,r)&&(t=r=void 0),e=yg(e),t===void 0?(t=e,e=0):t=yg(t),r=r===void 0?e<t?1:-1:yg(r);const n=Math.max(Math.ceil((t-e)/(r||1)),0),a=new Array(n);for(let o=0;o<n;o++)a[o]=e,e+=r;return a}var bn=e=>e.chartData,Hy=q([bn],e=>{var t=e.chartData!=null?e.chartData.length-1:0;return{chartData:e.chartData,computedData:e.computedData,dataEndIndex:t,dataStartIndex:0}}),_h=(e,t,r,n)=>n?Hy(e):bn(e),yF=(e,t,r)=>r?Hy(e):bn(e),xF=q([_h],e=>{var t=e.chartData,r=e.dataStartIndex,n=e.dataEndIndex;return t!=null?t.slice(r,n+1):[]});q([Hy],e=>{var t=e.chartData,r=e.dataStartIndex,n=e.dataEndIndex;return t!=null?t.slice(r,n+1):[]});var bF=q([bn],e=>{var t=e.chartData,r=e.dataStartIndex,n=e.dataEndIndex;return t!=null?t.slice(r,n+1):[]});function Wy(e,t){return SF(e)||jF(e,t)||kF(e,t)||wF()}function wF(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function kF(e,t){if(e){if(typeof e=="string")return Sj(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Sj(e,t):void 0}}function Sj(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function jF(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function SF(e){if(Array.isArray(e))return e}function Rn(e){if(Array.isArray(e)&&e.length===2){var t=Wy(e,2),r=t[0],n=t[1];if(He(r)&&He(n))return!0}return!1}function Nj(e,t,r){return r?e:[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}function vA(e,t){if(t&&typeof e!="function"&&Array.isArray(e)&&e.length===2){var r=Wy(e,2),n=r[0],a=r[1],o,u;if(He(n))o=n;else if(typeof n=="function")return;if(He(a))u=a;else if(typeof a=="function")return;var c=[o,u];if(Rn(c))return c}}function NF(e,t,r){if(!(!r&&t==null)){if(typeof e=="function"&&t!=null)try{var n=e(t,r);if(Rn(n))return Nj(n,t,r)}catch{}if(Array.isArray(e)&&e.length===2){var a=Wy(e,2),o=a[0],u=a[1],c,f;if(o==="auto")t!=null&&(c=Math.min(...t));else if(Ee(o))c=o;else if(typeof o=="function")try{t!=null&&(c=o(t==null?void 0:t[0]))}catch{}else if(typeof o=="string"&&vk.test(o)){var h=vk.exec(o);if(h==null||h[1]==null||t==null)c=void 0;else{var m=+h[1];c=t[0]-m}}else c=t==null?void 0:t[0];if(u==="auto")t!=null&&(f=Math.max(...t));else if(Ee(u))f=u;else if(typeof u=="function")try{t!=null&&(f=u(t==null?void 0:t[1]))}catch{}else if(typeof u=="string"&&yk.test(u)){var g=yk.exec(u);if(g==null||g[1]==null||t==null)f=void 0;else{var v=+g[1];f=t[1]+v}}else f=t==null?void 0:t[1];var b=[c,f];if(Rn(b))return t==null?b:Nj(b,t,r)}}}var Qs=1e9,EF={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Gy,ut=!0,Zr="[DecimalError] ",io=Zr+"Invalid argument: ",Ky=Zr+"Exponent out of range: ",Ys=Math.floor,Fa=Math.pow,AF=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Tr,Tt=1e7,st=7,yA=9007199254740991,Ef=Ys(yA/st),be={};be.absoluteValue=be.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};be.comparedTo=be.cmp=function(e){var t,r,n,a,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(n=o.d.length,a=e.d.length,t=0,r=n<a?n:a;t<r;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return n===a?0:n>a^o.s<0?1:-1};be.decimalPlaces=be.dp=function(){var e=this,t=e.d.length-1,r=(t-e.e)*st;if(t=e.d[t],t)for(;t%10==0;t/=10)r--;return r<0?0:r};be.dividedBy=be.div=function(e){return fi(this,new this.constructor(e))};be.dividedToIntegerBy=be.idiv=function(e){var t=this,r=t.constructor;return Je(fi(t,new r(e),0,1),r.precision)};be.equals=be.eq=function(e){return!this.cmp(e)};be.exponent=function(){return kt(this)};be.greaterThan=be.gt=function(e){return this.cmp(e)>0};be.greaterThanOrEqualTo=be.gte=function(e){return this.cmp(e)>=0};be.isInteger=be.isint=function(){return this.e>this.d.length-2};be.isNegative=be.isneg=function(){return this.s<0};be.isPositive=be.ispos=function(){return this.s>0};be.isZero=function(){return this.s===0};be.lessThan=be.lt=function(e){return this.cmp(e)<0};be.lessThanOrEqualTo=be.lte=function(e){return this.cmp(e)<1};be.logarithm=be.log=function(e){var t,r=this,n=r.constructor,a=n.precision,o=a+5;if(e===void 0)e=new n(10);else if(e=new n(e),e.s<1||e.eq(Tr))throw Error(Zr+"NaN");if(r.s<1)throw Error(Zr+(r.s?"NaN":"-Infinity"));return r.eq(Tr)?new n(0):(ut=!1,t=fi(Au(r,o),Au(e,o),o),ut=!0,Je(t,a))};be.minus=be.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?wA(t,e):xA(t,(e.s=-e.s,e))};be.modulo=be.mod=function(e){var t,r=this,n=r.constructor,a=n.precision;if(e=new n(e),!e.s)throw Error(Zr+"NaN");return r.s?(ut=!1,t=fi(r,e,0,1).times(e),ut=!0,r.minus(t)):Je(new n(r),a)};be.naturalExponential=be.exp=function(){return bA(this)};be.naturalLogarithm=be.ln=function(){return Au(this)};be.negated=be.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};be.plus=be.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?xA(t,e):wA(t,(e.s=-e.s,e))};be.precision=be.sd=function(e){var t,r,n,a=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(io+e);if(t=kt(a)+1,n=a.d.length-1,r=n*st+1,n=a.d[n],n){for(;n%10==0;n/=10)r--;for(n=a.d[0];n>=10;n/=10)r++}return e&&t>r?t:r};be.squareRoot=be.sqrt=function(){var e,t,r,n,a,o,u,c=this,f=c.constructor;if(c.s<1){if(!c.s)return new f(0);throw Error(Zr+"NaN")}for(e=kt(c),ut=!1,a=Math.sqrt(+c),a==0||a==1/0?(t=Dn(c.d),(t.length+e)%2==0&&(t+="0"),a=Math.sqrt(t),e=Ys((e+1)/2)-(e<0||e%2),a==1/0?t="5e"+e:(t=a.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),n=new f(t)):n=new f(a.toString()),r=f.precision,a=u=r+3;;)if(o=n,n=o.plus(fi(c,o,u+2)).times(.5),Dn(o.d).slice(0,u)===(t=Dn(n.d)).slice(0,u)){if(t=t.slice(u-3,u+1),a==u&&t=="4999"){if(Je(o,r+1,0),o.times(o).eq(c)){n=o;break}}else if(t!="9999")break;u+=4}return ut=!0,Je(n,r)};be.times=be.mul=function(e){var t,r,n,a,o,u,c,f,h,m=this,g=m.constructor,v=m.d,b=(e=new g(e)).d;if(!m.s||!e.s)return new g(0);for(e.s*=m.s,r=m.e+e.e,f=v.length,h=b.length,f<h&&(o=v,v=b,b=o,u=f,f=h,h=u),o=[],u=f+h,n=u;n--;)o.push(0);for(n=h;--n>=0;){for(t=0,a=f+n;a>n;)c=o[a]+b[n]*v[a-n-1]+t,o[a--]=c%Tt|0,t=c/Tt|0;o[a]=(o[a]+t)%Tt|0}for(;!o[--u];)o.pop();return t?++r:o.shift(),e.d=o,e.e=r,ut?Je(e,g.precision):e};be.toDecimalPlaces=be.todp=function(e,t){var r=this,n=r.constructor;return r=new n(r),e===void 0?r:(Hn(e,0,Qs),t===void 0?t=n.rounding:Hn(t,0,8),Je(r,e+kt(r)+1,t))};be.toExponential=function(e,t){var r,n=this,a=n.constructor;return e===void 0?r=mo(n,!0):(Hn(e,0,Qs),t===void 0?t=a.rounding:Hn(t,0,8),n=Je(new a(n),e+1,t),r=mo(n,!0,e+1)),r};be.toFixed=function(e,t){var r,n,a=this,o=a.constructor;return e===void 0?mo(a):(Hn(e,0,Qs),t===void 0?t=o.rounding:Hn(t,0,8),n=Je(new o(a),e+kt(a)+1,t),r=mo(n.abs(),!1,e+kt(n)+1),a.isneg()&&!a.isZero()?"-"+r:r)};be.toInteger=be.toint=function(){var e=this,t=e.constructor;return Je(new t(e),kt(e)+1,t.rounding)};be.toNumber=function(){return+this};be.toPower=be.pow=function(e){var t,r,n,a,o,u,c=this,f=c.constructor,h=12,m=+(e=new f(e));if(!e.s)return new f(Tr);if(c=new f(c),!c.s){if(e.s<1)throw Error(Zr+"Infinity");return c}if(c.eq(Tr))return c;if(n=f.precision,e.eq(Tr))return Je(c,n);if(t=e.e,r=e.d.length-1,u=t>=r,o=c.s,u){if((r=m<0?-m:m)<=yA){for(a=new f(Tr),t=Math.ceil(n/st+4),ut=!1;r%2&&(a=a.times(c),Aj(a.d,t)),r=Ys(r/2),r!==0;)c=c.times(c),Aj(c.d,t);return ut=!0,e.s<0?new f(Tr).div(a):Je(a,n)}}else if(o<0)throw Error(Zr+"NaN");return o=o<0&&e.d[Math.max(t,r)]&1?-1:1,c.s=1,ut=!1,a=e.times(Au(c,n+h)),ut=!0,a=bA(a),a.s=o,a};be.toPrecision=function(e,t){var r,n,a=this,o=a.constructor;return e===void 0?(r=kt(a),n=mo(a,r<=o.toExpNeg||r>=o.toExpPos)):(Hn(e,1,Qs),t===void 0?t=o.rounding:Hn(t,0,8),a=Je(new o(a),e,t),r=kt(a),n=mo(a,e<=r||r<=o.toExpNeg,e)),n};be.toSignificantDigits=be.tosd=function(e,t){var r=this,n=r.constructor;return e===void 0?(e=n.precision,t=n.rounding):(Hn(e,1,Qs),t===void 0?t=n.rounding:Hn(t,0,8)),Je(new n(r),e,t)};be.toString=be.valueOf=be.val=be.toJSON=be[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=kt(e),r=e.constructor;return mo(e,t<=r.toExpNeg||t>=r.toExpPos)};function xA(e,t){var r,n,a,o,u,c,f,h,m=e.constructor,g=m.precision;if(!e.s||!t.s)return t.s||(t=new m(e)),ut?Je(t,g):t;if(f=e.d,h=t.d,u=e.e,a=t.e,f=f.slice(),o=u-a,o){for(o<0?(n=f,o=-o,c=h.length):(n=h,a=u,c=f.length),u=Math.ceil(g/st),c=u>c?u+1:c+1,o>c&&(o=c,n.length=1),n.reverse();o--;)n.push(0);n.reverse()}for(c=f.length,o=h.length,c-o<0&&(o=c,n=h,h=f,f=n),r=0;o;)r=(f[--o]=f[o]+h[o]+r)/Tt|0,f[o]%=Tt;for(r&&(f.unshift(r),++a),c=f.length;f[--c]==0;)f.pop();return t.d=f,t.e=a,ut?Je(t,g):t}function Hn(e,t,r){if(e!==~~e||e<t||e>r)throw Error(io+e)}function Dn(e){var t,r,n,a=e.length-1,o="",u=e[0];if(a>0){for(o+=u,t=1;t<a;t++)n=e[t]+"",r=st-n.length,r&&(o+=Xi(r)),o+=n;u=e[t],n=u+"",r=st-n.length,r&&(o+=Xi(r))}else if(u===0)return"0";for(;u%10===0;)u/=10;return o+u}var fi=(function(){function e(n,a){var o,u=0,c=n.length;for(n=n.slice();c--;)o=n[c]*a+u,n[c]=o%Tt|0,u=o/Tt|0;return u&&n.unshift(u),n}function t(n,a,o,u){var c,f;if(o!=u)f=o>u?1:-1;else for(c=f=0;c<o;c++)if(n[c]!=a[c]){f=n[c]>a[c]?1:-1;break}return f}function r(n,a,o){for(var u=0;o--;)n[o]-=u,u=n[o]<a[o]?1:0,n[o]=u*Tt+n[o]-a[o];for(;!n[0]&&n.length>1;)n.shift()}return function(n,a,o,u){var c,f,h,m,g,v,b,j,k,S,N,E,A,P,_,O,D,B,F=n.constructor,z=n.s==a.s?1:-1,Y=n.d,U=a.d;if(!n.s)return new F(n);if(!a.s)throw Error(Zr+"Division by zero");for(f=n.e-a.e,D=U.length,_=Y.length,b=new F(z),j=b.d=[],h=0;U[h]==(Y[h]||0);)++h;if(U[h]>(Y[h]||0)&&--f,o==null?E=o=F.precision:u?E=o+(kt(n)-kt(a))+1:E=o,E<0)return new F(0);if(E=E/st+2|0,h=0,D==1)for(m=0,U=U[0],E++;(h<_||m)&&E--;h++)A=m*Tt+(Y[h]||0),j[h]=A/U|0,m=A%U|0;else{for(m=Tt/(U[0]+1)|0,m>1&&(U=e(U,m),Y=e(Y,m),D=U.length,_=Y.length),P=D,k=Y.slice(0,D),S=k.length;S<D;)k[S++]=0;B=U.slice(),B.unshift(0),O=U[0],U[1]>=Tt/2&&++O;do m=0,c=t(U,k,D,S),c<0?(N=k[0],D!=S&&(N=N*Tt+(k[1]||0)),m=N/O|0,m>1?(m>=Tt&&(m=Tt-1),g=e(U,m),v=g.length,S=k.length,c=t(g,k,v,S),c==1&&(m--,r(g,D<v?B:U,v))):(m==0&&(c=m=1),g=U.slice()),v=g.length,v<S&&g.unshift(0),r(k,g,S),c==-1&&(S=k.length,c=t(U,k,D,S),c<1&&(m++,r(k,D<S?B:U,S))),S=k.length):c===0&&(m++,k=[0]),j[h++]=m,c&&k[0]?k[S++]=Y[P]||0:(k=[Y[P]],S=1);while((P++<_||k[0]!==void 0)&&E--)}return j[0]||j.shift(),b.e=f,Je(b,u?o+kt(b)+1:o)}})();function bA(e,t){var r,n,a,o,u,c,f=0,h=0,m=e.constructor,g=m.precision;if(kt(e)>16)throw Error(Ky+kt(e));if(!e.s)return new m(Tr);for(ut=!1,c=g,u=new m(.03125);e.abs().gte(.1);)e=e.times(u),h+=5;for(n=Math.log(Fa(2,h))/Math.LN10*2+5|0,c+=n,r=a=o=new m(Tr),m.precision=c;;){if(a=Je(a.times(e),c),r=r.times(++f),u=o.plus(fi(a,r,c)),Dn(u.d).slice(0,c)===Dn(o.d).slice(0,c)){for(;h--;)o=Je(o.times(o),c);return m.precision=g,t==null?(ut=!0,Je(o,g)):o}o=u}}function kt(e){for(var t=e.e*st,r=e.d[0];r>=10;r/=10)t++;return t}function xg(e,t,r){if(t>e.LN10.sd())throw ut=!0,r&&(e.precision=r),Error(Zr+"LN10 precision limit exceeded");return Je(new e(e.LN10),t)}function Xi(e){for(var t="";e--;)t+="0";return t}function Au(e,t){var r,n,a,o,u,c,f,h,m,g=1,v=10,b=e,j=b.d,k=b.constructor,S=k.precision;if(b.s<1)throw Error(Zr+(b.s?"NaN":"-Infinity"));if(b.eq(Tr))return new k(0);if(t==null?(ut=!1,h=S):h=t,b.eq(10))return t==null&&(ut=!0),xg(k,h);if(h+=v,k.precision=h,r=Dn(j),n=r.charAt(0),o=kt(b),Math.abs(o)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)b=b.times(e),r=Dn(b.d),n=r.charAt(0),g++;o=kt(b),n>1?(b=new k("0."+r),o++):b=new k(n+"."+r.slice(1))}else return f=xg(k,h+2,S).times(o+""),b=Au(new k(n+"."+r.slice(1)),h-v).plus(f),k.precision=S,t==null?(ut=!0,Je(b,S)):b;for(c=u=b=fi(b.minus(Tr),b.plus(Tr),h),m=Je(b.times(b),h),a=3;;){if(u=Je(u.times(m),h),f=c.plus(fi(u,new k(a),h)),Dn(f.d).slice(0,h)===Dn(c.d).slice(0,h))return c=c.times(2),o!==0&&(c=c.plus(xg(k,h+2,S).times(o+""))),c=fi(c,new k(g),h),k.precision=S,t==null?(ut=!0,Je(c,S)):c;c=f,a+=2}}function Ej(e,t){var r,n,a;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;t.charCodeAt(n)===48;)++n;for(a=t.length;t.charCodeAt(a-1)===48;)--a;if(t=t.slice(n,a),t){if(a-=n,r=r-n-1,e.e=Ys(r/st),e.d=[],n=(r+1)%st,r<0&&(n+=st),n<a){for(n&&e.d.push(+t.slice(0,n)),a-=st;n<a;)e.d.push(+t.slice(n,n+=st));t=t.slice(n),n=st-t.length}else n-=a;for(;n--;)t+="0";if(e.d.push(+t),ut&&(e.e>Ef||e.e<-Ef))throw Error(Ky+r)}else e.s=0,e.e=0,e.d=[0];return e}function Je(e,t,r){var n,a,o,u,c,f,h,m,g=e.d;for(u=1,o=g[0];o>=10;o/=10)u++;if(n=t-u,n<0)n+=st,a=t,h=g[m=0];else{if(m=Math.ceil((n+1)/st),o=g.length,m>=o)return e;for(h=o=g[m],u=1;o>=10;o/=10)u++;n%=st,a=n-st+u}if(r!==void 0&&(o=Fa(10,u-a-1),c=h/o%10|0,f=t<0||g[m+1]!==void 0||h%o,f=r<4?(c||f)&&(r==0||r==(e.s<0?3:2)):c>5||c==5&&(r==4||f||r==6&&(n>0?a>0?h/Fa(10,u-a):0:g[m-1])%10&1||r==(e.s<0?8:7))),t<1||!g[0])return f?(o=kt(e),g.length=1,t=t-o-1,g[0]=Fa(10,(st-t%st)%st),e.e=Ys(-t/st)||0):(g.length=1,g[0]=e.e=e.s=0),e;if(n==0?(g.length=m,o=1,m--):(g.length=m+1,o=Fa(10,st-n),g[m]=a>0?(h/Fa(10,u-a)%Fa(10,a)|0)*o:0),f)for(;;)if(m==0){(g[0]+=o)==Tt&&(g[0]=1,++e.e);break}else{if(g[m]+=o,g[m]!=Tt)break;g[m--]=0,o=1}for(n=g.length;g[--n]===0;)g.pop();if(ut&&(e.e>Ef||e.e<-Ef))throw Error(Ky+kt(e));return e}function wA(e,t){var r,n,a,o,u,c,f,h,m,g,v=e.constructor,b=v.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new v(e),ut?Je(t,b):t;if(f=e.d,g=t.d,n=t.e,h=e.e,f=f.slice(),u=h-n,u){for(m=u<0,m?(r=f,u=-u,c=g.length):(r=g,n=h,c=f.length),a=Math.max(Math.ceil(b/st),c)+2,u>a&&(u=a,r.length=1),r.reverse(),a=u;a--;)r.push(0);r.reverse()}else{for(a=f.length,c=g.length,m=a<c,m&&(c=a),a=0;a<c;a++)if(f[a]!=g[a]){m=f[a]<g[a];break}u=0}for(m&&(r=f,f=g,g=r,t.s=-t.s),c=f.length,a=g.length-c;a>0;--a)f[c++]=0;for(a=g.length;a>u;){if(f[--a]<g[a]){for(o=a;o&&f[--o]===0;)f[o]=Tt-1;--f[o],f[a]+=Tt}f[a]-=g[a]}for(;f[--c]===0;)f.pop();for(;f[0]===0;f.shift())--n;return f[0]?(t.d=f,t.e=n,ut?Je(t,b):t):new v(0)}function mo(e,t,r){var n,a=kt(e),o=Dn(e.d),u=o.length;return t?(r&&(n=r-u)>0?o=o.charAt(0)+"."+o.slice(1)+Xi(n):u>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(a<0?"e":"e+")+a):a<0?(o="0."+Xi(-a-1)+o,r&&(n=r-u)>0&&(o+=Xi(n))):a>=u?(o+=Xi(a+1-u),r&&(n=r-a-1)>0&&(o=o+"."+Xi(n))):((n=a+1)<u&&(o=o.slice(0,n)+"."+o.slice(n)),r&&(n=r-u)>0&&(a+1===u&&(o+="."),o+=Xi(n))),e.s<0?"-"+o:o}function Aj(e,t){if(e.length>t)return e.length=t,!0}function kA(e){var t,r,n;function a(o){var u=this;if(!(u instanceof a))return new a(o);if(u.constructor=a,o instanceof a){u.s=o.s,u.e=o.e,u.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(io+o);if(o>0)u.s=1;else if(o<0)o=-o,u.s=-1;else{u.s=0,u.e=0,u.d=[0];return}if(o===~~o&&o<1e7){u.e=0,u.d=[o];return}return Ej(u,o.toString())}else if(typeof o!="string")throw Error(io+o);if(o.charCodeAt(0)===45?(o=o.slice(1),u.s=-1):u.s=1,AF.test(o))Ej(u,o);else throw Error(io+o)}if(a.prototype=be,a.ROUND_UP=0,a.ROUND_DOWN=1,a.ROUND_CEIL=2,a.ROUND_FLOOR=3,a.ROUND_HALF_UP=4,a.ROUND_HALF_DOWN=5,a.ROUND_HALF_EVEN=6,a.ROUND_HALF_CEIL=7,a.ROUND_HALF_FLOOR=8,a.clone=kA,a.config=a.set=CF,e===void 0&&(e={}),e)for(n=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<n.length;)e.hasOwnProperty(r=n[t++])||(e[r]=this[r]);return a.config(e),a}function CF(e){if(!e||typeof e!="object")throw Error(Zr+"Object expected");var t,r,n,a=["precision",1,Qs,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<a.length;t+=3)if((n=e[r=a[t]])!==void 0)if(Ys(n)===n&&n>=a[t+1]&&n<=a[t+2])this[r]=n;else throw Error(io+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(io+r+": "+n);return this}var Gy=kA(EF);Tr=new Gy(1);const Ke=Gy;function jA(e){var t;return e===0?t=1:t=Math.floor(new Ke(e).abs().log(10).toNumber())+1,t}function SA(e,t,r){for(var n=new Ke(e),a=0,o=[];n.lt(t)&&a<1e5;)o.push(n.toNumber()),n=n.add(r),a++;return o}function Cu(e,t){return MF(e)||_F(e,t)||OF(e,t)||PF()}function PF(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function OF(e,t){if(e){if(typeof e=="string")return Cj(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Cj(e,t):void 0}}function Cj(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function _F(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function MF(e){if(Array.isArray(e))return e}var NA=e=>{var t=Cu(e,2),r=t[0],n=t[1],a=r,o=n;return r>n&&(a=n,o=r),[a,o]},Vy=(e,t,r)=>{if(e.lte(0))return new Ke(0);var n=jA(e.toNumber()),a=new Ke(10).pow(n),o=e.div(a),u=n!==1?.05:.1,c=new Ke(Math.ceil(o.div(u).toNumber())).add(r).mul(u),f=c.mul(a);return t?new Ke(f.toNumber()):new Ke(Math.ceil(f.toNumber()))},EA=(e,t,r)=>{var n;if(e.lte(0))return new Ke(0);var a=[1,2,2.5,5],o=e.toNumber(),u=Math.floor(new Ke(o).abs().log(10).toNumber()),c=new Ke(10).pow(u),f=e.div(c).toNumber(),h=a.findIndex(b=>b>=f-1e-10);if(h===-1&&(c=c.mul(10),h=0),h+=r,h>=a.length){var m=Math.floor(h/a.length);h%=a.length,c=c.mul(new Ke(10).pow(m))}var g=(n=a[h])!==null&&n!==void 0?n:1,v=new Ke(g).mul(c);return t?v:new Ke(Math.ceil(v.toNumber()))},IF=(e,t,r)=>{var n=new Ke(1),a=new Ke(e);if(!a.isint()&&r){var o=Math.abs(e);o<1?(n=new Ke(10).pow(jA(e)-1),a=new Ke(Math.floor(a.div(n).toNumber())).mul(n)):o>1&&(a=new Ke(Math.floor(e)))}else e===0?a=new Ke(Math.floor((t-1)/2)):r||(a=new Ke(Math.floor(e)));for(var u=Math.floor((t-1)/2),c=[],f=0;f<t;f++)c.push(a.add(new Ke(f-u).mul(n)).toNumber());return c},AA=function(t,r,n,a){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,u=arguments.length>5&&arguments[5]!==void 0?arguments[5]:Vy;if(!Number.isFinite((r-t)/(n-1)))return{step:new Ke(0),tickMin:new Ke(0),tickMax:new Ke(0)};var c=u(new Ke(r).sub(t).div(n-1),a,o),f;t<=0&&r>=0?f=new Ke(0):(f=new Ke(t).add(r).div(2),f=f.sub(new Ke(f).mod(c)));var h=Math.ceil(f.sub(t).div(c).toNumber()),m=Math.ceil(new Ke(r).sub(f).div(c).toNumber()),g=h+m+1;return g>n?AA(t,r,n,a,o+1,u):(g<n&&(m=r>0?m+(n-g):m,h=r>0?h:h+(n-g)),{step:c,tickMin:f.sub(new Ke(h).mul(c)),tickMax:f.add(new Ke(m).mul(c))})},Pj=function(t){var r=Cu(t,2),n=r[0],a=r[1],o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"auto",f=Math.max(o,2),h=NA([n,a]),m=Cu(h,2),g=m[0],v=m[1];if(g===-1/0||v===1/0){var b=v===1/0?[g,...Array(o-1).fill(1/0)]:[...Array(o-1).fill(-1/0),v];return n>a?b.reverse():b}if(g===v)return IF(g,o,u);var j=c==="snap125"?EA:Vy,k=AA(g,v,f,u,0,j),S=k.step,N=k.tickMin,E=k.tickMax,A=SA(N,E.add(new Ke(.1).mul(S)),S);return n>a?A.reverse():A},Oj=function(t,r){var n=Cu(t,2),a=n[0],o=n[1],u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"auto",f=NA([a,o]),h=Cu(f,2),m=h[0],g=h[1];if(m===-1/0||g===1/0)return[a,o];if(m===g)return[m];var v=c==="snap125"?EA:Vy,b=Math.max(r,2),j=v(new Ke(g).sub(m).div(b-1),u,0),k=[...SA(new Ke(m),new Ke(g),j),g];return u===!1&&(k=k.map(S=>Math.round(S))),a>o?k.reverse():k},TF=e=>e.rootProps.barCategoryGap,Mh=e=>e.rootProps.stackOffset,CA=e=>e.rootProps.reverseStackOrder,qy=e=>e.options.chartName,Qy=e=>e.rootProps.syncId,PA=e=>e.rootProps.syncMethod,Yy=e=>e.options.eventEmitter,DF=e=>e.rootProps.baseValue,dr={grid:-100,barBackground:-50,area:100,cursorRectangle:200,bar:300,line:400,axis:500,scatter:600,activeBar:1e3,cursorLine:1100,activeDot:1200,label:2e3},Ma={allowDecimals:!1,allowDataOverflow:!1,angleAxisId:0,reversed:!1,scale:"auto",tick:!0,type:"auto"},Cn={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:!0,includeHidden:!1,radiusAxisId:0,reversed:!1,scale:"auto",tick:!0,tickCount:5,type:"auto"},Ih=(e,t)=>{if(!(!e||!t))return e!=null&&e.reversed?[t[1],t[0]]:t};function Th(e,t,r){if(r!=="auto")return r;if(e!=null)return Gn(e,t)?"category":"number"}function _j(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Af(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?_j(Object(r),!0).forEach(function(n){RF(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_j(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function RF(e,t,r){return(t=LF(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function LF(e){var t=$F(e,"string");return typeof t=="symbol"?t:t+""}function $F(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Mj={allowDataOverflow:Ma.allowDataOverflow,allowDecimals:Ma.allowDecimals,allowDuplicatedCategory:!1,dataKey:void 0,domain:void 0,id:Ma.angleAxisId,includeHidden:!1,name:void 0,reversed:Ma.reversed,scale:Ma.scale,tick:Ma.tick,tickCount:void 0,ticks:void 0,type:Ma.type,unit:void 0,niceTicks:"auto"},Ij={allowDataOverflow:Cn.allowDataOverflow,allowDecimals:Cn.allowDecimals,allowDuplicatedCategory:Cn.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Cn.radiusAxisId,includeHidden:Cn.includeHidden,name:void 0,reversed:Cn.reversed,scale:Cn.scale,tick:Cn.tick,tickCount:Cn.tickCount,ticks:void 0,type:Cn.type,unit:void 0,niceTicks:"auto"},zF=(e,t)=>{if(t!=null)return e.polarAxis.angleAxis[t]},Xy=q([zF,J5],(e,t)=>{var r;if(e!=null)return e;var n=(r=Th(t,"angleAxis",Mj.type))!==null&&r!==void 0?r:"category";return Af(Af({},Mj),{},{type:n})}),FF=(e,t)=>e.polarAxis.radiusAxis[t],Zy=q([FF,J5],(e,t)=>{var r;if(e!=null)return e;var n=(r=Th(t,"radiusAxis",Ij.type))!==null&&r!==void 0?r:"category";return Af(Af({},Ij),{},{type:n})}),Dh=e=>e.polarOptions,Jy=q([xi,bi,Qt],oF),OA=q([Dh,Jy],(e,t)=>{if(e!=null)return pa(e.innerRadius,t,0)}),_A=q([Dh,Jy],(e,t)=>{if(e!=null)return pa(e.outerRadius,t,t*.8)}),BF=e=>{if(e==null)return[0,0];var t=e.startAngle,r=e.endAngle;return[t,r]},MA=q([Dh],BF);q([Xy,MA],Ih);var IA=q([Jy,OA,_A],(e,t,r)=>{if(!(e==null||t==null||r==null))return[t,r]});q([Zy,IA],Ih);var TA=q([ct,Dh,OA,_A,xi,bi],(e,t,r,n,a,o)=>{if(!(e!=="centric"&&e!=="radial"||t==null||r==null||n==null)){var u=t.cx,c=t.cy,f=t.startAngle,h=t.endAngle;return{cx:pa(u,a,a/2),cy:pa(c,o,o/2),innerRadius:r,outerRadius:n,startAngle:f,endAngle:h,clockWise:!1}}}),Rt=(e,t)=>t,Rh=(e,t,r)=>r;function e0(e){return e==null?void 0:e.id}function DA(e,t,r){var n=t.chartData,a=n===void 0?[]:n,o=r.allowDuplicatedCategory,u=r.dataKey,c=new Map;return e.forEach(f=>{var h,m=(h=f.data)!==null&&h!==void 0?h:a;if(!(m==null||m.length===0)){var g=e0(f);m.forEach((v,b)=>{var j=u==null||o?b:String(Dt(v,u,null)),k=Dt(v,f.dataKey,0),S;c.has(j)?S=c.get(j):S={},Object.assign(S,{[g]:k}),c.set(j,S)})}}),Array.from(c.values())}function t0(e){return"stackId"in e&&e.stackId!=null&&e.dataKey!=null}var Lh=(e,t)=>e===t?!0:e==null||t==null?!1:e[0]===t[0]&&e[1]===t[1];function $h(e,t){return Array.isArray(e)&&Array.isArray(t)&&e.length===0&&t.length===0?!0:e===t}function UF(e,t){if(e.length===t.length){for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}return!1}var Lt=e=>{var t=ct(e);return t==="horizontal"?"xAxis":t==="vertical"?"yAxis":t==="centric"?"angleAxis":"radiusAxis"},Xs=e=>e.tooltip.settings.axisId;function r0(e){if(e!=null){var t=e.ticks,r=e.bandwidth,n=e.range(),a=[Math.min(...n),Math.max(...n)];return{domain:()=>e.domain(),range:(function(o){function u(){return o.apply(this,arguments)}return u.toString=function(){return o.toString()},u})(()=>a),rangeMin:()=>a[0],rangeMax:()=>a[1],isInRange(o){var u=a[0],c=a[1];return u<=c?o>=u&&o<=c:o>=c&&o<=u},bandwidth:r?()=>r.call(e):void 0,ticks:t?o=>t.call(e,o):void 0,map:(o,u)=>{var c=e(o);if(c!=null){if(e.bandwidth&&u!==null&&u!==void 0&&u.position){var f=e.bandwidth();switch(u.position){case"middle":c+=f/2;break;case"end":c+=f;break}}return c}}}}}var HF=(e,t)=>{if(t!=null)switch(e){case"linear":{if(!Rn(t)){for(var r,n,a=0;a<t.length;a++){var o=t[a];He(o)&&((r===void 0||o<r)&&(r=o),(n===void 0||o>n)&&(n=o))}return r!==void 0&&n!==void 0?[r,n]:void 0}return t}default:return t}};function da(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function WF(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function n0(e){let t,r,n;e.length!==2?(t=da,r=(c,f)=>da(e(c),f),n=(c,f)=>e(c)-f):(t=e===da||e===WF?e:KF,r=e,n=e);function a(c,f,h=0,m=c.length){if(h<m){if(t(f,f)!==0)return m;do{const g=h+m>>>1;r(c[g],f)<0?h=g+1:m=g}while(h<m)}return h}function o(c,f,h=0,m=c.length){if(h<m){if(t(f,f)!==0)return m;do{const g=h+m>>>1;r(c[g],f)<=0?h=g+1:m=g}while(h<m)}return h}function u(c,f,h=0,m=c.length){const g=a(c,f,h,m-1);return g>h&&n(c[g-1],f)>-n(c[g],f)?g-1:g}return{left:a,center:u,right:o}}function KF(){return 0}function RA(e){return e===null?NaN:+e}function*GF(e,t){for(let r of e)r!=null&&(r=+r)>=r&&(yield r)}const VF=n0(da),Xu=VF.right;n0(RA).center;class Tj extends Map{constructor(t,r=YF){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[n,a]of t)this.set(n,a)}get(t){return super.get(Dj(this,t))}has(t){return super.has(Dj(this,t))}set(t,r){return super.set(qF(this,t),r)}delete(t){return super.delete(QF(this,t))}}function Dj({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function qF({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function QF({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function YF(e){return e!==null&&typeof e=="object"?e.valueOf():e}function XF(e=da){if(e===da)return LA;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,r)=>{const n=e(t,r);return n||n===0?n:(e(r,r)===0)-(e(t,t)===0)}}function LA(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const ZF=Math.sqrt(50),JF=Math.sqrt(10),e9=Math.sqrt(2);function Cf(e,t,r){const n=(t-e)/Math.max(0,r),a=Math.floor(Math.log10(n)),o=n/Math.pow(10,a),u=o>=ZF?10:o>=JF?5:o>=e9?2:1;let c,f,h;return a<0?(h=Math.pow(10,-a)/u,c=Math.round(e*h),f=Math.round(t*h),c/h<e&&++c,f/h>t&&--f,h=-h):(h=Math.pow(10,a)*u,c=Math.round(e/h),f=Math.round(t/h),c*h<e&&++c,f*h>t&&--f),f<c&&.5<=r&&r<2?Cf(e,t,r*2):[c,f,h]}function Uv(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const n=t<e,[a,o,u]=n?Cf(t,e,r):Cf(e,t,r);if(!(o>=a))return[];const c=o-a+1,f=new Array(c);if(n)if(u<0)for(let h=0;h<c;++h)f[h]=(o-h)/-u;else for(let h=0;h<c;++h)f[h]=(o-h)*u;else if(u<0)for(let h=0;h<c;++h)f[h]=(a+h)/-u;else for(let h=0;h<c;++h)f[h]=(a+h)*u;return f}function Hv(e,t,r){return t=+t,e=+e,r=+r,Cf(e,t,r)[2]}function Wv(e,t,r){t=+t,e=+e,r=+r;const n=t<e,a=n?Hv(t,e,r):Hv(e,t,r);return(n?-1:1)*(a<0?1/-a:a)}function Rj(e,t){let r;for(const n of e)n!=null&&(r<n||r===void 0&&n>=n)&&(r=n);return r}function Lj(e,t){let r;for(const n of e)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);return r}function $A(e,t,r=0,n=1/0,a){if(t=Math.floor(t),r=Math.floor(Math.max(0,r)),n=Math.floor(Math.min(e.length-1,n)),!(r<=t&&t<=n))return e;for(a=a===void 0?LA:XF(a);n>r;){if(n-r>600){const f=n-r+1,h=t-r+1,m=Math.log(f),g=.5*Math.exp(2*m/3),v=.5*Math.sqrt(m*g*(f-g)/f)*(h-f/2<0?-1:1),b=Math.max(r,Math.floor(t-h*g/f+v)),j=Math.min(n,Math.floor(t+(f-h)*g/f+v));$A(e,t,b,j,a)}const o=e[t];let u=r,c=n;for(Xl(e,r,t),a(e[n],o)>0&&Xl(e,r,n);u<c;){for(Xl(e,u,c),++u,--c;a(e[u],o)<0;)++u;for(;a(e[c],o)>0;)--c}a(e[r],o)===0?Xl(e,r,c):(++c,Xl(e,c,n)),c<=t&&(r=c+1),t<=c&&(n=c-1)}return e}function Xl(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function t9(e,t,r){if(e=Float64Array.from(GF(e)),!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return Lj(e);if(t>=1)return Rj(e);var n,a=(n-1)*t,o=Math.floor(a),u=Rj($A(e,o).subarray(0,o+1)),c=Lj(e.subarray(o+1));return u+(c-u)*(a-o)}}function r9(e,t,r=RA){if(!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return+r(e[0],0,e);if(t>=1)return+r(e[n-1],n-1,e);var n,a=(n-1)*t,o=Math.floor(a),u=+r(e[o],o,e),c=+r(e[o+1],o+1,e);return u+(c-u)*(a-o)}}function n9(e,t,r){e=+e,t=+t,r=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+r;for(var n=-1,a=Math.max(0,Math.ceil((t-e)/r))|0,o=new Array(a);++n<a;)o[n]=e+n*r;return o}function en(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function wi(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const Kv=Symbol("implicit");function i0(){var e=new Tj,t=[],r=[],n=Kv;function a(o){let u=e.get(o);if(u===void 0){if(n!==Kv)return n;e.set(o,u=t.push(o)-1)}return r[u%r.length]}return a.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new Tj;for(const u of o)e.has(u)||e.set(u,t.push(u)-1);return a},a.range=function(o){return arguments.length?(r=Array.from(o),a):r.slice()},a.unknown=function(o){return arguments.length?(n=o,a):n},a.copy=function(){return i0(t,r).unknown(n)},en.apply(a,arguments),a}function a0(){var e=i0().unknown(void 0),t=e.domain,r=e.range,n=0,a=1,o,u,c=!1,f=0,h=0,m=.5;delete e.unknown;function g(){var v=t().length,b=a<n,j=b?a:n,k=b?n:a;o=(k-j)/Math.max(1,v-f+h*2),c&&(o=Math.floor(o)),j+=(k-j-o*(v-f))*m,u=o*(1-f),c&&(j=Math.round(j),u=Math.round(u));var S=n9(v).map(function(N){return j+o*N});return r(b?S.reverse():S)}return e.domain=function(v){return arguments.length?(t(v),g()):t()},e.range=function(v){return arguments.length?([n,a]=v,n=+n,a=+a,g()):[n,a]},e.rangeRound=function(v){return[n,a]=v,n=+n,a=+a,c=!0,g()},e.bandwidth=function(){return u},e.step=function(){return o},e.round=function(v){return arguments.length?(c=!!v,g()):c},e.padding=function(v){return arguments.length?(f=Math.min(1,h=+v),g()):f},e.paddingInner=function(v){return arguments.length?(f=Math.min(1,v),g()):f},e.paddingOuter=function(v){return arguments.length?(h=+v,g()):h},e.align=function(v){return arguments.length?(m=Math.max(0,Math.min(1,v)),g()):m},e.copy=function(){return a0(t(),[n,a]).round(c).paddingInner(f).paddingOuter(h).align(m)},en.apply(g(),arguments)}function zA(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return zA(t())},e}function i9(){return zA(a0.apply(null,arguments).paddingInner(1))}function o0(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function FA(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Zu(){}var Pu=.7,Pf=1/Pu,ps="\\s*([+-]?\\d+)\\s*",Ou="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ln="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",a9=/^#([0-9a-f]{3,8})$/,o9=new RegExp(`^rgb\\(${ps},${ps},${ps}\\)$`),s9=new RegExp(`^rgb\\(${Ln},${Ln},${Ln}\\)$`),l9=new RegExp(`^rgba\\(${ps},${ps},${ps},${Ou}\\)$`),u9=new RegExp(`^rgba\\(${Ln},${Ln},${Ln},${Ou}\\)$`),c9=new RegExp(`^hsl\\(${Ou},${Ln},${Ln}\\)$`),d9=new RegExp(`^hsla\\(${Ou},${Ln},${Ln},${Ou}\\)$`),$j={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};o0(Zu,_u,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:zj,formatHex:zj,formatHex8:f9,formatHsl:h9,formatRgb:Fj,toString:Fj});function zj(){return this.rgb().formatHex()}function f9(){return this.rgb().formatHex8()}function h9(){return BA(this).formatHsl()}function Fj(){return this.rgb().formatRgb()}function _u(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=a9.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?Bj(t):r===3?new Sr(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?Id(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?Id(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=o9.exec(e))?new Sr(t[1],t[2],t[3],1):(t=s9.exec(e))?new Sr(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=l9.exec(e))?Id(t[1],t[2],t[3],t[4]):(t=u9.exec(e))?Id(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=c9.exec(e))?Wj(t[1],t[2]/100,t[3]/100,1):(t=d9.exec(e))?Wj(t[1],t[2]/100,t[3]/100,t[4]):$j.hasOwnProperty(e)?Bj($j[e]):e==="transparent"?new Sr(NaN,NaN,NaN,0):null}function Bj(e){return new Sr(e>>16&255,e>>8&255,e&255,1)}function Id(e,t,r,n){return n<=0&&(e=t=r=NaN),new Sr(e,t,r,n)}function m9(e){return e instanceof Zu||(e=_u(e)),e?(e=e.rgb(),new Sr(e.r,e.g,e.b,e.opacity)):new Sr}function Gv(e,t,r,n){return arguments.length===1?m9(e):new Sr(e,t,r,n??1)}function Sr(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}o0(Sr,Gv,FA(Zu,{brighter(e){return e=e==null?Pf:Math.pow(Pf,e),new Sr(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Pu:Math.pow(Pu,e),new Sr(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Sr(ao(this.r),ao(this.g),ao(this.b),Of(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Uj,formatHex:Uj,formatHex8:p9,formatRgb:Hj,toString:Hj}));function Uj(){return`#${Wa(this.r)}${Wa(this.g)}${Wa(this.b)}`}function p9(){return`#${Wa(this.r)}${Wa(this.g)}${Wa(this.b)}${Wa((isNaN(this.opacity)?1:this.opacity)*255)}`}function Hj(){const e=Of(this.opacity);return`${e===1?"rgb(":"rgba("}${ao(this.r)}, ${ao(this.g)}, ${ao(this.b)}${e===1?")":`, ${e})`}`}function Of(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function ao(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Wa(e){return e=ao(e),(e<16?"0":"")+e.toString(16)}function Wj(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new mn(e,t,r,n)}function BA(e){if(e instanceof mn)return new mn(e.h,e.s,e.l,e.opacity);if(e instanceof Zu||(e=_u(e)),!e)return new mn;if(e instanceof mn)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,a=Math.min(t,r,n),o=Math.max(t,r,n),u=NaN,c=o-a,f=(o+a)/2;return c?(t===o?u=(r-n)/c+(r<n)*6:r===o?u=(n-t)/c+2:u=(t-r)/c+4,c/=f<.5?o+a:2-o-a,u*=60):c=f>0&&f<1?0:u,new mn(u,c,f,e.opacity)}function g9(e,t,r,n){return arguments.length===1?BA(e):new mn(e,t,r,n??1)}function mn(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}o0(mn,g9,FA(Zu,{brighter(e){return e=e==null?Pf:Math.pow(Pf,e),new mn(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Pu:Math.pow(Pu,e),new mn(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,a=2*r-n;return new Sr(bg(e>=240?e-240:e+120,a,n),bg(e,a,n),bg(e<120?e+240:e-120,a,n),this.opacity)},clamp(){return new mn(Kj(this.h),Td(this.s),Td(this.l),Of(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Of(this.opacity);return`${e===1?"hsl(":"hsla("}${Kj(this.h)}, ${Td(this.s)*100}%, ${Td(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Kj(e){return e=(e||0)%360,e<0?e+360:e}function Td(e){return Math.max(0,Math.min(1,e||0))}function bg(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const s0=e=>()=>e;function v9(e,t){return function(r){return e+r*t}}function y9(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function x9(e){return(e=+e)==1?UA:function(t,r){return r-t?y9(t,r,e):s0(isNaN(t)?r:t)}}function UA(e,t){var r=t-e;return r?v9(e,r):s0(isNaN(e)?t:e)}const Gj=(function e(t){var r=x9(t);function n(a,o){var u=r((a=Gv(a)).r,(o=Gv(o)).r),c=r(a.g,o.g),f=r(a.b,o.b),h=UA(a.opacity,o.opacity);return function(m){return a.r=u(m),a.g=c(m),a.b=f(m),a.opacity=h(m),a+""}}return n.gamma=e,n})(1);function b9(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),a;return function(o){for(a=0;a<r;++a)n[a]=e[a]*(1-o)+t[a]*o;return n}}function w9(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function k9(e,t){var r=t?t.length:0,n=e?Math.min(r,e.length):0,a=new Array(n),o=new Array(r),u;for(u=0;u<n;++u)a[u]=Zs(e[u],t[u]);for(;u<r;++u)o[u]=t[u];return function(c){for(u=0;u<n;++u)o[u]=a[u](c);return o}}function j9(e,t){var r=new Date;return e=+e,t=+t,function(n){return r.setTime(e*(1-n)+t*n),r}}function _f(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function S9(e,t){var r={},n={},a;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(a in t)a in e?r[a]=Zs(e[a],t[a]):n[a]=t[a];return function(o){for(a in r)n[a]=r[a](o);return n}}var Vv=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,wg=new RegExp(Vv.source,"g");function N9(e){return function(){return e}}function E9(e){return function(t){return e(t)+""}}function A9(e,t){var r=Vv.lastIndex=wg.lastIndex=0,n,a,o,u=-1,c=[],f=[];for(e=e+"",t=t+"";(n=Vv.exec(e))&&(a=wg.exec(t));)(o=a.index)>r&&(o=t.slice(r,o),c[u]?c[u]+=o:c[++u]=o),(n=n[0])===(a=a[0])?c[u]?c[u]+=a:c[++u]=a:(c[++u]=null,f.push({i:u,x:_f(n,a)})),r=wg.lastIndex;return r<t.length&&(o=t.slice(r),c[u]?c[u]+=o:c[++u]=o),c.length<2?f[0]?E9(f[0].x):N9(t):(t=f.length,function(h){for(var m=0,g;m<t;++m)c[(g=f[m]).i]=g.x(h);return c.join("")})}function Zs(e,t){var r=typeof t,n;return t==null||r==="boolean"?s0(t):(r==="number"?_f:r==="string"?(n=_u(t))?(t=n,Gj):A9:t instanceof _u?Gj:t instanceof Date?j9:w9(t)?b9:Array.isArray(t)?k9:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?S9:_f)(e,t)}function l0(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}function C9(e,t){t===void 0&&(t=e,e=Zs);for(var r=0,n=t.length-1,a=t[0],o=new Array(n<0?0:n);r<n;)o[r]=e(a,a=t[++r]);return function(u){var c=Math.max(0,Math.min(n-1,Math.floor(u*=n)));return o[c](u-c)}}function P9(e){return function(){return e}}function Mf(e){return+e}var Vj=[0,1];function fr(e){return e}function qv(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:P9(isNaN(t)?NaN:.5)}function O9(e,t){var r;return e>t&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function _9(e,t,r){var n=e[0],a=e[1],o=t[0],u=t[1];return a<n?(n=qv(a,n),o=r(u,o)):(n=qv(n,a),o=r(o,u)),function(c){return o(n(c))}}function M9(e,t,r){var n=Math.min(e.length,t.length)-1,a=new Array(n),o=new Array(n),u=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++u<n;)a[u]=qv(e[u],e[u+1]),o[u]=r(t[u],t[u+1]);return function(c){var f=Xu(e,c,1,n)-1;return o[f](a[f](c))}}function Ju(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function zh(){var e=Vj,t=Vj,r=Zs,n,a,o,u=fr,c,f,h;function m(){var v=Math.min(e.length,t.length);return u!==fr&&(u=O9(e[0],e[v-1])),c=v>2?M9:_9,f=h=null,g}function g(v){return v==null||isNaN(v=+v)?o:(f||(f=c(e.map(n),t,r)))(n(u(v)))}return g.invert=function(v){return u(a((h||(h=c(t,e.map(n),_f)))(v)))},g.domain=function(v){return arguments.length?(e=Array.from(v,Mf),m()):e.slice()},g.range=function(v){return arguments.length?(t=Array.from(v),m()):t.slice()},g.rangeRound=function(v){return t=Array.from(v),r=l0,m()},g.clamp=function(v){return arguments.length?(u=v?!0:fr,m()):u!==fr},g.interpolate=function(v){return arguments.length?(r=v,m()):r},g.unknown=function(v){return arguments.length?(o=v,g):o},function(v,b){return n=v,a=b,m()}}function u0(){return zh()(fr,fr)}function I9(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function If(e,t){if(!isFinite(e)||e===0)return null;var r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function $s(e){return e=If(Math.abs(e)),e?e[1]:NaN}function T9(e,t){return function(r,n){for(var a=r.length,o=[],u=0,c=e[0],f=0;a>0&&c>0&&(f+c+1>n&&(c=Math.max(1,n-f)),o.push(r.substring(a-=c,a+c)),!((f+=c+1)>n));)c=e[u=(u+1)%e.length];return o.reverse().join(t)}}function D9(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var R9=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Mu(e){if(!(t=R9.exec(e)))throw new Error("invalid format: "+e);var t;return new c0({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}Mu.prototype=c0.prototype;function c0(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}c0.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function L9(e){e:for(var t=e.length,r=1,n=-1,a;r<t;++r)switch(e[r]){case".":n=a=r;break;case"0":n===0&&(n=r),a=r;break;default:if(!+e[r])break e;n>0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(a+1):e}var Tf;function $9(e,t){var r=If(e,t);if(!r)return Tf=void 0,e.toPrecision(t);var n=r[0],a=r[1],o=a-(Tf=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,u=n.length;return o===u?n:o>u?n+new Array(o-u+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+If(e,Math.max(0,t+o-1))[0]}function qj(e,t){var r=If(e,t);if(!r)return e+"";var n=r[0],a=r[1];return a<0?"0."+new Array(-a).join("0")+n:n.length>a+1?n.slice(0,a+1)+"."+n.slice(a+1):n+new Array(a-n.length+2).join("0")}const Qj={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:I9,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>qj(e*100,t),r:qj,s:$9,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Yj(e){return e}var Xj=Array.prototype.map,Zj=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function z9(e){var t=e.grouping===void 0||e.thousands===void 0?Yj:T9(Xj.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",a=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?Yj:D9(Xj.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",c=e.minus===void 0?"−":e.minus+"",f=e.nan===void 0?"NaN":e.nan+"";function h(g,v){g=Mu(g);var b=g.fill,j=g.align,k=g.sign,S=g.symbol,N=g.zero,E=g.width,A=g.comma,P=g.precision,_=g.trim,O=g.type;O==="n"?(A=!0,O="g"):Qj[O]||(P===void 0&&(P=12),_=!0,O="g"),(N||b==="0"&&j==="=")&&(N=!0,b="0",j="=");var D=(v&&v.prefix!==void 0?v.prefix:"")+(S==="$"?r:S==="#"&&/[boxX]/.test(O)?"0"+O.toLowerCase():""),B=(S==="$"?n:/[%p]/.test(O)?u:"")+(v&&v.suffix!==void 0?v.suffix:""),F=Qj[O],z=/[defgprs%]/.test(O);P=P===void 0?6:/[gprs]/.test(O)?Math.max(1,Math.min(21,P)):Math.max(0,Math.min(20,P));function Y(U){var he=D,ue=B,ge,ie,se;if(O==="c")ue=F(U)+ue,U="";else{U=+U;var X=U<0||1/U<0;if(U=isNaN(U)?f:F(Math.abs(U),P),_&&(U=L9(U)),X&&+U==0&&k!=="+"&&(X=!1),he=(X?k==="("?k:c:k==="-"||k==="("?"":k)+he,ue=(O==="s"&&!isNaN(U)&&Tf!==void 0?Zj[8+Tf/3]:"")+ue+(X&&k==="("?")":""),z){for(ge=-1,ie=U.length;++ge<ie;)if(se=U.charCodeAt(ge),48>se||se>57){ue=(se===46?a+U.slice(ge+1):U.slice(ge))+ue,U=U.slice(0,ge);break}}}A&&!N&&(U=t(U,1/0));var te=he.length+U.length+ue.length,J=te<E?new Array(E-te+1).join(b):"";switch(A&&N&&(U=t(J+U,J.length?E-ue.length:1/0),J=""),j){case"<":U=he+U+ue+J;break;case"=":U=he+J+U+ue;break;case"^":U=J.slice(0,te=J.length>>1)+he+U+ue+J.slice(te);break;default:U=J+he+U+ue;break}return o(U)}return Y.toString=function(){return g+""},Y}function m(g,v){var b=Math.max(-8,Math.min(8,Math.floor($s(v)/3)))*3,j=Math.pow(10,-b),k=h((g=Mu(g),g.type="f",g),{suffix:Zj[8+b/3]});return function(S){return k(j*S)}}return{format:h,formatPrefix:m}}var Dd,d0,HA;F9({thousands:",",grouping:[3],currency:["$",""]});function F9(e){return Dd=z9(e),d0=Dd.format,HA=Dd.formatPrefix,Dd}function B9(e){return Math.max(0,-$s(Math.abs(e)))}function U9(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor($s(t)/3)))*3-$s(Math.abs(e)))}function H9(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,$s(t)-$s(e))+1}function WA(e,t,r,n){var a=Wv(e,t,r),o;switch(n=Mu(n??",f"),n.type){case"s":{var u=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(o=U9(a,u))&&(n.precision=o),HA(n,u)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(o=H9(a,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=o-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(o=B9(a))&&(n.precision=o-(n.type==="%")*2);break}}return d0(n)}function ga(e){var t=e.domain;return e.ticks=function(r){var n=t();return Uv(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var a=t();return WA(a[0],a[a.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),a=0,o=n.length-1,u=n[a],c=n[o],f,h,m=10;for(c<u&&(h=u,u=c,c=h,h=a,a=o,o=h);m-- >0;){if(h=Hv(u,c,r),h===f)return n[a]=u,n[o]=c,t(n);if(h>0)u=Math.floor(u/h)*h,c=Math.ceil(c/h)*h;else if(h<0)u=Math.ceil(u*h)/h,c=Math.floor(c*h)/h;else break;f=h}return e},e}function KA(){var e=u0();return e.copy=function(){return Ju(e,KA())},en.apply(e,arguments),ga(e)}function GA(e){var t;function r(n){return n==null||isNaN(n=+n)?t:n}return r.invert=r,r.domain=r.range=function(n){return arguments.length?(e=Array.from(n,Mf),r):e.slice()},r.unknown=function(n){return arguments.length?(t=n,r):t},r.copy=function(){return GA(e).unknown(t)},e=arguments.length?Array.from(e,Mf):[0,1],ga(r)}function VA(e,t){e=e.slice();var r=0,n=e.length-1,a=e[r],o=e[n],u;return o<a&&(u=r,r=n,n=u,u=a,a=o,o=u),e[r]=t.floor(a),e[n]=t.ceil(o),e}function Jj(e){return Math.log(e)}function eS(e){return Math.exp(e)}function W9(e){return-Math.log(-e)}function K9(e){return-Math.exp(-e)}function G9(e){return isFinite(e)?+("1e"+e):e<0?0:e}function V9(e){return e===10?G9:e===Math.E?Math.exp:t=>Math.pow(e,t)}function q9(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function tS(e){return(t,r)=>-e(-t,r)}function f0(e){const t=e(Jj,eS),r=t.domain;let n=10,a,o;function u(){return a=q9(n),o=V9(n),r()[0]<0?(a=tS(a),o=tS(o),e(W9,K9)):e(Jj,eS),t}return t.base=function(c){return arguments.length?(n=+c,u()):n},t.domain=function(c){return arguments.length?(r(c),u()):r()},t.ticks=c=>{const f=r();let h=f[0],m=f[f.length-1];const g=m<h;g&&([h,m]=[m,h]);let v=a(h),b=a(m),j,k;const S=c==null?10:+c;let N=[];if(!(n%1)&&b-v<S){if(v=Math.floor(v),b=Math.ceil(b),h>0){for(;v<=b;++v)for(j=1;j<n;++j)if(k=v<0?j/o(-v):j*o(v),!(k<h)){if(k>m)break;N.push(k)}}else for(;v<=b;++v)for(j=n-1;j>=1;--j)if(k=v>0?j/o(-v):j*o(v),!(k<h)){if(k>m)break;N.push(k)}N.length*2<S&&(N=Uv(h,m,S))}else N=Uv(v,b,Math.min(b-v,S)).map(o);return g?N.reverse():N},t.tickFormat=(c,f)=>{if(c==null&&(c=10),f==null&&(f=n===10?"s":","),typeof f!="function"&&(!(n%1)&&(f=Mu(f)).precision==null&&(f.trim=!0),f=d0(f)),c===1/0)return f;const h=Math.max(1,n*c/t.ticks().length);return m=>{let g=m/o(Math.round(a(m)));return g*n<n-.5&&(g*=n),g<=h?f(m):""}},t.nice=()=>r(VA(r(),{floor:c=>o(Math.floor(a(c))),ceil:c=>o(Math.ceil(a(c)))})),t}function qA(){const e=f0(zh()).domain([1,10]);return e.copy=()=>Ju(e,qA()).base(e.base()),en.apply(e,arguments),e}function rS(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function nS(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function h0(e){var t=1,r=e(rS(t),nS(t));return r.constant=function(n){return arguments.length?e(rS(t=+n),nS(t)):t},ga(r)}function QA(){var e=h0(zh());return e.copy=function(){return Ju(e,QA()).constant(e.constant())},en.apply(e,arguments)}function iS(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function Q9(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function Y9(e){return e<0?-e*e:e*e}function m0(e){var t=e(fr,fr),r=1;function n(){return r===1?e(fr,fr):r===.5?e(Q9,Y9):e(iS(r),iS(1/r))}return t.exponent=function(a){return arguments.length?(r=+a,n()):r},ga(t)}function p0(){var e=m0(zh());return e.copy=function(){return Ju(e,p0()).exponent(e.exponent())},en.apply(e,arguments),e}function X9(){return p0.apply(null,arguments).exponent(.5)}function aS(e){return Math.sign(e)*e*e}function Z9(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function YA(){var e=u0(),t=[0,1],r=!1,n;function a(o){var u=Z9(e(o));return isNaN(u)?n:r?Math.round(u):u}return a.invert=function(o){return e.invert(aS(o))},a.domain=function(o){return arguments.length?(e.domain(o),a):e.domain()},a.range=function(o){return arguments.length?(e.range((t=Array.from(o,Mf)).map(aS)),a):t.slice()},a.rangeRound=function(o){return a.range(o).round(!0)},a.round=function(o){return arguments.length?(r=!!o,a):r},a.clamp=function(o){return arguments.length?(e.clamp(o),a):e.clamp()},a.unknown=function(o){return arguments.length?(n=o,a):n},a.copy=function(){return YA(e.domain(),t).round(r).clamp(e.clamp()).unknown(n)},en.apply(a,arguments),ga(a)}function XA(){var e=[],t=[],r=[],n;function a(){var u=0,c=Math.max(1,t.length);for(r=new Array(c-1);++u<c;)r[u-1]=r9(e,u/c);return o}function o(u){return u==null||isNaN(u=+u)?n:t[Xu(r,u)]}return o.invertExtent=function(u){var c=t.indexOf(u);return c<0?[NaN,NaN]:[c>0?r[c-1]:e[0],c<r.length?r[c]:e[e.length-1]]},o.domain=function(u){if(!arguments.length)return e.slice();e=[];for(let c of u)c!=null&&!isNaN(c=+c)&&e.push(c);return e.sort(da),a()},o.range=function(u){return arguments.length?(t=Array.from(u),a()):t.slice()},o.unknown=function(u){return arguments.length?(n=u,o):n},o.quantiles=function(){return r.slice()},o.copy=function(){return XA().domain(e).range(t).unknown(n)},en.apply(o,arguments)}function ZA(){var e=0,t=1,r=1,n=[.5],a=[0,1],o;function u(f){return f!=null&&f<=f?a[Xu(n,f,0,r)]:o}function c(){var f=-1;for(n=new Array(r);++f<r;)n[f]=((f+1)*t-(f-r)*e)/(r+1);return u}return u.domain=function(f){return arguments.length?([e,t]=f,e=+e,t=+t,c()):[e,t]},u.range=function(f){return arguments.length?(r=(a=Array.from(f)).length-1,c()):a.slice()},u.invertExtent=function(f){var h=a.indexOf(f);return h<0?[NaN,NaN]:h<1?[e,n[0]]:h>=r?[n[r-1],t]:[n[h-1],n[h]]},u.unknown=function(f){return arguments.length&&(o=f),u},u.thresholds=function(){return n.slice()},u.copy=function(){return ZA().domain([e,t]).range(a).unknown(o)},en.apply(ga(u),arguments)}function JA(){var e=[.5],t=[0,1],r,n=1;function a(o){return o!=null&&o<=o?t[Xu(e,o,0,n)]:r}return a.domain=function(o){return arguments.length?(e=Array.from(o),n=Math.min(e.length,t.length-1),a):e.slice()},a.range=function(o){return arguments.length?(t=Array.from(o),n=Math.min(e.length,t.length-1),a):t.slice()},a.invertExtent=function(o){var u=t.indexOf(o);return[e[u-1],e[u]]},a.unknown=function(o){return arguments.length?(r=o,a):r},a.copy=function(){return JA().domain(e).range(t).unknown(r)},en.apply(a,arguments)}const kg=new Date,jg=new Date;function Ct(e,t,r,n){function a(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return a.floor=o=>(e(o=new Date(+o)),o),a.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),a.round=o=>{const u=a(o),c=a.ceil(o);return o-u<c-o?u:c},a.offset=(o,u)=>(t(o=new Date(+o),u==null?1:Math.floor(u)),o),a.range=(o,u,c)=>{const f=[];if(o=a.ceil(o),c=c==null?1:Math.floor(c),!(o<u)||!(c>0))return f;let h;do f.push(h=new Date(+o)),t(o,c),e(o);while(h<o&&o<u);return f},a.filter=o=>Ct(u=>{if(u>=u)for(;e(u),!o(u);)u.setTime(u-1)},(u,c)=>{if(u>=u)if(c<0)for(;++c<=0;)for(;t(u,-1),!o(u););else for(;--c>=0;)for(;t(u,1),!o(u););}),r&&(a.count=(o,u)=>(kg.setTime(+o),jg.setTime(+u),e(kg),e(jg),Math.floor(r(kg,jg))),a.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?a.filter(n?u=>n(u)%o===0:u=>a.count(0,u)%o===0):a)),a}const Df=Ct(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Df.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Ct(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):Df);Df.range;const ui=1e3,Qr=ui*60,ci=Qr*60,pi=ci*24,g0=pi*7,oS=pi*30,Sg=pi*365,Ka=Ct(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*ui)},(e,t)=>(t-e)/ui,e=>e.getUTCSeconds());Ka.range;const v0=Ct(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*ui)},(e,t)=>{e.setTime(+e+t*Qr)},(e,t)=>(t-e)/Qr,e=>e.getMinutes());v0.range;const y0=Ct(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Qr)},(e,t)=>(t-e)/Qr,e=>e.getUTCMinutes());y0.range;const x0=Ct(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*ui-e.getMinutes()*Qr)},(e,t)=>{e.setTime(+e+t*ci)},(e,t)=>(t-e)/ci,e=>e.getHours());x0.range;const b0=Ct(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*ci)},(e,t)=>(t-e)/ci,e=>e.getUTCHours());b0.range;const ec=Ct(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Qr)/pi,e=>e.getDate()-1);ec.range;const Fh=Ct(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/pi,e=>e.getUTCDate()-1);Fh.range;const eC=Ct(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/pi,e=>Math.floor(e/pi));eC.range;function wo(e){return Ct(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*Qr)/g0)}const Bh=wo(0),Rf=wo(1),J9=wo(2),e7=wo(3),zs=wo(4),t7=wo(5),r7=wo(6);Bh.range;Rf.range;J9.range;e7.range;zs.range;t7.range;r7.range;function ko(e){return Ct(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/g0)}const Uh=ko(0),Lf=ko(1),n7=ko(2),i7=ko(3),Fs=ko(4),a7=ko(5),o7=ko(6);Uh.range;Lf.range;n7.range;i7.range;Fs.range;a7.range;o7.range;const w0=Ct(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());w0.range;const k0=Ct(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());k0.range;const gi=Ct(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());gi.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Ct(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});gi.range;const vi=Ct(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());vi.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Ct(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});vi.range;function tC(e,t,r,n,a,o){const u=[[Ka,1,ui],[Ka,5,5*ui],[Ka,15,15*ui],[Ka,30,30*ui],[o,1,Qr],[o,5,5*Qr],[o,15,15*Qr],[o,30,30*Qr],[a,1,ci],[a,3,3*ci],[a,6,6*ci],[a,12,12*ci],[n,1,pi],[n,2,2*pi],[r,1,g0],[t,1,oS],[t,3,3*oS],[e,1,Sg]];function c(h,m,g){const v=m<h;v&&([h,m]=[m,h]);const b=g&&typeof g.range=="function"?g:f(h,m,g),j=b?b.range(h,+m+1):[];return v?j.reverse():j}function f(h,m,g){const v=Math.abs(m-h)/g,b=n0(([,,S])=>S).right(u,v);if(b===u.length)return e.every(Wv(h/Sg,m/Sg,g));if(b===0)return Df.every(Math.max(Wv(h,m,g),1));const[j,k]=u[v/u[b-1][2]<u[b][2]/v?b-1:b];return j.every(k)}return[c,f]}const[s7,l7]=tC(vi,k0,Uh,eC,b0,y0),[u7,c7]=tC(gi,w0,Bh,ec,x0,v0);function Ng(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Eg(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function Zl(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function d7(e){var t=e.dateTime,r=e.date,n=e.time,a=e.periods,o=e.days,u=e.shortDays,c=e.months,f=e.shortMonths,h=Jl(a),m=eu(a),g=Jl(o),v=eu(o),b=Jl(u),j=eu(u),k=Jl(c),S=eu(c),N=Jl(f),E=eu(f),A={a:se,A:X,b:te,B:J,c:null,d:fS,e:fS,f:T7,g:W7,G:G7,H:_7,I:M7,j:I7,L:rC,m:D7,M:R7,p:I,q:M,Q:pS,s:gS,S:L7,u:$7,U:z7,V:F7,w:B7,W:U7,x:null,X:null,y:H7,Y:K7,Z:V7,"%":mS},P={a:H,A:ne,b:Z,B:me,c:null,d:hS,e:hS,f:X7,g:sB,G:uB,H:q7,I:Q7,j:Y7,L:iC,m:Z7,M:J7,p:pe,q:Oe,Q:pS,s:gS,S:eB,u:tB,U:rB,V:nB,w:iB,W:aB,x:null,X:null,y:oB,Y:lB,Z:cB,"%":mS},_={a:z,A:Y,b:U,B:he,c:ue,d:cS,e:cS,f:A7,g:uS,G:lS,H:dS,I:dS,j:j7,L:E7,m:k7,M:S7,p:F,q:w7,Q:P7,s:O7,S:N7,u:g7,U:v7,V:y7,w:p7,W:x7,x:ge,X:ie,y:uS,Y:lS,Z:b7,"%":C7};A.x=O(r,A),A.X=O(n,A),A.c=O(t,A),P.x=O(r,P),P.X=O(n,P),P.c=O(t,P);function O(re,we){return function(_e){var ae=[],et=-1,Be=0,Pe=re.length,vt,Yt,K;for(_e instanceof Date||(_e=new Date(+_e));++et<Pe;)re.charCodeAt(et)===37&&(ae.push(re.slice(Be,et)),(Yt=sS[vt=re.charAt(++et)])!=null?vt=re.charAt(++et):Yt=vt==="e"?" ":"0",(K=we[vt])&&(vt=K(_e,Yt)),ae.push(vt),Be=et+1);return ae.push(re.slice(Be,et)),ae.join("")}}function D(re,we){return function(_e){var ae=Zl(1900,void 0,1),et=B(ae,re,_e+="",0),Be,Pe;if(et!=_e.length)return null;if("Q"in ae)return new Date(ae.Q);if("s"in ae)return new Date(ae.s*1e3+("L"in ae?ae.L:0));if(we&&!("Z"in ae)&&(ae.Z=0),"p"in ae&&(ae.H=ae.H%12+ae.p*12),ae.m===void 0&&(ae.m="q"in ae?ae.q:0),"V"in ae){if(ae.V<1||ae.V>53)return null;"w"in ae||(ae.w=1),"Z"in ae?(Be=Eg(Zl(ae.y,0,1)),Pe=Be.getUTCDay(),Be=Pe>4||Pe===0?Lf.ceil(Be):Lf(Be),Be=Fh.offset(Be,(ae.V-1)*7),ae.y=Be.getUTCFullYear(),ae.m=Be.getUTCMonth(),ae.d=Be.getUTCDate()+(ae.w+6)%7):(Be=Ng(Zl(ae.y,0,1)),Pe=Be.getDay(),Be=Pe>4||Pe===0?Rf.ceil(Be):Rf(Be),Be=ec.offset(Be,(ae.V-1)*7),ae.y=Be.getFullYear(),ae.m=Be.getMonth(),ae.d=Be.getDate()+(ae.w+6)%7)}else("W"in ae||"U"in ae)&&("w"in ae||(ae.w="u"in ae?ae.u%7:"W"in ae?1:0),Pe="Z"in ae?Eg(Zl(ae.y,0,1)).getUTCDay():Ng(Zl(ae.y,0,1)).getDay(),ae.m=0,ae.d="W"in ae?(ae.w+6)%7+ae.W*7-(Pe+5)%7:ae.w+ae.U*7-(Pe+6)%7);return"Z"in ae?(ae.H+=ae.Z/100|0,ae.M+=ae.Z%100,Eg(ae)):Ng(ae)}}function B(re,we,_e,ae){for(var et=0,Be=we.length,Pe=_e.length,vt,Yt;et<Be;){if(ae>=Pe)return-1;if(vt=we.charCodeAt(et++),vt===37){if(vt=we.charAt(et++),Yt=_[vt in sS?we.charAt(et++):vt],!Yt||(ae=Yt(re,_e,ae))<0)return-1}else if(vt!=_e.charCodeAt(ae++))return-1}return ae}function F(re,we,_e){var ae=h.exec(we.slice(_e));return ae?(re.p=m.get(ae[0].toLowerCase()),_e+ae[0].length):-1}function z(re,we,_e){var ae=b.exec(we.slice(_e));return ae?(re.w=j.get(ae[0].toLowerCase()),_e+ae[0].length):-1}function Y(re,we,_e){var ae=g.exec(we.slice(_e));return ae?(re.w=v.get(ae[0].toLowerCase()),_e+ae[0].length):-1}function U(re,we,_e){var ae=N.exec(we.slice(_e));return ae?(re.m=E.get(ae[0].toLowerCase()),_e+ae[0].length):-1}function he(re,we,_e){var ae=k.exec(we.slice(_e));return ae?(re.m=S.get(ae[0].toLowerCase()),_e+ae[0].length):-1}function ue(re,we,_e){return B(re,t,we,_e)}function ge(re,we,_e){return B(re,r,we,_e)}function ie(re,we,_e){return B(re,n,we,_e)}function se(re){return u[re.getDay()]}function X(re){return o[re.getDay()]}function te(re){return f[re.getMonth()]}function J(re){return c[re.getMonth()]}function I(re){return a[+(re.getHours()>=12)]}function M(re){return 1+~~(re.getMonth()/3)}function H(re){return u[re.getUTCDay()]}function ne(re){return o[re.getUTCDay()]}function Z(re){return f[re.getUTCMonth()]}function me(re){return c[re.getUTCMonth()]}function pe(re){return a[+(re.getUTCHours()>=12)]}function Oe(re){return 1+~~(re.getUTCMonth()/3)}return{format:function(re){var we=O(re+="",A);return we.toString=function(){return re},we},parse:function(re){var we=D(re+="",!1);return we.toString=function(){return re},we},utcFormat:function(re){var we=O(re+="",P);return we.toString=function(){return re},we},utcParse:function(re){var we=D(re+="",!0);return we.toString=function(){return re},we}}}var sS={"-":"",_:" ",0:"0"},$t=/^\s*\d+/,f7=/^%/,h7=/[\\^$*+?|[\]().{}]/g;function Ye(e,t,r){var n=e<0?"-":"",a=(n?-e:e)+"",o=a.length;return n+(o<r?new Array(r-o+1).join(t)+a:a)}function m7(e){return e.replace(h7,"\\$&")}function Jl(e){return new RegExp("^(?:"+e.map(m7).join("|")+")","i")}function eu(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function p7(e,t,r){var n=$t.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function g7(e,t,r){var n=$t.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function v7(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function y7(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function x7(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function lS(e,t,r){var n=$t.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function uS(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function b7(e,t,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function w7(e,t,r){var n=$t.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function k7(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function cS(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function j7(e,t,r){var n=$t.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function dS(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function S7(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function N7(e,t,r){var n=$t.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function E7(e,t,r){var n=$t.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function A7(e,t,r){var n=$t.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function C7(e,t,r){var n=f7.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function P7(e,t,r){var n=$t.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function O7(e,t,r){var n=$t.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function fS(e,t){return Ye(e.getDate(),t,2)}function _7(e,t){return Ye(e.getHours(),t,2)}function M7(e,t){return Ye(e.getHours()%12||12,t,2)}function I7(e,t){return Ye(1+ec.count(gi(e),e),t,3)}function rC(e,t){return Ye(e.getMilliseconds(),t,3)}function T7(e,t){return rC(e,t)+"000"}function D7(e,t){return Ye(e.getMonth()+1,t,2)}function R7(e,t){return Ye(e.getMinutes(),t,2)}function L7(e,t){return Ye(e.getSeconds(),t,2)}function $7(e){var t=e.getDay();return t===0?7:t}function z7(e,t){return Ye(Bh.count(gi(e)-1,e),t,2)}function nC(e){var t=e.getDay();return t>=4||t===0?zs(e):zs.ceil(e)}function F7(e,t){return e=nC(e),Ye(zs.count(gi(e),e)+(gi(e).getDay()===4),t,2)}function B7(e){return e.getDay()}function U7(e,t){return Ye(Rf.count(gi(e)-1,e),t,2)}function H7(e,t){return Ye(e.getFullYear()%100,t,2)}function W7(e,t){return e=nC(e),Ye(e.getFullYear()%100,t,2)}function K7(e,t){return Ye(e.getFullYear()%1e4,t,4)}function G7(e,t){var r=e.getDay();return e=r>=4||r===0?zs(e):zs.ceil(e),Ye(e.getFullYear()%1e4,t,4)}function V7(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Ye(t/60|0,"0",2)+Ye(t%60,"0",2)}function hS(e,t){return Ye(e.getUTCDate(),t,2)}function q7(e,t){return Ye(e.getUTCHours(),t,2)}function Q7(e,t){return Ye(e.getUTCHours()%12||12,t,2)}function Y7(e,t){return Ye(1+Fh.count(vi(e),e),t,3)}function iC(e,t){return Ye(e.getUTCMilliseconds(),t,3)}function X7(e,t){return iC(e,t)+"000"}function Z7(e,t){return Ye(e.getUTCMonth()+1,t,2)}function J7(e,t){return Ye(e.getUTCMinutes(),t,2)}function eB(e,t){return Ye(e.getUTCSeconds(),t,2)}function tB(e){var t=e.getUTCDay();return t===0?7:t}function rB(e,t){return Ye(Uh.count(vi(e)-1,e),t,2)}function aC(e){var t=e.getUTCDay();return t>=4||t===0?Fs(e):Fs.ceil(e)}function nB(e,t){return e=aC(e),Ye(Fs.count(vi(e),e)+(vi(e).getUTCDay()===4),t,2)}function iB(e){return e.getUTCDay()}function aB(e,t){return Ye(Lf.count(vi(e)-1,e),t,2)}function oB(e,t){return Ye(e.getUTCFullYear()%100,t,2)}function sB(e,t){return e=aC(e),Ye(e.getUTCFullYear()%100,t,2)}function lB(e,t){return Ye(e.getUTCFullYear()%1e4,t,4)}function uB(e,t){var r=e.getUTCDay();return e=r>=4||r===0?Fs(e):Fs.ceil(e),Ye(e.getUTCFullYear()%1e4,t,4)}function cB(){return"+0000"}function mS(){return"%"}function pS(e){return+e}function gS(e){return Math.floor(+e/1e3)}var ts,oC,sC;dB({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function dB(e){return ts=d7(e),oC=ts.format,ts.parse,sC=ts.utcFormat,ts.utcParse,ts}function fB(e){return new Date(e)}function hB(e){return e instanceof Date?+e:+new Date(+e)}function j0(e,t,r,n,a,o,u,c,f,h){var m=u0(),g=m.invert,v=m.domain,b=h(".%L"),j=h(":%S"),k=h("%I:%M"),S=h("%I %p"),N=h("%a %d"),E=h("%b %d"),A=h("%B"),P=h("%Y");function _(O){return(f(O)<O?b:c(O)<O?j:u(O)<O?k:o(O)<O?S:n(O)<O?a(O)<O?N:E:r(O)<O?A:P)(O)}return m.invert=function(O){return new Date(g(O))},m.domain=function(O){return arguments.length?v(Array.from(O,hB)):v().map(fB)},m.ticks=function(O){var D=v();return e(D[0],D[D.length-1],O??10)},m.tickFormat=function(O,D){return D==null?_:h(D)},m.nice=function(O){var D=v();return(!O||typeof O.range!="function")&&(O=t(D[0],D[D.length-1],O??10)),O?v(VA(D,O)):m},m.copy=function(){return Ju(m,j0(e,t,r,n,a,o,u,c,f,h))},m}function mB(){return en.apply(j0(u7,c7,gi,w0,Bh,ec,x0,v0,Ka,oC).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function pB(){return en.apply(j0(s7,l7,vi,k0,Uh,Fh,b0,y0,Ka,sC).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Hh(){var e=0,t=1,r,n,a,o,u=fr,c=!1,f;function h(g){return g==null||isNaN(g=+g)?f:u(a===0?.5:(g=(o(g)-r)*a,c?Math.max(0,Math.min(1,g)):g))}h.domain=function(g){return arguments.length?([e,t]=g,r=o(e=+e),n=o(t=+t),a=r===n?0:1/(n-r),h):[e,t]},h.clamp=function(g){return arguments.length?(c=!!g,h):c},h.interpolator=function(g){return arguments.length?(u=g,h):u};function m(g){return function(v){var b,j;return arguments.length?([b,j]=v,u=g(b,j),h):[u(0),u(1)]}}return h.range=m(Zs),h.rangeRound=m(l0),h.unknown=function(g){return arguments.length?(f=g,h):f},function(g){return o=g,r=g(e),n=g(t),a=r===n?0:1/(n-r),h}}function va(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function lC(){var e=ga(Hh()(fr));return e.copy=function(){return va(e,lC())},wi.apply(e,arguments)}function uC(){var e=f0(Hh()).domain([1,10]);return e.copy=function(){return va(e,uC()).base(e.base())},wi.apply(e,arguments)}function cC(){var e=h0(Hh());return e.copy=function(){return va(e,cC()).constant(e.constant())},wi.apply(e,arguments)}function S0(){var e=m0(Hh());return e.copy=function(){return va(e,S0()).exponent(e.exponent())},wi.apply(e,arguments)}function gB(){return S0.apply(null,arguments).exponent(.5)}function dC(){var e=[],t=fr;function r(n){if(n!=null&&!isNaN(n=+n))return t((Xu(e,n,1)-1)/(e.length-1))}return r.domain=function(n){if(!arguments.length)return e.slice();e=[];for(let a of n)a!=null&&!isNaN(a=+a)&&e.push(a);return e.sort(da),r},r.interpolator=function(n){return arguments.length?(t=n,r):t},r.range=function(){return e.map((n,a)=>t(a/(e.length-1)))},r.quantiles=function(n){return Array.from({length:n+1},(a,o)=>t9(e,o/n))},r.copy=function(){return dC(t).domain(e)},wi.apply(r,arguments)}function Wh(){var e=0,t=.5,r=1,n=1,a,o,u,c,f,h=fr,m,g=!1,v;function b(k){return isNaN(k=+k)?v:(k=.5+((k=+m(k))-o)*(n*k<n*o?c:f),h(g?Math.max(0,Math.min(1,k)):k))}b.domain=function(k){return arguments.length?([e,t,r]=k,a=m(e=+e),o=m(t=+t),u=m(r=+r),c=a===o?0:.5/(o-a),f=o===u?0:.5/(u-o),n=o<a?-1:1,b):[e,t,r]},b.clamp=function(k){return arguments.length?(g=!!k,b):g},b.interpolator=function(k){return arguments.length?(h=k,b):h};function j(k){return function(S){var N,E,A;return arguments.length?([N,E,A]=S,h=C9(k,[N,E,A]),b):[h(0),h(.5),h(1)]}}return b.range=j(Zs),b.rangeRound=j(l0),b.unknown=function(k){return arguments.length?(v=k,b):v},function(k){return m=k,a=k(e),o=k(t),u=k(r),c=a===o?0:.5/(o-a),f=o===u?0:.5/(u-o),n=o<a?-1:1,b}}function fC(){var e=ga(Wh()(fr));return e.copy=function(){return va(e,fC())},wi.apply(e,arguments)}function hC(){var e=f0(Wh()).domain([.1,1,10]);return e.copy=function(){return va(e,hC()).base(e.base())},wi.apply(e,arguments)}function mC(){var e=h0(Wh());return e.copy=function(){return va(e,mC()).constant(e.constant())},wi.apply(e,arguments)}function N0(){var e=m0(Wh());return e.copy=function(){return va(e,N0()).exponent(e.exponent())},wi.apply(e,arguments)}function vB(){return N0.apply(null,arguments).exponent(.5)}const pC=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:a0,scaleDiverging:fC,scaleDivergingLog:hC,scaleDivergingPow:N0,scaleDivergingSqrt:vB,scaleDivergingSymlog:mC,scaleIdentity:GA,scaleImplicit:Kv,scaleLinear:KA,scaleLog:qA,scaleOrdinal:i0,scalePoint:i9,scalePow:p0,scaleQuantile:XA,scaleQuantize:ZA,scaleRadial:YA,scaleSequential:lC,scaleSequentialLog:uC,scaleSequentialPow:S0,scaleSequentialQuantile:dC,scaleSequentialSqrt:gB,scaleSequentialSymlog:cC,scaleSqrt:X9,scaleSymlog:QA,scaleThreshold:JA,scaleTime:mB,scaleUtc:pB,tickFormat:WA},Symbol.toStringTag,{value:"Module"}));function yB(e){var t=pC;if(e in t&&typeof t[e]=="function")return t[e]();var r="scale".concat(Cy(e));if(r in t&&typeof t[r]=="function")return t[r]()}function vS(e,t,r){if(typeof e=="function")return e.copy().domain(t).range(r);if(e!=null){var n=yB(e);if(n!=null)return n.domain(t).range(r),n}}function E0(e,t,r,n){if(!(r==null||n==null))return typeof e.scale=="function"?vS(e.scale,r,n):vS(t,r,n)}function xB(e){return"scale".concat(Cy(e))}function bB(e){return xB(e)in pC}var gC=(e,t,r)=>{if(e!=null){var n=e.scale,a=e.type;if(n==="auto")return a==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!t)?"point":a==="category"?"band":"linear";if(typeof n=="string")return bB(n)?n:"point"}};function wB(e,t){for(var r=0,n=e.length,a=e[0]<e[e.length-1];r<n;){var o=Math.floor((r+n)/2);(a?e[o]<t:e[o]>t)?r=o+1:n=o}return r}function vC(e,t){if(e){var r=t??e.domain(),n=r.map(o=>{var u;return(u=e(o))!==null&&u!==void 0?u:0}),a=e.range();if(!(r.length===0||a.length<2))return o=>{var u,c,f=wB(n,o);if(f<=0)return r[0];if(f>=r.length)return r[r.length-1];var h=(u=n[f-1])!==null&&u!==void 0?u:0,m=(c=n[f])!==null&&c!==void 0?c:0;return Math.abs(o-h)<=Math.abs(o-m)?r[f-1]:r[f]}}}function kB(e){if(e!=null)return"invert"in e&&typeof e.invert=="function"?e.invert.bind(e):vC(e,void 0)}function yS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function $f(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yS(Object(r),!0).forEach(function(n){jB(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jB(e,t,r){return(t=SB(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function SB(e){var t=NB(e,"string");return typeof t=="symbol"?t:t+""}function NB(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function yC(e,t){return PB(e)||CB(e,t)||AB(e,t)||EB()}function EB(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function AB(e,t){if(e){if(typeof e=="string")return xS(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?xS(e,t):void 0}}function xS(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CB(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function PB(e){if(Array.isArray(e))return e}var Qv=[0,"auto"],Et={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:void 0,height:30,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"bottom",padding:{left:0,right:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"category",unit:void 0,niceTicks:"auto"},xC=(e,t)=>e.cartesianAxis.xAxis[t],ki=(e,t)=>{var r=xC(e,t);return r??Et},At={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:Qv,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"left",padding:{top:0,bottom:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"number",unit:void 0,niceTicks:"auto",width:Gu},bC=(e,t)=>e.cartesianAxis.yAxis[t],ji=(e,t)=>{var r=bC(e,t);return r??At},OB={domain:[0,"auto"],includeHidden:!1,reversed:!1,allowDataOverflow:!1,allowDuplicatedCategory:!1,dataKey:void 0,id:0,name:"",range:[64,64],scale:"auto",type:"number",unit:""},A0=(e,t)=>{var r=e.cartesianAxis.zAxis[t];return r??OB},mr=(e,t,r)=>{switch(t){case"xAxis":return ki(e,r);case"yAxis":return ji(e,r);case"zAxis":return A0(e,r);case"angleAxis":return Xy(e,r);case"radiusAxis":return Zy(e,r);default:throw new Error("Unexpected axis type: ".concat(t))}},_B=(e,t,r)=>{switch(t){case"xAxis":return ki(e,r);case"yAxis":return ji(e,r);default:throw new Error("Unexpected axis type: ".concat(t))}},tc=(e,t,r)=>{switch(t){case"xAxis":return ki(e,r);case"yAxis":return ji(e,r);case"angleAxis":return Xy(e,r);case"radiusAxis":return Zy(e,r);default:throw new Error("Unexpected axis type: ".concat(t))}},wC=e=>e.graphicalItems.cartesianItems.some(t=>t.type==="bar")||e.graphicalItems.polarItems.some(t=>t.type==="radialBar");function kC(e,t){return r=>{switch(e){case"xAxis":return"xAxisId"in r&&r.xAxisId===t;case"yAxis":return"yAxisId"in r&&r.yAxisId===t;case"zAxis":return"zAxisId"in r&&r.zAxisId===t;case"angleAxis":return"angleAxisId"in r&&r.angleAxisId===t;case"radiusAxis":return"radiusAxisId"in r&&r.radiusAxisId===t;default:return!1}}}var jC=e=>e.graphicalItems.cartesianItems,MB=q([Rt,Rh],kC),SC=(e,t,r)=>e.filter(r).filter(n=>(t==null?void 0:t.includeHidden)===!0?!0:!n.hide),Js=q([jC,mr,MB],SC,{memoizeOptions:{resultEqualityCheck:$h}}),NC=q([Js],e=>e.filter(t=>t.type==="area"||t.type==="bar").filter(t0)),EC=e=>e.filter(t=>!("stackId"in t)||t.stackId===void 0),IB=q([Js],EC),AC=e=>e.map(t=>t.data).filter(Boolean).flat(1),TB=q([Js],e=>e.some(t=>!t.data)),CC=q([Js],AC,{memoizeOptions:{resultEqualityCheck:$h}}),PC=(e,t)=>{var r=t.chartData,n=r===void 0?[]:r,a=t.dataStartIndex,o=t.dataEndIndex;return e.length>0?e:n.slice(a,o+1)},C0=q([CC,_h],PC),DB=(e,t,r)=>(t==null?void 0:t.dataKey)!=null?e.map(n=>({value:Dt(n,t.dataKey)})):r.length>0?r.map(n=>n.dataKey).flatMap(n=>e.map(a=>({value:Dt(a,n)}))):e.map(n=>({value:n})),OC=(e,t,r,n,a,o)=>{var u=n.chartData,c=u===void 0?[]:u,f=n.dataStartIndex,h=n.dataEndIndex,m=DB(e,t,r);if(a&&(t==null?void 0:t.dataKey)!=null&&o.length>0){var g=c.slice(f,h+1),v=g.map(b=>({value:Dt(b,t.dataKey)})).filter(b=>b.value!=null);return[...v,...m]}return m},rc=q([C0,mr,Js,_h,TB,CC],OC);function gs(e){if(Bn(e)||e instanceof Date){var t=Number(e);if(He(t))return t}}function bS(e){if(Array.isArray(e)){var t=[gs(e[0]),gs(e[1])];return Rn(t)?t:void 0}var r=gs(e);if(r!=null)return[r,r]}function Wn(e){return e.map(gs).filter(jr)}function RB(e,t){var r=gs(e),n=gs(t);return r==null&&n==null?0:r==null?-1:n==null?1:r-n}var LB=q([rc],e=>e==null?void 0:e.map(t=>t.value).sort(RB));function _C(e,t){switch(e){case"xAxis":return t.direction==="x";case"yAxis":return t.direction==="y";default:return!1}}function $B(e,t,r){if(!r)return[];if(!r.length)return[];var n;if(typeof t=="number"&&!Fn(t))n=t;else if(Array.isArray(t)){var a=Wn(t);a.length>0&&(n=Math.max(...a))}return n==null?[]:Wn(r.flatMap(o=>{var u=Dt(e,o.dataKey),c,f;if(Array.isArray(u)){var h=yC(u,2);c=h[0],f=h[1]}else c=f=u;if(!(!He(c)||!He(f)))return[n-c,n+f]}))}var Pt=e=>{var t=Lt(e),r=Xs(e);return tc(e,t,r)},Bs=q([Pt],e=>e==null?void 0:e.dataKey),zB=q([NC,_h,Pt],DA),MC=(e,t,r,n)=>{var a={},o=t.reduce((u,c)=>{if(c.stackId==null)return u;var f=u[c.stackId];return f==null&&(f=[]),f.push(c),u[c.stackId]=f,u},a);return Object.fromEntries(Object.entries(o).map(u=>{var c=yC(u,2),f=c[0],h=c[1],m=n?[...h].reverse():h,g=m.map(e0);return[f,{stackedData:nz(e,g,r),graphicalItems:m}]}))},IC=q([zB,NC,Mh,CA],MC),TC=(e,t,r,n)=>{var a=t.dataStartIndex,o=t.dataEndIndex;if(n==null&&r!=="zAxis")return sz(e,a,o)},FB=q([mr],e=>e.allowDataOverflow),P0=e=>{var t;if(e==null||!("domain"in e))return Qv;if(e.domain!=null)return e.domain;if("ticks"in e&&e.ticks!=null){if(e.type==="number"){var r=Wn(e.ticks);return[Math.min(...r),Math.max(...r)]}if(e.type==="category")return e.ticks.map(String)}return(t=e==null?void 0:e.domain)!==null&&t!==void 0?t:Qv},DC=q([mr],P0),RC=q([DC,FB],vA),BB=q([IC,bn,Rt,RC],TC,{memoizeOptions:{resultEqualityCheck:Lh}}),O0=e=>e.errorBars,UB=(e,t,r)=>e.flatMap(n=>t[n.id]).filter(Boolean).filter(n=>_C(r,n)),zf=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];var a=r.filter(Boolean);if(a.length!==0){var o=a.flat(),u=Math.min(...o),c=Math.max(...o);return[u,c]}},LC=function(t,r,n,a,o){var u=arguments.length>5&&arguments[5]!==void 0?arguments[5]:[],c,f;if(n.length>0&&n.forEach(h=>{var m,g=h.data!=null?[...h.data]:u,v=(m=a[h.id])===null||m===void 0?void 0:m.filter(b=>_C(o,b));g.forEach(b=>{var j,k=Dt(b,(j=r.dataKey)!==null&&j!==void 0?j:h.dataKey),S=$B(b,k,v);if(S.length>=2){var N=Math.min(...S),E=Math.max(...S);(c==null||N<c)&&(c=N),(f==null||E>f)&&(f=E)}var A=bS(k);A!=null&&(c=c==null?A[0]:Math.min(c,A[0]),f=f==null?A[1]:Math.max(f,A[1]))})}),(r==null?void 0:r.dataKey)!=null&&n.length===0&&t.forEach(h=>{var m=bS(Dt(h,r.dataKey));m!=null&&(c=c==null?m[0]:Math.min(c,m[0]),f=f==null?m[1]:Math.max(f,m[1]))}),He(c)&&He(f))return[c,f]},HB=q([C0,mr,IB,O0,Rt,xF],LC,{memoizeOptions:{resultEqualityCheck:Lh}});function WB(e){var t=e.value;if(Bn(t)||t instanceof Date)return t}var KB=(e,t,r)=>{var n=e.map(WB).filter(a=>a!=null);return r&&(t.dataKey==null||t.allowDuplicatedCategory&&qE(n))?gA(0,e.length):t.allowDuplicatedCategory?n:Array.from(new Set(n))},$C=e=>e.referenceElements.dots,el=(e,t,r)=>e.filter(n=>n.ifOverflow==="extendDomain").filter(n=>t==="xAxis"?n.xAxisId===r:n.yAxisId===r),GB=q([$C,Rt,Rh],el),zC=e=>e.referenceElements.areas,VB=q([zC,Rt,Rh],el),FC=e=>e.referenceElements.lines,qB=q([FC,Rt,Rh],el),BC=(e,t)=>{if(e!=null){var r=Wn(e.map(n=>t==="xAxis"?n.x:n.y));if(r.length!==0)return[Math.min(...r),Math.max(...r)]}},QB=q(GB,Rt,BC),UC=(e,t)=>{if(e!=null){var r=Wn(e.flatMap(n=>[t==="xAxis"?n.x1:n.y1,t==="xAxis"?n.x2:n.y2]));if(r.length!==0)return[Math.min(...r),Math.max(...r)]}},YB=q([VB,Rt],UC);function XB(e){var t;if(e.x!=null)return Wn([e.x]);var r=(t=e.segment)===null||t===void 0?void 0:t.map(n=>n.x);return r==null||r.length===0?[]:Wn(r)}function ZB(e){var t;if(e.y!=null)return Wn([e.y]);var r=(t=e.segment)===null||t===void 0?void 0:t.map(n=>n.y);return r==null||r.length===0?[]:Wn(r)}var HC=(e,t)=>{if(e!=null){var r=e.flatMap(n=>t==="xAxis"?XB(n):ZB(n));if(r.length!==0)return[Math.min(...r),Math.max(...r)]}},JB=q([qB,Rt],HC),eU=q(QB,JB,YB,(e,t,r)=>zf(e,r,t)),WC=(e,t,r,n,a,o,u,c)=>{if(r!=null)return r;var f=u==="vertical"&&c==="xAxis"||u==="horizontal"&&c==="yAxis",h=f?zf(n,o,a):zf(o,a);return NF(t,h,e.allowDataOverflow)},tU=q([mr,DC,RC,BB,HB,eU,ct,Rt],WC,{memoizeOptions:{resultEqualityCheck:Lh}}),rU=[0,1],KC=(e,t,r,n,a,o,u)=>{if(!((e==null||r==null||r.length===0)&&u===void 0)){var c=e.dataKey,f=e.type,h=Gn(t,o);if(h&&c==null){var m;return gA(0,(m=r==null?void 0:r.length)!==null&&m!==void 0?m:0)}return f==="category"?KB(n,e,h):a==="expand"&&!h?rU:u}},_0=q([mr,ct,C0,rc,Mh,Rt,tU],KC),tl=q([mr,wC,qy],gC),GC=(e,t,r)=>{var n=t.niceTicks;if(n!=="none"){var a=P0(t),o=Array.isArray(a)&&(a[0]==="auto"||a[1]==="auto");if((n==="snap125"||n==="adaptive")&&t!=null&&t.tickCount&&Rn(e)){if(o)return Pj(e,t.tickCount,t.allowDecimals,n);if(t.type==="number")return Oj(e,t.tickCount,t.allowDecimals,n)}if(n==="auto"&&r==="linear"&&t!=null&&t.tickCount){if(o&&Rn(e))return Pj(e,t.tickCount,t.allowDecimals,"adaptive");if(t.type==="number"&&Rn(e))return Oj(e,t.tickCount,t.allowDecimals,"adaptive")}}},M0=q([_0,tc,tl],GC),VC=(e,t,r,n)=>{if(n!=="angleAxis"&&(e==null?void 0:e.type)==="number"&&Rn(t)&&Array.isArray(r)&&r.length>0){var a,o,u=t[0],c=(a=r[0])!==null&&a!==void 0?a:0,f=t[1],h=(o=r[r.length-1])!==null&&o!==void 0?o:0;return[Math.min(u,c),Math.max(f,h)]}return t},nU=q([mr,_0,M0,Rt],VC),iU=q(rc,mr,(e,t)=>{if(!(!t||t.type!=="number")){var r=1/0,n=Array.from(Wn(e.map(g=>g.value))).sort((g,v)=>g-v),a=n[0],o=n[n.length-1];if(a==null||o==null)return 1/0;var u=o-a;if(u===0)return 1/0;for(var c=0;c<n.length-1;c++){var f=n[c],h=n[c+1];if(!(f==null||h==null)){var m=h-f;r=Math.min(r,m)}}return r/u}}),qC=q(iU,ct,TF,Qt,(e,t,r,n,a)=>a,(e,t,r,n,a)=>{if(!He(e))return 0;var o=t==="vertical"?n.height:n.width;if(a==="gap")return e*o/2;if(a==="no-gap"){var u=pa(r,e*o),c=e*o/2;return c-u-(c-u)/o*u}return 0}),aU=(e,t,r)=>{var n=ki(e,t);return n==null||typeof n.padding!="string"?0:qC(e,"xAxis",t,r,n.padding)},oU=(e,t,r)=>{var n=ji(e,t);return n==null||typeof n.padding!="string"?0:qC(e,"yAxis",t,r,n.padding)},sU=q(ki,aU,(e,t)=>{var r,n;if(e==null)return{left:0,right:0};var a=e.padding;return typeof a=="string"?{left:t,right:t}:{left:((r=a.left)!==null&&r!==void 0?r:0)+t,right:((n=a.right)!==null&&n!==void 0?n:0)+t}}),lU=q(ji,oU,(e,t)=>{var r,n;if(e==null)return{top:0,bottom:0};var a=e.padding;return typeof a=="string"?{top:t,bottom:t}:{top:((r=a.top)!==null&&r!==void 0?r:0)+t,bottom:((n=a.bottom)!==null&&n!==void 0?n:0)+t}}),QC=q([Qt,sU,Nh,Sh,(e,t,r)=>r],(e,t,r,n,a)=>{var o=n.padding;return a?[o.left,r.width-o.right]:[e.left+t.left,e.left+e.width-t.right]}),YC=q([Qt,ct,lU,Nh,Sh,(e,t,r)=>r],(e,t,r,n,a,o)=>{var u=a.padding;return o?[n.height-u.bottom,u.top]:t==="horizontal"?[e.top+e.height-r.bottom,e.top+r.top]:[e.top+r.top,e.top+e.height-r.bottom]}),nc=(e,t,r,n)=>{var a;switch(t){case"xAxis":return QC(e,r,n);case"yAxis":return YC(e,r,n);case"zAxis":return(a=A0(e,r))===null||a===void 0?void 0:a.range;case"angleAxis":return MA(e);case"radiusAxis":return IA(e,r);default:return}},XC=q([mr,nc],Ih),uU=q([tl,nU],HF),I0=q([mr,tl,uU,XC],E0),ZC=(e,t,r,n)=>{if(!(r==null||r.dataKey==null)){var a=r.type,o=r.scale,u=Gn(e,n);if(u&&(a==="number"||o!=="auto"))return t.map(c=>c.value)}},T0=q([ct,rc,tc,Rt],ZC),Kh=q([I0],r0);q([I0],kB);q([I0,LB],vC);q([Js,O0,Rt],UB);function JC(e,t){return e.id<t.id?-1:e.id>t.id?1:0}var Gh=(e,t)=>t,Vh=(e,t,r)=>r,cU=q(kh,Gh,Vh,(e,t,r)=>e.filter(n=>n.orientation===t).filter(n=>n.mirror===r).sort(JC)),dU=q(jh,Gh,Vh,(e,t,r)=>e.filter(n=>n.orientation===t).filter(n=>n.mirror===r).sort(JC)),eP=(e,t)=>({width:e.width,height:t.height}),fU=(e,t)=>{var r=typeof t.width=="number"?t.width:Gu;return{width:r,height:e.height}},hU=q(Qt,ki,eP),mU=(e,t,r)=>{switch(t){case"top":return e.top;case"bottom":return r-e.bottom;default:return 0}},pU=(e,t,r)=>{switch(t){case"left":return e.left;case"right":return r-e.right;default:return 0}},gU=q(bi,Qt,cU,Gh,Vh,(e,t,r,n,a)=>{var o={},u;return r.forEach(c=>{var f=eP(t,c);u==null&&(u=mU(t,n,e));var h=n==="top"&&!a||n==="bottom"&&a;o[c.id]=u-Number(h)*f.height,u+=(h?-1:1)*f.height}),o}),vU=q(xi,Qt,dU,Gh,Vh,(e,t,r,n,a)=>{var o={},u;return r.forEach(c=>{var f=fU(t,c);u==null&&(u=pU(t,n,e));var h=n==="left"&&!a||n==="right"&&a;o[c.id]=u-Number(h)*f.width,u+=(h?-1:1)*f.width}),o}),yU=(e,t)=>{var r=ki(e,t);if(r!=null)return gU(e,r.orientation,r.mirror)},xU=q([Qt,ki,yU,(e,t)=>t],(e,t,r,n)=>{if(t!=null){var a=r==null?void 0:r[n];return a==null?{x:e.left,y:0}:{x:e.left,y:a}}}),bU=(e,t)=>{var r=ji(e,t);if(r!=null)return vU(e,r.orientation,r.mirror)},wU=q([Qt,ji,bU,(e,t)=>t],(e,t,r,n)=>{if(t!=null){var a=r==null?void 0:r[n];return a==null?{x:0,y:e.top}:{x:a,y:e.top}}}),kU=q(Qt,ji,(e,t)=>{var r=typeof t.width=="number"?t.width:Gu;return{width:r,height:e.height}}),tP=(e,t,r,n)=>{if(r!=null){var a=r.allowDuplicatedCategory,o=r.type,u=r.dataKey,c=Gn(e,n),f=t.map(m=>m.value),h=f.filter(m=>m!=null);if(u&&c&&o==="category"&&a&&qE(h))return f}},D0=q([ct,rc,mr,Rt],tP),wS=q([ct,_B,tl,Kh,D0,T0,nc,M0,Rt],(e,t,r,n,a,o,u,c,f)=>{if(t!=null){var h=Gn(e,f);return{angle:t.angle,interval:t.interval,minTickGap:t.minTickGap,orientation:t.orientation,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,axisType:f,categoricalDomain:o,duplicateDomain:a,isCategorical:h,niceTicks:c,range:u,realScaleType:r,scale:n}}}),jU=(e,t,r,n,a,o,u,c,f)=>{if(!(t==null||n==null)){var h=Gn(e,f),m=t.type,g=t.ticks,v=t.tickCount,b=r==="scaleBand"&&typeof n.bandwidth=="function"?n.bandwidth()/2:2,j=m==="category"&&n.bandwidth?n.bandwidth()/b:0;j=f==="angleAxis"&&o!=null&&o.length>=2?Vr(o[0]-o[1])*2*j:j;var k=g||a;return k?k.map((S,N)=>{var E=u?u.indexOf(S):S,A=n.map(E);return He(A)?{index:N,coordinate:A+j,value:S,offset:j}:null}).filter(jr):h&&c?c.map((S,N)=>{var E=n.map(S);return He(E)?{coordinate:E+j,value:S,index:N,offset:j}:null}).filter(jr):n.ticks?n.ticks(v).map((S,N)=>{var E=n.map(S);return He(E)?{coordinate:E+j,value:S,index:N,offset:j}:null}).filter(jr):n.domain().map((S,N)=>{var E=n.map(S);return He(E)?{coordinate:E+j,value:u?u[S]:S,index:N,offset:j}:null}).filter(jr)}},rP=q([ct,tc,tl,Kh,M0,nc,D0,T0,Rt],jU),SU=(e,t,r,n,a,o,u)=>{if(!(t==null||r==null||n==null||n[0]===n[1])){var c=Gn(e,u),f=t.tickCount,h=0;return h=u==="angleAxis"&&(n==null?void 0:n.length)>=2?Vr(n[0]-n[1])*2*h:h,c&&o?o.map((m,g)=>{var v=r.map(m);return He(v)?{coordinate:v+h,value:m,index:g,offset:h}:null}).filter(jr):r.ticks?r.ticks(f).map((m,g)=>{var v=r.map(m);return He(v)?{coordinate:v+h,value:m,index:g,offset:h}:null}).filter(jr):r.domain().map((m,g)=>{var v=r.map(m);return He(v)?{coordinate:v+h,value:a?a[m]:m,index:g,offset:h}:null}).filter(jr)}},nP=q([ct,tc,Kh,nc,D0,T0,Rt],SU),iP=q(mr,Kh,(e,t)=>{if(!(e==null||t==null))return $f($f({},e),{},{scale:t})}),NU=q([mr,tl,_0,XC],E0),EU=q([NU],r0);q((e,t,r)=>A0(e,r),EU,(e,t)=>{if(!(e==null||t==null))return $f($f({},e),{},{scale:t})});var AU=q([ct,kh,jh],(e,t,r)=>{switch(e){case"horizontal":return t.some(n=>n.reversed)?"right-to-left":"left-to-right";case"vertical":return r.some(n=>n.reversed)?"bottom-to-top":"top-to-bottom";case"centric":case"radial":return"left-to-right";default:return}}),CU=(e,t,r)=>{var n;return(n=e.renderedTicks[t])===null||n===void 0?void 0:n[r]};q([CU],e=>{if(!(!e||e.length===0))return t=>{var r,n=1/0,a=e[0];for(var o of e){var u=Math.abs(o.coordinate-t);u<n&&(n=u,a=o)}return(r=a)===null||r===void 0?void 0:r.value}});var aP=e=>e.options.defaultTooltipEventType,oP=e=>e.options.validateTooltipEventTypes;function sP(e,t,r){if(e==null)return t;var n=e?"axis":"item";return r==null?t:r.includes(n)?n:t}function ic(e,t){var r=aP(e),n=oP(e);return sP(t,r,n)}function PU(e){return Me(t=>ic(t,e))}var lP=(e,t)=>{var r,n=Number(t);if(!(Fn(n)||t==null))return n>=0?e==null||(r=e[n])===null||r===void 0?void 0:r.value:void 0},OU=e=>e.tooltip.settings,Ji={active:!1,index:null,dataKey:void 0,graphicalItemId:void 0,coordinate:void 0},_U={itemInteraction:{click:Ji,hover:Ji},axisInteraction:{click:Ji,hover:Ji},keyboardInteraction:Ji,syncInteraction:{active:!1,index:null,dataKey:void 0,label:void 0,coordinate:void 0,sourceViewBox:void 0,graphicalItemId:void 0},tooltipItemPayloads:[],settings:{shared:void 0,trigger:"hover",axisId:0,active:!1,defaultIndex:void 0}},uP=sr({name:"tooltip",initialState:_U,reducers:{addTooltipEntrySettings:{reducer(e,t){e.tooltipItemPayloads.push(t.payload)},prepare:ot()},replaceTooltipEntrySettings:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next,o=qr(e).tooltipItemPayloads.indexOf(n);o>-1&&(e.tooltipItemPayloads[o]=a)},prepare:ot()},removeTooltipEntrySettings:{reducer(e,t){var r=qr(e).tooltipItemPayloads.indexOf(t.payload);r>-1&&e.tooltipItemPayloads.splice(r,1)},prepare:ot()},setTooltipSettingsState(e,t){e.settings=t.payload},setActiveMouseOverItemIndex(e,t){e.syncInteraction.active=!1,e.syncInteraction.sourceViewBox=void 0,e.keyboardInteraction.active=!1,e.itemInteraction.hover.active=!0,e.itemInteraction.hover.index=t.payload.activeIndex,e.itemInteraction.hover.dataKey=t.payload.activeDataKey,e.itemInteraction.hover.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.hover.coordinate=t.payload.activeCoordinate},mouseLeaveChart(e){e.itemInteraction.hover.active=!1,e.axisInteraction.hover.active=!1},mouseLeaveItem(e){e.itemInteraction.hover.active=!1},setActiveClickItemIndex(e,t){e.syncInteraction.active=!1,e.syncInteraction.sourceViewBox=void 0,e.itemInteraction.click.active=!0,e.keyboardInteraction.active=!1,e.itemInteraction.click.index=t.payload.activeIndex,e.itemInteraction.click.dataKey=t.payload.activeDataKey,e.itemInteraction.click.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.click.coordinate=t.payload.activeCoordinate},setMouseOverAxisIndex(e,t){e.syncInteraction.active=!1,e.syncInteraction.sourceViewBox=void 0,e.axisInteraction.hover.active=!0,e.keyboardInteraction.active=!1,e.axisInteraction.hover.index=t.payload.activeIndex,e.axisInteraction.hover.dataKey=t.payload.activeDataKey,e.axisInteraction.hover.coordinate=t.payload.activeCoordinate},setMouseClickAxisIndex(e,t){e.syncInteraction.active=!1,e.syncInteraction.sourceViewBox=void 0,e.keyboardInteraction.active=!1,e.axisInteraction.click.active=!0,e.axisInteraction.click.index=t.payload.activeIndex,e.axisInteraction.click.dataKey=t.payload.activeDataKey,e.axisInteraction.click.coordinate=t.payload.activeCoordinate},setSyncInteraction(e,t){e.syncInteraction=t.payload},setKeyboardInteraction(e,t){e.keyboardInteraction.active=t.payload.active,e.keyboardInteraction.index=t.payload.activeIndex,e.keyboardInteraction.coordinate=t.payload.activeCoordinate}}}),tn=uP.actions,MU=tn.addTooltipEntrySettings,IU=tn.replaceTooltipEntrySettings,TU=tn.removeTooltipEntrySettings,DU=tn.setTooltipSettingsState,RU=tn.setActiveMouseOverItemIndex;tn.mouseLeaveItem;var cP=tn.mouseLeaveChart;tn.setActiveClickItemIndex;var dP=tn.setMouseOverAxisIndex,LU=tn.setMouseClickAxisIndex,lu=tn.setSyncInteraction,Ff=tn.setKeyboardInteraction,$U=uP.reducer;function kS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Rd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?kS(Object(r),!0).forEach(function(n){zU(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function zU(e,t,r){return(t=FU(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function FU(e){var t=BU(e,"string");return typeof t=="symbol"?t:t+""}function BU(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function UU(e,t,r){return t==="axis"?r==="click"?e.axisInteraction.click:e.axisInteraction.hover:r==="click"?e.itemInteraction.click:e.itemInteraction.hover}function HU(e){return e.index!=null}var fP=(e,t,r,n)=>{if(t==null)return Ji;var a=UU(e,t,r);if(a==null)return Ji;if(a.active)return a;if(e.keyboardInteraction.active)return e.keyboardInteraction;if(e.syncInteraction.active&&e.syncInteraction.index!=null)return e.syncInteraction;var o=e.settings.active===!0;if(HU(a)){if(o)return Rd(Rd({},a),{},{active:!0})}else if(n!=null)return{active:!0,coordinate:void 0,dataKey:void 0,index:n,graphicalItemId:void 0};return Rd(Rd({},Ji),{},{coordinate:a.coordinate})};function WU(e){if(typeof e=="number")return Number.isFinite(e)?e:void 0;if(e instanceof Date){var t=e.valueOf();return Number.isFinite(t)?t:void 0}var r=Number(e);return Number.isFinite(r)?r:void 0}function KU(e,t){var r=WU(e),n=t[0],a=t[1];if(r===void 0)return!1;var o=Math.min(n,a),u=Math.max(n,a);return r>=o&&r<=u}function GU(e,t,r){if(r==null||t==null)return!0;var n=Dt(e,t);return n==null||!Rn(r)?!0:KU(n,r)}var du=(e,t,r,n)=>{var a=e==null?void 0:e.index;if(a==null)return null;var o=Number(a);if(!He(o))return a;var u=0,c=1/0;t.length>0&&(c=t.length-1);var f=Math.max(u,Math.min(o,c)),h=t[f];return h==null||GU(h,r,n)?String(f):null},hP=(e,t,r,n,a,o,u)=>{if(o!=null){var c=u[0],f=c==null?void 0:c.getPosition(o);if(f!=null)return f;var h=a==null?void 0:a[Number(o)];if(h)switch(r){case"horizontal":return{x:h.coordinate,y:(n.top+t)/2};default:return{x:(n.left+e)/2,y:h.coordinate}}}},mP=(e,t,r,n)=>{if(t==="axis")return e.tooltipItemPayloads;if(e.tooltipItemPayloads.length===0)return[];var a;if(r==="hover"?a=e.itemInteraction.hover.graphicalItemId:a=e.itemInteraction.click.graphicalItemId,e.syncInteraction.active&&a==null)return e.tooltipItemPayloads;if(a==null&&(n!=null||e.keyboardInteraction.active)){var o=e.tooltipItemPayloads[0];return o!=null?[o]:[]}return e.tooltipItemPayloads.filter(u=>{var c;return((c=u.settings)===null||c===void 0?void 0:c.graphicalItemId)===a})},pP=e=>e.options.tooltipPayloadSearcher,rl=e=>e.tooltip;function jS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function SS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?jS(Object(r),!0).forEach(function(n){VU(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):jS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function VU(e,t,r){return(t=qU(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function qU(e){var t=QU(e,"string");return typeof t=="symbol"?t:t+""}function QU(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function YU(e){if(typeof e=="string"||typeof e=="number")return e}function XU(e){if(typeof e=="string"||typeof e=="number"||typeof e=="boolean")return e}function ZU(e){if(typeof e=="string"||typeof e=="number")return e;if(typeof e=="function")return t=>e(t)}function NS(e){if(typeof e=="string")return e}function JU(e){if(!(e==null||typeof e!="object")){var t="name"in e?YU(e.name):void 0,r="unit"in e?XU(e.unit):void 0,n="dataKey"in e?ZU(e.dataKey):void 0,a="payload"in e?e.payload:void 0,o="color"in e?NS(e.color):void 0,u="fill"in e?NS(e.fill):void 0;return{name:t,unit:r,dataKey:n,payload:a,color:o,fill:u}}}function eH(e,t){return e??t}var gP=(e,t,r,n,a,o,u)=>{if(!(t==null||o==null)){var c=r.chartData,f=r.computedData,h=r.dataStartIndex,m=r.dataEndIndex,g=[];return e.reduce((v,b)=>{var j,k=b.dataDefinedOnItem,S=b.settings,N=eH(k,c),E=Array.isArray(N)?B5(N,h,m):N,A=(j=S==null?void 0:S.dataKey)!==null&&j!==void 0?j:n,P=S==null?void 0:S.nameKey,_;if(n&&Array.isArray(E)&&!Array.isArray(E[0])&&u==="axis"?_=QE(E,n,a):_=o(E,t,f,P),Array.isArray(_))_.forEach(D=>{var B,F,z=JU(D),Y=z==null?void 0:z.name,U=z==null?void 0:z.dataKey,he=z==null?void 0:z.payload,ue=SS(SS({},S),{},{name:Y,unit:z==null?void 0:z.unit,color:(B=z==null?void 0:z.color)!==null&&B!==void 0?B:S==null?void 0:S.color,fill:(F=z==null?void 0:z.fill)!==null&&F!==void 0?F:S==null?void 0:S.fill});v.push(xk({tooltipEntrySettings:ue,dataKey:U,payload:he,value:Dt(he,U),name:Y==null?void 0:String(Y)}))});else{var O;v.push(xk({tooltipEntrySettings:S,dataKey:A,payload:_,value:Dt(_,A),name:(O=Dt(_,P))!==null&&O!==void 0?O:S==null?void 0:S.name}))}return v},g)}},R0=q([Pt,wC,qy],gC),tH=q([e=>e.graphicalItems.cartesianItems,e=>e.graphicalItems.polarItems],(e,t)=>[...e,...t]),rH=q([Lt,Xs],kC),jo=q([tH,Pt,rH],SC,{memoizeOptions:{resultEqualityCheck:$h}}),nH=q([jo],e=>e.filter(t0)),vP=q([jo],AC,{memoizeOptions:{resultEqualityCheck:$h}}),iH=q([jo],e=>e.some(t=>!t.data)),po=q([vP,bn],PC),aH=q([nH,bn,Pt],DA),L0=q([po,Pt,jo,bn,iH,vP],OC),yP=q([Pt],P0),oH=q([Pt],e=>e.allowDataOverflow),xP=q([yP,oH],vA),sH=q([jo],e=>e.filter(t0)),lH=q([aH,sH,Mh,CA],MC),uH=q([lH,bn,Lt,xP],TC),cH=q([jo],EC),dH=q([po,Pt,cH,O0,Lt,bF],LC,{memoizeOptions:{resultEqualityCheck:Lh}}),fH=q([$C,Lt,Xs],el),hH=q([fH,Lt],BC),mH=q([zC,Lt,Xs],el),pH=q([mH,Lt],UC),gH=q([FC,Lt,Xs],el),vH=q([gH,Lt],HC),yH=q([hH,vH,pH],zf),xH=q([Pt,yP,xP,uH,dH,yH,ct,Lt],WC),Us=q([Pt,ct,po,L0,Mh,Lt,xH],KC),bH=q([Us,Pt,R0],GC),wH=q([Pt,Us,bH,Lt],VC),bP=e=>{var t=Lt(e),r=Xs(e),n=!1;return nc(e,t,r,n)},wP=q([Pt,bP],Ih),kH=q([Pt,R0,wH,wP],E0),kP=q([kH],r0),jH=q([ct,L0,Pt,Lt],tP),SH=q([ct,L0,Pt,Lt],ZC),NH=(e,t,r,n,a,o,u,c)=>{if(t){var f=t.type,h=Gn(e,c);if(n){var m=r==="scaleBand"&&n.bandwidth?n.bandwidth()/2:2,g=f==="category"&&n.bandwidth?n.bandwidth()/m:0;return g=c==="angleAxis"&&a!=null&&(a==null?void 0:a.length)>=2?Vr(a[0]-a[1])*2*g:g,h&&u?u.map((v,b)=>{var j=n.map(v);return He(j)?{coordinate:j+g,value:v,index:b,offset:g}:null}).filter(jr):n.domain().map((v,b)=>{var j=n.map(v);return He(j)?{coordinate:j+g,value:o?o[v]:v,index:b,offset:g}:null}).filter(jr)}}},Si=q([ct,Pt,R0,kP,bP,jH,SH,Lt],NH),$0=q([aP,oP,OU],(e,t,r)=>sP(r.shared,e,t)),jP=e=>e.tooltip.settings.trigger,z0=e=>e.tooltip.settings.defaultIndex,ac=q([rl,$0,jP,z0],fP),Iu=q([ac,po,Bs,Us],du),SP=q([Si,Iu],lP),EH=q([ac],e=>{if(e)return e.dataKey}),AH=q([ac],e=>{if(e)return e.graphicalItemId}),NP=q([rl,$0,jP,z0],mP),CH=q([xi,bi,ct,Qt,Si,z0,NP],hP),PH=q([ac,CH],(e,t)=>e!=null&&e.coordinate?e.coordinate:t),OH=q([ac],e=>{var t;return(t=e==null?void 0:e.active)!==null&&t!==void 0?t:!1}),_H=q([NP,Iu,bn,Bs,SP,pP,$0],gP),MH=q([_H],e=>{if(e!=null){var t=e.map(r=>r.payload).filter(r=>r!=null);return Array.from(new Set(t))}});function ES(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function AS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ES(Object(r),!0).forEach(function(n){IH(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ES(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function IH(e,t,r){return(t=TH(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function TH(e){var t=DH(e,"string");return typeof t=="symbol"?t:t+""}function DH(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var RH=()=>Me(Pt),LH=()=>{var e=RH(),t=Me(Si),r=Me(kP);return gf(!e||!r?void 0:AS(AS({},e),{},{scale:r}),t)};function CS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function rs(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?CS(Object(r),!0).forEach(function(n){$H(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):CS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function $H(e,t,r){return(t=zH(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function zH(e){var t=FH(e,"string");return typeof t=="symbol"?t:t+""}function FH(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var BH=(e,t,r,n)=>{var a=t.find(o=>o&&o.index===r);if(a){if(e==="horizontal")return{x:a.coordinate,y:n.relativeY};if(e==="vertical")return{x:n.relativeX,y:a.coordinate}}return{x:0,y:0}},UH=(e,t,r,n)=>{var a=t.find(h=>h&&h.index===r);if(a){if(e==="centric"){var o=a.coordinate,u=n.radius;return rs(rs(rs({},n),Kt(n.cx,n.cy,u,o)),{},{angle:o,radius:u})}var c=a.coordinate,f=n.angle;return rs(rs(rs({},n),Kt(n.cx,n.cy,c,f)),{},{angle:f,radius:c})}return{angle:0,clockWise:!1,cx:0,cy:0,endAngle:0,innerRadius:0,outerRadius:0,radius:0,startAngle:0,x:0,y:0}};function HH(e,t){var r=e.relativeX,n=e.relativeY;return r>=t.left&&r<=t.left+t.width&&n>=t.top&&n<=t.top+t.height}var EP=(e,t,r,n,a)=>{var o,u=(o=t==null?void 0:t.length)!==null&&o!==void 0?o:0;if(u<=1||e==null)return 0;if(n==="angleAxis"&&a!=null&&Math.abs(Math.abs(a[1]-a[0])-360)<=1e-6)for(var c=0;c<u;c++){var f,h,m,g,v,b=c>0?(f=r[c-1])===null||f===void 0?void 0:f.coordinate:(h=r[u-1])===null||h===void 0?void 0:h.coordinate,j=(m=r[c])===null||m===void 0?void 0:m.coordinate,k=c>=u-1?(g=r[0])===null||g===void 0?void 0:g.coordinate:(v=r[c+1])===null||v===void 0?void 0:v.coordinate,S=void 0;if(!(b==null||j==null||k==null))if(Vr(j-b)!==Vr(k-j)){var N=[];if(Vr(k-j)===Vr(a[1]-a[0])){S=k;var E=j+a[1]-a[0];N[0]=Math.min(E,(E+b)/2),N[1]=Math.max(E,(E+b)/2)}else{S=b;var A=k+a[1]-a[0];N[0]=Math.min(j,(A+j)/2),N[1]=Math.max(j,(A+j)/2)}var P=[Math.min(j,(S+j)/2),Math.max(j,(S+j)/2)];if(e>P[0]&&e<=P[1]||e>=N[0]&&e<=N[1]){var _;return(_=r[c])===null||_===void 0?void 0:_.index}}else{var O=Math.min(b,k),D=Math.max(b,k);if(e>(O+j)/2&&e<=(D+j)/2){var B;return(B=r[c])===null||B===void 0?void 0:B.index}}}else if(t)for(var F=0;F<u;F++){var z=t[F];if(z!=null){var Y=t[F+1],U=t[F-1];if(F===0&&Y!=null&&e<=(z.coordinate+Y.coordinate)/2||F===u-1&&U!=null&&e>(z.coordinate+U.coordinate)/2||F>0&&F<u-1&&U!=null&&Y!=null&&e>(z.coordinate+U.coordinate)/2&&e<=(z.coordinate+Y.coordinate)/2)return z.index}}return-1},AP=()=>Me(qy),F0=(e,t)=>t,CP=(e,t,r)=>r,B0=(e,t,r,n)=>n,WH=q(Si,e=>dh(e,t=>t.coordinate)),U0=q([rl,F0,CP,B0],fP),H0=q([U0,po,Bs,Us],du),KH=(e,t,r)=>{if(t!=null){var n=rl(e);return t==="axis"?r==="hover"?n.axisInteraction.hover.dataKey:n.axisInteraction.click.dataKey:r==="hover"?n.itemInteraction.hover.dataKey:n.itemInteraction.click.dataKey}},PP=q([rl,F0,CP,B0],mP),Bf=q([xi,bi,ct,Qt,Si,B0,PP],hP),GH=q([U0,Bf],(e,t)=>{var r;return(r=e.coordinate)!==null&&r!==void 0?r:t}),OP=q([Si,H0],lP),VH=q([PP,H0,bn,Bs,OP,pP,F0],gP),qH=q([U0,H0],(e,t)=>({isActive:e.active&&t!=null,activeIndex:t})),QH=(e,t,r,n,a,o,u)=>{if(!(!e||!r||!n||!a)&&HH(e,u)){var c=lz(e,t),f=EP(c,o,a,r,n),h=BH(t,a,f,e);return{activeIndex:String(f),activeCoordinate:h}}},YH=(e,t,r,n,a,o,u)=>{if(!(!e||!n||!a||!o||!r)){var c=dF(e,r);if(c){var f=uz(c,t),h=EP(f,u,o,n,a),m=UH(t,o,h,c);return{activeIndex:String(h),activeCoordinate:m}}}},XH=(e,t,r,n,a,o,u,c)=>{if(!(!e||!t||!n||!a||!o))return t==="horizontal"||t==="vertical"?QH(e,t,n,a,o,u,c):YH(e,t,r,n,a,o,u)},ZH=q(e=>e.zIndex.zIndexMap,(e,t)=>t,(e,t,r)=>r,(e,t,r)=>{if(t!=null){var n=e[t];if(n!=null)return r?n.panoramaElement:n.element}}),JH=q(e=>e.zIndex.zIndexMap,e=>{var t=Object.keys(e).map(n=>parseInt(n,10)).concat(Object.values(dr)),r=Array.from(new Set(t));return r.sort((n,a)=>n-a)},{memoizeOptions:{resultEqualityCheck:UF}});function PS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function OS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?PS(Object(r),!0).forEach(function(n){eW(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):PS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function eW(e,t,r){return(t=tW(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tW(e){var t=rW(e,"string");return typeof t=="symbol"?t:t+""}function rW(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var nW={},iW={zIndexMap:Object.values(dr).reduce((e,t)=>OS(OS({},e),{},{[t]:{element:void 0,panoramaElement:void 0,consumers:0}}),nW)},aW=new Set(Object.values(dr));function oW(e){return aW.has(e)}var _P=sr({name:"zIndex",initialState:iW,reducers:{registerZIndexPortal:{reducer:(e,t)=>{var r=t.payload.zIndex;e.zIndexMap[r]?e.zIndexMap[r].consumers+=1:e.zIndexMap[r]={consumers:1,element:void 0,panoramaElement:void 0}},prepare:ot()},unregisterZIndexPortal:{reducer:(e,t)=>{var r=t.payload.zIndex;e.zIndexMap[r]&&(e.zIndexMap[r].consumers-=1,e.zIndexMap[r].consumers<=0&&!oW(r)&&delete e.zIndexMap[r])},prepare:ot()},registerZIndexPortalElement:{reducer:(e,t)=>{var r=t.payload,n=r.zIndex,a=r.element,o=r.isPanorama;e.zIndexMap[n]?o?e.zIndexMap[n].panoramaElement=a:e.zIndexMap[n].element=a:e.zIndexMap[n]={consumers:0,element:o?void 0:a,panoramaElement:o?a:void 0}},prepare:ot()},unregisterZIndexPortalElement:{reducer:(e,t)=>{var r=t.payload.zIndex;e.zIndexMap[r]&&(t.payload.isPanorama?e.zIndexMap[r].panoramaElement=void 0:e.zIndexMap[r].element=void 0)},prepare:ot()}}}),qh=_P.actions,sW=qh.registerZIndexPortal,Ag=qh.unregisterZIndexPortal,lW=qh.registerZIndexPortalElement,uW=qh.unregisterZIndexPortalElement,cW=_P.reducer;function Ni(e){var t=e.zIndex,r=e.children,n=Vz(),a=n&&t!==void 0&&t!==0,o=Nr(),u=y.useRef(void 0),c=y.useRef(new Set),f=jt(),h=Me(g=>ZH(g,t,o));if(y.useLayoutEffect(()=>{if(!a){var g=c.current;g.forEach(b=>{f(Ag({zIndex:b}))}),g.clear(),u.current=void 0;return}if(c.current.has(t)||(f(sW({zIndex:t})),c.current.add(t)),h){u.current=h;var v=c.current;v.forEach(b=>{b!==t&&(f(Ag({zIndex:b})),v.delete(b))})}},[f,t,a,h]),y.useLayoutEffect(()=>{var g=c.current;return()=>{g.forEach(v=>{f(Ag({zIndex:v}))}),g.clear()}},[f]),!a)return r;var m=h??u.current;return m?rh.createPortal(r,m):null}function Yv(){return Yv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Yv.apply(null,arguments)}function _S(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Ld(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?_S(Object(r),!0).forEach(function(n){dW(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_S(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function dW(e,t,r){return(t=fW(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function fW(e){var t=hW(e,"string");return typeof t=="symbol"?t:t+""}function hW(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function mW(e){var t=e.cursor,r=e.cursorComp,n=e.cursorProps;return y.isValidElement(t)?y.cloneElement(t,n):y.createElement(r,n)}function pW(e){var t,r=e.coordinate,n=e.payload,a=e.index,o=e.offset,u=e.tooltipAxisBandSize,c=e.layout,f=e.cursor,h=e.tooltipEventType,m=e.chartName,g=r,v=n,b=a;if(!f||!g||m!=="ScatterChart"&&h!=="axis")return null;var j,k,S;if(m==="ScatterChart")j=g,k=x8,S=dr.cursorLine;else if(m==="BarChart")j=b8(c,g,o,u),k=tF,S=dr.cursorRectangle;else if(c==="radial"&&YE(g)){var N=mA(g),E=N.cx,A=N.cy,P=N.radius,_=N.startAngle,O=N.endAngle;j={cx:E,cy:A,startAngle:_,endAngle:O,innerRadius:P,outerRadius:P},k=pF,S=dr.cursorLine}else j={points:gF(c,g,o)},k=Vd,S=dr.cursorLine;var D=typeof f=="object"&&"className"in f?f.className:void 0,B=Ld(Ld(Ld(Ld({stroke:"#ccc",pointerEvents:"none"},o),j),lh(f)),{},{payload:v,payloadIndex:b,className:rt("recharts-tooltip-cursor",D)});return y.createElement(Ni,{zIndex:(t=e.zIndex)!==null&&t!==void 0?t:S},y.createElement(mW,{cursor:f,cursorComp:k,cursorProps:B}))}function gW(e){var t=LH(),r=Y5(),n=qs(),a=AP();return t==null||r==null||n==null||a==null?null:y.createElement(pW,Yv({},e,{offset:r,layout:n,tooltipAxisBandSize:t,chartName:a}))}var MP=y.createContext(null),vW=()=>y.useContext(MP),Cg={exports:{}},MS;function yW(){return MS||(MS=1,(function(e){var t=Object.prototype.hasOwnProperty,r="~";function n(){}Object.create&&(n.prototype=Object.create(null),new n().__proto__||(r=!1));function a(f,h,m){this.fn=f,this.context=h,this.once=m||!1}function o(f,h,m,g,v){if(typeof m!="function")throw new TypeError("The listener must be a function");var b=new a(m,g||f,v),j=r?r+h:h;return f._events[j]?f._events[j].fn?f._events[j]=[f._events[j],b]:f._events[j].push(b):(f._events[j]=b,f._eventsCount++),f}function u(f,h){--f._eventsCount===0?f._events=new n:delete f._events[h]}function c(){this._events=new n,this._eventsCount=0}c.prototype.eventNames=function(){var h=[],m,g;if(this._eventsCount===0)return h;for(g in m=this._events)t.call(m,g)&&h.push(r?g.slice(1):g);return Object.getOwnPropertySymbols?h.concat(Object.getOwnPropertySymbols(m)):h},c.prototype.listeners=function(h){var m=r?r+h:h,g=this._events[m];if(!g)return[];if(g.fn)return[g.fn];for(var v=0,b=g.length,j=new Array(b);v<b;v++)j[v]=g[v].fn;return j},c.prototype.listenerCount=function(h){var m=r?r+h:h,g=this._events[m];return g?g.fn?1:g.length:0},c.prototype.emit=function(h,m,g,v,b,j){var k=r?r+h:h;if(!this._events[k])return!1;var S=this._events[k],N=arguments.length,E,A;if(S.fn){switch(S.once&&this.removeListener(h,S.fn,void 0,!0),N){case 1:return S.fn.call(S.context),!0;case 2:return S.fn.call(S.context,m),!0;case 3:return S.fn.call(S.context,m,g),!0;case 4:return S.fn.call(S.context,m,g,v),!0;case 5:return S.fn.call(S.context,m,g,v,b),!0;case 6:return S.fn.call(S.context,m,g,v,b,j),!0}for(A=1,E=new Array(N-1);A<N;A++)E[A-1]=arguments[A];S.fn.apply(S.context,E)}else{var P=S.length,_;for(A=0;A<P;A++)switch(S[A].once&&this.removeListener(h,S[A].fn,void 0,!0),N){case 1:S[A].fn.call(S[A].context);break;case 2:S[A].fn.call(S[A].context,m);break;case 3:S[A].fn.call(S[A].context,m,g);break;case 4:S[A].fn.call(S[A].context,m,g,v);break;default:if(!E)for(_=1,E=new Array(N-1);_<N;_++)E[_-1]=arguments[_];S[A].fn.apply(S[A].context,E)}}return!0},c.prototype.on=function(h,m,g){return o(this,h,m,g,!1)},c.prototype.once=function(h,m,g){return o(this,h,m,g,!0)},c.prototype.removeListener=function(h,m,g,v){var b=r?r+h:h;if(!this._events[b])return this;if(!m)return u(this,b),this;var j=this._events[b];if(j.fn)j.fn===m&&(!v||j.once)&&(!g||j.context===g)&&u(this,b);else{for(var k=0,S=[],N=j.length;k<N;k++)(j[k].fn!==m||v&&!j[k].once||g&&j[k].context!==g)&&S.push(j[k]);S.length?this._events[b]=S.length===1?S[0]:S:u(this,b)}return this},c.prototype.removeAllListeners=function(h){var m;return h?(m=r?r+h:h,this._events[m]&&u(this,m)):(this._events=new n,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,e.exports=c})(Cg)),Cg.exports}var xW=yW();const bW=ly(xW);var Tu=new bW,Xv="recharts.syncEvent.tooltip",IS="recharts.syncEvent.brush",wW=(e,t)=>{if(t&&Array.isArray(e)){var r=Number.parseInt(t,10);if(!Fn(r))return e[r]}},kW={chartName:"",tooltipPayloadSearcher:()=>{},eventEmitter:void 0,defaultTooltipEventType:"axis"},IP=sr({name:"options",initialState:kW,reducers:{createEventEmitter:e=>{e.eventEmitter==null&&(e.eventEmitter=Symbol("rechartsEventEmitter"))}}}),jW=IP.reducer,SW=IP.actions.createEventEmitter;function NW(e){return e.tooltip.syncInteraction}var EW={chartData:void 0,computedData:void 0,dataStartIndex:0,dataEndIndex:0},TP=sr({name:"chartData",initialState:EW,reducers:{setChartData(e,t){if(e.chartData=t.payload,t.payload==null){e.dataStartIndex=0,e.dataEndIndex=0;return}t.payload.length>0&&e.dataEndIndex!==t.payload.length-1&&(e.dataEndIndex=t.payload.length-1)},setComputedData(e,t){e.computedData=t.payload},setDataStartEndIndexes(e,t){var r=t.payload,n=r.startIndex,a=r.endIndex;n!=null&&(e.dataStartIndex=n),a!=null&&(e.dataEndIndex=a)}}}),W0=TP.actions,TS=W0.setChartData,AW=W0.setDataStartEndIndexes;W0.setComputedData;var CW=TP.reducer,PW=["x","y"];function DS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ns(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?DS(Object(r),!0).forEach(function(n){OW(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):DS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function OW(e,t,r){return(t=_W(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function _W(e){var t=MW(e,"string");return typeof t=="symbol"?t:t+""}function MW(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function IW(e,t){if(e==null)return{};var r,n,a=TW(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function TW(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function DW(){var e=Me(Qy),t=Me(Yy),r=jt(),n=Me(PA),a=Me(Si),o=qs(),u=Eh(),c=Me(f=>f.rootProps.className);y.useEffect(()=>{if(e==null)return Vs;var f=(h,m,g)=>{if(t!==g&&e===h){if(m.payload.active===!1){r(lu({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0,sourceViewBox:void 0,graphicalItemId:void 0}));return}if(n==="index"){var v;if(u&&m!==null&&m!==void 0&&(v=m.payload)!==null&&v!==void 0&&v.coordinate&&m.payload.sourceViewBox){var b=m.payload.coordinate,j=b.x,k=b.y,S=IW(b,PW),N=m.payload.sourceViewBox,E=N.x,A=N.y,P=N.width,_=N.height,O=ns(ns({},S),{},{x:u.x+(P?(j-E)/P:0)*u.width,y:u.y+(_?(k-A)/_:0)*u.height});r(ns(ns({},m),{},{payload:ns(ns({},m.payload),{},{coordinate:O})}))}else r(m);return}if(a!=null){var D;if(typeof n=="function"){var B={activeTooltipIndex:m.payload.index==null?void 0:Number(m.payload.index),isTooltipActive:m.payload.active,activeIndex:m.payload.index==null?void 0:Number(m.payload.index),activeLabel:m.payload.label,activeDataKey:m.payload.dataKey,activeCoordinate:m.payload.coordinate},F=n(a,B);D=a[F]}else n==="value"&&(D=a.find(se=>String(se.value)===m.payload.label));var z=m.payload.coordinate;if(z==null||u==null){r(lu({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0,sourceViewBox:void 0,graphicalItemId:void 0}));return}if(D==null){r(lu({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0,sourceViewBox:m.payload.sourceViewBox,graphicalItemId:void 0}));return}var Y=z.x,U=z.y,he=Math.min(Y,u.x+u.width),ue=Math.min(U,u.y+u.height),ge={x:o==="horizontal"?D.coordinate:he,y:o==="horizontal"?ue:D.coordinate},ie=lu({active:m.payload.active,coordinate:ge,dataKey:m.payload.dataKey,index:String(D.index),label:m.payload.label,sourceViewBox:m.payload.sourceViewBox,graphicalItemId:m.payload.graphicalItemId});r(ie)}}};return Tu.on(Xv,f),()=>{Tu.off(Xv,f)}},[c,r,t,e,n,a,o,u])}function RW(){var e=Me(Qy),t=Me(Yy),r=jt();y.useEffect(()=>{if(e==null)return Vs;var n=(a,o,u)=>{t!==u&&e===a&&r(AW(o))};return Tu.on(IS,n),()=>{Tu.off(IS,n)}},[r,t,e])}function LW(){var e=jt();y.useEffect(()=>{e(SW())},[e]),DW(),RW()}function $W(e,t,r,n,a,o){var u=Me(j=>KH(j,e,t)),c=Me(AH),f=Me(Yy),h=Me(Qy),m=Me(PA),g=Me(NW),v=(g==null?void 0:g.sourceViewBox)!=null,b=Eh();y.useEffect(()=>{if(!v&&h!=null&&f!=null){var j=lu({active:o,coordinate:r,dataKey:u,index:a,label:typeof n=="number"?String(n):n,sourceViewBox:b,graphicalItemId:c});Tu.emit(Xv,h,j,f)}},[v,r,u,c,a,n,f,h,m,o,b])}function RS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function LS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?RS(Object(r),!0).forEach(function(n){zW(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):RS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function zW(e,t,r){return(t=FW(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function FW(e){var t=BW(e,"string");return typeof t=="symbol"?t:t+""}function BW(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function UW(e,t){return GW(e)||KW(e,t)||WW(e,t)||HW()}function HW(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function WW(e,t){if(e){if(typeof e=="string")return $S(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?$S(e,t):void 0}}function $S(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function KW(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function GW(e){if(Array.isArray(e))return e}function VW(e){return e.dataKey}function qW(e,t){return y.isValidElement(e)?y.cloneElement(e,t):typeof e=="function"?y.createElement(e,t):y.createElement($6,t)}var zS=[],QW={allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",axisId:0,contentStyle:{},cursor:!0,filterNull:!0,includeHidden:!1,isAnimationActive:"auto",itemSorter:"name",itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,wrapperStyle:{}};function YW(e){var t,r,n=Jr(e,QW),a=n.active,o=n.allowEscapeViewBox,u=n.animationDuration,c=n.animationEasing,f=n.content,h=n.filterNull,m=n.isAnimationActive,g=n.offset,v=n.payloadUniqBy,b=n.position,j=n.reverseDirection,k=n.useTranslate3d,S=n.wrapperStyle,N=n.cursor,E=n.shared,A=n.trigger,P=n.defaultIndex,_=n.portal,O=n.axisId,D=jt(),B=typeof P=="number"?String(P):P;y.useEffect(()=>{D(DU({shared:E,trigger:A,axisId:O,active:a,defaultIndex:B}))},[D,E,A,O,a,B]);var F=Eh(),z=lA(),Y=PU(E),U=(t=Me(_e=>qH(_e,Y,A,B)))!==null&&t!==void 0?t:{},he=U.activeIndex,ue=U.isActive,ge=Me(_e=>VH(_e,Y,A,B)),ie=Me(_e=>OP(_e,Y,A,B)),se=Me(_e=>GH(_e,Y,A,B)),X=ge,te=vW(),J=(r=a??ue)!==null&&r!==void 0?r:!1,I=qL([X,J]),M=UW(I,2),H=M[0],ne=M[1],Z=Y==="axis"?ie:void 0;$W(Y,A,se,Z,he,J);var me=_??te;if(me==null||F==null||Y==null)return null;var pe=X??zS;J||(pe=zS),h&&pe.length&&(pe=vL(pe.filter(_e=>_e.value!=null&&(_e.hide!==!0||n.includeHidden)),v,VW));var Oe=pe.length>0,re=LS(LS({},n),{},{payload:pe,label:Z,active:J,activeIndex:he,coordinate:se,accessibilityLayer:z}),we=y.createElement(a8,{allowEscapeViewBox:o,animationDuration:u,animationEasing:c,isAnimationActive:m,active:J,coordinate:se,hasPayload:Oe,offset:g,position:b,reverseDirection:j,useTranslate3d:k,viewBox:F,wrapperStyle:S,lastBoundingBox:H,innerRef:ne,hasPortalFromProps:!!_},qW(f,re));return y.createElement(y.Fragment,null,rh.createPortal(we,me),J&&y.createElement(gW,{cursor:N,tooltipEventType:Y,coordinate:se,payload:pe,index:he}))}function XW(e,t,r){return(t=ZW(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ZW(e){var t=JW(e,"string");return typeof t=="symbol"?t:t+""}function JW(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}class eK{constructor(t){XW(this,"cache",new Map),this.maxSize=t}get(t){var r=this.cache.get(t);return r!==void 0&&(this.cache.delete(t),this.cache.set(t,r)),r}set(t,r){if(this.cache.has(t))this.cache.delete(t);else if(this.cache.size>=this.maxSize){var n=this.cache.keys().next().value;n!=null&&this.cache.delete(n)}this.cache.set(t,r)}clear(){this.cache.clear()}size(){return this.cache.size}}function FS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function tK(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?FS(Object(r),!0).forEach(function(n){rK(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):FS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function rK(e,t,r){return(t=nK(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function nK(e){var t=iK(e,"string");return typeof t=="symbol"?t:t+""}function iK(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var aK={cacheSize:2e3,enableCache:!0},DP=tK({},aK),BS=new eK(DP.cacheSize),oK={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},US="recharts_measurement_span";function sK(e,t){var r=t.fontSize||"",n=t.fontFamily||"",a=t.fontWeight||"",o=t.fontStyle||"",u=t.letterSpacing||"",c=t.textTransform||"";return"".concat(e,"|").concat(r,"|").concat(n,"|").concat(a,"|").concat(o,"|").concat(u,"|").concat(c)}var HS=(e,t)=>{try{var r=document.getElementById(US);r||(r=document.createElement("span"),r.setAttribute("id",US),r.setAttribute("aria-hidden","true"),document.body.appendChild(r)),Object.assign(r.style,oK,t),r.textContent="".concat(e);var n=r.getBoundingClientRect();return{width:n.width,height:n.height}}catch{return{width:0,height:0}}},fu=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||Yu.isSsr)return{width:0,height:0};if(!DP.enableCache)return HS(t,r);var n=sK(t,r),a=BS.get(n);if(a)return a;var o=HS(t,r);return BS.set(n,o),o},RP;function Uf(e,t){return dK(e)||cK(e,t)||uK(e,t)||lK()}function lK(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function uK(e,t){if(e){if(typeof e=="string")return WS(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?WS(e,t):void 0}}function WS(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function cK(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;f=!1}else for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function dK(e){if(Array.isArray(e))return e}function fK(e,t,r){return(t=hK(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hK(e){var t=mK(e,"string");return typeof t=="symbol"?t:t+""}function mK(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var KS=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,GS=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,pK=/^(px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q)$/,gK=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,vK={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},yK=["cm","mm","pt","pc","in","Q","px"];function xK(e){return yK.includes(e)}var ds="NaN";function bK(e,t){return e*vK[t]}class Ht{static parse(t){var r,n=(r=gK.exec(t))!==null&&r!==void 0?r:[],a=Uf(n,3),o=a[1],u=a[2];return o==null?Ht.NaN:new Ht(parseFloat(o),u??"")}constructor(t,r){this.num=t,this.unit=r,this.num=t,this.unit=r,Fn(t)&&(this.unit=""),r!==""&&!pK.test(r)&&(this.num=NaN,this.unit=""),xK(r)&&(this.num=bK(t,r),this.unit="px")}add(t){return this.unit!==t.unit?new Ht(NaN,""):new Ht(this.num+t.num,this.unit)}subtract(t){return this.unit!==t.unit?new Ht(NaN,""):new Ht(this.num-t.num,this.unit)}multiply(t){return this.unit!==""&&t.unit!==""&&this.unit!==t.unit?new Ht(NaN,""):new Ht(this.num*t.num,this.unit||t.unit)}divide(t){return this.unit!==""&&t.unit!==""&&this.unit!==t.unit?new Ht(NaN,""):new Ht(this.num/t.num,this.unit||t.unit)}toString(){return"".concat(this.num).concat(this.unit)}isNaN(){return Fn(this.num)}}RP=Ht;fK(Ht,"NaN",new RP(NaN,""));function LP(e){if(e==null||e.includes(ds))return ds;for(var t=e;t.includes("*")||t.includes("/");){var r,n=(r=KS.exec(t))!==null&&r!==void 0?r:[],a=Uf(n,4),o=a[1],u=a[2],c=a[3],f=Ht.parse(o??""),h=Ht.parse(c??""),m=u==="*"?f.multiply(h):f.divide(h);if(m.isNaN())return ds;t=t.replace(KS,m.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var g,v=(g=GS.exec(t))!==null&&g!==void 0?g:[],b=Uf(v,4),j=b[1],k=b[2],S=b[3],N=Ht.parse(j??""),E=Ht.parse(S??""),A=k==="+"?N.add(E):N.subtract(E);if(A.isNaN())return ds;t=t.replace(GS,A.toString())}return t}var VS=/\(([^()]*)\)/;function wK(e){for(var t=e,r;(r=VS.exec(t))!=null;){var n=r,a=Uf(n,2),o=a[1];t=t.replace(VS,LP(o))}return t}function kK(e){var t=e.replace(/\s+/g,"");return t=wK(t),t=LP(t),t}function jK(e){try{return kK(e)}catch{return ds}}function Pg(e){var t=jK(e.slice(5,-1));return t===ds?"":t}var SK=["x","y","lineHeight","capHeight","fill","scaleToFit","textAnchor","verticalAnchor"],NK=["dx","dy","angle","className","breakAll"];function Zv(){return Zv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Zv.apply(null,arguments)}function qS(e,t){if(e==null)return{};var r,n,a=EK(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function EK(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function QS(e,t){return OK(e)||PK(e,t)||CK(e,t)||AK()}function AK(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function CK(e,t){if(e){if(typeof e=="string")return YS(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?YS(e,t):void 0}}function YS(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function PK(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;f=!1}else for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function OK(e){if(Array.isArray(e))return e}var $P=/[ \f\n\r\t\v\u2028\u2029]+/,zP=e=>{var t=e.children,r=e.breakAll,n=e.style;try{var a=[];Gt(t)||(r?a=t.toString().split(""):a=t.toString().split($P));var o=a.map(c=>({word:c,width:fu(c,n).width})),u=r?0:fu(" ",n).width;return{wordsWithComputedWidth:o,spaceWidth:u}}catch{return null}};function FP(e){return e==="start"||e==="middle"||e==="end"||e==="inherit"}function _K(e){return Gt(e)||typeof e=="string"||typeof e=="number"||typeof e=="boolean"}var BP=(e,t,r,n)=>e.reduce((a,o)=>{var u=o.word,c=o.width,f=a[a.length-1];if(f&&c!=null&&(t==null||n||f.width+c+r<Number(t)))f.words.push(u),f.width+=c+r;else{var h={words:[u],width:c};a.push(h)}return a},[]),UP=e=>e.reduce((t,r)=>t.width>r.width?t:r),MK="…",XS=(e,t,r,n,a,o,u,c)=>{var f=e.slice(0,t),h=zP({breakAll:r,style:n,children:f+MK});if(!h)return[!1,[]];var m=BP(h.wordsWithComputedWidth,o,u,c),g=m.length>a||UP(m).width>Number(o);return[g,m]},IK=(e,t,r,n,a)=>{var o=e.maxLines,u=e.children,c=e.style,f=e.breakAll,h=Ee(o),m=String(u),g=BP(t,n,r,a);if(!h||a)return g;var v=g.length>o||UP(g).width>Number(n);if(!v)return g;for(var b=0,j=m.length-1,k=0,S;b<=j&&k<=m.length-1;){var N=Math.floor((b+j)/2),E=N-1,A=XS(m,E,f,c,o,n,r,a),P=QS(A,2),_=P[0],O=P[1],D=XS(m,N,f,c,o,n,r,a),B=QS(D,1),F=B[0];if(!_&&!F&&(b=N+1),_&&F&&(j=N-1),!_&&F){S=O;break}k++}return S||g},ZS=e=>{var t=Gt(e)?[]:e.toString().split($P);return[{words:t,width:void 0}]},TK=e=>{var t=e.width,r=e.scaleToFit,n=e.children,a=e.style,o=e.breakAll,u=e.maxLines;if((t||r)&&!Yu.isSsr){var c,f,h=zP({breakAll:o,children:n,style:a});if(h){var m=h.wordsWithComputedWidth,g=h.spaceWidth;c=m,f=g}else return ZS(n);return IK({breakAll:o,children:n,maxLines:u,style:a},c,f,t,!!r)}return ZS(n)},HP="#808080",DK={angle:0,breakAll:!1,capHeight:"0.71em",fill:HP,lineHeight:"1em",scaleToFit:!1,textAnchor:"start",verticalAnchor:"end",x:0,y:0},K0=y.forwardRef((e,t)=>{var r=Jr(e,DK),n=r.x,a=r.y,o=r.lineHeight,u=r.capHeight,c=r.fill,f=r.scaleToFit,h=r.textAnchor,m=r.verticalAnchor,g=qS(r,SK),v=y.useMemo(()=>TK({breakAll:g.breakAll,children:g.children,maxLines:g.maxLines,scaleToFit:f,style:g.style,width:g.width}),[g.breakAll,g.children,g.maxLines,f,g.style,g.width]),b=g.dx,j=g.dy,k=g.angle,S=g.className,N=g.breakAll,E=qS(g,NK);if(!Bn(n)||!Bn(a)||v.length===0)return null;var A=Number(n)+(Ee(b)?b:0),P=Number(a)+(Ee(j)?j:0);if(!He(A)||!He(P))return null;var _;switch(m){case"start":_=Pg("calc(".concat(u,")"));break;case"middle":_=Pg("calc(".concat((v.length-1)/2," * -").concat(o," + (").concat(u," / 2))"));break;default:_=Pg("calc(".concat(v.length-1," * -").concat(o,")"));break}var O=[],D=v[0];if(f&&D!=null){var B=D.width,F=g.width;O.push("scale(".concat(Ee(F)&&Ee(B)?F/B:1,")"))}return k&&O.push("rotate(".concat(k,", ").concat(A,", ").concat(P,")")),O.length&&(E.transform=O.join(" ")),y.createElement("text",Zv({},Yr(E),{ref:t,x:A,y:P,className:rt("recharts-text",S),textAnchor:h,fill:c.includes("url")?HP:c}),v.map((z,Y)=>{var U=z.words.join(N?"":" ");return y.createElement("tspan",{x:A,dy:Y===0?_:o,key:"".concat(U,"-").concat(Y)},U)}))});K0.displayName="Text";function JS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Pn(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?JS(Object(r),!0).forEach(function(n){RK(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):JS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function RK(e,t,r){return(t=LK(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function LK(e){var t=$K(e,"string");return typeof t=="symbol"?t:t+""}function $K(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zK=e=>{var t=e.viewBox,r=e.position,n=e.offset,a=n===void 0?0:n,o=e.parentViewBox,u=zy(t),c=u.x,f=u.y,h=u.height,m=u.upperWidth,g=u.lowerWidth,v=c,b=c+(m-g)/2,j=(v+b)/2,k=(m+g)/2,S=v+m/2,N=h>=0?1:-1,E=N*a,A=N>0?"end":"start",P=N>0?"start":"end",_=m>=0?1:-1,O=_*a,D=_>0?"end":"start",B=_>0?"start":"end",F=o;if(r==="top"){var z={x:v+m/2,y:f-E,horizontalAnchor:"middle",verticalAnchor:A};return F&&(z.height=Math.max(f-F.y,0),z.width=m),z}if(r==="bottom"){var Y={x:b+g/2,y:f+h+E,horizontalAnchor:"middle",verticalAnchor:P};return F&&(Y.height=Math.max(F.y+F.height-(f+h),0),Y.width=g),Y}if(r==="left"){var U={x:j-O,y:f+h/2,horizontalAnchor:D,verticalAnchor:"middle"};return F&&(U.width=Math.max(U.x-F.x,0),U.height=h),U}if(r==="right"){var he={x:j+k+O,y:f+h/2,horizontalAnchor:B,verticalAnchor:"middle"};return F&&(he.width=Math.max(F.x+F.width-he.x,0),he.height=h),he}var ue=F?{width:k,height:h}:{};return r==="insideLeft"?Pn({x:j+O,y:f+h/2,horizontalAnchor:B,verticalAnchor:"middle"},ue):r==="insideRight"?Pn({x:j+k-O,y:f+h/2,horizontalAnchor:D,verticalAnchor:"middle"},ue):r==="insideTop"?Pn({x:v+m/2,y:f+E,horizontalAnchor:"middle",verticalAnchor:P},ue):r==="insideBottom"?Pn({x:b+g/2,y:f+h-E,horizontalAnchor:"middle",verticalAnchor:A},ue):r==="insideTopLeft"?Pn({x:v+O,y:f+E,horizontalAnchor:B,verticalAnchor:P},ue):r==="insideTopRight"?Pn({x:v+m-O,y:f+E,horizontalAnchor:D,verticalAnchor:P},ue):r==="insideBottomLeft"?Pn({x:b+O,y:f+h-E,horizontalAnchor:B,verticalAnchor:A},ue):r==="insideBottomRight"?Pn({x:b+g-O,y:f+h-E,horizontalAnchor:D,verticalAnchor:A},ue):r&&typeof r=="object"&&(Ee(r.x)||uo(r.x))&&(Ee(r.y)||uo(r.y))?Pn({x:c+pa(r.x,k),y:f+pa(r.y,h),horizontalAnchor:"end",verticalAnchor:"end"},ue):Pn({x:S,y:f+h/2,horizontalAnchor:"middle",verticalAnchor:"middle"},ue)},FK=["labelRef"],BK=["content"];function e2(e,t){if(e==null)return{};var r,n,a=UK(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function UK(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function t2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function uu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?t2(Object(r),!0).forEach(function(n){HK(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):t2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function HK(e,t,r){return(t=WK(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function WK(e){var t=KK(e,"string");return typeof t=="symbol"?t:t+""}function KK(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function si(){return si=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},si.apply(null,arguments)}var WP=y.createContext(null),GK=e=>{var t=e.x,r=e.y,n=e.upperWidth,a=e.lowerWidth,o=e.width,u=e.height,c=e.children,f=y.useMemo(()=>({x:t,y:r,upperWidth:n,lowerWidth:a,width:o,height:u}),[t,r,n,a,o,u]);return y.createElement(WP.Provider,{value:f},c)},KP=()=>{var e=y.useContext(WP),t=Eh();return e||(t?zy(t):void 0)},VK=y.createContext(null),qK=()=>{var e=y.useContext(VK),t=Me(TA);return e||t},QK=e=>{var t=e.value,r=e.formatter,n=Gt(e.children)?t:e.children;return typeof r=="function"?r(n):n},G0=e=>e!=null&&typeof e=="function",YK=(e,t)=>{var r=Vr(t-e),n=Math.min(Math.abs(t-e),360);return r*n},XK=(e,t,r,n,a)=>{var o=e.offset,u=e.className,c=a.cx,f=a.cy,h=a.innerRadius,m=a.outerRadius,g=a.startAngle,v=a.endAngle,b=a.clockWise,j=(h+m)/2,k=YK(g,v),S=k>=0?1:-1,N,E;switch(t){case"insideStart":N=g+S*o,E=b;break;case"insideEnd":N=v-S*o,E=!b;break;case"end":N=v+S*o,E=b;break;default:throw new Error("Unsupported position ".concat(t))}E=k<=0?E:!E;var A=Kt(c,f,j,N),P=Kt(c,f,j,N+(E?1:-1)*359),_="M".concat(A.x,",").concat(A.y,`
|
||
A`).concat(j,",").concat(j,",0,1,").concat(E?0:1,`,
|
||
`).concat(P.x,",").concat(P.y),O=Gt(e.id)?bu("recharts-radial-line-"):e.id;return y.createElement("text",si({},n,{dominantBaseline:"central",className:rt("recharts-radial-bar-label",u)}),y.createElement("defs",null,y.createElement("path",{id:O,d:_})),y.createElement("textPath",{xlinkHref:"#".concat(O)},r))},ZK=(e,t,r)=>{var n=e.cx,a=e.cy,o=e.innerRadius,u=e.outerRadius,c=e.startAngle,f=e.endAngle,h=(c+f)/2;if(r==="outside"){var m=Kt(n,a,u+t,h),g=m.x,v=m.y;return{x:g,y:v,textAnchor:g>=n?"start":"end",verticalAnchor:"middle"}}if(r==="center")return{x:n,y:a,textAnchor:"middle",verticalAnchor:"middle"};if(r==="centerTop")return{x:n,y:a,textAnchor:"middle",verticalAnchor:"start"};if(r==="centerBottom")return{x:n,y:a,textAnchor:"middle",verticalAnchor:"end"};var b=(o+u)/2,j=Kt(n,a,b,h),k=j.x,S=j.y;return{x:k,y:S,textAnchor:"middle",verticalAnchor:"middle"}},qd=e=>e!=null&&"cx"in e&&Ee(e.cx),JK={angle:0,offset:5,zIndex:dr.label,position:"middle",textBreakAll:!1};function eG(e){if(!qd(e))return e;var t=e.cx,r=e.cy,n=e.outerRadius,a=n*2;return{x:t-n,y:r-n,width:a,upperWidth:a,lowerWidth:a,height:a}}function Zi(e){var t=Jr(e,JK),r=t.viewBox,n=t.parentViewBox,a=t.position,o=t.value,u=t.children,c=t.content,f=t.className,h=f===void 0?"":f,m=t.textBreakAll,g=t.labelRef,v=qK(),b=KP(),j=a==="center"?b:v??b,k,S,N;r==null?k=j:qd(r)?k=r:k=zy(r);var E=eG(k);if(!k||Gt(o)&&Gt(u)&&!y.isValidElement(c)&&typeof c!="function")return null;var A=uu(uu({},t),{},{viewBox:k});if(y.isValidElement(c)){A.labelRef;var P=e2(A,FK);return y.cloneElement(c,P)}if(typeof c=="function"){A.content;var _=e2(A,BK);if(S=y.createElement(c,_),y.isValidElement(S))return S}else S=QK(t);var O=Yr(t);if(qd(k)){if(a==="insideStart"||a==="insideEnd"||a==="end")return XK(t,a,S,O,k);N=ZK(k,t.offset,t.position)}else{if(!E)return null;var D=zK({viewBox:E,position:a,offset:t.offset,parentViewBox:qd(n)?void 0:n});N=uu(uu({x:D.x,y:D.y,textAnchor:D.horizontalAnchor,verticalAnchor:D.verticalAnchor},D.width!==void 0?{width:D.width}:{}),D.height!==void 0?{height:D.height}:{})}return y.createElement(Ni,{zIndex:t.zIndex},y.createElement(K0,si({ref:g,className:rt("recharts-label",h)},O,N,{textAnchor:FP(O.textAnchor)?O.textAnchor:N.textAnchor,breakAll:m}),S))}Zi.displayName="Label";var tG=(e,t,r)=>{if(!e)return null;var n={viewBox:t,labelRef:r};return e===!0?y.createElement(Zi,si({key:"label-implicit"},n)):Bn(e)?y.createElement(Zi,si({key:"label-implicit",value:e},n)):y.isValidElement(e)?e.type===Zi?y.cloneElement(e,uu({key:"label-implicit"},n)):y.createElement(Zi,si({key:"label-implicit",content:e},n)):G0(e)?y.createElement(Zi,si({key:"label-implicit",content:e},n)):e&&typeof e=="object"?y.createElement(Zi,si({},e,{key:"label-implicit"},n)):null};function rG(e){var t=e.label,r=e.labelRef,n=KP();return tG(t,n,r)||null}var nG=["valueAccessor"],iG=["dataKey","clockWise","id","textBreakAll","zIndex"];function Hf(){return Hf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Hf.apply(null,arguments)}function r2(e,t){if(e==null)return{};var r,n,a=aG(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function aG(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var oG=e=>{var t=Array.isArray(e.value)?e.value[e.value.length-1]:e.value;if(_K(t))return t},GP=y.createContext(void 0),sG=GP.Provider,VP=y.createContext(void 0);VP.Provider;function lG(){return y.useContext(GP)}function uG(){return y.useContext(VP)}function Qd(e){var t=e.valueAccessor,r=t===void 0?oG:t,n=r2(e,nG),a=n.dataKey;n.clockWise;var o=n.id,u=n.textBreakAll,c=n.zIndex,f=r2(n,iG),h=lG(),m=uG(),g=h||m;return!g||!g.length?null:y.createElement(Ni,{zIndex:c??dr.label},y.createElement(Xr,{className:"recharts-label-list"},g.map((v,b)=>{var j,k=Gt(a)?r(v,b):Dt(v.payload,a),S=Gt(o)?{}:{id:"".concat(o,"-").concat(b)};return y.createElement(Zi,Hf({key:"label-".concat(b)},Yr(v),f,S,{fill:(j=n.fill)!==null&&j!==void 0?j:v.fill,parentViewBox:v.parentViewBox,value:k,textBreakAll:u,viewBox:v.viewBox,index:b,zIndex:0}))})))}Qd.displayName="LabelList";function cG(e){var t=e.label;return t?t===!0?y.createElement(Qd,{key:"labelList-implicit"}):y.isValidElement(t)||G0(t)?y.createElement(Qd,{key:"labelList-implicit",content:t}):typeof t=="object"?y.createElement(Qd,Hf({key:"labelList-implicit"},t,{type:String(t.type)})):null:null}function Jv(){return Jv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Jv.apply(null,arguments)}var qP=e=>{var t=e.cx,r=e.cy,n=e.r,a=e.className,o=rt("recharts-dot",a);return Ee(t)&&Ee(r)&&Ee(n)?y.createElement("circle",Jv({},vn(e),Py(e),{className:o,cx:t,cy:r,r:n})):null},dG={radiusAxis:{},angleAxis:{}},QP=sr({name:"polarAxis",initialState:dG,reducers:{addRadiusAxis(e,t){e.radiusAxis[t.payload.id]=t.payload},removeRadiusAxis(e,t){delete e.radiusAxis[t.payload.id]},addAngleAxis(e,t){e.angleAxis[t.payload.id]=t.payload},removeAngleAxis(e,t){delete e.angleAxis[t.payload.id]}}}),Qh=QP.actions;Qh.addRadiusAxis;Qh.removeRadiusAxis;Qh.addAngleAxis;Qh.removeAngleAxis;var fG=QP.reducer;function hG(e){return e&&typeof e=="object"&&"className"in e&&typeof e.className=="string"?e.className:""}var YP=e=>e&&typeof e=="object"&&"clipDot"in e?!!e.clipDot:!0;function n2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function i2(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?n2(Object(r),!0).forEach(function(n){mG(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function mG(e,t,r){return(t=pG(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function pG(e){var t=gG(e,"string");return typeof t=="symbol"?t:t+""}function gG(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function XP(e,t){return i2(i2({},t),e)}function vG(e){return y.isValidElement(e)?e.props:e}function yG(e,t){return y.cloneElement(e,XP(vG(e),t))}function xG(e){if("index"in e){var t=e.index;return typeof t=="number"||typeof t=="string"?t:void 0}}function bG(e){return"isActive"in e&&e.isActive===!0}function wG(e){var t=e.option,r=e.DefaultShape,n=e.shapeProps,a=e.activeClassName,o=a===void 0?"recharts-active-shape":a,u=e.inActiveClassName,c=u===void 0?"recharts-shape":u,f=xG(n),h;return y.isValidElement(t)?h=yG(t,n):t===r?h=y.createElement(r,n):typeof t=="function"?h=t(n,f):typeof t=="object"?h=y.createElement(r,XP(t,n)):h=y.createElement(r,n),bG(n)?y.createElement(Xr,{className:o},h):y.createElement(Xr,{className:c},h)}function kG(e){var t=e.tooltipEntrySettings,r=jt(),n=Nr(),a=y.useRef(null);return y.useLayoutEffect(()=>{n||(a.current===null?r(MU(t)):a.current!==t&&r(IU({prev:a.current,next:t})),a.current=t)},[t,r,n]),y.useLayoutEffect(()=>()=>{a.current&&(r(TU(a.current)),a.current=null)},[r]),null}function jG(e){var t=e.legendPayload,r=jt(),n=Nr(),a=y.useRef(null);return y.useLayoutEffect(()=>{n||(a.current===null?r(o6(t)):a.current!==t&&r(s6({prev:a.current,next:t})),a.current=t)},[r,n,t]),y.useLayoutEffect(()=>()=>{a.current&&(r(l6(a.current)),a.current=null)},[r]),null}function SG(e,t){return CG(e)||AG(e,t)||EG(e,t)||NG()}function NG(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function EG(e,t){if(e){if(typeof e=="string")return a2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?a2(e,t):void 0}}function a2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function AG(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function CG(e){if(Array.isArray(e))return e}var V0="index",PG="append";function q0(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],n=[];for(var a of r)n.push({status:"removed",prev:a});for(var o=0;o<t.length;o++){var u=e[o],c=t[o];u!=null?n.push({status:"matched",prev:u,next:c}):n.push({status:"added",next:c})}return n}function OG(e,t){var r=e.length/t.length,n=t.map((a,o)=>e[Math.floor(o*r)]);return q0(n,t)}function _G(e,t){var r=t.map((n,a)=>e[a]);return q0(r,t)}function MG(e,t){for(var r=new Map,n=0;n<e.length;n++){var a=e[n];if(a!=null){var o=t(a,n);o!=null&&!r.has(o)&&r.set(o,a)}}return r}function IG(e,t,r){var n=MG(e,r),a=new Set,o=t.map((g,v)=>{var b=r(g,v);if(b!=null){var j=n.get(b);if(j!==void 0)return a.add(b),j}}),u=[];for(var c of n){var f=SG(c,2),h=f[0],m=f[1];a.has(h)||u.push(m)}return q0(o,t,u)}function ey(e,t,r){return t==null?null:e==null?t.map(n=>({status:"added",next:n})):r===V0?OG(e,t):r===PG?_G(e,t):IG(e,t,r)}function ZP(e,t){var r=y.useRef(e),n=y.useRef(t.current),a=y.useRef(!0);r.current!==e&&(r.current=e,n.current=t.current,a.current=!1);var o=y.useCallback(function(u,c){var f=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(c===0){a.current=!0;return}c===1&&(n.current=u),c>0&&a.current&&f&&(t.current=u)},[t]);return{startValue:n.current,syncStepValue:o}}function TG(e,t){return $G(e)||LG(e,t)||RG(e,t)||DG()}function DG(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function RG(e,t){if(e){if(typeof e=="string")return o2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o2(e,t):void 0}}function o2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function LG(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function $G(e){if(Array.isArray(e))return e}function zG(e,t){var r=y.useState(!1),n=TG(r,2),a=n[0],o=n[1],u=y.useCallback(()=>{typeof e=="function"&&e(),o(!0)},[e]),c=y.useCallback(()=>{typeof t=="function"&&t(),o(!1)},[t]);return{isAnimating:a,handleAnimationStart:u,handleAnimationEnd:c}}function FG(e){var t,r=e.animationInput,n=e.animationIdPrefix,a=e.items,o=e.previousItemsRef,u=e.isAnimationActive,c=e.animationBegin,f=e.animationDuration,h=e.animationEasing,m=e.onAnimationStart,g=e.onAnimationEnd,v=e.animationInterpolateFn,b=e.animationMatchBy,j=e.shouldUpdatePreviousRef,k=e.children,S=e.layout,N=hA(r,n),E=ZP(N,o),A=(t=E.startValue)!==null&&t!==void 0?t:null,P=ey(A,a,b??V0);return y.createElement(fA,{animationId:N,begin:c,duration:f,isActive:u,easing:h,onAnimationEnd:g,onAnimationStart:m,key:N},_=>{var O=A==null,D=a==null?a:v(P,_,S),B=j?j(_):_>0;return E.syncStepValue(D,_,B),D==null?null:k(D,_,O)})}var Og;function BG(e,t){return KG(e)||WG(e,t)||HG(e,t)||UG()}function UG(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function HG(e,t){if(e){if(typeof e=="string")return s2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?s2(e,t):void 0}}function s2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function WG(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function KG(e){if(Array.isArray(e))return e}var GG=()=>{var e=y.useState(()=>bu("uid-")),t=BG(e,1),r=t[0];return r},JP=(Og=Xf.useId)!==null&&Og!==void 0?Og:GG;function VG(e,t){var r=JP();return t||(e?"".concat(e,"-").concat(r):r)}var qG=y.createContext(void 0),QG=e=>{var t=e.id,r=e.type,n=e.children,a=VG("recharts-".concat(r),t);return y.createElement(qG.Provider,{value:a},n(a))},YG={cartesianItems:[],polarItems:[]},eO=sr({name:"graphicalItems",initialState:YG,reducers:{addCartesianGraphicalItem:{reducer(e,t){e.cartesianItems.push(t.payload)},prepare:ot()},replaceCartesianGraphicalItem:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next,o=qr(e).cartesianItems.indexOf(n);o>-1&&(e.cartesianItems[o]=a)},prepare:ot()},removeCartesianGraphicalItem:{reducer(e,t){var r=qr(e).cartesianItems.indexOf(t.payload);r>-1&&e.cartesianItems.splice(r,1)},prepare:ot()},addPolarGraphicalItem:{reducer(e,t){e.polarItems.push(t.payload)},prepare:ot()},removePolarGraphicalItem:{reducer(e,t){var r=qr(e).polarItems.indexOf(t.payload);r>-1&&e.polarItems.splice(r,1)},prepare:ot()},replacePolarGraphicalItem:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next,o=qr(e).polarItems.indexOf(n);o>-1&&(e.polarItems[o]=a)},prepare:ot()}}}),nl=eO.actions,XG=nl.addCartesianGraphicalItem,ZG=nl.replaceCartesianGraphicalItem,JG=nl.removeCartesianGraphicalItem;nl.addPolarGraphicalItem;nl.removePolarGraphicalItem;nl.replacePolarGraphicalItem;var eV=eO.reducer,tV=e=>{var t=jt(),r=y.useRef(null);return y.useLayoutEffect(()=>{r.current===null?t(XG(e)):r.current!==e&&t(ZG({prev:r.current,next:e})),r.current=e},[t,e]),y.useLayoutEffect(()=>()=>{r.current&&(t(JG(r.current)),r.current=null)},[t]),null},rV=y.memo(tV),nV=["points"];function l2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function _g(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?l2(Object(r),!0).forEach(function(n){iV(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function iV(e,t,r){return(t=aV(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function aV(e){var t=oV(e,"string");return typeof t=="symbol"?t:t+""}function oV(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Wf(){return Wf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Wf.apply(null,arguments)}function sV(e,t){if(e==null)return{};var r,n,a=lV(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function lV(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function uV(e){var t=e.option,r=e.dotProps,n=e.className;if(y.isValidElement(t))return y.cloneElement(t,r);if(typeof t=="function")return t(r);var a=rt(n,typeof t!="boolean"?t.className:""),o=r??{};o.points;var u=sV(o,nV);return y.createElement(qP,Wf({},u,{className:a}))}function cV(e,t){return e==null?!1:t?!0:e.length===1}function dV(e){var t=e.points,r=e.dot,n=e.className,a=e.dotClassName,o=e.dataKey,u=e.baseProps,c=e.needClip,f=e.clipPathId,h=e.zIndex,m=h===void 0?dr.scatter:h;if(!cV(t,r))return null;var g=YP(r),v=GD(r),b=t.map((k,S)=>{var N,E,A=_g(_g(_g({r:3},u),v),{},{index:S,cx:(N=k.x)!==null&&N!==void 0?N:void 0,cy:(E=k.y)!==null&&E!==void 0?E:void 0,dataKey:o,value:k.value,payload:k.payload,points:t});return y.createElement(uV,{key:"dot-".concat(S),option:r,dotProps:A,className:a})}),j={};return c&&f!=null&&(j.clipPath="url(#clipPath-".concat(g?"":"dots-").concat(f,")")),y.createElement(Ni,{zIndex:m},y.createElement(Xr,Wf({className:n},j),b))}function u2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function c2(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?u2(Object(r),!0).forEach(function(n){fV(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):u2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function fV(e,t,r){return(t=hV(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hV(e){var t=mV(e,"string");return typeof t=="symbol"?t:t+""}function mV(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var tO=0,pV={xAxis:{},yAxis:{},zAxis:{}},rO=sr({name:"cartesianAxis",initialState:pV,reducers:{addXAxis:{reducer(e,t){e.xAxis[t.payload.id]=t.payload},prepare:ot()},replaceXAxis:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next;e.xAxis[n.id]!==void 0&&(n.id!==a.id&&delete e.xAxis[n.id],e.xAxis[a.id]=a)},prepare:ot()},removeXAxis:{reducer(e,t){delete e.xAxis[t.payload.id]},prepare:ot()},addYAxis:{reducer(e,t){e.yAxis[t.payload.id]=t.payload},prepare:ot()},replaceYAxis:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next;e.yAxis[n.id]!==void 0&&(n.id!==a.id&&delete e.yAxis[n.id],e.yAxis[a.id]=a)},prepare:ot()},removeYAxis:{reducer(e,t){delete e.yAxis[t.payload.id]},prepare:ot()},addZAxis:{reducer(e,t){e.zAxis[t.payload.id]=t.payload},prepare:ot()},replaceZAxis:{reducer(e,t){var r=t.payload,n=r.prev,a=r.next;e.zAxis[n.id]!==void 0&&(n.id!==a.id&&delete e.zAxis[n.id],e.zAxis[a.id]=a)},prepare:ot()},removeZAxis:{reducer(e,t){delete e.zAxis[t.payload.id]},prepare:ot()},updateYAxisWidth(e,t){var r=t.payload,n=r.id,a=r.width,o=e.yAxis[n];if(o){var u,c=o.widthHistory||[];if(c.length===3&&c[0]===c[2]&&a===c[1]&&a!==o.width&&Math.abs(a-((u=c[0])!==null&&u!==void 0?u:0))<=1)return;var f=[...c,a].slice(-3);e.yAxis[n]=c2(c2({},o),{},{width:a,widthHistory:f})}}}}),Vn=rO.actions,gV=Vn.addXAxis,vV=Vn.replaceXAxis,yV=Vn.removeXAxis,xV=Vn.addYAxis,bV=Vn.replaceYAxis,wV=Vn.removeYAxis;Vn.addZAxis;Vn.replaceZAxis;Vn.removeZAxis;var kV=Vn.updateYAxisWidth,jV=rO.reducer,SV=q([Qt],e=>({top:e.top,bottom:e.bottom,left:e.left,right:e.right})),NV=q([SV,xi,bi],(e,t,r)=>{if(!(!e||t==null||r==null))return{x:e.left,y:e.top,width:Math.max(0,t-e.left-e.right),height:Math.max(0,r-e.top-e.bottom)}}),Q0=()=>Me(NV),EV=()=>Me(MH);function d2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Mg(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?d2(Object(r),!0).forEach(function(n){AV(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):d2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function AV(e,t,r){return(t=CV(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function CV(e){var t=PV(e,"string");return typeof t=="symbol"?t:t+""}function PV(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var OV=e=>{var t=e.point,r=e.childIndex,n=e.mainColor,a=e.activeDot,o=e.dataKey,u=e.clipPath;if(a===!1||t.x==null||t.y==null)return null;var c={index:r,dataKey:o,cx:t.x,cy:t.y,r:4,fill:n??"none",strokeWidth:2,stroke:"#fff",payload:t.payload,value:t.value},f=Mg(Mg(Mg({},c),lh(a)),Py(a)),h;return y.isValidElement(a)?h=y.cloneElement(a,f):typeof a=="function"?h=a(f):h=y.createElement(qP,f),y.createElement(Xr,{className:"recharts-active-dot",clipPath:u},h)};function f2(e){var t=e.points,r=e.mainColor,n=e.activeDot,a=e.itemDataKey,o=e.clipPath,u=e.zIndex,c=u===void 0?dr.activeDot:u,f=Me(Iu),h=EV();if(t==null||h==null)return null;var m=t.find(g=>h.includes(g.payload));return Gt(m)?null:y.createElement(Ni,{zIndex:c},y.createElement(OV,{point:m,childIndex:Number(f),mainColor:r,dataKey:a,activeDot:n,clipPath:o}))}var _V=e=>{var t=e.chartData,r=jt(),n=Nr();return y.useEffect(()=>n?()=>{}:(r(TS(t)),()=>{r(TS(void 0))}),[t,r,n]),null},h2={x:0,y:0,width:0,height:0,padding:{top:0,right:0,bottom:0,left:0}},nO=sr({name:"brush",initialState:h2,reducers:{setBrushSettings(e,t){return t.payload==null?h2:t.payload}}});nO.actions.setBrushSettings;var MV=nO.reducer;function IV(e){return(e%180+180)%180}var TV=function(t){var r=t.width,n=t.height,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=IV(a),u=o*Math.PI/180,c=Math.atan(n/r),f=u>c&&u<Math.PI-c?n/Math.sin(u):r/Math.cos(u);return Math.abs(f)},DV={dots:[],areas:[],lines:[]},iO=sr({name:"referenceElements",initialState:DV,reducers:{addDot:(e,t)=>{e.dots.push(t.payload)},removeDot:(e,t)=>{var r=qr(e).dots.findIndex(n=>n===t.payload);r!==-1&&e.dots.splice(r,1)},addArea:(e,t)=>{e.areas.push(t.payload)},removeArea:(e,t)=>{var r=qr(e).areas.findIndex(n=>n===t.payload);r!==-1&&e.areas.splice(r,1)},addLine:(e,t)=>{e.lines.push(t.payload)},removeLine:(e,t)=>{var r=qr(e).lines.findIndex(n=>n===t.payload);r!==-1&&e.lines.splice(r,1)}}}),il=iO.actions;il.addDot;il.removeDot;il.addArea;il.removeArea;il.addLine;il.removeLine;var RV=iO.reducer;function LV(e,t){return BV(e)||FV(e,t)||zV(e,t)||$V()}function $V(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zV(e,t){if(e){if(typeof e=="string")return m2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?m2(e,t):void 0}}function m2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function FV(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function BV(e){if(Array.isArray(e))return e}var UV=y.createContext(void 0),HV=e=>{var t=e.children,r=y.useState("".concat(bu("recharts"),"-clip")),n=LV(r,1),a=n[0],o=Q0();if(o==null)return null;var u=o.x,c=o.y,f=o.width,h=o.height;return y.createElement(UV.Provider,{value:a},y.createElement("defs",null,y.createElement("clipPath",{id:a},y.createElement("rect",{x:u,y:c,height:h,width:f}))),t)};function aO(e,t){if(t<1)return[];if(t===1)return e;for(var r=[],n=0;n<e.length;n+=t){var a=e[n];a!==void 0&&r.push(a)}return r}function WV(e,t,r){var n={width:e.width+t.width,height:e.height+t.height};return TV(n,r)}function KV(e,t,r){var n=r==="width",a=e.x,o=e.y,u=e.width,c=e.height;return t===1?{start:n?a:o,end:n?a+u:o+c}:{start:n?a+u:o+c,end:n?a:o}}function Du(e,t,r,n,a){if(e*t<e*n||e*t>e*a)return!1;var o=r();return e*(t-e*o/2-n)>=0&&e*(t+e*o/2-a)<=0}function GV(e,t){return aO(e,t+1)}function VV(e,t,r,n,a){for(var o=(n||[]).slice(),u=t.start,c=t.end,f=0,h=1,m=u,g=function(){var j=n==null?void 0:n[f];if(j===void 0)return{v:aO(n,h)};var k=f,S,N=()=>(S===void 0&&(S=r(j,k)),S),E=j.coordinate,A=f===0||Du(e,E,N,m,c);A||(f=0,m=u,h+=1),A&&(m=E+e*(N()/2+a),f+=h)},v;h<=o.length;)if(v=g(),v)return v.v;return[]}function qV(e,t,r,n,a){var o=(n||[]).slice(),u=o.length;if(u===0)return[];for(var c=t.start,f=t.end,h=1;h<=u;h++){for(var m=(u-1)%h,g=c,v=!0,b=function(){var P=n[k];if(P==null)return 0;var _=k,O,D=()=>(O===void 0&&(O=r(P,_)),O),B=P.coordinate,F=k===m||Du(e,B,D,g,f);if(!F)return v=!1,1;F&&(g=B+e*(D()/2+a))},j,k=m;k<u&&(j=b(),!(j!==0&&j===1));k+=h);if(v){for(var S=[],N=m;N<u;N+=h){var E=n[N];E!=null&&S.push(E)}return S}}return[]}function p2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function nr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?p2(Object(r),!0).forEach(function(n){QV(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function QV(e,t,r){return(t=YV(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function YV(e){var t=XV(e,"string");return typeof t=="symbol"?t:t+""}function XV(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ZV(e,t,r,n,a){for(var o=(n||[]).slice(),u=o.length,c=t.start,f=t.end,h=function(v){var b=o[v];if(b==null)return 1;var j=b,k,S=()=>(k===void 0&&(k=r(b,v)),k);if(v===u-1){var N=e*(j.coordinate+e*S()/2-f);o[v]=j=nr(nr({},j),{},{tickCoord:N>0?j.coordinate-N*e:j.coordinate})}else o[v]=j=nr(nr({},j),{},{tickCoord:j.coordinate});if(j.tickCoord!=null){var E=Du(e,j.tickCoord,S,c,f);E&&(f=j.tickCoord-e*(S()/2+a),o[v]=nr(nr({},j),{},{isShow:!0}))}},m=u-1;m>=0;m--)h(m);return o}function JV(e,t,r,n,a,o){var u=(n||[]).slice(),c=u.length,f=t.start,h=t.end;if(o){var m=n[c-1];if(m!=null){var g=r(m,c-1),v=e*(m.coordinate+e*g/2-h);if(u[c-1]=m=nr(nr({},m),{},{tickCoord:v>0?m.coordinate-v*e:m.coordinate}),m.tickCoord!=null){var b=Du(e,m.tickCoord,()=>g,f,h);b&&(h=m.tickCoord-e*(g/2+a),u[c-1]=nr(nr({},m),{},{isShow:!0}))}}}for(var j=o?c-1:c,k=function(E){var A=u[E];if(A==null)return 1;var P=A,_,O=()=>(_===void 0&&(_=r(A,E)),_);if(E===0){var D=e*(P.coordinate-e*O()/2-f);u[E]=P=nr(nr({},P),{},{tickCoord:D<0?P.coordinate-D*e:P.coordinate})}else u[E]=P=nr(nr({},P),{},{tickCoord:P.coordinate});if(P.tickCoord!=null){var B=Du(e,P.tickCoord,O,f,h);B&&(f=P.tickCoord+e*(O()/2+a),u[E]=nr(nr({},P),{},{isShow:!0}))}},S=0;S<j;S++)k(S);return u}function Y0(e,t,r){var n=e.tick,a=e.ticks,o=e.viewBox,u=e.minTickGap,c=e.orientation,f=e.interval,h=e.tickFormatter,m=e.unit,g=e.angle;if(!a||!a.length||!n)return[];if(Ee(f)||Yu.isSsr){var v;return(v=GV(a,Ee(f)?f:0))!==null&&v!==void 0?v:[]}var b=[],j=c==="top"||c==="bottom"?"width":"height",k=m&&j==="width"?fu(m,{fontSize:t,letterSpacing:r}):{width:0,height:0},S=(_,O)=>{var D=typeof h=="function"?h(_.value,O):_.value;return j==="width"?WV(fu(D,{fontSize:t,letterSpacing:r}),k,g):fu(D,{fontSize:t,letterSpacing:r})[j]},N=a[0],E=a[1],A=a.length>=2&&N!=null&&E!=null?Vr(E.coordinate-N.coordinate):1,P=KV(o,A,j);return f==="equidistantPreserveStart"?VV(A,P,S,a,u):f==="equidistantPreserveEnd"?qV(A,P,S,a,u):(f==="preserveStart"||f==="preserveStartEnd"?b=JV(A,P,S,a,u,f==="preserveStartEnd"):b=ZV(A,P,S,a,u),b.filter(_=>_.isShow))}var eq=e=>{var t=e.ticks,r=e.label,n=e.labelGapWithTick,a=n,o=e.tickSize,u=o===void 0?0:o,c=e.tickMargin,f=c===void 0?0:c,h=0;if(t){Array.from(t).forEach(b=>{if(b){var j=b.getBoundingClientRect();j.width>h&&(h=j.width)}});var m=r?r.getBoundingClientRect().width:0,g=u+f,v=h+g+m+(r?a:0);return Math.round(v)}return 0},tq={xAxis:{},yAxis:{}},oO=sr({name:"renderedTicks",initialState:tq,reducers:{setRenderedTicks:(e,t)=>{var r=t.payload,n=r.axisType,a=r.axisId,o=r.ticks;e[n][a]=o},removeRenderedTicks:(e,t)=>{var r=t.payload,n=r.axisType,a=r.axisId;delete e[n][a]}}}),sO=oO.actions,rq=sO.setRenderedTicks,nq=sO.removeRenderedTicks,iq=oO.reducer,aq=["axisLine","width","height","className","hide","ticks","axisType","axisId"];function g2(e,t){return uq(e)||lq(e,t)||sq(e,t)||oq()}function oq(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function sq(e,t){if(e){if(typeof e=="string")return v2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?v2(e,t):void 0}}function v2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function lq(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function uq(e){if(Array.isArray(e))return e}function cq(e,t){if(e==null)return{};var r,n,a=dq(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function dq(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function go(){return go=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},go.apply(null,arguments)}function y2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function gt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?y2(Object(r),!0).forEach(function(n){fq(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):y2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function fq(e,t,r){return(t=hq(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hq(e){var t=mq(e,"string");return typeof t=="symbol"?t:t+""}function mq(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var hi={x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd",zIndex:dr.axis};function pq(e){var t=e.x,r=e.y,n=e.width,a=e.height,o=e.orientation,u=e.mirror,c=e.axisLine,f=e.otherSvgProps;if(!c)return null;var h=gt(gt(gt({},f),vn(c)),{},{fill:"none"});if(o==="top"||o==="bottom"){var m=+(o==="top"&&!u||o==="bottom"&&u);h=gt(gt({},h),{},{x1:t,y1:r+m*a,x2:t+n,y2:r+m*a})}else{var g=+(o==="left"&&!u||o==="right"&&u);h=gt(gt({},h),{},{x1:t+g*n,y1:r,x2:t+g*n,y2:r+a})}return y.createElement("line",go({},h,{className:rt("recharts-cartesian-axis-line",bo(c,"className"))}))}function gq(e,t,r,n,a,o,u,c,f){var h,m,g,v,b,j,k=c?-1:1,S=e.tickSize||u,N=Ee(e.tickCoord)?e.tickCoord:e.coordinate;switch(o){case"top":h=m=e.coordinate,v=r+ +!c*a,g=v-k*S,j=g-k*f,b=N;break;case"left":g=v=e.coordinate,m=t+ +!c*n,h=m-k*S,b=h-k*f,j=N;break;case"right":g=v=e.coordinate,m=t+ +c*n,h=m+k*S,b=h+k*f,j=N;break;default:h=m=e.coordinate,v=r+ +c*a,g=v+k*S,j=g+k*f,b=N;break}return{line:{x1:h,y1:g,x2:m,y2:v},tick:{x:b,y:j}}}function vq(e,t){switch(e){case"left":return t?"start":"end";case"right":return t?"end":"start";default:return"middle"}}function yq(e,t){switch(e){case"left":case"right":return"middle";case"top":return t?"start":"end";default:return t?"end":"start"}}function xq(e){var t=e.option,r=e.tickProps,n=e.value,a,o=rt(r.className,"recharts-cartesian-axis-tick-value");if(y.isValidElement(t))a=y.cloneElement(t,gt(gt({},r),{},{className:o}));else if(typeof t=="function")a=t(gt(gt({},r),{},{className:o}));else{var u="recharts-cartesian-axis-tick-value";typeof t!="boolean"&&(u=rt(u,hG(t))),a=y.createElement(K0,go({},r,{className:u}),n)}return a}function bq(e){var t=e.ticks,r=e.axisType,n=e.axisId,a=jt();return y.useEffect(()=>{if(n==null||r==null)return Vs;var o=t.map(u=>({value:u.value,coordinate:u.coordinate,offset:u.offset,index:u.index}));return a(rq({ticks:o,axisId:n,axisType:r})),()=>{a(nq({axisId:n,axisType:r}))}},[a,t,n,r]),null}var wq=y.forwardRef((e,t)=>{var r=e.ticks,n=r===void 0?[]:r,a=e.tick,o=e.tickLine,u=e.stroke,c=e.tickFormatter,f=e.unit,h=e.padding,m=e.tickTextProps,g=e.orientation,v=e.mirror,b=e.x,j=e.y,k=e.width,S=e.height,N=e.tickSize,E=e.tickMargin,A=e.fontSize,P=e.letterSpacing,_=e.getTicksConfig,O=e.events,D=e.axisType,B=e.axisId,F=Y0(gt(gt({},_),{},{ticks:n}),A,P),z=vn(_),Y=lh(a),U=FP(z.textAnchor)?z.textAnchor:vq(g,v),he=yq(g,v),ue={};typeof o=="object"&&(ue=o);var ge=gt(gt({},z),{},{fill:"none"},ue),ie=F.map(te=>gt({entry:te},gq(te,b,j,k,S,g,N,v,E))),se=ie.map(te=>{var J=te.entry,I=te.line;return y.createElement(Xr,{className:"recharts-cartesian-axis-tick",key:"tick-".concat(J.value,"-").concat(J.coordinate,"-").concat(J.tickCoord)},o&&y.createElement("line",go({},ge,I,{className:rt("recharts-cartesian-axis-tick-line",bo(o,"className"))})))}),X=ie.map((te,J)=>{var I,M,H=te.entry,ne=te.tick,Z=gt(gt(gt(gt({verticalAnchor:he},z),{},{textAnchor:U,stroke:"none",fill:u},ne),{},{index:J,payload:H,visibleTicksCount:F.length,tickFormatter:c,padding:h},m),{},{angle:(I=(M=m==null?void 0:m.angle)!==null&&M!==void 0?M:z.angle)!==null&&I!==void 0?I:0}),me=gt(gt({},Z),Y);return y.createElement(Xr,go({className:"recharts-cartesian-axis-tick-label",key:"tick-label-".concat(H.value,"-").concat(H.coordinate,"-").concat(H.tickCoord)},NR(O,H,J)),a&&y.createElement(xq,{option:a,tickProps:me,value:"".concat(typeof c=="function"?c(H.value,J):H.value).concat(f||"")}))});return y.createElement("g",{className:"recharts-cartesian-axis-ticks recharts-".concat(D,"-ticks")},y.createElement(bq,{ticks:F,axisId:B,axisType:D}),X.length>0&&y.createElement(Ni,{zIndex:dr.label},y.createElement("g",{className:"recharts-cartesian-axis-tick-labels recharts-".concat(D,"-tick-labels"),ref:t},X)),se.length>0&&y.createElement("g",{className:"recharts-cartesian-axis-tick-lines recharts-".concat(D,"-tick-lines")},se))}),kq=y.forwardRef((e,t)=>{var r=e.axisLine,n=e.width,a=e.height,o=e.className,u=e.hide,c=e.ticks,f=e.axisType,h=e.axisId,m=cq(e,aq),g=y.useState(""),v=g2(g,2),b=v[0],j=v[1],k=y.useState(""),S=g2(k,2),N=S[0],E=S[1],A=y.useRef(null);y.useImperativeHandle(t,()=>({getCalculatedWidth:()=>{var _;return eq({ticks:A.current,label:(_=e.labelRef)===null||_===void 0?void 0:_.current,labelGapWithTick:5,tickSize:e.tickSize,tickMargin:e.tickMargin})}}));var P=y.useCallback(_=>{if(_){var O=_.getElementsByClassName("recharts-cartesian-axis-tick-value");A.current=O;var D=O[0];if(D){var B=window.getComputedStyle(D),F=B.fontSize,z=B.letterSpacing;(F!==b||z!==N)&&(j(F),E(z))}}},[b,N]);return u||n!=null&&n<=0||a!=null&&a<=0?null:y.createElement(Ni,{zIndex:e.zIndex},y.createElement(Xr,{className:rt("recharts-cartesian-axis",o)},y.createElement(pq,{x:e.x,y:e.y,width:n,height:a,orientation:e.orientation,mirror:e.mirror,axisLine:r,otherSvgProps:vn(e)}),y.createElement(wq,{ref:P,axisType:f,events:m,fontSize:b,getTicksConfig:e,height:e.height,letterSpacing:N,mirror:e.mirror,orientation:e.orientation,padding:e.padding,stroke:e.stroke,tick:e.tick,tickFormatter:e.tickFormatter,tickLine:e.tickLine,tickMargin:e.tickMargin,tickSize:e.tickSize,tickTextProps:e.tickTextProps,ticks:c,unit:e.unit,width:e.width,x:e.x,y:e.y,axisId:h}),y.createElement(GK,{x:e.x,y:e.y,width:e.width,height:e.height,lowerWidth:e.width,upperWidth:e.width},y.createElement(rG,{label:e.label,labelRef:e.labelRef}),e.children)))}),X0=y.forwardRef((e,t)=>{var r=Jr(e,hi);return y.createElement(kq,go({},r,{ref:t}))});X0.displayName="CartesianAxis";var jq=["x1","y1","x2","y2","key"],Sq=["offset"],Nq=["xAxisId","yAxisId"],Eq=["xAxisId","yAxisId"];function x2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ar(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?x2(Object(r),!0).forEach(function(n){Aq(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):x2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Aq(e,t,r){return(t=Cq(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Cq(e){var t=Pq(e,"string");return typeof t=="symbol"?t:t+""}function Pq(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ga(){return Ga=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ga.apply(null,arguments)}function Kf(e,t){if(e==null)return{};var r,n,a=Oq(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function Oq(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var _q=e=>{var t=e.fill;if(!t||t==="none")return null;var r=e.fillOpacity,n=e.x,a=e.y,o=e.width,u=e.height,c=e.ry;return y.createElement("rect",{x:n,y:a,ry:c,width:o,height:u,stroke:"none",fill:t,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function lO(e){var t=e.option,r=e.lineItemProps,n;if(y.isValidElement(t))n=y.cloneElement(t,r);else if(typeof t=="function")n=t(r);else{var a,o=r.x1,u=r.y1,c=r.x2,f=r.y2,h=r.key,m=Kf(r,jq),g=(a=vn(m))!==null&&a!==void 0?a:{};g.offset;var v=Kf(g,Sq);n=y.createElement("line",Ga({},v,{x1:o,y1:u,x2:c,y2:f,fill:"none",key:h}))}return n}function Mq(e){var t=e.x,r=e.width,n=e.horizontal,a=n===void 0?!0:n,o=e.horizontalPoints;if(!a||!o||!o.length)return null;e.xAxisId,e.yAxisId;var u=Kf(e,Nq),c=o.map((f,h)=>{var m=ar(ar({},u),{},{x1:t,y1:f,x2:t+r,y2:f,key:"line-".concat(h),index:h});return y.createElement(lO,{key:"line-".concat(h),option:a,lineItemProps:m})});return y.createElement("g",{className:"recharts-cartesian-grid-horizontal"},c)}function Iq(e){var t=e.y,r=e.height,n=e.vertical,a=n===void 0?!0:n,o=e.verticalPoints;if(!a||!o||!o.length)return null;e.xAxisId,e.yAxisId;var u=Kf(e,Eq),c=o.map((f,h)=>{var m=ar(ar({},u),{},{x1:f,y1:t,x2:f,y2:t+r,key:"line-".concat(h),index:h});return y.createElement(lO,{option:a,lineItemProps:m,key:"line-".concat(h)})});return y.createElement("g",{className:"recharts-cartesian-grid-vertical"},c)}function Tq(e){var t=e.horizontalFill,r=e.fillOpacity,n=e.x,a=e.y,o=e.width,u=e.height,c=e.horizontalPoints,f=e.horizontal,h=f===void 0?!0:f;if(!h||!t||!t.length||c==null)return null;var m=c.map(v=>Math.round(v+a-a)).sort((v,b)=>v-b);a!==m[0]&&m.unshift(0);var g=m.map((v,b)=>{var j=m[b+1],k=j==null,S=k?a+u-v:j-v;if(S<=0)return null;var N=b%t.length;return y.createElement("rect",{key:"react-".concat(b),y:v,x:n,height:S,width:o,stroke:"none",fill:t[N],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return y.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},g)}function Dq(e){var t=e.vertical,r=t===void 0?!0:t,n=e.verticalFill,a=e.fillOpacity,o=e.x,u=e.y,c=e.width,f=e.height,h=e.verticalPoints;if(!r||!n||!n.length)return null;var m=h.map(v=>Math.round(v+o-o)).sort((v,b)=>v-b);o!==m[0]&&m.unshift(0);var g=m.map((v,b)=>{var j=m[b+1],k=j==null,S=k?o+c-v:j-v;if(S<=0)return null;var N=b%n.length;return y.createElement("rect",{key:"react-".concat(b),x:v,y:u,width:S,height:f,stroke:"none",fill:n[N],fillOpacity:a,className:"recharts-cartesian-grid-bg"})});return y.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},g)}var Rq=(e,t)=>{var r=e.xAxis,n=e.width,a=e.height,o=e.offset;return U5(Y0(ar(ar(ar({},hi),r),{},{ticks:H5(r),viewBox:{x:0,y:0,width:n,height:a}})),o.left,o.left+o.width,t)},Lq=(e,t)=>{var r=e.yAxis,n=e.width,a=e.height,o=e.offset;return U5(Y0(ar(ar(ar({},hi),r),{},{ticks:H5(r),viewBox:{x:0,y:0,width:n,height:a}})),o.top,o.top+o.height,t)},$q={horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[],xAxisId:0,yAxisId:0,syncWithTicks:!1,zIndex:dr.grid};function uO(e){var t=X5(),r=Z5(),n=Y5(),a=ar(ar({},Jr(e,$q)),{},{x:Ee(e.x)?e.x:n.left,y:Ee(e.y)?e.y:n.top,width:Ee(e.width)?e.width:n.width,height:Ee(e.height)?e.height:n.height}),o=a.xAxisId,u=a.yAxisId,c=a.x,f=a.y,h=a.width,m=a.height,g=a.syncWithTicks,v=a.horizontalValues,b=a.verticalValues,j=Nr(),k=Me(F=>wS(F,"xAxis",o,j)),S=Me(F=>wS(F,"yAxis",u,j));if(!Un(h)||!Un(m)||!Ee(c)||!Ee(f))return null;var N=a.verticalCoordinatesGenerator||Rq,E=a.horizontalCoordinatesGenerator||Lq,A=a.horizontalPoints,P=a.verticalPoints;if((!A||!A.length)&&typeof E=="function"){var _=v&&v.length,O=E({yAxis:S?ar(ar({},S),{},{ticks:_?v:S.ticks}):void 0,width:t??h,height:r??m,offset:n},_?!0:g);vf(Array.isArray(O),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(typeof O,"]")),Array.isArray(O)&&(A=O)}if((!P||!P.length)&&typeof N=="function"){var D=b&&b.length,B=N({xAxis:k?ar(ar({},k),{},{ticks:D?b:k.ticks}):void 0,width:t??h,height:r??m,offset:n},D?!0:g);vf(Array.isArray(B),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(typeof B,"]")),Array.isArray(B)&&(P=B)}return y.createElement(Ni,{zIndex:a.zIndex},y.createElement("g",{className:"recharts-cartesian-grid"},y.createElement(_q,{fill:a.fill,fillOpacity:a.fillOpacity,x:a.x,y:a.y,width:a.width,height:a.height,ry:a.ry}),y.createElement(Tq,Ga({},a,{horizontalPoints:A})),y.createElement(Dq,Ga({},a,{verticalPoints:P})),y.createElement(Mq,Ga({},a,{offset:n,horizontalPoints:A,xAxis:k,yAxis:S})),y.createElement(Iq,Ga({},a,{offset:n,verticalPoints:P,xAxis:k,yAxis:S}))))}uO.displayName="CartesianGrid";var zq={},cO=sr({name:"errorBars",initialState:zq,reducers:{addErrorBar:(e,t)=>{var r=t.payload,n=r.itemId,a=r.errorBar;e[n]||(e[n]=[]),e[n].push(a)},replaceErrorBar:(e,t)=>{var r=t.payload,n=r.itemId,a=r.prev,o=r.next;e[n]&&(e[n]=e[n].map(u=>u.dataKey===a.dataKey&&u.direction===a.direction?o:u))},removeErrorBar:(e,t)=>{var r=t.payload,n=r.itemId,a=r.errorBar;e[n]&&(e[n]=e[n].filter(o=>o.dataKey!==a.dataKey||o.direction!==a.direction))}}}),Z0=cO.actions;Z0.addErrorBar;Z0.replaceErrorBar;Z0.removeErrorBar;var Fq=cO.reducer;function dO(e,t){var r,n,a=Me(h=>ki(h,e)),o=Me(h=>ji(h,t)),u=(r=a==null?void 0:a.allowDataOverflow)!==null&&r!==void 0?r:Et.allowDataOverflow,c=(n=o==null?void 0:o.allowDataOverflow)!==null&&n!==void 0?n:At.allowDataOverflow,f=u||c;return{needClip:f,needClipX:u,needClipY:c}}function Bq(e){var t=e.xAxisId,r=e.yAxisId,n=e.clipPathId,a=Q0(),o=dO(t,r),u=o.needClipX,c=o.needClipY,f=o.needClip,h=Me(A=>QC(A,t,!1)),m=Me(A=>YC(A,r,!1));if(!f||!a)return null;var g=a.x,v=a.y,b=a.width,j=a.height,k=u&&h?Math.min(h[0],h[1]):g-b/2,S=c&&m?Math.min(m[0],m[1]):v-j/2,N=u&&h?Math.abs(h[1]-h[0]):b*2,E=c&&m?Math.abs(m[1]-m[0]):j*2;return y.createElement("clipPath",{id:"clipPath-".concat(n)},y.createElement("rect",{x:k,y:S,width:N,height:E}))}function Uq(e){var t=lh(e),r=3,n=2;if(t!=null){var a=t.r,o=t.strokeWidth,u=Number(a),c=Number(o);return(Number.isNaN(u)||u<0)&&(u=r),(Number.isNaN(c)||c<0)&&(c=n),{r:u,strokeWidth:c}}return{r,strokeWidth:n}}function J0(e,t){var r,n;return(r=(n=e.graphicalItems.cartesianItems.find(a=>a.id===t))===null||n===void 0?void 0:n.xAxisId)!==null&&r!==void 0?r:tO}function ex(e,t){var r,n;return(r=(n=e.graphicalItems.cartesianItems.find(a=>a.id===t))===null||n===void 0?void 0:n.yAxisId)!==null&&r!==void 0?r:tO}var fO=(e,t,r)=>iP(e,"xAxis",J0(e,t),r),hO=(e,t,r)=>nP(e,"xAxis",J0(e,t),r),mO=(e,t,r)=>iP(e,"yAxis",ex(e,t),r),pO=(e,t,r)=>nP(e,"yAxis",ex(e,t),r),Hq=q([ct,fO,mO,hO,pO],(e,t,r,n,a)=>Gn(e,"xAxis")?gf(t,n,!1):gf(r,a,!1)),Wq=(e,t)=>t,gO=q([jC,Wq],(e,t)=>e.filter(r=>r.type==="area").find(r=>r.id===t)),vO=e=>{var t=ct(e),r=Gn(t,"xAxis");return r?"yAxis":"xAxis"},Kq=(e,t)=>{var r=vO(e);return r==="yAxis"?ex(e,t):J0(e,t)},Gq=(e,t,r)=>IC(e,vO(e),Kq(e,t),r),Vq=q([gO,Gq],(e,t)=>{var r;if(!(e==null||t==null)){var n=e.stackId,a=e0(e);if(!(n==null||a==null)){var o=(r=t[n])===null||r===void 0?void 0:r.stackedData,u=o==null?void 0:o.find(c=>c.key===a);if(u!=null)return u.map(c=>[c[0],c[1]])}}}),qq=q([ct,fO,mO,hO,pO,Vq,yF,Hq,gO,DF],(e,t,r,n,a,o,u,c,f,h)=>{var m=u.chartData,g=u.dataStartIndex,v=u.dataEndIndex;if(!(f==null||e!=="horizontal"&&e!=="vertical"||t==null||r==null||n==null||a==null||n.length===0||a.length===0||c==null)){var b=f.data,j;if(b&&b.length>0?j=b:j=m==null?void 0:m.slice(g,v+1),j!=null)return bQ({layout:e,xAxis:t,yAxis:r,xAxisTicks:n,yAxisTicks:a,dataStartIndex:g,areaSettings:f,stackedData:o,displayedData:j,chartBaseValue:h,bandSize:c})}}),Qq=["animationElapsedTime","isAnimating","isEntrance","layout","isRange","stroke","connectNulls"],Yq=["id","baseLine"];function hu(){return hu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},hu.apply(null,arguments)}function b2(e,t){if(e==null)return{};var r,n,a=Xq(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function Xq(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function Zq(e){var t,r,n=e.alpha,a=e.baseLine,o=e.points,u=e.strokeWidth,c=(t=o[0])===null||t===void 0?void 0:t.x,f=(r=o[o.length-1])===null||r===void 0?void 0:r.x;if(!He(c)||!He(f))return null;var h=n*Math.abs(c-f),m=Math.max(...o.map(g=>g.y||0));return Ee(a)?m=Math.max(a,m):a&&Array.isArray(a)&&a.length&&(m=Math.max(...a.map(g=>g.y||0),m)),Ee(m)?y.createElement("rect",{x:c<f?c:c-h,y:0,width:h,height:Math.floor(m+(u?parseInt("".concat(u),10):1))}):null}function Jq(e){var t,r,n=e.alpha,a=e.baseLine,o=e.points,u=e.strokeWidth,c=(t=o[0])===null||t===void 0?void 0:t.y,f=(r=o[o.length-1])===null||r===void 0?void 0:r.y;if(!He(c)||!He(f))return null;var h=n*Math.abs(c-f),m=Math.max(...o.map(g=>g.x||0));return Ee(a)?m=Math.max(a,m):a&&Array.isArray(a)&&a.length&&(m=Math.max(...a.map(g=>g.x||0),m)),Ee(m)?y.createElement("rect",{x:0,y:c<f?c:c-h,width:m+(u?parseInt("".concat(u),10):1),height:Math.floor(h)}):null}function eQ(e){var t=e.alpha,r=e.layout,n=e.points,a=e.baseLine,o=e.strokeWidth;return r==="vertical"?y.createElement(Jq,{alpha:t,points:n,baseLine:a,strokeWidth:o}):y.createElement(Zq,{alpha:t,points:n,baseLine:a,strokeWidth:o})}function tQ(e){var t=e.animationElapsedTime,r=t===void 0?1:t,n=e.isAnimating,a=n===void 0?!1:n,o=e.isEntrance,u=o===void 0?!1:o,c=e.layout,f=e.isRange,h=e.stroke,m=e.connectNulls,g=b2(e,Qq),v=c==="vertical"?"vertical":"horizontal",b=m??!1,j=JP(),k=g.id,S=g.baseLine,N=b2(g,Yq),E=vn(N),A=y.createElement(Vd,hu({},g,{id:k,baseLine:S,connectNulls:b,stroke:"none",className:"recharts-area-area",layout:v})),P=h!=="none"&&y.createElement(Vd,hu({},E,{className:"recharts-area-curve",layout:v,type:g.type,connectNulls:b,fill:"none",stroke:h,points:g.points})),_=h!=="none"&&f&&Array.isArray(S)&&y.createElement(Vd,hu({},E,{className:"recharts-area-curve",layout:v,type:g.type,connectNulls:b,fill:"none",stroke:h,points:S}));if(u&&(a||r<1)){var O;return y.createElement(Xr,null,y.createElement("defs",null,y.createElement("clipPath",{id:j},y.createElement(eQ,{alpha:r,points:(O=g.points)!==null&&O!==void 0?O:[],baseLine:S,layout:v,strokeWidth:g.strokeWidth}))),y.createElement(Xr,{clipPath:"url(#".concat(j,")")},A,P,_))}return y.createElement(y.Fragment,null,A,P,_)}var rQ=["id"],nQ=["activeDot","animationBegin","animationDuration","animationEasing","connectNulls","dot","fill","fillOpacity","hide","isAnimationActive","legendType","stroke","xAxisId","yAxisId"];function Gf(){return Gf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Gf.apply(null,arguments)}function yO(e,t){if(e==null)return{};var r,n,a=iQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function iQ(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function w2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Hs(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?w2(Object(r),!0).forEach(function(n){aQ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):w2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function aQ(e,t,r){return(t=oQ(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function oQ(e){var t=sQ(e,"string");return typeof t=="symbol"?t:t+""}function sQ(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var lQ=(e,t)=>e==null?[]:t===1?e.flatMap(r=>r.status==="removed"?[]:[r.next]):e.flatMap(r=>r.status==="matched"?[Hs(Hs({},r.next),{},{x:li(r.prev.x,r.next.x,t),y:li(r.prev.y,r.next.y,t)})]:r.status==="added"?[r.next]:[]),xO={activeDot:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",animationMatchBy:V0,animationInterpolateFn:lQ,connectNulls:!1,dot:!1,fill:"#3182bd",fillOpacity:.6,hide:!1,isAnimationActive:"auto",legendType:"line",stroke:"#3182bd",strokeWidth:1,type:"linear",label:!1,shape:tQ,xAxisId:0,yAxisId:0,zIndex:dr.area};function Vf(e,t){return e&&e!=="none"?e:t}var uQ=e=>{var t=e.dataKey,r=e.name,n=e.stroke,a=e.fill,o=e.legendType,u=e.hide;return[{inactive:u,dataKey:t,type:o,color:Vf(n,a),value:W5(r,t),payload:e}]},cQ=y.memo(e=>{var t=e.dataKey,r=e.data,n=e.stroke,a=e.strokeWidth,o=e.fill,u=e.name,c=e.hide,f=e.unit,h=e.tooltipType,m=e.id,g={dataDefinedOnItem:r,getPosition:Vs,settings:{stroke:n,strokeWidth:a,fill:o,dataKey:t,nameKey:void 0,name:W5(u,t),hide:c,type:h,color:Vf(n,o),unit:f,graphicalItemId:m}};return y.createElement(kG,{tooltipEntrySettings:g})});function dQ(e){var t=e.clipPathId,r=e.points,n=e.props,a=n.needClip,o=n.dot,u=n.dataKey,c=vn(n);return y.createElement(dV,{points:r,dot:o,className:"recharts-area-dots",dotClassName:"recharts-area-dot",dataKey:u,baseProps:c,needClip:a,clipPathId:t})}function fQ(e){var t=e.showLabels,r=e.children,n=e.points,a=n.map(o=>{var u,c,f={x:(u=o.x)!==null&&u!==void 0?u:0,y:(c=o.y)!==null&&c!==void 0?c:0,width:0,lowerWidth:0,upperWidth:0,height:0};return Hs(Hs({},f),{},{value:o.value,payload:o.payload,parentViewBox:void 0,viewBox:f,fill:void 0})});return y.createElement(sG,{value:t?a:void 0},r)}function hQ(e){var t=e.points,r=e.baseLine,n=e.needClip,a=e.clipPathId,o=e.props,u=e.animationElapsedTime,c=e.isAnimating,f=e.isEntrance,h=o.layout,m=o.type,g=o.stroke,v=o.connectNulls,b=o.isRange,j=o.shape,k=o.id,S=yO(o,rQ),N=Yr(S),E=Hs(Hs({},N),{},{id:k,points:t,connectNulls:v,type:m,baseLine:r,layout:h,stroke:g,isRange:b,animationElapsedTime:u,isAnimating:c,isEntrance:f});return y.createElement(y.Fragment,null,(t==null?void 0:t.length)>1&&y.createElement(Xr,{clipPath:n?"url(#clipPath-".concat(a,")"):void 0},y.createElement(wG,{option:j,DefaultShape:xO.shape,shapeProps:E})),y.createElement(dQ,{points:t,props:S,clipPathId:a}))}function mQ(e,t,r){if(Ee(e)){var n=Ee(t)?t:void 0;return li(n,e,r)}if(Gt(e)||Fn(e)){var a=Ee(t)?t:void 0;return li(a,0,r)}return e}function pQ(e){var t=e.needClip,r=e.clipPathId,n=e.props,a=e.previousPointsRef,o=e.previousBaselineRef,u=n.points,c=n.baseLine,f=n.isAnimationActive,h=n.animationBegin,m=n.animationDuration,g=n.animationEasing,v=n.animationMatchBy,b=n.animationInterpolateFn,j=y.useMemo(()=>({points:u,baseLine:c}),[u,c]),k=ZP(j,o),S=Fy(),N=zG(n.onAnimationStart,n.onAnimationEnd),E=N.isAnimating,A=N.handleAnimationStart,P=N.handleAnimationEnd,_=k.startValue;if(S==null)return null;var O;return Array.isArray(c)&&Array.isArray(_)?O=ey(_,c,v):Array.isArray(c)?O=ey(null,c,v):O=null,y.createElement(FG,{animationInput:j,animationIdPrefix:"recharts-area-",items:u,previousItemsRef:a,isAnimationActive:f,animationBegin:h,animationDuration:m,animationEasing:g,onAnimationStart:A,onAnimationEnd:P,animationInterpolateFn:b,animationMatchBy:v,layout:S},(D,B,F)=>{var z;return B===1?z=c:Array.isArray(c)?z=b(O,B,S):z=F?c:mQ(c,_,B),k.syncStepValue(z,B),y.createElement(fQ,{showLabels:!E,points:u},n.children,y.createElement(hQ,{points:D,baseLine:z,needClip:t,clipPathId:r,props:n,animationElapsedTime:B,isAnimating:E||B<1,isEntrance:F}),y.createElement(cG,{label:n.label}))})}function gQ(e){var t=e.needClip,r=e.clipPathId,n=e.props,a=y.useRef(null),o=y.useRef();return y.createElement(pQ,{needClip:t,clipPathId:r,props:n,previousPointsRef:a,previousBaselineRef:o})}class vQ extends y.PureComponent{render(){var t=this.props,r=t.hide,n=t.dot,a=t.points,o=t.className,u=t.top,c=t.left,f=t.needClip,h=t.xAxisId,m=t.yAxisId,g=t.width,v=t.height,b=t.id,j=t.baseLine,k=t.zIndex;if(r)return null;var S=rt("recharts-area",o),N=b,E=Uq(n),A=E.r,P=E.strokeWidth,_=YP(n),O=A*2+P,D=f?"url(#clipPath-".concat(_?"":"dots-").concat(N,")"):void 0;return y.createElement(Ni,{zIndex:k},y.createElement(Xr,{className:S},f&&y.createElement("defs",null,y.createElement(Bq,{clipPathId:N,xAxisId:h,yAxisId:m}),!_&&y.createElement("clipPath",{id:"clipPath-dots-".concat(N)},y.createElement("rect",{x:c-O/2,y:u-O/2,width:g+O,height:v+O}))),y.createElement(gQ,{needClip:f,clipPathId:N,props:this.props})),y.createElement(f2,{points:a,mainColor:Vf(this.props.stroke,this.props.fill),itemDataKey:this.props.dataKey,activeDot:this.props.activeDot,clipPath:D}),this.props.isRange&&Array.isArray(j)&&y.createElement(f2,{points:j,mainColor:Vf(this.props.stroke,this.props.fill),itemDataKey:this.props.dataKey,activeDot:this.props.activeDot,clipPath:D}))}}function yQ(e){var t,r=e.activeDot,n=e.animationBegin,a=e.animationDuration,o=e.animationEasing,u=e.connectNulls,c=e.dot,f=e.fill,h=e.fillOpacity,m=e.hide,g=e.isAnimationActive,v=e.legendType,b=e.stroke,j=e.xAxisId,k=e.yAxisId,S=yO(e,nQ),N=qs(),E=AP(),A=dO(j,k),P=A.needClip,_=Nr(),O=(t=Me(ge=>qq(ge,e.id,_)))!==null&&t!==void 0?t:{},D=O.points,B=O.isRange,F=O.baseLine,z=Q0();if(N!=="horizontal"&&N!=="vertical"||z==null||E!=="AreaChart"&&E!=="ComposedChart")return null;var Y=z.height,U=z.width,he=z.x,ue=z.y;return!D||!D.length?null:y.createElement(vQ,Gf({},S,{activeDot:r,animationBegin:n,animationDuration:a,animationEasing:o,baseLine:F,connectNulls:u,dot:c,fill:f,fillOpacity:h,height:Y,hide:m,layout:N,isAnimationActive:g,isRange:B,legendType:v,needClip:P,points:D,stroke:b,width:U,left:he,top:ue,xAxisId:j,yAxisId:k}))}var xQ=(e,t,r,n,a)=>{var o=r??t;if(Ee(o))return o;var u=e==="horizontal"?a:n,c=u.scale.domain();if(u.type==="number"){var f=Math.max(c[0],c[1]),h=Math.min(c[0],c[1]);return o==="dataMin"?h:o==="dataMax"||f<0?f:Math.max(Math.min(c[0],c[1]),0)}return o==="dataMin"?c[0]:o==="dataMax"?c[1]:c[0]};function bQ(e){var t=e.areaSettings,r=t.connectNulls,n=t.baseValue,a=t.dataKey,o=e.stackedData,u=e.layout,c=e.chartBaseValue,f=e.xAxis,h=e.yAxis,m=e.displayedData,g=e.dataStartIndex,v=e.xAxisTicks,b=e.yAxisTicks,j=e.bandSize,k=o&&o.length,S=xQ(u,c,n,f,h),N=u==="horizontal",E=!1,A=m.map((_,O)=>{var D,B,F,z;if(k)z=o[g+O];else{var Y=Dt(_,a);Array.isArray(Y)?(z=Y,E=!0):z=[S,Y]}var U=(D=(B=z)===null||B===void 0?void 0:B[1])!==null&&D!==void 0?D:null,he=U==null||k&&!r&&Dt(_,a)==null;if(N){var ue;return{x:gk({axis:f,ticks:v,bandSize:j,entry:_,index:O}),y:he?null:(ue=h.scale.map(U))!==null&&ue!==void 0?ue:null,value:z,payload:_}}return{x:he?null:(F=f.scale.map(U))!==null&&F!==void 0?F:null,y:gk({axis:h,ticks:b,bandSize:j,entry:_,index:O}),value:z,payload:_}}),P;return k||E?P=A.map(_=>{var O,D=Array.isArray(_.value)?_.value[0]:null;if(N){var B;return{x:_.x,y:D!=null&&_.y!=null&&(B=h.scale.map(D))!==null&&B!==void 0?B:null,payload:_.payload}}return{x:D!=null&&(O=f.scale.map(D))!==null&&O!==void 0?O:null,y:_.y,payload:_.payload}}):P=N?h.scale.map(S):f.scale.map(S),{points:A,baseLine:P??0,isRange:E}}function wQ(e){var t=Jr(e,xO),r=Nr();return y.createElement(QG,{id:t.id,type:"area"},n=>y.createElement(y.Fragment,null,y.createElement(jG,{legendPayload:uQ(t)}),y.createElement(cQ,{dataKey:t.dataKey,data:t.data,stroke:t.stroke,strokeWidth:t.strokeWidth,fill:t.fill,name:t.name,hide:t.hide,unit:t.unit,tooltipType:t.tooltipType,id:n}),y.createElement(rV,{type:"area",id:n,data:t.data,dataKey:t.dataKey,xAxisId:t.xAxisId,yAxisId:t.yAxisId,zAxisId:0,stackId:iz(t.stackId),hide:t.hide,barSize:void 0,baseValue:t.baseValue,isPanorama:r,connectNulls:t.connectNulls}),y.createElement(yQ,Gf({},t,{id:n}))))}var bO=y.memo(wQ,Oh);bO.displayName="Area";var kQ=["domain","range"],jQ=["domain","range"];function k2(e,t){if(e==null)return{};var r,n,a=SQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function SQ(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function j2(e,t){return e===t?!0:Array.isArray(e)&&e.length===2&&Array.isArray(t)&&t.length===2?e[0]===t[0]&&e[1]===t[1]:!1}function wO(e,t){if(e===t)return!0;var r=e.domain,n=e.range,a=k2(e,kQ),o=t.domain,u=t.range,c=k2(t,jQ);return!j2(r,o)||!j2(n,u)?!1:Oh(a,c)}var NQ=["type"],EQ=["dangerouslySetInnerHTML","ticks","scale"],AQ=["id","scale"];function ty(){return ty=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ty.apply(null,arguments)}function S2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function N2(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?S2(Object(r),!0).forEach(function(n){CQ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):S2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function CQ(e,t,r){return(t=PQ(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function PQ(e){var t=OQ(e,"string");return typeof t=="symbol"?t:t+""}function OQ(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ry(e,t){if(e==null)return{};var r,n,a=_Q(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function _Q(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function MQ(e){var t=jt(),r=y.useRef(null),n=Fy(),a=e.type,o=ry(e,NQ),u=Th(n,"xAxis",a),c=y.useMemo(()=>{if(u!=null)return N2(N2({},o),{},{type:u})},[o,u]);return y.useLayoutEffect(()=>{c!=null&&(r.current===null?t(gV(c)):r.current!==c&&t(vV({prev:r.current,next:c})),r.current=c)},[c,t]),y.useLayoutEffect(()=>()=>{r.current&&(t(yV(r.current)),r.current=null)},[t]),null}var IQ=e=>{var t=e.xAxisId,r=e.className,n=Me(G5),a=Nr(),o="xAxis",u=Me(v=>rP(v,o,t,a)),c=Me(v=>hU(v,t)),f=Me(v=>xU(v,t)),h=Me(v=>xC(v,t));if(c==null||f==null||h==null)return null;e.dangerouslySetInnerHTML,e.ticks,e.scale;var m=ry(e,EQ);h.id,h.scale;var g=ry(h,AQ);return y.createElement(X0,ty({},m,g,{x:f.x,y:f.y,width:c.width,height:c.height,className:rt("recharts-".concat(o," ").concat(o),r),viewBox:n,ticks:u,axisType:o,axisId:t}))},TQ={allowDataOverflow:Et.allowDataOverflow,allowDecimals:Et.allowDecimals,allowDuplicatedCategory:Et.allowDuplicatedCategory,angle:Et.angle,axisLine:hi.axisLine,height:Et.height,hide:!1,includeHidden:Et.includeHidden,interval:Et.interval,label:!1,minTickGap:Et.minTickGap,mirror:Et.mirror,orientation:Et.orientation,padding:Et.padding,reversed:Et.reversed,scale:Et.scale,tick:Et.tick,tickCount:Et.tickCount,tickLine:hi.tickLine,tickSize:hi.tickSize,type:Et.type,niceTicks:Et.niceTicks,xAxisId:0},DQ=e=>{var t=Jr(e,TQ);return y.createElement(y.Fragment,null,y.createElement(MQ,{allowDataOverflow:t.allowDataOverflow,allowDecimals:t.allowDecimals,allowDuplicatedCategory:t.allowDuplicatedCategory,angle:t.angle,dataKey:t.dataKey,domain:t.domain,height:t.height,hide:t.hide,id:t.xAxisId,includeHidden:t.includeHidden,interval:t.interval,minTickGap:t.minTickGap,mirror:t.mirror,name:t.name,orientation:t.orientation,padding:t.padding,reversed:t.reversed,scale:t.scale,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,niceTicks:t.niceTicks}),y.createElement(IQ,t))},kO=y.memo(DQ,wO);kO.displayName="XAxis";var RQ=["type"],LQ=["dangerouslySetInnerHTML","ticks","scale"],$Q=["id","scale"];function ny(){return ny=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ny.apply(null,arguments)}function E2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function A2(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?E2(Object(r),!0).forEach(function(n){zQ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):E2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function zQ(e,t,r){return(t=FQ(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function FQ(e){var t=BQ(e,"string");return typeof t=="symbol"?t:t+""}function BQ(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function iy(e,t){if(e==null)return{};var r,n,a=UQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function UQ(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function HQ(e){var t=jt(),r=y.useRef(null),n=Fy(),a=e.type,o=iy(e,RQ),u=Th(n,"yAxis",a),c=y.useMemo(()=>{if(u!=null)return A2(A2({},o),{},{type:u})},[u,o]);return y.useLayoutEffect(()=>{c!=null&&(r.current===null?t(xV(c)):r.current!==c&&t(bV({prev:r.current,next:c})),r.current=c)},[c,t]),y.useLayoutEffect(()=>()=>{r.current&&(t(wV(r.current)),r.current=null)},[t]),null}function WQ(e){var t=e.yAxisId,r=e.className,n=e.width,a=e.label,o=y.useRef(null),u=y.useRef(null),c=Me(G5),f=Nr(),h=jt(),m="yAxis",g=Me(N=>kU(N,t)),v=Me(N=>wU(N,t)),b=Me(N=>rP(N,m,t,f)),j=Me(N=>bC(N,t));if(y.useLayoutEffect(()=>{if(!(n!=="auto"||!g||G0(a)||y.isValidElement(a)||j==null)){var N=o.current;if(N){var E=N.getCalculatedWidth();Math.round(g.width)!==Math.round(E)&&h(kV({id:t,width:E}))}}},[b,g,h,a,t,n,j]),g==null||v==null||j==null)return null;e.dangerouslySetInnerHTML,e.ticks,e.scale;var k=iy(e,LQ);j.id,j.scale;var S=iy(j,$Q);return y.createElement(X0,ny({},k,S,{ref:o,labelRef:u,x:v.x,y:v.y,tickTextProps:n==="auto"?{width:void 0}:{width:n},width:g.width,height:g.height,className:rt("recharts-".concat(m," ").concat(m),r),viewBox:c,ticks:b,axisType:m,axisId:t}))}var KQ={allowDataOverflow:At.allowDataOverflow,allowDecimals:At.allowDecimals,allowDuplicatedCategory:At.allowDuplicatedCategory,angle:At.angle,axisLine:hi.axisLine,hide:!1,includeHidden:At.includeHidden,interval:At.interval,label:!1,minTickGap:At.minTickGap,mirror:At.mirror,orientation:At.orientation,padding:At.padding,reversed:At.reversed,scale:At.scale,tick:At.tick,tickCount:At.tickCount,tickLine:hi.tickLine,tickSize:hi.tickSize,type:At.type,niceTicks:At.niceTicks,width:At.width,yAxisId:0},GQ=e=>{var t=Jr(e,KQ);return y.createElement(y.Fragment,null,y.createElement(HQ,{interval:t.interval,id:t.yAxisId,scale:t.scale,type:t.type,domain:t.domain,allowDataOverflow:t.allowDataOverflow,dataKey:t.dataKey,allowDuplicatedCategory:t.allowDuplicatedCategory,allowDecimals:t.allowDecimals,tickCount:t.tickCount,padding:t.padding,includeHidden:t.includeHidden,reversed:t.reversed,ticks:t.ticks,width:t.width,orientation:t.orientation,mirror:t.mirror,hide:t.hide,unit:t.unit,name:t.name,angle:t.angle,minTickGap:t.minTickGap,tick:t.tick,tickFormatter:t.tickFormatter,niceTicks:t.niceTicks}),y.createElement(WQ,t))},jO=y.memo(GQ,wO);jO.displayName="YAxis";var VQ=(e,t)=>t,tx=q([VQ,ct,TA,Lt,wP,Si,WH,Qt],XH);function qQ(e){return"getBBox"in e.currentTarget&&typeof e.currentTarget.getBBox=="function"}function rx(e){var t=e.currentTarget.getBoundingClientRect(),r,n;if(qQ(e)){var a=e.currentTarget.getBBox();r=a.width>0?t.width/a.width:1,n=a.height>0?t.height/a.height:1}else{var o=e.currentTarget;r=o.offsetWidth>0?t.width/o.offsetWidth:1,n=o.offsetHeight>0?t.height/o.offsetHeight:1}var u=(c,f)=>({relativeX:Math.round((c-t.left)/r),relativeY:Math.round((f-t.top)/n)});return"touches"in e?Array.from(e.touches).map(c=>u(c.clientX,c.clientY)):u(e.clientX,e.clientY)}var SO=Lr("mouseClick"),NO=Ku();NO.startListening({actionCreator:SO,effect:(e,t)=>{var r=e.payload,n=tx(t.getState(),rx(r));(n==null?void 0:n.activeIndex)!=null&&t.dispatch(LU({activeIndex:n.activeIndex,activeDataKey:void 0,activeCoordinate:n.activeCoordinate}))}});var ay=Lr("mouseMove"),EO=Ku(),is=null,Ia=null,Ig=null;EO.startListening({actionCreator:ay,effect:(e,t)=>{var r=e.payload,n=t.getState(),a=n.eventSettings,o=a.throttleDelay,u=a.throttledEvents,c=u==="all"||(u==null?void 0:u.includes("mousemove"));is!==null&&(cancelAnimationFrame(is),is=null),Ia!==null&&(typeof o!="number"||!c)&&(clearTimeout(Ia),Ia=null),Ig=rx(r);var f=()=>{var h=t.getState(),m=ic(h,h.tooltip.settings.shared);if(!Ig){is=null,Ia=null;return}if(m==="axis"){var g=tx(h,Ig);(g==null?void 0:g.activeIndex)!=null?t.dispatch(dP({activeIndex:g.activeIndex,activeDataKey:void 0,activeCoordinate:g.activeCoordinate})):t.dispatch(cP())}is=null,Ia=null};if(!c){f();return}o==="raf"?is=requestAnimationFrame(f):typeof o=="number"&&Ia===null&&(Ia=setTimeout(f,o))}});function QQ(e,t){return t instanceof HTMLElement?"HTMLElement <".concat(t.tagName,' class="').concat(t.className,'">'):t===window?"global.window":e==="children"&&typeof t=="object"&&t!==null?"<<CHILDREN>>":t}var C2={accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,barSize:void 0,className:void 0,maxBarSize:void 0,stackOffset:"none",syncId:void 0,syncMethod:"index",baseValue:void 0,reverseStackOrder:!1},AO=sr({name:"rootProps",initialState:C2,reducers:{updateOptions:(e,t)=>{var r;e.accessibilityLayer=t.payload.accessibilityLayer,e.barCategoryGap=t.payload.barCategoryGap,e.barGap=(r=t.payload.barGap)!==null&&r!==void 0?r:C2.barGap,e.barSize=t.payload.barSize,e.maxBarSize=t.payload.maxBarSize,e.stackOffset=t.payload.stackOffset,e.syncId=t.payload.syncId,e.syncMethod=t.payload.syncMethod,e.className=t.payload.className,e.baseValue=t.payload.baseValue,e.reverseStackOrder=t.payload.reverseStackOrder}}}),YQ=AO.reducer,XQ=AO.actions.updateOptions,ZQ=null,JQ={updatePolarOptions:(e,t)=>e===null?t.payload:(e.startAngle=t.payload.startAngle,e.endAngle=t.payload.endAngle,e.cx=t.payload.cx,e.cy=t.payload.cy,e.innerRadius=t.payload.innerRadius,e.outerRadius=t.payload.outerRadius,e)},CO=sr({name:"polarOptions",initialState:ZQ,reducers:JQ});CO.actions.updatePolarOptions;var eY=CO.reducer,PO=Lr("keyDown"),OO=Lr("focus"),_O=Lr("blur"),Yh=Ku(),as=null,Ta=null,$d=null;Yh.startListening({actionCreator:PO,effect:(e,t)=>{$d=e.payload,as!==null&&(cancelAnimationFrame(as),as=null);var r=t.getState(),n=r.eventSettings,a=n.throttleDelay,o=n.throttledEvents,u=o==="all"||o.includes("keydown");Ta!==null&&(typeof a!="number"||!u)&&(clearTimeout(Ta),Ta=null);var c=()=>{try{var f=t.getState(),h=f.rootProps.accessibilityLayer!==!1;if(!h)return;var m=f.tooltip.keyboardInteraction,g=$d;if(g!=="ArrowRight"&&g!=="ArrowLeft"&&g!=="Enter")return;var v=du(m,po(f),Bs(f),Us(f)),b=v==null?-1:Number(v),j=!Number.isFinite(b)||b<0,k=Si(f),S=po(f),N=ic(f,f.tooltip.settings.shared);if(g==="Enter"){if(j)return;var E=Bf(f,N,"hover",String(m.index));t.dispatch(Ff({active:!m.active,activeIndex:m.index,activeCoordinate:E}));return}var A=AU(f),P=A==="left-to-right"?1:-1,_=g==="ArrowRight"?1:-1,O;if(j){var D=Bs(f),B=Us(f),F=_*P,z=ge=>({active:!1,index:String(ge),dataKey:void 0,graphicalItemId:void 0,coordinate:void 0});if(O=-1,F>0){for(var Y=0;Y<S.length;Y++)if(du(z(Y),S,D,B)!=null){O=Y;break}}else for(var U=S.length-1;U>=0;U--)if(du(z(U),S,D,B)!=null){O=U;break}if(O<0)return}else{O=b+_*P;var he=(k==null?void 0:k.length)||S.length;if(he===0||O>=he||O<0)return}var ue=Bf(f,N,"hover",String(O));t.dispatch(Ff({active:!0,activeIndex:O.toString(),activeCoordinate:ue}))}finally{as=null,Ta=null}};if(!u){c();return}a==="raf"?as=requestAnimationFrame(c):typeof a=="number"&&Ta===null&&(c(),$d=null,Ta=setTimeout(()=>{$d?c():(Ta=null,as=null)},a))}});Yh.startListening({actionCreator:OO,effect:(e,t)=>{var r=t.getState(),n=r.rootProps.accessibilityLayer!==!1;if(n){var a=r.tooltip.keyboardInteraction;if(!a.active&&a.index==null){var o="0",u=ic(r,r.tooltip.settings.shared),c=Bf(r,u,"hover",String(o));t.dispatch(Ff({active:!0,activeIndex:o,activeCoordinate:c}))}}}});Yh.startListening({actionCreator:_O,effect:(e,t)=>{var r=t.getState(),n=r.rootProps.accessibilityLayer!==!1;if(n){var a=r.tooltip.keyboardInteraction;a.active&&t.dispatch(Ff({active:!1,activeIndex:a.index,activeCoordinate:a.coordinate}))}}});function MO(e){e.persist();var t=e.currentTarget;return new Proxy(e,{get:(r,n)=>{if(n==="currentTarget")return t;var a=Reflect.get(r,n);return typeof a=="function"?a.bind(r):a}})}var Kr=Lr("externalEvent"),IO=Ku(),zd=new Map,tu=new Map,Tg=new Map;IO.startListening({actionCreator:Kr,effect:(e,t)=>{var r=e.payload,n=r.handler,a=r.reactEvent;if(n!=null){var o=a.type,u=MO(a);Tg.set(o,{handler:n,reactEvent:u});var c=zd.get(o);c!==void 0&&(cancelAnimationFrame(c),zd.delete(o));var f=t.getState(),h=f.eventSettings,m=h.throttleDelay,g=h.throttledEvents,v=g,b=v==="all"||(v==null?void 0:v.includes(o)),j=tu.get(o);j!==void 0&&(typeof m!="number"||!b)&&(clearTimeout(j),tu.delete(o));var k=()=>{var E=Tg.get(o);try{if(!E)return;var A=E.handler,P=E.reactEvent,_=t.getState(),O={activeCoordinate:PH(_),activeDataKey:EH(_),activeIndex:Iu(_),activeLabel:SP(_),activeTooltipIndex:Iu(_),isTooltipActive:OH(_)};A&&A(O,P)}finally{zd.delete(o),tu.delete(o),Tg.delete(o)}};if(!b){k();return}if(m==="raf"){var S=requestAnimationFrame(k);zd.set(o,S)}else if(typeof m=="number"){if(!tu.has(o)){k();var N=setTimeout(k,m);tu.set(o,N)}}else k()}}});var tY=q([rl],e=>e.tooltipItemPayloads),rY=q([tY,(e,t)=>t,(e,t,r)=>r],(e,t,r)=>{if(t!=null){var n=e.find(o=>o.settings.graphicalItemId===r);if(n!=null){var a=n.getPosition;if(a!=null)return a(t)}}}),TO=Lr("touchMove"),DO=Ku(),Da=null,Vi=null,P2=null,ru=null;DO.startListening({actionCreator:TO,effect:(e,t)=>{var r=e.payload;if(!(r.touches==null||r.touches.length===0)){ru=MO(r);var n=t.getState(),a=n.eventSettings,o=a.throttleDelay,u=a.throttledEvents,c=u==="all"||u.includes("touchmove");Da!==null&&(cancelAnimationFrame(Da),Da=null),Vi!==null&&(typeof o!="number"||!c)&&(clearTimeout(Vi),Vi=null),P2=Array.from(r.touches).map(h=>rx({clientX:h.clientX,clientY:h.clientY,currentTarget:r.currentTarget}));var f=()=>{if(ru!=null){var h=t.getState(),m=ic(h,h.tooltip.settings.shared);if(m==="axis"){var g,v=(g=P2)===null||g===void 0?void 0:g[0];if(v==null){Da=null,Vi=null;return}var b=tx(h,v);(b==null?void 0:b.activeIndex)!=null&&t.dispatch(dP({activeIndex:b.activeIndex,activeDataKey:void 0,activeCoordinate:b.activeCoordinate}))}else if(m==="item"){var j,k=ru.touches[0];if(document.elementFromPoint==null||k==null)return;var S=document.elementFromPoint(k.clientX,k.clientY);if(!S||!S.getAttribute)return;var N=S.getAttribute(dz),E=(j=S.getAttribute(fz))!==null&&j!==void 0?j:void 0,A=jo(h).find(O=>O.id===E);if(N==null||A==null||E==null)return;var P=A.dataKey,_=rY(h,N,E);t.dispatch(RU({activeDataKey:P,activeIndex:N,activeCoordinate:_,activeGraphicalItemId:E}))}Da=null,Vi=null}};if(!c){f();return}o==="raf"?Da=requestAnimationFrame(f):typeof o=="number"&&Vi===null&&(f(),ru=null,Vi=setTimeout(()=>{ru?f():(Vi=null,Da=null)},o))}}});var RO={throttleDelay:"raf",throttledEvents:["mousemove","touchmove","pointermove","scroll","wheel"]},LO=sr({name:"eventSettings",initialState:RO,reducers:{setEventSettings:(e,t)=>{t.payload.throttleDelay!=null&&(e.throttleDelay=t.payload.throttleDelay),t.payload.throttledEvents!=null&&(e.throttledEvents=t.payload.throttledEvents)}}}),nY=LO.actions.setEventSettings,iY=LO.reducer,aY=h5({brush:MV,cartesianAxis:jV,chartData:CW,errorBars:Fq,eventSettings:iY,graphicalItems:eV,layout:Q$,legend:u6,options:jW,polarAxis:fG,polarOptions:eY,referenceElements:RV,renderedTicks:iq,rootProps:YQ,tooltip:$U,zIndex:cW}),oY=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"Chart";return b$({reducer:aY,preloadedState:t,middleware:n=>{var a;return n({serializableCheck:!1,immutableCheck:!["commonjs","es6","production"].includes((a="es6")!==null&&a!==void 0?a:"")}).concat([NO.middleware,EO.middleware,Yh.middleware,IO.middleware,DO.middleware])},enhancers:n=>{var a=n;return typeof n=="function"&&(a=n()),a.concat(C5({type:"raf"}))},devTools:{serialize:{replacer:QQ},name:"recharts-".concat(r)}})};function sY(e){var t=e.preloadedState,r=e.children,n=e.reduxStoreName,a=Nr(),o=y.useRef(null);if(a)return r;o.current==null&&(o.current=oY(t,n));var u=_y;return y.createElement(N6,{context:u,store:o.current},r)}function lY(e){var t=e.layout,r=e.margin,n=jt(),a=Nr();return y.useEffect(()=>{a||(n(G$(t)),n(K$(r)))},[n,a,t,r]),null}var uY=y.memo(lY,Oh);function cY(e){var t=jt();return y.useEffect(()=>{t(XQ(e))},[t,e]),null}var dY=e=>{var t=jt();return y.useEffect(()=>{t(nY(e))},[t,e]),null},fY=y.memo(dY,Oh);function O2(e){var t=e.zIndex,r=e.isPanorama,n=y.useRef(null),a=jt();return y.useLayoutEffect(()=>(n.current&&a(lW({zIndex:t,element:n.current,isPanorama:r})),()=>{a(uW({zIndex:t,isPanorama:r}))}),[a,t,r]),y.createElement("g",{tabIndex:-1,ref:n,className:"recharts-zIndex-layer_".concat(t)})}function _2(e){var t=e.children,r=e.isPanorama,n=Me(JH);if(!n||n.length===0)return t;var a=n.filter(u=>u<0),o=n.filter(u=>u>0);return y.createElement(y.Fragment,null,a.map(u=>y.createElement(O2,{key:u,zIndex:u,isPanorama:r})),t,o.map(u=>y.createElement(O2,{key:u,zIndex:u,isPanorama:r})))}var hY=["children"];function mY(e,t){if(e==null)return{};var r,n,a=pY(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function pY(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function qf(){return qf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},qf.apply(null,arguments)}var gY={width:"100%",height:"100%",display:"block"},vY=y.forwardRef((e,t)=>{var r=X5(),n=Z5(),a=lA();if(!Un(r)||!Un(n))return null;var o=e.children,u=e.otherAttributes,c=e.title,f=e.desc,h,m;return u!=null&&(typeof u.tabIndex=="number"?h=u.tabIndex:h=a?0:void 0,typeof u.role=="string"?m=u.role:m=a?"application":void 0),y.createElement(_E,qf({},u,{title:c,desc:f,role:m,tabIndex:h,width:r,height:n,style:gY,ref:t}),o)}),yY=e=>{var t=e.children,r=Me(Nh);if(!r)return null;var n=r.width,a=r.height,o=r.y,u=r.x;return y.createElement(_E,{width:n,height:a,x:u,y:o},t)},M2=y.forwardRef((e,t)=>{var r=e.children,n=mY(e,hY),a=Nr();return a?y.createElement(yY,null,y.createElement(_2,{isPanorama:!0},r)):y.createElement(vY,qf({ref:t},n),y.createElement(_2,{isPanorama:!1},r))});function xY(e,t){return jY(e)||kY(e,t)||wY(e,t)||bY()}function bY(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function wY(e,t){if(e){if(typeof e=="string")return I2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?I2(e,t):void 0}}function I2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function kY(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function jY(e){if(Array.isArray(e))return e}function SY(){var e=jt(),t=y.useState(null),r=xY(t,2),n=r[0],a=r[1],o=Me(cz);return y.useEffect(()=>{if(n!=null){var u=n.getBoundingClientRect(),c=u.width/n.offsetWidth;He(c)&&c!==o&&e(q$(c))}},[n,e,o]),a}function T2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function NY(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?T2(Object(r),!0).forEach(function(n){EY(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):T2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function EY(e,t,r){return(t=AY(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function AY(e){var t=CY(e,"string");return typeof t=="symbol"?t:t+""}function CY(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function fa(){return fa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},fa.apply(null,arguments)}function Qf(e,t){return MY(e)||_Y(e,t)||OY(e,t)||PY()}function PY(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function OY(e,t){if(e){if(typeof e=="string")return D2(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?D2(e,t):void 0}}function D2(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function _Y(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,a,o,u,c=[],f=!0,h=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(f=(n=o.call(r)).done)&&(c.push(n.value),c.length!==t);f=!0);}catch(m){h=!0,a=m}finally{try{if(!f&&r.return!=null&&(u=r.return(),Object(u)!==u))return}finally{if(h)throw a}}return c}}function MY(e){if(Array.isArray(e))return e}var IY=()=>(LW(),null);function Yf(e){if(typeof e=="number")return e;if(typeof e=="string"){var t=parseFloat(e);if(!Number.isNaN(t))return t}return 0}var TY=y.forwardRef((e,t)=>{var r,n,a=y.useRef(null),o=y.useState({containerWidth:Yf((r=e.style)===null||r===void 0?void 0:r.width),containerHeight:Yf((n=e.style)===null||n===void 0?void 0:n.height)}),u=Qf(o,2),c=u[0],f=u[1],h=y.useCallback((g,v)=>{f(b=>{var j=Math.round(g),k=Math.round(v);return b.containerWidth===j&&b.containerHeight===k?b:{containerWidth:j,containerHeight:k}})},[]),m=y.useCallback(g=>{if(typeof t=="function"&&t(g),a.current!=null&&(a.current.disconnect(),a.current=null),g!=null&&typeof ResizeObserver<"u"){var v=g.getBoundingClientRect(),b=v.width,j=v.height;h(b,j);var k=N=>{var E=N[0];if(E!=null){var A=E.contentRect,P=A.width,_=A.height;h(P,_)}},S=new ResizeObserver(k);S.observe(g),a.current=S}},[t,h]);return y.useEffect(()=>()=>{var g=a.current;g!=null&&g.disconnect()},[h]),y.createElement(y.Fragment,null,y.createElement(Vu,{width:c.containerWidth,height:c.containerHeight}),y.createElement("div",fa({ref:m},e)))}),DY=y.forwardRef((e,t)=>{var r=e.width,n=e.height,a=y.useState({containerWidth:Yf(r),containerHeight:Yf(n)}),o=Qf(a,2),u=o[0],c=o[1],f=y.useCallback((m,g)=>{c(v=>{var b=Math.round(m),j=Math.round(g);return v.containerWidth===b&&v.containerHeight===j?v:{containerWidth:b,containerHeight:j}})},[]),h=y.useCallback(m=>{if(typeof t=="function"&&t(m),m!=null){var g=m.getBoundingClientRect(),v=g.width,b=g.height;f(v,b)}},[t,f]);return y.createElement(y.Fragment,null,y.createElement(Vu,{width:u.containerWidth,height:u.containerHeight}),y.createElement("div",fa({ref:h},e)))}),RY=y.forwardRef((e,t)=>{var r=e.width,n=e.height;return y.createElement(y.Fragment,null,y.createElement(Vu,{width:r,height:n}),y.createElement("div",fa({ref:t},e)))}),LY=y.forwardRef((e,t)=>{var r=e.width,n=e.height;return typeof r=="string"||typeof n=="string"?y.createElement(DY,fa({},e,{ref:t})):typeof r=="number"&&typeof n=="number"?y.createElement(RY,fa({},e,{width:r,height:n,ref:t})):y.createElement(y.Fragment,null,y.createElement(Vu,{width:r,height:n}),y.createElement("div",fa({ref:t},e)))});function $Y(e){return e?TY:LY}var zY=y.forwardRef((e,t)=>{var r=e.children,n=e.className,a=e.height,o=e.onClick,u=e.onContextMenu,c=e.onDoubleClick,f=e.onMouseDown,h=e.onMouseEnter,m=e.onMouseLeave,g=e.onMouseMove,v=e.onMouseUp,b=e.onTouchEnd,j=e.onTouchMove,k=e.onTouchStart,S=e.style,N=e.width,E=e.responsive,A=e.dispatchTouchEvents,P=A===void 0?!0:A,_=y.useRef(null),O=jt(),D=y.useState(null),B=Qf(D,2),F=B[0],z=B[1],Y=y.useState(null),U=Qf(Y,2),he=U[0],ue=U[1],ge=SY(),ie=$y(),se=(ie==null?void 0:ie.width)>0?ie.width:N,X=(ie==null?void 0:ie.height)>0?ie.height:a,te=y.useCallback(Pe=>{ge(Pe),typeof t=="function"&&t(Pe),z(Pe),ue(Pe),Pe!=null&&(_.current=Pe)},[ge,t,z,ue]),J=y.useCallback(Pe=>{O(SO(Pe)),O(Kr({handler:o,reactEvent:Pe}))},[O,o]),I=y.useCallback(Pe=>{O(ay(Pe)),O(Kr({handler:h,reactEvent:Pe}))},[O,h]),M=y.useCallback(Pe=>{O(cP()),O(Kr({handler:m,reactEvent:Pe}))},[O,m]),H=y.useCallback(Pe=>{O(ay(Pe)),O(Kr({handler:g,reactEvent:Pe}))},[O,g]),ne=y.useCallback(()=>{O(OO())},[O]),Z=y.useCallback(()=>{O(_O())},[O]),me=y.useCallback(Pe=>{O(PO(Pe.key))},[O]),pe=y.useCallback(Pe=>{O(Kr({handler:u,reactEvent:Pe}))},[O,u]),Oe=y.useCallback(Pe=>{O(Kr({handler:c,reactEvent:Pe}))},[O,c]),re=y.useCallback(Pe=>{O(Kr({handler:f,reactEvent:Pe}))},[O,f]),we=y.useCallback(Pe=>{O(Kr({handler:v,reactEvent:Pe}))},[O,v]),_e=y.useCallback(Pe=>{O(Kr({handler:k,reactEvent:Pe}))},[O,k]),ae=y.useCallback(Pe=>{P&&O(TO(Pe)),O(Kr({handler:j,reactEvent:Pe}))},[O,P,j]),et=y.useCallback(Pe=>{O(Kr({handler:b,reactEvent:Pe}))},[O,b]),Be=$Y(E);return y.createElement(MP.Provider,{value:F},y.createElement(JD.Provider,{value:he},y.createElement(Be,{width:se??(S==null?void 0:S.width),height:X??(S==null?void 0:S.height),className:rt("recharts-wrapper",n),style:NY({position:"relative",cursor:"default",width:se,height:X},S),onClick:J,onContextMenu:pe,onDoubleClick:Oe,onFocus:ne,onBlur:Z,onKeyDown:me,onMouseDown:re,onMouseEnter:I,onMouseLeave:M,onMouseMove:H,onMouseUp:we,onTouchEnd:et,onTouchMove:ae,onTouchStart:_e,ref:te},y.createElement(IY,null),r)))}),FY=["width","height","responsive","children","className","style","compact","title","desc"];function BY(e,t){if(e==null)return{};var r,n,a=UY(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function UY(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}var HY=y.forwardRef((e,t)=>{var r=e.width,n=e.height,a=e.responsive,o=e.children,u=e.className,c=e.style,f=e.compact,h=e.title,m=e.desc,g=BY(e,FY),v=vn(g);return f?y.createElement(y.Fragment,null,y.createElement(Vu,{width:r,height:n}),y.createElement(M2,{otherAttributes:v,title:h,desc:m},o)):y.createElement(zY,{className:u,style:c,width:r,height:n,responsive:a??!1,onClick:e.onClick,onMouseLeave:e.onMouseLeave,onMouseEnter:e.onMouseEnter,onMouseMove:e.onMouseMove,onMouseDown:e.onMouseDown,onMouseUp:e.onMouseUp,onContextMenu:e.onContextMenu,onDoubleClick:e.onDoubleClick,onTouchStart:e.onTouchStart,onTouchMove:e.onTouchMove,onTouchEnd:e.onTouchEnd},y.createElement(M2,{otherAttributes:v,title:h,desc:m,ref:t},y.createElement(HV,null,o)))});function oy(){return oy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},oy.apply(null,arguments)}function R2(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function WY(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?R2(Object(r),!0).forEach(function(n){KY(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):R2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function KY(e,t,r){return(t=GY(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function GY(e){var t=VY(e,"string");return typeof t=="symbol"?t:t+""}function VY(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var qY={top:5,right:5,bottom:5,left:5},QY=WY({accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,layout:"horizontal",margin:qY,responsive:!1,reverseStackOrder:!1,stackOffset:"none",syncMethod:"index"},RO),YY=y.forwardRef(function(t,r){var n,a=Jr(t.categoricalChartProps,QY),o=t.chartName,u=t.defaultTooltipEventType,c=t.validateTooltipEventTypes,f=t.tooltipPayloadSearcher,h=t.categoricalChartProps,m={chartName:o,defaultTooltipEventType:u,validateTooltipEventTypes:c,tooltipPayloadSearcher:f,eventEmitter:void 0};return y.createElement(sY,{preloadedState:{options:m},reduxStoreName:(n=h.id)!==null&&n!==void 0?n:o},y.createElement(_V,{chartData:h.data}),y.createElement(uY,{layout:a.layout,margin:a.margin}),y.createElement(fY,{throttleDelay:a.throttleDelay,throttledEvents:a.throttledEvents}),y.createElement(cY,{baseValue:a.baseValue,accessibilityLayer:a.accessibilityLayer,barCategoryGap:a.barCategoryGap,maxBarSize:a.maxBarSize,stackOffset:a.stackOffset,barGap:a.barGap,barSize:a.barSize,syncId:a.syncId,syncMethod:a.syncMethod,className:a.className,reverseStackOrder:a.reverseStackOrder}),y.createElement(HY,oy({},a,{ref:r})))}),XY=["axis"],ZY=y.forwardRef((e,t)=>y.createElement(YY,{chartName:"AreaChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:XY,tooltipPayloadSearcher:wW,categoricalChartProps:e,ref:t}));const JY="rgba(130,130,150,0.14)",L2="rgba(130,130,150,0.85)";function eX(e){if(e<=0)return 10;const t=Math.pow(10,Math.floor(Math.log10(e))),r=e/t;return(r<=1?1:r<=2?2:r<=5?5:10)*t}function $O(e,t){return`${t==="%"?Math.round(e):e>=1e3?`${(e/1e3).toFixed(1)}k`:Math.round(e).toString()}${t}`}function tX({active:e,payload:t,unit:r}){return!e||!(t!=null&&t.length)?null:l.jsx("div",{className:"rounded-lg border border-border/70 bg-popover/95 px-3 py-2 shadow-xl backdrop-blur",children:l.jsx("div",{className:"space-y-1",children:t.map(n=>l.jsxs("div",{className:"flex items-center gap-2 text-[11px] font-mono",children:[l.jsx("span",{className:"h-2 w-2 rounded-full",style:{background:n.color}}),l.jsx("span",{className:"uppercase tracking-wider text-muted-foreground",children:n.name}),l.jsx("span",{className:"ml-auto pl-3 font-bold tabular-nums text-foreground",children:$O(n.value,r)})]},n.dataKey))})})}function zO({data:e,series:t,unit:r="%",yMode:n="percent",height:a=176}){const o=e.reduce((c,f)=>t.reduce((h,m)=>Math.max(h,Number(f[m.key])||0),c),0),u=n==="percent"?Math.min(100,Math.max(25,Math.ceil(o*1.2/25)*25)):Math.max(eX(o*1.15),10);return l.jsx("div",{style:{height:a},className:"w-full",children:l.jsx(Kz,{width:"100%",height:"100%",children:l.jsxs(ZY,{data:e,margin:{top:8,right:6,bottom:0,left:-12},children:[l.jsx("defs",{children:t.map(c=>l.jsxs("linearGradient",{id:`grad-${c.key}`,x1:"0",y1:"0",x2:"0",y2:"1",children:[l.jsx("stop",{offset:"0%",stopColor:c.color,stopOpacity:.22}),l.jsx("stop",{offset:"100%",stopColor:c.color,stopOpacity:0})]},c.key))}),l.jsx(uO,{vertical:!1,stroke:JY}),l.jsx(kO,{dataKey:"t",hide:!0}),l.jsx(jO,{domain:[0,u],ticks:[0,u/2,u],tickFormatter:c=>$O(c,r),width:42,axisLine:!1,tickLine:!1,tick:{fontSize:10,fill:L2}}),l.jsx(YW,{content:l.jsx(tX,{unit:r}),cursor:{stroke:L2,strokeOpacity:.4,strokeDasharray:"3 3"}}),t.map(c=>l.jsx(bO,{type:"monotone",dataKey:c.key,name:c.label,stroke:c.color,strokeWidth:2,fill:`url(#grad-${c.key})`,dot:!1,activeDot:{r:3,strokeWidth:0},isAnimationActive:!1,connectNulls:!0},c.key))]})})})}const rX=[{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 FO(){var u,c,f,h;const{sys:e,hist:t}=BD(),r=!!(e!=null&&e.gpu&&e.gpu.busy_percent!=null&&e.gpu.gtt_used!=null&&e.gpu.gtt_total!=null),n=rX.filter(m=>m.key!=="gpu"||r),a={cpu:(u=e==null?void 0:e.cpu)==null?void 0:u.percent,ram:(c=e==null?void 0:e.ram)==null?void 0:c.percent,gpu:r?e.gpu.busy_percent:null,disk:(f=e==null?void 0:e.disk)==null?void 0:f.percent},o={cpu:(h=e==null?void 0:e.cpu)!=null&&h.cores?`${e.cpu.cores} Cores`:"",ram:e?`${Yi(e.ram.used)}/${Yi(e.ram.total)} GB`:"",gpu:r?`${Yi(e.gpu.gtt_used)}/${Yi(e.gpu.gtt_total)} GB`:"",disk:e!=null&&e.disk?`${Yi(e.disk.used)}/${Yi(e.disk.total)} GB`:""};return l.jsxs("div",{className:"flex flex-col justify-between rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15",children:[l.jsxs("div",{children:[l.jsxs("div",{className:"mb-3 flex items-center gap-2",children:[l.jsx($n,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"System-Status"}),l.jsxs("span",{className:"ml-1 inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground/70",children:[l.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"})," live"]})]}),e?l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"mb-2 grid grid-cols-2 gap-x-4 gap-y-1.5",children:n.map(m=>l.jsxs("div",{className:"flex min-w-0 items-center gap-1.5",children:[l.jsx("span",{className:"h-2 w-2 shrink-0 rounded-full",style:{background:m.color}}),l.jsx("span",{className:"shrink-0 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",children:m.label}),l.jsxs("span",{className:"shrink-0 font-mono text-xs font-bold tabular-nums text-foreground",children:[Math.round(a[m.key]??0),"%"]}),o[m.key]&&l.jsx("span",{className:"truncate font-mono text-[10px] text-muted-foreground/60",children:o[m.key]})]},m.key))}),l.jsx(zO,{data:t,series:n,unit:"%",yMode:"percent",height:176})]}):l.jsx("div",{className:"flex h-44 items-center justify-center text-xs text-muted-foreground",children:"Lade Systemdaten…"})]}),(e==null?void 0:e.temp)&&(e.temp.cpu||e.temp.gpu)&&l.jsxs("div",{className:"mt-3 flex gap-4 border-t border-border/30 pt-3 font-mono text-xs text-muted-foreground/80",children:[e.temp.cpu!=null&&l.jsxs("span",{children:["CPU Temp: ",e.temp.cpu," °C"]}),e.temp.gpu!=null&&l.jsxs("span",{children:["GPU Temp: ",e.temp.gpu," °C"]})]})]})}function nu({label:e,value:t,tone:r}){return l.jsxs("div",{className:ee("flex items-center justify-between rounded-lg border px-3 py-1.5 text-xs",r==="alert"?"border-amber-500/30 bg-amber-500/5 font-semibold text-amber-400":r==="accent"?"border-primary/30 bg-primary/5 font-semibold text-primary":"border-border/30 bg-background/25 text-muted-foreground"),children:[l.jsx("span",{className:"flex items-center gap-1.5",children:e}),l.jsx("span",{className:"font-mono text-[10px]",children:t})]})}function nX(){var r;const{data:e}=sh(3e3),t=()=>window.dispatchEvent(new CustomEvent("open-system-drawer",{detail:{tab:"maintenance"}}));return l.jsxs("div",{className:"flex flex-col justify-between rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15",children:[l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-2 border-b border-border/20 pb-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(I4,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"Updates & Pflege"})]}),(e==null?void 0:e.last_check)&&l.jsxs("span",{className:"font-mono text-[9px] text-muted-foreground/80",children:["Zuletzt gesucht: ",new Date(e.last_check*1e3).toLocaleString("de-DE",{day:"2-digit",month:"2-digit",hour:"2-digit",minute:"2-digit"})]})]}),e?l.jsxs("div",{className:"space-y-1.5",children:[l.jsx(nu,{label:"OS-Pakete",tone:e.os>0?"alert":"muted",value:e.os>0?`${e.os} verfügbar`:"aktuell"}),l.jsx(nu,{label:"Inferenz-Engine (llama.cpp)",tone:e.engine>0?"alert":"muted",value:e.engine>0?"Update verfügbar":"aktuell"}),l.jsx(nu,{label:"Router (llama-swap)",tone:e.swap>0?"alert":"muted",value:e.swap>0?"Update verfügbar":"aktuell"}),l.jsx(nu,{label:"Modell-Upgrades",tone:e.models>0?"accent":"muted",value:e.models>0?`${e.models} verfügbar`:"aktuell"}),(r=e.components)==null?void 0:r.map(n=>l.jsx(nu,{tone:n.update===!0?"alert":"muted",label:l.jsxs(l.Fragment,{children:[n.name,n.reachable===!1&&l.jsx("span",{className:"text-[8px] font-bold uppercase text-red-400/80",children:"offline"})]}),value:n.update===!0?`Update: ${n.latest}`:n.update===!1?"aktuell":n.latest?`neueste: ${n.latest}`:"—"},n.key))]}):l.jsx("div",{className:"flex h-24 items-center justify-center text-xs text-muted-foreground",children:"Lade Updates..."})]}),l.jsxs("button",{onClick:t,className:"mt-4 flex h-9 w-full items-center justify-center gap-1.5 rounded-lg bg-primary text-xs font-semibold text-primary-foreground shadow-md shadow-primary/10 transition-all hover:opacity-90 cursor-pointer",children:["Updates verwalten & Pflege ",l.jsx(Jf,{className:"h-3.5 w-3.5"})]})]})}function BO({type:e,title:t,message:r,defaultValue:n,autoValue:a,autoLabel:o,onConfirm:u,onCancel:c}){const f=y.useRef(null);return l.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":t,children:l.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:[l.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary",children:t}),l.jsx("button",{onClick:c||(()=>u()),"aria-label":"Schließen",className:"p-1 rounded hover:bg-accent text-muted-foreground hover:text-foreground cursor-pointer",children:l.jsx(zn,{className:"h-4 w-4","aria-hidden":"true"})})]}),l.jsx("p",{className:"text-xs text-muted-foreground leading-relaxed",children:r}),e==="prompt"&&l.jsxs("div",{className:"flex gap-2",children:[l.jsx("input",{ref:f,type:"text",defaultValue:n,"aria-label":t,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:h=>{var m;h.key==="Enter"&&u((m=f.current)==null?void 0:m.value)}}),a!==void 0&&l.jsx("button",{type:"button",onClick:()=>{f.current&&(f.current.value=a)},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:o||"Auto"})]}),l.jsxs("div",{className:"flex justify-end gap-3 pt-2",children:[(e==="confirm"||e==="prompt")&&l.jsx("button",{onClick:c,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"}),l.jsx("button",{onClick:()=>{var m;const h=e==="prompt"?(m=f.current)==null?void 0:m.value:void 0;u(h)},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:e==="confirm"?"Ja, fortfahren":e==="prompt"?"Übernehmen":"OK"})]})]})})}function ya(){const[e,t]=y.useState(null),r=y.useCallback(()=>t(null),[]),n=y.useCallback((c,f,h)=>{t({type:"alert",title:c,message:f,onConfirm:()=>{t(null),h==null||h()}})},[]),a=y.useCallback((c,f,h,m)=>{t({type:"confirm",title:c,message:f,onConfirm:()=>{t(null),h()},onCancel:()=>{t(null),m==null||m()}})},[]),o=y.useCallback((c,f,h,m,g,v)=>{t({type:"prompt",title:c,message:f,defaultValue:h,autoValue:v==null?void 0:v.autoValue,autoLabel:v==null?void 0:v.autoLabel,onConfirm:b=>{t(null),m(b)},onCancel:()=>{t(null),g==null||g()}})},[]),u=e?l.jsx(BO,{...e}):null;return{showAlert:n,showConfirm:a,showPrompt:o,close:r,dialogElement:u}}function iX(){const e=Kn(),{data:t}=jy(3e3),{data:r}=yi(),{showAlert:n,dialogElement:a}=ya(),[o,u]=y.useState(!1),c=(r==null?void 0:r.models)??[];async function f(h){try{await je("/api/agent/brain",{method:"POST",body:JSON.stringify({model:h})}),n("Erfolgreich",`Hermes-Gehirn wurde auf '${h}' geändert. Der Gateway-Dienst wurde neu gestartet.`),e.invalidateQueries({queryKey:Ve.agentStatus}),u(!1)}catch(m){n("Fehler",`Fehler beim Wechseln des Gehirns: ${m.message}`)}}return l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15 flex flex-col justify-between",children:[l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center justify-between mb-4",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(pn,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold tracking-wide uppercase text-foreground",children:"Hermes Agent"})]}),(t==null?void 0:t.terminal_url)&&l.jsxs("a",{href:Ds(t.terminal_url),target:"_blank",rel:"noopener",className:ee("flex items-center gap-1 px-3 py-1 rounded-lg text-xs font-medium transition-all",t.terminal_reachable?"bg-primary text-primary-foreground hover:opacity-90 shadow-md shadow-primary/20":"border border-border text-muted-foreground"),children:[l.jsx(Ms,{className:"h-3 w-3"})," Terminal öffnen"]})]}),t?l.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[l.jsxs("div",{className:"p-3 bg-background/20 rounded-xl border border-border/40",children:[l.jsx("div",{className:"text-[10px] text-muted-foreground uppercase font-semibold",children:"Gateway"}),l.jsxs("div",{className:"flex items-center gap-2 mt-1",children:[l.jsx("span",{className:ee("h-2 w-2 rounded-full",t.gateway_reachable?"bg-emerald-500 animate-pulse":"bg-amber-500")}),l.jsx("span",{className:"text-xs font-medium",children:t.gateway_reachable?"Online":"Offline"})]})]}),l.jsxs("div",{className:"p-3 bg-background/20 rounded-xl border border-border/40",children:[l.jsx("div",{className:"text-[10px] text-muted-foreground uppercase font-semibold",children:"Terminal"}),l.jsxs("div",{className:"flex items-center gap-2 mt-1",children:[l.jsx("span",{className:ee("h-2 w-2 rounded-full",t.terminal_reachable?"bg-emerald-500 animate-pulse":"bg-amber-500")}),l.jsx("span",{className:"text-xs font-medium",children:t.terminal_reachable?"Online":"Offline"})]})]}),l.jsxs("div",{onClick:()=>u(!0),className:"p-3 bg-background/20 rounded-xl border border-border/40 hover:border-primary/45 hover:bg-background/30 transition-all duration-300 cursor-pointer",children:[l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsx("span",{className:"text-[10px] text-muted-foreground uppercase font-semibold",children:"Gehirn"}),l.jsx($n,{className:"h-3 w-3 text-primary"})]}),l.jsxs("div",{className:"text-xs font-medium mt-1 font-mono text-primary truncate flex items-center gap-1",children:[l.jsx(my,{className:"h-3 w-3 shrink-0"}),t.brain_model||"auto"]})]}),l.jsxs("div",{className:"p-3 bg-background/20 rounded-xl border border-border/40",children:[l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsx("span",{className:"text-[10px] text-muted-foreground uppercase font-semibold",children:"Verdrahtung"}),l.jsx(Uu,{className:"h-3 w-3 text-primary"})]}),l.jsxs("div",{className:"text-[10px] font-mono mt-1 space-y-0.5 text-muted-foreground",children:[l.jsxs("div",{children:["Config: ",t.has_config?l.jsx("span",{className:"text-emerald-400",children:"✓"}):"—"]}),l.jsxs("div",{children:["Skills: ",t.has_skills?l.jsx("span",{className:"text-emerald-400",children:"✓"}):"—"]}),l.jsxs("div",{children:["Memory: ",t.has_memories?l.jsx("span",{className:"text-emerald-400",children:"✓"}):"—"]})]})]})]}):l.jsx("div",{className:"h-28 flex items-center justify-center text-xs text-muted-foreground",children:"Lade Agenten-Status…"})]}),t&&l.jsxs("div",{className:"mt-3 border-t border-border/30 pt-3 space-y-1.5",children:[l.jsxs("div",{className:"flex items-center justify-between text-[10px] text-muted-foreground",children:[l.jsx("span",{children:"Telegram"}),l.jsx("span",{className:ee("font-semibold",t.telegram_enabled?"text-emerald-400":""),children:t.telegram_enabled?"aktiv":"nicht konfiguriert"})]}),l.jsxs("div",{className:"flex items-center justify-between text-[10px] text-muted-foreground",children:[l.jsx("span",{children:"MCP-Server"}),l.jsxs("span",{className:"font-semibold text-foreground",children:[t.mcp_server_count??0," verbunden"]})]}),l.jsxs("div",{className:"flex items-center justify-between text-[10px] text-muted-foreground",children:[l.jsx("span",{children:"PC Executor"}),l.jsx("span",{className:ee("font-semibold",t.pc_executor_reachable?"text-emerald-400":""),children:t.pc_executor_reachable?"erreichbar":"nicht verbunden"})]})]}),t&&o&&l.jsx("div",{className:"fixed inset-0 z-50 bg-black/60 backdrop-blur-sm flex items-center justify-center p-4",children:l.jsxs("div",{className:"w-full max-w-md 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:[l.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[l.jsxs("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary flex items-center gap-1.5",children:[l.jsx($n,{className:"h-4 w-4"}),l.jsx("span",{children:"Hermes-Gehirn konfigurieren"})]}),l.jsx("button",{onClick:()=>u(!1),className:"p-1 rounded hover:bg-accent text-muted-foreground hover:text-foreground cursor-pointer",children:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsxs("p",{className:"text-xs text-muted-foreground leading-relaxed",children:['Das „Gehirn" ist das primäre LLM für Hermes. Wähle ein Modell aus deiner Bibliothek oder nutze ein Gateway-Alias (',l.jsx("code",{className:"text-primary font-semibold",children:"auto"})," / ",l.jsx("code",{className:"text-primary font-semibold",children:"fast"})," / ",l.jsx("code",{className:"text-primary font-semibold",children:"heavy"}),"):"]}),l.jsx("div",{className:"space-y-1.5 max-h-60 overflow-y-auto pr-1",children:["auto","fast","heavy",...c.map(h=>{var m;return((m=h.name.split("/").pop())==null?void 0:m.replace(".gguf",""))||h.name})].map(h=>{const m=["auto","fast","heavy"].includes(h);return l.jsxs("button",{onClick:()=>f(h),className:ee("w-full text-left px-3 py-2.5 rounded-lg text-xs hover:bg-accent flex items-center justify-between font-mono cursor-pointer border border-border/30",t.brain_model===h||!t.brain_model&&h==="auto"?"text-primary font-bold bg-primary/10 border-primary/30":"text-foreground bg-background/20"),children:[l.jsxs("div",{className:"flex flex-col text-left",children:[l.jsx("span",{className:"font-semibold truncate max-w-[280px]",children:h}),l.jsx("span",{className:"text-[9px] text-muted-foreground mt-0.5",children:m?"Gateway Routing Alias":"Installiertes GGUF Modell"})]}),(t.brain_model===h||!t.brain_model&&h==="auto")&&l.jsx(or,{className:"h-4 w-4 shrink-0 text-primary"})]},h)})})]})}),a]})}function aX(){const e=Kn(),{data:t=[]}=lv({limit:3}),[r,n]=y.useState(""),[a,o]=y.useState("stable"),[u,c]=y.useState(!1);async function f(){if(!(!r.trim()||u)){c(!0);try{await je("/api/memory",{method:"POST",body:JSON.stringify({content:r,category:a,source:"dashboard"})}),n(""),e.invalidateQueries({queryKey:["memory"]})}catch(h){console.error(h)}finally{c(!1)}}}return l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15 flex flex-col justify-between",children:[l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[l.jsx(vo,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold tracking-wide uppercase text-foreground",children:"Gedächtnis"})]}),l.jsxs("div",{className:"space-y-3",children:[l.jsx("textarea",{value:r,onChange:h=>n(h.target.value),"aria-label":"Fakt oder Regel im Gedächtnis speichern",placeholder:"Fakt / Regel im Pool speichern…",rows:2,className:"w-full resize-none rounded-xl border border-border/50 bg-background/30 p-2 text-[10px] outline-none focus:ring-1 focus:ring-primary transition-all leading-normal"}),l.jsxs("div",{className:"flex items-center gap-2 justify-between",children:[l.jsxs("select",{value:a,onChange:h=>o(h.target.value),"aria-label":"Kategorie",className:"h-7 rounded-lg border border-border/50 bg-background/50 px-2 text-[10px] outline-none cursor-pointer",children:[l.jsx("option",{value:"stable",children:"🔵 Fakt"}),l.jsx("option",{value:"instruction",children:"📋 Regel"}),l.jsx("option",{value:"user",children:"👤 User"}),l.jsx("option",{value:"versioned",children:"🟡 Version"})]}),l.jsxs("button",{onClick:f,disabled:!r.trim()||u,className:"flex h-7 items-center gap-1 rounded-lg bg-primary px-3 text-[10px] font-semibold text-primary-foreground hover:opacity-90 disabled:opacity-50 transition-all cursor-pointer",children:[l.jsx(ef,{className:"h-3.5 w-3.5"})," Speichern"]})]})]}),l.jsxs("div",{className:"mt-3.5 space-y-1.5",children:[l.jsx("div",{className:"text-[9px] text-muted-foreground uppercase font-bold tracking-wider",children:"Zuletzt gespeichert:"}),l.jsx("div",{className:"max-h-20 overflow-y-auto space-y-1 pr-1 scrollbar-thin",children:t.length===0?l.jsx("div",{className:"text-[10px] text-muted-foreground/75 py-1",children:"Keine Einträge vorhanden."}):t.map(h=>l.jsxs("div",{className:"text-[10px] bg-background/10 border border-border/30 rounded p-1.5 flex items-start gap-1.5",children:[l.jsx("span",{className:"shrink-0 text-[8px] font-mono text-muted-foreground/80 px-1 py-0.5 rounded bg-muted/20",children:h.category}),l.jsx("span",{className:"truncate flex-1 text-muted-foreground hover:text-foreground transition-colors",title:h.content,children:h.content})]},h.id))})]})]}),l.jsx("div",{className:"mt-4 text-[10px] text-muted-foreground/80 border-t border-border/30 pt-3",children:"Steht allen Clients per MCP zur Verfügung."})]})}const $2=[{key:"prompt",label:"Prompt",color:"#f59e0b"},{key:"completion",label:"Antwort",color:"#2dd4bf"}];function UO(){const{data:e}=ky(3e3),t=zD(),r=t[t.length-1],n=r?Math.round(r.prompt+r.completion):0;return l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15",children:[l.jsxs("div",{className:"mb-3 flex items-start justify-between gap-3",children:[l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Zf,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"Token-Durchsatz"}),l.jsxs("span",{className:"ml-1 inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground/70",children:[l.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"})," live"]})]}),e&&l.jsxs("div",{className:"mt-2 flex items-baseline gap-2",children:[l.jsx("span",{className:"font-space text-3xl font-bold tracking-tight text-foreground tabular-nums",children:n.toLocaleString("de-DE")}),l.jsx("span",{className:"text-xs text-muted-foreground",children:"tok/s aktuell"})]}),e&&l.jsxs("div",{className:"mt-0.5 space-y-0.5 font-mono text-[11px] text-muted-foreground/70",children:[l.jsxs("div",{children:[e.total_tokens.toLocaleString("de-DE")," Tokens gesamt · ",l.jsxs("span",{className:"text-emerald-400/90",children:[e.saved_eur.toLocaleString("de-DE",{minimumFractionDigits:2})," € gespart"]})]}),l.jsxs("div",{className:"text-muted-foreground/55",children:["Input ",e.prompt_tokens.toLocaleString("de-DE")," · Output ",e.completion_tokens.toLocaleString("de-DE")]})]})]}),l.jsx("div",{className:"flex shrink-0 flex-col items-end gap-1.5 pt-1",children:$2.map(a=>l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsx("span",{className:"h-2 w-2 rounded-full",style:{background:a.color}}),l.jsx("span",{className:"text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",children:a.label}),l.jsx("span",{className:"font-mono text-xs font-bold tabular-nums text-foreground",children:Math.round((r==null?void 0:r[a.key])??0)})]},a.key))})]}),e?l.jsx(zO,{data:t,series:$2,unit:" tok/s",yMode:"auto",height:150}):l.jsx("div",{className:"flex h-[150px] items-center justify-center text-xs text-muted-foreground",children:"Lade Durchsatz…"}),l.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."})]})}function oX(){const{data:e}=SE(3e3),{showAlert:t,dialogElement:r}=ya(),[n,a]=y.useState({});async function o(u){a(c=>({...c,[u]:!0}));try{const c=await je("/api/maintenance/restart",{method:"POST",body:JSON.stringify({service:u})});c.ok||t("Fehler",`Neustart fehlgeschlagen: ${c.err||"Unbekannt"}`)}catch(c){t("Fehler",`Fehler: ${c.message}`)}finally{a(c=>({...c,[u]:!1}))}}return l.jsxs("div",{className:"flex flex-col rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15",children:[l.jsxs("div",{className:"mb-3 flex items-center justify-between",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(th,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold uppercase tracking-wide text-foreground",children:"Dienste"})]}),l.jsx("button",{onClick:()=>window.dispatchEvent(new CustomEvent("open-system-drawer",{detail:{tab:"logs"}})),className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground transition-colors hover:text-primary cursor-pointer",children:"Logs / Pflege"})]}),e?l.jsxs("div",{className:"flex flex-1 flex-col",children:[l.jsx("div",{className:"space-y-1.5",children:e.services.map(u=>l.jsxs("div",{className:"group flex items-center justify-between gap-2 rounded-xl border border-border/30 bg-background/20 p-2.5",children:[l.jsxs("div",{className:"flex min-w-0 items-center gap-2",children:[l.jsx("span",{className:ee("h-2.5 w-2.5 shrink-0 rounded-full ring-2 ring-black/40",u.ok?"bg-emerald-500":"bg-amber-500")}),l.jsxs("div",{className:"min-w-0",children:[l.jsx("div",{className:"truncate text-xs font-bold text-foreground",children:u.name}),l.jsx("div",{className:"truncate font-mono text-[9px] text-muted-foreground/60",children:u.url})]})]}),l.jsx("button",{onClick:()=>o(u.unit),disabled:n[u.unit],className:"flex h-7 w-7 shrink-0 items-center justify-center rounded-lg border border-border/40 text-muted-foreground opacity-0 transition-all hover:bg-primary/5 hover:text-primary group-hover:opacity-100",title:"Dienst neu starten",children:l.jsx(ro,{className:ee("h-3.5 w-3.5",n[u.unit]&&"animate-spin")})})]},u.unit))}),l.jsxs("div",{className:"mt-auto flex flex-wrap gap-3 border-t border-border/20 pt-2.5 text-[10px] font-semibold text-muted-foreground",children:[l.jsxs("a",{href:Ds(e.links.engine_ui),target:"_blank",rel:"noopener",className:"flex items-center gap-1 rounded px-1.5 py-0.5 text-primary transition-colors hover:bg-primary/10",children:[l.jsx(Ms,{className:"h-3 w-3"})," Engine"]}),l.jsxs("a",{href:Ds(e.links.gateway),target:"_blank",rel:"noopener",className:"flex items-center gap-1 rounded px-1.5 py-0.5 text-primary transition-colors hover:bg-primary/10",children:[l.jsx(Ms,{className:"h-3 w-3"})," Gateway"]})]})]}):l.jsx("div",{className:"flex h-24 items-center justify-center text-xs text-muted-foreground",children:"Lade Dienste…"}),r]})}const HO=[{role:"hermes",label:"Lucys Hirn",short:"Hirn",icon:vo,desc:"Lucys Alltags-Verstand — denkt und redet mit dir. Immer bereit.",tone:"bg-indigo-500/15 text-indigo-400 border-indigo-500/25",protected:!0},{role:"embed",label:"Lucys Gedächtnis",short:"Gedächtnis",icon:NN,desc:"Merkt sich Wichtiges und findet es später wieder.",tone:"bg-emerald-500/15 text-emerald-400 border-emerald-500/25",protected:!0},{role:"vision",label:"Lucys Augen",short:"Augen",icon:vu,desc:"Sieht Bilder und Screenshots und beschreibt, was drauf ist.",tone:"bg-pink-500/15 text-pink-400 border-pink-500/25"},{role:"heavy",label:"Großes Hirn",short:"Groß",icon:YM,desc:"Das schwere Geschütz — wird für besonders knifflige Fragen dazugeholt.",tone:"bg-amber-500/15 text-amber-400 border-amber-500/25"},{role:"coder-lite",label:"Programmierer (schnell)",short:"Code schnell",icon:Os,desc:"Schnelles Programmieren im Alltag.",tone:"bg-violet-500/15 text-violet-400 border-violet-500/25"},{role:"coder",label:"Programmierer (gründlich)",short:"Code gründlich",icon:Os,desc:"Schreibt und prüft Code besonders sorgfältig — für schwere Coding-Aufgaben.",tone:"bg-fuchsia-500/15 text-fuchsia-400 border-fuchsia-500/25"},{role:"scout",label:"Späher",short:"Späher",icon:$4,desc:"Schneller erster Blick und grobe Einschätzung.",tone:"bg-teal-500/15 text-teal-400 border-teal-500/25"}],WO=HO.map(e=>e.role),z2=Object.fromEntries(HO.map(e=>[e.role,e])),F2=e=>({role:e||"?",label:e||"unbekannt",short:e||"?",icon:vo,desc:"Rolle ohne hinterlegten Klartext-Namen.",tone:"bg-slate-500/15 text-slate-300 border-slate-500/25"}),sX={fast:"hermes",coder_lite:"coder-lite"};function ir(e){return e&&(z2[e]||z2[sX[e]])||F2(e)}function oo({role:e,dense:t=!1,className:r}){const n=ir(e),a=n.icon;return l.jsxs("span",{className:ee("inline-flex items-center gap-1 rounded px-1.5 py-0.5 text-[10px] font-semibold border tracking-wide",n.tone,r),title:`${n.desc} (${n.role})`,children:[l.jsx(a,{className:"h-3 w-3 shrink-0","aria-hidden":"true"}),t?n.short:n.label]})}function lX({fit:e}){const t={perfect:"bg-emerald-500/15 text-emerald-400 border border-emerald-500/20",marginal:"bg-amber-500/15 text-amber-400 border border-amber-500/20",too_tight:"bg-red-500/15 text-red-400 border border-red-500/20"}[e.level];return l.jsxs("span",{className:ee("rounded px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wider font-mono",t),children:[e.text," • ",e.req_gb," GB RAM"]})}function B2(e){const t=e.toLowerCase();return t.includes("qwen")?{name:"Qwen",color:"bg-purple-500/20 text-purple-300 border-purple-500/30",initial:"Q"}:t.includes("gemma")?{name:"Gemma",color:"bg-blue-500/20 text-blue-300 border-blue-500/30",initial:"G"}:t.includes("llama")?{name:"Llama",color:"bg-red-500/20 text-red-300 border-red-500/30",initial:"🦙"}:t.includes("mistral")||t.includes("mixtral")?{name:"Mistral",color:"bg-orange-500/20 text-orange-300 border-orange-500/30",initial:"M"}:t.includes("deepseek")?{name:"DeepSeek",color:"bg-cyan-500/20 text-cyan-300 border-cyan-500/30",initial:"D"}:t.includes("hermes")||t.includes("nous")?{name:"Hermes",color:"bg-amber-500/20 text-amber-300 border-amber-500/30",initial:"H"}:t.includes("phi")?{name:"Phi",color:"bg-emerald-500/20 text-emerald-300 border-emerald-500/30",initial:"Φ"}:{name:"Other",color:"bg-slate-500/20 text-slate-300 border-slate-500/30",initial:"AI"}}function uX(){var b,j,k;const{data:e}=yi(2e3),{data:t}=ky(2e3),{data:r}=xo(),n=(e==null?void 0:e.models)??[],a=(e==null?void 0:e.running)??[],o=((b=r==null?void 0:r.gpu)==null?void 0:b.gtt_total)||((j=r==null?void 0:r.gpu)==null?void 0:j.vram_total)||0,u=((k=r==null?void 0:r.gpu)==null?void 0:k.gtt_used)||0,c=o>0?Math.min(100,u/o*100):0,f=c>=88?"bg-red-500":c>=70?"bg-amber-500":"bg-teal-500",h=c>=88?"text-red-400":c>=70?"text-amber-400":"text-foreground",m=y.useRef(null),[g,v]=y.useState(!1);return y.useEffect(()=>{if(!t)return;const S=t.total_tokens;if(m.current!==null&&S>m.current){v(!0);const N=setTimeout(()=>v(!1),4e3);return m.current=S,()=>clearTimeout(N)}m.current=S},[t==null?void 0:t.total_tokens]),l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/15 flex flex-col",children:[l.jsxs("div",{className:"flex items-center justify-between mb-4",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Zd,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold tracking-wide uppercase text-foreground",children:"Modelle"})]}),l.jsxs("span",{className:ee("flex items-center gap-1.5 text-[10px] font-bold uppercase tracking-wider font-mono px-2 py-0.5 rounded-full border transition-colors",g?"bg-emerald-500/10 text-emerald-400 border-emerald-500/30":"bg-background/30 text-muted-foreground/70 border-border/40"),children:[g?l.jsx(ha,{className:"h-3 w-3 animate-pulse"}):l.jsx(S4,{className:"h-3 w-3"}),g?"Inferenz aktiv":"Idle"]})]}),o>0&&l.jsxs("div",{className:"mb-4",children:[l.jsxs("div",{className:"flex items-center justify-between text-[10px] font-mono text-muted-foreground/80 mb-1",children:[l.jsx("span",{className:"uppercase tracking-wider font-semibold",children:"Speicher-Pool"}),l.jsxs("span",{children:[l.jsx("span",{className:ee("font-bold",h),children:Yi(u)})," / ",Yi(o)," GB belegt"]})]}),l.jsx("div",{className:"h-1.5 w-full rounded-full bg-background/50 border border-border/30 overflow-hidden",children:l.jsx("div",{className:ee("h-full rounded-full transition-all duration-500",f),style:{width:`${c}%`}})})]}),l.jsx("div",{className:"space-y-2 flex-1",children:WO.map(S=>{var A;const N=n.find(P=>P.role===S),E=N?a.includes(N.name):!1;return l.jsxs("div",{className:ee("flex items-center justify-between gap-2 p-2 rounded-xl border transition-all duration-300",E?"border-emerald-500/30 bg-emerald-500/5 shadow-sm shadow-emerald-500/5":N?"border-primary/20 bg-primary/5":"border-border/30 bg-background/10 opacity-60"),children:[l.jsxs("div",{className:"flex items-center gap-2 min-w-0",children:[l.jsx(oo,{role:S,className:"shrink-0"}),l.jsxs("div",{className:"flex flex-col min-w-0",children:[l.jsx("span",{className:"text-xs font-semibold truncate font-mono text-foreground",children:N?(A=N.name.split("/").pop())==null?void 0:A.replace(/\.gguf$/i,""):"nicht zugewiesen"}),N&&l.jsxs("div",{className:"flex gap-1 items-center mt-0.5 flex-wrap text-muted-foreground/70",children:[l.jsx("span",{className:"text-[9px] font-mono",children:_r(N.size_bytes)}),N.prompt_cache&&l.jsx("span",{className:"text-[7px] leading-none font-mono font-bold bg-cyan-500/10 text-cyan-400 border border-cyan-500/20 px-1 py-0.5 rounded",title:"Prompt Caching aktiv",children:"PC"}),N.spec_active&&l.jsx("span",{className:"text-[7px] leading-none font-mono font-bold bg-emerald-500/10 text-emerald-400 border border-emerald-500/20 px-1 py-0.5 rounded",title:`Speculative Decoding aktiv (Draft: ${N.spec_draft_model})`,children:"SPEC"}),N.parallel_slots>1&&l.jsxs("span",{className:"text-[7px] leading-none font-mono font-bold bg-violet-500/10 text-violet-400 border border-violet-500/20 px-1 py-0.5 rounded",title:`${N.parallel_slots} parallele Slots aktiv`,children:["SLOTS: ",N.parallel_slots]}),N.incomplete&&l.jsx("span",{className:"text-[7px] leading-none font-mono font-bold bg-amber-500/10 text-amber-400 border border-amber-500/20 px-1 py-0.5 rounded",title:"GGUF-Datei fehlt",children:"⚠ fehlt"})]})]})]}),l.jsx("span",{className:"shrink-0",children:N?E?l.jsxs("span",{className:"flex items-center gap-1 text-[8px] font-semibold text-emerald-400 uppercase tracking-wider font-mono",children:[l.jsx("span",{className:ee("h-1.5 w-1.5 rounded-full bg-emerald-500",g&&"animate-pulse")})," warm"]}):l.jsx("span",{className:"text-[8px] font-semibold text-muted-foreground uppercase tracking-wider font-mono",children:"bereit"}):l.jsx("span",{className:"text-[8px] font-semibold text-muted-foreground/60 uppercase tracking-wider font-mono",children:"—"})})]},S)})}),l.jsx("div",{className:"mt-4 text-[10px] text-muted-foreground/80 border-t border-border/30 pt-3",children:"Laden erfolgt automatisch per Auto-Swap. Details & Routing im Modell-Manager."})]})}function cX(){var P,_,O,D,B,F;const{data:e}=wy(),{data:t}=SE(),{data:r}=yi(),{data:n}=xo(),a=!!e&&!!t,o=z=>{var Y;return(Y=t==null?void 0:t.services.find(U=>U.name.toLowerCase().includes(z)))==null?void 0:Y.ok},u=e==null?void 0:e.engine_reachable,c=(P=e==null?void 0:e.brain)==null?void 0:P.ready,f=((_=e==null?void 0:e.brain)==null?void 0:_.model)||((O=r==null?void 0:r.models.find(z=>z.role==="hermes"))==null?void 0:O.name)||"",h=[];h.push((()=>{const z={id:"brain",label:"Lucys Hirn",icon:vo,critical:!0};return a?u===!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}}:c===!1?{...z,status:"down",detail:"Lucys Hirn ist gerade eingeschlafen — einmal aufwecken.",repair:f?{kind:"loadModel",model:f,label:"Hirn aufwecken"}:void 0}:{...z,status:"ok",detail:"Wach und ansprechbar."}:{...z,status:"loading",detail:"Wird geprüft …"}})()),h.push((()=>{const z={id:"vision",label:"Lucys Augen",icon:vu,critical:!1};if(!a||!r)return{...z,status:"loading",detail:"Wird geprüft …"};const Y=r.models.find(he=>he.role==="vision");return Y?(r.running??[]).includes(Y.name)?{...z,status:"ok",detail:"Sieht Bildschirm und Bilder."}:{...z,status:"warn",detail:"Lucys Augen sind eingeschlafen — das erste Bild-Ansehen dauert dann kurz.",repair:{kind:"loadModel",model:Y.name,label:"Augen aufwecken"}}:{...z,status:"warn",detail:"Kein Augen-Modell eingerichtet — Lucy kann keine Bilder ansehen."}})()),h.push((()=>{const z={id:"memory",label:"Lucys Gedächtnis",icon:NN,critical:!0},Y=o("mem0");return!a||Y===void 0?{...z,status:"loading",detail:"Wird geprüft …"}:Y?{...z,status:"ok",detail:"Merkt sich Neues und findet Altes wieder."}:{...z,status:"down",detail:"Lucy kann sich gerade nichts merken — das Gedächtnis antwortet nicht.",repair:{kind:"restart",service:"mem0-service",label:"Gedächtnis neu starten"}}})()),h.push((()=>{const z={id:"gateway",label:"Verbindung (Gateway)",icon:Jd,critical:!0},Y=e?e.gateway_reachable:o("integriert");return!a||Y===void 0?{...z,status:"loading",detail:"Wird geprüft …"}:Y?{...z,status:"ok",detail:"Apps und IDEs können Lucy erreichen."}:{...z,status:"down",detail:"Die Verbindungs-Zentrale antwortet nicht — Apps erreichen Lucy nicht.",repair:{kind:"restart",service:"mission-control-2",label:"Zentrale neu starten"}}})()),h.push((()=>{const z={id:"agent",label:"Lucys Agent (Hermes)",icon:pn,critical:!0},Y=o("hermes-gateway");return!a||Y===void 0?{...z,status:"loading",detail:"Wird geprüft …"}:Y?{...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"}}})()),h.push((()=>{const z={id:"voice",label:"Lucys Stimme",icon:j4,critical:!1},Y=o("voice");return!a||Y===void 0?{...z,status:"loading",detail:"Wird geprüft …"}:Y?{...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 m=((D=n==null?void 0:n.gpu)==null?void 0:D.gtt_total)||((B=n==null?void 0:n.gpu)==null?void 0:B.vram_total)||0,g=((F=n==null?void 0:n.gpu)==null?void 0:F.gtt_used)||0,v=m>0?Math.min(100,g/m*100):0,b=1024**3,j=m?v>=90?{status:"full",usedGb:g/b,totalGb:m/b,pct:v,text:"Speicher fast voll — Lucy könnte langsamer werden."}:v>=72?{status:"warn",usedGb:g/b,totalGb:m/b,pct:v,text:"Speicher gut gefüllt — noch okay."}:{status:"ok",usedGb:g/b,totalGb:m/b,pct:v,text:"Genug Speicher frei."}:{status:"unknown",usedGb:0,totalGb:0,pct:0,text:"Speicher-Auslastung unbekannt."},k=h.some(z=>z.status==="loading"),S=h.filter(z=>z.critical&&z.status==="down"),N=h.filter(z=>z.status==="warn"||!z.critical&&z.status==="down"),E=j.status==="full";return{verdict:k&&!S.length?"loading":S.length?"problem":N.length||E?"warn":"gut",checks:h,memory:j,problems:S}}const dX={ok:"bg-emerald-500",warn:"bg-amber-500",down:"bg-red-500",loading:"bg-muted-foreground/40"};function KO({frame:e="lucy"}={}){const{verdict:t,checks:r,memory:n,problems:a}=cX(),{showAlert:o,dialogElement:u}=ya(),c=Kn(),[f,h]=y.useState({});async function m(S,N){h(E=>({...E,[S]:!0}));try{if(N.kind==="loadModel")await je(`/api/models/${encodeURIComponent(N.model)}/load`,{method:"POST"});else{const E=await je("/api/maintenance/restart",{method:"POST",body:JSON.stringify({service:N.service})});E.ok||o("Reparatur nicht ganz geklappt",(E.err||"Unbekannter Fehler")+(N.needsSudo?`
|
||
|
||
Tipp: Dafür wird evtl. das Box-Passwort gebraucht (oben rechts hinterlegen).`:""))}c.invalidateQueries({queryKey:Ve.health}),c.invalidateQueries({queryKey:Ve.services}),c.invalidateQueries({queryKey:Ve.models})}catch(E){o("Reparatur fehlgeschlagen",String((E==null?void 0:E.message)||E))}finally{h(E=>({...E,[S]:!1}))}}const g=e==="box"?{loading:"Box wird geprüft …",gut:"Alles okay",warn:"Kleinigkeit an der Box",problem:"Box braucht Hilfe"}:{loading:"Lucy wird geprüft …",gut:"Lucy geht's gut 💚",warn:"Kleinigkeit bei Lucy",problem:"Lucy braucht Hilfe"},v={loading:{ring:"border-border/60 bg-card/45",icon:eh,iconCls:"text-muted-foreground animate-spin",title:g.loading,sub:"Einen Moment, ich schaue nach dem Rechten."},gut:{ring:"border-emerald-500/40 bg-emerald-500/5",icon:f4,iconCls:"text-emerald-400",title:g.gut,sub:"Alle wichtigen Fähigkeiten laufen."},warn:{ring:"border-amber-500/40 bg-amber-500/5",icon:gn,iconCls:"text-amber-400",title:g.warn,sub:"Nichts Schlimmes — nur ein Hinweis."},problem:{ring:"border-red-500/50 bg-red-500/5",icon:gn,iconCls:"text-red-400",title:g.problem,sub:`${a.length} wichtige${a.length===1?"s":""} Problem${a.length===1?"":"e"} gefunden.`}}[t],b=v.icon,j={ok:"bg-emerald-500",warn:"bg-amber-500",full:"bg-red-500",unknown:"bg-muted-foreground/40"}[n.status],k={ok:"text-emerald-400",warn:"text-amber-400",full:"text-red-400",unknown:"text-muted-foreground"}[n.status];return l.jsxs("div",{className:ee("rounded-2xl border p-5 shadow-lg shadow-black/15 backdrop-blur-md transition-colors",v.ring),children:[l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"flex h-11 w-11 shrink-0 items-center justify-center rounded-xl border border-border/40 bg-background/30",children:l.jsx(b,{className:ee("h-6 w-6",v.iconCls)})}),l.jsxs("div",{className:"min-w-0",children:[l.jsx("h2",{className:"text-base font-bold tracking-tight text-foreground",children:v.title}),l.jsx("p",{className:"text-xs text-muted-foreground",children:v.sub})]})]}),l.jsxs("div",{className:"mt-4 rounded-xl border border-border/30 bg-background/20 p-3",children:[l.jsxs("div",{className:"mb-1.5 flex items-center justify-between text-[11px]",children:[l.jsxs("span",{className:"flex items-center gap-1.5 font-semibold uppercase tracking-wider text-muted-foreground",children:[l.jsx(cu,{className:"h-3.5 w-3.5"})," Speicher"]}),l.jsx("span",{className:ee("font-mono font-bold",k),children:n.status==="unknown"?"—":`${n.usedGb.toFixed(0)} / ${n.totalGb.toFixed(0)} GB`})]}),l.jsx("div",{className:"h-2 w-full overflow-hidden rounded-full border border-border/30 bg-background/50",children:l.jsx("div",{className:ee("h-full rounded-full transition-all duration-500",j),style:{width:`${n.pct}%`}})}),l.jsx("p",{className:ee("mt-1.5 text-[11px]",k),children:n.text})]}),l.jsx("div",{className:"mt-4 space-y-1.5",children:r.map(S=>l.jsx(fX,{c:S,busy:!!f[S.id],onRepair:()=>S.repair&&m(S.id,S.repair)},S.id))}),u]})}function fX({c:e,busy:t,onRepair:r}){const n=e.icon,a=e.status==="down"||e.status==="warn";return l.jsxs("div",{className:ee("flex items-center justify-between gap-3 rounded-xl border p-2.5 transition-colors",e.status==="down"?"border-red-500/25 bg-red-500/5":e.status==="warn"?"border-amber-500/20 bg-amber-500/5":"border-border/30 bg-background/15"),children:[l.jsxs("div",{className:"flex min-w-0 items-center gap-2.5",children:[l.jsxs("span",{className:"relative flex h-8 w-8 shrink-0 items-center justify-center rounded-lg border border-border/40 bg-background/30 text-foreground/80",children:[l.jsx(n,{className:"h-4 w-4"}),l.jsx("span",{className:ee("absolute -right-0.5 -top-0.5 h-2.5 w-2.5 rounded-full ring-2 ring-black/40",dX[e.status],e.status==="down"&&"animate-pulse")})]}),l.jsxs("div",{className:"min-w-0",children:[l.jsxs("div",{className:"flex items-center gap-1.5 text-xs font-bold text-foreground",children:[e.label,e.status==="ok"&&l.jsx(or,{className:"h-3 w-3 text-emerald-400"}),!e.critical&&l.jsx("span",{className:"rounded bg-background/40 px-1 py-0.5 text-[8px] font-semibold uppercase tracking-wider text-muted-foreground/60",children:"optional"})]}),l.jsx("div",{className:"truncate text-[11px] text-muted-foreground",children:e.detail})]})]}),a&&e.repair&&l.jsxs("button",{onClick:r,disabled:t,className:ee("flex h-8 shrink-0 items-center gap-1.5 rounded-lg border px-2.5 text-[10px] font-bold uppercase tracking-wide transition-all cursor-pointer disabled:opacity-60",e.status==="down"?"border-red-500/40 bg-red-500/10 text-red-300 hover:bg-red-500/20":"border-amber-500/40 bg-amber-500/10 text-amber-300 hover:bg-amber-500/20"),title:e.repair.label,children:[t?l.jsx(eh,{className:"h-3.5 w-3.5 animate-spin"}):l.jsx(Uu,{className:"h-3.5 w-3.5"}),e.repair.label]}),a&&!e.repair&&l.jsxs("span",{className:"flex shrink-0 items-center gap-1 text-[10px] font-semibold text-muted-foreground",title:"Keine Auto-Reparatur bekannt",children:[l.jsx(T4,{className:"h-3.5 w-3.5"})," manuell"]})]})}function U2({children:e}){return l.jsx("p",{className:"mb-2 ml-0.5 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground/60",children:e})}function hX(){return l.jsxs("div",{className:"space-y-7",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Zentrale"}),l.jsx("p",{className:"text-sm text-muted-foreground",children:"Aktueller Status von System, Modellen und Agent."})]}),l.jsx(KO,{}),l.jsxs("div",{className:"grid items-stretch gap-6 lg:grid-cols-3",children:[l.jsx(FO,{}),l.jsx(UO,{}),l.jsx(uX,{})]}),l.jsxs("section",{children:[l.jsx(U2,{children:"Stack & Telemetrie"}),l.jsx(oX,{})]}),l.jsxs("section",{children:[l.jsx(U2,{children:"Betrieb & Wissen"}),l.jsxs("div",{className:"grid gap-6 md:grid-cols-3",children:[l.jsx(nX,{}),l.jsx(iX,{}),l.jsx(aX,{})]})]})]})}function mX(){const e=Kn(),{data:t=[]}=_D(2e3),{showAlert:r,dialogElement:n}=ya();async function a(c){try{await je(`/api/jobs/${c}/cancel`,{method:"POST"}),e.invalidateQueries({queryKey:Ve.jobs})}catch(f){r("Fehler",f.message)}}const o=t.filter(c=>c.state==="running"||c.state==="queued"),u=t.filter(c=>c.state!=="running"&&c.state!=="queued").slice(-3);return o.length===0&&u.length===0?null:l.jsxs("div",{className:"space-y-3 rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-4 shadow-lg shadow-black/10",children:[l.jsx("div",{className:"text-[11px] font-semibold text-muted-foreground uppercase tracking-wider",children:"Aktive Downloads"}),o.map(c=>l.jsxs("div",{className:"space-y-1.5 p-3 rounded-xl bg-background/20 border border-border/40",children:[l.jsxs("div",{className:"flex justify-between items-center text-xs",children:[l.jsx("span",{className:"font-semibold truncate max-w-[250px]",children:c.label}),l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsxs("span",{className:"text-muted-foreground font-mono",children:[c.progress??0,"% • ",fv(c.done_bytes),"/",fv(c.total_bytes),c.eta_s?` • ETA ${UD(c.eta_s)}`:""]}),l.jsx("button",{onClick:()=>a(c.id),className:"text-[10px] text-red-400 hover:text-red-300 font-semibold border border-red-500/25 bg-red-500/5 px-2 py-0.5 rounded transition-all cursor-pointer",children:"Abbrechen"})]})]}),l.jsx("div",{className:"h-1.5 overflow-hidden rounded-full bg-muted",children:l.jsx("div",{className:"h-full rounded-full bg-primary transition-all duration-500",style:{width:`${c.progress??0}%`}})})]},c.id)),u.map(c=>l.jsxs("div",{className:"flex justify-between items-center text-xs text-muted-foreground px-1",children:[l.jsx("span",{className:"truncate",children:c.label}),l.jsx("span",{className:ee("font-semibold text-[10px] px-1.5 py-0.5 rounded uppercase font-mono",c.state==="done"?"bg-emerald-500/10 text-emerald-400":"bg-amber-500/10 text-amber-400"),children:c.state})]},c.id)),n]})}function Ra({children:e,tone:t="muted"}){const r={muted:"bg-muted text-muted-foreground",primary:"bg-primary/15 text-primary",warn:"bg-amber-500/15 text-amber-500"};return l.jsx("span",{className:`rounded px-1.5 py-0.5 text-[11px] font-medium ${r[t]}`,children:e})}function H2({caps:e}){return e?l.jsxs("span",{className:"inline-flex flex-wrap gap-1",children:[e.coder&&l.jsx(Ra,{children:"💻 Code"}),e.vision&&l.jsx(Ra,{children:"👁 Bild"}),e.reasoning&&l.jsx(Ra,{children:"🧠 Reason"}),e.moe&&l.jsxs(Ra,{tone:"primary",children:["🧩 MoE",e.active_b?`·${e.active_b}b`:""]}),e.tools==="yes"&&l.jsx(Ra,{tone:"primary",children:"🛠 Tools"}),e.tools==="likely"&&l.jsx(Ra,{tone:"warn",children:"🛠 Tools?"}),e.embedding&&l.jsx(Ra,{children:"🔢 Embed"})]}):null}function pX({model:e,onClose:t,onChanged:r}){var k,S;const{data:n,isLoading:a}=ID(e.gguf_path),[o,u]=y.useState(null),[c,f]=y.useState(""),h=n==null?void 0:n.target_vocab,m=(n==null?void 0:n.drafts)??[],g=m.filter(N=>N.compatible===!0),v=e.spec_draft_model;async function b(N){u(N??"__clear__"),f("");try{await je(`/api/models/${encodeURIComponent(e.name)}/draft`,{method:"POST",body:JSON.stringify({draft_path:N})}),r(),t()}catch(E){f(String((E==null?void 0:E.message)||E)),u(null)}}const j=N=>{var E;return N?`${N.pre??"?"} · ${((E=N.n_vocab)==null?void 0:E.toLocaleString())??"?"} Tokens`:"—"};return l.jsx("div",{className:"fixed inset-0 z-50 bg-black/60 backdrop-blur-sm flex items-center justify-center p-4",children:l.jsxs("div",{className:"w-full max-w-lg 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:[l.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[l.jsxs("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary flex items-center gap-2",children:[l.jsx(ha,{className:"h-4 w-4"})," Speculative Draft"]}),l.jsx("button",{onClick:t,className:"p-1 rounded hover:bg-accent text-muted-foreground hover:text-foreground cursor-pointer",children:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsxs("div",{className:"text-xs text-muted-foreground leading-relaxed",children:['Beschleunigt die Token-Generierung mit einem kleinen "Draft"-Modell. Voraussetzung: der Draft muss den ',l.jsx("strong",{className:"text-foreground",children:"exakt gleichen Tokenizer (Vocab)"})," haben wie das Modell — sonst lehnt llama.cpp es ab."]}),l.jsxs("div",{className:"rounded-lg border border-border/40 bg-background/30 px-3 py-2 text-[11px] font-mono flex items-center justify-between",children:[l.jsx("span",{className:"text-muted-foreground",children:(k=e.name.split("/").pop())==null?void 0:k.replace(/\.gguf$/i,"")}),l.jsxs("span",{className:"text-foreground",children:["Vocab: ",j(h)]})]}),e.spec_active&&v&&l.jsxs("div",{className:"rounded-lg border border-emerald-500/30 bg-emerald-500/5 px-3 py-2 flex items-center justify-between gap-2",children:[l.jsxs("span",{className:"text-[11px] text-emerald-400 font-mono flex items-center gap-1.5 truncate",children:[l.jsx(or,{className:"h-3.5 w-3.5 shrink-0"})," Aktiv: ",v]}),l.jsx("button",{onClick:()=>b(null),disabled:o!==null,className:"h-6 px-2.5 rounded border border-amber-500/30 bg-amber-500/5 hover:bg-amber-500/10 text-amber-400 text-[9px] font-bold uppercase shrink-0 cursor-pointer disabled:opacity-50",children:"Deaktivieren"})]}),!(n!=null&&n.target_exists)&&l.jsxs("div",{className:"rounded-lg border border-amber-500/30 bg-amber-500/5 px-3 py-2 text-[11px] text-amber-400 flex items-center gap-2",children:[l.jsx(gn,{className:"h-3.5 w-3.5 shrink-0"}),"Modell-GGUF noch nicht vorhanden — Spec-Draft ist nach dem Download konfigurierbar."]}),l.jsx("div",{className:"space-y-1.5 max-h-64 overflow-y-auto pr-1",children:a?l.jsx("div",{className:"text-xs text-muted-foreground py-6 text-center",children:"Prüfe Vocab-Kompatibilität…"}):m.length===0?l.jsxs("div",{className:"text-[11px] text-muted-foreground border border-dashed border-border/50 rounded-lg p-4 text-center",children:["Keine Draft-Modelle in ",l.jsx("code",{className:"font-mono",children:"/srv/models/drafts"}),". Lade ein kleines same-family-Modell (z.B. Qwen3-0.6B) und lege es dort ab."]}):m.map(N=>{var P,_;const E=N.filename===v,A=N.compatible===!0;return l.jsxs("div",{className:ee("rounded-lg border px-3 py-2 flex items-center justify-between gap-2 text-left",A?"border-border/40 bg-background/20":"border-border/20 bg-background/10 opacity-60",E&&"border-primary/40 bg-primary/10"),children:[l.jsxs("div",{className:"min-w-0",children:[l.jsxs("div",{className:"text-[11px] font-mono font-semibold text-foreground truncate flex items-center gap-1.5",children:[N.filename,N.mtp&&l.jsx("span",{className:"shrink-0 rounded bg-indigo-500/15 px-1.5 py-0.5 text-[8px] font-bold uppercase tracking-wider text-indigo-400 border border-indigo-500/25",title:"MTP-Kopf (Multi-Token-Prediction) — by-construction vocab-identisch, höchste Akzeptanzrate",children:"MTP"})]}),l.jsxs("div",{className:"text-[9px] text-muted-foreground font-mono",children:[_r(N.size_bytes)," · Vocab: ",j(N.vocab)]})]}),A?E?l.jsxs("span",{className:"text-[9px] font-bold uppercase text-primary flex items-center gap-1 shrink-0",children:[l.jsx(or,{className:"h-3.5 w-3.5"})," Aktiv"]}):l.jsx("button",{onClick:()=>b(N.path),disabled:o!==null,className:"h-7 px-3 rounded-lg border border-emerald-500/30 bg-emerald-500/5 hover:bg-emerald-500/15 text-emerald-400 text-[9px] font-bold uppercase shrink-0 cursor-pointer disabled:opacity-50",children:"Aktivieren"}):l.jsxs("span",{className:"text-[9px] font-bold uppercase text-amber-400/80 flex items-center gap-1 shrink-0",title:N.compatible===!1?`Inkompatibel: Tokenizer/Vocab weicht ab (Draft ${(P=N.vocab)==null?void 0:P.pre}/${(_=N.vocab)==null?void 0:_.n_vocab} ≠ Modell ${h==null?void 0:h.pre}/${h==null?void 0:h.n_vocab}).`:"Kompatibilität nicht prüfbar (Datei fehlt).",children:[l.jsx(gn,{className:"h-3.5 w-3.5"})," ",N.compatible===!1?"Vocab ≠":"n/a"]})]},N.path)})}),!a&&(n==null?void 0:n.target_exists)&&m.length>0&&g.length===0&&l.jsxs("div",{className:"rounded-lg border border-amber-500/30 bg-amber-500/5 px-3 py-2 text-[11px] text-amber-400 leading-relaxed",children:["Kein vocab-kompatibler Draft verfügbar — Speculative Decoding ist für dieses Modell nicht möglich. Es braucht einen Draft mit identischem Tokenizer (pre=",l.jsx("span",{className:"font-mono",children:h==null?void 0:h.pre}),", n_vocab=",l.jsx("span",{className:"font-mono",children:(S=h==null?void 0:h.n_vocab)==null?void 0:S.toLocaleString()}),")."]}),c&&l.jsx("div",{className:"text-[10px] text-red-400 font-mono",children:c})]})})}const gX=e=>!!ir(e).protected;function vX({role:e,roleRec:t,models:r,onAssign:n,onClose:a}){var f,h;const o=t&&t.role===e?t:null,u={};o==null||o.models.forEach(m=>{u[m.name]=m});const c=o?o.models.map(m=>r.find(g=>g.name===m.name)).filter(Boolean):r;return l.jsx("div",{className:"fixed inset-0 z-50 bg-black/60 backdrop-blur-sm flex items-center justify-center p-4 overscroll-contain",role:"dialog","aria-modal":"true","aria-label":`${ir(e).label} konfigurieren`,children:l.jsxs("div",{className:"w-full max-w-md 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:[l.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[l.jsxs("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary flex items-center gap-1.5",children:[l.jsx(oo,{role:e})," festlegen"]}),l.jsx("button",{onClick:a,className:"p-1 rounded hover:bg-accent text-muted-foreground hover:text-foreground cursor-pointer",children:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsxs("div",{className:"flex items-center justify-between gap-2",children:[l.jsxs("p",{className:"text-xs text-muted-foreground",children:["Wähle ein Modell für ",l.jsx("strong",{className:"text-foreground",children:ir(e).label}),l.jsx("span",{className:"block text-[10px] text-muted-foreground/70 mt-0.5",children:ir(e).desc})]}),(o==null?void 0:o.recommended)&&l.jsxs("button",{onClick:()=>n(o.recommended),title:(f=u[o.recommended])==null?void 0:f.reason,className:"shrink-0 h-7 px-3 text-[11px] font-semibold text-primary border border-primary/50 bg-primary/10 hover:bg-primary/20 rounded-lg cursor-pointer flex items-center gap-1",children:[l.jsx(ha,{className:"h-3 w-3"})," Auto: ",(h=o.recommended.split("/").pop())==null?void 0:h.replace(/\.gguf$/i,"")]})]}),l.jsxs("div",{className:"space-y-1.5 max-h-60 overflow-y-auto pr-1",children:[gX(e)?l.jsx("div",{className:"w-full px-3 py-2 rounded-lg text-[11px] text-muted-foreground border border-border/30 bg-background/20 flex items-center gap-1.5",children:"🔒 Diese Rolle ist lebenswichtig und kann nicht leer bleiben — wähle stattdessen ein anderes Modell."}):l.jsx("button",{onClick:()=>n(""),className:"w-full text-left px-3 py-2 rounded-lg text-xs hover:bg-accent text-red-400 font-semibold cursor-pointer border border-red-500/20 bg-red-500/5 flex items-center justify-between",children:l.jsx("span",{children:"Zuweisung entfernen"})}),c.map(m=>{var k;const g=u[m.name],v=m.role===e,b=!!(g!=null&&g.recommended),j=!!g&&!g.suitable;return l.jsxs("button",{onClick:()=>n(m.name),className:ee("w-full text-left px-3 py-2.5 rounded-lg text-xs hover:bg-accent flex items-center justify-between font-mono cursor-pointer border",b?"border-primary/50 bg-primary/10":v?"text-primary font-bold bg-primary/5 border-primary/30":j?"border-border/20 bg-background/10 opacity-60":"text-foreground bg-background/20 border-border/30"),children:[l.jsxs("div",{className:"flex flex-col text-left min-w-0",children:[l.jsxs("span",{className:"truncate max-w-[260px] font-semibold flex items-center gap-1.5",children:[(k=m.name.split("/").pop())==null?void 0:k.replace(/\.gguf$/i,""),b&&l.jsx("span",{className:"text-[8px] font-bold uppercase tracking-wide text-primary bg-primary/15 px-1.5 py-0.5 rounded",children:"Empfohlen"})]}),l.jsx("span",{className:"text-[9px] text-muted-foreground mt-0.5",children:g?`${g.params_b}B · ${m.quant} · ${g.reason}`:`${_r(m.size_bytes)} · ${m.quant}`})]}),v&&l.jsx(or,{className:"h-4 w-4 shrink-0 text-primary"})]},m.name)})]})]})})}const yX=["fast","heavy","heavy_chars"],xX=["coder_lite","coder","coding_escalate_chars"];function bX(){const e=Kn(),{data:t,isLoading:r}=OD(),[n,a]=y.useState(null),[o,u]=y.useState(!1),[c,f]=y.useState(""),[h,m]=y.useState(0);if(y.useEffect(()=>{t!=null&&t.policy&&!n&&a({...t.policy})},[t,n]),r||!t||!n)return l.jsx("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 text-xs text-muted-foreground",children:"Lade Routing-Policy…"});const g=N=>t.fields.find(E=>E.key===N),v=Object.keys(n).some(N=>n[N]!==t.policy[N]),b=(N,E)=>{a(A=>A&&{...A,[N]:E}),f("")},j=N=>b(N,t.defaults[N]);async function k(){if(!n)return;const N={};for(const E of Object.keys(n))n[E]!==t.policy[E]&&(N[E]=n[E]);if(Object.keys(N).length!==0){u(!0),f("");try{const{policy:E}=await CD(N);a({...E}),e.invalidateQueries({queryKey:Ve.routingPolicy}),e.invalidateQueries({queryKey:Ve.routing}),m(Date.now()),setTimeout(()=>m(0),2e3)}catch(E){f(E.message||String(E))}finally{u(!1)}}}function S({k:N}){const E=g(N),A=n[N],P=n[N]===t.defaults[N];return l.jsxs("div",{className:"space-y-1",children:[l.jsxs("div",{className:"flex items-center justify-between gap-2",children:[l.jsx("label",{className:"text-[10px] font-semibold text-muted-foreground",children:E.label}),!P&&l.jsxs("button",{onClick:()=>j(N),className:"flex items-center gap-0.5 text-[9px] text-muted-foreground/60 hover:text-foreground transition-colors cursor-pointer",title:`Auf Default zurücksetzen (${String(t.defaults[N])||"leer"})`,children:[l.jsx(P4,{className:"h-2.5 w-2.5"})," Default"]})]}),E.type==="bool"?l.jsxs("button",{onClick:()=>b(N,!A),className:ee("flex h-8 w-full items-center justify-between rounded-lg border px-3 text-[11px] font-semibold transition-all cursor-pointer",A?"border-emerald-500/40 bg-emerald-500/10 text-emerald-300":"border-border/40 bg-background/40 text-muted-foreground"),children:[l.jsx("span",{children:A?"An":"Aus"}),l.jsx("span",{className:ee("h-3.5 w-3.5 rounded-full transition-colors",A?"bg-emerald-400":"bg-muted-foreground/40")})]}):E.type==="int"?l.jsx("input",{type:"number",value:A,min:E.min,max:E.max,"aria-label":E.label,onChange:_=>b(N,Number(_.target.value)),className:"h-8 w-full rounded-lg border border-border/40 bg-background/40 px-3 font-mono text-[11px] text-foreground outline-none focus:border-primary/50"}):l.jsx("input",{type:"text",value:A,"aria-label":E.label,spellCheck:!1,placeholder:N==="coder_lite"?"(leer = aus)":"",onChange:_=>b(N,_.target.value),className:"h-8 w-full rounded-lg border border-border/40 bg-background/40 px-3 font-mono text-[11px] text-foreground outline-none focus:border-primary/50"})]})}return l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10 space-y-4",children:[l.jsxs("div",{className:"flex items-center justify-between gap-3 flex-wrap",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(R4,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("span",{className:"text-xs font-bold uppercase tracking-wider text-foreground",children:"Lane-Routing & Policy"}),l.jsx("span",{className:"text-[9px] font-mono px-1.5 py-0.5 rounded bg-emerald-500/10 text-emerald-300 border border-emerald-500/20",children:"hot-reload"})]}),l.jsxs("div",{className:"flex items-center gap-2",children:[c&&l.jsx("span",{className:"text-[10px] text-red-400 max-w-[280px] truncate",title:c,children:c}),h>0&&l.jsxs("span",{className:"flex items-center gap-1 text-[10px] text-emerald-400",children:[l.jsx(or,{className:"h-3.5 w-3.5"})," gespeichert"]}),l.jsxs("button",{onClick:k,disabled:!v||o,className:ee("h-8 px-4 rounded-lg text-[10px] font-bold uppercase tracking-wide transition-all flex items-center gap-1.5",v&&!o?"bg-primary text-primary-foreground hover:opacity-90 cursor-pointer shadow-md shadow-primary/10":"bg-background/40 text-muted-foreground/50 border border-border/40 cursor-not-allowed"),children:[o?l.jsx(eh,{className:"h-3.5 w-3.5 animate-spin"}):null,"Speichern"]})]})]}),l.jsxs("p",{className:"text-[10px] text-muted-foreground/70 leading-relaxed -mt-1",children:["Welches echte Modell hinter den virtuellen Lanes ",l.jsx("code",{className:"text-cyan-300",children:"chat"})," und"," ",l.jsx("code",{className:"text-cyan-300",children:"coding"})," steckt. Änderungen greifen sofort (kein Neustart). Die Keyword-Heuristiken bleiben im Code."]}),l.jsxs("div",{className:"grid gap-4 md:grid-cols-2",children:[l.jsxs("div",{className:"rounded-xl border border-border/40 bg-background/25 p-4 space-y-3",children:[l.jsxs("div",{className:"flex items-center gap-2 border-b border-border/30 pb-2",children:[l.jsx(w4,{className:"h-4 w-4 text-teal-400"}),l.jsx("span",{className:"text-[11px] font-bold uppercase tracking-wider text-foreground",children:"chat"}),l.jsx("span",{className:"text-[9px] text-muted-foreground/60 font-mono",children:"(= auto)"})]}),yX.map(N=>l.jsx(S,{k:N},N))]}),l.jsxs("div",{className:"rounded-xl border border-border/40 bg-background/25 p-4 space-y-3",children:[l.jsxs("div",{className:"flex items-center gap-2 border-b border-border/30 pb-2",children:[l.jsx(r4,{className:"h-4 w-4 text-indigo-400"}),l.jsx("span",{className:"text-[11px] font-bold uppercase tracking-wider text-foreground",children:"coding"}),l.jsx("span",{className:"text-[9px] text-muted-foreground/60 font-mono",children:"(agentisch → immer Coder)"})]}),xX.map(N=>l.jsx(S,{k:N},N))]})]}),l.jsx("div",{className:"rounded-xl border border-border/40 bg-background/25 p-4",children:l.jsx("div",{className:"max-w-xs",children:l.jsx(S,{k:"fast_no_think"})})})]})}function wX(){var he,ue,ge;const e=Kn(),{data:t}=yi(4e3),{data:r}=NE(),{data:n}=xo(),{data:a}=EE(),{showAlert:o,dialogElement:u}=ya(),[c,f]=y.useState(!1),[h,m]=y.useState(!1),g=(t==null?void 0:t.models)??[],v=(t==null?void 0:t.running)??[],b=(he=r==null?void 0:r.groups)==null?void 0:he.brains,j=(b==null?void 0:b.members)??[],k=ie=>g.find(se=>se.name===ie),S=ie=>{var se;return((se=ie.split("/").pop())==null?void 0:se.replace(/\.gguf$/i,""))||ie},N=j.map(k).filter(Boolean),E=1024**3,A=a==null?void 0:a.budget,P=N.reduce((ie,se)=>ie+(se.size_bytes||0),0)/E,_=((ue=n==null?void 0:n.gpu)==null?void 0:ue.gtt_total)||((ge=n==null?void 0:n.gpu)==null?void 0:ge.vram_total)||0,O=(A==null?void 0:A.gtt_gb)||(_?_/E:0),D=(A==null?void 0:A.warm_projected_gb)??P,B=O>0?Math.min(100,D/O*100):0,F=g.filter(ie=>!j.includes(ie.name)&&!ie.incomplete);async function z(ie){m(!0);try{await jE("brains",ie,(b==null?void 0:b.swap)??!1,(b==null?void 0:b.persist)??!0),e.invalidateQueries({queryKey:Ve.groups}),e.invalidateQueries({queryKey:Ve.models}),e.invalidateQueries({queryKey:Ve.hermesBrain})}catch(se){o("Fehler",`Immer-bereit-Set konnte nicht geändert werden: ${(se==null?void 0:se.message)||se}`)}finally{m(!1)}}function Y(ie){const se=k(ie);if(se&&ir(se.role).protected){o("Geschützt",`„${ir(se.role).label}" ist lebenswichtig und bleibt immer bereit.`);return}z(j.filter(X=>X!==ie))}function U(ie){f(!1),z([...j,ie])}return b?l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10 space-y-4",children:[l.jsx(W2,{}),l.jsxs("div",{className:"space-y-1.5",children:[N.length===0&&l.jsx("div",{className:"text-xs text-muted-foreground",children:"Noch keine Modelle im Set."}),N.map(ie=>{const se=v.includes(ie.name),X=ir(ie.role).protected;return l.jsxs("div",{className:"flex items-center justify-between gap-2 rounded-xl border border-border/30 bg-background/20 p-2.5",children:[l.jsxs("div",{className:"flex min-w-0 items-center gap-2.5",children:[l.jsx("span",{className:ee("h-2 w-2 shrink-0 rounded-full ring-2 ring-black/40",se?"bg-emerald-500 animate-pulse":"bg-muted-foreground/40"),title:se?"Gerade warm (bereit)":"Reserviert — lädt bei Bedarf sofort"}),ie.role&&l.jsx(oo,{role:ie.role,dense:!0,className:"shrink-0"}),l.jsx("span",{className:"truncate font-mono text-xs font-semibold text-foreground",title:ie.name,children:S(ie.name)}),l.jsx("span",{className:"shrink-0 font-mono text-[10px] text-muted-foreground/70",children:_r(ie.size_bytes)})]}),X?l.jsx("span",{className:"shrink-0 text-[10px] font-semibold text-muted-foreground",title:"Lebenswichtig — bleibt immer im Set.",children:"🔒"}):l.jsx("button",{onClick:()=>Y(ie.name),disabled:h,className:"flex h-7 w-7 shrink-0 items-center justify-center rounded-lg border border-border/40 text-muted-foreground transition-colors hover:bg-red-500/5 hover:text-red-400 cursor-pointer disabled:opacity-50",title:"Aus dem Immer-bereit-Set nehmen (lädt dann nur noch bei Bedarf)",children:l.jsx(zn,{className:"h-3.5 w-3.5"})})]},ie.name)})]}),l.jsxs("button",{onClick:()=>f(!0),disabled:h||F.length===0,className:"flex h-8 w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-border/50 text-[11px] font-semibold uppercase tracking-wide text-muted-foreground transition-colors hover:border-primary/40 hover:text-primary cursor-pointer disabled:opacity-50",children:[l.jsx(ef,{className:"h-3.5 w-3.5"})," Modell dauerhaft bereithalten"]}),l.jsxs("div",{className:"rounded-xl border border-border/30 bg-background/20 p-3",children:[l.jsxs("div",{className:"mb-1.5 flex items-center justify-between text-[11px]",children:[l.jsxs("span",{className:"flex items-center gap-1.5 font-semibold uppercase tracking-wider text-muted-foreground",title:"Modellgewichte + KV-Cache, berechnet aus den echten Architektur-Daten jedes Modells (Layer × KV-Köpfe × Kontext) und seiner KV-Quantisierung. So viel legt llama.cpp beim Laden wirklich für den eingestellten Kontext an — kein Aufschlag mehr.",children:[l.jsx(cu,{className:"h-3.5 w-3.5"})," Reserviert fürs Set"]}),l.jsxs("span",{className:"font-mono font-bold text-foreground",children:[D.toFixed(1),O>0?` / ${O.toFixed(0)}`:""," GB"]})]}),l.jsx("div",{className:"h-2 w-full overflow-hidden rounded-full border border-border/30 bg-background/50",children:l.jsx("div",{className:ee("h-full rounded-full transition-all duration-500",B>=85?"bg-red-500":B>=65?"bg-amber-500":"bg-teal-500"),style:{width:`${B}%`}})}),A&&!A.fits&&l.jsxs("p",{className:"mt-2 flex items-start gap-1.5 text-[11px] text-amber-400",children:[l.jsx(gn,{className:"mt-0.5 h-3.5 w-3.5 shrink-0"}),l.jsxs("span",{children:["Zusammen mit dem größten Gelegenheits-Modell (~",A.largest_ondemand_gb," GB) wird der Speicher knapp. Das Set bleibt dabei immer geladen — wird es wirklich eng, schlägt das Laden des großen Modells fehl (es wartet dann, statt das Set zu verdrängen)."]})]}),A&&A.fits&&l.jsxs("p",{className:"mt-2 flex items-center gap-1.5 text-[11px] text-emerald-400",children:[l.jsx(or,{className:"h-3.5 w-3.5 shrink-0"})," Passt auch neben dem größten Gelegenheits-Modell — nichts wird verdrängt."]})]}),c&&l.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 p-4 backdrop-blur-sm",role:"dialog","aria-modal":"true","aria-label":"Modell zum Immer-bereit-Set hinzufügen",children:l.jsxs("div",{className:"w-full max-w-md space-y-3 rounded-2xl border border-border/80 bg-card p-6 shadow-2xl animate-in fade-in zoom-in-95 duration-200",children:[l.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary",children:"Dauerhaft bereithalten"}),l.jsx("button",{onClick:()=>f(!1),className:"rounded p-1 text-muted-foreground hover:bg-accent hover:text-foreground cursor-pointer",children:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsx("p",{className:"text-xs text-muted-foreground",children:"Wähle ein Modell, das ohne Ladezeit bereitstehen soll:"}),l.jsx("div",{className:"max-h-60 space-y-1.5 overflow-y-auto pr-1",children:F.map(ie=>l.jsxs("button",{onClick:()=>U(ie.name),className:"flex w-full items-center justify-between gap-2 rounded-lg border border-border/30 bg-background/20 px-3 py-2.5 text-left transition-colors hover:bg-accent cursor-pointer",children:[l.jsxs("span",{className:"flex min-w-0 items-center gap-2",children:[ie.role&&l.jsx(oo,{role:ie.role,dense:!0,className:"shrink-0"}),l.jsx("span",{className:"truncate font-mono text-xs font-semibold text-foreground",children:S(ie.name)})]}),l.jsx("span",{className:"shrink-0 font-mono text-[10px] text-muted-foreground/70",children:_r(ie.size_bytes)})]},ie.name))})]})}),u]}):l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10",children:[l.jsx(W2,{}),l.jsx("p",{className:"mt-3 text-xs text-muted-foreground",children:"Es gibt noch kein Immer-bereit-Set. Es entsteht automatisch, sobald Lucys Hirn zugewiesen ist."}),u]})}function W2(){return l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(ha,{className:"h-4.5 w-4.5 text-primary"}),l.jsxs("div",{children:[l.jsx("h2",{className:"text-sm font-bold uppercase tracking-wide text-foreground",children:"Immer-bereit-Set"}),l.jsx("p",{className:"text-[11px] text-muted-foreground",children:"Diese Modelle hält Lucy immer bereit — sie antworten ohne Ladezeit."})]})]})}function GO(){var Be,Pe,vt,Yt;const e=Kn(),{data:t,isLoading:r,error:n}=yi(4e3),{data:a}=sh(4e3),{data:o}=EE(),{data:u}=xo(),{data:c}=NE(),{showAlert:f,showConfirm:h,showPrompt:m,dialogElement:g}=ya(),v=pE(),b=K=>!!ir(K).protected,j=(t==null?void 0:t.models)??[],k=(t==null?void 0:t.running)??[],S=n?String(n):"",N=()=>{e.invalidateQueries({queryKey:Ve.models}),e.invalidateQueries({queryKey:Ve.routing})},E=(Be=c==null?void 0:c.groups)==null?void 0:Be.brains,A=(E==null?void 0:E.members)??[],P=K=>A.includes(K),_=A.some(K=>k.includes(K));async function O(K){if(!E){f("Keine brains-Gruppe","Es existiert noch keine Ko-Residenz-Gruppe „brains“ in der Engine-Konfiguration. Lege sie erst über die Gruppen-Verwaltung an.");return}const Se=A.includes(K)?A.filter(qe=>qe!==K):[...A,K];try{await jE("brains",Se,E.swap??!1,E.persist??!0),e.invalidateQueries({queryKey:Ve.groups}),N()}catch(qe){f("Fehler",`Ko-Residenz konnte nicht geändert werden: ${qe.message||qe}`)}}const[D,B]=y.useState(null),[F,z]=y.useState(null),[Y,U]=y.useState(null),[he,ue]=y.useState("grid"),[ge,ie]=y.useState("all"),se=j.filter(K=>ge==="in_use"?!!K.role||k.includes(K.name):!0);async function X(K){try{await je(`/api/models/${encodeURIComponent(K)}/load`,{method:"POST"}),N()}catch(Ae){f("Fehler",`Fehler beim Laden des Modells: ${Ae.message}`)}}async function te(K){if(E&&_&&!P(K)){const Ae=A.filter(Se=>k.includes(Se)).map(Se=>Se.split("/").pop()).join(", ");h("Verdrängt das Hirn?",`„${K.split("/").pop()}“ ist nicht in der Ko-Residenz-Gruppe „brains“. Beim Laden wirft es das aktuell warme Hirn (${Ae}) raus — Lucy verliert Hirn bzw. Augen.
|
||
|
||
Trotzdem exklusiv laden? Tipp: Mit dem 🧠-Schalter machst du das Modell dauerhaft ko-resident, dann bleiben beide warm.`,()=>X(K));return}X(K)}async function J(K){const Ae=j.find(Se=>Se.name===K);if(Ae&&b(Ae.role)){f("Geschützt",`„${ir(Ae.role).label}" ist lebenswichtig für Lucy und bleibt geladen. Zum Entladen erst im Experten-Modus die Rolle einem anderen Modell geben.`);return}try{await je(`/api/models/${encodeURIComponent(K)}/unload`,{method:"POST"}),N()}catch(Se){f("Fehler",`Fehler beim Entladen des Modells: ${Se.message}`)}}async function I(){try{await je("/api/models/unload",{method:"POST"}),N()}catch(K){f("Fehler",`Fehler beim Entladen aller Modelle: ${K.message}`)}}async function M(K,Ae){try{const Se=await je(`/api/models/${encodeURIComponent(Ae)}/role`,{method:"POST",body:JSON.stringify({role:K||null})});N(),Se!=null&&Se.warning&&f("Hirn gesetzt — Hinweis",Se.warning)}catch(Se){f("Fehler",`Fehler beim Zuweisen der Rolle: ${Se.message||Se}`)}}function H(K){B(K),z(null),je(`/api/roles/${encodeURIComponent(K)}/recommend`).then(Ae=>z(Ae)).catch(()=>{})}async function ne(K,Ae){let Se=null;try{Se=await je(`/api/models/${encodeURIComponent(K)}/ctx/auto`)}catch{}const qe=Se?`Optimal für dein Setup: ${(Se.ctx/1024).toFixed(0)}k (${Se.ctx}) — GTT ${Se.gtt_gb} GB − reserviert ${Se.reserved_gb} GB (${Se.mode}) → ${Se.budget_gb} GB frei. »Auto« trägt diesen Wert ein.`:"Gib die gewünschte Kontextlänge in Tokens an:";m("Kontextlänge anpassen",qe,String(Ae||32768),async G=>{if(G)try{await je(`/api/models/${encodeURIComponent(K)}/ctx`,{method:"POST",body:JSON.stringify({ctx:parseInt(G,10)})}),N()}catch(Ie){f("Fehler",`Fehler beim Setzen des Kontexts: ${Ie.message||Ie}`)}},void 0,Se?{autoValue:String(Se.ctx),autoLabel:`Auto (${(Se.ctx/1024).toFixed(0)}k)`}:void 0)}async function Z(K){const Ae=j.find(Se=>Se.name===K);if(Ae&&b(Ae.role)){f("Geschützt",`„${ir(Ae.role).label}" ist lebenswichtig für Lucy und kann nicht gelöscht werden. Weise die Rolle zuerst einem anderen Modell zu.`);return}h("Modell löschen?",`Modell '${K}' und alle zugehörigen GGUF-Dateien unwiderruflich von der Box löschen?`,async()=>{try{await je(`/api/models/${encodeURIComponent(K)}`,{method:"DELETE"}),N()}catch(Se){f("Fehler",`Fehler beim Löschen: ${Se.message||Se}`)}})}async function me(K,Ae,Se,qe){try{await je("/api/models/install",{method:"POST",body:JSON.stringify({repo:K,role:Ae,quant:Se,jinja:qe})}),f("Herunterladen gestartet",`Download für '${K}' gestartet! Der Fortschritt wird oben angezeigt.`)}catch(G){f("Fehler",`Fehler beim Starten des Upgrades: ${G.message||G}`)}}async function pe(K){const Ae=o==null?void 0:o.budget,Se=Ae&&!Ae.fits?`
|
||
|
||
⚠ Speicher-Warnung: Dieses Brain (~${Ae.brain_gb} GB) bleibt immer resident (persistent). Zusammen mit dem größten on-demand-Modell (~${Ae.largest_ondemand_gb} GB) sprengt das das Budget (${Ae.gtt_gb} GB) → beim Laden von heavy/coder droht ein Überlauf. Erwäge ein kleineres Brain oder weniger Kontext.`:"";h("Agent-Hirn aktualisieren?",`Neues Hermes-Modell '${K.split("/").pop()}' herunterladen und als Agent-Hirn (Rolle hermes) setzen? Hermes nutzt danach automatisch das neue Modell.${Se}`,async()=>{try{await je("/api/models/install",{method:"POST",body:JSON.stringify({repo:K,role:"hermes",quant:"Q4_K_M",jinja:!0})}),f("Download gestartet","Das neue Agent-Hirn wird geladen. Fortschritt oben."),N()}catch(qe){f("Fehler",`Update fehlgeschlagen: ${qe.message||qe}`)}})}if(r)return l.jsx("div",{className:"text-xs text-muted-foreground py-12 text-center",children:"Initialisiere HUD Cockpit…"});if(S)return l.jsxs("div",{className:"rounded-xl border border-red-500/20 bg-red-500/5 p-4 text-xs text-red-400",children:["Gateway oder Engine nicht erreichbar (",S,")."]});const Oe=j.filter(K=>k.includes(K.name)),re=Oe.reduce((K,Ae)=>K+(Ae.size_bytes||0),0),we=((Pe=u==null?void 0:u.gpu)==null?void 0:Pe.gtt_total)||((vt=u==null?void 0:u.gpu)==null?void 0:vt.vram_total)||0,_e=((Yt=u==null?void 0:u.gpu)==null?void 0:Yt.gtt_used)||0,ae=16*1024**3,et=we>2*1024**3?we:re>ae?re*1.2:ae;return l.jsxs("div",{className:"space-y-8",children:[l.jsx("style",{children:`
|
||
@keyframes flow-dash {
|
||
to {
|
||
stroke-dashoffset: -20;
|
||
}
|
||
}
|
||
.svg-flow-path {
|
||
stroke-dasharray: 4 6;
|
||
animation: flow-dash 1s linear infinite;
|
||
}
|
||
`}),l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10 space-y-3.5",children:[l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(cu,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("span",{className:"text-xs font-bold uppercase tracking-wider text-foreground",children:"VRAM / Memory Belegung"})]}),l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsxs("span",{className:"text-[10px] font-mono text-muted-foreground",children:["Speicher-Pool: ",_r(re)," Gewichte",_e>0?` · ${_r(_e)} real belegt (inkl. KV)`:""," / ",_r(et)]}),v&&k.length>0&&l.jsx("button",{onClick:I,className:"h-6 px-2.5 rounded border border-amber-500/30 bg-amber-500/5 hover:bg-amber-500/10 text-amber-400 text-[9px] font-bold uppercase transition-all cursor-pointer",children:"Alle entladen"})]})]}),l.jsx("div",{className:"h-7 w-full rounded-xl bg-background/50 border border-border/40 overflow-hidden flex p-0.5 relative group",children:Oe.length===0?l.jsx("div",{className:"w-full h-full flex items-center justify-center text-[10px] text-muted-foreground/60 italic font-mono select-none",children:"VRAM Leer — Auto-Swap lädt Modelle bei Anfrage"}):Oe.map((K,Ae)=>{var G;const Se=(K.size_bytes||0)/et*100,qe=["from-teal-500 to-emerald-500","from-indigo-500 to-blue-500","from-purple-500 to-pink-500","from-cyan-500 to-sky-500"][Ae%4];return l.jsxs("div",{style:{width:`${Se}%`},className:ee("h-full rounded bg-gradient-to-r flex items-center justify-between px-2.5 transition-all text-white/95 shrink-0 shadow-inner select-none",qe),title:`${K.name} (${_r(K.size_bytes)})`,children:[l.jsxs("span",{className:"text-[9px] font-bold truncate max-w-[120px] font-space tracking-wide",children:[K.role?`[${ir(K.role).short}] `:"",(G=K.name.split("/").pop())==null?void 0:G.replace(".gguf","")]}),l.jsx("span",{className:"text-[8px] font-mono opacity-80",children:_r(K.size_bytes)})]},K.name)})})]}),l.jsx(wX,{}),v&&l.jsx(bX,{}),l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10 space-y-3.5",children:[l.jsx("div",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground px-1",children:v?"Gateway Steckplatz-Belegung (Slot-Zuweisung)":"Wer macht was bei Lucy — zum Ändern antippen"}),l.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-6 gap-3",children:WO.map(K=>{var qe;const Ae=j.find(G=>G.role===K),Se=Ae?k.includes(Ae.name):!1;return l.jsxs("div",{onClick:()=>H(K),className:ee("rounded-xl border p-3 flex flex-col justify-between gap-2.5 transition-all cursor-pointer select-none text-left bg-background/25 hover:border-primary/45 hover:bg-background/40 group min-h-[90px]",Se?"border-emerald-500/40 shadow-sm shadow-emerald-500/5":Ae?"border-primary/20 bg-primary/5":"border-border/30 border-dashed opacity-75"),children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsx(oo,{role:K}),Se&&l.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-400 animate-pulse"})]}),l.jsx("div",{className:"text-[10px] font-mono font-medium truncate text-foreground/90 pr-1 font-space",title:Ae==null?void 0:Ae.name,children:Ae?(qe=Ae.name.split("/").pop())==null?void 0:qe.replace(/\.gguf$/i,""):"nicht zugewiesen"}),l.jsx("div",{className:"text-[8px] text-primary/70 group-hover:text-primary font-bold uppercase tracking-wider transition-colors font-space",children:"Ändern ➔"})]},K)})})]}),(o==null?void 0:o.current)&&l.jsxs("div",{className:"rounded-2xl border border-indigo-500/30 bg-indigo-500/5 backdrop-blur-md p-5 shadow-lg shadow-black/10 space-y-3.5",children:[l.jsxs("div",{className:"flex items-center justify-between flex-wrap gap-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(pn,{className:"h-4.5 w-4.5 text-indigo-400"}),l.jsx("span",{className:"text-xs font-bold uppercase tracking-wider text-foreground",children:"Agent-Hirn (Hermes)"}),o.current.version!=null&&l.jsxs("span",{className:"text-[9px] font-mono px-1.5 py-0.5 rounded bg-indigo-500/15 text-indigo-300 border border-indigo-500/25",children:["v",o.current.version]})]}),l.jsx("button",{onClick:()=>window.dispatchEvent(new CustomEvent("mc-navigate",{detail:{view:"agent"}})),className:"h-7 px-3 rounded-lg border border-indigo-500/30 bg-indigo-500/5 text-indigo-300 text-[9px] font-bold uppercase hover:bg-indigo-500/15 transition-all cursor-pointer",title:"Hirn-Wechsel passiert jetzt zentral im Hermes-Tab",children:"Im Hermes-Tab wechseln →"})]}),l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-3 rounded-xl bg-background/30 border border-border/30 p-3.5",children:[l.jsxs("div",{className:"min-w-0",children:[l.jsx("div",{className:"text-xs font-mono font-bold text-foreground truncate",title:o.current.name,children:o.current.name.split("/").pop()}),l.jsxs("div",{className:"text-[10px] text-muted-foreground/80 flex items-center gap-2 mt-0.5",children:[l.jsx("span",{children:o.current.params_b?`${o.current.params_b}B`:"—"}),l.jsx("span",{children:"•"}),l.jsx("span",{children:o.current.quant||"GGUF"}),l.jsx("span",{children:"•"}),l.jsx("span",{children:_r(o.current.size_bytes||0)})]})]}),o.update_available&&o.recommended?l.jsxs("button",{onClick:()=>pe(o.recommended.repo),className:ee("h-8 px-3 shrink-0 flex items-center justify-center gap-1.5 rounded-lg text-[10px] font-bold uppercase transition-all cursor-pointer shadow-md",o.budget&&!o.budget.fits?"bg-red-500 text-white hover:bg-red-400 shadow-red-500/10":"bg-amber-500 text-black hover:bg-amber-400 shadow-amber-500/10"),children:[l.jsx(_s,{className:"h-3.5 w-3.5"})," Aktualisieren"]}):l.jsxs("span",{className:"h-8 px-3 shrink-0 flex items-center gap-1.5 text-[10px] font-bold text-emerald-400 uppercase tracking-wide bg-emerald-500/5 border border-emerald-500/15 rounded-lg select-none",children:[l.jsx(or,{className:"h-4 w-4"})," Neueste Generation"]})]}),o.update_available&&o.recommended&&l.jsxs("div",{className:"text-[10px] text-amber-400/90 flex items-center gap-1.5",children:[l.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-amber-400 animate-ping shrink-0"}),"Neuere Generation verfügbar: ",l.jsx("span",{className:"font-mono font-bold",children:o.recommended.name.replace(/-GGUF$/i,"")}),"(v",o.recommended.version,", ",o.recommended.params_b,"B) — von NousResearch."]}),o.budget&&l.jsxs("div",{className:ee("text-[10px] flex items-start gap-1.5 leading-relaxed",o.budget.fits?"text-muted-foreground/80":"text-red-400 font-semibold"),children:[l.jsx(cu,{className:"h-3 w-3 shrink-0 mt-0.5"}),l.jsxs("span",{children:["Always-On-Brain ~",o.budget.brain_gb," GB + größtes on-demand (~",o.budget.largest_ondemand_gb," GB) = ",(o.budget.brain_gb+o.budget.largest_ondemand_gb).toFixed(1)," / ",o.budget.gtt_gb," GB",o.budget.fits?" · passt gleichzeitig ✓":" · passt NICHT gleichzeitig ⚠ — heavy/coder würden das Brain verdrängen. Kleineres Brain oder weniger Kontext."]})]})]}),l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-3 px-1",children:[l.jsxs("div",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:["Installierte Modell-Bibliothek (",se.length," von ",j.length,")"]}),l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsxs("div",{className:"flex rounded-lg border border-border/40 bg-card/45 p-0.5",children:[l.jsx("button",{onClick:()=>ie("all"),className:ee("px-2.5 py-1 rounded-md text-[9px] font-bold uppercase transition-all cursor-pointer",ge==="all"?"bg-primary text-primary-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),children:"Vorhanden"}),l.jsx("button",{onClick:()=>ie("in_use"),className:ee("px-2.5 py-1 rounded-md text-[9px] font-bold uppercase transition-all cursor-pointer",ge==="in_use"?"bg-primary text-primary-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),children:"In Benutzung"})]}),l.jsxs("div",{className:"flex rounded-lg border border-border/40 bg-card/45 p-0.5",children:[l.jsx("button",{onClick:()=>ue("grid"),className:ee("px-2.5 py-1 rounded-md text-[9px] font-bold uppercase transition-all cursor-pointer",he==="grid"?"bg-primary text-primary-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),children:"Grid"}),l.jsx("button",{onClick:()=>ue("list"),className:ee("px-2.5 py-1 rounded-md text-[9px] font-bold uppercase transition-all cursor-pointer",he==="list"?"bg-primary text-primary-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),children:"List"})]})]})]}),he==="grid"?l.jsx("div",{className:"grid gap-4 sm:grid-cols-2 lg:grid-cols-3",children:se.length===0?l.jsx("div",{className:"col-span-full text-xs text-muted-foreground border border-dashed border-border/60 rounded-2xl p-12 text-center select-none",children:ge==="in_use"?"Keine Modelle in Benutzung (keine Zuweisung oder warm geladene Modelle).":'Keine Modelle konfiguriert. Verwende den Tab "Modelle finden" zum Herunterladen.'}):se.map(K=>{const Ae=k.includes(K.name),Se=a==null?void 0:a.model_list.find(G=>G.role===K.role),qe=B2(K.name);return l.jsxs("div",{className:ee("rounded-2xl border bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10 flex flex-col justify-between gap-4 transition-all duration-300 hover:border-primary/40 group relative overflow-hidden",Ae?"border-primary/45 shadow-primary/5":K.role?"border-primary/30 bg-primary/5 shadow-inner":"border-border/60"),children:[l.jsxs("div",{className:"space-y-3",children:[l.jsx("div",{className:"flex items-start justify-between gap-3",children:l.jsxs("div",{className:"flex gap-2.5 min-w-0",children:[l.jsx("div",{className:ee("w-7 h-7 rounded-lg border flex items-center justify-center font-bold text-xs shrink-0 shadow-sm",qe.color),title:qe.name,children:qe.initial}),l.jsxs("div",{className:"min-w-0",children:[l.jsx("h3",{className:"text-xs font-bold tracking-tight text-foreground line-clamp-2 break-all font-mono",title:K.name,children:K.name.split("/").pop()}),l.jsxs("div",{className:"flex items-center gap-2 flex-wrap mt-1",children:[l.jsx("span",{className:"text-[9px] font-mono text-muted-foreground bg-background/40 px-1.5 py-0.5 rounded border border-border/30",children:K.quant||"GGUF"}),Ae&&l.jsxs("span",{className:"flex items-center gap-1 text-[9px] font-semibold text-emerald-400 uppercase tracking-wider",children:[l.jsx(Zf,{className:"h-3 w-3 animate-pulse"})," Warm"]}),K.role&&l.jsx(oo,{role:K.role,dense:!0}),b(K.role)&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-background/40 border border-border/40 text-[9px] font-semibold text-muted-foreground",title:"Lebenswichtig für Lucy — geschützt vor Löschen/Entladen.",children:"🔒 geschützt"}),v&&P(K.name)&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-fuchsia-500/10 border border-fuchsia-500/30 text-[9px] font-mono text-fuchsia-300 font-bold uppercase",title:"Ko-resident in der brains-Gruppe — bleibt mit dem Hirn gemeinsam warm, verdrängt es nicht.",children:"🧠 Ko-resident"}),v&&K.prompt_cache&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-cyan-500/10 border border-cyan-500/20 text-[9px] font-mono text-cyan-400 font-bold uppercase",title:"Prompt Caching aktiv",children:"PC"}),v&&(K.spec_active?l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-emerald-500/10 border border-emerald-500/20 text-[9px] font-mono text-emerald-400 font-bold uppercase",title:`Speculative Decoding aktiv (Draft: ${K.spec_draft_model})`,children:"SPEC"}):K.spec_draft_model?l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-amber-500/10 border border-amber-500/20 text-[9px] font-mono text-amber-400 font-bold uppercase",title:`Draft gesetzt (${K.spec_draft_model}), aber INAKTIV — --spec-type fehlt oder Vocab inkompatibel. Über 'Spec' neu konfigurieren.`,children:"SPEC?"}):null),v&&K.parallel_slots>1&&l.jsxs("span",{className:"px-1.5 py-0.5 rounded bg-violet-500/10 border border-violet-500/20 text-[9px] font-mono text-violet-400 font-bold uppercase",title:`${K.parallel_slots} parallele Slots aktiv`,children:["SLOTS: ",K.parallel_slots]}),K.incomplete&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-amber-500/10 border border-amber-500/20 text-[9px] font-mono text-amber-400 font-bold uppercase",title:"GGUF-Datei fehlt — Modell kann nicht geladen werden",children:"⚠ Datei fehlt"})]})]})]})}),l.jsx("div",{className:"border-t border-border/30 pt-3 flex flex-wrap gap-1",children:l.jsx(H2,{caps:K.capabilities})})]}),l.jsxs("div",{className:"space-y-3 pt-1",children:[l.jsxs("div",{className:"grid grid-cols-2 gap-2 text-[10px] font-mono text-muted-foreground",children:[l.jsxs("div",{className:"flex items-center gap-1.5 p-2 bg-background/20 rounded-lg border border-border/20",children:[l.jsx(cu,{className:"h-3.5 w-3.5 text-primary/80"}),l.jsxs("div",{children:[l.jsx("div",{className:"text-[8px] uppercase tracking-wider font-semibold text-muted-foreground/60",children:"Größe"}),l.jsx("div",{className:"text-foreground font-semibold",children:_r(K.size_bytes)})]})]}),l.jsxs("div",{className:"flex items-center gap-1.5 p-2 bg-background/20 rounded-lg border border-border/20",children:[l.jsx(E4,{className:"h-3.5 w-3.5 text-primary/80"}),l.jsxs("div",{children:[l.jsx("div",{className:"text-[8px] uppercase tracking-wider font-semibold text-muted-foreground/60",children:"Kontext"}),l.jsx("div",{className:"text-foreground font-semibold",children:Rw(K.ctx)})]})]})]}),Se&&l.jsxs("div",{className:"p-3 bg-amber-500/5 border border-amber-500/30 rounded-xl space-y-2 flex flex-col justify-between shrink-0",children:[l.jsxs("div",{className:"text-[9px] font-semibold text-amber-400 flex items-center gap-1",children:[l.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-amber-400 animate-ping"}),l.jsxs("span",{children:["Upgrade verfügbar: ",Se.repo.split("/").pop()]})]}),l.jsxs("button",{onClick:()=>me(Se.repo,K.role,K.quant||"Q4_K_M",K.capabilities.tools!=="no"),className:"h-7 w-full flex items-center justify-center gap-1 rounded-lg bg-amber-500 text-black text-[10px] font-bold hover:bg-amber-400 transition-colors cursor-pointer",children:[l.jsx(_s,{className:"h-3 w-3"})," Smart-Swap starten"]})]}),l.jsxs("div",{className:"flex items-center gap-1.5 border-t border-border/20 pt-3 mt-auto",children:[(()=>{const G=b(K.role),Ie=Ae&&G,Xt=K.incomplete&&!Ae||Ie;return l.jsx("button",{onClick:()=>Ae?J(K.name):te(K.name),disabled:Xt,title:Ie?`„${ir(K.role).label}" bleibt geladen (geschützt).`:void 0,className:ee("flex-1 h-7 rounded-lg text-[9px] font-bold uppercase transition-all border flex items-center justify-center gap-1",Xt?"border-border/30 bg-background/10 text-muted-foreground/50 cursor-not-allowed":Ae?"border-amber-500/30 bg-amber-500/5 hover:bg-amber-500/15 text-amber-400 cursor-pointer":"border-primary/30 bg-primary/5 hover:bg-primary/15 text-primary cursor-pointer"),children:Ie?"🔒 geladen":Ae?"Entladen":"Laden"})})(),v&&l.jsx("button",{onClick:()=>ne(K.name,K.ctx),className:"h-7 px-2.5 rounded-lg border border-border/40 text-[9px] font-bold uppercase hover:bg-accent text-muted-foreground transition-colors cursor-pointer",title:"Kontextlänge anpassen",children:"Ctx"}),v&&E&&l.jsx("button",{onClick:()=>O(K.name),className:ee("h-7 px-2.5 rounded-lg border text-[9px] font-bold uppercase transition-colors cursor-pointer",P(K.name)?"border-fuchsia-500/40 bg-fuchsia-500/10 text-fuchsia-300 hover:bg-fuchsia-500/20":"border-border/40 text-muted-foreground hover:bg-accent"),title:P(K.name)?"Ko-resident (brains): bleibt mit dem Hirn gemeinsam warm. Klick = aus der Gruppe nehmen.":"Zur brains-Gruppe hinzufügen — lädt dann ko-resident neben dem Hirn, statt es zu verdrängen.",children:"🧠"}),v&&l.jsxs("button",{onClick:()=>U(K),className:ee("h-7 px-2.5 rounded-lg border text-[9px] font-bold uppercase transition-colors cursor-pointer flex items-center gap-1",K.spec_active?"border-emerald-500/30 text-emerald-400 hover:bg-emerald-500/10":K.spec_draft_model?"border-amber-500/30 text-amber-400 hover:bg-amber-500/10":"border-border/40 text-muted-foreground hover:bg-accent"),title:"Speculative Draft konfigurieren (Vocab-geprüft)",children:[l.jsx(ha,{className:"h-3 w-3"})," Spec"]}),l.jsx("button",{onClick:()=>Z(K.name),disabled:b(K.role),className:ee("h-7 w-7 rounded-lg border border-border/40 flex items-center justify-center transition-colors",b(K.role)?"text-muted-foreground/40 cursor-not-allowed":"text-muted-foreground hover:text-red-400 hover:bg-red-500/5 cursor-pointer"),"aria-label":"Modell löschen",title:b(K.role)?`„${ir(K.role).label}" ist geschützt und kann nicht gelöscht werden.`:"Modell löschen",children:l.jsx(tv,{className:"h-3.5 w-3.5","aria-hidden":"true"})})]})]})]},K.name)})}):l.jsx("div",{className:"space-y-2",children:se.length===0?l.jsx("div",{className:"text-xs text-muted-foreground border border-dashed border-border/60 rounded-2xl p-12 text-center select-none",children:ge==="in_use"?"Keine Modelle in Benutzung (keine Zuweisung oder warm geladene Modelle).":'Keine Modelle konfiguriert. Verwende den Tab "Modelle finden" zum Herunterladen.'}):se.map(K=>{const Ae=k.includes(K.name),Se=B2(K.name);return l.jsxs("div",{className:ee("rounded-xl border bg-card/45 backdrop-blur-md p-3.5 shadow-lg shadow-black/5 flex flex-col sm:flex-row sm:items-center justify-between gap-3 hover:border-primary/40 transition-all",Ae?"border-primary/45":K.role?"border-primary/30 bg-primary/5":"border-border/60"),children:[l.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[l.jsx("div",{className:ee("w-8 h-8 rounded-lg border border-border/40 flex items-center justify-center font-bold text-xs shrink-0 shadow-sm",Se.color),title:Se.name,children:Se.initial}),l.jsxs("div",{className:"min-w-0 text-left",children:[l.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[l.jsx("h4",{className:"text-xs font-bold text-foreground truncate max-w-[250px] sm:max-w-[400px] break-all font-mono",title:K.name,children:K.name.split("/").pop()}),K.role&&l.jsx(oo,{role:K.role,dense:!0,className:"shrink-0"}),b(K.role)&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-background/40 border border-border/40 text-[8px] font-semibold text-muted-foreground shrink-0",title:"Lebenswichtig für Lucy — geschützt vor Löschen/Entladen.",children:"🔒 geschützt"}),v&&P(K.name)&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-fuchsia-500/10 border border-fuchsia-500/30 text-[8px] font-mono text-fuchsia-300 font-bold uppercase shrink-0",title:"Ko-resident in der brains-Gruppe — bleibt mit dem Hirn gemeinsam warm.",children:"🧠 Ko-resident"}),v&&K.prompt_cache&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-cyan-500/10 border border-cyan-500/20 text-[8px] font-mono text-cyan-400 font-bold uppercase shrink-0",title:"Prompt Caching aktiv",children:"PC"}),v&&(K.spec_active?l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-emerald-500/10 border border-emerald-500/20 text-[8px] font-mono text-emerald-400 font-bold uppercase shrink-0",title:`Speculative Decoding aktiv (Draft: ${K.spec_draft_model})`,children:"SPEC"}):K.spec_draft_model?l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-amber-500/10 border border-amber-500/20 text-[8px] font-mono text-amber-400 font-bold uppercase shrink-0",title:`Draft gesetzt (${K.spec_draft_model}), aber INAKTIV — --spec-type fehlt oder Vocab inkompatibel.`,children:"SPEC?"}):null),v&&K.parallel_slots>1&&l.jsxs("span",{className:"px-1.5 py-0.5 rounded bg-violet-500/10 border border-violet-500/20 text-[8px] font-mono text-violet-400 font-bold uppercase shrink-0",title:`${K.parallel_slots} parallele Slots aktiv`,children:["SLOTS: ",K.parallel_slots]}),K.incomplete&&l.jsx("span",{className:"px-1.5 py-0.5 rounded bg-amber-500/10 border border-amber-500/20 text-[8px] font-mono text-amber-400 font-bold uppercase shrink-0",title:"GGUF-Datei fehlt",children:"⚠ Datei fehlt"}),Ae&&l.jsxs("span",{className:"flex items-center gap-0.5 text-[8px] font-semibold text-emerald-400 uppercase tracking-wider shrink-0",children:[l.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"})," warm"]})]}),l.jsxs("div",{className:"text-[10px] text-muted-foreground/80 flex items-center gap-2 mt-0.5",children:[l.jsxs("span",{children:["Größe: ",_r(K.size_bytes)]}),l.jsx("span",{children:"•"}),l.jsxs("span",{children:["Kontext: ",Rw(K.ctx)]}),l.jsx("span",{children:"•"}),l.jsx("span",{className:"font-mono text-[9px]",children:K.quant||"GGUF"})]})]})]}),l.jsxs("div",{className:"flex items-center gap-3 shrink-0 self-end sm:self-auto",children:[l.jsx("div",{className:"hidden lg:flex flex-wrap gap-1",children:l.jsx(H2,{caps:K.capabilities})}),l.jsxs("div",{className:"flex items-center gap-1.5",children:[(()=>{const qe=b(K.role),G=Ae&&qe,Ie=K.incomplete&&!Ae||G;return l.jsx("button",{onClick:()=>Ae?J(K.name):te(K.name),disabled:Ie,title:G?`„${ir(K.role).label}" bleibt geladen (geschützt).`:void 0,className:ee("h-7 px-3 rounded-lg text-[9px] font-bold uppercase transition-all border flex items-center gap-1",Ie?"border-border/30 bg-background/10 text-muted-foreground/50 cursor-not-allowed":Ae?"border-amber-500/30 bg-amber-500/5 hover:bg-amber-500/15 text-amber-400 cursor-pointer":"border-primary/30 bg-primary/5 hover:bg-primary/15 text-primary cursor-pointer"),children:G?"🔒 geladen":Ae?"Entladen":"Laden"})})(),v&&l.jsx("button",{onClick:()=>ne(K.name,K.ctx),className:"h-7 px-2.5 rounded-lg border border-border/40 text-[9px] font-bold uppercase hover:bg-accent text-muted-foreground transition-all cursor-pointer",title:"Kontextlänge anpassen",children:"Ctx"}),v&&E&&l.jsx("button",{onClick:()=>O(K.name),className:ee("h-7 px-2.5 rounded-lg border text-[9px] font-bold uppercase transition-colors cursor-pointer",P(K.name)?"border-fuchsia-500/40 bg-fuchsia-500/10 text-fuchsia-300 hover:bg-fuchsia-500/20":"border-border/40 text-muted-foreground hover:bg-accent"),title:P(K.name)?"Ko-resident (brains): bleibt mit dem Hirn gemeinsam warm. Klick = aus der Gruppe nehmen.":"Zur brains-Gruppe hinzufügen — lädt dann ko-resident neben dem Hirn, statt es zu verdrängen.",children:"🧠"}),v&&l.jsxs("button",{onClick:()=>U(K),className:ee("h-7 px-2.5 rounded-lg border text-[9px] font-bold uppercase transition-all cursor-pointer flex items-center gap-1",K.spec_active?"border-emerald-500/30 text-emerald-400 hover:bg-emerald-500/10":K.spec_draft_model?"border-amber-500/30 text-amber-400 hover:bg-amber-500/10":"border-border/40 text-muted-foreground hover:bg-accent"),title:"Speculative Draft konfigurieren (Vocab-geprüft)",children:[l.jsx(ha,{className:"h-3 w-3"})," Spec"]}),l.jsx("button",{onClick:()=>Z(K.name),disabled:b(K.role),className:ee("h-7 w-7 rounded-lg flex items-center justify-center border border-border/40 transition-all",b(K.role)?"text-muted-foreground/40 cursor-not-allowed":"text-muted-foreground hover:text-red-400 hover:bg-red-500/5 cursor-pointer"),"aria-label":"Modell löschen",title:b(K.role)?`„${ir(K.role).label}" ist geschützt und kann nicht gelöscht werden.`:"Modell löschen",children:l.jsx(tv,{className:"h-3.5 w-3.5","aria-hidden":"true"})})]})]})]},K.name)})})]}),D&&l.jsx(vX,{role:D,roleRec:F,models:j,onAssign:K=>{M(D,K),B(null)},onClose:()=>B(null)}),Y&&l.jsx(pX,{model:Y,onClose:()=>U(null),onChanged:N}),g]})}const kX=[{key:"popular",label:"Beliebt",q:""},{key:"coder",label:"Coder",q:"coder"},{key:"vision",label:"Vision",q:"vision"},{key:"reasoning",label:"Reasoning",q:"reasoning"},{key:"small",label:"Klein (≤4B)",q:"3B"}],jX=["fast","heavy","coder","vision","hermes","scout"],SX=new Intl.NumberFormat(void 0,{notation:"compact",maximumFractionDigits:1});function K2(e){return SX.format(e)}function NX(){const{data:e}=yi(),t=(e==null?void 0:e.models)??[],[r,n]=y.useState(""),[a,o]=y.useState([]),[u,c]=y.useState(!1),[f,h]=y.useState(""),[m,g]=y.useState("popular"),[v,b]=y.useState(""),[j,k]=y.useState(null),[S,N]=y.useState([]),[E,A]=y.useState("Q4_K_M"),[P,_]=y.useState(""),[O,D]=y.useState(null),[B,F]=y.useState(!1),[z,Y]=y.useState({});async function U(M){c(!0),h("");try{const H=await je(`/api/hf/search?q=${encodeURIComponent(M)}`);o(H.results),H.results.length||h("Keine Ergebnisse.")}catch(H){h(`Suche fehlgeschlagen: ${H}`)}finally{c(!1)}}y.useEffect(()=>{U("")},[]);function he(M){g(M.key),n(""),U(M.q)}function ue(){g(""),U(r)}async function ge(M,H,ne){F(!1);try{const Z=await je(`/api/fit?params_b=0&quant=${encodeURIComponent(H)}&ctx=8192&name=${encodeURIComponent(M)}&role=${encodeURIComponent(ne)}`);D(Z)}catch{D(null)}}async function ie(M){if(j===M){k(null);return}k(M),N([]),D(null),_(""),F(!1),h("Analysiere Repository…");try{const H=await je(`/api/hf/quants?repo=${encodeURIComponent(M)}`);N(H.quants);const ne=H.quants.includes("Q4_K_M")?"Q4_K_M":H.quants[0]||"Q4_K_M";A(ne),h(H.quants.length?"":"Keine GGUF-Dateien in diesem Repo gefunden."),H.quants.length&&ge(H.repo,ne,"")}catch(H){h(`Fehler: ${H}`)}}function se(){const M=v.trim();M&&(o(H=>H.some(ne=>ne.repo===M)?H:[{repo:M,downloads:0,likes:0},...H]),b(""),ie(M))}const X=P?t.find(M=>(M.role||"").toLowerCase()===P):void 0;async function te(M){if((O==null?void 0:O.fit.level)==="too_tight"&&!B){F(!0);return}Y(H=>({...H,[M]:"Starte…"}));try{await je("/api/models/install",{method:"POST",body:JSON.stringify({repo:M,quant:E,role:P||void 0,jinja:!0})}),Y(H=>({...H,[M]:"Download läuft"})),F(!1)}catch{Y(ne=>({...ne,[M]:"Fehler"}))}}const J=M=>{var ne;const H=((ne=M.split("/").pop())==null?void 0:ne.toLowerCase().replace(/-gguf$/i,""))||"";return H.length>3&&t.some(Z=>Z.name.toLowerCase().includes(H))},I=M=>M==="perfect"?"text-emerald-400 border-emerald-500/40 bg-emerald-500/10":M==="marginal"?"text-amber-400 border-amber-500/40 bg-amber-500/10":"text-red-400 border-red-500/40 bg-red-500/10";return l.jsxs("div",{className:"space-y-5",children:[l.jsxs("div",{className:"flex gap-2",children:[l.jsxs("div",{className:"relative flex-1",children:[l.jsx(py,{className:"absolute left-3 top-2.5 h-4 w-4 text-muted-foreground"}),l.jsx("input",{value:r,onChange:M=>n(M.target.value),onKeyDown:M=>M.key==="Enter"&&ue(),"aria-label":"HuggingFace durchsuchen",type:"search",spellCheck:!1,placeholder:"HuggingFace durchsuchen (z.B. Qwen Coder, Llama-3.1, gemma)…",className:"w-full h-10 pl-9 pr-3 rounded-xl border border-border/60 bg-background/40 text-xs outline-none focus:ring-1 focus:ring-primary/50 text-foreground"})]}),l.jsx("button",{onClick:ue,className:"h-10 px-5 rounded-xl bg-primary text-primary-foreground text-xs font-semibold hover:opacity-90 transition-all cursor-pointer",children:"Suchen"})]}),l.jsx("div",{className:"flex items-center gap-2 flex-wrap",children:kX.map(M=>l.jsxs("button",{onClick:()=>he(M),className:ee("flex items-center gap-1.5 rounded-full px-3 py-1.5 text-[11px] font-semibold transition-all cursor-pointer border",m===M.key?"bg-primary/15 text-primary border-primary/30":"border-border/50 text-muted-foreground hover:text-foreground hover:border-border"),children:[M.key==="popular"&&l.jsx(s4,{className:"h-3 w-3"}),M.label]},M.key))}),u?l.jsx("div",{className:"text-xs text-muted-foreground py-10 text-center",children:"Lade GGUF-Modelle von HuggingFace…"}):l.jsxs("div",{className:"space-y-2",children:[a.map(M=>{const H=j===M.repo,ne=J(M.repo),Z=M.repo.includes("/")?M.repo.split("/")[0]:"—",me=M.repo.split("/").pop();return l.jsxs("div",{className:ee("rounded-xl border bg-card/45 backdrop-blur-md transition-all",H?"border-primary/40 shadow-lg shadow-primary/5":"border-border/50 hover:border-primary/30"),children:[l.jsxs("button",{onClick:()=>ie(M.repo),className:"w-full flex items-center gap-3 p-3.5 text-left cursor-pointer",children:[l.jsxs("div",{className:"min-w-0 flex-1",children:[l.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[l.jsx("span",{className:"text-xs font-bold font-mono text-foreground truncate max-w-[280px]",title:M.repo,children:me}),ne&&l.jsxs("span",{className:"flex items-center gap-1 text-[8px] font-bold text-emerald-400 uppercase tracking-wider bg-emerald-500/10 border border-emerald-500/20 px-1.5 py-0.5 rounded",children:[l.jsx(or,{className:"h-2.5 w-2.5"})," installiert"]})]}),l.jsxs("div",{className:"text-[10px] text-muted-foreground/80 flex items-center gap-3 mt-0.5 font-mono",children:[l.jsx("span",{children:Z}),l.jsxs("span",{className:"flex items-center gap-1",children:[l.jsx(_s,{className:"h-3 w-3"})," ",K2(M.downloads)]}),M.likes>0&&l.jsxs("span",{className:"flex items-center gap-1",children:[l.jsx(h4,{className:"h-3 w-3"})," ",K2(M.likes)]})]})]}),H?l.jsx(AN,{className:"h-4 w-4 text-muted-foreground shrink-0"}):l.jsx(EN,{className:"h-4 w-4 text-muted-foreground shrink-0"})]}),H&&l.jsx("div",{className:"border-t border-border/30 p-3.5 space-y-3",children:S.length===0?l.jsx("div",{className:"text-[11px] text-muted-foreground font-mono",children:f||"Lade Quants…"}):l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[l.jsx("label",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground",children:"Quant"}),l.jsx("select",{value:E,onChange:pe=>{A(pe.target.value),ge(M.repo,pe.target.value,P)},"aria-label":"Quantisierung",className:"h-8 rounded-lg border border-border/60 bg-background/40 px-2 text-xs text-foreground font-semibold outline-none",children:S.map(pe=>l.jsx("option",{value:pe,className:"bg-popover text-foreground",children:pe},pe))}),l.jsx("label",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground ml-1",children:"Rolle"}),l.jsxs("select",{value:P,onChange:pe=>{_(pe.target.value),ge(M.repo,E,pe.target.value)},"aria-label":"Rolle",title:"Optional — bestimmt Auto-Konfiguration + setup-bewussten Kontext",className:"h-8 rounded-lg border border-border/60 bg-background/40 px-2 text-xs text-foreground font-semibold outline-none",children:[l.jsx("option",{value:"",className:"bg-popover text-foreground",children:"keine"}),jX.map(pe=>l.jsx("option",{value:pe,className:"bg-popover text-foreground",children:pe},pe))]}),l.jsx("button",{onClick:()=>te(M.repo),disabled:!!z[M.repo]&&z[M.repo]==="Download läuft",className:ee("h-8 px-3.5 ml-auto rounded-lg text-xs font-semibold transition-all cursor-pointer flex items-center gap-1.5",B?"bg-red-500 text-white hover:opacity-90":"bg-primary text-primary-foreground hover:opacity-90"),children:z[M.repo]?z[M.repo]:B?l.jsxs(l.Fragment,{children:[l.jsx(gn,{className:"h-3.5 w-3.5"})," OOM — trotzdem laden"]}):l.jsxs(l.Fragment,{children:[l.jsx(_s,{className:"h-3.5 w-3.5"})," Herunterladen"]})})]}),O&&l.jsxs("div",{className:ee("flex flex-wrap items-center gap-x-3 gap-y-1 rounded-lg border px-3 py-2 text-[11px] font-medium",I(O.fit.level)),children:[l.jsx("span",{className:"font-bold uppercase tracking-wide",children:O.fit.text}),l.jsxs("span",{className:"font-mono opacity-90",children:["~",O.params_b,"B · ~",O.fit.req_gb," GB / ",O.sys_ram_gb," GB · ~",O.fit.tps," t/s"]}),O.fit.level!=="too_tight"?l.jsxs("span",{className:"font-mono opacity-80",children:["ctx → ",(O.assigned_ctx/1024).toFixed(0),"k"]}):l.jsx("span",{className:"opacity-90",children:"— passt nicht, würde beim Laden abstürzen (OOM)."})]}),X&&l.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-amber-500/40 bg-amber-500/10 px-3 py-2 text-[11px] text-amber-400",children:[l.jsx(gn,{className:"h-3.5 w-3.5 mt-0.5 shrink-0"}),l.jsxs("span",{children:["Rolle ",l.jsxs("strong",{children:["„",P,'"']})," hält aktuell ",l.jsx("strong",{children:X.name.split("/").pop()})," — wird beim Download übernommen."]})]})]})})]},M.repo)}),!a.length&&!u&&l.jsx("div",{className:"text-xs text-muted-foreground py-10 text-center",children:f||"Keine Ergebnisse."})]}),l.jsxs("div",{className:"border-t border-border/30 pt-4 flex flex-col sm:flex-row gap-2 items-stretch sm:items-center",children:[l.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground shrink-0",children:"Direkt:"}),l.jsx("input",{value:v,onChange:M=>b(M.target.value),onKeyDown:M=>M.key==="Enter"&&se(),"aria-label":"Repository oder URL direkt eingeben",spellCheck:!1,placeholder:"org/repo oder HF-URL (z.B. unsloth/Qwen2.5-Coder-7B-Instruct-GGUF)",className:"flex-1 h-9 rounded-lg border border-border/60 bg-background/40 px-3 text-xs outline-none focus:ring-1 focus:ring-primary/50 text-foreground font-mono"}),l.jsx("button",{onClick:se,className:"h-9 px-4 rounded-lg border border-border/60 bg-background/20 text-xs font-semibold hover:border-primary/50 hover:bg-background/40 transition-all cursor-pointer whitespace-nowrap",children:"Laden"})]})]})}const EX={fast:{title:"Schnelles Alltags-Hirn",desc:"Schnelle MoE-Antworten für Chat, Zusammenfassungen und alltägliche Aufgaben.",icon:ha},heavy:{title:"Schweres Reasoning",desc:"Große Modelle für komplexe Logik, Mathematik und tiefgründiges Planen.",icon:vo},coder:{title:"Coden & Entwicklung",desc:"Autovervollständigung, Refactoring und Codegenerierung direkt in deiner IDE.",icon:Os},vision:{title:"Bilder & Vision",desc:"Verarbeitet Bilder, Screenshots und visuelle Diagramme in multimodalen Chats.",icon:vu},hermes:{title:"Lucys Hirn (Agent)",desc:"Lucys dauer-warmes Agent-Hirn mit Tool-Calling — bleibt ko-resident, lädt nie kalt nach.",icon:QM},scout:{title:"Multimodal-Allrounder",desc:"Multimodaler Allrounder für schnelle Antworten, Übersetzungen und Alltag.",icon:Jg}};function AX(){const{data:e,isLoading:t,error:r}=MD(),{data:n}=yi(),{data:a}=sh(),o=(n==null?void 0:n.models)??[],u=r?String(r):"",[c,f]=y.useState({}),[h,m]=y.useState({}),[g,v]=y.useState("recommended");async function b(j,k,S,N){f(E=>({...E,[j]:"Starte..."}));try{await je("/api/models/install",{method:"POST",body:JSON.stringify({repo:j,role:k,quant:S,jinja:N})}),f(E=>({...E,[j]:"Download läuft"}))}catch{f(A=>({...A,[j]:"Fehler"}))}}return l.jsxs("div",{className:"space-y-6",children:[l.jsx("div",{className:"flex rounded-xl border border-border/60 bg-card/45 backdrop-blur-md p-1 w-fit",children:[["recommended","Empfohlen"],["browse","Stöbern & Suchen"]].map(([j,k])=>l.jsx("button",{onClick:()=>v(j),className:ee("rounded-lg px-4 py-1.5 text-xs font-semibold tracking-wide transition-all cursor-pointer",g===j?"bg-primary text-primary-foreground shadow-md shadow-primary/10":"text-muted-foreground hover:text-foreground"),children:k},j))}),g==="browse"?l.jsx(NX,{}):t?l.jsx("div",{className:"text-xs text-muted-foreground py-12 text-center",children:"Analysiere Hardware und suche passende GGUF-Empfehlungen…"}):u||!e?l.jsxs("div",{className:"rounded-xl border border-red-500/20 bg-red-500/5 p-4 text-xs text-red-400",children:["Empfehlungsdienst temporär nicht erreichbar (",u,")."]}):l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"text-[10px] font-mono text-muted-foreground bg-background/25 border border-border/40 p-4 rounded-xl flex flex-col sm:flex-row sm:items-center justify-between gap-3 shadow-sm",children:[l.jsxs("div",{children:["Modell-Registry geladen für ",l.jsxs("span",{className:"text-foreground font-bold",children:[e.sys_ram_gb," GB"]})," System-RAM."]}),l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsx(L4,{className:"h-3.5 w-3.5 text-primary fill-primary/20"}),l.jsx("span",{children:"Empfehlungen sind automatisch auf deine Box-Hardware optimiert."})]})]}),l.jsx("div",{className:"grid gap-6 md:grid-cols-2",children:e.categories.map(j=>{const k=EX[j.role]||{title:j.title||j.role,desc:"Spezifisches Modell für diese Systemrolle.",icon:my},S=k.icon,N=o.find(D=>D.role===j.role||(D.aliases||[]).includes(j.role)),E=a==null?void 0:a.model_list.find(D=>D.role===j.role),A=j.models.find(D=>D.repo===j.recommended)||j.models[0];if(!A)return null;const P=c[A.repo],_=j.models.filter(D=>D.repo!==j.recommended),O=!!h[j.role];return l.jsxs("div",{className:ee("rounded-2xl border bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10 flex flex-col justify-between gap-5 transition-all duration-300 hover:border-primary/40",N?"border-border/60":"border-primary/20 shadow-primary/5"),children:[l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between gap-3",children:[l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary/10 border border-primary/20 flex items-center justify-center text-primary shadow-sm shrink-0",children:l.jsx(S,{className:"h-5.5 w-5.5"})}),l.jsxs("div",{children:[l.jsx("h3",{className:"text-sm font-bold tracking-tight text-foreground",children:k.title}),l.jsxs("span",{className:"text-[9px] font-mono text-muted-foreground uppercase bg-background/50 px-1.5 py-0.5 rounded border border-border/30 inline-block mt-0.5",children:["Rolle: ",j.role]})]})]}),N?l.jsxs("span",{className:"flex items-center gap-1.5 text-[9px] font-bold text-emerald-400 uppercase tracking-wider bg-emerald-500/10 border border-emerald-500/20 px-2.5 py-1 rounded-lg",children:[l.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"}),"Aktiviert"]}):l.jsx("span",{className:"text-[9px] font-bold text-primary/70 uppercase tracking-wider bg-primary/10 border border-primary/20 px-2.5 py-1 rounded-lg",children:"Frei"})]}),l.jsx("p",{className:"text-xs text-muted-foreground leading-relaxed",children:k.desc}),l.jsx("div",{className:"p-3.5 rounded-xl bg-background/35 border border-border/30 space-y-2.5",children:N?l.jsxs("div",{className:"space-y-1.5",children:[l.jsx("div",{className:"text-[9px] font-bold uppercase tracking-wider text-muted-foreground/60",children:"Aktive GGUF-Belegung"}),l.jsx("div",{className:"text-xs font-mono font-bold text-foreground truncate",title:N.name,children:N.name.split("/").pop()}),l.jsxs("div",{className:"text-[10px] text-muted-foreground/80 flex items-center gap-2",children:[l.jsxs("span",{children:["Größe: ",fv(N.size_bytes||0)]}),l.jsx("span",{children:"•"}),l.jsxs("span",{children:["Quant: ",N.quant||"GGUF"]})]})]}):l.jsxs("div",{className:"space-y-1.5",children:[l.jsx("div",{className:"text-[9px] font-bold uppercase tracking-wider text-primary/80",children:"Empfohlenes Modell"}),l.jsx("div",{className:"text-xs font-mono font-bold text-foreground truncate",title:A.name,children:A.name}),l.jsxs("div",{className:"text-[10px] text-muted-foreground/80 flex items-center gap-2 flex-wrap",children:[l.jsxs("span",{children:["Ersteller: ",A.author]}),l.jsx("span",{children:"•"}),l.jsxs("span",{children:["Quant: ",A.quant]})]}),l.jsx("div",{className:"flex items-center gap-1.5 pt-0.5",children:l.jsx(lX,{fit:A.fit})})]})}),l.jsx("div",{className:"pt-1",children:N?E?l.jsxs("div",{className:"space-y-2",children:[l.jsxs("div",{className:"text-[9px] font-semibold text-amber-400 flex items-center gap-1.5",children:[l.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-amber-400 animate-ping shrink-0"}),l.jsxs("span",{children:["Bessere Version in der Registry: ",E.repo.split("/").pop()]})]}),l.jsxs("button",{onClick:()=>b(E.repo,j.role,A.quant||"Q4_K_M",A.caps.tools!=="no"),disabled:!!c[E.repo],className:"h-8 w-full flex items-center justify-center gap-1.5 rounded-lg bg-amber-500 text-black text-xs font-bold hover:bg-amber-400 disabled:opacity-50 transition-all cursor-pointer shadow-md shadow-amber-500/10",children:[l.jsx(_s,{className:"h-3.5 w-3.5"}),c[E.repo]||"Auf neue Version aktualisieren"]})]}):l.jsxs("div",{className:"h-8 flex items-center justify-center gap-1.5 text-[10px] font-bold text-emerald-400 uppercase tracking-wide bg-emerald-500/5 border border-emerald-500/10 rounded-lg select-none",children:[l.jsx(or,{className:"h-4 w-4"})," Auf neuestem Stand"]}):l.jsxs("button",{onClick:()=>b(A.repo,j.role,A.quant||"Q4_K_M",A.caps.tools!=="no"),disabled:!!P,className:ee("h-8 w-full flex items-center justify-center gap-1.5 rounded-lg text-xs font-bold transition-all cursor-pointer border",P?"border-primary/40 bg-primary/5 text-primary":"bg-primary text-primary-foreground hover:opacity-90 shadow-md shadow-primary/10"),children:[l.jsx(_s,{className:"h-3.5 w-3.5"}),P||"Optimales Modell einsetzen"]})})]}),_.length>0&&l.jsxs("div",{className:"border-t border-border/20 pt-3",children:[l.jsxs("button",{onClick:()=>m(D=>({...D,[j.role]:!O})),className:"flex items-center gap-1.5 text-[10px] text-muted-foreground/80 hover:text-foreground transition-colors cursor-pointer",children:[O?l.jsx(AN,{className:"h-3 w-3"}):l.jsx(EN,{className:"h-3 w-3"}),l.jsxs("span",{children:["Alternative Empfehlungen anzeigen (",_.length,")"]})]}),O&&l.jsx("div",{className:"mt-2.5 space-y-2 max-h-36 overflow-y-auto pr-1 scrollbar-thin",children:_.map(D=>l.jsxs("div",{className:"p-2 rounded-lg bg-background/25 border border-border/20 flex items-center justify-between gap-3",children:[l.jsxs("div",{className:"min-w-0",children:[l.jsx("div",{className:"text-[10px] font-mono font-bold text-foreground truncate",title:D.name,children:D.name}),l.jsxs("div",{className:"text-[9px] text-muted-foreground flex items-center gap-1.5 mt-0.5",children:[l.jsxs("span",{children:["Quant: ",D.quant]}),l.jsx("span",{children:"•"}),l.jsx("span",{children:D.fit.text})]})]}),l.jsx("button",{onClick:()=>b(D.repo,j.role,D.quant||"Q4_K_M",D.caps.tools!=="no"),disabled:!!c[D.repo],className:"h-6 px-2.5 rounded bg-background/40 hover:bg-background/80 border border-border/40 text-[9px] font-bold text-foreground transition-all cursor-pointer shrink-0 disabled:opacity-50",children:c[D.repo]||"Installieren"})]},D.repo))})]})]},j.role)})})]})]})}function CX(){const[e,t]=y.useState("cockpit");return l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row justify-between sm:items-center gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Modell-Manager"}),l.jsx("p",{className:"text-sm text-muted-foreground",children:"Verwalte deine Modelle und passe das Gateway-Routing live über das interaktive Cockpit an."})]}),l.jsx("div",{className:"flex rounded-xl border border-border/60 bg-card/45 backdrop-blur-md p-1 self-start",children:["cockpit","discover"].map(r=>l.jsx("button",{onClick:()=>t(r),className:ee("rounded-lg px-4 py-1.5 text-xs font-semibold tracking-wide uppercase transition-all cursor-pointer",e===r?"bg-primary text-primary-foreground shadow-md shadow-primary/10":"text-muted-foreground hover:text-foreground"),children:r==="cockpit"?"Cockpit":"Modelle finden"},r))})]}),l.jsx(mX,{}),l.jsx("div",{className:"transition-all duration-300",children:e==="cockpit"?l.jsx(GO,{}):l.jsx(AX,{})})]})}const PX={zed:"Zed: settings.json",kilo:"Kilo: Einstellungen → API Provider",claude_code:"env / Übersetzer"};function G2({line:e,loading:t}){return t||!e?l.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-semibold text-muted-foreground",children:[l.jsx(eh,{className:"h-3 w-3 animate-spin"})," prüfe…"]}):e.ok?l.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-semibold text-emerald-400",children:[l.jsx(CN,{className:"h-3 w-3"})," ",e.detail]}):l.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-semibold text-red-400",children:[l.jsx(t4,{className:"h-3 w-3"})," ",e.detail]})}function V2({tool:e,fileName:t,accent:r,copied:n,onCopy:a}){return l.jsxs("div",{className:"flex flex-col border border-border/60 bg-black/60 rounded-2xl overflow-hidden shadow-2xl",children:[l.jsxs("div",{className:"flex h-11 items-center justify-between px-4 border-b border-border/40 bg-black/40 shrink-0",children:[l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsx("span",{className:"h-3 w-3 rounded-full bg-red-500/80"}),l.jsx("span",{className:"h-3 w-3 rounded-full bg-amber-500/80"}),l.jsx("span",{className:"h-3 w-3 rounded-full bg-emerald-500/80"})]}),l.jsx("div",{className:"flex items-center gap-1.5 text-[10px] font-mono text-muted-foreground/75 bg-background/30 px-3 py-1 rounded-md border border-border/20",children:l.jsx("span",{children:t})}),l.jsxs("button",{onClick:a,className:"flex h-7 px-2.5 items-center gap-1.5 rounded-lg border border-border/40 bg-background/30 text-[10px] font-semibold text-muted-foreground hover:text-foreground hover:bg-background/60 transition-all cursor-pointer",children:[n?l.jsx(or,{className:"h-3.5 w-3.5 text-emerald-400"}):l.jsx(ev,{className:"h-3.5 w-3.5"}),l.jsx("span",{children:n?"Kopiert":"Kopieren"})]})]}),l.jsx("pre",{className:ee("p-5 overflow-x-auto text-xs font-mono whitespace-pre leading-relaxed scrollbar-thin select-text bg-black/10",r==="teal"?"text-cyan-200/90":"text-violet-200/90"),children:l.jsx("code",{children:e.snippet})})]})}function VO(){const[e,t]=y.useState(localStorage.getItem("mc_host")||"192.168.178.151"),[r,n]=y.useState(localStorage.getItem("mc_mcp_path")||""),[a,o]=y.useState("zed"),[u,c]=y.useState(null),f=new URLSearchParams({host:e});r&&f.set("mcp_path",r);const{data:h,error:m}=TD(f.toString()),{data:g,isLoading:v}=DD(),b=m?String(m):"";function j(E){t(E),E&&localStorage.setItem("mc_host",E)}function k(E){n(E),localStorage.setItem("mc_mcp_path",E)}const S=h==null?void 0:h.tools[a];async function N(E,A){A&&(await navigator.clipboard.writeText(A),c(E),setTimeout(()=>c(null),1500))}return l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Verbindung & Integration"}),l.jsxs("p",{className:"text-sm text-muted-foreground",children:["Binde deinen lokalen Agenten an die Box an — über ",l.jsx("span",{className:"text-foreground",children:"zwei getrennte Leitungen"}),": das Modell (Gateway) und das geteilte Gedächtnis (MCP)."]})]}),l.jsxs("div",{className:"p-5 rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md shadow-lg shadow-black/10",children:[l.jsxs("div",{className:"grid gap-4 md:grid-cols-[170px_1fr] items-center",children:[l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-background/40 p-4 text-center",children:[l.jsx(p4,{className:"h-7 w-7 mx-auto text-muted-foreground"}),l.jsx("div",{className:"mt-2 text-sm font-semibold text-foreground",children:"Dein lokaler Agent"}),l.jsx("div",{className:"text-[11px] text-muted-foreground",children:"Cline · Cursor · Zed …"})]}),l.jsxs("div",{className:"flex flex-col gap-2.5",children:[l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx(Xd,{className:"h-4 w-4 text-muted-foreground shrink-0"}),l.jsxs("div",{className:"flex-1 rounded-xl border border-primary/25 bg-primary/5 px-3.5 py-2.5",children:[l.jsxs("div",{className:"flex items-center justify-between gap-2",children:[l.jsxs("div",{className:"flex items-center gap-2 text-xs font-semibold text-primary",children:[l.jsx($n,{className:"h-3.5 w-3.5"})," Leitung 1 — Modell"]}),l.jsx(G2,{line:g==null?void 0:g.gateway,loading:v})]}),l.jsx("div",{className:"mt-1 text-[11px] font-mono text-primary/80",children:"Gateway · :9001/v1 · Lanes chat / coding"})]})]}),l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx(Xd,{className:"h-4 w-4 text-muted-foreground shrink-0"}),l.jsxs("div",{className:"flex-1 rounded-xl border border-violet-500/25 bg-violet-500/5 px-3.5 py-2.5",children:[l.jsxs("div",{className:"flex items-center justify-between gap-2",children:[l.jsxs("div",{className:"flex items-center gap-2 text-xs font-semibold text-violet-300",children:[l.jsx(vo,{className:"h-3.5 w-3.5"})," Leitung 2 — Gedächtnis"]}),l.jsx(G2,{line:g==null?void 0:g.memory,loading:v})]}),l.jsx("div",{className:"mt-1 text-[11px] font-mono text-violet-300/80",children:"MCP · mcp_memory.py · separat"})]})]})]})]}),l.jsxs("p",{className:"mt-3.5 text-[11px] text-muted-foreground leading-relaxed",children:["Der Gateway liefert ",l.jsx("span",{className:"text-foreground",children:"nur das LLM"}),". Das geteilte Gedächtnis läuft über einen",l.jsx("span",{className:"text-foreground",children:" eigenen MCP-Server"})," — beide werden unabhängig eingerichtet."]})]}),l.jsxs("div",{className:"grid gap-4 md:grid-cols-2 p-5 rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md shadow-lg shadow-black/10",children:[l.jsxs("div",{className:"space-y-1.5",children:[l.jsxs("label",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground flex items-center gap-1.5",children:[l.jsx(d4,{className:"h-3.5 w-3.5 text-primary"})," Box LAN IP-Adresse"]}),l.jsx("input",{value:e,onChange:E=>j(E.target.value),"aria-label":"Box LAN IP-Adresse",spellCheck:!1,placeholder:"z.B. 192.168.178.151",className:"w-full h-9 rounded-lg border border-border/60 bg-background/40 px-3 font-mono text-xs outline-none focus:ring-1 focus:ring-primary/50 text-foreground"})]}),l.jsxs("div",{className:"space-y-1.5",children:[l.jsxs("label",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground flex items-center gap-1.5",children:[l.jsx(l4,{className:"h-3.5 w-3.5 text-violet-400"})," Lokaler MCP-Scriptpfad",l.jsx("span",{className:"text-violet-400/70 normal-case font-semibold tracking-normal",children:"(nur Leitung 2)"})]}),l.jsx("input",{value:r,onChange:E=>k(E.target.value),"aria-label":"Lokaler MCP-Scriptpfad",spellCheck:!1,placeholder:"z.B. F:\\Coding Stuff\\mission-control-2\\mcp\\mcp_memory.py",className:"w-full h-9 rounded-lg border border-border/60 bg-background/40 px-3 font-mono text-xs outline-none focus:ring-1 focus:ring-violet-500/50 text-foreground"})]})]}),b&&l.jsxs("div",{className:"rounded-xl border border-red-500/20 bg-red-500/5 p-4 text-xs text-red-400",children:["Fehler beim Generieren der Snippets: ",b]}),h&&l.jsxs("div",{className:"grid gap-5 lg:grid-cols-2",children:[l.jsxs("div",{className:"space-y-3 rounded-2xl border border-border/60 border-t-2 border-t-primary/70 bg-card/30 p-4",children:[l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2 text-sm font-space font-bold text-foreground",children:[l.jsx("span",{className:"flex h-5 w-5 items-center justify-center rounded-md bg-primary/15 text-primary text-[11px]",children:"1"}),"Modell anbinden"]}),l.jsx("p",{className:"text-[11px] text-muted-foreground mt-0.5",children:"Wähle dein Tool — das Snippet zeigt auf den Gateway."})]}),l.jsx("div",{className:"flex flex-wrap gap-1.5",children:Object.entries(h.tools).map(([E,A])=>l.jsx("button",{onClick:()=>o(E),className:ee("rounded-lg px-3 py-1.5 text-[11px] font-semibold tracking-wide transition-all cursor-pointer",a===E?"bg-primary text-primary-foreground shadow-md shadow-primary/10":"border border-border/50 text-muted-foreground hover:text-foreground"),children:A.label},E))}),S&&l.jsxs(l.Fragment,{children:[S.note&&l.jsxs("div",{className:"flex items-start gap-2.5 p-3 rounded-xl bg-primary/5 border border-primary/20 text-[11px] text-muted-foreground leading-relaxed",children:[l.jsx(fw,{className:"h-4 w-4 text-primary shrink-0 mt-0.5"}),l.jsx("span",{children:S.note})]}),l.jsx(V2,{tool:S,fileName:PX[a]||"config.json",accent:"teal",copied:u==="model",onCopy:()=>N("model",S.snippet)})]})]}),l.jsxs("div",{className:"space-y-3 rounded-2xl border border-border/60 border-t-2 border-t-violet-500/70 bg-card/30 p-4",children:[l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2 text-sm font-space font-bold text-foreground",children:[l.jsx("span",{className:"flex h-5 w-5 items-center justify-center rounded-md bg-violet-500/15 text-violet-300 text-[11px]",children:"2"}),"Gedächtnis anbinden",l.jsx("span",{className:"text-[10px] font-medium text-muted-foreground normal-case",children:"optional"})]}),l.jsxs("p",{className:"text-[11px] text-muted-foreground mt-0.5",children:["Ein MCP-Block — gilt zusätzlich für ",l.jsx("em",{children:"jedes"})," Tool aus Schritt 1."]})]}),l.jsxs("div",{className:"flex items-start gap-2.5 p-3 rounded-xl bg-violet-500/5 border border-violet-500/20 text-[11px] text-muted-foreground leading-relaxed",children:[l.jsx(fw,{className:"h-4 w-4 text-violet-400 shrink-0 mt-0.5"}),l.jsx("span",{children:h.memory.note})]}),l.jsx(V2,{tool:h.memory,fileName:"mcp.json",accent:"violet",copied:u==="memory",onCopy:()=>N("memory",h.memory.snippet)})]})]})]})}const OX="modulepreload",_X=function(e){return"/"+e},q2={},MX=function(t,r,n){let a=Promise.resolve();if(r&&r.length>0){let u=function(h){return Promise.all(h.map(m=>Promise.resolve(m).then(g=>({status:"fulfilled",value:g}),g=>({status:"rejected",reason:g}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),f=(c==null?void 0:c.nonce)||(c==null?void 0:c.getAttribute("nonce"));a=u(r.map(h=>{if(h=_X(h),h in q2)return;q2[h]=!0;const m=h.endsWith(".css"),g=m?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${h}"]${g}`))return;const v=document.createElement("link");if(v.rel=m?"stylesheet":OX,m||(v.as="script"),v.crossOrigin="",v.href=h,f&&v.setAttribute("nonce",f),document.head.appendChild(v),m)return new Promise((b,j)=>{v.addEventListener("load",b),v.addEventListener("error",()=>j(new Error(`Unable to preload CSS for ${h}`)))})}))}function o(u){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=u,window.dispatchEvent(c),!c.defaultPrevented)throw u}return a.then(u=>{for(const c of u||[])c.status==="rejected"&&o(c.reason);return t().catch(o)})};class IX extends y.Component{constructor(){super(...arguments);qo(this,"state",{error:null})}static getDerivedStateFromError(r){return{error:r}}render(){return this.state.error?l.jsxs("div",{className:"h-[480px] rounded-2xl border border-red-500/20 bg-red-500/5 p-6 text-xs text-red-400 overflow-auto",children:[l.jsx("div",{className:"font-semibold mb-2",children:"Graph konnte nicht gerendert werden"}),l.jsx("pre",{className:"whitespace-pre-wrap break-words text-[11px] leading-relaxed",children:this.state.error.message})]}):this.props.children}}const TX=y.lazy(()=>MX(()=>import("./GraphView-DbX5M6kv.js"),[]).then(e=>({default:e.GraphView}))),Fd=["identity","knowledge","rules","events"],Q2=new Set(["auto","agent","hermes"]),Dg={identity:{label:"Identität",icon:z4,bg:"bg-cyan-500/10",text:"text-cyan-400"},knowledge:{label:"Wissen",icon:Ks,bg:"bg-indigo-500/10",text:"text-indigo-400"},rules:{label:"Regeln",icon:O4,bg:"bg-violet-500/10",text:"text-violet-400"},events:{label:"Ereignisse",icon:PN,bg:"bg-amber-500/10",text:"text-amber-400"}},Y2={label:"Gedächtnis",icon:Zg,text:"text-muted-foreground"},DX={identity:"border-l-cyan-500/80",knowledge:"border-l-indigo-500/80",rules:"border-l-violet-500/80",events:"border-l-amber-500/80"},X2=`Hi Hermes! Lass uns ein kurzes Onboarding machen, damit du dich künftig an mich erinnerst. Stell mir nacheinander ein paar kurze Fragen zu:
|
||
1) wer ich bin und woran ich gerade arbeite,
|
||
2) wie ich angesprochen werden möchte,
|
||
3) meine bevorzugten Tools, Sprachen und Arbeitsweise,
|
||
4) wichtige Regeln/Konventionen, die du beachten sollst,
|
||
5) meine Infrastruktur (Server, Dienste – ohne Geheimnisse).
|
||
Frag immer nur eine Sache auf einmal und fass am Ende zusammen, was du dir gemerkt hast.`;function qO(){const[e,t]=y.useState(""),[r,n]=y.useState(""),[a,o]=y.useState(""),[u,c]=y.useState("knowledge"),[f,h]=y.useState(!1),[m,g]=y.useState(!1),[v,b]=y.useState("liste"),[j,k]=y.useState(!1),S=Kn(),{showAlert:N,showConfirm:E,dialogElement:A}=ya(),{data:P=[]}=lv({}),{data:_=[],error:O}=lv({q:r,category:e}),{data:D}=PD(v==="graph"),B=O?String(O):"",F=()=>{S.invalidateQueries({queryKey:["memory"]}),S.invalidateQueries({queryKey:["memory-graph"]})},z=y.useMemo(()=>{const I=P.length,M=P.filter(H=>Q2.has(H.source)).length;return{total:I,auto:M,manual:I-M,cats:new Set(P.map(H=>H.category)).size}},[P]),Y=P.length===0,U=y.useMemo(()=>{const I=D??{nodes:[],edges:[]};if(!r.trim())return I;const M=r.toLowerCase(),H=I.nodes.filter(Z=>Z.content.toLowerCase().includes(M)),ne=new Set(H.map(Z=>Z.id));return{nodes:H,edges:I.edges.filter(Z=>ne.has(Z.source)&&ne.has(Z.target))}},[D,r]),he=y.useMemo(()=>{const I={};return _.forEach(M=>{var H;(I[H=M.category]??(I[H]=[])).push(M)}),I},[_]),ue=y.useMemo(()=>_.filter(I=>!Fd.includes(I.category)),[_]);async function ge(){a.trim()&&(await je("/api/memory",{method:"POST",body:JSON.stringify({content:a,category:u,source:"ui"})}),o(""),k(!1),F())}function ie(I){E("Eintrag löschen?","Diesen Gedächtnis-Eintrag dauerhaft entfernen?",async()=>{try{await je(`/api/memory/${I}`,{method:"DELETE"}),F()}catch(M){N("Fehler",`Löschen fehlgeschlagen: ${M.message||M}`)}})}async function se(){try{await navigator.clipboard.writeText(X2),g(!0),setTimeout(()=>g(!1),1800)}catch{N("Kopieren fehlgeschlagen","Markiere den Prompt und kopiere ihn manuell (Strg+C).")}}function X(){se(),window.dispatchEvent(new CustomEvent("mc-navigate",{detail:{view:"terminal"}}))}async function te(){h(!0);try{const I=await je("/api/memory/dedupe",{method:"POST",body:JSON.stringify({apply:!1})});if(I.duplicate_count===0){N("Ergebnis","Keine Dubletten gefunden — alles sauber.");return}E("Deduplizierung bestätigen",`${I.duplicate_count} Dublette(n) in ${I.groups.length} Gruppe(n) gefunden. Entfernen?`,async()=>{try{await je("/api/memory/dedupe",{method:"POST",body:JSON.stringify({apply:!0})}),F()}catch(M){N("Fehler",`Fehler beim Löschen: ${M.message}`)}})}catch(I){N("Fehler",`Fehler bei der Deduplizierung: ${I.message}`)}finally{h(!1)}}const J=({value:I,label:M,accent:H})=>l.jsxs("span",{className:ee("flex items-center gap-1.5 text-[11px] rounded-lg px-2.5 py-1 border",H==="auto"?"text-emerald-400 bg-emerald-500/[0.07] border-emerald-500/20":"text-muted-foreground bg-card/40 border-border/50"),children:[H==="auto"&&l.jsx(us,{className:"h-3 w-3"}),l.jsx("b",{className:ee("font-semibold",H==="auto"?"":"text-foreground"),children:I})," ",M]});return l.jsxs("div",{className:"space-y-5",children:[l.jsxs("div",{className:"flex flex-col lg:flex-row lg:items-center justify-between gap-3",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Gedächtnis-Pool"}),l.jsx("p",{className:"text-sm text-muted-foreground",children:"Geteilte Konstitution — Hermes, IDEs & Gateway lesen und lernen hier per MCP."})]}),l.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[l.jsxs("div",{className:"relative",children:[l.jsx("input",{value:r,onChange:I=>n(I.target.value),"aria-label":"Gedächtnis durchsuchen",type:"search",placeholder:"Semantisch suchen…",className:"w-52 h-9 pl-8 pr-3 rounded-lg border border-border/60 bg-card/45 text-xs outline-none focus:ring-1 focus:ring-primary/50 text-foreground"}),l.jsx(py,{className:"absolute left-2.5 top-2.5 h-3.5 w-3.5 text-muted-foreground"})]}),l.jsxs("button",{onClick:()=>k(I=>!I),className:"h-9 px-3 rounded-lg bg-primary text-primary-foreground text-xs font-semibold hover:opacity-90 transition-all flex items-center gap-1.5 cursor-pointer shadow-md shadow-primary/10",children:[l.jsx(ef,{className:"h-4 w-4"})," Eintrag"]}),l.jsx("div",{className:"flex items-center gap-1 p-1 bg-card/30 border border-border/40 rounded-lg",children:[["liste",x4,"Liste"],["graph",M4,"Graph"]].map(([I,M,H])=>l.jsxs("button",{onClick:()=>b(I),className:ee("flex h-7 px-2.5 items-center gap-1.5 text-[11px] font-semibold rounded-md transition-all cursor-pointer",v===I?"bg-primary text-primary-foreground":"text-muted-foreground hover:text-foreground"),children:[l.jsx(M,{className:"h-3.5 w-3.5"})," ",H]},I))}),l.jsx("button",{onClick:te,disabled:f,className:"flex h-9 w-9 items-center justify-center rounded-lg border border-border/60 bg-card hover:border-primary/50 transition-all cursor-pointer shadow-md disabled:opacity-50","aria-label":"Duplikate bereinigen",title:"Deduplizieren",children:l.jsx(us,{className:"h-4 w-4 text-primary","aria-hidden":"true"})})]})]}),!Y&&l.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[l.jsx(J,{value:z.total,label:"Fakten"}),l.jsx(J,{value:z.auto,label:"auto gelernt",accent:"auto"}),l.jsx(J,{value:z.manual,label:"manuell"}),l.jsx(J,{value:z.cats,label:"Kategorien"}),l.jsxs("span",{className:"ml-auto text-[11px] text-muted-foreground/70 flex items-center gap-1.5",children:[l.jsx(us,{className:"h-3 w-3 text-emerald-400"})," lernt automatisch aus Hermes-Gesprächen"]})]}),j&&l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-4 space-y-3",children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsx("div",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Neuen Eintrag anlegen"}),l.jsx("button",{onClick:()=>k(!1),"aria-label":"Schließen",className:"text-muted-foreground hover:text-foreground",children:l.jsx(zn,{className:"h-4 w-4","aria-hidden":"true"})})]}),l.jsx("textarea",{value:a,onChange:I=>o(I.target.value),rows:2,"aria-label":"Eintragstext",placeholder:"Eine Regel, Vorliebe oder einen stabilen Fakt über dich oder das Projekt…",className:"w-full resize-none rounded-xl border border-border/60 bg-background/30 p-3 text-xs outline-none focus:ring-1 focus:ring-primary/50 text-foreground leading-relaxed"}),l.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[l.jsx("select",{value:u,onChange:I=>c(I.target.value),"aria-label":"Kategorie",className:"h-8 rounded-lg border border-border/60 bg-background/50 px-2 text-xs outline-none font-semibold text-foreground cursor-pointer",children:Fd.map(I=>{var M;return l.jsx("option",{value:I,className:"bg-popover text-foreground",children:((M=Dg[I])==null?void 0:M.label)||I},I)})}),l.jsxs("button",{onClick:ge,className:"h-9 px-4 rounded-lg bg-primary text-primary-foreground text-xs font-semibold hover:opacity-90 transition-all flex items-center gap-1.5 cursor-pointer",children:[l.jsx(ef,{className:"h-4 w-4"})," Speichern"]})]})]}),B&&l.jsxs("div",{className:"rounded-xl border border-red-500/20 bg-red-500/5 p-4 text-xs text-red-400",children:["Fehler: ",B]}),Y?l.jsxs("div",{className:"rounded-2xl border border-dashed border-border/60 bg-card/20 p-8 sm:p-10 flex flex-col items-center text-center gap-5",children:[l.jsx("div",{className:"h-14 w-14 rounded-2xl bg-primary/10 flex items-center justify-center",children:l.jsx(k4,{className:"h-7 w-7 text-primary"})}),l.jsxs("div",{className:"space-y-1.5 max-w-lg",children:[l.jsx("h3",{className:"text-base font-semibold text-foreground",children:"Lass Hermes dich kennenlernen"}),l.jsx("p",{className:"text-xs text-muted-foreground leading-relaxed",children:"Statt Fakten einzutippen: führ ein kurzes Onboarding-Gespräch mit Hermes. Was ihr besprecht, merkt sich das Gedächtnis automatisch — du musst nichts manuell pflegen."})]}),l.jsxs("div",{className:"w-full max-w-lg text-left",children:[l.jsxs("div",{className:"flex items-center justify-between mb-1.5",children:[l.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground/60",children:"Sende das an Hermes"}),l.jsx("button",{onClick:se,className:"flex items-center gap-1 text-[10px] font-semibold text-muted-foreground hover:text-foreground transition-colors",children:m?l.jsxs(l.Fragment,{children:[l.jsx(or,{className:"h-3 w-3 text-emerald-400"})," Kopiert"]}):l.jsxs(l.Fragment,{children:[l.jsx(ev,{className:"h-3 w-3"})," Kopieren"]})})]}),l.jsx("pre",{className:"w-full rounded-xl border border-border/60 bg-background/40 p-3.5 text-[11px] leading-relaxed text-foreground/90 whitespace-pre-wrap font-mono",children:X2})]}),l.jsxs("div",{className:"flex flex-wrap items-center justify-center gap-2",children:[l.jsxs("button",{onClick:X,className:"h-9 px-4 rounded-lg bg-primary text-primary-foreground text-xs font-semibold hover:opacity-90 transition-all flex items-center gap-1.5 cursor-pointer",children:[l.jsx(IN,{className:"h-4 w-4"})," Im Terminal starten"]}),l.jsxs("button",{onClick:se,className:"h-9 px-4 rounded-lg border border-border/60 bg-card text-xs font-semibold hover:border-primary/50 transition-all flex items-center gap-1.5 cursor-pointer",children:[m?l.jsx(or,{className:"h-4 w-4 text-emerald-400"}):l.jsx(ev,{className:"h-4 w-4"})," Prompt kopieren"]})]}),l.jsxs("p",{className:"text-[11px] text-muted-foreground/70 flex items-center gap-1.5",children:[l.jsx(_4,{className:"h-3 w-3"})," Funktioniert genauso über Telegram —"," ",l.jsx("button",{onClick:()=>k(!0),className:"underline hover:text-foreground",children:"oder lieber manuell anlegen"}),"."]})]}):v==="graph"?l.jsx(IX,{children:l.jsx(y.Suspense,{fallback:l.jsx("div",{className:"h-[480px] rounded-2xl border border-border/60 bg-card/30 flex items-center justify-center text-xs text-muted-foreground",children:"Graph wird geladen…"}),children:l.jsx(TX,{data:U,onDelete:ie})})}):l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"flex flex-wrap items-center gap-1.5 p-1 bg-card/30 border border-border/40 rounded-xl w-fit",children:[l.jsx("button",{onClick:()=>t(""),className:ee("h-7 px-3 rounded-lg text-[10px] font-semibold uppercase tracking-wider transition-all cursor-pointer",e?"text-muted-foreground hover:text-foreground":"bg-primary text-primary-foreground"),children:"Alle"}),Fd.map(I=>{const M=Dg[I]||Y2,H=M.icon;return l.jsxs("button",{onClick:()=>t(I),className:ee("h-7 px-2.5 rounded-lg text-[10px] font-semibold uppercase tracking-wider transition-all cursor-pointer flex items-center gap-1",e===I?"bg-primary text-primary-foreground":"text-muted-foreground hover:text-foreground"),children:[l.jsx(H,{className:"h-3 w-3"})," ",M.label]},I)})]}),_.length===0?l.jsx("div",{className:"text-xs text-muted-foreground border border-dashed border-border/60 rounded-2xl p-12 text-center",children:"Keine Einträge für die aktuellen Filterkriterien gefunden."}):l.jsx("div",{className:"space-y-5",children:[...Fd,"__other"].map(I=>{const M=I==="__other"?ue:he[I]||[];if(!M.length)return null;const H=Dg[I]||Y2,ne=H.icon;return l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2 mb-2 px-1",children:[l.jsx(ne,{className:ee("h-3.5 w-3.5",H.text)}),l.jsx("span",{className:ee("text-[11px] font-bold uppercase tracking-wider",H.text),children:H.label}),l.jsx("span",{className:"text-[10px] font-mono text-muted-foreground/60 bg-card/50 rounded px-1.5 py-0.5",children:M.length}),l.jsx("div",{className:"ml-1 h-px flex-1 bg-border/30"})]}),l.jsx("div",{className:"space-y-2",children:M.map(Z=>{const me=Q2.has(Z.source);return l.jsxs("div",{className:ee("flex items-start justify-between gap-4 p-3.5 rounded-xl border border-l-4 bg-card/45 backdrop-blur-md border-border/60 hover:border-primary/20 transition-all group",DX[Z.category]||"border-l-muted"),children:[l.jsx("span",{className:"text-xs text-foreground leading-relaxed break-words whitespace-pre-wrap flex-1 min-w-0",children:Z.content}),l.jsxs("div",{className:"flex items-center gap-2 shrink-0",children:[typeof Z.score=="number"&&l.jsxs("span",{className:"text-[9px] font-mono text-primary bg-primary/10 px-1.5 py-0.5 rounded",title:"Relevanz der semantischen Suche",children:[Math.round(Z.score*100),"%"]}),l.jsxs("span",{className:ee("flex items-center gap-1 text-[9px] font-mono px-1.5 py-0.5 rounded",me?"text-emerald-400 bg-emerald-500/10":"text-muted-foreground/60 bg-background/20"),title:me?"Automatisch gelernt":"Manuell angelegt",children:[me&&l.jsx(us,{className:"h-2.5 w-2.5"}),Z.source]}),l.jsx("button",{onClick:()=>ie(Z.id),"aria-label":"Eintrag löschen",title:"Eintrag löschen",className:"h-7 w-7 rounded-lg flex items-center justify-center border border-border/40 text-muted-foreground hover:text-red-400 hover:bg-red-500/5 transition-all opacity-0 group-hover:opacity-100",children:l.jsx(tv,{className:"h-3.5 w-3.5","aria-hidden":"true"})})]})]},Z.id)})})]},I)})})]}),A]})}const RX=["chat","coding","fast","heavy"];function QO(){const{data:e,error:t}=jy(5e3),{data:r}=yi(),{showAlert:n,dialogElement:a}=ya(),o=Kn(),u=t?String(t):"",[c,f]=y.useState(!1),h=(r==null?void 0:r.models)??[];async function m(v){try{await je("/api/agent/brain",{method:"POST",body:JSON.stringify({model:v})}),n("Erledigt",`Hermes-Hirn zeigt jetzt auf das Alias '${v}'. Der Gateway-Dienst wurde neu gestartet.`),o.invalidateQueries({queryKey:Ve.agentStatus}),f(!1)}catch(b){n("Fehler",`Wechsel fehlgeschlagen: ${b.message||b}`)}}async function g(v){try{await je("/api/agent/brain/set",{method:"POST",body:JSON.stringify({model_id:v})}),n("Erledigt","Agent-Hirn gewechselt (warm gehalten). Gateway wurde neugestartet."),o.invalidateQueries({queryKey:Ve.agentStatus}),o.invalidateQueries({queryKey:Ve.models}),f(!1)}catch(b){n("Fehler",`Wechsel fehlgeschlagen: ${b.message||b}`)}}return l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row justify-between sm:items-center gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Hermes Agenten-Cockpit"}),l.jsxs("p",{className:"text-sm text-muted-foreground",children:["Hermes ist ein autonomer Agent, der im Hintergrund der Box läuft (Port ",l.jsx("code",{children:":8642"}),") und seine eigene UI besitzt."]})]}),(e==null?void 0:e.terminal_url)&&l.jsxs("a",{href:Ds(e.terminal_url),target:"_blank",rel:"noopener",className:ee("flex h-9 px-4 items-center gap-1.5 text-xs font-semibold rounded-lg transition-all cursor-pointer shadow-md shrink-0 self-start",e.terminal_reachable?"bg-primary text-primary-foreground hover:opacity-90 shadow-primary/10":"border border-border/60 text-muted-foreground bg-background/20"),children:[l.jsx(Ms,{className:"h-4 w-4"}),l.jsx("span",{children:"Terminal öffnen"})]})]}),u&&l.jsxs("div",{className:"rounded-xl border border-red-500/20 bg-red-500/5 p-4 text-xs text-red-400 font-mono",children:["Status nicht lesbar (",u,")."]}),e&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 shadow-lg shadow-black/10",children:[l.jsxs("div",{className:"mb-4 flex items-center gap-2",children:[l.jsx(pn,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("span",{className:"text-xs font-bold uppercase tracking-wider text-foreground",children:"Agent-Fluss"})]}),l.jsxs("div",{className:"flex flex-col lg:flex-row lg:items-stretch gap-3",children:[l.jsxs("button",{onClick:()=>e.terminal_reachable&&window.open(Ds(e.terminal_url),"_blank"),title:e.terminal_reachable?"Hermes-Terminal öffnen":"Terminal offline",className:"lg:w-40 shrink-0 rounded-xl border border-border/60 bg-background/30 p-3 text-left hover:border-primary/40 transition-all cursor-pointer flex flex-col justify-center",children:[l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsx(Zf,{className:ee("h-3.5 w-3.5",e.terminal_reachable?"text-emerald-400":"text-amber-500")}),l.jsx("span",{className:"text-xs font-semibold text-foreground",children:"Terminal"}),l.jsx("span",{className:ee("ml-auto h-1.5 w-1.5 rounded-full animate-pulse",e.terminal_reachable?"bg-emerald-500":"bg-amber-500")})]}),l.jsx("span",{className:"text-[10px] text-muted-foreground font-mono mt-0.5",children:"hermes chat · Clients"})]}),l.jsx("div",{className:"hidden lg:flex items-center text-muted-foreground text-lg select-none",children:"→"}),l.jsxs("div",{className:"flex-1 flex flex-col gap-2.5",children:[l.jsxs("div",{className:"rounded-xl border border-primary/40 bg-primary/5 px-3.5 py-2.5 flex items-center gap-2",children:[l.jsx(pn,{className:"h-3.5 w-3.5 text-primary"}),l.jsx("span",{className:"text-xs font-semibold text-primary",children:"Agent Gateway"}),l.jsx("span",{className:"text-[11px] font-mono text-muted-foreground",children:":8642"}),l.jsxs("span",{className:ee("ml-auto inline-flex items-center gap-1.5 text-[10px] font-bold uppercase font-mono px-2 py-0.5 rounded-full border",e.gateway_reachable?"bg-emerald-500/10 text-emerald-400 border-emerald-500/20":"bg-red-500/10 text-red-400 border-red-500/20"),children:[l.jsx("span",{className:ee("h-1.5 w-1.5 rounded-full",e.gateway_reachable?"bg-emerald-500 animate-pulse":"bg-red-500")}),e.gateway_reachable?"online":"offline"]})]}),l.jsxs("div",{className:"grid gap-2.5 sm:grid-cols-3",children:[l.jsxs("button",{onClick:()=>f(!0),className:"rounded-xl border border-border/60 bg-background/30 p-3 text-left hover:border-primary/45 transition-all cursor-pointer",children:[l.jsxs("div",{className:"flex items-center gap-1.5 text-muted-foreground",children:[l.jsx($n,{className:"h-3.5 w-3.5 text-primary"}),l.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wider",children:"Hirn"}),l.jsx("span",{className:"ml-auto text-[9px] text-primary/70 font-bold uppercase",children:"wechseln →"})]}),l.jsx("div",{className:"text-[11px] font-mono font-medium text-foreground truncate mt-1",title:e.brain_model,children:e.brain_model||"chat"})]}),l.jsxs("div",{className:"rounded-xl border border-border/60 bg-background/30 p-3",children:[l.jsxs("div",{className:"flex items-center gap-1.5 text-muted-foreground",children:[l.jsx(Uu,{className:"h-3.5 w-3.5 text-primary"}),l.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wider",children:"Verdrahtung"})]}),l.jsxs("div",{className:"text-[10px] font-mono mt-1 flex flex-wrap gap-x-2 text-muted-foreground",children:[l.jsxs("span",{children:["Config: ",e.has_config?"✓":"—"]}),l.jsxs("span",{children:["Skills: ",e.has_skills?"✓":"—"]}),l.jsxs("span",{children:["Memory: ",e.has_memories?"✓":"—"]})]})]}),l.jsxs("div",{className:"rounded-xl border border-border/60 bg-background/30 p-3",children:[l.jsxs("div",{className:"flex items-center gap-1.5 text-muted-foreground",children:[l.jsx(hw,{className:"h-3.5 w-3.5 text-primary"}),l.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wider",children:"PC"}),l.jsx("span",{className:ee("ml-auto h-1.5 w-1.5 rounded-full",e.pc_executor_reachable?"bg-emerald-500 animate-pulse":"bg-amber-500")})]}),l.jsxs("div",{className:ee("text-[11px] font-mono mt-1",e.pc_executor_reachable?"text-emerald-400":"text-muted-foreground"),children:[":7777 ",e.pc_executor_reachable?"verbunden":"offline"]})]})]})]})]})]}),l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-6 space-y-4 shadow-lg shadow-black/10",children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(hw,{className:"h-5 w-5 text-primary"}),l.jsx("h3",{className:"text-sm font-bold uppercase tracking-wider text-foreground",children:"PC Verbindung"})]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("span",{className:ee("h-2 w-2 rounded-full",e.pc_executor_reachable?"bg-emerald-500 animate-pulse":"bg-amber-500")}),l.jsx("span",{className:"text-xs font-semibold text-foreground",children:e.pc_executor_reachable?"Erreichbar":"Nicht verbunden"})]})]}),l.jsxs("div",{className:"grid gap-6 md:grid-cols-2 text-xs text-muted-foreground leading-relaxed text-left",children:[l.jsxs("div",{className:"space-y-3",children:[l.jsxs("p",{children:["Der ",l.jsx("strong",{className:"text-foreground",children:"Hermes PC Executor"})," läuft auf ",l.jsx("code",{className:"text-foreground font-mono px-1 py-0.5 rounded bg-muted/40 border border-border/30",children:"192.168.178.98:7777"})," und ermöglicht Hermes den direkten Zugriff auf deinen Windows-PC — Shell-Befehle, Screenshots, Tastatureingaben."]}),l.jsxs("p",{children:["Hermes erreicht den PC über den MCP-Server ",l.jsx("code",{className:"text-foreground font-mono px-1 py-0.5 rounded bg-muted/40 border border-border/30",children:"hermes-pc-control"}),", der automatisch beim Gateway-Start verbunden wird."]})]}),l.jsx("div",{className:"space-y-3",children:e.pc_executor_reachable?l.jsxs("div",{className:"p-3.5 bg-emerald-500/5 border border-emerald-500/20 rounded-xl space-y-1",children:[l.jsxs("div",{className:"text-emerald-400 font-semibold text-xs flex items-center gap-1.5",children:[l.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-emerald-500 animate-pulse"}),"PC Executor verbunden"]}),l.jsxs("p",{className:"text-[10px]",children:["Hermes kann jetzt per Telegram oder Terminal Befehle auf TobisNicerPC ausführen. Nutze ",l.jsx("code",{className:"text-foreground",children:"pc_shell"}),", ",l.jsx("code",{className:"text-foreground",children:"pc_screenshot"})," oder ",l.jsx("code",{className:"text-foreground",children:"pc_open"}),"."]})]}):l.jsxs("div",{className:"space-y-2",children:[l.jsx("h4",{className:"text-xs font-bold text-foreground",children:"PC Executor starten"}),l.jsxs("p",{children:["Starte ",l.jsx("code",{className:"text-foreground font-mono",children:"start.bat"})," im Ordner ",l.jsx("code",{className:"text-foreground font-mono",children:"client\\hermes-pc\\"})," auf dem Windows-PC und lasse das Fenster offen."]}),l.jsx("div",{className:"p-3 bg-background/25 rounded-xl border border-border/30 font-mono text-[9px] text-cyan-300",children:"client\\hermes-pc\\start.bat"})]})})]})]}),!e.gateway_reachable&&l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-6 space-y-4 shadow-lg shadow-black/10 text-left",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Ks,{className:"h-5 w-5 text-amber-500"}),l.jsx("h3",{className:"text-sm font-bold uppercase tracking-wider text-foreground",children:"Hermes-Agent Diagnostics"})]}),l.jsxs("div",{className:"text-xs text-muted-foreground space-y-3 leading-relaxed",children:[l.jsx("p",{children:"Der Hermes-Dienst ist auf der Box derzeit offline oder kann sich nicht mit dem lokalen llama-swap verbinden."}),l.jsxs("p",{children:["Stelle sicher, dass die systemd-Dienste auf der Box laufen. Du kannst den Status im ",l.jsx("strong",{children:"OS & Updates Drawer"})," prüfen und die Dienste bei Bedarf neu starten."]}),l.jsxs("div",{className:"p-3.5 bg-background/25 rounded-xl border border-border/30 font-mono text-[10px] space-y-1",children:[l.jsx("div",{className:"text-muted-foreground/60",children:"# Dienste manuell auf der Box prüfen:"}),l.jsx("div",{className:"text-primary",children:"systemctl --user status hermes-gateway"}),l.jsx("div",{className:"text-primary",children:"systemctl --user status hermes-terminal"})]}),l.jsxs("p",{children:["Weitere Einrichtungsdetails (Brain-Konfiguration, MCP-Kopplungen, SSH-Tunneling und Such-Engines) findest du in der Dokumentationsdatei:",l.jsx("code",{className:"ml-1 px-1.5 py-0.5 rounded bg-muted/40 text-foreground border border-border/30",children:"docs/HERMES_SETUP.md"}),"."]})]})]})]}),e&&c&&l.jsx("div",{className:"fixed inset-0 z-50 bg-black/60 backdrop-blur-sm flex items-center justify-center p-4 overscroll-contain",role:"dialog","aria-modal":"true","aria-label":"Hermes-Hirn konfigurieren",children:l.jsxs("div",{className:"w-full max-w-md 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:[l.jsxs("div",{className:"flex items-center justify-between border-b border-border/20 pb-2",children:[l.jsxs("h3",{className:"text-xs font-bold uppercase tracking-wider text-primary flex items-center gap-1.5",children:[l.jsx($n,{className:"h-4 w-4"}),l.jsx("span",{children:"Hermes-Hirn konfigurieren"})]}),l.jsx("button",{onClick:()=>f(!1),className:"p-1 rounded hover:bg-accent text-muted-foreground hover:text-foreground cursor-pointer",children:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsxs("div",{className:"space-y-1.5",children:[l.jsx("div",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground",children:"Lane / Gateway-Alias"}),l.jsx("div",{className:"flex flex-wrap gap-1.5",children:RX.map(v=>{const b=e.brain_model===v;return l.jsxs("button",{onClick:()=>m(v),className:ee("px-3 py-1.5 rounded-lg text-xs font-mono font-semibold border transition-all cursor-pointer flex items-center gap-1.5",b?"border-primary/40 bg-primary/10 text-primary":"border-border/30 bg-background/20 text-foreground hover:bg-accent"),children:[v,b&&l.jsx(or,{className:"h-3.5 w-3.5"})]},v)})}),l.jsxs("p",{className:"text-[10px] text-muted-foreground/70",children:["Schlank & flexibel: das Hirn folgt dem Lane-Routing (z.B. ",l.jsx("code",{className:"text-primary",children:"chat"})," = fast↔heavy)."]})]}),l.jsxs("div",{className:"space-y-1.5",children:[l.jsx("div",{className:"text-[10px] font-bold uppercase tracking-wider text-muted-foreground",children:"Installiertes Modell (warm gehalten)"}),l.jsx("div",{className:"space-y-1.5 max-h-56 overflow-y-auto pr-1",children:h.map(v=>{var j;const b=v.role==="hermes";return l.jsxs("button",{onClick:()=>!b&&g(v.name),disabled:b||v.incomplete,className:ee("w-full text-left px-3 py-2.5 rounded-lg text-xs flex items-center justify-between font-mono border transition-all",b?"border-indigo-500/40 bg-indigo-500/10 text-indigo-300":v.incomplete?"border-border/20 bg-background/10 text-muted-foreground/50 cursor-not-allowed":"border-border/30 bg-background/20 text-foreground hover:bg-accent cursor-pointer"),children:[l.jsxs("div",{className:"flex flex-col min-w-0",children:[l.jsx("span",{className:"font-semibold truncate max-w-[280px]",children:(j=v.name.split("/").pop())==null?void 0:j.replace(/\.gguf$/i,"")}),l.jsxs("span",{className:"text-[9px] text-muted-foreground mt-0.5",children:[v.capabilities.params_b?`${v.capabilities.params_b}B`:"?"," · ",v.capabilities.tools!=="no"?"Tools ✓":"ohne Tools",v.role&&` · Rolle: ${v.role}`]})]}),b?l.jsxs("span",{className:"text-[9px] font-bold uppercase text-indigo-300 shrink-0 flex items-center gap-1",children:[l.jsx(or,{className:"h-3.5 w-3.5"})," Aktiv"]}):l.jsx("span",{className:"text-[9px] font-bold uppercase text-primary/70 shrink-0",children:"Warm setzen →"})]},v.name)})})]}),l.jsxs("div",{className:"text-[10px] text-amber-400/80 flex items-start gap-1.5 border-t border-border/20 pt-2.5",children:[l.jsx("span",{children:"💡"}),l.jsxs("span",{children:["Für einen ",l.jsx("strong",{children:"Agenten"}),' sind Hermes-Modelle (natives Tool-Calling) meist die robustere Wahl. Neues Modell? Erst über „Modell-Manager → Modelle finden" laden.']})]})]})}),a]})}function LX(){const{data:e}=jy(5e3),t=e!=null&&e.terminal_url?Ds(e.terminal_url):void 0,r=e==null?void 0:e.terminal_reachable;return l.jsxs("div",{className:"flex h-full flex-col gap-4",children:[l.jsxs("div",{className:"flex flex-wrap items-end justify-between gap-3",children:[l.jsxs("div",{children:[l.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:"Hermes Terminal"}),l.jsxs("p",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:["Interaktiver Agent (",l.jsx("code",{className:"rounded bg-background/40 px-1 font-mono text-[11px] text-primary",children:"hermes chat"}),') mit Tools & PC-Steuerung — „mehr als Chatten".']})]}),l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsxs("span",{className:"flex items-center gap-1.5 text-[11px] font-medium text-muted-foreground",children:[l.jsx("span",{className:`h-2 w-2 rounded-full ${r?"bg-emerald-500 animate-pulse":"bg-amber-500"}`}),r?"online":"offline"]}),t&&l.jsxs("a",{href:t,target:"_blank",rel:"noopener",className:"flex h-8 items-center gap-1.5 rounded-lg border border-border/60 bg-background/20 px-3 text-xs font-semibold text-muted-foreground transition-all hover:border-primary/50 hover:text-foreground",children:[l.jsx(Ms,{className:"h-3.5 w-3.5"})," In neuem Tab"]})]})]}),t?l.jsxs("div",{className:"relative min-h-[68vh] flex-1 overflow-hidden rounded-2xl border border-border/60 bg-black/50 shadow-lg shadow-black/25",children:[r===!1&&l.jsxs("div",{className:"absolute inset-0 z-10 flex flex-col items-center justify-center gap-3 bg-black/70 text-center",children:[l.jsx(gn,{className:"h-8 w-8 text-amber-400"}),l.jsx("div",{className:"text-sm font-semibold text-amber-300",children:"Terminal nicht erreichbar"}),l.jsxs("p",{className:"max-w-sm text-[11px] leading-normal text-muted-foreground",children:["Der ",l.jsx("code",{className:"font-mono text-primary",children:"hermes-terminal"}),"-Dienst (ttyd) läuft nicht. Auf der Box: ",l.jsx("code",{className:"font-mono",children:"systemctl --user restart hermes-terminal"}),"."]})]}),l.jsx("iframe",{src:t,title:"Hermes Terminal",className:"h-full w-full border-0",style:{minHeight:"68vh"}})]}):l.jsxs("div",{className:"flex min-h-[68vh] flex-1 items-center justify-center rounded-2xl border border-border/60 bg-background/20 text-xs text-muted-foreground",children:[l.jsx(MN,{className:"mr-2 h-4 w-4"})," Lade Terminal…"]})]})}const Z2=[{id:"grundlagen",label:"Grundlagen"},{id:"moe",label:"MoE & Quant"},{id:"lokal",label:"Lokal betreiben"},{id:"modelle",label:"Modell-Landschaft"},{id:"gateway",label:"Gateway-Trick"},{id:"mcp",label:"MCP"},{id:"skills",label:"Skills"},{id:"memory",label:"Gedächtnis & RAG"},{id:"agents",label:"Agenten"},{id:"ide",label:"IDE anbinden"},{id:"tricks",label:"Tricks & Kniffe"},{id:"wartung",label:"Sicherheit & Wartung"},{id:"ressourcen",label:"Ressourcen"},{id:"troubleshooting",label:"Troubleshooting"}];function $X(e){var t;(t=document.getElementById(e))==null||t.scrollIntoView({behavior:"smooth",block:"start"})}function Or({id:e,icon:t,color:r,title:n,kicker:a,children:o,wide:u}){return l.jsxs("section",{id:e,className:ee("scroll-mt-20 rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-6 shadow-lg shadow-black/10 space-y-3",u&&"md:col-span-2"),children:[l.jsxs("div",{className:"flex items-center gap-2.5 border-b border-border/20 pb-3",children:[l.jsx(t,{className:ee("h-5 w-5 shrink-0",r)}),l.jsxs("div",{children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-foreground",children:n}),a&&l.jsx("span",{className:ee("text-[9px] font-mono",r),children:a})]})]}),l.jsx("div",{className:"text-xs text-muted-foreground space-y-2.5 leading-relaxed",children:o})]})}function La({children:e}){return l.jsxs("div",{className:"mt-1 rounded-xl border border-primary/25 bg-primary/[0.06] p-3 text-[11px] leading-relaxed",children:[l.jsxs("div",{className:"flex items-center gap-1.5 font-bold text-primary mb-1",children:[l.jsx(us,{className:"h-3 w-3"})," Bei dir konkret"]}),l.jsx("div",{className:"text-muted-foreground space-y-1",children:e})]})}function ze({children:e}){return l.jsx("code",{className:"rounded bg-background/40 border border-border/30 px-1.5 py-0.5 font-mono text-[10px] text-foreground",children:e})}function bt({href:e,name:t,note:r}){return l.jsxs("li",{className:"leading-relaxed",children:[l.jsxs("a",{href:e,target:"_blank",rel:"noopener",className:"text-primary hover:underline font-semibold inline-flex items-center gap-0.5",children:[t,l.jsx(GM,{className:"h-3 w-3 opacity-60"})]}),l.jsxs("span",{className:"text-muted-foreground",children:[" — ",r]})]})}function zX(){const[e,t]=y.useState(!1);return l.jsxs("div",{className:"space-y-7",children:[l.jsxs("div",{className:"rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-6 shadow-lg shadow-black/10 flex items-start gap-4",children:[l.jsx("div",{className:"h-11 w-11 rounded-xl bg-primary/15 flex items-center justify-center shrink-0",children:l.jsx(Zg,{className:"h-6 w-6 text-primary"})}),l.jsxs("div",{className:"space-y-1",children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Die AI-Bibel"}),l.jsxs("p",{className:"text-sm text-muted-foreground leading-relaxed max-w-2xl",children:["Allgemeines Nachschlagewerk für lokale & agentische AI — Konzepte, Tricks, Kniffe und kuratierte Quellen. ",l.jsx("span",{className:"font-semibold text-foreground",children:"Stand Juni 2026."})," ","Das meiste gilt überall; ",l.jsx("span",{className:"text-primary font-semibold",children:'„Bei dir konkret"'}),"-Kästen zeigen, was dein Stack daraus macht."]})]})]}),l.jsx("div",{className:"sticky top-0 z-10 -mx-1 px-1",children:l.jsx("div",{className:"rounded-xl border border-border/50 bg-card/70 backdrop-blur-xl p-2 shadow-lg shadow-black/20",children:l.jsxs("div",{className:"flex items-center gap-1.5 flex-wrap",children:[l.jsx(Jg,{className:"h-3.5 w-3.5 text-primary ml-1 mr-0.5 shrink-0"}),(e?Z2:Z2.slice(0,9)).map(r=>l.jsx("button",{onClick:()=>$X(r.id),className:"rounded-lg px-2.5 py-1 text-[11px] font-semibold text-muted-foreground hover:text-primary hover:bg-primary/10 transition-colors cursor-pointer",children:r.label},r.id)),l.jsx("button",{onClick:()=>t(r=>!r),className:"rounded-lg px-2 py-1 text-[11px] font-semibold text-primary hover:bg-primary/10 transition-colors cursor-pointer",children:e?"weniger":"+ mehr"})]})})}),l.jsxs("div",{className:"grid gap-5 md:grid-cols-2",children:[l.jsxs(Or,{id:"grundlagen",icon:$n,color:"text-cyan-400",title:"1. Wie LLMs ticken",kicker:"Grundlagen",children:[l.jsxs("p",{children:["Ein LLM ist im Kern ein ",l.jsx("strong",{children:"Wahrscheinlichkeits-Rechner für das nächste Token"}),' (Wortteil). Es „weiß" nichts — es setzt fort, was statistisch am plausibelsten ist. Daraus folgt fast alles andere.']}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Tokens"})," sind die Einheit — ~¾ Wort. Ein- und Ausgabe werden in Tokens gezählt."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Kontextfenster"}),' = wie viele Tokens das Modell gleichzeitig „sehen" kann (Prompt + Antwort). Voll = Anfang fällt raus.']}),l.jsxs("li",{children:[l.jsx("strong",{children:"Parameter"})," = die trainierten Gewichte. Training ist einmalig, ",l.jsx("strong",{children:"Inferenz"})," ist jede Antwort."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Temperatur / Sampling"})," steuert Zufall: niedrig = deterministisch/präzise (Code), hoch = kreativ."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Halluzination"})," ist kein Bug, sondern die Kehrseite des Ratens. Gegenmittel: Grounding via Tools/RAG, Verifikation."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Reasoning-/Thinking-Modelle"}),' „denken" in unsichtbaren Tokens vor der Antwort — besser bei Logik, langsamer/teurer.']})]})]}),l.jsxs(Or,{id:"moe",icon:my,color:"text-violet-400",title:"2. MoE & Quantisierung",kicker:"Mehr Modell, weniger Last",children:[l.jsxs("p",{children:[l.jsx("strong",{children:"Mixture of Experts (MoE):"})," Statt für jedes Token das ganze Netz zu aktivieren, wählt ein",l.jsx("em",{children:" Router"})," nur ein paar spezialisierte ",l.jsx("em",{children:"Experts"}),' aus. So läuft ein 100B-Modell mit der aktiven Rechenlast eines viel kleineren (z.B. „122B total / 10B aktiv").']}),l.jsxs("p",{children:[l.jsx("strong",{children:"Quantisierung:"})," Gewichte von FP16 auf weniger Bits eindampfen — kleiner & schneller bei minimalem Qualitätsverlust. Faustregel:"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx(ze,{children:"Q8"})," nahezu verlustfrei, größter Footprint"]}),l.jsxs("li",{children:[l.jsx(ze,{children:"Q6_K"})," sehr gut, guter Mittelweg"]}),l.jsxs("li",{children:[l.jsx(ze,{children:"Q4_K_M"})," der Sweet-Spot für lokal — viel Modell pro GB"]})]}),l.jsxs(La,{children:["VRAM/RAM ist die harte Grenze — ",l.jsx("strong",{children:"darum"})," ist beides hier zentral: MoE lässt 100B+ überhaupt laufen, Quant entscheidet, was reinpasst. Dein Line-up fährt durchweg ",l.jsx(ze,{children:"Q4_K_M"}),"/",l.jsx(ze,{children:"Q6_K"}),"."]})]}),l.jsxs(Or,{id:"lokal",icon:th,color:"text-emerald-400",title:"3. Lokal betreiben: Engines & Backends",kicker:"llama.cpp, vLLM & Co.",wide:!0,children:[l.jsxs("div",{className:"grid md:grid-cols-2 gap-4",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{children:[l.jsx("strong",{children:"Inference-Engines"})," — was die Modelle ausführt:"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"llama.cpp / GGUF"})," — der De-facto-Standard für lokal, CPU+GPU, läuft überall."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Ollama / LM Studio"})," — bequeme Wrapper mit One-Click-Downloads (LM Studio mit GUI)."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"vLLM / TGI"})," — Server-Engines für maximalen Durchsatz auf dicken GPUs."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"llama-swap"})," — Proxy, der ",l.jsx("em",{children:"mehrere"})," Modelle hinter ",l.jsx("em",{children:"einem"})," Port hält und je nach Anfrage automatisch ein-/aussattelt."]})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{children:[l.jsx("strong",{children:"GPU-Backends"})," — wie gerechnet wird:"]}),l.jsx("ul",{className:"list-disc pl-4 space-y-1",children:l.jsxs("li",{children:[l.jsx(ze,{children:"CUDA"})," NVIDIA · ",l.jsx(ze,{children:"ROCm"})," AMD · ",l.jsx(ze,{children:"Vulkan"})," herstellerübergreifend · ",l.jsx(ze,{children:"Metal"})," Apple"]})}),l.jsxs("p",{className:"pt-1",children:[l.jsx("strong",{children:"Begriffe, die immer wiederkommen:"})," Kontext (",l.jsx(ze,{children:"-c"}),"), Slots/Parallel, KV-Cache, Modell-TTL/Swap, ",l.jsx("strong",{children:"Speculative Decoding"})," (kleines Draft-Modell rät voraus → schneller)."]})]})]}),l.jsxs(La,{children:["Deine Box hat eine AMD-APU (gfx1151). ",l.jsx("strong",{children:"Einschränkung & Trick:"})," dort schlägt ",l.jsx(ze,{children:"Vulkan/RADV"})," das offizielle ",l.jsx(ze,{children:"ROCm"})," bei Token-Generierung um ~12–22 % — darum läuft die Engine auf Vulkan.",l.jsx(ze,{children:"llama-swap"})," hält die Alltags-Hirne dauerwarm; ",l.jsx(ze,{children:"coder"})," nutzt Spec-Decoding."]})]}),l.jsxs(Or,{id:"modelle",icon:Zd,color:"text-sky-400",title:"4. Modell-Landschaft",kicker:"Stand Juni 2026",wide:!0,children:[l.jsxs("div",{className:"grid md:grid-cols-2 gap-4",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsx("p",{children:l.jsx("strong",{children:"Open-Weight (lokal nutzbar):"})}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Qwen"})," (Alibaba) — starke Allrounder + Coder + Vision, viele Größen/MoE."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Llama"})," (Meta), ",l.jsx("strong",{children:"Gemma"})," (Google), ",l.jsx("strong",{children:"Phi"})," (Microsoft) — solide Open-Familien."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"DeepSeek"}),", ",l.jsx("strong",{children:"Mistral/Mixtral"})," — kräftige MoE-/Reasoning-Modelle."]})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsx("p",{children:l.jsx("strong",{children:"Frontier (Cloud-API):"})}),l.jsx("ul",{className:"list-disc pl-4 space-y-1",children:l.jsxs("li",{children:[l.jsx("strong",{children:"Claude"})," (Anthropic), ",l.jsx("strong",{children:"GPT"})," (OpenAI), ",l.jsx("strong",{children:"Gemini"})," (Google) — die stärksten Allrounder, aber nicht lokal."]})}),l.jsxs("p",{className:"pt-1",children:[l.jsx("strong",{children:"Modellwahl nach Aufgabe:"})," schnelles Alltags-Hirn · großes Logik-Hirn für harte Tasks · dediziertes Code-Modell · multimodal für Bilder · Embedding-Modell fürs Gedächtnis."]})]})]}),l.jsx("p",{className:"text-[11px] italic",children:'Leaderboards (HF, LMArena) sind grobe Orientierung — der einzige Benchmark, der zählt, ist deine eigene Aufgabe. Vorsicht vor „Benchmaxxing".'}),l.jsxs(La,{children:["Dein Line-up via llama-swap: ",l.jsx(ze,{children:"fast"})," (Alltag/Vision/MoE) · ",l.jsx(ze,{children:"heavy"})," (schwere Logik) ·",l.jsx(ze,{children:"coder"})," · ",l.jsx(ze,{children:"scout"})," · ",l.jsx(ze,{children:"vision"})," · ",l.jsx(ze,{children:"embed"})," (fürs Gedächtnis) ·",l.jsx(ze,{children:"hermes"})," (Agent-Hirn). Verwalten/tauschen im ",l.jsx("strong",{children:"Modell-Manager"}),"-Tab."]})]}),l.jsxs(Or,{id:"gateway",icon:N4,color:"text-amber-400",title:"5. Der Gateway-Trick",kicker:"OpenAI-kompatibel = überall andocken",children:[l.jsxs("p",{children:["Fast jedes AI-Tool spricht heute das ",l.jsx("strong",{children:"OpenAI-Format"})," (",l.jsx(ze,{children:"/v1/chat/completions"}),"). Ein",l.jsx("strong",{children:" Gateway"})," davor gibt dir ",l.jsx("em",{children:"einen"})," Endpunkt für alles: zentrales Key-Management, Logging und transparentes ",l.jsx("strong",{children:"Routing"})," — der Client merkt nicht, welches Modell tatsächlich antwortet."]}),l.jsxs("p",{children:["Die ",l.jsx(ze,{children:"model:auto"}),'-Idee: du sagst „auto", das Gateway wählt das passende Modell je nach Anfrage und lädt es bei Bedarf.']}),l.jsxs(La,{children:["Dein Gateway: ",l.jsx(ze,{children:"http://192.168.178.151:9001/v1"}),", Model ",l.jsx(ze,{children:"auto"}),", API-Key beliebig. Fertige Configs erzeugt dir der ",l.jsx("strong",{children:"Verbinden"}),"-Tab live — eine Wahrheit, kein Abtippen."]})]}),l.jsxs(Or,{id:"mcp",icon:Jd,color:"text-violet-400",title:"6. MCP — Werkzeuge für Agenten",kicker:"USB-C für AI-Tools",children:[l.jsxs("p",{children:["Das ",l.jsx("strong",{children:"Model Context Protocol"})," (offen, von Anthropic initiiert) standardisiert, wie ein AI-Client mit externen Tools & Datenquellen spricht. Ein ",l.jsx("strong",{children:"MCP-Server"})," bringt Fähigkeiten: Dateien, Web-Fetch, Git, Datenbanken, eigene APIs."]}),l.jsx("p",{children:"Statt für jeden Editor eigene Tools zu schreiben, bindet jeder MCP-fähige Agent denselben Server an."}),l.jsxs("div",{className:"flex items-start gap-1.5 rounded-xl border border-amber-500/25 bg-amber-500/[0.06] p-2.5 text-[11px]",children:[l.jsx(b4,{className:"h-3.5 w-3.5 text-amber-400 shrink-0 mt-0.5"}),l.jsxs("span",{children:[l.jsx("strong",{children:"Sicherheit:"})," ein MCP-Server hat echten Zugriff (Dateien, Shell). Nur vertrauenswürdige Server laufen lassen, Rechte minimal halten, Quelle prüfen."]})]})]}),l.jsxs(Or,{id:"skills",icon:C4,color:"text-emerald-400",title:"7. Agent Skills",kicker:"Wiederverwendbare Fähigkeiten",children:[l.jsxs("p",{children:["Ein ",l.jsx("strong",{children:"Skill"})," ist ein Ordner mit einer ",l.jsx(ze,{children:"SKILL.md"})," (YAML-Kopf + Anleitung, optional Skripte/Beispiele), den der Agent für eine bestimmte Aufgabe lädt — z.B. TDD, Code-Vereinfachung, API-Design."]}),l.jsx("pre",{className:"p-2.5 bg-background/25 rounded-lg border border-border/30 font-mono text-[9px] text-foreground overflow-x-auto whitespace-pre",children:`---
|
||
name: tdd-pro
|
||
description: Treibt Entwicklung mit strikter TDD-Praxis
|
||
---
|
||
# Instructions
|
||
...`}),l.jsxs("p",{children:["Suchen & installieren über die ",l.jsx("strong",{children:"skills.sh"}),"-Registry: ",l.jsx(ze,{children:"npx skills find"})," /",l.jsx(ze,{children:"npx skills add owner/repo"}),". Skills liegen projektweit (vom Agent beim Start gelesen) oder global."]})]}),l.jsxs(Or,{id:"memory",icon:a4,color:"text-indigo-400",title:"8. Gedächtnis & RAG",kicker:"Modelle vergessen — du nicht",wide:!0,children:[l.jsxs("div",{className:"grid md:grid-cols-2 gap-4",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{children:["LLMs sind ",l.jsx("strong",{children:"zustandslos"}),": ohne Hilfe weiß das Modell beim nächsten Turn nichts mehr. Gedächtnis lebt extern."]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Embeddings"})," wandeln Text in Vektoren; ein ",l.jsx("strong",{children:"Vektor-Store"})," (Chroma, …) findet semantisch Ähnliches."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"RAG"})," = relevante Fakten vor dem Turn heraussuchen und einblenden statt alles im Prompt zu halten."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Long-Context vs. RAG:"}),' riesige Fenster sind bequem, aber teuer & „lost in the middle" — gezieltes Abrufen skaliert besser.']})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{children:[l.jsx("strong",{children:"Auto-lernendes Gedächtnis"})," ist die nächste Stufe:"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:["extrahiert Fakten ",l.jsx("em",{children:"selbst"})," aus Gesprächen, statt nur abzuspeichern"]}),l.jsx("li",{children:"dedupliziert semantisch (kein 10× derselbe Fakt)"}),l.jsxs("li",{children:[l.jsx("strong",{children:"Graph-Sicht"})," = Fakten ",l.jsx("em",{children:"plus"})," ihre Beziehungen, nicht nur eine flache Liste"]})]})]})]}),l.jsxs(La,{children:["Dein Gedächtnis (Tab ",l.jsx("strong",{children:"Gedächtnis"}),") ist ",l.jsx("strong",{children:"Mem0"}),"-basiert: auto-lernend & semantisch, ",l.jsx("strong",{children:"graph-first"})," dargestellt, mit 4-Typen-Taxonomie (",l.jsx(ze,{children:"Identität"})," · ",l.jsx(ze,{children:"Wissen"})," · ",l.jsx(ze,{children:"Regeln"})," · ",l.jsx(ze,{children:"Ereignisse"}),"). Einstieg über ein kurzes ",l.jsx("strong",{children:"Hermes-Onboarding-Gespräch"})," im Terminal — der Agent lernt im Hintergrund nach jedem Turn.",l.jsx("br",{}),l.jsx("strong",{children:"Gotcha:"})," ein gelöschter Fakt kann wieder auftauchen, solange die Original-Nachricht noch im Verlauf steht (additive Extraktion)."]})]}),l.jsxs(Or,{id:"agents",icon:pn,color:"text-rose-400",title:"9. Autonome Agenten betreiben",kicker:"LLM in der Schleife",wide:!0,children:[l.jsxs("div",{className:"grid md:grid-cols-2 gap-4",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{children:["Ein ",l.jsx("strong",{children:"Agent"})," ist ein LLM in einer Schleife mit Tools:",l.jsx("em",{children:" denken → Tool aufrufen → Ergebnis beobachten → weiter"}),", bis das Ziel erreicht ist."]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Guardrails"})," (Hard-Stop, Tool-Limits) verhindern Endlos-Loops, wenn ein Tool fehlt oder hängt."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Kontext-Hygiene"})," ist die wichtigste Disziplin: frische Sessions starten — vollgemüllte Historien werden langsam, driften und halluzinieren."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Kanäle:"})," CLI/Terminal, Chat-UI, Messaging (z.B. Telegram), reine API."]})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{children:[l.jsx("strong",{children:"Least Privilege:"})," gib einem Agenten nur die Tools, die er wirklich braucht. Kritische Aktionen (Shell auf dem Host, Löschen, Geld/Deploys) hinter menschliche Freigabe."]}),l.jsxs("p",{children:[l.jsx("strong",{children:"Was sich vollautomatisch lohnt:"})," Modell-Routing, Hintergrund-Gedächtnis, Recherche. ",l.jsx("strong",{children:"Was Freigabe braucht:"})," Systembefehle, Updates/Reboots, permanentes Löschen."]})]})]}),l.jsxs(La,{children:[l.jsx("strong",{children:"Hermes"})," ist dein Box-Agent (Hirn = ",l.jsx(ze,{children:"fast"}),"). Reden tust du mit ihm im",l.jsx("strong",{children:" Terminal"}),"-Tab (Web-Terminal via ttyd) oder per ",l.jsx("strong",{children:"Telegram"}),". Er hat MCP-Server für Gedächtnis, Stack-Steuerung, Web-Fetch und ",l.jsx("strong",{children:"PC-Steuerung"})," (Executor auf deinem Windows-PC). Status & Verdrahtung im ",l.jsx("strong",{children:"Hermes"}),"-Tab."]})]}),l.jsxs(Or,{id:"ide",icon:Os,color:"text-cyan-400",title:"10. IDE / Editor anbinden",kicker:"Vibe-Coding lokal",children:[l.jsxs("p",{children:["Jede ",l.jsx("strong",{children:"OpenAI-kompatible"})," IDE oder Extension lässt sich auf einen lokalen Server umbiegen — Base-URL + Model eintragen, fertig:"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Cline"})," & ",l.jsx("strong",{children:"Roo Code"})," (VS-Code-Extensions, voller Agent + MCP)"]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Cursor"})," (VS-Code-Fork mit Top-Autocomplete)"]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Continue"}),", ",l.jsx("strong",{children:"aider"})," (CLI), ",l.jsx("strong",{children:"OpenCode"})," (Desktop)"]})]}),l.jsxs(La,{children:["Tipp den Kram nicht ab: der ",l.jsx("strong",{children:"Verbinden"}),"-Tab generiert die fertige Config (inkl. MCP-Gedächtnis) pro Tool zum Kopieren. Essenz: Base ",l.jsx(ze,{children:"…:9001/v1"}),", Model ",l.jsx(ze,{children:"auto"}),", Key beliebig."]})]}),l.jsx(Or,{id:"tricks",icon:y4,color:"text-amber-400",title:"11. Tricks & Kniffe",kicker:"Was im Alltag wirklich spart",wide:!0,children:l.jsx("div",{className:"grid md:grid-cols-3 gap-3",children:[["Kontext sauber halten","Neue Session statt Mega-Historie. Drift, Tempo und Halluzination hängen direkt am Kontext-Müll."],["Plan-then-Act","Erst Plan/Vorgehen bestätigen lassen, dann ausführen. Spart teure Holzwege."],["Gezielte Edits","Nie ganze Dateien überschreiben für eine Zeile — Such-/Ersetz-Tools nutzen. Weniger Tokens, weniger Fehler."],["Non-interaktive Befehle","Keine interaktiven Prompts im Agent-Terminal; lange Tasks als Background-Job. Sonst hängt der Loop."],["DevTools koppeln","Browser-/Konsolen-Zugriff geben — der Agent liest echte Fehler statt blind zu raten."],["Richtige Modellwahl","Schnelles Hirn für Alltag, großes für harte Logik, Coder fürs Coden. Nicht alles mit der Kanone."],["Akzeptanzkriterien","Sag konkret, woran „fertig“ erkennbar ist. Vage Prompts → vage Ergebnisse."],["Verifizieren statt vertrauen","Tests/Live-Check fordern. „Sollte funktionieren“ ist kein Beweis."],["Regeln ins Gedächtnis","Wiederkehrende Vorlieben/Konventionen einmal ablegen — der Agent zieht sie selbst."]].map(([r,n])=>l.jsxs("div",{className:"space-y-1 p-3 bg-background/10 rounded-xl border border-border/30",children:[l.jsxs("div",{className:"flex items-center gap-1.5 font-bold text-foreground text-[11px]",children:[l.jsx(ha,{className:"h-3 w-3 text-amber-400"})," ",r]}),l.jsx("p",{className:"text-[11px]",children:n})]},r))})}),l.jsx(Or,{id:"wartung",icon:Ks,color:"text-emerald-400",title:"12. Sicherheit & Wartung",kicker:"Damit's auch morgen noch läuft",wide:!0,children:l.jsxs("div",{className:"grid md:grid-cols-2 gap-4",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{className:"flex items-center gap-1.5 font-bold text-foreground",children:[l.jsx(u4,{className:"h-3.5 w-3.5 text-emerald-400"})," Goldene Regeln"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Ein ungetesteter Restore ist kein Backup."})," Wiederherstellung mindestens einmal echt durchspielen."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Updates können Dinge still zerschießen"})," — gerade bei AI-Stacks (Embeddings, Provider-Interna). Versionen pinnen, Smoke-Test, Post-Check."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Least Privilege"})," für Agenten, MCP-Server und PC-Zugriff. Kritisches hinter Freigabe."]})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("p",{className:"flex items-center gap-1.5 font-bold text-foreground",children:[l.jsx(Uu,{className:"h-3.5 w-3.5 text-emerald-400"})," Bei dir im SystemDrawer"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Backup:"})," tägliches Voll-Zustands-Backup, getesteter ",l.jsx(ze,{children:"restore.sh"})," (Doku in ",l.jsx(ze,{children:"docs/BACKUP.md"}),")."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Updates:"})," git-basierter Update-Check; ",l.jsx("strong",{children:"Hermes-Update-Button"})," mit anschließendem ",l.jsx("strong",{children:"Gehirn-Check"})," (rot, falls das Update das Gedächtnis zerschießt) + Engine-Update."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Dienste & Gefahrenzone:"})," Restart/Logs pro Dienst, kritische Eingriffe getrennt."]})]}),l.jsx("p",{className:"text-[10px] italic",children:'Erreichbar über das System-Icon → Tab „Wartung".'})]})]})}),l.jsxs("section",{id:"ressourcen",className:"scroll-mt-20 md:col-span-2 rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-6 shadow-lg shadow-black/10 space-y-4",children:[l.jsxs("div",{className:"flex items-center gap-2.5 border-b border-border/20 pb-3",children:[l.jsx(Jg,{className:"h-5 w-5 text-primary"}),l.jsxs("div",{children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-foreground",children:"13. Kuratierte Ressourcen & Links"}),l.jsx("span",{className:"text-[9px] font-mono text-primary",children:"Sauber geordnet — die guten Quellen"})]})]}),l.jsxs("div",{className:"grid md:grid-cols-2 gap-5 text-xs",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsxs("div",{className:"font-bold text-foreground flex items-center gap-1.5",children:[l.jsx(Zd,{className:"h-3.5 w-3.5 text-sky-400"})," Modelle & Engines"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1.5",children:[l.jsx(bt,{href:"https://huggingface.co/models",name:"Hugging Face",note:"das Repository für offene Modelle (GGUF, Embeddings, Datasets)."}),l.jsx(bt,{href:"https://github.com/ggml-org/llama.cpp",name:"llama.cpp",note:"die Referenz-Engine für lokale Inferenz."}),l.jsx(bt,{href:"https://github.com/mostlygeek/llama-swap",name:"llama-swap",note:"mehrere Modelle hinter einem Port, Auto-Swap."}),l.jsx(bt,{href:"https://ollama.com",name:"Ollama",note:"einfachster Einstieg, One-Command-Modelle."}),l.jsx(bt,{href:"https://lmstudio.ai",name:"LM Studio",note:"lokale GUI zum Stöbern, Laden & Chatten."}),l.jsx(bt,{href:"https://github.com/vllm-project/vllm",name:"vLLM",note:"Hochdurchsatz-Serving auf dicken GPUs."})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("div",{className:"font-bold text-foreground flex items-center gap-1.5",children:[l.jsx(Jd,{className:"h-3.5 w-3.5 text-violet-400"})," MCP & Skills"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1.5",children:[l.jsx(bt,{href:"https://modelcontextprotocol.io",name:"MCP — offizielle Doku",note:"Spezifikation & Einstieg."}),l.jsx(bt,{href:"https://github.com/modelcontextprotocol/servers",name:"Offizielle MCP-Server",note:"filesystem, git, postgres, fetch & mehr."}),l.jsx(bt,{href:"https://smithery.ai",name:"Smithery",note:"Registry zum Suchen & Auto-Installieren von MCP-Servern."}),l.jsx(bt,{href:"https://glama.ai/mcp/servers",name:"Glama MCP Registry",note:"kuratierte Community-Datenbank."}),l.jsx(bt,{href:"https://skills.sh",name:"skills.sh",note:"Registry & CLI für Agent-Skills."})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("div",{className:"font-bold text-foreground flex items-center gap-1.5",children:[l.jsx(pn,{className:"h-3.5 w-3.5 text-rose-400"})," Agenten & Frameworks"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1.5",children:[l.jsx(bt,{href:"https://github.com/NousResearch/hermes-agent",name:"Hermes Agent (Nous)",note:"der Agent, der auf deiner Box läuft."}),l.jsx(bt,{href:"https://docs.claude.com",name:"Anthropic / Claude Docs",note:"API, Tool-Use, Agent SDK, MCP."}),l.jsx(bt,{href:"https://github.com/cline/cline",name:"Cline",note:"autonomer Coding-Agent für VS Code."}),l.jsx(bt,{href:"https://aider.chat",name:"aider",note:"AI-Pair-Programming im Terminal, git-nativ."}),l.jsx(bt,{href:"https://continue.dev",name:"Continue",note:"Open-Source-Autopilot für IDEs."})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("div",{className:"font-bold text-foreground flex items-center gap-1.5",children:[l.jsx(Zg,{className:"h-3.5 w-3.5 text-amber-400"})," Lernen & Community"]}),l.jsxs("ul",{className:"list-disc pl-4 space-y-1.5",children:[l.jsx(bt,{href:"https://docs.anthropic.com/en/docs/build-with-claude/prompt-engineering/overview",name:"Prompt-Engineering (Anthropic)",note:"die beste praktische Anleitung."}),l.jsx(bt,{href:"https://github.com/anthropics/anthropic-cookbook",name:"Anthropic Cookbook",note:"lauffähige Rezepte für Tools, RAG, Agenten."}),l.jsx(bt,{href:"https://www.promptingguide.ai",name:"Prompt Engineering Guide",note:"herstellerneutrales Nachschlagewerk."}),l.jsx(bt,{href:"https://github.com/mem0ai/mem0",name:"Mem0",note:"die auto-lernende Memory-Schicht hinter deinem Gedächtnis."}),l.jsx(bt,{href:"https://www.reddit.com/r/LocalLLaMA/",name:"r/LocalLLaMA",note:"der Puls der lokalen-LLM-Szene."})]})]})]})]}),l.jsx(Or,{id:"troubleshooting",icon:v4,color:"text-rose-400",title:"14. Troubleshooting",kicker:"Wenn's hakt",wide:!0,children:l.jsxs("ul",{className:"space-y-2 list-disc pl-4",children:[l.jsxs("li",{children:[l.jsx("strong",{children:"Keine Verbindung?"})," Selbes LAN wie die Box? IP/Port stimmen (",l.jsx(ze,{children:":9001"}),")? Backend-Status in der ",l.jsx("strong",{children:"Zentrale"})," prüfen."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Modell antwortet nicht / langsam?"})," In der ",l.jsx("strong",{children:"Zentrale → Dienste"})," schauen, ob ",l.jsx(ze,{children:"llama-swap"})," grün ist; sonst Restart. Erstes Token nach Swap dauert (Modell lädt)."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Agent dreht durch / halluziniert?"})," Frische Session im ",l.jsx("strong",{children:"Terminal"})," starten — meist ist es vollgemüllter Kontext."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Gedächtnis findet nichts?"})," Embedding-Dienst online? Semantisch suchen (Sinn statt exaktem Wort). Leeres Gedächtnis → Hermes-Onboarding starten."]}),l.jsxs("li",{children:[l.jsx("strong",{children:"Update hat etwas zerschossen?"})," Genau dafür gibt es Backup & ",l.jsx(ze,{children:"restore.sh"})," — den getesteten Restore fahren, dann Ursache suchen."]})]})})]}),l.jsx("p",{className:"text-center text-[10px] text-muted-foreground/50 pt-2",children:"Mission Control 2 · AI-Bibel · Stand Juni 2026 — lebendes Dokument, wächst mit dem Stack."})]})}function FX({title:e,hint:t}){return l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold",children:e}),l.jsx("p",{className:"text-sm text-muted-foreground",children:t})]}),l.jsxs("div",{className:"flex flex-col items-center justify-center gap-3 rounded-xl border border-dashed border-border bg-card/50 py-20 text-center",children:[l.jsx(i4,{className:"h-8 w-8 text-muted-foreground"}),l.jsx("div",{className:"text-sm text-muted-foreground",children:"Kommt in einer späteren Phase."})]})]})}const J2=[{id:"mission-control-2",label:"Mission Control",type:"user",reach:"gateway (integr"},{id:"hermes-gateway",label:"Hermes Gateway",type:"user",reach:"hermes-gateway"},{id:"mem0-service",label:"Mem0 (Gedächtnis)",type:"user",reach:"mem0"},{id:"voice-service",label:"Voice (Sprache)",type:"user",reach:"voice"},{id:"hermes-terminal",label:"Hermes Terminal",type:"user",reach:"hermes-terminal"},{id:"llama-swap",label:"Llama Swap",type:"system",reach:"llama-swap"}];function iu({icon:e,iconClass:t,name:r,status:n,available:a,busy:o,actionLabel:u,onAction:c}){return l.jsxs("div",{className:ee("flex items-center gap-3 rounded-lg border px-3 py-2",a?"border-amber-500/30 bg-amber-500/5":"border-border/50 bg-background/20"),children:[l.jsx(e,{className:ee("h-4 w-4 shrink-0",t)}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("div",{className:"text-xs text-foreground truncate",children:r}),l.jsx("div",{className:ee("text-[10px] truncate",a?"text-amber-400/90":"text-muted-foreground"),children:n})]}),l.jsx("button",{onClick:c,disabled:!a||o,className:ee("text-[11px] font-semibold rounded-lg px-2.5 py-1 transition-colors shrink-0",a?"bg-primary text-primary-foreground hover:opacity-90 cursor-pointer":"border border-border/50 text-muted-foreground/40 cursor-default"),children:o?"…":u})]})}function BX({label:e,ok:t,system:r,busy:n,onRestart:a,onLogs:o}){return l.jsxs("div",{className:"flex items-center gap-2.5 rounded-lg border border-border/50 bg-background/20 px-3 py-2",children:[l.jsx("span",{className:ee("w-1.5 h-1.5 rounded-full shrink-0",t===!0?"bg-emerald-500":t===!1?"bg-red-500":"bg-muted-foreground/40")}),l.jsxs("span",{className:"flex-1 text-xs text-foreground truncate",children:[e,r&&l.jsx("span",{className:"text-[9px] text-muted-foreground",children:" (root)"})]}),l.jsx("button",{onClick:a,disabled:n,title:"Neu starten",className:"text-muted-foreground hover:text-primary transition-colors disabled:opacity-50",children:l.jsx(ro,{className:ee("h-3.5 w-3.5",n&&"animate-spin")})}),l.jsx("button",{onClick:o,title:"Logs ansehen",className:"text-muted-foreground hover:text-primary transition-colors",children:l.jsx(o4,{className:"h-3.5 w-3.5"})})]})}function Rg(e){return e==null?"":e>1024**3?`${(e/1024**3).toFixed(2)} GB`:`${(e/1024**2).toFixed(1)} MB`}const UX=/\b(error|fehler|fail(ed|ure)?|fatal|critical|crit|panic|traceback|exception|denied|refused|unable|emerg|alert|oom|killed)\b/i,HX=/\b(warn(ing)?|deprecat\w*|retry(ing)?|timeout|timed out|degraded|missing|not found|nicht gefunden)\b/i;function WX(e){return UX.test(e)?"error":HX.test(e)?"warn":"info"}const KX={error:"text-red-400",warn:"text-amber-300",info:"text-cyan-300/80"};function GX({service:e,text:t,loading:r,logStatus:n,onRefresh:a,onOpenSettings:o}){const[u,c]=y.useState(!1),[f,h]=y.useState(""),m=y.useRef(null),g=y.useMemo(()=>t?t.split(`
|
||
`).map(S=>({t:S,level:WX(S)})):[],[t]),v=y.useMemo(()=>g.filter(S=>S.level!=="info").length,[g]),b=f.trim().toLowerCase(),j=g.filter(S=>(!u||S.level!=="info")&&(!b||S.t.toLowerCase().includes(b))),k=n==="password_required"||n==="incorrect_password";return l.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:[l.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:[l.jsxs("div",{className:"flex items-center gap-1.5 text-[10px] font-mono text-muted-foreground shrink-0",children:[l.jsx(IN,{className:"h-3 w-3 text-primary"}),l.jsx("span",{className:"hidden sm:inline",children:"stdout/stderr —"})," ",e]}),l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsxs("div",{className:"relative",children:[l.jsx(py,{className:"pointer-events-none absolute left-2 top-1/2 h-3 w-3 -translate-y-1/2 text-muted-foreground"}),l.jsx("input",{value:f,onChange:S=>h(S.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"})]}),l.jsxs("button",{onClick:()=>c(S=>!S),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",u?"border-amber-500/50 bg-amber-500/15 text-amber-300":"border-border/50 bg-background/20 text-muted-foreground hover:text-foreground"),children:[l.jsx(gn,{className:"h-3 w-3"}),"Nur Probleme",v>0?` (${v})`:""]}),l.jsx("button",{onClick:a,disabled:r,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:l.jsx(ro,{className:ee("h-3 w-3",r&&"animate-spin")})})]})]}),l.jsx("div",{ref:m,className:"flex-1 overflow-y-auto p-3 text-[10px] font-mono leading-relaxed scrollbar-thin select-text",children:k?l.jsxs("div",{className:"flex h-full flex-col items-center justify-center space-y-3 p-6 text-center",children:[l.jsx(gn,{className:"h-8 w-8 text-amber-400 animate-pulse animate-duration-1000"}),l.jsx("div",{className:"text-xs font-semibold text-amber-300",children:n==="incorrect_password"?"Falsches Sudo-Passwort hinterlegt.":"Sudo-Passwort für systemd-Dienste erforderlich."}),l.jsxs("p",{className:"max-w-xs text-[10px] leading-normal text-muted-foreground",children:["Für das Auslesen der systemd-Logs von ",e," werden Root-Rechte benötigt. Hinterlege dein Passwort in den Einstellungen."]}),l.jsx("button",{onClick:o,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"})]}):r&&!t?l.jsx("span",{className:"text-muted-foreground",children:"Lade Logs…"}):g.length===0?l.jsx("span",{className:"text-muted-foreground",children:"Keine Logeinträge vorhanden."}):j.length===0?l.jsx("span",{className:"text-muted-foreground",children:u?"Keine Fehler oder Warnungen — der Dienst läuft sauber. ✓":"Kein Treffer für den Filter."}):j.map((S,N)=>l.jsx("div",{className:ee("whitespace-pre-wrap",KX[S.level]),children:S.t||" "},N))})]})}function VX({open:e,showAlert:t}){const[r,n]=y.useState(""),[a,o]=y.useState(""),[u,c]=y.useState(!1),[f,h]=y.useState(!1);return y.useEffect(()=>{e&&(n(localStorage.getItem("mc_sudo_password")||""),o(localStorage.getItem("mc_hf_token")||""))},[e]),l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"space-y-2",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Zugangsdaten & Schlüssel"}),l.jsx("p",{className:"text-[10px] text-muted-foreground leading-normal",children:"Diese Daten werden ausschließlich lokal in deinem Browser (localStorage) gespeichert und bei Bedarf an das Backend übertragen."})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("label",{className:"text-xs font-semibold flex items-center gap-1.5",children:[l.jsx(Ks,{className:"h-4 w-4 text-amber-400"}),"Host Sudo-Passwort"]}),l.jsxs("div",{className:"relative",children:[l.jsx("input",{type:u?"text":"password",value:r,onChange:m=>n(m.target.value),"aria-label":"Host Sudo-Passwort",name:"sudo-password",autoComplete:"off",spellCheck:!1,placeholder:"Sudo-Passwort für System-Operationen",className:"w-full h-10 pl-3 pr-10 text-xs bg-background/40 border border-border/60 rounded-lg outline-none focus:border-primary transition-colors text-foreground"}),l.jsx("button",{type:"button",onClick:()=>c(!u),"aria-label":u?"Passwort verbergen":"Passwort anzeigen",className:"absolute inset-y-0 right-0 flex items-center pr-3 text-muted-foreground hover:text-foreground transition-colors",children:u?l.jsx(dw,{className:"h-4 w-4","aria-hidden":"true"}):l.jsx(vu,{className:"h-4 w-4","aria-hidden":"true"})})]}),l.jsx("p",{className:"text-[9px] text-muted-foreground leading-normal",children:"Wird benötigt für systemd-Dienste (Llama Swap logs/restart), OS-Update (apt) und Reboot."})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsxs("label",{className:"text-xs font-semibold flex items-center gap-1.5",children:[l.jsx(m4,{className:"h-4 w-4 text-violet-400"}),"HuggingFace API Token"]}),l.jsxs("div",{className:"relative",children:[l.jsx("input",{type:f?"text":"password",value:a,onChange:m=>o(m.target.value),"aria-label":"HuggingFace API Token",name:"hf-token",autoComplete:"off",spellCheck:!1,placeholder:"hf_…",className:"w-full h-10 pl-3 pr-10 text-xs bg-background/40 border border-border/60 rounded-lg outline-none focus:border-primary transition-colors text-foreground"}),l.jsx("button",{type:"button",onClick:()=>h(!f),"aria-label":f?"Token verbergen":"Token anzeigen",className:"absolute inset-y-0 right-0 flex items-center pr-3 text-muted-foreground hover:text-foreground transition-colors",children:f?l.jsx(dw,{className:"h-4 w-4","aria-hidden":"true"}):l.jsx(vu,{className:"h-4 w-4","aria-hidden":"true"})})]}),l.jsx("p",{className:"text-[9px] text-muted-foreground leading-normal",children:"Erlaubt das Herunterladen von geschützten oder Gate-restricted Modellen direkt über Mission Control."})]}),l.jsxs("div",{className:"flex gap-3 pt-2",children:[l.jsx("button",{onClick:()=>{localStorage.setItem("mc_sudo_password",r),localStorage.setItem("mc_hf_token",a),t("Erfolgreich","Einstellungen erfolgreich lokal gespeichert.")},className:"flex-1 h-9 flex items-center justify-center text-xs font-semibold text-primary-foreground bg-primary hover:bg-primary/90 rounded-lg transition-colors shadow shadow-primary/10 cursor-pointer",children:"Speichern"}),l.jsx("button",{onClick:()=>{n(""),o(""),localStorage.removeItem("mc_sudo_password"),localStorage.removeItem("mc_hf_token"),t("Gelöscht","Zugangsdaten gelöscht.")},className:"h-9 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:"Zurücksetzen"})]})]})}function qX({detail:e,maintenanceJob:t,onClose:r,onApply:n}){var f,h;const a=e.data,o={os:{icon:Ks,cls:"text-cyan-400",title:"OS-Pakete (apt)"},engine:{icon:th,cls:"text-violet-400",title:"Inferenz-Engine (llama.cpp)"},swap:{icon:_N,cls:"text-fuchsia-400",title:"Router (llama-swap)"},hermes:{icon:pn,cls:"text-amber-400",title:"Hermes-Agent"}}[e.kind],u=o.icon,c=a?e.kind==="os"?(a.count??0)===0:e.kind==="hermes"?(a.behind??0)===0:a.installed_build!=null&&a.latest_build!=null&&a.latest_build<=a.installed_build:!0;return l.jsxs("div",{className:"fixed inset-0 z-[60] flex items-center justify-center p-4",children:[l.jsx("div",{className:"absolute inset-0 bg-black/70 backdrop-blur-sm",onClick:r}),l.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:[l.jsxs("div",{className:"flex h-14 shrink-0 items-center justify-between border-b border-border/40 px-5",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(u,{className:ee("h-4.5 w-4.5",o.cls)}),l.jsx("h3",{className:"text-sm font-semibold",children:o.title})]}),l.jsx("button",{onClick:r,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:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsx("div",{className:"flex-1 overflow-y-auto p-5 text-xs space-y-3 scrollbar-thin",children:e.loading?l.jsxs("div",{className:"flex h-24 items-center justify-center gap-2 text-muted-foreground",children:[l.jsx(ro,{className:"h-4 w-4 animate-spin"})," Details werden geladen…"]}):a!=null&&a.error?l.jsx("div",{className:"rounded-lg border border-red-500/30 bg-red-500/5 p-3 text-red-400",children:a.error}):l.jsxs(l.Fragment,{children:[(a==null?void 0:a.action_needed)!=null&&l.jsxs("div",{className:ee("flex items-start gap-2 rounded-lg border p-3",a.action_needed?"border-amber-500/40 bg-amber-500/10":"border-emerald-500/40 bg-emerald-500/10"),children:[a.action_needed?l.jsx(gn,{className:"h-4 w-4 text-amber-400 shrink-0 mt-0.5"}):l.jsx(CN,{className:"h-4 w-4 text-emerald-400 shrink-0 mt-0.5"}),l.jsxs("div",{className:"min-w-0",children:[l.jsxs("div",{className:ee("text-xs font-semibold",a.action_needed?"text-amber-300":"text-emerald-300"),children:["Musst du etwas tun? ",a.action_needed?"Ja":"Nein — die Box regelt das (Fangnetz)"]}),a.action_needed&&a.action_text&&l.jsx("div",{className:"mt-0.5 text-[11px] text-foreground/90",children:a.action_text})]})]}),(a==null?void 0:a.summary)&&l.jsxs("div",{className:"rounded-lg border border-primary/25 bg-primary/5 p-3 space-y-1",children:[l.jsx("div",{className:"text-[10px] font-bold uppercase tracking-wider text-primary",children:"Was dieses Update bedeutet (Zusammenfassung der Box)"}),l.jsx("pre",{className:"whitespace-pre-wrap text-[11px] leading-relaxed text-foreground/90 font-sans",children:a.summary})]}),e.kind==="os"?l.jsxs(l.Fragment,{children:[((a==null?void 0:a.count)??0)===0?l.jsx("div",{className:"text-muted-foreground",children:"Keine Pakete zu aktualisieren — System ist aktuell."}):l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"text-muted-foreground",children:[a.count," Paket(e) werden aktualisiert:"]}),l.jsx("div",{className:"space-y-1",children:a.packages.map(m=>l.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:[l.jsxs("span",{className:"flex items-center gap-1.5 font-mono text-[11px] truncate",children:[l.jsx(mw,{className:"h-3 w-3 text-cyan-400 shrink-0"}),m.name]}),l.jsxs("span",{className:"flex items-center gap-1 font-mono text-[10px] text-muted-foreground shrink-0",children:[l.jsx("span",{children:m.current}),l.jsx(Xd,{className:"h-3 w-3"}),l.jsx("span",{className:"text-emerald-400",children:m.candidate})]})]},m.name))})]}),(((f=a==null?void 0:a.held_back)==null?void 0:f.length)??0)>0&&l.jsxs("div",{className:"space-y-1.5 rounded-lg border border-border/40 bg-background/20 p-3",children:[l.jsxs("div",{className:"flex items-center gap-1.5 text-[11px] font-semibold text-muted-foreground",children:[l.jsx(PN,{className:"h-3.5 w-3.5"})," Vom Hersteller zurückgestellt — kein Handeln nötig"]}),l.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."}),l.jsx("div",{className:"space-y-1",children:a.held_back.map(m=>l.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:[l.jsxs("span",{className:"flex items-center gap-1.5 font-mono text-[11px] truncate",children:[l.jsx(mw,{className:"h-3 w-3 text-muted-foreground shrink-0"}),m.name]}),l.jsx("span",{className:"text-[9px] text-muted-foreground shrink-0",children:m.reason==="phasing"?"Phasen-Rollout":"vorerst zurückgehalten"})]},m.name))})]})]}):e.kind==="engine"||e.kind==="swap"?l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"flex items-center gap-2 font-mono text-[11px]",children:[l.jsxs("span",{className:"rounded-md border border-border/40 bg-background/30 px-2 py-1",children:["Build ",(a==null?void 0:a.installed_build)??"?"]}),l.jsx(Xd,{className:"h-3.5 w-3.5 text-muted-foreground"}),l.jsxs("span",{className:"rounded-md border border-emerald-500/30 bg-emerald-500/5 px-2 py-1 text-emerald-400",children:["Build ",(a==null?void 0:a.latest_build)??"?"]})]}),((a==null?void 0:a.name)||(a==null?void 0:a.latest_tag))&&l.jsxs("div",{className:"text-muted-foreground",children:["Release: ",l.jsx("span",{className:"text-foreground",children:a==null?void 0:a.name}),a!=null&&a.latest_tag?` (${a.latest_tag})`:""]}),(a==null?void 0:a.url)&&l.jsxs("a",{href:a.url,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-1 text-primary hover:underline",children:["Original-Release-Notes auf GitHub ",l.jsx(Ms,{className:"h-3 w-3"})]}),(a==null?void 0:a.body)&&l.jsxs("details",{className:"group",children:[l.jsx("summary",{className:"cursor-pointer text-[10px] text-muted-foreground hover:text-foreground",children:"Original-Notizen (englisch) anzeigen"}),l.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:a.body})]})]}):(((h=a==null?void 0:a.commits)==null?void 0:h.length)??0)===0?l.jsx("div",{className:"text-muted-foreground",children:"Keine neuen Commits — Hermes-Agent ist bereits aktuell."}):l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"text-muted-foreground",children:[a.behind," neue Commit(s) auf ",l.jsxs("span",{className:"font-mono text-foreground",children:["origin/",a.branch]}),":"]}),l.jsx("div",{className:"space-y-1",children:a.commits.map(m=>l.jsxs("div",{className:"flex items-start gap-2 rounded-md border border-border/40 bg-background/30 px-2.5 py-1.5",children:[l.jsx(c4,{className:"h-3.5 w-3.5 text-primary shrink-0 mt-0.5"}),l.jsxs("div",{className:"min-w-0",children:[l.jsx("div",{className:"text-[11px] truncate",children:m.subject}),l.jsxs("div",{className:"font-mono text-[9px] text-muted-foreground",children:[m.hash," · ",m.when]})]})]},m.hash))})]}),e.kind!=="os"&&!c&&l.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-border/40 bg-background/20 p-2.5",children:[l.jsx(ON,{className:"h-3.5 w-3.5 text-emerald-400 shrink-0 mt-0.5"}),l.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",e.kind==="hermes"?" und startet den Gateway neu":"","."]})]})]})}),l.jsxs("div",{className:"flex gap-3 border-t border-border/40 p-4 shrink-0",children:[l.jsx("button",{onClick:r,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"}),l.jsx("button",{onClick:n,disabled:e.loading||c||!!t,title:t?`Update läuft bereits: ${t.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:t?"Update läuft…":"Jetzt aktualisieren"})]})]})]})}function YO({open:e,onClose:t,defaultTab:r="maintenance"}){var qe;const[n,a]=y.useState(null),[o,u]=y.useState([]),[c,f]=y.useState("llama-swap"),[h,m]=y.useState(""),[g,v]=y.useState(!1),[b,j]=y.useState(null),[k,S]=y.useState({}),[N,E]=y.useState("maintenance"),[A,P]=y.useState(!1),[_,O]=y.useState(""),[D,B]=y.useState(!1),[F,z]=y.useState(null),[Y,U]=y.useState([]),[he,ue]=y.useState(!1),[ge,ie]=y.useState(null),[se,X]=y.useState(null);function te(G,Ie,Xt){X({type:"alert",title:G,message:Ie,onConfirm:()=>{X(null),Xt&&Xt()}})}function J(G,Ie,Xt){X({type:"confirm",title:G,message:Ie,onConfirm:()=>{X(null),Xt()},onCancel:()=>X(null)})}function I(G){return G?new Date(G*1e3).toLocaleString("de-DE",{day:"2-digit",month:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):"Nie"}y.useEffect(()=>{e&&r&&E(r)},[e,r]);function M(){je("/api/maintenance/updates").then(a).catch(G=>console.error("Error loading updates",G))}function H(){je("/api/jobs").then(G=>u(G.jobs||[])).catch(G=>console.error("Error loading jobs",G))}function ne(){je("/api/system/services").then(z).catch(()=>{})}function Z(){je("/api/system/backups").then(G=>U(G.backups||[])).catch(()=>{})}function me(G){v(!0),j(null),je(`/api/maintenance/logs?service=${G}&lines=150`).then(Ie=>{Ie.ok?m(Ie.text):(m(`Fehler beim Laden der Logs: ${Ie.err||"Unbekannter Fehler"}`),(Ie.status==="incorrect_password"||Ie.status==="password_required")&&j(Ie.status))}).catch(Ie=>m(`Fehler: ${Ie.message}`)).finally(()=>v(!1))}y.useEffect(()=>{if(!e)return;M(),H(),ne(),Z();const G=setInterval(()=>{H(),M(),ne()},3e3);return()=>clearInterval(G)},[e]),y.useEffect(()=>{!e||N!=="logs"||me(c)},[e,N,c]);function pe(G){return(G==null?void 0:G.status)==="busy"?(te("Update läuft bereits",`Es läuft gerade „${G.running}". Bitte warte, bis es fertig ist.`),H(),!0):!1}async function Oe(){try{const G=await je("/api/maintenance/os-update",{method:"POST"});if(pe(G))return;H(),E("maintenance")}catch(G){te("Fehler",`Fehler beim Starten des OS-Updates: ${G.message}`)}}async function re(){try{const G=await je("/api/maintenance/engine-update",{method:"POST"});if(pe(G))return;H(),E("maintenance")}catch(G){te("Fehler",`Fehler beim Engine-Update: ${G.message}`)}}async function we(){try{const G=await je("/api/maintenance/swap-update",{method:"POST"});if(pe(G))return;H(),E("maintenance")}catch(G){te("Fehler",`Fehler beim Router-Update: ${G.message}`)}}async function _e(){ue(!0);try{const G=await je("/api/maintenance/hermes-update",{method:"POST"});if(pe(G))return;H()}catch(G){te("Fehler",`Hermes-Update fehlgeschlagen: ${G.message}`)}finally{ue(!1)}}async function ae(G){ie({kind:G,loading:!0,data:null});try{const Ie=await je(`/api/maintenance/update-details?kind=${G}`);ie({kind:G,loading:!1,data:Ie})}catch(Ie){ie({kind:G,loading:!1,data:{kind:G,error:Ie.message}})}}function et(){const G=ge==null?void 0:ge.kind;ie(null),G==="os"?Oe():G==="engine"?re():G==="swap"?we():G==="hermes"&&_e()}async function Be(){P(!0);try{await je("/api/maintenance/check-updates",{method:"POST"}),H(),E("maintenance")}catch(G){te("Fehler",`Fehler bei der Update-Suche: ${G.message}`)}finally{P(!1)}}async function Pe(G,Ie){try{await je("/api/models/install",{method:"POST",body:JSON.stringify({repo:G,role:Ie})}),te("Gestartet",`Modell-Upgrade für '${Ie}' (${G}) gestartet.`),H(),E("maintenance")}catch(Xt){te("Fehler",`Fehler beim Starten des Modell-Upgrades: ${Xt.message}`)}}async function vt(){J("Reboot bestätigen","Bist du sicher, dass du das gesamte Host-System neu starten willst?",async()=>{try{await je("/api/maintenance/reboot",{method:"POST"}),te("Reboot","Reboot ausgelöst. System startet neu...",()=>{t()})}catch(G){te("Fehler",`Fehler beim Reboot: ${G.message}`)}})}async function Yt(){B(!0),O("Snapshot wird erzeugt...");try{const G=await je("/api/system/backup",{method:"POST"});O(G.ok?`Snapshot erzeugt: ${G.snapshot} (${G.files.length} Komponenten)`:"Backup fehlgeschlagen."),Z()}catch(G){O(`Fehler: ${G.message}`)}finally{B(!1)}}async function K(G){S(Ie=>({...Ie,[G]:!0}));try{const Ie=await je("/api/maintenance/restart",{method:"POST",body:JSON.stringify({service:G})});Ie.ok?te("Dienst neu gestartet",`Dienst ${G} wurde erfolgreich neu gestartet.`,()=>{N==="logs"&&c===G&&me(G)}):te("Fehler",`Fehler beim Neustart: ${Ie.err||"Unbekannter Fehler"}`)}catch(Ie){te("Fehler",`Fehler beim Neustart: ${Ie.message}`)}finally{S(Ie=>({...Ie,[G]:!1}))}}async function Ae(G){try{await je(`/api/jobs/${G}/cancel`,{method:"POST"}),H()}catch(Ie){te("Fehler",`Fehler beim Abbrechen: ${Ie.message}`)}}const Se=o.find(G=>(G.state==="running"||G.state==="queued")&&G.group==="maintenance");return l.jsxs(l.Fragment,{children:[l.jsx("div",{className:ee("fixed inset-0 bg-black/60 backdrop-blur-sm z-50 transition-opacity duration-300",e?"opacity-100 pointer-events-auto":"opacity-0 pointer-events-none"),onClick:t}),l.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",e?"translate-x-0":"translate-x-full"),children:[l.jsxs("div",{className:"flex h-16 shrink-0 items-center justify-between border-b border-border/40 px-6",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx($n,{className:"h-4.5 w-4.5 text-primary"}),l.jsx("h2",{className:"text-sm font-semibold tracking-wide uppercase font-space",children:"OS-Zentrale & Pflege"})]}),l.jsx("button",{onClick:t,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:l.jsx(zn,{className:"h-4 w-4"})})]}),l.jsxs("div",{className:"flex border-b border-border/40 px-6",children:[l.jsx("button",{onClick:()=>E("maintenance"),className:ee("flex-1 py-3 text-xs font-semibold uppercase tracking-wider border-b-2 text-center transition-all",N==="maintenance"?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground"),children:"System-Wartung"}),l.jsx("button",{onClick:()=>E("logs"),className:ee("flex-1 py-3 text-xs font-semibold uppercase tracking-wider border-b-2 text-center transition-all",N==="logs"?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground"),children:"System-Logs"}),l.jsx("button",{onClick:()=>E("settings"),className:ee("flex-1 py-3 text-xs font-semibold uppercase tracking-wider border-b-2 text-center transition-all",N==="settings"?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground"),children:"Einstellungen"})]}),l.jsxs("div",{className:"flex-1 overflow-y-auto p-6 space-y-6",children:[N==="maintenance"&&l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"space-y-2.5",children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Updates"}),l.jsxs("button",{onClick:Be,disabled:A||!!Se,className:"flex items-center gap-1 text-[10px] font-semibold text-primary hover:text-primary/80 transition-colors disabled:opacity-50",children:[l.jsx(ro,{className:ee("h-3 w-3",A&&"animate-spin")})," Nach Updates suchen"]})]}),(n==null?void 0:n.last_check)&&l.jsxs("div",{className:"text-[9px] text-muted-foreground -mt-1",children:["Zuletzt gesucht: ",I(n.last_check)]}),Se&&l.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:[l.jsx(ro,{className:"h-3.5 w-3.5 shrink-0 animate-spin"}),l.jsxs("span",{children:["Update läuft: ",l.jsx("span",{className:"font-semibold",children:Se.label})," — bitte warten. Weitere Updates sind solange gesperrt."]})]}),l.jsxs("div",{className:"space-y-1.5",children:[l.jsx(iu,{icon:Ks,iconClass:"text-cyan-400",name:"OS-Pakete (apt)",available:!!(n!=null&&n.os),status:n!=null&&n.os?`${n.os} verfügbar`:"aktuell",actionLabel:"Anzeigen",onAction:()=>ae("os")}),l.jsx(iu,{icon:th,iconClass:"text-violet-400",name:"Inferenz-Engine (llama.cpp)",available:!!(n!=null&&n.engine),status:n!=null&&n.engine?"Update verfügbar":"aktuell",actionLabel:"Anzeigen",onAction:()=>ae("engine")}),l.jsx(iu,{icon:_N,iconClass:"text-fuchsia-400",name:"Router (llama-swap)",available:!!(n!=null&&n.swap),status:n!=null&&n.swap?"Update verfügbar":"aktuell",actionLabel:"Anzeigen",onAction:()=>ae("swap")}),(()=>{var Ie;const G=(Ie=n==null?void 0:n.components)==null?void 0:Ie.find(Xt=>Xt.key==="hermes_agent");return l.jsx(iu,{icon:pn,iconClass:"text-amber-400",name:"Hermes-Agent",available:(G==null?void 0:G.update)===!0,busy:he,status:(G==null?void 0:G.update)===!0?`Update: ${G.latest}`:(G==null?void 0:G.reachable)===!1?"offline":"aktuell",actionLabel:"Anzeigen",onAction:()=>ae("hermes")})})(),(qe=n==null?void 0:n.model_list)==null?void 0:qe.map(G=>l.jsx(iu,{icon:qM,iconClass:"text-emerald-400",name:`Modell · ${G.role}`,available:!0,status:G.title,actionLabel:"Upgrade",onAction:()=>Pe(G.repo,G.role)},G.role))]})]}),l.jsxs("div",{className:"space-y-2.5",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Dienste"}),l.jsx("div",{className:"space-y-1.5",children:J2.map(G=>{var Ie;return l.jsx(BX,{label:G.label,system:G.type==="system",ok:(Ie=F==null?void 0:F.services.find(Xt=>Xt.name.toLowerCase().includes(G.reach)))==null?void 0:Ie.ok,busy:k[G.id],onRestart:()=>K(G.id),onLogs:()=>{f(G.id),E("logs")}},G.id)})})]}),l.jsxs("div",{className:"space-y-2.5",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Backup"}),l.jsxs("div",{className:"rounded-lg border border-border/50 bg-background/20 px-3 py-2.5 flex items-center gap-3",children:[l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("div",{className:"text-xs text-foreground truncate",children:Y[0]?`Letztes: ${Y[0].snapshot}`:"Noch kein Backup"}),l.jsxs("div",{className:"text-[10px] text-muted-foreground",children:[Y.length," Snapshots · Restore per CLI (restore.sh)"]})]}),l.jsxs("button",{onClick:Yt,disabled:D,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:[l.jsx(XM,{className:ee("h-3.5 w-3.5",D&&"animate-pulse")})," Snapshot"]})]}),_&&l.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:_})]}),l.jsxs("div",{className:"space-y-2.5",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-red-400/80",children:"Gefahrenzone"}),l.jsxs("button",{onClick:vt,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:[l.jsx(A4,{className:"h-4.5 w-4.5"}),l.jsxs("div",{children:[l.jsx("div",{children:"Host-System neu starten"}),l.jsx("div",{className:"text-[10px] text-red-400/80 font-normal",children:"Startet die ganze Box neu"})]})]})]}),l.jsxs("div",{className:"space-y-3",children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsx("h3",{className:"text-xs font-bold uppercase tracking-wider text-muted-foreground",children:"Hintergrund-Aufgaben"}),l.jsxs("span",{className:"text-[10px] font-mono bg-primary/10 text-primary px-1.5 py-0.5 rounded-full",children:[o.filter(G=>G.state==="running"||G.state==="queued").length," Aktiv"]})]}),l.jsx("div",{className:"space-y-3",children:o.length===0?l.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."}):o.map(G=>{const Ie=G.state==="running"||G.state==="queued";return l.jsxs("div",{className:ee("p-3 rounded-xl border transition-all duration-300",Ie?"border-primary/40 bg-primary/5 shadow-md shadow-primary/5":"border-border/40 bg-background/20 opacity-80"),children:[l.jsxs("div",{className:"flex items-start justify-between gap-3",children:[l.jsxs("div",{className:"space-y-1",children:[l.jsxs("div",{className:"text-xs font-semibold flex items-center gap-1.5",children:[Ie&&l.jsxs("span",{className:"flex h-2 w-2 relative",children:[l.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-primary opacity-75"}),l.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-primary"})]}),G.label]}),l.jsxs("div",{className:"text-[10px] font-mono text-muted-foreground uppercase flex items-center gap-2",children:[l.jsxs("span",{children:["ID: ",G.id]}),l.jsx("span",{children:"•"}),l.jsx("span",{className:ee(G.state==="done"&&"text-emerald-400",G.state==="failed"&&"text-red-400",G.state==="running"&&"text-primary",G.state==="queued"&&"text-amber-400",G.state==="canceled"&&"text-muted-foreground"),children:G.state})]})]}),Ie&&l.jsx("button",{onClick:()=>Ae(G.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"})]}),G.state==="running"&&l.jsxs("div",{className:"mt-3 space-y-1",children:[l.jsx("div",{className:"w-full h-1.5 bg-muted rounded-full overflow-hidden",children:l.jsx("div",{className:"h-full bg-primary transition-all duration-500",style:{width:`${G.progress??0}%`}})}),l.jsxs("div",{className:"flex justify-between items-center text-[9px] font-mono text-muted-foreground",children:[l.jsxs("span",{children:[G.progress??0,"%"]}),G.done_bytes!=null&&G.total_bytes!=null&&l.jsxs("span",{children:[Rg(G.done_bytes)," / ",Rg(G.total_bytes),G.rate_bps!=null&&` (${Rg(G.rate_bps)}/s)`]}),G.eta_s!=null&&l.jsxs("span",{children:["ETA: ",G.eta_s,"s"]})]})]})]},G.id)})})]})]}),N==="logs"&&l.jsxs("div",{className:"flex flex-col h-full space-y-4",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("select",{value:c,onChange:G=>f(G.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:J2.map(G=>l.jsxs("option",{value:G.id,children:[G.label," (",G.type==="system"?"systemd-root":"user",")"]},G.id))}),l.jsxs("button",{onClick:()=>K(c),disabled:k[c],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:[l.jsx(ro,{className:ee("h-3.5 w-3.5",k[c]&&"animate-spin")}),"Restart"]})]}),l.jsx(GX,{service:c,text:h,loading:g,logStatus:b,onRefresh:()=>me(c),onOpenSettings:()=>E("settings")})]}),N==="settings"&&l.jsx(VX,{open:e,showAlert:te})]})]}),ge&&l.jsx(qX,{detail:ge,maintenanceJob:Se,onClose:()=>ie(null),onApply:et}),se&&l.jsx(BO,{type:se.type,title:se.title,message:se.message,onConfirm:se.onConfirm,onCancel:se.onCancel})]})}function QX(){const{data:e}=sh(3e4),{data:t}=yi(),r=((e==null?void 0:e.os)||0)+((e==null?void 0:e.engine)||0)+((e==null?void 0:e.swap)||0)+((e==null?void 0:e.models)||0),n=()=>window.dispatchEvent(new CustomEvent("open-system-drawer",{detail:{tab:"maintenance"}})),a=(t==null?void 0:t.models)??[],o=(t==null?void 0:t.running)??[],u=a.find(m=>m.role==="hermes"),c=a.find(m=>m.role==="coder-lite")||a.find(m=>m.role==="coder"),f=m=>m?o.includes(m):!1,h=m=>{var g;return((g=m==null?void 0:m.split("/").pop())==null?void 0:g.replace(/\.gguf$/i,""))||"—"};return l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Basisstation"}),l.jsx("p",{className:"text-sm text-muted-foreground",children:"Geht's der Box gut, gibt's Updates, was läuft gerade."})]}),l.jsx(KO,{frame:"box"}),l.jsxs("button",{onClick:n,className:ee("w-full flex items-center gap-3 rounded-2xl border p-4 text-left transition-all cursor-pointer",r>0?"border-amber-500/30 bg-amber-500/5 hover:bg-amber-500/10":"border-border/60 bg-card/45 hover:border-primary/40"),children:[r>0?l.jsx(JM,{className:"h-6 w-6 shrink-0 text-amber-400"}):l.jsx(or,{className:"h-6 w-6 shrink-0 text-emerald-400"}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("div",{className:ee("text-sm font-semibold",r>0?"text-amber-400":"text-foreground"),children:r>0?`${r} Update${r===1?"":"s"} verfügbar`:"Alles aktuell"}),l.jsx("div",{className:"text-xs text-muted-foreground",children:r>0?"Antippen, um zu sehen, was genau aktualisiert wird.":"Keine ausstehenden Updates."})]}),r>0&&l.jsxs("span",{className:"shrink-0 flex items-center gap-1 text-xs font-semibold text-amber-400",children:["Ansehen ",l.jsx(Jf,{className:"h-4 w-4"})]})]}),l.jsxs("div",{children:[l.jsx("div",{className:"text-xs text-muted-foreground mb-2",children:"Was gerade läuft"}),l.jsx("div",{className:"rounded-2xl border border-border/60 overflow-hidden",children:[{icon:$n,label:"Lucys Hirn",model:u==null?void 0:u.name,warm:f(u==null?void 0:u.name)},{icon:Os,label:"Coder (Vibe-Coding)",model:c==null?void 0:c.name,warm:f(c==null?void 0:c.name)}].map(m=>l.jsxs("div",{className:"flex items-center gap-3 px-4 py-3 border-b border-border/40 last:border-0",children:[l.jsx("span",{className:ee("h-2 w-2 shrink-0 rounded-full",m.warm?"bg-emerald-500 animate-pulse":"bg-muted-foreground/40")}),l.jsx(m.icon,{className:"h-4 w-4 text-muted-foreground shrink-0"}),l.jsx("span",{className:"text-sm text-foreground w-40 shrink-0",children:m.label}),l.jsx("span",{className:"text-xs text-muted-foreground flex-1 truncate font-mono",children:h(m.model)}),l.jsx("span",{className:ee("text-xs shrink-0",m.warm?"text-emerald-400":"text-muted-foreground"),children:m.model?m.warm?"warm":"bereit":"nicht gesetzt"})]},m.label))})]}),l.jsxs("div",{className:"grid gap-6 lg:grid-cols-2",children:[l.jsx(FO,{}),l.jsx(UO,{})]})]})}function Lg({icon:e,title:t,sub:r,onClick:n}){return l.jsxs("button",{onClick:n,className:"w-full flex items-center gap-4 rounded-2xl border border-border/60 bg-card/45 backdrop-blur-md p-5 text-left transition-all hover:border-primary/40 cursor-pointer",children:[l.jsx(e,{className:"h-6 w-6 text-muted-foreground shrink-0"}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("div",{className:"text-sm text-foreground",children:t}),l.jsx("div",{className:"text-xs text-muted-foreground",children:r})]}),l.jsx(Jf,{className:"h-5 w-5 text-muted-foreground shrink-0"})]})}function YX(){const[e,t]=y.useState(null);return e?l.jsxs("div",{className:"space-y-4",children:[l.jsxs("button",{onClick:()=>t(null),className:"flex items-center gap-1.5 text-xs font-semibold text-muted-foreground hover:text-foreground transition-colors cursor-pointer",children:[l.jsx(SN,{className:"h-4 w-4"})," Maschinenraum"]}),e==="modelle"?l.jsx(GO,{}):l.jsx(QO,{})]}):l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between gap-3",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-space font-bold tracking-tight bg-gradient-to-r from-foreground via-foreground to-primary bg-clip-text text-transparent",children:"Maschinenraum"}),l.jsx("p",{className:"text-sm text-muted-foreground",children:"Nur nötig, wenn du wirklich was ändern willst."})]}),l.jsx(kE,{})]}),l.jsx(Lg,{icon:$n,title:"Modelle",sub:"Hirne, Coder, Immer-bereit-Set, Bibliothek",onClick:()=>t("modelle")}),l.jsx(Lg,{icon:ON,title:"Wartung und Logs",sub:"Updates, Backup, Dienste, Logs, Zugangsdaten",onClick:()=>window.dispatchEvent(new CustomEvent("open-system-drawer",{detail:{tab:"maintenance"}}))}),l.jsx(Lg,{icon:pn,title:"Hermes und Verdrahtung",sub:"Agent, Gehirn-Modell, PC-Verbindung",onClick:()=>t("hermes")})]})}const XX=[{id:"start",label:"Start",icon:Zf},{id:"vibe",label:"Vibe-Coding",icon:Os},{id:"konstitution",label:"Konstitution",icon:VM},{id:"maschinenraum",label:"Maschinenraum",icon:Uu}];function ZX(){const[e,t]=y.useState("start"),[r,n]=y.useState(!1),[a,o]=y.useState("maintenance"),{data:u}=wy();y.useEffect(()=>{const f=h=>{var m;o(((m=h.detail)==null?void 0:m.tab)||"maintenance"),n(!0)};return window.addEventListener("open-system-drawer",f),()=>window.removeEventListener("open-system-drawer",f)},[]);const c=u&&u.engine_reachable&&(u.brain?u.brain.ready:!0);return l.jsxs("div",{className:"flex h-full relative",children:[l.jsx("div",{className:"fixed inset-0 -z-50 pointer-events-none overflow-hidden bg-[hsl(224,30%,6%)]",children:l.jsx("div",{className:"absolute inset-0 opacity-30 animate-aurora bg-gradient-to-tr from-teal-500/15 via-indigo-500/10 to-purple-500/15 blur-[130px]"})}),l.jsx(YO,{open:r,onClose:()=>n(!1),defaultTab:a}),l.jsxs("aside",{className:"flex w-56 shrink-0 flex-col border-r border-border/40 bg-card/45 backdrop-blur-md",children:[l.jsxs("div",{className:"flex items-center gap-2 px-5 py-4 border-b border-border/40",children:[l.jsx("div",{className:"h-7 w-7 rounded-lg bg-primary shadow-md shadow-primary/20"}),l.jsxs("div",{className:"leading-tight",children:[l.jsx("div",{className:"text-sm font-semibold tracking-wide font-space",children:"Mission Control"}),l.jsx("div",{className:"text-[10px] text-muted-foreground",children:"3 · Prototyp"})]})]}),l.jsx("nav",{className:"flex-1 space-y-1 px-3 py-4",children:XX.map(f=>l.jsxs("button",{onClick:()=>t(f.id),className:ee("flex w-full items-center gap-3 rounded-md px-3 py-2 text-sm transition-all cursor-pointer",e===f.id?"bg-primary/15 text-primary":"text-muted-foreground hover:bg-accent hover:text-accent-foreground"),children:[l.jsx(f.icon,{className:"h-4.5 w-4.5 shrink-0"})," ",f.label]},f.id))}),l.jsxs("div",{className:"px-3 py-3 border-t border-border/40 space-y-2",children:[l.jsxs("div",{className:"flex items-center gap-2 px-2 text-xs text-muted-foreground",children:[l.jsx("span",{className:ee("h-2 w-2 rounded-full",c?"bg-emerald-500 animate-pulse":"bg-amber-500")}),c?"Box läuft":"prüfen"]}),l.jsxs("a",{href:"#dashboard",className:"flex items-center gap-1.5 rounded-md px-2 py-1.5 text-[11px] text-muted-foreground hover:text-foreground transition-colors",children:[l.jsx(SN,{className:"h-3.5 w-3.5"})," zurück zu MC2"]})]})]}),l.jsxs("main",{className:"flex-1 min-w-0 overflow-y-auto p-6 scrollbar-thin",children:[e==="start"&&l.jsx(QX,{}),e==="vibe"&&l.jsx(VO,{}),e==="konstitution"&&l.jsx(qO,{}),e==="maschinenraum"&&l.jsx(YX,{})]})]})}function JX(){var j,k,S,N,E;FD();const[e,t]=y.useState(()=>{const A=window.location.hash.slice(1);return ou.some(P=>P.id===A)?A:"dashboard"}),r=y.useCallback(A=>{window.location.hash.slice(1)===A?t(A):window.location.hash=A},[]),[n,a]=y.useState(()=>localStorage.getItem("mc_sidebar_collapsed")==="true"),[o,u]=y.useState(!1),[c,f]=y.useState("maintenance"),[h,m]=y.useState(()=>window.location.hash==="#mc3"),{data:g}=wy(),{data:v}=xo(2e4);y.useEffect(()=>{document.documentElement.classList.add("dark")},[]),y.useEffect(()=>{const A=P=>{var O;f(((O=P.detail)==null?void 0:O.tab)||"maintenance"),u(!0)};return window.addEventListener("open-system-drawer",A),()=>window.removeEventListener("open-system-drawer",A)},[]),y.useEffect(()=>{const A=P=>{var O;const _=(O=P.detail)==null?void 0:O.view;_&&r(_)};return window.addEventListener("mc-navigate",A),()=>window.removeEventListener("mc-navigate",A)},[r]),y.useEffect(()=>{const A=()=>{m(window.location.hash==="#mc3");const P=window.location.hash.slice(1);ou.some(_=>_.id===P)&&t(P)};return window.addEventListener("hashchange",A),()=>window.removeEventListener("hashchange",A)},[]);const b=ou.find(A=>A.id===e);return h?l.jsx(ZX,{}):l.jsxs("div",{className:"flex h-full relative",children:[l.jsxs("div",{className:"fixed inset-0 -z-50 pointer-events-none overflow-hidden bg-[hsl(224,30%,6%)]",children:[l.jsx("div",{className:"absolute inset-0 opacity-35 animate-aurora bg-gradient-to-tr from-teal-500/20 via-indigo-500/15 to-purple-500/20 blur-[130px]"}),l.jsx("div",{className:"absolute top-[-10%] left-[-10%] h-[50%] w-[50%] rounded-full bg-teal-500/15 blur-[160px]"}),l.jsx("div",{className:"absolute bottom-[-10%] right-[-10%] h-[50%] w-[50%] rounded-full bg-purple-500/15 blur-[160px]"}),l.jsx("div",{className:"absolute top-[30%] right-[20%] h-[40%] w-[40%] rounded-full bg-indigo-500/10 blur-[140px]"})]}),l.jsx(VT,{onNavigate:r}),l.jsx(YO,{open:o,onClose:()=>u(!1),defaultTab:c}),l.jsxs("aside",{className:ee("flex shrink-0 flex-col border-r border-border/40 bg-card/45 backdrop-blur-md transition-all duration-300 ease-in-out",n?"w-16":"w-60"),children:[l.jsxs("div",{className:ee("flex items-center py-4 border-b border-border/40 shrink-0",n?"flex-col gap-3 px-2":"justify-between px-5"),children:[l.jsxs("div",{className:"flex items-center gap-2 overflow-hidden",children:[l.jsx("div",{className:"h-7 w-7 rounded-lg bg-primary shadow-md shadow-primary/20 shrink-0"}),!n&&l.jsxs("div",{className:"leading-tight",children:[l.jsx("div",{className:"text-sm font-semibold tracking-wide font-space",children:"Mission Control"}),l.jsx("div",{className:"text-xs text-muted-foreground",children:"2.0"})]})]}),l.jsx("button",{onClick:()=>{a(A=>{const P=!A;return localStorage.setItem("mc_sidebar_collapsed",P.toString()),P})},className:"p-1 rounded-md hover:bg-accent text-muted-foreground transition-colors cursor-pointer","aria-label":n?"Seitenleiste ausklappen":"Seitenleiste einklappen",title:n?"Maximieren":"Minimieren",children:n?l.jsx(Jf,{className:"h-4 w-4","aria-hidden":"true"}):l.jsx(ZM,{className:"h-4 w-4","aria-hidden":"true"})})]}),l.jsx("nav",{className:"flex-1 space-y-1 px-3 py-4 overflow-y-auto",children:ou.map(A=>l.jsxs("a",{href:`#${A.id}`,"aria-current":e===A.id?"page":void 0,className:ee("flex w-full items-center rounded-md text-sm transition-all cursor-pointer",n?"justify-center p-2.5":"gap-3 px-3 py-2",e===A.id?"bg-primary/15 text-primary shadow-sm shadow-primary/5":"text-muted-foreground hover:bg-accent hover:text-accent-foreground"),title:n?A.label:void 0,"aria-label":n?A.label:void 0,children:[l.jsx(A.icon,{className:"h-4.5 w-4.5 shrink-0","aria-hidden":"true"}),!n&&l.jsx("span",{className:"truncate",children:A.label})]},A.id))}),l.jsx("div",{className:ee("py-3 text-xs text-muted-foreground border-t border-border/40 shrink-0",n?"px-2 text-center":"px-5"),children:n?l.jsx("div",{className:"flex justify-center",children:l.jsx("span",{className:ee("h-2.5 w-2.5 rounded-full ring-2 ring-black/40",g?g.engine_reachable?g.brain&&!g.brain.ready?"bg-amber-500 animate-pulse":"bg-emerald-500 animate-pulse":"bg-amber-500":"bg-red-500"),title:g?g.engine_reachable?g.brain&&!g.brain.ready?`Hirn offline (${g.brain.model??"fast"})`:"Engine + Hirn online":"Engine offline":"Backend offline"})}):l.jsxs("div",{className:"space-y-2 text-left",children:[g?l.jsxs(l.Fragment,{children:[l.jsxs("span",{className:"flex items-center gap-2",children:[l.jsx("span",{className:ee("h-2 w-2 rounded-full animate-pulse",g.engine_reachable?"bg-emerald-500":"bg-amber-500")}),l.jsxs("span",{className:"truncate",children:["Engine ",g.engine_reachable?"online":"offline"]})]}),g.brain&&!g.brain.ready&&l.jsxs("span",{className:"flex items-center gap-2 text-amber-400",title:`Agent-Hirn '${g.brain.model??"fast"}' lädt nicht/abgestürzt`,children:[l.jsx("span",{className:"h-2 w-2 rounded-full bg-amber-500 animate-pulse"}),l.jsxs("span",{className:"truncate",children:["Hirn offline",g.brain.model?` (${g.brain.model})`:""]})]})]}):l.jsxs("span",{className:"flex items-center gap-2",children:[l.jsx("span",{className:"h-2 w-2 rounded-full bg-red-500"})," ",l.jsx("span",{className:"truncate",children:"Backend offline"})]}),(v==null?void 0:v.versions)&&l.jsxs("div",{className:"space-y-1 text-[9px] text-muted-foreground/60 mt-2 pt-2 border-t border-border/30",children:[l.jsxs("div",{className:"truncate",title:v.versions.mc2?`${v.versions.mc2.branch}-${v.versions.mc2.hash}${v.versions.mc2.dirty?"*":""} (${v.versions.mc2.date})`:"nicht gefunden",children:[l.jsx("strong",{children:"MC2:"})," ",v.versions.mc2?`${v.versions.mc2.hash}${v.versions.mc2.dirty?"*":""}`:"—"]}),l.jsxs("div",{className:"truncate",title:((j=v.versions.engine)==null?void 0:j.type)==="git"?`${v.versions.engine.branch}-${v.versions.engine.hash}${v.versions.engine.dirty?"*":""} (${v.versions.engine.date})`:((k=v.versions.engine)==null?void 0:k.version_text)||"unbekannt",children:[l.jsx("strong",{children:"Engine:"})," ",((S=v.versions.engine)==null?void 0:S.type)==="git"?`${v.versions.engine.hash}${v.versions.engine.dirty?"*":""}`:((E=(N=v.versions.engine)==null?void 0:N.version_text)==null?void 0:E.split(" ").pop())||"—"]}),l.jsxs("div",{className:"truncate",title:v.versions.hermes_ui?`${v.versions.hermes_ui.branch}-${v.versions.hermes_ui.hash}${v.versions.hermes_ui.dirty?"*":""} (${v.versions.hermes_ui.date})`:"nicht gefunden",children:[l.jsx("strong",{children:"Hermes UI:"})," ",v.versions.hermes_ui?`${v.versions.hermes_ui.hash}${v.versions.hermes_ui.dirty?"*":""}`:"—"]}),l.jsxs("div",{className:"truncate",title:v.versions.hermes_agent?`${v.versions.hermes_agent.branch}-${v.versions.hermes_agent.hash}${v.versions.hermes_agent.dirty?"*":""} (${v.versions.hermes_agent.date})`:"nicht gefunden",children:[l.jsx("strong",{children:"Hermes Agent:"})," ",v.versions.hermes_agent?`${v.versions.hermes_agent.hash}${v.versions.hermes_agent.dirty?"*":""}`:"—"]})]})]})})]}),l.jsxs("div",{className:"flex min-w-0 flex-1 flex-col",children:[l.jsxs("header",{className:"flex h-14 shrink-0 items-center justify-between border-b border-border/40 px-6 bg-card/20 backdrop-blur-sm",children:[l.jsx("div",{className:"text-xs font-medium text-muted-foreground tracking-wide uppercase font-sans",children:b.hint}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(kE,{}),l.jsx("a",{href:"https://git.tobisniceshomelab.ddnsfree.com/Hitonabi/mission-control-v2/src/branch/main/docs/BEDIENUNG.md",target:"_blank",rel:"noopener",className:"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"}),l.jsxs("button",{onClick:()=>{const A=new KeyboardEvent("keydown",{key:"k",metaKey:!0});document.dispatchEvent(A)},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:[l.jsx(n4,{className:"h-3.5 w-3.5"}),l.jsx("span",{children:"Suchen"}),l.jsx("kbd",{className:"rounded bg-muted px-1.5 py-0.5 font-mono text-[9px]",children:"⌘K"})]})]})]}),l.jsxs("main",{className:"flex-1 overflow-y-auto p-6 scrollbar-thin",children:[e==="dashboard"&&l.jsx(hX,{}),e==="models"&&l.jsx(CX,{}),e==="connect"&&l.jsx(VO,{}),e==="memory"&&l.jsx(qO,{}),e==="agent"&&l.jsx(QO,{}),e==="terminal"&&l.jsx(LX,{}),e==="guide"&&l.jsx(zX,{}),!["dashboard","models","connect","memory","agent","terminal","guide"].includes(e)&&l.jsx(FX,{title:b.label,hint:b.hint})]})]})]})}class eZ extends uy.Component{constructor(){super(...arguments);qo(this,"state",{error:null})}static getDerivedStateFromError(r){return{error:r}}componentDidCatch(r,n){console.error("Unbehandelter UI-Fehler:",r,n.componentStack)}render(){return this.state.error?l.jsx("div",{className:"min-h-screen flex items-center justify-center bg-neutral-950 text-neutral-200 p-8",children:l.jsxs("div",{className:"max-w-lg space-y-4 text-center",children:[l.jsx("div",{className:"text-2xl",children:"Da ist etwas schiefgelaufen."}),l.jsx("div",{className:"text-sm text-neutral-400 break-all",children:this.state.error.message}),l.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 tZ=new OM({defaultOptions:{queries:{retry:1,refetchOnWindowFocus:!1,staleTime:5e3}}});iM.createRoot(document.getElementById("root")).render(l.jsx(uy.StrictMode,{children:l.jsx(eZ,{children:l.jsx(_M,{client:tZ,children:l.jsx(JX,{})})})}));export{ro as R,us as S,tv as T,M4 as a,ly as g,l as j,y as r};
|