@carbon/ibm-products 2.43.2-canary.11 → 2.43.2-canary.112

Sign up to get free protection for your applications and to get access to all the features.
Files changed (416) hide show
  1. package/css/config-dev.css +6 -1
  2. package/css/config-dev.css.map +1 -1
  3. package/css/config.css +6 -1
  4. package/css/config.css.map +1 -1
  5. package/css/index-full-carbon.css +1846 -499
  6. package/css/index-full-carbon.css.map +1 -1
  7. package/css/index-full-carbon.min.css +1 -1
  8. package/css/index-full-carbon.min.css.map +1 -1
  9. package/css/index-without-carbon-released-only.css +267 -65
  10. package/css/index-without-carbon-released-only.css.map +1 -1
  11. package/css/index-without-carbon-released-only.min.css +1 -1
  12. package/css/index-without-carbon-released-only.min.css.map +1 -1
  13. package/css/index-without-carbon.css +1455 -250
  14. package/css/index-without-carbon.css.map +1 -1
  15. package/css/index-without-carbon.min.css +1 -1
  16. package/css/index-without-carbon.min.css.map +1 -1
  17. package/css/index.css +1651 -369
  18. package/css/index.css.map +1 -1
  19. package/css/index.min.css +1 -1
  20. package/css/index.min.css.map +1 -1
  21. package/es/components/APIKeyModal/APIKeyModal.types.d.ts +6 -0
  22. package/es/components/ActionBar/ActionBar.d.ts +58 -2
  23. package/es/components/ActionBar/ActionBar.js +14 -9
  24. package/es/components/ActionBar/ActionBarItem.d.ts +36 -2
  25. package/es/components/ActionBar/ActionBarItem.js +8 -5
  26. package/es/components/ActionBar/ActionBarOverflowItems.d.ts +55 -16
  27. package/es/components/ActionBar/ActionBarOverflowItems.js +8 -4
  28. package/es/components/AddSelect/types/index.d.ts +6 -0
  29. package/es/components/Card/Card.d.ts +68 -2
  30. package/es/components/Card/Card.js +28 -35
  31. package/es/components/Card/CardFooter.d.ts +51 -48
  32. package/es/components/Card/CardFooter.js +4 -2
  33. package/es/components/Card/CardHeader.d.ts +67 -49
  34. package/es/components/Card/CardHeader.js +4 -2
  35. package/es/components/Coachmark/Coachmark.d.ts +6 -1
  36. package/es/components/Coachmark/Coachmark.js +47 -11
  37. package/es/components/Coachmark/CoachmarkOverlay.js +2 -4
  38. package/es/components/Coachmark/utils/enums.d.ts +6 -0
  39. package/es/components/CoachmarkBeacon/CoachmarkBeacon.js +1 -7
  40. package/es/components/CoachmarkFixed/CoachmarkFixed.js +13 -11
  41. package/es/components/CoachmarkStack/CoachmarkStack.js +7 -3
  42. package/es/components/CoachmarkStack/CoachmarkStackHome.js +8 -4
  43. package/es/components/ConditionBuilder/ConditionBlock/ConditionBlock.d.ts +1 -0
  44. package/es/components/ConditionBuilder/ConditionBlock/ConditionBlock.js +90 -56
  45. package/es/components/ConditionBuilder/ConditionBuilder.js +82 -25
  46. package/es/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.d.ts +15 -0
  47. package/es/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.js +154 -0
  48. package/es/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.d.ts +3 -1
  49. package/es/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.js +29 -13
  50. package/es/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.d.ts +8 -1
  51. package/es/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.js +35 -11
  52. package/es/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.js +18 -10
  53. package/es/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.js +19 -11
  54. package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.d.ts +9 -13
  55. package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +83 -64
  56. package/es/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.d.ts +13 -7
  57. package/es/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.js +31 -8
  58. package/es/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.d.ts +8 -2
  59. package/es/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.js +35 -24
  60. package/es/components/ConditionBuilder/ConditionBuilderContext/translationObject.d.ts +43 -36
  61. package/es/components/ConditionBuilder/ConditionBuilderContext/translationObject.js +43 -36
  62. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.d.ts +6 -2
  63. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.js +114 -40
  64. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.d.ts +3 -1
  65. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.js +24 -9
  66. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.js +27 -9
  67. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.d.ts +13 -0
  68. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +114 -0
  69. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.d.ts → ItemOptionForValueField.d.ts} +2 -2
  70. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.js → ItemOptionForValueField.js} +71 -38
  71. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.d.ts +5 -1
  72. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.js +22 -9
  73. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.js +1 -1
  74. package/es/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.d.ts +1 -3
  75. package/es/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.js +131 -42
  76. package/es/components/ConditionBuilder/ConditionPreview/ConditionPreview.d.ts +5 -1
  77. package/es/components/ConditionBuilder/ConditionPreview/ConditionPreview.js +51 -19
  78. package/es/components/ConditionBuilder/utils/handleKeyboardEvents.d.ts +2 -1
  79. package/es/components/ConditionBuilder/utils/handleKeyboardEvents.js +152 -42
  80. package/es/components/ConditionBuilder/utils/useTranslations.d.ts +1 -0
  81. package/es/components/ConditionBuilder/utils/useTranslations.js +26 -0
  82. package/es/components/ConditionBuilder/utils/util.d.ts +6 -4
  83. package/es/components/ConditionBuilder/utils/util.js +42 -17
  84. package/es/components/CreateFullPage/CreateFullPage.js +2 -2
  85. package/es/components/DataSpreadsheet/DataSpreadsheet.d.ts +26 -0
  86. package/es/components/DataSpreadsheet/DataSpreadsheet.js +129 -53
  87. package/es/components/DataSpreadsheet/DataSpreadsheetBody.d.ts +16 -0
  88. package/es/components/DataSpreadsheet/DataSpreadsheetBody.js +32 -7
  89. package/es/components/DataSpreadsheet/DataSpreadsheetHeader.d.ts +8 -0
  90. package/es/components/DataSpreadsheet/DataSpreadsheetHeader.js +16 -3
  91. package/es/components/DataSpreadsheet/types/index.d.ts +7 -0
  92. package/es/components/Datagrid/Datagrid/Datagrid.d.ts +0 -4
  93. package/es/components/Datagrid/Datagrid/Datagrid.js +4 -9
  94. package/es/components/Datagrid/Datagrid/DatagridBody.d.ts +6 -0
  95. package/es/components/Datagrid/Datagrid/DatagridContent.js +4 -3
  96. package/es/components/Datagrid/Datagrid/DatagridHeaderRow.js +23 -8
  97. package/es/components/Datagrid/Datagrid/DatagridRefBody.d.ts +6 -0
  98. package/es/components/Datagrid/Datagrid/DatagridRow.js +21 -8
  99. package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +6 -6
  100. package/es/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +3 -2
  101. package/es/components/Datagrid/Datagrid/DatagridSimpleBody.d.ts +6 -0
  102. package/es/components/Datagrid/Datagrid/DraggableElement.d.ts +6 -0
  103. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +34 -10
  104. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +6 -1
  105. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +6 -1
  106. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.d.ts +6 -3
  107. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +20 -12
  108. package/es/components/Datagrid/Datagrid/addons/Filtering/handleCheckboxChange.js +7 -0
  109. package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.d.ts +1 -1
  110. package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +54 -17
  111. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +2 -3
  112. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +75 -12
  113. package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +10 -2
  114. package/es/components/Datagrid/common-column-ids.d.ts +6 -0
  115. package/es/components/Datagrid/types/index.d.ts +63 -9
  116. package/es/components/Datagrid/useActionsColumn.d.ts +8 -1
  117. package/es/components/Datagrid/useActionsColumn.js +7 -6
  118. package/es/components/Datagrid/useColumnRightAlign.d.ts +8 -1
  119. package/es/components/Datagrid/useColumnRightAlign.js +4 -3
  120. package/es/components/Datagrid/useCustomizeColumns.d.ts +8 -1
  121. package/es/components/Datagrid/useCustomizeColumns.js +4 -3
  122. package/es/components/Datagrid/useDatagrid.d.ts +6 -0
  123. package/es/components/Datagrid/useDefaultStringRenderer.js +0 -1
  124. package/es/components/Datagrid/useDisableSelectRows.d.ts +8 -1
  125. package/es/components/Datagrid/useDisableSelectRows.js +27 -22
  126. package/es/components/Datagrid/useInlineEdit.js +12 -2
  127. package/es/components/Datagrid/useNestedRowExpander.js +1 -3
  128. package/es/components/Datagrid/useNestedRows.js +32 -13
  129. package/es/components/Datagrid/useRowExpander.js +1 -3
  130. package/es/components/Datagrid/useRowIsMouseOver.d.ts +6 -0
  131. package/es/components/Datagrid/useSelectRows.js +2 -1
  132. package/es/components/Datagrid/useStickyColumn.d.ts +8 -1
  133. package/es/components/Datagrid/useStickyColumn.js +12 -9
  134. package/es/components/EditInPlace/EditInPlace.d.ts +4 -0
  135. package/es/components/EditInPlace/EditInPlace.js +21 -10
  136. package/es/components/EditTearsheet/EditTearsheet.d.ts +7 -2
  137. package/es/components/EditTearsheet/EditTearsheet.js +44 -10
  138. package/es/components/EditTearsheet/EditTearsheetForm.d.ts +45 -2
  139. package/es/components/EditTearsheet/EditTearsheetForm.js +3 -0
  140. package/es/components/EmptyStates/EmptyState.d.ts +72 -5
  141. package/es/components/EmptyStates/EmptyState.js +8 -5
  142. package/es/components/EmptyStates/EmptyStateV2.d.ts +63 -2
  143. package/es/components/EmptyStates/EmptyStateV2.js +3 -2
  144. package/es/components/FullPageError/FullPageError.d.ts +36 -2
  145. package/es/components/FullPageError/FullPageError.js +0 -3
  146. package/es/components/GetStartedCard/GetStartedCard.d.ts +60 -2
  147. package/es/components/GetStartedCard/GetStartedCard.js +11 -10
  148. package/es/components/HTTPErrors/HTTPError403/HTTPError403.js +6 -0
  149. package/es/components/HTTPErrors/HTTPError404/HTTPError404.js +6 -0
  150. package/es/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +6 -0
  151. package/es/components/HTTPErrors/assets/HTTPErrorSvg403.js +204 -200
  152. package/es/components/HTTPErrors/assets/HTTPErrorSvg404.js +116 -112
  153. package/es/components/HTTPErrors/assets/HTTPErrorSvgOther.js +110 -106
  154. package/es/components/Nav/NavItem.js +12 -3
  155. package/es/components/OptionsTile/OptionsTile.js +11 -6
  156. package/es/components/PageHeader/PageHeader.js +1 -0
  157. package/es/components/PageHeader/PageHeaderUtils.js +1 -1
  158. package/es/components/RemoveModal/RemoveModal.d.ts +4 -0
  159. package/es/components/RemoveModal/RemoveModal.js +7 -1
  160. package/es/components/SearchBar/SearchBar.d.ts +1 -1
  161. package/es/components/SearchBar/SearchBar.js +2 -2
  162. package/es/components/SidePanel/SidePanel.js +17 -21
  163. package/es/components/SidePanel/motion/variants.d.ts +4 -6
  164. package/es/components/SidePanel/motion/variants.js +10 -11
  165. package/es/components/StatusIndicator/StatusIndicatorStep.js +87 -0
  166. package/es/components/StringFormatter/StringFormatter.js +14 -3
  167. package/es/components/StringFormatter/utils/enums.d.ts +20 -1
  168. package/es/components/StringFormatter/utils/enums.js +29 -2
  169. package/es/components/TagOverflow/TagOverflow.d.ts +35 -4
  170. package/es/components/TagOverflow/TagOverflow.js +47 -64
  171. package/es/components/TagOverflow/TagOverflowModal.js +4 -6
  172. package/es/components/TagOverflow/TagOverflowPopover.d.ts +13 -1
  173. package/es/components/TagOverflow/TagOverflowPopover.js +38 -41
  174. package/es/components/Tearsheet/Tearsheet.d.ts +8 -1
  175. package/es/components/Tearsheet/Tearsheet.js +9 -1
  176. package/es/components/Tearsheet/TearsheetNarrow.d.ts +11 -0
  177. package/es/components/Tearsheet/TearsheetNarrow.js +12 -0
  178. package/es/components/Tearsheet/TearsheetShell.d.ts +11 -1
  179. package/es/components/Tearsheet/TearsheetShell.js +28 -7
  180. package/es/components/Toolbar/ToolbarButton.js +1 -1
  181. package/es/components/UserAvatar/UserAvatar.d.ts +59 -1
  182. package/es/components/UserAvatar/UserAvatar.js +7 -23
  183. package/es/components/WebTerminal/WebTerminal.js +10 -12
  184. package/es/components/index.d.ts +1 -1
  185. package/es/global/js/hooks/useFocus.d.ts +1 -0
  186. package/es/global/js/hooks/useFocus.js +5 -2
  187. package/es/global/js/hooks/usePrefersReducedMotion.js +14 -8
  188. package/es/global/js/package-settings.d.ts +1 -1
  189. package/es/global/js/package-settings.js +1 -1
  190. package/es/global/js/utils/scrollableAncestor.js +7 -0
  191. package/es/global/js/utils/uuidv4.d.ts +6 -0
  192. package/es/global/js/utils/uuidv4.js +2 -0
  193. package/es/global/js/utils/wait.d.ts +6 -0
  194. package/es/global/js/utils/wait.js +2 -0
  195. package/es/index.js +1 -0
  196. package/es/node_modules/@carbon/icon-helpers/es/index.js +49 -62
  197. package/es/node_modules/@carbon/icons-react/es/generated/bucket-2.js +1020 -1058
  198. package/es/node_modules/@carbon/icons-react/es/generated/bucket-9.js +881 -758
  199. package/es/settings.d.ts +1 -1
  200. package/flags.js +7 -0
  201. package/lib/components/APIKeyModal/APIKeyModal.types.d.ts +6 -0
  202. package/lib/components/ActionBar/ActionBar.d.ts +58 -2
  203. package/lib/components/ActionBar/ActionBar.js +14 -9
  204. package/lib/components/ActionBar/ActionBarItem.d.ts +36 -2
  205. package/lib/components/ActionBar/ActionBarItem.js +7 -4
  206. package/lib/components/ActionBar/ActionBarOverflowItems.d.ts +55 -16
  207. package/lib/components/ActionBar/ActionBarOverflowItems.js +8 -4
  208. package/lib/components/AddSelect/types/index.d.ts +6 -0
  209. package/lib/components/Card/Card.d.ts +68 -2
  210. package/lib/components/Card/Card.js +28 -35
  211. package/lib/components/Card/CardFooter.d.ts +51 -48
  212. package/lib/components/Card/CardFooter.js +4 -2
  213. package/lib/components/Card/CardHeader.d.ts +67 -49
  214. package/lib/components/Card/CardHeader.js +4 -2
  215. package/lib/components/Coachmark/Coachmark.d.ts +6 -1
  216. package/lib/components/Coachmark/Coachmark.js +46 -10
  217. package/lib/components/Coachmark/CoachmarkOverlay.js +2 -4
  218. package/lib/components/Coachmark/utils/enums.d.ts +6 -0
  219. package/lib/components/CoachmarkBeacon/CoachmarkBeacon.js +1 -7
  220. package/lib/components/CoachmarkFixed/CoachmarkFixed.js +13 -11
  221. package/lib/components/CoachmarkStack/CoachmarkStack.js +7 -3
  222. package/lib/components/CoachmarkStack/CoachmarkStackHome.js +8 -4
  223. package/lib/components/ConditionBuilder/ConditionBlock/ConditionBlock.d.ts +1 -0
  224. package/lib/components/ConditionBuilder/ConditionBlock/ConditionBlock.js +87 -53
  225. package/lib/components/ConditionBuilder/ConditionBuilder.js +82 -25
  226. package/lib/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.d.ts +15 -0
  227. package/lib/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.js +163 -0
  228. package/lib/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.d.ts +3 -1
  229. package/lib/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.js +28 -11
  230. package/lib/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.d.ts +8 -1
  231. package/lib/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.js +33 -9
  232. package/lib/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.js +16 -8
  233. package/lib/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.js +18 -10
  234. package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.d.ts +9 -13
  235. package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +81 -62
  236. package/lib/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.d.ts +13 -7
  237. package/lib/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.js +31 -8
  238. package/lib/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.d.ts +8 -2
  239. package/lib/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.js +34 -24
  240. package/lib/components/ConditionBuilder/ConditionBuilderContext/translationObject.d.ts +43 -36
  241. package/lib/components/ConditionBuilder/ConditionBuilderContext/translationObject.js +43 -36
  242. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.d.ts +6 -2
  243. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.js +112 -38
  244. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.d.ts +3 -1
  245. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.js +24 -9
  246. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.js +28 -10
  247. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.d.ts +13 -0
  248. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +122 -0
  249. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.d.ts → ItemOptionForValueField.d.ts} +2 -2
  250. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.js → ItemOptionForValueField.js} +68 -35
  251. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.d.ts +5 -1
  252. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.js +21 -8
  253. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.js +1 -1
  254. package/lib/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.d.ts +1 -3
  255. package/lib/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.js +128 -39
  256. package/lib/components/ConditionBuilder/ConditionPreview/ConditionPreview.d.ts +5 -1
  257. package/lib/components/ConditionBuilder/ConditionPreview/ConditionPreview.js +50 -17
  258. package/lib/components/ConditionBuilder/utils/handleKeyboardEvents.d.ts +2 -1
  259. package/lib/components/ConditionBuilder/utils/handleKeyboardEvents.js +152 -41
  260. package/lib/components/ConditionBuilder/utils/useTranslations.d.ts +1 -0
  261. package/lib/components/ConditionBuilder/utils/useTranslations.js +30 -0
  262. package/lib/components/ConditionBuilder/utils/util.d.ts +6 -4
  263. package/lib/components/ConditionBuilder/utils/util.js +44 -16
  264. package/lib/components/CreateFullPage/CreateFullPage.js +2 -2
  265. package/lib/components/DataSpreadsheet/DataSpreadsheet.d.ts +26 -0
  266. package/lib/components/DataSpreadsheet/DataSpreadsheet.js +129 -53
  267. package/lib/components/DataSpreadsheet/DataSpreadsheetBody.d.ts +16 -0
  268. package/lib/components/DataSpreadsheet/DataSpreadsheetBody.js +32 -7
  269. package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.d.ts +8 -0
  270. package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.js +16 -3
  271. package/lib/components/DataSpreadsheet/types/index.d.ts +7 -0
  272. package/lib/components/Datagrid/Datagrid/Datagrid.d.ts +0 -4
  273. package/lib/components/Datagrid/Datagrid/Datagrid.js +4 -9
  274. package/lib/components/Datagrid/Datagrid/DatagridBody.d.ts +6 -0
  275. package/lib/components/Datagrid/Datagrid/DatagridContent.js +4 -3
  276. package/lib/components/Datagrid/Datagrid/DatagridHeaderRow.js +23 -8
  277. package/lib/components/Datagrid/Datagrid/DatagridRefBody.d.ts +6 -0
  278. package/lib/components/Datagrid/Datagrid/DatagridRow.js +21 -8
  279. package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +6 -6
  280. package/lib/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +3 -2
  281. package/lib/components/Datagrid/Datagrid/DatagridSimpleBody.d.ts +6 -0
  282. package/lib/components/Datagrid/Datagrid/DraggableElement.d.ts +6 -0
  283. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +34 -10
  284. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +6 -1
  285. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +6 -1
  286. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.d.ts +6 -3
  287. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +20 -12
  288. package/lib/components/Datagrid/Datagrid/addons/Filtering/handleCheckboxChange.js +7 -0
  289. package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.d.ts +1 -1
  290. package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +53 -16
  291. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +2 -3
  292. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +74 -11
  293. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +10 -2
  294. package/lib/components/Datagrid/common-column-ids.d.ts +6 -0
  295. package/lib/components/Datagrid/types/index.d.ts +63 -9
  296. package/lib/components/Datagrid/useActionsColumn.d.ts +8 -1
  297. package/lib/components/Datagrid/useActionsColumn.js +7 -6
  298. package/lib/components/Datagrid/useColumnRightAlign.d.ts +8 -1
  299. package/lib/components/Datagrid/useColumnRightAlign.js +4 -3
  300. package/lib/components/Datagrid/useCustomizeColumns.d.ts +8 -1
  301. package/lib/components/Datagrid/useCustomizeColumns.js +4 -3
  302. package/lib/components/Datagrid/useDatagrid.d.ts +6 -0
  303. package/lib/components/Datagrid/useDefaultStringRenderer.js +0 -1
  304. package/lib/components/Datagrid/useDisableSelectRows.d.ts +8 -1
  305. package/lib/components/Datagrid/useDisableSelectRows.js +27 -22
  306. package/lib/components/Datagrid/useInlineEdit.js +12 -2
  307. package/lib/components/Datagrid/useNestedRowExpander.js +1 -3
  308. package/lib/components/Datagrid/useNestedRows.js +32 -13
  309. package/lib/components/Datagrid/useRowExpander.js +1 -3
  310. package/lib/components/Datagrid/useRowIsMouseOver.d.ts +6 -0
  311. package/lib/components/Datagrid/useSelectRows.js +2 -1
  312. package/lib/components/Datagrid/useStickyColumn.d.ts +8 -1
  313. package/lib/components/Datagrid/useStickyColumn.js +12 -9
  314. package/lib/components/EditInPlace/EditInPlace.d.ts +4 -0
  315. package/lib/components/EditInPlace/EditInPlace.js +21 -10
  316. package/lib/components/EditTearsheet/EditTearsheet.d.ts +7 -2
  317. package/lib/components/EditTearsheet/EditTearsheet.js +43 -9
  318. package/lib/components/EditTearsheet/EditTearsheetForm.d.ts +45 -2
  319. package/lib/components/EditTearsheet/EditTearsheetForm.js +3 -0
  320. package/lib/components/EmptyStates/EmptyState.d.ts +72 -5
  321. package/lib/components/EmptyStates/EmptyState.js +8 -5
  322. package/lib/components/EmptyStates/EmptyStateV2.d.ts +63 -2
  323. package/lib/components/EmptyStates/EmptyStateV2.js +3 -2
  324. package/lib/components/FullPageError/FullPageError.d.ts +36 -2
  325. package/lib/components/FullPageError/FullPageError.js +0 -3
  326. package/lib/components/GetStartedCard/GetStartedCard.d.ts +60 -2
  327. package/lib/components/GetStartedCard/GetStartedCard.js +10 -9
  328. package/lib/components/HTTPErrors/HTTPError403/HTTPError403.js +6 -0
  329. package/lib/components/HTTPErrors/HTTPError404/HTTPError404.js +6 -0
  330. package/lib/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +6 -0
  331. package/lib/components/HTTPErrors/assets/HTTPErrorSvg403.js +204 -200
  332. package/lib/components/HTTPErrors/assets/HTTPErrorSvg404.js +116 -112
  333. package/lib/components/HTTPErrors/assets/HTTPErrorSvgOther.js +110 -106
  334. package/lib/components/Nav/NavItem.js +10 -1
  335. package/lib/components/OptionsTile/OptionsTile.js +11 -6
  336. package/lib/components/PageHeader/PageHeader.js +1 -0
  337. package/lib/components/PageHeader/PageHeaderUtils.js +1 -1
  338. package/lib/components/RemoveModal/RemoveModal.d.ts +4 -0
  339. package/lib/components/RemoveModal/RemoveModal.js +7 -1
  340. package/lib/components/SearchBar/SearchBar.d.ts +1 -1
  341. package/lib/components/SearchBar/SearchBar.js +2 -2
  342. package/lib/components/SidePanel/SidePanel.js +16 -20
  343. package/lib/components/SidePanel/motion/variants.d.ts +4 -6
  344. package/lib/components/SidePanel/motion/variants.js +10 -11
  345. package/lib/components/StatusIndicator/StatusIndicatorStep.js +94 -0
  346. package/lib/components/StringFormatter/StringFormatter.js +13 -2
  347. package/lib/components/StringFormatter/utils/enums.d.ts +20 -1
  348. package/lib/components/StringFormatter/utils/enums.js +30 -1
  349. package/lib/components/TagOverflow/TagOverflow.d.ts +35 -4
  350. package/lib/components/TagOverflow/TagOverflow.js +46 -63
  351. package/lib/components/TagOverflow/TagOverflowModal.js +4 -6
  352. package/lib/components/TagOverflow/TagOverflowPopover.d.ts +13 -1
  353. package/lib/components/TagOverflow/TagOverflowPopover.js +37 -40
  354. package/lib/components/Tearsheet/Tearsheet.d.ts +8 -1
  355. package/lib/components/Tearsheet/Tearsheet.js +9 -1
  356. package/lib/components/Tearsheet/TearsheetNarrow.d.ts +11 -0
  357. package/lib/components/Tearsheet/TearsheetNarrow.js +12 -0
  358. package/lib/components/Tearsheet/TearsheetShell.d.ts +11 -1
  359. package/lib/components/Tearsheet/TearsheetShell.js +26 -5
  360. package/lib/components/Toolbar/ToolbarButton.js +1 -1
  361. package/lib/components/UserAvatar/UserAvatar.d.ts +59 -1
  362. package/lib/components/UserAvatar/UserAvatar.js +7 -23
  363. package/lib/components/WebTerminal/WebTerminal.js +10 -12
  364. package/lib/components/index.d.ts +1 -1
  365. package/lib/global/js/hooks/useFocus.d.ts +1 -0
  366. package/lib/global/js/hooks/useFocus.js +5 -1
  367. package/lib/global/js/hooks/usePrefersReducedMotion.js +13 -7
  368. package/lib/global/js/package-settings.d.ts +1 -1
  369. package/lib/global/js/package-settings.js +1 -1
  370. package/lib/global/js/utils/scrollableAncestor.js +7 -0
  371. package/lib/global/js/utils/uuidv4.d.ts +6 -0
  372. package/lib/global/js/utils/uuidv4.js +2 -0
  373. package/lib/global/js/utils/wait.d.ts +6 -0
  374. package/lib/global/js/utils/wait.js +2 -0
  375. package/lib/index.js +5 -0
  376. package/lib/node_modules/@carbon/icon-helpers/es/index.js +49 -62
  377. package/lib/node_modules/@carbon/icons-react/es/generated/bucket-2.js +1036 -1074
  378. package/lib/node_modules/@carbon/icons-react/es/generated/bucket-9.js +946 -823
  379. package/lib/settings.d.ts +1 -1
  380. package/package.json +8 -7
  381. package/scss/components/Coachmark/_coachmark-overlay.scss +6 -70
  382. package/scss/components/Coachmark/_coachmark.scss +5 -4
  383. package/scss/components/CoachmarkBeacon/_coachmark-beacon.scss +1 -3
  384. package/scss/components/ConditionBuilder/_condition-builder.scss +8 -1
  385. package/scss/components/ConditionBuilder/styles/_conditionBuilderCondition.scss +38 -5
  386. package/scss/components/ConditionBuilder/styles/_conditionBuilderItem.scss +68 -22
  387. package/scss/components/ConditionBuilder/styles/_index.scss +7 -0
  388. package/scss/components/CreateModal/_create-modal.scss +0 -4
  389. package/scss/components/DataSpreadsheet/_data-spreadsheet.scss +16 -2
  390. package/scss/components/Datagrid/_datagrid.scss +0 -4
  391. package/scss/components/Datagrid/styles/_datagrid.scss +1 -0
  392. package/scss/components/Datagrid/styles/_useActionsColumn.scss +6 -7
  393. package/scss/components/Datagrid/styles/_useColumnRightAlign.scss +6 -7
  394. package/scss/components/Datagrid/styles/_useExpandedRow.scss +6 -7
  395. package/scss/components/Datagrid/styles/_useInlineEdit.scss +19 -7
  396. package/scss/components/Datagrid/styles/_useNestedRows.scss +6 -7
  397. package/scss/components/Datagrid/styles/_useNestedTable.scss +6 -7
  398. package/scss/components/Datagrid/styles/_useStickyColumn.scss +6 -7
  399. package/scss/components/Datagrid/styles/addons/_CustomizeColumnsTearsheet.scss +7 -5
  400. package/scss/components/Datagrid/styles/addons/_FilterFlyout.scss +5 -4
  401. package/scss/components/Datagrid/styles/addons/_RowSizeDropdown.scss +6 -7
  402. package/scss/components/HTTPErrors/_http-errors.scss +77 -0
  403. package/scss/components/OptionsTile/_options-tile.scss +6 -6
  404. package/scss/components/SidePanel/_side-panel.scss +1 -1
  405. package/scss/components/_index-released-only.scss +1 -0
  406. package/scss/config-dev.scss +7 -0
  407. package/scss/config.scss +7 -0
  408. package/telemetry.yml +32 -19
  409. package/es/components/ConditionBuilder/utils/checkForHoldingKey.d.ts +0 -1
  410. package/es/components/ConditionBuilder/utils/checkForHoldingKey.js +0 -16
  411. package/es/global/js/utils/window.d.ts +0 -2
  412. package/es/global/js/utils/window.js +0 -12
  413. package/lib/components/ConditionBuilder/utils/checkForHoldingKey.d.ts +0 -1
  414. package/lib/components/ConditionBuilder/utils/checkForHoldingKey.js +0 -20
  415. package/lib/global/js/utils/window.d.ts +0 -2
  416. package/lib/global/js/utils/window.js +0 -16
