@burdenoff/microfe-export 2026.1124.1 → 2026.1125.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 (38) hide show
  1. package/dist/export/ExportRoutes.js +62 -57
  2. package/dist/export/ExportRoutes.js.map +1 -1
  3. package/dist/export/components/ConfirmDestructiveDialog.js +18 -14
  4. package/dist/export/components/ConfirmDestructiveDialog.js.map +1 -1
  5. package/dist/export/components/DownloadStatus.js +14 -10
  6. package/dist/export/components/DownloadStatus.js.map +1 -1
  7. package/dist/export/components/ExportProgressBar.d.ts +3 -1
  8. package/dist/export/components/ExportProgressBar.js +23 -11
  9. package/dist/export/components/ExportProgressBar.js.map +1 -1
  10. package/dist/export/components/loadingSystem.d.ts +64 -0
  11. package/dist/export/components/loadingSystem.js +49 -0
  12. package/dist/export/components/loadingSystem.js.map +1 -0
  13. package/dist/export/hooks/exportBackgroundTask.d.ts +18 -0
  14. package/dist/export/hooks/exportBackgroundTask.js +46 -0
  15. package/dist/export/hooks/exportBackgroundTask.js.map +1 -0
  16. package/dist/export/hooks/useExportQueries.js +140 -124
  17. package/dist/export/hooks/useExportQueries.js.map +1 -1
  18. package/dist/export/pages/CreateExportPage.js +29 -27
  19. package/dist/export/pages/CreateExportPage.js.map +1 -1
  20. package/dist/export/pages/ExportDashboardPage.js +114 -113
  21. package/dist/export/pages/ExportDashboardPage.js.map +1 -1
  22. package/dist/export/pages/ExportDetailPage.js +104 -98
  23. package/dist/export/pages/ExportDetailPage.js.map +1 -1
  24. package/dist/export/pages/ExportHistoryPage.js +150 -149
  25. package/dist/export/pages/ExportHistoryPage.js.map +1 -1
  26. package/dist/export/pages/ExportTemplatesPage.js +156 -154
  27. package/dist/export/pages/ExportTemplatesPage.js.map +1 -1
  28. package/dist/export/pages/TemplateDetailPage.js +142 -136
  29. package/dist/export/pages/TemplateDetailPage.js.map +1 -1
  30. package/dist/export/pages/v2/DownloadDetailPage.js +108 -103
  31. package/dist/export/pages/v2/DownloadDetailPage.js.map +1 -1
  32. package/dist/export/pages/v2/DownloadsPage.js +153 -152
  33. package/dist/export/pages/v2/DownloadsPage.js.map +1 -1
  34. package/dist/export/pages/v2/NewDownloadPage.js +142 -138
  35. package/dist/export/pages/v2/NewDownloadPage.js.map +1 -1
  36. package/dist/export/workspace-v2/DownloadCells.js +32 -20
  37. package/dist/export/workspace-v2/DownloadCells.js.map +1 -1
  38. package/package.json +2 -2
@@ -2,377 +2,379 @@ import { useExport as e } from "../providers/ExportProvider.js";
2
2
  import { useAvailableEntities as t, useCreateExportTemplate as ee, useDeleteExportTemplate as te, useExportTemplates as ne } from "../hooks/useExportQueries.js";
3
3
  import { PageLayout as n } from "../components/PageLayout.js";
4
4
  import { DownloadsTabs as r } from "../components/DownloadsTabs.js";
5
- import { ConfirmDestructiveDialog as re } from "../components/ConfirmDestructiveDialog.js";
6
- import { useNavigationV2 as ie } from "../navigation-v2/NavigationV2.js";
7
- import { useEntityLabel as ae } from "../hooks/useEntityLabel.js";
8
- import { isExportEntityDisabled as oe, isForeignProductEntity as se } from "../utils/disabledModules.js";
9
- import { getFormatDisplayName as i } from "../constants/enums.js";
10
- import { useTr as a } from "../hooks/useTr.js";
11
- import { cn as o } from "../utils/cn.js";
12
- import { nativeImpact as s, nativeNotify as c } from "../../utils/nativeBridge.js";
13
- import { useMemo as l, useState as u } from "react";
14
- import { ChevronRight as ce, FileBox as d, Loader2 as le, Plus as f, Search as ue, Sparkles as de, X as p } from "lucide-react";
5
+ import { ConfirmDestructiveDialog as i } from "../components/ConfirmDestructiveDialog.js";
6
+ import { useNavigationV2 as re } from "../navigation-v2/NavigationV2.js";
7
+ import { useEntityLabel as ie } from "../hooks/useEntityLabel.js";
8
+ import { isExportEntityDisabled as ae, isForeignProductEntity as oe } from "../utils/disabledModules.js";
9
+ import { getFormatDisplayName as se } from "../constants/enums.js";
10
+ import { useTr as ce } from "../hooks/useTr.js";
11
+ import { cn as a } from "../utils/cn.js";
12
+ import { nativeImpact as le, nativeNotify as o } from "../../utils/nativeBridge.js";
13
+ import { SkeletonBlock as s, SpinnerIcon as ue } from "../components/loadingSystem.js";
14
+ import { useMemo as de, useState as c } from "react";
15
+ import { ChevronRight as l, FileBox as u, Plus as d, Search as f, Sparkles as p, X as m } from "lucide-react";
15
16
  import { useAppShell as fe } from "@burdenoff/fe-libs/shared/providers/shell";
