@burdenoff/microfe-security 2026.525.2 → 2026.527.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/SecurityAdminRoot.js +4 -4
- package/dist/security/SecurityAdminRoot.js.map +1 -1
- package/dist/security/SecurityRoot.js +4 -4
- package/dist/security/SecurityRoot.js.map +1 -1
- package/dist/security/SecurityUserRoot.js +4 -4
- package/dist/security/SecurityUserRoot.js.map +1 -1
- package/dist/security/components/ActivityTimeline.js +1 -1
- package/dist/security/components/ActivityTimeline.js.map +1 -1
- package/dist/security/components/BulkActionBar.js +6 -5
- package/dist/security/components/BulkActionBar.js.map +1 -1
- package/dist/security/components/ConfirmDialog.js +5 -3
- package/dist/security/components/ConfirmDialog.js.map +1 -1
- package/dist/security/components/CopyButton.js +4 -3
- package/dist/security/components/CopyButton.js.map +1 -1
- package/dist/security/components/ExportDialog.js +39 -38
- package/dist/security/components/ExportDialog.js.map +1 -1
- package/dist/security/components/ImportWizard.js +14 -13
- package/dist/security/components/ImportWizard.js.map +1 -1
- package/dist/security/components/PasswordGenerator.js +8 -4
- package/dist/security/components/PasswordGenerator.js.map +1 -1
- package/dist/security/components/RotationStatusBadge.js +1 -1
- package/dist/security/components/RotationStatusBadge.js.map +1 -1
- package/dist/security/components/SecretFormFields.js +88 -75
- package/dist/security/components/SecretFormFields.js.map +1 -1
- package/dist/security/components/SecretRow.js +11 -9
- package/dist/security/components/SecretRow.js.map +1 -1
- package/dist/security/components/SecretValueDisplay.js +45 -44
- package/dist/security/components/SecretValueDisplay.js.map +1 -1
- package/dist/security/components/SecurityPermissionGuard.js +1 -1
- package/dist/security/components/SecurityPermissionGuard.js.map +1 -1
- package/dist/security/components/VaultCard.js +5 -5
- package/dist/security/components/VaultCard.js.map +1 -1
- package/dist/security/components/VaultShareDialog.js +9 -6
- package/dist/security/components/VaultShareDialog.js.map +1 -1
- package/dist/security/components/ui.js +9 -8
- package/dist/security/components/ui.js.map +1 -1
- package/dist/security/constants/providers.js.map +1 -1
- package/dist/security/hooks/useProviderQueries.js.map +1 -1
- package/dist/security/hooks/useSecretQueries.js.map +1 -1
- package/dist/security/hooks/useSecretValue.js +12 -11
- package/dist/security/hooks/useSecretValue.js.map +1 -1
- package/dist/security/hooks/useSecurityDashboard.js +10 -10
- package/dist/security/hooks/useSecurityDashboard.js.map +1 -1
- package/dist/security/hooks/useSecuritySubscriptions.js.map +1 -1
- package/dist/security/pages/AccessReviewPage.js +4 -4
- package/dist/security/pages/AccessReviewPage.js.map +1 -1
- package/dist/security/pages/AuditLogPage.js +11 -5
- package/dist/security/pages/AuditLogPage.js.map +1 -1
- package/dist/security/pages/ImportExportPage.js +4 -2
- package/dist/security/pages/ImportExportPage.js.map +1 -1
- package/dist/security/pages/ProviderDetailPage.js +12 -12
- package/dist/security/pages/ProviderDetailPage.js.map +1 -1
- package/dist/security/pages/ProvidersPage.js +9 -9
- package/dist/security/pages/ProvidersPage.js.map +1 -1
- package/dist/security/pages/SecretCreatePage.js +5 -5
- package/dist/security/pages/SecretCreatePage.js.map +1 -1
- package/dist/security/pages/SecretDetailPage.js +213 -205
- package/dist/security/pages/SecretDetailPage.js.map +1 -1
- package/dist/security/pages/SecurityDashboardPage.js +7 -7
- package/dist/security/pages/SecurityDashboardPage.js.map +1 -1
- package/dist/security/pages/VaultCreatePage.js +2 -2
- package/dist/security/pages/VaultCreatePage.js.map +1 -1
- package/dist/security/pages/VaultDetailPage.js +13 -13
- package/dist/security/pages/VaultDetailPage.js.map +1 -1
- package/dist/security/pages/VaultSettingsPage.js +160 -140
- package/dist/security/pages/VaultSettingsPage.js.map +1 -1
- package/dist/security/pages/VaultsDashboardPage.js +147 -143
- package/dist/security/pages/VaultsDashboardPage.js.map +1 -1
- package/dist/security/providers/SecurityProvider.js +1 -1
- package/dist/security/providers/SecurityProvider.js.map +1 -1
- package/dist/security/routes/routeUtils.js +4 -3
- package/dist/security/routes/routeUtils.js.map +1 -1
- package/dist/security/utils/clipboard.js.map +1 -1
- package/dist/security/utils/fileParser.js +4 -1
- package/dist/security/utils/fileParser.js.map +1 -1
- package/package.json +1 -1
- package/dist/dev/main.d.ts +0 -2
- package/dist/dev/main.d.ts.map +0 -1
- package/dist/generated/global-operations.d.ts +0 -2
- package/dist/generated/global-operations.d.ts.map +0 -1
- package/dist/generated/global-types.d.ts +0 -23527
- package/dist/generated/global-types.d.ts.map +0 -1
- package/dist/generated/wspace-operations.d.ts +0 -1461
- package/dist/generated/wspace-operations.d.ts.map +0 -1
- package/dist/generated/wspace-types.d.ts +0 -57851
- package/dist/generated/wspace-types.d.ts.map +0 -1
- package/dist/index.d.ts +0 -6
- package/dist/index.d.ts.map +0 -1
- package/dist/security/SecurityAdminRoot.d.ts +0 -19
- package/dist/security/SecurityAdminRoot.d.ts.map +0 -1
- package/dist/security/SecurityRoot.d.ts +0 -18
- package/dist/security/SecurityRoot.d.ts.map +0 -1
- package/dist/security/SecurityRootBase.d.ts +0 -19
- package/dist/security/SecurityRootBase.d.ts.map +0 -1
- package/dist/security/SecurityUserRoot.d.ts +0 -18
- package/dist/security/SecurityUserRoot.d.ts.map +0 -1
- package/dist/security/components/ActivityTimeline.d.ts +0 -12
- package/dist/security/components/ActivityTimeline.d.ts.map +0 -1
- package/dist/security/components/AuditLogTable.d.ts +0 -12
- package/dist/security/components/AuditLogTable.d.ts.map +0 -1
- package/dist/security/components/BulkActionBar.d.ts +0 -9
- package/dist/security/components/BulkActionBar.d.ts.map +0 -1
- package/dist/security/components/ConfirmDialog.d.ts +0 -19
- package/dist/security/components/ConfirmDialog.d.ts.map +0 -1
- package/dist/security/components/CopyButton.d.ts +0 -20
- package/dist/security/components/CopyButton.d.ts.map +0 -1
- package/dist/security/components/ExportDialog.d.ts +0 -7
- package/dist/security/components/ExportDialog.d.ts.map +0 -1
- package/dist/security/components/ImportWizard.d.ts +0 -7
- package/dist/security/components/ImportWizard.d.ts.map +0 -1
- package/dist/security/components/PageLayout.d.ts +0 -23
- package/dist/security/components/PageLayout.d.ts.map +0 -1
- package/dist/security/components/PasswordGenerator.d.ts +0 -17
- package/dist/security/components/PasswordGenerator.d.ts.map +0 -1
- package/dist/security/components/ProviderSetupWizard.d.ts +0 -13
- package/dist/security/components/ProviderSetupWizard.d.ts.map +0 -1
- package/dist/security/components/RotationStatusBadge.d.ts +0 -13
- package/dist/security/components/RotationStatusBadge.d.ts.map +0 -1
- package/dist/security/components/SecretFormFields.d.ts +0 -23
- package/dist/security/components/SecretFormFields.d.ts.map +0 -1
- package/dist/security/components/SecretRow.d.ts +0 -13
- package/dist/security/components/SecretRow.d.ts.map +0 -1
- package/dist/security/components/SecretTypeBadge.d.ts +0 -13
- package/dist/security/components/SecretTypeBadge.d.ts.map +0 -1
- package/dist/security/components/SecretTypeIcon.d.ts +0 -14
- package/dist/security/components/SecretTypeIcon.d.ts.map +0 -1
- package/dist/security/components/SecretValueDisplay.d.ts +0 -26
- package/dist/security/components/SecretValueDisplay.d.ts.map +0 -1
- package/dist/security/components/SecurityPermissionGuard.d.ts +0 -16
- package/dist/security/components/SecurityPermissionGuard.d.ts.map +0 -1
- package/dist/security/components/SecurityScoreCard.d.ts +0 -12
- package/dist/security/components/SecurityScoreCard.d.ts.map +0 -1
- package/dist/security/components/VaultCard.d.ts +0 -13
- package/dist/security/components/VaultCard.d.ts.map +0 -1
- package/dist/security/components/VaultFormFields.d.ts +0 -17
- package/dist/security/components/VaultFormFields.d.ts.map +0 -1
- package/dist/security/components/VaultShareDialog.d.ts +0 -16
- package/dist/security/components/VaultShareDialog.d.ts.map +0 -1
- package/dist/security/components/ui.d.ts +0 -55
- package/dist/security/components/ui.d.ts.map +0 -1
- package/dist/security/config/navigation.d.ts +0 -10
- package/dist/security/config/navigation.d.ts.map +0 -1
- package/dist/security/constants/featureFlags.d.ts +0 -36
- package/dist/security/constants/featureFlags.d.ts.map +0 -1
- package/dist/security/constants/permissions.d.ts +0 -11
- package/dist/security/constants/permissions.d.ts.map +0 -1
- package/dist/security/constants/providers.d.ts +0 -12
- package/dist/security/constants/providers.d.ts.map +0 -1
- package/dist/security/constants/secretTypes.d.ts +0 -16
- package/dist/security/constants/secretTypes.d.ts.map +0 -1
- package/dist/security/hooks/useAuditLog.d.ts +0 -4
- package/dist/security/hooks/useAuditLog.d.ts.map +0 -1
- package/dist/security/hooks/useBulkSecretOperations.d.ts +0 -7
- package/dist/security/hooks/useBulkSecretOperations.d.ts.map +0 -1
- package/dist/security/hooks/useClipboardAutoClear.d.ts +0 -10
- package/dist/security/hooks/useClipboardAutoClear.d.ts.map +0 -1
- package/dist/security/hooks/useImportExport.d.ts +0 -55
- package/dist/security/hooks/useImportExport.d.ts.map +0 -1
- package/dist/security/hooks/usePasswordGenerator.d.ts +0 -18
- package/dist/security/hooks/usePasswordGenerator.d.ts.map +0 -1
- package/dist/security/hooks/useProviderQueries.d.ts +0 -8
- package/dist/security/hooks/useProviderQueries.d.ts.map +0 -1
- package/dist/security/hooks/useSecretQueries.d.ts +0 -10
- package/dist/security/hooks/useSecretQueries.d.ts.map +0 -1
- package/dist/security/hooks/useSecretValue.d.ts +0 -12
- package/dist/security/hooks/useSecretValue.d.ts.map +0 -1
- package/dist/security/hooks/useSecurityCacheInvalidation.d.ts +0 -2
- package/dist/security/hooks/useSecurityCacheInvalidation.d.ts.map +0 -1
- package/dist/security/hooks/useSecurityDashboard.d.ts +0 -21
- package/dist/security/hooks/useSecurityDashboard.d.ts.map +0 -1
- package/dist/security/hooks/useSecurityEventEmitter.d.ts +0 -14
- package/dist/security/hooks/useSecurityEventEmitter.d.ts.map +0 -1
- package/dist/security/hooks/useSecuritySubscriptions.d.ts +0 -21
- package/dist/security/hooks/useSecuritySubscriptions.d.ts.map +0 -1
- package/dist/security/hooks/useVaultQueries.d.ts +0 -14
- package/dist/security/hooks/useVaultQueries.d.ts.map +0 -1
- package/dist/security/index.d.ts +0 -31
- package/dist/security/index.d.ts.map +0 -1
- package/dist/security/pages/AccessReviewPage.d.ts +0 -2
- package/dist/security/pages/AccessReviewPage.d.ts.map +0 -1
- package/dist/security/pages/AuditLogPage.d.ts +0 -2
- package/dist/security/pages/AuditLogPage.d.ts.map +0 -1
- package/dist/security/pages/ImportExportPage.d.ts +0 -2
- package/dist/security/pages/ImportExportPage.d.ts.map +0 -1
- package/dist/security/pages/ProviderDetailPage.d.ts +0 -2
- package/dist/security/pages/ProviderDetailPage.d.ts.map +0 -1
- package/dist/security/pages/ProvidersPage.d.ts +0 -2
- package/dist/security/pages/ProvidersPage.d.ts.map +0 -1
- package/dist/security/pages/SecretCreatePage.d.ts +0 -2
- package/dist/security/pages/SecretCreatePage.d.ts.map +0 -1
- package/dist/security/pages/SecretDetailPage.d.ts +0 -2
- package/dist/security/pages/SecretDetailPage.d.ts.map +0 -1
- package/dist/security/pages/SecurityDashboardPage.d.ts +0 -2
- package/dist/security/pages/SecurityDashboardPage.d.ts.map +0 -1
- package/dist/security/pages/VaultCreatePage.d.ts +0 -2
- package/dist/security/pages/VaultCreatePage.d.ts.map +0 -1
- package/dist/security/pages/VaultDetailPage.d.ts +0 -2
- package/dist/security/pages/VaultDetailPage.d.ts.map +0 -1
- package/dist/security/pages/VaultLandingPage.d.ts +0 -10
- package/dist/security/pages/VaultLandingPage.d.ts.map +0 -1
- package/dist/security/pages/VaultSettingsPage.d.ts +0 -2
- package/dist/security/pages/VaultSettingsPage.d.ts.map +0 -1
- package/dist/security/pages/VaultsDashboardPage.d.ts +0 -2
- package/dist/security/pages/VaultsDashboardPage.d.ts.map +0 -1
- package/dist/security/providers/SecurityProvider.d.ts +0 -13
- package/dist/security/providers/SecurityProvider.d.ts.map +0 -1
- package/dist/security/routes/SecurityAdminRoutes.d.ts +0 -7
- package/dist/security/routes/SecurityAdminRoutes.d.ts.map +0 -1
- package/dist/security/routes/SecurityRoutes.d.ts +0 -19
- package/dist/security/routes/SecurityRoutes.d.ts.map +0 -1
- package/dist/security/routes/SecurityUserRoutes.d.ts +0 -11
- package/dist/security/routes/SecurityUserRoutes.d.ts.map +0 -1
- package/dist/security/routes/routeUtils.d.ts +0 -28
- package/dist/security/routes/routeUtils.d.ts.map +0 -1
- package/dist/security/store/securityStore.d.ts +0 -35
- package/dist/security/store/securityStore.d.ts.map +0 -1
- package/dist/security/types/index.d.ts +0 -283
- package/dist/security/types/index.d.ts.map +0 -1
- package/dist/security/utils/clipboard.d.ts +0 -20
- package/dist/security/utils/clipboard.d.ts.map +0 -1
- package/dist/security/utils/cn.d.ts +0 -7
- package/dist/security/utils/cn.d.ts.map +0 -1
- package/dist/security/utils/fileParser.d.ts +0 -18
- package/dist/security/utils/fileParser.d.ts.map +0 -1
- package/dist/security/utils/i18n.d.ts +0 -5
- package/dist/security/utils/i18n.d.ts.map +0 -1
- package/dist/security/utils/importParsers.d.ts +0 -30
- package/dist/security/utils/importParsers.d.ts.map +0 -1
- package/dist/security/utils/mappers.d.ts +0 -35
- package/dist/security/utils/mappers.d.ts.map +0 -1
- package/dist/security/utils/passwordGenerator.d.ts +0 -22
- package/dist/security/utils/passwordGenerator.d.ts.map +0 -1
- package/dist/utils/nativeBridge.d.ts +0 -3
- package/dist/utils/nativeBridge.d.ts.map +0 -1
|
@@ -3,270 +3,272 @@ import { SECURITY_FEATURE_FLAGS as t } from "../constants/featureFlags.js";
|
|
|
3
3
|
import { cn as n } from "../utils/cn.js";
|
|
4
4
|
import { PageLayout as r } from "../components/PageLayout.js";
|
|
5
5
|
import { Badge as i, Button as a, Card as o } from "../components/ui.js";
|
|
6
|
-
import { translateWithFallback as
|
|
7
|
-
import { ConfirmDialog as
|
|
8
|
-
import { useGetSecretVersionsQuery as
|
|
9
|
-
import { useSecurityEventEmitter as
|
|
10
|
-
import { useDeleteSecret as
|
|
11
|
-
import { nativeConfirm as
|
|
12
|
-
import { SecurityPermissionGuard as
|
|
13
|
-
import { SecretValueDisplay as
|
|
14
|
-
import { SecretTypeBadge as
|
|
15
|
-
import { RotationStatusBadge as
|
|
16
|
-
import { useSecretValue as
|
|
17
|
-
import { useState as
|
|
18
|
-
import { usePermission as
|
|
19
|
-
import { useNavigate as
|
|
20
|
-
import { jsx as
|
|
21
|
-
import { AlertTriangle as
|
|
22
|
-
import { useI18n as
|
|
6
|
+
import { translateWithFallback as ee } from "../utils/i18n.js";
|
|
7
|
+
import { ConfirmDialog as te } from "../components/ConfirmDialog.js";
|
|
8
|
+
import { useGetSecretVersionsQuery as ne } from "../../generated/wspace-operations.js";
|
|
9
|
+
import { useSecurityEventEmitter as s } from "../hooks/useSecurityEventEmitter.js";
|
|
10
|
+
import { useDeleteSecret as re, useGetSecret as ie, useRollbackSecret as c, useRotateSecret as l } from "../hooks/useSecretQueries.js";
|
|
11
|
+
import { nativeConfirm as u, nativeImpact as d, nativeNotify as f } from "../../utils/nativeBridge.js";
|
|
12
|
+
import { SecurityPermissionGuard as p } from "../components/SecurityPermissionGuard.js";
|
|
13
|
+
import { SecretValueDisplay as ae } from "../components/SecretValueDisplay.js";
|
|
14
|
+
import { SecretTypeBadge as oe } from "../components/SecretTypeBadge.js";
|
|
15
|
+
import { RotationStatusBadge as se } from "../components/RotationStatusBadge.js";
|
|
16
|
+
import { useSecretValue as ce } from "../hooks/useSecretValue.js";
|
|
17
|
+
import { useRef as le, useState as m } from "react";
|
|
18
|
+
import { usePermission as h } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
19
|
+
import { useNavigate as ue, useParams as de } from "react-router-dom";
|
|
20
|
+
import { jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
21
|
+
import { AlertTriangle as fe, ArrowLeft as v, Calendar as y, Clock as b, History as x, KeyRound as pe, Loader2 as S, RefreshCw as C, Shield as me, Trash2 as he, X as w } from "lucide-react";
|
|
22
|
+
import { useI18n as T } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
23
23
|
//#region src/security/pages/SecretDetailPage.tsx
|
|
24
|
-
function
|
|
25
|
-
let { vaultId:
|
|
24
|
+
function E() {
|
|
25
|
+
let { vaultId: E, secretId: D } = de(), { basePath: O = "/", navigate: k } = e(), { t: A } = T(), j = ue(), { data: M, loading: N, error: P, refetch: F } = ie(D ?? null), I = M?.getSecret, { data: L, loading: R } = ne({
|
|
26
26
|
variables: {
|
|
27
|
-
secretId:
|
|
27
|
+
secretId: D ?? "",
|
|
28
28
|
pagination: { limit: 50 }
|
|
29
29
|
},
|
|
30
|
-
skip: !
|
|
30
|
+
skip: !D,
|
|
31
31
|
fetchPolicy: "network-only"
|
|
32
|
-
}),
|
|
33
|
-
|
|
34
|
-
let
|
|
35
|
-
|
|
32
|
+
}), z = L?.getSecretVersionsPaginated?.items ?? [], { value: ge, reveal: _e, hide: ve, loading: ye, isRevealed: B } = ce(D ?? ""), [be, { loading: xe }] = re(), [Se, { loading: V }] = l(), [Ce, { loading: we }] = c(), { emit: H } = s(), Te = h("secret:delete");
|
|
33
|
+
h("secret:update");
|
|
34
|
+
let Ee = h("secret:decrypt"), [De, U] = m(!1), [Oe, W] = m(!1), G = le(null), ke = () => {
|
|
35
|
+
W(!0), requestAnimationFrame(() => G.current?.focus());
|
|
36
|
+
}, [Ae, K] = m(!1), [q, J] = m(""), Y = (e, t, n) => ee(A, e, t, n), je = (e) => {
|
|
37
|
+
k ? k(e) : j(e);
|
|
36
38
|
}, X = () => {
|
|
37
|
-
|
|
39
|
+
je(`${O}/vaults/${E}`);
|
|
38
40
|
}, Z = async () => {
|
|
39
|
-
if (
|
|
40
|
-
await
|
|
41
|
-
secretId:
|
|
42
|
-
vaultId:
|
|
43
|
-
}),
|
|
41
|
+
if (D) try {
|
|
42
|
+
await be({ variables: { id: D } }), H("secret.deleted", {
|
|
43
|
+
secretId: D,
|
|
44
|
+
vaultId: E
|
|
45
|
+
}), U(!1), f("success"), X();
|
|
44
46
|
} catch (e) {
|
|
45
|
-
console.error("Failed to delete secret:", e),
|
|
47
|
+
console.error("Failed to delete secret:", e), f("error");
|
|
46
48
|
}
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
let e = await
|
|
49
|
+
}, Me = async () => {
|
|
50
|
+
d("medium");
|
|
51
|
+
let e = await u({
|
|
50
52
|
title: "Delete Secret",
|
|
51
53
|
message: "Delete this secret? This cannot be undone.",
|
|
52
54
|
okButtonTitle: "Delete",
|
|
53
55
|
cancelButtonTitle: "Cancel"
|
|
54
56
|
});
|
|
55
57
|
if (e === null) {
|
|
56
|
-
|
|
58
|
+
U(!0);
|
|
57
59
|
return;
|
|
58
60
|
}
|
|
59
61
|
e && await Z();
|
|
60
|
-
},
|
|
61
|
-
if (!(!
|
|
62
|
-
await
|
|
63
|
-
id:
|
|
62
|
+
}, Ne = async () => {
|
|
63
|
+
if (!(!D || !q.trim())) try {
|
|
64
|
+
await Se({ variables: {
|
|
65
|
+
id: D,
|
|
64
66
|
newValue: q.trim()
|
|
65
|
-
} }),
|
|
66
|
-
secretId:
|
|
67
|
-
vaultId:
|
|
68
|
-
}),
|
|
67
|
+
} }), H("secret.rotated", {
|
|
68
|
+
secretId: D,
|
|
69
|
+
vaultId: E
|
|
70
|
+
}), W(!1), J(""), F();
|
|
69
71
|
} catch (e) {
|
|
70
72
|
console.error("Failed to rotate secret:", e);
|
|
71
73
|
}
|
|
72
|
-
},
|
|
73
|
-
if (
|
|
74
|
-
await
|
|
75
|
-
id:
|
|
74
|
+
}, Pe = async (e) => {
|
|
75
|
+
if (D) try {
|
|
76
|
+
await Ce({ variables: {
|
|
77
|
+
id: D,
|
|
76
78
|
version: e
|
|
77
|
-
} }),
|
|
78
|
-
secretId:
|
|
79
|
-
vaultId:
|
|
80
|
-
}),
|
|
79
|
+
} }), H("secret.rollback", {
|
|
80
|
+
secretId: D,
|
|
81
|
+
vaultId: E
|
|
82
|
+
}), F(), K(!1);
|
|
81
83
|
} catch (e) {
|
|
82
84
|
console.error("Failed to rollback secret:", e);
|
|
83
85
|
}
|
|
84
86
|
};
|
|
85
|
-
if (
|
|
87
|
+
if (N && !I) return /* @__PURE__ */ g(r, {
|
|
86
88
|
title: Y("security.secretDetail.loading.title", "Loading Secret..."),
|
|
87
89
|
breadcrumbs: [{
|
|
88
90
|
label: Y("security.common.breadcrumbs.security", "Security"),
|
|
89
|
-
path:
|
|
91
|
+
path: O
|
|
90
92
|
}, { label: Y("security.common.breadcrumbs.secret", "Secret") }],
|
|
91
|
-
children: /* @__PURE__ */
|
|
93
|
+
children: /* @__PURE__ */ g("div", {
|
|
92
94
|
className: "flex items-center justify-center py-20",
|
|
93
|
-
children: /* @__PURE__ */
|
|
95
|
+
children: /* @__PURE__ */ g(S, { className: "size-10 animate-spin text-primary/60" })
|
|
94
96
|
})
|
|
95
97
|
});
|
|
96
|
-
if (
|
|
98
|
+
if (P || !I) return /* @__PURE__ */ g(r, {
|
|
97
99
|
title: Y("security.common.errorPage.title", "Error"),
|
|
98
100
|
breadcrumbs: [{
|
|
99
101
|
label: Y("security.common.breadcrumbs.security", "Security"),
|
|
100
|
-
path:
|
|
102
|
+
path: O
|
|
101
103
|
}, { label: Y("security.common.breadcrumbs.secret", "Secret") }],
|
|
102
|
-
children: /* @__PURE__ */
|
|
104
|
+
children: /* @__PURE__ */ g(o, {
|
|
103
105
|
className: "p-8 text-center max-w-lg mx-auto mt-10",
|
|
104
|
-
children: /* @__PURE__ */
|
|
106
|
+
children: /* @__PURE__ */ _("div", {
|
|
105
107
|
className: "flex flex-col items-center gap-4",
|
|
106
108
|
children: [
|
|
107
|
-
/* @__PURE__ */
|
|
109
|
+
/* @__PURE__ */ g("div", {
|
|
108
110
|
className: "p-3 rounded-full bg-destructive/10",
|
|
109
|
-
children: /* @__PURE__ */
|
|
111
|
+
children: /* @__PURE__ */ g(fe, { className: "size-8 text-destructive" })
|
|
110
112
|
}),
|
|
111
|
-
/* @__PURE__ */
|
|
113
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("h3", {
|
|
112
114
|
className: "text-lg font-bold text-foreground",
|
|
113
115
|
children: Y("security.secretDetail.error.title", "Failed to load secret")
|
|
114
|
-
}), /* @__PURE__ */
|
|
116
|
+
}), /* @__PURE__ */ g("p", {
|
|
115
117
|
className: "text-sm text-muted-foreground mt-2",
|
|
116
|
-
children:
|
|
118
|
+
children: P?.message ?? Y("security.secretDetail.error.description", "Secret not found or access denied.")
|
|
117
119
|
})] }),
|
|
118
|
-
/* @__PURE__ */
|
|
120
|
+
/* @__PURE__ */ _(a, {
|
|
119
121
|
variant: "outline",
|
|
120
122
|
onClick: X,
|
|
121
123
|
className: "mt-4",
|
|
122
|
-
children: [/* @__PURE__ */
|
|
124
|
+
children: [/* @__PURE__ */ g(v, { className: "size-4" }), Y("security.secretDetail.actions.backToVault", "Go Back to Vault")]
|
|
123
125
|
})
|
|
124
126
|
]
|
|
125
127
|
})
|
|
126
128
|
})
|
|
127
129
|
});
|
|
128
|
-
let Q =
|
|
129
|
-
return /* @__PURE__ */
|
|
130
|
-
title:
|
|
131
|
-
description:
|
|
130
|
+
let Q = I.versionCount ?? 0, $ = I.lastRotatedAt ? "healthy" : void 0;
|
|
131
|
+
return /* @__PURE__ */ _(r, {
|
|
132
|
+
title: I.name,
|
|
133
|
+
description: I.description ?? Y("security.secretDetail.description", "View and manage this secret."),
|
|
132
134
|
breadcrumbs: [
|
|
133
135
|
{
|
|
134
136
|
label: Y("security.common.breadcrumbs.security", "Security"),
|
|
135
|
-
path:
|
|
137
|
+
path: O
|
|
136
138
|
},
|
|
137
139
|
{
|
|
138
140
|
label: Y("security.common.breadcrumbs.vault", "Vault"),
|
|
139
|
-
path: `${
|
|
141
|
+
path: `${O}/vaults/${E}`
|
|
140
142
|
},
|
|
141
|
-
{ label:
|
|
143
|
+
{ label: I.name }
|
|
142
144
|
],
|
|
143
|
-
actions: /* @__PURE__ */
|
|
145
|
+
actions: /* @__PURE__ */ _("div", {
|
|
144
146
|
className: "flex flex-wrap items-center gap-2",
|
|
145
147
|
children: [
|
|
146
|
-
/* @__PURE__ */
|
|
148
|
+
/* @__PURE__ */ _(a, {
|
|
147
149
|
variant: "outline",
|
|
148
150
|
size: "sm",
|
|
149
151
|
onClick: X,
|
|
150
152
|
children: [
|
|
151
|
-
/* @__PURE__ */
|
|
152
|
-
/* @__PURE__ */
|
|
153
|
+
/* @__PURE__ */ g(v, { className: "size-4" }),
|
|
154
|
+
/* @__PURE__ */ g("span", {
|
|
153
155
|
className: "hidden sm:inline",
|
|
154
156
|
children: Y("security.secretDetail.actions.backToVault", "Back to Vault")
|
|
155
157
|
}),
|
|
156
|
-
/* @__PURE__ */
|
|
158
|
+
/* @__PURE__ */ g("span", {
|
|
157
159
|
className: "sm:hidden",
|
|
158
160
|
children: Y("security.common.actions.back", "Back")
|
|
159
161
|
})
|
|
160
162
|
]
|
|
161
163
|
}),
|
|
162
|
-
/* @__PURE__ */
|
|
164
|
+
/* @__PURE__ */ g(p, {
|
|
163
165
|
permission: "secret:update",
|
|
164
166
|
featureFlagKey: t.SECRET_ROTATE,
|
|
165
167
|
featureFlagDefault: !1,
|
|
166
|
-
children: /* @__PURE__ */
|
|
168
|
+
children: /* @__PURE__ */ _(a, {
|
|
167
169
|
variant: "outline",
|
|
168
170
|
size: "sm",
|
|
169
|
-
onClick:
|
|
170
|
-
children: [/* @__PURE__ */
|
|
171
|
+
onClick: ke,
|
|
172
|
+
children: [/* @__PURE__ */ g(C, { className: "size-4" }), Y("security.secretDetail.actions.rotate", "Rotate")]
|
|
171
173
|
})
|
|
172
174
|
}),
|
|
173
|
-
|
|
175
|
+
Te && /* @__PURE__ */ _(a, {
|
|
174
176
|
variant: "outline",
|
|
175
177
|
size: "sm",
|
|
176
178
|
className: "text-destructive hover:bg-destructive/10 border-destructive/20",
|
|
177
|
-
onClick: () => void
|
|
178
|
-
children: [/* @__PURE__ */
|
|
179
|
+
onClick: () => void Me(),
|
|
180
|
+
children: [/* @__PURE__ */ g(he, { className: "size-4" }), Y("security.common.actions.delete", "Delete")]
|
|
179
181
|
})
|
|
180
182
|
]
|
|
181
183
|
}),
|
|
182
184
|
children: [
|
|
183
|
-
/* @__PURE__ */
|
|
185
|
+
/* @__PURE__ */ _("div", {
|
|
184
186
|
className: "space-y-6",
|
|
185
|
-
children: [/* @__PURE__ */
|
|
187
|
+
children: [/* @__PURE__ */ _("div", {
|
|
186
188
|
className: "flex flex-wrap items-center gap-3",
|
|
187
189
|
children: [
|
|
188
|
-
/* @__PURE__ */
|
|
189
|
-
$ && /* @__PURE__ */
|
|
190
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ g(oe, { type: I.type }),
|
|
191
|
+
$ && /* @__PURE__ */ g(se, { status: $ }),
|
|
192
|
+
/* @__PURE__ */ g(i, {
|
|
191
193
|
variant: "outline",
|
|
192
194
|
className: "bg-background/50",
|
|
193
|
-
children: Y("security.secretDetail.status.label", "Status: {status}", { status:
|
|
195
|
+
children: Y("security.secretDetail.status.label", "Status: {status}", { status: I.status })
|
|
194
196
|
}),
|
|
195
|
-
|
|
197
|
+
I.labels?.map((e) => /* @__PURE__ */ g(i, {
|
|
196
198
|
variant: "outline",
|
|
197
199
|
className: "border-primary/20 text-primary",
|
|
198
200
|
children: e.label
|
|
199
201
|
}, e.id))
|
|
200
202
|
]
|
|
201
|
-
}), /* @__PURE__ */
|
|
203
|
+
}), /* @__PURE__ */ _("div", {
|
|
202
204
|
className: "grid grid-cols-1 md:grid-cols-3 gap-6",
|
|
203
|
-
children: [/* @__PURE__ */
|
|
205
|
+
children: [/* @__PURE__ */ _("div", {
|
|
204
206
|
className: "md:col-span-2 space-y-6",
|
|
205
|
-
children: [/* @__PURE__ */
|
|
207
|
+
children: [/* @__PURE__ */ _(o, {
|
|
206
208
|
className: "p-6 shadow-sm border-border/60",
|
|
207
209
|
children: [
|
|
208
|
-
/* @__PURE__ */
|
|
210
|
+
/* @__PURE__ */ _("div", {
|
|
209
211
|
className: "flex items-center justify-between mb-4",
|
|
210
|
-
children: [/* @__PURE__ */
|
|
212
|
+
children: [/* @__PURE__ */ _("h2", {
|
|
211
213
|
className: "text-lg font-bold text-foreground flex items-center gap-2",
|
|
212
|
-
children: [/* @__PURE__ */
|
|
213
|
-
}),
|
|
214
|
+
children: [/* @__PURE__ */ g(pe, { className: "size-5 text-primary" }), Y("security.secretDetail.value.title", "Secret Value")]
|
|
215
|
+
}), I.expiresAt && /* @__PURE__ */ _("div", {
|
|
214
216
|
className: "flex items-center gap-1.5 text-xs text-warning",
|
|
215
|
-
children: [/* @__PURE__ */ y
|
|
217
|
+
children: [/* @__PURE__ */ g(y, { className: "size-3.5" }), Y("security.secretDetail.value.expires", "Expires: {date}", { date: new Date(I.expiresAt).toLocaleDateString() })]
|
|
216
218
|
})]
|
|
217
219
|
}),
|
|
218
|
-
/* @__PURE__ */
|
|
219
|
-
value:
|
|
220
|
-
isRevealed:
|
|
221
|
-
onToggleReveal:
|
|
222
|
-
|
|
220
|
+
/* @__PURE__ */ g(ae, {
|
|
221
|
+
value: ge ?? "",
|
|
222
|
+
isRevealed: B,
|
|
223
|
+
onToggleReveal: Ee ? () => {
|
|
224
|
+
B ? ve() : _e();
|
|
223
225
|
} : void 0,
|
|
224
|
-
isLoading:
|
|
226
|
+
isLoading: ye
|
|
225
227
|
}),
|
|
226
|
-
/* @__PURE__ */
|
|
228
|
+
/* @__PURE__ */ g("p", {
|
|
227
229
|
className: "text-xs text-muted-foreground mt-4 italic",
|
|
228
230
|
children: Y("security.secretDetail.value.note", "Secret values are decrypted on-demand and never stored in plain text.")
|
|
229
231
|
})
|
|
230
232
|
]
|
|
231
|
-
}), /* @__PURE__ */
|
|
233
|
+
}), /* @__PURE__ */ _(o, {
|
|
232
234
|
className: "p-6 shadow-sm border-border/60",
|
|
233
|
-
children: [/* @__PURE__ */
|
|
235
|
+
children: [/* @__PURE__ */ _("div", {
|
|
234
236
|
className: "flex items-center justify-between mb-6",
|
|
235
|
-
children: [/* @__PURE__ */
|
|
237
|
+
children: [/* @__PURE__ */ _("h2", {
|
|
236
238
|
className: "text-lg font-bold text-foreground flex items-center gap-2",
|
|
237
|
-
children: [/* @__PURE__ */
|
|
238
|
-
}), /* @__PURE__ */
|
|
239
|
+
children: [/* @__PURE__ */ g(x, { className: "size-5 text-primary" }), Y("security.secretDetail.history.title", "Version History")]
|
|
240
|
+
}), /* @__PURE__ */ g(i, {
|
|
239
241
|
variant: "outline",
|
|
240
242
|
className: "bg-muted font-mono",
|
|
241
243
|
children: Y("security.secretDetail.history.totalVersions", "{count} total versions", { count: Q })
|
|
242
244
|
})]
|
|
243
|
-
}), /* @__PURE__ */
|
|
245
|
+
}), /* @__PURE__ */ _("div", {
|
|
244
246
|
className: "space-y-4",
|
|
245
|
-
children: [/* @__PURE__ */
|
|
247
|
+
children: [/* @__PURE__ */ _("div", {
|
|
246
248
|
className: "flex items-center justify-between p-4 rounded-lg bg-primary/5 border border-primary/10",
|
|
247
|
-
children: [/* @__PURE__ */
|
|
249
|
+
children: [/* @__PURE__ */ _("div", {
|
|
248
250
|
className: "flex items-center gap-3",
|
|
249
|
-
children: [/* @__PURE__ */
|
|
250
|
-
className: "
|
|
251
|
-
children: ["v",
|
|
252
|
-
}), /* @__PURE__ */
|
|
251
|
+
children: [/* @__PURE__ */ _("div", {
|
|
252
|
+
className: "size-8 rounded-full bg-primary/10 flex items-center justify-center text-primary text-xs font-bold",
|
|
253
|
+
children: ["v", I.version ?? Q]
|
|
254
|
+
}), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
253
255
|
className: "text-sm font-semibold",
|
|
254
256
|
children: Y("security.secretDetail.history.currentVersion", "Current Active Version")
|
|
255
|
-
}), /* @__PURE__ */
|
|
257
|
+
}), /* @__PURE__ */ g("p", {
|
|
256
258
|
className: "text-xs text-muted-foreground",
|
|
257
|
-
children: Y("security.secretDetail.history.lastUpdated", "Last updated {date}", { date: new Date(
|
|
259
|
+
children: Y("security.secretDetail.history.lastUpdated", "Last updated {date}", { date: new Date(I.updatedAt).toLocaleString() })
|
|
258
260
|
})] })]
|
|
259
|
-
}), /* @__PURE__ */
|
|
261
|
+
}), /* @__PURE__ */ g(i, {
|
|
260
262
|
variant: "success",
|
|
261
263
|
className: "text-[10px] uppercase",
|
|
262
264
|
children: Y("security.common.status.active", "Active")
|
|
263
265
|
})]
|
|
264
|
-
}), Q > 1 && /* @__PURE__ */
|
|
266
|
+
}), Q > 1 && /* @__PURE__ */ _("div", {
|
|
265
267
|
className: "text-center py-4 border-2 border-dashed border-border/40 rounded-lg bg-muted/20",
|
|
266
|
-
children: [/* @__PURE__ */
|
|
268
|
+
children: [/* @__PURE__ */ g("p", {
|
|
267
269
|
className: "text-sm text-muted-foreground",
|
|
268
270
|
children: Y("security.secretDetail.history.available", "Historical versions are available. You can rollback to a previous state if needed.")
|
|
269
|
-
}), /* @__PURE__ */
|
|
271
|
+
}), /* @__PURE__ */ g(a, {
|
|
270
272
|
variant: "outline",
|
|
271
273
|
size: "sm",
|
|
272
274
|
className: "mt-3",
|
|
@@ -276,52 +278,52 @@ function D() {
|
|
|
276
278
|
})]
|
|
277
279
|
})]
|
|
278
280
|
})]
|
|
279
|
-
}), /* @__PURE__ */
|
|
281
|
+
}), /* @__PURE__ */ _("div", {
|
|
280
282
|
className: "space-y-6",
|
|
281
|
-
children: [/* @__PURE__ */
|
|
283
|
+
children: [/* @__PURE__ */ _(o, {
|
|
282
284
|
className: "p-6 shadow-sm border-border/60 space-y-4",
|
|
283
|
-
children: [/* @__PURE__ */
|
|
285
|
+
children: [/* @__PURE__ */ g("h3", {
|
|
284
286
|
className: "font-bold text-sm uppercase tracking-wider text-muted-foreground",
|
|
285
287
|
children: Y("security.secretDetail.details.title", "Details")
|
|
286
|
-
}), /* @__PURE__ */
|
|
288
|
+
}), /* @__PURE__ */ _("div", {
|
|
287
289
|
className: "space-y-3",
|
|
288
290
|
children: [
|
|
289
|
-
/* @__PURE__ */
|
|
291
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
290
292
|
className: "text-xs text-muted-foreground",
|
|
291
293
|
children: Y("security.secretDetail.details.keyIdentifier", "Key Identifier")
|
|
292
|
-
}), /* @__PURE__ */
|
|
294
|
+
}), /* @__PURE__ */ g("code", {
|
|
293
295
|
className: "text-xs font-mono bg-muted px-1.5 py-0.5 rounded block mt-1 overflow-hidden text-ellipsis whitespace-nowrap",
|
|
294
|
-
children:
|
|
296
|
+
children: I.key
|
|
295
297
|
})] }),
|
|
296
|
-
/* @__PURE__ */
|
|
298
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
297
299
|
className: "text-xs text-muted-foreground",
|
|
298
300
|
children: Y("security.secretDetail.details.createdBy", "Created By")
|
|
299
|
-
}), /* @__PURE__ */
|
|
301
|
+
}), /* @__PURE__ */ g("p", {
|
|
300
302
|
className: "text-sm font-medium mt-1",
|
|
301
|
-
children:
|
|
303
|
+
children: I.createdBy
|
|
302
304
|
})] }),
|
|
303
|
-
/* @__PURE__ */
|
|
305
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
304
306
|
className: "text-xs text-muted-foreground",
|
|
305
307
|
children: Y("security.secretDetail.details.createdAt", "Created At")
|
|
306
|
-
}), /* @__PURE__ */
|
|
308
|
+
}), /* @__PURE__ */ _("div", {
|
|
307
309
|
className: "flex items-center gap-1.5 text-sm mt-1",
|
|
308
|
-
children: [/* @__PURE__ */
|
|
310
|
+
children: [/* @__PURE__ */ g(b, { className: "size-3.5" }), new Date(I.createdAt).toLocaleDateString()]
|
|
309
311
|
})] }),
|
|
310
|
-
|
|
312
|
+
I.lastRotatedAt && /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
311
313
|
className: "text-xs text-muted-foreground",
|
|
312
314
|
children: Y("security.secretDetail.details.lastRotation", "Last Rotation")
|
|
313
|
-
}), /* @__PURE__ */
|
|
315
|
+
}), /* @__PURE__ */ g("p", {
|
|
314
316
|
className: "text-sm mt-1",
|
|
315
|
-
children: new Date(
|
|
317
|
+
children: new Date(I.lastRotatedAt).toLocaleString()
|
|
316
318
|
})] })
|
|
317
319
|
]
|
|
318
320
|
})]
|
|
319
|
-
}), /* @__PURE__ */
|
|
321
|
+
}), /* @__PURE__ */ _(o, {
|
|
320
322
|
className: "p-6 shadow-sm border-border/60 space-y-4 bg-primary/5 border-primary/10",
|
|
321
|
-
children: [/* @__PURE__ */
|
|
323
|
+
children: [/* @__PURE__ */ _("h3", {
|
|
322
324
|
className: "font-bold text-sm text-primary flex items-center gap-2",
|
|
323
|
-
children: [/* @__PURE__ */
|
|
324
|
-
}), /* @__PURE__ */
|
|
325
|
+
children: [/* @__PURE__ */ g(me, { className: "size-4" }), Y("security.secretDetail.security.title", "Security")]
|
|
326
|
+
}), /* @__PURE__ */ g("p", {
|
|
325
327
|
className: "text-xs text-muted-foreground leading-relaxed",
|
|
326
328
|
children: Y("security.secretDetail.security.description", "This secret is protected by 256-bit encryption. All access is logged and monitored for suspicious activity.")
|
|
327
329
|
})]
|
|
@@ -329,72 +331,75 @@ function D() {
|
|
|
329
331
|
})]
|
|
330
332
|
})]
|
|
331
333
|
}),
|
|
332
|
-
|
|
334
|
+
Ae && /* @__PURE__ */ _("div", {
|
|
333
335
|
className: "fixed inset-0 z-50 flex items-center justify-center p-4",
|
|
334
|
-
children: [/* @__PURE__ */
|
|
335
|
-
|
|
336
|
+
children: [/* @__PURE__ */ g("button", {
|
|
337
|
+
type: "button",
|
|
338
|
+
"aria-label": "Close version history",
|
|
339
|
+
className: "absolute inset-0 bg-background/80 backdrop-blur-sm animate-in fade-in duration-200 cursor-default",
|
|
336
340
|
onClick: () => K(!1)
|
|
337
|
-
}), /* @__PURE__ */
|
|
341
|
+
}), /* @__PURE__ */ _(o, {
|
|
338
342
|
className: "relative z-10 w-full max-w-2xl shadow-2xl animate-in zoom-in-95 duration-200 border-primary/20 max-h-[80vh] flex flex-col",
|
|
339
|
-
children: [/* @__PURE__ */
|
|
343
|
+
children: [/* @__PURE__ */ _("div", {
|
|
340
344
|
className: "flex items-center justify-between p-6 border-b border-border",
|
|
341
|
-
children: [/* @__PURE__ */
|
|
345
|
+
children: [/* @__PURE__ */ _("div", {
|
|
342
346
|
className: "flex items-center gap-3",
|
|
343
|
-
children: [/* @__PURE__ */
|
|
347
|
+
children: [/* @__PURE__ */ g("div", {
|
|
344
348
|
className: "p-2 rounded-full bg-primary/10 text-primary",
|
|
345
|
-
children: /* @__PURE__ */
|
|
346
|
-
}), /* @__PURE__ */
|
|
349
|
+
children: /* @__PURE__ */ g(x, { className: "size-5" })
|
|
350
|
+
}), /* @__PURE__ */ g("h2", {
|
|
347
351
|
className: "text-xl font-bold text-foreground",
|
|
348
352
|
children: Y("security.secretDetail.history.modalTitle", "Version History")
|
|
349
353
|
})]
|
|
350
|
-
}), /* @__PURE__ */
|
|
354
|
+
}), /* @__PURE__ */ g("button", {
|
|
355
|
+
type: "button",
|
|
351
356
|
onClick: () => K(!1),
|
|
352
357
|
className: "p-2 rounded-md hover:bg-muted text-muted-foreground transition-colors",
|
|
353
|
-
children: /* @__PURE__ */
|
|
358
|
+
children: /* @__PURE__ */ g(w, { className: "size-5" })
|
|
354
359
|
})]
|
|
355
|
-
}), /* @__PURE__ */
|
|
360
|
+
}), /* @__PURE__ */ g("div", {
|
|
356
361
|
className: "p-6 overflow-y-auto flex-1",
|
|
357
|
-
children:
|
|
362
|
+
children: R ? /* @__PURE__ */ g("div", {
|
|
358
363
|
className: "flex justify-center py-8",
|
|
359
|
-
children: /* @__PURE__ */
|
|
360
|
-
}) : /* @__PURE__ */
|
|
364
|
+
children: /* @__PURE__ */ g(S, { className: "size-8 animate-spin text-primary/60" })
|
|
365
|
+
}) : /* @__PURE__ */ g("div", {
|
|
361
366
|
className: "space-y-4",
|
|
362
|
-
children:
|
|
363
|
-
className: n("p-4 rounded-lg border", e.version ===
|
|
364
|
-
children: /* @__PURE__ */
|
|
367
|
+
children: z.map((e) => /* @__PURE__ */ g("div", {
|
|
368
|
+
className: n("p-4 rounded-lg border", e.version === I.version ? "bg-primary/5 border-primary/20" : "bg-card border-border"),
|
|
369
|
+
children: /* @__PURE__ */ _("div", {
|
|
365
370
|
className: "flex items-center justify-between",
|
|
366
|
-
children: [/* @__PURE__ */
|
|
367
|
-
/* @__PURE__ */
|
|
371
|
+
children: [/* @__PURE__ */ _("div", { children: [
|
|
372
|
+
/* @__PURE__ */ _("div", {
|
|
368
373
|
className: "flex items-center gap-2",
|
|
369
|
-
children: [/* @__PURE__ */
|
|
374
|
+
children: [/* @__PURE__ */ g("span", {
|
|
370
375
|
className: "font-semibold",
|
|
371
376
|
children: Y("security.secretDetail.history.versionLabel", "Version {version}", { version: e.version })
|
|
372
|
-
}), e.version ===
|
|
377
|
+
}), e.version === I.version && /* @__PURE__ */ g(i, {
|
|
373
378
|
variant: "success",
|
|
374
379
|
className: "text-[10px] uppercase",
|
|
375
380
|
children: Y("security.common.status.active", "Active")
|
|
376
381
|
})]
|
|
377
382
|
}),
|
|
378
|
-
/* @__PURE__ */
|
|
383
|
+
/* @__PURE__ */ g("p", {
|
|
379
384
|
className: "text-xs text-muted-foreground mt-1",
|
|
380
385
|
children: Y("security.secretDetail.history.versionMeta", "{date} by {createdBy}", {
|
|
381
386
|
date: new Date(e.createdAt).toLocaleString(),
|
|
382
387
|
createdBy: e.createdBy
|
|
383
388
|
})
|
|
384
389
|
}),
|
|
385
|
-
e.changeReason && /* @__PURE__ */
|
|
390
|
+
e.changeReason && /* @__PURE__ */ g("p", {
|
|
386
391
|
className: "text-sm mt-2",
|
|
387
392
|
children: e.changeReason
|
|
388
393
|
})
|
|
389
|
-
] }), e.version !==
|
|
394
|
+
] }), e.version !== I.version && /* @__PURE__ */ g(p, {
|
|
390
395
|
permission: "secret:update",
|
|
391
396
|
featureFlagKey: t.SECRET_ROLLBACK,
|
|
392
397
|
featureFlagDefault: !1,
|
|
393
|
-
children: /* @__PURE__ */
|
|
398
|
+
children: /* @__PURE__ */ g(a, {
|
|
394
399
|
variant: "outline",
|
|
395
400
|
size: "sm",
|
|
396
|
-
onClick: () =>
|
|
397
|
-
disabled:
|
|
401
|
+
onClick: () => Pe(e.version),
|
|
402
|
+
disabled: we,
|
|
398
403
|
children: Y("security.secretDetail.actions.rollback", "Rollback")
|
|
399
404
|
})
|
|
400
405
|
})]
|
|
@@ -404,66 +409,69 @@ function D() {
|
|
|
404
409
|
})]
|
|
405
410
|
})]
|
|
406
411
|
}),
|
|
407
|
-
/* @__PURE__ */
|
|
408
|
-
isOpen:
|
|
409
|
-
onClose: () =>
|
|
412
|
+
/* @__PURE__ */ g(te, {
|
|
413
|
+
isOpen: De,
|
|
414
|
+
onClose: () => U(!1),
|
|
410
415
|
onConfirm: Z,
|
|
411
416
|
title: Y("security.secretDetail.delete.title", "Delete Secret"),
|
|
412
|
-
description: Y("security.secretDetail.delete.description", "Are you sure you want to delete \"{name}\"? This action cannot be undone and will permanently remove this secret from the vault.", { name:
|
|
413
|
-
confirmLabel:
|
|
417
|
+
description: Y("security.secretDetail.delete.description", "Are you sure you want to delete \"{name}\"? This action cannot be undone and will permanently remove this secret from the vault.", { name: I.name }),
|
|
418
|
+
confirmLabel: xe ? Y("security.secretDetail.delete.deleting", "Deleting...") : Y("security.secretDetail.delete.confirm", "Delete Secret"),
|
|
414
419
|
variant: "destructive"
|
|
415
420
|
}),
|
|
416
|
-
|
|
421
|
+
Oe && /* @__PURE__ */ _("div", {
|
|
417
422
|
className: "fixed inset-0 z-50 flex items-center justify-center p-4",
|
|
418
|
-
children: [/* @__PURE__ */
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
423
|
+
children: [/* @__PURE__ */ g("button", {
|
|
424
|
+
type: "button",
|
|
425
|
+
"aria-label": "Close rotate dialog",
|
|
426
|
+
className: "absolute inset-0 bg-background/80 backdrop-blur-sm animate-in fade-in duration-200 cursor-default",
|
|
427
|
+
onClick: () => W(!1)
|
|
428
|
+
}), /* @__PURE__ */ g(o, {
|
|
422
429
|
className: "relative z-10 w-full max-w-md shadow-2xl animate-in zoom-in-95 duration-200 border-primary/20",
|
|
423
|
-
children: /* @__PURE__ */
|
|
430
|
+
children: /* @__PURE__ */ _("div", {
|
|
424
431
|
className: "p-6 space-y-4",
|
|
425
432
|
children: [
|
|
426
|
-
/* @__PURE__ */
|
|
433
|
+
/* @__PURE__ */ _("div", {
|
|
427
434
|
className: "flex items-center gap-3",
|
|
428
|
-
children: [/* @__PURE__ */
|
|
435
|
+
children: [/* @__PURE__ */ g("div", {
|
|
429
436
|
className: "p-2 rounded-full bg-primary/10 text-primary",
|
|
430
|
-
children: /* @__PURE__ */
|
|
431
|
-
}), /* @__PURE__ */
|
|
437
|
+
children: /* @__PURE__ */ g(C, { className: "size-5" })
|
|
438
|
+
}), /* @__PURE__ */ g("h2", {
|
|
432
439
|
className: "text-xl font-bold text-foreground",
|
|
433
440
|
children: Y("security.secretDetail.rotate.title", "Rotate Secret")
|
|
434
441
|
})]
|
|
435
442
|
}),
|
|
436
|
-
/* @__PURE__ */
|
|
443
|
+
/* @__PURE__ */ g("p", {
|
|
437
444
|
className: "text-sm text-muted-foreground",
|
|
438
|
-
children: Y("security.secretDetail.rotate.description", "Enter a new value for {name}. The current value will be moved to version history.", { name:
|
|
445
|
+
children: Y("security.secretDetail.rotate.description", "Enter a new value for {name}. The current value will be moved to version history.", { name: I.name })
|
|
439
446
|
}),
|
|
440
|
-
/* @__PURE__ */
|
|
447
|
+
/* @__PURE__ */ _("div", {
|
|
441
448
|
className: "space-y-2",
|
|
442
|
-
children: [/* @__PURE__ */
|
|
449
|
+
children: [/* @__PURE__ */ g("label", {
|
|
443
450
|
htmlFor: "new-secret-value",
|
|
444
451
|
className: "text-sm font-medium",
|
|
445
452
|
children: Y("security.secretDetail.rotate.newValue", "New Secret Value")
|
|
446
|
-
}), /* @__PURE__ */
|
|
453
|
+
}), /* @__PURE__ */ g("textarea", {
|
|
447
454
|
id: "new-secret-value",
|
|
455
|
+
"aria-label": Y("security.secretDetail.rotate.newValue", "New Secret Value"),
|
|
456
|
+
ref: G,
|
|
448
457
|
value: q,
|
|
449
458
|
onChange: (e) => J(e.target.value),
|
|
450
459
|
placeholder: Y("security.secretDetail.rotate.placeholder", "Enter new secret value..."),
|
|
451
460
|
rows: 4,
|
|
452
|
-
className: n("w-full rounded-md border border-border bg-background px-3 py-2 text-sm font-mono transition-all", "focus:outline-none focus:ring-2 focus:ring-primary/50 focus:border-primary", "placeholder:text-muted-foreground/50")
|
|
453
|
-
autoFocus: !0
|
|
461
|
+
className: n("w-full rounded-md border border-border bg-background px-3 py-2 text-sm font-mono transition-all", "focus:outline-none focus:ring-2 focus:ring-primary/50 focus:border-primary", "placeholder:text-muted-foreground/50")
|
|
454
462
|
})]
|
|
455
463
|
}),
|
|
456
|
-
/* @__PURE__ */
|
|
464
|
+
/* @__PURE__ */ _("div", {
|
|
457
465
|
className: "flex justify-end gap-3 pt-2",
|
|
458
|
-
children: [/* @__PURE__ */
|
|
466
|
+
children: [/* @__PURE__ */ g(a, {
|
|
459
467
|
variant: "outline",
|
|
460
|
-
onClick: () =>
|
|
461
|
-
disabled:
|
|
468
|
+
onClick: () => W(!1),
|
|
469
|
+
disabled: V,
|
|
462
470
|
children: Y("security.common.actions.cancel", "Cancel")
|
|
463
|
-
}), /* @__PURE__ */
|
|
464
|
-
onClick:
|
|
465
|
-
disabled:
|
|
466
|
-
children: [
|
|
471
|
+
}), /* @__PURE__ */ _(a, {
|
|
472
|
+
onClick: Ne,
|
|
473
|
+
disabled: V || !q.trim(),
|
|
474
|
+
children: [V ? /* @__PURE__ */ g(S, { className: "size-4 animate-spin" }) : /* @__PURE__ */ g(C, { className: "size-4" }), V ? Y("security.secretDetail.rotate.loading", "Rotating...") : Y("security.secretDetail.rotate.confirm", "Rotate Secret")]
|
|
467
475
|
})]
|
|
468
476
|
})
|
|
469
477
|
]
|
|
@@ -474,6 +482,6 @@ function D() {
|
|
|
474
482
|
});
|
|
475
483
|
}
|
|
476
484
|
//#endregion
|
|
477
|
-
export {
|
|
485
|
+
export { E as SecretDetailPage };
|
|
478
486
|
|
|
479
487
|
//# sourceMappingURL=SecretDetailPage.js.map
|