@me1a/ui 2.2.2 → 2.2.3

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 (353) hide show
  1. package/dist/{atoms/accordion.mjs → accordion/index.mjs} +2 -2
  2. package/dist/accordion/index.mjs.map +1 -0
  3. package/dist/{atoms/avatar.mjs → avatar/index.mjs} +2 -2
  4. package/dist/avatar/index.mjs.map +1 -0
  5. package/dist/{atoms/badge.d.mts → badge/index.d.mts} +9 -8
  6. package/dist/{atoms/badge.mjs → badge/index.mjs} +2 -2
  7. package/dist/{atoms/badge.mjs.map → badge/index.mjs.map} +1 -1
  8. package/dist/{atoms/box.mjs → box/index.mjs} +2 -2
  9. package/dist/box/index.mjs.map +1 -0
  10. package/dist/{atoms/breadcrumb.mjs → breadcrumb/index.mjs} +2 -2
  11. package/dist/breadcrumb/index.mjs.map +1 -0
  12. package/dist/{atoms/button.d.mts → button/index.d.mts} +2 -2
  13. package/dist/{atoms/button.mjs → button/index.mjs} +2 -2
  14. package/dist/button/index.mjs.map +1 -0
  15. package/dist/card/index.d.mts +127 -0
  16. package/dist/card/index.mjs +2 -0
  17. package/dist/card/index.mjs.map +1 -0
  18. package/dist/{atoms/checkbox.mjs → checkbox/index.mjs} +2 -2
  19. package/dist/checkbox/index.mjs.map +1 -0
  20. package/dist/{atoms/collapsible.mjs → collapsible/index.mjs} +2 -2
  21. package/dist/collapsible/index.mjs.map +1 -0
  22. package/dist/{atoms/command.mjs → command/index.mjs} +2 -2
  23. package/dist/command/index.mjs.map +1 -0
  24. package/dist/container/index.d.mts +33 -0
  25. package/dist/{atoms/container.mjs → container/index.mjs} +2 -2
  26. package/dist/container/index.mjs.map +1 -0
  27. package/dist/{atoms/dialog.mjs → dialog/index.mjs} +2 -2
  28. package/dist/dialog/index.mjs.map +1 -0
  29. package/dist/{organisms/drawer.mjs → drawer/index.mjs} +2 -2
  30. package/dist/drawer/index.mjs.map +1 -0
  31. package/dist/{organisms/dropdown-menu.d.mts → dropdown-menu/index.d.mts} +2 -2
  32. package/dist/{organisms/dropdown-menu.mjs → dropdown-menu/index.mjs} +2 -2
  33. package/dist/dropdown-menu/index.mjs.map +1 -0
  34. package/dist/{rhf/form.mjs → form/index.mjs} +2 -2
  35. package/dist/form/index.mjs.map +1 -0
  36. package/dist/{hooks.d.mts → hooks/index.d.mts} +2 -2
  37. package/dist/{hooks.mjs → hooks/index.mjs} +2 -2
  38. package/dist/{hooks.js.map → hooks/index.mjs.map} +1 -1
  39. package/dist/index.d.mts +159 -39
  40. package/dist/index.mjs +47 -2
  41. package/dist/index.mjs.map +1 -1
  42. package/dist/{atoms/input.mjs → input/index.mjs} +2 -2
  43. package/dist/{atoms/input.mjs.map → input/index.mjs.map} +1 -1
  44. package/dist/{atoms/label.d.mts → label/index.d.mts} +2 -2
  45. package/dist/{atoms/label.mjs → label/index.mjs} +2 -2
  46. package/dist/{atoms/label.mjs.map → label/index.mjs.map} +1 -1
  47. package/dist/{molecules/navigation-menu.d.mts → navigation-menu/index.d.mts} +21 -20
  48. package/dist/{molecules/navigation-menu.mjs → navigation-menu/index.mjs} +2 -2
  49. package/dist/navigation-menu/index.mjs.map +1 -0
  50. package/dist/{atoms/page-loader.d.mts → page-loader/index.d.mts} +2 -2
  51. package/dist/{atoms/page-loader.mjs → page-loader/index.mjs} +2 -2
  52. package/dist/page-loader/index.mjs.map +1 -0
  53. package/dist/{atoms/pagination.d.mts → pagination/index.d.mts} +2 -2
  54. package/dist/{atoms/pagination.mjs → pagination/index.mjs} +2 -2
  55. package/dist/pagination/index.mjs.map +1 -0
  56. package/dist/{atoms/popover.mjs → popover/index.mjs} +2 -2
  57. package/dist/popover/index.mjs.map +1 -0
  58. package/dist/{atoms/radio-group.d.mts → radio-group/index.d.mts} +2 -2
  59. package/dist/{atoms/radio-group.mjs → radio-group/index.mjs} +2 -2
  60. package/dist/radio-group/index.mjs.map +1 -0
  61. package/dist/{atoms/resizable.mjs → resizable/index.mjs} +2 -2
  62. package/dist/resizable/index.mjs.map +1 -0
  63. package/dist/{rhf/rhf-checkbox.mjs → rhf-checkbox/index.mjs} +2 -2
  64. package/dist/rhf-checkbox/index.mjs.map +1 -0
  65. package/dist/{rhf/rhf-multi-select.mjs → rhf-multi-select/index.mjs} +2 -2
  66. package/dist/rhf-multi-select/index.mjs.map +1 -0
  67. package/dist/{rhf/rhf-radio-button-group.mjs → rhf-radio-button-group/index.mjs} +2 -2
  68. package/dist/rhf-radio-button-group/index.mjs.map +1 -0
  69. package/dist/{rhf/rhf-radio-group.mjs → rhf-radio-group/index.mjs} +2 -2
  70. package/dist/rhf-radio-group/index.mjs.map +1 -0
  71. package/dist/{rhf/rhf-select.mjs → rhf-select/index.mjs} +2 -2
  72. package/dist/rhf-select/index.mjs.map +1 -0
  73. package/dist/{rhf/rhf-switch.mjs → rhf-switch/index.mjs} +2 -2
  74. package/dist/rhf-switch/index.mjs.map +1 -0
  75. package/dist/{rhf/rhf-textarea.mjs → rhf-textarea/index.mjs} +2 -2
  76. package/dist/rhf-textarea/index.mjs.map +1 -0
  77. package/dist/{atoms/separator.mjs → separator/index.mjs} +2 -2
  78. package/dist/separator/index.mjs.map +1 -0
  79. package/dist/{atoms/sheet.d.mts → sheet/index.d.mts} +2 -2
  80. package/dist/{atoms/sheet.mjs → sheet/index.mjs} +2 -2
  81. package/dist/{atoms/sheet.mjs.map → sheet/index.mjs.map} +1 -1
  82. package/dist/{organisms/sidebar.d.mts → sidebar/index.d.mts} +4 -4
  83. package/dist/{organisms/sidebar.mjs → sidebar/index.mjs} +2 -2
  84. package/dist/sidebar/index.mjs.map +1 -0
  85. package/dist/skeleton/index.d.mts +17 -0
  86. package/dist/skeleton/index.mjs +2 -0
  87. package/dist/skeleton/index.mjs.map +1 -0
  88. package/dist/{atoms/stack.mjs → stack/index.mjs} +2 -2
  89. package/dist/{atoms/stack.mjs.map → stack/index.mjs.map} +1 -1
  90. package/dist/{atoms/switch.mjs → switch/index.mjs} +2 -2
  91. package/dist/switch/index.mjs.map +1 -0
  92. package/dist/{atoms/table.mjs → table/index.mjs} +2 -2
  93. package/dist/{atoms/table.mjs.map → table/index.mjs.map} +1 -1
  94. package/dist/tabs/index.d.mts +97 -0
  95. package/dist/tabs/index.mjs +2 -0
  96. package/dist/tabs/index.mjs.map +1 -0
  97. package/dist/{atoms/text-field.d.mts → text-field/index.d.mts} +2 -2
  98. package/dist/{atoms/text-field.mjs → text-field/index.mjs} +2 -2
  99. package/dist/text-field/index.mjs.map +1 -0
  100. package/dist/textarea/index.d.mts +24 -0
  101. package/dist/{atoms/textarea.mjs → textarea/index.mjs} +2 -2
  102. package/dist/textarea/index.mjs.map +1 -0
  103. package/dist/{atoms/toast.d.mts → toast/index.d.mts} +2 -2
  104. package/dist/{atoms/toast.mjs → toast/index.mjs} +2 -2
  105. package/dist/{atoms/toast.mjs.map → toast/index.mjs.map} +1 -1
  106. package/dist/{atoms/toaster.mjs → toaster/index.mjs} +2 -2
  107. package/dist/toaster/index.mjs.map +1 -0
  108. package/dist/{atoms/tooltip.mjs → tooltip/index.mjs} +2 -2
  109. package/dist/tooltip/index.mjs.map +1 -0
  110. package/dist/types/index.d.mts +2 -0
  111. package/dist/types/index.mjs +2 -0
  112. package/dist/types/index.mjs.map +1 -0
  113. package/dist/{atoms/typography.d.mts → typography/index.d.mts} +2 -2
  114. package/dist/{atoms/typography.mjs → typography/index.mjs} +2 -2
  115. package/dist/typography/index.mjs.map +1 -0
  116. package/dist/utils/index.d.mts +5 -0
  117. package/dist/{utils.mjs → utils/index.mjs} +2 -2
  118. package/dist/utils/index.mjs.map +1 -0
  119. package/package.json +196 -257
  120. package/dist/atoms/accordion.d.ts +0 -94
  121. package/dist/atoms/accordion.js +0 -2
  122. package/dist/atoms/accordion.js.map +0 -1
  123. package/dist/atoms/accordion.mjs.map +0 -1
  124. package/dist/atoms/avatar.d.ts +0 -34
  125. package/dist/atoms/avatar.js +0 -2
  126. package/dist/atoms/avatar.js.map +0 -1
  127. package/dist/atoms/avatar.mjs.map +0 -1
  128. package/dist/atoms/badge.d.ts +0 -40
  129. package/dist/atoms/badge.js +0 -2
  130. package/dist/atoms/badge.js.map +0 -1
  131. package/dist/atoms/box.d.ts +0 -50
  132. package/dist/atoms/box.js +0 -2
  133. package/dist/atoms/box.js.map +0 -1
  134. package/dist/atoms/box.mjs.map +0 -1
  135. package/dist/atoms/breadcrumb.d.ts +0 -35
  136. package/dist/atoms/breadcrumb.js +0 -2
  137. package/dist/atoms/breadcrumb.js.map +0 -1
  138. package/dist/atoms/breadcrumb.mjs.map +0 -1
  139. package/dist/atoms/button.d.ts +0 -82
  140. package/dist/atoms/button.js +0 -2
  141. package/dist/atoms/button.js.map +0 -1
  142. package/dist/atoms/button.mjs.map +0 -1
  143. package/dist/atoms/checkbox.d.ts +0 -21
  144. package/dist/atoms/checkbox.js +0 -2
  145. package/dist/atoms/checkbox.js.map +0 -1
  146. package/dist/atoms/checkbox.mjs.map +0 -1
  147. package/dist/atoms/collapsible.d.ts +0 -26
  148. package/dist/atoms/collapsible.js +0 -2
  149. package/dist/atoms/collapsible.js.map +0 -1
  150. package/dist/atoms/collapsible.mjs.map +0 -1
  151. package/dist/atoms/command.d.ts +0 -122
  152. package/dist/atoms/command.js +0 -2
  153. package/dist/atoms/command.js.map +0 -1
  154. package/dist/atoms/command.mjs.map +0 -1
  155. package/dist/atoms/container.js +0 -2
  156. package/dist/atoms/container.js.map +0 -1
  157. package/dist/atoms/container.mjs.map +0 -1
  158. package/dist/atoms/dialog.d.ts +0 -35
  159. package/dist/atoms/dialog.js +0 -2
  160. package/dist/atoms/dialog.js.map +0 -1
  161. package/dist/atoms/dialog.mjs.map +0 -1
  162. package/dist/atoms/input.d.ts +0 -12
  163. package/dist/atoms/input.js +0 -2
  164. package/dist/atoms/input.js.map +0 -1
  165. package/dist/atoms/label.d.ts +0 -18
  166. package/dist/atoms/label.js +0 -2
  167. package/dist/atoms/label.js.map +0 -1
  168. package/dist/atoms/page-loader.d.ts +0 -29
  169. package/dist/atoms/page-loader.js +0 -2
  170. package/dist/atoms/page-loader.js.map +0 -1
  171. package/dist/atoms/page-loader.mjs.map +0 -1
  172. package/dist/atoms/pagination.d.ts +0 -105
  173. package/dist/atoms/pagination.js +0 -2
  174. package/dist/atoms/pagination.js.map +0 -1
  175. package/dist/atoms/pagination.mjs.map +0 -1
  176. package/dist/atoms/popover.d.ts +0 -30
  177. package/dist/atoms/popover.js +0 -2
  178. package/dist/atoms/popover.js.map +0 -1
  179. package/dist/atoms/popover.mjs.map +0 -1
  180. package/dist/atoms/radio-group.d.ts +0 -62
  181. package/dist/atoms/radio-group.js +0 -2
  182. package/dist/atoms/radio-group.js.map +0 -1
  183. package/dist/atoms/radio-group.mjs.map +0 -1
  184. package/dist/atoms/resizable.d.ts +0 -53
  185. package/dist/atoms/resizable.js +0 -2
  186. package/dist/atoms/resizable.js.map +0 -1
  187. package/dist/atoms/resizable.mjs.map +0 -1
  188. package/dist/atoms/separator.d.ts +0 -13
  189. package/dist/atoms/separator.js +0 -2
  190. package/dist/atoms/separator.js.map +0 -1
  191. package/dist/atoms/separator.mjs.map +0 -1
  192. package/dist/atoms/sheet.d.ts +0 -42
  193. package/dist/atoms/sheet.js +0 -2
  194. package/dist/atoms/sheet.js.map +0 -1
  195. package/dist/atoms/skeleton.js +0 -2
  196. package/dist/atoms/skeleton.js.map +0 -1
  197. package/dist/atoms/skeleton.mjs +0 -2
  198. package/dist/atoms/skeleton.mjs.map +0 -1
  199. package/dist/atoms/stack.d.ts +0 -121
  200. package/dist/atoms/stack.js +0 -2
  201. package/dist/atoms/stack.js.map +0 -1
  202. package/dist/atoms/switch.d.ts +0 -21
  203. package/dist/atoms/switch.js +0 -2
  204. package/dist/atoms/switch.js.map +0 -1
  205. package/dist/atoms/switch.mjs.map +0 -1
  206. package/dist/atoms/table.d.ts +0 -53
  207. package/dist/atoms/table.js +0 -2
  208. package/dist/atoms/table.js.map +0 -1
  209. package/dist/atoms/text-field.d.ts +0 -65
  210. package/dist/atoms/text-field.js +0 -2
  211. package/dist/atoms/text-field.js.map +0 -1
  212. package/dist/atoms/text-field.mjs.map +0 -1
  213. package/dist/atoms/textarea.js +0 -2
  214. package/dist/atoms/textarea.js.map +0 -1
  215. package/dist/atoms/textarea.mjs.map +0 -1
  216. package/dist/atoms/toast.d.ts +0 -18
  217. package/dist/atoms/toast.js +0 -2
  218. package/dist/atoms/toast.js.map +0 -1
  219. package/dist/atoms/toaster.d.ts +0 -26
  220. package/dist/atoms/toaster.js +0 -2
  221. package/dist/atoms/toaster.js.map +0 -1
  222. package/dist/atoms/toaster.mjs.map +0 -1
  223. package/dist/atoms/tooltip.d.ts +0 -25
  224. package/dist/atoms/tooltip.js +0 -2
  225. package/dist/atoms/tooltip.js.map +0 -1
  226. package/dist/atoms/tooltip.mjs.map +0 -1
  227. package/dist/atoms/typography.d.ts +0 -24
  228. package/dist/atoms/typography.js +0 -2
  229. package/dist/atoms/typography.js.map +0 -1
  230. package/dist/atoms/typography.mjs.map +0 -1
  231. package/dist/atoms.d.mts +0 -1237
  232. package/dist/atoms.d.ts +0 -1237
  233. package/dist/atoms.js +0 -2
  234. package/dist/atoms.js.map +0 -1
  235. package/dist/atoms.mjs +0 -2
  236. package/dist/atoms.mjs.map +0 -1
  237. package/dist/hooks.d.ts +0 -57
  238. package/dist/hooks.js +0 -2
  239. package/dist/hooks.mjs.map +0 -1
  240. package/dist/index.d.ts +0 -2619
  241. package/dist/index.js +0 -2
  242. package/dist/index.js.map +0 -1
  243. package/dist/molecules/card.d.mts +0 -72
  244. package/dist/molecules/card.d.ts +0 -72
  245. package/dist/molecules/card.js +0 -2
  246. package/dist/molecules/card.js.map +0 -1
  247. package/dist/molecules/card.mjs +0 -2
  248. package/dist/molecules/card.mjs.map +0 -1
  249. package/dist/molecules/navigation-menu.d.ts +0 -103
  250. package/dist/molecules/navigation-menu.js +0 -2
  251. package/dist/molecules/navigation-menu.js.map +0 -1
  252. package/dist/molecules/navigation-menu.mjs.map +0 -1
  253. package/dist/molecules/tabs.d.mts +0 -32
  254. package/dist/molecules/tabs.d.ts +0 -32
  255. package/dist/molecules/tabs.js +0 -2
  256. package/dist/molecules/tabs.js.map +0 -1
  257. package/dist/molecules/tabs.mjs +0 -2
  258. package/dist/molecules/tabs.mjs.map +0 -1
  259. package/dist/molecules.d.mts +0 -201
  260. package/dist/molecules.d.ts +0 -201
  261. package/dist/molecules.js +0 -2
  262. package/dist/molecules.js.map +0 -1
  263. package/dist/molecules.mjs +0 -2
  264. package/dist/molecules.mjs.map +0 -1
  265. package/dist/organisms/drawer.d.ts +0 -63
  266. package/dist/organisms/drawer.js +0 -2
  267. package/dist/organisms/drawer.js.map +0 -1
  268. package/dist/organisms/drawer.mjs.map +0 -1
  269. package/dist/organisms/dropdown-menu.d.ts +0 -335
  270. package/dist/organisms/dropdown-menu.js +0 -2
  271. package/dist/organisms/dropdown-menu.js.map +0 -1
  272. package/dist/organisms/dropdown-menu.mjs.map +0 -1
  273. package/dist/organisms/sidebar.d.ts +0 -328
  274. package/dist/organisms/sidebar.js +0 -2
  275. package/dist/organisms/sidebar.js.map +0 -1
  276. package/dist/organisms/sidebar.mjs.map +0 -1
  277. package/dist/organisms.d.mts +0 -717
  278. package/dist/organisms.d.ts +0 -717
  279. package/dist/organisms.js +0 -2
  280. package/dist/organisms.js.map +0 -1
  281. package/dist/organisms.mjs +0 -2
  282. package/dist/organisms.mjs.map +0 -1
  283. package/dist/rhf/form.d.ts +0 -96
  284. package/dist/rhf/form.js +0 -2
  285. package/dist/rhf/form.js.map +0 -1
  286. package/dist/rhf/form.mjs.map +0 -1
  287. package/dist/rhf/rhf-checkbox.d.ts +0 -57
  288. package/dist/rhf/rhf-checkbox.js +0 -2
  289. package/dist/rhf/rhf-checkbox.js.map +0 -1
  290. package/dist/rhf/rhf-checkbox.mjs.map +0 -1
  291. package/dist/rhf/rhf-multi-select.d.ts +0 -84
  292. package/dist/rhf/rhf-multi-select.js +0 -2
  293. package/dist/rhf/rhf-multi-select.js.map +0 -1
  294. package/dist/rhf/rhf-multi-select.mjs.map +0 -1
  295. package/dist/rhf/rhf-radio-button-group.d.ts +0 -73
  296. package/dist/rhf/rhf-radio-button-group.js +0 -2
  297. package/dist/rhf/rhf-radio-button-group.js.map +0 -1
  298. package/dist/rhf/rhf-radio-button-group.mjs.map +0 -1
  299. package/dist/rhf/rhf-radio-group.d.ts +0 -103
  300. package/dist/rhf/rhf-radio-group.js +0 -2
  301. package/dist/rhf/rhf-radio-group.js.map +0 -1
  302. package/dist/rhf/rhf-radio-group.mjs.map +0 -1
  303. package/dist/rhf/rhf-select.d.ts +0 -80
  304. package/dist/rhf/rhf-select.js +0 -2
  305. package/dist/rhf/rhf-select.js.map +0 -1
  306. package/dist/rhf/rhf-select.mjs.map +0 -1
  307. package/dist/rhf/rhf-switch.d.ts +0 -57
  308. package/dist/rhf/rhf-switch.js +0 -2
  309. package/dist/rhf/rhf-switch.js.map +0 -1
  310. package/dist/rhf/rhf-switch.mjs.map +0 -1
  311. package/dist/rhf/rhf-textarea.d.ts +0 -66
  312. package/dist/rhf/rhf-textarea.js +0 -2
  313. package/dist/rhf/rhf-textarea.js.map +0 -1
  314. package/dist/rhf/rhf-textarea.mjs.map +0 -1
  315. package/dist/rhf.d.mts +0 -614
  316. package/dist/rhf.d.ts +0 -614
  317. package/dist/rhf.js +0 -2
  318. package/dist/rhf.js.map +0 -1
  319. package/dist/rhf.mjs +0 -2
  320. package/dist/rhf.mjs.map +0 -1
  321. package/dist/types.js +0 -2
  322. package/dist/types.js.map +0 -1
  323. package/dist/types.mjs +0 -2
  324. package/dist/types.mjs.map +0 -1
  325. package/dist/utils.js +0 -2
  326. package/dist/utils.js.map +0 -1
  327. package/dist/utils.mjs.map +0 -1
  328. /package/dist/{atoms/accordion.d.mts → accordion/index.d.mts} +0 -0
  329. /package/dist/{atoms/avatar.d.mts → avatar/index.d.mts} +0 -0
  330. /package/dist/{atoms/box.d.mts → box/index.d.mts} +0 -0
  331. /package/dist/{atoms/breadcrumb.d.mts → breadcrumb/index.d.mts} +0 -0
  332. /package/dist/{atoms/checkbox.d.mts → checkbox/index.d.mts} +0 -0
  333. /package/dist/{atoms/collapsible.d.mts → collapsible/index.d.mts} +0 -0
  334. /package/dist/{atoms/command.d.mts → command/index.d.mts} +0 -0
  335. /package/dist/{atoms/dialog.d.mts → dialog/index.d.mts} +0 -0
  336. /package/dist/{organisms/drawer.d.mts → drawer/index.d.mts} +0 -0
  337. /package/dist/{rhf/form.d.mts → form/index.d.mts} +0 -0
  338. /package/dist/{atoms/input.d.mts → input/index.d.mts} +0 -0
  339. /package/dist/{atoms/popover.d.mts → popover/index.d.mts} +0 -0
  340. /package/dist/{atoms/resizable.d.mts → resizable/index.d.mts} +0 -0
  341. /package/dist/{rhf/rhf-checkbox.d.mts → rhf-checkbox/index.d.mts} +0 -0
  342. /package/dist/{rhf/rhf-multi-select.d.mts → rhf-multi-select/index.d.mts} +0 -0
  343. /package/dist/{rhf/rhf-radio-button-group.d.mts → rhf-radio-button-group/index.d.mts} +0 -0
  344. /package/dist/{rhf/rhf-radio-group.d.mts → rhf-radio-group/index.d.mts} +0 -0
  345. /package/dist/{rhf/rhf-select.d.mts → rhf-select/index.d.mts} +0 -0
  346. /package/dist/{rhf/rhf-switch.d.mts → rhf-switch/index.d.mts} +0 -0
  347. /package/dist/{rhf/rhf-textarea.d.mts → rhf-textarea/index.d.mts} +0 -0
  348. /package/dist/{atoms/separator.d.mts → separator/index.d.mts} +0 -0
  349. /package/dist/{atoms/stack.d.mts → stack/index.d.mts} +0 -0
  350. /package/dist/{atoms/switch.d.mts → switch/index.d.mts} +0 -0
  351. /package/dist/{atoms/table.d.mts → table/index.d.mts} +0 -0
  352. /package/dist/{atoms/toaster.d.mts → toaster/index.d.mts} +0 -0
  353. /package/dist/{atoms/tooltip.d.mts → tooltip/index.d.mts} +0 -0
