welcome-ui 8.0.0 → 8.1.0-alpha.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 (301) hide show
  1. package/dist/AXB53BZF-XKOjjeWO.mjs +25 -0
  2. package/dist/Accordion.mjs +30 -23
  3. package/dist/Alert.mjs +76 -70
  4. package/dist/AspectRatio.mjs +8 -10
  5. package/dist/Avatar.mjs +48 -47
  6. package/dist/{BYC7LY2E-CVjUW1dr.mjs → BYC7LY2E-CWSI38FM.mjs} +355 -351
  7. package/dist/Badge.mjs +25 -25
  8. package/dist/Box.mjs +5 -5
  9. package/dist/Breadcrumb.mjs +173 -168
  10. package/dist/Button.mjs +72 -67
  11. package/dist/ButtonGroup.mjs +13 -12
  12. package/dist/Card.mjs +14 -14
  13. package/dist/Checkbox.mjs +2 -2
  14. package/dist/ClearButton.mjs +15 -15
  15. package/dist/CloseButton.mjs +9 -9
  16. package/dist/{CustomInput-D_13Gd_3.mjs → CustomPopper-CZt4RioF.mjs} +3200 -3047
  17. package/dist/DatePicker.mjs +81 -80
  18. package/dist/DateTimePicker.mjs +67 -62
  19. package/dist/DateTimePickerCommon.mjs +1 -1
  20. package/dist/Drawer.mjs +190 -174
  21. package/dist/DropdownMenu.mjs +389 -386
  22. package/dist/Field.mjs +104 -92
  23. package/dist/FieldGroup.mjs +12 -9
  24. package/dist/FileDrop.mjs +613 -576
  25. package/dist/FileUpload.mjs +95 -74
  26. package/dist/Files.mjs +46 -46
  27. package/dist/Flex.mjs +13 -13
  28. package/dist/Grid.mjs +29 -29
  29. package/dist/Hint.mjs +12 -12
  30. package/dist/ITI7HKP4-C89kOQb8.mjs +474 -0
  31. package/dist/Icon.mjs +24 -24
  32. package/dist/Icons.mjs +988 -988
  33. package/dist/IconsFont.mjs +159 -159
  34. package/dist/InputText.mjs +65 -57
  35. package/dist/{JC64G2H7-Dey-8h60.mjs → JC64G2H7-afsomHuH.mjs} +109 -108
  36. package/dist/KUU7WJ55-CzsjuIMv.mjs +61 -0
  37. package/dist/LVA2YJMS-C-kJ1lkr.mjs +873 -0
  38. package/dist/Label.mjs +37 -35
  39. package/dist/Link.mjs +28 -24
  40. package/dist/Loader.mjs +20 -16
  41. package/dist/Logo.mjs +55 -42
  42. package/dist/MTZPJQMC-TybFZCho.mjs +15 -0
  43. package/dist/Modal.mjs +276 -253
  44. package/dist/NLEBE274-oSxMftGy.mjs +84 -0
  45. package/dist/P2CTZE2T-DOT1mNnX.mjs +301 -0
  46. package/dist/P4IRICAX-CWSZLTGz.mjs +37 -0
  47. package/dist/Pagination.mjs +104 -104
  48. package/dist/PasswordInput.mjs +35 -34
  49. package/dist/Picker.mjs +35 -33
  50. package/dist/Popover.mjs +100 -93
  51. package/dist/QYJ6MIDR-DJ-vUdAM.mjs +98 -0
  52. package/dist/Radio.mjs +58 -52
  53. package/dist/RadioGroup.mjs +46 -46
  54. package/dist/RadioTab.mjs +37 -35
  55. package/dist/{SYRFVSLH-cVmYtx36.mjs → SYRFVSLH-B6m278Vb.mjs} +18 -17
  56. package/dist/Search.mjs +175 -161
  57. package/dist/Select.mjs +885 -847
  58. package/dist/Shape.mjs +9 -9
  59. package/dist/Slider.mjs +359 -336
  60. package/dist/Stack.mjs +22 -24
  61. package/dist/Swiper.mjs +324 -311
  62. package/dist/Table.mjs +23 -23
  63. package/dist/Tabs.mjs +250 -245
  64. package/dist/Tag.mjs +51 -49
  65. package/dist/Text.mjs +49 -47
  66. package/dist/Textarea.mjs +39 -39
  67. package/dist/TimePicker.mjs +57 -56
  68. package/dist/Toast.mjs +144 -137
  69. package/dist/Toggle.mjs +27 -24
  70. package/dist/Tooltip.mjs +115 -111
  71. package/dist/UniversalLink.mjs +16 -16
  72. package/dist/VEVQD5MH-0w9Y7Ytc.mjs +20 -0
  73. package/dist/{VGCJ63VH-B39w1tBw.mjs → VGCJ63VH-C0UPBY-5.mjs} +61 -62
  74. package/dist/VariantIcon.mjs +14 -22
  75. package/dist/WelcomeLoader.mjs +4863 -9223
  76. package/dist/WuiProvider.mjs +69 -58
  77. package/dist/X5NMLKT6-BJw3xE-K.mjs +25 -0
  78. package/dist/YV4JVR4I-DPC8mMuG.mjs +344 -0
  79. package/dist/downshift.esm-B7Jil1wW.mjs +1082 -0
  80. package/dist/{field-styles-DLIhqG_8.mjs → field-styles-BVlRlvuu.mjs} +2 -2
  81. package/dist/{hex-to-rgba-BIDK-3ab.mjs → hex-to-rgba-DU_XzKIK.mjs} +2 -2
  82. package/dist/hide-focus-rings-root-CCXdysih.mjs +15 -0
  83. package/dist/index-5HBq1O6Z.mjs +185 -0
  84. package/dist/{index-C7zM96J_.mjs → index-BaLGEKs7.mjs} +8 -8
  85. package/dist/{index-BYdkhqH4.mjs → index-CBBbX29m.mjs} +3652 -3584
  86. package/dist/index-CYmF7qCH.mjs +11 -0
  87. package/dist/index-C_k-m0Rl.mjs +36 -0
  88. package/dist/index-D8v_VJ9z.mjs +26 -0
  89. package/dist/{index-BNGGwOCo.mjs → index-DAZ1SYdj.mjs} +7 -7
  90. package/dist/{index-SbQUT2mU.mjs → index-DgSynio4.mjs} +244 -239
  91. package/dist/index-DpkNUfAS.mjs +11 -0
  92. package/dist/{index-DqBUFsqP.mjs → index-DvzWKxKE.mjs} +7 -7
  93. package/dist/{index-BJAZgeHL.mjs → index-QaLwIvZS.mjs} +8 -8
  94. package/dist/{index-BQtDgQBH.mjs → index-SQQQ4dEE.mjs} +8 -8
  95. package/dist/index-i_anpNhw.mjs +66 -0
  96. package/dist/index-wl3X6EM1.mjs +16 -0
  97. package/dist/jsx-runtime-B7I4PJ0H.mjs +613 -0
  98. package/dist/radio-group-C0fUHvam.mjs +52 -0
  99. package/dist/theme.mjs +1175 -1120
  100. package/dist/throttle-CW18pWlW.mjs +13 -0
  101. package/dist/types/components/Accordion/index.d.ts +1 -1
  102. package/dist/types/components/Accordion/styles.d.ts +2 -2
  103. package/dist/types/components/Accordion/theme.d.ts +1 -1
  104. package/dist/types/components/Alert/index.d.ts +2 -2
  105. package/dist/types/components/Alert/styles.d.ts +9 -9
  106. package/dist/types/components/Alert/theme.d.ts +4 -4
  107. package/dist/types/components/Avatar/index.d.ts +2 -3
  108. package/dist/types/components/Avatar/styles.d.ts +8 -8
  109. package/dist/types/components/Avatar/theme.d.ts +3 -3
  110. package/dist/types/components/Avatar/utils.d.ts +1 -1
  111. package/dist/types/components/Badge/index.d.ts +2 -2
  112. package/dist/types/components/Badge/styles.d.ts +5 -5
  113. package/dist/types/components/Badge/theme.d.ts +1 -1
  114. package/dist/types/components/Breadcrumb/Item.d.ts +1 -1
  115. package/dist/types/components/Breadcrumb/index.d.ts +2 -2
  116. package/dist/types/components/Breadcrumb/theme.d.ts +1 -1
  117. package/dist/types/components/Button/index.d.ts +4 -5
  118. package/dist/types/components/Button/styles.d.ts +1 -1
  119. package/dist/types/components/Button/theme.d.ts +7 -7
  120. package/dist/types/components/ButtonGroup/index.d.ts +3 -3
  121. package/dist/types/components/Card/Cover.styles.d.ts +4 -4
  122. package/dist/types/components/Card/index.d.ts +2 -3
  123. package/dist/types/components/Card/theme.d.ts +1 -1
  124. package/dist/types/components/Checkbox/index.d.ts +2 -2
  125. package/dist/types/components/Checkbox/styles.d.ts +1 -1
  126. package/dist/types/components/Checkbox/theme.d.ts +1 -1
  127. package/dist/types/components/ClearButton/index.d.ts +5 -6
  128. package/dist/types/components/ClearButton/styles.d.ts +4 -4
  129. package/dist/types/components/CloseButton/styles.d.ts +4 -4
  130. package/dist/types/components/DatePicker/index.d.ts +3 -3
  131. package/dist/types/components/DateTimePicker/index.d.ts +2 -2
  132. package/dist/types/components/DateTimePickerCommon/CustomHeader.d.ts +1 -1
  133. package/dist/types/components/DateTimePickerCommon/CustomInput.d.ts +5 -5
  134. package/dist/types/components/DateTimePickerCommon/CustomPopper.d.ts +1 -1
  135. package/dist/types/components/DateTimePickerCommon/index.d.ts +2 -2
  136. package/dist/types/components/DateTimePickerCommon/theme.d.ts +1 -1
  137. package/dist/types/components/DateTimePickerCommon/utils.d.ts +2 -2
  138. package/dist/types/components/Drawer/AssetDrawer/Header.d.ts +1 -1
  139. package/dist/types/components/Drawer/AssetDrawer/index.d.ts +1 -1
  140. package/dist/types/components/Drawer/index.d.ts +12 -12
  141. package/dist/types/components/Drawer/styles.d.ts +5 -5
  142. package/dist/types/components/Drawer/theme.d.ts +2 -2
  143. package/dist/types/components/DropdownMenu/index.d.ts +4 -4
  144. package/dist/types/components/DropdownMenu/theme.d.ts +1 -1
  145. package/dist/types/components/Field/index.d.ts +8 -8
  146. package/dist/types/components/Field/styles.d.ts +1 -1
  147. package/dist/types/components/Field/utils.d.ts +1 -1
  148. package/dist/types/components/FileDrop/FilePreview.d.ts +2 -2
  149. package/dist/types/components/FileDrop/Message.d.ts +1 -1
  150. package/dist/types/components/FileDrop/index.d.ts +20 -20
  151. package/dist/types/components/FileDrop/theme.d.ts +1 -1
  152. package/dist/types/components/FileUpload/index.d.ts +13 -13
  153. package/dist/types/components/Files/index.d.ts +5 -5
  154. package/dist/types/components/Files/types.d.ts +1 -1
  155. package/dist/types/components/Hint/index.d.ts +1 -2
  156. package/dist/types/components/Hint/theme.d.ts +1 -1
  157. package/dist/types/components/Icon/index.d.ts +3 -3
  158. package/dist/types/components/Icon/styles.d.ts +3 -3
  159. package/dist/types/components/Icon/theme.d.ts +3 -3
  160. package/dist/types/components/Icons/Sun/content.json.d.ts +2 -1
  161. package/dist/types/components/Icons/index.d.ts +2 -2
  162. package/dist/types/components/IconsFont/index.d.ts +2 -3
  163. package/dist/types/components/IconsFont/styles.d.ts +1 -1
  164. package/dist/types/components/InputText/index.d.ts +1 -1
  165. package/dist/types/components/InputText/styles.d.ts +1 -1
  166. package/dist/types/components/Label/index.d.ts +2 -3
  167. package/dist/types/components/Label/theme.d.ts +1 -1
  168. package/dist/types/components/Link/index.d.ts +5 -5
  169. package/dist/types/components/Link/styles.d.ts +4 -4
  170. package/dist/types/components/Link/theme.d.ts +1 -1
  171. package/dist/types/components/Loader/index.d.ts +1 -1
  172. package/dist/types/components/Loader/styles.d.ts +4 -4
  173. package/dist/types/components/Loader/theme.d.ts +4 -4
  174. package/dist/types/components/Logo/Solutions.d.ts +1 -2
  175. package/dist/types/components/Logo/Symbol.d.ts +1 -2
  176. package/dist/types/components/Logo/Wui.d.ts +1 -2
  177. package/dist/types/components/Logo/index.d.ts +5 -5
  178. package/dist/types/components/Modal/Assets/Backdrop.d.ts +5 -6
  179. package/dist/types/components/Modal/Assets/Iframe.d.ts +1 -2
  180. package/dist/types/components/Modal/Assets/index.d.ts +9 -9
  181. package/dist/types/components/Modal/Assets/styles.d.ts +8 -8
  182. package/dist/types/components/Modal/Close.d.ts +3 -4
  183. package/dist/types/components/Modal/Content.d.ts +4 -5
  184. package/dist/types/components/Modal/Footer.d.ts +1 -1
  185. package/dist/types/components/Modal/Header.d.ts +2 -2
  186. package/dist/types/components/Modal/index.d.ts +17 -17
  187. package/dist/types/components/Modal/styles.d.ts +7 -7
  188. package/dist/types/components/Modal/theme.d.ts +2 -2
  189. package/dist/types/components/Pagination/index.d.ts +2 -2
  190. package/dist/types/components/Pagination/theme.d.ts +1 -1
  191. package/dist/types/components/Pagination/utils.d.ts +1 -1
  192. package/dist/types/components/Picker/index.d.ts +1 -1
  193. package/dist/types/components/Picker/styles.d.ts +1 -1
  194. package/dist/types/components/Popover/Arrow.d.ts +1 -2
  195. package/dist/types/components/Popover/Content.d.ts +2 -3
  196. package/dist/types/components/Popover/Popover.d.ts +4 -5
  197. package/dist/types/components/Popover/PopoverHover.d.ts +3 -4
  198. package/dist/types/components/Popover/Trigger.d.ts +1 -1
  199. package/dist/types/components/Popover/styles.d.ts +4 -4
  200. package/dist/types/components/Popover/theme.d.ts +1 -1
  201. package/dist/types/components/Popover/usePopover.d.ts +6 -6
  202. package/dist/types/components/Radio/index.d.ts +3 -3
  203. package/dist/types/components/Radio/styles.d.ts +5 -5
  204. package/dist/types/components/Radio/theme.d.ts +1 -1
  205. package/dist/types/components/RadioGroup/index.d.ts +2 -2
  206. package/dist/types/components/RadioTab/index.d.ts +3 -3
  207. package/dist/types/components/RadioTab/styles.d.ts +3 -9
  208. package/dist/types/components/RadioTab/theme.d.ts +1 -1
  209. package/dist/types/components/Search/index.d.ts +5 -5
  210. package/dist/types/components/Select/index.d.ts +11 -11
  211. package/dist/types/components/Select/styles.d.ts +6 -6
  212. package/dist/types/components/Select/utils.d.ts +11 -7
  213. package/dist/types/components/Shape/index.d.ts +1 -1
  214. package/dist/types/components/Shape/styles.d.ts +3 -3
  215. package/dist/types/components/Slider/Range.d.ts +3 -3
  216. package/dist/types/components/Slider/index.d.ts +2 -2
  217. package/dist/types/components/Slider/styles.d.ts +16 -16
  218. package/dist/types/components/Slider/theme.d.ts +1 -1
  219. package/dist/types/components/Stack/index.d.ts +1 -1
  220. package/dist/types/components/Swiper/index.d.ts +17 -18
  221. package/dist/types/components/Swiper/styles.d.ts +56 -56
  222. package/dist/types/components/Swiper/theme.d.ts +1 -1
  223. package/dist/types/components/System/index.d.ts +14 -14
  224. package/dist/types/components/Table/index.d.ts +6 -7
  225. package/dist/types/components/Table/styles.d.ts +1 -1
  226. package/dist/types/components/Table/theme.d.ts +1 -1
  227. package/dist/types/components/Tabs/ActiveBar.d.ts +5 -5
  228. package/dist/types/components/Tabs/TabList.d.ts +4 -4
  229. package/dist/types/components/Tabs/TabPanel.d.ts +2 -2
  230. package/dist/types/components/Tabs/styles.d.ts +2 -2
  231. package/dist/types/components/Tabs/theme.d.ts +2 -2
  232. package/dist/types/components/Tag/index.d.ts +2 -3
  233. package/dist/types/components/Tag/styles.d.ts +1 -1
  234. package/dist/types/components/Tag/theme.d.ts +3 -3
  235. package/dist/types/components/Text/index.d.ts +2 -2
  236. package/dist/types/components/Textarea/index.d.ts +1 -1
  237. package/dist/types/components/Textarea/theme.d.ts +1 -1
  238. package/dist/types/components/TimePicker/index.d.ts +2 -2
  239. package/dist/types/components/Toast/Growl.d.ts +1 -1
  240. package/dist/types/components/Toast/Snackbar.d.ts +1 -1
  241. package/dist/types/components/Toast/ToastWrapper.d.ts +5 -5
  242. package/dist/types/components/Toast/index.d.ts +6 -6
  243. package/dist/types/components/Toast/styles.d.ts +16 -16
  244. package/dist/types/components/Toast/theme.d.ts +2 -2
  245. package/dist/types/components/Toast/utils.d.ts +13 -13
  246. package/dist/types/components/Toggle/index.d.ts +3 -3
  247. package/dist/types/components/Toggle/styles.d.ts +5 -4
  248. package/dist/types/components/Toggle/theme.d.ts +6 -6
  249. package/dist/types/components/Tooltip/index.d.ts +2 -2
  250. package/dist/types/components/Tooltip/styles.d.ts +1 -1
  251. package/dist/types/components/Tooltip/theme.d.ts +1 -1
  252. package/dist/types/components/VariantIcon/index.d.ts +1 -1
  253. package/dist/types/components/VariantIcon/styles.d.ts +1 -1
  254. package/dist/types/components/VariantIcon/theme.d.ts +3 -3
  255. package/dist/types/components/WuiProvider/font.d.ts +3 -5
  256. package/dist/types/components/WuiProvider/index.d.ts +1 -1
  257. package/dist/types/theme/colors.d.ts +3 -11
  258. package/dist/types/theme/dark.d.ts +1 -1
  259. package/dist/types/theme/defaultFields.d.ts +10 -10
  260. package/dist/types/theme/fonts.d.ts +5 -5
  261. package/dist/types/theme/index.d.ts +31 -31
  262. package/dist/types/theme/screens.d.ts +1 -1
  263. package/dist/types/theme/space.d.ts +1 -1
  264. package/dist/types/theme/typography.d.ts +1 -1
  265. package/dist/types/utils/field-styles.d.ts +6 -6
  266. package/dist/types/utils/index.d.ts +2 -2
  267. package/dist/types/utils/ts-utils.d.ts +1 -1
  268. package/dist/types/utils/use-copy-text.d.ts +1 -1
  269. package/dist/types/utils/use-create-portal.d.ts +1 -1
  270. package/dist/types/utils/use-viewport.d.ts +2 -2
  271. package/dist/types/utils/wrap-children.d.ts +1 -1
  272. package/dist/{use-fork-ref-CUZErtAC.mjs → use-fork-ref-DvaCTfQ_.mjs} +4 -3
  273. package/dist/use-viewport-CWpjoHXy.mjs +16 -0
  274. package/dist/utils.mjs +96 -85
  275. package/dist/wrap-children-DBSD-X5-.mjs +9 -0
  276. package/package.json +9 -36
  277. package/dist/AXB53BZF-CGoc4K3d.mjs +0 -25
  278. package/dist/ITI7HKP4-BONrZ9Pq.mjs +0 -473
  279. package/dist/KUU7WJ55-3sP-w1F1.mjs +0 -61
  280. package/dist/LVA2YJMS-qFC9J-lt.mjs +0 -1479
  281. package/dist/MTZPJQMC-C0Xe_WK4.mjs +0 -13
  282. package/dist/NLEBE274-C94QU78N.mjs +0 -84
  283. package/dist/P2CTZE2T-YPes1GXe.mjs +0 -297
  284. package/dist/P4IRICAX-DzXqUYe-.mjs +0 -37
  285. package/dist/QYJ6MIDR-BLLqyXdd.mjs +0 -97
  286. package/dist/VEVQD5MH-ZMnHV8ZJ.mjs +0 -20
  287. package/dist/X5NMLKT6-uFSu0Lii.mjs +0 -25
  288. package/dist/YV4JVR4I-BGfUf3Nu.mjs +0 -341
  289. package/dist/downshift.esm-CEHW4VDy.mjs +0 -1085
  290. package/dist/hide-focus-rings-root-BNyva1yb.mjs +0 -14
  291. package/dist/index-BDeIsk2X.mjs +0 -184
  292. package/dist/index-BRDOakbf.mjs +0 -11
  293. package/dist/index-BpRjq7lj.mjs +0 -11
  294. package/dist/index-BrfXjmHY.mjs +0 -36
  295. package/dist/index-CExLVjET.mjs +0 -26
  296. package/dist/index-DEJJvyGk.mjs +0 -66
  297. package/dist/index-u1oHKa7X.mjs +0 -16
  298. package/dist/radio-group-CGC6DTFJ.mjs +0 -51
  299. package/dist/throttle-BDBzFeFj.mjs +0 -13
  300. package/dist/use-viewport-m3glsbna.mjs +0 -16
  301. package/dist/wrap-children-aq69jtFP.mjs +0 -12
