@burdenoff/microfe-notification 2026.1124.1 → 2026.1127.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/AdminNotificationRoutes.js +59 -51
- package/dist/AdminNotificationRoutes.js.map +1 -1
- package/dist/NotificationRoutes.js +76 -68
- package/dist/NotificationRoutes.js.map +1 -1
- package/dist/UserNotificationRoutes.js +39 -31
- package/dist/UserNotificationRoutes.js.map +1 -1
- package/dist/components/NotificationListFooter.js +1 -1
- package/dist/components/NotificationListFooter.js.map +1 -1
- package/dist/components/NotificationPanel.js +0 -1
- package/dist/components/NotificationPanel.js.map +1 -1
- package/dist/components/loadingSystem.d.ts +64 -0
- package/dist/components/loadingSystem.js +34 -0
- package/dist/components/loadingSystem.js.map +1 -0
- package/dist/graphql/global-client.js +34 -34
- package/dist/index.js +9 -11
- package/dist/navigation-v2/AdminPageV2.js +23 -16
- package/dist/navigation-v2/AdminPageV2.js.map +1 -1
- package/dist/navigation-v2/NotificationArchivedV2.js +104 -98
- package/dist/navigation-v2/NotificationArchivedV2.js.map +1 -1
- package/dist/navigation-v2/NotificationInboxV2.js +133 -127
- package/dist/navigation-v2/NotificationInboxV2.js.map +1 -1
- package/dist/navigation-v2/NotificationSettingsV2.js +91 -85
- package/dist/navigation-v2/NotificationSettingsV2.js.map +1 -1
- package/dist/navigation-v2/NotificationsV2Landing.js +31 -23
- package/dist/navigation-v2/NotificationsV2Landing.js.map +1 -1
- package/dist/pages/CreateNotificationPage.js +442 -432
- package/dist/pages/CreateNotificationPage.js.map +1 -1
- package/dist/pages/NotificationCenterPage.js +93 -87
- package/dist/pages/NotificationCenterPage.js.map +1 -1
- package/dist/pages/NotificationHistoryAdminPage.js +231 -225
- package/dist/pages/NotificationHistoryAdminPage.js.map +1 -1
- package/dist/pages/NotificationHistoryPage.js +72 -66
- package/dist/pages/NotificationHistoryPage.js.map +1 -1
- package/dist/pages/NotificationLandingPage.js +42 -34
- package/dist/pages/NotificationLandingPage.js.map +1 -1
- package/dist/pages/NotificationPreferencesPage.js +80 -71
- package/dist/pages/NotificationPreferencesPage.js.map +1 -1
- package/dist/pages/NotificationTemplatesPage.js +192 -181
- package/dist/pages/NotificationTemplatesPage.js.map +1 -1
- package/dist/pages/NotificationTopicsPage.js +124 -118
- package/dist/pages/NotificationTopicsPage.js.map +1 -1
- package/dist/pages/TemplateEditorPage.js +248 -233
- package/dist/pages/TemplateEditorPage.js.map +1 -1
- package/package.json +5 -2
- package/dist/components/index.js +0 -4
- package/dist/hooks/index.js +0 -8
- package/dist/node_modules/@apollo/client/errors/CombinedGraphQLErrors.js +0 -23
- package/dist/node_modules/@apollo/client/errors/CombinedGraphQLErrors.js.map +0 -1
- package/dist/node_modules/@apollo/client/errors/utils.js +0 -15
- package/dist/node_modules/@apollo/client/errors/utils.js.map +0 -1
- package/dist/node_modules/@apollo/client/link/core/ApolloLink.js +0 -51
- package/dist/node_modules/@apollo/client/link/core/ApolloLink.js.map +0 -1
- package/dist/node_modules/@apollo/client/link/subscriptions/index.js +0 -40
- package/dist/node_modules/@apollo/client/link/subscriptions/index.js.map +0 -1
- package/dist/node_modules/@apollo/client/link/utils/createOperation.js +0 -33
- package/dist/node_modules/@apollo/client/link/utils/createOperation.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/caching/sizes.js +0 -5
- package/dist/node_modules/@apollo/client/utilities/caching/sizes.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/graphql/print.js +0 -15
- package/dist/node_modules/@apollo/client/utilities/graphql/print.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/caches.js +0 -18
- package/dist/node_modules/@apollo/client/utilities/internal/caches.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/checkDocument.js +0 -20
- package/dist/node_modules/@apollo/client/utilities/internal/checkDocument.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getMainDefinition.js +0 -16
- package/dist/node_modules/@apollo/client/utilities/internal/getMainDefinition.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getMemoryInternals.js +0 -8
- package/dist/node_modules/@apollo/client/utilities/internal/getMemoryInternals.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationDefinition.js +0 -8
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationDefinition.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationName.js +0 -7
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationName.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/globals/global.js +0 -8
- package/dist/node_modules/@apollo/client/utilities/internal/globals/global.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/globals/maybe.js +0 -9
- package/dist/node_modules/@apollo/client/utilities/internal/globals/maybe.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/isNonNullObject.js +0 -7
- package/dist/node_modules/@apollo/client/utilities/internal/isNonNullObject.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/makeUniqueId.js +0 -9
- package/dist/node_modules/@apollo/client/utilities/internal/makeUniqueId.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/memoize.js +0 -22
- package/dist/node_modules/@apollo/client/utilities/internal/memoize.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/stringifyForDisplay.js +0 -9
- package/dist/node_modules/@apollo/client/utilities/internal/stringifyForDisplay.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/invariant/index.js +0 -56
- package/dist/node_modules/@apollo/client/utilities/invariant/index.js.map +0 -1
- package/dist/node_modules/@apollo/client/version.js +0 -5
- package/dist/node_modules/@apollo/client/version.js.map +0 -1
- package/dist/node_modules/@wry/caches/lib/weak.js +0 -66
- package/dist/node_modules/@wry/caches/lib/weak.js.map +0 -1
- package/dist/node_modules/@wry/trie/lib/index.js +0 -52
- package/dist/node_modules/@wry/trie/lib/index.js.map +0 -1
- package/dist/node_modules/graphql-ws/dist/client.js +0 -279
- package/dist/node_modules/graphql-ws/dist/client.js.map +0 -1
- package/dist/node_modules/graphql-ws/dist/common-CGW11Fyb.js +0 -61
- package/dist/node_modules/graphql-ws/dist/common-CGW11Fyb.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/NotificationFactories.js +0 -20
- package/dist/node_modules/rxjs/dist/esm5/internal/NotificationFactories.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/Observable.js +0 -77
- package/dist/node_modules/rxjs/dist/esm5/internal/Observable.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/Subscriber.js +0 -116
- package/dist/node_modules/rxjs/dist/esm5/internal/Subscriber.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/Subscription.js +0 -96
- package/dist/node_modules/rxjs/dist/esm5/internal/Subscription.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/config.js +0 -11
- package/dist/node_modules/rxjs/dist/esm5/internal/config.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/observable/empty.js +0 -8
- package/dist/node_modules/rxjs/dist/esm5/internal/observable/empty.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/scheduler/timeoutProvider.js +0 -15
- package/dist/node_modules/rxjs/dist/esm5/internal/scheduler/timeoutProvider.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/symbol/observable.js +0 -7
- package/dist/node_modules/rxjs/dist/esm5/internal/symbol/observable.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/UnsubscriptionError.js +0 -12
- package/dist/node_modules/rxjs/dist/esm5/internal/util/UnsubscriptionError.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/arrRemove.js +0 -10
- package/dist/node_modules/rxjs/dist/esm5/internal/util/arrRemove.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/createErrorClass.js +0 -10
- package/dist/node_modules/rxjs/dist/esm5/internal/util/createErrorClass.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/errorContext.js +0 -21
- package/dist/node_modules/rxjs/dist/esm5/internal/util/errorContext.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/identity.js +0 -7
- package/dist/node_modules/rxjs/dist/esm5/internal/util/identity.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/isFunction.js +0 -7
- package/dist/node_modules/rxjs/dist/esm5/internal/util/isFunction.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/noop.js +0 -5
- package/dist/node_modules/rxjs/dist/esm5/internal/util/noop.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/pipe.js +0 -12
- package/dist/node_modules/rxjs/dist/esm5/internal/util/pipe.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/reportUnhandledError.js +0 -13
- package/dist/node_modules/rxjs/dist/esm5/internal/util/reportUnhandledError.js.map +0 -1
- package/dist/node_modules/tslib/tslib.es6.js +0 -51
- package/dist/node_modules/tslib/tslib.es6.js.map +0 -1
|
@@ -1,307 +1,313 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import "../hooks/index.js";
|
|
1
|
+
import { NotificationCard as e } from "../components/NotificationCard.js";
|
|
2
|
+
import { useNotificationAdmin as t } from "../hooks/useNotificationAdmin.js";
|
|
3
|
+
import { useNotificationTopics as n } from "../hooks/useNotificationTopics.js";
|
|
5
4
|
import { NOTIFICATION_PERMISSIONS as r } from "../constants/permissions.js";
|
|
6
5
|
import { useTr as i } from "../shared/hooks/useTr.js";
|
|
7
6
|
import { exportNotificationsAsCsv as a } from "../utils/notificationHistoryExport.js";
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
7
|
+
import { CompactMarkOr as o, SectionLoaderOr as s } from "../components/loadingSystem.js";
|
|
8
|
+
import { useState as c } from "react";
|
|
9
|
+
import { usePermissions as l } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
10
|
+
import { CalendarClock as u, Download as d, RefreshCw as f, Search as p } from "lucide-react";
|
|
11
|
+
import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
|
|
12
|
+
import { Button as _, EmphasisPanel as v, GlassCard as y, IllustratedEmptyState as b, NextSteps as x, PagePurpose as S, ShowMore as C, ThemedSelect as w } from "@burdenoff/fe-libs/ui";
|
|
13
13
|
// src/pages/NotificationHistoryAdminPage.tsx
|
|
14
|
-
function
|
|
14
|
+
function T(e) {
|
|
15
15
|
return e ? new Date(e).toLocaleString() : "—";
|
|
16
16
|
}
|
|
17
|
-
function
|
|
18
|
-
let
|
|
19
|
-
return
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
function E() {
|
|
18
|
+
let E = i(), { hasPermission: D, isLoading: O } = l(), { topics: k } = n(), { filters: A, setFilters: j, notifications: M, scheduledNotifications: N, selectedNotification: P, events: F, isLoading: I, loadNotification: L, archiveNotification: R, unarchiveNotification: z, cancelScheduledNotification: B, rescheduleNotification: V, clearSelection: H } = t(), [U, W] = c("");
|
|
19
|
+
return O ? /* @__PURE__ */ h(s, {
|
|
20
|
+
minHeight: "16rem",
|
|
21
|
+
today: /* @__PURE__ */ h("div", {
|
|
22
|
+
className: "flex h-64 items-center justify-center",
|
|
23
|
+
children: /* @__PURE__ */ h(o, {
|
|
24
|
+
className: "h-8 w-8",
|
|
25
|
+
today: /* @__PURE__ */ h("div", { className: "h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent" })
|
|
26
|
+
})
|
|
27
|
+
})
|
|
28
|
+
}) : D(r.NOTIFICATION_LIST) ? /* @__PURE__ */ g("div", {
|
|
23
29
|
className: "space-y-4 sm:space-y-6",
|
|
24
30
|
children: [
|
|
25
|
-
/* @__PURE__ */
|
|
26
|
-
icon: /* @__PURE__ */
|
|
27
|
-
children:
|
|
31
|
+
/* @__PURE__ */ h(S, {
|
|
32
|
+
icon: /* @__PURE__ */ h(u, { size: 16 }),
|
|
33
|
+
children: E("notifications.adminHistoryPurpose", "The operations console for everything your team has sent. Audit delivery outcomes (delivered, opened, clicked, failed, unsubscribed), inspect a single notification’s full event timeline, and manage the schedule — reschedule or cancel anything still pending. Use it to debug a campaign or prove a notification went out.")
|
|
28
34
|
}),
|
|
29
|
-
/* @__PURE__ */
|
|
35
|
+
/* @__PURE__ */ h(x, {
|
|
30
36
|
storageKey: "notification-admin-history",
|
|
31
37
|
steps: [
|
|
32
38
|
{
|
|
33
39
|
id: "inspect",
|
|
34
|
-
label:
|
|
35
|
-
description:
|
|
40
|
+
label: E("notifications.nextInspectLabel", "Inspect a delivery"),
|
|
41
|
+
description: E("notifications.nextInspectDesc", "Click any notification to see its receipts, opens, clicks and full event timeline."),
|
|
36
42
|
onClick: () => {
|
|
37
|
-
|
|
43
|
+
M[0] && L(M[0].id);
|
|
38
44
|
}
|
|
39
45
|
},
|
|
40
46
|
{
|
|
41
47
|
id: "failed",
|
|
42
|
-
label:
|
|
43
|
-
description:
|
|
44
|
-
onClick: () =>
|
|
48
|
+
label: E("notifications.nextFailedLabel", "Find failed deliveries"),
|
|
49
|
+
description: E("notifications.nextFailedDesc", "Filter by a FAILED delivery state to triage what did not reach recipients."),
|
|
50
|
+
onClick: () => j((e) => ({
|
|
45
51
|
...e,
|
|
46
52
|
deliveryStatus: "FAILED"
|
|
47
53
|
}))
|
|
48
54
|
},
|
|
49
55
|
{
|
|
50
56
|
id: "export",
|
|
51
|
-
label:
|
|
52
|
-
description:
|
|
57
|
+
label: E("notifications.nextExportLabel", "Export the current view"),
|
|
58
|
+
description: E("notifications.nextExportDesc", "Download the filtered results as CSV for reporting or an external audit."),
|
|
53
59
|
onClick: () => {
|
|
54
|
-
|
|
60
|
+
M.length > 0 && a(E, M);
|
|
55
61
|
}
|
|
56
62
|
}
|
|
57
63
|
]
|
|
58
64
|
}),
|
|
59
|
-
/* @__PURE__ */
|
|
65
|
+
/* @__PURE__ */ g("div", {
|
|
60
66
|
className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",
|
|
61
|
-
children: [/* @__PURE__ */
|
|
67
|
+
children: [/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h1", {
|
|
62
68
|
className: "text-xl sm:text-2xl font-bold text-primary",
|
|
63
|
-
children:
|
|
64
|
-
}), /* @__PURE__ */
|
|
69
|
+
children: E("notifications.adminHistoryTitle", "Notification Operations")
|
|
70
|
+
}), /* @__PURE__ */ h("p", {
|
|
65
71
|
className: "text-sm text-text-secondary mt-1",
|
|
66
|
-
children:
|
|
67
|
-
})] }), /* @__PURE__ */
|
|
72
|
+
children: E("notifications.adminHistorySubtitle", "Review sent and scheduled notifications, delivery outcomes, opens, clicks, and user activity.")
|
|
73
|
+
})] }), /* @__PURE__ */ g(_, {
|
|
68
74
|
type: "button",
|
|
69
75
|
variant: "outline",
|
|
70
|
-
onClick: () => a(
|
|
71
|
-
disabled:
|
|
76
|
+
onClick: () => a(E, M),
|
|
77
|
+
disabled: M.length === 0,
|
|
72
78
|
className: "gap-2",
|
|
73
|
-
children: [/* @__PURE__ */
|
|
79
|
+
children: [/* @__PURE__ */ h(d, { size: 16 }), E("notifications.export", "Export")]
|
|
74
80
|
})]
|
|
75
81
|
}),
|
|
76
|
-
/* @__PURE__ */
|
|
82
|
+
/* @__PURE__ */ g(y, {
|
|
77
83
|
treatment: "plain",
|
|
78
84
|
className: "grid gap-3 border-border-seam p-4 lg:grid-cols-6",
|
|
79
85
|
children: [
|
|
80
|
-
/* @__PURE__ */
|
|
86
|
+
/* @__PURE__ */ g("label", {
|
|
81
87
|
className: "relative lg:col-span-2",
|
|
82
|
-
children: [/* @__PURE__ */ p
|
|
88
|
+
children: [/* @__PURE__ */ h(p, {
|
|
83
89
|
size: 16,
|
|
84
90
|
className: "absolute left-3 top-1/2 -translate-y-1/2 text-tertiary"
|
|
85
|
-
}), /* @__PURE__ */
|
|
91
|
+
}), /* @__PURE__ */ h("input", {
|
|
86
92
|
type: "text",
|
|
87
|
-
value:
|
|
88
|
-
onChange: (e) =>
|
|
93
|
+
value: A.search,
|
|
94
|
+
onChange: (e) => j((t) => ({
|
|
89
95
|
...t,
|
|
90
96
|
search: e.target.value
|
|
91
97
|
})),
|
|
92
|
-
placeholder:
|
|
98
|
+
placeholder: E("notifications.searchByTitleOrContent", "Search by title or content..."),
|
|
93
99
|
className: "w-full rounded-md border border-default bg-bg-canvas py-2 pl-9 pr-3 text-sm text-primary focus:outline-none focus:ring-2 focus:ring-accent"
|
|
94
100
|
})]
|
|
95
101
|
}),
|
|
96
|
-
/* @__PURE__ */
|
|
97
|
-
value:
|
|
98
|
-
onChange: (e) =>
|
|
102
|
+
/* @__PURE__ */ g(w, {
|
|
103
|
+
value: A.status,
|
|
104
|
+
onChange: (e) => j((t) => ({
|
|
99
105
|
...t,
|
|
100
106
|
status: e.target.value
|
|
101
107
|
})),
|
|
102
108
|
className: "rounded-md border border-default bg-bg-canvas px-3 py-2 text-sm text-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
103
109
|
children: [
|
|
104
|
-
/* @__PURE__ */
|
|
110
|
+
/* @__PURE__ */ h("option", {
|
|
105
111
|
value: "all",
|
|
106
|
-
children:
|
|
112
|
+
children: E("notifications.allStatuses", "All Statuses")
|
|
107
113
|
}),
|
|
108
|
-
/* @__PURE__ */
|
|
114
|
+
/* @__PURE__ */ h("option", {
|
|
109
115
|
value: "PENDING",
|
|
110
116
|
children: "PENDING"
|
|
111
117
|
}),
|
|
112
|
-
/* @__PURE__ */
|
|
118
|
+
/* @__PURE__ */ h("option", {
|
|
113
119
|
value: "TRIGGERED",
|
|
114
120
|
children: "TRIGGERED"
|
|
115
121
|
}),
|
|
116
|
-
/* @__PURE__ */
|
|
122
|
+
/* @__PURE__ */ h("option", {
|
|
117
123
|
value: "SENT",
|
|
118
124
|
children: "SENT"
|
|
119
125
|
}),
|
|
120
|
-
/* @__PURE__ */
|
|
126
|
+
/* @__PURE__ */ h("option", {
|
|
121
127
|
value: "FAILED",
|
|
122
128
|
children: "FAILED"
|
|
123
129
|
}),
|
|
124
|
-
/* @__PURE__ */
|
|
130
|
+
/* @__PURE__ */ h("option", {
|
|
125
131
|
value: "CANCELLED",
|
|
126
132
|
children: "CANCELLED"
|
|
127
133
|
})
|
|
128
134
|
]
|
|
129
135
|
}),
|
|
130
|
-
/* @__PURE__ */
|
|
131
|
-
value:
|
|
132
|
-
onChange: (e) =>
|
|
136
|
+
/* @__PURE__ */ g(w, {
|
|
137
|
+
value: A.channel,
|
|
138
|
+
onChange: (e) => j((t) => ({
|
|
133
139
|
...t,
|
|
134
140
|
channel: e.target.value
|
|
135
141
|
})),
|
|
136
142
|
className: "rounded-md border border-default bg-bg-canvas px-3 py-2 text-sm text-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
137
143
|
children: [
|
|
138
|
-
/* @__PURE__ */
|
|
144
|
+
/* @__PURE__ */ h("option", {
|
|
139
145
|
value: "all",
|
|
140
|
-
children:
|
|
146
|
+
children: E("notifications.allChannels", "All Channels")
|
|
141
147
|
}),
|
|
142
|
-
/* @__PURE__ */
|
|
148
|
+
/* @__PURE__ */ h("option", {
|
|
143
149
|
value: "EMAIL",
|
|
144
150
|
children: "EMAIL"
|
|
145
151
|
}),
|
|
146
|
-
/* @__PURE__ */
|
|
152
|
+
/* @__PURE__ */ h("option", {
|
|
147
153
|
value: "SMS",
|
|
148
154
|
children: "SMS"
|
|
149
155
|
}),
|
|
150
|
-
/* @__PURE__ */
|
|
156
|
+
/* @__PURE__ */ h("option", {
|
|
151
157
|
value: "PUSH",
|
|
152
158
|
children: "PUSH"
|
|
153
159
|
}),
|
|
154
|
-
/* @__PURE__ */
|
|
160
|
+
/* @__PURE__ */ h("option", {
|
|
155
161
|
value: "WHATSAPP",
|
|
156
162
|
children: "WHATSAPP"
|
|
157
163
|
}),
|
|
158
|
-
/* @__PURE__ */
|
|
164
|
+
/* @__PURE__ */ h("option", {
|
|
159
165
|
value: "IN_APP",
|
|
160
166
|
children: "IN_APP"
|
|
161
167
|
})
|
|
162
168
|
]
|
|
163
169
|
}),
|
|
164
|
-
/* @__PURE__ */
|
|
165
|
-
value:
|
|
166
|
-
onChange: (e) =>
|
|
170
|
+
/* @__PURE__ */ g(w, {
|
|
171
|
+
value: A.deliveryStatus,
|
|
172
|
+
onChange: (e) => j((t) => ({
|
|
167
173
|
...t,
|
|
168
174
|
deliveryStatus: e.target.value
|
|
169
175
|
})),
|
|
170
176
|
className: "rounded-md border border-default bg-bg-canvas px-3 py-2 text-sm text-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
171
177
|
children: [
|
|
172
|
-
/* @__PURE__ */
|
|
178
|
+
/* @__PURE__ */ h("option", {
|
|
173
179
|
value: "all",
|
|
174
|
-
children:
|
|
180
|
+
children: E("notifications.allDeliveryStates", "All Delivery")
|
|
175
181
|
}),
|
|
176
|
-
/* @__PURE__ */
|
|
182
|
+
/* @__PURE__ */ h("option", {
|
|
177
183
|
value: "DELIVERED",
|
|
178
184
|
children: "DELIVERED"
|
|
179
185
|
}),
|
|
180
|
-
/* @__PURE__ */
|
|
186
|
+
/* @__PURE__ */ h("option", {
|
|
181
187
|
value: "OPENED",
|
|
182
188
|
children: "OPENED"
|
|
183
189
|
}),
|
|
184
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ h("option", {
|
|
185
191
|
value: "CLICKED",
|
|
186
192
|
children: "CLICKED"
|
|
187
193
|
}),
|
|
188
|
-
/* @__PURE__ */
|
|
194
|
+
/* @__PURE__ */ h("option", {
|
|
189
195
|
value: "FAILED",
|
|
190
196
|
children: "FAILED"
|
|
191
197
|
}),
|
|
192
|
-
/* @__PURE__ */
|
|
198
|
+
/* @__PURE__ */ h("option", {
|
|
193
199
|
value: "UNSUBSCRIBED",
|
|
194
200
|
children: "UNSUBSCRIBED"
|
|
195
201
|
})
|
|
196
202
|
]
|
|
197
203
|
}),
|
|
198
|
-
/* @__PURE__ */
|
|
199
|
-
value:
|
|
200
|
-
onChange: (e) =>
|
|
204
|
+
/* @__PURE__ */ g(w, {
|
|
205
|
+
value: A.topicId,
|
|
206
|
+
onChange: (e) => j((t) => ({
|
|
201
207
|
...t,
|
|
202
208
|
topicId: e.target.value
|
|
203
209
|
})),
|
|
204
210
|
className: "rounded-md border border-default bg-bg-canvas px-3 py-2 text-sm text-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
205
|
-
children: [/* @__PURE__ */
|
|
211
|
+
children: [/* @__PURE__ */ h("option", {
|
|
206
212
|
value: "",
|
|
207
|
-
children:
|
|
208
|
-
}),
|
|
213
|
+
children: E("notifications.allTopics", "All Topics")
|
|
214
|
+
}), k.map((e) => /* @__PURE__ */ h("option", {
|
|
209
215
|
value: e.id,
|
|
210
216
|
children: e.name
|
|
211
217
|
}, e.id))]
|
|
212
218
|
}),
|
|
213
|
-
/* @__PURE__ */
|
|
214
|
-
value:
|
|
215
|
-
onChange: (e) =>
|
|
219
|
+
/* @__PURE__ */ g(w, {
|
|
220
|
+
value: A.archived,
|
|
221
|
+
onChange: (e) => j((t) => ({
|
|
216
222
|
...t,
|
|
217
223
|
archived: e.target.value
|
|
218
224
|
})),
|
|
219
225
|
className: "rounded-md border border-default bg-bg-canvas px-3 py-2 text-sm text-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
220
226
|
children: [
|
|
221
|
-
/* @__PURE__ */
|
|
227
|
+
/* @__PURE__ */ h("option", {
|
|
222
228
|
value: "all",
|
|
223
|
-
children:
|
|
229
|
+
children: E("notifications.activeAndArchived", "Active + Archived")
|
|
224
230
|
}),
|
|
225
|
-
/* @__PURE__ */
|
|
231
|
+
/* @__PURE__ */ h("option", {
|
|
226
232
|
value: "active",
|
|
227
|
-
children:
|
|
233
|
+
children: E("notifications.activeOnly", "Active Only")
|
|
228
234
|
}),
|
|
229
|
-
/* @__PURE__ */
|
|
235
|
+
/* @__PURE__ */ h("option", {
|
|
230
236
|
value: "archived",
|
|
231
|
-
children:
|
|
237
|
+
children: E("notifications.archivedOnly", "Archived Only")
|
|
232
238
|
})
|
|
233
239
|
]
|
|
234
240
|
})
|
|
235
241
|
]
|
|
236
242
|
}),
|
|
237
|
-
/* @__PURE__ */
|
|
243
|
+
/* @__PURE__ */ g("div", {
|
|
238
244
|
className: "grid gap-6 xl:grid-cols-[minmax(0,1fr),420px]",
|
|
239
|
-
children: [/* @__PURE__ */
|
|
245
|
+
children: [/* @__PURE__ */ g("div", {
|
|
240
246
|
className: "space-y-6",
|
|
241
|
-
children: [/* @__PURE__ */
|
|
247
|
+
children: [/* @__PURE__ */ g(v, {
|
|
242
248
|
className: "p-4",
|
|
243
|
-
children: [/* @__PURE__ */
|
|
249
|
+
children: [/* @__PURE__ */ g("div", {
|
|
244
250
|
className: "mb-4 flex items-center justify-between",
|
|
245
|
-
children: [/* @__PURE__ */
|
|
251
|
+
children: [/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h2", {
|
|
246
252
|
className: "text-base font-semibold text-primary",
|
|
247
|
-
children:
|
|
248
|
-
}), /* @__PURE__ */
|
|
253
|
+
children: E("notifications.sentNotifications", "Notifications")
|
|
254
|
+
}), /* @__PURE__ */ g("p", {
|
|
249
255
|
className: "text-sm text-text-secondary",
|
|
250
256
|
children: [
|
|
251
|
-
|
|
257
|
+
M.length,
|
|
252
258
|
" ",
|
|
253
|
-
|
|
259
|
+
E("notifications.resultsFoundShort", "results")
|
|
254
260
|
]
|
|
255
|
-
})] }),
|
|
261
|
+
})] }), I && /* @__PURE__ */ h(o, { today: /* @__PURE__ */ h(f, {
|
|
256
262
|
size: 16,
|
|
257
263
|
className: "animate-spin text-tertiary"
|
|
258
|
-
})]
|
|
259
|
-
}), /* @__PURE__ */
|
|
264
|
+
}) })]
|
|
265
|
+
}), /* @__PURE__ */ h("div", {
|
|
260
266
|
className: "space-y-3",
|
|
261
|
-
children:
|
|
267
|
+
children: M.length === 0 ? /* @__PURE__ */ h(b, {
|
|
262
268
|
illustration: "empty-search",
|
|
263
|
-
title:
|
|
264
|
-
description:
|
|
269
|
+
title: E("notifications.noNotificationsFound", "No notifications found"),
|
|
270
|
+
description: E("notifications.adjustSearchOrDateRange", "Try adjusting your filters"),
|
|
265
271
|
kind: "filtered"
|
|
266
|
-
}) :
|
|
272
|
+
}) : M.map((t) => /* @__PURE__ */ h("button", {
|
|
267
273
|
type: "button",
|
|
268
|
-
onClick: () =>
|
|
274
|
+
onClick: () => L(t.id),
|
|
269
275
|
className: "block w-full text-left",
|
|
270
|
-
children: /* @__PURE__ */
|
|
271
|
-
notification:
|
|
276
|
+
children: /* @__PURE__ */ h(e, {
|
|
277
|
+
notification: t,
|
|
272
278
|
compact: !0,
|
|
273
279
|
showArchivedState: !0,
|
|
274
280
|
analyticsSource: "admin_history"
|
|
275
281
|
})
|
|
276
|
-
},
|
|
282
|
+
}, t.id))
|
|
277
283
|
})]
|
|
278
|
-
}), /* @__PURE__ */
|
|
284
|
+
}), /* @__PURE__ */ g("section", {
|
|
279
285
|
className: "rounded-lg border border-border-seam bg-gloss-card p-4",
|
|
280
|
-
children: [/* @__PURE__ */
|
|
286
|
+
children: [/* @__PURE__ */ g("div", {
|
|
281
287
|
className: "mb-4 flex items-center gap-2",
|
|
282
|
-
children: [/* @__PURE__ */
|
|
288
|
+
children: [/* @__PURE__ */ h(u, {
|
|
283
289
|
size: 18,
|
|
284
290
|
className: "text-accent-primary"
|
|
285
|
-
}), /* @__PURE__ */
|
|
291
|
+
}), /* @__PURE__ */ h("h2", {
|
|
286
292
|
className: "text-base font-semibold text-primary",
|
|
287
|
-
children:
|
|
293
|
+
children: E("notifications.scheduledNotifications", "Scheduled Notifications")
|
|
288
294
|
})]
|
|
289
|
-
}), /* @__PURE__ */
|
|
295
|
+
}), /* @__PURE__ */ h("div", {
|
|
290
296
|
className: "space-y-3",
|
|
291
|
-
children:
|
|
297
|
+
children: N.length === 0 ? /* @__PURE__ */ h(b, {
|
|
292
298
|
illustration: "empty-data",
|
|
293
|
-
title:
|
|
294
|
-
description:
|
|
299
|
+
title: E("notifications.noScheduledNotifications", "No scheduled notifications"),
|
|
300
|
+
description: E("notifications.noScheduledDescription", "Notifications queued for a future send time will appear here, ready to reschedule or cancel."),
|
|
295
301
|
glassIllustration: "calendar",
|
|
296
302
|
size: "panel"
|
|
297
|
-
}) :
|
|
303
|
+
}) : N.map((e) => /* @__PURE__ */ h("div", {
|
|
298
304
|
className: "rounded-md border border-default bg-bg-canvas p-4",
|
|
299
|
-
children: /* @__PURE__ */
|
|
305
|
+
children: /* @__PURE__ */ g("div", {
|
|
300
306
|
className: "flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",
|
|
301
|
-
children: [/* @__PURE__ */
|
|
307
|
+
children: [/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h3", {
|
|
302
308
|
className: "text-sm font-semibold text-primary",
|
|
303
309
|
children: e.notification.title
|
|
304
|
-
}), /* @__PURE__ */
|
|
310
|
+
}), /* @__PURE__ */ g("p", {
|
|
305
311
|
className: "text-xs text-text-secondary",
|
|
306
312
|
children: [
|
|
307
313
|
e.notification.channel,
|
|
@@ -309,109 +315,109 @@ function w() {
|
|
|
309
315
|
e.notification.type,
|
|
310
316
|
" •",
|
|
311
317
|
" ",
|
|
312
|
-
|
|
318
|
+
T(e.scheduledFor)
|
|
313
319
|
]
|
|
314
|
-
})] }), /* @__PURE__ */
|
|
320
|
+
})] }), /* @__PURE__ */ g("div", {
|
|
315
321
|
className: "flex items-center gap-2",
|
|
316
|
-
children: [/* @__PURE__ */
|
|
322
|
+
children: [/* @__PURE__ */ h("button", {
|
|
317
323
|
type: "button",
|
|
318
|
-
onClick: () =>
|
|
324
|
+
onClick: () => L(e.notification.id),
|
|
319
325
|
className: "rounded-md border border-default px-3 py-2 text-xs text-text-secondary hover:bg-bg-sunken",
|
|
320
|
-
children:
|
|
321
|
-
}), e.status === "PENDING" && /* @__PURE__ */
|
|
326
|
+
children: E("notifications.view", "View")
|
|
327
|
+
}), e.status === "PENDING" && /* @__PURE__ */ h("button", {
|
|
322
328
|
type: "button",
|
|
323
|
-
onClick: () =>
|
|
329
|
+
onClick: () => B(e.id),
|
|
324
330
|
className: "rounded-md border border-status-error-border px-3 py-2 text-xs text-status-error-text hover:bg-status-error-bg-subtle",
|
|
325
|
-
children:
|
|
331
|
+
children: E("notifications.cancel", "Cancel")
|
|
326
332
|
})]
|
|
327
333
|
})]
|
|
328
334
|
})
|
|
329
335
|
}, e.id))
|
|
330
336
|
})]
|
|
331
337
|
})]
|
|
332
|
-
}), /* @__PURE__ */
|
|
338
|
+
}), /* @__PURE__ */ h("aside", {
|
|
333
339
|
className: "rounded-lg border border-border-seam bg-gloss-card p-4 xl:sticky xl:top-4 xl:max-h-[calc(100vh-2rem)] xl:self-start xl:overflow-y-auto",
|
|
334
|
-
children:
|
|
340
|
+
children: P ? /* @__PURE__ */ g("div", {
|
|
335
341
|
className: "space-y-4",
|
|
336
342
|
children: [
|
|
337
|
-
/* @__PURE__ */
|
|
343
|
+
/* @__PURE__ */ g("div", {
|
|
338
344
|
className: "flex items-start justify-between gap-3",
|
|
339
|
-
children: [/* @__PURE__ */
|
|
345
|
+
children: [/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h2", {
|
|
340
346
|
className: "text-lg font-semibold text-primary",
|
|
341
|
-
children:
|
|
342
|
-
}), /* @__PURE__ */
|
|
347
|
+
children: P.title
|
|
348
|
+
}), /* @__PURE__ */ h("p", {
|
|
343
349
|
className: "text-sm text-text-secondary",
|
|
344
|
-
children:
|
|
345
|
-
})] }), /* @__PURE__ */
|
|
350
|
+
children: P.body
|
|
351
|
+
})] }), /* @__PURE__ */ h("button", {
|
|
346
352
|
type: "button",
|
|
347
|
-
onClick:
|
|
353
|
+
onClick: H,
|
|
348
354
|
className: "rounded-md border border-default px-3 py-2 text-xs text-text-secondary hover:bg-bg-sunken",
|
|
349
|
-
children:
|
|
355
|
+
children: E("notifications.close", "Close")
|
|
350
356
|
})]
|
|
351
357
|
}),
|
|
352
|
-
/* @__PURE__ */
|
|
358
|
+
/* @__PURE__ */ g("div", {
|
|
353
359
|
className: "grid gap-2 rounded-md border border-default bg-bg-canvas p-3 text-sm text-text-secondary",
|
|
354
360
|
children: [
|
|
355
|
-
/* @__PURE__ */
|
|
356
|
-
/* @__PURE__ */
|
|
361
|
+
/* @__PURE__ */ g("div", { children: [
|
|
362
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.status", "Status"), ":"] }),
|
|
357
363
|
" ",
|
|
358
|
-
|
|
364
|
+
P.status
|
|
359
365
|
] }),
|
|
360
|
-
/* @__PURE__ */
|
|
361
|
-
/* @__PURE__ */
|
|
366
|
+
/* @__PURE__ */ g("div", { children: [
|
|
367
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.delivery", "Delivery"), ":"] }),
|
|
362
368
|
" ",
|
|
363
|
-
|
|
369
|
+
P.deliveryStatus || "—"
|
|
364
370
|
] }),
|
|
365
|
-
/* @__PURE__ */
|
|
366
|
-
/* @__PURE__ */
|
|
371
|
+
/* @__PURE__ */ g("div", { children: [
|
|
372
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.topic", "Topic"), ":"] }),
|
|
367
373
|
" ",
|
|
368
|
-
|
|
374
|
+
P.topic?.name || "—"
|
|
369
375
|
] }),
|
|
370
|
-
/* @__PURE__ */
|
|
371
|
-
/* @__PURE__ */
|
|
376
|
+
/* @__PURE__ */ g("div", { children: [
|
|
377
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.created", "Created"), ":"] }),
|
|
372
378
|
" ",
|
|
373
|
-
|
|
379
|
+
T(P.createdAt)
|
|
374
380
|
] }),
|
|
375
|
-
/* @__PURE__ */
|
|
376
|
-
/* @__PURE__ */
|
|
381
|
+
/* @__PURE__ */ g("div", { children: [
|
|
382
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.sent", "Sent"), ":"] }),
|
|
377
383
|
" ",
|
|
378
|
-
|
|
384
|
+
T(P.sentAt)
|
|
379
385
|
] }),
|
|
380
|
-
/* @__PURE__ */
|
|
381
|
-
/* @__PURE__ */
|
|
386
|
+
/* @__PURE__ */ g("div", { children: [
|
|
387
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.delivered", "Delivered"), ":"] }),
|
|
382
388
|
" ",
|
|
383
|
-
|
|
389
|
+
T(P.deliveredAt)
|
|
384
390
|
] }),
|
|
385
|
-
/* @__PURE__ */
|
|
386
|
-
/* @__PURE__ */
|
|
391
|
+
/* @__PURE__ */ g("div", { children: [
|
|
392
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.opened", "Opened"), ":"] }),
|
|
387
393
|
" ",
|
|
388
|
-
|
|
394
|
+
T(P.openedAt)
|
|
389
395
|
] }),
|
|
390
|
-
/* @__PURE__ */
|
|
391
|
-
/* @__PURE__ */
|
|
396
|
+
/* @__PURE__ */ g("div", { children: [
|
|
397
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.clicked", "Clicked"), ":"] }),
|
|
392
398
|
" ",
|
|
393
|
-
|
|
399
|
+
T(P.clickedAt)
|
|
394
400
|
] }),
|
|
395
|
-
/* @__PURE__ */
|
|
396
|
-
/* @__PURE__ */
|
|
401
|
+
/* @__PURE__ */ g("div", { children: [
|
|
402
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.read", "Read"), ":"] }),
|
|
397
403
|
" ",
|
|
398
|
-
|
|
404
|
+
T(P.readAt)
|
|
399
405
|
] }),
|
|
400
|
-
/* @__PURE__ */
|
|
401
|
-
/* @__PURE__ */
|
|
406
|
+
/* @__PURE__ */ g("div", { children: [
|
|
407
|
+
/* @__PURE__ */ g("strong", { children: [E("notifications.detail.recipient", "Recipient"), ":"] }),
|
|
402
408
|
" ",
|
|
403
|
-
|
|
409
|
+
P.recipientEmail || P.recipientPhone || P.id
|
|
404
410
|
] })
|
|
405
411
|
]
|
|
406
412
|
}),
|
|
407
|
-
|
|
413
|
+
P.media.length > 0 && /* @__PURE__ */ g("div", {
|
|
408
414
|
className: "space-y-2",
|
|
409
|
-
children: [/* @__PURE__ */
|
|
415
|
+
children: [/* @__PURE__ */ h("h3", {
|
|
410
416
|
className: "text-sm font-semibold text-primary",
|
|
411
|
-
children:
|
|
412
|
-
}), /* @__PURE__ */
|
|
417
|
+
children: E("notifications.media", "Media")
|
|
418
|
+
}), /* @__PURE__ */ h("div", {
|
|
413
419
|
className: "grid gap-3",
|
|
414
|
-
children:
|
|
420
|
+
children: P.media.map((e) => /* @__PURE__ */ h("a", {
|
|
415
421
|
href: e.url,
|
|
416
422
|
target: "_blank",
|
|
417
423
|
rel: "noreferrer",
|
|
@@ -420,93 +426,93 @@ function w() {
|
|
|
420
426
|
}, e.url))
|
|
421
427
|
})]
|
|
422
428
|
}),
|
|
423
|
-
|
|
429
|
+
P.actions.length > 0 && /* @__PURE__ */ g("div", {
|
|
424
430
|
className: "space-y-2",
|
|
425
|
-
children: [/* @__PURE__ */
|
|
431
|
+
children: [/* @__PURE__ */ h("h3", {
|
|
426
432
|
className: "text-sm font-semibold text-primary",
|
|
427
|
-
children:
|
|
428
|
-
}), /* @__PURE__ */
|
|
433
|
+
children: E("notifications.actions", "Actions")
|
|
434
|
+
}), /* @__PURE__ */ h("div", {
|
|
429
435
|
className: "grid gap-2",
|
|
430
|
-
children:
|
|
436
|
+
children: P.actions.map((e) => /* @__PURE__ */ g("div", {
|
|
431
437
|
className: "rounded-md border border-default bg-bg-canvas p-3 text-sm text-text-secondary",
|
|
432
|
-
children: [/* @__PURE__ */
|
|
438
|
+
children: [/* @__PURE__ */ h("div", {
|
|
433
439
|
className: "font-medium text-primary",
|
|
434
440
|
children: e.label
|
|
435
|
-
}), /* @__PURE__ */
|
|
441
|
+
}), /* @__PURE__ */ h("div", {
|
|
436
442
|
className: "truncate text-xs",
|
|
437
443
|
children: e.url
|
|
438
444
|
})]
|
|
439
445
|
}, e.id))
|
|
440
446
|
})]
|
|
441
447
|
}),
|
|
442
|
-
|
|
448
|
+
P.scheduledNotification && /* @__PURE__ */ g("div", {
|
|
443
449
|
className: "space-y-3 rounded-md border border-default bg-bg-canvas p-3",
|
|
444
450
|
children: [
|
|
445
|
-
/* @__PURE__ */
|
|
451
|
+
/* @__PURE__ */ h("div", {
|
|
446
452
|
className: "text-sm font-semibold text-primary",
|
|
447
|
-
children:
|
|
453
|
+
children: E("notifications.scheduling", "Scheduling")
|
|
448
454
|
}),
|
|
449
|
-
/* @__PURE__ */
|
|
455
|
+
/* @__PURE__ */ h("div", {
|
|
450
456
|
className: "text-sm text-text-secondary",
|
|
451
|
-
children:
|
|
457
|
+
children: T(P.scheduledNotification.scheduledFor)
|
|
452
458
|
}),
|
|
453
|
-
|
|
459
|
+
P.scheduledNotification.status === "PENDING" && /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h("input", {
|
|
454
460
|
type: "datetime-local",
|
|
455
|
-
value:
|
|
456
|
-
onChange: (e) =>
|
|
461
|
+
value: U,
|
|
462
|
+
onChange: (e) => W(e.target.value),
|
|
457
463
|
className: "w-full rounded-md border border-default bg-surface px-3 py-2 text-sm text-primary"
|
|
458
|
-
}), /* @__PURE__ */
|
|
464
|
+
}), /* @__PURE__ */ g("div", {
|
|
459
465
|
className: "flex items-center gap-2",
|
|
460
|
-
children: [/* @__PURE__ */
|
|
466
|
+
children: [/* @__PURE__ */ h("button", {
|
|
461
467
|
type: "button",
|
|
462
|
-
onClick: () =>
|
|
468
|
+
onClick: () => U && V(P.scheduledNotification.id, new Date(U).toISOString()),
|
|
463
469
|
className: "rounded-md bg-accent-primary px-3 py-2 text-xs font-medium text-text-inverse hover:opacity-90",
|
|
464
|
-
children:
|
|
465
|
-
}), /* @__PURE__ */
|
|
470
|
+
children: E("notifications.reschedule", "Reschedule")
|
|
471
|
+
}), /* @__PURE__ */ h("button", {
|
|
466
472
|
type: "button",
|
|
467
|
-
onClick: () =>
|
|
473
|
+
onClick: () => B(P.scheduledNotification.id),
|
|
468
474
|
className: "rounded-md border border-status-error-border px-3 py-2 text-xs text-status-error-text hover:bg-status-error-bg-subtle",
|
|
469
|
-
children:
|
|
475
|
+
children: E("notifications.cancel", "Cancel")
|
|
470
476
|
})]
|
|
471
477
|
})] })
|
|
472
478
|
]
|
|
473
479
|
}),
|
|
474
|
-
/* @__PURE__ */
|
|
480
|
+
/* @__PURE__ */ h("div", {
|
|
475
481
|
className: "flex items-center gap-2",
|
|
476
|
-
children:
|
|
482
|
+
children: P.archivedAt ? /* @__PURE__ */ h("button", {
|
|
477
483
|
type: "button",
|
|
478
|
-
onClick: () =>
|
|
484
|
+
onClick: () => z(P.id),
|
|
479
485
|
className: "rounded-md border border-default px-3 py-2 text-xs text-text-secondary hover:bg-bg-sunken",
|
|
480
|
-
children:
|
|
481
|
-
}) : /* @__PURE__ */
|
|
486
|
+
children: E("notifications.restore", "Restore")
|
|
487
|
+
}) : /* @__PURE__ */ h("button", {
|
|
482
488
|
type: "button",
|
|
483
|
-
onClick: () =>
|
|
489
|
+
onClick: () => R(P.id),
|
|
484
490
|
className: "rounded-md border border-default px-3 py-2 text-xs text-text-secondary hover:bg-bg-sunken",
|
|
485
|
-
children:
|
|
491
|
+
children: E("notifications.archive", "Archive")
|
|
486
492
|
})
|
|
487
493
|
}),
|
|
488
|
-
/* @__PURE__ */
|
|
494
|
+
/* @__PURE__ */ g("div", {
|
|
489
495
|
className: "space-y-2",
|
|
490
|
-
children: [/* @__PURE__ */
|
|
496
|
+
children: [/* @__PURE__ */ h("h3", {
|
|
491
497
|
className: "text-sm font-semibold text-primary",
|
|
492
|
-
children:
|
|
493
|
-
}),
|
|
498
|
+
children: E("notifications.eventTimeline", "Event Timeline")
|
|
499
|
+
}), F.length === 0 ? /* @__PURE__ */ h("div", {
|
|
494
500
|
className: "rounded-md border border-dashed border-border-seam p-4 text-sm text-text-secondary",
|
|
495
|
-
children:
|
|
496
|
-
}) : /* @__PURE__ */
|
|
501
|
+
children: E("notifications.noEvents", "No events recorded yet.")
|
|
502
|
+
}) : /* @__PURE__ */ h(C, {
|
|
497
503
|
collapsedHeight: 180,
|
|
498
|
-
children: /* @__PURE__ */
|
|
504
|
+
children: /* @__PURE__ */ h("div", {
|
|
499
505
|
className: "space-y-2",
|
|
500
|
-
children:
|
|
506
|
+
children: F.map((e) => /* @__PURE__ */ g("div", {
|
|
501
507
|
className: "rounded-md border border-border-seam bg-surface p-3 text-sm text-text-secondary",
|
|
502
508
|
children: [
|
|
503
|
-
/* @__PURE__ */
|
|
509
|
+
/* @__PURE__ */ h("div", {
|
|
504
510
|
className: "font-medium text-primary",
|
|
505
511
|
children: e.eventType
|
|
506
512
|
}),
|
|
507
|
-
/* @__PURE__ */
|
|
508
|
-
e.deliveryStatus && /* @__PURE__ */
|
|
509
|
-
|
|
513
|
+
/* @__PURE__ */ h("div", { children: T(e.timestamp) }),
|
|
514
|
+
e.deliveryStatus && /* @__PURE__ */ g("div", { children: [
|
|
515
|
+
E("notifications.detail.delivery", "Delivery"),
|
|
510
516
|
":",
|
|
511
517
|
" ",
|
|
512
518
|
e.deliveryStatus
|
|
@@ -517,12 +523,12 @@ function w() {
|
|
|
517
523
|
})]
|
|
518
524
|
})
|
|
519
525
|
]
|
|
520
|
-
}) : /* @__PURE__ */
|
|
526
|
+
}) : /* @__PURE__ */ h("div", {
|
|
521
527
|
className: "flex h-full min-h-[360px] items-center justify-center",
|
|
522
|
-
children: /* @__PURE__ */
|
|
528
|
+
children: /* @__PURE__ */ h(b, {
|
|
523
529
|
illustration: "empty-search",
|
|
524
|
-
title:
|
|
525
|
-
description:
|
|
530
|
+
title: E("notifications.selectNotificationTitle", "Nothing selected"),
|
|
531
|
+
description: E("notifications.selectNotificationForDetails", "Select a notification to inspect details, delivery receipts, and activity."),
|
|
526
532
|
glassIllustration: "notifications",
|
|
527
533
|
size: "panel"
|
|
528
534
|
})
|
|
@@ -530,11 +536,11 @@ function w() {
|
|
|
530
536
|
})]
|
|
531
537
|
})
|
|
532
538
|
]
|
|
533
|
-
}) : /* @__PURE__ */
|
|
539
|
+
}) : /* @__PURE__ */ h("div", {
|
|
534
540
|
className: "p-8 text-center text-text-secondary",
|
|
535
|
-
children:
|
|
541
|
+
children: E("notifications.noPermissionHistory", "You don't have permission to view notification history.")
|
|
536
542
|
});
|
|
537
543
|
}
|
|
538
|
-
export {
|
|
544
|
+
export { E as NotificationHistoryAdminPage };
|
|
539
545
|
|
|
540
546
|
//# sourceMappingURL=NotificationHistoryAdminPage.js.map
|