@burdenoff/microfe-channel 2026.624.3 → 2026.625.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 (29) hide show
  1. package/dist/channel/modules/channels/pages/ChannelDashboardPage.js +134 -134
  2. package/dist/channel/modules/channels/pages/ChannelDashboardPage.js.map +1 -1
  3. package/dist/channel/modules/channels/pages/ChannelDetailsPage.js +287 -277
  4. package/dist/channel/modules/channels/pages/ChannelDetailsPage.js.map +1 -1
  5. package/dist/channel/modules/channels/pages/ChannelSettingsPage.js +140 -131
  6. package/dist/channel/modules/channels/pages/ChannelSettingsPage.js.map +1 -1
  7. package/dist/channel/modules/channels/pages/ChannelUsersPage.js +169 -169
  8. package/dist/channel/modules/channels/pages/ChannelUsersPage.js.map +1 -1
  9. package/dist/channel/modules/channels/pages/ChannelsListPage.js +204 -209
  10. package/dist/channel/modules/channels/pages/ChannelsListPage.js.map +1 -1
  11. package/dist/channel/modules/channels/pages/ConnectionDetailsPage.js +161 -155
  12. package/dist/channel/modules/channels/pages/ConnectionDetailsPage.js.map +1 -1
  13. package/dist/channel/modules/channels/pages/ConnectionsListPage.js +141 -148
  14. package/dist/channel/modules/channels/pages/ConnectionsListPage.js.map +1 -1
  15. package/dist/channel/modules/channels/pages/CreateChannelPage.js +27 -24
  16. package/dist/channel/modules/channels/pages/CreateChannelPage.js.map +1 -1
  17. package/dist/channel/modules/channels/pages/CreateConnectionPage.js +161 -156
  18. package/dist/channel/modules/channels/pages/CreateConnectionPage.js.map +1 -1
  19. package/dist/channel/modules/channels/pages/DeliveryHistoryPage.js +177 -192
  20. package/dist/channel/modules/channels/pages/DeliveryHistoryPage.js.map +1 -1
  21. package/dist/channel/modules/channels/pages/EditChannelPage.js +130 -122
  22. package/dist/channel/modules/channels/pages/EditChannelPage.js.map +1 -1
  23. package/dist/channel/modules/channels/pages/EditConnectionPage.js +137 -132
  24. package/dist/channel/modules/channels/pages/EditConnectionPage.js.map +1 -1
  25. package/dist/channel/modules/channels/pages/SendMessagePage.js +87 -84
  26. package/dist/channel/modules/channels/pages/SendMessagePage.js.map +1 -1
  27. package/dist/channel/modules/channels/pages/WebhookEventsPage.js +185 -183
  28. package/dist/channel/modules/channels/pages/WebhookEventsPage.js.map +1 -1
  29. package/package.json +2 -2
@@ -5,21 +5,22 @@ import { CHANNEL_PERMISSIONS as r } from "../../../constants/permissions.js";
5
5
  import { useExportDeliveryAttempts as i } from "../hooks/useExport.js";
6
6
  import { useCallback as a, useEffect as o, useRef as s, useState as c } from "react";
7
7
  import { useI18n as l } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
8
- import { AlertCircle as u, ArrowLeft as d, CheckCircle2 as f, ChevronLeft as ee, ChevronRight as p, Clock as m, Download as h, Loader2 as g, RefreshCw as _, RotateCcw as te, Send as v, XCircle as y } from "lucide-react";
9
- import { useNavigate as b, useParams as x } from "react-router-dom";
10
- import { Fragment as ne, jsx as S, jsxs as C } from "react/jsx-runtime";
11
- import { ResponsiveTable as w } from "@burdenoff/fe-libs/ui";
8
+ import { AlertCircle as u, ArrowLeft as ee, CheckCircle2 as d, ChevronLeft as te, ChevronRight as f, Clock as p, Download as m, Loader2 as h, RefreshCw as g, RotateCcw as _, Send as v, XCircle as y } from "lucide-react";
9
+ import { useNavigate as ne, useParams as re } from "react-router-dom";
10
+ import { usePermissions as b } from "@burdenoff/fe-libs/shared/providers/shell";
11
+ import { Fragment as ie, jsx as x, jsxs as S } from "react/jsx-runtime";
12
+ import { CTAOverflowMenu as ae, GlassCard as oe, IllustratedEmptyState as C, ResponsiveTable as w } from "@burdenoff/fe-libs/ui";
12
13
  //#region src/channel/modules/channels/pages/DeliveryHistoryPage.tsx
