@codefast/ui 0.3.11 → 0.3.12-canary.0

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 (246) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/README.md +4 -0
  3. package/dist/components/accordion.d.ts +11 -29
  4. package/dist/components/accordion.d.ts.map +1 -0
  5. package/dist/components/accordion.js +10 -37
  6. package/dist/components/alert-dialog.d.ts +25 -60
  7. package/dist/components/alert-dialog.d.ts.map +1 -0
  8. package/dist/components/alert-dialog.js +16 -69
  9. package/dist/components/alert.d.ts +16 -27
  10. package/dist/components/alert.d.ts.map +1 -0
  11. package/dist/components/alert.js +22 -30
  12. package/dist/components/aspect-ratio.d.ts +5 -8
  13. package/dist/components/aspect-ratio.d.ts.map +1 -0
  14. package/dist/components/aspect-ratio.js +5 -7
  15. package/dist/components/avatar.d.ts +7 -17
  16. package/dist/components/avatar.d.ts.map +1 -0
  17. package/dist/components/avatar.js +7 -18
  18. package/dist/components/badge.d.ts +15 -21
  19. package/dist/components/badge.d.ts.map +1 -0
  20. package/dist/components/badge.js +23 -20
  21. package/dist/components/breadcrumb.d.ts +13 -35
  22. package/dist/components/breadcrumb.d.ts.map +1 -0
  23. package/dist/components/breadcrumb.js +13 -49
  24. package/dist/components/button-group.d.ts +15 -29
  25. package/dist/components/button-group.d.ts.map +1 -0
  26. package/dist/components/button-group.js +22 -27
  27. package/dist/components/button.d.ts +26 -35
  28. package/dist/components/button.d.ts.map +1 -0
  29. package/dist/components/button.js +43 -51
  30. package/dist/components/calendar.d.ts +10 -24
  31. package/dist/components/calendar.d.ts.map +1 -0
  32. package/dist/components/calendar.js +75 -92
  33. package/dist/components/card.d.ts +11 -34
  34. package/dist/components/card.d.ts.map +1 -0
  35. package/dist/components/card.js +11 -39
  36. package/dist/components/carousel.d.ts +25 -55
  37. package/dist/components/carousel.d.ts.map +1 -0
  38. package/dist/components/carousel.js +82 -114
  39. package/dist/components/chart.d.ts +37 -72
  40. package/dist/components/chart.d.ts.map +1 -0
  41. package/dist/components/chart.js +161 -150
  42. package/dist/components/checkbox-cards.d.ts +9 -15
  43. package/dist/components/checkbox-cards.d.ts.map +1 -0
  44. package/dist/components/checkbox-cards.js +8 -22
  45. package/dist/components/checkbox-group.d.ts +9 -16
  46. package/dist/components/checkbox-group.d.ts.map +1 -0
  47. package/dist/components/checkbox-group.js +7 -19
  48. package/dist/components/checkbox.d.ts +5 -9
  49. package/dist/components/checkbox.d.ts.map +1 -0
  50. package/dist/components/checkbox.js +6 -14
  51. package/dist/components/collapsible.d.ts +7 -14
  52. package/dist/components/collapsible.d.ts.map +1 -0
  53. package/dist/components/collapsible.js +7 -15
  54. package/dist/components/command.d.ts +24 -55
  55. package/dist/components/command.d.ts.map +1 -0
  56. package/dist/components/command.js +18 -69
  57. package/dist/components/context-menu.d.ts +23 -72
  58. package/dist/components/context-menu.d.ts.map +1 -0
  59. package/dist/components/context-menu.js +21 -89
  60. package/dist/components/dialog.d.ts +23 -53
  61. package/dist/components/dialog.d.ts.map +1 -0
  62. package/dist/components/dialog.js +20 -72
  63. package/dist/components/drawer.d.ts +29 -60
  64. package/dist/components/drawer.d.ts.map +1 -0
  65. package/dist/components/drawer.js +16 -58
  66. package/dist/components/dropdown-menu.d.ts +23 -73
  67. package/dist/components/dropdown-menu.d.ts.map +1 -0
  68. package/dist/components/dropdown-menu.js +21 -96
  69. package/dist/components/empty.d.ts +16 -37
  70. package/dist/components/empty.d.ts.map +1 -0
  71. package/dist/components/empty.js +24 -44
  72. package/dist/components/field.d.ts +26 -63
  73. package/dist/components/field.d.ts.map +1 -0
  74. package/dist/components/field.js +46 -89
  75. package/dist/components/form.d.ts +16 -37
  76. package/dist/components/form.d.ts.map +1 -0
  77. package/dist/components/form.js +50 -66
  78. package/dist/components/hover-card.d.ts +8 -21
  79. package/dist/components/hover-card.d.ts.map +1 -0
  80. package/dist/components/hover-card.js +8 -23
  81. package/dist/components/input-group.d.ts +29 -53
  82. package/dist/components/input-group.d.ts.map +1 -0
  83. package/dist/components/input-group.js +59 -66
  84. package/dist/components/input-number.d.ts +8 -28
  85. package/dist/components/input-number.d.ts.map +1 -0
  86. package/dist/components/input-number.js +14 -55
  87. package/dist/components/input-otp.d.ts +11 -24
  88. package/dist/components/input-otp.d.ts.map +1 -0
  89. package/dist/components/input-otp.js +13 -34
  90. package/dist/components/input-password.d.ts +6 -12
  91. package/dist/components/input-password.d.ts.map +1 -0
  92. package/dist/components/input-password.js +10 -31
  93. package/dist/components/input-search.d.ts +9 -18
  94. package/dist/components/input-search.d.ts.map +1 -0
  95. package/dist/components/input-search.js +16 -44
  96. package/dist/components/input.d.ts +5 -10
  97. package/dist/components/input.d.ts.map +1 -0
  98. package/dist/components/input.js +5 -9
  99. package/dist/components/item.d.ts +33 -69
  100. package/dist/components/item.d.ts.map +1 -0
  101. package/dist/components/item.js +47 -90
  102. package/dist/components/kbd.d.ts +6 -13
  103. package/dist/components/kbd.d.ts.map +1 -0
  104. package/dist/components/kbd.js +6 -13
  105. package/dist/components/label.d.ts +5 -9
  106. package/dist/components/label.d.ts.map +1 -0
  107. package/dist/components/label.js +5 -8
  108. package/dist/components/menubar.d.ts +24 -80
  109. package/dist/components/menubar.d.ts.map +1 -0
  110. package/dist/components/menubar.js +23 -99
  111. package/dist/components/native-select.d.ts +7 -16
  112. package/dist/components/native-select.d.ts.map +1 -0
  113. package/dist/components/native-select.js +7 -25
  114. package/dist/components/navigation-menu.d.ts +13 -36
  115. package/dist/components/navigation-menu.d.ts.map +1 -0
  116. package/dist/components/navigation-menu.js +25 -61
  117. package/dist/components/pagination.d.ts +15 -35
  118. package/dist/components/pagination.d.ts.map +1 -0
  119. package/dist/components/pagination.js +13 -55
  120. package/dist/components/popover.d.ts +9 -24
  121. package/dist/components/popover.d.ts.map +1 -0
  122. package/dist/components/popover.js +9 -27
  123. package/dist/components/progress-circle.d.ts +89 -106
  124. package/dist/components/progress-circle.d.ts.map +1 -0
  125. package/dist/components/progress-circle.js +70 -103
  126. package/dist/components/progress.d.ts +5 -10
  127. package/dist/components/progress.d.ts.map +1 -0
  128. package/dist/components/progress.js +7 -13
  129. package/dist/components/radio-cards.d.ts +5 -10
  130. package/dist/components/radio-cards.d.ts.map +1 -0
  131. package/dist/components/radio-cards.js +7 -21
  132. package/dist/components/radio-group.d.ts +6 -13
  133. package/dist/components/radio-group.d.ts.map +1 -0
  134. package/dist/components/radio-group.js +6 -17
  135. package/dist/components/radio.d.ts +6 -12
  136. package/dist/components/radio.d.ts.map +1 -0
  137. package/dist/components/radio.js +5 -10
  138. package/dist/components/resizable.d.ts +8 -18
  139. package/dist/components/resizable.d.ts.map +1 -0
  140. package/dist/components/resizable.js +7 -21
  141. package/dist/components/scroll-area.d.ts +21 -33
  142. package/dist/components/scroll-area.d.ts.map +1 -0
  143. package/dist/components/scroll-area.js +64 -84
  144. package/dist/components/select.d.ts +17 -50
  145. package/dist/components/select.d.ts.map +1 -0
  146. package/dist/components/select.js +26 -78
  147. package/dist/components/separator.d.ts +20 -29
  148. package/dist/components/separator.d.ts.map +1 -0
  149. package/dist/components/separator.js +27 -36
  150. package/dist/components/sheet.d.ts +30 -62
  151. package/dist/components/sheet.d.ts.map +1 -0
  152. package/dist/components/sheet.js +36 -80
  153. package/dist/components/sidebar.d.ts +67 -160
  154. package/dist/components/sidebar.d.ts.map +1 -0
  155. package/dist/components/sidebar.js +166 -301
  156. package/dist/components/skeleton.d.ts +5 -9
  157. package/dist/components/skeleton.d.ts.map +1 -0
  158. package/dist/components/skeleton.js +5 -8
  159. package/dist/components/slider.d.ts +5 -13
  160. package/dist/components/slider.d.ts.map +1 -0
  161. package/dist/components/slider.js +12 -34
  162. package/dist/components/sonner.d.ts +8 -10
  163. package/dist/components/sonner.d.ts.map +1 -0
  164. package/dist/components/sonner.js +13 -16
  165. package/dist/components/spinner.d.ts +6 -12
  166. package/dist/components/spinner.d.ts.map +1 -0
  167. package/dist/components/spinner.js +20 -33
  168. package/dist/components/switch.d.ts +5 -9
  169. package/dist/components/switch.d.ts.map +1 -0
  170. package/dist/components/switch.js +5 -12
  171. package/dist/components/table.d.ts +12 -37
  172. package/dist/components/table.d.ts.map +1 -0
  173. package/dist/components/table.js +12 -47
  174. package/dist/components/tabs.d.ts +8 -21
  175. package/dist/components/tabs.d.ts.map +1 -0
  176. package/dist/components/tabs.js +8 -23
  177. package/dist/components/textarea.d.ts +5 -9
  178. package/dist/components/textarea.d.ts.map +1 -0
  179. package/dist/components/textarea.js +5 -8
  180. package/dist/components/toggle-group.d.ts +10 -24
  181. package/dist/components/toggle-group.d.ts.map +1 -0
  182. package/dist/components/toggle-group.js +20 -38
  183. package/dist/components/toggle.d.ts +18 -25
  184. package/dist/components/toggle.d.ts.map +1 -0
  185. package/dist/components/toggle.js +24 -29
  186. package/dist/components/tooltip.d.ts +9 -24
  187. package/dist/components/tooltip.d.ts.map +1 -0
  188. package/dist/components/tooltip.js +9 -28
  189. package/dist/hooks/use-animated-value.d.ts +2 -4
  190. package/dist/hooks/use-animated-value.d.ts.map +1 -0
  191. package/dist/hooks/use-animated-value.js +67 -58
  192. package/dist/hooks/use-copy-to-clipboard.d.ts +6 -11
  193. package/dist/hooks/use-copy-to-clipboard.d.ts.map +1 -0
  194. package/dist/hooks/use-copy-to-clipboard.js +42 -39
  195. package/dist/hooks/use-is-mobile.d.ts +2 -4
  196. package/dist/hooks/use-is-mobile.d.ts.map +1 -0
  197. package/dist/hooks/use-is-mobile.js +20 -23
  198. package/dist/hooks/use-media-query.d.ts +2 -4
  199. package/dist/hooks/use-media-query.d.ts.map +1 -0
  200. package/dist/hooks/use-media-query.js +49 -46
  201. package/dist/hooks/use-mutation-observer.d.ts +3 -6
  202. package/dist/hooks/use-mutation-observer.d.ts.map +1 -0
  203. package/dist/hooks/use-mutation-observer.js +33 -34
  204. package/dist/hooks/use-pagination.d.ts +15 -22
  205. package/dist/hooks/use-pagination.d.ts.map +1 -0
  206. package/dist/hooks/use-pagination.js +99 -99
  207. package/dist/index.d.ts +131 -69
  208. package/dist/index.d.ts.map +1 -0
  209. package/dist/index.js +68 -69
  210. package/dist/primitives/checkbox-group.d.ts +84 -105
  211. package/dist/primitives/checkbox-group.d.ts.map +1 -0
  212. package/dist/primitives/checkbox-group.js +91 -105
  213. package/dist/primitives/input-number.d.ts +41 -51
  214. package/dist/primitives/input-number.d.ts.map +1 -0
  215. package/dist/primitives/input-number.js +417 -473
  216. package/dist/primitives/input.d.ts +43 -48
  217. package/dist/primitives/input.d.ts.map +1 -0
  218. package/dist/primitives/input.js +67 -66
  219. package/dist/primitives/progress-circle.d.ts +49 -79
  220. package/dist/primitives/progress-circle.d.ts.map +1 -0
  221. package/dist/primitives/progress-circle.js +134 -149
  222. package/package.json +17 -10
  223. package/{dist → src}/css/preset.css +1 -1
  224. /package/{dist → src}/css/amber.css +0 -0
  225. /package/{dist → src}/css/blue.css +0 -0
  226. /package/{dist → src}/css/cyan.css +0 -0
  227. /package/{dist → src}/css/emerald.css +0 -0
  228. /package/{dist → src}/css/fuchsia.css +0 -0
  229. /package/{dist → src}/css/gray.css +0 -0
  230. /package/{dist → src}/css/green.css +0 -0
  231. /package/{dist → src}/css/indigo.css +0 -0
  232. /package/{dist → src}/css/lime.css +0 -0
  233. /package/{dist → src}/css/neutral.css +0 -0
  234. /package/{dist → src}/css/orange.css +0 -0
  235. /package/{dist → src}/css/pink.css +0 -0
  236. /package/{dist → src}/css/purple.css +0 -0
  237. /package/{dist → src}/css/red.css +0 -0
  238. /package/{dist → src}/css/rose.css +0 -0
  239. /package/{dist → src}/css/sky.css +0 -0
  240. /package/{dist → src}/css/slate.css +0 -0
  241. /package/{dist → src}/css/stone.css +0 -0
  242. /package/{dist → src}/css/style.css +0 -0
  243. /package/{dist → src}/css/teal.css +0 -0
  244. /package/{dist → src}/css/violet.css +0 -0
  245. /package/{dist → src}/css/yellow.css +0 -0
  246. /package/{dist → src}/css/zinc.css +0 -0
