@burdenoff/microfe-notification 2026.830.1 → 2026.830.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,81 +1,83 @@
1
1
  import { NotificationProvider as e } from "./providers/NotificationProvider.js";
2
- import { AdminNotificationRoutes as t } from "./AdminNotificationRoutes.js";
3
- import { useEffect as n } from "react";
4
- import { ErrorBoundary as r } from "@burdenoff/fe-libs/shared/components";
5
- import { useFeatureFlagDetails as i } from "@burdenoff/fe-libs/shared/feature-flags";
6
- import { Archive as a, Bell as o, FileText as s, Send as c, Tag as l } from "lucide-react";
7
- import { jsx as u } from "react/jsx-runtime";
2
+ import { useTr as t } from "./shared/hooks/useTr.js";
3
+ import { AdminNotificationRoutes as n } from "./AdminNotificationRoutes.js";
4
+ import { useEffect as r } from "react";
5
+ import { ErrorBoundary as i } from "@burdenoff/fe-libs/shared/components";
6
+ import { useFeatureFlagDetails as a } from "@burdenoff/fe-libs/shared/feature-flags";
7
+ import { Archive as o, Bell as s, FileText as c, Send as l, Tag as u } from "lucide-react";
8
+ import { jsx as d } from "react/jsx-runtime";
8
9
  //#region src/AdminNotificationRoot.tsx
