@burdenoff/microfe-integrations 2026.828.1 → 2026.830.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/dist/integrations/components/AddConnectionDialog.d.ts.map +1 -1
  2. package/dist/integrations/components/AddConnectionDialog.js +151 -152
  3. package/dist/integrations/components/AddConnectionDialog.js.map +1 -1
  4. package/dist/integrations/components/AuthMethodSelector.d.ts.map +1 -1
  5. package/dist/integrations/components/AuthMethodSelector.js +48 -40
  6. package/dist/integrations/components/AuthMethodSelector.js.map +1 -1
  7. package/dist/integrations/components/AuthMethodsEditor.d.ts.map +1 -1
  8. package/dist/integrations/components/AuthMethodsEditor.js +207 -190
  9. package/dist/integrations/components/AuthMethodsEditor.js.map +1 -1
  10. package/dist/integrations/components/ConnectionCard.d.ts.map +1 -1
  11. package/dist/integrations/components/ConnectionCard.js +102 -98
  12. package/dist/integrations/components/ConnectionCard.js.map +1 -1
  13. package/dist/integrations/components/ConnectionStatusBadge.d.ts.map +1 -1
  14. package/dist/integrations/components/ConnectionStatusBadge.js +9 -5
  15. package/dist/integrations/components/ConnectionStatusBadge.js.map +1 -1
  16. package/dist/integrations/components/CredentialStorageSelector.d.ts.map +1 -1
  17. package/dist/integrations/components/CredentialStorageSelector.js +124 -121
  18. package/dist/integrations/components/CredentialStorageSelector.js.map +1 -1
  19. package/dist/integrations/components/ProviderCard.d.ts.map +1 -1
  20. package/dist/integrations/components/ProviderCard.js +25 -65
  21. package/dist/integrations/components/ProviderCard.js.map +1 -1
  22. package/dist/integrations/components/SchemaForm.d.ts.map +1 -1
  23. package/dist/integrations/components/SchemaForm.js +116 -111
  24. package/dist/integrations/components/SchemaForm.js.map +1 -1
  25. package/dist/integrations/hooks/useFormatDate.d.ts +7 -0
  26. package/dist/integrations/hooks/useFormatDate.d.ts.map +1 -0
  27. package/dist/integrations/hooks/useFormatDate.js +17 -0
  28. package/dist/integrations/hooks/useFormatDate.js.map +1 -0
  29. package/dist/integrations/hooks/useFormatLastUsed.d.ts +9 -0
  30. package/dist/integrations/hooks/useFormatLastUsed.d.ts.map +1 -0
  31. package/dist/integrations/hooks/useFormatLastUsed.js +15 -0
  32. package/dist/integrations/hooks/useFormatLastUsed.js.map +1 -0
  33. package/dist/integrations/hooks/useLabel.d.ts +13 -0
  34. package/dist/integrations/hooks/useLabel.d.ts.map +1 -0
  35. package/dist/integrations/hooks/useLabel.js +20 -0
  36. package/dist/integrations/hooks/useLabel.js.map +1 -0
  37. package/dist/integrations/hooks/useTr.d.ts +17 -0
  38. package/dist/integrations/hooks/useTr.d.ts.map +1 -0
  39. package/dist/integrations/hooks/useTr.js +14 -0
  40. package/dist/integrations/hooks/useTr.js.map +1 -0
  41. package/dist/integrations/pages/AddConnectionWizard.d.ts.map +1 -1
  42. package/dist/integrations/pages/AddConnectionWizard.js +396 -387
  43. package/dist/integrations/pages/AddConnectionWizard.js.map +1 -1
  44. package/dist/integrations/pages/ConnectionDetail.d.ts.map +1 -1
  45. package/dist/integrations/pages/ConnectionDetail.js +128 -128
  46. package/dist/integrations/pages/ConnectionDetail.js.map +1 -1
  47. package/dist/integrations/pages/ConnectionLogs.d.ts.map +1 -1
  48. package/dist/integrations/pages/ConnectionLogs.js +210 -181
  49. package/dist/integrations/pages/ConnectionLogs.js.map +1 -1
  50. package/dist/integrations/pages/ConnectionsList.d.ts.map +1 -1
  51. package/dist/integrations/pages/ConnectionsList.js +136 -115
  52. package/dist/integrations/pages/ConnectionsList.js.map +1 -1
  53. package/dist/integrations/pages/IntegrationsOverview.d.ts.map +1 -1
  54. package/dist/integrations/pages/IntegrationsOverview.js +76 -77
  55. package/dist/integrations/pages/IntegrationsOverview.js.map +1 -1
  56. package/dist/integrations/pages/IntegrationsSettings.d.ts.map +1 -1
  57. package/dist/integrations/pages/IntegrationsSettings.js +59 -61
  58. package/dist/integrations/pages/IntegrationsSettings.js.map +1 -1
  59. package/dist/integrations/pages/IntegrationsUserLandingPage.d.ts.map +1 -1
  60. package/dist/integrations/pages/IntegrationsUserLandingPage.js +29 -28
  61. package/dist/integrations/pages/IntegrationsUserLandingPage.js.map +1 -1
  62. package/dist/integrations/pages/ProviderCatalog.d.ts.map +1 -1
  63. package/dist/integrations/pages/ProviderCatalog.js +99 -141
  64. package/dist/integrations/pages/ProviderCatalog.js.map +1 -1
  65. package/dist/integrations/pages/ProviderDetail.d.ts.map +1 -1
  66. package/dist/integrations/pages/ProviderDetail.js +208 -220
  67. package/dist/integrations/pages/ProviderDetail.js.map +1 -1
  68. package/dist/integrations/pages/ProviderEditorPage.d.ts.map +1 -1
  69. package/dist/integrations/pages/ProviderEditorPage.js +262 -261
  70. package/dist/integrations/pages/ProviderEditorPage.js.map +1 -1
  71. package/dist/integrations/translations/en.d.ts +731 -0
  72. package/dist/integrations/translations/en.d.ts.map +1 -0
  73. package/dist/integrations/utils/integrationsHelpers.js +2 -16
  74. package/dist/integrations/utils/integrationsHelpers.js.map +1 -1
  75. package/package.json +1 -1
