@burdenoff/microfe-integrations 2026.624.2 → 2026.624.4

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.
@@ -2,77 +2,78 @@ import { useIntegrations as e } from "../providers/IntegrationsProvider.js";
2
2
  import { cn as t } from "../utils/cn.js";
3
3
  import { INTEGRATION_PERMISSIONS as n } from "../constants/permissions.js";
4
4
  import { joinPath as r } from "../utils/navigation.js";
5
- import { formatDate as i, formatLastUsed as a, getAuthTypeLabel as o } from "../utils/integrationsHelpers.js";
6
- import { useConnection as s, useDeleteConnection as c, useRefreshToken as ee, useRevokeConnection as te, useTestConnection as ne } from "../hooks/useConnections.js";
7
- import { ProviderIcon as re } from "../components/ProviderIcon.js";
8
- import { ConnectionStatusBadge as ie } from "../components/ConnectionStatusBadge.js";
5
+ import { formatDate as i, formatLastUsed as ee, getAuthTypeLabel as te } from "../utils/integrationsHelpers.js";
6
+ import { useConnection as ne, useDeleteConnection as re, useRefreshToken as ie, useRevokeConnection as a, useTestConnection as o } from "../hooks/useConnections.js";
7
+ import { ProviderIcon as s } from "../components/ProviderIcon.js";
8
+ import { ConnectionStatusBadge as c } from "../components/ConnectionStatusBadge.js";
9
9
  import { INTEGRATION_FEATURE_FLAGS as ae } from "../constants/featureFlags.js";
10
10
  import { ConfirmDialog as oe } from "../components/ConfirmDialog.js";
11
11
  import { nativeConfirm as se, nativeImpact as ce, nativeNotify as l } from "../../utils/nativeBridge.js";
12
12
  import { useState as u } from "react";
13
- import { Activity as d, AlertCircle as f, ArrowLeft as p, CheckCircle2 as m, Clock as h, Key as g, Loader2 as _, Mail as le, RefreshCw as ue, RotateCcw as de, Shield as v, Trash2 as y, User as fe, XCircle as b, Zap as pe } from "lucide-react";
14
- import { useParams as me } from "react-router-dom";
15
- import { useI18n as he, usePermissions as ge } from "@burdenoff/fe-libs/shared/providers/shell";
16
- import { jsx as x, jsxs as S } from "react/jsx-runtime";
17
- import { useFeatureFlag as _e } from "@burdenoff/fe-libs/shared/feature-flags";
13
+ import { Activity as le, AlertCircle as ue, ArrowLeft as d, CheckCircle2 as f, Clock as de, Key as p, Loader2 as m, Mail as fe, RefreshCw as pe, RotateCcw as h, Shield as g, Trash2 as _, User as me, XCircle as v, Zap as he } from "lucide-react";
14
+ import { useParams as ge } from "react-router-dom";
15
+ import { useI18n as _e, usePermissions as ve } from "@burdenoff/fe-libs/shared/providers/shell";
16
+ import { jsx as y, jsxs as b } from "react/jsx-runtime";
17
+ import { useFeatureFlag as ye } from "@burdenoff/fe-libs/shared/feature-flags";
18
+ import { AlertDialog as be, AlertDialogAction as xe, AlertDialogCancel as x, AlertDialogContent as S, AlertDialogDescription as C, AlertDialogFooter as w, AlertDialogHeader as T, AlertDialogTitle as E } from "@burdenoff/fe-libs/ui";
18
19
  //#region src/integrations/pages/ConnectionDetail.tsx