9
- function d(d) {
10
- let { registerNavItems: f, registerFooterItems: p, basePath: m = "/" } = d, h = i("notification.templates"), g = i("notification.create"), _ = i("notification.history"), v = h ? !!h.value : !1, y = g ? !!g.value : !1, b = _ ? !!_.value : !1, x = (e, t) => (e.endsWith("/") ? e.slice(0, -1) : e) + (t.startsWith("/") ? t : `/${t}`);
11
- return n(() => {
12
- if (f) return f([
10
+ function f(f) {
11
+ let { registerNavItems: p, registerFooterItems: m, basePath: h = "/" } = f, g = t(), _ = a("notification.templates"), v = a("notification.create"), y = a("notification.history"), b = _ ? !!_.value : !1, x = v ? !!v.value : !1, S = y ? !!y.value : !1, C = (e, t) => (e.endsWith("/") ? e.slice(0, -1) : e) + (t.startsWith("/") ? t : `/${t}`);
12
+ return r(() => {
13
+ if (p) return p([
13
14
  {
14
15
  id: "admin-notification-center",
15
- label: "Notification Center",
16
- path: x(m, "center"),
17
- icon: /* @__PURE__ */ u(o, { size: 20 }),
16
+ label: g("notification.nav.center", "Notification Center"),
17
+ path: C(h, "center"),
18
+ icon: /* @__PURE__ */ d(s, { size: 20 }),
18
19
  order: 10,
19
20
  group: "notifications"
20
21
  },
21
- ...b ? [{
22
+ ...S ? [{
22
23
  id: "admin-notification-history",
23
- label: "History",
24
- path: x(m, "history"),
25
- icon: /* @__PURE__ */ u(a, { size: 20 }),
24
+ label: g("notification.nav.history", "History"),
25
+ path: C(h, "history"),
26
+ icon: /* @__PURE__ */ d(o, { size: 20 }),
26
27
  order: 20,
27
28
  group: "notifications"
28
29
  }] : [],
29
- ...v ? [{
30
+ ...b ? [{
30
31
  id: "admin-notification-templates",
31
- label: "Templates",
32
- path: x(m, "templates"),
33
- icon: /* @__PURE__ */ u(s, { size: 20 }),
32
+ label: g("notification.nav.templates", "Templates"),
33
+ path: C(h, "templates"),
34
+ icon: /* @__PURE__ */ d(c, { size: 20 }),
34
35
  order: 30,
35
36
  group: "notifications"
36
37
  }] : [],
37
- ...y ? [{
38
+ ...x ? [{
38
39
  id: "admin-notification-create",
39
- label: "Send Notification",
40
- path: x(m, "create"),
41
- icon: /* @__PURE__ */ u(c, { size: 20 }),
40
+ label: g("notification.nav.send", "Send Notification"),
41
+ path: C(h, "create"),
42
+ icon: /* @__PURE__ */ d(l, { size: 20 }),
42
43
  order: 40,
43
44
  group: "notifications"
44
45
  }, {
45
46
  id: "admin-notification-topics",
46
- label: "Topics",
47
- path: x(m, "topics"),
48
- icon: /* @__PURE__ */ u(l, { size: 20 }),
47
+ label: g("notification.nav.topics", "Topics"),
48
+ path: C(h, "topics"),
49
+ icon: /* @__PURE__ */ d(u, { size: 20 }),
49
50
  order: 50,
50
51
  group: "notifications"
51
52
  }] : []
52
53
  ]);
53
54
  }, [
54
- f,
55
- m,
55
+ p,
56
+ h,
57
+ S,
56
58
  b,
57
- v,
58
- y
59
- ]), n(() => {
60
- if (p) return p([{
59
+ x,
60
+ g
61
+ ]), r(() => {
62
+ if (m) return m([{
61
63
  id: "admin-notification-status",
62
- label: "Notifications Ready",
64
+ label: g("notification.footer.ready", "Notifications Ready"),
63
65
  type: "status",
64
66
  order: 10,
65
67
  section: "left"
66
68
  }]);
67
- }, [p]), /* @__PURE__ */ u(r, {
68
- fallback: /* @__PURE__ */ u("div", {
69
+ }, [m, g]), /* @__PURE__ */ d(i, {
70
+ fallback: /* @__PURE__ */ d("div", {
69
71
  className: "p-6 text-center text-text-secondary",
70
- children: "Something went wrong loading this module. Please refresh the page."
72
+ children: g("notification.error.moduleLoad", "Something went wrong loading this module. Please refresh the page.")
71
73
  }),
72
- children: /* @__PURE__ */ u(e, {
73
- ...d,
74
- children: /* @__PURE__ */ u(t, {})
74
+ children: /* @__PURE__ */ d(e, {
75
+ ...f,
76
+ children: /* @__PURE__ */ d(n, {})
75
77
  })
76
78
  });
77
79
  }
78
80
  //#endregion
79
- export { d as AdminNotificationRoot };
81
+ export { f as AdminNotificationRoot };
80
82
 
81
83
  //# sourceMappingURL=AdminNotificationRoot.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"AdminNotificationRoot.js","names":[],"sources":["../src/AdminNotificationRoot.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { ErrorBoundary } from '@burdenoff/fe-libs/shared/components';\nimport { useFeatureFlagDetails } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { Bell, Archive, FileText, Send, Tag } from 'lucide-react';\nimport { NotificationProvider } from './providers/NotificationProvider';\nimport type { NavItem, FooterItem, NotificationRootProps } from './types';\nimport { AdminNotificationRoutes } from './AdminNotificationRoutes';\n\n/**\n * Admin Root component for the Notification microfrontend.\n *\n * This is the full admin entry point intended for `admin-app`. It exposes all\n * notification surfaces (Notification Center, History, Templates, Create &\n * Send) and sets up the required provider stack. In-page actions remain gated\n * by RBAC via `usePermissions` checks.\n *\n * For product shells that only need user-facing surfaces, use\n * `UserNotificationRoot` instead.\n *\n * @example\n * ```tsx\n * import { AdminNotificationRoot, type NotificationRootProps } from '@burdenoff/micro-fe/notification';\n *\n * function App() {\n * const props: NotificationRootProps = {\n * basePath: '/notifications',\n * navigate: (path) => router.push(path),\n * currentUser: { id: '1', email: 'user@example.com' },\n * workspaceId: 'ws-123',\n * apiGatewayUrl: 'https://api.example.com',\n * authToken: 'token',\n * registerNavItems: (items) => { return () => {}; },\n * onNotificationClick: (notification) => console.log('Clicked:', notification),\n * };\n *\n * return <AdminNotificationRoot {...props} />;\n * }\n * ```\n */\nexport function AdminNotificationRoot(props: NotificationRootProps) {\n const { registerNavItems, registerFooterItems, basePath = '/' } = props;\n\n // Component-level feature gates. `notification.*` flags are declared as\n // unreleased (defaultValue=false). We use `useFeatureFlagDetails` and\n // explicitly fall back to `false` when the flag is absent from the cache,\n // because the provider's global default-allow would otherwise return `true`\n // for unseeded flags — which would defeat the whole point of the unreleased\n // pattern.\n const templatesDetails = useFeatureFlagDetails('notification.templates');\n const createDetails = useFeatureFlagDetails('notification.create');\n const historyDetails = useFeatureFlagDetails('notification.history');\n const templatesEnabled = templatesDetails ? Boolean(templatesDetails.value) : false;\n const createEnabled = createDetails ? Boolean(createDetails.value) : false;\n const historyEnabled = historyDetails ? Boolean(historyDetails.value) : false;\n\n // Helper to join paths correctly, avoiding double slashes\n const joinPath = (base: string, path: string): string => {\n const cleanBase = base.endsWith('/') ? base.slice(0, -1) : base;\n const cleanPath = path.startsWith('/') ? path : `/${path}`;\n return cleanBase + cleanPath;\n };\n\n // Register navigation items with the shell (admin - full surface)\n useEffect(() => {\n if (!registerNavItems) return;\n\n const navItems: NavItem[] = [\n {\n id: 'admin-notification-center',\n label: 'Notification Center',\n path: joinPath(basePath, 'center'),\n icon: <Bell size={20} />,\n order: 10,\n group: 'notifications',\n },\n ...(historyEnabled\n ? [\n {\n id: 'admin-notification-history',\n label: 'History',\n path: joinPath(basePath, 'history'),\n icon: <Archive size={20} />,\n order: 20,\n group: 'notifications',\n },\n ]\n : []),\n ...(templatesEnabled\n ? [\n {\n id: 'admin-notification-templates',\n label: 'Templates',\n path: joinPath(basePath, 'templates'),\n icon: <FileText size={20} />,\n order: 30,\n group: 'notifications',\n },\n ]\n : []),\n ...(createEnabled\n ? [\n {\n id: 'admin-notification-create',\n label: 'Send Notification',\n path: joinPath(basePath, 'create'),\n icon: <Send size={20} />,\n order: 40,\n group: 'notifications',\n },\n {\n id: 'admin-notification-topics',\n label: 'Topics',\n path: joinPath(basePath, 'topics'),\n icon: <Tag size={20} />,\n order: 50,\n group: 'notifications',\n },\n ]\n : []),\n ];\n\n // Register and get cleanup function\n const cleanup = registerNavItems(navItems);\n\n // Return cleanup function to unregister on unmount\n return cleanup;\n }, [registerNavItems, basePath, historyEnabled, templatesEnabled, createEnabled]);\n\n // Register footer items (status indicator in left section)\n useEffect(() => {\n if (!registerFooterItems) return;\n\n const footerItems: FooterItem[] = [\n {\n id: 'admin-notification-status',\n label: 'Notifications Ready',\n type: 'status',\n order: 10,\n section: 'left',\n },\n ];\n\n const cleanup = registerFooterItems(footerItems);\n return cleanup;\n }, [registerFooterItems]);\n\n return (\n <ErrorBoundary\n fallback={\n <div className=\"p-6 text-center text-text-secondary\">\n Something went wrong loading this module. Please refresh the page.\n </div>\n }\n >\n <NotificationProvider {...props}>\n <AdminNotificationRoutes />\n </NotificationProvider>\n </ErrorBoundary>\n );\n}\n"],"mappings":";;;;;;;;AAuCA,SAAgB,EAAsB,GAA8B;CAClE,IAAM,EAAE,qBAAkB,wBAAqB,cAAW,QAAQ,GAQ5D,IAAmB,EAAsB,yBAAyB,EAClE,IAAgB,EAAsB,sBAAsB,EAC5D,IAAiB,EAAsB,uBAAuB,EAC9D,IAAmB,IAAmB,EAAQ,EAAiB,QAAS,IACxE,IAAgB,IAAgB,EAAQ,EAAc,QAAS,IAC/D,IAAiB,IAAiB,EAAQ,EAAe,QAAS,IAGlE,KAAY,GAAc,OACZ,EAAK,SAAS,IAAI,GAAG,EAAK,MAAM,GAAG,GAAG,GAAG,MACzC,EAAK,WAAW,IAAI,GAAG,IAAO,IAAI;AAwFtD,QAnFA,QAAgB;AACT,QA6DL,QAHgB,EAxDY;GAC1B;IACE,IAAI;IACJ,OAAO;IACP,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR;GACD,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO;IACP,MAAM,EAAS,GAAU,UAAU;IACnC,MAAM,kBAAC,GAAD,EAAS,MAAM,IAAM,CAAA;IAC3B,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACN,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO;IACP,MAAM,EAAS,GAAU,YAAY;IACrC,MAAM,kBAAC,GAAD,EAAU,MAAM,IAAM,CAAA;IAC5B,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACN,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO;IACP,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR,EACD;IACE,IAAI;IACJ,OAAO;IACP,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAK,MAAM,IAAM,CAAA;IACvB,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACP,CAGyC;IAIzC;EAAC;EAAkB;EAAU;EAAgB;EAAkB;EAAc,CAAC,EAGjF,QAAgB;AACT,QAaL,QADgB,EAVkB,CAChC;GACE,IAAI;GACJ,OAAO;GACP,MAAM;GACN,OAAO;GACP,SAAS;GACV,CACF,CAE+C;IAE/C,CAAC,EAAoB,CAAC,EAGvB,kBAAC,GAAD;EACE,UACE,kBAAC,OAAD;GAAK,WAAU;aAAsC;GAE/C,CAAA;YAGR,kBAAC,GAAD;GAAsB,GAAI;aACxB,kBAAC,GAAD,EAA2B,CAAA;GACN,CAAA;EACT,CAAA"}
1
+ {"version":3,"file":"AdminNotificationRoot.js","names":[],"sources":["../src/AdminNotificationRoot.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { ErrorBoundary } from '@burdenoff/fe-libs/shared/components';\nimport { useFeatureFlagDetails } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { Bell, Archive, FileText, Send, Tag } from 'lucide-react';\nimport { NotificationProvider } from './providers/NotificationProvider';\nimport { useTr } from './shared/hooks/useTr';\nimport type { NavItem, FooterItem, NotificationRootProps } from './types';\nimport { AdminNotificationRoutes } from './AdminNotificationRoutes';\n\n/**\n * Admin Root component for the Notification microfrontend.\n *\n * This is the full admin entry point intended for `admin-app`. It exposes all\n * notification surfaces (Notification Center, History, Templates, Create &\n * Send) and sets up the required provider stack. In-page actions remain gated\n * by RBAC via `usePermissions` checks.\n *\n * For product shells that only need user-facing surfaces, use\n * `UserNotificationRoot` instead.\n *\n * @example\n * ```tsx\n * import { AdminNotificationRoot, type NotificationRootProps } from '@burdenoff/micro-fe/notification';\n *\n * function App() {\n * const props: NotificationRootProps = {\n * basePath: '/notifications',\n * navigate: (path) => router.push(path),\n * currentUser: { id: '1', email: 'user@example.com' },\n * workspaceId: 'ws-123',\n * apiGatewayUrl: 'https://api.example.com',\n * authToken: 'token',\n * registerNavItems: (items) => { return () => {}; },\n * onNotificationClick: (notification) => console.log('Clicked:', notification),\n * };\n *\n * return <AdminNotificationRoot {...props} />;\n * }\n * ```\n */\nexport function AdminNotificationRoot(props: NotificationRootProps) {\n const { registerNavItems, registerFooterItems, basePath = '/' } = props;\n const tr = useTr();\n\n // Component-level feature gates. `notification.*` flags are declared as\n // unreleased (defaultValue=false). We use `useFeatureFlagDetails` and\n // explicitly fall back to `false` when the flag is absent from the cache,\n // because the provider's global default-allow would otherwise return `true`\n // for unseeded flags — which would defeat the whole point of the unreleased\n // pattern.\n const templatesDetails = useFeatureFlagDetails('notification.templates');\n const createDetails = useFeatureFlagDetails('notification.create');\n const historyDetails = useFeatureFlagDetails('notification.history');\n const templatesEnabled = templatesDetails ? Boolean(templatesDetails.value) : false;\n const createEnabled = createDetails ? Boolean(createDetails.value) : false;\n const historyEnabled = historyDetails ? Boolean(historyDetails.value) : false;\n\n // Helper to join paths correctly, avoiding double slashes\n const joinPath = (base: string, path: string): string => {\n const cleanBase = base.endsWith('/') ? base.slice(0, -1) : base;\n const cleanPath = path.startsWith('/') ? path : `/${path}`;\n return cleanBase + cleanPath;\n };\n\n // Register navigation items with the shell (admin - full surface)\n useEffect(() => {\n if (!registerNavItems) return;\n\n const navItems: NavItem[] = [\n {\n id: 'admin-notification-center',\n label: tr('notification.nav.center', 'Notification Center'),\n path: joinPath(basePath, 'center'),\n icon: <Bell size={20} />,\n order: 10,\n group: 'notifications',\n },\n ...(historyEnabled\n ? [\n {\n id: 'admin-notification-history',\n label: tr('notification.nav.history', 'History'),\n path: joinPath(basePath, 'history'),\n icon: <Archive size={20} />,\n order: 20,\n group: 'notifications',\n },\n ]\n : []),\n ...(templatesEnabled\n ? [\n {\n id: 'admin-notification-templates',\n label: tr('notification.nav.templates', 'Templates'),\n path: joinPath(basePath, 'templates'),\n icon: <FileText size={20} />,\n order: 30,\n group: 'notifications',\n },\n ]\n : []),\n ...(createEnabled\n ? [\n {\n id: 'admin-notification-create',\n label: tr('notification.nav.send', 'Send Notification'),\n path: joinPath(basePath, 'create'),\n icon: <Send size={20} />,\n order: 40,\n group: 'notifications',\n },\n {\n id: 'admin-notification-topics',\n label: tr('notification.nav.topics', 'Topics'),\n path: joinPath(basePath, 'topics'),\n icon: <Tag size={20} />,\n order: 50,\n group: 'notifications',\n },\n ]\n : []),\n ];\n\n // Register and get cleanup function\n const cleanup = registerNavItems(navItems);\n\n // Return cleanup function to unregister on unmount\n return cleanup;\n }, [registerNavItems, basePath, historyEnabled, templatesEnabled, createEnabled, tr]);\n\n // Register footer items (status indicator in left section)\n useEffect(() => {\n if (!registerFooterItems) return;\n\n const footerItems: FooterItem[] = [\n {\n id: 'admin-notification-status',\n label: tr('notification.footer.ready', 'Notifications Ready'),\n type: 'status',\n order: 10,\n section: 'left',\n },\n ];\n\n const cleanup = registerFooterItems(footerItems);\n return cleanup;\n }, [registerFooterItems, tr]);\n\n return (\n <ErrorBoundary\n fallback={\n <div className=\"p-6 text-center text-text-secondary\">\n {tr(\n 'notification.error.moduleLoad',\n 'Something went wrong loading this module. Please refresh the page.'\n )}\n </div>\n }\n >\n <NotificationProvider {...props}>\n <AdminNotificationRoutes />\n </NotificationProvider>\n </ErrorBoundary>\n );\n}\n"],"mappings":";;;;;;;;;AAwCA,SAAgB,EAAsB,GAA8B;CAClE,IAAM,EAAE,qBAAkB,wBAAqB,cAAW,QAAQ,GAC5D,IAAK,GAAO,EAQZ,IAAmB,EAAsB,yBAAyB,EAClE,IAAgB,EAAsB,sBAAsB,EAC5D,IAAiB,EAAsB,uBAAuB,EAC9D,IAAmB,IAAmB,EAAQ,EAAiB,QAAS,IACxE,IAAgB,IAAgB,EAAQ,EAAc,QAAS,IAC/D,IAAiB,IAAiB,EAAQ,EAAe,QAAS,IAGlE,KAAY,GAAc,OACZ,EAAK,SAAS,IAAI,GAAG,EAAK,MAAM,GAAG,GAAG,GAAG,MACzC,EAAK,WAAW,IAAI,GAAG,IAAO,IAAI;AAwFtD,QAnFA,QAAgB;AACT,QA6DL,QAHgB,EAxDY;GAC1B;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,sBAAsB;IAC3D,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR;GACD,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO,EAAG,4BAA4B,UAAU;IAChD,MAAM,EAAS,GAAU,UAAU;IACnC,MAAM,kBAAC,GAAD,EAAS,MAAM,IAAM,CAAA;IAC3B,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACN,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO,EAAG,8BAA8B,YAAY;IACpD,MAAM,EAAS,GAAU,YAAY;IACrC,MAAM,kBAAC,GAAD,EAAU,MAAM,IAAM,CAAA;IAC5B,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACN,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO,EAAG,yBAAyB,oBAAoB;IACvD,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR,EACD;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,SAAS;IAC9C,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAK,MAAM,IAAM,CAAA;IACvB,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACP,CAGyC;IAIzC;EAAC;EAAkB;EAAU;EAAgB;EAAkB;EAAe;EAAG,CAAC,EAGrF,QAAgB;AACT,QAaL,QADgB,EAVkB,CAChC;GACE,IAAI;GACJ,OAAO,EAAG,6BAA6B,sBAAsB;GAC7D,MAAM;GACN,OAAO;GACP,SAAS;GACV,CACF,CAE+C;IAE/C,CAAC,GAAqB,EAAG,CAAC,EAG3B,kBAAC,GAAD;EACE,UACE,kBAAC,OAAD;GAAK,WAAU;aACZ,EACC,iCACA,qEACD;GACG,CAAA;YAGR,kBAAC,GAAD;GAAsB,GAAI;aACxB,kBAAC,GAAD,EAA2B,CAAA;GACN,CAAA;EACT,CAAA"}
@@ -1,108 +1,109 @@
1
1
  import { useNotification as e } from "./providers/NotificationProvider.js";
2
- import { NOTIFICATION_PERMISSIONS as t } from "./constants/permissions.js";
3
- import { NotificationCenterPage as n } from "./pages/NotificationCenterPage.js";
4
- import { NotificationLandingPage as r } from "./pages/NotificationLandingPage.js";
5
- import { FeatureDisabledPage as i } from "./components/FeatureDisabledPage.js";
6
- import { Suspense as a, lazy as o, useEffect as s } from "react";
7
- import { PermissionGate as c } from "@burdenoff/fe-libs/shared/components";
8
- import { useFeatureFlagDetails as l } from "@burdenoff/fe-libs/shared/feature-flags";
9
- import { useGlobalUi as u } from "@burdenoff/fe-libs/shared/providers/shell";
10
- import { Navigate as d, Route as f, Routes as p, useNavigate as m } from "react-router";
11
- import { jsx as h, jsxs as g } from "react/jsx-runtime";
2
+ import { useTr as t } from "./shared/hooks/useTr.js";
3
+ import { NOTIFICATION_PERMISSIONS as n } from "./constants/permissions.js";
4
+ import { NotificationCenterPage as r } from "./pages/NotificationCenterPage.js";
5
+ import { NotificationLandingPage as i } from "./pages/NotificationLandingPage.js";
6
+ import { FeatureDisabledPage as a } from "./components/FeatureDisabledPage.js";
7
+ import { Suspense as o, lazy as s, useEffect as c } from "react";
8
+ import { PermissionGate as l } from "@burdenoff/fe-libs/shared/components";
9
+ import { useFeatureFlagDetails as u } from "@burdenoff/fe-libs/shared/feature-flags";
10
+ import { useGlobalUi as d } from "@burdenoff/fe-libs/shared/providers/shell";
11
+ import { Navigate as f, Route as p, Routes as m, useNavigate as h } from "react-router";
12
+ import { jsx as g, jsxs as _ } from "react/jsx-runtime";
12
13
  //#region src/AdminNotificationRoutes.tsx
13
- var _ = o(() => import("./pages/NotificationHistoryAdminPage.js").then((e) => ({ default: e.NotificationHistoryAdminPage }))), v = o(() => import("./pages/NotificationTemplatesPage.js").then((e) => ({ default: e.NotificationTemplatesPage }))), y = o(() => import("./pages/TemplateEditorPage.js").then((e) => ({ default: e.TemplateEditorPage }))), b = o(() => import("./pages/CreateNotificationPage.js").then((e) => ({ default: e.CreateNotificationPage }))), x = o(() => import("./pages/NotificationTopicsPage.js").then((e) => ({ default: e.NotificationTopicsPage })));
14
- function S() {
15
- return /* @__PURE__ */ h("div", {
14
+ var v = s(() => import("./pages/NotificationHistoryAdminPage.js").then((e) => ({ default: e.NotificationHistoryAdminPage }))), y = s(() => import("./pages/NotificationTemplatesPage.js").then((e) => ({ default: e.NotificationTemplatesPage }))), b = s(() => import("./pages/TemplateEditorPage.js").then((e) => ({ default: e.TemplateEditorPage }))), x = s(() => import("./pages/CreateNotificationPage.js").then((e) => ({ default: e.CreateNotificationPage }))), S = s(() => import("./pages/NotificationTopicsPage.js").then((e) => ({ default: e.NotificationTopicsPage })));
15
+ function C() {
16
+ return /* @__PURE__ */ g("div", {
16
17
  className: "flex h-64 items-center justify-center",
17
- children: /* @__PURE__ */ h("div", { className: "h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent" })
18
+ children: /* @__PURE__ */ g("div", { className: "h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent" })
18
19
  });
19
20
  }
20
- function C() {
21
- let { showToast: t } = u(), n = m(), { basePath: r } = e();
22
- return s(() => {
23
- t("You do not have permission to access that notification page.", "warning"), n(`${r}/center`, { replace: !0 });
21
+ function w() {
22
+ let { showToast: n } = d(), r = h(), { basePath: i } = e(), a = t();
23
+ return c(() => {
24
+ n(a("notification.error.accessDeniedRedirect", "You do not have permission to access that notification page."), "warning"), r(`${i}/center`, { replace: !0 });
24
25
  }, []), null;
25
26
  }
26
- function w(e) {
27
+ function T(e) {
27
28
  let { children: t, ...n } = e;
28
- return /* @__PURE__ */ h(c, {
29
+ return /* @__PURE__ */ g(l, {
29
30
  permission: n.permission,
30
31
  permissions: n.permissions,
31
32
  requireAll: n.requireAll,
32
- loading: /* @__PURE__ */ h(S, {}),
33
- fallback: /* @__PURE__ */ h(C, {}),
33
+ loading: /* @__PURE__ */ g(C, {}),
34
+ fallback: /* @__PURE__ */ g(w, {}),
34
35
  children: t
35
36
  });
36
37
  }
37
- function T() {
38
- let { basePath: o = "/" } = e(), s = `${o.endsWith("/") ? o.slice(0, -1) : o}/center`, c = l("notification.templates"), u = l("notification.create"), m = l("notification.history"), C = c ? !!c.value : !1, T = u ? !!u.value : !1, E = m ? !!m.value : !1;
39
- return /* @__PURE__ */ h(a, {
40
- fallback: /* @__PURE__ */ h(S, {}),
41
- children: /* @__PURE__ */ g(p, { children: [
42
- /* @__PURE__ */ h(f, {
38
+ function E() {
39
+ let { basePath: s = "/" } = e(), c = t(), l = `${s.endsWith("/") ? s.slice(0, -1) : s}/center`, d = u("notification.templates"), h = u("notification.create"), w = u("notification.history"), E = d ? !!d.value : !1, D = h ? !!h.value : !1, O = w ? !!w.value : !1;
40
+ return /* @__PURE__ */ g(o, {
41
+ fallback: /* @__PURE__ */ g(C, {}),
42
+ children: /* @__PURE__ */ _(m, { children: [
43
+ /* @__PURE__ */ g(p, {
43
44
  index: !0,
44
- element: /* @__PURE__ */ h(r, {})
45
+ element: /* @__PURE__ */ g(i, {})
45
46
  }),
46
- /* @__PURE__ */ h(f, {
47
+ /* @__PURE__ */ g(p, {
47
48
  path: "list",
48
- element: /* @__PURE__ */ h(n, {})
49
+ element: /* @__PURE__ */ g(r, {})
49
50
  }),
50
- /* @__PURE__ */ h(f, {
51
+ /* @__PURE__ */ g(p, {
51
52
  path: "center",
52
- element: /* @__PURE__ */ h(n, {})
53
+ element: /* @__PURE__ */ g(r, {})
53
54
  }),
54
- /* @__PURE__ */ h(f, {
55
+ /* @__PURE__ */ g(p, {
55
56
  path: "history",
56
- element: E ? /* @__PURE__ */ h(_, {}) : /* @__PURE__ */ h(i, {
57
- title: "Notification history is not enabled",
58
- description: "This admin page is controlled by the notification.history feature flag. Enable the flag before validating delivery history."
57
+ element: O ? /* @__PURE__ */ g(v, {}) : /* @__PURE__ */ g(a, {
58
+ title: c("notification.featureDisabled.historyTitle", "Notification history is not enabled"),
59
+ description: c("notification.featureDisabled.historyAdminDescription", "This admin page is controlled by the notification.history feature flag. Enable the flag before validating delivery history.")
59
60
  })
60
61
  }),
61
- C && /* @__PURE__ */ h(f, {
62
+ E && /* @__PURE__ */ g(p, {
62
63
  path: "templates",
63
- element: /* @__PURE__ */ h(w, {
64
+ element: /* @__PURE__ */ g(T, {
64
65
  permissions: [
65
- t.TEMPLATE_LIST,
66
- t.TEMPLATE_CREATE,
67
- t.TEMPLATE_UPDATE,
68
- t.TEMPLATE_DELETE
66
+ n.TEMPLATE_LIST,
67
+ n.TEMPLATE_CREATE,
68
+ n.TEMPLATE_UPDATE,
69
+ n.TEMPLATE_DELETE
69
70
  ],
70
- children: /* @__PURE__ */ h(v, {})
71
+ children: /* @__PURE__ */ g(y, {})
71
72
  })
72
73
  }),
73
- C && /* @__PURE__ */ h(f, {
74
+ E && /* @__PURE__ */ g(p, {
74
75
  path: "templates/new",
75
- element: /* @__PURE__ */ h(w, {
76
- permission: t.TEMPLATE_CREATE,
77
- children: /* @__PURE__ */ h(y, {})
76
+ element: /* @__PURE__ */ g(T, {
77
+ permission: n.TEMPLATE_CREATE,
78
+ children: /* @__PURE__ */ g(b, {})
78
79
  })
79
80
  }),
80
- C && /* @__PURE__ */ h(f, {
81
+ E && /* @__PURE__ */ g(p, {
81
82
  path: "templates/:templateId",
82
- element: /* @__PURE__ */ h(w, {
83
- permission: t.TEMPLATE_UPDATE,
84
- children: /* @__PURE__ */ h(y, {})
83
+ element: /* @__PURE__ */ g(T, {
84
+ permission: n.TEMPLATE_UPDATE,
85
+ children: /* @__PURE__ */ g(b, {})
85
86
  })
86
87
  }),
87
- T && /* @__PURE__ */ h(f, {
88
+ D && /* @__PURE__ */ g(p, {
88
89
  path: "create",
89
- element: /* @__PURE__ */ h(w, {
90
- permissions: [t.NOTIFICATION_CREATE, t.NOTIFICATION_SEND],
90
+ element: /* @__PURE__ */ g(T, {
91
+ permissions: [n.NOTIFICATION_CREATE, n.NOTIFICATION_SEND],
91
92
  requireAll: !0,
92
- children: /* @__PURE__ */ h(b, {})
93
+ children: /* @__PURE__ */ g(x, {})
93
94
  })
94
95
  }),
95
- T && /* @__PURE__ */ h(f, {
96
+ D && /* @__PURE__ */ g(p, {
96
97
  path: "topics",
97
- element: /* @__PURE__ */ h(w, {
98
- permission: t.NOTIFICATION_CREATE,
99
- children: /* @__PURE__ */ h(x, {})
98
+ element: /* @__PURE__ */ g(T, {
99
+ permission: n.NOTIFICATION_CREATE,
100
+ children: /* @__PURE__ */ g(S, {})
100
101
  })
101
102
  }),
102
- /* @__PURE__ */ h(f, {
103
+ /* @__PURE__ */ g(p, {
103
104
  path: "*",
104
- element: /* @__PURE__ */ h(d, {
105
- to: s,
105
+ element: /* @__PURE__ */ g(f, {
106
+ to: l,
106
107
  replace: !0
107
108
  })
108
109
  })
@@ -110,6 +111,6 @@ function T() {
110
111
  });
111
112
  }
112
113
  //#endregion
113
- export { T as AdminNotificationRoutes };
114
+ export { E as AdminNotificationRoutes };
114
115
 
115
116
  //# sourceMappingURL=AdminNotificationRoutes.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"AdminNotificationRoutes.js","names":[],"sources":["../src/AdminNotificationRoutes.tsx"],"sourcesContent":["import { lazy, Suspense, useEffect, type ReactNode } from 'react';\nimport { Navigate, Route, Routes, useNavigate } from 'react-router';\nimport { useFeatureFlagDetails } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { PermissionGate } from '@burdenoff/fe-libs/shared/components';\nimport { useGlobalUi } from '@burdenoff/fe-libs/shared/providers/shell';\nimport { FeatureDisabledPage } from './components/FeatureDisabledPage';\nimport { NOTIFICATION_PERMISSIONS, type NotificationPermission } from './constants/permissions';\nimport { useNotification } from './providers/NotificationProvider';\n\n// Eager load - Primary landing page\nimport { NotificationCenterPage } from './pages/NotificationCenterPage';\nimport { NotificationLandingPage } from './pages/NotificationLandingPage';\n\n// Lazy load - Secondary pages\nconst NotificationHistoryAdminPage = lazy(() =>\n import('./pages/NotificationHistoryAdminPage').then((m) => ({\n default: m.NotificationHistoryAdminPage,\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);\n\n// Loading fallback component\nfunction PageLoader() {\n return (\n <div className=\"flex h-64 items-center justify-center\">\n <div className=\"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent\" />\n </div>\n );\n}\n\n// Pair toast + programmatic navigation in one effect to avoid <Navigate> unmounting before the toast fires.\n// Uses absolute `${basePath}/center` because relative `../center` resolves wrong from nested paths like `/templates/new`.\nfunction AccessDeniedRedirect() {\n const { showToast } = useGlobalUi();\n const navigate = useNavigate();\n const { basePath } = useNotification();\n useEffect(() => {\n showToast('You do not have permission to access that notification page.', 'warning');\n navigate(`${basePath}/center`, { replace: true });\n // Run once per access-denied mount; re-running on hook identity changes would duplicate the toast.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return null;\n}\n\n// Discriminated union: callers must pass exactly one of `permission` / `permissions`.\ntype AdminRouteGateProps = {\n children: ReactNode;\n} & (\n | { permission: NotificationPermission; permissions?: never; requireAll?: never }\n | {\n permission?: never;\n permissions: NotificationPermission[];\n requireAll?: boolean;\n }\n);\n\nfunction AdminRouteGate(props: AdminRouteGateProps) {\n const { children, ...gateProps } = props;\n return (\n <PermissionGate\n permission={gateProps.permission}\n permissions={gateProps.permissions}\n requireAll={gateProps.requireAll}\n loading={<PageLoader />}\n fallback={<AccessDeniedRedirect />}\n >\n {children}\n </PermissionGate>\n );\n}\n\n// Admin-app router for the notification MFE. Admin routes are wrapped in PermissionGate.\nexport function AdminNotificationRoutes() {\n const { basePath = '/' } = useNotification();\n const centerPath = `${basePath.endsWith('/') ? basePath.slice(0, -1) : basePath}/center`;\n\n // Explicit `false` fallback prevents provider's default-allow from leaking unseeded flags.\n const templatesDetails = useFeatureFlagDetails('notification.templates');\n const createDetails = useFeatureFlagDetails('notification.create');\n const historyDetails = useFeatureFlagDetails('notification.history');\n const templatesEnabled = templatesDetails ? Boolean(templatesDetails.value) : false;\n const createEnabled = createDetails ? Boolean(createDetails.value) : false;\n const historyEnabled = historyDetails ? Boolean(historyDetails.value) : false;\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\n path=\"history\"\n element={\n historyEnabled ? (\n <NotificationHistoryAdminPage />\n ) : (\n <FeatureDisabledPage\n title=\"Notification history is not enabled\"\n description=\"This admin page is controlled by the notification.history feature flag. Enable the flag before validating delivery history.\"\n />\n )\n }\n />\n\n {/* Gate admits any actor with read or any write permission; page disables write actions for read-only. */}\n {templatesEnabled && (\n <Route\n path=\"templates\"\n element={\n <AdminRouteGate\n permissions={[\n NOTIFICATION_PERMISSIONS.TEMPLATE_LIST,\n NOTIFICATION_PERMISSIONS.TEMPLATE_CREATE,\n NOTIFICATION_PERMISSIONS.TEMPLATE_UPDATE,\n NOTIFICATION_PERMISSIONS.TEMPLATE_DELETE,\n ]}\n >\n <NotificationTemplatesPage />\n </AdminRouteGate>\n }\n />\n )}\n {templatesEnabled && (\n <Route\n path=\"templates/new\"\n element={\n <AdminRouteGate permission={NOTIFICATION_PERMISSIONS.TEMPLATE_CREATE}>\n <TemplateEditorPage />\n </AdminRouteGate>\n }\n />\n )}\n {templatesEnabled && (\n <Route\n path=\"templates/:templateId\"\n element={\n <AdminRouteGate permission={NOTIFICATION_PERMISSIONS.TEMPLATE_UPDATE}>\n <TemplateEditorPage />\n </AdminRouteGate>\n }\n />\n )}\n\n {/* Admin routes - Create/Send Notification (wrapped in PermissionGate) */}\n {createEnabled && (\n <Route\n path=\"create\"\n element={\n <AdminRouteGate\n permissions={[\n NOTIFICATION_PERMISSIONS.NOTIFICATION_CREATE,\n NOTIFICATION_PERMISSIONS.NOTIFICATION_SEND,\n ]}\n requireAll\n >\n <CreateNotificationPage />\n </AdminRouteGate>\n }\n />\n )}\n {/* Topics CRUD maps to `notification:create` per backend @rbac — tracked in BOFF-2386. */}\n {createEnabled && (\n <Route\n path=\"topics\"\n element={\n <AdminRouteGate permission={NOTIFICATION_PERMISSIONS.NOTIFICATION_CREATE}>\n <NotificationTopicsPage />\n </AdminRouteGate>\n }\n />\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"],"mappings":"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"}
1
+ {"version":3,"file":"AdminNotificationRoutes.js","names":[],"sources":["../src/AdminNotificationRoutes.tsx"],"sourcesContent":["import { lazy, Suspense, useEffect, type ReactNode } from 'react';\nimport { Navigate, Route, Routes, useNavigate } from 'react-router';\nimport { useFeatureFlagDetails } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { PermissionGate } from '@burdenoff/fe-libs/shared/components';\nimport { useGlobalUi } from '@burdenoff/fe-libs/shared/providers/shell';\nimport { FeatureDisabledPage } from './components/FeatureDisabledPage';\nimport { NOTIFICATION_PERMISSIONS, type NotificationPermission } from './constants/permissions';\nimport { useNotification } from './providers/NotificationProvider';\nimport { useTr } from './shared/hooks/useTr';\n\n// Eager load - Primary landing page\nimport { NotificationCenterPage } from './pages/NotificationCenterPage';\nimport { NotificationLandingPage } from './pages/NotificationLandingPage';\n\n// Lazy load - Secondary pages\nconst NotificationHistoryAdminPage = lazy(() =>\n import('./pages/NotificationHistoryAdminPage').then((m) => ({\n default: m.NotificationHistoryAdminPage,\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);\n\n// Loading fallback component\nfunction PageLoader() {\n return (\n <div className=\"flex h-64 items-center justify-center\">\n <div className=\"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent\" />\n </div>\n );\n}\n\n// Pair toast + programmatic navigation in one effect to avoid <Navigate> unmounting before the toast fires.\n// Uses absolute `${basePath}/center` because relative `../center` resolves wrong from nested paths like `/templates/new`.\nfunction AccessDeniedRedirect() {\n const { showToast } = useGlobalUi();\n const navigate = useNavigate();\n const { basePath } = useNotification();\n const tr = useTr();\n useEffect(() => {\n showToast(\n tr(\n 'notification.error.accessDeniedRedirect',\n 'You do not have permission to access that notification page.'\n ),\n 'warning'\n );\n navigate(`${basePath}/center`, { replace: true });\n // Run once per access-denied mount; re-running on hook identity changes would duplicate the toast.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return null;\n}\n\n// Discriminated union: callers must pass exactly one of `permission` / `permissions`.\ntype AdminRouteGateProps = {\n children: ReactNode;\n} & (\n | { permission: NotificationPermission; permissions?: never; requireAll?: never }\n | {\n permission?: never;\n permissions: NotificationPermission[];\n requireAll?: boolean;\n }\n);\n\nfunction AdminRouteGate(props: AdminRouteGateProps) {\n const { children, ...gateProps } = props;\n return (\n <PermissionGate\n permission={gateProps.permission}\n permissions={gateProps.permissions}\n requireAll={gateProps.requireAll}\n loading={<PageLoader />}\n fallback={<AccessDeniedRedirect />}\n >\n {children}\n </PermissionGate>\n );\n}\n\n// Admin-app router for the notification MFE. Admin routes are wrapped in PermissionGate.\nexport function AdminNotificationRoutes() {\n const { basePath = '/' } = useNotification();\n const tr = useTr();\n const centerPath = `${basePath.endsWith('/') ? basePath.slice(0, -1) : basePath}/center`;\n\n // Explicit `false` fallback prevents provider's default-allow from leaking unseeded flags.\n const templatesDetails = useFeatureFlagDetails('notification.templates');\n const createDetails = useFeatureFlagDetails('notification.create');\n const historyDetails = useFeatureFlagDetails('notification.history');\n const templatesEnabled = templatesDetails ? Boolean(templatesDetails.value) : false;\n const createEnabled = createDetails ? Boolean(createDetails.value) : false;\n const historyEnabled = historyDetails ? Boolean(historyDetails.value) : false;\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\n path=\"history\"\n element={\n historyEnabled ? (\n <NotificationHistoryAdminPage />\n ) : (\n <FeatureDisabledPage\n title={tr(\n 'notification.featureDisabled.historyTitle',\n 'Notification history is not enabled'\n )}\n description={tr(\n 'notification.featureDisabled.historyAdminDescription',\n 'This admin page is controlled by the notification.history feature flag. Enable the flag before validating delivery history.'\n )}\n />\n )\n }\n />\n\n {/* Gate admits any actor with read or any write permission; page disables write actions for read-only. */}\n {templatesEnabled && (\n <Route\n path=\"templates\"\n element={\n <AdminRouteGate\n permissions={[\n NOTIFICATION_PERMISSIONS.TEMPLATE_LIST,\n NOTIFICATION_PERMISSIONS.TEMPLATE_CREATE,\n NOTIFICATION_PERMISSIONS.TEMPLATE_UPDATE,\n NOTIFICATION_PERMISSIONS.TEMPLATE_DELETE,\n ]}\n >\n <NotificationTemplatesPage />\n </AdminRouteGate>\n }\n />\n )}\n {templatesEnabled && (\n <Route\n path=\"templates/new\"\n element={\n <AdminRouteGate permission={NOTIFICATION_PERMISSIONS.TEMPLATE_CREATE}>\n <TemplateEditorPage />\n </AdminRouteGate>\n }\n />\n )}\n {templatesEnabled && (\n <Route\n path=\"templates/:templateId\"\n element={\n <AdminRouteGate permission={NOTIFICATION_PERMISSIONS.TEMPLATE_UPDATE}>\n <TemplateEditorPage />\n </AdminRouteGate>\n }\n />\n )}\n\n {/* Admin routes - Create/Send Notification (wrapped in PermissionGate) */}\n {createEnabled && (\n <Route\n path=\"create\"\n element={\n <AdminRouteGate\n permissions={[\n NOTIFICATION_PERMISSIONS.NOTIFICATION_CREATE,\n NOTIFICATION_PERMISSIONS.NOTIFICATION_SEND,\n ]}\n requireAll\n >\n <CreateNotificationPage />\n </AdminRouteGate>\n }\n />\n )}\n {/* Topics CRUD maps to `notification:create` per backend @rbac — tracked in BOFF-2386. */}\n {createEnabled && (\n <Route\n path=\"topics\"\n element={\n <AdminRouteGate permission={NOTIFICATION_PERMISSIONS.NOTIFICATION_CREATE}>\n <NotificationTopicsPage />\n </AdminRouteGate>\n }\n />\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"],"mappings":"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"}
@@ -70,7 +70,7 @@ function f(f) {
70
70
  }, [m, g]), /* @__PURE__ */ d(r, {
71
71
  fallback: /* @__PURE__ */ d("div", {
72
72
  className: "p-6 text-center text-text-secondary",
73
- children: "Something went wrong loading this module. Please refresh the page."
73
+ children: _("notification.error.moduleLoad", "Something went wrong loading this module. Please refresh the page.")
74
74
  }),
75
75
  children: /* @__PURE__ */ d(i, {
76
76
  workspaceId: null,
@@ -1 +1 @@
1
- {"version":3,"file":"NotificationRoot.js","names":[],"sources":["../src/NotificationRoot.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { ErrorBoundary } from '@burdenoff/fe-libs/shared/components';\nimport { FeatureFlagProvider } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell';\nimport { Bell, Archive, FileText, Settings2, Tag } from 'lucide-react';\nimport { NotificationProvider } from './providers/NotificationProvider';\nimport type { NavItem, FooterItem, NotificationRootProps } from './types';\nimport { NotificationRoutes } from './NotificationRoutes';\n\n/**\n * Root component for the Notification microfrontend.\n *\n * This is the main entry point that host applications import and render.\n * It sets up the necessary providers and renders the internal routing.\n * Automatically registers navigation items with the shell if registration functions are provided.\n *\n * @example\n * ```tsx\n * import { NotificationRoot, type NotificationRootProps } from '@burdenoff/micro-fe/notification';\n *\n * function App() {\n * const props: NotificationRootProps = {\n * basePath: '/notifications',\n * navigate: (path) => router.push(path),\n * currentUser: { id: '1', email: 'user@example.com' },\n * workspaceId: 'ws-123',\n * apiGatewayUrl: 'https://api.example.com',\n * authToken: 'token',\n * registerNavItems: (items) => { return () => {}; },\n * onNotificationClick: (notification) => console.log('Clicked:', notification),\n * };\n *\n * return <NotificationRoot {...props} />;\n * }\n * ```\n */\nexport function NotificationRoot(props: NotificationRootProps) {\n const { registerNavItems, registerFooterItems, basePath = '/' } = props;\n const { t } = useI18n();\n const tr = (key: string, fallback: string): string => {\n const translated = t(key);\n return translated === key ? fallback : translated;\n };\n\n // Helper to join paths correctly, avoiding double slashes\n const joinPath = (base: string, path: string): string => {\n const cleanBase = base.endsWith('/') ? base.slice(0, -1) : base;\n const cleanPath = path.startsWith('/') ? path : `/${path}`;\n return cleanBase + cleanPath;\n };\n\n // Register navigation items with the shell\n useEffect(() => {\n if (!registerNavItems) return;\n\n const navItems: NavItem[] = [\n {\n id: 'notification-center',\n label: tr('notification.nav.center', 'Notification Center'),\n path: joinPath(basePath, 'center'),\n icon: <Bell size={20} />,\n order: 10,\n group: 'notifications',\n },\n {\n id: 'notification-history',\n label: tr('notification.nav.history', 'History'),\n path: joinPath(basePath, 'history'),\n icon: <Archive size={20} />,\n order: 20,\n group: 'notifications',\n },\n {\n id: 'notification-templates',\n label: tr('notification.nav.templates', 'Templates'),\n path: joinPath(basePath, 'templates'),\n icon: <FileText size={20} />,\n order: 30,\n group: 'notifications',\n // Admin only - host should filter based on permissions\n },\n {\n id: 'notification-topics',\n label: tr('notification.nav.topics', 'Topics'),\n path: joinPath(basePath, 'topics'),\n icon: <Tag size={20} />,\n order: 40,\n group: 'notifications',\n },\n {\n id: 'notification-preferences',\n label: tr('notification.nav.preferences', 'Preferences'),\n path: joinPath(basePath, 'preferences'),\n icon: <Settings2 size={20} />,\n order: 50,\n group: 'notifications',\n },\n ];\n\n // Register and get cleanup function\n const cleanup = registerNavItems(navItems);\n\n // Return cleanup function to unregister on unmount\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerNavItems, basePath, t]);\n\n // Register footer items (status indicator in left section)\n useEffect(() => {\n if (!registerFooterItems) return;\n\n const footerItems: FooterItem[] = [\n {\n id: 'notification-status',\n label: tr('notification.footer.ready', 'Notifications Ready'),\n type: 'status',\n order: 10,\n section: 'left',\n },\n ];\n\n const cleanup = registerFooterItems(footerItems);\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerFooterItems, t]);\n\n return (\n <ErrorBoundary\n fallback={\n <div className=\"p-6 text-center text-text-secondary\">\n Something went wrong loading this module. Please refresh the page.\n </div>\n }\n >\n <FeatureFlagProvider workspaceId={null} gateway=\"global\" defaultEnabled={true}>\n <NotificationProvider {...props}>\n <NotificationRoutes />\n </NotificationProvider>\n </FeatureFlagProvider>\n </ErrorBoundary>\n );\n}\n"],"mappings":";;;;;;;;;AAoCA,SAAgB,EAAiB,GAA8B;CAC7D,IAAM,EAAE,qBAAkB,wBAAqB,cAAW,QAAQ,GAC5D,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,MAA6B;EACpD,IAAM,IAAa,EAAE,EAAI;AACzB,SAAO,MAAe,IAAM,IAAW;IAInC,KAAY,GAAc,OACZ,EAAK,SAAS,IAAI,GAAG,EAAK,MAAM,GAAG,GAAG,GAAG,MACzC,EAAK,WAAW,IAAI,GAAG,IAAO,IAAI;AA+EtD,QA1EA,QAAgB;AACT,QAkDL,QAHgB,EA7CY;GAC1B;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,sBAAsB;IAC3D,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR;GACD;IACE,IAAI;IACJ,OAAO,EAAG,4BAA4B,UAAU;IAChD,MAAM,EAAS,GAAU,UAAU;IACnC,MAAM,kBAAC,GAAD,EAAS,MAAM,IAAM,CAAA;IAC3B,OAAO;IACP,OAAO;IACR;GACD;IACE,IAAI;IACJ,OAAO,EAAG,8BAA8B,YAAY;IACpD,MAAM,EAAS,GAAU,YAAY;IACrC,MAAM,kBAAC,GAAD,EAAU,MAAM,IAAM,CAAA;IAC5B,OAAO;IACP,OAAO;IAER;GACD;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,SAAS;IAC9C,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAK,MAAM,IAAM,CAAA;IACvB,OAAO;IACP,OAAO;IACR;GACD;IACE,IAAI;IACJ,OAAO,EAAG,gCAAgC,cAAc;IACxD,MAAM,EAAS,GAAU,cAAc;IACvC,MAAM,kBAAC,GAAD,EAAW,MAAM,IAAM,CAAA;IAC7B,OAAO;IACP,OAAO;IACR;GACF,CAGyC;IAKzC;EAAC;EAAkB;EAAU;EAAE,CAAC,EAGnC,QAAgB;AACT,QAaL,QADgB,EAVkB,CAChC;GACE,IAAI;GACJ,OAAO,EAAG,6BAA6B,sBAAsB;GAC7D,MAAM;GACN,OAAO;GACP,SAAS;GACV,CACF,CAE+C;IAG/C,CAAC,GAAqB,EAAE,CAAC,EAG1B,kBAAC,GAAD;EACE,UACE,kBAAC,OAAD;GAAK,WAAU;aAAsC;GAE/C,CAAA;YAGR,kBAAC,GAAD;GAAqB,aAAa;GAAM,SAAQ;GAAS,gBAAgB;aACvE,kBAAC,GAAD;IAAsB,GAAI;cACxB,kBAAC,GAAD,EAAsB,CAAA;IACD,CAAA;GACH,CAAA;EACR,CAAA"}
1
+ {"version":3,"file":"NotificationRoot.js","names":[],"sources":["../src/NotificationRoot.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { ErrorBoundary } from '@burdenoff/fe-libs/shared/components';\nimport { FeatureFlagProvider } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell';\nimport { Bell, Archive, FileText, Settings2, Tag } from 'lucide-react';\nimport { NotificationProvider } from './providers/NotificationProvider';\nimport type { NavItem, FooterItem, NotificationRootProps } from './types';\nimport { NotificationRoutes } from './NotificationRoutes';\n\n/**\n * Root component for the Notification microfrontend.\n *\n * This is the main entry point that host applications import and render.\n * It sets up the necessary providers and renders the internal routing.\n * Automatically registers navigation items with the shell if registration functions are provided.\n *\n * @example\n * ```tsx\n * import { NotificationRoot, type NotificationRootProps } from '@burdenoff/micro-fe/notification';\n *\n * function App() {\n * const props: NotificationRootProps = {\n * basePath: '/notifications',\n * navigate: (path) => router.push(path),\n * currentUser: { id: '1', email: 'user@example.com' },\n * workspaceId: 'ws-123',\n * apiGatewayUrl: 'https://api.example.com',\n * authToken: 'token',\n * registerNavItems: (items) => { return () => {}; },\n * onNotificationClick: (notification) => console.log('Clicked:', notification),\n * };\n *\n * return <NotificationRoot {...props} />;\n * }\n * ```\n */\nexport function NotificationRoot(props: NotificationRootProps) {\n const { registerNavItems, registerFooterItems, basePath = '/' } = props;\n const { t } = useI18n();\n const tr = (key: string, fallback: string): string => {\n const translated = t(key);\n return translated === key ? fallback : translated;\n };\n\n // Helper to join paths correctly, avoiding double slashes\n const joinPath = (base: string, path: string): string => {\n const cleanBase = base.endsWith('/') ? base.slice(0, -1) : base;\n const cleanPath = path.startsWith('/') ? path : `/${path}`;\n return cleanBase + cleanPath;\n };\n\n // Register navigation items with the shell\n useEffect(() => {\n if (!registerNavItems) return;\n\n const navItems: NavItem[] = [\n {\n id: 'notification-center',\n label: tr('notification.nav.center', 'Notification Center'),\n path: joinPath(basePath, 'center'),\n icon: <Bell size={20} />,\n order: 10,\n group: 'notifications',\n },\n {\n id: 'notification-history',\n label: tr('notification.nav.history', 'History'),\n path: joinPath(basePath, 'history'),\n icon: <Archive size={20} />,\n order: 20,\n group: 'notifications',\n },\n {\n id: 'notification-templates',\n label: tr('notification.nav.templates', 'Templates'),\n path: joinPath(basePath, 'templates'),\n icon: <FileText size={20} />,\n order: 30,\n group: 'notifications',\n // Admin only - host should filter based on permissions\n },\n {\n id: 'notification-topics',\n label: tr('notification.nav.topics', 'Topics'),\n path: joinPath(basePath, 'topics'),\n icon: <Tag size={20} />,\n order: 40,\n group: 'notifications',\n },\n {\n id: 'notification-preferences',\n label: tr('notification.nav.preferences', 'Preferences'),\n path: joinPath(basePath, 'preferences'),\n icon: <Settings2 size={20} />,\n order: 50,\n group: 'notifications',\n },\n ];\n\n // Register and get cleanup function\n const cleanup = registerNavItems(navItems);\n\n // Return cleanup function to unregister on unmount\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerNavItems, basePath, t]);\n\n // Register footer items (status indicator in left section)\n useEffect(() => {\n if (!registerFooterItems) return;\n\n const footerItems: FooterItem[] = [\n {\n id: 'notification-status',\n label: tr('notification.footer.ready', 'Notifications Ready'),\n type: 'status',\n order: 10,\n section: 'left',\n },\n ];\n\n const cleanup = registerFooterItems(footerItems);\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerFooterItems, t]);\n\n return (\n <ErrorBoundary\n fallback={\n <div className=\"p-6 text-center text-text-secondary\">\n {tr(\n 'notification.error.moduleLoad',\n 'Something went wrong loading this module. Please refresh the page.'\n )}\n </div>\n }\n >\n <FeatureFlagProvider workspaceId={null} gateway=\"global\" defaultEnabled={true}>\n <NotificationProvider {...props}>\n <NotificationRoutes />\n </NotificationProvider>\n </FeatureFlagProvider>\n </ErrorBoundary>\n );\n}\n"],"mappings":";;;;;;;;;AAoCA,SAAgB,EAAiB,GAA8B;CAC7D,IAAM,EAAE,qBAAkB,wBAAqB,cAAW,QAAQ,GAC5D,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,MAA6B;EACpD,IAAM,IAAa,EAAE,EAAI;AACzB,SAAO,MAAe,IAAM,IAAW;IAInC,KAAY,GAAc,OACZ,EAAK,SAAS,IAAI,GAAG,EAAK,MAAM,GAAG,GAAG,GAAG,MACzC,EAAK,WAAW,IAAI,GAAG,IAAO,IAAI;AA+EtD,QA1EA,QAAgB;AACT,QAkDL,QAHgB,EA7CY;GAC1B;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,sBAAsB;IAC3D,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR;GACD;IACE,IAAI;IACJ,OAAO,EAAG,4BAA4B,UAAU;IAChD,MAAM,EAAS,GAAU,UAAU;IACnC,MAAM,kBAAC,GAAD,EAAS,MAAM,IAAM,CAAA;IAC3B,OAAO;IACP,OAAO;IACR;GACD;IACE,IAAI;IACJ,OAAO,EAAG,8BAA8B,YAAY;IACpD,MAAM,EAAS,GAAU,YAAY;IACrC,MAAM,kBAAC,GAAD,EAAU,MAAM,IAAM,CAAA;IAC5B,OAAO;IACP,OAAO;IAER;GACD;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,SAAS;IAC9C,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAK,MAAM,IAAM,CAAA;IACvB,OAAO;IACP,OAAO;IACR;GACD;IACE,IAAI;IACJ,OAAO,EAAG,gCAAgC,cAAc;IACxD,MAAM,EAAS,GAAU,cAAc;IACvC,MAAM,kBAAC,GAAD,EAAW,MAAM,IAAM,CAAA;IAC7B,OAAO;IACP,OAAO;IACR;GACF,CAGyC;IAKzC;EAAC;EAAkB;EAAU;EAAE,CAAC,EAGnC,QAAgB;AACT,QAaL,QADgB,EAVkB,CAChC;GACE,IAAI;GACJ,OAAO,EAAG,6BAA6B,sBAAsB;GAC7D,MAAM;GACN,OAAO;GACP,SAAS;GACV,CACF,CAE+C;IAG/C,CAAC,GAAqB,EAAE,CAAC,EAG1B,kBAAC,GAAD;EACE,UACE,kBAAC,OAAD;GAAK,WAAU;aACZ,EACC,iCACA,qEACD;GACG,CAAA;YAGR,kBAAC,GAAD;GAAqB,aAAa;GAAM,SAAQ;GAAS,gBAAgB;aACvE,kBAAC,GAAD;IAAsB,GAAI;cACxB,kBAAC,GAAD,EAAsB,CAAA;IACD,CAAA;GACH,CAAA;EACR,CAAA"}
@@ -55,7 +55,7 @@ function u(u) {
55
55
  }, [f, m]), /* @__PURE__ */ l(r, {
56
56
  fallback: /* @__PURE__ */ l("div", {
57
57
  className: "p-6 text-center text-text-secondary",
58
- children: "Something went wrong loading this module. Please refresh the page."
58
+ children: h("notification.error.moduleLoad", "Something went wrong loading this module. Please refresh the page.")
59
59
  }),
60
60
  children: /* @__PURE__ */ l(e, {
61
61
  ...u,
@@ -1 +1 @@
1
- {"version":3,"file":"UserNotificationRoot.js","names":[],"sources":["../src/UserNotificationRoot.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { ErrorBoundary } from '@burdenoff/fe-libs/shared/components';\nimport { useFeatureFlagDetails } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell';\nimport { Bell, Archive, Settings2 } from 'lucide-react';\nimport { NotificationProvider } from './providers/NotificationProvider';\nimport type { NavItem, FooterItem, NotificationRootProps } from './types';\nimport { UserNotificationRoutes } from './UserNotificationRoutes';\n\n/**\n * User Root component for the Notification microfrontend.\n *\n * This is the entry point host product shells should import. It exposes only\n * the user-facing notification surfaces (Notification Center, History) and\n * sets up the required provider stack.\n *\n * For the full admin experience (templates, create/send notification) use\n * `AdminNotificationRoot` instead.\n *\n * @example\n * ```tsx\n * import { UserNotificationRoot, type NotificationRootProps } from '@burdenoff/micro-fe/notification';\n *\n * function App() {\n * const props: NotificationRootProps = {\n * basePath: '/notifications',\n * navigate: (path) => router.push(path),\n * currentUser: { id: '1', email: 'user@example.com' },\n * workspaceId: 'ws-123',\n * apiGatewayUrl: 'https://api.example.com',\n * authToken: 'token',\n * registerNavItems: (items) => { return () => {}; },\n * onNotificationClick: (notification) => console.log('Clicked:', notification),\n * };\n *\n * return <UserNotificationRoot {...props} />;\n * }\n * ```\n */\nexport function UserNotificationRoot(props: NotificationRootProps) {\n const { registerNavItems, registerFooterItems, basePath = '/' } = props;\n const { t } = useI18n();\n const tr = (key: string, fallback: string): string => {\n const translated = t(key);\n return translated === key ? fallback : translated;\n };\n\n // Component-level feature gate. `notification.history` is declared as\n // unreleased (defaultValue=false). We use `useFeatureFlagDetails` and\n // explicitly fall back to `false` when the flag is absent from the cache,\n // because the provider's global default-allow would otherwise return `true`\n // for unseeded flags — which would defeat the whole point of the unreleased\n // pattern.\n const historyDetails = useFeatureFlagDetails('notification.history');\n const historyEnabled = historyDetails ? Boolean(historyDetails.value) : false;\n\n // Helper to join paths correctly, avoiding double slashes\n const joinPath = (base: string, path: string): string => {\n const cleanBase = base.endsWith('/') ? base.slice(0, -1) : base;\n const cleanPath = path.startsWith('/') ? path : `/${path}`;\n return cleanBase + cleanPath;\n };\n\n // Register navigation items with the shell (user-facing only)\n useEffect(() => {\n if (!registerNavItems) return;\n\n const navItems: NavItem[] = [\n {\n id: 'user-notification-center',\n label: tr('notification.nav.center', 'Notification Center'),\n path: joinPath(basePath, 'center'),\n icon: <Bell size={20} />,\n order: 10,\n group: 'notifications',\n },\n ...(historyEnabled\n ? [\n {\n id: 'user-notification-history',\n label: tr('notification.nav.history', 'History'),\n path: joinPath(basePath, 'history'),\n icon: <Archive size={20} />,\n order: 20,\n group: 'notifications',\n },\n ]\n : []),\n {\n id: 'user-notification-preferences',\n label: tr('notification.nav.preferences', 'Preferences'),\n path: joinPath(basePath, 'preferences'),\n icon: <Settings2 size={20} />,\n order: 30,\n group: 'notifications',\n },\n ];\n\n // Register and get cleanup function\n const cleanup = registerNavItems(navItems);\n\n // Return cleanup function to unregister on unmount\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerNavItems, basePath, historyEnabled, t]);\n\n // Register footer items (status indicator in left section)\n useEffect(() => {\n if (!registerFooterItems) return;\n\n const footerItems: FooterItem[] = [\n {\n id: 'user-notification-status',\n label: tr('notification.footer.ready', 'Notifications Ready'),\n type: 'status',\n order: 10,\n section: 'left',\n },\n ];\n\n const cleanup = registerFooterItems(footerItems);\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerFooterItems, t]);\n\n return (\n <ErrorBoundary\n fallback={\n <div className=\"p-6 text-center text-text-secondary\">\n Something went wrong loading this module. Please refresh the page.\n </div>\n }\n >\n <NotificationProvider {...props}>\n <UserNotificationRoutes />\n </NotificationProvider>\n </ErrorBoundary>\n );\n}\n"],"mappings":";;;;;;;;;AAuCA,SAAgB,EAAqB,GAA8B;CACjE,IAAM,EAAE,qBAAkB,wBAAqB,cAAW,QAAQ,GAC5D,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,MAA6B;EACpD,IAAM,IAAa,EAAE,EAAI;AACzB,SAAO,MAAe,IAAM,IAAW;IASnC,IAAiB,EAAsB,uBAAuB,EAC9D,IAAiB,IAAiB,EAAQ,EAAe,QAAS,IAGlE,KAAY,GAAc,OACZ,EAAK,SAAS,IAAI,GAAG,EAAK,MAAM,GAAG,GAAG,GAAG,MACzC,EAAK,WAAW,IAAI,GAAG,IAAO,IAAI;AAkEtD,QA7DA,QAAgB;AACT,QAqCL,QAHgB,EAhCY;GAC1B;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,sBAAsB;IAC3D,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR;GACD,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO,EAAG,4BAA4B,UAAU;IAChD,MAAM,EAAS,GAAU,UAAU;IACnC,MAAM,kBAAC,GAAD,EAAS,MAAM,IAAM,CAAA;IAC3B,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACN;IACE,IAAI;IACJ,OAAO,EAAG,gCAAgC,cAAc;IACxD,MAAM,EAAS,GAAU,cAAc;IACvC,MAAM,kBAAC,GAAD,EAAW,MAAM,IAAM,CAAA;IAC7B,OAAO;IACP,OAAO;IACR;GACF,CAGyC;IAKzC;EAAC;EAAkB;EAAU;EAAgB;EAAE,CAAC,EAGnD,QAAgB;AACT,QAaL,QADgB,EAVkB,CAChC;GACE,IAAI;GACJ,OAAO,EAAG,6BAA6B,sBAAsB;GAC7D,MAAM;GACN,OAAO;GACP,SAAS;GACV,CACF,CAE+C;IAG/C,CAAC,GAAqB,EAAE,CAAC,EAG1B,kBAAC,GAAD;EACE,UACE,kBAAC,OAAD;GAAK,WAAU;aAAsC;GAE/C,CAAA;YAGR,kBAAC,GAAD;GAAsB,GAAI;aACxB,kBAAC,GAAD,EAA0B,CAAA;GACL,CAAA;EACT,CAAA"}
1
+ {"version":3,"file":"UserNotificationRoot.js","names":[],"sources":["../src/UserNotificationRoot.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { ErrorBoundary } from '@burdenoff/fe-libs/shared/components';\nimport { useFeatureFlagDetails } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell';\nimport { Bell, Archive, Settings2 } from 'lucide-react';\nimport { NotificationProvider } from './providers/NotificationProvider';\nimport type { NavItem, FooterItem, NotificationRootProps } from './types';\nimport { UserNotificationRoutes } from './UserNotificationRoutes';\n\n/**\n * User Root component for the Notification microfrontend.\n *\n * This is the entry point host product shells should import. It exposes only\n * the user-facing notification surfaces (Notification Center, History) and\n * sets up the required provider stack.\n *\n * For the full admin experience (templates, create/send notification) use\n * `AdminNotificationRoot` instead.\n *\n * @example\n * ```tsx\n * import { UserNotificationRoot, type NotificationRootProps } from '@burdenoff/micro-fe/notification';\n *\n * function App() {\n * const props: NotificationRootProps = {\n * basePath: '/notifications',\n * navigate: (path) => router.push(path),\n * currentUser: { id: '1', email: 'user@example.com' },\n * workspaceId: 'ws-123',\n * apiGatewayUrl: 'https://api.example.com',\n * authToken: 'token',\n * registerNavItems: (items) => { return () => {}; },\n * onNotificationClick: (notification) => console.log('Clicked:', notification),\n * };\n *\n * return <UserNotificationRoot {...props} />;\n * }\n * ```\n */\nexport function UserNotificationRoot(props: NotificationRootProps) {\n const { registerNavItems, registerFooterItems, basePath = '/' } = props;\n const { t } = useI18n();\n const tr = (key: string, fallback: string): string => {\n const translated = t(key);\n return translated === key ? fallback : translated;\n };\n\n // Component-level feature gate. `notification.history` is declared as\n // unreleased (defaultValue=false). We use `useFeatureFlagDetails` and\n // explicitly fall back to `false` when the flag is absent from the cache,\n // because the provider's global default-allow would otherwise return `true`\n // for unseeded flags — which would defeat the whole point of the unreleased\n // pattern.\n const historyDetails = useFeatureFlagDetails('notification.history');\n const historyEnabled = historyDetails ? Boolean(historyDetails.value) : false;\n\n // Helper to join paths correctly, avoiding double slashes\n const joinPath = (base: string, path: string): string => {\n const cleanBase = base.endsWith('/') ? base.slice(0, -1) : base;\n const cleanPath = path.startsWith('/') ? path : `/${path}`;\n return cleanBase + cleanPath;\n };\n\n // Register navigation items with the shell (user-facing only)\n useEffect(() => {\n if (!registerNavItems) return;\n\n const navItems: NavItem[] = [\n {\n id: 'user-notification-center',\n label: tr('notification.nav.center', 'Notification Center'),\n path: joinPath(basePath, 'center'),\n icon: <Bell size={20} />,\n order: 10,\n group: 'notifications',\n },\n ...(historyEnabled\n ? [\n {\n id: 'user-notification-history',\n label: tr('notification.nav.history', 'History'),\n path: joinPath(basePath, 'history'),\n icon: <Archive size={20} />,\n order: 20,\n group: 'notifications',\n },\n ]\n : []),\n {\n id: 'user-notification-preferences',\n label: tr('notification.nav.preferences', 'Preferences'),\n path: joinPath(basePath, 'preferences'),\n icon: <Settings2 size={20} />,\n order: 30,\n group: 'notifications',\n },\n ];\n\n // Register and get cleanup function\n const cleanup = registerNavItems(navItems);\n\n // Return cleanup function to unregister on unmount\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerNavItems, basePath, historyEnabled, t]);\n\n // Register footer items (status indicator in left section)\n useEffect(() => {\n if (!registerFooterItems) return;\n\n const footerItems: FooterItem[] = [\n {\n id: 'user-notification-status',\n label: tr('notification.footer.ready', 'Notifications Ready'),\n type: 'status',\n order: 10,\n section: 'left',\n },\n ];\n\n const cleanup = registerFooterItems(footerItems);\n return cleanup;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [registerFooterItems, t]);\n\n return (\n <ErrorBoundary\n fallback={\n <div className=\"p-6 text-center text-text-secondary\">\n {tr(\n 'notification.error.moduleLoad',\n 'Something went wrong loading this module. Please refresh the page.'\n )}\n </div>\n }\n >\n <NotificationProvider {...props}>\n <UserNotificationRoutes />\n </NotificationProvider>\n </ErrorBoundary>\n );\n}\n"],"mappings":";;;;;;;;;AAuCA,SAAgB,EAAqB,GAA8B;CACjE,IAAM,EAAE,qBAAkB,wBAAqB,cAAW,QAAQ,GAC5D,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,MAA6B;EACpD,IAAM,IAAa,EAAE,EAAI;AACzB,SAAO,MAAe,IAAM,IAAW;IASnC,IAAiB,EAAsB,uBAAuB,EAC9D,IAAiB,IAAiB,EAAQ,EAAe,QAAS,IAGlE,KAAY,GAAc,OACZ,EAAK,SAAS,IAAI,GAAG,EAAK,MAAM,GAAG,GAAG,GAAG,MACzC,EAAK,WAAW,IAAI,GAAG,IAAO,IAAI;AAkEtD,QA7DA,QAAgB;AACT,QAqCL,QAHgB,EAhCY;GAC1B;IACE,IAAI;IACJ,OAAO,EAAG,2BAA2B,sBAAsB;IAC3D,MAAM,EAAS,GAAU,SAAS;IAClC,MAAM,kBAAC,GAAD,EAAM,MAAM,IAAM,CAAA;IACxB,OAAO;IACP,OAAO;IACR;GACD,GAAI,IACA,CACE;IACE,IAAI;IACJ,OAAO,EAAG,4BAA4B,UAAU;IAChD,MAAM,EAAS,GAAU,UAAU;IACnC,MAAM,kBAAC,GAAD,EAAS,MAAM,IAAM,CAAA;IAC3B,OAAO;IACP,OAAO;IACR,CACF,GACD,EAAE;GACN;IACE,IAAI;IACJ,OAAO,EAAG,gCAAgC,cAAc;IACxD,MAAM,EAAS,GAAU,cAAc;IACvC,MAAM,kBAAC,GAAD,EAAW,MAAM,IAAM,CAAA;IAC7B,OAAO;IACP,OAAO;IACR;GACF,CAGyC;IAKzC;EAAC;EAAkB;EAAU;EAAgB;EAAE,CAAC,EAGnD,QAAgB;AACT,QAaL,QADgB,EAVkB,CAChC;GACE,IAAI;GACJ,OAAO,EAAG,6BAA6B,sBAAsB;GAC7D,MAAM;GACN,OAAO;GACP,SAAS;GACV,CACF,CAE+C;IAG/C,CAAC,GAAqB,EAAE,CAAC,EAG1B,kBAAC,GAAD;EACE,UACE,kBAAC,OAAD;GAAK,WAAU;aACZ,EACC,iCACA,qEACD;GACG,CAAA;YAGR,kBAAC,GAAD;GAAsB,GAAI;aACxB,kBAAC,GAAD,EAA0B,CAAA;GACL,CAAA;EACT,CAAA"}
@@ -1,53 +1,54 @@
1
1
  import { useNotification as e } from "./providers/NotificationProvider.js";
2
- import { NotificationCenterPage as t } from "./pages/NotificationCenterPage.js";
3
- import { FeatureDisabledPage as n } from "./components/FeatureDisabledPage.js";
4
- import { Suspense as r, lazy as i } from "react";
5
- import { useFeatureFlagDetails as a } from "@burdenoff/fe-libs/shared/feature-flags";
6
- import { Navigate as o, Route as s, Routes as c } from "react-router";
7
- import { jsx as l, jsxs as u } from "react/jsx-runtime";
2
+ import { useTr as t } from "./shared/hooks/useTr.js";
3
+ import { NotificationCenterPage as n } from "./pages/NotificationCenterPage.js";
4
+ import { FeatureDisabledPage as r } from "./components/FeatureDisabledPage.js";
5
+ import { Suspense as i, lazy as a } from "react";
6
+ import { useFeatureFlagDetails as o } from "@burdenoff/fe-libs/shared/feature-flags";
7
+ import { Navigate as s, Route as c, Routes as l } from "react-router";
8
+ import { jsx as u, jsxs as d } from "react/jsx-runtime";
8
9
  //#region src/UserNotificationRoutes.tsx
9
- var d = i(() => import("./pages/NotificationHistoryPage.js").then((e) => ({ default: e.NotificationHistoryPage }))), f = i(() => import("./pages/NotificationPreferencesPage.js").then((e) => ({ default: e.NotificationPreferencesPage })));
10
- function p() {
11
- return /* @__PURE__ */ l("div", {
10
+ var f = a(() => import("./pages/NotificationHistoryPage.js").then((e) => ({ default: e.NotificationHistoryPage }))), p = a(() => import("./pages/NotificationPreferencesPage.js").then((e) => ({ default: e.NotificationPreferencesPage })));
11
+ function m() {
12
+ return /* @__PURE__ */ u("div", {
12
13
  className: "flex h-64 items-center justify-center",
13
- children: /* @__PURE__ */ l("div", { className: "h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent" })
14
+ children: /* @__PURE__ */ u("div", { className: "h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent" })
14
15
  });
15
16
  }
16
- function m() {
17
- let { basePath: i = "/" } = e(), m = `${i.endsWith("/") ? i.slice(0, -1) : i}/center`, h = a("notification.history"), g = h ? !!h.value : !1;
18
- return /* @__PURE__ */ l(r, {
19
- fallback: /* @__PURE__ */ l(p, {}),
20
- children: /* @__PURE__ */ u(c, { children: [
21
- /* @__PURE__ */ l(s, {
17
+ function h() {
18
+ let { basePath: a = "/" } = e(), h = t(), g = `${a.endsWith("/") ? a.slice(0, -1) : a}/center`, _ = o("notification.history"), v = _ ? !!_.value : !1;
19
+ return /* @__PURE__ */ u(i, {
20
+ fallback: /* @__PURE__ */ u(m, {}),
21
+ children: /* @__PURE__ */ d(l, { children: [
22
+ /* @__PURE__ */ u(c, {
22
23
  index: !0,
23
- element: /* @__PURE__ */ l(o, {
24
- to: m,
24
+ element: /* @__PURE__ */ u(s, {
25
+ to: g,
25
26
  replace: !0
26
27
  })
27
28
  }),
28
- /* @__PURE__ */ l(s, {
29
+ /* @__PURE__ */ u(c, {
29
30
  path: "list",
30
- element: /* @__PURE__ */ l(t, {})
31
+ element: /* @__PURE__ */ u(n, {})
31
32
  }),
32
- /* @__PURE__ */ l(s, {
33
+ /* @__PURE__ */ u(c, {
33
34
  path: "center",
34
- element: /* @__PURE__ */ l(t, {})
35
+ element: /* @__PURE__ */ u(n, {})
35
36
  }),
36
- /* @__PURE__ */ l(s, {
37
+ /* @__PURE__ */ u(c, {
37
38
  path: "history",
38
- element: g ? /* @__PURE__ */ l(d, {}) : /* @__PURE__ */ l(n, {
39
- title: "Notification history is not enabled",
40
- description: "This page is controlled by the notification.history feature flag. Ask an administrator to enable it for this tenant if history should be available."
39
+ element: v ? /* @__PURE__ */ u(f, {}) : /* @__PURE__ */ u(r, {
40
+ title: h("notification.featureDisabled.historyTitle", "Notification history is not enabled"),
41
+ description: h("notification.featureDisabled.historyUserDescription", "This page is controlled by the notification.history feature flag. Ask an administrator to enable it for this tenant if history should be available.")
41
42
  })
42
43
  }),
43
- /* @__PURE__ */ l(s, {
44
+ /* @__PURE__ */ u(c, {
44
45
  path: "preferences",
45
- element: /* @__PURE__ */ l(f, {})
46
+ element: /* @__PURE__ */ u(p, {})
46
47
  }),
47
- /* @__PURE__ */ l(s, {
48
+ /* @__PURE__ */ u(c, {
48
49
  path: "*",
49
- element: /* @__PURE__ */ l(o, {
50
- to: m,
50
+ element: /* @__PURE__ */ u(s, {
51
+ to: g,
51
52
  replace: !0
52
53
  })
53
54
  })
@@ -55,6 +56,6 @@ function m() {
55
56
  });
56
57
  }
57
58
  //#endregion
58
- export { m as UserNotificationRoutes };
59
+ export { h as UserNotificationRoutes };
59
60
 
60
61
  //# sourceMappingURL=UserNotificationRoutes.js.map