@@ -1,16 +1,17 @@
1
1
  import { useIntegrations as e } from "../providers/IntegrationsProvider.js";
2
- import { INTEGRATION_PERMISSIONS as t } from "../constants/permissions.js";
3
- import { joinPath as n } from "../utils/navigation.js";
4
- import { useInstallPlugin as r, useProvider as i, useUpdatePlugin as a } from "../hooks/useProviders.js";
5
- import { AuthMethodsEditor as o } from "../components/AuthMethodsEditor.js";
6
- import { useEffect as s, useId as c, useState as l } from "react";
7
- import { ArrowLeft as u, Loader2 as d, Save as f, Shield as p } from "lucide-react";
8
- import { useParams as m } from "react-router";
9
- import { usePermissions as h } from "@burdenoff/fe-libs/shared/providers/shell";
10
- import { jsx as g, jsxs as _ } from "react/jsx-runtime";
11
- import { Button as v, EmphasisPanel as y, GlassCard as b, OptionalFields as x, PagePurpose as S } from "@burdenoff/fe-libs/ui";
2
+ import { useTr as t } from "../hooks/useTr.js";
3
+ import { INTEGRATION_PERMISSIONS as n } from "../constants/permissions.js";
4
+ import { joinPath as r } from "../utils/navigation.js";
5
+ import { useInstallPlugin as i, useProvider as a, useUpdatePlugin as o } from "../hooks/useProviders.js";
6
+ import { AuthMethodsEditor as s } from "../components/AuthMethodsEditor.js";
7
+ import { useEffect as c, useId as l, useState as u } from "react";
8
+ import { ArrowLeft as d, Loader2 as f, Save as p, Shield as m } from "lucide-react";
9
+ import { useParams as h } from "react-router";
10
+ import { usePermissions as g } from "@burdenoff/fe-libs/shared/providers/shell";
11
+ import { jsx as _, jsxs as v } from "react/jsx-runtime";
12
+ import { Button as y, EmphasisPanel as b, GlassCard as x, OptionalFields as S, PagePurpose as C } from "@burdenoff/fe-libs/ui";
12
13
  //#region src/integrations/pages/ProviderEditorPage.tsx
