@dimasbaguspm/versaur 0.0.19 → 0.0.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/dist/js/bottom-sheet-DbtyWwsy.js +493 -0
  2. package/dist/js/{selectable-multiple-input-CJXfqy1Z.js → bottom-sheet-input-C7cYfBaK.js} +591 -476
  3. package/dist/js/forms/index.js +20 -17
  4. package/dist/js/{image-rectangle-CLU-GVtw.js → image-rectangle-DH7v2xvp.js} +300 -395
  5. package/dist/js/index.js +63 -56
  6. package/dist/js/layouts/index.js +5 -4
  7. package/dist/js/overlays/index.js +6 -4
  8. package/dist/js/primitive/index.js +10 -9
  9. package/dist/js/side-bar-CHhcp0yS.js +397 -0
  10. package/dist/js/text-CRsIInRA.js +127 -0
  11. package/dist/js/tooltip-CDdl1U3A.js +148 -0
  12. package/dist/types/forms/bottom-sheet-input/bottom-sheet-input.d.ts +7 -0
  13. package/dist/types/forms/bottom-sheet-input/index.d.ts +2 -0
  14. package/dist/types/forms/bottom-sheet-input/types.d.ts +17 -0
  15. package/dist/types/forms/drawer-input/drawer-input.d.ts +6 -0
  16. package/dist/types/forms/drawer-input/index.d.ts +2 -0
  17. package/dist/types/forms/drawer-input/types.d.ts +18 -0
  18. package/dist/types/forms/index.d.ts +3 -0
  19. package/dist/types/forms/modal-input/index.d.ts +2 -0
  20. package/dist/types/forms/modal-input/modal-input.d.ts +6 -0
  21. package/dist/types/forms/modal-input/types.d.ts +18 -0
  22. package/dist/types/layouts/index.d.ts +1 -0
  23. package/dist/types/layouts/side-bar/index.d.ts +2 -0
  24. package/dist/types/layouts/side-bar/side-bar.atoms.d.ts +3 -0
  25. package/dist/types/layouts/side-bar/side-bar.d.ts +5 -0
  26. package/dist/types/layouts/side-bar/types.d.ts +42 -0
  27. package/dist/types/overlays/bottom-sheet/types.d.ts +2 -1
  28. package/dist/types/overlays/drawer/types.d.ts +2 -1
  29. package/dist/types/overlays/index.d.ts +1 -0
  30. package/dist/types/overlays/menu/menu.atoms.d.ts +5 -10
  31. package/dist/types/overlays/menu/menu.d.ts +2 -6
  32. package/dist/types/overlays/menu/types.d.ts +9 -14
  33. package/dist/types/overlays/menu/use-menu.d.ts +0 -1
  34. package/dist/types/overlays/modal/modal.d.ts +14 -5
  35. package/dist/types/overlays/modal/types.d.ts +7 -20
  36. package/dist/types/overlays/tooltip/index.d.ts +2 -0
  37. package/dist/types/overlays/tooltip/tooltip.d.ts +5 -0
  38. package/dist/types/overlays/tooltip/types.d.ts +33 -0
  39. package/dist/types/overlays/tooltip/use-tooltip-position.d.ts +8 -0
  40. package/dist/types/primitive/table/table.atoms.d.ts +4 -6
  41. package/dist/types/primitive/table/table.d.ts +2 -1
  42. package/dist/types/primitive/table/types.d.ts +7 -4
  43. package/dist/utils/enforce-subpath-import.js +5 -0
  44. package/package.json +1 -1
  45. package/dist/js/bottom-sheet-BRv-oJL-.js +0 -646
  46. package/dist/js/form-layout-4ASWdXn8.js +0 -302
  47. package/dist/types/overlays/modal/use-escape-close.d.ts +0 -6
  48. package/dist/types/overlays/modal/use-focus-trap.d.ts +0 -6
@@ -1,44 +1,10 @@
1
1
  import { c as cva, j as jsxRuntimeExports, a as cn } from "./index-DOdDlCoL.js";
2
2
  import * as React from "react";
3
- import React__default, { forwardRef, useState, useEffect, useCallback, useRef, createContext, useContext, useMemo } from "react";
3
+ import React__default, { forwardRef, useState, useEffect, useCallback, useRef, createContext, useContext } from "react";
4
4
  import { X, ChevronLeft, ChevronRight, ImageOff } from "lucide-react";
5
+ import { T as Text } from "./text-CRsIInRA.js";
5
6
  import { S as Skeleton } from "./skeleton-BNZyaRjo.js";