@@ -1,88 +1,109 @@
1
1
  "use client";
2
- import n, { useState as x, useRef as z, useEffect as v } from "react";
3
- import { c as _ } from "./create-event-rXDe5aCQ.mjs";
4
- import D from "@xstyled/styled-components";
5
- import { shouldForwardProp as h, forwardRef as C } from "./System.mjs";
6
- import { Button as N } from "./Button.mjs";
7
- import { getFileIcon as O, getFileName as P, getFileSize as K } from "./Files.mjs";
8
- import { Tag as M } from "./Tag.mjs";
9
- import { Box as X } from "./Box.mjs";
10
- const Y = D.inputBox.withConfig({ shouldForwardProp: h })`
2
+ import { j as e } from "./jsx-runtime-B7I4PJ0H.mjs";
3
+ import { useState as A, useRef as D, useEffect as _ } from "react";
4
+ import { Box as N } from "./Box.mjs";
5
+ import { Button as O } from "./Button.mjs";
6
+ import { getFileIcon as P, getFileName as K, getFileSize as M } from "./Files.mjs";
7
+ import { shouldForwardProp as X, forwardRef as Y } from "./System.mjs";
8
+ import { Tag as Z } from "./Tag.mjs";
9
+ import { c as b } from "./create-event-rXDe5aCQ.mjs";
10
+ import q from "@xstyled/styled-components";
11
+ const G = q.inputBox.withConfig({ shouldForwardProp: X })`
11
12
  display: none;
