@arolariu/components 0.5.0 → 1.0.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 (892) hide show
  1. package/{changelog.md → CHANGELOG.md} +25 -0
  2. package/CONTRIBUTING.md +344 -265
  3. package/DEBUGGING.md +185 -103
  4. package/EXAMPLES.md +470 -345
  5. package/{readme.md → README.md} +306 -203
  6. package/dist/components/ui/accordion.d.ts +157 -5
  7. package/dist/components/ui/accordion.d.ts.map +1 -1
  8. package/dist/components/ui/accordion.js +100 -22
  9. package/dist/components/ui/accordion.js.map +1 -1
  10. package/dist/components/ui/accordion.module.js +12 -0
  11. package/dist/components/ui/accordion.module.js.map +1 -0
  12. package/dist/components/ui/accordion_module.css +72 -0
  13. package/dist/components/ui/accordion_module.css.map +1 -0
  14. package/dist/components/ui/alert-dialog.d.ts +321 -18
  15. package/dist/components/ui/alert-dialog.d.ts.map +1 -1
  16. package/dist/components/ui/alert-dialog.js +145 -52
  17. package/dist/components/ui/alert-dialog.js.map +1 -1
  18. package/dist/components/ui/alert-dialog.module.js +13 -0
  19. package/dist/components/ui/alert-dialog.module.js.map +1 -0
  20. package/dist/components/ui/alert-dialog_module.css +89 -0
  21. package/dist/components/ui/alert-dialog_module.css.map +1 -0
  22. package/dist/components/ui/alert.d.ts +109 -6
  23. package/dist/components/ui/alert.d.ts.map +1 -1
  24. package/dist/components/ui/alert.js +12 -21
  25. package/dist/components/ui/alert.js.map +1 -1
  26. package/dist/components/ui/alert.module.js +11 -0
  27. package/dist/components/ui/alert.module.js.map +1 -0
  28. package/dist/components/ui/alert_module.css +59 -0
  29. package/dist/components/ui/alert_module.css.map +1 -0
  30. package/dist/components/ui/aspect-ratio.d.ts +24 -2
  31. package/dist/components/ui/aspect-ratio.d.ts.map +1 -1
  32. package/dist/components/ui/aspect-ratio.js +14 -3
  33. package/dist/components/ui/aspect-ratio.js.map +1 -1
  34. package/dist/components/ui/aspect-ratio.module.js +7 -0
  35. package/dist/components/ui/aspect-ratio.module.js.map +1 -0
  36. package/dist/components/ui/aspect-ratio_module.css +10 -0
  37. package/dist/components/ui/aspect-ratio_module.css.map +1 -0
  38. package/dist/components/ui/async-boundary.js +17 -0
  39. package/dist/components/ui/async-boundary.js.map +1 -0
  40. package/dist/components/ui/avatar.d.ts +97 -4
  41. package/dist/components/ui/avatar.d.ts.map +1 -1
  42. package/dist/components/ui/avatar.js +50 -21
  43. package/dist/components/ui/avatar.js.map +1 -1
  44. package/dist/components/ui/avatar.module.js +9 -0
  45. package/dist/components/ui/avatar.module.js.map +1 -0
  46. package/dist/components/ui/avatar_module.css +35 -0
  47. package/dist/components/ui/avatar_module.css.map +1 -0
  48. package/dist/components/ui/background-beams.d.ts +21 -3
  49. package/dist/components/ui/background-beams.d.ts.map +1 -1
  50. package/dist/components/ui/background-beams.js +22 -11
  51. package/dist/components/ui/background-beams.js.map +1 -1
  52. package/dist/components/ui/background-beams.module.js +8 -0
  53. package/dist/components/ui/background-beams.module.js.map +1 -0
  54. package/dist/components/ui/background-beams_module.css +22 -0
  55. package/dist/components/ui/background-beams_module.css.map +1 -0
  56. package/dist/components/ui/badge.d.ts +79 -6
  57. package/dist/components/ui/badge.d.ts.map +1 -1
  58. package/dist/components/ui/badge.js +19 -23
  59. package/dist/components/ui/badge.js.map +1 -1
  60. package/dist/components/ui/badge.module.js +11 -0
  61. package/dist/components/ui/badge.module.js.map +1 -0
  62. package/dist/components/ui/badge_module.css +63 -0
  63. package/dist/components/ui/badge_module.css.map +1 -0
  64. package/dist/components/ui/breadcrumb.d.ts +158 -13
  65. package/dist/components/ui/breadcrumb.d.ts.map +1 -1
  66. package/dist/components/ui/breadcrumb.js +39 -30
  67. package/dist/components/ui/breadcrumb.js.map +1 -1
  68. package/dist/components/ui/breadcrumb.module.js +14 -0
  69. package/dist/components/ui/breadcrumb.module.js.map +1 -0
  70. package/dist/components/ui/breadcrumb_module.css +90 -0
  71. package/dist/components/ui/breadcrumb_module.css.map +1 -0
  72. package/dist/components/ui/bubble-background.d.ts +38 -10
  73. package/dist/components/ui/bubble-background.d.ts.map +1 -1
  74. package/dist/components/ui/bubble-background.js +33 -35
  75. package/dist/components/ui/bubble-background.js.map +1 -1
  76. package/dist/components/ui/bubble-background.module.js +20 -0
  77. package/dist/components/ui/bubble-background.module.js.map +1 -0
  78. package/dist/components/ui/bubble-background_module.css +99 -0
  79. package/dist/components/ui/bubble-background_module.css.map +1 -0
  80. package/dist/components/ui/button-group.d.ts +88 -8
  81. package/dist/components/ui/button-group.d.ts.map +1 -1
  82. package/dist/components/ui/button-group.js +35 -32
  83. package/dist/components/ui/button-group.js.map +1 -1
  84. package/dist/components/ui/button-group.module.js +11 -0
  85. package/dist/components/ui/button-group.module.js.map +1 -0
  86. package/dist/components/ui/button-group_module.css +79 -0
  87. package/dist/components/ui/button-group_module.css.map +1 -0
  88. package/dist/components/ui/button.d.ts +82 -7
  89. package/dist/components/ui/button.d.ts.map +1 -1
  90. package/dist/components/ui/button.js +69 -34
  91. package/dist/components/ui/button.js.map +1 -1
  92. package/dist/components/ui/button.module.js +17 -0
  93. package/dist/components/ui/button.module.js.map +1 -0
  94. package/dist/components/ui/button_module.css +137 -0
  95. package/dist/components/ui/button_module.css.map +1 -0
  96. package/dist/components/ui/calendar.d.ts +39 -5
  97. package/dist/components/ui/calendar.d.ts.map +1 -1
  98. package/dist/components/ui/calendar.js +72 -61
  99. package/dist/components/ui/calendar.js.map +1 -1
  100. package/dist/components/ui/calendar.module.js +35 -0
  101. package/dist/components/ui/calendar.module.js.map +1 -0
  102. package/dist/components/ui/calendar_module.css +245 -0
  103. package/dist/components/ui/calendar_module.css.map +1 -0
  104. package/dist/components/ui/card-skeleton.js +41 -0
  105. package/dist/components/ui/card-skeleton.js.map +1 -0
  106. package/dist/components/ui/card-skeleton.module.js +15 -0
  107. package/dist/components/ui/card-skeleton.module.js.map +1 -0
  108. package/dist/components/ui/card-skeleton_module.css +54 -0
  109. package/dist/components/ui/card-skeleton_module.css.map +1 -0
  110. package/dist/components/ui/card.d.ts +162 -7
  111. package/dist/components/ui/card.d.ts.map +1 -1
  112. package/dist/components/ui/card.js +13 -13
  113. package/dist/components/ui/card.js.map +1 -1
  114. package/dist/components/ui/card.module.js +13 -0
  115. package/dist/components/ui/card.module.js.map +1 -0
  116. package/dist/components/ui/card_module.css +43 -0
  117. package/dist/components/ui/card_module.css.map +1 -0
  118. package/dist/components/ui/carousel.d.ts +127 -3
  119. package/dist/components/ui/carousel.d.ts.map +1 -1
  120. package/dist/components/ui/carousel.js +63 -36
  121. package/dist/components/ui/carousel.js.map +1 -1
  122. package/dist/components/ui/carousel.module.js +17 -0
  123. package/dist/components/ui/carousel.module.js.map +1 -0
  124. package/dist/components/ui/carousel_module.css +82 -0
  125. package/dist/components/ui/carousel_module.css.map +1 -0
  126. package/dist/components/ui/chart.d.ts +323 -13
  127. package/dist/components/ui/chart.d.ts.map +1 -1
  128. package/dist/components/ui/chart.js +158 -53
  129. package/dist/components/ui/chart.js.map +1 -1
  130. package/dist/components/ui/chart.module.js +27 -0
  131. package/dist/components/ui/chart.module.js.map +1 -0
  132. package/dist/components/ui/chart_module.css +159 -0
  133. package/dist/components/ui/chart_module.css.map +1 -0
  134. package/dist/components/ui/checkbox-group.d.ts +31 -0
  135. package/dist/components/ui/checkbox-group.d.ts.map +1 -0
  136. package/dist/components/ui/checkbox-group.js +25 -0
  137. package/dist/components/ui/checkbox-group.js.map +1 -0
  138. package/dist/components/ui/checkbox-group.module.js +7 -0
  139. package/dist/components/ui/checkbox-group.module.js.map +1 -0
  140. package/dist/components/ui/checkbox-group_module.css +11 -0
  141. package/dist/components/ui/checkbox-group_module.css.map +1 -0
  142. package/dist/components/ui/checkbox.d.ts +33 -2
  143. package/dist/components/ui/checkbox.d.ts.map +1 -1
  144. package/dist/components/ui/checkbox.js +37 -12
  145. package/dist/components/ui/checkbox.js.map +1 -1
  146. package/dist/components/ui/checkbox.module.js +8 -0
  147. package/dist/components/ui/checkbox.module.js.map +1 -0
  148. package/dist/components/ui/checkbox_module.css +45 -0
  149. package/dist/components/ui/checkbox_module.css.map +1 -0
  150. package/dist/components/ui/collapsible.d.ts +87 -3
  151. package/dist/components/ui/collapsible.d.ts.map +1 -1
  152. package/dist/components/ui/collapsible.js +46 -32
  153. package/dist/components/ui/collapsible.js.map +1 -1
  154. package/dist/components/ui/collapsible.module.js +8 -0
  155. package/dist/components/ui/collapsible.module.js.map +1 -0
  156. package/dist/components/ui/collapsible_module.css +26 -0
  157. package/dist/components/ui/collapsible_module.css.map +1 -0
  158. package/dist/components/ui/command.d.ts +284 -51
  159. package/dist/components/ui/command.d.ts.map +1 -1
  160. package/dist/components/ui/command.js +387 -51
  161. package/dist/components/ui/command.js.map +1 -1
  162. package/dist/components/ui/command.module.js +20 -0
  163. package/dist/components/ui/command.module.js.map +1 -0
  164. package/dist/components/ui/command_module.css +194 -0
  165. package/dist/components/ui/command_module.css.map +1 -0
  166. package/dist/components/ui/context-menu.d.ts +414 -21
  167. package/dist/components/ui/context-menu.d.ts.map +1 -1
  168. package/dist/components/ui/context-menu.js +190 -68
  169. package/dist/components/ui/context-menu.js.map +1 -1
  170. package/dist/components/ui/context-menu.module.js +19 -0
  171. package/dist/components/ui/context-menu.module.js.map +1 -0
  172. package/dist/components/ui/context-menu_module.css +114 -0
  173. package/dist/components/ui/context-menu_module.css.map +1 -0
  174. package/dist/components/ui/copy-button.d.ts +41 -0
  175. package/dist/components/ui/copy-button.d.ts.map +1 -0
  176. package/dist/components/ui/copy-button.js +51 -0
  177. package/dist/components/ui/copy-button.js.map +1 -0
  178. package/dist/components/ui/copy-button.module.js +8 -0
  179. package/dist/components/ui/copy-button.module.js.map +1 -0
  180. package/dist/components/ui/copy-button_module.css +37 -0
  181. package/dist/components/ui/copy-button_module.css.map +1 -0
  182. package/dist/components/ui/counting-number.d.ts +28 -2
  183. package/dist/components/ui/counting-number.d.ts.map +1 -1
  184. package/dist/components/ui/counting-number.js +31 -27
  185. package/dist/components/ui/counting-number.js.map +1 -1
  186. package/dist/components/ui/counting-number.module.js +7 -0
  187. package/dist/components/ui/counting-number.module.js.map +1 -0
  188. package/dist/components/ui/counting-number_module.css +7 -0
  189. package/dist/components/ui/counting-number_module.css.map +1 -0
  190. package/dist/components/ui/dialog.d.ts +287 -17
  191. package/dist/components/ui/dialog.d.ts.map +1 -1
  192. package/dist/components/ui/dialog.js +129 -52
  193. package/dist/components/ui/dialog.js.map +1 -1
  194. package/dist/components/ui/dialog.module.js +13 -0
  195. package/dist/components/ui/dialog.module.js.map +1 -0
  196. package/dist/components/ui/dialog_module.css +114 -0
  197. package/dist/components/ui/dialog_module.css.map +1 -0
  198. package/dist/components/ui/dot-background.d.ts +25 -35
  199. package/dist/components/ui/dot-background.d.ts.map +1 -1
  200. package/dist/components/ui/dot-background.js +31 -22
  201. package/dist/components/ui/dot-background.js.map +1 -1
  202. package/dist/components/ui/dot-background.module.js +8 -0
  203. package/dist/components/ui/dot-background.module.js.map +1 -0
  204. package/dist/components/ui/dot-background_module.css +15 -0
  205. package/dist/components/ui/dot-background_module.css.map +1 -0
  206. package/dist/components/ui/drawer.d.ts +287 -18
  207. package/dist/components/ui/drawer.d.ts.map +1 -1
  208. package/dist/components/ui/drawer.js +117 -40
  209. package/dist/components/ui/drawer.js.map +1 -1
  210. package/dist/components/ui/drawer.module.js +14 -0
  211. package/dist/components/ui/drawer.module.js.map +1 -0
  212. package/dist/components/ui/drawer_module.css +86 -0
  213. package/dist/components/ui/drawer_module.css.map +1 -0
  214. package/dist/components/ui/dropdown-menu.d.ts +414 -21
  215. package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
  216. package/dist/components/ui/dropdown-menu.js +189 -68
  217. package/dist/components/ui/dropdown-menu.js.map +1 -1
  218. package/dist/components/ui/dropdown-menu.module.js +19 -0
  219. package/dist/components/ui/dropdown-menu.module.js.map +1 -0
  220. package/dist/components/ui/dropdown-menu_module.css +114 -0
  221. package/dist/components/ui/dropdown-menu_module.css.map +1 -0
  222. package/dist/components/ui/dropdrawer.d.ts +313 -17
  223. package/dist/components/ui/dropdrawer.d.ts.map +1 -1
  224. package/dist/components/ui/dropdrawer.js +423 -159
  225. package/dist/components/ui/dropdrawer.js.map +1 -1
  226. package/dist/components/ui/dropdrawer.module.js +43 -0
  227. package/dist/components/ui/dropdrawer.module.js.map +1 -0
  228. package/dist/components/ui/dropdrawer_module.css +307 -0
  229. package/dist/components/ui/dropdrawer_module.css.map +1 -0
  230. package/dist/components/ui/empty.d.ts +129 -10
  231. package/dist/components/ui/empty.d.ts.map +1 -1
  232. package/dist/components/ui/empty.js +32 -47
  233. package/dist/components/ui/empty.js.map +1 -1
  234. package/dist/components/ui/empty.module.js +13 -0
  235. package/dist/components/ui/empty.module.js.map +1 -0
  236. package/dist/components/ui/empty_module.css +85 -0
  237. package/dist/components/ui/empty_module.css.map +1 -0
  238. package/dist/components/ui/error-boundary.js +61 -0
  239. package/dist/components/ui/error-boundary.js.map +1 -0
  240. package/dist/components/ui/error-boundary.module.js +10 -0
  241. package/dist/components/ui/error-boundary.module.js.map +1 -0
  242. package/dist/components/ui/error-boundary_module.css +41 -0
  243. package/dist/components/ui/error-boundary_module.css.map +1 -0
  244. package/dist/components/ui/field.d.ts +222 -23
  245. package/dist/components/ui/field.d.ts.map +1 -1
  246. package/dist/components/ui/field.js +76 -86
  247. package/dist/components/ui/field.js.map +1 -1
  248. package/dist/components/ui/field.module.js +24 -0
  249. package/dist/components/ui/field.module.js.map +1 -0
  250. package/dist/components/ui/field_module.css +185 -0
  251. package/dist/components/ui/field_module.css.map +1 -0
  252. package/dist/components/ui/fireworks-background.d.ts +27 -3
  253. package/dist/components/ui/fireworks-background.d.ts.map +1 -1
  254. package/dist/components/ui/fireworks-background.js +36 -35
  255. package/dist/components/ui/fireworks-background.js.map +1 -1
  256. package/dist/components/ui/fireworks-background.module.js +8 -0
  257. package/dist/components/ui/fireworks-background.module.js.map +1 -0
  258. package/dist/components/ui/fireworks-background_module.css +17 -0
  259. package/dist/components/ui/fireworks-background_module.css.map +1 -0
  260. package/dist/components/ui/flip-button.d.ts +27 -3
  261. package/dist/components/ui/flip-button.d.ts.map +1 -1
  262. package/dist/components/ui/flip-button.js +27 -17
  263. package/dist/components/ui/flip-button.js.map +1 -1
  264. package/dist/components/ui/flip-button.module.js +11 -0
  265. package/dist/components/ui/flip-button.module.js.map +1 -0
  266. package/dist/components/ui/flip-button_module.css +47 -0
  267. package/dist/components/ui/flip-button_module.css.map +1 -0
  268. package/dist/components/ui/focus-scope.js +70 -0
  269. package/dist/components/ui/focus-scope.js.map +1 -0
  270. package/dist/components/ui/focus-scope.module.js +7 -0
  271. package/dist/components/ui/focus-scope.module.js.map +1 -0
  272. package/dist/components/ui/focus-scope_module.css +6 -0
  273. package/dist/components/ui/focus-scope_module.css.map +1 -0
  274. package/dist/components/ui/form-skeleton.js +32 -0
  275. package/dist/components/ui/form-skeleton.js.map +1 -0
  276. package/dist/components/ui/form-skeleton.module.js +11 -0
  277. package/dist/components/ui/form-skeleton.module.js.map +1 -0
  278. package/dist/components/ui/form-skeleton_module.css +30 -0
  279. package/dist/components/ui/form-skeleton_module.css.map +1 -0
  280. package/dist/components/ui/form.d.ts +143 -13
  281. package/dist/components/ui/form.d.ts.map +1 -1
  282. package/dist/components/ui/form.js +55 -21
  283. package/dist/components/ui/form.js.map +1 -1
  284. package/dist/components/ui/form.module.js +10 -0
  285. package/dist/components/ui/form.module.js.map +1 -0
  286. package/dist/components/ui/form_module.css +22 -0
  287. package/dist/components/ui/form_module.css.map +1 -0
  288. package/dist/components/ui/gradient-background.d.ts +21 -3
  289. package/dist/components/ui/gradient-background.d.ts.map +1 -1
  290. package/dist/components/ui/gradient-background.js +8 -4
  291. package/dist/components/ui/gradient-background.js.map +1 -1
  292. package/dist/components/ui/gradient-background.module.js +7 -0
  293. package/dist/components/ui/gradient-background.module.js.map +1 -0
  294. package/dist/components/ui/gradient-background_module.css +9 -0
  295. package/dist/components/ui/gradient-background_module.css.map +1 -0
  296. package/dist/components/ui/gradient-text.d.ts +23 -2
  297. package/dist/components/ui/gradient-text.d.ts.map +1 -1
  298. package/dist/components/ui/gradient-text.js +8 -6
  299. package/dist/components/ui/gradient-text.js.map +1 -1
  300. package/dist/components/ui/gradient-text.module.js +9 -0
  301. package/dist/components/ui/gradient-text.module.js.map +1 -0
  302. package/dist/components/ui/gradient-text_module.css +24 -0
  303. package/dist/components/ui/gradient-text_module.css.map +1 -0
  304. package/dist/components/ui/highlight-text.d.ts +24 -2
  305. package/dist/components/ui/highlight-text.d.ts.map +1 -1
  306. package/dist/components/ui/highlight-text.js +7 -10
  307. package/dist/components/ui/highlight-text.js.map +1 -1
  308. package/dist/components/ui/highlight-text.module.js +7 -0
  309. package/dist/components/ui/highlight-text.module.js.map +1 -0
  310. package/dist/components/ui/highlight-text_module.css +16 -0
  311. package/dist/components/ui/highlight-text_module.css.map +1 -0
  312. package/dist/components/ui/hole-background.d.ts +23 -2
  313. package/dist/components/ui/hole-background.d.ts.map +1 -1
  314. package/dist/components/ui/hole-background.js +155 -118
  315. package/dist/components/ui/hole-background.js.map +1 -1
  316. package/dist/components/ui/hole-background.module.js +10 -0
  317. package/dist/components/ui/hole-background.module.js.map +1 -0
  318. package/dist/components/ui/hole-background_module.css +85 -0
  319. package/dist/components/ui/hole-background_module.css.map +1 -0
  320. package/dist/components/ui/hover-card.d.ts +85 -4
  321. package/dist/components/ui/hover-card.d.ts.map +1 -1
  322. package/dist/components/ui/hover-card.js +52 -10
  323. package/dist/components/ui/hover-card.js.map +1 -1
  324. package/dist/components/ui/hover-card.module.js +8 -0
  325. package/dist/components/ui/hover-card.module.js.map +1 -0
  326. package/dist/components/ui/hover-card_module.css +23 -0
  327. package/dist/components/ui/hover-card_module.css.map +1 -0
  328. package/dist/components/ui/input-group.d.ts +132 -13
  329. package/dist/components/ui/input-group.d.ts.map +1 -1
  330. package/dist/components/ui/input-group.js +62 -66
  331. package/dist/components/ui/input-group.js.map +1 -1
  332. package/dist/components/ui/input-group.module.js +20 -0
  333. package/dist/components/ui/input-group.module.js.map +1 -0
  334. package/dist/components/ui/input-group_module.css +150 -0
  335. package/dist/components/ui/input-group_module.css.map +1 -0
  336. package/dist/components/ui/input-otp.d.ts +110 -30
  337. package/dist/components/ui/input-otp.d.ts.map +1 -1
  338. package/dist/components/ui/input-otp.js +24 -15
  339. package/dist/components/ui/input-otp.js.map +1 -1
  340. package/dist/components/ui/input-otp.module.js +17 -0
  341. package/dist/components/ui/input-otp.module.js.map +1 -0
  342. package/dist/components/ui/input-otp_module.css +89 -0
  343. package/dist/components/ui/input-otp_module.css.map +1 -0
  344. package/dist/components/ui/input.d.ts +31 -1
  345. package/dist/components/ui/input.d.ts.map +1 -1
  346. package/dist/components/ui/input.js +21 -8
  347. package/dist/components/ui/input.js.map +1 -1
  348. package/dist/components/ui/input.module.js +7 -0
  349. package/dist/components/ui/input.module.js.map +1 -0
  350. package/dist/components/ui/input_module.css +40 -0
  351. package/dist/components/ui/input_module.css.map +1 -0
  352. package/dist/components/ui/item.d.ts +221 -19
  353. package/dist/components/ui/item.d.ts.map +1 -1
  354. package/dist/components/ui/item.js +66 -90
  355. package/dist/components/ui/item.js.map +1 -1
  356. package/dist/components/ui/item.module.js +22 -0
  357. package/dist/components/ui/item.module.js.map +1 -0
  358. package/dist/components/ui/item_module.css +143 -0
  359. package/dist/components/ui/item_module.css.map +1 -0
  360. package/dist/components/ui/kbd.d.ts +43 -2
  361. package/dist/components/ui/kbd.d.ts.map +1 -1
  362. package/dist/components/ui/kbd.js +12 -12
  363. package/dist/components/ui/kbd.js.map +1 -1
  364. package/dist/components/ui/kbd.module.js +8 -0
  365. package/dist/components/ui/kbd.module.js.map +1 -0
  366. package/dist/components/ui/kbd_module.css +35 -0
  367. package/dist/components/ui/kbd_module.css.map +1 -0
  368. package/dist/components/ui/label.d.ts +30 -3
  369. package/dist/components/ui/label.d.ts.map +1 -1
  370. package/dist/components/ui/label.js +7 -8
  371. package/dist/components/ui/label.js.map +1 -1
  372. package/dist/components/ui/label.module.js +7 -0
  373. package/dist/components/ui/label.module.js.map +1 -0
  374. package/dist/components/ui/label_module.css +17 -0
  375. package/dist/components/ui/label_module.css.map +1 -0
  376. package/dist/components/ui/list-skeleton.js +35 -0
  377. package/dist/components/ui/list-skeleton.js.map +1 -0
  378. package/dist/components/ui/list-skeleton.module.js +12 -0
  379. package/dist/components/ui/list-skeleton.module.js.map +1 -0
  380. package/dist/components/ui/list-skeleton_module.css +39 -0
  381. package/dist/components/ui/list-skeleton_module.css.map +1 -0
  382. package/dist/components/ui/loading-overlay.js +21 -0
  383. package/dist/components/ui/loading-overlay.js.map +1 -0
  384. package/dist/components/ui/loading-overlay.module.js +9 -0
  385. package/dist/components/ui/loading-overlay.module.js.map +1 -0
  386. package/dist/components/ui/loading-overlay_module.css +22 -0
  387. package/dist/components/ui/loading-overlay_module.css.map +1 -0
  388. package/dist/components/ui/menubar.d.ts +422 -22
  389. package/dist/components/ui/menubar.d.ts.map +1 -1
  390. package/dist/components/ui/menubar.js +199 -100
  391. package/dist/components/ui/menubar.js.map +1 -1
  392. package/dist/components/ui/menubar.module.js +21 -0
  393. package/dist/components/ui/menubar.module.js.map +1 -0
  394. package/dist/components/ui/menubar_module.css +145 -0
  395. package/dist/components/ui/menubar_module.css.map +1 -0
  396. package/dist/components/ui/meter.d.ts +101 -0
  397. package/dist/components/ui/meter.d.ts.map +1 -0
  398. package/dist/components/ui/meter.js +71 -0
  399. package/dist/components/ui/meter.js.map +1 -0
  400. package/dist/components/ui/meter.module.js +10 -0
  401. package/dist/components/ui/meter.module.js.map +1 -0
  402. package/dist/components/ui/meter_module.css +31 -0
  403. package/dist/components/ui/meter_module.css.map +1 -0
  404. package/dist/components/ui/navigation-menu.d.ts +242 -11
  405. package/dist/components/ui/navigation-menu.d.ts.map +1 -1
  406. package/dist/components/ui/navigation-menu.js +135 -49
  407. package/dist/components/ui/navigation-menu.js.map +1 -1
  408. package/dist/components/ui/navigation-menu.module.js +18 -0
  409. package/dist/components/ui/navigation-menu.module.js.map +1 -0
  410. package/dist/components/ui/navigation-menu_module.css +112 -0
  411. package/dist/components/ui/navigation-menu_module.css.map +1 -0
  412. package/dist/components/ui/number-field.d.ts +144 -0
  413. package/dist/components/ui/number-field.d.ts.map +1 -0
  414. package/dist/components/ui/number-field.js +111 -0
  415. package/dist/components/ui/number-field.js.map +1 -0
  416. package/dist/components/ui/number-field.module.js +15 -0
  417. package/dist/components/ui/number-field.module.js.map +1 -0
  418. package/dist/components/ui/number-field_module.css +125 -0
  419. package/dist/components/ui/number-field_module.css.map +1 -0
  420. package/dist/components/ui/pagination.d.ts +150 -24
  421. package/dist/components/ui/pagination.d.ts.map +1 -1
  422. package/dist/components/ui/pagination.js +41 -38
  423. package/dist/components/ui/pagination.js.map +1 -1
  424. package/dist/components/ui/pagination.module.js +14 -0
  425. package/dist/components/ui/pagination.module.js.map +1 -0
  426. package/dist/components/ui/pagination_module.css +66 -0
  427. package/dist/components/ui/pagination_module.css.map +1 -0
  428. package/dist/components/ui/popover.d.ts +133 -5
  429. package/dist/components/ui/popover.d.ts.map +1 -1
  430. package/dist/components/ui/popover.js +68 -14
  431. package/dist/components/ui/popover.js.map +1 -1
  432. package/dist/components/ui/popover.module.js +9 -0
  433. package/dist/components/ui/popover.module.js.map +1 -0
  434. package/dist/components/ui/popover_module.css +28 -0
  435. package/dist/components/ui/popover_module.css.map +1 -0
  436. package/dist/components/ui/progress.d.ts +34 -2
  437. package/dist/components/ui/progress.d.ts.map +1 -1
  438. package/dist/components/ui/progress.js +22 -14
  439. package/dist/components/ui/progress.js.map +1 -1
  440. package/dist/components/ui/progress.module.js +8 -0
  441. package/dist/components/ui/progress.module.js.map +1 -0
  442. package/dist/components/ui/progress_module.css +20 -0
  443. package/dist/components/ui/progress_module.css.map +1 -0
  444. package/dist/components/ui/radio-group.d.ts +44 -3
  445. package/dist/components/ui/radio-group.d.ts.map +1 -1
  446. package/dist/components/ui/radio-group.js +38 -16
  447. package/dist/components/ui/radio-group.js.map +1 -1
  448. package/dist/components/ui/radio-group.module.js +10 -0
  449. package/dist/components/ui/radio-group.module.js.map +1 -0
  450. package/dist/components/ui/radio-group_module.css +44 -0
  451. package/dist/components/ui/radio-group_module.css.map +1 -0
  452. package/dist/components/ui/resizable.d.ts +79 -6
  453. package/dist/components/ui/resizable.d.ts.map +1 -1
  454. package/dist/components/ui/resizable.js +23 -13
  455. package/dist/components/ui/resizable.js.map +1 -1
  456. package/dist/components/ui/resizable.module.js +10 -0
  457. package/dist/components/ui/resizable.module.js.map +1 -0
  458. package/dist/components/ui/resizable_module.css +70 -0
  459. package/dist/components/ui/resizable_module.css.map +1 -0
  460. package/dist/components/ui/ripple-button.d.ts +23 -2
  461. package/dist/components/ui/ripple-button.d.ts.map +1 -1
  462. package/dist/components/ui/ripple-button.js +26 -11
  463. package/dist/components/ui/ripple-button.js.map +1 -1
  464. package/dist/components/ui/ripple-button.module.js +9 -0
  465. package/dist/components/ui/ripple-button.module.js.map +1 -0
  466. package/dist/components/ui/ripple-button_module.css +38 -0
  467. package/dist/components/ui/ripple-button_module.css.map +1 -0
  468. package/dist/components/ui/scratcher.d.ts +25 -2
  469. package/dist/components/ui/scratcher.d.ts.map +1 -1
  470. package/dist/components/ui/scratcher.js +85 -87
  471. package/dist/components/ui/scratcher.js.map +1 -1
  472. package/dist/components/ui/scratcher.module.js +8 -0
  473. package/dist/components/ui/scratcher.module.js.map +1 -0
  474. package/dist/components/ui/scratcher_module.css +13 -0
  475. package/dist/components/ui/scratcher_module.css.map +1 -0
  476. package/dist/components/ui/scroll-area.d.ts +46 -3
  477. package/dist/components/ui/scroll-area.d.ts.map +1 -1
  478. package/dist/components/ui/scroll-area.js +44 -19
  479. package/dist/components/ui/scroll-area.js.map +1 -1
  480. package/dist/components/ui/scroll-area.module.js +14 -0
  481. package/dist/components/ui/scroll-area.module.js.map +1 -0
  482. package/dist/components/ui/scroll-area_module.css +51 -0
  483. package/dist/components/ui/scroll-area_module.css.map +1 -0
  484. package/dist/components/ui/select.d.ts +269 -11
  485. package/dist/components/ui/select.d.ts.map +1 -1
  486. package/dist/components/ui/select.js +152 -67
  487. package/dist/components/ui/select.js.map +1 -1
  488. package/dist/components/ui/select.module.js +20 -0
  489. package/dist/components/ui/select.module.js.map +1 -0
  490. package/dist/components/ui/select_module.css +134 -0
  491. package/dist/components/ui/select_module.css.map +1 -0
  492. package/dist/components/ui/separator.d.ts +36 -2
  493. package/dist/components/ui/separator.d.ts.map +1 -1
  494. package/dist/components/ui/separator.js +20 -10
  495. package/dist/components/ui/separator.js.map +1 -1
  496. package/dist/components/ui/separator.module.js +9 -0
  497. package/dist/components/ui/separator.module.js.map +1 -0
  498. package/dist/components/ui/separator_module.css +17 -0
  499. package/dist/components/ui/separator_module.css.map +1 -0
  500. package/dist/components/ui/sheet.d.ts +297 -23
  501. package/dist/components/ui/sheet.d.ts.map +1 -1
  502. package/dist/components/ui/sheet.js +121 -63
  503. package/dist/components/ui/sheet.js.map +1 -1
  504. package/dist/components/ui/sheet.module.js +18 -0
  505. package/dist/components/ui/sheet.module.js.map +1 -0
  506. package/dist/components/ui/sheet_module.css +136 -0
  507. package/dist/components/ui/sheet_module.css.map +1 -0
  508. package/dist/components/ui/sidebar.d.ts +491 -23
  509. package/dist/components/ui/sidebar.d.ts.map +1 -1
  510. package/dist/components/ui/sidebar.js +214 -143
  511. package/dist/components/ui/sidebar.js.map +1 -1
  512. package/dist/components/ui/sidebar.module.js +50 -0
  513. package/dist/components/ui/sidebar.module.js.map +1 -0
  514. package/dist/components/ui/sidebar_module.css +569 -0
  515. package/dist/components/ui/sidebar_module.css.map +1 -0
  516. package/dist/components/ui/skeleton.d.ts +30 -1
  517. package/dist/components/ui/skeleton.d.ts.map +1 -1
  518. package/dist/components/ui/skeleton.js +7 -7
  519. package/dist/components/ui/skeleton.js.map +1 -1
  520. package/dist/components/ui/skeleton.module.js +8 -0
  521. package/dist/components/ui/skeleton.module.js.map +1 -0
  522. package/dist/components/ui/skeleton_module.css +18 -0
  523. package/dist/components/ui/skeleton_module.css.map +1 -0
  524. package/dist/components/ui/slider.d.ts +48 -2
  525. package/dist/components/ui/slider.d.ts.map +1 -1
  526. package/dist/components/ui/slider.js +44 -17
  527. package/dist/components/ui/slider.js.map +1 -1
  528. package/dist/components/ui/slider.module.js +11 -0
  529. package/dist/components/ui/slider.module.js.map +1 -0
  530. package/dist/components/ui/slider_module.css +55 -0
  531. package/dist/components/ui/slider_module.css.map +1 -0
  532. package/dist/components/ui/sonner.d.ts +137 -4
  533. package/dist/components/ui/sonner.d.ts.map +1 -1
  534. package/dist/components/ui/sonner.js +450 -18
  535. package/dist/components/ui/sonner.js.map +1 -1
  536. package/dist/components/ui/sonner.module.js +34 -0
  537. package/dist/components/ui/sonner.module.js.map +1 -0
  538. package/dist/components/ui/sonner_module.css +233 -0
  539. package/dist/components/ui/sonner_module.css.map +1 -0
  540. package/dist/components/ui/spinner.d.ts +20 -1
  541. package/dist/components/ui/spinner.d.ts.map +1 -1
  542. package/dist/components/ui/spinner.js +29 -11
  543. package/dist/components/ui/spinner.js.map +1 -1
  544. package/dist/components/ui/spinner.module.js +10 -0
  545. package/dist/components/ui/spinner.module.js.map +1 -0
  546. package/dist/components/ui/spinner_module.css +28 -0
  547. package/dist/components/ui/spinner_module.css.map +1 -0
  548. package/dist/components/ui/stepper.d.ts +48 -0
  549. package/dist/components/ui/stepper.d.ts.map +1 -0
  550. package/dist/components/ui/stepper.js +41 -0
  551. package/dist/components/ui/stepper.js.map +1 -0
  552. package/dist/components/ui/stepper.module.js +12 -0
  553. package/dist/components/ui/stepper.module.js.map +1 -0
  554. package/dist/components/ui/stepper_module.css +75 -0
  555. package/dist/components/ui/stepper_module.css.map +1 -0
  556. package/dist/components/ui/switch.d.ts +29 -2
  557. package/dist/components/ui/switch.d.ts.map +1 -1
  558. package/dist/components/ui/switch.js +21 -9
  559. package/dist/components/ui/switch.js.map +1 -1
  560. package/dist/components/ui/switch.module.js +8 -0
  561. package/dist/components/ui/switch.module.js.map +1 -0
  562. package/dist/components/ui/switch_module.css +45 -0
  563. package/dist/components/ui/switch_module.css.map +1 -0
  564. package/dist/components/ui/table-skeleton.js +34 -0
  565. package/dist/components/ui/table-skeleton.js.map +1 -0
  566. package/dist/components/ui/table-skeleton.module.js +11 -0
  567. package/dist/components/ui/table-skeleton.module.js.map +1 -0
  568. package/dist/components/ui/table-skeleton_module.css +32 -0
  569. package/dist/components/ui/table-skeleton_module.css.map +1 -0
  570. package/dist/components/ui/table.d.ts +170 -8
  571. package/dist/components/ui/table.d.ts.map +1 -1
  572. package/dist/components/ui/table.js +17 -17
  573. package/dist/components/ui/table.js.map +1 -1
  574. package/dist/components/ui/table.module.js +15 -0
  575. package/dist/components/ui/table.module.js.map +1 -0
  576. package/dist/components/ui/table_module.css +71 -0
  577. package/dist/components/ui/table_module.css.map +1 -0
  578. package/dist/components/ui/tabs.d.ts +114 -5
  579. package/dist/components/ui/tabs.d.ts.map +1 -1
  580. package/dist/components/ui/tabs.js +71 -20
  581. package/dist/components/ui/tabs.js.map +1 -1
  582. package/dist/components/ui/tabs.module.js +10 -0
  583. package/dist/components/ui/tabs.module.js.map +1 -0
  584. package/dist/components/ui/tabs_module.css +89 -0
  585. package/dist/components/ui/tabs_module.css.map +1 -0
  586. package/dist/components/ui/textarea.d.ts +24 -1
  587. package/dist/components/ui/textarea.d.ts.map +1 -1
  588. package/dist/components/ui/textarea.js +2 -2
  589. package/dist/components/ui/textarea.js.map +1 -1
  590. package/dist/components/ui/textarea.module.js +7 -0
  591. package/dist/components/ui/textarea.module.js.map +1 -0
  592. package/dist/components/ui/textarea_module.css +33 -0
  593. package/dist/components/ui/textarea_module.css.map +1 -0
  594. package/dist/components/ui/timeline.d.ts +111 -0
  595. package/dist/components/ui/timeline.d.ts.map +1 -0
  596. package/dist/components/ui/timeline.js +34 -0
  597. package/dist/components/ui/timeline.js.map +1 -0
  598. package/dist/components/ui/timeline.module.js +10 -0
  599. package/dist/components/ui/timeline.module.js.map +1 -0
  600. package/dist/components/ui/timeline_module.css +47 -0
  601. package/dist/components/ui/timeline_module.css.map +1 -0
  602. package/dist/components/ui/toggle-group.d.ts +81 -10
  603. package/dist/components/ui/toggle-group.d.ts.map +1 -1
  604. package/dist/components/ui/toggle-group.js +32 -23
  605. package/dist/components/ui/toggle-group.js.map +1 -1
  606. package/dist/components/ui/toggle-group.module.js +7 -0
  607. package/dist/components/ui/toggle-group.module.js.map +1 -0
  608. package/dist/components/ui/toggle-group_module.css +8 -0
  609. package/dist/components/ui/toggle-group_module.css.map +1 -0
  610. package/dist/components/ui/toggle.d.ts +60 -11
  611. package/dist/components/ui/toggle.d.ts.map +1 -1
  612. package/dist/components/ui/toggle.js +29 -29
  613. package/dist/components/ui/toggle.js.map +1 -1
  614. package/dist/components/ui/toggle.module.js +12 -0
  615. package/dist/components/ui/toggle.module.js.map +1 -0
  616. package/dist/components/ui/toggle_module.css +62 -0
  617. package/dist/components/ui/toggle_module.css.map +1 -0
  618. package/dist/components/ui/toolbar.d.ts +127 -0
  619. package/dist/components/ui/toolbar.d.ts.map +1 -0
  620. package/dist/components/ui/toolbar.js +85 -0
  621. package/dist/components/ui/toolbar.js.map +1 -0
  622. package/dist/components/ui/toolbar.module.js +12 -0
  623. package/dist/components/ui/toolbar.module.js.map +1 -0
  624. package/dist/components/ui/toolbar_module.css +115 -0
  625. package/dist/components/ui/toolbar_module.css.map +1 -0
  626. package/dist/components/ui/tooltip.d.ts +119 -5
  627. package/dist/components/ui/tooltip.d.ts.map +1 -1
  628. package/dist/components/ui/tooltip.js +48 -13
  629. package/dist/components/ui/tooltip.js.map +1 -1
  630. package/dist/components/ui/tooltip.module.js +9 -0
  631. package/dist/components/ui/tooltip.module.js.map +1 -0
  632. package/dist/components/ui/tooltip_module.css +35 -0
  633. package/dist/components/ui/tooltip_module.css.map +1 -0
  634. package/dist/components/ui/typewriter.d.ts +48 -13
  635. package/dist/components/ui/typewriter.d.ts.map +1 -1
  636. package/dist/components/ui/typewriter.js +46 -49
  637. package/dist/components/ui/typewriter.js.map +1 -1
  638. package/dist/components/ui/typewriter.module.js +16 -0
  639. package/dist/components/ui/typewriter.module.js.map +1 -0
  640. package/dist/components/ui/typewriter_module.css +102 -0
  641. package/dist/components/ui/typewriter_module.css.map +1 -0
  642. package/dist/components/ui/visually-hidden.d.ts +38 -0
  643. package/dist/components/ui/visually-hidden.d.ts.map +1 -0
  644. package/dist/components/ui/visually-hidden.js +13 -0
  645. package/dist/components/ui/visually-hidden.js.map +1 -0
  646. package/dist/components/ui/visually-hidden.module.js +7 -0
  647. package/dist/components/ui/visually-hidden.module.js.map +1 -0
  648. package/dist/components/ui/visually-hidden_module.css +14 -0
  649. package/dist/components/ui/visually-hidden_module.css.map +1 -0
  650. package/dist/hooks/useAnnounce.js +46 -0
  651. package/dist/hooks/useAnnounce.js.map +1 -0
  652. package/dist/hooks/useBreakpoint.d.ts +17 -0
  653. package/dist/hooks/useBreakpoint.d.ts.map +1 -0
  654. package/dist/hooks/useBreakpoint.js +16 -0
  655. package/dist/hooks/useBreakpoint.js.map +1 -0
  656. package/dist/hooks/useColorScheme.d.ts +14 -0
  657. package/dist/hooks/useColorScheme.d.ts.map +1 -0
  658. package/dist/hooks/useColorScheme.js +9 -0
  659. package/dist/hooks/useColorScheme.js.map +1 -0
  660. package/dist/hooks/useFocusManager.js +51 -0
  661. package/dist/hooks/useFocusManager.js.map +1 -0
  662. package/dist/hooks/useFocusVisible.d.ts +50 -0
  663. package/dist/hooks/useFocusVisible.d.ts.map +1 -0
  664. package/dist/hooks/useFocusVisible.js +35 -0
  665. package/dist/hooks/useFocusVisible.js.map +1 -0
  666. package/dist/hooks/useIsMobile.d.ts +5 -11
  667. package/dist/hooks/useIsMobile.d.ts.map +1 -1
  668. package/dist/hooks/useIsMobile.js +2 -13
  669. package/dist/hooks/useIsMobile.js.map +1 -1
  670. package/dist/hooks/useMediaQuery.d.ts +14 -0
  671. package/dist/hooks/useMediaQuery.d.ts.map +1 -0
  672. package/dist/hooks/useMediaQuery.js +20 -0
  673. package/dist/hooks/useMediaQuery.js.map +1 -0
  674. package/dist/hooks/usePrefersContrast.d.ts +19 -0
  675. package/dist/hooks/usePrefersContrast.d.ts.map +1 -0
  676. package/dist/hooks/usePrefersContrast.js +8 -0
  677. package/dist/hooks/usePrefersContrast.js.map +1 -0
  678. package/dist/hooks/useReducedMotion.d.ts +19 -0
  679. package/dist/hooks/useReducedMotion.d.ts.map +1 -0
  680. package/dist/hooks/useReducedMotion.js +2 -0
  681. package/dist/index.css +104 -5363
  682. package/dist/index.css.map +1 -1
  683. package/dist/index.d.ts +38 -8
  684. package/dist/index.d.ts.map +1 -1
  685. package/dist/index.js +89 -72
  686. package/dist/lib/utilities.d.ts +5 -4
  687. package/dist/lib/utilities.d.ts.map +1 -1
  688. package/dist/lib/utilities.js +1 -2
  689. package/dist/lib/utilities.js.map +1 -1
  690. package/dist/motion/Collapse.js +19 -0
  691. package/dist/motion/Collapse.js.map +1 -0
  692. package/dist/motion/Collapse.module.js +8 -0
  693. package/dist/motion/Collapse.module.js.map +1 -0
  694. package/dist/motion/Collapse_module.css +25 -0
  695. package/dist/motion/Collapse_module.css.map +1 -0
  696. package/dist/motion/Presence.js +14 -0
  697. package/dist/motion/Presence.js.map +1 -0
  698. package/dist/motion/index.js +5 -0
  699. package/dist/motion/presets.js +117 -0
  700. package/dist/motion/presets.js.map +1 -0
  701. package/dist/motion/tokens.js +41 -0
  702. package/dist/motion/tokens.js.map +1 -0
  703. package/package.json +154 -67
  704. package/src/components/ui/accordion.module.css +70 -0
  705. package/src/components/ui/accordion.tsx +278 -44
  706. package/src/components/ui/alert-dialog.module.css +87 -0
  707. package/src/components/ui/alert-dialog.tsx +474 -99
  708. package/src/components/ui/alert.module.css +57 -0
  709. package/src/components/ui/alert.tsx +136 -43
  710. package/src/components/ui/aspect-ratio.module.css +7 -0
  711. package/src/components/ui/aspect-ratio.tsx +38 -3
  712. package/src/components/ui/async-boundary.tsx +56 -0
  713. package/src/components/ui/avatar.module.css +31 -0
  714. package/src/components/ui/avatar.tsx +146 -36
  715. package/src/components/ui/background-beams.module.css +20 -0
  716. package/src/components/ui/background-beams.tsx +173 -134
  717. package/src/components/ui/badge.module.css +60 -0
  718. package/src/components/ui/badge.tsx +100 -32
  719. package/src/components/ui/breadcrumb.module.css +87 -0
  720. package/src/components/ui/breadcrumb.tsx +256 -74
  721. package/src/components/ui/bubble-background.module.css +97 -0
  722. package/src/components/ui/bubble-background.tsx +92 -52
  723. package/src/components/ui/button-group.module.css +76 -0
  724. package/src/components/ui/button-group.tsx +135 -46
  725. package/src/components/ui/button.module.css +138 -0
  726. package/src/components/ui/button.tsx +159 -41
  727. package/src/components/ui/calendar.module.css +250 -0
  728. package/src/components/ui/calendar.tsx +133 -103
  729. package/src/components/ui/card-skeleton.module.css +50 -0
  730. package/src/components/ui/card-skeleton.tsx +69 -0
  731. package/src/components/ui/card.module.css +41 -0
  732. package/src/components/ui/card.tsx +175 -22
  733. package/src/components/ui/carousel.module.css +80 -0
  734. package/src/components/ui/carousel.tsx +184 -43
  735. package/src/components/ui/chart.module.css +164 -0
  736. package/src/components/ui/chart.tsx +444 -102
  737. package/src/components/ui/checkbox-group.module.css +8 -0
  738. package/src/components/ui/checkbox-group.tsx +54 -0
  739. package/src/components/ui/checkbox.module.css +43 -0
  740. package/src/components/ui/checkbox.tsx +73 -19
  741. package/src/components/ui/collapsible.module.css +24 -0
  742. package/src/components/ui/collapsible.tsx +139 -3
  743. package/src/components/ui/command.module.css +193 -0
  744. package/src/components/ui/command.tsx +877 -114
  745. package/src/components/ui/context-menu.module.css +113 -0
  746. package/src/components/ui/context-menu.tsx +616 -157
  747. package/src/components/ui/copy-button.module.css +34 -0
  748. package/src/components/ui/copy-button.tsx +116 -0
  749. package/src/components/ui/counting-number.module.css +4 -0
  750. package/src/components/ui/counting-number.tsx +69 -31
  751. package/src/components/ui/dialog.module.css +113 -0
  752. package/src/components/ui/dialog.tsx +427 -81
  753. package/src/components/ui/dot-background.module.css +12 -0
  754. package/src/components/ui/dot-background.tsx +134 -126
  755. package/src/components/ui/drawer.module.css +85 -0
  756. package/src/components/ui/drawer.tsx +408 -80
  757. package/src/components/ui/dropdown-menu.module.css +113 -0
  758. package/src/components/ui/dropdown-menu.tsx +616 -159
  759. package/src/components/ui/dropdrawer.module.css +322 -0
  760. package/src/components/ui/dropdrawer.tsx +850 -398
  761. package/src/components/ui/empty.module.css +84 -0
  762. package/src/components/ui/empty.tsx +176 -52
  763. package/src/components/ui/error-boundary.module.css +36 -0
  764. package/src/components/ui/error-boundary.tsx +127 -0
  765. package/src/components/ui/field.module.css +179 -0
  766. package/src/components/ui/field.tsx +345 -139
  767. package/src/components/ui/fireworks-background.module.css +13 -0
  768. package/src/components/ui/fireworks-background.tsx +89 -51
  769. package/src/components/ui/flip-button.module.css +44 -0
  770. package/src/components/ui/flip-button.tsx +59 -28
  771. package/src/components/ui/focus-scope.module.css +3 -0
  772. package/src/components/ui/focus-scope.tsx +160 -0
  773. package/src/components/ui/form-skeleton.module.css +28 -0
  774. package/src/components/ui/form-skeleton.tsx +62 -0
  775. package/src/components/ui/form.module.css +20 -0
  776. package/src/components/ui/form.tsx +244 -33
  777. package/src/components/ui/gradient-background.module.css +6 -0
  778. package/src/components/ui/gradient-background.tsx +27 -5
  779. package/src/components/ui/gradient-text.module.css +23 -0
  780. package/src/components/ui/gradient-text.tsx +36 -9
  781. package/src/components/ui/highlight-text.module.css +14 -0
  782. package/src/components/ui/highlight-text.tsx +37 -15
  783. package/src/components/ui/hole-background.module.css +84 -0
  784. package/src/components/ui/hole-background.tsx +290 -162
  785. package/src/components/ui/hover-card.module.css +21 -0
  786. package/src/components/ui/hover-card.tsx +142 -21
  787. package/src/components/ui/input-group.module.css +148 -0
  788. package/src/components/ui/input-group.tsx +222 -98
  789. package/src/components/ui/input-otp.module.css +92 -0
  790. package/src/components/ui/input-otp.tsx +159 -33
  791. package/src/components/ui/input.module.css +37 -0
  792. package/src/components/ui/input.tsx +56 -14
  793. package/src/components/ui/item.module.css +143 -0
  794. package/src/components/ui/item.tsx +331 -104
  795. package/src/components/ui/kbd.module.css +31 -0
  796. package/src/components/ui/kbd.tsx +60 -17
  797. package/src/components/ui/label.module.css +13 -0
  798. package/src/components/ui/label.tsx +38 -14
  799. package/src/components/ui/list-skeleton.module.css +35 -0
  800. package/src/components/ui/list-skeleton.tsx +70 -0
  801. package/src/components/ui/loading-overlay.module.css +19 -0
  802. package/src/components/ui/loading-overlay.tsx +72 -0
  803. package/src/components/ui/menubar.module.css +144 -0
  804. package/src/components/ui/menubar.tsx +605 -192
  805. package/src/components/ui/meter.module.css +32 -0
  806. package/src/components/ui/meter.tsx +170 -0
  807. package/src/components/ui/navigation-menu.module.css +110 -0
  808. package/src/components/ui/navigation-menu.tsx +375 -101
  809. package/src/components/ui/number-field.module.css +126 -0
  810. package/src/components/ui/number-field.tsx +254 -0
  811. package/src/components/ui/pagination.module.css +64 -0
  812. package/src/components/ui/pagination.tsx +250 -72
  813. package/src/components/ui/popover.module.css +26 -0
  814. package/src/components/ui/popover.tsx +207 -25
  815. package/src/components/ui/progress.module.css +15 -0
  816. package/src/components/ui/progress.tsx +53 -16
  817. package/src/components/ui/radio-group.module.css +41 -0
  818. package/src/components/ui/radio-group.tsx +91 -34
  819. package/src/components/ui/resizable.module.css +67 -0
  820. package/src/components/ui/resizable.tsx +106 -26
  821. package/src/components/ui/ripple-button.module.css +35 -0
  822. package/src/components/ui/ripple-button.tsx +55 -21
  823. package/src/components/ui/scratcher.module.css +9 -0
  824. package/src/components/ui/scratcher.tsx +129 -99
  825. package/src/components/ui/scroll-area.module.css +47 -0
  826. package/src/components/ui/scroll-area.tsx +96 -34
  827. package/src/components/ui/select.module.css +131 -0
  828. package/src/components/ui/select.tsx +435 -124
  829. package/src/components/ui/separator.module.css +14 -0
  830. package/src/components/ui/separator.tsx +59 -18
  831. package/src/components/ui/sheet.module.css +138 -0
  832. package/src/components/ui/sheet.tsx +424 -95
  833. package/src/components/ui/sidebar.module.css +594 -0
  834. package/src/components/ui/sidebar.tsx +899 -425
  835. package/src/components/ui/skeleton.module.css +14 -0
  836. package/src/components/ui/skeleton.tsx +39 -9
  837. package/src/components/ui/slider.module.css +48 -0
  838. package/src/components/ui/slider.tsx +89 -16
  839. package/src/components/ui/sonner.module.css +246 -0
  840. package/src/components/ui/sonner.tsx +769 -25
  841. package/src/components/ui/spinner.module.css +25 -0
  842. package/src/components/ui/spinner.tsx +51 -12
  843. package/src/components/ui/stepper.module.css +72 -0
  844. package/src/components/ui/stepper.tsx +95 -0
  845. package/src/components/ui/switch.module.css +42 -0
  846. package/src/components/ui/switch.tsx +53 -20
  847. package/src/components/ui/table-skeleton.module.css +29 -0
  848. package/src/components/ui/table-skeleton.tsx +79 -0
  849. package/src/components/ui/table.module.css +66 -0
  850. package/src/components/ui/table.tsx +235 -61
  851. package/src/components/ui/tabs.module.css +89 -0
  852. package/src/components/ui/tabs.tsx +192 -45
  853. package/src/components/ui/textarea.module.css +30 -0
  854. package/src/components/ui/textarea.tsx +30 -10
  855. package/src/components/ui/timeline.module.css +43 -0
  856. package/src/components/ui/timeline.tsx +153 -0
  857. package/src/components/ui/toggle-group.module.css +5 -0
  858. package/src/components/ui/toggle-group.tsx +116 -35
  859. package/src/components/ui/toggle.module.css +57 -0
  860. package/src/components/ui/toggle.tsx +89 -33
  861. package/src/components/ui/toolbar.module.css +112 -0
  862. package/src/components/ui/toolbar.tsx +210 -0
  863. package/src/components/ui/tooltip.module.css +39 -0
  864. package/src/components/ui/tooltip.tsx +181 -24
  865. package/src/components/ui/typewriter.module.css +101 -0
  866. package/src/components/ui/typewriter.tsx +130 -128
  867. package/src/components/ui/visually-hidden.module.css +11 -0
  868. package/src/components/ui/visually-hidden.tsx +50 -0
  869. package/src/css-modules.d.ts +9 -0
  870. package/src/hooks/useAnnounce.tsx +73 -0
  871. package/src/hooks/useBreakpoint.tsx +41 -0
  872. package/src/hooks/useColorScheme.tsx +23 -0
  873. package/src/hooks/useFocusManager.tsx +89 -0
  874. package/src/hooks/useFocusVisible.tsx +88 -0
  875. package/src/hooks/useIsMobile.tsx +7 -28
  876. package/src/hooks/useMediaQuery.tsx +34 -0
  877. package/src/hooks/usePrefersContrast.tsx +24 -0
  878. package/src/hooks/useReducedMotion.tsx +20 -0
  879. package/src/index.css +127 -65
  880. package/src/index.ts +196 -18
  881. package/src/lib/utilities.ts +7 -6
  882. package/src/motion/Collapse.module.css +22 -0
  883. package/src/motion/Collapse.tsx +52 -0
  884. package/src/motion/Presence.tsx +44 -0
  885. package/src/motion/index.ts +13 -0
  886. package/src/motion/presets.ts +77 -0
  887. package/src/motion/tokens.ts +37 -0
  888. package/src/hooks/useIsMobile.test.tsx +0 -96
  889. package/src/hooks/useWindowSize.test.tsx +0 -57
  890. package/src/index.test.ts +0 -537
  891. package/src/lib/color-conversion-utilities.test.ts +0 -225
  892. package/src/lib/utilities.test.ts +0 -37
