beth-clarity 1.2.2 → 1.2.3

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.
@@ -13,21 +13,21 @@ const Ke = ({
13
13
  ...d
14
14
  }) => {
15
15
  const i = "clarity-badge", u = !!r;
16
- let g = "";
17
- u ? g = `${i}--custom-bg` : g = `${i}--${t}`;
18
- const f = [
16
+ let f = "";
17
+ u ? f = `${i}--custom-bg` : f = `${i}--${t}`;
18
+ const p = [
19
19
  i,
20
- g,
20
+ f,
21
21
  `${i}--${a}`,
22
22
  s ? `${i}--rounded` : "",
23
23
  c ? `${i}--outlined` : "",
24
24
  o
25
- ].filter(Boolean).join(" "), p = {};
26
- return u && (p.backgroundColor = r, l && (p.color = l)), /* @__PURE__ */ e(
25
+ ].filter(Boolean).join(" "), h = {};
26
+ return u && (h.backgroundColor = r, l && (h.color = l)), /* @__PURE__ */ e(
27
27
  "span",
28
28
  {
29
- className: f,
30
- style: p,
29
+ className: p,
30
+ style: h,
31
31
  ...d,
32
32
  children: n
33
33
  }
@@ -81,14 +81,14 @@ const Ke = ({
81
81
  justifyContent: d,
82
82
  gap: i,
83
83
  m: u,
84
- mt: g,
85
- mr: f,
86
- mb: p,
87
- ml: y,
84
+ mt: f,
85
+ mr: p,
86
+ mb: h,
87
+ ml: g,
88
88
  mx: b,
89
89
  my: N,
90
90
  p: m,
91
- pt: h,
91
+ pt: y,
92
92
  pr: _,
93
93
  pb: x,
94
94
  pl: E,
@@ -128,11 +128,11 @@ const Ke = ({
128
128
  alignItems: c,
129
129
  justifyContent: d,
130
130
  gap: nt(i),
131
- marginTop: nt(g ?? N ?? u),
132
- marginRight: nt(f ?? b ?? u),
133
- marginBottom: nt(p ?? N ?? u),
134
- marginLeft: nt(y ?? b ?? u),
135
- paddingTop: nt(h ?? B ?? m),
131
+ marginTop: nt(f ?? N ?? u),
132
+ marginRight: nt(p ?? b ?? u),
133
+ marginBottom: nt(h ?? N ?? u),
134
+ marginLeft: nt(g ?? b ?? u),
135
+ paddingTop: nt(y ?? B ?? m),
136
136
  paddingRight: nt(_ ?? C ?? m),
137
137
  paddingBottom: nt(x ?? B ?? m),
138
138
  paddingLeft: nt(E ?? C ?? m),
@@ -163,14 +163,14 @@ const Ke = ({
163
163
  d,
164
164
  i,
165
165
  u,
166
- g,
167
166
  f,
168
167
  p,
169
- y,
168
+ h,
169
+ g,
170
170
  b,
171
171
  N,
172
172
  m,
173
- h,
173
+ y,
174
174
  _,
175
175
  x,
176
176
  E,
@@ -215,28 +215,28 @@ const Pe = ({
215
215
  title: d,
216
216
  customColor: i,
217
217
  customColorHover: u,
218
- ...g
218
+ ...f
219
219
  }) => {
220
- const f = "clarity-button", p = [
221
- f,
222
- !i && `${f}--${t}`,
223
- `${f}--${a}`,
224
- l && `${f}--loading`,
225
- r && `${f}--disabled`,
220
+ const p = "clarity-button", h = [
221
+ p,
222
+ !i && `${p}--${t}`,
223
+ `${p}--${a}`,
224
+ l && `${p}--loading`,
225
+ r && `${p}--disabled`,
226
226
  c
227
- ].filter(Boolean).join(" "), y = {};
228
- return i && (y["--button-bg"] = i, y["--button-hover-bg"] = u || `${i}E6`, y["--button-border"] = i, y["--button-hover-border"] = u || `${i}E6`, y["--button-fg"] = "#fff"), /* @__PURE__ */ w(
227
+ ].filter(Boolean).join(" "), g = {};
228
+ return i && (g["--button-bg"] = i, g["--button-hover-bg"] = u || `${i}E6`, g["--button-border"] = i, g["--button-hover-border"] = u || `${i}E6`, g["--button-fg"] = "#fff"), /* @__PURE__ */ w(
229
229
  "button",
230
230
  {
231
- className: p,
232
- style: y,
231
+ className: h,
232
+ style: g,
233
233
  disabled: r || l,
234
234
  onClick: o,
235
235
  type: s,
236
236
  title: d,
237
- ...g,
237
+ ...f,
238
238
  children: [
239
- l && /* @__PURE__ */ e("div", { className: `${f}__spinner` }),
239
+ l && /* @__PURE__ */ e("div", { className: `${p}__spinner` }),
240
240
  n
241
241
  ]
242
242
  }
@@ -253,31 +253,31 @@ const Pe = ({
253
253
  className: d = "",
254
254
  ...i
255
255
  }) => {
256
- const u = "clarity-button-group", g = `${u}--${t}`, f = [
256
+ const u = "clarity-button-group", f = `${u}--${t}`, p = [
257
257
  u,
258
- g,
258
+ f,
259
259
  `${u}--${a}`,
260
260
  !r && `${u}--outline`,
261
261
  s && `${u}--disabled`,
262
262
  d
263
- ].filter(Boolean).join(" "), p = (b) => {
263
+ ].filter(Boolean).join(" "), h = (b) => {
264
264
  if (s || !c) return;
265
265
  const N = l.find((m) => m.id === b);
266
266
  if (!(N != null && N.disabled))
267
267
  if (o) {
268
- const m = Array.isArray(n) ? n : [], h = m.includes(b) ? m.filter((_) => _ !== b) : [...m, b];
269
- c(h);
268
+ const m = Array.isArray(n) ? n : [], y = m.includes(b) ? m.filter((_) => _ !== b) : [...m, b];
269
+ c(y);
270
270
  } else
271
271
  c(b);
272
- }, y = (b) => o ? Array.isArray(n) && n.includes(b) : n === b;
272
+ }, g = (b) => o ? Array.isArray(n) && n.includes(b) : n === b;
273
273
  return /* @__PURE__ */ e(
274
274
  "div",
275
275
  {
276
- className: f,
276
+ className: p,
277
277
  role: "group",
278
278
  ...i,
279
279
  children: l.map((b, N) => {
280
- const m = y(b.id), h = [
280
+ const m = g(b.id), y = [
281
281
  `${u}__item`,
282
282
  m && `${u}__item--selected`,
283
283
  b.disabled && `${u}__item--disabled`,
@@ -287,8 +287,8 @@ const Pe = ({
287
287
  return /* @__PURE__ */ w(
288
288
  "button",
289
289
  {
290
- className: h,
291
- onClick: () => p(b.id),
290
+ className: y,
291
+ onClick: () => h(b.id),
292
292
  disabled: s || b.disabled,
293
293
  type: "button",
294
294
  "aria-pressed": m,
@@ -374,11 +374,11 @@ const pt = ({
374
374
  disabled: d = !1,
375
375
  delay: i = 200,
376
376
  hideDelay: u = 100,
377
- trigger: g = "hover",
378
- arrow: f = !0,
379
- ...p
377
+ trigger: f = "hover",
378
+ arrow: p = !0,
379
+ ...h
380
380
  }) => {
381
- const [y, b] = D(!1), [N, m] = D(a), [h, _] = D({ top: 0, left: 0 }), [x, E] = D(null), C = et(null), B = et(null), R = "clarity-tooltip", $ = 8, k = !!l || o;
381
+ const [g, b] = D(!1), [N, m] = D(a), [y, _] = D({ top: 0, left: 0 }), [x, E] = D(null), C = et(null), B = et(null), R = "clarity-tooltip", $ = 8, k = !!l || o;
382
382
  let A = "";
383
383
  k ? A = `${R}__content--custom-bg` : A = `${R}__content--${r}`;
384
384
  const H = [
@@ -388,14 +388,14 @@ const pt = ({
388
388
  ].filter(Boolean).join(" "), S = [
389
389
  `${R}__content`,
390
390
  A,
391
- f && `${R}__content--arrow`
391
+ p && `${R}__content--arrow`
392
392
  ].filter(Boolean).join(" "), z = {}, M = {};
393
393
  k && (M["--tooltip-bg-color"] = l || "#FFFFFF"), (n || o) && (M["--tooltip-text-color"] = n || "var(--clarity-gray-900)");
394
394
  const F = {
395
395
  ...z,
396
396
  ...Object.keys(M).length > 0 ? M : {},
397
- top: h.top,
398
- left: h.left,
397
+ top: y.top,
398
+ left: y.left,
399
399
  // Resetar estilos que vêm do CSS para posicionamento relativo
400
400
  position: "absolute",
401
401
  bottom: "auto",
@@ -418,7 +418,7 @@ const pt = ({
418
418
  }, u);
419
419
  E(O);
420
420
  }, L = () => {
421
- d || (y ? U() : j());
421
+ d || (g ? U() : j());
422
422
  }, K = () => {
423
423
  d || j();
424
424
  }, P = () => {
@@ -428,7 +428,7 @@ const pt = ({
428
428
  x && clearTimeout(x);
429
429
  }, [x]);
430
430
  const Z = () => {
431
- if (!y || !B.current || !C.current) return;
431
+ if (!g || !B.current || !C.current) return;
432
432
  const O = B.current.getBoundingClientRect(), X = C.current.getBoundingClientRect(), V = window.scrollX, Y = window.scrollY, lt = window.innerWidth, v = window.innerHeight, W = {
433
433
  top: {
434
434
  top: O.top + Y - X.height - $,
@@ -487,16 +487,16 @@ const pt = ({
487
487
  }
488
488
  };
489
489
  Lt(() => {
490
- if (y)
490
+ if (g)
491
491
  return Z(), window.addEventListener("scroll", Z, !0), window.addEventListener("resize", Z), () => {
492
492
  window.removeEventListener("scroll", Z, !0), window.removeEventListener("resize", Z);
493
493
  };
494
- }, [y, a, t]);
494
+ }, [g, a, t]);
495
495
  const q = {};
496
- let tt = g;
496
+ let tt = f;
497
497
  if (typeof window < "u") {
498
498
  const O = "ontouchstart" in window || navigator.maxTouchPoints > 0 || window.matchMedia && window.matchMedia("(pointer: coarse)").matches;
499
- g === "hover" && O && (tt = "focus");
499
+ f === "hover" && O && (tt = "focus");
500
500
  }
501
501
  return tt === "hover" ? (q.onMouseEnter = j, q.onMouseLeave = U) : tt === "click" ? q.onClick = L : tt === "focus" && (q.onFocus = K, q.onBlur = P), /* @__PURE__ */ w(jt, { children: [
502
502
  /* @__PURE__ */ e(
@@ -505,11 +505,11 @@ const pt = ({
505
505
  ref: B,
506
506
  className: `${R}__trigger`,
507
507
  ...q,
508
- ...p,
508
+ ...h,
509
509
  children: s
510
510
  }
511
511
  ),
512
- y && Ne(
512
+ g && Ne(
513
513
  /* @__PURE__ */ e(
514
514
  "div",
515
515
  {
@@ -517,7 +517,7 @@ const pt = ({
517
517
  className: H,
518
518
  style: F,
519
519
  role: "tooltip",
520
- "aria-hidden": !y,
520
+ "aria-hidden": !g,
521
521
  children: /* @__PURE__ */ e("div", { className: S, children: t })
522
522
  }
523
523
  ),
@@ -536,18 +536,18 @@ const pt = ({
536
536
  helper: d = !1,
537
537
  helperPosition: i = "top-right",
538
538
  className: u = "",
539
- disabled: g = !1,
540
- value: f,
541
- defaultValue: p,
542
- onFocus: y,
539
+ disabled: f = !1,
540
+ value: p,
541
+ defaultValue: h,
542
+ onFocus: g,
543
543
  onBlur: b,
544
544
  ...N
545
545
  }, m) => {
546
- const [h, _] = D(!1), [x, E] = D(!1), C = et(null), B = N.id || `input-${Math.random().toString(36).substr(2, 9)}`, R = et(null), [$, k] = D(!1);
546
+ const [y, _] = D(!1), [x, E] = D(!1), C = et(null), B = N.id || `input-${Math.random().toString(36).substr(2, 9)}`, R = et(null), [$, k] = D(!1);
547
547
  I.useImperativeHandle(m, () => C.current), J(() => {
548
548
  const j = C.current;
549
549
  j && E(j.value.length > 0);
550
- }, [f, p]), J(() => {
550
+ }, [p, h]), J(() => {
551
551
  const j = R.current;
552
552
  if (!j) return;
553
553
  const U = () => {
@@ -557,9 +557,9 @@ const pt = ({
557
557
  U();
558
558
  const L = new ResizeObserver(() => U());
559
559
  return L.observe(j), () => L.disconnect();
560
- }, [r, h, x, a, s, c]);
560
+ }, [r, y, x, a, s, c]);
561
561
  const A = (j) => {
562
- _(!0), y == null || y(j);
562
+ _(!0), g == null || g(j);
563
563
  }, H = (j) => {
564
564
  _(!1), E(j.target.value.length > 0), b == null || b(j);
565
565
  }, S = [
@@ -568,8 +568,8 @@ const pt = ({
568
568
  `clarity-input--${a}`,
569
569
  t && `clarity-input--${t}`,
570
570
  n && "clarity-input--error",
571
- g && "clarity-input--disabled",
572
- h && "clarity-input--focused",
571
+ f && "clarity-input--disabled",
572
+ y && "clarity-input--focused",
573
573
  x && "clarity-input--has-value",
574
574
  s && "clarity-input--with-start-icon",
575
575
  c && "clarity-input--with-end-icon",
@@ -607,9 +607,9 @@ const pt = ({
607
607
  ref: C,
608
608
  id: B,
609
609
  className: "clarity-input__element",
610
- disabled: g,
611
- value: f,
612
- defaultValue: p,
610
+ disabled: f,
611
+ value: p,
612
+ defaultValue: h,
613
613
  onFocus: A,
614
614
  onBlur: H,
615
615
  "aria-label": l,
@@ -630,9 +630,9 @@ const pt = ({
630
630
  ref: C,
631
631
  id: B,
632
632
  className: "clarity-input__element",
633
- disabled: g,
634
- value: f,
635
- defaultValue: p,
633
+ disabled: f,
634
+ value: p,
635
+ defaultValue: h,
636
636
  onFocus: A,
637
637
  onBlur: H,
638
638
  "aria-label": l,
@@ -660,25 +660,25 @@ const je = I.forwardRef(({
660
660
  endIcon: d,
661
661
  className: i = "",
662
662
  disabled: u = !1,
663
- value: g,
664
- defaultValue: f,
665
- onFocus: p,
666
- onBlur: y,
663
+ value: f,
664
+ defaultValue: p,
665
+ onFocus: h,
666
+ onBlur: g,
667
667
  rows: b = 3,
668
668
  minHeight: N,
669
669
  maxHeight: m,
670
- resizable: h = !0,
670
+ resizable: y = !0,
671
671
  ..._
672
672
  }, x) => {
673
673
  const [E, C] = D(!1), [B, R] = D(!1), $ = et(null);
674
674
  I.useImperativeHandle(x, () => $.current), J(() => {
675
675
  const j = $.current;
676
676
  j && R(j.value.length > 0);
677
- }, [g, f]);
677
+ }, [f, p]);
678
678
  const k = (j) => {
679
- C(!0), p == null || p(j);
679
+ C(!0), h == null || h(j);
680
680
  }, A = (j) => {
681
- C(!1), R(j.target.value.length > 0), y == null || y(j);
681
+ C(!1), R(j.target.value.length > 0), g == null || g(j);
682
682
  }, H = [
683
683
  "clarity-textarea",
684
684
  "clarity-textarea--outlined",
@@ -692,7 +692,7 @@ const je = I.forwardRef(({
692
692
  d && "clarity-textarea--with-end-icon",
693
693
  i
694
694
  ].filter(Boolean).join(" "), S = {
695
- resize: h ? "vertical" : "none",
695
+ resize: y ? "vertical" : "none",
696
696
  minHeight: N ? `${N}px` : void 0,
697
697
  maxHeight: m ? `${m}px` : void 0
698
698
  }, z = n != null && n.endsWith("left") ? "left" : "right", M = (j, U) => {
@@ -721,8 +721,8 @@ const je = I.forwardRef(({
721
721
  ref: $,
722
722
  className: "clarity-textarea__element",
723
723
  disabled: u,
724
- value: g,
725
- defaultValue: f,
724
+ value: f,
725
+ defaultValue: p,
726
726
  onFocus: k,
727
727
  onBlur: A,
728
728
  rows: b,
@@ -759,35 +759,35 @@ const Le = I.forwardRef(({
759
759
  endIcon: d,
760
760
  className: i = "",
761
761
  disabled: u = !1,
762
- value: g,
763
- defaultValue: f,
764
- onFocus: p,
765
- onBlur: y,
762
+ value: f,
763
+ defaultValue: p,
764
+ onFocus: h,
765
+ onBlur: g,
766
766
  onChange: b,
767
767
  options: N = [],
768
768
  placeholder: m = "Selecione uma opção",
769
- isClearable: h = !1,
769
+ isClearable: y = !1,
770
770
  isSearchable: _ = !1,
771
771
  ...x
772
772
  }, E) => {
773
- const [C, B] = D(!1), [R, $] = D(!1), [k, A] = D(g || f || ""), [H, S] = D(""), z = et(null), M = et(null), F = Array.isArray(N) ? N : [];
773
+ const [C, B] = D(!1), [R, $] = D(!1), [k, A] = D(f || p || ""), [H, S] = D(""), z = et(null), M = et(null), F = Array.isArray(N) ? N : [];
774
774
  I.useImperativeHandle(E, () => z.current), J(() => {
775
- g !== void 0 && A(g);
776
- }, [g]), J(() => {
775
+ f !== void 0 && A(f);
776
+ }, [f]), J(() => {
777
777
  const v = (W) => {
778
- z.current && !z.current.contains(W.target) && (B(!1), $(!1), y == null || y());
778
+ z.current && !z.current.contains(W.target) && (B(!1), $(!1), g == null || g());
779
779
  };
780
780
  return document.addEventListener("mousedown", v), () => document.removeEventListener("mousedown", v);
781
- }, [y]);
781
+ }, [g]);
782
782
  const j = _ && H ? F.filter(
783
783
  (v) => v.label.toLowerCase().includes(H.toLowerCase())
784
784
  ) : F, U = () => {
785
- u || (B(!C), $(!C), C ? (y == null || y(), _ && S("")) : (p == null || p(), _ && setTimeout(() => {
785
+ u || (B(!C), $(!C), C ? (g == null || g(), _ && S("")) : (h == null || h(), _ && setTimeout(() => {
786
786
  var v;
787
787
  (v = M.current) == null || v.focus();
788
788
  }, 0)));
789
789
  }, L = (v, W) => {
790
- v.disabled || (A(v.value), B(!1), $(!1), S(""), b == null || b(v, W), y == null || y());
790
+ v.disabled || (A(v.value), B(!1), $(!1), S(""), b == null || b(v, W), g == null || g());
791
791
  }, K = (v) => {
792
792
  S(v.target.value);
793
793
  }, P = (v) => {
@@ -808,7 +808,7 @@ const Le = I.forwardRef(({
808
808
  C && "clarity-select--open",
809
809
  _ && "clarity-select--searchable",
810
810
  c && "clarity-select--with-start-icon",
811
- (d || h) && "clarity-select--with-end-icon",
811
+ (d || y) && "clarity-select--with-end-icon",
812
812
  i
813
813
  ].filter(Boolean).join(" "), V = n != null && n.endsWith("left") ? "left" : "right", Y = (v, W) => {
814
814
  if (!l) return null;
@@ -850,7 +850,7 @@ const Le = I.forwardRef(({
850
850
  onChange: K,
851
851
  onKeyDown: P,
852
852
  onFocus: () => {
853
- C || (B(!0), $(!0), p == null || p());
853
+ C || (B(!0), $(!0), h == null || h());
854
854
  },
855
855
  placeholder: Z ? Z.label : m,
856
856
  disabled: u,
@@ -859,7 +859,7 @@ const Le = I.forwardRef(({
859
859
  ) : /* @__PURE__ */ e("div", { className: "clarity-select__display", children: Z ? Z.label : m }),
860
860
  r && /* @__PURE__ */ e("label", { className: "clarity-select__label", children: r })
861
861
  ] }),
862
- h && q && /* @__PURE__ */ e(
862
+ y && q && /* @__PURE__ */ e(
863
863
  "button",
864
864
  {
865
865
  type: "button",
@@ -956,14 +956,14 @@ const Ee = be(({
956
956
  errorMessage: d,
957
957
  disabled: i = !1,
958
958
  variant: u = "primary",
959
- size: g = "medium",
960
- maxSelectedLabels: f = 3,
961
- selectionLimit: p,
962
- className: y = "",
959
+ size: f = "medium",
960
+ maxSelectedLabels: p = 3,
961
+ selectionLimit: h,
962
+ className: g = "",
963
963
  id: b,
964
964
  name: N,
965
965
  required: m = !1,
966
- "data-testid": h,
966
+ "data-testid": y,
967
967
  ..._
968
968
  }, x) => {
969
969
  const [E, C] = D(!1), [B, R] = D(""), [$, k] = D(!1), A = et(null), H = et(null), S = et(null), z = Array.isArray(t) ? t : [], M = (v) => {
@@ -1003,7 +1003,7 @@ const Ee = be(({
1003
1003
  if (a.length === 0) return null;
1004
1004
  const v = a.map(
1005
1005
  (G) => z.find((Q) => Q.value === G)
1006
- ).filter(Boolean), W = v.slice(0, f), T = v.length - f;
1006
+ ).filter(Boolean), W = v.slice(0, p), T = v.length - p;
1007
1007
  return /* @__PURE__ */ w("div", { className: "clarity-multiselect__chips", children: [
1008
1008
  W.map((G) => /* @__PURE__ */ w("div", { className: "clarity-multiselect__chip", children: [
1009
1009
  /* @__PURE__ */ e("span", { className: "clarity-multiselect__chip-label", children: G.label }),
@@ -1026,11 +1026,11 @@ const Ee = be(({
1026
1026
  ] });
1027
1027
  }, O = [
1028
1028
  "clarity-multiselect-wrapper",
1029
- y
1029
+ g
1030
1030
  ].filter(Boolean).join(" "), X = [
1031
1031
  "clarity-multiselect",
1032
1032
  `clarity-multiselect--${u}`,
1033
- `clarity-multiselect--${g}`,
1033
+ `clarity-multiselect--${f}`,
1034
1034
  E && "clarity-multiselect--open",
1035
1035
  $ && "clarity-multiselect--focused",
1036
1036
  q && "clarity-multiselect--label-up",
@@ -1058,7 +1058,7 @@ const Ee = be(({
1058
1058
  {
1059
1059
  ref: M,
1060
1060
  className: X,
1061
- "data-testid": h,
1061
+ "data-testid": y,
1062
1062
  ..._,
1063
1063
  children: [
1064
1064
  /* @__PURE__ */ w(
@@ -1219,29 +1219,29 @@ const mt = ({
1219
1219
  showCloseButton: c = !0,
1220
1220
  closeOnOverlayClick: d = !0
1221
1221
  }) => {
1222
- const [i, u] = D(!1), f = t !== void 0 ? t : i, p = I.useCallback(() => {
1222
+ const [i, u] = D(!1), p = t !== void 0 ? t : i, h = I.useCallback(() => {
1223
1223
  a ? a() : u(!1);
1224
1224
  }, [a]);
1225
1225
  J(() => {
1226
- f && (r == null || r());
1227
- }, [f, r]), J(() => {
1228
- const h = (_) => {
1229
- _.key === "Escape" && p();
1226
+ p && (r == null || r());
1227
+ }, [p, r]), J(() => {
1228
+ const y = (_) => {
1229
+ _.key === "Escape" && h();
1230
1230
  };
1231
- return f ? (document.addEventListener("keydown", h), document.body.style.overflow = "hidden") : document.body.style.overflow = "unset", () => {
1232
- document.removeEventListener("keydown", h), document.body.style.overflow = "unset";
1231
+ return p ? (document.addEventListener("keydown", y), document.body.style.overflow = "hidden") : document.body.style.overflow = "unset", () => {
1232
+ document.removeEventListener("keydown", y), document.body.style.overflow = "unset";
1233
1233
  };
1234
- }, [f, p]);
1235
- const y = (h) => {
1236
- d && h.target === h.currentTarget && p();
1234
+ }, [p, h]);
1235
+ const g = (y) => {
1236
+ d && y.target === y.currentTarget && h();
1237
1237
  }, b = I.Children.toArray(l).find(
1238
- (h) => ot(h) && h.type.displayName === "Modal.Trigger"
1238
+ (y) => ot(y) && y.type.displayName === "Modal.Trigger"
1239
1239
  ), N = I.Children.toArray(l).filter(
1240
- (h) => ot(h) && h.type.displayName !== "Modal.Trigger"
1240
+ (y) => ot(y) && y.type.displayName !== "Modal.Trigger"
1241
1241
  ), m = ["clarity-modal", n, `clarity-modal--${s}`].filter(Boolean).join(" ");
1242
- return /* @__PURE__ */ w(Rt.Provider, { value: { onClose: p, variant: o, showCloseButton: c }, children: [
1242
+ return /* @__PURE__ */ w(Rt.Provider, { value: { onClose: h, variant: o, showCloseButton: c }, children: [
1243
1243
  b && rt(b, { onClick: () => u(!0) }),
1244
- f && /* @__PURE__ */ e("div", { className: "clarity-modal-overlay", onClick: y, children: /* @__PURE__ */ e("div", { className: m, children: N }) })
1244
+ p && /* @__PURE__ */ e("div", { className: "clarity-modal-overlay", onClick: g, children: /* @__PURE__ */ e("div", { className: m, children: N }) })
1245
1245
  ] });
1246
1246
  };
1247
1247
  mt.Header = Wt;
@@ -1262,11 +1262,11 @@ const zt = ct(void 0), ea = () => {
1262
1262
  c("visible");
1263
1263
  }, 10), u = setTimeout(() => {
1264
1264
  c("exiting");
1265
- }, l * 1e3 - 300), g = setTimeout(() => {
1265
+ }, l * 1e3 - 300), f = setTimeout(() => {
1266
1266
  n(t);
1267
1267
  }, l * 1e3);
1268
1268
  return () => {
1269
- clearTimeout(i), clearTimeout(u), clearTimeout(g);
1269
+ clearTimeout(i), clearTimeout(u), clearTimeout(f);
1270
1270
  };
1271
1271
  }, [t, l, n]);
1272
1272
  const d = [
@@ -1307,9 +1307,9 @@ const zt = ct(void 0), ea = () => {
1307
1307
  // position: 'right-top',
1308
1308
  ...d
1309
1309
  };
1310
- r((g) => {
1311
- const f = [u, ...g];
1312
- return f.length > 4 ? f.slice(0, 4) : f;
1310
+ r((f) => {
1311
+ const p = [u, ...f];
1312
+ return p.length > 4 ? p.slice(0, 4) : p;
1313
1313
  });
1314
1314
  }, []), o = _t((d) => {
1315
1315
  r((i) => i.filter((u) => u.id !== d));
@@ -1383,20 +1383,20 @@ const ht = ({
1383
1383
  showCloseButton: d = !0,
1384
1384
  title: i
1385
1385
  }) => {
1386
- const [u, g] = D(!1), [f, p] = D(!1), [y, b] = D(!1), N = t !== void 0, m = N ? t : u, h = _t(() => {
1387
- a ? a() : g(!1);
1386
+ const [u, f] = D(!1), [p, h] = D(!1), [g, b] = D(!1), N = t !== void 0, m = N ? t : u, y = _t(() => {
1387
+ a ? a() : f(!1);
1388
1388
  }, [a]), _ = _t(() => {
1389
- N || g(!0), r == null || r();
1389
+ N || f(!0), r == null || r();
1390
1390
  }, [N, r]);
1391
1391
  J(() => {
1392
1392
  if (m) {
1393
1393
  b(!0);
1394
1394
  const S = setTimeout(() => {
1395
- p(!0);
1395
+ h(!0);
1396
1396
  }, 50);
1397
1397
  return () => clearTimeout(S);
1398
1398
  } else {
1399
- p(!1);
1399
+ h(!1);
1400
1400
  const S = setTimeout(() => {
1401
1401
  b(!1);
1402
1402
  }, 300);
@@ -1404,14 +1404,14 @@ const ht = ({
1404
1404
  }
1405
1405
  }, [m]), J(() => {
1406
1406
  const S = (z) => {
1407
- z.key === "Escape" && h();
1407
+ z.key === "Escape" && y();
1408
1408
  };
1409
1409
  return m ? (document.addEventListener("keydown", S), document.body.style.overflow = "hidden") : (document.removeEventListener("keydown", S), document.body.style.overflow = "unset"), () => {
1410
1410
  document.removeEventListener("keydown", S), document.body.style.overflow = "unset";
1411
1411
  };
1412
- }, [m, h]);
1412
+ }, [m, y]);
1413
1413
  const x = (S) => {
1414
- c && S.target === S.currentTarget && h();
1414
+ c && S.target === S.currentTarget && y();
1415
1415
  }, E = I.Children.toArray(l);
1416
1416
  let C, B, R, $, k;
1417
1417
  E.forEach((S) => {
@@ -1436,14 +1436,14 @@ const ht = ({
1436
1436
  n,
1437
1437
  `clarity-offcanvas--${s}`,
1438
1438
  o && `clarity-offcanvas--${o}`,
1439
- f ? "clarity-offcanvas--open" : "clarity-offcanvas--closed"
1439
+ p ? "clarity-offcanvas--open" : "clarity-offcanvas--closed"
1440
1440
  ].filter(Boolean).join(" "), H = [
1441
1441
  "clarity-offcanvas-overlay",
1442
- f ? "clarity-offcanvas-overlay--visible" : ""
1442
+ p ? "clarity-offcanvas-overlay--visible" : ""
1443
1443
  ].filter(Boolean).join(" ");
1444
- return /* @__PURE__ */ w(Dt.Provider, { value: { onClose: h, variant: o, showCloseButton: d, placement: s, title: i }, children: [
1444
+ return /* @__PURE__ */ w(Dt.Provider, { value: { onClose: y, variant: o, showCloseButton: d, placement: s, title: i }, children: [
1445
1445
  C && rt(C, { onClick: _, variant: o }),
1446
- y && // Only render if shouldRender is true
1446
+ g && // Only render if shouldRender is true
1447
1447
  /* @__PURE__ */ e("div", { className: H, onClick: x, children: /* @__PURE__ */ w("div", { className: A, children: [
1448
1448
  B,
1449
1449
  R,
@@ -1471,28 +1471,28 @@ const Re = I.forwardRef(({
1471
1471
  errorMessage: d,
1472
1472
  labelPosition: i = "right",
1473
1473
  className: u = "",
1474
- disabled: g = !1,
1475
- checked: f,
1476
- id: p,
1477
- ...y
1474
+ disabled: f = !1,
1475
+ checked: p,
1476
+ id: h,
1477
+ ...g
1478
1478
  }, b) => {
1479
- const N = p || `check-input-${Math.random().toString(36).substr(2, 9)}`, m = [
1479
+ const N = h || `check-input-${Math.random().toString(36).substr(2, 9)}`, m = [
1480
1480
  "clarity-check-input-wrapper",
1481
1481
  `clarity-check-input-wrapper--${i}`,
1482
- g && "clarity-check-input-wrapper--disabled",
1482
+ f && "clarity-check-input-wrapper--disabled",
1483
1483
  c && "clarity-check-input-wrapper--error"
1484
- ].filter(Boolean).join(" "), h = [
1484
+ ].filter(Boolean).join(" "), y = [
1485
1485
  "clarity-check-input",
1486
1486
  `clarity-check-input--${t}`,
1487
1487
  `clarity-check-input--${r}`,
1488
1488
  a && `clarity-check-input--${a}`,
1489
1489
  c && "clarity-check-input--error",
1490
- g && "clarity-check-input--disabled",
1490
+ f && "clarity-check-input--disabled",
1491
1491
  u
1492
1492
  ].filter(Boolean).join(" "), _ = [
1493
1493
  "clarity-check-input__label",
1494
1494
  `clarity-check-input__label--${r}`,
1495
- g && "clarity-check-input__label--disabled"
1495
+ f && "clarity-check-input__label--disabled"
1496
1496
  ].filter(Boolean).join(" "), x = s != null && s.endsWith("left") ? "left" : "right", E = (B, R) => {
1497
1497
  if (!o) return null;
1498
1498
  const $ = typeof o == "object" ? o : void 0, k = ($ == null ? void 0 : $.content) ?? "Ajuda", A = ($ == null ? void 0 : $.plain) === !0, H = $ == null ? void 0 : $.variant, S = $ == null ? void 0 : $.bgColor, z = $ == null ? void 0 : $.textColor, M = B === "middle" ? 20 : 16;
@@ -1516,10 +1516,10 @@ const Re = I.forwardRef(({
1516
1516
  ref: b,
1517
1517
  id: N,
1518
1518
  type: t,
1519
- className: h,
1520
- disabled: g,
1521
- checked: f,
1522
- ...y
1519
+ className: y,
1520
+ disabled: f,
1521
+ checked: p,
1522
+ ...g
1523
1523
  }
1524
1524
  ),
1525
1525
  /* @__PURE__ */ w("div", { className: "clarity-check-input__custom", children: [
@@ -1570,10 +1570,10 @@ const Oe = I.forwardRef(({
1570
1570
  className: d = "",
1571
1571
  disabled: i = !1,
1572
1572
  checked: u,
1573
- id: g,
1574
- ...f
1575
- }, p) => {
1576
- const y = g || `input-switch-${Math.random().toString(36).substr(2, 9)}`, b = [
1573
+ id: f,
1574
+ ...p
1575
+ }, h) => {
1576
+ const g = f || `input-switch-${Math.random().toString(36).substr(2, 9)}`, b = [
1577
1577
  "clarity-input-switch-wrapper",
1578
1578
  `clarity-input-switch-wrapper--${c}`,
1579
1579
  i && "clarity-input-switch-wrapper--disabled",
@@ -1590,7 +1590,7 @@ const Oe = I.forwardRef(({
1590
1590
  `clarity-input-switch__label--${a}`,
1591
1591
  t && `clarity-input-switch__label--${t}`,
1592
1592
  i && "clarity-input-switch__label--disabled"
1593
- ].filter(Boolean).join(" "), h = n != null && n.endsWith("left") ? "left" : "right", _ = (E, C) => {
1593
+ ].filter(Boolean).join(" "), y = n != null && n.endsWith("left") ? "left" : "right", _ = (E, C) => {
1594
1594
  if (!l) return null;
1595
1595
  const B = typeof l == "object" ? l : void 0, R = (B == null ? void 0 : B.content) ?? "Ajuda", $ = (B == null ? void 0 : B.plain) === !0, k = B == null ? void 0 : B.variant, A = B == null ? void 0 : B.bgColor, H = B == null ? void 0 : B.textColor, S = E === "middle" ? 20 : 16;
1596
1596
  return /* @__PURE__ */ e(
@@ -1606,30 +1606,30 @@ const Oe = I.forwardRef(({
1606
1606
  children: /* @__PURE__ */ e("button", { type: "button", className: "clarity-input-switch__helper-icon", "aria-label": "Helper", children: /* @__PURE__ */ e("svg", { viewBox: "0 0 24 24", width: S, height: S, fill: "currentColor", children: /* @__PURE__ */ e("path", { d: "M12.866 3l9.526 16.5a1 1 0 0 1-.866 1.5H2.474a1 1 0 0 1-.866-1.5L11.134 3a1 1 0 0 1 1.732 0zM11 16v2h2v-2h-2zm0-7v5h2V9h-2z" }) }) })
1607
1607
  }
1608
1608
  );
1609
- }, x = /* @__PURE__ */ w("label", { className: b, htmlFor: y, children: [
1609
+ }, x = /* @__PURE__ */ w("label", { className: b, htmlFor: g, children: [
1610
1610
  /* @__PURE__ */ e(
1611
1611
  "input",
1612
1612
  {
1613
- ref: p,
1614
- id: y,
1613
+ ref: h,
1614
+ id: g,
1615
1615
  type: "checkbox",
1616
1616
  className: N,
1617
1617
  disabled: i,
1618
1618
  checked: u,
1619
- ...f
1619
+ ...p
1620
1620
  }
1621
1621
  ),
1622
1622
  /* @__PURE__ */ e("div", { className: "clarity-input-switch__track", children: /* @__PURE__ */ e("div", { className: "clarity-input-switch__thumb" }) }),
1623
1623
  r && /* @__PURE__ */ e("span", { className: m, children: r })
1624
1624
  ] });
1625
1625
  return /* @__PURE__ */ w("div", { className: "clarity-input-switch-container", children: [
1626
- l && (n == null ? void 0 : n.startsWith("top")) && /* @__PURE__ */ e("div", { className: `clarity-input-switch__helper-row clarity-input-switch__helper-row--top clarity-input-switch__helper-row--${h}`, children: _("top", h) }),
1627
- l && (n != null && n.startsWith("middle")) ? /* @__PURE__ */ w("div", { className: `clarity-input-switch__middle-row clarity-input-switch__middle-row--${h}`, children: [
1628
- h === "left" && _("middle", h),
1626
+ l && (n == null ? void 0 : n.startsWith("top")) && /* @__PURE__ */ e("div", { className: `clarity-input-switch__helper-row clarity-input-switch__helper-row--top clarity-input-switch__helper-row--${y}`, children: _("top", y) }),
1627
+ l && (n != null && n.startsWith("middle")) ? /* @__PURE__ */ w("div", { className: `clarity-input-switch__middle-row clarity-input-switch__middle-row--${y}`, children: [
1628
+ y === "left" && _("middle", y),
1629
1629
  x,
1630
- h === "right" && _("middle", h)
1630
+ y === "right" && _("middle", y)
1631
1631
  ] }) : x,
1632
- l && (n == null ? void 0 : n.startsWith("bottom")) && /* @__PURE__ */ e("div", { className: `clarity-input-switch__helper-row clarity-input-switch__helper-row--bottom clarity-input-switch__helper-row--${h}`, children: _("bottom", h) }),
1632
+ l && (n == null ? void 0 : n.startsWith("bottom")) && /* @__PURE__ */ e("div", { className: `clarity-input-switch__helper-row clarity-input-switch__helper-row--bottom clarity-input-switch__helper-row--${y}`, children: _("bottom", y) }),
1633
1633
  o && s && /* @__PURE__ */ e("div", { className: "clarity-input-switch__error-text", children: s })
1634
1634
  ] });
1635
1635
  });
@@ -1688,27 +1688,27 @@ const ut = ({
1688
1688
  }) => {
1689
1689
  const [s, c] = D(!1), d = t !== void 0, i = d ? t : s, u = () => {
1690
1690
  d || c(!0);
1691
- }, g = I.useCallback(() => {
1691
+ }, f = I.useCallback(() => {
1692
1692
  a ? a() : c(!1);
1693
- }, [a]), f = () => {
1694
- r && r(), g();
1693
+ }, [a]), p = () => {
1694
+ r && r(), f();
1695
1695
  };
1696
1696
  J(() => {
1697
1697
  const N = (m) => {
1698
- m.key === "Escape" && g();
1698
+ m.key === "Escape" && f();
1699
1699
  };
1700
1700
  return i ? (document.addEventListener("keydown", N), o && (document.body.style.overflow = "hidden")) : document.body.style.overflow = "unset", () => {
1701
1701
  document.removeEventListener("keydown", N), document.body.style.overflow = "unset";
1702
1702
  };
1703
- }, [i, g, o]);
1704
- const p = I.Children.toArray(n).find(
1703
+ }, [i, f, o]);
1704
+ const h = I.Children.toArray(n).find(
1705
1705
  (N) => ot(N) && N.type.displayName === "ConfirmationDialog.Trigger"
1706
- ), y = I.Children.toArray(n).filter(
1706
+ ), g = I.Children.toArray(n).filter(
1707
1707
  (N) => ot(N) && N.type.displayName !== "ConfirmationDialog.Trigger"
1708
1708
  ), b = `clarity-confirmation-dialog clarity-confirmation-dialog--${l}`;
1709
- return /* @__PURE__ */ w(Yt.Provider, { value: { variant: l, onClose: g, onConfirm: f, onOpen: u }, children: [
1710
- p,
1711
- i && /* @__PURE__ */ e("div", { className: "clarity-modal-overlay", children: /* @__PURE__ */ e("div", { className: b, children: y }) })
1709
+ return /* @__PURE__ */ w(Yt.Provider, { value: { variant: l, onClose: f, onConfirm: p, onOpen: u }, children: [
1710
+ h,
1711
+ i && /* @__PURE__ */ e("div", { className: "clarity-modal-overlay", children: /* @__PURE__ */ e("div", { className: b, children: g }) })
1712
1712
  ] });
1713
1713
  };
1714
1714
  ut.Header = Zt;
@@ -1730,30 +1730,30 @@ const ra = ({
1730
1730
  "aria-label": d,
1731
1731
  title: i,
1732
1732
  customColor: u,
1733
- customColorHover: g,
1734
- ...f
1733
+ customColorHover: f,
1734
+ ...p
1735
1735
  }) => {
1736
- const p = "clarity-button-icon", y = [
1737
- p,
1738
- !u && `${p}--${t}`,
1739
- `${p}--${a}`,
1740
- l && `${p}--loading`,
1741
- r && `${p}--disabled`,
1736
+ const h = "clarity-button-icon", g = [
1737
+ h,
1738
+ !u && `${h}--${t}`,
1739
+ `${h}--${a}`,
1740
+ l && `${h}--loading`,
1741
+ r && `${h}--disabled`,
1742
1742
  c
1743
1743
  ].filter(Boolean).join(" "), b = {};
1744
- return u && (b["--button-icon-bg"] = u, b["--button-icon-hover-bg"] = g || `${u}E6`), /* @__PURE__ */ w(
1744
+ return u && (b["--button-icon-bg"] = u, b["--button-icon-hover-bg"] = f || `${u}E6`), /* @__PURE__ */ w(
1745
1745
  "button",
1746
1746
  {
1747
- className: y,
1747
+ className: g,
1748
1748
  disabled: r || l,
1749
1749
  onClick: o,
1750
1750
  type: s,
1751
1751
  "aria-label": d,
1752
1752
  title: i,
1753
1753
  style: b,
1754
- ...f,
1754
+ ...p,
1755
1755
  children: [
1756
- l && /* @__PURE__ */ e("div", { className: `${p}__spinner` }),
1756
+ l && /* @__PURE__ */ e("div", { className: `${h}__spinner` }),
1757
1757
  !l && n
1758
1758
  ]
1759
1759
  }
@@ -1770,19 +1770,19 @@ const ra = ({
1770
1770
  href: d,
1771
1771
  target: i,
1772
1772
  rel: u,
1773
- className: g = "",
1774
- ...f
1773
+ className: f = "",
1774
+ ...p
1775
1775
  }) => {
1776
- const p = "clarity-button-link", y = a && r, b = y ? `${p}--custom` : `${p}--${t}`, N = [
1777
- p,
1776
+ const h = "clarity-button-link", g = a && r, b = g ? `${h}--custom` : `${h}--${t}`, N = [
1777
+ h,
1778
1778
  b,
1779
- `${p}--${n}`,
1780
- o && `${p}--disabled`,
1781
- g
1779
+ `${h}--${n}`,
1780
+ o && `${h}--disabled`,
1781
+ f
1782
1782
  ].filter(Boolean).join(" "), m = (_) => {
1783
1783
  const x = parseInt(_);
1784
1784
  return x >= 800 ? "900" : x >= 700 ? "800" : x >= 600 ? "700" : x >= 500 ? "600" : x >= 400 ? "500" : x >= 300 ? "400" : x >= 200 ? "300" : "200";
1785
- }, h = y ? {
1785
+ }, y = g ? {
1786
1786
  "--custom-color": `var(--clarity-${a}-${r})`,
1787
1787
  "--custom-hover-color": `var(--clarity-${a}-${l || m(r)})`
1788
1788
  } : {};
@@ -1793,19 +1793,19 @@ const ra = ({
1793
1793
  target: i,
1794
1794
  rel: u || (i === "_blank" ? "noopener noreferrer" : void 0),
1795
1795
  className: N,
1796
- style: h,
1796
+ style: y,
1797
1797
  onClick: o ? void 0 : c,
1798
- ...f,
1798
+ ...p,
1799
1799
  children: s
1800
1800
  }
1801
1801
  ) : /* @__PURE__ */ e(
1802
1802
  "button",
1803
1803
  {
1804
1804
  className: N,
1805
- style: h,
1805
+ style: y,
1806
1806
  disabled: o,
1807
1807
  onClick: c,
1808
- ...f,
1808
+ ...p,
1809
1809
  children: s
1810
1810
  }
1811
1811
  );
@@ -1827,24 +1827,24 @@ const ra = ({
1827
1827
  onSelect: i,
1828
1828
  ...u
1829
1829
  }) => {
1830
- const [g, f] = D(() => n ? Array.isArray(n) ? n : [n] : []), p = (E) => {
1830
+ const [f, p] = D(() => n ? Array.isArray(n) ? n : [n] : []), h = (E) => {
1831
1831
  let C;
1832
- o ? C = g.includes(E) ? g.filter((B) => B !== E) : [...g, E] : C = g.includes(E) ? [] : [E], f(C), i && i(g.includes(E) ? null : E, {});
1833
- }, y = "clarity-accordion", b = a && r, N = b ? `${y}--custom` : `${y}--${t}`, m = [
1834
- y,
1832
+ o ? C = f.includes(E) ? f.filter((B) => B !== E) : [...f, E] : C = f.includes(E) ? [] : [E], p(C), i && i(f.includes(E) ? null : E, {});
1833
+ }, g = "clarity-accordion", b = a && r, N = b ? `${g}--custom` : `${g}--${t}`, m = [
1834
+ g,
1835
1835
  N,
1836
- s && `${y}--flush`,
1836
+ s && `${g}--flush`,
1837
1837
  c
1838
- ].filter(Boolean).join(" "), h = (E) => {
1838
+ ].filter(Boolean).join(" "), y = (E) => {
1839
1839
  const C = parseInt(E);
1840
1840
  return C >= 800 ? "900" : C >= 700 ? "800" : C >= 600 ? "700" : C >= 500 ? "600" : C >= 400 ? "500" : C >= 300 ? "400" : C >= 200 ? "300" : "200";
1841
1841
  }, _ = b ? {
1842
1842
  "--custom-border-color": `var(--clarity-${a}-${r})`,
1843
1843
  "--custom-header-color": `var(--clarity-${a}-${r})`,
1844
- "--custom-hover-color": `var(--clarity-${a}-${l || h(r)})`
1844
+ "--custom-hover-color": `var(--clarity-${a}-${l || y(r)})`
1845
1845
  } : {}, x = {
1846
- activeKeys: g,
1847
- toggleItem: p,
1846
+ activeKeys: f,
1847
+ toggleItem: h,
1848
1848
  alwaysOpen: o,
1849
1849
  variant: t,
1850
1850
  product: a,
@@ -1959,32 +1959,32 @@ const ra = ({
1959
1959
  const [l, n] = D(!1), [o, s] = D({}), c = et(null), d = et(null), i = et(null);
1960
1960
  return Lt(() => {
1961
1961
  if (l) {
1962
- const u = d.current, g = i.current;
1963
- if (!u || !g) return;
1964
- const f = u.getBoundingClientRect(), p = g.getBoundingClientRect(), y = window.innerHeight, b = window.innerWidth;
1962
+ const u = d.current, f = i.current;
1963
+ if (!u || !f) return;
1964
+ const p = u.getBoundingClientRect(), h = f.getBoundingClientRect(), g = window.innerHeight, b = window.innerWidth;
1965
1965
  let N = a;
1966
- a === "bottom" && f.bottom + p.height > y && (N = "top"), a === "top" && f.top - p.height < 0 && (N = "bottom"), a === "right" && f.right + p.width > b && (N = "left"), a === "left" && f.left - p.width < 0 && (N = "right");
1966
+ a === "bottom" && p.bottom + h.height > g && (N = "top"), a === "top" && p.top - h.height < 0 && (N = "bottom"), a === "right" && p.right + h.width > b && (N = "left"), a === "left" && p.left - h.width < 0 && (N = "right");
1967
1967
  const m = {};
1968
1968
  switch (N) {
1969
1969
  case "top":
1970
- m.bottom = f.height + 4, m.left = f.width / 2 - p.width / 2;
1970
+ m.bottom = p.height + 4, m.left = p.width / 2 - h.width / 2;
1971
1971
  break;
1972
1972
  case "right":
1973
- m.left = f.width + 4, m.top = f.height / 2 - p.height / 2;
1973
+ m.left = p.width + 4, m.top = p.height / 2 - h.height / 2;
1974
1974
  break;
1975
1975
  case "left":
1976
- m.right = f.width + 4, m.top = f.height / 2 - p.height / 2;
1976
+ m.right = p.width + 4, m.top = p.height / 2 - h.height / 2;
1977
1977
  break;
1978
1978
  case "bottom":
1979
1979
  default:
1980
- m.top = f.height + 4, m.left = f.width / 2 - p.width / 2;
1980
+ m.top = p.height + 4, m.left = p.width / 2 - h.width / 2;
1981
1981
  break;
1982
1982
  }
1983
1983
  s(m);
1984
1984
  }
1985
1985
  }, [l, a]), J(() => {
1986
- const u = (g) => {
1987
- c.current && !c.current.contains(g.target) && n(!1);
1986
+ const u = (f) => {
1987
+ c.current && !c.current.contains(f.target) && n(!1);
1988
1988
  };
1989
1989
  return document.addEventListener("mousedown", u), () => {
1990
1990
  document.removeEventListener("mousedown", u);
@@ -2044,25 +2044,29 @@ const le = ({
2044
2044
  onTabChange: r,
2045
2045
  variant: l = "primary",
2046
2046
  orientation: n = "horizontal",
2047
- className: o = ""
2047
+ align: o = "left",
2048
+ className: s = ""
2048
2049
  }) => {
2049
- const s = [
2050
+ let c = "";
2051
+ o === "center" ? c = "clarity-tabs-align-center" : o === "right" && (c = "clarity-tabs-align-right");
2052
+ const d = [
2050
2053
  "clarity-tabs-container",
2051
- o,
2052
- `orientation-${n}`
2053
- ].filter(Boolean).join(" "), c = [], d = [];
2054
- return _e.forEach(t, (i) => {
2055
- ot(i) && i.type === xt ? c.push(i) : d.push(i);
2056
- }), /* @__PURE__ */ w("div", { className: s, children: [
2057
- /* @__PURE__ */ e("div", { className: "clarity-tab-list", role: "tablist", children: c.map(
2058
- (i) => rt(i, {
2059
- isActive: I.isValidElement(i) && i.props.id === a,
2054
+ s,
2055
+ `orientation-${n}`,
2056
+ n === "horizontal" ? c : ""
2057
+ ].filter(Boolean).join(" "), i = [], u = [];
2058
+ return _e.forEach(t, (f) => {
2059
+ ot(f) && f.type === xt ? i.push(f) : u.push(f);
2060
+ }), /* @__PURE__ */ w("div", { className: d, children: [
2061
+ /* @__PURE__ */ e("div", { className: "clarity-tab-list", role: "tablist", children: i.map(
2062
+ (f) => rt(f, {
2063
+ isActive: I.isValidElement(f) && f.props.id === a,
2060
2064
  onClick: r,
2061
2065
  variant: l,
2062
2066
  orientation: n
2063
2067
  })
2064
2068
  ) }),
2065
- d
2069
+ u
2066
2070
  ] });
2067
2071
  };
2068
2072
  le.Tab = xt;
@@ -2080,11 +2084,11 @@ const ne = ct(null), yt = () => {
2080
2084
  inputPlaceholder: n = "Search...",
2081
2085
  ...o
2082
2086
  }) => {
2083
- const [s, c] = D(""), [d, i] = D(null), [u, g] = D(!1), f = [
2087
+ const [s, c] = D(""), [d, i] = D(null), [u, f] = D(!1), p = [
2084
2088
  "clarity-command",
2085
2089
  `clarity-command--${r}`,
2086
2090
  a
2087
- ].filter(Boolean).join(" "), p = vt(() => ({
2091
+ ].filter(Boolean).join(" "), h = vt(() => ({
2088
2092
  searchTerm: s,
2089
2093
  setSearchTerm: c,
2090
2094
  value: d,
@@ -2095,9 +2099,9 @@ const ne = ct(null), yt = () => {
2095
2099
  inputPlaceholder: n
2096
2100
  },
2097
2101
  isOpen: u,
2098
- setIsOpen: g
2102
+ setIsOpen: f
2099
2103
  }), [s, d, r, l, n, u]);
2100
- return /* @__PURE__ */ e(ne.Provider, { value: p, children: /* @__PURE__ */ e("div", { className: f, ...o, children: t }) });
2104
+ return /* @__PURE__ */ e(ne.Provider, { value: h, children: /* @__PURE__ */ e("div", { className: p, ...o, children: t }) });
2101
2105
  };
2102
2106
  ie.displayName = "Command";
2103
2107
  const se = ({ placeholder: t = "Search...", variant: a, onClick: r }) => {
@@ -2158,16 +2162,16 @@ const de = ({ children: t, className: a = "", ...r }) => {
2158
2162
  const { searchTerm: l } = yt();
2159
2163
  let n = !1;
2160
2164
  const o = (d) => I.Children.toArray(d).map((i) => {
2161
- var g;
2165
+ var f;
2162
2166
  if (!I.isValidElement(i)) return i;
2163
2167
  const u = i.type.displayName;
2164
2168
  if (u === "Command.Empty")
2165
2169
  return null;
2166
2170
  if (u === "Command.Item")
2167
- return (((g = i.props.children) == null ? void 0 : g.toString().toLowerCase()) || "").includes(l.toLowerCase()) ? (n = !0, i) : null;
2171
+ return (((f = i.props.children) == null ? void 0 : f.toString().toLowerCase()) || "").includes(l.toLowerCase()) ? (n = !0, i) : null;
2168
2172
  if (u === "Command.Group") {
2169
- const f = o(i.props.children);
2170
- return I.Children.toArray(f).some((y) => I.isValidElement(y) && y.type.displayName === "Command.Item") ? I.cloneElement(i, { ...i.props, children: f }) : null;
2173
+ const p = o(i.props.children);
2174
+ return I.Children.toArray(p).some((g) => I.isValidElement(g) && g.type.displayName === "Command.Item") ? I.cloneElement(i, { ...i.props, children: p }) : null;
2171
2175
  }
2172
2176
  return i;
2173
2177
  }).filter(Boolean), s = o(t), c = ["clarity-command-list", a].filter(Boolean).join(" ");
@@ -2230,40 +2234,40 @@ const ia = Object.assign(ie, {
2230
2234
  isLoading: o = !1,
2231
2235
  pagination: s
2232
2236
  }) => {
2233
- const [c, d] = D(null), [i, u] = D("none"), g = (m) => {
2234
- m.sortable && (c === m.key ? u((h) => h === "asc" ? "desc" : h === "desc" ? "none" : "asc") : (d(m.key), u("asc")));
2235
- }, f = vt(() => i === "none" || !c ? r : [...r].sort((m, h) => {
2236
- const _ = m[c], x = h[c];
2237
+ const [c, d] = D(null), [i, u] = D("none"), f = (m) => {
2238
+ m.sortable && (c === m.key ? u((y) => y === "asc" ? "desc" : y === "desc" ? "none" : "asc") : (d(m.key), u("asc")));
2239
+ }, p = vt(() => i === "none" || !c ? r : [...r].sort((m, y) => {
2240
+ const _ = m[c], x = y[c];
2237
2241
  return _ < x ? i === "asc" ? -1 : 1 : _ > x ? i === "asc" ? 1 : -1 : 0;
2238
- }), [r, c, i]), p = (m) => m.sortable ? c !== m.key || i === "none" ? /* @__PURE__ */ e("span", { className: "sort-icon", children: "↕" }) : i === "asc" ? /* @__PURE__ */ e("span", { className: "sort-icon", children: "↑" }) : /* @__PURE__ */ e("span", { className: "sort-icon", children: "↓" }) : null;
2242
+ }), [r, c, i]), h = (m) => m.sortable ? c !== m.key || i === "none" ? /* @__PURE__ */ e("span", { className: "sort-icon", children: "↕" }) : i === "asc" ? /* @__PURE__ */ e("span", { className: "sort-icon", children: "↑" }) : /* @__PURE__ */ e("span", { className: "sort-icon", children: "↓" }) : null;
2239
2243
  if (o)
2240
2244
  return /* @__PURE__ */ e(Ge, { columns: a, viewMode: l });
2241
- const y = `table-variant-${t} ${n ? "is-scrollable" : ""}`, b = () => {
2245
+ const g = `table-variant-${t} ${n ? "is-scrollable" : ""}`, b = () => {
2242
2246
  if (!s) return null;
2243
2247
  const {
2244
2248
  currentPage: m,
2245
- totalPages: h,
2249
+ totalPages: y,
2246
2250
  onPageChange: _,
2247
2251
  totalItems: x,
2248
2252
  itemsPerPage: E,
2249
2253
  position: C = "right"
2250
2254
  } = s;
2251
- if (typeof h != "number" || typeof m != "number")
2255
+ if (typeof y != "number" || typeof m != "number")
2252
2256
  return console.warn("Table Pagination: Invalid pagination props", s), null;
2253
2257
  if (x <= E)
2254
2258
  return null;
2255
2259
  const B = (m - 1) * E + 1, R = Math.min(m * E, x), $ = () => {
2256
2260
  const k = [];
2257
- if (h <= 5)
2258
- for (let H = 1; H <= h; H++) k.push(H);
2261
+ if (y <= 5)
2262
+ for (let H = 1; H <= y; H++) k.push(H);
2259
2263
  else if (m <= 3) {
2260
2264
  for (let H = 1; H <= 4; H++) k.push(H);
2261
- k.push("..."), k.push(h);
2262
- } else if (m >= h - 2) {
2265
+ k.push("..."), k.push(y);
2266
+ } else if (m >= y - 2) {
2263
2267
  k.push(1), k.push("...");
2264
- for (let H = h - 3; H <= h; H++) k.push(H);
2268
+ for (let H = y - 3; H <= y; H++) k.push(H);
2265
2269
  } else
2266
- k.push(1), k.push("..."), k.push(m - 1), k.push(m), k.push(m + 1), k.push("..."), k.push(h);
2270
+ k.push(1), k.push("..."), k.push(m - 1), k.push(m), k.push(m + 1), k.push("..."), k.push(y);
2267
2271
  return k;
2268
2272
  };
2269
2273
  return /* @__PURE__ */ w("div", { className: `table-pagination align-${C}`, children: [
@@ -2312,7 +2316,7 @@ const ia = Object.assign(ie, {
2312
2316
  {
2313
2317
  className: "pagination-button",
2314
2318
  onClick: () => _(m + 1),
2315
- disabled: m === h,
2319
+ disabled: m === y,
2316
2320
  "aria-label": "Próxima página",
2317
2321
  children: "›"
2318
2322
  }
@@ -2321,48 +2325,48 @@ const ia = Object.assign(ie, {
2321
2325
  "button",
2322
2326
  {
2323
2327
  className: "pagination-button",
2324
- onClick: () => _(h),
2325
- disabled: m === h,
2328
+ onClick: () => _(y),
2329
+ disabled: m === y,
2326
2330
  "aria-label": "Última página",
2327
2331
  children: "»"
2328
2332
  }
2329
2333
  )
2330
2334
  ] })
2331
2335
  ] });
2332
- }, N = /* @__PURE__ */ w("div", { className: `table-wrapper ${y}`, children: [
2336
+ }, N = /* @__PURE__ */ w("div", { className: `table-wrapper ${g}`, children: [
2333
2337
  /* @__PURE__ */ w("table", { children: [
2334
2338
  /* @__PURE__ */ e("thead", { className: "table-header", children: /* @__PURE__ */ e("tr", { className: "table-row", children: a.map((m) => /* @__PURE__ */ w(
2335
2339
  "th",
2336
2340
  {
2337
2341
  className: `table-header-cell ${m.sortable ? "sortable" : ""} table-header-cell-${t}`,
2338
- onClick: () => g(m),
2342
+ onClick: () => f(m),
2339
2343
  style: { minWidth: m.minWidth },
2340
2344
  children: [
2341
2345
  m.header,
2342
- p(m)
2346
+ h(m)
2343
2347
  ]
2344
2348
  },
2345
2349
  m.key
2346
2350
  )) }) }),
2347
- /* @__PURE__ */ e("tbody", { children: f.length === 0 ? /* @__PURE__ */ e("tr", { className: "table-row", children: /* @__PURE__ */ e("td", { colSpan: a.length, className: "table-cell", style: { textAlign: "center", padding: "2rem" }, children: "Nenhum resultado encontrado" }) }) : f.map((m, h) => /* @__PURE__ */ e("tr", { className: `table-row table-row-${t}`, children: a.map((_) => /* @__PURE__ */ e("td", { className: `table-cell ${_.align ? `table-cell-align-${_.align}` : ""}`, style: { minWidth: _.minWidth }, children: _.render ? _.render(m) : m[_.key] }, _.key)) }, h)) })
2351
+ /* @__PURE__ */ e("tbody", { children: p.length === 0 ? /* @__PURE__ */ e("tr", { className: "table-row", children: /* @__PURE__ */ e("td", { colSpan: a.length, className: "table-cell", style: { textAlign: "center", padding: "2rem" }, children: "Nenhum resultado encontrado" }) }) : p.map((m, y) => /* @__PURE__ */ e("tr", { className: `table-row table-row-${t}`, children: a.map((_) => /* @__PURE__ */ e("td", { className: `table-cell ${_.align ? `table-cell-align-${_.align}` : ""}`, style: { minWidth: _.minWidth }, children: _.render ? _.render(m) : m[_.key] }, _.key)) }, y)) })
2348
2352
  ] }),
2349
2353
  b()
2350
2354
  ] });
2351
- return l === "card" ? /* @__PURE__ */ w("div", { className: `card-view-wrapper ${y}`, children: [
2355
+ return l === "card" ? /* @__PURE__ */ w("div", { className: `card-view-wrapper ${g}`, children: [
2352
2356
  /* @__PURE__ */ e("div", { className: `card-view-header table-header-cell-${t}`, children: a.map((m) => /* @__PURE__ */ w(
2353
2357
  "div",
2354
2358
  {
2355
2359
  className: `card-view-header-cell ${m.sortable ? "sortable" : ""}`,
2356
- onClick: () => g(m),
2360
+ onClick: () => f(m),
2357
2361
  style: { minWidth: m.minWidth },
2358
2362
  children: [
2359
2363
  m.header,
2360
- p(m)
2364
+ h(m)
2361
2365
  ]
2362
2366
  },
2363
2367
  m.key
2364
2368
  )) }),
2365
- /* @__PURE__ */ e("div", { className: "card-view-body", children: f.length === 0 ? /* @__PURE__ */ e("div", { className: `card-view-row table-row-${t}`, style: { justifyContent: "center", padding: "2rem" }, children: "Nenhum resultado encontrado" }) : f.map((m, h) => /* @__PURE__ */ e("div", { className: `card-view-row table-row-${t}`, children: a.map((_) => /* @__PURE__ */ e("div", { className: `card-view-cell ${_.align ? `table-cell-align-${_.align}` : ""}`, style: { minWidth: _.minWidth }, children: _.render ? _.render(m) : m[_.key] }, _.key)) }, h)) }),
2369
+ /* @__PURE__ */ e("div", { className: "card-view-body", children: p.length === 0 ? /* @__PURE__ */ e("div", { className: `card-view-row table-row-${t}`, style: { justifyContent: "center", padding: "2rem" }, children: "Nenhum resultado encontrado" }) : p.map((m, y) => /* @__PURE__ */ e("div", { className: `card-view-row table-row-${t}`, children: a.map((_) => /* @__PURE__ */ e("div", { className: `card-view-cell ${_.align ? `table-cell-align-${_.align}` : ""}`, style: { minWidth: _.minWidth }, children: _.render ? _.render(m) : m[_.key] }, _.key)) }, y)) }),
2366
2370
  b()
2367
2371
  ] }) : N;
2368
2372
  }, oa = ({
@@ -2439,20 +2443,20 @@ const Xe = (t) => `${t / 12 * 100}%`, Ye = (t) => `${t / 12 * 100}%`, Ze = ({
2439
2443
  children: d,
2440
2444
  as: i = "div",
2441
2445
  style: u,
2442
- ...g
2446
+ ...f
2443
2447
  }) => {
2444
- const f = { ...u }, p = (N, m) => {
2448
+ const p = { ...u }, h = (N, m) => {
2445
2449
  if (m === void 0) return;
2446
- const h = `--clarity-col-width-${N}`;
2447
- f[h] = typeof m == "number" ? Xe(m) : "auto";
2448
- }, y = (N, m) => {
2450
+ const y = `--clarity-col-width-${N}`;
2451
+ p[y] = typeof m == "number" ? Xe(m) : "auto";
2452
+ }, g = (N, m) => {
2449
2453
  if (m === void 0) return;
2450
- const h = `--clarity-col-offset-${N}`;
2451
- f[h] = Ye(m);
2454
+ const y = `--clarity-col-offset-${N}`;
2455
+ p[y] = Ye(m);
2452
2456
  };
2453
- p("xs", a), p("sm", r), p("md", l), p("lg", n), p("xl", o), p("xxl", s), y("xs", c == null ? void 0 : c.xs), y("sm", c == null ? void 0 : c.sm), y("md", c == null ? void 0 : c.md), y("lg", c == null ? void 0 : c.lg), y("xl", c == null ? void 0 : c.xl), y("xxl", c == null ? void 0 : c.xxl);
2457
+ h("xs", a), h("sm", r), h("md", l), h("lg", n), h("xl", o), h("xxl", s), g("xs", c == null ? void 0 : c.xs), g("sm", c == null ? void 0 : c.sm), g("md", c == null ? void 0 : c.md), g("lg", c == null ? void 0 : c.lg), g("xl", c == null ? void 0 : c.xl), g("xxl", c == null ? void 0 : c.xxl);
2454
2458
  const b = ["clarity-col", t].filter(Boolean).join(" ");
2455
- return I.createElement(i, { className: b, style: f, ...g }, d);
2459
+ return I.createElement(i, { className: b, style: p, ...f }, d);
2456
2460
  };
2457
2461
  Ze.displayName = "Col";
2458
2462
  const he = ({ children: t, className: a, ...r }) => /* @__PURE__ */ e("div", { className: `clarity-card__header ${a || ""}`, ...r, children: t });