@burdenoff/microfe-security 2026.625.1 → 2026.626.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.
- package/dist/security/components/PageLayout.js +35 -18
- package/dist/security/components/PageLayout.js.map +1 -1
- package/dist/security/components/SecurityScoreCard.js +11 -10
- package/dist/security/components/SecurityScoreCard.js.map +1 -1
- package/dist/security/components/VaultCard.js +8 -1
- package/dist/security/components/VaultCard.js.map +1 -1
- package/dist/security/components/ui.js +7 -15
- package/dist/security/components/ui.js.map +1 -1
- package/dist/security/pages/AccessReviewPage.js +129 -98
- package/dist/security/pages/AccessReviewPage.js.map +1 -1
- package/dist/security/pages/AuditLogPage.js +69 -62
- package/dist/security/pages/AuditLogPage.js.map +1 -1
- package/dist/security/pages/ImportExportPage.js +23 -17
- package/dist/security/pages/ImportExportPage.js.map +1 -1
- package/dist/security/pages/ProviderDetailPage.js +193 -173
- package/dist/security/pages/ProviderDetailPage.js.map +1 -1
- package/dist/security/pages/ProvidersPage.js +59 -56
- package/dist/security/pages/ProvidersPage.js.map +1 -1
- package/dist/security/pages/SecretCreatePage.js +76 -70
- package/dist/security/pages/SecretCreatePage.js.map +1 -1
- package/dist/security/pages/SecretDetailPage.js +325 -290
- package/dist/security/pages/SecretDetailPage.js.map +1 -1
- package/dist/security/pages/SecurityDashboardPage.js +107 -68
- package/dist/security/pages/SecurityDashboardPage.js.map +1 -1
- package/dist/security/pages/SharedWithMePage.js +48 -44
- package/dist/security/pages/SharedWithMePage.js.map +1 -1
- package/dist/security/pages/VaultCreatePage.js +65 -58
- package/dist/security/pages/VaultCreatePage.js.map +1 -1
- package/dist/security/pages/VaultDetailPage.js +225 -196
- package/dist/security/pages/VaultDetailPage.js.map +1 -1
- package/dist/security/pages/VaultSettingsPage.js +224 -205
- package/dist/security/pages/VaultSettingsPage.js.map +1 -1
- package/dist/security/pages/VaultsDashboardPage.js +100 -93
- package/dist/security/pages/VaultsDashboardPage.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,26 +1,43 @@
|
|
|
1
1
|
import { cn as e } from "../utils/cn.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Fragment as t, jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
3
|
+
import { AuroraBackground as i, GradientText as a } from "@burdenoff/fe-libs/ui";
|
|
3
4
|
//#region src/security/components/PageLayout.tsx
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
5
|
+
function o({ title: e, accent: i }) {
|
|
6
|
+
if (!i || !e.includes(i)) return /* @__PURE__ */ n(t, { children: e });
|
|
7
|
+
let [o, s] = e.split(i);
|
|
8
|
+
return /* @__PURE__ */ r(t, { children: [
|
|
9
|
+
o,
|
|
10
|
+
/* @__PURE__ */ n(a, { children: i }),
|
|
11
|
+
s
|
|
12
|
+
] });
|
|
13
|
+
}
|
|
14
|
+
var s = ({ title: t, description: a, actions: s, children: c, className: l, hero: u = !1, titleAccent: d }) => /* @__PURE__ */ r("div", {
|
|
15
|
+
className: e("flex flex-col gap-6 p-6", l),
|
|
16
|
+
children: [/* @__PURE__ */ r("div", {
|
|
17
|
+
className: e("flex items-start justify-between gap-4", u && "relative overflow-hidden rounded-card px-1 py-1"),
|
|
18
|
+
children: [
|
|
19
|
+
u && /* @__PURE__ */ n(i, { intensity: "subtle" }),
|
|
20
|
+
/* @__PURE__ */ r("div", { children: [/* @__PURE__ */ n("h1", {
|
|
21
|
+
className: "text-2xl font-bold text-text-primary",
|
|
22
|
+
children: /* @__PURE__ */ n(o, {
|
|
23
|
+
title: t,
|
|
24
|
+
accent: d
|
|
25
|
+
})
|
|
26
|
+
}), a && /* @__PURE__ */ n("p", {
|
|
27
|
+
className: "mt-1 text-sm text-text-secondary",
|
|
28
|
+
children: a
|
|
29
|
+
})] }),
|
|
30
|
+
s && /* @__PURE__ */ n("div", {
|
|
31
|
+
className: "flex items-center gap-2 shrink-0",
|
|
32
|
+
children: s
|
|
33
|
+
})
|
|
34
|
+
]
|
|
35
|
+
}), /* @__PURE__ */ n("div", {
|
|
19
36
|
className: "flex-1",
|
|
20
|
-
children:
|
|
37
|
+
children: c
|
|
21
38
|
})]
|
|
22
39
|
});
|
|
23
40
|
//#endregion
|
|
24
|
-
export {
|
|
41
|
+
export { s as PageLayout };
|
|
25
42
|
|
|
26
43
|
//# sourceMappingURL=PageLayout.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageLayout.js","names":[],"sources":["../../../src/security/components/PageLayout.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport { cn } from '../utils/cn';\n\nexport interface Breadcrumb {\n label: string;\n path?: string;\n}\n\ninterface PageLayoutProps {\n title: string;\n description?: string;\n /**\n * Accepted for API compatibility with callers, but intentionally ignored:\n * the host shell (AppShellLayout → AutoBreadcrumbs) already renders\n * breadcrumbs for every page. Rendering them again here caused duplicate\n * breadcrumbs on pages like /security/*.\n */\n breadcrumbs?: Breadcrumb[];\n actions?: ReactNode;\n children: ReactNode;\n className?: string;\n}\n\nexport const PageLayout: FC<PageLayoutProps> = ({\n title,\n description,\n actions,\n children,\n className,\n}) => {\n return (\n <div className={cn('flex flex-col gap-6 p-6', className)}>\n {/* Header */}\n <div
|
|
1
|
+
{"version":3,"file":"PageLayout.js","names":[],"sources":["../../../src/security/components/PageLayout.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport { AuroraBackground, GradientText } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/cn';\n\nexport interface Breadcrumb {\n label: string;\n path?: string;\n}\n\ninterface PageLayoutProps {\n title: string;\n description?: string;\n /**\n * Accepted for API compatibility with callers, but intentionally ignored:\n * the host shell (AppShellLayout → AutoBreadcrumbs) already renders\n * breadcrumbs for every page. Rendering them again here caused duplicate\n * breadcrumbs on pages like /security/*.\n */\n breadcrumbs?: Breadcrumb[];\n actions?: ReactNode;\n children: ReactNode;\n className?: string;\n /**\n * Boff UI 2.0 living-glass hero backdrop. Opt-in — set ONLY on the MFE's\n * primary landing page (one aurora per MFE). Drops a subtle AuroraBackground\n * behind the header zone; it sits at -z-10 and never moves content.\n */\n hero?: boolean;\n /**\n * When set, the matching substring of `title` is rendered with a brand\n * GradientText fill (the hero heading's key noun). Use on the hero page only.\n */\n titleAccent?: string;\n}\n\nfunction HeroTitle({ title, accent }: { title: string; accent?: string }) {\n if (!accent || !title.includes(accent)) {\n return <>{title}</>;\n }\n const [before, after] = title.split(accent);\n return (\n <>\n {before}\n <GradientText>{accent}</GradientText>\n {after}\n </>\n );\n}\n\nexport const PageLayout: FC<PageLayoutProps> = ({\n title,\n description,\n actions,\n children,\n className,\n hero = false,\n titleAccent,\n}) => {\n return (\n <div className={cn('flex flex-col gap-6 p-6', className)}>\n {/* Header */}\n <div\n className={cn(\n 'flex items-start justify-between gap-4',\n hero && 'relative overflow-hidden rounded-card px-1 py-1'\n )}\n >\n {hero && <AuroraBackground intensity=\"subtle\" />}\n <div>\n <h1 className=\"text-2xl font-bold text-text-primary\">\n <HeroTitle title={title} accent={titleAccent} />\n </h1>\n {description && <p className=\"mt-1 text-sm text-text-secondary\">{description}</p>}\n </div>\n {actions && <div className=\"flex items-center gap-2 shrink-0\">{actions}</div>}\n </div>\n\n {/* Content */}\n <div className=\"flex-1\">{children}</div>\n </div>\n );\n};\n"],"mappings":";;;;AAmCA,SAAS,EAAU,EAAE,UAAO,aAA8C;AACxE,KAAI,CAAC,KAAU,CAAC,EAAM,SAAS,EAAO,CACpC,QAAO,kBAAA,GAAA,EAAA,UAAG,GAAS,CAAA;CAErB,IAAM,CAAC,GAAQ,KAAS,EAAM,MAAM,EAAO;AAC3C,QACE,kBAAA,GAAA,EAAA,UAAA;EACG;EACD,kBAAC,GAAD,EAAA,UAAe,GAAsB,CAAA;EACpC;EACA,EAAA,CAAA;;AAIP,IAAa,KAAmC,EAC9C,UACA,gBACA,YACA,aACA,cACA,UAAO,IACP,qBAGE,kBAAC,OAAD;CAAK,WAAW,EAAG,2BAA2B,EAAU;WAAxD,CAEE,kBAAC,OAAD;EACE,WAAW,EACT,0CACA,KAAQ,kDACT;YAJH;GAMG,KAAQ,kBAAC,GAAD,EAAkB,WAAU,UAAW,CAAA;GAChD,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,MAAD;IAAI,WAAU;cACZ,kBAAC,GAAD;KAAkB;KAAO,QAAQ;KAAe,CAAA;IAC7C,CAAA,EACJ,KAAe,kBAAC,KAAD;IAAG,WAAU;cAAoC;IAAgB,CAAA,CAC7E,EAAA,CAAA;GACL,KAAW,kBAAC,OAAD;IAAK,WAAU;cAAoC;IAAc,CAAA;GACzE;KAGN,kBAAC,OAAD;EAAK,WAAU;EAAU;EAAe,CAAA,CACpC"}
|
|
@@ -3,8 +3,8 @@ import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
|
3
3
|
import { AlertTriangle as r, CheckCircle as i, Shield as a, XCircle as o } from "lucide-react";
|
|
4
4
|
import { GlassCard as s } from "@burdenoff/fe-libs/ui";
|
|
5
5
|
//#region src/security/components/SecurityScoreCard.tsx
|
|
6
|
-
var c = ({ score: c, className: l }) => {
|
|
7
|
-
let
|
|
6
|
+
var c = ({ score: c, className: l, glow: u }) => {
|
|
7
|
+
let d = ((e) => e >= 80 ? {
|
|
8
8
|
label: "Excellent",
|
|
9
9
|
color: "text-status-success-text",
|
|
10
10
|
bg: "bg-status-success-bg",
|
|
@@ -24,9 +24,10 @@ var c = ({ score: c, className: l }) => {
|
|
|
24
24
|
color: "text-status-error-text",
|
|
25
25
|
bg: "bg-status-error-bg",
|
|
26
26
|
Icon: o
|
|
27
|
-
})(c),
|
|
27
|
+
})(c), f = d.Icon, p = 2 * Math.PI * 37, m = p - c / 100 * p;
|
|
28
28
|
return /* @__PURE__ */ n(s, {
|
|
29
29
|
treatment: "glass",
|
|
30
|
+
glow: u,
|
|
30
31
|
className: e("p-5 flex flex-col items-center gap-2", l),
|
|
31
32
|
children: [/* @__PURE__ */ n("div", {
|
|
32
33
|
className: "relative",
|
|
@@ -49,16 +50,16 @@ var c = ({ score: c, className: l }) => {
|
|
|
49
50
|
fill: "none",
|
|
50
51
|
stroke: "currentColor",
|
|
51
52
|
strokeWidth: 6,
|
|
52
|
-
strokeDasharray:
|
|
53
|
-
strokeDashoffset:
|
|
53
|
+
strokeDasharray: p,
|
|
54
|
+
strokeDashoffset: m,
|
|
54
55
|
strokeLinecap: "round",
|
|
55
|
-
className: e(
|
|
56
|
+
className: e(d.color, "transition-all duration-200"),
|
|
56
57
|
transform: `rotate(-90 ${80 / 2} ${80 / 2})`
|
|
57
58
|
})]
|
|
58
59
|
}), /* @__PURE__ */ t("div", {
|
|
59
60
|
className: "absolute inset-0 flex items-center justify-center",
|
|
60
61
|
children: /* @__PURE__ */ t("span", {
|
|
61
|
-
className: e("text-xl font-bold tabular-nums",
|
|
62
|
+
className: e("text-xl font-bold tabular-nums", d.color),
|
|
62
63
|
children: c
|
|
63
64
|
})
|
|
64
65
|
})]
|
|
@@ -66,9 +67,9 @@ var c = ({ score: c, className: l }) => {
|
|
|
66
67
|
className: "text-center",
|
|
67
68
|
children: [/* @__PURE__ */ n("div", {
|
|
68
69
|
className: "flex items-center gap-1",
|
|
69
|
-
children: [/* @__PURE__ */ t(
|
|
70
|
-
className: e("text-sm font-semibold",
|
|
71
|
-
children:
|
|
70
|
+
children: [/* @__PURE__ */ t(f, { className: e("h-4 w-4", d.color) }), /* @__PURE__ */ t("span", {
|
|
71
|
+
className: e("text-sm font-semibold", d.color),
|
|
72
|
+
children: d.label
|
|
72
73
|
})]
|
|
73
74
|
}), /* @__PURE__ */ t("p", {
|
|
74
75
|
className: "text-xs text-text-secondary mt-0.5",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SecurityScoreCard.js","names":[],"sources":["../../../src/security/components/SecurityScoreCard.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { Shield, CheckCircle, AlertTriangle, XCircle } from 'lucide-react';\nimport { GlassCard } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/cn';\n\ninterface SecurityScoreCardProps {\n score: number;\n className?: string;\n}\n\n/**\n * Visual card displaying the security health score as a circular gauge.\n */\nexport const SecurityScoreCard: FC<SecurityScoreCardProps> = ({ score, className }) => {\n const getScoreConfig = (s: number) => {\n if (s >= 80)\n return {\n label: 'Excellent',\n color: 'text-status-success-text',\n bg: 'bg-status-success-bg',\n Icon: CheckCircle,\n };\n if (s >= 60)\n return { label: 'Good', color: 'text-status-info-text', bg: 'bg-accent-blue', Icon: Shield };\n if (s >= 40)\n return {\n label: 'Fair',\n color: 'text-status-warning-text',\n bg: 'bg-status-warning-bg',\n Icon: AlertTriangle,\n };\n return {\n label: 'Needs Attention',\n color: 'text-status-error-text',\n bg: 'bg-status-error-bg',\n Icon: XCircle,\n };\n };\n\n const config = getScoreConfig(score);\n const Icon = config.Icon;\n\n // SVG circle properties\n const size = 80;\n const strokeWidth = 6;\n const radius = (size - strokeWidth) / 2;\n const circumference = 2 * Math.PI * radius;\n const offset = circumference - (score / 100) * circumference;\n\n return (\n <GlassCard
|
|
1
|
+
{"version":3,"file":"SecurityScoreCard.js","names":[],"sources":["../../../src/security/components/SecurityScoreCard.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { Shield, CheckCircle, AlertTriangle, XCircle } from 'lucide-react';\nimport { GlassCard } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/cn';\n\ninterface SecurityScoreCardProps {\n score: number;\n className?: string;\n /** Boff UI 2.0 featured accent glow — use when this is the hero card of the page. */\n glow?: boolean;\n}\n\n/**\n * Visual card displaying the security health score as a circular gauge.\n */\nexport const SecurityScoreCard: FC<SecurityScoreCardProps> = ({ score, className, glow }) => {\n const getScoreConfig = (s: number) => {\n if (s >= 80)\n return {\n label: 'Excellent',\n color: 'text-status-success-text',\n bg: 'bg-status-success-bg',\n Icon: CheckCircle,\n };\n if (s >= 60)\n return { label: 'Good', color: 'text-status-info-text', bg: 'bg-accent-blue', Icon: Shield };\n if (s >= 40)\n return {\n label: 'Fair',\n color: 'text-status-warning-text',\n bg: 'bg-status-warning-bg',\n Icon: AlertTriangle,\n };\n return {\n label: 'Needs Attention',\n color: 'text-status-error-text',\n bg: 'bg-status-error-bg',\n Icon: XCircle,\n };\n };\n\n const config = getScoreConfig(score);\n const Icon = config.Icon;\n\n // SVG circle properties\n const size = 80;\n const strokeWidth = 6;\n const radius = (size - strokeWidth) / 2;\n const circumference = 2 * Math.PI * radius;\n const offset = circumference - (score / 100) * circumference;\n\n return (\n <GlassCard\n treatment=\"glass\"\n glow={glow}\n className={cn('p-5 flex flex-col items-center gap-2', className)}\n >\n <div className=\"relative\">\n <svg width={size} height={size} viewBox={`0 0 ${size} ${size}`}>\n {/* Background circle */}\n <circle\n cx={size / 2}\n cy={size / 2}\n r={radius}\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth={strokeWidth}\n className=\"text-muted/30\"\n />\n {/* Score circle */}\n <circle\n cx={size / 2}\n cy={size / 2}\n r={radius}\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth={strokeWidth}\n strokeDasharray={circumference}\n strokeDashoffset={offset}\n strokeLinecap=\"round\"\n className={cn(config.color, 'transition-all duration-200')}\n transform={`rotate(-90 ${size / 2} ${size / 2})`}\n />\n </svg>\n <div className=\"absolute inset-0 flex items-center justify-center\">\n <span className={cn('text-xl font-bold tabular-nums', config.color)}>{score}</span>\n </div>\n </div>\n <div className=\"text-center\">\n <div className=\"flex items-center gap-1\">\n <Icon className={cn('h-4 w-4', config.color)} />\n <span className={cn('text-sm font-semibold', config.color)}>{config.label}</span>\n </div>\n <p className=\"text-xs text-text-secondary mt-0.5\">Health Score</p>\n </div>\n </GlassCard>\n );\n};\n"],"mappings":";;;;;AAeA,IAAa,KAAiD,EAAE,UAAO,cAAW,cAAW;CA0B3F,IAAM,MAzBkB,MAClB,KAAK,KACA;EACL,OAAO;EACP,OAAO;EACP,IAAI;EACJ,MAAM;EACP,GACC,KAAK,KACA;EAAE,OAAO;EAAQ,OAAO;EAAyB,IAAI;EAAkB,MAAM;EAAQ,GAC1F,KAAK,KACA;EACL,OAAO;EACP,OAAO;EACP,IAAI;EACJ,MAAM;EACP,GACI;EACL,OAAO;EACP,OAAO;EACP,IAAI;EACJ,MAAM;EACP,EAG2B,EAAM,EAC9B,IAAO,EAAO,MAMd,IAAgB,IAAI,KAAK,KAAK,IAC9B,IAAS,IAAiB,IAAQ,MAAO;AAE/C,QACE,kBAAC,GAAD;EACE,WAAU;EACJ;EACN,WAAW,EAAG,wCAAwC,EAAU;YAHlE,CAKE,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,OAAD;IAAK,OAAO;IAAM,QAAQ;IAAM,SAAS;cAAzC,CAEE,kBAAC,UAAD;KACE,IAAI,KAAO;KACX,IAAI,KAAO;KACX,GAAG;KACH,MAAK;KACL,QAAO;KACM;KACb,WAAU;KACV,CAAA,EAEF,kBAAC,UAAD;KACE,IAAI,KAAO;KACX,IAAI,KAAO;KACX,GAAG;KACH,MAAK;KACL,QAAO;KACM;KACb,iBAAiB;KACjB,kBAAkB;KAClB,eAAc;KACd,WAAW,EAAG,EAAO,OAAO,8BAA8B;KAC1D,WAAW,cAAc,KAAO,EAAE,GAAG,KAAO,EAAE;KAC9C,CAAA,CACE;OACN,kBAAC,OAAD;IAAK,WAAU;cACb,kBAAC,QAAD;KAAM,WAAW,EAAG,kCAAkC,EAAO,MAAM;eAAG;KAAa,CAAA;IAC/E,CAAA,CACF;MACN,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,GAAD,EAAM,WAAW,EAAG,WAAW,EAAO,MAAM,EAAI,CAAA,EAChD,kBAAC,QAAD;KAAM,WAAW,EAAG,yBAAyB,EAAO,MAAM;eAAG,EAAO;KAAa,CAAA,CAC7E;OACN,kBAAC,KAAD;IAAG,WAAU;cAAqC;IAAgB,CAAA,CAC9D;KACI"}
|
|
@@ -67,7 +67,14 @@ var d = ({ vault: d, onClick: f, isSelected: p, onSelect: m, className: h }) =>
|
|
|
67
67
|
]
|
|
68
68
|
}), /* @__PURE__ */ a(t, {
|
|
69
69
|
variant: y.variant,
|
|
70
|
-
children: [
|
|
70
|
+
children: [
|
|
71
|
+
d.status === "ACTIVE" && /* @__PURE__ */ i("span", {
|
|
72
|
+
"aria-hidden": "true",
|
|
73
|
+
className: "size-1.5 rounded-full bg-status-success-text motion-safe:animate-vc-glow-pulse"
|
|
74
|
+
}),
|
|
75
|
+
b && /* @__PURE__ */ i(b, { className: "size-3" }),
|
|
76
|
+
y.label
|
|
77
|
+
]
|
|
71
78
|
})]
|
|
72
79
|
}), /* @__PURE__ */ a("div", {
|
|
73
80
|
className: "flex items-center gap-4 text-sm text-text-secondary",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VaultCard.js","names":[],"sources":["../../../src/security/components/VaultCard.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { KeyRound, Users, Lock, Archive } from 'lucide-react';\nimport { cn } from '../utils/cn';\nimport { Card, Badge } from './ui';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { translateWithFallback } from '../utils/i18n';\nimport type { Vault } from '../types';\n\ninterface VaultCardProps {\n vault: Vault;\n onClick?: () => void;\n isSelected?: boolean;\n onSelect?: (vaultId: string) => void;\n className?: string;\n}\n\nexport const VaultCard: FC<VaultCardProps> = ({\n vault,\n onClick,\n isSelected,\n onSelect,\n className,\n}) => {\n const { t } = useI18n();\n const tx = (key: string, fallback: string, params?: Record<string, string | number>) =>\n translateWithFallback(t, key, fallback, params);\n\n const statusConfig: Record<\n string,\n { label: string; variant: 'success' | 'warning' | 'outline'; icon: typeof Lock | null }\n > = {\n ACTIVE: {\n label: tx('security.vaultCard.status.active', 'Active'),\n variant: 'success',\n icon: null,\n },\n LOCKED: {\n label: tx('security.vaultCard.status.locked', 'Locked'),\n variant: 'warning',\n icon: Lock,\n },\n ARCHIVED: {\n label: tx('security.vaultCard.status.archived', 'Archived'),\n variant: 'outline',\n icon: Archive,\n },\n SUSPENDED: {\n label: tx('security.vaultCard.status.suspended', 'Suspended'),\n variant: 'outline',\n icon: Archive,\n },\n DELETED: {\n label: tx('security.vaultCard.status.deleted', 'Deleted'),\n variant: 'outline',\n icon: Archive,\n },\n };\n\n const status = statusConfig[vault.status] ?? statusConfig.ACTIVE;\n const StatusIcon = status.icon;\n\n const secretLabel =\n vault.secretCount === 1\n ? tx('security.vaultCard.secretCount.singular', '{count} secret', {\n count: vault.secretCount,\n })\n : tx('security.vaultCard.secretCount.plural', '{count} secrets', {\n count: vault.secretCount,\n });\n\n const memberLabel =\n vault.memberCount === 1\n ? tx('security.vaultCard.memberCount.singular', '{count} member', {\n count: vault.memberCount,\n })\n : tx('security.vaultCard.memberCount.plural', '{count} members', {\n count: vault.memberCount,\n });\n\n return (\n <Card\n onClick={onClick}\n className={cn(\n 'p-5',\n 'focus-visible:ring-2 focus-visible:ring-primary focus-visible:outline-none',\n isSelected && 'ring-2 ring-primary/50',\n className\n )}\n aria-selected={isSelected}\n data-tour=\"vaults-card-item\"\n >\n <div className=\"flex items-start justify-between mb-3\">\n <div className=\"flex items-center gap-2.5\">\n {onSelect && (\n <input\n type=\"checkbox\"\n checked={isSelected ?? false}\n onChange={(e) => {\n e.stopPropagation();\n onSelect(vault.id);\n }}\n onClick={(e) => e.stopPropagation()}\n className=\"size-4 rounded border-border-subtle text-primary focus:ring-primary shrink-0\"\n aria-label={tx('security.vaultCard.checkbox.aria', 'Select vault {name}', {\n name: vault.name,\n })}\n />\n )}\n <div className=\"p-2 rounded-lg bg-action-primary-bg/10 text-primary\">\n <KeyRound className=\"size-5\" />\n </div>\n <div>\n <h3 className=\"font-semibold text-text-primary leading-tight\">{vault.name}</h3>\n {vault.description && (\n <p className=\"text-xs text-text-secondary mt-0.5 line-clamp-1\">\n {vault.description}\n </p>\n )}\n </div>\n </div>\n <Badge variant={status.variant}>\n {StatusIcon && <StatusIcon className=\"size-3\" />}\n {status.label}\n </Badge>\n </div>\n\n <div className=\"flex items-center gap-4 text-sm text-text-secondary\">\n <div className=\"flex items-center gap-1.5\" aria-label={secretLabel}>\n <KeyRound className=\"size-3.5\" />\n <span aria-hidden=\"true\">{secretLabel}</span>\n </div>\n <div className=\"flex items-center gap-1.5\" aria-label={memberLabel}>\n <Users className=\"size-3.5\" />\n <span aria-hidden=\"true\">{memberLabel}</span>\n </div>\n </div>\n </Card>\n );\n};\n"],"mappings":";;;;;;;AAgBA,IAAa,KAAiC,EAC5C,UACA,YACA,eACA,aACA,mBACI;CACJ,IAAM,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,GAAkB,MACzC,EAAsB,GAAG,GAAK,GAAU,EAAO,EAE3C,IAGF;EACF,QAAQ;GACN,OAAO,EAAG,oCAAoC,SAAS;GACvD,SAAS;GACT,MAAM;GACP;EACD,QAAQ;GACN,OAAO,EAAG,oCAAoC,SAAS;GACvD,SAAS;GACT,MAAM;GACP;EACD,UAAU;GACR,OAAO,EAAG,sCAAsC,WAAW;GAC3D,SAAS;GACT,MAAM;GACP;EACD,WAAW;GACT,OAAO,EAAG,uCAAuC,YAAY;GAC7D,SAAS;GACT,MAAM;GACP;EACD,SAAS;GACP,OAAO,EAAG,qCAAqC,UAAU;GACzD,SAAS;GACT,MAAM;GACP;EACF,EAEK,IAAS,EAAa,EAAM,WAAW,EAAa,QACpD,IAAa,EAAO,MAEpB,IACJ,EAAM,gBAAgB,IAClB,EAAG,2CAA2C,kBAAkB,EAC9D,OAAO,EAAM,aACd,CAAC,GACF,EAAG,yCAAyC,mBAAmB,EAC7D,OAAO,EAAM,aACd,CAAC,EAEF,IACJ,EAAM,gBAAgB,IAClB,EAAG,2CAA2C,kBAAkB,EAC9D,OAAO,EAAM,aACd,CAAC,GACF,EAAG,yCAAyC,mBAAmB,EAC7D,OAAO,EAAM,aACd,CAAC;AAER,QACE,kBAAC,GAAD;EACW;EACT,WAAW,EACT,OACA,8EACA,KAAc,0BACd,EACD;EACD,iBAAe;EACf,aAAU;YATZ,CAWE,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,OAAD;IAAK,WAAU;cAAf;KACG,KACC,kBAAC,SAAD;MACE,MAAK;MACL,SAAS,KAAc;MACvB,WAAW,MAAM;AAEf,OADA,EAAE,iBAAiB,EACnB,EAAS,EAAM,GAAG;;MAEpB,UAAU,MAAM,EAAE,iBAAiB;MACnC,WAAU;MACV,cAAY,EAAG,oCAAoC,uBAAuB,EACxE,MAAM,EAAM,MACb,CAAC;MACF,CAAA;KAEJ,kBAAC,OAAD;MAAK,WAAU;gBACb,kBAAC,GAAD,EAAU,WAAU,UAAW,CAAA;MAC3B,CAAA;KACN,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,MAAD;MAAI,WAAU;gBAAiD,EAAM;MAAU,CAAA,EAC9E,EAAM,eACL,kBAAC,KAAD;MAAG,WAAU;gBACV,EAAM;MACL,CAAA,CAEF,EAAA,CAAA;KACF;OACN,kBAAC,GAAD;IAAO,SAAS,EAAO;cAAvB,
|
|
1
|
+
{"version":3,"file":"VaultCard.js","names":[],"sources":["../../../src/security/components/VaultCard.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { KeyRound, Users, Lock, Archive } from 'lucide-react';\nimport { cn } from '../utils/cn';\nimport { Card, Badge } from './ui';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\nimport { translateWithFallback } from '../utils/i18n';\nimport type { Vault } from '../types';\n\ninterface VaultCardProps {\n vault: Vault;\n onClick?: () => void;\n isSelected?: boolean;\n onSelect?: (vaultId: string) => void;\n className?: string;\n}\n\nexport const VaultCard: FC<VaultCardProps> = ({\n vault,\n onClick,\n isSelected,\n onSelect,\n className,\n}) => {\n const { t } = useI18n();\n const tx = (key: string, fallback: string, params?: Record<string, string | number>) =>\n translateWithFallback(t, key, fallback, params);\n\n const statusConfig: Record<\n string,\n { label: string; variant: 'success' | 'warning' | 'outline'; icon: typeof Lock | null }\n > = {\n ACTIVE: {\n label: tx('security.vaultCard.status.active', 'Active'),\n variant: 'success',\n icon: null,\n },\n LOCKED: {\n label: tx('security.vaultCard.status.locked', 'Locked'),\n variant: 'warning',\n icon: Lock,\n },\n ARCHIVED: {\n label: tx('security.vaultCard.status.archived', 'Archived'),\n variant: 'outline',\n icon: Archive,\n },\n SUSPENDED: {\n label: tx('security.vaultCard.status.suspended', 'Suspended'),\n variant: 'outline',\n icon: Archive,\n },\n DELETED: {\n label: tx('security.vaultCard.status.deleted', 'Deleted'),\n variant: 'outline',\n icon: Archive,\n },\n };\n\n const status = statusConfig[vault.status] ?? statusConfig.ACTIVE;\n const StatusIcon = status.icon;\n\n const secretLabel =\n vault.secretCount === 1\n ? tx('security.vaultCard.secretCount.singular', '{count} secret', {\n count: vault.secretCount,\n })\n : tx('security.vaultCard.secretCount.plural', '{count} secrets', {\n count: vault.secretCount,\n });\n\n const memberLabel =\n vault.memberCount === 1\n ? tx('security.vaultCard.memberCount.singular', '{count} member', {\n count: vault.memberCount,\n })\n : tx('security.vaultCard.memberCount.plural', '{count} members', {\n count: vault.memberCount,\n });\n\n return (\n <Card\n onClick={onClick}\n className={cn(\n 'p-5',\n 'focus-visible:ring-2 focus-visible:ring-primary focus-visible:outline-none',\n isSelected && 'ring-2 ring-primary/50',\n className\n )}\n aria-selected={isSelected}\n data-tour=\"vaults-card-item\"\n >\n <div className=\"flex items-start justify-between mb-3\">\n <div className=\"flex items-center gap-2.5\">\n {onSelect && (\n <input\n type=\"checkbox\"\n checked={isSelected ?? false}\n onChange={(e) => {\n e.stopPropagation();\n onSelect(vault.id);\n }}\n onClick={(e) => e.stopPropagation()}\n className=\"size-4 rounded border-border-subtle text-primary focus:ring-primary shrink-0\"\n aria-label={tx('security.vaultCard.checkbox.aria', 'Select vault {name}', {\n name: vault.name,\n })}\n />\n )}\n <div className=\"p-2 rounded-lg bg-action-primary-bg/10 text-primary\">\n <KeyRound className=\"size-5\" />\n </div>\n <div>\n <h3 className=\"font-semibold text-text-primary leading-tight\">{vault.name}</h3>\n {vault.description && (\n <p className=\"text-xs text-text-secondary mt-0.5 line-clamp-1\">\n {vault.description}\n </p>\n )}\n </div>\n </div>\n <Badge variant={status.variant}>\n {vault.status === 'ACTIVE' && (\n <span\n aria-hidden=\"true\"\n className=\"size-1.5 rounded-full bg-status-success-text motion-safe:animate-vc-glow-pulse\"\n />\n )}\n {StatusIcon && <StatusIcon className=\"size-3\" />}\n {status.label}\n </Badge>\n </div>\n\n <div className=\"flex items-center gap-4 text-sm text-text-secondary\">\n <div className=\"flex items-center gap-1.5\" aria-label={secretLabel}>\n <KeyRound className=\"size-3.5\" />\n <span aria-hidden=\"true\">{secretLabel}</span>\n </div>\n <div className=\"flex items-center gap-1.5\" aria-label={memberLabel}>\n <Users className=\"size-3.5\" />\n <span aria-hidden=\"true\">{memberLabel}</span>\n </div>\n </div>\n </Card>\n );\n};\n"],"mappings":";;;;;;;AAgBA,IAAa,KAAiC,EAC5C,UACA,YACA,eACA,aACA,mBACI;CACJ,IAAM,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,GAAkB,MACzC,EAAsB,GAAG,GAAK,GAAU,EAAO,EAE3C,IAGF;EACF,QAAQ;GACN,OAAO,EAAG,oCAAoC,SAAS;GACvD,SAAS;GACT,MAAM;GACP;EACD,QAAQ;GACN,OAAO,EAAG,oCAAoC,SAAS;GACvD,SAAS;GACT,MAAM;GACP;EACD,UAAU;GACR,OAAO,EAAG,sCAAsC,WAAW;GAC3D,SAAS;GACT,MAAM;GACP;EACD,WAAW;GACT,OAAO,EAAG,uCAAuC,YAAY;GAC7D,SAAS;GACT,MAAM;GACP;EACD,SAAS;GACP,OAAO,EAAG,qCAAqC,UAAU;GACzD,SAAS;GACT,MAAM;GACP;EACF,EAEK,IAAS,EAAa,EAAM,WAAW,EAAa,QACpD,IAAa,EAAO,MAEpB,IACJ,EAAM,gBAAgB,IAClB,EAAG,2CAA2C,kBAAkB,EAC9D,OAAO,EAAM,aACd,CAAC,GACF,EAAG,yCAAyC,mBAAmB,EAC7D,OAAO,EAAM,aACd,CAAC,EAEF,IACJ,EAAM,gBAAgB,IAClB,EAAG,2CAA2C,kBAAkB,EAC9D,OAAO,EAAM,aACd,CAAC,GACF,EAAG,yCAAyC,mBAAmB,EAC7D,OAAO,EAAM,aACd,CAAC;AAER,QACE,kBAAC,GAAD;EACW;EACT,WAAW,EACT,OACA,8EACA,KAAc,0BACd,EACD;EACD,iBAAe;EACf,aAAU;YATZ,CAWE,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,OAAD;IAAK,WAAU;cAAf;KACG,KACC,kBAAC,SAAD;MACE,MAAK;MACL,SAAS,KAAc;MACvB,WAAW,MAAM;AAEf,OADA,EAAE,iBAAiB,EACnB,EAAS,EAAM,GAAG;;MAEpB,UAAU,MAAM,EAAE,iBAAiB;MACnC,WAAU;MACV,cAAY,EAAG,oCAAoC,uBAAuB,EACxE,MAAM,EAAM,MACb,CAAC;MACF,CAAA;KAEJ,kBAAC,OAAD;MAAK,WAAU;gBACb,kBAAC,GAAD,EAAU,WAAU,UAAW,CAAA;MAC3B,CAAA;KACN,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,MAAD;MAAI,WAAU;gBAAiD,EAAM;MAAU,CAAA,EAC9E,EAAM,eACL,kBAAC,KAAD;MAAG,WAAU;gBACV,EAAM;MACL,CAAA,CAEF,EAAA,CAAA;KACF;OACN,kBAAC,GAAD;IAAO,SAAS,EAAO;cAAvB;KACG,EAAM,WAAW,YAChB,kBAAC,QAAD;MACE,eAAY;MACZ,WAAU;MACV,CAAA;KAEH,KAAc,kBAAC,GAAD,EAAY,WAAU,UAAW,CAAA;KAC/C,EAAO;KACF;MACJ;MAEN,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,OAAD;IAAK,WAAU;IAA4B,cAAY;cAAvD,CACE,kBAAC,GAAD,EAAU,WAAU,YAAa,CAAA,EACjC,kBAAC,QAAD;KAAM,eAAY;eAAQ;KAAmB,CAAA,CACzC;OACN,kBAAC,OAAD;IAAK,WAAU;IAA4B,cAAY;cAAvD,CACE,kBAAC,GAAD,EAAO,WAAU,YAAa,CAAA,EAC9B,kBAAC,QAAD;KAAM,eAAY;eAAQ;KAAmB,CAAA,CACzC;MACF;KACD"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { cn as e } from "../utils/cn.js";
|
|
2
2
|
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
3
|
-
import
|
|
3
|
+
import "@burdenoff/fe-libs/ui";
|
|
4
4
|
//#region src/security/components/ui.tsx
|
|
5
|
-
var
|
|
5
|
+
var r = ({ children: n, variant: r = "default", className: i }) => /* @__PURE__ */ t("span", {
|
|
6
6
|
className: e("inline-flex items-center gap-1 rounded-full px-2.5 py-0.5 text-xs font-medium", {
|
|
7
7
|
default: "bg-action-primary-bg/10 text-primary",
|
|
8
8
|
success: "bg-status-success-bg-subtle text-status-success-text",
|
|
@@ -11,7 +11,7 @@ var i = ({ children: n, variant: r = "default", className: i }) => /* @__PURE__
|
|
|
11
11
|
outline: "border border-border-subtle text-text-secondary"
|
|
12
12
|
}[r], i),
|
|
13
13
|
children: n
|
|
14
|
-
}),
|
|
14
|
+
}), i = ({ children: n, variant: r = "primary", size: i = "md", className: a, ...o }) => /* @__PURE__ */ t("button", {
|
|
15
15
|
type: "button",
|
|
16
16
|
className: e("inline-flex items-center justify-center gap-2 rounded-md font-medium transition-colors", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", "disabled:pointer-events-none disabled:opacity-50", {
|
|
17
17
|
primary: "bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90",
|
|
@@ -27,7 +27,7 @@ var i = ({ children: n, variant: r = "default", className: i }) => /* @__PURE__
|
|
|
27
27
|
}[i], a),
|
|
28
28
|
...o,
|
|
29
29
|
children: n
|
|
30
|
-
}),
|
|
30
|
+
}), a = ({ label: r, className: i, id: a, ...o }) => /* @__PURE__ */ n("div", {
|
|
31
31
|
className: "space-y-1.5",
|
|
32
32
|
children: [r && /* @__PURE__ */ t("label", {
|
|
33
33
|
htmlFor: a,
|
|
@@ -38,7 +38,7 @@ var i = ({ children: n, variant: r = "default", className: i }) => /* @__PURE__
|
|
|
38
38
|
className: e("flex h-9 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-1 text-sm", "placeholder:text-text-secondary", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", "disabled:cursor-not-allowed disabled:opacity-50", i),
|
|
39
39
|
...o
|
|
40
40
|
})]
|
|
41
|
-
}),
|
|
41
|
+
}), o = ({ children: n, className: r, onClick: i, ...a }) => i ? /* @__PURE__ */ t("button", {
|
|
42
42
|
type: "button",
|
|
43
43
|
className: e("block w-full text-left rounded-card border border-border-seam bg-bg-surface text-text-primary shadow-[var(--shadow-pop)]", "cursor-pointer transition-[box-shadow,border-color] duration-200 hover:shadow-[var(--shadow-pop-hover)] hover:border-border-strong", r),
|
|
44
44
|
onClick: i,
|
|
@@ -48,15 +48,7 @@ var i = ({ children: n, variant: r = "default", className: i }) => /* @__PURE__
|
|
|
48
48
|
className: e("rounded-card border border-border-seam bg-bg-surface text-text-primary shadow-elevation-1", r),
|
|
49
49
|
...a,
|
|
50
50
|
children: n
|
|
51
|
-
}),
|
|
52
|
-
className: o,
|
|
53
|
-
children: /* @__PURE__ */ t(r, {
|
|
54
|
-
icon: e,
|
|
55
|
-
title: n,
|
|
56
|
-
description: i,
|
|
57
|
-
action: a
|
|
58
|
-
})
|
|
59
|
-
}), l = ({ label: r, value: i, onChange: a, options: o, className: s, disabled: c, id: l }) => /* @__PURE__ */ n("div", {
|
|
51
|
+
}), s = ({ label: r, value: i, onChange: a, options: o, className: s, disabled: c, id: l }) => /* @__PURE__ */ n("div", {
|
|
60
52
|
className: "space-y-1.5",
|
|
61
53
|
children: [r && /* @__PURE__ */ t("label", {
|
|
62
54
|
htmlFor: l,
|
|
@@ -75,6 +67,6 @@ var i = ({ children: n, variant: r = "default", className: i }) => /* @__PURE__
|
|
|
75
67
|
})]
|
|
76
68
|
});
|
|
77
69
|
//#endregion
|
|
78
|
-
export {
|
|
70
|
+
export { r as Badge, i as Button, o as Card, a as Input, s as Select };
|
|
79
71
|
|
|
80
72
|
//# sourceMappingURL=ui.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ui.js","names":[],"sources":["../../../src/security/components/ui.tsx"],"sourcesContent":["import type {\n FC,\n ReactNode,\n ButtonHTMLAttributes,\n InputHTMLAttributes,\n HTMLAttributes,\n} from 'react';\nimport { EmptyState as CanonicalEmptyState } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/cn';\n\n/**\n * Badge component\n */\nexport const Badge: FC<{\n children: ReactNode;\n variant?: 'default' | 'success' | 'warning' | 'destructive' | 'outline';\n className?: string;\n}> = ({ children, variant = 'default', className }) => {\n const variants = {\n default: 'bg-action-primary-bg/10 text-primary',\n success: 'bg-status-success-bg-subtle text-status-success-text',\n warning: 'bg-status-warning-bg-subtle text-status-warning-text',\n destructive: 'bg-status-error-bg-subtle text-status-error-text',\n outline: 'border border-border-subtle text-text-secondary',\n };\n\n return (\n <span\n className={cn(\n 'inline-flex items-center gap-1 rounded-full px-2.5 py-0.5 text-xs font-medium',\n variants[variant],\n className\n )}\n >\n {children}\n </span>\n );\n};\n\n/**\n * Button component\n */\nexport const Button: FC<\n ButtonHTMLAttributes<HTMLButtonElement> & {\n variant?: 'primary' | 'secondary' | 'outline' | 'ghost' | 'destructive' | 'link';\n size?: 'sm' | 'md' | 'lg';\n }\n> = ({ children, variant = 'primary', size = 'md', className, ...props }) => {\n const variants = {\n primary: 'bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90',\n secondary: 'bg-secondary text-secondary-foreground hover:bg-secondary/80',\n outline: 'border border-border-subtle bg-transparent hover:bg-accent hover:text-text-primary',\n ghost: 'hover:bg-accent hover:text-text-primary',\n destructive: 'bg-status-error-bg text-status-error-text hover:bg-status-error-bg/90',\n link: 'text-primary underline-offset-4 hover:underline h-auto p-0',\n };\n\n const sizes = {\n sm: 'h-8 px-3 text-xs',\n md: 'h-9 px-4 text-sm',\n lg: 'h-10 px-6 text-sm',\n };\n\n return (\n <button\n type=\"button\"\n className={cn(\n 'inline-flex items-center justify-center gap-2 rounded-md font-medium transition-colors',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n 'disabled:pointer-events-none disabled:opacity-50',\n variants[variant],\n variant !== 'link' && sizes[size],\n className\n )}\n {...props}\n >\n {children}\n </button>\n );\n};\n\n/**\n * Input component\n */\nexport const Input: FC<InputHTMLAttributes<HTMLInputElement> & { label?: string }> = ({\n label,\n className,\n id,\n ...props\n}) => {\n return (\n <div className=\"space-y-1.5\">\n {label && (\n <label htmlFor={id} className=\"text-sm font-medium text-text-primary\">\n {label}\n </label>\n )}\n <input\n id={id}\n className={cn(\n 'flex h-9 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-1 text-sm',\n 'placeholder:text-text-secondary',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n className\n )}\n {...props}\n />\n </div>\n );\n};\n\n/**\n * Card component\n */\nexport const Card: FC<HTMLAttributes<HTMLDivElement> & { onClick?: () => void }> = ({\n children,\n className,\n onClick,\n ...props\n}) => {\n if (onClick) {\n return (\n <button\n type=\"button\"\n className={cn(\n 'block w-full text-left rounded-card border border-border-seam bg-bg-surface text-text-primary shadow-[var(--shadow-pop)]',\n // No-movement policy (Boff UI 2.0): hover only intensifies shadow/border\n // (a calm highlight). Never translate or scale the card.\n 'cursor-pointer transition-[box-shadow,border-color] duration-200 hover:shadow-[var(--shadow-pop-hover)] hover:border-border-strong',\n className\n )}\n onClick={onClick}\n {...(props as HTMLAttributes<HTMLButtonElement>)}\n >\n {children}\n </button>\n );\n }\n\n return (\n <div\n className={cn(\n 'rounded-card border border-border-seam bg-bg-surface text-text-primary shadow-elevation-1',\n className\n )}\n {...props}\n >\n {children}\n </div>\n );\n};\n\n/**\n * Empty state component\n */\nexport const EmptyState: FC<{\n icon?: ReactNode;\n title: string;\n description?: string;\n action?: ReactNode;\n className?: string;\n}> = ({ icon, title, description, action, className }) => {\n return (\n <div className={className}>\n <CanonicalEmptyState icon={icon} title={title} description={description} action={action} />\n </div>\n );\n};\n\n/**\n * Select component\n */\nexport const Select: FC<{\n label?: string;\n value: string;\n onChange: (value: string) => void;\n options: Array<{ value: string; label: string }>;\n className?: string;\n disabled?: boolean;\n id?: string;\n}> = ({ label, value, onChange, options, className, disabled, id }) => {\n return (\n <div className=\"space-y-1.5\">\n {label && (\n <label htmlFor={id} className=\"text-sm font-medium text-text-primary\">\n {label}\n </label>\n )}\n <select\n id={id}\n value={value}\n onChange={(e) => onChange(e.target.value)}\n disabled={disabled}\n className={cn(\n 'flex h-9 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-1 text-sm',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n className\n )}\n >\n {options.map((opt) => (\n <option key={opt.value} value={opt.value}>\n {opt.label}\n </option>\n ))}\n </select>\n </div>\n );\n};\n"],"mappings":";;;;AAaA,IAAa,KAIP,EAAE,aAAU,aAAU,WAAW,mBAUnC,kBAAC,QAAD;CACE,WAAW,EACT,iFAXW;EACf,SAAS;EACT,SAAS;EACT,SAAS;EACT,aAAa;EACb,SAAS;EACV,CAMc,IACT,EACD;CAEA;CACI,CAAA,EAOE,KAKR,EAAE,aAAU,aAAU,WAAW,UAAO,MAAM,cAAW,GAAG,QAiB7D,kBAAC,UAAD;CACE,MAAK;CACL,WAAW,EACT,0FACA,gGACA,oDArBW;EACf,SAAS;EACT,WAAW;EACX,SAAS;EACT,OAAO;EACP,aAAa;EACb,MAAM;EACP,CAec,IACT,MAAY,UAdJ;EACZ,IAAI;EACJ,IAAI;EACJ,IAAI;EACL,CAUiC,IAC5B,EACD;CACD,GAAI;CAEH;CACM,CAAA,EAOA,KAAyE,EACpF,UACA,cACA,OACA,GAAG,QAGD,kBAAC,OAAD;CAAK,WAAU;WAAf,CACG,KACC,kBAAC,SAAD;EAAO,SAAS;EAAI,WAAU;YAC3B;EACK,CAAA,EAEV,kBAAC,SAAD;EACM;EACJ,WAAW,EACT,0FACA,mCACA,gGACA,mDACA,EACD;EACD,GAAI;EACJ,CAAA,CACE;IAOG,KAAuE,EAClF,aACA,cACA,YACA,GAAG,QAEC,IAEA,kBAAC,UAAD;CACE,MAAK;CACL,WAAW,EACT,4HAGA,sIACA,EACD;CACQ;CACT,GAAK;CAEJ;CACM,CAAA,GAKX,kBAAC,OAAD;CACE,WAAW,EACT,6FACA,EACD;CACD,GAAI;CAEH;CACG,CAAA,
|
|
1
|
+
{"version":3,"file":"ui.js","names":[],"sources":["../../../src/security/components/ui.tsx"],"sourcesContent":["import type {\n FC,\n ReactNode,\n ButtonHTMLAttributes,\n InputHTMLAttributes,\n HTMLAttributes,\n} from 'react';\nimport { EmptyState as CanonicalEmptyState } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/cn';\n\n/**\n * Badge component\n */\nexport const Badge: FC<{\n children: ReactNode;\n variant?: 'default' | 'success' | 'warning' | 'destructive' | 'outline';\n className?: string;\n}> = ({ children, variant = 'default', className }) => {\n const variants = {\n default: 'bg-action-primary-bg/10 text-primary',\n success: 'bg-status-success-bg-subtle text-status-success-text',\n warning: 'bg-status-warning-bg-subtle text-status-warning-text',\n destructive: 'bg-status-error-bg-subtle text-status-error-text',\n outline: 'border border-border-subtle text-text-secondary',\n };\n\n return (\n <span\n className={cn(\n 'inline-flex items-center gap-1 rounded-full px-2.5 py-0.5 text-xs font-medium',\n variants[variant],\n className\n )}\n >\n {children}\n </span>\n );\n};\n\n/**\n * Button component\n */\nexport const Button: FC<\n ButtonHTMLAttributes<HTMLButtonElement> & {\n variant?: 'primary' | 'secondary' | 'outline' | 'ghost' | 'destructive' | 'link';\n size?: 'sm' | 'md' | 'lg';\n }\n> = ({ children, variant = 'primary', size = 'md', className, ...props }) => {\n const variants = {\n primary: 'bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90',\n secondary: 'bg-secondary text-secondary-foreground hover:bg-secondary/80',\n outline: 'border border-border-subtle bg-transparent hover:bg-accent hover:text-text-primary',\n ghost: 'hover:bg-accent hover:text-text-primary',\n destructive: 'bg-status-error-bg text-status-error-text hover:bg-status-error-bg/90',\n link: 'text-primary underline-offset-4 hover:underline h-auto p-0',\n };\n\n const sizes = {\n sm: 'h-8 px-3 text-xs',\n md: 'h-9 px-4 text-sm',\n lg: 'h-10 px-6 text-sm',\n };\n\n return (\n <button\n type=\"button\"\n className={cn(\n 'inline-flex items-center justify-center gap-2 rounded-md font-medium transition-colors',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n 'disabled:pointer-events-none disabled:opacity-50',\n variants[variant],\n variant !== 'link' && sizes[size],\n className\n )}\n {...props}\n >\n {children}\n </button>\n );\n};\n\n/**\n * Input component\n */\nexport const Input: FC<InputHTMLAttributes<HTMLInputElement> & { label?: string }> = ({\n label,\n className,\n id,\n ...props\n}) => {\n return (\n <div className=\"space-y-1.5\">\n {label && (\n <label htmlFor={id} className=\"text-sm font-medium text-text-primary\">\n {label}\n </label>\n )}\n <input\n id={id}\n className={cn(\n 'flex h-9 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-1 text-sm',\n 'placeholder:text-text-secondary',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n className\n )}\n {...props}\n />\n </div>\n );\n};\n\n/**\n * Card component\n */\nexport const Card: FC<HTMLAttributes<HTMLDivElement> & { onClick?: () => void }> = ({\n children,\n className,\n onClick,\n ...props\n}) => {\n if (onClick) {\n return (\n <button\n type=\"button\"\n className={cn(\n 'block w-full text-left rounded-card border border-border-seam bg-bg-surface text-text-primary shadow-[var(--shadow-pop)]',\n // No-movement policy (Boff UI 2.0): hover only intensifies shadow/border\n // (a calm highlight). Never translate or scale the card.\n 'cursor-pointer transition-[box-shadow,border-color] duration-200 hover:shadow-[var(--shadow-pop-hover)] hover:border-border-strong',\n className\n )}\n onClick={onClick}\n {...(props as HTMLAttributes<HTMLButtonElement>)}\n >\n {children}\n </button>\n );\n }\n\n return (\n <div\n className={cn(\n 'rounded-card border border-border-seam bg-bg-surface text-text-primary shadow-elevation-1',\n className\n )}\n {...props}\n >\n {children}\n </div>\n );\n};\n\n/**\n * Empty state component\n */\nexport const EmptyState: FC<{\n icon?: ReactNode;\n title: string;\n description?: string;\n action?: ReactNode;\n className?: string;\n}> = ({ icon, title, description, action, className }) => {\n return (\n <div className={className}>\n <CanonicalEmptyState icon={icon} title={title} description={description} action={action} />\n </div>\n );\n};\n\n/**\n * Select component\n */\nexport const Select: FC<{\n label?: string;\n value: string;\n onChange: (value: string) => void;\n options: Array<{ value: string; label: string }>;\n className?: string;\n disabled?: boolean;\n id?: string;\n}> = ({ label, value, onChange, options, className, disabled, id }) => {\n return (\n <div className=\"space-y-1.5\">\n {label && (\n <label htmlFor={id} className=\"text-sm font-medium text-text-primary\">\n {label}\n </label>\n )}\n <select\n id={id}\n value={value}\n onChange={(e) => onChange(e.target.value)}\n disabled={disabled}\n className={cn(\n 'flex h-9 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-1 text-sm',\n 'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n className\n )}\n >\n {options.map((opt) => (\n <option key={opt.value} value={opt.value}>\n {opt.label}\n </option>\n ))}\n </select>\n </div>\n );\n};\n"],"mappings":";;;;AAaA,IAAa,KAIP,EAAE,aAAU,aAAU,WAAW,mBAUnC,kBAAC,QAAD;CACE,WAAW,EACT,iFAXW;EACf,SAAS;EACT,SAAS;EACT,SAAS;EACT,aAAa;EACb,SAAS;EACV,CAMc,IACT,EACD;CAEA;CACI,CAAA,EAOE,KAKR,EAAE,aAAU,aAAU,WAAW,UAAO,MAAM,cAAW,GAAG,QAiB7D,kBAAC,UAAD;CACE,MAAK;CACL,WAAW,EACT,0FACA,gGACA,oDArBW;EACf,SAAS;EACT,WAAW;EACX,SAAS;EACT,OAAO;EACP,aAAa;EACb,MAAM;EACP,CAec,IACT,MAAY,UAdJ;EACZ,IAAI;EACJ,IAAI;EACJ,IAAI;EACL,CAUiC,IAC5B,EACD;CACD,GAAI;CAEH;CACM,CAAA,EAOA,KAAyE,EACpF,UACA,cACA,OACA,GAAG,QAGD,kBAAC,OAAD;CAAK,WAAU;WAAf,CACG,KACC,kBAAC,SAAD;EAAO,SAAS;EAAI,WAAU;YAC3B;EACK,CAAA,EAEV,kBAAC,SAAD;EACM;EACJ,WAAW,EACT,0FACA,mCACA,gGACA,mDACA,EACD;EACD,GAAI;EACJ,CAAA,CACE;IAOG,KAAuE,EAClF,aACA,cACA,YACA,GAAG,QAEC,IAEA,kBAAC,UAAD;CACE,MAAK;CACL,WAAW,EACT,4HAGA,sIACA,EACD;CACQ;CACT,GAAK;CAEJ;CACM,CAAA,GAKX,kBAAC,OAAD;CACE,WAAW,EACT,6FACA,EACD;CACD,GAAI;CAEH;CACG,CAAA,EAwBG,KAQP,EAAE,UAAO,UAAO,aAAU,YAAS,cAAW,aAAU,YAE1D,kBAAC,OAAD;CAAK,WAAU;WAAf,CACG,KACC,kBAAC,SAAD;EAAO,SAAS;EAAI,WAAU;YAC3B;EACK,CAAA,EAEV,kBAAC,UAAD;EACM;EACG;EACP,WAAW,MAAM,EAAS,EAAE,OAAO,MAAM;EAC/B;EACV,WAAW,EACT,0FACA,gGACA,mDACA,EACD;YAEA,EAAQ,KAAK,MACZ,kBAAC,UAAD;GAAwB,OAAO,EAAI;aAChC,EAAI;GACE,EAFI,EAAI,MAER,CACT;EACK,CAAA,CACL"}
|
|
@@ -1,139 +1,170 @@
|
|
|
1
1
|
import { useSecurity as e } from "../providers/SecurityProvider.js";
|
|
2
2
|
import { PageLayout as t } from "../components/PageLayout.js";
|
|
3
|
-
import { Badge as n, Button as r, Card as i
|
|
4
|
-
import { useGetVaults as
|
|
5
|
-
import { getVaultRoleInfo as
|
|
6
|
-
import { jsx as
|
|
7
|
-
import { AlertTriangle as
|
|
8
|
-
import {
|
|
3
|
+
import { Badge as n, Button as r, Card as i } from "../components/ui.js";
|
|
4
|
+
import { useGetVaults as a } from "../hooks/useVaultQueries.js";
|
|
5
|
+
import { getVaultRoleInfo as o } from "../constants/permissions.js";
|
|
6
|
+
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
7
|
+
import { AlertTriangle as l, Loader2 as u, Lock as d, Shield as f } from "lucide-react";
|
|
8
|
+
import { EmphasisPanel as p, IllustratedEmptyState as m, PagePurpose as h, ResponsiveTable as g } from "@burdenoff/fe-libs/ui";
|
|
9
9
|
//#region src/security/pages/AccessReviewPage.tsx
|
|
10
|
-
function
|
|
11
|
-
let { basePath:
|
|
12
|
-
return
|
|
10
|
+
function _() {
|
|
11
|
+
let { basePath: _ = "/" } = e(), { data: v, loading: y, error: b, refetch: x } = a(void 0, { limit: 100 }), S = v?.getVaults?.items ?? [];
|
|
12
|
+
return y ? /* @__PURE__ */ s(t, {
|
|
13
13
|
title: "Access Review",
|
|
14
14
|
breadcrumbs: [{
|
|
15
15
|
label: "Security",
|
|
16
|
-
path:
|
|
16
|
+
path: _
|
|
17
17
|
}, { label: "Access Review" }],
|
|
18
|
-
children: /* @__PURE__ */
|
|
18
|
+
children: /* @__PURE__ */ s("div", {
|
|
19
19
|
className: "flex items-center justify-center py-16",
|
|
20
|
-
children: /* @__PURE__ */
|
|
20
|
+
children: /* @__PURE__ */ s(u, { className: "size-8 animate-spin text-primary" })
|
|
21
21
|
})
|
|
22
|
-
}) :
|
|
22
|
+
}) : b ? /* @__PURE__ */ s(t, {
|
|
23
23
|
title: "Access Review",
|
|
24
24
|
breadcrumbs: [{
|
|
25
25
|
label: "Security",
|
|
26
|
-
path:
|
|
26
|
+
path: _
|
|
27
27
|
}, { label: "Access Review" }],
|
|
28
|
-
children: /* @__PURE__ */
|
|
28
|
+
children: /* @__PURE__ */ s(i, {
|
|
29
29
|
className: "p-6",
|
|
30
|
-
children: /* @__PURE__ */
|
|
30
|
+
children: /* @__PURE__ */ c("div", {
|
|
31
31
|
className: "flex items-start gap-4",
|
|
32
|
-
children: [/* @__PURE__ */
|
|
33
|
-
/* @__PURE__ */
|
|
32
|
+
children: [/* @__PURE__ */ s(l, { className: "size-6 text-status-error-text" }), /* @__PURE__ */ c("div", { children: [
|
|
33
|
+
/* @__PURE__ */ s("h3", {
|
|
34
34
|
className: "font-semibold text-status-error-text",
|
|
35
35
|
children: "Failed to load access data"
|
|
36
36
|
}),
|
|
37
|
-
/* @__PURE__ */
|
|
37
|
+
/* @__PURE__ */ s("p", {
|
|
38
38
|
className: "text-sm text-text-secondary mt-1",
|
|
39
|
-
children:
|
|
39
|
+
children: b.message
|
|
40
40
|
}),
|
|
41
|
-
/* @__PURE__ */
|
|
41
|
+
/* @__PURE__ */ s(r, {
|
|
42
42
|
variant: "outline",
|
|
43
43
|
size: "sm",
|
|
44
44
|
className: "mt-3",
|
|
45
|
-
onClick: () =>
|
|
45
|
+
onClick: () => x(),
|
|
46
46
|
children: "Retry"
|
|
47
47
|
})
|
|
48
48
|
] })]
|
|
49
49
|
})
|
|
50
50
|
})
|
|
51
|
-
}) : /* @__PURE__ */
|
|
51
|
+
}) : /* @__PURE__ */ s(t, {
|
|
52
52
|
title: "Access Review",
|
|
53
53
|
description: "Review who has access to each vault and their permission levels.",
|
|
54
54
|
breadcrumbs: [{
|
|
55
55
|
label: "Security",
|
|
56
|
-
path:
|
|
56
|
+
path: _
|
|
57
57
|
}, { label: "Access Review" }],
|
|
58
|
-
children:
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
58
|
+
children: S.length === 0 ? /* @__PURE__ */ c("div", {
|
|
59
|
+
className: "space-y-6",
|
|
60
|
+
children: [/* @__PURE__ */ s(h, {
|
|
61
|
+
icon: /* @__PURE__ */ s(f, { className: "size-4" }),
|
|
62
|
+
children: "Access review shows, vault by vault, exactly who can reach your secrets and at what role (owner, editor, viewer). Use it periodically to catch over-broad access — people who no longer need a vault, or roles that are higher than necessary — and tighten permissions before an audit."
|
|
63
|
+
}), /* @__PURE__ */ s(m, {
|
|
64
|
+
illustration: "empty-people",
|
|
65
|
+
title: "No vaults to review",
|
|
66
|
+
description: "Create vaults and share them with team members to see access details here."
|
|
67
|
+
})]
|
|
62
68
|
}) : /* @__PURE__ */ c("div", {
|
|
63
|
-
className: "space-y-
|
|
64
|
-
children:
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
69
|
+
className: "space-y-6",
|
|
70
|
+
children: [
|
|
71
|
+
/* @__PURE__ */ s(h, {
|
|
72
|
+
icon: /* @__PURE__ */ s(f, { className: "size-4" }),
|
|
73
|
+
children: "Access review shows, vault by vault, exactly who can reach your secrets and at what role (owner, editor, viewer). Use it periodically to catch over-broad access — people who no longer need a vault, or roles that are higher than necessary — and tighten permissions before an audit."
|
|
74
|
+
}),
|
|
75
|
+
/* @__PURE__ */ s(p, { children: /* @__PURE__ */ c("div", {
|
|
76
|
+
className: "flex flex-wrap items-center gap-x-8 gap-y-3",
|
|
77
|
+
children: [/* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("p", {
|
|
78
|
+
className: "text-xs uppercase tracking-wider font-semibold text-text-secondary",
|
|
79
|
+
children: "Vaults under review"
|
|
80
|
+
}), /* @__PURE__ */ s("p", {
|
|
81
|
+
className: "text-2xl font-bold text-text-primary tabular-nums",
|
|
82
|
+
children: S.length
|
|
83
|
+
})] }), /* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("p", {
|
|
84
|
+
className: "text-xs uppercase tracking-wider font-semibold text-text-secondary",
|
|
85
|
+
children: "Total access grants"
|
|
86
|
+
}), /* @__PURE__ */ s("p", {
|
|
87
|
+
className: "text-2xl font-bold text-text-primary tabular-nums",
|
|
88
|
+
children: S.reduce((e, t) => e + (t.members?.length ?? 0), 0)
|
|
89
|
+
})] })]
|
|
90
|
+
}) }),
|
|
91
|
+
/* @__PURE__ */ s("div", {
|
|
92
|
+
className: "space-y-4",
|
|
93
|
+
children: S.map((e) => {
|
|
94
|
+
let t = e.members ?? [], r = e.status === "LOCKED";
|
|
95
|
+
return /* @__PURE__ */ c(i, {
|
|
96
|
+
className: "p-5",
|
|
97
|
+
children: [/* @__PURE__ */ c("div", {
|
|
98
|
+
className: "flex items-center justify-between mb-4",
|
|
99
|
+
children: [/* @__PURE__ */ c("div", {
|
|
100
|
+
className: "flex items-center gap-3",
|
|
101
|
+
children: [r ? /* @__PURE__ */ s(d, { className: "size-5 text-status-warning-text" }) : /* @__PURE__ */ s(f, { className: "size-5 text-primary" }), /* @__PURE__ */ c("div", { children: [/* @__PURE__ */ s("h3", {
|
|
102
|
+
className: "font-semibold text-text-primary",
|
|
103
|
+
children: e.name
|
|
104
|
+
}), /* @__PURE__ */ c("p", {
|
|
105
|
+
className: "text-xs text-text-secondary",
|
|
106
|
+
children: [
|
|
107
|
+
t.length,
|
|
108
|
+
" member",
|
|
109
|
+
t.length === 1 ? "" : "s"
|
|
110
|
+
]
|
|
111
|
+
})] })]
|
|
112
|
+
}), /* @__PURE__ */ s(n, {
|
|
113
|
+
variant: r ? "warning" : "success",
|
|
114
|
+
children: r ? "Locked" : "Active"
|
|
115
|
+
})]
|
|
116
|
+
}), t.length > 0 ? /* @__PURE__ */ s(g, {
|
|
117
|
+
className: "border border-border-subtle/60 rounded-lg",
|
|
118
|
+
data: t,
|
|
119
|
+
rowKey: (e) => e.id,
|
|
120
|
+
columns: [
|
|
121
|
+
{
|
|
122
|
+
key: "actor",
|
|
123
|
+
header: "Actor",
|
|
124
|
+
priority: "primary",
|
|
125
|
+
cell: (e) => /* @__PURE__ */ s("span", {
|
|
126
|
+
className: "font-medium text-text-primary",
|
|
127
|
+
children: e.actorId
|
|
128
|
+
})
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
key: "type",
|
|
132
|
+
header: "Type",
|
|
133
|
+
cell: (e) => /* @__PURE__ */ s("span", {
|
|
134
|
+
className: "text-text-secondary capitalize",
|
|
135
|
+
children: e.actorType
|
|
136
|
+
})
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
key: "role",
|
|
140
|
+
header: "Role",
|
|
141
|
+
cell: (e) => /* @__PURE__ */ s(n, {
|
|
142
|
+
variant: "outline",
|
|
143
|
+
className: "text-[10px] uppercase font-bold tracking-tighter",
|
|
144
|
+
children: o(e.role.toLowerCase()).label
|
|
145
|
+
})
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
key: "since",
|
|
149
|
+
header: "Since",
|
|
150
|
+
cell: (e) => /* @__PURE__ */ s("span", {
|
|
151
|
+
className: "text-text-secondary",
|
|
152
|
+
children: new Date(e.createdAt).toLocaleDateString()
|
|
153
|
+
})
|
|
154
|
+
}
|
|
81
155
|
]
|
|
82
|
-
})
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
})
|
|
87
|
-
})
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
rowKey: (e) => e.id,
|
|
91
|
-
columns: [
|
|
92
|
-
{
|
|
93
|
-
key: "actor",
|
|
94
|
-
header: "Actor",
|
|
95
|
-
priority: "primary",
|
|
96
|
-
cell: (e) => /* @__PURE__ */ c("span", {
|
|
97
|
-
className: "font-medium text-text-primary",
|
|
98
|
-
children: e.actorId
|
|
99
|
-
})
|
|
100
|
-
},
|
|
101
|
-
{
|
|
102
|
-
key: "type",
|
|
103
|
-
header: "Type",
|
|
104
|
-
cell: (e) => /* @__PURE__ */ c("span", {
|
|
105
|
-
className: "text-text-secondary capitalize",
|
|
106
|
-
children: e.actorType
|
|
107
|
-
})
|
|
108
|
-
},
|
|
109
|
-
{
|
|
110
|
-
key: "role",
|
|
111
|
-
header: "Role",
|
|
112
|
-
cell: (e) => /* @__PURE__ */ c(n, {
|
|
113
|
-
variant: "outline",
|
|
114
|
-
className: "text-[10px] uppercase font-bold tracking-tighter",
|
|
115
|
-
children: s(e.role.toLowerCase()).label
|
|
116
|
-
})
|
|
117
|
-
},
|
|
118
|
-
{
|
|
119
|
-
key: "since",
|
|
120
|
-
header: "Since",
|
|
121
|
-
cell: (e) => /* @__PURE__ */ c("span", {
|
|
122
|
-
className: "text-text-secondary",
|
|
123
|
-
children: new Date(e.createdAt).toLocaleDateString()
|
|
124
|
-
})
|
|
125
|
-
}
|
|
126
|
-
]
|
|
127
|
-
}) : /* @__PURE__ */ c("p", {
|
|
128
|
-
className: "text-sm text-text-secondary text-center py-3 bg-bg-sunken/10 rounded-lg border border-dashed border-border-subtle",
|
|
129
|
-
children: "No additional members. Only the vault creator has access."
|
|
130
|
-
})]
|
|
131
|
-
}, e.id);
|
|
132
|
-
})
|
|
156
|
+
}) : /* @__PURE__ */ s("p", {
|
|
157
|
+
className: "text-sm text-text-secondary text-center py-3 bg-bg-sunken/10 rounded-lg border border-dashed border-border-subtle",
|
|
158
|
+
children: "No additional members. Only the vault creator has access."
|
|
159
|
+
})]
|
|
160
|
+
}, e.id);
|
|
161
|
+
})
|
|
162
|
+
})
|
|
163
|
+
]
|
|
133
164
|
})
|
|
134
165
|
});
|
|
135
166
|
}
|
|
136
167
|
//#endregion
|
|
137
|
-
export {
|
|
168
|
+
export { _ as AccessReviewPage };
|
|
138
169
|
|
|
139
170
|
//# sourceMappingURL=AccessReviewPage.js.map
|