@procore/core-react 12.21.2 → 12.23.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 (407) hide show
  1. package/CHANGELOG.md +20 -8
  2. package/dist/@types/global.d.js.map +1 -1
  3. package/dist/AnchorNavigation/AnchorNavigation.styles.d.ts +6 -5
  4. package/dist/AnchorNavigation/AnchorNavigation.styles.js +3 -3
  5. package/dist/Avatar/Avatar.styles.d.ts +7 -6
  6. package/dist/Avatar/Avatar.styles.js +5 -5
  7. package/dist/AvatarStack/AvatarStack.styles.d.ts +1677 -13
  8. package/dist/AvatarStack/AvatarStack.styles.js +7 -7
  9. package/dist/Badge/Badge.styles.d.ts +3 -2
  10. package/dist/Badge/Badge.styles.js +2 -2
  11. package/dist/BadgePill/BadgePill.d.ts +3 -0
  12. package/dist/BadgePill/BadgePill.js +25 -0
  13. package/dist/BadgePill/BadgePill.js.map +1 -0
  14. package/dist/BadgePill/BadgePill.styles.d.ts +12 -0
  15. package/dist/BadgePill/BadgePill.styles.js +33 -0
  16. package/dist/BadgePill/BadgePill.styles.js.map +1 -0
  17. package/dist/BadgePill/BadgePill.types.d.ts +50 -0
  18. package/dist/BadgePill/BadgePill.types.js +2 -0
  19. package/dist/BadgePill/BadgePill.types.js.map +1 -0
  20. package/dist/BadgePill/index.d.ts +2 -0
  21. package/dist/BadgePill/index.js +2 -0
  22. package/dist/BadgePill/index.js.map +1 -0
  23. package/dist/Banner/Banner.js +1 -1
  24. package/dist/Banner/Banner.js.map +1 -1
  25. package/dist/Banner/Banner.styles.d.ts +22 -13
  26. package/dist/Banner/Banner.styles.js +12 -12
  27. package/dist/Banner/Banner.styles.js.map +1 -1
  28. package/dist/Box/Box.js +1 -1
  29. package/dist/Box/Box.js.map +1 -1
  30. package/dist/Box/Box.styles.d.ts +2 -1
  31. package/dist/Box/Box.styles.js +3 -3
  32. package/dist/Box/Box.styles.js.map +1 -1
  33. package/dist/Box/Box.types.d.ts +1 -1
  34. package/dist/Box/Box.types.js.map +1 -1
  35. package/dist/Breadcrumbs/Breadcrumbs.styles.d.ts +5 -4
  36. package/dist/Breadcrumbs/Breadcrumbs.styles.js +4 -4
  37. package/dist/Button/Button.styles.d.ts +8 -6
  38. package/dist/Button/Button.styles.js +5 -5
  39. package/dist/Calendar/Calendar.styles.d.ts +15 -9
  40. package/dist/Calendar/Calendar.styles.js +8 -8
  41. package/dist/Card/Card.styles.d.ts +3 -2
  42. package/dist/Card/Card.styles.js +1 -1
  43. package/dist/Checkbox/Checkbox.styles.d.ts +11 -10
  44. package/dist/Checkbox/Checkbox.styles.js +6 -6
  45. package/dist/Checkbox/CheckboxTooltip.js +1 -1
  46. package/dist/ContactItem/ContactItem.js +2 -0
  47. package/dist/ContactItem/ContactItem.js.map +1 -1
  48. package/dist/ContactItem/ContactItem.styles.d.ts +18 -7
  49. package/dist/ContactItem/ContactItem.styles.js +5 -5
  50. package/dist/Content/Content.styles.d.ts +6 -2
  51. package/dist/Content/Content.styles.js +2 -2
  52. package/dist/DateInput/DateInput.js +6 -6
  53. package/dist/DateInput/DateInput.js.map +1 -1
  54. package/dist/DateInput/DateInput.styles.d.ts +20 -13
  55. package/dist/DateInput/DateInput.styles.js +21 -23
  56. package/dist/DateInput/DateInput.styles.js.map +1 -1
  57. package/dist/DateSelect/DateSelect.js +2 -2
  58. package/dist/DateSelect/DateSelect.js.map +1 -1
  59. package/dist/DetailPage/DetailPage.styles.d.ts +13 -7
  60. package/dist/DetailPage/DetailPage.styles.js +7 -7
  61. package/dist/Dropdown/Dropdown.styles.d.ts +10 -4
  62. package/dist/Dropdown/Dropdown.styles.js +3 -3
  63. package/dist/DropdownFlyout/DropdownFlyout.js +1 -1
  64. package/dist/DropdownFlyout/DropdownFlyout.js.map +1 -1
  65. package/dist/DropdownFlyout/DropdownFlyout.styles.d.ts +5 -4
  66. package/dist/DropdownFlyout/DropdownFlyout.styles.js +4 -4
  67. package/dist/DropdownFlyout/DropdownFlyout.types.d.ts +4 -1
  68. package/dist/DropdownFlyout/DropdownFlyout.types.js.map +1 -1
  69. package/dist/Dropzone/Dropzone.d.ts +3 -1
  70. package/dist/Dropzone/Dropzone.js +5 -5
  71. package/dist/Dropzone/Dropzone.js.map +1 -1
  72. package/dist/Dropzone/Dropzone.styles.d.ts +24 -16
  73. package/dist/Dropzone/Dropzone.styles.js +22 -22
  74. package/dist/Dropzone/Dropzone.styles.js.map +1 -1
  75. package/dist/EmptyState/EmptyState.js +1 -1
  76. package/dist/EmptyState/EmptyState.js.map +1 -1
  77. package/dist/EmptyState/EmptyState.styles.d.ts +8 -7
  78. package/dist/EmptyState/EmptyState.styles.js +6 -6
  79. package/dist/Field/Field.styles.d.ts +4 -3
  80. package/dist/Field/Field.styles.js +3 -3
  81. package/dist/FileList/FileList.styles.d.ts +8 -4
  82. package/dist/FileList/FileList.styles.js +4 -4
  83. package/dist/FileSelect/FileExplorer/FileExplorer.styles.d.ts +18 -10
  84. package/dist/FileSelect/FileExplorer/FileExplorer.styles.js +9 -9
  85. package/dist/FileSelect/FileExplorer/FileExplorerSidebar.styles.d.ts +5 -3
  86. package/dist/FileSelect/FileExplorer/FileExplorerSidebar.styles.js +3 -3
  87. package/dist/FileSelect/FileSelect.d.ts +3 -3
  88. package/dist/FileSelect/FileSelect.js +4 -4
  89. package/dist/FileSelect/FileSelect.js.map +1 -1
  90. package/dist/FileSelect/FileSelect.styles.d.ts +4 -2
  91. package/dist/FileSelect/FileSelect.styles.js +2 -2
  92. package/dist/FileSelect/FileSelectDropzone/FileSelectDropzone.styles.d.ts +7 -5
  93. package/dist/FileSelect/FileSelectDropzone/FileSelectDropzone.styles.js +3 -3
  94. package/dist/FileSelect/FileTokenList/FileTokenList.styles.d.ts +4 -2
  95. package/dist/FileSelect/FileTokenList/FileTokenList.styles.js +2 -2
  96. package/dist/FileSelect/GridSource/GridSource.styles.d.ts +11 -9
  97. package/dist/FileSelect/GridSource/GridSource.styles.js +6 -6
  98. package/dist/FileSelect/LocalSource/LocalSource.styles.d.ts +10 -4
  99. package/dist/FileSelect/LocalSource/LocalSource.styles.js +4 -4
  100. package/dist/FileSelect/SourceItem/SourceItem.styles.d.ts +5 -4
  101. package/dist/FileSelect/SourceItem/SourceItem.styles.js +3 -3
  102. package/dist/FileSelect/ThumbnailList/ThumbnailList.js +1 -1
  103. package/dist/FileSelect/ThumbnailList/ThumbnailList.js.map +1 -1
  104. package/dist/FileSelect/ThumbnailList/ThumbnailList.styles.d.ts +18 -8
  105. package/dist/FileSelect/ThumbnailList/ThumbnailList.styles.js +6 -6
  106. package/dist/FileSelect/TreeSource/TreeSource.styles.d.ts +2 -1
  107. package/dist/FileSelect/TreeSource/TreeSource.styles.js +1 -1
  108. package/dist/FileToken/FileToken.styles.d.ts +6 -5
  109. package/dist/FileToken/FileToken.styles.js +4 -4
  110. package/dist/FilterToken/FilterToken.styles.d.ts +8 -7
  111. package/dist/FilterToken/FilterToken.styles.js +5 -5
  112. package/dist/FlexList/FlexList.styles.d.ts +4 -2
  113. package/dist/FlexList/FlexList.styles.js +1 -1
  114. package/dist/Form/Form.d.ts +2 -1
  115. package/dist/Form/Form.js.map +1 -1
  116. package/dist/Form/Form.styles.d.ts +48 -25
  117. package/dist/Form/Form.styles.js +18 -18
  118. package/dist/Form/Form.styles.js.map +1 -1
  119. package/dist/Form/Form.types.d.ts +1 -1
  120. package/dist/Form/Form.types.js.map +1 -1
  121. package/dist/Form/StyledFormikForm.styles.d.ts +7 -3
  122. package/dist/Form/StyledFormikForm.styles.js +2 -2
  123. package/dist/GhostPlaceholder/GhostPlaceholder.styles.d.ts +5 -2
  124. package/dist/GhostPlaceholder/GhostPlaceholder.styles.js +2 -2
  125. package/dist/Grid/Grid.styles.d.ts +5 -4
  126. package/dist/Grid/Grid.styles.js +2 -2
  127. package/dist/GroupSelect/GroupSelect.js +1 -1
  128. package/dist/GroupSelect/GroupSelect.js.map +1 -1
  129. package/dist/GroupSelect/GroupSelect.styles.d.ts +4 -2
  130. package/dist/GroupSelect/GroupSelect.styles.js +1 -1
  131. package/dist/Input/Input.js +5 -1
  132. package/dist/Input/Input.js.map +1 -1
  133. package/dist/Input/Input.styles.d.ts +8 -8
  134. package/dist/Input/Input.styles.js +5 -5
  135. package/dist/Input/Input.styles.js.map +1 -1
  136. package/dist/Link/Link.js +3 -1
  137. package/dist/Link/Link.js.map +1 -1
  138. package/dist/Link/Link.styles.d.ts +4 -1
  139. package/dist/Link/Link.styles.js +4 -4
  140. package/dist/Link/Link.styles.js.map +1 -1
  141. package/dist/Link/Link.types.d.ts +1 -2
  142. package/dist/Link/Link.types.js.map +1 -1
  143. package/dist/ListPage/ListPage.styles.d.ts +9 -8
  144. package/dist/ListPage/ListPage.styles.js +8 -8
  145. package/dist/Loader/Loader.styles.d.ts +4 -3
  146. package/dist/Loader/Loader.styles.js +2 -2
  147. package/dist/Menu/Menu.js +6 -5
  148. package/dist/Menu/Menu.js.map +1 -1
  149. package/dist/MenuImperative/MenuImperative.d.ts +2 -3
  150. package/dist/MenuImperative/MenuImperative.js +8 -26
  151. package/dist/MenuImperative/MenuImperative.js.map +1 -1
  152. package/dist/MenuImperative/MenuImperative.styles.d.ts +15 -13
  153. package/dist/MenuImperative/MenuImperative.styles.js +13 -13
  154. package/dist/MenuImperative/MenuImperative.styles.js.map +1 -1
  155. package/dist/Modal/Modal.d.ts +6 -6
  156. package/dist/Modal/Modal.js +2 -2
  157. package/dist/Modal/Modal.js.map +1 -1
  158. package/dist/Modal/Modal.styles.d.ts +27 -19
  159. package/dist/Modal/Modal.styles.js +13 -13
  160. package/dist/MultiSelect/MultiSelect.js +5 -5
  161. package/dist/MultiSelect/MultiSelect.js.map +1 -1
  162. package/dist/MultiSelect/MultiSelect.styles.d.ts +19 -13
  163. package/dist/MultiSelect/MultiSelect.styles.js +6 -6
  164. package/dist/NextMenu/NextMenu.styles.d.ts +4 -3
  165. package/dist/NextMenu/NextMenu.styles.js +3 -3
  166. package/dist/Notation/Notation.js +5 -5
  167. package/dist/Notation/Notation.js.map +1 -1
  168. package/dist/NumberInput/NumberInput.hooks.d.ts +1 -1
  169. package/dist/NumberInput/NumberInput.styles.d.ts +16 -10
  170. package/dist/NumberInput/NumberInput.styles.js +7 -7
  171. package/dist/Overlay/OverlayArrow.styles.d.ts +2 -1
  172. package/dist/Overlay/OverlayArrow.styles.js +1 -1
  173. package/dist/OverlayTrigger/a11yPresets.d.ts +20 -20
  174. package/dist/PageLayout/PageLayout.styles.d.ts +33 -24
  175. package/dist/PageLayout/PageLayout.styles.js +16 -16
  176. package/dist/PageTemplate/PageFooterTemplate/PageFooterTemplate.styles.d.ts +2 -1
  177. package/dist/PageTemplate/PageFooterTemplate/PageFooterTemplate.styles.js +1 -1
  178. package/dist/PageTemplate/PageHeaderTemplate/PageHeaderTemplate.d.ts +3 -1
  179. package/dist/PageTemplate/PageHeaderTemplate/PageHeaderTemplate.js.map +1 -1
  180. package/dist/PageTemplate/PageHeaderTemplate/PageHeaderTemplate.styles.d.ts +10 -4
  181. package/dist/PageTemplate/PageHeaderTemplate/PageHeaderTemplate.styles.js +3 -3
  182. package/dist/PageTemplate/PagePaneTemplate/PagePaneTemplate.styles.d.ts +12 -8
  183. package/dist/PageTemplate/PagePaneTemplate/PagePaneTemplate.styles.js +2 -2
  184. package/dist/PageTemplate/PageTemplate/PageTemplate.styles.d.ts +5 -3
  185. package/dist/PageTemplate/PageTemplate/PageTemplate.styles.js +3 -3
  186. package/dist/Pagination/Pagination.styles.d.ts +13 -5
  187. package/dist/Pagination/Pagination.styles.js +5 -5
  188. package/dist/Panel/Panel.js +1 -1
  189. package/dist/Panel/Panel.js.map +1 -1
  190. package/dist/Panel/Panel.styles.d.ts +19 -15
  191. package/dist/Panel/Panel.styles.js +19 -19
  192. package/dist/Panel/Panel.styles.js.map +1 -1
  193. package/dist/Pill/Pill.styles.d.ts +9 -5
  194. package/dist/Pill/Pill.styles.js +2 -2
  195. package/dist/PillSelect/PillSelect.styles.d.ts +7 -5
  196. package/dist/PillSelect/PillSelect.styles.js +4 -4
  197. package/dist/Popover/Popover.styles.d.ts +3 -2
  198. package/dist/Popover/Popover.styles.js +2 -2
  199. package/dist/Portal/Portal.styles.d.ts +2 -1
  200. package/dist/Portal/Portal.styles.js +1 -1
  201. package/dist/ProgressBar/ProgressBar.styles.d.ts +3 -3
  202. package/dist/ProgressBar/ProgressBar.styles.js +2 -2
  203. package/dist/RadioButton/RadioButton.styles.d.ts +5 -4
  204. package/dist/RadioButton/RadioButton.styles.js +3 -3
  205. package/dist/Required/Required.styles.d.ts +5 -4
  206. package/dist/Required/Required.styles.js +3 -3
  207. package/dist/Search/Search.js +6 -2
  208. package/dist/Search/Search.js.map +1 -1
  209. package/dist/Search/Search.styles.d.ts +11 -12
  210. package/dist/Search/Search.styles.js +13 -7
  211. package/dist/Search/Search.styles.js.map +1 -1
  212. package/dist/Section/Section.styles.d.ts +11 -9
  213. package/dist/Section/Section.styles.js +7 -7
  214. package/dist/SegmentedController/SegmentedController.js +1 -1
  215. package/dist/SegmentedController/SegmentedController.js.map +1 -1
  216. package/dist/SegmentedController/SegmentedController.styles.d.ts +8 -7
  217. package/dist/SegmentedController/SegmentedController.styles.js +9 -9
  218. package/dist/SegmentedController/SegmentedController.styles.js.map +1 -1
  219. package/dist/Select/Select.js +4 -4
  220. package/dist/Select/Select.js.map +1 -1
  221. package/dist/Select/Select.styles.d.ts +13 -9
  222. package/dist/Select/Select.styles.js +7 -7
  223. package/dist/Semantic/Semantic.styles.d.ts +359 -20
  224. package/dist/Semantic/Semantic.styles.js +11 -12
  225. package/dist/Semantic/Semantic.styles.js.map +1 -1
  226. package/dist/Slider/Slider.styles.d.ts +9 -7
  227. package/dist/Slider/Slider.styles.js +5 -5
  228. package/dist/Spinner/Spinner.styles.d.ts +9 -8
  229. package/dist/Spinner/Spinner.styles.js +7 -7
  230. package/dist/SplitViewCard/SplitViewCard.styles.d.ts +13 -11
  231. package/dist/SplitViewCard/SplitViewCard.styles.js +8 -8
  232. package/dist/SuperSelect/SuperSelect.components.d.ts +1 -1
  233. package/dist/SuperSelect/SuperSelect.components.js.map +1 -1
  234. package/dist/SuperSelect/SuperSelect.presets.styles.d.ts +3 -1
  235. package/dist/SuperSelect/SuperSelect.presets.styles.js +1 -1
  236. package/dist/SuperSelect/SuperSelect.styles.d.ts +67 -54
  237. package/dist/SuperSelect/SuperSelect.styles.js +37 -37
  238. package/dist/SuperSelect/SuperSelect.styles.js.map +1 -1
  239. package/dist/SuperSelect/SuperSelect.types.d.ts +9 -8
  240. package/dist/SuperSelect/SuperSelect.types.js.map +1 -1
  241. package/dist/SuperSelect/presets/filterPreset.js.map +1 -1
  242. package/dist/SuperSelect/useSuperSelect.js.map +1 -1
  243. package/dist/Switch/Switch.styles.d.ts +6 -5
  244. package/dist/Switch/Switch.styles.js +4 -4
  245. package/dist/Table/Table.d.ts +7 -3
  246. package/dist/Table/Table.js.map +1 -1
  247. package/dist/Table/Table.styles.d.ts +69 -45
  248. package/dist/Table/Table.styles.js +28 -28
  249. package/dist/TableShelf/TableShelf.styles.d.ts +6 -5
  250. package/dist/TableShelf/TableShelf.styles.js +5 -5
  251. package/dist/Tabs/Tabs.styles.d.ts +31 -9
  252. package/dist/Tabs/Tabs.styles.js +15 -15
  253. package/dist/Tearsheet/Tearsheet.styles.d.ts +12 -10
  254. package/dist/Tearsheet/Tearsheet.styles.js +6 -6
  255. package/dist/Tearsheet/Tearsheet.styles.js.map +1 -1
  256. package/dist/TextArea/TextArea.js +6 -2
  257. package/dist/TextArea/TextArea.js.map +1 -1
  258. package/dist/TextArea/TextArea.styles.d.ts +7 -1
  259. package/dist/TextArea/TextArea.styles.js +2 -2
  260. package/dist/TextArea/TextArea.styles.js.map +1 -1
  261. package/dist/TextEditor/TextEditor.styles.d.ts +3 -2
  262. package/dist/TextEditorOutput/TextEditorOutput.styles.d.ts +2 -1
  263. package/dist/TextEditorOutput/TextEditorOutput.styles.js +1 -1
  264. package/dist/Thumbnail/Thumbnail.hooks.d.ts +131 -141
  265. package/dist/Thumbnail/Thumbnail.js +69 -56
  266. package/dist/Thumbnail/Thumbnail.js.map +1 -1
  267. package/dist/Thumbnail/Thumbnail.styles.d.ts +34 -32
  268. package/dist/Thumbnail/Thumbnail.styles.js +78 -79
  269. package/dist/Thumbnail/Thumbnail.styles.js.map +1 -1
  270. package/dist/Thumbnail/Thumbnail.types.d.ts +1 -1
  271. package/dist/Thumbnail/Thumbnail.types.js.map +1 -1
  272. package/dist/Thumbnail/ThumbnailCaption.js +10 -10
  273. package/dist/Thumbnail/ThumbnailCaption.js.map +1 -1
  274. package/dist/ThumbnailGrid/ThumbnailGrid.js +2 -2
  275. package/dist/ThumbnailGrid/ThumbnailGrid.js.map +1 -1
  276. package/dist/ThumbnailGrid/ThumbnailGrid.styles.d.ts +20 -8
  277. package/dist/ThumbnailGrid/ThumbnailGrid.styles.js +7 -7
  278. package/dist/TieredSelect/TierSelectionTieredSelect.js +9 -9
  279. package/dist/TieredSelect/TierSelectionTieredSelect.js.map +1 -1
  280. package/dist/TieredSelect/TieredSelect.styles.d.ts +29 -13
  281. package/dist/TieredSelect/TieredSelect.styles.js +9 -9
  282. package/dist/TieredSelect/TieredSelect.types.d.ts +1 -1
  283. package/dist/TieredSelect/TieredSelect.types.js.map +1 -1
  284. package/dist/TieredSelect/TieredSelectMenu.js +10 -10
  285. package/dist/TieredSelect/TieredSelectMenu.js.map +1 -1
  286. package/dist/Tile/Tile.js +1 -1
  287. package/dist/Tile/Tile.js.map +1 -1
  288. package/dist/Tile/Tile.styles.d.ts +13 -11
  289. package/dist/Tile/Tile.styles.js +8 -8
  290. package/dist/Title/Title.styles.d.ts +12 -8
  291. package/dist/Title/Title.styles.js +7 -7
  292. package/dist/Toast/Toast.styles.d.ts +7 -5
  293. package/dist/Toast/Toast.styles.js +3 -3
  294. package/dist/ToggleButton/ToggleButton.styles.d.ts +4 -2
  295. package/dist/ToggleButton/ToggleButton.styles.js +1 -1
  296. package/dist/Token/Token.styles.d.ts +9 -5
  297. package/dist/Token/Token.styles.js +3 -3
  298. package/dist/ToolHeader/ToolHeader.d.ts +8 -4
  299. package/dist/ToolHeader/ToolHeader.styles.d.ts +9 -7
  300. package/dist/ToolHeader/ToolHeader.styles.js +8 -8
  301. package/dist/ToolHeader/ToolHeader.styles.js.map +1 -1
  302. package/dist/ToolLandingPage/ToolLandingPage.styles.d.ts +5 -3
  303. package/dist/ToolLandingPage/ToolLandingPage.styles.js +3 -3
  304. package/dist/Tooltip/Tooltip.js +3 -4
  305. package/dist/Tooltip/Tooltip.js.map +1 -1
  306. package/dist/Tooltip/Tooltip.styles.d.ts +3 -2
  307. package/dist/Tooltip/Tooltip.styles.js +3 -3
  308. package/dist/Tooltip/Tooltip.styles.js.map +1 -1
  309. package/dist/Tree/Tree.styles.d.ts +24 -12
  310. package/dist/Tree/Tree.styles.js +9 -9
  311. package/dist/Typeahead/Typeahead.js +1 -1
  312. package/dist/Typeahead/Typeahead.js.map +1 -1
  313. package/dist/Typeahead/Typeahead.styles.d.ts +5 -7
  314. package/dist/Typeahead/Typeahead.styles.js +3 -3
  315. package/dist/Typography/Typography.styles.d.ts +5 -4
  316. package/dist/Typography/Typography.styles.js +1 -1
  317. package/dist/Typography/Typography.styles.js.map +1 -1
  318. package/dist/Typography/Typography.table.story.js +2 -2
  319. package/dist/_hooks/ClickOutside.js +19 -5
  320. package/dist/_hooks/ClickOutside.js.map +1 -1
  321. package/dist/_hooks/I18n.d.ts +44 -9
  322. package/dist/_hooks/I18n.js +63 -28
  323. package/dist/_hooks/I18n.js.map +1 -1
  324. package/dist/_styles/arrows.d.ts +4 -4
  325. package/dist/_styles/borderRadius.d.ts +1 -1
  326. package/dist/_styles/mixins.d.ts +7 -7
  327. package/dist/_styles/shadows.d.ts +1 -1
  328. package/dist/_typedoc/AnchorNavigation/AnchorNavigation.types.json +3 -3
  329. package/dist/_typedoc/Avatar/Avatar.types.json +20 -20
  330. package/dist/_typedoc/AvatarStack/AvatarStack.types.json +24 -24
  331. package/dist/_typedoc/Badge/Badge.types.json +6 -6
  332. package/dist/_typedoc/Banner/Banner.types.json +13 -13
  333. package/dist/_typedoc/Box/Box.types.json +77 -77
  334. package/dist/_typedoc/Breadcrumbs/Breadcrumbs.types.json +10 -10
  335. package/dist/_typedoc/Button/Button.types.json +13 -13
  336. package/dist/_typedoc/Calendar/Calendar.types.json +80 -80
  337. package/dist/_typedoc/Card/Card.types.json +6 -6
  338. package/dist/_typedoc/Checkbox/Checkbox.types.json +9 -9
  339. package/dist/_typedoc/ContactItem/ContactItem.types.json +9 -9
  340. package/dist/_typedoc/DateInput/DateInput.types.json +35 -35
  341. package/dist/_typedoc/DateSelect/DateSelect.types.json +13 -13
  342. package/dist/_typedoc/DetailPage/DetailPage.types.json +5 -5
  343. package/dist/_typedoc/Dropdown/Dropdown.types.json +37 -37
  344. package/dist/_typedoc/DropdownFlyout/DropdownFlyout.types.json +39 -29
  345. package/dist/_typedoc/Dropzone/Dropzone.types.json +44 -44
  346. package/dist/_typedoc/EmptyState/EmptyState.types.json +16 -16
  347. package/dist/_typedoc/FileList/FileList.types.json +9 -9
  348. package/dist/_typedoc/FileSelect/FileSelect.types.json +27 -27
  349. package/dist/_typedoc/FileSelect/GridSource/GridSource.types.json +20 -20
  350. package/dist/_typedoc/FileSelect/LocalSource/LocalSource.types.json +14 -14
  351. package/dist/_typedoc/FileSelect/TreeSource/TreeSource.types.json +9 -9
  352. package/dist/_typedoc/Flex/Flex.types.json +27 -27
  353. package/dist/_typedoc/FlexList/FlexList.types.json +30 -30
  354. package/dist/_typedoc/Form/Form.types.json +747 -747
  355. package/dist/_typedoc/GhostPlaceholder/GhostPlaceholder.types.json +12 -12
  356. package/dist/_typedoc/Grid/Grid.types.json +8 -8
  357. package/dist/_typedoc/GroupSelect/GroupSelect.types.json +52 -52
  358. package/dist/_typedoc/Input/Input.types.json +2 -2
  359. package/dist/_typedoc/Link/Link.types.json +11 -6
  360. package/dist/_typedoc/ListPage/ListPage.types.json +13 -13
  361. package/dist/_typedoc/Menu/Menu.types.json +62 -62
  362. package/dist/_typedoc/MenuImperative/MenuImperative.types.json +74 -74
  363. package/dist/_typedoc/Modal/Modal.types.json +46 -46
  364. package/dist/_typedoc/MultiSelect/MultiSelect.types.json +31 -31
  365. package/dist/_typedoc/Notation/Notation.types.json +4 -4
  366. package/dist/_typedoc/NumberInput/NumberInput.types.json +37 -37
  367. package/dist/_typedoc/OverlayTrigger/OverlayTrigger.types.json +31 -31
  368. package/dist/_typedoc/PageLayout/PageLayout.types.json +29 -29
  369. package/dist/_typedoc/Pagination/Pagination.types.json +7 -7
  370. package/dist/_typedoc/Panel/Panel.types.json +28 -28
  371. package/dist/_typedoc/Pill/Pill.types.json +2 -2
  372. package/dist/_typedoc/PillSelect/PillSelect.types.json +49 -49
  373. package/dist/_typedoc/Popover/Popover.types.json +15 -15
  374. package/dist/_typedoc/ProgressBar/ProgressBar.types.json +6 -6
  375. package/dist/_typedoc/RadioButton/RadioButton.types.json +6 -6
  376. package/dist/_typedoc/Required/Required.types.json +5 -5
  377. package/dist/_typedoc/Search/Search.types.json +18 -18
  378. package/dist/_typedoc/Section/Section.types.json +15 -15
  379. package/dist/_typedoc/SegmentedController/SegmentedController.types.json +21 -21
  380. package/dist/_typedoc/Select/Select.types.json +60 -60
  381. package/dist/_typedoc/SettingsPage/SettingsPage.types.json +10 -10
  382. package/dist/_typedoc/Slider/Slider.types.json +6 -6
  383. package/dist/_typedoc/Spinner/Spinner.types.json +9 -9
  384. package/dist/_typedoc/SplitViewCard/SplitViewCard.types.json +12 -12
  385. package/dist/_typedoc/Switch/Switch.types.json +3 -3
  386. package/dist/_typedoc/Table/Table.types.json +101 -101
  387. package/dist/_typedoc/Tabs/Tabs.types.json +20 -20
  388. package/dist/_typedoc/Tearsheet/Tearsheet.types.json +17 -17
  389. package/dist/_typedoc/TextArea/TextArea.types.json +3 -3
  390. package/dist/_typedoc/TextEditor/TextEditor.types.json +9 -9
  391. package/dist/_typedoc/TextEditorOutput/TextEditorOutput.types.json +4 -4
  392. package/dist/_typedoc/Thumbnail/Thumbnail.types.json +19 -19
  393. package/dist/_typedoc/TieredDropdown/TieredDropdown.types.json +44 -44
  394. package/dist/_typedoc/TieredSelect/TieredSelect.types.json +30 -30
  395. package/dist/_typedoc/Tile/Tile.types.json +30 -30
  396. package/dist/_typedoc/Title/Title.types.json +3 -3
  397. package/dist/_typedoc/Toast/Toast.types.json +4 -4
  398. package/dist/_typedoc/ToggleButton/ToggleButton.types.json +4 -4
  399. package/dist/_typedoc/Token/Token.types.json +6 -6
  400. package/dist/_typedoc/ToolHeader/ToolHeader.types.json +10 -10
  401. package/dist/_typedoc/ToolLandingPage/ToolLandingPage.types.json +7 -7
  402. package/dist/_typedoc/Tooltip/Tooltip.types.json +13 -13
  403. package/dist/_typedoc/Tree/Tree.types.json +86 -86
  404. package/dist/_typedoc/Typeahead/Typeahead.types.json +2 -2
  405. package/dist/_typedoc/Typography/Typography.types.json +9 -9
  406. package/dist/_typedoc/_utils/types.json +3 -3
  407. package/package.json +90 -91
