diff --git a/webui/src/features/ops/OpsPage.tsx b/webui/src/features/ops/OpsPage.tsx
index bd8b5dd..508f79a 100644
--- a/webui/src/features/ops/OpsPage.tsx
+++ b/webui/src/features/ops/OpsPage.tsx
@@ -3,13 +3,15 @@ import { RefreshCw } from "lucide-react";
import {
Button,
Card,
+ DataGrid,
DismissibleAlert,
LoadingFrame,
MetricCard,
PageTitle,
StatusBadge,
adminErrorMessage,
- type ApiSettings } from
+ type ApiSettings,
+ type DataGridColumn } from
"@govoplan/core-webui";
import { fetchOpsStatus, type OpsCheck, type OpsDeploymentProfile, type OpsSizingAssumption, type OpsStatus } from "../../api/ops";
@@ -95,47 +97,27 @@ function CheckList({ checks }: {checks: OpsCheck[];}) {
function ProfileList({ profiles }: {profiles: OpsDeploymentProfile[];}) {
if (!profiles.length) return
i18n:govoplan-ops.no_deployment_profiles_reported.7c3af1db
;
+ const columns: DataGridColumn[] = [
+ { id: "profile", header: "i18n:govoplan-ops.profile.ff4fc027", width: "minmax(220px, 1fr)", minWidth: 180, resizable: true, sortable: true, filterable: true, value: (profile) => `${profile.name} ${profile.id}`, render: (profile) => {profile.name}{profile.id}
},
+ { id: "status", header: "i18n:govoplan-ops.status.bae7d5be", width: 140, sortable: true, filterable: true, value: (profile) => profile.current ? "current" : "reference", render: (profile) => },
+ { id: "components", header: "i18n:govoplan-ops.components.9289473e", width: "minmax(220px, 1fr)", minWidth: 180, resizable: true, filterable: true, value: (profile) => profile.components.join(" "), render: (profile) => profile.components.join(", ") },
+ { id: "fit", header: "i18n:govoplan-ops.fit.dab564d8", width: "minmax(180px, .8fr)", minWidth: 160, resizable: true, filterable: true, value: (profile) => profile.fit }
+ ];
return (
-
-
-
- | i18n:govoplan-ops.profile.ff4fc027 | i18n:govoplan-ops.status.bae7d5be | i18n:govoplan-ops.components.9289473e | i18n:govoplan-ops.fit.dab564d8 |
-
-
- {profiles.map((profile) =>
-
- | {profile.name}{profile.id} |
- |
- {profile.components.join(", ")} |
- {profile.fit} |
-
- )}
-
-
-
);
+ profile.id} />);
}
function SizingTable({ items }: {items: OpsSizingAssumption[];}) {
if (!items.length) return i18n:govoplan-ops.no_sizing_assumptions_reported.17515959
;
+ const columns: DataGridColumn[] = [
+ { id: "area", header: "i18n:govoplan-ops.area.2745deba", width: "minmax(180px, .7fr)", minWidth: 160, resizable: true, sortable: true, filterable: true, value: (item) => item.area, render: (item) => {item.area} },
+ { id: "baseline", header: "i18n:govoplan-ops.baseline.e6ab7982", width: "minmax(220px, 1fr)", minWidth: 180, resizable: true, filterable: true, value: (item) => item.baseline },
+ { id: "trigger", header: "i18n:govoplan-ops.scale_trigger.1c85e10e", width: "minmax(220px, 1fr)", minWidth: 180, resizable: true, filterable: true, value: (item) => item.scale_trigger },
+ { id: "note", header: "i18n:govoplan-ops.operator_note.1dc58f7b", width: "minmax(240px, 1.2fr)", minWidth: 200, resizable: true, filterable: true, value: (item) => item.operator_note }
+ ];
return (
-
-
-
- | i18n:govoplan-ops.area.2745deba | i18n:govoplan-ops.baseline.e6ab7982 | i18n:govoplan-ops.scale_trigger.1c85e10e | i18n:govoplan-ops.operator_note.1dc58f7b |
-
-
- {items.map((item) =>
-
- | {item.area} |
- {item.baseline} |
- {item.scale_trigger} |
- {item.operator_note} |
-
- )}
-
-
-
);
+ item.area} />);
}