From 374fb835c5bd911d22824da2cf28c20f1ac09295 Mon Sep 17 00:00:00 2001 From: K7ZVX Date: Tue, 12 May 2026 16:46:51 +0000 Subject: [PATCH] fix(dashboard): content scroll overflow bug --- dashboard-frontend/src/components/Layout.tsx | 324 +++++++++--------- .../static/assets/index-DdqEB3wX.css | 1 + .../dashboard/static/assets/index-DnO02g6m.js | 147 ++++++++ meshai/dashboard/static/index.html | 37 +- 4 files changed, 327 insertions(+), 182 deletions(-) create mode 100644 meshai/dashboard/static/assets/index-DdqEB3wX.css create mode 100644 meshai/dashboard/static/assets/index-DnO02g6m.js diff --git a/dashboard-frontend/src/components/Layout.tsx b/dashboard-frontend/src/components/Layout.tsx index 778d77c..c620da8 100644 --- a/dashboard-frontend/src/components/Layout.tsx +++ b/dashboard-frontend/src/components/Layout.tsx @@ -1,162 +1,162 @@ -import { ReactNode, useEffect, useState } from 'react' -import { Link, useLocation } from 'react-router-dom' -import { - LayoutDashboard, - Radio, - Cloud, - Settings, - Bell, -} from 'lucide-react' -import { fetchStatus, type SystemStatus } from '@/lib/api' -import { useWebSocket } from '@/hooks/useWebSocket' - -interface LayoutProps { - children: ReactNode -} - -const navItems = [ - { path: '/', label: 'Dashboard', icon: LayoutDashboard }, - { path: '/mesh', label: 'Mesh', icon: Radio }, - { path: '/environment', label: 'Environment', icon: Cloud }, - { path: '/config', label: 'Config', icon: Settings }, - { path: '/alerts', label: 'Alerts', icon: Bell }, -] - -function formatUptime(seconds: number): string { - const days = Math.floor(seconds / 86400) - const hours = Math.floor((seconds % 86400) / 3600) - const mins = Math.floor((seconds % 3600) / 60) - - if (days > 0) return `${days}d ${hours}h` - if (hours > 0) return `${hours}h ${mins}m` - return `${mins}m` -} - -function getPageTitle(pathname: string): string { - const item = navItems.find((i) => i.path === pathname) - return item?.label || 'Dashboard' -} - -export default function Layout({ children }: LayoutProps) { - const location = useLocation() - const { connected } = useWebSocket() - const [status, setStatus] = useState(null) - const [currentTime, setCurrentTime] = useState(new Date()) - - useEffect(() => { - fetchStatus().then(setStatus).catch(console.error) - const interval = setInterval(() => { - fetchStatus().then(setStatus).catch(console.error) - }, 30000) - return () => clearInterval(interval) - }, []) - - useEffect(() => { - const interval = setInterval(() => setCurrentTime(new Date()), 1000) - return () => clearInterval(interval) - }, []) - - const timeStr = currentTime.toLocaleTimeString('en-US', { - hour12: false, - hour: '2-digit', - minute: '2-digit', - second: '2-digit', - }) - - return ( -
- {/* Sidebar */} - - - {/* Main content */} -
- {/* Header */} -
-

- {getPageTitle(location.pathname)} -

-
- {/* Live indicator */} -
-
- - {connected ? 'Live' : 'Offline'} - -
- {/* Clock */} -
- {timeStr} MT -
-
-
- - {/* Page content */} -
{children}
-
-
- ) -} +import { ReactNode, useEffect, useState } from 'react' +import { Link, useLocation } from 'react-router-dom' +import { + LayoutDashboard, + Radio, + Cloud, + Settings, + Bell, +} from 'lucide-react' +import { fetchStatus, type SystemStatus } from '@/lib/api' +import { useWebSocket } from '@/hooks/useWebSocket' + +interface LayoutProps { + children: ReactNode +} + +const navItems = [ + { path: '/', label: 'Dashboard', icon: LayoutDashboard }, + { path: '/mesh', label: 'Mesh', icon: Radio }, + { path: '/environment', label: 'Environment', icon: Cloud }, + { path: '/config', label: 'Config', icon: Settings }, + { path: '/alerts', label: 'Alerts', icon: Bell }, +] + +function formatUptime(seconds: number): string { + const days = Math.floor(seconds / 86400) + const hours = Math.floor((seconds % 86400) / 3600) + const mins = Math.floor((seconds % 3600) / 60) + + if (days > 0) return `${days}d ${hours}h` + if (hours > 0) return `${hours}h ${mins}m` + return `${mins}m` +} + +function getPageTitle(pathname: string): string { + const item = navItems.find((i) => i.path === pathname) + return item?.label || 'Dashboard' +} + +export default function Layout({ children }: LayoutProps) { + const location = useLocation() + const { connected } = useWebSocket() + const [status, setStatus] = useState(null) + const [currentTime, setCurrentTime] = useState(new Date()) + + useEffect(() => { + fetchStatus().then(setStatus).catch(console.error) + const interval = setInterval(() => { + fetchStatus().then(setStatus).catch(console.error) + }, 30000) + return () => clearInterval(interval) + }, []) + + useEffect(() => { + const interval = setInterval(() => setCurrentTime(new Date()), 1000) + return () => clearInterval(interval) + }, []) + + const timeStr = currentTime.toLocaleTimeString('en-US', { + hour12: false, + hour: '2-digit', + minute: '2-digit', + second: '2-digit', + }) + + return ( +
+ {/* Sidebar */} + + + {/* Main content */} +
+ {/* Header */} +
+

+ {getPageTitle(location.pathname)} +

+
+ {/* Live indicator */} +
+
+ + {connected ? 'Live' : 'Offline'} + +
+ {/* Clock */} +
+ {timeStr} MT +
+
+
+ + {/* Page content */} +
{children}
+
+
+ ) +} diff --git a/meshai/dashboard/static/assets/index-DdqEB3wX.css b/meshai/dashboard/static/assets/index-DdqEB3wX.css new file mode 100644 index 0000000..38bf7bc --- /dev/null +++ b/meshai/dashboard/static/assets/index-DdqEB3wX.css @@ -0,0 +1 @@ +*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:JetBrains Mono,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.absolute{position:absolute}.relative{position:relative}.bottom-0{bottom:0}.left-0{left:0}.top-0{top:0}.mb-2{margin-bottom:.5rem}.mb-4{margin-bottom:1rem}.mb-6{margin-bottom:1.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-6{margin-top:1.5rem}.flex{display:flex}.grid{display:grid}.h-10{height:2.5rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-64{height:16rem}.h-\[60vh\]{height:60vh}.h-full{height:100%}.h-screen{height:100vh}.w-0\.5{width:.125rem}.w-10{width:2.5rem}.w-12{width:3rem}.w-16{width:4rem}.w-2{width:.5rem}.w-24{width:6rem}.w-\[220px\]{width:220px}.min-w-0{min-width:0px}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.flex-shrink-0{flex-shrink:0}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.border{border-width:1px}.border-b{border-bottom-width:1px}.border-l-2{border-left-width:2px}.border-r{border-right-width:1px}.border-t{border-top-width:1px}.border-amber-500{--tw-border-opacity: 1;border-color:rgb(245 158 11 / var(--tw-border-opacity, 1))}.border-border{--tw-border-opacity: 1;border-color:rgb(30 42 58 / var(--tw-border-opacity, 1))}.border-green-500{--tw-border-opacity: 1;border-color:rgb(34 197 94 / var(--tw-border-opacity, 1))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68 / var(--tw-border-opacity, 1))}.bg-amber-500{--tw-bg-opacity: 1;background-color:rgb(245 158 11 / var(--tw-bg-opacity, 1))}.bg-amber-500\/10{background-color:#f59e0b1a}.bg-bg{--tw-bg-opacity: 1;background-color:rgb(10 14 23 / var(--tw-bg-opacity, 1))}.bg-bg-card{--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity, 1))}.bg-bg-hover{--tw-bg-opacity: 1;background-color:rgb(26 35 50 / var(--tw-bg-opacity, 1))}.bg-blue-500{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}.bg-blue-500\/10{background-color:#3b82f61a}.bg-border{--tw-bg-opacity: 1;background-color:rgb(30 42 58 / var(--tw-bg-opacity, 1))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity, 1))}.bg-green-500\/10{background-color:#22c55e1a}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-500\/10{background-color:#ef44441a}.bg-slate-500{--tw-bg-opacity: 1;background-color:rgb(100 116 139 / var(--tw-bg-opacity, 1))}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.from-blue-500{--tw-gradient-from: #3b82f6 var(--tw-gradient-from-position);--tw-gradient-to: rgb(59 130 246 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.to-blue-700{--tw-gradient-to: #1d4ed8 var(--tw-gradient-to-position)}.fill-slate-100{fill:#f1f5f9}.fill-slate-400{fill:#94a3b8}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.text-center{text-align:center}.text-right{text-align:right}.font-mono{font-family:JetBrains Mono,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.text-amber-500{--tw-text-opacity: 1;color:rgb(245 158 11 / var(--tw-text-opacity, 1))}.text-blue-400{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity, 1))}.text-red-400{--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-slate-100{--tw-text-opacity: 1;color:rgb(241 245 249 / var(--tw-text-opacity, 1))}.text-slate-200{--tw-text-opacity: 1;color:rgb(226 232 240 / var(--tw-text-opacity, 1))}.text-slate-300{--tw-text-opacity: 1;color:rgb(203 213 225 / var(--tw-text-opacity, 1))}.text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.text-slate-500{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-300{transition-duration:.3s}.duration-500{transition-duration:.5s}body{background:#0a0e17;margin:0;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-track{background:#0a0e17}::-webkit-scrollbar-thumb{background:#2d3a4d;border-radius:4px}::-webkit-scrollbar-thumb:hover{background:#3b4a5d}.font-mono{font-family:JetBrains Mono,monospace}@keyframes pulse{0%,to{opacity:1}50%{opacity:.5}}.animate-pulse-slow{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}.hover\:bg-bg-hover:hover{--tw-bg-opacity: 1;background-color:rgb(26 35 50 / var(--tw-bg-opacity, 1))}.hover\:text-slate-200:hover{--tw-text-opacity: 1;color:rgb(226 232 240 / var(--tw-text-opacity, 1))}@media (min-width: 1024px){.lg\:col-span-2{grid-column:span 2 / span 2}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}} diff --git a/meshai/dashboard/static/assets/index-DnO02g6m.js b/meshai/dashboard/static/assets/index-DnO02g6m.js new file mode 100644 index 0000000..88092d2 --- /dev/null +++ b/meshai/dashboard/static/assets/index-DnO02g6m.js @@ -0,0 +1,147 @@ +function tf(e,t){for(var n=0;nr[l]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))r(l);new MutationObserver(l=>{for(const o of l)if(o.type==="childList")for(const i of o.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&r(i)}).observe(document,{childList:!0,subtree:!0});function n(l){const o={};return l.integrity&&(o.integrity=l.integrity),l.referrerPolicy&&(o.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?o.credentials="include":l.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(l){if(l.ep)return;l.ep=!0;const o=n(l);fetch(l.href,o)}})();function nf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Cs={exports:{}},vl={},Ns={exports:{}},T={};/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var lr=Symbol.for("react.element"),rf=Symbol.for("react.portal"),lf=Symbol.for("react.fragment"),of=Symbol.for("react.strict_mode"),uf=Symbol.for("react.profiler"),sf=Symbol.for("react.provider"),af=Symbol.for("react.context"),cf=Symbol.for("react.forward_ref"),ff=Symbol.for("react.suspense"),df=Symbol.for("react.memo"),pf=Symbol.for("react.lazy"),ou=Symbol.iterator;function hf(e){return e===null||typeof e!="object"?null:(e=ou&&e[ou]||e["@@iterator"],typeof e=="function"?e:null)}var _s={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Ps=Object.assign,js={};function dn(e,t,n){this.props=e,this.context=t,this.refs=js,this.updater=n||_s}dn.prototype.isReactComponent={};dn.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};dn.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function zs(){}zs.prototype=dn.prototype;function ii(e,t,n){this.props=e,this.context=t,this.refs=js,this.updater=n||_s}var ui=ii.prototype=new zs;ui.constructor=ii;Ps(ui,dn.prototype);ui.isPureReactComponent=!0;var iu=Array.isArray,Ls=Object.prototype.hasOwnProperty,si={current:null},Rs={key:!0,ref:!0,__self:!0,__source:!0};function Ts(e,t,n){var r,l={},o=null,i=null;if(t!=null)for(r in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(o=""+t.key),t)Ls.call(t,r)&&!Rs.hasOwnProperty(r)&&(l[r]=t[r]);var u=arguments.length-2;if(u===1)l.children=n;else if(1>>1,J=_[Q];if(0>>1;Ql(Il,R))Stl(pr,Il)?(_[Q]=pr,_[St]=R,Q=St):(_[Q]=Il,_[wt]=R,Q=wt);else if(Stl(pr,R))_[Q]=pr,_[St]=R,Q=St;else break e}}return L}function l(_,L){var R=_.sortIndex-L.sortIndex;return R!==0?R:_.id-L.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var i=Date,u=i.now();e.unstable_now=function(){return i.now()-u}}var s=[],a=[],h=1,p=null,m=3,g=!1,x=!1,y=!1,E=typeof setTimeout=="function"?setTimeout:null,f=typeof clearTimeout=="function"?clearTimeout:null,c=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function d(_){for(var L=n(a);L!==null;){if(L.callback===null)r(a);else if(L.startTime<=_)r(a),L.sortIndex=L.expirationTime,t(s,L);else break;L=n(a)}}function w(_){if(y=!1,d(_),!x)if(n(s)!==null)x=!0,Ml(C);else{var L=n(a);L!==null&&Ol(w,L.startTime-_)}}function C(_,L){x=!1,y&&(y=!1,f(z),z=-1),g=!0;var R=m;try{for(d(L),p=n(s);p!==null&&(!(p.expirationTime>L)||_&&!ze());){var Q=p.callback;if(typeof Q=="function"){p.callback=null,m=p.priorityLevel;var J=Q(p.expirationTime<=L);L=e.unstable_now(),typeof J=="function"?p.callback=J:p===n(s)&&r(s),d(L)}else r(s);p=n(s)}if(p!==null)var dr=!0;else{var wt=n(a);wt!==null&&Ol(w,wt.startTime-L),dr=!1}return dr}finally{p=null,m=R,g=!1}}var P=!1,j=null,z=-1,H=5,M=-1;function ze(){return!(e.unstable_now()-M_||125<_?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):H=0<_?Math.floor(1e3/_):5},e.unstable_getCurrentPriorityLevel=function(){return m},e.unstable_getFirstCallbackNode=function(){return n(s)},e.unstable_next=function(_){switch(m){case 1:case 2:case 3:var L=3;break;default:L=m}var R=m;m=L;try{return _()}finally{m=R}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(_,L){switch(_){case 1:case 2:case 3:case 4:case 5:break;default:_=3}var R=m;m=_;try{return L()}finally{m=R}},e.unstable_scheduleCallback=function(_,L,R){var Q=e.unstable_now();switch(typeof R=="object"&&R!==null?(R=R.delay,R=typeof R=="number"&&0Q?(_.sortIndex=R,t(a,_),n(s)===null&&_===n(a)&&(y?(f(z),z=-1):y=!0,Ol(w,R-Q))):(_.sortIndex=J,t(s,_),x||g||(x=!0,Ml(C))),_},e.unstable_shouldYield=ze,e.unstable_wrapCallback=function(_){var L=m;return function(){var R=m;m=L;try{return _.apply(this,arguments)}finally{m=R}}}})(Us);Fs.exports=Us;var _f=Fs.exports;/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var Pf=k,xe=_f;function S(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),co=Object.prototype.hasOwnProperty,jf=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,su={},au={};function zf(e){return co.call(au,e)?!0:co.call(su,e)?!1:jf.test(e)?au[e]=!0:(su[e]=!0,!1)}function Lf(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Rf(e,t,n,r){if(t===null||typeof t>"u"||Lf(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function ce(e,t,n,r,l,o,i){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=i}var ne={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){ne[e]=new ce(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];ne[t]=new ce(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){ne[e]=new ce(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){ne[e]=new ce(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){ne[e]=new ce(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){ne[e]=new ce(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){ne[e]=new ce(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){ne[e]=new ce(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){ne[e]=new ce(e,5,!1,e.toLowerCase(),null,!1,!1)});var ci=/[\-:]([a-z])/g;function fi(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(ci,fi);ne[t]=new ce(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(ci,fi);ne[t]=new ce(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(ci,fi);ne[t]=new ce(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){ne[e]=new ce(e,1,!1,e.toLowerCase(),null,!1,!1)});ne.xlinkHref=new ce("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){ne[e]=new ce(e,1,!1,e.toLowerCase(),null,!0,!0)});function di(e,t,n,r){var l=ne.hasOwnProperty(t)?ne[t]:null;(l!==null?l.type!==0:r||!(2u||l[i]!==o[u]){var s=` +`+l[i].replace(" at new "," at ");return e.displayName&&s.includes("")&&(s=s.replace("",e.displayName)),s}while(1<=i&&0<=u);break}}}finally{Ul=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?_n(e):""}function Tf(e){switch(e.tag){case 5:return _n(e.type);case 16:return _n("Lazy");case 13:return _n("Suspense");case 19:return _n("SuspenseList");case 0:case 2:case 15:return e=$l(e.type,!1),e;case 11:return e=$l(e.type.render,!1),e;case 1:return e=$l(e.type,!0),e;default:return""}}function mo(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Bt:return"Fragment";case At:return"Portal";case fo:return"Profiler";case pi:return"StrictMode";case po:return"Suspense";case ho:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Bs:return(e.displayName||"Context")+".Consumer";case As:return(e._context.displayName||"Context")+".Provider";case hi:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case mi:return t=e.displayName||null,t!==null?t:mo(e.type)||"Memo";case be:t=e._payload,e=e._init;try{return mo(e(t))}catch{}}return null}function Mf(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return mo(t);case 8:return t===pi?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function mt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Vs(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Of(e){var t=Vs(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(i){r=""+i,o.call(this,i)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(i){r=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function vr(e){e._valueTracker||(e._valueTracker=Of(e))}function Hs(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Vs(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Qr(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function vo(e,t){var n=t.checked;return W({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function fu(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=mt(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Qs(e,t){t=t.checked,t!=null&&di(e,"checked",t,!1)}function go(e,t){Qs(e,t);var n=mt(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?yo(e,t.type,n):t.hasOwnProperty("defaultValue")&&yo(e,t.type,mt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function du(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function yo(e,t,n){(t!=="number"||Qr(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Pn=Array.isArray;function qt(e,t,n,r){if(e=e.options,t){t={};for(var l=0;l"+t.valueOf().toString()+"",t=gr.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function An(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ln={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},If=["Webkit","ms","Moz","O"];Object.keys(Ln).forEach(function(e){If.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ln[t]=Ln[e]})});function Gs(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Ln.hasOwnProperty(e)&&Ln[e]?(""+t).trim():t+"px"}function Zs(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,l=Gs(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,l):e[n]=l}}var Df=W({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function So(e,t){if(t){if(Df[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(S(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(S(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(S(61))}if(t.style!=null&&typeof t.style!="object")throw Error(S(62))}}function ko(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Eo=null;function vi(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Co=null,bt=null,en=null;function mu(e){if(e=ur(e)){if(typeof Co!="function")throw Error(S(280));var t=e.stateNode;t&&(t=Sl(t),Co(e.stateNode,e.type,t))}}function Js(e){bt?en?en.push(e):en=[e]:bt=e}function qs(){if(bt){var e=bt,t=en;if(en=bt=null,mu(e),t)for(e=0;e>>=0,e===0?32:31-(Yf(e)/Xf|0)|0}var yr=64,xr=4194304;function jn(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Gr(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,l=e.suspendedLanes,o=e.pingedLanes,i=n&268435455;if(i!==0){var u=i&~l;u!==0?r=jn(u):(o&=i,o!==0&&(r=jn(o)))}else i=n&~l,i!==0?r=jn(i):o!==0&&(r=jn(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&l)&&(l=r&-r,o=t&-t,l>=o||l===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function or(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Oe(t),e[t]=n}function qf(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Tn),Cu=" ",Nu=!1;function ya(e,t){switch(e){case"keyup":return _d.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function xa(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Wt=!1;function jd(e,t){switch(e){case"compositionend":return xa(t);case"keypress":return t.which!==32?null:(Nu=!0,Cu);case"textInput":return e=t.data,e===Cu&&Nu?null:e;default:return null}}function zd(e,t){if(Wt)return e==="compositionend"||!Ci&&ya(e,t)?(e=va(),Dr=Si=rt=null,Wt=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=zu(n)}}function Ea(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Ea(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Ca(){for(var e=window,t=Qr();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Qr(e.document)}return t}function Ni(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function Ud(e){var t=Ca(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Ea(n.ownerDocument.documentElement,n)){if(r!==null&&Ni(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var l=n.textContent.length,o=Math.min(r.start,l);r=r.end===void 0?o:Math.min(r.end,l),!e.extend&&o>r&&(l=r,r=o,o=l),l=Lu(n,o);var i=Lu(n,r);l&&i&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==i.node||e.focusOffset!==i.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(i.node,i.offset)):(t.setEnd(i.node,i.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,Vt=null,Lo=null,On=null,Ro=!1;function Ru(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ro||Vt==null||Vt!==Qr(r)||(r=Vt,"selectionStart"in r&&Ni(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),On&&Kn(On,r)||(On=r,r=qr(Lo,"onSelect"),0Kt||(e.current=Fo[Kt],Fo[Kt]=null,Kt--)}function D(e,t){Kt++,Fo[Kt]=e.current,e.current=t}var vt={},ie=yt(vt),pe=yt(!1),zt=vt;function on(e,t){var n=e.type.contextTypes;if(!n)return vt;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var l={},o;for(o in n)l[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function he(e){return e=e.childContextTypes,e!=null}function el(){U(pe),U(ie)}function Uu(e,t,n){if(ie.current!==vt)throw Error(S(168));D(ie,t),D(pe,n)}function Ma(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var l in r)if(!(l in t))throw Error(S(108,Mf(e)||"Unknown",l));return W({},n,r)}function tl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||vt,zt=ie.current,D(ie,e),D(pe,pe.current),!0}function $u(e,t,n){var r=e.stateNode;if(!r)throw Error(S(169));n?(e=Ma(e,t,zt),r.__reactInternalMemoizedMergedChildContext=e,U(pe),U(ie),D(ie,e)):U(pe),D(pe,n)}var Ve=null,kl=!1,bl=!1;function Oa(e){Ve===null?Ve=[e]:Ve.push(e)}function Zd(e){kl=!0,Oa(e)}function xt(){if(!bl&&Ve!==null){bl=!0;var e=0,t=I;try{var n=Ve;for(I=1;e>=i,l-=i,He=1<<32-Oe(t)+l|n<z?(H=j,j=null):H=j.sibling;var M=m(f,j,d[z],w);if(M===null){j===null&&(j=H);break}e&&j&&M.alternate===null&&t(f,j),c=o(M,c,z),P===null?C=M:P.sibling=M,P=M,j=H}if(z===d.length)return n(f,j),$&&kt(f,z),C;if(j===null){for(;zz?(H=j,j=null):H=j.sibling;var ze=m(f,j,M.value,w);if(ze===null){j===null&&(j=H);break}e&&j&&ze.alternate===null&&t(f,j),c=o(ze,c,z),P===null?C=ze:P.sibling=ze,P=ze,j=H}if(M.done)return n(f,j),$&&kt(f,z),C;if(j===null){for(;!M.done;z++,M=d.next())M=p(f,M.value,w),M!==null&&(c=o(M,c,z),P===null?C=M:P.sibling=M,P=M);return $&&kt(f,z),C}for(j=r(f,j);!M.done;z++,M=d.next())M=g(j,f,z,M.value,w),M!==null&&(e&&M.alternate!==null&&j.delete(M.key===null?z:M.key),c=o(M,c,z),P===null?C=M:P.sibling=M,P=M);return e&&j.forEach(function(vn){return t(f,vn)}),$&&kt(f,z),C}function E(f,c,d,w){if(typeof d=="object"&&d!==null&&d.type===Bt&&d.key===null&&(d=d.props.children),typeof d=="object"&&d!==null){switch(d.$$typeof){case mr:e:{for(var C=d.key,P=c;P!==null;){if(P.key===C){if(C=d.type,C===Bt){if(P.tag===7){n(f,P.sibling),c=l(P,d.props.children),c.return=f,f=c;break e}}else if(P.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===be&&Wu(C)===P.type){n(f,P.sibling),c=l(P,d.props),c.ref=En(f,P,d),c.return=f,f=c;break e}n(f,P);break}else t(f,P);P=P.sibling}d.type===Bt?(c=jt(d.props.children,f.mode,w,d.key),c.return=f,f=c):(w=Hr(d.type,d.key,d.props,null,f.mode,w),w.ref=En(f,c,d),w.return=f,f=w)}return i(f);case At:e:{for(P=d.key;c!==null;){if(c.key===P)if(c.tag===4&&c.stateNode.containerInfo===d.containerInfo&&c.stateNode.implementation===d.implementation){n(f,c.sibling),c=l(c,d.children||[]),c.return=f,f=c;break e}else{n(f,c);break}else t(f,c);c=c.sibling}c=uo(d,f.mode,w),c.return=f,f=c}return i(f);case be:return P=d._init,E(f,c,P(d._payload),w)}if(Pn(d))return x(f,c,d,w);if(yn(d))return y(f,c,d,w);_r(f,d)}return typeof d=="string"&&d!==""||typeof d=="number"?(d=""+d,c!==null&&c.tag===6?(n(f,c.sibling),c=l(c,d),c.return=f,f=c):(n(f,c),c=io(d,f.mode,w),c.return=f,f=c),i(f)):n(f,c)}return E}var sn=Ua(!0),$a=Ua(!1),ll=yt(null),ol=null,Gt=null,zi=null;function Li(){zi=Gt=ol=null}function Ri(e){var t=ll.current;U(ll),e._currentValue=t}function Ao(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function nn(e,t){ol=e,zi=Gt=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(de=!0),e.firstContext=null)}function _e(e){var t=e._currentValue;if(zi!==e)if(e={context:e,memoizedValue:t,next:null},Gt===null){if(ol===null)throw Error(S(308));Gt=e,ol.dependencies={lanes:0,firstContext:e}}else Gt=Gt.next=e;return t}var Nt=null;function Ti(e){Nt===null?Nt=[e]:Nt.push(e)}function Aa(e,t,n,r){var l=t.interleaved;return l===null?(n.next=n,Ti(t)):(n.next=l.next,l.next=n),t.interleaved=n,Ge(e,r)}function Ge(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var et=!1;function Mi(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Ba(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Ke(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function ct(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,O&2){var l=r.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),r.pending=t,Ge(e,n)}return l=r.interleaved,l===null?(t.next=t,Ti(r)):(t.next=l.next,l.next=t),r.interleaved=t,Ge(e,n)}function Ur(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,yi(e,n)}}function Vu(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var l=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var i={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?l=o=i:o=o.next=i,n=n.next}while(n!==null);o===null?l=o=t:o=o.next=t}else l=o=t;n={baseState:r.baseState,firstBaseUpdate:l,lastBaseUpdate:o,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function il(e,t,n,r){var l=e.updateQueue;et=!1;var o=l.firstBaseUpdate,i=l.lastBaseUpdate,u=l.shared.pending;if(u!==null){l.shared.pending=null;var s=u,a=s.next;s.next=null,i===null?o=a:i.next=a,i=s;var h=e.alternate;h!==null&&(h=h.updateQueue,u=h.lastBaseUpdate,u!==i&&(u===null?h.firstBaseUpdate=a:u.next=a,h.lastBaseUpdate=s))}if(o!==null){var p=l.baseState;i=0,h=a=s=null,u=o;do{var m=u.lane,g=u.eventTime;if((r&m)===m){h!==null&&(h=h.next={eventTime:g,lane:0,tag:u.tag,payload:u.payload,callback:u.callback,next:null});e:{var x=e,y=u;switch(m=t,g=n,y.tag){case 1:if(x=y.payload,typeof x=="function"){p=x.call(g,p,m);break e}p=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=y.payload,m=typeof x=="function"?x.call(g,p,m):x,m==null)break e;p=W({},p,m);break e;case 2:et=!0}}u.callback!==null&&u.lane!==0&&(e.flags|=64,m=l.effects,m===null?l.effects=[u]:m.push(u))}else g={eventTime:g,lane:m,tag:u.tag,payload:u.payload,callback:u.callback,next:null},h===null?(a=h=g,s=p):h=h.next=g,i|=m;if(u=u.next,u===null){if(u=l.shared.pending,u===null)break;m=u,u=m.next,m.next=null,l.lastBaseUpdate=m,l.shared.pending=null}}while(!0);if(h===null&&(s=p),l.baseState=s,l.firstBaseUpdate=a,l.lastBaseUpdate=h,t=l.shared.interleaved,t!==null){l=t;do i|=l.lane,l=l.next;while(l!==t)}else o===null&&(l.shared.lanes=0);Tt|=i,e.lanes=i,e.memoizedState=p}}function Hu(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=to.transition;to.transition={};try{e(!1),t()}finally{I=n,to.transition=r}}function lc(){return Pe().memoizedState}function ep(e,t,n){var r=dt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},oc(e))ic(t,n);else if(n=Aa(e,t,n,r),n!==null){var l=se();Ie(n,e,r,l),uc(n,t,r)}}function tp(e,t,n){var r=dt(e),l={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(oc(e))ic(t,l);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var i=t.lastRenderedState,u=o(i,n);if(l.hasEagerState=!0,l.eagerState=u,De(u,i)){var s=t.interleaved;s===null?(l.next=l,Ti(t)):(l.next=s.next,s.next=l),t.interleaved=l;return}}catch{}finally{}n=Aa(e,t,l,r),n!==null&&(l=se(),Ie(n,e,r,l),uc(n,t,r))}}function oc(e){var t=e.alternate;return e===B||t!==null&&t===B}function ic(e,t){In=sl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function uc(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,yi(e,n)}}var al={readContext:_e,useCallback:re,useContext:re,useEffect:re,useImperativeHandle:re,useInsertionEffect:re,useLayoutEffect:re,useMemo:re,useReducer:re,useRef:re,useState:re,useDebugValue:re,useDeferredValue:re,useTransition:re,useMutableSource:re,useSyncExternalStore:re,useId:re,unstable_isNewReconciler:!1},np={readContext:_e,useCallback:function(e,t){return Ue().memoizedState=[e,t===void 0?null:t],e},useContext:_e,useEffect:Ku,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Ar(4194308,4,ba.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Ar(4194308,4,e,t)},useInsertionEffect:function(e,t){return Ar(4,2,e,t)},useMemo:function(e,t){var n=Ue();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Ue();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=ep.bind(null,B,e),[r.memoizedState,e]},useRef:function(e){var t=Ue();return e={current:e},t.memoizedState=e},useState:Qu,useDebugValue:Bi,useDeferredValue:function(e){return Ue().memoizedState=e},useTransition:function(){var e=Qu(!1),t=e[0];return e=bd.bind(null,e[1]),Ue().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=B,l=Ue();if($){if(n===void 0)throw Error(S(407));n=n()}else{if(n=t(),b===null)throw Error(S(349));Rt&30||Qa(r,t,n)}l.memoizedState=n;var o={value:n,getSnapshot:t};return l.queue=o,Ku(Ya.bind(null,r,o,e),[e]),r.flags|=2048,er(9,Ka.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=Ue(),t=b.identifierPrefix;if($){var n=Qe,r=He;n=(r&~(1<<32-Oe(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=qn++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=i.createElement(n,{is:r.is}):(e=i.createElement(n),n==="select"&&(i=e,r.multiple?i.multiple=!0:r.size&&(i.size=r.size))):e=i.createElementNS(e,n),e[$e]=t,e[Gn]=r,gc(e,t,!1,!1),t.stateNode=e;e:{switch(i=ko(n,r),n){case"dialog":F("cancel",e),F("close",e),l=r;break;case"iframe":case"object":case"embed":F("load",e),l=r;break;case"video":case"audio":for(l=0;lfn&&(t.flags|=128,r=!0,Cn(o,!1),t.lanes=4194304)}else{if(!r)if(e=ul(i),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Cn(o,!0),o.tail===null&&o.tailMode==="hidden"&&!i.alternate&&!$)return le(t),null}else 2*K()-o.renderingStartTime>fn&&n!==1073741824&&(t.flags|=128,r=!0,Cn(o,!1),t.lanes=4194304);o.isBackwards?(i.sibling=t.child,t.child=i):(n=o.last,n!==null?n.sibling=i:t.child=i,o.last=i)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=K(),t.sibling=null,n=A.current,D(A,r?n&1|2:n&1),t):(le(t),null);case 22:case 23:return Yi(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?ve&1073741824&&(le(t),t.subtreeFlags&6&&(t.flags|=8192)):le(t),null;case 24:return null;case 25:return null}throw Error(S(156,t.tag))}function cp(e,t){switch(Pi(t),t.tag){case 1:return he(t.type)&&el(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return an(),U(pe),U(ie),Di(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Ii(t),null;case 13:if(U(A),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(S(340));un()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return U(A),null;case 4:return an(),null;case 10:return Ri(t.type._context),null;case 22:case 23:return Yi(),null;case 24:return null;default:return null}}var jr=!1,oe=!1,fp=typeof WeakSet=="function"?WeakSet:Set,N=null;function Zt(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){V(e,t,r)}else n.current=null}function Go(e,t,n){try{n()}catch(r){V(e,t,r)}}var rs=!1;function dp(e,t){if(To=Zr,e=Ca(),Ni(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var l=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var i=0,u=-1,s=-1,a=0,h=0,p=e,m=null;t:for(;;){for(var g;p!==n||l!==0&&p.nodeType!==3||(u=i+l),p!==o||r!==0&&p.nodeType!==3||(s=i+r),p.nodeType===3&&(i+=p.nodeValue.length),(g=p.firstChild)!==null;)m=p,p=g;for(;;){if(p===e)break t;if(m===n&&++a===l&&(u=i),m===o&&++h===r&&(s=i),(g=p.nextSibling)!==null)break;p=m,m=p.parentNode}p=g}n=u===-1||s===-1?null:{start:u,end:s}}else n=null}n=n||{start:0,end:0}}else n=null;for(Mo={focusedElem:e,selectionRange:n},Zr=!1,N=t;N!==null;)if(t=N,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,N=e;else for(;N!==null;){t=N;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var y=x.memoizedProps,E=x.memoizedState,f=t.stateNode,c=f.getSnapshotBeforeUpdate(t.elementType===t.type?y:Re(t.type,y),E);f.__reactInternalSnapshotBeforeUpdate=c}break;case 3:var d=t.stateNode.containerInfo;d.nodeType===1?d.textContent="":d.nodeType===9&&d.documentElement&&d.removeChild(d.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(S(163))}}catch(w){V(t,t.return,w)}if(e=t.sibling,e!==null){e.return=t.return,N=e;break}N=t.return}return x=rs,rs=!1,x}function Dn(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var l=r=r.next;do{if((l.tag&e)===e){var o=l.destroy;l.destroy=void 0,o!==void 0&&Go(t,n,o)}l=l.next}while(l!==r)}}function Nl(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Zo(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function wc(e){var t=e.alternate;t!==null&&(e.alternate=null,wc(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[$e],delete t[Gn],delete t[Do],delete t[Xd],delete t[Gd])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Sc(e){return e.tag===5||e.tag===3||e.tag===4}function ls(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Sc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Jo(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=br));else if(r!==4&&(e=e.child,e!==null))for(Jo(e,t,n),e=e.sibling;e!==null;)Jo(e,t,n),e=e.sibling}function qo(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(qo(e,t,n),e=e.sibling;e!==null;)qo(e,t,n),e=e.sibling}var ee=null,Te=!1;function qe(e,t,n){for(n=n.child;n!==null;)kc(e,t,n),n=n.sibling}function kc(e,t,n){if(Ae&&typeof Ae.onCommitFiberUnmount=="function")try{Ae.onCommitFiberUnmount(gl,n)}catch{}switch(n.tag){case 5:oe||Zt(n,t);case 6:var r=ee,l=Te;ee=null,qe(e,t,n),ee=r,Te=l,ee!==null&&(Te?(e=ee,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):ee.removeChild(n.stateNode));break;case 18:ee!==null&&(Te?(e=ee,n=n.stateNode,e.nodeType===8?ql(e.parentNode,n):e.nodeType===1&&ql(e,n),Hn(e)):ql(ee,n.stateNode));break;case 4:r=ee,l=Te,ee=n.stateNode.containerInfo,Te=!0,qe(e,t,n),ee=r,Te=l;break;case 0:case 11:case 14:case 15:if(!oe&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){l=r=r.next;do{var o=l,i=o.destroy;o=o.tag,i!==void 0&&(o&2||o&4)&&Go(n,t,i),l=l.next}while(l!==r)}qe(e,t,n);break;case 1:if(!oe&&(Zt(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(u){V(n,t,u)}qe(e,t,n);break;case 21:qe(e,t,n);break;case 22:n.mode&1?(oe=(r=oe)||n.memoizedState!==null,qe(e,t,n),oe=r):qe(e,t,n);break;default:qe(e,t,n)}}function os(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new fp),t.forEach(function(r){var l=Sp.bind(null,e,r);n.has(r)||(n.add(r),r.then(l,l))})}}function Le(e,t){var n=t.deletions;if(n!==null)for(var r=0;rl&&(l=i),r&=~o}if(r=l,r=K()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*hp(r/1960))-r,10e?16:e,lt===null)var r=!1;else{if(e=lt,lt=null,dl=0,O&6)throw Error(S(331));var l=O;for(O|=4,N=e.current;N!==null;){var o=N,i=o.child;if(N.flags&16){var u=o.deletions;if(u!==null){for(var s=0;sK()-Qi?Pt(e,0):Hi|=n),me(e,t)}function Lc(e,t){t===0&&(e.mode&1?(t=xr,xr<<=1,!(xr&130023424)&&(xr=4194304)):t=1);var n=se();e=Ge(e,t),e!==null&&(or(e,t,n),me(e,n))}function wp(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Lc(e,n)}function Sp(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,l=e.memoizedState;l!==null&&(n=l.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(S(314))}r!==null&&r.delete(t),Lc(e,n)}var Rc;Rc=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||pe.current)de=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return de=!1,sp(e,t,n);de=!!(e.flags&131072)}else de=!1,$&&t.flags&1048576&&Ia(t,rl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Br(e,t),e=t.pendingProps;var l=on(t,ie.current);nn(t,n),l=Ui(null,t,r,e,l,n);var o=$i();return t.flags|=1,typeof l=="object"&&l!==null&&typeof l.render=="function"&&l.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,he(r)?(o=!0,tl(t)):o=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,Mi(t),l.updater=Cl,t.stateNode=l,l._reactInternals=t,Wo(t,r,e,n),t=Qo(null,t,r,!0,o,n)):(t.tag=0,$&&o&&_i(t),ue(null,t,l,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Br(e,t),e=t.pendingProps,l=r._init,r=l(r._payload),t.type=r,l=t.tag=Ep(r),e=Re(r,e),l){case 0:t=Ho(null,t,r,e,n);break e;case 1:t=es(null,t,r,e,n);break e;case 11:t=qu(null,t,r,e,n);break e;case 14:t=bu(null,t,r,Re(r.type,e),n);break e}throw Error(S(306,r,""))}return t;case 0:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Re(r,l),Ho(e,t,r,l,n);case 1:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Re(r,l),es(e,t,r,l,n);case 3:e:{if(hc(t),e===null)throw Error(S(387));r=t.pendingProps,o=t.memoizedState,l=o.element,Ba(e,t),il(t,r,null,n);var i=t.memoizedState;if(r=i.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:i.cache,pendingSuspenseBoundaries:i.pendingSuspenseBoundaries,transitions:i.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){l=cn(Error(S(423)),t),t=ts(e,t,r,n,l);break e}else if(r!==l){l=cn(Error(S(424)),t),t=ts(e,t,r,n,l);break e}else for(ge=at(t.stateNode.containerInfo.firstChild),ye=t,$=!0,Me=null,n=$a(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(un(),r===l){t=Ze(e,t,n);break e}ue(e,t,r,n)}t=t.child}return t;case 5:return Wa(t),e===null&&$o(t),r=t.type,l=t.pendingProps,o=e!==null?e.memoizedProps:null,i=l.children,Oo(r,l)?i=null:o!==null&&Oo(r,o)&&(t.flags|=32),pc(e,t),ue(e,t,i,n),t.child;case 6:return e===null&&$o(t),null;case 13:return mc(e,t,n);case 4:return Oi(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=sn(t,null,r,n):ue(e,t,r,n),t.child;case 11:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Re(r,l),qu(e,t,r,l,n);case 7:return ue(e,t,t.pendingProps,n),t.child;case 8:return ue(e,t,t.pendingProps.children,n),t.child;case 12:return ue(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,l=t.pendingProps,o=t.memoizedProps,i=l.value,D(ll,r._currentValue),r._currentValue=i,o!==null)if(De(o.value,i)){if(o.children===l.children&&!pe.current){t=Ze(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var u=o.dependencies;if(u!==null){i=o.child;for(var s=u.firstContext;s!==null;){if(s.context===r){if(o.tag===1){s=Ke(-1,n&-n),s.tag=2;var a=o.updateQueue;if(a!==null){a=a.shared;var h=a.pending;h===null?s.next=s:(s.next=h.next,h.next=s),a.pending=s}}o.lanes|=n,s=o.alternate,s!==null&&(s.lanes|=n),Ao(o.return,n,t),u.lanes|=n;break}s=s.next}}else if(o.tag===10)i=o.type===t.type?null:o.child;else if(o.tag===18){if(i=o.return,i===null)throw Error(S(341));i.lanes|=n,u=i.alternate,u!==null&&(u.lanes|=n),Ao(i,n,t),i=o.sibling}else i=o.child;if(i!==null)i.return=o;else for(i=o;i!==null;){if(i===t){i=null;break}if(o=i.sibling,o!==null){o.return=i.return,i=o;break}i=i.return}o=i}ue(e,t,l.children,n),t=t.child}return t;case 9:return l=t.type,r=t.pendingProps.children,nn(t,n),l=_e(l),r=r(l),t.flags|=1,ue(e,t,r,n),t.child;case 14:return r=t.type,l=Re(r,t.pendingProps),l=Re(r.type,l),bu(e,t,r,l,n);case 15:return fc(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Re(r,l),Br(e,t),t.tag=1,he(r)?(e=!0,tl(t)):e=!1,nn(t,n),sc(t,r,l),Wo(t,r,l,n),Qo(null,t,r,!0,e,n);case 19:return vc(e,t,n);case 22:return dc(e,t,n)}throw Error(S(156,t.tag))};function Tc(e,t){return oa(e,t)}function kp(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ce(e,t,n,r){return new kp(e,t,n,r)}function Gi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Ep(e){if(typeof e=="function")return Gi(e)?1:0;if(e!=null){if(e=e.$$typeof,e===hi)return 11;if(e===mi)return 14}return 2}function pt(e,t){var n=e.alternate;return n===null?(n=Ce(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Hr(e,t,n,r,l,o){var i=2;if(r=e,typeof e=="function")Gi(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case Bt:return jt(n.children,l,o,t);case pi:i=8,l|=8;break;case fo:return e=Ce(12,n,t,l|2),e.elementType=fo,e.lanes=o,e;case po:return e=Ce(13,n,t,l),e.elementType=po,e.lanes=o,e;case ho:return e=Ce(19,n,t,l),e.elementType=ho,e.lanes=o,e;case Ws:return Pl(n,l,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case As:i=10;break e;case Bs:i=9;break e;case hi:i=11;break e;case mi:i=14;break e;case be:i=16,r=null;break e}throw Error(S(130,e==null?e:typeof e,""))}return t=Ce(i,n,t,l),t.elementType=e,t.type=r,t.lanes=o,t}function jt(e,t,n,r){return e=Ce(7,e,r,t),e.lanes=n,e}function Pl(e,t,n,r){return e=Ce(22,e,r,t),e.elementType=Ws,e.lanes=n,e.stateNode={isHidden:!1},e}function io(e,t,n){return e=Ce(6,e,null,t),e.lanes=n,e}function uo(e,t,n){return t=Ce(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Cp(e,t,n,r,l){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Bl(0),this.expirationTimes=Bl(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Bl(0),this.identifierPrefix=r,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function Zi(e,t,n,r,l,o,i,u,s){return e=new Cp(e,t,n,u,s),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Ce(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Mi(o),e}function Np(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Dc)}catch(e){console.error(e)}}Dc(),Ds.exports=we;var Lp=Ds.exports,ps=Lp;ao.createRoot=ps.createRoot,ao.hydrateRoot=ps.hydrateRoot;/** + * @remix-run/router v1.23.2 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function nr(){return nr=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function eu(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Tp(){return Math.random().toString(36).substr(2,8)}function ms(e,t){return{usr:e.state,key:e.key,idx:t}}function ri(e,t,n,r){return n===void 0&&(n=null),nr({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?mn(t):t,{state:n,key:t&&t.key||r||Tp()})}function ml(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function mn(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Mp(e,t,n,r){r===void 0&&(r={});let{window:l=document.defaultView,v5Compat:o=!1}=r,i=l.history,u=ot.Pop,s=null,a=h();a==null&&(a=0,i.replaceState(nr({},i.state,{idx:a}),""));function h(){return(i.state||{idx:null}).idx}function p(){u=ot.Pop;let E=h(),f=E==null?null:E-a;a=E,s&&s({action:u,location:y.location,delta:f})}function m(E,f){u=ot.Push;let c=ri(y.location,E,f);a=h()+1;let d=ms(c,a),w=y.createHref(c);try{i.pushState(d,"",w)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;l.location.assign(w)}o&&s&&s({action:u,location:y.location,delta:1})}function g(E,f){u=ot.Replace;let c=ri(y.location,E,f);a=h();let d=ms(c,a),w=y.createHref(c);i.replaceState(d,"",w),o&&s&&s({action:u,location:y.location,delta:0})}function x(E){let f=l.location.origin!=="null"?l.location.origin:l.location.href,c=typeof E=="string"?E:ml(E);return c=c.replace(/ $/,"%20"),X(f,"No window.location.(origin|href) available to create URL for href: "+c),new URL(c,f)}let y={get action(){return u},get location(){return e(l,i)},listen(E){if(s)throw new Error("A history only accepts one active listener");return l.addEventListener(hs,p),s=E,()=>{l.removeEventListener(hs,p),s=null}},createHref(E){return t(l,E)},createURL:x,encodeLocation(E){let f=x(E);return{pathname:f.pathname,search:f.search,hash:f.hash}},push:m,replace:g,go(E){return i.go(E)}};return y}var vs;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(vs||(vs={}));function Op(e,t,n){return n===void 0&&(n="/"),Ip(e,t,n)}function Ip(e,t,n,r){let l=typeof t=="string"?mn(t):t,o=tu(l.pathname||"/",n);if(o==null)return null;let i=Fc(e);Dp(i);let u=null;for(let s=0;u==null&&s{let s={relativePath:u===void 0?o.path||"":u,caseSensitive:o.caseSensitive===!0,childrenIndex:i,route:o};s.relativePath.startsWith("/")&&(X(s.relativePath.startsWith(r),'Absolute route path "'+s.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),s.relativePath=s.relativePath.slice(r.length));let a=ht([r,s.relativePath]),h=n.concat(s);o.children&&o.children.length>0&&(X(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+a+'".')),Fc(o.children,t,h,a)),!(o.path==null&&!o.index)&&t.push({path:a,score:Vp(a,o.index),routesMeta:h})};return e.forEach((o,i)=>{var u;if(o.path===""||!((u=o.path)!=null&&u.includes("?")))l(o,i);else for(let s of Uc(o.path))l(o,i,s)}),t}function Uc(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,l=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return l?[o,""]:[o];let i=Uc(r.join("/")),u=[];return u.push(...i.map(s=>s===""?o:[o,s].join("/"))),l&&u.push(...i),u.map(s=>e.startsWith("/")&&s===""?"/":s)}function Dp(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Hp(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const Fp=/^:[\w-]+$/,Up=3,$p=2,Ap=1,Bp=10,Wp=-2,gs=e=>e==="*";function Vp(e,t){let n=e.split("/"),r=n.length;return n.some(gs)&&(r+=Wp),t&&(r+=$p),n.filter(l=>!gs(l)).reduce((l,o)=>l+(Fp.test(o)?Up:o===""?Ap:Bp),r)}function Hp(e,t){return e.length===t.length&&e.slice(0,-1).every((r,l)=>r===t[l])?e[e.length-1]-t[t.length-1]:0}function Qp(e,t,n){let{routesMeta:r}=e,l={},o="/",i=[];for(let u=0;u{let{paramName:m,isOptional:g}=h;if(m==="*"){let y=u[p]||"";i=o.slice(0,o.length-y.length).replace(/(.)\/+$/,"$1")}const x=u[p];return g&&!x?a[m]=void 0:a[m]=(x||"").replace(/%2F/g,"/"),a},{}),pathname:o,pathnameBase:i,pattern:e}}function Yp(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),eu(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],l="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(i,u,s)=>(r.push({paramName:u,isOptional:s!=null}),s?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),l+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?l+="\\/*$":e!==""&&e!=="/"&&(l+="(?:(?=\\/|$))"),[new RegExp(l,t?void 0:"i"),r]}function Xp(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return eu(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function tu(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}const Gp=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Zp=e=>Gp.test(e);function Jp(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:l=""}=typeof e=="string"?mn(e):e,o;if(n)if(Zp(n))o=n;else{if(n.includes("//")){let i=n;n=n.replace(/\/\/+/g,"/"),eu(!1,"Pathnames cannot have embedded double slashes - normalizing "+(i+" -> "+n))}n.startsWith("/")?o=ys(n.substring(1),"/"):o=ys(n,t)}else o=t;return{pathname:o,search:eh(r),hash:th(l)}}function ys(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(l=>{l===".."?n.length>1&&n.pop():l!=="."&&n.push(l)}),n.length>1?n.join("/"):"/"}function so(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function qp(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function $c(e,t){let n=qp(e);return t?n.map((r,l)=>l===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Ac(e,t,n,r){r===void 0&&(r=!1);let l;typeof e=="string"?l=mn(e):(l=nr({},e),X(!l.pathname||!l.pathname.includes("?"),so("?","pathname","search",l)),X(!l.pathname||!l.pathname.includes("#"),so("#","pathname","hash",l)),X(!l.search||!l.search.includes("#"),so("#","search","hash",l)));let o=e===""||l.pathname==="",i=o?"/":l.pathname,u;if(i==null)u=n;else{let p=t.length-1;if(!r&&i.startsWith("..")){let m=i.split("/");for(;m[0]==="..";)m.shift(),p-=1;l.pathname=m.join("/")}u=p>=0?t[p]:"/"}let s=Jp(l,u),a=i&&i!=="/"&&i.endsWith("/"),h=(o||i===".")&&n.endsWith("/");return!s.pathname.endsWith("/")&&(a||h)&&(s.pathname+="/"),s}const ht=e=>e.join("/").replace(/\/\/+/g,"/"),bp=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),eh=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,th=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function nh(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Bc=["post","put","patch","delete"];new Set(Bc);const rh=["get",...Bc];new Set(rh);/** + * React Router v6.30.3 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function rr(){return rr=Object.assign?Object.assign.bind():function(e){for(var t=1;t{u.current=!0}),k.useCallback(function(a,h){if(h===void 0&&(h={}),!u.current)return;if(typeof a=="number"){r.go(a);return}let p=Ac(a,JSON.parse(i),o,h.relative==="path");e==null&&t!=="/"&&(p.pathname=p.pathname==="/"?t:ht([t,p.pathname])),(h.replace?r.replace:r.push)(p,h.state,h)},[t,r,i,o,e])}function Hc(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=k.useContext(Dt),{matches:l}=k.useContext(Ft),{pathname:o}=cr(),i=JSON.stringify($c(l,r.v7_relativeSplatPath));return k.useMemo(()=>Ac(e,JSON.parse(i),o,n==="path"),[e,i,o,n])}function sh(e,t){return ah(e,t)}function ah(e,t,n,r){ar()||X(!1);let{navigator:l}=k.useContext(Dt),{matches:o}=k.useContext(Ft),i=o[o.length-1],u=i?i.params:{};i&&i.pathname;let s=i?i.pathnameBase:"/";i&&i.route;let a=cr(),h;if(t){var p;let E=typeof t=="string"?mn(t):t;s==="/"||(p=E.pathname)!=null&&p.startsWith(s)||X(!1),h=E}else h=a;let m=h.pathname||"/",g=m;if(s!=="/"){let E=s.replace(/^\//,"").split("/");g="/"+m.replace(/^\//,"").split("/").slice(E.length).join("/")}let x=Op(e,{pathname:g}),y=hh(x&&x.map(E=>Object.assign({},E,{params:Object.assign({},u,E.params),pathname:ht([s,l.encodeLocation?l.encodeLocation(E.pathname).pathname:E.pathname]),pathnameBase:E.pathnameBase==="/"?s:ht([s,l.encodeLocation?l.encodeLocation(E.pathnameBase).pathname:E.pathnameBase])})),o,n,r);return t&&y?k.createElement(Tl.Provider,{value:{location:rr({pathname:"/",search:"",hash:"",state:null,key:"default"},h),navigationType:ot.Pop}},y):y}function ch(){let e=yh(),t=nh(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,l={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return k.createElement(k.Fragment,null,k.createElement("h2",null,"Unexpected Application Error!"),k.createElement("h3",{style:{fontStyle:"italic"}},t),n?k.createElement("pre",{style:l},n):null,null)}const fh=k.createElement(ch,null);class dh extends k.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?k.createElement(Ft.Provider,{value:this.props.routeContext},k.createElement(Wc.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function ph(e){let{routeContext:t,match:n,children:r}=e,l=k.useContext(nu);return l&&l.static&&l.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(l.staticContext._deepestRenderedBoundaryId=n.route.id),k.createElement(Ft.Provider,{value:t},r)}function hh(e,t,n,r){var l;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var o;if(!n)return null;if(n.errors)e=n.matches;else if((o=r)!=null&&o.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let i=e,u=(l=n)==null?void 0:l.errors;if(u!=null){let h=i.findIndex(p=>p.route.id&&(u==null?void 0:u[p.route.id])!==void 0);h>=0||X(!1),i=i.slice(0,Math.min(i.length,h+1))}let s=!1,a=-1;if(n&&r&&r.v7_partialHydration)for(let h=0;h=0?i=i.slice(0,a+1):i=[i[0]];break}}}return i.reduceRight((h,p,m)=>{let g,x=!1,y=null,E=null;n&&(g=u&&p.route.id?u[p.route.id]:void 0,y=p.route.errorElement||fh,s&&(a<0&&m===0?(wh("route-fallback"),x=!0,E=null):a===m&&(x=!0,E=p.route.hydrateFallbackElement||null)));let f=t.concat(i.slice(0,m+1)),c=()=>{let d;return g?d=y:x?d=E:p.route.Component?d=k.createElement(p.route.Component,null):p.route.element?d=p.route.element:d=h,k.createElement(ph,{match:p,routeContext:{outlet:h,matches:f,isDataRoute:n!=null},children:d})};return n&&(p.route.ErrorBoundary||p.route.errorElement||m===0)?k.createElement(dh,{location:n.location,revalidation:n.revalidation,component:y,error:g,children:c(),routeContext:{outlet:null,matches:f,isDataRoute:!0}}):c()},null)}var Qc=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Qc||{}),Kc=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Kc||{});function mh(e){let t=k.useContext(nu);return t||X(!1),t}function vh(e){let t=k.useContext(lh);return t||X(!1),t}function gh(e){let t=k.useContext(Ft);return t||X(!1),t}function Yc(e){let t=gh(),n=t.matches[t.matches.length-1];return n.route.id||X(!1),n.route.id}function yh(){var e;let t=k.useContext(Wc),n=vh(),r=Yc();return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function xh(){let{router:e}=mh(Qc.UseNavigateStable),t=Yc(Kc.UseNavigateStable),n=k.useRef(!1);return Vc(()=>{n.current=!0}),k.useCallback(function(l,o){o===void 0&&(o={}),n.current&&(typeof l=="number"?e.navigate(l):e.navigate(l,rr({fromRouteId:t},o)))},[e,t])}const xs={};function wh(e,t,n){xs[e]||(xs[e]=!0)}function Sh(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function $t(e){X(!1)}function kh(e){let{basename:t="/",children:n=null,location:r,navigationType:l=ot.Pop,navigator:o,static:i=!1,future:u}=e;ar()&&X(!1);let s=t.replace(/^\/*/,"/"),a=k.useMemo(()=>({basename:s,navigator:o,static:i,future:rr({v7_relativeSplatPath:!1},u)}),[s,u,o,i]);typeof r=="string"&&(r=mn(r));let{pathname:h="/",search:p="",hash:m="",state:g=null,key:x="default"}=r,y=k.useMemo(()=>{let E=tu(h,s);return E==null?null:{location:{pathname:E,search:p,hash:m,state:g,key:x},navigationType:l}},[s,h,p,m,g,x,l]);return y==null?null:k.createElement(Dt.Provider,{value:a},k.createElement(Tl.Provider,{children:n,value:y}))}function Eh(e){let{children:t,location:n}=e;return sh(li(t),n)}new Promise(()=>{});function li(e,t){t===void 0&&(t=[]);let n=[];return k.Children.forEach(e,(r,l)=>{if(!k.isValidElement(r))return;let o=[...t,l];if(r.type===k.Fragment){n.push.apply(n,li(r.props.children,o));return}r.type!==$t&&X(!1),!r.props.index||!r.props.children||X(!1);let i={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(i.children=li(r.props.children,o)),n.push(i)}),n}/** + * React Router DOM v6.30.3 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function oi(){return oi=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[l]=e[l]);return n}function Nh(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function _h(e,t){return e.button===0&&(!t||t==="_self")&&!Nh(e)}const Ph=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],jh="6";try{window.__reactRouterVersion=jh}catch{}const zh="startTransition",ws=xf[zh];function Lh(e){let{basename:t,children:n,future:r,window:l}=e,o=k.useRef();o.current==null&&(o.current=Rp({window:l,v5Compat:!0}));let i=o.current,[u,s]=k.useState({action:i.action,location:i.location}),{v7_startTransition:a}=r||{},h=k.useCallback(p=>{a&&ws?ws(()=>s(p)):s(p)},[s,a]);return k.useLayoutEffect(()=>i.listen(h),[i,h]),k.useEffect(()=>Sh(r),[r]),k.createElement(kh,{basename:t,children:n,location:u.location,navigationType:u.action,navigator:i,future:r})}const Rh=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Th=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Mh=k.forwardRef(function(t,n){let{onClick:r,relative:l,reloadDocument:o,replace:i,state:u,target:s,to:a,preventScrollReset:h,viewTransition:p}=t,m=Ch(t,Ph),{basename:g}=k.useContext(Dt),x,y=!1;if(typeof a=="string"&&Th.test(a)&&(x=a,Rh))try{let d=new URL(window.location.href),w=a.startsWith("//")?new URL(d.protocol+a):new URL(a),C=tu(w.pathname,g);w.origin===d.origin&&C!=null?a=C+w.search+w.hash:y=!0}catch{}let E=oh(a,{relative:l}),f=Oh(a,{replace:i,state:u,target:s,preventScrollReset:h,relative:l,viewTransition:p});function c(d){r&&r(d),d.defaultPrevented||f(d)}return k.createElement("a",oi({},m,{href:x||E,onClick:y||o?r:c,ref:n,target:s}))});var Ss;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Ss||(Ss={}));var ks;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(ks||(ks={}));function Oh(e,t){let{target:n,replace:r,state:l,preventScrollReset:o,relative:i,viewTransition:u}=t===void 0?{}:t,s=ih(),a=cr(),h=Hc(e,{relative:i});return k.useCallback(p=>{if(_h(p,n)){p.preventDefault();let m=r!==void 0?r:ml(a)===ml(h);s(e,{replace:m,state:l,preventScrollReset:o,relative:i,viewTransition:u})}},[a,s,h,r,l,n,e,o,i,u])}/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Ih=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Xc=(...e)=>e.filter((t,n,r)=>!!t&&r.indexOf(t)===n).join(" ");/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */var Dh={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.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Fh=k.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:l="",children:o,iconNode:i,...u},s)=>k.createElement("svg",{ref:s,...Dh,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Xc("lucide",l),...u},[...i.map(([a,h])=>k.createElement(a,h)),...Array.isArray(o)?o:[o]]));/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const je=(e,t)=>{const n=k.forwardRef(({className:r,...l},o)=>k.createElement(Fh,{ref:o,iconNode:t,className:Xc(`lucide-${Ih(e)}`,r),...l}));return n.displayName=`${e}`,n};/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Uh=je("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Gc=je("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const $h=je("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Ah=je("CircleCheckBig",[["path",{d:"M22 11.08V12a10 10 0 1 1-5.93-9.14",key:"g774vq"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Zc=je("Cloud",[["path",{d:"M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z",key:"p7xjir"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Bh=je("Cpu",[["rect",{width:"16",height:"16",x:"4",y:"4",rx:"2",key:"14l7u7"}],["rect",{width:"6",height:"6",x:"9",y:"9",rx:"1",key:"5aljv4"}],["path",{d:"M15 2v2",key:"13l42r"}],["path",{d:"M15 20v2",key:"15mkzm"}],["path",{d:"M2 15h2",key:"1gxd5l"}],["path",{d:"M2 9h2",key:"1bbxkp"}],["path",{d:"M20 15h2",key:"19e6y8"}],["path",{d:"M20 9h2",key:"19tzq7"}],["path",{d:"M9 2v2",key:"165o2o"}],["path",{d:"M9 20v2",key:"i2bqo8"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Wh=je("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Vh=je("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Hh=je("MapPin",[["path",{d:"M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z",key:"2oe9fu"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ru=je("Radio",[["path",{d:"M4.9 19.1C1 15.2 1 8.8 4.9 4.9",key:"1vaf9d"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5",key:"u1ii0m"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5",key:"1j5fej"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19",key:"10b0cb"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Jc=je("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/** + * @license lucide-react v0.383.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Qh=je("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);async function fr(e){const t=await fetch(e);if(!t.ok)throw new Error(`API error: ${t.status} ${t.statusText}`);return t.json()}async function Es(){return fr("/api/status")}async function Kh(){return fr("/api/health")}async function Yh(){return fr("/api/sources")}async function Xh(){return fr("/api/alerts/active")}async function Gh(){return fr("/api/env/status")}function qc(){const[e,t]=k.useState(!1),[n,r]=k.useState(null),[l,o]=k.useState(null),i=k.useRef(null),u=k.useRef(null),s=k.useRef(1e3),a=k.useCallback(()=>{var m;if(((m=i.current)==null?void 0:m.readyState)===WebSocket.OPEN)return;const p=`${window.location.protocol==="https:"?"wss:":"ws:"}//${window.location.host}/ws/live`;try{const g=new WebSocket(p);i.current=g,g.onopen=()=>{t(!0),s.current=1e3},g.onmessage=y=>{try{const E=JSON.parse(y.data);switch(E.type){case"health_update":r(E.data);break;case"alert_fired":o(E.data);break}}catch(E){console.error("Failed to parse WebSocket message:",E)}},g.onclose=()=>{t(!1),i.current=null;const y=Math.min(s.current,3e4);u.current=window.setTimeout(()=>{s.current=Math.min(y*2,3e4),a()},y)},g.onerror=()=>{g.close()};const x=setInterval(()=>{g.readyState===WebSocket.OPEN&&g.send("ping")},3e4);g.addEventListener("close",()=>{clearInterval(x)})}catch(g){console.error("Failed to create WebSocket:",g)}},[]);return k.useEffect(()=>(a(),()=>{u.current&&clearTimeout(u.current),i.current&&i.current.close()}),[a]),{connected:e,lastHealth:n,lastAlert:l}}const bc=[{path:"/",label:"Dashboard",icon:Vh},{path:"/mesh",label:"Mesh",icon:ru},{path:"/environment",label:"Environment",icon:Zc},{path:"/config",label:"Config",icon:Jc},{path:"/alerts",label:"Alerts",icon:Gc}];function Zh(e){const t=Math.floor(e/86400),n=Math.floor(e%86400/3600),r=Math.floor(e%3600/60);return t>0?`${t}d ${n}h`:n>0?`${n}h ${r}m`:`${r}m`}function Jh(e){const t=bc.find(n=>n.path===e);return(t==null?void 0:t.label)||"Dashboard"}function qh({children:e}){var s;const t=cr(),{connected:n}=qc(),[r,l]=k.useState(null),[o,i]=k.useState(new Date);k.useEffect(()=>{Es().then(l).catch(console.error);const a=setInterval(()=>{Es().then(l).catch(console.error)},3e4);return()=>clearInterval(a)},[]),k.useEffect(()=>{const a=setInterval(()=>i(new Date),1e3);return()=>clearInterval(a)},[]);const u=o.toLocaleTimeString("en-US",{hour12:!1,hour:"2-digit",minute:"2-digit",second:"2-digit"});return v.jsxs("div",{className:"flex h-screen overflow-hidden bg-bg text-slate-200",children:[v.jsxs("aside",{className:"w-[220px] flex-shrink-0 bg-bg-card border-r border-border flex flex-col overflow-y-auto",children:[v.jsx("div",{className:"p-5 border-b border-border",children:v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsx("div",{className:"w-10 h-10 rounded-lg bg-gradient-to-br from-blue-500 to-blue-700 flex items-center justify-center text-white font-bold text-xl",children:"M"}),v.jsxs("div",{children:[v.jsx("div",{className:"font-semibold text-lg",children:"MeshAI"}),v.jsxs("div",{className:"text-xs text-slate-500 font-mono",children:["v",(r==null?void 0:r.version)||"..."]})]})]})}),v.jsx("nav",{className:"flex-1 py-4",children:bc.map(a=>{const h=t.pathname===a.path,p=a.icon;return v.jsxs(Mh,{to:a.path,className:`flex items-center gap-3 px-5 py-3 text-sm transition-colors relative ${h?"text-blue-400 bg-blue-500/10":"text-slate-400 hover:text-slate-200 hover:bg-bg-hover"}`,children:[h&&v.jsx("div",{className:"absolute left-0 top-0 bottom-0 w-0.5 bg-blue-500"}),v.jsx(p,{size:18}),a.label]},a.path)})}),v.jsxs("div",{className:"p-5 border-t border-border",children:[v.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[v.jsx("div",{className:`w-2 h-2 rounded-full ${r!=null&&r.connected?"bg-green-500":"bg-red-500"}`}),v.jsx("span",{className:"text-xs text-slate-400",children:r!=null&&r.connected?"Connected":"Disconnected"})]}),v.jsxs("div",{className:"text-xs text-slate-500 font-mono truncate",children:[(s=r==null?void 0:r.connection_type)==null?void 0:s.toUpperCase(),": ",r==null?void 0:r.connection_target]}),v.jsxs("div",{className:"text-xs text-slate-500 mt-1",children:["Uptime: ",r?Zh(r.uptime_seconds):"..."]})]})]}),v.jsxs("div",{className:"flex-1 flex flex-col overflow-hidden",children:[v.jsxs("header",{className:"h-14 flex-shrink-0 border-b border-border bg-bg-card flex items-center justify-between px-6",children:[v.jsx("h1",{className:"text-lg font-semibold",children:Jh(t.pathname)}),v.jsxs("div",{className:"flex items-center gap-6",children:[v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:`w-2 h-2 rounded-full ${n?"bg-green-500 animate-pulse-slow":"bg-slate-500"}`}),v.jsx("span",{className:"text-xs text-slate-400",children:n?"Live":"Offline"})]}),v.jsxs("div",{className:"text-sm font-mono text-slate-400",children:[u," MT"]})]})]}),v.jsx("main",{className:"flex-1 overflow-y-auto p-6",children:e})]})]})}function bh({health:e}){const t=e.score,n=e.tier,l=(u=>u>=80?"#22c55e":u>=60?"#f59e0b":"#ef4444")(t),o=2*Math.PI*45,i=t/100*o;return v.jsx("div",{className:"flex flex-col items-center",children:v.jsxs("svg",{width:"140",height:"140",viewBox:"0 0 100 100",children:[v.jsx("circle",{cx:"50",cy:"50",r:"45",fill:"none",stroke:"#1e2a3a",strokeWidth:"8"}),v.jsx("circle",{cx:"50",cy:"50",r:"45",fill:"none",stroke:l,strokeWidth:"8",strokeLinecap:"round",strokeDasharray:o,strokeDashoffset:o-i,transform:"rotate(-90 50 50)",className:"transition-all duration-500"}),v.jsx("text",{x:"50",y:"46",textAnchor:"middle",className:"fill-slate-100 font-mono text-2xl font-bold",style:{fontSize:"24px"},children:t.toFixed(1)}),v.jsx("text",{x:"50",y:"62",textAnchor:"middle",className:"fill-slate-400 text-xs",style:{fontSize:"10px"},children:n})]})})}function Rr({label:e,value:t}){const n=r=>r>=80?"bg-green-500":r>=60?"bg-amber-500":"bg-red-500";return v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsx("div",{className:"w-24 text-xs text-slate-400 truncate",children:e}),v.jsx("div",{className:"flex-1 h-2 bg-border rounded-full overflow-hidden",children:v.jsx("div",{className:`h-full ${n(t)} transition-all duration-300`,style:{width:`${t}%`}})}),v.jsx("div",{className:"w-12 text-right text-xs font-mono text-slate-300",children:t.toFixed(1)})]})}function em({alert:e}){const n=(l=>{switch(l.toLowerCase()){case"critical":case"emergency":return{bg:"bg-red-500/10",border:"border-red-500",icon:$h,iconColor:"text-red-500"};case"warning":return{bg:"bg-amber-500/10",border:"border-amber-500",icon:Qh,iconColor:"text-amber-500"};default:return{bg:"bg-green-500/10",border:"border-green-500",icon:Wh,iconColor:"text-green-500"}}})(e.severity),r=n.icon;return v.jsxs("div",{className:`p-3 rounded-lg ${n.bg} border-l-2 ${n.border} flex items-start gap-3`,children:[v.jsx(r,{size:16,className:n.iconColor}),v.jsxs("div",{className:"flex-1 min-w-0",children:[v.jsx("div",{className:"text-sm text-slate-200",children:e.message}),v.jsx("div",{className:"text-xs text-slate-500 mt-1",children:e.timestamp||"Just now"})]})]})}function tm({source:e}){const t=()=>e.is_loaded?e.last_error?"bg-amber-500":"bg-green-500":"bg-red-500";return v.jsxs("div",{className:"flex items-center gap-3 p-3 rounded-lg bg-bg-hover",children:[v.jsx("div",{className:`w-2 h-2 rounded-full ${t()}`}),v.jsxs("div",{className:"flex-1 min-w-0",children:[v.jsx("div",{className:"text-sm text-slate-200 truncate",children:e.name}),v.jsxs("div",{className:"text-xs text-slate-500",children:[e.node_count," nodes • ",e.type]})]})]})}function Tr({icon:e,label:t,value:n,subvalue:r}){return v.jsxs("div",{className:"bg-bg-card border border-border rounded-lg p-4",children:[v.jsxs("div",{className:"flex items-center gap-2 text-slate-400 mb-2",children:[v.jsx(e,{size:14}),v.jsx("span",{className:"text-xs",children:t})]}),v.jsx("div",{className:"font-mono text-xl text-slate-100",children:n}),r&&v.jsx("div",{className:"text-xs text-slate-500 mt-1",children:r})]})}function nm(){var g;const[e,t]=k.useState(null),[n,r]=k.useState([]),[l,o]=k.useState([]),[i,u]=k.useState(null),[s,a]=k.useState(!0),[h,p]=k.useState(null),{lastHealth:m}=qc();return k.useEffect(()=>{Promise.all([Kh(),Yh(),Xh(),Gh()]).then(([x,y,E,f])=>{t(x),r(y),o(E),u(f),a(!1)}).catch(x=>{p(x.message),a(!1)})},[]),k.useEffect(()=>{m&&t(m)},[m]),s?v.jsx("div",{className:"flex items-center justify-center h-64",children:v.jsx("div",{className:"text-slate-400",children:"Loading..."})}):h?v.jsx("div",{className:"flex items-center justify-center h-64",children:v.jsxs("div",{className:"text-red-400",children:["Error: ",h]})}):v.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[v.jsxs("div",{className:"bg-bg-card border border-border rounded-lg p-6",children:[v.jsx("h2",{className:"text-sm font-medium text-slate-400 mb-4",children:"Mesh Health"}),e&&v.jsxs(v.Fragment,{children:[v.jsx(bh,{health:e}),v.jsxs("div",{className:"mt-6 space-y-3",children:[v.jsx(Rr,{label:"Infrastructure",value:e.pillars.infrastructure}),v.jsx(Rr,{label:"Utilization",value:e.pillars.utilization}),v.jsx(Rr,{label:"Behavior",value:e.pillars.behavior}),v.jsx(Rr,{label:"Power",value:e.pillars.power})]})]})]}),v.jsxs("div",{className:"lg:col-span-2 space-y-6",children:[v.jsxs("div",{className:"bg-bg-card border border-border rounded-lg p-6",children:[v.jsx("h2",{className:"text-sm font-medium text-slate-400 mb-4",children:"Active Alerts"}),l.length>0?v.jsx("div",{className:"space-y-3",children:l.map((x,y)=>v.jsx(em,{alert:x},y))}):v.jsxs("div",{className:"flex items-center gap-2 text-slate-500 py-4",children:[v.jsx(Ah,{size:16,className:"text-green-500"}),v.jsx("span",{children:"No active alerts"})]})]}),v.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-4",children:[v.jsx(Tr,{icon:ru,label:"Nodes Online",value:(e==null?void 0:e.total_nodes)||0,subvalue:`${(e==null?void 0:e.unlocated_count)||0} unlocated`}),v.jsx(Tr,{icon:Bh,label:"Infrastructure",value:`${(e==null?void 0:e.infra_online)||0}/${(e==null?void 0:e.infra_total)||0}`,subvalue:(e==null?void 0:e.infra_online)===(e==null?void 0:e.infra_total)?"All online":"Some offline"}),v.jsx(Tr,{icon:Uh,label:"Utilization",value:`${((g=e==null?void 0:e.util_percent)==null?void 0:g.toFixed(1))||0}%`,subvalue:`${(e==null?void 0:e.flagged_nodes)||0} flagged`}),v.jsx(Tr,{icon:Hh,label:"Regions",value:(e==null?void 0:e.total_regions)||0,subvalue:`${(e==null?void 0:e.battery_warnings)||0} battery warnings`})]})]}),v.jsxs("div",{className:"bg-bg-card border border-border rounded-lg p-6",children:[v.jsxs("h2",{className:"text-sm font-medium text-slate-400 mb-4",children:["Mesh Sources (",n.length,")"]}),n.length>0?v.jsx("div",{className:"space-y-2",children:n.map((x,y)=>v.jsx(tm,{source:x},y))}):v.jsx("div",{className:"text-slate-500 py-4",children:"No sources configured"})]}),v.jsxs("div",{className:"bg-bg-card border border-border rounded-lg p-6",children:[v.jsx("h2",{className:"text-sm font-medium text-slate-400 mb-4",children:"Environmental Feeds"}),i!=null&&i.enabled?v.jsxs("div",{className:"text-slate-400",children:[i.feeds.length," feeds active"]}):v.jsxs("div",{className:"text-slate-500",children:[v.jsx("p",{children:"Environmental feeds not enabled."}),v.jsx("p",{className:"text-xs mt-2",children:"Enable in Config → Mesh Intelligence"})]})]}),v.jsxs("div",{className:"bg-bg-card border border-border rounded-lg p-6",children:[v.jsx("h2",{className:"text-sm font-medium text-slate-400 mb-4",children:"HF Propagation"}),v.jsxs("div",{className:"text-slate-500",children:[v.jsx("p",{children:"Space weather data not enabled."}),v.jsx("p",{className:"text-xs mt-2",children:"Coming in Phase 1"})]})]})]})}function rm(){return v.jsxs("div",{className:"flex flex-col items-center justify-center h-[60vh] text-center",children:[v.jsx("div",{className:"w-16 h-16 rounded-full bg-bg-card border border-border flex items-center justify-center mb-6",children:v.jsx(ru,{size:32,className:"text-slate-500"})}),v.jsx("h2",{className:"text-xl font-semibold text-slate-300 mb-2",children:"Mesh"}),v.jsx("p",{className:"text-slate-500 max-w-md",children:"Topology graph and geographic map coming in Phase 6"})]})}function lm(){return v.jsxs("div",{className:"flex flex-col items-center justify-center h-[60vh] text-center",children:[v.jsx("div",{className:"w-16 h-16 rounded-full bg-bg-card border border-border flex items-center justify-center mb-6",children:v.jsx(Zc,{size:32,className:"text-slate-500"})}),v.jsx("h2",{className:"text-xl font-semibold text-slate-300 mb-2",children:"Environment"}),v.jsx("p",{className:"text-slate-500 max-w-md",children:"Environmental feeds and space weather detail coming soon"})]})}function om(){return v.jsxs("div",{className:"flex flex-col items-center justify-center h-[60vh] text-center",children:[v.jsx("div",{className:"w-16 h-16 rounded-full bg-bg-card border border-border flex items-center justify-center mb-6",children:v.jsx(Jc,{size:32,className:"text-slate-500"})}),v.jsx("h2",{className:"text-xl font-semibold text-slate-300 mb-2",children:"Configuration"}),v.jsx("p",{className:"text-slate-500 max-w-md",children:"Configuration management coming in Phase 5"})]})}function im(){return v.jsxs("div",{className:"flex flex-col items-center justify-center h-[60vh] text-center",children:[v.jsx("div",{className:"w-16 h-16 rounded-full bg-bg-card border border-border flex items-center justify-center mb-6",children:v.jsx(Gc,{size:32,className:"text-slate-500"})}),v.jsx("h2",{className:"text-xl font-semibold text-slate-300 mb-2",children:"Alerts"}),v.jsx("p",{className:"text-slate-500 max-w-md",children:"Alert history and subscriptions coming in Phase 11"})]})}function um(){return v.jsx(qh,{children:v.jsxs(Eh,{children:[v.jsx($t,{path:"/",element:v.jsx(nm,{})}),v.jsx($t,{path:"/mesh",element:v.jsx(rm,{})}),v.jsx($t,{path:"/environment",element:v.jsx(lm,{})}),v.jsx($t,{path:"/config",element:v.jsx(om,{})}),v.jsx($t,{path:"/alerts",element:v.jsx(im,{})})]})})}ao.createRoot(document.getElementById("root")).render(v.jsx(Os.StrictMode,{children:v.jsx(Lh,{children:v.jsx(um,{})})})); diff --git a/meshai/dashboard/static/index.html b/meshai/dashboard/static/index.html index 35a3925..b94443a 100644 --- a/meshai/dashboard/static/index.html +++ b/meshai/dashboard/static/index.html @@ -1,20 +1,17 @@ - - - - MeshAI Dashboard - - - - -
-

MeshAI Dashboard

-

Frontend build pending - API is live.

- -
- - + + + + + + + MeshAI Dashboard + + + + + + + +
+ +