16
- import { jsx as m, jsxs as h } from "react/jsx-runtime";
17
- import { CTAOverflowMenu as pe, IllustratedEmptyState as me, PagePurpose as g, ThemedSelect as _ } from "@burdenoff/fe-libs/ui";
17
+ import { jsx as h, jsxs as g } from "react/jsx-runtime";
18
+ import { CTAOverflowMenu as pe, IllustratedEmptyState as me, PagePurpose as he, ThemedSelect as ge } from "@burdenoff/fe-libs/ui";
18
19
  // src/export/pages/ExportTemplatesPage.tsx
19
- var v = (e, t) => (e.endsWith("/") ? e.slice(0, -1) : e) + (t.startsWith("/") ? t : `/${t}`);
20
- function y() {
21
- let { basePath: y = "/", navigate: b } = e(), x = a(), { data: S, isLoading: C } = ne(), { deleteTemplate: he } = te(), { createTemplate: ge, isPending: w } = ee(), { data: _e } = t(), T = ie(), E = ae(T), { productSlug: D } = fe(), O = _e.filter((e) => e.enabled !== !1 && !oe(e.entityType) && !se(e.entityType, D)), [k, A] = u(null), [j, M] = u(!1), [N, P] = u(""), [F, I] = u(!1), [L, R] = u(""), [z, B] = u(""), [V, H] = u([]), [U, W] = u("CSV"), [G, K] = u(null), [q, J] = u(null), Y = () => {
20
+ var _ = (e, t) => (e.endsWith("/") ? e.slice(0, -1) : e) + (t.startsWith("/") ? t : `/${t}`);
21
+ function v() {
22
+ let { basePath: v = "/", navigate: y } = e(), b = ce(), { data: x, isLoading: S } = ne(), { deleteTemplate: _e } = te(), { createTemplate: ve, isPending: C } = ee(), { data: w } = t(), T = re(), E = ie(T), { productSlug: D } = fe(), O = w.filter((e) => e.enabled !== !1 && !ae(e.entityType) && !oe(e.entityType, D)), [k, A] = c(null), [j, M] = c(!1), [N, P] = c(""), [F, I] = c(!1), [L, R] = c(""), [z, B] = c(""), [V, H] = c([]), [U, W] = c("CSV"), [G, K] = c(null), [q, J] = c(null), Y = () => {
22
23
  R(""), B(""), H([]), W("CSV"), K(null), I(!0);
23
- }, ve = async () => {
24
- if (!L.trim()) K(x("export.templates.form.errors.nameRequired", "Template name is required."));
25
- else if (V.length === 0) K(x("export.templates.form.errors.entityRequired", "Select at least one entity type."));
24
+ }, ye = async () => {
25
+ if (!L.trim()) K(b("export.templates.form.errors.nameRequired", "Template name is required."));
26
+ else if (V.length === 0) K(b("export.templates.form.errors.entityRequired", "Select at least one entity type."));
26
27
  else {
27
28
  K(null);
28
29
  try {
29
- await ge({
30
+ await ve({
30
31
  name: L.trim(),
31
32
  description: z.trim() || void 0,
32
33
  entityTypes: V,
33
34
  format: U
34
35
  }), I(!1);
35
36
  } catch (e) {
36
- K(e instanceof Error ? e.message : x("export.templates.form.errors.createFailed", "Failed to create template."));
37
+ K(e instanceof Error ? e.message : b("export.templates.form.errors.createFailed", "Failed to create template."));
37
38
  }
38
39
  }
39
- }, ye = (e) => {
40
+ }, be = (e) => {
40
41
  H((t) => t.includes(e) ? t.filter((t) => t !== e) : [...t, e]);
41
- }, X = l(() => {
42
- if (!N) return S;
42
+ }, X = de(() => {
43
+ if (!N) return x;
43
44
  let e = N.toLowerCase();
44
- return S.filter((t) => t.name.toLowerCase().includes(e) || t.entityTypes.some((t) => t.toLowerCase().includes(e) || E(t).toLowerCase().includes(e)));
45
+ return x.filter((t) => t.name.toLowerCase().includes(e) || t.entityTypes.some((t) => t.toLowerCase().includes(e) || E(t).toLowerCase().includes(e)));
45
46
  }, [
46
- S,
47
+ x,
47
48
  N,
48
49
  E
49
50
  ]), Z = (e) => {
50
- b?.(v(y, `templates/${e}`));
51
- }, be = async (e, t) => {
52
- e.stopPropagation(), s("medium"), J(t);
51
+ y?.(_(v, `templates/${e}`));
52
+ }, xe = async (e, t) => {
53
+ e.stopPropagation(), le("medium"), J(t);
53
54
  }, Q = () => {
54
55
  J(null), A(null);
55
56
  }, $ = async () => {
56
57
  if (q) {
57
58
  A(null), M(!0);
58
59
  try {
59
- await he(q), c("success"), J(null);
60
+ await _e(q), o("success"), J(null);
60
61
  } catch (e) {
61
- c("error"), A(e instanceof Error && e.message ? e.message : x("export.templates.delete.failed", "Couldn't delete this template. Try again."));
62
+ o("error"), A(e instanceof Error && e.message ? e.message : b("export.templates.delete.failed", "Couldn't delete this template. Try again."));
62
63
  } finally {
63
64
  M(!1);
64
65
  }
65
66
  }
66
- }, xe = S.find((e) => e.id === q)?.name ?? "";
67
- return /* @__PURE__ */ h(n, {
68
- title: x("export.templates.title", "Export Templates"),
69
- subtitle: x("export.templates.subtitle", "Reusable export configurations for common data exports"),
70
- icon: /* @__PURE__ */ m(d, { size: 24 }),
71
- headerActions: /* @__PURE__ */ m(pe, {
67
+ }, Se = x.find((e) => e.id === q)?.name ?? "";
68
+ return /* @__PURE__ */ g(n, {
69
+ title: b("export.templates.title", "Export Templates"),
70
+ subtitle: b("export.templates.subtitle", "Reusable export configurations for common data exports"),
71
+ icon: /* @__PURE__ */ h(u, { size: 24 }),
72
+ headerActions: /* @__PURE__ */ h(pe, {
72
73
  primary: {
73
- label: x("export.templates.actions.newTemplate", "New Template"),
74
- icon: /* @__PURE__ */ m(f, { size: 16 }),
74
+ label: b("export.templates.actions.newTemplate", "New Template"),
75
+ icon: /* @__PURE__ */ h(d, { size: 16 }),
75
76
  onSelect: Y
76
77
  },
77
78
  actions: [{
78
- label: x("export.templates.actions.newExport", "New Export"),
79
- icon: /* @__PURE__ */ m(f, { size: 16 }),
80
- onSelect: () => b?.(v(y, "new"))
79
+ label: b("export.templates.actions.newExport", "New Export"),
80
+ icon: /* @__PURE__ */ h(d, { size: 16 }),
81
+ onSelect: () => y?.(_(v, "new"))
81
82
  }]
82
83
  }),
83
- headerContent: /* @__PURE__ */ h("span", {
84
+ headerContent: /* @__PURE__ */ g("span", {
84
85
  className: "inline-flex items-center gap-1.5 px-2.5 py-0.5 rounded-full text-xs font-medium bg-bg-sunken text-text-secondary",
85
- children: [/* @__PURE__ */ m(de, { size: 12 }), T ? X.length === 1 ? x("export.templates.summary.one", "1 setup") : x("export.templates.summary.other", "{{count}} setups", { count: X.length }) : x("export.templates.summary.available", "{{count}} template{{suffix}} available", {
86
+ children: [/* @__PURE__ */ h(p, { size: 12 }), T ? X.length === 1 ? b("export.templates.summary.one", "1 setup") : b("export.templates.summary.other", "{{count}} setups", { count: X.length }) : b("export.templates.summary.available", "{{count}} template{{suffix}} available", {
86
87
  count: X.length,
87
88
  suffix: X.length === 1 ? "" : "s"
88
89
  })]
89
90
  }),
90
91
  children: [
91
- T && /* @__PURE__ */ m(r, {}),
92
- /* @__PURE__ */ m(g, {
93
- icon: /* @__PURE__ */ m(d, { size: 16 }),
94
- children: x("export.templates.purpose", "Templates save an export setup — the entity types and format you regularly need — so you don't rebuild it each time. Create one here, then start a new export from it in a single click. Handy for recurring backups, periodic audits, or any export you run more than once.")
92
+ T && /* @__PURE__ */ h(r, {}),
93
+ /* @__PURE__ */ h(he, {
94
+ icon: /* @__PURE__ */ h(u, { size: 16 }),
95
+ children: b("export.templates.purpose", "Templates save an export setup — the entity types and format you regularly need — so you don't rebuild it each time. Create one here, then start a new export from it in a single click. Handy for recurring backups, periodic audits, or any export you run more than once.")
95
96
  }),
96
- F && /* @__PURE__ */ h("div", {
97
+ F && /* @__PURE__ */ g("div", {
97
98
  className: "border border-primary/30 rounded-xl p-6 bg-accent-wash space-y-4",
98
99
  children: [
99
- /* @__PURE__ */ h("div", {
100
+ /* @__PURE__ */ g("div", {
100
101
  className: "flex items-center justify-between",
101
- children: [/* @__PURE__ */ m("h3", {
102
+ children: [/* @__PURE__ */ h("h3", {
102
103
  className: "font-semibold text-lg",
103
- children: x("export.templates.form.title", "New Template")
104
- }), /* @__PURE__ */ m("button", {
104
+ children: b("export.templates.form.title", "New Template")
105
+ }), /* @__PURE__ */ h("button", {
105
106
  type: "button",
106
107
  onClick: () => I(!1),
107
108
  className: "p-1.5 rounded-md hover:bg-accent",
108
- children: /* @__PURE__ */ m(p, { size: 16 })
109
+ children: /* @__PURE__ */ h(m, { size: 16 })
109
110
  })]
110
111
  }),
111
- G && /* @__PURE__ */ m("p", {
112
+ G && /* @__PURE__ */ h("p", {
112
113
  className: "text-sm text-status-error-text bg-status-error-bg/10 rounded-lg px-3 py-2",
113
114
  children: G
114
115
  }),
115
- /* @__PURE__ */ h("div", {
116
+ /* @__PURE__ */ g("div", {
116
117
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
117
- children: [/* @__PURE__ */ h("div", {
118
+ children: [/* @__PURE__ */ g("div", {
118
119
  className: "space-y-1",
119
- children: [/* @__PURE__ */ h("label", {
120
+ children: [/* @__PURE__ */ g("label", {
120
121
  className: "text-sm font-medium",
121
- children: [x("export.templates.form.fields.name", "Name"), " *"]
122
- }), /* @__PURE__ */ m("input", {
122
+ children: [b("export.templates.form.fields.name", "Name"), " *"]
123
+ }), /* @__PURE__ */ h("input", {
123
124
  type: "text",
124
- "aria-label": x("export.templates.form.fields.name", "Name"),
125
- placeholder: x("export.templates.form.fields.namePlaceholder", "e.g. Weekly Tags Export"),
125
+ "aria-label": b("export.templates.form.fields.name", "Name"),
126
+ placeholder: b("export.templates.form.fields.namePlaceholder", "e.g. Weekly Tags Export"),
126
127
  value: L,
127
128
  onChange: (e) => R(e.target.value),
128
129
  className: "w-full px-3 py-2 border-2 border-border-subtle rounded-lg bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary transition-all"
129
130
  })]
130
- }), /* @__PURE__ */ h("div", {
131
+ }), /* @__PURE__ */ g("div", {
131
132
  className: "space-y-1",
132
- children: [/* @__PURE__ */ h("label", {
133
+ children: [/* @__PURE__ */ g("label", {
133
134
  className: "text-sm font-medium",
134
- children: [x("export.templates.form.fields.format", "Format"), " *"]
135
- }), /* @__PURE__ */ h(_, {
135
+ children: [b("export.templates.form.fields.format", "Format"), " *"]
136
+ }), /* @__PURE__ */ g(ge, {
136
137
  value: U,
137
138
  onChange: (e) => W(e.target.value),
138
139
  className: "w-full px-3 py-2 border-2 border-border-subtle rounded-lg bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary transition-all scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
139
- children: [/* @__PURE__ */ m("option", {
140
+ children: [/* @__PURE__ */ h("option", {
140
141
  value: "CSV",
141
- children: x("export.format.csv", "CSV")
142
- }), /* @__PURE__ */ m("option", {
142
+ children: b("export.format.csv", "CSV")
143
+ }), /* @__PURE__ */ h("option", {
143
144
  value: "JSON",
144
- children: x("export.format.json", "JSON")
145
+ children: b("export.format.json", "JSON")
145
146
  })]
146
147
  })]
147
148
  })]
148
149
  }),
149
- /* @__PURE__ */ h("div", {
150
+ /* @__PURE__ */ g("div", {
150
151
  className: "space-y-1",
151
- children: [/* @__PURE__ */ m("label", {
152
+ children: [/* @__PURE__ */ h("label", {
152
153
  className: "text-sm font-medium",
153
- children: x("export.templates.form.fields.description", "Description")
154
- }), /* @__PURE__ */ m("input", {
154
+ children: b("export.templates.form.fields.description", "Description")
155
+ }), /* @__PURE__ */ h("input", {
155
156
  type: "text",
156
- "aria-label": x("export.templates.form.fields.description", "Description"),
157
- placeholder: x("export.templates.form.fields.descriptionPlaceholder", "Optional description"),
157
+ "aria-label": b("export.templates.form.fields.description", "Description"),
158
+ placeholder: b("export.templates.form.fields.descriptionPlaceholder", "Optional description"),
158
159
  value: z,
159
160
  onChange: (e) => B(e.target.value),
160
161
  className: "w-full px-3 py-2 border-2 border-border-subtle rounded-lg bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary transition-all"
161
162
  })]
162
163
  }),
163
- /* @__PURE__ */ h("div", {
164
+ /* @__PURE__ */ g("div", {
164
165
  className: "space-y-2",
165
- children: [/* @__PURE__ */ h("label", {
166
+ children: [/* @__PURE__ */ g("label", {
166
167
  className: "text-sm font-medium",
167
168
  children: [
168
- x("export.templates.form.fields.entityTypes", "Entity Types"),
169
+ b("export.templates.form.fields.entityTypes", "Entity Types"),
169
170
  " *",
170
171
  " ",
171
- /* @__PURE__ */ m("span", {
172
+ /* @__PURE__ */ h("span", {
172
173
  className: "text-text-secondary font-normal",
173
- children: x("export.templates.form.fields.entityTypesHint", "(select at least one)")
174
+ children: b("export.templates.form.fields.entityTypesHint", "(select at least one)")
174
175
  })
175
176
  ]
176
- }), /* @__PURE__ */ m("div", {
177
+ }), /* @__PURE__ */ h("div", {
177
178
  className: "flex flex-wrap gap-2",
178
- children: O.map((e) => /* @__PURE__ */ m("button", {
179
+ children: O.map((e) => /* @__PURE__ */ h("button", {
179
180
  type: "button",
180
- onClick: () => ye(e.entityType),
181
- className: o("px-3 py-1.5 rounded-lg text-sm font-medium border-2 transition-all", V.includes(e.entityType) ? "border-primary bg-action-primary-bg/10 text-primary" : "border-border-subtle bg-bg-surface hover:border-primary/50"),
181
+ onClick: () => be(e.entityType),
182
+ className: a("px-3 py-1.5 rounded-lg text-sm font-medium border-2 transition-all", V.includes(e.entityType) ? "border-primary bg-action-primary-bg/10 text-primary" : "border-border-subtle bg-bg-surface hover:border-primary/50"),
182
183
  children: T ? E(e.entityType) : e.displayName
183
184
  }, e.entityType))
184
185
  })]
185
186
  }),
186
- /* @__PURE__ */ h("div", {
187
+ /* @__PURE__ */ g("div", {
187
188
  className: "flex gap-3 pt-2",
188
- children: [/* @__PURE__ */ h("button", {
189
+ children: [/* @__PURE__ */ g("button", {
189
190
  type: "button",
190
- onClick: ve,
191
- disabled: w,
191
+ onClick: ye,
192
+ disabled: C,
192
193
  className: "inline-flex items-center gap-2 px-5 py-2.5 bg-action-primary-bg text-action-primary-text rounded-lg hover:bg-action-primary-bg/90 transition-colors font-medium disabled:opacity-50",
193
- children: [w ? /* @__PURE__ */ m(le, {
194
+ children: [C ? /* @__PURE__ */ h(ue, {
195
+ tone: "current",
194
196
  size: 16,
195
197
  className: "animate-spin"
196
- }) : /* @__PURE__ */ m(f, { size: 16 }), x("export.templates.form.actions.create", "Create Template")]
197
- }), /* @__PURE__ */ m("button", {
198
+ }) : /* @__PURE__ */ h(d, { size: 16 }), b("export.templates.form.actions.create", "Create Template")]
199
+ }), /* @__PURE__ */ h("button", {
198
200
  type: "button",
199
201
  onClick: () => I(!1),
200
202
  className: "px-5 py-2.5 border-2 border-border-subtle rounded-lg hover:bg-accent transition-colors font-medium",
201
- children: x("export.templates.form.actions.cancel", "Cancel")
203
+ children: b("export.templates.form.actions.cancel", "Cancel")
202
204
  })]
203
205
  })
204
206
  ]
205
207
  }),
206
- /* @__PURE__ */ h("div", {
208
+ /* @__PURE__ */ g("div", {
207
209
  className: "relative group",
208
210
  children: [
209
- /* @__PURE__ */ m(ue, {
211
+ /* @__PURE__ */ h(f, {
210
212
  size: 18,
211
213
  className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary group-focus-within:text-primary transition-colors"
212
214
  }),
213
- /* @__PURE__ */ m("input", {
215
+ /* @__PURE__ */ h("input", {
214
216
  type: "text",
215
- "aria-label": x("export.templates.search.placeholder", "Search templates"),
216
- placeholder: x("export.templates.search.placeholder", "Search templates..."),
217
+ "aria-label": b("export.templates.search.placeholder", "Search templates"),
218
+ placeholder: b("export.templates.search.placeholder", "Search templates..."),
217
219
  value: N,
218
220
  onChange: (e) => P(e.target.value),
219
221
  className: "w-full pl-[3.25rem] pr-4 py-2.5 border-2 border-border-subtle rounded-lg bg-bg-surface focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary transition-all duration-200"
220
222
  }),
221
- N && /* @__PURE__ */ m("button", {
223
+ N && /* @__PURE__ */ h("button", {
222
224
  type: "button",
223
225
  onClick: () => P(""),
224
226
  className: "absolute right-3 top-1/2 -translate-y-1/2 p-1 rounded-md text-text-secondary hover:text-text-primary hover:bg-accent",
225
- children: /* @__PURE__ */ m(p, { size: 16 })
227
+ children: /* @__PURE__ */ h(m, { size: 16 })
226
228
  })
227
229
  ]
228
230
  }),
229
- C && /* @__PURE__ */ m("div", {
231
+ S && /* @__PURE__ */ h("div", {
230
232
  className: "grid grid-cols-1 lg:grid-cols-2 gap-4",
231
233
  children: [...[
232
234
  ,
233
235
  ,
234
236
  ,
235
237
  ,
236
- ]].map((e, t) => /* @__PURE__ */ h("div", {
238
+ ]].map((e, t) => /* @__PURE__ */ g("div", {
237
239
  className: "border border-border-seam rounded-xl p-5",
238
240
  children: [
239
- /* @__PURE__ */ m("div", { className: "h-5 w-40 bg-bg-sunken rounded mb-3 animate-vc-shimmer" }),
240
- /* @__PURE__ */ m("div", { className: "h-3 w-full bg-bg-sunken rounded mb-2 animate-vc-shimmer" }),
241
- /* @__PURE__ */ h("div", {
241
+ /* @__PURE__ */ h(s, { className: "h-5 w-40 bg-bg-sunken rounded mb-3 animate-vc-shimmer" }),
242
+ /* @__PURE__ */ h(s, { className: "h-3 w-full bg-bg-sunken rounded mb-2 animate-vc-shimmer" }),
243
+ /* @__PURE__ */ g("div", {
242
244
  className: "flex gap-2 mt-4",
243
- children: [/* @__PURE__ */ m("div", { className: "h-5 w-16 bg-bg-sunken rounded-full animate-vc-shimmer" }), /* @__PURE__ */ m("div", { className: "h-5 w-16 bg-bg-sunken rounded-full animate-vc-shimmer" })]
245
+ children: [/* @__PURE__ */ h(s, { className: "h-5 w-16 bg-bg-sunken rounded-full animate-vc-shimmer" }), /* @__PURE__ */ h(s, { className: "h-5 w-16 bg-bg-sunken rounded-full animate-vc-shimmer" })]
244
246
  })
245
247
  ]
246
248
  }, t))
247
249
  }),
248
- C ? null : X.length > 0 ? /* @__PURE__ */ m("div", {
250
+ S ? null : X.length > 0 ? /* @__PURE__ */ h("div", {
249
251
  className: "grid grid-cols-1 lg:grid-cols-2 gap-4",
250
- children: X.map((e, t) => /* @__PURE__ */ h("div", {
252
+ children: X.map((e, t) => /* @__PURE__ */ g("div", {
251
253
  role: "button",
252
254
  tabIndex: 0,
253
255
  onClick: () => Z(e.id),
254
256
  onKeyDown: (t) => {
255
257
  (t.key === "Enter" || t.key === " ") && (t.preventDefault(), Z(e.id));
256
258
  },
257
- className: o("text-left group cursor-pointer border border-border-seam rounded-xl overflow-hidden bg-bg-surface", "hover:border-primary/40 shadow-[var(--shadow-pop)] transition-colors duration-200", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/40", "animate-in fade-in-0"),
259
+ className: a("text-left group cursor-pointer border border-border-seam rounded-xl overflow-hidden bg-bg-surface", "hover:border-primary/40 shadow-[var(--shadow-pop)] transition-colors duration-200", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/40", "animate-in fade-in-0"),
258
260
  style: { animationDelay: `${t * 50}ms` },
259
- children: [/* @__PURE__ */ m("div", {
261
+ children: [/* @__PURE__ */ h("div", {
260
262
  className: "p-4 border-b bg-bg-sunken/30",
261
- children: /* @__PURE__ */ h("div", {
263
+ children: /* @__PURE__ */ g("div", {
262
264
  className: "flex items-start justify-between",
263
- children: [/* @__PURE__ */ h("div", {
265
+ children: [/* @__PURE__ */ g("div", {
264
266
  className: "flex items-center gap-3",
265
- children: [/* @__PURE__ */ m("div", {
267
+ children: [/* @__PURE__ */ h("div", {
266
268
  className: "p-2 rounded-lg bg-action-primary-bg/10",
267
- children: /* @__PURE__ */ m(d, {
269
+ children: /* @__PURE__ */ h(u, {
268
270
  size: 20,
269
271
  className: "text-primary"
270
272
  })
271
- }), /* @__PURE__ */ h("div", { children: [/* @__PURE__ */ m("h3", {
273
+ }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h3", {
272
274
  className: "font-semibold",
273
275
  children: e.name
274
- }), /* @__PURE__ */ h("p", {
276
+ }), /* @__PURE__ */ g("p", {
275
277
  className: "text-xs text-text-secondary",
276
- children: [i(e.format), e.isDefault && /* @__PURE__ */ m("span", {
278
+ children: [se(e.format), e.isDefault && /* @__PURE__ */ h("span", {
277
279
  className: "ml-1.5 inline-flex items-center px-1.5 py-0.5 rounded text-xs bg-action-primary-bg/10 text-primary font-medium",
278
- children: x("export.templates.card.default", "Default")
280
+ children: b("export.templates.card.default", "Default")
279
281
  })]
280
282
  })] })]
281
- }), /* @__PURE__ */ h("div", {
283
+ }), /* @__PURE__ */ g("div", {
282
284
  className: "flex items-center gap-2",
283
- children: [/* @__PURE__ */ m("button", {
285
+ children: [/* @__PURE__ */ h("button", {
284
286
  type: "button",
285
- onClick: (t) => be(t, e.id),
287
+ onClick: (t) => xe(t, e.id),
286
288
  className: "p-1.5 rounded-md text-text-secondary hover:text-status-error-text hover:bg-status-error-bg/10 transition-colors",
287
- "aria-label": x("export.templates.card.deleteAriaLabel", "Delete {{name}}", { name: e.name }),
288
- children: /* @__PURE__ */ m(p, { size: 14 })
289
- }), /* @__PURE__ */ m(ce, {
289
+ "aria-label": b("export.templates.card.deleteAriaLabel", "Delete {{name}}", { name: e.name }),
290
+ children: /* @__PURE__ */ h(m, { size: 14 })
291
+ }), /* @__PURE__ */ h(l, {
290
292
  size: 18,
291
293
  className: "text-text-secondary group-hover:text-primary transition-colors mt-1"
292
294
  })]
293
295
  })]
294
296
  })
295
- }), /* @__PURE__ */ h("div", {
297
+ }), /* @__PURE__ */ g("div", {
296
298
  className: "p-4",
297
- children: [e.description && /* @__PURE__ */ m("p", {
299
+ children: [e.description && /* @__PURE__ */ h("p", {
298
300
  className: "text-sm text-text-secondary mb-3 line-clamp-2",
299
301
  children: e.description
300
- }), /* @__PURE__ */ h("div", {
302
+ }), /* @__PURE__ */ g("div", {
301
303
  className: "flex flex-wrap gap-1.5 overflow-hidden",
302
- children: [e.entityTypes.slice(0, 6).map((e) => /* @__PURE__ */ m("span", {
304
+ children: [e.entityTypes.slice(0, 6).map((e) => /* @__PURE__ */ h("span", {
303
305
  className: "inline-flex px-2 py-0.5 rounded text-xs font-medium bg-bg-sunken text-text-secondary max-w-full truncate",
304
306
  children: E(e)
305
- }, e)), e.entityTypes.length > 6 && /* @__PURE__ */ m("span", {
307
+ }, e)), e.entityTypes.length > 6 && /* @__PURE__ */ h("span", {
306
308
  className: "inline-flex px-2 py-0.5 rounded text-xs font-medium bg-bg-sunken text-text-secondary",
307
- children: x("export.templates.card.moreEntities", "+{{count}} more", { count: e.entityTypes.length - 6 })
309
+ children: b("export.templates.card.moreEntities", "+{{count}} more", { count: e.entityTypes.length - 6 })
308
310
  })]
309
311
  })]
310
312
  })]
311
313
  }, e.id))
312
- }) : /* @__PURE__ */ m(me, {
314
+ }) : /* @__PURE__ */ h(me, {
313
315
  illustration: N ? "empty-search" : "empty-data",
314
- title: N ? x("export.templates.empty.filtered.title", "No matching templates") : x("export.templates.empty.title", "No templates yet"),
315
- description: N ? x("export.templates.empty.filtered.description", "Try adjusting your search to find what you are looking for.") : x("export.templates.empty.description", "Create a template to save reusable export configurations."),
316
- action: N ? /* @__PURE__ */ h("button", {
316
+ title: N ? b("export.templates.empty.filtered.title", "No matching templates") : b("export.templates.empty.title", "No templates yet"),
317
+ description: N ? b("export.templates.empty.filtered.description", "Try adjusting your search to find what you are looking for.") : b("export.templates.empty.description", "Create a template to save reusable export configurations."),
318
+ action: N ? /* @__PURE__ */ g("button", {
317
319
  type: "button",
318
320
  onClick: () => P(""),
319
321
  className: "inline-flex items-center gap-2 px-4 py-2 border-2 border-border-subtle rounded-lg hover:bg-accent transition-colors font-medium",
320
- children: [/* @__PURE__ */ m(p, { size: 16 }), x("export.templates.empty.filtered.actions.clear", "Clear Search")]
321
- }) : /* @__PURE__ */ h("button", {
322
+ children: [/* @__PURE__ */ h(m, { size: 16 }), b("export.templates.empty.filtered.actions.clear", "Clear Search")]
323
+ }) : /* @__PURE__ */ g("button", {
322
324
  type: "button",
323
325
  onClick: Y,
324
326
  className: "inline-flex items-center gap-2 px-4 py-2 bg-action-primary-bg text-action-primary-text rounded-lg hover:bg-action-primary-bg/90 transition-colors font-medium",
325
- children: [/* @__PURE__ */ m(f, { size: 16 }), x("export.templates.empty.actions.newTemplate", "New Template")]
327
+ children: [/* @__PURE__ */ h(d, { size: 16 }), b("export.templates.empty.actions.newTemplate", "New Template")]
326
328
  }),
327
329
  kind: N ? "no-results" : "first-use",
328
330
  glassIllustration: "documents"
329
331
  }),
330
- T ? /* @__PURE__ */ m(re, {
332
+ T ? /* @__PURE__ */ h(i, {
331
333
  open: q !== null,
332
334
  onOpenChange: (e) => {
333
335
  e || Q();
334
336
  },
335
- title: x("export.templates.delete.named", "Delete “{{name}}”?", { name: xe }),
336
- description: x("export.templates.delete.description", "This removes the saved export configuration. Existing export jobs are not deleted."),
337
- confirmLabel: x("export.templates.delete.confirmAction", "Delete Template"),
338
- keepLabel: x("export.templates.delete.cancel", "Keep Template"),
337
+ title: b("export.templates.delete.named", "Delete “{{name}}”?", { name: Se }),
338
+ description: b("export.templates.delete.description", "This removes the saved export configuration. Existing export jobs are not deleted."),
339
+ confirmLabel: b("export.templates.delete.confirmAction", "Delete Template"),
340
+ keepLabel: b("export.templates.delete.cancel", "Keep Template"),
339
341
  busy: j,
340
342
  error: k,
341
343
  onConfirm: () => void $()
342
- }) : q && /* @__PURE__ */ m("div", {
344
+ }) : q && /* @__PURE__ */ h("div", {
343
345
  role: "dialog",
344
346
  "aria-modal": "true",
345
347
  "aria-labelledby": "template-list-delete-title",
346
348
  className: "fixed inset-0 z-50 flex items-center justify-center bg-bg-surface/80 backdrop-blur-sm p-4",
347
- children: /* @__PURE__ */ h("div", {
349
+ children: /* @__PURE__ */ g("div", {
348
350
  className: "w-full max-w-md rounded-xl border-2 border-border-subtle bg-bg-surface p-6 shadow-xl",
349
351
  children: [
350
- /* @__PURE__ */ m("h2", {
352
+ /* @__PURE__ */ h("h2", {
351
353
  id: "template-list-delete-title",
352
354
  className: "text-lg font-bold",
353
- children: x("export.templates.delete.title", "Delete template?")
355
+ children: b("export.templates.delete.title", "Delete template?")
354
356
  }),
355
- /* @__PURE__ */ m("p", {
357
+ /* @__PURE__ */ h("p", {
356
358
  className: "mt-2 text-sm text-text-secondary",
357
- children: x("export.templates.delete.description", "This removes the saved export configuration. Existing export jobs are not deleted.")
359
+ children: b("export.templates.delete.description", "This removes the saved export configuration. Existing export jobs are not deleted.")
358
360
  }),
359
- k && /* @__PURE__ */ m("p", {
361
+ k && /* @__PURE__ */ h("p", {
360
362
  role: "alert",
361
363
  className: "mt-3 rounded-lg bg-status-error-bg-subtle px-3 py-2 text-sm text-status-error-text",
362
364
  children: k
363
365
  }),
364
- /* @__PURE__ */ h("div", {
366
+ /* @__PURE__ */ g("div", {
365
367
  className: "mt-6 flex flex-col-reverse sm:flex-row sm:justify-end gap-3",
366
- children: [/* @__PURE__ */ m("button", {
368
+ children: [/* @__PURE__ */ h("button", {
367
369
  type: "button",
368
370
  onClick: Q,
369
371
  className: "px-4 py-2 rounded-lg border-2 border-border-subtle hover:bg-accent transition-colors font-medium",
370
- children: x("export.templates.delete.cancel", "Keep Template")
371
- }), /* @__PURE__ */ m("button", {
372
+ children: b("export.templates.delete.cancel", "Keep Template")
373
+ }), /* @__PURE__ */ h("button", {
372
374
  type: "button",
373
375
  onClick: $,
374
376
  className: "px-4 py-2 rounded-lg bg-status-error-bg text-status-error-text hover:bg-status-error-bg/90 transition-colors font-medium",
375
- children: x("export.templates.delete.confirmAction", "Delete Template")
377
+ children: b("export.templates.delete.confirmAction", "Delete Template")
376
378
  })]
377
379
  })
378
380
  ]
@@ -381,6 +383,6 @@ function y() {
381
383
  ]
382
384
  });
383
385
  }
384
- export { y as ExportTemplatesPage };
386
+ export { v as ExportTemplatesPage };
385
387
 
386
388
  //# sourceMappingURL=ExportTemplatesPage.js.map