@@ -6,7 +6,7 @@
6
6
  */
7
7
 
8
8
  import { objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, objectSpread2 as _objectSpread2, extends as _extends, defineProperty as _defineProperty } from '../../_virtual/_rollupPluginBabelHelpers.js';
9
- import React__default, { useRef, useState, useCallback, useEffect } from 'react';
9
+ import React__default, { forwardRef, useRef, useState, useCallback, useEffect, createElement } from 'react';
10
10
  import PropTypes from '../../node_modules/prop-types/index.js';
11
11
  import cx from 'classnames';
12
12
  import { getDevtoolsProps } from '../../global/js/utils/devtools.js';
@@ -18,52 +18,36 @@ import { useResizeObserver } from '../../global/js/hooks/useResizeObserver.js';
18
18
  import { TagOverflowPopover } from './TagOverflowPopover.js';
19
19
  import { TagOverflowModal } from './TagOverflowModal.js';
20
20
 
21
- var _excluded = ["items", "tagComponent", "align", "showAllTagsLabel", "allTagsModalSearchLabel", "allTagsModalSearchPlaceholderText", "allTagsModalTarget", "allTagsModalTitle", "className", "containingElementRef", "measurementOffset", "maxVisible", "multiline", "overflowAlign", "overflowClassName", "overflowType", "onOverflowTagChange"],
21
+ var _excluded = ["align", "allTagsModalSearchLabel", "allTagsModalSearchPlaceholderText", "allTagsModalTarget", "allTagsModalTitle", "className", "containingElementRef", "items", "maxVisible", "measurementOffset", "multiline", "overflowAlign", "overflowClassName", "overflowType", "onOverflowTagChange", "showAllTagsLabel", "tagComponent"],
22
22
  _excluded2 = ["className", "id"],