@@ -1,2 +1,2 @@
1
- import*as r from'react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function t(...e){return twMerge(clsx(e))}var a=r.forwardRef(({className:e,type:o,...n},i)=>jsx("input",{type:o,className:t("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:i,...n}));a.displayName="Input";export{a as Input};//# sourceMappingURL=input.mjs.map
2
- //# sourceMappingURL=input.mjs.map
1
+ import*as r from'react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function t(...e){return twMerge(clsx(e))}var a=r.forwardRef(({className:e,type:o,...n},i)=>jsx("input",{type:o,className:t("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:i,...n}));a.displayName="Input";export{a as Input};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/input/input.tsx"],"names":["cn","inputs","twMerge","clsx","Input","className","type","props","ref","jsx"],"mappings":"yHAGO,SAASA,CAAAA,CAAAA,GAAMC,EAAsB,CAC1C,OAAOC,OAAQC,CAAAA,IAAAA,CAAKF,CAAM,CAAC,CAC7B,CCMMG,IAAAA,CAAAA,CAAc,aAClB,CAAC,CAAE,SAAAC,CAAAA,CAAAA,CAAW,IAAAC,CAAAA,CAAAA,CAAM,GAAGC,CAAM,CAAA,CAAGC,CAE5BC,GAAAA,GAAAA,CAAC,OACC,CAAA,CAAA,IAAA,CAAMH,EACN,SAAWN,CAAAA,CAAAA,CACT,yWACAK,CAAAA,CACF,CACA,CAAA,GAAA,CAAKG,CACJ,CAAA,GAAGD,CACN,CAAA,CAGN,EACAH,CAAAA,CAAM,WAAc,CAAA,OAAA","file":"input.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\n\nimport { cn } from \"@/utils/cn\"\n\n/**\n * Input component for creating accessible input fields.\n * Built on top of shadcn/ui's Input component.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-input--docs\n *\n */\nconst Input = React.forwardRef<HTMLInputElement, React.ComponentProps<\"input\">>(\n ({ className, type, ...props }, ref) => {\n return (\n <input\n type={type}\n className={cn(\n \"flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm\",\n className\n )}\n ref={ref}\n {...props}\n />\n )\n }\n)\nInput.displayName = \"Input\"\n\nexport { Input }\n"]}
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/input/input.tsx"],"names":["cn","inputs","twMerge","clsx","Input","className","type","props","ref","jsx"],"mappings":"yHAGO,SAASA,CAAAA,CAAAA,GAAMC,EAAsB,CAC1C,OAAOC,OAAQC,CAAAA,IAAAA,CAAKF,CAAM,CAAC,CAC7B,CCMMG,IAAAA,CAAAA,CAAc,aAClB,CAAC,CAAE,SAAAC,CAAAA,CAAAA,CAAW,IAAAC,CAAAA,CAAAA,CAAM,GAAGC,CAAM,CAAA,CAAGC,CAE5BC,GAAAA,GAAAA,CAAC,OACC,CAAA,CAAA,IAAA,CAAMH,EACN,SAAWN,CAAAA,CAAAA,CACT,yWACAK,CAAAA,CACF,CACA,CAAA,GAAA,CAAKG,CACJ,CAAA,GAAGD,CACN,CAAA,CAGN,EACAH,CAAAA,CAAM,WAAc,CAAA,OAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\n\nimport { cn } from \"@/utils/cn\"\n\n/**\n * Input component for creating accessible input fields.\n * Built on top of shadcn/ui's Input component.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-input--docs\n *\n */\nconst Input = React.forwardRef<HTMLInputElement, React.ComponentProps<\"input\">>(\n ({ className, type, ...props }, ref) => {\n return (\n <input\n type={type}\n className={cn(\n \"flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm\",\n className\n )}\n ref={ref}\n {...props}\n />\n )\n }\n)\nInput.displayName = \"Input\"\n\nexport { Input }\n"]}
@@ -1,9 +1,9 @@
1
- import * as class_variance_authority_types from 'class-variance-authority/types';
1
+ import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
2
2
  import * as React from 'react';
3
3
  import * as LabelPrimitive from '@radix-ui/react-label';
4
4
  import { VariantProps } from 'class-variance-authority';
5
5
 
6
- declare const labelVariants: (props?: class_variance_authority_types.ClassProp | undefined) => string;
6
+ declare const labelVariants: (props?: class_variance_authority_dist_types.ClassProp | undefined) => string;
7
7
  interface LabelProps extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>, VariantProps<typeof labelVariants> {
8
8
  }
9
9
  /**
@@ -1,2 +1,2 @@
1
- import*as a from'react';import*as t from'@radix-ui/react-label';import {cva}from'class-variance-authority';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function o(...e){return twMerge(clsx(e))}var n=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),r=a.forwardRef(({className:e,...i},p)=>jsx(t.Root,{ref:p,className:o(n(),e),...i}));r.displayName=t.Root.displayName;export{r as Label};//# sourceMappingURL=label.mjs.map
2
- //# sourceMappingURL=label.mjs.map
1
+ import*as a from'react';import*as t from'@radix-ui/react-label';import {cva}from'class-variance-authority';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function o(...e){return twMerge(clsx(e))}var n=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),r=a.forwardRef(({className:e,...i},p)=>jsx(t.Root,{ref:p,className:o(n(),e),...i}));r.displayName=t.Root.displayName;export{r as Label};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/label/label.tsx"],"names":["cn","inputs","twMerge","clsx","labelVariants","cva","Label","className","props","ref","jsx"],"mappings":"4MAGO,SAASA,CAAMC,CAAAA,GAAAA,CAAAA,CAAsB,CAC1C,OAAOC,OAAQC,CAAAA,IAAAA,CAAKF,CAAM,CAAC,CAC7B,CCCMG,IAAAA,CAAAA,CAAgBC,GACpB,CAAA,4FACF,CAaMC,CAAAA,CAAAA,CAAc,CAClB,CAAA,UAAA,CAAA,CAAC,CAAE,SAAA,CAAAC,CAAW,CAAA,GAAGC,CAAM,CAAA,CAAGC,IACxBC,GAAgB,CAAA,CAAA,CAAA,IAAA,CAAf,CAAoB,GAAA,CAAKD,CAAK,CAAA,SAAA,CAAWT,CAAGI,CAAAA,CAAAA,EAAiBG,CAAAA,CAAS,CAAI,CAAA,GAAGC,CAAO,CAAA,CAEzF,EACAF,CAAAA,CAAM,YAA6B,CAAK,CAAA,IAAA,CAAA,WAAA","file":"label.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\nimport * as LabelPrimitive from \"@radix-ui/react-label\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/utils/index\"\n\nconst labelVariants = cva(\n \"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70\"\n)\n\nexport interface LabelProps\n extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>,\n VariantProps<typeof labelVariants> {}\n\n/**\n * Label component for creating accessible labels.\n * Built on top of Radix UI's Label primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-label--docs\n *\n */\nconst Label = React.forwardRef<React.ElementRef<typeof LabelPrimitive.Root>, LabelProps>(\n ({ className, ...props }, ref) => (\n <LabelPrimitive.Root ref={ref} className={cn(labelVariants(), className)} {...props} />\n )\n)\nLabel.displayName = LabelPrimitive.Root.displayName\n\nexport { Label }\n"]}
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/label/label.tsx"],"names":["cn","inputs","twMerge","clsx","labelVariants","cva","Label","className","props","ref","jsx"],"mappings":"4MAGO,SAASA,CAAMC,CAAAA,GAAAA,CAAAA,CAAsB,CAC1C,OAAOC,OAAQC,CAAAA,IAAAA,CAAKF,CAAM,CAAC,CAC7B,CCCMG,IAAAA,CAAAA,CAAgBC,GACpB,CAAA,4FACF,CAaMC,CAAAA,CAAAA,CAAc,CAClB,CAAA,UAAA,CAAA,CAAC,CAAE,SAAA,CAAAC,CAAW,CAAA,GAAGC,CAAM,CAAA,CAAGC,IACxBC,GAAgB,CAAA,CAAA,CAAA,IAAA,CAAf,CAAoB,GAAA,CAAKD,CAAK,CAAA,SAAA,CAAWT,CAAGI,CAAAA,CAAAA,EAAiBG,CAAAA,CAAS,CAAI,CAAA,GAAGC,CAAO,CAAA,CAEzF,EACAF,CAAAA,CAAM,YAA6B,CAAK,CAAA,IAAA,CAAA,WAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\nimport * as LabelPrimitive from \"@radix-ui/react-label\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/utils/index\"\n\nconst labelVariants = cva(\n \"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70\"\n)\n\nexport interface LabelProps\n extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>,\n VariantProps<typeof labelVariants> {}\n\n/**\n * Label component for creating accessible labels.\n * Built on top of Radix UI's Label primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-label--docs\n *\n */\nconst Label = React.forwardRef<React.ElementRef<typeof LabelPrimitive.Root>, LabelProps>(\n ({ className, ...props }, ref) => (\n <LabelPrimitive.Root ref={ref} className={cn(labelVariants(), className)} {...props} />\n )\n)\nLabel.displayName = LabelPrimitive.Root.displayName\n\nexport { Label }\n"]}
@@ -1,59 +1,60 @@
1
- import * as React$1 from 'react';
1
+ import * as React from 'react';
2
+ import React__default from 'react';
2
3
  import * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';
