@burdenoff/microfe-i18n 2026.624.1 → 2026.625.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,14 +1,16 @@
1
- import { ChevronRight as e } from "../../node_modules/lucide-react/dist/esm/icons/chevron-right.js";
2
- import { Package as t } from "../../node_modules/lucide-react/dist/esm/icons/package.js";
3
- import { Plus as n } from "../../node_modules/lucide-react/dist/esm/icons/plus.js";
4
- import { Search as r } from "../../node_modules/lucide-react/dist/esm/icons/search.js";
5
- import { useI18n as i } from "../providers/I18nProvider.js";
6
- import { useI18nStore as a } from "../store/i18nStore.js";
7
- import { useState as o } from "react";
8
- import { jsx as s, jsxs as c } from "react/jsx-runtime";
1
+ import { Boxes as e } from "../../node_modules/lucide-react/dist/esm/icons/boxes.js";
2
+ import { ChevronRight as t } from "../../node_modules/lucide-react/dist/esm/icons/chevron-right.js";
3
+ import { Package as n } from "../../node_modules/lucide-react/dist/esm/icons/package.js";
4
+ import { Plus as r } from "../../node_modules/lucide-react/dist/esm/icons/plus.js";
5
+ import { Search as i } from "../../node_modules/lucide-react/dist/esm/icons/search.js";
6
+ import { useI18n as a } from "../providers/I18nProvider.js";
7
+ import { useI18nStore as o } from "../store/i18nStore.js";
8
+ import { useState as s } from "react";
9
+ import { jsx as c, jsxs as l } from "react/jsx-runtime";
10
+ import { AuroraBackground as u, CTAOverflowMenu as d, EmphasisPanel as f, GlassCard as p, GradientText as m, IllustratedEmptyState as h, PagePurpose as g } from "@burdenoff/fe-libs/ui";
9
11
  //#region src/i18n/pages/ProductsListPage.tsx