13
- var C = [
14
+ var w = [
14
15
  "COMMUNICATION",
15
16
  "PRODUCTIVITY",
16
17
  "CLOUD_STORAGE",
@@ -22,7 +23,7 @@ var C = [
22
23
  "PAYMENT",
23
24
  "ANALYTICS",
24
25
  "CUSTOM"
25
- ], w = [
26
+ ], T = [
26
27
  "OAUTH2",
27
28
  "API_KEY",
28
29
  "BASIC_AUTH",
@@ -30,7 +31,7 @@ var C = [
30
31
  "SERVICE_ACCOUNT",
31
32
  "CUSTOM"
32
33
  ];
33
- function T(e, t) {
34
+ function E(e, t) {
34
35
  let n = e.trim();
35
36
  if (n) try {
36
37
  return JSON.parse(n);
@@ -38,7 +39,7 @@ function T(e, t) {
38
39
  throw Error(`${t} must be valid JSON`);
39
40
  }
40
41
  }
41
- function E(e) {
42
+ function D(e) {
42
43
  return {
43
44
  communication: "COMMUNICATION",
44
45
  productivity: "PRODUCTIVITY",
@@ -53,7 +54,7 @@ function E(e) {
53
54
  other: "CUSTOM"
54
55
  }[e || ""] || "CUSTOM";
55
56
  }
56
- function D(e) {
57
+ function O(e) {
57
58
  return {
58
59
  oauth2: "OAUTH2",
59
60
  api_key: "API_KEY",
@@ -62,8 +63,8 @@ function D(e) {
62
63
  service_account: "SERVICE_ACCOUNT"
63
64
  }[e || ""] || "CUSTOM";
64
65
  }
65
- function O() {
66
- let { providerId: O } = m(), k = !!O, { basePath: A = "/", navigate: j } = e(), { hasPermission: M, isLoading: N } = h(), P = M(t.PROVIDER_CREATE), F = M(t.PROVIDER_UPDATE), { provider: I, loading: L } = i(O ?? ""), { installPlugin: R, loading: z } = r(), { updatePlugin: B, loading: V } = a(), [H, U] = l(""), [W, G] = l({
66
+ function k() {
67
+ let { providerId: k } = h(), A = !!k, { basePath: j = "/", navigate: M } = e(), N = t(), { hasPermission: P, isLoading: F } = g(), I = P(n.PROVIDER_CREATE), L = P(n.PROVIDER_UPDATE), { provider: R, loading: z } = a(k ?? ""), { installPlugin: B, loading: V } = i(), { updatePlugin: H, loading: U } = o(), [W, G] = u(""), [K, q] = u({
67
68
  key: "",
68
69
  name: "",
69
70
  description: "",
@@ -87,397 +88,397 @@ function O() {
87
88
  configSchema: "",
88
89
  isEnabled: !0
89
90
  });
90
- s(() => {
91
- !I || !k || G({
92
- key: I.key,
93
- name: I.name,
94
- description: I.description || "",
95
- category: E(I.category),
96
- authType: D(I.authType),
97
- icon: I.icon || "",
98
- color: I.color || "",
99
- website: I.website || "",
100
- docsUrl: I.docsUrl || "",
101
- baseUrl: I.baseUrl || "",
102
- apiVersion: I.apiVersion || "",
103
- pluginVersion: I.pluginVersion || "1.0.0",
104
- pluginAuthor: I.pluginAuthor || "",
105
- pluginRepository: I.pluginRepository || "",
106
- displayOrder: String(I.displayOrder || 0),
107
- defaultScopes: (I.defaultScopes || []).join(", "),
108
- supportedFeatures: (I.supportedFeatures || []).join(", "),
109
- oauthConfig: I.oauthConfig ? JSON.stringify(I.oauthConfig, null, 2) : "",
110
- availableScopes: I.availableScopes ? JSON.stringify(I.availableScopes, null, 2) : "",
111
- rateLimitConfig: I.rateLimitConfig ? JSON.stringify(I.rateLimitConfig, null, 2) : "",
112
- configSchema: I.configSchema ? JSON.stringify(I.configSchema, null, 2) : "",
113
- isEnabled: I.isEnabled
91
+ c(() => {
92
+ !R || !A || q({
93
+ key: R.key,
94
+ name: R.name,
95
+ description: R.description || "",
96
+ category: D(R.category),
97
+ authType: O(R.authType),
98
+ icon: R.icon || "",
99
+ color: R.color || "",
100
+ website: R.website || "",
101
+ docsUrl: R.docsUrl || "",
102
+ baseUrl: R.baseUrl || "",
103
+ apiVersion: R.apiVersion || "",
104
+ pluginVersion: R.pluginVersion || "1.0.0",
105
+ pluginAuthor: R.pluginAuthor || "",
106
+ pluginRepository: R.pluginRepository || "",
107
+ displayOrder: String(R.displayOrder || 0),
108
+ defaultScopes: (R.defaultScopes || []).join(", "),
109
+ supportedFeatures: (R.supportedFeatures || []).join(", "),
110
+ oauthConfig: R.oauthConfig ? JSON.stringify(R.oauthConfig, null, 2) : "",
111
+ availableScopes: R.availableScopes ? JSON.stringify(R.availableScopes, null, 2) : "",
112
+ rateLimitConfig: R.rateLimitConfig ? JSON.stringify(R.rateLimitConfig, null, 2) : "",
113
+ configSchema: R.configSchema ? JSON.stringify(R.configSchema, null, 2) : "",
114
+ isEnabled: R.isEnabled
114
115
  });
115
- }, [k, I]);
116
- let K = k ? F : P, q = c(), J = (e) => `${q}-${e}`, Y = (e, t) => {
117
- G((n) => ({
116
+ }, [A, R]);
117
+ let J = A ? L : I, Y = l(), X = (e) => `${Y}-${e}`, Z = (e, t) => {
118
+ q((n) => ({
118
119
  ...n,
119
120
  [e]: t
120
121
  }));
121
122
  };
122
- return N || k && L ? /* @__PURE__ */ g("div", {
123
+ return F || A && z ? /* @__PURE__ */ _("div", {
123
124
  className: "flex items-center justify-center py-20",
124
- children: /* @__PURE__ */ g(d, {
125
+ children: /* @__PURE__ */ _(f, {
125
126
  size: 44,
126
127
  className: "animate-spin text-primary"
127
128
  })
128
- }) : K ? /* @__PURE__ */ _("div", {
129
+ }) : J ? /* @__PURE__ */ v("div", {
129
130
  className: "space-y-6 p-6 max-w-5xl mx-auto",
130
131
  children: [
131
- /* @__PURE__ */ _("div", {
132
+ /* @__PURE__ */ v("div", {
132
133
  className: "rounded-xl border border-border-seam bg-accent-wash p-6 flex items-center gap-4",
133
- children: [/* @__PURE__ */ g(v, {
134
+ children: [/* @__PURE__ */ _(y, {
134
135
  variant: "ghost",
135
136
  size: "icon",
136
- onClick: () => j?.(n(A, "providers")),
137
- "aria-label": "Back to providers",
138
- children: /* @__PURE__ */ g(u, { size: 20 })
139
- }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("h1", {
137
+ onClick: () => M?.(r(j, "providers")),
138
+ "aria-label": N("integrations.common.back", "Back"),
139
+ children: /* @__PURE__ */ _(d, { size: 20 })
140
+ }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("h1", {
140
141
  className: "text-2xl font-bold text-text-primary",
141
- children: k ? "Edit Provider" : "Add Provider"
142
- }), /* @__PURE__ */ g("p", {
142
+ children: A ? N("integrations.providerEditor.editTitle", "Edit Provider") : N("integrations.providerEditor.addTitle", "Add Provider")
143
+ }), /* @__PURE__ */ _("p", {
143
144
  className: "text-sm text-text-secondary mt-1",
144
- children: "Configure catalog metadata, auth configuration, and runtime settings."
145
+ children: N("integrations.providerEditor.subtitle", "Configure catalog metadata, auth configuration, and runtime settings.")
145
146
  })] })]
146
147
  }),
147
- /* @__PURE__ */ g(S, {
148
- icon: /* @__PURE__ */ g(p, { size: 16 }),
149
- children: "Providers are the building blocks of integrations: each one tells the platform how to authenticate with and call an external service. Use this form to register a new provider (or edit an existing one) — set its identity and category, choose how it authenticates, and optionally supply advanced OAuth, scope, and rate-limit configuration. Once saved and enabled, anyone in the workspace can create connections to it."
148
+ /* @__PURE__ */ _(C, {
149
+ icon: /* @__PURE__ */ _(m, { size: 16 }),
150
+ children: N("integrations.providerEditor.purpose", "Providers are the building blocks of integrations: each one tells the platform how to authenticate with and call an external service. Use this form to register a new provider (or edit an existing one) — set its identity and category, choose how it authenticates, and optionally supply advanced OAuth, scope, and rate-limit configuration. Once saved and enabled, anyone in the workspace can create connections to it.")
150
151
  }),
151
- H && /* @__PURE__ */ g("div", {
152
+ W && /* @__PURE__ */ _("div", {
152
153
  className: "rounded-xl border border-border-seam bg-status-error-bg-subtle px-4 py-3 text-sm text-status-error-text",
153
- children: H
154
+ children: W
154
155
  }),
155
- /* @__PURE__ */ _("div", {
156
+ /* @__PURE__ */ v("div", {
156
157
  className: "grid grid-cols-1 lg:grid-cols-2 gap-4",
157
158
  children: [
158
- /* @__PURE__ */ _(y, {
159
+ /* @__PURE__ */ v(b, {
159
160
  className: "p-5 space-y-4",
160
161
  children: [
161
- /* @__PURE__ */ g("h2", {
162
+ /* @__PURE__ */ _("h2", {
162
163
  className: "font-semibold text-text-primary",
163
- children: "Core details"
164
+ children: N("integrations.providerEditor.sections.coreDetails", "Core details")
164
165
  }),
165
- !k && /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
166
- htmlFor: J("key"),
166
+ !A && /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
167
+ htmlFor: X("key"),
167
168
  className: "block text-sm font-medium mb-1.5 text-text-primary",
168
- children: "Key"
169
- }), /* @__PURE__ */ g("input", {
170
- id: J("key"),
171
- "aria-label": "Key",
172
- value: W.key,
173
- onChange: (e) => Y("key", e.target.value),
169
+ children: N("integrations.providerEditor.fields.key", "Key")
170
+ }), /* @__PURE__ */ _("input", {
171
+ id: X("key"),
172
+ "aria-label": N("integrations.providerEditor.fields.key", "Key"),
173
+ value: K.key,
174
+ onChange: (e) => Z("key", e.target.value),
174
175
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm",
175
- placeholder: "e.g. slack-user"
176
+ placeholder: N("integrations.providerEditor.fields.keyPlaceholder", "e.g. slack-user")
176
177
  })] }),
177
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
178
- htmlFor: J("name"),
178
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
179
+ htmlFor: X("name"),
179
180
  className: "block text-sm font-medium mb-1.5 text-text-primary",
180
- children: "Name"
181
- }), /* @__PURE__ */ g("input", {
182
- id: J("name"),
183
- "aria-label": "Name",
184
- value: W.name,
185
- onChange: (e) => Y("name", e.target.value),
181
+ children: N("integrations.providerEditor.fields.name", "Name")
182
+ }), /* @__PURE__ */ _("input", {
183
+ id: X("name"),
184
+ "aria-label": N("integrations.providerEditor.fields.name", "Name"),
185
+ value: K.name,
186
+ onChange: (e) => Z("name", e.target.value),
186
187
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
187
188
  })] }),
188
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
189
- htmlFor: J("description"),
189
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
190
+ htmlFor: X("description"),
190
191
  className: "block text-sm font-medium mb-1.5 text-text-primary",
191
- children: "Description"
192
- }), /* @__PURE__ */ g("textarea", {
193
- id: J("description"),
194
- "aria-label": "Description",
195
- value: W.description,
196
- onChange: (e) => Y("description", e.target.value),
192
+ children: N("integrations.providerEditor.fields.description", "Description")
193
+ }), /* @__PURE__ */ _("textarea", {
194
+ id: X("description"),
195
+ "aria-label": N("integrations.providerEditor.fields.description", "Description"),
196
+ value: K.description,
197
+ onChange: (e) => Z("description", e.target.value),
197
198
  rows: 4,
198
199
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
199
200
  })] }),
200
- /* @__PURE__ */ _("div", {
201
+ /* @__PURE__ */ v("div", {
201
202
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
202
- children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
203
- htmlFor: J("category"),
203
+ children: [/* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
204
+ htmlFor: X("category"),
204
205
  className: "block text-sm font-medium mb-1.5 text-text-primary",
205
- children: "Category"
206
- }), /* @__PURE__ */ g("select", {
207
- id: J("category"),
208
- "aria-label": "Category",
209
- value: W.category,
210
- onChange: (e) => Y("category", e.target.value),
206
+ children: N("integrations.providerEditor.fields.category", "Category")
207
+ }), /* @__PURE__ */ _("select", {
208
+ id: X("category"),
209
+ "aria-label": N("integrations.providerEditor.fields.category", "Category"),
210
+ value: K.category,
211
+ onChange: (e) => Z("category", e.target.value),
211
212
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm",
212
- children: C.map((e) => /* @__PURE__ */ g("option", {
213
+ children: w.map((e) => /* @__PURE__ */ _("option", {
213
214
  value: e,
214
215
  children: e
215
216
  }, e))
216
- })] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
217
- htmlFor: J("authType"),
217
+ })] }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
218
+ htmlFor: X("authType"),
218
219
  className: "block text-sm font-medium mb-1.5 text-text-primary",
219
- children: "Auth Type"
220
- }), /* @__PURE__ */ g("select", {
221
- id: J("authType"),
222
- "aria-label": "Auth Type",
223
- value: W.authType,
224
- onChange: (e) => Y("authType", e.target.value),
220
+ children: N("integrations.providerEditor.fields.authType", "Auth Type")
221
+ }), /* @__PURE__ */ _("select", {
222
+ id: X("authType"),
223
+ "aria-label": N("integrations.providerEditor.fields.authType", "Auth Type"),
224
+ value: K.authType,
225
+ onChange: (e) => Z("authType", e.target.value),
225
226
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm",
226
- children: w.map((e) => /* @__PURE__ */ g("option", {
227
+ children: T.map((e) => /* @__PURE__ */ _("option", {
227
228
  value: e,
228
229
  children: e
229
230
  }, e))
230
231
  })] })]
231
232
  }),
232
- /* @__PURE__ */ _("div", {
233
+ /* @__PURE__ */ v("div", {
233
234
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
234
- children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
235
- htmlFor: J("website"),
235
+ children: [/* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
236
+ htmlFor: X("website"),
236
237
  className: "block text-sm font-medium mb-1.5 text-text-primary",
237
- children: "Website"
238
- }), /* @__PURE__ */ g("input", {
239
- id: J("website"),
240
- "aria-label": "Website",
241
- value: W.website,
242
- onChange: (e) => Y("website", e.target.value),
238
+ children: N("integrations.providerEditor.fields.website", "Website")
239
+ }), /* @__PURE__ */ _("input", {
240
+ id: X("website"),
241
+ "aria-label": N("integrations.providerEditor.fields.website", "Website"),
242
+ value: K.website,
243
+ onChange: (e) => Z("website", e.target.value),
243
244
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
244
- })] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
245
- htmlFor: J("docsUrl"),
245
+ })] }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
246
+ htmlFor: X("docsUrl"),
246
247
  className: "block text-sm font-medium mb-1.5 text-text-primary",
247
- children: "Docs URL"
248
- }), /* @__PURE__ */ g("input", {
249
- id: J("docsUrl"),
250
- "aria-label": "Docs URL",
251
- value: W.docsUrl,
252
- onChange: (e) => Y("docsUrl", e.target.value),
248
+ children: N("integrations.providerEditor.fields.docsUrl", "Docs URL")
249
+ }), /* @__PURE__ */ _("input", {
250
+ id: X("docsUrl"),
251
+ "aria-label": N("integrations.providerEditor.fields.docsUrl", "Docs URL"),
252
+ value: K.docsUrl,
253
+ onChange: (e) => Z("docsUrl", e.target.value),
253
254
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
254
255
  })] })]
255
256
  }),
256
- /* @__PURE__ */ _("div", {
257
+ /* @__PURE__ */ v("div", {
257
258
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
258
- children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
259
- htmlFor: J("pluginVersion"),
259
+ children: [/* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
260
+ htmlFor: X("pluginVersion"),
260
261
  className: "block text-sm font-medium mb-1.5 text-text-primary",
261
- children: "Plugin version"
262
- }), /* @__PURE__ */ g("input", {
263
- id: J("pluginVersion"),
264
- "aria-label": "Plugin version",
265
- value: W.pluginVersion,
266
- onChange: (e) => Y("pluginVersion", e.target.value),
262
+ children: N("integrations.providerEditor.fields.pluginVersion", "Plugin version")
263
+ }), /* @__PURE__ */ _("input", {
264
+ id: X("pluginVersion"),
265
+ "aria-label": N("integrations.providerEditor.fields.pluginVersion", "Plugin version"),
266
+ value: K.pluginVersion,
267
+ onChange: (e) => Z("pluginVersion", e.target.value),
267
268
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
268
- })] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
269
- htmlFor: J("displayOrder"),
269
+ })] }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
270
+ htmlFor: X("displayOrder"),
270
271
  className: "block text-sm font-medium mb-1.5 text-text-primary",
271
- children: "Display order"
272
- }), /* @__PURE__ */ g("input", {
273
- id: J("displayOrder"),
274
- "aria-label": "Display order",
272
+ children: N("integrations.providerEditor.fields.displayOrder", "Display order")
273
+ }), /* @__PURE__ */ _("input", {
274
+ id: X("displayOrder"),
275
+ "aria-label": N("integrations.providerEditor.fields.displayOrder", "Display order"),
275
276
  type: "number",
276
- value: W.displayOrder,
277
- onChange: (e) => Y("displayOrder", e.target.value),
277
+ value: K.displayOrder,
278
+ onChange: (e) => Z("displayOrder", e.target.value),
278
279
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
279
280
  })] })]
280
281
  }),
281
- /* @__PURE__ */ _("div", {
282
+ /* @__PURE__ */ v("div", {
282
283
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
283
- children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
284
- htmlFor: J("pluginAuthor"),
284
+ children: [/* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
285
+ htmlFor: X("pluginAuthor"),
285
286
  className: "block text-sm font-medium mb-1.5 text-text-primary",
286
- children: "Plugin author"
287
- }), /* @__PURE__ */ g("input", {
288
- id: J("pluginAuthor"),
289
- "aria-label": "Plugin author",
290
- value: W.pluginAuthor,
291
- onChange: (e) => Y("pluginAuthor", e.target.value),
287
+ children: N("integrations.providerEditor.fields.pluginAuthor", "Plugin author")
288
+ }), /* @__PURE__ */ _("input", {
289
+ id: X("pluginAuthor"),
290
+ "aria-label": N("integrations.providerEditor.fields.pluginAuthor", "Plugin author"),
291
+ value: K.pluginAuthor,
292
+ onChange: (e) => Z("pluginAuthor", e.target.value),
292
293
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
293
- })] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
294
- htmlFor: J("pluginRepository"),
294
+ })] }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
295
+ htmlFor: X("pluginRepository"),
295
296
  className: "block text-sm font-medium mb-1.5 text-text-primary",
296
- children: "Repository"
297
- }), /* @__PURE__ */ g("input", {
298
- id: J("pluginRepository"),
299
- "aria-label": "Repository",
300
- value: W.pluginRepository,
301
- onChange: (e) => Y("pluginRepository", e.target.value),
297
+ children: N("integrations.providerEditor.fields.repository", "Repository")
298
+ }), /* @__PURE__ */ _("input", {
299
+ id: X("pluginRepository"),
300
+ "aria-label": N("integrations.providerEditor.fields.repository", "Repository"),
301
+ value: K.pluginRepository,
302
+ onChange: (e) => Z("pluginRepository", e.target.value),
302
303
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
303
304
  })] })]
304
305
  })
305
306
  ]
306
307
  }),
307
- /* @__PURE__ */ _(b, {
308
+ /* @__PURE__ */ v(x, {
308
309
  className: "border-border-seam p-5 space-y-4",
309
310
  children: [
310
- /* @__PURE__ */ g("h2", {
311
+ /* @__PURE__ */ _("h2", {
311
312
  className: "font-semibold text-text-primary",
312
- children: "Runtime config"
313
+ children: N("integrations.providerEditor.sections.runtimeConfig", "Runtime config")
313
314
  }),
314
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
315
- htmlFor: J("baseUrl"),
315
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
316
+ htmlFor: X("baseUrl"),
316
317
  className: "block text-sm font-medium mb-1.5 text-text-primary",
317
- children: "Base URL"
318
- }), /* @__PURE__ */ g("input", {
319
- id: J("baseUrl"),
320
- "aria-label": "Base URL",
321
- value: W.baseUrl,
322
- onChange: (e) => Y("baseUrl", e.target.value),
318
+ children: N("integrations.providerEditor.fields.baseUrl", "Base URL")
319
+ }), /* @__PURE__ */ _("input", {
320
+ id: X("baseUrl"),
321
+ "aria-label": N("integrations.providerEditor.fields.baseUrl", "Base URL"),
322
+ value: K.baseUrl,
323
+ onChange: (e) => Z("baseUrl", e.target.value),
323
324
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
324
325
  })] }),
325
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
326
- htmlFor: J("apiVersion"),
326
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
327
+ htmlFor: X("apiVersion"),
327
328
  className: "block text-sm font-medium mb-1.5 text-text-primary",
328
- children: "API version"
329
- }), /* @__PURE__ */ g("input", {
330
- id: J("apiVersion"),
331
- "aria-label": "API version",
332
- value: W.apiVersion,
333
- onChange: (e) => Y("apiVersion", e.target.value),
329
+ children: N("integrations.providerEditor.fields.apiVersion", "API version")
330
+ }), /* @__PURE__ */ _("input", {
331
+ id: X("apiVersion"),
332
+ "aria-label": N("integrations.providerEditor.fields.apiVersion", "API version"),
333
+ value: K.apiVersion,
334
+ onChange: (e) => Z("apiVersion", e.target.value),
334
335
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
335
336
  })] }),
