@konstructio/ui 0.1.2-alpha.47 → 0.1.2-alpha.48

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 (29) hide show
  1. package/dist/assets/icons/index.js +7 -0
  2. package/dist/components/Badge/Badge.js +36 -35
  3. package/dist/components/Counter/Counter.js +23 -23
  4. package/dist/components/ImageUpload/ImageUpload.js +8 -8
  5. package/dist/components/Input/Input.js +185 -118
  6. package/dist/components/Input/Input.variants.js +16 -20
  7. package/dist/components/MultiSelectDropdown/MultiSelectDropdown.js +19 -19
  8. package/dist/components/MultiSelectDropdown/MultiSelectDropdown.variants.js +11 -15
  9. package/dist/components/MultiSelectDropdown/components/Item/Item.js +18 -26
  10. package/dist/components/MultiSelectDropdown/components/Item/Item.variants.js +8 -8
  11. package/dist/components/MultiSelectDropdown/components/List/List.js +12 -19
  12. package/dist/components/MultiSelectDropdown/components/List/List.variants.js +6 -4
  13. package/dist/components/MultiSelectDropdown/components/Wrapper/Wrapper.js +79 -65
  14. package/dist/components/PhoneNumberInput/components/Wrapper.js +43 -36
  15. package/dist/components/RadioGroup/RadioGroup.js +9 -9
  16. package/dist/components/Select/components/Wrapper.js +1 -1
  17. package/dist/components/TimePicker/components/Wrapper/Wrapper.js +1 -1
  18. package/dist/components/Typography/Typography.variants.js +6 -1
  19. package/dist/components/VirtualizedTable/VirtualizedTable.js +14 -14
  20. package/dist/components/VirtualizedTable/components/Actions/Actions.js +20 -16
  21. package/dist/components/VirtualizedTable/components/DotPaginate/DotPaginate.js +60 -60
  22. package/dist/components/VirtualizedTable/components/DropdownPaginate/DropdownPaginate.js +8 -8
  23. package/dist/components/VirtualizedTable/components/FormPaginate/FormPaginate.js +32 -21
  24. package/dist/components/VirtualizedTable/components/Header/Header.js +15 -15
  25. package/dist/components/VirtualizedTable/components/Pagination/Pagination.js +8 -8
  26. package/dist/index.d.ts +10 -9
  27. package/dist/package.json +4 -4
  28. package/dist/styles.css +1 -1
  29. package/package.json +4 -4
@@ -1,207 +1,274 @@
1
- import { jsxs as m, jsx as s } from "react/jsx-runtime";
2
- import l, { forwardRef as x, useId as _, useRef as I, useState as W } from "react";
3
- import { cn as u } from "../../utils/index.js";
1
+ import { jsxs as h, jsx as s } from "react/jsx-runtime";
2
+ import p, { forwardRef as y, useId as I, useRef as L, useState as W } from "react";
3
+ import { cn as i } from "../../utils/index.js";
4
4
  import { inputVariants as $ } from "./Input.variants.js";
