@burdenoff/microfe-product 2026.624.2 → 2026.625.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/dist/product/pages/ContentPageViewPage.js +25 -24
  2. package/dist/product/pages/ContentPageViewPage.js.map +1 -1
  3. package/dist/product/pages/ProductCatalogPage.js +69 -64
  4. package/dist/product/pages/ProductCatalogPage.js.map +1 -1
  5. package/dist/product/pages/ProductViewPage.js +91 -86
  6. package/dist/product/pages/ProductViewPage.js.map +1 -1
  7. package/dist/product-management/modules/content-pages/components/ContentPageForm.js +7 -7
  8. package/dist/product-management/modules/content-pages/components/ContentPageForm.js.map +1 -1
  9. package/dist/product-management/modules/content-pages/pages/ContentPageCreatePage.js +2 -2
  10. package/dist/product-management/modules/content-pages/pages/ContentPageCreatePage.js.map +1 -1
  11. package/dist/product-management/modules/content-pages/pages/ContentPageDetailPage.js +243 -230
  12. package/dist/product-management/modules/content-pages/pages/ContentPageDetailPage.js.map +1 -1
  13. package/dist/product-management/modules/content-pages/pages/ContentPageEditPage.js +2 -2
  14. package/dist/product-management/modules/content-pages/pages/ContentPageEditPage.js.map +1 -1
  15. package/dist/product-management/modules/content-pages/pages/ContentPagesListPage.js +293 -277
  16. package/dist/product-management/modules/content-pages/pages/ContentPagesListPage.js.map +1 -1
  17. package/dist/product-management/modules/feature-flags/components/FeatureFlagForm.js +1 -1
  18. package/dist/product-management/modules/feature-flags/components/FeatureFlagForm.js.map +1 -1
  19. package/dist/product-management/modules/feature-flags/pages/FeatureFlagCreatePage.js +2 -2
  20. package/dist/product-management/modules/feature-flags/pages/FeatureFlagCreatePage.js.map +1 -1
  21. package/dist/product-management/modules/feature-flags/pages/FeatureFlagDetailPage.js +158 -148
  22. package/dist/product-management/modules/feature-flags/pages/FeatureFlagDetailPage.js.map +1 -1
  23. package/dist/product-management/modules/feature-flags/pages/FeatureFlagEditPage.js +2 -2
  24. package/dist/product-management/modules/feature-flags/pages/FeatureFlagEditPage.js.map +1 -1
  25. package/dist/product-management/modules/feature-flags/pages/FeatureFlagsListPage.js +98 -81
  26. package/dist/product-management/modules/feature-flags/pages/FeatureFlagsListPage.js.map +1 -1
  27. package/dist/product-management/modules/press-kit/components/PressKitAssetForm.js +4 -4
  28. package/dist/product-management/modules/press-kit/components/PressKitAssetForm.js.map +1 -1
  29. package/dist/product-management/modules/press-kit/pages/PressKitCreatePage.js +2 -2
  30. package/dist/product-management/modules/press-kit/pages/PressKitCreatePage.js.map +1 -1
  31. package/dist/product-management/modules/press-kit/pages/PressKitDetailPage.js +109 -99
  32. package/dist/product-management/modules/press-kit/pages/PressKitDetailPage.js.map +1 -1
  33. package/dist/product-management/modules/press-kit/pages/PressKitEditPage.js +2 -2
  34. package/dist/product-management/modules/press-kit/pages/PressKitEditPage.js.map +1 -1
  35. package/dist/product-management/modules/press-kit/pages/PressKitListPage.js +252 -236
  36. package/dist/product-management/modules/press-kit/pages/PressKitListPage.js.map +1 -1
  37. package/dist/product-management/modules/products/components/ProductForm.js +8 -8
  38. package/dist/product-management/modules/products/components/ProductForm.js.map +1 -1
  39. package/dist/product-management/modules/products/components/ProductPlans.js +4 -4
  40. package/dist/product-management/modules/products/components/ProductPlans.js.map +1 -1
  41. package/dist/product-management/modules/products/pages/ProductCreatePage.js +2 -2
  42. package/dist/product-management/modules/products/pages/ProductCreatePage.js.map +1 -1
  43. package/dist/product-management/modules/products/pages/ProductDetailPage.js +408 -395
  44. package/dist/product-management/modules/products/pages/ProductDetailPage.js.map +1 -1
  45. package/dist/product-management/modules/products/pages/ProductEditPage.js +2 -2
  46. package/dist/product-management/modules/products/pages/ProductEditPage.js.map +1 -1
  47. package/dist/product-management/modules/products/pages/ProductsListPage.js +301 -281
  48. package/dist/product-management/modules/products/pages/ProductsListPage.js.map +1 -1
  49. package/dist/product-management/modules/shortcuts/components/ShortcutForm.js +3 -3
  50. package/dist/product-management/modules/shortcuts/components/ShortcutForm.js.map +1 -1
  51. package/dist/product-management/modules/shortcuts/pages/ShortcutCreatePage.js +2 -2
  52. package/dist/product-management/modules/shortcuts/pages/ShortcutCreatePage.js.map +1 -1
  53. package/dist/product-management/modules/shortcuts/pages/ShortcutDetailPage.js +221 -218
  54. package/dist/product-management/modules/shortcuts/pages/ShortcutDetailPage.js.map +1 -1
  55. package/dist/product-management/modules/shortcuts/pages/ShortcutEditPage.js +2 -2
  56. package/dist/product-management/modules/shortcuts/pages/ShortcutEditPage.js.map +1 -1
  57. package/dist/product-management/modules/shortcuts/pages/ShortcutsListPage.js +260 -241
  58. package/dist/product-management/modules/shortcuts/pages/ShortcutsListPage.js.map +1 -1
  59. package/dist/product-management/shared/components/AuditHistoryTab.js +1 -1
  60. package/dist/product-management/shared/components/AuditHistoryTab.js.map +1 -1
  61. package/dist/product-management/shared/components/feedback/EmptyState.js +2 -20
  62. package/dist/product-management/shared/hooks/useConfirmDialog.js +44 -0
  63. package/dist/product-management/shared/hooks/useConfirmDialog.js.map +1 -0
  64. package/package.json +2 -2
  65. package/dist/product-management/shared/components/feedback/EmptyState.js.map +0 -1
