@jbpark/ui-kit 10.2.0 → 10.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (351) hide show
  1. package/dist/Alert.d.mts +2 -2
  2. package/dist/Alert.d.mts.map +1 -1
  3. package/dist/Alert.mjs +1 -1
  4. package/dist/Anchor.d.mts +29 -0
  5. package/dist/Anchor.d.mts.map +1 -0
  6. package/dist/Anchor.mjs +120 -0
  7. package/dist/Anchor.mjs.map +1 -0
  8. package/dist/AutoComplete.d.mts +34 -0
  9. package/dist/AutoComplete.d.mts.map +1 -0
  10. package/dist/AutoComplete.mjs +82 -0
  11. package/dist/AutoComplete.mjs.map +1 -0
  12. package/dist/Avatar.d.mts +2 -2
  13. package/dist/Avatar.d.mts.map +1 -1
  14. package/dist/Avatar.mjs +2 -2
  15. package/dist/Badge.d.mts +2 -2
  16. package/dist/Badge.d.mts.map +1 -1
  17. package/dist/Breadcrumb.d.mts +3 -3
  18. package/dist/Breadcrumb.d.mts.map +1 -1
  19. package/dist/Breadcrumb.mjs +1 -1
  20. package/dist/Breadcrumb.mjs.map +1 -1
  21. package/dist/Button.d.mts +3 -3
  22. package/dist/Button.d.mts.map +1 -1
  23. package/dist/Button.mjs +1 -1
  24. package/dist/Calendar.d.mts +28 -0
  25. package/dist/Calendar.d.mts.map +1 -0
  26. package/dist/Calendar.mjs +64 -0
  27. package/dist/Calendar.mjs.map +1 -0
  28. package/dist/Card.d.mts +2 -2
  29. package/dist/Card.d.mts.map +1 -1
  30. package/dist/Cascader.d.mts +34 -0
  31. package/dist/Cascader.d.mts.map +1 -0
  32. package/dist/Cascader.mjs +144 -0
  33. package/dist/Cascader.mjs.map +1 -0
  34. package/dist/CodeEditor.d.mts +2 -2
  35. package/dist/CodeEditor.d.mts.map +1 -1
  36. package/dist/ContextMenu.d.mts +33 -0
  37. package/dist/ContextMenu.d.mts.map +1 -0
  38. package/dist/ContextMenu.mjs +92 -0
  39. package/dist/ContextMenu.mjs.map +1 -0
  40. package/dist/Descriptions.d.mts +31 -0
  41. package/dist/Descriptions.d.mts.map +1 -0
  42. package/dist/Descriptions.mjs +67 -0
  43. package/dist/Descriptions.mjs.map +1 -0
  44. package/dist/Divider.d.mts +18 -0
  45. package/dist/Divider.d.mts.map +1 -0
  46. package/dist/Divider.mjs +44 -0
  47. package/dist/Divider.mjs.map +1 -0
  48. package/dist/Form.d.mts +12 -0
  49. package/dist/Form.d.mts.map +1 -0
  50. package/dist/Form.mjs +11 -0
  51. package/dist/Form.mjs.map +1 -0
  52. package/dist/Layout.d.mts.map +1 -1
  53. package/dist/Mentions.d.mts +34 -0
  54. package/dist/Mentions.d.mts.map +1 -0
  55. package/dist/Mentions.mjs +207 -0
  56. package/dist/Mentions.mjs.map +1 -0
  57. package/dist/Menu.mjs +1 -2
  58. package/dist/Pagination.d.mts +2 -2
  59. package/dist/Pagination.d.mts.map +1 -1
  60. package/dist/Pagination.mjs +1 -1
  61. package/dist/Popconfirm.d.mts +33 -0
  62. package/dist/Popconfirm.d.mts.map +1 -0
  63. package/dist/Popconfirm.mjs +119 -0
  64. package/dist/Popconfirm.mjs.map +1 -0
  65. package/dist/Rate.d.mts +27 -0
  66. package/dist/Rate.d.mts.map +1 -0
  67. package/dist/Rate.mjs +81 -0
  68. package/dist/Rate.mjs.map +1 -0
  69. package/dist/Reveals.d.mts.map +1 -1
  70. package/dist/ScrollArea.d.mts +8 -0
  71. package/dist/ScrollArea.d.mts.map +1 -0
  72. package/dist/ScrollArea.mjs +11 -0
  73. package/dist/ScrollArea.mjs.map +1 -0
  74. package/dist/Segmented.d.mts +3 -3
  75. package/dist/Segmented.d.mts.map +1 -1
  76. package/dist/Space.d.mts +2 -2
  77. package/dist/Space.d.mts.map +1 -1
  78. package/dist/Statistic.d.mts +22 -0
  79. package/dist/Statistic.d.mts.map +1 -0
  80. package/dist/Statistic.mjs +53 -0
  81. package/dist/Statistic.mjs.map +1 -0
  82. package/dist/Steps.d.mts +3 -3
  83. package/dist/Steps.d.mts.map +1 -1
  84. package/dist/Steps.mjs +1 -1
  85. package/dist/Table.d.mts +4 -4
  86. package/dist/Table.d.mts.map +1 -1
  87. package/dist/Tag.d.mts +3 -3
  88. package/dist/Tag.d.mts.map +1 -1
  89. package/dist/TimePicker.d.mts +26 -0
  90. package/dist/TimePicker.d.mts.map +1 -0
  91. package/dist/TimePicker.mjs +77 -0
  92. package/dist/TimePicker.mjs.map +1 -0
  93. package/dist/Timeline.d.mts +35 -0
  94. package/dist/Timeline.d.mts.map +1 -0
  95. package/dist/Timeline.mjs +59 -0
  96. package/dist/Timeline.mjs.map +1 -0
  97. package/dist/Tour.d.mts +37 -0
  98. package/dist/Tour.d.mts.map +1 -0
  99. package/dist/Tour.mjs +192 -0
  100. package/dist/Tour.mjs.map +1 -0
  101. package/dist/Transfer.d.mts +36 -0
  102. package/dist/Transfer.d.mts.map +1 -0
  103. package/dist/Transfer.mjs +147 -0
  104. package/dist/Transfer.mjs.map +1 -0
  105. package/dist/Tree.d.mts +62 -0
  106. package/dist/Tree.d.mts.map +1 -0
  107. package/dist/Tree.mjs +462 -0
  108. package/dist/Tree.mjs.map +1 -0
  109. package/dist/TreeSelect.d.mts +34 -0
  110. package/dist/TreeSelect.d.mts.map +1 -0
  111. package/dist/TreeSelect.mjs +135 -0
  112. package/dist/TreeSelect.mjs.map +1 -0
  113. package/dist/Typography.d.mts.map +1 -1
  114. package/dist/components/atoms/checkbox/checkbox.d.mts +5 -3
  115. package/dist/components/atoms/checkbox/checkbox.d.mts.map +1 -1
  116. package/dist/components/atoms/checkbox/checkbox.mjs +8 -4
  117. package/dist/components/atoms/checkbox/checkbox.mjs.map +1 -1
  118. package/dist/components/atoms/checkbox/group.d.mts +2 -2
  119. package/dist/components/atoms/checkbox/group.d.mts.map +1 -1
  120. package/dist/components/atoms/checkbox/index.d.mts.map +1 -1
  121. package/dist/components/atoms/color-picker.d.mts +2 -2
  122. package/dist/components/atoms/color-picker.d.mts.map +1 -1
  123. package/dist/components/atoms/date-picker.d.mts +5 -1
  124. package/dist/components/atoms/date-picker.d.mts.map +1 -1
  125. package/dist/components/atoms/date-picker.mjs +54 -10
  126. package/dist/components/atoms/date-picker.mjs.map +1 -1
  127. package/dist/components/atoms/float-button/back-top.d.mts +2 -2
  128. package/dist/components/atoms/float-button/back-top.d.mts.map +1 -1
  129. package/dist/components/atoms/float-button/back-top.mjs +1 -1
  130. package/dist/components/atoms/float-button/float-button.d.mts +2 -2
  131. package/dist/components/atoms/float-button/float-button.d.mts.map +1 -1
  132. package/dist/components/atoms/float-button/index.d.mts.map +1 -1
  133. package/dist/components/atoms/index.d.mts +13 -6
  134. package/dist/components/atoms/input/index.d.mts +3 -1
  135. package/dist/components/atoms/input/index.d.mts.map +1 -1
  136. package/dist/components/atoms/input/index.mjs +3 -1
  137. package/dist/components/atoms/input/index.mjs.map +1 -1
  138. package/dist/components/atoms/input/number.d.mts +2 -2
  139. package/dist/components/atoms/input/number.d.mts.map +1 -1
  140. package/dist/components/atoms/input/number.mjs +1 -1
  141. package/dist/components/atoms/input/otp.d.mts +26 -0
  142. package/dist/components/atoms/input/otp.d.mts.map +1 -0
  143. package/dist/components/atoms/input/otp.mjs +52 -0
  144. package/dist/components/atoms/input/otp.mjs.map +1 -0
  145. package/dist/components/atoms/input/search.d.mts +2 -2
  146. package/dist/components/atoms/input/search.d.mts.map +1 -1
  147. package/dist/components/atoms/input/search.mjs +2 -2
  148. package/dist/components/atoms/mentions-token.mjs +31 -0
  149. package/dist/components/atoms/mentions-token.mjs.map +1 -0
  150. package/dist/components/atoms/option-group.d.mts +4 -5
  151. package/dist/components/atoms/option-group.d.mts.map +1 -1
  152. package/dist/components/atoms/popover.d.mts +2 -2
  153. package/dist/components/atoms/popover.d.mts.map +1 -1
  154. package/dist/components/atoms/progress.d.mts +2 -2
  155. package/dist/components/atoms/progress.d.mts.map +1 -1
  156. package/dist/components/atoms/radio/group.d.mts +2 -2
  157. package/dist/components/atoms/radio/group.d.mts.map +1 -1
  158. package/dist/components/atoms/radio/group.mjs +1 -1
  159. package/dist/components/atoms/radio/index.d.mts.map +1 -1
  160. package/dist/components/atoms/radio/radio.d.mts +2 -2
  161. package/dist/components/atoms/radio/radio.d.mts.map +1 -1
  162. package/dist/components/atoms/radio/radio.mjs +1 -1
  163. package/dist/components/atoms/rich-text-editor/rich-text-editor.d.mts +2 -2
  164. package/dist/components/atoms/rich-text-editor/rich-text-editor.d.mts.map +1 -1
  165. package/dist/components/atoms/rich-text-editor/toolbar-presets.mjs +2 -2
  166. package/dist/components/atoms/rich-text-editor/types.d.mts +2 -3
  167. package/dist/components/atoms/rich-text-editor/types.d.mts.map +1 -1
  168. package/dist/components/atoms/select-multiple.d.mts +2 -3
  169. package/dist/components/atoms/select-multiple.d.mts.map +1 -1
  170. package/dist/components/atoms/select-multiple.mjs +4 -3
  171. package/dist/components/atoms/select-multiple.mjs.map +1 -1
  172. package/dist/components/atoms/select-searchable-options.d.mts +3 -4
  173. package/dist/components/atoms/select-searchable-options.d.mts.map +1 -1
  174. package/dist/components/atoms/select-searchable.d.mts +2 -3
  175. package/dist/components/atoms/select-searchable.d.mts.map +1 -1
  176. package/dist/components/atoms/select-searchable.mjs +4 -3
  177. package/dist/components/atoms/select-searchable.mjs.map +1 -1
  178. package/dist/components/atoms/select.d.mts +3 -3
  179. package/dist/components/atoms/select.d.mts.map +1 -1
  180. package/dist/components/atoms/skeleton/button.d.mts.map +1 -1
  181. package/dist/components/atoms/skeleton/index.d.mts.map +1 -1
  182. package/dist/components/atoms/skeleton/node.d.mts.map +1 -1
  183. package/dist/components/atoms/skeleton/skeleton.d.mts +2 -2
  184. package/dist/components/atoms/skeleton/skeleton.d.mts.map +1 -1
  185. package/dist/components/atoms/slider/slider.d.mts +3 -3
  186. package/dist/components/atoms/slider/slider.d.mts.map +1 -1
  187. package/dist/components/atoms/spin.d.mts +2 -2
  188. package/dist/components/atoms/spin.d.mts.map +1 -1
  189. package/dist/components/atoms/spin.mjs +1 -1
  190. package/dist/components/atoms/switch.d.mts +2 -2
  191. package/dist/components/atoms/switch.d.mts.map +1 -1
  192. package/dist/components/atoms/tooltip.d.mts +2 -2
  193. package/dist/components/atoms/tooltip.d.mts.map +1 -1
  194. package/dist/components/atoms/typography/link.d.mts +2 -2
  195. package/dist/components/atoms/typography/link.d.mts.map +1 -1
  196. package/dist/components/atoms/typography/paragraph.d.mts +2 -2
  197. package/dist/components/atoms/typography/paragraph.d.mts.map +1 -1
  198. package/dist/components/atoms/typography/text.d.mts +2 -2
  199. package/dist/components/atoms/typography/text.d.mts.map +1 -1
  200. package/dist/components/atoms/typography/title.d.mts +2 -2
  201. package/dist/components/atoms/typography/title.d.mts.map +1 -1
  202. package/dist/components/atoms/typography/typography.d.mts +2 -2
  203. package/dist/components/atoms/typography/typography.d.mts.map +1 -1
  204. package/dist/components/molecules/collapse.d.mts +2 -2
  205. package/dist/components/molecules/collapse.d.mts.map +1 -1
  206. package/dist/components/molecules/dropdown.d.mts +2 -2
  207. package/dist/components/molecules/dropdown.d.mts.map +1 -1
  208. package/dist/components/molecules/index.d.mts +22 -14
  209. package/dist/components/molecules/marquees/index.d.mts.map +1 -1
  210. package/dist/components/molecules/marquees/item.d.mts +4 -4
  211. package/dist/components/molecules/marquees/item.d.mts.map +1 -1
  212. package/dist/components/molecules/marquees/item.mjs +5 -5
  213. package/dist/components/molecules/marquees/item.mjs.map +1 -1
  214. package/dist/components/molecules/marquees/marquees.d.mts +2 -2
  215. package/dist/components/molecules/marquees/marquees.d.mts.map +1 -1
  216. package/dist/components/molecules/marquees/marquees.mjs +4 -5
  217. package/dist/components/molecules/marquees/marquees.mjs.map +1 -1
  218. package/dist/components/molecules/menu/item/item.mjs +1 -1
  219. package/dist/components/molecules/menu/menu.d.mts +9 -9
  220. package/dist/components/molecules/menu/menu.d.mts.map +1 -1
  221. package/dist/components/molecules/reveals/item.d.mts +2 -2
  222. package/dist/components/molecules/reveals/item.d.mts.map +1 -1
  223. package/dist/components/molecules/reveals/reveals.d.mts +5 -5
  224. package/dist/components/molecules/reveals/reveals.d.mts.map +1 -1
  225. package/dist/components/molecules/splitter/index.d.mts.map +1 -1
  226. package/dist/components/molecules/splitter/panel.d.mts +3 -3
  227. package/dist/components/molecules/splitter/panel.d.mts.map +1 -1
  228. package/dist/components/molecules/splitter/splitter.d.mts +3 -3
  229. package/dist/components/molecules/splitter/splitter.d.mts.map +1 -1
  230. package/dist/components/molecules/tabs.d.mts +4 -4
  231. package/dist/components/molecules/tabs.d.mts.map +1 -1
  232. package/dist/components/molecules/upload.d.mts +3 -3
  233. package/dist/components/molecules/upload.d.mts.map +1 -1
  234. package/dist/components/molecules/upload.mjs +1 -1
  235. package/dist/components/organisms/drawer.d.mts +2 -2
  236. package/dist/components/organisms/drawer.d.mts.map +1 -1
  237. package/dist/components/organisms/drawer.mjs +2 -2
  238. package/dist/components/organisms/form/context.d.mts +4 -0
  239. package/dist/components/organisms/form/context.d.mts.map +1 -0
  240. package/dist/components/organisms/form/context.mjs +9 -0
  241. package/dist/components/organisms/form/context.mjs.map +1 -0
  242. package/dist/components/organisms/form/control.d.mts +11 -0
  243. package/dist/components/organisms/form/control.d.mts.map +1 -0
  244. package/dist/components/organisms/form/control.mjs +19 -0
  245. package/dist/components/organisms/form/control.mjs.map +1 -0
  246. package/dist/components/organisms/form/field.d.mts +25 -0
  247. package/dist/components/organisms/form/field.d.mts.map +1 -0
  248. package/dist/components/organisms/form/field.mjs +54 -0
  249. package/dist/components/organisms/form/field.mjs.map +1 -0
  250. package/dist/components/organisms/form/form.d.mts +14 -0
  251. package/dist/components/organisms/form/form.d.mts.map +1 -0
  252. package/dist/components/organisms/form/form.mjs +23 -0
  253. package/dist/components/organisms/form/form.mjs.map +1 -0
  254. package/dist/components/organisms/index.d.mts +14 -6
  255. package/dist/components/organisms/list/index.d.mts.map +1 -1
  256. package/dist/components/organisms/list/list.d.mts +2 -2
  257. package/dist/components/organisms/list/list.d.mts.map +1 -1
  258. package/dist/components/organisms/modal.d.mts +6 -3
  259. package/dist/components/organisms/modal.d.mts.map +1 -1
  260. package/dist/components/organisms/modal.mjs +25 -18
  261. package/dist/components/organisms/modal.mjs.map +1 -1
  262. package/dist/components/organisms/swiper/index.d.mts.map +1 -1
  263. package/dist/components/organisms/swiper/swiper.d.mts +2 -2
  264. package/dist/components/organisms/swiper/swiper.d.mts.map +1 -1
  265. package/dist/components/organisms/toast.d.mts +2 -2
  266. package/dist/components/organisms/toast.d.mts.map +1 -1
  267. package/dist/components/organisms/toast.mjs +1 -1
  268. package/dist/components/templates/container.d.mts +2 -2
  269. package/dist/components/templates/container.d.mts.map +1 -1
  270. package/dist/components/templates/empty.d.mts +2 -2
  271. package/dist/components/templates/empty.d.mts.map +1 -1
  272. package/dist/components/templates/empty.mjs +1 -1
  273. package/dist/components/templates/grid/col.d.mts +2 -2
  274. package/dist/components/templates/grid/col.d.mts.map +1 -1
  275. package/dist/components/templates/grid/row.d.mts +2 -2
  276. package/dist/components/templates/grid/row.d.mts.map +1 -1
  277. package/dist/components/templates/layout/content.d.mts +2 -2
  278. package/dist/components/templates/layout/content.d.mts.map +1 -1
  279. package/dist/components/templates/layout/footer.d.mts +2 -2
  280. package/dist/components/templates/layout/footer.d.mts.map +1 -1
  281. package/dist/components/templates/layout/header.d.mts +2 -2
  282. package/dist/components/templates/layout/header.d.mts.map +1 -1
  283. package/dist/components/templates/layout/layout.d.mts +2 -2
  284. package/dist/components/templates/layout/layout.d.mts.map +1 -1
  285. package/dist/components/templates/layout/sider.d.mts +2 -2
  286. package/dist/components/templates/layout/sider.d.mts.map +1 -1
  287. package/dist/components/templates/layout/sider.mjs +1 -1
  288. package/dist/components/templates/page-header.d.mts +2 -2
  289. package/dist/components/templates/page-header.d.mts.map +1 -1
  290. package/dist/components/templates/page-header.mjs +1 -1
  291. package/dist/components/templates/result.d.mts +2 -2
  292. package/dist/components/templates/result.d.mts.map +1 -1
  293. package/dist/components/templates/result.mjs +1 -1
  294. package/dist/core/accordion.mjs +1 -1
  295. package/dist/core/autocomplete.d.mts +2 -0
  296. package/dist/core/autocomplete.mjs +48 -0
  297. package/dist/core/autocomplete.mjs.map +1 -0
  298. package/dist/core/badge.d.mts +5 -3
  299. package/dist/core/badge.d.mts.map +1 -1
  300. package/dist/core/button.d.mts +6 -4
  301. package/dist/core/button.d.mts.map +1 -1
  302. package/dist/core/calendar.d.mts +13 -3
  303. package/dist/core/calendar.d.mts.map +1 -0
  304. package/dist/core/calendar.mjs +1 -1
  305. package/dist/core/checkbox.mjs +11 -8
  306. package/dist/core/checkbox.mjs.map +1 -1
  307. package/dist/core/combobox.d.mts +26 -4
  308. package/dist/core/combobox.d.mts.map +1 -1
  309. package/dist/core/combobox.mjs +2 -2
  310. package/dist/core/combobox.mjs.map +1 -1
  311. package/dist/core/dialog.mjs +2 -2
  312. package/dist/core/dialog.mjs.map +1 -1
  313. package/dist/core/form.d.mts +8 -0
  314. package/dist/core/form.d.mts.map +1 -0
  315. package/dist/core/form.mjs +3 -0
  316. package/dist/core/index.d.mts +13 -9
  317. package/dist/core/popover.mjs +10 -2
  318. package/dist/core/popover.mjs.map +1 -1
  319. package/dist/core/radio-group.mjs +1 -1
  320. package/dist/core/resizable.d.mts +7 -2
  321. package/dist/core/resizable.d.mts.map +1 -1
  322. package/dist/core/resizable.mjs +1 -1
  323. package/dist/core/scroll-area.d.mts +20 -0
  324. package/dist/core/scroll-area.d.mts.map +1 -0
  325. package/dist/core/scroll-area.mjs +57 -0
  326. package/dist/core/scroll-area.mjs.map +1 -0
  327. package/dist/core/select.d.mts +24 -2
  328. package/dist/core/select.d.mts.map +1 -1
  329. package/dist/core/select.mjs +1 -1
  330. package/dist/core/separator.d.mts +13 -2
  331. package/dist/core/separator.d.mts.map +1 -0
  332. package/dist/core/tabs.d.mts +16 -2
  333. package/dist/core/tabs.d.mts.map +1 -1
  334. package/dist/index.d.mts +59 -36
  335. package/dist/index.mjs +25 -6
  336. package/dist/lib/colors.d.mts +2 -3
  337. package/dist/lib/colors.d.mts.map +1 -1
  338. package/dist/providers/config/context.d.mts +2 -3
  339. package/dist/providers/config/context.d.mts.map +1 -1
  340. package/dist/providers/config/context.mjs +3 -1
  341. package/dist/providers/config/context.mjs.map +1 -1
  342. package/dist/providers/config/registry.d.mts +2 -3
  343. package/dist/providers/config/registry.d.mts.map +1 -1
  344. package/dist/providers/config/types.d.mts +8 -7
  345. package/dist/providers/config/types.d.mts.map +1 -1
  346. package/dist/style.css +689 -332
  347. package/dist/utils.d.mts +2 -3
  348. package/dist/utils.d.mts.map +1 -1
  349. package/package.json +122 -26
  350. package/dist/components/molecules/marquees/use-pause-on-hover.mjs +0 -26
  351. package/dist/components/molecules/marquees/use-pause-on-hover.mjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"select-searchable.mjs","names":["combobox","select.selectTriggerStyles"],"sources":["../../../src/components/atoms/select-searchable.tsx"],"sourcesContent":["'use client';\n\nimport { type ReactNode } from 'react';\n\nimport { ChevronDownIcon, XIcon } from 'lucide-react';\n\nimport { DEFAULT_LOCALE, useConfig } from '@repo/ui/providers';\nimport { cn } from '@repo/ui/utils';\n\nimport { combobox, select } from '../../core';\nimport Button from './button';\nimport Input from './input';\nimport SearchableOptions, {\n type ClassNames,\n type Option,\n type OptionGroup,\n useSelectItems,\n} from './select-searchable-options';\n\nconst {\n Combobox: Core,\n ComboboxClear,\n ComboboxContent,\n ComboboxIcon,\n ComboboxInput,\n ComboboxTrigger,\n ComboboxValue,\n} = combobox;\n\nexport interface Props extends Omit<\n combobox.RootProps<string, Option>,\n | 'children'\n | 'items'\n | 'multiple'\n | 'filteredItems'\n | 'onValueChange'\n | 'itemToStringLabel'\n | 'itemToStringValue'\n | 'isItemEqualToValue'\n> {\n searchable: true;\n multiple?: false;\n /** Accessible name for the trigger and search popup. */\n label: string;\n options: (Option | OptionGroup)[];\n placeholder?: string;\n searchPlaceholder?: string;\n emptyText?: ReactNode;\n allowClear?: boolean;\n className?: string;\n classNames?: ClassNames;\n onChange?: (value: string | null) => void;\n}\n\nconst SearchableSelect = ({\n label,\n options,\n placeholder,\n searchPlaceholder = 'Search...',\n emptyText = 'No results found.',\n allowClear = true,\n className,\n classNames,\n onChange,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars -- Do not forward the public mode switch to Base UI.\n searchable: _searchable,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars -- The single-select primitive fixes this mode internally.\n multiple: _multiple,\n ...props\n}: Props) => {\n const { locale } = useConfig();\n const items = useSelectItems(options);\n\n return (\n <Core items={items} onValueChange={value => onChange?.(value)} {...props}>\n <ComboboxTrigger\n data-slot=\"select-trigger\"\n data-size=\"default\"\n aria-label={label}\n className={cn(select.selectTriggerStyles, 'w-full max-w-48', className)}\n >\n <span\n data-slot=\"select-value\"\n className=\"min-w-0 flex-1 truncate text-start\"\n >\n <ComboboxValue placeholder={placeholder} />\n </span>\n <ComboboxIcon className=\"opacity-50\">\n <ChevronDownIcon />\n </ComboboxIcon>\n </ComboboxTrigger>\n <ComboboxContent aria-label={label} className={classNames?.content}>\n <div className=\"border-b p-1\">\n <div className=\"relative flex items-center\">\n <ComboboxInput\n render={\n <Input\n aria-label={`${label} search`}\n placeholder={searchPlaceholder}\n className={cn(allowClear && 'pe-8', classNames?.input)}\n />\n }\n />\n {allowClear && (\n <ComboboxClear\n data-slot=\"combobox-clear\"\n render={\n <Button\n variant=\"text\"\n size=\"icon-sm\"\n icon={<XIcon />}\n aria-label={locale.clear ?? DEFAULT_LOCALE.clear}\n className=\"absolute end-0\"\n />\n }\n />\n )}\n </div>\n </div>\n <SearchableOptions emptyText={emptyText} classNames={classNames} />\n </ComboboxContent>\n </Core>\n );\n};\n\nexport default SearchableSelect;\n"],"mappings":";;;;;;;;;;;AAmBA,MAAM,EACJ,UAAU,MACV,eACA,iBACA,cACA,eACA,iBACA,kBACEA;AA2BJ,MAAM,oBAAoB,EACxB,OACA,SACA,aACA,oBAAoB,aACpB,YAAY,qBACZ,aAAa,MACb,WACA,YACA,UAEA,YAAY,aAEZ,UAAU,WACV,GAAG,YACQ;CACX,MAAM,EAAE,WAAW,UAAU;CAC7B,MAAM,QAAQ,eAAe,OAAO;CAEpC,OACE,qBAAC,MAAD;EAAa;EAAO,gBAAe,UAAS,WAAW,KAAK;EAAG,GAAI;EAAnE,UAAA,CACE,qBAAC,iBAAD;GACE,aAAU;GACV,aAAU;GACV,cAAY;GACZ,WAAW,GAAGC,qBAA4B,mBAAmB,SAAS;GAJxE,UAAA,CAME,oBAAC,QAAD;IACE,aAAU;IACV,WAAU;IAEV,UAAA,oBAAC,eAAD,EAA4B,YAAc,CAAA;GACtC,CAAA,GACN,oBAAC,cAAD;IAAc,WAAU;IACtB,UAAA,oBAAC,iBAAD,CAAkB,CAAA;GACN,CAAA,CACC;EACjB,CAAA,GAAA,qBAAC,iBAAD;GAAiB,cAAY;GAAO,WAAW,YAAY;GAA3D,UAAA,CACE,oBAAC,OAAD;IAAK,WAAU;IACb,UAAA,qBAAC,OAAD;KAAK,WAAU;KAAf,UAAA,CACE,oBAAC,eAAD,EACE,QACE,oBAAC,OAAD;MACE,cAAY,GAAG,MAAM;MACrB,aAAa;MACb,WAAW,GAAG,cAAc,QAAQ,YAAY,KAAK;KACtD,CAAA,EAEJ,CAAA,GACA,cACC,oBAAC,eAAD;MACE,aAAU;MACV,QACE,oBAAC,QAAD;OACE,SAAQ;OACR,MAAK;OACL,MAAM,oBAAC,OAAD,CAAQ,CAAA;OACd,cAAY,OAAO,SAAS,eAAe;OAC3C,WAAU;MACX,CAAA;KAEJ,CAAA,CAEA;;GACF,CAAA,GACL,oBAAC,mBAAD;IAA8B;IAAuB;GAAa,CAAA,CACnD;EACb,CAAA,CAAA;;AAEV"}
