@vritti/quantum-ui 0.6.10 → 0.6.11

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 (173) hide show
  1. package/dist/Avatar.js +5 -5
  2. package/dist/Badge2.js +86 -11
  3. package/dist/Badge2.js.map +1 -1
  4. package/dist/ChartFrame.js +4 -1
  5. package/dist/ChartFrame.js.map +1 -1
  6. package/dist/Checkbox2.js +5 -5
  7. package/dist/CurrencyFieldFilter.js +60 -34
  8. package/dist/CurrencyFieldFilter.js.map +1 -1
  9. package/dist/Dialog.js +1 -1
  10. package/dist/DropdownMenu.js +6 -1
  11. package/dist/DropdownMenu.js.map +1 -1
  12. package/dist/IconSelect.js +2302 -2324
  13. package/dist/IconSelect.js.map +1 -1
  14. package/dist/Input.js +1 -1
  15. package/dist/Input.js.map +1 -1
  16. package/dist/Label.js +1 -1
  17. package/dist/OTPField.js +2 -2
  18. package/dist/OTPField.js.map +1 -1
  19. package/dist/PhoneField.js +2 -2
  20. package/dist/PhoneField.js.map +1 -1
  21. package/dist/Progress.js +2 -2
  22. package/dist/QuantityField.js +125 -11
  23. package/dist/QuantityField.js.map +1 -1
  24. package/dist/RadioGroup.js +7 -7
  25. package/dist/Select.js +92 -4
  26. package/dist/Select.js.map +1 -1
  27. package/dist/Sidebar.js +1 -1
  28. package/dist/SingleSelect.js +1 -1
  29. package/dist/SingleSelect.js.map +1 -1
  30. package/dist/Sonner.js +1 -1
  31. package/dist/Switch.js +5 -5
  32. package/dist/TabsSkeleton.js +2 -2
  33. package/dist/TextArea.js +1 -1
  34. package/dist/TextArea.js.map +1 -1
  35. package/dist/TextField.js +29 -27
  36. package/dist/TextField.js.map +1 -1
  37. package/dist/Toggle.js +1 -1
  38. package/dist/assets/quantum-ui.css +453 -239
  39. package/dist/bindFilters.js +14 -1
  40. package/dist/bindFilters.js.map +1 -1
  41. package/dist/components/ContextBar.js.map +1 -1
  42. package/dist/components/RichTextEditor.js +1 -1
  43. package/dist/components/TreeView.js +4 -4
  44. package/dist/currencyCode.js +1520 -0
  45. package/dist/currencyCode.js.map +1 -0
  46. package/dist/dropdown-menu.js +9 -9
  47. package/dist/image-component.js +1 -1
  48. package/dist/index.js +1 -1
  49. package/dist/index10.js +37 -1499
  50. package/dist/index10.js.map +1 -1
  51. package/dist/index11.js +503 -28
  52. package/dist/index11.js.map +1 -1
  53. package/dist/index12.js +230 -454
  54. package/dist/index12.js.map +1 -1
  55. package/dist/index13.js +1073 -214
  56. package/dist/index13.js.map +1 -1
  57. package/dist/index14.js +20 -1139
  58. package/dist/index14.js.map +1 -1
  59. package/dist/index15.js +14 -20
  60. package/dist/index15.js.map +1 -1
  61. package/dist/index16.js +173 -19
  62. package/dist/index16.js.map +1 -1
  63. package/dist/index17.js +173 -168
  64. package/dist/index17.js.map +1 -1
  65. package/dist/index18.js +201 -171
  66. package/dist/index18.js.map +1 -1
  67. package/dist/index19.js +190 -186
  68. package/dist/index19.js.map +1 -1
  69. package/dist/index20.js +204 -202
  70. package/dist/index20.js.map +1 -1
  71. package/dist/index21.js +68 -209
  72. package/dist/index21.js.map +1 -1
  73. package/dist/index22.js +1128 -70
  74. package/dist/index22.js.map +1 -1
  75. package/dist/index23.js +4 -1133
  76. package/dist/index23.js.map +1 -1
  77. package/dist/index24.js +232 -4
  78. package/dist/index24.js.map +1 -1
  79. package/dist/index25.js +1100 -207
  80. package/dist/index25.js.map +1 -1
  81. package/dist/index26.js +2469 -1023
  82. package/dist/index26.js.map +1 -1
  83. package/dist/index27.js +35 -2569
  84. package/dist/index27.js.map +1 -1
  85. package/dist/index28.js +308 -36
  86. package/dist/index28.js.map +1 -1
  87. package/dist/index29.js +7 -307
  88. package/dist/index29.js.map +1 -1
  89. package/dist/index30.js +30 -8
  90. package/dist/index30.js.map +1 -1
  91. package/dist/index31.js +59 -29
  92. package/dist/index31.js.map +1 -1
  93. package/dist/index32.js +10 -59
  94. package/dist/index32.js.map +1 -1
  95. package/dist/index33.js +35347 -9
  96. package/dist/index33.js.map +1 -1
  97. package/dist/index34.js +72 -35342
  98. package/dist/index34.js.map +1 -1
  99. package/dist/index35.js +187 -72
  100. package/dist/index35.js.map +1 -1
  101. package/dist/index5.js +4 -4
  102. package/dist/index9.js +1 -1
  103. package/dist/lib/components/ContextBar/useContextState.d.ts +7 -1
  104. package/dist/lib/components/ContextBar/useContextState.d.ts.map +1 -1
  105. package/dist/lib/components/CurrencyField/CurrencyField.d.ts +8 -4
  106. package/dist/lib/components/CurrencyField/CurrencyField.d.ts.map +1 -1
  107. package/dist/lib/components/CurrencyField/CurrencyFieldFilter.d.ts +3 -2
  108. package/dist/lib/components/CurrencyField/CurrencyFieldFilter.d.ts.map +1 -1
  109. package/dist/lib/components/DropdownMenu/DropdownMenu.d.ts.map +1 -1
  110. package/dist/lib/components/DropdownMenu/types.d.ts +2 -0
  111. package/dist/lib/components/DropdownMenu/types.d.ts.map +1 -1
  112. package/dist/lib/components/Field/numberConstraints.d.ts +19 -0
  113. package/dist/lib/components/Field/numberConstraints.d.ts.map +1 -0
  114. package/dist/lib/components/PhoneField/PhoneField.d.ts.map +1 -1
  115. package/dist/lib/components/QuantityField/QuantityField.d.ts +5 -0
  116. package/dist/lib/components/QuantityField/QuantityField.d.ts.map +1 -1
  117. package/dist/lib/components/Select/Select.d.ts +3 -0
  118. package/dist/lib/components/Select/Select.d.ts.map +1 -1
  119. package/dist/lib/components/Select/hooks/useSelect.d.ts +2 -0
  120. package/dist/lib/components/Select/hooks/useSelect.d.ts.map +1 -1
  121. package/dist/lib/components/TextField/TextField.d.ts.map +1 -1
  122. package/dist/lib/hooks/useWorkspaceCurrency.d.ts +2 -1
  123. package/dist/lib/hooks/useWorkspaceCurrency.d.ts.map +1 -1
  124. package/dist/lib/types/conditions.d.ts +2 -1
  125. package/dist/lib/types/conditions.d.ts.map +1 -1
  126. package/dist/lib/{components/DataTable/components → utils}/bindFilters.d.ts +2 -1
  127. package/dist/lib/utils/bindFilters.d.ts.map +1 -0
  128. package/dist/lib/utils/currency.d.ts +7 -5
  129. package/dist/lib/utils/currency.d.ts.map +1 -1
  130. package/dist/lib/utils/currencyCode.d.ts +14 -0
  131. package/dist/lib/utils/currencyCode.d.ts.map +1 -0
  132. package/dist/lib/utils/format.d.ts +3 -5
  133. package/dist/lib/utils/format.d.ts.map +1 -1
  134. package/dist/lib/utils/money.d.ts +5 -4
  135. package/dist/lib/utils/money.d.ts.map +1 -1
  136. package/dist/lib/utils/store.d.ts +3 -0
  137. package/dist/lib/utils/store.d.ts.map +1 -0
  138. package/dist/lib/utils/zod.d.ts +3 -1
  139. package/dist/lib/utils/zod.d.ts.map +1 -1
  140. package/dist/numberConstraints.js +68 -0
  141. package/dist/numberConstraints.js.map +1 -0
  142. package/dist/popover.js +1 -1
  143. package/dist/react.js +45 -0
  144. package/dist/react.js.map +1 -0
  145. package/dist/ruler.js +27 -0
  146. package/dist/ruler.js.map +1 -0
  147. package/dist/select2.js +2 -2
  148. package/dist/select2.js.map +1 -1
  149. package/dist/separator2.js +1 -1
  150. package/dist/shadcn/shadcnBadge/Badge.d.ts +5 -2
  151. package/dist/shadcn/shadcnBadge/Badge.d.ts.map +1 -1
  152. package/dist/shadcn/shadcnChart/Chart.d.ts.map +1 -1
  153. package/dist/tooltip2.js +1 -1
  154. package/dist/useContextState.js +39 -6
  155. package/dist/useContextState.js.map +1 -1
  156. package/dist/useDataTable.js +3 -43
  157. package/dist/useDataTable.js.map +1 -1
  158. package/dist/useWorkspaceCurrency.js.map +1 -1
  159. package/dist/utils/currency.js +3 -14
  160. package/dist/utils/currency.js.map +1 -1
  161. package/dist/utils/format.js.map +1 -1
  162. package/dist/utils/money.js +5 -3
  163. package/dist/utils/money.js.map +1 -1
  164. package/dist/utils/motion.js +2 -2
  165. package/dist/utils/store.js +67 -0
  166. package/dist/utils/store.js.map +1 -0
  167. package/dist/utils/zod.js +10 -7
  168. package/dist/utils/zod.js.map +1 -1
  169. package/dist/value.js +1 -1
  170. package/package.json +5 -1
  171. package/dist/index36.js +0 -199
  172. package/dist/index36.js.map +0 -1
  173. package/dist/lib/components/DataTable/components/bindFilters.d.ts.map +0 -1
