This commit is contained in:
lda
2026-04-12 02:41:36 +07:00 Unverified
parent 6e91d0b599
commit 34e40e8c0d
13 changed files with 399 additions and 132 deletions
+40
View File
@@ -0,0 +1,40 @@
import { NavLink, Outlet } from "react-router-dom";
const navItems = [
["/", "Dashboard"],
["/agents", "Agents"],
["/commands", "Commands"],
["/audit", "Audit"],
["/alerts", "Alerts"],
["/tokens", "Tokens"],
] as const;
export function AppLayout() {
return (
<div className="app">
<header className="topbar">
<div>
<h1>Wakey Operator UI</h1>
<p>Control-plane operations, audits, and live alerts</p>
</div>
</header>
<nav className="tabs">
{navItems.map(([to, label]) => (
<NavLink
key={to}
to={to}
end={to === "/"}
className={({ isActive }) => `tab ${isActive ? "active" : ""}`}
>
{label}
</NavLink>
))}
</nav>
<main>
<Outlet />
</main>
</div>
);
}