@burdenoff/microfe-notification 2026.1127.1 → 2026.1129.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/NotificationRoutes.d.ts +10 -0
- package/dist/NotificationRoutes.js +76 -71
- package/dist/NotificationRoutes.js.map +1 -1
- package/dist/generated/global-operations.d.ts +58 -3
- package/dist/generated/global-operations.js +31 -23
- package/dist/generated/global-operations.js.map +1 -1
- package/dist/generated/global-types.d.ts +10933 -581
- package/dist/hooks/useNotificationAnalytics.d.ts +1 -1
- package/dist/hooks/useNotificationAnalytics.js.map +1 -1
- package/dist/hooks/useNotifications.d.ts +7 -0
- package/dist/hooks/useNotifications.js +1 -1
- package/dist/hooks/useNotifications.js.map +1 -1
- package/dist/translations/en.d.ts +80 -0
- package/dist/types/index.d.ts +2 -1
- package/dist/v2/ArchivedRedirect.d.ts +1 -0
- package/dist/v2/ArchivedRedirect.js +14 -0
- package/dist/v2/ArchivedRedirect.js.map +1 -0
- package/dist/v2/InboxPage.d.ts +1 -0
- package/dist/v2/InboxPage.js +191 -0
- package/dist/v2/InboxPage.js.map +1 -0
- package/dist/v2/InboxRows.d.ts +10 -0
- package/dist/v2/InboxRows.js +101 -0
- package/dist/v2/InboxRows.js.map +1 -0
- package/dist/v2/KindIcon.d.ts +4 -0
- package/dist/v2/KindIcon.js +33 -0
- package/dist/v2/KindIcon.js.map +1 -0
- package/dist/v2/NotificationDetailPanel.d.ts +7 -0
- package/dist/v2/NotificationDetailPanel.js +200 -0
- package/dist/v2/NotificationDetailPanel.js.map +1 -0
- package/dist/v2/PreferencesPage.d.ts +1 -0
- package/dist/v2/PreferencesPage.js +139 -0
- package/dist/v2/PreferencesPage.js.map +1 -0
- package/dist/v2/__tests__/routeShapes.d.ts +13 -0
- package/dist/v2/model/days.d.ts +9 -0
- package/dist/v2/model/days.js +25 -0
- package/dist/v2/model/days.js.map +1 -0
- package/dist/v2/model/events.d.ts +17 -0
- package/dist/v2/model/events.js +72 -0
- package/dist/v2/model/events.js.map +1 -0
- package/dist/v2/model/icons.d.ts +6 -0
- package/dist/v2/model/icons.js +19 -0
- package/dist/v2/model/icons.js.map +1 -0
- package/dist/v2/model/inbox.d.ts +15 -0
- package/dist/v2/model/inbox.js +22 -0
- package/dist/v2/model/inbox.js.map +1 -0
- package/dist/v2/model/thing.d.ts +16 -0
- package/dist/v2/model/thing.js +41 -0
- package/dist/v2/model/thing.js.map +1 -0
- package/dist/v2/model/tr.d.ts +2 -0
- package/dist/v2/useNotificationDetail.d.ts +19 -0
- package/dist/v2/useNotificationDetail.js +65 -0
- package/dist/v2/useNotificationDetail.js.map +1 -0
- package/package.json +2 -2
|
@@ -16,3 +16,13 @@
|
|
|
16
16
|
* - unmatched → Absolute redirect to /{basePath}/center (avoids relative redirect loops)
|
|
17
17
|
*/
|
|
18
18
|
export declare function NotificationRoutes(): import('react').JSX.Element;
|
|
19
|
+
/**
|
|
20
|
+
* FluidGrids' Navigation v2 routes (BOFF-11872). Every URL of the classic
|
|
21
|
+
* routes keeps working: `/` opens straight on the inbox (old `?tab=` values
|
|
22
|
+
* still open their page), and the admin pages get a route-level permission
|
|
23
|
+
* gate and a way back to the inbox.
|
|
24
|
+
*/
|
|
25
|
+
export declare function NavigationV2Routes({ centerPath, v2 }: {
|
|
26
|
+
centerPath: string;
|
|
27
|
+
v2: boolean;
|
|
28
|
+
}): import('react').JSX.Element;
|
|
@@ -4,146 +4,151 @@ import { NotificationLandingPage as n } from "./pages/NotificationLandingPage.js
|
|
|
4
4
|
import { AdminPageV2 as r } from "./navigation-v2/AdminPageV2.js";
|
|
5
5
|
import { DeliveryLogV2 as i, NotificationsV2Landing as a } from "./navigation-v2/NotificationsV2Landing.js";
|
|
6
6
|
import { CompactMarkOr as o, SectionLoaderOr as s } from "./components/loadingSystem.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
7
|
+
import { ArchivedRedirect as c } from "./v2/ArchivedRedirect.js";
|
|
8
|
+
import { Suspense as l, lazy as u } from "react";
|
|
9
|
+
import { Navigate as d, Route as f, Routes as p } from "react-router";
|
|
10
|
+
import { jsx as m, jsxs as h } from "react/jsx-runtime";
|
|
11
|
+
import { useAccountPagesV2 as g } from "@burdenoff/fe-libs/ui/account-pages-v2";
|
|
10
12
|
// src/NotificationRoutes.tsx
|
|
11
|
-
var
|
|
12
|
-
function
|
|
13
|
-
return /* @__PURE__ */
|
|
13
|
+
var _ = u(() => import("./v2/InboxPage.js").then((e) => ({ default: e.InboxPage }))), v = u(() => import("./v2/PreferencesPage.js").then((e) => ({ default: e.PreferencesPage }))), y = u(() => import("./pages/NotificationHistoryPage.js").then((e) => ({ default: e.NotificationHistoryPage }))), b = u(() => import("./pages/NotificationTemplatesPage.js").then((e) => ({ default: e.NotificationTemplatesPage }))), x = u(() => import("./pages/TemplateEditorPage.js").then((e) => ({ default: e.TemplateEditorPage }))), S = u(() => import("./pages/CreateNotificationPage.js").then((e) => ({ default: e.CreateNotificationPage }))), C = u(() => import("./pages/NotificationTopicsPage.js").then((e) => ({ default: e.NotificationTopicsPage }))), w = u(() => import("./pages/NotificationPreferencesPage.js").then((e) => ({ default: e.NotificationPreferencesPage })));
|
|
14
|
+
function T() {
|
|
15
|
+
return /* @__PURE__ */ m(s, {
|
|
14
16
|
route: !0,
|
|
15
17
|
minHeight: "16rem",
|
|
16
|
-
today: /* @__PURE__ */
|
|
18
|
+
today: /* @__PURE__ */ m("div", {
|
|
17
19
|
className: "flex h-64 items-center justify-center",
|
|
18
|
-
children: /* @__PURE__ */
|
|
20
|
+
children: /* @__PURE__ */ m(o, {
|
|
19
21
|
className: "h-8 w-8",
|
|
20
|
-
today: /* @__PURE__ */
|
|
22
|
+
today: /* @__PURE__ */ m("div", { className: "h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent" })
|
|
21
23
|
})
|
|
22
24
|
})
|
|
23
25
|
});
|
|
24
26
|
}
|
|
25
|
-
function
|
|
26
|
-
let { basePath: r = "/", navigationV2: i } = e(), a = `${r.endsWith("/") ? r.slice(0, -1) : r}/center`;
|
|
27
|
-
return i ? /* @__PURE__ */
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
function E() {
|
|
28
|
+
let { basePath: r = "/", navigationV2: i } = e(), a = g(), o = `${r.endsWith("/") ? r.slice(0, -1) : r}/center`;
|
|
29
|
+
return i ? /* @__PURE__ */ m(D, {
|
|
30
|
+
centerPath: o,
|
|
31
|
+
v2: a
|
|
32
|
+
}) : /* @__PURE__ */ m(l, {
|
|
33
|
+
fallback: /* @__PURE__ */ m(T, {}),
|
|
34
|
+
children: /* @__PURE__ */ h(p, { children: [
|
|
35
|
+
/* @__PURE__ */ m(f, {
|
|
31
36
|
index: !0,
|
|
32
|
-
element:
|
|
37
|
+
element: m(a ? _ : n, {})
|
|
33
38
|
}),
|
|
34
|
-
/* @__PURE__ */
|
|
39
|
+
/* @__PURE__ */ m(f, {
|
|
35
40
|
path: "list",
|
|
36
|
-
element:
|
|
41
|
+
element: m(a ? _ : t, {})
|
|
37
42
|
}),
|
|
38
|
-
/* @__PURE__ */
|
|
43
|
+
/* @__PURE__ */ m(f, {
|
|
39
44
|
path: "center",
|
|
40
|
-
element:
|
|
45
|
+
element: m(a ? _ : t, {})
|
|
41
46
|
}),
|
|
42
|
-
/* @__PURE__ */
|
|
47
|
+
/* @__PURE__ */ m(f, {
|
|
43
48
|
path: "history",
|
|
44
|
-
element:
|
|
49
|
+
element: m(a ? c : y, {})
|
|
45
50
|
}),
|
|
46
|
-
/* @__PURE__ */
|
|
51
|
+
/* @__PURE__ */ m(f, {
|
|
47
52
|
path: "templates",
|
|
48
|
-
element: /* @__PURE__ */
|
|
53
|
+
element: /* @__PURE__ */ m(b, {})
|
|
49
54
|
}),
|
|
50
|
-
/* @__PURE__ */
|
|
55
|
+
/* @__PURE__ */ m(f, {
|
|
51
56
|
path: "templates/new",
|
|
52
|
-
element: /* @__PURE__ */
|
|
57
|
+
element: /* @__PURE__ */ m(x, {})
|
|
53
58
|
}),
|
|
54
|
-
/* @__PURE__ */
|
|
59
|
+
/* @__PURE__ */ m(f, {
|
|
55
60
|
path: "templates/:templateId",
|
|
56
|
-
element: /* @__PURE__ */
|
|
61
|
+
element: /* @__PURE__ */ m(x, {})
|
|
57
62
|
}),
|
|
58
|
-
/* @__PURE__ */
|
|
63
|
+
/* @__PURE__ */ m(f, {
|
|
59
64
|
path: "create",
|
|
60
|
-
element: /* @__PURE__ */
|
|
65
|
+
element: /* @__PURE__ */ m(S, {})
|
|
61
66
|
}),
|
|
62
|
-
/* @__PURE__ */
|
|
67
|
+
/* @__PURE__ */ m(f, {
|
|
63
68
|
path: "topics",
|
|
64
|
-
element: /* @__PURE__ */
|
|
69
|
+
element: /* @__PURE__ */ m(C, {})
|
|
65
70
|
}),
|
|
66
|
-
/* @__PURE__ */
|
|
71
|
+
/* @__PURE__ */ m(f, {
|
|
67
72
|
path: "preferences",
|
|
68
|
-
element:
|
|
73
|
+
element: m(a ? v : w, {})
|
|
69
74
|
}),
|
|
70
|
-
/* @__PURE__ */
|
|
75
|
+
/* @__PURE__ */ m(f, {
|
|
71
76
|
path: "*",
|
|
72
|
-
element: /* @__PURE__ */
|
|
73
|
-
to:
|
|
77
|
+
element: /* @__PURE__ */ m(d, {
|
|
78
|
+
to: o,
|
|
74
79
|
replace: !0
|
|
75
80
|
})
|
|
76
81
|
})
|
|
77
82
|
] })
|
|
78
83
|
});
|
|
79
84
|
}
|
|
80
|
-
function
|
|
81
|
-
return /* @__PURE__ */
|
|
82
|
-
fallback: /* @__PURE__ */
|
|
83
|
-
children: /* @__PURE__ */
|
|
84
|
-
/* @__PURE__ */
|
|
85
|
+
function D({ centerPath: e, v2: n }) {
|
|
86
|
+
return /* @__PURE__ */ m(l, {
|
|
87
|
+
fallback: /* @__PURE__ */ m(T, {}),
|
|
88
|
+
children: /* @__PURE__ */ h(p, { children: [
|
|
89
|
+
/* @__PURE__ */ m(f, {
|
|
85
90
|
index: !0,
|
|
86
|
-
element:
|
|
91
|
+
element: m(n ? _ : a, {})
|
|
87
92
|
}),
|
|
88
|
-
/* @__PURE__ */
|
|
93
|
+
/* @__PURE__ */ m(f, {
|
|
89
94
|
path: "list",
|
|
90
|
-
element:
|
|
95
|
+
element: m(n ? _ : t, {})
|
|
91
96
|
}),
|
|
92
|
-
/* @__PURE__ */
|
|
97
|
+
/* @__PURE__ */ m(f, {
|
|
93
98
|
path: "center",
|
|
94
|
-
element:
|
|
99
|
+
element: m(n ? _ : t, {})
|
|
95
100
|
}),
|
|
96
|
-
/* @__PURE__ */
|
|
101
|
+
/* @__PURE__ */ m(f, {
|
|
97
102
|
path: "history",
|
|
98
|
-
element:
|
|
103
|
+
element: m(n ? c : y, {})
|
|
99
104
|
}),
|
|
100
|
-
/* @__PURE__ */
|
|
105
|
+
/* @__PURE__ */ m(f, {
|
|
101
106
|
path: "preferences",
|
|
102
|
-
element:
|
|
107
|
+
element: m(n ? v : w, {})
|
|
103
108
|
}),
|
|
104
|
-
/* @__PURE__ */
|
|
109
|
+
/* @__PURE__ */ m(f, {
|
|
105
110
|
path: "templates",
|
|
106
|
-
element: /* @__PURE__ */
|
|
111
|
+
element: /* @__PURE__ */ m(r, {
|
|
107
112
|
tool: "templates",
|
|
108
|
-
children: /* @__PURE__ */
|
|
113
|
+
children: /* @__PURE__ */ m(b, {})
|
|
109
114
|
})
|
|
110
115
|
}),
|
|
111
|
-
/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ m(f, {
|
|
112
117
|
path: "templates/new",
|
|
113
|
-
element: /* @__PURE__ */
|
|
118
|
+
element: /* @__PURE__ */ m(r, {
|
|
114
119
|
tool: "templates",
|
|
115
|
-
children: /* @__PURE__ */
|
|
120
|
+
children: /* @__PURE__ */ m(x, {})
|
|
116
121
|
})
|
|
117
122
|
}),
|
|
118
|
-
/* @__PURE__ */
|
|
123
|
+
/* @__PURE__ */ m(f, {
|
|
119
124
|
path: "templates/:templateId",
|
|
120
|
-
element: /* @__PURE__ */
|
|
125
|
+
element: /* @__PURE__ */ m(r, {
|
|
121
126
|
tool: "templates",
|
|
122
|
-
children: /* @__PURE__ */
|
|
127
|
+
children: /* @__PURE__ */ m(x, {})
|
|
123
128
|
})
|
|
124
129
|
}),
|
|
125
|
-
/* @__PURE__ */
|
|
130
|
+
/* @__PURE__ */ m(f, {
|
|
126
131
|
path: "create",
|
|
127
|
-
element: /* @__PURE__ */
|
|
132
|
+
element: /* @__PURE__ */ m(r, {
|
|
128
133
|
tool: "send",
|
|
129
134
|
back: !1,
|
|
130
|
-
children: /* @__PURE__ */
|
|
135
|
+
children: /* @__PURE__ */ m(S, {})
|
|
131
136
|
})
|
|
132
137
|
}),
|
|
133
|
-
/* @__PURE__ */
|
|
138
|
+
/* @__PURE__ */ m(f, {
|
|
134
139
|
path: "topics",
|
|
135
|
-
element: /* @__PURE__ */
|
|
140
|
+
element: /* @__PURE__ */ m(r, {
|
|
136
141
|
tool: "topics",
|
|
137
|
-
children: /* @__PURE__ */
|
|
142
|
+
children: /* @__PURE__ */ m(C, {})
|
|
138
143
|
})
|
|
139
144
|
}),
|
|
140
|
-
/* @__PURE__ */
|
|
145
|
+
/* @__PURE__ */ m(f, {
|
|
141
146
|
path: "delivery-log",
|
|
142
|
-
element: /* @__PURE__ */
|
|
147
|
+
element: /* @__PURE__ */ m(i, {})
|
|
143
148
|
}),
|
|
144
|
-
/* @__PURE__ */
|
|
149
|
+
/* @__PURE__ */ m(f, {
|
|
145
150
|
path: "*",
|
|
146
|
-
element: /* @__PURE__ */
|
|
151
|
+
element: /* @__PURE__ */ m(d, {
|
|
147
152
|
to: e,
|
|
148
153
|
replace: !0
|
|
149
154
|
})
|
|
@@ -151,6 +156,6 @@ function C({ centerPath: e }) {
|
|
|
151
156
|
] })
|
|
152
157
|
});
|
|
153
158
|
}
|
|
154
|
-
export {
|
|
159
|
+
export { D as NavigationV2Routes, E as NotificationRoutes };
|
|
155
160
|
|
|
156
161
|
//# sourceMappingURL=NotificationRoutes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationRoutes.js","names":["NotificationHistoryPage","lazy","m","NotificationTemplatesPage","TemplateEditorPage","CreateNotificationPage","NotificationTopicsPage","NotificationPreferencesPage","PageLoader","SectionLoaderOr","CompactMarkOr","NotificationRoutes","useNotification","centerPath","basePath","navigationV2","NavigationV2Routes","Suspense","Routes","Route","NotificationLandingPage","NotificationCenterPage","Navigate","NotificationsV2Landing","AdminPageV2","DeliveryLogV2"],"sources":["../src/NotificationRoutes.tsx"],"sourcesContent":["import { lazy, Suspense } from 'react';\nimport { Navigate, Route, Routes } from 'react-router';\nimport { useNotification } from './providers/NotificationProvider';\n\n// Eager load - Primary landing page\nimport { NotificationCenterPage } from './pages/NotificationCenterPage';\nimport { NotificationLandingPage } from './pages/NotificationLandingPage';\nimport { AdminPageV2 } from './navigation-v2/AdminPageV2';\nimport { DeliveryLogV2, NotificationsV2Landing } from './navigation-v2/NotificationsV2Landing';\nimport { CompactMarkOr, SectionLoaderOr } from './components/loadingSystem';\n\n// Lazy load - Secondary pages\nconst NotificationHistoryPage = lazy(() =>\n import('./pages/NotificationHistoryPage').then((m) => ({\n default: m.NotificationHistoryPage,\n }))\n);\nconst NotificationTemplatesPage = lazy(() =>\n import('./pages/NotificationTemplatesPage').then((m) => ({\n default: m.NotificationTemplatesPage,\n }))\n);\nconst TemplateEditorPage = lazy(() =>\n import('./pages/TemplateEditorPage').then((m) => ({ default: m.TemplateEditorPage }))\n);\nconst CreateNotificationPage = lazy(() =>\n import('./pages/CreateNotificationPage').then((m) => ({ default: m.CreateNotificationPage }))\n);\nconst NotificationTopicsPage = lazy(() =>\n import('./pages/NotificationTopicsPage').then((m) => ({ default: m.NotificationTopicsPage }))\n);\nconst NotificationPreferencesPage = lazy(() =>\n import('./pages/NotificationPreferencesPage').then((m) => ({\n default: m.NotificationPreferencesPage,\n }))\n);\n\n// Loading fallback component\nfunction PageLoader() {\n return (\n <SectionLoaderOr\n route\n minHeight=\"16rem\"\n today={\n <div className=\"flex h-64 items-center justify-center\">\n <CompactMarkOr\n className=\"h-8 w-8\"\n today={\n <div className=\"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent\" />\n }\n />\n </div>\n }\n />\n );\n}\n\n/**\n * Internal router for the Notification microfrontend.\n * This component handles routing within the microfrontend using React Router v7.\n *\n * Routes:\n * - / → Notification landing page\n * - /list → Notification center (canonical list alias used by shell nav homePath)\n * - /center → Notification center (in-app notifications)\n * - /history → Notification history and archive\n * - /templates → Notification templates list (admin)\n * - /templates/new → Create new template (admin)\n * - /templates/:templateId → Edit template (admin)\n * - /create → Create and send notification (admin)\n * - /topics → Manage topics (admin)\n * - /preferences → User topic preferences\n * - unmatched → Absolute redirect to /{basePath}/center (avoids relative redirect loops)\n */\nexport function NotificationRoutes() {\n const { basePath = '/', navigationV2 } = useNotification();\n const centerPath = `${basePath.endsWith('/') ? basePath.slice(0, -1) : basePath}/center`;\n\n if (navigationV2) return <NavigationV2Routes centerPath={centerPath} />;\n\n return (\n <Suspense fallback={<PageLoader />}>\n <Routes>\n {/* Tabbed landing - default route */}\n <Route index element={<NotificationLandingPage />} />\n\n {/* Canonical list alias used by product-shell nav homePath */}\n <Route path=\"list\" element={<NotificationCenterPage />} />\n\n {/* User-facing routes (all users) */}\n <Route path=\"center\" element={<NotificationCenterPage />} />\n <Route path=\"history\" element={<NotificationHistoryPage />} />\n\n {/* Admin routes - Templates */}\n <Route path=\"templates\" element={<NotificationTemplatesPage />} />\n <Route path=\"templates/new\" element={<TemplateEditorPage />} />\n <Route path=\"templates/:templateId\" element={<TemplateEditorPage />} />\n\n {/* Admin routes - Create/Send Notification */}\n <Route path=\"create\" element={<CreateNotificationPage />} />\n <Route path=\"topics\" element={<NotificationTopicsPage />} />\n <Route path=\"preferences\" element={<NotificationPreferencesPage />} />\n\n {/* Catch-all route - absolute redirect so an unmatched path like /list\n cannot recursively append /center (e.g. /list/center/center/...) */}\n <Route path=\"*\" element={<Navigate to={centerPath} replace />} />\n </Routes>\n </Suspense>\n );\n}\n\n/**\n * FluidGrids' Navigation v2 routes (BOFF-11872). Every URL of the classic\n * routes keeps working: `/` opens straight on the inbox (old `?tab=` values\n * still open their page), and the admin pages get a route-level permission\n * gate and a way back to the inbox.\n */\nfunction NavigationV2Routes({ centerPath }: { centerPath: string }) {\n return (\n <Suspense fallback={<PageLoader />}>\n <Routes>\n <Route index element={<NotificationsV2Landing />} />\n <Route path=\"list\" element={<NotificationCenterPage />} />\n <Route path=\"center\" element={<NotificationCenterPage />} />\n <Route path=\"history\" element={<NotificationHistoryPage />} />\n <Route path=\"preferences\" element={<NotificationPreferencesPage />} />\n <Route\n path=\"templates\"\n element={\n <AdminPageV2 tool=\"templates\">\n <NotificationTemplatesPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"templates/new\"\n element={\n <AdminPageV2 tool=\"templates\">\n <TemplateEditorPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"templates/:templateId\"\n element={\n <AdminPageV2 tool=\"templates\">\n <TemplateEditorPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"create\"\n element={\n <AdminPageV2 tool=\"send\" back={false}>\n <CreateNotificationPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"topics\"\n element={\n <AdminPageV2 tool=\"topics\">\n <NotificationTopicsPage />\n </AdminPageV2>\n }\n />\n <Route path=\"delivery-log\" element={<DeliveryLogV2 />} />\n <Route path=\"*\" element={<Navigate to={centerPath} replace />} />\n </Routes>\n </Suspense>\n );\n}\n"],"mappings":";;;;;;;;;;AAYA,IAAMA,IAA0BC,QAC9B,OAAO,qCAAkC,CAAC,MAAM,OAAO,EACrD,SAASC,EAAE,wBACb,EAAE,CACJ,GACMC,IAA4BF,QAChC,OAAO,uCAAoC,CAAC,MAAM,OAAO,EACvD,SAASC,EAAE,0BACb,EAAE,CACJ,GACME,IAAqBH,QACzB,OAAO,gCAA6B,CAAC,MAAM,OAAO,EAAE,SA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AA;IACjB,CAAA;GAEhB,CAAA;GACD,kBAACgB,GAAD;IACE,MAAK;IACL,SACE,kBAACK,GAAD;KAAa,MAAK;KAChB,UAAA,kBAACpB,GAAD,CAAqB,CAAA;IACV,CAAA;GAEhB,CAAA;GACD,kBAACe,GAAD;IACE,MAAK;IACL,SACE,kBAACK,GAAD;KAAa,MAAK;KAChB,UAAA,kBAACpB,GAAD,CAAqB,CAAA;IACV,CAAA;GAEhB,CAAA;GACD,kBAACe,GAAD;IACE,MAAK;IACL,SACE,kBAACK,GAAD;KAAa,MAAK;KAAO,MAAM;KAC7B,UAAA,kBAACnB,GAAD,CAAyB,CAAA;IACd,CAAA;GAEhB,CAAA;GACD,kBAACc,GAAD;IACE,MAAK;IACL,SACE,kBAACK,GAAD;KAAa,MAAK;KAChB,UAAA,kBAAClB,GAAD,CAAyB,CAAA;IACd,CAAA;GAEhB,CAAA;GACD,kBAACa,GAAD;IAAO,MAAK;IAAe,SAAS,kBAACM,GAAD,CAAgB,CAAA;GAAI,CAAA;GACxD,kBAACN,GAAD;IAAO,MAAK;IAAI,SAAS,kBAACG,GAAD;KAAU,IAAIT;KAAY,SAAA;IAAS,CAAA;GAAI,CAAA;EAC1D,EAAA,CAAA;CACA,CAAA;AAEd"}
|
|
1
|
+
{"version":3,"file":"NotificationRoutes.js","names":["InboxPageV2","lazy","m","PreferencesPageV2","NotificationHistoryPage","NotificationTemplatesPage","TemplateEditorPage","CreateNotificationPage","NotificationTopicsPage","NotificationPreferencesPage","PageLoader","SectionLoaderOr","CompactMarkOr","NotificationRoutes","useNotification","v2","useAccountPagesV2","centerPath","basePath","navigationV2","NavigationV2Routes","Suspense","Routes","Route","jsx","NotificationLandingPage","NotificationCenterPage","ArchivedRedirect","Navigate","NotificationsV2Landing","AdminPageV2","DeliveryLogV2"],"sources":["../src/NotificationRoutes.tsx"],"sourcesContent":["import { lazy, Suspense } from 'react';\nimport { Navigate, Route, Routes } from 'react-router';\nimport { useNotification } from './providers/NotificationProvider';\n\n// Eager load - Primary landing page\nimport { NotificationCenterPage } from './pages/NotificationCenterPage';\nimport { NotificationLandingPage } from './pages/NotificationLandingPage';\nimport { AdminPageV2 } from './navigation-v2/AdminPageV2';\nimport { DeliveryLogV2, NotificationsV2Landing } from './navigation-v2/NotificationsV2Landing';\nimport { CompactMarkOr, SectionLoaderOr } from './components/loadingSystem';\nimport { useAccountPagesV2 } from '@burdenoff/fe-libs/ui/account-pages-v2';\nimport { ArchivedRedirect } from './v2/ArchivedRedirect';\n\n// Account & platform v2 (BOFF-16785, C1): FluidGrids' redesigned inbox and notification settings.\nconst InboxPageV2 = lazy(() => import('./v2/InboxPage').then((m) => ({ default: m.InboxPage })));\nconst PreferencesPageV2 = lazy(() =>\n import('./v2/PreferencesPage').then((m) => ({ default: m.PreferencesPage }))\n);\n\n// Lazy load - Secondary pages\nconst NotificationHistoryPage = lazy(() =>\n import('./pages/NotificationHistoryPage').then((m) => ({\n default: m.NotificationHistoryPage,\n }))\n);\nconst NotificationTemplatesPage = lazy(() =>\n import('./pages/NotificationTemplatesPage').then((m) => ({\n default: m.NotificationTemplatesPage,\n }))\n);\nconst TemplateEditorPage = lazy(() =>\n import('./pages/TemplateEditorPage').then((m) => ({ default: m.TemplateEditorPage }))\n);\nconst CreateNotificationPage = lazy(() =>\n import('./pages/CreateNotificationPage').then((m) => ({ default: m.CreateNotificationPage }))\n);\nconst NotificationTopicsPage = lazy(() =>\n import('./pages/NotificationTopicsPage').then((m) => ({ default: m.NotificationTopicsPage }))\n);\nconst NotificationPreferencesPage = lazy(() =>\n import('./pages/NotificationPreferencesPage').then((m) => ({\n default: m.NotificationPreferencesPage,\n }))\n);\n\n// Loading fallback component\nfunction PageLoader() {\n return (\n <SectionLoaderOr\n route\n minHeight=\"16rem\"\n today={\n <div className=\"flex h-64 items-center justify-center\">\n <CompactMarkOr\n className=\"h-8 w-8\"\n today={\n <div className=\"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent\" />\n }\n />\n </div>\n }\n />\n );\n}\n\n/**\n * Internal router for the Notification microfrontend.\n * This component handles routing within the microfrontend using React Router v7.\n *\n * Routes:\n * - / → Notification landing page\n * - /list → Notification center (canonical list alias used by shell nav homePath)\n * - /center → Notification center (in-app notifications)\n * - /history → Notification history and archive\n * - /templates → Notification templates list (admin)\n * - /templates/new → Create new template (admin)\n * - /templates/:templateId → Edit template (admin)\n * - /create → Create and send notification (admin)\n * - /topics → Manage topics (admin)\n * - /preferences → User topic preferences\n * - unmatched → Absolute redirect to /{basePath}/center (avoids relative redirect loops)\n */\nexport function NotificationRoutes() {\n const { basePath = '/', navigationV2 } = useNotification();\n // FluidGrids' Account & platform pages (BOFF-16785): every other host keeps the elements below.\n const v2 = useAccountPagesV2();\n const centerPath = `${basePath.endsWith('/') ? basePath.slice(0, -1) : basePath}/center`;\n\n if (navigationV2) return <NavigationV2Routes centerPath={centerPath} v2={v2} />;\n\n return (\n <Suspense fallback={<PageLoader />}>\n <Routes>\n {/* Tabbed landing - default route */}\n <Route index element={v2 ? <InboxPageV2 /> : <NotificationLandingPage />} />\n\n {/* Canonical list alias used by product-shell nav homePath */}\n <Route path=\"list\" element={v2 ? <InboxPageV2 /> : <NotificationCenterPage />} />\n\n {/* User-facing routes (all users) */}\n <Route path=\"center\" element={v2 ? <InboxPageV2 /> : <NotificationCenterPage />} />\n <Route path=\"history\" element={v2 ? <ArchivedRedirect /> : <NotificationHistoryPage />} />\n\n {/* Admin routes - Templates */}\n <Route path=\"templates\" element={<NotificationTemplatesPage />} />\n <Route path=\"templates/new\" element={<TemplateEditorPage />} />\n <Route path=\"templates/:templateId\" element={<TemplateEditorPage />} />\n\n {/* Admin routes - Create/Send Notification */}\n <Route path=\"create\" element={<CreateNotificationPage />} />\n <Route path=\"topics\" element={<NotificationTopicsPage />} />\n <Route\n path=\"preferences\"\n element={v2 ? <PreferencesPageV2 /> : <NotificationPreferencesPage />}\n />\n\n {/* Catch-all route - absolute redirect so an unmatched path like /list\n cannot recursively append /center (e.g. /list/center/center/...) */}\n <Route path=\"*\" element={<Navigate to={centerPath} replace />} />\n </Routes>\n </Suspense>\n );\n}\n\n/**\n * FluidGrids' Navigation v2 routes (BOFF-11872). Every URL of the classic\n * routes keeps working: `/` opens straight on the inbox (old `?tab=` values\n * still open their page), and the admin pages get a route-level permission\n * gate and a way back to the inbox.\n */\nexport function NavigationV2Routes({ centerPath, v2 }: { centerPath: string; v2: boolean }) {\n return (\n <Suspense fallback={<PageLoader />}>\n <Routes>\n <Route index element={v2 ? <InboxPageV2 /> : <NotificationsV2Landing />} />\n <Route path=\"list\" element={v2 ? <InboxPageV2 /> : <NotificationCenterPage />} />\n <Route path=\"center\" element={v2 ? <InboxPageV2 /> : <NotificationCenterPage />} />\n <Route path=\"history\" element={v2 ? <ArchivedRedirect /> : <NotificationHistoryPage />} />\n <Route\n path=\"preferences\"\n element={v2 ? <PreferencesPageV2 /> : <NotificationPreferencesPage />}\n />\n <Route\n path=\"templates\"\n element={\n <AdminPageV2 tool=\"templates\">\n <NotificationTemplatesPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"templates/new\"\n element={\n <AdminPageV2 tool=\"templates\">\n <TemplateEditorPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"templates/:templateId\"\n element={\n <AdminPageV2 tool=\"templates\">\n <TemplateEditorPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"create\"\n element={\n <AdminPageV2 tool=\"send\" back={false}>\n <CreateNotificationPage />\n </AdminPageV2>\n }\n />\n <Route\n path=\"topics\"\n element={\n <AdminPageV2 tool=\"topics\">\n <NotificationTopicsPage />\n </AdminPageV2>\n }\n />\n <Route path=\"delivery-log\" element={<DeliveryLogV2 />} />\n <Route path=\"*\" element={<Navigate to={centerPath} replace />} />\n </Routes>\n </Suspense>\n );\n}\n"],"mappings":";;;;;;;;;;;;AAcA,IAAMA,IAAcC,QAAW,OAAO,oBAAiB,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,UAAU,EAAE,CAAC,GACzF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,GAAD;KAAU,IAAIX;KAAY,SAAA;IAAS,CAAA;GAAI,CAAA;EAC1D,EAAA,CAAA;CACA,CAAA;AAEd"}
|
|
@@ -15,6 +15,11 @@ export type CreateNotificationInput = {
|
|
|
15
15
|
actions?: Array<NotificationActionInput> | null | undefined;
|
|
16
16
|
appName?: string | null | undefined;
|
|
17
17
|
body: string;
|
|
18
|
+
/**
|
|
19
|
+
* Feature category, a lower-case slug (letters, digits, "-", "_"; max 64),
|
|
20
|
+
* e.g. "proactive". Out-of-app copies follow the user's CATEGORY preference.
|
|
21
|
+
*/
|
|
22
|
+
category?: string | null | undefined;
|
|
18
23
|
channel: NotificationChannel;
|
|
19
24
|
data?: Record<string, unknown> | null | undefined;
|
|
20
25
|
expiresAt?: string | null | undefined;
|
|
@@ -31,6 +36,11 @@ export type CreateNotificationInput = {
|
|
|
31
36
|
type?: NotificationType | null | undefined;
|
|
32
37
|
};
|
|
33
38
|
export type CreateNotificationPreferenceInput = {
|
|
39
|
+
/**
|
|
40
|
+
* Required for scope CATEGORY: "<category>" or "<category>.<appName>", e.g.
|
|
41
|
+
* "proactive.fluidgrids". The product-level key wins over the category-wide one.
|
|
42
|
+
*/
|
|
43
|
+
category?: string | null | undefined;
|
|
34
44
|
channel?: NotificationChannel | null | undefined;
|
|
35
45
|
enabled?: boolean | null | undefined;
|
|
36
46
|
frequency?: NotificationPreferenceFrequency | null | undefined;
|
|
@@ -79,9 +89,13 @@ export type NotificationEventType = 'BOUNCED' | 'CANCELLED' | 'CLICKED' | 'COMPL
|
|
|
79
89
|
export type NotificationFilterInput = {
|
|
80
90
|
appName?: string | null | undefined;
|
|
81
91
|
archived?: boolean | null | undefined;
|
|
92
|
+
/** Only notifications in this category */
|
|
93
|
+
category?: string | null | undefined;
|
|
82
94
|
channel?: NotificationChannel | null | undefined;
|
|
83
95
|
deliveryStatus?: NotificationDeliveryStatus | null | undefined;
|
|
84
96
|
endDate?: string | null | undefined;
|
|
97
|
+
/** Also return notifications snoozed into the future (hidden by default) */
|
|
98
|
+
includeSnoozed?: boolean | null | undefined;
|
|
85
99
|
isRead?: boolean | null | undefined;
|
|
86
100
|
priority?: NotificationPriority | null | undefined;
|
|
87
101
|
search?: string | null | undefined;
|
|
@@ -108,6 +122,8 @@ export type NotificationMediaInput = {
|
|
|
108
122
|
url: string;
|
|
109
123
|
};
|
|
110
124
|
export type NotificationPreferenceFilterInput = {
|
|
125
|
+
/** CATEGORY preference key, e.g. "proactive.fluidgrids" */
|
|
126
|
+
category?: string | null | undefined;
|
|
111
127
|
channel?: NotificationChannel | null | undefined;
|
|
112
128
|
enabled?: boolean | null | undefined;
|
|
113
129
|
scope?: NotificationPreferenceScope | null | undefined;
|
|
@@ -116,7 +132,9 @@ export type NotificationPreferenceFilterInput = {
|
|
|
116
132
|
userId?: string | number | null | undefined;
|
|
117
133
|
};
|
|
118
134
|
export type NotificationPreferenceFrequency = 'DAILY_DIGEST' | 'IMMEDIATE' | 'NEVER' | 'WEEKLY_DIGEST';
|
|
119
|
-
export type NotificationPreferenceScope =
|
|
135
|
+
export type NotificationPreferenceScope =
|
|
136
|
+
/** Feature category (e.g. proactive), optionally per app: key "proactive.fluidgrids" */
|
|
137
|
+
'CATEGORY' | 'CHANNEL' | 'GLOBAL' | 'TOPIC' | 'TYPE';
|
|
120
138
|
export type NotificationPriority = 'HIGH' | 'LOW' | 'MEDIUM' | 'URGENT';
|
|
121
139
|
export type NotificationStatus = 'CANCELLED' | 'DELIVERED' | 'DRAFT' | 'EXPIRED' | 'FAILED' | 'PENDING' | 'READ' | 'SCHEDULED' | 'SENT' | 'TRIGGERED';
|
|
122
140
|
export type NotificationTopicFilterInput = {
|
|
@@ -188,8 +206,6 @@ export type TriggerBatchNotificationsInput = {
|
|
|
188
206
|
export type TriggerNotificationInput = {
|
|
189
207
|
/** Specific channel instance ID from channel service (takes precedence) */
|
|
190
208
|
channelId?: string | number | null | undefined;
|
|
191
|
-
/** Channels to deliver to (deprecated - use channelId or platform instead) */
|
|
192
|
-
channels?: Array<NotificationChannel> | null | undefined;
|
|
193
209
|
/** Also deliver as in-app notification alongside the primary platform */
|
|
194
210
|
includeInApp?: boolean | null | undefined;
|
|
195
211
|
/** Or create and trigger a new notification */
|
|
@@ -203,9 +219,13 @@ export type TriggerNotificationInput = {
|
|
|
203
219
|
};
|
|
204
220
|
export type TriggerNotificationWithTemplateInput = {
|
|
205
221
|
actions?: Array<NotificationActionInput> | null | undefined;
|
|
222
|
+
/** Feature category stored on every created notification, e.g. "proactive" */
|
|
223
|
+
category?: string | null | undefined;
|
|
206
224
|
/** Specific channel instance ID from channel service (takes precedence) */
|
|
207
225
|
channelId?: string | number | null | undefined;
|
|
208
226
|
expiresAt?: string | null | undefined;
|
|
227
|
+
/** At-most-once delivery key forwarded to channel-svc (same key + same input = one delivery) */
|
|
228
|
+
idempotencyKey?: string | null | undefined;
|
|
209
229
|
/** Also deliver as in-app notification alongside the primary platform */
|
|
210
230
|
includeInApp?: boolean | null | undefined;
|
|
211
231
|
media?: Array<NotificationMediaInput> | null | undefined;
|
|
@@ -230,6 +250,8 @@ export type TriggerNotificationWithTemplateInput = {
|
|
|
230
250
|
};
|
|
231
251
|
export type TriggerStatus = 'CANCELLED' | 'FAILED' | 'PENDING' | 'TRIGGERED';
|
|
232
252
|
export type UpdateNotificationPreferenceInput = {
|
|
253
|
+
/** CATEGORY preference key; see CreateNotificationPreferenceInput.category */
|
|
254
|
+
category?: string | null | undefined;
|
|
233
255
|
channel?: NotificationChannel | null | undefined;
|
|
234
256
|
enabled?: boolean | null | undefined;
|
|
235
257
|
frequency?: NotificationPreferenceFrequency | null | undefined;
|
|
@@ -547,6 +569,16 @@ export type MarkNotificationAsReadMutation = {
|
|
|
547
569
|
status: Types.NotificationStatus;
|
|
548
570
|
};
|
|
549
571
|
};
|
|
572
|
+
export type MarkNotificationAsUnreadMutationVariables = Exact<{
|
|
573
|
+
id: string | number;
|
|
574
|
+
}>;
|
|
575
|
+
export type MarkNotificationAsUnreadMutation = {
|
|
576
|
+
markNotificationAsUnread: {
|
|
577
|
+
id: string;
|
|
578
|
+
readAt: string | null;
|
|
579
|
+
isRead: boolean;
|
|
580
|
+
};
|
|
581
|
+
};
|
|
550
582
|
export type MarkNotificationsAsReadMutationVariables = Exact<{
|
|
551
583
|
notificationIds: Array<string | number> | string | number;
|
|
552
584
|
}>;
|
|
@@ -1481,6 +1513,29 @@ export declare function useMarkNotificationAsReadMutation(baseOptions?: ApolloRe
|
|
|
1481
1513
|
export type MarkNotificationAsReadMutationHookResult = ReturnType<typeof useMarkNotificationAsReadMutation>;
|
|
1482
1514
|
export type MarkNotificationAsReadMutationResult = Apollo.MutationResult<Types.MarkNotificationAsReadMutation>;
|
|
1483
1515
|
export type MarkNotificationAsReadMutationOptions = Apollo.BaseMutationOptions<Types.MarkNotificationAsReadMutation, Types.MarkNotificationAsReadMutationVariables>;
|
|
1516
|
+
export declare const MarkNotificationAsUnreadDocument: Apollo.DocumentNode;
|
|
1517
|
+
export type MarkNotificationAsUnreadMutationFn = Apollo.MutationFunction<Types.MarkNotificationAsUnreadMutation, Types.MarkNotificationAsUnreadMutationVariables>;
|
|
1518
|
+
/**
|
|
1519
|
+
* __useMarkNotificationAsUnreadMutation__
|
|
1520
|
+
*
|
|
1521
|
+
* To run a mutation, you first call `useMarkNotificationAsUnreadMutation` within a React component and pass it any options that fit your needs.
|
|
1522
|
+
* When your component renders, `useMarkNotificationAsUnreadMutation` returns a tuple that includes:
|
|
1523
|
+
* - A mutate function that you can call at any time to execute the mutation
|
|
1524
|
+
* - An object with fields that represent the current status of the mutation's execution
|
|
1525
|
+
*
|
|
1526
|
+
* @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2;
|
|
1527
|
+
*
|
|
1528
|
+
* @example
|
|
1529
|
+
* const [markNotificationAsUnreadMutation, { data, loading, error }] = useMarkNotificationAsUnreadMutation({
|
|
1530
|
+
* variables: {
|
|
1531
|
+
* id: // value for 'id'
|
|
1532
|
+
* },
|
|
1533
|
+
* });
|
|
1534
|
+
*/
|
|
1535
|
+
export declare function useMarkNotificationAsUnreadMutation(baseOptions?: ApolloReactHooks.MutationHookOptions<Types.MarkNotificationAsUnreadMutation, Types.MarkNotificationAsUnreadMutationVariables>): ApolloReactHooks.useMutation.ResultTuple<Types.MarkNotificationAsUnreadMutation, any, Apollo.ApolloCache, undefined>;
|
|
1536
|
+
export type MarkNotificationAsUnreadMutationHookResult = ReturnType<typeof useMarkNotificationAsUnreadMutation>;
|
|
1537
|
+
export type MarkNotificationAsUnreadMutationResult = Apollo.MutationResult<Types.MarkNotificationAsUnreadMutation>;
|
|
1538
|
+
export type MarkNotificationAsUnreadMutationOptions = Apollo.BaseMutationOptions<Types.MarkNotificationAsUnreadMutation, Types.MarkNotificationAsUnreadMutationVariables>;
|
|
1484
1539
|
export declare const MarkNotificationsAsReadDocument: Apollo.DocumentNode;
|
|
1485
1540
|
export type MarkNotificationsAsReadMutationFn = Apollo.MutationFunction<Types.MarkNotificationsAsReadMutation, Types.MarkNotificationsAsReadMutationVariables>;
|
|
1486
1541
|
/**
|
|
@@ -220,6 +220,14 @@ var _ = e`
|
|
|
220
220
|
readAt
|
|
221
221
|
status
|
|
222
222
|
}
|
|
223
|
+
}
|
|
224
|
+
`, y = e`
|
|
225
|
+
mutation MarkNotificationAsUnread($id: ID!) {
|
|
226
|
+
markNotificationAsUnread(id: $id) {
|
|
227
|
+
id
|
|
228
|
+
readAt
|
|
229
|
+
isRead
|
|
230
|
+
}
|
|
223
231
|
}
|
|
224
232
|
`;
|
|
225
233
|
e`
|
|
@@ -231,7 +239,7 @@ e`
|
|
|
231
239
|
}
|
|
232
240
|
}
|
|
233
241
|
`;
|
|
234
|
-
var
|
|
242
|
+
var b = e`
|
|
235
243
|
mutation RecordNotificationAction($input: RecordNotificationActionInput!) {
|
|
236
244
|
recordNotificationAction(input: $input) {
|
|
237
245
|
id
|
|
@@ -240,7 +248,7 @@ var y = e`
|
|
|
240
248
|
status
|
|
241
249
|
}
|
|
242
250
|
}
|
|
243
|
-
`,
|
|
251
|
+
`, x = e`
|
|
244
252
|
mutation RescheduleNotification($input: RescheduleNotificationInput!) {
|
|
245
253
|
rescheduleNotification(input: $input) {
|
|
246
254
|
id
|
|
@@ -250,7 +258,7 @@ var y = e`
|
|
|
250
258
|
retryCount
|
|
251
259
|
}
|
|
252
260
|
}
|
|
253
|
-
`,
|
|
261
|
+
`, S = e`
|
|
254
262
|
mutation SetNotificationTopicSubscription($input: SetNotificationTopicSubscriptionInput!) {
|
|
255
263
|
setNotificationTopicSubscription(input: $input) {
|
|
256
264
|
id
|
|
@@ -260,7 +268,7 @@ var y = e`
|
|
|
260
268
|
userId
|
|
261
269
|
}
|
|
262
270
|
}
|
|
263
|
-
`,
|
|
271
|
+
`, C = e`
|
|
264
272
|
mutation TriggerBatchNotifications($input: TriggerBatchNotificationsInput!) {
|
|
265
273
|
triggerBatchNotifications(input: $input) {
|
|
266
274
|
batchId
|
|
@@ -270,7 +278,7 @@ var y = e`
|
|
|
270
278
|
totalTriggered
|
|
271
279
|
}
|
|
272
280
|
}
|
|
273
|
-
`,
|
|
281
|
+
`, w = e`
|
|
274
282
|
mutation TriggerNotification($input: TriggerNotificationInput!) {
|
|
275
283
|
triggerNotification(input: $input) {
|
|
276
284
|
id
|
|
@@ -282,7 +290,7 @@ var y = e`
|
|
|
282
290
|
message
|
|
283
291
|
}
|
|
284
292
|
}
|
|
285
|
-
`,
|
|
293
|
+
`, T = e`
|
|
286
294
|
mutation TriggerNotificationWithTemplate($input: TriggerNotificationWithTemplateInput!) {
|
|
287
295
|
triggerNotificationWithTemplate(input: $input) {
|
|
288
296
|
totalRequested
|
|
@@ -297,7 +305,7 @@ var y = e`
|
|
|
297
305
|
}
|
|
298
306
|
}
|
|
299
307
|
}
|
|
300
|
-
`,
|
|
308
|
+
`, E = e`
|
|
301
309
|
mutation UnarchiveNotification($id: ID!) {
|
|
302
310
|
unarchiveNotification(id: $id) {
|
|
303
311
|
id
|
|
@@ -305,14 +313,14 @@ var y = e`
|
|
|
305
313
|
status
|
|
306
314
|
}
|
|
307
315
|
}
|
|
308
|
-
`,
|
|
316
|
+
`, D = e`
|
|
309
317
|
mutation UpdateNotificationPreference($id: ID!, $input: UpdateNotificationPreferenceInput!) {
|
|
310
318
|
updateNotificationPreference(id: $id, input: $input) {
|
|
311
319
|
...NotificationPreferenceFields
|
|
312
320
|
}
|
|
313
321
|
}
|
|
314
322
|
${s}
|
|
315
|
-
${t}`,
|
|
323
|
+
${t}`, O = e`
|
|
316
324
|
mutation UpdateNotificationTemplate($id: ID!, $input: UpdateTemplateInput!) {
|
|
317
325
|
updateNotificationTemplate(id: $id, input: $input) {
|
|
318
326
|
id
|
|
@@ -333,7 +341,7 @@ ${t}`, D = e`
|
|
|
333
341
|
metadata
|
|
334
342
|
}
|
|
335
343
|
}
|
|
336
|
-
`,
|
|
344
|
+
`, k = e`
|
|
337
345
|
mutation UpdateNotificationTopic($id: ID!, $input: UpdateNotificationTopicInput!) {
|
|
338
346
|
updateNotificationTopic(id: $id, input: $input) {
|
|
339
347
|
id
|
|
@@ -346,11 +354,11 @@ ${t}`, D = e`
|
|
|
346
354
|
updatedAt
|
|
347
355
|
}
|
|
348
356
|
}
|
|
349
|
-
`,
|
|
357
|
+
`, A = e`
|
|
350
358
|
query GetMyUnreadNotificationCount($filter: NotificationFilterInput) {
|
|
351
359
|
myUnreadNotificationCount(filter: $filter)
|
|
352
360
|
}
|
|
353
|
-
`,
|
|
361
|
+
`, j = e`
|
|
354
362
|
query GetNotification($id: ID!) {
|
|
355
363
|
notification(id: $id) {
|
|
356
364
|
...NotificationFields
|
|
@@ -367,7 +375,7 @@ ${t}`, D = e`
|
|
|
367
375
|
${t}
|
|
368
376
|
${n}
|
|
369
377
|
${r}
|
|
370
|
-
${i}`,
|
|
378
|
+
${i}`, M = e`
|
|
371
379
|
query GetNotificationEvents($notificationId: ID!) {
|
|
372
380
|
notificationEvents(notificationId: $notificationId) {
|
|
373
381
|
id
|
|
@@ -393,7 +401,7 @@ e`
|
|
|
393
401
|
}
|
|
394
402
|
}
|
|
395
403
|
${o}`;
|
|
396
|
-
var
|
|
404
|
+
var N = e`
|
|
397
405
|
query GetNotificationPreferences($filter: NotificationPreferenceFilterInput, $limit: Int, $offset: Int) {
|
|
398
406
|
notificationPreferences(filter: $filter, limit: $limit, offset: $offset) {
|
|
399
407
|
items {
|
|
@@ -421,7 +429,7 @@ e`
|
|
|
421
429
|
}
|
|
422
430
|
}
|
|
423
431
|
`;
|
|
424
|
-
var
|
|
432
|
+
var P = e`
|
|
425
433
|
query GetNotificationTemplate($slug: String!, $locale: String) {
|
|
426
434
|
notificationTemplate(slug: $slug, locale: $locale) {
|
|
427
435
|
id
|
|
@@ -442,7 +450,7 @@ var N = e`
|
|
|
442
450
|
metadata
|
|
443
451
|
}
|
|
444
452
|
}
|
|
445
|
-
`,
|
|
453
|
+
`, F = e`
|
|
446
454
|
query GetNotificationTemplates($filter: TemplateFilterInput, $limit: Int, $offset: Int) {
|
|
447
455
|
notificationTemplates(filter: $filter, limit: $limit, offset: $offset) {
|
|
448
456
|
items {
|
|
@@ -467,7 +475,7 @@ var N = e`
|
|
|
467
475
|
hasMore
|
|
468
476
|
}
|
|
469
477
|
}
|
|
470
|
-
`,
|
|
478
|
+
`, I = e`
|
|
471
479
|
query GetNotificationTopics($filter: NotificationTopicFilterInput, $limit: Int, $offset: Int) {
|
|
472
480
|
notificationTopics(filter: $filter, limit: $limit, offset: $offset) {
|
|
473
481
|
items {
|
|
@@ -493,7 +501,7 @@ var N = e`
|
|
|
493
501
|
hasMore
|
|
494
502
|
}
|
|
495
503
|
}
|
|
496
|
-
`,
|
|
504
|
+
`, L = e`
|
|
497
505
|
query GetNotifications($filter: NotificationFilterInput, $limit: Int, $offset: Int) {
|
|
498
506
|
notifications(filter: $filter, limit: $limit, offset: $offset) {
|
|
499
507
|
items {
|
|
@@ -507,7 +515,7 @@ var N = e`
|
|
|
507
515
|
${t}
|
|
508
516
|
${n}
|
|
509
517
|
${r}
|
|
510
|
-
${i}`,
|
|
518
|
+
${i}`, R = e`
|
|
511
519
|
query GetScheduledNotifications($filter: ScheduledNotificationFilterInput, $limit: Int, $offset: Int) {
|
|
512
520
|
scheduledNotifications(filter: $filter, limit: $limit, offset: $offset) {
|
|
513
521
|
items {
|
|
@@ -533,7 +541,7 @@ ${i}`, L = e`
|
|
|
533
541
|
hasMore
|
|
534
542
|
}
|
|
535
543
|
}
|
|
536
|
-
`,
|
|
544
|
+
`, z = e`
|
|
537
545
|
query SearchUsers($filter: UserFilterInput, $pagination: PaginationInput) {
|
|
538
546
|
users(filter: $filter, pagination: $pagination) {
|
|
539
547
|
users {
|
|
@@ -548,7 +556,7 @@ ${i}`, L = e`
|
|
|
548
556
|
totalCount
|
|
549
557
|
}
|
|
550
558
|
}
|
|
551
|
-
`,
|
|
559
|
+
`, B = e`
|
|
552
560
|
subscription NotificationReceived($userId: ID!) {
|
|
553
561
|
notificationReceived(userId: $userId) {
|
|
554
562
|
...NotificationFields
|
|
@@ -558,11 +566,11 @@ ${i}`, L = e`
|
|
|
558
566
|
${t}
|
|
559
567
|
${n}
|
|
560
568
|
${r}
|
|
561
|
-
${i}`,
|
|
569
|
+
${i}`, V = e`
|
|
562
570
|
subscription UnreadCountUpdated($userId: ID!) {
|
|
563
571
|
unreadCountUpdated(userId: $userId)
|
|
564
572
|
}
|
|
565
573
|
`;
|
|
566
|
-
export { c as ArchiveNotificationDocument, l as ArchiveNotificationsDocument, u as CancelScheduledNotificationDocument, d as CreateNotificationPreferenceDocument, f as CreateNotificationTemplateDocument, p as CreateNotificationTopicDocument, m as DeleteNotificationPreferenceDocument, h as DeleteNotificationTemplateDocument, g as DeleteNotificationTopicDocument,
|
|
574
|
+
export { c as ArchiveNotificationDocument, l as ArchiveNotificationsDocument, u as CancelScheduledNotificationDocument, d as CreateNotificationPreferenceDocument, f as CreateNotificationTemplateDocument, p as CreateNotificationTopicDocument, m as DeleteNotificationPreferenceDocument, h as DeleteNotificationTemplateDocument, g as DeleteNotificationTopicDocument, A as GetMyUnreadNotificationCountDocument, j as GetNotificationDocument, M as GetNotificationEventsDocument, N as GetNotificationPreferencesDocument, P as GetNotificationTemplateDocument, F as GetNotificationTemplatesDocument, I as GetNotificationTopicsDocument, L as GetNotificationsDocument, R as GetScheduledNotificationsDocument, _ as MarkAllMyNotificationsAsReadDocument, v as MarkNotificationAsReadDocument, y as MarkNotificationAsUnreadDocument, n as NotificationActionFieldsFragmentDoc, a as NotificationFieldsFragmentDoc, o as NotificationHistoryFieldsFragmentDoc, r as NotificationMediaFieldsFragmentDoc, s as NotificationPreferenceFieldsFragmentDoc, B as NotificationReceivedDocument, t as NotificationTopicSummaryFieldsFragmentDoc, b as RecordNotificationActionDocument, x as RescheduleNotificationDocument, i as ScheduledNotificationSummaryFieldsFragmentDoc, z as SearchUsersDocument, S as SetNotificationTopicSubscriptionDocument, C as TriggerBatchNotificationsDocument, w as TriggerNotificationDocument, T as TriggerNotificationWithTemplateDocument, E as UnarchiveNotificationDocument, V as UnreadCountUpdatedDocument, D as UpdateNotificationPreferenceDocument, O as UpdateNotificationTemplateDocument, k as UpdateNotificationTopicDocument };
|
|
567
575
|
|
|
568
576
|
//# sourceMappingURL=global-operations.js.map
|