package/dist/Avatar.js CHANGED
@@ -1,10 +1,10 @@
1
1
  import { jsx } from 'react/jsx-runtime';
2
2
  import * as React from 'react';
3
- import { c as createContextScope } from './index32.js';
4
- import { u as useCallbackRef } from './index30.js';
5
- import { u as useLayoutEffect2 } from './index24.js';
6
- import { P as Primitive } from './index28.js';
7
- import { r as requireShim } from './index36.js';
3
+ import { c as createContextScope } from './index31.js';
4
+ import { u as useCallbackRef } from './index29.js';
5
+ import { u as useLayoutEffect2 } from './index23.js';
6
+ import { P as Primitive } from './index27.js';
7
+ import { r as requireShim } from './index35.js';
8
8
  import { c as cn } from './utils.js';
9
9
 
10
10
  var shimExports = requireShim();
package/dist/Badge2.js CHANGED
@@ -1,33 +1,108 @@
1
- import { jsx } from 'react/jsx-runtime';
1
+ import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { S as Slot } from './index9.js';
3
3
  import { c as cva } from './index8.js';
4
4
  import { c as cn } from './utils.js';
5
5
 
6
+ const TONES = {
7
+ destructive: {
8
+ solid: "bg-destructive text-destructive-foreground dark:bg-destructive/60",
9
+ soft: "bg-destructive/15 text-destructive-ink dark:bg-destructive/15",
10
+ outline: "border-destructive/45 text-destructive-ink dark:bg-transparent"
11
+ },
12
+ success: {
13
+ solid: "bg-success text-success-foreground",
14
+ soft: "bg-success/15 text-success-ink",
15
+ outline: "border-success/50 text-success-ink"
16
+ },
17
+ warning: {
18
+ solid: "bg-warning text-warning-foreground",
19
+ soft: "bg-warning/15 text-warning-ink",
20
+ outline: "border-warning/60 text-warning-ink"
21
+ },
22
+ info: {
23
+ solid: "bg-info text-info-foreground",
24
+ soft: "bg-info/15 text-info-ink",
25
+ outline: "border-info/55 text-info-ink"
26
+ },
27
+ excess: {
28
+ solid: "bg-group-violet text-excess-foreground dark:bg-group-violet/70",
29
+ soft: "bg-group-violet/15 text-excess-ink",
30
+ outline: "border-group-violet/45 text-excess-ink"
31
+ },
32
+ notice: {
33
+ solid: "bg-notice text-notice-foreground",
34
+ soft: "bg-notice/15 text-notice-ink",
35
+ outline: "border-notice/45 text-notice-ink dark:border-notice-ink/45"
36
+ }
37
+ };
38
+ const appearanceVariants = Object.keys(TONES).flatMap(
39
+ (tone) => Object.keys(TONES[tone]).map((appearance) => ({
40
+ variant: tone,
41
+ appearance,
42
+ // An outline drops the fill its variant draws by default
43
+ className: cn(appearance === "outline" && "bg-transparent", TONES[tone][appearance])
44
+ }))
45
+ );
6
46
  const badgeVariants = cva(
7
- "inline-flex items-center justify-center rounded-full border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] transition-[color,box-shadow] overflow-hidden",
47
+ "inline-flex items-center justify-center border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-3 transition-[color,box-shadow] overflow-hidden",
8
48
  {
9
49
  variants: {
10
50
  variant: {
11
51
  default: "bg-primary text-primary-foreground [a&]:hover:bg-primary/90",
12
52
  secondary: "bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",
13
- destructive: "bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
14
- success: "bg-success/15 text-success [a&]:hover:bg-success/25 focus-visible:ring-success/20 dark:focus-visible:ring-success/40",
15
- warning: "bg-warning/15 text-warning [a&]:hover:bg-warning/25 focus-visible:ring-warning/20 dark:focus-visible:ring-warning/40",
16
- info: "bg-info/15 text-info [a&]:hover:bg-info/25 focus-visible:ring-info/20 dark:focus-visible:ring-info/40",
17
- excess: "bg-group-violet/15 text-group-violet [a&]:hover:bg-group-violet/25 focus-visible:ring-group-violet/20 dark:focus-visible:ring-group-violet/40",
18
- outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
53
+ destructive: "bg-destructive text-destructive-foreground [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
54
+ success: "bg-success/15 text-success-ink [a&]:hover:bg-success/25 focus-visible:ring-success/20 dark:focus-visible:ring-success/40",
55
+ warning: "bg-warning/15 text-warning-ink [a&]:hover:bg-warning/25 focus-visible:ring-warning/20 dark:focus-visible:ring-warning/40",
56
+ info: "bg-info/15 text-info-ink [a&]:hover:bg-info/25 focus-visible:ring-info/20 dark:focus-visible:ring-info/40",
57
+ excess: "bg-group-violet/15 text-excess-ink [a&]:hover:bg-group-violet/25 focus-visible:ring-group-violet/20 dark:focus-visible:ring-group-violet/40",
58
+ notice: "bg-notice text-notice-foreground [a&]:hover:bg-notice/90 focus-visible:ring-notice/20",
59
+ outline: "border-foreground/25 text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
19
60
  ghost: "hover:bg-accent hover:text-accent-foreground",
20
61
  link: "text-primary underline-offset-4 hover:underline cursor-pointer"
62
+ },
63
+ // A pill, or a rounded rectangle for statuses
64
+ shape: {
65
+ pill: "rounded-full",
66
+ rounded: "rounded-md"
67
+ },
68
+ // Solid, a soft tint or an outline in the variant's tone; left out, each variant keeps its own fill
69
+ appearance: {
70
+ solid: "",
71
+ soft: "",
72
+ outline: ""
21
73
  }
22
74
  },
75
+ compoundVariants: appearanceVariants,
23
76
  defaultVariants: {
24
- variant: "default"
77
+ variant: "default",
78
+ shape: "pill"
25
79
  }
26
80
  }
27
81
  );
