@burdenoff/microfe-integrations 2026.527.2 → 2026.529.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/integrations/components/AddConnectionDialog.js +140 -133
- package/dist/integrations/components/AddConnectionDialog.js.map +1 -1
- package/dist/integrations/hooks/useProviders.js +22 -18
- package/dist/integrations/hooks/useProviders.js.map +1 -1
- package/dist/integrations/pages/AddConnectionWizard.js +247 -233
- package/dist/integrations/pages/AddConnectionWizard.js.map +1 -1
- package/dist/integrations/pages/ConnectionsList.js +7 -7
- package/dist/integrations/pages/ProviderCatalog.js +10 -10
- package/dist/integrations/pages/ProviderCatalog.js.map +1 -1
- package/dist/integrations/pages/ProviderEditorPage.js +159 -154
- package/dist/integrations/pages/ProviderEditorPage.js.map +1 -1
- package/dist/integrations/utils/constants.js +10 -1
- package/dist/integrations/utils/constants.js.map +1 -1
- package/package.json +2 -2
|
@@ -4,166 +4,170 @@ import { INTEGRATION_PERMISSIONS as n } from "../constants/permissions.js";
|
|
|
4
4
|
import { joinPath as r } from "../utils/navigation.js";
|
|
5
5
|
import { getAuthTypeLabel as i, getCategoryLabel as ee } from "../utils/integrationsHelpers.js";
|
|
6
6
|
import { useGetConnectionLazyQuery as te } from "../../generated/wspace-operations.js";
|
|
7
|
-
import {
|
|
8
|
-
import { useAuthenticateWithApiKey as
|
|
9
|
-
import { waitForOAuthPopupCompletion as
|
|
10
|
-
import { CredentialStorageSelector as
|
|
11
|
-
import { ProviderIcon as
|
|
12
|
-
import { useCallback as
|
|
13
|
-
import { AlertCircle as
|
|
14
|
-
import { useLocation as
|
|
15
|
-
import { usePermissions as
|
|
16
|
-
import { jsx as
|
|
7
|
+
import { useProvider as ne, useProviderByKey as re, useProviders as ie } from "../hooks/useProviders.js";
|
|
8
|
+
import { useAuthenticateWithApiKey as ae, useAuthenticateWithBasicAuth as oe, useAuthenticateWithBearerToken as se, useCreateConnection as ce, useInitiateOAuth as le } from "../hooks/useConnections.js";
|
|
9
|
+
import { waitForOAuthPopupCompletion as ue } from "../utils/oauthPopup.js";
|
|
10
|
+
import { CredentialStorageSelector as de } from "../components/CredentialStorageSelector.js";
|
|
11
|
+
import { ProviderIcon as fe } from "../components/ProviderIcon.js";
|
|
12
|
+
import { useCallback as a, useEffect as o, useMemo as s, useRef as c, useState as l } from "react";
|
|
13
|
+
import { AlertCircle as u, ArrowLeft as pe, ArrowRight as me, Check as he, CheckCircle2 as ge, ExternalLink as _e, Key as ve, Link as ye, Loader2 as d, Lock as be, Search as xe, Shield as Se } from "lucide-react";
|
|
14
|
+
import { useLocation as Ce, useParams as we } from "react-router-dom";
|
|
15
|
+
import { usePermissions as Te } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
16
|
+
import { jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
17
17
|
//#region src/integrations/pages/AddConnectionWizard.tsx
|
|
18
|
-
function
|
|
19
|
-
let { providerId:
|
|
18
|
+
function m() {
|
|
19
|
+
let { providerId: m } = we(), { basePath: h = "/", navigate: g, apiGatewayUrl: _ } = e(), v = Ce().search, y = s(() => new URLSearchParams(v), [v]), b = y.get("providerKey") ?? null, x = y.get("returnTo") ?? null, S = y.get("channelId") ?? null, C = !!(x && S), { provider: w, loading: Ee } = re(b ?? ""), { providers: T, loading: E } = ie(), { hasPermission: De, isLoading: Oe } = Te(), ke = De(n.CONNECTION_CREATE), { createConnection: D, loading: Ae } = ce(), { initiateOAuth: O, loading: je } = le(), { authenticateWithApiKey: k, loading: Me } = ae(), { authenticateWithBasicAuth: A, loading: Ne } = oe(), { authenticateWithBearerToken: j, loading: Pe } = se(), [Fe] = te({ fetchPolicy: "network-only" }), [M, N] = l(m || b ? "configure" : "select_provider"), [P, Ie] = l(null), [F, Le] = l(""), [I, L] = l(""), [R, Re] = l(""), [z, ze] = l(""), [B, Be] = l(""), [V, Ve] = l(""), [H, He] = l(""), [U, Ue] = l({
|
|
20
20
|
mode: "managed",
|
|
21
21
|
vaultId: "",
|
|
22
22
|
secretId: "",
|
|
23
23
|
managedSecretName: ""
|
|
24
|
-
}), [
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
}), [W, G] = l(""), [K, We] = l(null), [Ge, Ke] = l(!1), q = c(null), J = c(null);
|
|
25
|
+
o(() => () => {
|
|
26
|
+
J.current?.(), q.current && !q.current.closed && q.current.close();
|
|
27
27
|
}, []);
|
|
28
|
-
let
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
let Y = s(() => !m || !T ? null : T.find((e) => e.id === m) || null, [m, T]), { provider: qe, loading: Je } = ne(m && !Y && !E ? m : ""), X = s(() => w ?? Y ?? qe, [
|
|
29
|
+
w,
|
|
30
|
+
Y,
|
|
31
|
+
qe
|
|
32
|
+
]);
|
|
33
|
+
o(() => {
|
|
34
|
+
X && !P && M === "configure" && (Ie(X), I || L(`${X.name} Connection`));
|
|
31
35
|
}, [
|
|
32
36
|
X,
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
37
|
+
P,
|
|
38
|
+
M,
|
|
39
|
+
I
|
|
36
40
|
]);
|
|
37
|
-
let
|
|
41
|
+
let Ye = s(() => {
|
|
38
42
|
let e = (T ?? []).filter((e) => e.pluginStatus === "installed" && e.isEnabled);
|
|
39
|
-
if (!
|
|
40
|
-
let t =
|
|
43
|
+
if (!F) return e;
|
|
44
|
+
let t = F.toLowerCase();
|
|
41
45
|
return e.filter((e) => e.name.toLowerCase().includes(t) || (e.description ?? "").toLowerCase().includes(t));
|
|
42
|
-
}, [T,
|
|
43
|
-
|
|
44
|
-
}, []),
|
|
45
|
-
if (!
|
|
46
|
-
|
|
46
|
+
}, [T, F]), Xe = a((e) => {
|
|
47
|
+
Ie(e), L(`${e.name} Connection`), N("configure");
|
|
48
|
+
}, []), Ze = a(() => {
|
|
49
|
+
if (!I.trim()) {
|
|
50
|
+
G("Connection name is required");
|
|
47
51
|
return;
|
|
48
52
|
}
|
|
49
|
-
if (!
|
|
50
|
-
|
|
53
|
+
if (!U.vaultId) {
|
|
54
|
+
G("Please select a vault for storing or referencing credentials");
|
|
51
55
|
return;
|
|
52
56
|
}
|
|
53
|
-
if (
|
|
54
|
-
|
|
57
|
+
if (U.mode === "existing" && !U.secretId) {
|
|
58
|
+
G("Please select an existing vault secret to reuse");
|
|
55
59
|
return;
|
|
56
60
|
}
|
|
57
|
-
|
|
58
|
-
}, [
|
|
59
|
-
if (
|
|
60
|
-
|
|
61
|
-
let e =
|
|
61
|
+
G(""), N("authenticate");
|
|
62
|
+
}, [I, U]), Qe = a(async () => {
|
|
63
|
+
if (P) try {
|
|
64
|
+
G("");
|
|
65
|
+
let e = _ ? `${_}/integrations/oauth/callback` : "/integrations/oauth/callback", t = C ? {
|
|
62
66
|
returnTo: x,
|
|
63
67
|
channelId: S
|
|
64
|
-
} : void 0, n =
|
|
65
|
-
name:
|
|
66
|
-
description:
|
|
67
|
-
providerId:
|
|
68
|
-
vaultId:
|
|
69
|
-
credentialSecretId:
|
|
70
|
-
managedSecretName:
|
|
68
|
+
} : void 0, n = K ?? await D({
|
|
69
|
+
name: I.trim(),
|
|
70
|
+
description: R.trim(),
|
|
71
|
+
providerId: P.id,
|
|
72
|
+
vaultId: U.vaultId,
|
|
73
|
+
credentialSecretId: U.mode === "existing" ? U.secretId : void 0,
|
|
74
|
+
managedSecretName: U.mode === "managed" && U.managedSecretName.trim() || void 0,
|
|
71
75
|
...t ? { config: t } : {}
|
|
72
76
|
});
|
|
73
77
|
if (!n) {
|
|
74
|
-
|
|
78
|
+
G("Failed to create connection"), N("error");
|
|
75
79
|
return;
|
|
76
80
|
}
|
|
77
|
-
switch (
|
|
81
|
+
switch (We(n), P.authType) {
|
|
78
82
|
case "oauth2": {
|
|
79
|
-
let t = await O(n, e,
|
|
83
|
+
let t = await O(n, e, P.key);
|
|
80
84
|
if (t?.redirectUrl) if (C) {
|
|
81
85
|
window.location.href = t.redirectUrl;
|
|
82
86
|
return;
|
|
83
87
|
} else {
|
|
84
88
|
let e = window.screenX + (window.innerWidth - 600) / 2, r = window.screenY + (window.innerHeight - 700) / 2, i = window.open(t.redirectUrl, "oauth_popup", `width=600,height=700,left=${e},top=${r},toolbar=no,menubar=no,scrollbars=yes,resizable=yes`);
|
|
85
89
|
if (!i) {
|
|
86
|
-
|
|
90
|
+
G("Popup was blocked. Please allow popups for this site and try again."), N("error");
|
|
87
91
|
return;
|
|
88
92
|
}
|
|
89
|
-
|
|
93
|
+
q.current = i, Ke(!0), J.current?.(), J.current = ue({
|
|
90
94
|
connectionId: n,
|
|
91
95
|
popup: i,
|
|
92
96
|
fetchConnectionStatus: async () => {
|
|
93
|
-
let { data: e } = await
|
|
97
|
+
let { data: e } = await Fe({ variables: { id: n } });
|
|
94
98
|
return e?.getConnection ?? null;
|
|
95
99
|
},
|
|
96
100
|
onSuccess: () => {
|
|
97
|
-
|
|
101
|
+
N("success");
|
|
98
102
|
},
|
|
99
103
|
onError: (e) => {
|
|
100
|
-
|
|
104
|
+
G(e), N("error");
|
|
101
105
|
},
|
|
102
106
|
onSettled: () => {
|
|
103
|
-
|
|
107
|
+
J.current = null, q.current = null, Ke(!1);
|
|
104
108
|
}
|
|
105
109
|
});
|
|
106
110
|
return;
|
|
107
111
|
}
|
|
108
|
-
|
|
112
|
+
N("success");
|
|
109
113
|
break;
|
|
110
114
|
}
|
|
111
115
|
case "api_key":
|
|
112
|
-
if (!
|
|
113
|
-
|
|
116
|
+
if (!z.trim()) {
|
|
117
|
+
G("API key is required");
|
|
114
118
|
return;
|
|
115
119
|
}
|
|
116
|
-
await k(n,
|
|
120
|
+
await k(n, z.trim()), N("success");
|
|
117
121
|
break;
|
|
118
122
|
case "basic_auth":
|
|
119
|
-
if (!
|
|
120
|
-
|
|
123
|
+
if (!B.trim() || !V.trim()) {
|
|
124
|
+
G("Username and password are required");
|
|
121
125
|
return;
|
|
122
126
|
}
|
|
123
|
-
await A(n,
|
|
127
|
+
await A(n, B.trim(), V.trim()), N("success");
|
|
124
128
|
break;
|
|
125
129
|
case "bearer_token":
|
|
126
|
-
if (!
|
|
127
|
-
|
|
130
|
+
if (!H.trim()) {
|
|
131
|
+
G("Bearer token is required");
|
|
128
132
|
return;
|
|
129
133
|
}
|
|
130
|
-
await j(n,
|
|
134
|
+
await j(n, H.trim()), N("success");
|
|
131
135
|
break;
|
|
132
|
-
default:
|
|
136
|
+
default: N("success");
|
|
133
137
|
}
|
|
134
138
|
} catch (e) {
|
|
135
|
-
|
|
139
|
+
G(e instanceof Error ? e.message : "Authentication failed"), N("error");
|
|
136
140
|
}
|
|
137
141
|
}, [
|
|
138
|
-
|
|
139
|
-
|
|
142
|
+
P,
|
|
143
|
+
I,
|
|
144
|
+
R,
|
|
140
145
|
z,
|
|
141
146
|
B,
|
|
142
147
|
V,
|
|
143
148
|
H,
|
|
144
|
-
U,
|
|
145
149
|
D,
|
|
146
150
|
O,
|
|
147
|
-
|
|
151
|
+
Fe,
|
|
148
152
|
k,
|
|
149
153
|
A,
|
|
150
154
|
j,
|
|
151
155
|
C,
|
|
152
156
|
x,
|
|
153
157
|
S,
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
]),
|
|
158
|
-
if (!x || !
|
|
158
|
+
_,
|
|
159
|
+
K,
|
|
160
|
+
U
|
|
161
|
+
]), $e = a(() => {
|
|
162
|
+
if (!x || !K) return;
|
|
159
163
|
let e = new URL(x, window.location.origin);
|
|
160
|
-
e.searchParams.set("integrationConnectionId",
|
|
164
|
+
e.searchParams.set("integrationConnectionId", K), S && e.searchParams.set("channelId", S), g?.(e.pathname + e.search);
|
|
161
165
|
}, [
|
|
162
166
|
x,
|
|
163
|
-
|
|
167
|
+
K,
|
|
164
168
|
S,
|
|
165
|
-
|
|
166
|
-
]), Z =
|
|
169
|
+
g
|
|
170
|
+
]), Z = Ae || je || Ge || Me || Ne || Pe, et = b ? Ee : E || Je, Q = [
|
|
167
171
|
{
|
|
168
172
|
key: "select_provider",
|
|
169
173
|
label: "Select Provider"
|
|
@@ -176,121 +180,131 @@ function h() {
|
|
|
176
180
|
key: "authenticate",
|
|
177
181
|
label: "Authenticate"
|
|
178
182
|
}
|
|
179
|
-
], $ = Q.findIndex((e) => e.key ===
|
|
180
|
-
return
|
|
183
|
+
], $ = Q.findIndex((e) => e.key === M);
|
|
184
|
+
return Oe ? /* @__PURE__ */ f("div", {
|
|
181
185
|
className: "flex items-center justify-center py-20",
|
|
182
|
-
children: /* @__PURE__ */
|
|
186
|
+
children: /* @__PURE__ */ f(d, {
|
|
183
187
|
size: 48,
|
|
184
188
|
className: "animate-spin text-primary"
|
|
185
189
|
})
|
|
186
|
-
}) :
|
|
190
|
+
}) : ke ? /* @__PURE__ */ p("div", {
|
|
187
191
|
className: "space-y-6 p-6 max-w-3xl mx-auto",
|
|
188
192
|
children: [
|
|
189
|
-
/* @__PURE__ */
|
|
193
|
+
/* @__PURE__ */ p("div", {
|
|
190
194
|
className: "flex items-center gap-4",
|
|
191
195
|
children: [
|
|
192
|
-
/* @__PURE__ */
|
|
196
|
+
/* @__PURE__ */ f("button", {
|
|
193
197
|
type: "button",
|
|
194
|
-
onClick: () =>
|
|
198
|
+
onClick: () => g?.(r(h, "connections")),
|
|
195
199
|
className: "p-2.5 hover:bg-accent rounded-lg transition-all",
|
|
196
200
|
"aria-label": "Back",
|
|
197
|
-
children: /* @__PURE__ */
|
|
201
|
+
children: /* @__PURE__ */ f(pe, { size: 20 })
|
|
198
202
|
}),
|
|
199
|
-
/* @__PURE__ */
|
|
203
|
+
/* @__PURE__ */ f("h1", {
|
|
200
204
|
className: "text-2xl font-bold text-foreground",
|
|
201
205
|
children: "Add Connection"
|
|
202
206
|
}),
|
|
203
|
-
C && /* @__PURE__ */
|
|
207
|
+
C && /* @__PURE__ */ f("span", {
|
|
204
208
|
className: "ml-auto text-xs font-medium px-2.5 py-1 rounded-full bg-primary/10 text-primary",
|
|
205
209
|
children: "Bot Channel Setup"
|
|
206
210
|
})
|
|
207
211
|
]
|
|
208
212
|
}),
|
|
209
|
-
|
|
213
|
+
M !== "success" && M !== "error" && /* @__PURE__ */ f("div", {
|
|
210
214
|
className: "flex items-center gap-2",
|
|
211
|
-
children: Q.map((e, n) => /* @__PURE__ */
|
|
215
|
+
children: Q.map((e, n) => /* @__PURE__ */ p("div", {
|
|
212
216
|
className: "flex items-center gap-2",
|
|
213
217
|
children: [
|
|
214
|
-
/* @__PURE__ */
|
|
218
|
+
/* @__PURE__ */ f("div", {
|
|
215
219
|
className: t("w-8 h-8 rounded-full flex items-center justify-center text-sm font-medium transition-all", n < $ ? "bg-primary text-primary-foreground" : n === $ ? "bg-primary text-primary-foreground ring-4 ring-primary/20" : "bg-muted text-muted-foreground"),
|
|
216
|
-
children: n < $ ? /* @__PURE__ */
|
|
220
|
+
children: n < $ ? /* @__PURE__ */ f(he, { size: 16 }) : n + 1
|
|
217
221
|
}),
|
|
218
|
-
/* @__PURE__ */
|
|
222
|
+
/* @__PURE__ */ f("span", {
|
|
219
223
|
className: t("text-sm font-medium hidden sm:inline", n === $ ? "text-foreground" : "text-muted-foreground"),
|
|
220
224
|
children: e.label
|
|
221
225
|
}),
|
|
222
|
-
n < Q.length - 1 && /* @__PURE__ */
|
|
226
|
+
n < Q.length - 1 && /* @__PURE__ */ f("div", { className: "w-8 h-px bg-border" })
|
|
223
227
|
]
|
|
224
228
|
}, e.key))
|
|
225
229
|
}),
|
|
226
|
-
|
|
230
|
+
W && M !== "error" && /* @__PURE__ */ p("div", {
|
|
227
231
|
className: "rounded-xl border border-border-default bg-status-error-bg-subtle p-4 flex items-center gap-3",
|
|
228
|
-
children: [/* @__PURE__ */
|
|
232
|
+
children: [/* @__PURE__ */ f(u, {
|
|
229
233
|
size: 20,
|
|
230
234
|
className: "text-status-error-text flex-shrink-0"
|
|
231
|
-
}), /* @__PURE__ */
|
|
235
|
+
}), /* @__PURE__ */ f("p", {
|
|
232
236
|
className: "text-sm text-status-error-text",
|
|
233
|
-
children:
|
|
237
|
+
children: W
|
|
234
238
|
})]
|
|
235
239
|
}),
|
|
236
|
-
|
|
240
|
+
M === "configure" && et && !P && /* @__PURE__ */ f("div", {
|
|
237
241
|
className: "flex items-center justify-center py-12",
|
|
238
|
-
children: /* @__PURE__ */
|
|
242
|
+
children: /* @__PURE__ */ f(d, {
|
|
239
243
|
size: 24,
|
|
240
244
|
className: "animate-spin text-muted-foreground"
|
|
241
245
|
})
|
|
242
246
|
}),
|
|
243
|
-
|
|
247
|
+
M === "configure" && !et && !P && (m || b) && /* @__PURE__ */ p("div", {
|
|
248
|
+
className: "flex flex-col items-center justify-center py-12 text-center",
|
|
249
|
+
children: [/* @__PURE__ */ f(u, {
|
|
250
|
+
size: 32,
|
|
251
|
+
className: "text-muted-foreground mb-3"
|
|
252
|
+
}), /* @__PURE__ */ f("p", {
|
|
253
|
+
className: "text-sm text-muted-foreground",
|
|
254
|
+
children: "This provider isn't available."
|
|
255
|
+
})]
|
|
256
|
+
}),
|
|
257
|
+
M === "select_provider" && /* @__PURE__ */ p("div", {
|
|
244
258
|
className: "space-y-4",
|
|
245
259
|
children: [
|
|
246
|
-
/* @__PURE__ */
|
|
260
|
+
/* @__PURE__ */ p("div", {
|
|
247
261
|
className: "relative group",
|
|
248
|
-
children: [/* @__PURE__ */
|
|
262
|
+
children: [/* @__PURE__ */ f(xe, {
|
|
249
263
|
size: 18,
|
|
250
264
|
className: "absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"
|
|
251
|
-
}), /* @__PURE__ */
|
|
265
|
+
}), /* @__PURE__ */ f("input", {
|
|
252
266
|
type: "text",
|
|
253
267
|
placeholder: "Search installed providers...",
|
|
254
268
|
"aria-label": "Search installed providers",
|
|
255
|
-
value:
|
|
256
|
-
onChange: (e) =>
|
|
269
|
+
value: F,
|
|
270
|
+
onChange: (e) => Le(e.target.value),
|
|
257
271
|
className: "w-full pl-10 pr-4 py-2.5 border border-border rounded-lg bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
258
272
|
})]
|
|
259
273
|
}),
|
|
260
|
-
E && /* @__PURE__ */
|
|
274
|
+
E && /* @__PURE__ */ f("div", {
|
|
261
275
|
className: "flex items-center justify-center py-12",
|
|
262
|
-
children: /* @__PURE__ */
|
|
276
|
+
children: /* @__PURE__ */ f(d, {
|
|
263
277
|
size: 24,
|
|
264
278
|
className: "animate-spin text-muted-foreground"
|
|
265
279
|
})
|
|
266
280
|
}),
|
|
267
|
-
!E &&
|
|
281
|
+
!E && Ye.length === 0 && /* @__PURE__ */ p("div", {
|
|
268
282
|
className: "text-center py-12",
|
|
269
|
-
children: [/* @__PURE__ */
|
|
283
|
+
children: [/* @__PURE__ */ f("p", {
|
|
270
284
|
className: "text-muted-foreground",
|
|
271
285
|
children: "No installed providers found. Install a provider from the catalog first."
|
|
272
|
-
}), /* @__PURE__ */
|
|
286
|
+
}), /* @__PURE__ */ f("button", {
|
|
273
287
|
type: "button",
|
|
274
|
-
onClick: () =>
|
|
288
|
+
onClick: () => g?.(r(h, "providers")),
|
|
275
289
|
className: "mt-4 inline-flex items-center gap-2 px-4 py-2 text-sm font-medium rounded-lg bg-primary text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
276
290
|
children: "Browse Catalog"
|
|
277
291
|
})]
|
|
278
292
|
}),
|
|
279
|
-
/* @__PURE__ */
|
|
293
|
+
/* @__PURE__ */ f("div", {
|
|
280
294
|
className: "grid grid-cols-1 sm:grid-cols-2 gap-3",
|
|
281
|
-
children:
|
|
295
|
+
children: Ye.map((e) => /* @__PURE__ */ p("button", {
|
|
282
296
|
type: "button",
|
|
283
|
-
onClick: () =>
|
|
297
|
+
onClick: () => Xe(e),
|
|
284
298
|
className: t("flex items-start gap-3 p-4 rounded-xl border border-border/50 bg-card text-left", "hover:border-primary/50 hover:bg-accent/30 hover:shadow-md transition-all duration-200"),
|
|
285
|
-
children: [/* @__PURE__ */
|
|
299
|
+
children: [/* @__PURE__ */ f(fe, {
|
|
286
300
|
provider: e,
|
|
287
301
|
size: 40
|
|
288
|
-
}), /* @__PURE__ */
|
|
302
|
+
}), /* @__PURE__ */ p("div", {
|
|
289
303
|
className: "flex-1 min-w-0",
|
|
290
|
-
children: [/* @__PURE__ */
|
|
304
|
+
children: [/* @__PURE__ */ f("h3", {
|
|
291
305
|
className: "font-medium text-foreground truncate",
|
|
292
306
|
children: e.name
|
|
293
|
-
}), /* @__PURE__ */
|
|
307
|
+
}), /* @__PURE__ */ p("p", {
|
|
294
308
|
className: "text-xs text-muted-foreground mt-0.5",
|
|
295
309
|
children: [
|
|
296
310
|
ee(e.category),
|
|
@@ -303,283 +317,283 @@ function h() {
|
|
|
303
317
|
})
|
|
304
318
|
]
|
|
305
319
|
}),
|
|
306
|
-
|
|
320
|
+
M === "configure" && P && /* @__PURE__ */ p("div", {
|
|
307
321
|
className: "space-y-6",
|
|
308
322
|
children: [
|
|
309
|
-
/* @__PURE__ */
|
|
323
|
+
/* @__PURE__ */ p("div", {
|
|
310
324
|
className: "flex items-center gap-3 p-4 rounded-xl border border-border/50 bg-card",
|
|
311
|
-
children: [/* @__PURE__ */
|
|
312
|
-
provider:
|
|
325
|
+
children: [/* @__PURE__ */ f(fe, {
|
|
326
|
+
provider: P,
|
|
313
327
|
size: 40
|
|
314
|
-
}), /* @__PURE__ */
|
|
328
|
+
}), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("h3", {
|
|
315
329
|
className: "font-medium text-foreground",
|
|
316
|
-
children:
|
|
317
|
-
}), /* @__PURE__ */
|
|
330
|
+
children: P.name
|
|
331
|
+
}), /* @__PURE__ */ f("p", {
|
|
318
332
|
className: "text-xs text-muted-foreground",
|
|
319
|
-
children: i(
|
|
333
|
+
children: i(P.authType)
|
|
320
334
|
})] })]
|
|
321
335
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
336
|
+
/* @__PURE__ */ p("div", {
|
|
323
337
|
className: "space-y-4",
|
|
324
338
|
children: [
|
|
325
|
-
/* @__PURE__ */
|
|
339
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("label", {
|
|
326
340
|
htmlFor: "conn-name",
|
|
327
341
|
className: "block text-sm font-semibold mb-2",
|
|
328
|
-
children: ["Connection Name ", /* @__PURE__ */
|
|
342
|
+
children: ["Connection Name ", /* @__PURE__ */ f("span", {
|
|
329
343
|
className: "text-status-error-text",
|
|
330
344
|
children: "*"
|
|
331
345
|
})]
|
|
332
|
-
}), /* @__PURE__ */
|
|
346
|
+
}), /* @__PURE__ */ f("input", {
|
|
333
347
|
type: "text",
|
|
334
348
|
id: "conn-name",
|
|
335
349
|
"aria-label": "Connection Name",
|
|
336
|
-
value:
|
|
337
|
-
onChange: (e) =>
|
|
350
|
+
value: I,
|
|
351
|
+
onChange: (e) => L(e.target.value),
|
|
338
352
|
placeholder: "e.g., My Slack Workspace",
|
|
339
353
|
className: "w-full px-4 py-2.5 border border-border rounded-lg bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
340
354
|
})] }),
|
|
341
|
-
/* @__PURE__ */
|
|
355
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
|
|
342
356
|
htmlFor: "conn-desc",
|
|
343
357
|
className: "block text-sm font-semibold mb-2",
|
|
344
358
|
children: "Description"
|
|
345
|
-
}), /* @__PURE__ */
|
|
359
|
+
}), /* @__PURE__ */ f("textarea", {
|
|
346
360
|
id: "conn-desc",
|
|
347
361
|
"aria-label": "Description",
|
|
348
|
-
value:
|
|
349
|
-
onChange: (e) =>
|
|
362
|
+
value: R,
|
|
363
|
+
onChange: (e) => Re(e.target.value),
|
|
350
364
|
rows: 3,
|
|
351
365
|
placeholder: "Optional description...",
|
|
352
366
|
className: "w-full px-4 py-2.5 border border-border rounded-lg bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
353
367
|
})] }),
|
|
354
|
-
/* @__PURE__ */
|
|
355
|
-
value:
|
|
356
|
-
onChange:
|
|
357
|
-
providerAuthType:
|
|
368
|
+
/* @__PURE__ */ f(de, {
|
|
369
|
+
value: U,
|
|
370
|
+
onChange: Ue,
|
|
371
|
+
providerAuthType: P.authType
|
|
358
372
|
})
|
|
359
373
|
]
|
|
360
374
|
}),
|
|
361
|
-
/* @__PURE__ */
|
|
375
|
+
/* @__PURE__ */ p("div", {
|
|
362
376
|
className: "flex gap-3",
|
|
363
|
-
children: [/* @__PURE__ */
|
|
377
|
+
children: [/* @__PURE__ */ f("button", {
|
|
364
378
|
type: "button",
|
|
365
|
-
onClick: () =>
|
|
379
|
+
onClick: () => m || b ? g?.(r(h, "connections")) : N("select_provider"),
|
|
366
380
|
className: "px-4 py-2.5 text-sm font-medium rounded-lg border border-border hover:bg-accent transition-colors",
|
|
367
381
|
children: "Back"
|
|
368
|
-
}), /* @__PURE__ */
|
|
382
|
+
}), /* @__PURE__ */ p("button", {
|
|
369
383
|
type: "button",
|
|
370
|
-
onClick:
|
|
384
|
+
onClick: Ze,
|
|
371
385
|
className: "inline-flex items-center gap-2 px-4 py-2.5 text-sm font-medium rounded-lg bg-primary text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
372
|
-
children: ["Next ", /* @__PURE__ */
|
|
386
|
+
children: ["Next ", /* @__PURE__ */ f(me, { size: 16 })]
|
|
373
387
|
})]
|
|
374
388
|
})
|
|
375
389
|
]
|
|
376
390
|
}),
|
|
377
|
-
|
|
391
|
+
M === "authenticate" && P && /* @__PURE__ */ p("div", {
|
|
378
392
|
className: "space-y-6",
|
|
379
|
-
children: [/* @__PURE__ */
|
|
393
|
+
children: [/* @__PURE__ */ p("div", {
|
|
380
394
|
className: "rounded-xl border border-border/50 bg-card p-5",
|
|
381
395
|
children: [
|
|
382
|
-
/* @__PURE__ */
|
|
396
|
+
/* @__PURE__ */ p("h2", {
|
|
383
397
|
className: "font-semibold text-foreground flex items-center gap-2 mb-4",
|
|
384
398
|
children: [
|
|
385
|
-
/* @__PURE__ */
|
|
399
|
+
/* @__PURE__ */ f(Se, {
|
|
386
400
|
size: 18,
|
|
387
401
|
className: "text-primary"
|
|
388
402
|
}),
|
|
389
403
|
"Authentication: ",
|
|
390
|
-
i(
|
|
404
|
+
i(P.authType)
|
|
391
405
|
]
|
|
392
406
|
}),
|
|
393
|
-
|
|
407
|
+
P.authType === "oauth2" && /* @__PURE__ */ p("div", {
|
|
394
408
|
className: "space-y-4",
|
|
395
|
-
children: [/* @__PURE__ */
|
|
409
|
+
children: [/* @__PURE__ */ p("p", {
|
|
396
410
|
className: "text-sm text-muted-foreground",
|
|
397
411
|
children: [
|
|
398
412
|
"You will be redirected to ",
|
|
399
|
-
|
|
413
|
+
P.name,
|
|
400
414
|
" to authorize access. After granting permission, you'll be redirected back."
|
|
401
415
|
]
|
|
402
|
-
}), /* @__PURE__ */
|
|
416
|
+
}), /* @__PURE__ */ p("div", {
|
|
403
417
|
className: "p-3 rounded-lg bg-status-info-bg-subtle border border-border-default text-sm text-status-info-text flex items-center gap-2",
|
|
404
|
-
children: [/* @__PURE__ */
|
|
418
|
+
children: [/* @__PURE__ */ f(_e, { size: 16 }), C ? "You'll be redirected back to the bot channel setup after authorization." : "A new window will open for OAuth authentication"]
|
|
405
419
|
})]
|
|
406
420
|
}),
|
|
407
|
-
|
|
421
|
+
P.authType === "api_key" && /* @__PURE__ */ p("div", {
|
|
408
422
|
className: "space-y-4",
|
|
409
|
-
children: [/* @__PURE__ */
|
|
423
|
+
children: [/* @__PURE__ */ p("p", {
|
|
410
424
|
className: "text-sm text-muted-foreground",
|
|
411
425
|
children: [
|
|
412
426
|
"Enter your ",
|
|
413
|
-
|
|
427
|
+
P.name,
|
|
414
428
|
" API key. You can typically find this in your account settings."
|
|
415
429
|
]
|
|
416
|
-
}), /* @__PURE__ */
|
|
430
|
+
}), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("label", {
|
|
417
431
|
htmlFor: "api-key",
|
|
418
432
|
className: "block text-sm font-semibold mb-2",
|
|
419
|
-
children: ["API Key ", /* @__PURE__ */
|
|
433
|
+
children: ["API Key ", /* @__PURE__ */ f("span", {
|
|
420
434
|
className: "text-status-error-text",
|
|
421
435
|
children: "*"
|
|
422
436
|
})]
|
|
423
|
-
}), /* @__PURE__ */
|
|
437
|
+
}), /* @__PURE__ */ p("div", {
|
|
424
438
|
className: "relative",
|
|
425
|
-
children: [/* @__PURE__ */
|
|
439
|
+
children: [/* @__PURE__ */ f(ve, {
|
|
426
440
|
size: 16,
|
|
427
441
|
className: "absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"
|
|
428
|
-
}), /* @__PURE__ */
|
|
442
|
+
}), /* @__PURE__ */ f("input", {
|
|
429
443
|
type: "password",
|
|
430
444
|
id: "api-key",
|
|
431
445
|
"aria-label": "API Key",
|
|
432
|
-
value:
|
|
433
|
-
onChange: (e) =>
|
|
446
|
+
value: z,
|
|
447
|
+
onChange: (e) => ze(e.target.value),
|
|
434
448
|
placeholder: "Enter your API key",
|
|
435
449
|
className: "w-full pl-10 pr-4 py-2.5 border border-border rounded-lg bg-background text-sm font-mono focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
436
450
|
})]
|
|
437
451
|
})] })]
|
|
438
452
|
}),
|
|
439
|
-
|
|
453
|
+
P.authType === "basic_auth" && /* @__PURE__ */ p("div", {
|
|
440
454
|
className: "space-y-4",
|
|
441
455
|
children: [
|
|
442
|
-
/* @__PURE__ */
|
|
456
|
+
/* @__PURE__ */ p("p", {
|
|
443
457
|
className: "text-sm text-muted-foreground",
|
|
444
458
|
children: [
|
|
445
459
|
"Enter your ",
|
|
446
|
-
|
|
460
|
+
P.name,
|
|
447
461
|
" credentials."
|
|
448
462
|
]
|
|
449
463
|
}),
|
|
450
|
-
/* @__PURE__ */
|
|
464
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("label", {
|
|
451
465
|
htmlFor: "username",
|
|
452
466
|
className: "block text-sm font-semibold mb-2",
|
|
453
|
-
children: ["Username ", /* @__PURE__ */
|
|
467
|
+
children: ["Username ", /* @__PURE__ */ f("span", {
|
|
454
468
|
className: "text-status-error-text",
|
|
455
469
|
children: "*"
|
|
456
470
|
})]
|
|
457
|
-
}), /* @__PURE__ */
|
|
471
|
+
}), /* @__PURE__ */ f("input", {
|
|
458
472
|
type: "text",
|
|
459
473
|
id: "username",
|
|
460
474
|
"aria-label": "Username",
|
|
461
|
-
value:
|
|
462
|
-
onChange: (e) =>
|
|
475
|
+
value: B,
|
|
476
|
+
onChange: (e) => Be(e.target.value),
|
|
463
477
|
placeholder: "Username or email",
|
|
464
478
|
className: "w-full px-4 py-2.5 border border-border rounded-lg bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
465
479
|
})] }),
|
|
466
|
-
/* @__PURE__ */
|
|
480
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("label", {
|
|
467
481
|
htmlFor: "password",
|
|
468
482
|
className: "block text-sm font-semibold mb-2",
|
|
469
|
-
children: ["Password ", /* @__PURE__ */
|
|
483
|
+
children: ["Password ", /* @__PURE__ */ f("span", {
|
|
470
484
|
className: "text-status-error-text",
|
|
471
485
|
children: "*"
|
|
472
486
|
})]
|
|
473
|
-
}), /* @__PURE__ */
|
|
487
|
+
}), /* @__PURE__ */ p("div", {
|
|
474
488
|
className: "relative",
|
|
475
|
-
children: [/* @__PURE__ */
|
|
489
|
+
children: [/* @__PURE__ */ f(be, {
|
|
476
490
|
size: 16,
|
|
477
491
|
className: "absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"
|
|
478
|
-
}), /* @__PURE__ */
|
|
492
|
+
}), /* @__PURE__ */ f("input", {
|
|
479
493
|
type: "password",
|
|
480
494
|
id: "password",
|
|
481
495
|
"aria-label": "Password",
|
|
482
|
-
value:
|
|
483
|
-
onChange: (e) =>
|
|
496
|
+
value: V,
|
|
497
|
+
onChange: (e) => Ve(e.target.value),
|
|
484
498
|
placeholder: "Password",
|
|
485
499
|
className: "w-full pl-10 pr-4 py-2.5 border border-border rounded-lg bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
486
500
|
})]
|
|
487
501
|
})] })
|
|
488
502
|
]
|
|
489
503
|
}),
|
|
490
|
-
|
|
504
|
+
P.authType === "bearer_token" && /* @__PURE__ */ p("div", {
|
|
491
505
|
className: "space-y-4",
|
|
492
|
-
children: [/* @__PURE__ */
|
|
506
|
+
children: [/* @__PURE__ */ p("p", {
|
|
493
507
|
className: "text-sm text-muted-foreground",
|
|
494
508
|
children: [
|
|
495
509
|
"Enter your ",
|
|
496
|
-
|
|
510
|
+
P.name,
|
|
497
511
|
" bearer token."
|
|
498
512
|
]
|
|
499
|
-
}), /* @__PURE__ */
|
|
513
|
+
}), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("label", {
|
|
500
514
|
htmlFor: "bearer-token",
|
|
501
515
|
className: "block text-sm font-semibold mb-2",
|
|
502
|
-
children: ["Bearer Token ", /* @__PURE__ */
|
|
516
|
+
children: ["Bearer Token ", /* @__PURE__ */ f("span", {
|
|
503
517
|
className: "text-status-error-text",
|
|
504
518
|
children: "*"
|
|
505
519
|
})]
|
|
506
|
-
}), /* @__PURE__ */
|
|
520
|
+
}), /* @__PURE__ */ p("div", {
|
|
507
521
|
className: "relative",
|
|
508
|
-
children: [/* @__PURE__ */
|
|
522
|
+
children: [/* @__PURE__ */ f(ve, {
|
|
509
523
|
size: 16,
|
|
510
524
|
className: "absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"
|
|
511
|
-
}), /* @__PURE__ */
|
|
525
|
+
}), /* @__PURE__ */ f("input", {
|
|
512
526
|
type: "password",
|
|
513
527
|
id: "bearer-token",
|
|
514
528
|
"aria-label": "Bearer Token",
|
|
515
|
-
value:
|
|
516
|
-
onChange: (e) =>
|
|
529
|
+
value: H,
|
|
530
|
+
onChange: (e) => He(e.target.value),
|
|
517
531
|
placeholder: "Enter your token",
|
|
518
532
|
className: "w-full pl-10 pr-4 py-2.5 border border-border rounded-lg bg-background text-sm font-mono focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
|
|
519
533
|
})]
|
|
520
534
|
})] })]
|
|
521
535
|
})
|
|
522
536
|
]
|
|
523
|
-
}), /* @__PURE__ */
|
|
537
|
+
}), /* @__PURE__ */ p("div", {
|
|
524
538
|
className: "flex gap-3",
|
|
525
|
-
children: [/* @__PURE__ */
|
|
539
|
+
children: [/* @__PURE__ */ f("button", {
|
|
526
540
|
type: "button",
|
|
527
|
-
onClick: () =>
|
|
541
|
+
onClick: () => N("configure"),
|
|
528
542
|
disabled: Z,
|
|
529
543
|
className: "px-4 py-2.5 text-sm font-medium rounded-lg border border-border hover:bg-accent transition-colors disabled:opacity-50",
|
|
530
544
|
children: "Back"
|
|
531
|
-
}), /* @__PURE__ */
|
|
545
|
+
}), /* @__PURE__ */ p("button", {
|
|
532
546
|
type: "button",
|
|
533
|
-
onClick:
|
|
547
|
+
onClick: Qe,
|
|
534
548
|
disabled: Z,
|
|
535
549
|
className: "inline-flex items-center gap-2 px-4 py-2.5 text-sm font-medium rounded-lg bg-primary text-primary-foreground hover:bg-primary/90 transition-colors disabled:opacity-50",
|
|
536
|
-
children: [Z ? /* @__PURE__ */
|
|
550
|
+
children: [Z ? /* @__PURE__ */ f(d, {
|
|
537
551
|
size: 16,
|
|
538
552
|
className: "animate-spin"
|
|
539
|
-
}) : /* @__PURE__ */
|
|
553
|
+
}) : /* @__PURE__ */ f(he, { size: 16 }), P.authType === "oauth2" ? "Authorize" : "Connect"]
|
|
540
554
|
})]
|
|
541
555
|
})]
|
|
542
556
|
}),
|
|
543
|
-
|
|
557
|
+
M === "success" && /* @__PURE__ */ p("div", {
|
|
544
558
|
className: "flex flex-col items-center justify-center py-12 text-center",
|
|
545
559
|
children: [
|
|
546
|
-
/* @__PURE__ */
|
|
560
|
+
/* @__PURE__ */ f("div", {
|
|
547
561
|
className: "p-4 rounded-full bg-status-success-bg-subtle mb-4",
|
|
548
|
-
children: /* @__PURE__ */
|
|
562
|
+
children: /* @__PURE__ */ f(ge, {
|
|
549
563
|
size: 48,
|
|
550
564
|
className: "text-status-success-text"
|
|
551
565
|
})
|
|
552
566
|
}),
|
|
553
|
-
/* @__PURE__ */
|
|
567
|
+
/* @__PURE__ */ f("h2", {
|
|
554
568
|
className: "text-xl font-bold text-foreground mb-2",
|
|
555
569
|
children: "Connection Created!"
|
|
556
570
|
}),
|
|
557
|
-
/* @__PURE__ */
|
|
571
|
+
/* @__PURE__ */ p("p", {
|
|
558
572
|
className: "text-sm text-muted-foreground mb-6 max-w-sm",
|
|
559
573
|
children: [
|
|
560
574
|
"Your ",
|
|
561
|
-
|
|
575
|
+
P?.name,
|
|
562
576
|
" connection has been set up successfully."
|
|
563
577
|
]
|
|
564
578
|
}),
|
|
565
|
-
/* @__PURE__ */
|
|
579
|
+
/* @__PURE__ */ p("div", {
|
|
566
580
|
className: "flex gap-3",
|
|
567
581
|
children: [
|
|
568
|
-
C &&
|
|
582
|
+
C && K && /* @__PURE__ */ p("button", {
|
|
569
583
|
type: "button",
|
|
570
|
-
onClick:
|
|
584
|
+
onClick: $e,
|
|
571
585
|
className: "inline-flex items-center gap-2 px-4 py-2.5 text-sm font-medium rounded-lg bg-primary text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
572
|
-
children: [/* @__PURE__ */
|
|
586
|
+
children: [/* @__PURE__ */ f(ye, { size: 16 }), "Link to Bot Channel"]
|
|
573
587
|
}),
|
|
574
|
-
!C &&
|
|
588
|
+
!C && K && /* @__PURE__ */ f("button", {
|
|
575
589
|
type: "button",
|
|
576
|
-
onClick: () =>
|
|
590
|
+
onClick: () => g?.(r(h, `connections/${K}`)),
|
|
577
591
|
className: "inline-flex items-center gap-2 px-4 py-2.5 text-sm font-medium rounded-lg bg-primary text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
578
592
|
children: "View Connection"
|
|
579
593
|
}),
|
|
580
|
-
/* @__PURE__ */
|
|
594
|
+
/* @__PURE__ */ f("button", {
|
|
581
595
|
type: "button",
|
|
582
|
-
onClick: () =>
|
|
596
|
+
onClick: () => g?.(r(h, "connections")),
|
|
583
597
|
className: "px-4 py-2.5 text-sm font-medium rounded-lg border border-border hover:bg-accent transition-colors",
|
|
584
598
|
children: "All Connections"
|
|
585
599
|
})
|
|
@@ -587,36 +601,36 @@ function h() {
|
|
|
587
601
|
})
|
|
588
602
|
]
|
|
589
603
|
}),
|
|
590
|
-
|
|
604
|
+
M === "error" && /* @__PURE__ */ p("div", {
|
|
591
605
|
className: "flex flex-col items-center justify-center py-12 text-center",
|
|
592
606
|
children: [
|
|
593
|
-
/* @__PURE__ */
|
|
607
|
+
/* @__PURE__ */ f("div", {
|
|
594
608
|
className: "p-4 rounded-full bg-status-error-bg-subtle mb-4",
|
|
595
|
-
children: /* @__PURE__ */
|
|
609
|
+
children: /* @__PURE__ */ f(u, {
|
|
596
610
|
size: 48,
|
|
597
611
|
className: "text-status-error-text"
|
|
598
612
|
})
|
|
599
613
|
}),
|
|
600
|
-
/* @__PURE__ */
|
|
614
|
+
/* @__PURE__ */ f("h2", {
|
|
601
615
|
className: "text-xl font-bold text-foreground mb-2",
|
|
602
616
|
children: "Connection Failed"
|
|
603
617
|
}),
|
|
604
|
-
/* @__PURE__ */
|
|
618
|
+
/* @__PURE__ */ f("p", {
|
|
605
619
|
className: "text-sm text-status-error-text mb-6 max-w-sm",
|
|
606
|
-
children:
|
|
620
|
+
children: W || "An unexpected error occurred."
|
|
607
621
|
}),
|
|
608
|
-
/* @__PURE__ */
|
|
622
|
+
/* @__PURE__ */ p("div", {
|
|
609
623
|
className: "flex gap-3",
|
|
610
|
-
children: [/* @__PURE__ */
|
|
624
|
+
children: [/* @__PURE__ */ f("button", {
|
|
611
625
|
type: "button",
|
|
612
626
|
onClick: () => {
|
|
613
|
-
|
|
627
|
+
G(""), N("authenticate");
|
|
614
628
|
},
|
|
615
629
|
className: "inline-flex items-center gap-2 px-4 py-2.5 text-sm font-medium rounded-lg bg-primary text-primary-foreground hover:bg-primary/90 transition-colors",
|
|
616
630
|
children: "Try Again"
|
|
617
|
-
}), /* @__PURE__ */
|
|
631
|
+
}), /* @__PURE__ */ f("button", {
|
|
618
632
|
type: "button",
|
|
619
|
-
onClick: () =>
|
|
633
|
+
onClick: () => g?.(r(h, "connections")),
|
|
620
634
|
className: "px-4 py-2.5 text-sm font-medium rounded-lg border border-border hover:bg-accent transition-colors",
|
|
621
635
|
children: "Cancel"
|
|
622
636
|
})]
|
|
@@ -624,31 +638,31 @@ function h() {
|
|
|
624
638
|
]
|
|
625
639
|
})
|
|
626
640
|
]
|
|
627
|
-
}) : /* @__PURE__ */
|
|
641
|
+
}) : /* @__PURE__ */ p("div", {
|
|
628
642
|
className: "flex flex-col items-center justify-center py-20 text-center p-6",
|
|
629
643
|
children: [
|
|
630
|
-
/* @__PURE__ */
|
|
644
|
+
/* @__PURE__ */ f(Se, {
|
|
631
645
|
size: 48,
|
|
632
646
|
className: "text-muted-foreground mb-4"
|
|
633
647
|
}),
|
|
634
|
-
/* @__PURE__ */
|
|
648
|
+
/* @__PURE__ */ f("h2", {
|
|
635
649
|
className: "text-xl font-bold text-foreground mb-2",
|
|
636
650
|
children: "Access Denied"
|
|
637
651
|
}),
|
|
638
|
-
/* @__PURE__ */
|
|
652
|
+
/* @__PURE__ */ f("p", {
|
|
639
653
|
className: "text-sm text-muted-foreground mb-6 max-w-sm",
|
|
640
654
|
children: "You don't have permission to create connections."
|
|
641
655
|
}),
|
|
642
|
-
/* @__PURE__ */
|
|
656
|
+
/* @__PURE__ */ p("button", {
|
|
643
657
|
type: "button",
|
|
644
|
-
onClick: () =>
|
|
658
|
+
onClick: () => g?.(r(h, "connections")),
|
|
645
659
|
className: "inline-flex items-center gap-2 px-4 py-2.5 text-sm font-medium rounded-lg border border-border hover:bg-accent transition-colors",
|
|
646
|
-
children: [/* @__PURE__ */
|
|
660
|
+
children: [/* @__PURE__ */ f(pe, { size: 16 }), " Back to Connections"]
|
|
647
661
|
})
|
|
648
662
|
]
|
|
649
663
|
});
|
|
650
664
|
}
|
|
651
665
|
//#endregion
|
|
652
|
-
export {
|
|
666
|
+
export { m as AddConnectionWizard };
|
|
653
667
|
|
|
654
668
|
//# sourceMappingURL=AddConnectionWizard.js.map
|