impact-nova 2.1.0-alpha.7 → 2.1.0-alpha.9

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 (108) hide show
  1. package/dist/components/data/ag-grid-react/ag-grid.types.d.ts +6 -0
  2. package/dist/components/data/ag-grid-react/build-ag-grid-theme.d.ts +3 -0
  3. package/dist/components/data/ag-grid-react/cell-renderers/editors/input-cell-editor.js +58 -58
  4. package/dist/components/data/ag-grid-react/column-indicator-sync-bus.d.ts +9 -0
  5. package/dist/components/data/ag-grid-react/column-indicator-sync-bus.js +15 -0
  6. package/dist/components/data/ag-grid-react/headers/column-menu/column-settings-menu.js +78 -73
  7. package/dist/components/data/ag-grid-react/headers/custom-header.js +3 -1
  8. package/dist/components/data/ag-grid-react/headers/header-search-input.js +87 -91
  9. package/dist/components/data/ag-grid-react/index.d.ts +1 -1
  10. package/dist/components/data/ag-grid-react/index.js +109 -100
  11. package/dist/components/data/ag-grid-react/notify-column-indicator-sync.d.ts +3 -2
  12. package/dist/components/data/ag-grid-react/notify-column-indicator-sync.js +4 -3
  13. package/dist/components/data/ag-grid-react/sync-ag-grid-theme-mode.d.ts +3 -0
  14. package/dist/components/data/ag-grid-react/sync-ag-grid-theme-mode.js +10 -0
  15. package/dist/components/data/ag-grid-react/theme.d.ts +1 -0
  16. package/dist/components/data/ag-grid-react/theme.js +93 -21
  17. package/dist/components/data/data-table/column-indicator.d.ts +1 -1
  18. package/dist/components/data/data-table/column-indicator.js +15 -11
  19. package/dist/components/data/data-table/data-table-column-def-pin.d.ts +9 -4
  20. package/dist/components/data/data-table/data-table-column-def-pin.js +38 -38
  21. package/dist/components/data/data-table/data-table-saved-views.js +37 -37
  22. package/dist/components/data/data-table/data-table.js +78 -73
  23. package/dist/components/data/data-table/data-table.types.d.ts +7 -1
  24. package/dist/components/data/data-table/indicator-legend.d.ts +13 -2
  25. package/dist/components/data/data-table/indicator-legend.js +20 -17
  26. package/dist/components/data/data-table/pin-switch.js +9 -9
  27. package/dist/components/data/data-table/use-data-table-column-list-sync.js +92 -89
  28. package/dist/components/data/nested-list/nested-list-change-detection.d.ts +11 -0
  29. package/dist/components/data/nested-list/nested-list-change-detection.js +13 -0
  30. package/dist/components/data/nested-list/nested-list.js +107 -97
  31. package/dist/components/data-display/calendar/calendar.d.ts +1 -1
  32. package/dist/components/data-display/calendar/calendar.js +194 -189
  33. package/dist/components/data-display/chart/chart-palette.d.ts +16 -0
  34. package/dist/components/data-display/chart/chart-palette.js +28 -0
  35. package/dist/components/data-display/chart/chart.js +121 -115
  36. package/dist/components/data-display/chart/chart.utils.js +9 -6
  37. package/dist/components/data-display/chart/index.d.ts +1 -0
  38. package/dist/components/data-display/chart/index.js +15 -9
  39. package/dist/components/data-display/chart/resolve-highcharts-options.d.ts +3 -0
  40. package/dist/components/data-display/chart/resolve-highcharts-options.js +35 -0
  41. package/dist/components/data-display/statistics-card/statistics-card.color.d.ts +6 -0
  42. package/dist/components/data-display/statistics-card/statistics-card.color.js +19 -0
  43. package/dist/components/data-display/statistics-card/statistics-card.hooks.js +50 -48
  44. package/dist/components/data-display/statistics-card/statistics-card.js +127 -146
  45. package/dist/components/feedback/alert-dialog/alert-dialog.js +15 -15
  46. package/dist/components/feedback/dialog/dialog.js +3 -3
  47. package/dist/components/feedback/drawer/drawer.js +32 -32
  48. package/dist/components/feedback/sheet/sheet.js +8 -8
  49. package/dist/components/feedback/sheet/sheet.variants.js +1 -1
  50. package/dist/components/feedback/toast/toast.js +83 -92
  51. package/dist/components/flows/command-palette/command-palette-context.types.d.ts +5 -0
  52. package/dist/components/flows/command-palette/command-palette.d.ts +4 -16
  53. package/dist/components/flows/command-palette/command-palette.js +245 -258
  54. package/dist/components/flows/command-palette/command-palette.types.d.ts +9 -0
  55. package/dist/components/flows/command-palette/shortcut-overlay.js +6 -6
  56. package/dist/components/flows/filter-panel/filter-panel.d.ts +3 -2
  57. package/dist/components/flows/filter-panel/filter-panel.js +99 -104
  58. package/dist/components/flows/filter-strip/filter-summary.js +41 -41
  59. package/dist/components/flows/filter-strip/filter-tag-list.js +48 -48
  60. package/dist/components/flows/wizard/wizard.js +32 -32
  61. package/dist/components/forms/choice-card/choice-card.d.ts +2 -2
  62. package/dist/components/forms/choice-card/choice-card.js +156 -166
  63. package/dist/components/forms/combobox/combobox.js +70 -70
  64. package/dist/components/forms/date-picker/date-picker.js +31 -30
  65. package/dist/components/forms/file-upload/file-upload.js +146 -168
  66. package/dist/components/forms/prompt/prompt.js +47 -48
  67. package/dist/components/forms/select/components/SelectAllRow.js +14 -14
  68. package/dist/components/forms/select/components/SelectMenuFooter.js +12 -12
  69. package/dist/components/forms/select/components/SelectMenuHeader.js +44 -44
  70. package/dist/components/forms/select/components/SelectMenuListBody.js +22 -22
  71. package/dist/components/forms/select/components/SelectMenuPanel.js +8 -8
  72. package/dist/components/forms/select/components/SelectOptionRow.js +62 -62
  73. package/dist/components/forms/select/select.d.ts +5 -4
  74. package/dist/components/forms/select/select.js +123 -120
  75. package/dist/components/forms/select/select.types.d.ts +95 -204
  76. package/dist/components/forms/slider/slider.js +17 -17
  77. package/dist/components/forms/smart-input/smart-input.js +49 -49
  78. package/dist/components/forms/textarea/textarea.js +25 -25
  79. package/dist/components/layout/breadcrumb/breadcrumb.js +112 -118
  80. package/dist/components/layout/header/header.d.ts +5 -17
  81. package/dist/components/layout/header/header.js +113 -116
  82. package/dist/components/layout/header/header.types.d.ts +3 -0
  83. package/dist/components/layout/sidebar/sidebar.js +5 -5
  84. package/dist/components/layout/sidebar/sidebar.variants.js +1 -1
  85. package/dist/components/primitives/accordion/accordion.js +38 -41
  86. package/dist/components/primitives/kbd/kbd.variants.js +1 -1
  87. package/dist/i18n/defaultMessages.d.ts +2 -0
  88. package/dist/i18n/defaultMessages.js +6 -4
  89. package/dist/i18n/locales/de.js +2 -0
  90. package/dist/i18n/locales/es.js +2 -0
  91. package/dist/i18n/locales/hi.js +2 -0
  92. package/dist/i18n/locales/kn.js +2 -0
  93. package/dist/impact-nova-base.scss +8 -5
  94. package/dist/impact-nova-components.css +2 -2
  95. package/dist/impact-nova-tokens.scss +346 -189
  96. package/dist/impact-nova.css +1 -1
  97. package/dist/index.js +505 -499
  98. package/dist/lib/resolve-design-token-color.d.ts +5 -0
  99. package/dist/lib/resolve-design-token-color.js +12 -0
  100. package/dist/llms/rules/ag-grid.js +1 -1
  101. package/dist/llms/rules/installation.js +1 -1
  102. package/dist/llms/rules/requirements.js +1 -1
  103. package/dist/tailwind.config.js +297 -0
  104. package/dist/theme/tailwind-colors.js +199 -0
  105. package/dist/theme/tokens/chart-series-palette.json.d.ts +53 -0
  106. package/dist/theme/tokens/chart-series-palette.json.js +7 -0
  107. package/package.json +32 -259
  108. package/tailwind.config.js +0 -335
