@algolia/satellite 1.0.0-beta.147 → 1.0.0-beta.148

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 (411) hide show
  1. package/cjs/AnnouncementBadge/AnnouncementBadge.js +7 -24
  2. package/cjs/AnnouncementBadge/index.js +0 -5
  3. package/cjs/AutoComplete/AutoComplete.js +68 -163
  4. package/cjs/AutoComplete/AutoComplete.tailwind.js +2 -5
  5. package/cjs/AutoComplete/components/AutoCompleteEmptyState.js +5 -14
  6. package/cjs/AutoComplete/components/DefaultOptionItem.js +2 -11
  7. package/cjs/AutoComplete/index.js +0 -11
  8. package/cjs/AutoComplete/utils.js +0 -8
  9. package/cjs/Avatars/ApplicationAvatar.js +3 -13
  10. package/cjs/Avatars/UserAvatar.js +6 -20
  11. package/cjs/Avatars/index.js +0 -7
  12. package/cjs/Avatars/utils.js +6 -37
  13. package/cjs/Badge/Badge.js +13 -36
  14. package/cjs/Badge/index.js +0 -5
  15. package/cjs/Banners/Alert/Alert.js +18 -28
  16. package/cjs/Banners/Alert/index.js +0 -5
  17. package/cjs/Banners/BigBertha/BigBertha.js +1 -9
  18. package/cjs/Banners/BigBertha/index.js +0 -5
  19. package/cjs/Banners/Promote/Promote.js +8 -19
  20. package/cjs/Banners/Promote/index.js +0 -5
  21. package/cjs/Banners/index.js +0 -6
  22. package/cjs/Button/Button.js +13 -33
  23. package/cjs/Button/Button.tailwind.js +3 -5
  24. package/cjs/Button/ButtonGroup.js +3 -11
  25. package/cjs/Button/IconButton.js +12 -35
  26. package/cjs/Button/index.js +0 -11
  27. package/cjs/Button/styles.js +1 -10
  28. package/cjs/Button/types.js +0 -1
  29. package/cjs/Card/Card.js +6 -21
  30. package/cjs/Card/Card.tailwind.js +1 -2
  31. package/cjs/Card/components/CardHeader.js +1 -14
  32. package/cjs/Card/components/CardTitle.js +2 -15
  33. package/cjs/Card/index.js +0 -9
  34. package/cjs/Checkbox/Checkbox.js +14 -38
  35. package/cjs/Checkbox/Checkbox.tailwind.js +1 -3
  36. package/cjs/Checkbox/index.js +0 -5
  37. package/cjs/ClickAwayContainer/ClickAwayContainer.js +11 -23
  38. package/cjs/ClickAwayContainer/index.js +0 -2
  39. package/cjs/DatePicker/DatePicker/DatePicker.js +13 -46
  40. package/cjs/DatePicker/DatePicker/datePickerReducer.js +0 -15
  41. package/cjs/DatePicker/DatePicker/index.js +0 -7
  42. package/cjs/DatePicker/DatePicker.tailwind.js +2 -12
  43. package/cjs/DatePicker/DateRangePicker/DateRangePicker.js +29 -72
  44. package/cjs/DatePicker/DateRangePicker/DateRangePickerDisplay.js +4 -14
  45. package/cjs/DatePicker/DateRangePicker/dateRangePickerReducer.js +2 -28
  46. package/cjs/DatePicker/DateRangePicker/dateRangePickerTimeRange.js +0 -6
  47. package/cjs/DatePicker/DateRangePicker/index.js +0 -9
  48. package/cjs/DatePicker/components/Calendar.js +5 -16
  49. package/cjs/DatePicker/components/Display.js +3 -9
  50. package/cjs/DatePicker/components/Footer.js +0 -7
  51. package/cjs/DatePicker/components/FooterActions.js +3 -11
  52. package/cjs/DatePicker/components/Modal.js +17 -39
  53. package/cjs/DatePicker/components/NavBar.js +12 -34
  54. package/cjs/DatePicker/components/SidePanel.js +0 -7
  55. package/cjs/DatePicker/components/index.js +0 -7
  56. package/cjs/DatePicker/index.js +0 -9
  57. package/cjs/DatePicker/utils.js +0 -4
  58. package/cjs/Dropdown/Dropdown.js +23 -58
  59. package/cjs/Dropdown/DropdownButton.js +3 -20
  60. package/cjs/Dropdown/DropdownContext.js +0 -6
  61. package/cjs/Dropdown/components/DropdownButtonItem.js +5 -21
  62. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.js +10 -25
  63. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.js +2 -6
  64. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroupContext.js +0 -6
  65. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.js +6 -16
  66. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.js +6 -15
  67. package/cjs/Dropdown/components/DropdownCollapsibleItem/index.js +0 -9
  68. package/cjs/Dropdown/components/DropdownDivider.js +0 -7
  69. package/cjs/Dropdown/components/DropdownFooterItem.js +2 -15
  70. package/cjs/Dropdown/components/DropdownLinkItem.js +6 -23
  71. package/cjs/Dropdown/components/DropdownRadioItem.js +4 -20
  72. package/cjs/Dropdown/components/DropdownTitle.js +1 -14
  73. package/cjs/Dropdown/components/DropdownToggleItem.js +5 -22
  74. package/cjs/Dropdown/index.js +0 -27
  75. package/cjs/Dropdown/useDropdownItemProps.js +1 -14
  76. package/cjs/Dropzone/Dropzone.js +27 -62
  77. package/cjs/Dropzone/index.js +0 -5
  78. package/cjs/EmptyState/EmptyState.js +12 -23
  79. package/cjs/EmptyState/EmptyState.tailwind.js +0 -1
  80. package/cjs/EmptyState/index.js +0 -7
  81. package/cjs/Field/Field.js +8 -21
  82. package/cjs/Field/FieldStateContext.js +0 -2
  83. package/cjs/Field/index.js +0 -9
  84. package/cjs/Field/useFieldState.js +0 -7
  85. package/cjs/Flag/Flag.js +17 -40
  86. package/cjs/Flag/Flag.tailwind.js +0 -1
  87. package/cjs/Flag/Flags.js +4 -19
  88. package/cjs/Flag/index.js +0 -9
  89. package/cjs/FlexGrid/FlexGrid.js +13 -24
  90. package/cjs/FlexGrid/FlexGrid.tailwind.js +4 -11
  91. package/cjs/FlexGrid/index.js +0 -5
  92. package/cjs/HelpUnderline/HelpUnderline.js +5 -14
  93. package/cjs/HelpUnderline/HelpUnderline.tailwind.js +1 -2
  94. package/cjs/HelpUnderline/index.js +0 -5
  95. package/cjs/Input/Input.js +26 -70
  96. package/cjs/Input/Input.tailwind.js +1 -4
  97. package/cjs/Input/index.js +0 -5
  98. package/cjs/Insert/Insert.js +7 -17
  99. package/cjs/Insert/index.js +0 -5
  100. package/cjs/InstantSearch/InstantSearch.tailwind.js +4 -10
  101. package/cjs/KeyboardKey/KeyboardKey.js +1 -12
  102. package/cjs/KeyboardKey/KeyboardKey.tailwind.js +1 -2
  103. package/cjs/KeyboardKey/index.js +0 -2
  104. package/cjs/Link/BaseLink.js +2 -12
  105. package/cjs/Link/ButtonLink.js +3 -17
  106. package/cjs/Link/IconButtonLink.js +2 -13
  107. package/cjs/Link/Link.js +6 -23
  108. package/cjs/Link/index.js +0 -11
  109. package/cjs/Medallion/Medallion.js +5 -14
  110. package/cjs/Medallion/Medallion.tailwind.js +3 -6
  111. package/cjs/Medallion/index.js +0 -7
  112. package/cjs/Modal/Modal.js +21 -57
  113. package/cjs/Modal/Modal.tailwind.js +3 -3
  114. package/cjs/Modal/components/ModalFooter.js +2 -16
  115. package/cjs/Modal/components/ModalSection.js +3 -11
  116. package/cjs/Modal/index.js +0 -9
  117. package/cjs/Pagination/CompactPagination/CompactPagination.js +1 -22
  118. package/cjs/Pagination/CompactPagination/index.js +0 -5
  119. package/cjs/Pagination/DotPagination/DotPagination.js +5 -19
  120. package/cjs/Pagination/DotPagination/index.js +0 -5
  121. package/cjs/Pagination/Pagination/Pagination.js +9 -34
  122. package/cjs/Pagination/Pagination/index.js +0 -5
  123. package/cjs/Pagination/index.js +0 -9
  124. package/cjs/ProgressBar/ProgressBar.js +3 -16
  125. package/cjs/ProgressBar/ProgressBar.tailwind.js +1 -3
  126. package/cjs/ProgressBar/index.js +0 -5
  127. package/cjs/ProgressSpinner/ProgressSpinner.js +8 -20
  128. package/cjs/ProgressSpinner/ProgressSpinner.tailwind.js +2 -3
  129. package/cjs/ProgressSpinner/index.js +0 -5
  130. package/cjs/RadioGroup/RadioButton.js +1 -14
  131. package/cjs/RadioGroup/RadioButton.tailwind.js +1 -4
  132. package/cjs/RadioGroup/RadioGroup.js +19 -38
  133. package/cjs/RadioGroup/RadiogroupContext.js +0 -6
  134. package/cjs/RadioGroup/index.js +0 -9
  135. package/cjs/RangeSlider/RangeSlider.js +26 -43
  136. package/cjs/RangeSlider/RangeSlider.tailwind.js +1 -3
  137. package/cjs/RangeSlider/index.js +0 -5
  138. package/cjs/Satellite/Satellite.js +4 -10
  139. package/cjs/Satellite/SatelliteContext.js +0 -9
  140. package/cjs/Satellite/SatelliteRouter.js +2 -9
  141. package/cjs/Satellite/index.js +0 -13
  142. package/cjs/Satellite/locale.js +1 -7
  143. package/cjs/Satellite/useCreatePortal.js +2 -8
  144. package/cjs/ScrollIndicator/ScrollIndicator.js +18 -41
  145. package/cjs/ScrollIndicator/ScrollIndicator.tailwind.js +1 -3
  146. package/cjs/ScrollIndicator/index.js +0 -5
  147. package/cjs/Select/Select.js +4 -17
  148. package/cjs/Select/Select.tailwind.js +2 -5
  149. package/cjs/Select/index.js +0 -5
  150. package/cjs/Sidebar/Sidebar.js +11 -30
  151. package/cjs/Sidebar/SidebarButtonLink.js +10 -30
  152. package/cjs/Sidebar/SidebarContext.js +0 -6
  153. package/cjs/Sidebar/SidebarHeader.js +1 -9
  154. package/cjs/Sidebar/SidebarHeading.js +3 -14
  155. package/cjs/Sidebar/SidebarLink.js +5 -20
  156. package/cjs/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.js +2 -11
  157. package/cjs/Sidebar/SidebarLinksGroup/SidebarGroupLink.js +3 -14
  158. package/cjs/Sidebar/SidebarLinksGroup/SidebarLinksGroup.js +8 -31
  159. package/cjs/Sidebar/SidebarLinksGroup/index.js +0 -2
  160. package/cjs/Sidebar/SidebarNav.js +5 -16
  161. package/cjs/Sidebar/index.js +0 -17
  162. package/cjs/Switch/Switch.js +15 -36
  163. package/cjs/Switch/Switch.tailwind.js +1 -2
  164. package/cjs/Switch/SwitchOption.js +2 -15
  165. package/cjs/Switch/index.js +0 -7
  166. package/cjs/Switch/utils.js +0 -9
  167. package/cjs/Tables/DataTable/DataTable.js +28 -70
  168. package/cjs/Tables/DataTable/DataTable.tailwind.js +2 -2
  169. package/cjs/Tables/DataTable/components/Body.js +14 -33
  170. package/cjs/Tables/DataTable/components/Footer.js +1 -17
  171. package/cjs/Tables/DataTable/components/Header.js +5 -12
  172. package/cjs/Tables/DataTable/components/HeaderCell.js +10 -27
  173. package/cjs/Tables/DataTable/components/Loader.js +4 -17
  174. package/cjs/Tables/DataTable/components/index.js +0 -10
  175. package/cjs/Tables/DataTable/index.js +0 -7
  176. package/cjs/Tables/DataTable/utils.js +0 -9
  177. package/cjs/Tables/Table/Table.js +7 -21
  178. package/cjs/Tables/Table/Table.tailwind.js +1 -2
  179. package/cjs/Tables/Table/components/TableFooter.js +2 -10
  180. package/cjs/Tables/Table/index.js +0 -7
  181. package/cjs/Tables/index.js +0 -7
  182. package/cjs/Tabs/ContentTabs.js +10 -21
  183. package/cjs/Tabs/LinkTabs.js +5 -18
  184. package/cjs/Tabs/Tabs.tailwind.js +1 -2
  185. package/cjs/Tabs/components/LinkTab.js +2 -27
  186. package/cjs/Tabs/index.js +0 -9
  187. package/cjs/Tabs/utils.js +0 -5
  188. package/cjs/Tag/Tag.js +7 -26
  189. package/cjs/Tag/Tag.tailwind.js +1 -2
  190. package/cjs/Tag/index.js +0 -5
  191. package/cjs/TextArea/TextArea.js +1 -14
  192. package/cjs/TextArea/TextArea.tailwind.js +1 -4
  193. package/cjs/TextArea/index.js +0 -5
  194. package/cjs/TextWrap/TextWrap.js +3 -18
  195. package/cjs/TextWrap/index.js +0 -5
  196. package/cjs/Toggle/Toggle.js +6 -27
  197. package/cjs/Toggle/Toggle.tailwind.js +1 -3
  198. package/cjs/Toggle/index.js +0 -5
  199. package/cjs/Tooltip/OverflowTooltipWrapper.js +33 -62
  200. package/cjs/Tooltip/Tooltip.js +4 -17
  201. package/cjs/Tooltip/Tooltip.tailwind.js +3 -5
  202. package/cjs/Tooltip/TooltipWrapper.js +43 -71
  203. package/cjs/Tooltip/index.js +0 -9
  204. package/cjs/Typography/Typography.tailwind.js +12 -18
  205. package/cjs/UserContent/UserContent.js +3 -11
  206. package/cjs/UserContent/UserContent.tailwind.js +2 -11
  207. package/cjs/index.js +0 -89
  208. package/cjs/styles/base.tailwind.js +7 -7
  209. package/cjs/styles/colors.js +7 -7
  210. package/cjs/styles/disabledColor.js +1 -4
  211. package/cjs/styles/helpers/icons.js +5 -11
  212. package/cjs/styles/helpers/makePurgeCssExtractor.js +3 -15
  213. package/cjs/styles/helpers/makeTailwindPrefixer.js +1 -9
  214. package/cjs/styles/helpers/prefixTailwindClassName.js +6 -6
  215. package/cjs/styles/helpers/satellitePrefixer.js +1 -2
  216. package/cjs/styles/rgba.js +1 -3
  217. package/cjs/styles/tailwind.config.js +4 -11
  218. package/cjs/styles/zIndexes.js +1 -0
  219. package/cjs/utilities/utilities.tailwind.js +0 -3
  220. package/cjs/utils/event-polyfill.js +0 -2
  221. package/cjs/utils/formatters.js +12 -19
  222. package/cjs/utils/genericChangeHandler.js +0 -6
  223. package/cjs/utils/hashCode.js +0 -5
  224. package/cjs/utils/index.js +0 -7
  225. package/cjs/utils/isCssPropertySupported.js +0 -3
  226. package/cjs/utils/isNil.js +0 -2
  227. package/cjs/utils/isRenderedChild.js +0 -2
  228. package/cjs/utils/matchLocation.js +0 -4
  229. package/cjs/utils/onlyText.js +3 -12
  230. package/cjs/utils/parseUrl.js +2 -4
  231. package/cjs/utils/pluralize.js +2 -7
  232. package/cjs/utils/range.js +0 -2
  233. package/cjs/utils/toSentenceCase.js +0 -4
  234. package/cjs/utils/uniqBy.js +0 -4
  235. package/cjs/utils/uniqueId.js +0 -2
  236. package/cjs/utils/useForwardedRef.js +0 -6
  237. package/cjs/utils/useLinkProps.js +1 -13
  238. package/cjs/utils/useTriggerInputChange.js +2 -4
  239. package/esm/AnnouncementBadge/AnnouncementBadge.js +7 -14
  240. package/esm/AutoComplete/AutoComplete.js +68 -158
  241. package/esm/AutoComplete/AutoComplete.tailwind.js +2 -2
  242. package/esm/AutoComplete/components/AutoCompleteEmptyState.js +5 -7
  243. package/esm/AutoComplete/components/DefaultOptionItem.js +2 -8
  244. package/esm/AutoComplete/utils.js +0 -2
  245. package/esm/Avatars/ApplicationAvatar.js +3 -6
  246. package/esm/Avatars/UserAvatar.js +6 -12
  247. package/esm/Avatars/utils.js +7 -23
  248. package/esm/Badge/Badge.js +13 -28
  249. package/esm/Banners/Alert/Alert.js +18 -20
  250. package/esm/Banners/BigBertha/BigBertha.js +1 -4
  251. package/esm/Banners/Promote/Promote.js +8 -10
  252. package/esm/Button/Button.js +13 -21
  253. package/esm/Button/Button.tailwind.js +3 -2
  254. package/esm/Button/ButtonGroup.js +3 -6
  255. package/esm/Button/IconButton.js +12 -22
  256. package/esm/Button/styles.js +1 -5
  257. package/esm/Card/Card.js +6 -12
  258. package/esm/Card/Card.tailwind.js +1 -1
  259. package/esm/Card/components/CardHeader.js +1 -7
  260. package/esm/Card/components/CardTitle.js +2 -8
  261. package/esm/Checkbox/Checkbox.js +14 -28
  262. package/esm/Checkbox/Checkbox.tailwind.js +1 -1
  263. package/esm/ClickAwayContainer/ClickAwayContainer.js +11 -13
  264. package/esm/DatePicker/DatePicker/DatePicker.js +13 -31
  265. package/esm/DatePicker/DatePicker/datePickerReducer.js +0 -9
  266. package/esm/DatePicker/DatePicker.tailwind.js +2 -9
  267. package/esm/DatePicker/DateRangePicker/DateRangePicker.js +29 -55
  268. package/esm/DatePicker/DateRangePicker/DateRangePickerDisplay.js +4 -8
  269. package/esm/DatePicker/DateRangePicker/dateRangePickerReducer.js +2 -16
  270. package/esm/DatePicker/components/Calendar.js +5 -10
  271. package/esm/DatePicker/components/Display.js +3 -5
  272. package/esm/DatePicker/components/Footer.js +0 -4
  273. package/esm/DatePicker/components/FooterActions.js +3 -7
  274. package/esm/DatePicker/components/Modal.js +17 -27
  275. package/esm/DatePicker/components/NavBar.js +12 -22
  276. package/esm/DatePicker/components/SidePanel.js +0 -4
  277. package/esm/Dropdown/Dropdown.js +23 -34
  278. package/esm/Dropdown/DropdownButton.js +3 -11
  279. package/esm/Dropdown/DropdownContext.js +0 -2
  280. package/esm/Dropdown/components/DropdownButtonItem.js +5 -12
  281. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.js +10 -15
  282. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.js +2 -2
  283. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroupContext.js +0 -2
  284. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.js +6 -9
  285. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.js +6 -9
  286. package/esm/Dropdown/components/DropdownDivider.js +0 -2
  287. package/esm/Dropdown/components/DropdownFooterItem.js +2 -8
  288. package/esm/Dropdown/components/DropdownLinkItem.js +6 -13
  289. package/esm/Dropdown/components/DropdownRadioItem.js +4 -11
  290. package/esm/Dropdown/components/DropdownTitle.js +1 -7
  291. package/esm/Dropdown/components/DropdownToggleItem.js +5 -12
  292. package/esm/Dropdown/useDropdownItemProps.js +1 -7
  293. package/esm/Dropzone/Dropzone.js +27 -45
  294. package/esm/EmptyState/EmptyState.js +12 -16
  295. package/esm/Field/Field.js +8 -11
  296. package/esm/Flag/Flag.js +17 -25
  297. package/esm/Flag/Flags.js +4 -9
  298. package/esm/FlexGrid/FlexGrid.js +13 -15
  299. package/esm/FlexGrid/FlexGrid.tailwind.js +4 -9
  300. package/esm/HelpUnderline/HelpUnderline.js +5 -7
  301. package/esm/HelpUnderline/HelpUnderline.tailwind.js +1 -1
  302. package/esm/Input/Input.js +26 -54
  303. package/esm/Input/Input.tailwind.js +1 -1
  304. package/esm/Insert/Insert.js +7 -11
  305. package/esm/InstantSearch/InstantSearch.tailwind.js +4 -4
  306. package/esm/KeyboardKey/KeyboardKey.js +1 -3
  307. package/esm/KeyboardKey/KeyboardKey.tailwind.js +1 -1
  308. package/esm/Link/BaseLink.js +2 -6
  309. package/esm/Link/ButtonLink.js +3 -9
  310. package/esm/Link/IconButtonLink.js +2 -6
  311. package/esm/Link/Link.js +6 -14
  312. package/esm/Medallion/Medallion.js +5 -7
  313. package/esm/Medallion/Medallion.tailwind.js +3 -2
  314. package/esm/Modal/Modal.js +21 -38
  315. package/esm/Modal/Modal.tailwind.js +3 -2
  316. package/esm/Modal/components/ModalFooter.js +2 -8
  317. package/esm/Modal/components/ModalSection.js +3 -5
  318. package/esm/Pagination/CompactPagination/CompactPagination.js +1 -9
  319. package/esm/Pagination/DotPagination/DotPagination.js +5 -11
  320. package/esm/Pagination/Pagination/Pagination.js +9 -21
  321. package/esm/ProgressBar/ProgressBar.js +3 -10
  322. package/esm/ProgressBar/ProgressBar.tailwind.js +1 -1
  323. package/esm/ProgressSpinner/ProgressSpinner.js +8 -12
  324. package/esm/ProgressSpinner/ProgressSpinner.tailwind.js +2 -2
  325. package/esm/RadioGroup/RadioButton.js +1 -7
  326. package/esm/RadioGroup/RadioButton.tailwind.js +1 -1
  327. package/esm/RadioGroup/RadioGroup.js +19 -25
  328. package/esm/RadioGroup/RadiogroupContext.js +0 -2
  329. package/esm/RangeSlider/RangeSlider.js +26 -35
  330. package/esm/RangeSlider/RangeSlider.tailwind.js +1 -1
  331. package/esm/Satellite/Satellite.js +4 -4
  332. package/esm/Satellite/SatelliteContext.js +0 -3
  333. package/esm/Satellite/SatelliteRouter.js +2 -4
  334. package/esm/Satellite/locale.js +1 -2
  335. package/esm/Satellite/useCreatePortal.js +2 -2
  336. package/esm/ScrollIndicator/ScrollIndicator.js +18 -31
  337. package/esm/ScrollIndicator/ScrollIndicator.tailwind.js +1 -1
  338. package/esm/Select/Select.js +4 -9
  339. package/esm/Select/Select.tailwind.js +2 -2
  340. package/esm/Sidebar/Sidebar.js +11 -17
  341. package/esm/Sidebar/SidebarButtonLink.js +10 -20
  342. package/esm/Sidebar/SidebarContext.js +0 -2
  343. package/esm/Sidebar/SidebarHeader.js +1 -3
  344. package/esm/Sidebar/SidebarHeading.js +3 -7
  345. package/esm/Sidebar/SidebarLink.js +5 -11
  346. package/esm/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.js +2 -4
  347. package/esm/Sidebar/SidebarLinksGroup/SidebarGroupLink.js +3 -7
  348. package/esm/Sidebar/SidebarLinksGroup/SidebarLinksGroup.js +8 -18
  349. package/esm/Sidebar/SidebarNav.js +5 -9
  350. package/esm/Switch/Switch.js +15 -24
  351. package/esm/Switch/Switch.tailwind.js +1 -1
  352. package/esm/Switch/SwitchOption.js +2 -6
  353. package/esm/Tables/DataTable/DataTable.js +28 -49
  354. package/esm/Tables/DataTable/DataTable.tailwind.js +2 -1
  355. package/esm/Tables/DataTable/components/Body.js +14 -23
  356. package/esm/Tables/DataTable/components/Footer.js +1 -8
  357. package/esm/Tables/DataTable/components/Header.js +5 -6
  358. package/esm/Tables/DataTable/components/HeaderCell.js +10 -17
  359. package/esm/Tables/DataTable/components/Loader.js +4 -8
  360. package/esm/Tables/DataTable/utils.js +0 -1
  361. package/esm/Tables/Table/Table.js +7 -14
  362. package/esm/Tables/Table/Table.tailwind.js +1 -1
  363. package/esm/Tables/Table/components/TableFooter.js +2 -4
  364. package/esm/Tabs/ContentTabs.js +10 -12
  365. package/esm/Tabs/LinkTabs.js +5 -7
  366. package/esm/Tabs/Tabs.tailwind.js +1 -1
  367. package/esm/Tabs/components/LinkTab.js +2 -18
  368. package/esm/Tabs/utils.js +0 -2
  369. package/esm/Tag/Tag.js +7 -16
  370. package/esm/Tag/Tag.tailwind.js +1 -1
  371. package/esm/TextArea/TextArea.js +1 -7
  372. package/esm/TextArea/TextArea.tailwind.js +1 -1
  373. package/esm/TextWrap/TextWrap.js +3 -11
  374. package/esm/Toggle/Toggle.js +6 -19
  375. package/esm/Toggle/Toggle.tailwind.js +1 -1
  376. package/esm/Tooltip/OverflowTooltipWrapper.js +33 -46
  377. package/esm/Tooltip/Tooltip.js +4 -9
  378. package/esm/Tooltip/Tooltip.tailwind.js +3 -4
  379. package/esm/Tooltip/TooltipWrapper.js +43 -56
  380. package/esm/Typography/Typography.tailwind.js +12 -15
  381. package/esm/UserContent/UserContent.js +3 -5
  382. package/esm/UserContent/UserContent.tailwind.js +2 -7
  383. package/esm/styles/base.tailwind.js +7 -6
  384. package/esm/styles/colors.js +7 -7
  385. package/esm/styles/disabledColor.js +1 -2
  386. package/esm/styles/helpers/icons.js +5 -8
  387. package/esm/styles/helpers/makePurgeCssExtractor.js +3 -14
  388. package/esm/styles/helpers/makeTailwindPrefixer.js +1 -6
  389. package/esm/styles/helpers/prefixTailwindClassName.js +6 -6
  390. package/esm/styles/helpers/satellitePrefixer.js +1 -1
  391. package/esm/styles/rgba.js +1 -2
  392. package/esm/styles/tailwind.config.js +4 -6
  393. package/esm/styles/zIndexes.js +1 -0
  394. package/esm/utils/event-polyfill.js +0 -2
  395. package/esm/utils/formatters.js +12 -16
  396. package/esm/utils/genericChangeHandler.js +0 -2
  397. package/esm/utils/hashCode.js +0 -3
  398. package/esm/utils/isCssPropertySupported.js +0 -2
  399. package/esm/utils/isRenderedChild.js +0 -1
  400. package/esm/utils/matchLocation.js +0 -2
  401. package/esm/utils/onlyText.js +3 -11
  402. package/esm/utils/parseUrl.js +2 -2
  403. package/esm/utils/pluralize.js +2 -5
  404. package/esm/utils/toSentenceCase.js +1 -1
  405. package/esm/utils/uniqBy.js +0 -2
  406. package/esm/utils/useForwardedRef.js +0 -3
  407. package/esm/utils/useLinkProps.js +1 -7
  408. package/esm/utils/useTriggerInputChange.js +2 -3
  409. package/package.json +1 -1
  410. package/satellite.min.css +1 -1
  411. package/scss/colors.scss +16 -16
