@bubo-squared/ui-framework 0.2.23 → 0.2.25

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.d.cts CHANGED
@@ -11,7 +11,7 @@ import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
11
11
  import { ClassValue } from 'clsx';
12
12
 
13
13
  declare const buttonVariants: (props?: ({
14
- variant?: "primary" | "secondary" | "ghost" | "outline" | "destructive" | null | undefined;
14
+ variant?: "primary" | "secondary" | "ghost" | "outline" | "destructive" | "destructive-outline" | null | undefined;
15
15
  size?: "sm" | "md" | "lg" | "xl" | null | undefined;
16
16
  } & class_variance_authority_types.ClassProp) | undefined) => string;
17
17
  interface ButtonProps$1 extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
@@ -135,7 +135,7 @@ declare const badgeVariants: (props?: ({
135
135
  } & class_variance_authority_types.ClassProp) | undefined) => string;
136
136
  type BadgeVariant = "primary" | "secondary" | "informal" | "success" | "warning" | "error" | "disabled" | "active";
137
137
  type BadgeSize = "sm" | "md" | "lg" | "xl";
138
- interface BadgeProps extends VariantProps<typeof badgeVariants> {
138
+ interface BadgeProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
139
139
  asChild?: boolean;
140
140
  label: React$1.ReactNode;
141
141
  value?: React$1.ReactNode;
@@ -162,7 +162,7 @@ declare const BadgeDigit: React$1.ForwardRefExoticComponent<BadgeDigitProps & Re
162
162
  declare const badgeDotVariants: (props?: ({
163
163
  status?: "error" | "disabled" | "informal" | "warning" | "success/online" | null | undefined;
164
164
  } & class_variance_authority_types.ClassProp) | undefined) => string;
165
- interface BadgeDotProps extends VariantProps<typeof badgeDotVariants> {
165
+ interface BadgeDotProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeDotVariants> {
166
166
  className?: string;
167
167
  }
168
168
  declare const BadgeDot: React$1.FC<BadgeDotProps>;
@@ -540,10 +540,13 @@ type SliderBaseProps = {
540
540
  tooltipPlacement?: SliderTooltipPlacement;
541
541
  /**
542
542
  * Custom formatter for tooltip / numeric / accessibility text.
543
- * Receives the current slider value and should return a display string.
543
+ * Receives the current slider value and should return display content.
544
544
  * If provided, it takes precedence over `showPercentage`.
545
+ *
546
+ * Accessibility note: when the formatter returns non-text content,
547
+ * `aria-valuetext` falls back to the default numeric/percentage string.
545
548
  */
546
- tooltipFormatter?: (value: number) => string;
549
+ tooltipFormatter?: (value: number) => React$1.ReactNode;
547
550
  /**
548
551
  * When true (default), values are rendered as percentages (e.g. "30%").
549
552
  * When false, raw numbers are shown instead.
package/dist/index.d.ts CHANGED
@@ -11,7 +11,7 @@ import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
11
11
  import { ClassValue } from 'clsx';
12
12
 
13
13
  declare const buttonVariants: (props?: ({
14
- variant?: "primary" | "secondary" | "ghost" | "outline" | "destructive" | null | undefined;
14
+ variant?: "primary" | "secondary" | "ghost" | "outline" | "destructive" | "destructive-outline" | null | undefined;
15
15
  size?: "sm" | "md" | "lg" | "xl" | null | undefined;
16
16
  } & class_variance_authority_types.ClassProp) | undefined) => string;
17
17
  interface ButtonProps$1 extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
@@ -135,7 +135,7 @@ declare const badgeVariants: (props?: ({
135
135
  } & class_variance_authority_types.ClassProp) | undefined) => string;
136
136
  type BadgeVariant = "primary" | "secondary" | "informal" | "success" | "warning" | "error" | "disabled" | "active";
137
137
  type BadgeSize = "sm" | "md" | "lg" | "xl";
138
- interface BadgeProps extends VariantProps<typeof badgeVariants> {
138
+ interface BadgeProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
139
139
  asChild?: boolean;
140
140
  label: React$1.ReactNode;
141
141
  value?: React$1.ReactNode;
@@ -162,7 +162,7 @@ declare const BadgeDigit: React$1.ForwardRefExoticComponent<BadgeDigitProps & Re
162
162
  declare const badgeDotVariants: (props?: ({
163
163
  status?: "error" | "disabled" | "informal" | "warning" | "success/online" | null | undefined;
164
164
  } & class_variance_authority_types.ClassProp) | undefined) => string;
165
- interface BadgeDotProps extends VariantProps<typeof badgeDotVariants> {
165
+ interface BadgeDotProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeDotVariants> {
166
166
  className?: string;
167
167
  }
168
168
  declare const BadgeDot: React$1.FC<BadgeDotProps>;
@@ -540,10 +540,13 @@ type SliderBaseProps = {
540
540
  tooltipPlacement?: SliderTooltipPlacement;
541
541
  /**
542
542
  * Custom formatter for tooltip / numeric / accessibility text.
543
- * Receives the current slider value and should return a display string.
543
+ * Receives the current slider value and should return display content.
544
544
  * If provided, it takes precedence over `showPercentage`.
545
+ *
546
+ * Accessibility note: when the formatter returns non-text content,
547
+ * `aria-valuetext` falls back to the default numeric/percentage string.
545
548
  */
546
- tooltipFormatter?: (value: number) => string;
549
+ tooltipFormatter?: (value: number) => React$1.ReactNode;
547
550
  /**
548
551
  * When true (default), values are rendered as percentages (e.g. "30%").
549
552
  * When false, raw numbers are shown instead.
package/dist/index.js CHANGED
@@ -66,6 +66,10 @@ var buttonVariants = cva(
66
66
  destructive: [
67
67
  "btn-destructive",
68
68
  "focus-ring-error"
69
+ ],
70
+ "destructive-outline": [
71
+ "btn-destructive-outline",
72
+ "focus-ring-error-outline"
69
73
  ]
70
74
  },
71
75
  size: {
@@ -292,7 +296,7 @@ var IconButtonGroup = (props) => {
292
296
  "aria-label": item.ariaLabel,
293
297
  disabled: item.disabled,
294
298
  className: cn(
295
- "rounded-none border-1 border-(--border-secondary) text-primary ",
299
+ "rounded-none border-1 border-secondary text-primary ",
296
300
  index === 0 && "rounded-l-6",
297
301
  index === items.length - 1 && "rounded-r-6",
298
302
  index > 0 && "-ml-px"
@@ -469,7 +473,7 @@ var Accordion = React6.forwardRef(
469
473
  AccordionPrimitive.Item,
470
474
  {
471
475
  value: "item",
472
- className: cn(bordered ? "border rounded-4" : "border-b", "border-(--border-secondary) px-4"),
476
+ className: cn(bordered ? "border rounded-4" : "border-b", "border-secondary px-4"),
473
477
  children: [
474
478
  /* @__PURE__ */ jsx8(AccordionPrimitive.Header, { className: "flex", children: /* @__PURE__ */ jsxs4(
475
479
  AccordionPrimitive.Trigger,
@@ -503,7 +507,7 @@ import { cva as cva6 } from "class-variance-authority";
503
507
  import { UserIcon } from "@bubo-squared/icons";
504
508
  import { jsx as jsx9, jsxs as jsxs5 } from "react/jsx-runtime";
505
509
  var avatarVariants = cva6(
506
- "relative inline-flex items-center justify-center rounded-full border-(--border-secondary) border-1 bg-(--background-primary) text-primary overflow-hidden hover:border-(--focus-secondary) focus-visible:border-(--focus-primary) focus-visible:outline-none",
510
+ "relative inline-flex items-center justify-center rounded-full border-secondary border-1 bg-(--background-primary) text-primary overflow-hidden hover:border-(--focus-secondary) focus-visible:border-(--focus-primary) focus-visible:outline-none",
507
511
  {
508
512
  variants: {
509
513
  size: {
@@ -652,24 +656,24 @@ import { Slot as Slot5 } from "@radix-ui/react-slot";
652
656
  import { cva as cva7 } from "class-variance-authority";
653
657
  import { Fragment, jsx as jsx11, jsxs as jsxs6 } from "react/jsx-runtime";
654
658
  var badgeVariants = cva7(
655
- "inline-flex items-center justify-center rounded-4 leading-none whitespace-nowrap gap-1 px-1 py-0",
659
+ "inline-flex items-center justify-center rounded-4 leading-none whitespace-nowrap gap-1 py-0",
656
660
  {
657
661
  variants: {
658
662
  size: {
659
- sm: "px-1 paragraph-sm",
660
- md: "px-1 paragraph-md",
661
- lg: "px-1.5 subtitle",
662
- xl: "px-2 h6-title"
663
+ sm: "px-1.5 paragraph-sm",
664
+ md: "px-2 paragraph-md",
665
+ lg: "px-2 subtitle",
666
+ xl: "px-2.5 h6-title"
663
667
  },
664
668
  variant: {
665
669
  primary: "bg-(--background-secondary) text-primary",
666
- secondary: "bg-(--background-primary) border-1 border-(--border-primary) text-primary",
670
+ secondary: "bg-(--background-primary) border-1 border-primary text-primary",
667
671
  active: "bg-ac-lilac text-badge-black",
668
672
  informal: "bg-ac-neon-blue text-badge-black",
669
673
  success: "bg-ac-neon-green text-badge-black",
670
674
  warning: "bg-ac-light-orange text-badge-black",
671
675
  error: "bg-s-error-300 text-badge-black",
672
- disabled: "bg-(--background-primary-disabled) border-1 border-(--border-primary-disabled) text-primary-disabled",
676
+ disabled: "bg-(--background-primary-disabled) border-1 border-primary-disabled text-primary-disabled",
673
677
  "double-default": "bg-(--background-secondary) text-primary",
674
678
  "double-current": "bg-color-ac-lilac text-badge-black"
675
679
  }
@@ -724,12 +728,12 @@ var badgeDigitVariants = cva8(
724
728
  },
725
729
  variant: {
726
730
  primary: "bg-(--background-brand)",
727
- secondary: "bg-(--background-primary) border-1 border-(--border-secondary) text-(--color-secondary)",
731
+ secondary: "bg-(--background-primary) border-1 border-secondary text-primary",
728
732
  informal: "bg-(--background-informal)",
729
733
  success: "bg-(--background-success)",
730
734
  warning: "bg-(--background-warning)",
731
735
  error: "bg-(--background-error)",
732
- disabled: "bg-(--background-primary) border-1 border-(--border-primary-disabled) text-primary-disabled"
736
+ disabled: "bg-(--background-primary) border-1 border-primary-disabled text-primary-disabled"
733
737
  }
734
738
  },
735
739
  defaultVariants: {
@@ -1204,7 +1208,7 @@ import { Slot as Slot6 } from "@radix-ui/react-slot";
1204
1208
  import { cva as cva11 } from "class-variance-authority";
1205
1209
  import { jsx as jsx19, jsxs as jsxs11 } from "react/jsx-runtime";
1206
1210
  var tagVariants = cva11(
1207
- "inline-flex flex-row items-center justify-center rounded-6 gap-2 px-3 overflow-hidden border-1 border-(--border-secondary) bg-(--background-neutral) focus:border-(--border-brand) focus-ring-primary ",
1211
+ "inline-flex flex-row items-center justify-center rounded-6 gap-2 px-3 overflow-hidden border-1 border-secondary bg-(--background-neutral) focus:border-brand focus-ring-primary ",
1208
1212
  {
1209
1213
  variants: {
1210
1214
  size: {
@@ -1217,7 +1221,7 @@ var tagVariants = cva11(
1217
1221
  }
1218
1222
  }
1219
1223
  );
1220
- var disabledTag = "pointer-events-none border-(--border-secondary-disabled) bg-(--background-neutral-disabled) text-primary-disabled";
1224
+ var disabledTag = "pointer-events-none border-secondary-disabled bg-(--background-neutral-disabled) text-primary-disabled";
1221
1225
  var iconClasses = "flex items-center justify-center w-5 h-5 [&>*]:w-5 [&>*]:h-5 shrink-0 text-primary";
1222
1226
  var Tag = React17.forwardRef(
1223
1227
  (props, ref) => {
@@ -1264,7 +1268,7 @@ import { ChevronRightIcon } from "@bubo-squared/icons";
1264
1268
 
1265
1269
  // src/components/ui/dropdown-styles.ts
1266
1270
  import { cva as cva12 } from "class-variance-authority";
1267
- var dropdownSurfaceClass = "z-50 rounded-4 border border-(--border-secondary-hover) bg-(--background-neutral) shadow-card-md";
1271
+ var dropdownSurfaceClass = "z-50 rounded-4 border border-secondary-hover bg-(--background-neutral) shadow-card-md";
1268
1272
  var dropdownScrollClass = "max-h-79 overflow-y-auto dropdown-scrollbar";
1269
1273
  var dropdownRowVariants = cva12(
1270
1274
  "flex w-full items-center gap-2 pl-(--space-8) pr-(--space-16) text-left text-primary cursor-pointer hover:bg-(--background-secondary)",
@@ -1525,15 +1529,15 @@ var Checkbox = React20.forwardRef(({ label, className, ...props }, forwardedRef)
1525
1529
  {
1526
1530
  ref: forwardedRef,
1527
1531
  className: cn(
1528
- "group flex h-5 w-5 items-center justify-center rounded-2 border border-(--border-secondary) bg-(--background-neutral) text-primary-inverse",
1532
+ "group flex h-5 w-5 items-center justify-center rounded-2 border border-secondary bg-(--background-neutral) text-primary-inverse",
1529
1533
  "data-[state=checked]:bg-(--background-brand) data-[state=checked]:text-button-white data-[state=checked]:border-none",
1530
1534
  "data-[state=indeterminate]:bg-(--background-brand) data-[state=indeterminate]:text-button-white data-[state=indeterminate]:border-none",
1531
1535
  "data-[state=checked]:hover:bg-(--background-brand-hover) data-[state=indeterminate]:hover:bg-(--background-brand-hover)",
1532
- "focus-visible:border-(--border-brand)",
1536
+ "focus-visible:border-brand",
1533
1537
  "disabled:bg-(--background-primary-disabled) disabled:border-none disabled:text-(--icon-primary-disabled)",
1534
1538
  "data-[state=checked]:disabled:bg-(--background-primary-disabled) data-[state=checked]:disabled:border-none data-[state=checked]:disabled:text-(--icon-primary-disabled)",
1535
1539
  "data-[state=indeterminate]:disabled:bg-(--background-primary-disabled) data-[state=indeterminate]:disabled:border-none data-[state=indeterminate]:disabled:text-(--icon-primary-disabled)",
1536
- "focus-ring-primary hover:cursor-pointer hover:border-(--border-secondary-hover)",
1540
+ "focus-ring-primary hover:cursor-pointer hover:border-secondary-hover",
1537
1541
  className
1538
1542
  ),
1539
1543
  ...props,
@@ -1557,7 +1561,7 @@ import * as React21 from "react";
1557
1561
  import { cva as cva13 } from "class-variance-authority";
1558
1562
  import { jsx as jsx23 } from "react/jsx-runtime";
1559
1563
  var inputShellVariants = cva13(
1560
- "group flex w-full items-center rounded-4 border bg-(--background-primary) text-left cursor-text border-(--border-secondary)",
1564
+ "group flex w-full items-center rounded-4 border bg-(--background-primary) text-left cursor-text border-secondary",
1561
1565
  {
1562
1566
  variants: {
1563
1567
  size: {
@@ -1572,7 +1576,7 @@ var inputShellVariants = cva13(
1572
1576
  error: "input-error"
1573
1577
  },
1574
1578
  disabled: {
1575
- true: "bg-(--background-primary-disabled) border-(--border-secondary-disabled) text-primary-disabled cursor-default"
1579
+ true: "bg-(--background-primary-disabled) border-secondary-disabled text-primary-disabled cursor-default"
1576
1580
  }
1577
1581
  },
1578
1582
  defaultVariants: {
@@ -1956,7 +1960,7 @@ import { cva as cva15 } from "class-variance-authority";
1956
1960
  import { ChevronDownIcon as ChevronDownIcon2 } from "@bubo-squared/icons";
1957
1961
  import { jsx as jsx26, jsxs as jsxs16 } from "react/jsx-runtime";
1958
1962
  var selectTriggerVariants = cva15(
1959
- "group flex w-full items-center justify-between rounded-4 border bg-(--background-primary) p-2 text-left transition-colors cursor-pointer hover:bg-(--background-primary-hover) disabled:bg-(--background-primary-disabled) disabled:text-primary-disabled disabled:cursor-default",
1963
+ "group flex w-full items-center justify-between rounded-4 border bg-(--background-primary) p-2 text-left transition-[background-color] cursor-pointer hover:bg-(--background-primary-hover) disabled:bg-(--background-primary-disabled) disabled:text-primary-disabled disabled:cursor-default",
1960
1964
  {
1961
1965
  variants: {
1962
1966
  size: {
@@ -2731,7 +2735,7 @@ function ScrollBar({
2731
2735
  // src/components/Inputs/PhoneInput.tsx
2732
2736
  import { cva as cva18 } from "class-variance-authority";
2733
2737
  import { jsx as jsx33, jsxs as jsxs21 } from "react/jsx-runtime";
2734
- var inputBase = "h-full rounded-4 border-(--border-secondary) bg-(--background-primary) hover:border-(--border-secondary-hover)";
2738
+ var inputBase = "h-full rounded-4 border-secondary bg-(--background-primary) hover:border-secondary-hover";
2735
2739
  var sizeBase = cva18(
2736
2740
  "flex w-full",
2737
2741
  {
@@ -2754,7 +2758,7 @@ var inputTextVariants2 = cva18("", {
2754
2758
  xl: "h6-title"
2755
2759
  },
2756
2760
  disabled: {
2757
- true: "text-primary-disabled border-(--border-secondary-disabled)"
2761
+ true: "text-primary-disabled border-secondary-disabled"
2758
2762
  }
2759
2763
  },
2760
2764
  defaultVariants: {
@@ -2796,7 +2800,7 @@ var countryOptionVariants = cva18(
2796
2800
  }
2797
2801
  );
2798
2802
  var PhoneInput = React31.forwardRef(
2799
- (props, ref) => {
2803
+ (props, forwardedRef) => {
2800
2804
  const {
2801
2805
  className,
2802
2806
  onChange,
@@ -2810,6 +2814,11 @@ var PhoneInput = React31.forwardRef(
2810
2814
  status = "default",
2811
2815
  ...rest
2812
2816
  } = props;
2817
+ const wrapperRef = React31.useRef(null);
2818
+ const focusNumberInput = React31.useCallback(() => {
2819
+ const el = wrapperRef.current?.querySelector("input");
2820
+ el?.focus();
2821
+ }, []);
2813
2822
  return /* @__PURE__ */ jsx33(
2814
2823
  Field,
2815
2824
  {
@@ -2819,16 +2828,29 @@ var PhoneInput = React31.forwardRef(
2819
2828
  status,
2820
2829
  disabled,
2821
2830
  className,
2822
- children: /* @__PURE__ */ jsx33("div", { className: cn("w-full", wrapperStatusClass[status]), children: /* @__PURE__ */ jsx33(
2831
+ children: /* @__PURE__ */ jsx33("div", { ref: wrapperRef, className: cn("w-full", wrapperStatusClass[status]), children: /* @__PURE__ */ jsx33(
2823
2832
  RPNInput.default,
2824
2833
  {
2825
- ref,
2834
+ ref: forwardedRef,
2826
2835
  className: cn(
2827
2836
  sizeBase({ size }),
2828
2837
  inputTextVariants2({ size, disabled })
2829
2838
  ),
2830
2839
  flagComponent: FlagComponent,
2831
- countrySelectComponent: (countrySelectProps) => /* @__PURE__ */ jsx33(CountrySelect, { ...countrySelectProps, size }),
2840
+ countrySelectComponent: (countrySelectProps) => /* @__PURE__ */ jsx33(
2841
+ CountrySelect,
2842
+ {
2843
+ ...countrySelectProps,
2844
+ size,
2845
+ onAfterSelect: () => {
2846
+ requestAnimationFrame(() => {
2847
+ requestAnimationFrame(() => {
2848
+ focusNumberInput();
2849
+ });
2850
+ });
2851
+ }
2852
+ }
2853
+ ),
2832
2854
  inputComponent: InputComponent,
2833
2855
  smartCaret: false,
2834
2856
  value: value || void 0,
@@ -2863,7 +2885,8 @@ var CountrySelect = ({
2863
2885
  value: selectedCountry,
2864
2886
  options: countryList,
2865
2887
  onChange,
2866
- size = "md"
2888
+ size = "md",
2889
+ onAfterSelect
2867
2890
  }) => {
2868
2891
  const scrollAreaRef = React31.useRef(null);
2869
2892
  const [searchValue, setSearchValue] = React31.useState("");
@@ -2947,7 +2970,10 @@ var CountrySelect = ({
2947
2970
  countryName: label,
2948
2971
  selectedCountry,
2949
2972
  onChange,
2950
- onSelectComplete: () => setIsOpen(false),
2973
+ onSelectComplete: () => {
2974
+ setIsOpen(false);
2975
+ onAfterSelect?.();
2976
+ },
2951
2977
  size
2952
2978
  },
2953
2979
  value
@@ -3061,24 +3087,24 @@ var RadioGroup = React32.forwardRef((props, forwardedRef) => {
3061
3087
  className: cn(
3062
3088
  "flex items-center justify-center shrink-0 h-5 w-5 rounded-full border bg-(--background-primary) transition-all",
3063
3089
  // 1: enabled, unchecked, unfocused, unhovered
3064
- "group-data-[state=unchecked]:border-(--border-secondary)",
3090
+ "group-data-[state=unchecked]:border-secondary",
3065
3091
  // 2: enabled, checked, unfocused, unhovered
3066
- "group-data-[state=checked]:border-(--border-brand)",
3092
+ "group-data-[state=checked]:border-brand",
3067
3093
  // 3: enabled, unchecked, hovered, unfocused
3068
- "group-data-[state=unchecked]:group-hover:border-(--border-secondary-hover)",
3094
+ "group-data-[state=unchecked]:group-hover:border-secondary-hover",
3069
3095
  // 4: enabled, checked, hovered, unfocused
3070
- "group-data-[state=checked]:group-hover:border-(--border-brand-hover)",
3096
+ "group-data-[state=checked]:group-hover:border-brand-hover",
3071
3097
  "group-data-[state=checked]:group-hover:shadow-[0_0_0_var(--focus-ring-spread)_var(--focus-secondary)]",
3072
3098
  // 5: enabled, unchecked, focused (override 1/3)
3073
- "group-data-[state=unchecked]:group-focus-visible:border-(--border-secondary-hover)",
3099
+ "group-data-[state=unchecked]:group-focus-visible:border-secondary-hover",
3074
3100
  // 6: enabled, checked, focused (override 2/4)
3075
- "group-data-[state=checked]:group-focus-visible:border-(--border-brand-focus)",
3101
+ "group-data-[state=checked]:group-focus-visible:border-brand-focus",
3076
3102
  "group-data-[state=checked]:group-focus-visible:shadow-[0_0_0_var(--focus-ring-spread)_var(--focus-primary)]",
3077
3103
  // 7: disabled, unchecked (override everything above)
3078
3104
  "group-[&[data-disabled][data-state=unchecked]]:border-none",
3079
3105
  "group-[&[data-disabled][data-state=unchecked]]:bg-(--background-primary-disabled)",
3080
3106
  // 8: disabled, checked (override everything above)
3081
- "group-[&[data-disabled][data-state=checked]]:border-(--border-primary-disabled)",
3107
+ "group-[&[data-disabled][data-state=checked]]:border-primary-disabled",
3082
3108
  "group-[&[data-disabled][data-state=checked]]:bg-(--background-primary-disabled)"
3083
3109
  ),
3084
3110
  children: /* @__PURE__ */ jsx34(
@@ -3549,15 +3575,27 @@ var Slider = React35.forwardRef((props, forwardedRef) => {
3549
3575
  }
3550
3576
  return rounded.toFixed(2);
3551
3577
  };
3552
- const formatDisplayValue = (val) => {
3578
+ const formatFallbackText = (val) => {
3553
3579
  const value2 = val ?? min;
3554
- if (tooltipFormatter) return tooltipFormatter(value2);
3555
3580
  if (showPercentage) {
3556
3581
  const percent = valueToPercent(value2);
3557
3582
  return `${formatNumber(percent)}%`;
3558
3583
  }
3559
3584
  return formatNumber(value2);
3560
3585
  };
3586
+ const formatDisplayNode = (val) => {
3587
+ const value2 = val ?? min;
3588
+ if (tooltipFormatter) return tooltipFormatter(value2);
3589
+ return formatFallbackText(value2);
3590
+ };
3591
+ const formatAriaValueText = (val) => {
3592
+ const fallback = formatFallbackText(val);
3593
+ if (!tooltipFormatter) return fallback;
3594
+ const node = tooltipFormatter(val ?? min);
3595
+ if (typeof node === "string") return node;
3596
+ if (typeof node === "number") return String(node);
3597
+ return fallback;
3598
+ };
3561
3599
  const formatNumericLabel = () => {
3562
3600
  if (isRange && secondary !== void 0) {
3563
3601
  if (!tooltipFormatter && showPercentage && display === "numeric") {
@@ -3565,14 +3603,18 @@ var Slider = React35.forwardRef((props, forwardedRef) => {
3565
3603
  const second = formatNumber(valueToPercent(secondary));
3566
3604
  return `${first} - ${second}`;
3567
3605
  }
3568
- return `${formatDisplayValue(primary)} - ${formatDisplayValue(secondary)}`;
3606
+ return /* @__PURE__ */ jsxs25(Fragment2, { children: [
3607
+ formatDisplayNode(primary),
3608
+ " - ",
3609
+ formatDisplayNode(secondary)
3610
+ ] });
3569
3611
  }
3570
- return formatDisplayValue(primary);
3612
+ return formatDisplayNode(primary);
3571
3613
  };
3572
3614
  const trackHeight = 32;
3573
3615
  const thumbWidth = 18;
3574
3616
  const thumbRadius = thumbWidth / 2;
3575
- const renderHandle = (index, percent, ariaValueText) => {
3617
+ const renderHandle = (index, percent, tooltipContent, ariaValueText) => {
3576
3618
  const val = index === 0 ? primary : secondary;
3577
3619
  const isDragging = draggingThumbIndex === index;
3578
3620
  const isTooltipVisible = showTooltip && (hoveredThumbIndex === index || draggingThumbIndex === index || focusedThumbIndex === index);
@@ -3625,7 +3667,7 @@ var Slider = React35.forwardRef((props, forwardedRef) => {
3625
3667
  return /* @__PURE__ */ jsx37(
3626
3668
  Tooltip,
3627
3669
  {
3628
- title: ariaValueText,
3670
+ title: tooltipContent,
3629
3671
  placement: tooltipPlacement === "top" ? "top" : "bottom",
3630
3672
  offset: 8,
3631
3673
  open: isTooltipVisible,
@@ -3687,8 +3729,18 @@ var Slider = React35.forwardRef((props, forwardedRef) => {
3687
3729
  }
3688
3730
  }
3689
3731
  ),
3690
- renderHandle(0, primaryPercent, formatDisplayValue(primary)),
3691
- isRange && secondary !== void 0 && renderHandle(1, secondaryPercent, formatDisplayValue(secondary))
3732
+ renderHandle(
3733
+ 0,
3734
+ primaryPercent,
3735
+ formatDisplayNode(primary),
3736
+ formatAriaValueText(primary)
3737
+ ),
3738
+ isRange && secondary !== void 0 && renderHandle(
3739
+ 1,
3740
+ secondaryPercent,
3741
+ formatDisplayNode(secondary),
3742
+ formatAriaValueText(secondary)
3743
+ )
3692
3744
  ]
3693
3745
  }
3694
3746
  ) }),
@@ -3772,8 +3824,8 @@ var TextArea = React36.forwardRef((props, forwardedRef) => {
3772
3824
  const textareaId = id ?? generatedId;
3773
3825
  const statusBorderClass = {
3774
3826
  default: "",
3775
- success: "border-(--border-success)",
3776
- error: "border-(--border-error)"
3827
+ success: "border-success",
3828
+ error: "border-error"
3777
3829
  };
3778
3830
  const statusShellClass = {
3779
3831
  default: "input-default",
@@ -3819,9 +3871,9 @@ var TextArea = React36.forwardRef((props, forwardedRef) => {
3819
3871
  {
3820
3872
  className: cn(
3821
3873
  "relative flex w-full rounded-4 border bg-(--background-primary) cursor-text",
3822
- "border-(--border-secondary)",
3874
+ "border-secondary",
3823
3875
  statusShellClass[status],
3824
- disabled && "bg-(--background-primary-disabled) border-(--border-secondary-disabled) cursor-default",
3876
+ disabled && "bg-(--background-primary-disabled) border-secondary-disabled cursor-default",
3825
3877
  statusBorderClass[status],
3826
3878
  className
3827
3879
  ),
@@ -4069,16 +4121,16 @@ var Toggle = React38.forwardRef((props, forwardedRef) => {
4069
4121
  // Knob position
4070
4122
  "justify-start peer-checked:justify-end",
4071
4123
  // 1: enabled, unchecked, unhovered, unfocused
4072
- "border-(--border-secondary)",
4124
+ "border-secondary",
4073
4125
  // 3: enabled, unchecked, hovered, unfocused
4074
- "hover:border-(--border-secondary-hover)",
4126
+ "hover:border-secondary-hover",
4075
4127
  // 2: enabled, checked, unhovered, unfocused
4076
- "peer-checked:border-(--border-brand)",
4128
+ "peer-checked:border-brand",
4077
4129
  // 4: enabled, checked, hovered, unfocused
4078
- "peer-checked:hover:border-(--border-brand-hover)",
4130
+ "peer-checked:hover:border-brand-hover",
4079
4131
  "peer-checked:hover:shadow-[0_0_0_var(--focus-ring-spread)_var(--focus-secondary)]",
4080
4132
  // 5: enabled, unchecked, unhovered, focused
4081
- "peer-focus-visible:border-(--border-brand-focus)",
4133
+ "peer-focus-visible:border-brand-focus",
4082
4134
  // 6: enabled, checked, unhovered, focused
4083
4135
  "peer-checked:peer-focus-visible:bg-(--background-brand-focus)",
4084
4136
  "peer-checked:peer-focus-visible:shadow-[0_0_0_var(--focus-ring-spread)_var(--focus-primary)]",
@@ -4087,7 +4139,7 @@ var Toggle = React38.forwardRef((props, forwardedRef) => {
4087
4139
  "peer-disabled:border-none",
4088
4140
  "peer-disabled:shadow-none",
4089
4141
  // 8: disabled, checked (override)
4090
- "peer-disabled:peer-checked:border-(--border-primary-disabled)",
4142
+ "peer-disabled:peer-checked:border-primary-disabled",
4091
4143
  // Disable hover when disabled
4092
4144
  "peer-disabled:pointer-events-none",
4093
4145
  // Knob on (enabled)
@@ -4146,7 +4198,7 @@ var WebsiteInput = React39.forwardRef((props, forwardedRef) => {
4146
4198
  const baseClass = cn(
4147
4199
  "[&>span]:w-[unset] hover:bg-[unset]",
4148
4200
  !disabled && "[&:not(:focus-within):hover]:shadow-[0_0_0_var(--focus-ring-spread)_var(--background-secondary-hover)]",
4149
- disabled && "bg-[unset] hover:shadow-none hover:border-(--border-secondary-disabled) border-(--border-secondary-disabled)",
4201
+ disabled && "bg-[unset] hover:shadow-none hover:border-secondary-disabled border-secondary-disabled",
4150
4202
  spanHeightClass
4151
4203
  );
4152
4204
  const addonTextClass = cn(
@@ -4157,9 +4209,9 @@ var WebsiteInput = React39.forwardRef((props, forwardedRef) => {
4157
4209
  const baseAddonClass = cn(
4158
4210
  "flex items-center gap-2 px-2 h-full",
4159
4211
  // layout + padding
4160
- "border-(--border-secondary)",
4212
+ "border-secondary",
4161
4213
  // divider color
4162
- disabled && "border-(--border-secondary-disabled) hover:border-(--border-secondary-disabled)",
4214
+ disabled && "border-secondary-disabled hover:border-secondary-disabled",
4163
4215
  isLeading ? "border-r" : "border-l"
4164
4216
  );
4165
4217
  const iconWrapperClass = cn(
@@ -4422,7 +4474,7 @@ var Breadcrumbs = React43.forwardRef(
4422
4474
  DropdownMenuContent,
4423
4475
  {
4424
4476
  align: "start",
4425
- className: "bg-(--background-neutral) border-(--border-secondary-hover) shadow-card-md rounded-4",
4477
+ className: "bg-(--background-neutral) border-secondary-hover shadow-card-md rounded-4",
4426
4478
  children: /* @__PURE__ */ jsx45(DropdownMenuGroup, { children: hiddenItems.map((hidden, hiddenIndex) => {
4427
4479
  const hiddenKey = React43.isValidElement(hidden) && hidden.key != null ? String(hidden.key) : `hidden-${hiddenIndex}`;
4428
4480
  if (React43.isValidElement(hidden)) {