5
- import { SearchIcon as L } from "../../assets/icons/components/Search.js";
6
- import { Warning as T } from "../../assets/icons/components/Warning.js";
7
- import { P as i } from "../../index-BOE_3f_Z.js";
8
- function h() {
9
- return h = Object.assign || function(t) {
10
- for (var n = 1; n < arguments.length; n++) {
11
- var a = arguments[n];
12
- for (var e in a)
13
- Object.prototype.hasOwnProperty.call(a, e) && (t[e] = a[e]);
5
+ import { Typography as u } from "../Typography/Typography.js";
6
+ import { SearchIcon as T } from "../../assets/icons/components/Search.js";
7
+ import { Warning as S } from "../../assets/icons/components/Warning.js";
8
+ import { P as l } from "../../index-BOE_3f_Z.js";
9
+ function g() {
10
+ return g = Object.assign || function(t) {
11
+ for (var r = 1; r < arguments.length; r++) {
12
+ var n = arguments[r];
13
+ for (var e in n)
14
+ Object.prototype.hasOwnProperty.call(n, e) && (t[e] = n[e]);
14
15
  }
15
16
  return t;
16
- }, h.apply(this, arguments);
17
+ }, g.apply(this, arguments);
17
18
  }
18
- function S(t, n) {
19
+ function C(t, r) {
19
20
  if (t == null) return {};
20
- var a = C(t, n), e, r;
21
+ var n = M(t, r), e, o;
21
22
  if (Object.getOwnPropertySymbols) {
22
- var o = Object.getOwnPropertySymbols(t);
23
- for (r = 0; r < o.length; r++)
24
- e = o[r], !(n.indexOf(e) >= 0) && Object.prototype.propertyIsEnumerable.call(t, e) && (a[e] = t[e]);
23
+ var a = Object.getOwnPropertySymbols(t);
24
+ for (o = 0; o < a.length; o++)
25
+ e = a[o], !(r.indexOf(e) >= 0) && Object.prototype.propertyIsEnumerable.call(t, e) && (n[e] = t[e]);
25
26
  }
26
- return a;
27
+ return n;
27
28
  }
28
- function C(t, n) {
29
+ function M(t, r) {
29
30
  if (t == null) return {};
30
- var a = {}, e = Object.keys(t), r, o;
31
- for (o = 0; o < e.length; o++)
32
- r = e[o], !(n.indexOf(r) >= 0) && (a[r] = t[r]);
33
- return a;
31
+ var n = {}, e = Object.keys(t), o, a;
32
+ for (a = 0; a < e.length; a++)
33
+ o = e[a], !(r.indexOf(o) >= 0) && (n[o] = t[o]);
34
+ return n;
34
35
  }
35
- var v = x(function(t, n) {
36
- var a = t.color, e = a === void 0 ? "currentColor" : a, r = t.size, o = r === void 0 ? 24 : r, c = S(t, ["color", "size"]);
37
- return /* @__PURE__ */ l.createElement("svg", h({
38
- ref: n,
36
+ var x = y(function(t, r) {
37
+ var n = t.color, e = n === void 0 ? "currentColor" : n, o = t.size, a = o === void 0 ? 24 : o, c = C(t, ["color", "size"]);
38
+ return /* @__PURE__ */ p.createElement("svg", g({
39
+ ref: r,
39
40
  xmlns: "http://www.w3.org/2000/svg",
40
- width: o,
41
- height: o,
41
+ width: a,
42
+ height: a,
42
43
  viewBox: "0 0 24 24",
43
44
  fill: "none",
44
45
  stroke: e,
45
46
  strokeWidth: "2",
46
47
  strokeLinecap: "round",
47
48
  strokeLinejoin: "round"
48
- }, c), /* @__PURE__ */ l.createElement("path", {
49
+ }, c), /* @__PURE__ */ p.createElement("path", {
49
50
  d: "M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24"
50
- }), /* @__PURE__ */ l.createElement("line", {
51
+ }), /* @__PURE__ */ p.createElement("line", {
51
52
  x1: "1",
52
53
  y1: "1",
53
54
  x2: "23",
54
55
  y2: "23"
55
56
  }));
56
57
  });
57
- v.propTypes = {
58
- color: i.string,
59
- size: i.oneOfType([i.string, i.number])
58
+ x.propTypes = {
59
+ color: l.string,
60
+ size: l.oneOfType([l.string, l.number])
60
61
  };
61
- v.displayName = "EyeOff";
62
- function g() {
63
- return g = Object.assign || function(t) {
64
- for (var n = 1; n < arguments.length; n++) {
65
- var a = arguments[n];
66
- for (var e in a)
67
- Object.prototype.hasOwnProperty.call(a, e) && (t[e] = a[e]);
62
+ x.displayName = "EyeOff";
63
+ function v() {
64
+ return v = Object.assign || function(t) {
65
+ for (var r = 1; r < arguments.length; r++) {
66
+ var n = arguments[r];
67
+ for (var e in n)
68
+ Object.prototype.hasOwnProperty.call(n, e) && (t[e] = n[e]);
68
69
  }
69
70
  return t;
70
- }, g.apply(this, arguments);
71
+ }, v.apply(this, arguments);
71
72
  }
72
- function M(t, n) {
73
+ function R(t, r) {
73
74
  if (t == null) return {};
74
- var a = R(t, n), e, r;
75
+ var n = A(t, r), e, o;
75
76
  if (Object.getOwnPropertySymbols) {
76
- var o = Object.getOwnPropertySymbols(t);
77
- for (r = 0; r < o.length; r++)
78
- e = o[r], !(n.indexOf(e) >= 0) && Object.prototype.propertyIsEnumerable.call(t, e) && (a[e] = t[e]);
77
+ var a = Object.getOwnPropertySymbols(t);
78
+ for (o = 0; o < a.length; o++)
79
+ e = a[o], !(r.indexOf(e) >= 0) && Object.prototype.propertyIsEnumerable.call(t, e) && (n[e] = t[e]);
79
80
  }
80
- return a;
81
+ return n;
81
82
  }
82
- function R(t, n) {
83
+ function A(t, r) {
83
84
  if (t == null) return {};
84
- var a = {}, e = Object.keys(t), r, o;
85
- for (o = 0; o < e.length; o++)
86
- r = e[o], !(n.indexOf(r) >= 0) && (a[r] = t[r]);
87
- return a;
85
+ var n = {}, e = Object.keys(t), o, a;
86
+ for (a = 0; a < e.length; a++)
87
+ o = e[a], !(r.indexOf(o) >= 0) && (n[o] = t[o]);
88
+ return n;
88
89
  }
89
- var y = x(function(t, n) {
90
- var a = t.color, e = a === void 0 ? "currentColor" : a, r = t.size, o = r === void 0 ? 24 : r, c = M(t, ["color", "size"]);
91
- return /* @__PURE__ */ l.createElement("svg", g({
92
- ref: n,
90
+ var w = y(function(t, r) {
91
+ var n = t.color, e = n === void 0 ? "currentColor" : n, o = t.size, a = o === void 0 ? 24 : o, c = R(t, ["color", "size"]);
92
+ return /* @__PURE__ */ p.createElement("svg", v({
93
+ ref: r,
93
94
  xmlns: "http://www.w3.org/2000/svg",
94
- width: o,
95
- height: o,
95
+ width: a,
96
+ height: a,
96
97
  viewBox: "0 0 24 24",
97
98
  fill: "none",
98
99
  stroke: e,
99
100
  strokeWidth: "2",
100
101
  strokeLinecap: "round",
101
102
  strokeLinejoin: "round"
102
- }, c), /* @__PURE__ */ l.createElement("path", {
103
+ }, c), /* @__PURE__ */ p.createElement("path", {
103
104
  d: "M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"
104
- }), /* @__PURE__ */ l.createElement("circle", {
105
+ }), /* @__PURE__ */ p.createElement("circle", {
105
106
  cx: "12",
106
107
  cy: "12",
107
108
  r: "3"
108
109
  }));
109
110
  });
110
- y.propTypes = {
111
- color: i.string,
112
- size: i.oneOfType([i.string, i.number])
111
+ w.propTypes = {
112
+ color: l.string,
113
+ size: l.oneOfType([l.string, l.number])
113
114
  };
114
- y.displayName = "Eye";
115
- const A = x(
115
+ w.displayName = "Eye";
116
+ const B = y(
116
117
  ({
117
118
  className: t,
118
- error: n,
119
- isRequired: a = !1,
120
- isSearch: e = !1,
121
- label: r,
122
- labelClassName: o,
123
- name: c,
124
- theme: O,
119
+ error: r,
120
+ helperText: n,
121
+ helperTextClassName: e,
122
+ isRequired: o = !1,
123
+ isSearch: a = !1,
124
+ label: c,
125
+ labelClassName: O,
126
+ name: j,
127
+ theme: k,
125
128
  type: f = "text",
126
- helperText: w,
127
- helperTextClassName: j,
128
- ...k
129
- }, N) => {
130
- const b = _(), P = I(f === "password"), [d, E] = W(() => f !== "password"), p = typeof n == "string" && n.length >= 0, z = d ? y : v;
131
- return /* @__PURE__ */ m("div", { className: "flex flex-col gap-2 w-full relative", "data-theme": O, children: [
132
- r ? /* @__PURE__ */ m(
133
- "label",
129
+ ...N
130
+ }, P) => {
131
+ const b = I(), E = L(f === "password"), [d, z] = W(() => f !== "password"), m = typeof r == "string" && r.length >= 0, _ = d ? w : x;
132
+ return /* @__PURE__ */ h("div", { className: "flex flex-col gap-2 w-full relative", "data-theme": k, children: [
133
+ c ? /* @__PURE__ */ h(
134
+ u,
134
135
  {
136
+ component: "label",
137
+ variant: "labelLarge",
135
138
  htmlFor: b,
136
- className: u(
137
- "cursor-pointer text-slate-500 flex gap-1 text-sm font-medium dark:text-slate-50 kubefirst-dark:text-slate-50",
138
- o
139
+ className: i(
140
+ "cursor-pointer",
141
+ "flex",
142
+ "gap-1",
143
+ "text-sm",
144
+ "font-medium",
145
+ O
139
146
  ),
140
147
  children: [
141
- r,
148
+ c,
142
149
  " ",
143
- a && /* @__PURE__ */ s("span", { className: "text-red-600 text-xs mt-0.5", children: "*" })
150
+ o && /* @__PURE__ */ s(
151
+ u,
152
+ {
153
+ component: "span",
154
+ className: i(
155
+ "text-red-600",
156
+ "dark:text-red-500",
157
+ "text-xs",
158
+ "mt-0.5"
159
+ ),
160
+ children: "*"
161
+ }
162
+ )
144
163
  ]
145
164
  }
146
165
  ) : null,
147
- /* @__PURE__ */ m("div", { className: "relative", children: [
148
- e ? /* @__PURE__ */ s(
166
+ /* @__PURE__ */ h("div", { className: "relative", children: [
167
+ a ? /* @__PURE__ */ s(
149
168
  "i",
150
169
  {
151
- className: u(
152
- "absolute left-2.5 top-1/2 -translate-y-[50%] text-slate-400",
170
+ className: i(
171
+ "absolute",
172
+ "left-2.5",
173
+ "top-1/2",
174
+ "-translate-y-[50%]",
175
+ "text-slate-400",
176
+ "dark:text-metal-400",
153
177
  {
154
- "text-red-700": p
178
+ "text-red-700": m
155
179
  }
156
180
  ),
157
- children: /* @__PURE__ */ s(L, { className: "w-5 h-5" })
181
+ children: /* @__PURE__ */ s(T, { className: "w-5 h-5" })
158
182
  }
159
183
  ) : null,
160
184
  /* @__PURE__ */ s(
161
185
  "input",
162
186
  {
163
- id: r ? b : void 0,
164
- ref: N,
165
- name: c,
166
- type: d ? P.current ? "text" : f : "password",
167
- "data-error": p,
168
- className: u(
187
+ id: c ? b : void 0,
188
+ ref: P,
189
+ name: j,
190
+ type: d ? E.current ? "text" : f : "password",
191
+ "data-error": m,
192
+ className: i(
169
193
  $({
170
194
  className: t,
171
- variant: p ? "error" : "default"
195
+ variant: m ? "error" : "default"
172
196
  }),
173
197
  {
174
- "pr-10": f === "password" || p,
175
- "pl-8": e
198
+ "pr-10": f === "password" || m,
199
+ "pl-8": a
176
200
  }
177
201
  ),
178
- ...k
202
+ ...N
179
203
  }
180
204
  ),
181
- p ? /* @__PURE__ */ s("i", { className: "absolute right-3 text-red-700 dark:text-red-500 top-1/2 -translate-y-[50%]", children: /* @__PURE__ */ s(T, { className: "w-5 h-5" }) }) : null,
182
- f === "password" && !n ? /* @__PURE__ */ s("i", { className: "absolute right-3 text-slate-400 top-1/2 -translate-y-[50%]", children: /* @__PURE__ */ s(
183
- z,
205
+ m ? /* @__PURE__ */ s(
206
+ "i",
184
207
  {
185
- className: "w-5 h-5 cursor-pointer",
186
- onClick: () => E(!d)
208
+ className: i(
209
+ "-translate-y-[50%]",
210
+ "absolute",
211
+ "right-3",
212
+ "text-red-700",
213
+ "top-1/2",
214
+ "dark:text-red-500"
215
+ ),
216
+ children: /* @__PURE__ */ s(S, { className: "w-5 h-5" })
187
217
  }
188
- ) }) : null
218
+ ) : null,
219
+ f === "password" && !r ? /* @__PURE__ */ s(
220
+ "i",
221
+ {
222
+ className: i(
223
+ "-translate-y-[50%]",
224
+ "absolute",
225
+ "right-3",
226
+ "text-slate-400",
227
+ "top-1/2"
228
+ ),
229
+ children: /* @__PURE__ */ s(
230
+ _,
231
+ {
232
+ className: "w-5 h-5 cursor-pointer",
233
+ onClick: () => z(!d)
234
+ }
235
+ )
236
+ }
237
+ ) : null
189
238
  ] }),
190
- n ? /* @__PURE__ */ s("span", { className: "text-xs text-red-700 dark:text-red-500", children: n }) : null,
191
- !n && w ? /* @__PURE__ */ s(
192
- "span",
239
+ r ? /* @__PURE__ */ s(
240
+ u,
241
+ {
242
+ component: "span",
243
+ className: i(
244
+ "text-xs",
245
+ "tracking-normal",
246
+ "text-red-700",
247
+ "dark:text-red-400"
248
+ ),
249
+ children: r
250
+ }
251
+ ) : null,
252
+ !r && n ? /* @__PURE__ */ s(
253
+ u,
193
254
  {
194
- className: u(
195
- "text-xs text-slate-600 dark:text-slate-200 kubefirst-dark:text-slate-200",
196
- j
255
+ component: "span",
256
+ variant: "body1",
257
+ className: i(
258
+ "text-xs",
259
+ "text-slate-600",
260
+ "dark:text-slate-200",
261
+ "select-none",
262
+ "tracking-normal",
263
+ e
197
264
  ),
198
- children: w
265
+ children: n
199
266
  }
200
267
  ) : null
201
268
  ] });
202
269
  }
203
270
  );
204
- A.displayName = "KonstructInput";
271
+ B.displayName = "KonstructInput";
205
272
  export {
206
- A as Input
273
+ B as Input
207
274
  };
@@ -1,41 +1,38 @@
1
- import { c as r } from "../../index-D29mdTf5.js";
2
- const a = r(
1
+ import { c as e } from "../../index-D29mdTf5.js";
2
+ const r = e(
3
3
  [
4
4
  "bg-white",
5
- "border-gray-300",
6
5
  "border",
7
- "disabled:bg-gray-50",
6
+ "border-gray-300",
7
+ "caret-text-slate-800",
8
8
  "disabled:cursor-not-allowed",
9
9
  "disabled:text-slate-500",
10
10
  "flex",
11
+ "focus-visible:border-transparent",
11
12
  "focus-visible:outline-none",
12
13
  "focus-visible:ring-1",
13
14
  "h-10",
14
- "placeholder:text-zinc-400",
15
- "dark:placeholder:text-metal-300",
16
15
  "px-2.5",
17
16
  "py-2",
18
17
  "rounded",
19
18
  "text-slate-800",
20
19
  "text-sm",
21
- "w-full",
22
20
  "transition-all",
23
- "focus-visible:border-transparent",
21
+ "w-full",
22
+ "disabled:bg-gray-50",
23
+ "placeholder:text-slate-400",
24
24
  "data-[error=false]:dark:focus:ring-aurora-500",
25
25
  "data-[error=false]:focus:ring-aurora-500",
26
- "data-[error=false]:kubefirst:focus:ring-kubefirst-primary",
27
26
  "dark:bg-metal-800",
28
27
  "dark:border-metal-700",
29
- "dark:disabled:bg-slate-900",
28
+ "dark:caret-text-metal-50",
29
+ "dark:disabled:bg-metal-900",
30
+ "dark:disabled:placeholder:text-metal-400",
31
+ "dark:disabled:text-metal-400",
30
32
  "dark:disabled:text-slate-400",
33
+ "dark:placeholder:text-metal-300",
31
34
  "dark:text-slate-50",
32
- "dark:text-white",
33
- "kubefirst-dark:bg-slate-800",
34
- "kubefirst-dark:border-slate-600",
35
- "kubefirst-dark:disabled:bg-slate-900",
36
- "kubefirst-dark:disabled:text-slate-400",
37
- "kubefirst-dark:text-slate-50",
38
- "kubefirst-dark:text-white"
35
+ "dark:text-white"
39
36
  ],
40
37
  {
41
38
  variants: {
@@ -46,8 +43,7 @@ const a = r(
46
43
  "border-red-600",
47
44
  "focus-visible:border-red-600",
48
45
  "focus-visible:ring-transparent",
49
- "dark:border-red-500",
50
- "kubefirst-dark:border-red-500"
46
+ "dark:border-red-500"
51
47
  ]
52
48
  }
53
49
  },
@@ -57,5 +53,5 @@ const a = r(
57
53
  }
58
54
  );
59
55
  export {
60
- a as inputVariants
56
+ r as inputVariants
61
57
  };
@@ -1,34 +1,34 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
2
  import { forwardRef as n } from "react";
3
- import { MultiSelectDropdownProvider as a } from "./contexts/MultiSelectDropdown.provider.js";
4
- import { Wrapper as s } from "./components/Wrapper/Wrapper.js";
5
- const u = n(
3
+ import { MultiSelectDropdownProvider as s } from "./contexts/MultiSelectDropdown.provider.js";
4
+ import { Wrapper as u } from "./components/Wrapper/Wrapper.js";
5
+ const a = n(
6
6
  ({
7
- options: t,
7
+ isLoading: t,
8
8
  multiselect: e,
9
- value: p,
10
- onChange: i,
11
- onBlur: l,
12
9
  name: o,
13
- isLoading: d,
14
- noOptionsText: m,
10
+ noOptionsText: p,
11
+ options: i,
12
+ value: l,
13
+ onChange: d,
14
+ onBlur: m,
15
15
  ...f
16
16
  }, c) => /* @__PURE__ */ r(
17
- a,
17
+ s,
18
18
  {
19
- defaultOptions: t,
19
+ defaultOptions: i,
20
20
  multiselect: e,
21
- value: p,
22
- onChange: i,
23
- onBlur: l,
21
+ value: l,
22
+ onChange: d,
23
+ onBlur: m,
24
24
  name: o,
25
- isLoading: d,
26
- noOptionsText: m,
27
- children: /* @__PURE__ */ r(s, { ref: c, ...f, name: o })
25
+ isLoading: t,
26
+ noOptionsText: p,
27
+ children: /* @__PURE__ */ r(u, { ref: c, name: o, ...f })
28
28
  }
29
29
  )
30
30
  );
31
- u.displayName = "MultiSelectDropdown";
31
+ a.displayName = "KonstructMultiSelectDropdown";
32
32
  export {
33
- u as MultiSelectDropdown
33
+ a as MultiSelectDropdown
34
34
  };
@@ -1,18 +1,12 @@
1
- import { c as t } from "../../index-D29mdTf5.js";
2
- const r = t([
1
+ import { c as r } from "../../index-D29mdTf5.js";
2
+ const t = r([
3
3
  "flex",
4
4
  "flex-col",
5
5
  "w-full",
6
6
  "relative",
7
- "text-slate-500",
8
- "mb-1",
9
- "cursor-pointer",
10
- "text-sm",
11
- "leading-5",
12
- "tracking-[0.1px]",
13
- "dark:text-slate-50"
14
- ]), a = t(["cursor-pointer", "mb-1"]), o = t([
15
- "h-9",
7
+ "cursor-pointer"
8
+ ]), o = r(["cursor-pointer", "mb-1", "select-none"]), a = r([
9
+ "min-h-9",
16
10
  "border",
17
11
  "cursor-pointer",
18
12
  "duration-250",
@@ -25,10 +19,12 @@ const r = t([
25
19
  "rounded-md",
26
20
  "transition-all",
27
21
  "w-full",
28
- "border-gray-200"
22
+ "border-gray-200",
23
+ "dark:border-metal-700",
24
+ "dark:bg-metal-800"
29
25
  ]);
30
26
  export {
31
- a as labelVariants,
32
- o as multiSelectDropdownVariants,
33
- r as wrapperVariants
27
+ o as labelVariants,
28
+ a as multiSelectDropdownVariants,
29
+ t as wrapperVariants
34
30
  };
@@ -1,38 +1,30 @@
1
- import { jsxs as m, jsx as t } from "react/jsx-runtime";
2
- import { cn as i } from "../../../../utils/index.js";
3
- import { wrapperVariants as s } from "./Item.variants.js";
4
- import { useMultiSelectDropdown as c } from "../../contexts/MultiSelectDropdown.hook.js";
5
- import { Typography as p } from "../../../Typography/Typography.js";
6
- import { Tag as n } from "../../../Tag/Tag.js";
7
- const u = ({
1
+ import { jsxs as i, jsx as e } from "react/jsx-runtime";
2
+ import { Badge as l } from "../../../Badge/Badge.js";
3
+ import { Typography as n } from "../../../Typography/Typography.js";
4
+ import { cn as c } from "../../../../utils/index.js";
5
+ import { itemVariants as p } from "./Item.variants.js";
6
+ import { useMultiSelectDropdown as s } from "../../contexts/MultiSelectDropdown.hook.js";
7
+ const x = ({
8
8
  option: r,
9
- theme: e,
10
- isSelected: a,
11
- className: o
9
+ theme: o,
10
+ isSelected: t,
11
+ className: m
12
12
  }) => {
13
- const { onSelectOption: l } = c();
14
- return /* @__PURE__ */ m(
13
+ const { onSelectOption: a } = s();
14
+ return /* @__PURE__ */ i(
15
15
  "li",
16
16
  {
17
17
  role: "option",
18
- "data-theme": e,
19
- className: i(s({ isSelected: a }), o),
20
- onClick: () => l(r),
18
+ "data-theme": o,
19
+ className: c(p({ isSelected: t }), m),
20
+ onClick: () => a(r),
21
21
  children: [
22
- /* @__PURE__ */ t(p, { variant: "body2", className: "text-slate-800", children: r.label }),
23
- r.tagLabel && /* @__PURE__ */ t(
24
- n,
25
- {
26
- id: r.id,
27
- label: r.tagLabel,
28
- color: r.tagColor,
29
- isSelected: a
30
- }
31
- )
22
+ /* @__PURE__ */ e(n, { variant: "body2", children: r.label }),
23
+ r.badge && /* @__PURE__ */ e(l, { label: r.badge })
32
24
  ]
33
25
  }
34
26
  );
35
27
  };
36
28
  export {
37
- u as Item
29
+ x as Item
38
30
  };
@@ -1,5 +1,5 @@
1
1
  import { c as e } from "../../../../index-D29mdTf5.js";
2
- const r = e(
2
+ const t = e(
3
3
  [
4
4
  "cursor-pointer",
5
5
  "py-1.5",
@@ -7,13 +7,13 @@ const r = e(
7
7
  "last:pb-2",
8
8
  "first:pt-2",
9
9
  "h-full",
10
- "hover:bg-gray-50",
11
- "focus:bg-gray-50",
12
- "dark:hover:bg-slate-700",
13
- "dark:focus:bg-slate-700",
14
10
  "flex",
15
11
  "items-center",
16
- "gap-4"
12
+ "gap-2",
13
+ "hover:bg-gray-50",
14
+ "focus:bg-gray-50",
15
+ "dark:hover:bg-metal-700",
16
+ "dark:focus:bg-metal-700"
17
17
  ],
18
18
  {
19
19
  variants: {
@@ -25,7 +25,7 @@ const r = e(
25
25
  compoundVariants: [
26
26
  {
27
27
  isSelected: !0,
28
- class: ["bg-slate-50"]
28
+ class: ["bg-slate-50", "dark:bg-metal-700"]
29
29
  }
30
30
  ],
31
31
  defaultVariants: {
@@ -34,5 +34,5 @@ const r = e(
34
34
  }
35
35
  );
36
36
  export {
37
- r as wrapperVariants
37
+ t as itemVariants
38
38
  };