@burdenoff/microfe-semanticfed 2026.525.1 → 2026.829.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/dist/semanticfed/SemanticFedRoot.js +79 -74
  2. package/dist/semanticfed/SemanticFedRoot.js.map +1 -1
  3. package/dist/semanticfed/hooks/useTr.js +12 -0
  4. package/dist/semanticfed/hooks/useTr.js.map +1 -0
  5. package/dist/semanticfed/pages/AgentsPage.js +111 -97
  6. package/dist/semanticfed/pages/AgentsPage.js.map +1 -1
  7. package/dist/semanticfed/pages/AnalyticsPage.js +99 -100
  8. package/dist/semanticfed/pages/AnalyticsPage.js.map +1 -1
  9. package/dist/semanticfed/pages/AuditPage.js +83 -75
  10. package/dist/semanticfed/pages/AuditPage.js.map +1 -1
  11. package/dist/semanticfed/pages/CollaborationPage.js +71 -57
  12. package/dist/semanticfed/pages/CollaborationPage.js.map +1 -1
  13. package/dist/semanticfed/pages/ConfigurationPage.js +71 -64
  14. package/dist/semanticfed/pages/ConfigurationPage.js.map +1 -1
  15. package/dist/semanticfed/pages/DeploymentPage.js +73 -72
  16. package/dist/semanticfed/pages/DeploymentPage.js.map +1 -1
  17. package/dist/semanticfed/pages/KnowledgeGraphPage.js +102 -103
  18. package/dist/semanticfed/pages/KnowledgeGraphPage.js.map +1 -1
  19. package/dist/semanticfed/pages/PerformancePage.js +63 -68
  20. package/dist/semanticfed/pages/PerformancePage.js.map +1 -1
  21. package/dist/semanticfed/pages/PoliciesPage.js +116 -97
  22. package/dist/semanticfed/pages/PoliciesPage.js.map +1 -1
  23. package/dist/semanticfed/pages/ProtocolPage.js +74 -69
  24. package/dist/semanticfed/pages/ProtocolPage.js.map +1 -1
  25. package/dist/semanticfed/pages/TechStackPage.js +54 -46
  26. package/dist/semanticfed/pages/TechStackPage.js.map +1 -1
  27. package/dist/semanticfed/pages/TopologyPage.js +74 -78
  28. package/dist/semanticfed/pages/TopologyPage.js.map +1 -1
  29. package/dist/semanticfed/pages/VisualizationPage.js +119 -109
  30. package/dist/semanticfed/pages/VisualizationPage.js.map +1 -1
  31. package/package.json +1 -1
@@ -1,101 +1,100 @@
1
1
  import { useSemanticFedStore as e } from "../store/semanticfedStore.js";
2
- import { Gauge as t, Minus as n, TrendingDown as r, TrendingUp as i, Zap as a } from "lucide-react";
3
- import { jsx as o, jsxs as s } from "react/jsx-runtime";
4
- import { Badge as c, Card as l, CardContent as u, CardHeader as d, CardTitle as f } from "@burdenoff/fe-libs/ui";
2
+ import { useTr as t } from "../hooks/useTr.js";
3
+ import { Gauge as n, Minus as r, TrendingDown as i, TrendingUp as a, Zap as o } from "lucide-react";
4
+ import { jsx as s, jsxs as c } from "react/jsx-runtime";
5
+ import { Badge as l, Card as u, CardContent as d, CardHeader as f, CardTitle as p } from "@burdenoff/fe-libs/ui";
5
6
  //#region src/semanticfed/pages/PerformancePage.tsx