10
- var l = () => {
11
- let { t: l } = i(), u = (e, t, n) => l(e, t, n), { setSelectedProduct: d } = a(), [f, p] = o(""), m = [{
12
+ var _ = () => {
13
+ let { t: _ } = a(), v = (e, t, n) => _(e, t, n), { setSelectedProduct: y } = o(), [b, x] = s(""), S = [{
12
14
  id: "1",
13
15
  name: "workspaces",
14
16
  displayName: "Workspaces",
@@ -46,89 +48,151 @@ var l = () => {
46
48
  name: "notification",
47
49
  displayName: "Notifications"
48
50
  }]
49
- }].filter((e) => e.displayName.toLowerCase().includes(f.toLowerCase()) || e.name.toLowerCase().includes(f.toLowerCase()));
50
- return /* @__PURE__ */ c("div", {
51
- className: "flex h-full flex-col",
52
- children: [
53
- /* @__PURE__ */ s("div", {
54
- className: "border-b border-border-subtle bg-surface-elevated p-6",
55
- children: /* @__PURE__ */ c("div", {
56
- className: "flex items-center justify-between",
51
+ }], C = S.filter((e) => e.displayName.toLowerCase().includes(b.toLowerCase()) || e.name.toLowerCase().includes(b.toLowerCase())), w = S.reduce((e, t) => e + t.modules.length, 0), T = b.trim().length > 0;
52
+ return /* @__PURE__ */ l("div", {
53
+ className: "min-h-full w-full bg-bg-surface",
54
+ children: [/* @__PURE__ */ l("div", {
55
+ className: "relative overflow-hidden border-b border-border-seam bg-bg-surface px-6 py-6 sm:px-8 lg:px-10",
56
+ children: [/* @__PURE__ */ c(u, { intensity: "subtle" }), /* @__PURE__ */ l("div", {
57
+ className: "mx-auto flex max-w-screen-xl flex-col gap-4 sm:flex-row sm:items-start sm:justify-between",
58
+ children: [/* @__PURE__ */ l("div", {
59
+ className: "flex items-center gap-4",
57
60
  children: [/* @__PURE__ */ c("div", {
58
- className: "flex items-center gap-3",
59
- children: [/* @__PURE__ */ s(t, { className: "size-6 text-accent-primary" }), /* @__PURE__ */ s("h1", {
60
- className: "text-2xl font-semibold text-content-primary",
61
- children: u("i18n.products.title", "Products")
61
+ className: "flex size-11 shrink-0 items-center justify-center rounded-xl bg-action-primary-bg/10 text-primary shadow-elevation-1",
62
+ children: /* @__PURE__ */ c(n, {
63
+ className: "size-5",
64
+ "aria-hidden": "true"
65
+ })
66
+ }), /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("h1", {
67
+ className: "text-2xl font-bold tracking-tight text-text-primary",
68
+ children: /* @__PURE__ */ c(m, { children: v("i18n.products.title", "Products") })
69
+ }), /* @__PURE__ */ c("p", {
70
+ className: "mt-0.5 text-sm text-text-secondary",
71
+ children: v("i18n.products.subtitle", "Manage localization across products and their modules")
72
+ })] })]
73
+ }), /* @__PURE__ */ c(d, {
74
+ primary: {
75
+ label: v("i18n.products.actions.add", "Add Product"),
76
+ onSelect: () => void 0,
77
+ icon: /* @__PURE__ */ c(r, {
78
+ className: "size-4",
79
+ "aria-hidden": "true"
80
+ })
81
+ },
82
+ actions: []
83
+ })]
84
+ })]
85
+ }), /* @__PURE__ */ l("div", {
86
+ className: "mx-auto max-w-screen-xl space-y-8 px-6 py-8 sm:px-8 lg:px-10",
87
+ children: [
88
+ /* @__PURE__ */ c(g, { children: v("i18n.products.purpose", "Products are the apps you localize. Each one groups the modules (auth, billing, calendar…) whose user-facing text needs translating. Register a product here so its translation keys, languages, and coverage are tracked together — pick a product to drill into its modules and manage their strings.") }),
89
+ /* @__PURE__ */ l(f, {
90
+ className: "flex flex-col gap-4 sm:flex-row sm:items-center",
91
+ children: [/* @__PURE__ */ l("div", {
92
+ className: "flex flex-1 items-center gap-4",
93
+ children: [/* @__PURE__ */ c("div", {
94
+ className: "flex size-14 shrink-0 items-center justify-center rounded-2xl bg-action-primary-bg/10 text-primary shadow-elevation-1",
95
+ children: /* @__PURE__ */ c(e, {
96
+ className: "size-7",
97
+ "aria-hidden": "true"
98
+ })
99
+ }), /* @__PURE__ */ l("div", { children: [/* @__PURE__ */ c("p", {
100
+ className: "text-sm font-medium text-text-secondary",
101
+ children: v("i18n.products.summary.label", "Products tracked")
102
+ }), /* @__PURE__ */ c("p", {
103
+ className: "text-4xl font-bold tracking-tight text-text-primary tabular-nums",
104
+ children: S.length
105
+ })] })]
106
+ }), /* @__PURE__ */ l("div", {
107
+ className: "flex flex-wrap gap-3 sm:justify-end",
108
+ children: [/* @__PURE__ */ c("div", {
109
+ className: "rounded-lg border border-border-seam bg-bg-sunken/60 px-3 py-1.5 text-xs text-text-secondary tabular-nums",
110
+ children: v("i18n.products.summary.modules", "{{count}} modules", { count: w })
111
+ }), /* @__PURE__ */ l("div", {
112
+ className: "flex items-center gap-1.5 rounded-lg border border-border-seam bg-bg-sunken/60 px-3 py-1.5 text-xs text-text-secondary",
113
+ children: [/* @__PURE__ */ c("span", {
114
+ className: "size-1.5 rounded-full bg-status-success-text motion-safe:animate-vc-glow-pulse",
115
+ "aria-hidden": "true"
116
+ }), v("i18n.products.summary.active", "All active")]
62
117
  })]
63
- }), /* @__PURE__ */ c("button", {
64
- type: "button",
65
- className: "flex items-center gap-2 rounded-md bg-accent-primary px-4 py-2 text-sm font-medium text-white hover:bg-accent-primary-hover",
66
- children: [/* @__PURE__ */ s(n, { className: "size-4" }), u("i18n.products.actions.add", "Add Product")]
67
118
  })]
68
- })
69
- }),
70
- /* @__PURE__ */ s("div", {
71
- className: "border-b border-border-subtle bg-surface p-4",
72
- children: /* @__PURE__ */ c("div", {
73
- className: "relative",
74
- children: [/* @__PURE__ */ s(r, { className: "absolute left-3 top-1/2 size-4 -translate-y-1/2 text-content-secondary" }), /* @__PURE__ */ s("input", {
119
+ }),
120
+ /* @__PURE__ */ l("div", {
121
+ className: "relative max-w-md",
122
+ children: [/* @__PURE__ */ c(i, {
123
+ className: "pointer-events-none absolute left-3 top-1/2 size-4 -translate-y-1/2 text-text-secondary",
124
+ "aria-hidden": "true"
125
+ }), /* @__PURE__ */ c("input", {
75
126
  type: "text",
76
- "aria-label": u("i18n.products.search.ariaLabel", "Search products"),
77
- placeholder: u("i18n.products.search.placeholder", "Search products..."),
78
- value: f,
79
- onChange: (e) => p(e.target.value),
80
- className: "w-full rounded-md border border-border-subtle bg-surface-elevated py-2 pl-10 pr-4 text-sm text-content-primary placeholder:text-content-tertiary focus:border-accent-primary focus:outline-none focus:ring-1 focus:ring-accent-primary"
127
+ "aria-label": v("i18n.products.search.ariaLabel", "Search products"),
128
+ placeholder: v("i18n.products.search.placeholder", "Search products..."),
129
+ value: b,
130
+ onChange: (e) => x(e.target.value),
131
+ className: "w-full rounded-lg border border-border-seam bg-bg-elevated py-2.5 pl-10 pr-4 text-sm text-text-primary placeholder:text-text-tertiary focus:border-action-primary-bg focus-visible:shadow-[var(--shadow-focus)] focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-[var(--color-focus-ring)]"
81
132
  })]
82
- })
83
- }),
84
- /* @__PURE__ */ s("div", {
85
- className: "flex-1 overflow-auto p-6",
86
- children: /* @__PURE__ */ s("div", {
133
+ }),
134
+ C.length === 0 && /* @__PURE__ */ c(h, {
135
+ illustration: T ? "empty-search" : "empty-data",
136
+ title: T ? v("i18n.products.empty.search.title", "No products found") : v("i18n.products.empty.title", "No products yet"),
137
+ description: T ? v("i18n.products.empty.search.description", "Try a different search term to find a product.") : v("i18n.products.empty.description", "Add your first product to start managing translations.")
138
+ }),
139
+ C.length > 0 && /* @__PURE__ */ c("div", {
87
140
  className: "space-y-4",
88
- children: m.map((t) => /* @__PURE__ */ s("button", {
89
- type: "button",
90
- onClick: () => d(t),
91
- className: "block w-full cursor-pointer rounded-lg border border-border-subtle bg-surface-elevated p-6 text-left transition-all hover:border-accent-primary hover:shadow-md",
92
- children: /* @__PURE__ */ s("div", {
93
- className: "flex items-start justify-between",
94
- children: /* @__PURE__ */ c("div", {
95
- className: "flex-1",
96
- children: [
97
- /* @__PURE__ */ c("div", {
98
- className: "flex items-center gap-2",
99
- children: [/* @__PURE__ */ s("h3", {
100
- className: "text-lg font-medium text-content-primary",
101
- children: t.displayName
102
- }), /* @__PURE__ */ s("span", {
103
- className: "rounded bg-accent-primary/10 px-2 py-0.5 text-xs font-medium text-accent-primary",
104
- children: t.status === "active" ? u("i18n.shared.status.active", "Active") : u("i18n.shared.status.archived", "Archived")
105
- })]
106
- }),
107
- /* @__PURE__ */ s("p", {
108
- className: "mt-1 text-sm text-content-secondary",
109
- children: t.description
110
- }),
111
- /* @__PURE__ */ c("div", {
112
- className: "mt-4",
113
- children: [/* @__PURE__ */ s("p", {
114
- className: "mb-2 text-xs font-medium uppercase tracking-wider text-content-tertiary",
115
- children: u("i18n.products.modules.count", "Modules ({{count}})", { count: t.modules.length })
116
- }), /* @__PURE__ */ s("div", {
117
- className: "flex flex-wrap gap-2",
118
- children: t.modules.map((t) => /* @__PURE__ */ c("span", {
119
- className: "inline-flex items-center gap-1 rounded-md border border-border-subtle bg-surface px-2 py-1 text-xs text-content-secondary",
120
- children: [t.displayName, /* @__PURE__ */ s(e, { className: "size-3" })]
121
- }, t.id))
122
- })]
123
- })
124
- ]
141
+ children: C.map((e, n) => /* @__PURE__ */ c(p, {
142
+ treatment: "insight",
143
+ glow: n === 0,
144
+ className: "border-border-seam",
145
+ children: /* @__PURE__ */ c("button", {
146
+ type: "button",
147
+ onClick: () => y(e),
148
+ className: "block w-full cursor-pointer rounded-[inherit] p-6 text-left focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-[var(--color-focus-ring)]",
149
+ children: /* @__PURE__ */ l("div", {
150
+ className: "flex items-start justify-between gap-4",
151
+ children: [/* @__PURE__ */ l("div", {
152
+ className: "flex-1",
153
+ children: [
154
+ /* @__PURE__ */ l("div", {
155
+ className: "flex items-center gap-2",
156
+ children: [/* @__PURE__ */ c("h3", {
157
+ className: "text-lg font-semibold text-text-primary",
158
+ children: e.displayName
159
+ }), /* @__PURE__ */ c("span", {
160
+ className: "rounded-full bg-status-success-bg px-2 py-0.5 text-xs font-medium text-status-success-text",
161
+ children: e.status === "active" ? v("i18n.shared.status.active", "Active") : v("i18n.shared.status.archived", "Archived")
162
+ })]
163
+ }),
164
+ /* @__PURE__ */ c("p", {
165
+ className: "mt-1 text-sm text-text-secondary",
166
+ children: e.description
167
+ }),
168
+ /* @__PURE__ */ l("div", {
169
+ className: "mt-4",
170
+ children: [/* @__PURE__ */ c("p", {
171
+ className: "mb-2 text-xs font-medium uppercase tracking-wider text-text-tertiary",
172
+ children: v("i18n.products.modules.count", "Modules ({{count}})", { count: e.modules.length })
173
+ }), /* @__PURE__ */ c("div", {
174
+ className: "flex flex-wrap gap-2",
175
+ children: e.modules.map((e) => /* @__PURE__ */ l("span", {
176
+ className: "inline-flex items-center gap-1 rounded-md border border-border-seam bg-bg-sunken/60 px-2 py-1 text-xs text-text-secondary",
177
+ children: [e.displayName, /* @__PURE__ */ c(t, {
178
+ className: "size-3",
179
+ "aria-hidden": "true"
180
+ })]
181
+ }, e.id))
182
+ })]
183
+ })
184
+ ]
185
+ }), /* @__PURE__ */ c(t, {
186
+ className: "mt-1 size-5 shrink-0 text-text-tertiary",
187
+ "aria-hidden": "true"
188
+ })]
125
189
  })
126
190
  })
127
- }, t.id))
191
+ }, e.id))
128
192
  })
129
- })
130
- ]
193
+ ]
194
+ })]
131
195
  });
132
196
  };
133
197
  //#endregion
134
- export { l as ProductsListPage };
198
+ export { _ as ProductsListPage };