@@ -1,11 +1,27 @@
1
1
  "use client";
2
2
  import { jsx } from "react/jsx-runtime";
3
- import { Slot } from "@radix-ui/react-slot";
4
- import { createContext, forwardRef, useContext, useId } from "react";
5
- import { Controller, FormProvider, useFormContext } from "react-hook-form";
6
- import { Label } from "./label.js";
3
+ import { cloneElement, createContext, forwardRef, isValidElement, useContext, useId } from "react";
4
+ import { Controller, FormProvider, useController, useFieldArray, useForm, useFormContext, useFormState, useWatch } from "react-hook-form";
7
5
  import { cn } from "../../lib/utilities.js";
8
- const Form = FormProvider;
6
+ import form_module from "./form.module.js";
7
+ const Form = Object.assign(FormProvider, {
8
+ displayName: "Form"
9
+ });
10
+ function assignRef(ref, value) {
11
+ if ("function" == typeof ref) return void ref(value);
12
+ if (ref) ref.current = value;
13
+ }
14
+ function composeRefs(...refs) {
15
+ return (value)=>{
16
+ for (const ref of refs)assignRef(ref, value);
17
+ };
18
+ }
19
+ function mergeAriaDescribedBy(...describedByValues) {
20
+ const tokens = describedByValues.flatMap((describedByValue)=>describedByValue?.split(/\s+/u) ?? []).filter((token)=>token.length > 0);
21
+ return tokens.length > 0 ? [
22
+ ...new Set(tokens)
23
+ ].join(" ") : void 0;
24
+ }
9
25
  const FormFieldContext = /*#__PURE__*/ createContext(null);
