@burdenoff/microfe-channel 2026.715.1 → 2026.720.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.
Files changed (30) hide show
  1. package/dist/channel/components/MarkdownEditor.d.ts +23 -0
  2. package/dist/channel/components/MarkdownEditor.d.ts.map +1 -0
  3. package/dist/channel/components/MarkdownEditor.js +172 -0
  4. package/dist/channel/components/MarkdownEditor.js.map +1 -0
  5. package/dist/channel/modules/channels/pages/ChannelDetailsPage.d.ts.map +1 -1
  6. package/dist/channel/modules/channels/pages/ChannelDetailsPage.js +47 -46
  7. package/dist/channel/modules/channels/pages/ChannelDetailsPage.js.map +1 -1
  8. package/dist/channel/modules/channels/pages/ChannelSettingsPage.js.map +1 -1
  9. package/dist/channel/modules/channels/pages/ChannelUsersPage.d.ts.map +1 -1
  10. package/dist/channel/modules/channels/pages/ChannelUsersPage.js.map +1 -1
  11. package/dist/channel/modules/channels/pages/ChannelsListPage.d.ts.map +1 -1
  12. package/dist/channel/modules/channels/pages/ChannelsListPage.js.map +1 -1
  13. package/dist/channel/modules/channels/pages/ConnectionDetailsPage.d.ts.map +1 -1
  14. package/dist/channel/modules/channels/pages/ConnectionDetailsPage.js.map +1 -1
  15. package/dist/channel/modules/channels/pages/ConnectionsListPage.d.ts.map +1 -1
  16. package/dist/channel/modules/channels/pages/ConnectionsListPage.js.map +1 -1
  17. package/dist/channel/modules/channels/pages/CreateChannelPage.d.ts.map +1 -1
  18. package/dist/channel/modules/channels/pages/CreateChannelPage.js +158 -156
  19. package/dist/channel/modules/channels/pages/CreateChannelPage.js.map +1 -1
  20. package/dist/channel/modules/channels/pages/CreateConnectionPage.js.map +1 -1
  21. package/dist/channel/modules/channels/pages/DeliveryHistoryPage.d.ts.map +1 -1
  22. package/dist/channel/modules/channels/pages/DeliveryHistoryPage.js.map +1 -1
  23. package/dist/channel/modules/channels/pages/EditChannelPage.d.ts.map +1 -1
  24. package/dist/channel/modules/channels/pages/EditChannelPage.js +125 -123
  25. package/dist/channel/modules/channels/pages/EditChannelPage.js.map +1 -1
  26. package/dist/channel/modules/channels/pages/EditConnectionPage.js.map +1 -1
  27. package/dist/channel/modules/channels/pages/SendMessagePage.d.ts.map +1 -1
  28. package/dist/channel/modules/channels/pages/SendMessagePage.js +171 -171
  29. package/dist/channel/modules/channels/pages/SendMessagePage.js.map +1 -1
  30. package/package.json +2 -2
@@ -2,19 +2,20 @@ import { nativeImpact as e, nativeNotify as t } from "../../../../utils/nativeBr
2
2
  import { useChannel as n, useChannels as r } from "../../../hooks/useChannels.js";
3
3
  import { PermissionGuard as i } from "../../../components/PermissionGuard.js";
4
4
  import { CHANNEL_PERMISSIONS as a } from "../../../constants/permissions.js";
5
- import { useEffect as o, useRef as ee, useState as s } from "react";
6
- import { useI18n as c } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
7
- import { AlertCircle as l, ArrowLeft as u, Bell as d, Hash as f, Inbox as p, Loader2 as m, Mail as h, MessageCircle as g, MessageSquare as _, Save as v, Send as y, Smartphone as b, Trash2 as x, Users as S } from "lucide-react";
8
- import { useNavigate as C, useParams as w } from "react-router-dom";
9
- import { Fragment as T, jsx as E, jsxs as D } from "react/jsx-runtime";
10
- import { EmphasisPanel as O, GlassCard as k, PagePurpose as A } from "@burdenoff/fe-libs/ui";
5
+ import { MarkdownEditor as o } from "../../../components/MarkdownEditor.js";
6
+ import { useEffect as s, useRef as c, useState as l } from "react";
7
+ import { useI18n as ee } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
8
+ import { AlertCircle as u, ArrowLeft as d, Bell as f, Hash as p, Inbox as m, Loader2 as h, Mail as g, MessageCircle as _, MessageSquare as v, Save as y, Send as b, Smartphone as x, Trash2 as S, Users as C } from "lucide-react";
9
+ import { useNavigate as w, useParams as T } from "react-router-dom";
10
+ import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
11
+ import { EmphasisPanel as te, GlassCard as k, PagePurpose as A } from "@burdenoff/fe-libs/ui";
11
12
  //#region src/channel/modules/channels/pages/EditChannelPage.tsx
