@orfium/ictinus 4.75.0 → 4.76.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 (365) hide show
  1. package/dist/components/Avatar/Avatar.d.ts +1 -1
  2. package/dist/components/Avatar/Avatar.js +9 -22
  3. package/dist/components/Avatar/Avatar.style.js +3 -18
  4. package/dist/components/Avatar/AvatarStack/AvatarStack.d.ts +1 -1
  5. package/dist/components/Avatar/AvatarStack/AvatarStack.js +8 -24
  6. package/dist/components/Avatar/AvatarStack/AvatarStack.style.js +1 -12
  7. package/dist/components/Avatar/AvatarStack/index.js +0 -3
  8. package/dist/components/Avatar/AvatarStack/utils.js +1 -3
  9. package/dist/components/Avatar/index.js +0 -3
  10. package/dist/components/Avatar/utils.js +0 -5
  11. package/dist/components/Breadcrumb/Breadcrumb.d.ts +2 -2
  12. package/dist/components/Breadcrumb/Breadcrumb.js +5 -17
  13. package/dist/components/Breadcrumb/Breadcrumb.style.js +1 -9
  14. package/dist/components/Breadcrumb/BreadcrumbItem/BreadcrumbItem.js +2 -9
  15. package/dist/components/Breadcrumb/BreadcrumbItem/BreadcrumbItem.style.js +0 -5
  16. package/dist/components/Breadcrumb/Separator/Separator.js +1 -10
  17. package/dist/components/Breadcrumb/Separator/Separator.style.js +0 -4
  18. package/dist/components/Breadcrumb/index.js +0 -3
  19. package/dist/components/Button/Button.js +22 -37
  20. package/dist/components/Button/Button.style.js +3 -9
  21. package/dist/components/Button/ButtonLoader/ButtonLoader.js +5 -16
  22. package/dist/components/Button/ButtonLoader/ButtonLoader.style.js +0 -6
  23. package/dist/components/Button/ButtonLoader/index.js +0 -3
  24. package/dist/components/Button/index.js +0 -3
  25. package/dist/components/Button/utils.js +1 -15
  26. package/dist/components/ButtonBase/ButtonBase.d.ts +4 -4
  27. package/dist/components/ButtonBase/ButtonBase.js +31 -41
  28. package/dist/components/ButtonBase/ButtonBase.style.js +10 -28
  29. package/dist/components/ButtonBase/config.js +1 -1
  30. package/dist/components/ButtonBase/index.js +0 -3
  31. package/dist/components/ButtonBase/utils.js +6 -20
  32. package/dist/components/Card/Card.d.ts +2 -2
  33. package/dist/components/Card/Card.js +4 -10
  34. package/dist/components/Card/Card.style.js +3 -10
  35. package/dist/components/Card/index.js +0 -3
  36. package/dist/components/Chart/BarChart/BarChart.js +10 -29
  37. package/dist/components/Chart/BarChart/components/CustomLabel/CustomLabel.js +6 -13
  38. package/dist/components/Chart/BarChart/components/CustomLabel/index.js +0 -3
  39. package/dist/components/Chart/BarChart/components/CustomTooltip/CustomTooltip.js +5 -15
  40. package/dist/components/Chart/BarChart/components/CustomTooltip/CustomTooltip.style.js +1 -12
  41. package/dist/components/Chart/BarChart/components/CustomTooltip/index.js +0 -3
  42. package/dist/components/Chart/BarChart/components/CustomTooltipContent/CustomTooltipContent.js +4 -11
  43. package/dist/components/Chart/BarChart/components/CustomTooltipContent/CustomTooltipContent.style.js +1 -10
  44. package/dist/components/Chart/BarChart/components/CustomTooltipContent/index.js +0 -3
  45. package/dist/components/Chart/BarChart/index.js +0 -3
  46. package/dist/components/Chart/BarChart/utils.js +4 -24
  47. package/dist/components/Chart/DonutChart/DonutChart.js +2 -13
  48. package/dist/components/Chart/DonutChart/components/CustomLabel/CustomLabel.js +4 -11
  49. package/dist/components/Chart/DonutChart/components/CustomLabel/CustomLabel.style.js +0 -8
  50. package/dist/components/Chart/DonutChart/components/CustomLabel/index.js +0 -3
  51. package/dist/components/Chart/DonutChart/index.js +0 -3
  52. package/dist/components/Chart/LineChart/LineChart.js +7 -22
  53. package/dist/components/Chart/LineChart/components/CustomTooltip/CustomTooltip.js +2 -8
  54. package/dist/components/Chart/LineChart/components/CustomTooltip/CustomTooltip.style.js +1 -10
  55. package/dist/components/Chart/LineChart/components/CustomTooltip/index.js +0 -3
  56. package/dist/components/Chart/LineChart/components/GradientLine/GradientLine.js +1 -7
  57. package/dist/components/Chart/LineChart/components/GradientLine/index.js +0 -3
  58. package/dist/components/Chart/LineChart/index.js +0 -3
  59. package/dist/components/Chart/LineChart/story.utils.js +0 -5
  60. package/dist/components/Chart/LineChart/utils.js +3 -9
  61. package/dist/components/Chart/Wrapper.js +2 -14
  62. package/dist/components/CheckBox/CheckBox.js +17 -39
  63. package/dist/components/CheckBox/CheckBox.style.js +4 -26
  64. package/dist/components/CheckBox/index.js +0 -3
  65. package/dist/components/Chip/Chip.js +13 -33
  66. package/dist/components/Chip/Chip.style.js +5 -15
  67. package/dist/components/Chip/Chip.types.js +1 -1
  68. package/dist/components/Chip/components/Badge/Badge.js +3 -10
  69. package/dist/components/Chip/components/Badge/Badge.style.js +2 -7
  70. package/dist/components/Chip/components/Badge/index.js +0 -3
  71. package/dist/components/Chip/index.js +0 -3
  72. package/dist/components/Chip/utils.js +5 -8
  73. package/dist/components/DatePicker/DatePickInput/DatePickInput.js +16 -37
  74. package/dist/components/DatePicker/DatePickInput/DatePickInput.style.js +0 -5
  75. package/dist/components/DatePicker/DatePickInput/index.js +0 -3
  76. package/dist/components/DatePicker/DatePicker.js +31 -63
  77. package/dist/components/DatePicker/DatePicker.style.js +0 -4
  78. package/dist/components/DatePicker/Day/Day.js +15 -32
  79. package/dist/components/DatePicker/Day/Day.style.js +11 -23
  80. package/dist/components/DatePicker/Day/index.js +0 -3
  81. package/dist/components/DatePicker/Month/Month.js +6 -26
  82. package/dist/components/DatePicker/Month/Month.style.js +1 -12
  83. package/dist/components/DatePicker/Month/Month.utils.js +1 -25
  84. package/dist/components/DatePicker/Month/index.js +0 -3
  85. package/dist/components/DatePicker/OverlayComponent/OverlayComponent.js +17 -33
  86. package/dist/components/DatePicker/OverlayComponent/OverlayComponent.style.js +1 -21
  87. package/dist/components/DatePicker/OverlayComponent/components/MonthWrapper/MonthWrapper.js +13 -32
  88. package/dist/components/DatePicker/OverlayComponent/components/MonthWrapper/MonthWrapper.style.js +2 -20
  89. package/dist/components/DatePicker/OverlayComponent/index.js +0 -3
  90. package/dist/components/DatePicker/index.js +0 -4
  91. package/dist/components/DatePicker/utils.js +0 -7
  92. package/dist/components/Drawer/Drawer.js +0 -9
  93. package/dist/components/Drawer/Drawer.style.js +0 -6
  94. package/dist/components/Drawer/Navigation/MenuItem/MenuItem.js +10 -26
  95. package/dist/components/Drawer/Navigation/Navigation.js +5 -20
  96. package/dist/components/Drawer/Navigation/Navigation.style.js +1 -34
  97. package/dist/components/Drawer/index.js +0 -3
  98. package/dist/components/ExpandCollapse/ExpandCollapse.js +15 -31
  99. package/dist/components/ExpandCollapse/ExpandCollapse.style.js +0 -5
  100. package/dist/components/ExpandCollapse/index.js +0 -3
  101. package/dist/components/ExpandCollapse/useManageContentRef.js +0 -13
  102. package/dist/components/ExpandCollapse/utils.js +2 -4
  103. package/dist/components/Filter/Filter.js +54 -90
  104. package/dist/components/Filter/Filter.style.js +15 -46
  105. package/dist/components/Filter/components/FilterBase/FilterBase.js +18 -36
  106. package/dist/components/Filter/components/FilterBase/index.js +0 -3
  107. package/dist/components/Filter/components/MultiFilter/MultiFilter.js +9 -23
  108. package/dist/components/Filter/components/MultiFilter/MultiFilter.style.js +1 -11
  109. package/dist/components/Filter/components/MultiFilter/index.js +0 -3
  110. package/dist/components/Filter/components/Options/Options.js +7 -16
  111. package/dist/components/Filter/components/Options/Options.style.js +0 -6
  112. package/dist/components/Filter/components/SingleFilter/SingleFilter.js +10 -19
  113. package/dist/components/Filter/components/SingleFilter/components/SearchInput/SearchInput.js +3 -16
  114. package/dist/components/Filter/components/SingleFilter/components/SearchInput/SearchInput.style.js +1 -9
  115. package/dist/components/Filter/components/SingleFilter/components/SearchInput/index.js +0 -3
  116. package/dist/components/Filter/components/SingleFilter/index.js +0 -3
  117. package/dist/components/Filter/hooks/useMultiFilterUtils.js +14 -32
  118. package/dist/components/Filter/index.js +0 -3
  119. package/dist/components/Filter/utils.d.ts +1 -1
  120. package/dist/components/Filter/utils.js +17 -39
  121. package/dist/components/Icon/Icon.js +8 -16
  122. package/dist/components/Icon/Icon.style.js +3 -9
  123. package/dist/components/Icon/assets/iconSelector.js +0 -347
  124. package/dist/components/Icon/index.js +0 -4
  125. package/dist/components/IconButton/IconButton.js +10 -24
  126. package/dist/components/IconButton/IconButton.style.js +0 -3
  127. package/dist/components/IconButton/index.js +0 -3
  128. package/dist/components/Label/Label.js +9 -17
  129. package/dist/components/Label/Label.style.js +1 -8
  130. package/dist/components/Label/index.js +0 -3
  131. package/dist/components/List/List.js +11 -24
  132. package/dist/components/List/List.style.js +4 -16
  133. package/dist/components/List/ListItem/ListItem.js +14 -23
  134. package/dist/components/List/ListItem/ListItem.style.js +5 -14
  135. package/dist/components/List/ListItem/index.js +0 -3
  136. package/dist/components/List/ListItemGroup/ListGroupTitle/ListGroupTitle.js +4 -11
  137. package/dist/components/List/ListItemGroup/ListGroupTitle/ListGroupTitle.style.js +2 -11
  138. package/dist/components/List/ListItemGroup/ListGroupTitle/index.js +0 -3
  139. package/dist/components/List/ListItemGroup/ListItemGroup.js +6 -17
  140. package/dist/components/List/ListItemGroup/index.js +0 -3
  141. package/dist/components/List/NormalList/NormalList.js +9 -20
  142. package/dist/components/List/NormalList/index.js +0 -3
  143. package/dist/components/List/VirtualizedList/VirtualizedList.js +12 -34
  144. package/dist/components/List/VirtualizedList/index.js +0 -3
  145. package/dist/components/List/index.js +0 -3
  146. package/dist/components/List/utils.d.ts +1 -1
  147. package/dist/components/List/utils.js +5 -24
  148. package/dist/components/Loader/Loader.js +3 -10
  149. package/dist/components/Loader/Loader.style.js +0 -5
  150. package/dist/components/Loader/Loader.utils.d.ts +2 -2
  151. package/dist/components/Loader/Loader.utils.js +1 -12
  152. package/dist/components/Loader/components/DotsLoader/DotsLoader.js +1 -8
  153. package/dist/components/Loader/components/DotsLoader/DotsLoader.style.js +1 -14
  154. package/dist/components/Loader/components/DotsLoader/index.js +0 -3
  155. package/dist/components/Loader/components/IndeterminateLoader/IndeterminateLoader.js +1 -8
  156. package/dist/components/Loader/components/IndeterminateLoader/IndeterminateLoader.style.js +1 -19
  157. package/dist/components/Loader/components/IndeterminateLoader/index.js +0 -3
  158. package/dist/components/Loader/components/Spinner/Spinner.js +1 -8
  159. package/dist/components/Loader/components/Spinner/Spinner.style.js +0 -7
  160. package/dist/components/Loader/components/Spinner/index.js +0 -3
  161. package/dist/components/Loader/index.js +0 -3
  162. package/dist/components/Menu/Menu.js +24 -46
  163. package/dist/components/Menu/Menu.style.js +4 -11
  164. package/dist/components/Menu/index.js +0 -3
  165. package/dist/components/Modal/Modal.d.ts +2 -3
  166. package/dist/components/Modal/Modal.js +11 -26
  167. package/dist/components/Modal/Modal.style.js +1 -14
  168. package/dist/components/Modal/ModalContent/ModalContent.js +7 -17
  169. package/dist/components/Modal/ModalContent/ModalContent.style.js +1 -18
  170. package/dist/components/Modal/ModalContent/index.js +0 -3
  171. package/dist/components/Modal/index.js +0 -3
  172. package/dist/components/MultiTextFieldBase/MultiTextFieldBase.js +42 -67
  173. package/dist/components/MultiTextFieldBase/MultiTextFieldBase.style.js +7 -34
  174. package/dist/components/MultiTextFieldBase/hooks.js +9 -30
  175. package/dist/components/MultiTextFieldBase/index.js +0 -3
  176. package/dist/components/Notification/Banner/Banner.js +12 -20
  177. package/dist/components/Notification/Banner/index.js +0 -3
  178. package/dist/components/Notification/InlineNotification/InlineNotification.js +11 -19
  179. package/dist/components/Notification/InlineNotification/index.js +0 -3
  180. package/dist/components/Notification/Notification.style.js +3 -22
  181. package/dist/components/Notification/NotificationVisual/NotificationVisual.js +8 -19
  182. package/dist/components/Notification/NotificationVisual/NotificationVisual.style.js +1 -9
  183. package/dist/components/Notification/NotificationVisual/index.js +0 -3
  184. package/dist/components/Notification/NotificationsContainer/NotificationsContainer.js +3 -12
  185. package/dist/components/Notification/NotificationsContainer/NotificationsContainer.style.js +0 -8
  186. package/dist/components/Notification/NotificationsContainer/index.js +0 -3
  187. package/dist/components/Notification/Snackbar/Snackbar.js +13 -29
  188. package/dist/components/Notification/Snackbar/Snackbar.style.js +1 -18
  189. package/dist/components/Notification/Snackbar/index.js +0 -3
  190. package/dist/components/Notification/subcomponents/CompactNotification/CompactNotification.js +14 -32
  191. package/dist/components/Notification/subcomponents/CompactNotification/CompactNotification.style.js +1 -23
  192. package/dist/components/Notification/subcomponents/CompactNotification/index.js +0 -3
  193. package/dist/components/Notification/subcomponents/NotificationActionsArea/NotificationActionsArea.js +5 -13
  194. package/dist/components/Notification/subcomponents/NotificationActionsArea/index.js +0 -3
  195. package/dist/components/Overlay/Overlay.d.ts +1 -1
  196. package/dist/components/Overlay/Overlay.js +7 -18
  197. package/dist/components/Overlay/Overlay.style.js +3 -33
  198. package/dist/components/Overlay/index.js +0 -3
  199. package/dist/components/Pagination/Pagination.js +19 -29
  200. package/dist/components/Pagination/index.js +0 -3
  201. package/dist/components/Radio/Radio.js +19 -38
  202. package/dist/components/Radio/Radio.style.js +3 -27
  203. package/dist/components/Radio/index.js +0 -3
  204. package/dist/components/RadioGroup/RadioGroup.js +7 -22
  205. package/dist/components/RadioGroup/RadioGroupContext.js +0 -4
  206. package/dist/components/RadioGroup/index.js +0 -3
  207. package/dist/components/RadioGroup/useRadioGroup.js +0 -6
  208. package/dist/components/SearchField/SearchField.js +12 -31
  209. package/dist/components/SearchField/SearchFieldShowcase.js +4 -15
  210. package/dist/components/SearchField/index.js +0 -3
  211. package/dist/components/Select/Select.js +63 -124
  212. package/dist/components/Select/Select.style.js +1 -10
  213. package/dist/components/Select/components/SelectMenu/SelectMenu.js +7 -23
  214. package/dist/components/Select/components/SelectMenu/SelectMenu.style.js +5 -15
  215. package/dist/components/Select/components/SelectMenu/index.js +0 -3
  216. package/dist/components/Select/hooks/useMultiselectUtils.js +18 -39
  217. package/dist/components/Select/index.js +0 -3
  218. package/dist/components/Slider/Slider.js +12 -42
  219. package/dist/components/Slider/Slider.style.js +4 -9
  220. package/dist/components/Slider/components/SliderMark/SliderMark.js +7 -19
  221. package/dist/components/Slider/components/SliderMark/SliderMark.style.js +3 -7
  222. package/dist/components/Slider/components/SliderMark/index.js +0 -3
  223. package/dist/components/Slider/components/SliderThumb/SliderThumb.js +5 -13
  224. package/dist/components/Slider/components/SliderThumb/SliderThumb.style.js +4 -10
  225. package/dist/components/Slider/components/SliderThumb/index.js +0 -3
  226. package/dist/components/Slider/components/SliderTrack/SliderTrack.d.ts +2 -3
  227. package/dist/components/Slider/components/SliderTrack/SliderTrack.js +8 -20
  228. package/dist/components/Slider/components/SliderTrack/SliderTrack.style.js +1 -5
  229. package/dist/components/Slider/components/SliderTrack/index.js +0 -3
  230. package/dist/components/Slider/index.js +0 -3
  231. package/dist/components/Switch/Switch.js +8 -20
  232. package/dist/components/Switch/Switch.style.js +9 -14
  233. package/dist/components/Switch/index.js +0 -3
  234. package/dist/components/Table/Table.d.ts +4 -4
  235. package/dist/components/Table/Table.js +40 -76
  236. package/dist/components/Table/Table.style.js +1 -14
  237. package/dist/components/Table/TableRowContext.js +0 -4
  238. package/dist/components/Table/components/ExtendedColumnItem/ExtendedColumnItem.js +10 -27
  239. package/dist/components/Table/components/ExtendedColumnItem/ExtendedColumnItem.style.js +0 -9
  240. package/dist/components/Table/components/ExtendedColumnItem/index.js +0 -3
  241. package/dist/components/Table/components/RenderRowOrNestedRow/RenderRowOrNestedRow.js +30 -59
  242. package/dist/components/Table/components/RenderRowOrNestedRow/RenderRowOrNestedRow.style.js +4 -13
  243. package/dist/components/Table/components/RenderRowOrNestedRow/components/ContentCell/ContentCell.js +12 -22
  244. package/dist/components/Table/components/RenderRowOrNestedRow/components/ContentCell/ContentCell.style.js +0 -4
  245. package/dist/components/Table/components/RenderRowOrNestedRow/components/ContentCell/index.js +0 -3
  246. package/dist/components/Table/components/RenderRowOrNestedRow/components/ExpandedButtonCell/ExpandedButtonCell.js +6 -16
  247. package/dist/components/Table/components/RenderRowOrNestedRow/components/ExpandedButtonCell/index.js +0 -3
  248. package/dist/components/Table/components/RenderRowOrNestedRow/index.js +0 -3
  249. package/dist/components/Table/components/TableCell/TableCell.d.ts +2 -2
  250. package/dist/components/Table/components/TableCell/TableCell.js +24 -36
  251. package/dist/components/Table/components/TableCell/TableCell.style.js +0 -8
  252. package/dist/components/Table/components/TableCell/index.js +0 -3
  253. package/dist/components/Table/components/TableCell/utils.js +0 -3
  254. package/dist/components/Table/components/TableRow/TableRow.d.ts +2 -2
  255. package/dist/components/Table/components/TableRow/TableRow.js +6 -18
  256. package/dist/components/Table/components/TableRow/index.js +0 -3
  257. package/dist/components/Table/components/TableRowWrapper/TableRowWrapper.js +14 -24
  258. package/dist/components/Table/components/TableRowWrapper/index.js +0 -3
  259. package/dist/components/Table/index.js +0 -3
  260. package/dist/components/Table/utils/index.js +0 -2
  261. package/dist/components/Table/utils/utils.js +1 -7
  262. package/dist/components/TextArea/TextArea.js +10 -27
  263. package/dist/components/TextArea/TextArea.style.js +0 -4
  264. package/dist/components/TextArea/index.js +0 -3
  265. package/dist/components/TextField/TextField.js +55 -85
  266. package/dist/components/TextField/TextField.style.js +1 -6
  267. package/dist/components/TextField/components/commons.d.ts +3 -2
  268. package/dist/components/TextField/components/commons.js +2 -8
  269. package/dist/components/TextField/hooks/useMultiTextFieldUtils.js +14 -31
  270. package/dist/components/TextField/index.js +0 -3
  271. package/dist/components/TextInputBase/TextInputBase.d.ts +6 -6
  272. package/dist/components/TextInputBase/TextInputBase.js +21 -31
  273. package/dist/components/TextInputBase/TextInputBase.style.js +21 -43
  274. package/dist/components/TextInputBase/config.js +1 -1
  275. package/dist/components/TextInputBase/index.js +0 -4
  276. package/dist/components/ThemeProvider/ThemeProvider.d.ts +2 -3
  277. package/dist/components/ThemeProvider/ThemeProvider.js +6 -24
  278. package/dist/components/ThemeProvider/ThemeProvider.style.js +1 -9
  279. package/dist/components/ThemeProvider/index.js +0 -3
  280. package/dist/components/Toast/Toast.d.ts +2 -3
  281. package/dist/components/Toast/Toast.js +16 -33
  282. package/dist/components/Toast/Toast.style.js +1 -28
  283. package/dist/components/Toast/index.js +0 -3
  284. package/dist/components/Tooltip/Tooltip.js +11 -18
  285. package/dist/components/Tooltip/Tooltip.style.js +1 -10
  286. package/dist/components/Tooltip/index.js +0 -3
  287. package/dist/components/TopAppBar/TopAppBar.js +14 -24
  288. package/dist/components/TopAppBar/TopAppBar.style.js +0 -13
  289. package/dist/components/TopAppBar/TopAppBar.types.d.ts +2 -2
  290. package/dist/components/TopAppBar/components/Logo/Logo.style.js +1 -8
  291. package/dist/components/TopAppBar/components/Logo/Logo.wrapper.d.ts +2 -2
  292. package/dist/components/TopAppBar/components/Logo/Logo.wrapper.js +0 -7
  293. package/dist/components/TopAppBar/components/Logo/index.js +0 -3
  294. package/dist/components/TopAppBar/components/Search/Search.js +9 -18
  295. package/dist/components/TopAppBar/components/Search/Search.style.js +1 -13
  296. package/dist/components/TopAppBar/components/Search/index.js +0 -3
  297. package/dist/components/TopAppBar/components/SidebarMenuIcon/SidebarMenuIcon.js +0 -7
  298. package/dist/components/TopAppBar/components/SidebarMenuIcon/SidebarMenuIcon.style.js +0 -4
  299. package/dist/components/TopAppBar/components/SidebarMenuIcon/index.js +0 -3
  300. package/dist/components/TopAppBar/components/UserMenu/UserMenu.js +5 -12
  301. package/dist/components/TopAppBar/components/UserMenu/UserMenu.style.js +0 -4
  302. package/dist/components/TopAppBar/components/UserMenu/index.js +0 -3
  303. package/dist/components/TopAppBar/components/index.js +0 -7
  304. package/dist/components/TopAppBar/index.js +0 -3
  305. package/dist/components/TruncatedContent/TruncatedContent.d.ts +2 -2
  306. package/dist/components/TruncatedContent/TruncatedContent.js +7 -20
  307. package/dist/components/TruncatedContent/TruncatedContent.style.js +1 -5
  308. package/dist/components/TruncatedContent/index.js +0 -3
  309. package/dist/components/storyUtils/Stack/Stack.d.ts +2 -2
  310. package/dist/components/utils/ClickAwayListener/ClickAwayListener.d.ts +2 -2
  311. package/dist/components/utils/ClickAwayListener/ClickAwayListener.js +6 -17
  312. package/dist/components/utils/ClickAwayListener/index.js +0 -3
  313. package/dist/components/utils/DropdownOptions/index.js +0 -5
  314. package/dist/components/utils/PositionInScreen/PositionInScreen.d.ts +3 -2
  315. package/dist/components/utils/PositionInScreen/PositionInScreen.js +13 -24
  316. package/dist/components/utils/PositionInScreen/PositionInScreen.style.js +1 -10
  317. package/dist/components/utils/PositionInScreen/hooks.js +39 -60
  318. package/dist/components/utils/PositionInScreen/index.js +0 -3
  319. package/dist/components/utils/PositionInScreen/utils.js +1 -6
  320. package/dist/components/utils/handleSearch.js +7 -13
  321. package/dist/hooks/index.js +0 -3
  322. package/dist/hooks/useBreakpoints.js +1 -7
  323. package/dist/hooks/useCheck.d.ts +1 -1
  324. package/dist/hooks/useCheck.js +4 -9
  325. package/dist/hooks/useCombinedRefs.js +0 -7
  326. package/dist/hooks/useEscape.js +0 -4
  327. package/dist/hooks/useLoading.js +2 -7
  328. package/dist/hooks/useLocationToGetCurrentMenuItem.js +4 -10
  329. package/dist/hooks/usePagination.js +6 -17
  330. package/dist/hooks/useSearchQueryParams.js +1 -6
  331. package/dist/hooks/useTheme.js +0 -3
  332. package/dist/hooks/useThemeSwitch.d.ts +2 -2
  333. package/dist/hooks/useThemeSwitch.js +4 -15
  334. package/dist/hooks/useToggle.js +2 -9
  335. package/dist/hooks/useTypeColorToColorMatch.d.ts +4 -4
  336. package/dist/hooks/useTypeColorToColorMatch.js +6 -21
  337. package/dist/index.js +1 -108
  338. package/dist/test/index.js +0 -2
  339. package/dist/test/setup.js +2 -5
  340. package/dist/test/utils.d.ts +2 -2
  341. package/dist/test/utils.js +15 -39
  342. package/dist/theme/functions.js +5 -15
  343. package/dist/theme/index.js +0 -12
  344. package/dist/theme/palette.config.js +2 -4
  345. package/dist/theme/palette.js +12 -24
  346. package/dist/theme/spacing.js +1 -3
  347. package/dist/theme/states/disabled.js +1 -4
  348. package/dist/theme/states/focus.js +3 -7
  349. package/dist/theme/states/hover.js +2 -10
  350. package/dist/theme/states/index.js +0 -8
  351. package/dist/theme/states/pressed.js +2 -10
  352. package/dist/theme/states/statesConfig.js +1 -1
  353. package/dist/theme/states/utils.js +4 -9
  354. package/dist/theme/typography.js +0 -2
  355. package/dist/theme/utils.js +2 -23
  356. package/dist/utils/common.js +6 -3
  357. package/dist/utils/errors.js +4 -21
  358. package/dist/utils/helpers.d.ts +2 -2
  359. package/dist/utils/helpers.js +10 -26
  360. package/dist/utils/initLocaleFormat.js +1 -10
  361. package/dist/utils/size-utils.js +2 -20
  362. package/dist/utils/storyshots.js +4 -8
  363. package/dist/utils/themeFunctions.js +3 -25
  364. package/dist/utils/types.d.ts +2 -0
  365. package/package.json +16 -15