10
26
  const FormField = ({ ...props })=>/*#__PURE__*/ jsx(FormFieldContext.Provider, {
11
27
  value: {
@@ -24,12 +40,16 @@ const useFormField = ()=>{
24
40
  const fieldState = getFieldState(fieldContext.name, formState);
25
41
  const { id } = itemContext;
26
42
  return {
27
- id,
28
- name: fieldContext.name,
29
- formItemId: `${id}-form-item`,
43
+ error: fieldState.error,
30
44
  formDescriptionId: `${id}-form-item-description`,
45
+ formItemId: `${id}-form-item`,
31
46
  formMessageId: `${id}-form-item-message`,
32
- ...fieldState
47
+ id,
48
+ invalid: fieldState.invalid,
49
+ isDirty: fieldState.isDirty,
50
+ isTouched: fieldState.isTouched,
51
+ isValidating: fieldState.isValidating,
52
+ name: fieldContext.name
33
53
  };
34
54
  };
35
55
  const FormItemContext = /*#__PURE__*/ createContext(null);
@@ -41,7 +61,7 @@ const FormItem = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>{
41
61
  },
42
62
  children: /*#__PURE__*/ jsx("div", {
43
63
  ref: ref,
44
- className: cn("space-y-2", className),
64
+ className: cn(form_module.item, className),
45
65
  ...props
46
66
  })
47
67
  });
@@ -49,22 +69,35 @@ const FormItem = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>{
49
69
  FormItem.displayName = "FormItem";
50
70
  const FormLabel = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>{
51
71
  const { error, formItemId } = useFormField();
52
- return /*#__PURE__*/ jsx(Label, {
72
+ return /*#__PURE__*/ jsx("label", {
53
73
  ref: ref,
54
- className: cn(error && "text-red-500 dark:text-red-900", className),
74
+ className: cn(error && form_module.labelError, className),
55
75
  htmlFor: formItemId,
56
76
  ...props
57
77
  });
58
78
  });
59
79
  FormLabel.displayName = "FormLabel";
60
- const FormControl = /*#__PURE__*/ forwardRef(({ ...props }, ref)=>{
61
- const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
62
- return /*#__PURE__*/ jsx(Slot, {
80
+ const FormControl = /*#__PURE__*/ forwardRef(({ children, ...props }, ref)=>{
81
+ const { error, formDescriptionId, formItemId, formMessageId } = useFormField();
82
+ const describedBy = mergeAriaDescribedBy("string" == typeof props["aria-describedby"] ? props["aria-describedby"] : void 0, formDescriptionId, error ? formMessageId : void 0);
83
+ if (/*#__PURE__*/ isValidElement(children)) {
84
+ const child = children;
85
+ const childDescribedBy = "string" == typeof child.props["aria-describedby"] ? child.props["aria-describedby"] : void 0;
86
+ return /*#__PURE__*/ cloneElement(child, {
87
+ ...props,
88
+ ref: composeRefs(ref, child.props.ref),
89
+ id: formItemId,
90
+ "aria-describedby": mergeAriaDescribedBy(childDescribedBy, describedBy),
91
+ "aria-invalid": Boolean(error)
92
+ });
93
+ }
94
+ return /*#__PURE__*/ jsx("div", {
63
95
  ref: ref,
64
96
  id: formItemId,
65
- "aria-describedby": error ? `${formDescriptionId} ${formMessageId}` : `${formDescriptionId}`,
97
+ "aria-describedby": describedBy,
66
98
  "aria-invalid": Boolean(error),
67
- ...props
99
+ ...props,
100
+ children: children
68
101
  });
69
102
  });
70
103
  FormControl.displayName = "FormControl";
@@ -73,24 +106,25 @@ const FormDescription = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=
73
106
  return /*#__PURE__*/ jsx("p", {
74
107
  ref: ref,
75
108
  id: formDescriptionId,
76
- className: cn("text-[0.8rem] text-neutral-500 dark:text-neutral-400", className),
109
+ className: cn(form_module.description, className),
77
110
  ...props
78
111
  });
79
112
  });
80
113
  FormDescription.displayName = "FormDescription";
81
114
  const FormMessage = /*#__PURE__*/ forwardRef(({ className, children, ...props }, ref)=>{
82
115
  const { error, formMessageId } = useFormField();
83
- const body = error ? String(error?.message ?? "") : children;
116
+ const body = error ? String(error.message ?? "") : children;
84
117
  if (!body) return null;
85
118
  return /*#__PURE__*/ jsx("p", {
86
119
  ref: ref,
87
120
  id: formMessageId,
88
- className: cn("text-[0.8rem] font-medium text-red-500 dark:text-red-900", className),
121
+ className: cn(form_module.message, className),
89
122
  ...props,
90
123
  children: body
91
124
  });
92
125
  });
93
126
  FormMessage.displayName = "FormMessage";
94
- export { Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, useFormField };
127
+ FormField.displayName = "FormField";
128
+ export { Controller, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, useController, useFieldArray, useForm, useFormContext, useFormField, useFormState, useWatch };
95
129
 
96
130
  //# sourceMappingURL=form.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/form.js","sources":["../../../src/components/ui/form.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport * as LabelPrimitive from \"@radix-ui/react-label\";\r\nimport {Slot} from \"@radix-ui/react-slot\";\r\nimport * as React from \"react\";\r\nimport {Controller, FormProvider, useFormContext, type ControllerProps, type FieldPath, type FieldValues} from \"react-hook-form\";\r\n\r\nimport {Label} from \"@/components/ui/label\";\r\nimport {cn} from \"@/lib/utilities\";\r\n\r\nconst Form = FormProvider;\r\n\r\ntype FormFieldContextValue<\r\n TFieldValues extends FieldValues = FieldValues,\r\n TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>,\r\n> = {\r\n name: TName;\r\n};\r\n\r\nconst FormFieldContext = React.createContext<FormFieldContextValue | null>(null);\r\n\r\nconst FormField = <TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({\r\n ...props\r\n}: ControllerProps<TFieldValues, TName>) => {\r\n return (\r\n <FormFieldContext.Provider value={{name: props.name}}>\r\n <Controller {...props} />\r\n </FormFieldContext.Provider>\r\n );\r\n};\r\n\r\nconst useFormField = () => {\r\n const fieldContext = React.useContext(FormFieldContext);\r\n const itemContext = React.useContext(FormItemContext);\r\n const {getFieldState, formState} = useFormContext();\r\n\r\n if (!fieldContext) {\r\n throw new Error(\"useFormField should be used within <FormField>\");\r\n }\r\n\r\n if (!itemContext) {\r\n throw new Error(\"useFormField should be used within <FormItem>\");\r\n }\r\n\r\n const fieldState = getFieldState(fieldContext.name, formState);\r\n\r\n const {id} = itemContext;\r\n\r\n return {\r\n id,\r\n name: fieldContext.name,\r\n formItemId: `${id}-form-item`,\r\n formDescriptionId: `${id}-form-item-description`,\r\n formMessageId: `${id}-form-item-message`,\r\n ...fieldState,\r\n };\r\n};\r\n\r\ntype FormItemContextValue = {\r\n id: string;\r\n};\r\n\r\nconst FormItemContext = React.createContext<FormItemContextValue | null>(null);\r\n\r\nconst FormItem = React.forwardRef<HTMLDivElement, React.HTMLAttributes<HTMLDivElement>>(({className, ...props}, ref) => {\r\n const id = React.useId();\r\n\r\n return (\r\n <FormItemContext.Provider value={{id}}>\r\n <div\r\n ref={ref}\r\n className={cn(\"space-y-2\", className)}\r\n {...props}\r\n />\r\n </FormItemContext.Provider>\r\n );\r\n});\r\nFormItem.displayName = \"FormItem\";\r\n\r\nconst FormLabel = React.forwardRef<\r\n React.ComponentRef<typeof LabelPrimitive.Root>,\r\n React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>\r\n>(({className, ...props}, ref) => {\r\n const {error, formItemId} = useFormField();\r\n\r\n return (\r\n <Label\r\n ref={ref}\r\n className={cn(error && \"text-red-500 dark:text-red-900\", className)}\r\n htmlFor={formItemId}\r\n {...props}\r\n />\r\n );\r\n});\r\nFormLabel.displayName = \"FormLabel\";\r\n\r\nconst FormControl = React.forwardRef<React.ComponentRef<typeof Slot>, React.ComponentPropsWithoutRef<typeof Slot>>(({...props}, ref) => {\r\n const {error, formItemId, formDescriptionId, formMessageId} = useFormField();\r\n\r\n return (\r\n <Slot\r\n ref={ref}\r\n id={formItemId}\r\n aria-describedby={error ? `${formDescriptionId} ${formMessageId}` : `${formDescriptionId}`}\r\n aria-invalid={Boolean(error)}\r\n {...props}\r\n />\r\n );\r\n});\r\nFormControl.displayName = \"FormControl\";\r\n\r\nconst FormDescription = React.forwardRef<HTMLParagraphElement, React.HTMLAttributes<HTMLParagraphElement>>(({className, ...props}, ref) => {\r\n const {formDescriptionId} = useFormField();\r\n\r\n return (\r\n <p\r\n ref={ref}\r\n id={formDescriptionId}\r\n className={cn(\"text-[0.8rem] text-neutral-500 dark:text-neutral-400\", className)}\r\n {...props}\r\n />\r\n );\r\n});\r\nFormDescription.displayName = \"FormDescription\";\r\n\r\nconst FormMessage = React.forwardRef<HTMLParagraphElement, React.HTMLAttributes<HTMLParagraphElement>>(\r\n ({className, children, ...props}, ref) => {\r\n const {error, formMessageId} = useFormField();\r\n const body = error ? String(error?.message ?? \"\") : children;\r\n\r\n if (!body) {\r\n return null;\r\n }\r\n\r\n return (\r\n <p\r\n ref={ref}\r\n id={formMessageId}\r\n className={cn(\"text-[0.8rem] font-medium text-red-500 dark:text-red-900\", className)}\r\n {...props}>\r\n {body}\r\n </p>\r\n );\r\n },\r\n);\r\nFormMessage.displayName = \"FormMessage\";\r\n\r\nexport {Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, useFormField};\r\n"],"names":["Form","FormProvider","FormFieldContext","React","FormField","props","Controller","useFormField","fieldContext","itemContext","FormItemContext","getFieldState","formState","useFormContext","Error","fieldState","id","FormItem","className","ref","cn","FormLabel","error","formItemId","Label","FormControl","formDescriptionId","formMessageId","Slot","Boolean","FormDescription","FormMessage","children","body","String"],"mappings":"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"}
1
+ {"version":3,"file":"components/ui/form.js","sources":["../../../src/components/ui/form.tsx"],"sourcesContent":["\"use client\";\r\n\r\n/* eslint-disable react/prop-types */\r\n\r\nimport * as React from \"react\";\r\nimport {Controller, FormProvider, useFormContext, type ControllerProps, type FieldPath, type FieldValues} from \"react-hook-form\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\n\r\nimport styles from \"./form.module.css\";\r\n\r\n/**\r\n * Provides the `react-hook-form` context to nested form primitives.\r\n *\r\n * @remarks\r\n * - Renders the `FormProvider` component from `react-hook-form`\r\n * - Built on `react-hook-form`\r\n *\r\n * @example\r\n * ```tsx\r\n * <Form {...form}>\r\n * <form>...</form>\r\n * </Form>\r\n * ```\r\n *\r\n * @see {@link https://react-hook-form.com/docs/formprovider | React Hook Form FormProvider Docs}\r\n */\r\nconst Form = Object.assign(FormProvider, {displayName: \"Form\"});\r\n\r\ntype FormControlElementProps = React.HTMLAttributes<HTMLElement> & {\r\n ref?: React.Ref<HTMLElement>;\r\n};\r\n\r\ninterface FormControlProps extends Omit<React.HTMLAttributes<HTMLElement>, \"children\"> {\r\n /**\r\n * Single form control element or fallback content to receive field accessibility attributes.\r\n * @default undefined\r\n */\r\n children: React.ReactNode;\r\n}\r\n\r\nfunction assignRef<TValue>(ref: React.Ref<TValue> | undefined, value: TValue | null): void {\r\n if (typeof ref === \"function\") {\r\n ref(value);\r\n return;\r\n }\r\n\r\n if (ref) {\r\n ref.current = value;\r\n }\r\n}\r\n\r\nfunction composeRefs<TValue>(...refs: Array<React.Ref<TValue> | undefined>): React.RefCallback<TValue> {\r\n return (value: TValue | null): void => {\r\n for (const ref of refs) {\r\n assignRef(ref, value);\r\n }\r\n };\r\n}\r\n\r\nfunction mergeAriaDescribedBy(...describedByValues: Array<string | undefined>): string | undefined {\r\n const tokens = describedByValues\r\n .flatMap((describedByValue) => describedByValue?.split(/\\s+/u) ?? [])\r\n .filter((token): token is string => token.length > 0);\r\n\r\n return tokens.length > 0 ? [...new Set(tokens)].join(\" \") : undefined;\r\n}\r\n\r\ntype FormFieldContextValue<\r\n TFieldValues extends FieldValues = FieldValues,\r\n TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>,\r\n> = {\r\n name: TName;\r\n};\r\n\r\nconst FormFieldContext = React.createContext<FormFieldContextValue | null>(null);\r\n\r\n/**\r\n * Binds a single field name to the shared form field context.\r\n *\r\n * @remarks\r\n * - Renders the `Controller` component from `react-hook-form`\r\n * - Built on `react-hook-form` controller primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <FormField\r\n * control={form.control}\r\n * name='email'\r\n * render={({field}) => <input {...field} />}\r\n * />\r\n * ```\r\n *\r\n * @see {@link https://react-hook-form.com/docs/usecontroller/controller | React Hook Form Controller Docs}\r\n */\r\nconst FormField = <TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({\r\n ...props\r\n}: ControllerProps<TFieldValues, TName>): React.JSX.Element => {\r\n return (\r\n <FormFieldContext.Provider value={{name: props.name}}>\r\n <Controller {...props} />\r\n </FormFieldContext.Provider>\r\n );\r\n};\r\n\r\ntype UseFormFieldReturn = {\r\n id: string;\r\n name: FieldPath<FieldValues>;\r\n formItemId: string;\r\n formDescriptionId: string;\r\n formMessageId: string;\r\n invalid: boolean;\r\n isDirty: boolean;\r\n isTouched: boolean;\r\n isValidating: boolean;\r\n error?: ReturnType<ReturnType<typeof useFormContext>[\"getFieldState\"]>[\"error\"];\r\n};\r\n\r\n/**\r\n * Returns the resolved form field metadata for nested form primitives.\r\n *\r\n * @remarks\r\n * Reads the nearest {@link FormField} and {@link FormItem} contexts, then combines them\r\n * with `react-hook-form` field state to expose stable IDs and validation metadata.\r\n *\r\n * @example\r\n * ```tsx\r\n * const field = useFormField();\r\n * ```\r\n *\r\n * @see {@link https://react-hook-form.com/docs/useformcontext | React Hook Form useFormContext Docs}\r\n */\r\nconst useFormField = (): UseFormFieldReturn => {\r\n const fieldContext = React.useContext(FormFieldContext);\r\n const itemContext = React.useContext(FormItemContext);\r\n const {getFieldState, formState} = useFormContext();\r\n\r\n if (!fieldContext) {\r\n throw new Error(\"useFormField should be used within <FormField>\");\r\n }\r\n\r\n if (!itemContext) {\r\n throw new Error(\"useFormField should be used within <FormItem>\");\r\n }\r\n\r\n const fieldState = getFieldState(fieldContext.name, formState);\r\n const {id} = itemContext;\r\n\r\n return {\r\n error: fieldState.error,\r\n formDescriptionId: `${id}-form-item-description`,\r\n formItemId: `${id}-form-item`,\r\n formMessageId: `${id}-form-item-message`,\r\n id,\r\n invalid: fieldState.invalid,\r\n isDirty: fieldState.isDirty,\r\n isTouched: fieldState.isTouched,\r\n isValidating: fieldState.isValidating,\r\n name: fieldContext.name as FieldPath<FieldValues>,\r\n };\r\n};\r\n\r\ntype FormItemContextValue = {\r\n id: string;\r\n};\r\n\r\nconst FormItemContext = React.createContext<FormItemContextValue | null>(null);\r\n\r\n/**\r\n * Wraps a label, control, description, and message into a single form item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element\r\n * - Built on the shared form item context\r\n *\r\n * @example\r\n * ```tsx\r\n * <FormItem>\r\n * <FormLabel>Email</FormLabel>\r\n * </FormItem>\r\n * ```\r\n *\r\n * @see {@link https://react-hook-form.com/docs/useformcontext | React Hook Form Docs}\r\n */\r\nconst FormItem = React.forwardRef<HTMLDivElement, React.HTMLAttributes<HTMLDivElement>>(({className, ...props}, ref) => {\r\n const id = React.useId();\r\n\r\n return (\r\n <FormItemContext.Provider value={{id}}>\r\n <div\r\n ref={ref}\r\n className={cn(styles.item, className)}\r\n {...props}\r\n />\r\n </FormItemContext.Provider>\r\n );\r\n});\r\nFormItem.displayName = \"FormItem\";\r\n\r\n/**\r\n * Renders the accessible label for the current form item.\r\n *\r\n * @remarks\r\n * - Renders a `<label>` element\r\n * - Built on the shared form field metadata hook\r\n *\r\n * @example\r\n * ```tsx\r\n * <FormLabel>Email</FormLabel>\r\n * ```\r\n *\r\n * @see {@link https://developer.mozilla.org/docs/Web/HTML/Element/label | HTML label element}\r\n */\r\nconst FormLabel = React.forwardRef<HTMLLabelElement, React.LabelHTMLAttributes<HTMLLabelElement>>(({className, ...props}, ref) => {\r\n const {error, formItemId} = useFormField();\r\n\r\n return (\r\n <label\r\n ref={ref}\r\n className={cn(error && styles.labelError, className)}\r\n htmlFor={formItemId}\r\n {...props}\r\n />\r\n );\r\n});\r\nFormLabel.displayName = \"FormLabel\";\r\n\r\n/**\r\n * Provides react-hook-form field metadata to a single control element.\r\n *\r\n * @remarks\r\n * This replaces the former Radix Slot-based implementation by cloning the\r\n * direct child element and merging the accessibility attributes required by the\r\n * surrounding form primitives. A fallback wrapper is rendered only when the\r\n * child is not a valid React element.\r\n */\r\nconst FormControl = React.forwardRef<HTMLElement, FormControlProps>(\r\n ({children, ...props}: Readonly<FormControlProps>, ref): React.JSX.Element => {\r\n const {error, formDescriptionId, formItemId, formMessageId} = useFormField();\r\n const describedBy = mergeAriaDescribedBy(\r\n typeof props[\"aria-describedby\"] === \"string\" ? props[\"aria-describedby\"] : undefined,\r\n formDescriptionId,\r\n error ? formMessageId : undefined,\r\n );\r\n\r\n if (React.isValidElement(children)) {\r\n const child = children as React.ReactElement<FormControlElementProps>;\r\n const childDescribedBy = typeof child.props[\"aria-describedby\"] === \"string\" ? child.props[\"aria-describedby\"] : undefined;\r\n\r\n // eslint-disable-next-line react-x/no-clone-element -- removes Radix Slot while preserving child element semantics\r\n return React.cloneElement(child, {\r\n ...props,\r\n ref: composeRefs(ref, child.props.ref),\r\n id: formItemId,\r\n \"aria-describedby\": mergeAriaDescribedBy(childDescribedBy, describedBy),\r\n \"aria-invalid\": Boolean(error),\r\n });\r\n }\r\n\r\n return (\r\n <div\r\n ref={ref as React.Ref<HTMLDivElement>}\r\n id={formItemId}\r\n aria-describedby={describedBy}\r\n aria-invalid={Boolean(error)}\r\n {...props}>\r\n {children}\r\n </div>\r\n );\r\n },\r\n);\r\nFormControl.displayName = \"FormControl\";\r\n\r\n/**\r\n * Renders helper text that describes the current form control.\r\n *\r\n * @remarks\r\n * - Renders a `<p>` element\r\n * - Built on the shared form field metadata hook\r\n *\r\n * @example\r\n * ```tsx\r\n * <FormDescription>We'll never share your email.</FormDescription>\r\n * ```\r\n *\r\n * @see {@link https://developer.mozilla.org/docs/Web/HTML/Element/p | HTML paragraph element}\r\n */\r\nconst FormDescription = React.forwardRef<HTMLParagraphElement, React.HTMLAttributes<HTMLParagraphElement>>(({className, ...props}, ref) => {\r\n const {formDescriptionId} = useFormField();\r\n\r\n return (\r\n <p\r\n ref={ref}\r\n id={formDescriptionId}\r\n className={cn(styles.description, className)}\r\n {...props}\r\n />\r\n );\r\n});\r\nFormDescription.displayName = \"FormDescription\";\r\n\r\n/**\r\n * Renders the validation message or fallback message for the current form control.\r\n *\r\n * @remarks\r\n * - Renders a `<p>` element when content is available\r\n * - Built on the shared form field metadata hook\r\n *\r\n * @example\r\n * ```tsx\r\n * <FormMessage />\r\n * ```\r\n *\r\n * @see {@link https://developer.mozilla.org/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-invalid | ARIA invalid state}\r\n */\r\nconst FormMessage = React.forwardRef<HTMLParagraphElement, React.HTMLAttributes<HTMLParagraphElement>>(\r\n ({className, children, ...props}, ref) => {\r\n const {error, formMessageId} = useFormField();\r\n const body = error ? String(error.message ?? \"\") : children;\r\n\r\n if (!body) {\r\n return null;\r\n }\r\n\r\n return (\r\n <p\r\n ref={ref}\r\n id={formMessageId}\r\n className={cn(styles.message, className)}\r\n {...props}>\r\n {body}\r\n </p>\r\n );\r\n },\r\n);\r\nFormMessage.displayName = \"FormMessage\";\r\nFormField.displayName = \"FormField\";\r\n\r\nexport {Controller, useController, useFieldArray, useForm, useFormContext, useFormState, useWatch} from \"react-hook-form\";\r\nexport type {\r\n Control,\r\n ControllerFieldState,\r\n ControllerProps,\r\n ControllerRenderProps,\r\n DefaultValues,\r\n FieldError,\r\n FieldErrors,\r\n FieldPath,\r\n FieldValues,\r\n Path,\r\n RegisterOptions,\r\n Resolver,\r\n SubmitHandler,\r\n UseControllerReturn,\r\n UseFieldArrayReturn,\r\n UseFormReturn,\r\n} from \"react-hook-form\";\r\nexport {Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, useFormField};\r\nexport type {FormControlProps};\r\n"],"names":["Form","Object","FormProvider","assignRef","ref","value","composeRefs","refs","mergeAriaDescribedBy","describedByValues","tokens","describedByValue","token","Set","undefined","FormFieldContext","React","FormField","props","Controller","useFormField","fieldContext","itemContext","FormItemContext","getFieldState","formState","useFormContext","Error","fieldState","id","FormItem","className","cn","styles","FormLabel","error","formItemId","FormControl","children","formDescriptionId","formMessageId","describedBy","child","childDescribedBy","Boolean","FormDescription","FormMessage","body","String"],"mappings":"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"}
@@ -0,0 +1,10 @@
1
+ import "./form_module.css";
2
+ const form_module = {
3
+ item: "item-kXRJ67",
4
+ labelError: "labelError-R0Bie6",
5
+ description: "description-yOLp5t",
6
+ message: "message-yxAxP5"
7
+ };
8
+ export default form_module;
9
+
10
+ //# sourceMappingURL=form.module.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components/ui/form.module.js","sources":["../../../src/components/ui/form.module.css"],"sourcesContent":["// extracted by LIB_CSS_EXTRACT_LOADER\nimport \"./form_module.css\"\nexport default {\"item\":\"item-kXRJ67\",\"labelError\":\"labelError-R0Bie6\",\"description\":\"description-yOLp5t\",\"message\":\"message-yxAxP5\"};"],"names":[],"mappings":";AAEA,oBAAe;IAAC,MAAO;IAAc,YAAa;IAAoB,aAAc;IAAqB,SAAU;AAAgB"}
@@ -0,0 +1,22 @@
1
+ .item-kXRJ67 {
2
+ gap: var(--ac-space-2);
3
+ display: grid;
4
+ }
5
+
6
+ .labelError-R0Bie6 {
7
+ color: var(--ac-destructive);
8
+ }
9
+
10
+ .description-yOLp5t {
11
+ color: var(--ac-muted-foreground);
12
+ font-size: .8rem;
13
+ }
14
+
15
+ .message-yxAxP5 {
16
+ color: var(--ac-destructive);
17
+ font-size: .8rem;
18
+ font-weight: 500;
19
+ }
20
+
21
+
22
+ /*# sourceMappingURL=form_module.css.map */
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["webpack://./home/runner/work/arolariu.ro/arolariu.ro/packages/components/src/components/ui/form.module.css","webpack://./src/components/ui/form.module.css"],"names":[],"mappings":"AADA;ECEE,sBAAsB;EACtB,aAAa;AACf;;AAEA;EACE,4BAA4B;AAC9B;;AAEA;EACE,iCAAiC;EACjC,gBAAgB;AAClB;;AAEA;EACE,4BAA4B;EAC5B,gBAAgB;EAChB,gBAAgB;AAClB","sourcesContent":[".item{display:grid;gap:var(--ac-space-2)}.labelError{color:var(--ac-destructive)}.description{color:var(--ac-muted-foreground);font-size:.8rem}.message{color:var(--ac-destructive);font-size:.8rem;font-weight:500}",".item {\n gap: var(--ac-space-2);\n display: grid;\n}\n\n.labelError {\n color: var(--ac-destructive);\n}\n\n.description {\n color: var(--ac-muted-foreground);\n font-size: .8rem;\n}\n\n.message {\n color: var(--ac-destructive);\n font-size: .8rem;\n font-weight: 500;\n}\n"],"sourceRoot":""}
@@ -1,8 +1,26 @@
1
- import { HTMLMotionProps, type Transition } from "motion/react";
1
+ import { type HTMLMotionProps, type Transition } from "motion/react";
2
2
  import * as React from "react";
3
- interface GradientBackgroundProps extends HTMLMotionProps<"div"> {
3
+ /** Props accepted by {@link GradientBackground}. */
4
+ export interface GradientBackgroundProps extends HTMLMotionProps<"div"> {
5
+ /** Motion timing used for the animated background-position sweep. @default {duration: 15, ease: "easeInOut", repeat: Infinity} */
4
6
  transition?: Transition;
5
7
  }
8
+ /**
9
+ * Renders a continuously shifting multicolor gradient background.
10
+ *
11
+ * @remarks
12
+ * - Animated component using the `motion` library
13
+ * - Renders a `<div>` element
14
+ * - Styling via CSS Modules with `--ac-*` custom properties
15
+ * - Client-side only (`"use client"` directive)
16
+ *
17
+ * @example
18
+ * ```tsx
19
+ * <GradientBackground />
20
+ * ```
21
+ *
22
+ * @see {@link GradientBackgroundProps} for available props
23
+ */
6
24
  declare const GradientBackground: React.ForwardRefExoticComponent<Omit<GradientBackgroundProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
7
- export { GradientBackground, type GradientBackgroundProps };
25
+ export { GradientBackground };
8
26
  //# sourceMappingURL=gradient-background.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"gradient-background.d.ts","sourceRoot":"","sources":["../../../src/components/ui/gradient-background.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAC,eAAe,EAAU,KAAK,UAAU,EAAC,MAAM,cAAc,CAAC;AACtE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,UAAU,uBAAwB,SAAQ,eAAe,CAAC,KAAK,CAAC;IAC9D,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAED,QAAA,MAAM,kBAAkB,6GAcvB,CAAC;AAIF,OAAO,EAAC,kBAAkB,EAAE,KAAK,uBAAuB,EAAC,CAAC"}
1
+ {"version":3,"file":"gradient-background.d.ts","sourceRoot":"","sources":["../../../src/components/ui/gradient-background.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAS,KAAK,eAAe,EAAE,KAAK,UAAU,EAAC,MAAM,cAAc,CAAC;AAC3E,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,oDAAoD;AACpD,MAAM,WAAW,uBAAwB,SAAQ,eAAe,CAAC,KAAK,CAAC;IACrE,kIAAkI;IAClI,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAED;;;;;;;;;;;;;;;GAeG;AACH,QAAA,MAAM,kBAAkB,6GAiBvB,CAAC;AAIF,OAAO,EAAC,kBAAkB,EAAC,CAAC"}
@@ -3,13 +3,16 @@ import { jsx } from "react/jsx-runtime";
3
3
  import { motion } from "motion/react";
4
4
  import { forwardRef } from "react";
5
5
  import { cn } from "../../lib/utilities.js";
6
+ import gradient_background_module from "./gradient-background.module.js";
6
7
  const GradientBackground = /*#__PURE__*/ forwardRef(({ className, transition = {
7
8
  duration: 15,
8
9
  ease: "easeInOut",
9
10
  repeat: 1 / 0
10
- }, ...props }, ref)=>/*#__PURE__*/ jsx(motion.div, {
11
+ }, ...props }, ref)=>{
12
+ const { key: _ignoredKey, ...restProps } = props;
13
+ return /*#__PURE__*/ jsx(motion.div, {
11
14
  ref: ref,
12
- className: cn("size-full bg-gradient-to-br from-blue-500 via-purple-500 to-pink-500 bg-[length:400%_400%]", className),
15
+ className: cn(gradient_background_module.root, className),
13
16
  animate: {
14
17
  backgroundPosition: [
15
18
  "0% 50%",
@@ -18,8 +21,9 @@ const GradientBackground = /*#__PURE__*/ forwardRef(({ className, transition = {
18
21
  ]
19
22
  },
20
23
  transition: transition,
21
- ...props
22
- }));
24
+ ...restProps
25
+ });
26
+ });
23
27
  GradientBackground.displayName = "GradientBackground";
24
28
  export { GradientBackground };
25
29
 
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/gradient-background.js","sources":["../../../src/components/ui/gradient-background.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {HTMLMotionProps, motion, type Transition} from \"motion/react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\n\r\ninterface GradientBackgroundProps extends HTMLMotionProps<\"div\"> {\r\n transition?: Transition;\r\n}\r\n\r\nconst GradientBackground = React.forwardRef<HTMLDivElement, GradientBackgroundProps>(\r\n ({className, transition = {duration: 15, ease: \"easeInOut\", repeat: Infinity}, ...props}, ref) => {\r\n return (\r\n <motion.div\r\n ref={ref}\r\n className={cn(\"size-full bg-gradient-to-br from-blue-500 via-purple-500 to-pink-500 bg-[length:400%_400%]\", className)}\r\n animate={{\r\n backgroundPosition: [\"0% 50%\", \"100% 50%\", \"0% 50%\"],\r\n }}\r\n transition={transition}\r\n {...props}\r\n />\r\n );\r\n },\r\n);\r\n\r\nGradientBackground.displayName = \"GradientBackground\";\r\n\r\nexport {GradientBackground, type GradientBackgroundProps};\r\n"],"names":["GradientBackground","React","className","transition","Infinity","props","ref","motion","cn"],"mappings":";;;;;AAWA,MAAMA,qBAAqB,WAArBA,GAAqBC,WACzB,CAAC,EAACC,SAAS,EAAEC,aAAa;IAAC,UAAU;IAAI,MAAM;IAAa,QAAQC;AAAQ,CAAC,EAAE,GAAGC,OAAM,EAAEC,MACjF,WAAP,GACE,IAACC,OAAO,GAAG;QACT,KAAKD;QACL,WAAWE,GAAG,8FAA8FN;QAC5G,SAAS;YACP,oBAAoB;gBAAC;gBAAU;gBAAY;aAAS;QACtD;QACA,YAAYC;QACX,GAAGE,KAAK;;AAMjBL,mBAAmB,WAAW,GAAG"}
1
+ {"version":3,"file":"components/ui/gradient-background.js","sources":["../../../src/components/ui/gradient-background.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {motion, type HTMLMotionProps, type Transition} from \"motion/react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./gradient-background.module.css\";\r\n\r\n/** Props accepted by {@link GradientBackground}. */\r\nexport interface GradientBackgroundProps extends HTMLMotionProps<\"div\"> {\r\n /** Motion timing used for the animated background-position sweep. @default {duration: 15, ease: \"easeInOut\", repeat: Infinity} */\r\n transition?: Transition;\r\n}\r\n\r\n/**\r\n * Renders a continuously shifting multicolor gradient background.\r\n *\r\n * @remarks\r\n * - Animated component using the `motion` library\r\n * - Renders a `<div>` element\r\n * - Styling via CSS Modules with `--ac-*` custom properties\r\n * - Client-side only (`\"use client\"` directive)\r\n *\r\n * @example\r\n * ```tsx\r\n * <GradientBackground />\r\n * ```\r\n *\r\n * @see {@link GradientBackgroundProps} for available props\r\n */\r\nconst GradientBackground = React.forwardRef<HTMLDivElement, GradientBackgroundProps>(\r\n ({className, transition = {duration: 15, ease: \"easeInOut\", repeat: Infinity}, ...props}, ref) => {\r\n // eslint-disable-next-line sonarjs/no-unused-vars -- removing React key avoids implicit key spreading\r\n const {key: _ignoredKey, ...restProps} = props;\r\n\r\n return (\r\n <motion.div\r\n ref={ref}\r\n className={cn(styles.root, className)}\r\n animate={{\r\n backgroundPosition: [\"0% 50%\", \"100% 50%\", \"0% 50%\"],\r\n }}\r\n transition={transition}\r\n {...restProps}\r\n />\r\n );\r\n },\r\n);\r\n\r\nGradientBackground.displayName = \"GradientBackground\";\r\n\r\nexport {GradientBackground};\r\n"],"names":["GradientBackground","React","className","transition","Infinity","props","ref","_ignoredKey","restProps","motion","cn","styles"],"mappings":";;;;;;AA8BA,MAAMA,qBAAqB,WAAHA,GAAGC,WACzB,CAAC,EAACC,SAAS,EAAEC,aAAa;IAAC,UAAU;IAAI,MAAM;IAAa,QAAQC;AAAQ,CAAC,EAAE,GAAGC,OAAM,EAAEC;IAExF,MAAM,EAAC,KAAKC,WAAW,EAAE,GAAGC,WAAU,GAAGH;IAEzC,OAAO,WAAP,GACE,IAACI,OAAO,GAAG;QACT,KAAKH;QACL,WAAWI,GAAGC,2BAAAA,IAAW,EAAET;QAC3B,SAAS;YACP,oBAAoB;gBAAC;gBAAU;gBAAY;aAAS;QACtD;QACA,YAAYC;QACX,GAAGK,SAAS;;AAGnB;AAGFR,mBAAmB,WAAW,GAAG"}
@@ -0,0 +1,7 @@
1
+ import "./gradient-background_module.css";
2
+ const gradient_background_module = {
3
+ root: "root-k726lA"
4
+ };
5
+ export default gradient_background_module;
6
+
7
+ //# sourceMappingURL=gradient-background.module.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components/ui/gradient-background.module.js","sources":["../../../src/components/ui/gradient-background.module.css"],"sourcesContent":["// extracted by LIB_CSS_EXTRACT_LOADER\nimport \"./gradient-background_module.css\"\nexport default {\"root\":\"root-k726lA\"};"],"names":[],"mappings":";AAEA,mCAAe;IAAC,MAAO;AAAa"}
@@ -0,0 +1,9 @@
1
+ .root-k726lA {
2
+ background-image: linear-gradient(135deg, #3b82f6, #a855f7 50%, #ec4899);
3
+ background-size: 400% 400%;
4
+ width: 100%;
5
+ height: 100%;
6
+ }
7
+
8
+
9
+ /*# sourceMappingURL=gradient-background_module.css.map */
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["webpack://./home/runner/work/arolariu.ro/arolariu.ro/packages/components/src/components/ui/gradient-background.module.css","webpack://./src/components/ui/gradient-background.module.css"],"names":[],"mappings":"AADA;ECEE,wEAAwE;EACxE,0BAA0B;EAC1B,WAAW;EACX,YAAY;AACd","sourcesContent":[".root{background-image:linear-gradient(135deg,#3b82f6,#a855f7 50%,#ec4899);background-size:400% 400%;height:100%;width:100%}",".root {\n background-image: linear-gradient(135deg, #3b82f6, #a855f7 50%, #ec4899);\n background-size: 400% 400%;\n width: 100%;\n height: 100%;\n}\n"],"sourceRoot":""}
@@ -1,11 +1,32 @@
1
1
  import { type Transition } from "motion/react";
2
2
  import * as React from "react";
3
- interface GradientTextProps extends React.HTMLAttributes<HTMLSpanElement> {
3
+ /** Props accepted by {@link GradientText}. */
4
+ export interface GradientTextProps extends React.HTMLAttributes<HTMLSpanElement> {
5
+ /** Text content rendered with the animated gradient fill. @default undefined */
4
6
  text: string;
7
+ /** CSS gradient string assigned to the animated text fill. @default "linear-gradient(90deg, #3b82f6 0%, #a855f7 20%, #ec4899 50%, #a855f7 80%, #3b82f6 100%)" */
5
8
  gradient?: string;
9
+ /** Adds a blurred neon duplicate behind the primary text layer. @default false */
6
10
  neon?: boolean;
11
+ /** Motion timing used for the animated gradient background. @default {duration: 50, repeat: Infinity, ease: "linear"} */
7
12
  transition?: Transition;
8
13
  }
14
+ /**
15
+ * Renders animated gradient-filled text with an optional neon glow layer.
16
+ *
17
+ * @remarks
18
+ * - Animated component using the `motion` library
19
+ * - Renders a `<span>` element
20
+ * - Styling via CSS Modules with `--ac-*` custom properties
21
+ * - Client-side only (`"use client"` directive)
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * <GradientText text="Launch ready" />
26
+ * ```
27
+ *
28
+ * @see {@link GradientTextProps} for available props
29
+ */
9
30
  declare const GradientText: React.ForwardRefExoticComponent<GradientTextProps & React.RefAttributes<HTMLSpanElement>>;
10
- export { GradientText, type GradientTextProps };
31
+ export { GradientText };
11
32
  //# sourceMappingURL=gradient-text.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"gradient-text.d.ts","sourceRoot":"","sources":["../../../src/components/ui/gradient-text.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAS,KAAK,UAAU,EAAC,MAAM,cAAc,CAAC;AACrD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,UAAU,iBAAkB,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IACvE,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAED,QAAA,MAAM,YAAY,2FA2CjB,CAAC;AAIF,OAAO,EAAC,YAAY,EAAE,KAAK,iBAAiB,EAAC,CAAC"}
1
+ {"version":3,"file":"gradient-text.d.ts","sourceRoot":"","sources":["../../../src/components/ui/gradient-text.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAS,KAAK,UAAU,EAAC,MAAM,cAAc,CAAC;AACrD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,8CAA8C;AAC9C,MAAM,WAAW,iBAAkB,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IAC9E,gFAAgF;IAChF,IAAI,EAAE,MAAM,CAAC;IACb,iKAAiK;IACjK,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,kFAAkF;IAClF,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,yHAAyH;IACzH,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAMD;;;;;;;;;;;;;;;GAeG;AACH,QAAA,MAAM,YAAY,2FA4CjB,CAAC;AAIF,OAAO,EAAC,YAAY,EAAC,CAAC"}
@@ -3,21 +3,22 @@ import { jsx, jsxs } from "react/jsx-runtime";
3
3
  import { motion } from "motion/react";
4
4
  import { forwardRef } from "react";
5
5
  import { cn } from "../../lib/utilities.js";
6
+ import gradient_text_module from "./gradient-text.module.js";
6
7
  const GradientText = /*#__PURE__*/ forwardRef(({ text, className, gradient = "linear-gradient(90deg, #3b82f6 0%, #a855f7 20%, #ec4899 50%, #a855f7 80%, #3b82f6 100%)", neon = false, transition = {
7
8
  duration: 50,
8
9
  repeat: 1 / 0,
9
10
  ease: "linear"
10
11
  }, ...props }, ref)=>{
11
12
  const baseStyle = {
12
- backgroundImage: gradient
13
+ "--ac-gradient-text-background": gradient
13
14
  };
14
15
  return /*#__PURE__*/ jsxs("span", {
15
16
  ref: ref,
16
- className: cn("relative inline-block", className),
17
+ className: cn(gradient_text_module.root, className),
17
18
  ...props,
18
19
  children: [
19
20
  /*#__PURE__*/ jsx(motion.span, {
20
- className: "m-0 bg-[length:700%_100%] bg-clip-text bg-[position:0%_0%] text-transparent",
21
+ className: gradient_text_module.text,
21
22
  style: baseStyle,
22
23
  initial: {
23
24
  backgroundPosition: "0% 0%"
@@ -28,8 +29,9 @@ const GradientText = /*#__PURE__*/ forwardRef(({ text, className, gradient = "li
28
29
  transition: transition,
29
30
  children: text
30
31
  }),
31
- Boolean(neon) && /*#__PURE__*/ jsx(motion.span, {
32
- className: "absolute top-0 left-0 m-0 bg-[length:700%_100%] bg-clip-text bg-[position:0%_0%] text-transparent mix-blend-plus-lighter blur-[8px]",
32
+ neon ? /*#__PURE__*/ jsx(motion.span, {
33
+ "aria-hidden": "true",
34
+ className: gradient_text_module.neon,
33
35
  style: baseStyle,
34
36
  initial: {
35
37
  backgroundPosition: "0% 0%"
@@ -39,7 +41,7 @@ const GradientText = /*#__PURE__*/ forwardRef(({ text, className, gradient = "li
39
41
  },
40
42
  transition: transition,
41
43
  children: text
42
- })
44
+ }) : null
43
45
  ]
44
46
  });
45
47
  });
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/gradient-text.js","sources":["../../../src/components/ui/gradient-text.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {motion, type Transition} from \"motion/react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\n\r\ninterface GradientTextProps extends React.HTMLAttributes<HTMLSpanElement> {\r\n text: string;\r\n gradient?: string;\r\n neon?: boolean;\r\n transition?: Transition;\r\n}\r\n\r\nconst GradientText = React.forwardRef<HTMLSpanElement, GradientTextProps>(\r\n (\r\n {\r\n text,\r\n className,\r\n gradient = \"linear-gradient(90deg, #3b82f6 0%, #a855f7 20%, #ec4899 50%, #a855f7 80%, #3b82f6 100%)\",\r\n neon = false,\r\n transition = {duration: 50, repeat: Infinity, ease: \"linear\"},\r\n ...props\r\n },\r\n ref,\r\n ) => {\r\n const baseStyle: React.CSSProperties = {\r\n backgroundImage: gradient,\r\n };\r\n\r\n return (\r\n <span\r\n ref={ref}\r\n className={cn(\"relative inline-block\", className)}\r\n {...props}>\r\n <motion.span\r\n className='m-0 bg-[length:700%_100%] bg-clip-text bg-[position:0%_0%] text-transparent'\r\n style={baseStyle}\r\n initial={{backgroundPosition: \"0% 0%\"}}\r\n animate={{backgroundPosition: \"500% 100%\"}}\r\n transition={transition}>\r\n {text}\r\n </motion.span>\r\n\r\n {Boolean(neon) && (\r\n <motion.span\r\n className='absolute top-0 left-0 m-0 bg-[length:700%_100%] bg-clip-text bg-[position:0%_0%] text-transparent mix-blend-plus-lighter blur-[8px]'\r\n style={baseStyle}\r\n initial={{backgroundPosition: \"0% 0%\"}}\r\n animate={{backgroundPosition: \"500% 100%\"}}\r\n transition={transition}>\r\n {text}\r\n </motion.span>\r\n )}\r\n </span>\r\n );\r\n },\r\n);\r\n\r\nGradientText.displayName = \"GradientText\";\r\n\r\nexport {GradientText, type GradientTextProps};\r\n"],"names":["GradientText","React","text","className","gradient","neon","transition","Infinity","props","ref","baseStyle","cn","motion","Boolean"],"mappings":";;;;;AAcA,MAAMA,eAAe,WAAfA,GAAeC,WACnB,CACE,EACEC,IAAI,EACJC,SAAS,EACTC,WAAW,yFAAyF,EACpGC,OAAO,KAAK,EACZC,aAAa;IAAC,UAAU;IAAI,QAAQC;IAAU,MAAM;AAAQ,CAAC,EAC7D,GAAGC,OACJ,EACDC;IAEA,MAAMC,YAAiC;QACrC,iBAAiBN;IACnB;IAEA,OAAO,WAAP,GACE,KAAC;QACC,KAAKK;QACL,WAAWE,GAAG,yBAAyBR;QACtC,GAAGK,KAAK;;0BACT,IAACI,OAAO,IAAI;gBACV,WAAU;gBACV,OAAOF;gBACP,SAAS;oBAAC,oBAAoB;gBAAO;gBACrC,SAAS;oBAAC,oBAAoB;gBAAW;gBACzC,YAAYJ;0BACXJ;;YAGFW,QAAQR,SAAS,WAATA,GACP,IAACO,OAAO,IAAI;gBACV,WAAU;gBACV,OAAOF;gBACP,SAAS;oBAAC,oBAAoB;gBAAO;gBACrC,SAAS;oBAAC,oBAAoB;gBAAW;gBACzC,YAAYJ;0BACXJ;;;;AAKX;AAGFF,aAAa,WAAW,GAAG"}
1
+ {"version":3,"file":"components/ui/gradient-text.js","sources":["../../../src/components/ui/gradient-text.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {motion, type Transition} from \"motion/react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./gradient-text.module.css\";\r\n\r\n/** Props accepted by {@link GradientText}. */\r\nexport interface GradientTextProps extends React.HTMLAttributes<HTMLSpanElement> {\r\n /** Text content rendered with the animated gradient fill. @default undefined */\r\n text: string;\r\n /** CSS gradient string assigned to the animated text fill. @default \"linear-gradient(90deg, #3b82f6 0%, #a855f7 20%, #ec4899 50%, #a855f7 80%, #3b82f6 100%)\" */\r\n gradient?: string;\r\n /** Adds a blurred neon duplicate behind the primary text layer. @default false */\r\n neon?: boolean;\r\n /** Motion timing used for the animated gradient background. @default {duration: 50, repeat: Infinity, ease: \"linear\"} */\r\n transition?: Transition;\r\n}\r\n\r\ntype GradientStyleProperties = React.CSSProperties & {\r\n \"--ac-gradient-text-background\": string;\r\n};\r\n\r\n/**\r\n * Renders animated gradient-filled text with an optional neon glow layer.\r\n *\r\n * @remarks\r\n * - Animated component using the `motion` library\r\n * - Renders a `<span>` element\r\n * - Styling via CSS Modules with `--ac-*` custom properties\r\n * - Client-side only (`\"use client\"` directive)\r\n *\r\n * @example\r\n * ```tsx\r\n * <GradientText text=\"Launch ready\" />\r\n * ```\r\n *\r\n * @see {@link GradientTextProps} for available props\r\n */\r\nconst GradientText = React.forwardRef<HTMLSpanElement, GradientTextProps>(\r\n (\r\n {\r\n text,\r\n className,\r\n gradient = \"linear-gradient(90deg, #3b82f6 0%, #a855f7 20%, #ec4899 50%, #a855f7 80%, #3b82f6 100%)\",\r\n neon = false,\r\n transition = {duration: 50, repeat: Infinity, ease: \"linear\"},\r\n ...props\r\n },\r\n ref,\r\n ) => {\r\n const baseStyle: GradientStyleProperties = {\r\n \"--ac-gradient-text-background\": gradient,\r\n };\r\n\r\n return (\r\n <span\r\n ref={ref}\r\n className={cn(styles.root, className)}\r\n {...props}>\r\n <motion.span\r\n className={styles.text}\r\n style={baseStyle}\r\n initial={{backgroundPosition: \"0% 0%\"}}\r\n animate={{backgroundPosition: \"500% 100%\"}}\r\n transition={transition}>\r\n {text}\r\n </motion.span>\r\n\r\n {neon ? (\r\n <motion.span\r\n aria-hidden='true'\r\n className={styles.neon}\r\n style={baseStyle}\r\n initial={{backgroundPosition: \"0% 0%\"}}\r\n animate={{backgroundPosition: \"500% 100%\"}}\r\n transition={transition}>\r\n {text}\r\n </motion.span>\r\n ) : null}\r\n </span>\r\n );\r\n },\r\n);\r\n\r\nGradientText.displayName = \"GradientText\";\r\n\r\nexport {GradientText};\r\n"],"names":["GradientText","React","text","className","gradient","neon","transition","Infinity","props","ref","baseStyle","cn","styles","motion"],"mappings":";;;;;;AAwCA,MAAMA,eAAe,WAAHA,GAAGC,WACnB,CACE,EACEC,IAAI,EACJC,SAAS,EACTC,WAAW,yFAAyF,EACpGC,OAAO,KAAK,EACZC,aAAa;IAAC,UAAU;IAAI,QAAQC;IAAU,MAAM;AAAQ,CAAC,EAC7D,GAAGC,OACJ,EACDC;IAEA,MAAMC,YAAqC;QACzC,iCAAiCN;IACnC;IAEA,OAAO,WAAP,GACE,KAAC;QACC,KAAKK;QACL,WAAWE,GAAGC,qBAAAA,IAAW,EAAET;QAC1B,GAAGK,KAAK;;0BACT,IAACK,OAAO,IAAI;gBACV,WAAWD,qBAAAA,IAAW;gBACtB,OAAOF;gBACP,SAAS;oBAAC,oBAAoB;gBAAO;gBACrC,SAAS;oBAAC,oBAAoB;gBAAW;gBACzC,YAAYJ;0BACXJ;;YAGFG,OAAO,WAAPA,GACC,IAACQ,OAAO,IAAI;gBACV,eAAY;gBACZ,WAAWD,qBAAAA,IAAW;gBACtB,OAAOF;gBACP,SAAS;oBAAC,oBAAoB;gBAAO;gBACrC,SAAS;oBAAC,oBAAoB;gBAAW;gBACzC,YAAYJ;0BACXJ;iBAED;;;AAGV;AAGFF,aAAa,WAAW,GAAG"}
@@ -0,0 +1,9 @@
1
+ import "./gradient-text_module.css";
2
+ const gradient_text_module = {
3
+ root: "root-lzRVsJ",
4
+ neon: "neon-gZ2mQJ",
5
+ text: "text-P04R0z"
6
+ };
7
+ export default gradient_text_module;
8
+
9
+ //# sourceMappingURL=gradient-text.module.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components/ui/gradient-text.module.js","sources":["../../../src/components/ui/gradient-text.module.css"],"sourcesContent":["// extracted by LIB_CSS_EXTRACT_LOADER\nimport \"./gradient-text_module.css\"\nexport default {\"root\":\"root-lzRVsJ\",\"neon\":\"neon-gZ2mQJ\",\"text\":\"text-P04R0z\"};"],"names":[],"mappings":";AAEA,6BAAe;IAAC,MAAO;IAAc,MAAO;IAAc,MAAO;AAAa"}
@@ -0,0 +1,24 @@
1
+ .root-lzRVsJ {
2
+ display: inline-block;
3
+ position: relative;
4
+ }
5
+
6
+ .neon-gZ2mQJ, .text-P04R0z {
7
+ background-clip: text;
8
+ background-image: var(--ac-gradient-text-background);
9
+ color: #0000;
10
+ background-position: 0 0;
11
+ background-size: 700% 100%;
12
+ margin: 0;
13
+ }
14
+
15
+ .neon-gZ2mQJ {
16
+ filter: blur(8px);
17
+ mix-blend-mode: plus-lighter;
18
+ pointer-events: none;
19
+ position: absolute;
20
+ inset: 0;
21
+ }
22
+
23
+
24
+ /*# sourceMappingURL=gradient-text_module.css.map */
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["webpack://./home/runner/work/arolariu.ro/arolariu.ro/packages/components/src/components/ui/gradient-text.module.css","webpack://./src/components/ui/gradient-text.module.css"],"names":[],"mappings":"AADA;ECEE,qBAAqB;EACrB,kBAAkB;AACpB;;AAEA;EACE,qBAAqB;EACrB,oDAAoD;EACpD,YAAY;EACZ,wBAAwB;EACxB,0BAA0B;EAC1B,SAAS;AACX;;AAEA;EACE,iBAAiB;EACjB,4BAA4B;EAC5B,oBAAoB;EACpB,kBAAkB;EAClB,QAAQ;AACV","sourcesContent":[".root{display:inline-block;position:relative}.neon,.text{-webkit-background-clip:text;background-clip:text;background-image:var(--ac-gradient-text-background);background-position:0 0;background-size:700% 100%;color:transparent;margin:0}.neon{filter:blur(8px);inset:0;mix-blend-mode:plus-lighter;pointer-events:none;position:absolute}",".root {\n display: inline-block;\n position: relative;\n}\n\n.neon, .text {\n background-clip: text;\n background-image: var(--ac-gradient-text-background);\n color: #0000;\n background-position: 0 0;\n background-size: 700% 100%;\n margin: 0;\n}\n\n.neon {\n filter: blur(8px);\n mix-blend-mode: plus-lighter;\n pointer-events: none;\n position: absolute;\n inset: 0;\n}\n"],"sourceRoot":""}
@@ -1,12 +1,34 @@
1
1
  import { type HTMLMotionProps, type Transition, type UseInViewOptions } from "motion/react";
2
2
  import * as React from "react";
3
- interface HighlightTextProps extends HTMLMotionProps<"span"> {
3
+ /** Props accepted by {@link HighlightText}. */
4
+ export interface HighlightTextProps extends HTMLMotionProps<"span"> {
5
+ /** Inline text content that receives the animated highlight sweep. @default undefined */
4
6
  text: string;
7
+ /** Delays the highlight animation until the text enters the viewport. @default false */
5
8
  inView?: boolean;
9
+ /** Margin passed to the in-view observer when `inView` is enabled. @default "0px" */
6
10
  inViewMargin?: UseInViewOptions["margin"];
11
+ /** Prevents the in-view animation from replaying after the first reveal. @default true */
7
12
  inViewOnce?: boolean;
13
+ /** Motion timing used for the highlight fill animation. @default {duration: 2, ease: "easeInOut"} */
8
14
  transition?: Transition;
9
15
  }
16
+ /**
17
+ * Animates a gradient highlight fill behind inline text content.
18
+ *
19
+ * @remarks
20
+ * - Animated component using the `motion` library
21
+ * - Renders a `<span>` element
22
+ * - Styling via CSS Modules with `--ac-*` custom properties
23
+ * - Client-side only (`"use client"` directive)
24
+ *
25
+ * @example
26
+ * ```tsx
27
+ * <HighlightText text="Highlighted copy" />
28
+ * ```
29
+ *
30
+ * @see {@link HighlightTextProps} for available props
31
+ */
10
32
  declare const HighlightText: React.ForwardRefExoticComponent<Omit<HighlightTextProps, "ref"> & React.RefAttributes<HTMLSpanElement>>;
11
- export { HighlightText, type HighlightTextProps };
33
+ export { HighlightText };
12
34
  //# sourceMappingURL=highlight-text.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"highlight-text.d.ts","sourceRoot":"","sources":["../../../src/components/ui/highlight-text.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAoB,KAAK,eAAe,EAAE,KAAK,UAAU,EAAE,KAAK,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAC7G,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,UAAU,kBAAmB,SAAQ,eAAe,CAAC,MAAM,CAAC;IAC1D,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,YAAY,CAAC,EAAE,gBAAgB,CAAC,QAAQ,CAAC,CAAC;IAC1C,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAID,QAAA,MAAM,aAAa,yGAiClB,CAAC;AAGF,OAAO,EAAC,aAAa,EAAE,KAAK,kBAAkB,EAAC,CAAC"}
1
+ {"version":3,"file":"highlight-text.d.ts","sourceRoot":"","sources":["../../../src/components/ui/highlight-text.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAoB,KAAK,eAAe,EAAE,KAAK,UAAU,EAAE,KAAK,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAC7G,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,+CAA+C;AAC/C,MAAM,WAAW,kBAAmB,SAAQ,eAAe,CAAC,MAAM,CAAC;IACjE,yFAAyF;IACzF,IAAI,EAAE,MAAM,CAAC;IACb,wFAAwF;IACxF,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,qFAAqF;IACrF,YAAY,CAAC,EAAE,gBAAgB,CAAC,QAAQ,CAAC,CAAC;IAC1C,0FAA0F;IAC1F,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,qGAAqG;IACrG,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAID;;;;;;;;;;;;;;;GAeG;AACH,QAAA,MAAM,aAAa,yGA+BlB,CAAC;AAIF,OAAO,EAAC,aAAa,EAAC,CAAC"}
@@ -3,17 +3,19 @@ import { jsx } from "react/jsx-runtime";
3
3
  import { motion, useInView } from "motion/react";
4
4
  import { forwardRef, useImperativeHandle, useRef } from "react";
5
5
  import { cn } from "../../lib/utilities.js";
6
+ import highlight_text_module from "./highlight-text.module.js";
6
7
  const animation = {
7
8
  backgroundSize: "100% 100%"
8
9
  };
9
- const HighlightText = /*#__PURE__*/ forwardRef(({ text, className, inView = false, inViewMargin = "0px", transition = {
10
+ const HighlightText = /*#__PURE__*/ forwardRef(({ text, className, inView = false, inViewMargin = "0px", inViewOnce = true, transition = {
10
11
  duration: 2,
11
12
  ease: "easeInOut"
12
13
  }, ...props }, ref)=>{
14
+ const { key: _ignoredKey, ...restProps } = props;
13
15
  const localRef = useRef(null);
14
- useImperativeHandle(ref, ()=>localRef.current);
16
+ useImperativeHandle(ref, ()=>localRef.current, []);
15
17
  const inViewResult = useInView(localRef, {
16
- once: true,
18
+ once: inViewOnce,
17
19
  margin: inViewMargin
18
20
  });
19
21
  const isInView = !inView || inViewResult;
@@ -24,13 +26,8 @@ const HighlightText = /*#__PURE__*/ forwardRef(({ text, className, inView = fals
24
26
  },
25
27
  animate: isInView ? animation : void 0,
26
28
  transition: transition,
27
- style: {
28
- backgroundRepeat: "no-repeat",
29
- backgroundPosition: "left center",
30
- display: "inline"
31
- },
32
- className: cn("relative inline-block rounded-lg bg-gradient-to-r from-blue-100 to-purple-100 px-2 py-1 dark:from-blue-500 dark:to-purple-500", className),
33
- ...props,
29
+ className: cn(highlight_text_module.highlight, className),
30
+ ...restProps,
34
31
  children: text
35
32
  });
36
33
  });
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/highlight-text.js","sources":["../../../src/components/ui/highlight-text.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {motion, useInView, type HTMLMotionProps, type Transition, type UseInViewOptions} from \"motion/react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\n\r\ninterface HighlightTextProps extends HTMLMotionProps<\"span\"> {\r\n text: string;\r\n inView?: boolean;\r\n inViewMargin?: UseInViewOptions[\"margin\"];\r\n inViewOnce?: boolean;\r\n transition?: Transition;\r\n}\r\n\r\nconst animation = {backgroundSize: \"100% 100%\"};\r\n\r\nconst HighlightText = React.forwardRef<HTMLSpanElement, HighlightTextProps>(\r\n ({text, className, inView = false, inViewMargin = \"0px\", transition = {duration: 2, ease: \"easeInOut\"}, ...props}, ref) => {\r\n const localRef = React.useRef<HTMLSpanElement>(null);\r\n React.useImperativeHandle(ref, () => localRef.current as HTMLSpanElement);\r\n\r\n const inViewResult = useInView(localRef, {\r\n once: true,\r\n margin: inViewMargin,\r\n });\r\n const isInView = !inView || inViewResult;\r\n\r\n return (\r\n <motion.span\r\n ref={localRef}\r\n initial={{\r\n backgroundSize: \"0% 100%\",\r\n }}\r\n animate={isInView ? animation : undefined}\r\n transition={transition}\r\n style={{\r\n backgroundRepeat: \"no-repeat\",\r\n backgroundPosition: \"left center\",\r\n display: \"inline\",\r\n }}\r\n className={cn(\r\n `relative inline-block rounded-lg bg-gradient-to-r from-blue-100 to-purple-100 px-2 py-1 dark:from-blue-500 dark:to-purple-500`,\r\n className,\r\n )}\r\n {...props}>\r\n {text}\r\n </motion.span>\r\n );\r\n },\r\n);\r\nHighlightText.displayName = \"HighlightText\";\r\n\r\nexport {HighlightText, type HighlightTextProps};\r\n"],"names":["animation","HighlightText","React","text","className","inView","inViewMargin","transition","props","ref","localRef","inViewResult","useInView","isInView","motion","undefined","cn"],"mappings":";;;;;AAeA,MAAMA,YAAY;IAAC,gBAAgB;AAAW;AAE9C,MAAMC,gBAAgB,WAAhBA,GAAgBC,WACpB,CAAC,EAACC,IAAI,EAAEC,SAAS,EAAEC,SAAS,KAAK,EAAEC,eAAe,KAAK,EAAEC,aAAa;IAAC,UAAU;IAAG,MAAM;AAAW,CAAC,EAAE,GAAGC,OAAM,EAAEC;IACjH,MAAMC,WAAWR,OAA8B;IAC/CA,oBAA0BO,KAAK,IAAMC,SAAS,OAAO;IAErD,MAAMC,eAAeC,UAAUF,UAAU;QACvC,MAAM;QACN,QAAQJ;IACV;IACA,MAAMO,WAAW,CAACR,UAAUM;IAE5B,OAAO,WAAP,GACE,IAACG,OAAO,IAAI;QACV,KAAKJ;QACL,SAAS;YACP,gBAAgB;QAClB;QACA,SAASG,WAAWb,YAAYe;QAChC,YAAYR;QACZ,OAAO;YACL,kBAAkB;YAClB,oBAAoB;YACpB,SAAS;QACX;QACA,WAAWS,GACT,iIACAZ;QAED,GAAGI,KAAK;kBACRL;;AAGP;AAEFF,cAAc,WAAW,GAAG"}
1
+ {"version":3,"file":"components/ui/highlight-text.js","sources":["../../../src/components/ui/highlight-text.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {motion, useInView, type HTMLMotionProps, type Transition, type UseInViewOptions} from \"motion/react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./highlight-text.module.css\";\r\n\r\n/** Props accepted by {@link HighlightText}. */\r\nexport interface HighlightTextProps extends HTMLMotionProps<\"span\"> {\r\n /** Inline text content that receives the animated highlight sweep. @default undefined */\r\n text: string;\r\n /** Delays the highlight animation until the text enters the viewport. @default false */\r\n inView?: boolean;\r\n /** Margin passed to the in-view observer when `inView` is enabled. @default \"0px\" */\r\n inViewMargin?: UseInViewOptions[\"margin\"];\r\n /** Prevents the in-view animation from replaying after the first reveal. @default true */\r\n inViewOnce?: boolean;\r\n /** Motion timing used for the highlight fill animation. @default {duration: 2, ease: \"easeInOut\"} */\r\n transition?: Transition;\r\n}\r\n\r\nconst animation = {backgroundSize: \"100% 100%\"};\r\n\r\n/**\r\n * Animates a gradient highlight fill behind inline text content.\r\n *\r\n * @remarks\r\n * - Animated component using the `motion` library\r\n * - Renders a `<span>` element\r\n * - Styling via CSS Modules with `--ac-*` custom properties\r\n * - Client-side only (`\"use client\"` directive)\r\n *\r\n * @example\r\n * ```tsx\r\n * <HighlightText text=\"Highlighted copy\" />\r\n * ```\r\n *\r\n * @see {@link HighlightTextProps} for available props\r\n */\r\nconst HighlightText = React.forwardRef<HTMLSpanElement, HighlightTextProps>(\r\n (\r\n {text, className, inView = false, inViewMargin = \"0px\", inViewOnce = true, transition = {duration: 2, ease: \"easeInOut\"}, ...props},\r\n ref,\r\n ) => {\r\n // eslint-disable-next-line sonarjs/no-unused-vars -- removing React key avoids implicit key spreading\r\n const {key: _ignoredKey, ...restProps} = props;\r\n const localRef = React.useRef<HTMLSpanElement>(null);\r\n\r\n React.useImperativeHandle(ref, () => localRef.current!, []);\r\n\r\n const inViewResult = useInView(localRef, {\r\n once: inViewOnce,\r\n margin: inViewMargin,\r\n });\r\n const isInView = !inView || inViewResult;\r\n\r\n return (\r\n <motion.span\r\n ref={localRef}\r\n initial={{\r\n backgroundSize: \"0% 100%\",\r\n }}\r\n animate={isInView ? animation : undefined}\r\n transition={transition}\r\n className={cn(styles.highlight, className)}\r\n {...restProps}>\r\n {text}\r\n </motion.span>\r\n );\r\n },\r\n);\r\n\r\nHighlightText.displayName = \"HighlightText\";\r\n\r\nexport {HighlightText};\r\n"],"names":["animation","HighlightText","React","text","className","inView","inViewMargin","inViewOnce","transition","props","ref","_ignoredKey","restProps","localRef","inViewResult","useInView","isInView","motion","undefined","cn","styles"],"mappings":";;;;;;AAsBA,MAAMA,YAAY;IAAC,gBAAgB;AAAW;AAkB9C,MAAMC,gBAAgB,WAAHA,GAAGC,WACpB,CACE,EAACC,IAAI,EAAEC,SAAS,EAAEC,SAAS,KAAK,EAAEC,eAAe,KAAK,EAAEC,aAAa,IAAI,EAAEC,aAAa;IAAC,UAAU;IAAG,MAAM;AAAW,CAAC,EAAE,GAAGC,OAAM,EACnIC;IAGA,MAAM,EAAC,KAAKC,WAAW,EAAE,GAAGC,WAAU,GAAGH;IACzC,MAAMI,WAAWX,OAA8B;IAE/CA,oBAA0BQ,KAAK,IAAMG,SAAS,OAAO,EAAG,EAAE;IAE1D,MAAMC,eAAeC,UAAUF,UAAU;QACvC,MAAMN;QACN,QAAQD;IACV;IACA,MAAMU,WAAW,CAACX,UAAUS;IAE5B,OAAO,WAAP,GACE,IAACG,OAAO,IAAI;QACV,KAAKJ;QACL,SAAS;YACP,gBAAgB;QAClB;QACA,SAASG,WAAWhB,YAAYkB;QAChC,YAAYV;QACZ,WAAWW,GAAGC,sBAAAA,SAAgB,EAAEhB;QAC/B,GAAGQ,SAAS;kBACZT;;AAGP;AAGFF,cAAc,WAAW,GAAG"}
@@ -0,0 +1,7 @@
1
+ import "./highlight-text_module.css";
2
+ const highlight_text_module = {
3
+ highlight: "highlight-roGyzF"
4
+ };
5
+ export default highlight_text_module;
6
+
7
+ //# sourceMappingURL=highlight-text.module.js.map