6
- const iconVariants = cva("inline-flex items-center justify-center", {
7
- variants: {
8
- size: {
9
- xs: "w-3 h-3",
10
- sm: "w-4 h-4",
11
- md: "w-5 h-5",
12
- lg: "w-6 h-6",
13
- xl: "w-8 h-8"
14
- },
15
- color: {
16
- primary: "text-primary",
17
- secondary: "text-secondary",
18
- tertiary: "text-tertiary",
19
- ghost: "text-ghost",
20
- neutral: "text-neutral",
21
- success: "text-success",
22
- info: "text-info",
23
- warning: "text-warning",
24
- danger: "text-danger",
25
- inherit: ""
26
- }
27
- },
28
- defaultVariants: {
29
- size: "md",
30
- color: "primary"
31
- }
32
- }), Icon = React__default.forwardRef(function({ as: t, color: r = "primary", size: s = "md", className: n, ...o }, i) {
33
- return /* @__PURE__ */ jsxRuntimeExports.jsx(
34
- t,
35
- {
36
- ref: i,
37
- className: iconVariants({ color: r, size: s, className: n }),
38
- ...o
39
- }
40
- );
41
- }), alertVariants = cva(
7
+ const alertVariants = cva(
42
8
  "relative flex items-center gap-2 rounded-md p-2 text-sm transition-all duration-200",
43
9
  {
44
10
  variants: {
@@ -181,18 +147,18 @@ const iconVariants = cva("inline-flex items-center justify-center", {
181
147
  color: t = "neutral",
182
148
  icon: r,
183
149
  className: s,
184
- children: n,
185
- ...o
150
+ children: o,
151
+ ...n
186
152
  }, i) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
187
153
  "div",
188
154
  {
189
155
  ref: i,
190
156
  role: "alert",
191
157
  className: cn(alertVariants({ variant: e, color: t }), s),
192
- ...o,
158
+ ...n,
193
159
  children: [
194
160
  r && /* @__PURE__ */ jsxRuntimeExports.jsx(AlertIcon, { children: r }),
195
- /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", children: n })
161
+ /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", children: o })
196
162
  ]
197
163
  }
198
164
  )
@@ -261,15 +227,15 @@ const iconVariants = cva("inline-flex items-center justify-center", {
261
227
  className: t,
262
228
  color: r = "primary",
263
229
  fontSize: s = "base",
264
- fontWeight: n = "medium",
265
- quiet: o = !1,
230
+ fontWeight: o = "medium",
231
+ quiet: n = !1,
266
232
  ...i
267
233
  }, a) => /* @__PURE__ */ jsxRuntimeExports.jsx(
268
234
  "a",
269
235
  {
270
236
  ref: a,
271
237
  className: cn(
272
- anchorVariants({ color: r, fontSize: s, fontWeight: n, quiet: o }),
238
+ anchorVariants({ color: r, fontSize: s, fontWeight: o, quiet: n }),
273
239
  t
274
240
  ),
275
241
  ...i,
@@ -320,38 +286,38 @@ const iconVariants = cva("inline-flex items-center justify-center", {
320
286
  size: t = "md",
321
287
  shape: r = "circle",
322
288
  className: s,
323
- children: n,
324
- ...o
289
+ children: o,
290
+ ...n
325
291
  }, i) => /* @__PURE__ */ jsxRuntimeExports.jsx(
326
292
  "div",
327
293
  {
328
294
  ref: i,
329
295
  className: cn(avatarVariants({ variant: e, size: t, shape: r }), s),
330
- ...o,
331
- children: n
296
+ ...n,
297
+ children: o
332
298
  }
333
299
  )
334
300
  ), AvatarImage = forwardRef(
335
- ({ src: e, alt: t, className: r, onError: s, ...n }, o) => {
301
+ ({ src: e, alt: t, className: r, onError: s, ...o }, n) => {
336
302
  const [i, a] = useState(!1);
337
303
  useEffect(() => {
338
304
  a(!1);
339
305
  }, [e]);
340
- const u = useCallback(
341
- (l) => {
342
- a(!0), s?.(l);
306
+ const g = useCallback(
307
+ (c) => {
308
+ a(!0), s?.(c);
343
309
  },
344
310
  [s]
345
311
  );
346
312
  return i ? null : /* @__PURE__ */ jsxRuntimeExports.jsx(
347
313
  "img",
348
314
  {
349
- ref: o,
315
+ ref: n,
350
316
  src: e,
351
317
  alt: t,
352
318
  className: cn(avatarImageVariants(), r),
353
- onError: u,
354
- ...n
319
+ onError: g,
320
+ ...o
355
321
  }
356
322
  );
357
323
  }
@@ -519,17 +485,17 @@ const iconVariants = cva("inline-flex items-center justify-center", {
519
485
  shape: t = "square",
520
486
  color: r = "primary",
521
487
  size: s = "md",
522
- iconLeft: n,
523
- iconRight: o,
488
+ iconLeft: o,
489
+ iconRight: n,
524
490
  className: i,
525
491
  children: a,
526
- ...u
527
- }, l) => {
528
- const f = !(a != null && a !== "") && !!(n || o);
492
+ ...g
493
+ }, c) => {
494
+ const f = !(a != null && a !== "") && !!(o || n);
529
495
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
530
496
  "span",
531
497
  {
532
- ref: l,
498
+ ref: c,
533
499
  className: cn(
534
500
  badgeVariants({
535
501
  variant: e,
@@ -540,16 +506,16 @@ const iconVariants = cva("inline-flex items-center justify-center", {
540
506
  }),
541
507
  i
542
508
  ),
543
- ...u,
509
+ ...g,
544
510
  children: f ? (
545
511
  // Icon-only mode: display only the icon
546
- n || o
512
+ o || n
547
513
  ) : (
548
514
  // Normal mode: display icon(s) and text
549
515
  /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
550
- n,
516
+ o,
551
517
  a,
552
- o
518
+ n
553
519
  ] })
554
520
  )
555
521
  }
@@ -572,13 +538,13 @@ const SvgSpenicleSquare = (e) => /* @__PURE__ */ React.createElement("svg", { wi
572
538
  }
573
539
  }), BrandLogo = forwardRef(
574
540
  ({ shape: e = "square", size: t, ...r }, s) => {
575
- const o = {
541
+ const n = {
576
542
  square: SvgSpenicleSquare,
577
543
  rounded: SvgSpenicleRounded,
578
544
  circle: SvgSpenicleCircle
579
545
  }[e] || SvgSpenicleSquare;
580
546
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
581
- o,
547
+ n,
582
548
  {
583
549
  ref: s,
584
550
  ...r,
@@ -587,10 +553,10 @@ const SvgSpenicleSquare = (e) => /* @__PURE__ */ React.createElement("svg", { wi
587
553
  );
588
554
  }
589
555
  ), Brand = forwardRef(
590
- ({ name: e = "spenicle", size: t = "md", shape: r, ...s }, n) => /* @__PURE__ */ jsxRuntimeExports.jsx(
556
+ ({ name: e = "spenicle", size: t = "md", shape: r, ...s }, o) => /* @__PURE__ */ jsxRuntimeExports.jsx(
591
557
  "span",
592
558
  {
593
- ref: n,
559
+ ref: o,
594
560
  className: cn("inline-flex items-center gap-2"),
595
561
  ...s,
596
562
  children: /* @__PURE__ */ jsxRuntimeExports.jsx(BrandLogo, { shape: r, size: t, "aria-hidden": "true" })
@@ -651,20 +617,20 @@ const SvgSpenicleSquare = (e) => /* @__PURE__ */ React.createElement("svg", { wi
651
617
  className: t,
652
618
  variant: r = "primary",
653
619
  size: s = "md",
654
- disabled: n = !1,
655
- type: o = "button",
620
+ disabled: o = !1,
621
+ type: n = "button",
656
622
  children: i,
657
623
  ...a
658
- }, u) {
624
+ }, g) {
659
625
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
660
626
  "button",
661
627
  {
662
- ref: u,
663
- type: o,
628
+ ref: g,
629
+ type: n,
664
630
  className: cn(buttonVariants({ variant: r, size: s }), t),
665
- disabled: n,
666
- "aria-disabled": n,
667
- inert: n ? !0 : void 0,
631
+ disabled: o,
632
+ "aria-disabled": o,
633
+ inert: o ? !0 : void 0,
668
634
  ...a,
669
635
  children: i
670
636
  }
@@ -738,64 +704,64 @@ const SvgSpenicleSquare = (e) => /* @__PURE__ */ React.createElement("svg", { wi
738
704
  }
739
705
  );
740
706
  function useFloatingPosition(e, t = "1rem") {
741
- const r = useRef(null), [s, n] = useState({}), [o, i] = useState("fixed bottom-4 right-4"), a = useCallback(() => {
742
- const l = r.current;
743
- if (!l) return;
744
- const h = l.getBoundingClientRect().height > window.innerHeight;
707
+ const r = useRef(null), [s, o] = useState({}), [n, i] = useState("fixed bottom-4 right-4"), a = useCallback(() => {
708
+ const c = r.current;
709
+ if (!c) return;
710
+ const b = c.getBoundingClientRect().height > window.innerHeight;
745
711
  let f = {}, p = "";
746
- h ? (f = {
712
+ b ? (f = {
747
713
  position: "fixed",
748
714
  bottom: t,
749
715
  zIndex: 50,
750
- transform: `translateY(${l.scrollTop}px)`
716
+ transform: `translateY(${c.scrollTop}px)`
751
717
  }, p = `fixed bottom-4 ${e}-4`) : (f = {
752
718
  position: "fixed",
753
719
  bottom: t,
754
720
  zIndex: 50
755
- }, p = `fixed bottom-4 ${e}-4`), n(f), i(p);
721
+ }, p = `fixed bottom-4 ${e}-4`), o(f), i(p);
756
722
  }, [e, t]);
757
723
  return useEffect(() => {
758
724
  a();
759
- const l = r.current;
760
- return l && l.addEventListener("scroll", a), window.addEventListener("resize", a), () => {
761
- l && l.removeEventListener("scroll", a), window.removeEventListener("resize", a);
725
+ const c = r.current;
726
+ return c && c.addEventListener("scroll", a), window.addEventListener("resize", a), () => {
727
+ c && c.removeEventListener("scroll", a), window.removeEventListener("resize", a);
762
728
  };
763
729
  }, [a]), useEffect(() => {
764
730
  r.current && a();
765
731
  }, [e, t, a]), [useCallback(
766
- (l) => {
767
- r.current = l, l && a();
732
+ (c) => {
733
+ r.current = c, c && a();
768
734
  },
769
735
  [a]
770
- ), s, o];
736
+ ), s, n];
771
737
  }
772
738
  const ButtonFloat = forwardRef(
773
739
  function({
774
740
  className: t,
775
741
  variant: r = "primary",
776
742
  size: s = "md",
777
- side: n = "right",
778
- offset: o = "1rem",
743
+ side: o = "right",
744
+ offset: n = "1rem",
779
745
  ...i
780
746
  }, a) {
781
- const [u, l, x] = useFloatingPosition(
782
- n,
783
- o
784
- ), [h, f] = useState(!1);
747
+ const [g, c, m] = useFloatingPosition(
748
+ o,
749
+ n
750
+ ), [b, f] = useState(!1);
785
751
  return useEffect(() => {
786
752
  f(!0);
787
- }, []), /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: u, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
753
+ }, []), /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: g, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
788
754
  "button",
789
755
  {
790
756
  ref: a,
791
757
  type: i.type || "button",
792
758
  className: cn(
793
759
  buttonFloatVariants({ variant: r, size: s }),
794
- x,
795
- h && "animate-fab-in",
760
+ m,
761
+ b && "animate-fab-in",
796
762
  t
797
763
  ),
798
- style: l,
764
+ style: c,
799
765
  ...i
800
766
  }
801
767
  ) });
@@ -894,35 +860,70 @@ const buttonIconVariants = cva(
894
860
  shape: "rounded"
895
861
  }
896
862
  }
897
- ), ButtonIcon = React__default.forwardRef(
863
+ ), iconVariants = cva("inline-flex items-center justify-center", {
864
+ variants: {
865
+ size: {
866
+ xs: "w-3 h-3",
867
+ sm: "w-4 h-4",
868
+ md: "w-5 h-5",
869
+ lg: "w-6 h-6",
870
+ xl: "w-8 h-8"
871
+ },
872
+ color: {
873
+ primary: "text-primary",
874
+ secondary: "text-secondary",
875
+ tertiary: "text-tertiary",
876
+ ghost: "text-ghost",
877
+ neutral: "text-neutral",
878
+ success: "text-success",
879
+ info: "text-info",
880
+ warning: "text-warning",
881
+ danger: "text-danger",
882
+ inherit: ""
883
+ }
884
+ },
885
+ defaultVariants: {
886
+ size: "md",
887
+ color: "primary"
888
+ }
889
+ }), Icon = React__default.forwardRef(function({ as: t, color: r = "primary", size: s = "md", className: o, ...n }, i) {
890
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(
891
+ t,
892
+ {
893
+ ref: i,
894
+ className: iconVariants({ color: r, size: s, className: o }),
895
+ ...n
896
+ }
897
+ );
898
+ }), ButtonIcon = React__default.forwardRef(
898
899
  function({
899
900
  className: t,
900
901
  variant: r = "primary",
901
902
  size: s = "md",
902
- shape: n = "rounded",
903
- disabled: o = !1,
903
+ shape: o = "rounded",
904
+ disabled: n = !1,
904
905
  as: i,
905
906
  "aria-label": a,
906
- ...u
907
- }, l) {
907
+ ...g
908
+ }, c) {
908
909
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
909
910
  "button",
910
911
  {
911
- ref: l,
912
+ ref: c,
912
913
  type: "button",
913
914
  className: cn(
914
915
  buttonIconVariants({
915
916
  variant: r,
916
917
  size: s,
917
- shape: n
918
+ shape: o
918
919
  }),
919
920
  t
920
921
  ),
921
- disabled: o,
922
- "aria-disabled": o,
922
+ disabled: n,
923
+ "aria-disabled": n,
923
924
  "aria-label": a,
924
- inert: o ? !0 : void 0,
925
- ...u,
925
+ inert: n ? !0 : void 0,
926
+ ...g,
926
927
  children: /* @__PURE__ */ jsxRuntimeExports.jsx(
927
928
  Icon,
928
929
  {
@@ -1050,9 +1051,9 @@ const BUTTONS = [
1050
1051
  onChange: t,
1051
1052
  disabled: r,
1052
1053
  className: s,
1053
- "aria-label": n
1054
- }, o) => {
1055
- const { input: i, inputRef: a, handleButton: u, handleInput: l } = useCalculator({
1054
+ "aria-label": o
1055
+ }, n) => {
1056
+ const { input: i, inputRef: a, handleButton: g, handleInput: c } = useCalculator({
1056
1057
  initialValue: e,
1057
1058
  disabled: r,
1058
1059
  onChange: t
@@ -1060,9 +1061,9 @@ const BUTTONS = [
1060
1061
  return /* @__PURE__ */ jsxRuntimeExports.jsxs(
1061
1062
  "div",
1062
1063
  {
1063
- ref: o,
1064
+ ref: n,
1064
1065
  className: cn(calculatorRootVariants({ disabled: r }), s),
1065
- "aria-label": n || "Calculator",
1066
+ "aria-label": o || "Calculator",
1066
1067
  role: "region",
1067
1068
  children: [
1068
1069
  /* @__PURE__ */ jsxRuntimeExports.jsx(
@@ -1071,20 +1072,20 @@ const BUTTONS = [
1071
1072
  ref: a,
1072
1073
  className: "w-full mb-3 px-3 py-2 rounded border border-[var(--color-neutral)] bg-[var(--color-neutral-soft)] text-right text-xl font-mono focus:outline-none focus:ring-2 focus:ring-[var(--color-primary)]",
1073
1074
  value: i,
1074
- onChange: l,
1075
+ onChange: c,
1075
1076
  disabled: r,
1076
1077
  inputMode: "decimal",
1077
1078
  "aria-label": "Calculator input"
1078
1079
  }
1079
1080
  ),
1080
- /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col gap-1 mb-3", children: BUTTONS.map((x, h) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex w-full", children: x.map((f) => f === "⌫" ? /* @__PURE__ */ jsxRuntimeExports.jsx(
1081
+ /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col gap-1 mb-3", children: BUTTONS.map((m, b) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex w-full", children: m.map((f) => f === "⌫" ? /* @__PURE__ */ jsxRuntimeExports.jsx(
1081
1082
  ButtonIcon,
1082
1083
  {
1083
1084
  as: X,
1084
1085
  variant: "danger-ghost",
1085
1086
  "aria-label": "Backspace",
1086
1087
  size: "md",
1087
- onClick: () => u("⌫"),
1088
+ onClick: () => g("⌫"),
1088
1089
  disabled: r
1089
1090
  },
1090
1091
  "backspace"
@@ -1092,141 +1093,20 @@ const BUTTONS = [
1092
1093
  CalculatorButton,
1093
1094
  {
1094
1095
  variant: f === "=" ? "action" : f === "C" ? "danger" : ["/", "*", "-", "+", "/"].includes(f) ? "operator" : "default",
1095
- onClick: () => u(f),
1096
+ onClick: () => g(f),
1096
1097
  disabled: r,
1097
1098
  "aria-label": f,
1098
1099
  children: f
1099
1100
  },
1100
1101
  f
1101
- )) }, h)) })
1102
+ )) }, b)) })
1102
1103
  ]
1103
1104
  }
1104
1105
  );
1105
1106
  }
1106
1107
  );
1107
1108
  Calculator.displayName = "Calculator";
1108
- const textVariants = cva("", {
1109
- variants: {
1110
- color: {
1111
- primary: "text-primary",
1112
- secondary: "text-secondary",
1113
- tertiary: "text-tertiary",
1114
- ghost: "text-ghost",
1115
- neutral: "text-ghost",
1116
- success: "text-success",
1117
- info: "text-info",
1118
- warning: "text-warning",
1119
- danger: "text-danger",
1120
- inherit: "",
1121
- gray: "text-gray-500",
1122
- black: "text-black",
1123
- white: "text-white"
1124
- },
1125
- hasUnderline: {
1126
- true: "underline",
1127
- false: ""
1128
- },
1129
- isCapitalize: {
1130
- true: "capitalize",
1131
- false: ""
1132
- },
1133
- align: {
1134
- left: "text-left",
1135
- center: "text-center",
1136
- right: "text-right",
1137
- justify: "text-justify"
1138
- },
1139
- italic: {
1140
- true: "italic",
1141
- false: ""
1142
- },
1143
- clamp: {
1144
- 1: "line-clamp-1",
1145
- 2: "line-clamp-2",
1146
- 3: "line-clamp-3",
1147
- 4: "line-clamp-4",
1148
- 5: "line-clamp-5",
1149
- none: ""
1150
- },
1151
- ellipsis: {
1152
- true: "truncate",
1153
- false: ""
1154
- },
1155
- as: {
1156
- h1: "font-bold text-4xl leading-loose",
1157
- h2: "font-semibold text-3xl leading-relaxed",
1158
- h3: "font-medium text-2xl leading-relaxed",
1159
- h4: "font-bold text-xl leading-normal",
1160
- h5: "font-semibold text-lg leading-normal",
1161
- h6: "font-medium text-base leading-normal",
1162
- p: "font-normal text-base leading-normal",
1163
- span: "font-normal text-base leading-normal",
1164
- label: "font-normal text-xs leading-normal"
1165
- }
1166
- },
1167
- defaultVariants: {
1168
- color: "neutral",
1169
- hasUnderline: !1,
1170
- isCapitalize: !1,
1171
- align: "left",
1172
- italic: !1,
1173
- clamp: "none",
1174
- ellipsis: !1,
1175
- as: "span"
1176
- }
1177
- }), Text = forwardRef(
1178
- ({
1179
- as: e = "span",
1180
- color: t = "ghost",
1181
- hasUnderline: r = !1,
1182
- isCapitalize: s = !1,
1183
- align: n = "left",
1184
- italic: o = !1,
1185
- clamp: i = "none",
1186
- ellipsis: a = !1,
1187
- fontSize: u,
1188
- fontWeight: l,
1189
- className: x,
1190
- children: h,
1191
- ...f
1192
- }, p) => {
1193
- const d = [
1194
- "h1",
1195
- "h2",
1196
- "h3",
1197
- "h4",
1198
- "h5",
1199
- "h6",
1200
- "p",
1201
- "span",
1202
- "label"
1203
- ].includes(e) ? e : "span", v = u ? `text-${u}` : "", w = l ? `font-${l}` : "";
1204
- return /* @__PURE__ */ jsxRuntimeExports.jsx(
1205
- e,
1206
- {
1207
- ref: p,
1208
- className: cn(
1209
- textVariants({
1210
- color: t,
1211
- hasUnderline: r,
1212
- isCapitalize: s,
1213
- align: n,
1214
- italic: o,
1215
- clamp: i,
1216
- ellipsis: a,
1217
- // @ts-expect-error - `as` is not a valid variant
1218
- as: d
1219
- }),
1220
- v,
1221
- w,
1222
- x
1223
- ),
1224
- ...f,
1225
- children: h
1226
- }
1227
- );
1228
- }
1229
- ), CalendarContext = createContext(null);
1109
+ const CalendarContext = createContext(null);
1230
1110
  function useCalendarContext() {
1231
1111
  const e = useContext(CalendarContext);
1232
1112
  if (!e)
@@ -1269,27 +1149,27 @@ const CalendarHeader = () => {
1269
1149
  ] })
1270
1150
  ] });
1271
1151
  }, CalendarWeekdays = () => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "grid grid-cols-7 px-4 text-ghost-500 mb-3", children: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"].map((e) => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { fontSize: "xs", color: "ghost", align: "center", children: e }, e)) }), CalendarDaysSingle = () => {
1272
- const e = useCalendarContext(), { year: t, month: r, value: s, onChange: n, setMonth: o, setYear: i } = e, a = (g, m) => new Date(g, m + 1, 0).getDate(), l = ((g, m) => new Date(g, m, 1).getDay())(t, r), x = a(t, r), h = r - 1 < 0 ? 11 : r - 1, f = r === 0 ? t - 1 : t, p = a(t, h), y = r === 11 ? 0 : r + 1, d = r === 11 ? t + 1 : t, v = [];
1273
- for (let g = 0; g < l; g++) {
1274
- const m = p - l + g + 1;
1152
+ const e = useCalendarContext(), { year: t, month: r, value: s, onChange: o, setMonth: n, setYear: i } = e, a = (u, x) => new Date(u, x + 1, 0).getDate(), c = ((u, x) => new Date(u, x, 1).getDay())(t, r), m = a(t, r), b = r - 1 < 0 ? 11 : r - 1, f = r === 0 ? t - 1 : t, p = a(t, b), y = r === 11 ? 0 : r + 1, d = r === 11 ? t + 1 : t, v = [];
1153
+ for (let u = 0; u < c; u++) {
1154
+ const x = p - c + u + 1;
1275
1155
  v.push(
1276
1156
  /* @__PURE__ */ jsxRuntimeExports.jsx(
1277
1157
  ButtonIcon,
1278
1158
  {
1279
- as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: m }),
1159
+ as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: x }),
1280
1160
  size: "sm",
1281
1161
  "aria-label": "Previous month day",
1282
1162
  variant: "ghost",
1283
1163
  onClick: () => {
1284
- n?.(new Date(f, h, m)), o(h), i(f);
1164
+ o?.(new Date(f, b, x)), n(b), i(f);
1285
1165
  }
1286
1166
  },
1287
- "prev-" + g
1167
+ "prev-" + u
1288
1168
  )
1289
1169
  );