@@ -1,116 +1,83 @@
1
1
  "use client";
2
- import { useAnimatedValue } from "../hooks/use-animated-value.js";
3
- import { Indicator as ProgressCircleIndicator, ProgressCircle as ProgressCircle$1, ProgressCircleProvider, ProgressCircleSVG, ProgressCircleTrack, ProgressCircleValue } from "../primitives/progress-circle.js";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
4
3
  import { tv } from "@codefast/tailwind-variants";
5
- import { jsx, jsxs } from "react/jsx-runtime";
6
4
  import { useCallback, useMemo } from "react";
7
- //#region src/components/progress-circle.tsx
5
+ import { useAnimatedValue } from "#hooks/use-animated-value";
6
+ import * as ProgressCirclePrimitive from "#primitives/progress-circle";
7
+ /* -------------------------------------------------------------------------------------------------
8
+ * Variant: ProgressCircle
9
+ * ----------------------------------------------------------------------------------------------- */
8
10
  const progressCircleVariants = tv({
9
- defaultVariants: {
10
- size: "md",
11
- thickness: "regular",
12
- variant: "default"
13
- },
14
- slots: {
15
- indicator: "origin-center",
16
- label: "absolute inset-0 flex items-center justify-center text-xs font-medium",
17
- root: "relative inline-flex items-center justify-center",
18
- svg: "size-full",
19
- track: "origin-center"
20
- },
21
- variants: {
22
- size: {
23
- sm: { label: "text-[0.625rem]" },
24
- md: { label: "text-xs" },
25
- lg: { label: "text-sm" },
26
- xl: { label: "text-base" },
27
- "2xl": { label: "text-lg" }
28
- },
29
- thickness: {
30
- regular: {},
31
- thick: {},
32
- thin: {}
33
- },
34
- variant: {
35
- default: {
36
- indicator: "text-primary",
37
- track: "text-primary/20"
38
- },
39
- destructive: {
40
- indicator: "text-destructive",
41
- track: "text-destructive/20"
42
- }
43
- }
44
- }
11
+ defaultVariants: { size: "md", thickness: "regular", variant: "default" },
12
+ slots: {
13
+ indicator: "origin-center",
14
+ label: "absolute inset-0 flex items-center justify-center text-xs font-medium",
15
+ root: "relative inline-flex items-center justify-center",
16
+ svg: "size-full",
17
+ track: "origin-center",
18
+ },
19
+ variants: {
20
+ size: {
21
+ sm: { label: "text-[0.625rem]" },
22
+ md: { label: "text-xs" },
23
+ lg: { label: "text-sm" },
24
+ xl: { label: "text-base" },
25
+ "2xl": { label: "text-lg" },
26
+ },
27
+ thickness: { regular: {}, thick: {}, thin: {} },
28
+ variant: {
29
+ default: { indicator: "text-primary", track: "text-primary/20" },
30
+ destructive: { indicator: "text-destructive", track: "text-destructive/20" },
31
+ },
32
+ },
45
33
  });
