meticulous-ui 2.6.1 → 2.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
1
  import { jsxs as C, jsx as u } from "react/jsx-runtime";
2
- import { useState as $, useId as ie, useRef as v, useMemo as le, useEffect as h, useLayoutEffect as ae, useCallback as ue, createElement as fe } from "react";
2
+ import { useState as $, useId as le, useRef as v, useMemo as ae, useEffect as h, useLayoutEffect as ue, useCallback as fe, createElement as de } from "react";
3
3
  import E from "../../colors/grey.js";
4
- import de from "../MenuItem/MenuItem.js";
5
- import pe from "../../colors/index.js";
6
- import me from "../../colors/blue.js";
4
+ import pe from "../MenuItem/MenuItem.js";
5
+ import me from "../../colors/index.js";
6
+ import he from "../../colors/blue.js";
7
7
  import K from "../Spinner/Spinner.js";
8
- import { DropdownWrapper as he, Box as be, PWrapper as we, ChevronDownWrapper as xe, OptionWrapper as ge, SearchContainer as Ie, SearchIcon as ke, SearchInput as Se, OptionsList as Ce, LoadMoreSentinel as $e, SpinnerWrapper as ve } from "./styles.js";
9
- const ye = (n) => {
8
+ import { DropdownWrapper as be, Box as we, PWrapper as xe, ChevronDownWrapper as ge, OptionWrapper as Ie, SearchContainer as ke, SearchIcon as Se, SearchInput as Ce, OptionsList as $e, LoadMoreSentinel as ve, SpinnerWrapper as ye } from "./styles.js";
9
+ const Ee = (n) => {
10
10
  if (typeof n != "string") return n;
11
11
  if (n.endsWith("px")) return parseFloat(n);
12
12
  if (n.endsWith("rem")) {
@@ -14,7 +14,7 @@ const ye = (n) => {
14
14
  return O * s;
15
15
  }
16
16
  return parseFloat(n);
17
- }, Pe = ({
17
+ }, He = ({
18
18
  options: n,
19
19
  onChange: O,
20
20
  value: s,
@@ -29,12 +29,13 @@ const ye = (n) => {
29
29
  onLoadMore: c,
30
30
  hasMore: I = !1,
31
31
  isLoadingMore: f = !1,
32
- searchPh: R = "Search..."
32
+ searchPh: R = "Search...",
33
+ ...q
33
34
  }) => {
34
35
  var j;
35
- const [r, d] = $(!1), [q, W] = $(!1), [N, T] = $("bottom"), [k, A] = $(""), [i, p] = $(-1), y = ie(), m = v(null), S = v(null), D = v(null), B = v(null), G = v(!0), J = () => !w && !x && d((e) => !e), P = (e) => {
36
+ const [r, d] = $(!1), [N, W] = $(!1), [T, G] = $("bottom"), [k, A] = $(""), [i, p] = $(-1), y = le(), m = v(null), S = v(null), D = v(null), B = v(null), J = v(!0), X = () => !w && !x && d((e) => !e), P = (e) => {
36
37
  e !== s && (O(e), d(!1));
37
- }, l = le(() => {
38
+ }, l = ae(() => {
38
39
  if (!g || !k.trim()) return n;
39
40
  const e = k.toLowerCase();
40
41
  return n.filter(({ label: t }) => t.toLowerCase().includes(e));
@@ -61,35 +62,35 @@ const ye = (n) => {
61
62
  }, [i, r]), h(() => {
62
63
  r && g && D.current && D.current.focus();
63
64
  }, [r, g]), h(() => {
64
- r || (G.current = !0);
65
+ r || (J.current = !0);
65
66
  }, [r]), h(() => {
66
67
  const e = (t) => {
67
68
  m.current && !m.current.contains(t.target) && d(!1);
68
69
  };
69
70
  return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
70
- }, []), ae(() => {
71
+ }, []), ue(() => {
71
72
  if (r && S.current && m.current) {
72
- const e = m.current.getBoundingClientRect(), t = window.innerHeight, o = ye(F), a = t - e.bottom;
73
- T(
73
+ const e = m.current.getBoundingClientRect(), t = window.innerHeight, o = Ee(F), a = t - e.bottom;
74
+ G(
74
75
  a < o + 8 && e.top > a ? "top" : "bottom"
75
76
  );
76
77
  }
77
78
  }, [r, F]);
78
- const X = (e) => {
79
+ const Y = (e) => {
79
80
  let t = e + 1;
80
81
  for (; t < l.length; ) {
81
82
  if (!l[t].disabled) return t;
82
83
  t++;
83
84
  }
84
85
  return e;
85
- }, Y = (e) => {
86
+ }, Z = (e) => {
86
87
  let t = e - 1;
87
88
  for (; t >= 0; ) {
88
89
  if (!l[t].disabled) return t;
89
90
  t--;
90
91
  }
91
92
  return e;
92
- }, Z = (e) => {
93
+ }, _ = (e) => {
93
94
  if (!(w || x)) {
94
95
  if (!r) {
95
96
  (e.key === " " || e.key === "Enter" || e.key === "ArrowDown" || e.key === "ArrowUp") && (e.preventDefault(), d(!0));
@@ -98,11 +99,11 @@ const ye = (n) => {
98
99
  switch (e.key) {
99
100
  case "ArrowDown":
100
101
  e.preventDefault();
101
- const t = X(i);
102
+ const t = Y(i);
102
103
  t === i && I && !f && (c == null || c()), p(t);
103
104
  break;
104
105
  case "ArrowUp":
105
- e.preventDefault(), p((a) => Y(a));
106
+ e.preventDefault(), p((a) => Z(a));
106
107
  break;
107
108
  case "Enter":
108
109
  e.preventDefault();
@@ -114,7 +115,7 @@ const ye = (n) => {
114
115
  break;
115
116
  }
116
117
  }
117
- }, H = ue(() => {
118
+ }, H = fe(() => {
118
119
  I && !f && c && c();
119
120
  }, [I, f, c]);
120
121
  h(() => {
@@ -135,44 +136,45 @@ const ye = (n) => {
135
136
  return t.observe(e), () => t.disconnect();
136
137
  }, [H, c, I, f]);
137
138
  const {
138
- m50: _,
139
- m100: L,
140
- m200: M,
141
- m500: ee
142
- } = pe[U] ?? me, te = (e, t) => () => !e && p(t), V = (e) => `${y}-opt-${e}`, re = ({ value: e, label: t, disabled: o }, a) => /* @__PURE__ */ fe(
143
- de,
139
+ m50: L,
140
+ m100: M,
141
+ m200: ee,
142
+ m500: te
143
+ } = me[U] ?? he, re = (e, t) => () => !e && p(t), V = (e) => `${y}-opt-${e}`, ne = ({ value: e, label: t, disabled: o }, a) => /* @__PURE__ */ de(
144
+ pe,
144
145
  {
145
146
  value: e,
146
147
  label: t,
147
148
  isDisabled: o,
148
149
  onSelect: P,
149
- onMouseEnter: te(o, a),
150
+ onMouseEnter: re(o, a),
150
151
  isSelected: e === s,
151
152
  isHighlighted: a === i,
152
153
  key: e,
153
154
  id: V(a),
154
155
  width: b,
155
- selectedColor: M,
156
- hoverColor: _,
157
- activeColor: L
156
+ selectedColor: ee,
157
+ hoverColor: L,
158
+ activeColor: M
158
159
  }
159
- ), ne = (e) => () => {
160
+ ), oe = (e) => () => {
160
161
  W(e);
161
- }, oe = (e) => {
162
+ }, se = (e) => {
162
163
  var t;
163
164
  W(!1), (t = m.current) != null && t.contains(e.relatedTarget) || d(!1);
164
- }, se = (e) => {
165
- A(e.target.value);
166
165
  }, ce = (e) => {
166
+ A(e.target.value);
167
+ }, ie = (e) => {
167
168
  e.stopPropagation();
168
169
  };
169
170
  return /* @__PURE__ */ C(
170
- he,
171
+ be,
171
172
  {
172
173
  ref: m,
173
174
  $width: b,
175
+ ...q,
174
176
  tabIndex: x || w ? -1 : 0,
175
- onKeyDown: Z,
177
+ onKeyDown: _,
176
178
  $isLoading: w,
177
179
  $isDisabled: x,
178
180
  role: "combobox",
@@ -181,32 +183,32 @@ const ye = (n) => {
181
183
  "aria-controls": y,
182
184
  "aria-disabled": x || void 0,
183
185
  "aria-activedescendant": i !== -1 ? V(i) : void 0,
184
- onFocus: ne(!0),
185
- onBlur: oe,
186
+ onFocus: oe(!0),
187
+ onBlur: se,
186
188
  children: [
187
189
  /* @__PURE__ */ C(
188
- be,
190
+ we,
189
191
  {
190
192
  $width: b,
191
- onClick: J,
193
+ onClick: X,
192
194
  $isOpen: r,
193
- $border: ee,
194
- $isFocused: q && !r,
195
+ $border: te,
196
+ $isFocused: N && !r,
195
197
  children: [
196
- /* @__PURE__ */ u(we, { $width: b, color: s ? E.m700 : E.m500, size: "1.2rem", children: s ? (j = n.find(({ value: e }) => s === e)) == null ? void 0 : j.label : Q }),
197
- /* @__PURE__ */ u(xe, { color: E.m500, size: 22, $isOpen: r, "aria-hidden": !0 })
198
+ /* @__PURE__ */ u(xe, { $width: b, color: s ? E.m700 : E.m500, size: "1.2rem", children: s ? (j = n.find(({ value: e }) => s === e)) == null ? void 0 : j.label : Q }),
199
+ /* @__PURE__ */ u(ge, { color: E.m500, size: 22, $isOpen: r, "aria-hidden": !0 })
198
200
  ]
199
201
  }
200
202
  ),
201
- /* @__PURE__ */ C(ge, { $isOpen: r, $width: b, $height: F, $top: N === "top", children: [
202
- g && /* @__PURE__ */ C(Ie, { onClick: ce, children: [
203
- /* @__PURE__ */ u(ke, { size: 20, color: E.m600, "aria-hidden": !0 }),
203
+ /* @__PURE__ */ C(Ie, { $isOpen: r, $width: b, $height: F, $top: T === "top", children: [
204
+ g && /* @__PURE__ */ C(ke, { onClick: ie, children: [
205
+ /* @__PURE__ */ u(Se, { size: 20, color: E.m600, "aria-hidden": !0 }),
204
206
  /* @__PURE__ */ u(
205
- Se,
207
+ Ce,
206
208
  {
207
209
  ref: D,
208
210
  value: k,
209
- onChange: se,
211
+ onChange: ce,
210
212
  placeholder: R,
211
213
  "aria-label": R,
212
214
  "aria-controls": y,
@@ -217,16 +219,16 @@ const ye = (n) => {
217
219
  }
218
220
  )
219
221
  ] }),
220
- /* @__PURE__ */ C(Ce, { ref: S, role: "listbox", id: y, tabIndex: -1, children: [
221
- l.map(re),
222
- c && /* @__PURE__ */ u($e, { ref: B, children: f && /* @__PURE__ */ u(K, { size: "small", color: z }) })
222
+ /* @__PURE__ */ C($e, { ref: S, role: "listbox", id: y, tabIndex: -1, children: [
223
+ l.map(ne),
224
+ c && /* @__PURE__ */ u(ve, { ref: B, children: f && /* @__PURE__ */ u(K, { size: "small", color: z }) })
223
225
  ] })
224
226
  ] }),
225
- w && /* @__PURE__ */ u(ve, { children: /* @__PURE__ */ u(K, { size: "small", color: z }) })
227
+ w && /* @__PURE__ */ u(ye, { children: /* @__PURE__ */ u(K, { size: "small", color: z }) })
226
228
  ]
227
229
  }
228
230
  );
229
231
  };
230
232
  export {
231
- Pe as default
233
+ He as default
232
234
  };
@@ -1,6 +1,6 @@
1
- import { jsx as s } from "react/jsx-runtime";
2
- import { GlassWrapper as a } from "./styles.js";
3
- const t = ({ border: r = "none", borderRadius: o = 0 }) => /* @__PURE__ */ s(a, { $border: r, $borderRadius: o });
1
+ import { jsx as a } from "react/jsx-runtime";
2
+ import { GlassWrapper as e } from "./styles.js";
3
+ const d = ({ border: r = "none", borderRadius: o = 0, ...s }) => /* @__PURE__ */ a(e, { $border: r, $borderRadius: o, ...s });
4
4
  export {
5
- t as default
5
+ d as default
6
6
  };
@@ -1,23 +1,24 @@
1
- import { jsxs as D, jsx as s } from "react/jsx-runtime";
2
- import { useState as $, useRef as g } from "react";
3
- import H from "../../../colors/grey.js";
4
- import P from "../../Typography/P/P.js";
5
- import j from "../../../colors/white.js";
1
+ import { jsxs as $, jsx as s } from "react/jsx-runtime";
2
+ import { useState as g, useRef as H } from "react";
3
+ import P from "../../../colors/grey.js";
4
+ import j from "../../Typography/P/P.js";
5
+ import z from "../../../colors/white.js";
6
6
  import m from "../../../colors/blue.js";
7
- import { Wrapper as z, CbInput as B, Box as C } from "./styles.js";
8
- import { getColor as E } from "./helpers.js";
9
- const G = ({
7
+ import { Wrapper as B, CbInput as C, Box as E } from "./styles.js";
8
+ import { getColor as F } from "./helpers.js";
9
+ const J = ({
10
10
  label: u,
11
11
  value: o,
12
12
  color: l = "blue",
13
- textColor: p = H.m700,
13
+ textColor: p = P.m700,
14
14
  disabled: c,
15
15
  onChange: t,
16
16
  tabIndex: d,
17
17
  innerShade: h,
18
- outerShade: k
18
+ outerShade: k,
19
+ ...y
19
20
  }) => {
20
- const [y, n] = $(!1), r = E(l), S = h ?? (r == null ? void 0 : r.m500) ?? m.m500, b = k ?? (r == null ? void 0 : r.m600) ?? m.m600, a = g(0), x = (e) => t(e.target.checked), w = (e) => {
21
+ const [S, n] = g(!1), r = F(l), b = h ?? (r == null ? void 0 : r.m500) ?? m.m500, x = k ?? (r == null ? void 0 : r.m600) ?? m.m600, a = H(0), w = (e) => t(e.target.checked), D = (e) => {
21
22
  if (e.key === "Enter" || e.key === " ") {
22
23
  const i = Date.now();
23
24
  if (i - a.current < 500) {
@@ -32,14 +33,14 @@ const G = ({
32
33
  }
33
34
  e.key === "Escape" && n(!1);
34
35
  }, f = (e) => () => n(e);
35
- return /* @__PURE__ */ D(z, { as: "label", $disabled: c, children: [
36
+ return /* @__PURE__ */ $(B, { as: "label", $disabled: c, ...y, children: [
36
37
  /* @__PURE__ */ s(
37
- B,
38
+ C,
38
39
  {
39
40
  type: "checkbox",
40
41
  checked: o,
41
- onChange: x,
42
- onKeyDown: w,
42
+ onChange: w,
43
+ onKeyDown: D,
43
44
  onFocus: f(!0),
44
45
  onBlur: f(!1),
45
46
  disabled: c,
@@ -47,20 +48,20 @@ const G = ({
47
48
  }
48
49
  ),
49
50
  /* @__PURE__ */ s(
50
- C,
51
+ E,
51
52
  {
52
53
  $value: o,
53
- $focused: y,
54
+ $focused: S,
54
55
  size: 6,
55
- color: j,
56
- $innerShade: S,
57
- $outerShade: b,
56
+ color: z,
57
+ $innerShade: b,
58
+ $outerShade: x,
58
59
  "aria-hidden": "true"
59
60
  }
60
61
  ),
61
- /* @__PURE__ */ s(P, { color: p, size: "1.2rem", children: u })
62
+ /* @__PURE__ */ s(j, { color: p, size: "1.2rem", children: u })
62
63
  ] });
63
64
  };
64
65
  export {
65
- G as default
66
+ J as default
66
67
  };
@@ -11,7 +11,7 @@ const c = e.div`
11
11
 
12
12
  ${({ $disabled: r }) => r && t`
13
13
  pointer-events: none;
14
- opacity: 0.7;
14
+ opacity: 0.4;
15
15
  `}
16
16
  `, d = e(i)`
17
17
  width: 1.2rem;
@@ -1,36 +1,37 @@
1
- import { jsx as o, jsxs as U } from "react/jsx-runtime";
1
+ import { jsx as o, jsxs as g } from "react/jsx-runtime";
2
2
  import { useRef as C } from "react";
3
- import { UploadBtnContainer as g, Wrapper as j, HiddenInput as M, PWrapper as W } from "./styles.js";
4
- import b from "../../../colors/white.js";
3
+ import { UploadBtnContainer as j, Wrapper as M, HiddenInput as W, PWrapper as b } from "./styles.js";
4
+ import B from "../../../colors/white.js";
5
5
  import x from "../../../colors/blue.js";
6
- import B from "../../../colors/grey.js";
7
- import F from "../../Icons/Link/Link.js";
8
- import H from "../../../colors/index.js";
9
- import P from "../../Ripple/Ripple.js";
10
- import { SIZE as Z, MEDIUM as q } from "./constants.js";
11
- const A = ({ theme: e, children: l }) => /* @__PURE__ */ o(P, { rippleColor: e.m100, children: l }), L = ({
6
+ import F from "../../../colors/grey.js";
7
+ import H from "../../Icons/Link/Link.js";
8
+ import P from "../../../colors/index.js";
9
+ import Z from "../../Ripple/Ripple.js";
10
+ import { SIZE as q, MEDIUM as A } from "./constants.js";
11
+ const G = ({ theme: e, children: l }) => /* @__PURE__ */ o(Z, { rippleColor: e.m100, children: l }), oo = ({
12
12
  label: e,
13
13
  labelColor: l,
14
14
  theme: p = x,
15
- size: D = q,
15
+ size: D = A,
16
16
  width: s,
17
17
  isLoading: t,
18
18
  disabled: r,
19
- prefixIcon: c = F,
19
+ prefixIcon: c = H,
20
20
  suffixIcon: m,
21
21
  type: I = "file",
22
22
  accept: R,
23
23
  isMultiple: k,
24
- onChange: z
24
+ onChange: z,
25
+ ...K
25
26
  }) => {
26
- const u = C(null), { m400: K, m500: v, m600: E } = H[p] ?? x, { height: h, width: a, font: n } = Z[D] || {}, f = l || ["white", "yellow"].includes(p) ? B.m600 : b, $ = C(0), w = /* @__PURE__ */ U(
27
- j,
27
+ const u = C(null), { m400: v, m500: E, m600: U } = P[p] ?? x, { height: h, width: a, font: n } = q[D] || {}, f = l || ["white", "yellow"].includes(p) ? F.m600 : B, $ = C(0), w = /* @__PURE__ */ g(
28
+ M,
28
29
  {
29
- $selectedColor: K,
30
- $hoverColor: v,
30
+ $selectedColor: v,
31
+ $hoverColor: E,
31
32
  $height: h,
32
33
  $width: s || a,
33
- $activeColor: E,
34
+ $activeColor: U,
34
35
  disabled: r,
35
36
  $isLoading: t,
36
37
  role: "button",
@@ -51,7 +52,7 @@ const A = ({ theme: e, children: l }) => /* @__PURE__ */ o(P, { rippleColor: e.m
51
52
  },
52
53
  children: [
53
54
  /* @__PURE__ */ o(
54
- M,
55
+ W,
55
56
  {
56
57
  ref: u,
57
58
  type: I,
@@ -64,7 +65,7 @@ const A = ({ theme: e, children: l }) => /* @__PURE__ */ o(P, { rippleColor: e.m
64
65
  ),
65
66
  c && /* @__PURE__ */ o(c, { color: f, size: n + 19 }),
66
67
  /* @__PURE__ */ o(
67
- W,
68
+ b,
68
69
  {
69
70
  color: f,
70
71
  size: `${n}rem`,
@@ -79,8 +80,8 @@ const A = ({ theme: e, children: l }) => /* @__PURE__ */ o(P, { rippleColor: e.m
79
80
  ]
80
81
  }
81
82
  );
82
- return /* @__PURE__ */ o(g, { $height: h, $width: s || a, disabled: r, $isLoading: t, children: t || r ? w : /* @__PURE__ */ o(A, { theme: p, children: w }) });
83
+ return /* @__PURE__ */ o(j, { $height: h, $width: s || a, disabled: r, $isLoading: t, ...K, children: t || r ? w : /* @__PURE__ */ o(G, { theme: p, children: w }) });
83
84
  };
84
85
  export {
85
- L as default
86
+ oo as default
86
87
  };
@@ -1,12 +1,12 @@
1
- import { jsxs as o, jsx as n } from "react/jsx-runtime";
2
- import u from "../../Typography/P/P.js";
1
+ import { jsxs as u, jsx as n } from "react/jsx-runtime";
2
+ import $ from "../../Typography/P/P.js";
3
3
  import m from "../../../colors/blue.js";
4
- import { Wrapper as $, HiddenInput as y, CircleBorder as D, Circle as w } from "./styles.js";
5
- const k = ({ label: s, value: r, name: p, color: e, textColor: f, isSelected: d, disabled: t, onChange: i }) => {
6
- const c = (e == null ? void 0 : e.m500) ?? m.m500, a = (e == null ? void 0 : e.m800) ?? m.m800;
7
- return /* @__PURE__ */ o($, { $disabled: t, $focusShade: a, children: [
4
+ import { Wrapper as y, HiddenInput as D, CircleBorder as w, Circle as x } from "./styles.js";
5
+ const C = ({ label: s, value: r, name: p, color: e, textColor: f, isSelected: d, disabled: t, onChange: i, ...c }) => {
6
+ const o = (e == null ? void 0 : e.m500) ?? m.m500, a = (e == null ? void 0 : e.m800) ?? m.m800;
7
+ return /* @__PURE__ */ u(y, { $disabled: t, $focusShade: a, ...c, children: [
8
8
  /* @__PURE__ */ n(
9
- y,
9
+ D,
10
10
  {
11
11
  type: "radio",
12
12
  name: p,
@@ -19,10 +19,10 @@ const k = ({ label: s, value: r, name: p, color: e, textColor: f, isSelected: d,
19
19
  }
20
20
  }
21
21
  ),
22
- /* @__PURE__ */ n(D, { "aria-hidden": "true", $isSelected: d, $shade: a, children: /* @__PURE__ */ n(w, { $isSelected: d, $shade: c }) }),
23
- /* @__PURE__ */ n(u, { color: f, size: "1.2rem", children: s })
22
+ /* @__PURE__ */ n(w, { "aria-hidden": "true", $isSelected: d, $shade: a, children: /* @__PURE__ */ n(x, { $isSelected: d, $shade: o }) }),
23
+ /* @__PURE__ */ n($, { color: f, size: "1.2rem", children: s })
24
24
  ] });
25
25
  };
26
26
  export {
27
- k as default
27
+ C as default
28
28
  };
@@ -1,9 +1,9 @@
1
- import { jsxs as f, jsx as u } from "react/jsx-runtime";
2
- import { createElement as g } from "react";
3
- import { getColor as h } from "../Checkbox/helpers.js";
4
- import x from "../Radio/Radio.js";
5
- import { Wrapper as j } from "./styles.js";
6
- const v = ({
1
+ import { jsxs as u, jsx as g } from "react/jsx-runtime";
2
+ import { createElement as h } from "react";
3
+ import { getColor as x } from "../Checkbox/helpers.js";
4
+ import j from "../Radio/Radio.js";
5
+ import { Wrapper as k } from "./styles.js";
6
+ const y = ({
7
7
  options: i,
8
8
  color: n = "blue",
9
9
  value: o,
@@ -11,34 +11,36 @@ const v = ({
11
11
  isHorizonatal: d,
12
12
  label: e,
13
13
  ariaLabel: m,
14
- name: c
14
+ name: c,
15
+ ...l
15
16
  }) => {
16
- const l = h(n), s = (r) => {
17
+ const s = x(n), t = (r) => {
17
18
  r !== o && a(r);
18
- }, t = (r) => /* @__PURE__ */ g(
19
- x,
19
+ }, f = (r) => /* @__PURE__ */ h(
20
+ j,
20
21
  {
21
22
  ...r,
22
23
  key: r == null ? void 0 : r.value,
23
24
  name: c,
24
- color: l,
25
+ color: s,
25
26
  isSelected: o === (r == null ? void 0 : r.value),
26
- onChange: s
27
+ onChange: t
27
28
  }
28
29
  );
29
- return /* @__PURE__ */ f(
30
- j,
30
+ return /* @__PURE__ */ u(
31
+ k,
31
32
  {
32
33
  role: "radiogroup",
33
34
  "aria-label": e ? void 0 : m,
34
35
  $isHorizonatal: d,
36
+ ...l,
35
37
  children: [
36
- e && /* @__PURE__ */ u("legend", { children: e }),
37
- i.map(t)
38
+ e && /* @__PURE__ */ g("legend", { children: e }),
39
+ i.map(f)
38
40
  ]
39
41
  }
40
42
  );
41
43
  };
42
44
  export {
43
- v as default
45
+ y as default
44
46
  };
@@ -1,24 +1,24 @@
1
- import { jsxs as u, jsx as d } from "react/jsx-runtime";
2
- import { LoaderWrapper as L, VisuallyHidden as $, Dot as f } from "./styles.js";
3
- import { SIZE as c, MEDIUM as l, THEME_SHADE as s, MINI_ANIMATION_DELAYS as D, ANIMATION_DELAYS as M, BLUE as N } from "./constants.js";
4
- import { getTheme as g } from "./helpers.js";
5
- const H = ({ size: m = l, theme: n = N, isBounce: p, isMini: t, isMiniDark: i }) => {
6
- const { dot: E, gap: I } = c[m] || c[l], r = g(n), a = t ? D : M, A = (i ? s.slice(2, 6) : t ? s.slice(0, 3) : s).map((o) => r[o] ?? r.m500), h = a.map(() => E);
7
- return /* @__PURE__ */ u(L, { role: "status", $gap: I, children: [
8
- /* @__PURE__ */ d($, { children: "Loading" }),
9
- h.map((o, e) => /* @__PURE__ */ d(
10
- f,
1
+ import { jsxs as L, jsx as a } from "react/jsx-runtime";
2
+ import { LoaderWrapper as g, VisuallyHidden as A, Dot as D } from "./styles.js";
3
+ import { SIZE as d, MEDIUM as c, THEME_SHADE as s, ANIMATION_DELAYS as I, BLUE as M } from "./constants.js";
4
+ import { getTheme as x } from "./helpers.js";
5
+ const B = ({ size: l = c, theme: n = M, isBounce: i, isMini: m, isMiniDark: p, ...E }) => {
6
+ const { dot: h, gap: u } = d[l] || d[c], t = x(n), r = I, $ = (p ? s.slice(2, 6) : m ? s.slice(0, 3) : s).map((o) => t[o] ?? t.m500), f = r.map(() => h);
7
+ return /* @__PURE__ */ L(g, { role: "status", $gap: u, ...E, children: [
8
+ /* @__PURE__ */ a(A, { children: "Loading" }),
9
+ f.map((o, e) => /* @__PURE__ */ a(
10
+ D,
11
11
  {
12
12
  "aria-hidden": "true",
13
13
  $size: o,
14
- $color: A[e],
15
- $delay: a[e],
16
- $isBounce: p
14
+ $color: $[e],
15
+ $delay: r[e],
16
+ $isBounce: i
17
17
  },
18
18
  `dot-${e}`
19
19
  ))
20
20
  ] });
21
21
  };
22
22
  export {
23
- H as default
23
+ B as default
24
24
  };
@@ -2,14 +2,13 @@ const m = "small", o = "medium", t = "large", e = {
2
2
  [m]: { dot: "0.5rem", gap: "0.3rem" },
3
3
  [o]: { dot: "0.75rem", gap: "0.5rem" },
4
4
  [t]: { dot: "1rem", gap: "0.7rem" }
5
- }, s = "blue", A = ["m200", "m300", "m400", "m600", "m800"], E = [0, 0.17, 0.34, 0.51, 0.68], c = [0, 0.28, 0.57];
5
+ }, r = "blue", s = ["m200", "m300", "m400", "m600", "m800"], E = [0, 0.17, 0.34, 0.51, 0.68];
6
6
  export {
7
7
  E as ANIMATION_DELAYS,
8
- s as BLUE,
8
+ r as BLUE,
9
9
  t as LARGE,
10
10
  o as MEDIUM,
11
- c as MINI_ANIMATION_DELAYS,
12
11
  e as SIZE,
13
12
  m as SMALL,
14
- A as THEME_SHADE
13
+ s as THEME_SHADE
15
14
  };
@@ -1,15 +1,15 @@
1
1
  import { jsx as c } from "react/jsx-runtime";
2
2
  import i from "../../colors/grey.js";
3
3
  import m from "../../colors/blue.js";
4
- import g from "../../colors/white.js";
5
- import { Wrapper as s, PWrapper as k } from "./styles.js";
6
- const v = ({ isSelected: o, isDisabled: e }) => o ? i.m700 : e ? i.m300 : i.m500, I = ({
4
+ import s from "../../colors/white.js";
5
+ import { Wrapper as k, PWrapper as v } from "./styles.js";
6
+ const w = ({ isSelected: o, isDisabled: e }) => o ? i.m700 : e ? i.m300 : i.m500, M = ({
7
7
  id: o,
8
8
  value: e,
9
9
  label: l,
10
10
  width: n = "20rem",
11
11
  isSelected: t,
12
- defaultColor: p = g,
12
+ defaultColor: p = s,
13
13
  selectedColor: a = m.m200,
14
14
  hoverColor: d = m.m50,
15
15
  activeColor: f = m.m100,
@@ -17,9 +17,10 @@ const v = ({ isSelected: o, isDisabled: e }) => o ? i.m700 : e ? i.m300 : i.m500
17
17
  size: $ = "1.2rem",
18
18
  onSelect: u,
19
19
  isDisabled: r,
20
- onMouseEnter: C
20
+ onMouseEnter: C,
21
+ ...g
21
22
  }) => /* @__PURE__ */ c(
22
- s,
23
+ k,
23
24
  {
24
25
  $isSelected: t,
25
26
  $width: n,
@@ -31,6 +32,7 @@ const v = ({ isSelected: o, isDisabled: e }) => o ? i.m700 : e ? i.m300 : i.m500
31
32
  $isHighlighted: h,
32
33
  id: o,
33
34
  role: "option",
35
+ ...g,
34
36
  "aria-selected": t,
35
37
  "aria-disabled": r || void 0,
36
38
  onClick: () => {
@@ -38,9 +40,9 @@ const v = ({ isSelected: o, isDisabled: e }) => o ? i.m700 : e ? i.m300 : i.m500
38
40
  },
39
41
  onMouseEnter: C,
40
42
  title: l,
41
- children: /* @__PURE__ */ c(k, { size: $, color: v({ isSelected: t, isDisabled: r }), $width: n, children: l })
43
+ children: /* @__PURE__ */ c(v, { size: $, color: w({ isSelected: t, isDisabled: r }), $width: n, children: l })
42
44
  }
43
45
  );
44
46
  export {
45
- I as default
47
+ M as default
46
48
  };