@loadsmart/loadsmart-ui 7.3.3 → 7.5.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 (459) hide show
  1. package/dist/DragDropFile.context-D-EBrXnw.js +2 -0
  2. package/dist/DragDropFile.context-D-EBrXnw.js.map +1 -0
  3. package/dist/DragDropFile.context-jVTIKfj5.mjs +29 -0
  4. package/dist/DragDropFile.context-jVTIKfj5.mjs.map +1 -0
  5. package/dist/addons/Theme/register.d.ts +1 -0
  6. package/dist/common/BackButton/BackButton.d.ts +4 -5
  7. package/dist/common/BackButton/index.d.ts +2 -2
  8. package/dist/common/CloseButton/CloseButton.d.ts +6 -7
  9. package/dist/common/CloseButton/index.d.ts +2 -2
  10. package/dist/common/SelectionWrapper.d.ts +14 -14
  11. package/dist/components/Accordion/Accordion.context.d.ts +10 -10
  12. package/dist/components/Accordion/Accordion.d.ts +19 -19
  13. package/dist/components/Accordion/Accordion.stories.d.ts +8 -8
  14. package/dist/components/Accordion/Accordion.test.d.ts +1 -1
  15. package/dist/components/Accordion/index.d.ts +2 -2
  16. package/dist/components/Banner/Banner.d.ts +25 -25
  17. package/dist/components/Banner/Banner.stories.d.ts +107 -106
  18. package/dist/components/Banner/Banner.test.d.ts +1 -1
  19. package/dist/components/Banner/index.d.ts +2 -2
  20. package/dist/components/Breadcrumbs/Breadbrumbs.test.d.ts +1 -1
  21. package/dist/components/Breadcrumbs/Breadcrumb.d.ts +8 -8
  22. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +10 -10
  23. package/dist/components/Breadcrumbs/Breadcrumbs.stories.d.ts +5 -4
  24. package/dist/components/Breadcrumbs/index.d.ts +3 -3
  25. package/dist/components/Button/Button.d.ts +21 -22
  26. package/dist/components/Button/Button.stories.d.ts +33 -32
  27. package/dist/components/Button/Button.test.d.ts +1 -1
  28. package/dist/components/Button/index.d.ts +2 -2
  29. package/dist/components/Calendar/Calendar.d.ts +9 -10
  30. package/dist/components/Calendar/Calendar.helpers.d.ts +2 -2
  31. package/dist/components/Calendar/Calendar.stories.d.ts +21 -21
  32. package/dist/components/Calendar/Calendar.test.d.ts +1 -1
  33. package/dist/components/Calendar/Calendar.types.d.ts +63 -63
  34. package/dist/components/Calendar/Date.helper.d.ts +214 -214
  35. package/dist/components/Calendar/Date.helper.test.d.ts +1 -1
  36. package/dist/components/Calendar/DateFormat.helper.d.ts +35 -35
  37. package/dist/components/Calendar/DateFormat.helper.test.d.ts +1 -1
  38. package/dist/components/Calendar/Month.helper.d.ts +58 -58
  39. package/dist/components/Calendar/Month.helper.test.d.ts +1 -1
  40. package/dist/components/Calendar/PickerModeToggle.d.ts +5 -6
  41. package/dist/components/Calendar/Pickers/DayPicker.d.ts +9 -10
  42. package/dist/components/Calendar/Pickers/DayPicker.test.d.ts +1 -1
  43. package/dist/components/Calendar/Pickers/MonthPicker.d.ts +3 -4
  44. package/dist/components/Calendar/Pickers/MonthPicker.test.d.ts +1 -1
  45. package/dist/components/Calendar/Pickers/PickerButton.d.ts +4 -5
  46. package/dist/components/Calendar/Pickers/YearPicker.d.ts +3 -4
  47. package/dist/components/Calendar/Pickers/YearPicker.test.d.ts +1 -1
  48. package/dist/components/Calendar/index.d.ts +9 -9
  49. package/dist/components/Calendar/useCalendar.d.ts +19 -19
  50. package/dist/components/Calendar/usePickerMode.d.ts +3 -3
  51. package/dist/components/Card/Card.d.ts +16 -16
  52. package/dist/components/Card/Card.stories.d.ts +8 -8
  53. package/dist/components/Card/Card.test.d.ts +1 -1
  54. package/dist/components/Card/CardTitle.d.ts +8 -8
  55. package/dist/components/Card/index.d.ts +2 -2
  56. package/dist/components/Checkbox/Checkbox.d.ts +10 -10
  57. package/dist/components/Checkbox/Checkbox.stories.d.ts +8 -8
  58. package/dist/components/Checkbox/Checkbox.test.d.ts +1 -1
  59. package/dist/components/Checkbox/index.d.ts +2 -2
  60. package/dist/components/DatePicker/DatePicker.d.ts +13 -13
  61. package/dist/components/DatePicker/DatePicker.stories.d.ts +22 -23
  62. package/dist/components/DatePicker/DatePicker.test.d.ts +1 -1
  63. package/dist/components/DatePicker/DatePicker.types.d.ts +27 -27
  64. package/dist/components/DatePicker/DateRangePicker.d.ts +4 -5
  65. package/dist/components/DatePicker/DateRangePicker.stories.d.ts +21 -22
  66. package/dist/components/DatePicker/DateRangePicker.test.d.ts +1 -1
  67. package/dist/components/DatePicker/index.d.ts +3 -3
  68. package/dist/components/DatePicker/useDatePicker.d.ts +604 -591
  69. package/dist/components/DatePicker/useDateRangePicker.d.ts +905 -885
  70. package/dist/components/Dialog/Dialog.d.ts +37 -37
  71. package/dist/components/Dialog/Dialog.stories.d.ts +67 -67
  72. package/dist/components/Dialog/Dialog.test.d.ts +1 -1
  73. package/dist/components/Dialog/index.d.ts +4 -4
  74. package/dist/components/Dialog/useDialog.d.ts +12 -12
  75. package/dist/components/DragDropFile/DragDropFile.context.d.ts +5 -5
  76. package/dist/components/DragDropFile/DragDropFile.d.ts +7 -8
  77. package/dist/components/DragDropFile/DragDropFile.stories.d.ts +33 -33
  78. package/dist/components/DragDropFile/components/DropZone.d.ts +3 -4
  79. package/dist/components/DragDropFile/components/DropZone.test.d.ts +1 -1
  80. package/dist/components/DragDropFile/components/FileItem.d.ts +3 -4
  81. package/dist/components/DragDropFile/components/FileList.d.ts +3 -4
  82. package/dist/components/DragDropFile/components/FileList.test.d.ts +1 -1
  83. package/dist/components/DragDropFile/components/Wrapper.d.ts +7 -7
  84. package/dist/components/DragDropFile/index.d.ts +3 -3
  85. package/dist/components/DragDropFile/mocks.d.ts +9 -9
  86. package/dist/components/DragDropFile/styles.d.ts +11 -11
  87. package/dist/components/DragDropFile/types.d.ts +71 -71
  88. package/dist/components/Drawer/Drawer.d.ts +27 -28
  89. package/dist/components/Drawer/Drawer.stories.d.ts +6 -6
  90. package/dist/components/Drawer/Drawer.test.d.ts +1 -1
  91. package/dist/components/Drawer/index.d.ts +3 -3
  92. package/dist/components/Dropdown/Dropdown.context.d.ts +3 -4
  93. package/dist/components/Dropdown/Dropdown.d.ts +47 -47
  94. package/dist/components/Dropdown/Dropdown.fixtures.d.ts +12 -12
  95. package/dist/components/Dropdown/Dropdown.stories.d.ts +12 -12
  96. package/dist/components/Dropdown/Dropdown.test.d.ts +1 -1
  97. package/dist/components/Dropdown/Dropdown.types.d.ts +49 -49
  98. package/dist/components/Dropdown/DropdownMenu.d.ts +8 -8
  99. package/dist/components/Dropdown/DropdownTrigger.d.ts +21 -22
  100. package/dist/components/Dropdown/index.d.ts +6 -6
  101. package/dist/components/Dropdown/useDropdown.d.ts +14 -14
  102. package/dist/components/Dropdown/useDropdown.test.d.ts +1 -1
  103. package/dist/components/EmptyState/EmptyState.d.ts +7 -7
  104. package/dist/components/EmptyState/EmptyState.mocks.d.ts +7 -7
  105. package/dist/components/EmptyState/EmptyState.stories.d.ts +32 -32
  106. package/dist/components/EmptyState/EmptyState.test.d.ts +1 -1
  107. package/dist/components/EmptyState/EmptyState.types.d.ts +22 -22
  108. package/dist/components/EmptyState/EmptyStateWithIcon.d.ts +4 -4
  109. package/dist/components/EmptyState/EmptyStateWithIllustration.d.ts +4 -4
  110. package/dist/components/EmptyState/Illustration.d.ts +4 -4
  111. package/dist/components/EmptyState/index.d.ts +3 -3
  112. package/dist/components/ErrorMessage/ErrorMessage.d.ts +5 -5
  113. package/dist/components/ErrorMessage/ErrorMessage.stories.d.ts +13 -13
  114. package/dist/components/ErrorMessage/ErrorMessage.test.d.ts +1 -1
  115. package/dist/components/ErrorMessage/index.d.ts +2 -2
  116. package/dist/components/HighlightMatch/HighlightMatch.d.ts +7 -7
  117. package/dist/components/HighlightMatch/HighlightMatch.stories.d.ts +5 -5
  118. package/dist/components/HighlightMatch/HighlightMatch.test.d.ts +1 -1
  119. package/dist/components/HighlightMatch/index.d.ts +2 -2
  120. package/dist/components/Icon/Icon.d.ts +27 -28
  121. package/dist/components/Icon/index.d.ts +2 -2
  122. package/dist/components/IconFactory/IconFactory.d.ts +17 -17
  123. package/dist/components/IconFactory/IconFactory.fixtures.d.ts +10 -10
  124. package/dist/components/IconFactory/IconFactory.stories.d.ts +6 -6
  125. package/dist/components/IconFactory/IconFactory.test.d.ts +1 -1
  126. package/dist/components/IconFactory/index.d.ts +2 -2
  127. package/dist/components/Label/Label.d.ts +17 -18
  128. package/dist/components/Label/Label.stories.d.ts +14 -14
  129. package/dist/components/Label/Label.test.d.ts +1 -1
  130. package/dist/components/Label/index.d.ts +2 -2
  131. package/dist/components/Layout/Box.d.ts +15 -15
  132. package/dist/components/Layout/Grid.d.ts +11 -11
  133. package/dist/components/Layout/Group.d.ts +13 -14
  134. package/dist/components/Layout/Layout.d.ts +16 -16
  135. package/dist/components/Layout/Layout.stories.d.ts +146 -146
  136. package/dist/components/Layout/Layout.types.d.ts +3 -3
  137. package/dist/components/Layout/Layout.utils.d.ts +3 -3
  138. package/dist/components/Layout/Sidebar.d.ts +13 -13
  139. package/dist/components/Layout/Stack.d.ts +18 -19
  140. package/dist/components/Layout/Switcher.d.ts +12 -12
  141. package/dist/components/Layout/index.d.ts +7 -7
  142. package/dist/components/Link/Link.d.ts +8 -9
  143. package/dist/components/Link/Link.stories.d.ts +5 -5
  144. package/dist/components/Link/Link.test.d.ts +1 -1
  145. package/dist/components/Link/index.d.ts +3 -3
  146. package/dist/components/Link/useSafeLink.d.ts +3 -3
  147. package/dist/components/Loaders/LoadingBar.d.ts +13 -13
  148. package/dist/components/Loaders/LoadingBar.stories.d.ts +5 -5
  149. package/dist/components/Loaders/LoadingBar.test.d.ts +1 -1
  150. package/dist/components/Loaders/LoadingDots.d.ts +5 -6
  151. package/dist/components/Loaders/LoadingDots.stories.d.ts +6 -6
  152. package/dist/components/Loaders/LoadingDots.test.d.ts +1 -1
  153. package/dist/components/Loaders/Spinner.d.ts +5 -6
  154. package/dist/components/Loaders/Spinner.stories.d.ts +5 -5
  155. package/dist/components/Loaders/Spinner.test.d.ts +1 -1
  156. package/dist/components/Loaders/index.d.ts +3 -3
  157. package/dist/components/Modal/Modal.d.ts +22 -22
  158. package/dist/components/Modal/Modal.stories.d.ts +30 -30
  159. package/dist/components/Modal/Modal.test.d.ts +1 -1
  160. package/dist/components/Modal/index.d.ts +2 -2
  161. package/dist/components/Pagination/Pagination.constants.d.ts +7 -7
  162. package/dist/components/Pagination/Pagination.d.ts +3 -4
  163. package/dist/components/Pagination/Pagination.helper.d.ts +15 -15
  164. package/dist/components/Pagination/Pagination.stories.d.ts +5 -5
  165. package/dist/components/Pagination/Pagination.test.d.ts +1 -1
  166. package/dist/components/Pagination/Pagination.types.d.ts +48 -48
  167. package/dist/components/Pagination/PaginationItem.d.ts +3 -4
  168. package/dist/components/Pagination/index.d.ts +2 -2
  169. package/dist/components/Pagination/usePagination.d.ts +3 -3
  170. package/dist/components/Pagination/usePagination.test.d.ts +1 -1
  171. package/dist/components/Popover/Popover.d.ts +10 -11
  172. package/dist/components/Popover/Popover.stories.d.ts +5 -5
  173. package/dist/components/Popover/Popover.test.d.ts +1 -1
  174. package/dist/components/Popover/Popover.types.d.ts +31 -31
  175. package/dist/components/Popover/index.d.ts +2 -2
  176. package/dist/components/ProgressBar/ProgressBar.d.ts +9 -9
  177. package/dist/components/ProgressBar/ProgressBar.stories.d.ts +12 -12
  178. package/dist/components/ProgressBar/ProgressBar.test.d.ts +1 -1
  179. package/dist/components/ProgressBar/index.d.ts +2 -2
  180. package/dist/components/Radio/Radio.d.ts +10 -10
  181. package/dist/components/Radio/Radio.stories.d.ts +8 -8
  182. package/dist/components/Radio/Radio.test.d.ts +1 -1
  183. package/dist/components/Radio/index.d.ts +2 -2
  184. package/dist/components/Section/Section.d.ts +12 -12
  185. package/dist/components/Section/Section.test.d.ts +1 -1
  186. package/dist/components/Section/Sections.stories.d.ts +5 -5
  187. package/dist/components/Section/index.d.ts +2 -2
  188. package/dist/components/Select/Select.constants.d.ts +2 -2
  189. package/dist/components/Select/Select.context.d.ts +5 -6
  190. package/dist/components/Select/Select.d.ts +13 -13
  191. package/dist/components/Select/Select.fixtures.d.ts +37 -37
  192. package/dist/components/Select/Select.stories.d.ts +19 -19
  193. package/dist/components/Select/Select.test.d.ts +1 -1
  194. package/dist/components/Select/Select.types.d.ts +122 -122
  195. package/dist/components/Select/SelectCreatableOption.d.ts +3 -4
  196. package/dist/components/Select/SelectEmpty.d.ts +3 -4
  197. package/dist/components/Select/SelectEmpty.test.d.ts +1 -1
  198. package/dist/components/Select/SelectOption.d.ts +3 -4
  199. package/dist/components/Select/SelectOption.test.d.ts +1 -1
  200. package/dist/components/Select/SelectTrigger.d.ts +3 -3
  201. package/dist/components/Select/components.d.ts +2 -2
  202. package/dist/components/Select/index.d.ts +3 -3
  203. package/dist/components/Select/useSelect.d.ts +8 -8
  204. package/dist/components/Select/useSelect.helpers.d.ts +6 -6
  205. package/dist/components/Select/useSelect.helpers.test.d.ts +1 -1
  206. package/dist/components/Select/useSelect.test.d.ts +1 -1
  207. package/dist/components/Select/useSelectExternal.d.ts +2 -2
  208. package/dist/components/SideNavigation/Logo/Logo.d.ts +8 -14
  209. package/dist/components/SideNavigation/Logo/Logo.test.d.ts +1 -1
  210. package/dist/components/SideNavigation/Logo/index.d.ts +1 -1
  211. package/dist/components/SideNavigation/Menu/Menu.d.ts +16 -17
  212. package/dist/components/SideNavigation/Menu/Menu.test.d.ts +1 -1
  213. package/dist/components/SideNavigation/Menu/MenuBaseItem.d.ts +11 -11
  214. package/dist/components/SideNavigation/Menu/MenuExpandable.d.ts +6 -6
  215. package/dist/components/SideNavigation/Menu/MenuLink.d.ts +10 -11
  216. package/dist/components/SideNavigation/Menu/index.d.ts +1 -1
  217. package/dist/components/SideNavigation/Separator/Separator.d.ts +5 -6
  218. package/dist/components/SideNavigation/Separator/Separator.test.d.ts +1 -1
  219. package/dist/components/SideNavigation/Separator/index.d.ts +1 -1
  220. package/dist/components/SideNavigation/SideNavigation.d.ts +28 -34
  221. package/dist/components/SideNavigation/SideNavigation.stories.d.ts +5 -5
  222. package/dist/components/SideNavigation/SideNavigation.test.d.ts +1 -1
  223. package/dist/components/SideNavigation/index.d.ts +4 -4
  224. package/dist/components/SideNavigation/useSideNavigation.d.ts +8 -8
  225. package/dist/components/Steps/ProgressSteps/ProgressStep.d.ts +12 -12
  226. package/dist/components/Steps/ProgressSteps/ProgressSteps.d.ts +7 -8
  227. package/dist/components/Steps/ProgressSteps/index.d.ts +1 -1
  228. package/dist/components/Steps/Steps.d.ts +16 -16
  229. package/dist/components/Steps/Steps.fixtures.d.ts +6 -6
  230. package/dist/components/Steps/Steps.helpers.d.ts +2 -2
  231. package/dist/components/Steps/Steps.stories.d.ts +5 -5
  232. package/dist/components/Steps/Steps.test.d.ts +1 -1
  233. package/dist/components/Steps/Steps.types.d.ts +5 -5
  234. package/dist/components/Steps/StepsContext.d.ts +3 -3
  235. package/dist/components/Steps/StepsStep.d.ts +8 -8
  236. package/dist/components/Steps/index.d.ts +5 -5
  237. package/dist/components/Steps/useStep.test.d.ts +1 -1
  238. package/dist/components/Steps/useSteps.d.ts +30 -30
  239. package/dist/components/Switch/Switch.d.ts +11 -11
  240. package/dist/components/Switch/Switch.stories.d.ts +5 -5
  241. package/dist/components/Switch/Switch.test.d.ts +1 -1
  242. package/dist/components/Switch/index.d.ts +2 -2
  243. package/dist/components/Table/Selection.d.ts +34 -35
  244. package/dist/components/Table/Table.d.ts +38 -39
  245. package/dist/components/Table/Table.fixtures.d.ts +29 -29
  246. package/dist/components/Table/Table.stories.d.ts +61 -61
  247. package/dist/components/Table/Table.test.d.ts +1 -1
  248. package/dist/components/Table/Table.types.d.ts +72 -72
  249. package/dist/components/Table/TableSortHandle.d.ts +7 -8
  250. package/dist/components/Table/index.d.ts +2 -2
  251. package/dist/components/Table/useSortBy.d.ts +16 -16
  252. package/dist/components/Table/useSortBy.test.d.ts +1 -1
  253. package/dist/components/Table/useSortBy.types.d.ts +16 -16
  254. package/dist/components/TablePagination/RowsPerPage.d.ts +3 -4
  255. package/dist/components/TablePagination/TablePagination.d.ts +3 -4
  256. package/dist/components/TablePagination/TablePagination.stories.d.ts +5 -5
  257. package/dist/components/TablePagination/TablePagination.styles.d.ts +4 -5
  258. package/dist/components/TablePagination/TablePagination.test.d.ts +1 -1
  259. package/dist/components/TablePagination/TablePagination.types.d.ts +59 -59
  260. package/dist/components/TablePagination/TablePaginationActions.d.ts +11 -11
  261. package/dist/components/TablePagination/index.d.ts +2 -2
  262. package/dist/components/Tabs/Tabs.d.ts +49 -49
  263. package/dist/components/Tabs/Tabs.stories.d.ts +23 -23
  264. package/dist/components/Tabs/Tabs.test.d.ts +1 -1
  265. package/dist/components/Tabs/Tabs.types.d.ts +6 -6
  266. package/dist/components/Tabs/TabsContext.d.ts +8 -9
  267. package/dist/components/Tabs/index.d.ts +2 -2
  268. package/dist/components/Tag/Tag.d.ts +18 -19
  269. package/dist/components/Tag/Tag.stories.d.ts +42 -41
  270. package/dist/components/Tag/Tag.test.d.ts +1 -1
  271. package/dist/components/Tag/index.d.ts +2 -2
  272. package/dist/components/Text/Text.d.ts +9 -15
  273. package/dist/components/Text/Text.stories.d.ts +7 -5
  274. package/dist/components/Text/Text.test.d.ts +1 -1
  275. package/dist/components/Text/index.d.ts +2 -2
  276. package/dist/components/TextField/TextField.d.ts +18 -19
  277. package/dist/components/TextField/TextField.stories.d.ts +11 -11
  278. package/dist/components/TextField/TextField.test.d.ts +1 -1
  279. package/dist/components/TextField/index.d.ts +4 -4
  280. package/dist/components/TextField/useTextField.d.ts +6 -6
  281. package/dist/components/Textarea/Textarea.d.ts +16 -17
  282. package/dist/components/Textarea/Textarea.stories.d.ts +11 -11
  283. package/dist/components/Textarea/Textarea.test.d.ts +1 -1
  284. package/dist/components/Textarea/index.d.ts +2 -2
  285. package/dist/components/Toast/Toast.d.ts +11 -11
  286. package/dist/components/Toast/Toast.stories.d.ts +12 -12
  287. package/dist/components/Toast/Toast.test.d.ts +1 -1
  288. package/dist/components/Toast/index.d.ts +2 -2
  289. package/dist/components/ToggleGroup/Toggle.d.ts +4 -5
  290. package/dist/components/ToggleGroup/Toggle.test.d.ts +1 -1
  291. package/dist/components/ToggleGroup/ToggleGroup.constants.d.ts +2 -2
  292. package/dist/components/ToggleGroup/ToggleGroup.d.ts +6 -7
  293. package/dist/components/ToggleGroup/ToggleGroup.stories.d.ts +6 -6
  294. package/dist/components/ToggleGroup/ToggleGroup.test.d.ts +1 -1
  295. package/dist/components/ToggleGroup/ToggleGroup.types.d.ts +26 -26
  296. package/dist/components/ToggleGroup/ToggleGroupContext.d.ts +5 -5
  297. package/dist/components/ToggleGroup/index.d.ts +2 -2
  298. package/dist/components/Tooltip/Tooltip.d.ts +22 -23
  299. package/dist/components/Tooltip/Tooltip.stories.d.ts +13 -13
  300. package/dist/components/Tooltip/Tooltip.test.d.ts +1 -1
  301. package/dist/components/Tooltip/index.d.ts +2 -2
  302. package/dist/components/TopNavigation/Logo/Logo.d.ts +8 -14
  303. package/dist/components/TopNavigation/Logo/Logo.test.d.ts +1 -1
  304. package/dist/components/TopNavigation/Logo/index.d.ts +1 -1
  305. package/dist/components/TopNavigation/Menu/Menu.d.ts +18 -18
  306. package/dist/components/TopNavigation/Menu/Menu.test.d.ts +1 -1
  307. package/dist/components/TopNavigation/Menu/MenuItemDropdown.d.ts +17 -17
  308. package/dist/components/TopNavigation/Menu/MenuItemIcon.d.ts +8 -8
  309. package/dist/components/TopNavigation/Menu/index.d.ts +1 -1
  310. package/dist/components/TopNavigation/OpenSideNavButton/OpenSideNavButton.d.ts +7 -8
  311. package/dist/components/TopNavigation/OpenSideNavButton/index.d.ts +1 -1
  312. package/dist/components/TopNavigation/TopNavigation.d.ts +11 -17
  313. package/dist/components/TopNavigation/TopNavigation.stories.d.ts +5 -6
  314. package/dist/components/TopNavigation/index.d.ts +2 -2
  315. package/dist/components/VisuallyHidden/VisuallyHidden.d.ts +1 -1
  316. package/dist/components/VisuallyHidden/VisuallyHidden.stories.d.ts +12 -13
  317. package/dist/components/VisuallyHidden/VisuallyHidden.test.d.ts +1 -1
  318. package/dist/components/VisuallyHidden/index.d.ts +1 -1
  319. package/dist/hooks/useClickOutside/index.d.ts +1 -1
  320. package/dist/hooks/useClickOutside/useClickOutside.d.ts +3 -3
  321. package/dist/hooks/useClickOutside/useClickOutside.test.d.ts +1 -1
  322. package/dist/hooks/useDidMount/index.d.ts +1 -1
  323. package/dist/hooks/useDidMount/useDidMount.d.ts +9 -9
  324. package/dist/hooks/useDidMount/useDidMount.test.d.ts +1 -1
  325. package/dist/hooks/useFingerprint/index.d.ts +1 -1
  326. package/dist/hooks/useFingerprint/useFingerprint.d.ts +18 -18
  327. package/dist/hooks/useFingerprint/useFingerprint.test.d.ts +1 -1
  328. package/dist/hooks/useFocusTrap/index.d.ts +2 -2
  329. package/dist/hooks/useFocusTrap/useFocusTrap.d.ts +27 -27
  330. package/dist/hooks/useFocusTrap/useFocusTrap.stories.d.ts +7 -7
  331. package/dist/hooks/useFocusTrap/useFocusTrap.test.d.ts +1 -1
  332. package/dist/hooks/useFocusWithin/index.d.ts +2 -2
  333. package/dist/hooks/useFocusWithin/useFocusWithin.d.ts +15 -15
  334. package/dist/hooks/useFocusWithin/useFocusWithin.test.d.ts +1 -1
  335. package/dist/hooks/useHeightExpansionToggler/index.d.ts +2 -2
  336. package/dist/hooks/useHeightExpansionToggler/useHeightExpansionToggler.d.ts +14 -14
  337. package/dist/hooks/useHeightExpansionToggler/useHeightExpansionToggler.test.d.ts +1 -1
  338. package/dist/hooks/useID/index.d.ts +1 -1
  339. package/dist/hooks/useID/useID.d.ts +2 -2
  340. package/dist/hooks/useSelectable/SelectableStrategy.d.ts +11 -11
  341. package/dist/hooks/useSelectable/SelectableStrategy.test.d.ts +1 -1
  342. package/dist/hooks/useSelectable/index.d.ts +2 -2
  343. package/dist/hooks/useSelectable/useSelectable.d.ts +6 -6
  344. package/dist/hooks/useSelectable/useSelectable.test.d.ts +1 -1
  345. package/dist/hooks/useSelectable/useSelectable.types.d.ts +46 -46
  346. package/dist/hooks/useWindowResize/index.d.ts +1 -1
  347. package/dist/hooks/useWindowResize/useWindowResize.d.ts +5 -5
  348. package/dist/index.d.ts +97 -97
  349. package/dist/index.js +305 -2676
  350. package/dist/index.js.map +1 -1
  351. package/dist/index.mjs +9310 -0
  352. package/dist/index.mjs.map +1 -0
  353. package/dist/miranda-compatibility.theme-C3Dt-45K.js +2 -0
  354. package/dist/miranda-compatibility.theme-C3Dt-45K.js.map +1 -0
  355. package/dist/miranda-compatibility.theme-ClCWbTIT.mjs +2525 -0
  356. package/dist/miranda-compatibility.theme-ClCWbTIT.mjs.map +1 -0
  357. package/dist/prop-C4yDbi0C.mjs +53 -0
  358. package/dist/prop-C4yDbi0C.mjs.map +1 -0
  359. package/dist/prop-pWSEOvKc.js +2 -0
  360. package/dist/{prop-597d4792.js.map → prop-pWSEOvKc.js.map} +1 -1
  361. package/dist/styles/activatable.d.ts +10 -10
  362. package/dist/styles/disableable.d.ts +10 -10
  363. package/dist/styles/ellipsizable.d.ts +7 -7
  364. package/dist/styles/focusable.d.ts +10 -10
  365. package/dist/styles/font.d.ts +16 -16
  366. package/dist/styles/font.test.d.ts +1 -1
  367. package/dist/styles/hidden.d.ts +7 -7
  368. package/dist/styles/hoverable.d.ts +10 -10
  369. package/dist/styles/transition.d.ts +11 -11
  370. package/dist/styles/typography.d.ts +26 -27
  371. package/dist/styles/typography.test.d.ts +1 -1
  372. package/dist/testing/DatePickerEvent/DatePickerEvent.d.ts +42 -42
  373. package/dist/testing/DatePickerEvent/DateRangePickerEvent.d.ts +41 -41
  374. package/dist/testing/DatePickerEvent/index.d.ts +2 -2
  375. package/dist/testing/DragDropFileEvent/DragDropFileEvent.d.ts +6 -6
  376. package/dist/testing/DragDropFileEvent/index.d.ts +1 -1
  377. package/dist/testing/SelectEvent/SelectEvent.d.ts +66 -66
  378. package/dist/testing/SelectEvent/SelectEvent.test.d.ts +1 -1
  379. package/dist/testing/SelectEvent/index.d.ts +1 -1
  380. package/dist/testing/getInterpolatedStyles/getInterpolatedStyles.d.ts +10 -10
  381. package/dist/testing/getInterpolatedStyles/index.d.ts +1 -1
  382. package/dist/testing/index.d.ts +5 -5
  383. package/dist/testing/index.js +1 -1
  384. package/dist/testing/index.js.map +1 -1
  385. package/dist/testing/index.mjs +227 -0
  386. package/dist/testing/index.mjs.map +1 -0
  387. package/dist/testing/renderWithDragDropFileProvider/index.d.ts +1 -1
  388. package/dist/testing/renderWithDragDropFileProvider/renderWithDragDropFileProvider.d.ts +5 -5
  389. package/dist/tests/generator.d.ts +34 -35
  390. package/dist/tests/renderer.d.ts +9 -10
  391. package/dist/theming/index.d.ts +16 -16
  392. package/dist/theming/index.js +1 -1
  393. package/dist/theming/index.js.map +1 -1
  394. package/dist/theming/index.mjs +19 -0
  395. package/dist/theming/index.mjs.map +1 -0
  396. package/dist/theming/themes/alice.theme.d.ts +812 -812
  397. package/dist/theming/themes/index.d.ts +3 -3
  398. package/dist/theming/themes/loadsmart.theme.d.ts +794 -794
  399. package/dist/theming/themes/miranda-compatibility.theme.d.ts +808 -808
  400. package/dist/theming/theming.helpers.d.ts +22 -22
  401. package/dist/toArray-BJfx0Xhj.mjs +38 -0
  402. package/dist/toArray-BJfx0Xhj.mjs.map +1 -0
  403. package/dist/toArray-Dw6F-w3t.js +2 -0
  404. package/dist/{toArray-b56541b4.js.map → toArray-Dw6F-w3t.js.map} +1 -1
  405. package/dist/tools/conditional.d.ts +39 -39
  406. package/dist/tools/conditional.test.d.ts +1 -1
  407. package/dist/tools/index.d.ts +2 -2
  408. package/dist/tools/index.js +1 -1
  409. package/dist/tools/index.mjs +7 -0
  410. package/dist/tools/index.mjs.map +1 -0
  411. package/dist/tools/prop.d.ts +15 -15
  412. package/dist/tools/prop.test.d.ts +1 -1
  413. package/dist/utils/toolset/awaitTo.d.ts +10 -10
  414. package/dist/utils/toolset/flatten.d.ts +2 -1
  415. package/dist/utils/toolset/formatBytes.d.ts +4 -4
  416. package/dist/utils/toolset/formatBytes.test.d.ts +1 -1
  417. package/dist/utils/toolset/get.d.ts +2 -1
  418. package/dist/utils/toolset/getID.d.ts +13 -13
  419. package/dist/utils/toolset/getID.test.d.ts +1 -1
  420. package/dist/utils/toolset/getOrdinalSuffix.d.ts +1 -1
  421. package/dist/utils/toolset/getOrdinalSuffix.test.d.ts +1 -1
  422. package/dist/utils/toolset/highlightMatch.d.ts +9 -10
  423. package/dist/utils/toolset/highlightMatch.test.d.ts +1 -1
  424. package/dist/utils/toolset/interleave.d.ts +2 -2
  425. package/dist/utils/toolset/interleave.test.d.ts +1 -1
  426. package/dist/utils/toolset/isEmpty.d.ts +2 -1
  427. package/dist/utils/toolset/isThenable.d.ts +5 -5
  428. package/dist/utils/toolset/isThenable.test.d.ts +1 -1
  429. package/dist/utils/toolset/keyboard.d.ts +24 -24
  430. package/dist/utils/toolset/omit.d.ts +2 -1
  431. package/dist/utils/toolset/pluralize.d.ts +14 -14
  432. package/dist/utils/toolset/range.d.ts +2 -1
  433. package/dist/utils/toolset/rem.d.ts +3 -3
  434. package/dist/utils/toolset/styledCompounds.d.ts +12 -13
  435. package/dist/utils/toolset/toArray.d.ts +2 -2
  436. package/dist/utils/types/ColorScheme.d.ts +2 -2
  437. package/dist/utils/types/EventLike.d.ts +10 -10
  438. package/dist/utils/types/InterpolatedStyle.d.ts +2 -2
  439. package/dist/utils/types/Status.d.ts +7 -7
  440. package/package.json +31 -50
  441. package/src/components/Dropdown/Dropdown.test.tsx +3 -1
  442. package/src/components/Icon/Icon.tsx +21 -21
  443. package/src/components/IconFactory/IconFactory.tsx +3 -3
  444. package/src/components/Select/Select.stories.tsx +1 -1
  445. package/src/components/Switch/Switch.test.tsx +3 -1
  446. package/src/components/Text/Text.stories.tsx +29 -25
  447. package/src/utils/toolset/flatten.ts +3 -1
  448. package/src/utils/toolset/get.ts +2 -1
  449. package/src/utils/toolset/isEmpty.ts +2 -1
  450. package/src/utils/toolset/omit.ts +2 -1
  451. package/src/utils/toolset/range.ts +2 -1
  452. package/dist/DragDropFile.context-bbb7d631.js +0 -2
  453. package/dist/DragDropFile.context-bbb7d631.js.map +0 -1
  454. package/dist/miranda-compatibility.theme-8689186b.js +0 -2
  455. package/dist/miranda-compatibility.theme-8689186b.js.map +0 -1
  456. package/dist/prop-597d4792.js +0 -2
  457. package/dist/toArray-b56541b4.js +0 -2
  458. package/dist/utils/toolset/debounce.d.ts +0 -1
  459. package/src/utils/toolset/debounce.ts +0 -1