336
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
337
- htmlFor: J("defaultScopes"),
337
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
338
+ htmlFor: X("defaultScopes"),
338
339
  className: "block text-sm font-medium mb-1.5 text-text-primary",
339
- children: "Default scopes"
340
- }), /* @__PURE__ */ g("input", {
341
- id: J("defaultScopes"),
342
- "aria-label": "Default scopes",
343
- value: W.defaultScopes,
344
- onChange: (e) => Y("defaultScopes", e.target.value),
345
- placeholder: "openid, profile, email",
340
+ children: N("integrations.providerEditor.fields.defaultScopes", "Default scopes")
341
+ }), /* @__PURE__ */ _("input", {
342
+ id: X("defaultScopes"),
343
+ "aria-label": N("integrations.providerEditor.fields.defaultScopes", "Default scopes"),
344
+ value: K.defaultScopes,
345
+ onChange: (e) => Z("defaultScopes", e.target.value),
346
+ placeholder: N("integrations.providerEditor.fields.defaultScopesPlaceholder", "openid, profile, email"),
346
347
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
347
348
  })] }),
348
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
349
- htmlFor: J("supportedFeatures"),
349
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
350
+ htmlFor: X("supportedFeatures"),
350
351
  className: "block text-sm font-medium mb-1.5 text-text-primary",