@@ -2,55 +2,41 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _useLoading2 = require("../../hooks/useLoading");
7
-
8
6
  var _react = _interopRequireWildcard(require("react"));
9
-
10
- var _ButtonBase = _interopRequireDefault(require("../ButtonBase/ButtonBase"));
11
-
12
7
  var _Button = require("./Button.style");
13
-
14
8
  var _ButtonLoader = _interopRequireDefault(require("./ButtonLoader"));
15
-
9
+ var _ButtonBase = _interopRequireDefault(require("../ButtonBase/ButtonBase"));
16
10
  var _react2 = require("@emotion/react");
17
-
18
11
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
19
-
20
12
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
21
-
22
13
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
-
24
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
25
-
14
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
26
15
  var Button = /*#__PURE__*/_react["default"].forwardRef(function (props, ref) {
27
16
  var _childrenWrapperRef$c;
28
-
29
17
  var _props$size = props.size,
30
- size = _props$size === void 0 ? 'md' : _props$size,
31
- _props$type = props.type,
32
- type = _props$type === void 0 ? 'primary' : _props$type,
33
- _props$color = props.color,
34
- color = _props$color === void 0 ? '' : _props$color,
35
- _props$filled = props.filled,
36
- filled = _props$filled === void 0 ? true : _props$filled,
37
- _props$transparent = props.transparent,
38
- transparent = _props$transparent === void 0 ? false : _props$transparent,
39
- _props$iconLeft = props.iconLeft,
40
- iconLeft = _props$iconLeft === void 0 ? null : _props$iconLeft,
41
- _props$iconRight = props.iconRight,
42
- iconRight = _props$iconRight === void 0 ? null : _props$iconRight,
43
- _props$disabled = props.disabled,
44
- disabled = _props$disabled === void 0 ? false : _props$disabled,
45
- children = props.children,
46
- onClick = props.onClick;
47
-
18
+ size = _props$size === void 0 ? 'md' : _props$size,
19
+ _props$type = props.type,
20
+ type = _props$type === void 0 ? 'primary' : _props$type,
21
+ _props$color = props.color,
22
+ color = _props$color === void 0 ? '' : _props$color,
23
+ _props$filled = props.filled,
24
+ filled = _props$filled === void 0 ? true : _props$filled,
25
+ _props$transparent = props.transparent,
26
+ transparent = _props$transparent === void 0 ? false : _props$transparent,
27
+ _props$iconLeft = props.iconLeft,
28
+ iconLeft = _props$iconLeft === void 0 ? null : _props$iconLeft,
29
+ _props$iconRight = props.iconRight,
30
+ iconRight = _props$iconRight === void 0 ? null : _props$iconRight,
31
+ _props$disabled = props.disabled,
32
+ disabled = _props$disabled === void 0 ? false : _props$disabled,
33
+ children = props.children,
34
+ onClick = props.onClick;
48
35
  var _useLoading = (0, _useLoading2.useLoading)(onClick),
49
- loading = _useLoading.loading,
50
- handleAsyncOperation = _useLoading.handleAsyncOperation;
51
-
36
+ loading = _useLoading.loading,
37
+ handleAsyncOperation = _useLoading.handleAsyncOperation;
52
38
  var childrenWrapperRef = (0, _react.useRef)(null);
53
- var innerButtonWidth = childrenWrapperRef == null ? void 0 : (_childrenWrapperRef$c = childrenWrapperRef.current) == null ? void 0 : _childrenWrapperRef$c.clientWidth;
39
+ var innerButtonWidth = childrenWrapperRef == null || (_childrenWrapperRef$c = childrenWrapperRef.current) == null ? void 0 : _childrenWrapperRef$c.clientWidth;
54
40
  return (0, _react2.jsx)(_ButtonBase["default"], _extends({}, props, {
55
41
  ref: ref,
56
42
  loading: loading,
@@ -81,7 +67,6 @@ var Button = /*#__PURE__*/_react["default"].forwardRef(function (props, ref) {
81
67
  css: (0, _Button.iconStyle)()
82
68
  }, iconRight)));
83
69
  });
84
-
85
70
  Button.displayName = 'Button';
86
71
  var _default = Button;
87
72
  exports["default"] = _default;
@@ -1,8 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.childrenWrapperStyle = exports.iconStyle = exports.buttonSpanStyle = void 0;
5
-
4
+ exports.iconStyle = exports.childrenWrapperStyle = exports.buttonSpanStyle = void 0;
6
5
  var buttonSpanStyle = function buttonSpanStyle() {
7
6
  return function () {
8
7
  return {
@@ -12,9 +11,7 @@ var buttonSpanStyle = function buttonSpanStyle() {
12
11
  };
13
12
  };
14
13
  };
15
-
16
14
  exports.buttonSpanStyle = buttonSpanStyle;
17
-
18
15
  var iconStyle = function iconStyle() {
19
16
  return function () {
20
17
  return {
@@ -22,13 +19,11 @@ var iconStyle = function iconStyle() {
22
19
  };
23
20
  };
24
21
  };
25
-
26
22
  exports.iconStyle = iconStyle;
27
-
28
23
  var childrenWrapperStyle = function childrenWrapperStyle(_ref) {
29
24
  var iconLeft = _ref.iconLeft,
30
- iconRight = _ref.iconRight,
31
- hasChildren = _ref.hasChildren;
25
+ iconRight = _ref.iconRight,
26
+ hasChildren = _ref.hasChildren;
32
27
  return function (theme) {
33
28
  var rightIconExists = hasChildren && iconRight;
34
29
  var leftIconExists = hasChildren && iconLeft;
@@ -38,5 +33,4 @@ var childrenWrapperStyle = function childrenWrapperStyle(_ref) {
38
33
  };
39
34
  };
40
35
  };
41
-
42
36
  exports.childrenWrapperStyle = childrenWrapperStyle;
@@ -2,32 +2,22 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _react = _interopRequireDefault(require("react"));
7
-
8
6
  var _useTypeColorToColorMatch = require("../../../hooks/useTypeColorToColorMatch");
9
-
10
7
  var _index = require("../../../index");
11
-
12
8
  var _ButtonLoader = require("./ButtonLoader.style");
13
-
14
9
  var _Loader = _interopRequireDefault(require("../../Loader"));
15
-
16
10
  var _react2 = require("@emotion/react");
17
-
18
11
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
19
-
20
12
  var ButtonLoader = function ButtonLoader(_ref) {
21
13
  var innerButtonWidth = _ref.innerButtonWidth,
22
- _ref$type = _ref.type,
23
- type = _ref$type === void 0 ? 'primary' : _ref$type,
24
- _ref$color = _ref.color,
25
- color = _ref$color === void 0 ? '' : _ref$color;
14
+ _ref$type = _ref.type,
15
+ type = _ref$type === void 0 ? 'primary' : _ref$type,
16
+ _ref$color = _ref.color,
17
+ color = _ref$color === void 0 ? '' : _ref$color;
26
18
  var theme = (0, _index.useTheme)();
27
-
28
19
  var _useTypeColorToColorM = (0, _useTypeColorToColorMatch.useTypeColorToColorMatch)(),
29
- calculateColorBetweenColorAndType = _useTypeColorToColorM.calculateColorBetweenColorAndType;
30
-
20
+ calculateColorBetweenColorAndType = _useTypeColorToColorM.calculateColorBetweenColorAndType;
31
21
  var calculatedColor = calculateColorBetweenColorAndType(color, type);
32
22
  var spinnerColor = theme.utils.getAAColorFromSwatches(calculatedColor.color, calculatedColor.shade);
33
23
  return (0, _react2.jsx)("div", {
@@ -37,7 +27,6 @@ var ButtonLoader = function ButtonLoader(_ref) {
37
27
  color: spinnerColor
38
28
  }));
39
29
  };
40
-
41
30
  ButtonLoader.displayName = 'Button';
42
31
  var _default = ButtonLoader;
43
32
  exports["default"] = _default;
@@ -2,20 +2,14 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports.centralizedLoader = void 0;
5
-
6
5
  var _react = require("@emotion/react");
7
-
8
6
  var _functions = require("../../../theme/functions");
9
-
10
7
  var _utils = require("../../../theme/utils");
11
-
12
8
  var centralizedLoader = function centralizedLoader(clientWidth) {
13
9
  return (
14
10
  /*#__PURE__*/
15
-
16
11
  /*#__PURE__*/
17
12
  (0, _react.css)("width:", clientWidth ? (0, _utils.rem)(clientWidth) : 'auto', ";", _functions.flex, ";justify-content:center;" + (process.env.NODE_ENV === "production" ? "" : ";label:centralizedLoader;"), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9jb21wb25lbnRzL0J1dHRvbi9CdXR0b25Mb2FkZXIvQnV0dG9uTG9hZGVyLnN0eWxlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUkrRiIsImZpbGUiOiIuLi8uLi8uLi8uLi9zcmMvY29tcG9uZW50cy9CdXR0b24vQnV0dG9uTG9hZGVyL0J1dHRvbkxvYWRlci5zdHlsZS50cyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGNzcywgU2VyaWFsaXplZFN0eWxlcyB9IGZyb20gJ0BlbW90aW9uL3JlYWN0JztcbmltcG9ydCB7IGZsZXggfSBmcm9tICd0aGVtZS9mdW5jdGlvbnMnO1xuaW1wb3J0IHsgcmVtIH0gZnJvbSAndGhlbWUvdXRpbHMnO1xuXG5leHBvcnQgY29uc3QgY2VudHJhbGl6ZWRMb2FkZXI6IChjbGllbnRXaWR0aD86IG51bWJlcikgPT4gU2VyaWFsaXplZFN0eWxlcyA9IGNsaWVudFdpZHRoID0+IGNzc2BcbiAgd2lkdGg6ICR7Y2xpZW50V2lkdGggPyByZW0oY2xpZW50V2lkdGgpIDogJ2F1dG8nfTtcbiAgJHtmbGV4fTtcbiAganVzdGlmeS1jb250ZW50OiBjZW50ZXI7XG5gO1xuIl19 */", process.env.NODE_ENV === "production" ? "" : ";label:centralizedLoader;")
18
13
  );
19
14
  };
20
-
21
15
  exports.centralizedLoader = centralizedLoader;
@@ -2,9 +2,6 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ButtonLoader = _interopRequireDefault(require("./ButtonLoader"));
7
-
8
6
  exports["default"] = _ButtonLoader["default"];
9
-
10
7
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
@@ -2,9 +2,6 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _Button = _interopRequireDefault(require("./Button"));
7
-
8
6
  exports["default"] = _Button["default"];
9
-
10
7
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
@@ -2,17 +2,11 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports.stateBackgroundColor = exports.defineBackgroundColor = void 0;
5
-
6
5
  var _isEmpty = _interopRequireDefault(require("lodash/isEmpty"));
7
-
8
6
  var _polished = require("polished");
9
-
10
7
  var _palette = require("../../theme/palette");
11
-
12
8
  var _themeFunctions = require("../../utils/themeFunctions");
13
-
14
9
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
-
16
10
  /**
17
11
  * This function defines what background-color to show based on type or color passed
18
12
  * if color it retrieves the color directly from the palette
@@ -22,37 +16,29 @@ var defineBackgroundColor = function defineBackgroundColor(theme, color, type, i
22
16
  if (!childrenExists && iconExists) {
23
17
  return 'transparent';
24
18
  }
25
-
26
19
  if (color && !(0, _isEmpty["default"])(color)) {
27
20
  return theme.utils.getColor(color.color, color.shade);
28
21
  }
29
-
30
22
  if (childrenExists && type) {
31
23
  return (0, _themeFunctions.getColorFromType)(type, theme);
32
24
  }
33
-
34
25
  return 'transparent';
35
26
  };
27
+
36
28
  /**
37
29
  * return the correct color to show based on the state that is passed
38
30
  * The state must be 'hover' or 'active' for now
39
31
  * It is being defined by the team that the values will always be 10% and 20%
40
32
  * for transparentize there is a revert to these values to match 90% and 80% accordingly
41
33
  */
42
-
43
-
44
34
  exports.defineBackgroundColor = defineBackgroundColor;
45
-
46
35
  var stateBackgroundColor = function stateBackgroundColor(theme, state, calculatedColor, filled) {
47
36
  var value = state === 'hover' ? 0.1 : 0.2;
48
37
  var color = defineBackgroundColor(theme, calculatedColor);
49
-
50
38
  if (!filled) {
51
39
  // value here is reverted to follow tranparentize e.g (1 - 0.1 = 0.9)
52
40
  return (0, _polished.transparentize)(1 - value, color);
53
41
  }
54
-
55
42
  return calculatedColor.shade > _palette.BASE_SHADE ? (0, _polished.lighten)(value, color) : (0, _polished.darken)(value, color);
56
43
  };
57
-
58
44
  exports.stateBackgroundColor = stateBackgroundColor;
@@ -1,9 +1,9 @@
1
1
  import { CSSObject } from '@emotion/serialize';
2
2
  import React from 'react';
3
+ import { buttonSizes } from './config';
3
4
  import { ClickEvent } from '../../hooks/useLoading';
4
5
  import { AcceptedColorComponentTypes } from '../../utils/themeFunctions';
5
6
  import { TestProps } from '../../utils/types';
6
- import { buttonSizes } from './config';
7
7
  export declare type EventButtonProps = {
8
8
  onClick?: (event: ClickEvent) => void;
9
9
  onBlur?: () => void;
@@ -14,7 +14,7 @@ export declare type Props = {
14
14
  /** the color of the button based on our colors eg. red-500 */
15
15
  color?: string;
16
16
  /** This property define the size of the button. Defaults to 'md' */
17
- size?: typeof buttonSizes[number];
17
+ size?: (typeof buttonSizes)[number];
18
18
  /** This property will make the button fit to its parent width. Defaults to false */
19
19
  block?: boolean;
20
20
  /** Property indicating if the component is filled with a color based on the type */
@@ -26,9 +26,9 @@ export declare type Props = {
26
26
  /** An optional boolean to show if the button is icon */
27
27
  isIconButton?: boolean;
28
28
  /** An optional icon to put on the right of the button */
29
- iconRight?: React.Component | JSX.Element | null;
29
+ iconRight?: React.ReactNode | null;
30
30
  /** An optional icon to put on the left of the button */
31
- iconLeft?: React.Component | JSX.Element | null;
31
+ iconLeft?: React.ReactNode | null;
32
32
  /** Define if the button is in disabled state */
33
33
  disabled?: boolean;
34
34
  /** Defines the button type */
@@ -2,55 +2,46 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _react = _interopRequireDefault(require("react"));
7
-
6
+ var _ButtonBase = require("./ButtonBase.style");
8
7
  var _useTypeColorToColorMatch = require("../../hooks/useTypeColorToColorMatch");
9
-
10
8
  var _helpers = require("../../utils/helpers");
11
-
12
- var _ButtonBase = require("./ButtonBase.style");
13
-
14
9
  var _react2 = require("@emotion/react");
15
-
16
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
17
-
18
11
  //@TODO fix props to not overwrite button props
19
12
  var ButtonBase = /*#__PURE__*/_react["default"].forwardRef(function (props, ref) {
20
13
  var _props$size = props.size,
21
- size = _props$size === void 0 ? 'md' : _props$size,
22
- _props$type = props.type,
23
- type = _props$type === void 0 ? 'primary' : _props$type,
24
- _props$color = props.color,
25
- color = _props$color === void 0 ? '' : _props$color,
26
- _props$block = props.block,
27
- block = _props$block === void 0 ? false : _props$block,
28
- _props$filled = props.filled,
29
- filled = _props$filled === void 0 ? true : _props$filled,
30
- _props$transparent = props.transparent,
31
- transparent = _props$transparent === void 0 ? false : _props$transparent,
32
- _props$iconLeft = props.iconLeft,
33
- iconLeft = _props$iconLeft === void 0 ? null : _props$iconLeft,
34
- _props$iconRight = props.iconRight,
35
- iconRight = _props$iconRight === void 0 ? null : _props$iconRight,
36
- _props$disabled = props.disabled,
37
- disabled = _props$disabled === void 0 ? false : _props$disabled,
38
- _props$loading = props.loading,
39
- loading = _props$loading === void 0 ? false : _props$loading,
40
- children = props.children,
41
- _props$dataTestId = props.dataTestId,
42
- dataTestId = _props$dataTestId === void 0 ? '' : _props$dataTestId,
43
- _props$dataTestPrefix = props.dataTestPrefixId,
44
- dataTestPrefixId = _props$dataTestPrefix === void 0 ? '' : _props$dataTestPrefix,
45
- _props$buttonType = props.buttonType,
46
- buttonType = _props$buttonType === void 0 ? 'button' : _props$buttonType,
47
- _onClick = props.onClick,
48
- onBlur = props.onBlur,
49
- sx = props.sx;
50
-
14
+ size = _props$size === void 0 ? 'md' : _props$size,
15
+ _props$type = props.type,
16
+ type = _props$type === void 0 ? 'primary' : _props$type,
17
+ _props$color = props.color,
18
+ color = _props$color === void 0 ? '' : _props$color,
19
+ _props$block = props.block,
20
+ block = _props$block === void 0 ? false : _props$block,
21
+ _props$filled = props.filled,
22
+ filled = _props$filled === void 0 ? true : _props$filled,
23
+ _props$transparent = props.transparent,
24
+ transparent = _props$transparent === void 0 ? false : _props$transparent,
25
+ _props$iconLeft = props.iconLeft,
26
+ iconLeft = _props$iconLeft === void 0 ? null : _props$iconLeft,
27
+ _props$iconRight = props.iconRight,
28
+ iconRight = _props$iconRight === void 0 ? null : _props$iconRight,
29
+ _props$disabled = props.disabled,
30
+ disabled = _props$disabled === void 0 ? false : _props$disabled,
31
+ _props$loading = props.loading,
32
+ loading = _props$loading === void 0 ? false : _props$loading,
33
+ children = props.children,
34
+ _props$dataTestId = props.dataTestId,
35
+ dataTestId = _props$dataTestId === void 0 ? '' : _props$dataTestId,
36
+ _props$dataTestPrefix = props.dataTestPrefixId,
37
+ dataTestPrefixId = _props$dataTestPrefix === void 0 ? '' : _props$dataTestPrefix,
38
+ _props$buttonType = props.buttonType,
39
+ buttonType = _props$buttonType === void 0 ? 'button' : _props$buttonType,
40
+ _onClick = props.onClick,
41
+ onBlur = props.onBlur,
42
+ sx = props.sx;
51
43
  var _useTypeColorToColorM = (0, _useTypeColorToColorMatch.useTypeColorToColorMatch)(),
52
- calculateColorBetweenColorAndType = _useTypeColorToColorM.calculateColorBetweenColorAndType;
53
-
44
+ calculateColorBetweenColorAndType = _useTypeColorToColorM.calculateColorBetweenColorAndType;
54
45
  var calculatedColor = calculateColorBetweenColorAndType(color, type);
55
46
  var testIdName = dataTestPrefixId + "button";
56
47
  return (0, _react2.jsx)("button", {
@@ -81,7 +72,6 @@ var ButtonBase = /*#__PURE__*/_react["default"].forwardRef(function (props, ref)
81
72
  disabled: disabled || loading
82
73
  }, children);
83
74
  });
84
-
85
75
  ButtonBase.displayName = 'ButtonBase';
86
76
  var _default = ButtonBase;
87
77
  exports["default"] = _default;
@@ -1,46 +1,34 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.iconStyle = exports.buttonSpanStyle = exports.buttonBaseStyle = exports.heightBasedOnSize = void 0;
5
-
4
+ exports.iconStyle = exports.heightBasedOnSize = exports.buttonSpanStyle = exports.buttonBaseStyle = void 0;
6
5
  var _react = require("@emotion/react");
7
-
8
6
  var _utils = require("../../theme/utils");
9
-
10
7
  var _states = require("../../theme/states");
11
-
12
8
  var _config = require("./config");
13
-
14
9
  var _utils2 = require("./utils");
15
-
16
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
17
-
10
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
18
11
  /** Calculates the button specific height based on the size passed to it **/
19
12
  var heightBasedOnSize = function heightBasedOnSize(size) {
20
13
  var _buttonConfig$sizes$s;
21
-
22
14
  return (0, _utils.rem)((_buttonConfig$sizes$s = _config.buttonConfig.sizes[size]) != null ? _buttonConfig$sizes$s : _config.buttonConfig.sizes["default"]);
23
15
  };
24
- /** Calculates the button specific font size based on the size passed to it **/
25
-
26
16
 
17
+ /** Calculates the button specific font size based on the size passed to it **/
27
18
  exports.heightBasedOnSize = heightBasedOnSize;
28
-
29
19
  var fontSizeBasedOnSize = function fontSizeBasedOnSize(theme, size) {
30
20
  var _buttonConfig$fontSiz;
31
-
32
21
  return theme.typography.fontSizes[(_buttonConfig$fontSiz = _config.buttonConfig.fontSize[size]) != null ? _buttonConfig$fontSiz : _config.buttonConfig.fontSize["default"]];
33
22
  };
34
-
35
23
  var buttonBaseStyle = function buttonBaseStyle(_ref) {
36
24
  var type = _ref.type,
37
- filled = _ref.filled,
38
- calculatedColor = _ref.calculatedColor,
39
- size = _ref.size,
40
- block = _ref.block,
41
- transparent = _ref.transparent,
42
- childrenCount = _ref.childrenCount,
43
- sx = _ref.sx;
25
+ filled = _ref.filled,
26
+ calculatedColor = _ref.calculatedColor,
27
+ size = _ref.size,
28
+ block = _ref.block,
29
+ transparent = _ref.transparent,
30
+ childrenCount = _ref.childrenCount,
31
+ sx = _ref.sx;
44
32
  return function (theme) {
45
33
  var backGroundColor = (0, _utils2.defineBackgroundColor)(theme, calculatedColor, type, childrenCount > 0);
46
34
  var isOutlined = !filled && !transparent;
@@ -88,15 +76,12 @@ var buttonBaseStyle = function buttonBaseStyle(_ref) {
88
76
  };
89
77
  return (
90
78
  /*#__PURE__*/
91
-
92
79
  /*#__PURE__*/
93
80
  (0, _react.css)(_extends({}, baseButtonStyles, sx == null ? void 0 : sx.container), process.env.NODE_ENV === "production" ? "" : ";label:buttonBaseStyle;", process.env.NODE_ENV === "production" ? "" : "/*#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ge1xuICByZXR1cm4ge1xuICAgIGRpc3BsYXk6ICdmbGV4JyxcbiAgICBhbGlnbkl0ZW1zOiAnY2VudGVyJyxcbiAgfTtcbn07XG5cbmV4cG9ydCBjb25zdCBpY29uU3R5bGUgPSAoKSA9PiAoKSA9PiAoe1xuICBkaXNwbGF5OiAnaW5saW5lLWZsZXgnLFxufSk7XG4iXX0= */", process.env.NODE_ENV === "production" ? "" : ";label:buttonBaseStyle;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9jb21wb25lbnRzL0J1dHRvbkJhc2UvQnV0dG9uQmFzZS5zdHlsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUEyRVMiLCJmaWxlIjoiLi4vLi4vLi4vc3JjL2NvbXBvbmVudHMvQnV0dG9uQmFzZS9CdXR0b25CYXNlLnN0eWxlLnRzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgY3NzLCBTZXJpYWxpemVkU3R5bGVzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuaW1wb3J0IHsgcmVtIH0gZnJvbSAndGhlbWUvdXRpbHMnO1xuXG5pbXBvcnQgeyBUaGVtZSB9IGZyb20gJy4uLy4uL3RoZW1lJztcbmltcG9ydCB7IGdldERpc2FibGVkLCBnZXRGb2N1cywgZ2V0SG92ZXIsIGdldFByZXNzZWQgfSBmcm9tICcuLi8uLi90aGVtZS9zdGF0ZXMnO1xuaW1wb3J0IHsgQ29sb3JTaGFwZUZyb21Db21wb25lbnQgfSBmcm9tICcuLi8uLi91dGlscy90aGVtZUZ1bmN0aW9ucyc7XG5pbXBvcnQgeyBQcm9wcyB9IGZyb20gJy4vQnV0dG9uQmFzZSc7XG5pbXBvcnQgeyBidXR0b25Db25maWcsIGJ1dHRvblNpemVzIH0gZnJvbSAnLi9jb25maWcnO1xuaW1wb3J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DogY2FsY3VsYXRlZENvbG9yLnNoYWRlLFxuICAgICAgfSkuYmFja2dyb3VuZENvbG9yLFxuICAgIH0sXG4gICAgJzpkaXNhYmxlZCc6IGdldERpc2FibGVkKCksXG4gIH07XG5cbiAgcmV0dXJuIGNzcyh7IC4uLmJhc2VCdXR0b25TdHlsZXMsIC4uLnN4Py5jb250YWluZXIgfSk7XG59O1xuXG5leHBvcnQgY29uc3QgYnV0dG9uU3BhblN0eWxlID0gKCkgPT4gKCkgPT4ge1xuICByZXR1cm4ge1xuICAgIGRpc3BsYXk6ICdmbGV4JyxcbiAgICBhbGlnbkl0ZW1zOiAnY2VudGVyJyxcbiAgfTtcbn07XG5cbmV4cG9ydCBjb25zdCBpY29uU3R5bGUgPSAoKSA9PiAoKSA9PiAoe1xuICBkaXNwbGF5OiAnaW5saW5lLWZsZXgnLFxufSk7XG4iXX0= */")
94
81
  );
95
82
  };
96
83
  };
97
-
98
84
  exports.buttonBaseStyle = buttonBaseStyle;
99
-
100
85
  var buttonSpanStyle = function buttonSpanStyle() {
101
86
  return function () {
102
87
  return {
@@ -105,9 +90,7 @@ var buttonSpanStyle = function buttonSpanStyle() {
105
90
  };
106
91
  };
107
92
  };
108
-
109
93
  exports.buttonSpanStyle = buttonSpanStyle;
110
-
111
94
  var iconStyle = function iconStyle() {
112
95
  return function () {
113
96
  return {
@@ -115,5 +98,4 @@ var iconStyle = function iconStyle() {
115
98
  };
116
99
  };
117
100
  };
118
-
119
101
  exports.iconStyle = iconStyle;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.buttonConfig = exports.buttonSizes = exports.SM = exports.MD = exports.LG = void 0;
4
+ exports.buttonSizes = exports.buttonConfig = exports.SM = exports.MD = exports.LG = void 0;
5
5
  var LG = 'lg';
6
6
  exports.LG = LG;
7
7
  var MD = 'md';
@@ -2,9 +2,6 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ButtonBase = _interopRequireDefault(require("./ButtonBase"));
7
-
8
6
  exports["default"] = _ButtonBase["default"];
9
-
10
7
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
@@ -1,16 +1,11 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.calculateButtonColor = exports.defineBackgroundColor = void 0;
5
-
4
+ exports.defineBackgroundColor = exports.calculateButtonColor = void 0;
6
5
  var _isEmpty = _interopRequireDefault(require("lodash/isEmpty"));
7
-
8
6
  var _themeFunctions = require("../../utils/themeFunctions");
9
-
10
7
  var _config = require("./config");
11
-
12
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
-
14
9
  /**
15
10
  * This function defines what background-color to show based on type or color passed
16
11
  * if color it retrieves the color directly from the palette
@@ -20,44 +15,35 @@ var defineBackgroundColor = function defineBackgroundColor(theme, color, type, c
20
15
  if (type === 'link') {
21
16
  return 'transparent';
22
17
  }
23
-
24
18
  if (color && !(0, _isEmpty["default"])(color)) {
25
19
  return theme.utils.getColor(color.color, color.shade);
26
20
  }
27
-
28
21
  if (childrenExists && type) {
29
22
  return (0, _themeFunctions.getColorFromType)(type, theme);
30
23
  }
31
-
32
24
  return 'transparent';
33
25
  };
26
+
34
27
  /**
35
28
  * This function defines what color to show based on type or color passed
36
29
  * if type is link uses the link color
37
30
  * if it's background is transparent ( transparent or Outlined ) then it uses the background color
38
31
  * else it uses the calculated color
39
32
  */
40
-
41
-
42
33
  exports.defineBackgroundColor = defineBackgroundColor;
43
-
44
34
  var calculateButtonColor = function calculateButtonColor(_ref) {
45
35
  var type = _ref.type,
46
- isBackgroundTransparent = _ref.isBackgroundTransparent,
47
- backGroundColor = _ref.backGroundColor,
48
- calculatedColor = _ref.calculatedColor,
49
- theme = _ref.theme;
50
-
36
+ isBackgroundTransparent = _ref.isBackgroundTransparent,
37
+ backGroundColor = _ref.backGroundColor,
38
+ calculatedColor = _ref.calculatedColor,
39
+ theme = _ref.theme;
51
40
  if (type === 'link') {
52
41
  var color = _config.buttonConfig.types.link.color;
53
42
  return theme.utils.getColor(color.name, color.shade);
54
43
  }
55
-
56
44
  if (isBackgroundTransparent) {
57
45
  return backGroundColor;
58
46
  }
59
-
60
47
  return theme.utils.getAAColorFromSwatches(calculatedColor.color, calculatedColor.shade);
61
48
  };
62
-
63
49
  exports.calculateButtonColor = calculateButtonColor;
@@ -1,5 +1,5 @@
1
1
  import { Elevation, Spacing } from 'index';
2
- import React from 'react';
2
+ import { ReactFCC } from 'utils/types';
3
3
  export declare type Props = {
4
4
  /** Elevation of Card */
5
5
  elevated?: keyof Elevation;
@@ -8,5 +8,5 @@ export declare type Props = {
8
8
  /** Border radius of Card: if not provided it defaults to 0 */
9
9
  radius?: keyof Spacing;
10
10
  };
11
- declare const Card: React.FC<Props>;
11
+ declare const Card: ReactFCC<Props>;
12
12
  export default Card;
@@ -2,21 +2,16 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _react = _interopRequireDefault(require("react"));
7
-
8
6
  var _Card = require("./Card.style");
9
-
10
7
  var _react2 = require("@emotion/react");
11
-
12
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
-
14
9
  var Card = function Card(_ref) {
15
10
  var elevated = _ref.elevated,
16
- _ref$transparent = _ref.transparent,
17
- transparent = _ref$transparent === void 0 ? false : _ref$transparent,
18
- radius = _ref.radius,
19
- children = _ref.children;
11
+ _ref$transparent = _ref.transparent,
12
+ transparent = _ref$transparent === void 0 ? false : _ref$transparent,
13
+ radius = _ref.radius,
14
+ children = _ref.children;
20
15
  return (0, _react2.jsx)("div", {
21
16
  css: (0, _Card.cardStyle)({
22
17
  elevated: elevated,
@@ -25,6 +20,5 @@ var Card = function Card(_ref) {
25
20
  })
26
21
  }, children);
27
22
  };
28
-
29
23
  var _default = Card;
30
24
  exports["default"] = _default;