@xenide-io/the-old-ui-theme 0.2.4 → 0.2.6

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.
package/dist/index.mjs CHANGED
@@ -1,3 +1,9 @@
1
+ import {
2
+ __objRest,
3
+ __spreadProps,
4
+ __spreadValues
5
+ } from "./chunk-FWCSY2DS.mjs";
6
+
1
7
  // src/components/ui/ButtonChrome.tsx
2
8
  import { jsx, jsxs } from "react/jsx-runtime";
3
9
  function ButtonChrome({ label, icon, sideIcon, split }) {
@@ -42,19 +48,30 @@ var shapeClass = {
42
48
  square: "ph-btn-square",
43
49
  wide: "ph-btn-wide"
44
50
  };
45
- function Button({
46
- variant = "secondary",
47
- size = "md",
48
- shape = "default",
49
- outline = false,
50
- split = false,
51
- icon,
52
- sideIcon,
53
- className,
54
- children,
55
- type = "button",
56
- ...props
57
- }) {
51
+ function Button(_a) {
52
+ var _b = _a, {
53
+ variant = "secondary",
54
+ size = "md",
55
+ shape = "default",
56
+ outline = false,
57
+ split = false,
58
+ icon,
59
+ sideIcon,
60
+ className,
61
+ children,
62
+ type = "button"
63
+ } = _b, props = __objRest(_b, [
64
+ "variant",
65
+ "size",
66
+ "shape",
67
+ "outline",
68
+ "split",
69
+ "icon",
70
+ "sideIcon",
71
+ "className",
72
+ "children",
73
+ "type"
74
+ ]);
58
75
  const usesLemonChrome = variant === "primary" || variant === "secondary";
59
76
  const content = usesLemonChrome ? /* @__PURE__ */ jsx2(ButtonChrome, { label: children, icon, sideIcon, split }) : /* @__PURE__ */ jsxs2(Fragment, { children: [
60
77
  icon != null ? /* @__PURE__ */ jsx2("span", { className: "ph-btn-icon", children: icon }) : null,
@@ -64,7 +81,7 @@ function Button({
64
81
  ] });
65
82
  return /* @__PURE__ */ jsx2(
66
83
  "button",
67
- {
84
+ __spreadProps(__spreadValues({
68
85
  type,
69
86
  className: cn(
70
87
  "ph-btn",
@@ -74,39 +91,48 @@ function Button({
74
91
  shapeClass[shape],
75
92
  split && "ph-btn-split",
76
93
  className
77
- ),
78
- ...props,
94
+ )
95
+ }, props), {
79
96
  children: content
80
- }
97
+ })
81
98
  );
82
99
  }
83
100
 
84
101
  // src/components/icons/IconBase.tsx
85
102
  import { jsx as jsx3 } from "react/jsx-runtime";
86
- function IconBase({
87
- className,
88
- size,
89
- children,
90
- viewBox = "0 0 24 24",
91
- fill: fill2 = "none",
92
- xmlns = "http://www.w3.org/2000/svg",
93
- focusable = "false",
94
- ...props
95
- }) {
103
+ function IconBase(_a) {
104
+ var _b = _a, {
105
+ className,
106
+ size,
107
+ children,
108
+ viewBox = "0 0 24 24",
109
+ fill: fill2 = "none",
110
+ xmlns = "http://www.w3.org/2000/svg",
111
+ focusable = "false"
112
+ } = _b, props = __objRest(_b, [
113
+ "className",
114
+ "size",
115
+ "children",
116
+ "viewBox",
117
+ "fill",
118
+ "xmlns",
119
+ "focusable"
120
+ ]);
121
+ var _a2;
96
122
  const dimensionProps = size != null ? { width: size, height: size } : {};
97
123
  return /* @__PURE__ */ jsx3(
98
124
  "svg",
99
- {
100
- className: cn("ph-icon", className),
101
- ...dimensionProps,
125
+ __spreadProps(__spreadValues(__spreadProps(__spreadValues({
126
+ className: cn("ph-icon", className)
127
+ }, dimensionProps), {
102
128
  viewBox,
103
129
  fill: fill2,
104
130
  xmlns,
105
131
  focusable,
106
- "aria-hidden": props["aria-hidden"] ?? true,
107
- ...props,
132
+ "aria-hidden": (_a2 = props["aria-hidden"]) != null ? _a2 : true
133
+ }), props), {
108
134
  children
109
- }
135
+ })
110
136
  );
111
137
  }
112
138
 
@@ -114,7 +140,7 @@ function IconBase({
114
140
  import { jsx as jsx4 } from "react/jsx-runtime";
115
141
  function createIconBase({ viewBox = "0 0 24 24", paths }) {
116
142
  return function IconGlyph(props) {
117
- return /* @__PURE__ */ jsx4(IconBase, { viewBox, ...props, children: paths });
143
+ return /* @__PURE__ */ jsx4(IconBase, __spreadProps(__spreadValues({ viewBox }, props), { children: paths }));
118
144
  };
119
145
  }
120
146
  function createIconBasePath(d, viewBox = "0 0 24 24") {
@@ -337,8 +363,9 @@ var IconActivity = createIconBasePath(
337
363
  var IconFlask = createIconBasePath(
338
364
  "M19.8 18.4L14 10.67V6.5l1.35-1.35c.39-.39.39-1.02 0-1.41L14.65 2.7a.9959.9959 0 0 0-1.41 0L9.35 6.54c-.39.39-.39 1.02 0 1.41L10.7 9.3v4.17L4.2 18.4C3.53 19.07 4.04 20.25 5 20.25h14c.96 0 1.47-1.18.8-1.85zM6.91 18.25l5.09-5.09 5.09 5.09H6.91z"
339
365
  );
340
- function IconSpinner({ className, ...props }) {
341
- return /* @__PURE__ */ jsx5(IconSync, { className: cn("ph-icon-spin", className), ...props });
366
+ function IconSpinner(_a) {
367
+ var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
368
+ return /* @__PURE__ */ jsx5(IconSync, __spreadValues({ className: cn("ph-icon-spin", className) }, props));
342
369
  }
343
370
  var PH_ICONS = {
344
371
  activity: IconActivity,
@@ -410,9 +437,10 @@ var PH_ICONS = {
410
437
  warning: IconExclamation,
411
438
  xCircle: IconCancel
412
439
  };
413
- function IconByName({ name, ...props }) {
440
+ function IconByName(_a) {
441
+ var _b = _a, { name } = _b, props = __objRest(_b, ["name"]);
414
442
  const Icon = PH_ICONS[name];
415
- return /* @__PURE__ */ jsx5(Icon, { ...props });
443
+ return /* @__PURE__ */ jsx5(Icon, __spreadValues({}, props));
416
444
  }
417
445
 
418
446
  // src/components/ui/Alert.tsx
@@ -446,7 +474,7 @@ function Alert({
446
474
  role: "alert",
447
475
  className: cn("ph-alert", statusClassMap[status], className),
448
476
  children: [
449
- icon ?? /* @__PURE__ */ jsx6(Icon, { className: cn("mt-0.5 h-5 w-5 shrink-0", config.color) }),
477
+ icon != null ? icon : /* @__PURE__ */ jsx6(Icon, { className: cn("mt-0.5 h-5 w-5 shrink-0", config.color) }),
450
478
  /* @__PURE__ */ jsxs4("div", { className: "flex-1", children: [
451
479
  title && /* @__PURE__ */ jsx6("p", { className: "font-semibold", children: title }),
452
480
  description && /* @__PURE__ */ jsx6("p", { className: "mt-1 text-sm text-ph-subtle", children: description }),
@@ -592,12 +620,13 @@ function Drawer({
592
620
 
593
621
  // src/components/ui/Kbd.tsx
594
622
  import { jsx as jsx10 } from "react/jsx-runtime";
595
- function Kbd({ variant = "shortcut", keys, children, className, ...props }) {
623
+ function Kbd(_a) {
624
+ var _b = _a, { variant = "shortcut", keys, children, className } = _b, props = __objRest(_b, ["variant", "keys", "children", "className"]);
596
625
  if (variant === "token") {
597
- return /* @__PURE__ */ jsx10("code", { className: cn("ph-kbd text-ph-ink", className), ...props, children });
626
+ return /* @__PURE__ */ jsx10("code", __spreadProps(__spreadValues({ className: cn("ph-kbd text-ph-ink", className) }, props), { children }));
598
627
  }
599
628
  const content = (keys == null ? void 0 : keys.length) ? keys.join(" ") : normalizeShortcut(children);
600
- return /* @__PURE__ */ jsx10("kbd", { className: cn("ph-shortcut", className), ...props, children: content });
629
+ return /* @__PURE__ */ jsx10("kbd", __spreadProps(__spreadValues({ className: cn("ph-shortcut", className) }, props), { children: content }));
601
630
  }
602
631
  function normalizeShortcut(children) {
603
632
  if (typeof children !== "string") return children;
@@ -624,16 +653,23 @@ function dropdownPanelClass(align, panelClassName) {
624
653
  panelClassName
625
654
  );
626
655
  }
627
- function DropdownMenu({
628
- trigger,
629
- children,
630
- align = "start",
631
- className,
632
- panelClassName,
633
- "aria-label": ariaLabel,
634
- ...props
635
- }) {
636
- return /* @__PURE__ */ jsxs7("details", { className: cn("relative", className), ...props, children: [
656
+ function DropdownMenu(_a) {
657
+ var _b = _a, {
658
+ trigger,
659
+ children,
660
+ align = "start",
661
+ className,
662
+ panelClassName,
663
+ "aria-label": ariaLabel
664
+ } = _b, props = __objRest(_b, [
665
+ "trigger",
666
+ "children",
667
+ "align",
668
+ "className",
669
+ "panelClassName",
670
+ "aria-label"
671
+ ]);
672
+ return /* @__PURE__ */ jsxs7("details", __spreadProps(__spreadValues({ className: cn("relative", className) }, props), { children: [
637
673
  /* @__PURE__ */ jsx11(
638
674
  "summary",
639
675
  {
@@ -643,27 +679,40 @@ function DropdownMenu({
643
679
  }
644
680
  ),
645
681
  /* @__PURE__ */ jsx11("div", { className: dropdownPanelClass(align, panelClassName), children })
646
- ] });
647
- }
648
- function DropdownButton({
649
- label,
650
- variant = "secondary",
651
- outline = false,
652
- size = "md",
653
- split = false,
654
- icon,
655
- sideIcon,
656
- children,
657
- align = "start",
658
- className,
659
- panelClassName,
660
- "aria-label": ariaLabel,
661
- ...props
662
- }) {
682
+ ] }));
683
+ }
684
+ function DropdownButton(_a) {
685
+ var _b = _a, {
686
+ label,
687
+ variant = "secondary",
688
+ outline = false,
689
+ size = "md",
690
+ split = false,
691
+ icon,
692
+ sideIcon,
693
+ children,
694
+ align = "start",
695
+ className,
696
+ panelClassName,
697
+ "aria-label": ariaLabel
698
+ } = _b, props = __objRest(_b, [
699
+ "label",
700
+ "variant",
701
+ "outline",
702
+ "size",
703
+ "split",
704
+ "icon",
705
+ "sideIcon",
706
+ "children",
707
+ "align",
708
+ "className",
709
+ "panelClassName",
710
+ "aria-label"
711
+ ]);
663
712
  const usesLemonChrome = variant === "primary" || variant === "secondary";
664
713
  const chevron = /* @__PURE__ */ jsx11(IconChevronDown, { className: "h-4 w-4", "aria-hidden": true });
665
- const trailing = sideIcon ?? chevron;
666
- return /* @__PURE__ */ jsxs7("details", { className: cn("relative", className), ...props, children: [
714
+ const trailing = sideIcon != null ? sideIcon : chevron;
715
+ return /* @__PURE__ */ jsxs7("details", __spreadProps(__spreadValues({ className: cn("relative", className) }, props), { children: [
667
716
  /* @__PURE__ */ jsx11(
668
717
  "summary",
669
718
  {
@@ -674,7 +723,7 @@ function DropdownButton({
674
723
  sizeClass2[size],
675
724
  split && "ph-btn-split"
676
725
  ),
677
- "aria-label": ariaLabel ?? label,
726
+ "aria-label": ariaLabel != null ? ariaLabel : label,
678
727
  children: usesLemonChrome ? /* @__PURE__ */ jsx11(ButtonChrome, { label, icon, sideIcon: trailing, split }) : /* @__PURE__ */ jsxs7(Fragment4, { children: [
679
728
  icon != null ? /* @__PURE__ */ jsx11("span", { className: "ph-btn-icon", children: icon }) : null,
680
729
  /* @__PURE__ */ jsx11("span", { className: "ph-btn-label", children: label }),
@@ -683,14 +732,17 @@ function DropdownButton({
683
732
  }
684
733
  ),
685
734
  /* @__PURE__ */ jsx11("div", { className: dropdownPanelClass(align, panelClassName), children })
686
- ] });
735
+ ] }));
687
736
  }
688
- function DropdownItem({
689
- className,
690
- children,
691
- ...props
692
- }) {
693
- return /* @__PURE__ */ jsx11("button", { type: "button", className: cn("ph-dropdown-item w-full text-left", className), ...props, children });
737
+ function DropdownItem(_a) {
738
+ var _b = _a, {
739
+ className,
740
+ children
741
+ } = _b, props = __objRest(_b, [
742
+ "className",
743
+ "children"
744
+ ]);
745
+ return /* @__PURE__ */ jsx11("button", __spreadProps(__spreadValues({ type: "button", className: cn("ph-dropdown-item w-full text-left", className) }, props), { children }));
694
746
  }
695
747
 
696
748
  // src/components/ui/Input.tsx
@@ -701,21 +753,32 @@ var sizeMap3 = {
701
753
  md: "",
702
754
  lg: "ph-input-lg"
703
755
  };
704
- function Input({
705
- id: idProp,
706
- label,
707
- hideLabel = false,
708
- error,
709
- helperText,
710
- size = "md",
711
- variant = "default",
712
- className,
713
- wrapperClassName,
714
- disabled,
715
- ...props
716
- }) {
756
+ function Input(_a) {
757
+ var _b = _a, {
758
+ id: idProp,
759
+ label,
760
+ hideLabel = false,
761
+ error,
762
+ helperText,
763
+ size = "md",
764
+ variant = "default",
765
+ className,
766
+ wrapperClassName,
767
+ disabled
768
+ } = _b, props = __objRest(_b, [
769
+ "id",
770
+ "label",
771
+ "hideLabel",
772
+ "error",
773
+ "helperText",
774
+ "size",
775
+ "variant",
776
+ "className",
777
+ "wrapperClassName",
778
+ "disabled"
779
+ ]);
717
780
  const autoId = useId();
718
- const id = idProp ?? autoId;
781
+ const id = idProp != null ? idProp : autoId;
719
782
  const hasError = Boolean(error);
720
783
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-field", wrapperClassName), children: [
721
784
  label && /* @__PURE__ */ jsx12(
@@ -732,7 +795,7 @@ function Input({
732
795
  ),
733
796
  /* @__PURE__ */ jsx12(
734
797
  "input",
735
- {
798
+ __spreadValues({
736
799
  id,
737
800
  disabled,
738
801
  "aria-invalid": hasError || void 0,
@@ -743,29 +806,39 @@ function Input({
743
806
  hasError && "ph-input-error",
744
807
  disabled && "cursor-not-allowed opacity-60",
745
808
  className
746
- ),
747
- ...props
748
- }
809
+ )
810
+ }, props)
749
811
  ),
750
812
  helperText && !hasError && /* @__PURE__ */ jsx12("p", { className: "mt-1 text-xs text-ph-subtle", children: helperText }),
751
813
  error && /* @__PURE__ */ jsx12("p", { className: "mt-1 text-xs font-medium text-ph-danger", children: error })
752
814
  ] });
753
815
  }
754
- function Select({
755
- id: idProp,
756
- label,
757
- hideLabel = false,
758
- error,
759
- helperText,
760
- size = "md",
761
- className,
762
- wrapperClassName,
763
- disabled,
764
- children,
765
- ...props
766
- }) {
816
+ function Select(_a) {
817
+ var _b = _a, {
818
+ id: idProp,
819
+ label,
820
+ hideLabel = false,
821
+ error,
822
+ helperText,
823
+ size = "md",
824
+ className,
825
+ wrapperClassName,
826
+ disabled,
827
+ children
828
+ } = _b, props = __objRest(_b, [
829
+ "id",
830
+ "label",
831
+ "hideLabel",
832
+ "error",
833
+ "helperText",
834
+ "size",
835
+ "className",
836
+ "wrapperClassName",
837
+ "disabled",
838
+ "children"
839
+ ]);
767
840
  const autoId = useId();
768
- const id = idProp ?? autoId;
841
+ const id = idProp != null ? idProp : autoId;
769
842
  const hasError = Boolean(error);
770
843
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-field", wrapperClassName), children: [
771
844
  label && /* @__PURE__ */ jsx12(
@@ -778,7 +851,7 @@ function Select({
778
851
  ),
779
852
  /* @__PURE__ */ jsx12(
780
853
  "select",
781
- {
854
+ __spreadProps(__spreadValues({
782
855
  id,
783
856
  disabled,
784
857
  "aria-invalid": hasError || void 0,
@@ -788,29 +861,39 @@ function Select({
788
861
  hasError && "border-ph-danger focus:border-ph-danger focus:ring-ph-danger/20",
789
862
  disabled && "cursor-not-allowed opacity-60",
790
863
  className
791
- ),
792
- ...props,
864
+ )
865
+ }, props), {
793
866
  children
794
- }
867
+ })
795
868
  ),
796
869
  helperText && !hasError && /* @__PURE__ */ jsx12("p", { className: "mt-1 text-xs text-ph-subtle", children: helperText }),
797
870
  error && /* @__PURE__ */ jsx12("p", { className: "mt-1 text-xs font-medium text-ph-danger", children: error })
798
871
  ] });
799
872
  }
800
- function Textarea({
801
- id: idProp,
802
- label,
803
- hideLabel = false,
804
- error,
805
- helperText,
806
- size = "md",
807
- className,
808
- wrapperClassName,
809
- disabled,
810
- ...props
811
- }) {
873
+ function Textarea(_a) {
874
+ var _b = _a, {
875
+ id: idProp,
876
+ label,
877
+ hideLabel = false,
878
+ error,
879
+ helperText,
880
+ size = "md",
881
+ className,
882
+ wrapperClassName,
883
+ disabled
884
+ } = _b, props = __objRest(_b, [
885
+ "id",
886
+ "label",
887
+ "hideLabel",
888
+ "error",
889
+ "helperText",
890
+ "size",
891
+ "className",
892
+ "wrapperClassName",
893
+ "disabled"
894
+ ]);
812
895
  const autoId = useId();
813
- const id = idProp ?? autoId;
896
+ const id = idProp != null ? idProp : autoId;
814
897
  const hasError = Boolean(error);
815
898
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-field", wrapperClassName), children: [
816
899
  label && /* @__PURE__ */ jsx12(
@@ -823,7 +906,7 @@ function Textarea({
823
906
  ),
824
907
  /* @__PURE__ */ jsx12(
825
908
  "textarea",
826
- {
909
+ __spreadValues({
827
910
  id,
828
911
  disabled,
829
912
  "aria-invalid": hasError || void 0,
@@ -833,31 +916,38 @@ function Textarea({
833
916
  hasError && "border-ph-danger focus:border-ph-danger focus:ring-ph-danger/20",
834
917
  disabled && "cursor-not-allowed opacity-60",
835
918
  className
836
- ),
837
- ...props
838
- }
919
+ )
920
+ }, props)
839
921
  ),
840
922
  helperText && !hasError && /* @__PURE__ */ jsx12("p", { className: "mt-1 text-xs text-ph-subtle", children: helperText }),
841
923
  error && /* @__PURE__ */ jsx12("p", { className: "mt-1 text-xs font-medium text-ph-danger", children: error })
842
924
  ] });
843
925
  }
844
- function Checkbox({
845
- id: idProp,
846
- label,
847
- error,
848
- helperText,
849
- className,
850
- wrapperClassName,
851
- disabled,
852
- ...props
853
- }) {
926
+ function Checkbox(_a) {
927
+ var _b = _a, {
928
+ id: idProp,
929
+ label,
930
+ error,
931
+ helperText,
932
+ className,
933
+ wrapperClassName,
934
+ disabled
935
+ } = _b, props = __objRest(_b, [
936
+ "id",
937
+ "label",
938
+ "error",
939
+ "helperText",
940
+ "className",
941
+ "wrapperClassName",
942
+ "disabled"
943
+ ]);
854
944
  const autoId = useId();
855
- const id = idProp ?? autoId;
945
+ const id = idProp != null ? idProp : autoId;
856
946
  const hasError = Boolean(error);
857
947
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-control-row", wrapperClassName), children: [
858
948
  /* @__PURE__ */ jsx12(
859
949
  "input",
860
- {
950
+ __spreadValues({
861
951
  id,
862
952
  type: "checkbox",
863
953
  disabled,
@@ -867,76 +957,92 @@ function Checkbox({
867
957
  hasError && "border-ph-danger",
868
958
  disabled && "cursor-not-allowed opacity-60",
869
959
  className
870
- ),
871
- ...props
872
- }
960
+ )
961
+ }, props)
873
962
  ),
874
963
  /* @__PURE__ */ jsx12("label", { htmlFor: id, className: cn("cursor-pointer", disabled && "opacity-60"), children: label }),
875
964
  helperText && !hasError && /* @__PURE__ */ jsx12("p", { className: "mt-0.5 text-xs text-ph-subtle", children: helperText }),
876
965
  error && /* @__PURE__ */ jsx12("p", { className: "mt-0.5 text-xs font-medium text-ph-danger", children: error })
877
966
  ] });
878
967
  }
879
- function Radio({
880
- id: idProp,
881
- label,
882
- className,
883
- wrapperClassName,
884
- disabled,
885
- ...props
886
- }) {
968
+ function Radio(_a) {
969
+ var _b = _a, {
970
+ id: idProp,
971
+ label,
972
+ className,
973
+ wrapperClassName,
974
+ disabled
975
+ } = _b, props = __objRest(_b, [
976
+ "id",
977
+ "label",
978
+ "className",
979
+ "wrapperClassName",
980
+ "disabled"
981
+ ]);
887
982
  const autoId = useId();
888
- const id = idProp ?? autoId;
983
+ const id = idProp != null ? idProp : autoId;
889
984
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-control-row", wrapperClassName, disabled && "opacity-60"), children: [
890
985
  /* @__PURE__ */ jsx12(
891
986
  "input",
892
- {
987
+ __spreadValues({
893
988
  id,
894
989
  type: "radio",
895
990
  disabled,
896
- className: cn("ph-radio", disabled && "cursor-not-allowed", className),
897
- ...props
898
- }
991
+ className: cn("ph-radio", disabled && "cursor-not-allowed", className)
992
+ }, props)
899
993
  ),
900
994
  /* @__PURE__ */ jsx12("label", { htmlFor: id, className: cn("cursor-pointer", disabled && "opacity-60"), children: label })
901
995
  ] });
902
996
  }
903
- function Toggle({
904
- id: idProp,
905
- label,
906
- className,
907
- wrapperClassName,
908
- disabled,
909
- ...props
910
- }) {
997
+ function Toggle(_a) {
998
+ var _b = _a, {
999
+ id: idProp,
1000
+ label,
1001
+ className,
1002
+ wrapperClassName,
1003
+ disabled
1004
+ } = _b, props = __objRest(_b, [
1005
+ "id",
1006
+ "label",
1007
+ "className",
1008
+ "wrapperClassName",
1009
+ "disabled"
1010
+ ]);
911
1011
  const autoId = useId();
912
- const id = idProp ?? autoId;
1012
+ const id = idProp != null ? idProp : autoId;
913
1013
  return /* @__PURE__ */ jsxs8("label", { className: cn("ph-control-row-between", wrapperClassName, disabled && "opacity-60"), children: [
914
1014
  /* @__PURE__ */ jsx12("span", { className: disabled ? "opacity-60" : void 0, children: label }),
915
1015
  /* @__PURE__ */ jsx12(
916
1016
  "input",
917
- {
1017
+ __spreadValues({
918
1018
  id,
919
1019
  type: "checkbox",
920
1020
  role: "switch",
921
1021
  disabled,
922
- className: cn("ph-toggle", disabled && "cursor-not-allowed", className),
923
- ...props
924
- }
1022
+ className: cn("ph-toggle", disabled && "cursor-not-allowed", className)
1023
+ }, props)
925
1024
  )
926
1025
  ] });
927
1026
  }
928
- function Range({
929
- label,
930
- minLabel,
931
- maxLabel,
932
- valueLabel,
933
- wrapperClassName,
934
- className,
935
- ...props
936
- }) {
1027
+ function Range(_a) {
1028
+ var _b = _a, {
1029
+ label,
1030
+ minLabel,
1031
+ maxLabel,
1032
+ valueLabel,
1033
+ wrapperClassName,
1034
+ className
1035
+ } = _b, props = __objRest(_b, [
1036
+ "label",
1037
+ "minLabel",
1038
+ "maxLabel",
1039
+ "valueLabel",
1040
+ "wrapperClassName",
1041
+ "className"
1042
+ ]);
937
1043
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-field", wrapperClassName), children: [
938
1044
  label && /* @__PURE__ */ jsx12("label", { className: "ph-label", children: label }),
939
- /* @__PURE__ */ jsx12("input", { type: "range", className: cn("ph-range", className), ...props }),
1045
+ /* @__PURE__ */ jsx12("input", __spreadValues({ type: "range", className: cn("ph-range", className) }, props)),
940
1046
  (minLabel || valueLabel || maxLabel) && /* @__PURE__ */ jsxs8("div", { className: "flex justify-between text-xs text-ph-mutedtext", children: [
941
1047
  /* @__PURE__ */ jsx12("span", { children: minLabel }),
942
1048
  /* @__PURE__ */ jsx12("span", { children: valueLabel }),
@@ -944,11 +1050,12 @@ function Range({
944
1050
  ] })
945
1051
  ] });
946
1052
  }
947
- function FileUpload({ label, prompt = "Drop file or browse", wrapperClassName, className, ...props }) {
1053
+ function FileUpload(_a) {
1054
+ var _b = _a, { label, prompt = "Drop file or browse", wrapperClassName, className } = _b, props = __objRest(_b, ["label", "prompt", "wrapperClassName", "className"]);
948
1055
  return /* @__PURE__ */ jsxs8("div", { className: cn("ph-field", wrapperClassName), children: [
949
1056
  label && /* @__PURE__ */ jsx12("label", { className: "ph-label", children: label }),
950
1057
  /* @__PURE__ */ jsxs8("label", { className: "flex cursor-pointer items-center gap-3 rounded-lg border border-dashed border-ph-border bg-ph-surface px-4 py-6 text-sm text-ph-subtle transition hover:bg-ph-muted/60", children: [
951
- /* @__PURE__ */ jsx12("input", { type: "file", className: cn("sr-only", className), ...props }),
1058
+ /* @__PURE__ */ jsx12("input", __spreadValues({ type: "file", className: cn("sr-only", className) }, props)),
952
1059
  prompt
953
1060
  ] })
954
1061
  ] });
@@ -1069,36 +1176,45 @@ function Pagination({
1069
1176
 
1070
1177
  // src/components/ui/Panel.tsx
1071
1178
  import { jsx as jsx15, jsxs as jsxs11 } from "react/jsx-runtime";
1072
- function Panel({ title, description, children, className, ...props }) {
1073
- return /* @__PURE__ */ jsxs11("div", { className: cn("ph-panel", className), ...props, children: [
1179
+ function Panel(_a) {
1180
+ var _b = _a, { title, description, children, className } = _b, props = __objRest(_b, ["title", "description", "children", "className"]);
1181
+ return /* @__PURE__ */ jsxs11("div", __spreadProps(__spreadValues({ className: cn("ph-panel", className) }, props), { children: [
1074
1182
  title && /* @__PURE__ */ jsx15("h3", { className: "text-sm font-semibold uppercase tracking-wider text-ph-mutedtext", children: title }),
1075
1183
  description && /* @__PURE__ */ jsx15("p", { className: "text-sm text-ph-subtle", children: description }),
1076
1184
  children
1077
- ] });
1185
+ ] }));
1078
1186
  }
1079
1187
 
1080
1188
  // src/components/ui/Rating.tsx
1081
1189
  import { jsx as jsx16, jsxs as jsxs12 } from "react/jsx-runtime";
1082
- function Rating({
1083
- label,
1084
- value = 0,
1085
- max = 5,
1086
- readOnly = true,
1087
- onChange,
1088
- className,
1089
- wrapperClassName,
1090
- ...props
1091
- }) {
1190
+ function Rating(_a) {
1191
+ var _b = _a, {
1192
+ label,
1193
+ value = 0,
1194
+ max = 5,
1195
+ readOnly = true,
1196
+ onChange,
1197
+ className,
1198
+ wrapperClassName
1199
+ } = _b, props = __objRest(_b, [
1200
+ "label",
1201
+ "value",
1202
+ "max",
1203
+ "readOnly",
1204
+ "onChange",
1205
+ "className",
1206
+ "wrapperClassName"
1207
+ ]);
1092
1208
  const stars = Array.from({ length: max }, (_, index) => index + 1);
1093
1209
  return /* @__PURE__ */ jsxs12("div", { className: cn("ph-field", wrapperClassName), children: [
1094
1210
  label && /* @__PURE__ */ jsx16("span", { className: "ph-label", children: label }),
1095
1211
  /* @__PURE__ */ jsx16(
1096
1212
  "div",
1097
- {
1213
+ __spreadProps(__spreadValues({
1098
1214
  className: cn("ph-rating flex", className),
1099
1215
  role: readOnly ? "img" : "radiogroup",
1100
- "aria-label": label ?? `Rating: ${value} out of ${max}`,
1101
- ...props,
1216
+ "aria-label": label != null ? label : `Rating: ${value} out of ${max}`
1217
+ }, props), {
1102
1218
  children: stars.map((star) => {
1103
1219
  const active = star <= value;
1104
1220
  if (readOnly) {
@@ -1125,7 +1241,7 @@ function Rating({
1125
1241
  star
1126
1242
  );
1127
1243
  })
1128
- }
1244
+ })
1129
1245
  )
1130
1246
  ] });
1131
1247
  }
@@ -1133,19 +1249,28 @@ function Rating({
1133
1249
  // src/components/ui/SearchInput.tsx
1134
1250
  import { useId as useId2 } from "react";
1135
1251
  import { jsx as jsx17, jsxs as jsxs13 } from "react/jsx-runtime";
1136
- function SearchInput({
1137
- id: idProp,
1138
- label = "Search",
1139
- hideLabel = false,
1140
- shortcut,
1141
- density = "default",
1142
- className,
1143
- wrapperClassName,
1144
- placeholder,
1145
- ...props
1146
- }) {
1252
+ function SearchInput(_a) {
1253
+ var _b = _a, {
1254
+ id: idProp,
1255
+ label = "Search",
1256
+ hideLabel = false,
1257
+ shortcut,
1258
+ density = "default",
1259
+ className,
1260
+ wrapperClassName,
1261
+ placeholder
1262
+ } = _b, props = __objRest(_b, [
1263
+ "id",
1264
+ "label",
1265
+ "hideLabel",
1266
+ "shortcut",
1267
+ "density",
1268
+ "className",
1269
+ "wrapperClassName",
1270
+ "placeholder"
1271
+ ]);
1147
1272
  const autoId = useId2();
1148
- const id = idProp ?? autoId;
1273
+ const id = idProp != null ? idProp : autoId;
1149
1274
  return /* @__PURE__ */ jsxs13("div", { className: cn("relative", wrapperClassName), children: [
1150
1275
  /* @__PURE__ */ jsx17("label", { htmlFor: id, className: hideLabel ? "sr-only" : "ph-label mb-1.5 block", children: label }),
1151
1276
  /* @__PURE__ */ jsxs13("div", { className: "relative", children: [
@@ -1159,7 +1284,7 @@ function SearchInput({
1159
1284
  ) : null,
1160
1285
  /* @__PURE__ */ jsx17(
1161
1286
  "input",
1162
- {
1287
+ __spreadValues({
1163
1288
  id,
1164
1289
  type: "search",
1165
1290
  placeholder,
@@ -1169,36 +1294,41 @@ function SearchInput({
1169
1294
  density === "compact" && "max-w-xs !min-h-[2rem] py-1.5 text-sm",
1170
1295
  shortcut != null && "pl-[3.25rem]",
1171
1296
  className
1172
- ),
1173
- ...props
1174
- }
1297
+ )
1298
+ }, props)
1175
1299
  )
1176
1300
  ] })
1177
1301
  ] });
1178
1302
  }
1179
- function SearchGroup({
1180
- id: idProp,
1181
- label = "Search records",
1182
- submitLabel = "Search",
1183
- placeholder = "Persons, actions, flags\u2026",
1184
- wrapperClassName,
1185
- className,
1186
- ...props
1187
- }) {
1303
+ function SearchGroup(_a) {
1304
+ var _b = _a, {
1305
+ id: idProp,
1306
+ label = "Search records",
1307
+ submitLabel = "Search",
1308
+ placeholder = "Persons, actions, flags\u2026",
1309
+ wrapperClassName,
1310
+ className
1311
+ } = _b, props = __objRest(_b, [
1312
+ "id",
1313
+ "label",
1314
+ "submitLabel",
1315
+ "placeholder",
1316
+ "wrapperClassName",
1317
+ "className"
1318
+ ]);
1188
1319
  const autoId = useId2();
1189
- const id = idProp ?? autoId;
1320
+ const id = idProp != null ? idProp : autoId;
1190
1321
  return /* @__PURE__ */ jsxs13("div", { className: cn("ph-field", wrapperClassName), children: [
1191
1322
  /* @__PURE__ */ jsx17("label", { htmlFor: id, className: "ph-label", children: label }),
1192
1323
  /* @__PURE__ */ jsxs13("div", { className: "ph-search-group flex w-full max-w-lg min-h-[2.3125rem] items-stretch divide-x divide-ph-border", children: [
1193
1324
  /* @__PURE__ */ jsx17(
1194
1325
  "input",
1195
- {
1326
+ __spreadValues({
1196
1327
  id,
1197
1328
  type: "search",
1198
1329
  placeholder,
1199
- className: cn("ph-input ph-input-group-field min-w-0 flex-1", className),
1200
- ...props
1201
- }
1330
+ className: cn("ph-input ph-input-group-field min-w-0 flex-1", className)
1331
+ }, props)
1202
1332
  ),
1203
1333
  /* @__PURE__ */ jsx17(
1204
1334
  Button,
@@ -1249,13 +1379,14 @@ var statMap = {
1249
1379
  purple: "",
1250
1380
  warning: "border-amber-200 bg-amber-50/70"
1251
1381
  };
1252
- function Stat({ icon, label, value, footer, tone = "default", className, ...props }) {
1253
- return /* @__PURE__ */ jsxs15("article", { className: cn("ph-stat", statMap[tone], className), ...props, children: [
1382
+ function Stat(_a) {
1383
+ var _b = _a, { icon, label, value, footer, tone = "default", className } = _b, props = __objRest(_b, ["icon", "label", "value", "footer", "tone", "className"]);
1384
+ return /* @__PURE__ */ jsxs15("article", __spreadProps(__spreadValues({ className: cn("ph-stat", statMap[tone], className) }, props), { children: [
1254
1385
  icon && /* @__PURE__ */ jsx19("div", { className: cn("mb-2 h-7 w-7", toneMap[tone]), children: icon }),
1255
1386
  /* @__PURE__ */ jsx19("div", { className: cn("ph-stat-label", tone === "warning" && toneMap[tone]), children: label }),
1256
1387
  /* @__PURE__ */ jsx19("div", { className: cn("ph-stat-val", toneMap[tone]), children: value }),
1257
1388
  footer && /* @__PURE__ */ jsx19("p", { className: "text-xs text-ph-subtle", children: footer })
1258
- ] });
1389
+ ] }));
1259
1390
  }
1260
1391
 
1261
1392
  // src/components/ui/Toast.tsx
@@ -2050,12 +2181,15 @@ function ComponentDocs({ title = "Props & variants", rows, defaultOpen = false,
2050
2181
  /* @__PURE__ */ jsx33("th", { className: "px-4 py-2 font-semibold", children: "Default" }),
2051
2182
  /* @__PURE__ */ jsx33("th", { className: "px-4 py-2 font-semibold", children: "Use" })
2052
2183
  ] }) }),
2053
- /* @__PURE__ */ jsx33("tbody", { className: "divide-y divide-ph-border", children: rows.map((row) => /* @__PURE__ */ jsxs27("tr", { children: [
2054
- /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-ink", children: row.name }),
2055
- /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-subtle", children: row.type }),
2056
- /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-subtle", children: row.defaultValue ?? "-" }),
2057
- /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top text-ph-subtle", children: row.description })
2058
- ] }, row.name)) })
2184
+ /* @__PURE__ */ jsx33("tbody", { className: "divide-y divide-ph-border", children: rows.map((row) => {
2185
+ var _a;
2186
+ return /* @__PURE__ */ jsxs27("tr", { children: [
2187
+ /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-ink", children: row.name }),
2188
+ /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-subtle", children: row.type }),
2189
+ /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-subtle", children: (_a = row.defaultValue) != null ? _a : "-" }),
2190
+ /* @__PURE__ */ jsx33("td", { className: "px-4 py-3 align-top text-ph-subtle", children: row.description })
2191
+ ] }, row.name);
2192
+ }) })
2059
2193
  ] }) })
2060
2194
  ] });
2061
2195
  }
@@ -2073,9 +2207,10 @@ function ShowcaseWrapper({
2073
2207
  children,
2074
2208
  className
2075
2209
  }) {
2210
+ var _a;
2076
2211
  const [showCode, setShowCode] = useState7(false);
2077
- const fallbackId = titleIdMap[title] ?? title.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "");
2078
- return /* @__PURE__ */ jsxs28("section", { id: id ?? fallbackId, className: cn("scroll-mt-20", className), children: [
2212
+ const fallbackId = (_a = titleIdMap[title]) != null ? _a : title.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "");
2213
+ return /* @__PURE__ */ jsxs28("section", { id: id != null ? id : fallbackId, className: cn("scroll-mt-20", className), children: [
2079
2214
  /* @__PURE__ */ jsxs28("div", { className: "ph-h2-rule mb-8", children: [
2080
2215
  /* @__PURE__ */ jsxs28("div", { className: "flex items-center gap-1.5", children: [
2081
2216
  /* @__PURE__ */ jsx34("h2", { children: title }),
@@ -2309,17 +2444,25 @@ var statusMap = {
2309
2444
  away: "bg-amber-400",
2310
2445
  busy: "bg-ph-danger"
2311
2446
  };
2312
- function Avatar({
2313
- label,
2314
- icon,
2315
- size = "md",
2316
- color = "bg-ph-brand text-white",
2317
- status,
2318
- badge,
2319
- className,
2320
- ...props
2321
- }) {
2322
- return /* @__PURE__ */ jsxs30("div", { className: cn("relative inline-flex shrink-0", className), ...props, children: [
2447
+ function Avatar(_a) {
2448
+ var _b = _a, {
2449
+ label,
2450
+ icon,
2451
+ size = "md",
2452
+ color = "bg-ph-brand text-white",
2453
+ status,
2454
+ badge,
2455
+ className
2456
+ } = _b, props = __objRest(_b, [
2457
+ "label",
2458
+ "icon",
2459
+ "size",
2460
+ "color",
2461
+ "status",
2462
+ "badge",
2463
+ "className"
2464
+ ]);
2465
+ return /* @__PURE__ */ jsxs30("div", __spreadProps(__spreadValues({ className: cn("relative inline-flex shrink-0", className) }, props), { children: [
2323
2466
  /* @__PURE__ */ jsx37(
2324
2467
  "div",
2325
2468
  {
@@ -2341,13 +2484,14 @@ function Avatar({
2341
2484
  }
2342
2485
  ),
2343
2486
  badge && /* @__PURE__ */ jsx37("span", { className: "absolute -bottom-1 -right-1 flex min-w-[22px] items-center justify-center rounded-full bg-ph-brand px-1.5 py-px text-[10px] font-bold text-white", children: badge })
2344
- ] });
2487
+ ] }));
2345
2488
  }
2346
- function AvatarGroup({ children, max, className, ...props }) {
2489
+ function AvatarGroup(_a) {
2490
+ var _b = _a, { children, max, className } = _b, props = __objRest(_b, ["children", "max", "className"]);
2347
2491
  const items = Array.isArray(children) ? children : [children];
2348
2492
  const visible = max ? items.slice(0, max) : items;
2349
2493
  const remaining = max ? items.length - max : 0;
2350
- return /* @__PURE__ */ jsxs30("div", { className: cn("-space-x-3 flex rtl:space-x-reverse", className), ...props, children: [
2494
+ return /* @__PURE__ */ jsxs30("div", __spreadProps(__spreadValues({ className: cn("-space-x-3 flex rtl:space-x-reverse", className) }, props), { children: [
2351
2495
  visible,
2352
2496
  remaining > 0 && /* @__PURE__ */ jsx37(
2353
2497
  Avatar,
@@ -2357,7 +2501,7 @@ function AvatarGroup({ children, max, className, ...props }) {
2357
2501
  color: "bg-ph-toolbar text-ph-subtle"
2358
2502
  }
2359
2503
  )
2360
- ] });
2504
+ ] }));
2361
2505
  }
2362
2506
 
2363
2507
  // src/components/ui/Progress.tsx
@@ -2367,18 +2511,26 @@ var sizeMap6 = {
2367
2511
  md: "h-2",
2368
2512
  lg: "h-3"
2369
2513
  };
2370
- function Progress({
2371
- value,
2372
- max = 100,
2373
- color = "bg-ph-brand",
2374
- label,
2375
- showPercentage = false,
2376
- size = "md",
2377
- className,
2378
- ...props
2379
- }) {
2514
+ function Progress(_a) {
2515
+ var _b = _a, {
2516
+ value,
2517
+ max = 100,
2518
+ color = "bg-ph-brand",
2519
+ label,
2520
+ showPercentage = false,
2521
+ size = "md",
2522
+ className
2523
+ } = _b, props = __objRest(_b, [
2524
+ "value",
2525
+ "max",
2526
+ "color",
2527
+ "label",
2528
+ "showPercentage",
2529
+ "size",
2530
+ "className"
2531
+ ]);
2380
2532
  const percentage = Math.min(100, Math.max(0, value / max * 100));
2381
- return /* @__PURE__ */ jsxs31("div", { className: cn("w-full", className), ...props, children: [
2533
+ return /* @__PURE__ */ jsxs31("div", __spreadProps(__spreadValues({ className: cn("w-full", className) }, props), { children: [
2382
2534
  (label || showPercentage) && /* @__PURE__ */ jsxs31("div", { className: "mb-1.5 flex justify-between text-sm text-ph-subtle", children: [
2383
2535
  label && /* @__PURE__ */ jsx38("span", { children: label }),
2384
2536
  showPercentage && /* @__PURE__ */ jsxs31("span", { className: "tabular-nums", children: [
@@ -2397,31 +2549,39 @@ function Progress({
2397
2549
  "aria-valuemax": max
2398
2550
  }
2399
2551
  ) })
2400
- ] });
2552
+ ] }));
2401
2553
  }
2402
2554
 
2403
2555
  // src/components/ui/ChatBubble.tsx
2404
2556
  import { jsx as jsx39, jsxs as jsxs32 } from "react/jsx-runtime";
2405
- function ChatBubble({
2406
- children,
2407
- avatar,
2408
- name,
2409
- time,
2410
- variant = "from",
2411
- footer,
2412
- className,
2413
- ...props
2414
- }) {
2557
+ function ChatBubble(_a) {
2558
+ var _b = _a, {
2559
+ children,
2560
+ avatar,
2561
+ name,
2562
+ time,
2563
+ variant = "from",
2564
+ footer,
2565
+ className
2566
+ } = _b, props = __objRest(_b, [
2567
+ "children",
2568
+ "avatar",
2569
+ "name",
2570
+ "time",
2571
+ "variant",
2572
+ "footer",
2573
+ "className"
2574
+ ]);
2415
2575
  const isSelf = variant === "self";
2416
2576
  return /* @__PURE__ */ jsxs32(
2417
2577
  "div",
2418
- {
2578
+ __spreadProps(__spreadValues({
2419
2579
  className: cn(
2420
2580
  "flex gap-3",
2421
2581
  isSelf && "flex-row-reverse",
2422
2582
  className
2423
- ),
2424
- ...props,
2583
+ )
2584
+ }, props), {
2425
2585
  children: [
2426
2586
  avatar && /* @__PURE__ */ jsx39("div", { className: "shrink-0", children: avatar }),
2427
2587
  /* @__PURE__ */ jsxs32("div", { className: cn("min-w-0 flex-1", isSelf && "text-right"), children: [
@@ -2451,27 +2611,32 @@ function ChatBubble({
2451
2611
  footer && /* @__PURE__ */ jsx39("footer", { className: "mt-2 text-[11px] text-ph-mutedtext", children: footer })
2452
2612
  ] })
2453
2613
  ]
2454
- }
2614
+ })
2455
2615
  );
2456
2616
  }
2457
2617
 
2458
2618
  // src/components/ui/Terminal.tsx
2459
2619
  import { Fragment as Fragment6, jsx as jsx40, jsxs as jsxs33 } from "react/jsx-runtime";
2460
- function Terminal({
2461
- title = "sandbox",
2462
- lines,
2463
- children,
2464
- className,
2465
- ...props
2466
- }) {
2620
+ function Terminal(_a) {
2621
+ var _b = _a, {
2622
+ title = "sandbox",
2623
+ lines,
2624
+ children,
2625
+ className
2626
+ } = _b, props = __objRest(_b, [
2627
+ "title",
2628
+ "lines",
2629
+ "children",
2630
+ "className"
2631
+ ]);
2467
2632
  return /* @__PURE__ */ jsxs33(
2468
2633
  "div",
2469
- {
2634
+ __spreadProps(__spreadValues({
2470
2635
  className: cn(
2471
2636
  "overflow-hidden rounded-xl border border-ph-border shadow-ph-md",
2472
2637
  className
2473
- ),
2474
- ...props,
2638
+ )
2639
+ }, props), {
2475
2640
  children: [
2476
2641
  /* @__PURE__ */ jsxs33("header", { className: "flex items-center gap-2 border-b border-ph-border bg-ph-muted px-4 py-3", children: [
2477
2642
  /* @__PURE__ */ jsx40("div", { className: "h-3 w-3 rounded-full bg-red-400" }),
@@ -2488,7 +2653,7 @@ function Terminal({
2488
2653
  ] }, i);
2489
2654
  }) }) })
2490
2655
  ]
2491
- }
2656
+ })
2492
2657
  );
2493
2658
  }
2494
2659
 
@@ -2500,16 +2665,23 @@ var positionMap = {
2500
2665
  "bottom-right": "-right-[2px] -bottom-[2px]",
2501
2666
  "bottom-left": "-left-[2px] -bottom-[2px]"
2502
2667
  };
2503
- function Indicator({
2504
- children,
2505
- badge,
2506
- color = "bg-ph-brand",
2507
- position = "top-right",
2508
- dot = false,
2509
- className,
2510
- ...props
2511
- }) {
2512
- return /* @__PURE__ */ jsxs34("div", { className: cn("relative inline-flex items-center justify-center", className), ...props, children: [
2668
+ function Indicator(_a) {
2669
+ var _b = _a, {
2670
+ children,
2671
+ badge,
2672
+ color = "bg-ph-brand",
2673
+ position = "top-right",
2674
+ dot = false,
2675
+ className
2676
+ } = _b, props = __objRest(_b, [
2677
+ "children",
2678
+ "badge",
2679
+ "color",
2680
+ "position",
2681
+ "dot",
2682
+ "className"
2683
+ ]);
2684
+ return /* @__PURE__ */ jsxs34("div", __spreadProps(__spreadValues({ className: cn("relative inline-flex items-center justify-center", className) }, props), { children: [
2513
2685
  dot ? /* @__PURE__ */ jsx41(
2514
2686
  "span",
2515
2687
  {
@@ -2531,22 +2703,26 @@ function Indicator({
2531
2703
  }
2532
2704
  ) : null,
2533
2705
  children
2534
- ] });
2706
+ ] }));
2535
2707
  }
2536
2708
 
2537
2709
  // src/components/ui/Timeline.tsx
2538
2710
  import { jsx as jsx42, jsxs as jsxs35 } from "react/jsx-runtime";
2539
- function Timeline({
2540
- events,
2541
- alternate = false,
2542
- className,
2543
- ...props
2544
- }) {
2711
+ function Timeline(_a) {
2712
+ var _b = _a, {
2713
+ events,
2714
+ alternate = false,
2715
+ className
2716
+ } = _b, props = __objRest(_b, [
2717
+ "events",
2718
+ "alternate",
2719
+ "className"
2720
+ ]);
2545
2721
  return /* @__PURE__ */ jsx42(
2546
2722
  "ol",
2547
- {
2548
- className: cn("relative space-y-8", className),
2549
- ...props,
2723
+ __spreadProps(__spreadValues({
2724
+ className: cn("relative space-y-8", className)
2725
+ }, props), {
2550
2726
  children: events.map((event, idx) => {
2551
2727
  const align = alternate && idx % 2 !== 0 ? "lg:flex-row-reverse" : "";
2552
2728
  return /* @__PURE__ */ jsxs35("li", { className: cn("relative flex gap-6", align), children: [
@@ -2569,12 +2745,26 @@ function Timeline({
2569
2745
  ] })
2570
2746
  ] }, event.id);
2571
2747
  })
2572
- }
2748
+ })
2573
2749
  );
2574
2750
  }
2575
2751
 
2576
2752
  // src/components/charts/ph-insight-charts.tsx
2577
2753
  import { useEffect as useEffect5, useMemo as useMemo2, useState as useState11 } from "react";
2754
+ import {
2755
+ ArcElement,
2756
+ BarController,
2757
+ BarElement,
2758
+ CategoryScale,
2759
+ Chart as ChartJS,
2760
+ DoughnutController,
2761
+ Legend,
2762
+ LinearScale,
2763
+ PolarAreaController,
2764
+ RadialLinearScale,
2765
+ Title,
2766
+ Tooltip
2767
+ } from "chart.js";
2578
2768
  import { Bar, Doughnut, PolarArea } from "react-chartjs-2";
2579
2769
 
2580
2770
  // src/lib/chart/with-alpha.ts
@@ -2910,7 +3100,7 @@ function buildPolarAreaDemo(tokens) {
2910
3100
  }
2911
3101
 
2912
3102
  // src/lib/chart/use-ph-chart-tokens.ts
2913
- import { useEffect as useEffect3, useState as useState9 } from "react";
3103
+ import { useEffect as useEffect3, useRef as useRef2, useState as useState9 } from "react";
2914
3104
 
2915
3105
  // src/lib/chart/ph-chart-tokens.ts
2916
3106
  var FALLBACK_CHART_TOKENS = {
@@ -2929,7 +3119,7 @@ function readChartTokens(root) {
2929
3119
  if (typeof document === "undefined") {
2930
3120
  return FALLBACK_CHART_TOKENS;
2931
3121
  }
2932
- const el = root ?? document.documentElement;
3122
+ const el = root != null ? root : document.documentElement;
2933
3123
  const series = [1, 2, 3, 4, 5, 6, 7].map((index) => {
2934
3124
  const raw = readCssVar(el, `--ph-data-${index}`);
2935
3125
  return raw !== "" ? raw : FALLBACK_CHART_TOKENS.series[index - 1];
@@ -2944,12 +3134,24 @@ function readChartTokens(root) {
2944
3134
  }
2945
3135
 
2946
3136
  // src/lib/chart/use-ph-chart-tokens.ts
3137
+ function tokensEqual(a, b) {
3138
+ if (a.series.length !== b.series.length) return false;
3139
+ for (let i = 0; i < a.series.length; i++) {
3140
+ if (a.series[i] !== b.series[i]) return false;
3141
+ }
3142
+ return a.grid === b.grid && a.text === b.text && a.textMuted === b.textMuted && a.surface === b.surface && a.borderStrong === b.borderStrong && a.accent === b.accent;
3143
+ }
2947
3144
  function useChartTokens() {
2948
3145
  const [tokens, setTokens] = useState9(FALLBACK_CHART_TOKENS);
3146
+ const tokensRef = useRef2(FALLBACK_CHART_TOKENS);
2949
3147
  useEffect3(() => {
2950
3148
  const root = document.documentElement;
2951
3149
  const refresh = () => {
2952
- setTokens(readChartTokens(root));
3150
+ const next = readChartTokens(root);
3151
+ if (!tokensEqual(tokensRef.current, next)) {
3152
+ tokensRef.current = next;
3153
+ setTokens(next);
3154
+ }
2953
3155
  };
2954
3156
  refresh();
2955
3157
  const observer = new MutationObserver(refresh);
@@ -2972,7 +3174,7 @@ function buildHogChartTheme(tokens) {
2972
3174
 
2973
3175
  // src/lib/hog-charts-lite/CanvasTrendLineChart.tsx
2974
3176
  import { scaleLinear, scalePoint } from "d3-scale";
2975
- import { useCallback, useEffect as useEffect4, useMemo, useRef as useRef2, useState as useState10 } from "react";
3177
+ import { useCallback, useEffect as useEffect4, useMemo, useRef as useRef3, useState as useState10 } from "react";
2976
3178
  import { jsx as jsx43, jsxs as jsxs36 } from "react/jsx-runtime";
2977
3179
  var HOG_LITE_DEFAULT_MARGINS = { top: 16, right: 16, bottom: 32, left: 48 };
2978
3180
  function resolveDisplayedSeries(series, palette) {
@@ -2983,7 +3185,7 @@ function resolveDisplayedSeries(series, palette) {
2983
3185
  return visible.map((s, visibleIndex) => {
2984
3186
  const hasExplicit = s.color != null && String(s.color).trim() !== "";
2985
3187
  const resolvedColor = hasExplicit ? String(s.color).trim() : palette[visibleIndex % palette.length];
2986
- return { ...s, resolvedColor };
3188
+ return __spreadProps(__spreadValues({}, s), { resolvedColor });
2987
3189
  });
2988
3190
  }
2989
3191
  function yDomainForSeries(resolved) {
@@ -3027,8 +3229,8 @@ function CanvasTrendLineChart({
3027
3229
  showCrosshair = true,
3028
3230
  className = ""
3029
3231
  }) {
3030
- const containerRef = useRef2(null);
3031
- const canvasRef = useRef2(null);
3232
+ const containerRef = useRef3(null);
3233
+ const canvasRef = useRef3(null);
3032
3234
  const [size, setSize] = useState10({ width: 0, height: 0 });
3033
3235
  const [hoverIndex, setHoverIndex] = useState10(null);
3034
3236
  useEffect4(() => {
@@ -3046,7 +3248,7 @@ function CanvasTrendLineChart({
3046
3248
  }, []);
3047
3249
  const resolved = useMemo(() => resolveDisplayedSeries(series, theme.colors), [series, theme.colors]);
3048
3250
  const draw = useCallback(() => {
3049
- var _a, _b, _c;
3251
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i;
3050
3252
  const canvas = canvasRef.current;
3051
3253
  const container = containerRef.current;
3052
3254
  if (!canvas || !container) {
@@ -3074,15 +3276,15 @@ function CanvasTrendLineChart({
3074
3276
  if (plotWidth <= 4 || plotHeight <= 4) {
3075
3277
  return;
3076
3278
  }
3077
- const bg = theme.backgroundColor ?? "#ffffff";
3279
+ const bg = (_a = theme.backgroundColor) != null ? _a : "#ffffff";
3078
3280
  ctx.fillStyle = bg;
3079
3281
  ctx.fillRect(0, 0, cssW, cssH);
3080
3282
  const labelList = [...labels];
3081
3283
  const xScale = scalePoint().domain(labelList).range([plotLeft, plotLeft + plotWidth]).padding(0.5);
3082
3284
  const [y0, y1] = yDomainForSeries(resolved);
3083
3285
  const yScale = scaleLinear().domain([y0, y1]).nice().range([plotTop + plotHeight, plotTop]);
3084
- const axisColor = theme.axisColor ?? "#666";
3085
- const gridColor = theme.gridColor ?? "rgba(0,0,0,0.08)";
3286
+ const axisColor = (_b = theme.axisColor) != null ? _b : "#666";
3287
+ const gridColor = (_c = theme.gridColor) != null ? _c : "rgba(0,0,0,0.08)";
3086
3288
  if (showGrid) {
3087
3289
  const ticks = yScale.ticks(6);
3088
3290
  ctx.strokeStyle = gridColor;
@@ -3104,7 +3306,7 @@ function CanvasTrendLineChart({
3104
3306
  if (s.overlay || !s.fill) {
3105
3307
  continue;
3106
3308
  }
3107
- const opacity = s.fill.opacity ?? 0.45;
3309
+ const opacity = (_d = s.fill.opacity) != null ? _d : 0.45;
3108
3310
  const baseline = yScale(0);
3109
3311
  ctx.save();
3110
3312
  ctx.globalAlpha = opacity;
@@ -3138,10 +3340,10 @@ function CanvasTrendLineChart({
3138
3340
  ctx.restore();
3139
3341
  }
3140
3342
  for (const s of resolved) {
3141
- if ((_a = s.visibility) == null ? void 0 : _a.excluded) {
3343
+ if ((_e = s.visibility) == null ? void 0 : _e.excluded) {
3142
3344
  continue;
3143
3345
  }
3144
- const pattern = ((_b = s.stroke) == null ? void 0 : _b.pattern) ?? [];
3346
+ const pattern = (_g = (_f = s.stroke) == null ? void 0 : _f.pattern) != null ? _g : [];
3145
3347
  ctx.strokeStyle = s.resolvedColor;
3146
3348
  ctx.lineWidth = 2;
3147
3349
  ctx.lineJoin = "round";
@@ -3195,7 +3397,7 @@ function CanvasTrendLineChart({
3195
3397
  if (hi != null && hi >= 0 && hi < labels.length && showCrosshair) {
3196
3398
  const cx = xAt(hi);
3197
3399
  if (cx != null) {
3198
- const cross = theme.crosshairColor ?? gridColor;
3400
+ const cross = (_h = theme.crosshairColor) != null ? _h : gridColor;
3199
3401
  ctx.strokeStyle = cross;
3200
3402
  ctx.lineWidth = 1;
3201
3403
  ctx.setLineDash([4, 4]);
@@ -3205,7 +3407,7 @@ function CanvasTrendLineChart({
3205
3407
  ctx.stroke();
3206
3408
  ctx.setLineDash([]);
3207
3409
  for (const s of resolved) {
3208
- if (s.overlay || ((_c = s.visibility) == null ? void 0 : _c.excluded)) {
3410
+ if (s.overlay || ((_i = s.visibility) == null ? void 0 : _i.excluded)) {
3209
3411
  continue;
3210
3412
  }
3211
3413
  const v = s.data[hi];
@@ -3305,9 +3507,31 @@ function CanvasTrendLineChart({
3305
3507
  // src/components/charts/ph-insight-charts.tsx
3306
3508
  import { jsx as jsx44 } from "react/jsx-runtime";
3307
3509
  var DEMO_LABELS = ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"];
3510
+ var chartJsRegistered = false;
3511
+ function registerChartJs() {
3512
+ if (chartJsRegistered) return;
3513
+ if (typeof window === "undefined") return;
3514
+ ChartJS.register(
3515
+ CategoryScale,
3516
+ LinearScale,
3517
+ RadialLinearScale,
3518
+ BarController,
3519
+ BarElement,
3520
+ DoughnutController,
3521
+ PolarAreaController,
3522
+ ArcElement,
3523
+ Title,
3524
+ Tooltip,
3525
+ Legend
3526
+ );
3527
+ chartJsRegistered = true;
3528
+ }
3308
3529
  function useClientMounted() {
3309
3530
  const [mounted, setMounted] = useState11(false);
3310
- useEffect5(() => setMounted(true), []);
3531
+ useEffect5(() => {
3532
+ setMounted(true);
3533
+ registerChartJs();
3534
+ }, []);
3311
3535
  return mounted;
3312
3536
  }
3313
3537
  function ChartSkeleton({ className = "h-[280px]" }) {
@@ -3364,7 +3588,7 @@ function InsightVerticalBarChart() {
3364
3588
  if (!mounted) {
3365
3589
  return /* @__PURE__ */ jsx44(ChartSkeleton, {});
3366
3590
  }
3367
- return /* @__PURE__ */ jsx44("div", { className: "relative h-[280px] w-full min-h-[220px]", children: /* @__PURE__ */ jsx44(Bar, { data: config.data, options: config.options }) });
3591
+ return /* @__PURE__ */ jsx44("div", { className: "relative h-[280px] w-full min-h-[220px]", children: /* @__PURE__ */ jsx44(Bar, { data: config.data, options: config.options, redraw: false }) });
3368
3592
  }
3369
3593
  function InsightHorizontalBarChart() {
3370
3594
  const mounted = useClientMounted();
@@ -3373,7 +3597,7 @@ function InsightHorizontalBarChart() {
3373
3597
  if (!mounted) {
3374
3598
  return /* @__PURE__ */ jsx44(ChartSkeleton, { className: "h-[320px]" });
3375
3599
  }
3376
- return /* @__PURE__ */ jsx44("div", { className: "relative h-[320px] w-full min-h-[260px]", children: /* @__PURE__ */ jsx44(Bar, { data: config.data, options: config.options }) });
3600
+ return /* @__PURE__ */ jsx44("div", { className: "relative h-[320px] w-full min-h-[260px]", children: /* @__PURE__ */ jsx44(Bar, { data: config.data, options: config.options, redraw: false }) });
3377
3601
  }
3378
3602
  function InsightStackedBarChart() {
3379
3603
  const mounted = useClientMounted();
@@ -3382,7 +3606,7 @@ function InsightStackedBarChart() {
3382
3606
  if (!mounted) {
3383
3607
  return /* @__PURE__ */ jsx44(ChartSkeleton, { className: "h-[300px]" });
3384
3608
  }
3385
- return /* @__PURE__ */ jsx44("div", { className: "relative h-[300px] w-full min-h-[240px]", children: /* @__PURE__ */ jsx44(Bar, { data: config.data, options: config.options }) });
3609
+ return /* @__PURE__ */ jsx44("div", { className: "relative h-[300px] w-full min-h-[240px]", children: /* @__PURE__ */ jsx44(Bar, { data: config.data, options: config.options, redraw: false }) });
3386
3610
  }
3387
3611
  function InsightDoughnutChart() {
3388
3612
  const mounted = useClientMounted();
@@ -3391,7 +3615,7 @@ function InsightDoughnutChart() {
3391
3615
  if (!mounted) {
3392
3616
  return /* @__PURE__ */ jsx44(ChartSkeleton, { className: "h-[260px]" });
3393
3617
  }
3394
- return /* @__PURE__ */ jsx44("div", { className: "relative mx-auto h-[260px] w-full max-w-[280px] min-h-[220px]", children: /* @__PURE__ */ jsx44(Doughnut, { data: config.data, options: config.options }) });
3618
+ return /* @__PURE__ */ jsx44("div", { className: "relative mx-auto h-[260px] w-full max-w-[280px] min-h-[220px]", children: /* @__PURE__ */ jsx44(Doughnut, { data: config.data, options: config.options, redraw: false }) });
3395
3619
  }
3396
3620
  function InsightPolarAreaChart() {
3397
3621
  const mounted = useClientMounted();
@@ -3400,13 +3624,14 @@ function InsightPolarAreaChart() {
3400
3624
  if (!mounted) {
3401
3625
  return /* @__PURE__ */ jsx44(ChartSkeleton, { className: "h-[280px]" });
3402
3626
  }
3403
- return /* @__PURE__ */ jsx44("div", { className: "relative mx-auto h-[280px] w-full max-w-[320px] min-h-[240px]", children: /* @__PURE__ */ jsx44(PolarArea, { data: config.data, options: config.options }) });
3627
+ return /* @__PURE__ */ jsx44("div", { className: "relative mx-auto h-[280px] w-full max-w-[320px] min-h-[240px]", children: /* @__PURE__ */ jsx44(PolarArea, { data: config.data, options: config.options, redraw: false }) });
3404
3628
  }
3405
3629
 
3406
3630
  // src/components/dashboard/DashboardWell.tsx
3407
3631
  import { jsx as jsx45 } from "react/jsx-runtime";
3408
- function DashboardWell({ className, ...props }) {
3409
- return /* @__PURE__ */ jsx45("div", { className: cn("ph-dashboard-well", className), ...props });
3632
+ function DashboardWell(_a) {
3633
+ var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3634
+ return /* @__PURE__ */ jsx45("div", __spreadValues({ className: cn("ph-dashboard-well", className) }, props));
3410
3635
  }
3411
3636
 
3412
3637
  // src/components/dashboard/DashboardToolbar.tsx
@@ -3427,78 +3652,92 @@ var presetClass = {
3427
3652
  insights: "grid gap-4 md:grid-cols-2 xl:grid-cols-3",
3428
3653
  dense: "grid gap-3 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4"
3429
3654
  };
3430
- function DashboardGrid({
3431
- preset = "insights",
3432
- className,
3433
- ...props
3434
- }) {
3435
- return /* @__PURE__ */ jsx47("div", { className: cn(presetClass[preset], className), ...props });
3655
+ function DashboardGrid(_a) {
3656
+ var _b = _a, {
3657
+ preset = "insights",
3658
+ className
3659
+ } = _b, props = __objRest(_b, [
3660
+ "preset",
3661
+ "className"
3662
+ ]);
3663
+ return /* @__PURE__ */ jsx47("div", __spreadValues({ className: cn(presetClass[preset], className) }, props));
3436
3664
  }
3437
3665
 
3438
3666
  // src/components/dashboard/DashboardFiltersBar.tsx
3439
3667
  import { jsx as jsx48 } from "react/jsx-runtime";
3440
- function DashboardFiltersBar({ className, ...props }) {
3668
+ function DashboardFiltersBar(_a) {
3669
+ var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3441
3670
  return /* @__PURE__ */ jsx48(
3442
3671
  "div",
3443
- {
3672
+ __spreadValues({
3444
3673
  className: cn(
3445
3674
  "flex flex-wrap items-center gap-2 rounded-[var(--ph-radius-app)] border border-solid bg-ph-surface px-3 py-2 text-sm text-ph-subtle [border-color:var(--ph-border-control)]",
3446
3675
  "[box-shadow:var(--ph-chrome-inset-face-top),var(--ph-chrome-inset-face-bottom),var(--ph-shadow-elevation-3000)]",
3447
3676
  className
3448
- ),
3449
- ...props
3450
- }
3677
+ )
3678
+ }, props)
3451
3679
  );
3452
3680
  }
3453
3681
 
3454
3682
  // src/components/dashboard/DashboardKpiCard.tsx
3455
3683
  import { jsx as jsx49, jsxs as jsxs38 } from "react/jsx-runtime";
3456
- function DashboardKpiCard({ label, value, footer, icon, className, children, ...props }) {
3457
- return /* @__PURE__ */ jsxs38("article", { className: cn("ph-stat", className), ...props, children: [
3684
+ function DashboardKpiCard(_a) {
3685
+ var _b = _a, { label, value, footer, icon, className, children } = _b, props = __objRest(_b, ["label", "value", "footer", "icon", "className", "children"]);
3686
+ return /* @__PURE__ */ jsxs38("article", __spreadProps(__spreadValues({ className: cn("ph-stat", className) }, props), { children: [
3458
3687
  icon != null ? /* @__PURE__ */ jsx49("div", { className: "mb-2 [&>svg]:h-7 [&>svg]:w-7", children: icon }) : null,
3459
3688
  /* @__PURE__ */ jsx49("div", { className: "ph-stat-label", children: label }),
3460
3689
  /* @__PURE__ */ jsx49("div", { className: "ph-stat-val", children: value }),
3461
3690
  footer != null ? /* @__PURE__ */ jsx49("p", { className: "mt-1 text-xs text-ph-subtle", children: footer }) : null,
3462
3691
  children
3463
- ] });
3692
+ ] }));
3464
3693
  }
3465
3694
 
3466
3695
  // src/components/dashboard/DashboardInsightPlaceholder.tsx
3467
3696
  import { jsx as jsx50 } from "react/jsx-runtime";
3468
- function DashboardInsightPlaceholder({
3469
- label = "Add insight",
3470
- className,
3471
- children,
3472
- type = "button",
3473
- ...props
3474
- }) {
3697
+ function DashboardInsightPlaceholder(_a) {
3698
+ var _b = _a, {
3699
+ label = "Add insight",
3700
+ className,
3701
+ children,
3702
+ type = "button"
3703
+ } = _b, props = __objRest(_b, [
3704
+ "label",
3705
+ "className",
3706
+ "children",
3707
+ "type"
3708
+ ]);
3475
3709
  return /* @__PURE__ */ jsx50(
3476
3710
  "button",
3477
- {
3711
+ __spreadProps(__spreadValues({
3478
3712
  type,
3479
3713
  "aria-label": label,
3480
3714
  className: cn(
3481
3715
  "ph-dashboard-placeholder group text-left outline-none transition",
3482
3716
  "focus-visible:ring-2 focus-visible:ring-ph-brand focus-visible:ring-offset-2",
3483
3717
  className
3484
- ),
3485
- ...props,
3718
+ )
3719
+ }, props), {
3486
3720
  children: children != null ? children : /* @__PURE__ */ jsx50("span", { className: "font-medium text-ph-subtle group-hover:text-ph-ink", children: label })
3487
- }
3721
+ })
3488
3722
  );
3489
3723
  }
3490
3724
 
3491
3725
  // src/components/dashboard/InsightShell.tsx
3492
3726
  import { jsx as jsx51, jsxs as jsxs39 } from "react/jsx-runtime";
3493
- function InsightShell({
3494
- ribbonColour,
3495
- bodyClassName,
3496
- className,
3497
- children,
3498
- ...props
3499
- }) {
3727
+ function InsightShell(_a) {
3728
+ var _b = _a, {
3729
+ ribbonColour,
3730
+ bodyClassName,
3731
+ className,
3732
+ children
3733
+ } = _b, props = __objRest(_b, [
3734
+ "ribbonColour",
3735
+ "bodyClassName",
3736
+ "className",
3737
+ "children"
3738
+ ]);
3500
3739
  const ribbon = ribbonColour != null && String(ribbonColour).trim() !== "" ? String(ribbonColour).trim() : null;
3501
- return /* @__PURE__ */ jsxs39("article", { className: cn("ph-insight-shell flex-row", className), ...props, children: [
3740
+ return /* @__PURE__ */ jsxs39("article", __spreadProps(__spreadValues({ className: cn("ph-insight-shell flex-row", className) }, props), { children: [
3502
3741
  ribbon != null ? /* @__PURE__ */ jsx51(
3503
3742
  "div",
3504
3743
  {
@@ -3508,7 +3747,7 @@ function InsightShell({
3508
3747
  }
3509
3748
  ) : null,
3510
3749
  /* @__PURE__ */ jsx51("div", { className: cn("flex min-w-0 flex-1 flex-col gap-3 p-4", bodyClassName), children })
3511
- ] });
3750
+ ] }));
3512
3751
  }
3513
3752
 
3514
3753
  // src/components/dashboard/InsightShellHeader.tsx
@@ -3538,7 +3777,10 @@ function MiniTrendBars({
3538
3777
  seriesResolver,
3539
3778
  className
3540
3779
  }) {
3541
- const resolveSeries = seriesResolver ?? ((i) => DEFAULT_SERIES_CYCLE[i % DEFAULT_SERIES_CYCLE.length] ?? 1);
3780
+ const resolveSeries = seriesResolver != null ? seriesResolver : ((i) => {
3781
+ var _a;
3782
+ return (_a = DEFAULT_SERIES_CYCLE[i % DEFAULT_SERIES_CYCLE.length]) != null ? _a : 1;
3783
+ });
3542
3784
  return /* @__PURE__ */ jsx53("div", { className: cn("flex items-end gap-0.5", rowClassName, className), children: heights.map((raw, i) => {
3543
3785
  const pct = clampPct(raw);
3544
3786
  const series = resolveSeries(i, pct);
@@ -3553,17 +3795,22 @@ function MiniTrendBars({
3553
3795
 
3554
3796
  // src/components/dashboard/InsightMiniCard.tsx
3555
3797
  import { jsx as jsx54, jsxs as jsxs41 } from "react/jsx-runtime";
3556
- function InsightMiniCard({
3557
- title,
3558
- subtitle,
3559
- heights,
3560
- ribbonColour,
3561
- ...shellProps
3562
- }) {
3563
- return /* @__PURE__ */ jsxs41(InsightShell, { ribbonColour, ...shellProps, children: [
3798
+ function InsightMiniCard(_a) {
3799
+ var _b = _a, {
3800
+ title,
3801
+ subtitle,
3802
+ heights,
3803
+ ribbonColour
3804
+ } = _b, shellProps = __objRest(_b, [
3805
+ "title",
3806
+ "subtitle",
3807
+ "heights",
3808
+ "ribbonColour"
3809
+ ]);
3810
+ return /* @__PURE__ */ jsxs41(InsightShell, __spreadProps(__spreadValues({ ribbonColour }, shellProps), { children: [
3564
3811
  /* @__PURE__ */ jsx54(InsightShellHeader, { title, subtitle }),
3565
3812
  /* @__PURE__ */ jsx54(MiniTrendBars, { heights })
3566
- ] });
3813
+ ] }));
3567
3814
  }
3568
3815
  export {
3569
3816
  Accordion,