@@ -1,7 +1,5 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
2
  var _templateObject, _templateObject2, _templateObject3;
4
-
5
3
  import cx from "clsx";
6
4
  import stl from "../styles/helpers/satellitePrefixer";
7
5
  import { getApplicationInitials, pickApplicationColors } from "./utils";
@@ -10,13 +8,12 @@ var SIZE_CLASSNAMES = {
10
8
  small: stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["w-4 h-4"]))),
11
9
  medium: stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["w-8 h-8"])))
12
10
  };
13
-
14
11
  /** The `ApplicationAvatar` is used as a visual representation of an application. */
15
12
  export var ApplicationAvatar = function ApplicationAvatar(_ref) {
16
13
  var className = _ref.className,
17
- application = _ref.application,
18
- _ref$size = _ref.size,
19
- size = _ref$size === void 0 ? "medium" : _ref$size;
14
+ application = _ref.application,
15
+ _ref$size = _ref.size,
16
+ size = _ref$size === void 0 ? "medium" : _ref$size;
20
17
  return /*#__PURE__*/_jsx("div", {
21
18
  role: "img",
22
19
  "aria-label": application.name || "Application's avatar",
@@ -1,29 +1,23 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
2
  import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
3
-
4
3
  var _templateObject, _templateObject2, _templateObject3;
5
-
6
4
  import cx from "clsx";
7
5
  import { useEffect, useState } from "react";
8
6
  import stl from "../styles/helpers/satellitePrefixer";
9
7
  import { getUserBackgroundClassName, getUserInitials } from "./utils";
10
8
  import { jsx as _jsx } from "react/jsx-runtime";
11
9
  import { jsxs as _jsxs } from "react/jsx-runtime";
12
-
13
10
  /** The `UserAvatar` is used as a visual representation of a user. */
14
11
  export var UserAvatar = function UserAvatar(_ref) {
15
12
  var _user$email;
16
-
17
13
  var className = _ref.className,
18
- user = _ref.user,
19
- _ref$size = _ref.size,
20
- size = _ref$size === void 0 ? 32 : _ref$size;
21
-
14
+ user = _ref.user,
15
+ _ref$size = _ref.size,
16
+ size = _ref$size === void 0 ? 32 : _ref$size;
22
17
  var _useState = useState(false),
23
- _useState2 = _slicedToArray(_useState, 2),
24
- imageLoaded = _useState2[0],
25
- setImageLoaded = _useState2[1];
26
-
18
+ _useState2 = _slicedToArray(_useState, 2),
19
+ imageLoaded = _useState2[0],
20
+ setImageLoaded = _useState2[1];
27
21
  var initials = getUserInitials(user);
28
22
  useEffect(function () {
29
23
  return setImageLoaded(false);
@@ -1,21 +1,14 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
2
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23, _templateObject24, _templateObject25, _templateObject26, _templateObject27, _templateObject28;
4
-
5
3
  import { remove as removeDiacritics } from "diacritics";
6
4
  import stl from "../styles/helpers/satellitePrefixer";
7
5
  import hashCode from "../utils/hashCode";
8
-
9
6
  /** APPLICATION */
10
- var APPLICATION_COLORS_CLASSNAMES = [
11
- /* eslint-disable @algolia/satellite/prefer-accent */
12
- stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["bg-grey-200 text-grey-800"]))), stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["bg-nebula-200 text-nebula-800"]))), stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["bg-blue-200 text-blue-900"]))), stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["bg-green-200 text-green-900"]))), stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["bg-pink-200 text-pink-800"]))), stl(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["bg-red-200 text-red-800"]))), stl(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["bg-orange-200 text-orange-900"]))), // Darker variants
13
- stl(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["bg-grey-300 text-grey-900"]))), stl(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["bg-nebula-300 text-nebula-900"]))), stl(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["bg-blue-300 text-blue-900"]))), stl(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["bg-green-300 text-green-900"]))), stl(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["bg-pink-300 text-pink-900"]))), stl(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["bg-red-300 text-red-900"]))), stl(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["bg-orange-300 text-orange-900"])))
14
- /* eslint-enable @algolia/satellite/prefer-accent */
15
- ];
7
+
8
+ var APPLICATION_COLORS_CLASSNAMES = [/* eslint-disable @algolia/satellite/prefer-accent */stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["bg-grey-200 text-grey-800"]))), stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["bg-nebula-200 text-nebula-800"]))), stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["bg-blue-200 text-blue-900"]))), stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["bg-green-200 text-green-900"]))), stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["bg-pink-200 text-pink-800"]))), stl(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["bg-red-200 text-red-800"]))), stl(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["bg-orange-200 text-orange-900"]))), // Darker variants
9
+ stl(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["bg-grey-300 text-grey-900"]))), stl(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["bg-nebula-300 text-nebula-900"]))), stl(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["bg-blue-300 text-blue-900"]))), stl(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["bg-green-300 text-green-900"]))), stl(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["bg-pink-300 text-pink-900"]))), stl(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["bg-red-300 text-red-900"]))), stl(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["bg-orange-300 text-orange-900"]))) /* eslint-enable @algolia/satellite/prefer-accent */];
16
10
  export var pickApplicationColors = function pickApplicationColors(applicationId) {
17
11
  var _APPLICATION_COLORS_C;
18
-
19
12
  return (_APPLICATION_COLORS_C = APPLICATION_COLORS_CLASSNAMES[Math.abs(hashCode(applicationId)) % APPLICATION_COLORS_CLASSNAMES.length]) !== null && _APPLICATION_COLORS_C !== void 0 ? _APPLICATION_COLORS_C : APPLICATION_COLORS_CLASSNAMES[0];
20
13
  };