1
+ {"version":3,"file":"select-searchable.mjs","names":["combobox","select.selectTriggerStyles"],"sources":["../../../src/components/atoms/select-searchable.tsx"],"sourcesContent":["'use client';\n\nimport { type ReactNode } from 'react';\n\nimport { ChevronDownIcon, XIcon } from 'lucide-react';\n\nimport { DEFAULT_LOCALE, useConfig } from '@repo/ui/providers';\nimport { cn } from '@repo/ui/utils';\n\nimport { combobox, select } from '../../core';\nimport Button from './button';\nimport Input from './input';\nimport SearchableOptions, {\n type ClassNames,\n type Option,\n type OptionGroup,\n useSelectItems,\n} from './select-searchable-options';\n\nconst {\n Combobox: Core,\n ComboboxClear,\n ComboboxContent,\n ComboboxIcon,\n ComboboxInput,\n ComboboxTrigger,\n ComboboxValue,\n} = combobox;\n\nexport interface Props extends Omit<\n combobox.RootProps<string, Option>,\n | 'children'\n | 'items'\n | 'multiple'\n | 'filteredItems'\n | 'onValueChange'\n | 'itemToStringLabel'\n | 'itemToStringValue'\n | 'isItemEqualToValue'\n> {\n searchable: true;\n multiple?: false;\n /** Accessible name for the trigger and search popup. */\n label: string;\n options: (Option | OptionGroup)[];\n placeholder?: string;\n searchPlaceholder?: string;\n emptyText?: ReactNode;\n allowClear?: boolean;\n className?: string;\n classNames?: ClassNames;\n onChange?: (value: string | null) => void;\n}\n\nconst SearchableSelect = ({\n label,\n options,\n placeholder,\n searchPlaceholder = 'Search...',\n emptyText = 'No results found.',\n allowClear = true,\n className,\n classNames,\n onChange,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars -- Do not forward the public mode switch to Base UI.\n searchable: _searchable,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars -- The single-select primitive fixes this mode internally.\n multiple: _multiple,\n ...props\n}: Props) => {\n const { locale } = useConfig();\n const items = useSelectItems(options);\n\n return (\n <Core items={items} onValueChange={value => onChange?.(value)} {...props}>\n <ComboboxTrigger\n data-slot=\"select-trigger\"\n data-size=\"default\"\n aria-label={label}\n className={cn(select.selectTriggerStyles, 'w-full max-w-48', className)}\n >\n <span\n data-slot=\"select-value\"\n className=\"min-w-0 flex-1 truncate text-start\"\n >\n <ComboboxValue placeholder={placeholder} />\n </span>\n <ComboboxIcon className=\"opacity-50\">\n <ChevronDownIcon />\n </ComboboxIcon>\n </ComboboxTrigger>\n <ComboboxContent aria-label={label} className={classNames?.content}>\n <div className=\"border-b p-1\">\n <div className=\"relative flex items-center\">\n <ComboboxInput\n render={\n <Input\n aria-label={`${label} search`}\n placeholder={searchPlaceholder}\n className={cn(allowClear && 'pe-8', classNames?.input)}\n />\n }\n />\n {allowClear && (\n <ComboboxClear\n data-slot=\"combobox-clear\"\n render={\n <Button\n variant=\"text\"\n size=\"icon-sm\"\n icon={<XIcon />}\n aria-label={locale.clear ?? DEFAULT_LOCALE.clear}\n className=\"absolute end-0\"\n />\n }\n >\n {null}\n </ComboboxClear>\n )}\n </div>\n </div>\n <SearchableOptions emptyText={emptyText} classNames={classNames} />\n </ComboboxContent>\n </Core>\n );\n};\n\nexport default SearchableSelect;\n"],"mappings":";;;;;;;;;;;AAmBA,MAAM,EACJ,UAAU,MACV,eACA,iBACA,cACA,eACA,iBACA,kBACEA;AA2BJ,MAAM,oBAAoB,EACxB,OACA,SACA,aACA,oBAAoB,aACpB,YAAY,qBACZ,aAAa,MACb,WACA,YACA,UAEA,YAAY,aAEZ,UAAU,WACV,GAAG,YACQ;CACX,MAAM,EAAE,WAAW,UAAU;CAC7B,MAAM,QAAQ,eAAe,OAAO;CAEpC,OACE,qBAAC,MAAD;EAAa;EAAO,gBAAe,UAAS,WAAW,KAAK;EAAG,GAAI;EAAnE,UAAA,CACE,qBAAC,iBAAD;GACE,aAAU;GACV,aAAU;GACV,cAAY;GACZ,WAAW,GAAGC,qBAA4B,mBAAmB,SAAS;GAJxE,UAAA,CAME,oBAAC,QAAD;IACE,aAAU;IACV,WAAU;IAEV,UAAA,oBAAC,eAAD,EAA4B,YAAc,CAAA;GACtC,CAAA,GACN,oBAAC,cAAD;IAAc,WAAU;IACtB,UAAA,oBAAC,iBAAD,CAAkB,CAAA;GACN,CAAA,CACC;EACjB,CAAA,GAAA,qBAAC,iBAAD;GAAiB,cAAY;GAAO,WAAW,YAAY;GAA3D,UAAA,CACE,oBAAC,OAAD;IAAK,WAAU;IACb,UAAA,qBAAC,OAAD;KAAK,WAAU;KAAf,UAAA,CACE,oBAAC,eAAD,EACE,QACE,oBAAC,OAAD;MACE,cAAY,GAAG,MAAM;MACrB,aAAa;MACb,WAAW,GAAG,cAAc,QAAQ,YAAY,KAAK;KACtD,CAAA,EAEJ,CAAA,GACA,cACC,oBAAC,eAAD;MACE,aAAU;MACV,QACE,oBAAC,QAAD;OACE,SAAQ;OACR,MAAK;OACL,MAAM,oBAAC,OAAD,CAAQ,CAAA;OACd,cAAY,OAAO,SAAS,eAAe;OAC3C,WAAU;MACX,CAAA;MAGF,UAAA;KACY,CAAA,CAEd;;GACF,CAAA,GACL,oBAAC,mBAAD;IAA8B;IAAuB;GAAa,CAAA,CACnD;EACb,CAAA,CAAA;;AAEV"}
@@ -1,4 +1,4 @@
1
- import { Select as Select$1 } from "../../core/select.mjs";
1
+ import { Select as Select$1, select_d_exports } from "../../core/select.mjs";
2
2
  import "../../core/index.mjs";