23
23
  _excluded3 = ["tagType"],
24
24
  _excluded4 = ["id", "label", "tagType", "onClose"];
25
25
  var blockClass = "".concat(pkg.prefix, "--tag-overflow");
26
26
  var componentName = 'TagOverflow';
27
27
  var allTagsModalSearchThreshold = 10;
28
-
29
- // Default values for props
30
- var defaults = {
31
- items: [],
32
- align: 'start',
33
- measurementOffset: 0,
34
- overflowAlign: 'bottom',
35
- overflowType: 'default',
36
- onOverflowTagChange: function onOverflowTagChange() {}
37
- };
38
-
39
- /**
40
- * TODO: A description of the component.
41
- */
42
- var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
43
- var _ref$items = _ref.items,
44
- items = _ref$items === void 0 ? defaults.items : _ref$items,
45
- tagComponent = _ref.tagComponent,
46
- _ref$align = _ref.align,
47
- align = _ref$align === void 0 ? defaults.align : _ref$align,
48
- showAllTagsLabel = _ref.showAllTagsLabel,
49
- allTagsModalSearchLabel = _ref.allTagsModalSearchLabel,
50
- allTagsModalSearchPlaceholderText = _ref.allTagsModalSearchPlaceholderText,
51
- allTagsModalTarget = _ref.allTagsModalTarget,
52
- allTagsModalTitle = _ref.allTagsModalTitle,
53
- className = _ref.className,
54
- containingElementRef = _ref.containingElementRef,
55
- _ref$measurementOffse = _ref.measurementOffset,
56
- measurementOffset = _ref$measurementOffse === void 0 ? defaults.measurementOffset : _ref$measurementOffse,
57
- maxVisible = _ref.maxVisible,
58
- multiline = _ref.multiline,
59
- _ref$overflowAlign = _ref.overflowAlign,
60
- overflowAlign = _ref$overflowAlign === void 0 ? defaults.overflowAlign : _ref$overflowAlign,
61
- overflowClassName = _ref.overflowClassName,
62
- _ref$overflowType = _ref.overflowType,
63
- overflowType = _ref$overflowType === void 0 ? defaults.overflowType : _ref$overflowType,
64
- _ref$onOverflowTagCha = _ref.onOverflowTagChange,
65
- onOverflowTagChange = _ref$onOverflowTagCha === void 0 ? defaults.onOverflowTagChange : _ref$onOverflowTagCha,
66
- rest = _objectWithoutProperties(_ref, _excluded);
28
+ var TagOverflow = /*#__PURE__*/forwardRef(function (props, ref) {
29
+ var _props$align = props.align,
30
+ align = _props$align === void 0 ? 'start' : _props$align,
31
+ allTagsModalSearchLabel = props.allTagsModalSearchLabel,
32
+ allTagsModalSearchPlaceholderText = props.allTagsModalSearchPlaceholderText,
33
+ allTagsModalTarget = props.allTagsModalTarget,
34
+ allTagsModalTitle = props.allTagsModalTitle,
35
+ className = props.className,
36
+ containingElementRef = props.containingElementRef,
37
+ items = props.items,
38
+ maxVisible = props.maxVisible,
39
+ _props$measurementOff = props.measurementOffset,
40
+ measurementOffset = _props$measurementOff === void 0 ? 0 : _props$measurementOff,
41
+ multiline = props.multiline,
42
+ _props$overflowAlign = props.overflowAlign,
43
+ overflowAlign = _props$overflowAlign === void 0 ? 'bottom' : _props$overflowAlign,
44
+ overflowClassName = props.overflowClassName,
45
+ _props$overflowType = props.overflowType,
46
+ overflowType = _props$overflowType === void 0 ? 'default' : _props$overflowType,
47
+ onOverflowTagChange = props.onOverflowTagChange,
48
+ showAllTagsLabel = props.showAllTagsLabel,
49
+ tagComponent = props.tagComponent,
50
+ rest = _objectWithoutProperties(props, _excluded);
67
51
  var localContainerRef = useRef(null);
68
52
  var containerRef = ref || localContainerRef;
69
53
  var itemRefs = useRef(null);
@@ -100,7 +84,9 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
100
84
  setShowAllModalOpen(false);
101
85
  };
102
86
  var handleResize = function handleResize() {
103
- setContainerWidth(resizeElm.current.offsetWidth);
87
+ if (typeof resizeElm !== 'function' && resizeElm.current) {
88
+ setContainerWidth(resizeElm.current.offsetWidth);
89
+ }
104
90
  };
105
91
  useResizeObserver(resizeElm, handleResize);
106
92
  var getMap = function getMap() {
@@ -116,7 +102,6 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
116
102
  }
117
103
  };