21
14
  export var getApplicationIdInitial = function getApplicationIdInitial(applicationId) {
@@ -23,40 +16,31 @@ export var getApplicationIdInitial = function getApplicationIdInitial(applicatio
23
16
  };
24
17
  export var getApplicationInitials = function getApplicationInitials(_ref) {
25
18
  var name = _ref.name,
26
- applicationId = _ref.applicationId;
27
-
19
+ applicationId = _ref.applicationId;
28
20
  if (!name) {
29
21
  return getApplicationIdInitial(applicationId);
30
22
  }
31
-
32
23
  var words = removeDiacritics(name.trim()).toLocaleUpperCase().split(/\W+/).filter(function (word) {
33
24
  return word.length >= 1;
34
25
  });
35
-
36
26
  if (words.length === 0 || words.length === 1 && words[0].length < 2) {
37
27
  return getApplicationIdInitial(applicationId);
38
28
  } else if (words.length === 1) {
39
29
  return words[0].slice(0, 2);
40
30
  }
41
-
42
31
  return "".concat(words[0][0]).concat(words[1][0]);
43
32
  };
33
+
44
34
  /** USER */
45
35
 
46
- var USER_COLORS_CLASSNAMES = [
47
- /* eslint-disable @algolia/satellite/prefer-accent */
48
- stl(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["bg-grey-400 text-grey-900"]))), stl(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["bg-nebula-400 text-grey-900"]))), stl(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["bg-blue-400 text-grey-900"]))), stl(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["bg-green-400 text-grey-900"]))), stl(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["bg-pink-400 text-grey-900"]))), stl(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["bg-red-400 text-grey-900"]))), stl(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["bg-orange-400 text-grey-900"]))), // Darker variants
49
- stl(_templateObject22 || (_templateObject22 = _taggedTemplateLiteral(["bg-grey-700 text-white"]))), stl(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["bg-nebula-700 text-white"]))), stl(_templateObject24 || (_templateObject24 = _taggedTemplateLiteral(["bg-blue-700 text-grey-900"]))), stl(_templateObject25 || (_templateObject25 = _taggedTemplateLiteral(["bg-green-700 text-grey-900"]))), stl(_templateObject26 || (_templateObject26 = _taggedTemplateLiteral(["bg-pink-700 text-white"]))), stl(_templateObject27 || (_templateObject27 = _taggedTemplateLiteral(["bg-red-700 text-white"]))), stl(_templateObject28 || (_templateObject28 = _taggedTemplateLiteral(["bg-orange-600 text-grey-900"])))
50
- /* eslint-enable @algolia/satellite/prefer-accent */
51
- ];
36
+ var USER_COLORS_CLASSNAMES = [/* eslint-disable @algolia/satellite/prefer-accent */stl(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["bg-grey-400 text-grey-900"]))), stl(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["bg-nebula-400 text-grey-900"]))), stl(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["bg-blue-400 text-grey-900"]))), stl(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["bg-green-400 text-grey-900"]))), stl(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["bg-pink-400 text-grey-900"]))), stl(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["bg-red-400 text-grey-900"]))), stl(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["bg-orange-400 text-grey-900"]))), // Darker variants
37
+ stl(_templateObject22 || (_templateObject22 = _taggedTemplateLiteral(["bg-grey-700 text-white"]))), stl(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["bg-nebula-700 text-white"]))), stl(_templateObject24 || (_templateObject24 = _taggedTemplateLiteral(["bg-blue-700 text-grey-900"]))), stl(_templateObject25 || (_templateObject25 = _taggedTemplateLiteral(["bg-green-700 text-grey-900"]))), stl(_templateObject26 || (_templateObject26 = _taggedTemplateLiteral(["bg-pink-700 text-white"]))), stl(_templateObject27 || (_templateObject27 = _taggedTemplateLiteral(["bg-red-700 text-white"]))), stl(_templateObject28 || (_templateObject28 = _taggedTemplateLiteral(["bg-orange-600 text-grey-900"]))) /* eslint-enable @algolia/satellite/prefer-accent */];
52
38
  export var getUserBackgroundClassName = function getUserBackgroundClassName(email) {
53
39
  var _USER_COLORS_CLASSNAM;
54
-
55
40
  return (_USER_COLORS_CLASSNAM = USER_COLORS_CLASSNAMES[Math.abs(hashCode(email)) % USER_COLORS_CLASSNAMES.length]) !== null && _USER_COLORS_CLASSNAM !== void 0 ? _USER_COLORS_CLASSNAM : USER_COLORS_CLASSNAMES[0];
56
41
  };