@@ -1,22 +1,22 @@
1
- declare type VariableValue = string | number;
2
- declare type VariableMap = {
3
- [key: string]: VariableValue;
4
- };
5
- export declare function generateColorGetter(colors: VariableMap): (name: string, opacity?: number) => VariableValue;
6
- export declare function generateSpacingGetter(spacings: VariableMap): (name: string) => VariableValue;
7
- export declare function generateShadowGetter(shadows: VariableMap): (name: string) => VariableValue;
8
- export declare function generateFontGetters({ families, sizes, weights, heights, }: {
9
- families: VariableMap;
10
- sizes: VariableMap;
11
- weights: VariableMap;
12
- heights: VariableMap;
13
- }): {
14
- [key: string]: (name: string) => VariableValue;
15
- };
16
- export declare function generateOpacityGetter(opacities: VariableMap): (name: string) => VariableValue;
17
- export declare function generateBorderGetters({ radiuses, widths, }: {
18
- radiuses: VariableMap;
19
- widths: VariableMap;
20
- }): Record<string, (name: string) => VariableValue>;
21
- export declare function generateHeightGetter(heights: VariableMap): (name: string) => VariableValue;
22
- export {};
1
+ type VariableValue = string | number;
2
+ type VariableMap = {
3
+ [key: string]: VariableValue;
4
+ };
5
+ export declare function generateColorGetter(colors: VariableMap): (name: string, opacity?: number) => VariableValue;
6
+ export declare function generateSpacingGetter(spacings: VariableMap): (name: string) => VariableValue;
7
+ export declare function generateShadowGetter(shadows: VariableMap): (name: string) => VariableValue;
8
+ export declare function generateFontGetters({ families, sizes, weights, heights, }: {
9
+ families: VariableMap;
10
+ sizes: VariableMap;
11
+ weights: VariableMap;
12
+ heights: VariableMap;
13
+ }): {
14
+ [key: string]: (name: string) => VariableValue;
15
+ };
16
+ export declare function generateOpacityGetter(opacities: VariableMap): (name: string) => VariableValue;
17
+ export declare function generateBorderGetters({ radiuses, widths, }: {
18
+ radiuses: VariableMap;
19
+ widths: VariableMap;
20
+ }): Record<string, (name: string) => VariableValue>;
21
+ export declare function generateHeightGetter(heights: VariableMap): (name: string) => VariableValue;
22
+ export {};
@@ -0,0 +1,38 @@
1
+ var r = {}, t = {}, s;
2
+ function f() {
3
+ if (s) return t;
4
+ s = 1, Object.defineProperty(t, "__esModule", { value: !0 });
5
+ function e(i) {
6
+ return i == null;
7
+ }
8
+ return t.default = e, t;
9
+ }
10
+ var u = {}, a;
11
+ function o() {
12
+ if (a) return u;
13
+ a = 1, Object.defineProperty(u, "__esModule", { value: !0 });
14
+ var e = f();
15
+ function i(n) {
16
+ var c = typeof n;
17
+ return !e.default(n) && ["object", "function"].includes(c);
18
+ }
19
+ return u.default = i, u;
20
+ }
21
+ var l;
22
+ function d() {
23
+ if (l) return r;
24
+ l = 1, Object.defineProperty(r, "__esModule", { value: !0 }), r.isObject = r.isNil = void 0;
25
+ var e = f();
26
+ r.isNil = e.default;
27
+ var i = o();
28
+ return r.isObject = i.default, r;
29
+ }
30
+ var b = d();
31
+ function j(e) {
32
+ return b.isNil(e) ? [] : Array.isArray(e) ? e : [e];
33
+ }
34
+ export {
35
+ b as l,
36
+ j as t
37
+ };
38
+ //# sourceMappingURL=toArray-BJfx0Xhj.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"toArray-BJfx0Xhj.mjs","sources":["../node_modules/@loadsmart/utils-object/lib/isNil.js","../node_modules/@loadsmart/utils-object/lib/isObject.js","../node_modules/@loadsmart/utils-object/lib/index.js","../src/utils/toolset/toArray.ts"],"sourcesContent":["'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nfunction isNil(value) {\n return value == null\n}\nexports.default = isNil\n//# sourceMappingURL=isNil.js.map\n","'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nvar isNil_1 = require('./isNil')\nfunction isObject(value) {\n var type = typeof value\n return !isNil_1.default(value) && ['object', 'function'].includes(type)\n}\nexports.default = isObject\n//# sourceMappingURL=isObject.js.map\n","'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nexports.isObject = exports.isNil = void 0\nvar isNil_1 = require('./isNil')\nexports.isNil = isNil_1.default\nvar isObject_1 = require('./isObject')\nexports.isObject = isObject_1.default\n//# sourceMappingURL=index.js.map\n","import { isNil } from '@loadsmart/utils-object'\n\n// TODO: add this helper to @loadsmart/utils\nfunction toArray<T>(value: T | T[]): T[] {\n if (isNil(value)) {\n return []\n }\n\n if (Array.isArray(value)) {\n return value\n }\n\n return [value]\n}\n\nexport default toArray\n"],"names":["isNil_1","isNil","value","isObject_1","require$$0","isObject","type","lib","require$$1","toArray","Array","isArray"],"mappings":";;;SACA,OAAO,eAAeA,GAAS,cAAc,EAAE,OAAO,GAAM,CAAA;AAC5D,WAASC,EAAMC,GAAO;AACpB,WAAOA,KAAS;AAAA,EAClB;AACAF,SAAAA,EAAA,UAAkBC;;;;;SCJlB,OAAO,eAAeE,GAAS,cAAc,EAAE,OAAO,GAAM,CAAA;AAC5D,MAAIH,IAAUI,EAAA;AACd,WAASC,EAASH,GAAO;AACvB,QAAII,IAAO,OAAOJ;AAClB,WAAO,CAACF,EAAQ,QAAQE,CAAK,KAAK,CAAC,UAAU,UAAU,EAAE,SAASI,CAAI;AAAA,EACxE;AACAH,SAAAA,EAAA,UAAkBE;;;;;SCNlB,OAAO,eAAeE,GAAS,cAAc,EAAE,OAAO,GAAM,CAAA,GAC5CA,EAAA,WAAGA,EAAa,QAAG;AACnC,MAAIP,IAAUI,EAAA;AACD,EAAAG,EAAA,QAAGP,EAAQ;AACxB,MAAIG,IAAaK,EAAA;AACD,SAAAD,EAAA,WAAGJ,EAAW;;;ACH9B,SAASM,EAAWP,GAAqB;AACnCD,SAAAA,EAAAA,MAAMC,CAAK,IACN,CAAE,IAGPQ,MAAMC,QAAQT,CAAK,IACdA,IAGF,CAACA,CAAK;AACf;","x_google_ignoreList":[0,1,2]}
@@ -0,0 +1,2 @@
1
+ "use strict";var e={},t={},s;function f(){if(s)return t;s=1,Object.defineProperty(t,"__esModule",{value:!0});function r(i){return i==null}return t.default=r,t}var u={},a;function b(){if(a)return u;a=1,Object.defineProperty(u,"__esModule",{value:!0});var r=f();function i(n){var o=typeof n;return!r.default(n)&&["object","function"].includes(o)}return u.default=i,u}var l;function d(){if(l)return e;l=1,Object.defineProperty(e,"__esModule",{value:!0}),e.isObject=e.isNil=void 0;var r=f();e.isNil=r.default;var i=b();return e.isObject=i.default,e}var c=d();function j(r){return c.isNil(r)?[]:Array.isArray(r)?r:[r]}exports.libExports=c;exports.toArray=j;
2
+ //# sourceMappingURL=toArray-Dw6F-w3t.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"toArray-b56541b4.js","sources":["../node_modules/@loadsmart/utils-object/lib/isNil.js","../node_modules/@loadsmart/utils-object/lib/isObject.js","../node_modules/@loadsmart/utils-object/lib/index.js","../src/utils/toolset/toArray.ts"],"sourcesContent":["'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nfunction isNil(value) {\n return value == null\n}\nexports.default = isNil\n//# sourceMappingURL=isNil.js.map\n","'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nvar isNil_1 = require('./isNil')\nfunction isObject(value) {\n var type = typeof value\n return !isNil_1.default(value) && ['object', 'function'].includes(type)\n}\nexports.default = isObject\n//# sourceMappingURL=isObject.js.map\n","'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nexports.isObject = exports.isNil = void 0\nvar isNil_1 = require('./isNil')\nexports.isNil = isNil_1.default\nvar isObject_1 = require('./isObject')\nexports.isObject = isObject_1.default\n//# sourceMappingURL=index.js.map\n","import { isNil } from '@loadsmart/utils-object'\n\n// TODO: add this helper to @loadsmart/utils\nfunction toArray<T>(value: T | T[]): T[] {\n if (isNil(value)) {\n return []\n }\n\n if (Array.isArray(value)) {\n return value\n }\n\n return [value]\n}\n\nexport default toArray\n"],"names":["Object","defineProperty","isNil_1","value","default","isObject_1","require$$0","type","includes","lib","isObject","isNil","require$$1","Array","isArray"],"mappings":"2BACAA,OAAOC,eAAeC,EAAS,aAAc,CAAEC,OAAO,IAItDD,EAAAE,QAHA,SAAeD,GACb,OAAgB,MAATA,CACT,WCHAH,OAAOC,eAAeI,EAAS,aAAc,CAAEF,OAAO,IACtD,IAAID,EAAUI,EAKdD,EAAAD,QAJA,SAAkBD,GAChB,IAAII,SAAcJ,EAClB,OAAQD,EAAQE,QAAQD,IAAU,CAAC,SAAU,YAAYK,SAASD,EACpE,ECLAP,OAAOC,eAAeQ,EAAS,aAAc,CAAEN,OAAO,IACtDO,QAAAA,SAAAD,EAAAC,SAAmBC,QAAAA,MAAAF,EAAAE,WAAgB,EACnC,IAAIT,EAAUI,EACDK,QAAAA,MAAAF,EAAAE,MAAGT,EAAQE,QACxB,IAAIC,EAAaO,EACjBF,QAAAA,SAAgBD,EAAAC,SAAGL,EAAWD,wBCH9B,SAAoBD,GAClB,OAAIQ,QAAAA,MAAMR,GACD,GAGLU,MAAMC,QAAQX,GACTA,EAGF,CAACA,EACV"}
1
+ {"version":3,"file":"toArray-Dw6F-w3t.js","sources":["../node_modules/@loadsmart/utils-object/lib/isNil.js","../node_modules/@loadsmart/utils-object/lib/isObject.js","../node_modules/@loadsmart/utils-object/lib/index.js","../src/utils/toolset/toArray.ts"],"sourcesContent":["'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nfunction isNil(value) {\n return value == null\n}\nexports.default = isNil\n//# sourceMappingURL=isNil.js.map\n","'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nvar isNil_1 = require('./isNil')\nfunction isObject(value) {\n var type = typeof value\n return !isNil_1.default(value) && ['object', 'function'].includes(type)\n}\nexports.default = isObject\n//# sourceMappingURL=isObject.js.map\n","'use strict'\nObject.defineProperty(exports, '__esModule', { value: true })\nexports.isObject = exports.isNil = void 0\nvar isNil_1 = require('./isNil')\nexports.isNil = isNil_1.default\nvar isObject_1 = require('./isObject')\nexports.isObject = isObject_1.default\n//# sourceMappingURL=index.js.map\n","import { isNil } from '@loadsmart/utils-object'\n\n// TODO: add this helper to @loadsmart/utils\nfunction toArray<T>(value: T | T[]): T[] {\n if (isNil(value)) {\n return []\n }\n\n if (Array.isArray(value)) {\n return value\n }\n\n return [value]\n}\n\nexport default toArray\n"],"names":["isNil_1","isNil","value","isObject_1","require$$0","isObject","type","lib","require$$1","toArray","Array","isArray"],"mappings":"4DACA,OAAO,eAAeA,EAAS,aAAc,CAAE,MAAO,EAAM,CAAA,EAC5D,SAASC,EAAMC,EAAO,CACpB,OAAOA,GAAS,IAClB,CACAF,OAAAA,EAAA,QAAkBC,8CCJlB,OAAO,eAAeE,EAAS,aAAc,CAAE,MAAO,EAAM,CAAA,EAC5D,IAAIH,EAAUI,EAAA,EACd,SAASC,EAASH,EAAO,CACvB,IAAII,EAAO,OAAOJ,EAClB,MAAO,CAACF,EAAQ,QAAQE,CAAK,GAAK,CAAC,SAAU,UAAU,EAAE,SAASI,CAAI,CACxE,CACAH,OAAAA,EAAA,QAAkBE,yCCNlB,OAAO,eAAeE,EAAS,aAAc,CAAE,MAAO,EAAM,CAAA,EAC5CA,EAAA,SAAGA,EAAa,MAAG,OACnC,IAAIP,EAAUI,EAAA,EACDG,EAAA,MAAGP,EAAQ,QACxB,IAAIG,EAAaK,EAAA,EACD,OAAAD,EAAA,SAAGJ,EAAW,oBCH9B,SAASM,EAAWP,EAAqB,CACnCD,OAAAA,EAAAA,MAAMC,CAAK,EACN,CAAE,EAGPQ,MAAMC,QAAQT,CAAK,EACdA,EAGF,CAACA,CAAK,CACf","x_google_ignoreList":[0,1,2]}
@@ -1,39 +1,39 @@
1
- import type { F } from 'ts-toolbelt';
2
- declare type WhenProps<K> = K | undefined | ((value: K) => boolean | undefined);
3
- export declare type When<P> = {
4
- [Key in keyof P]?: WhenProps<P[Key]> | WhenProps<P[Key]>[] | undefined;
5
- };
6
- /**
7
- * Utility to generate style/class name conditions based on a components props.
8
- * Expected prop values can be a single value, an array of values or a function/callback.
9
- * @example
10
- * ```jsx
11
- * whenProps({
12
- * 'prop-a': true, // checks `props['prop-a']` === true`
13
- * 'prop-b': [1, 2], // checks `toArray([1, 2]).includes(props['prop-b'])`
14
- * 'prop-c': (value) => value + 1 // checks `Boolean(callback(props['prop-c']))`
15
- * 'prop-d': Boolean // checks `Boolean(Boolean(props['prop-d']))`
16
- * })
17
- * ```
18
- * @param {...Object} conditions
19
- * @returns {(props: Object}) => boolean} Returns function that consumes component props.
20
- */
21
- export declare function whenProps<P>(conditions: When<F.Narrow<P>> | When<F.Narrow<P>>[]): (props: P) => boolean;
22
- declare type ConditionObject<P> = Record<string, string | number | boolean | ((props: P) => boolean) | undefined>;
23
- declare type Condition<P> = number | string | ConditionObject<P> | ((props: P) => string);
24
- /**
25
- * Concatenate style properties or class names conditionally.
26
- * Conditions can be functions that consume components props,
27
- * objects, strings, or numbers (that will be coerced to strings).
28
- * @example
29
- * ```jsx
30
- * conditional(1, 'some-class', {
31
- * 'class-a': true,
32
- * 'class-b': (props) => props.showClassB,
33
- * }, (props) => props.className)
34
- * ```
35
- * @param conditions
36
- * @returns {(props: ThemedProps) => string} Returns function that consumes component props.
37
- */
38
- declare function conditional<P>(...conditions: Condition<P>[]): (props: P) => string;
39
- export default conditional;
1
+ import { F } from 'ts-toolbelt';
2
+ type WhenProps<K> = K | undefined | ((value: K) => boolean | undefined);
3
+ export type When<P> = {
4
+ [Key in keyof P]?: WhenProps<P[Key]> | WhenProps<P[Key]>[] | undefined;
5
+ };
6
+ /**
7
+ * Utility to generate style/class name conditions based on a components props.
8
+ * Expected prop values can be a single value, an array of values or a function/callback.
9
+ * @example
10
+ * ```jsx
11
+ * whenProps({
12
+ * 'prop-a': true, // checks `props['prop-a']` === true`
13
+ * 'prop-b': [1, 2], // checks `toArray([1, 2]).includes(props['prop-b'])`
14
+ * 'prop-c': (value) => value + 1 // checks `Boolean(callback(props['prop-c']))`
15
+ * 'prop-d': Boolean // checks `Boolean(Boolean(props['prop-d']))`
16
+ * })
17
+ * ```
18
+ * @param {...Object} conditions
19
+ * @returns {(props: Object}) => boolean} Returns function that consumes component props.
20
+ */
21
+ export declare function whenProps<P>(conditions: When<F.Narrow<P>> | When<F.Narrow<P>>[]): (props: P) => boolean;
22
+ type ConditionObject<P> = Record<string, string | number | boolean | ((props: P) => boolean) | undefined>;
23
+ type Condition<P> = number | string | ConditionObject<P> | ((props: P) => string);
24
+ /**
25
+ * Concatenate style properties or class names conditionally.
26
+ * Conditions can be functions that consume components props,
27
+ * objects, strings, or numbers (that will be coerced to strings).
28
+ * @example
29
+ * ```jsx
30
+ * conditional(1, 'some-class', {
31
+ * 'class-a': true,
32
+ * 'class-b': (props) => props.showClassB,
33
+ * }, (props) => props.className)
34
+ * ```
35
+ * @param conditions
36
+ * @returns {(props: ThemedProps) => string} Returns function that consumes component props.
37
+ */
38
+ declare function conditional<P>(...conditions: Condition<P>[]): (props: P) => string;
39
+ export default conditional;
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1,2 +1,2 @@
1
- export { default as conditional, whenProps } from './conditional';
2
- export { default as prop } from './prop';
1
+ export { default as conditional, whenProps } from './conditional';
2
+ export { default as prop } from './prop';
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../prop-597d4792.js");require("../toArray-b56541b4.js"),require("../miranda-compatibility.theme-8689186b.js"),require("@loadsmart/miranda-tokens"),require("../theming/index.js"),exports.conditional=e.conditional,exports.prop=e.prop,exports.whenProps=e.whenProps;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../prop-pWSEOvKc.js");exports.conditional=o.conditional;exports.prop=o.prop;exports.whenProps=o.whenProps;
2
2
  //# sourceMappingURL=index.js.map