118
104
  var getVisibleItems = useCallback(function () {
119
- var _overflowRef$current;
120
105
  if (!itemRefs.current) {
121
106
  return items;
122
107
  }
@@ -128,13 +113,13 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
128
113
  var optionalContainingElement = containingElementRef === null || containingElementRef === void 0 ? void 0 : containingElementRef.current;
129
114
  var measurementOffsetValue = typeof measurementOffset === 'number' ? measurementOffset : 0;
130
115
  var spaceAvailable = optionalContainingElement ? optionalContainingElement.offsetWidth - measurementOffsetValue : containerWidth;
131
- var overflowContainerWidth = ((_overflowRef$current = overflowRef.current) === null || _overflowRef$current === void 0 ? void 0 : _overflowRef$current.offsetWidth) > overflowIndicatorWidth ? overflowRef.current.offsetWidth : overflowIndicatorWidth;
116
+ var overflowContainerWidth = overflowRef && overflowRef.current && overflowRef.current.offsetWidth > overflowIndicatorWidth ? overflowRef.current.offsetWidth : overflowIndicatorWidth;
132
117
  var maxWidth = spaceAvailable - overflowContainerWidth;
133
118
  var childrenWidth = 0;
134
119
  var maxReached = false;
135
120
  return items.reduce(function (prev, cur) {
136
121
  if (!maxReached) {
137
- var itemWidth = map.get(cur.id) + itemOffset;
122
+ var itemWidth = (map ? Number(map.get(cur.id)) : 0) + itemOffset;
138
123
  var fits = itemWidth + childrenWidth < maxWidth;
139
124
  if (fits) {
140
125
  childrenWidth += itemWidth;
@@ -145,12 +130,13 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
145
130
  }
146
131
  return prev;
147
132
  }, []);
148
- }, [itemRefs, overflowRef, containerWidth, items, multiline, maxVisible, containingElementRef, measurementOffset]);
149
- var getCustomComponent = function getCustomComponent(item) {
133
+ }, [containerWidth, containingElementRef, items, maxVisible, measurementOffset, multiline]);
134
+ var getCustomComponent = function getCustomComponent(item, tagComponent) {
150
135
  var className = item.className,
151
136
  id = item.id,
152
137
  other = _objectWithoutProperties(item, _excluded2);
153
- return /*#__PURE__*/React__default.createElement(tagComponent, _objectSpread2(_objectSpread2({}, other), {}, {
138
+ return /*#__PURE__*/createElement(tagComponent, _objectSpread2(_objectSpread2({}, other), {}, {
139
+ key: id,
154
140
  className: cx("".concat(blockClass, "__item"), className),
155
141
  ref: function ref(node) {
156
142
  return itemRefHandler(id, node);
@@ -164,9 +150,9 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
164
150
  visibleItemsArr = (_visibleItemsArr = visibleItemsArr) === null || _visibleItemsArr === void 0 ? void 0 : _visibleItemsArr.slice(0, maxVisible);
165
151
  }
166
152
  var hiddenItems = items === null || items === void 0 ? void 0 : items.slice(visibleItemsArr.length);
167
- var overflowItemsArr = hiddenItems === null || hiddenItems === void 0 ? void 0 : hiddenItems.map(function (_ref2) {
168
- var tagType = _ref2.tagType,
169
- other = _objectWithoutProperties(_ref2, _excluded3);
153
+ var overflowItemsArr = hiddenItems === null || hiddenItems === void 0 ? void 0 : hiddenItems.map(function (_ref) {
154
+ var tagType = _ref.tagType,
155
+ other = _objectWithoutProperties(_ref, _excluded3);
170
156
  return _objectSpread2({
171
157
  type: tagType
172
158
  }, other);
@@ -174,10 +160,10 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
174
160
  setVisibleItems(visibleItemsArr);
175
161
  setOverflowItems(overflowItemsArr);
176
162
  onOverflowTagChange === null || onOverflowTagChange === void 0 || onOverflowTagChange(overflowItemsArr);
177
- }, [containerWidth, items, maxVisible, getVisibleItems, onOverflowTagChange]);
163
+ }, [getVisibleItems, items, maxVisible, onOverflowTagChange]);
178
164
  var handleTagOnClose = useCallback(function (onClose, index) {
179
165
  onClose === null || onClose === void 0 || onClose();
180
- if (index <= visibleItems.length - 1) {
166
+ if (index <= (visibleItems === null || visibleItems === void 0 ? void 0 : visibleItems.length) - 1) {
181
167
  setPopoverOpen(false);
182
168
  }
183
169
  }, [visibleItems]);
@@ -185,10 +171,10 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
185
171
  className: cx(blockClass, className, "".concat(blockClass, "--align-").concat(align), _defineProperty({}, "".concat(blockClass, "--multiline"), multiline)),
186
172
  ref: containerRef,
187
173
  role: "main"
188
- }, getDevtoolsProps(componentName)), visibleItems.length > 0 && visibleItems.map(function (item, index) {
174
+ }, getDevtoolsProps(componentName)), (visibleItems === null || visibleItems === void 0 ? void 0 : visibleItems.length) > 0 && visibleItems.map(function (item, index) {
189
175
  // Render custom components
190
176
  if (tagComponent) {
191
- return getCustomComponent(item);
177
+ return getCustomComponent(item, tagComponent);
192
178
  } else {
193
179
  var id = item.id,
194
180
  label = item.label,
@@ -215,7 +201,7 @@ var TagOverflow = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
215
201
  }), /*#__PURE__*/React__default.createElement("span", {
216
202
  className: "".concat(blockClass, "__indicator"),
217
203
  ref: overflowRef
218
- }, overflowItems.length > 0 && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(TagOverflowPopover, {
204
+ }, (overflowItems === null || overflowItems === void 0 ? void 0 : overflowItems.length) > 0 && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(TagOverflowPopover, {
219
205
  allTagsModalSearchThreshold: allTagsModalSearchThreshold,
220
206
  className: overflowClassName,
221
207
  onShowAllClick: handleShowAllClick,
@@ -251,9 +237,9 @@ var tagTypes = Object.keys(TYPES);
251
237
  * The strings shown in the showAllModal are only shown if we have more than allTagsModalSearchLThreshold
252
238
  * @returns null if no problems
253
239
  */
254
- var string_required_if_more_than_10_tags = isRequiredIf(PropTypes.string, function (_ref3) {
255
- var items = _ref3.items;
256
- return items && items.length > allTagsModalSearchThreshold;
240
+ var string_required_if_more_than_10_tags = isRequiredIf(PropTypes.string, function (_ref2) {
241
+ var items = _ref2.items;
242
+ return (items === null || items === void 0 ? void 0 : items.length) > allTagsModalSearchThreshold;
257
243
  });
258
244
 
259
245
  // The types and DocGen commentary for the component props,
@@ -284,11 +270,6 @@ TagOverflow.propTypes = {
284
270
  * Provide an optional class to be applied to the containing node.
285
271
  */
286
272
  className: PropTypes.string,
287
- /**
288
- * Optional ref for custom resize container to measure available space
289
- * Default will measure the available space of the TagSet container itself.
290
- */
291
- containingElementRef: PropTypes.object,
292
273
  /**
293
274
  * The items to be shown in the TagOverflow. Each item is specified as an object with properties:
294
275
  * **label**\* (required) to supply the content,
@@ -299,6 +280,7 @@ TagOverflow.propTypes = {
299
280
  * If you want to render a custom component, pass it as tagComponent prop and
300
281
  * then pass the props required for your custom component as the properties of item object
301
282
  */
283
+ //@ts-ignore
302
284
  items: PropTypes.arrayOf(PropTypes.shape({
303
285
  id: PropTypes.string.isRequired,
304
286
  label: PropTypes.string.isRequired,
@@ -342,6 +324,7 @@ TagOverflow.propTypes = {
342
324
  /** Component definition of the items to be rendered inside TagOverflow.
343
325
  * If this is not passed, items will be rendered as Tag component
344
326
  */
327
+ //@ts-ignore
345
328
  tagComponent: PropTypes.elementType
346
329
  };
347
330
 
@@ -14,8 +14,7 @@ import { pkg } from '../../settings.js';
14
14
  import { prepareProps } from '../../global/js/utils/props-helper.js';
15
15
  import { usePortalTarget } from '../../global/js/hooks/usePortalTarget.js';
16
16
 
17
- var _excluded = ["allTags", "className", "title", "onClose", "open", "overflowType", "portalTarget", "searchLabel", "searchPlaceholder"],
18
- _excluded2 = ["label", "id", "filter"];
17
+ var _excluded = ["allTags", "className", "title", "onClose", "open", "overflowType", "portalTarget", "searchLabel", "searchPlaceholder"];
19
18
  var componentName = 'TagOverflowModal';
20
19
  var blockClass = "".concat(pkg.prefix, "--tag-overflow-modal");
21
20
 
@@ -77,13 +76,12 @@ var TagOverflowModal = function TagOverflowModal(_ref) {
77
76
  }, getFilteredItems().map(function (_ref2) {
78
77
  var label = _ref2.label,
79
78
  id = _ref2.id,
80
- filter = _ref2.filter,
81
- other = _objectWithoutProperties(_ref2, _excluded2);
79
+ filter = _ref2.filter;
82
80
  var isFilterable = overflowType === 'tag' ? filter : false;
83
- return /*#__PURE__*/React__default.createElement(Tag, _extends({}, other, {
81
+ return /*#__PURE__*/React__default.createElement(Tag, {
84
82
  key: id,
85
83
  filter: isFilterable
86
- }), label);
84
+ }, label);
87
85
  })), /*#__PURE__*/React__default.createElement("div", {
88
86
  className: "".concat(blockClass, "__fade")
89
87
  })));
@@ -1,2 +1,14 @@
1
- export const TagOverflowPopover: React.ForwardRefExoticComponent<React.RefAttributes<any>>;
2
1
  import React from 'react';
2
+ import { TagOverflowItem } from './TagOverflow';
3
+ export interface Props {
4
+ allTagsModalSearchThreshold?: number;
5
+ className?: string;
6
+ onShowAllClick: () => void;
7
+ overflowAlign?: string;
8
+ overflowTags: TagOverflowItem[];
9
+ overflowType?: string;
10
+ popoverOpen?: boolean;
11
+ setPopoverOpen?: (x: boolean) => void;
12
+ showAllTagsLabel?: string;
13
+ }
14
+ export declare const TagOverflowPopover: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLDivElement>>;
@@ -6,7 +6,7 @@
6
6
  */
7
7
 
8
8
  import { objectWithoutProperties as _objectWithoutProperties, extends as _extends, defineProperty as _defineProperty } from '../../_virtual/_rollupPluginBabelHelpers.js';
9
- import React__default, { useRef } from 'react';
9
+ import React__default, { forwardRef, useRef } from 'react';
10
10
  import PropTypes from '../../node_modules/prop-types/index.js';
11
11
  import cx from 'classnames';
12
12
  import { Popover, Tag, PopoverContent, Link } from '@carbon/react';
@@ -17,52 +17,48 @@ var _excluded = ["allTagsModalSearchThreshold", "className", "onShowAllClick", "
17
17
  _excluded2 = ["label", "id", "tagType", "filter", "onClose"];
18
18
  var componentName = 'TagOverflowPopover';
19
19
  var blockClass = "".concat(pkg.prefix, "--tag-overflow-popover");
20
-
21
- // Default values for props
22
- var defaults = {
23
- allTagsModalSearchThreshold: 10,
24
- overflowAlign: 'bottom'
25
- };
26
- var TagOverflowPopover = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
27
- var _ref$allTagsModalSear = _ref.allTagsModalSearchThreshold,
28
- allTagsModalSearchThreshold = _ref$allTagsModalSear === void 0 ? defaults.allTagsModalSearchThreshold : _ref$allTagsModalSear,
29
- className = _ref.className,
30
- onShowAllClick = _ref.onShowAllClick,
31
- _ref$overflowAlign = _ref.overflowAlign,
32
- overflowAlign = _ref$overflowAlign === void 0 ? defaults.overflowAlign : _ref$overflowAlign,
33
- overflowTags = _ref.overflowTags,
34
- overflowType = _ref.overflowType,
35
- showAllTagsLabel = _ref.showAllTagsLabel,
36
- popoverOpen = _ref.popoverOpen,
37
- setPopoverOpen = _ref.setPopoverOpen,
38
- rest = _objectWithoutProperties(_ref, _excluded);
39
- var localRef = useRef();
20
+ var TagOverflowPopover = /*#__PURE__*/forwardRef(function (props, ref) {
21
+ var _overflowTags$length;
22
+ var allTagsModalSearchThreshold = props.allTagsModalSearchThreshold,
23
+ className = props.className,
24
+ onShowAllClick = props.onShowAllClick,
25
+ overflowAlign = props.overflowAlign,
26
+ overflowTags = props.overflowTags,
27
+ overflowType = props.overflowType,
28
+ showAllTagsLabel = props.showAllTagsLabel,
29
+ popoverOpen = props.popoverOpen,
30
+ setPopoverOpen = props.setPopoverOpen,
31
+ rest = _objectWithoutProperties(props, _excluded);
32
+ var localRef = useRef(null);
40
33
  var overflowTagContent = useRef(null);
41
34
  useClickOutside(ref || localRef, function () {
42
35
  if (popoverOpen) {
43
- setPopoverOpen(false);
36
+ setPopoverOpen === null || setPopoverOpen === void 0 || setPopoverOpen(false);
44
37
  }
45
38
  });
46
39
  var handleShowAllTagsClick = function handleShowAllTagsClick(evt) {
47
40
  evt.stopPropagation();
48
41
  evt.preventDefault();
49
- setPopoverOpen(false);
50
- onShowAllClick();
42
+ setPopoverOpen === null || setPopoverOpen === void 0 || setPopoverOpen(false);
43
+ onShowAllClick === null || onShowAllClick === void 0 || onShowAllClick();
51
44
  };
52
- var handleEscKeyPress = function handleEscKeyPress(event) {
53
- var key = event.key;
45
+ var handleEscKeyPress = function handleEscKeyPress(evt) {
46
+ var key = evt.key;
54
47
  if (key === 'Escape') {
55
- setPopoverOpen(false);
48
+ setPopoverOpen === null || setPopoverOpen === void 0 || setPopoverOpen(false);
56
49
  }
57
50
  };
58
51
  var getOverflowPopoverItems = function getOverflowPopoverItems() {
59
- return overflowTags.filter(function (_, index) {
60
- return overflowTags.length > allTagsModalSearchThreshold ? index < allTagsModalSearchThreshold : index <= allTagsModalSearchThreshold;
52
+ var thresh = allTagsModalSearchThreshold !== null && allTagsModalSearchThreshold !== void 0 ? allTagsModalSearchThreshold : 0;
53
+ return overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.filter(function (_, index) {
54
+ return (overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.length) > thresh ? index < thresh : index <= thresh;
61
55
  });
62
56
  };
57
+ var visibleItems = getOverflowPopoverItems();
58
+ var hasItems = (visibleItems === null || visibleItems === void 0 ? void 0 : visibleItems.length) > 0;
63
59
  return /*#__PURE__*/React__default.createElement("span", _extends({}, rest, {
64
- "aria-hidden": overflowTags.length === 0,
65
- className: cx(blockClass, _defineProperty({}, "".concat(blockClass, "--hidden"), overflowTags.length === 0)),
60
+ "aria-hidden": (overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.length) === 0,
61
+ className: cx(blockClass, _defineProperty({}, "".concat(blockClass, "--hidden"), (overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.length) === 0)),
66
62
  ref: ref || localRef
67
63
  }), /*#__PURE__*/React__default.createElement(Popover, {
68
64
  align: overflowAlign,
@@ -73,21 +69,21 @@ var TagOverflowPopover = /*#__PURE__*/React__default.forwardRef(function (_ref,
73
69
  open: popoverOpen
74
70
  }, /*#__PURE__*/React__default.createElement(Tag, {
75
71
  onClick: function onClick() {
76
- return setPopoverOpen(!popoverOpen);
72
+ return setPopoverOpen === null || setPopoverOpen === void 0 ? void 0 : setPopoverOpen(!popoverOpen);
77
73
  },
78
74
  className: cx("".concat(blockClass, "__trigger"))
79
- }, "+", overflowTags.length), /*#__PURE__*/React__default.createElement(PopoverContent, null, /*#__PURE__*/React__default.createElement("div", {
75
+ }, "+", overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.length), /*#__PURE__*/React__default.createElement(PopoverContent, null, /*#__PURE__*/React__default.createElement("div", {
80
76
  ref: overflowTagContent,
81
77
  className: "".concat(blockClass, "__content")
82
78
  }, /*#__PURE__*/React__default.createElement("ul", {
83
79
  className: "".concat(blockClass, "__tag-list")
84
- }, getOverflowPopoverItems().map(function (_ref2) {
85
- var label = _ref2.label,
86
- id = _ref2.id,
87
- tagType = _ref2.tagType,
88
- filter = _ref2.filter,
89
- _onClose = _ref2.onClose,
90
- other = _objectWithoutProperties(_ref2, _excluded2);
80
+ }, hasItems && visibleItems.map(function (_ref) {
81
+ var label = _ref.label,
82
+ id = _ref.id,
83
+ tagType = _ref.tagType,
84
+ filter = _ref.filter,
85
+ _onClose = _ref.onClose,
86
+ other = _objectWithoutProperties(_ref, _excluded2);
91
87
  var typeValue = overflowType === 'tag' ? 'high-contrast' : tagType;
92
88
  var isFilterable = overflowType === 'tag' ? filter : false;
93
89
  return /*#__PURE__*/React__default.createElement("li", {
@@ -100,7 +96,7 @@ var TagOverflowPopover = /*#__PURE__*/React__default.forwardRef(function (_ref,
100
96
  type: typeValue,
101
97
  filter: isFilterable
102
98
  }), label) : label);
103
- })), overflowTags.length > allTagsModalSearchThreshold && /*#__PURE__*/React__default.createElement(Link, {
99
+ })), ((_overflowTags$length = overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.length) !== null && _overflowTags$length !== void 0 ? _overflowTags$length : 0) > (allTagsModalSearchThreshold !== null && allTagsModalSearchThreshold !== void 0 ? allTagsModalSearchThreshold : 0) && /*#__PURE__*/React__default.createElement(Link, {
104
100
  className: "".concat(blockClass, "__show-all-tags-link"),
105
101
  href: "",
106
102
  onClick: handleShowAllTagsClick,
@@ -128,6 +124,7 @@ TagOverflowPopover.propTypes = {
128
124
  /**
129
125
  * tags shown in overflow
130
126
  */
127
+ //@ts-ignore
131
128
  overflowTags: PropTypes.arrayOf(PropTypes.object).isRequired,
132
129
  /**
133
130
  * Type of rendering displayed inside of the tag overflow component
@@ -99,9 +99,16 @@ interface TearsheetProps extends PropsWithChildren {
99
99
  */
100
100
  portalTarget: ReactNode;
101
101
  /**
102
- * Specify a CSS selector that matches the DOM element that should be focused when the Modal opens
102
+ * Specify a CSS selector that matches the DOM element that should be
103
+ * focused when the Modal opens.
103
104
  */
104
105
  selectorPrimaryFocus?: string;
106
+ /**
107
+ * Specify the CSS selectors that match the floating menus.
108
+ *
109
+ * See https://react.carbondesignsystem.com/?path=/docs/components-composedmodal--overview#focus-management
110
+ */
111
+ selectorsFloatingMenus?: string[];
105
112
  /**
106
113
  * The main title of the tearsheet, displayed in the header area.
107
114
  */
@@ -190,9 +190,17 @@ Tearsheet.propTypes = _objectSpread2({
190
190
  /**@ts-ignore */
191
191
  portalTarget: portalType,
192
192
  /**
193
- * Specify a CSS selector that matches the DOM element that should be focused when the Modal opens
193
+ * Specify a CSS selector that matches the DOM element that should be
194
+ * focused when the Modal opens.
194
195
  */
195
196
  selectorPrimaryFocus: PropTypes.string,
197
+ /**
198
+ * Specify the CSS selectors that match the floating menus.
199
+ *
200
+ * See https://react.carbondesignsystem.com/?path=/docs/components-composedmodal--overview#focus-management
201
+ */
202
+ /**@ts-ignore*/
203
+ selectorsFloatingMenus: PropTypes.arrayOf(PropTypes.string),
196
204
  /**
197
205
  * The main title of the tearsheet, displayed in the header area.
198
206
  */
@@ -64,6 +64,17 @@ interface TearsheetNarrowBaseProps extends PropsWithChildren {
64
64
  * The DOM element that the tearsheet should be rendered within. Defaults to document.body.
65
65
  */
66
66
  portalTarget?: ReactNode;
67
+ /**
68
+ * Specify a CSS selector that matches the DOM element that should be
69
+ * focused when the Modal opens.
70
+ */
71
+ selectorPrimaryFocus?: string;
72
+ /**
73
+ * Specify the CSS selectors that match the floating menus.
74
+ *
75
+ * See https://react.carbondesignsystem.com/?path=/docs/components-composedmodal--overview#focus-management
76
+ */
77
+ selectorsFloatingMenus?: string[];
67
78
  /**
68
79
  * The main title of the tearsheet, displayed in the header area.
69
80
  */
@@ -148,6 +148,18 @@ TearsheetNarrow.propTypes = _objectSpread2({
148
148
  */
149
149
  /**@ts-ignore */
150
150
  portalTarget: portalType,
151
+ /**
152
+ * Specify a CSS selector that matches the DOM element that should be
153
+ * focused when the Modal opens.
154
+ */
155
+ selectorPrimaryFocus: PropTypes.string,
156
+ /**
157
+ * Specify the CSS selectors that match the floating menus.
158
+ *
159
+ * See https://react.carbondesignsystem.com/?path=/docs/components-composedmodal--overview#focus-management
160
+ */
161
+ /**@ts-ignore*/
162
+ selectorsFloatingMenus: PropTypes.arrayOf(PropTypes.string),
151
163
  /**
152
164
  * The main title of the tearsheet, displayed in the header area.
153
165
  */
@@ -9,7 +9,7 @@ import React, { PropsWithChildren, ReactNode, RefObject } from 'react';
9
9
  import PropTypes from 'prop-types';
10
10
  import { type ButtonProps } from '@carbon/react';
11
11
  interface TearsheetShellProps extends PropsWithChildren {
12
- actions?: ButtonProps[];
12
+ actions?: ButtonProps<any>[];
13
13
  ariaLabel?: string;
14
14
  /**
15
15
  * An optional class or classes to be added to the outermost element.
@@ -81,7 +81,17 @@ interface TearsheetShellProps extends PropsWithChildren {
81
81
  * The DOM element that the tearsheet should be rendered within. Defaults to document.body.
82
82
  */
83
83
  portalTarget?: ReactNode;
84
+ /**
85
+ * Specify a CSS selector that matches the DOM element that should be
86
+ * focused when the Modal opens.
87
+ */
84
88
  selectorPrimaryFocus?: string;
89
+ /**
90
+ * Specify the CSS selectors that match the floating menus.
91
+ *
92
+ * See https://react.carbondesignsystem.com/?path=/docs/components-composedmodal--overview#focus-management
93
+ */
94
+ selectorsFloatingMenus?: string[];
85
95
  /**
86
96
  * Specifies the width of the tearsheet, 'narrow' or 'wide'.
87
97
  */
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  */
7
7
 
8
- import { objectSpread2 as _objectSpread2, objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, extends as _extends, defineProperty as _defineProperty } from '../../_virtual/_rollupPluginBabelHelpers.js';
8
+ import { objectSpread2 as _objectSpread2, objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, extends as _extends, defineProperty as _defineProperty, toConsumableArray as _toConsumableArray } from '../../_virtual/_rollupPluginBabelHelpers.js';
9
9
  import React__default, { useRef, useState, useEffect } from 'react';
10
10
  import { useResizeObserver } from '../../global/js/hooks/useResizeObserver.js';
11
11
  import PropTypes from '../../node_modules/prop-types/index.js';
@@ -16,11 +16,11 @@ import { getNodeTextContent } from '../../global/js/utils/getNodeTextContent.js'
16
16
  import { Button, usePrefix, ComposedModal, ModalHeader, Layer } from '@carbon/react';
17
17
  import { Wrap } from '../../global/js/utils/Wrap.js';
18
18
  import { usePortalTarget } from '../../global/js/hooks/usePortalTarget.js';
19
- import { useFocus } from '../../global/js/hooks/useFocus.js';
19
+ import { useFocus, getSpecificElement } from '../../global/js/hooks/useFocus.js';
20
20
  import { usePreviousValue } from '../../global/js/hooks/usePreviousValue.js';
21
21
  import { ActionSet } from '../ActionSet/ActionSet.js';
22
22
 
23
- var _excluded = ["actions", "ariaLabel", "children", "className", "closeIconDescription", "description", "hasCloseIcon", "headerActions", "influencer", "influencerPosition", "influencerWidth", "label", "navigation", "onClose", "open", "portalTarget", "selectorPrimaryFocus", "size", "slug", "title", "verticalPosition", "launcherButtonRef"];
23
+ var _excluded = ["actions", "ariaLabel", "children", "className", "closeIconDescription", "description", "hasCloseIcon", "headerActions", "influencer", "influencerPosition", "influencerWidth", "label", "navigation", "onClose", "open", "portalTarget", "selectorPrimaryFocus", "selectorsFloatingMenus", "size", "slug", "title", "verticalPosition", "launcherButtonRef"];
24
24
 
25
25
  // The block part of our conventional BEM class names (bc__E--M).
26
26
  var bc = "".concat(pkg.prefix, "--tearsheet");
@@ -79,6 +79,8 @@ var TearsheetShell = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
79
79
  open = _ref.open,
80
80
  portalTargetIn = _ref.portalTarget,
81
81
  selectorPrimaryFocus = _ref.selectorPrimaryFocus,
82
+ _ref$selectorsFloatin = _ref.selectorsFloatingMenus,
83
+ selectorsFloatingMenus = _ref$selectorsFloatin === void 0 ? [] : _ref$selectorsFloatin,
82
84
  size = _ref.size,
83
85
  slug = _ref.slug,
84
86
  title = _ref.title,
@@ -138,7 +140,8 @@ var TearsheetShell = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
138
140
  // Callback to give the tearsheet the opportunity to claim focus
139
141
  handleStackChange.claimFocus = function () {
140
142
  if (selectorPrimaryFocus) {
141
- return specifiedElement === null || specifiedElement === void 0 ? void 0 : specifiedElement.focus();
143
+ var _getSpecificElement;
144
+ return (_getSpecificElement = getSpecificElement(modalRef === null || modalRef === void 0 ? void 0 : modalRef.current, selectorPrimaryFocus)) === null || _getSpecificElement === void 0 ? void 0 : _getSpecificElement.focus();
142
145
  }
143
146
  firstElement === null || firstElement === void 0 || firstElement.focus();
144
147
  };
@@ -164,10 +167,13 @@ var TearsheetShell = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
164
167
  useEffect(function () {
165
168
  if (open && position !== depth) {
166
169
  setTimeout(function () {
170
+ if (selectorPrimaryFocus) {
171
+ return specifiedElement === null || specifiedElement === void 0 ? void 0 : specifiedElement.focus();
172
+ }
167
173
  firstElement === null || firstElement === void 0 || firstElement.focus();
168
174
  }, 0);
169
175
  }
170
- }, [position, depth, firstElement, open]);
176
+ }, [position, depth, firstElement, open, specifiedElement, selectorPrimaryFocus]);
171
177
  useEffect(function () {
172
178
  var notify = function notify() {
173
179
  return stack.all.forEach(function (handler) {
@@ -249,7 +255,7 @@ var TearsheetShell = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
249
255
  onKeyDown: keyDownListener,
250
256
  preventCloseOnClickOutside: !isPassive,
251
257
  ref: modalRef,
252
- selectorsFloatingMenus: [".".concat(carbonPrefix, "--overflow-menu-options"), ".".concat(carbonPrefix, "--tooltip"), '.flatpickr-calendar', ".".concat(bc, "__container")],
258
+ selectorsFloatingMenus: [".".concat(carbonPrefix, "--overflow-menu-options"), ".".concat(carbonPrefix, "--tooltip"), '.flatpickr-calendar', ".".concat(bc, "__container")].concat(_toConsumableArray(selectorsFloatingMenus)),
253
259
  size: "sm"
254
260
  }), includeHeader && /*#__PURE__*/React__default.createElement(ModalHeader, {
255
261
  className: cx("".concat(bc, "__header"), _defineProperty(_defineProperty({}, "".concat(bc, "__header--with-close-icon"), effectiveHasCloseIcon), "".concat(bc, "__header--with-nav"), navigation)),
@@ -311,7 +317,9 @@ var TearsheetShell = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
311
317
  // The display name of the component, used by React. Note that displayName
312
318
  // is used in preference to relying on function.name.
313
319
  TearsheetShell.displayName = componentName;
314
- var portalType = typeof Element === 'undefined' ? PropTypes.object : PropTypes.instanceOf(Element);
320
+ var portalType = typeof Element === 'undefined' ? PropTypes.object :
321
+ // eslint-disable-next-line ssr-friendly/no-dom-globals-in-module-scope
322
+ PropTypes.instanceOf(Element);
315
323
  var deprecatedProps = {
316
324
  /**
317
325
  * **Deprecated**
@@ -354,6 +362,7 @@ TearsheetShell.propTypes = _objectSpread2({
354
362
  label: PropTypes.string,
355
363
  loading: PropTypes.bool,
356
364
  // we duplicate this Button prop to improve the DocGen here
365
+ /**@ts-ignore*/
357
366
  onClick: Button.propTypes.onClick
358
367
  }))),
359
368
  /**
@@ -445,6 +454,18 @@ TearsheetShell.propTypes = _objectSpread2({
445
454
  */
446
455
  /**@ts-ignore*/
447
456
  portalTarget: portalType,
457
+ /**
458
+ * Specify a CSS selector that matches the DOM element that should be
459
+ * focused when the Modal opens.
460
+ */
461
+ selectorPrimaryFocus: PropTypes.string,
462
+ /**
463
+ * Specify the CSS selectors that match the floating menus.
464
+ *
465
+ * See https://react.carbondesignsystem.com/?path=/docs/components-composedmodal--overview#focus-management
466
+ */
467
+ /**@ts-ignore*/
468
+ selectorsFloatingMenus: PropTypes.arrayOf(PropTypes.string),
448
469
  /**
449
470
  * Specifies the width of the tearsheet, 'narrow' or 'wide'.
450
471
  */
@@ -28,7 +28,7 @@ var ToolbarButton = /*#__PURE__*/forwardRef(function (_ref, ref) {
28
28
  rest = _objectWithoutProperties(_ref, _excluded);
29
29
  var Icon = renderIcon;
30
30
  return /*#__PURE__*/React__default.createElement(IconButton, _extends({
31
- align: ((_useContext = useContext(ToolbarContext)) === null || _useContext === void 0 ? void 0 : _useContext.vertical) && 'right'
31
+ align: (_useContext = useContext(ToolbarContext)) !== null && _useContext !== void 0 && _useContext.vertical ? 'right' : 'top'
32
32
  }, rest, {
33
33
  label: iconDescription,
34
34
  ref: ref,