13
14
  var T = {
14
15
  PENDING: {
15
16
  label: "Pending",
16
17
  color: "text-text-secondary bg-bg-sunken",
17
- icon: m
18
+ icon: p
18
19
  },
19
20
  QUEUED: {
20
21
  label: "Queued",
21
22
  color: "text-accent-primary bg-accent-primary-subtle",
22
- icon: m
23
+ icon: p
23
24
  },
24
25
  SENDING: {
25
26
  label: "Sending",
@@ -29,12 +30,12 @@ var T = {
29
30
  SENT: {
30
31
  label: "Sent",
31
32
  color: "text-status-success-text bg-status-success-bg-subtle",
32
- icon: f
33
+ icon: d
33
34
  },
34
35
  DELIVERED: {
35
36
  label: "Delivered",
36
37
  color: "text-status-success-text bg-status-success-bg-subtle",
37
- icon: f
38
+ icon: d
38
39
  },
39
40
  FAILED: {
40
41
  label: "Failed",
@@ -54,106 +55,106 @@ var T = {
54
55
  RATE_LIMITED: {
55
56
  label: "Rate Limited",
56
57
  color: "text-status-warning-text bg-status-warning-bg-subtle",
57
- icon: m
58
+ icon: p
58
59
  },
59
60
  RETRYING: {
60
61
  label: "Retrying",
61
62
  color: "text-accent-primary bg-accent-primary/10",
62
- icon: _
63
+ icon: g
63
64
  },
64
65
  OPENED: {
65
66
  label: "Opened",
66
67
  color: "text-status-success-text bg-status-success-bg-subtle",
67
- icon: f
68
+ icon: d
68
69
  },
69
70
  CLICKED: {
70
71
  label: "Clicked",
71
72
  color: "text-status-success-text bg-status-success-bg-subtle",
72
- icon: f
73
+ icon: d
73
74
  }
74
75
  };
75
76
  function E() {
76
- let { channelId: f } = x(), m = b(), { t: y } = l(), E = (e, t) => {
77
- let n = y(e);
77
+ let { channelId: d } = re(), p = ne(), { hasPermission: v } = b(), y = v(r.CHANNEL_DELIVERY_EXPORT), { t: E } = l(), D = (e, t) => {
78
+ let n = E(e);
78
79
  return n === e ? t : n;
79
- }, { organizationId: D } = e(), { triggerExport: re, isExporting: O, exportError: k } = i(D ?? void 0, f), [A, j] = c(!0), [M, N] = c([]), [P, F] = c(null), [I, L] = c(null), [R, z] = c(25), [B, V] = c(0), [H, U] = c([void 0]), [W, G] = c(0), { channel: K, isLoading: q, error: J, fetchDeliveryAttempts: Y, retryDelivery: ie } = t(f), X = a(async (e) => {
80
- if (f) {
81
- j(!0), L(null);
80
+ }, { organizationId: O } = e(), { triggerExport: k, isExporting: A, exportError: j } = i(O ?? void 0, d), [M, N] = c(!0), [P, se] = c([]), [F, I] = c(null), [L, R] = c(null), [z, B] = c(25), [V, H] = c(0), [U, W] = c([void 0]), [G, K] = c(0), { channel: q, isLoading: ce, error: J, fetchDeliveryAttempts: Y, retryDelivery: le } = t(d), X = a(async (e) => {
81
+ if (d) {
82
+ N(!0), R(null);
82
83
  try {
83
- let t = await Y(R, e);
84
- return N(t.items), V(t.total), t.nextCursor;
84
+ let t = await Y(z, e);
85
+ return se(t.items), H(t.total), t.nextCursor;
85
86
  } finally {
86
- j(!1);
87
+ N(!1);
87
88
  }
88
89
  }
89
90
  }, [
90
- f,
91
+ d,
91
92
  Y,
92
- R
93
- ]), Z = s(X), Q = s(H);
93
+ z
94
+ ]), Z = s(X), Q = s(U);
94
95
  o(() => {
95
- Z.current = X, Q.current = H;
96
+ Z.current = X, Q.current = U;
96
97
  });
97
98
  let $ = s(!0);
98
99
  o(() => {
99
100
  Promise.resolve().then(() => {
100
- U([void 0]), G(0), Z.current(void 0);
101
+ W([void 0]), K(0), Z.current(void 0);
101
102
  });
102
- }, [R]), o(() => {
103
+ }, [z]), o(() => {
103
104
  if ($.current) {
104
105
  $.current = !1;
105
106
  return;
106
107
  }
107
- Promise.resolve().then(() => Z.current(Q.current[W]));
108
- }, [W]), o(() => {
109
- if (!f || W !== 0) return;
108
+ Promise.resolve().then(() => Z.current(Q.current[G]));
109
+ }, [G]), o(() => {
110
+ if (!d || G !== 0) return;
110
111
  let e = setInterval(() => {
111
112
  X(void 0);
112
113
  }, 6e4);
113
114
  return () => clearInterval(e);
114
115
  }, [
115
- f,
116
- W,
116
+ d,
117
+ G,
117
118
  X
118
119
  ]);
119
- let ae = a(async () => {
120
- let e = await X(H[W]);
121
- e && U((t) => {
120
+ let ue = a(async () => {
121
+ let e = await X(U[G]);
122
+ e && W((t) => {
122
123
  let n = [...t];
123
- return n[W + 1] || (n[W + 1] = e), n;
124
- }), G((e) => e + 1);
124
+ return n[G + 1] || (n[G + 1] = e), n;
125
+ }), K((e) => e + 1);
125
126
  }, [
126
- H,
127
- W,
127
+ U,
128
+ G,
128
129
  X
129
- ]), oe = a(() => {
130
- let e = W - 1;
131
- G(e), X(H[e]);
130
+ ]), de = a(() => {
131
+ let e = G - 1;
132
+ K(e), X(U[e]);
132
133
  }, [
133
- H,
134
- W,
134
+ U,
135
+ G,
135
136
  X
136
- ]), se = M.length === R, ce = W > 0, le = async (e) => {
137
- F(e), L(null);
137
+ ]), fe = P.length === z, pe = G > 0, me = async (e) => {
138
+ I(e), R(null);
138
139
  try {
139
- let t = await ie(e);
140
- t.success ? await X(H[W]) : L(t.error || "Retry failed");
140
+ let t = await le(e);
141
+ t.success ? await X(U[G]) : R(t.error || "Retry failed");
141
142
  } finally {
142
- F(null);
143
+ I(null);
143
144
  }
144
- }, ue = (e) => T[e] || T.PENDING, de = [
145
+ }, he = (e) => T[e] || T.PENDING, ge = [
145
146
  {
146
147
  key: "status",
147
- header: E("channel.status", "Status"),
148
+ header: D("channel.status", "Status"),
148
149
  priority: "primary",
149
150
  cell: (e) => {
150
- let t = ue(e.status), n = t.icon;
151
- return /* @__PURE__ */ C("div", {
151
+ let t = he(e.status), n = t.icon;
152
+ return /* @__PURE__ */ S("div", {
152
153
  className: "flex items-center gap-2",
153
- children: [/* @__PURE__ */ S(n, {
154
+ children: [/* @__PURE__ */ x(n, {
154
155
  size: 14,
155
156
  className: t.color.split(" ")[0]
156
- }), /* @__PURE__ */ S("span", {
157
+ }), /* @__PURE__ */ x("span", {
157
158
  className: `text-sm font-medium ${t.color}`,
158
159
  children: t.label
159
160
  })]
@@ -162,260 +163,244 @@ function E() {
162
163
  },
163
164
  {
164
165
  key: "content",
165
- header: E("channel.content", "Content"),
166
+ header: D("channel.content", "Content"),
166
167
  priority: "primary",
167
168
  cellClassName: "text-sm text-text-primary truncate max-w-xs",
168
169
  cell: (e) => e.content
169
170
  },
170
171
  {
171
172
  key: "sentAt",
172
- header: E("channel.sentAt", "Sent At"),
173
+ header: D("channel.sentAt", "Sent At"),
173
174
  priority: "secondary",
174
175
  cellClassName: "text-sm text-text-secondary",
175
176
  cell: (e) => e.sentAt ? new Date(e.sentAt).toLocaleString() : "-"
176
177
  },
177
178
  {
178
179
  key: "retries",
179
- header: E("channel.retries", "Retries"),
180
+ header: D("channel.retries", "Retries"),
180
181
  priority: "secondary",
181
182
  cellClassName: "text-sm text-text-secondary tabular-nums",
182
183
  cell: (e) => e.retryCount
183
184
  },
184
185
  {
185
186
  key: "error",
186
- header: E("channel.error", "Error"),
187
+ header: D("channel.error", "Error"),
187
188
  priority: "secondary",
188
189
  cellClassName: "text-sm text-status-error-text max-w-xs truncate",
189
190
  cell: (e) => e.errorMessage || "-"
190
191
  },
191
192
  {
192
193
  key: "actions",
193
- header: E("channel.actions", "Actions"),
194
+ header: D("channel.actions", "Actions"),
194
195
  priority: "secondary",
195
- cell: (e) => e.status === "FAILED" || e.status === "BOUNCED" || e.status === "REJECTED" ? /* @__PURE__ */ S(n, {
196
+ cell: (e) => e.status === "FAILED" || e.status === "BOUNCED" || e.status === "REJECTED" ? /* @__PURE__ */ x(n, {
196
197
  permission: r.CHANNEL_DELIVERY_EXECUTE,
197
- children: /* @__PURE__ */ C("button", {
198
+ children: /* @__PURE__ */ S("button", {
198
199
  type: "button",
199
- onClick: () => le(e.id),
200
- disabled: P === e.id,
200
+ onClick: () => me(e.id),
201
+ disabled: F === e.id,
201
202
  className: "flex items-center gap-1 px-2 py-1 text-xs font-medium text-accent-primary hover:bg-accent-primary/10 rounded transition-colors disabled:opacity-50",
202
- title: E("channel.retryDelivery", "Retry this delivery"),
203
- children: [/* @__PURE__ */ S(te, {
203
+ title: D("channel.retryDelivery", "Retry this delivery"),
204
+ children: [/* @__PURE__ */ x(_, {
204
205
  size: 12,
205
- className: P === e.id ? "animate-spin" : ""
206
- }), P === e.id ? E("channel.retrying", "Retrying...") : E("channel.retry", "Retry")]
206
+ className: F === e.id ? "animate-spin" : ""
207
+ }), F === e.id ? D("channel.retrying", "Retrying...") : D("channel.retry", "Retry")]
207
208
  })
208
209
  }) : null
209
210
  }
210
211
  ];
211
- return q ? /* @__PURE__ */ S("output", {
212
+ return ce ? /* @__PURE__ */ x("output", {
212
213
  className: "flex items-center justify-center min-h-screen",
213
- "aria-label": E("channel.loading", "Loading"),
214
- children: /* @__PURE__ */ S(g, {
214
+ "aria-label": D("channel.loading", "Loading"),
215
+ children: /* @__PURE__ */ x(h, {
215
216
  size: 32,
216
217
  className: "animate-spin text-accent-primary",
217
218
  "aria-hidden": "true"
218
219
  })
219
- }) : J || !K ? /* @__PURE__ */ S("div", {
220
+ }) : J || !q ? /* @__PURE__ */ x("div", {
220
221
  className: "p-6",
221
- children: /* @__PURE__ */ C("div", {
222
+ children: /* @__PURE__ */ S("div", {
222
223
  className: "flex items-center gap-3 p-4 bg-status-error-bg-subtle border border-status-error-border rounded-lg",
223
224
  children: [
224
- /* @__PURE__ */ S(u, {
225
+ /* @__PURE__ */ x(u, {
225
226
  size: 20,
226
227
  className: "text-status-error-text"
227
228
  }),
228
- /* @__PURE__ */ S("div", { children: /* @__PURE__ */ S("p", {
229
+ /* @__PURE__ */ x("div", { children: /* @__PURE__ */ x("p", {
229
230
  className: "text-sm font-medium text-status-error-text",
230
231
  children: J || "Channel not found"
231
232
  }) }),
232
- /* @__PURE__ */ S("button", {
233
+ /* @__PURE__ */ x("button", {
233
234
  type: "button",
234
- onClick: () => m(`/channels/${f}`),
235
+ onClick: () => p(`/channels/${d}`),
235
236
  className: "ml-auto px-3 py-1 text-sm text-status-error-text hover:bg-status-error-bg-subtle rounded transition-colors",
236
237
  children: "Go Back"
237
238
  })
238
239
  ]
239
240
  })
240
- }) : /* @__PURE__ */ S(n, {
241
+ }) : /* @__PURE__ */ x(n, {
241
242
  permission: r.CHANNEL_DELIVERY_READ,
242
- children: /* @__PURE__ */ C("div", {
243
+ children: /* @__PURE__ */ S("div", {
243
244
  className: "space-y-6 p-3 sm:p-6",
244
245
  children: [
245
- /* @__PURE__ */ C("div", {
246
+ /* @__PURE__ */ S("div", {
246
247
  className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",
247
- children: [/* @__PURE__ */ C("div", {
248
+ children: [/* @__PURE__ */ S("div", {
248
249
  className: "flex items-center gap-3",
249
- children: [/* @__PURE__ */ S("button", {
250
+ children: [/* @__PURE__ */ x("button", {
250
251
  type: "button",
251
- onClick: () => m(`/channels/${f}`),
252
- "aria-label": E("channel.backToChannel", "Back to channel"),
252
+ onClick: () => p(`/channels/${d}`),
253
+ "aria-label": D("channel.backToChannel", "Back to channel"),
253
254
  className: "p-2 text-text-secondary hover:text-text-primary hover:bg-bg-sunken rounded-lg transition-colors",
254
- children: /* @__PURE__ */ S(d, {
255
+ children: /* @__PURE__ */ x(ee, {
255
256
  size: 20,
256
257
  "aria-hidden": "true"
257
258
  })
258
- }), /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("h1", {
259
+ }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("h1", {
259
260
  className: "text-xl sm:text-2xl font-bold text-text-primary",
260
- children: E("channel.deliveryHistory", "Delivery History")
261
- }), /* @__PURE__ */ C("p", {
261
+ children: D("channel.deliveryHistory", "Delivery History")
262
+ }), /* @__PURE__ */ S("p", {
262
263
  className: "text-sm text-text-secondary mt-1",
263
- children: [K.name, " - Message deliveries"]
264
+ children: [q.name, " - Message deliveries"]
264
265
  })] })]
265
- }), /* @__PURE__ */ C("div", {
266
+ }), /* @__PURE__ */ S("div", {
266
267
  className: "flex items-center gap-3",
267
- children: [
268
- /* @__PURE__ */ C("select", {
269
- value: R,
270
- onChange: (e) => z(Number(e.target.value)),
271
- className: "px-3 py-2 text-sm bg-surface border border-border-subtle rounded-lg focus:outline-none focus:ring-2 focus:ring-action-primary-bg/50 text-text-primary",
272
- children: [
273
- /* @__PURE__ */ S("option", {
274
- value: 10,
275
- children: "10 results"
276
- }),
277
- /* @__PURE__ */ S("option", {
278
- value: 25,
279
- children: "25 results"
280
- }),
281
- /* @__PURE__ */ S("option", {
282
- value: 50,
283
- children: "50 results"
284
- }),
285
- /* @__PURE__ */ S("option", {
286
- value: 100,
287
- children: "100 results"
288
- })
289
- ]
268
+ children: [/* @__PURE__ */ S("select", {
269
+ value: z,
270
+ onChange: (e) => B(Number(e.target.value)),
271
+ className: "px-3 py-2 text-sm bg-surface border border-border-subtle rounded-lg focus:outline-none focus:ring-2 focus:ring-action-primary-bg/50 text-text-primary",
272
+ children: [
273
+ /* @__PURE__ */ x("option", {
274
+ value: 10,
275
+ children: "10 results"
276
+ }),
277
+ /* @__PURE__ */ x("option", {
278
+ value: 25,
279
+ children: "25 results"
280
+ }),
281
+ /* @__PURE__ */ x("option", {
282
+ value: 50,
283
+ children: "50 results"
284
+ }),
285
+ /* @__PURE__ */ x("option", {
286
+ value: 100,
287
+ children: "100 results"
288
+ })
289
+ ]
290
+ }), /* @__PURE__ */ x(ae, { actions: [{
291
+ label: D("channel.refresh", "Refresh"),
292
+ icon: /* @__PURE__ */ x(g, {
293
+ size: 16,
294
+ className: M ? "animate-spin" : "",
295
+ "aria-hidden": "true"
290
296
  }),
291
- /* @__PURE__ */ C("button", {
292
- type: "button",
293
- onClick: () => void X(H[W]),
294
- disabled: A,
295
- className: "flex items-center gap-2 px-4 py-2 text-sm font-medium text-text-secondary hover:text-text-primary hover:bg-bg-sunken rounded-lg transition-colors disabled:opacity-50",
296
- children: [/* @__PURE__ */ S(_, {
297
- size: 16,
298
- className: A ? "animate-spin" : ""
299
- }), E("channel.refresh", "Refresh")]
297
+ disabled: M,
298
+ onSelect: () => void X(U[G])
299
+ }, ...y ? [{
300
+ label: D("channel.export", "Export"),
301
+ icon: A ? /* @__PURE__ */ x(h, {
302
+ size: 16,
303
+ className: "animate-spin",
304
+ "aria-hidden": "true"
305
+ }) : /* @__PURE__ */ x(m, {
306
+ size: 16,
307
+ "aria-hidden": "true"
300
308
  }),
301
- /* @__PURE__ */ S(n, {
302
- permission: r.CHANNEL_DELIVERY_EXPORT,
303
- children: /* @__PURE__ */ C("button", {
304
- type: "button",
305
- onClick: () => void re(),
306
- disabled: O,
307
- className: "flex items-center gap-2 px-4 py-2 text-sm font-medium text-fg border border-border-subtle hover:bg-bg-elevated rounded-lg transition-colors disabled:opacity-50 disabled:cursor-not-allowed",
308
- title: E("channel.exportCSV", "Export to CSV"),
309
- children: [O ? /* @__PURE__ */ S(g, {
310
- size: 16,
311
- className: "animate-spin"
312
- }) : /* @__PURE__ */ S(h, { size: 16 }), E("channel.export", "Export")]
313
- })
314
- })
315
- ]
309
+ disabled: A,
310
+ onSelect: () => void k()
311
+ }] : []] })]
316
312
  })]
317
313
  }),
318
- k && /* @__PURE__ */ C("div", {
314
+ j && /* @__PURE__ */ S("div", {
319
315
  className: "p-4 bg-status-error-bg-subtle border border-status-error-border rounded-lg flex items-center gap-3",
320
- children: [/* @__PURE__ */ S(u, {
316
+ children: [/* @__PURE__ */ x(u, {
321
317
  size: 20,
322
318
  className: "text-status-error-text"
323
- }), /* @__PURE__ */ S("p", {
319
+ }), /* @__PURE__ */ x("p", {
324
320
  className: "text-sm text-status-error-text flex-1",
325
- children: k
321
+ children: j
326
322
  })]
327
323
  }),
328
- I && /* @__PURE__ */ C("div", {
324
+ L && /* @__PURE__ */ S("div", {
329
325
  className: "p-4 bg-status-error-bg-subtle border border-status-error-border rounded-lg flex items-center gap-3",
330
326
  children: [
331
- /* @__PURE__ */ S(u, {
327
+ /* @__PURE__ */ x(u, {
332
328
  size: 20,
333
329
  className: "text-status-error-text"
334
330
  }),
335
- /* @__PURE__ */ S("p", {
331
+ /* @__PURE__ */ x("p", {
336
332
  className: "text-sm text-status-error-text flex-1",
337
- children: I
333
+ children: L
338
334
  }),
339
- /* @__PURE__ */ S("button", {
335
+ /* @__PURE__ */ x("button", {
340
336
  type: "button",
341
- onClick: () => L(null),
337
+ onClick: () => R(null),
342
338
  className: "text-status-error-text hover:text-status-error-text",
343
- children: E("channel.dismiss", "Dismiss")
339
+ children: D("channel.dismiss", "Dismiss")
344
340
  })
345
341
  ]
346
342
  }),
347
- /* @__PURE__ */ S("div", {
348
- className: "p-4 bg-surface border border-border-subtle rounded-lg",
349
- children: /* @__PURE__ */ S("p", {
343
+ /* @__PURE__ */ x(oe, {
344
+ treatment: "insight",
345
+ className: "p-4 border-border-seam",
346
+ children: /* @__PURE__ */ x("p", {
350
347
  className: "text-sm text-text-secondary",
351
348
  children: "Delivery history shows all message attempts sent through this channel. Data is retained for 7 days. Click retry on a failed delivery to attempt sending again."
352
349
  })
353
350
  }),
354
- A ? /* @__PURE__ */ C("div", {
355
- className: "bg-surface border border-border-subtle rounded-lg px-4 py-12 text-center",
356
- children: [/* @__PURE__ */ S(g, {
351
+ M ? /* @__PURE__ */ S("div", {
352
+ className: "bg-surface border border-border-seam rounded-lg px-4 py-12 text-center",
353
+ children: [/* @__PURE__ */ x(h, {
357
354
  size: 24,
358
355
  className: "animate-spin text-accent-primary mx-auto"
359
- }), /* @__PURE__ */ S("p", {
356
+ }), /* @__PURE__ */ x("p", {
360
357
  className: "text-sm text-text-secondary mt-2",
361
358
  children: "Loading delivery attempts…"
362
359
  })]
363
- }) : /* @__PURE__ */ S(w, {
364
- columns: de,
365
- data: M,
360
+ }) : /* @__PURE__ */ x(w, {
361
+ columns: ge,
362
+ data: P,
366
363
  rowKey: (e) => e.id,
367
- className: "bg-surface border border-border-subtle rounded-lg",
368
- emptyState: /* @__PURE__ */ C("div", {
369
- className: "flex flex-col items-center gap-2 py-8",
370
- children: [
371
- /* @__PURE__ */ S(v, {
372
- size: 32,
373
- className: "text-text-secondary"
374
- }),
375
- /* @__PURE__ */ S("p", {
376
- className: "text-sm font-medium text-text-primary",
377
- children: E("channel.noDeliveryAttempts", "No delivery attempts yet")
378
- }),
379
- /* @__PURE__ */ S("p", {
380
- className: "text-xs text-text-secondary",
381
- children: E("channel.sendMessageToSeeHistory", "Send a message through this channel to see delivery history")
382
- })
383
- ]
364
+ className: "bg-surface border border-border-seam rounded-lg",
365
+ emptyState: /* @__PURE__ */ x(C, {
366
+ illustration: "empty-notifications",
367
+ title: D("channel.noDeliveryAttempts", "No delivery attempts yet"),
368
+ description: D("channel.sendMessageToSeeHistory", "Send a message through this channel to see delivery history")
384
369
  })
385
370
  }),
386
- /* @__PURE__ */ C("div", {
371
+ /* @__PURE__ */ S("div", {
387
372
  className: "flex items-center justify-between",
388
- children: [/* @__PURE__ */ S("p", {
373
+ children: [/* @__PURE__ */ x("p", {
389
374
  className: "text-sm text-text-secondary",
390
- children: B > 0 && /* @__PURE__ */ C(ne, { children: [
391
- E("channel.page", "Page"),
375
+ children: V > 0 && /* @__PURE__ */ S(ie, { children: [
376
+ D("channel.page", "Page"),
392
377
  " ",
393
- /* @__PURE__ */ S("span", {
378
+ /* @__PURE__ */ x("span", {
394
379
  className: "font-medium",
395
- children: W + 1
380
+ children: G + 1
396
381
  }),
397
382
  " · ",
398
- E("channel.totalRecords", "Total"),
383
+ D("channel.totalRecords", "Total"),
399
384
  ": ",
400
- /* @__PURE__ */ S("span", {
385
+ /* @__PURE__ */ x("span", {
401
386
  className: "font-medium",
402
- children: B
387
+ children: V
403
388
  })
404
389
  ] })
405
- }), /* @__PURE__ */ C("div", {
390
+ }), /* @__PURE__ */ S("div", {
406
391
  className: "flex items-center gap-2",
407
- children: [/* @__PURE__ */ C("button", {
392
+ children: [/* @__PURE__ */ S("button", {
408
393
  type: "button",
409
- onClick: oe,
410
- disabled: !ce || A,
394
+ onClick: de,
395
+ disabled: !pe || M,
411
396
  className: "flex items-center gap-1 px-3 py-1.5 text-sm border border-border-subtle rounded-lg hover:bg-bg-sunken transition-colors disabled:opacity-40 disabled:cursor-not-allowed",
412
- children: [/* @__PURE__ */ S(ee, { size: 16 }), E("channel.previous", "Previous")]
413
- }), /* @__PURE__ */ C("button", {
397
+ children: [/* @__PURE__ */ x(te, { size: 16 }), D("channel.previous", "Previous")]
398
+ }), /* @__PURE__ */ S("button", {
414
399
  type: "button",
415
- onClick: () => void ae(),
416
- disabled: !se || A,
400
+ onClick: () => void ue(),
401
+ disabled: !fe || M,
417
402
  className: "flex items-center gap-1 px-3 py-1.5 text-sm border border-border-subtle rounded-lg hover:bg-bg-sunken transition-colors disabled:opacity-40 disabled:cursor-not-allowed",
418
- children: [E("channel.next", "Next"), /* @__PURE__ */ S(p, { size: 16 })]
403
+ children: [D("channel.next", "Next"), /* @__PURE__ */ x(f, { size: 16 })]
419
404
  })]
420
405
  })]
421
406
  })