3
3
  import { Props as Props$1 } from "./select-multiple.mjs";
4
4
  import { Props as Props$2 } from "./select-searchable.mjs";
@@ -22,8 +22,8 @@ interface StaticProps extends Omit<React.ComponentProps<typeof Core>, 'onValueCh
22
22
  onChange?: (value: string) => void;
23
23
  'aria-label'?: string;
24
24
  }
25
- type Props = StaticProps | Props$2 | Props$1;
25
+ export type Props = StaticProps | Props$2 | Props$1;
26
26
  declare const Select: (props: Props) => React.JSX.Element;
27
27
  //#endregion
28
- export { Props, Select as default };
28
+ export { Select as default };
29
29
  //# sourceMappingURL=select.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"select.d.mts","names":[],"sources":["../../../src/components/atoms/select.tsx"],"mappings":";;;;;;cAWU,aAAI;UASJ;EACR,OAAO,MAAM;EACb;EACA;;UAGQ;EACR,OAAO,MAAM;EACb,SAAS;;UAOD,oBAAoB,KAC5B,MAAM,sBAAsB;EAG5B;EACA;EACA;EACA,WAAW,SAAS;EACpB,YAAY;EACZ;;KAGU,QAAQ,cAAc,UAAkB;cA8D9C,SAAU,OAAO,UAAK,MAAA,IAAA"}