12
- `, Z = 2e6, q = "*/*", A = (t) => Array.isArray(t) ? t : t ? [t] : [], G = ({ file: t, onRemove: m }) => {
13
- const l = O(t), o = P(t), u = K(t);
14
- return /* @__PURE__ */ n.createElement(M, { "data-id": o, key: o, mr: "sm", mt: "sm", onRemove: m }, /* @__PURE__ */ n.createElement(l, { size: "md" }), o, u && /* @__PURE__ */ n.createElement(X, { color: "beige-60" }, "(", u, ")"));
15
- }, H = C(
13
+ `, H = 2e6, J = "*/*", d = (r) => Array.isArray(r) ? r : r ? [r] : [], Q = ({ file: r, onRemove: f }) => {
14
+ const a = P(r), o = K(r), j = M(r);
15
+ return /* @__PURE__ */ e.jsxs(Z, { "data-id": o, mr: "sm", mt: "sm", onRemove: f, children: [
16
+ /* @__PURE__ */ e.jsx(a, { size: "md" }),
17
+ o,
18
+ j && /* @__PURE__ */ e.jsxs(N, { color: "beige-60", children: [
19
+ "(",
20
+ j,
21
+ ")"
22
+ ] })
23
+ ] }, o);
24
+ }, V = Y(
16
25
  ({
17
- accept: t = q,
18
- children: m,
19
- dataTestId: l,
26
+ accept: r = J,
27
+ children: f,
28
+ dataTestId: a,
20
29
  disabled: o,
21
30
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
22
- draggable: u,
23
- handleAddFile: y,
24
- handleRemoveFile: g,
25
- maxSize: I = Z,
26
- multiple: R,
27
- name: f,
31
+ draggable: j,
32
+ handleAddFile: u,
33
+ handleRemoveFile: x,
34
+ maxSize: g = H,
35
+ multiple: L,
36
+ name: E,
28
37
  onBlur: i,
29
- onChange: p,
38
+ onChange: n,
30
39
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
31
- onError: J,
32
- preview: w = G,
33
- value: E = [],
34
- ...S
35
- }, s) => {
36
- const [c, F] = x(A(E)), U = z();
37
- v(() => {
38
- F(A(E));
39
- }, [E]), v(() => () => {
40
- c && c.map((e) => e instanceof File ? URL.revokeObjectURL(e.preview) : e);
40
+ onError: W,
41
+ preview: v = Q,
42
+ value: w = [],
43
+ ...k
44
+ }, p) => {
45
+ const [c, y] = A(d(w)), F = D();
46
+ _(() => {
47
+ y(d(w));
48
+ }, [w]), _(() => () => {
49
+ c && c.forEach((t) => {
50
+ t instanceof File && t.preview && URL.revokeObjectURL(t.preview);
51
+ });
41
52
  }, [c]);
42
- const T = (e) => {
43
- let r = Array.from(e.target.files).map(
44
- (a) => (a.preview = URL.createObjectURL(a), a)
53
+ const S = (t) => {
54
+ let s = Array.from(t.target.files || []).map(
55
+ (m) => (m.preview = URL.createObjectURL(m), m)
45
56
  );
46
- F(r), r.length === 1 && (r = r[0]);
47
- const d = _({ name: f, value: r });
48
- p && p(d), y && y(r), i && i();
49
- }, L = (e) => {
50
- const r = c.filter((j) => j !== e), d = R ? r : void 0;
51
- F(r);
52
- const a = _({ name: f, value: d });
53
- p && p(a), g && g(e), i && i();
54
- }, k = () => {
55
- U.current.click();
56
- }, b = c.map((e) => e instanceof File ? e.preview : void 0).join("");
57
- return /* @__PURE__ */ n.createElement(n.Fragment, null, m ? m({ openFile: k, disabled: o, files: c, onRemoveFile: L }) : /* @__PURE__ */ n.createElement(N, { disabled: o, onClick: k }, "Upload file"), /* @__PURE__ */ n.createElement("br", null), /* @__PURE__ */ n.createElement(
58
- Y,
59
- {
60
- accept: t,
61
- "data-testid": l,
62
- disabled: o,
63
- key: b,
64
- maxSize: I,
65
- multiple: R,
66
- name: f,
67
- onBlur: i,
68
- onChange: T,
69
- ref: (e) => {
70
- U.current = e, typeof s == "function" ? s(e) : s != null && s.current && (s.current = e);
57
+ y(s), s.length === 1 && (s = s[0]);
58
+ const U = b({ name: E, value: s });
59
+ n == null || n(U), u == null || u(s), i == null || i();
60
+ }, R = (t) => {
61
+ const s = c.filter((z) => z !== t), U = L ? s : void 0;
62
+ y(s);
63
+ const m = b({ name: E, value: U });
64
+ n == null || n(m), x == null || x(t), i == null || i();
65
+ }, I = () => {
66
+ F.current && F.current.click();
67
+ }, T = c.map((t) => t instanceof File ? t.preview : void 0).join("");
68
+ return /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
69
+ f ? f({
70
+ disabled: !!o,
71
+ files: c,
72
+ onRemoveFile: R,
73
+ openFile: I
74
+ }) : /* @__PURE__ */ e.jsx(O, { disabled: o, onClick: I, children: "Upload file" }),
75
+ /* @__PURE__ */ e.jsx("br", {}),
76
+ /* @__PURE__ */ e.jsx(
77
+ G,
78
+ {
79
+ accept: r,
80
+ "data-testid": a,
81
+ disabled: o,
82
+ maxSize: g,
83
+ multiple: L,
84
+ name: E,
85
+ onBlur: i,
86
+ onChange: S,
87
+ ref: (t) => {
88
+ F.current = t, typeof p == "function" ? p(t) : p != null && p.current && (p.current = t);
89
+ },
90
+ ...k,
91
+ type: "file"
71
92
  },
72
- ...S,
73
- type: "file"
74
- }
75
- ), w && c.map((e) => /* @__PURE__ */ n.createElement(
76
- w,
77
- {
78
- file: e,
79
- key: e instanceof File ? e.name : e,
80
- onRemove: () => L(e)
81
- }
82
- )));
93
+ T
94
+ ),
95
+ v && c.map((t) => /* @__PURE__ */ e.jsx(
96
+ v,
97
+ {
98
+ file: t,
99
+ onRemove: () => R(t)
100
+ },
101
+ t instanceof File ? t.name : t
102
+ ))
103
+ ] });
83
104
  }
84
105
  );