@@ -5,15 +5,17 @@ import { ErrorState as r } from "../../../shared/components/feedback/ErrorState.
5
5
  import { SearchInput as i } from "../../../shared/components/input/SearchInput.js";
6
6
  import { exportToCsv as a } from "../../../shared/utils/exportUtils.js";
7
7
  import { nativeConfirm as o, nativeImpact as s, nativeNotify as c } from "../../../../utils/nativeBridge.js";
8
- import { useContentPages as l, useDeleteContentPage as u } from "../hooks/useContentPages.js";
9
- import { ContentPageStatusBadge as d } from "../components/ContentPageStatusBadge.js";
10
- import { useDebounced as f } from "../../../shared/hooks/useDebounced.js";
11
- import { useEffect as p, useState as m } from "react";
12
- import { ChevronLeft as h, ChevronRight as g, Download as _, Eye as v, FileText as y, Plus as b, RefreshCw as x, SquarePen as S, Trash2 as C } from "lucide-react";
8
+ import { useConfirmDialog as l } from "../../../shared/hooks/useConfirmDialog.js";
9
+ import { useContentPages as u, useDeleteContentPage as d } from "../hooks/useContentPages.js";
10
+ import { ContentPageStatusBadge as f } from "../components/ContentPageStatusBadge.js";
11
+ import { useDebounced as p } from "../../../shared/hooks/useDebounced.js";
12
+ import { useEffect as m, useState as h } from "react";
13
+ import { ChevronLeft as ee, ChevronRight as g, Download as _, Eye as v, FileText as y, Plus as b, RefreshCw as x, SquarePen as S, Trash2 as C } from "lucide-react";
13
14
  import { jsx as w, jsxs as T } from "react/jsx-runtime";
14
15
  import { PermissionGate as E } from "@burdenoff/fe-libs/shared/components";
16
+ import { Button as D, CTAOverflowMenu as O, GlassCard as k, GradientText as A, IllustratedEmptyState as j } from "@burdenoff/fe-libs/ui";
15
17
  //#region src/product-management/modules/content-pages/pages/ContentPagesListPage.tsx