6
- var p = {
7
- improving: /* @__PURE__ */ o(i, { className: "h-3 w-3 text-emerald-500" }),
8
- degrading: /* @__PURE__ */ o(r, { className: "h-3 w-3 text-red-500" }),
9
- stable: /* @__PURE__ */ o(n, { className: "h-3 w-3 text-muted-foreground" })
10
- }, m = {
7
+ var m = {
8
+ improving: /* @__PURE__ */ s(a, { className: "h-3 w-3 text-emerald-500" }),
9
+ degrading: /* @__PURE__ */ s(i, { className: "h-3 w-3 text-red-500" }),
10
+ stable: /* @__PURE__ */ s(r, { className: "h-3 w-3 text-muted-foreground" })
11
+ }, h = {
11
12
  improving: "text-emerald-600",
12
13
  degrading: "text-red-600",
13
14
  stable: "text-muted-foreground"
14
15
  };
15
- function h() {
16
- let { performanceBenchmarks: h } = e(), g = [...new Set(h.map((e) => e.category))], _ = h.filter((e) => e.trend === "improving").length, v = h.filter((e) => e.trend === "degrading").length;
17
- return /* @__PURE__ */ s("div", {
16
+ function g() {
17
+ let g = t(), { performanceBenchmarks: _ } = e(), v = [...new Set(_.map((e) => e.category))], y = _.filter((e) => e.trend === "improving").length, b = _.filter((e) => e.trend === "degrading").length;
18
+ return /* @__PURE__ */ c("div", {
18
19
  className: "space-y-6 p-6",
19
20
  children: [
20
- /* @__PURE__ */ s("div", {
21
+ /* @__PURE__ */ c("div", {
21
22
  className: "flex items-center justify-between",
22
- children: [/* @__PURE__ */ s("div", { children: [/* @__PURE__ */ o("h1", {
23
+ children: [/* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("h1", {
23
24
  className: "text-2xl font-semibold",
24
- children: "Performance Metrics"
25
- }), /* @__PURE__ */ o("p", {
25
+ children: g("semanticfed.performance.title", "Performance Metrics")
26
+ }), /* @__PURE__ */ s("p", {
26
27
  className: "text-sm text-muted-foreground",
27
- children: "Benchmark tracking for query, ingestion, reasoning, and federation performance"
28
- })] }), /* @__PURE__ */ s(c, {
28
+ children: g("semanticfed.performance.description", "Benchmark tracking for query, ingestion, reasoning, and federation performance")
29
+ })] }), /* @__PURE__ */ c(l, {
29
30
  variant: "secondary",
30
31
  className: "gap-1",
31
32
  children: [
32
- /* @__PURE__ */ o(t, { className: "h-3 w-3" }),
33
+ /* @__PURE__ */ s(n, { className: "h-3 w-3" }),
33
34
  " ",
34
- h.length,
35
- " Benchmarks"
35
+ g("semanticfed.performance.badges.benchmarkCount", "{count} Benchmarks", { count: _.length })
36
36
  ]
37
37
  })]
38
38
  }),
39
- /* @__PURE__ */ s("div", {
39
+ /* @__PURE__ */ c("div", {
40
40
  className: "grid gap-4 md:grid-cols-3",
41
41
  children: [
42
- /* @__PURE__ */ o(l, { children: /* @__PURE__ */ s(u, {
42
+ /* @__PURE__ */ s(u, { children: /* @__PURE__ */ c(d, {
43
43
  className: "flex items-center gap-3 pt-4",
44
- children: [/* @__PURE__ */ o(i, { className: "h-5 w-5 text-emerald-500" }), /* @__PURE__ */ s("div", { children: [/* @__PURE__ */ o("p", {
44
+ children: [/* @__PURE__ */ s(a, { className: "h-5 w-5 text-emerald-500" }), /* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("p", {
45
45
  className: "text-2xl font-bold text-emerald-600",
46
- children: _
47
- }), /* @__PURE__ */ o("p", {
46
+ children: y
47
+ }), /* @__PURE__ */ s("p", {
48
48
  className: "text-xs text-muted-foreground",
49
- children: "Improving"
49
+ children: g("semanticfed.performance.kpis.improving", "Improving")
50
50
  })] })]
51
51
  }) }),
52
- /* @__PURE__ */ o(l, { children: /* @__PURE__ */ s(u, {
52
+ /* @__PURE__ */ s(u, { children: /* @__PURE__ */ c(d, {
53
53
  className: "flex items-center gap-3 pt-4",
54
- children: [/* @__PURE__ */ o(r, { className: "h-5 w-5 text-red-500" }), /* @__PURE__ */ s("div", { children: [/* @__PURE__ */ o("p", {
54
+ children: [/* @__PURE__ */ s(i, { className: "h-5 w-5 text-red-500" }), /* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("p", {
55
55
  className: "text-2xl font-bold text-red-600",
56
- children: v
57
- }), /* @__PURE__ */ o("p", {
56
+ children: b
57
+ }), /* @__PURE__ */ s("p", {
58
58
  className: "text-xs text-muted-foreground",
59
- children: "Degrading"
59
+ children: g("semanticfed.performance.kpis.degrading", "Degrading")
60
60
  })] })]
61
61
  }) }),
62
- /* @__PURE__ */ o(l, { children: /* @__PURE__ */ s(u, {
62
+ /* @__PURE__ */ s(u, { children: /* @__PURE__ */ c(d, {
63
63
  className: "flex items-center gap-3 pt-4",
64
- children: [/* @__PURE__ */ o(n, { className: "h-5 w-5 text-muted-foreground" }), /* @__PURE__ */ s("div", { children: [/* @__PURE__ */ o("p", {
64
+ children: [/* @__PURE__ */ s(r, { className: "h-5 w-5 text-muted-foreground" }), /* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("p", {
65
65
  className: "text-2xl font-bold",
66
- children: h.length - _ - v
67
- }), /* @__PURE__ */ o("p", {
66
+ children: _.length - y - b
67
+ }), /* @__PURE__ */ s("p", {
68
68
  className: "text-xs text-muted-foreground",
69
- children: "Stable"
69
+ children: g("semanticfed.performance.kpis.stable", "Stable")
70
70
  })] })]
71
71
  }) })
72
72
  ]
73
73
  }),
74
- g.map((e) => /* @__PURE__ */ s(l, { children: [/* @__PURE__ */ o(d, { children: /* @__PURE__ */ s(f, {
74
+ v.map((e) => /* @__PURE__ */ c(u, { children: [/* @__PURE__ */ s(f, { children: /* @__PURE__ */ c(p, {
75
75
  className: "flex items-center gap-2 text-base capitalize",
76
76
  children: [
77
- /* @__PURE__ */ o(a, { className: "h-4 w-4" }),
77
+ /* @__PURE__ */ s(o, { className: "h-4 w-4" }),
78
78
  " ",
79
- e,
80
- " Performance"
79
+ g("semanticfed.performance.benchmark.title", "{category} Performance", { category: e })
81
80
  ]
82
- }) }), /* @__PURE__ */ o(u, {
81
+ }) }), /* @__PURE__ */ s(d, {
83
82
  className: "space-y-4",
84
- children: h.filter((t) => t.category === e).map((e) => {
83
+ children: _.filter((t) => t.category === e).map((e) => {
85
84
  let t = (e.currentValue - e.baselineValue) / e.baselineValue * 100, n = e.unit === "ms" || e.unit === "avg endpoints" ? e.currentValue < e.baselineValue : e.currentValue > e.baselineValue;
86
- return /* @__PURE__ */ s("div", {
85
+ return /* @__PURE__ */ c("div", {
87
86
  className: "space-y-1",
88
- children: [/* @__PURE__ */ s("div", {
87
+ children: [/* @__PURE__ */ c("div", {
89
88
  className: "flex items-center justify-between",
90
- children: [/* @__PURE__ */ s("div", {
89
+ children: [/* @__PURE__ */ c("div", {
91
90
  className: "flex items-center gap-2",
92
- children: [/* @__PURE__ */ o("span", {
91
+ children: [/* @__PURE__ */ s("span", {
93
92
  className: "text-sm font-medium",
94
93
  children: e.name
95
- }), p[e.trend]]
96
- }), /* @__PURE__ */ s("div", {
94
+ }), m[e.trend]]
95
+ }), /* @__PURE__ */ c("div", {
97
96
  className: "flex items-center gap-3",
98
- children: [/* @__PURE__ */ s("span", {
97
+ children: [/* @__PURE__ */ c("span", {
99
98
  className: "text-sm font-bold",
100
99
  children: [
101
100
  e.currentValue.toLocaleString(),
@@ -103,38 +102,34 @@ function h() {
103
102
  e.unit
104
103
  ]
105
104
  }), /* @__PURE__ */ s("span", {
106
- className: `text-xs ${m[e.trend]}`,
107
- children: [
108
- "(",
109
- t > 0 ? "+" : "",
110
- t.toFixed(1),
111
- "% vs baseline)"
112
- ]
105
+ className: `text-xs ${h[e.trend]}`,
106
+ children: g("semanticfed.performance.benchmark.vsBaseline", "({sign}{percent}% vs baseline)", {
107
+ sign: t > 0 ? "+" : "",
108
+ percent: t.toFixed(1)
109
+ })
113
110
  })]
114
111
  })]
115
- }), /* @__PURE__ */ s("div", {
112
+ }), /* @__PURE__ */ c("div", {
116
113
  className: "flex items-center gap-2",
117
114
  children: [
118
115
  /* @__PURE__ */ s("span", {
119
116
  className: "text-xs text-muted-foreground",
120
- children: [
121
- "Baseline: ",
122
- e.baselineValue.toLocaleString(),
123
- " ",
124
- e.unit
125
- ]
117
+ children: g("semanticfed.performance.benchmark.baseline", "Baseline: {value} {unit}", {
118
+ value: e.baselineValue.toLocaleString(),
119
+ unit: e.unit
120
+ })
126
121
  }),
127
- /* @__PURE__ */ o("div", {
122
+ /* @__PURE__ */ s("div", {
128
123
  className: "flex-1",
129
- children: /* @__PURE__ */ o("div", {
124
+ children: /* @__PURE__ */ s("div", {
130
125
  className: "h-2 rounded bg-muted",
131
- children: /* @__PURE__ */ o("div", {
126
+ children: /* @__PURE__ */ s("div", {
132
127
  className: `h-2 rounded ${n ? "bg-emerald-500" : "bg-amber-500"}`,
133
128
  style: { width: `${Math.min(e.currentValue / (e.baselineValue * 1.5) * 100, 100)}%` }
134
129
  })
135
130
  })
136
131
  }),
137
- /* @__PURE__ */ o("span", {
132
+ /* @__PURE__ */ s("span", {
138
133
  className: "text-xs text-muted-foreground",
139
134
  children: e.lastMeasuredAt
140
135
  })
@@ -147,6 +142,6 @@ function h() {
147
142
  });
148
143
  }
149
144
  //#endregion
150
- export { h as PerformancePage };
145
+ export { g as PerformancePage };
151
146
 
152
147
  //# sourceMappingURL=PerformancePage.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PerformancePage.js","names":[],"sources":["../../../src/semanticfed/pages/PerformancePage.tsx"],"sourcesContent":["import { Badge, Card, CardContent, CardHeader, CardTitle } from '@burdenoff/fe-libs/ui';\nimport { Gauge, TrendingUp, TrendingDown, Minus, Zap } from 'lucide-react';\nimport { useSemanticFedStore } from '../store/semanticfedStore';\n\nconst trendIcons: Record<string, React.ReactNode> = {\n improving: <TrendingUp className=\"h-3 w-3 text-emerald-500\" />,\n degrading: <TrendingDown className=\"h-3 w-3 text-red-500\" />,\n stable: <Minus className=\"h-3 w-3 text-muted-foreground\" />,\n};\n\nconst trendColors: Record<string, string> = {\n improving: 'text-emerald-600',\n degrading: 'text-red-600',\n stable: 'text-muted-foreground',\n};\n\nexport function PerformancePage() {\n const { performanceBenchmarks } = useSemanticFedStore();\n\n const categories = [...new Set(performanceBenchmarks.map((b) => b.category))];\n const improvingCount = performanceBenchmarks.filter((b) => b.trend === 'improving').length;\n const degradingCount = performanceBenchmarks.filter((b) => b.trend === 'degrading').length;\n\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"flex items-center justify-between\">\n <div>\n <h1 className=\"text-2xl font-semibold\">Performance Metrics</h1>\n <p className=\"text-sm text-muted-foreground\">\n Benchmark tracking for query, ingestion, reasoning, and federation performance\n </p>\n </div>\n <Badge variant=\"secondary\" className=\"gap-1\">\n <Gauge className=\"h-3 w-3\" /> {performanceBenchmarks.length} Benchmarks\n </Badge>\n </div>\n\n {/* Summary */}\n <div className=\"grid gap-4 md:grid-cols-3\">\n <Card>\n <CardContent className=\"flex items-center gap-3 pt-4\">\n <TrendingUp className=\"h-5 w-5 text-emerald-500\" />\n <div>\n <p className=\"text-2xl font-bold text-emerald-600\">{improvingCount}</p>\n <p className=\"text-xs text-muted-foreground\">Improving</p>\n </div>\n </CardContent>\n </Card>\n <Card>\n <CardContent className=\"flex items-center gap-3 pt-4\">\n <TrendingDown className=\"h-5 w-5 text-red-500\" />\n <div>\n <p className=\"text-2xl font-bold text-red-600\">{degradingCount}</p>\n <p className=\"text-xs text-muted-foreground\">Degrading</p>\n </div>\n </CardContent>\n </Card>\n <Card>\n <CardContent className=\"flex items-center gap-3 pt-4\">\n <Minus className=\"h-5 w-5 text-muted-foreground\" />\n <div>\n <p className=\"text-2xl font-bold\">\n {performanceBenchmarks.length - improvingCount - degradingCount}\n </p>\n <p className=\"text-xs text-muted-foreground\">Stable</p>\n </div>\n </CardContent>\n </Card>\n </div>\n\n {/* Benchmarks by Category */}\n {categories.map((category) => (\n <Card key={category}>\n <CardHeader>\n <CardTitle className=\"flex items-center gap-2 text-base capitalize\">\n <Zap className=\"h-4 w-4\" /> {category} Performance\n </CardTitle>\n </CardHeader>\n <CardContent className=\"space-y-4\">\n {performanceBenchmarks\n .filter((b) => b.category === category)\n .map((bench) => {\n const changePercent =\n ((bench.currentValue - bench.baselineValue) / bench.baselineValue) * 100;\n const isLowerBetter = bench.unit === 'ms' || bench.unit === 'avg endpoints';\n const isImproved = isLowerBetter\n ? bench.currentValue < bench.baselineValue\n : bench.currentValue > bench.baselineValue;\n return (\n <div key={bench.id} className=\"space-y-1\">\n <div className=\"flex items-center justify-between\">\n <div className=\"flex items-center gap-2\">\n <span className=\"text-sm font-medium\">{bench.name}</span>\n {trendIcons[bench.trend]}\n </div>\n <div className=\"flex items-center gap-3\">\n <span className=\"text-sm font-bold\">\n {bench.currentValue.toLocaleString()} {bench.unit}\n </span>\n <span className={`text-xs ${trendColors[bench.trend]}`}>\n ({changePercent > 0 ? '+' : ''}\n {changePercent.toFixed(1)}% vs baseline)\n </span>\n </div>\n </div>\n <div className=\"flex items-center gap-2\">\n <span className=\"text-xs text-muted-foreground\">\n Baseline: {bench.baselineValue.toLocaleString()} {bench.unit}\n </span>\n <div className=\"flex-1\">\n <div className=\"h-2 rounded bg-muted\">\n <div\n className={`h-2 rounded ${isImproved ? 'bg-emerald-500' : 'bg-amber-500'}`}\n style={{\n width: `${Math.min((bench.currentValue / (bench.baselineValue * 1.5)) * 100, 100)}%`,\n }}\n />\n </div>\n </div>\n <span className=\"text-xs text-muted-foreground\">{bench.lastMeasuredAt}</span>\n </div>\n </div>\n );\n })}\n </CardContent>\n </Card>\n ))}\n </div>\n );\n}\n"],"mappings":";;;;;AAIA,IAAM,IAA8C;CAClD,WAAW,kBAAC,GAAD,EAAY,WAAU,4BAA6B,CAAA;CAC9D,WAAW,kBAAC,GAAD,EAAc,WAAU,wBAAyB,CAAA;CAC5D,QAAQ,kBAAC,GAAD,EAAO,WAAU,iCAAkC,CAAA;CAC5D,EAEK,IAAsC;CAC1C,WAAW;CACX,WAAW;CACX,QAAQ;CACT;AAED,SAAgB,IAAkB;CAChC,IAAM,EAAE,6BAA0B,GAAqB,EAEjD,IAAa,CAAC,GAAG,IAAI,IAAI,EAAsB,KAAK,MAAM,EAAE,SAAS,CAAC,CAAC,EACvE,IAAiB,EAAsB,QAAQ,MAAM,EAAE,UAAU,YAAY,CAAC,QAC9E,IAAiB,EAAsB,QAAQ,MAAM,EAAE,UAAU,YAAY,CAAC;AAEpF,QACE,kBAAC,OAAD;EAAK,WAAU;YAAf;GACE,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,MAAD;KAAI,WAAU;eAAyB;KAAwB,CAAA,EAC/D,kBAAC,KAAD;KAAG,WAAU;eAAgC;KAEzC,CAAA,CACA,EAAA,CAAA,EACN,kBAAC,GAAD;KAAO,SAAQ;KAAY,WAAU;eAArC;MACE,kBAAC,GAAD,EAAO,WAAU,WAAY,CAAA;;MAAE,EAAsB;MAAO;MACtD;OACJ;;GAGN,kBAAC,OAAD;IAAK,WAAU;cAAf;KACE,kBAAC,GAAD,EAAA,UACE,kBAAC,GAAD;MAAa,WAAU;gBAAvB,CACE,kBAAC,GAAD,EAAY,WAAU,4BAA6B,CAAA,EACnD,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,KAAD;OAAG,WAAU;iBAAuC;OAAmB,CAAA,EACvE,kBAAC,KAAD;OAAG,WAA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A,EACxD,EAAW,EAAM,OACd;WACN,kBAAC,OAAD;QAAK,WAAU;kBAAf,CACE,kBAAC,QAAD;SAAM,WAAU;mBAAhB;UACG,EAAM,aAAa,gBAAgB;UAAC;UAAE,EAAM;UACxC;YACP,kBAAC,QAAD;SAAM,WAAW,WAAW,EAAY,EAAM;mBAA9C;UAAwD;UACpD,IAAgB,IAAI,MAAM;UAC3B,EAAc,QAAQ,EAAE;UAAC;UACrB;WACH;UACF;UACN,kBAAC,OAAD;OAAK,WAAU;iBAAf;QACE,kBAAC,QAAD;SAAM,WAAU;mBAAhB;UAAgD;UACnC,EAAM,cAAc,gBAAgB;UAAC;UAAE,EAAM;UACnD;;QACP,kBAAC,OAAD;SAAK,WAAU;mBACb,kBAAC,OAAD;UAAK,WAAU;oBACb,kBAAC,OAAD;WACE,WAAW,eAAe,IAAa,mBAAmB;WAC1D,OAAO,EACL,OAAO,GAAG,KAAK,IAAK,EAAM,gBAAgB,EAAM,gBAAgB,OAAQ,KAAK,IAAI,CAAC,IACnF;WACD,CAAA;UACE,CAAA;SACF,CAAA;QACN,kBAAC,QAAD;SAAM,WAAU;mBAAiC,EAAM;SAAsB,CAAA;QACzE;SACF;QAhCI,EAAM,GAgCV;MAER;IACQ,CAAA,CACT,EAAA,EArDI,EAqDJ,CACP;GACE"}
1
+ {"version":3,"file":"PerformancePage.js","names":[],"sources":["../../../src/semanticfed/pages/PerformancePage.tsx"],"sourcesContent":["import type React from 'react';\nimport { Badge, Card, CardContent, CardHeader, CardTitle } from '@burdenoff/fe-libs/ui';\nimport { Gauge, TrendingUp, TrendingDown, Minus, Zap } from 'lucide-react';\nimport { useSemanticFedStore } from '../store/semanticfedStore';\nimport { useTr } from '../hooks/useTr';\n\nconst trendIcons: Record<string, React.ReactNode> = {\n improving: <TrendingUp className=\"h-3 w-3 text-emerald-500\" />,\n degrading: <TrendingDown className=\"h-3 w-3 text-red-500\" />,\n stable: <Minus className=\"h-3 w-3 text-muted-foreground\" />,\n};\n\nconst trendColors: Record<string, string> = {\n improving: 'text-emerald-600',\n degrading: 'text-red-600',\n stable: 'text-muted-foreground',\n};\n\nconst trendLabels: Record<string, string> = {\n improving: 'semanticfed.performance.kpis.improving',\n degrading: 'semanticfed.performance.kpis.degrading',\n stable: 'semanticfed.performance.kpis.stable',\n};\n\nexport function PerformancePage() {\n const tr = useTr();\n const { performanceBenchmarks } = useSemanticFedStore();\n\n const categories = [...new Set(performanceBenchmarks.map((b) => b.category))];\n const improvingCount = performanceBenchmarks.filter((b) => b.trend === 'improving').length;\n const degradingCount = performanceBenchmarks.filter((b) => b.trend === 'degrading').length;\n\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"flex items-center justify-between\">\n <div>\n <h1 className=\"text-2xl font-semibold\">\n {tr('semanticfed.performance.title', 'Performance Metrics')}\n </h1>\n <p className=\"text-sm text-muted-foreground\">\n {tr(\n 'semanticfed.performance.description',\n 'Benchmark tracking for query, ingestion, reasoning, and federation performance'\n )}\n </p>\n </div>\n <Badge variant=\"secondary\" className=\"gap-1\">\n <Gauge className=\"h-3 w-3\" />{' '}\n {tr('semanticfed.performance.badges.benchmarkCount', '{count} Benchmarks', {\n count: performanceBenchmarks.length,\n })}\n </Badge>\n </div>\n\n {/* Summary */}\n <div className=\"grid gap-4 md:grid-cols-3\">\n <Card>\n <CardContent className=\"flex items-center gap-3 pt-4\">\n <TrendingUp className=\"h-5 w-5 text-emerald-500\" />\n <div>\n <p className=\"text-2xl font-bold text-emerald-600\">{improvingCount}</p>\n <p className=\"text-xs text-muted-foreground\">\n {tr('semanticfed.performance.kpis.improving', 'Improving')}\n </p>\n </div>\n </CardContent>\n </Card>\n <Card>\n <CardContent className=\"flex items-center gap-3 pt-4\">\n <TrendingDown className=\"h-5 w-5 text-red-500\" />\n <div>\n <p className=\"text-2xl font-bold text-red-600\">{degradingCount}</p>\n <p className=\"text-xs text-muted-foreground\">\n {tr('semanticfed.performance.kpis.degrading', 'Degrading')}\n </p>\n </div>\n </CardContent>\n </Card>\n <Card>\n <CardContent className=\"flex items-center gap-3 pt-4\">\n <Minus className=\"h-5 w-5 text-muted-foreground\" />\n <div>\n <p className=\"text-2xl font-bold\">\n {performanceBenchmarks.length - improvingCount - degradingCount}\n </p>\n <p className=\"text-xs text-muted-foreground\">\n {tr('semanticfed.performance.kpis.stable', 'Stable')}\n </p>\n </div>\n </CardContent>\n </Card>\n </div>\n\n {/* Benchmarks by Category */}\n {categories.map((category) => (\n <Card key={category}>\n <CardHeader>\n <CardTitle className=\"flex items-center gap-2 text-base capitalize\">\n <Zap className=\"h-4 w-4\" />{' '}\n {tr('semanticfed.performance.benchmark.title', '{category} Performance', {\n category,\n })}\n </CardTitle>\n </CardHeader>\n <CardContent className=\"space-y-4\">\n {performanceBenchmarks\n .filter((b) => b.category === category)\n .map((bench) => {\n const changePercent =\n ((bench.currentValue - bench.baselineValue) / bench.baselineValue) * 100;\n const isLowerBetter = bench.unit === 'ms' || bench.unit === 'avg endpoints';\n const isImproved = isLowerBetter\n ? bench.currentValue < bench.baselineValue\n : bench.currentValue > bench.baselineValue;\n return (\n <div key={bench.id} className=\"space-y-1\">\n <div className=\"flex items-center justify-between\">\n <div className=\"flex items-center gap-2\">\n <span className=\"text-sm font-medium\">{bench.name}</span>\n {trendIcons[bench.trend]}\n </div>\n <div className=\"flex items-center gap-3\">\n <span className=\"text-sm font-bold\">\n {bench.currentValue.toLocaleString()} {bench.unit}\n </span>\n <span className={`text-xs ${trendColors[bench.trend]}`}>\n {tr(\n 'semanticfed.performance.benchmark.vsBaseline',\n '({sign}{percent}% vs baseline)',\n {\n sign: changePercent > 0 ? '+' : '',\n percent: changePercent.toFixed(1),\n }\n )}\n </span>\n </div>\n </div>\n <div className=\"flex items-center gap-2\">\n <span className=\"text-xs text-muted-foreground\">\n {tr(\n 'semanticfed.performance.benchmark.baseline',\n 'Baseline: {value} {unit}',\n {\n value: bench.baselineValue.toLocaleString(),\n unit: bench.unit,\n }\n )}\n </span>\n <div className=\"flex-1\">\n <div className=\"h-2 rounded bg-muted\">\n <div\n className={`h-2 rounded ${isImproved ? 'bg-emerald-500' : 'bg-amber-500'}`}\n style={{\n width: `${Math.min((bench.currentValue / (bench.baselineValue * 1.5)) * 100, 100)}%`,\n }}\n />\n </div>\n </div>\n <span className=\"text-xs text-muted-foreground\">{bench.lastMeasuredAt}</span>\n </div>\n </div>\n );\n })}\n </CardContent>\n </Card>\n ))}\n </div>\n );\n}\n"],"mappings":";;;;;;AAMA,IAAM,IAA8C;CAClD,WAAW,kBAAC,GAAD,EAAY,WAAU,4BAA6B,CAAA;CAC9D,WAAW,kBAAC,GAAD,EAAc,WAAU,wBAAyB,CAAA;CAC5D,QAAQ,kBAAC,GAAD,EAAO,WAAU,iCAAkC,CAAA;CAC5D,EAEK,IAAsC;CAC1C,WAAW;CACX,WAAW;CACX,QAAQ;CACT;AAQD,SAAgB,IAAkB;CAChC,IAAM,IAAK,GAAO,EACZ,EAAE,6BAA0B,GAAqB,EAEjD,IAAa,CAAC,GAAG,IAAI,IAAI,EAAsB,KAAK,MAAM,EAAE,SAAS,CAAC,CAAC,EACvE,IAAiB,EAAsB,QAAQ,MAAM,EAAE,UAAU,YAAY,CAAC,QAC9E,IAAiB,EAAsB,QAAQ,MAAM,EAAE,UAAU,YAAY,CAAC;AAEpF,QACE,kBAAC,OAAD;EAAK,WAAU;YAAf;GACE,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,MAAD;KAAI,WAAU;eACX,EAAG,iCAAiC,sBAAsB;KACxD,CAAA,EACL,kBAAC,KAAD;KAAG,WAAU;eACV,EACC,uCACA,iFACD;KACC,CAAA,CACA,EAAA,CAAA,EACN,kBAAC,GAAD;KAAO,SAAQ;KAAY,WAAU;eAArC;MACE,kBAAC,GAAD,EAAO,WAAU,WAAY,CAAA;MAAC;MAC7B,EAAG,iDAAiD,sBAAsB,EACzE,OAAO,EAAsB,QAC9B,CAAC;MACI;OACJ;;GAGN,kB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useSemanticFedStore as e } from "../store/semanticfedStore.js";
2
- import { AlertTriangle as t, Plus as n, Search as r, Shield as i, ShieldAlert as a, ShieldCheck as o } from "lucide-react";
3
- import { jsx as s, jsxs as c } from "react/jsx-runtime";
4
- import { Badge as l, Button as u, Card as d, CardContent as f, CardHeader as p, CardTitle as m } from "@burdenoff/fe-libs/ui";
2
+ import { useTr as t } from "../hooks/useTr.js";
3
+ import { AlertTriangle as n, Plus as r, Search as i, Shield as a, ShieldAlert as o, ShieldCheck as s } from "lucide-react";
4
+ import { jsx as c, jsxs as l } from "react/jsx-runtime";
5
+ import { Badge as u, Button as d, Card as f, CardContent as p, CardHeader as m, CardTitle as h } from "@burdenoff/fe-libs/ui";
5
6
  //#region src/semanticfed/pages/PoliciesPage.tsx
6
- var h = {
7
- access: /* @__PURE__ */ s(i, { className: "h-4 w-4 text-blue-500" }),
8
- quality: /* @__PURE__ */ s(o, { className: "h-4 w-4 text-emerald-500" }),
9
- retention: /* @__PURE__ */ s(a, { className: "h-4 w-4 text-amber-500" }),
10
- lineage: /* @__PURE__ */ s(i, { className: "h-4 w-4 text-purple-500" }),
11
- privacy: /* @__PURE__ */ s(a, { className: "h-4 w-4 text-red-500" })
12
- }, g = {
7
+ var g = {
8
+ access: /* @__PURE__ */ c(a, { className: "h-4 w-4 text-blue-500" }),
9
+ quality: /* @__PURE__ */ c(s, { className: "h-4 w-4 text-emerald-500" }),
10
+ retention: /* @__PURE__ */ c(o, { className: "h-4 w-4 text-amber-500" }),
11
+ lineage: /* @__PURE__ */ c(a, { className: "h-4 w-4 text-purple-500" }),
12
+ privacy: /* @__PURE__ */ c(o, { className: "h-4 w-4 text-red-500" })
13
+ }, _ = {
13
14
  strict: "default",
14
15
  advisory: "secondary",
15
16
  audit: "outline"
16
17
  };
17
- function _() {
18
- let { policies: i } = e(), a = i.filter((e) => e.status === "active").length, o = i.reduce((e, t) => e + t.violations, 0), _ = i.filter((e) => e.enforcement === "strict").length;
19
- return /* @__PURE__ */ c("div", {
18
+ function v() {
19
+ let a = t(), { policies: o } = e(), s = {
20
+ access: a("semanticfed.policies.types.access", "Access"),
21
+ quality: a("semanticfed.policies.types.quality", "Quality"),
22
+ retention: a("semanticfed.policies.types.retention", "Retention"),
23
+ lineage: a("semanticfed.policies.types.lineage", "Lineage"),
24
+ privacy: a("semanticfed.policies.types.privacy", "Privacy")
25
+ }, v = {
26
+ strict: a("semanticfed.policies.enforcement.strict", "Strict"),
27
+ advisory: a("semanticfed.policies.enforcement.advisory", "Advisory"),
28
+ audit: a("semanticfed.policies.enforcement.audit", "Audit")
29
+ }, y = {
30
+ active: a("semanticfed.policies.status.active", "Active"),
31
+ draft: a("semanticfed.policies.status.draft", "Draft"),
32
+ disabled: a("semanticfed.policies.status.disabled", "Disabled")
33
+ }, b = o.filter((e) => e.status === "active").length, x = o.reduce((e, t) => e + t.violations, 0), S = o.filter((e) => e.enforcement === "strict").length;
34
+ return /* @__PURE__ */ l("div", {
20
35
  className: "space-y-6 p-6",
21
36
  children: [
22
- /* @__PURE__ */ c("div", {
37
+ /* @__PURE__ */ l("div", {
23
38
  className: "flex items-center justify-between",
24
- children: [/* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("h1", {
39
+ children: [/* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("h1", {
25
40
  className: "text-2xl font-semibold",
26
- children: "Governance Policies"
27
- }), /* @__PURE__ */ s("p", {
41
+ children: a("semanticfed.policies.title", "Governance Policies")
42
+ }), /* @__PURE__ */ c("p", {
28
43
  className: "text-sm text-muted-foreground",
29
- children: "Data access control, quality constraints, retention rules, and privacy enforcement for semantic data."
30
- })] }), /* @__PURE__ */ c("div", {
44
+ children: a("semanticfed.policies.description", "Data access control, quality constraints, retention rules, and privacy enforcement for semantic data.")
45
+ })] }), /* @__PURE__ */ l("div", {
31
46
  className: "flex gap-2",
32
- children: [/* @__PURE__ */ c(u, {
47
+ children: [/* @__PURE__ */ l(d, {
33
48
  variant: "outline",
34
49
  size: "sm",
35
- children: [/* @__PURE__ */ s(r, { className: "mr-2 h-4 w-4" }), " Audit Log"]
36
- }), /* @__PURE__ */ c(u, {
50
+ children: [
51
+ /* @__PURE__ */ c(i, { className: "mr-2 h-4 w-4" }),
52
+ " ",
53
+ a("semanticfed.policies.actions.auditLog", "Audit Log")
54
+ ]
55
+ }), /* @__PURE__ */ l(d, {
37
56
  size: "sm",
38
- children: [/* @__PURE__ */ s(n, { className: "mr-2 h-4 w-4" }), " Create Policy"]
57
+ children: [
58
+ /* @__PURE__ */ c(r, { className: "mr-2 h-4 w-4" }),
59
+ " ",
60
+ a("semanticfed.policies.actions.createPolicy", "Create Policy")
61
+ ]
39
62
  })]
40
63
  })]
41
64
  }),
42
- /* @__PURE__ */ c("div", {
65
+ /* @__PURE__ */ l("div", {
43
66
  className: "grid gap-4 md:grid-cols-4",
44
67
  children: [
45
- /* @__PURE__ */ c(d, { children: [/* @__PURE__ */ s(p, {
68
+ /* @__PURE__ */ l(f, { children: [/* @__PURE__ */ c(m, {
46
69
  className: "pb-2",
47
- children: /* @__PURE__ */ s(m, {
70
+ children: /* @__PURE__ */ c(h, {
48
71
  className: "text-sm font-medium",
49
- children: "Active Policies"
72
+ children: a("semanticfed.policies.kpis.active.title", "Active Policies")
50
73
  })
51
- }), /* @__PURE__ */ c(f, { children: [/* @__PURE__ */ s("div", {
74
+ }), /* @__PURE__ */ l(p, { children: [/* @__PURE__ */ c("div", {
52
75
  className: "text-2xl font-bold",
53
- children: a
76
+ children: b
54
77
  }), /* @__PURE__ */ c("p", {
55
78
  className: "text-xs text-muted-foreground",
56
- children: [
57
- "of ",
58
- i.length,
59
- " total"
60
- ]
79
+ children: a("semanticfed.policies.kpis.active.subtitle", "of {count} total", { count: o.length })
61
80
  })] })] }),
62
- /* @__PURE__ */ c(d, { children: [/* @__PURE__ */ s(p, {
81
+ /* @__PURE__ */ l(f, { children: [/* @__PURE__ */ c(m, {
63
82
  className: "pb-2",
64
- children: /* @__PURE__ */ s(m, {
83
+ children: /* @__PURE__ */ c(h, {
65
84
  className: "text-sm font-medium",
66
- children: "Violations"
85
+ children: a("semanticfed.policies.kpis.violations.title", "Violations")
67
86
  })
68
- }), /* @__PURE__ */ c(f, { children: [/* @__PURE__ */ s("div", {
69
- className: `text-2xl font-bold ${o > 0 ? "text-amber-500" : "text-emerald-500"}`,
70
- children: o
71
- }), /* @__PURE__ */ s("p", {
87
+ }), /* @__PURE__ */ l(p, { children: [/* @__PURE__ */ c("div", {
88
+ className: `text-2xl font-bold ${x > 0 ? "text-amber-500" : "text-emerald-500"}`,
89
+ children: x
90
+ }), /* @__PURE__ */ c("p", {
72
91
  className: "text-xs text-muted-foreground",
73
- children: "across all policies"
92
+ children: a("semanticfed.policies.kpis.violations.subtitle", "across all policies")
74
93
  })] })] }),
75
- /* @__PURE__ */ c(d, { children: [/* @__PURE__ */ s(p, {
94
+ /* @__PURE__ */ l(f, { children: [/* @__PURE__ */ c(m, {
76
95
  className: "pb-2",
77
- children: /* @__PURE__ */ s(m, {
96
+ children: /* @__PURE__ */ c(h, {
78
97
  className: "text-sm font-medium",
79
- children: "Strict Enforcement"
98
+ children: a("semanticfed.policies.kpis.strict.title", "Strict Enforcement")
80
99
  })
81
- }), /* @__PURE__ */ c(f, { children: [/* @__PURE__ */ s("div", {
100
+ }), /* @__PURE__ */ l(p, { children: [/* @__PURE__ */ c("div", {
82
101
  className: "text-2xl font-bold",
83
- children: _
84
- }), /* @__PURE__ */ s("p", {
102
+ children: S
103
+ }), /* @__PURE__ */ c("p", {
85
104
  className: "text-xs text-muted-foreground",
86
- children: "blocking policies"
105
+ children: a("semanticfed.policies.kpis.strict.subtitle", "blocking policies")
87
106
  })] })] }),
88
- /* @__PURE__ */ c(d, { children: [/* @__PURE__ */ s(p, {
107
+ /* @__PURE__ */ l(f, { children: [/* @__PURE__ */ c(m, {
89
108
  className: "pb-2",
90
- children: /* @__PURE__ */ s(m, {
109
+ children: /* @__PURE__ */ c(h, {
91
110
  className: "text-sm font-medium",
92
- children: "Compliance"
111
+ children: a("semanticfed.policies.kpis.compliance.title", "Compliance")
93
112
  })
94
- }), /* @__PURE__ */ c(f, { children: [/* @__PURE__ */ c("div", {
113
+ }), /* @__PURE__ */ l(p, { children: [/* @__PURE__ */ l("div", {
95
114
  className: "text-2xl font-bold text-emerald-500",
96
- children: [a > 0 ? Math.round((a - i.filter((e) => e.violations > 0 && e.status === "active").length) / a * 100) : 100, "%"]
97
- }), /* @__PURE__ */ s("p", {
115
+ children: [b > 0 ? Math.round((b - o.filter((e) => e.violations > 0 && e.status === "active").length) / b * 100) : 100, "%"]
116
+ }), /* @__PURE__ */ c("p", {
98
117
  className: "text-xs text-muted-foreground",
99
- children: "policies passing"
118
+ children: a("semanticfed.policies.kpis.compliance.subtitle", "policies passing")
100
119
  })] })] })
101
120
  ]
102
121
  }),
103
- /* @__PURE__ */ c(d, { children: [/* @__PURE__ */ s(p, {
122
+ /* @__PURE__ */ l(f, { children: [/* @__PURE__ */ c(m, {
104
123
  className: "pb-3",
105
- children: /* @__PURE__ */ s(m, {
124
+ children: /* @__PURE__ */ c(h, {
106
125
  className: "text-base",
107
- children: "Policy Registry"
126
+ children: a("semanticfed.policies.table.title", "Policy Registry")
108
127
  })
109
- }), /* @__PURE__ */ s(f, { children: /* @__PURE__ */ s("div", {
128
+ }), /* @__PURE__ */ c(p, { children: /* @__PURE__ */ c("div", {
110
129
  className: "overflow-x-auto",
111
- children: /* @__PURE__ */ c("table", {
130
+ children: /* @__PURE__ */ l("table", {
112
131
  className: "w-full text-sm",
113
- children: [/* @__PURE__ */ s("thead", { children: /* @__PURE__ */ c("tr", {
132
+ children: [/* @__PURE__ */ c("thead", { children: /* @__PURE__ */ l("tr", {
114
133
  className: "border-b text-left text-muted-foreground",
115
134
  children: [
116
- /* @__PURE__ */ s("th", {
135
+ /* @__PURE__ */ c("th", {
117
136
  className: "p-3",
118
- children: "Policy"
137
+ children: a("semanticfed.policies.table.columns.policy", "Policy")
119
138
  }),
120
- /* @__PURE__ */ s("th", {
139
+ /* @__PURE__ */ c("th", {
121
140
  className: "p-3",
122
- children: "Type"
141
+ children: a("semanticfed.policies.table.columns.type", "Type")
123
142
  }),
124
- /* @__PURE__ */ s("th", {
143
+ /* @__PURE__ */ c("th", {
125
144
  className: "p-3",
126
- children: "Scope"
145
+ children: a("semanticfed.policies.table.columns.scope", "Scope")
127
146
  }),
128
- /* @__PURE__ */ s("th", {
147
+ /* @__PURE__ */ c("th", {
129
148
  className: "p-3",
130
- children: "Enforcement"
149
+ children: a("semanticfed.policies.table.columns.enforcement", "Enforcement")
131
150
  }),
132
- /* @__PURE__ */ s("th", {
151
+ /* @__PURE__ */ c("th", {
133
152
  className: "p-3",
134
- children: "Status"
153
+ children: a("semanticfed.policies.table.columns.status", "Status")
135
154
  }),
136
- /* @__PURE__ */ s("th", {
155
+ /* @__PURE__ */ c("th", {
137
156
  className: "p-3 text-right",
138
- children: "Violations"
157
+ children: a("semanticfed.policies.table.columns.violations", "Violations")
139
158
  }),
140
- /* @__PURE__ */ s("th", {
159
+ /* @__PURE__ */ c("th", {
141
160
  className: "p-3 text-right",
142
- children: "Last Evaluated"
161
+ children: a("semanticfed.policies.table.columns.lastEvaluated", "Last Evaluated")
143
162
  })
144
163
  ]
145
- }) }), /* @__PURE__ */ s("tbody", { children: i.map((e) => /* @__PURE__ */ c("tr", {
164
+ }) }), /* @__PURE__ */ c("tbody", { children: o.map((e) => /* @__PURE__ */ l("tr", {
146
165
  className: "border-b hover:bg-muted/50",
147
166
  children: [
148
- /* @__PURE__ */ s("td", {
167
+ /* @__PURE__ */ c("td", {
149
168
  className: "p-3",
150
- children: /* @__PURE__ */ c("div", {
169
+ children: /* @__PURE__ */ l("div", {
151
170
  className: "flex items-center gap-2",
152
- children: [h[e.type], /* @__PURE__ */ s("span", {
171
+ children: [g[e.type], /* @__PURE__ */ c("span", {
153
172
  className: "font-medium",
154
173
  children: e.name
155
174
  })]
156
175
  })
157
176
  }),
158
- /* @__PURE__ */ s("td", {
177
+ /* @__PURE__ */ c("td", {
159
178
  className: "p-3",
160
- children: /* @__PURE__ */ s(l, {
179
+ children: /* @__PURE__ */ c(u, {
161
180
  variant: "outline",
162
181
  className: "capitalize",
163
- children: e.type
182
+ children: s[e.type] ?? e.type
164
183
  })
165
184
  }),
166
- /* @__PURE__ */ s("td", {
185
+ /* @__PURE__ */ c("td", {
167
186
  className: "p-3 text-muted-foreground",
168
187
  children: e.scope
169
188
  }),
170
- /* @__PURE__ */ s("td", {
189
+ /* @__PURE__ */ c("td", {
171
190
  className: "p-3",
172
- children: /* @__PURE__ */ s(l, {
173
- variant: g[e.enforcement],
174
- children: e.enforcement
191
+ children: /* @__PURE__ */ c(u, {
192
+ variant: _[e.enforcement],
193
+ children: v[e.enforcement] ?? e.enforcement
175
194
  })
176
195
  }),
177
- /* @__PURE__ */ s("td", {
196
+ /* @__PURE__ */ c("td", {
178
197
  className: "p-3",
179
- children: /* @__PURE__ */ s(l, {
198
+ children: /* @__PURE__ */ c(u, {
180
199
  variant: e.status === "active" ? "default" : e.status === "draft" ? "secondary" : "outline",
181
- children: e.status
200
+ children: y[e.status] ?? e.status
182
201
  })
183
202
  }),
184
- /* @__PURE__ */ s("td", {
203
+ /* @__PURE__ */ c("td", {
185
204
  className: "p-3 text-right",
186
- children: e.violations > 0 ? /* @__PURE__ */ c("span", {
205
+ children: e.violations > 0 ? /* @__PURE__ */ l("span", {
187
206
  className: "flex items-center justify-end gap-1 text-amber-500",
188
- children: [/* @__PURE__ */ s(t, { className: "h-3 w-3" }), e.violations]
189
- }) : /* @__PURE__ */ s("span", {
207
+ children: [/* @__PURE__ */ c(n, { className: "h-3 w-3" }), e.violations]
208
+ }) : /* @__PURE__ */ c("span", {
190
209
  className: "text-emerald-500",
191
210
  children: "0"
192
211
  })
193
212
  }),
194
- /* @__PURE__ */ s("td", {
213
+ /* @__PURE__ */ c("td", {
195
214
  className: "p-3 text-right text-muted-foreground",
196
215
  children: e.lastEvaluatedAt
197
216
  })
@@ -203,6 +222,6 @@ function _() {
203
222
  });
204
223
  }
205
224
  //#endregion
206
- export { _ as PoliciesPage };
225
+ export { v as PoliciesPage };
207
226
 
208
227
  //# sourceMappingURL=PoliciesPage.js.map