28
- function Badge({ className, variant = "default", asChild = false, ...props }) {
82
+ function Badge({
83
+ className,
84
+ variant = "default",
85
+ shape,
86
+ appearance,
87
+ dot = false,
88
+ asChild = false,
89
+ children,
90
+ ...props
91
+ }) {
29
92
  const Comp = asChild ? Slot : "span";
30
- return /* @__PURE__ */ jsx(Comp, { "data-slot": "badge", "data-variant": variant, className: cn(badgeVariants({ variant }), className), ...props });
93
+ return /* @__PURE__ */ jsxs(
94
+ Comp,
95
+ {
96
+ "data-slot": "badge",
97
+ "data-variant": variant,
98
+ className: cn(badgeVariants({ variant, shape, appearance }), className),
99
+ ...props,
100
+ children: [
101
+ dot && !asChild && /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "size-1.5 shrink-0 rounded-full bg-current" }),
102
+ children
103
+ ]
104
+ }
105
+ );
31
106
  }
32
107
 
33
108
  export { Badge as B, badgeVariants as b };
@@ -1 +1 @@
1
- {"version":3,"file":"Badge2.js","sources":["../shadcn/shadcnBadge/Badge.tsx"],"sourcesContent":["import { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport type * as React from 'react';\nimport { cn } from '../utils';\n\nconst badgeVariants = cva(\n 'inline-flex items-center justify-center rounded-full border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] transition-[color,box-shadow] overflow-hidden',\n {\n variants: {\n variant: {\n default: 'bg-primary text-primary-foreground [a&]:hover:bg-primary/90',\n secondary: 'bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90',\n destructive:\n 'bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60',\n success:\n 'bg-success/15 text-success [a&]:hover:bg-success/25 focus-visible:ring-success/20 dark:focus-visible:ring-success/40',\n warning:\n 'bg-warning/15 text-warning [a&]:hover:bg-warning/25 focus-visible:ring-warning/20 dark:focus-visible:ring-warning/40',\n info: 'bg-info/15 text-info [a&]:hover:bg-info/25 focus-visible:ring-info/20 dark:focus-visible:ring-info/40',\n excess:\n 'bg-group-violet/15 text-group-violet [a&]:hover:bg-group-violet/25 focus-visible:ring-group-violet/20 dark:focus-visible:ring-group-violet/40',\n outline: 'border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground',\n ghost: 'hover:bg-accent hover:text-accent-foreground',\n link: 'text-primary underline-offset-4 hover:underline cursor-pointer',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nexport interface BadgeProps extends React.ComponentProps<'span'>, VariantProps<typeof badgeVariants> {\n asChild?: boolean;\n}\n\nfunction Badge({ className, variant = 'default', asChild = false, ...props }: BadgeProps) {\n const Comp = asChild ? Slot : 'span';\n\n return (\n <Comp data-slot=\"badge\" data-variant={variant} className={cn(badgeVariants({ variant }), className)} {...props} />\n );\n}\n\nexport { Badge, badgeVariants };\n"],"names":[],"mappings":";;;;;AAKA,MAAM,aAAA,GAAgB,GAAA;AAAA,EACpB,8TAAA;AAAA,EACA;AAAA,IACE,QAAA,EAAU;AAAA,MACR,OAAA,EAAS;AAAA,QACP,OAAA,EAAS,6DAAA;AAAA,QACT,SAAA,EAAW,mEAAA;AAAA,QACX,WAAA,EACE,wJAAA;AAAA,QACF,OAAA,EACE,sHAAA;AAAA,QACF,OAAA,EACE,sHAAA;AAAA,QACF,IAAA,EAAM,uGAAA;AAAA,QACN,MAAA,EACE,+IAAA;AAAA,QACF,OAAA,EAAS,sFAAA;AAAA,QACT,KAAA,EAAO,8CAAA;AAAA,QACP,IAAA,EAAM;AAAA;AACR,KACF;AAAA,IACA,eAAA,EAAiB;AAAA,MACf,OAAA,EAAS;AAAA;AACX;AAEJ;AAMA,SAAS,KAAA,CAAM,EAAE,SAAA,EAAW,OAAA,GAAU,WAAW,OAAA,GAAU,KAAA,EAAO,GAAG,KAAA,EAAM,EAAe;AACxF,EAAA,MAAM,IAAA,GAAO,UAAU,IAAA,GAAO,MAAA;AAE9B,EAAA,2BACG,IAAA,EAAA,EAAK,WAAA,EAAU,OAAA,EAAQ,cAAA,EAAc,SAAS,SAAA,EAAW,EAAA,CAAG,aAAA,CAAc,EAAE,SAAS,CAAA,EAAG,SAAS,CAAA,EAAI,GAAG,KAAA,EAAO,CAAA;AAEpH;;;;"}
1
+ {"version":3,"file":"Badge2.js","sources":["../shadcn/shadcnBadge/Badge.tsx"],"sourcesContent":["import { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport type * as React from 'react';\nimport { cn } from '../utils';\n\n// The tones that can be drawn solid, soft or outlined, with the classes each appearance takes for them\nconst TONES = {\n destructive: {\n solid: 'bg-destructive text-destructive-foreground dark:bg-destructive/60',\n soft: 'bg-destructive/15 text-destructive-ink dark:bg-destructive/15',\n outline: 'border-destructive/45 text-destructive-ink dark:bg-transparent',\n },\n success: {\n solid: 'bg-success text-success-foreground',\n soft: 'bg-success/15 text-success-ink',\n outline: 'border-success/50 text-success-ink',\n },\n warning: {\n solid: 'bg-warning text-warning-foreground',\n soft: 'bg-warning/15 text-warning-ink',\n outline: 'border-warning/60 text-warning-ink',\n },\n info: {\n solid: 'bg-info text-info-foreground',\n soft: 'bg-info/15 text-info-ink',\n outline: 'border-info/55 text-info-ink',\n },\n excess: {\n solid: 'bg-group-violet text-excess-foreground dark:bg-group-violet/70',\n soft: 'bg-group-violet/15 text-excess-ink',\n outline: 'border-group-violet/45 text-excess-ink',\n },\n notice: {\n solid: 'bg-notice text-notice-foreground',\n soft: 'bg-notice/15 text-notice-ink',\n outline: 'border-notice/45 text-notice-ink dark:border-notice-ink/45',\n },\n} as const;\n\ntype Tone = keyof typeof TONES;\ntype Appearance = keyof (typeof TONES)[Tone];\n\nconst appearanceVariants = (Object.keys(TONES) as Tone[]).flatMap((tone) =>\n (Object.keys(TONES[tone]) as Appearance[]).map((appearance) => ({\n variant: tone,\n appearance,\n // An outline drops the fill its variant draws by default\n className: cn(appearance === 'outline' && 'bg-transparent', TONES[tone][appearance]),\n })),\n);\n\nconst badgeVariants = cva(\n 'inline-flex items-center justify-center border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-3 transition-[color,box-shadow] overflow-hidden',\n {\n variants: {\n variant: {\n default: 'bg-primary text-primary-foreground [a&]:hover:bg-primary/90',\n secondary: 'bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90',\n destructive:\n 'bg-destructive text-destructive-foreground [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60',\n success:\n 'bg-success/15 text-success-ink [a&]:hover:bg-success/25 focus-visible:ring-success/20 dark:focus-visible:ring-success/40',\n warning:\n 'bg-warning/15 text-warning-ink [a&]:hover:bg-warning/25 focus-visible:ring-warning/20 dark:focus-visible:ring-warning/40',\n info: 'bg-info/15 text-info-ink [a&]:hover:bg-info/25 focus-visible:ring-info/20 dark:focus-visible:ring-info/40',\n excess:\n 'bg-group-violet/15 text-excess-ink [a&]:hover:bg-group-violet/25 focus-visible:ring-group-violet/20 dark:focus-visible:ring-group-violet/40',\n notice: 'bg-notice text-notice-foreground [a&]:hover:bg-notice/90 focus-visible:ring-notice/20',\n outline: 'border-foreground/25 text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground',\n ghost: 'hover:bg-accent hover:text-accent-foreground',\n link: 'text-primary underline-offset-4 hover:underline cursor-pointer',\n },\n // A pill, or a rounded rectangle for statuses\n shape: {\n pill: 'rounded-full',\n rounded: 'rounded-md',\n },\n // Solid, a soft tint or an outline in the variant's tone; left out, each variant keeps its own fill\n appearance: {\n solid: '',\n soft: '',\n outline: '',\n },\n },\n compoundVariants: appearanceVariants,\n defaultVariants: {\n variant: 'default',\n shape: 'pill',\n },\n },\n);\n\nexport interface BadgeProps extends React.ComponentProps<'span'>, VariantProps<typeof badgeVariants> {\n asChild?: boolean;\n // A leading dot in the text colour, for a status\n dot?: boolean;\n}\n\nfunction Badge({\n className,\n variant = 'default',\n shape,\n appearance,\n dot = false,\n asChild = false,\n children,\n ...props\n}: BadgeProps) {\n const Comp = asChild ? Slot : 'span';\n\n return (\n <Comp\n data-slot=\"badge\"\n data-variant={variant}\n className={cn(badgeVariants({ variant, shape, appearance }), className)}\n {...props}\n >\n {dot && !asChild && <span aria-hidden className=\"size-1.5 shrink-0 rounded-full bg-current\" />}\n {children}\n </Comp>\n );\n}\n\nexport { Badge, badgeVariants };\n"],"names":[],"mappings":"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"}
@@ -25138,7 +25138,10 @@ function ChartTooltipContent({
25138
25138
  /* @__PURE__ */ jsxs(
25139
25139
  "div",
25140
25140
  {
25141
- className: cn("flex flex-1 justify-between gap-4 leading-none", nestLabel ? "items-end" : "items-center"),
25141
+ className: cn(
25142
+ "flex flex-1 justify-between gap-4 leading-none",
25143
+ nestLabel ? "items-end" : "items-center"
25144
+ ),
25142
25145
  children: [
25143
25146
  /* @__PURE__ */ jsxs("div", { className: "grid gap-1.5", children: [
25144
25147
  nestLabel ? tooltipLabel : null,