1290
1170
  }
1291
- for (let g = 1; g <= x; g++) {
1292
- const m = s instanceof Date && s.getFullYear() === t && s.getMonth() === r && s.getDate() === g;
1171
+ for (let u = 1; u <= m; u++) {
1172
+ const x = s instanceof Date && s.getFullYear() === t && s.getMonth() === r && s.getDate() === u;
1293
1173
  v.push(
1294
1174
  /* @__PURE__ */ jsxRuntimeExports.jsx(
1295
1175
  ButtonIcon,
@@ -1299,71 +1179,71 @@ const CalendarHeader = () => {
1299
1179
  {
1300
1180
  as: "span",
1301
1181
  fontSize: "sm",
1302
- color: m ? "inherit" : "ghost",
1303
- className: m ? "bg-primary text-white rounded-full" : "",
1304
- children: g
1182
+ color: x ? "inherit" : "ghost",
1183
+ className: x ? "bg-primary text-white rounded-full" : "",
1184
+ children: u
1305
1185
  }
1306
1186
  ),
1307
- variant: m ? "primary" : "ghost",
1187
+ variant: x ? "primary" : "ghost",
1308
1188
  size: "sm",
1309
- "aria-label": `Select ${t}-${r + 1}-${g}`,
1310
- "aria-current": m ? "date" : void 0,
1189
+ "aria-label": `Select ${t}-${r + 1}-${u}`,
1190
+ "aria-current": x ? "date" : void 0,
1311
1191
  onClick: () => {
1312
- n?.(new Date(t, r, g));
1192
+ o?.(new Date(t, r, u));
1313
1193
  }
1314
1194
  },
1315
- g
1195
+ u
1316
1196
  )
1317
1197
  );
1318
1198
  }