351
- children: "Supported features"
352
- }), /* @__PURE__ */ g("input", {
353
- id: J("supportedFeatures"),
354
- "aria-label": "Supported features",
355
- value: W.supportedFeatures,
356
- onChange: (e) => Y("supportedFeatures", e.target.value),
357
- placeholder: "messages, files, events",
352
+ children: N("integrations.providerEditor.fields.supportedFeatures", "Supported features")
353
+ }), /* @__PURE__ */ _("input", {
354
+ id: X("supportedFeatures"),
355
+ "aria-label": N("integrations.providerEditor.fields.supportedFeatures", "Supported features"),
356
+ value: K.supportedFeatures,
357
+ onChange: (e) => Z("supportedFeatures", e.target.value),
358
+ placeholder: N("integrations.providerEditor.fields.supportedFeaturesPlaceholder", "messages, files, events"),
358
359
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm"
359
360
  })] }),
360
- /* @__PURE__ */ g(x, {
361
- title: "Advanced provider config",
362
- description: "Raw JSON for OAuth, scopes, rate limiting, and config schema. Most providers leave these blank.",
363
- children: /* @__PURE__ */ g("div", {
361
+ /* @__PURE__ */ _(S, {
362
+ title: N("integrations.providerEditor.sections.advancedConfig", "Advanced provider config"),
363
+ description: N("integrations.providerEditor.sections.advancedConfigDescription", "Raw JSON for OAuth, scopes, rate limiting, and config schema. Most providers leave these blank."),
364
+ children: /* @__PURE__ */ _("div", {
364
365
  className: "space-y-3",
365
366
  children: [
366
- ["oauthConfig", "OAuth config JSON"],
367
- ["availableScopes", "Available scopes JSON"],
368
- ["rateLimitConfig", "Rate limit config JSON"],
369
- ["configSchema", "Config schema JSON"]
370
- ].map(([e, t]) => /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
371
- htmlFor: J(e),
367
+ ["oauthConfig", N("integrations.providerEditor.fields.oauthConfig", "OAuth config JSON")],
368
+ ["availableScopes", N("integrations.providerEditor.fields.availableScopes", "Available scopes JSON")],
369
+ ["rateLimitConfig", N("integrations.providerEditor.fields.rateLimitConfig", "Rate limit config JSON")],
370
+ ["configSchema", N("integrations.providerEditor.fields.configSchema", "Config schema JSON")]
371
+ ].map(([e, t]) => /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
372
+ htmlFor: X(e),
372
373
  className: "block text-sm font-medium mb-1.5 text-text-primary",
373
374
  children: t
374
- }), /* @__PURE__ */ g("textarea", {
375
- id: J(e),
375
+ }), /* @__PURE__ */ _("textarea", {
376
+ id: X(e),
376
377
  "aria-label": t,
377
- value: W[e],
378
- onChange: (t) => Y(e, t.target.value),
378
+ value: K[e],
379
+ onChange: (t) => Z(e, t.target.value),
379
380
  rows: 4,
380
381
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm font-mono"
381
382
  })] }, e))
382
383
  })
383
384
  }),