57
42
  export var getUserInitials = function getUserInitials(user) {
58
43
  var _user$email, _user$email$match;
59
-
60
44
  var words = user.name ? user.name.trim().split(/\s+/) : (_user$email = user.email) === null || _user$email === void 0 ? void 0 : (_user$email$match = _user$email.match(/^(.+)(?:\+.+?)?@.+$/)) === null || _user$email$match === void 0 ? void 0 : _user$email$match[1].split(".");
61
45
  return words ? words.slice(0, 2).map(function (w) {
62
46
  return w.toLocaleLowerCase()[0];
@@ -2,13 +2,9 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
4
4
  var _excluded = ["children", "value", "icon", "variant", "size", "className"];
5
-
6
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18;
7
-
5
+ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11;
8
6
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
9
-
10
7
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
11
-
12
8
  import cx from "clsx";
13
9
  import stl from "../styles/helpers/satellitePrefixer";
14
10
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -23,19 +19,11 @@ var VARIANT_CLASSNAMES = {
23
19
  red: stl(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["bg-red-100 border-red-200 text-red-700"]))),
24
20
  pink: stl(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["bg-pink-100 border-pink-200 text-pink-700"])))
25
21
  };
26
- var VALUE_VARIANT_CLASSNAMES = {
27
- grey: stl(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["text-grey-600"]))),
28
- accent: stl(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["text-accent-600"]))),
29
- blue: stl(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["text-blue-800"]))),
30
- green: stl(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["text-green-900"]))),
31
- orange: stl(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["text-orange-800"]))),
32
- red: stl(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["text-red-700"]))),
33
- pink: stl(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["text-pink-600"])))
34
- };
35
22
  var SIZE_CLASSNAMES = {
36
- "default": stl(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["h-6 display-body px-2 space-x-2"]))),
37
- small: stl(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["h-4 display-caption px-1 space-x-1"])))
23
+ "default": stl(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["h-6 display-body px-2 space-x-2"]))),
24
+ small: stl(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["h-4 display-caption px-1 space-x-1"])))
38
25
  };