@@ -7,32 +7,32 @@ import { spacing } from '../_styles/spacing';
7
7
  var maxModalWidth = 528;
8
8
  var StyledBaseAvatar = /*#__PURE__*/styled(Avatar).withConfig({
9
9
  displayName: "StyledBaseAvatar",
10
- componentId: "core-12_21_2__sc-ft72hu-0"
10
+ componentId: "core-12_23_0__sc-ft72hu-0"
11
11
  })(["border-color:", ";border-style:solid;border-width:1px;&:hover{z-index:1;}&[role='img']:focus{outline:none;}"], colors.white);
12
12
  export var StyledAvatar = /*#__PURE__*/styled(StyledBaseAvatar).withConfig({
13
13
  displayName: "StyledAvatar",
14
- componentId: "core-12_21_2__sc-ft72hu-1"
14
+ componentId: "core-12_23_0__sc-ft72hu-1"
15
15
  })(["background-color:", ";"], function (props) {
16
16
  return colors[props.$color];
17
17
  });
18
18
  export var StyledContactItems = /*#__PURE__*/styled.div.withConfig({
19
19
  displayName: "StyledContactItems",
20
- componentId: "core-12_21_2__sc-ft72hu-2"
20
+ componentId: "core-12_23_0__sc-ft72hu-2"
21
21
  })(["padding-top:", "px;padding-bottom:", "px;padding-left:", "px;"], spacing.sm, spacing.sm, spacing.xs);