1
+ {"version":3,"file":"select.d.mts","names":["select","select.Select","SearchableProps","MultipleProps"],"sources":["../../../src/components/atoms/select.tsx"],"mappings":";;;;;;cAWU,aAAIC;UASJ;EACR,OAAO,MAAM;EACb;EACA;;UAGQ;EACR,OAAO,MAAM;EACb,SAAS;;UAOD,oBAAoB,KAC5B,MAAM,sBAAsB;EAG5B;EACA;EACA;EACA,WAAW,SAAS;EACpB,YAAY;EACZ;;YAGU,QAAQ,cAAcC,UAAkBC;cA8D9C,SAAU,OAAO,UAAK,MAAA,IAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"button.d.mts","names":[],"sources":["../../../../src/components/atoms/skeleton/button.tsx"],"mappings":";;cAIM,WAAU,eAAA,SAA0B,0BAAa,IAAA"}
1
+ {"version":3,"file":"button.d.mts","names":["SkeletonProps"],"sources":["../../../../src/components/atoms/skeleton/button.tsx"],"mappings":";;cAIM,WAAU,eAAA,SAA0BA,0BAAa,IAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../../../../src/components/atoms/skeleton/index.ts"],"mappings":";;;;KAIK,2BAA2B;EAC9B,eAAe;EACf,aAAa;;cAGT,UAA2B"}
1
+ {"version":3,"file":"index.d.mts","names":["SkeletonImpl"],"sources":["../../../../src/components/atoms/skeleton/index.ts"],"mappings":";;;;KAIK,2BAA2BA;EAC9B,eAAe;EACf,aAAa;;cAGT,UAA2B"}
@@ -1 +1 @@
1
- {"version":3,"file":"node.d.mts","names":[],"sources":["../../../../src/components/atoms/skeleton/node.tsx"],"mappings":";;cAIM,SAAQ,eAAA,SAA0B,0BAAa,IAAA"}
1
+ {"version":3,"file":"node.d.mts","names":["SkeletonProps"],"sources":["../../../../src/components/atoms/skeleton/node.tsx"],"mappings":";;cAIM,SAAQ,eAAA,SAA0BA,0BAAa,IAAA"}
@@ -1,5 +1,5 @@
1
1
  //#region src/components/atoms/skeleton/skeleton.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'div'> {