384
- /* @__PURE__ */ _("label", {
385
+ /* @__PURE__ */ v("label", {
385
386
  className: "flex items-center gap-3 rounded-lg border border-border-seam bg-bg-surface px-3 py-2.5",
386
- children: [/* @__PURE__ */ g("input", {
387
+ children: [/* @__PURE__ */ _("input", {
387
388
  type: "checkbox",
388
- checked: W.isEnabled,
389
- onChange: (e) => Y("isEnabled", e.target.checked),
390
- "aria-label": "Provider enabled"
391
- }), /* @__PURE__ */ g("span", {
389
+ checked: K.isEnabled,
390
+ onChange: (e) => Z("isEnabled", e.target.checked),
391
+ "aria-label": N("integrations.providerEditor.fields.enabled", "Provider enabled")
392
+ }), /* @__PURE__ */ _("span", {
392
393
  className: "text-sm text-text-primary",
393
- children: "Provider enabled"
394
+ children: N("integrations.providerEditor.fields.enabled", "Provider enabled")
394
395
  })]
395
396
  })
396
397
  ]
397
398
  }),
398
- k && I && /* @__PURE__ */ g(b, {
399
+ A && R && /* @__PURE__ */ _(x, {
399
400
  className: "p-5",
400
- children: /* @__PURE__ */ g(o, {
401
- provider: I,
402
- canManage: K
401
+ children: /* @__PURE__ */ _(s, {
402
+ provider: R,
403
+ canManage: J
403
404
  })
404
405
  })
405
406
  ]
406
407
  }),
407
- /* @__PURE__ */ g("div", {
408
+ /* @__PURE__ */ _("div", {
408
409
  className: "flex justify-end",
409
- children: /* @__PURE__ */ _(v, {
410
+ children: /* @__PURE__ */ v(y, {
410
411
  onClick: async () => {
411
412
  try {
412
- U("");
413
+ G("");
413
414
  let e = {
414
- name: W.name.trim(),
415
- description: W.description.trim() || void 0,
416
- icon: W.icon.trim() || void 0,
417
- color: W.color.trim() || void 0,
418
- website: W.website.trim() || void 0,
419
- docsUrl: W.docsUrl.trim() || void 0,
420
- baseUrl: W.baseUrl.trim() || void 0,
421
- apiVersion: W.apiVersion.trim() || void 0,
422
- pluginVersion: W.pluginVersion.trim() || void 0,
423
- pluginAuthor: W.pluginAuthor.trim() || void 0,
424
- pluginRepository: W.pluginRepository.trim() || void 0,
425
- displayOrder: Number(W.displayOrder || "0"),
426
- defaultScopes: W.defaultScopes.split(",").flatMap((e) => {
415
+ name: K.name.trim(),
416
+ description: K.description.trim() || void 0,
417
+ icon: K.icon.trim() || void 0,
418
+ color: K.color.trim() || void 0,
419
+ website: K.website.trim() || void 0,
420
+ docsUrl: K.docsUrl.trim() || void 0,
421
+ baseUrl: K.baseUrl.trim() || void 0,
422
+ apiVersion: K.apiVersion.trim() || void 0,
423
+ pluginVersion: K.pluginVersion.trim() || void 0,
424
+ pluginAuthor: K.pluginAuthor.trim() || void 0,
425
+ pluginRepository: K.pluginRepository.trim() || void 0,
426
+ displayOrder: Number(K.displayOrder || "0"),
427
+ defaultScopes: K.defaultScopes.split(",").flatMap((e) => {
427
428
  let t = e.trim();
428
429
  return t ? [t] : [];
429
430
  }),
430
- supportedFeatures: W.supportedFeatures.split(",").flatMap((e) => {
431
+ supportedFeatures: K.supportedFeatures.split(",").flatMap((e) => {
431
432
  let t = e.trim();
432
433
  return t ? [t] : [];
433
434
  }),
434
- oauthConfig: T(W.oauthConfig, "OAuth config"),
435
- availableScopes: T(W.availableScopes, "Available scopes"),
436
- rateLimitConfig: T(W.rateLimitConfig, "Rate limit config"),
437
- configSchema: T(W.configSchema, "Config schema"),
438
- isEnabled: W.isEnabled
435
+ oauthConfig: E(K.oauthConfig, "OAuth config"),
436
+ availableScopes: E(K.availableScopes, "Available scopes"),
437
+ rateLimitConfig: E(K.rateLimitConfig, "Rate limit config"),
438
+ configSchema: E(K.configSchema, "Config schema"),
439
+ isEnabled: K.isEnabled
439
440
  };
440
- if (k && O) await B(O, e), j?.(n(A, `providers/${O}`));
441
+ if (A && k) await H(k, e), M?.(r(j, `providers/${k}`));
441
442
  else {
442
- let t = await R({
443
- key: W.key.trim(),
444
- category: W.category,
445
- authType: W.authType,
443
+ let t = await B({
444
+ key: K.key.trim(),
445
+ category: K.category,
446
+ authType: K.authType,
446
447
  ...e
447
448
  });
448
- j?.(n(A, `providers/${t?.id || ""}`));
449
+ M?.(r(j, `providers/${t?.id || ""}`));
449
450
  }
450
451
  } catch (e) {
451
- U(e instanceof Error ? e.message : "Failed to save provider");
452
+ G(e instanceof Error ? e.message : N("integrations.providerEditor.errors.saveFailed", "Failed to save provider"));
452
453
  }
453
454
  },
454
- disabled: z || V,
455
- children: [z || V ? /* @__PURE__ */ g(d, {
455
+ disabled: V || U,
456
+ children: [V || U ? /* @__PURE__ */ _(f, {
456
457
  size: 16,
457
458
  className: "animate-spin"
458
- }) : /* @__PURE__ */ g(f, { size: 16 }), k ? "Save Provider" : "Create Provider"]
459
+ }) : /* @__PURE__ */ _(p, { size: 16 }), A ? N("integrations.common.save", "Save Provider") : N("integrations.common.create", "Create Provider")]
459
460
  })
460
461
  })
461
462
  ]
462
- }) : /* @__PURE__ */ _("div", {
463
+ }) : /* @__PURE__ */ v("div", {
463
464
  className: "flex flex-col items-center justify-center py-20 text-center p-6",
464
465
  children: [
465
- /* @__PURE__ */ g(p, {
466
+ /* @__PURE__ */ _(m, {
466
467
  size: 48,
467
468
  className: "text-text-secondary mb-4"
468
469
  }),
469
- /* @__PURE__ */ g("h2", {
470
+ /* @__PURE__ */ _("h2", {
470
471
  className: "text-xl font-bold text-text-primary mb-2",
471
- children: "Access Denied"
472
+ children: N("integrations.providerEditor.accessDenied.title", "Access Denied")
472
473
  }),
473
- /* @__PURE__ */ g("p", {
474
+ /* @__PURE__ */ _("p", {
474
475
  className: "text-sm text-text-secondary max-w-md",
475
- children: "You do not have permission to manage providers."
476
+ children: N("integrations.providerEditor.accessDenied.description", "You do not have permission to manage providers.")
476
477
  })
477
478
  ]
478
479
  });
479
480
  }
480
481
  //#endregion
481
- export { O as ProviderEditorPage };
482
+ export { k as ProviderEditorPage };
482
483
 
483
484
  //# sourceMappingURL=ProviderEditorPage.js.map