1319
- const w = l + x;
1320
- for (let g = 0; g < (w % 7 === 0 ? 0 : 7 - w % 7); g++)
1199
+ const w = c + m;
1200
+ for (let u = 0; u < (w % 7 === 0 ? 0 : 7 - w % 7); u++)
1321
1201
  v.push(
1322
1202
  /* @__PURE__ */ jsxRuntimeExports.jsx(
1323
1203
  ButtonIcon,
1324
1204
  {
1325
- as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: g + 1 }),
1205
+ as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: u + 1 }),
1326
1206
  size: "sm",
1327
1207
  "aria-label": "Next month day",
1328
1208
  variant: "ghost",
1329
1209
  onClick: () => {
1330
- n?.(new Date(d, y, g + 1)), o(y), i(d);
1210
+ o?.(new Date(d, y, u + 1)), n(y), i(d);
1331
1211
  }
1332
1212
  },
1333
- "next-" + g
1213
+ "next-" + u
1334
1214
  )
1335
1215
  );
1336
1216
  return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "grid grid-cols-7 gap-2 px-4 pb-4", children: v });
1337
1217
  }, CalendarDaysRange = () => {
1338
- const { year: e, month: t, value: r, onChange: s, setMonth: n, setYear: o } = useCalendarContext(), i = (c, b) => new Date(c, b + 1, 0).getDate(), u = ((c, b) => new Date(c, b, 1).getDay())(e, t), l = i(e, t), x = t - 1 < 0 ? 11 : t - 1, h = t === 0 ? e - 1 : e, f = i(e, x), p = t === 11 ? 0 : t + 1, y = t === 11 ? e + 1 : e, d = [], v = () => {
1218
+ const { year: e, month: t, value: r, onChange: s, setMonth: o, setYear: n } = useCalendarContext(), i = (l, h) => new Date(l, h + 1, 0).getDate(), g = ((l, h) => new Date(l, h, 1).getDay())(e, t), c = i(e, t), m = t - 1 < 0 ? 11 : t - 1, b = t === 0 ? e - 1 : e, f = i(e, m), p = t === 11 ? 0 : t + 1, y = t === 11 ? e + 1 : e, d = [], v = () => {
1339
1219
  if (!Array.isArray(r)) return [null, null];
1340
- const [c, b] = r;
1341
- return !c && !b ? [null, null] : c && b ? c <= b ? [c, b] : [b, c] : [c, b];
1342
- }, [w, g] = v(), m = (c) => {
1343
- if (!w || !g) return !1;
1344
- const b = new Date(e, t, c);
1345
- return b >= w && b <= g;
1346
- }, I = (c) => w ? w.getFullYear() === e && w.getMonth() === t && w.getDate() === c : !1, N = (c) => g ? g.getFullYear() === e && g.getMonth() === t && g.getDate() === c : !1;
1347
- for (let c = 0; c < u; c++) {
1348
- const b = f - u + c + 1;
1220
+ const [l, h] = r;
1221
+ return !l && !h ? [null, null] : l && h ? l <= h ? [l, h] : [h, l] : [l, h];
1222
+ }, [w, u] = v(), x = (l) => {
1223
+ if (!w || !u) return !1;
1224
+ const h = new Date(e, t, l);
1225
+ return h >= w && h <= u;
1226
+ }, S = (l) => w ? w.getFullYear() === e && w.getMonth() === t && w.getDate() === l : !1, N = (l) => u ? u.getFullYear() === e && u.getMonth() === t && u.getDate() === l : !1;
1227
+ for (let l = 0; l < g; l++) {
1228
+ const h = f - g + l + 1;
1349
1229
  d.push(
1350
1230
  /* @__PURE__ */ jsxRuntimeExports.jsx(
1351
1231
  ButtonIcon,
1352
1232
  {
1353
- as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: b }),
1233
+ as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: h }),
1354
1234
  size: "sm",
1355
1235
  "aria-label": "Previous month day",
1356
1236
  variant: "ghost",
1357
1237
  onClick: () => {
1358
- s?.([null, null]), n(x), o(h);
1238
+ s?.([null, null]), o(m), n(b);
1359
1239
  }
1360
1240
  },
1361
- "prev-" + c
1241
+ "prev-" + l
1362
1242
  )