26
+
39
27
  /**
40
28
  * Badges are used to inform a user about a status of an item or a process. They can also contain a numeric value. Badges come with a set of colours that are easily identified. Green colour implies success or completion, while orange suggests a warning, on hold, or a problem. Red coloured badges mean error or failure.
41
29
  *
@@ -51,18 +39,16 @@ var SIZE_CLASSNAMES = {
51
39
  * - To indicate problem with an index
52
40
  * - To display numeric values for multiple items (similar to a "tag cloud")
53
41
  */
54
-
55
42
  export var Badge = function Badge(_ref) {
56
43
  var children = _ref.children,
57
- value = _ref.value,
58
- Icon = _ref.icon,
59
- _ref$variant = _ref.variant,
60
- variant = _ref$variant === void 0 ? "grey" : _ref$variant,
61
- _ref$size = _ref.size,
62
- size = _ref$size === void 0 ? "default" : _ref$size,
63
- className = _ref.className,
64
- props = _objectWithoutProperties(_ref, _excluded);
65
-
44
+ value = _ref.value,
45
+ Icon = _ref.icon,
46
+ _ref$variant = _ref.variant,
47
+ variant = _ref$variant === void 0 ? "grey" : _ref$variant,
48
+ _ref$size = _ref.size,
49
+ size = _ref$size === void 0 ? "default" : _ref$size,
50
+ className = _ref.className,
51
+ props = _objectWithoutProperties(_ref, _excluded);
66
52
  var badgeClassName = cx(BASE_CLASSNAMES, VARIANT_CLASSNAMES[variant], SIZE_CLASSNAMES[size], className);
67
53
  return /*#__PURE__*/_jsxs("div", _objectSpread(_objectSpread({}, props), {}, {
68
54
  className: badgeClassName,
@@ -71,10 +57,9 @@ export var Badge = function Badge(_ref) {
71
57
  size: ".8em"
72
58
  })
73
59
  }), children && /*#__PURE__*/_jsx("span", {
74
- className: stl(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["truncate"]))),
60
+ className: stl(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["truncate"]))),
75
61
  children: children