46
- function ProgressCircle({ animate = true, animationDuration = 1e3, className, classNames, customLabel, showValue = false, size, sizeInPixels, strokeWidth, thickness = "regular", value = 0, variant = "default", ...props }) {
47
- const displayValue = useAnimatedValue(value, animationDuration, animate);
48
- const actualSize = useMemo(() => sizeInPixels ?? getActualSize(size), [sizeInPixels, size]);
49
- const actualThickness = useMemo(() => strokeWidth ?? getStrokeWidth(thickness, actualSize), [
50
- strokeWidth,
51
- thickness,
52
- actualSize
53
- ]);
54
- const slots = useMemo(() => progressCircleVariants({
55
- size,
56
- thickness,
57
- variant
58
- }), [
59
- variant,
60
- size,
61
- thickness
62
- ]);
63
- const shouldShowLabel = showValue || Boolean(customLabel);
64
- const renderLabel = useCallback(() => {
65
- if (customLabel) return customLabel({ value: displayValue });
66
- return `${displayValue.toString()}%`;
67
- }, [customLabel, displayValue]);
68
- return /* @__PURE__ */ jsx(ProgressCircleProvider, {
69
- size: actualSize,
70
- strokeWidth: actualThickness,
71
- value,
72
- ...props,
73
- children: /* @__PURE__ */ jsxs(ProgressCircle$1, {
74
- className: slots.root({ className: [className, classNames?.root] }),
75
- children: [/* @__PURE__ */ jsxs(ProgressCircleSVG, {
76
- className: slots.svg({ className: classNames?.svg }),
77
- children: [/* @__PURE__ */ jsx(ProgressCircleTrack, { className: slots.track({ className: classNames?.track }) }), /* @__PURE__ */ jsx(ProgressCircleIndicator, {
78
- className: slots.indicator({ className: classNames?.indicator }),
79
- style: {
80
- transitionDuration: `${animationDuration.toString()}ms`,
81
- transitionProperty: "stroke-dashoffset"
82
- }
83
- })]
84
- }), shouldShowLabel ? /* @__PURE__ */ jsx(ProgressCircleValue, {
85
- className: slots.label({ className: classNames?.label }),
86
- children: renderLabel()
87
- }) : null]
88
- })
89
- });
34
+ function ProgressCircle({ animate = true, animationDuration = 1000, className, classNames, customLabel, showValue = false, size, sizeInPixels, strokeWidth, thickness = "regular", value = 0, variant = "default", ...props }) {
35
+ const displayValue = useAnimatedValue(value, animationDuration, animate);
36
+ const actualSize = useMemo(() => sizeInPixels ?? getActualSize(size), [sizeInPixels, size]);
37
+ const actualThickness = useMemo(() => strokeWidth ?? getStrokeWidth(thickness, actualSize), [strokeWidth, thickness, actualSize]);
38
+ const slots = useMemo(() => progressCircleVariants({ size, thickness, variant }), [variant, size, thickness]);
39
+ const shouldShowLabel = showValue || Boolean(customLabel);
40
+ const renderLabel = useCallback(() => {
41
+ if (customLabel) {
42
+ return customLabel({ value: displayValue });
43
+ }
44
+ return `${displayValue.toString()}%`;
45
+ }, [customLabel, displayValue]);
46
+ return (_jsx(ProgressCirclePrimitive.Provider, { size: actualSize, strokeWidth: actualThickness, value: value, ...props, children: _jsxs(ProgressCirclePrimitive.Root, { className: slots.root({ className: [className, classNames?.root] }), children: [_jsxs(ProgressCirclePrimitive.SVG, { className: slots.svg({ className: classNames?.svg }), children: [_jsx(ProgressCirclePrimitive.Track, { className: slots.track({ className: classNames?.track }) }), _jsx(ProgressCirclePrimitive.Indicator, { className: slots.indicator({ className: classNames?.indicator }), style: {
47
+ transitionDuration: `${animationDuration.toString()}ms`,
48
+ transitionProperty: "stroke-dashoffset",
49
+ } })] }), shouldShowLabel ? (_jsx(ProgressCirclePrimitive.Value, { className: slots.label({ className: classNames?.label }), children: renderLabel() })) : null] }) }));
90
50
  }
91
51
  ProgressCircle.displayName = "ProgressCircle";
52
+ /* -----------------------------------------------------------------------------
53
+ * Helpers
54
+ * -------------------------------------------------------------------------- */
92
55
  /**
93
- * Maps size variants to actual pixel sizes
94
- */
56
+ * Maps size variants to actual pixel sizes
57
+ */
95
58
  const getActualSize = (size) => {
96
- return size ? {
97
- "2xl": 128,
98
- lg: 64,
99
- md: 48,
100
- sm: 32,
101
- xl: 96
102
- }[size] : 48;
59
+ const sizeMap = {
60
+ "2xl": 128,
61
+ lg: 64,
62
+ md: 48,
63
+ sm: 32,
64
+ xl: 96,
65
+ };
66
+ return size ? sizeMap[size] : 48;
103
67
  };
104
68
  /**
105
- * Calculates stroke width based on thickness variant and circle size
106
- */
69
+ * Calculates stroke width based on thickness variant and circle size
70
+ */
107
71
  const getStrokeWidth = (thickness, size) => {
108
- const thicknessMap = {
109
- regular: Math.max(3, size * .05),
110
- thick: Math.max(4, size * .075),
111
- thin: Math.max(2, size * .025)
112
- };
113
- return thickness ? thicknessMap[thickness] : Math.max(3, size * .05);
72
+ const thicknessMap = {
73
+ regular: Math.max(3, size * 0.05),
74
+ thick: Math.max(4, size * 0.075),
75
+ thin: Math.max(2, size * 0.025),
76
+ };
77
+ return thickness ? thicknessMap[thickness] : Math.max(3, size * 0.05);
114
78
  };
115
- //#endregion
116
- export { ProgressCircle, progressCircleVariants };
79
+ /* -----------------------------------------------------------------------------
80
+ * Exports
81
+ * -------------------------------------------------------------------------- */
82
+ export { progressCircleVariants };
83
+ export { ProgressCircle };
@@ -1,12 +1,7 @@
1
- import { ComponentProps, JSX } from "react";
1
+ import type { ComponentProps, JSX } from "react";
2
2
  import * as ProgressPrimitive from "@radix-ui/react-progress";
3
-
4
- //#region src/components/progress.d.ts
5
3
  type ProgressProps = ComponentProps<typeof ProgressPrimitive.Root>;
6
- declare function Progress({
7
- className,
8
- value,
9
- ...props
10
- }: ProgressProps): JSX.Element;
11
- //#endregion
12
- export { Progress, type ProgressProps };
4
+ declare function Progress({ className, value, ...props }: ProgressProps): JSX.Element;
5
+ export { Progress };
6
+ export type { ProgressProps };
7
+ //# sourceMappingURL=progress.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"progress.d.ts","sourceRoot":"","sources":["../../src/components/progress.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAGjD,OAAO,KAAK,iBAAiB,MAAM,0BAA0B,CAAC;AAM9D,KAAK,aAAa,GAAG,cAAc,CAAC,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAC;AAEnE,iBAAS,QAAQ,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,aAAa,GAAG,GAAG,CAAC,OAAO,CAgB5E;AAMD,OAAO,EAAE,QAAQ,EAAE,CAAC;AACpB,YAAY,EAAE,aAAa,EAAE,CAAC"}
@@ -1,19 +1,13 @@
1
1
  "use client";
2
+ import { jsx as _jsx } from "react/jsx-runtime";
2
3
  import { cn } from "@codefast/tailwind-variants";
3
- import { jsx } from "react/jsx-runtime";
4
4
  import * as ProgressPrimitive from "@radix-ui/react-progress";
5
- //#region src/components/progress.tsx
6
5
  function Progress({ className, value, ...props }) {
7
- return /* @__PURE__ */ jsx(ProgressPrimitive.Root, {
8
- className: cn("relative h-2 w-full overflow-hidden rounded-full bg-primary/20", className),
9
- "data-slot": "progress",
10
- ...props,
11
- children: /* @__PURE__ */ jsx(ProgressPrimitive.Indicator, {
12
- className: "size-full flex-1 bg-primary transition-all",
13
- "data-slot": "progress-indicator",
14
- style: { transform: `translateX(-${(100 - (value ?? 0)).toString()}%)` }
15
- })
16
- });
6
+ return (_jsx(ProgressPrimitive.Root, { className: cn("relative h-2 w-full overflow-hidden rounded-full bg-primary/20", className), "data-slot": "progress", ...props, children: _jsx(ProgressPrimitive.Indicator, { className: "size-full flex-1 bg-primary transition-all", "data-slot": "progress-indicator", style: {
7
+ transform: `translateX(-${(100 - (value ?? 0)).toString()}%)`,
8
+ } }) }));
17
9
  }
18
- //#endregion
10
+ /* -----------------------------------------------------------------------------
11
+ * Exports
12
+ * -------------------------------------------------------------------------- */
19
13
  export { Progress };
@@ -1,14 +1,9 @@
1
- import { ComponentProps, JSX } from "react";
1
+ import type { ComponentProps, JSX } from "react";
2
2
  import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
3
-
4
- //#region src/components/radio-cards.d.ts
5
3
  type RadioCardsProps = ComponentProps<typeof RadioGroupPrimitive.Root>;
6
4
  declare function RadioCards(props: RadioCardsProps): JSX.Element;
7
5
  type RadioCardsItemProps = ComponentProps<typeof RadioGroupPrimitive.Item>;
8
- declare function RadioCardsItem({
9
- children,
10
- className,
11
- ...props
12
- }: RadioCardsItemProps): JSX.Element;
13
- //#endregion
14
- export { RadioCards, RadioCardsItem, type RadioCardsItemProps, type RadioCardsProps };
6
+ declare function RadioCardsItem({ children, className, ...props }: RadioCardsItemProps): JSX.Element;
7
+ export { RadioCards, RadioCardsItem };
8
+ export type { RadioCardsItemProps, RadioCardsProps };
9
+ //# sourceMappingURL=radio-cards.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"radio-cards.d.ts","sourceRoot":"","sources":["../../src/components/radio-cards.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAGjD,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAQnE,KAAK,eAAe,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,CAAC;AAEvE,iBAAS,UAAU,CAAC,KAAK,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAEvD;AAMD,KAAK,mBAAmB,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,CAAC;AAE3E,iBAAS,cAAc,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,mBAAmB,GAAG,GAAG,CAAC,OAAO,CAsB3F;AAMD,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,CAAC;AACtC,YAAY,EAAE,mBAAmB,EAAE,eAAe,EAAE,CAAC"}
@@ -1,29 +1,15 @@
1
1
  "use client";
2
- import { Label } from "./label.js";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import { cn } from "@codefast/tailwind-variants";
4
- import { jsx, jsxs } from "react/jsx-runtime";
5
4
  import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
6
- //#region src/components/radio-cards.tsx
5
+ import { Label } from "#components/label";
7
6
  function RadioCards(props) {
8
- return /* @__PURE__ */ jsx(RadioGroupPrimitive.Root, {
9
- "data-slot": "radio-cards",
10
- ...props
11
- });
7
+ return _jsx(RadioGroupPrimitive.Root, { "data-slot": "radio-cards", ...props });
12
8
  }
13
9
  function RadioCardsItem({ children, className, ...props }) {
14
- return /* @__PURE__ */ jsxs(Label, {
15
- className: "flex items-start gap-3 rounded-lg border border-input p-3 transition hover:not-has-disabled:not-has-aria-checked:bg-secondary has-focus-visible:border-ring has-disabled:opacity-50 has-aria-checked:border-primary has-aria-checked:bg-primary/10",
16
- "data-slot": "radio-card",
17
- children: [/* @__PURE__ */ jsx(RadioGroupPrimitive.Item, {
18
- className: cn("peer flex size-4 shrink-0 items-center justify-center rounded-full border border-input text-primary-foreground shadow-xs outline-hidden transition focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:not-aria-checked:border-ring aria-checked:border-primary aria-checked:bg-primary focus-visible:aria-checked:ring-primary/20 dark:bg-input/30 dark:focus-visible:aria-checked:ring-primary/40", className),
19
- "data-slot": "radio-card-item",
20
- ...props,
21
- children: /* @__PURE__ */ jsx(RadioGroupPrimitive.Indicator, {
22
- className: "size-1 rounded-full bg-background",
23
- "data-slot": "radio-card-indicator"
24
- })
25
- }), children]
26
- });
10
+ return (_jsxs(Label, { className: "flex items-start gap-3 rounded-lg border border-input p-3 transition hover:not-has-disabled:not-has-aria-checked:bg-secondary has-focus-visible:border-ring has-disabled:opacity-50 has-aria-checked:border-primary has-aria-checked:bg-primary/10", "data-slot": "radio-card", children: [_jsx(RadioGroupPrimitive.Item, { className: cn("peer flex size-4 shrink-0 items-center justify-center rounded-full border border-input text-primary-foreground shadow-xs outline-hidden transition focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:not-aria-checked:border-ring aria-checked:border-primary aria-checked:bg-primary focus-visible:aria-checked:ring-primary/20 dark:bg-input/30 dark:focus-visible:aria-checked:ring-primary/40", className), "data-slot": "radio-card-item", ...props, children: _jsx(RadioGroupPrimitive.Indicator, { className: "size-1 rounded-full bg-background", "data-slot": "radio-card-indicator" }) }), children] }));
27
11
  }
28
- //#endregion
12
+ /* -----------------------------------------------------------------------------
13
+ * Exports
14
+ * -------------------------------------------------------------------------- */
29
15
  export { RadioCards, RadioCardsItem };
@@ -1,16 +1,9 @@
1
- import { ComponentProps, JSX } from "react";
1
+ import type { ComponentProps, JSX } from "react";
2
2
  import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
3
-
4
- //#region src/components/radio-group.d.ts
5
3
  type RadioGroupProps = ComponentProps<typeof RadioGroupPrimitive.Root>;
6
- declare function RadioGroup({
7
- className,
8
- ...props
9
- }: RadioGroupProps): JSX.Element;
4
+ declare function RadioGroup({ className, ...props }: RadioGroupProps): JSX.Element;
10
5
  type RadioGroupItemProps = ComponentProps<typeof RadioGroupPrimitive.Item>;
11
- declare function RadioGroupItem({
12
- className,
13
- ...props
14
- }: RadioGroupItemProps): JSX.Element;
15
- //#endregion
16
- export { RadioGroup, RadioGroupItem, type RadioGroupItemProps, type RadioGroupProps };
6
+ declare function RadioGroupItem({ className, ...props }: RadioGroupItemProps): JSX.Element;
7
+ export { RadioGroup, RadioGroupItem };
8
+ export type { RadioGroupItemProps, RadioGroupProps };
9
+ //# sourceMappingURL=radio-group.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"radio-group.d.ts","sourceRoot":"","sources":["../../src/components/radio-group.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAGjD,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAMnE,KAAK,eAAe,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,CAAC;AAEvE,iBAAS,UAAU,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAQzE;AAMD,KAAK,mBAAmB,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,CAAC;AAE3E,iBAAS,cAAc,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,mBAAmB,GAAG,GAAG,CAAC,OAAO,CAgBjF;AAMD,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,CAAC;AACtC,YAAY,EAAE,mBAAmB,EAAE,eAAe,EAAE,CAAC"}
@@ -1,25 +1,14 @@
1
1
  "use client";
2
+ import { jsx as _jsx } from "react/jsx-runtime";
2
3
  import { cn } from "@codefast/tailwind-variants";
3
- import { jsx } from "react/jsx-runtime";
4
4
  import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
5
- //#region src/components/radio-group.tsx
6
5
  function RadioGroup({ className, ...props }) {
7
- return /* @__PURE__ */ jsx(RadioGroupPrimitive.Root, {
8
- className: cn("grid gap-2", className),
9
- "data-slot": "radio-group",
10
- ...props
11
- });
6
+ return (_jsx(RadioGroupPrimitive.Root, { className: cn("grid gap-2", className), "data-slot": "radio-group", ...props }));
12
7
  }
13
8
  function RadioGroupItem({ className, ...props }) {
14
- return /* @__PURE__ */ jsx(RadioGroupPrimitive.Item, {
15
- className: cn("peer inline-flex size-4 shrink-0 items-center justify-center rounded-full border border-input shadow-xs outline-hidden transition hover:not-disabled:not-aria-checked:border-ring/60 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:opacity-50 aria-checked:border-primary aria-checked:bg-primary focus-visible:aria-checked:ring-primary/20 aria-invalid:border-destructive aria-invalid:ring-destructive/20 hover:not-disabled:not-aria-checked:aria-invalid:border-destructive/60 aria-checked:aria-invalid:bg-destructive dark:bg-input/30 dark:focus-visible:aria-checked:ring-primary/40 dark:aria-invalid:ring-destructive/40", className),
16
- "data-slot": "radio-group-item",
17
- ...props,
18
- children: /* @__PURE__ */ jsx(RadioGroupPrimitive.Indicator, {
19
- className: "size-1 rounded-full bg-background",
20
- "data-slot": "radio-group-indicator"
21
- })
22
- });
9
+ return (_jsx(RadioGroupPrimitive.Item, { className: cn("peer inline-flex size-4 shrink-0 items-center justify-center rounded-full border border-input shadow-xs outline-hidden transition hover:not-disabled:not-aria-checked:border-ring/60 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:opacity-50 aria-checked:border-primary aria-checked:bg-primary focus-visible:aria-checked:ring-primary/20 aria-invalid:border-destructive aria-invalid:ring-destructive/20 hover:not-disabled:not-aria-checked:aria-invalid:border-destructive/60 aria-checked:aria-invalid:bg-destructive dark:bg-input/30 dark:focus-visible:aria-checked:ring-primary/40 dark:aria-invalid:ring-destructive/40", className), "data-slot": "radio-group-item", ...props, children: _jsx(RadioGroupPrimitive.Indicator, { className: "size-1 rounded-full bg-background", "data-slot": "radio-group-indicator" }) }));
23
10
  }
24
- //#endregion
11
+ /* -----------------------------------------------------------------------------
12
+ * Exports
13
+ * -------------------------------------------------------------------------- */
25
14
  export { RadioGroup, RadioGroupItem };
@@ -1,14 +1,8 @@
1
- import { ComponentProps, JSX } from "react";
2
-
3
- //#region src/components/radio.d.ts
1
+ import type { ComponentProps, JSX } from "react";
4
2
  interface RadioProps extends Omit<ComponentProps<"input">, "type"> {
5
- onValueChange?: (value: string) => void;
3
+ onValueChange?: (value: string) => void;
6
4
  }
7
- declare function Radio({
8
- className,
9
- onChange,
10
- onValueChange,
11
- ...props
12
- }: RadioProps): JSX.Element;
13
- //#endregion
14
- export { Radio, type RadioProps };
5
+ declare function Radio({ className, onChange, onValueChange, ...props }: RadioProps): JSX.Element;
6
+ export { Radio };
7
+ export type { RadioProps };
8
+ //# sourceMappingURL=radio.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"radio.d.ts","sourceRoot":"","sources":["../../src/components/radio.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AASjD,UAAU,UAAW,SAAQ,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAChE,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACzC;AAED,iBAAS,KAAK,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,aAAa,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,GAAG,GAAG,CAAC,OAAO,CAexF;AAMD,OAAO,EAAE,KAAK,EAAE,CAAC;AACjB,YAAY,EAAE,UAAU,EAAE,CAAC"}
@@ -1,16 +1,11 @@
1
1
  "use client";
2
+ import { jsx as _jsx } from "react/jsx-runtime";
2
3
  import { cn } from "@codefast/tailwind-variants";
3
- import { jsx } from "react/jsx-runtime";
4
4
  import { composeEventHandlers } from "@radix-ui/primitive";
5
- //#region src/components/radio.tsx
6
5
  function Radio({ className, onChange, onValueChange, ...props }) {
7
- return /* @__PURE__ */ jsx("input", {
8
- className: cn("peer inline-flex size-4 shrink-0 appearance-none items-center justify-center rounded-full border border-input shadow-xs outline-hidden after:size-full after:rounded-full after:bg-background after:transition-[width,height] checked:border-primary checked:bg-primary checked:after:size-1 hover:not-disabled:not-checked:border-ring/60 focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:not-checked:border-ring focus-visible:checked:ring-primary/20 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 checked:aria-invalid:bg-destructive hover:not-disabled:not-checked:aria-invalid:border-destructive/60 dark:not-checked:after:bg-input/30 dark:focus-visible:checked:ring-primary/40 dark:aria-invalid:ring-destructive/40", className),
9
- "data-slot": "radio",
10
- type: "radio",
11
- onChange: composeEventHandlers(onChange, (event) => onValueChange?.(event.currentTarget.value)),
12
- ...props
13
- });
6
+ return (_jsx("input", { className: cn("peer inline-flex size-4 shrink-0 appearance-none items-center justify-center rounded-full border border-input shadow-xs outline-hidden after:size-full after:rounded-full after:bg-background after:transition-[width,height] checked:border-primary checked:bg-primary checked:after:size-1 hover:not-disabled:not-checked:border-ring/60 focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:not-checked:border-ring focus-visible:checked:ring-primary/20 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 checked:aria-invalid:bg-destructive hover:not-disabled:not-checked:aria-invalid:border-destructive/60 dark:not-checked:after:bg-input/30 dark:focus-visible:checked:ring-primary/40 dark:aria-invalid:ring-destructive/40", className), "data-slot": "radio", type: "radio", onChange: composeEventHandlers(onChange, (event) => onValueChange?.(event.currentTarget.value)), ...props }));
14
7
  }
15
- //#endregion
8
+ /* -----------------------------------------------------------------------------
9
+ * Exports
10
+ * -------------------------------------------------------------------------- */
16
11
  export { Radio };
@@ -1,23 +1,13 @@
1
- import { ComponentProps, JSX } from "react";
1
+ import type { ComponentProps, JSX } from "react";
2
2
  import * as ResizablePrimitive from "react-resizable-panels";
3
-
4
- //#region src/components/resizable.d.ts
5
3
  type ResizableGroupProps = ComponentProps<typeof ResizablePrimitive.Group>;
6
- declare function ResizableGroup({
7
- className,
8
- ...props
9
- }: ResizableGroupProps): JSX.Element;
4
+ declare function ResizableGroup({ className, ...props }: ResizableGroupProps): JSX.Element;
10
5
  type ResizablePanelProps = ComponentProps<typeof ResizablePrimitive.Panel>;
11
- declare function ResizablePanel({
12
- ...props
13
- }: ResizablePanelProps): JSX.Element;
6
+ declare function ResizablePanel({ ...props }: ResizablePanelProps): JSX.Element;
14
7
  interface ResizableSeparatorProps extends ComponentProps<typeof ResizablePrimitive.Separator> {
15
- withHandle?: boolean;
8
+ withHandle?: boolean;
16
9
  }
17
- declare function ResizableSeparator({
18
- className,
19
- withHandle,
20
- ...props
21
- }: ResizableSeparatorProps): JSX.Element;
22
- //#endregion
23
- export { ResizableGroup, type ResizableGroupProps, ResizablePanel, type ResizablePanelProps, ResizableSeparator, type ResizableSeparatorProps };
10
+ declare function ResizableSeparator({ className, withHandle, ...props }: ResizableSeparatorProps): JSX.Element;
11
+ export { ResizableGroup, ResizablePanel, ResizableSeparator };
12
+ export type { ResizableGroupProps, ResizablePanelProps, ResizableSeparatorProps };
13
+ //# sourceMappingURL=resizable.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resizable.d.ts","sourceRoot":"","sources":["../../src/components/resizable.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAIjD,OAAO,KAAK,kBAAkB,MAAM,wBAAwB,CAAC;AAM7D,KAAK,mBAAmB,GAAG,cAAc,CAAC,OAAO,kBAAkB,CAAC,KAAK,CAAC,CAAC;AAE3E,iBAAS,cAAc,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,mBAAmB,GAAG,GAAG,CAAC,OAAO,CAQjF;AAMD,KAAK,mBAAmB,GAAG,cAAc,CAAC,OAAO,kBAAkB,CAAC,KAAK,CAAC,CAAC;AAE3E,iBAAS,cAAc,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,mBAAmB,GAAG,GAAG,CAAC,OAAO,CAEtE;AAMD,UAAU,uBAAwB,SAAQ,cAAc,CAAC,OAAO,kBAAkB,CAAC,SAAS,CAAC;IAC3F,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,iBAAS,kBAAkB,CAAC,EAC1B,SAAS,EACT,UAAU,EACV,GAAG,KAAK,EACT,EAAE,uBAAuB,GAAG,GAAG,CAAC,OAAO,CAmBvC;AAMD,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,kBAAkB,EAAE,CAAC;AAC9D,YAAY,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,CAAC"}
@@ -1,32 +1,18 @@
1
1
  "use client";
2
+ import { jsx as _jsx } from "react/jsx-runtime";
2
3
  import { cn } from "@codefast/tailwind-variants";
3
4
  import { GripVerticalIcon } from "lucide-react";
4
- import { jsx } from "react/jsx-runtime";
5
5
  import * as ResizablePrimitive from "react-resizable-panels";
6
- //#region src/components/resizable.tsx
7
6
  function ResizableGroup({ className, ...props }) {
8
- return /* @__PURE__ */ jsx(ResizablePrimitive.Group, {
9
- className: cn("flex size-full", className),
10
- "data-slot": "resizable-group",
11
- ...props
12
- });
7
+ return (_jsx(ResizablePrimitive.Group, { className: cn("flex size-full", className), "data-slot": "resizable-group", ...props }));
13
8
  }
14
9
  function ResizablePanel({ ...props }) {
15
- return /* @__PURE__ */ jsx(ResizablePrimitive.Panel, {
16
- "data-slot": "resizable-panel",
17
- ...props
18
- });
10
+ return _jsx(ResizablePrimitive.Panel, { "data-slot": "resizable-panel", ...props });
19
11
  }
20
12
  function ResizableSeparator({ className, withHandle, ...props }) {
21
- return /* @__PURE__ */ jsx(ResizablePrimitive.Separator, {
22
- className: cn("flex items-center justify-center bg-border outline-hidden focus-visible:bg-ring focus-visible:ring-3 focus-visible:ring-ring/50", "aria-[orientation=vertical]:w-px", "aria-[orientation=horizontal]:h-px", className),
23
- "data-slot": "resizable-separator",
24
- ...props,
25
- children: withHandle ? /* @__PURE__ */ jsx("div", {
26
- className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border",
27
- children: /* @__PURE__ */ jsx(GripVerticalIcon, { className: "size-2.5" })
28
- }) : null
29
- });
13
+ return (_jsx(ResizablePrimitive.Separator, { className: cn("flex items-center justify-center bg-border outline-hidden focus-visible:bg-ring focus-visible:ring-3 focus-visible:ring-ring/50", "aria-[orientation=vertical]:w-px", "aria-[orientation=horizontal]:h-px", className), "data-slot": "resizable-separator", ...props, children: withHandle ? (_jsx("div", { className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border", children: _jsx(GripVerticalIcon, { className: "size-2.5" }) })) : null }));
30
14
  }
31
- //#endregion
15
+ /* -----------------------------------------------------------------------------
16
+ * Exports
17
+ * -------------------------------------------------------------------------- */
32
18
  export { ResizableGroup, ResizablePanel, ResizableSeparator };
@@ -1,40 +1,28 @@
1
- import * as _$_codefast_tailwind_variants0 from "@codefast/tailwind-variants";
2
- import { VariantProps } from "@codefast/tailwind-variants";
3
- import { ComponentProps, JSX } from "react";
4
- import { Scope } from "@radix-ui/react-context";
1
+ import type { VariantProps } from "@codefast/tailwind-variants";
2
+ import type { Scope } from "@radix-ui/react-context";
3
+ import type { ComponentProps, JSX } from "react";
5
4
  import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
6
-
7
- //#region src/components/scroll-area.d.ts
8
- declare const scrollAreaScrollbarVariants: _$_codefast_tailwind_variants0.VariantFunctionType<{
9
- orientation: {
10
- horizontal: string;
11
- vertical: string;
12
- };
13
- size: {
14
- none: string;
15
- sm: string;
16
- md: string;
17
- lg: string;
18
- };
5
+ declare const scrollAreaScrollbarVariants: import("@codefast/tailwind-variants").VariantFunctionType<{
6
+ orientation: {
7
+ horizontal: string;
8
+ vertical: string;
9
+ };
10
+ size: {
11
+ none: string;
12
+ sm: string;
13
+ md: string;
14
+ lg: string;
15
+ };
19
16
  }, Record<string, never>>;
20
17
  type ScopedProps<P> = P & {
21
- __scopeScrollArea?: Scope;
18
+ __scopeScrollArea?: Scope;
22
19
  };
23
20
  type ScrollAreaContextValue = Pick<VariantProps<typeof scrollAreaScrollbarVariants>, "size">;
24
21
  type ScrollAreaProps = ScopedProps<ComponentProps<typeof ScrollAreaPrimitive.Root> & ScrollAreaContextValue>;
25
- declare function ScrollArea({
26
- __scopeScrollArea,
27
- children,
28
- className,
29
- size,
30
- ...props
31
- }: ScrollAreaProps): JSX.Element;
22
+ declare function ScrollArea({ __scopeScrollArea, children, className, size, ...props }: ScrollAreaProps): JSX.Element;
32
23
  type ScrollAreaScrollbarProps = ScopedProps<ComponentProps<typeof ScrollAreaPrimitive.Scrollbar>>;
33
- declare function ScrollAreaScrollbar({
34
- __scopeScrollArea,
35
- className,
36
- orientation,
37
- ...props
38
- }: ScrollAreaScrollbarProps): JSX.Element;
39
- //#endregion
40
- export { ScrollArea, type ScrollAreaProps, ScrollAreaScrollbar, type ScrollAreaScrollbarProps, scrollAreaScrollbarVariants };
24
+ declare function ScrollAreaScrollbar({ __scopeScrollArea, className, orientation, ...props }: ScrollAreaScrollbarProps): JSX.Element;
25
+ export { scrollAreaScrollbarVariants };
26
+ export { ScrollArea, ScrollAreaScrollbar };
27
+ export type { ScrollAreaProps, ScrollAreaScrollbarProps };
28
+ //# sourceMappingURL=scroll-area.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scroll-area.d.ts","sourceRoot":"","sources":["../../src/components/scroll-area.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAIjD,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAMnE,QAAA,MAAM,2BAA2B;;;;;;;;;;;yBAqD/B,CAAC;AAQH,KAAK,WAAW,CAAC,CAAC,IAAI,CAAC,GAAG;IAAE,iBAAiB,CAAC,EAAE,KAAK,CAAA;CAAE,CAAC;AAIxD,KAAK,sBAAsB,GAAG,IAAI,CAAC,YAAY,CAAC,OAAO,2BAA2B,CAAC,EAAE,MAAM,CAAC,CAAC;AAS7F,KAAK,eAAe,GAAG,WAAW,CAChC,cAAc,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,GAAG,sBAAsB,CACzE,CAAC;AAEF,iBAAS,UAAU,CAAC,EAClB,iBAAiB,EACjB,QAAQ,EACR,SAAS,EACT,IAAI,EACJ,GAAG,KAAK,EACT,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAoB/B;AAMD,KAAK,wBAAwB,GAAG,WAAW,CAAC,cAAc,CAAC,OAAO,mBAAmB,CAAC,SAAS,CAAC,CAAC,CAAC;AAElG,iBAAS,mBAAmB,CAAC,EAC3B,iBAAiB,EACjB,SAAS,EACT,WAAW,EACX,GAAG,KAAK,EACT,EAAE,wBAAwB,GAAG,GAAG,CAAC,OAAO,CAaxC;AAMD,OAAO,EAAE,2BAA2B,EAAE,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,mBAAmB,EAAE,CAAC;AAC3C,YAAY,EAAE,eAAe,EAAE,wBAAwB,EAAE,CAAC"}