@@ -0,0 +1,7 @@
1
+ import { c as a, p as r, w as s } from "../prop-C4yDbi0C.mjs";
2
+ export {
3
+ a as conditional,
4
+ r as prop,
5
+ s as whenProps
6
+ };
7
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,15 +1,15 @@
1
- declare function compare(...args: any[]): unknown;
2
- /**
3
- * Retrieve the key value from the props object
4
- * @example
5
- * ```jsx
6
- * -transform: scaleY(${(props) => props.$height || 1});
7
- * +transform: scaleY(${prop('$height', 1)});
8
- * ```
9
- * @param name a valid property name from the object
10
- * @param defaultValue a fallback value in case the property value is invalid
11
- * @param comparatorFn a function to be used to decide between value or defaultValue
12
- * @returns {(props: ThemedProps) => string} Returns function that consumes component props.
13
- */
14
- declare function prop<P, K extends keyof P = keyof P>(name: K, defaultValue?: NonNullable<P[K]>, comparatorFn?: typeof compare): (props: P) => P[K];
15
- export default prop;
1
+ declare function compare(...args: any[]): unknown;
2
+ /**
3
+ * Retrieve the key value from the props object
4
+ * @example
5
+ * ```jsx
6
+ * -transform: scaleY(${(props) => props.$height || 1});
7
+ * +transform: scaleY(${prop('$height', 1)});
8
+ * ```
9
+ * @param name a valid property name from the object
10
+ * @param defaultValue a fallback value in case the property value is invalid
11
+ * @param comparatorFn a function to be used to decide between value or defaultValue
12
+ * @returns {(props: ThemedProps) => string} Returns function that consumes component props.
13
+ */
14
+ declare function prop<P, K extends keyof P = keyof P>(name: K, defaultValue?: NonNullable<P[K]>, comparatorFn?: typeof compare): (props: P) => P[K];
15
+ export default prop;
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1,10 +1,10 @@
1
- /**
2
- * This is an async wrapper for waiting a promise to be settled without the hussle of handling error.
3
- * It returns `[error, data]`.
4
- * @example
5
- * const [error, data] = await genericTo(myPromise())
6
- * @param promise - promise to be awaited for.
7
- * @param errorExt - error to be appended, in case the promise is rejected.
8
- */
9
- declare function genericTo<T>(promise: Promise<T>, errorExt?: Record<string, unknown>): Promise<[any, T | undefined]>;
10
- export default genericTo;
1
+ /**
2
+ * This is an async wrapper for waiting a promise to be settled without the hussle of handling error.
3
+ * It returns `[error, data]`.
4
+ * @example
5
+ * const [error, data] = await genericTo(myPromise())
6
+ * @param promise - promise to be awaited for.
7
+ * @param errorExt - error to be appended, in case the promise is rejected.
8
+ */
9
+ declare function genericTo<T>(promise: Promise<T>, errorExt?: Record<string, unknown>): Promise<[any, T | undefined]>;
10
+ export default genericTo;
@@ -1 +1,2 @@
1
- export { default } from 'lodash.flatten';
1
+ import { flatten } from 'lodash';
2
+ export default flatten;
@@ -1,4 +1,4 @@
1
- export declare const BYTES_PER_KILOBYTE = 1024;
2
- export declare const FILE_SIZE_ABBREVIATIONS: string[];
3
- declare const formatBytes: (bytes: number, decimals?: number) => string;
4
- export default formatBytes;
1
+ export declare const BYTES_PER_KILOBYTE = 1024;
2
+ export declare const FILE_SIZE_ABBREVIATIONS: string[];
3
+ declare const formatBytes: (bytes: number, decimals?: number) => string;
4
+ export default formatBytes;
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1 +1,2 @@
1
- export { default } from 'lodash.get';
1
+ import { get } from 'lodash';
2
+ export default get;
@@ -1,13 +1,13 @@
1
- /**
2
- *
3
- * @param {Object} options - Options
4
- * @param
5
- * @returns
6
- */
7
- export declare function IDGenerator({ maxIDLength, initialIDLength, alphabet, }: {
8
- maxIDLength: number;
9
- initialIDLength: number;
10
- alphabet: string;
11
- }): () => string;
12
- declare const getID: () => string;
13
- export default getID;
1
+ /**
2
+ *
3
+ * @param {Object} options - Options
4
+ * @param
5
+ * @returns
6
+ */
7
+ export declare function IDGenerator({ maxIDLength, initialIDLength, alphabet, }: {
8
+ maxIDLength: number;
9
+ initialIDLength: number;
10
+ alphabet: string;
11
+ }): () => string;
12
+ declare const getID: () => string;
13
+ export default getID;
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1 +1 @@
1
- export declare const getOrdinalSuffix: (number: number) => 'st' | 'nd' | 'rd' | 'th';
1
+ export declare const getOrdinalSuffix: (number: number) => "st" | "nd" | "rd" | "th";
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1,10 +1,9 @@
1
- /// <reference types="react" />
2
- /**
3
- * A function that wraps a match into `mark` element to be highlighted.
4
- * @example
5
- *
6
- * @param {string} - label to be split
7
- * @param {string} - match to be found
8
- * @returns {ReactNode} - an element with marked match
9
- */
10
- export default function highlightMatch(str: string, match: string): JSX.Element;
1
+ /**
2
+ * A function that wraps a match into `mark` element to be highlighted.
3
+ * @example
4
+ *
5
+ * @param {string} - label to be split
6
+ * @param {string} - match to be found
7
+ * @returns {ReactNode} - an element with marked match
8
+ */
9
+ export default function highlightMatch(str: string, match: string): JSX.Element;
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1,2 +1,2 @@
1
- declare function interleave<T>(array1: Array<T>, array2: Array<T>): T[];
2
- export default interleave;
1
+ declare function interleave<T>(array1: Array<T>, array2: Array<T>): T[];
2
+ export default interleave;
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1 +1,2 @@
1
- export { default } from 'lodash.isempty';
1
+ import { isEmpty } from 'lodash';
2
+ export default isEmpty;
@@ -1,5 +1,5 @@
1
- interface Thenable {
2
- then(): any;
3
- }
4
- export declare function isThenable(object: any): object is Thenable;
5
- export {};
1
+ interface Thenable {
2
+ then(): any;
3
+ }
4
+ export declare function isThenable(object: any): object is Thenable;
5
+ export {};
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1,24 +1,24 @@
1
- import type { KeyboardEvent } from 'react';
2
- declare const SUPPORTED_KEYS: {
3
- ALT: string;
4
- ARROW_DOWN: string;
5
- ARROW_LEFT: string;
6
- ARROW_RIGHT: string;
7
- ARROW_UP: string;
8
- CONTROL: string;
9
- ENTER: string;
10
- ESCAPE: string;
11
- SHIFT: string;
12
- SPACE: string;
13
- TAB: string;
14
- E_LOWERCASE: string;
15
- DOT: string;
16
- PLUS: string;
17
- MINUS: string;
18
- };
19
- export declare type SupportedKey = keyof typeof SUPPORTED_KEYS;
20
- export declare function getKeyboardKey(e: KeyboardEvent): KeyboardEvent['key'];
21
- declare function KeyboardKey(e: KeyboardEvent): {
22
- is(otherKeys: SupportedKey | SupportedKey[]): boolean;
23
- };
24
- export default KeyboardKey;
1
+ import { KeyboardEvent } from 'react';
2
+ declare const SUPPORTED_KEYS: {
3
+ ALT: string;
4
+ ARROW_DOWN: string;
5
+ ARROW_LEFT: string;
6
+ ARROW_RIGHT: string;
7
+ ARROW_UP: string;
8
+ CONTROL: string;
9
+ ENTER: string;
10
+ ESCAPE: string;
11
+ SHIFT: string;
12
+ SPACE: string;
13
+ TAB: string;
14
+ E_LOWERCASE: string;
15
+ DOT: string;
16
+ PLUS: string;
17
+ MINUS: string;
18
+ };
19
+ export type SupportedKey = keyof typeof SUPPORTED_KEYS;
20
+ export declare function getKeyboardKey(e: KeyboardEvent): KeyboardEvent['key'];
21
+ declare function KeyboardKey(e: KeyboardEvent): {
22
+ is(otherKeys: SupportedKey | SupportedKey[]): boolean;
23
+ };
24
+ export default KeyboardKey;
@@ -1 +1,2 @@
1
- export { default } from 'lodash.omit';
1
+ import { omit } from 'lodash';
2
+ export default omit;
@@ -1,14 +1,14 @@
1
- /**
2
- * Helper that returns the plural form if count is different than 1, otherwise the singular one.
3
- * @example
4
- * let total = 3
5
- * `Item${pluralize(total)}` // "Items"
6
- * `Child${pluralize(total, 'ren')}` // "Children"
7
- * `Pe${pluralize(total, 'ople', 'rson')}` // "People"
8
- * `${pluralize(total, 'People', 'Person')}` // "People"
9
- * @param count - total of items
10
- * @param plural - defaults to "s"
11
- * @param singular - defaults to ""
12
- * @returns plural or singular.
13
- */
14
- export default function pluralize(count: number, plural?: string, singular?: string): string;
1
+ /**
2
+ * Helper that returns the plural form if count is different than 1, otherwise the singular one.
3
+ * @example
4
+ * let total = 3
5
+ * `Item${pluralize(total)}` // "Items"
6
+ * `Child${pluralize(total, 'ren')}` // "Children"
7
+ * `Pe${pluralize(total, 'ople', 'rson')}` // "People"
8
+ * `${pluralize(total, 'People', 'Person')}` // "People"
9
+ * @param count - total of items
10
+ * @param plural - defaults to "s"
11
+ * @param singular - defaults to ""
12
+ * @returns plural or singular.
13
+ */
14
+ export default function pluralize(count: number, plural?: string, singular?: string): string;
@@ -1 +1,2 @@
1
- export { default } from 'lodash.range';
1
+ import { range } from 'lodash';
2
+ export default range;
@@ -1,3 +1,3 @@
1
- export declare const BASE_PIXELS = 16;
2
- declare function rem(valueInPixels: number | string, base?: number): string;
3
- export default rem;
1
+ export declare const BASE_PIXELS = 16;
2
+ declare function rem(valueInPixels: number | string, base?: number): string;
3
+ export default rem;
@@ -1,13 +1,12 @@
1
- /// <reference types="react" />
2
- import type { StyledComponent } from 'styled-components';
3
- /**
4
- * Helper that returns the plural form if count is different than 1, otherwise the singular one.
5
- * @example
6
- * const StyledParent = styled.div``
7
- * styledCompounds(StyledParent, { Child: (props) => <div /> })
8
- * <StyledParent.Child />
9
- * @param StyledComponent - Parent instance of a styled-component
10
- * @param compounds - Object with compound components
11
- * @returns Parent component with type-safe accessable compound components
12
- */
13
- export declare function styledCompounds<A extends StyledComponent<React.ComponentType, Record<string, unknown>>, B extends Record<string, unknown>>(Parent: A, compounds: B): A & B;
1
+ import { StyledComponent } from 'styled-components';
2
+ /**
3
+ * Helper that returns the plural form if count is different than 1, otherwise the singular one.
4
+ * @example
5
+ * const StyledParent = styled.div``
6
+ * styledCompounds(StyledParent, { Child: (props) => <div /> })
7
+ * <StyledParent.Child />
8
+ * @param StyledComponent - Parent instance of a styled-component
9
+ * @param compounds - Object with compound components
10
+ * @returns Parent component with type-safe accessable compound components
11
+ */
12
+ export declare function styledCompounds<A extends StyledComponent<React.ComponentType, Record<string, unknown>>, B extends Record<string, unknown>>(Parent: A, compounds: B): A & B;
@@ -1,2 +1,2 @@
1
- declare function toArray<T>(value: T | T[]): T[];
2
- export default toArray;
1
+ declare function toArray<T>(value: T | T[]): T[];
2
+ export default toArray;
@@ -1,2 +1,2 @@
1
- declare type ColorScheme = 'dark' | 'light';
2
- export default ColorScheme;
1
+ type ColorScheme = 'dark' | 'light';
2
+ export default ColorScheme;
@@ -1,10 +1,10 @@
1
- export interface EventLikeTarget<T> {
2
- id?: number | string;
3
- name: string;
4
- value: T;
5
- type?: string;
6
- checked?: boolean;
7
- }
8
- export default interface EventLike<T> {
9
- target: EventLikeTarget<T>;
10
- }
1
+ export interface EventLikeTarget<T> {
2
+ id?: number | string;
3
+ name: string;
4
+ value: T;
5
+ type?: string;
6
+ checked?: boolean;
7
+ }
8
+ export default interface EventLike<T> {
9
+ target: EventLikeTarget<T>;
10
+ }
@@ -1,2 +1,2 @@
1
- import type { ThemeTokenValue } from "../../theming";
2
- export declare type InterpolatedStyle = (ThemeTokenValue | ((...args: unknown[]) => ThemeTokenValue))[];
1
+ import { ThemeTokenValue } from '../../theming';
2
+ export type InterpolatedStyle = (ThemeTokenValue | ((...args: unknown[]) => ThemeTokenValue))[];
@@ -1,7 +1,7 @@
1
- declare enum Status {
2
- Success = "success",
3
- Danger = "danger",
4
- Warn = "warn",
5
- Neutral = "neutral"
6
- }
7
- export default Status;
1
+ declare enum Status {
2
+ Success = "success",
3
+ Danger = "danger",
4
+ Warn = "warn",
5
+ Neutral = "neutral"
6
+ }
7
+ export default Status;