1363
1243
  );
1364
1244
  }
1365
- for (let c = 1; c <= l; c++) {
1366
- const b = m(c), C = I(c), E = N(c);
1245
+ for (let l = 1; l <= c; l++) {
1246
+ const h = x(l), E = S(l), C = N(l);
1367
1247
  d.push(
1368
1248
  /* @__PURE__ */ jsxRuntimeExports.jsx(
1369
1249
  ButtonIcon,
@@ -1373,47 +1253,47 @@ const CalendarHeader = () => {
1373
1253
  {
1374
1254
  as: "span",
1375
1255
  fontSize: "sm",
1376
- color: b || C || E ? "inherit" : "ghost",
1256
+ color: h || E || C ? "inherit" : "ghost",
1377
1257
  className: cn(
1378
- b && " bg-primary text-white",
1379
- C && "rounded-l-full bg-primary text-white",
1380
- E && "rounded-r-full bg-primary text-white"
1258
+ h && " bg-primary text-white",
1259
+ E && "rounded-l-full bg-primary text-white",
1260
+ C && "rounded-r-full bg-primary text-white"
1381
1261
  ),
1382
- children: c
1262
+ children: l
1383
1263
  }
1384
1264
  ),
1385
- variant: C || E || b ? "primary" : "ghost",
1265
+ variant: E || C || h ? "primary" : "ghost",
1386
1266
  size: "sm",
1387
- "aria-label": `Select ${e}-${t + 1}-${c}`,
1388
- "aria-current": C || E ? "date" : void 0,
1267
+ "aria-label": `Select ${e}-${t + 1}-${l}`,
1268
+ "aria-current": E || C ? "date" : void 0,
1389
1269
  onClick: () => {
1390
1270
  if (!Array.isArray(r) || !r[0] || r[0] && r[1])
1391
- s?.([new Date(e, t, c), null]);
1271
+ s?.([new Date(e, t, l), null]);
1392
1272
  else if (r[0] && !r[1]) {
1393
- const j = r[0], R = new Date(e, t, c);
1273
+ const j = r[0], R = new Date(e, t, l);
1394
1274
  j.getTime() === R.getTime() ? s?.([j, R]) : s?.(j < R ? [j, R] : [R, j]);
1395
1275
  }
1396
1276
  }
1397
1277
  },
1398
- c
1278
+ l
1399
1279
  )
1400
1280
  );
1401
1281
  }
