@oneplatformdev/ui 0.0.1-beta.98 → 0.1.2-1

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 (444) hide show
  1. package/README.md +4 -30
  2. package/package.json +35 -92
  3. package/src/globals.css +123 -0
  4. package/Accordion/Accordion.d.ts +0 -9
  5. package/Accordion/Accordion.mjs +0 -49
  6. package/Accordion/index.d.ts +0 -1
  7. package/Accordion/index.mjs +0 -7
  8. package/Accordion/package.json +0 -7
  9. package/Alert/Alert.d.ts +0 -7
  10. package/Alert/Alert.mjs +0 -37
  11. package/Alert/alertVariants.d.ts +0 -4
  12. package/Alert/alertVariants.mjs +0 -19
  13. package/Alert/index.d.ts +0 -1
  14. package/Alert/index.mjs +0 -6
  15. package/Alert/package.json +0 -7
  16. package/AlertDialog/AlertDialog.d.ts +0 -65
  17. package/AlertDialog/AlertDialog.mjs +0 -97
  18. package/AlertDialog/AlertDialog.types.d.ts +0 -53
  19. package/AlertDialog/AlertDialogRoot.d.ts +0 -21
  20. package/AlertDialog/AlertDialogRoot.mjs +0 -114
  21. package/AlertDialog/index.d.ts +0 -3
  22. package/AlertDialog/index.mjs +0 -16
  23. package/AlertDialog/package.json +0 -7
  24. package/AreaChart/AreaChart.d.ts +0 -4
  25. package/AreaChart/AreaChart.mjs +0 -27
  26. package/AreaChart/AreaChart.types.d.ts +0 -15
  27. package/AreaChart/index.d.ts +0 -2
  28. package/AreaChart/index.mjs +0 -4
  29. package/AreaChart/package.json +0 -7
  30. package/Aside/Aside.d.ts +0 -4
  31. package/Aside/Aside.mjs +0 -23
  32. package/Aside/Aside.types.d.ts +0 -18
  33. package/Aside/AsideSidebar.d.ts +0 -3
  34. package/Aside/AsideSidebar.mjs +0 -37
  35. package/Aside/index.d.ts +0 -3
  36. package/Aside/index.mjs +0 -7
  37. package/Aside/package.json +0 -7
  38. package/AspectRatio/AspectRatio.d.ts +0 -2
  39. package/AspectRatio/AspectRatio.mjs +0 -5
  40. package/AspectRatio/index.d.ts +0 -1
  41. package/AspectRatio/index.mjs +0 -5
  42. package/AspectRatio/package.json +0 -7
  43. package/Avatar/Avatar.d.ts +0 -5
  44. package/Avatar/Avatar.mjs +0 -42
  45. package/Avatar/index.d.ts +0 -1
  46. package/Avatar/index.mjs +0 -6
  47. package/Avatar/package.json +0 -7
  48. package/Badge/Badge.d.ts +0 -5
  49. package/Badge/Badge.mjs +0 -10
  50. package/Badge/Badge.types.d.ts +0 -5
  51. package/Badge/badgeVariants.d.ts +0 -3
  52. package/Badge/badgeVariants.mjs +0 -20
  53. package/Badge/index.d.ts +0 -3
  54. package/Badge/index.mjs +0 -6
  55. package/Badge/package.json +0 -7
  56. package/Breadcrumb/Breadcrumb.d.ts +0 -19
  57. package/Breadcrumb/Breadcrumb.mjs +0 -90
  58. package/Breadcrumb/index.d.ts +0 -1
  59. package/Breadcrumb/index.mjs +0 -10
  60. package/Breadcrumb/package.json +0 -7
  61. package/Button/Button.d.ts +0 -4
  62. package/Button/Button.mjs +0 -32
  63. package/Button/Button.types.d.ts +0 -8
  64. package/Button/buttonVariants.d.ts +0 -4
  65. package/Button/buttonVariants.mjs +0 -29
  66. package/Button/index.d.ts +0 -3
  67. package/Button/index.mjs +0 -7
  68. package/Button/package.json +0 -7
  69. package/ButtonIcon/ButtonIcon.d.ts +0 -3
  70. package/ButtonIcon/ButtonIcon.mjs +0 -29
  71. package/ButtonIcon/ButtonIcon.types.d.ts +0 -7
  72. package/ButtonIcon/buttonIconVariants.d.ts +0 -7
  73. package/ButtonIcon/buttonIconVariants.mjs +0 -139
  74. package/ButtonIcon/index.d.ts +0 -3
  75. package/ButtonIcon/index.mjs +0 -7
  76. package/ButtonIcon/package.json +0 -7
  77. package/Calendar/Calendar.d.ts +0 -8
  78. package/Calendar/Calendar.mjs +0 -64
  79. package/Calendar/index.d.ts +0 -1
  80. package/Calendar/index.mjs +0 -4
  81. package/Calendar/package.json +0 -7
  82. package/Card/Card.d.ts +0 -8
  83. package/Card/Card.mjs +0 -61
  84. package/Card/index.d.ts +0 -1
  85. package/Card/index.mjs +0 -9
  86. package/Card/package.json +0 -7
  87. package/Carousel/Carousel.d.ts +0 -18
  88. package/Carousel/Carousel.mjs +0 -168
  89. package/Carousel/index.d.ts +0 -1
  90. package/Carousel/index.mjs +0 -8
  91. package/Carousel/package.json +0 -7
  92. package/Chart/Chart.d.ts +0 -62
  93. package/Chart/Chart.mjs +0 -210
  94. package/Chart/index.d.ts +0 -1
  95. package/Chart/index.mjs +0 -9
  96. package/Chart/package.json +0 -7
  97. package/Checkbox/Checkbox.d.ts +0 -5
  98. package/Checkbox/Checkbox.mjs +0 -54
  99. package/Checkbox/Checkbox.types.d.ts +0 -10
  100. package/Checkbox/index.d.ts +0 -2
  101. package/Checkbox/index.mjs +0 -5
  102. package/Checkbox/package.json +0 -7
  103. package/Collapsible/Collapsible.d.ts +0 -5
  104. package/Collapsible/Collapsible.mjs +0 -7
  105. package/Collapsible/index.d.ts +0 -1
  106. package/Collapsible/index.mjs +0 -6
  107. package/Collapsible/package.json +0 -7
  108. package/Combobox/Combobox.d.ts +0 -4
  109. package/Combobox/Combobox.mjs +0 -15
  110. package/Combobox/Combobox.types.d.ts +0 -38
  111. package/Combobox/ComboboxOptionItem.d.ts +0 -5
  112. package/Combobox/ComboboxOptionItem.mjs +0 -67
  113. package/Combobox/ComboboxOptions.d.ts +0 -4
  114. package/Combobox/ComboboxOptions.mjs +0 -12
  115. package/Combobox/index.d.ts +0 -2
  116. package/Combobox/index.mjs +0 -4
  117. package/Combobox/package.json +0 -7
  118. package/Combobox-B0sHDL7X.js +0 -301
  119. package/Command/Command.d.ts +0 -80
  120. package/Command/Command.mjs +0 -116
  121. package/Command/index.d.ts +0 -1
  122. package/Command/index.mjs +0 -12
  123. package/Command/package.json +0 -7
  124. package/DataTable/DataTable.d.ts +0 -11
  125. package/DataTable/DataTable.mjs +0 -64
  126. package/DataTable/DataTable.types.d.ts +0 -11
  127. package/DataTable/DataTableColumnFilter.d.ts +0 -4
  128. package/DataTable/DataTableColumnFilter.mjs +0 -31
  129. package/DataTable/index.d.ts +0 -2
  130. package/DataTable/index.mjs +0 -4
  131. package/DataTable/package.json +0 -7
  132. package/DataTable/useDataTable.d.ts +0 -3
  133. package/DataTable/useDataTable.mjs +0 -30
  134. package/DatePicker/DatePicker.d.ts +0 -3
  135. package/DatePicker/DatePicker.mjs +0 -699
  136. package/DatePicker/DatePicker.types.d.ts +0 -5
  137. package/DatePicker/index.d.ts +0 -3
  138. package/DatePicker/index.mjs +0 -5
  139. package/DatePicker/package.json +0 -7
  140. package/Dialog/Dialog.d.ts +0 -21
  141. package/Dialog/Dialog.mjs +0 -117
  142. package/Dialog/index.d.ts +0 -1
  143. package/Dialog/index.mjs +0 -13
  144. package/Dialog/package.json +0 -7
  145. package/Drawer/Drawer.d.ts +0 -22
  146. package/Drawer/Drawer.mjs +0 -98
  147. package/Drawer/index.d.ts +0 -1
  148. package/Drawer/index.mjs +0 -13
  149. package/Drawer/package.json +0 -7
  150. package/DropdownMenu/DropdownMenu.d.ts +0 -27
  151. package/DropdownMenu/DropdownMenu.mjs +0 -148
  152. package/DropdownMenu/index.d.ts +0 -1
  153. package/DropdownMenu/index.mjs +0 -18
  154. package/DropdownMenu/package.json +0 -7
  155. package/Dropzone/Dropzone.d.ts +0 -22
  156. package/Dropzone/Dropzone.mjs +0 -152
  157. package/Dropzone/Dropzone.types.d.ts +0 -42
  158. package/Dropzone/DropzoneFilePreview.d.ts +0 -4
  159. package/Dropzone/DropzoneFilePreview.mjs +0 -9
  160. package/Dropzone/DropzoneSinglePickPreview.d.ts +0 -10
  161. package/Dropzone/DropzoneSinglePickPreview.mjs +0 -41
  162. package/Dropzone/DropzoneUtils.d.ts +0 -5
  163. package/Dropzone/DropzoneUtils.mjs +0 -24
  164. package/Dropzone/index.d.ts +0 -2
  165. package/Dropzone/index.mjs +0 -7
  166. package/Dropzone/package.json +0 -7
  167. package/DropzoneFilePreview-Dhtv8F4u.js +0 -67
  168. package/Form/Form.d.ts +0 -23
  169. package/Form/Form.mjs +0 -98
  170. package/Form/FormRenderControl.d.ts +0 -4
  171. package/Form/FormRenderControl.mjs +0 -21
  172. package/Form/FormRenderControl.types.d.ts +0 -16
  173. package/Form/index.d.ts +0 -3
  174. package/Form/index.mjs +0 -13
  175. package/Form/package.json +0 -7
  176. package/FormCheckbox/FormCheckbox.d.ts +0 -4
  177. package/FormCheckbox/FormCheckbox.mjs +0 -30
  178. package/FormCheckbox/FormCheckbox.types.d.ts +0 -7
  179. package/FormCheckbox/index.d.ts +0 -2
  180. package/FormCheckbox/index.mjs +0 -4
  181. package/FormCheckbox/package.json +0 -7
  182. package/FormCombobox/FormCombobox.d.ts +0 -4
  183. package/FormCombobox/FormCombobox.mjs +0 -26
  184. package/FormCombobox/FormCombobox.types.d.ts +0 -6
  185. package/FormCombobox/index.d.ts +0 -2
  186. package/FormCombobox/index.mjs +0 -4
  187. package/FormCombobox/package.json +0 -7
  188. package/FormDatePicker/FormDatePicker.d.ts +0 -4
  189. package/FormDatePicker/FormDatePicker.mjs +0 -29
  190. package/FormDatePicker/FormDatePicker.types.d.ts +0 -6
  191. package/FormDatePicker/index.d.ts +0 -3
  192. package/FormDatePicker/index.mjs +0 -5
  193. package/FormDatePicker/package.json +0 -7
  194. package/FormDropzone/FormDropzone.d.ts +0 -4
  195. package/FormDropzone/FormDropzone.mjs +0 -19
  196. package/FormDropzone/FormDropzone.types.d.ts +0 -6
  197. package/FormDropzone/index.d.ts +0 -2
  198. package/FormDropzone/index.mjs +0 -4
  199. package/FormDropzone/package.json +0 -7
  200. package/FormInput/FormInput.d.ts +0 -7
  201. package/FormInput/FormInput.mjs +0 -40
  202. package/FormInput/FormInput.types.d.ts +0 -6
  203. package/FormInput/index.d.ts +0 -2
  204. package/FormInput/index.mjs +0 -4
  205. package/FormInput/package.json +0 -7
  206. package/FormRadio/FormRadio.d.ts +0 -4
  207. package/FormRadio/FormRadio.mjs +0 -40
  208. package/FormRadio/FormRadio.types.d.ts +0 -6
  209. package/FormRadio/index.d.ts +0 -2
  210. package/FormRadio/index.mjs +0 -4
  211. package/FormRadio/package.json +0 -7
  212. package/FormSelect/FormSelect.d.ts +0 -4
  213. package/FormSelect/FormSelect.mjs +0 -40
  214. package/FormSelect/FormSelect.types.d.ts +0 -6
  215. package/FormSelect/index.d.ts +0 -2
  216. package/FormSelect/index.mjs +0 -4
  217. package/FormSelect/package.json +0 -7
  218. package/FormTextarea/FormTextarea.d.ts +0 -4
  219. package/FormTextarea/FormTextarea.mjs +0 -27
  220. package/FormTextarea/FormTextarea.types.d.ts +0 -6
  221. package/FormTextarea/index.d.ts +0 -2
  222. package/FormTextarea/index.mjs +0 -4
  223. package/FormTextarea/package.json +0 -7
  224. package/Header/Header.d.ts +0 -4
  225. package/Header/Header.mjs +0 -26
  226. package/Header/Header.types.d.ts +0 -3
  227. package/Header/index.d.ts +0 -2
  228. package/Header/index.mjs +0 -5
  229. package/Header/package.json +0 -7
  230. package/HoverCard/HoverCard.d.ts +0 -6
  231. package/HoverCard/HoverCard.mjs +0 -23
  232. package/HoverCard/index.d.ts +0 -1
  233. package/HoverCard/index.mjs +0 -6
  234. package/HoverCard/package.json +0 -7
  235. package/Input/Input.d.ts +0 -6
  236. package/Input/Input.mjs +0 -73
  237. package/Input/Input.types.d.ts +0 -17
  238. package/Input/index.d.ts +0 -3
  239. package/Input/index.mjs +0 -7
  240. package/Input/inputVariants.d.ts +0 -3
  241. package/Input/inputVariants.mjs +0 -24
  242. package/Input/package.json +0 -7
  243. package/InputOTP/InputOTP.d.ts +0 -34
  244. package/InputOTP/InputOTP.mjs +0 -48
  245. package/InputOTP/index.d.ts +0 -1
  246. package/InputOTP/index.mjs +0 -7
  247. package/InputOTP/package.json +0 -7
  248. package/Label/Label.d.ts +0 -5
  249. package/Label/Label.mjs +0 -17
  250. package/Label/index.d.ts +0 -2
  251. package/Label/index.mjs +0 -6
  252. package/Label/labelVariants.d.ts +0 -1
  253. package/Label/labelVariants.mjs +0 -10
  254. package/Label/package.json +0 -7
  255. package/LazyLoader/LazyLoader.d.ts +0 -20
  256. package/LazyLoader/LazyLoader.mjs +0 -8
  257. package/LazyLoader/index.d.ts +0 -1
  258. package/LazyLoader/index.mjs +0 -5
  259. package/LazyLoader/package.json +0 -7
  260. package/LoadingMask/LoadingMask.d.ts +0 -4
  261. package/LoadingMask/LoadingMask.mjs +0 -21
  262. package/LoadingMask/LoadingMask.types.d.ts +0 -5
  263. package/LoadingMask/RenderLoadingMask.d.ts +0 -3
  264. package/LoadingMask/RenderLoadingMask.mjs +0 -108
  265. package/LoadingMask/index.d.ts +0 -3
  266. package/LoadingMask/index.mjs +0 -6
  267. package/LoadingMask/package.json +0 -7
  268. package/LoadingProgress/LoadingProgress.d.ts +0 -4
  269. package/LoadingProgress/LoadingProgress.mjs +0 -37
  270. package/LoadingProgress/LoadingProgress.types.d.ts +0 -8
  271. package/LoadingProgress/index.d.ts +0 -3
  272. package/LoadingProgress/index.mjs +0 -6
  273. package/LoadingProgress/loadingProgressVariants.d.ts +0 -4
  274. package/LoadingProgress/loadingProgressVariants.mjs +0 -24
  275. package/LoadingProgress/package.json +0 -7
  276. package/Menubar/Menubar.d.ts +0 -28
  277. package/Menubar/Menubar.mjs +0 -175
  278. package/Menubar/index.d.ts +0 -1
  279. package/Menubar/index.mjs +0 -19
  280. package/Menubar/package.json +0 -7
  281. package/NavigationMenu/NavigationMenu.d.ts +0 -11
  282. package/NavigationMenu/NavigationMenu.mjs +0 -101
  283. package/NavigationMenu/index.d.ts +0 -2
  284. package/NavigationMenu/index.mjs +0 -13
  285. package/NavigationMenu/navigationMenuVariants.d.ts +0 -1
  286. package/NavigationMenu/navigationMenuVariants.mjs +0 -7
  287. package/NavigationMenu/package.json +0 -7
  288. package/Pagination/Pagination.d.ts +0 -28
  289. package/Pagination/Pagination.mjs +0 -106
  290. package/Pagination/index.d.ts +0 -1
  291. package/Pagination/index.mjs +0 -10
  292. package/Pagination/package.json +0 -7
  293. package/Popover/Popover.d.ts +0 -7
  294. package/Popover/Popover.mjs +0 -28
  295. package/Popover/index.d.ts +0 -1
  296. package/Popover/index.mjs +0 -7
  297. package/Popover/package.json +0 -7
  298. package/Progress/Progress.d.ts +0 -4
  299. package/Progress/Progress.mjs +0 -26
  300. package/Progress/index.d.ts +0 -1
  301. package/Progress/index.mjs +0 -4
  302. package/Progress/package.json +0 -7
  303. package/Radio/Radio.d.ts +0 -4
  304. package/Radio/Radio.mjs +0 -12
  305. package/Radio/Radio.types.d.ts +0 -11
  306. package/Radio/index.d.ts +0 -2
  307. package/Radio/index.mjs +0 -4
  308. package/Radio/package.json +0 -7
  309. package/RadioGroup/RadioGroup.d.ts +0 -11
  310. package/RadioGroup/RadioGroup.mjs +0 -49
  311. package/RadioGroup/index.d.ts +0 -1
  312. package/RadioGroup/index.mjs +0 -6
  313. package/RadioGroup/package.json +0 -7
  314. package/Resizable/Resizable.d.ts +0 -23
  315. package/Resizable/Resizable.mjs +0 -36
  316. package/Resizable/index.d.ts +0 -1
  317. package/Resizable/index.mjs +0 -6
  318. package/Resizable/package.json +0 -7
  319. package/ScrollArea/ScrollArea.d.ts +0 -5
  320. package/ScrollArea/ScrollArea.mjs +0 -51
  321. package/ScrollArea/index.d.ts +0 -1
  322. package/ScrollArea/index.mjs +0 -5
  323. package/ScrollArea/package.json +0 -7
  324. package/Search/Search.d.ts +0 -4
  325. package/Search/Search.mjs +0 -30
  326. package/Search/Search.types.d.ts +0 -6
  327. package/Search/index.d.ts +0 -3
  328. package/Search/index.mjs +0 -5
  329. package/Search/package.json +0 -7
  330. package/Select/Select.d.ts +0 -3
  331. package/Select/Select.mjs +0 -103
  332. package/Select/Select.types.d.ts +0 -37
  333. package/Select/SelectRoot.d.ts +0 -13
  334. package/Select/SelectRoot.mjs +0 -126
  335. package/Select/index.d.ts +0 -3
  336. package/Select/index.mjs +0 -15
  337. package/Select/package.json +0 -7
  338. package/Separator/Separator.d.ts +0 -4
  339. package/Separator/Separator.mjs +0 -24
  340. package/Separator/index.d.ts +0 -1
  341. package/Separator/index.mjs +0 -4
  342. package/Separator/package.json +0 -7
  343. package/Sheet/Sheet.d.ts +0 -28
  344. package/Sheet/Sheet.mjs +0 -110
  345. package/Sheet/index.d.ts +0 -1
  346. package/Sheet/index.mjs +0 -13
  347. package/Sheet/package.json +0 -7
  348. package/Sidebar/Sidebar.d.ts +0 -66
  349. package/Sidebar/Sidebar.mjs +0 -543
  350. package/Sidebar/index.d.ts +0 -1
  351. package/Sidebar/index.mjs +0 -27
  352. package/Sidebar/package.json +0 -7
  353. package/Skeleton/Skeleton.d.ts +0 -4
  354. package/Skeleton/Skeleton.mjs +0 -17
  355. package/Skeleton/index.d.ts +0 -1
  356. package/Skeleton/index.mjs +0 -4
  357. package/Skeleton/package.json +0 -7
  358. package/Slider/Slider.d.ts +0 -4
  359. package/Slider/Slider.mjs +0 -23
  360. package/Slider/index.d.ts +0 -1
  361. package/Slider/index.mjs +0 -4
  362. package/Slider/package.json +0 -7
  363. package/Sonner/Sonner.d.ts +0 -5
  364. package/Sonner/Sonner.mjs +0 -25
  365. package/Sonner/index.d.ts +0 -1
  366. package/Sonner/index.mjs +0 -4
  367. package/Sonner/package.json +0 -7
  368. package/Switch/Switch.d.ts +0 -4
  369. package/Switch/Switch.mjs +0 -27
  370. package/Switch/index.d.ts +0 -1
  371. package/Switch/index.mjs +0 -4
  372. package/Switch/package.json +0 -7
  373. package/Table/Table.d.ts +0 -10
  374. package/Table/Table.mjs +0 -90
  375. package/Table/index.d.ts +0 -1
  376. package/Table/index.mjs +0 -11
  377. package/Table/package.json +0 -7
  378. package/TablePagination/TablePagination.d.ts +0 -16
  379. package/TablePagination/TablePagination.mjs +0 -74
  380. package/TablePagination/index.d.ts +0 -1
  381. package/TablePagination/index.mjs +0 -4
  382. package/TablePagination/package.json +0 -7
  383. package/Tabs/Tabs.d.ts +0 -5
  384. package/Tabs/Tabs.mjs +0 -23
  385. package/Tabs/Tabs.types.d.ts +0 -12
  386. package/Tabs/TabsRoot.d.ts +0 -7
  387. package/Tabs/TabsRoot.mjs +0 -46
  388. package/Tabs/index.d.ts +0 -2
  389. package/Tabs/index.mjs +0 -10
  390. package/Tabs/package.json +0 -7
  391. package/Textarea/Textarea.d.ts +0 -4
  392. package/Textarea/Textarea.mjs +0 -74
  393. package/Textarea/Textarea.types.d.ts +0 -18
  394. package/Textarea/index.d.ts +0 -2
  395. package/Textarea/index.mjs +0 -4
  396. package/Textarea/package.json +0 -7
  397. package/Textarea/useAutosizeTextArea.d.ts +0 -3
  398. package/Textarea/useAutosizeTextArea.mjs +0 -20
  399. package/Theme/ThemeModeToggle.d.ts +0 -8
  400. package/Theme/ThemeModeToggle.mjs +0 -48
  401. package/Theme/ThemeProvider.d.ts +0 -4
  402. package/Theme/ThemeProvider.mjs +0 -27
  403. package/Theme/index.d.ts +0 -2
  404. package/Theme/index.mjs +0 -6
  405. package/Theme/package.json +0 -7
  406. package/Toast/Toast.d.ts +0 -13
  407. package/Toast/Toast.mjs +0 -80
  408. package/Toast/Toast.types.d.ts +0 -34
  409. package/Toast/index.d.ts +0 -3
  410. package/Toast/index.mjs +0 -15
  411. package/Toast/package.json +0 -7
  412. package/Toast/toast.constants.d.ts +0 -6
  413. package/Toast/toast.constants.mjs +0 -9
  414. package/Toast/toastVariants.d.ts +0 -3
  415. package/Toast/toastVariants.mjs +0 -21
  416. package/Toast/useToast.d.ts +0 -16
  417. package/Toast/useToast.mjs +0 -101
  418. package/Toaster/Toaster.d.ts +0 -1
  419. package/Toaster/Toaster.mjs +0 -22
  420. package/Toaster/index.d.ts +0 -1
  421. package/Toaster/index.mjs +0 -4
  422. package/Toaster/package.json +0 -7
  423. package/Toggle/Toggle.d.ts +0 -12
  424. package/Toggle/Toggle.mjs +0 -37
  425. package/Toggle/index.d.ts +0 -1
  426. package/Toggle/index.mjs +0 -5
  427. package/Toggle/package.json +0 -7
  428. package/ToggleGroup/ToggleGroup.d.ts +0 -12
  429. package/ToggleGroup/ToggleGroup.mjs +0 -41
  430. package/ToggleGroup/index.d.ts +0 -1
  431. package/ToggleGroup/index.mjs +0 -5
  432. package/ToggleGroup/package.json +0 -7
  433. package/Tooltip/Tooltip.d.ts +0 -4
  434. package/Tooltip/Tooltip.mjs +0 -12
  435. package/Tooltip/Tooltip.types.d.ts +0 -8
  436. package/Tooltip/TooltipRoot.d.ts +0 -7
  437. package/Tooltip/TooltipRoot.mjs +0 -23
  438. package/Tooltip/index.d.ts +0 -3
  439. package/Tooltip/index.mjs +0 -9
  440. package/Tooltip/package.json +0 -7
  441. package/index.css +0 -1
  442. package/index.d.ts +0 -68
  443. package/index.mjs +0 -367
  444. package/tailwind.config.mjs +0 -148