16
- var D = [
18
+ var M = [
17
19
  {
18
20
  label: "All",
19
21
  tag: ""
@@ -38,313 +40,327 @@ var D = [
38
40
  label: "Pages",
39
41
  tag: "page"
40
42
  }
41
- ], O = 20;
42
- function k() {
43
- let { navigate: k, basePath: A = "/products" } = t(), j = `${A}/content-pages`, [M, N] = m(""), P = f(M, 300), F = e(), [I, L] = m({}), [R, z] = m(0), { contentPages: B, total: V, hasMore: H, loading: U, error: W, refetch: G } = l(void 0, {
44
- ...I,
45
- search: P || void 0
43
+ ], N = 20;
44
+ function P() {
45
+ let { navigate: P, basePath: F = "/products" } = t(), I = `${F}/content-pages`, [L, R] = h(""), z = p(L, 300), B = e(), [V, H] = h({}), [U, W] = h(0), { contentPages: G, total: K, hasMore: q, loading: J, error: Y, refetch: X } = u(void 0, {
46
+ ...V,
47
+ search: z || void 0
46
48
  }, {
47
- limit: O,
48
- offset: R * O
49
- }), K = Math.max(1, Math.ceil(V / O)), q = R * O + 1, J = Math.min((R + 1) * O, V);
50
- p(() => {
51
- if (V === 0) {
52
- z(0);
49
+ limit: N,
50
+ offset: U * N
51
+ }), Z = Math.max(1, Math.ceil(K / N)), Q = U * N + 1, $ = Math.min((U + 1) * N, K);
52
+ m(() => {
53
+ if (K === 0) {
54
+ W(0);
53
55
  return;
54
56
  }
55
- let e = Math.ceil(V / O) - 1;
56
- z((t) => t > e ? e : t);
57
- }, [V]);
58
- let { deleteContentPage: Y, loading: X } = u(), Z = async (e) => {
57
+ let e = Math.ceil(K / N) - 1;
58
+ W((t) => t > e ? e : t);
59
+ }, [K]);
60
+ let { deleteContentPage: te, loading: ne } = d(), { confirm: re, ConfirmDialog: ie } = l(), ae = async (e) => {
59
61
  s("medium");
60
- let t = F("contentPages.confirmDelete", "Are you sure you want to delete this content page?"), n = await o({
62
+ let t = B("contentPages.confirmDelete", "Are you sure you want to delete this content page?"), n = await o({
61
63
  title: "Delete content page",
62
64
  message: t,
63
65
  okButtonTitle: "Delete",
64
66
  cancelButtonTitle: "Cancel"
65
67
  });
66
- if (n === null ? window.confirm(t) : n) try {
67
- await Y(e), c("success"), G();
68
+ if (n === null ? await re({
69
+ title: "Delete content page",
70
+ message: t,
71
+ okButtonTitle: "Delete",
72
+ cancelButtonTitle: "Cancel",
73
+ destructive: !0
74
+ }) : n) try {
75
+ await te(e), c("success"), X();
68
76
  } catch (e) {
69
77
  c("error"), console.error("Failed to delete content page:", e);
70
78
  }
71
- }, Q = (e) => e ? new Date(e).toLocaleDateString("en-US", {
79
+ }, oe = (e) => e ? new Date(e).toLocaleDateString("en-US", {
72
80
  year: "numeric",
73
81
  month: "short",
74
82
  day: "numeric"
75
83
  }) : "—";
76
84
  return /* @__PURE__ */ T("div", {
77
85
  className: "min-h-full bg-[var(--color-bg-canvas)] p-6 animate-in fade-in duration-200",
78
- children: [/* @__PURE__ */ T("div", {
79
- className: "mb-6",
80
- children: [
81
- /* @__PURE__ */ T("div", {
82
- className: "flex items-center justify-between mb-4",
83
- children: [/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("h1", {
84
- className: "text-3xl font-bold text-text-primary mb-2",
85
- children: F("contentPages.title", "Content Pages")
86
- }), /* @__PURE__ */ w("p", {
87
- className: "text-text-secondary",
88
- children: F("contentPages.subtitle", "Manage content pages and documentation")
89
- })] }), /* @__PURE__ */ w(E, {
90
- role: "super_admin",
91
- children: /* @__PURE__ */ T("button", {
86
+ children: [
87
+ /* @__PURE__ */ T("div", {
88
+ className: "mb-6",
89
+ children: [
90
+ /* @__PURE__ */ T("div", {
91
+ className: "flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 mb-4",
92
+ children: [/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("h1", {
93
+ className: "text-2xl md:text-3xl font-semibold tracking-tight text-text-primary mb-2",
94
+ children: /* @__PURE__ */ w(A, { children: B("contentPages.title", "Content Pages") })
95
+ }), /* @__PURE__ */ w("p", {
96
+ className: "text-text-secondary",
97
+ children: B("contentPages.subtitle", "Manage content pages and documentation")
98
+ })] }), /* @__PURE__ */ w(E, {
99
+ role: "super_admin",
100
+ children: /* @__PURE__ */ w(O, {
101
+ primary: {
102
+ label: B("contentPages.newPage", "New Page"),
103
+ onSelect: () => P(`${I}/new`),
104
+ icon: /* @__PURE__ */ w(b, { className: "size-4" })
105
+ },
106
+ actions: []
107
+ })
108
+ })]
109
+ }),
110
+ /* @__PURE__ */ w("div", {
111
+ className: "flex flex-wrap gap-1 border-b border-border-seam pb-px",
112
+ children: M.map((e) => /* @__PURE__ */ w("button", {
92
113
  type: "button",
93
- onClick: () => k(`${j}/new`),
94
- className: "\n inline-flex items-center gap-2 px-4 py-2\n bg-[var(--color-action-primary-bg)]\n text-[var(--color-action-primary-text)]\n rounded-lg\n hover:opacity-90\n transition-all duration-200\n font-medium\n ",
95
- children: [/* @__PURE__ */ w(b, { size: 20 }), F("contentPages.newPage", "New Page")]
96
- })
97
- })]
98
- }),
99
- /* @__PURE__ */ w("div", {
100
- className: "flex flex-wrap gap-1 border-b border-default pb-px",
101
- children: D.map((e) => /* @__PURE__ */ w("button", {
102
- type: "button",
103
- onClick: () => {
104
- L({
105
- ...I,
106
- tag: e.tag || void 0
107
- }), z(0);
108
- },
109
- className: `px-4 py-2 rounded-t-lg text-sm font-medium transition-all border-b-2 ${(I.tag ?? "") === e.tag ? "border-[var(--color-action-primary-bg)] text-text-primary" : "border-transparent text-text-secondary hover:text-text-primary"}`,
110
- children: F(`contentPages.tab.${e.label.toLowerCase()}`, e.label)
111
- }, e.label))
112
- }),
113
- /* @__PURE__ */ T("div", {
114
- className: "flex gap-4",
115
- children: [
116
- /* @__PURE__ */ w(i, {
117
- value: M,
118
- onChange: (e) => {
119
- N(e), z(0);
120
- },
121
- placeholder: F("contentPages.searchPlaceholder", "Search content pages..."),
122
- className: "flex-1"
123
- }),
124
- /* @__PURE__ */ T("select", {
125
- value: I.isPublished === void 0 ? "" : I.isPublished ? "published" : "all",
126
- onChange: (e) => {
127
- L({
128
- ...I,
129
- isPublished: e.target.value === "published" ? !0 : void 0
130
- }), z(0);
114
+ onClick: () => {
115
+ H({
116
+ ...V,
117
+ tag: e.tag || void 0
118
+ }), W(0);
131
119
  },
132
- className: "\n px-4 py-2\n bg-surface\n border border-default\n rounded-lg\n text-text-primary\n focus:outline-none focus:ring-2 focus:ring-[var(--color-border-focus)]\n transition-all duration-200\n ",
133
- children: [/* @__PURE__ */ w("option", {
134
- value: "",
135
- children: F("contentPages.filterAll", "All")
136
- }), /* @__PURE__ */ w("option", {
137
- value: "published",
138
- children: F("contentPages.publishedOnly", "Published Only")
139
- })]
140
- }),
141
- /* @__PURE__ */ w("button", {
142
- type: "button",
143
- onClick: () => G(),
144
- className: "\n inline-flex items-center gap-2 px-4 py-2\n bg-surface\n text-text-primary\n border border-default\n rounded-lg\n hover:bg-bg-sunken\n transition-all duration-200\n ",
145
- children: /* @__PURE__ */ w(x, { size: 18 })
146
- }),
147
- B.length > 0 && /* @__PURE__ */ w("button", {
148
- type: "button",
149
- onClick: () => a("content-pages", B.map((e) => ({
150
- id: e.id,
151
- slug: e.slug,
152
- title: e.title,
153
- isPublished: e.isPublished,
154
- contentFormat: e.contentFormat,
155
- tags: (e.tags ?? []).join(", "),
156
- sortOrder: e.sortOrder,
157
- productId: e.productId ?? "",
158
- createdAt: e.createdAt,
159
- updatedAt: e.updatedAt
160
- }))),
161
- className: "\n inline-flex items-center gap-2 px-4 py-2\n bg-surface\n text-text-primary\n border border-default\n rounded-lg\n hover:bg-bg-sunken\n transition-all duration-200\n ",
162
- title: F("contentPages.exportCsv", "Export as CSV"),
163
- children: /* @__PURE__ */ w(_, { size: 18 })
164
- })
165
- ]
166
- })
167
- ]
168
- }), W ? /* @__PURE__ */ w(r, {
169
- message: W.message,
170
- action: {
171
- label: F("productCommon.retry", "Retry"),
172
- onClick: () => G()
173
- }
174
- }) : U && B.length === 0 ? /* @__PURE__ */ w(n, { message: F("contentPages.loadingContentPages", "Loading content pages...") }) : B.length === 0 ? /* @__PURE__ */ T("div", {
175
- className: "bg-surface border border-default rounded-lg p-12 text-center animate-in fade-in duration-200",
176
- children: [/* @__PURE__ */ w("p", {
177
- className: "text-text-secondary mb-4",
178
- children: F("contentPages.noContentPagesFound", "No content pages found")
179
- }), /* @__PURE__ */ T("button", {
180
- type: "button",
181
- onClick: () => k(`${j}/new`),
182
- className: "\n inline-flex items-center gap-2 px-4 py-2\n bg-[var(--color-action-primary-bg)]\n text-[var(--color-action-primary-text)]\n rounded-lg\n hover:opacity-90\n transition-all duration-200\n font-medium\n ",
183
- children: [/* @__PURE__ */ w(b, { size: 20 }), F("contentPages.newPage", "New Page")]
184
- })]
185
- }) : /* @__PURE__ */ T("div", {
186
- className: "bg-surface border border-default rounded-lg shadow-[var(--shadow-elevation-1)] overflow-hidden",
187
- children: [/* @__PURE__ */ T("table", {
188
- className: "w-full",
189
- children: [/* @__PURE__ */ w("thead", {
190
- className: "bg-bg-sunken border-b border-default",
191
- children: /* @__PURE__ */ T("tr", { children: [
192
- /* @__PURE__ */ w("th", {
193
- className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
194
- children: F("contentPages.columnPage", "Page")
195
- }),
196
- /* @__PURE__ */ w("th", {
197
- className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
198
- children: F("contentPages.columnSlug", "Slug")
199
- }),
200
- /* @__PURE__ */ w("th", {
201
- className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
202
- children: F("contentPages.columnStatus", "Status")
203
- }),
204
- /* @__PURE__ */ w("th", {
205
- className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
206
- children: F("contentPages.columnVersion", "Version")
207
- }),
208
- /* @__PURE__ */ w("th", {
209
- className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
210
- children: F("contentPages.columnLastUpdated", "Last Updated")
211
- }),
212
- /* @__PURE__ */ w("th", {
213
- className: "text-right px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
214
- children: F("contentPages.columnActions", "Actions")
215
- })
216
- ] })
217
- }), /* @__PURE__ */ w("tbody", {
218
- className: "divide-y divide-[var(--color-border-default)]",
219
- children: B.map((e) => /* @__PURE__ */ T("tr", {
220
- className: "hover:bg-bg-sunken transition-all duration-200 cursor-pointer",
221
- onClick: () => k(`${j}/${e.id}`),
120
+ className: `px-4 py-2 rounded-t-lg text-sm font-medium transition-all border-b-2 ${(V.tag ?? "") === e.tag ? "border-[var(--color-action-primary-bg)] text-text-primary" : "border-transparent text-text-secondary hover:text-text-primary"}`,
121
+ children: B(`contentPages.tab.${e.label.toLowerCase()}`, e.label)
122
+ }, e.label))
123
+ }),
124
+ /* @__PURE__ */ T("div", {
125
+ className: "flex gap-4",
222
126
  children: [
223
- /* @__PURE__ */ w("td", {
224
- className: "px-6 py-4",
225
- children: /* @__PURE__ */ T("div", {
226
- className: "flex items-center gap-3",
227
- children: [/* @__PURE__ */ w("div", {
228
- className: "size-10 rounded-lg bg-[var(--color-status-info-subtle)] flex items-center justify-center",
229
- children: /* @__PURE__ */ w(y, {
230
- size: 20,
231
- className: "text-[var(--color-status-info)]"
232
- })
233
- }), /* @__PURE__ */ w("div", { children: /* @__PURE__ */ w("p", {
234
- className: "font-medium text-text-primary",
235
- children: e.title
236
- }) })]
237
- })
127
+ /* @__PURE__ */ w(i, {
128
+ value: L,
129
+ onChange: (e) => {
130
+ R(e), W(0);
131
+ },
132
+ placeholder: B("contentPages.searchPlaceholder", "Search content pages..."),
133
+ className: "flex-1"
238
134
  }),
239
- /* @__PURE__ */ w("td", {
240
- className: "px-6 py-4",
241
- children: /* @__PURE__ */ T("span", {
242
- className: "text-sm text-text-tertiary font-mono",
243
- children: ["/", e.slug]
244
- })
135
+ /* @__PURE__ */ T("select", {
136
+ value: V.isPublished === void 0 ? "" : V.isPublished ? "published" : "all",
137
+ onChange: (e) => {
138
+ H({
139
+ ...V,
140
+ isPublished: e.target.value === "published" ? !0 : void 0
141
+ }), W(0);
142
+ },
143
+ className: "\n px-4 py-2\n bg-surface\n border border-default\n rounded-lg\n text-text-primary\n focus:outline-none focus:ring-2 focus:ring-[var(--color-border-focus)]\n transition-all duration-200\n ",
144
+ children: [/* @__PURE__ */ w("option", {
145
+ value: "",
146
+ children: B("contentPages.filterAll", "All")
147
+ }), /* @__PURE__ */ w("option", {
148
+ value: "published",
149
+ children: B("contentPages.publishedOnly", "Published Only")
150
+ })]
245
151
  }),
246
- /* @__PURE__ */ w("td", {
247
- className: "px-6 py-4",
248
- children: /* @__PURE__ */ w(d, { isPublished: e.isPublished })
152
+ /* @__PURE__ */ w("button", {
153
+ type: "button",
154
+ onClick: () => X(),
155
+ className: "\n inline-flex items-center gap-2 px-4 py-2\n bg-surface\n text-text-primary\n border border-default\n rounded-lg\n hover:bg-bg-sunken\n transition-all duration-200\n ",
156
+ children: /* @__PURE__ */ w(x, { size: 18 })
249
157
  }),
250
- /* @__PURE__ */ w("td", {
251
- className: "px-6 py-4",
252
- children: /* @__PURE__ */ T("span", {
253
- className: "text-sm text-text-primary font-mono",
254
- children: ["v", e.version]
255
- })
158
+ G.length > 0 && /* @__PURE__ */ w("button", {
159
+ type: "button",
160
+ onClick: () => a("content-pages", G.map((e) => ({
161
+ id: e.id,
162
+ slug: e.slug,
163
+ title: e.title,
164
+ isPublished: e.isPublished,
165
+ contentFormat: e.contentFormat,
166
+ tags: (e.tags ?? []).join(", "),
167
+ sortOrder: e.sortOrder,
168
+ productId: e.productId ?? "",
169
+ createdAt: e.createdAt,
170
+ updatedAt: e.updatedAt
171
+ }))),
172
+ className: "\n inline-flex items-center gap-2 px-4 py-2\n bg-surface\n text-text-primary\n border border-default\n rounded-lg\n hover:bg-bg-sunken\n transition-all duration-200\n ",
173
+ title: B("contentPages.exportCsv", "Export as CSV"),
174
+ children: /* @__PURE__ */ w(_, { size: 18 })
175
+ })
176
+ ]
177
+ })
178
+ ]
179
+ }),
180
+ Y ? /* @__PURE__ */ w(r, {
181
+ message: Y.message,
182
+ action: {
183
+ label: B("productCommon.retry", "Retry"),
184
+ onClick: () => X()
185
+ }
186
+ }) : J && G.length === 0 ? /* @__PURE__ */ w(n, { message: B("contentPages.loadingContentPages", "Loading content pages...") }) : G.length === 0 ? /* @__PURE__ */ w(k, {
187
+ treatment: "insight",
188
+ className: "animate-in fade-in duration-200",
189
+ children: /* @__PURE__ */ w(j, {
190
+ illustration: L || V.tag || V.isPublished ? "empty-search" : "empty-files",
191
+ title: B("contentPages.noContentPagesFound", "No content pages found"),
192
+ action: /* @__PURE__ */ T(D, {
193
+ type: "button",
194
+ onClick: () => P(`${I}/new`),
195
+ children: [/* @__PURE__ */ w(b, { className: "size-4" }), B("contentPages.newPage", "New Page")]
196
+ })
197
+ })
198
+ }) : /* @__PURE__ */ T(k, {
199
+ treatment: "insight",
200
+ className: "overflow-hidden p-0",
201
+ children: [/* @__PURE__ */ T("table", {
202
+ className: "w-full",
203
+ children: [/* @__PURE__ */ w("thead", {
204
+ className: "bg-bg-sunken/60 border-b border-border-seam",
205
+ children: /* @__PURE__ */ T("tr", { children: [
206
+ /* @__PURE__ */ w("th", {
207
+ className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
208
+ children: B("contentPages.columnPage", "Page")
256
209
  }),
257
- /* @__PURE__ */ w("td", {
258
- className: "px-6 py-4",
259
- children: /* @__PURE__ */ w("span", {
260
- className: "text-sm text-text-secondary",
261
- children: Q(e.lastUpdated || e.updatedAt)
262
- })
210
+ /* @__PURE__ */ w("th", {
211
+ className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
212
+ children: B("contentPages.columnSlug", "Slug")
213
+ }),
214
+ /* @__PURE__ */ w("th", {
215
+ className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
216
+ children: B("contentPages.columnStatus", "Status")
263
217
  }),
264
- /* @__PURE__ */ w("td", {
265
- className: "px-6 py-4",
266
- children: /* @__PURE__ */ T("div", {
267
- className: "flex items-center justify-end gap-2",
268
- onClick: (e) => e.stopPropagation(),
269
- children: [/* @__PURE__ */ w("button", {
270
- type: "button",
271
- onClick: () => k(`${j}/${e.id}`),
272
- className: "p-2 rounded-lg text-text-secondary hover:bg-bg-sunken transition-all duration-200",
273
- title: F("contentPages.viewDetails", "View details"),
274
- children: /* @__PURE__ */ w(v, { size: 18 })
275
- }), /* @__PURE__ */ T(E, {
276
- role: "super_admin",
218
+ /* @__PURE__ */ w("th", {
219
+ className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
220
+ children: B("contentPages.columnVersion", "Version")
221
+ }),
222
+ /* @__PURE__ */ w("th", {
223
+ className: "text-left px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
224
+ children: B("contentPages.columnLastUpdated", "Last Updated")
225
+ }),
226
+ /* @__PURE__ */ w("th", {
227
+ className: "text-right px-6 py-3 text-xs font-semibold text-text-secondary uppercase",
228
+ children: B("contentPages.columnActions", "Actions")
229
+ })
230
+ ] })
231
+ }), /* @__PURE__ */ w("tbody", {
232
+ className: "divide-y divide-border-seam",
233
+ children: G.map((e) => /* @__PURE__ */ T("tr", {
234
+ className: "hover:bg-bg-sunken/70 transition-colors duration-200 cursor-pointer",
235
+ onClick: () => P(`${I}/${e.id}`),
236
+ children: [
237
+ /* @__PURE__ */ w("td", {
238
+ className: "px-6 py-4",
239
+ children: /* @__PURE__ */ T("div", {
240
+ className: "flex items-center gap-3",
241
+ children: [/* @__PURE__ */ w("div", {
242
+ className: "size-10 rounded-lg bg-[var(--color-status-info-subtle)] flex items-center justify-center",
243
+ children: /* @__PURE__ */ w(y, {
244
+ size: 20,
245
+ className: "text-[var(--color-status-info)]"
246
+ })
247
+ }), /* @__PURE__ */ w("div", { children: /* @__PURE__ */ w("p", {
248
+ className: "font-medium text-text-primary",
249
+ children: e.title
250
+ }) })]
251
+ })
252
+ }),
253
+ /* @__PURE__ */ w("td", {
254
+ className: "px-6 py-4",
255
+ children: /* @__PURE__ */ T("span", {
256
+ className: "text-sm text-text-tertiary font-mono",
257
+ children: ["/", e.slug]
258
+ })
259
+ }),
260
+ /* @__PURE__ */ w("td", {
261
+ className: "px-6 py-4",
262
+ children: /* @__PURE__ */ w(f, { isPublished: e.isPublished })
263
+ }),
264
+ /* @__PURE__ */ w("td", {
265
+ className: "px-6 py-4",
266
+ children: /* @__PURE__ */ T("span", {
267
+ className: "text-sm text-text-primary font-mono",
268
+ children: ["v", e.version]
269
+ })
270
+ }),
271
+ /* @__PURE__ */ w("td", {
272
+ className: "px-6 py-4",
273
+ children: /* @__PURE__ */ w("span", {
274
+ className: "text-sm text-text-secondary",
275
+ children: oe(e.lastUpdated || e.updatedAt)
276
+ })
277
+ }),
278
+ /* @__PURE__ */ w("td", {
279
+ className: "px-6 py-4",
280
+ children: /* @__PURE__ */ T("div", {
281
+ className: "flex items-center justify-end gap-2",
282
+ onClick: (e) => e.stopPropagation(),
277
283
  children: [/* @__PURE__ */ w("button", {
278
284
  type: "button",
279
- onClick: () => k(`${j}/${e.id}/edit`),
285
+ onClick: () => P(`${I}/${e.id}`),
280
286
  className: "p-2 rounded-lg text-text-secondary hover:bg-bg-sunken transition-all duration-200",
281
- title: F("contentPages.edit", "Edit"),
282
- children: /* @__PURE__ */ w(S, { size: 18 })
283
- }), /* @__PURE__ */ w("button", {
284
- type: "button",
285
- onClick: () => Z(e.id),
286
- disabled: X,
287
- className: "p-2 rounded-lg text-[var(--color-status-error)] hover:bg-[var(--color-status-error-subtle)] transition-all duration-200 disabled:opacity-50",
288
- title: F("contentPages.delete", "Delete"),
289
- children: /* @__PURE__ */ w(C, { size: 18 })
287
+ title: B("contentPages.viewDetails", "View details"),
288
+ children: /* @__PURE__ */ w(v, { size: 18 })
289
+ }), /* @__PURE__ */ T(E, {
290
+ role: "super_admin",
291
+ children: [/* @__PURE__ */ w("button", {
292
+ type: "button",
293
+ onClick: () => P(`${I}/${e.id}/edit`),
294
+ className: "p-2 rounded-lg text-text-secondary hover:bg-bg-sunken transition-all duration-200",
295
+ title: B("contentPages.edit", "Edit"),
296
+ children: /* @__PURE__ */ w(S, { size: 18 })
297
+ }), /* @__PURE__ */ w("button", {
298
+ type: "button",
299
+ onClick: () => ae(e.id),
300
+ disabled: ne,
301
+ className: "p-2 rounded-lg text-[var(--color-status-error)] hover:bg-[var(--color-status-error-subtle)] transition-all duration-200 disabled:opacity-50",
302
+ title: B("contentPages.delete", "Delete"),
303
+ children: /* @__PURE__ */ w(C, { size: 18 })
304
+ })]
290
305
  })]
291
- })]
306
+ })
292
307
  })
308
+ ]
309
+ }, e.id))
310
+ })]
311
+ }), K > N && /* @__PURE__ */ T("div", {
312
+ className: "flex items-center justify-between px-6 py-3 border-t border-border-seam bg-bg-sunken/40",
313
+ children: [/* @__PURE__ */ T("p", {
314
+ className: "text-sm text-text-secondary",
315
+ children: [
316
+ B("contentPages.showing", "Showing"),
317
+ " ",
318
+ Q,
319
+ "–",
320
+ $,
321
+ " ",
322
+ B("contentPages.of", "of"),
323
+ " ",
324
+ K,
325
+ " ",
326
+ B("contentPages.contentPages", "content pages")
327
+ ]
328
+ }), /* @__PURE__ */ T("div", {
329
+ className: "flex items-center gap-2",
330
+ children: [
331
+ /* @__PURE__ */ T("button", {
332
+ type: "button",
333
+ onClick: () => W((e) => Math.max(0, e - 1)),
334
+ disabled: U === 0 || J,
335
+ "aria-label": B("contentPages.prevPage", "Previous page"),
336
+ className: "\n inline-flex items-center gap-1 px-3 py-1.5 text-sm\n bg-surface border border-default rounded-lg\n text-text-primary\n hover:bg-bg-sunken transition-all duration-200\n disabled:opacity-40 disabled:cursor-not-allowed\n ",
337
+ children: [/* @__PURE__ */ w(ee, { size: 16 }), B("contentPages.prev", "Prev")]
338
+ }),
339
+ /* @__PURE__ */ T("span", {
340
+ className: "text-sm text-text-secondary px-2 tabular-nums",
341
+ children: [
342
+ U + 1,
343
+ " / ",
344
+ Z
345
+ ]
346
+ }),
347
+ /* @__PURE__ */ T("button", {
348
+ type: "button",
349
+ onClick: () => W((e) => e + 1),
350
+ disabled: !q && U + 1 >= Z || J,
351
+ "aria-label": B("contentPages.nextPage", "Next page"),
352
+ className: "\n inline-flex items-center gap-1 px-3 py-1.5 text-sm\n bg-surface border border-default rounded-lg\n text-text-primary\n hover:bg-bg-sunken transition-all duration-200\n disabled:opacity-40 disabled:cursor-not-allowed\n ",
353
+ children: [B("contentPages.next", "Next"), /* @__PURE__ */ w(g, { size: 16 })]
293
354
  })
294
355
  ]
295
- }, e.id))
296
- })]
297
- }), V > O && /* @__PURE__ */ T("div", {
298
- className: "flex items-center justify-between px-6 py-3 border-t border-default bg-bg-sunken/50",
299
- children: [/* @__PURE__ */ T("p", {
300
- className: "text-sm text-text-secondary",
301
- children: [
302
- F("contentPages.showing", "Showing"),
303
- " ",
304
- q,
305
- "–",
306
- J,
307
- " ",
308
- F("contentPages.of", "of"),
309
- " ",
310
- V,
311
- " ",
312
- F("contentPages.contentPages", "content pages")
313
- ]
314
- }), /* @__PURE__ */ T("div", {
315
- className: "flex items-center gap-2",
316
- children: [
317
- /* @__PURE__ */ T("button", {
318
- type: "button",
319
- onClick: () => z((e) => Math.max(0, e - 1)),
320
- disabled: R === 0 || U,
321
- "aria-label": F("contentPages.prevPage", "Previous page"),
322
- className: "\n inline-flex items-center gap-1 px-3 py-1.5 text-sm\n bg-surface border border-default rounded-lg\n text-text-primary\n hover:bg-bg-sunken transition-all duration-200\n disabled:opacity-40 disabled:cursor-not-allowed\n ",
323
- children: [/* @__PURE__ */ w(h, { size: 16 }), F("contentPages.prev", "Prev")]
324
- }),
325
- /* @__PURE__ */ T("span", {
326
- className: "text-sm text-text-secondary px-2",
327
- children: [
328
- R + 1,
329
- " / ",
330
- K
331
- ]
332
- }),
333
- /* @__PURE__ */ T("button", {
334
- type: "button",
335
- onClick: () => z((e) => e + 1),
336
- disabled: !H && R + 1 >= K || U,
337
- "aria-label": F("contentPages.nextPage", "Next page"),
338
- className: "\n inline-flex items-center gap-1 px-3 py-1.5 text-sm\n bg-surface border border-default rounded-lg\n text-text-primary\n hover:bg-bg-sunken transition-all duration-200\n disabled:opacity-40 disabled:cursor-not-allowed\n ",
339
- children: [F("contentPages.next", "Next"), /* @__PURE__ */ w(g, { size: 16 })]
340
- })
341
- ]
356
+ })]
342
357
  })]
343
- })]
344
- })]
358
+ }),
359
+ ie
360
+ ]
345
361
  });
346
362
  }
347
363
  //#endregion
348
- export { k as ContentPagesListPage };
364
+ export { P as ContentPagesListPage };
349
365
 
350
366
  //# sourceMappingURL=ContentPagesListPage.js.map