1402
- const S = u + l;
1403
- for (let c = 0; c < (S % 7 === 0 ? 0 : 7 - S % 7); c++)
1282
+ const I = g + c;
1283
+ for (let l = 0; l < (I % 7 === 0 ? 0 : 7 - I % 7); l++)
1404
1284
  d.push(
1405
1285
  /* @__PURE__ */ jsxRuntimeExports.jsx(
1406
1286
  ButtonIcon,
1407
1287
  {
1408
- as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: c + 1 }),
1288
+ as: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", color: "tertiary", children: l + 1 }),
1409
1289
  size: "sm",
1410
1290
  "aria-label": "Next month day",
1411
1291
  variant: "ghost",
1412
1292
  onClick: () => {
1413
- s?.([null, null]), n(p), o(y);
1293
+ s?.([null, null]), o(p), n(y);
1414
1294
  }
1415
1295
  },
1416
- "next-" + c
1296
+ "next-" + l
1417
1297
  )
1418
1298
  );
1419
1299
  return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "grid grid-cols-7 gap-2 px-4 pb-4", children: d });
@@ -1426,32 +1306,32 @@ function useCalendar({
1426
1306
  type: t,
1427
1307
  onChange: r,
1428
1308
  initialYear: s,
1429
- initialMonth: n
1309
+ initialMonth: o
1430
1310
  }) {
1431
- const [o, i] = useState(n), [a, u] = useState(s), [l, x] = useState([
1311
+ const [n, i] = useState(o), [a, g] = useState(s), [c, m] = useState([
1432
1312
  null,
1433
1313
  null
1434
1314
  ]);
1435
- let h = e;
1436
- t === "range" && !e && (h = l);
1315
+ let b = e;
1316
+ t === "range" && !e && (b = c);
1437
1317
  const f = useCallback(() => {
1438
- const d = o === 0 ? 11 : o - 1, v = o === 0 ? a - 1 : a;
1439
- i(d), u(v), t === "single" && r?.(new Date(v, d, 1));
1440
- }, [o, a, t, r]), p = useCallback(() => {
1441
- const d = o === 11 ? 0 : o + 1, v = o === 11 ? a + 1 : a;
1442
- i(d), u(v), t === "single" && r?.(new Date(v, d, 1));
1443
- }, [o, a, t, r]), y = useCallback(
1318
+ const d = n === 0 ? 11 : n - 1, v = n === 0 ? a - 1 : a;
1319
+ i(d), g(v), t === "single" && r?.(new Date(v, d, 1));
1320
+ }, [n, a, t, r]), p = useCallback(() => {
1321
+ const d = n === 11 ? 0 : n + 1, v = n === 11 ? a + 1 : a;
1322
+ i(d), g(v), t === "single" && r?.(new Date(v, d, 1));
1323
+ }, [n, a, t, r]), y = useCallback(
1444
1324
  (d) => {
1445
- t === "single" ? r?.(d) : t === "range" && (x(d), r?.(d));
1325
+ t === "single" ? r?.(d) : t === "range" && (m(d), r?.(d));
1446
1326
  },
1447
1327
  [t, r]
1448
1328
  );
1449
1329
  return {
1450
1330
  year: a,
1451
- month: o,
1452
- value: h,
1331
+ month: n,
1332
+ value: b,
1453
1333
  setMonth: i,
1454
- setYear: u,
1334
+ setYear: g,
1455
1335
  onChange: y,
1456
1336
  handlePrevMonth: f,
1457
1337
  handleNextMonth: p
@@ -1462,14 +1342,14 @@ const CalendarRoot = ({
1462
1342
  onChange: t,
1463
1343
  className: r,
1464
1344
  type: s = "single",
1465
- ...n
1345
+ ...o
1466
1346
  }) => {
1467
- const o = /* @__PURE__ */ new Date(), i = useCalendar({
1347
+ const n = /* @__PURE__ */ new Date(), i = useCalendar({
1468
1348
  value: e,
1469
1349
  onChange: t,
1470
1350
  type: s,
1471
- initialYear: o.getFullYear(),
1472
- initialMonth: o.getMonth()
1351
+ initialYear: n.getFullYear(),
1352
+ initialMonth: n.getMonth()
1473
1353
  });
1474
1354
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
1475
1355
  CalendarContext.Provider,
@@ -1483,7 +1363,7 @@ const CalendarRoot = ({
1483
1363
  setYear: i.setYear,
1484
1364
  onChange: i.onChange
1485
1365
  },
1486
- children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("select-none", r), ...n, children: [
1366
+ children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("select-none", r), ...o, children: [
1487
1367
  /* @__PURE__ */ jsxRuntimeExports.jsx(CalendarHeader, {}),
1488
1368
  /* @__PURE__ */ jsxRuntimeExports.jsx(CalendarWeekdays, {}),
1489
1369
  /* @__PURE__ */ jsxRuntimeExports.jsx(CalendarDays, {})
@@ -1561,7 +1441,7 @@ const getTableColumnClass = (e) => {
1561
1441
  }
1562
1442
  }, TableHeader = forwardRef(
1563
1443
  ({ children: e, className: t, ...r }, s) => {
1564
- const { maxColumns: n } = useTableContext();
1444
+ const { columns: o } = useTableContext();
1565
1445
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
1566
1446
  "div",
1567
1447
  {
@@ -1573,7 +1453,7 @@ const getTableColumnClass = (e) => {
1573
1453
  "div",
1574
1454
  {
1575
1455
  role: "row",
1576
- className: cn("grid gap-4", getTableColumnClass(n)),
1456
+ className: cn("grid gap-4", getTableColumnClass(o)),
1577
1457
  children: e
1578
1458
  }
1579
1459
  )
@@ -1584,7 +1464,7 @@ const getTableColumnClass = (e) => {
1584
1464
  ({ children: e, className: t, ...r }, s) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { role: "rowgroup", ref: s, className: cn(t), ...r, children: e })
1585
1465
  ), TableFooter = forwardRef(
1586
1466
  ({ children: e, className: t, ...r }, s) => {
1587
- const { maxColumns: n } = useTableContext();
1467
+ const { columns: o } = useTableContext();
1588
1468
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
1589
1469
  "div",
1590
1470
  {
@@ -1596,7 +1476,7 @@ const getTableColumnClass = (e) => {
1596
1476
  "div",
1597
1477
  {
1598
1478
  role: "row",
1599
- className: cn("grid gap-4", getTableColumnClass(n)),
1479
+ className: cn("grid gap-4", getTableColumnClass(o)),
1600
1480
  children: e
1601
1481
  }
1602
1482
  )
@@ -1605,14 +1485,14 @@ const getTableColumnClass = (e) => {
1605
1485
  }
1606
1486
  ), TableRow = forwardRef(
1607
1487
  ({ children: e, className: t, ...r }, s) => {
1608
- const { maxColumns: n } = useTableContext();
1488
+ const { columns: o } = useTableContext();
1609
1489
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
1610
1490
  "div",
1611
1491
  {
1612
1492
  role: "row",
1613
1493
  className: cn(
1614
1494
  "grid gap-4",
1615
- getTableColumnClass(n),
1495
+ getTableColumnClass(o),
1616
1496
  "border-b border-border last:border-0",
1617
1497
  t
1618
1498
  ),
@@ -1623,10 +1503,10 @@ const getTableColumnClass = (e) => {
1623
1503
  );
1624
1504
  }
1625
1505
  ), TableColumn = forwardRef(
1626
- ({ as: e = "td", span: t, align: r = "left", children: s, className: n, ...o }, i) => {
1506
+ ({ as: e = "td", span: t, align: r = "left", children: s, className: o, ...n }, i) => {
1627
1507
  const a = e === "th" ? "columnheader" : "cell";
1628
- let u = "text-left";
1629
- return r === "center" ? u = "text-center" : r === "right" && (u = "text-right"), /* @__PURE__ */ jsxRuntimeExports.jsx(
1508
+ let g = "text-left";
1509
+ return r === "center" ? g = "text-center" : r === "right" && (g = "text-right"), /* @__PURE__ */ jsxRuntimeExports.jsx(
1630
1510
  "div",
1631
1511
  {
1632
1512
  ref: i,
@@ -1635,40 +1515,66 @@ const getTableColumnClass = (e) => {
1635
1515
  "px-4 py-2",
1636
1516
  "[&:not(:last-child)]:border-r [&:not(:last-child)]:border-border",
1637
1517
  getRowSpanClass(t),
1638
- u,
1639
- n
1518
+ g,
1519
+ "truncate overflow-hidden whitespace-nowrap",
1520
+ o
1640
1521
  ),
1641
- ...o,
1522
+ ...n,
1642
1523
  children: s
1643
1524
  }
1644
1525
  );
1645
1526
  }
1527
+ ), TableRowItem = forwardRef(
1528
+ (e, t) => /* @__PURE__ */ jsxRuntimeExports.jsx(
1529
+ TableColumn,
1530
+ {
1531
+ ...e,
1532
+ as: "td",
1533
+ ref: t,
1534
+ className: cn(
1535
+ "truncate overflow-hidden whitespace-nowrap",
1536
+ e.className
1537
+ )
1538
+ }
1539
+ )
1540
+ ), TableHeaderItem = forwardRef(
1541
+ (e, t) => /* @__PURE__ */ jsxRuntimeExports.jsx(
1542
+ TableColumn,
1543
+ {
1544
+ ...e,
1545
+ as: "th",
1546
+ ref: t,
1547
+ className: cn(
1548
+ "truncate overflow-hidden whitespace-nowrap",
1549
+ e.className
1550
+ )
1551
+ }
1552
+ )
1646
1553
  ), TableRoot = forwardRef(
1647
- ({ children: e, className: t, maxColumns: r = 12, ...s }, n) => {
1648
- const o = useMemo(
1649
- () => ({ maxColumns: r }),
1650
- [r]
1651
- );
1652
- return /* @__PURE__ */ jsxRuntimeExports.jsx(TableProvider, { value: o, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
1653
- "div",
1654
- {
1655
- ref: n,
1656
- role: "table",
1657
- className: cn(
1658
- "w-full overflow-x-auto rounded-lg border border-border",
1659
- t
1660
- ),
1661
- ...s,
1662
- children: e
1663
- }
1664
- ) });
1665
- }
1554
+ ({ children: e, className: t, columns: r = 12, ...s }, o) => /* @__PURE__ */ jsxRuntimeExports.jsx(TableProvider, { value: { columns: r }, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
1555
+ "div",
1556
+ {
1557
+ ref: o,
1558
+ role: "table",
1559
+ className: cn(
1560
+ // Versaur design system: border, background, shadow, rounded, spacing
1561
+ "w-full overflow-x-auto border border-border bg-background rounded-lg ",
1562
+ "text-foreground",
1563
+ "sm:rounded-xl",
1564
+ "transition-colors",
1565
+ t
1566
+ ),
1567
+ ...s,
1568
+ children: e
1569
+ }
1570
+ ) })
1666
1571
  ), Table = Object.assign(TableRoot, {
1667
1572
  Header: TableHeader,
1573
+ HeaderItem: TableHeaderItem,
1668
1574
  Body: TableBody,
1669
1575
  Footer: TableFooter,
1670
1576
  Row: TableRow,
1671
- Column: TableColumn
1577
+ RowItem: TableRowItem
1672
1578
  }), tileVariants = cva(
1673
1579
  // Base classes
1674
1580
  "block transition-colors duration-200",
@@ -1705,12 +1611,12 @@ const getTableColumnClass = (e) => {
1705
1611
  }
1706
1612
  }
1707
1613
  ), Tile = forwardRef(
1708
- ({ variant: e = "white", size: t = "md", shape: r = "rounded", className: s, ...n }, o) => /* @__PURE__ */ jsxRuntimeExports.jsx(
1614
+ ({ variant: e = "white", size: t = "md", shape: r = "rounded", className: s, ...o }, n) => /* @__PURE__ */ jsxRuntimeExports.jsx(
1709
1615
  "div",
1710
1616
  {
1711
- ref: o,
1617
+ ref: n,
1712
1618
  className: cn(tileVariants({ variant: e, size: t, shape: r }), s),
1713
- ...n
1619
+ ...o
1714
1620
  }
1715
1621
  )
1716
1622
  );
@@ -1744,19 +1650,19 @@ function getColSpan(e = 4) {
1744
1650
  return "col-span-4";
1745
1651
  }
1746
1652
  }
1747
- const DescriptionListItem = forwardRef(function e({ children: t, className: r, span: s = 4, ...n }, o) {
1653
+ const DescriptionListItem = forwardRef(function e({ children: t, className: r, span: s = 4, ...o }, n) {
1748
1654
  const i = getColSpan(s);
1749
- return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: o, className: cn(i, r), ...n, children: t });
1655
+ return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: n, className: cn(i, r), ...o, children: t });
1750
1656
  }), DescriptionListTerm = forwardRef(function e({ children: t, ...r }, s) {
1751
1657
  return /* @__PURE__ */ jsxRuntimeExports.jsx("dt", { ref: s, ...r, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "sm", fontWeight: "medium", color: "gray", children: t }) });
1752
- }), DescriptionListDetails = forwardRef(function e({ children: t, color: r = "black", ...s }, n) {
1753
- return /* @__PURE__ */ jsxRuntimeExports.jsx("dd", { ref: n, ...s, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "base", fontWeight: "medium", color: r, children: t }) });
1658
+ }), DescriptionListDetails = forwardRef(function e({ children: t, color: r = "black", ...s }, o) {
1659
+ return /* @__PURE__ */ jsxRuntimeExports.jsx("dd", { ref: o, ...s, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { as: "span", fontSize: "base", fontWeight: "medium", color: r, children: t }) });
1754
1660
  }), DescriptionListRoot = forwardRef(
1755
- function e({ children: t, className: r, ...s }, n) {
1661
+ function e({ children: t, className: r, ...s }, o) {
1756
1662
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
1757
1663
  "dl",
1758
1664
  {
1759
- ref: n,
1665
+ ref: o,
1760
1666
  className: cn("grid grid-cols-12 gap-y-4", r),
1761
1667
  ...s,
1762
1668
  children: t
@@ -1769,20 +1675,20 @@ const DescriptionListItem = forwardRef(function e({ children: t, className: r, s
1769
1675
  Details: DescriptionListDetails
1770
1676
  });
1771
1677
  function useImage({ src: e }) {
1772
- const [t, r] = useState(!1), [s, n] = useState(!1), o = useRef(!1), i = () => {
1678
+ const [t, r] = useState(!1), [s, o] = useState(!1), n = useRef(!1), i = () => {
1773
1679
  r(!0);
1774
1680
  }, a = () => {
1775
- n(!0);
1681
+ o(!0);
1776
1682
  };
1777
1683
  return useEffect(() => {
1778
1684
  if (!e) return;
1779
- const u = new Image();
1780
- return u.src = e, u.onload = () => {
1781
- o.current || r(!0);
1782
- }, u.onerror = () => {
1783
- o.current || n(!0);
1685
+ const g = new Image();
1686
+ return g.src = e, g.onload = () => {
1687
+ n.current || r(!0);
1688
+ }, g.onerror = () => {
1689
+ n.current || o(!0);
1784
1690
  }, () => {
1785
- o.current = !0;
1691
+ n.current = !0;
1786
1692
  };
1787
1693
  }, [e]), {
1788
1694
  loaded: t,
@@ -1849,13 +1755,13 @@ function BaseImageSkeleton({
1849
1755
  shape: t,
1850
1756
  size: r,
1851
1757
  height: s,
1852
- width: n
1758
+ width: o
1853
1759
  }) {
1854
1760
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
1855
1761
  Skeleton,
1856
1762
  {
1857
1763
  className: cn(imageAtomVariants({ shape: t, size: r }), e),
1858
- style: { height: s, width: n }
1764
+ style: { height: s, width: o }
1859
1765
  }
1860
1766
  );
1861
1767
  }
@@ -1864,15 +1770,15 @@ function BaseImageFallback({
1864
1770
  width: t,
1865
1771
  height: r,
1866
1772
  className: s,
1867
- style: n,
1868
- shape: o,
1773
+ style: o,
1774
+ shape: n,
1869
1775
  size: i
1870
1776
  }) {
1871
1777
  return /* @__PURE__ */ jsxRuntimeExports.jsxs(
1872
1778
  "div",
1873
1779
  {
1874
- className: imageAtomVariants({ shape: o, size: i, className: s }),
1875
- style: { width: t, height: r, ...n },
1780
+ className: imageAtomVariants({ shape: n, size: i, className: s }),
1781
+ style: { width: t, height: r, ...o },
1876
1782
  "aria-label": e,
1877
1783
  role: "img",
1878
1784
  children: [
@@ -1895,32 +1801,32 @@ const BaseImage = forwardRef(
1895
1801
  alt: t,
1896
1802
  onLoad: r,
1897
1803
  onError: s,
1898
- width: n,
1899
- height: o,
1804
+ width: o,
1805
+ height: n,
1900
1806
  loading: i = "lazy",
1901
1807
  position: a = "cover",
1902
- size: u = "auto",
1903
- shape: l,
1904
- className: x,
1905
- ...h
1808
+ size: g = "auto",
1809
+ shape: c,
1810
+ className: m,
1811
+ ...b
1906
1812
  }, f) => {
1907
1813
  const { loaded: p, errored: y, handleLoad: d, handleError: v } = useImage({
1908
1814
  src: e
1909
- }), w = typeof n == "number" ? n : Number(n), g = typeof o == "number" ? o : Number(o);
1815
+ }), w = typeof o == "number" ? o : Number(o), u = typeof n == "number" ? n : Number(n);
1910
1816
  return !p && !y ? /* @__PURE__ */ jsxRuntimeExports.jsx(
1911
1817
  BaseImageSkeleton,
1912
1818
  {
1913
- shape: l,
1819
+ shape: c,
1914
1820
  width: w,
1915
- height: g
1821
+ height: u
1916
1822
  }
1917
1823
  ) : y ? /* @__PURE__ */ jsxRuntimeExports.jsx(
1918
1824
  BaseImageFallback,
1919
1825
  {
1920
- shape: l,
1826
+ shape: c,
1921
1827
  alt: t,
1922
1828
  width: w,
1923
- height: g
1829
+ height: u
1924
1830
  }
1925
1831
  ) : /* @__PURE__ */ jsxRuntimeExports.jsx(
1926
1832
  "img",
@@ -1929,23 +1835,23 @@ const BaseImage = forwardRef(
1929
1835
  src: e,
1930
1836
  alt: t,
1931
1837
  width: w,
1932
- height: g,
1838
+ height: u,
1933
1839
  loading: i,
1934
1840
  className: cn(
1935
1841
  imageVariants({
1936
1842
  position: a,
1937
- size: u,
1938
- shape: l
1843
+ size: g,
1844
+ shape: c
1939
1845
  }),
1940
- x
1846
+ m
1941
1847
  ),
1942
- onLoad: (m) => {
1943
- d(), r?.(m);
1848
+ onLoad: (x) => {
1849
+ d(), r?.(x);
1944
1850
  },
1945
- onError: (m) => {
1946
- v(), s?.(m);
1851
+ onError: (x) => {
1852
+ v(), s?.(x);
1947
1853
  },
1948
- ...h
1854
+ ...b
1949
1855
  }
1950
1856
  );
1951
1857
  }
@@ -1964,10 +1870,9 @@ export {
1964
1870
  ButtonFloat as e,
1965
1871
  ButtonIcon as f,
1966
1872
  Calendar as g,
1967
- Text as h,
1968
- Tile as i,
1969
- ImageCircle as j,
1970
- ImageSquare as k,
1971
- ImageRectangle as l,
1972
- BaseImage as m
1873
+ Tile as h,
1874
+ ImageCircle as i,
1875
+ ImageSquare as j,
1876
+ ImageRectangle as k,
1877
+ BaseImage as l
1973
1878
  };