85
- H.displayName = "FileUpload";
106
+ V.displayName = "FileUpload";
86
107
  export {
87
- H as FileUpload
108
+ V as FileUpload
88
109
  };
package/dist/Files.mjs CHANGED
@@ -1,9 +1,9 @@
1
1
  "use client";
2
- import { f as o } from "./format-bytes-gST0dTWd.mjs";
3
- import "react";
2
+ import "./jsx-runtime-B7I4PJ0H.mjs";
4
3
  import "./Icon.mjs";
5
- import { A as e, C as t, M as n, V as m, a as c, Z as s, P as r, X as d, b as l, D as g, c as u, d as f } from "./index-DEJJvyGk.mjs";
6
- const x = {
4
+ import { A as p, C as o, M as t, V as n, a as m, D as s, X as c, P as r, b as d, c as l, d as g, Z as u } from "./index-i_anpNhw.mjs";
5
+ import { f as x } from "./format-bytes-gST0dTWd.mjs";
6
+ const f = {
7
7
  "7z": "application/x-7z-compressed",
8
8
  aac: "audio/aac",
9
9
  aif: "audio/x-aiff",
@@ -69,62 +69,62 @@ const x = {
69
69
  xwd: "image/x-xwindowdump",
70
70
  zip: "application/zip"
71
71
  };
72
- function v(i) {
73
- return i.split("?")[0];
74
- }
75
- function b(i) {
76
- return typeof i == "string" ? v(i).split("/").pop() : i.name;
77
- }
78
- function w(i) {
79
- if (typeof i == "string") {
80
- const p = b(i).split(".").pop();
81
- return x[p] || null;
82
- } else
83
- return i.type;
84
- }
85
- function j(i) {
86
- return i instanceof File && i.size ? o(i.size, 0) : null;
87
- }
88
- function q(i, p) {
89
- const a = w(i);
90
- if (!p && !a)
91
- return e;
92
- if (p === "image" || a && a.startsWith("image/"))
72
+ function j(i, e) {
73
+ const a = b(i);
74
+ if (!e && !a)
75
+ return p;
76
+ if (e === "image" || a && a.startsWith("image/"))
77
+ return o;
78
+ if (e === "audio" || a && a.startsWith("audio/"))
93
79
  return t;
94
- if (p === "audio" || a && a.startsWith("audio/"))
80
+ if (e === "video" || a && a.startsWith("video/"))
95
81
  return n;
96
- if (p === "video" || a && a.startsWith("video/"))
97
- return m;
98
82
  switch (a) {
99
- case "application/pdf":
100
- return f;
101
- case "application/msword":
83
+ case "application/gzip":
84
+ case "application/vnd.rar":
85
+ case "application/x-7z-compressed":
86
+ case "application/x-bzip":
87
+ case "application/x-bzip2":
88
+ case "application/zip":
102
89
  return u;
103
- case "application/vnd.openxmlformats-officedocument.wordprocessingml.document":
90
+ case "application/msword":
104
91
  return g;
105
- case "application/vnd.ms-excel":
92
+ case "application/pdf":
106
93
  return l;
107
- case "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":
94
+ case "application/vnd.ms-excel":
108
95
  return d;
109
96
  case "application/vnd.ms-powerpoint":
110
97
  case "application/vnd.openxmlformats-officedocument.presentationml.presentation":
111
98
  return r;
112
- case "application/zip":
113
- case "application/x-bzip":
114
- case "application/x-bzip2":
115
- case "application/x-7z-compressed":
116
- case "application/gzip":
117
- case "application/vnd.rar":
99
+ case "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":
100
+ return c;
101
+ case "application/vnd.openxmlformats-officedocument.wordprocessingml.document":
118
102
  return s;
119
103
  case "text/csv":
120
- return c;
104
+ return m;
121
105
  default:
122
- return e;
106
+ return p;
123
107
  }
124
108
  }
109
+ function v(i) {
110
+ return typeof i == "string" ? w(i).split("/").pop() : i.name;
111
+ }
112
+ function q(i) {
113
+ return i instanceof File && i.size ? x(i.size, 0) : null;
114
+ }
115
+ function b(i) {
116
+ if (typeof i == "string") {
117
+ const e = v(i), a = e ? e.split(".").pop() : void 0;
118
+ return a && f[a] || null;
119
+ } else
120
+ return i.type;
121
+ }
122
+ function w(i) {
123
+ return i.split("?")[0];
124
+ }
125
125
  export {
126
- q as getFileIcon,
127
- b as getFileName,
128
- j as getFileSize,
129
- w as getMimeType
126
+ j as getFileIcon,
127
+ v as getFileName,
128
+ q as getFileSize,
129
+ b as getMimeType
130
130
  };
package/dist/Flex.mjs CHANGED
@@ -1,22 +1,22 @@
1
1
  "use client";
2
- import n from "react";
3
- import { forwardRef as s } from "./System.mjs";
4
- import { Box as p } from "./Box.mjs";
5
- const d = s(
6
- ({ align: e, basis: t, dataTestId: r, direction: l, grow: f, justify: i, shrink: o, wrap: a, ...x }, m) => /* @__PURE__ */ n.createElement(
7
- p,
2
+ import { j as m } from "./jsx-runtime-B7I4PJ0H.mjs";
3
+ import { Box as n } from "./Box.mjs";
4
+ import { forwardRef as p } from "./System.mjs";
5
+ const d = p(
6
+ ({ align: e, basis: t, dataTestId: r, direction: i, grow: o, justify: s, shrink: x, wrap: f, ...l }, a) => /* @__PURE__ */ m.jsx(
7
+ n,
8
8
  {
9
9
  alignItems: e,
10
10
  "data-testid": r,
11
11
  display: "flex",
12
12
  flexBasis: t,
13
- flexDirection: l,
14
- flexGrow: f,
15
- flexShrink: o,
16
- flexWrap: a,
17
- justifyContent: i,
18
- ref: m,
19
- ...x
13
+ flexDirection: i,
14
+ flexGrow: o,
15
+ flexShrink: x,
16
+ flexWrap: f,
17
+ justifyContent: s,
18
+ ref: a,
19
+ ...l
20
20
  }
21
21
  )
22
22
  );
package/dist/Grid.mjs CHANGED
@@ -1,57 +1,57 @@
1
1
  "use client";
2
- import a from "react";
2
+ import { j as s } from "./jsx-runtime-B7I4PJ0H.mjs";
3
3
  import { Box as m } from "./Box.mjs";
4
- import { forwardRef as n } from "./System.mjs";
5
- const C = n(
6
- ({ area: r, column: t, dataTestId: e, row: o, ...i }, d) => /* @__PURE__ */ a.createElement(
4
+ import { forwardRef as a } from "./System.mjs";
5
+ const j = a(
6
+ ({ area: r, column: t, dataTestId: o, row: i, ...e }, d) => /* @__PURE__ */ s.jsx(
7
7
  m,
8
8
  {
9
- "data-testid": e,
9
+ "data-testid": o,
10
10
  gridArea: r,
11
11
  gridColumn: t,
12
12
  ref: d,
13
- row: o,
14
- ...i
13
+ row: i,
14
+ ...e
15
15
  }
16
16
  )
17
- ), R = n(
17
+ ), w = a(
18
18
  ({
19
19
  area: r,
20
20
  autoColumns: t,
21
- autoFlow: e,
22
- autoRows: o,
23
- column: i,
21
+ autoFlow: o,
22
+ autoRows: i,
23
+ column: e,
24
24
  columnGap: d,
25
- dataTestId: s,
25
+ dataTestId: n,
26
26
  gap: g,
27
- row: l,
28
- rowGap: u,
27
+ row: u,
28
+ rowGap: l,
29
29
  templateAreas: p,
30
- templateColumns: c,
31
- templateRows: f,
32
- ...A
33
- }, w) => /* @__PURE__ */ a.createElement(
30
+ templateColumns: x,
31
+ templateRows: A,
32
+ ...c
33
+ }, f) => /* @__PURE__ */ s.jsx(
34
34
  m,
35
35
  {
36
36
  columnGap: d,
37
- "data-testid": s,
37
+ "data-testid": n,
38
38
  display: "grid",
39
39
  gap: g,
40
40
  gridArea: r,
41
41
  gridAutoColumns: t,
42
- gridAutoFlow: e,
43
- gridAutoRows: o,
44
- gridColumn: i,
45
- gridRow: l,
42
+ gridAutoFlow: o,
43
+ gridAutoRows: i,
44
+ gridColumn: e,
45
+ gridRow: u,
46
46
  gridTemplateAreas: p,
47
- gridTemplateColumns: c,
48
- gridTemplateRows: f,
49
- ref: w,
50
- rowGap: u,
51
- ...A
47
+ gridTemplateColumns: x,
48
+ gridTemplateRows: A,
49
+ ref: f,
50
+ rowGap: l,
51
+ ...c
52
52
  }
53
53
  )
54
- ), G = Object.assign(R, { Item: C });
54
+ ), G = Object.assign(w, { Item: j });
55
55
  export {
56
56
  G as Grid
57
57
  };
package/dist/Hint.mjs CHANGED
@@ -1,21 +1,21 @@
1
1
  "use client";
2
- import a from "react";
3
- import d, { css as l, th as e } from "@xstyled/styled-components";
4
- import { forwardRef as m } from "./System.mjs";
5
- const i = d.divBox(
2
+ import { j as m } from "./jsx-runtime-B7I4PJ0H.mjs";
3
+ import { forwardRef as d } from "./System.mjs";
4
+ import a, { th as s, css as l } from "@xstyled/styled-components";
5
+ const i = a.divBox(
6
6
  ({ variant: t }) => l`
7
- ${e("hints.default")};
8
- ${t && e(`hints.${t}`)};
7
+ ${s("hints.default")};
8
+ ${t && s(`hints.${t}`)};
9
9
  margin-top: xs;
10
10
  display: flex;
11
11
  align-items: center;
12
12
  `
13
- ), c = m(
14
- ({ children: t, dataTestId: n, variant: s, ...o }, r) => /* @__PURE__ */ a.createElement(i, { "data-testid": n, ref: r, variant: s, ...o }, t)
13
+ ), p = d(
14
+ ({ children: t, dataTestId: e, variant: n, ...o }, r) => /* @__PURE__ */ m.jsx(i, { "data-testid": e, ref: r, variant: n, ...o, children: t })
15
15
  );
16
- c.displayName = "Hint";
17
- const x = i;
16
+ p.displayName = "Hint";
17
+ const u = i;
18
18
  export {
19
- c as Hint,
20
- x as StyledHint
19
+ p as Hint,
20
+ u as StyledHint
21
21
  };