76
62
  }), value && /*#__PURE__*/_jsx("span", {
77
- className: VALUE_VARIANT_CLASSNAMES[variant],
78
63
  children: value
79
64
  })]
80
65
  }));
@@ -1,14 +1,12 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23;
4
-
2
+ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23, _templateObject24;
5
3
  import cx from "clsx";
6
4
  import { AlertCircle, AlertOctagon, AlertTriangle, CheckCircle, X } from "react-feather";
7
5
  import { IconButton } from "../../Button";
8
6
  import stl from "../../styles/helpers/satellitePrefixer";
9
7
  import { jsx as _jsx } from "react/jsx-runtime";
10
8
  import { jsxs as _jsxs } from "react/jsx-runtime";
11
- var BASE_CLASSNAME = stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["relative flex text-grey-900 display-body"])));
9
+ var BASE_CLASSNAME = stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["relative flex text-grey-900 display-body border"])));
12
10
  var BACKGROUND_CLASSNAMES = {
13
11
  grey: stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["bg-grey-100"]))),
14
12
  accent: stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["bg-accent-100"]))),
@@ -33,10 +31,11 @@ var ICON_VARIANTS = {
33
31
  var ICON_CLASSNAME_VARIANTS = {
34
32
  grey: stl(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["text-grey-600"]))),
35
33
  accent: stl(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["text-accent-600"]))),
36
- green: stl(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["text-green-600"]))),
34
+ green: stl(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["text-green-700"]))),
37
35
  orange: stl(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["text-orange-600"]))),
38
36
  red: stl(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["text-red-600"])))
39
37
  };
38
+
40
39
  /**
41
40
  * Alerts inform users about important changes or temporally conditions. Use this component if you need to communicate something to users in a prominent way.
42
41
 
@@ -87,37 +86,36 @@ var ICON_CLASSNAME_VARIANTS = {
87
86
  * ## Accessibility
88
87
  * TODO
89
88
  */
90
-
91
89
  export var Alert = function Alert(_ref) {
92
90
  var title = _ref.title,
93
- _ref$usageContext = _ref.usageContext,
94
- usageContext = _ref$usageContext === void 0 ? "section" : _ref$usageContext,
95
- _ref$variant = _ref.variant,
96
- variant = _ref$variant === void 0 ? "grey" : _ref$variant,
97
- onDismiss = _ref.onDismiss,
98
- icon = _ref.icon,
99
- className = _ref.className,
100
- style = _ref.style,
101
- children = _ref.children;
102
- var containerClassName = cx(BASE_CLASSNAME, title ? stl(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["p-4"]))) : stl(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["py-2 px-3"]))), BACKGROUND_CLASSNAMES[variant], BORDER_CLASSNAMES[variant], usageContext !== "page" && stl(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["rounded border"]))), className);
91
+ _ref$usageContext = _ref.usageContext,
92
+ usageContext = _ref$usageContext === void 0 ? "section" : _ref$usageContext,
93
+ _ref$variant = _ref.variant,
94
+ variant = _ref$variant === void 0 ? "grey" : _ref$variant,
95
+ onDismiss = _ref.onDismiss,
96
+ icon = _ref.icon,
97
+ className = _ref.className,
98
+ style = _ref.style,
99
+ children = _ref.children;
100
+ var containerClassName = cx(BASE_CLASSNAME, title ? stl(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["p-4"]))) : stl(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["py-2 px-3"]))), BACKGROUND_CLASSNAMES[variant], usageContext !== "page" ? BORDER_CLASSNAMES[variant] : stl(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["border-transparent"]))), usageContext !== "page" && stl(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["rounded"]))), className);
103
101
  var internalIcon = icon === undefined ? true : icon;
104
102
  var Icon = typeof internalIcon === "boolean" && internalIcon ? ICON_VARIANTS[variant] : internalIcon;
