beth-clarity 1.1.21 → 1.2.1

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,7 +1,7 @@
1
- import { jsx as a, jsxs as w, Fragment as ot } from "react/jsx-runtime";
2
- import E, { useState as T, useRef as M, useEffect as D, forwardRef as ct, isValidElement as se, createContext as Q, cloneElement as z, useContext as Z, useMemo as te, useCallback as ce, useLayoutEffect as dt } from "react";
3
- import mt from "react-dom";
4
- const Dt = ({
1
+ import { jsx as a, jsxs as _, Fragment as Ze } from "react/jsx-runtime";
2
+ import B, { useState as x, useRef as P, useEffect as O, forwardRef as Ke, isValidElement as Z, createContext as U, cloneElement as W, useContext as q, useMemo as Y, useCallback as le, useLayoutEffect as et } from "react";
3
+ import tt from "react-dom";
4
+ const xt = ({
5
5
  variant: e = "primary",
6
6
  product: t,
7
7
  tone: s,
@@ -9,21 +9,21 @@ const Dt = ({
9
9
  bgColor: l,
10
10
  textColor: i,
11
11
  children: d,
12
- className: o = "",
12
+ className: c = "",
13
13
  rounded: r = !1,
14
- outlined: c = !1,
15
- ...p
14
+ outlined: o = !1,
15
+ ...u
16
16
  }) => {
17
17
  const v = "clarity-badge", m = !!l, f = t && s && !m;
18
- let u = "";
19
- m ? u = `${v}--custom-bg` : f ? u = `${v}--custom` : u = `${v}--${e}`;
18
+ let p = "";
19
+ m ? p = `${v}--custom-bg` : f ? p = `${v}--custom` : p = `${v}--${e}`;
20
20
  const h = [
21
21
  v,
22
- u,
22
+ p,
23
23
  `${v}--${n}`,
24
24
  r ? `${v}--rounded` : "",
25
- c ? `${v}--outlined` : "",
26
- o
25
+ o ? `${v}--outlined` : "",
26
+ c
27
27
  ].filter(Boolean).join(" "), y = {};
28
28
  m && (y.backgroundColor = l, i && (y.color = i));
29
29
  const b = f && t && s ? {
@@ -38,124 +38,11 @@ const Dt = ({
38
38
  ...y,
39
39
  ...b
40
40
  },
41
- ...p,
41
+ ...u,
42
42
  children: d
43
43
  }
44
44
  );
45
- }, ve = {
46
- fontFamily: {
47
- sans: ["Inter", "system-ui", "sans-serif"],
48
- mono: ["Fira Code", "monospace"]
49
- },
50
- fontSize: {
51
- xs: "12px",
52
- sm: "14px",
53
- base: "16px",
54
- lg: "18px",
55
- xl: "20px",
56
- "2xl": "24px",
57
- "3xl": "30px"
58
- },
59
- fontWeight: {
60
- normal: 400,
61
- medium: 500,
62
- semibold: 600,
63
- bold: 700
64
- },
65
- letterSpacing: {
66
- tighter: "-0.05em",
67
- tight: "-0.025em",
68
- normal: "0em",
69
- wide: "0.025em",
70
- wider: "0.05em"
71
- }
72
- }, ue = (e) => {
73
- if (e) {
74
- if (e.startsWith("#") || e.startsWith("rgb") || e.startsWith("hsl") || e === "transparent")
75
- return e;
76
- if (e.includes(".")) {
77
- const [t, s] = e.split(".");
78
- return `var(--clarity-${t}-${s})`;
79
- }
80
- return `var(--clarity-${e})`;
81
- }
82
- }, U = (e) => e !== void 0 ? `var(--clarity-spacing-${e})` : void 0, de = E.forwardRef(({
83
- as: e,
84
- children: t,
85
- className: s,
86
- display: n,
87
- flexDirection: l,
88
- alignItems: i,
89
- justifyContent: d,
90
- gap: o,
91
- m: r,
92
- mt: c,
93
- mr: p,
94
- mb: v,
95
- ml: m,
96
- mx: f,
97
- my: u,
98
- p: h,
99
- pt: y,
100
- pr: b,
101
- pb: N,
102
- pl: B,
103
- px: x,
104
- py: _,
105
- bg: $,
106
- color: L,
107
- fontSize: k,
108
- fontWeight: j,
109
- textAlign: I,
110
- lineHeight: A,
111
- letterSpacing: O,
112
- borderRadius: g,
113
- boxShadow: V,
114
- borderWidth: H,
115
- borderTopWidth: W,
116
- borderRightWidth: q,
117
- borderBottomWidth: X,
118
- borderLeftWidth: F,
119
- borderXWidth: P,
120
- borderYWidth: Y,
121
- borderColor: le,
122
- ...re
123
- }, ie) => {
124
- const C = e || "div", S = (R, J) => {
125
- if (R === void 0 || R === 0) return;
126
- const rt = `var(--clarity-border-width-${R})`, it = J ? ue(J) : "currentColor";
127
- return `${rt} solid ${it}`;
128
- }, G = {
129
- display: n,
130
- flexDirection: l,
131
- alignItems: i,
132
- justifyContent: d,
133
- gap: U(o),
134
- marginTop: U(c ?? u ?? r),
135
- marginRight: U(p ?? f ?? r),
136
- marginBottom: U(v ?? u ?? r),
137
- marginLeft: U(m ?? f ?? r),
138
- paddingTop: U(y ?? _ ?? h),
139
- paddingRight: U(b ?? x ?? h),
140
- paddingBottom: U(N ?? _ ?? h),
141
- paddingLeft: U(B ?? x ?? h),
142
- backgroundColor: $ ? ue($) : void 0,
143
- color: L ? ue(L) : void 0,
144
- fontSize: k ? `var(--clarity-font-size-${k})` : void 0,
145
- fontWeight: j ? ve.fontWeight[j] : void 0,
146
- textAlign: I,
147
- lineHeight: A,
148
- letterSpacing: O ? ve.letterSpacing[O] : void 0,
149
- borderRadius: g ? `var(--clarity-radius-${g})` : void 0,
150
- boxShadow: V ? `var(--clarity-shadow-${V})` : void 0,
151
- border: S(H, le),
152
- borderTop: S(W ?? Y),
153
- borderRight: S(q ?? P),
154
- borderBottom: S(X ?? Y),
155
- borderLeft: S(F ?? P)
156
- };
157
- return /* @__PURE__ */ a(C, { ref: ie, className: `clarity-box ${s || ""}`.trim(), style: G, ...re, children: t });
158
- }), At = ({
45
+ }, Tt = ({
159
46
  variant: e = "primary",
160
47
  size: t = "medium",
161
48
  disabled: s = !1,
@@ -163,25 +50,25 @@ const Dt = ({
163
50
  children: l,
164
51
  onClick: i,
165
52
  type: d = "button",
166
- className: o = "",
53
+ className: c = "",
167
54
  title: r,
168
- customColor: c,
169
- customColorHover: p,
55
+ customColor: o,
56
+ customColorHover: u,
170
57
  ...v
171
58
  }) => {
172
59
  const m = "clarity-button", f = [
173
60
  m,
174
- !c && `${m}--${e}`,
61
+ !o && `${m}--${e}`,
175
62
  `${m}--${t}`,
176
63
  n && `${m}--loading`,
177
64
  s && `${m}--disabled`,
178
- o
179
- ].filter(Boolean).join(" "), u = {};
180
- return c && (u["--button-bg"] = c, u["--button-hover-bg"] = p || `${c}E6`, u["--button-border"] = c, u["--button-hover-border"] = p || `${c}E6`, u["--button-fg"] = "#fff"), /* @__PURE__ */ w(
65
+ c
66
+ ].filter(Boolean).join(" "), p = {};
67
+ return o && (p["--button-bg"] = o, p["--button-hover-bg"] = u || `${o}E6`, p["--button-border"] = o, p["--button-hover-border"] = u || `${o}E6`, p["--button-fg"] = "#fff"), /* @__PURE__ */ _(
181
68
  "button",
182
69
  {
183
70
  className: f,
184
- style: u,
71
+ style: p,
185
72
  disabled: s || n,
186
73
  onClick: i,
187
74
  type: d,
@@ -193,7 +80,7 @@ const Dt = ({
193
80
  ]
194
81
  }
195
82
  );
196
- }, Pt = ({
83
+ }, Bt = ({
197
84
  variant: e = "primary",
198
85
  size: t = "medium",
199
86
  filled: s = !0,
@@ -201,52 +88,52 @@ const Dt = ({
201
88
  value: l,
202
89
  multiple: i = !1,
203
90
  disabled: d = !1,
204
- onChange: o,
91
+ onChange: c,
205
92
  className: r = "",
206
- ...c
93
+ ...o
207
94
  }) => {
208
- const p = "clarity-button-group", v = `${p}--${e}`, m = [
209
- p,
95
+ const u = "clarity-button-group", v = `${u}--${e}`, m = [
96
+ u,
210
97
  v,
211
- `${p}--${t}`,
212
- !s && `${p}--outline`,
213
- d && `${p}--disabled`,
98
+ `${u}--${t}`,
99
+ !s && `${u}--outline`,
100
+ d && `${u}--disabled`,
214
101
  r
215
102
  ].filter(Boolean).join(" "), f = (h) => {
216
- if (d || !o) return;
103
+ if (d || !c) return;
217
104
  const y = n.find((b) => b.id === h);
218
105
  if (!(y != null && y.disabled))
219
106
  if (i) {
220
- const b = Array.isArray(l) ? l : [], N = b.includes(h) ? b.filter((B) => B !== h) : [...b, h];
221
- o(N);
107
+ const b = Array.isArray(l) ? l : [], C = b.includes(h) ? b.filter((j) => j !== h) : [...b, h];
108
+ c(C);
222
109
  } else
223
- o(h);
224
- }, u = (h) => i ? Array.isArray(l) && l.includes(h) : l === h;
110
+ c(h);
111
+ }, p = (h) => i ? Array.isArray(l) && l.includes(h) : l === h;
225
112
  return /* @__PURE__ */ a(
226
113
  "div",
227
114
  {
228
115
  className: m,
229
116
  role: "group",
230
- ...c,
117
+ ...o,
231
118
  children: n.map((h, y) => {
232
- const b = u(h.id), N = [
233
- `${p}__item`,
234
- b && `${p}__item--selected`,
235
- h.disabled && `${p}__item--disabled`,
236
- y === 0 && `${p}__item--first`,
237
- y === n.length - 1 && `${p}__item--last`
119
+ const b = p(h.id), C = [
120
+ `${u}__item`,
121
+ b && `${u}__item--selected`,
122
+ h.disabled && `${u}__item--disabled`,
123
+ y === 0 && `${u}__item--first`,
124
+ y === n.length - 1 && `${u}__item--last`
238
125
  ].filter(Boolean).join(" ");
239
- return /* @__PURE__ */ w(
126
+ return /* @__PURE__ */ _(
240
127
  "button",
241
128
  {
242
- className: N,
129
+ className: C,
243
130
  onClick: () => f(h.id),
244
131
  disabled: d || h.disabled,
245
132
  type: "button",
246
133
  "aria-pressed": b,
247
134
  children: [
248
- h.icon && /* @__PURE__ */ a("span", { className: `${p}__item-icon`, children: h.icon }),
249
- /* @__PURE__ */ a("span", { className: `${p}__item-label`, children: h.label })
135
+ h.icon && /* @__PURE__ */ a("span", { className: `${u}__item-icon`, children: h.icon }),
136
+ /* @__PURE__ */ a("span", { className: `${u}__item-label`, children: h.label })
250
137
  ]
251
138
  },
252
139
  h.id
@@ -254,7 +141,7 @@ const Dt = ({
254
141
  })
255
142
  }
256
143
  );
257
- }, ut = E.forwardRef(({
144
+ }, st = B.forwardRef(({
258
145
  variant: e,
259
146
  size: t = "medium",
260
147
  label: s,
@@ -262,63 +149,63 @@ const Dt = ({
262
149
  error: l = !1,
263
150
  errorMessage: i,
264
151
  startIcon: d,
265
- endIcon: o,
152
+ endIcon: c,
266
153
  className: r = "",
267
- disabled: c = !1,
268
- value: p,
154
+ disabled: o = !1,
155
+ value: u,
269
156
  defaultValue: v,
270
157
  onFocus: m,
271
158
  onBlur: f,
272
- ...u
159
+ ...p
273
160
  }, h) => {
274
- const [y, b] = T(!1), [N, B] = T(!1), x = M(null);
275
- E.useImperativeHandle(h, () => x.current), D(() => {
276
- const k = x.current;
277
- k && B(k.value.length > 0);
278
- }, [p, v]);
279
- const _ = (k) => {
161
+ const [y, b] = x(!1), [C, j] = x(!1), T = P(null);
162
+ B.useImperativeHandle(h, () => T.current), O(() => {
163
+ const k = T.current;
164
+ k && j(k.value.length > 0);
165
+ }, [u, v]);
166
+ const w = (k) => {
280
167
  b(!0), m == null || m(k);
281
168
  }, $ = (k) => {
282
- b(!1), B(k.target.value.length > 0), f == null || f(k);
283
- }, L = [
169
+ b(!1), j(k.target.value.length > 0), f == null || f(k);
170
+ }, S = [
284
171
  "clarity-input",
285
172
  "clarity-input--outlined",
286
173
  `clarity-input--${t}`,
287
174
  e && `clarity-input--${e}`,
288
175
  l && "clarity-input--error",
289
- c && "clarity-input--disabled",
176
+ o && "clarity-input--disabled",
290
177
  y && "clarity-input--focused",
291
- N && "clarity-input--has-value",
178
+ C && "clarity-input--has-value",
292
179
  d && "clarity-input--with-start-icon",
293
- o && "clarity-input--with-end-icon",
180
+ c && "clarity-input--with-end-icon",
294
181
  r
295
182
  ].filter(Boolean).join(" ");
296
- return /* @__PURE__ */ w("div", { className: "clarity-input-wrapper", children: [
297
- /* @__PURE__ */ w("div", { className: L, children: [
183
+ return /* @__PURE__ */ _("div", { className: "clarity-input-wrapper", children: [
184
+ /* @__PURE__ */ _("div", { className: S, children: [
298
185
  d && /* @__PURE__ */ a("div", { className: "clarity-input__start-icon", children: d }),
299
- /* @__PURE__ */ w("div", { className: "clarity-input__field", children: [
186
+ /* @__PURE__ */ _("div", { className: "clarity-input__field", children: [
300
187
  /* @__PURE__ */ a(
301
188
  "input",
302
189
  {
303
- ref: x,
190
+ ref: T,
304
191
  className: "clarity-input__element",
305
- disabled: c,
306
- value: p,
192
+ disabled: o,
193
+ value: u,
307
194
  defaultValue: v,
308
- onFocus: _,
195
+ onFocus: w,
309
196
  onBlur: $,
310
- ...u
197
+ ...p
311
198
  }
312
199
  ),
313
200
  s && /* @__PURE__ */ a("label", { className: "clarity-input__label", children: s })
314
201
  ] }),
315
- o && /* @__PURE__ */ a("div", { className: "clarity-input__end-icon", children: o })
202
+ c && /* @__PURE__ */ a("div", { className: "clarity-input__end-icon", children: c })
316
203
  ] }),
317
204
  (n || l && i) && /* @__PURE__ */ a("div", { className: "clarity-input__helper-text", children: l && i ? i : n })
318
205
  ] });
319
206
  });
320
- ut.displayName = "Input";
321
- const pt = E.forwardRef(({
207
+ st.displayName = "Input";
208
+ const at = B.forwardRef(({
322
209
  variant: e,
323
210
  size: t = "medium",
324
211
  label: s,
@@ -326,73 +213,73 @@ const pt = E.forwardRef(({
326
213
  error: l = !1,
327
214
  errorMessage: i,
328
215
  startIcon: d,
329
- endIcon: o,
216
+ endIcon: c,
330
217
  className: r = "",
331
- disabled: c = !1,
332
- value: p,
218
+ disabled: o = !1,
219
+ value: u,
333
220
  defaultValue: v,
334
221
  onFocus: m,
335
222
  onBlur: f,
336
- rows: u = 3,
223
+ rows: p = 3,
337
224
  minHeight: h,
338
225
  maxHeight: y,
339
226
  resizable: b = !0,
340
- ...N
341
- }, B) => {
342
- const [x, _] = T(!1), [$, L] = T(!1), k = M(null);
343
- E.useImperativeHandle(B, () => k.current), D(() => {
227
+ ...C
228
+ }, j) => {
229
+ const [T, w] = x(!1), [$, S] = x(!1), k = P(null);
230
+ B.useImperativeHandle(j, () => k.current), O(() => {
344
231
  const g = k.current;
345
- g && L(g.value.length > 0);
346
- }, [p, v]);
347
- const j = (g) => {
348
- _(!0), m == null || m(g);
349
- }, I = (g) => {
350
- _(!1), L(g.target.value.length > 0), f == null || f(g);
232
+ g && S(g.value.length > 0);
233
+ }, [u, v]);
234
+ const E = (g) => {
235
+ w(!0), m == null || m(g);
236
+ }, R = (g) => {
237
+ w(!1), S(g.target.value.length > 0), f == null || f(g);
351
238
  }, A = [
352
239
  "clarity-textarea",
353
240
  "clarity-textarea--outlined",
354
241
  `clarity-textarea--${t}`,
355
242
  e && `clarity-textarea--${e}`,
356
243
  l && "clarity-textarea--error",
357
- c && "clarity-textarea--disabled",
358
- x && "clarity-textarea--focused",
244
+ o && "clarity-textarea--disabled",
245
+ T && "clarity-textarea--focused",
359
246
  $ && "clarity-textarea--has-value",
360
247
  d && "clarity-textarea--with-start-icon",
361
- o && "clarity-textarea--with-end-icon",
248
+ c && "clarity-textarea--with-end-icon",
362
249
  r
363
- ].filter(Boolean).join(" "), O = {
250
+ ].filter(Boolean).join(" "), I = {
364
251
  resize: b ? "vertical" : "none",
365
252
  minHeight: h ? `${h}px` : void 0,
366
253
  maxHeight: y ? `${y}px` : void 0
367
254
  };
368
- return /* @__PURE__ */ w("div", { className: "clarity-textarea-wrapper", children: [
369
- /* @__PURE__ */ w("div", { className: A, children: [
255
+ return /* @__PURE__ */ _("div", { className: "clarity-textarea-wrapper", children: [
256
+ /* @__PURE__ */ _("div", { className: A, children: [
370
257
  d && /* @__PURE__ */ a("div", { className: "clarity-textarea__start-icon", children: d }),
371
- /* @__PURE__ */ w("div", { className: "clarity-textarea__field", children: [
258
+ /* @__PURE__ */ _("div", { className: "clarity-textarea__field", children: [
372
259
  /* @__PURE__ */ a(
373
260
  "textarea",
374
261
  {
375
262
  ref: k,
376
263
  className: "clarity-textarea__element",
377
- disabled: c,
378
- value: p,
264
+ disabled: o,
265
+ value: u,
379
266
  defaultValue: v,
380
- onFocus: j,
381
- onBlur: I,
382
- rows: u,
383
- style: O,
384
- ...N
267
+ onFocus: E,
268
+ onBlur: R,
269
+ rows: p,
270
+ style: I,
271
+ ...C
385
272
  }
386
273
  ),
387
274
  s && /* @__PURE__ */ a("label", { className: "clarity-textarea__label", children: s })
388
275
  ] }),
389
- o && /* @__PURE__ */ a("div", { className: "clarity-textarea__end-icon", children: o })
276
+ c && /* @__PURE__ */ a("div", { className: "clarity-textarea__end-icon", children: c })
390
277
  ] }),
391
278
  (n || l && i) && /* @__PURE__ */ a("div", { className: "clarity-textarea__helper-text", children: l && i ? i : n })
392
279
  ] });
393
280
  });
394
- pt.displayName = "Textarea";
395
- const ft = E.forwardRef(({
281
+ at.displayName = "Textarea";
282
+ const nt = B.forwardRef(({
396
283
  variant: e,
397
284
  size: t = "medium",
398
285
  label: s,
@@ -400,99 +287,101 @@ const ft = E.forwardRef(({
400
287
  error: l = !1,
401
288
  errorMessage: i,
402
289
  startIcon: d,
403
- endIcon: o,
290
+ endIcon: c,
404
291
  className: r = "",
405
- disabled: c = !1,
406
- value: p,
292
+ disabled: o = !1,
293
+ value: u,
407
294
  defaultValue: v,
408
295
  onFocus: m,
409
296
  onBlur: f,
410
- onChange: u,
297
+ onChange: p,
411
298
  options: h,
412
299
  placeholder: y = "Selecione uma opção",
413
300
  isClearable: b = !1,
414
- isSearchable: N = !1,
415
- ...B
416
- }, x) => {
417
- const [_, $] = T(!1), [L, k] = T(!1), [j, I] = T(p || v || ""), [A, O] = T(""), g = M(null), V = M(null);
418
- E.useImperativeHandle(x, () => g.current), D(() => {
419
- p !== void 0 && I(p);
420
- }, [p]), D(() => {
421
- const C = (S) => {
422
- g.current && !g.current.contains(S.target) && ($(!1), k(!1), f == null || f());
301
+ isSearchable: C = !1,
302
+ ...j
303
+ }, T) => {
304
+ const [w, $] = x(!1), [S, k] = x(!1), [E, R] = x(u || v || ""), [A, I] = x(""), g = P(null), H = P(null);
305
+ B.useImperativeHandle(T, () => g.current), O(() => {
306
+ u !== void 0 && R(u);
307
+ }, [u]), O(() => {
308
+ const N = (L) => {
309
+ g.current && !g.current.contains(L.target) && ($(!1), k(!1), f == null || f());
423
310
  };
424
- return document.addEventListener("mousedown", C), () => document.removeEventListener("mousedown", C);
311
+ return document.addEventListener("mousedown", N), () => document.removeEventListener("mousedown", N);
425
312
  }, [f]);
426
- const H = N && A ? h.filter(
427
- (C) => C.label.toLowerCase().includes(A.toLowerCase())
428
- ) : h, W = () => {
429
- c || ($(!_), k(!_), _ ? (f == null || f(), N && O("")) : (m == null || m(), N && setTimeout(() => {
430
- var C;
431
- (C = V.current) == null || C.focus();
313
+ const V = C && A ? h.filter(
314
+ (N) => N.label.toLowerCase().includes(A.toLowerCase())
315
+ ) : h, F = () => {
316
+ o || ($(!w), k(!w), w ? (f == null || f(), C && I("")) : (m == null || m(), C && setTimeout(() => {
317
+ var N;
318
+ (N = H.current) == null || N.focus();
432
319
  }, 0)));
433
- }, q = (C) => {
434
- C.disabled || (I(C.value), $(!1), k(!1), O(""), u == null || u(C.value), f == null || f());
435
- }, X = (C) => {
436
- O(C.target.value);
437
- }, F = (C) => {
438
- C.key === "Escape" ? ($(!1), k(!1), O("")) : C.key === "Enter" && H.length > 0 && H[0] && q(H[0]);
439
- }, P = h.find((C) => C.value === j), Y = j !== "" && j !== void 0, le = (C) => {
440
- C.stopPropagation(), I(""), u == null || u("");
441
- }, re = Y || L || y || N && A, ie = [
320
+ }, X = (N, L) => {
321
+ N.disabled || (R(N.value), $(!1), k(!1), I(""), p == null || p(N, L), f == null || f());
322
+ }, te = (N) => {
323
+ I(N.target.value);
324
+ }, G = (N) => {
325
+ N.key === "Escape" ? ($(!1), k(!1), I("")) : N.key === "Enter" && V.length > 0 && V[0] && X(V[0], N);
326
+ }, M = h.find((N) => N.value === E), ne = E !== "" && E !== void 0, ie = (N) => {
327
+ N.stopPropagation(), R("");
328
+ const L = { value: "", label: "" };
329
+ p == null || p(L, N);
330
+ }, re = ne || S || y || C && A, ce = [
442
331
  "clarity-select",
443
332
  "clarity-select--outlined",
444
333
  `clarity-select--${t}`,
445
334
  e && `clarity-select--${e}`,
446
335
  l && "clarity-select--error",
447
- c && "clarity-select--disabled",
448
- (L || _) && "clarity-select--focused",
336
+ o && "clarity-select--disabled",
337
+ (S || w) && "clarity-select--focused",
449
338
  re && "clarity-select--label-up",
450
- _ && "clarity-select--open",
451
- N && "clarity-select--searchable",
339
+ w && "clarity-select--open",
340
+ C && "clarity-select--searchable",
452
341
  d && "clarity-select--with-start-icon",
453
- (o || b) && "clarity-select--with-end-icon",
342
+ (c || b) && "clarity-select--with-end-icon",
454
343
  r
455
344
  ].filter(Boolean).join(" ");
456
- return /* @__PURE__ */ w("div", { className: "clarity-select-wrapper", children: [
457
- /* @__PURE__ */ w(
345
+ return /* @__PURE__ */ _("div", { className: "clarity-select-wrapper", children: [
346
+ /* @__PURE__ */ _(
458
347
  "div",
459
348
  {
460
349
  ref: g,
461
- className: ie,
462
- onClick: N ? void 0 : W,
350
+ className: ce,
351
+ onClick: C ? void 0 : F,
463
352
  role: "combobox",
464
- "aria-expanded": _,
353
+ "aria-expanded": w,
465
354
  "aria-haspopup": "listbox",
466
- tabIndex: c || N ? -1 : 0,
467
- ...B,
355
+ tabIndex: o || C ? -1 : 0,
356
+ ...j,
468
357
  children: [
469
358
  d && /* @__PURE__ */ a("div", { className: "clarity-select__start-icon", children: d }),
470
- /* @__PURE__ */ w("div", { className: "clarity-select__field", children: [
471
- N ? /* @__PURE__ */ a(
359
+ /* @__PURE__ */ _("div", { className: "clarity-select__field", children: [
360
+ C ? /* @__PURE__ */ a(
472
361
  "input",
473
362
  {
474
- ref: V,
363
+ ref: H,
475
364
  type: "text",
476
365
  className: "clarity-select__search-input",
477
- value: _ ? A : P ? P.label : "",
478
- onChange: X,
479
- onKeyDown: F,
366
+ value: w ? A : M ? M.label : "",
367
+ onChange: te,
368
+ onKeyDown: G,
480
369
  onFocus: () => {
481
- _ || ($(!0), k(!0), m == null || m());
370
+ w || ($(!0), k(!0), m == null || m());
482
371
  },
483
- placeholder: P ? P.label : y,
484
- disabled: c,
485
- readOnly: !_
372
+ placeholder: M ? M.label : y,
373
+ disabled: o,
374
+ readOnly: !w
486
375
  }
487
- ) : /* @__PURE__ */ a("div", { className: "clarity-select__display", children: P ? P.label : y }),
376
+ ) : /* @__PURE__ */ a("div", { className: "clarity-select__display", children: M ? M.label : y }),
488
377
  s && /* @__PURE__ */ a("label", { className: "clarity-select__label", children: s })
489
378
  ] }),
490
- b && Y && /* @__PURE__ */ a(
379
+ b && ne && /* @__PURE__ */ a(
491
380
  "button",
492
381
  {
493
382
  type: "button",
494
383
  className: "clarity-select__clear-button",
495
- onClick: le,
384
+ onClick: ie,
496
385
  "aria-label": "Limpar seleção",
497
386
  children: /* @__PURE__ */ a(
498
387
  "svg",
@@ -519,8 +408,8 @@ const ft = E.forwardRef(({
519
408
  "div",
520
409
  {
521
410
  className: "clarity-select__end-icon",
522
- onClick: N ? W : void 0,
523
- children: o || /* @__PURE__ */ a(
411
+ onClick: C ? F : void 0,
412
+ children: c || /* @__PURE__ */ a(
524
413
  "svg",
525
414
  {
526
415
  className: "clarity-select__arrow",
@@ -542,20 +431,20 @@ const ft = E.forwardRef(({
542
431
  )
543
432
  }
544
433
  ),
545
- _ && /* @__PURE__ */ a("div", { className: "clarity-select__dropdown", children: /* @__PURE__ */ a("ul", { className: "clarity-select__options", role: "listbox", children: H.length > 0 ? H.map((C) => /* @__PURE__ */ a(
434
+ w && /* @__PURE__ */ a("div", { className: "clarity-select__dropdown", children: /* @__PURE__ */ a("ul", { className: "clarity-select__options", role: "listbox", children: V.length > 0 ? V.map((N) => /* @__PURE__ */ a(
546
435
  "li",
547
436
  {
548
437
  className: [
549
438
  "clarity-select__option",
550
- C.disabled && "clarity-select__option--disabled",
551
- j === C.value && "clarity-select__option--selected"
439
+ N.disabled && "clarity-select__option--disabled",
440
+ E === N.value && "clarity-select__option--selected"
552
441
  ].filter(Boolean).join(" "),
553
- onClick: () => q(C),
442
+ onClick: (L) => X(N, L),
554
443
  role: "option",
555
- "aria-selected": j === C.value,
556
- children: C.label
444
+ "aria-selected": E === N.value,
445
+ children: N.label
557
446
  },
558
- C.value
447
+ N.value
559
448
  )) : /* @__PURE__ */ a("li", { className: "clarity-select__option clarity-select__option--no-results", children: "Nenhum resultado encontrado" }) }) })
560
449
  ]
561
450
  }
@@ -563,8 +452,8 @@ const ft = E.forwardRef(({
563
452
  (n || l && i) && /* @__PURE__ */ a("div", { className: "clarity-select__helper-text", children: l && i ? i : n })
564
453
  ] });
565
454
  });
566
- ft.displayName = "Select";
567
- const ht = ct(({
455
+ nt.displayName = "Select";
456
+ const lt = Ke(({
568
457
  options: e = [],
569
458
  value: t = [],
570
459
  onChange: s,
@@ -572,118 +461,118 @@ const ht = ct(({
572
461
  label: l,
573
462
  helperText: i,
574
463
  error: d = !1,
575
- errorMessage: o,
464
+ errorMessage: c,
576
465
  disabled: r = !1,
577
- variant: c = "primary",
578
- size: p = "medium",
466
+ variant: o = "primary",
467
+ size: u = "medium",
579
468
  maxSelectedLabels: v = 3,
580
469
  selectionLimit: m,
581
470
  className: f = "",
582
- id: u,
471
+ id: p,
583
472
  name: h,
584
473
  required: y = !1,
585
474
  "data-testid": b,
586
- ...N
587
- }, B) => {
588
- const [x, _] = T(!1), [$, L] = T(""), [k, j] = T(!1), I = M(null), A = M(null), O = M(null), g = (C) => {
589
- I.current = C, B && (typeof B == "function" ? B(C) : B.current = C);
475
+ ...C
476
+ }, j) => {
477
+ const [T, w] = x(!1), [$, S] = x(""), [k, E] = x(!1), R = P(null), A = P(null), I = P(null), g = (N) => {
478
+ R.current = N, j && (typeof j == "function" ? j(N) : j.current = N);
590
479
  };
591
- D(() => {
592
- const C = (S) => {
593
- I.current && !I.current.contains(S.target) && (_(!1), j(!1), L(""));
480
+ O(() => {
481
+ const N = (L) => {
482
+ R.current && !R.current.contains(L.target) && (w(!1), E(!1), S(""));
594
483
  };
595
- return document.addEventListener("click", C), () => document.removeEventListener("click", C);
484
+ return document.addEventListener("click", N), () => document.removeEventListener("click", N);
596
485
  }, []);
597
- const V = e.filter(
598
- (C) => C.label.toLowerCase().includes($.toLowerCase())
599
- ), H = () => {
600
- r || (_(!x), j(!x), x ? L("") : setTimeout(() => {
601
- var C;
602
- (C = A.current) == null || C.focus();
486
+ const H = e.filter(
487
+ (N) => N.label.toLowerCase().includes($.toLowerCase())
488
+ ), V = () => {
489
+ r || (w(!T), E(!T), T ? S("") : setTimeout(() => {
490
+ var N;
491
+ (N = A.current) == null || N.focus();
603
492
  }, 100));
604
- }, W = (C, S) => {
493
+ }, F = (N, L) => {
605
494
  if (r)
606
495
  return;
607
- S && (S.stopPropagation(), S.preventDefault());
608
- const G = t.includes(C);
609
- let R;
610
- G ? R = t.filter((J) => J !== C) : R = [...t, C], s && s(R);
611
- }, q = (C, S) => {
612
- if (S.stopPropagation(), r) return;
613
- const G = t.filter((R) => R !== C);
614
- s == null || s(G);
615
- }, X = (C) => {
616
- C.stopPropagation(), !r && (s == null || s([]));
617
- }, F = (C) => {
618
- L(C.target.value);
619
- }, P = (C) => {
620
- C.key === "Escape" && (_(!1), j(!1), L(""));
621
- }, Y = k || x || t.length > 0, le = () => {
496
+ L && (L.stopPropagation(), L.preventDefault());
497
+ const z = t.includes(N);
498
+ let D;
499
+ z ? D = t.filter((se) => se !== N) : D = [...t, N], s && s(D);
500
+ }, X = (N, L) => {
501
+ if (L.stopPropagation(), r) return;
502
+ const z = t.filter((D) => D !== N);
503
+ s == null || s(z);
504
+ }, te = (N) => {
505
+ N.stopPropagation(), !r && (s == null || s([]));
506
+ }, G = (N) => {
507
+ S(N.target.value);
508
+ }, M = (N) => {
509
+ N.key === "Escape" && (w(!1), E(!1), S(""));
510
+ }, ne = k || T || t.length > 0, ie = () => {
622
511
  if (t.length === 0) return null;
623
- const C = t.map(
624
- (R) => e.find((J) => J.value === R)
625
- ).filter(Boolean), S = C.slice(0, v), G = C.length - v;
626
- return /* @__PURE__ */ w("div", { className: "clarity-multiselect__chips", children: [
627
- S.map((R) => /* @__PURE__ */ w("div", { className: "clarity-multiselect__chip", children: [
628
- /* @__PURE__ */ a("span", { className: "clarity-multiselect__chip-label", children: R.label }),
512
+ const N = t.map(
513
+ (D) => e.find((se) => se.value === D)
514
+ ).filter(Boolean), L = N.slice(0, v), z = N.length - v;
515
+ return /* @__PURE__ */ _("div", { className: "clarity-multiselect__chips", children: [
516
+ L.map((D) => /* @__PURE__ */ _("div", { className: "clarity-multiselect__chip", children: [
517
+ /* @__PURE__ */ a("span", { className: "clarity-multiselect__chip-label", children: D.label }),
629
518
  !r && /* @__PURE__ */ a(
630
519
  "button",
631
520
  {
632
521
  type: "button",
633
522
  className: "clarity-multiselect__chip-remove",
634
- onClick: (J) => q(R.value, J),
635
- "aria-label": `Remover ${R.label}`,
523
+ onClick: (se) => X(D.value, se),
524
+ "aria-label": `Remover ${D.label}`,
636
525
  children: "×"
637
526
  }
638
527
  )
639
- ] }, R.value)),
640
- G > 0 && /* @__PURE__ */ w("div", { className: "clarity-multiselect__chip clarity-multiselect__chip--count", children: [
528
+ ] }, D.value)),
529
+ z > 0 && /* @__PURE__ */ _("div", { className: "clarity-multiselect__chip clarity-multiselect__chip--count", children: [
641
530
  "+",
642
- G,
531
+ z,
643
532
  " mais"
644
533
  ] })
645
534
  ] });
646
535
  }, re = [
647
536
  "clarity-multiselect-wrapper",
648
537
  f
649
- ].filter(Boolean).join(" "), ie = [
538
+ ].filter(Boolean).join(" "), ce = [
650
539
  "clarity-multiselect",
651
- `clarity-multiselect--${c}`,
652
- `clarity-multiselect--${p}`,
653
- x && "clarity-multiselect--open",
540
+ `clarity-multiselect--${o}`,
541
+ `clarity-multiselect--${u}`,
542
+ T && "clarity-multiselect--open",
654
543
  k && "clarity-multiselect--focused",
655
- Y && "clarity-multiselect--label-up",
544
+ ne && "clarity-multiselect--label-up",
656
545
  d && "clarity-multiselect--error",
657
546
  r && "clarity-multiselect--disabled",
658
547
  t.length > 0 && "clarity-multiselect--has-value"
659
548
  ].filter(Boolean).join(" ");
660
- return /* @__PURE__ */ w("div", { className: re, children: [
661
- /* @__PURE__ */ w(
549
+ return /* @__PURE__ */ _("div", { className: re, children: [
550
+ /* @__PURE__ */ _(
662
551
  "div",
663
552
  {
664
553
  ref: g,
665
- className: ie,
554
+ className: ce,
666
555
  "data-testid": b,
667
- ...N,
556
+ ...C,
668
557
  children: [
669
- /* @__PURE__ */ w(
558
+ /* @__PURE__ */ _(
670
559
  "div",
671
560
  {
672
561
  className: "clarity-multiselect__field",
673
- onClick: H,
562
+ onClick: V,
674
563
  children: [
675
- l && /* @__PURE__ */ w("label", { className: "clarity-multiselect__label", children: [
564
+ l && /* @__PURE__ */ _("label", { className: "clarity-multiselect__label", children: [
676
565
  l,
677
566
  y && /* @__PURE__ */ a("span", { className: "clarity-multiselect__required", children: "*" })
678
567
  ] }),
679
- /* @__PURE__ */ a("div", { className: "clarity-multiselect__content", children: t.length > 0 ? le() : /* @__PURE__ */ a("span", { className: "clarity-multiselect__placeholder", children: n }) }),
680
- /* @__PURE__ */ w("div", { className: "clarity-multiselect__icons", children: [
568
+ /* @__PURE__ */ a("div", { className: "clarity-multiselect__content", children: t.length > 0 ? ie() : /* @__PURE__ */ a("span", { className: "clarity-multiselect__placeholder", children: n }) }),
569
+ /* @__PURE__ */ _("div", { className: "clarity-multiselect__icons", children: [
681
570
  t.length > 0 && !r && /* @__PURE__ */ a(
682
571
  "button",
683
572
  {
684
573
  type: "button",
685
574
  className: "clarity-multiselect__clear-button",
686
- onClick: X,
575
+ onClick: te,
687
576
  "aria-label": "Limpar seleção",
688
577
  children: "×"
689
578
  }
@@ -702,7 +591,7 @@ const ht = ct(({
702
591
  ]
703
592
  }
704
593
  ),
705
- x && /* @__PURE__ */ w("div", { ref: O, className: "clarity-multiselect__dropdown", children: [
594
+ T && /* @__PURE__ */ _("div", { ref: I, className: "clarity-multiselect__dropdown", children: [
706
595
  /* @__PURE__ */ a("div", { className: "clarity-multiselect__search", children: /* @__PURE__ */ a(
707
596
  "input",
708
597
  {
@@ -711,26 +600,26 @@ const ht = ct(({
711
600
  className: "clarity-multiselect__search-input",
712
601
  placeholder: "Buscar opções...",
713
602
  value: $,
714
- onChange: F,
715
- onKeyDown: P
603
+ onChange: G,
604
+ onKeyDown: M
716
605
  }
717
606
  ) }),
718
- /* @__PURE__ */ a("ul", { className: "clarity-multiselect__options", children: V.length > 0 ? V.map((C) => {
719
- const S = t.includes(C.value), G = C.disabled || r;
720
- return /* @__PURE__ */ w(
607
+ /* @__PURE__ */ a("ul", { className: "clarity-multiselect__options", children: H.length > 0 ? H.map((N) => {
608
+ const L = t.includes(N.value), z = N.disabled || r;
609
+ return /* @__PURE__ */ _(
721
610
  "li",
722
611
  {
723
612
  className: [
724
613
  "clarity-multiselect__option",
725
- S && "clarity-multiselect__option--selected",
726
- G && "clarity-multiselect__option--disabled"
614
+ L && "clarity-multiselect__option--selected",
615
+ z && "clarity-multiselect__option--disabled"
727
616
  ].filter(Boolean).join(" "),
728
- onClick: (R) => !G && W(C.value, R),
617
+ onClick: (D) => !z && F(N.value, D),
729
618
  children: [
730
619
  /* @__PURE__ */ a("div", { className: "clarity-multiselect__option-checkbox", children: /* @__PURE__ */ a("div", { className: [
731
620
  "clarity-multiselect__checkbox",
732
- S && "clarity-multiselect__checkbox--checked"
733
- ].filter(Boolean).join(" "), children: S && /* @__PURE__ */ a("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", children: /* @__PURE__ */ a(
621
+ L && "clarity-multiselect__checkbox--checked"
622
+ ].filter(Boolean).join(" "), children: L && /* @__PURE__ */ a("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", children: /* @__PURE__ */ a(
734
623
  "path",
735
624
  {
736
625
  d: "M2 6L5 9L10 3",
@@ -740,72 +629,72 @@ const ht = ct(({
740
629
  strokeLinejoin: "round"
741
630
  }
742
631
  ) }) }) }),
743
- /* @__PURE__ */ a("span", { className: "clarity-multiselect__option-label", children: C.label })
632
+ /* @__PURE__ */ a("span", { className: "clarity-multiselect__option-label", children: N.label })
744
633
  ]
745
634
  },
746
- C.value
635
+ N.value
747
636
  );
748
637
  }) : /* @__PURE__ */ a("li", { className: "clarity-multiselect__option clarity-multiselect__option--no-results", children: "Nenhum resultado encontrado" }) })
749
638
  ] })
750
639
  ]
751
640
  }
752
641
  ),
753
- (i || d && o) && /* @__PURE__ */ a("div", { className: "clarity-multiselect__helper", children: d && o ? /* @__PURE__ */ a("span", { className: "clarity-multiselect__error-message", children: o }) : i && /* @__PURE__ */ a("span", { className: "clarity-multiselect__helper-text", children: i }) })
642
+ (i || d && c) && /* @__PURE__ */ a("div", { className: "clarity-multiselect__helper", children: d && c ? /* @__PURE__ */ a("span", { className: "clarity-multiselect__error-message", children: c }) : i && /* @__PURE__ */ a("span", { className: "clarity-multiselect__helper-text", children: i }) })
754
643
  ] });
755
644
  });
756
- ht.displayName = "MultiSelect";
757
- const be = Q(null), Ce = () => {
758
- const e = Z(be);
645
+ lt.displayName = "MultiSelect";
646
+ const pe = U(null), fe = () => {
647
+ const e = q(pe);
759
648
  if (!e)
760
649
  throw new Error("useModal must be used within a Modal provider");
761
650
  return e;
762
- }, Ne = ({
651
+ }, he = ({
763
652
  children: e,
764
653
  className: t = "",
765
654
  title: s
766
655
  }) => {
767
- const { onClose: n, variant: l, showCloseButton: i } = Ce(), d = [
656
+ const { onClose: n, variant: l, showCloseButton: i } = fe(), d = [
768
657
  "clarity-modal-header",
769
658
  t,
770
659
  l && `clarity-modal-header--${l}`
771
- ].filter(Boolean).join(" "), o = [
660
+ ].filter(Boolean).join(" "), c = [
772
661
  "clarity-modal-close",
773
662
  l && `clarity-modal-close--${l}`
774
663
  ].filter(Boolean).join(" ");
775
- return /* @__PURE__ */ w("div", { className: d, children: [
664
+ return /* @__PURE__ */ _("div", { className: d, children: [
776
665
  s && /* @__PURE__ */ a("h2", { className: "clarity-modal-title", children: s }),
777
666
  e,
778
- i && /* @__PURE__ */ a("button", { className: o, onClick: (r) => {
667
+ i && /* @__PURE__ */ a("button", { className: c, onClick: (r) => {
779
668
  r.stopPropagation(), n();
780
669
  }, children: "×" })
781
670
  ] });
782
671
  };
783
- Ne.displayName = "Modal.Header";
784
- const we = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-modal-content ${t}`, children: e });
785
- we.displayName = "Modal.Content";
786
- const _e = ({ children: e, className: t = "" }) => /* @__PURE__ */ w("div", { className: `clarity-modal-footer ${t}`, children: [
672
+ he.displayName = "Modal.Header";
673
+ const ye = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-modal-content ${t}`, children: e });
674
+ ye.displayName = "Modal.Content";
675
+ const ve = ({ children: e, className: t = "" }) => /* @__PURE__ */ _("div", { className: `clarity-modal-footer ${t}`, children: [
787
676
  /* @__PURE__ */ a("div", { className: "clarity-modal-scroll-indicator" }),
788
677
  e
789
678
  ] });
790
- _e.displayName = "Modal.Footer";
791
- const ge = ({ children: e, onClick: t }) => z(e, {
679
+ ve.displayName = "Modal.Footer";
680
+ const Ne = ({ children: e, onClick: t }) => W(e, {
792
681
  onClick: (s) => {
793
682
  var n, l;
794
683
  t == null || t(), (l = (n = e.props).onClick) == null || l.call(n, s);
795
684
  }
796
685
  });
797
- ge.displayName = "Modal.Trigger";
798
- const $e = ({ children: e }) => {
799
- const { onClose: t } = Ce();
800
- return z(e, {
686
+ Ne.displayName = "Modal.Trigger";
687
+ const be = ({ children: e }) => {
688
+ const { onClose: t } = fe();
689
+ return W(e, {
801
690
  onClick: (s) => {
802
691
  var n, l;
803
692
  t(), (l = (n = e.props).onClick) == null || l.call(n, s);
804
693
  }
805
694
  });
806
695
  };
807
- $e.displayName = "Modal.Close";
808
- const K = ({
696
+ be.displayName = "Modal.Close";
697
+ const J = ({
809
698
  isOpen: e,
810
699
  onClose: t,
811
700
  onOpen: s,
@@ -813,57 +702,57 @@ const K = ({
813
702
  className: l = "",
814
703
  variant: i,
815
704
  size: d = "medium",
816
- showCloseButton: o = !0,
705
+ showCloseButton: c = !0,
817
706
  closeOnOverlayClick: r = !0
818
707
  }) => {
819
- const [c, p] = T(!1), m = e !== void 0 ? e : c, f = t || (() => {
820
- p(!1);
708
+ const [o, u] = x(!1), m = e !== void 0 ? e : o, f = t || (() => {
709
+ u(!1);
821
710
  });
822
- D(() => {
711
+ O(() => {
823
712
  m && (s == null || s());
824
- }, [m, s]), D(() => {
825
- const N = (B) => {
826
- B.key === "Escape" && f();
713
+ }, [m, s]), O(() => {
714
+ const C = (j) => {
715
+ j.key === "Escape" && f();
827
716
  };
828
- return m ? (document.addEventListener("keydown", N), document.body.style.overflow = "hidden") : document.body.style.overflow = "unset", () => {
829
- document.removeEventListener("keydown", N), document.body.style.overflow = "unset";
717
+ return m ? (document.addEventListener("keydown", C), document.body.style.overflow = "hidden") : document.body.style.overflow = "unset", () => {
718
+ document.removeEventListener("keydown", C), document.body.style.overflow = "unset";
830
719
  };
831
720
  }, [m, f]);
832
- const u = (N) => {
833
- r && N.target === N.currentTarget && f();
834
- }, h = E.Children.toArray(n).find(
835
- (N) => se(N) && N.type.displayName === "Modal.Trigger"
836
- ), y = E.Children.toArray(n).filter(
837
- (N) => se(N) && N.type.displayName !== "Modal.Trigger"
721
+ const p = (C) => {
722
+ r && C.target === C.currentTarget && f();
723
+ }, h = B.Children.toArray(n).find(
724
+ (C) => Z(C) && C.type.displayName === "Modal.Trigger"
725
+ ), y = B.Children.toArray(n).filter(
726
+ (C) => Z(C) && C.type.displayName !== "Modal.Trigger"
838
727
  ), b = ["clarity-modal", l, `clarity-modal--${d}`].filter(Boolean).join(" ");
839
- return /* @__PURE__ */ w(be.Provider, { value: { onClose: f, variant: i, showCloseButton: o }, children: [
840
- h && z(h, { onClick: () => p(!0) }),
841
- m && /* @__PURE__ */ a("div", { className: "clarity-modal-overlay", onClick: u, children: /* @__PURE__ */ a("div", { className: b, children: y }) })
728
+ return /* @__PURE__ */ _(pe.Provider, { value: { onClose: f, variant: i, showCloseButton: c }, children: [
729
+ h && W(h, { onClick: () => u(!0) }),
730
+ m && /* @__PURE__ */ a("div", { className: "clarity-modal-overlay", onClick: p, children: /* @__PURE__ */ a("div", { className: b, children: y }) })
842
731
  ] });
843
732
  };
844
- K.Header = Ne;
845
- K.Content = we;
846
- K.Footer = _e;
847
- K.Trigger = ge;
848
- K.Close = $e;
849
- K.displayName = "Modal";
850
- const ke = Q(void 0), Vt = () => {
851
- const e = Z(ke);
733
+ J.Header = he;
734
+ J.Content = ye;
735
+ J.Footer = ve;
736
+ J.Trigger = Ne;
737
+ J.Close = be;
738
+ J.displayName = "Modal";
739
+ const Ce = U(void 0), jt = () => {
740
+ const e = q(Ce);
852
741
  if (!e)
853
742
  throw new Error("useToast must be used within a ToastProvider");
854
743
  return e;
855
- }, yt = ({ id: e, message: t, variant: s, duration: n, onClose: l, invertColors: i }) => {
856
- const [d, o] = T("entering");
857
- D(() => {
858
- const c = setTimeout(() => {
859
- o("visible");
860
- }, 10), p = setTimeout(() => {
861
- o("exiting");
744
+ }, it = ({ id: e, message: t, variant: s, duration: n, onClose: l, invertColors: i }) => {
745
+ const [d, c] = x("entering");
746
+ O(() => {
747
+ const o = setTimeout(() => {
748
+ c("visible");
749
+ }, 10), u = setTimeout(() => {
750
+ c("exiting");
862
751
  }, n * 1e3 - 300), v = setTimeout(() => {
863
752
  l(e);
864
753
  }, n * 1e3);
865
754
  return () => {
866
- clearTimeout(c), clearTimeout(p), clearTimeout(v);
755
+ clearTimeout(o), clearTimeout(u), clearTimeout(v);
867
756
  };
868
757
  }, [e, n, l]);
869
758
  const r = [
@@ -872,9 +761,9 @@ const ke = Q(void 0), Vt = () => {
872
761
  i ? "colored-background" : "",
873
762
  `cl-toast-${d}`
874
763
  ].filter(Boolean).join(" ");
875
- return /* @__PURE__ */ w("div", { className: r, children: [
764
+ return /* @__PURE__ */ _("div", { className: r, children: [
876
765
  /* @__PURE__ */ a("div", { className: "cl-toast-message", children: t }),
877
- /* @__PURE__ */ a("button", { onClick: () => o("exiting"), className: "cl-toast-close-button", children: "×" }),
766
+ /* @__PURE__ */ a("button", { onClick: () => c("exiting"), className: "cl-toast-close-button", children: "×" }),
878
767
  /* @__PURE__ */ a(
879
768
  "div",
880
769
  {
@@ -883,92 +772,92 @@ const ke = Q(void 0), Vt = () => {
883
772
  }
884
773
  )
885
774
  ] });
886
- }, Ht = ({ children: e }) => {
887
- const [t, s] = T([]), n = te(() => {
775
+ }, Et = ({ children: e }) => {
776
+ const [t, s] = x([]), n = Y(() => {
888
777
  if (typeof document < "u") {
889
778
  const r = document.createElement("div");
890
779
  return r.id = "toast-portal-root", r;
891
780
  }
892
781
  return null;
893
782
  }, []);
894
- D(() => {
783
+ O(() => {
895
784
  if (n)
896
785
  return document.body.appendChild(n), () => {
897
786
  document.body.removeChild(n);
898
787
  };
899
788
  }, [n]);
900
- const l = ce((r) => {
901
- const p = {
789
+ const l = le((r) => {
790
+ const u = {
902
791
  id: (/* @__PURE__ */ new Date()).toISOString() + Math.random(),
903
792
  // duration: 5,
904
793
  // position: 'right-top',
905
794
  ...r
906
795
  };
907
796
  s((v) => {
908
- const m = [p, ...v];
797
+ const m = [u, ...v];
909
798
  return m.length > 4 ? m.slice(0, 4) : m;
910
799
  });
911
- }, []), i = ce((r) => {
912
- s((c) => c.filter((p) => p.id !== r));
913
- }, []), d = te(() => t.reduce((r, c) => (r[c.position] || (r[c.position] = []), r[c.position].push(c), r), {}), [t]), o = te(() => ({ show: l }), [l]);
914
- return /* @__PURE__ */ w(ke.Provider, { value: o, children: [
800
+ }, []), i = le((r) => {
801
+ s((o) => o.filter((u) => u.id !== r));
802
+ }, []), d = Y(() => t.reduce((r, o) => (r[o.position] || (r[o.position] = []), r[o.position].push(o), r), {}), [t]), c = Y(() => ({ show: l }), [l]);
803
+ return /* @__PURE__ */ _(Ce.Provider, { value: c, children: [
915
804
  e,
916
- n && mt.createPortal(
917
- Object.entries(d).map(([r, c]) => /* @__PURE__ */ a("div", { className: `cl-toast-container ${r}`, children: c.map((p) => /* @__PURE__ */ a(yt, { ...p, onClose: i }, p.id)) }, r)),
805
+ n && tt.createPortal(
806
+ Object.entries(d).map(([r, o]) => /* @__PURE__ */ a("div", { className: `cl-toast-container ${r}`, children: o.map((u) => /* @__PURE__ */ a(it, { ...u, onClose: i }, u.id)) }, r)),
918
807
  n
919
808
  )
920
809
  ] });
921
- }, xe = Q(null), Te = () => {
922
- const e = Z(xe);
810
+ }, _e = U(null), we = () => {
811
+ const e = q(_e);
923
812
  if (!e)
924
813
  throw new Error("useOffcanvas must be used within an Offcanvas provider");
925
814
  return e;
926
- }, Be = ({
815
+ }, ge = ({
927
816
  children: e,
928
817
  className: t = ""
929
818
  }) => {
930
- const { onClose: s, variant: n, showCloseButton: l, title: i } = Te(), d = [
819
+ const { onClose: s, variant: n, showCloseButton: l, title: i } = we(), d = [
931
820
  "clarity-offcanvas-header",
932
821
  t
933
- ].filter(Boolean).join(" "), o = [
822
+ ].filter(Boolean).join(" "), c = [
934
823
  "clarity-offcanvas-close",
935
824
  n && `clarity-offcanvas-close--${n}`
936
825
  ].filter(Boolean).join(" "), r = [
937
826
  "clarity-offcanvas-title",
938
827
  n && `clarity-offcanvas-title--${n}`
939
828
  ].filter(Boolean).join(" ");
940
- return /* @__PURE__ */ w("div", { className: d, children: [
829
+ return /* @__PURE__ */ _("div", { className: d, children: [
941
830
  i && /* @__PURE__ */ a("h2", { className: r, children: i }),
942
831
  e,
943
- l && /* @__PURE__ */ a("button", { className: o, onClick: (c) => {
944
- c.stopPropagation(), s();
832
+ l && /* @__PURE__ */ a("button", { className: c, onClick: (o) => {
833
+ o.stopPropagation(), s();
945
834
  }, children: "×" })
946
835
  ] });
947
836
  };
948
- Be.displayName = "Offcanvas.Header";
949
- const je = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-offcanvas-content ${t}`, children: e });
950
- je.displayName = "Offcanvas.Content";
951
- const Ee = ({ children: e, onClick: t, variant: s }) => z(e, {
837
+ ge.displayName = "Offcanvas.Header";
838
+ const $e = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-offcanvas-content ${t}`, children: e });
839
+ $e.displayName = "Offcanvas.Content";
840
+ const ke = ({ children: e, onClick: t, variant: s }) => W(e, {
952
841
  onClick: (n) => {
953
842
  var l, i;
954
843
  t == null || t(), (i = (l = e.props).onClick) == null || i.call(l, n);
955
844
  },
956
845
  variant: s
957
846
  });
958
- Ee.displayName = "Offcanvas.Trigger";
959
- const pe = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-offcanvas-footer ${t}`, children: e });
960
- pe.displayName = "Offcanvas.Footer";
961
- const Le = ({ children: e }) => {
962
- const { onClose: t } = Te();
963
- return z(e, {
847
+ ke.displayName = "Offcanvas.Trigger";
848
+ const oe = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-offcanvas-footer ${t}`, children: e });
849
+ oe.displayName = "Offcanvas.Footer";
850
+ const xe = ({ children: e }) => {
851
+ const { onClose: t } = we();
852
+ return W(e, {
964
853
  onClick: (s) => {
965
854
  var n, l;
966
855
  t(), (l = (n = e.props).onClick) == null || l.call(n, s);
967
856
  }
968
857
  });
969
858
  };
970
- Le.displayName = "Offcanvas.Close";
971
- const ae = ({
859
+ xe.displayName = "Offcanvas.Close";
860
+ const K = ({
972
861
  isOpen: e,
973
862
  onClose: t,
974
863
  onOpen: s,
@@ -976,16 +865,16 @@ const ae = ({
976
865
  className: l = "",
977
866
  variant: i,
978
867
  placement: d = "right",
979
- closeOnOverlayClick: o = !0,
868
+ closeOnOverlayClick: c = !0,
980
869
  showCloseButton: r = !0,
981
- title: c
870
+ title: o
982
871
  }) => {
983
- const [p, v] = T(!1), [m, f] = T(!1), [u, h] = T(!1), y = e !== void 0, b = y ? e : p, N = ce(() => {
872
+ const [u, v] = x(!1), [m, f] = x(!1), [p, h] = x(!1), y = e !== void 0, b = y ? e : u, C = le(() => {
984
873
  t ? t() : v(!1);
985
- }, [t]), B = ce(() => {
874
+ }, [t]), j = le(() => {
986
875
  y || v(!0), s == null || s();
987
876
  }, [y, s]);
988
- D(() => {
877
+ O(() => {
989
878
  if (b) {
990
879
  h(!0);
991
880
  const g = setTimeout(() => {
@@ -999,64 +888,64 @@ const ae = ({
999
888
  }, 300);
1000
889
  return () => clearTimeout(g);
1001
890
  }
1002
- }, [b]), D(() => {
1003
- const g = (V) => {
1004
- V.key === "Escape" && N();
891
+ }, [b]), O(() => {
892
+ const g = (H) => {
893
+ H.key === "Escape" && C();
1005
894
  };
1006
895
  return b ? (document.addEventListener("keydown", g), document.body.style.overflow = "hidden") : (document.removeEventListener("keydown", g), document.body.style.overflow = "unset"), () => {
1007
896
  document.removeEventListener("keydown", g), document.body.style.overflow = "unset";
1008
897
  };
1009
- }, [b, N]);
1010
- const x = (g) => {
1011
- o && g.target === g.currentTarget && N();
1012
- }, _ = E.Children.toArray(n);
1013
- let $, L, k, j, I;
1014
- _.forEach((g) => {
1015
- if (se(g))
898
+ }, [b, C]);
899
+ const T = (g) => {
900
+ c && g.target === g.currentTarget && C();
901
+ }, w = B.Children.toArray(n);
902
+ let $, S, k, E, R;
903
+ w.forEach((g) => {
904
+ if (Z(g))
1016
905
  if (g.type.displayName === "Offcanvas.Trigger")
1017
906
  $ = g;
1018
907
  else if (g.type.displayName === "Offcanvas.Header")
1019
- L = g;
908
+ S = g;
1020
909
  else if (g.type.displayName === "Offcanvas.Content") {
1021
910
  k = g;
1022
- const H = E.Children.toArray(k.props.children).filter((W) => se(W) && W.type.displayName === "Offcanvas.Close" ? (I = W, !1) : !0);
1023
- k = z(k, { children: H });
1024
- } else g.type.displayName === "Offcanvas.Footer" && (j = g);
1025
- }), I && (j ? j = z(j, {
1026
- children: /* @__PURE__ */ w(ot, { children: [
1027
- j.props.children,
1028
- I
911
+ const V = B.Children.toArray(k.props.children).filter((F) => Z(F) && F.type.displayName === "Offcanvas.Close" ? (R = F, !1) : !0);
912
+ k = W(k, { children: V });
913
+ } else g.type.displayName === "Offcanvas.Footer" && (E = g);
914
+ }), R && (E ? E = W(E, {
915
+ children: /* @__PURE__ */ _(Ze, { children: [
916
+ E.props.children,
917
+ R
1029
918
  ] })
1030
- }) : j = /* @__PURE__ */ a(pe, { children: I }));
919
+ }) : E = /* @__PURE__ */ a(oe, { children: R }));
1031
920
  const A = [
1032
921
  "clarity-offcanvas",
1033
922
  l,
1034
923
  `clarity-offcanvas--${d}`,
1035
924
  i && `clarity-offcanvas--${i}`,
1036
925
  m ? "clarity-offcanvas--open" : "clarity-offcanvas--closed"
1037
- ].filter(Boolean).join(" "), O = [
926
+ ].filter(Boolean).join(" "), I = [
1038
927
  "clarity-offcanvas-overlay",
1039
928
  m ? "clarity-offcanvas-overlay--visible" : ""
1040
929
  ].filter(Boolean).join(" ");
1041
- return /* @__PURE__ */ w(xe.Provider, { value: { onClose: N, variant: i, showCloseButton: r, placement: d, title: c }, children: [
1042
- $ && z($, { onClick: B, variant: i }),
1043
- u && // Only render if shouldRender is true
1044
- /* @__PURE__ */ a("div", { className: O, onClick: x, children: /* @__PURE__ */ w("div", { className: A, children: [
1045
- L,
930
+ return /* @__PURE__ */ _(_e.Provider, { value: { onClose: C, variant: i, showCloseButton: r, placement: d, title: o }, children: [
931
+ $ && W($, { onClick: j, variant: i }),
932
+ p && // Only render if shouldRender is true
933
+ /* @__PURE__ */ a("div", { className: I, onClick: T, children: /* @__PURE__ */ _("div", { className: A, children: [
934
+ S,
1046
935
  k,
1047
- j && /* @__PURE__ */ a("div", { className: "clarity-offcanvas-scroll-indicator" }),
936
+ E && /* @__PURE__ */ a("div", { className: "clarity-offcanvas-scroll-indicator" }),
1048
937
  " ",
1049
- j
938
+ E
1050
939
  ] }) })
1051
940
  ] });
1052
941
  };
1053
- ae.Header = Be;
1054
- ae.Content = je;
1055
- ae.Footer = pe;
1056
- ae.Trigger = Ee;
1057
- ae.Close = Le;
1058
- ae.displayName = "Offcanvas";
1059
- const vt = E.forwardRef(({
942
+ K.Header = ge;
943
+ K.Content = $e;
944
+ K.Footer = oe;
945
+ K.Trigger = ke;
946
+ K.Close = xe;
947
+ K.displayName = "Offcanvas";
948
+ const rt = B.forwardRef(({
1060
949
  type: e,
1061
950
  variant: t = "primary",
1062
951
  size: s = "medium",
@@ -1064,17 +953,17 @@ const vt = E.forwardRef(({
1064
953
  helperText: l,
1065
954
  error: i = !1,
1066
955
  errorMessage: d,
1067
- labelPosition: o = "right",
956
+ labelPosition: c = "right",
1068
957
  className: r = "",
1069
- disabled: c = !1,
1070
- checked: p,
958
+ disabled: o = !1,
959
+ checked: u,
1071
960
  id: v,
1072
961
  ...m
1073
962
  }, f) => {
1074
- const u = v || `check-input-${Math.random().toString(36).substr(2, 9)}`, h = [
963
+ const p = v || `check-input-${Math.random().toString(36).substr(2, 9)}`, h = [
1075
964
  "clarity-check-input-wrapper",
1076
- `clarity-check-input-wrapper--${o}`,
1077
- c && "clarity-check-input-wrapper--disabled",
965
+ `clarity-check-input-wrapper--${c}`,
966
+ o && "clarity-check-input-wrapper--disabled",
1078
967
  i && "clarity-check-input-wrapper--error"
1079
968
  ].filter(Boolean).join(" "), y = [
1080
969
  "clarity-check-input",
@@ -1082,28 +971,28 @@ const vt = E.forwardRef(({
1082
971
  `clarity-check-input--${s}`,
1083
972
  t && `clarity-check-input--${t}`,
1084
973
  i && "clarity-check-input--error",
1085
- c && "clarity-check-input--disabled",
974
+ o && "clarity-check-input--disabled",
1086
975
  r
1087
976
  ].filter(Boolean).join(" "), b = [
1088
977
  "clarity-check-input__label",
1089
978
  `clarity-check-input__label--${s}`,
1090
- c && "clarity-check-input__label--disabled"
979
+ o && "clarity-check-input__label--disabled"
1091
980
  ].filter(Boolean).join(" ");
1092
- return /* @__PURE__ */ w("div", { className: "clarity-check-input-container", children: [
1093
- /* @__PURE__ */ w("label", { className: h, htmlFor: u, children: [
981
+ return /* @__PURE__ */ _("div", { className: "clarity-check-input-container", children: [
982
+ /* @__PURE__ */ _("label", { className: h, htmlFor: p, children: [
1094
983
  /* @__PURE__ */ a(
1095
984
  "input",
1096
985
  {
1097
986
  ref: f,
1098
- id: u,
987
+ id: p,
1099
988
  type: e,
1100
989
  className: y,
1101
- disabled: c,
1102
- checked: p,
990
+ disabled: o,
991
+ checked: u,
1103
992
  ...m
1104
993
  }
1105
994
  ),
1106
- /* @__PURE__ */ w("div", { className: "clarity-check-input__custom", children: [
995
+ /* @__PURE__ */ _("div", { className: "clarity-check-input__custom", children: [
1107
996
  e === "checkbox" && /* @__PURE__ */ a(
1108
997
  "svg",
1109
998
  {
@@ -1130,8 +1019,8 @@ const vt = E.forwardRef(({
1130
1019
  (l || i && d) && /* @__PURE__ */ a("div", { className: "clarity-check-input__helper-text", children: i && d ? d : l })
1131
1020
  ] });
1132
1021
  });
1133
- vt.displayName = "CheckInput";
1134
- const bt = E.forwardRef(({
1022
+ rt.displayName = "CheckInput";
1023
+ const ct = B.forwardRef(({
1135
1024
  variant: e = "primary",
1136
1025
  size: t = "medium",
1137
1026
  label: s,
@@ -1139,13 +1028,13 @@ const bt = E.forwardRef(({
1139
1028
  error: l = !1,
1140
1029
  errorMessage: i,
1141
1030
  labelPosition: d = "right",
1142
- className: o = "",
1031
+ className: c = "",
1143
1032
  disabled: r = !1,
1144
- checked: c,
1145
- id: p,
1033
+ checked: o,
1034
+ id: u,
1146
1035
  ...v
1147
1036
  }, m) => {
1148
- const f = p || `input-switch-${Math.random().toString(36).substr(2, 9)}`, u = [
1037
+ const f = u || `input-switch-${Math.random().toString(36).substr(2, 9)}`, p = [
1149
1038
  "clarity-input-switch-wrapper",
1150
1039
  `clarity-input-switch-wrapper--${d}`,
1151
1040
  r && "clarity-input-switch-wrapper--disabled",
@@ -1156,14 +1045,14 @@ const bt = E.forwardRef(({
1156
1045
  e && `clarity-input-switch--${e}`,
1157
1046
  l && "clarity-input-switch--error",
1158
1047
  r && "clarity-input-switch--disabled",
1159
- o
1048
+ c
1160
1049
  ].filter(Boolean).join(" "), y = [
1161
1050
  "clarity-input-switch__label",
1162
1051
  `clarity-input-switch__label--${t}`,
1163
1052
  r && "clarity-input-switch__label--disabled"
1164
1053
  ].filter(Boolean).join(" ");
1165
- return /* @__PURE__ */ w("div", { className: "clarity-input-switch-container", children: [
1166
- /* @__PURE__ */ w("label", { className: u, htmlFor: f, children: [
1054
+ return /* @__PURE__ */ _("div", { className: "clarity-input-switch-container", children: [
1055
+ /* @__PURE__ */ _("label", { className: p, htmlFor: f, children: [
1167
1056
  /* @__PURE__ */ a(
1168
1057
  "input",
1169
1058
  {
@@ -1172,7 +1061,7 @@ const bt = E.forwardRef(({
1172
1061
  type: "checkbox",
1173
1062
  className: h,
1174
1063
  disabled: r,
1175
- checked: c,
1064
+ checked: o,
1176
1065
  ...v
1177
1066
  }
1178
1067
  ),
@@ -1182,88 +1071,88 @@ const bt = E.forwardRef(({
1182
1071
  (n || l && i) && /* @__PURE__ */ a("div", { className: "clarity-input-switch__helper-text", children: l && i ? i : n })
1183
1072
  ] });
1184
1073
  });
1185
- bt.displayName = "InputSwitch";
1186
- const Se = Q(null), fe = () => {
1187
- const e = Z(Se);
1074
+ ct.displayName = "InputSwitch";
1075
+ const Te = U(null), de = () => {
1076
+ const e = q(Te);
1188
1077
  if (!e)
1189
1078
  throw new Error("useConfirmationDialog must be used within a ConfirmationDialog provider");
1190
1079
  return e;
1191
- }, Oe = ({ children: e, className: t = "" }) => {
1192
- const { variant: s } = fe(), n = `clarity-confirmation-dialog-header ${t} clarity-confirmation-dialog-header--${s}`;
1080
+ }, Be = ({ children: e, className: t = "" }) => {
1081
+ const { variant: s } = de(), n = `clarity-confirmation-dialog-header ${t} clarity-confirmation-dialog-header--${s}`;
1193
1082
  return /* @__PURE__ */ a("div", { className: n, children: e });
1194
1083
  };
1195
- Oe.displayName = "ConfirmationDialog.Header";
1196
- const Ie = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-confirmation-dialog-content ${t}`, children: e });
1197
- Ie.displayName = "ConfirmationDialog.Content";
1198
- const Re = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-confirmation-dialog-footer ${t}`, children: e });
1199
- Re.displayName = "ConfirmationDialog.Footer";
1200
- const De = ({ children: e }) => z(e, {
1084
+ Be.displayName = "ConfirmationDialog.Header";
1085
+ const je = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-confirmation-dialog-content ${t}`, children: e });
1086
+ je.displayName = "ConfirmationDialog.Content";
1087
+ const Ee = ({ children: e, className: t = "" }) => /* @__PURE__ */ a("div", { className: `clarity-confirmation-dialog-footer ${t}`, children: e });
1088
+ Ee.displayName = "ConfirmationDialog.Footer";
1089
+ const Le = ({ children: e }) => W(e, {
1201
1090
  onClick: (t) => {
1202
1091
  var s, n;
1203
1092
  (n = (s = e.props).onClick) == null || n.call(s, t);
1204
1093
  }
1205
1094
  });
1206
- De.displayName = "ConfirmationDialog.Trigger";
1207
- const Ae = ({ children: e }) => {
1208
- const { onClose: t } = fe();
1209
- return z(e, {
1095
+ Le.displayName = "ConfirmationDialog.Trigger";
1096
+ const Se = ({ children: e }) => {
1097
+ const { onClose: t } = de();
1098
+ return W(e, {
1210
1099
  onClick: (s) => {
1211
1100
  var n, l;
1212
1101
  t(), (l = (n = e.props).onClick) == null || l.call(n, s);
1213
1102
  }
1214
1103
  });
1215
1104
  };
1216
- Ae.displayName = "ConfirmationDialog.Close";
1217
- const Pe = ({ children: e }) => {
1218
- const { onConfirm: t } = fe();
1219
- return z(e, {
1105
+ Se.displayName = "ConfirmationDialog.Close";
1106
+ const Oe = ({ children: e }) => {
1107
+ const { onConfirm: t } = de();
1108
+ return W(e, {
1220
1109
  onClick: (s) => {
1221
1110
  var n, l;
1222
1111
  t(), (l = (n = e.props).onClick) == null || l.call(n, s);
1223
1112
  }
1224
1113
  });
1225
1114
  };
1226
- Pe.displayName = "ConfirmationDialog.Confirm";
1227
- const ee = ({
1115
+ Oe.displayName = "ConfirmationDialog.Confirm";
1116
+ const Q = ({
1228
1117
  isOpen: e,
1229
1118
  onClose: t,
1230
1119
  onConfirm: s,
1231
1120
  variant: n = "clarity-primary",
1232
1121
  children: l
1233
1122
  }) => {
1234
- const [i, d] = T(!1), o = e !== void 0, r = o ? e : i, c = () => {
1235
- o || d(!0);
1236
- }, p = () => {
1123
+ const [i, d] = x(!1), c = e !== void 0, r = c ? e : i, o = () => {
1124
+ c || d(!0);
1125
+ }, u = () => {
1237
1126
  t ? t() : d(!1);
1238
1127
  }, v = () => {
1239
- s && s(), p();
1128
+ s && s(), u();
1240
1129
  };
1241
- D(() => {
1130
+ O(() => {
1242
1131
  const h = (y) => {
1243
- y.key === "Escape" && p();
1132
+ y.key === "Escape" && u();
1244
1133
  };
1245
1134
  return r ? (document.addEventListener("keydown", h), document.body.style.overflow = "hidden") : document.body.style.overflow = "unset", () => {
1246
1135
  document.removeEventListener("keydown", h), document.body.style.overflow = "unset";
1247
1136
  };
1248
- }, [r, p]);
1249
- const m = E.Children.toArray(l).find(
1250
- (h) => se(h) && h.type.displayName === "ConfirmationDialog.Trigger"
1251
- ), f = E.Children.toArray(l).filter(
1252
- (h) => se(h) && h.type.displayName !== "ConfirmationDialog.Trigger"
1253
- ), u = `clarity-confirmation-dialog clarity-confirmation-dialog--${n}`;
1254
- return /* @__PURE__ */ w(Se.Provider, { value: { variant: n, onClose: p, onConfirm: v, onOpen: c }, children: [
1137
+ }, [r, u]);
1138
+ const m = B.Children.toArray(l).find(
1139
+ (h) => Z(h) && h.type.displayName === "ConfirmationDialog.Trigger"
1140
+ ), f = B.Children.toArray(l).filter(
1141
+ (h) => Z(h) && h.type.displayName !== "ConfirmationDialog.Trigger"
1142
+ ), p = `clarity-confirmation-dialog clarity-confirmation-dialog--${n}`;
1143
+ return /* @__PURE__ */ _(Te.Provider, { value: { variant: n, onClose: u, onConfirm: v, onOpen: o }, children: [
1255
1144
  m,
1256
- r && /* @__PURE__ */ a("div", { className: "clarity-modal-overlay", children: /* @__PURE__ */ a("div", { className: u, children: f }) })
1145
+ r && /* @__PURE__ */ a("div", { className: "clarity-modal-overlay", children: /* @__PURE__ */ a("div", { className: p, children: f }) })
1257
1146
  ] });
1258
1147
  };
1259
- ee.Header = Oe;
1260
- ee.Content = Ie;
1261
- ee.Footer = Re;
1262
- ee.Trigger = De;
1263
- ee.Close = Ae;
1264
- ee.Confirm = Pe;
1265
- ee.displayName = "ConfirmationDialog";
1266
- const Mt = ({
1148
+ Q.Header = Be;
1149
+ Q.Content = je;
1150
+ Q.Footer = Ee;
1151
+ Q.Trigger = Le;
1152
+ Q.Close = Se;
1153
+ Q.Confirm = Oe;
1154
+ Q.displayName = "ConfirmationDialog";
1155
+ const Lt = ({
1267
1156
  variant: e = "primary",
1268
1157
  size: t = "medium",
1269
1158
  disabled: s = !1,
@@ -1271,30 +1160,30 @@ const Mt = ({
1271
1160
  children: l,
1272
1161
  onClick: i,
1273
1162
  type: d = "button",
1274
- className: o = "",
1163
+ className: c = "",
1275
1164
  "aria-label": r,
1276
- title: c,
1277
- customColor: p,
1165
+ title: o,
1166
+ customColor: u,
1278
1167
  customColorHover: v,
1279
1168
  ...m
1280
1169
  }) => {
1281
- const f = "clarity-button-icon", u = [
1170
+ const f = "clarity-button-icon", p = [
1282
1171
  f,
1283
- !p && `${f}--${e}`,
1172
+ !u && `${f}--${e}`,
1284
1173
  `${f}--${t}`,
1285
1174
  n && `${f}--loading`,
1286
1175
  s && `${f}--disabled`,
1287
- o
1176
+ c
1288
1177
  ].filter(Boolean).join(" "), h = {};
1289
- return p && (h["--button-icon-bg"] = p, h["--button-icon-hover-bg"] = v || `${p}E6`), /* @__PURE__ */ w(
1178
+ return u && (h["--button-icon-bg"] = u, h["--button-icon-hover-bg"] = v || `${u}E6`), /* @__PURE__ */ _(
1290
1179
  "button",
1291
1180
  {
1292
- className: u,
1181
+ className: p,
1293
1182
  disabled: s || n,
1294
1183
  onClick: i,
1295
1184
  type: d,
1296
1185
  "aria-label": r,
1297
- title: c,
1186
+ title: o,
1298
1187
  style: h,
1299
1188
  ...m,
1300
1189
  children: [
@@ -1303,7 +1192,7 @@ const Mt = ({
1303
1192
  ]
1304
1193
  }
1305
1194
  );
1306
- }, Wt = ({
1195
+ }, St = ({
1307
1196
  variant: e = "primary",
1308
1197
  product: t,
1309
1198
  tone: s,
@@ -1311,23 +1200,23 @@ const Mt = ({
1311
1200
  size: l = "medium",
1312
1201
  disabled: i = !1,
1313
1202
  children: d,
1314
- onClick: o,
1203
+ onClick: c,
1315
1204
  href: r,
1316
- target: c,
1317
- rel: p,
1205
+ target: o,
1206
+ rel: u,
1318
1207
  className: v = "",
1319
1208
  ...m
1320
1209
  }) => {
1321
- const f = "clarity-button-link", u = t && s, h = u ? `${f}--custom` : `${f}--${e}`, y = [
1210
+ const f = "clarity-button-link", p = t && s, h = p ? `${f}--custom` : `${f}--${e}`, y = [
1322
1211
  f,
1323
1212
  h,
1324
1213
  `${f}--${l}`,
1325
1214
  i && `${f}--disabled`,
1326
1215
  v
1327
- ].filter(Boolean).join(" "), b = (B) => {
1328
- const x = parseInt(B);
1329
- return x >= 800 ? "900" : x >= 700 ? "800" : x >= 600 ? "700" : x >= 500 ? "600" : x >= 400 ? "500" : x >= 300 ? "400" : x >= 200 ? "300" : "200";
1330
- }, N = u ? {
1216
+ ].filter(Boolean).join(" "), b = (j) => {
1217
+ const T = parseInt(j);
1218
+ return T >= 800 ? "900" : T >= 700 ? "800" : T >= 600 ? "700" : T >= 500 ? "600" : T >= 400 ? "500" : T >= 300 ? "400" : T >= 200 ? "300" : "200";
1219
+ }, C = p ? {
1331
1220
  "--custom-color": `var(--clarity-${t}-${s})`,
1332
1221
  "--custom-hover-color": `var(--clarity-${t}-${n || b(s)})`
1333
1222
  } : {};
@@ -1335,11 +1224,11 @@ const Mt = ({
1335
1224
  "a",
1336
1225
  {
1337
1226
  href: r,
1338
- target: c,
1339
- rel: p || (c === "_blank" ? "noopener noreferrer" : void 0),
1227
+ target: o,
1228
+ rel: u || (o === "_blank" ? "noopener noreferrer" : void 0),
1340
1229
  className: y,
1341
- style: N,
1342
- onClick: i ? void 0 : o,
1230
+ style: C,
1231
+ onClick: i ? void 0 : c,
1343
1232
  ...m,
1344
1233
  children: d
1345
1234
  }
@@ -1347,19 +1236,19 @@ const Mt = ({
1347
1236
  "button",
1348
1237
  {
1349
1238
  className: y,
1350
- style: N,
1239
+ style: C,
1351
1240
  disabled: i,
1352
- onClick: o,
1241
+ onClick: c,
1353
1242
  ...m,
1354
1243
  children: d
1355
1244
  }
1356
1245
  );
1357
- }, Ve = Q(void 0), He = () => {
1358
- const e = Z(Ve);
1246
+ }, Ie = U(void 0), Re = () => {
1247
+ const e = q(Ie);
1359
1248
  if (!e)
1360
1249
  throw new Error("Accordion components must be used within an Accordion");
1361
1250
  return e;
1362
- }, Ct = ({
1251
+ }, ot = ({
1363
1252
  variant: e = "primary",
1364
1253
  product: t,
1365
1254
  tone: s,
@@ -1367,27 +1256,27 @@ const Mt = ({
1367
1256
  defaultActiveKey: l,
1368
1257
  alwaysOpen: i = !1,
1369
1258
  flush: d = !1,
1370
- className: o = "",
1259
+ className: c = "",
1371
1260
  children: r,
1372
- onSelect: c,
1373
- ...p
1261
+ onSelect: o,
1262
+ ...u
1374
1263
  }) => {
1375
- const [v, m] = T(() => l ? Array.isArray(l) ? l : [l] : []), f = (_) => {
1264
+ const [v, m] = x(() => l ? Array.isArray(l) ? l : [l] : []), f = (w) => {
1376
1265
  let $;
1377
- i ? $ = v.includes(_) ? v.filter((L) => L !== _) : [...v, _] : $ = v.includes(_) ? [] : [_], m($), c && c(v.includes(_) ? null : _, {});
1378
- }, u = "clarity-accordion", h = t && s, y = h ? `${u}--custom` : `${u}--${e}`, b = [
1379
- u,
1266
+ i ? $ = v.includes(w) ? v.filter((S) => S !== w) : [...v, w] : $ = v.includes(w) ? [] : [w], m($), o && o(v.includes(w) ? null : w, {});
1267
+ }, p = "clarity-accordion", h = t && s, y = h ? `${p}--custom` : `${p}--${e}`, b = [
1268
+ p,
1380
1269
  y,
1381
- d && `${u}--flush`,
1382
- o
1383
- ].filter(Boolean).join(" "), N = (_) => {
1384
- const $ = parseInt(_);
1270
+ d && `${p}--flush`,
1271
+ c
1272
+ ].filter(Boolean).join(" "), C = (w) => {
1273
+ const $ = parseInt(w);
1385
1274
  return $ >= 800 ? "900" : $ >= 700 ? "800" : $ >= 600 ? "700" : $ >= 500 ? "600" : $ >= 400 ? "500" : $ >= 300 ? "400" : $ >= 200 ? "300" : "200";
1386
- }, B = h ? {
1275
+ }, j = h ? {
1387
1276
  "--custom-border-color": `var(--clarity-${t}-${s})`,
1388
1277
  "--custom-header-color": `var(--clarity-${t}-${s})`,
1389
- "--custom-hover-color": `var(--clarity-${t}-${n || N(s)})`
1390
- } : {}, x = {
1278
+ "--custom-hover-color": `var(--clarity-${t}-${n || C(s)})`
1279
+ } : {}, T = {
1391
1280
  activeKeys: v,
1392
1281
  toggleItem: f,
1393
1282
  alwaysOpen: i,
@@ -1397,27 +1286,27 @@ const Mt = ({
1397
1286
  hoverTone: n,
1398
1287
  flush: d
1399
1288
  };
1400
- return /* @__PURE__ */ a(Ve.Provider, { value: x, children: /* @__PURE__ */ a("div", { className: b, style: B, ...p, children: r }) });
1401
- }, Nt = ({
1289
+ return /* @__PURE__ */ a(Ie.Provider, { value: T, children: /* @__PURE__ */ a("div", { className: b, style: j, ...u, children: r }) });
1290
+ }, dt = ({
1402
1291
  eventKey: e,
1403
1292
  disabled: t = !1,
1404
1293
  className: s = "",
1405
1294
  children: n,
1406
1295
  ...l
1407
1296
  }) => {
1408
- const { activeKeys: i } = He(), d = "clarity-accordion", o = i.includes(e), r = [
1297
+ const { activeKeys: i } = Re(), d = "clarity-accordion", c = i.includes(e), r = [
1409
1298
  `${d}__item`,
1410
- o && `${d}__item--active`,
1299
+ c && `${d}__item--active`,
1411
1300
  t && `${d}__item--disabled`,
1412
1301
  s
1413
1302
  ].filter(Boolean).join(" ");
1414
- return /* @__PURE__ */ a("div", { className: r, ...l, children: E.Children.map(n, (c) => E.isValidElement(c) ? E.cloneElement(c, {
1415
- ...c.props,
1303
+ return /* @__PURE__ */ a("div", { className: r, ...l, children: B.Children.map(n, (o) => B.isValidElement(o) ? B.cloneElement(o, {
1304
+ ...o.props,
1416
1305
  eventKey: e,
1417
1306
  disabled: t,
1418
- isActive: o
1419
- }) : c) });
1420
- }, wt = ({
1307
+ isActive: c
1308
+ }) : o) });
1309
+ }, mt = ({
1421
1310
  className: e = "",
1422
1311
  children: t,
1423
1312
  onClick: s,
@@ -1426,14 +1315,14 @@ const Mt = ({
1426
1315
  isActive: i = !1,
1427
1316
  ...d
1428
1317
  }) => {
1429
- const { toggleItem: o } = He(), r = "clarity-accordion", c = (p) => {
1430
- !l && n && o(n), s == null || s(p);
1318
+ const { toggleItem: c } = Re(), r = "clarity-accordion", o = (u) => {
1319
+ !l && n && c(n), s == null || s(u);
1431
1320
  };
1432
- return /* @__PURE__ */ w(
1321
+ return /* @__PURE__ */ _(
1433
1322
  "button",
1434
1323
  {
1435
1324
  className: [`${r}__header`, e].filter(Boolean).join(" "),
1436
- onClick: c,
1325
+ onClick: o,
1437
1326
  disabled: l,
1438
1327
  "aria-expanded": i,
1439
1328
  "aria-controls": n ? `${r}-collapse-${n}` : void 0,
@@ -1454,7 +1343,7 @@ const Mt = ({
1454
1343
  ]
1455
1344
  }
1456
1345
  );
1457
- }, _t = ({
1346
+ }, ut = ({
1458
1347
  className: e = "",
1459
1348
  children: t,
1460
1349
  eventKey: s,
@@ -1473,19 +1362,19 @@ const Mt = ({
1473
1362
  children: /* @__PURE__ */ a("div", { className: [`${i}__body`, e].filter(Boolean).join(" "), ...l, children: t })
1474
1363
  }
1475
1364
  );
1476
- }, Ft = Object.assign(Ct, {
1477
- Item: Nt,
1478
- Header: wt,
1479
- Body: _t
1480
- }), Me = Q(
1365
+ }, Ot = Object.assign(ot, {
1366
+ Item: dt,
1367
+ Header: mt,
1368
+ Body: ut
1369
+ }), De = U(
1481
1370
  void 0
1482
- ), We = () => {
1483
- const e = Z(Me);
1371
+ ), Ae = () => {
1372
+ const e = q(De);
1484
1373
  if (!e)
1485
1374
  throw new Error("useDropdown must be used within a DropdownProvider");
1486
1375
  return e;
1487
- }, gt = ({ children: e }) => {
1488
- const { setIsOpen: t, triggerRef: s } = We();
1376
+ }, pt = ({ children: e }) => {
1377
+ const { setIsOpen: t, triggerRef: s } = Ae();
1489
1378
  return /* @__PURE__ */ a(
1490
1379
  "button",
1491
1380
  {
@@ -1497,18 +1386,18 @@ const Mt = ({
1497
1386
  children: e
1498
1387
  }
1499
1388
  );
1500
- }, $t = ({ children: e }) => {
1501
- const { isOpen: t, contentRef: s, styles: n } = We();
1389
+ }, ft = ({ children: e }) => {
1390
+ const { isOpen: t, contentRef: s, styles: n } = Ae();
1502
1391
  return t ? /* @__PURE__ */ a("div", { ref: s, className: "dropdown__content", style: n, children: e }) : null;
1503
- }, kt = ({ children: e }) => /* @__PURE__ */ a("div", { className: "dropdown__menu", children: e }), xt = ({ as: e, children: t, ...s }) => /* @__PURE__ */ a(e || "a", { ...s, className: "dropdown__item", children: t }), Tt = () => /* @__PURE__ */ a("hr", { className: "dropdown__separator" }), oe = ({ title: e, position: t = "bottom", children: s }) => {
1504
- const [n, l] = T(!1), [i, d] = T({}), o = M(null), r = M(null), c = M(null);
1505
- return dt(() => {
1392
+ }, ht = ({ children: e }) => /* @__PURE__ */ a("div", { className: "dropdown__menu", children: e }), yt = ({ as: e, children: t, ...s }) => /* @__PURE__ */ a(e || "a", { ...s, className: "dropdown__item", children: t }), vt = () => /* @__PURE__ */ a("hr", { className: "dropdown__separator" }), ae = ({ title: e, position: t = "bottom", children: s }) => {
1393
+ const [n, l] = x(!1), [i, d] = x({}), c = P(null), r = P(null), o = P(null);
1394
+ return et(() => {
1506
1395
  if (n) {
1507
- const p = r.current, v = c.current;
1508
- if (!p || !v) return;
1509
- const m = p.getBoundingClientRect(), f = v.getBoundingClientRect(), u = window.innerHeight, h = window.innerWidth;
1396
+ const u = r.current, v = o.current;
1397
+ if (!u || !v) return;
1398
+ const m = u.getBoundingClientRect(), f = v.getBoundingClientRect(), p = window.innerHeight, h = window.innerWidth;
1510
1399
  let y = t;
1511
- t === "bottom" && m.bottom + f.height > u && (y = "top"), t === "top" && m.top - f.height < 0 && (y = "bottom"), t === "right" && m.right + f.width > h && (y = "left"), t === "left" && m.left - f.width < 0 && (y = "right");
1400
+ t === "bottom" && m.bottom + f.height > p && (y = "top"), t === "top" && m.top - f.height < 0 && (y = "bottom"), t === "right" && m.right + f.width > h && (y = "left"), t === "left" && m.left - f.width < 0 && (y = "right");
1512
1401
  const b = {};
1513
1402
  switch (y) {
1514
1403
  case "top":
@@ -1527,39 +1416,39 @@ const Mt = ({
1527
1416
  }
1528
1417
  d(b);
1529
1418
  }
1530
- }, [n, t]), D(() => {
1531
- const p = (v) => {
1532
- o.current && !o.current.contains(v.target) && l(!1);
1419
+ }, [n, t]), O(() => {
1420
+ const u = (v) => {
1421
+ c.current && !c.current.contains(v.target) && l(!1);
1533
1422
  };
1534
- return document.addEventListener("mousedown", p), () => {
1535
- document.removeEventListener("mousedown", p);
1423
+ return document.addEventListener("mousedown", u), () => {
1424
+ document.removeEventListener("mousedown", u);
1536
1425
  };
1537
- }, []), /* @__PURE__ */ a(Me.Provider, { value: { isOpen: n, setIsOpen: l, triggerRef: r, contentRef: c, styles: i }, children: /* @__PURE__ */ a(
1426
+ }, []), /* @__PURE__ */ a(De.Provider, { value: { isOpen: n, setIsOpen: l, triggerRef: r, contentRef: o, styles: i }, children: /* @__PURE__ */ a(
1538
1427
  "div",
1539
1428
  {
1540
- ref: o,
1429
+ ref: c,
1541
1430
  className: "dropdown",
1542
1431
  title: e,
1543
1432
  children: s
1544
1433
  }
1545
1434
  ) });
1546
1435
  };
1547
- oe.Trigger = gt;
1548
- oe.Content = $t;
1549
- oe.Menu = kt;
1550
- oe.Item = xt;
1551
- oe.Separator = Tt;
1552
- const Fe = Q(null), Ge = () => {
1553
- const e = Z(Fe);
1436
+ ae.Trigger = pt;
1437
+ ae.Content = ft;
1438
+ ae.Menu = ht;
1439
+ ae.Item = yt;
1440
+ ae.Separator = vt;
1441
+ const Pe = U(null), Ve = () => {
1442
+ const e = q(Pe);
1554
1443
  if (!e)
1555
1444
  throw new Error("useTabs must be used within a Tabs provider");
1556
1445
  return e;
1557
- }, ze = ({ id: e, label: t, className: s = "" }) => {
1558
- const { activeTab: n, setActiveTab: l, variant: i, orientation: d } = Ge(), o = n === e, r = [
1446
+ }, Me = ({ id: e, label: t, className: s = "" }) => {
1447
+ const { activeTab: n, setActiveTab: l, variant: i, orientation: d } = Ve(), c = n === e, r = [
1559
1448
  "clarity-tab",
1560
1449
  s,
1561
- o ? "active" : "",
1562
- o ? `variant-${i}` : "",
1450
+ c ? "active" : "",
1451
+ c ? `variant-${i}` : "",
1563
1452
  `orientation-${d}`
1564
1453
  ].filter(Boolean).join(" ");
1565
1454
  return /* @__PURE__ */ a(
@@ -1568,21 +1457,21 @@ const Fe = Q(null), Ge = () => {
1568
1457
  className: r,
1569
1458
  onClick: () => l(e),
1570
1459
  role: "tab",
1571
- "aria-selected": o,
1460
+ "aria-selected": c,
1572
1461
  children: /* @__PURE__ */ a("span", { className: "clarity-tab-label", children: t })
1573
1462
  }
1574
1463
  );
1575
1464
  };
1576
- ze.displayName = "Tabs.Tab";
1577
- const Ue = ({ id: e, children: t, className: s = "" }) => {
1578
- const { activeTab: n } = Ge(), l = n === e, i = {
1465
+ Me.displayName = "Tabs.Tab";
1466
+ const He = ({ id: e, children: t, className: s = "" }) => {
1467
+ const { activeTab: n } = Ve(), l = n === e, i = {
1579
1468
  visibility: l ? "visible" : "hidden",
1580
1469
  gridArea: "1 / 1"
1581
1470
  };
1582
1471
  return l || (i.pointerEvents = "none"), /* @__PURE__ */ a("div", { className: `clarity-tab-content ${s}`, role: "tabpanel", style: i, children: t });
1583
1472
  };
1584
- Ue.displayName = "Tabs.Content";
1585
- const he = ({
1473
+ He.displayName = "Tabs.Content";
1474
+ const me = ({
1586
1475
  children: e,
1587
1476
  defaultTab: t,
1588
1477
  variant: s = "primary",
@@ -1590,8 +1479,8 @@ const he = ({
1590
1479
  className: l = "",
1591
1480
  useUrl: i = !1
1592
1481
  }) => {
1593
- const d = () => window.location.hash.replace("#", ""), [o, r] = T(() => i && d() || t);
1594
- D(() => {
1482
+ const d = () => window.location.hash.replace("#", ""), [c, r] = x(() => i && d() || t);
1483
+ O(() => {
1595
1484
  if (i) {
1596
1485
  const m = () => {
1597
1486
  const f = d();
@@ -1602,24 +1491,24 @@ const he = ({
1602
1491
  };
1603
1492
  }
1604
1493
  }, [i]);
1605
- const c = (m) => {
1494
+ const o = (m) => {
1606
1495
  i && (window.location.hash = String(m)), r(m);
1607
- }, p = te(() => ({
1608
- activeTab: o,
1609
- setActiveTab: c,
1496
+ }, u = Y(() => ({
1497
+ activeTab: c,
1498
+ setActiveTab: o,
1610
1499
  variant: s,
1611
1500
  orientation: n
1612
- }), [o, s, n]), v = [
1501
+ }), [c, s, n]), v = [
1613
1502
  "clarity-tabs-container",
1614
1503
  l,
1615
1504
  `orientation-${n}`
1616
1505
  ].filter(Boolean).join(" ");
1617
- return /* @__PURE__ */ a(Fe.Provider, { value: p, children: /* @__PURE__ */ a("div", { className: v, children: e }) });
1506
+ return /* @__PURE__ */ a(Pe.Provider, { value: u, children: /* @__PURE__ */ a("div", { className: v, children: e }) });
1618
1507
  };
1619
- he.Tab = ze;
1620
- he.Content = Ue;
1621
- he.displayName = "Tabs";
1622
- const Gt = ({
1508
+ me.Tab = Me;
1509
+ me.Content = He;
1510
+ me.displayName = "Tabs";
1511
+ const It = ({
1623
1512
  content: e,
1624
1513
  position: t = "top",
1625
1514
  variant: s = "primary",
@@ -1627,84 +1516,84 @@ const Gt = ({
1627
1516
  tone: l,
1628
1517
  bgColor: i,
1629
1518
  textColor: d,
1630
- children: o,
1519
+ children: c,
1631
1520
  className: r = "",
1632
- disabled: c = !1,
1633
- delay: p = 200,
1521
+ disabled: o = !1,
1522
+ delay: u = 200,
1634
1523
  hideDelay: v = 100,
1635
1524
  trigger: m = "hover",
1636
1525
  arrow: f = !0,
1637
- ...u
1526
+ ...p
1638
1527
  }) => {
1639
- const [h, y] = T(!1), [b, N] = T(null), B = M(null), x = M(null), _ = "clarity-tooltip", $ = !!i, L = n && l && !$;
1528
+ const [h, y] = x(!1), [b, C] = x(null), j = P(null), T = P(null), w = "clarity-tooltip", $ = !!i, S = n && l && !$;
1640
1529
  let k = "";
1641
- $ ? k = `${_}__content--custom-bg` : L ? k = `${_}__content--custom` : k = `${_}__content--${s}`;
1642
- const j = [
1643
- _,
1644
- `${_}--${t}`,
1530
+ $ ? k = `${w}__content--custom-bg` : S ? k = `${w}__content--custom` : k = `${w}__content--${s}`;
1531
+ const E = [
1532
+ w,
1533
+ `${w}--${t}`,
1645
1534
  r
1646
- ].filter(Boolean).join(" "), I = [
1647
- `${_}__content`,
1535
+ ].filter(Boolean).join(" "), R = [
1536
+ `${w}__content`,
1648
1537
  k,
1649
- f && `${_}__content--arrow`
1650
- ].filter(Boolean).join(" "), A = {}, O = {};
1651
- $ && i && (O["--tooltip-bg-color"] = i), d && (O["--tooltip-text-color"] = d), L && n && l && (O["--tooltip-product"] = n, O["--tooltip-tone"] = l);
1538
+ f && `${w}__content--arrow`
1539
+ ].filter(Boolean).join(" "), A = {}, I = {};
1540
+ $ && i && (I["--tooltip-bg-color"] = i), d && (I["--tooltip-text-color"] = d), S && n && l && (I["--tooltip-product"] = n, I["--tooltip-tone"] = l);
1652
1541
  const g = {
1653
1542
  ...A,
1654
- ...Object.keys(O).length > 0 ? O : {}
1655
- }, V = () => {
1656
- if (c) return;
1543
+ ...Object.keys(I).length > 0 ? I : {}
1544
+ }, H = () => {
1545
+ if (o) return;
1657
1546
  b && clearTimeout(b);
1658
- const P = setTimeout(() => {
1547
+ const M = setTimeout(() => {
1659
1548
  y(!0);
1660
- }, p);
1661
- N(P);
1662
- }, H = () => {
1549
+ }, u);
1550
+ C(M);
1551
+ }, V = () => {
1663
1552
  b && clearTimeout(b);
1664
- const P = setTimeout(() => {
1553
+ const M = setTimeout(() => {
1665
1554
  y(!1);
1666
1555
  }, v);
1667
- N(P);
1668
- }, W = () => {
1669
- c || y(!h);
1670
- }, q = () => {
1671
- c || V();
1556
+ C(M);
1557
+ }, F = () => {
1558
+ o || y(!h);
1672
1559
  }, X = () => {
1673
- H();
1560
+ o || H();
1561
+ }, te = () => {
1562
+ V();
1674
1563
  };
1675
- D(() => () => {
1564
+ O(() => () => {
1676
1565
  b && clearTimeout(b);
1677
1566
  }, [b]);
1678
- const F = {};
1679
- return m === "hover" ? (F.onMouseEnter = V, F.onMouseLeave = H) : m === "click" ? F.onClick = W : m === "focus" && (F.onFocus = q, F.onBlur = X), /* @__PURE__ */ w(
1567
+ const G = {};
1568
+ return m === "hover" ? (G.onMouseEnter = H, G.onMouseLeave = V) : m === "click" ? G.onClick = F : m === "focus" && (G.onFocus = X, G.onBlur = te), /* @__PURE__ */ _(
1680
1569
  "div",
1681
1570
  {
1682
- ref: x,
1683
- className: `${_}__trigger`,
1684
- ...F,
1685
- ...u,
1571
+ ref: T,
1572
+ className: `${w}__trigger`,
1573
+ ...G,
1574
+ ...p,
1686
1575
  children: [
1687
- o,
1576
+ c,
1688
1577
  h && /* @__PURE__ */ a(
1689
1578
  "div",
1690
1579
  {
1691
- ref: B,
1692
- className: j,
1580
+ ref: j,
1581
+ className: E,
1693
1582
  style: g,
1694
1583
  role: "tooltip",
1695
1584
  "aria-hidden": !h,
1696
- children: /* @__PURE__ */ a("div", { className: I, children: e })
1585
+ children: /* @__PURE__ */ a("div", { className: R, children: e })
1697
1586
  }
1698
1587
  )
1699
1588
  ]
1700
1589
  }
1701
1590
  );
1702
- }, qe = Q(null), ne = () => {
1703
- const e = Z(qe);
1591
+ }, We = U(null), ee = () => {
1592
+ const e = q(We);
1704
1593
  if (!e)
1705
1594
  throw new Error("useCommand must be used within a Command provider");
1706
1595
  return e;
1707
- }, Je = ({
1596
+ }, Fe = ({
1708
1597
  children: e,
1709
1598
  className: t = "",
1710
1599
  variant: s = "secondary",
@@ -1712,61 +1601,61 @@ const Gt = ({
1712
1601
  inputPlaceholder: l = "Search...",
1713
1602
  ...i
1714
1603
  }) => {
1715
- const [d, o] = T(""), [r, c] = T(null), [p, v] = T(!1), m = [
1604
+ const [d, c] = x(""), [r, o] = x(null), [u, v] = x(!1), m = [
1716
1605
  "clarity-command",
1717
1606
  `clarity-command--${s}`,
1718
1607
  t
1719
- ].filter(Boolean).join(" "), f = te(() => ({
1608
+ ].filter(Boolean).join(" "), f = Y(() => ({
1720
1609
  searchTerm: d,
1721
- setSearchTerm: o,
1610
+ setSearchTerm: c,
1722
1611
  value: r,
1723
- setValue: c,
1612
+ setValue: o,
1724
1613
  variant: s,
1725
1614
  texts: {
1726
1615
  empty: n,
1727
1616
  inputPlaceholder: l
1728
1617
  },
1729
- isOpen: p,
1618
+ isOpen: u,
1730
1619
  setIsOpen: v
1731
- }), [d, r, s, n, l, p]);
1732
- return /* @__PURE__ */ a(qe.Provider, { value: f, children: /* @__PURE__ */ a("div", { className: m, ...i, children: e }) });
1620
+ }), [d, r, s, n, l, u]);
1621
+ return /* @__PURE__ */ a(We.Provider, { value: f, children: /* @__PURE__ */ a("div", { className: m, ...i, children: e }) });
1733
1622
  };
1734
- Je.displayName = "Command";
1735
- const Qe = ({ placeholder: e = "Search...", variant: t, onClick: s }) => {
1736
- const { setIsOpen: n, variant: l } = ne(), [i, d] = T(!1);
1737
- D(() => {
1623
+ Fe.displayName = "Command";
1624
+ const Ge = ({ placeholder: e = "Search...", variant: t, onClick: s }) => {
1625
+ const { setIsOpen: n, variant: l } = ee(), [i, d] = x(!1);
1626
+ O(() => {
1738
1627
  d(/Mac|iPod|iPhone|iPad/.test(navigator.platform));
1739
1628
  }, []);
1740
1629
  const r = [
1741
1630
  "clarity-command-button",
1742
1631
  `clarity-command-button--${t || l}`
1743
1632
  ].filter(Boolean).join(" ");
1744
- return /* @__PURE__ */ w("button", { className: r, onClick: (p) => {
1745
- n(!0), s == null || s(p);
1633
+ return /* @__PURE__ */ _("button", { className: r, onClick: (u) => {
1634
+ n(!0), s == null || s(u);
1746
1635
  }, children: [
1747
1636
  /* @__PURE__ */ a("span", { children: e }),
1748
- /* @__PURE__ */ w("kbd", { className: "clarity-command-shortcut", children: [
1637
+ /* @__PURE__ */ _("kbd", { className: "clarity-command-shortcut", children: [
1749
1638
  i ? "⌘" : "Ctrl+",
1750
1639
  "K"
1751
1640
  ] })
1752
1641
  ] });
1753
1642
  };
1754
- Qe.displayName = "Command.Button";
1755
- const Ze = ({ children: e, ...t }) => {
1756
- const { isOpen: s, setIsOpen: n, variant: l } = ne();
1757
- return D(() => {
1643
+ Ge.displayName = "Command.Button";
1644
+ const ze = ({ children: e, ...t }) => {
1645
+ const { isOpen: s, setIsOpen: n, variant: l } = ee();
1646
+ return O(() => {
1758
1647
  const i = (d) => {
1759
1648
  d.key === "k" && (d.metaKey || d.ctrlKey) && (d.preventDefault(), n(!s));
1760
1649
  };
1761
1650
  return document.addEventListener("keydown", i), () => document.removeEventListener("keydown", i);
1762
- }, [s, n]), /* @__PURE__ */ a(K, { isOpen: s, onClose: () => n(!1), size: "large", closeOnOverlayClick: !0, children: /* @__PURE__ */ a("div", { className: `clarity-command--${l}`, children: e }) });
1651
+ }, [s, n]), /* @__PURE__ */ a(J, { isOpen: s, onClose: () => n(!1), size: "large", closeOnOverlayClick: !0, children: /* @__PURE__ */ a("div", { className: `clarity-command--${l}`, children: e }) });
1763
1652
  };
1764
- Ze.displayName = "Command.Dialog";
1765
- const Xe = ({ className: e = "", ...t }) => {
1766
- const { searchTerm: s, setSearchTerm: n, variant: l, texts: i, isOpen: d } = ne(), o = M(null);
1767
- D(() => {
1768
- var c;
1769
- d && ((c = o.current) == null || c.focus());
1653
+ ze.displayName = "Command.Dialog";
1654
+ const Ue = ({ className: e = "", ...t }) => {
1655
+ const { searchTerm: s, setSearchTerm: n, variant: l, texts: i, isOpen: d } = ee(), c = P(null);
1656
+ O(() => {
1657
+ var o;
1658
+ d && ((o = c.current) == null || o.focus());
1770
1659
  }, [d]);
1771
1660
  const r = [
1772
1661
  "clarity-command-input",
@@ -1776,84 +1665,84 @@ const Xe = ({ className: e = "", ...t }) => {
1776
1665
  return /* @__PURE__ */ a("div", { className: "clarity-command-input__wrapper", children: /* @__PURE__ */ a(
1777
1666
  "input",
1778
1667
  {
1779
- ref: o,
1668
+ ref: c,
1780
1669
  className: r,
1781
1670
  value: s,
1782
- onChange: (c) => n(c.target.value),
1671
+ onChange: (o) => n(o.target.value),
1783
1672
  placeholder: t.placeholder || i.inputPlaceholder,
1784
1673
  ...t
1785
1674
  }
1786
1675
  ) });
1787
1676
  };
1788
- Xe.displayName = "Command.Input";
1789
- const Ye = ({ children: e, className: t = "", ...s }) => {
1790
- const { searchTerm: n } = ne();
1677
+ Ue.displayName = "Command.Input";
1678
+ const qe = ({ children: e, className: t = "", ...s }) => {
1679
+ const { searchTerm: n } = ee();
1791
1680
  let l = !1;
1792
- const i = (r) => E.Children.toArray(r).map((c) => {
1681
+ const i = (r) => B.Children.toArray(r).map((o) => {
1793
1682
  var v;
1794
- if (!E.isValidElement(c)) return c;
1795
- const p = c.type.displayName;
1796
- if (p === "Command.Empty")
1683
+ if (!B.isValidElement(o)) return o;
1684
+ const u = o.type.displayName;
1685
+ if (u === "Command.Empty")
1797
1686
  return null;
1798
- if (p === "Command.Item")
1799
- return (((v = c.props.children) == null ? void 0 : v.toString().toLowerCase()) || "").includes(n.toLowerCase()) ? (l = !0, c) : null;
1800
- if (p === "Command.Group") {
1801
- const m = i(c.props.children);
1802
- return E.Children.toArray(m).some((u) => E.isValidElement(u) && u.type.displayName === "Command.Item") ? E.cloneElement(c, { ...c.props, children: m }) : null;
1687
+ if (u === "Command.Item")
1688
+ return (((v = o.props.children) == null ? void 0 : v.toString().toLowerCase()) || "").includes(n.toLowerCase()) ? (l = !0, o) : null;
1689
+ if (u === "Command.Group") {
1690
+ const m = i(o.props.children);
1691
+ return B.Children.toArray(m).some((p) => B.isValidElement(p) && p.type.displayName === "Command.Item") ? B.cloneElement(o, { ...o.props, children: m }) : null;
1803
1692
  }
1804
- return c;
1805
- }).filter(Boolean), d = i(e), o = ["clarity-command-list", t].filter(Boolean).join(" ");
1806
- return /* @__PURE__ */ w("div", { className: o, ...s, children: [
1693
+ return o;
1694
+ }).filter(Boolean), d = i(e), c = ["clarity-command-list", t].filter(Boolean).join(" ");
1695
+ return /* @__PURE__ */ _("div", { className: c, ...s, children: [
1807
1696
  d,
1808
- !l && /* @__PURE__ */ a(ye, {})
1697
+ !l && /* @__PURE__ */ a(ue, {})
1809
1698
  ] });
1810
1699
  };
1811
- Ye.displayName = "Command.List";
1812
- const ye = ({ children: e, className: t = "", ...s }) => {
1813
- const { texts: n } = ne(), l = ["clarity-command-empty", t].filter(Boolean).join(" ");
1700
+ qe.displayName = "Command.List";
1701
+ const ue = ({ children: e, className: t = "", ...s }) => {
1702
+ const { texts: n } = ee(), l = ["clarity-command-empty", t].filter(Boolean).join(" ");
1814
1703
  return /* @__PURE__ */ a("div", { className: l, ...s, children: e || s.emptyText || n.empty });
1815
1704
  };
1816
- ye.displayName = "Command.Empty";
1817
- const Ke = ({ children: e, className: t = "", ...s }) => {
1705
+ ue.displayName = "Command.Empty";
1706
+ const Je = ({ children: e, className: t = "", ...s }) => {
1818
1707
  const n = ["clarity-command-group", t].filter(Boolean).join(" ");
1819
1708
  return /* @__PURE__ */ a("div", { className: n, ...s, children: e });
1820
1709
  };
1821
- Ke.displayName = "Command.Group";
1822
- const et = ({ children: e, className: t = "", ...s }) => {
1823
- const { setValue: n, variant: l } = ne(), i = ["clarity-command-item", `clarity-command-item--${l}`, t].filter(Boolean).join(" ");
1710
+ Je.displayName = "Command.Group";
1711
+ const Qe = ({ children: e, className: t = "", ...s }) => {
1712
+ const { setValue: n, variant: l } = ee(), i = ["clarity-command-item", `clarity-command-item--${l}`, t].filter(Boolean).join(" ");
1824
1713
  return /* @__PURE__ */ a("div", { className: i, onClick: () => n((e == null ? void 0 : e.toString()) || ""), ...s, children: e });
1825
1714
  };
1826
- et.displayName = "Command.Item";
1827
- const tt = ({ className: e = "", ...t }) => {
1715
+ Qe.displayName = "Command.Item";
1716
+ const Xe = ({ className: e = "", ...t }) => {
1828
1717
  const s = ["clarity-command-separator", e].filter(Boolean).join(" ");
1829
1718
  return /* @__PURE__ */ a("hr", { className: s, ...t });
1830
1719
  };
1831
- tt.displayName = "Command.Separator";
1832
- const st = ({ children: e, className: t = "", ...s }) => {
1720
+ Xe.displayName = "Command.Separator";
1721
+ const Ye = ({ children: e, className: t = "", ...s }) => {
1833
1722
  const n = ["clarity-command-shortcut", t].filter(Boolean).join(" ");
1834
1723
  return /* @__PURE__ */ a("span", { className: n, ...s, children: e });
1835
1724
  };
1836
- st.displayName = "Command.Shortcut";
1837
- const zt = Object.assign(Je, {
1838
- Button: Qe,
1839
- Dialog: Ze,
1840
- Input: Xe,
1841
- List: Ye,
1842
- Empty: ye,
1843
- Group: Ke,
1844
- Item: et,
1845
- Separator: tt,
1846
- Shortcut: st
1847
- }), Bt = ({ columns: e, viewMode: t }) => {
1725
+ Ye.displayName = "Command.Shortcut";
1726
+ const Rt = Object.assign(Fe, {
1727
+ Button: Ge,
1728
+ Dialog: ze,
1729
+ Input: Ue,
1730
+ List: qe,
1731
+ Empty: ue,
1732
+ Group: Je,
1733
+ Item: Qe,
1734
+ Separator: Xe,
1735
+ Shortcut: Ye
1736
+ }), Nt = ({ columns: e, viewMode: t }) => {
1848
1737
  const s = Array.from({ length: 5 }, (n, l) => l);
1849
- return t === "card" ? /* @__PURE__ */ w("div", { className: "card-view-wrapper is-loading", children: [
1738
+ return t === "card" ? /* @__PURE__ */ _("div", { className: "card-view-wrapper is-loading", children: [
1850
1739
  /* @__PURE__ */ a("div", { className: "skeleton card-view-header" }),
1851
1740
  /* @__PURE__ */ a("div", { className: "card-view-body", children: s.map((n) => /* @__PURE__ */ a("div", { className: "skeleton card-view-row" }, n)) })
1852
- ] }) : /* @__PURE__ */ a("div", { className: "table-wrapper is-loading", children: /* @__PURE__ */ w("table", { children: [
1741
+ ] }) : /* @__PURE__ */ a("div", { className: "table-wrapper is-loading", children: /* @__PURE__ */ _("table", { children: [
1853
1742
  /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ a("tr", { className: "table-row", children: e.map((n) => /* @__PURE__ */ a("th", { className: "table-header-cell", children: /* @__PURE__ */ a("div", { className: "skeleton skeleton-text" }) }, n.key)) }) }),
1854
1743
  /* @__PURE__ */ a("tbody", { children: s.map((n) => /* @__PURE__ */ a("tr", { className: "table-row", children: e.map((l) => /* @__PURE__ */ a("td", { className: "table-cell", children: /* @__PURE__ */ a("div", { className: "skeleton skeleton-text" }) }, l.key)) }, n)) })
1855
1744
  ] }) });
1856
- }, Ut = ({
1745
+ }, Dt = ({
1857
1746
  variant: e = "secondary",
1858
1747
  columns: t,
1859
1748
  data: s,
@@ -1861,47 +1750,47 @@ const zt = Object.assign(Je, {
1861
1750
  isScrollable: l = !1,
1862
1751
  isLoading: i = !1
1863
1752
  }) => {
1864
- const [d, o] = T(null), [r, c] = T("none"), p = (u) => {
1865
- u.sortable && (d === u.key ? c((h) => h === "asc" ? "desc" : h === "desc" ? "none" : "asc") : (o(u.key), c("asc")));
1866
- }, v = te(() => r === "none" || !d ? s : [...s].sort((u, h) => {
1867
- const y = u[d], b = h[d];
1753
+ const [d, c] = x(null), [r, o] = x("none"), u = (p) => {
1754
+ p.sortable && (d === p.key ? o((h) => h === "asc" ? "desc" : h === "desc" ? "none" : "asc") : (c(p.key), o("asc")));
1755
+ }, v = Y(() => r === "none" || !d ? s : [...s].sort((p, h) => {
1756
+ const y = p[d], b = h[d];
1868
1757
  return y < b ? r === "asc" ? -1 : 1 : y > b ? r === "asc" ? 1 : -1 : 0;
1869
- }), [s, d, r]), m = (u) => u.sortable ? d !== u.key || r === "none" ? /* @__PURE__ */ a("span", { className: "sort-icon", children: "↕" }) : r === "asc" ? /* @__PURE__ */ a("span", { className: "sort-icon", children: "↑" }) : /* @__PURE__ */ a("span", { className: "sort-icon", children: "↓" }) : null;
1758
+ }), [s, d, r]), m = (p) => p.sortable ? d !== p.key || r === "none" ? /* @__PURE__ */ a("span", { className: "sort-icon", children: "↕" }) : r === "asc" ? /* @__PURE__ */ a("span", { className: "sort-icon", children: "↑" }) : /* @__PURE__ */ a("span", { className: "sort-icon", children: "↓" }) : null;
1870
1759
  if (i)
1871
- return /* @__PURE__ */ a(Bt, { columns: t, viewMode: n });
1760
+ return /* @__PURE__ */ a(Nt, { columns: t, viewMode: n });
1872
1761
  const f = `table-variant-${e} ${l ? "is-scrollable" : ""}`;
1873
- return n === "card" ? /* @__PURE__ */ w("div", { className: `card-view-wrapper ${f}`, children: [
1874
- /* @__PURE__ */ a("div", { className: `card-view-header table-header-cell-${e}`, children: t.map((u) => /* @__PURE__ */ w(
1762
+ return n === "card" ? /* @__PURE__ */ _("div", { className: `card-view-wrapper ${f}`, children: [
1763
+ /* @__PURE__ */ a("div", { className: `card-view-header table-header-cell-${e}`, children: t.map((p) => /* @__PURE__ */ _(
1875
1764
  "div",
1876
1765
  {
1877
- className: `card-view-header-cell ${u.sortable ? "sortable" : ""}`,
1878
- onClick: () => p(u),
1879
- style: { minWidth: u.minWidth },
1766
+ className: `card-view-header-cell ${p.sortable ? "sortable" : ""}`,
1767
+ onClick: () => u(p),
1768
+ style: { minWidth: p.minWidth },
1880
1769
  children: [
1881
- u.header,
1882
- m(u)
1770
+ p.header,
1771
+ m(p)
1883
1772
  ]
1884
1773
  },
1885
- u.key
1774
+ p.key
1886
1775
  )) }),
1887
- /* @__PURE__ */ a("div", { className: "card-view-body", children: v.map((u, h) => /* @__PURE__ */ a("div", { className: `card-view-row table-row-${e}`, children: t.map((y) => /* @__PURE__ */ a("div", { className: `card-view-cell ${y.align ? `table-cell-align-${y.align}` : ""}`, style: { minWidth: y.minWidth }, children: y.render ? y.render(u) : u[y.key] }, y.key)) }, h)) })
1888
- ] }) : /* @__PURE__ */ a("div", { className: `table-wrapper ${f}`, children: /* @__PURE__ */ w("table", { children: [
1889
- /* @__PURE__ */ a("thead", { className: "table-header", children: /* @__PURE__ */ a("tr", { className: "table-row", children: t.map((u) => /* @__PURE__ */ w(
1776
+ /* @__PURE__ */ a("div", { className: "card-view-body", children: v.map((p, h) => /* @__PURE__ */ a("div", { className: `card-view-row table-row-${e}`, children: t.map((y) => /* @__PURE__ */ a("div", { className: `card-view-cell ${y.align ? `table-cell-align-${y.align}` : ""}`, style: { minWidth: y.minWidth }, children: y.render ? y.render(p) : p[y.key] }, y.key)) }, h)) })
1777
+ ] }) : /* @__PURE__ */ a("div", { className: `table-wrapper ${f}`, children: /* @__PURE__ */ _("table", { children: [
1778
+ /* @__PURE__ */ a("thead", { className: "table-header", children: /* @__PURE__ */ a("tr", { className: "table-row", children: t.map((p) => /* @__PURE__ */ _(
1890
1779
  "th",
1891
1780
  {
1892
- className: `table-header-cell ${u.sortable ? "sortable" : ""} table-header-cell-${e}`,
1893
- onClick: () => p(u),
1894
- style: { minWidth: u.minWidth },
1781
+ className: `table-header-cell ${p.sortable ? "sortable" : ""} table-header-cell-${e}`,
1782
+ onClick: () => u(p),
1783
+ style: { minWidth: p.minWidth },
1895
1784
  children: [
1896
- u.header,
1897
- m(u)
1785
+ p.header,
1786
+ m(p)
1898
1787
  ]
1899
1788
  },
1900
- u.key
1789
+ p.key
1901
1790
  )) }) }),
1902
- /* @__PURE__ */ a("tbody", { children: v.map((u, h) => /* @__PURE__ */ a("tr", { className: `table-row table-row-${e}`, children: t.map((y) => /* @__PURE__ */ a("td", { className: `table-cell ${y.align ? `table-cell-align-${y.align}` : ""}`, style: { minWidth: y.minWidth }, children: y.render ? y.render(u) : u[y.key] }, y.key)) }, h)) })
1791
+ /* @__PURE__ */ a("tbody", { children: v.map((p, h) => /* @__PURE__ */ a("tr", { className: `table-row table-row-${e}`, children: t.map((y) => /* @__PURE__ */ a("td", { className: `table-cell ${y.align ? `table-cell-align-${y.align}` : ""}`, style: { minWidth: y.minWidth }, children: y.render ? y.render(p) : p[y.key] }, y.key)) }, h)) })
1903
1792
  ] }) });
1904
- }, qt = ({
1793
+ }, At = ({
1905
1794
  variant: e = "primary",
1906
1795
  product: t,
1907
1796
  tone: s,
@@ -1909,7 +1798,7 @@ const zt = Object.assign(Je, {
1909
1798
  color: l,
1910
1799
  className: i = "",
1911
1800
  "aria-label": d = "Carregando...",
1912
- ...o
1801
+ ...c
1913
1802
  }) => {
1914
1803
  const r = "clarity-spinner", v = l ? `${r}--custom` : t && s ? `${r}--custom` : `${r}--${e}`, m = [
1915
1804
  r,
@@ -1924,7 +1813,7 @@ const zt = Object.assign(Je, {
1924
1813
  style: f,
1925
1814
  role: "status",
1926
1815
  "aria-label": d,
1927
- ...o,
1816
+ ...c,
1928
1817
  children: /* @__PURE__ */ a("div", { className: `${r}__container`, children: /* @__PURE__ */ a(
1929
1818
  "svg",
1930
1819
  {
@@ -1946,7 +1835,7 @@ const zt = Object.assign(Je, {
1946
1835
  ) })
1947
1836
  }
1948
1837
  );
1949
- }, jt = ({
1838
+ }, bt = ({
1950
1839
  className: e = "",
1951
1840
  noGutters: t,
1952
1841
  justify: s,
@@ -1955,17 +1844,17 @@ const zt = Object.assign(Je, {
1955
1844
  as: i = "div",
1956
1845
  ...d
1957
1846
  }) => {
1958
- const o = [
1847
+ const c = [
1959
1848
  "clarity-row",
1960
1849
  t ? "clarity-row--no-gutters" : "",
1961
1850
  s ? `clarity-row--justify-${s}` : "",
1962
1851
  n ? `clarity-row--align-${n}` : "",
1963
1852
  e
1964
1853
  ].filter(Boolean).join(" ");
1965
- return E.createElement(i, { className: o, ...d }, l);
1854
+ return B.createElement(i, { className: c, ...d }, l);
1966
1855
  };
1967
- jt.displayName = "Row";
1968
- const Et = (e) => `${e / 12 * 100}%`, Lt = (e) => `${e / 12 * 100}%`, St = ({
1856
+ bt.displayName = "Row";
1857
+ const Ct = (e) => `${e / 12 * 100}%`, _t = (e) => `${e / 12 * 100}%`, wt = ({
1969
1858
  className: e = "",
1970
1859
  xs: t,
1971
1860
  sm: s,
@@ -1973,48 +1862,27 @@ const Et = (e) => `${e / 12 * 100}%`, Lt = (e) => `${e / 12 * 100}%`, St = ({
1973
1862
  lg: l,
1974
1863
  xl: i,
1975
1864
  xxl: d,
1976
- offset: o,
1865
+ offset: c,
1977
1866
  children: r,
1978
- as: c = "div",
1979
- style: p,
1867
+ as: o = "div",
1868
+ style: u,
1980
1869
  ...v
1981
1870
  }) => {
1982
- const m = { ...p }, f = (y, b) => {
1871
+ const m = { ...u }, f = (y, b) => {
1983
1872
  if (b === void 0) return;
1984
- const N = `--clarity-col-width-${y}`;
1985
- m[N] = typeof b == "number" ? Et(b) : "auto";
1986
- }, u = (y, b) => {
1873
+ const C = `--clarity-col-width-${y}`;
1874
+ m[C] = typeof b == "number" ? Ct(b) : "auto";
1875
+ }, p = (y, b) => {
1987
1876
  if (b === void 0) return;
1988
- const N = `--clarity-col-offset-${y}`;
1989
- m[N] = Lt(b);
1877
+ const C = `--clarity-col-offset-${y}`;
1878
+ m[C] = _t(b);
1990
1879
  };
1991
- f("xs", t), f("sm", s), f("md", n), f("lg", l), f("xl", i), f("xxl", d), u("xs", o == null ? void 0 : o.xs), u("sm", o == null ? void 0 : o.sm), u("md", o == null ? void 0 : o.md), u("lg", o == null ? void 0 : o.lg), u("xl", o == null ? void 0 : o.xl), u("xxl", o == null ? void 0 : o.xxl);
1880
+ f("xs", t), f("sm", s), f("md", n), f("lg", l), f("xl", i), f("xxl", d), p("xs", c == null ? void 0 : c.xs), p("sm", c == null ? void 0 : c.sm), p("md", c == null ? void 0 : c.md), p("lg", c == null ? void 0 : c.lg), p("xl", c == null ? void 0 : c.xl), p("xxl", c == null ? void 0 : c.xxl);
1992
1881
  const h = ["clarity-col", e].filter(Boolean).join(" ");
1993
- return E.createElement(c, { className: h, style: m, ...v }, r);
1882
+ return B.createElement(o, { className: h, style: m, ...v }, r);
1994
1883
  };
1995
- St.displayName = "Col";
1996
- const at = ({ children: e, className: t, ...s }) => /* @__PURE__ */ a(de, { as: "header", p: 4, borderBottomWidth: 1, borderColor: "gray.200", className: t, ...s, children: e });
1997
- at.displayName = "Card.Header";
1998
- const nt = ({ children: e, className: t, ...s }) => /* @__PURE__ */ a(de, { p: 4, className: t, ...s, children: e });
1999
- nt.displayName = "Card.Content";
2000
- const lt = ({ children: e, className: t, ...s }) => /* @__PURE__ */ a(de, { as: "footer", p: 4, borderTopWidth: 1, borderColor: "gray.200", display: "flex", justifyContent: "flex-end", gap: 3, className: t, ...s, children: e });
2001
- lt.displayName = "Card.Footer";
2002
- const me = ({ children: e, bg: t = "white", ...s }) => /* @__PURE__ */ a(
2003
- de,
2004
- {
2005
- bg: t,
2006
- borderRadius: 3,
2007
- boxShadow: 1,
2008
- overflow: "hidden",
2009
- ...s,
2010
- children: e
2011
- }
2012
- );
2013
- me.Header = at;
2014
- me.Content = nt;
2015
- me.Footer = lt;
2016
- me.displayName = "Card";
2017
- const Jt = {
1884
+ wt.displayName = "Col";
1885
+ const Pt = {
2018
1886
  primary: {
2019
1887
  50: "#f0f9ff",
2020
1888
  100: "#e0f2fe",
@@ -2063,7 +1931,7 @@ const Jt = {
2063
1931
  800: "#065f46",
2064
1932
  900: "#064e3b"
2065
1933
  }
2066
- }, Qt = {
1934
+ }, Vt = {
2067
1935
  xs: "4px",
2068
1936
  sm: "8px",
2069
1937
  md: "16px",
@@ -2071,38 +1939,56 @@ const Jt = {
2071
1939
  xl: "32px",
2072
1940
  "2xl": "48px",
2073
1941
  "3xl": "64px"
2074
- }, Zt = (...e) => e.filter(Boolean).join(" "), Xt = () => Math.random().toString(36).substr(2, 9);
1942
+ }, Mt = {
1943
+ fontFamily: {
1944
+ sans: ["Inter", "system-ui", "sans-serif"],
1945
+ mono: ["Fira Code", "monospace"]
1946
+ },
1947
+ fontSize: {
1948
+ xs: "12px",
1949
+ sm: "14px",
1950
+ base: "16px",
1951
+ lg: "18px",
1952
+ xl: "20px",
1953
+ "2xl": "24px",
1954
+ "3xl": "30px"
1955
+ },
1956
+ fontWeight: {
1957
+ normal: 400,
1958
+ medium: 500,
1959
+ semibold: 600,
1960
+ bold: 700
1961
+ }
1962
+ }, Ht = (...e) => e.filter(Boolean).join(" "), Wt = () => Math.random().toString(36).substr(2, 9);
2075
1963
  export {
2076
- Ft as Accordion,
2077
- Dt as Badge,
2078
- de as Box,
2079
- At as Button,
2080
- Pt as ButtonGroup,
2081
- Mt as ButtonIcon,
2082
- Wt as ButtonLink,
2083
- me as Card,
2084
- vt as CheckInput,
2085
- St as Col,
2086
- zt as Command,
2087
- ee as ConfirmationDialog,
2088
- oe as Dropdown,
2089
- ut as Input,
2090
- bt as InputSwitch,
2091
- K as Modal,
2092
- ht as MultiSelect,
2093
- ae as Offcanvas,
2094
- jt as Row,
2095
- ft as Select,
2096
- qt as Spinner,
2097
- Ut as Table,
2098
- he as Tabs,
2099
- pt as Textarea,
2100
- Ht as ToastProvider,
2101
- Gt as Tooltip,
2102
- Zt as cn,
2103
- Jt as colors,
2104
- Xt as generateId,
2105
- Qt as spacing,
2106
- ve as typography,
2107
- Vt as useToast
1964
+ Ot as Accordion,
1965
+ xt as Badge,
1966
+ Tt as Button,
1967
+ Bt as ButtonGroup,
1968
+ Lt as ButtonIcon,
1969
+ St as ButtonLink,
1970
+ rt as CheckInput,
1971
+ wt as Col,
1972
+ Rt as Command,
1973
+ Q as ConfirmationDialog,
1974
+ ae as Dropdown,
1975
+ st as Input,
1976
+ ct as InputSwitch,
1977
+ J as Modal,
1978
+ lt as MultiSelect,
1979
+ K as Offcanvas,
1980
+ bt as Row,
1981
+ nt as Select,
1982
+ At as Spinner,
1983
+ Dt as Table,
1984
+ me as Tabs,
1985
+ at as Textarea,
1986
+ Et as ToastProvider,
1987
+ It as Tooltip,
1988
+ Ht as cn,
1989
+ Pt as colors,
1990
+ Wt as generateId,
1991
+ Vt as spacing,
1992
+ Mt as typography,
1993
+ jt as useToast
2108
1994
  };