@@ -1,152 +0,0 @@
1
- import { jsxs as r, jsx as i, Fragment as U } from "react/jsx-runtime";
2
- import { X as j } from "lucide-react";
3
- import { forwardRef as H, useState as w, useImperativeHandle as O } from "react";
4
- import { useDropzone as X } from "react-dropzone";
5
- import { cn as f } from "@oneplatformdev/utils";
6
- import { Card as Y } from "../Card/Card.mjs";
7
- import { F as q, D as G } from "../DropzoneFilePreview-Dhtv8F4u.js";
8
- import { DropzoneSinglePickPreview as J } from "./DropzoneSinglePickPreview.mjs";
9
- import { DefaultFileIcon as K, isFile as g, extractName as Q } from "./DropzoneUtils.mjs";
10
- const R = H(
11
- ({
12
- acceptTypes: y = G,
13
- maxSizeMB: F,
14
- maxFiles: v = 1,
15
- onErrors: a,
16
- hideErrors: D = !1,
17
- disabled: p = !1,
18
- classNames: o,
19
- value: z = [],
20
- onChangeValue: s,
21
- className: I,
22
- labelDropzonePrompt: E = "Drop files here or click to select",
23
- labelDropzoneSubPrompt: b = "",
24
- labelOrClickToSelect: Z = "Click to select files",
25
- labelSelectedFiles: S = "Selected Files",
26
- labelUploadErrors: N = "Upload Errors",
27
- labelFileTooLarge: W = "File is too large",
28
- labelInvalidFileType: k = "Invalid file type",
29
- singlePick: c = !1,
30
- ...B
31
- }, T) => {
32
- const [n, x] = w(z), [m, _] = w([]), A = (e, l) => {
33
- _(l), a == null || a(l);
34
- const t = c ? e.slice(0, 1) : [...n, ...e].slice(0, v);
35
- x(t), s == null || s(t);
36
- }, u = (e, l) => {
37
- if (p) return;
38
- e.stopPropagation();
39
- const t = n.filter((d, h) => h !== l);
40
- x(t), s == null || s(t);
41
- }, { getRootProps: L, getInputProps: M, isDragActive: P } = X({
42
- onDrop: A,
43
- accept: y.reduce((e, l) => (e[l] = [], e), {}),
44
- maxSize: F * 1024 * 1024,
45
- maxFiles: c ? 1 : v,
46
- disabled: p
47
- });
48
- return O(T, () => ({
49
- setItems: x
50
- }), []), /* @__PURE__ */ r(
51
- Y,
52
- {
53
- ...L(),
54
- ...B,
55
- className: f(
56
- "border-dashed p-2 text-center flex flex-col items-center justify-center cursor-pointer",
57
- p && "border-[#E4E4E7] pointer-events-none",
58
- m.length > 0 ? "border-red-500" : "!border-[#E4E4E7]",
59
- P && "bg-gray-100",
60
- c && "!shadow-none",
61
- c && n.length > 0 && "!p-0 !shadow-none",
62
- I
63
- ),
64
- children: [
65
- /* @__PURE__ */ i("input", { ...M() }),
66
- n.length === 0 && m.length === 0 && /* @__PURE__ */ r(
67
- "div",
68
- {
69
- className: f(
70
- "flex flex-col items-center gap-1",
71
- o == null ? void 0 : o.idleWrapper
72
- ),
73
- children: [
74
- /* @__PURE__ */ i(K, {}),
75
- !p && /* @__PURE__ */ r(U, { children: [
76
- /* @__PURE__ */ i("span", { className: "font-medium text-md text-foreground max-w-[200px]", children: E }),
77
- /* @__PURE__ */ i("span", { className: "font-normal text-xs text-foreground max-w-[250px]", children: b })
78
- ] })
79
- ]
80
- }
81
- ),
82
- m.length > 0 && /* @__PURE__ */ r("div", { className: f("w-full mt-4", o == null ? void 0 : o.errorWrapper), children: [
83
- /* @__PURE__ */ r("span", { className: "font-semibold text-red-500", children: [
84
- N,
85
- ":"
86
- ] }),
87
- /* @__PURE__ */ i("ul", { className: "mt-2 text-sm text-red-500 list-disc list-inside", children: m.map((e, l) => /* @__PURE__ */ r("li", { children: [
88
- e.file.name,
89
- " (",
90
- (e.file.size / (1024 * 1024)).toFixed(2),
91
- " MB)",
92
- !D && /* @__PURE__ */ i("ul", { className: "ml-4 list-disc list-inside", children: e.errors.map((t, d) => /* @__PURE__ */ r("li", { children: [
93
- t.code === "file-too-large" && W,
94
- t.code === "file-invalid-type" && k,
95
- t.code !== "file-too-large" && t.code !== "file-invalid-type" && t.message
96
- ] }, d)) })
97
- ] }, l)) })
98
- ] }),
99
- !!(c && n.length) && /* @__PURE__ */ i(
100
- J,
101
- {
102
- item: n[0],
103
- onRemoveClick: (e) => u(e, 0),
104
- disabled: p
105
- }
106
- ),
107
- !c && n.length > 0 && /* @__PURE__ */ r("div", { className: f("w-full mt-2", o == null ? void 0 : o.previewWrapper), children: [
108
- /* @__PURE__ */ r("pre", { className: "font-semibold text-gray-600", children: [
109
- S,
110
- ":"
111
- ] }),
112
- /* @__PURE__ */ i("ul", { className: "mt-2 text-sm text-gray-500 flex flex-wrap gap-4 items-start justify-center", children: n.map((e, l) => {
113
- const t = g(e) ? e.name : Q(e), d = g(e) ? (e.size / (1024 * 1024)).toFixed(2) + " MB" : "";
114
- return /* @__PURE__ */ r(
115
- "li",
116
- {
117
- className: "flex flex-col items-center gap-2 relative",
118
- children: [
119
- /* @__PURE__ */ r("div", { className: "relative", children: [
120
- /* @__PURE__ */ i(q, { item: e, styles: o }),
121
- /* @__PURE__ */ i(
122
- "div",
123
- {
124
- className: "absolute top-0 right-0 cursor-pointer bg-gray-300 rounded-sm",
125
- onClick: (h) => u(h, l),
126
- children: /* @__PURE__ */ i(j, { size: 16, strokeWidth: 1, color: "black" })
127
- }
128
- )
129
- ] }),
130
- /* @__PURE__ */ r("span", { className: "inline-flex flex-col items-center", children: [
131
- /* @__PURE__ */ i("span", { className: "max-w-[80px] text-ellipsis overflow-hidden whitespace-nowrap", children: t }),
132
- d && /* @__PURE__ */ r("span", { children: [
133
- "(",
134
- d,
135
- ")"
136
- ] })
137
- ] })
138
- ]
139
- },
140
- l
141
- );
142
- }) })
143
- ] })
144
- ]
145
- }
146
- );
147
- }
148
- );
149
- R.displayName = "Dropzone";
150
- export {
151
- R as Dropzone
152
- };
@@ -1,42 +0,0 @@
1
- import { Dispatch, SetStateAction } from 'react';
2
- import { FileRejection } from 'react-dropzone';
3
-
4
- export type DropzoneValueItem = File | string;
5
- export interface FilePreviewProps {
6
- item: DropzoneValueItem;
7
- styles?: Pick<DropzoneStyles, 'previewWraper' | 'previewImage' | 'previewFile'>;
8
- }
9
- export interface DropzoneTranslations {
10
- labelDropzonePrompt?: string;
11
- labelDropzoneSubPrompt?: string;
12
- labelOrClickToSelect?: string;
13
- labelSelectedFiles?: string;
14
- labelUploadErrors?: string;
15
- labelFileTooLarge?: string;
16
- labelInvalidFileType?: string;
17
- }
18
- export interface DropzoneProps extends DropzoneTranslations, React.HTMLAttributes<HTMLDivElement> {
19
- acceptTypes?: string[];
20
- maxSizeMB: number;
21
- maxFiles?: number;
22
- onErrors?: (errors: FileRejection[]) => void;
23
- hideErrors?: boolean;
24
- disabled?: boolean;
25
- classNames?: DropzoneStyles;
26
- value?: DropzoneValueItem[];
27
- onChangeValue?: (items: DropzoneValueItem[]) => void;
28
- singlePick?: boolean;
29
- }
30
- export interface DropzoneStyles {
31
- idleWrapper?: string;
32
- previewWrapper?: string;
33
- errorWrapper?: string;
34
- previewWraper?: string;
35
- previewImage?: string;
36
- previewFile?: string;
37
- }
38
- export declare const DEFAULT_FILE_TYPES: string[];
39
- export declare const DEFAULT_IMAGES_TYPES: string[];
40
- export interface DropzoneControl {
41
- setItems: Dispatch<SetStateAction<DropzoneValueItem[]>>;
42
- }
@@ -1,4 +0,0 @@
1
- import { FilePreviewProps } from './Dropzone.types';
2
- import { FC } from 'react';
3
-
4
- export declare const FilePreview: FC<FilePreviewProps>;
@@ -1,9 +0,0 @@
1
- import "react/jsx-runtime";
2
- import "react";
3
- import "lucide-react";
4
- import { F } from "../DropzoneFilePreview-Dhtv8F4u.js";
5
- import "./DropzoneUtils.mjs";
6
- import "@oneplatformdev/utils";
7
- export {
8
- F as FilePreview
9
- };
@@ -1,10 +0,0 @@
1
- import { DropzoneValueItem } from './Dropzone.types';
2
-
3
- export declare const transformImageToSrc: (preview?: string | File | null) => string;
4
- interface SinglePickPreviewProps {
5
- item: DropzoneValueItem;
6
- disabled?: boolean;
7
- onRemoveClick: (e: React.MouseEvent<HTMLDivElement>) => void;
8
- }
9
- export declare const DropzoneSinglePickPreview: ({ item, disabled, onRemoveClick, }: SinglePickPreviewProps) => import("react/jsx-runtime").JSX.Element;
10
- export {};
@@ -1,41 +0,0 @@
1
- import { jsxs as s, jsx as r } from "react/jsx-runtime";
2
- import { useMemo as c } from "react";
3
- import { isFile as i } from "./DropzoneUtils.mjs";
4
- import { X as a, FileIcon as u } from "lucide-react";
5
- const d = (t) => {
6
- if (!t) return "";
7
- switch (!0) {
8
- case (typeof t == "string" && !!t.trim() && t !== "null"):
9
- return t;
10
- case t instanceof File:
11
- return URL.createObjectURL(t);
12
- case t instanceof FileList:
13
- return t[0] ? URL.createObjectURL(t[0]) : "";
14
- default:
15
- return "";
16
- }
17
- }, p = ({
18
- item: t,
19
- disabled: l,
20
- onRemoveClick: n
21
- }) => {
22
- const e = i(t) ? t.name : t, o = c(() => d(t), [t]);
23
- return /* @__PURE__ */ s("div", { className: "relative w-full h-64 sm:h-80 md:h-96 overflow-hidden outline-[#E4E4E7] outline-[2px] outline-dashed outline-offset-[-1px] rounded-lg", children: [
24
- !l && /* @__PURE__ */ r("div", { className: "absolute top-2 right-2 cursor-pointer bg-white/70 rounded-[4px] p-1 shadow", onClick: n, children: /* @__PURE__ */ r(a, { size: 16, strokeWidth: 2, color: "black" }) }),
25
- o ? /* @__PURE__ */ r(
26
- "img",
27
- {
28
- src: o,
29
- alt: e == null ? void 0 : e.toString(),
30
- className: "w-full h-full object-cover rounded-lg "
31
- }
32
- ) : /* @__PURE__ */ s("div", { className: "w-full h-full flex flex-col items-center justify-center text-gray-600", children: [
33
- /* @__PURE__ */ r(u, { size: 28 }),
34
- /* @__PURE__ */ r("span", { className: "text-sm mt-2 break-all px-2 text-center", children: e == null ? void 0 : e.toString() })
35
- ] })
36
- ] });
37
- };
38
- export {
39
- p as DropzoneSinglePickPreview,
40
- d as transformImageToSrc
41
- };
@@ -1,5 +0,0 @@
1
- import { DropzoneValueItem } from './Dropzone.types';
2
-
3
- export declare function isFile(item: DropzoneValueItem): item is File;
4
- export declare function extractName(url: string): string;
5
- export declare const DefaultFileIcon: () => import("react/jsx-runtime").JSX.Element;
@@ -1,24 +0,0 @@
1
- import { jsxs as t, jsx as l } from "react/jsx-runtime";
2
- function d(e) {
3
- return e instanceof File;
4
- }
5
- function r(e) {
6
- try {
7
- const i = e.split("?")[0].split("#")[0].split("/");
8
- return i[i.length - 1] || e;
9
- } catch {
10
- return e;
11
- }
12
- }
13
- const o = () => /* @__PURE__ */ t("svg", { width: "55", height: "55", viewBox: "0 0 55 55", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
14
- /* @__PURE__ */ l("mask", { id: "mask0_2430_114601", maskUnits: "userSpaceOnUse", x: "7", y: "4", width: "39", height: "46", children: /* @__PURE__ */ l("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M7.25 4.68359H45.6174V49.354H7.25V4.68359Z", fill: "white" }) }),
15
- /* @__PURE__ */ l("g", { mask: "url(#mask0_2430_114601)", children: /* @__PURE__ */ l("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M17.5386 8.05859C13.8103 8.05859 10.7143 11.0781 10.6266 14.8018V38.9196C10.5456 42.7468 13.5606 45.8968 17.3518 45.9801H35.5386C39.2938 45.8451 42.2661 42.7468 42.2413 38.9308V18.9216L31.8148 8.05859H17.5656H17.5386ZM17.5664 49.3551H17.2829C11.6309 49.2336 7.1309 44.5356 7.2524 38.8836V14.7613C7.38515 9.17909 11.9932 4.68359 17.5327 4.68359H17.5732H32.5334C32.9924 4.68359 33.4312 4.87034 33.7507 5.20109L45.1492 17.0743C45.4484 17.3871 45.6172 17.8078 45.6172 18.2421V38.9196C45.6532 44.5648 41.2522 49.1526 35.5979 49.3551H17.5664Z", fill: "#0D0E2B", "fill-opacity": "0.7" }) }),
16
- /* @__PURE__ */ l("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M43.9198 20.3703H37.7233C33.6036 20.359 30.2578 17.002 30.2578 12.889V6.34375C30.2578 5.41225 31.0138 4.65625 31.9453 4.65625C32.8768 4.65625 33.6328 5.41225 33.6328 6.34375V12.889C33.6328 15.148 35.4688 16.9885 37.7278 16.9953H43.9198C44.8513 16.9953 45.6073 17.7513 45.6073 18.6828C45.6073 19.6143 44.8513 20.3703 43.9198 20.3703Z", fill: "#0D0E2B", "fill-opacity": "0.7" }),
17
- /* @__PURE__ */ l("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M25.5708 37.729C24.6393 37.729 23.8833 36.973 23.8833 36.0415V22.4492C23.8833 21.5177 24.6393 20.7617 25.5708 20.7617C26.5023 20.7617 27.2583 21.5177 27.2583 22.4492V36.0415C27.2583 36.973 26.5023 37.729 25.5708 37.729Z", fill: "#0D0E2B", "fill-opacity": "0.7" }),
18
- /* @__PURE__ */ l("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M25.5678 37.7279C25.1201 37.7279 24.6881 37.5501 24.3731 37.2306L19.0968 31.9341C18.4398 31.2726 18.4421 30.2039 19.1013 29.5469C19.7628 28.8899 20.8316 28.8899 21.4886 29.5514L25.5678 33.6509L29.6471 29.5514C30.3041 28.8899 31.3728 28.8899 32.0343 29.5469C32.6936 30.2039 32.6958 31.2726 32.0388 31.9341L26.7626 37.2306C26.4476 37.5501 26.0156 37.7279 25.5678 37.7279Z", fill: "#0D0E2B", "fill-opacity": "0.7" })
19
- ] });
20
- export {
21
- o as DefaultFileIcon,
22
- r as extractName,
23
- d as isFile
24
- };
@@ -1,2 +0,0 @@
1
- export * from './Dropzone';
2
- export * from './Dropzone.types';
@@ -1,7 +0,0 @@
1
- import { Dropzone as r } from "./Dropzone.mjs";
2
- import { D as T, a as _ } from "../DropzoneFilePreview-Dhtv8F4u.js";
3
- export {
4
- T as DEFAULT_FILE_TYPES,
5
- _ as DEFAULT_IMAGES_TYPES,
6
- r as Dropzone
7
- };
@@ -1,7 +0,0 @@
1
- {
2
- "sideEffects": false,
3
- "main": "./index.mjs",
4
- "module": "./index.mjs",
5
- "default": "./index.mjs",
6
- "types": "./index.d.ts"
7
- }
@@ -1,67 +0,0 @@
1
- import { jsx as l, jsxs as d } from "react/jsx-runtime";
2
- import { useState as m, useEffect as f } from "react";
3
- import { File as s } from "lucide-react";
4
- import { isFile as o } from "./Dropzone/DropzoneUtils.mjs";
5
- import { cn as c } from "@oneplatformdev/utils";
6
- const h = [
7
- "application/msword",
8
- "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
9
- "text/csv",
10
- "text/plain",
11
- "application/pdf"
12
- ], u = [
13
- "image/png",
14
- "image/jpeg",
15
- "image/jpg",
16
- "image/webp",
17
- "image/gif"
18
- ], j = ({ item: e, styles: r }) => {
19
- const [t, a] = m(null), p = o(e) && u.includes(e.type);
20
- return f(() => {
21
- let n = null;
22
- if (o(e) && p) {
23
- const i = new FileReader();
24
- return i.onloadend = () => a(i.result), i.readAsDataURL(e), () => a(null);
25
- } else {
26
- if (typeof e == "string")
27
- return n = new Image(), n.src = e, n.onload = () => a(e), n.onerror = () => a(null), () => {
28
- n.onload = null, n.onerror = null;
29
- };
30
- a(null);
31
- }
32
- return () => a(null);
33
- }, [e, p]), /* @__PURE__ */ l(
34
- "div",
35
- {
36
- className: c(
37
- "w-32 h-32 border border-gray-300 rounded-md overflow-hidden flex items-center justify-center",
38
- r == null ? void 0 : r.previewWraper
39
- ),
40
- children: t ? /* @__PURE__ */ l(
41
- "img",
42
- {
43
- src: t,
44
- alt: o(e) ? e.name : "external-image",
45
- className: c("w-full h-full object-cover", r == null ? void 0 : r.previewImage)
46
- }
47
- ) : /* @__PURE__ */ d(
48
- "div",
49
- {
50
- className: c(
51
- "flex flex-col items-center justify-center text-gray-500 text-sm p-2 text-center",
52
- r == null ? void 0 : r.previewFile
53
- ),
54
- children: [
55
- /* @__PURE__ */ l(s, { className: "w-6 h-6" }),
56
- o(e) ? /* @__PURE__ */ l("span", { className: "text-xs break-all", children: e.name }) : /* @__PURE__ */ l("span", { className: "text-xs break-all", children: e })
57
- ]
58
- }
59
- )
60
- }
61
- );
62
- };
63
- export {
64
- h as D,
65
- j as F,
66
- u as a
67
- };
package/Form/Form.d.ts DELETED
@@ -1,23 +0,0 @@
1
- import { ControllerProps, FieldPath, FieldValues } from 'react-hook-form';
2
- import * as React from 'react';
3
- import * as LabelPrimitive from '@radix-ui/react-label';
4
- declare const Form: <TFieldValues extends FieldValues, TContext = any, TTransformedValues extends FieldValues | undefined = undefined>(props: import('react-hook-form').FormProviderProps<TFieldValues, TContext, TTransformedValues>) => React.JSX.Element;
5
- declare const FormField: <TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({ ...props }: ControllerProps<TFieldValues, TName>) => import("react/jsx-runtime").JSX.Element;
6
- declare const useFormField: () => {
7
- invalid: boolean;
8
- isDirty: boolean;
9
- isTouched: boolean;
10
- isValidating: boolean;
11
- error?: import('react-hook-form').FieldError;
12
- id: string;
13
- name: string;
14
- formItemId: string;
15
- formDescriptionId: string;
16
- formMessageId: string;
17
- };
18
- declare const FormItem: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
19
- declare const FormLabel: React.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React.RefAttributes<HTMLLabelElement>, "ref"> & React.RefAttributes<HTMLLabelElement>>;
20
- declare const FormControl: React.ForwardRefExoticComponent<Omit<import('@radix-ui/react-slot').SlotProps & React.RefAttributes<HTMLElement>, "ref"> & React.RefAttributes<HTMLElement>>;
21
- declare const FormDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
22
- declare const FormMessage: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
23
- export { useFormField, Form, FormItem, FormLabel, FormControl, FormDescription, FormMessage, FormField, };
package/Form/Form.mjs DELETED
@@ -1,98 +0,0 @@
1
- import { jsx as n } from "react/jsx-runtime";
2
- import * as s from "react";
3
- import { Slot as F } from "@radix-ui/react-slot";
4
- import { FormProvider as u, Controller as p, useFormContext as x } from "react-hook-form";
5
- import { cn as a } from "@oneplatformdev/utils";
6
- import { Label as I } from "../Label/Label.mjs";
7
- import "../Label/labelVariants.mjs";
8
- const M = u, l = s.createContext(
9
- {}
10
- ), S = ({
11
- ...e
12
- }) => /* @__PURE__ */ n(l.Provider, { value: { name: e.name }, children: /* @__PURE__ */ n(p, { ...e }) }), c = () => {
13
- const e = s.useContext(l), t = s.useContext(f), { getFieldState: o, formState: r } = x(), m = o(e.name, r);
14
- if (!e)
15
- throw new Error("useFormField should be used within <FormField>");
16
- const { id: i } = t;
17
- return {
18
- id: i,
19
- name: e.name,
20
- formItemId: `${i}-form-item`,
21
- formDescriptionId: `${i}-form-item-description`,
22
- formMessageId: `${i}-form-item-message`,
23
- ...m
24
- };
25
- }, f = s.createContext(
26
- {}
27
- ), v = s.forwardRef(({ className: e, ...t }, o) => {
28
- const r = s.useId();
29
- return /* @__PURE__ */ n(f.Provider, { value: { id: r }, children: /* @__PURE__ */ n("div", { ref: o, className: a("space-y-1", e), ...t }) });
30
- });
31
- v.displayName = "FormItem";
32
- const C = s.forwardRef(({ className: e, ...t }, o) => {
33
- const { error: r, formItemId: m } = c();
34
- return /* @__PURE__ */ n(
35
- I,
36
- {
37
- ref: o,
38
- "data-state": r ? "invalid" : "valid",
39
- className: a(r && "text-destructive", e),
40
- htmlFor: m,
41
- ...t
42
- }
43
- );
44
- });
45
- C.displayName = "FormLabel";
46
- const g = s.forwardRef(({ className: e, ...t }, o) => {
47
- const { error: r, formItemId: m, formDescriptionId: i, formMessageId: d } = c();
48
- return /* @__PURE__ */ n(
49
- F,
50
- {
51
- ref: o,
52
- id: m,
53
- "data-state": r ? "invalid" : "valid",
54
- "aria-describedby": r ? `${i} ${d}` : `${i}`,
55
- "aria-invalid": !!r,
56
- className: a("group/form-control", e),
57
- ...t
58
- }
59
- );
60
- });
61
- g.displayName = "FormControl";
62
- const N = s.forwardRef(({ className: e, ...t }, o) => {
63
- const { formDescriptionId: r } = c();
64
- return /* @__PURE__ */ n(
65
- "p",
66
- {
67
- ref: o,
68
- id: r,
69
- className: a("text-[0.8rem] text-muted-foreground", e),
70
- ...t
71
- }
72
- );
73
- });
74
- N.displayName = "FormDescription";
75
- const w = s.forwardRef(({ className: e, children: t, ...o }, r) => {
76
- const { error: m, formMessageId: i } = c(), d = m ? String(m == null ? void 0 : m.message) : t;
77
- return d ? /* @__PURE__ */ n(
78
- "p",
79
- {
80
- ref: r,
81
- id: i,
82
- className: a("text-[0.8rem] font-medium text-destructive", e),
83
- ...o,
84
- children: d
85
- }
86
- ) : null;
87
- });
88
- w.displayName = "FormMessage";
89
- export {
90
- M as Form,
91
- g as FormControl,
92
- N as FormDescription,
93
- S as FormField,
94
- v as FormItem,
95
- C as FormLabel,
96
- w as FormMessage,
97
- c as useFormField
98
- };
@@ -1,4 +0,0 @@
1
- import { FieldValues } from 'react-hook-form';
2
- import { FormRenderControlProps } from './FormRenderControl.types';
3
-
4
- export declare const FormRenderControl: <Data extends FieldValues>(props: FormRenderControlProps<Data>) => import("react/jsx-runtime").JSX.Element;
@@ -1,21 +0,0 @@
1
- import { jsx as r, jsxs as a } from "react/jsx-runtime";
2
- import { FormField as d, FormItem as i, FormLabel as F, FormMessage as p } from "./Form.mjs";
3
- const b = (e) => {
4
- const { form: n, name: m, label: o, render: t, containerProps: l = {}, ...s } = e;
5
- return /* @__PURE__ */ r(
6
- d,
7
- {
8
- control: n.control,
9
- name: m,
10
- render: (c) => /* @__PURE__ */ a(i, { ...l, children: [
11
- !!o && /* @__PURE__ */ r(F, { children: o }),
12
- t(c),
13
- /* @__PURE__ */ r(p, {})
14
- ] }),
15
- ...s
16
- }
17
- );
18
- };
19
- export {
20
- b as FormRenderControl
21
- };
@@ -1,16 +0,0 @@
1
- import { ControllerFieldState, ControllerRenderProps, FieldPath, FieldValues, UseFormReturn, UseFormStateReturn } from 'react-hook-form';
2
- import { default as React } from 'react';
3
-
4
- export type FormRenderProps<Data extends FieldValues> = ({ field, fieldState, formState, }: {
5
- field: ControllerRenderProps<Data, FieldPath<Data>>;
6
- fieldState: ControllerFieldState;
7
- formState: UseFormStateReturn<Data>;
8
- }) => React.ReactElement;
9
- export interface FormRenderControlProps<Data extends FieldValues> {
10
- form: UseFormReturn<Data>;
11
- name: FieldPath<Data>;
12
- label?: string;
13
- render: FormRenderProps<Data>;
14
- containerProps?: React.HTMLAttributes<HTMLDivElement>;
15
- }
16
- export type FormRenderControlExtendProps<Data extends FieldValues> = Omit<FormRenderControlProps<Data>, 'render'>;
package/Form/index.d.ts DELETED
@@ -1,3 +0,0 @@
1
- export * from './Form';
2
- export * from './FormRenderControl';
3
- export type * from './FormRenderControl.types';
package/Form/index.mjs DELETED
@@ -1,13 +0,0 @@
1
- import { Form as e, FormControl as m, FormDescription as F, FormField as t, FormItem as l, FormLabel as i, FormMessage as n, useFormField as s } from "./Form.mjs";
2
- import { FormRenderControl as p } from "./FormRenderControl.mjs";
3
- export {
4
- e as Form,
5
- m as FormControl,
6
- F as FormDescription,
7
- t as FormField,
8
- l as FormItem,
9
- i as FormLabel,
10
- n as FormMessage,
11
- p as FormRenderControl,
12
- s as useFormField
13
- };
package/Form/package.json DELETED
@@ -1,7 +0,0 @@
1
- {
2
- "sideEffects": false,
3
- "main": "./index.mjs",
4
- "module": "./index.mjs",
5
- "default": "./index.mjs",
6
- "types": "./index.d.ts"
7
- }
@@ -1,4 +0,0 @@
1
- import { FormCheckboxProps } from './FormCheckbox.types';
2
- import { FieldValues } from 'react-hook-form';
3
-
4
- export declare const FormCheckbox: <Data extends FieldValues>(props: FormCheckboxProps<Data>) => import("react/jsx-runtime").JSX.Element;
@@ -1,30 +0,0 @@
1
- import { jsx as e } from "react/jsx-runtime";
2
- import { FormControl as h } from "../Form/Form.mjs";
3
- import { FormRenderControl as p } from "../Form/FormRenderControl.mjs";
4
- import { CheckboxLabel as s } from "../Checkbox/Checkbox.mjs";
5
- const i = (t) => {
6
- const { form: c, label: a, name: l, onCheckedChange: o, ...m } = t;
7
- return /* @__PURE__ */ e(
8
- p,
9
- {
10
- form: c,
11
- name: l,
12
- render: ({ field: r }) => /* @__PURE__ */ e(h, { children: /* @__PURE__ */ e(
13
- s,
14
- {
15
- ...r,
16
- ...m,
17
- label: a,
18
- checked: r.value || !1,
19
- onCheckedChange: (n) => {
20
- r.onChange(n), o == null || o(n);
21
- }
22
- }
23
- ) }),
24
- ...m
25
- }
26
- );
27
- };
28
- export {
29
- i as FormCheckbox
30
- };
@@ -1,7 +0,0 @@
1
- import { FormRenderControlExtendProps } from '../Form';
2
- import { FieldValues } from 'react-hook-form';
3
- import { CheckboxProps } from '../Checkbox';
4
-
5
- export interface FormCheckboxProps<Data extends FieldValues> extends FormRenderControlExtendProps<Data>, Omit<CheckboxProps, 'form' | 'name' | 'label'> {
6
- disabled?: boolean;
7
- }
@@ -1,2 +0,0 @@
1
- export * from './FormCheckbox';
2
- export type * from './FormCheckbox.types';
@@ -1,4 +0,0 @@
1
- import { FormCheckbox as e } from "./FormCheckbox.mjs";
2
- export {
3
- e as FormCheckbox
4
- };
@@ -1,7 +0,0 @@
1
- {
2
- "sideEffects": false,
3
- "main": "./index.mjs",
4
- "module": "./index.mjs",
5
- "default": "./index.mjs",
6
- "types": "./index.d.ts"
7
- }
@@ -1,4 +0,0 @@
1
- import { FieldValues } from 'react-hook-form';
2
- import { FormComboboxProps } from './FormCombobox.types';
3
-
4
- export declare const FormCombobox: <Data extends FieldValues>(props: FormComboboxProps<Data>) => import("react/jsx-runtime").JSX.Element;