(function(){const O=document.createElement("link").relList;if(O&&O.supports&&O.supports("modulepreload"))return;for(const E of document.querySelectorAll('link[rel="modulepreload"]'))d(E);new MutationObserver(E=>{for(const H of E)if(H.type==="childList")for(const J of H.addedNodes)J.tagName==="LINK"&&J.rel==="modulepreload"&&d(J)}).observe(document,{childList:!0,subtree:!0});function T(E){const H={};return E.integrity&&(H.integrity=E.integrity),E.referrerPolicy&&(H.referrerPolicy=E.referrerPolicy),E.crossOrigin==="use-credentials"?H.credentials="include":E.crossOrigin==="anonymous"?H.credentials="omit":H.credentials="same-origin",H}function d(E){if(E.ep)return;E.ep=!0;const H=T(E);fetch(E.href,H)}})();function g0(x){return x&&x.__esModule&&Object.prototype.hasOwnProperty.call(x,"default")?x.default:x}var Ts={exports:{}},nn={};/** * @license React * react-jsx-runtime.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 u0;function pv(){if(u0)return nn;u0=1;var x=Symbol.for("react.transitional.element"),O=Symbol.for("react.fragment");function T(d,E,H){var J=null;if(H!==void 0&&(J=""+H),E.key!==void 0&&(J=""+E.key),"key"in E){H={};for(var K in E)K!=="key"&&(H[K]=E[K])}else H=E;return E=H.ref,{$$typeof:x,type:d,key:J,ref:E!==void 0?E:null,props:H}}return nn.Fragment=O,nn.jsx=T,nn.jsxs=T,nn}var n0;function Nv(){return n0||(n0=1,Ts.exports=pv()),Ts.exports}var f=Nv(),_s={exports:{}},V={};/** * @license React * react.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 c0;function Tv(){if(c0)return V;c0=1;var x=Symbol.for("react.transitional.element"),O=Symbol.for("react.portal"),T=Symbol.for("react.fragment"),d=Symbol.for("react.strict_mode"),E=Symbol.for("react.profiler"),H=Symbol.for("react.consumer"),J=Symbol.for("react.context"),K=Symbol.for("react.forward_ref"),Q=Symbol.for("react.suspense"),W=Symbol.for("react.memo"),A=Symbol.for("react.lazy"),S=Symbol.for("react.activity"),D=Symbol.for("react.view_transition"),w=Symbol.iterator;function U(r){return r===null||typeof r!="object"?null:(r=w&&r[w]||r["@@iterator"],typeof r=="function"?r:null)}var vl={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},P=Object.assign,jl={};function Bl(r,_,B){this.props=r,this.context=_,this.refs=jl,this.updater=B||vl}Bl.prototype.isReactComponent={},Bl.prototype.setState=function(r,_){if(typeof r!="object"&&typeof r!="function"&&r!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,r,_,"setState")},Bl.prototype.forceUpdate=function(r){this.updater.enqueueForceUpdate(this,r,"forceUpdate")};function I(){}I.prototype=Bl.prototype;function il(r,_,B){this.props=r,this.context=_,this.refs=jl,this.updater=B||vl}var Il=il.prototype=new I;Il.constructor=il,P(Il,Bl.prototype),Il.isPureReactComponent=!0;var Pl=Array.isArray;function ll(){}var ol={H:null,A:null,T:null,S:null},Qt=Object.prototype.hasOwnProperty;function Tt(r,_,B){var q=B.ref;return{$$typeof:x,type:r,key:_,ref:q!==void 0?q:null,props:B}}function _t(r,_){return Tt(r.type,_,r.props)}function rt(r){return typeof r=="object"&&r!==null&&r.$$typeof===x}function be(r){var _={"=":"=0",":":"=2"};return"$"+r.replace(/[=:]/g,function(B){return _[B]})}var $e=/\/+/g;function ql(r,_){return typeof r=="object"&&r!==null&&r.key!=null?be(""+r.key):_.toString(36)}function j(r){switch(r.status){case"fulfilled":return r.value;case"rejected":throw r.reason;default:switch(typeof r.status=="string"?r.then(ll,ll):(r.status="pending",r.then(function(_){r.status==="pending"&&(r.status="fulfilled",r.value=_)},function(_){r.status==="pending"&&(r.status="rejected",r.reason=_)})),r.status){case"fulfilled":return r.value;case"rejected":throw r.reason}}throw r}function X(r,_,B,q,cl){var fl=typeof r;(fl==="undefined"||fl==="boolean")&&(r=null);var rl=!1;if(r===null)rl=!0;else switch(fl){case"bigint":case"string":case"number":rl=!0;break;case"object":switch(r.$$typeof){case x:case O:rl=!0;break;case A:return rl=r._init,X(rl(r._payload),_,B,q,cl)}}if(rl)return cl=cl(r),rl=q===""?"."+ql(r,0):q,Pl(cl)?(B="",rl!=null&&(B=rl.replace($e,"$&/")+"/"),X(cl,_,B,"",function(ee){return ee})):cl!=null&&(rt(cl)&&(cl=_t(cl,B+(cl.key==null||r&&r.key===cl.key?"":(""+cl.key).replace($e,"$&/")+"/")+rl)),_.push(cl)),1;rl=0;var R=q===""?".":q+":";if(Pl(r))for(var Z=0;Z>>1,ml=j[pl];if(0>>1;plE(We,L))rE(_,We)?(j[pl]=_,j[r]=L,pl=r):(j[pl]=We,j[te]=L,pl=te);else if(rE(_,L))j[pl]=_,j[r]=L,pl=r;else break l}}return X}function E(j,X){var L=j.sortIndex-X.sortIndex;return L!==0?L:j.id-X.id}if(x.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var H=performance;x.unstable_now=function(){return H.now()}}else{var J=Date,K=J.now();x.unstable_now=function(){return J.now()-K}}var Q=[],W=[],A=1,S=null,D=3,w=!1,U=!1,vl=!1,P=!1,jl=typeof setTimeout=="function"?setTimeout:null,Bl=typeof clearTimeout=="function"?clearTimeout:null,I=typeof setImmediate<"u"?setImmediate:null;function il(j){for(var X=T(W);X!==null;){if(X.callback===null)d(W);else if(X.startTime<=j)d(W),X.sortIndex=X.expirationTime,O(Q,X);else break;X=T(W)}}function Il(j){if(vl=!1,il(j),!U)if(T(Q)!==null)U=!0,Pl||(Pl=!0,rt());else{var X=T(W);X!==null&&ql(Il,X.startTime-j)}}var Pl=!1,ll=-1,ol=5,Qt=-1;function Tt(){return P?!0:!(x.unstable_now()-Qtj&&Tt());){var pl=S.callback;if(typeof pl=="function"){S.callback=null,D=S.priorityLevel;var ml=pl(S.expirationTime<=j);if(j=x.unstable_now(),typeof ml=="function"){S.callback=ml,il(j),X=!0;break t}S===T(Q)&&d(Q),il(j)}else d(Q);S=T(Q)}if(S!==null)X=!0;else{var Rt=T(W);Rt!==null&&ql(Il,Rt.startTime-j),X=!1}}break l}finally{S=null,D=L,w=!1}X=void 0}}finally{X?rt():Pl=!1}}}var rt;if(typeof I=="function")rt=function(){I(_t)};else if(typeof MessageChannel<"u"){var be=new MessageChannel,$e=be.port2;be.port1.onmessage=_t,rt=function(){$e.postMessage(null)}}else rt=function(){jl(_t,0)};function ql(j,X){ll=jl(function(){j(x.unstable_now())},X)}x.unstable_IdlePriority=5,x.unstable_ImmediatePriority=1,x.unstable_LowPriority=4,x.unstable_NormalPriority=3,x.unstable_Profiling=null,x.unstable_UserBlockingPriority=2,x.unstable_cancelCallback=function(j){j.callback=null},x.unstable_forceFrameRate=function(j){0>j||125pl?(j.sortIndex=L,O(W,j),T(Q)===null&&j===T(W)&&(vl?(Bl(ll),ll=-1):vl=!0,ql(Il,L-pl))):(j.sortIndex=ml,O(Q,j),U||w||(U=!0,Pl||(Pl=!0,rt()))),j},x.unstable_shouldYield=Tt,x.unstable_wrapCallback=function(j){var X=D;return function(){var L=D;D=X;try{return j.apply(this,arguments)}finally{D=L}}}})(Os)),Os}var s0;function Ev(){return s0||(s0=1,zs.exports=_v()),zs.exports}var js={exports:{}},Wl={};/** * @license React * react-dom.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var o0;function zv(){if(o0)return Wl;o0=1;var x=As();function O(A){var S="https://react.dev/errors/"+A;if(1"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(x)}catch(O){console.error(O)}}return x(),js.exports=zv(),js.exports}/** * @license React * react-dom-client.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var d0;function jv(){if(d0)return cn;d0=1;var x=Ev(),O=As(),T=Ov();function d(l){var t="https://react.dev/errors/"+l;if(1Sa||(l.current=Qc[Sa],Qc[Sa]=null,Sa--)}function Tl(l,t){Sa++,Qc[Sa]=l.current,l.current=t}var Lt=Xt(null),ru=Xt(null),xe=Xt(null),fn=Xt(null);function sn(l,t){switch(Tl(xe,t),Tl(ru,l),Tl(Lt,null),t.nodeType){case 9:case 11:l=(l=t.documentElement)&&(l=l.namespaceURI)?mm(l):0;break;default:if(l=t.tagName,t=t.namespaceURI)t=mm(t),l=hm(t,l);else switch(l){case"svg":l=1;break;case"math":l=2;break;default:l=0}}Ll(Lt),Tl(Lt,l)}function pa(){Ll(Lt),Ll(ru),Ll(xe)}function Xc(l){var t=l.memoizedState;t!==null&&(fu._currentValue=t.memoizedState,Tl(fn,l)),t=Lt.current;var e=hm(t,l.type);t!==e&&(Tl(ru,l),Tl(Lt,e))}function on(l){ru.current===l&&(Ll(Lt),Ll(ru)),fn.current===l&&(Ll(fn),fu._currentValue=ee)}var Lc,Us;function Se(l){if(Lc===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);Lc=t&&t[1]||"",Us=-1)":-1u||s[a]!==v[u]){var b=` `+s[a].replace(" at new "," at ");return l.displayName&&b.includes("")&&(b=b.replace("",l.displayName)),b}while(1<=a&&0<=u);break}}}finally{Zc=!1,Error.prepareStackTrace=e}return(e=l?l.displayName||l.name:"")?Se(e):""}function E0(l,t){switch(l.tag){case 26:case 27:case 5:return Se(l.type);case 16:return Se("Lazy");case 13:return l.child!==t&&t!==null?Se("Suspense Fallback"):Se("Suspense");case 19:return Se("SuspenseList");case 0:case 15:return Vc(l.type,!1);case 11:return Vc(l.type.render,!1);case 1:return Vc(l.type,!0);case 31:return Se("Activity");case 30:return Se("ViewTransition");default:return""}}function Rs(l){try{var t="",e=null;do t+=E0(l,e),e=l,l=l.return;while(l);return t}catch(a){return` Error generating stack: `+a.message+` `+a.stack}}var Kc=Object.prototype.hasOwnProperty,Jc=x.unstable_scheduleCallback,kc=x.unstable_cancelCallback,z0=x.unstable_shouldYield,O0=x.unstable_requestPaint,dt=x.unstable_now,j0=x.unstable_getCurrentPriorityLevel,Hs=x.unstable_ImmediatePriority,Ys=x.unstable_UserBlockingPriority,rn=x.unstable_NormalPriority,A0=x.unstable_LowPriority,Bs=x.unstable_IdlePriority,C0=x.log,M0=x.unstable_setDisableYieldValue,du=null,mt=null;function pe(l){if(typeof C0=="function"&&M0(l),mt&&typeof mt.setStrictMode=="function")try{mt.setStrictMode(du,l)}catch{}}var ht=Math.clz32?Math.clz32:R0,D0=Math.log,U0=Math.LN2;function R0(l){return l>>>=0,l===0?32:31-(D0(l)/U0|0)|0}var dn=256,mn=262144,hn=4194304;function Fe(l){var t=l&42;if(t!==0)return t;switch(l&-l){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return l&-l;case 262144:case 524288:case 1048576:case 2097152:return l&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return l&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return l}}function vn(l,t,e){var a=l.pendingLanes;if(a===0)return 0;var u=0,n=l.suspendedLanes,c=l.pingedLanes;l=l.warmLanes;var i=a&134217727;return i!==0?(a=i&~n,a!==0?u=Fe(a):(c&=i,c!==0?u=Fe(c):e||(e=i&~l,e!==0&&(u=Fe(e))))):(i=a&~n,i!==0?u=Fe(i):c!==0?u=Fe(c):e||(e=a&~l,e!==0&&(u=Fe(e)))),u===0?0:t!==0&&t!==u&&(t&n)===0&&(n=u&-u,e=t&-t,n>=e||n===32&&(e&4194048)!==0)?t:u}function mu(l,t){return(l.pendingLanes&~(l.suspendedLanes&~l.pingedLanes)&t)===0}function qs(l,t){(t&8)!==0&&(t|=t&32);var e=l.entangledLanes;if(e!==0)for(l=l.entanglements,e&=t;0e;e++)t.push(l);return t}function hu(l,t){l.pendingLanes|=t,t!==268435456&&(l.suspendedLanes=0,l.pingedLanes=0,l.warmLanes=0)}function Y0(l,t,e,a,u,n){var c=l.pendingLanes;l.pendingLanes=e,l.suspendedLanes=0,l.pingedLanes=0,l.warmLanes=0,l.expiredLanes&=e,l.entangledLanes&=e,l.errorRecoveryDisabledLanes&=e,l.shellSuspendCounter=0;var i=l.entanglements,s=l.expirationTimes,v=l.hiddenUpdates;for(e=c&~e;0"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ni=!1;if(ne)try{var bu={};Object.defineProperty(bu,"passive",{get:function(){ni=!0}}),window.addEventListener("test",bu,bu),window.removeEventListener("test",bu,bu)}catch{ni=!1}var Ne=null,ci=null,pn=null;function fo(){if(pn)return pn;var l,t=ci,e=t.length,a,u="value"in Ne?Ne.value:Ne.textContent,n=u.length;for(l=0;l=pu),vo=" ",yo=!1;function go(l,t){switch(l){case"keyup":return bh.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function bo(l){return l=l.detail,typeof l=="object"&&"data"in l?l.data:null}var Ca=!1;function Sh(l,t){switch(l){case"compositionend":return bo(t);case"keypress":return t.which!==32?null:(yo=!0,vo);case"textInput":return l=t.data,l===vo&&yo?null:l;default:return null}}function ph(l,t){if(Ca)return l==="compositionend"||!ri&&go(l,t)?(l=fo(),pn=ci=Ne=null,Ca=!1,l):null;switch(l){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1"u")return null;try{return l.activeElement||l.body}catch{return l.body}}function zo(l){for(;l&&l.firstChild;)l=l.firstChild;return l}function Oo(l,t){var e=zo(l);l=0;for(var a;e;){if(e.nodeType===3){if(a=l+e.textContent.length,l<=t&&a>=t)return{node:e,offset:t-l};l=a}l:{for(;e;){if(e.nextSibling){e=e.nextSibling;break l}e=e.parentNode}e=void 0}e=zo(e)}}function jo(l,t){return l&&t?l===t?!0:l&&l.nodeType===3?!1:t&&t.nodeType===3?jo(l,t.parentNode):"contains"in l?l.contains(t):l.compareDocumentPosition?!!(l.compareDocumentPosition(t)&16):!1:!1}function Ao(l){l=l!=null&&l.ownerDocument!=null&&l.ownerDocument.defaultView!=null?l.ownerDocument.defaultView:window;for(var t=hi(l.document);t instanceof l.HTMLIFrameElement;){try{var e=typeof t.contentWindow.location.href=="string"}catch{e=!1}if(e)l=t.contentWindow;else break;t=hi(l.document)}return t}function vi(l){var t=l&&l.nodeName&&l.nodeName.toLowerCase();return t&&(t==="input"&&(l.type==="text"||l.type==="search"||l.type==="tel"||l.type==="url"||l.type==="password")||t==="textarea"||l.contentEditable==="true")}var Ah=ne&&"documentMode"in document&&11>=document.documentMode,Ma=null,yi=null,Eu=null,gi=!1;function Co(l,t,e){var a=e.window===e?e.document:e.nodeType===9?e:e.ownerDocument;gi||Ma==null||Ma!==hi(a)||(a=Ma,"selectionStart"in a&&vi(a)?a={start:a.selectionStart,end:a.selectionEnd}:(a=(a.ownerDocument&&a.ownerDocument.defaultView||window).getSelection(),a={anchorNode:a.anchorNode,anchorOffset:a.anchorOffset,focusNode:a.focusNode,focusOffset:a.focusOffset}),Eu&&_u(Eu,a)||(Eu=a,a=zc(yi,"onSelect"),0>=c,u-=c,Vt=1<<32-ht(t)+u|e<G?(Hl=Y,Y=null):Hl=Y.sibling;var nl=m(h,Y,y[G],p);if(nl===null){Y===null&&(Y=Hl);break}l&&Y&&nl.alternate===null&&t(h,Y),o=n(nl,o,G),ul===null?C=nl:ul.sibling=nl,ul=nl,Y=Hl}if(G===y.length)return e(h,Y),F&&se(h,G),C;if(Y===null){for(;GG?(Hl=Y,Y=null):Hl=Y.sibling;var Je=m(h,Y,nl.value,p);if(Je===null){Y===null&&(Y=Hl);break}l&&Y&&Je.alternate===null&&t(h,Y),o=n(Je,o,G),ul===null?C=Je:ul.sibling=Je,ul=Je,Y=Hl}if(nl.done)return e(h,Y),F&&se(h,G),C;if(Y===null){for(;!nl.done;G++,nl=y.next())nl=N(h,nl.value,p),nl!==null&&(o=n(nl,o,G),ul===null?C=nl:ul.sibling=nl,ul=nl);return F&&se(h,G),C}for(Y=a(Y);!nl.done;G++,nl=y.next())nl=g(Y,h,G,nl.value,p),nl!==null&&(l&&(Hl=nl.alternate,Hl!==null&&Y.delete(Hl.key===null?G:Hl.key)),o=n(nl,o,G),ul===null?C=nl:ul.sibling=nl,ul=nl);return l&&Y.forEach(function(Sv){return t(h,Sv)}),F&&se(h,G),C}function $(h,o,y,p){if(typeof y=="object"&&y!==null&&y.type===_t&&y.key===null&&y.props.ref===void 0&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case Qt:l:{for(var C=y.key;o!==null;){if(o.key===C){if(C=y.type,C===_t){if(o.tag===7){e(h,o.sibling),p=u(o,y.props.children),je(p,y),p.return=h,h=p;break l}}else if(o.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===ml&&oa(C)===o.type){e(h,o.sibling),p=u(o,y.props),je(p,y),p.return=h,h=p;break l}e(h,o);break}else t(h,o);o=o.sibling}y.type===_t?(p=aa(y.props.children,h.mode,p,y.key),je(p,y),p.return=h,h=p):(p=Mn(y.type,y.key,y.props,null,h.mode,p),je(p,y),p.return=h,h=p)}return c(h);case Tt:l:{for(C=y.key;o!==null;){if(o.key===C)if(o.tag===4&&o.stateNode.containerInfo===y.containerInfo&&o.stateNode.implementation===y.implementation){e(h,o.sibling),p=u(o,y.children||[]),p.return=h,h=p;break l}else{e(h,o);break}else t(h,o);o=o.sibling}p=_i(y,h.mode,p),p.return=h,h=p}return c(h);case ml:return y=oa(y),$(h,o,y,p)}if(rl(y))return z(h,o,y,p);if(q(y)){if(C=q(y),typeof C!="function")throw Error(d(150));return y=C.call(y),M(h,o,y,p)}if(typeof y.then=="function")return $(h,o,Qn(y),p);if(y.$$typeof===ql)return $(h,o,Bn(h,y),p);Xn(h,y)}return typeof y=="string"&&y!==""||typeof y=="number"||typeof y=="bigint"?(y=""+y,o!==null&&o.tag===6?(e(h,o.sibling),p=u(o,y),p.return=h,h=p):(e(h,o),p=Ti(y,h.mode,p),p.return=h,h=p),c(h)):e(h,o)}return function(h,o,y,p){try{Mu=0;var C=$(h,o,y,p);return Ga=null,C}catch(Y){if(Y===wa||Y===wn)throw Y;var ul=ct(29,Y,null,h.mode);return ul.lanes=p,ul.return=h,ul}finally{}}}var da=lr(!0),tr=lr(!1),Ae=!1;function Ri(l){l.updateQueue={baseState:l.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Hi(l,t){l=l.updateQueue,t.updateQueue===l&&(t.updateQueue={baseState:l.baseState,firstBaseUpdate:l.firstBaseUpdate,lastBaseUpdate:l.lastBaseUpdate,shared:l.shared,callbacks:null})}function Ce(l){return{lane:l,tag:0,payload:null,callback:null,next:null}}function Me(l,t,e){var a=l.updateQueue;if(a===null)return null;if(a=a.shared,(dl&2)!==0){var u=a.pending;return u===null?t.next=t:(t.next=u.next,u.next=t),a.pending=t,t=Cn(l),qo(l,null,e),t}return An(l,a,t,e),Cn(l)}function Du(l,t,e){if(t=t.updateQueue,t!==null&&(t=t.shared,(e&4194048)!==0)){var a=t.lanes;a&=l.pendingLanes,e|=a,t.lanes=e,Qs(l,e)}}function Yi(l,t){var e=l.updateQueue,a=l.alternate;if(a!==null&&(a=a.updateQueue,e===a)){var u=null,n=null;if(e=e.firstBaseUpdate,e!==null){do{var c={lane:e.lane,tag:e.tag,payload:e.payload,callback:null,next:null};n===null?u=n=c:n=n.next=c,e=e.next}while(e!==null);n===null?u=n=t:n=n.next=t}else u=n=t;e={baseState:a.baseState,firstBaseUpdate:u,lastBaseUpdate:n,shared:a.shared,callbacks:a.callbacks},l.updateQueue=e;return}l=e.lastBaseUpdate,l===null?e.firstBaseUpdate=t:l.next=t,e.lastBaseUpdate=t}var Bi=!1;function Uu(){if(Bi){var l=qa;if(l!==null)throw l}}function Ru(l,t,e,a){Bi=!1;var u=l.updateQueue;Ae=!1;var n=u.firstBaseUpdate,c=u.lastBaseUpdate,i=u.shared.pending;if(i!==null){u.shared.pending=null;var s=i,v=s.next;s.next=null,c===null?n=v:c.next=v,c=s;var b=l.alternate;b!==null&&(b=b.updateQueue,i=b.lastBaseUpdate,i!==c&&(i===null?b.firstBaseUpdate=v:i.next=v,b.lastBaseUpdate=s))}if(n!==null){var N=u.baseState;c=0,b=v=s=null,i=n;do{var m=i.lane&-536870913,g=m!==i.lane;if(g?(al&m)===m:(a&m)===m){m!==0&&m===fa&&(Bi=!0),b!==null&&(b=b.next={lane:0,tag:i.tag,payload:i.payload,callback:null,next:null});l:{var z=l,M=i;m=t;var $=e;switch(M.tag){case 1:if(z=M.payload,typeof z=="function"){N=z.call($,N,m);break l}N=z;break l;case 3:z.flags=z.flags&-65537|128;case 0:if(z=M.payload,m=typeof z=="function"?z.call($,N,m):z,m==null)break l;N=ll({},N,m);break l;case 2:Ae=!0}}m=i.callback,m!==null&&(l.flags|=64,g&&(l.flags|=8192),g=u.callbacks,g===null?u.callbacks=[m]:g.push(m))}else g={lane:m,tag:i.tag,payload:i.payload,callback:i.callback,next:null},b===null?(v=b=g,s=N):b=b.next=g,c|=m;if(i=i.next,i===null){if(i=u.shared.pending,i===null)break;g=i,i=g.next,g.next=null,u.lastBaseUpdate=g,u.shared.pending=null}}while(!0);b===null&&(s=N),u.baseState=s,u.firstBaseUpdate=v,u.lastBaseUpdate=b,n===null&&(u.shared.lanes=0),qe|=c,l.lanes=c,l.memoizedState=N}}function er(l,t){if(typeof l!="function")throw Error(d(191,l));l.call(t)}function ar(l,t){var e=l.callbacks;if(e!==null)for(l.callbacks=null,l=0;ln?n:8;var c=R.T,i={};i.types=c!==null?c.types:null,R.T=i,af(l,!1,t,e);try{var s=u(),v=R.S;if(v!==null&&v(i,s),s!==null&&typeof s=="object"&&typeof s.then=="function"){var b=Gh(s,a);qu(l,t,b,pt(l))}else qu(l,t,a,pt(l))}catch(N){qu(l,t,{then:function(){},status:"rejected",reason:N},pt())}finally{Z.p=n,c!==null&&i.types!==null&&(c.types=i.types),R.T=c}}function Kh(){}function tf(l,t,e,a){if(l.tag!==5)throw Error(d(476));var u=Hr(l).queue;Rr(l,u,t,ee,e===null?Kh:function(){return Yr(l),e(a)})}function Hr(l){var t=l.memoizedState;if(t!==null)return t;t={memoizedState:ee,baseState:ee,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:me,lastRenderedState:ee},next:null};var e={};return t.next={memoizedState:e,baseState:e,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:me,lastRenderedState:e},next:null},l.memoizedState=t,l=l.alternate,l!==null&&(l.memoizedState=t),t}function Yr(l){var t=Hr(l);t.next===null&&(t=l.alternate.memoizedState),qu(l,t.next.queue,{},pt())}function ef(){return Vl(fu)}function Br(){return Ml().memoizedState}function qr(){return Ml().memoizedState}function Jh(l){for(var t=l.return;t!==null;){switch(t.tag){case 24:case 3:var e=pt();l=Ce(e);var a=Me(t,l,e);a!==null&&(ot(a,t,e),Du(a,t,e)),t={cache:Ci()},l.payload=t;return}t=t.return}}function kh(l,t,e){var a=pt();e={lane:a,revertLane:0,gesture:null,action:e,hasEagerState:!1,eagerState:null,next:null},In(l)?Gr(t,e):(e=pi(l,t,e,a),e!==null&&(ot(e,l,a),Qr(e,t,a)))}function wr(l,t,e){var a=pt();qu(l,t,e,a)}function qu(l,t,e,a){var u={lane:a,revertLane:0,gesture:null,action:e,hasEagerState:!1,eagerState:null,next:null};if(In(l))Gr(t,u);else{var n=l.alternate;if(l.lanes===0&&(n===null||n.lanes===0)&&(n=t.lastRenderedReducer,n!==null))try{var c=t.lastRenderedState,i=n(c,e);if(u.hasEagerState=!0,u.eagerState=i,yt(i,c))return An(l,t,u,0),Nl===null&&jn(),!1}catch{}finally{}if(e=pi(l,t,u,a),e!==null)return ot(e,l,a),Qr(e,t,a),!0}return!1}function af(l,t,e,a){if(a={lane:2,revertLane:kf(),gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},In(l)){if(t)throw Error(d(479))}else t=pi(l,e,a,2),t!==null&&ot(t,l,2)}function In(l){var t=l.alternate;return l===k||t!==null&&t===k}function Gr(l,t){Qa=Vn=!0;var e=l.pending;e===null?t.next=t:(t.next=e.next,e.next=t),l.pending=t}function Qr(l,t,e){if((e&4194048)!==0){var a=t.lanes;a&=l.pendingLanes,e|=a,t.lanes=e,Qs(l,e)}}var Pn={readContext:Vl,use:kn,useCallback:Al,useContext:Al,useEffect:Al,useImperativeHandle:Al,useLayoutEffect:Al,useInsertionEffect:Al,useMemo:Al,useReducer:Al,useRef:Al,useState:Al,useDebugValue:Al,useDeferredValue:Al,useTransition:Al,useSyncExternalStore:Al,useId:Al,useHostTransitionStatus:Al,useFormState:Al,useActionState:Al,useOptimistic:Al,useMemoCache:Al,useCacheRefresh:Al,useEffectEvent:Al},Xr={readContext:Vl,use:kn,useCallback:function(l,t){return et().memoizedState=[l,t===void 0?null:t],l},useContext:Vl,useEffect:Er,useImperativeHandle:function(l,t,e){e=e!=null?e.concat([l]):null,Wn(4194308,4,Ar.bind(null,t,l),e)},useLayoutEffect:function(l,t){return Wn(4194308,4,l,t)},useInsertionEffect:function(l,t){Wn(4,2,l,t)},useMemo:function(l,t){var e=et();t=t===void 0?null:t;var a=l();if(ma){pe(!0);try{l()}finally{pe(!1)}}return e.memoizedState=[a,t],a},useReducer:function(l,t,e){var a=et();if(e!==void 0){var u=e(t);if(ma){pe(!0);try{e(t)}finally{pe(!1)}}}else u=t;return a.memoizedState=a.baseState=u,l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:l,lastRenderedState:u},a.queue=l,l=l.dispatch=kh.bind(null,k,l),[a.memoizedState,l]},useRef:function(l){var t=et();return l={current:l},t.memoizedState=l},useState:function(l){l=Wi(l);var t=l.queue,e=wr.bind(null,k,t);return t.dispatch=e,[l.memoizedState,e]},useDebugValue:Pi,useDeferredValue:function(l,t){var e=et();return lf(e,l,t)},useTransition:function(){var l=Wi(!1);return l=Rr.bind(null,k,l.queue,!0,!1),et().memoizedState=l,[!1,l]},useSyncExternalStore:function(l,t,e){var a=k,u=et();if(F){if(e===void 0)throw Error(d(407));e=e()}else{if(e=t(),Nl===null)throw Error(d(349));(al&127)!==0||sr(a,t,e)}u.memoizedState=e;var n={value:e,getSnapshot:t};return u.queue=n,Er(rr.bind(null,a,n,l),[l]),a.flags|=2048,La(9,{destroy:void 0},or.bind(null,a,n,e,t),null),e},useId:function(){var l=et(),t=Nl.identifierPrefix;if(F){var e=Kt,a=Vt;e=(a&~(1<<32-ht(a)-1)).toString(32)+e,t="_"+t+"R_"+e,e=Kn++,0<\/script>",n=n.removeChild(n.firstChild);break;case"select":n=typeof a.is=="string"?c.createElement("select",{is:a.is}):c.createElement("select"),a.multiple?n.multiple=!0:a.size&&(n.size=a.size);break;default:n=typeof a.is=="string"?c.createElement(u,{is:a.is}):c.createElement(u)}}n[Zl]=t,n[nt]=a;l:for(c=t.child;c!==null;){if(c.tag===5||c.tag===6)n.appendChild(c.stateNode);else if(c.tag!==4&&c.tag!==27&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===t)break l;for(;c.sibling===null;){if(c.return===null||c.return===t)break l;c=c.return}c.sibling.return=c.return,c=c.sibling}t.stateNode=n;l:switch($l(n,u,a),u){case"button":case"input":case"select":case"textarea":a=!!a.autoFocus;break l;case"img":a=!0;break l;default:a=!1}a&&ve(t)}}return El(t),t.subtreeFlags&=-33554433,gf(t,t.type,l===null?null:l.memoizedProps,t.pendingProps,e),null;case 6:if(l&&t.stateNode!=null)l.memoizedProps!==a&&ve(t);else{if(typeof a!="string"&&t.stateNode===null)throw Error(d(166));if(l=xe.current,Ba(t)){if(l=t.stateNode,e=t.memoizedProps,a=null,u=Gl,u!==null)switch(u.tag){case 27:case 5:a=u.memoizedProps}l[Zl]=t,l=!!(l.nodeValue===e||a!==null&&a.suppressHydrationWarning===!0||rm(l.nodeValue,e)),l||ze(t,!0)}else l=Fu(l).createTextNode(a),l[Zl]=t,t.stateNode=l}return El(t),null;case 31:if(e=t.memoizedState,l===null||l.memoizedState!==null){if(a=Ba(t),e!==null){if(l===null){if(!a)throw Error(d(318));if(l=t.memoizedState,l=l!==null?l.dehydrated:null,!l)throw Error(d(557));l[Zl]=t}else ua(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;El(t),l=!1}else e=Oi(),l!==null&&l.memoizedState!==null&&(l.memoizedState.hydrationErrors=e),l=!0;if(!l)return t.flags&256?(gt(t),t):(gt(t),null);if((t.flags&128)!==0)throw Error(d(558))}return El(t),null;case 13:if(a=t.memoizedState,l===null||l.memoizedState!==null&&l.memoizedState.dehydrated!==null){if(u=Ba(t),a!==null&&a.dehydrated!==null){if(l===null){if(!u)throw Error(d(318));if(u=t.memoizedState,u=u!==null?u.dehydrated:null,!u)throw Error(d(317));u[Zl]=t}else ua(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;El(t),u=!1}else u=Oi(),l!==null&&l.memoizedState!==null&&(l.memoizedState.hydrationErrors=u),u=!0;if(!u)return t.flags&256?(gt(t),t):(gt(t),null)}return gt(t),(t.flags&128)!==0?(t.lanes=e,t):(e=a!==null,l=l!==null&&l.memoizedState!==null,e&&(a=t.child,u=null,a.alternate!==null&&a.alternate.memoizedState!==null&&a.alternate.memoizedState.cachePool!==null&&(u=a.alternate.memoizedState.cachePool.pool),n=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(n=a.memoizedState.cachePool.pool),n!==u&&(a.flags|=2048)),e!==l&&e&&(t.child.flags|=8192),nc(t,t.updateQueue),El(t),null);case 4:return pa(),l===null&&If(t.stateNode.containerInfo),t.flags|=67108864,El(t),null;case 10:return re(t.type),El(t),null;case 19:if(Qi(t),a=t.memoizedState,a===null)return El(t),null;if(u=(t.flags&128)!==0,n=a.rendering,n===null)if(u)Gu(a,!1);else{if(Cl!==0||l!==null&&(l.flags&128)!==0)for(l=t.child;l!==null;){if(n=Zn(l),n!==null){for(t.flags|=128,Gu(a,!1),l=n.updateQueue,t.updateQueue=l,nc(t,l),t.subtreeFlags=0,l=e,e=t.child;e!==null;)wo(e,l),e=e.sibling;return Hu(t,Jl.current&1|2),F&&se(t,a.treeForkCount),t.child}l=l.sibling}a.tail!==null&&dt()>gc&&(t.flags|=128,u=!0,Gu(a,!1),t.lanes=4194304)}else{if(!u)if(l=Zn(n),l!==null){if(t.flags|=128,u=!0,l=l.updateQueue,t.updateQueue=l,nc(t,l),Gu(a,!0),a.tail===null&&a.tailMode!=="collapsed"&&a.tailMode!=="visible"&&!n.alternate&&!F)return El(t),null}else 2*dt()-a.renderingStartTime>gc&&e!==536870912&&(t.flags|=128,u=!0,Gu(a,!1),t.lanes=4194304);a.isBackwards?(n.sibling=t.child,t.child=n):(l=a.last,l!==null?l.sibling=n:t.child=n,a.last=n)}if(a.tail!==null){l=a.tail;l:{for(e=l;e!==null;){if(e.alternate!==null){e=!1;break l}e=e.sibling}e=!0}return a.rendering=l,a.tail=l.sibling,a.renderingStartTime=dt(),l.sibling=null,n=Jl.current,n=u?n&1|2:n&1,a.tailMode==="visible"||a.tailMode==="collapsed"||!e||F?Hu(t,n):(e=n,Tl(Kl,t),Tl(Jl,e),lt===null&&(lt=t)),F&&se(t,a.treeForkCount),l}return El(t),null;case 22:case 23:return gt(t),wi(),a=t.memoizedState!==null,l!==null?l.memoizedState!==null!==a&&(t.flags|=8192):a&&(t.flags|=8192),a?(e&536870912)!==0&&(t.flags&128)===0&&(El(t),t.subtreeFlags&6&&(t.flags|=8192)):El(t),e=t.updateQueue,e!==null&&nc(t,e.retryQueue),e=null,l!==null&&l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(e=l.memoizedState.cachePool.pool),a=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(a=t.memoizedState.cachePool.pool),a!==e&&(t.flags|=2048),l!==null&&Ll(sa),null;case 24:return e=null,l!==null&&(e=l.memoizedState.cache),t.memoizedState.cache!==e&&(t.flags|=2048),re(Dl),El(t),null;case 25:return null;case 30:return t.flags|=33554432,El(t),null}throw Error(d(156,t.tag))}function t1(l,t){switch(Ei(t),t.tag){case 1:return l=t.flags,l&65536?(t.flags=l&-65537|128,t):null;case 3:return re(Dl),pa(),l=t.flags,(l&65536)!==0&&(l&128)===0?(t.flags=l&-65537|128,t):null;case 26:case 27:case 5:return on(t),null;case 31:if(t.memoizedState!==null){if(gt(t),t.alternate===null)throw Error(d(340));ua()}return l=t.flags,l&65536?(t.flags=l&-65537|128,t):null;case 13:if(gt(t),l=t.memoizedState,l!==null&&l.dehydrated!==null){if(t.alternate===null)throw Error(d(340));ua()}return l=t.flags,l&65536?(t.flags=l&-65537|128,t):null;case 19:return Qi(t),l=t.flags,l&65536?(t.flags=l&-65537|128,l=t.memoizedState,l!==null&&(l.rendering=null,l.tail=null),t.flags|=4,t):null;case 4:return pa(),null;case 10:return re(t.type),null;case 22:case 23:return gt(t),wi(),l!==null&&Ll(sa),l=t.flags,l&65536?(t.flags=l&-65537|128,t):null;case 24:return re(Dl),null;case 25:return null;default:return null}}function md(l,t){switch(Ei(t),t.tag){case 3:re(Dl),pa();break;case 26:case 27:case 5:on(t);break;case 4:pa();break;case 31:t.memoizedState!==null&>(t);break;case 13:gt(t);break;case 19:Qi(t);break;case 10:re(t.type);break;case 22:case 23:gt(t),wi(),l!==null&&Ll(sa);break;case 24:re(Dl)}}function Qu(l,t){try{var e=t.updateQueue,a=e!==null?e.lastEffect:null;if(a!==null){var u=a.next;e=u;do{if((e.tag&l)===l){a=void 0;var n=e.create,c=e.inst;a=n(),c.destroy=a}e=e.next}while(e!==u)}}catch(i){gl(t,t.return,i)}}function He(l,t,e){try{var a=t.updateQueue,u=a!==null?a.lastEffect:null;if(u!==null){var n=u.next;a=n;do{if((a.tag&l)===l){var c=a.inst,i=c.destroy;if(i!==void 0){c.destroy=void 0,u=t;var s=e,v=i;try{v()}catch(b){gl(u,s,b)}}}a=a.next}while(a!==n)}}catch(b){gl(t,t.return,b)}}function hd(l){var t=l.updateQueue;if(t!==null){var e=l.stateNode;try{ar(t,e)}catch(a){gl(l,l.return,a)}}}function vd(l,t,e){e.props=ha(l.type,l.memoizedProps),e.state=l.memoizedState;try{e.componentWillUnmount()}catch(a){gl(l,t,a)}}function Jt(l,t){try{var e=l.ref;if(e!==null){switch(l.tag){case 26:case 27:case 5:var a=l.stateNode;break;case 30:var u=l.stateNode,n=ce(l.memoizedProps,u);(u.ref===null||u.ref.name!==n)&&(u.ref=Nm(n)),a=u.ref;break;case 7:if(l.stateNode===null){var c=new Nt(l);S(l.child,!1,V1,c,void 0,void 0),l.stateNode=c}a=l.stateNode;break;default:a=l.stateNode}typeof e=="function"?l.refCleanup=e(a):e.current=a}}catch(i){gl(l,t,i)}}function kl(l,t){var e=l.ref,a=l.refCleanup;if(e!==null)if(typeof a=="function")try{a()}catch(u){gl(l,t,u)}finally{l.refCleanup=null,l=l.alternate,l!=null&&(l.refCleanup=null)}else if(typeof e=="function")try{e(null)}catch(u){gl(l,t,u)}else e.current=null}function cc(l,t){if((l.tag===5||l.tag===27||l.tag===6)&&l.alternate===null&&t!==null)for(var e=0;e title"))),$l(a,t,e),a[Zl]=l,wl(a),t=a;break l;case"link":if(n=wm("link","href",u).get(t+(e.href||""))){for(c=0;c$&&(c=$,$=M,M=c);var h=Oo(i,M),o=Oo(i,$);if(h&&o&&(g.rangeCount!==1||g.anchorNode!==h.node||g.anchorOffset!==h.offset||g.focusNode!==o.node||g.focusOffset!==o.offset)){var y=N.createRange();y.setStart(h.node,h.offset),g.removeAllRanges(),M>$?(g.addRange(y),g.extend(o.node,o.offset)):(y.setEnd(o.node,o.offset),g.addRange(y))}}}}for(N=[],g=i;g=g.parentNode;)g.nodeType===1&&N.push({element:g,left:g.scrollLeft,top:g.scrollTop});for(typeof i.focus=="function"&&i.focus(),i=0;ie?32:e,R.T=null,e=qf,qf=null;var n=wt,c=Pt;if(Ol=0,ba=wt=null,Pt=0,(dl&6)!==0)throw Error(d(331));var i=dl;if(dl|=4,qd(n.current),Hd(n,n.current,c,e),dl=i,ku(0,!1),mt&&typeof mt.onPostCommitFiberRoot=="function")try{mt.onPostCommitFiberRoot(du,n)}catch{}return!0}finally{Z.p=u,R.T=a,Pd(l,t)}}function lm(l,t,e){t=Ot(e,t),t=cf(l.stateNode,t,2),l=Me(l,t,2),l!==null&&(hu(l,2),le(l))}function gl(l,t,e){if(l.tag===3)lm(l,l,e);else for(;t!==null;){if(t.tag===3){lm(t,l,e);break}else if(t.tag===1){var a=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof a.componentDidCatch=="function"&&(we===null||!we.has(a))){l=Ot(e,l),e=Wr(2),a=Me(t,e,2),a!==null&&(Fr(e,a,t,l),hu(a,2),le(a));break}}t=t.return}}function Vf(l,t,e){var a=l.pingCache;if(a===null){a=l.pingCache=new n1;var u=new Set;a.set(t,u)}else u=a.get(t),u===void 0&&(u=new Set,a.set(t,u));u.has(e)||(Hf=!0,u.add(e),l=m1.bind(null,l,t,e),t.then(l,l))}function m1(l,t,e){var a=l.pingCache;a!==null&&a.delete(t),l.pingedLanes|=l.suspendedLanes&e,l.warmLanes&=~e,Nl===l&&(al&e)===e&&((Cl===4||Cl===3&&(al&62914560)===al&&300>dt()-yc)&&(dl&2)===0?lu(l,0):vc|=e,$a===al&&($a=0)),le(l)}function tm(l,t){t===0&&(t=ws()),l=ea(l,t),l!==null&&(hu(l,t),le(l))}function h1(l){var t=l.memoizedState,e=0;t!==null&&(e=t.retryLane),tm(l,e)}function v1(l,t){var e=0;switch(l.tag){case 31:case 13:var a=l.stateNode,u=l.memoizedState;u!==null&&(e=u.retryLane);break;case 19:a=l.stateNode;break;case 22:a=l.stateNode._retryCache;break;default:throw Error(d(314))}a!==null&&a.delete(t),tm(l,e)}function y1(l,t){return Jc(l,t)}var eu=null,au=null,Kf=!1,_c=!1,Jf=!1,Qe=0;function le(l){l!==au&&l.next===null&&(au===null?eu=au=l:au=au.next=l),_c=!0,Kf||(Kf=!0,b1())}function ku(l,t){if(!Jf&&_c){Jf=!0;do for(var e=!1,a=eu;a!==null;){if(l!==0){var u=a.pendingLanes;if(u===0)var n=0;else{var c=a.suspendedLanes,i=a.pingedLanes;n=(1<<31-ht(42|l)+1)-1,n&=u&~(c&~i),n=n&201326741?n&201326741|1:n?n|2:0}n!==0&&(e=!0,nm(a,n))}else n=al,n=vn(a,a===Nl?n:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),(n&3)===0||mu(a,n)||(e=!0,nm(a,n));a=a.next}while(e);Jf=!1}}function g1(){em()}function em(){_c=Kf=!1;var l=0;Qe!==0&&A1()&&(l=Qe);for(var t=dt(),e=null,a=eu;a!==null;){var u=a.next,n=am(a,t);n===0?(a.next=null,e===null?eu=u:e.next=u,u===null&&(au=e)):(e=a,(l!==0||(n&3)!==0)&&(_c=!0)),a=u}Ol!==0&&Ol!==5||ku(l),Qe!==0&&(Qe=0)}function am(l,t){for(var e=l.suspendedLanes,a=l.pingedLanes,u=l.expirationTimes,n=l.pendingLanes&-62914561;0i)break;var b=s.transferSize,N=s.initiatorType;b&&dm(N)&&(s=s.responseEnd,c+=b*(sAc){M.length=z;break}y=new Promise(H1.bind(y)),M.push(y)}}}if(0"u"?null:document;function Hm(l,t,e){var a=nu;if(a&&typeof t=="string"&&t){var u=Et(t);u='link[rel="'+l+'"][href="'+u+'"]',typeof e=="string"&&(u+='[crossorigin="'+e+'"]'),Rm.has(u)||(Rm.add(u),l={rel:l,crossOrigin:e,href:t},a.querySelector(u)===null&&(t=a.createElement("link"),$l(t,"link",l),wl(t),a.head.appendChild(t)))}}function lv(l){ge.D(l),Hm("dns-prefetch",l,null)}function tv(l,t){ge.C(l,t),Hm("preconnect",l,t)}function ev(l,t,e){ge.L(l,t,e);var a=nu;if(a&&l&&t){var u='link[rel="preload"][as="'+Et(t)+'"]';t==="image"&&e&&e.imageSrcSet?(u+='[imagesrcset="'+Et(e.imageSrcSet)+'"]',typeof e.imageSizes=="string"&&(u+='[imagesizes="'+Et(e.imageSizes)+'"]')):u+='[href="'+Et(l)+'"]';var n=u;switch(t){case"style":n=cu(l);break;case"script":n=iu(l)}if(!(Ut.has(n)||(l=ll({rel:"preload",href:t==="image"&&e&&e.imageSrcSet?void 0:l,as:t},e),Ut.set(n,l),a.querySelector(u)!==null||t==="style"&&a.querySelector(Pu(n))||t==="script"&&a.querySelector(ln(n))))){var c=a.createElement("link");$l(c,"link",l),t==="style"&&(c[yn]=!0,c.onload=c.onerror=function(){Js(c)}),wl(c),a.head.appendChild(c)}}}function av(l,t){ge.m(l,t);var e=nu;if(e&&l){var a=t&&typeof t.as=="string"?t.as:"script",u='link[rel="modulepreload"][as="'+Et(a)+'"][href="'+Et(l)+'"]',n=u;switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":n=iu(l)}if(!Ut.has(n)&&(l=ll({rel:"modulepreload",href:l},t),Ut.set(n,l),e.querySelector(u)===null)){switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(e.querySelector(ln(n)))return}a=e.createElement("link"),$l(a,"link",l),wl(a),e.head.appendChild(a)}}}function uv(l,t,e){ge.S(l,t,e);var a=nu;if(a&&l){var u=_a(a).hoistableStyles,n=cu(l);t=t||"default";var c=u.get(n);if(!c){var i={loading:0,preload:null};if(c=a.querySelector(Pu(n)))i.loading=5;else{l=ll({rel:"stylesheet",href:l,"data-precedence":t},e),(e=Ut.get(n))&&hs(l,e);var s=c=a.createElement("link");wl(s),$l(s,"link",l),s._p=new Promise(function(v,b){s.onload=v,s.onerror=b}),s.addEventListener("load",function(){i.loading|=1}),s.addEventListener("error",function(){i.loading|=2}),i.loading|=4,Oc(c,t,a)}c={type:"stylesheet",instance:c,count:1,state:i},u.set(n,c)}}}function nv(l,t){ge.X(l,t);var e=nu;if(e&&l){var a=_a(e).hoistableScripts,u=iu(l),n=a.get(u);n||(n=e.querySelector(ln(u)),n||(l=ll({src:l,async:!0},t),(t=Ut.get(u))&&vs(l,t),n=e.createElement("script"),wl(n),$l(n,"link",l),e.head.appendChild(n)),n={type:"script",instance:n,count:1,state:null},a.set(u,n))}}function cv(l,t){ge.M(l,t);var e=nu;if(e&&l){var a=_a(e).hoistableScripts,u=iu(l),n=a.get(u);n||(n=e.querySelector(ln(u)),n||(l=ll({src:l,async:!0,type:"module"},t),(t=Ut.get(u))&&vs(l,t),n=e.createElement("script"),wl(n),$l(n,"link",l),e.head.appendChild(n)),n={type:"script",instance:n,count:1,state:null},a.set(u,n))}}function Ym(l,t,e,a){var u=(u=xe.current)?Iu(u):null;if(!u)throw Error(d(446));switch(l){case"meta":case"title":return null;case"style":return typeof e.precedence=="string"&&typeof e.href=="string"?(e=cu(e.href),t=_a(u).hoistableStyles,a=t.get(e),a||(a={type:"style",instance:null,count:0,state:null},t.set(e,a)),a):{type:"void",instance:null,count:0,state:null};case"link":if(e.rel==="stylesheet"&&typeof e.href=="string"&&typeof e.precedence=="string"){l=cu(e.href);var n=_a(u).hoistableStyles,c=n.get(l);if(c||(u=u.ownerDocument||u,c={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},n.set(l,c),(n=u.querySelector(Pu(l)))?n._p||(c.instance=n,c.state.loading=5):(n=Ut.get(l),n||(n={rel:"preload",as:"style",href:e.href,crossOrigin:e.crossOrigin,integrity:e.integrity,media:e.media,hrefLang:e.hrefLang,referrerPolicy:e.referrerPolicy},Ut.set(l,n)),iv(u,l,n,c.state))),t&&a===null)throw Error(d(528,""));return c}if(t&&a!==null)throw Error(d(529,""));return null;case"script":return t=e.async,e=e.src,typeof e=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(e=iu(e),t=_a(u).hoistableScripts,a=t.get(e),a||(a={type:"script",instance:null,count:0,state:null},t.set(e,a)),a):{type:"void",instance:null,count:0,state:null};default:throw Error(d(444,l))}}function cu(l){return'href="'+Et(l)+'"'}function Pu(l){return'link[rel="stylesheet"]['+l+"]"}function Bm(l){return ll({},l,{"data-precedence":l.precedence,precedence:null})}function iv(l,t,e,a){if(t=l.querySelector('link[rel="preload"][as="style"]['+t+"]")){if(t[yn]!==!0){a.loading=1;return}}else t=l.createElement("link"),t[yn]=!0,t.onload=t.onerror=Js.bind(null,t),$l(t,"link",e),wl(t),l.head.appendChild(t);a.preload=t,t.addEventListener("load",function(){return a.loading|=1}),t.addEventListener("error",function(){return a.loading|=2})}function iu(l){return'[src="'+Et(l)+'"]'}function ln(l){return"script[async]"+l}function qm(l,t,e){if(t.count++,t.instance===null)switch(t.type){case"style":var a=l.querySelector('style[data-href~="'+Et(e.href)+'"]');if(a)return t.instance=a,wl(a),a;var u=ll({},e,{"data-href":e.href,"data-precedence":e.precedence,href:null,precedence:null});return a=(l.ownerDocument||l).createElement("style"),wl(a),$l(a,"style",u),Oc(a,e.precedence,l),t.instance=a;case"stylesheet":u=cu(e.href);var n=l.querySelector(Pu(u));if(n)return t.state.loading|=4,t.instance=n,wl(n),n;a=Bm(e),(u=Ut.get(u))&&hs(a,u),n=(l.ownerDocument||l).createElement("link"),wl(n);var c=n;return c._p=new Promise(function(i,s){c.onload=i,c.onerror=s}),$l(n,"link",a),t.state.loading|=4,Oc(n,e.precedence,l),t.instance=n;case"script":return n=iu(e.src),(u=l.querySelector(ln(n)))?(t.instance=u,wl(u),u):(a=e,(u=Ut.get(n))&&(a=ll({},e),vs(a,u)),l=l.ownerDocument||l,u=l.createElement("script"),wl(u),$l(u,"link",a),l.head.appendChild(u),t.instance=u);case"void":return null;default:throw Error(d(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(a=t.instance,t.state.loading|=4,Oc(a,e.precedence,l));return t.instance}function Oc(l,t,e){for(var a=e.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),u=a.length?a[a.length-1]:null,n=u,c=0;c title"):null)}function fv(l,t,e){if(e===1||t.itemProp!=null)return!1;switch(l){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return l=t.disabled,typeof t.precedence=="string"&&l==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function Gm(l,t){return l==="img"&&t.src!=null&&t.src!==""&&t.onLoad==null&&t.loading!=="lazy"}function Qm(l){return!(l.type==="stylesheet"&&(l.state.loading&3)===0)}function Xm(l){return(l.width||100)*(l.height||100)*(typeof devicePixelRatio=="number"?devicePixelRatio:1)*.25}function Lm(l,t){typeof t.decode=="function"&&(l.imgCount++,t.complete||(l.imgBytes+=Xm(t),l.suspenseyImages.push(t)),l=rv.bind(l),t.decode().then(l,l))}function sv(l,t,e,a){if(e.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(e.state.loading&4)===0){if(e.instance===null){var u=cu(a.href),n=t.querySelector(Pu(u));if(n){t=n._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(l.count++,l=tn.bind(l),t.then(l,l)),e.state.loading|=4,e.instance=n,wl(n);return}n=t.ownerDocument||t,a=Bm(a),(u=Ut.get(u))&&hs(a,u),n=n.createElement("link"),wl(n);var c=n;c._p=new Promise(function(i,s){c.onload=i,c.onerror=s}),$l(n,"link",a),e.instance=n}l.stylesheets===null&&(l.stylesheets=new Map),l.stylesheets.set(e,t),(t=e.state.preload)&&(e.state.loading&3)===0&&(l.count++,e=tn.bind(l),t.addEventListener("load",e),t.addEventListener("error",e))}}var Ac=0;function ov(l,t){return l.stylesheets&&l.count===0&&Mc(l,l.stylesheets),0Ac?50:800)+t);return l.unsuspend=e,function(){l.unsuspend=null,clearTimeout(a),clearTimeout(u)}}:null}function Zm(l){if(l.count===0&&(l.imgCount===0||!l.waitingForImages)){if(l.stylesheets)Mc(l,l.stylesheets);else if(l.unsuspend){var t=l.unsuspend;l.unsuspend=null,t()}}}function tn(){this.count--,Zm(this)}function rv(){this.imgCount--,Zm(this)}var Cc=null;function Mc(l,t){l.stylesheets=null,l.unsuspend!==null&&(l.count++,Cc=new Map,t.forEach(dv,l),Cc=null,tn.call(l))}function dv(l,t){if(!(t.state.loading&4)){var e=Cc.get(l);if(e)var a=e.get(null);else{e=new Map,Cc.set(l,e);for(var u=l.querySelectorAll("link[data-precedence],style[data-precedence]"),n=0;n"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(x)}catch(O){console.error(O)}}return x(),Es.exports=jv(),Es.exports}var Cv=Av();const Mv=g0(Cv),h0=x=>{let O;const T=new Set,d=(W,A)=>{const S=typeof W=="function"?W(O):W;if(!Object.is(S,O)){const D=O;O=A??(typeof S!="object"||S===null)?S:Object.assign({},O,S),T.forEach(w=>w(O,D))}},E=()=>O,K={setState:d,getState:E,getInitialState:()=>Q,subscribe:W=>(T.add(W),()=>T.delete(W))},Q=O=x(d,E,K);return K},Dv=(x=>x?h0(x):h0),Uv=x=>x;function Rv(x,O=Uv){const T=wc.useSyncExternalStore(x.subscribe,wc.useCallback(()=>O(x.getState()),[x,O]),()=>O(x.getInitialState()));return wc.useDebugValue(T),T}const v0=x=>{const O=Dv(x),T=d=>Rv(O,d);return Object.assign(T,O),T},Hv=(x=>x?v0(x):v0),Yv=()=>typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,b0=x=>{const O=x==="system"?Yv():x==="dark",T=O?"catppuccin":"zinc-light";return typeof document<"u"&&document.documentElement.setAttribute("data-theme",T),O?"dark":"light"},qc=localStorage.getItem("hl_theme_v2"),x0=qc==="light"||qc==="dark"||qc==="system"?qc:"system",Bv=b0(x0),qv=localStorage.getItem("hl_route_mode")||"auto",wv=localStorage.getItem("hl_layout_preset")||"homepage-3col",Gv=typeof window<"u"&&window.location.pathname.startsWith("/storybook")?"storybook":"dashboard",ke=Hv((x,O)=>({theme:x0,resolvedTheme:Bv,routeMode:qv,layoutPreset:wv,viewMode:Gv,showAgyModal:!1,showCmdPalette:!1,toast:"",actionLoading:!1,telemetry:{mini:{chip:"Apple M6 (12核)",ip:"192.168.31.164",tailscale_ip:"100.108.205.40",cpu_pct:6.5,load_1m:.85,mem_used_gb:11.8,mem_total_gb:24,mem_pct:49.2,disk_used_gb:59.9,disk_total_gb:460.4,disk_pct:13,uptime:"运行中",agy_tmux:!0},nas:{ip:"192.168.31.185",online:!0,mounted:!0,total_tb:19.94,used_tb:3.36,free_tb:16.58,pct:16.8,latest_backup:"11-06 23:17"},network:{home_wan_ip:"124.90.142.21",ai_policy:"Ai平台 → 狮城节点",sg_node:"233boy-sea",sg_egress_ip:"104.43.105.243",sg_delay_ms:68},services:{agy:!0,vaultwarden:!0,nas:!0,clash:!0,router:!0,uptime:!0}},setTheme:T=>{localStorage.setItem("hl_theme_v2",T);const d=b0(T);x({theme:T,resolvedTheme:d})},toggleTheme:()=>{const{resolvedTheme:T,setTheme:d}=O();d(T==="dark"?"light":"dark")},setRouteMode:T=>{localStorage.setItem("hl_route_mode",T),x({routeMode:T})},setLayoutPreset:T=>{localStorage.setItem("hl_layout_preset",T),x({layoutPreset:T})},setViewMode:T=>{if(typeof window<"u"){const d=T==="storybook"?"/storybook":"/";window.history.pushState({},"",d)}x({viewMode:T})},setShowAgyModal:T=>x({showAgyModal:T}),setShowCmdPalette:T=>x({showCmdPalette:T}),showToast:T=>{x({toast:T}),setTimeout(()=>{O().toast===T&&x({toast:""})},3e3)},fetchTelemetry:async()=>{try{const T=await fetch("/api/telemetry");if(T.ok){const d=await T.json();x({telemetry:d})}}catch{}},triggerAction:async(T,d)=>{const{showToast:E,fetchTelemetry:H}=O();x({actionLoading:!0}),E(d);try{const K=await(await fetch(`/api/action/${T}`,{method:"POST"})).json();E(K.message||"操作已完成"),await H()}catch{E("请求失败,请稍后重试")}finally{x({actionLoading:!1})}},copyCmd:async(T,d)=>{const{showToast:E}=O();try{await navigator.clipboard.writeText(T),E(`已复制「${d}」: ${T}`)}catch{E(T)}},getEffectiveMode:()=>{const{routeMode:T}=O();if(T!=="auto")return T;const d=window.location.hostname;return d.startsWith("192.168.")||d.startsWith("100.")||d==="localhost"?"lan":d.includes(".home.961504.xyz")||window.location.port==="10443"?"home10443":"edge443"}}));typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",()=>{const x=ke.getState();x.theme==="system"&&x.setTheme("system")});/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Qv=x=>x.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),S0=(...x)=>x.filter((O,T,d)=>!!O&&O.trim()!==""&&d.indexOf(O)===T).join(" ").trim();/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Xv={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.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Lv=xl.forwardRef(({color:x="currentColor",size:O=24,strokeWidth:T=2,absoluteStrokeWidth:d,className:E="",children:H,iconNode:J,...K},Q)=>xl.createElement("svg",{ref:Q,...Xv,width:O,height:O,stroke:x,strokeWidth:d?Number(T)*24/Number(O):T,className:S0("lucide",E),...K},[...J.map(([W,A])=>xl.createElement(W,A)),...Array.isArray(H)?H:[H]]));/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Fl=(x,O)=>{const T=xl.forwardRef(({className:d,...E},H)=>xl.createElement(Lv,{ref:H,iconNode:O,className:S0(`lucide-${Qv(x)}`,d),...E}));return T.displayName=`${x}`,T};/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Zv=[["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"}]],p0=Fl("BookOpen",Zv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Vv=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],N0=Fl("Check",Vv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Kv=[["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"}]],Jv=Fl("EyeOff",Kv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const kv=[["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"}]],$v=Fl("Eye",kv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Wv=[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]],y0=Fl("KeyRound",Wv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Fv=[["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:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],Iv=Fl("Layers",Fv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Pv=[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]],ly=Fl("LayoutGrid",Pv);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const ty=[["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"}]],ey=Fl("Lock",ty);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const ay=[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]],uy=Fl("Moon",ay);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const ny=[["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10c.926 0 1.648-.746 1.648-1.688 0-.437-.18-.835-.437-1.125-.29-.289-.438-.652-.438-1.125a1.64 1.64 0 0 1 1.668-1.668h1.996c3.051 0 5.555-2.503 5.555-5.554C21.965 6.012 17.461 2 12 2z",key:"12rzf8"}]],cy=Fl("Palette",ny);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const iy=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M9 21V9",key:"1oto5p"}]],fy=Fl("PanelsTopLeft",iy);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const sy=[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],Cs=Fl("Search",sy);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const oy=[["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"}]],ry=Fl("ShieldCheck",oy);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const dy=[["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"}]],my=Fl("Sparkles",dy);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const hy=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]],vy=Fl("Sun",hy);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const yy=[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]],Ms=Fl("Terminal",yy);/** * @license lucide-react v0.475.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const gy=[["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"}]],by=Fl("User",gy),xy=[{id:"auto",label:"智能路由"},{id:"edge443",label:"443 免端口"},{id:"home10443",label:"10443 家宽"},{id:"lan",label:"LAN 局域网"}],Sy=()=>{const{theme:x,resolvedTheme:O,routeMode:T,viewMode:d,telemetry:E,setTheme:H,toggleTheme:J,setRouteMode:K,setViewMode:Q,setShowAgyModal:W,setShowCmdPalette:A}=ke();return f.jsxs(f.Fragment,{children:[f.jsx("header",{className:"border-b hl-border sticky top-0 z-30 backdrop-blur-md",style:{backgroundColor:"color-mix(in srgb, var(--bg-card) 88%, transparent)"},children:f.jsxs("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 h-14 flex items-center justify-between gap-4",children:[f.jsxs("div",{className:"flex items-center gap-4 shrink-0",children:[f.jsxs("div",{onClick:()=>Q("dashboard"),className:"flex items-center gap-2.5 cursor-pointer",children:[f.jsx("img",{src:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/apple.png",alt:"Mac mini",className:"w-6 h-6 rounded"}),f.jsx("span",{className:"font-semibold text-sm tracking-tight",children:"HomeLab"}),f.jsx("span",{className:"w-2 h-2 rounded-full",style:{backgroundColor:"var(--success)"},title:"全屋 4 节点在线"})]}),f.jsx("div",{className:"h-4 w-[1px] hl-muted"}),f.jsxs("nav",{className:"flex items-center gap-1 text-xs",children:[f.jsxs("button",{onClick:()=>Q("dashboard"),className:"px-2.5 py-1.5 rounded-md font-medium flex items-center gap-1.5 transition-all cursor-pointer",style:d==="dashboard"?{backgroundColor:"var(--bg-muted)",color:"var(--text-main)"}:{color:"var(--text-muted)"},children:[f.jsx(ly,{className:"w-3.5 h-3.5"}),f.jsx("span",{children:"中控台"})]}),f.jsxs("button",{onClick:()=>Q("storybook"),className:"px-2.5 py-1.5 rounded-md font-medium flex items-center gap-1.5 transition-all cursor-pointer",style:d==="storybook"?{backgroundColor:"var(--bg-muted)",color:"var(--text-main)"}:{color:"var(--text-muted)"},children:[f.jsx(p0,{className:"w-3.5 h-3.5"}),f.jsx("span",{children:"Storybook 设计规范"})]})]})]}),f.jsxs("div",{className:"flex items-center gap-2.5 shrink-0 ml-auto",children:[f.jsxs("button",{onClick:()=>A(!0),className:"hl-btn-outline px-3 py-1.5 text-xs flex items-center gap-3 cursor-pointer",title:"按 Cmd+K 唤起全局命令面板",children:[f.jsxs("span",{className:"flex items-center gap-1.5",style:{color:"var(--text-muted)"},children:[f.jsx(Cs,{className:"w-3.5 h-3.5"}),f.jsx("span",{className:"hidden sm:inline",children:"搜索服务或指令..."})]}),f.jsx("kbd",{className:"px-1.5 py-0.5 text-[10px] font-mono-num rounded hl-muted",style:{color:"var(--text-muted)"},children:"⌘K"})]}),f.jsxs("button",{onClick:()=>W(!0),className:"hl-btn-primary px-3 py-1.5 text-xs flex items-center gap-1.5 cursor-pointer",children:[f.jsx(Ms,{className:"w-3.5 h-3.5"}),f.jsx("span",{children:"AGY 终端"})]}),f.jsxs("div",{className:"flex items-center p-0.5 rounded-lg hl-muted border hl-border text-xs",children:[f.jsx("button",{onClick:J,className:"px-2.5 py-1 rounded-md font-medium transition-all flex items-center gap-1.5 cursor-pointer",style:{backgroundColor:"var(--bg-card)",color:"var(--text-main)",boxShadow:"0 1px 2px rgba(0,0,0,0.08)"},title:"点击切换深色 / 浅色主题(默认跟随系统)",children:O==="dark"?f.jsxs(f.Fragment,{children:[f.jsx(uy,{className:"w-3.5 h-3.5"}),f.jsx("span",{children:"深色"})]}):f.jsxs(f.Fragment,{children:[f.jsx(vy,{className:"w-3.5 h-3.5"}),f.jsx("span",{children:"浅色"})]})}),x!=="system"&&f.jsx("button",{onClick:()=>H("system"),className:"px-2 py-1 rounded-md text-[11px] transition-all cursor-pointer",style:{color:"var(--text-muted)"},title:"恢复跟随设备系统深浅色自动切换",children:"自动"})]})]})]})}),d==="dashboard"&&f.jsx("div",{className:"border-b hl-border",style:{backgroundColor:"var(--bg-card)"},children:f.jsxs("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-2.5 flex flex-wrap items-center justify-between gap-3",children:[f.jsxs("div",{className:"flex flex-wrap items-center gap-2 text-xs font-mono-num",children:[f.jsxs("div",{className:"hl-pill px-2.5 py-1 flex items-center gap-2",children:[f.jsx("span",{style:{color:"var(--text-muted)"},children:"M6 CPU"}),f.jsx("div",{className:"w-12 h-1.5 rounded-full hl-muted overflow-hidden",children:f.jsx("div",{className:"h-full hl-bar-fill",style:{width:`${Math.max(5,E.mini.cpu_pct)}%`}})}),f.jsxs("span",{className:"font-medium",children:[E.mini.cpu_pct,"%"]})]}),f.jsxs("div",{className:"hl-pill px-2.5 py-1 flex items-center gap-2",children:[f.jsx("span",{style:{color:"var(--text-muted)"},children:"RAM"}),f.jsx("div",{className:"w-12 h-1.5 rounded-full hl-muted overflow-hidden",children:f.jsx("div",{className:"h-full hl-bar-fill",style:{width:`${Math.max(5,E.mini.mem_pct)}%`}})}),f.jsxs("span",{className:"font-medium",children:[E.mini.mem_used_gb,"G"]})]}),f.jsxs("div",{className:"hl-pill px-2.5 py-1 flex items-center gap-2",children:[f.jsx("span",{style:{color:"var(--text-muted)"},children:"NAS 余量"}),f.jsx("div",{className:"w-12 h-1.5 rounded-full hl-muted overflow-hidden",children:f.jsx("div",{className:"h-full hl-bar-fill-green",style:{width:`${Math.max(5,E.nas.pct)}%`}})}),f.jsxs("span",{className:"font-medium",style:{color:"var(--success)"},children:[E.nas.free_tb," TB"]})]}),f.jsxs("div",{className:"hl-pill px-2.5 py-1 flex items-center gap-1.5",children:[f.jsx("span",{className:"w-1.5 h-1.5 rounded-full",style:{backgroundColor:"var(--success)"}}),f.jsx("span",{style:{color:"var(--text-muted)"},children:"SG 专线"}),f.jsx("span",{className:"font-medium",children:E.network.sg_delay_ms>0?`${E.network.sg_delay_ms}ms`:"直连"})]})]}),f.jsx("div",{className:"flex items-center p-0.5 rounded-lg hl-muted border hl-border text-xs ml-auto",children:xy.map(S=>f.jsx("button",{onClick:()=>K(S.id),className:"px-2.5 py-1 rounded-md font-medium transition-all cursor-pointer",style:T===S.id?{backgroundColor:"var(--bg-card)",color:"var(--text-main)",boxShadow:"0 1px 2px rgba(0,0,0,0.08)"}:{color:"var(--text-muted)"},children:S.label},S.id))})]})})]})},T0=({card:x})=>{const{getEffectiveMode:O,setShowAgyModal:T,triggerAction:d}=ke(),E=O(),H=E==="lan"?x.lanUrl:E==="home10443"?x.homeUrl:x.edgeUrl,J=E==="lan"?"LAN 直连":E==="home10443"?"10443":"443 免端口";return f.jsxs("a",{href:H,target:"_blank",rel:"noopener noreferrer",className:"hl-card hl-card-interactive flex flex-col justify-between overflow-hidden group cursor-pointer",children:[f.jsxs("div",{className:"p-4 sm:p-5 space-y-3",children:[f.jsxs("div",{className:"flex items-start justify-between gap-3",children:[f.jsxs("div",{className:"flex items-center gap-3.5 min-w-0",children:[f.jsx("div",{className:"w-10 h-10 rounded-xl hl-muted border hl-border p-1.5 flex items-center justify-center shrink-0",children:f.jsx("img",{src:x.iconUrl,alt:x.title,className:"w-full h-full object-contain"})}),f.jsxs("div",{className:"min-w-0",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("h3",{className:"text-sm font-semibold truncate group-hover:underline",children:x.title}),f.jsx("span",{className:"w-2 h-2 rounded-full shrink-0",style:{backgroundColor:x.online!==!1?"var(--success)":"#ef4444"}})]}),f.jsx("p",{className:"text-[11px] font-mono-num truncate mt-0.5",style:{color:"var(--text-muted)"},children:x.subtitle})]})]}),x.actionType==="drawer"?f.jsx("button",{onClick:K=>{K.preventDefault(),T(!0)},className:"px-2 py-1 rounded-md text-[11px] font-medium shrink-0 transition-opacity hover:opacity-80 cursor-pointer",style:{backgroundColor:"var(--accent-soft)",color:"var(--accent)"},children:"页内终端"}):x.actionType==="backup"?f.jsx("button",{onClick:K=>{K.preventDefault(),d("backup_nas","正在打包备份至极空间 Z4...")},className:"px-2 py-1 rounded-md text-[11px] font-medium shrink-0 transition-opacity hover:opacity-80 cursor-pointer",style:{backgroundColor:"var(--success-soft)",color:"var(--success)"},children:"立即备份"}):f.jsx("span",{className:"text-xs font-mono-num px-2 py-0.5 rounded hl-muted shrink-0",style:{color:"var(--text-muted)"},children:J})]}),f.jsx("p",{className:"text-xs leading-relaxed line-clamp-2",style:{color:"var(--text-muted)"},children:x.desc})]}),f.jsx("div",{className:"hl-widget-footer grid grid-cols-3 divide-x hl-border text-center",children:x.stats.map((K,Q)=>f.jsxs("div",{className:"py-2.5 px-2 flex flex-col items-center justify-center",children:[f.jsx("span",{className:"text-[10px] uppercase tracking-wider truncate max-w-full",style:{color:"var(--text-subtle)"},children:K.label}),f.jsx("span",{className:"text-xs font-semibold font-mono-num mt-0.5 truncate max-w-full",style:{color:K.highlight?"var(--success)":"var(--text-main)"},children:K.value})]},Q))})]})},py=[{label:"SSH 连接 Mac mini",cmd:"ssh mini"},{label:"终端接力 AGY 会话",cmd:'ssh mini -t "tmux attach -t agy"'},{label:"SSH 连接新加坡 Azure",cmd:"ssh azure"},{label:"SSH 连接小米主路由",cmd:"ssh root@192.168.31.1"}],_0=()=>{const{copyCmd:x,triggerAction:O}=ke();return f.jsxs("section",{className:"space-y-3 pt-1",children:[f.jsxs("div",{className:"flex items-center justify-between px-0.5",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("h2",{className:"text-xs font-semibold uppercase tracking-wider",style:{color:"var(--text-muted)"},children:"终端快捷指令与备用直连书签"}),f.jsx("span",{className:"text-[11px] font-mono-num",style:{color:"var(--text-subtle)"},children:"· 点击指令即复制"})]}),f.jsxs("div",{className:"flex items-center gap-3 text-xs",children:[f.jsx("button",{onClick:()=>O("refresh_ddns","正在同步 Cloudflare DDNS..."),className:"hover:underline font-medium cursor-pointer",style:{color:"var(--accent)"},children:"刷新 DDNS 解析"}),f.jsx("button",{onClick:()=>O("mount_nas","正在巡检极空间 20TB SMB 挂载..."),className:"hover:underline font-medium cursor-pointer",style:{color:"var(--accent)"},children:"巡检极空间挂载"})]})]}),f.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-3",children:py.map(T=>f.jsxs("button",{onClick:()=>x(T.cmd,T.label),className:"hl-card hl-card-interactive px-4 py-3 text-left flex items-center justify-between gap-2 cursor-pointer",children:[f.jsxs("div",{className:"min-w-0",children:[f.jsx("div",{className:"text-xs font-semibold",children:T.label}),f.jsx("div",{className:"text-[11px] font-mono-num truncate mt-0.5",style:{color:"var(--accent)"},children:T.cmd})]}),f.jsx("span",{className:"text-[10px] font-mono-num px-1.5 py-0.5 rounded hl-muted shrink-0",style:{color:"var(--text-muted)"},children:"COPY"})]},T.cmd))})]})},Ny=()=>{const{showCmdPalette:x,setShowCmdPalette:O,setShowAgyModal:T,setTheme:d,triggerAction:E,copyCmd:H,getEffectiveMode:J}=ke(),[K,Q]=xl.useState(""),W=xl.useRef(null);xl.useEffect(()=>{x&&(Q(""),setTimeout(()=>{var w;return(w=W.current)==null?void 0:w.focus()},20))},[x]);const A=xl.useMemo(()=>{const w=J(),U=(vl,P,jl)=>w==="lan"?jl:w==="home10443"?P:vl;return[{id:"open-agy-drawer",title:"在页内唤起 AGY 云端终端",hint:"tmux attach -t agy",type:"终端",run:()=>T(!0)},{id:"open-agy",title:"新窗口打开 AGY 云端工作台",hint:"https://agy.961504.xyz",type:"跳转",run:()=>window.open(U("https://agy.961504.xyz","https://agy.home.961504.xyz:10443","http://192.168.31.164:7681"),"_blank")},{id:"open-z4",title:"打开 极空间 Z4 私有云 (20TB)",hint:"192.168.31.185:5055",type:"跳转",run:()=>window.open(U("https://z4.home.961504.xyz:10443","https://z4.home.961504.xyz:10443","http://192.168.31.185:5055"),"_blank")},{id:"open-vw",title:"打开 Vaultwarden 密码保险箱",hint:"https://vw.961504.xyz",type:"跳转",run:()=>window.open(U("https://vw.961504.xyz","https://vw.home.961504.xyz:10443","http://192.168.31.164:8222"),"_blank")},{id:"open-clash",title:"打开 Mihomo 路由分流面板",hint:"192.168.31.1:9999",type:"跳转",run:()=>window.open(U("https://clash.home.961504.xyz:10443/ui/","https://clash.home.961504.xyz:10443/ui/","http://192.168.31.1:9999/ui/"),"_blank")},{id:"act-backup",title:"立即打包备份核心数据至极空间 Z4",hint:"backup-to-nas.sh",type:"运维",run:()=>E("backup_nas","正在打包备份至极空间 Z4...")},{id:"act-ddns",title:"立即刷新 Cloudflare DDNS 解析",hint:"cloudflare-ddns.sh",type:"运维",run:()=>E("refresh_ddns","正在同步 Cloudflare DDNS...")},{id:"ssh-mini",title:"复制 SSH 连接 Mac mini 指令",hint:"ssh mini",type:"SSH",run:()=>H("ssh mini","SSH Mac mini")},{id:"ssh-agy",title:"复制 终端接力 AGY 会话指令",hint:'ssh mini -t "tmux attach -t agy"',type:"SSH",run:()=>H('ssh mini -t "tmux attach -t agy"',"接力 AGY")},{id:"theme-system",title:"主题模式: 跟随设备系统深浅色自动切换",hint:"system",type:"主题",run:()=>d("system")},{id:"theme-light",title:"切换主题: 浅色纯净 (Light)",hint:"light",type:"主题",run:()=>d("light")},{id:"theme-dark",title:"切换主题: 深色极客 (Dark)",hint:"dark",type:"主题",run:()=>d("dark")}]},[J,T,d,E,H]),S=xl.useMemo(()=>{const w=K.trim().toLowerCase();return w?A.filter(U=>U.title.toLowerCase().includes(w)||U.hint.toLowerCase().includes(w)):A},[K,A]);if(!x)return null;const D=w=>{O(!1),w.run()};return f.jsx("div",{onClick:w=>{w.target===w.currentTarget&&O(!1)},className:"fixed inset-0 z-50 bg-black/60 backdrop-blur-sm flex items-start justify-center pt-20 px-4",children:f.jsxs("div",{className:"w-full max-w-xl hl-card overflow-hidden shadow-2xl",children:[f.jsxs("div",{className:"px-4 py-3 border-b hl-border flex items-center gap-3",children:[f.jsx(Cs,{className:"w-4 h-4",style:{color:"var(--text-muted)"}}),f.jsx("input",{ref:W,value:K,onChange:w=>Q(w.target.value),type:"text",placeholder:"输入服务名称、SSH 指令、路由模式或主题...",className:"w-full bg-transparent text-sm outline-none",onKeyDown:w=>{w.key==="Escape"&&O(!1),w.key==="Enter"&&S.length>0&&D(S[0])}}),f.jsx("kbd",{className:"px-1.5 py-0.5 text-[10px] font-mono-num rounded hl-muted",style:{color:"var(--text-muted)"},children:"ESC"})]}),f.jsxs("div",{className:"max-h-80 overflow-y-auto p-2 text-xs",children:[f.jsx("div",{className:"px-2.5 py-1 text-[10px] font-semibold uppercase tracking-wider",style:{color:"var(--text-subtle)"},children:"快速操作与服务直达"}),S.map(w=>f.jsxs("button",{onClick:()=>D(w),className:"w-full px-3 py-2 rounded-lg text-left flex items-center justify-between transition-colors cursor-pointer",onMouseEnter:U=>{U.currentTarget.style.backgroundColor="var(--bg-muted)"},onMouseLeave:U=>{U.currentTarget.style.backgroundColor="transparent"},children:[f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx("span",{className:"font-medium",children:w.title}),f.jsx("span",{className:"font-mono-num text-[11px]",style:{color:"var(--text-muted)"},children:w.hint})]}),f.jsx("span",{className:"text-[10px] font-mono-num px-1.5 py-0.5 rounded hl-muted",style:{color:"var(--text-muted)"},children:w.type})]},w.id))]})]})})},Ds=({targetUrl:x="https://agy.961504.xyz",onSuccess:O,onCancel:T,embedded:d=!1})=>{const[E,H]=xl.useState("ixvii0iv"),[J,K]=xl.useState(""),[Q,W]=xl.useState(!1),[A,S]=xl.useState(!0),[D,w]=xl.useState(!1),[U,vl]=xl.useState(null),P=async jl=>{if(jl.preventDefault(),!E.trim()||!J){vl("请输入用户名与访问密钥");return}w(!0),vl(null);try{const Bl=await fetch("/api/auth/login",{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({username:E.trim(),password:J,remember:A})}),I=await Bl.json();Bl.ok&&I.ok?O==null||O():vl(I.message||"认证未通过,请检查密码")}catch{vl("网络请求异常,请稍后重试")}finally{w(!1)}};return f.jsxs("div",{className:`w-full max-w-md hl-card p-6 space-y-5 ${d?"":"shadow-2xl"}`,children:[f.jsx("div",{className:"flex items-start justify-between gap-3 border-b hl-border pb-4",children:f.jsxs("div",{className:"flex items-center gap-3",children:[f.jsx("div",{className:"w-10 h-10 rounded-xl flex items-center justify-center border hl-border shrink-0",style:{backgroundColor:"var(--accent-soft)",color:"var(--accent)"},children:f.jsx(ry,{className:"w-5 h-5"})}),f.jsxs("div",{children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("h3",{className:"text-sm font-bold tracking-tight",children:"HomeLab 统一安全通行证"}),f.jsx("span",{className:"text-[10px] font-mono-num px-1.5 py-0.5 rounded font-semibold",style:{backgroundColor:"var(--success-soft)",color:"var(--success)"},children:"SSO 2.0"})]}),f.jsx("p",{className:"text-xs font-mono-num mt-0.5 truncate max-w-[260px]",style:{color:"var(--text-muted)"},children:x})]})]})}),f.jsxs("form",{onSubmit:P,className:"space-y-4",children:[f.jsxs("div",{className:"space-y-1.5",children:[f.jsx("label",{className:"block text-xs font-semibold",style:{color:"var(--text-muted)"},children:"管理员账号 (Username)"}),f.jsxs("div",{className:"hl-input-group",children:[f.jsx(by,{className:"w-4 h-4 shrink-0",style:{color:"var(--text-subtle)"}}),f.jsx("input",{type:"text",autoComplete:"username",value:E,onChange:jl=>H(jl.target.value),placeholder:"输入管理员账号 (如 ixvii0iv)",className:"font-mono-num"})]})]}),f.jsxs("div",{className:"space-y-1.5",children:[f.jsxs("div",{className:"flex items-center justify-between",children:[f.jsx("label",{className:"block text-xs font-semibold",style:{color:"var(--text-muted)"},children:"访问通行密钥 (Access Key)"}),f.jsx("span",{className:"text-[10px] font-mono-num",style:{color:"var(--text-subtle)"},children:"与 Mac mini 密码一致"})]}),f.jsxs("div",{className:"hl-input-group",children:[f.jsx(ey,{className:"w-4 h-4 shrink-0",style:{color:"var(--text-subtle)"}}),f.jsx("input",{type:Q?"text":"password",autoComplete:"current-password",autoFocus:!0,value:J,onChange:jl=>K(jl.target.value),placeholder:"输入访问密钥...",className:"font-mono-num"}),f.jsx("button",{type:"button",onClick:()=>W(!Q),className:"p-1 rounded hover:opacity-80 cursor-pointer",style:{color:"var(--text-muted)"},title:Q?"隐藏密码":"显示密码",children:Q?f.jsx(Jv,{className:"w-3.5 h-3.5"}):f.jsx($v,{className:"w-3.5 h-3.5"})})]})]}),f.jsx("div",{className:"flex items-center justify-between pt-0.5",children:f.jsxs("button",{type:"button",onClick:()=>S(!A),className:"flex items-center gap-2 text-xs cursor-pointer select-none",style:{color:"var(--text-muted)"},children:[f.jsx("span",{className:"w-4 h-4 rounded flex items-center justify-center border transition-colors",style:A?{backgroundColor:"var(--accent)",borderColor:"var(--accent)",color:"#ffffff"}:{backgroundColor:"var(--bg-muted)",borderColor:"var(--border-color)"},children:A&&f.jsx(N0,{className:"w-3 h-3"})}),f.jsx("span",{children:"在此设备保持 30 天免密通行 (*.961504.xyz)"})]})}),U&&f.jsx("div",{className:"px-3 py-2 rounded-lg text-xs font-medium border",style:{backgroundColor:"rgba(239, 68, 68, 0.1)",borderColor:"rgba(239, 68, 68, 0.3)",color:"#ef4444"},children:U}),f.jsxs("div",{className:"flex items-center justify-end gap-2.5 pt-2",children:[T&&f.jsx("button",{type:"button",onClick:T,className:"hl-btn-outline px-4 py-2 text-xs font-medium cursor-pointer",children:"取消"}),f.jsxs("button",{type:"submit",disabled:D,className:"hl-btn-primary px-5 py-2 text-xs font-semibold flex items-center gap-2 cursor-pointer",children:[f.jsx(Ms,{className:"w-3.5 h-3.5"}),f.jsx("span",{children:D?"正在验证签名...":"解锁并进入工作台"})]})]})]})]})},Ty=()=>{const{showAgyModal:x,setShowAgyModal:O,getEffectiveMode:T}=ke(),[d,E]=xl.useState(!1),[H,J]=xl.useState(!1),K=T(),Q=K==="lan"?"http://192.168.31.164:7681":K==="home10443"?"https://agy.home.961504.xyz:10443":"https://agy.961504.xyz";return xl.useEffect(()=>{if(x){if(K==="lan"){J(!0),E(!0);return}E(!1),fetch("/api/auth/status",{credentials:"include"}).then(W=>W.json()).then(W=>{J(!!W.authenticated),E(!0)}).catch(()=>{J(!1),E(!0)})}},[x,K]),x?f.jsx("div",{className:"fixed inset-0 z-50 bg-black/75 backdrop-blur-sm flex items-center justify-center p-3 sm:p-6",children:f.jsxs("div",{className:"w-full h-full max-w-6xl hl-card flex flex-col overflow-hidden shadow-2xl",children:[f.jsxs("div",{className:"px-4 py-2.5 border-b hl-border flex items-center justify-between hl-muted",children:[f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx("img",{src:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/google-gemini.png",alt:"AGY",className:"w-4 h-4"}),f.jsx("span",{className:"text-xs font-mono-num font-medium",children:"AGY 云端工作台 · tmux 持久会话 (关窗不断连)"})]}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("a",{href:Q,target:"_blank",rel:"noopener noreferrer",className:"hl-btn-outline px-2.5 py-1 text-xs font-mono-num",children:"新标签页全屏 ↗"}),f.jsx("button",{onClick:()=>O(!1),className:"hl-btn-primary px-3 py-1 text-xs cursor-pointer",children:"收起终端"})]})]}),d?H?f.jsx("iframe",{src:Q,title:"AGY Cloud Workbench",className:"w-full flex-1 bg-black border-0"}):f.jsx("div",{className:"flex-1 flex items-center justify-center p-4",style:{backgroundColor:"var(--bg-page)"},children:f.jsx(Ds,{targetUrl:Q,onSuccess:()=>J(!0),onCancel:()=>O(!1)})}):f.jsx("div",{className:"flex-1 flex items-center justify-center text-xs font-mono-num",style:{color:"var(--text-muted)"},children:"正在校验 HomeLab SSO 通行证..."})]})}):null},_y={light:{id:"light",name:"Shadcn Clean Light (浅色纯净)",description:"对标 Apple / Stripe / Linear 浅色日光模式,高对比深灰文字配纯净白卡片与冷灰微边框。",tokens:{"--bg-page":"#f8fafc","--bg-card":"#ffffff","--bg-widget":"#f8fafc","--bg-muted":"#f1f5f9","--bg-hover":"#ffffff","--text-main":"#0f172a","--text-muted":"#64748b","--text-subtle":"#94a3b8","--border-color":"#e2e8f0","--border-hover":"#cbd5e1","--primary":"#0f172a","--primary-fg":"#ffffff","--accent":"#2563eb","--accent-soft":"rgba(37, 99, 235, 0.08)","--success":"#10b981","--success-soft":"rgba(16, 185, 129, 0.10)"}},dark:{id:"dark",name:"Catppuccin / Linear Dark (深色极客)",description:"融合 Catppuccin Mocha 与 Linear 暗黑规范,柔和护眼的深邃蓝黑基底配高辨识度状态色。",tokens:{"--bg-page":"#11111b","--bg-card":"#1e1e2e","--bg-widget":"#181825","--bg-muted":"#313244","--bg-hover":"#242438","--text-main":"#cdd6f4","--text-muted":"#a6adc8","--text-subtle":"#6c7086","--border-color":"#313244","--border-hover":"#45475a","--primary":"#cba6f7","--primary-fg":"#11111b","--accent":"#89b4fa","--accent-soft":"rgba(137, 180, 250, 0.15)","--success":"#a6e3a1","--success-soft":"rgba(166, 227, 161, 0.15)"}}},Gc={"homepage-3col":{id:"homepage-3col",name:"Homepage 经典三列矩阵 (3-Column Grid)",description:"gethomepage.dev 标志性对称 3 列分组卡片,底部内嵌 3 格实时遥测单元。",gridClass:"grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4"},"bento-split":{id:"bento-split",name:"Shadcn 双列宽屏卡片 (2-Column Wide Bento)",description:"适合大字号阅读的 2 列宽体卡片布局,留白更充裕。",gridClass:"grid-cols-1 lg:grid-cols-2 gap-5"},"compact-2col":{id:"compact-2col",name:"高密度四列紧凑矩阵 (4-Column Dense)",description:"适合超宽显示器的一屏高密度 4 列布局。",gridClass:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-3.5"}},Ey=()=>{const[x,O]=xl.useState("form-inputs"),{theme:T,resolvedTheme:d,layoutPreset:E,setTheme:H,setLayoutPreset:J,setViewMode:K,telemetry:Q,showToast:W}=ke(),[A,S]=xl.useState(!0),[D,w]=xl.useState("drawer"),[U,vl]=xl.useState(""),[P,jl]=xl.useState("192.168.31.164"),Bl=[{id:"layout-architecture",group:"FOUNDATIONS / 架构与布局",title:"01. AppShell 双层顶栏与网格布局",icon:f.jsx(fy,{className:"w-3.5 h-3.5"})},{id:"theme-tokens",group:"FOUNDATIONS / 架构与布局",title:"02. 双主题色板与自动切换规范",icon:f.jsx(cy,{className:"w-3.5 h-3.5"})},{id:"form-inputs",group:"COMPONENTS / 核心组件",title:"03. Input & AuthGate 输入框与登录弹窗",icon:f.jsx(y0,{className:"w-3.5 h-3.5"})},{id:"service-card",group:"COMPONENTS / 核心组件",title:"04. ServiceCard 内联遥测卡片",icon:f.jsx(Iv,{className:"w-3.5 h-3.5"})},{id:"ssh-shelf",group:"COMPONENTS / 核心组件",title:"05. SshShelf 快捷指令栏",icon:f.jsx(Ms,{className:"w-3.5 h-3.5"})}];return f.jsx("div",{className:"flex-1 max-w-7xl w-full mx-auto px-4 sm:px-6 lg:px-8 py-6",children:f.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-4 gap-6 items-start",children:[f.jsxs("aside",{className:"hl-card p-4 space-y-4 lg:sticky lg:top-20",children:[f.jsxs("div",{className:"flex items-center justify-between border-b hl-border pb-3",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(p0,{className:"w-4 h-4",style:{color:"var(--accent)"}}),f.jsx("span",{className:"text-xs font-bold uppercase tracking-wider",children:"Storybook 组件库"})]}),f.jsx("span",{className:"text-[10px] font-mono-num px-1.5 py-0.5 rounded hl-muted",children:"v3.2"})]}),f.jsx("div",{className:"space-y-1",children:Bl.map(I=>f.jsxs("button",{onClick:()=>O(I.id),className:"w-full px-3 py-2 rounded-lg text-left text-xs font-medium flex items-center gap-2.5 transition-all cursor-pointer",style:x===I.id?{backgroundColor:"var(--accent-soft)",color:"var(--accent)"}:{color:"var(--text-muted)"},children:[I.icon,f.jsx("span",{className:"truncate",children:I.title})]},I.id))}),f.jsxs("div",{className:"pt-3 border-t hl-border space-y-2 text-xs",children:[f.jsx("div",{className:"text-[11px] font-semibold",style:{color:"var(--text-muted)"},children:"全局外观状态预览"}),f.jsx("div",{className:"grid grid-cols-3 gap-1 p-1 rounded-lg hl-muted border hl-border",children:["system","light","dark"].map(I=>f.jsx("button",{onClick:()=>H(I),className:"py-1 rounded text-[11px] font-medium cursor-pointer",style:T===I?{backgroundColor:"var(--bg-card)",color:"var(--text-main)"}:{color:"var(--text-muted)"},children:I==="system"?"自动":I==="light"?"浅色":"深色"},I))}),f.jsx("button",{onClick:()=>K("dashboard"),className:"w-full hl-btn-primary py-2 text-xs text-center mt-2 cursor-pointer",children:"返回中控台主页"})]})]}),f.jsxs("div",{className:"lg:col-span-3 space-y-6",children:[x==="layout-architecture"&&f.jsx("div",{className:"space-y-6",children:f.jsxs("div",{className:"hl-card p-6 space-y-4",children:[f.jsx("div",{className:"flex items-center justify-between border-b hl-border pb-4",children:f.jsxs("div",{children:[f.jsx("span",{className:"text-[11px] font-mono-num uppercase tracking-wider",style:{color:"var(--accent)"},children:"Foundations / AppShell Layout"}),f.jsx("h2",{className:"text-lg font-bold mt-0.5",children:"标准双层顶栏架构 (Two-Tier AppShell) & 响应式网格切换"})]})}),f.jsxs("p",{className:"text-xs leading-relaxed",style:{color:"var(--text-muted)"},children:["参考 ",f.jsx("strong",{children:"Vercel Geist / shadcn/ui Dashboard-01 / GitHub AppShell"})," ","标准规范,将原本容易挤压折行的单层顶栏拆分为职责清晰的双层结构:"]}),f.jsxs("div",{className:"p-4 rounded-xl hl-muted border hl-border space-y-2.5 font-mono-num text-xs",children:[f.jsxs("div",{className:"p-3 rounded-lg hl-card flex items-center justify-between",children:[f.jsx("span",{children:"[左] 🍎 HomeLab · 导航切换 (中控台 / Storybook)"}),f.jsx("span",{style:{color:"var(--accent)"},children:"[最右固定] 🔍 搜索 ⌘K · >_ AGY 终端 · ☀️/🌙 主题切换"})]}),f.jsxs("div",{className:"p-3 rounded-lg hl-card flex items-center justify-between",children:[f.jsx("span",{style:{color:"var(--success)"},children:"[左] 实时硬件遥测条 (M6 CPU · RAM · Z4 20TB · SG 专线)"}),f.jsx("span",{children:"[右对齐] 路由模式切换器 (智能路由 / 443 / 10443 / LAN)"})]})]}),f.jsxs("div",{className:"pt-2 space-y-3",children:[f.jsx("div",{className:"text-xs font-semibold",children:"选择主页卡片网格布局预设(点击立即应用到主页):"}),f.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-3.5",children:Object.keys(Gc).map(I=>{const il=Gc[I],Il=E===I;return f.jsxs("div",{onClick:()=>J(I),className:"hl-card hl-card-interactive p-4 cursor-pointer space-y-2",style:Il?{borderColor:"var(--accent)"}:{},children:[f.jsxs("div",{className:"flex items-center justify-between",children:[f.jsx("span",{className:"text-xs font-bold",children:il.name}),Il&&f.jsx("span",{className:"w-4 h-4 rounded-full flex items-center justify-center",style:{backgroundColor:"var(--accent)",color:"#fff"},children:f.jsx(N0,{className:"w-2.5 h-2.5"})})]}),f.jsx("p",{className:"text-[11px]",style:{color:"var(--text-muted)"},children:il.description}),f.jsx("code",{className:"text-[10px] font-mono-num block pt-1",style:{color:"var(--accent)"},children:il.gridClass})]},I)})})]})]})}),x==="theme-tokens"&&f.jsxs("div",{className:"hl-card p-6 space-y-6",children:[f.jsxs("div",{className:"border-b hl-border pb-4 flex items-center justify-between",children:[f.jsxs("div",{children:[f.jsx("span",{className:"text-[11px] font-mono-num uppercase tracking-wider",style:{color:"var(--accent)"},children:"Foundations / Color System"}),f.jsxs("h2",{className:"text-lg font-bold mt-0.5",children:["主流双主题色板规范(当前生效:",d==="dark"?"深色极客":"浅色纯净",")"]})]}),f.jsxs("span",{className:"text-xs font-mono-num px-2.5 py-1 rounded hl-muted",children:["模式: ",T==="system"?"跟随设备自动切换":"手动锁定"]})]}),f.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-5",children:["light","dark"].map(I=>{const il=_y[I];return f.jsxs("div",{className:"rounded-xl p-5 space-y-4 border",style:{backgroundColor:il.tokens["--bg-page"],color:il.tokens["--text-main"],borderColor:il.tokens["--border-color"]},children:[f.jsxs("div",{className:"flex items-center justify-between border-b pb-3",style:{borderColor:il.tokens["--border-color"]},children:[f.jsxs("div",{children:[f.jsx("div",{className:"text-sm font-bold",children:il.name}),f.jsx("div",{className:"text-xs mt-0.5",style:{color:il.tokens["--text-muted"]},children:il.description})]}),f.jsx("button",{onClick:()=>H(I),className:"px-2.5 py-1 rounded-md text-xs font-mono-num font-semibold cursor-pointer",style:{backgroundColor:il.tokens["--primary"],color:il.tokens["--primary-fg"]},children:"预览此主题"})]}),f.jsx("div",{className:"grid grid-cols-2 gap-2",children:Object.entries(il.tokens).map(([Il,Pl])=>f.jsxs("div",{className:"p-2 rounded-lg border flex items-center gap-2",style:{backgroundColor:il.tokens["--bg-card"],borderColor:il.tokens["--border-color"]},children:[f.jsx("span",{className:"w-5 h-5 rounded border shrink-0",style:{backgroundColor:Pl,borderColor:il.tokens["--border-hover"]}}),f.jsxs("div",{className:"min-w-0",children:[f.jsx("div",{className:"text-[10px] font-mono-num font-semibold truncate",children:Il}),f.jsx("div",{className:"text-[10px] font-mono-num truncate",style:{color:il.tokens["--text-muted"]},children:Pl})]})]},Il))})]},il.id)})})]}),x==="form-inputs"&&f.jsxs("div",{className:"hl-card p-6 space-y-6",children:[f.jsxs("div",{className:"border-b hl-border pb-4 flex items-center justify-between",children:[f.jsxs("div",{children:[f.jsx("span",{className:"text-[11px] font-mono-num uppercase tracking-wider",style:{color:"var(--accent)"},children:"Components / Form Controls & SSO Auth Gate"}),f.jsx("h2",{className:"text-lg font-bold mt-0.5",children:"统一自定义输入框 (`.hl-input`) 与 SSO 认证卡片(彻底禁用浏览器原生弹窗)"})]}),f.jsx(y0,{className:"w-4 h-4",style:{color:"var(--accent)"}})]}),f.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6 items-start",children:[f.jsxs("div",{className:"p-5 rounded-xl hl-muted border hl-border space-y-4",children:[f.jsx("div",{className:"text-xs font-bold uppercase tracking-wider",style:{color:"var(--text-muted)"},children:"1. 基础表单输入组件规范 (`.hl-input` / `.hl-input-group`)"}),f.jsxs("div",{className:"space-y-1.5",children:[f.jsx("label",{className:"block text-xs font-medium",style:{color:"var(--text-muted)"},children:"带前缀图标与快捷键提示的搜索框"}),f.jsxs("div",{className:"hl-input-group",children:[f.jsx(Cs,{className:"w-4 h-4 shrink-0",style:{color:"var(--text-subtle)"}}),f.jsx("input",{type:"text",value:U,onChange:I=>vl(I.target.value),placeholder:"搜索服务、SSH 指令或节点..."}),f.jsx("kbd",{className:"px-1.5 py-0.5 text-[10px] font-mono-num rounded hl-card border hl-border",style:{color:"var(--text-muted)"},children:"⌘K"})]})]}),f.jsxs("div",{className:"space-y-1.5",children:[f.jsx("label",{className:"block text-xs font-medium",style:{color:"var(--text-muted)"},children:"等宽字体 IP / 域名输入框 (`.hl-input .font-mono-num`)"}),f.jsx("input",{type:"text",value:P,onChange:I=>jl(I.target.value),className:"hl-input font-mono-num",placeholder:"192.168.31.164"})]}),f.jsxs("div",{className:"p-3 rounded-lg hl-card text-[11px] leading-relaxed space-y-1",style:{color:"var(--text-muted)"},children:[f.jsx("div",{className:"font-semibold",style:{color:"var(--text-main)"},children:"为什么不再出现浏览器默认输入框和弹窗?"}),f.jsxs("p",{children:["1. 全局 CSS 已设置 ",f.jsx("code",{children:"appearance: none"})," 与自定义聚焦光环"," ",f.jsx("code",{children:"box-shadow: 0 0 0 3px var(--accent-soft)"}),",并覆盖了 Chrome 自动填充的黄色背景。"]}),f.jsxs("p",{children:["2. Caddy 网关已移除 ",f.jsx("code",{children:"basicauth"}),",改用 ",f.jsx("code",{children:"forward_auth"})," 对接右侧的"," ",f.jsx("strong",{children:"HomeLab SSO 2.0 统一认证卡片"}),",一次登录全域名 30 天免密通行。"]})]})]}),f.jsx("div",{className:"flex flex-col items-center",children:f.jsx(Ds,{embedded:!0,targetUrl:"https://agy.961504.xyz",onSuccess:()=>W("SSO 认证成功!已签发 30 天全域名通行 Cookie")})})]})]}),x==="service-card"&&f.jsxs("div",{className:"hl-card p-6 space-y-6",children:[f.jsxs("div",{className:"border-b hl-border pb-4 flex items-center justify-between",children:[f.jsxs("div",{children:[f.jsx("span",{className:"text-[11px] font-mono-num uppercase tracking-wider",style:{color:"var(--accent)"},children:"Components / ServiceCard"}),f.jsx("h2",{className:"text-lg font-bold mt-0.5",children:"三段式内联遥测卡片 (ServiceCard Interactive Story)"})]}),f.jsx(my,{className:"w-4 h-4",style:{color:"var(--accent)"}})]}),f.jsxs("div",{className:"p-4 rounded-xl hl-muted border hl-border flex flex-wrap items-center gap-6 text-xs",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("span",{className:"font-semibold",children:"在线状态 (online):"}),f.jsx("button",{onClick:()=>S(!A),className:"px-2.5 py-1 rounded hl-card font-mono-num cursor-pointer",children:A?"true (绿灯)":"false (离线红灯)"})]}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("span",{className:"font-semibold",children:"右上角动作按钮 (actionType):"}),["drawer","backup",void 0].map((I,il)=>f.jsx("button",{onClick:()=>w(I),className:"px-2.5 py-1 rounded hl-card font-mono-num cursor-pointer",style:D===I?{borderColor:"var(--accent)"}:{},children:I||"route-badge"},il))]})]}),f.jsx("div",{className:"max-w-md mx-auto py-4",children:f.jsx(T0,{card:{id:"agy",title:"AGY 云端工作台",subtitle:"agy.961504.xyz · ttyd + tmux",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/google-gemini.png",online:A,actionType:D,desc:"M6 Mac mini 上的 24 小时常驻 AI 编程终端,已同步 Google 登录态并锁定新加坡出口,关掉网页后台继续运行。",edgeUrl:"https://agy.961504.xyz",homeUrl:"https://agy.home.961504.xyz:10443",lanUrl:"http://192.168.31.164:7681",stats:[{label:"M6 CPU 负载",value:`${Q.mini.cpu_pct}%`},{label:"已用内存",value:`${Q.mini.mem_used_gb} / 24 GB`},{label:"tmux 会话",value:"常驻运行中",highlight:!0}]}})})]}),x==="ssh-shelf"&&f.jsxs("div",{className:"hl-card p-6 space-y-6",children:[f.jsxs("div",{className:"border-b hl-border pb-4",children:[f.jsx("span",{className:"text-[11px] font-mono-num uppercase tracking-wider",style:{color:"var(--accent)"},children:"Components / SshShelf"}),f.jsx("h2",{className:"text-lg font-bold mt-0.5",children:"底部 SSH 快捷复制与运维操作栏"})]}),f.jsx(_0,{})]})]})]})})},zy=()=>{var w;const{telemetry:x,toast:O,viewMode:T,layoutPreset:d,fetchTelemetry:E,setShowCmdPalette:H,getEffectiveMode:J,routeMode:K}=ke(),[Q,W]=xl.useState(()=>typeof window>"u"?null:new URLSearchParams(window.location.search).get("auth_redirect"));xl.useEffect(()=>{E();const U=setInterval(E,3e3),vl=P=>{(P.metaKey||P.ctrlKey)&&P.key.toLowerCase()==="k"&&(P.preventDefault(),H(!0))};return window.addEventListener("keydown",vl),()=>{clearInterval(U),window.removeEventListener("keydown",vl)}},[E,H]);const A=xl.useMemo(()=>{const U=J();return U==="lan"?"LAN 局域网极速直连 (192.168.31.x)":U==="home10443"?"10443 家宽公网 HTTPS 直连":"443 免端口 HTTPS 直达 (*.961504.xyz)"},[J,K]),S=((w=Gc[d])==null?void 0:w.gridClass)||Gc["homepage-3col"].gridClass,D=xl.useMemo(()=>{const U=x;return[{title:"核心工作台与私有云存储",subtitle:"Core Workbench & Storage",showRouteHint:!0,items:[{id:"agy",title:"AGY 云端工作台",subtitle:"agy.961504.xyz · ttyd + tmux",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/google-gemini.png",online:U.services.agy,actionType:"drawer",desc:"M6 Mac mini 上的 24 小时常驻 AI 编程终端,已同步 Google 登录态并锁定新加坡出口,关掉网页后台继续运行。",edgeUrl:"https://agy.961504.xyz",homeUrl:"https://agy.home.961504.xyz:10443",lanUrl:"http://192.168.31.164:7681",stats:[{label:"M6 CPU 负载",value:`${U.mini.cpu_pct}%`},{label:"已用内存",value:`${U.mini.mem_used_gb} / 24 GB`},{label:"tmux 会话",value:U.mini.agy_tmux?"常驻运行中":"待机",highlight:!0}]},{id:"zspace",title:"极空间 Z4 私有云",subtitle:"192.168.31.185 · 20TB RAID 存储池",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/synology-drive.png",online:U.services.nas,desc:"家庭 20TB 大容量存储中心、极影视蓝光影院与手机相册备份,已自动 SMB 挂载至 Mac mini ~/nas。",edgeUrl:"https://z4.home.961504.xyz:10443",homeUrl:"https://z4.home.961504.xyz:10443",lanUrl:"http://192.168.31.185:5055",stats:[{label:"剩余可用",value:`${U.nas.free_tb} TB`,highlight:!0},{label:"已用容量",value:`${U.nas.used_tb} TB (${U.nas.pct}%)`},{label:"SMB 挂载",value:U.nas.mounted?"~/nas 已挂载":"重连中"}]},{id:"vaultwarden",title:"Vaultwarden 密码保险箱",subtitle:"vw.961504.xyz · Bitwarden 兼容",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/vaultwarden.png",online:U.services.vaultwarden,actionType:"backup",desc:"自托管全平台加密密码库,支持 iOS / Android / 浏览器插件自动填充,每天凌晨 03:30 自动打包灾备至极空间。",edgeUrl:"https://vw.961504.xyz",homeUrl:"https://vw.home.961504.xyz:10443",lanUrl:"http://192.168.31.164:8222",stats:[{label:"容器状态",value:"Healthy",highlight:!0},{label:"最近极空间灾备",value:U.nas.latest_backup},{label:"Mac SSD 占用",value:`${U.mini.disk_pct}%`}]}]},{title:"网络网关、AI 专线与外部哨兵",subtitle:"Network Gateway & Cloud Edge",showRouteHint:!1,items:[{id:"clash",title:"Mihomo 路由分流面板",subtitle:"192.168.31.1:9999 · ShellCrash",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/clash.png",online:U.services.clash,desc:"小米主路由器透明网关控制台,实时监控全屋设备流量、分流规则与狮城 AI 算力专线锁定状态。",edgeUrl:"https://clash.home.961504.xyz:10443/ui/",homeUrl:"https://clash.home.961504.xyz:10443/ui/",lanUrl:"http://192.168.31.1:9999/ui/",stats:[{label:"AI 锁定策略",value:"狮城节点",highlight:!0},{label:"新加坡延迟",value:U.network.sg_delay_ms>0?`${U.network.sg_delay_ms} ms`:"直连"},{label:"固定出口 IP",value:U.network.sg_egress_ip}]},{id:"router",title:"小米主路由器后台",subtitle:"192.168.31.1 · PPPoE 公网网关",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/openwrt.png",online:U.services.router,desc:"管理家庭联通公网宽带拨号、DHCP 静态 IP 绑定、10443 与 41641 端口转发及全屋内网 Split-DNS。",edgeUrl:"https://router.home.961504.xyz:10443",homeUrl:"https://router.home.961504.xyz:10443",lanUrl:"http://192.168.31.1",stats:[{label:"联通公网 IPv4",value:U.network.home_wan_ip,highlight:!0},{label:"泛域名 DDNS",value:"*.home.961504.xyz"},{label:"内网网关",value:"192.168.31.1"}]},{id:"uptime",title:"Uptime Kuma 外部哨兵",subtitle:"status.961504.xyz · SG Azure",iconUrl:"https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/uptime-kuma.png",online:U.services.uptime,desc:"独立部署在新加坡 Azure 公有云上的 24 小时外部监控哨兵,通过 Tailscale P2P 专线实时探测家庭服务。",edgeUrl:"https://status.961504.xyz",homeUrl:"https://status.961504.xyz",lanUrl:"https://status.961504.xyz",stats:[{label:"云端公网 IP",value:"104.43.105.243"},{label:"Tailscale 专线",value:"100.115.204.51"},{label:"外部探测状态",value:"100% 在线",highlight:!0}]}]}]},[x]);return f.jsxs("div",{className:"min-h-screen flex flex-col",children:[O&&f.jsxs("div",{className:"fixed bottom-5 right-5 z-50 hl-card px-4 py-3 flex items-center gap-2.5 shadow-2xl",children:[f.jsx("span",{className:"w-2 h-2 rounded-full",style:{backgroundColor:"var(--success)"}}),f.jsx("span",{className:"text-xs font-medium",children:O})]}),f.jsx(Sy,{}),T==="storybook"?f.jsx(Ey,{}):f.jsxs("main",{className:"flex-1 max-w-7xl w-full mx-auto px-4 sm:px-6 lg:px-8 py-6 space-y-7",children:[D.map(U=>f.jsxs("section",{className:"space-y-3",children:[f.jsxs("div",{className:"flex items-center justify-between px-0.5",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("h2",{className:"text-xs font-semibold uppercase tracking-wider",style:{color:"var(--text-muted)"},children:U.title}),f.jsxs("span",{className:"text-[11px] font-mono-num",style:{color:"var(--text-subtle)"},children:["· ",U.subtitle]})]}),U.showRouteHint&&f.jsxs("span",{className:"text-[11px] font-mono-num hidden sm:inline",style:{color:"var(--text-subtle)"},children:["当前路由模式: ",A]})]}),f.jsx("div",{className:`grid ${S}`,children:U.items.map(vl=>f.jsx(T0,{card:vl},vl.id))})]},U.title)),f.jsx(_0,{})]}),f.jsx(Ny,{}),f.jsx(Ty,{}),Q&&f.jsx("div",{className:"fixed inset-0 z-50 bg-black/75 backdrop-blur-sm flex items-center justify-center p-4",children:f.jsx(Ds,{targetUrl:Q,onSuccess:()=>{window.location.href=Q},onCancel:()=>{W(null),window.history.replaceState({},"","/")}})})]})};Mv.createRoot(document.getElementById("root")).render(f.jsx(wc.StrictMode,{children:f.jsx(zy,{})}));