2
+ export interface Props extends React.ComponentPropsWithoutRef<'div'> {
3
3
  active?: boolean;
4
4
  loading?: boolean;
5
5
  avatar?: boolean;
@@ -19,5 +19,5 @@ interface Props extends React.ComponentPropsWithoutRef<'div'> {
19
19
  }
20
20
  declare const Skeleton: ({ active, loading, avatar, size, orientation, direction, count, gap, className, classNames, style, width, height, children, ...props }: Props) => string | number | bigint | boolean | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react").JSX.Element | null;
21
21
  //#endregion
22
- export { Props, Skeleton as default };
22
+ export { Skeleton as default };
23
23
  //# sourceMappingURL=skeleton.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"skeleton.d.mts","names":[],"sources":["../../../../src/components/atoms/skeleton/skeleton.tsx"],"mappings":";UAaiB,cAAc,MAAM;EACnC;EACA;EACA;EACA;EACA;EACA;EACA;;EAEA;EACA;EACA;EACA;IACE;IACA;IACA;;;cAUE,aAAY,QAAA,SAAA,QAAA,MAAA,aAAA,WAAA,OAAA,KAAA,WAAA,YAAA,OAAA,OAAA,QAAA,aAAA,SAgBf,+CAAK,yBAAA,aAAA,6DAAA,8BAAA,+CAAA,8BAAA,yBAAA,iDAAA,IAAA"}
1
+ {"version":3,"file":"skeleton.d.mts","names":[],"sources":["../../../../src/components/atoms/skeleton/skeleton.tsx"],"mappings":";iBAaiB,cAAc,MAAM;EACnC;EACA;EACA;EACA;EACA;EACA;EACA;;EAEA;EACA;EACA;EACA;IACE;IACA;IACA;;;cAUE,aAAY,QAAA,SAAA,QAAA,MAAA,aAAA,WAAA,OAAA,KAAA,WAAA,YAAA,OAAA,OAAA,QAAA,aAAA,SAgBf,+CAAK,yBAAA,aAAA,6DAAA,8BAAA,+CAAA,8BAAA,yBAAA,iDAAA,IAAA"}
@@ -1,7 +1,7 @@
1
1
  //#region src/components/atoms/slider/slider.d.ts
2
2
  /** A single thumb (`number`) or a two-thumb range (`[min, max]`). */
3
- type SliderValue = number | number[];
4
- interface Props extends Omit<React.ComponentPropsWithoutRef<'span'>, 'onChange' | 'defaultValue' | 'dir'> {
3
+ export type SliderValue = number | number[];
4
+ export interface Props extends Omit<React.ComponentPropsWithoutRef<'span'>, 'onChange' | 'defaultValue' | 'dir'> {
5
5
  value?: SliderValue;
6
6
  defaultValue?: SliderValue;
7
7
  min?: number;
@@ -13,5 +13,5 @@ interface Props extends Omit<React.ComponentPropsWithoutRef<'span'>, 'onChange'
13
13
  }
14
14
  declare const Slider: ({ value: _value, defaultValue, min, max, step, disabled, orientation, onChange: _onChange, className, ...props }: Props) => import("react").JSX.Element;
15
15
  //#endregion
16
- export { Props, SliderValue, Slider as default };
16
+ export { Slider as default };
17
17
  //# sourceMappingURL=slider.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"slider.d.mts","names":[],"sources":["../../../../src/components/atoms/slider/slider.tsx"],"mappings":";;KAWY;UAEK,cAAc,KAC7B,MAAM;EAGN,QAAQ;EACR,eAAe;EACf;EACA;EACA;EACA;EACA;EACA,YAAY,OAAO;;cAWf,WAAU,OAAA,QAAA,cAAA,KAAA,KAAA,MAAA,UAAA,aAAA,UAAA,WAAA,cAAA,SAWb,0BAAK,IAAA"}
1
+ {"version":3,"file":"slider.d.mts","names":[],"sources":["../../../../src/components/atoms/slider/slider.tsx"],"mappings":";;YAWY;iBAEK,cAAc,KAC7B,MAAM;EAGN,QAAQ;EACR,eAAe;EACf;EACA;EACA;EACA;EACA;EACA,YAAY,OAAO;;cAWf,WAAU,OAAA,QAAA,cAAA,KAAA,KAAA,MAAA,UAAA,aAAA,UAAA,WAAA,cAAA,SAWb,0BAAK,IAAA"}
@@ -1,8 +1,8 @@
1
1
  //#region src/components/atoms/spin.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'div'> {
2
+ export interface Props extends React.ComponentPropsWithoutRef<'div'> {
3
3
  spinning?: boolean;
4
4
  }
5
5
  declare const Spin: ({ spinning, className, children, ...props }: Props) => string | number | bigint | true | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react").JSX.Element | null;
6
6
  //#endregion
7
- export { Props, Spin as default };
7
+ export { Spin as default };
8
8
  //# sourceMappingURL=spin.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"spin.d.mts","names":[],"sources":["../../../src/components/atoms/spin.tsx"],"mappings":";UAOiB,cAAc,MAAM;EACnC;;cAGI,SAAQ,UAAA,WAAA,aAAA,SAA6C,4CAAK,yBAAA,aAAA,6DAAA,8BAAA,+CAAA,8BAAA,yBAAA,iDAAA,IAAA"}
1
+ {"version":3,"file":"spin.d.mts","names":[],"sources":["../../../src/components/atoms/spin.tsx"],"mappings":";iBAOiB,cAAc,MAAM;EACnC;;cAGI,SAAQ,UAAA,WAAA,aAAA,SAA6C,4CAAK,yBAAA,aAAA,6DAAA,8BAAA,+CAAA,8BAAA,yBAAA,iDAAA,IAAA"}
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import { cn } from "../../utils.mjs";
3
3
  import { DEFAULT_LOCALE, useConfig } from "../../providers/config/context.mjs";
4
- import { Loader2 } from "lucide-react";
5
4
  import { jsx, jsxs } from "react/jsx-runtime";
5
+ import { Loader2 } from "lucide-react";
6
6
  //#region src/components/atoms/spin.tsx
7
7
  const Spin = ({ spinning, className, children, ...props }) => {
8
8
  const { locale } = useConfig();
@@ -1,6 +1,6 @@
1
1
  import { ComponentSize } from "../../providers/config/types.mjs";
2
2
  //#region src/components/atoms/switch.d.ts
3
- interface Props extends Omit<React.ComponentPropsWithoutRef<'span'>, 'onChange'> {
3
+ export interface Props extends Omit<React.ComponentPropsWithoutRef<'span'>, 'onChange'> {
4
4
  classNames?: {
5
5
  track?: string;
6
6
  handle?: string;
@@ -22,5 +22,5 @@ interface Props extends Omit<React.ComponentPropsWithoutRef<'span'>, 'onChange'>
22
22
  }
23
23
  declare const Switch: ({ className, classNames, size, defaultChecked, checked: _checked, onChange: _onChange, checkedChildren, unCheckedChildren, ...props }: Props) => import("react").JSX.Element;
24
24
  //#endregion
25
- export { Props, Switch as default };
25
+ export { Switch as default };
26
26
  //# sourceMappingURL=switch.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"switch.d.mts","names":[],"sources":["../../../src/components/atoms/switch.tsx"],"mappings":";;UAiDiB,cAAc,KAC7B,MAAM;EAGN;IACE;IACA;;;;;;;;;EASF,OAAO;EACP;EACA;EACA;EACA,YAAY;EACZ,kBAAkB,MAAM;EACxB,oBAAoB,MAAM;;cAGtB,WAAU,WAAA,YAAA,MAAA,gBAAA,SAAA,UAAA,UAAA,WAAA,iBAAA,sBAAA,SAUb,0BAAK,IAAA"}
1
+ {"version":3,"file":"switch.d.mts","names":[],"sources":["../../../src/components/atoms/switch.tsx"],"mappings":";;iBAiDiB,cAAc,KAC7B,MAAM;EAGN;IACE;IACA;;;;;;;;;EASF,OAAO;EACP;EACA;EACA;EACA,YAAY;EACZ,kBAAkB,MAAM;EACxB,oBAAoB,MAAM;;cAGtB,WAAU,WAAA,YAAA,MAAA,gBAAA,SAAA,UAAA,UAAA,WAAA,iBAAA,sBAAA,SAUb,0BAAK,IAAA"}
@@ -2,7 +2,7 @@ import { ReactElement, ReactNode } from "react";
2
2
  //#region src/components/atoms/tooltip.d.ts
3
3
  declare const Core: <Payload>(props: import("@base-ui/react").TooltipRoot.Props<Payload>) => React.JSX.Element;
4
4
  type Placement = 'top' | 'left' | 'right' | 'bottom' | 'topLeft' | 'topRight' | 'bottomLeft' | 'bottomRight' | 'leftTop' | 'leftBottom' | 'rightTop' | 'rightBottom';
5
- interface Props extends Omit<React.ComponentProps<typeof Core>, 'children' | 'handle' | 'triggerId' | 'defaultTriggerId'> {
5
+ export interface Props extends Omit<React.ComponentProps<typeof Core>, 'children' | 'handle' | 'triggerId' | 'defaultTriggerId'> {
6
6
  children: ReactElement;
7
7
  /** Supplementary visual hint; keep essential information visible elsewhere. */
8
8
  content: ReactNode;
@@ -17,5 +17,5 @@ interface Props extends Omit<React.ComponentProps<typeof Core>, 'children' | 'ha
17
17
  }
18
18
  declare const Tooltip: ({ children, content, className, placement, offset, delay, closeDelay, ...props }: Props) => import("react").JSX.Element;
19
19
  //#endregion
20
- export { Props, Tooltip as default };
20
+ export { Tooltip as default };
21
21
  //# sourceMappingURL=tooltip.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tooltip.d.mts","names":[],"sources":["../../../src/components/atoms/tooltip.tsx"],"mappings":";;cAMiB,OAAI,SAAA,gCAAA,YAAA,MAAA,aAAA,MAAA,IAAA;KAEhB;UAgCY,cAAc,KAC7B,MAAM,sBAAsB;EAG5B,UAAU;;EAEV,SAAS;;EAET;EACA,YAAY;;EAEZ;;EAEA;EACA;;cAGI,YAAW,UAAA,SAAA,WAAA,WAAA,QAAA,OAAA,eAAA,SASd,0BAAK,IAAA"}
1
+ {"version":3,"file":"tooltip.d.mts","names":[],"sources":["../../../src/components/atoms/tooltip.tsx"],"mappings":";;cAMiB,OAAI,SAAA,gCAAA,YAAA,MAAA,aAAA,MAAA,IAAA;KAEhB;iBAgCY,cAAc,KAC7B,MAAM,sBAAsB;EAG5B,UAAU;;EAEV,SAAS;;EAET;EACA,YAAY;;EAEZ;;EAEA;EACA;;cAGI,YAAW,UAAA,SAAA,WAAA,WAAA,QAAA,OAAA,eAAA,SASd,0BAAK,IAAA"}
@@ -1,6 +1,6 @@
1
1
  //#region src/components/atoms/typography/link.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'a'> {}
2
+ export interface Props extends React.ComponentPropsWithoutRef<'a'> {}
3
3
  declare const Link: ({ children, className, target, rel, ...props }: Props) => import("react").JSX.Element;
4
4
  //#endregion
5
- export { Props, Link as default };
5
+ export { Link as default };
6
6
  //# sourceMappingURL=link.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"link.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/link.tsx"],"mappings":";UAEiB,cAAc,MAAM;cAE/B,SAAQ,UAAA,WAAA,QAAA,QAAA,SAAgD,0BAAK,IAAA"}
1
+ {"version":3,"file":"link.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/link.tsx"],"mappings":";iBAEiB,cAAc,MAAM;cAE/B,SAAQ,UAAA,WAAA,QAAA,QAAA,SAAgD,0BAAK,IAAA"}
@@ -1,6 +1,6 @@
1
1
  //#region src/components/atoms/typography/paragraph.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'p'> {}
2
+ export interface Props extends React.ComponentPropsWithoutRef<'p'> {}
3
3
  declare const Paragraph: ({ children, className, ...props }: Props) => import("react").JSX.Element;
4
4
  //#endregion
5
- export { Props, Paragraph as default };
5
+ export { Paragraph as default };
6
6
  //# sourceMappingURL=paragraph.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"paragraph.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/paragraph.tsx"],"mappings":";UAEiB,cAAc,MAAM;cAE/B,cAAa,UAAA,cAAA,SAAmC,0BAAK,IAAA"}
1
+ {"version":3,"file":"paragraph.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/paragraph.tsx"],"mappings":";iBAEiB,cAAc,MAAM;cAE/B,cAAa,UAAA,cAAA,SAAmC,0BAAK,IAAA"}
@@ -1,9 +1,9 @@
1
1
  //#region src/components/atoms/typography/text.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'span'> {
2
+ export interface Props extends React.ComponentPropsWithoutRef<'span'> {
3
3
  underline?: boolean;
4
4
  strong?: boolean;
5
5
  }
6
6
  declare const Text: ({ children, underline, strong, className, ...props }: Props) => import("react").JSX.Element;
7
7
  //#endregion
8
- export { Props, Text as default };
8
+ export { Text as default };
9
9
  //# sourceMappingURL=text.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"text.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/text.tsx"],"mappings":";UAEiB,cAAc,MAAM;EACnC;EACA;;cAGI,SAAQ,UAAA,WAAA,QAAA,cAAA,SAAsD,0BAAK,IAAA"}
1
+ {"version":3,"file":"text.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/text.tsx"],"mappings":";iBAEiB,cAAc,MAAM;EACnC;EACA;;cAGI,SAAQ,UAAA,WAAA,QAAA,cAAA,SAAsD,0BAAK,IAAA"}
@@ -1,8 +1,8 @@
1
1
  //#region src/components/atoms/typography/title.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'> {
2
+ export interface Props extends React.ComponentPropsWithoutRef<'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'> {
3
3
  level?: 1 | 2 | 3 | 4 | 5 | 6;
4
4
  }
5
5
  declare const Title: ({ children, level, className, ...props }: Props) => import("react").JSX.Element;
6
6
  //#endregion
7
- export { Props, Title as default };
7
+ export { Title as default };
8
8
  //# sourceMappingURL=title.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"title.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/title.tsx"],"mappings":";UAEiB,cAAc,MAAM;EAGnC;;cAiBI,UAAS,UAAA,OAAA,cAAA,SAA8C,0BAAK,IAAA"}
1
+ {"version":3,"file":"title.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/title.tsx"],"mappings":";iBAEiB,cAAc,MAAM;EAGnC;;cAiBI,UAAS,UAAA,OAAA,cAAA,SAA8C,0BAAK,IAAA"}
@@ -1,6 +1,6 @@
1
1
  //#region src/components/atoms/typography/typography.d.ts
2
- interface Props extends React.ComponentPropsWithoutRef<'article'> {}
2
+ export interface Props extends React.ComponentPropsWithoutRef<'article'> {}
3
3
  declare const Typography: ({ children, ...props }: Props) => import("react").JSX.Element;
4
4
  //#endregion
5
- export { Props, Typography as default };
5
+ export { Typography as default };
6
6
  //# sourceMappingURL=typography.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"typography.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/typography.tsx"],"mappings":";UAAiB,cAAc,MAAM;cAE/B,eAAc,aAAA,SAAwB,0BAAK,IAAA"}
1
+ {"version":3,"file":"typography.d.mts","names":[],"sources":["../../../../src/components/atoms/typography/typography.tsx"],"mappings":";iBAAiB,cAAc,MAAM;cAE/B,eAAc,aAAA,SAAwB,0BAAK,IAAA"}
@@ -6,7 +6,7 @@ interface Item<Key extends React.Key = string> {
6
6
  disabled?: boolean;
7
7
  children: React.ReactNode;
8
8
  }
9
- interface Props<Key extends React.Key = string> extends Omit<React.ComponentPropsWithoutRef<'div'>, 'onChange' | 'defaultValue' | 'value' | 'dir'> {
9
+ export interface Props<Key extends React.Key = string> extends Omit<React.ComponentPropsWithoutRef<'div'>, 'onChange' | 'defaultValue' | 'value' | 'dir'> {
10
10
  items?: Item<Key>[];
11
11
  accordion?: boolean;
12
12
  expandIcon?: React.ReactNode;
@@ -21,5 +21,5 @@ interface Props<Key extends React.Key = string> extends Omit<React.ComponentProp
21
21
  }
22
22
  declare const Collapse: <Key extends React.Key = string>({ expandIcon, accordion, items, className, classNames, defaultActiveKey, activeKey: _activeKey, onChange: _onChange, ...props }: Props<Key>) => React.JSX.Element;
23
23
  //#endregion
24
- export { Props, Collapse as default };
24
+ export { Collapse as default };
25
25
  //# sourceMappingURL=collapse.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"collapse.d.mts","names":[],"sources":["../../../src/components/molecules/collapse.tsx"],"mappings":";;UAWU,KAAK,YAAY,MAAM;EAC/B,KAAK;EACL,OAAO,MAAM;EACb;EACA,UAAU,MAAM;;UAGD,MAAM,YAAY,MAAM,sBAAsB,KAC7D,MAAM;EAGN,QAAQ,KAAK;EACb;EACA,aAAa,MAAM;EACnB;IACE;IACA;IACA;;EAEF,mBAAmB;EACnB,YAAY;EACZ,YAAY,MAAM;;cAGd,WAAY,YAAY,MAAM,gBAAc,YAAA,WAAA,OAAA,WAAA,YAAA,kBAAA,WAAA,YAAA,UAAA,cAAA,SAU/C,MAAM,SAAI,MAAA,IAAA"}
1
+ {"version":3,"file":"collapse.d.mts","names":[],"sources":["../../../src/components/molecules/collapse.tsx"],"mappings":";;UAWU,KAAK,YAAY,MAAM;EAC/B,KAAK;EACL,OAAO,MAAM;EACb;EACA,UAAU,MAAM;;iBAGD,MAAM,YAAY,MAAM,sBAAsB,KAC7D,MAAM;EAGN,QAAQ,KAAK;EACb;EACA,aAAa,MAAM;EACnB;IACE;IACA;IACA;;EAEF,mBAAmB;EACnB,YAAY;EACZ,YAAY,MAAM;;cAGd,WAAY,YAAY,MAAM,gBAAc,YAAA,WAAA,OAAA,WAAA,YAAA,kBAAA,WAAA,YAAA,UAAA,cAAA,SAU/C,MAAM,SAAI,MAAA,IAAA"}
@@ -1,7 +1,7 @@
1
1
  import { MenuProps } from "./menu/menu.mjs";
2
2
  //#region src/components/molecules/dropdown.d.ts
3
3
  type ChangeEventHandler = (open: boolean) => void;
4
- interface Props extends React.ComponentPropsWithoutRef<'div'> {
4
+ export interface Props extends React.ComponentPropsWithoutRef<'div'> {
5
5
  open?: boolean;
6
6
  trigger?: 'hover' | 'click';
7
7
  menu?: MenuProps;
@@ -9,5 +9,5 @@ interface Props extends React.ComponentPropsWithoutRef<'div'> {
9
9
  }
10
10
  declare const Dropdown: ({ children, menu, trigger, open: _open, onOpenChange: _onOpenChange, className, onMouseEnter, onMouseLeave, ...props }: Props) => import("react").JSX.Element;
11
11
  //#endregion
12
- export { Props, Dropdown as default };
12
+ export { Dropdown as default };
13
13
  //# sourceMappingURL=dropdown.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"dropdown.d.mts","names":[],"sources":["../../../src/components/molecules/dropdown.tsx"],"mappings":";;KAYK,sBAAsB;UAEV,cAAc,MAAM;EACnC;EACA;EACA,OAAO;EACP,eAAe;;cAGX,aAAY,UAAA,MAAA,SAAA,MAAA,OAAA,cAAA,eAAA,WAAA,cAAA,iBAAA,SAUf,0BAAK,IAAA"}
1
+ {"version":3,"file":"dropdown.d.mts","names":[],"sources":["../../../src/components/molecules/dropdown.tsx"],"mappings":";;KAYK,sBAAsB;iBAEV,cAAc,MAAM;EACnC;EACA;EACA,OAAO;EACP,eAAe;;cAGX,aAAY,UAAA,MAAA,SAAA,MAAA,OAAA,cAAA,eAAA,WAAA,cAAA,iBAAA,SAUf,0BAAK,IAAA"}
@@ -1,18 +1,26 @@
1
1
  import Alert, { Props } from "../../Alert.mjs";
2
- import Breadcrumb, { Props as Props$1 } from "../../Breadcrumb.mjs";
3
- import Card, { Props as Props$2 } from "../../Card.mjs";
4
- import Menu, { Props as Props$3 } from "./menu/menu.mjs";
5
- import Pagination, { Props as Props$4 } from "../../Pagination.mjs";
6
- import { Props as Props$5 } from "./reveals/reveals.mjs";
2
+ import Anchor, { Item, Props as Props$1 } from "../../Anchor.mjs";
3
+ import Breadcrumb, { Props as Props$2 } from "../../Breadcrumb.mjs";
4
+ import Card, { Props as Props$3 } from "../../Card.mjs";
5
+ import ContextMenu, { Item as Item$1, Props as Props$4 } from "../../ContextMenu.mjs";
6
+ import Descriptions, { Columns, Item as Item$2, Props as Props$5 } from "../../Descriptions.mjs";
7
+ import Menu, { Props as Props$6 } from "./menu/menu.mjs";
8
+ import Pagination, { Props as Props$7 } from "../../Pagination.mjs";
9
+ import Popconfirm, { Props as Props$8 } from "../../Popconfirm.mjs";
10
+ import { Props as Props$9 } from "./reveals/reveals.mjs";
7
11
  import Reveals from "../../Reveals.mjs";
8
- import Space, { Props as Props$6 } from "../../Space.mjs";
9
- import Steps, { Item, Props as Props$7 } from "../../Steps.mjs";
10
- import Collapse, { Props as Props$8 } from "./collapse.mjs";
11
- import Dropdown, { Props as Props$9 } from "./dropdown.mjs";
12
- import { Props as Props$10 } from "./marquees/marquees.mjs";
12
+ import ScrollArea, { Props as Props$10 } from "../../ScrollArea.mjs";
13
+ import Space, { Props as Props$11 } from "../../Space.mjs";
14
+ import Statistic, { Props as Props$12 } from "../../Statistic.mjs";
15
+ import Steps, { Item as Item$3, Props as Props$13 } from "../../Steps.mjs";
16
+ import Timeline, { Item as Item$4, Props as Props$14, Timestamp } from "../../Timeline.mjs";
17
+ import Transfer, { Item as Item$5, Props as Props$15 } from "../../Transfer.mjs";
18
+ import Collapse, { Props as Props$16 } from "./collapse.mjs";
19
+ import Dropdown, { Props as Props$17 } from "./dropdown.mjs";
20
+ import { Props as Props$18 } from "./marquees/marquees.mjs";
13
21
  import Marquees from "./marquees/index.mjs";
14
- import { Props as Props$11 } from "./splitter/splitter.mjs";
22
+ import { Props as Props$19 } from "./splitter/splitter.mjs";
15
23
  import Splitter from "./splitter/index.mjs";
16
- import Tabs, { Props as Props$12 } from "./tabs.mjs";
17
- import Upload, { Props as Props$13, UploadFile } from "./upload.mjs";
18
- export { Alert, type Props as AlertProps, Breadcrumb, type Props$1 as BreadcrumbProps, Card, type Props$2 as CardProps, Collapse, type Props$8 as CollapseProps, Dropdown, type Props$9 as DropdownProps, Marquees, type Props$10 as MarqueesProps, Menu, type Props$3 as MenuProps, Pagination, type Props$4 as PaginationProps, Reveals, type Props$5 as RevealsProps, Space, type Props$6 as SpaceProps, Splitter, type Props$11 as SplitterProps, type Item as StepItem, Steps, type Props$7 as StepsProps, Tabs, type Props$12 as TabsProps, Upload, type UploadFile, type Props$13 as UploadProps };
24
+ import Tabs, { Props as Props$20 } from "./tabs.mjs";
25
+ import Upload, { Props as Props$21, UploadFile } from "./upload.mjs";
26
+ export { Alert, type Props as AlertProps, Anchor, type Item as AnchorItem, type Props$1 as AnchorProps, Breadcrumb, type Props$2 as BreadcrumbProps, Card, type Props$3 as CardProps, Collapse, type Props$16 as CollapseProps, ContextMenu, type Item$1 as ContextMenuItem, type Props$4 as ContextMenuProps, type Item$2 as DescriptionItem, Descriptions, type Columns as DescriptionsColumns, type Props$5 as DescriptionsProps, Dropdown, type Props$17 as DropdownProps, Marquees, type Props$18 as MarqueesProps, Menu, type Props$6 as MenuProps, Pagination, type Props$7 as PaginationProps, Popconfirm, type Props$8 as PopconfirmProps, Reveals, type Props$9 as RevealsProps, ScrollArea, type Props$10 as ScrollAreaProps, Space, type Props$11 as SpaceProps, Splitter, type Props$19 as SplitterProps, Statistic, type Props$12 as StatisticProps, type Item$3 as StepItem, Steps, type Props$13 as StepsProps, Tabs, type Props$20 as TabsProps, Timeline, type Item$4 as TimelineItem, type Props$14 as TimelineProps, type Timestamp as TimelineTimestamp, Transfer, type Item$5 as TransferItem, type Props$15 as TransferProps, Upload, type UploadFile, type Props$21 as UploadProps };
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../../../../src/components/molecules/marquees/index.ts"],"mappings":";;;KAGK,2BAA2B;EAAiB,aAAa;;cAExD,UAA2B"}
1
+ {"version":3,"file":"index.d.mts","names":["MarqueesImpl"],"sources":["../../../../src/components/molecules/marquees/index.ts"],"mappings":";;;KAGK,2BAA2BA;EAAiB,aAAa;;cAExD,UAA2B"}
@@ -1,5 +1,5 @@
1
1
  //#region src/components/molecules/marquees/item.d.ts
2
- interface ItemProps {
2
+ export interface ItemProps {
3
3
  key?: React.Key;
4
4
  speed?: number;
5
5
  autoFill?: boolean | number;
@@ -8,10 +8,10 @@ interface ItemProps {
8
8
  gap?: number;
9
9
  children?: React.ReactNode;
10
10
  }
11
- interface Props extends Omit<React.ComponentPropsWithoutRef<'div'>, 'key'>, ItemProps {
11
+ export interface Props extends Omit<React.ComponentPropsWithoutRef<'div'>, 'key'>, ItemProps {
12
12
  width: string | number;
13
13
  }
14
- declare const Item: ({ width: _width, speed, autoFill, pause: _pause, pauseOnHover, gap, children }: Props) => import("react").JSX.Element;
14
+ declare const Item: ({ width: _width, speed, autoFill, pause, pauseOnHover, gap, children }: Props) => import("react").JSX.Element;
15
15
  //#endregion
16
- export { ItemProps, Props, Item as default };
16
+ export { Item as default };
17
17
  //# sourceMappingURL=item.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"item.d.mts","names":[],"sources":["../../../../src/components/molecules/marquees/item.tsx"],"mappings":";UASiB;EACf,MAAM,MAAM;EACZ;EACA;EACA;EACA;EACA;EACA,WAAW,MAAM;;UAGF,cACP,KAAK,MAAM,yCAAyC;EAC5D;;cAoBI,SAAQ,OAAA,QAAA,OAAA,UAAA,OAAA,QAAA,cAAA,KAAA,YAQX,0BAAK,IAAA"}
1
+ {"version":3,"file":"item.d.mts","names":[],"sources":["../../../../src/components/molecules/marquees/item.tsx"],"mappings":";iBAQiB;EACf,MAAM,MAAM;EACZ;EACA;EACA;EACA;EACA;EACA,WAAW,MAAM;;iBAGF,cACP,KAAK,MAAM,yCAAyC;EAC5D;;cAoBI,SAAQ,OAAA,QAAA,OAAA,UAAA,OAAA,cAAA,KAAA,YAQX,0BAAK,IAAA"}
@@ -1,6 +1,6 @@
1
1
  "use client";
2
- import usePauseOnHover from "./use-pause-on-hover.mjs";
3
2
  import { useEffect, useRef, useState } from "react";
3
+ import { useHoverOrFocusWithin } from "@jbpark/use-hooks";
4
4
  import { jsx, jsxs } from "react/jsx-runtime";
5
5
  import { useGSAP } from "@gsap/react";
6
6
  import { gsap } from "gsap";
@@ -10,12 +10,12 @@ const resolveInitialRepeatCount = (autoFill) => {
10
10
  if (!autoFill) return 0;
11
11
  return typeof autoFill === "boolean" ? INITIAL_AUTO_FILL_GUESS : autoFill;
12
12
  };
13
- const Item = ({ width: _width, speed = 100, autoFill = false, pause: _pause = false, pauseOnHover = false, gap = 0, children }) => {
13
+ const Item = ({ width: _width, speed = 100, autoFill = false, pause = false, pauseOnHover = false, gap = 0, children }) => {
14
14
  const itemRefs = useRef([]);
15
15
  const containerRef = useRef(null);
16
16
  const tweenRef = useRef(null);
17
17
  const [width, setWidth] = useState(_width);
18
- const { pause, hoverEvents } = usePauseOnHover(pauseOnHover);
18
+ const { active: isHoverOrFocusPaused, handlers } = useHoverOrFocusWithin({ enabled: pauseOnHover });
19
19
  const [repeatCount, setRepeatCount] = useState(resolveInitialRepeatCount(autoFill));
20
20
  const [prevWidthProp, setPrevWidthProp] = useState(_width);
21
21
  const [prevAutoFill, setPrevAutoFill] = useState(autoFill);
@@ -33,7 +33,7 @@ const Item = ({ width: _width, speed = 100, autoFill = false, pause: _pause = fa
33
33
  setWidth(_width);
34
34
  setRepeatCount(resolveInitialRepeatCount(autoFill));
35
35
  }
36
- const isPaused = _pause || pause;
36
+ const isPaused = pause || isHoverOrFocusPaused;
37
37
  useEffect(() => {
38
38
  if (!autoFill || !children || !itemRefs.current[0] || typeof width === "string") return;
39
39
  const itemWidth = itemRefs.current[0].offsetWidth;
@@ -79,7 +79,7 @@ const Item = ({ width: _width, speed = 100, autoFill = false, pause: _pause = fa
79
79
  }, [isPaused]);
80
80
  return /* @__PURE__ */ jsx("div", {
81
81
  className: "flex overflow-hidden",
82
- ...hoverEvents,
82
+ ...handlers,
83
83
  children: /* @__PURE__ */ jsx("div", {
84
84
  ref: containerRef,
85
85
  className: "flex flex-nowrap",
@@ -1 +1 @@
1
- {"version":3,"file":"item.mjs","names":[],"sources":["../../../../src/components/molecules/marquees/item.tsx"],"sourcesContent":["'use client';\n\nimport { useEffect, useRef, useState } from 'react';\n\nimport { useGSAP } from '@gsap/react';\nimport { gsap } from 'gsap';\n\nimport usePauseOnHover from './use-pause-on-hover';\n\nexport interface ItemProps {\n key?: React.Key;\n speed?: number;\n autoFill?: boolean | number;\n pause?: boolean;\n pauseOnHover?: boolean;\n gap?: number;\n children?: React.ReactNode;\n}\n\nexport interface Props\n extends Omit<React.ComponentPropsWithoutRef<'div'>, 'key'>, ItemProps {\n width: string | number;\n}\n\n// `autoFill={true}` (the default on `Marquees`) needs *some* repeat count\n// before the item can be measured and the real count computed — this is\n// only ever visible for that one render, but rendering 100 copies (200\n// with the 2x loop duplication) up front was needlessly heavy for the\n// common case. A modest guess still avoids visible gaps for typical\n// item/container width ratios while cutting the worst-case default\n// render by ~90%.\nconst INITIAL_AUTO_FILL_GUESS = 10;\n\nconst resolveInitialRepeatCount = (autoFill: boolean | number) => {\n if (!autoFill) {\n return 0;\n }\n\n return typeof autoFill === 'boolean' ? INITIAL_AUTO_FILL_GUESS : autoFill;\n};\n\nconst Item = ({\n width: _width,\n speed = 100,\n autoFill = false,\n pause: _pause = false,\n pauseOnHover = false,\n gap = 0,\n children,\n}: Props) => {\n const itemRefs = useRef<HTMLDivElement[]>([]);\n const containerRef = useRef<HTMLDivElement>(null);\n const tweenRef = useRef<gsap.core.Tween | null>(null);\n\n const [width, setWidth] = useState<string | number>(_width);\n const { pause, hoverEvents } = usePauseOnHover(pauseOnHover);\n const [repeatCount, setRepeatCount] = useState(\n resolveInitialRepeatCount(autoFill),\n );\n const [prevWidthProp, setPrevWidthProp] = useState(_width);\n const [prevAutoFill, setPrevAutoFill] = useState(autoFill);\n const [prevGap, setPrevGap] = useState(gap);\n\n // Adjusted directly in render (React's \"adjust state during render\"\n // pattern) instead of an effect, so `width`/`repeatCount` re-sync with\n // the prop in the same render it changes rather than the render after.\n if (_width !== prevWidthProp) {\n setPrevWidthProp(_width);\n setWidth(_width);\n }\n\n if (autoFill !== prevAutoFill) {\n setPrevAutoFill(autoFill);\n setRepeatCount(resolveInitialRepeatCount(autoFill));\n }\n\n // `gap` widens every copy, so both the measured item width and the repeat\n // count derived from it are stale. Rewind `width` to the container width\n // so the measuring effect below recomputes the loop distance from scratch.\n if (gap !== prevGap) {\n setPrevGap(gap);\n setWidth(_width);\n setRepeatCount(resolveInitialRepeatCount(autoFill));\n }\n\n const isPaused = _pause || pause;\n\n useEffect(() => {\n if (\n !autoFill ||\n !children ||\n !itemRefs.current[0] ||\n typeof width === 'string'\n ) {\n return;\n }\n\n // `offsetWidth` is the border-box width, so it already includes the\n // `gap` padding each copy carries — the loop distance stays exact\n // without adding `gap` back in here.\n const itemWidth = itemRefs.current[0].offsetWidth;\n\n if (itemWidth >= width) {\n setWidth(itemWidth);\n setRepeatCount(0);\n return;\n }\n\n let totalWidth = 0;\n let repeatCount = 0;\n\n while (totalWidth < width) {\n totalWidth += itemWidth;\n repeatCount += 1;\n }\n\n setWidth(totalWidth);\n setRepeatCount(repeatCount - 1);\n }, [autoFill, width, children, gap]);\n\n useGSAP(\n () => {\n if (!containerRef.current || typeof width === 'string') {\n return;\n }\n\n if (tweenRef.current) {\n tweenRef.current.kill();\n }\n\n tweenRef.current = gsap.fromTo(\n containerRef.current,\n { x: 0 },\n {\n x: -width,\n duration: width / speed,\n repeat: -1,\n ease: 'linear',\n },\n );\n\n return () => {\n tweenRef.current?.kill();\n };\n },\n {\n scope: containerRef,\n dependencies: [width, speed],\n },\n );\n\n useEffect(() => {\n if (!tweenRef.current) {\n return;\n }\n\n if (isPaused) {\n tweenRef.current.pause();\n } else {\n tweenRef.current.play();\n }\n }, [isPaused]);\n\n return (\n <div\n className=\"flex overflow-hidden\"\n {...hoverEvents}\n //\n >\n <div ref={containerRef} className=\"flex flex-nowrap\">\n {[...Array(2)].map((_, index) => (\n <div\n key={index}\n style={{ minWidth: width }}\n className=\"flex flex-nowrap\"\n >\n {/* Every copy carries the same trailing `gap`, so the spacing is\n uniform at the seam between copies and between the two loop\n halves — no special-casing at either boundary. */}\n <div\n ref={el => {\n if (el) {\n itemRefs.current[index] = el;\n }\n }}\n style={{ paddingRight: gap }}\n >\n {children}\n </div>\n {[\n ...Array(typeof autoFill === 'number' ? autoFill : repeatCount),\n ].map((_, i) => (\n <div key={i} style={{ paddingRight: gap }}>\n {children}\n </div>\n ))}\n </div>\n ))}\n </div>\n </div>\n );\n};\n\nexport default Item;\n"],"mappings":"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"}
1
+ {"version":3,"file":"item.mjs","names":[],"sources":["../../../../src/components/molecules/marquees/item.tsx"],"sourcesContent":["'use client';\n\nimport { useEffect, useRef, useState } from 'react';\n\nimport { useGSAP } from '@gsap/react';\nimport { useHoverOrFocusWithin } from '@jbpark/use-hooks';\nimport { gsap } from 'gsap';\n\nexport interface ItemProps {\n key?: React.Key;\n speed?: number;\n autoFill?: boolean | number;\n pause?: boolean;\n pauseOnHover?: boolean;\n gap?: number;\n children?: React.ReactNode;\n}\n\nexport interface Props\n extends Omit<React.ComponentPropsWithoutRef<'div'>, 'key'>, ItemProps {\n width: string | number;\n}\n\n// `autoFill={true}` (the default on `Marquees`) needs *some* repeat count\n// before the item can be measured and the real count computed — this is\n// only ever visible for that one render, but rendering 100 copies (200\n// with the 2x loop duplication) up front was needlessly heavy for the\n// common case. A modest guess still avoids visible gaps for typical\n// item/container width ratios while cutting the worst-case default\n// render by ~90%.\nconst INITIAL_AUTO_FILL_GUESS = 10;\n\nconst resolveInitialRepeatCount = (autoFill: boolean | number) => {\n if (!autoFill) {\n return 0;\n }\n\n return typeof autoFill === 'boolean' ? INITIAL_AUTO_FILL_GUESS : autoFill;\n};\n\nconst Item = ({\n width: _width,\n speed = 100,\n autoFill = false,\n pause = false,\n pauseOnHover = false,\n gap = 0,\n children,\n}: Props) => {\n const itemRefs = useRef<HTMLDivElement[]>([]);\n const containerRef = useRef<HTMLDivElement>(null);\n const tweenRef = useRef<gsap.core.Tween | null>(null);\n\n const [width, setWidth] = useState<string | number>(_width);\n const { active: isHoverOrFocusPaused, handlers } = useHoverOrFocusWithin({\n enabled: pauseOnHover,\n });\n const [repeatCount, setRepeatCount] = useState(\n resolveInitialRepeatCount(autoFill),\n );\n const [prevWidthProp, setPrevWidthProp] = useState(_width);\n const [prevAutoFill, setPrevAutoFill] = useState(autoFill);\n const [prevGap, setPrevGap] = useState(gap);\n\n // Adjusted directly in render (React's \"adjust state during render\"\n // pattern) instead of an effect, so `width`/`repeatCount` re-sync with\n // the prop in the same render it changes rather than the render after.\n if (_width !== prevWidthProp) {\n setPrevWidthProp(_width);\n setWidth(_width);\n }\n\n if (autoFill !== prevAutoFill) {\n setPrevAutoFill(autoFill);\n setRepeatCount(resolveInitialRepeatCount(autoFill));\n }\n\n // `gap` widens every copy, so both the measured item width and the repeat\n // count derived from it are stale. Rewind `width` to the container width\n // so the measuring effect below recomputes the loop distance from scratch.\n if (gap !== prevGap) {\n setPrevGap(gap);\n setWidth(_width);\n setRepeatCount(resolveInitialRepeatCount(autoFill));\n }\n\n const isPaused = pause || isHoverOrFocusPaused;\n\n useEffect(() => {\n if (\n !autoFill ||\n !children ||\n !itemRefs.current[0] ||\n typeof width === 'string'\n ) {\n return;\n }\n\n // `offsetWidth` is the border-box width, so it already includes the\n // `gap` padding each copy carries — the loop distance stays exact\n // without adding `gap` back in here.\n const itemWidth = itemRefs.current[0].offsetWidth;\n\n if (itemWidth >= width) {\n setWidth(itemWidth);\n setRepeatCount(0);\n return;\n }\n\n let totalWidth = 0;\n let repeatCount = 0;\n\n while (totalWidth < width) {\n totalWidth += itemWidth;\n repeatCount += 1;\n }\n\n setWidth(totalWidth);\n setRepeatCount(repeatCount - 1);\n }, [autoFill, width, children, gap]);\n\n useGSAP(\n () => {\n if (!containerRef.current || typeof width === 'string') {\n return;\n }\n\n if (tweenRef.current) {\n tweenRef.current.kill();\n }\n\n tweenRef.current = gsap.fromTo(\n containerRef.current,\n { x: 0 },\n {\n x: -width,\n duration: width / speed,\n repeat: -1,\n ease: 'linear',\n },\n );\n\n return () => {\n tweenRef.current?.kill();\n };\n },\n {\n scope: containerRef,\n dependencies: [width, speed],\n },\n );\n\n useEffect(() => {\n if (!tweenRef.current) {\n return;\n }\n\n if (isPaused) {\n tweenRef.current.pause();\n } else {\n tweenRef.current.play();\n }\n }, [isPaused]);\n\n return (\n <div\n className=\"flex overflow-hidden\"\n {...handlers}\n //\n >\n <div ref={containerRef} className=\"flex flex-nowrap\">\n {[...Array(2)].map((_, index) => (\n <div\n key={index}\n style={{ minWidth: width }}\n className=\"flex flex-nowrap\"\n >\n {/* Every copy carries the same trailing `gap`, so the spacing is\n uniform at the seam between copies and between the two loop\n halves — no special-casing at either boundary. */}\n <div\n ref={el => {\n if (el) {\n itemRefs.current[index] = el;\n }\n }}\n style={{ paddingRight: gap }}\n >\n {children}\n </div>\n {[\n ...Array(typeof autoFill === 'number' ? autoFill : repeatCount),\n ].map((_, i) => (\n <div key={i} style={{ paddingRight: gap }}>\n {children}\n </div>\n ))}\n </div>\n ))}\n </div>\n </div>\n );\n};\n\nexport default Item;\n"],"mappings":"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"}
@@ -1,6 +1,6 @@
1
1
  import { ItemProps } from "./item.mjs";
2
2
  //#region src/components/molecules/marquees/marquees.d.ts
3
- interface Props extends React.ComponentPropsWithoutRef<'div'> {
3
+ export interface Props extends React.ComponentPropsWithoutRef<'div'> {
4
4
  speed?: number;
5
5
  autoFill?: boolean | number;
6
6
  pauseOnHover?: boolean;
@@ -9,5 +9,5 @@ interface Props extends React.ComponentPropsWithoutRef<'div'> {
9
9
  }
10
10
  declare const Marquees: ({ className, items, speed, pauseOnHover, autoFill, gap, ...props }: Props) => import("react").JSX.Element;
11
11
  //#endregion
12
- export { Props, Marquees as default };
12
+ export { Marquees as default };
13
13
  //# sourceMappingURL=marquees.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"marquees.d.mts","names":[],"sources":["../../../../src/components/molecules/marquees/marquees.tsx"],"mappings":";;UAeiB,cAAc,MAAM;EACnC;EACA;EACA;EACA;EACA,QAAQ;;cAGJ,aAAY,WAAA,OAAA,OAAA,cAAA,UAAA,QAAA,SAQf,0BAAK,IAAA"}
1
+ {"version":3,"file":"marquees.d.mts","names":[],"sources":["../../../../src/components/molecules/marquees/marquees.tsx"],"mappings":";;iBAeiB,cAAc,MAAM;EACnC;EACA;EACA;EACA;EACA,QAAQ;;cAGJ,aAAY,WAAA,OAAA,OAAA,cAAA,UAAA,QAAA,SAQf,0BAAK,IAAA"}
@@ -1,15 +1,14 @@
1
1
  "use client";
2
2
  import { cn } from "../../../utils.mjs";
3
- import usePauseOnHover from "./use-pause-on-hover.mjs";
4
3
  import Item from "./item.mjs";
5
4
  import { useEffect, useRef, useState } from "react";
6
- import { useMergedRef, useResponsiveSize, useThrottledValue } from "@jbpark/use-hooks";
5
+ import { useHoverOrFocusWithin, useMergedRef, useResponsiveSize, useThrottledValue } from "@jbpark/use-hooks";
7
6
  import { jsx } from "react/jsx-runtime";
8
7
  //#region src/components/molecules/marquees/marquees.tsx
9
8
  const Marquees = ({ className, items, speed, pauseOnHover = true, autoFill = true, gap, ...props }) => {
10
9
  const [width, setWidth] = useState("100%");
11
10
  const [padding, setPadding] = useState(0);
12
- const { pause, hoverEvents } = usePauseOnHover(pauseOnHover);
11
+ const { active: isPaused, handlers } = useHoverOrFocusWithin({ enabled: pauseOnHover });
13
12
  const throttledWidth = useThrottledValue(width, 200);
14
13
  const { size, ref: responsiveRef } = useResponsiveSize();
15
14
  const containerRef = useRef(null);
@@ -25,14 +24,14 @@ const Marquees = ({ className, items, speed, pauseOnHover = true, autoFill = tru
25
24
  return /* @__PURE__ */ jsx("div", {
26
25
  ref: setContainerRef,
27
26
  className: cn(className),
28
- ...hoverEvents,
27
+ ...handlers,
29
28
  ...props,
30
29
  children: /* @__PURE__ */ jsx("div", {
31
30
  className: cn("flex flex-col gap-y-5", "overflow-hidden", "whitespace-nowrap", "bg-inherit"),
32
31
  style: { width: typeof throttledWidth === "number" ? throttledWidth - padding : throttledWidth },
33
32
  children: items?.map(({ children, key: itemKey, ...item }, key) => /* @__PURE__ */ jsx(Item, {
34
33
  width: throttledWidth,
35
- pause,
34
+ pause: isPaused,
36
35
  speed,
37
36
  autoFill,
38
37
  gap,
@@ -1 +1 @@
1
- {"version":3,"file":"marquees.mjs","names":[],"sources":["../../../../src/components/molecules/marquees/marquees.tsx"],"sourcesContent":["'use client';\n\nimport { useEffect, useRef, useState } from 'react';\n\nimport {\n useMergedRef,\n useResponsiveSize,\n useThrottledValue,\n} from '@jbpark/use-hooks';\n\nimport { cn } from '@repo/ui/utils';\n\nimport Item, { type ItemProps } from './item';\nimport usePauseOnHover from './use-pause-on-hover';\n\nexport interface Props extends React.ComponentPropsWithoutRef<'div'> {\n speed?: number;\n autoFill?: boolean | number;\n pauseOnHover?: boolean;\n gap?: number;\n items?: ItemProps[];\n}\n\nconst Marquees = ({\n className,\n items,\n speed,\n pauseOnHover = true,\n autoFill = true,\n gap,\n ...props\n}: Props) => {\n // The container's own width, not the viewport's. `useResponsiveSize`\n // measures in a layout effect, but this component copies the result into\n // state in a passive effect and then throttles it, so the seed is what\n // paints for the first ~200ms. `100vw` overflowed every padded or columned\n // layout for that window — on the docs page it drew the track 1280px wide\n // inside a 703px column, briefly showing the whole track and giving the\n // page a horizontal scrollbar. `100%` resolves to the same value the\n // measurement lands on, so there is nothing left to snap.\n const [width, setWidth] = useState<string | number>(\n '100%',\n //\n );\n const [padding, setPadding] = useState(0);\n const { pause, hoverEvents } = usePauseOnHover(pauseOnHover);\n\n const throttledWidth = useThrottledValue(width, 200);\n\n const { size, ref: responsiveRef } = useResponsiveSize<HTMLDivElement>();\n const containerRef = useRef<HTMLDivElement | null>(null);\n const setContainerRef = useMergedRef(containerRef, responsiveRef);\n\n useEffect(() => {\n if (!size.width || !containerRef.current) {\n return;\n }\n\n const computedStyle = getComputedStyle(containerRef.current);\n const paddingLeft = parseFloat(computedStyle.paddingLeft) || 0;\n const paddingRight = parseFloat(computedStyle.paddingRight) || 0;\n\n setPadding(paddingLeft + paddingRight);\n\n setWidth(size.width);\n }, [size]);\n\n return (\n <div\n ref={setContainerRef}\n className={cn(\n className,\n //\n )}\n {...hoverEvents}\n {...props}\n >\n <div\n className={cn(\n 'flex flex-col gap-y-5',\n 'overflow-hidden',\n 'whitespace-nowrap',\n 'bg-inherit',\n //\n )}\n style={{\n width:\n typeof throttledWidth === 'number'\n ? throttledWidth - padding\n : throttledWidth,\n }}\n >\n {items?.map(({ children, key: itemKey, ...item }: ItemProps, key) => (\n <Item\n key={itemKey || key}\n width={throttledWidth}\n pause={pause}\n speed={speed}\n autoFill={autoFill}\n gap={gap}\n {...item}\n >\n {children}\n </Item>\n ))}\n </div>\n </div>\n );\n};\n\nexport default Marquees;\n"],"mappings":";;;;;;;;AAuBA,MAAM,YAAY,EAChB,WACA,OACA,OACA,eAAe,MACf,WAAW,MACX,KACA,GAAG,YACQ;CASX,MAAM,CAAC,OAAO,YAAY,SACxB,MAEF;CACA,MAAM,CAAC,SAAS,cAAc,SAAS,CAAC;CACxC,MAAM,EAAE,OAAO,gBAAgB,gBAAgB,YAAY;CAE3D,MAAM,iBAAiB,kBAAkB,OAAO,GAAG;CAEnD,MAAM,EAAE,MAAM,KAAK,kBAAkB,kBAAkC;CACvE,MAAM,eAAe,OAA8B,IAAI;CACvD,MAAM,kBAAkB,aAAa,cAAc,aAAa;CAEhE,gBAAgB;EACd,IAAI,CAAC,KAAK,SAAS,CAAC,aAAa,SAC/B;EAGF,MAAM,gBAAgB,iBAAiB,aAAa,OAAO;EAC3D,MAAM,cAAc,WAAW,cAAc,WAAW,KAAK;EAC7D,MAAM,eAAe,WAAW,cAAc,YAAY,KAAK;EAE/D,WAAW,cAAc,YAAY;EAErC,SAAS,KAAK,KAAK;CACrB,GAAG,CAAC,IAAI,CAAC;CAET,OACE,oBAAC,OAAD;EACE,KAAK;EACL,WAAW,GACT,SAEF;EACA,GAAI;EACJ,GAAI;EAEJ,UAAA,oBAAC,OAAD;GACE,WAAW,GACT,yBACA,mBACA,qBACA,YAEF;GACA,OAAO,EACL,OACE,OAAO,mBAAmB,WACtB,iBAAiB,UACjB,eACR;GAEC,UAAA,OAAO,KAAK,EAAE,UAAU,KAAK,SAAS,GAAG,QAAmB,QAC3D,oBAAC,MAAD;IAEE,OAAO;IACA;IACA;IACG;IACL;IACL,GAAI;IAEH;GACG,GATC,WAAW,GASZ,CACP;EACE,CAAA;CACF,CAAA;AAET"}
1
+ {"version":3,"file":"marquees.mjs","names":[],"sources":["../../../../src/components/molecules/marquees/marquees.tsx"],"sourcesContent":["'use client';\n\nimport { useEffect, useRef, useState } from 'react';\n\nimport {\n useHoverOrFocusWithin,\n useMergedRef,\n useResponsiveSize,\n useThrottledValue,\n} from '@jbpark/use-hooks';\n\nimport { cn } from '@repo/ui/utils';\n\nimport Item, { type ItemProps } from './item';\n\nexport interface Props extends React.ComponentPropsWithoutRef<'div'> {\n speed?: number;\n autoFill?: boolean | number;\n pauseOnHover?: boolean;\n gap?: number;\n items?: ItemProps[];\n}\n\nconst Marquees = ({\n className,\n items,\n speed,\n pauseOnHover = true,\n autoFill = true,\n gap,\n ...props\n}: Props) => {\n // The container's own width, not the viewport's. `useResponsiveSize`\n // measures in a layout effect, but this component copies the result into\n // state in a passive effect and then throttles it, so the seed is what\n // paints for the first ~200ms. `100vw` overflowed every padded or columned\n // layout for that window — on the docs page it drew the track 1280px wide\n // inside a 703px column, briefly showing the whole track and giving the\n // page a horizontal scrollbar. `100%` resolves to the same value the\n // measurement lands on, so there is nothing left to snap.\n const [width, setWidth] = useState<string | number>(\n '100%',\n //\n );\n const [padding, setPadding] = useState(0);\n const { active: isPaused, handlers } = useHoverOrFocusWithin({\n enabled: pauseOnHover,\n });\n\n const throttledWidth = useThrottledValue(width, 200);\n\n const { size, ref: responsiveRef } = useResponsiveSize<HTMLDivElement>();\n const containerRef = useRef<HTMLDivElement | null>(null);\n const setContainerRef = useMergedRef(containerRef, responsiveRef);\n\n useEffect(() => {\n if (!size.width || !containerRef.current) {\n return;\n }\n\n const computedStyle = getComputedStyle(containerRef.current);\n const paddingLeft = parseFloat(computedStyle.paddingLeft) || 0;\n const paddingRight = parseFloat(computedStyle.paddingRight) || 0;\n\n setPadding(paddingLeft + paddingRight);\n\n setWidth(size.width);\n }, [size]);\n\n return (\n <div\n ref={setContainerRef}\n className={cn(\n className,\n //\n )}\n {...handlers}\n {...props}\n >\n <div\n className={cn(\n 'flex flex-col gap-y-5',\n 'overflow-hidden',\n 'whitespace-nowrap',\n 'bg-inherit',\n //\n )}\n style={{\n width:\n typeof throttledWidth === 'number'\n ? throttledWidth - padding\n : throttledWidth,\n }}\n >\n {items?.map(({ children, key: itemKey, ...item }: ItemProps, key) => (\n <Item\n key={itemKey || key}\n width={throttledWidth}\n pause={isPaused}\n speed={speed}\n autoFill={autoFill}\n gap={gap}\n {...item}\n >\n {children}\n </Item>\n ))}\n </div>\n </div>\n );\n};\n\nexport default Marquees;\n"],"mappings":";;;;;;;AAuBA,MAAM,YAAY,EAChB,WACA,OACA,OACA,eAAe,MACf,WAAW,MACX,KACA,GAAG,YACQ;CASX,MAAM,CAAC,OAAO,YAAY,SACxB,MAEF;CACA,MAAM,CAAC,SAAS,cAAc,SAAS,CAAC;CACxC,MAAM,EAAE,QAAQ,UAAU,aAAa,sBAAsB,EAC3D,SAAS,aACX,CAAC;CAED,MAAM,iBAAiB,kBAAkB,OAAO,GAAG;CAEnD,MAAM,EAAE,MAAM,KAAK,kBAAkB,kBAAkC;CACvE,MAAM,eAAe,OAA8B,IAAI;CACvD,MAAM,kBAAkB,aAAa,cAAc,aAAa;CAEhE,gBAAgB;EACd,IAAI,CAAC,KAAK,SAAS,CAAC,aAAa,SAC/B;EAGF,MAAM,gBAAgB,iBAAiB,aAAa,OAAO;EAC3D,MAAM,cAAc,WAAW,cAAc,WAAW,KAAK;EAC7D,MAAM,eAAe,WAAW,cAAc,YAAY,KAAK;EAE/D,WAAW,cAAc,YAAY;EAErC,SAAS,KAAK,KAAK;CACrB,GAAG,CAAC,IAAI,CAAC;CAET,OACE,oBAAC,OAAD;EACE,KAAK;EACL,WAAW,GACT,SAEF;EACA,GAAI;EACJ,GAAI;EAEJ,UAAA,oBAAC,OAAD;GACE,WAAW,GACT,yBACA,mBACA,qBACA,YAEF;GACA,OAAO,EACL,OACE,OAAO,mBAAmB,WACtB,iBAAiB,UACjB,eACR;GAEC,UAAA,OAAO,KAAK,EAAE,UAAU,KAAK,SAAS,GAAG,QAAmB,QAC3D,oBAAC,MAAD;IAEE,OAAO;IACP,OAAO;IACA;IACG;IACL;IACL,GAAI;IAEH;GACG,GATC,WAAW,GASZ,CACP;EACE,CAAA;CACF,CAAA;AAET"}
@@ -2,9 +2,9 @@
2
2
  import { cn } from "../../../../utils.mjs";
3
3
  import Label from "./label.mjs";
4
4
  import { MENU_CLASSNAMES } from "../menu.mjs";
5
- import { ChevronDown } from "lucide-react";
6
5
  import { createElement, useRef, useState } from "react";
7
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
+ import { ChevronDown } from "lucide-react";
8
8
  import { AnimatePresence, motion } from "motion/react";
9
9
  //#region src/components/molecules/menu/item/item.tsx
10
10
  const OFFSET = [8, 8];