105
103
  return /*#__PURE__*/_jsxs("div", {
106
104
  className: containerClassName,
107
105
  style: style,
108
106
  children: [/*#__PURE__*/_jsx(Icon, {
109
- className: cx(stl(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["\n shrink-0 mr-2\n ", "\n "])), title ? "mt-1" : "mt-2px"), ICON_CLASSNAME_VARIANTS[variant]),
107
+ className: cx(stl(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["\n shrink-0 mr-2\n ", "\n "])), title ? "mt-0.5" : "mt-2px"), ICON_CLASSNAME_VARIANTS[variant]),
110
108
  size: "1rem"
111
109
  }), /*#__PURE__*/_jsxs("div", {
112
- className: stl(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["flex flex-1 flex-col ", ""])), onDismiss && "mr-6"),
110
+ className: stl(_templateObject22 || (_templateObject22 = _taggedTemplateLiteral(["flex flex-1 flex-col ", ""])), onDismiss && "mr-6"),
113
111
  children: [title && /*#__PURE__*/_jsx("h4", {
114
- className: stl(_templateObject22 || (_templateObject22 = _taggedTemplateLiteral(["display-heading text-grey-900 mb-1"]))),
112
+ className: stl(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["font-bold text-grey-900 mb-1"]))),
115
113
  children: title
116
114
  }), /*#__PURE__*/_jsx("div", {
117
115
  children: children
118
116
  })]
119
117
  }), onDismiss && /*#__PURE__*/_jsx("span", {
120
- className: stl(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["absolute top-2 right-2"]))),
118
+ className: stl(_templateObject24 || (_templateObject24 = _taggedTemplateLiteral(["absolute right-1.5 top-1.5"]))),
121
119
  children: /*#__PURE__*/_jsx(IconButton, {
122
120
  icon: X,
123
121
  title: "Close",
@@ -1,12 +1,9 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
2
  var _templateObject, _templateObject2;
4
-
5
3
  import { AlertCircle } from "react-feather";
6
4
  import stl from "../../styles/helpers/satellitePrefixer";
7
5
  import { jsx as _jsx } from "react/jsx-runtime";
8
6
  import { jsxs as _jsxs } from "react/jsx-runtime";
9
-
10
7
  /**
11
8
  * Major product wide announcement from Algolia to the users.
12
9
 
@@ -42,7 +39,7 @@ import { jsxs as _jsxs } from "react/jsx-runtime";
42
39
  */
43
40
  export var BigBertha = function BigBertha(_ref) {
44
41
  var icon = _ref.icon,
45
- children = _ref.children;
42
+ children = _ref.children;
46
43
  var InternalIcon = icon || AlertCircle;
47
44
  return /*#__PURE__*/_jsxs("div", {
48
45
  className: stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["flex items-center justify-center space-x-4 bg-accent-600 text-white w-full p-4"]))),
@@ -1,7 +1,5 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
2
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12;
4
-
5
3
  import cx from "clsx";
6
4
  import { X } from "react-feather";
7
5
  import { IconButton } from "../../Button";
@@ -21,6 +19,7 @@ var ACTIONS_VARIANT_CLASSNAMES = {
21
19
  compact: stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["mt-1"]))),
22
20
  large: stl(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["mt-3"])))
23
21
  };
22
+
24
23
  /**
25
24
  * A contextual way of showing our user that a new feature / product is available to them on a higher plan or as an option.
26
25
 
@@ -55,16 +54,15 @@ var ACTIONS_VARIANT_CLASSNAMES = {
55
54
  * ## Accessibility
56
55
  * TODO
57
56
  */
58
-
59
57
  export var Promote = function Promote(_ref) {
60
58
  var context = _ref.context,
61
- title = _ref.title,
62
- _ref$variant = _ref.variant,
63
- variant = _ref$variant === void 0 ? "large" : _ref$variant,
64
- illustration = _ref.illustration,
65
- actions = _ref.actions,
66
- children = _ref.children,
67
- onDismiss = _ref.onDismiss;
59
+ title = _ref.title,
60
+ _ref$variant = _ref.variant,
61
+ variant = _ref$variant === void 0 ? "large" : _ref$variant,
62
+ illustration = _ref.illustration,
63
+ actions = _ref.actions,
64
+ children = _ref.children,
65
+ onDismiss = _ref.onDismiss;
68
66
  return /*#__PURE__*/_jsxs(Card, {
69
67
  className: stl(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["relative flex"]))),
70
68
  fullBleed: true,
@@ -2,13 +2,9 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
4
4
  var _excluded = ["as", "className", "variant", "size", "startIcon", "endIcon", "loading", "children"];
5
-
6
5
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8;
7
-
8
6
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
9
-
10
7
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
11
-
12
8
  import cx from "clsx";
13
9
  import ProgressSpinner from "../ProgressSpinner";
14
10
  import stl from "../styles/helpers/satellitePrefixer";
@@ -17,6 +13,7 @@ import { isButtonType } from "./types";
17
13
  import { jsx as _jsx } from "react/jsx-runtime";
18
14
  import { jsxs as _jsxs } from "react/jsx-runtime";
19
15
  var BASE_CLASSNAMES = stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["btn inline-flex justify-center items-center px-4 typo-display-body"])));
16
+
20
17
  /**
21
18
  * Buttons are used to trigger user actions (like "Add", "Close" or "Save") or navigate users elsewhere through the links. Buttons can contain a combination of a clear label and an icon while links are always text.
22
19
  *
@@ -31,36 +28,31 @@ var BASE_CLASSNAMES = stl(_templateObject || (_templateObject = _taggedTemplateL
31
28
  * - Use icon-only button for an action that is less critical and doesn't have to drag too much of user attention
32
29
  * - Buttons can take the full width to fill the parent container
33
30
  */
34
-
35
31
  export var Button = function Button(props) {
36
32
  var _props$as = props.as,
37
- Component = _props$as === void 0 ? "button" : _props$as,
38
- className = props.className,
39
- _props$variant = props.variant,
40
- variant = _props$variant === void 0 ? "neutral" : _props$variant,
41
- _props$size = props.size,
42
- size = _props$size === void 0 ? "medium" : _props$size,
43
- StartIcon = props.startIcon,
44
- EndIcon = props.endIcon,
45
- _props$loading = props.loading,
46
- loading = _props$loading === void 0 ? false : _props$loading,
47
- children = props.children,
48
- cleanedProps = _objectWithoutProperties(props, _excluded);
49
-
33
+ Component = _props$as === void 0 ? "button" : _props$as,
34
+ className = props.className,
35
+ _props$variant = props.variant,
36
+ variant = _props$variant === void 0 ? "neutral" : _props$variant,
37
+ _props$size = props.size,
38
+ size = _props$size === void 0 ? "medium" : _props$size,
39
+ StartIcon = props.startIcon,
40
+ EndIcon = props.endIcon,
41
+ _props$loading = props.loading,
42
+ loading = _props$loading === void 0 ? false : _props$loading,
43
+ children = props.children,
44
+ cleanedProps = _objectWithoutProperties(props, _excluded);
50
45
  if (loading) {
51
46
  cleanedProps.disabled = true;
52
47
  }
53
-
54
48
  var buttonClassName = cx(BASE_CLASSNAMES, BUTTON_SIZE_CLASSNAMES[size], BUTTON_VARIANT_CLASSNAMES[variant], cleanedProps.disabled && stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["btn-disabled"]))), className);
55
49
  var loaderClassNames = stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["absolute ", ""])), (variant === "destructive" || variant === "primary") && "text-white");
56
50
  var iconClassNames = cx(getIconColorClassName(props), loading && stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["invisible"]))));
57
51
  var textClassNames = cx(loading && stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["invisible"]))));
58
-
59
52
  if (isButtonType(props) && !cleanedProps.hasOwnProperty("type")) {
60
53
  // @ts-ignore
61
54
  cleanedProps.type = "button";
62
55
  }