22
22
  export var StyledWrapper = /*#__PURE__*/styled.div.withConfig({
23
23
  displayName: "StyledWrapper",
24
- componentId: "core-12_21_2__sc-ft72hu-3"
24
+ componentId: "core-12_23_0__sc-ft72hu-3"
25
25
  })(["display:flex;", " + ", "{margin-left:-", "px;}"], StyledAvatar, StyledAvatar, spacing.sm);
26
26
  export var StyledViewAllWrapper = /*#__PURE__*/styled.div.withConfig({
27
27
  displayName: "StyledViewAllWrapper",
28
- componentId: "core-12_21_2__sc-ft72hu-4"
28
+ componentId: "core-12_23_0__sc-ft72hu-4"
29
29
  })(["display:flex;margin-left:", "px;margin-bottom:", "px;"], spacing.md, spacing.lg);
30
30
  export var StyledModalBody = /*#__PURE__*/styled(Modal.Body).withConfig({
31
31
  displayName: "StyledModalBody",
32
- componentId: "core-12_21_2__sc-ft72hu-5"
32
+ componentId: "core-12_23_0__sc-ft72hu-5"
33
33
  })(["max-width:", "px;"], maxModalWidth);
34
34
  export var StyledContactItem = /*#__PURE__*/styled(ContactItem).withConfig({
35
35
  displayName: "StyledContactItem",
36
- componentId: "core-12_21_2__sc-ft72hu-6"
36
+ componentId: "core-12_23_0__sc-ft72hu-6"
37
37
  })(["flex-shrink:0;"]);
38
38
  //# sourceMappingURL=AvatarStack.styles.js.map
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { BadgeLabelProps, BadgeProps } from './Badge.types';
2
- export declare const StyledBadge: import("styled-components").StyledComponent<"div", any, BadgeProps, never>;
3
- export declare const StyledBadgeLabel: import("styled-components").StyledComponent<"span", any, BadgeLabelProps, never>;
3
+ export declare const StyledBadge: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, BadgeProps>> & string;
4
+ export declare const StyledBadgeLabel: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, BadgeLabelProps>> & string;
@@ -1,10 +1,10 @@
1
1
  import styled from 'styled-components';
2
2
  export var StyledBadge = /*#__PURE__*/styled.div.withConfig({
3
3
  displayName: "StyledBadge",
4
- componentId: "core-12_21_2__sc-rpertu-0"
4
+ componentId: "core-12_23_0__sc-rpertu-0"
5
5
  })(["display:inline-block;position:relative;"]);
6
6
  export var StyledBadgeLabel = /*#__PURE__*/styled.span.withConfig({
7
7
  displayName: "StyledBadgeLabel",
8
- componentId: "core-12_21_2__sc-rpertu-1"
8
+ componentId: "core-12_23_0__sc-rpertu-1"
9
9
  })(["bottom:100%;position:absolute;right:0;transform:translateX(50%) translateY(50%);"]);
