@konstructio/ui 0.1.2-alpha.55 → 0.1.2-alpha.57

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 (56) hide show
  1. package/dist/assets/icons/components/BookOpen.d.ts +3 -0
  2. package/dist/assets/icons/components/BookOpen.js +32 -0
  3. package/dist/assets/icons/components/DollarSign.d.ts +3 -0
  4. package/dist/assets/icons/components/DollarSign.js +30 -0
  5. package/dist/assets/icons/components/LightBulb.d.ts +3 -0
  6. package/dist/assets/icons/components/LightBulb.js +43 -0
  7. package/dist/assets/icons/components/index.d.ts +3 -0
  8. package/dist/assets/icons/components/index.js +114 -108
  9. package/dist/assets/icons/index.js +114 -108
  10. package/dist/components/Autocomplete/Autocomplete.js +41 -40
  11. package/dist/components/Autocomplete/Autocomplete.types.d.ts +2 -0
  12. package/dist/components/ButtonGroup/ButtonGroup.js +111 -91
  13. package/dist/components/ButtonGroup/ButtonGroup.types.d.ts +2 -0
  14. package/dist/components/ButtonGroup/ButtonGroup.variants.d.ts +5 -4
  15. package/dist/components/ButtonGroup/ButtonGroup.variants.js +33 -25
  16. package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.js +97 -246
  17. package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.types.d.ts +2 -2
  18. package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.variants.d.ts +2 -4
  19. package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.variants.js +22 -20
  20. package/dist/components/Checkbox/Checkbox.js +152 -144
  21. package/dist/components/Checkbox/Checkbox.types.d.ts +2 -0
  22. package/dist/components/Counter/Counter.js +43 -42
  23. package/dist/components/Counter/Counter.types.d.ts +2 -0
  24. package/dist/components/DateRangePicker/DateRangePicker.js +94 -93
  25. package/dist/components/DateRangePicker/DateRangePicker.types.d.ts +2 -0
  26. package/dist/components/DateRangePicker/components/CalendarPanel/components/IndependentModeCalendar/IndependentModeCalendar.js +1 -1
  27. package/dist/components/DateRangePicker/components/CalendarPanel/components/TogetherModeCalendar/TogetherModeCalendar.js +1 -1
  28. package/dist/components/ImageUpload/ImageUpload.d.ts +1 -1
  29. package/dist/components/ImageUpload/ImageUpload.js +51 -50
  30. package/dist/components/ImageUpload/ImageUpload.types.d.ts +2 -0
  31. package/dist/components/Input/Input.js +72 -58
  32. package/dist/components/Input/Input.types.d.ts +4 -0
  33. package/dist/components/MultiSelectDropdown/MultiSelectDropdown.types.d.ts +2 -0
  34. package/dist/components/MultiSelectDropdown/components/Wrapper/Wrapper.js +40 -39
  35. package/dist/components/PhoneNumberInput/PhoneNumberInput.types.d.ts +2 -0
  36. package/dist/components/PhoneNumberInput/components/Wrapper.js +164 -163
  37. package/dist/components/PhoneNumberInput/contexts/phone-number.provider.js +172 -116
  38. package/dist/components/Range/Range.js +26 -24
  39. package/dist/components/Range/Range.types.d.ts +2 -0
  40. package/dist/components/Select/Select.types.d.ts +1 -0
  41. package/dist/components/Select/Select.variants.js +2 -1
  42. package/dist/components/Select/components/Wrapper.js +74 -73
  43. package/dist/components/Slider/Slider.js +30 -20
  44. package/dist/components/Slider/Slider.types.d.ts +2 -0
  45. package/dist/components/Switch/Switch.js +89 -87
  46. package/dist/components/Switch/Switch.types.d.ts +2 -0
  47. package/dist/components/TagSelect/TagSelect.types.d.ts +2 -0
  48. package/dist/components/TagSelect/components/Wrapper/Wrapper.js +47 -46
  49. package/dist/components/TextArea/TextArea.js +27 -26
  50. package/dist/components/TextArea/TextArea.types.d.ts +2 -0
  51. package/dist/icons.d.ts +1 -1
  52. package/dist/icons.js +114 -108
  53. package/dist/package.json +17 -17
  54. package/dist/{proxy-i19-YB39.js → proxy-BhEKW5n7.js} +1903 -1757
  55. package/dist/styles.css +1 -1
  56. package/package.json +17 -17