3
4
  import { VariantProps } from 'class-variance-authority';
4
- import * as class_variance_authority_types from 'class-variance-authority/types';
5
+ import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
5
6
 
6
7
  declare const navigationMenuTriggerStyle: (props?: ({
7
8
  variant?: "default" | "ghost" | "link" | "mobile" | null | undefined;
8
- } & class_variance_authority_types.ClassProp) | undefined) => string;
9
+ } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
9
10
 
10
- interface NavigationMenuProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root> {
11
+ interface NavigationMenuProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root> {
11
12
  /**
12
13
  * The content of the navigation menu
13
14
  */
14
- children: React.ReactNode;
15
+ children: React__default.ReactNode;
15
16
  /**
16
17
  * Optional className for the root element
17
18
  */
18
19
  className?: string;
19
20
  }
20
- interface NavigationMenuListProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List> {
21
+ interface NavigationMenuListProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List> {
21
22
  /**
22
23
  * Optional className for the list element
23
24
  */
24
25
  className?: string;
25
26
  }
26
- interface NavigationMenuItemProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item> {
27
+ interface NavigationMenuItemProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item> {
27
28
  /**
28
29
  * Optional className for the item element
29
30
  */
30
31
  className?: string;
31
32
  }
32
- interface NavigationMenuTriggerProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>, VariantProps<typeof navigationMenuTriggerStyle> {
33
+ interface NavigationMenuTriggerProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>, VariantProps<typeof navigationMenuTriggerStyle> {
33
34
  /**
34
35
  * Optional className for the trigger element
35
36
  */
36
37
  className?: string;
37
38
  }
38
- interface NavigationMenuContentProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content> {
39
+ interface NavigationMenuContentProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content> {
39
40
  /**
40
41
  * Optional className for the content element
41
42
  */
42
43
  className?: string;
43
44
  }
44
- interface NavigationMenuLinkProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link> {
45
+ interface NavigationMenuLinkProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link> {
45
46
  /**
46
47
  * Optional className for the link element
47
48
  */
48
49
  className?: string;
49
50
  }
50
- interface NavigationMenuViewportProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport> {
51
+ interface NavigationMenuViewportProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport> {
51
52
  /**
52
53
  * Optional className for the viewport element
53
54
  */
54
55
  className?: string;
55
56
  }
56
- interface NavigationMenuIndicatorProps extends React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator> {
57
+ interface NavigationMenuIndicatorProps extends React__default.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator> {
57
58
  /**
58
59
  * Optional className for the indicator element
59
60
  */
@@ -91,13 +92,13 @@ interface NavigationMenuIndicatorProps extends React.ComponentPropsWithoutRef<ty
91
92
  * </NavigationMenu>
92
93
  * ```
93
94
  */
94
- declare const NavigationMenu: React$1.ForwardRefExoticComponent<NavigationMenuProps & React$1.RefAttributes<HTMLElement>>;
95
- declare const NavigationMenuList: React$1.ForwardRefExoticComponent<NavigationMenuListProps & React$1.RefAttributes<HTMLUListElement>>;
96
- declare const NavigationMenuItem: React$1.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuItemProps & React$1.RefAttributes<HTMLLIElement>>;
97
- declare const NavigationMenuTrigger: React$1.ForwardRefExoticComponent<NavigationMenuTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
98
- declare const NavigationMenuContent: React$1.ForwardRefExoticComponent<NavigationMenuContentProps & React$1.RefAttributes<HTMLDivElement>>;
99
- declare const NavigationMenuLink: React$1.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuLinkProps & React$1.RefAttributes<HTMLAnchorElement>>;
100
- declare const NavigationMenuViewport: React$1.ForwardRefExoticComponent<NavigationMenuViewportProps & React$1.RefAttributes<HTMLDivElement>>;
101
- declare const NavigationMenuIndicator: React$1.ForwardRefExoticComponent<NavigationMenuIndicatorProps & React$1.RefAttributes<HTMLDivElement>>;
95
+ declare const NavigationMenu: React.ForwardRefExoticComponent<NavigationMenuProps & React.RefAttributes<HTMLElement>>;
96
+ declare const NavigationMenuList: React.ForwardRefExoticComponent<NavigationMenuListProps & React.RefAttributes<HTMLUListElement>>;
97
+ declare const NavigationMenuItem: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuItemProps & React.RefAttributes<HTMLLIElement>>;
98
+ declare const NavigationMenuTrigger: React.ForwardRefExoticComponent<NavigationMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
99
+ declare const NavigationMenuContent: React.ForwardRefExoticComponent<NavigationMenuContentProps & React.RefAttributes<HTMLDivElement>>;
100
+ declare const NavigationMenuLink: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuLinkProps & React.RefAttributes<HTMLAnchorElement>>;
101
+ declare const NavigationMenuViewport: React.ForwardRefExoticComponent<NavigationMenuViewportProps & React.RefAttributes<HTMLDivElement>>;
102
+ declare const NavigationMenuIndicator: React.ForwardRefExoticComponent<NavigationMenuIndicatorProps & React.RefAttributes<HTMLDivElement>>;
102
103
 
103
104
  export { NavigationMenu, NavigationMenuContent, type NavigationMenuContentProps, NavigationMenuIndicator, type NavigationMenuIndicatorProps, NavigationMenuItem, type NavigationMenuItemProps, NavigationMenuLink, type NavigationMenuLinkProps, NavigationMenuList, type NavigationMenuListProps, type NavigationMenuProps, NavigationMenuTrigger, type NavigationMenuTriggerProps, NavigationMenuViewport, type NavigationMenuViewportProps };
@@ -1,2 +1,2 @@
1
- import*as r from'react';import*as e from'@radix-ui/react-navigation-menu';import {ChevronDown}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {cva}from'class-variance-authority';import {jsxs,jsx}from'react/jsx-runtime';function o(...t){return twMerge(clsx(t))}var v=cva("group inline-flex h-10 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50",{variants:{variant:{default:"text-foreground",ghost:"hover:bg-transparent hover:underline",link:"text-primary underline-offset-4 hover:underline",mobile:"w-full justify-between border-b border-border py-4 text-base font-medium"}},defaultVariants:{variant:"default"}});var u=r.forwardRef(({className:t,children:i,...a},s)=>jsxs(e.Root,{ref:s,className:o("relative z-10 flex max-w-max flex-1 items-center justify-center",t),...a,children:[i,jsx(m,{})]}));u.displayName=e.Root.displayName;var g=r.forwardRef(({className:t,...i},a)=>jsx(e.List,{ref:a,className:o("group flex flex-1 list-none items-center justify-center space-x-1",t),...i}));g.displayName=e.List.displayName;var w=e.Item,d=r.forwardRef(({className:t,children:i,variant:a,...s},N)=>jsxs(e.Trigger,{ref:N,className:o(v({variant:a}),t),...s,children:[i," ",jsx(ChevronDown,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));d.displayName=e.Trigger.displayName;var p=r.forwardRef(({className:t,...i},a)=>jsx(e.Content,{ref:a,className:o("left-0 top-0 w-full data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 md:absolute md:w-auto",t),...i}));p.displayName=e.Content.displayName;var R=e.Link,m=r.forwardRef(({className:t,...i},a)=>jsx("div",{className:o("absolute left-0 top-full flex justify-center"),children:jsx(e.Viewport,{className:o("origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]",t),ref:a,...i})}));m.displayName=e.Viewport.displayName;var f=r.forwardRef(({className:t,...i},a)=>jsx(e.Indicator,{ref:a,className:o("top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in",t),...i,children:jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));f.displayName=e.Indicator.displayName;export{u as NavigationMenu,p as NavigationMenuContent,f as NavigationMenuIndicator,w as NavigationMenuItem,R as NavigationMenuLink,g as NavigationMenuList,d as NavigationMenuTrigger,m as NavigationMenuViewport};//# sourceMappingURL=navigation-menu.mjs.map
2
- //# sourceMappingURL=navigation-menu.mjs.map
1
+ import*as r from'react';import*as e from'@radix-ui/react-navigation-menu';import {ChevronDown}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {cva}from'class-variance-authority';import {jsxs,jsx}from'react/jsx-runtime';function o(...t){return twMerge(clsx(t))}var v=cva("group inline-flex h-10 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50",{variants:{variant:{default:"text-foreground",ghost:"hover:bg-transparent hover:underline",link:"text-primary underline-offset-4 hover:underline",mobile:"w-full justify-between border-b border-border py-4 text-base font-medium"}},defaultVariants:{variant:"default"}});var u=r.forwardRef(({className:t,children:i,...a},s)=>jsxs(e.Root,{ref:s,className:o("relative z-10 flex max-w-max flex-1 items-center justify-center",t),...a,children:[i,jsx(m,{})]}));u.displayName=e.Root.displayName;var g=r.forwardRef(({className:t,...i},a)=>jsx(e.List,{ref:a,className:o("group flex flex-1 list-none items-center justify-center space-x-1",t),...i}));g.displayName=e.List.displayName;var w=e.Item,d=r.forwardRef(({className:t,children:i,variant:a,...s},N)=>jsxs(e.Trigger,{ref:N,className:o(v({variant:a}),t),...s,children:[i," ",jsx(ChevronDown,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));d.displayName=e.Trigger.displayName;var p=r.forwardRef(({className:t,...i},a)=>jsx(e.Content,{ref:a,className:o("left-0 top-0 w-full data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 md:absolute md:w-auto",t),...i}));p.displayName=e.Content.displayName;var R=e.Link,m=r.forwardRef(({className:t,...i},a)=>jsx("div",{className:o("absolute left-0 top-full flex justify-center"),children:jsx(e.Viewport,{className:o("origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]",t),ref:a,...i})}));m.displayName=e.Viewport.displayName;var f=r.forwardRef(({className:t,...i},a)=>jsx(e.Indicator,{ref:a,className:o("top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in",t),...i,children:jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));f.displayName=e.Indicator.displayName;export{u as NavigationMenu,p as NavigationMenuContent,f as NavigationMenuIndicator,w as NavigationMenuItem,R as NavigationMenuLink,g as NavigationMenuList,d as NavigationMenuTrigger,m as NavigationMenuViewport};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/molecules/navigation-menu/navigation-menu.variants.ts","../../src/components/molecules/navigation-menu/navigation-menu.tsx"],"names":["cn","inputs","twMerge","clsx","navigationMenuTriggerStyle","cva","NavigationMenu","className","children","props","ref","jsxs","jsx","NavigationMenuViewport","NavigationMenuList","NavigationMenuItem","NavigationMenuTrigger","variant","ChevronDown","NavigationMenuContent","NavigationMenuLink","Nav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AA,GAAGD,CACN,CAAA,CAAA,CACF,CACD,EACDI,EAAuB,WAAsC,CAAA,CAAA,CAAA,QAAA,CAAS,WAEtE,CAAA,IAAMQ,CAAgC,CAAA,CAAA,CAAA,UAAA,CAGpC,CAAC,CAAE,UAAAd,CAAW,CAAA,GAAGE,CAAM,CAAA,CAAGC,CAC1BE,GAAAA,GAAAA,CAAyB,CAAxB,CAAA,SAAA,CAAA,CACC,IAAKF,CACL,CAAA,SAAA,CAAWV,CACT,CAAA,8LAAA,CACAO,CACF,CAAA,CACC,GAAGE,CAAAA,CAEJ,SAAAG,GAAC,CAAA,KAAA,CAAA,CAAI,SAAU,CAAA,wEAAA,CAAyE,CAC1F,CAAA,CACD,EACDS,CAAAA,CAAwB,YAAsC,CAAU,CAAA,SAAA,CAAA,WAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import { cva } from \"class-variance-authority\"\n\nexport const navigationMenuTriggerStyle = cva(\n \"group inline-flex h-10 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50\",\n {\n variants: {\n variant: {\n default: \"text-foreground\",\n ghost: \"hover:bg-transparent hover:underline\",\n link: \"text-primary underline-offset-4 hover:underline\",\n mobile: \"w-full justify-between border-b border-border py-4 text-base font-medium\"\n }\n },\n defaultVariants: {\n variant: \"default\"\n }\n }\n)\n","import * as React from \"react\"\nimport * as NavigationMenuPrimitive from \"@radix-ui/react-navigation-menu\"\nimport { ChevronDown } from \"lucide-react\"\nimport { cn } from \"@/utils/index\"\nimport { navigationMenuTriggerStyle } from \"./navigation-menu.variants\"\nimport type {\n NavigationMenuProps,\n NavigationMenuListProps,\n NavigationMenuItemProps,\n NavigationMenuTriggerProps,\n NavigationMenuContentProps,\n NavigationMenuLinkProps,\n NavigationMenuViewportProps,\n NavigationMenuIndicatorProps\n} from \"./navigation-menu.types\"\n\n/**\n * NavigationMenu component for creating accessible navigation menus with dropdowns.\n * Built on top of Radix UI's NavigationMenu primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/molecules-navigation-menu--docs\n *\n * @example\n * ```\n * <NavigationMenu>\n * <NavigationMenuList>\n * <NavigationMenuItem>\n * <NavigationMenuTrigger>Getting Started</NavigationMenuTrigger>\n * <NavigationMenuContent>\n * <ul className=\"grid gap-3 p-4 md:w-[400px] lg:w-[500px]\">\n * <li className=\"row-span-3\">\n * <NavigationMenuLink asChild>\n * <a className=\"flex h-full w-full select-none flex-col justify-end rounded-md bg-gradient-to-b from-muted/50 to-muted p-6 no-underline outline-none focus:shadow-md\">\n * <div className=\"mb-2 mt-4 text-lg font-medium\">shadcn/ui</div>\n * <p className=\"text-sm leading-tight text-muted-foreground\">\n * Beautifully designed components built with Radix UI and Tailwind CSS.\n * </p>\n * </a>\n * </NavigationMenuLink>\n * </li>\n * </ul>\n * </NavigationMenuContent>\n * </NavigationMenuItem>\n * </NavigationMenuList>\n * </NavigationMenu>\n * ```\n */\nconst NavigationMenu = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Root>,\n NavigationMenuProps\n>(({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\"relative z-10 flex max-w-max flex-1 items-center justify-center\", className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n))\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName\n\nconst NavigationMenuList = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.List>,\n NavigationMenuListProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\"group flex flex-1 list-none items-center justify-center space-x-1\", className)}\n {...props}\n />\n))\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item\n\nconst NavigationMenuTrigger = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Trigger>,\n NavigationMenuTriggerProps\n>(({ className, children, variant, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={cn(navigationMenuTriggerStyle({ variant }), className)}\n {...props}\n >\n {children}{\" \"}\n <ChevronDown\n className=\"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180\"\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n))\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName\n\nconst NavigationMenuContent = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Content>,\n NavigationMenuContentProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n \"left-0 top-0 w-full data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 md:absolute md:w-auto\",\n className\n )}\n {...props}\n />\n))\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link\n\nconst NavigationMenuViewport = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Viewport>,\n NavigationMenuViewportProps\n>(({ className, ...props }, ref) => (\n <div className={cn(\"absolute left-0 top-full flex justify-center\")}>\n <NavigationMenuPrimitive.Viewport\n className={cn(\n \"origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]\",\n className\n )}\n ref={ref}\n {...props}\n />\n </div>\n))\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName\n\nconst NavigationMenuIndicator = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Indicator>,\n NavigationMenuIndicatorProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n \"top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in\",\n className\n )}\n {...props}\n >\n <div className=\"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md\" />\n </NavigationMenuPrimitive.Indicator>\n))\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName\n\nexport {\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n NavigationMenuIndicator,\n NavigationMenuViewport\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
 
3
- interface PageLoaderProps {
3
+ type PageLoaderProps = {
4
4
  /**
5
5
  * Optional className to extend the component's styles
6
6
  */
@@ -17,7 +17,7 @@ interface PageLoaderProps {
17
17
  * Optional color of the loader (default: "primary")
18
18
  */
19
19
  color?: "primary" | "secondary" | "accent" | "muted" | "destructive" | string;
20
- }
20
+ };
21
21
  /**
22
22
  * PageLoader component for displaying a loading indicator.
23
23
  *
@@ -1,2 +1,2 @@
1
- import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {Loader2}from'lucide-react';import {jsxs,jsx}from'react/jsx-runtime';function e(...r){return twMerge(clsx(r))}function b({className:r,size:o="default",text:t,color:s="primary"}){let c={sm:"h-4 w-4",default:"h-8 w-8",lg:"h-12 w-12"},i={primary:"text-primary",secondary:"text-secondary",accent:"text-accent",muted:"text-muted-foreground",destructive:"text-destructive"}[s]||`text-[${s}]`;return jsxs("div",{className:e("fixed inset-0 z-50 flex min-h-screen flex-col items-center justify-center bg-background/80 backdrop-blur-sm",r),role:"alert","aria-live":"assertive",children:[jsx(Loader2,{className:e("animate-spin",i,c[o]),"aria-hidden":"true"}),t&&jsx("p",{className:"mt-4 text-sm text-muted-foreground","aria-label":t,children:t})]})}export{b as PageLoader};//# sourceMappingURL=page-loader.mjs.map
2
- //# sourceMappingURL=page-loader.mjs.map
1
+ import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {Loader2}from'lucide-react';import {jsxs,jsx}from'react/jsx-runtime';function e(...r){return twMerge(clsx(r))}function b({className:r,size:o="default",text:t,color:s="primary"}){let c={sm:"h-4 w-4",default:"h-8 w-8",lg:"h-12 w-12"},i={primary:"text-primary",secondary:"text-secondary",accent:"text-accent",muted:"text-muted-foreground",destructive:"text-destructive"}[s]||`text-[${s}]`;return jsxs("div",{className:e("fixed inset-0 z-50 flex min-h-screen flex-col items-center justify-center bg-background/80 backdrop-blur-sm",r),role:"alert","aria-live":"assertive",children:[jsx(Loader2,{className:e("animate-spin",i,c[o]),"aria-hidden":"true"}),t&&jsx("p",{className:"mt-4 text-sm text-muted-foreground","aria-label":t,children:t})]})}export{b as PageLoader};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/page-loader/page-loader.tsx"],"names":["cn","inputs","twMerge","clsx","PageLoader","className","size","text","color","sizeClasses","loaderColor","jsxs","jsx","Loader2"],"mappings":"yIAGO,SAASA,CAAMC,CAAAA,GAAAA,CAAAA,CAAsB,CAC1C,OAAOC,QAAQC,IAAKF,CAAAA,CAAM,CAAC,CAC7B,CCwBO,SAASG,CAAW,CAAA,CACzB,SAAAC,CAAAA,CAAAA,CACA,KAAAC,CAAO,CAAA,SAAA,CACP,IAAAC,CAAAA,CAAAA,CACA,KAAAC,CAAAA,CAAAA,CAAQ,SACV,CAAoB,CAAA,CAClB,IAAMC,CAAAA,CAAc,CAClB,EAAA,CAAI,UACJ,OAAS,CAAA,SAAA,CACT,EAAI,CAAA,WACN,CAUMC,CAAAA,CAAAA,CARe,CACnB,OAAS,CAAA,cAAA,CACT,SAAW,CAAA,gBAAA,CACX,MAAQ,CAAA,aAAA,CACR,MAAO,uBACP,CAAA,WAAA,CAAa,kBACf,CAAA,CAEiCF,CAAkC,CAAA,EAAK,SAASA,CAAK,CAAA,CAAA,CAAA,CAEtF,OACEG,IAAAA,CAAC,KACC,CAAA,CAAA,SAAA,CAAWX,EACT,6GACAK,CAAAA,CACF,CACA,CAAA,IAAA,CAAK,OACL,CAAA,WAAA,CAAU,YAEV,QAAAO,CAAAA,CAAAA,GAAAA,CAACC,OAAA,CAAA,CAAQ,SAAWb,CAAAA,CAAAA,CAAG,eAAgBU,CAAaD,CAAAA,CAAAA,CAAYH,CAAI,CAAC,CAAG,CAAA,aAAA,CAAY,OAAO,CAC1FC,CAAAA,CAAAA,EACCK,GAAC,CAAA,GAAA,CAAA,CAAE,SAAU,CAAA,oCAAA,CAAqC,aAAYL,CAC3D,CAAA,QAAA,CAAAA,CACH,CAAA,CAAA,CAAA,CAEJ,CAEJ","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import { cn } from \"@/utils\"\nimport { Loader2 } from \"lucide-react\"\n\nexport type PageLoaderProps = {\n /**\n * Optional className to extend the component's styles\n */\n className?: string\n /**\n * Optional size of the loader (default: \"default\")\n */\n size?: \"sm\" | \"default\" | \"lg\"\n /**\n * Optional text to display below the loader\n */\n text?: string\n /**\n * Optional color of the loader (default: \"primary\")\n */\n color?: \"primary\" | \"secondary\" | \"accent\" | \"muted\" | \"destructive\" | string\n}\n\n/**\n * PageLoader component for displaying a loading indicator.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-page-loader--docs\n *\n */\n\nexport function PageLoader({\n className,\n size = \"default\",\n text,\n color = \"primary\"\n}: PageLoaderProps) {\n const sizeClasses = {\n sm: \"h-4 w-4\",\n default: \"h-8 w-8\",\n lg: \"h-12 w-12\"\n }\n\n const colorClasses = {\n primary: \"text-primary\",\n secondary: \"text-secondary\",\n accent: \"text-accent\",\n muted: \"text-muted-foreground\",\n destructive: \"text-destructive\"\n }\n\n const loaderColor = colorClasses[color as keyof typeof colorClasses] || `text-[${color}]`\n\n return (\n <div\n className={cn(\n \"fixed inset-0 z-50 flex min-h-screen flex-col items-center justify-center bg-background/80 backdrop-blur-sm\",\n className\n )}\n role=\"alert\"\n aria-live=\"assertive\"\n >\n <Loader2 className={cn(\"animate-spin\", loaderColor, sizeClasses[size])} aria-hidden=\"true\" />\n {text && (\n <p className=\"mt-4 text-sm text-muted-foreground\" aria-label={text}>\n {text}\n </p>\n )}\n </div>\n )\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as React from 'react';
3
3
  import { VariantProps } from 'class-variance-authority';
4
- import * as class_variance_authority_types from 'class-variance-authority/types';
4
+ import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
5
5
 
6
6
  /**
7
7
  * Props interface for the Button component.
@@ -44,7 +44,7 @@ interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, Var
44
44
  declare const buttonVariants: (props?: ({
45
45
  variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | null | undefined;
46
46
  size?: "default" | "sm" | "lg" | "icon" | null | undefined;
47
- } & class_variance_authority_types.ClassProp) | undefined) => string;
47
+ } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
48
48
 
49
49
  /**
50
50
  * Pagination component that provides navigation controls for paginated content.
@@ -1,2 +1,2 @@
1
- import*as g from'react';import {Loader2,ChevronLeft,ChevronRight,MoreHorizontal}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {Slot}from'@radix-ui/react-slot';import {cva}from'class-variance-authority';import {jsx,jsxs}from'react/jsx-runtime';function n(...a){return twMerge(clsx(a))}var u=cva("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),G=g.forwardRef(({className:a,variant:e,size:o,asChild:s=false,startIcon:r,endIcon:b,loading:l=false,disabled:B,children:p,type:y="button","aria-label":M,...m},v)=>{let h=s?Slot:"button",i=B||l,x=M||(typeof p=="string"?p:void 0),z=c=>{(c.key==="Enter"||c.key===" ")&&(c.preventDefault(),!i&&m.onClick&&m.onClick(c));};return s?jsx(h,{className:n(u({variant:e,size:o,className:a})),ref:v,disabled:i,type:y,"aria-label":x,"aria-disabled":i,...m,children:p}):jsxs(h,{className:n(u({variant:e,size:o,className:a})),ref:v,disabled:i,type:y,"aria-label":x,"aria-disabled":i,onKeyDown:z,...m,children:[l&&jsx(Loader2,{className:"mr-2 h-4 w-4 animate-spin",role:"status","aria-label":"Loading","aria-hidden":"true"}),!l&&r&&jsx("span",{className:"mr-2","aria-hidden":"true",children:r}),p,!l&&b&&jsx("span",{className:"ml-2","aria-hidden":"true",children:b})]})});G.displayName="Button";var w=({className:a,...e})=>jsx("nav",{role:"navigation","aria-label":"pagination",className:n("mx-auto flex w-full justify-center",a),...e});w.displayName="Pagination";var L=g.forwardRef(({className:a,...e},o)=>jsx("ul",{ref:o,className:n("flex flex-row items-center gap-1",a),...e}));L.displayName="PaginationContent";var k=g.forwardRef(({className:a,...e},o)=>jsx("li",{ref:o,className:n("",a),...e}));k.displayName="PaginationItem";var f=({className:a,isActive:e,size:o="icon",children:s,...r})=>jsx("a",{"aria-current":e?"page":void 0,className:n(u({variant:e?"outline":"ghost",size:o}),a),...r,children:s});f.displayName="PaginationLink";var C=({className:a,...e})=>jsxs(f,{"aria-label":"Go to previous page",size:"default",className:n("gap-1 pl-2.5",a),...e,children:[jsx(ChevronLeft,{className:"h-4 w-4"}),jsx("span",{children:"Previous"})]});C.displayName="PaginationPrevious";var R=({className:a,...e})=>jsxs(f,{"aria-label":"Go to next page",size:"default",className:n("gap-1 pr-2.5",a),...e,children:[jsx("span",{children:"Next"}),jsx(ChevronRight,{className:"h-4 w-4"})]});R.displayName="PaginationNext";var E=({className:a,...e})=>jsxs("span",{"aria-hidden":true,className:n("flex h-9 w-9 items-center justify-center",a),...e,children:[jsx(MoreHorizontal,{className:"h-4 w-4"}),jsx("span",{className:"sr-only",children:"More pages"})]});E.displayName="PaginationEllipsis";export{w as Pagination,L as PaginationContent,E as PaginationEllipsis,k as PaginationItem,f as PaginationLink,R as PaginationNext,C as PaginationPrevious};//# sourceMappingURL=pagination.mjs.map
2
- //# sourceMappingURL=pagination.mjs.map
1
+ import*as g from'react';import {Loader2,ChevronLeft,ChevronRight,MoreHorizontal}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {Slot}from'@radix-ui/react-slot';import {cva}from'class-variance-authority';import {jsx,jsxs}from'react/jsx-runtime';function n(...a){return twMerge(clsx(a))}var u=cva("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),G=g.forwardRef(({className:a,variant:e,size:o,asChild:s=false,startIcon:r,endIcon:b,loading:l=false,disabled:B,children:p,type:y="button","aria-label":M,...m},v)=>{let h=s?Slot:"button",i=B||l,x=M||(typeof p=="string"?p:void 0),z=c=>{(c.key==="Enter"||c.key===" ")&&(c.preventDefault(),!i&&m.onClick&&m.onClick(c));};return s?jsx(h,{className:n(u({variant:e,size:o,className:a})),ref:v,disabled:i,type:y,"aria-label":x,"aria-disabled":i,...m,children:p}):jsxs(h,{className:n(u({variant:e,size:o,className:a})),ref:v,disabled:i,type:y,"aria-label":x,"aria-disabled":i,onKeyDown:z,...m,children:[l&&jsx(Loader2,{className:"mr-2 h-4 w-4 animate-spin",role:"status","aria-label":"Loading","aria-hidden":"true"}),!l&&r&&jsx("span",{className:"mr-2","aria-hidden":"true",children:r}),p,!l&&b&&jsx("span",{className:"ml-2","aria-hidden":"true",children:b})]})});G.displayName="Button";var w=({className:a,...e})=>jsx("nav",{role:"navigation","aria-label":"pagination",className:n("mx-auto flex w-full justify-center",a),...e});w.displayName="Pagination";var L=g.forwardRef(({className:a,...e},o)=>jsx("ul",{ref:o,className:n("flex flex-row items-center gap-1",a),...e}));L.displayName="PaginationContent";var k=g.forwardRef(({className:a,...e},o)=>jsx("li",{ref:o,className:n("",a),...e}));k.displayName="PaginationItem";var f=({className:a,isActive:e,size:o="icon",children:s,...r})=>jsx("a",{"aria-current":e?"page":void 0,className:n(u({variant:e?"outline":"ghost",size:o}),a),...r,children:s});f.displayName="PaginationLink";var C=({className:a,...e})=>jsxs(f,{"aria-label":"Go to previous page",size:"default",className:n("gap-1 pl-2.5",a),...e,children:[jsx(ChevronLeft,{className:"h-4 w-4"}),jsx("span",{children:"Previous"})]});C.displayName="PaginationPrevious";var R=({className:a,...e})=>jsxs(f,{"aria-label":"Go to next page",size:"default",className:n("gap-1 pr-2.5",a),...e,children:[jsx("span",{children:"Next"}),jsx(ChevronRight,{className:"h-4 w-4"})]});R.displayName="PaginationNext";var E=({className:a,...e})=>jsxs("span",{"aria-hidden":true,className:n("flex h-9 w-9 items-center justify-center",a),...e,children:[jsx(MoreHorizontal,{className:"h-4 w-4"}),jsx("span",{className:"sr-only",children:"More pages"})]});E.displayName="PaginationEllipsis";export{w as Pagination,L as PaginationContent,E as PaginationEllipsis,k as PaginationItem,f as PaginationLink,R as PaginationNext,C as PaginationPrevious};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/button/button.tsx","../../src/components/atoms/pagination/pagination.tsx"],"names":["cn","inputs","twMerge","clsx","buttonVariants","cva","Button","N","className","variant","size","asChild","startIcon","endIcon","loading","disabled","children","type","ariaLabel","props","ref","Comp","Slot","isDisabled","buttonAriaLabel","handleKeyDown","event","jsx","jsxs","Loader2","Pagination","PaginationContent","PaginationItem","PaginationLink","isActive","PaginationPrevious","ChevronLeft","PaginationNext","ChevronRight","PaginationEllipsis","MoreHorizontal"],"mappings":"4RAGO,SAASA,CAAAA,CAAAA,GAAMC,CAAsB,CAAA,CAC1C,OAAOC,OAAAA,CAAQC,IAAKF,CAAAA,CAAM,CAAC,CAC7B,CCYA,IAAMG,CAAiBC,CAAAA,GAAAA,CACrB,wRACA,CAAA,CACE,QAAU,CAAA,CACR,OAAS,CAAA,CACP,OAA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AAAA,CAAW,GAAGW,CAAM,CAChDS,GAAAA,IAAAA,CAAC,MACC,CAAA,CAAA,aAAA,CAAW,IACX,CAAA,SAAA,CAAW5B,CAAG,CAAA,0CAAA,CAA4CQ,CAAS,CAAA,CAClE,GAAGW,CAAAA,CAEJ,QAAAQ,CAAAA,CAAAA,GAAAA,CAACa,cAAA,CAAA,CAAe,SAAU,CAAA,SAAA,CAAU,CACpCb,CAAAA,GAAAA,CAAC,MAAK,CAAA,CAAA,SAAA,CAAU,SAAU,CAAA,QAAA,CAAA,YAAA,CAAU,CACtC,CAAA,CAAA,EAEFY,EAAmB,WAAc,CAAA,oBAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\nimport { Slot } from \"@radix-ui/react-slot\"\nimport { cva } from \"class-variance-authority\"\nimport { cn } from \"@/utils/cn\"\nimport { Loader2 } from \"lucide-react\"\nimport { ButtonProps } from \"./button.types\"\n\n/**\n * Button variant styles using class-variance-authority.\n * Defines the visual styles for different button variants and sizes.\n * Follows WCAG 2.1 Level AA guidelines for accessibility.\n *\n * @example\n * ```tsx\n * <Button variant=\"primary\" size=\"lg\">Click me</Button>\n * ```\n */\nconst buttonVariants = cva(\n \"inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50\",\n {\n variants: {\n variant: {\n default: \"bg-primary text-primary-foreground shadow hover:bg-primary/90\",\n destructive: \"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90\",\n outline:\n \"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground\",\n secondary: \"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80\",\n ghost: \"hover:bg-accent hover:text-accent-foreground\",\n link: \"text-primary underline-offset-4 hover:underline\"\n } as const,\n size: {\n default: \"h-9 px-4 py-2\",\n sm: \"h-8 rounded-md px-3 text-xs\",\n lg: \"h-10 rounded-md px-8\",\n icon: \"h-9 w-9\"\n } as const\n },\n defaultVariants: {\n variant: \"default\",\n size: \"default\"\n }\n }\n)\n\n/**\n * A versatile button component that supports multiple variants, sizes, and can be rendered as a child component.\n * Built on top of Radix UI's Slot primitive for maximum flexibility.\n * Implements proper accessibility features and follows WCAG 2.1 Level AA guidelines.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-button--docs\n *\n * @component\n * @example\n * ```tsx\n * // Default button\n * <Button>Click me</Button>\n *\n * // Destructive button with small size\n * <Button variant=\"destructive\" size=\"sm\">Delete</Button>\n *\n * // As a link\n * <Button variant=\"link\" asChild>\n * <a href=\"/about\">About</a>\n * </Button>\n *\n * // With icons\n * <Button startIcon={<Icon />}>With Start Icon</Button>\n * <Button endIcon={<Icon />}>With End Icon</Button>\n *\n * // Loading state\n * <Button loading>Loading</Button>\n * ```\n *\n * @param {ButtonProps} props - The component props\n * @param {React.Ref<HTMLButtonElement>} ref - Forwarded ref\n * @returns {JSX.Element} A button element\n */\nconst Button = React.forwardRef<HTMLButtonElement, ButtonProps>(\n (\n {\n className,\n variant,\n size,\n asChild = false,\n startIcon,\n endIcon,\n loading = false,\n disabled,\n children,\n type = \"button\",\n \"aria-label\": ariaLabel,\n ...props\n },\n ref\n ) => {\n const Comp = asChild ? Slot : \"button\"\n const isDisabled = disabled || loading\n const buttonAriaLabel = ariaLabel || (typeof children === \"string\" ? children : undefined)\n\n // Handle keyboard interaction\n const handleKeyDown = (event: React.KeyboardEvent) => {\n if (event.key === \"Enter\" || event.key === \" \") {\n event.preventDefault()\n if (!isDisabled && props.onClick) {\n props.onClick(event as unknown as React.MouseEvent<HTMLButtonElement>)\n }\n }\n }\n\n if (asChild) {\n return (\n <Comp\n className={cn(buttonVariants({ variant, size, className }))}\n ref={ref}\n disabled={isDisabled}\n type={type}\n aria-label={buttonAriaLabel}\n aria-disabled={isDisabled}\n {...props}\n >\n {children}\n </Comp>\n )\n }\n\n return (\n <Comp\n className={cn(buttonVariants({ variant, size, className }))}\n ref={ref}\n disabled={isDisabled}\n type={type}\n aria-label={buttonAriaLabel}\n aria-disabled={isDisabled}\n onKeyDown={handleKeyDown}\n {...props}\n >\n {loading && (\n <Loader2\n className=\"mr-2 h-4 w-4 animate-spin\"\n role=\"status\"\n aria-label=\"Loading\"\n aria-hidden=\"true\"\n />\n )}\n {!loading && startIcon && (\n <span className=\"mr-2\" aria-hidden=\"true\">\n {startIcon}\n </span>\n )}\n {children}\n {!loading && endIcon && (\n <span className=\"ml-2\" aria-hidden=\"true\">\n {endIcon}\n </span>\n )}\n </Comp>\n )\n }\n)\nButton.displayName = \"Button\"\n\nexport { Button, buttonVariants }\n","import * as React from \"react\"\nimport { ChevronLeft, ChevronRight, MoreHorizontal } from \"lucide-react\"\n\nimport { cn } from \"@/utils/index\"\nimport { ButtonProps, buttonVariants } from \"@/components/atoms/button\"\n\n/**\n * Pagination component that provides navigation controls for paginated content.\n * Built on top of shadcn/ui's button component.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-pagination--docs\n *\n * @example\n * ```tsx\n * <Pagination>\n * <PaginationContent>\n * <PaginationItem>\n * <PaginationPrevious href=\"#\" />\n * </PaginationItem>\n * <PaginationItem>\n * <PaginationLink href=\"#\" isActive>1</PaginationLink>\n * </PaginationItem>\n * <PaginationItem>\n * <PaginationEllipsis />\n * </PaginationItem>\n * <PaginationItem>\n * <PaginationNext href=\"#\" />\n * </PaginationItem>\n * </PaginationContent>\n * </Pagination>\n * ```\n */\nconst Pagination = ({ className, ...props }: React.ComponentProps<\"nav\">) => (\n <nav\n role=\"navigation\"\n aria-label=\"pagination\"\n className={cn(\"mx-auto flex w-full justify-center\", className)}\n {...props}\n />\n)\nPagination.displayName = \"Pagination\"\n\nconst PaginationContent = React.forwardRef<HTMLUListElement, React.ComponentProps<\"ul\">>(\n ({ className, ...props }, ref) => (\n <ul ref={ref} className={cn(\"flex flex-row items-center gap-1\", className)} {...props} />\n )\n)\nPaginationContent.displayName = \"PaginationContent\"\n\nconst PaginationItem = React.forwardRef<HTMLLIElement, React.ComponentProps<\"li\">>(\n ({ className, ...props }, ref) => <li ref={ref} className={cn(\"\", className)} {...props} />\n)\nPaginationItem.displayName = \"PaginationItem\"\n\ntype PaginationLinkProps = {\n isActive?: boolean\n} & Pick<ButtonProps, \"size\"> &\n React.ComponentProps<\"a\">\n\nconst PaginationLink = ({\n className,\n isActive,\n size = \"icon\",\n children,\n ...props\n}: PaginationLinkProps) => (\n <a\n aria-current={isActive ? \"page\" : undefined}\n className={cn(\n buttonVariants({\n variant: isActive ? \"outline\" : \"ghost\",\n size\n }),\n className\n )}\n {...props}\n >\n {children}\n </a>\n)\nPaginationLink.displayName = \"PaginationLink\"\n\nconst PaginationPrevious = ({\n className,\n ...props\n}: React.ComponentProps<typeof PaginationLink>) => (\n <PaginationLink\n aria-label=\"Go to previous page\"\n size=\"default\"\n className={cn(\"gap-1 pl-2.5\", className)}\n {...props}\n >\n <ChevronLeft className=\"h-4 w-4\" />\n <span>Previous</span>\n </PaginationLink>\n)\nPaginationPrevious.displayName = \"PaginationPrevious\"\n\nconst PaginationNext = ({ className, ...props }: React.ComponentProps<typeof PaginationLink>) => (\n <PaginationLink\n aria-label=\"Go to next page\"\n size=\"default\"\n className={cn(\"gap-1 pr-2.5\", className)}\n {...props}\n >\n <span>Next</span>\n <ChevronRight className=\"h-4 w-4\" />\n </PaginationLink>\n)\nPaginationNext.displayName = \"PaginationNext\"\n\nconst PaginationEllipsis = ({ className, ...props }: React.ComponentProps<\"span\">) => (\n <span\n aria-hidden\n className={cn(\"flex h-9 w-9 items-center justify-center\", className)}\n {...props}\n >\n <MoreHorizontal className=\"h-4 w-4\" />\n <span className=\"sr-only\">More pages</span>\n </span>\n)\nPaginationEllipsis.displayName = \"PaginationEllipsis\"\n\nexport {\n Pagination,\n PaginationContent,\n PaginationLink,\n PaginationItem,\n PaginationPrevious,\n PaginationNext,\n PaginationEllipsis\n}\n"]}
@@ -1,2 +1,2 @@
1
- import*as i from'react';import*as o from'@radix-ui/react-popover';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function t(...e){return twMerge(clsx(e))}var C=o.Root,R=o.Trigger,x=o.Anchor,f=i.forwardRef(({className:e,align:a="center",sideOffset:n=4,...p},m)=>jsx(o.Portal,{children:jsx(o.Content,{ref:m,align:a,sideOffset:n,className:t("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-popover-content-transform-origin]",e),...p})}));f.displayName=o.Content.displayName;export{C as Popover,x as PopoverAnchor,f as PopoverContent,R as PopoverTrigger};//# sourceMappingURL=popover.mjs.map
2
- //# sourceMappingURL=popover.mjs.map
1
+ import*as i from'react';import*as o from'@radix-ui/react-popover';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function t(...e){return twMerge(clsx(e))}var C=o.Root,R=o.Trigger,x=o.Anchor,f=i.forwardRef(({className:e,align:a="center",sideOffset:n=4,...p},m)=>jsx(o.Portal,{children:jsx(o.Content,{ref:m,align:a,sideOffset:n,className:t("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-popover-content-transform-origin]",e),...p})}));f.displayName=o.Content.displayName;export{C as Popover,x as PopoverAnchor,f as PopoverContent,R as PopoverTrigger};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/popover/popover.tsx"],"names":["cn","inputs","twMerge","clsx","Popover","PopoverTrigger","PopoverAnchor","PopoverContent","className","align","sideOffset","props","ref","jsx"],"mappings":"mKAGO,SAASA,KAAMC,CAAsB,CAAA,CAC1C,OAAOC,OAAAA,CAAQC,KAAKF,CAAM,CAAC,CAC7B,CCgBMG,IAAAA,CAAAA,CAA2B,OAE3BC,CAAkC,CAAA,CAAA,CAAA,OAAA,CAElCC,CAAiC,CAAA,CAAA,CAAA,MAAA,CAEjCC,EAAuB,CAG3B,CAAA,UAAA,CAAA,CAAC,CAAE,SAAA,CAAAC,EAAW,KAAAC,CAAAA,CAAAA,CAAQ,QAAU,CAAA,UAAA,CAAAC,EAAa,CAAG,CAAA,GAAGC,CAAM,CAAA,CAAGC,IAC5DC,GAAkB,CAAA,CAAA,CAAA,MAAA,CAAjB,CACC,QAAA,CAAAA,IAAkB,CAAjB,CAAA,OAAA,CAAA,CACC,GAAKD,CAAAA,CAAAA,CACL,MAAOH,CACP,CAAA,UAAA,CAAYC,CACZ,CAAA,SAAA,CAAWV,EACT,8dACAQ,CAAAA,CACF,CACC,CAAA,GAAGG,EACN,CACF,CAAA,CACD,EACDJ,CAAAA,CAAe,YAA+B,CAAQ,CAAA,OAAA,CAAA,WAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\"\n\nimport { cn } from \"@/utils/index\"\n\n/**\n * Popover component that displays content in a floating panel.\n * Built on top of Radix UI's Popover primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-popover--docs\n *\n * @example\n * ```tsx\n * <Popover>\n * <PopoverTrigger>Open Popover</PopoverTrigger>\n * <PopoverContent>\n * <p>Popover content goes here</p>\n * </PopoverContent>\n * </Popover>\n * ```\n */\nconst Popover = PopoverPrimitive.Root\n\nconst PopoverTrigger = PopoverPrimitive.Trigger\n\nconst PopoverAnchor = PopoverPrimitive.Anchor\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>\n>(({ className, align = \"center\", sideOffset = 4, ...props }, ref) => (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n ref={ref}\n align={align}\n sideOffset={sideOffset}\n className={cn(\n \"z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-popover-content-transform-origin]\",\n className\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n))\nPopoverContent.displayName = PopoverPrimitive.Content.displayName\n\nexport { Popover, PopoverTrigger, PopoverContent, PopoverAnchor }\n"]}
@@ -1,10 +1,10 @@
1
- import * as class_variance_authority_types from 'class-variance-authority/types';
1
+ import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
2
2
  import * as React from 'react';
3
3
  import * as LabelPrimitive from '@radix-ui/react-label';
4
4
  import { VariantProps } from 'class-variance-authority';
5
5
  import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
6
6
 
7
- declare const labelVariants: (props?: class_variance_authority_types.ClassProp | undefined) => string;
7
+ declare const labelVariants: (props?: class_variance_authority_dist_types.ClassProp | undefined) => string;
8
8
  interface LabelProps extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>, VariantProps<typeof labelVariants> {
9
9
  }
10
10
 
@@ -1,2 +1,2 @@
1
- import*as m from'react';import*as i from'@radix-ui/react-radio-group';import {Circle}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import*as s from'@radix-ui/react-label';import {cva}from'class-variance-authority';import {jsx}from'react/jsx-runtime';function r(...e){return twMerge(clsx(e))}var y=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),p=m.forwardRef(({className:e,...o},t)=>jsx(s.Root,{ref:t,className:r(y(),e),...o}));p.displayName=s.Root.displayName;var d=m.forwardRef(({className:e,...o},t)=>jsx(i.Root,{className:r("grid gap-3",e),...o,ref:t}));d.displayName=i.Root.displayName;var n=m.forwardRef(({className:e,...o},t)=>jsx(i.Item,{ref:t,className:r("aspect-square h-4 w-4 rounded-full border border-primary text-primary shadow focus:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),...o,children:jsx(i.Indicator,{className:"flex items-center justify-center",children:jsx(Circle,{className:"h-3.5 w-3.5 fill-primary"})})}));n.displayName=i.Item.displayName;var R=m.forwardRef(({className:e,...o},t)=>jsx("div",{ref:t,className:r("flex items-center gap-2",e),...o}));R.displayName="RadioItemContainer";var f=m.forwardRef(({className:e,...o},t)=>jsx(p,{ref:t,className:r("text-sm font-medium leading-none cursor-pointer peer-disabled:cursor-not-allowed peer-disabled:opacity-70",e),...o}));f.displayName="RadioItemLabel";export{d as RadioGroup,n as RadioGroupItem,R as RadioItemContainer,f as RadioItemLabel};//# sourceMappingURL=radio-group.mjs.map
2
- //# sourceMappingURL=radio-group.mjs.map
1
+ import*as m from'react';import*as i from'@radix-ui/react-radio-group';import {Circle}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import*as s from'@radix-ui/react-label';import {cva}from'class-variance-authority';import {jsx}from'react/jsx-runtime';function r(...e){return twMerge(clsx(e))}var y=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),p=m.forwardRef(({className:e,...o},t)=>jsx(s.Root,{ref:t,className:r(y(),e),...o}));p.displayName=s.Root.displayName;var d=m.forwardRef(({className:e,...o},t)=>jsx(i.Root,{className:r("grid gap-3",e),...o,ref:t}));d.displayName=i.Root.displayName;var n=m.forwardRef(({className:e,...o},t)=>jsx(i.Item,{ref:t,className:r("aspect-square h-4 w-4 rounded-full border border-primary text-primary shadow focus:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),...o,children:jsx(i.Indicator,{className:"flex items-center justify-center",children:jsx(Circle,{className:"h-3.5 w-3.5 fill-primary"})})}));n.displayName=i.Item.displayName;var R=m.forwardRef(({className:e,...o},t)=>jsx("div",{ref:t,className:r("flex items-center gap-2",e),...o}));R.displayName="RadioItemContainer";var f=m.forwardRef(({className:e,...o},t)=>jsx(p,{ref:t,className:r("text-sm font-medium leading-none cursor-pointer peer-disabled:cursor-not-allowed peer-disabled:opacity-70",e),...o}));f.displayName="RadioItemLabel";export{d as RadioGroup,n as RadioGroupItem,R as RadioItemContainer,f as RadioItemLabel};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/label/label.tsx","../../src/components/atoms/radio-group/radio-group.tsx"],"names":["cn","inputs","twMerge","clsx","labelVariants","cva","Label","l","className","props","ref","jsx","RadioGroup","RadioGroupItem","Circle","RadioItemContainer","RadioItemLabel"],"mappings":"4RAGO,SAASA,CAAAA,CAAAA,GAAMC,CAAsB,CAAA,CAC1C,OAAOC,OAAAA,CAAQC,KAAKF,CAAM,CAAC,CAC7B,CCCA,IAAMG,EAAgBC,GACpB,CAAA,4FACF,CAaMC,CAAAA,CAAAA,CAAcC,CAClB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GAAAA,GAAAA,CAAC,KAAI,CAAA,CAAA,GAAA,CAAKD,CAAK,CAAA,SAAA,CAAWV,EAAG,yBAA2BQ,CAAAA,CAAS,EAAI,GAAGC,CAAAA,CAAO,CAE1F,EACAM,CAAAA,CAAmB,WAAc,CAAA,oBAAA,CAW3BC,IAAAA,CAAAA,CAAuB,aAG3B,CAAC,CAAE,UAAAR,CAAW,CAAA,GAAGC,CAAM,CAAGC,CAAAA,CAAAA,GAExBC,GAACL,CAAAA,CAAAA,CAAA,CACC,GAAA,CAAKI,EACL,SAAWV,CAAAA,CAAAA,CACT,4GACAQ,CACF,CAAA,CACC,GAAGC,CACN,CAAA,CAEH,EACDO,CAAAA,CAAe,WAAc,CAAA,gBAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import * as React from \"react\"\nimport * as LabelPrimitive from \"@radix-ui/react-label\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/utils/index\"\n\nconst labelVariants = cva(\n \"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70\"\n)\n\nexport interface LabelProps\n extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>,\n VariantProps<typeof labelVariants> {}\n\n/**\n * Label component for creating accessible labels.\n * Built on top of Radix UI's Label primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-label--docs\n *\n */\nconst Label = React.forwardRef<React.ElementRef<typeof LabelPrimitive.Root>, LabelProps>(\n ({ className, ...props }, ref) => (\n <LabelPrimitive.Root ref={ref} className={cn(labelVariants(), className)} {...props} />\n )\n)\nLabel.displayName = LabelPrimitive.Root.displayName\n\nexport { Label }\n","import * as React from \"react\"\nimport * as RadioGroupPrimitive from \"@radix-ui/react-radio-group\"\nimport { Circle } from \"lucide-react\"\n\nimport { cn } from \"@/utils\"\nimport { Label } from \"@/components/atoms/label\"\n\n/**\n * RadioGroup component that allows users to select a single option from a list.\n * Built on top of Radix UI's RadioGroup primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-radio-group--docs\n *\n * @example\n * ```tsx\n * <RadioGroup defaultValue=\"option-1\">\n * <RadioGroupItem value=\"option-1\">Option 1</RadioGroupItem>\n * <RadioGroupItem value=\"option-2\">Option 2</RadioGroupItem>\n * </RadioGroup>\n * ```\n */\nconst RadioGroup = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>\n>(({ className, ...props }, ref) => {\n return <RadioGroupPrimitive.Root className={cn(\"grid gap-3\", className)} {...props} ref={ref} />\n})\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName\n\n/**\n * RadioGroupItem component that represents a single option in a RadioGroup.\n * Built on top of Radix UI's RadioGroupItem primitive.\n *\n * @example\n * ```tsx\n * <RadioGroupItem value=\"option-1\">Option 1</RadioGroupItem>\n * ```\n */\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>\n>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Item\n ref={ref}\n className={cn(\n \"aspect-square h-4 w-4 rounded-full border border-primary text-primary shadow focus:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50\",\n className\n )}\n {...props}\n >\n <RadioGroupPrimitive.Indicator className=\"flex items-center justify-center\">\n <Circle className=\"h-3.5 w-3.5 fill-primary\" />\n </RadioGroupPrimitive.Indicator>\n </RadioGroupPrimitive.Item>\n )\n})\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName\n\n/**\n * RadioItemContainer component that provides a container for radio group items with proper spacing and layout.\n *\n * @example\n * ```tsx\n * <RadioItemContainer>\n * <RadioGroupItem value=\"option-1\">Option 1</RadioGroupItem>\n * <RadioGroupItem value=\"option-2\">Option 2</RadioGroupItem>\n * </RadioItemContainer>\n * ```\n */\nconst RadioItemContainer = React.forwardRef<HTMLDivElement, React.HTMLAttributes<HTMLDivElement>>(\n ({ className, ...props }, ref) => {\n return <div ref={ref} className={cn(\"flex items-center gap-2\", className)} {...props} />\n }\n)\nRadioItemContainer.displayName = \"RadioItemContainer\"\n\n/**\n * RadioItemLabel component that provides a label for individual radio items.\n * Built on top of the Label component.\n *\n * @example\n * ```tsx\n * <RadioItemLabel>Select an option</RadioItemLabel>\n * ```\n */\nconst RadioItemLabel = React.forwardRef<\n React.ElementRef<typeof Label>,\n React.ComponentPropsWithoutRef<typeof Label>\n>(({ className, ...props }, ref) => {\n return (\n <Label\n ref={ref}\n className={cn(\n \"text-sm font-medium leading-none cursor-pointer peer-disabled:cursor-not-allowed peer-disabled:opacity-70\",\n className\n )}\n {...props}\n />\n )\n})\nRadioItemLabel.displayName = \"RadioItemLabel\"\n\nexport { RadioGroup, RadioGroupItem, RadioItemContainer, RadioItemLabel }\n"]}
@@ -1,2 +1,2 @@
1
- import {GripVertical}from'lucide-react';import*as e from'react-resizable-panels';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function i(...a){return twMerge(clsx(a))}var p=({className:a,...t})=>jsx(e.PanelGroup,{className:i("flex h-full w-full data-[panel-group-direction=vertical]:flex-col",a),...t}),c=e.Panel,f=({withHandle:a,className:t,...l})=>jsx(e.PanelResizeHandle,{className:i("relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",t),...l,children:a&&jsx("div",{className:"z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border",children:jsx(GripVertical,{className:"h-2.5 w-2.5"})})});export{f as ResizableHandle,c as ResizablePanel,p as ResizablePanelGroup};//# sourceMappingURL=resizable.mjs.map
2
- //# sourceMappingURL=resizable.mjs.map
1
+ import {GripVertical}from'lucide-react';import*as e from'react-resizable-panels';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx}from'react/jsx-runtime';function i(...a){return twMerge(clsx(a))}var p=({className:a,...t})=>jsx(e.PanelGroup,{className:i("flex h-full w-full data-[panel-group-direction=vertical]:flex-col",a),...t}),c=e.Panel,f=({withHandle:a,className:t,...l})=>jsx(e.PanelResizeHandle,{className:i("relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",t),...l,children:a&&jsx("div",{className:"z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border",children:jsx(GripVertical,{className:"h-2.5 w-2.5"})})});export{f as ResizableHandle,c as ResizablePanel,p as ResizablePanelGroup};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/resizable/resizable.tsx"],"names":["cn","inputs","twMerge","clsx","ResizablePanelGroup","className","props","jsx","ResizablePanel","ResizableHandle","withHandle","GripVertical"],"mappings":"kLAGO,SAASA,CAAAA,CAAAA,GAAMC,EAAsB,CAC1C,OAAOC,OAAQC,CAAAA,IAAAA,CAAKF,CAAM,CAAC,CAC7B,CCqBMG,IAAAA,CAAAA,CAAsB,CAAC,CAC3B,UAAAC,CACA,CAAA,GAAGC,CACL,CACEC,GAAAA,GAAAA,CAAoB,aAAnB,CACC,SAAA,CAAWP,CAAG,CAAA,mEAAA,CAAqEK,CAAS,CAC3F,CAAA,GAAGC,EACN,CAGIE,CAAAA,CAAAA,CAAoC,QAEpCC,CAAkB,CAAA,CAAC,CACvB,UAAA,CAAAC,EACA,SAAAL,CAAAA,CAAAA,CACA,GAAGC,CACL,CAAA,GAGEC,IAAoB,CAAnB,CAAA,iBAAA,CAAA,CACC,SAAWP,CAAAA,CAAAA,CACT,0oBACAK,CACF,CAAA,CACC,GAAGC,CAEH,CAAA,QAAA,CAAAI,GACCH,GAAC,CAAA,KAAA,CAAA,CAAI,SAAU,CAAA,2EAAA,CACb,SAAAA,GAACI,CAAAA,YAAAA,CAAA,CAAa,SAAU,CAAA,aAAA,CAAc,EACxC,CAEJ,CAAA","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","\"use client\"\n\nimport { GripVertical } from \"lucide-react\"\nimport * as ResizablePrimitive from \"react-resizable-panels\"\nimport { cn } from \"@/utils/index\"\nimport { ComponentProps } from \"react\"\n\n/**\n * Resizable component that provides resizable panel functionality.\n * Built on top of react-resizable-panels.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-resizable--docs\n *\n * @example\n * ```tsx\n * <ResizablePanelGroup>\n * <ResizablePanel defaultSize={20}>\n * <div>Left Panel</div>\n * </ResizablePanel>\n * <ResizableHandle withHandle />\n * <ResizablePanel defaultSize={80}>\n * <div>Right Panel</div>\n * </ResizablePanel>\n * </ResizablePanelGroup>\n * ```\n */\nconst ResizablePanelGroup = ({\n className,\n ...props\n}: ComponentProps<typeof ResizablePrimitive.PanelGroup>) => (\n <ResizablePrimitive.PanelGroup\n className={cn(\"flex h-full w-full data-[panel-group-direction=vertical]:flex-col\", className)}\n {...props}\n />\n)\n\nconst ResizablePanel = ResizablePrimitive.Panel\n\nconst ResizableHandle = ({\n withHandle,\n className,\n ...props\n}: ComponentProps<typeof ResizablePrimitive.PanelResizeHandle> & {\n withHandle?: boolean\n}) => (\n <ResizablePrimitive.PanelResizeHandle\n className={cn(\n \"relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90\",\n className\n )}\n {...props}\n >\n {withHandle && (\n <div className=\"z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border\">\n <GripVertical className=\"h-2.5 w-2.5\" />\n </div>\n )}\n </ResizablePrimitive.PanelResizeHandle>\n)\n\nexport { ResizablePanelGroup, ResizablePanel, ResizableHandle }\n"]}
@@ -1,2 +1,2 @@
1
- import {useFormContext,Controller}from'react-hook-form';import*as r from'react';import*as d from'@radix-ui/react-checkbox';import {Check}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx,jsxs}from'react/jsx-runtime';import {Slot}from'@radix-ui/react-slot';import*as h from'@radix-ui/react-label';import {cva}from'class-variance-authority';function s(...e){return twMerge(clsx(e))}var f=r.forwardRef(({className:e,...o},t)=>jsx(d.Root,{ref:t,className:s("peer h-4 w-4 shrink-0 rounded-sm border border-primary shadow focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...o,children:jsx(d.Indicator,{className:s("flex items-center justify-center text-current"),"aria-hidden":"true",children:jsx(Check,{className:"h-4 w-4"})})}));f.displayName=d.Root.displayName;var A=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),u=r.forwardRef(({className:e,...o},t)=>jsx(h.Root,{ref:t,className:s(A(),e),...o}));u.displayName=h.Root.displayName;var I=r.createContext({}),v=({...e})=>jsx(I.Provider,{value:{name:e.name},children:jsx(Controller,{...e})}),c=()=>{let e=r.useContext(I),o=r.useContext(T),{getFieldState:t,formState:a}=useFormContext(),i=t(e.name,a);if(!e)throw new Error("useFormField should be used within <FormField>");let{id:m}=o;return {id:m,name:e.name,formItemId:`${m}-form-item`,formDescriptionId:`${m}-form-item-description`,formMessageId:`${m}-form-item-message`,...i}},T=r.createContext({}),x=r.forwardRef(({className:e,...o},t)=>{let a=r.useId();return jsx(T.Provider,{value:{id:a},children:jsx("div",{ref:t,className:s("space-y-2",e),...o})})});x.displayName="FormItem";var b=r.forwardRef(({className:e,...o},t)=>{let{error:a,formItemId:i}=c();return jsx(u,{ref:t,className:s(a&&"text-destructive",e),htmlFor:i,...o})});b.displayName="FormLabel";var C=r.forwardRef(({...e},o)=>{let{error:t,formItemId:a,formDescriptionId:i,formMessageId:m}=c();return jsx(Slot,{ref:o,id:a,"aria-describedby":t?`${i} ${m}`:`${i}`,"aria-invalid":!!t,...e})});C.displayName="FormControl";var P=r.forwardRef(({className:e,...o},t)=>{let{formDescriptionId:a}=c();return jsx("p",{ref:t,id:a,className:s("text-sm text-muted-foreground",e),...o})});P.displayName="FormDescription";var R=r.forwardRef(({className:e,children:o,...t},a)=>{let{error:i,formMessageId:m}=c(),p=i?String(i?.message??""):o;return p?jsx("p",{ref:a,id:m,className:s("text-sm font-medium text-destructive",e),...t,children:p}):null});R.displayName="FormMessage";function ye({name:e,label:o,description:t,className:a,warningText:i,required:m,disabled:p,readOnly:G,"aria-label":k,"aria-describedby":M,...w}){let{control:H}=useFormContext();return jsx(v,{name:e,control:H,render:({field:g,fieldState:{error:F}})=>jsxs(x,{className:"flex flex-row items-start space-x-3 space-y-0",children:[jsx(C,{children:jsx(f,{checked:g.value,onCheckedChange:g.onChange,disabled:p,"aria-label":k,"aria-describedby":M,"aria-invalid":!!F,"aria-required":m,...w})}),jsxs("div",{className:"space-y-1 leading-none",children:[o&&jsxs(b,{children:[o,m&&jsx("span",{className:"text-destructive ml-1",children:"*"})]}),t&&jsx(P,{children:t}),F&&jsx(R,{children:F.message}),!F&&i&&jsx("p",{className:"text-sm text-yellow-600 dark:text-yellow-500",role:"alert",children:i})]})]})})}export{ye as RHFCheckbox};//# sourceMappingURL=rhf-checkbox.mjs.map
2
- //# sourceMappingURL=rhf-checkbox.mjs.map
1
+ import {useFormContext,Controller}from'react-hook-form';import*as r from'react';import*as d from'@radix-ui/react-checkbox';import {Check}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx,jsxs}from'react/jsx-runtime';import {Slot}from'@radix-ui/react-slot';import*as h from'@radix-ui/react-label';import {cva}from'class-variance-authority';function s(...e){return twMerge(clsx(e))}var f=r.forwardRef(({className:e,...o},t)=>jsx(d.Root,{ref:t,className:s("peer h-4 w-4 shrink-0 rounded-sm border border-primary shadow focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...o,children:jsx(d.Indicator,{className:s("flex items-center justify-center text-current"),"aria-hidden":"true",children:jsx(Check,{className:"h-4 w-4"})})}));f.displayName=d.Root.displayName;var A=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),u=r.forwardRef(({className:e,...o},t)=>jsx(h.Root,{ref:t,className:s(A(),e),...o}));u.displayName=h.Root.displayName;var I=r.createContext({}),v=({...e})=>jsx(I.Provider,{value:{name:e.name},children:jsx(Controller,{...e})}),c=()=>{let e=r.useContext(I),o=r.useContext(T),{getFieldState:t,formState:a}=useFormContext(),i=t(e.name,a);if(!e)throw new Error("useFormField should be used within <FormField>");let{id:m}=o;return {id:m,name:e.name,formItemId:`${m}-form-item`,formDescriptionId:`${m}-form-item-description`,formMessageId:`${m}-form-item-message`,...i}},T=r.createContext({}),x=r.forwardRef(({className:e,...o},t)=>{let a=r.useId();return jsx(T.Provider,{value:{id:a},children:jsx("div",{ref:t,className:s("space-y-2",e),...o})})});x.displayName="FormItem";var b=r.forwardRef(({className:e,...o},t)=>{let{error:a,formItemId:i}=c();return jsx(u,{ref:t,className:s(a&&"text-destructive",e),htmlFor:i,...o})});b.displayName="FormLabel";var C=r.forwardRef(({...e},o)=>{let{error:t,formItemId:a,formDescriptionId:i,formMessageId:m}=c();return jsx(Slot,{ref:o,id:a,"aria-describedby":t?`${i} ${m}`:`${i}`,"aria-invalid":!!t,...e})});C.displayName="FormControl";var P=r.forwardRef(({className:e,...o},t)=>{let{formDescriptionId:a}=c();return jsx("p",{ref:t,id:a,className:s("text-sm text-muted-foreground",e),...o})});P.displayName="FormDescription";var R=r.forwardRef(({className:e,children:o,...t},a)=>{let{error:i,formMessageId:m}=c(),p=i?String(i?.message??""):o;return p?jsx("p",{ref:a,id:m,className:s("text-sm font-medium text-destructive",e),...t,children:p}):null});R.displayName="FormMessage";function ye({name:e,label:o,description:t,className:a,warningText:i,required:m,disabled:p,readOnly:G,"aria-label":k,"aria-describedby":M,...w}){let{control:H}=useFormContext();return jsx(v,{name:e,control:H,render:({field:g,fieldState:{error:F}})=>jsxs(x,{className:"flex flex-row items-start space-x-3 space-y-0",children:[jsx(C,{children:jsx(f,{checked:g.value,onCheckedChange:g.onChange,disabled:p,"aria-label":k,"aria-describedby":M,"aria-invalid":!!F,"aria-required":m,...w})}),jsxs("div",{className:"space-y-1 leading-none",children:[o&&jsxs(b,{children:[o,m&&jsx("span",{className:"text-destructive ml-1",children:"*"})]}),t&&jsx(P,{children:t}),F&&jsx(R,{children:F.message}),!F&&i&&jsx("p",{className:"text-sm text-yellow-600 dark:text-yellow-500",role:"alert",children:i})]})]})})}export{ye as RHFCheckbox};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/cn.ts","../../src/components/atoms/checkbox/checkbox.tsx","../../src/components/atoms/label/label.tsx","../../src/components/rhf/form/form.tsx","../../src/components/rhf/rhf-checkbox/rhf-checkbox.tsx"],"names":["cn","inputs","twMerge","clsx","Checkbox","L","className","props","ref","jsx","Check","labelVariants","cva","Label","N","FormFieldContext","FormField","Controller","useFormField","fieldContext","itemContext","FormItemContext","getFieldState","formState","useFormContext","fieldState","id","FormItem","FormLabel","error","formItemId","FormControl","formDescriptionId","formMessageId","Slot","FormDescription","FormMessage","children","body","RHFCheckbox","name","label","description","warningText","required","disabled","readOnly","ariaLabel","ariaDescribedby","other","control","field","jsxs"],"mappings":"6XAGO,SAASA,CAAMC,CAAAA,GAAAA,CAAAA,CAAsB,CAC1C,OAAOC,OAAAA,CAAQC,IAAKF,CAAAA,CAAM,CAAC,CAC7B,CCcA,IAAMG,CAAAA,CAAiBC,CACrB,CAAA,UAAA,CAAA,CAAC,CAAE,SAAA,CAAAC,CAAW,CAAA,GAAGC,CAAM,CAAGC,CAAAA,CAAAA,GACxBC,GAAmB,CAAA,CAAA,CAAA,IAAA,CAAlB,CACC,GAAKD,CAAAA,CAAAA,CACL,SAAWR,CAAAA,CAAAA,CACT,qQACAM,CACF,CAAA,CACC,GAAGC,CAAAA,CAEJ,SAAAE,GAAmB,CAAA,CAAA,CAAA,SAAA,CAAlB,CACC,SAAA,CAAWT,EAAG,+CAA+C,CAAA,CAC7D,aAAY,CAAA,MAAA,CAEZ,SAAAS,GAACC,CAAAA,KAAAA,CAAA,CAAM,SAAA,CAAU,UAAU,CAC7B,CAAA,CAAA,CACF,CAEJ,CAAA,CACAN,CAA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AI,CAAA,CAAA,SAAA,CAAU,yBACZ,QAAAX,CAAAA,CAAAA,CAAAA,EACCW,IAACxB,CAAAA,CAAAA,CAAA,CACE,QAAAa,CAAAA,CAAAA,CAAAA,CACAG,CAAYnC,EAAAA,GAAAA,CAAC,MAAK,CAAA,CAAA,SAAA,CAAU,uBAAwB,CAAA,QAAA,CAAA,GAAA,CAAC,GACxD,CAEDiC,CAAAA,CAAAA,EAAejC,GAAC0B,CAAAA,CAAAA,CAAA,CAAiB,QAAAO,CAAAA,CAAAA,CAAY,CAC7Cb,CAAAA,CAAAA,EAASpB,IAAC2B,CAAA,CAAA,CAAa,QAAAP,CAAAA,CAAAA,CAAM,QAAQ,CACrC,CAAA,CAACA,CAASc,EAAAA,CAAAA,EACTlC,IAAC,GAAE,CAAA,CAAA,SAAA,CAAU,8CAA+C,CAAA,IAAA,CAAK,QAC9D,QAAAkC,CAAAA,CAAAA,CACH,CAEJ,CAAA,CAAA,CAAA,CAAA,CACF,EAEJ,CAEJ","file":"index.mjs","sourcesContent":["import { type ClassValue, clsx } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","/**\n * Checkbox component built on top of Radix UI's Checkbox primitive.\n * Provides a customizable checkbox input with proper accessibility and keyboard navigation.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-checkbox--docs\n *\n * @example\n * ```tsx\n * <Checkbox id=\"terms\" name=\"terms\" />\n * <label htmlFor=\"terms\">Accept terms and conditions</label>\n * ```\n */\nimport * as React from \"react\"\nimport * as CheckboxPrimitive from \"@radix-ui/react-checkbox\"\nimport { Check } from \"lucide-react\"\n\nimport { cn } from \"@/utils/index\"\nimport type { CheckboxProps } from \"./checkbox.types\"\n\nconst Checkbox = React.forwardRef<React.ElementRef<typeof CheckboxPrimitive.Root>, CheckboxProps>(\n ({ className, ...props }, ref) => (\n <CheckboxPrimitive.Root\n ref={ref}\n className={cn(\n \"peer h-4 w-4 shrink-0 rounded-sm border border-primary shadow focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground\",\n className\n )}\n {...props}\n >\n <CheckboxPrimitive.Indicator\n className={cn(\"flex items-center justify-center text-current\")}\n aria-hidden=\"true\"\n >\n <Check className=\"h-4 w-4\" />\n </CheckboxPrimitive.Indicator>\n </CheckboxPrimitive.Root>\n )\n)\nCheckbox.displayName = CheckboxPrimitive.Root.displayName\n\nexport { Checkbox }\n","import * as React from \"react\"\nimport * as LabelPrimitive from \"@radix-ui/react-label\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/utils/index\"\n\nconst labelVariants = cva(\n \"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70\"\n)\n\nexport interface LabelProps\n extends React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>,\n VariantProps<typeof labelVariants> {}\n\n/**\n * Label component for creating accessible labels.\n * Built on top of Radix UI's Label primitive.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/atoms-label--docs\n *\n */\nconst Label = React.forwardRef<React.ElementRef<typeof LabelPrimitive.Root>, LabelProps>(\n ({ className, ...props }, ref) => (\n <LabelPrimitive.Root ref={ref} className={cn(labelVariants(), className)} {...props} />\n )\n)\nLabel.displayName = LabelPrimitive.Root.displayName\n\nexport { Label }\n","\"use client\"\n\nimport * as React from \"react\"\nimport * as LabelPrimitive from \"@radix-ui/react-label\"\nimport { Slot } from \"@radix-ui/react-slot\"\nimport {\n Controller,\n FormProvider,\n useFormContext,\n type ControllerProps,\n type FieldPath,\n type FieldValues\n} from \"react-hook-form\"\n\nimport { cn } from \"@/utils/cn\"\nimport { Label } from \"@/components/atoms/label\"\n\nconst Form = FormProvider\n\ntype FormFieldContextValue<\n TFieldValues extends FieldValues = FieldValues,\n TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>\n> = {\n name: TName\n}\n\nconst FormFieldContext = React.createContext<FormFieldContextValue>({} as FormFieldContextValue)\n\nconst FormField = <\n TFieldValues extends FieldValues = FieldValues,\n TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>\n>({\n ...props\n}: ControllerProps<TFieldValues, TName>) => {\n return (\n <FormFieldContext.Provider value={{ name: props.name }}>\n <Controller {...props} />\n </FormFieldContext.Provider>\n )\n}\n\nconst useFormField = () => {\n const fieldContext = React.useContext(FormFieldContext)\n const itemContext = React.useContext(FormItemContext)\n const { getFieldState, formState } = useFormContext()\n\n const fieldState = getFieldState(fieldContext.name, formState)\n\n if (!fieldContext) {\n throw new Error(\"useFormField should be used within <FormField>\")\n }\n\n const { id } = itemContext\n\n return {\n id,\n name: fieldContext.name,\n formItemId: `${id}-form-item`,\n formDescriptionId: `${id}-form-item-description`,\n formMessageId: `${id}-form-item-message`,\n ...fieldState\n }\n}\n\ntype FormItemContextValue = {\n id: string\n}\n\nconst FormItemContext = React.createContext<FormItemContextValue>({} as FormItemContextValue)\n\nconst FormItem = React.forwardRef<HTMLDivElement, React.HTMLAttributes<HTMLDivElement>>(\n ({ className, ...props }, ref) => {\n const id = React.useId()\n\n return (\n <FormItemContext.Provider value={{ id }}>\n <div ref={ref} className={cn(\"space-y-2\", className)} {...props} />\n </FormItemContext.Provider>\n )\n }\n)\nFormItem.displayName = \"FormItem\"\n\nconst FormLabel = React.forwardRef<\n React.ElementRef<typeof LabelPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>\n>(({ className, ...props }, ref) => {\n const { error, formItemId } = useFormField()\n\n return (\n <Label\n ref={ref}\n className={cn(error && \"text-destructive\", className)}\n htmlFor={formItemId}\n {...props}\n />\n )\n})\nFormLabel.displayName = \"FormLabel\"\n\nconst FormControl = React.forwardRef<\n React.ElementRef<typeof Slot>,\n React.ComponentPropsWithoutRef<typeof Slot>\n>(({ ...props }, ref) => {\n const { error, formItemId, formDescriptionId, formMessageId } = useFormField()\n\n return (\n <Slot\n ref={ref}\n id={formItemId}\n aria-describedby={!error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`}\n aria-invalid={!!error}\n {...props}\n />\n )\n})\nFormControl.displayName = \"FormControl\"\n\nconst FormDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLParagraphElement>\n>(({ className, ...props }, ref) => {\n const { formDescriptionId } = useFormField()\n\n return (\n <p\n ref={ref}\n id={formDescriptionId}\n className={cn(\"text-sm text-muted-foreground\", className)}\n {...props}\n />\n )\n})\nFormDescription.displayName = \"FormDescription\"\n\nconst FormMessage = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLParagraphElement>\n>(({ className, children, ...props }, ref) => {\n const { error, formMessageId } = useFormField()\n const body = error ? String(error?.message ?? \"\") : children\n\n if (!body) {\n return null\n }\n\n return (\n <p\n ref={ref}\n id={formMessageId}\n className={cn(\"text-sm font-medium text-destructive\", className)}\n {...props}\n >\n {body}\n </p>\n )\n})\nFormMessage.displayName = \"FormMessage\"\n\nexport {\n useFormField,\n Form,\n FormItem,\n FormLabel,\n FormControl,\n FormDescription,\n FormMessage,\n FormField\n}\n","import * as React from \"react\"\nimport { useFormContext, type FieldValues, type FieldPath } from \"react-hook-form\"\nimport { Checkbox } from \"@/components/atoms/checkbox\"\nimport {\n FormControl,\n FormItem,\n FormMessage,\n FormLabel,\n FormDescription,\n FormField\n} from \"@/components/rhf/form\"\nimport { type RHFCheckboxProps } from \"./rhf-checkbox.types\"\n\n// ----------------------------------------------------------------------\n\n/**\n * A checkbox component that integrates with React Hook Form.\n * Provides form validation, error handling, and accessibility features.\n *\n * @url https://sergii-melnykov.github.io/ui/?path=/docs/molecules-rhf-rhfcheckbox--docs\n *\n * @example\n * ```tsx\n * <Form>\n * <RHFCheckbox name=\"terms\" label=\"Accept terms and conditions\" />\n * </Form>\n * ```\n */\nexport function RHFCheckbox<\n TFieldValues extends FieldValues = FieldValues,\n TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>\n>({\n name,\n label,\n description,\n className,\n warningText,\n required,\n disabled,\n readOnly,\n \"aria-label\": ariaLabel,\n \"aria-describedby\": ariaDescribedby,\n ...other\n}: RHFCheckboxProps<TFieldValues, TName>) {\n const { control } = useFormContext<TFieldValues>()\n\n return (\n <FormField\n name={name}\n control={control}\n render={({ field, fieldState: { error } }) => (\n <FormItem className=\"flex flex-row items-start space-x-3 space-y-0\">\n <FormControl>\n <Checkbox\n checked={field.value}\n onCheckedChange={field.onChange}\n disabled={disabled}\n aria-label={ariaLabel}\n aria-describedby={ariaDescribedby}\n aria-invalid={!!error}\n aria-required={required}\n {...other}\n />\n </FormControl>\n <div className=\"space-y-1 leading-none\">\n {label && (\n <FormLabel>\n {label}\n {required && <span className=\"text-destructive ml-1\">*</span>}\n </FormLabel>\n )}\n {description && <FormDescription>{description}</FormDescription>}\n {error && <FormMessage>{error.message}</FormMessage>}\n {!error && warningText && (\n <p className=\"text-sm text-yellow-600 dark:text-yellow-500\" role=\"alert\">\n {warningText}\n </p>\n )}\n </div>\n </FormItem>\n )}\n />\n )\n}\n"]}
@@ -1,2 +1,2 @@
1
- import {useFormContext,Controller}from'react-hook-form';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import*as l from'react';import {Slot}from'@radix-ui/react-slot';import {cva}from'class-variance-authority';import {Loader2,Search,X as X$1,ChevronDown,Check}from'lucide-react';import {jsx,jsxs}from'react/jsx-runtime';import {Command}from'cmdk';import {Popover,PopoverTrigger,PopoverContent}from'@radix-ui/react-popover';import*as W from'@radix-ui/react-label';function a(...e){return twMerge(clsx(e))}var j=cva("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),z=l.forwardRef(({className:e,variant:t,size:o,asChild:m=false,startIcon:s,endIcon:i,loading:c=false,disabled:I,children:f,type:N="button","aria-label":y,...x},P)=>{let F=m?Slot:"button",p=I||c,u=y||(typeof f=="string"?f:void 0),T=w=>{(w.key==="Enter"||w.key===" ")&&(w.preventDefault(),!p&&x.onClick&&x.onClick(w));};return m?jsx(F,{className:a(j({variant:t,size:o,className:e})),ref:P,disabled:p,type:N,"aria-label":u,"aria-disabled":p,...x,children:f}):jsxs(F,{className:a(j({variant:t,size:o,className:e})),ref:P,disabled:p,type:N,"aria-label":u,"aria-disabled":p,onKeyDown:T,...x,children:[c&&jsx(Loader2,{className:"mr-2 h-4 w-4 animate-spin",role:"status","aria-label":"Loading","aria-hidden":"true"}),!c&&s&&jsx("span",{className:"mr-2","aria-hidden":"true",children:s}),f,!c&&i&&jsx("span",{className:"ml-2","aria-hidden":"true",children:i})]})});z.displayName="Button";var M=l.forwardRef(({className:e,...t},o)=>jsx(Command,{ref:o,className:a("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));M.displayName=Command.displayName;var E=l.forwardRef(({className:e,...t},o)=>jsxs("div",{className:"flex items-center border-b px-3","cmdk-input-wrapper":"",children:[jsx(Search,{className:"mr-2 h-4 w-4 shrink-0 opacity-50"}),jsx(Command.Input,{ref:o,className:a("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),...t})]}));E.displayName=Command.Input.displayName;var _=l.forwardRef(({className:e,...t},o)=>jsx(Command.List,{ref:o,className:a("max-h-[300px] overflow-y-auto overflow-x-hidden",e),...t}));_.displayName=Command.List.displayName;var D=l.forwardRef((e,t)=>jsx(Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));D.displayName=Command.Empty.displayName;var L=l.forwardRef(({className:e,...t},o)=>jsx(Command.Group,{ref:o,className:a("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));L.displayName=Command.Group.displayName;var H=l.forwardRef(({className:e,...t},o)=>jsx(Command.Separator,{ref:o,className:a("-mx-1 h-px bg-border",e),...t}));H.displayName=Command.Separator.displayName;var S=l.forwardRef(({className:e,...t},o)=>jsx(Command.Item,{ref:o,className:a("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));S.displayName=Command.Item.displayName;var xe=cva("",{variants:{variant:{h1:"scroll-m-5 text-4xl font-extrabold tracking-tight lg:text-5xl",h2:"scroll-m-5 text-3xl font-semibold tracking-tight",h3:"scroll-m-5 text-2xl font-semibold tracking-tight",h4:"scroll-m-5 text-xl font-semibold tracking-tight",h5:"scroll-m-5 text-lg font-semibold tracking-tight",h6:"scroll-m-5 text-base font-semibold tracking-tight",p:"leading-7 [&:not(:first-child)]:mt-6",blockquote:"mt-6 border-l-2 border-slate-300 pl-6 italic",list:"my-6 ml-6 list-disc [&>li]:mt-2",lead:"text-xl text-muted-foreground",large:"text-lg font-semibold",small:"text-sm font-medium leading-none",muted:"text-sm text-muted-foreground"},align:{left:"text-left",center:"text-center",right:"text-right",justify:"text-justify"}},defaultVariants:{variant:"p",align:"left"}}),G=l.forwardRef(({className:e,variant:t,align:o,as:m="p",...s},i)=>jsx(m,{className:a(xe({variant:t,align:o,className:e})),ref:i,...s}));G.displayName="Typography";function ee({options:e,value:t,onChange:o,placeholder:m="Select options",disabled:s,required:i,error:c,className:I,fullWidth:f,searchable:N,id:y,maxSelections:x,showSelectAll:P,renderCommandList:F}){let[p,u]=l.useState(false),T=e.filter(r=>t.includes(r.id)),w=r=>{if(t.includes(r))o(t.filter(b=>b!==r));else {if(x&&t.length>=x)return;o([...t,r]);}},me=()=>{let r=e.filter(b=>!b.disabled);t.length===r.length?o([]):o(r.map(b=>b.id));},se=(r,b)=>{b.stopPropagation(),o(t.filter(ne=>ne!==r));};return jsx("div",{className:a(f&&"w-full"),children:jsxs(Popover,{open:p,onOpenChange:u,children:[jsx(PopoverTrigger,{asChild:true,children:jsxs(z,{variant:"outline",role:"combobox","aria-expanded":p,"aria-controls":y?`${y}-content`:void 0,"aria-label":m,"aria-required":i,"aria-invalid":!!c,disabled:s,id:y,className:a("w-[13rem] justify-between min-h-[2.5rem] h-auto",!t.length&&"text-muted-foreground",f&&"w-full",c&&"border-destructive focus-visible:ring-destructive",I),children:[jsx("div",{className:"flex flex-wrap gap-1",children:T.length>0?T.map(r=>jsxs("div",{className:"flex items-center gap-1 bg-secondary text-secondary-foreground px-2 py-0.5 rounded-md text-sm",children:[jsx("span",{children:r.label}),jsx("span",{onClick:b=>se(r.id,b),className:"hover:bg-secondary-foreground/20 rounded-sm",children:jsx(X$1,{className:"h-3 w-3"})})]},r.id)):jsx("span",{children:m})}),jsx(ChevronDown,{className:a("opacity-50",p&&"rotate-180")})]})}),jsx(PopoverContent,{id:y?`${y}-content`:void 0,className:a("w-[13rem] p-0 rounded-md border bg-popover text-popover-foreground shadow-md",f&&"w-full"),align:"start",children:jsxs(M,{children:[N&&jsx(E,{placeholder:"Search...",className:"h-9",disabled:s}),jsxs(_,{className:"max-h-[12rem] overflow-y-auto",children:[jsx(D,{children:"No items found."}),jsxs(L,{children:[P&&jsxs(S,{onSelect:me,className:"flex items-center gap-2 cursor-pointer my-1",children:[jsx("div",{className:"flex h-4 w-4 items-center justify-center rounded border border-primary",children:t.length===e.filter(r=>!r.disabled).length&&jsx(Check,{className:"h-3 w-3"})}),jsx(G,{variant:"small",children:"Select All"})]}),jsx(H,{})]}),F?F(e):jsx(L,{children:e.map(r=>jsxs(S,{value:r.id,onSelect:()=>w(r.id),disabled:r.disabled,className:a("flex items-center justify-between cursor-pointer my-1",r.disabled&&"opacity-50 cursor-not-allowed",r.className),children:[jsxs("div",{className:"flex items-center gap-2",children:[jsx("div",{className:"flex h-4 w-4 items-center justify-center rounded border border-primary",children:t.includes(r.id)&&jsx(Check,{className:"h-3 w-3"})}),jsxs("div",{className:"flex items-center gap-1",children:[r.startIcon&&r.startIcon,jsx(G,{variant:"small",children:r.label})]})]}),r.endIcon&&jsx("div",{className:"ml-2",children:r.endIcon})]},r.id))})]})]})})]})})}var Pe=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),A=l.forwardRef(({className:e,...t},o)=>jsx(W.Root,{ref:o,className:a(Pe(),e),...t}));A.displayName=W.Root.displayName;var oe=l.createContext({}),X=({...e})=>jsx(oe.Provider,{value:{name:e.name},children:jsx(Controller,{...e})}),k=()=>{let e=l.useContext(oe),t=l.useContext(re),{getFieldState:o,formState:m}=useFormContext(),s=o(e.name,m);if(!e)throw new Error("useFormField should be used within <FormField>");let{id:i}=t;return {id:i,name:e.name,formItemId:`${i}-form-item`,formDescriptionId:`${i}-form-item-description`,formMessageId:`${i}-form-item-message`,...s}},re=l.createContext({}),B=l.forwardRef(({className:e,...t},o)=>{let m=l.useId();return jsx(re.Provider,{value:{id:m},children:jsx("div",{ref:o,className:a("space-y-2",e),...t})})});B.displayName="FormItem";var $=l.forwardRef(({className:e,...t},o)=>{let{error:m,formItemId:s}=k();return jsx(A,{ref:o,className:a(m&&"text-destructive",e),htmlFor:s,...t})});$.displayName="FormLabel";var O=l.forwardRef(({...e},t)=>{let{error:o,formItemId:m,formDescriptionId:s,formMessageId:i}=k();return jsx(Slot,{ref:t,id:m,"aria-describedby":o?`${s} ${i}`:`${s}`,"aria-invalid":!!o,...e})});O.displayName="FormControl";var q=l.forwardRef(({className:e,...t},o)=>{let{formDescriptionId:m}=k();return jsx("p",{ref:o,id:m,className:a("text-sm text-muted-foreground",e),...t})});q.displayName="FormDescription";var K=l.forwardRef(({className:e,children:t,...o},m)=>{let{error:s,formMessageId:i}=k(),c=s?String(s?.message??""):t;return c?jsx("p",{ref:m,id:i,className:a("text-sm font-medium text-destructive",e),...o,children:c}):null});K.displayName="FormMessage";function St({name:e,label:t,description:o,className:m,warningText:s,required:i,disabled:c,readOnly:I,placeholder:f,"aria-label":N,"aria-describedby":y,options:x,...P}){let{control:F}=useFormContext();return jsx(X,{name:e,control:F,render:({field:p,fieldState:{error:u}})=>jsxs(B,{children:[t&&jsxs($,{children:[t,i&&jsx("span",{className:"text-destructive ml-1",children:"*"})]}),jsx(O,{children:jsx(ee,{...p,options:x,value:p.value||[],onChange:p.onChange,className:a(u&&"border-destructive focus-visible:ring-destructive",m),disabled:c||I,required:i,placeholder:f,"aria-label":N,"aria-describedby":y,"aria-invalid":!!u,"aria-required":i,...P})}),o&&jsx(q,{children:o}),u&&jsx(K,{children:u.message}),!u&&s&&jsx("p",{className:"text-sm text-yellow-600 dark:text-yellow-500",role:"alert",children:s})]})})}export{St as RHFMultiSelect};//# sourceMappingURL=rhf-multi-select.mjs.map
2
- //# sourceMappingURL=rhf-multi-select.mjs.map
1
+ import {useFormContext,Controller}from'react-hook-form';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import*as l from'react';import {Slot}from'@radix-ui/react-slot';import {cva}from'class-variance-authority';import {Loader2,Search,X as X$1,ChevronDown,Check}from'lucide-react';import {jsx,jsxs}from'react/jsx-runtime';import {Command}from'cmdk';import {Popover,PopoverTrigger,PopoverContent}from'@radix-ui/react-popover';import*as W from'@radix-ui/react-label';function a(...e){return twMerge(clsx(e))}var j=cva("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),z=l.forwardRef(({className:e,variant:t,size:o,asChild:m=false,startIcon:s,endIcon:i,loading:c=false,disabled:I,children:f,type:N="button","aria-label":y,...x},P)=>{let F=m?Slot:"button",p=I||c,u=y||(typeof f=="string"?f:void 0),T=w=>{(w.key==="Enter"||w.key===" ")&&(w.preventDefault(),!p&&x.onClick&&x.onClick(w));};return m?jsx(F,{className:a(j({variant:t,size:o,className:e})),ref:P,disabled:p,type:N,"aria-label":u,"aria-disabled":p,...x,children:f}):jsxs(F,{className:a(j({variant:t,size:o,className:e})),ref:P,disabled:p,type:N,"aria-label":u,"aria-disabled":p,onKeyDown:T,...x,children:[c&&jsx(Loader2,{className:"mr-2 h-4 w-4 animate-spin",role:"status","aria-label":"Loading","aria-hidden":"true"}),!c&&s&&jsx("span",{className:"mr-2","aria-hidden":"true",children:s}),f,!c&&i&&jsx("span",{className:"ml-2","aria-hidden":"true",children:i})]})});z.displayName="Button";var M=l.forwardRef(({className:e,...t},o)=>jsx(Command,{ref:o,className:a("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));M.displayName=Command.displayName;var E=l.forwardRef(({className:e,...t},o)=>jsxs("div",{className:"flex items-center border-b px-3","cmdk-input-wrapper":"",children:[jsx(Search,{className:"mr-2 h-4 w-4 shrink-0 opacity-50"}),jsx(Command.Input,{ref:o,className:a("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),...t})]}));E.displayName=Command.Input.displayName;var _=l.forwardRef(({className:e,...t},o)=>jsx(Command.List,{ref:o,className:a("max-h-[300px] overflow-y-auto overflow-x-hidden",e),...t}));_.displayName=Command.List.displayName;var D=l.forwardRef((e,t)=>jsx(Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));D.displayName=Command.Empty.displayName;var L=l.forwardRef(({className:e,...t},o)=>jsx(Command.Group,{ref:o,className:a("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));L.displayName=Command.Group.displayName;var H=l.forwardRef(({className:e,...t},o)=>jsx(Command.Separator,{ref:o,className:a("-mx-1 h-px bg-border",e),...t}));H.displayName=Command.Separator.displayName;var S=l.forwardRef(({className:e,...t},o)=>jsx(Command.Item,{ref:o,className:a("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));S.displayName=Command.Item.displayName;var xe=cva("",{variants:{variant:{h1:"scroll-m-5 text-4xl font-extrabold tracking-tight lg:text-5xl",h2:"scroll-m-5 text-3xl font-semibold tracking-tight",h3:"scroll-m-5 text-2xl font-semibold tracking-tight",h4:"scroll-m-5 text-xl font-semibold tracking-tight",h5:"scroll-m-5 text-lg font-semibold tracking-tight",h6:"scroll-m-5 text-base font-semibold tracking-tight",p:"leading-7 [&:not(:first-child)]:mt-6",blockquote:"mt-6 border-l-2 border-slate-300 pl-6 italic",list:"my-6 ml-6 list-disc [&>li]:mt-2",lead:"text-xl text-muted-foreground",large:"text-lg font-semibold",small:"text-sm font-medium leading-none",muted:"text-sm text-muted-foreground"},align:{left:"text-left",center:"text-center",right:"text-right",justify:"text-justify"}},defaultVariants:{variant:"p",align:"left"}}),G=l.forwardRef(({className:e,variant:t,align:o,as:m="p",...s},i)=>jsx(m,{className:a(xe({variant:t,align:o,className:e})),ref:i,...s}));G.displayName="Typography";function ee({options:e,value:t,onChange:o,placeholder:m="Select options",disabled:s,required:i,error:c,className:I,fullWidth:f,searchable:N,id:y,maxSelections:x,showSelectAll:P,renderCommandList:F}){let[p,u]=l.useState(false),T=e.filter(r=>t.includes(r.id)),w=r=>{if(t.includes(r))o(t.filter(b=>b!==r));else {if(x&&t.length>=x)return;o([...t,r]);}},me=()=>{let r=e.filter(b=>!b.disabled);t.length===r.length?o([]):o(r.map(b=>b.id));},se=(r,b)=>{b.stopPropagation(),o(t.filter(ne=>ne!==r));};return jsx("div",{className:a(f&&"w-full"),children:jsxs(Popover,{open:p,onOpenChange:u,children:[jsx(PopoverTrigger,{asChild:true,children:jsxs(z,{variant:"outline",role:"combobox","aria-expanded":p,"aria-controls":y?`${y}-content`:void 0,"aria-label":m,"aria-required":i,"aria-invalid":!!c,disabled:s,id:y,className:a("w-[13rem] justify-between min-h-[2.5rem] h-auto",!t.length&&"text-muted-foreground",f&&"w-full",c&&"border-destructive focus-visible:ring-destructive",I),children:[jsx("div",{className:"flex flex-wrap gap-1",children:T.length>0?T.map(r=>jsxs("div",{className:"flex items-center gap-1 bg-secondary text-secondary-foreground px-2 py-0.5 rounded-md text-sm",children:[jsx("span",{children:r.label}),jsx("span",{onClick:b=>se(r.id,b),className:"hover:bg-secondary-foreground/20 rounded-sm",children:jsx(X$1,{className:"h-3 w-3"})})]},r.id)):jsx("span",{children:m})}),jsx(ChevronDown,{className:a("opacity-50",p&&"rotate-180")})]})}),jsx(PopoverContent,{id:y?`${y}-content`:void 0,className:a("w-[13rem] p-0 rounded-md border bg-popover text-popover-foreground shadow-md",f&&"w-full"),align:"start",children:jsxs(M,{children:[N&&jsx(E,{placeholder:"Search...",className:"h-9",disabled:s}),jsxs(_,{className:"max-h-[12rem] overflow-y-auto",children:[jsx(D,{children:"No items found."}),jsxs(L,{children:[P&&jsxs(S,{onSelect:me,className:"flex items-center gap-2 cursor-pointer my-1",children:[jsx("div",{className:"flex h-4 w-4 items-center justify-center rounded border border-primary",children:t.length===e.filter(r=>!r.disabled).length&&jsx(Check,{className:"h-3 w-3"})}),jsx(G,{variant:"small",children:"Select All"})]}),jsx(H,{})]}),F?F(e):jsx(L,{children:e.map(r=>jsxs(S,{value:r.id,onSelect:()=>w(r.id),disabled:r.disabled,className:a("flex items-center justify-between cursor-pointer my-1",r.disabled&&"opacity-50 cursor-not-allowed",r.className),children:[jsxs("div",{className:"flex items-center gap-2",children:[jsx("div",{className:"flex h-4 w-4 items-center justify-center rounded border border-primary",children:t.includes(r.id)&&jsx(Check,{className:"h-3 w-3"})}),jsxs("div",{className:"flex items-center gap-1",children:[r.startIcon&&r.startIcon,jsx(G,{variant:"small",children:r.label})]})]}),r.endIcon&&jsx("div",{className:"ml-2",children:r.endIcon})]},r.id))})]})]})})]})})}var Pe=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),A=l.forwardRef(({className:e,...t},o)=>jsx(W.Root,{ref:o,className:a(Pe(),e),...t}));A.displayName=W.Root.displayName;var oe=l.createContext({}),X=({...e})=>jsx(oe.Provider,{value:{name:e.name},children:jsx(Controller,{...e})}),k=()=>{let e=l.useContext(oe),t=l.useContext(re),{getFieldState:o,formState:m}=useFormContext(),s=o(e.name,m);if(!e)throw new Error("useFormField should be used within <FormField>");let{id:i}=t;return {id:i,name:e.name,formItemId:`${i}-form-item`,formDescriptionId:`${i}-form-item-description`,formMessageId:`${i}-form-item-message`,...s}},re=l.createContext({}),B=l.forwardRef(({className:e,...t},o)=>{let m=l.useId();return jsx(re.Provider,{value:{id:m},children:jsx("div",{ref:o,className:a("space-y-2",e),...t})})});B.displayName="FormItem";var $=l.forwardRef(({className:e,...t},o)=>{let{error:m,formItemId:s}=k();return jsx(A,{ref:o,className:a(m&&"text-destructive",e),htmlFor:s,...t})});$.displayName="FormLabel";var O=l.forwardRef(({...e},t)=>{let{error:o,formItemId:m,formDescriptionId:s,formMessageId:i}=k();return jsx(Slot,{ref:t,id:m,"aria-describedby":o?`${s} ${i}`:`${s}`,"aria-invalid":!!o,...e})});O.displayName="FormControl";var q=l.forwardRef(({className:e,...t},o)=>{let{formDescriptionId:m}=k();return jsx("p",{ref:o,id:m,className:a("text-sm text-muted-foreground",e),...t})});q.displayName="FormDescription";var K=l.forwardRef(({className:e,children:t,...o},m)=>{let{error:s,formMessageId:i}=k(),c=s?String(s?.message??""):t;return c?jsx("p",{ref:m,id:i,className:a("text-sm font-medium text-destructive",e),...o,children:c}):null});K.displayName="FormMessage";function St({name:e,label:t,description:o,className:m,warningText:s,required:i,disabled:c,readOnly:I,placeholder:f,"aria-label":N,"aria-describedby":y,options:x,...P}){let{control:F}=useFormContext();return jsx(X,{name:e,control:F,render:({field:p,fieldState:{error:u}})=>jsxs(B,{children:[t&&jsxs($,{children:[t,i&&jsx("span",{className:"text-destructive ml-1",children:"*"})]}),jsx(O,{children:jsx(ee,{...p,options:x,value:p.value||[],onChange:p.onChange,className:a(u&&"border-destructive focus-visible:ring-destructive",m),disabled:c||I,required:i,placeholder:f,"aria-label":N,"aria-describedby":y,"aria-invalid":!!u,"aria-required":i,...P})}),o&&jsx(q,{children:o}),u&&jsx(K,{children:u.message}),!u&&s&&jsx("p",{className:"text-sm text-yellow-600 dark:text-yellow-500",role:"alert",children:s})]})})}export{St as RHFMultiSelect};//# sourceMappingURL=index.mjs.map
2
+ //# sourceMappingURL=index.mjs.map