@@ -1,184 +1,168 @@
1
- import { jsx as e, jsxs as c, Fragment as k } from "react/jsx-runtime";
2
- import * as o from "react";
3
- import { cn as f } from "../../../lib/utils.js";
4
- import { Cross as T, Eye as I, Delete as L, Document as B } from "impact-nova-icons";
5
- import { FileUpload as M, Text as A, Csv as E, Excel as O } from "../../ui/local-raster-icons/rasterIcons.js";
6
- import { Tooltip as U, TooltipTrigger as C, TooltipContent as D } from "../../feedback/tooltip/tooltip.js";
7
- import { useImpactNovaI18n as z } from "../../../i18n/use-impact-nova-i18n.js";
8
- const R = o.createContext(void 0), j = () => {
9
- const a = o.useContext(R);
1
+ import { jsx as e, jsxs as c, Fragment as L } from "react/jsx-runtime";
2
+ import * as y from "react";
3
+ import { createComponent as v } from "../../../lib/primitives/create-component.js";
4
+ import { createCompoundPart as j } from "../../../lib/primitives/create-compound.js";
5
+ import { cn as F } from "../../../lib/utils.js";
6
+ import { Cross as E, Eye as M, Delete as B, Document as P } from "impact-nova-icons";
7
+ import { FileUpload as S, Text as A, Csv as O, Excel as R } from "../../ui/local-raster-icons/rasterIcons.js";
8
+ import { Tooltip as w, TooltipTrigger as D, TooltipContent as z } from "../../feedback/tooltip/tooltip.js";
9
+ import { useImpactNovaI18n as T } from "../../../i18n/use-impact-nova-i18n.js";
10
+ const k = y.createContext(void 0), H = [], I = () => {
11
+ const a = y.useContext(k);
10
12
  if (!a)
11
13
  throw new Error("useFileUpload must be used within a FileUpload component");
12
14
  return a;
13
- }, S = o.forwardRef(
15
+ }, J = v(
16
+ "FileUpload",
14
17
  ({
15
18
  className: a,
16
19
  children: t,
17
20
  onFilesChange: l,
18
- maxFiles: r = 1,
19
- accept: d = [],
20
- disabled: m = !1,
21
- value: u = [],
22
- ...p
23
- }, b) => {
24
- const [h, x] = o.useState(u);
25
- o.useEffect(() => {
26
- x(u);
27
- }, [u]);
28
- const g = (n) => {
29
- if (m) return;
30
- let s = n;
31
- d.length > 0 && (s = s.filter((y) => {
32
- const w = y.name.split(".").pop()?.toLowerCase();
33
- return w && d.includes(w);
21
+ maxFiles: o = 1,
22
+ accept: s = [],
23
+ disabled: p = !1,
24
+ value: m = H,
25
+ ...d
26
+ }, U) => {
27
+ const [f, u] = y.useState(m);
28
+ y.useEffect(() => {
29
+ u(m);
30
+ }, [m]);
31
+ const x = (n) => {
32
+ if (p) return;
33
+ let r = n;
34
+ s.length > 0 && (r = r.filter((N) => {
35
+ const C = N.name.split(".").pop()?.toLowerCase();
36
+ return C && s.includes(C);
34
37
  }));
35
- const v = r - h.length;
36
- if (v <= 0) return;
37
- const F = s.slice(0, v);
38
- if (F.length > 0) {
39
- const y = [...h, ...F];
40
- x(y), l?.(y);
38
+ const h = o - f.length;
39
+ if (h <= 0) return;
40
+ const g = r.slice(0, h);
41
+ if (g.length > 0) {
42
+ const N = [...f, ...g];
43
+ u(N), l?.(N);
41
44
  }
42
- }, N = (n) => {
43
- if (m) return;
44
- const s = h.filter((v) => v !== n);
45
- x(s), l?.(s);
45
+ }, b = (n) => {
46
+ if (p) return;
47
+ const r = f.filter((h) => h !== n);
48
+ u(r), l?.(r);
46
49
  };
47
50
  return /* @__PURE__ */ e(
48
- R.Provider,
51
+ k.Provider,
49
52
  {
50
- value: { files: h, addFiles: g, removeFile: N, maxFiles: r, accept: d, disabled: m },
53
+ value: { files: f, addFiles: x, removeFile: b, maxFiles: o, accept: s, disabled: p },
51
54
  children: /* @__PURE__ */ e(
52
55
  "div",
53
56
  {
54
- ref: b,
55
- className: f("w-full max-w-[550px]", a),
57
+ ref: U,
58
+ className: F("w-full max-w-[550px]", a),
56
59
  "data-component": "file-upload",
57
- "data-disabled": m || void 0,
58
- ...p,
60
+ "data-disabled": p || void 0,
61
+ ...d,
59
62
  children: t
60
63
  }
61
64
  )
62
65
  }
63
66
  );
64
67
  }
65
- );
66
- S.displayName = "FileUpload";
67
- const P = o.forwardRef(({ className: a, children: t, ...l }, r) => /* @__PURE__ */ e(
68
- "div",
69
- {
70
- ref: r,
71
- className: f(
72
- "flex flex-col gap-4 p-4 min-h-[274px] bg-canvas-elevated rounded-2xl shadow-elevation-header",
73
- a
74
- ),
75
- ...l,
76
- children: t
77
- }
78
- ));
79
- P.displayName = "FileUploadContent";
80
- const H = o.forwardRef(({ className: a, children: t, ...l }, r) => /* @__PURE__ */ e(
68
+ ), Q = j("file-upload", {
69
+ part: "content",
70
+ displayName: "FileUploadContent",
71
+ className: "flex flex-col gap-4 p-4 min-h-[274px] bg-canvas-elevated rounded-2xl shadow-elevation-header"
72
+ }), W = v("FileUploadHeader", ({ className: a, children: t, ...l }, o) => /* @__PURE__ */ e(
81
73
  "div",
82
74
  {
83
- ref: r,
84
- className: f("flex justify-between items-center w-full", a),
75
+ ref: o,
76
+ className: F("flex justify-between items-center w-full", a),
85
77
  ...l,
86
78
  children: /* @__PURE__ */ e("div", { className: "flex flex-col gap-[2px] w-full", children: t })
87
79
  }
88
- ));
89
- H.displayName = "FileUploadHeader";
90
- const Z = o.forwardRef(({ className: a, children: t, ...l }, r) => /* @__PURE__ */ e(
80
+ )), X = v("FileUploadTitle", ({ className: a, children: t, ...l }, o) => /* @__PURE__ */ e(
91
81
  "h3",
92
82
  {
93
- ref: r,
94
- className: f("text-base font-extrabold text-content leading-6", a),
83
+ ref: o,
84
+ className: F("text-base font-extrabold text-content leading-6", a),
95
85
  ...l,
96
86
  children: t
97
87
  }
98
- ));
99
- Z.displayName = "FileUploadTitle";
100
- const $ = o.forwardRef(({ className: a, children: t, ...l }, r) => /* @__PURE__ */ e(
88
+ )), ee = v("FileUploadDescription", ({ className: a, children: t, ...l }, o) => /* @__PURE__ */ e(
101
89
  "p",
102
90
  {
103
- ref: r,
104
- className: f(
91
+ ref: o,
92
+ className: F(
105
93
  "text-sm font-medium text-navigation-muted leading-5",
106
94
  a
107
95
  ),
108
96
  ...l,
109
97
  children: t
110
98
  }
111
- ));
112
- $.displayName = "FileUploadDescription";
113
- const G = o.forwardRef(({ className: a, ...t }, l) => {
114
- const { t: r } = z(), d = r("aria.close");
115
- return /* @__PURE__ */ c(U, { children: [
116
- /* @__PURE__ */ e(C, { asChild: !0, children: /* @__PURE__ */ e(
99
+ )), te = v("FileUploadClose", ({ className: a, ...t }, l) => {
100
+ const { t: o } = T(), s = o("aria.close");
101
+ return /* @__PURE__ */ c(w, { children: [
102
+ /* @__PURE__ */ e(D, { asChild: !0, children: /* @__PURE__ */ e(
117
103
  "button",
118
104
  {
119
105
  ref: l,
120
- className: f(
106
+ className: F(
121
107
  "text-content-tertiary hover:text-content transition-colors",
122
108
  a
123
109
  ),
124
110
  type: "button",
125
- "aria-label": d,
111
+ "aria-label": s,
126
112
  ...t,
127
- children: /* @__PURE__ */ e(T, { size: 16 })
113
+ children: /* @__PURE__ */ e(E, { size: 16 })
128
114
  }
129
115
  ) }),
130
- /* @__PURE__ */ e(D, { side: "top", variant: "tertiary", children: d })
116
+ /* @__PURE__ */ e(z, { side: "top", variant: "tertiary", children: s })
131
117
  ] });
132
- });
133
- G.displayName = "FileUploadClose";
134
- const K = o.forwardRef(({ className: a, label: t, subLabel: l, ...r }, d) => {
135
- const { addFiles: m, accept: u, disabled: p, files: b, maxFiles: h } = j(), [x, g] = o.useState(!1), N = o.useRef(null);
136
- if (b.length >= h)
118
+ }), ae = v("FileUploadDropZone", ({ className: a, label: t, subLabel: l, ...o }, s) => {
119
+ const { addFiles: p, accept: m, disabled: d, files: U, maxFiles: f } = I(), [u, x] = y.useState(!1), b = y.useRef(null);
120
+ if (U.length >= f)
137
121
  return null;
138
122
  const n = (i) => {
139
- i.preventDefault(), p || g(!0);
140
- }, s = (i) => {
141
- i.preventDefault(), g(!1);
142
- }, v = (i) => {
143
- i.preventDefault(), g(!1), !p && i.dataTransfer.files?.length && m(Array.from(i.dataTransfer.files));
144
- }, F = () => {
145
- p || N.current?.click();
146
- }, y = (i) => {
147
- i.target.files?.length && (m(Array.from(i.target.files)), i.target.value = "");
148
- }, w = u.length > 0 ? u.map((i) => `.${i}`).join(",") : void 0;
123
+ i.preventDefault(), d || x(!0);
124
+ }, r = (i) => {
125
+ i.preventDefault(), x(!1);
126
+ }, h = (i) => {
127
+ i.preventDefault(), x(!1), !d && i.dataTransfer.files?.length && p(Array.from(i.dataTransfer.files));
128
+ }, g = () => {
129
+ d || b.current?.click();
130
+ }, N = (i) => {
131
+ i.target.files?.length && (p(Array.from(i.target.files)), i.target.value = "");
132
+ }, C = m.length > 0 ? m.map((i) => `.${i}`).join(",") : void 0;
149
133
  return /* @__PURE__ */ c(
150
134
  "div",
151
135
  {
152
- ref: d,
153
- onClick: F,
136
+ ref: s,
137
+ onClick: g,
154
138
  onDragOver: n,
155
- onDragLeave: s,
156
- onDrop: v,
157
- className: f(
139
+ onDragLeave: r,
140
+ onDrop: h,
141
+ className: F(
158
142
  "relative flex flex-col items-center justify-end p-4 pt-6 pb-6 gap-2 h-[148px] rounded-lg border border-dashed border-stroke-accent bg-transparent cursor-pointer transition-colors",
159
- x && "border-brand bg-brand/5",
160
- p && "opacity-50 cursor-not-allowed",
143
+ u && "border-brand bg-brand/5",
144
+ d && "opacity-50 cursor-not-allowed",
161
145
  a
162
146
  ),
163
147
  "data-component": "file-upload-dropzone",
164
- "data-state": x ? "drag-over" : "idle",
165
- ...r,
148
+ "data-state": u ? "drag-over" : "idle",
149
+ ...o,
166
150
  children: [
167
151
  /* @__PURE__ */ e(
168
152
  "input",
169
153
  {
170
- ref: N,
154
+ ref: b,
171
155
  type: "file",
172
156
  multiple: !0,
173
157
  className: "hidden",
174
- accept: w,
175
- onChange: y,
176
- disabled: p
158
+ accept: C,
159
+ onChange: N,
160
+ disabled: d
177
161
  }
178
162
  ),
179
- /* @__PURE__ */ e("div", { className: "absolute top-[24px] left-1/2 -translate-x-1/2 pointer-events-none", children: /* @__PURE__ */ e(M, { size: 56 }) }),
163
+ /* @__PURE__ */ e("div", { className: "absolute top-[24px] left-1/2 -translate-x-1/2 pointer-events-none", children: /* @__PURE__ */ e(S, { size: 56 }) }),
180
164
  /* @__PURE__ */ c("div", { className: "text-center space-y-1 z-10 mt-auto", children: [
181
- /* @__PURE__ */ e("p", { className: "text-sm font-medium text-content leading-5", children: t || /* @__PURE__ */ c(k, { children: [
165
+ /* @__PURE__ */ e("p", { className: "text-sm font-medium text-content leading-5", children: t || /* @__PURE__ */ c(L, { children: [
182
166
  "Drag your files here or",
183
167
  " ",
184
168
  /* @__PURE__ */ e("span", { className: "text-brand text-sm font-medium hover:underline", children: "Choose File" })
@@ -188,111 +172,105 @@ const K = o.forwardRef(({ className: a, label: t, subLabel: l, ...r }, d) => {
188
172
  ]
189
173
  }
190
174
  );
191
- });
192
- K.displayName = "FileUploadDropZone";
193
- const V = o.forwardRef(({ className: a, children: t, ...l }, r) => /* @__PURE__ */ e("div", { ref: r, className: f("flex flex-col gap-3", a), ...l, children: t }));
194
- V.displayName = "FileUploadList";
195
- const q = o.forwardRef(
196
- ({ className: a, file: t, onRemove: l, onView: r, onClick: d, ...m }, u) => {
197
- const { t: p } = z(), { removeFile: b, disabled: h } = j(), x = (n) => {
198
- n.stopPropagation(), l ? l() : b(t);
199
- }, g = (n) => {
175
+ }), le = j("file-upload", {
176
+ part: "list",
177
+ displayName: "FileUploadList",
178
+ className: "flex flex-col gap-3"
179
+ }), oe = v(
180
+ "FileUploadItem",
181
+ ({ className: a, file: t, onRemove: l, onView: o, onClick: s, ...p }, m) => {
182
+ const { t: d } = T(), { removeFile: U, disabled: f } = I(), u = (n) => {
183
+ n.stopPropagation(), l ? l() : U(t);
184
+ }, x = (n) => {
200
185
  if (n === 0) return "0 B";
201
- const s = 1024, v = ["B", "KB", "MB", "GB"], F = Math.floor(Math.log(n) / Math.log(s));
202
- return parseFloat((n / Math.pow(s, F)).toFixed(2)) + " " + v[F];
203
- }, N = (n) => {
186
+ const r = 1024, h = ["B", "KB", "MB", "GB"], g = Math.floor(Math.log(n) / Math.log(r));
187
+ return parseFloat((n / Math.pow(r, g)).toFixed(2)) + " " + h[g];
188
+ }, b = (n) => {
204
189
  switch (n.split(".").pop()?.toLowerCase()) {
205
190
  case "xls":
206
191
  case "xlsx":
207
- return /* @__PURE__ */ e(O, { size: 36 });
192
+ return /* @__PURE__ */ e(R, { size: 36 });
208
193
  case "csv":
209
- return /* @__PURE__ */ e(E, { size: 36 });
194
+ return /* @__PURE__ */ e(O, { size: 36 });
210
195
  case "txt":
211
196
  return /* @__PURE__ */ e(A, { size: 36 });
212
197
  default:
213
- return /* @__PURE__ */ e(B, { size: 36, className: "text-content-icon" });
198
+ return /* @__PURE__ */ e(P, { size: 36, className: "text-content-icon" });
214
199
  }
215
200
  };
216
201
  return /* @__PURE__ */ e(
217
202
  "div",
218
203
  {
219
- ref: u,
220
- onClick: d,
221
- className: f(
204
+ ref: m,
205
+ onClick: s,
206
+ className: F(
222
207
  "flex flex-col justify-between items-stretch gap-2 p-4 border border-stroke-hairline rounded-xl bg-canvas-elevated",
223
- d && "cursor-pointer",
208
+ s && "cursor-pointer",
224
209
  a
225
210
  ),
226
211
  "data-component": "file-upload-item",
227
212
  "data-file-name": t.name,
228
213
  "data-file-size": t.size,
229
- ...m,
214
+ ...p,
230
215
  children: /* @__PURE__ */ c("div", { className: "flex justify-between items-center gap-2 z-10", children: [
231
216
  /* @__PURE__ */ c("div", { className: "flex gap-2 min-w-0", children: [
232
- /* @__PURE__ */ e("div", { className: "w-9 h-9 shrink-0", children: N(t.name) }),
217
+ /* @__PURE__ */ e("div", { className: "w-9 h-9 shrink-0", children: b(t.name) }),
233
218
  /* @__PURE__ */ c("div", { className: "flex flex-col justify-between gap-[2px] min-w-0", children: [
234
- /* @__PURE__ */ c(U, { children: [
235
- /* @__PURE__ */ e(C, { asChild: !0, children: /* @__PURE__ */ e("span", { className: "text-xs font-bold text-content leading-[18px] line-clamp-1 break-all cursor-default", children: t.name }) }),
236
- /* @__PURE__ */ e(D, { side: "top", variant: "tertiary", children: t.name })
219
+ /* @__PURE__ */ c(w, { children: [
220
+ /* @__PURE__ */ e(D, { asChild: !0, children: /* @__PURE__ */ e("span", { className: "text-xs font-bold text-content leading-[18px] line-clamp-1 break-all cursor-default", children: t.name }) }),
221
+ /* @__PURE__ */ e(z, { side: "top", variant: "tertiary", children: t.name })
237
222
  ] }),
238
- /* @__PURE__ */ e("span", { className: "text-xs font-medium text-secondary-foreground leading-[16px]", children: g(t.size) })
223
+ /* @__PURE__ */ e("span", { className: "text-xs font-medium text-secondary-foreground leading-[16px]", children: x(t.size) })
239
224
  ] })
240
225
  ] }),
241
226
  /* @__PURE__ */ c("div", { className: "flex items-center gap-4 shrink-0", children: [
242
- r && /* @__PURE__ */ c(U, { children: [
243
- /* @__PURE__ */ e(C, { asChild: !0, children: /* @__PURE__ */ e(
227
+ o && /* @__PURE__ */ c(w, { children: [
228
+ /* @__PURE__ */ e(D, { asChild: !0, children: /* @__PURE__ */ e(
244
229
  "button",
245
230
  {
246
231
  onClick: (n) => {
247
- n.stopPropagation(), r();
232
+ n.stopPropagation(), o();
248
233
  },
249
234
  className: "flex items-center justify-center text-content-tertiary hover:text-content transition-colors",
250
235
  type: "button",
251
236
  "aria-label": "View file data",
252
- children: /* @__PURE__ */ e(I, { size: 18 })
237
+ children: /* @__PURE__ */ e(M, { size: 18 })
253
238
  }
254
239
  ) }),
255
- /* @__PURE__ */ e(D, { side: "top", variant: "tertiary", children: "View" })
240
+ /* @__PURE__ */ e(z, { side: "top", variant: "tertiary", children: "View" })
256
241
  ] }),
257
- !h && /* @__PURE__ */ c(U, { children: [
258
- /* @__PURE__ */ e(C, { asChild: !0, children: /* @__PURE__ */ e(
242
+ !f && /* @__PURE__ */ c(w, { children: [
243
+ /* @__PURE__ */ e(D, { asChild: !0, children: /* @__PURE__ */ e(
259
244
  "button",
260
245
  {
261
- onClick: x,
246
+ onClick: u,
262
247
  className: "flex items-center justify-center text-content-tertiary hover:text-destructive transition-colors",
263
248
  type: "button",
264
- "aria-label": p("aria.removeFile"),
265
- children: /* @__PURE__ */ e(L, { size: 14 })
249
+ "aria-label": d("aria.removeFile"),
250
+ children: /* @__PURE__ */ e(B, { size: 14 })
266
251
  }
267
252
  ) }),
268
- /* @__PURE__ */ e(D, { side: "top", variant: "tertiary", children: p("aria.removeFile") })
253
+ /* @__PURE__ */ e(z, { side: "top", variant: "tertiary", children: d("aria.removeFile") })
269
254
  ] })
270
255
  ] })
271
256
  ] })
272
257
  }
273
258
  );
274
259
  }
275
- );
276
- q.displayName = "FileUploadItem";
277
- const J = o.forwardRef(({ className: a, children: t, ...l }, r) => /* @__PURE__ */ e(
278
- "div",
279
- {
280
- ref: r,
281
- className: f("flex items-center justify-end gap-4 mt-auto", a),
282
- ...l,
283
- children: t
284
- }
285
- ));
286
- J.displayName = "FileUploadFooter";
260
+ ), ne = j("file-upload", {
261
+ part: "footer",
262
+ displayName: "FileUploadFooter",
263
+ className: "flex items-center justify-end gap-4 mt-auto"
264
+ });
287
265
  export {
288
- S as FileUpload,
289
- G as FileUploadClose,
290
- P as FileUploadContent,
291
- $ as FileUploadDescription,
292
- K as FileUploadDropZone,
293
- J as FileUploadFooter,
294
- H as FileUploadHeader,
295
- q as FileUploadItem,
296
- V as FileUploadList,
297
- Z as FileUploadTitle
266
+ J as FileUpload,
267
+ te as FileUploadClose,
268
+ Q as FileUploadContent,
269
+ ee as FileUploadDescription,
270
+ ae as FileUploadDropZone,
271
+ ne as FileUploadFooter,
272
+ W as FileUploadHeader,
273
+ oe as FileUploadItem,
274
+ le as FileUploadList,
275
+ X as FileUploadTitle
298
276
  };
@@ -1,68 +1,68 @@
1
1
  import { jsx as e, jsxs as n } from "react/jsx-runtime";
2
- import * as p from "react";
3
- import { Cross as R } from "impact-nova-icons";
4
- import { Info3d as B, Success3d as F, Warning3d as H, Delete3d as S } from "../../ui/local-raster-icons/rasterIcons.js";
2
+ import "react";
3
+ import { Cross as B } from "impact-nova-icons";
4
+ import { Info3d as F, Success3d as H, Warning3d as S, Delete3d as V } from "../../ui/local-raster-icons/rasterIcons.js";
5
+ import { createComponent as p } from "../../../lib/primitives/create-component.js";
5
6
  import { cn as r } from "../../../lib/utils.js";
6
7
  import { useImpactNovaI18n as u } from "../../../i18n/use-impact-nova-i18n.js";
7
- import { Tooltip as V, TooltipTrigger as W, TooltipContent as q } from "../../feedback/tooltip/tooltip.js";
8
+ import { Tooltip as W, TooltipTrigger as q, TooltipContent as A } from "../../feedback/tooltip/tooltip.js";
8
9
  import { Button as f } from "../../primitives/button/button.js";
9
- import { Dialog as A, DialogContent as E, DialogHeader as G, DialogTitle as J, DialogDescription as K, DialogFooter as M } from "../../feedback/dialog/dialog.js";
10
- const Q = p.forwardRef(({ className: i, ...s }, a) => {
10
+ import { Dialog as E, DialogContent as G, DialogHeader as J, DialogTitle as K, DialogDescription as M, DialogFooter as Q } from "../../feedback/dialog/dialog.js";
11
+ const re = p("PromptClose", ({ className: i, ...s }, l) => {
11
12
  const { t: c } = u();
12
- return /* @__PURE__ */ n(V, { children: [
13
- /* @__PURE__ */ e(W, { asChild: !0, children: /* @__PURE__ */ e(
13
+ return /* @__PURE__ */ n(W, { children: [
14
+ /* @__PURE__ */ e(q, { asChild: !0, children: /* @__PURE__ */ e(
14
15
  "button",
15
16
  {
16
- ref: a,
17
+ ref: l,
17
18
  className: r("text-content-tertiary hover:text-content transition-colors", i),
18
19
  type: "button",
19
20
  "aria-label": c("aria.close"),
20
21
  ...s,
21
- children: /* @__PURE__ */ e(R, { size: 16 })
22
+ children: /* @__PURE__ */ e(B, { size: 16 })
22
23
  }
23
24
  ) }),
24
- /* @__PURE__ */ e(q, { side: "top", variant: "tertiary", children: c("aria.close") })
25
+ /* @__PURE__ */ e(A, { side: "top", variant: "tertiary", children: c("aria.close") })
25
26
  ] });
26
- });
27
- Q.displayName = "PromptClose";
28
- const U = p.forwardRef(
27
+ }), oe = p(
28
+ "Prompt",
29
29
  ({
30
30
  open: i,
31
31
  onOpenChange: s,
32
- title: a,
32
+ title: l,
33
33
  description: c,
34
34
  confirmLabel: x,
35
35
  cancelLabel: b,
36
36
  onConfirm: h,
37
37
  onCancel: g,
38
- confirmVariant: N,
39
- cancelVariant: y = "secondary",
38
+ confirmVariant: C,
39
+ cancelVariant: N = "secondary",
40
40
  variant: t = "default",
41
- showClose: w = !0,
42
- preventOutsideClick: C = !1,
43
- footer: l,
41
+ showClose: y = !0,
42
+ preventOutsideClick: v = !1,
43
+ footer: a,
44
44
  children: d,
45
- className: v,
45
+ className: w,
46
46
  ...D
47
47
  }, j) => {
48
- const { t: m } = u(), z = b ?? m("prompt.cancel"), P = x ?? m("prompt.confirm"), T = () => {
48
+ const { t: m } = u(), k = b ?? m("prompt.cancel"), z = x ?? m("prompt.confirm"), P = () => {
49
49
  h?.(), s?.(!1);
50
- }, k = () => {
50
+ }, T = () => {
51
51
  g?.(), s?.(!1);
52
- }, o = t !== "default", I = N || (t === "destructive" ? "destructive" : "default");
53
- return /* @__PURE__ */ e(A, { open: i, onOpenChange: s, ...D, children: /* @__PURE__ */ n(
54
- E,
52
+ }, o = t !== "default", I = C || (t === "destructive" ? "destructive" : "default");
53
+ return /* @__PURE__ */ e(E, { open: i, onOpenChange: s, ...D, children: /* @__PURE__ */ n(
54
+ G,
55
55
  {
56
56
  ref: j,
57
57
  "aria-describedby": void 0,
58
- hideClose: !w,
58
+ hideClose: !y,
59
59
  onPointerDownOutside: (L) => {
60
- C && L.preventDefault();
60
+ v && L.preventDefault();
61
61
  },
62
62
  className: r(
63
63
  "max-w-[400px] gap-0",
64
64
  o && "flex flex-col items-center p-6 pt-6 text-center",
65
- v
65
+ w
66
66
  ),
67
67
  "data-component": "prompt",
68
68
  "data-variant": t,
@@ -75,32 +75,32 @@ const U = p.forwardRef(
75
75
  t === "info" && "bg-brand-tint text-brand",
76
76
  t === "success" && "bg-feedback-success-surface text-success",
77
77
  t === "warning" && "bg-feedback-warning-surface text-content",
78
- t === "destructive" && "bg-prompt-error-bg text-destructive"
78
+ t === "destructive" && "bg-feedback-error-surface text-destructive"
79
79
  ),
80
80
  children: [
81
- t === "info" && /* @__PURE__ */ e(B, { size: 24 }),
82
- t === "success" && /* @__PURE__ */ e(F, { size: 24 }),
83
- t === "warning" && /* @__PURE__ */ e(H, { size: 24 }),
84
- t === "destructive" && /* @__PURE__ */ e(S, { size: 24 })
81
+ t === "info" && /* @__PURE__ */ e(F, { size: 24 }),
82
+ t === "success" && /* @__PURE__ */ e(H, { size: 24 }),
83
+ t === "warning" && /* @__PURE__ */ e(S, { size: 24 }),
84
+ t === "destructive" && /* @__PURE__ */ e(V, { size: 24 })
85
85
  ]
86
86
  }
87
87
  ),
88
88
  /* @__PURE__ */ n(
89
- G,
89
+ J,
90
90
  {
91
91
  className: r(o && "space-y-2 items-center bg-canvas-elevated border-none"),
92
92
  children: [
93
93
  /* @__PURE__ */ e(
94
- J,
94
+ K,
95
95
  {
96
96
  className: r(
97
97
  o && "text-[18px] font-extrabold text-content"
98
98
  ),
99
- children: a
99
+ children: l
100
100
  }
101
101
  ),
102
102
  c && /* @__PURE__ */ e(
103
- K,
103
+ M,
104
104
  {
105
105
  className: r(o && "text-sm text-content-tertiary"),
106
106
  children: c
@@ -110,8 +110,8 @@ const U = p.forwardRef(
110
110
  }
111
111
  ),
112
112
  d && /* @__PURE__ */ e("div", { className: r("w-full py-2", o && "text-center"), children: d }),
113
- l ? /* @__PURE__ */ e("div", { className: "w-full", children: l }) : /* @__PURE__ */ n(
114
- M,
113
+ a ? /* @__PURE__ */ e("div", { className: "w-full", children: a }) : /* @__PURE__ */ n(
114
+ Q,
115
115
  {
116
116
  className: r(
117
117
  o && "mt-6 flex flex-row justify-center gap-3 w-full sm:justify-center px-0 pb-0"
@@ -120,19 +120,19 @@ const U = p.forwardRef(
120
120
  /* @__PURE__ */ e(
121
121
  f,
122
122
  {
123
- variant: y,
124
- onClick: k,
123
+ variant: N,
124
+ onClick: T,
125
125
  className: r(o && "h-10 px-6"),
126
- children: z
126
+ children: k
127
127
  }
128
128
  ),
129
129
  /* @__PURE__ */ e(
130
130
  f,
131
131
  {
132
132
  variant: I,
133
- onClick: T,
133
+ onClick: P,
134
134
  className: r(o && "h-10 px-6"),
135
- children: P
135
+ children: z
136
136
  }
137
137
  )
138
138
  ]
@@ -143,8 +143,7 @@ const U = p.forwardRef(
143
143
  ) });
144
144
  }
145
145
  );
146
- U.displayName = "Prompt";
147
146
  export {
148
- U as Prompt,
149
- Q as PromptClose
147
+ oe as Prompt,
148
+ re as PromptClose
150
149
  };