@@ -32,6 +32,8 @@ export interface CounterProps extends VariantProps<typeof counterVariants> {
32
32
  isRequired?: boolean;
33
33
  /** Label displayed above the counter */
34
34
  label?: string;
35
+ /** Additional CSS classes for the label wrapper */
36
+ labelWrapperClassName?: string;
35
37
  /** Maximum allowed value */
36
38
  max?: number;
37
39
  /** Minimum allowed value */
@@ -1,84 +1,85 @@
1
- import { jsx as r, jsxs as a } from "react/jsx-runtime";
2
- import { cn as t } from "../../utils/index.js";
1
+ import { jsx as e, jsxs as t } from "react/jsx-runtime";
2
+ import { cn as a } from "../../utils/index.js";
3
3
  import { Typography as i } from "../Typography/Typography.js";
4
- import { rightPanelVariants as O, dateRangePickerVariants as Q } from "./DateRangePicker.variants.js";
5
- import { DateRangePickerProvider as S } from "./contexts/date-range-picker.provider.js";
6
- import { PresetPanel as U } from "./components/PresetPanel/PresetPanel.js";
7
- import { DateTimeInputs as W } from "./components/DateTimeInputs/DateTimeInputs.js";
8
- import { CalendarPanel as X } from "./components/CalendarPanel/CalendarPanel.js";
9
- const Y = ({
4
+ import { rightPanelVariants as Q, dateRangePickerVariants as S } from "./DateRangePicker.variants.js";
5
+ import { DateRangePickerProvider as U } from "./contexts/date-range-picker.provider.js";
6
+ import { PresetPanel as W } from "./components/PresetPanel/PresetPanel.js";
7
+ import { DateTimeInputs as X } from "./components/DateTimeInputs/DateTimeInputs.js";
8
+ import { CalendarPanel as Y } from "./components/CalendarPanel/CalendarPanel.js";
9
+ const Z = ({
10
10
  animationDuration: o = 500,
11
11
  className: m,
12
12
  defaultPreset: l = "custom",
13
13
  defaultRange: c,
14
- defaultTime: p,
15
- disabled: s = !1,
14
+ defaultTime: s,
15
+ disabled: p = !1,
16
16
  isRequired: d,
17
17
  label: n,
18
- name: f,
19
- showTime: g = !0,
20
- theme: P,
18
+ labelWrapperClassName: f,
19
+ name: g,
20
+ showTime: P = !0,
21
+ theme: h,
21
22
  timeFormat: x = "24",
22
- blockedDays: h,
23
- blockedMonths: u,
24
- minDate: k,
25
- maxDate: v,
23
+ blockedDays: u,
24
+ blockedMonths: k,
25
+ minDate: v,
26
+ maxDate: N,
26
27
  hideDisabledNavigation: D,
27
- showOutsideDays: N,
28
- navigationMode: R = "independent",
28
+ showOutsideDays: R,
29
+ navigationMode: y = "independent",
29
30
  // CalendarPanel props
30
- ariaLabelCalendar: y,
31
- ariaLabelPrevMonth: T,
32
- ariaLabelNextMonth: j,
33
- ariaLabelPrevMonthStart: I,
34
- ariaLabelNextMonthStart: V,
35
- ariaLabelPrevMonthEnd: b,
36
- ariaLabelNextMonthEnd: C,
31
+ ariaLabelCalendar: T,
32
+ ariaLabelPrevMonth: j,
33
+ ariaLabelNextMonth: I,
34
+ ariaLabelPrevMonthStart: V,
35
+ ariaLabelNextMonthStart: b,
36
+ ariaLabelPrevMonthEnd: C,
37
+ ariaLabelNextMonthEnd: K,
37
38
  // DateTimeInputs props
38
- labelStartDate: K,
39
- labelEndDate: L,
40
- labelTime: q,
41
- ariaLabelStartDate: w,
42
- ariaLabelEndDate: z,
43
- errorInvalidDate: A,
44
- errorDateNotAvailable: B,
39
+ labelStartDate: L,
40
+ labelEndDate: q,
41
+ labelTime: w,
42
+ ariaLabelStartDate: z,
43
+ ariaLabelEndDate: A,
44
+ errorInvalidDate: B,
45
+ errorDateNotAvailable: E,
45
46
  // PresetPanel props
46
- showPresets: E = !0,
47
- labelTimePeriod: F,
48
- ariaLabelTimePeriod: G,
49
- presetLabels: H,
47
+ showPresets: F = !0,
48
+ labelTimePeriod: G,
49
+ ariaLabelTimePeriod: H,
50
+ presetLabels: J,
50
51
  // Customizable class names
51
- classNames: e,
52
+ classNames: r,
52
53
  // Callbacks
53
- onRangeChange: J,
54
- onDateChange: M
55
- }) => /* @__PURE__ */ r(
56
- S,
54
+ onRangeChange: M,
55
+ onDateChange: O
56
+ }) => /* @__PURE__ */ e(
57
+ U,
57
58
  {
58
59
  defaultRange: c,
59
- defaultTime: p,
60
+ defaultTime: s,
60
61
  defaultPreset: l,
61
62
  timeFormat: x,
62
- showTime: g,
63
- name: f,
64
- disabled: s,
63
+ showTime: P,
64
+ name: g,
65
+ disabled: p,
65
66
  animationDuration: o,
66
- blockedDays: h,
67
- blockedMonths: u,
68
- minDate: k,
69
- maxDate: v,
67
+ blockedDays: u,
68
+ blockedMonths: k,
69
+ minDate: v,
70
+ maxDate: N,
70
71
  hideDisabledNavigation: D,
71
- showOutsideDays: N,
72
- navigationMode: R,
73
- onRangeChange: J,
74
- onDateChange: M,
75
- children: /* @__PURE__ */ a("div", { className: "flex flex-col gap-2", "data-theme": P, children: [
76
- n ? /* @__PURE__ */ a(
72
+ showOutsideDays: R,
73
+ navigationMode: y,
74
+ onRangeChange: M,
75
+ onDateChange: O,
76
+ children: /* @__PURE__ */ t("div", { className: "flex flex-col gap-2", "data-theme": h, children: [
77
+ n ? /* @__PURE__ */ e("div", { className: a(f), children: /* @__PURE__ */ t(
77
78
  i,
78
79
  {
79
80
  component: "label",
80
81
  variant: "labelLarge",
81
- className: t(
82
+ className: a(
82
83
  "cursor-pointer",
83
84
  "flex",
84
85
  "gap-1",
@@ -87,11 +88,11 @@ const Y = ({
87
88
  ),
88
89
  children: [
89
90
  n,
90
- d && /* @__PURE__ */ r(
91
+ d && /* @__PURE__ */ e(
91
92
  i,
92
93
  {
93
94
  component: "span",
94
- className: t(
95
+ className: a(
95
96
  "text-red-600",
96
97
  "dark:text-red-500",
97
98
  "text-xs",
@@ -102,52 +103,52 @@ const Y = ({
102
103
  )
103
104
  ]
104
105
  }
105
- ) : null,
106
- /* @__PURE__ */ a(
106
+ ) }) : null,
107
+ /* @__PURE__ */ t(
107
108
  "div",
108
109
  {
109
- className: t(
110
- Q({ className: m }),
110
+ className: a(
111
+ S({ className: m }),
111
112
  "gap-4",
112
- e?.container
113
+ r?.container
113
114
  ),
114
115
  role: "group",
115
116
  "aria-label": n || "Date range picker",
116
117
  children: [
117
- E && /* @__PURE__ */ r(
118
- U,
118
+ F && /* @__PURE__ */ e(
119
+ W,
119
120
  {
120
- labelTimePeriod: F,
121
- ariaLabelTimePeriod: G,
122
- presetLabels: H,
123
- classNames: e?.presetPanel
121
+ labelTimePeriod: G,
122
+ ariaLabelTimePeriod: H,
123
+ presetLabels: J,
124
+ classNames: r?.presetPanel
124
125
  }
125
126
  ),
126
- /* @__PURE__ */ a("div", { className: t(O(), e?.rightPanel), children: [
127
- /* @__PURE__ */ r(
128
- W,
127
+ /* @__PURE__ */ t("div", { className: a(Q(), r?.rightPanel), children: [
128
+ /* @__PURE__ */ e(
129
+ X,
129
130
  {
130
- labelStartDate: K,
131
- labelEndDate: L,
132
- labelTime: q,
133
- ariaLabelStartDate: w,
134
- ariaLabelEndDate: z,
135
- errorInvalidDate: A,
136
- errorDateNotAvailable: B,
137
- classNames: e?.dateTimeInputs
131
+ labelStartDate: L,
132
+ labelEndDate: q,
133
+ labelTime: w,
134
+ ariaLabelStartDate: z,
135
+ ariaLabelEndDate: A,
136
+ errorInvalidDate: B,
137
+ errorDateNotAvailable: E,
138
+ classNames: r?.dateTimeInputs
138
139
  }
139
140
  ),
140
- /* @__PURE__ */ r(
141
- X,
141
+ /* @__PURE__ */ e(
142
+ Y,
142
143
  {
143
- ariaLabelCalendar: y,
144
- ariaLabelPrevMonth: T,
145
- ariaLabelNextMonth: j,
146
- ariaLabelPrevMonthStart: I,
147
- ariaLabelNextMonthStart: V,
148
- ariaLabelPrevMonthEnd: b,
149
- ariaLabelNextMonthEnd: C,
150
- classNames: e?.calendarPanel
144
+ ariaLabelCalendar: T,
145
+ ariaLabelPrevMonth: j,
146
+ ariaLabelNextMonth: I,
147
+ ariaLabelPrevMonthStart: V,
148
+ ariaLabelNextMonthStart: b,
149
+ ariaLabelPrevMonthEnd: C,
150
+ ariaLabelNextMonthEnd: K,
151
+ classNames: r?.calendarPanel
151
152
  }
152
153
  )
153
154
  ] })
@@ -157,7 +158,7 @@ const Y = ({
157
158
  ] })
158
159
  }
159
160
  );
160
- Y.displayName = "KonstructDateRangePicker";
161
+ Z.displayName = "KonstructDateRangePicker";
161
162
  export {
162
- Y as DateRangePicker
163
+ Z as DateRangePicker
163
164
  };
@@ -41,6 +41,8 @@ export type DateRangePickerProps = VariantProps<typeof dateRangePickerVariants>
41
41
  name?: string;
42
42
  /** Label for the component */
43
43
  label?: string;
44
+ /** Additional CSS classes for the label wrapper */
45
+ labelWrapperClassName?: string;
44
46
  /** Whether the field is required */
45
47
  isRequired?: boolean;
46
48
  /** Animation duration in milliseconds for month transitions (default: 400) */
@@ -7,7 +7,7 @@ import { CalendarDivider as tt } from "../CalendarDivider/CalendarDivider.js";
7
7
  import { CalendarMonth as d } from "../CalendarMonth/CalendarMonth.js";
8
8
  import { NavigationButton as g } from "../NavigationButton/NavigationButton.js";
9
9
  import { useIndependentCarousel as nt } from "../../hooks/useIndependentCarousel.js";
10
- import { m as et } from "../../../../../../proxy-i19-YB39.js";
10
+ import { m as et } from "../../../../../../proxy-BhEKW5n7.js";
11
11
  const at = ({
12
12
  className: b,
13
13
  calendarWidth: x = 550,
@@ -6,7 +6,7 @@ import { CalendarDivider as F } from "../CalendarDivider/CalendarDivider.js";
6
6
  import { CalendarMonth as G } from "../CalendarMonth/CalendarMonth.js";
7
7
  import { NavigationButton as m } from "../NavigationButton/NavigationButton.js";
8
8
  import { useTogetherCarousel as H } from "../../hooks/useTogetherCarousel.js";
9
- import { m as R } from "../../../../../../proxy-i19-YB39.js";
9
+ import { m as R } from "../../../../../../proxy-BhEKW5n7.js";
10
10
  const S = ({
11
11
  className: s,
12
12
  calendarWidth: h = 550,
@@ -19,7 +19,7 @@ import { ImageUploadProps } from './ImageUpload.types';
19
19
  * @see {@link https://konstructio.github.io/konstruct-ui/?path=/docs/components-imageupload--docs Storybook}
20
20
  */
21
21
  declare const ImageUpload: {
22
- ({ className, error, fileName, fileSize, fileUrl, helperText, isRequired, label, labelClassName, name, onChange, onRemove, status, theme, uploadButtonText, accept, maxSize, }: ImageUploadProps): import("react/jsx-runtime").JSX.Element;
22
+ ({ className, error, fileName, fileSize, fileUrl, helperText, isRequired, label, labelClassName, labelWrapperClassName, name, onChange, onRemove, status, theme, uploadButtonText, accept, maxSize, }: ImageUploadProps): import("react/jsx-runtime").JSX.Element;
23
23
  displayName: string;
24
24
  };
25
25
  export { ImageUpload };
@@ -1,14 +1,14 @@
1
1
  import { jsxs as l, jsx as e, Fragment as j } from "react/jsx-runtime";
2
- import { useId as ee, useRef as D, useState as g, useEffect as te } from "react";
2
+ import { useId as te, useRef as D, useState as g, useEffect as ae } from "react";
3
3
  import { Button as F } from "../Button/Button.js";
4
- import { cn as m } from "../../utils/index.js";
5
- import { labelVariants as ae, inputFieldVariants as re, inputContainerVariants as le, helperTextVariants as ie, imageUploadVariants as se } from "./ImageUpload.variants.js";
6
- import { LoaderIcon as ne } from "../../assets/icons/components/Loader.js";
4
+ import { cn as c } from "../../utils/index.js";
5
+ import { labelVariants as re, inputFieldVariants as le, inputContainerVariants as ie, helperTextVariants as se, imageUploadVariants as ne } from "./ImageUpload.variants.js";
6
+ import { LoaderIcon as ce } from "../../assets/icons/components/Loader.js";
7
7
  import { PhotoLibraryIcon as oe } from "../../assets/icons/components/PhotoLibrary.js";
8
- import { WarningIcon as ce } from "../../assets/icons/components/Warning.js";
8
+ import { WarningIcon as de } from "../../assets/icons/components/Warning.js";
9
9
  import { X as P } from "../../x-B9bYxG31.js";
10
10
  var t = /* @__PURE__ */ ((s) => (s.Default = "default", s.Uploading = "uploading", s.Complete = "complete", s.Error = "error", s))(t || {});
11
- const de = ({
11
+ const me = ({
12
12
  className: s,
13
13
  error: b,
14
14
  fileName: T,
@@ -18,37 +18,38 @@ const de = ({
18
18
  isRequired: S = !1,
19
19
  label: p = "Item logo",
20
20
  labelClassName: L,
21
- name: A,
21
+ labelWrapperClassName: A,
22
+ name: H,
22
23
  onChange: N,
23
- onRemove: H,
24
+ onRemove: J,
24
25
  status: k = t.Default,
25
26
  theme: u,
26
- uploadButtonText: J = "Upload logo",
27
+ uploadButtonText: K = "Upload logo",
27
28
  accept: M = "image/svg+xml,image/png,image/jpeg,image/jpg",
28
- maxSize: K = 5 * 1024 * 1024
29
+ maxSize: W = 5 * 1024 * 1024
29
30
  }) => {
30
- const U = ee(), f = D(null), n = D(null), [W, o] = g(k), [$, B] = g(E), [X, C] = g(T), [q, G] = g(z);
31
- te(() => () => {
31
+ const U = te(), f = D(null), n = D(null), [$, o] = g(k), [X, B] = g(E), [q, C] = g(T), [O, G] = g(z);
32
+ ae(() => () => {
32
33
  n.current && clearTimeout(n.current);
33
34
  }, []);
34
- const a = k !== t.Default ? k : W, v = E ?? $, c = T ?? X, h = z ?? q, x = !!b || a === t.Error, O = (i) => {
35
+ const a = k !== t.Default ? k : $, v = E ?? X, d = T ?? q, h = z ?? O, x = !!b || a === t.Error, Q = (i) => {
35
36
  const r = i.target.files?.[0];
36
37
  if (!r) return;
37
- if (!M.split(",").map((d) => d.trim()).some((d) => {
38
- if (d.includes("*")) {
39
- const _ = d.split("/")[0];
40
- return r.type.startsWith(_);
38
+ if (!M.split(",").map((m) => m.trim()).some((m) => {
39
+ if (m.includes("*")) {
40
+ const ee = m.split("/")[0];
41
+ return r.type.startsWith(ee);
41
42
  }
42
- return r.type === d;
43
+ return r.type === m;
43
44
  })) {
44
45
  o(t.Error), N?.(i);
45
46
  return;
46
47
  }
47
- if (r.size > K) {
48
+ if (r.size > W) {
48
49
  o(t.Error), N?.(i);
49
50
  return;
50
51
  }
51
- o(t.Uploading), C(r.name), G(Y(r.size));
52
+ o(t.Uploading), C(r.name), G(Z(r.size));
52
53
  const y = new FileReader();
53
54
  y.onloadend = () => {
54
55
  B(y.result), n.current = setTimeout(() => {
@@ -56,31 +57,31 @@ const de = ({
56
57
  }, 500);
57
58
  }, y.readAsDataURL(r), N?.(i);
58
59
  }, I = () => {
59
- n.current && (clearTimeout(n.current), n.current = null), B(void 0), C(void 0), G(void 0), o(t.Default), f.current && (f.current.value = ""), H?.();
60
- }, Q = () => {
60
+ n.current && (clearTimeout(n.current), n.current = null), B(void 0), C(void 0), G(void 0), o(t.Default), f.current && (f.current.value = ""), J?.();
61
+ }, Y = () => {
61
62
  f.current?.click();
62
- }, Y = (i) => {
63
+ }, Z = (i) => {
63
64
  if (i === 0) return "0 Bytes";
64
65
  const r = 1024, V = ["Bytes", "KB", "MB", "GB"], w = Math.floor(Math.log(i) / Math.log(r));
65
66
  return `${parseFloat((i / Math.pow(r, w)).toFixed(2))}${V[w]}`;
66
- }, Z = b || (x ? "Invalid file format. Accepted file type is SVG, PNG, JPEG. Max file size is 5MB." : R || "Logo should be 32 x 32 pixels with transparent background (larger images will be downscaled proportionally to fit). Accepted file type is SVG, PNG, JPEG. Max file size is 5MB.");
67
+ }, _ = b || (x ? "Invalid file format. Accepted file type is SVG, PNG, JPEG. Max file size is 5MB." : R || "Logo should be 32 x 32 pixels with transparent background (larger images will be downscaled proportionally to fit). Accepted file type is SVG, PNG, JPEG. Max file size is 5MB.");
67
68
  return /* @__PURE__ */ l(
68
69
  "div",
69
70
  {
70
- className: m(
71
- se({
71
+ className: c(
72
+ ne({
72
73
  status: a,
73
74
  className: s
74
75
  })
75
76
  ),
76
77
  "data-theme": u,
77
78
  children: [
78
- p && /* @__PURE__ */ l(
79
+ p && /* @__PURE__ */ e("div", { className: c(A), children: /* @__PURE__ */ l(
79
80
  "label",
80
81
  {
81
82
  htmlFor: U,
82
- className: m(
83
- ae({
83
+ className: c(
84
+ re({
84
85
  className: L
85
86
  }),
86
87
  "cursor-pointer"
@@ -90,12 +91,12 @@ const de = ({
90
91
  S && /* @__PURE__ */ e("span", { className: "text-red-600 dark:text-red-500 text-xs mt-0.5", children: "*" })
91
92
  ]
92
93
  }
93
- ),
94
+ ) }),
94
95
  /* @__PURE__ */ l(
95
96
  "div",
96
97
  {
97
- className: m(
98
- le({
98
+ className: c(
99
+ ie({
99
100
  status: a
100
101
  })
101
102
  ),
@@ -103,8 +104,8 @@ const de = ({
103
104
  /* @__PURE__ */ l(
104
105
  "div",
105
106
  {
106
- className: m(
107
- re({
107
+ className: c(
108
+ le({
108
109
  status: a
109
110
  }),
110
111
  {
@@ -115,14 +116,14 @@ const de = ({
115
116
  children: [
116
117
  a === t.Uploading && /* @__PURE__ */ l(j, { children: [
117
118
  /* @__PURE__ */ e(
118
- ne,
119
+ ce,
119
120
  {
120
121
  size: 20,
121
122
  className: "shrink-0 animate-spin text-metal-400"
122
123
  }
123
124
  ),
124
- c && /* @__PURE__ */ l("div", { className: "flex flex-col items-start min-w-0 flex-1", children: [
125
- /* @__PURE__ */ e("p", { className: "text-sm leading-5 truncate w-full text-slate-800 dark:text-metal-50", children: c }),
125
+ d && /* @__PURE__ */ l("div", { className: "flex flex-col items-start min-w-0 flex-1", children: [
126
+ /* @__PURE__ */ e("p", { className: "text-sm leading-5 truncate w-full text-slate-800 dark:text-metal-50", children: d }),
126
127
  h && /* @__PURE__ */ e("p", { className: "text-xs leading-4 text-slate-600 dark:text-metal-300 tracking-[0.15px]", children: h })
127
128
  ] })
128
129
  ] }),
@@ -131,17 +132,17 @@ const de = ({
131
132
  "img",
132
133
  {
133
134
  src: v,
134
- alt: c || "Uploaded image",
135
+ alt: d || "Uploaded image",
135
136
  className: "w-full h-full object-contain"
136
137
  }
137
138
  ) }),
138
- c && /* @__PURE__ */ l("div", { className: "flex flex-col items-start min-w-0 flex-1", children: [
139
- /* @__PURE__ */ e("p", { className: "text-sm leading-5 truncate w-full text-slate-800 dark:text-slate-50 kubefirst-dark:text-slate-50", children: c }),
139
+ d && /* @__PURE__ */ l("div", { className: "flex flex-col items-start min-w-0 flex-1", children: [
140
+ /* @__PURE__ */ e("p", { className: "text-sm leading-5 truncate w-full text-slate-800 dark:text-slate-50 kubefirst-dark:text-slate-50", children: d }),
140
141
  h && /* @__PURE__ */ e("p", { className: "text-xs leading-4 text-slate-600 dark:text-slate-400 kubefirst-dark:text-slate-400 tracking-[0.15px]", children: h })
141
142
  ] })
142
143
  ] }),
143
144
  (a === t.Default || a === t.Error && !v) && /* @__PURE__ */ e("div", { className: "w-8 h-8 shrink-0 flex items-center justify-center", children: /* @__PURE__ */ e(oe, { className: "w-8 h-8 text-slate-400 dark:text-slate-500 kubefirst-dark:text-slate-500" }) }),
144
- x && /* @__PURE__ */ e("div", { className: "shrink-0", children: /* @__PURE__ */ e(ce, { className: "w-5 h-5 text-red-700 dark:text-red-500 kubefirst-dark:text-red-500" }) })
145
+ x && /* @__PURE__ */ e("div", { className: "shrink-0", children: /* @__PURE__ */ e(de, { className: "w-5 h-5 text-red-700 dark:text-red-500 kubefirst-dark:text-red-500" }) })
145
146
  ]
146
147
  }
147
148
  ),
@@ -149,10 +150,10 @@ const de = ({
149
150
  F,
150
151
  {
151
152
  variant: "secondary",
152
- onClick: Q,
153
+ onClick: Y,
153
154
  theme: u,
154
155
  className: "h-10 px-4 py-2 shrink-0",
155
- children: J
156
+ children: K
156
157
  }
157
158
  ),
158
159
  a === t.Uploading && /* @__PURE__ */ e(
@@ -188,12 +189,12 @@ const de = ({
188
189
  /* @__PURE__ */ e("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ e(
189
190
  "p",
190
191
  {
191
- className: m(
192
- ie({
192
+ className: c(
193
+ se({
193
194
  status: a
194
195
  })
195
196
  ),
196
- children: Z
197
+ children: _
197
198
  }
198
199
  ) }),
199
200
  (a === t.Default || a === t.Error) && /* @__PURE__ */ e("div", { className: "shrink-0 w-29" }),
@@ -205,9 +206,9 @@ const de = ({
205
206
  ref: f,
206
207
  id: U,
207
208
  type: "file",
208
- name: A,
209
+ name: H,
209
210
  accept: M,
210
- onChange: O,
211
+ onChange: Q,
211
212
  className: "hidden",
212
213
  "aria-label": typeof p == "string" ? p : "File upload"
213
214
  }
@@ -216,7 +217,7 @@ const de = ({
216
217
  }
217
218
  );
218
219
  };
219
- de.displayName = "KonstructImageUpload";
220
+ me.displayName = "KonstructImageUpload";
220
221
  export {
221
- de as ImageUpload
222
+ me as ImageUpload
222
223
  };
@@ -48,6 +48,8 @@ export interface ImageUploadProps extends Omit<VariantProps<typeof imageUploadVa
48
48
  label?: string | ReactNode;
49
49
  /** Additional CSS classes for the label */
50
50
  labelClassName?: string;
51
+ /** Additional CSS classes for the label wrapper */
52
+ labelWrapperClassName?: string;
51
53
  /** Form field name */
52
54
  name?: string;
53
55
  /** Callback fired when a file is selected */