63
-
64
56
  return /*#__PURE__*/_jsxs(Component, _objectSpread(_objectSpread({}, cleanedProps), {}, {
65
57
  className: buttonClassName,
66
58
  children: [loading && /*#__PURE__*/_jsx(ProgressSpinner, {
@@ -7,7 +7,7 @@ var disabledColor = _disabledColor;
7
7
  var rgba = _rgba;
8
8
  var buttonPlugin = plugin(function (_ref) {
9
9
  var addComponents = _ref.addComponents,
10
- theme = _ref.theme;
10
+ theme = _ref.theme;
11
11
  // Button
12
12
  addComponents({
13
13
  ".btn": {
@@ -126,8 +126,9 @@ var buttonPlugin = plugin(function (_ref) {
126
126
  boxShadow: "none"
127
127
  }
128
128
  }
129
- }); // Button groups
129
+ });
130
130
 
131
+ // Button groups
131
132
  addComponents({
132
133
  ".btn-group": {
133
134
  display: "flex",
@@ -1,11 +1,8 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
2
  var _templateObject;
4
-
5
3
  import cx from "clsx";
6
4
  import stl from "../styles/helpers/satellitePrefixer";
7
5
  import { jsx as _jsx } from "react/jsx-runtime";
8
-
9
6
  /**
10
7
  * - Use grouped buttons when there is a close relationship between a number of buttons.
11
8
  * - Group buttons logically into sets based on usage and importance.
@@ -13,9 +10,9 @@ import { jsx as _jsx } from "react/jsx-runtime";
13
10
  */
14
11
  export var ButtonGroup = function ButtonGroup(_ref) {
15
12
  var className = _ref.className,
16
- _ref$as = _ref.as,
17
- Tag = _ref$as === void 0 ? "div" : _ref$as,
18
- children = _ref.children;
13
+ _ref$as = _ref.as,
14
+ Tag = _ref$as === void 0 ? "div" : _ref$as,
15
+ children = _ref.children;
19
16
  return /*#__PURE__*/_jsx(Tag, {
20
17
  className: cx(stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["btn-group"]))), className),
21
18
  children: children
@@ -2,13 +2,9 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
2
2
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
3
3
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
4
4
  var _excluded = ["as", "className", "variant", "size", "icon", "title", "showTooltip", "loading"];
5
-
6
5
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8;
7
-
8
6
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
9
-
10
7
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
11
-
12
8
  import cx from "clsx";
13
9
  import ProgressSpinner from "../ProgressSpinner";
14
10
  import stl from "../styles/helpers/satellitePrefixer";
@@ -24,38 +20,32 @@ var SIZE_CLASSNAMES = {
24
20
  medium: stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["h-8 w-8 text-md"]))),
25
21
  large: stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["h-10 w-10 text-lg"])))
26
22
  };
27
-
28
23
  var VARIANT_CLASSNAMES = _objectSpread(_objectSpread({}, BUTTON_VARIANT_CLASSNAMES), {}, {
29
24
  neutral: stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["btn-neutral text-grey-600"])))
30
25
  });
31
-
32
26
  export var IconButton = function IconButton(props) {
33
27
  var _props$as = props.as,
34
- Tag = _props$as === void 0 ? "button" : _props$as,
35
- className = props.className,
36
- _props$variant = props.variant,
37
- variant = _props$variant === void 0 ? "neutral" : _props$variant,
38
- _props$size = props.size,
39
- size = _props$size === void 0 ? "medium" : _props$size,
40
- Icon = props.icon,
41
- title = props.title,
42
- showTooltip = props.showTooltip,
43
- _props$loading = props.loading,
44
- loading = _props$loading === void 0 ? false : _props$loading,
45
- cleanedProps = _objectWithoutProperties(props, _excluded);
46
-
28
+ Tag = _props$as === void 0 ? "button" : _props$as,
29
+ className = props.className,
30
+ _props$variant = props.variant,
31
+ variant = _props$variant === void 0 ? "neutral" : _props$variant,
32
+ _props$size = props.size,
33
+ size = _props$size === void 0 ? "medium" : _props$size,
34
+ Icon = props.icon,
35
+ title = props.title,
36
+ showTooltip = props.showTooltip,
37
+ _props$loading = props.loading,
38
+ loading = _props$loading === void 0 ? false : _props$loading,
39
+ cleanedProps = _objectWithoutProperties(props, _excluded);
47
40
  if (loading) {
48
41
  cleanedProps.disabled = true;
49
42
  }
50
-
51
43
  var iconButtonClassName = cx(BASE_CLASSNAMES, SIZE_CLASSNAMES[size], VARIANT_CLASSNAMES[variant], cleanedProps.disabled && stl(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["btn-disabled"]))), className);
52
44
  var loaderClassNames = stl(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["absolute ", ""])), (variant === "destructive" || variant === "primary") && "text-white");
53
-
54
45
  if (isButtonType(props) && !cleanedProps.hasOwnProperty("type")) {
55
46
  // @ts-ignore
56
47
  cleanedProps.type = "button";
57
48
  }
58
-
59
49
  return /*#__PURE__*/_jsx(TooltipWrapper, {
60
50
  delay: 500,
61
51
  show: showTooltip,
@@ -1,7 +1,5 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
2
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
4
-
5
3
  import stl from "../styles/helpers/satellitePrefixer";
6
4
  export var BUTTON_SIZE_CLASSNAMES = {
7
5
  small: stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["h-6"]))),
@@ -21,11 +19,9 @@ export var BUTTON_VARIANT_CLASSNAMES = {
21
19
  };
22
20
  export var getIconColorClassName = function getIconColorClassName(_ref) {
23
21
  var disabled = _ref.disabled,
24
- variant = _ref.variant;
25
-
22
+ variant = _ref.variant;
26
23
  if (variant === "destructive" || variant === "primary") {
27
24
  return stl(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["text-white"])));
28
25
  }
29
-
30
26
  return disabled ? stl(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["text-grey-300"]))) : stl(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["text-grey-600"])));
31
27
  };
package/esm/Card/Card.js CHANGED
@@ -2,13 +2,9 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
4
4
  var _excluded = ["className", "as", "elevation", "fullBleed"];
5
-
6
5
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
7
-
8
6
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
9
-
10
7
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
11
-
12
8
  import cx from "clsx";
13
9
  import { createElement, forwardRef } from "react";
14
10
  import stl from "../styles/helpers/satellitePrefixer";
@@ -21,17 +17,15 @@ var ELEVATION_CLASSNAMES = {
21
17
  "400": stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["card-z400"]))),
22
18
  "500": stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["card-z500"])))
23
19
  };
24
-
25
20
  /** The `Card` is a useful component for containing content within a page. */
26
21
  export var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
27
22
  var className = _ref.className,
28
- _ref$as = _ref.as,
29
- as = _ref$as === void 0 ? "section" : _ref$as,
30
- _ref$elevation = _ref.elevation,
31
- elevation = _ref$elevation === void 0 ? "100" : _ref$elevation,
32
- fullBleed = _ref.fullBleed,
33
- props = _objectWithoutProperties(_ref, _excluded);
34
-
23
+ _ref$as = _ref.as,
24
+ as = _ref$as === void 0 ? "section" : _ref$as,
25
+ _ref$elevation = _ref.elevation,
26
+ elevation = _ref$elevation === void 0 ? "100" : _ref$elevation,
27
+ fullBleed = _ref.fullBleed,
28
+ props = _objectWithoutProperties(_ref, _excluded);
35
29
  return /*#__PURE__*/createElement(as, _objectSpread(_objectSpread({}, props), {}, {
36
30
  ref: ref,
37
31
  className: cx(stl(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["card ", " display-body"])), fullBleed && "card-fullbleed"), ELEVATION_CLASSNAMES[elevation], className)
@@ -3,7 +3,7 @@ import _plugin from "tailwindcss/plugin";
3
3
  var plugin = _plugin;
4
4
  var cardPlugin = plugin(function (_ref) {
5
5
  var addComponents = _ref.addComponents,
6
- theme = _ref.theme;
6
+ theme = _ref.theme;
7
7
  addComponents({
8
8
  ".card": {
9
9
  background: theme("colors.white"),