10
10
  //# sourceMappingURL=Badge.styles.js.map
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import type { BadgePillProps } from './BadgePill.types';
3
+ export declare const BadgePill: (props: BadgePillProps) => React.JSX.Element;
@@ -0,0 +1,25 @@
1
+ var _excluded = ["children", "dotIndicator", "value", "hidden", "xOffset", "yOffset"];
2
+ function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
3
+ function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
4
+ function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
5
+ import React from 'react';
6
+ import { StyledBadgeContainer, StyledBadgeContent, StyledBadgeCounter, StyledBadgeDotIndicator } from './BadgePill.styles';
7
+ var MAX_DISPLAY_VALUE = 99;
8
+ export var BadgePill = function BadgePill(props) {
9
+ var children = props.children,
10
+ dotIndicator = props.dotIndicator,
11
+ value = props.value,
12
+ hidden = props.hidden,
13
+ xOffset = props.xOffset,
14
+ yOffset = props.yOffset,
15
+ restProps = _objectWithoutProperties(props, _excluded);
16
+ return /*#__PURE__*/React.createElement(StyledBadgeContainer, null, children, /*#__PURE__*/React.createElement(StyledBadgeContent, _extends({}, restProps, {
17
+ $overlapping: !!children,
18
+ $hidden: hidden,
19
+ $xOffset: xOffset,
20
+ $yOffset: yOffset
21
+ }), dotIndicator && /*#__PURE__*/React.createElement(StyledBadgeDotIndicator, null), !dotIndicator && /*#__PURE__*/React.createElement(StyledBadgeCounter, {
22
+ $oneDigit: value >= 0 && value < 10
23
+ }, value > MAX_DISPLAY_VALUE ? "".concat(MAX_DISPLAY_VALUE, "+") : value)));
24
+ };
25
+ //# sourceMappingURL=BadgePill.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgePill.js","names":["React","StyledBadgeContainer","StyledBadgeContent","StyledBadgeCounter","StyledBadgeDotIndicator","MAX_DISPLAY_VALUE","BadgePill","props","children","dotIndicator","value","hidden","xOffset","yOffset","restProps","_objectWithoutProperties","_excluded","createElement","_extends","$overlapping","$hidden","$xOffset","$yOffset","$oneDigit","concat"],"sources":["../../src/BadgePill/BadgePill.tsx"],"sourcesContent":["import React from 'react'\nimport {\n StyledBadgeContainer,\n StyledBadgeContent,\n StyledBadgeCounter,\n StyledBadgeDotIndicator,\n} from './BadgePill.styles'\nimport type { BadgePillProps } from './BadgePill.types'\n\nconst MAX_DISPLAY_VALUE = 99\n\nexport const BadgePill = (props: BadgePillProps) => {\n const {\n children,\n dotIndicator,\n value,\n hidden,\n xOffset,\n yOffset,\n ...restProps\n } = props\n\n return (\n <StyledBadgeContainer>\n {children}\n <StyledBadgeContent\n {...restProps}\n $overlapping={!!children}\n $hidden={hidden}\n $xOffset={xOffset}\n $yOffset={yOffset}\n >\n {dotIndicator && <StyledBadgeDotIndicator />}\n {!dotIndicator && (\n <StyledBadgeCounter $oneDigit={value >= 0 && value < 10}>\n {value > MAX_DISPLAY_VALUE ? `${MAX_DISPLAY_VALUE}+` : value}\n </StyledBadgeCounter>\n )}\n </StyledBadgeContent>\n </StyledBadgeContainer>\n )\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,oBAAoB,EACpBC,kBAAkB,EAClBC,kBAAkB,EAClBC,uBAAuB,QAClB,oBAAoB;AAG3B,IAAMC,iBAAiB,GAAG,EAAE;AAE5B,OAAO,IAAMC,SAAS,GAAG,SAAZA,SAASA,CAAIC,KAAqB,EAAK;EAClD,IACEC,QAAQ,GAOND,KAAK,CAPPC,QAAQ;IACRC,YAAY,GAMVF,KAAK,CANPE,YAAY;IACZC,KAAK,GAKHH,KAAK,CALPG,KAAK;IACLC,MAAM,GAIJJ,KAAK,CAJPI,MAAM;IACNC,OAAO,GAGLL,KAAK,CAHPK,OAAO;IACPC,OAAO,GAELN,KAAK,CAFPM,OAAO;IACJC,SAAS,GAAAC,wBAAA,CACVR,KAAK,EAAAS,SAAA;EAET,oBACEhB,KAAA,CAAAiB,aAAA,CAAChB,oBAAoB,QAClBO,QAAQ,eACTR,KAAA,CAAAiB,aAAA,CAACf,kBAAkB,EAAAgB,QAAA,KACbJ,SAAS;IACbK,YAAY,EAAE,CAAC,CAACX,QAAS;IACzBY,OAAO,EAAET,MAAO;IAChBU,QAAQ,EAAET,OAAQ;IAClBU,QAAQ,EAAET;EAAQ,IAEjBJ,YAAY,iBAAIT,KAAA,CAAAiB,aAAA,CAACb,uBAAuB,MAAE,CAAC,EAC3C,CAACK,YAAY,iBACZT,KAAA,CAAAiB,aAAA,CAACd,kBAAkB;IAACoB,SAAS,EAAEb,KAAK,IAAI,CAAC,IAAIA,KAAK,GAAG;EAAG,GACrDA,KAAK,GAAGL,iBAAiB,MAAAmB,MAAA,CAAMnB,iBAAiB,SAAMK,KACrC,CAEJ,CACA,CAAC;AAE3B,CAAC"}
@@ -0,0 +1,12 @@
1
+ /// <reference types="react" />
2
+ export declare const StyledBadgeContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
3
+ export declare const StyledBadgeContent: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
4
+ $overlapping: boolean;
5
+ $hidden?: boolean | undefined;
6
+ $xOffset?: number | undefined;
7
+ $yOffset?: number | undefined;
8
+ }>> & string;
9
+ export declare const StyledBadgeDotIndicator: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
10
+ export declare const StyledBadgeCounter: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
11
+ $oneDigit?: boolean | undefined;
12
+ }>> & string;
@@ -0,0 +1,33 @@
1
+ import styled from 'styled-components';
2
+ import { getTypographyIntent } from '../Typography';
3
+ import { colors } from '../_styles/colors';
4
+ export var StyledBadgeContainer = /*#__PURE__*/styled.div.withConfig({
5
+ displayName: "StyledBadgeContainer",
6
+ componentId: "core-12_23_0__sc-s2n9gd-0"
7
+ })(["display:inline-flex;position:relative;"]);
8
+ export var StyledBadgeContent = /*#__PURE__*/styled.div.withConfig({
9
+ displayName: "StyledBadgeContent",
10
+ componentId: "core-12_23_0__sc-s2n9gd-1"
11
+ })(["position:relative;", " ", " pointer-events:none;user-select:none;"], function (_ref) {
12
+ var $overlapping = _ref.$overlapping,
13
+ _ref$$xOffset = _ref.$xOffset,
14
+ $xOffset = _ref$$xOffset === void 0 ? 0 : _ref$$xOffset,
15
+ _ref$$yOffset = _ref.$yOffset,
16
+ $yOffset = _ref$$yOffset === void 0 ? 0 : _ref$$yOffset;
17
+ return $overlapping && "\n position: absolute;\n top: 0;\n right: 0;\n z-index: 1;\n transform: translate(\n calc(50% + ".concat($xOffset, "px),\n calc(-50% + ").concat($yOffset * -1, "px)\n );\n ");
18
+ }, function (props) {
19
+ return props.$hidden ? 'visibility: hidden;' : '';
20
+ });
21
+ export var StyledBadgeDotIndicator = /*#__PURE__*/styled.div.withConfig({
22
+ displayName: "StyledBadgeDotIndicator",
23
+ componentId: "core-12_23_0__sc-s2n9gd-2"
24
+ })(["width:6px;height:6px;border-radius:50%;background-color:", ";"], colors.orange50);
25
+ var oneDigitStyles = "\n border-radius: 50%;\n padding: 2px;\n min-width: 21.5px;\n min-height: 21.5px;\n";
26
+ var multiDigitStyles = "\n border-radius: 10px;\n padding: 2px 8px;\n";
27
+ export var StyledBadgeCounter = /*#__PURE__*/styled.div.withConfig({
28
+ displayName: "StyledBadgeCounter",
29
+ componentId: "core-12_23_0__sc-s2n9gd-3"
30
+ })(["display:inline-flex;justify-content:center;align-items:center;color:", ";background-color:", ";", " ", ""], colors.white, colors.orange50, getTypographyIntent('small'), function (props) {
31
+ return props.$oneDigit ? oneDigitStyles : multiDigitStyles;
32
+ });
33
+ //# sourceMappingURL=BadgePill.styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgePill.styles.js","names":["styled","getTypographyIntent","colors","StyledBadgeContainer","div","withConfig","displayName","componentId","StyledBadgeContent","_ref","$overlapping","_ref$$xOffset","$xOffset","_ref$$yOffset","$yOffset","concat","props","$hidden","StyledBadgeDotIndicator","orange50","oneDigitStyles","multiDigitStyles","StyledBadgeCounter","white","$oneDigit"],"sources":["../../src/BadgePill/BadgePill.styles.ts"],"sourcesContent":["import styled from 'styled-components'\nimport { getTypographyIntent } from '../Typography'\nimport { colors } from '../_styles/colors'\n\nexport const StyledBadgeContainer = styled.div`\n display: inline-flex;\n position: relative;\n`\n\nexport const StyledBadgeContent = styled.div<{\n $overlapping: boolean\n $hidden?: boolean\n $xOffset?: number\n $yOffset?: number\n}>`\n position: relative;\n ${({ $overlapping, $xOffset = 0, $yOffset = 0 }) =>\n $overlapping &&\n `\n position: absolute;\n top: 0;\n right: 0;\n z-index: 1;\n transform: translate(\n calc(50% + ${$xOffset}px),\n calc(-50% + ${$yOffset * -1}px)\n );\n `}\n ${(props) => (props.$hidden ? 'visibility: hidden;' : '')}\n pointer-events: none;\n user-select: none;\n`\n\nexport const StyledBadgeDotIndicator = styled.div`\n width: 6px;\n height: 6px;\n border-radius: 50%;\n background-color: ${colors.orange50};\n`\n\nconst oneDigitStyles = `\n border-radius: 50%;\n padding: 2px;\n min-width: 21.5px;\n min-height: 21.5px;\n`\n\nconst multiDigitStyles = `\n border-radius: 10px;\n padding: 2px 8px;\n`\n\nexport const StyledBadgeCounter = styled.div<{ $oneDigit?: boolean }>`\n display: inline-flex;\n justify-content: center;\n align-items: center;\n color: ${colors.white};\n background-color: ${colors.orange50};\n ${getTypographyIntent('small')}\n ${(props) => (props.$oneDigit ? oneDigitStyles : multiDigitStyles)}\n`\n"],"mappings":"AAAA,OAAOA,MAAM,MAAM,mBAAmB;AACtC,SAASC,mBAAmB,QAAQ,eAAe;AACnD,SAASC,MAAM,QAAQ,mBAAmB;AAE1C,OAAO,IAAMC,oBAAoB,gBAAGH,MAAM,CAACI,GAAG,CAAAC,UAAA;EAAAC,WAAA;EAAAC,WAAA;AAAA,8CAG7C;AAED,OAAO,IAAMC,kBAAkB,gBAAGR,MAAM,CAACI,GAAG,CAAAC,UAAA;EAAAC,WAAA;EAAAC,WAAA;AAAA,0EAOxC,UAAAE,IAAA;EAAA,IAAGC,YAAY,GAAAD,IAAA,CAAZC,YAAY;IAAAC,aAAA,GAAAF,IAAA,CAAEG,QAAQ;IAARA,QAAQ,GAAAD,aAAA,cAAG,CAAC,GAAAA,aAAA;IAAAE,aAAA,GAAAJ,IAAA,CAAEK,QAAQ;IAARA,QAAQ,GAAAD,aAAA,cAAG,CAAC,GAAAA,aAAA;EAAA,OAC3CH,YAAY,2HAAAK,MAAA,CAOGH,QAAQ,8BAAAG,MAAA,CACPD,QAAQ,GAAG,CAAC,CAAC,oBAE9B;AAAA,GACC,UAACE,KAAK;EAAA,OAAMA,KAAK,CAACC,OAAO,GAAG,qBAAqB,GAAG,EAAE;AAAA,CAAC,CAG1D;AAED,OAAO,IAAMC,uBAAuB,gBAAGlB,MAAM,CAACI,GAAG,CAAAC,UAAA;EAAAC,WAAA;EAAAC,WAAA;AAAA,sEAI3BL,MAAM,CAACiB,QAAQ,CACpC;AAED,IAAMC,cAAc,4FAKnB;AAED,IAAMC,gBAAgB,oDAGrB;AAED,OAAO,IAAMC,kBAAkB,gBAAGtB,MAAM,CAACI,GAAG,CAAAC,UAAA;EAAAC,WAAA;EAAAC,WAAA;AAAA,iHAIjCL,MAAM,CAACqB,KAAK,EACDrB,MAAM,CAACiB,QAAQ,EACjClB,mBAAmB,CAAC,OAAO,CAAC,EAC5B,UAACe,KAAK;EAAA,OAAMA,KAAK,CAACQ,SAAS,GAAGJ,cAAc,GAAGC,gBAAgB;AAAA,CAAC,CACnE"}
@@ -0,0 +1,50 @@
1
+ import type { ReactNode } from 'react';
2
+ declare type BadgePillBaseProps = {
3
+ /**
4
+ * Hide the badge conditionally
5
+ * @since 12.22.0
6
+ */
7
+ hidden?: boolean;
8
+ };
9
+ declare type BadgePillDotIndicatorProps = {
10
+ /**
11
+ * Renders a small dot indicator
12
+ * @since 12.22.0
13
+ */
14
+ dotIndicator: true;
15
+ value?: undefined;
16
+ };
17
+ declare type BadgePillCounterProps = {
18
+ dotIndicator?: undefined;
19
+ /**
20
+ * Renders a numeric counter value
21
+ * @since 12.22.0
22
+ */
23
+ value: number;
24
+ };
25
+ declare type BadgePillVariantProps = BadgePillDotIndicatorProps | BadgePillCounterProps;
26
+ declare type BadgePillInlineProps = {
27
+ children?: undefined;
28
+ xOffset?: undefined;
29
+ yOffset?: undefined;
30
+ };
31
+ declare type BadgePillOverlappingProps = {
32
+ /**
33
+ * The content that the badge will overlap
34
+ * @since 12.22.0
35
+ */
36
+ children: ReactNode;
37
+ /**
38
+ * Horizontal offset of the badge in pixels
39
+ * @since 12.22.0
40
+ */
41
+ xOffset?: number;
42
+ /**
43
+ * Vertical offset of the badge in pixels
44
+ * @since 12.22.0
45
+ */
46
+ yOffset?: number;
47
+ };
48
+ declare type BadgePillPositionProps = BadgePillInlineProps | BadgePillOverlappingProps;
49
+ export declare type BadgePillProps = BadgePillBaseProps & BadgePillPositionProps & BadgePillVariantProps;
50
+ export {};
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=BadgePill.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgePill.types.js","names":[],"sources":["../../src/BadgePill/BadgePill.types.ts"],"sourcesContent":["import type { ReactNode } from 'react'\n\ntype BadgePillBaseProps = {\n /**\n * Hide the badge conditionally\n * @since 12.22.0\n */\n hidden?: boolean\n}\n\ntype BadgePillDotIndicatorProps = {\n /**\n * Renders a small dot indicator\n * @since 12.22.0\n */\n dotIndicator: true\n value?: undefined\n}\n\ntype BadgePillCounterProps = {\n dotIndicator?: undefined\n /**\n * Renders a numeric counter value\n * @since 12.22.0\n */\n value: number\n}\n\ntype BadgePillVariantProps = BadgePillDotIndicatorProps | BadgePillCounterProps\n\ntype BadgePillInlineProps = {\n children?: undefined\n xOffset?: undefined\n yOffset?: undefined\n}\n\ntype BadgePillOverlappingProps = {\n /**\n * The content that the badge will overlap\n * @since 12.22.0\n */\n children: ReactNode\n /**\n * Horizontal offset of the badge in pixels\n * @since 12.22.0\n */\n xOffset?: number\n /**\n * Vertical offset of the badge in pixels\n * @since 12.22.0\n */\n yOffset?: number\n}\n\ntype BadgePillPositionProps = BadgePillInlineProps | BadgePillOverlappingProps\n\nexport type BadgePillProps = BadgePillBaseProps &\n BadgePillPositionProps &\n BadgePillVariantProps\n"],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export { BadgePill } from './BadgePill';
2
+ export type { BadgePillProps } from './BadgePill.types';
@@ -0,0 +1,2 @@
1
+ export { BadgePill } from './BadgePill';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["BadgePill"],"sources":["../../src/BadgePill/index.ts"],"sourcesContent":["export { BadgePill } from './BadgePill'\nexport type { BadgePillProps } from './BadgePill.types'\n"],"mappings":"AAAA,SAASA,SAAS,QAAQ,aAAa"}
@@ -68,7 +68,7 @@ var Banner_ = /*#__PURE__*/React.forwardRef(function Banner(_ref, ref) {
68
68
  return /*#__PURE__*/React.createElement(StyledBannerContainer, _extends({
69
69
  ref: ref,
70
70
  $isExpandable: isExpandable,
71
- variant: variant
71
+ $variant: variant
72
72
  }, props), isExpandable ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(StyledExpandableContentContainer, {
73
73
  justifyContent: "space-between",
74
74
  alignItems: "center",
@@ -1 +1 @@
1
- {"version":3,"file":"Banner.js","names":["Clear","EllipsisVertical","Error","Info","Warning","partition","React","Button","Card","Flex","Menu","useMenu","OverlayTrigger","useI18nContext","OverflowObserver","addSubcomponents","mergeRefs","StyledAction","StyledActionsTrigger","StyledBannerContainer","StyledBody","StyledContent","StyledExpandableContent","StyledExpandableContentContainer","StyledIconContainer","StyledMiniBannerContainer","StyledTitle","defaultIcons","error","createElement","size","attention","info","UNSAFE_attention_emphasized","Banner_","forwardRef","Banner","_ref","ref","children","variant","props","_objectWithoutProperties","_excluded","_ref2","element","isValidElement","type","ExpandableContent","Children","toArray","_ref3","_slicedToArray","expandableContentNodes","content","isExpandable","length","iconElement","useMemo","find","child","Icon","hasCustomIcon","icon","_extends","$isExpandable","Fragment","justifyContent","alignItems","gap","grow","Content","_ref4","_excluded2","_ref5","_ref5$expanded","expanded","_ref5$expandableConte","expandableContentMaxHeight","_excluded3","containerRef","useRef","_ref6","overflowRef","isOverflowingY","onAnimationEnd","current","$isOverflowingY","$expandableContentMaxHeight","tabIndex","Title","_ref7","_excluded4","Body","_ref8","_excluded5","Action","_ref9","_excluded6","DropdownAction","_ref0","_excluded7","Item","item","Actions","_ref1","_excluded8","actionButtons","filter","overlay","node","focus","usingHook","isSelectable","_ref10","Options","map","_ref11","idx","actionButtonProps","key","placement","arrow","_ref12","_excluded9","Dismiss","_ref13","_excluded0","I18n","t","ErrorBanner","_ref14","_excluded1","InfoBanner","_ref15","_excluded10","AttentionBanner","_ref16","_excluded11","ActionBanner","UNSAFE_MiniBanner","MiniBanner","_ref17","_ref17$variant","_excluded12","displayName"],"sources":["../../src/Banner/Banner.tsx"],"sourcesContent":["import {\n Clear,\n EllipsisVertical,\n Error,\n Info,\n Warning,\n} from '@procore/core-icons/dist'\nimport { partition } from 'ramda'\nimport React from 'react'\nimport { Button } from '../Button'\nimport { Card } from '../Card'\nimport { Flex } from '../Flex'\nimport { Menu, useMenu } from '../Menu/Menu'\nimport { OverlayTrigger } from '../OverlayTrigger'\nimport { useI18nContext } from '../_hooks/I18n'\nimport { OverflowObserver } from '../_hooks/OverflowObserver'\nimport { addSubcomponents } from '../_utils/addSubcomponents'\nimport { mergeRefs } from '../_utils/mergeRefs'\nimport type { ButtonAttributes, DivAttributes, Props } from '../_utils/types'\nimport {\n StyledAction,\n StyledActionsTrigger,\n StyledBannerContainer,\n StyledBody,\n StyledContent,\n StyledExpandableContent,\n StyledExpandableContentContainer,\n StyledIconContainer,\n StyledMiniBannerContainer,\n StyledTitle,\n} from './Banner.styles'\nimport type {\n BannerExpandableContentProps,\n BannerIconProps,\n BannerProps,\n BannerVariant,\n} from './Banner.types'\n\nconst defaultIcons: Record<BannerVariant, React.ReactNode> = {\n error: <Error size=\"lg\" />,\n attention: <Warning size=\"lg\" />,\n info: <Info size=\"lg\" />,\n UNSAFE_attention_emphasized: <Warning size=\"lg\" />,\n}\n\nconst Banner_ = React.forwardRef<HTMLDivElement, DivAttributes & BannerProps>(\n function Banner({ children, variant, ...props }, ref) {\n const [expandableContentNodes, content] = partition(\n (element: React.ReactNode) =>\n React.isValidElement(element) && element.type === ExpandableContent,\n React.Children.toArray(children)\n ) as [React.ReactElement[], React.ReactElement[]]\n const isExpandable = expandableContentNodes.length !== 0\n\n const iconElement = React.useMemo(() => {\n return React.Children.toArray(children).find(\n (child) => React.isValidElement(child) && child.type === Icon\n ) as React.ReactElement<BannerIconProps> | undefined\n }, [children])\n\n const hasCustomIcon = iconElement && iconElement.props.icon\n\n return (\n <StyledBannerContainer\n ref={ref}\n $isExpandable={isExpandable}\n variant={variant}\n {...props}\n >\n {isExpandable ? (\n <>\n <StyledExpandableContentContainer\n justifyContent=\"space-between\"\n alignItems=\"center\"\n gap=\"lg\"\n >\n {!hasCustomIcon && <Icon icon={defaultIcons[variant]} />}\n {content}\n </StyledExpandableContentContainer>\n {expandableContentNodes}\n </>\n ) : (\n <Flex\n justifyContent=\"flex-start\"\n alignItems=\"center\"\n gap=\"lg\"\n grow=\"1\"\n >\n {!hasCustomIcon && <Icon icon={defaultIcons[variant]} />}\n {content}\n </Flex>\n )}\n </StyledBannerContainer>\n )\n }\n)\n\nconst Content = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Content({ children, ...props }, ref) {\n return (\n <StyledContent {...props} ref={ref}>\n {children}\n </StyledContent>\n )\n }\n)\n\nconst ExpandableContent = React.forwardRef<\n HTMLDivElement,\n DivAttributes & BannerExpandableContentProps\n>(function ExpandableContent(\n { children, expanded = false, expandableContentMaxHeight = 120, ...props },\n ref\n) {\n const containerRef = React.useRef<HTMLDivElement>(null)\n\n return expanded ? (\n <OverflowObserver>\n {({ ref: overflowRef, isOverflowingY }) => (\n <StyledExpandableContent\n ref={mergeRefs(ref, containerRef)}\n data-qa=\"core-banner-expandable-content\"\n onAnimationEnd={() => overflowRef(containerRef.current)}\n $isOverflowingY={isOverflowingY}\n $expandableContentMaxHeight={expandableContentMaxHeight}\n {...props}\n {...(isOverflowingY && { tabIndex: 0 })}\n >\n {children}\n </StyledExpandableContent>\n )}\n </OverflowObserver>\n ) : null\n})\n\nconst Title = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Title({ children, ...props }, ref) {\n return (\n <StyledTitle {...props} ref={ref}>\n {children}\n </StyledTitle>\n )\n }\n)\n\nconst Body = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Body({ children, ...props }, ref) {\n return (\n <StyledBody {...props} ref={ref}>\n {children}\n </StyledBody>\n )\n }\n)\n\nconst Action = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Action({ children, ...props }, ref) {\n return (\n <StyledAction {...props} ref={ref}>\n {children}\n </StyledAction>\n )\n }\n)\n\nconst DropdownAction = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function DropdownAction({ children, ...props }, ref) {\n return (\n <Menu.Item ref={ref} item={null} {...(props as any)}>\n {children}\n </Menu.Item>\n )\n }\n)\n\nconst Actions = React.forwardRef<HTMLButtonElement, ButtonAttributes & Props>(\n function Actions({ children, ...props }, ref) {\n const actionButtons = React.Children.toArray(children).filter(\n (element: React.ReactNode) =>\n React.isValidElement(element) && element.type === Action\n ) as React.ReactElement[]\n\n return (\n <OverlayTrigger\n overlay={\n <Card>\n <Menu\n ref={(node) => node?.focus()}\n usingHook={useMenu({\n isSelectable: ({ type }) => type === DropdownAction,\n })}\n >\n <Menu.Options>\n {actionButtons.map(({ props: actionButtonProps }, idx) => (\n <DropdownAction key={idx} {...actionButtonProps} />\n ))}\n </Menu.Options>\n </Menu>\n </Card>\n }\n ref={ref}\n placement=\"bottom-right\"\n >\n <StyledActionsTrigger\n data-qa=\"core-banner-actions-trigger\"\n variant=\"tertiary\"\n arrow={false}\n icon={<EllipsisVertical />}\n {...props}\n />\n </OverlayTrigger>\n )\n }\n)\n\nconst Icon = React.forwardRef<HTMLDivElement, DivAttributes & BannerIconProps>(\n function Icon({ children, icon, ...props }, ref) {\n return (\n <StyledIconContainer ref={ref} aria-hidden=\"true\" {...props}>\n {icon}\n </StyledIconContainer>\n )\n }\n)\n\nconst Dismiss = React.forwardRef<HTMLButtonElement, ButtonAttributes & Props>(\n function Dismiss({ children, ...props }, ref) {\n const I18n = useI18nContext()\n\n return (\n <Button\n aria-label={I18n.t('core.banner.dismissAlert')}\n ref={ref}\n {...props}\n icon={<Clear />}\n variant=\"tertiary\"\n />\n )\n }\n)\n\nexport const ErrorBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props\n>(function ErrorBanner({ children, ...props }, ref) {\n return (\n <Banner ref={ref} variant=\"error\" {...props}>\n <Icon icon={<Error size=\"lg\" />} />\n {children}\n </Banner>\n )\n})\n\nexport const InfoBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props\n>(function InfoBanner({ children, ...props }, ref) {\n return (\n <Banner ref={ref} variant=\"info\" {...props}>\n <Icon icon={<Info size=\"lg\" />} />\n {children}\n </Banner>\n )\n})\n\n/**\n * @since 11.26.0\n */\nexport const AttentionBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props\n>(function AttentionBanner({ children, ...props }, ref) {\n return (\n <Banner ref={ref} variant=\"attention\" {...props}>\n <Icon icon={<Warning size=\"lg\" />} />\n {children}\n </Banner>\n )\n})\n/**\n * @deprecated ActionBanner was renamed to AttentionBanner.\n * @deprecatedSince 11.26.0\n */\nexport const ActionBanner = AttentionBanner\n\nexport const UNSAFE_MiniBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props & { variant?: BannerVariant }\n>(function MiniBanner({ children, variant = 'info', ...props }, ref) {\n return (\n <StyledMiniBannerContainer ref={ref} variant={variant} {...props}>\n {children}\n </StyledMiniBannerContainer>\n )\n})\n\nBanner_.displayName = 'Banner'\n\nBody.displayName = 'Banner.Body'\n\nContent.displayName = 'Banner.Content'\n\nExpandableContent.displayName = 'Banner.ExpandableContent'\n\nTitle.displayName = 'Banner.Title'\n\nAction.displayName = 'Banner.Action'\n\nActions.displayName = 'Banner.Actions'\n\nDropdownAction.displayName = 'Banner.DropdownAction'\n\nIcon.displayName = 'Banner.Icon'\n\nDismiss.displayName = 'Banner.Dismiss'\n\nErrorBanner.displayName = 'ErrorBanner'\n\nInfoBanner.displayName = 'InfoBanner'\n\nAttentionBanner.displayName = 'AttentionBanner'\n\nActionBanner.displayName = 'ActionBanner'\n\nUNSAFE_MiniBanner.displayName = 'MiniBanner'\n\n/**\n\n\n We use banners to contextually convey complicated or supplemental information\n to a user. Depending on the type of banner, we can provide more information\n about a feature or page the user is on, an action the user needs to perform,\n or an error the user has encountered.\n\n Procore banners are informative and actionable. Always explain what the user\n needs to know (and in some cases, why they’re seeing the banner), and provide\n an actionable next step.\n\n @since 10.19.0\n\n @see [Storybook](https://stories.core.procore.com/?path=/story/core-react_demos-banner--demo)\n\n @see [Design Guidelines](https://design.procore.com/banner)\n\n */\nexport const Banner = addSubcomponents(\n {\n Body,\n Content,\n ExpandableContent,\n Title,\n Action,\n Actions,\n Icon,\n Dismiss,\n },\n Banner_\n)\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA,SACEA,KAAK,EACLC,gBAAgB,EAChBC,KAAK,EACLC,IAAI,EACJC,OAAO,QACF,0BAA0B;AACjC,SAASC,SAAS,QAAQ,OAAO;AACjC,OAAOC,KAAK,MAAM,OAAO;AACzB,SAASC,MAAM,QAAQ,WAAW;AAClC,SAASC,IAAI,QAAQ,SAAS;AAC9B,SAASC,IAAI,QAAQ,SAAS;AAC9B,SAASC,IAAI,EAAEC,OAAO,QAAQ,cAAc;AAC5C,SAASC,cAAc,QAAQ,mBAAmB;AAClD,SAASC,cAAc,QAAQ,gBAAgB;AAC/C,SAASC,gBAAgB,QAAQ,4BAA4B;AAC7D,SAASC,gBAAgB,QAAQ,4BAA4B;AAC7D,SAASC,SAAS,QAAQ,qBAAqB;AAE/C,SACEC,YAAY,EACZC,oBAAoB,EACpBC,qBAAqB,E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,GAAKC,KAAK,GAC7DF,QACwB,CAAC;AAEhC,CAAC,CAAC;AAEFL,OAAO,CAAC+G,WAAW,GAAG,QAAQ;AAE9BpD,IAAI,CAACoD,WAAW,GAAG,aAAa;AAEhC1E,OAAO,CAAC0E,WAAW,GAAG,gBAAgB;AAEtCjG,iBAAiB,CAACiG,WAAW,GAAG,0BAA0B;AAE1DvD,KAAK,CAACuD,WAAW,GAAG,cAAc;AAElCjD,MAAM,CAACiD,WAAW,GAAG,eAAe;AAEpCzC,OAAO,CAACyC,WAAW,GAAG,gBAAgB;AAEtC9C,cAAc,CAAC8C,WAAW,GAAG,uBAAuB;AAEpDpF,IAAI,CAACoF,WAAW,GAAG,aAAa;AAEhCpB,OAAO,CAACoB,WAAW,GAAG,gBAAgB;AAEtCf,WAAW,CAACe,WAAW,GAAG,aAAa;AAEvCZ,UAAU,CAACY,WAAW,GAAG,YAAY;AAErCT,eAAe,CAACS,WAAW,GAAG,iBAAiB;AAE/CN,YAAY,CAACM,WAAW,GAAG,cAAc;AAEzCL,iBAAiB,CAACK,WAAW,GAAG,YAAY;;AAE5C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAM7G,MAAM,GAAGrB,gBAAgB,CACpC;EACE8E,IAAI,EAAJA,IAAI;EACJtB,OAAO,EAAPA,OAAO;EACPvB,iBAAiB,EAAjBA,iBAAiB;EACjB0C,KAAK,EAALA,KAAK;EACLM,MAAM,EAANA,MAAM;EACNQ,OAAO,EAAPA,OAAO;EACP3C,IAAI,EAAJA,IAAI;EACJgE,OAAO,EAAPA;AACF,CAAC,EACD3F,OACF,CAAC"}
1
+ {"version":3,"file":"Banner.js","names":["Clear","EllipsisVertical","Error","Info","Warning","partition","React","Button","Card","Flex","Menu","useMenu","OverlayTrigger","useI18nContext","OverflowObserver","addSubcomponents","mergeRefs","StyledAction","StyledActionsTrigger","StyledBannerContainer","StyledBody","StyledContent","StyledExpandableContent","StyledExpandableContentContainer","StyledIconContainer","StyledMiniBannerContainer","StyledTitle","defaultIcons","error","createElement","size","attention","info","UNSAFE_attention_emphasized","Banner_","forwardRef","Banner","_ref","ref","children","variant","props","_objectWithoutProperties","_excluded","_ref2","element","isValidElement","type","ExpandableContent","Children","toArray","_ref3","_slicedToArray","expandableContentNodes","content","isExpandable","length","iconElement","useMemo","find","child","Icon","hasCustomIcon","icon","_extends","$isExpandable","$variant","Fragment","justifyContent","alignItems","gap","grow","Content","_ref4","_excluded2","_ref5","_ref5$expanded","expanded","_ref5$expandableConte","expandableContentMaxHeight","_excluded3","containerRef","useRef","_ref6","overflowRef","isOverflowingY","onAnimationEnd","current","$isOverflowingY","$expandableContentMaxHeight","tabIndex","Title","_ref7","_excluded4","Body","_ref8","_excluded5","Action","_ref9","_excluded6","DropdownAction","_ref0","_excluded7","Item","item","Actions","_ref1","_excluded8","actionButtons","filter","overlay","node","focus","usingHook","isSelectable","_ref10","Options","map","_ref11","idx","actionButtonProps","key","placement","arrow","_ref12","_excluded9","Dismiss","_ref13","_excluded0","I18n","t","ErrorBanner","_ref14","_excluded1","InfoBanner","_ref15","_excluded10","AttentionBanner","_ref16","_excluded11","ActionBanner","UNSAFE_MiniBanner","MiniBanner","_ref17","_ref17$variant","_excluded12","displayName"],"sources":["../../src/Banner/Banner.tsx"],"sourcesContent":["import {\n Clear,\n EllipsisVertical,\n Error,\n Info,\n Warning,\n} from '@procore/core-icons/dist'\nimport { partition } from 'ramda'\nimport React from 'react'\nimport { Button } from '../Button'\nimport { Card } from '../Card'\nimport { Flex } from '../Flex'\nimport { Menu, useMenu } from '../Menu/Menu'\nimport { OverlayTrigger } from '../OverlayTrigger'\nimport { useI18nContext } from '../_hooks/I18n'\nimport { OverflowObserver } from '../_hooks/OverflowObserver'\nimport { addSubcomponents } from '../_utils/addSubcomponents'\nimport { mergeRefs } from '../_utils/mergeRefs'\nimport type { ButtonAttributes, DivAttributes, Props } from '../_utils/types'\nimport {\n StyledAction,\n StyledActionsTrigger,\n StyledBannerContainer,\n StyledBody,\n StyledContent,\n StyledExpandableContent,\n StyledExpandableContentContainer,\n StyledIconContainer,\n StyledMiniBannerContainer,\n StyledTitle,\n} from './Banner.styles'\nimport type {\n BannerExpandableContentProps,\n BannerIconProps,\n BannerProps,\n BannerVariant,\n} from './Banner.types'\n\nconst defaultIcons: Record<BannerVariant, React.ReactNode> = {\n error: <Error size=\"lg\" />,\n attention: <Warning size=\"lg\" />,\n info: <Info size=\"lg\" />,\n UNSAFE_attention_emphasized: <Warning size=\"lg\" />,\n}\n\nconst Banner_ = React.forwardRef<HTMLDivElement, DivAttributes & BannerProps>(\n function Banner({ children, variant, ...props }, ref) {\n const [expandableContentNodes, content] = partition(\n (element: React.ReactNode) =>\n React.isValidElement(element) && element.type === ExpandableContent,\n React.Children.toArray(children)\n ) as [React.ReactElement[], React.ReactElement[]]\n const isExpandable = expandableContentNodes.length !== 0\n\n const iconElement = React.useMemo(() => {\n return React.Children.toArray(children).find(\n (child) => React.isValidElement(child) && child.type === Icon\n ) as React.ReactElement<BannerIconProps> | undefined\n }, [children])\n\n const hasCustomIcon = iconElement && iconElement.props.icon\n\n return (\n <StyledBannerContainer\n ref={ref}\n $isExpandable={isExpandable}\n $variant={variant}\n {...props}\n >\n {isExpandable ? (\n <>\n <StyledExpandableContentContainer\n justifyContent=\"space-between\"\n alignItems=\"center\"\n gap=\"lg\"\n >\n {!hasCustomIcon && <Icon icon={defaultIcons[variant]} />}\n {content}\n </StyledExpandableContentContainer>\n {expandableContentNodes}\n </>\n ) : (\n <Flex\n justifyContent=\"flex-start\"\n alignItems=\"center\"\n gap=\"lg\"\n grow=\"1\"\n >\n {!hasCustomIcon && <Icon icon={defaultIcons[variant]} />}\n {content}\n </Flex>\n )}\n </StyledBannerContainer>\n )\n }\n)\n\nconst Content = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Content({ children, ...props }, ref) {\n return (\n <StyledContent {...props} ref={ref}>\n {children}\n </StyledContent>\n )\n }\n)\n\nconst ExpandableContent = React.forwardRef<\n HTMLDivElement,\n DivAttributes & BannerExpandableContentProps\n>(function ExpandableContent(\n { children, expanded = false, expandableContentMaxHeight = 120, ...props },\n ref\n) {\n const containerRef = React.useRef<HTMLDivElement>(null)\n\n return expanded ? (\n <OverflowObserver>\n {({ ref: overflowRef, isOverflowingY }) => (\n <StyledExpandableContent\n ref={mergeRefs(ref, containerRef)}\n data-qa=\"core-banner-expandable-content\"\n onAnimationEnd={() => overflowRef(containerRef.current)}\n $isOverflowingY={isOverflowingY}\n $expandableContentMaxHeight={expandableContentMaxHeight}\n {...props}\n {...(isOverflowingY && { tabIndex: 0 })}\n >\n {children}\n </StyledExpandableContent>\n )}\n </OverflowObserver>\n ) : null\n})\n\nconst Title = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Title({ children, ...props }, ref) {\n return (\n <StyledTitle {...props} ref={ref}>\n {children}\n </StyledTitle>\n )\n }\n)\n\nconst Body = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Body({ children, ...props }, ref) {\n return (\n <StyledBody {...props} ref={ref}>\n {children}\n </StyledBody>\n )\n }\n)\n\nconst Action = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function Action({ children, ...props }, ref) {\n return (\n <StyledAction {...props} ref={ref}>\n {children}\n </StyledAction>\n )\n }\n)\n\nconst DropdownAction = React.forwardRef<HTMLDivElement, DivAttributes & Props>(\n function DropdownAction({ children, ...props }, ref) {\n return (\n <Menu.Item ref={ref} item={null} {...(props as any)}>\n {children}\n </Menu.Item>\n )\n }\n)\n\nconst Actions = React.forwardRef<HTMLButtonElement, ButtonAttributes & Props>(\n function Actions({ children, ...props }, ref) {\n const actionButtons = React.Children.toArray(children).filter(\n (element: React.ReactNode) =>\n React.isValidElement(element) && element.type === Action\n ) as React.ReactElement[]\n\n return (\n <OverlayTrigger\n overlay={\n <Card>\n <Menu\n ref={(node) => node?.focus()}\n usingHook={useMenu({\n isSelectable: ({ type }) => type === DropdownAction,\n })}\n >\n <Menu.Options>\n {actionButtons.map(({ props: actionButtonProps }, idx) => (\n <DropdownAction key={idx} {...actionButtonProps} />\n ))}\n </Menu.Options>\n </Menu>\n </Card>\n }\n ref={ref}\n placement=\"bottom-right\"\n >\n <StyledActionsTrigger\n data-qa=\"core-banner-actions-trigger\"\n variant=\"tertiary\"\n arrow={false}\n icon={<EllipsisVertical />}\n {...props}\n />\n </OverlayTrigger>\n )\n }\n)\n\nconst Icon = React.forwardRef<HTMLDivElement, DivAttributes & BannerIconProps>(\n function Icon({ children, icon, ...props }, ref) {\n return (\n <StyledIconContainer ref={ref} aria-hidden=\"true\" {...props}>\n {icon}\n </StyledIconContainer>\n )\n }\n)\n\nconst Dismiss = React.forwardRef<HTMLButtonElement, ButtonAttributes & Props>(\n function Dismiss({ children, ...props }, ref) {\n const I18n = useI18nContext()\n\n return (\n <Button\n aria-label={I18n.t('core.banner.dismissAlert')}\n ref={ref}\n {...props}\n icon={<Clear />}\n variant=\"tertiary\"\n />\n )\n }\n)\n\nexport const ErrorBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props\n>(function ErrorBanner({ children, ...props }, ref) {\n return (\n <Banner ref={ref} variant=\"error\" {...props}>\n <Icon icon={<Error size=\"lg\" />} />\n {children}\n </Banner>\n )\n})\n\nexport const InfoBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props\n>(function InfoBanner({ children, ...props }, ref) {\n return (\n <Banner ref={ref} variant=\"info\" {...props}>\n <Icon icon={<Info size=\"lg\" />} />\n {children}\n </Banner>\n )\n})\n\n/**\n * @since 11.26.0\n */\nexport const AttentionBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props\n>(function AttentionBanner({ children, ...props }, ref) {\n return (\n <Banner ref={ref} variant=\"attention\" {...props}>\n <Icon icon={<Warning size=\"lg\" />} />\n {children}\n </Banner>\n )\n})\n/**\n * @deprecated ActionBanner was renamed to AttentionBanner.\n * @deprecatedSince 11.26.0\n */\nexport const ActionBanner = AttentionBanner\n\nexport const UNSAFE_MiniBanner = React.forwardRef<\n HTMLDivElement,\n DivAttributes & Props & { variant?: BannerVariant }\n>(function MiniBanner({ children, variant = 'info', ...props }, ref) {\n return (\n <StyledMiniBannerContainer ref={ref} variant={variant} {...props}>\n {children}\n </StyledMiniBannerContainer>\n )\n})\n\nBanner_.displayName = 'Banner'\n\nBody.displayName = 'Banner.Body'\n\nContent.displayName = 'Banner.Content'\n\nExpandableContent.displayName = 'Banner.ExpandableContent'\n\nTitle.displayName = 'Banner.Title'\n\nAction.displayName = 'Banner.Action'\n\nActions.displayName = 'Banner.Actions'\n\nDropdownAction.displayName = 'Banner.DropdownAction'\n\nIcon.displayName = 'Banner.Icon'\n\nDismiss.displayName = 'Banner.Dismiss'\n\nErrorBanner.displayName = 'ErrorBanner'\n\nInfoBanner.displayName = 'InfoBanner'\n\nAttentionBanner.displayName = 'AttentionBanner'\n\nActionBanner.displayName = 'ActionBanner'\n\nUNSAFE_MiniBanner.displayName = 'MiniBanner'\n\n/**\n\n\n We use banners to contextually convey complicated or supplemental information\n to a user. Depending on the type of banner, we can provide more information\n about a feature or page the user is on, an action the user needs to perform,\n or an error the user has encountered.\n\n Procore banners are informative and actionable. Always explain what the user\n needs to know (and in some cases, why they’re seeing the banner), and provide\n an actionable next step.\n\n @since 10.19.0\n\n @see [Storybook](https://stories.core.procore.com/?path=/story/core-react_demos-banner--demo)\n\n @see [Design Guidelines](https://design.procore.com/banner)\n\n */\nexport const Banner = addSubcomponents(\n {\n Body,\n Content,\n ExpandableContent,\n Title,\n Action,\n Actions,\n Icon,\n Dismiss,\n },\n Banner_\n)\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA,SACEA,KAAK,EACLC,gBAAgB,EAChBC,KAAK,EACLC,IAAI,EACJC,OAAO,QACF,0BAA0B;AACjC,SAASC,SAAS,QAAQ,OAAO;AACjC,OAAOC,KAAK,MAAM,OAAO;AACzB,SAASC,MAA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iB,EAAjBA,iBAAiB;EACjB2C,KAAK,EAALA,KAAK;EACLM,MAAM,EAANA,MAAM;EACNQ,OAAO,EAAPA,OAAO;EACP5C,IAAI,EAAJA,IAAI;EACJiE,OAAO,EAAPA;AACF,CAAC,EACD5F,OACF,CAAC"}
@@ -1,20 +1,29 @@
1
1
  /// <reference types="react" />
2
2
  import type { FlexProps } from '../Flex';
3
3
  import type { BannerProps, BannerVariant } from './Banner.types';
4
- export declare const StyledBannerContainer: import("styled-components").StyledComponent<"div", any, {
4
+ declare type StyledBannerContainerProps = {
5
5
  $isExpandable: boolean;
6
- } & BannerProps, never>;
7
- export declare const StyledContent: import("styled-components").StyledComponent<"div", any, {}, never>;
8
- export declare const StyledExpandableContentContainer: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("..").DivAttributes & FlexProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
9
- export declare const StyledExpandableContent: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("..").DivAttributes & FlexProps & import("react").RefAttributes<HTMLDivElement>>, any, FlexProps & {
6
+ $variant: BannerProps['variant'];
7
+ } & Omit<BannerProps, 'variant'>;
8
+ export declare const StyledBannerContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, StyledBannerContainerProps>> & string;
9
+ export declare const StyledContent: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
10
+ export declare const StyledExpandableContentContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<Omit<import("..").DivAttributes & FlexProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & {
11
+ ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
12
+ }, never>> & string & Omit<import("react").ForwardRefExoticComponent<import("..").DivAttributes & FlexProps & import("react").RefAttributes<HTMLDivElement>>, keyof import("react").Component<any, {}, any>>;
13
+ export declare const StyledExpandableContent: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<Omit<import("..").DivAttributes & FlexProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & {
14
+ ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
15
+ }, FlexProps & {
10
16
  $isOverflowingY: boolean;
11
17
  $expandableContentMaxHeight: number;
12
- }, never>;
13
- export declare const StyledTitle: import("styled-components").StyledComponent<"div", any, {}, never>;
14
- export declare const StyledBody: import("styled-components").StyledComponent<"div", any, {}, never>;
15
- export declare const StyledIconContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
16
- export declare const StyledActionsTrigger: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("../Dropdown/Dropdown.types").DropdownButtonProps & import("react").RefAttributes<HTMLButtonElement>>, any, {}, never>;
17
- export declare const StyledAction: import("styled-components").StyledComponent<"div", any, {}, never>;
18
- export declare const StyledMiniBannerContainer: import("styled-components").StyledComponent<"div", any, {
18
+ }>> & string & Omit<import("react").ForwardRefExoticComponent<import("..").DivAttributes & FlexProps & import("react").RefAttributes<HTMLDivElement>>, keyof import("react").Component<any, {}, any>>;
19
+ export declare const StyledTitle: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
20
+ export declare const StyledBody: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
21
+ export declare const StyledIconContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
22
+ export declare const StyledActionsTrigger: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<Omit<import("../Dropdown/Dropdown.types").DropdownButtonProps & import("react").RefAttributes<HTMLButtonElement>, "ref"> & {
23
+ ref?: ((instance: HTMLButtonElement | null) => void) | import("react").RefObject<HTMLButtonElement> | null | undefined;
24
+ }, never>> & string & Omit<import("react").ForwardRefExoticComponent<import("../Dropdown/Dropdown.types").DropdownButtonProps & import("react").RefAttributes<HTMLButtonElement>>, keyof import("react").Component<any, {}, any>>;
25
+ export declare const StyledAction: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
26
+ export declare const StyledMiniBannerContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
19
27
  variant: BannerVariant;
20
- }, never>;
28
+ }>> & string;
29
+ export {};
@@ -39,10 +39,10 @@ var expandContent = function expandContent(maxHeight) {
39
39
  };
40
40
  export var StyledBannerContainer = /*#__PURE__*/styled.div.withConfig({
41
41
  displayName: "StyledBannerContainer",
42
- componentId: "core-12_21_2__sc-149wm7c-0"
42
+ componentId: "core-12_23_0__sc-149wm7c-0"
43
43
  })(["align-items:center;border-left:", "px solid;border-radius:", "px;color:", ";display:flex;justify-content:space-between;min-height:52px;padding:0 ", "px;", " ", " ", ""], bannerLeft, borderRadius.md, colors.gray15, spacing.lg, bannerShadow, function (_ref) {
44
- var variant = _ref.variant;
45
- var _bannerVariantColors$ = bannerVariantColors[variant],
44
+ var $variant = _ref.$variant;
45
+ var _bannerVariantColors$ = bannerVariantColors[$variant],
46
46
  primary = _bannerVariantColors$.primary,
47
47
  secondary = _bannerVariantColors$.secondary;
48
48
  return css(["border-left-color:", ";background-color:", ";& ", "{color:", ";}"], primary, secondary, StyledIconContainer, primary);
@@ -52,15 +52,15 @@ export var StyledBannerContainer = /*#__PURE__*/styled.div.withConfig({
52
52
  });
53
53
  export var StyledContent = /*#__PURE__*/styled.div.withConfig({
54
54
  displayName: "StyledContent",
55
- componentId: "core-12_21_2__sc-149wm7c-1"
55
+ componentId: "core-12_23_0__sc-149wm7c-1"
56
56
  })(["align-self:center;margin:", "px ", "px ", "px 0;width:100%;"], spacing.sm, spacing.lg, spacing.sm);
57
57
  export var StyledExpandableContentContainer = /*#__PURE__*/styled(Flex).withConfig({
58
58
  displayName: "StyledExpandableContentContainer",
59
- componentId: "core-12_21_2__sc-149wm7c-2"
59
+ componentId: "core-12_23_0__sc-149wm7c-2"
60
60
  })(["color:", ";min-height:52px;padding:0 ", "px;position:relative;z-index:1;", ""], colors.gray15, spacing.lg, bannerShadow);
61
61
  export var StyledExpandableContent = /*#__PURE__*/styled(Flex).withConfig({
62
62
  displayName: "StyledExpandableContent",
63
- componentId: "core-12_21_2__sc-149wm7c-3"
63
+ componentId: "core-12_23_0__sc-149wm7c-3"
64
64
  })(["animation-duration:450ms;animation-fill-mode:forwards;animation-timing-function:ease-out;background-color:", ";box-sizing:border-box;font-size:14px;font-weight:500;letter-spacing:0.25px;line-height:20px;overflow-y:auto;padding:0 ", "px;position:relative;z-index:0;", " ", ""], colors.white, spacing.xl * 2 + spacing.sm, function (_ref3) {
65
65
  var $isOverflowingY = _ref3.$isOverflowingY;
66
66
  return $isOverflowingY && focusable;
@@ -70,23 +70,23 @@ export var StyledExpandableContent = /*#__PURE__*/styled(Flex).withConfig({
70
70
  });
71
71
  export var StyledTitle = /*#__PURE__*/styled.div.withConfig({
72
72
  displayName: "StyledTitle",
73
- componentId: "core-12_21_2__sc-149wm7c-4"
73
+ componentId: "core-12_23_0__sc-149wm7c-4"
74
74
  })(["", " color:", ";font-weight:", ";"], getTypographyIntent('body'), colors.gray15, typographyWeights.semibold);
75
75
  export var StyledBody = /*#__PURE__*/styled.div.withConfig({
76
76
  displayName: "StyledBody",
77
- componentId: "core-12_21_2__sc-149wm7c-5"
77
+ componentId: "core-12_23_0__sc-149wm7c-5"
78
78
  })(["", " color:", ";"], getTypographyIntent('body'), colors.gray15);
79
79
  export var StyledIconContainer = /*#__PURE__*/styled.div.withConfig({
80
80
  displayName: "StyledIconContainer",
81
- componentId: "core-12_21_2__sc-149wm7c-6"
81
+ componentId: "core-12_23_0__sc-149wm7c-6"
82
82
  })(["flex:0 0 auto;margin:", "px 0;"], spacing.lg);
83
83
  export var StyledActionsTrigger = /*#__PURE__*/styled(DropdownButton).withConfig({
84
84
  displayName: "StyledActionsTrigger",
85
- componentId: "core-12_21_2__sc-149wm7c-7"
85
+ componentId: "core-12_23_0__sc-149wm7c-7"
86
86
  })(["flex-shrink:0;& + ", ",& + ", "{margin-left:-", "px;}"], StyledButton, StyledLinkButton, spacing.sm);
87
87
  export var StyledAction = /*#__PURE__*/styled.div.withConfig({
88
88
  displayName: "StyledAction",
89
- componentId: "core-12_21_2__sc-149wm7c-8"
89
+ componentId: "core-12_23_0__sc-149wm7c-8"
90
90
  })(["margin:", "px 0 ", "px -", "px;& + ", ",& + ", ",& + ", "{margin-left:-", "px;}", ",", "{background:rgba(0,0,0,0.05);color:", ";&:hover{background:", ";color:", ";}}"], spacing.sm, spacing.sm, spacing.sm, StyledButton, StyledLinkButton, StyledActionsTrigger, spacing.sm, StyledButton, StyledLinkButton, colors.gray15, colors.gray85, colors.gray15);
91
91
  function getMiniBannerIconColor(_ref5) {
92
92
  var variant = _ref5.variant;
@@ -94,6 +94,6 @@ function getMiniBannerIconColor(_ref5) {
94
94
  }
95
95
  export var StyledMiniBannerContainer = /*#__PURE__*/styled.div.withConfig({
96
96
  displayName: "StyledMiniBannerContainer",
97
- componentId: "core-12_21_2__sc-149wm7c-9"
97
+ componentId: "core-12_23_0__sc-149wm7c-9"
98
98
  })(["align-items:center;background-color:", ";display:flex;justify-content:space-between;padding:0 ", "px;", " ", " & ", "{margin:", "px;}"], colors.gray96, spacing.md, getTypographyIntent('small'), getMiniBannerIconColor, StyledContent, spacing.sm);
99
99
  //# sourceMappingURL=Banner.styles.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Banner.styles.js","names":["styled","css","keyframes","StyledButton","StyledLinkButton","DropdownButton","Flex","getTypographyIntent","typographyWeights","borderRadius","colors","focusable","getShadow","spacing","bannerLeft","bannerVariantColors","attention","primary","yellow40","secondary","yellow94","error","red50","red98","info","blue50","blue96","UNSAFE_attention_emphasized","orange50","orange98","miniBannerVariantColors","yellow50","green50","bannerShadow","expandContent","maxHeight","sm","StyledBannerContainer","div","withConfig","displayName","componentId","md","gray15","lg","_ref","variant","_bannerVariantColors$","StyledIconContainer","_ref2","$isExpandable","StyledContent","StyledExpandableContentContainer","StyledExpandableContent","white","xl","_ref3","$isOverflowingY","_ref4","$expandableContentMaxHeight","StyledTitle","semibold","StyledBody","StyledActionsTrigger","StyledAction","gray85","getMiniBannerIconColor","_ref5","StyledMiniBannerContainer","gray96"],"sources":["../../src/Banner/Banner.styles.ts"],"sourcesContent":["import styled, { css, keyframes } from 'styled-components'\nimport { StyledButton, StyledLinkButton } from '../Button/Button.styles'\nimport { DropdownButton } from '../Dropdown/Dropdown'\nimport type { FlexProps } from '../Flex'\nimport { Flex } from '../Flex'\nimport { getTypographyIntent, typographyWeights } from '../Typography'\nimport { borderRadius } from '../_styles/borderRadius'\nimport { colors } from '../_styles/colors'\nimport { focusable } from '../_styles/mixins'\nimport { getShadow } from '../_styles/shadows'\nimport { spacing } from '../_styles/spacing'\nimport type { BannerProps, BannerVariant } from './Banner.types'\n\nconst bannerLeft = 8\n\nconst bannerVariantColors = {\n attention: {\n primary: colors.yellow40,\n secondary: colors.yellow94,\n },\n error: {\n primary: colors.red50,\n secondary: colors.red98,\n },\n info: {\n primary: colors.blue50,\n secondary: colors.blue96,\n },\n UNSAFE_attention_emphasized: {\n primary: colors.orange50,\n secondary: colors.orange98,\n },\n} as const\n\nconst miniBannerVariantColors = {\n attention: colors.yellow50,\n error: colors.red50,\n info: colors.blue50,\n UNSAFE_attention_emphasized: colors.green50,\n}\n\nconst bannerShadow = getShadow(1, 'bottom')\n\nconst expandContent = (maxHeight: number) => keyframes`\n from {\n padding-top: 0;\n padding-bottom: 0;\n max-height: 0;\n min-height: 0;\n overflow-y: hidden;\n }\n to {\n padding-top: ${spacing.sm}px;\n padding-bottom: ${spacing.sm}px;\n min-height: 32px;\n max-height: ${maxHeight}px;\n overflow-y: auto;\n }\n`\n\nexport const StyledBannerContainer = styled.div<\n { $isExpandable: boolean } & BannerProps\n>`\n align-items: center;\n border-left: ${bannerLeft}px solid;\n border-radius: ${borderRadius.md}px;\n color: ${colors.gray15};\n display: flex;\n justify-content: space-between;\n min-height: 52px;\n padding: 0 ${spacing.lg}px;\n\n ${bannerShadow}\n\n ${({ variant }) => {\n const { primary, secondary } = bannerVariantColors[variant]\n\n return css`\n border-left-color: ${primary};\n background-color: ${secondary};\n\n & ${StyledIconContainer} {\n color: ${primary};\n }\n `\n }}\n\n ${({ $isExpandable }) =>\n $isExpandable &&\n css`\n flex-direction: column;\n align-items: stretch;\n padding: 0;\n `}\n`\n\nexport const StyledContent = styled.div`\n align-self: center;\n margin: ${spacing.sm}px ${spacing.lg}px ${spacing.sm}px 0;\n width: 100%;\n`\n\nexport const StyledExpandableContentContainer = styled(Flex)`\n color: ${colors.gray15};\n min-height: 52px;\n padding: 0 ${spacing.lg}px;\n position: relative;\n z-index: 1;\n\n ${bannerShadow}\n`\n\nexport const StyledExpandableContent = styled(Flex)<\n FlexProps & { $isOverflowingY: boolean; $expandableContentMaxHeight: number }\n>`\n animation-duration: 450ms;\n animation-fill-mode: forwards;\n animation-timing-function: ease-out;\n background-color: ${colors.white};\n box-sizing: border-box;\n font-size: 14px;\n font-weight: 500;\n letter-spacing: 0.25px;\n line-height: 20px;\n overflow-y: auto;\n padding: 0 ${spacing.xl * 2 + spacing.sm}px;\n position: relative;\n z-index: 0;\n\n ${({ $isOverflowingY }) => $isOverflowingY && focusable}\n ${({ $expandableContentMaxHeight }) =>\n css`\n animation-name: ${expandContent($expandableContentMaxHeight)};\n `}\n`\n\nexport const StyledTitle = styled.div`\n ${getTypographyIntent('body')}\n color: ${colors.gray15};\n font-weight: ${typographyWeights.semibold};\n`\n\nexport const StyledBody = styled.div`\n ${getTypographyIntent('body')}\n color: ${colors.gray15};\n`\n\nexport const StyledIconContainer = styled.div`\n flex: 0 0 auto;\n margin: ${spacing.lg}px 0;\n`\n\nexport const StyledActionsTrigger = styled(DropdownButton)`\n flex-shrink: 0;\n\n & + ${StyledButton}, & + ${StyledLinkButton} {\n margin-left: -${spacing.sm}px;\n }\n`\n\nexport const StyledAction = styled.div`\n margin: ${spacing.sm}px 0 ${spacing.sm}px -${spacing.sm}px;\n\n & + ${StyledButton}, & + ${StyledLinkButton}, & + ${StyledActionsTrigger} {\n margin-left: -${spacing.sm}px;\n }\n\n ${StyledButton}, ${StyledLinkButton} {\n background: rgba(0, 0, 0, 0.05);\n color: ${colors.gray15};\n\n &:hover {\n background: ${colors.gray85};\n color: ${colors.gray15};\n }\n }\n`\n\nfunction getMiniBannerIconColor({ variant }: { variant: BannerVariant }) {\n return css`\n & ${StyledIconContainer} {\n color: ${miniBannerVariantColors[variant]};\n }\n `\n}\n\nexport const StyledMiniBannerContainer = styled.div<{\n variant: BannerVariant\n}>`\n align-items: center;\n background-color: ${colors.gray96};\n display: flex;\n justify-content: space-between;\n padding: 0 ${spacing.md}px;\n\n ${getTypographyIntent('small')}\n\n ${getMiniBannerIconColor}\n\n & ${StyledContent} {\n margin: ${spacing.sm}px;\n }\n`\n"],"mappings":"AAAA,OAAOA,MAAM,IAAIC,GAAG,EAAEC,SAAS,QAAQ,mBAAmB;AAC1D,SAASC,YAAY,EAAEC,gBAAgB,QAAQ,yBAAyB;AACxE,SAASC,cAAc,QAAQ,sBAAsB;AAErD,SAASC,IAAI,QAAQ,SAAS;AAC9B,SAASC,mBAAmB,EAAEC,iBAAiB,QAAQ,eAAe;AACtE,SAASC,YAAY,QAAQ,yBAAyB;A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,mBAAmB,EACZlB,uBAAuB,CAACgB,OAAO,CAAC;AAG/C;AAEA,OAAO,IAAMsB,yBAAyB,gBAAGpE,MAAM,CAACsC,GAAG,CAAAC,UAAA;EAAAC,WAAA;EAAAC,WAAA;AAAA,8IAI7B/B,MAAM,CAAC2D,MAAM,EAGpBxD,OAAO,CAAC6B,EAAE,EAErBnC,mBAAmB,CAAC,OAAO,CAAC,EAE5B2D,sBAAsB,EAEpBf,aAAa,EACLtC,OAAO,CAACuB,EAAE,CAEvB"}
1
+ {"version":3,"file":"Banner.styles.js","names":["styled","css","keyframes","StyledButton","StyledLinkButton","DropdownButton","Flex","getTypographyIntent","typographyWeights","borderRadius","colors","focusable","getShadow","spacing","bannerLeft","bannerVariantColors","attention","primary","yellow40","secondary","yellow94","error","red50","red98","info","blue50","blue96","UNSAFE_attention_emphasized","orange50","orange98","miniBannerVariantColors","yellow50","green50","bannerShadow","expandContent","maxHeight","sm","StyledBannerContainer","div","withConfig","displayName","componentId","md","gray15","lg","_ref","$variant","_bannerVariantColors$","StyledIconContainer","_ref2","$isExpandable","StyledContent","StyledExpandableContentContainer","StyledExpandableContent","white","xl","_ref3","$isOverflowingY","_ref4","$expandableContentMaxHeight","StyledTitle","semibold","StyledBody","StyledActionsTrigger","StyledAction","gray85","getMiniBannerIconColor","_ref5","variant","StyledMiniBannerContainer","gray96"],"sources":["../../src/Banner/Banner.styles.ts"],"sourcesContent":["import styled, { css, keyframes } from 'styled-components'\nimport { StyledButton, StyledLinkButton } from '../Button/Button.styles'\nimport { DropdownButton } from '../Dropdown/Dropdown'\nimport type { FlexProps } from '../Flex'\nimport { Flex } from '../Flex'\nimport { getTypographyIntent, typographyWeights } from '../Typography'\nimport { borderRadius } from '../_styles/borderRadius'\nimport { colors } from '../_styles/colors'\nimport { focusable } from '../_styles/mixins'\nimport { getShadow } from '../_styles/shadows'\nimport { spacing } from '../_styles/spacing'\nimport type { BannerProps, BannerVariant } from './Banner.types'\n\ntype StyledBannerContainerProps = {\n $isExpandable: boolean\n $variant: BannerProps['variant']\n} & Omit<BannerProps, 'variant'>\n\nconst bannerLeft = 8\n\nconst bannerVariantColors = {\n attention: {\n primary: colors.yellow40,\n secondary: colors.yellow94,\n },\n error: {\n primary: colors.red50,\n secondary: colors.red98,\n },\n info: {\n primary: colors.blue50,\n secondary: colors.blue96,\n },\n UNSAFE_attention_emphasized: {\n primary: colors.orange50,\n secondary: colors.orange98,\n },\n} as const\n\nconst miniBannerVariantColors = {\n attention: colors.yellow50,\n error: colors.red50,\n info: colors.blue50,\n UNSAFE_attention_emphasized: colors.green50,\n}\n\nconst bannerShadow = getShadow(1, 'bottom')\n\nconst expandContent = (maxHeight: number) => keyframes`\n from {\n padding-top: 0;\n padding-bottom: 0;\n max-height: 0;\n min-height: 0;\n overflow-y: hidden;\n }\n to {\n padding-top: ${spacing.sm}px;\n padding-bottom: ${spacing.sm}px;\n min-height: 32px;\n max-height: ${maxHeight}px;\n overflow-y: auto;\n }\n`\n\nexport const StyledBannerContainer = styled.div<StyledBannerContainerProps>`\n align-items: center;\n border-left: ${bannerLeft}px solid;\n border-radius: ${borderRadius.md}px;\n color: ${colors.gray15};\n display: flex;\n justify-content: space-between;\n min-height: 52px;\n padding: 0 ${spacing.lg}px;\n\n ${bannerShadow}\n\n ${({ $variant }) => {\n const { primary, secondary } = bannerVariantColors[$variant]\n\n return css`\n border-left-color: ${primary};\n background-color: ${secondary};\n\n & ${StyledIconContainer} {\n color: ${primary};\n }\n `\n }}\n\n ${({ $isExpandable }) =>\n $isExpandable &&\n css`\n flex-direction: column;\n align-items: stretch;\n padding: 0;\n `}\n`\n\nexport const StyledContent = styled.div`\n align-self: center;\n margin: ${spacing.sm}px ${spacing.lg}px ${spacing.sm}px 0;\n width: 100%;\n`\n\nexport const StyledExpandableContentContainer = styled(Flex)`\n color: ${colors.gray15};\n min-height: 52px;\n padding: 0 ${spacing.lg}px;\n position: relative;\n z-index: 1;\n\n ${bannerShadow}\n`\n\nexport const StyledExpandableContent = styled(Flex)<\n FlexProps & { $isOverflowingY: boolean; $expandableContentMaxHeight: number }\n>`\n animation-duration: 450ms;\n animation-fill-mode: forwards;\n animation-timing-function: ease-out;\n background-color: ${colors.white};\n box-sizing: border-box;\n font-size: 14px;\n font-weight: 500;\n letter-spacing: 0.25px;\n line-height: 20px;\n overflow-y: auto;\n padding: 0 ${spacing.xl * 2 + spacing.sm}px;\n position: relative;\n z-index: 0;\n\n ${({ $isOverflowingY }) => $isOverflowingY && focusable}\n ${({ $expandableContentMaxHeight }) =>\n css`\n animation-name: ${expandContent($expandableContentMaxHeight)};\n `}\n`\n\nexport const StyledTitle = styled.div`\n ${getTypographyIntent('body')}\n color: ${colors.gray15};\n font-weight: ${typographyWeights.semibold};\n`\n\nexport const StyledBody = styled.div`\n ${getTypographyIntent('body')}\n color: ${colors.gray15};\n`\n\nexport const StyledIconContainer = styled.div`\n flex: 0 0 auto;\n margin: ${spacing.lg}px 0;\n`\n\nexport const StyledActionsTrigger = styled(DropdownButton)`\n flex-shrink: 0;\n\n & + ${StyledButton}, & + ${StyledLinkButton} {\n margin-left: -${spacing.sm}px;\n }\n`\n\nexport const StyledAction = styled.div`\n margin: ${spacing.sm}px 0 ${spacing.sm}px -${spacing.sm}px;\n\n & + ${StyledButton}, & + ${StyledLinkButton}, & + ${StyledActionsTrigger} {\n margin-left: -${spacing.sm}px;\n }\n\n ${StyledButton}, ${StyledLinkButton} {\n background: rgba(0, 0, 0, 0.05);\n color: ${colors.gray15};\n\n &:hover {\n background: ${colors.gray85};\n color: ${colors.gray15};\n }\n }\n`\n\nfunction getMiniBannerIconColor({ variant }: { variant: BannerVariant }) {\n return css`\n & ${StyledIconContainer} {\n color: ${miniBannerVariantColors[variant]};\n }\n `\n}\n\nexport const StyledMiniBannerContainer = styled.div<{\n variant: BannerVariant\n}>`\n align-items: center;\n background-color: ${colors.gray96};\n display: flex;\n justify-content: space-between;\n padding: 0 ${spacing.md}px;\n\n ${getTypographyIntent('small')}\n\n ${getMini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CAACuB,EAAE,EAEjDjC,YAAY,EAASC,gBAAgB,EAAS2D,oBAAoB,EACtDlD,OAAO,CAACuB,EAAE,EAG1BjC,YAAY,EAAKC,gBAAgB,EAExBM,MAAM,CAACiC,MAAM,EAGNjC,MAAM,CAACuD,MAAM,EAClBvD,MAAM,CAACiC,MAAM,CAG3B;AAED,SAASuB,sBAAsBA,CAAAC,KAAA,EAA0C;EAAA,IAAvCC,OAAO,GAAAD,KAAA,CAAPC,OAAO;EACvC,OAAOnE,GAAG,0BACJ+C,mBAAmB,EACZlB,uBAAuB,CAACsC,OAAO,CAAC;AAG/C;AAEA,OAAO,IAAMC,yBAAyB,gBAAGrE,MAAM,CAACsC,GAAG,CAAAC,UAAA;EAAAC,WAAA;EAAAC,WAAA;AAAA,8IAI7B/B,MAAM,CAAC4D,MAAM,EAGpBzD,OAAO,CAAC6B,EAAE,EAErBnC,mBAAmB,CAAC,OAAO,CAAC,EAE5B2D,sBAAsB,EAEpBf,aAAa,EACLtC,OAAO,CAACuB,EAAE,CAEvB"}
package/dist/Box/Box.js CHANGED
@@ -67,7 +67,7 @@ export var Box = /*#__PURE__*/React.forwardRef(function Box(_ref, ref) {
67
67
  var legacyProps = getLegacyDisplayAndDirection(display);
68
68
  return /*#__PURE__*/React.createElement(StyledBox, _extends({}, props, {
69
69
  ref: ref,
70
- $as: as,
70
+ as: as,
71
71
  $alignContent: alignContent,
72
72
  $alignItems: alignItems,
73
73
  $alignSelf: alignSelf,
@@ -1 +1 @@
1
- {"version":3,"file":"Box.js","names":["React","StyledBox","getLegacyDisplayAndDirection","d","display","direction","includes","undefined","Box","forwardRef","_ref","ref","as","alignContent","alignItems","alignSelf","children","flex","flexBasis","flexDirection","flexGrow","flexShrink","flexWrap","gap","justifyContent","margin","marginBottom","marginLeft","marginRight","marginTop","order","padding","paddingBottom","paddingLeft","paddingRight","paddingTop","textAlign","props","_objectWithoutProperties","_excluded","legacyProps","createElement","_extends","$as","$alignContent","$alignItems","$alignSelf","$display","$flex","$flexBasis","$flexDirection","$flexGrow","$flexShrink","$flexWrap","$gap","$justifyContent","$margin","$marginBottom","$marginLeft","$marginRight","$marginTop","$order","$padding","$paddingBottom","$paddingLeft","$paddingRight","$paddingTop","$textAlign","displayName"],"sources":["../../src/Box/Box.tsx"],"sourcesContent":["import * as React from 'react'\nimport type { DivAttributes } from '../_utils/types'\nimport { StyledBox } from './Box.styles'\nimport type { BoxProps, Display, FlexDirection } from './Box.types'\n\n// TODO remove this after we decommission the LegacyDisplay type\nfunction getLegacyDisplayAndDirection(d?: Display) {\n if (!d) {\n return {}\n }\n\n let display = d\n\n let direction: FlexDirection | undefined = display.includes('flex')\n ? 'row'\n : undefined\n\n if (d.includes('flex-inline') || d.includes('inline-flex')) {\n display = 'inline-flex'\n } else if (d.includes('flex')) {\n display = 'flex'\n }\n\n if (d.includes('column-reverse')) {\n direction = 'column-reverse'\n } else if (d.includes('column')) {\n direction = 'column'\n }\n\n if (d.includes('row-reverse')) {\n direction = 'row-reverse'\n } else if (d.includes('row')) {\n direction = 'row'\n }\n\n return {\n display,\n direction,\n }\n}\n\n/**\n * `Box` is a general layout utility for CSS properties like `display`, `text-align`,\n * flex, spacing, and layout properties.\n */\nexport const Box = React.forwardRef<HTMLDivElement, DivAttributes & BoxProps>(\n function Box(\n {\n as,\n alignContent,\n alignItems,\n alignSelf,\n children,\n display,\n flex,\n flexBasis,\n flexDirection,\n flexGrow,\n flexShrink,\n flexWrap,\n gap,\n justifyContent,\n margin,\n marginBottom,\n marginLeft,\n marginRight,\n marginTop,\n order,\n padding,\n paddingBottom,\n paddingLeft,\n paddingRight,\n paddingTop,\n textAlign,\n ...props\n },\n ref\n ) {\n const legacyProps = getLegacyDisplayAndDirection(display)\n\n return (\n <StyledBox\n {...props}\n ref={ref}\n $as={as}\n $alignContent={alignContent}\n $alignItems={alignItems}\n $alignSelf={alignSelf}\n $display={legacyProps.display}\n $flex={flex}\n $flexBasis={flexBasis}\n $flexDirection={flexDirection ?? legacyProps.direction}\n $flexGrow={flexGrow}\n $flexShrink={flexShrink}\n $flexWrap={flexWrap}\n $gap={gap}\n $justifyContent={justifyContent}\n $margin={margin}\n $marginBottom={marginBottom}\n $marginLeft={marginLeft}\n $marginRight={marginRight}\n $marginTop={marginTop}\n $order={order}\n $padding={padding}\n $paddingBottom={paddingBottom}\n $paddingLeft={paddingLeft}\n $paddingRight={paddingRight}\n $paddingTop={paddingTop}\n $textAlign={textAlign}\n >\n {children}\n </StyledBox>\n )\n }\n)\n\nBox.displayName = 'Box'\n"],"mappings":";;;;AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAE9B,SAASC,SAAS,QAAQ,cAAc;AAGxC;AACA,SAASC,4BAA4BA,CAACC,CAAW,EAAE;EACjD,IAAI,CAACA,CAAC,EAAE;IACN,OAAO,CAAC,CAAC;EACX;EAEA,IAAIC,OAAO,GAAGD,CAAC;EAEf,IAAIE,SAAoC,GAAGD,OAAO,CAACE,QAAQ,CAAC,MAAM,CAAC,GAC/D,KAAK,GACLC,SAAS;EAEb,IAAIJ,CAAC,CAACG,QAAQ,CAAC,aAAa,CAAC,IAAIH,CAAC,CAACG,QAAQ,CAAC,aAAa,CAAC,EAAE;IAC1DF,OAAO,GAAG,aAAa;EACzB,CAAC,MAAM,IAAID,CAAC,CAACG,QAAQ,CAAC,MAAM,CAAC,EAAE;IAC7BF,OAAO,GAAG,MAAM;EAClB;EAEA,IAAID,CAAC,CAACG,QAAQ,CAAC,gBAAgB,CAAC,EAAE;IAChCD,SAAS,GAAG,gBAAgB;EAC9B,CAAC,MAAM,IAAIF,CAAC,CAACG,QAAQ,CAAC,QAAQ,CAAC,EAAE;IAC/BD,SAAS,GAAG,QAAQ;EACtB;EAEA,IAAIF,CAAC,CAACG,QAAQ,CAAC,aAAa,CAAC,EAAE;IAC7BD,SAAS,GAAG,aAAa;EAC3B,CAAC,MAAM,IAAIF,CAAC,CAACG,QAAQ,CAAC,KAAK,CAAC,EAAE;IAC5BD,SAAS,GAAG,KA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,SAAS;IACNC,KAAK,GAAAC,wBAAA,CAAA5B,IAAA,EAAA6B,SAAA;EAIV,IAAMC,WAAW,GAAGtC,4BAA4B,CAACE,OAAO,CAAC;EAEzD,oBACEJ,KAAA,CAAAyC,aAAA,CAACxC,SAAS,EAAAyC,QAAA,KACJL,KAAK;IACT1B,GAAG,EAAEA,GAAI;IACTgC,GAAG,EAAE/B,EAAG;IACRgC,aAAa,EAAE/B,YAAa;IAC5BgC,WAAW,EAAE/B,UAAW;IACxBgC,UAAU,EAAE/B,SAAU;IACtBgC,QAAQ,EAAEP,WAAW,CAACpC,OAAQ;IAC9B4C,KAAK,EAAE/B,IAAK;IACZgC,UAAU,EAAE/B,SAAU;IACtBgC,cAAc,EAAE/B,aAAa,aAAbA,aAAa,cAAbA,aAAa,GAAIqB,WAAW,CAACnC,SAAU;IACvD8C,SAAS,EAAE/B,QAAS;IACpBgC,WAAW,EAAE/B,UAAW;IACxBgC,SAAS,EAAE/B,QAAS;IACpBgC,IAAI,EAAE/B,GAAI;IACVgC,eAAe,EAAE/B,cAAe;IAChCgC,OAAO,EAAE/B,MAAO;IAChBgC,aAAa,EAAE/B,YAAa;IAC5BgC,WAAW,EAAE/B,UAAW;IACxBgC,YAAY,EAAE/B,WAAY;IAC1BgC,UAAU,EAAE/B,SAAU;IACtBgC,MAAM,EAAE/B,KAAM;IACdgC,QAAQ,EAAE/B,OAAQ;IAClBgC,cAAc,EAAE/B,aAAc;IAC9BgC,YAAY,EAAE/B,WAAY;IAC1BgC,aAAa,EAAE/B,YAAa;IAC5BgC,WAAW,EAAE/B,UAAW;IACxBgC,UAAU,EAAE/B;EAAU,IAErBpB,QACQ,CAAC;AAEhB,CACF,CAAC;AAEDR,GAAG,CAAC4D,WAAW,GAAG,KAAK"}
1
+ {"version":3,"file":"Box.js","names":["React","StyledBox","getLegacyDisplayAndDirection","d","display","direction","includes","undefined","Box","forwardRef","_ref","ref","as","alignContent","alignItems","alignSelf","children","flex","flexBasis","flexDirection","flexGrow","flexShrink","flexWrap","gap","justifyContent","margin","marginBottom","marginLeft","marginRight","marginTop","order","padding","paddingBottom","paddingLeft","paddingRight","paddingTop","textAlign","props","_objectWithoutProperties","_excluded","legacyProps","createElement","_extends","$alignContent","$alignItems","$alignSelf","$display","$flex","$flexBasis","$flexDirection","$flexGrow","$flexShrink","$flexWrap","$gap","$justifyContent","$margin","$marginBottom","$marginLeft","$marginRight","$marginTop","$order","$padding","$paddingBottom","$paddingLeft","$paddingRight","$paddingTop","$textAlign","displayName"],"sources":["../../src/Box/Box.tsx"],"sourcesContent":["import * as React from 'react'\nimport type { DivAttributes } from '../_utils/types'\nimport { StyledBox } from './Box.styles'\nimport type { BoxProps, Display, FlexDirection } from './Box.types'\n\n// TODO remove this after we decommission the LegacyDisplay type\nfunction getLegacyDisplayAndDirection(d?: Display) {\n if (!d) {\n return {}\n }\n\n let display = d\n\n let direction: FlexDirection | undefined = display.includes('flex')\n ? 'row'\n : undefined\n\n if (d.includes('flex-inline') || d.includes('inline-flex')) {\n display = 'inline-flex'\n } else if (d.includes('flex')) {\n display = 'flex'\n }\n\n if (d.includes('column-reverse')) {\n direction = 'column-reverse'\n } else if (d.includes('column')) {\n direction = 'column'\n }\n\n if (d.includes('row-reverse')) {\n direction = 'row-reverse'\n } else if (d.includes('row')) {\n direction = 'row'\n }\n\n return {\n display,\n direction,\n }\n}\n\n/**\n * `Box` is a general layout utility for CSS properties like `display`, `text-align`,\n * flex, spacing, and layout properties.\n */\nexport const Box = React.forwardRef<HTMLDivElement, DivAttributes & BoxProps>(\n function Box(\n {\n as,\n alignContent,\n alignItems,\n alignSelf,\n children,\n display,\n flex,\n flexBasis,\n flexDirection,\n flexGrow,\n flexShrink,\n flexWrap,\n gap,\n justifyContent,\n margin,\n marginBottom,\n marginLeft,\n marginRight,\n marginTop,\n order,\n padding,\n paddingBottom,\n paddingLeft,\n paddingRight,\n paddingTop,\n textAlign,\n ...props\n },\n ref\n ) {\n const legacyProps = getLegacyDisplayAndDirection(display)\n\n return (\n <StyledBox\n {...props}\n ref={ref}\n as={as}\n $alignContent={alignContent}\n $alignItems={alignItems}\n $alignSelf={alignSelf}\n $display={legacyProps.display}\n $flex={flex}\n $flexBasis={flexBasis}\n $flexDirection={flexDirection ?? legacyProps.direction}\n $flexGrow={flexGrow}\n $flexShrink={flexShrink}\n $flexWrap={flexWrap}\n $gap={gap}\n $justifyContent={justifyContent}\n $margin={margin}\n $marginBottom={marginBottom}\n $marginLeft={marginLeft}\n $marginRight={marginRight}\n $marginTop={marginTop}\n $order={order}\n $padding={padding}\n $paddingBottom={paddingBottom}\n $paddingLeft={paddingLeft}\n $paddingRight={paddingRight}\n $paddingTop={paddingTop}\n $textAlign={textAlign}\n >\n {children}\n </StyledBox>\n )\n }\n)\n\nBox.displayName = 'Box'\n"],"mappings":";;;;AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAE9B,SAASC,SAAS,QAAQ,cAAc;AAGxC;AACA,SAASC,4BAA4BA,CAACC,CAAW,EAAE;EACjD,IAAI,CAACA,CAAC,EAAE;IACN,OAAO,CAAC,CAAC;EACX;EAEA,IAAIC,OAAO,GAAGD,CAAC;EAEf,IAAIE,SAAoC,GAAGD,OAAO,CAACE,QAAQ,CAAC,MAAM,CAAC,GAC/D,KAAK,GACLC,SAAS;EAEb,IAAIJ,CAAC,CAACG,QAAQ,CAAC,aAAa,CAAC,IAAIH,CAAC,CAACG,QAAQ,CAAC,aAAa,CAAC,EAAE;IAC1DF,OAAO,GAAG,aAAa;EACzB,CAAC,MAAM,IAAID,CAAC,CAACG,QAAQ,CAAC,MAAM,CAAC,EAAE;IAC7BF,OAAO,GAAG,MAAM;EAClB;EAEA,IAAID,CAAC,CAACG,QAAQ,CAAC,gBAAgB,CAAC,EAAE;IAChCD,SAAS,GAAG,gBAAgB;EAC9B,CAAC,MAAM,IAAIF,CAAC,CAACG,QAAQ,CAAC,QAAQ,CAAC,EAAE;IAC/BD,SAAS,GAAG,QAAQ;EACtB;EAEA,IAA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AAC2D,WAAW,GAAG,KAAK"}
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  import type { $BoxProps } from './Box.types';
2
- export declare const StyledBox: import("styled-components").StyledComponent<"div", any, $BoxProps, never>;
3
+ export declare const StyledBox: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, $BoxProps>> & string;