Add Network Management module with collapsible left nav.

Consolidate devices, topology, alarms, WebCRT, and collection tasks under /network; keep legacy path redirects and workbench entry.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
oliver 2026-07-31 09:48:31 +08:00
parent 3bd5d5b7da
commit 2fc47e5135
13 changed files with 595 additions and 182 deletions

View file

@ -0,0 +1,50 @@
/**
* Left-nav tree for the Network Management module.
* Add leaf items here when extending (devices / topology / alarms / tasks).
*/
export type NetworkNavGroupId = "detail" | "tasks";
export type NetworkNavItem = {
id: string;
path: string;
labelKey: string;
group: NetworkNavGroupId;
};
export type NetworkNavGroup = {
id: NetworkNavGroupId;
labelKey: string;
items: NetworkNavItem[];
};
export const NETWORK_NAV: readonly NetworkNavGroup[] = [
{
id: "detail",
labelKey: "network.nav.detail",
items: [
{ id: "devices", path: "/network/devices", labelKey: "network.nav.devices", group: "detail" },
{ id: "topology", path: "/network/topology", labelKey: "network.nav.topology", group: "detail" },
{ id: "alarms", path: "/network/alarms", labelKey: "network.nav.alarms", group: "detail" },
{ id: "webcrt", path: "/network/webcrt", labelKey: "network.nav.webcrt", group: "detail" },
],
},
{
id: "tasks",
labelKey: "network.nav.tasks",
items: [
{
id: "config-sync",
path: "/network/tasks/config-sync",
labelKey: "network.nav.configSync",
group: "tasks",
},
{
id: "port-traffic",
path: "/network/tasks/port-traffic",
labelKey: "network.nav.portTraffic",
group: "tasks",
},
],
},
] as const;