12
13
  var j = [
13
14
  {
14
15
  value: "EMAIL",
15
16
  label: "Email",
16
17
  description: "Send emails via various providers",
17
- icon: h,
18
+ icon: g,
18
19
  color: "text-status-info-text bg-status-info-bg-subtle border-status-info-border",
19
20
  adapters: [
20
21
  {
@@ -51,7 +52,7 @@ var j = [
51
52
  value: "SMS",
52
53
  label: "SMS",
53
54
  description: "Send text messages",
54
- icon: b,
55
+ icon: x,
55
56
  color: "text-status-success-text bg-status-success-bg-subtle border-status-success-border/30",
56
57
  adapters: [
57
58
  {
@@ -84,7 +85,7 @@ var j = [
84
85
  value: "PUSH",
85
86
  label: "Push",
86
87
  description: "Mobile & web push",
87
- icon: d,
88
+ icon: f,
88
89
  color: "text-accent-purple bg-accent-purple-subtle border-accent-purple/30",
89
90
  adapters: [
90
91
  {
@@ -109,7 +110,7 @@ var j = [
109
110
  value: "INAPP",
110
111
  label: "In-App",
111
112
  description: "Internal in-app notifications",
112
- icon: p,
113
+ icon: m,
113
114
  color: "text-status-warning-text bg-status-warning-bg-subtle border-status-warning-border/30",
114
115
  adapters: [{
115
116
  value: "INAPP_NATIVE",
@@ -120,7 +121,7 @@ var j = [
120
121
  value: "WHATSAPP",
121
122
  label: "WhatsApp",
122
123
  description: "WhatsApp Business messaging",
123
- icon: _,
124
+ icon: v,
124
125
  color: "text-status-success-text bg-status-success-bg-subtle border-status-success-border/30",
125
126
  adapters: [{
126
127
  value: "WHATSAPP_CLOUD",
@@ -134,7 +135,7 @@ var j = [
134
135
  value: "SLACK",
135
136
  label: "Slack",
136
137
  description: "Slack bot & channels",
137
- icon: f,
138
+ icon: p,
138
139
  color: "text-accent-purple bg-accent-purple-subtle border-accent-purple/30",
139
140
  adapters: [{
140
141
  value: "SLACK_BOT",
@@ -145,7 +146,7 @@ var j = [
145
146
  value: "TEAMS",
146
147
  label: "Teams",
147
148
  description: "Microsoft Teams",
148
- icon: S,
149
+ icon: C,
149
150
  color: "text-status-info-text bg-status-info-bg-subtle border-status-info-border",
150
151
  adapters: [{
151
152
  value: "TEAMS_BOT",
@@ -156,7 +157,7 @@ var j = [
156
157
  value: "DISCORD",
157
158
  label: "Discord",
158
159
  description: "Discord bots & webhooks",
159
- icon: g,
160
+ icon: _,
160
161
  color: "text-accent-indigo bg-accent-indigo-subtle border-accent-indigo/30",
161
162
  adapters: [{
162
163
  value: "DISCORD_BOT",
@@ -167,7 +168,7 @@ var j = [
167
168
  value: "WEBCHAT",
168
169
  label: "Webchat",
169
170
  description: "Website live chat",
170
- icon: _,
171
+ icon: v,
171
172
  color: "text-accent-teal bg-accent-teal-subtle border-accent-teal/30",
172
173
  adapters: [{
173
174
  value: "WEBCHAT_NATIVE",
@@ -178,7 +179,7 @@ var j = [
178
179
  value: "WEBHOOK",
179
180
  label: "Webhook",
180
181
  description: "Generic HTTP webhook",
181
- icon: y,
182
+ icon: b,
182
183
  color: "text-text-secondary bg-bg-sunken/50 border-border-subtle",
183
184
  adapters: [{
184
185
  value: "WEBHOOK_HTTP",
@@ -208,184 +209,185 @@ var j = [
208
209
  }
209
210
  ];
210
211
  function N() {
211
- let d = C(), { channelId: f } = w(), { channel: p, isLoading: h, error: g } = n(f), { updateChannel: _, deleteChannel: y } = r(), { t: b } = c(), S = (e, t) => {
212
- let n = b(e);
212
+ let f = w(), { channelId: p } = T(), { channel: m, isLoading: g, error: _ } = n(p), { updateChannel: v, deleteChannel: b } = r(), { t: x } = ee(), C = (e, t) => {
213
+ let n = x(e);
213
214
  return n === e ? t : n;
214
- }, [N, P] = s(""), [F, I] = s(""), [L, R] = s("AWS_SES"), [z, B] = s(2), [V, H] = s("INACTIVE"), [U, W] = s(!1), [G, K] = s(!1), [q, J] = s(null), [Y, X] = s(!1), Z = ee(null);
215
- o(() => {
216
- p && p.id !== Z.current && (Z.current = p.id, Promise.resolve().then(() => {
217
- P(p.name || ""), I(p.description || ""), R(p.adapterType || "AWS_SES"), B(p.priority || 2), H(p.status || "INACTIVE");
215
+ }, [N, P] = l(""), [F, I] = l(""), [L, R] = l("AWS_SES"), [z, B] = l(2), [V, H] = l("INACTIVE"), [U, W] = l(!1), [G, K] = l(!1), [q, J] = l(null), [Y, X] = l(!1), Z = c(null);
216
+ s(() => {
217
+ m && m.id !== Z.current && (Z.current = m.id, Promise.resolve().then(() => {
218
+ P(m.name || ""), I(m.description || ""), R(m.adapterType || "AWS_SES"), B(m.priority || 2), H(m.status || "INACTIVE");
218
219
  }));
219
- }, [p]);
220
- let Q = p?.platform || "EMAIL", $ = j.find((e) => e.value === Q);
221
- return h ? /* @__PURE__ */ E("div", {
220
+ }, [m]);
221
+ let Q = m?.platform || "EMAIL", $ = j.find((e) => e.value === Q);
222
+ return g ? /* @__PURE__ */ D("div", {
222
223
  className: "flex items-center justify-center min-h-screen",
223
- children: /* @__PURE__ */ E(m, { className: "size-8 animate-spin text-text-secondary" })
224
- }) : g || !p ? /* @__PURE__ */ D("div", {
224
+ children: /* @__PURE__ */ D(h, { className: "size-8 animate-spin text-text-secondary" })
225
+ }) : _ || !m ? /* @__PURE__ */ O("div", {
225
226
  className: "flex flex-col items-center justify-center min-h-screen gap-4",
226
227
  children: [
227
- /* @__PURE__ */ E(l, { className: "size-12 text-status-error-text" }),
228
- /* @__PURE__ */ E("h1", {
228
+ /* @__PURE__ */ D(u, { className: "size-12 text-status-error-text" }),
229
+ /* @__PURE__ */ D("h1", {
229
230
  className: "text-xl font-semibold",
230
- children: S("channel.channelNotFound", "Channel not found")
231
+ children: C("channel.channelNotFound", "Channel not found")
231
232
  }),
232
- /* @__PURE__ */ E("button", {
233
+ /* @__PURE__ */ D("button", {
233
234
  type: "button",
234
- onClick: () => d("../list"),
235
+ onClick: () => f("../list"),
235
236
  className: "text-primary hover:underline",
236
- children: S("channel.backToChannels", "Back to channels")
237
+ children: C("channel.backToChannels", "Back to channels")
237
238
  })
238
239
  ]
239
- }) : /* @__PURE__ */ E(i, {
240
+ }) : /* @__PURE__ */ D(i, {
240
241
  permission: a.CHANNEL_UPDATE,
241
- children: /* @__PURE__ */ D("div", {
242
+ children: /* @__PURE__ */ O("div", {
242
243
  className: "min-h-screen bg-bg-surface",
243
- children: [/* @__PURE__ */ E("div", {
244
+ children: [/* @__PURE__ */ D("div", {
244
245
  className: "border-b bg-bg-surface",
245
- children: /* @__PURE__ */ E("div", {
246
+ children: /* @__PURE__ */ D("div", {
246
247
  className: "container mx-auto px-6 py-4",
247
- children: /* @__PURE__ */ D("div", {
248
+ children: /* @__PURE__ */ O("div", {
248
249
  className: "flex items-center gap-4",
249
- children: [/* @__PURE__ */ E("button", {
250
+ children: [/* @__PURE__ */ D("button", {
250
251
  type: "button",
251
- onClick: () => d(`/channels/${f}`),
252
+ onClick: () => f(`/channels/${p}`),
252
253
  className: "p-2 hover:bg-bg-sunken rounded-lg transition-colors",
253
- children: /* @__PURE__ */ E(u, { className: "size-5 " })
254
- }), /* @__PURE__ */ D("div", { children: [/* @__PURE__ */ E("h1", {
254
+ children: /* @__PURE__ */ D(d, { className: "size-5 " })
255
+ }), /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("h1", {
255
256
  className: "text-2xl font-bold",
256
- children: S("channel.editChannel", "Edit Channel")
257
- }), /* @__PURE__ */ E("p", {
257
+ children: C("channel.editChannel", "Edit Channel")
258
+ }), /* @__PURE__ */ D("p", {
258
259
  className: "text-sm text-text-secondary",
259
- children: S("channel.updateChannelConfig", "Update channel configuration")
260
+ children: C("channel.updateChannelConfig", "Update channel configuration")
260
261
  })] })]
261
262
  })
262
263
  })
263
- }), /* @__PURE__ */ E("div", {
264
+ }), /* @__PURE__ */ D("div", {
264
265
  className: "container mx-auto px-6 py-8 max-w-2xl",
265
- children: /* @__PURE__ */ D("div", {
266
+ children: /* @__PURE__ */ O("div", {
266
267
  className: "space-y-6",
267
268
  children: [
268
- /* @__PURE__ */ E(A, {
269
- icon: /* @__PURE__ */ E(v, {
269
+ /* @__PURE__ */ D(A, {
270
+ icon: /* @__PURE__ */ D(y, {
270
271
  size: 15,
271
272
  "aria-hidden": "true"
272
273
  }),
273
- children: S("channel.editChannelPurpose", "Change how this channel behaves — its name, description, priority and status. The platform and provider stay fixed (they define what the channel is); to swap credentials use the channel's connection instead. Use this to rename a channel, bump its priority, or temporarily deactivate it without deleting it.")
274
+ children: C("channel.editChannelPurpose", "Change how this channel behaves — its name, description, priority and status. The platform and provider stay fixed (they define what the channel is); to swap credentials use the channel's connection instead. Use this to rename a channel, bump its priority, or temporarily deactivate it without deleting it.")
274
275
  }),
275
- q && /* @__PURE__ */ D("div", {
276
+ q && /* @__PURE__ */ O("div", {
276
277
  className: "p-4 rounded-lg bg-status-error-bg/10 border border-status-error-border/20 flex items-center gap-3",
277
- children: [/* @__PURE__ */ E(l, { className: "size-5 text-status-error-text shrink-0" }), /* @__PURE__ */ E("p", {
278
+ children: [/* @__PURE__ */ D(u, { className: "size-5 text-status-error-text shrink-0" }), /* @__PURE__ */ D("p", {
278
279
  className: "text-sm text-status-error-text",
279
280
  children: q
280
281
  })]
281
282
  }),
282
- /* @__PURE__ */ D(k, {
283
+ /* @__PURE__ */ O(k, {
283
284
  treatment: "insight",
284
285
  className: "p-4 border-border-seam space-y-2",
285
- children: [/* @__PURE__ */ E("div", {
286
+ children: [/* @__PURE__ */ D("div", {
286
287
  className: "flex items-center gap-2",
287
- children: $ && /* @__PURE__ */ D(T, { children: [(() => {
288
+ children: $ && /* @__PURE__ */ O(E, { children: [(() => {
288
289
  let e = $.icon;
289
- return /* @__PURE__ */ E(e, { className: "size-5 text-text-secondary" });
290
- })(), /* @__PURE__ */ E("span", {
290
+ return /* @__PURE__ */ D(e, { className: "size-5 text-text-secondary" });
291
+ })(), /* @__PURE__ */ D("span", {
291
292
  className: "font-medium",
292
293
  children: Q
293
294
  })] })
294
- }), /* @__PURE__ */ E("p", {
295
+ }), /* @__PURE__ */ D("p", {
295
296
  className: "text-sm text-text-secondary",
296
- children: S("channel.platformLockedHint", "Platform cannot be changed after channel creation. Create a new channel to use a different platform.")
297
+ children: C("channel.platformLockedHint", "Platform cannot be changed after channel creation. Create a new channel to use a different platform.")
297
298
  })]
298
299
  }),
299
- /* @__PURE__ */ D(O, {
300
+ /* @__PURE__ */ O(te, {
300
301
  className: "p-5 space-y-6",
301
302
  children: [
302
- /* @__PURE__ */ D("div", {
303
+ /* @__PURE__ */ O("div", {
303
304
  className: "space-y-2",
304
- children: [/* @__PURE__ */ D("label", {
305
+ children: [/* @__PURE__ */ O("label", {
305
306
  className: "text-sm font-medium",
306
- children: [S("channel.channelName", "Channel Name"), " *"]
307
- }), /* @__PURE__ */ E("input", {
308
- "aria-label": S("channel.editNamePlaceholder", "e.g., Production Email, Customer SMS"),
307
+ children: [C("channel.channelName", "Channel Name"), " *"]
308
+ }), /* @__PURE__ */ D("input", {
309
+ "aria-label": C("channel.editNamePlaceholder", "e.g., Production Email, Customer SMS"),
309
310
  type: "text",
310
311
  value: N,
311
312
  onChange: (e) => P(e.target.value),
312
- placeholder: S("channel.editNamePlaceholder", "e.g., Production Email, Customer SMS"),
313
+ placeholder: C("channel.editNamePlaceholder", "e.g., Production Email, Customer SMS"),
313
314
  className: "w-full px-4 py-2 rounded-lg border bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary"
314
315
  })]
315
316
  }),
316
- /* @__PURE__ */ D("div", {
317
+ /* @__PURE__ */ O("div", {
317
318
  className: "space-y-2",
318
- children: [/* @__PURE__ */ E("label", {
319
+ children: [/* @__PURE__ */ D("label", {
320
+ htmlFor: "channel-edit-description",
319
321
  className: "text-sm font-medium",
320
- children: S("channel.description", "Description")
321
- }), /* @__PURE__ */ E("textarea", {
322
- "aria-label": S("channel.editDescriptionPlaceholder", "Optional description for this channel"),
322
+ children: C("channel.description", "Description")
323
+ }), /* @__PURE__ */ D(o, {
324
+ id: "channel-edit-description",
323
325
  value: F,
324
- onChange: (e) => I(e.target.value),
325
- placeholder: S("channel.editDescriptionPlaceholder", "Optional description for this channel"),
326
- rows: 3,
327
- className: "w-full px-4 py-2 rounded-lg border bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary resize-none"
326
+ onChange: I,
327
+ "aria-label": C("channel.editDescriptionPlaceholder", "Optional description for this channel"),
328
+ placeholder: C("channel.editDescriptionPlaceholder", "Optional description for this channel"),
329
+ rows: 3
328
330
  })]
329
331
  }),
330
- $ && /* @__PURE__ */ D("div", {
332
+ $ && /* @__PURE__ */ O("div", {
331
333
  className: "space-y-2",
332
- children: [/* @__PURE__ */ E("label", {
334
+ children: [/* @__PURE__ */ D("label", {
333
335
  className: "text-sm font-medium",
334
- children: S("channel.adapterProvider", "Adapter / Provider")
335
- }), /* @__PURE__ */ E("select", {
336
+ children: C("channel.adapterProvider", "Adapter / Provider")
337
+ }), /* @__PURE__ */ D("select", {
336
338
  value: L,
337
339
  onChange: (e) => R(e.target.value),
338
340
  className: "w-full px-4 py-2 rounded-lg border bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary",
339
- children: $.adapters.map((e) => /* @__PURE__ */ E("option", {
341
+ children: $.adapters.map((e) => /* @__PURE__ */ D("option", {
340
342
  value: e.value,
341
343
  children: e.label
342
344
  }, e.value))
343
345
  })]
344
346
  }),
345
- /* @__PURE__ */ D("div", {
347
+ /* @__PURE__ */ O("div", {
346
348
  className: "grid grid-cols-2 gap-4",
347
- children: [/* @__PURE__ */ D("div", {
349
+ children: [/* @__PURE__ */ O("div", {
348
350
  className: "space-y-2",
349
351
  children: [
350
- /* @__PURE__ */ E("label", {
352
+ /* @__PURE__ */ D("label", {
351
353
  className: "text-sm font-medium",
352
- children: S("channel.priority", "Priority")
354
+ children: C("channel.priority", "Priority")
353
355
  }),
354
- /* @__PURE__ */ E("select", {
356
+ /* @__PURE__ */ D("select", {
355
357
  value: z,
356
358
  onChange: (e) => B(Number(e.target.value)),
357
359
  className: "w-full px-4 py-2 rounded-lg border bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary",
358
- children: M.map((e) => /* @__PURE__ */ E("option", {
360
+ children: M.map((e) => /* @__PURE__ */ D("option", {
359
361
  value: e.value,
360
362
  children: e.label
361
363
  }, e.value))
362
364
  }),
363
- /* @__PURE__ */ E("p", {
365
+ /* @__PURE__ */ D("p", {
364
366
  className: "text-xs text-text-secondary",
365
- children: S("channel.priorityFailoverHint", "Higher priority channels are used first in failover")
367
+ children: C("channel.priorityFailoverHint", "Higher priority channels are used first in failover")
366
368
  })
367
369
  ]
368
- }), /* @__PURE__ */ D("div", {
370
+ }), /* @__PURE__ */ O("div", {
369
371
  className: "space-y-2",
370
- children: [/* @__PURE__ */ E("label", {
372
+ children: [/* @__PURE__ */ D("label", {
371
373
  className: "text-sm font-medium",
372
- children: S("channel.status", "Status")
373
- }), /* @__PURE__ */ D("select", {
374
+ children: C("channel.status", "Status")
375
+ }), /* @__PURE__ */ O("select", {
374
376
  value: V,
375
377
  onChange: (e) => H(e.target.value),
376
378
  className: "w-full px-4 py-2 rounded-lg border bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary",
377
379
  children: [
378
- /* @__PURE__ */ E("option", {
380
+ /* @__PURE__ */ D("option", {
379
381
  value: "INACTIVE",
380
- children: S("channel.status.inactive", "Inactive")
382
+ children: C("channel.status.inactive", "Inactive")
381
383
  }),
382
- /* @__PURE__ */ E("option", {
384
+ /* @__PURE__ */ D("option", {
383
385
  value: "ACTIVE",
384
- children: S("channel.status.active", "Active")
386
+ children: C("channel.status.active", "Active")
385
387
  }),
386
- /* @__PURE__ */ E("option", {
388
+ /* @__PURE__ */ D("option", {
387
389
  value: "SUSPENDED",
388
- children: S("channel.status.suspended", "Suspended")
390
+ children: C("channel.status.suspended", "Suspended")
389
391
  })
390
392
  ]
391
393
  })]
@@ -393,72 +395,72 @@ function N() {
393
395
  })
394
396
  ]
395
397
  }),
396
- /* @__PURE__ */ D("div", {
398
+ /* @__PURE__ */ O("div", {
397
399
  className: "flex items-center justify-between pt-6 border-t",
398
- children: [/* @__PURE__ */ E("div", { children: Y ? /* @__PURE__ */ D("div", {
400
+ children: [/* @__PURE__ */ D("div", { children: Y ? /* @__PURE__ */ O("div", {
399
401
  className: "flex items-center gap-2",
400
402
  children: [
401
- /* @__PURE__ */ E("span", {
403
+ /* @__PURE__ */ D("span", {
402
404
  className: "text-sm text-text-secondary",
403
- children: S("channel.confirmDelete", "Confirm delete?")
405
+ children: C("channel.confirmDelete", "Confirm delete?")
404
406
  }),
405
- /* @__PURE__ */ D("button", {
407
+ /* @__PURE__ */ O("button", {
406
408
  type: "button",
407
409
  onClick: async () => {
408
- if (!(!f || !Y)) {
410
+ if (!(!p || !Y)) {
409
411
  e("medium"), K(!0);
410
412
  try {
411
- await y(f) ? (t("success"), d("../list")) : t("error");
413
+ await b(p) ? (t("success"), f("../list")) : t("error");
412
414
  } catch (e) {
413
- t("error"), J(e instanceof Error ? e.message : S("channel.deleteFailed", "Failed to delete channel")), K(!1);
415
+ t("error"), J(e instanceof Error ? e.message : C("channel.deleteFailed", "Failed to delete channel")), K(!1);
414
416
  }
415
417
  }
416
418
  },
417
419
  disabled: G,
418
420
  className: "px-4 py-2 text-sm bg-status-error-bg text-status-error-text rounded-lg hover:bg-status-error-bg/90 transition-colors flex items-center gap-2",
419
- children: [G ? /* @__PURE__ */ E(m, { className: "size-4 animate-spin" }) : /* @__PURE__ */ E(x, { className: "size-4 " }), S("channel.delete", "Delete")]
421
+ children: [G ? /* @__PURE__ */ D(h, { className: "size-4 animate-spin" }) : /* @__PURE__ */ D(S, { className: "size-4 " }), C("channel.delete", "Delete")]
420
422
  }),
421
- /* @__PURE__ */ E("button", {
423
+ /* @__PURE__ */ D("button", {
422
424
  type: "button",
423
425
  onClick: () => X(!1),
424
426
  className: "px-4 py-2 text-sm text-text-secondary hover:bg-bg-sunken rounded-lg transition-colors",
425
- children: S("channel.cancel", "Cancel")
427
+ children: C("channel.cancel", "Cancel")
426
428
  })
427
429
  ]
428
- }) : /* @__PURE__ */ E(i, {
430
+ }) : /* @__PURE__ */ D(i, {
429
431
  permission: a.CHANNEL_DELETE,
430
- children: /* @__PURE__ */ D("button", {
432
+ children: /* @__PURE__ */ O("button", {
431
433
  type: "button",
432
434
  onClick: () => X(!0),
433
435
  className: "px-4 py-2 text-sm text-status-error-text hover:bg-status-error-bg/10 rounded-lg transition-colors flex items-center gap-2",
434
- children: [/* @__PURE__ */ E(x, { className: "size-4 " }), S("channel.deleteChannel", "Delete Channel")]
436
+ children: [/* @__PURE__ */ D(S, { className: "size-4 " }), C("channel.deleteChannel", "Delete Channel")]
435
437
  })
436
- }) }), /* @__PURE__ */ D("div", {
438
+ }) }), /* @__PURE__ */ O("div", {
437
439
  className: "flex items-center gap-3",
438
- children: [/* @__PURE__ */ E("button", {
440
+ children: [/* @__PURE__ */ D("button", {
439
441
  type: "button",
440
- onClick: () => d(`/channels/${f}`),
442
+ onClick: () => f(`/channels/${p}`),
441
443
  className: "px-4 py-2 text-sm text-text-secondary hover:bg-bg-sunken rounded-lg transition-colors",
442
- children: S("channel.cancel", "Cancel")
443
- }), /* @__PURE__ */ D("button", {
444
+ children: C("channel.cancel", "Cancel")
445
+ }), /* @__PURE__ */ O("button", {
444
446
  type: "button",
445
447
  onClick: async () => {
446
- if (f) {
448
+ if (p) {
447
449
  if (!N.trim()) {
448
- J(S("channel.validation.nameRequired", "Channel name is required"));
450
+ J(C("channel.validation.nameRequired", "Channel name is required"));
449
451
  return;
450
452
  }
451
453
  W(!0), J(null);
452
454
  try {
453
- await _(f, {
455
+ await v(p, {
454
456
  name: N.trim(),
455
457
  description: F.trim() || void 0,
456
458
  adapterType: L,
457
459
  priority: z,
458
460
  status: V
459
- }) ? d(`/channels/${f}`) : J(S("channel.updateFailed", "Failed to update channel"));
461
+ }) ? f(`/channels/${p}`) : J(C("channel.updateFailed", "Failed to update channel"));
460
462
  } catch (e) {
461
- J(e instanceof Error ? e.message : S("channel.updateFailed", "Failed to update channel"));
463
+ J(e instanceof Error ? e.message : C("channel.updateFailed", "Failed to update channel"));
462
464
  } finally {
463
465
  W(!1);
464
466
  }
@@ -466,7 +468,7 @@ function N() {
466
468
  },
467
469
  disabled: U || !N.trim(),
468
470
  className: "px-6 py-2 text-sm bg-action-primary-bg text-action-primary-text rounded-lg hover:bg-action-primary-bg/90 transition-colors flex items-center gap-2 disabled:opacity-50",
469
- children: [U ? /* @__PURE__ */ E(m, { className: "size-4 animate-spin" }) : /* @__PURE__ */ E(v, { className: "size-4 " }), S("channel.saveChanges", "Save Changes")]
471
+ children: [U ? /* @__PURE__ */ D(h, { className: "size-4 animate-spin" }) : /* @__PURE__ */ D(y, { className: "size-4 " }), C("channel.saveChanges", "Save Changes")]
470
472
  })]
471
473
  })]
472
474
  })