19
- function C() {
20
- let { connectionId: C } = me(), { basePath: w = "/", navigate: T } = e(), { t: E } = he(), D = (e, t, n) => {
21
- let r = E(e, n);
20
+ function D() {
21
+ let { connectionId: D } = ge(), { basePath: O = "/", navigate: k } = e(), { t: A } = _e(), j = (e, t, n) => {
22
+ let r = A(e, n);
22
23
  return r === e ? n ? Object.entries(n).reduce((e, [t, n]) => e.replace(`{{${t}}}`, String(n)).replace(`{${t}}`, String(n)), t) : t : r;
23
- }, { connection: O, loading: k, error: A, refetch: j } = s(C ?? ""), { testConnection: M, loading: N } = ne(), { refreshToken: P, loading: F } = ee(), { revokeConnection: I, loading: L } = te(), { deleteConnection: ve, loading: R } = c(), ye = _e(ae.OAUTH_REFRESH, !0), { hasPermission: z, isLoading: be } = ge(), B = z(n.CONNECTION_UPDATE), V = z(n.CONNECTION_DELETE), [H, xe] = u(null), [U, W] = u(null), [Se, G] = u(!1), [K, q] = u(!1), [Ce, J] = u(!1), Y = (e, t) => {
24
- W({
24
+ }, { connection: M, loading: Se, error: N, refetch: P } = ne(D ?? ""), { testConnection: Ce, loading: F } = o(), { refreshToken: we, loading: I } = ie(), { revokeConnection: Te, loading: L } = a(), { deleteConnection: R, loading: z } = re(), Ee = ye(ae.OAUTH_REFRESH, !0), { hasPermission: B, isLoading: De } = ve(), V = B(n.CONNECTION_UPDATE), H = B(n.CONNECTION_DELETE), [U, Oe] = u(null), [W, G] = u(null), [ke, K] = u(!1), [q, J] = u(!1), [Ae, Y] = u(!1), X = (e, t) => {
25
+ G({
25
26
  type: e,
26
27
  message: t
27
- }), setTimeout(() => W(null), 5e3);
28
+ }), setTimeout(() => G(null), 5e3);
28
29
  };
29
- if (k || be) return /* @__PURE__ */ S("div", {
30
+ if (Se || De) return /* @__PURE__ */ b("div", {
30
31
  className: "flex flex-col items-center justify-center py-20",
31
- children: [/* @__PURE__ */ x(_, {
32
+ children: [/* @__PURE__ */ y(m, {
32
33
  size: 48,
33
34
  className: "animate-spin text-primary"
34
- }), /* @__PURE__ */ x("span", {
35
+ }), /* @__PURE__ */ y("span", {
35
36
  className: "mt-6 text-sm font-medium text-text-secondary",
36
- children: D("integrations.connectionDetail.loading", "Loading connection details...")
37
+ children: j("integrations.connectionDetail.loading", "Loading connection details...")
37
38
  })]
38
39
  });
39
- if (A || !O) return /* @__PURE__ */ x("div", {
40
+ if (N || !M) return /* @__PURE__ */ y("div", {
40
41
  className: "p-6 max-w-4xl mx-auto",
41
- children: /* @__PURE__ */ S("div", {
42
+ children: /* @__PURE__ */ b("div", {
42
43
  className: "rounded-xl border border-border-default bg-status-error-bg-subtle p-6 flex items-start gap-4",
43
- children: [/* @__PURE__ */ x(f, {
44
+ children: [/* @__PURE__ */ y(ue, {
44
45
  size: 24,
45
46
  className: "text-status-error-text flex-shrink-0"
46
- }), /* @__PURE__ */ S("div", {
47
+ }), /* @__PURE__ */ b("div", {
47
48
  className: "flex-1",
48
49
  children: [
49
- /* @__PURE__ */ x("h3", {
50
+ /* @__PURE__ */ y("h3", {
50
51
  className: "font-semibold text-status-error-text mb-1",
51
- children: D("integrations.connectionDetail.error.title", "Connection not found")
52
+ children: j("integrations.connectionDetail.error.title", "Connection not found")
52
53
  }),
53
- /* @__PURE__ */ x("p", {
54
+ /* @__PURE__ */ y("p", {
54
55
  className: "text-sm text-status-error-text mb-3",
55
- children: A?.message || D("integrations.connectionDetail.error.description", "The requested connection could not be loaded.")
56
+ children: N?.message || j("integrations.connectionDetail.error.description", "The requested connection could not be loaded.")
56
57
  }),
57
- /* @__PURE__ */ S("div", {
58
+ /* @__PURE__ */ b("div", {
58
59
  className: "flex gap-2",
59
- children: [/* @__PURE__ */ S("button", {
60
+ children: [/* @__PURE__ */ b("button", {
60
61
  type: "button",
61
- onClick: () => j(),
62
+ onClick: () => P(),
62
63
  className: "inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium rounded-lg bg-status-error-bg-subtle text-status-error-text hover:bg-status-error-bg-subtle/80 transition-colors",
63
64
  children: [
64
- /* @__PURE__ */ x(ue, { size: 14 }),
65
+ /* @__PURE__ */ y(pe, { size: 14 }),
65
66
  " ",
66
- D("integrations.connectionDetail.error.retry", "Try Again")
67
+ j("integrations.connectionDetail.error.retry", "Try Again")
67
68
  ]
68
- }), /* @__PURE__ */ S("button", {
69
+ }), /* @__PURE__ */ b("button", {
69
70
  type: "button",
70
- onClick: () => T?.(r(w, "connections")),
71
+ onClick: () => k?.(r(O, "connections")),
71
72
  className: "inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium rounded-lg border border-border-subtle hover:bg-accent transition-colors",
72
73
  children: [
73
- /* @__PURE__ */ x(p, { size: 14 }),
74
+ /* @__PURE__ */ y(d, { size: 14 }),
74
75
  " ",
75
- D("integrations.connectionDetail.error.back", "Back to Connections")
76
+ j("integrations.connectionDetail.error.back", "Back to Connections")
76
77
  ]
77
78
  })]
78
79
  })
@@ -80,387 +81,380 @@ function C() {
80
81
  })]
81
82
  })
82
83
  });
83
- let we = async () => {
84
- let e = await M(O.id);
85
- e && (xe(e), Y(e.success ? "success" : "error", e.message));
86
- }, Te = async () => {
87
- await P(O.id), Y("success", D("integrations.connectionDetail.notifications.refreshSuccess", "Token refreshed successfully")), j();
88
- }, Ee = async () => {
89
- J(!0);
90
- }, X = async () => {
91
- await I(O.id), Y("success", D("integrations.connectionDetail.notifications.revokeSuccess", "Connection revoked")), J(!1), j();
92
- }, De = async () => {
84
+ let je = async () => {
85
+ let e = await Ce(M.id);
86
+ e && (Oe(e), X(e.success ? "success" : "error", e.message));
87
+ }, Me = async () => {
88
+ await we(M.id), X("success", j("integrations.connectionDetail.notifications.refreshSuccess", "Token refreshed successfully")), P();
89
+ }, Ne = async () => {
90
+ Y(!0);
91
+ }, Pe = async () => {
92
+ await Te(M.id), X("success", j("integrations.connectionDetail.notifications.revokeSuccess", "Connection revoked")), Y(!1), P();
93
+ }, Fe = async () => {
93
94
  ce("medium");
94
95
  let e = await se({
95
- title: D("integrations.connectionDetail.deleteDialog.title", "Delete Connection"),
96
- message: D("integrations.connectionDetail.deleteDialog.message", "Delete this connection? This cannot be undone."),
97
- okButtonTitle: D("integrations.connectionDetail.deleteDialog.confirm", "Delete"),
98
- cancelButtonTitle: D("integrations.connectionDetail.deleteDialog.cancel", "Cancel")
96
+ title: j("integrations.connectionDetail.deleteDialog.title", "Delete Connection"),
97
+ message: j("integrations.connectionDetail.deleteDialog.message", "Delete this connection? This cannot be undone."),
98
+ okButtonTitle: j("integrations.connectionDetail.deleteDialog.confirm", "Delete"),
99
+ cancelButtonTitle: j("integrations.connectionDetail.deleteDialog.cancel", "Cancel")
99
100
  });
100
101
  if (e === null) {
101
- G(!0);
102
+ K(!0);
102
103
  return;
103
104
  }
104
105
  e && await Z();
105
106
  }, Z = async () => {
106
107
  try {
107
- await ve(O.id, K), Y("success", D("integrations.connectionDetail.notifications.deleteSuccess", "Connection deleted")), l("success"), G(!1), q(!1), T?.(r(w, "connections"));
108
+ await R(M.id, q), X("success", j("integrations.connectionDetail.notifications.deleteSuccess", "Connection deleted")), l("success"), K(!1), J(!1), k?.(r(O, "connections"));
108
109
  } catch (e) {
109
- Y("error", e instanceof Error ? e.message : "Failed to delete connection"), l("error");
110
+ X("error", e instanceof Error ? e.message : "Failed to delete connection"), l("error");
110
111
  }
111
- }, Q = N || F || L || R, $ = !!(O.vaultId || O.credentialSecretId);
112
- return /* @__PURE__ */ S("div", {
112
+ }, Q = F || I || L || z, $ = !!(M.vaultId || M.credentialSecretId);
113
+ return /* @__PURE__ */ b("div", {
113
114
  className: "space-y-6 p-6 max-w-5xl mx-auto",
114
115
  children: [
115
- U && /* @__PURE__ */ S("div", {
116
- className: t("fixed top-4 right-4 z-50 flex items-center gap-3 px-5 py-3 rounded-xl shadow-2xl border-2 animate-in slide-in-from-top-4 duration-300", U.type === "success" ? "bg-status-success-bg-subtle text-status-success-text border-border-default" : "bg-status-error-bg-subtle text-status-error-text border-border-default"),
117
- children: [U.type === "success" ? /* @__PURE__ */ x(m, { size: 20 }) : /* @__PURE__ */ x(b, { size: 20 }), /* @__PURE__ */ x("span", {
116
+ W && /* @__PURE__ */ b("div", {
117
+ className: t("fixed top-4 right-4 z-50 flex items-center gap-3 px-5 py-3 rounded-xl shadow-2xl border-2 animate-in slide-in-from-top-4 duration-200", W.type === "success" ? "bg-status-success-bg-subtle text-status-success-text border-border-default" : "bg-status-error-bg-subtle text-status-error-text border-border-default"),
118
+ children: [W.type === "success" ? /* @__PURE__ */ y(f, { size: 20 }) : /* @__PURE__ */ y(v, { size: 20 }), /* @__PURE__ */ y("span", {
118
119
  className: "font-medium",
119
- children: U.message
120
+ children: W.message
120
121
  })]
121
122
  }),
122
- Se && /* @__PURE__ */ x("div", {
123
- className: "fixed inset-0 z-50 flex items-center justify-center bg-foreground/40 px-4",
124
- children: /* @__PURE__ */ S("div", {
125
- className: "w-full max-w-md rounded-xl border border-border-subtle bg-bg-surface p-6 shadow-2xl space-y-4",
123
+ /* @__PURE__ */ y(be, {
124
+ open: ke,
125
+ onOpenChange: (e) => {
126
+ e || (K(!1), J(!1));
127
+ },
128
+ children: /* @__PURE__ */ b(S, {
129
+ className: "max-w-md",
126
130
  children: [
127
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("h2", {
128
- className: "text-lg font-semibold text-text-primary",
129
- children: "Delete connection"
130
- }), /* @__PURE__ */ x("p", {
131
- className: "text-sm text-text-secondary mt-1",
132
- children: "This removes the connection record immediately. You can also remove the mapped vault secret if you no longer need it."
133
- })] }),
134
- $ && /* @__PURE__ */ S("label", {
131
+ /* @__PURE__ */ b(T, { children: [/* @__PURE__ */ y(E, { children: "Delete connection" }), /* @__PURE__ */ y(C, { children: "This removes the connection record immediately. You can also remove the mapped vault secret if you no longer need it." })] }),
132
+ $ && /* @__PURE__ */ b("label", {
135
133
  className: "flex items-start gap-3 rounded-lg border border-border-subtle/60 bg-bg-surface px-4 py-3 cursor-pointer",
136
- children: [/* @__PURE__ */ x("input", {
134
+ children: [/* @__PURE__ */ y("input", {
137
135
  type: "checkbox",
138
- checked: K,
139
- onChange: (e) => q(e.target.checked),
136
+ checked: q,
137
+ onChange: (e) => J(e.target.checked),
140
138
  className: "mt-0.5",
141
139
  "aria-label": "Also remove mapped vault secret"
142
- }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
140
+ }), /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("p", {
143
141
  className: "text-sm font-medium text-text-primary",
144
142
  children: "Also remove mapped vault secret"
145
- }), /* @__PURE__ */ x("p", {
143
+ }), /* @__PURE__ */ y("p", {
146
144
  className: "text-xs text-text-secondary mt-1",
147
145
  children: "Use this only if no other connections rely on the same secret."
148
146
  })] })]
149
147
  }),
150
- /* @__PURE__ */ S("div", {
151
- className: "flex justify-end gap-3",
152
- children: [/* @__PURE__ */ x("button", {
153
- type: "button",
154
- onClick: () => {
155
- G(!1), q(!1);
156
- },
157
- className: "px-4 py-2 text-sm font-medium rounded-lg border border-border-subtle hover:bg-accent transition-colors",
158
- children: "Cancel"
159
- }), /* @__PURE__ */ S("button", {
160
- type: "button",
161
- onClick: Z,
162
- disabled: R,
163
- className: "inline-flex items-center gap-2 px-4 py-2 text-sm font-medium rounded-lg bg-status-error-bg text-action-primary-text disabled:opacity-50",
164
- children: [R ? /* @__PURE__ */ x(_, {
165
- size: 14,
166
- className: "animate-spin"
167
- }) : /* @__PURE__ */ x(y, { size: 14 }), "Delete connection"]
168
- })]
169
- })
148
+ /* @__PURE__ */ b(w, { children: [/* @__PURE__ */ y(x, {
149
+ onClick: () => {
150
+ K(!1), J(!1);
151
+ },
152
+ children: "Cancel"
153
+ }), /* @__PURE__ */ b(xe, {
154
+ disabled: z,
155
+ onClick: (e) => {
156
+ e.preventDefault(), Z();
157
+ },
158
+ className: "inline-flex items-center gap-2 bg-status-error-bg text-action-primary-text disabled:opacity-50",
159
+ children: [z ? /* @__PURE__ */ y(m, {
160
+ size: 14,
161
+ className: "animate-spin"
162
+ }) : /* @__PURE__ */ y(_, { size: 14 }), "Delete connection"]
163
+ })] })
170
164
  ]
171
165
  })
172
166
  }),
173
- /* @__PURE__ */ x(oe, {
174
- open: Ce,
175
- title: D("integrations.connectionDetail.confirm.revokeTitle", "Revoke connection"),
176
- description: D("integrations.connectionDetail.confirm.revoke", "Are you sure you want to revoke this connection? This will disconnect the external service."),
177
- confirmLabel: D("integrations.connectionDetail.actions.revoke", "Revoke"),
178
- cancelLabel: D("integrations.connectionDetail.actions.cancel", "Cancel"),
167
+ /* @__PURE__ */ y(oe, {
168
+ open: Ae,
169
+ title: j("integrations.connectionDetail.confirm.revokeTitle", "Revoke connection"),
170
+ description: j("integrations.connectionDetail.confirm.revoke", "Are you sure you want to revoke this connection? This will disconnect the external service."),
171
+ confirmLabel: j("integrations.connectionDetail.actions.revoke", "Revoke"),
172
+ cancelLabel: j("integrations.connectionDetail.actions.cancel", "Cancel"),
179
173
  loading: L,
180
174
  destructive: !0,
181
- icon: /* @__PURE__ */ x(v, { size: 20 }),
182
- onConfirm: X,
183
- onCancel: () => J(!1)
175
+ icon: /* @__PURE__ */ y(g, { size: 20 }),
176
+ onConfirm: Pe,
177
+ onCancel: () => Y(!1)
184
178
  }),
185
- /* @__PURE__ */ S("div", {
179
+ /* @__PURE__ */ b("div", {
186
180
  className: "relative overflow-hidden rounded-xl bg-gradient-to-br from-primary/5 via-primary/3 to-background border border-border-subtle/50 p-6 shadow-sm",
187
- children: [/* @__PURE__ */ S("div", {
181
+ children: [/* @__PURE__ */ b("div", {
188
182
  className: "relative z-10 flex items-center gap-4",
189
183
  children: [
190
- /* @__PURE__ */ x("button", {
184
+ /* @__PURE__ */ y("button", {
191
185
  type: "button",
192
- onClick: () => T?.(r(w, "connections")),
186
+ onClick: () => k?.(r(O, "connections")),
193
187
  className: "p-2.5 hover:bg-accent rounded-lg transition-all",
194
- "aria-label": D("integrations.connectionDetail.actions.backAriaLabel", "Back"),
195
- children: /* @__PURE__ */ x(p, { size: 20 })
188
+ "aria-label": j("integrations.connectionDetail.actions.backAriaLabel", "Back"),
189
+ children: /* @__PURE__ */ y(d, { size: 20 })
196
190
  }),
197
- /* @__PURE__ */ x(re, {
198
- provider: O.provider,
191
+ /* @__PURE__ */ y(s, {
192
+ provider: M.provider,
199
193
  size: 56
200
194
  }),
201
- /* @__PURE__ */ S("div", {
195
+ /* @__PURE__ */ b("div", {
202
196
  className: "flex-1",
203
- children: [/* @__PURE__ */ S("div", {
197
+ children: [/* @__PURE__ */ b("div", {
204
198
  className: "flex items-center gap-3",
205
- children: [/* @__PURE__ */ x("h1", {
199
+ children: [/* @__PURE__ */ y("h1", {
206
200
  className: "text-2xl sm:text-3xl font-bold text-text-primary",
207
- children: O.name
208
- }), /* @__PURE__ */ x(ie, {
209
- status: O.status,
201
+ children: M.name
202
+ }), /* @__PURE__ */ y(c, {
203
+ status: M.status,
210
204
  size: "md"
211
205
  })]
212
- }), /* @__PURE__ */ S("p", {
206
+ }), /* @__PURE__ */ b("p", {
213
207
  className: "text-sm text-text-secondary mt-0.5",
214
208
  children: [
215
- O.provider.name,
209
+ M.provider.name,
216
210
  " · ",
217
- o(O.provider.authType)
211
+ te(M.provider.authType)
218
212
  ]
219
213
  })]
220
214
  })
221
215
  ]
222
- }), /* @__PURE__ */ x("div", { className: "absolute top-0 right-0 size-64 bg-gradient-to-br from-primary/10 to-transparent rounded-full blur-3xl -z-0" })]
216
+ }), /* @__PURE__ */ y("div", { className: "absolute top-0 right-0 size-64 bg-gradient-to-br from-primary/10 to-transparent rounded-full blur-3xl -z-0" })]
223
217
  }),
224
- /* @__PURE__ */ S("div", {
218
+ /* @__PURE__ */ b("div", {
225
219
  className: "grid grid-cols-1 md:grid-cols-2 gap-4",
226
- children: [/* @__PURE__ */ S("div", {
220
+ children: [/* @__PURE__ */ b("div", {
227
221
  className: "rounded-xl border border-border-subtle/50 bg-bg-surface p-5 space-y-4",
228
- children: [/* @__PURE__ */ S("h2", {
222
+ children: [/* @__PURE__ */ b("h2", {
229
223
  className: "font-semibold text-text-primary flex items-center gap-2",
230
- children: [/* @__PURE__ */ x(d, {
224
+ children: [/* @__PURE__ */ y(le, {
231
225
  size: 18,
232
226
  className: "text-primary"
233
- }), D("integrations.connectionDetail.sections.info", "Connection Info")]
234
- }), /* @__PURE__ */ S("div", {
227
+ }), j("integrations.connectionDetail.sections.info", "Connection Info")]
228
+ }), /* @__PURE__ */ b("div", {
235
229
  className: "space-y-3",
236
230
  children: [
237
- O.description && /* @__PURE__ */ S("div", {
231
+ M.description && /* @__PURE__ */ b("div", {
238
232
  className: "py-2 border-b border-border-subtle/50",
239
- children: [/* @__PURE__ */ x("span", {
233
+ children: [/* @__PURE__ */ y("span", {
240
234
  className: "text-xs text-text-secondary uppercase tracking-wide",
241
- children: D("integrations.connectionDetail.fields.description", "Description")
242
- }), /* @__PURE__ */ x("p", {
235
+ children: j("integrations.connectionDetail.fields.description", "Description")
236
+ }), /* @__PURE__ */ y("p", {
243
237
  className: "text-sm text-text-primary mt-0.5",
244
- children: O.description
238
+ children: M.description
245
239
  })]
246
240
  }),
247
- /* @__PURE__ */ S("div", {
241
+ /* @__PURE__ */ b("div", {
248
242
  className: "flex items-center justify-between py-2 border-b border-border-subtle/50",
249
- children: [/* @__PURE__ */ x("span", {
243
+ children: [/* @__PURE__ */ y("span", {
250
244
  className: "text-sm text-text-secondary",
251
- children: D("integrations.connectionDetail.fields.provider", "Provider")
252
- }), /* @__PURE__ */ x("span", {
245
+ children: j("integrations.connectionDetail.fields.provider", "Provider")
246
+ }), /* @__PURE__ */ y("span", {
253
247
  className: "text-sm font-medium text-text-primary",
254
- children: O.provider.name
248
+ children: M.provider.name
255
249
  })]
256
250
  }),
257
- O.externalAccountEmail && /* @__PURE__ */ S("div", {
251
+ M.externalAccountEmail && /* @__PURE__ */ b("div", {
258
252
  className: "flex items-center justify-between py-2 border-b border-border-subtle/50",
259
- children: [/* @__PURE__ */ S("span", {
253
+ children: [/* @__PURE__ */ b("span", {
260
254
  className: "text-sm text-text-secondary flex items-center gap-1",
261
255
  children: [
262
- /* @__PURE__ */ x(le, { size: 14 }),
256
+ /* @__PURE__ */ y(fe, { size: 14 }),
263
257
  " ",
264
- D("integrations.connectionDetail.fields.account", "Account")
258
+ j("integrations.connectionDetail.fields.account", "Account")
265
259
  ]
266
- }), /* @__PURE__ */ x("span", {
260
+ }), /* @__PURE__ */ y("span", {
267
261
  className: "text-sm font-medium text-text-primary",
268
- children: O.externalAccountEmail
262
+ children: M.externalAccountEmail
269
263
  })]
270
264
  }),
271
- O.externalAccountName && /* @__PURE__ */ S("div", {
265
+ M.externalAccountName && /* @__PURE__ */ b("div", {
272
266
  className: "flex items-center justify-between py-2 border-b border-border-subtle/50",
273
- children: [/* @__PURE__ */ S("span", {
267
+ children: [/* @__PURE__ */ b("span", {
274
268
  className: "text-sm text-text-secondary flex items-center gap-1",
275
269
  children: [
276
- /* @__PURE__ */ x(fe, { size: 14 }),
270
+ /* @__PURE__ */ y(me, { size: 14 }),
277
271
  " ",
278
- D("integrations.connectionDetail.fields.name", "Name")
272
+ j("integrations.connectionDetail.fields.name", "Name")
279
273
  ]
280
- }), /* @__PURE__ */ x("span", {
274
+ }), /* @__PURE__ */ y("span", {
281
275
  className: "text-sm font-medium text-text-primary",
282
- children: O.externalAccountName
276
+ children: M.externalAccountName
283
277
  })]
284
278
  }),
285
- O.errorMessage && /* @__PURE__ */ S("div", {
279
+ M.errorMessage && /* @__PURE__ */ b("div", {
286
280
  className: "py-2 border-b border-border-subtle/50",
287
- children: [/* @__PURE__ */ x("span", {
281
+ children: [/* @__PURE__ */ y("span", {
288
282
  className: "text-xs text-status-error-text uppercase tracking-wide",
289
- children: D("integrations.connectionDetail.fields.error", "Error")
290
- }), /* @__PURE__ */ x("p", {
283
+ children: j("integrations.connectionDetail.fields.error", "Error")
284
+ }), /* @__PURE__ */ y("p", {
291
285
  className: "text-sm text-status-error-text mt-0.5 bg-status-error-bg-subtle rounded-lg p-2",
292
- children: O.errorMessage
286
+ children: M.errorMessage
293
287
  })]
294
288
  }),
295
- /* @__PURE__ */ S("div", {
289
+ /* @__PURE__ */ b("div", {
296
290
  className: "flex items-center justify-between py-2 border-b border-border-subtle/50",
297
- children: [/* @__PURE__ */ S("span", {
291
+ children: [/* @__PURE__ */ b("span", {
298
292
  className: "text-sm text-text-secondary flex items-center gap-1",
299
293
  children: [
300
- /* @__PURE__ */ x(h, { size: 14 }),
294
+ /* @__PURE__ */ y(de, { size: 14 }),
301
295
  " ",
302
- D("integrations.connectionDetail.fields.lastUsed", "Last Used")
296
+ j("integrations.connectionDetail.fields.lastUsed", "Last Used")
303
297
  ]
304
- }), /* @__PURE__ */ x("span", {
298
+ }), /* @__PURE__ */ y("span", {
305
299
  className: "text-sm text-text-primary",
306
- children: a(O.lastUsedAt)
300
+ children: ee(M.lastUsedAt)
307
301
  })]
308
302
  }),
309
- /* @__PURE__ */ S("div", {
303
+ /* @__PURE__ */ b("div", {
310
304
  className: "flex items-center justify-between py-2 border-b border-border-subtle/50",
311
- children: [/* @__PURE__ */ x("span", {
305
+ children: [/* @__PURE__ */ y("span", {
312
306
  className: "text-sm text-text-secondary",
313
- children: D("integrations.connectionDetail.fields.healthCheck", "Health Check")
314
- }), /* @__PURE__ */ x("span", {
307
+ children: j("integrations.connectionDetail.fields.healthCheck", "Health Check")
308
+ }), /* @__PURE__ */ y("span", {
315
309
  className: "text-sm text-text-primary",
316
- children: i(O.lastHealthCheck)
310
+ children: i(M.lastHealthCheck)
317
311
  })]
318
312
  }),
319
- /* @__PURE__ */ S("div", {
313
+ /* @__PURE__ */ b("div", {
320
314
  className: "flex items-center justify-between py-2",
321
- children: [/* @__PURE__ */ x("span", {
315
+ children: [/* @__PURE__ */ y("span", {
322
316
  className: "text-sm text-text-secondary",
323
- children: D("integrations.connectionDetail.fields.created", "Created")
324
- }), /* @__PURE__ */ x("span", {
317
+ children: j("integrations.connectionDetail.fields.created", "Created")
318
+ }), /* @__PURE__ */ y("span", {
325
319
  className: "text-sm text-text-primary",
326
- children: i(O.createdAt)
320
+ children: i(M.createdAt)
327
321
  })]
328
322
  })
329
323
  ]
330
324
  })]
331
- }), /* @__PURE__ */ S("div", {
325
+ }), /* @__PURE__ */ b("div", {
332
326
  className: "space-y-4",
333
327
  children: [
334
- /* @__PURE__ */ S("div", {
328
+ /* @__PURE__ */ b("div", {
335
329
  className: "rounded-xl border border-border-subtle/50 bg-bg-surface p-5",
336
- children: [/* @__PURE__ */ S("h2", {
330
+ children: [/* @__PURE__ */ b("h2", {
337
331
  className: "font-semibold text-text-primary flex items-center gap-2 mb-3",
338
- children: [/* @__PURE__ */ x(v, {
332
+ children: [/* @__PURE__ */ y(g, {
339
333
  size: 18,
340
334
  className: "text-primary"
341
- }), D("integrations.connectionDetail.sections.scopes", "Granted Scopes")]
342
- }), O.grantedScopes.length > 0 ? /* @__PURE__ */ x("div", {
335
+ }), j("integrations.connectionDetail.sections.scopes", "Granted Scopes")]
336
+ }), M.grantedScopes.length > 0 ? /* @__PURE__ */ y("div", {
343
337
  className: "flex flex-wrap gap-2",
344
- children: O.grantedScopes.map((e) => /* @__PURE__ */ x("span", {
338
+ children: M.grantedScopes.map((e) => /* @__PURE__ */ y("span", {
345
339
  className: "text-xs px-2.5 py-1 rounded-full bg-bg-sunken text-text-secondary font-mono",
346
340
  children: e
347
341
  }, e))
348
- }) : /* @__PURE__ */ x("p", {
342
+ }) : /* @__PURE__ */ y("p", {
349
343
  className: "text-sm text-text-secondary",
350
- children: D("integrations.connectionDetail.scopes.empty", "No scopes granted.")
344
+ children: j("integrations.connectionDetail.scopes.empty", "No scopes granted.")
351
345
  })]
352
346
  }),
353
- H && /* @__PURE__ */ S("div", {
354
- className: t("rounded-xl border p-5", H.success ? "border-border-default bg-status-success-bg-subtle" : "border-border-default bg-status-error-bg-subtle"),
347
+ U && /* @__PURE__ */ b("div", {
348
+ className: t("rounded-xl border p-5", U.success ? "border-border-default bg-status-success-bg-subtle" : "border-border-default bg-status-error-bg-subtle"),
355
349
  children: [
356
- /* @__PURE__ */ S("h2", {
357
- className: t("font-semibold flex items-center gap-2 mb-2", H.success ? "text-status-success-text" : "text-status-error-text"),
358
- children: [H.success ? /* @__PURE__ */ x(m, { size: 18 }) : /* @__PURE__ */ x(b, { size: 18 }), H.success ? D("integrations.connectionDetail.testResult.passed", "Connection Test Passed") : D("integrations.connectionDetail.testResult.failed", "Connection Test Failed")]
350
+ /* @__PURE__ */ b("h2", {
351
+ className: t("font-semibold flex items-center gap-2 mb-2", U.success ? "text-status-success-text" : "text-status-error-text"),
352
+ children: [U.success ? /* @__PURE__ */ y(f, { size: 18 }) : /* @__PURE__ */ y(v, { size: 18 }), U.success ? j("integrations.connectionDetail.testResult.passed", "Connection Test Passed") : j("integrations.connectionDetail.testResult.failed", "Connection Test Failed")]
359
353
  }),
360
- /* @__PURE__ */ x("p", {
361
- className: t("text-sm", H.success ? "text-status-success-text" : "text-status-error-text"),
362
- children: H.message
354
+ /* @__PURE__ */ y("p", {
355
+ className: t("text-sm", U.success ? "text-status-success-text" : "text-status-error-text"),
356
+ children: U.message
363
357
  }),
364
- /* @__PURE__ */ x("p", {
358
+ /* @__PURE__ */ y("p", {
365
359
  className: "text-xs text-text-secondary mt-1",
366
- children: D("integrations.connectionDetail.testResult.latency", "Latency: {latency}ms", { latency: H.latencyMs })
360
+ children: j("integrations.connectionDetail.testResult.latency", "Latency: {latency}ms", { latency: U.latencyMs })
367
361
  })
368
362
  ]
369
363
  }),
370
- $ && /* @__PURE__ */ S("div", {
364
+ $ && /* @__PURE__ */ b("div", {
371
365
  className: "rounded-xl border border-border-subtle/50 bg-bg-surface p-5",
372
- children: [/* @__PURE__ */ S("h2", {
366
+ children: [/* @__PURE__ */ b("h2", {
373
367
  className: "font-semibold text-text-primary flex items-center gap-2 mb-3",
374
- children: [/* @__PURE__ */ x(g, {
368
+ children: [/* @__PURE__ */ y(p, {
375
369
  size: 18,
376
370
  className: "text-primary"
377
371
  }), "Credential Storage"]
378
- }), /* @__PURE__ */ S("div", {
372
+ }), /* @__PURE__ */ b("div", {
379
373
  className: "space-y-2 text-sm",
380
374
  children: [
381
- O.vaultId && /* @__PURE__ */ S("div", {
375
+ M.vaultId && /* @__PURE__ */ b("div", {
382
376
  className: "flex items-center justify-between gap-3",
383
- children: [/* @__PURE__ */ x("span", {
377
+ children: [/* @__PURE__ */ y("span", {
384
378
  className: "text-text-secondary",
385
379
  children: "Vault"
386
- }), /* @__PURE__ */ x("span", {
380
+ }), /* @__PURE__ */ y("span", {
387
381
  className: "font-medium text-text-primary break-all",
388
- children: O.vaultId
382
+ children: M.vaultId
389
383
  })]
390
384
  }),
391
- O.credentialSecretName && /* @__PURE__ */ S("div", {
385
+ M.credentialSecretName && /* @__PURE__ */ b("div", {
392
386
  className: "flex items-center justify-between gap-3",
393
- children: [/* @__PURE__ */ x("span", {
387
+ children: [/* @__PURE__ */ y("span", {
394
388
  className: "text-text-secondary",
395
389
  children: "Secret"
396
- }), /* @__PURE__ */ x("span", {
390
+ }), /* @__PURE__ */ y("span", {
397
391
  className: "font-medium text-text-primary break-all",
398
- children: O.credentialSecretName
392
+ children: M.credentialSecretName
399
393
  })]
400
394
  }),
401
- O.credentialSecretId && /* @__PURE__ */ S("div", {
395
+ M.credentialSecretId && /* @__PURE__ */ b("div", {
402
396
  className: "flex items-center justify-between gap-3",
403
- children: [/* @__PURE__ */ x("span", {
397
+ children: [/* @__PURE__ */ y("span", {
404
398
  className: "text-text-secondary",
405
399
  children: "Secret ID"
406
- }), /* @__PURE__ */ x("span", {
400
+ }), /* @__PURE__ */ y("span", {
407
401
  className: "font-mono text-xs text-text-primary break-all",
408
- children: O.credentialSecretId
402
+ children: M.credentialSecretId
409
403
  })]
410
404
  })
411
405
  ]
412
406
  })]
413
407
  }),
414
- (B || V) && /* @__PURE__ */ S("div", {
408
+ (V || H) && /* @__PURE__ */ b("div", {
415
409
  className: "rounded-xl border border-border-subtle/50 bg-bg-surface p-5",
416
- children: [/* @__PURE__ */ S("h2", {
410
+ children: [/* @__PURE__ */ b("h2", {
417
411
  className: "font-semibold text-text-primary flex items-center gap-2 mb-3",
418
- children: [/* @__PURE__ */ x(g, {
412
+ children: [/* @__PURE__ */ y(p, {
419
413
  size: 18,
420
414
  className: "text-primary"
421
- }), D("integrations.connectionDetail.sections.actions", "Actions")]
422
- }), /* @__PURE__ */ S("div", {
415
+ }), j("integrations.connectionDetail.sections.actions", "Actions")]
416
+ }), /* @__PURE__ */ b("div", {
423
417
  className: "flex flex-wrap gap-2",
424
418
  children: [
425
- /* @__PURE__ */ S("button", {
419
+ /* @__PURE__ */ b("button", {
426
420
  type: "button",
427
- onClick: we,
421
+ onClick: je,
428
422
  disabled: Q,
429
423
  className: "inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium rounded-lg bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90 transition-colors disabled:opacity-50",
430
- children: [N ? /* @__PURE__ */ x(_, {
424
+ children: [F ? /* @__PURE__ */ y(m, {
431
425
  size: 14,
432
426
  className: "animate-spin"
433
- }) : /* @__PURE__ */ x(pe, { size: 14 }), D("integrations.connectionDetail.actions.test", "Test Connection")]
427
+ }) : /* @__PURE__ */ y(he, { size: 14 }), j("integrations.connectionDetail.actions.test", "Test Connection")]
434
428
  }),
435
- B && O.provider.authType === "oauth2" && ye && /* @__PURE__ */ S("button", {
429
+ V && M.provider.authType === "oauth2" && Ee && /* @__PURE__ */ b("button", {
436
430
  type: "button",
437
- onClick: Te,
431
+ onClick: Me,
438
432
  disabled: Q,
439
433
  className: "inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium rounded-lg border border-border-subtle hover:bg-accent transition-colors disabled:opacity-50",
440
- children: [F ? /* @__PURE__ */ x(_, {
434
+ children: [I ? /* @__PURE__ */ y(m, {
441
435
  size: 14,
442
436
  className: "animate-spin"
443
- }) : /* @__PURE__ */ x(de, { size: 14 }), D("integrations.connectionDetail.actions.refreshToken", "Refresh Token")]
437
+ }) : /* @__PURE__ */ y(h, { size: 14 }), j("integrations.connectionDetail.actions.refreshToken", "Refresh Token")]
444
438
  }),
445
- V && /* @__PURE__ */ S("button", {
439
+ H && /* @__PURE__ */ b("button", {
446
440
  type: "button",
447
- onClick: Ee,
441
+ onClick: Ne,
448
442
  disabled: Q,
449
443
  className: "inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium rounded-lg border border-border-default text-status-warning-text hover:bg-status-warning-bg-subtle transition-colors disabled:opacity-50",
450
- children: [L ? /* @__PURE__ */ x(_, {
444
+ children: [L ? /* @__PURE__ */ y(m, {
451
445
  size: 14,
452
446
  className: "animate-spin"
453
- }) : /* @__PURE__ */ x(v, { size: 14 }), D("integrations.connectionDetail.actions.revoke", "Revoke")]
447
+ }) : /* @__PURE__ */ y(g, { size: 14 }), j("integrations.connectionDetail.actions.revoke", "Revoke")]
454
448
  }),
455
- V && /* @__PURE__ */ S("button", {
449
+ H && /* @__PURE__ */ b("button", {
456
450
  type: "button",
457
- onClick: De,
451
+ onClick: Fe,
458
452
  disabled: Q,
459
453
  className: "inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium rounded-lg border border-border-default text-status-error-text hover:bg-status-error-bg-subtle transition-colors disabled:opacity-50",
460
- children: [R ? /* @__PURE__ */ x(_, {
454
+ children: [z ? /* @__PURE__ */ y(m, {
461
455
  size: 14,
462
456
  className: "animate-spin"
463
- }) : /* @__PURE__ */ x(y, { size: 14 }), D("integrations.connectionDetail.actions.delete", "Delete")]
457
+ }) : /* @__PURE__ */ y(_, { size: 14 }), j("integrations.connectionDetail.actions.delete", "Delete")]
464
458
  })
465
459
  ]
466
460
  })]
@@ -472,6 +466,6 @@ function C() {
472
466
  });
473
467
  }
474
468
  //#endregion
475
- export { C as ConnectionDetail };
469
+ export { D as ConnectionDetail };
476
470
 
477
471
  //# sourceMappingURL=ConnectionDetail.js.map