@carbon/ibm-products 2.54.0-canary.7 → 2.54.0-canary.70
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.
- package/css/index-full-carbon.css +1352 -681
- package/css/index-full-carbon.css.map +1 -1
- package/css/index-full-carbon.min.css +1 -1
- package/css/index-full-carbon.min.css.map +1 -1
- package/css/index-without-carbon-released-only.css +974 -59
- package/css/index-without-carbon-released-only.css.map +1 -1
- package/css/index-without-carbon-released-only.min.css +1 -1
- package/css/index-without-carbon-released-only.min.css.map +1 -1
- package/css/index-without-carbon.css +597 -557
- package/css/index-without-carbon.css.map +1 -1
- package/css/index-without-carbon.min.css +1 -1
- package/css/index-without-carbon.min.css.map +1 -1
- package/css/index.css +678 -562
- package/css/index.css.map +1 -1
- package/css/index.min.css +1 -1
- package/css/index.min.css.map +1 -1
- package/es/_virtual/_rollupPluginBabelHelpers.js +1 -1
- package/es/components/APIKeyModal/APIKeyDownloader.d.ts +1 -1
- package/es/components/APIKeyModal/APIKeyDownloader.js +1 -1
- package/es/components/APIKeyModal/APIKeyModal.d.ts +13 -0
- package/es/components/APIKeyModal/APIKeyModal.js +85 -38
- package/es/components/APIKeyModal/APIKeyModal.types.d.ts +21 -3
- package/es/components/AboutModal/AboutModal.js +3 -6
- package/es/components/AddSelect/hooks/useFocus.js +1 -2
- package/es/components/AddSelect/hooks/useParentSelect.js +1 -2
- package/es/components/AddSelect/hooks/usePath.js +1 -2
- package/es/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +18 -9
- package/es/components/Card/Card.d.ts +3 -3
- package/es/components/Card/Card.js +12 -12
- package/es/components/Card/CardHeader.d.ts +7 -7
- package/es/components/Card/CardHeader.js +14 -12
- package/es/components/Checklist/Checklist.js +1 -1
- package/es/components/Checklist/ChecklistIcon.js +1 -1
- package/es/components/Coachmark/Coachmark.d.ts +5 -0
- package/es/components/Coachmark/Coachmark.js +11 -3
- package/es/components/CoachmarkOverlayElements/CoachmarkOverlayElements.d.ts +5 -0
- package/es/components/CoachmarkOverlayElements/CoachmarkOverlayElements.js +19 -5
- package/es/components/CoachmarkStack/CoachmarkStackHome.d.ts +4 -0
- package/es/components/CoachmarkStack/CoachmarkStackHome.js +18 -6
- package/es/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.js +1 -2
- package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +9 -5
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +1 -5
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOptionForValueField.js +5 -5
- package/es/components/ConditionBuilder/utils/util.js +0 -4
- package/es/components/CreateTearsheet/CreateTearsheet.d.ts +1 -1
- package/es/components/CreateTearsheet/CreateTearsheet.js +2 -2
- package/es/components/CreateTearsheet/CreateTearsheetStep.js +6 -3
- package/es/components/Datagrid/Datagrid/Datagrid.d.ts +1 -0
- package/es/components/Datagrid/Datagrid/Datagrid.js +7 -0
- package/es/components/Datagrid/Datagrid/DatagridHeaderRow.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +31 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +2 -3
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +2 -3
- package/es/components/Datagrid/Datagrid/addons/Filtering/OverflowCheckboxes.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilterContext.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useShouldDisableButtons.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useSubscribeToEventEmitter.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/stateReducer.js +1 -1
- package/es/components/Datagrid/useCustomizeColumns.js +4 -4
- package/es/components/Datagrid/useDatagrid.js +2 -2
- package/es/components/Datagrid/useDefaultStringRenderer.js +1 -2
- package/es/components/Datagrid/useEditableCell.js +1 -2
- package/es/components/Datagrid/useFlexResize.js +1 -2
- package/es/components/Datagrid/useFloatingScroll.js +1 -2
- package/es/components/Datagrid/useNestedRowExpander.js +1 -2
- package/es/components/Datagrid/useParentDimensions.js +1 -2
- package/es/components/Datagrid/useResizeTable.js +1 -2
- package/es/components/Datagrid/useRowExpander.js +1 -2
- package/es/components/Datagrid/useRowRenderer.js +1 -2
- package/es/components/Datagrid/useRowSize.js +1 -2
- package/es/components/Datagrid/useSkeletonRows.js +1 -2
- package/es/components/DecoratorDualButton/DecoratorDualButton.d.ts +1 -0
- package/es/components/DecoratorDualButton/DecoratorDualButton.js +5 -0
- package/es/components/DecoratorLink/DecoratorLink.d.ts +1 -0
- package/es/components/DecoratorLink/DecoratorLink.js +5 -0
- package/es/components/DecoratorSingleButton/DecoratorSingleButton.d.ts +1 -0
- package/es/components/DecoratorSingleButton/DecoratorSingleButton.js +5 -0
- package/es/components/DescriptionList/DescriptionList.d.ts +1 -0
- package/es/components/DescriptionList/DescriptionList.js +5 -0
- package/es/components/EditFullPage/EditFullPage.d.ts +2 -0
- package/es/components/EditFullPage/EditFullPage.js +8 -0
- package/es/components/EditSidePanel/EditSidePanel.d.ts +2 -0
- package/es/components/EditSidePanel/EditSidePanel.js +8 -0
- package/es/components/EditTearsheet/EditTearsheet.d.ts +2 -0
- package/es/components/EditTearsheet/EditTearsheet.js +8 -0
- package/es/components/EditTearsheetNarrow/EditTearsheetNarrow.d.ts +2 -0
- package/es/components/EditTearsheetNarrow/EditTearsheetNarrow.js +8 -0
- package/es/components/EditUpdateCards/EditUpdateCards.d.ts +2 -0
- package/es/components/EditUpdateCards/EditUpdateCards.js +8 -0
- package/es/components/EmptyStates/EmptyStateIllustration.js +1 -2
- package/es/components/EmptyStates/EmptyStateV2.d.ts +1 -0
- package/es/components/EmptyStates/EmptyStateV2.js +7 -0
- package/es/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +1 -1
- package/es/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +1 -1
- package/es/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +1 -1
- package/es/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +1 -1
- package/es/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +1 -1
- package/es/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +1 -1
- package/es/components/EmptyStates/assets/ErrorIllustration.js +3 -5
- package/es/components/EmptyStates/assets/NoDataIllustration.js +3 -5
- package/es/components/EmptyStates/assets/NoTagsIllustration.js +3 -5
- package/es/components/EmptyStates/assets/NotFoundIllustration.js +3 -5
- package/es/components/EmptyStates/assets/NotificationsIllustration.js +3 -5
- package/es/components/EmptyStates/assets/UnauthorizedIllustration.js +3 -5
- package/es/components/ExpressiveCard/ExpressiveCard.d.ts +5 -5
- package/es/components/ExpressiveCard/ExpressiveCard.js +5 -5
- package/es/components/FilterPanel/FilterPanel.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanel.js +6 -0
- package/es/components/FilterPanel/FilterPanelAccordion/FilterPanelAccordion.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanelAccordion/FilterPanelAccordion.js +5 -0
- package/es/components/FilterPanel/FilterPanelAccordionItem/FilterPanelAccordionItem.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanelAccordionItem/FilterPanelAccordionItem.js +5 -1
- package/es/components/FilterPanel/FilterPanelCheckbox/FilterPanelCheckbox.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanelCheckbox/FilterPanelCheckbox.js +5 -0
- package/es/components/FilterPanel/FilterPanelCheckboxWithOverflow/FilterPanelCheckboxWithOverflow.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanelCheckboxWithOverflow/FilterPanelCheckboxWithOverflow.js +5 -0
- package/es/components/FilterPanel/FilterPanelGroup/FilterPanelGroup.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanelGroup/FilterPanelGroup.js +5 -0
- package/es/components/FilterPanel/FilterPanelSearch/FilterPanelSearch.d.ts +1 -0
- package/es/components/FilterPanel/FilterPanelSearch/FilterPanelSearch.js +5 -1
- package/es/components/FullPageError/FullPageError.js +7 -7
- package/es/components/FullPageError/assets/Error403SVG.d.ts +1 -3
- package/es/components/FullPageError/assets/Error403SVG.js +4 -6
- package/es/components/FullPageError/assets/Error404SVG.d.ts +1 -3
- package/es/components/FullPageError/assets/Error404SVG.js +4 -6
- package/es/components/FullPageError/assets/ErrorGenericSVG.d.ts +1 -3
- package/es/components/FullPageError/assets/ErrorGenericSVG.js +4 -6
- package/es/components/HTTPErrors/HTTPError403/HTTPError403.js +1 -1
- package/es/components/HTTPErrors/HTTPError404/HTTPError404.js +1 -1
- package/es/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +1 -1
- package/es/components/InlineTip/InlineTip.d.ts +5 -0
- package/es/components/InlineTip/InlineTip.js +17 -8
- package/es/components/Nav/Nav.d.ts +3 -0
- package/es/components/Nav/Nav.js +8 -0
- package/es/components/Nav/NavItemLink.js +1 -2
- package/es/components/ProductiveCard/ProductiveCard.d.ts +9 -5
- package/es/components/ProductiveCard/ProductiveCard.js +11 -9
- package/es/components/SidePanel/SidePanel.d.ts +6 -1
- package/es/components/SidePanel/SidePanel.js +27 -14
- package/es/components/StatusIndicator/StatusIndicator.d.ts +1 -0
- package/es/components/StatusIndicator/StatusIndicator.js +5 -0
- package/es/components/StatusIndicator/StatusIndicatorStep.d.ts +1 -0
- package/es/components/StatusIndicator/StatusIndicatorStep.js +5 -0
- package/es/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +3 -1
- package/es/components/TagOverflow/TagOverflow.js +2 -5
- package/es/components/Tearsheet/TearsheetShell.js +3 -24
- package/es/global/js/hooks/useFocus.d.ts +1 -0
- package/es/global/js/hooks/useFocus.js +21 -1
- package/es/global/js/hooks/usePrefersReducedMotion.js +1 -2
- package/es/global/js/package-settings.d.ts +1 -1
- package/es/global/js/package-settings.js +1 -1
- package/es/index.js +1 -1
- package/es/settings.d.ts +1 -1
- package/lib/_virtual/_rollupPluginBabelHelpers.js +1 -1
- package/lib/components/APIKeyModal/APIKeyDownloader.d.ts +1 -1
- package/lib/components/APIKeyModal/APIKeyDownloader.js +1 -1
- package/lib/components/APIKeyModal/APIKeyModal.d.ts +13 -0
- package/lib/components/APIKeyModal/APIKeyModal.js +83 -34
- package/lib/components/APIKeyModal/APIKeyModal.types.d.ts +21 -3
- package/lib/components/AboutModal/AboutModal.js +2 -5
- package/lib/components/AddSelect/hooks/useFocus.js +1 -2
- package/lib/components/AddSelect/hooks/useParentSelect.js +1 -2
- package/lib/components/AddSelect/hooks/usePath.js +1 -2
- package/lib/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +17 -8
- package/lib/components/Card/Card.d.ts +3 -3
- package/lib/components/Card/Card.js +12 -12
- package/lib/components/Card/CardHeader.d.ts +7 -7
- package/lib/components/Card/CardHeader.js +14 -12
- package/lib/components/Checklist/ChecklistChart.js +7 -7
- package/lib/components/Coachmark/Coachmark.d.ts +5 -0
- package/lib/components/Coachmark/Coachmark.js +11 -3
- package/lib/components/CoachmarkOverlayElements/CoachmarkOverlayElements.d.ts +5 -0
- package/lib/components/CoachmarkOverlayElements/CoachmarkOverlayElements.js +18 -4
- package/lib/components/CoachmarkStack/CoachmarkStackHome.d.ts +4 -0
- package/lib/components/CoachmarkStack/CoachmarkStackHome.js +18 -6
- package/lib/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.js +1 -2
- package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +9 -5
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +1 -5
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOptionForValueField.js +5 -5
- package/lib/components/ConditionBuilder/utils/util.js +0 -4
- package/lib/components/CreateTearsheet/CreateTearsheet.d.ts +1 -1
- package/lib/components/CreateTearsheet/CreateTearsheet.js +2 -2
- package/lib/components/CreateTearsheet/CreateTearsheetStep.js +5 -2
- package/lib/components/Datagrid/Datagrid/Datagrid.d.ts +1 -0
- package/lib/components/Datagrid/Datagrid/Datagrid.js +7 -0
- package/lib/components/Datagrid/Datagrid/DatagridHeaderRow.js +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +30 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/OverflowCheckboxes.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilterContext.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useShouldDisableButtons.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useSubscribeToEventEmitter.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/stateReducer.js +1 -1
- package/lib/components/Datagrid/useColumnOrder.js +1 -1
- package/lib/components/Datagrid/useDefaultStringRenderer.js +1 -2
- package/lib/components/Datagrid/useEditableCell.js +1 -2
- package/lib/components/Datagrid/useFlexResize.js +1 -2
- package/lib/components/Datagrid/useFloatingScroll.js +1 -2
- package/lib/components/Datagrid/useNestedRowExpander.js +1 -2
- package/lib/components/Datagrid/useParentDimensions.js +1 -2
- package/lib/components/Datagrid/useResizeTable.js +1 -2
- package/lib/components/Datagrid/useRowExpander.js +1 -2
- package/lib/components/Datagrid/useRowRenderer.js +1 -2
- package/lib/components/Datagrid/useRowSize.js +1 -2
- package/lib/components/Datagrid/useSkeletonRows.js +1 -2
- package/lib/components/DecoratorDualButton/DecoratorDualButton.d.ts +1 -0
- package/lib/components/DecoratorDualButton/DecoratorDualButton.js +5 -0
- package/lib/components/DecoratorLink/DecoratorLink.d.ts +1 -0
- package/lib/components/DecoratorLink/DecoratorLink.js +5 -0
- package/lib/components/DecoratorSingleButton/DecoratorSingleButton.d.ts +1 -0
- package/lib/components/DecoratorSingleButton/DecoratorSingleButton.js +5 -0
- package/lib/components/DescriptionList/DescriptionList.d.ts +1 -0
- package/lib/components/DescriptionList/DescriptionList.js +5 -0
- package/lib/components/EditFullPage/EditFullPage.d.ts +2 -0
- package/lib/components/EditFullPage/EditFullPage.js +8 -0
- package/lib/components/EditSidePanel/EditSidePanel.d.ts +2 -0
- package/lib/components/EditSidePanel/EditSidePanel.js +8 -0
- package/lib/components/EditTearsheet/EditTearsheet.d.ts +2 -0
- package/lib/components/EditTearsheet/EditTearsheet.js +8 -0
- package/lib/components/EditTearsheetNarrow/EditTearsheetNarrow.d.ts +2 -0
- package/lib/components/EditTearsheetNarrow/EditTearsheetNarrow.js +8 -0
- package/lib/components/EditUpdateCards/EditUpdateCards.d.ts +2 -0
- package/lib/components/EditUpdateCards/EditUpdateCards.js +8 -0
- package/lib/components/EmptyStates/EmptyStateIllustration.js +1 -2
- package/lib/components/EmptyStates/EmptyStateV2.d.ts +1 -0
- package/lib/components/EmptyStates/EmptyStateV2.js +7 -0
- package/lib/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +1 -1
- package/lib/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +1 -1
- package/lib/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +1 -1
- package/lib/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +1 -1
- package/lib/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +1 -1
- package/lib/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +1 -1
- package/lib/components/EmptyStates/assets/ErrorIllustration.js +2 -4
- package/lib/components/EmptyStates/assets/NoDataIllustration.js +2 -4
- package/lib/components/EmptyStates/assets/NoTagsIllustration.js +2 -4
- package/lib/components/EmptyStates/assets/NotFoundIllustration.js +2 -4
- package/lib/components/EmptyStates/assets/NotificationsIllustration.js +2 -4
- package/lib/components/EmptyStates/assets/UnauthorizedIllustration.js +2 -4
- package/lib/components/ExpressiveCard/ExpressiveCard.d.ts +5 -5
- package/lib/components/ExpressiveCard/ExpressiveCard.js +5 -5
- package/lib/components/FilterPanel/FilterPanel.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanel.js +6 -0
- package/lib/components/FilterPanel/FilterPanelAccordion/FilterPanelAccordion.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanelAccordion/FilterPanelAccordion.js +5 -0
- package/lib/components/FilterPanel/FilterPanelAccordionItem/FilterPanelAccordionItem.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanelAccordionItem/FilterPanelAccordionItem.js +5 -1
- package/lib/components/FilterPanel/FilterPanelCheckbox/FilterPanelCheckbox.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanelCheckbox/FilterPanelCheckbox.js +5 -0
- package/lib/components/FilterPanel/FilterPanelCheckboxWithOverflow/FilterPanelCheckboxWithOverflow.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanelCheckboxWithOverflow/FilterPanelCheckboxWithOverflow.js +5 -0
- package/lib/components/FilterPanel/FilterPanelGroup/FilterPanelGroup.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanelGroup/FilterPanelGroup.js +5 -0
- package/lib/components/FilterPanel/FilterPanelSearch/FilterPanelSearch.d.ts +1 -0
- package/lib/components/FilterPanel/FilterPanelSearch/FilterPanelSearch.js +5 -1
- package/lib/components/FullPageError/FullPageError.js +7 -7
- package/lib/components/FullPageError/assets/Error403SVG.d.ts +1 -3
- package/lib/components/FullPageError/assets/Error403SVG.js +4 -6
- package/lib/components/FullPageError/assets/Error404SVG.d.ts +1 -3
- package/lib/components/FullPageError/assets/Error404SVG.js +4 -6
- package/lib/components/FullPageError/assets/ErrorGenericSVG.d.ts +1 -3
- package/lib/components/FullPageError/assets/ErrorGenericSVG.js +4 -6
- package/lib/components/HTTPErrors/HTTPError403/HTTPError403.js +1 -1
- package/lib/components/HTTPErrors/HTTPError404/HTTPError404.js +1 -1
- package/lib/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +1 -1
- package/lib/components/InlineTip/InlineTip.d.ts +5 -0
- package/lib/components/InlineTip/InlineTip.js +17 -8
- package/lib/components/Nav/Nav.d.ts +3 -0
- package/lib/components/Nav/Nav.js +8 -0
- package/lib/components/Nav/NavItemLink.js +1 -2
- package/lib/components/ProductiveCard/ProductiveCard.d.ts +9 -5
- package/lib/components/ProductiveCard/ProductiveCard.js +11 -9
- package/lib/components/SidePanel/SidePanel.d.ts +6 -1
- package/lib/components/SidePanel/SidePanel.js +27 -14
- package/lib/components/StatusIndicator/StatusIndicator.d.ts +1 -0
- package/lib/components/StatusIndicator/StatusIndicator.js +5 -0
- package/lib/components/StatusIndicator/StatusIndicatorStep.d.ts +1 -0
- package/lib/components/StatusIndicator/StatusIndicatorStep.js +5 -0
- package/lib/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +3 -1
- package/lib/components/TagOverflow/TagOverflow.js +1 -4
- package/lib/components/Tearsheet/TearsheetShell.js +2 -23
- package/lib/global/js/hooks/useFocus.d.ts +1 -0
- package/lib/global/js/hooks/useFocus.js +21 -0
- package/lib/global/js/hooks/usePrefersReducedMotion.js +1 -2
- package/lib/global/js/package-settings.d.ts +1 -1
- package/lib/global/js/package-settings.js +1 -1
- package/lib/index.js +109 -109
- package/lib/settings.d.ts +1 -1
- package/package.json +10 -10
- package/scss/components/APIKeyModal/_api-key-modal.scss +4 -0
- package/scss/components/BreadcrumbWithOverflow/_breadcrumb-with-overflow.scss +3 -3
- package/scss/components/Card/_card.scss +19 -5
- package/scss/components/Coachmark/_coachmark-overlay.scss +2 -2
- package/scss/components/Coachmark/_coachmark-tagline.scss +1 -1
- package/scss/components/CoachmarkBeacon/_coachmark-beacon.scss +3 -3
- package/scss/components/CoachmarkStack/_coachmark-stack.scss +2 -2
- package/scss/components/ConditionBuilder/styles/_conditionBuilderItem.scss +7 -7
- package/scss/components/CreateInfluencer/_create-influencer.scss +2 -2
- package/scss/components/CreateTearsheet/_create-tearsheet.scss +1 -2
- package/scss/components/DataSpreadsheet/_data-spreadsheet.scss +4 -4
- package/scss/components/Datagrid/styles/_datagrid.scss +21 -14
- package/scss/components/Datagrid/styles/_draggableElement.scss +2 -2
- package/scss/components/Datagrid/styles/_useColumnRightAlign.scss +1 -1
- package/scss/components/Datagrid/styles/_useExpandedRow.scss +1 -1
- package/scss/components/Datagrid/styles/_useInlineEdit.scss +1 -1
- package/scss/components/Datagrid/styles/_useNestedRows.scss +2 -2
- package/scss/components/Datagrid/styles/_useStickyColumn.scss +2 -2
- package/scss/components/Datagrid/styles/addons/_CustomizeColumnsTearsheet.scss +1 -1
- package/scss/components/Datagrid/styles/addons/_FilterFlyout.scss +1 -1
- package/scss/components/Datagrid/styles/addons/_FilterPanel.scss +1 -1
- package/scss/components/Datagrid/styles/addons/_RowSizeDropdown.scss +1 -2
- package/scss/components/DecoratorBase/_decorator-base-mixins.scss +1 -1
- package/scss/components/DecoratorBase/_decorator-base.scss +3 -3
- package/scss/components/DecoratorDualButton/_decorator-dual-button.scss +1 -1
- package/scss/components/DecoratorSingleButton/_decorator-single-button.scss +1 -1
- package/scss/components/EditTearsheet/_edit-tearsheet.scss +1 -2
- package/scss/components/EditUpdateCards/_edit-update-cards.scss +7 -7
- package/scss/components/FullPageError/_full-page-error.scss +1 -1
- package/scss/components/GetStartedCard/_get-started-card.scss +1 -1
- package/scss/components/Guidebanner/_guidebanner.scss +4 -4
- package/scss/components/HTTPErrors/_http-errors.scss +1 -1
- package/scss/components/InlineTip/_inline-tip.scss +4 -4
- package/scss/components/InterstitialScreen/_interstitial-screen.scss +6 -6
- package/scss/components/NonLinearReading/_non-linear-reading.scss +2 -2
- package/scss/components/NotificationsPanel/_notifications-panel.scss +3 -3
- package/scss/components/OptionsTile/_options-tile.scss +6 -8
- package/scss/components/PageHeader/_page-header.scss +20 -13
- package/scss/components/ProductiveCard/_productive-card.scss +2 -2
- package/scss/components/SidePanel/_side-panel.scss +24 -17
- package/scss/components/StatusIcon/_status-icon.scss +9 -7
- package/scss/components/StatusIndicator/_status-indicator.scss +1 -1
- package/scss/components/Tearsheet/_tearsheet.scss +5 -5
- package/scss/components/UserAvatar/_user-avatar.scss +5 -3
- package/scss/components/UserProfileImage/_user-profile-image.scss +6 -4
- package/scss/components/WebTerminal/_web-terminal.scss +2 -2
- package/scss/components/_index-released-only.scss +1 -0
- package/telemetry.yml +3 -0
@@ -5,22 +5,23 @@
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
6
6
|
*/
|
7
7
|
|
8
|
-
import { objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, extends as _extends,
|
8
|
+
import { objectSpread2 as _objectSpread2, objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, extends as _extends, asyncToGenerator as _asyncToGenerator, regeneratorRuntime as _regeneratorRuntime } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
9
9
|
import React__default, { forwardRef, useState, useRef, useEffect } from 'react';
|
10
10
|
import PropTypes from '../../_virtual/index.js';
|
11
11
|
import cx from 'classnames';
|
12
12
|
import { unstable_FeatureFlags, ComposedModal, ModalHeader, ModalBody, PasswordInput, TextInput, Form, InlineLoading, ModalFooter, Button } from '@carbon/react';
|
13
|
-
import { ErrorFilled, InformationFilled, Copy } from '@carbon/react/icons';
|
13
|
+
import { ErrorFilled, InformationFilled, CheckmarkFilled, Copy } from '@carbon/react/icons';
|
14
14
|
import { APIKeyDownloader } from './APIKeyDownloader.js';
|
15
15
|
import { pkg } from '../../settings.js';
|
16
16
|
import { usePortalTarget } from '../../global/js/hooks/usePortalTarget.js';
|
17
17
|
import { getDevtoolsProps } from '../../global/js/utils/devtools.js';
|
18
18
|
import { isRequiredIf } from '../../global/js/utils/props-helper.js';
|
19
19
|
import uuidv4 from '../../global/js/utils/uuidv4.js';
|
20
|
-
import { useFocus,
|
20
|
+
import { useFocus, claimFocus } from '../../global/js/hooks/useFocus.js';
|
21
|
+
import { usePreviousValue } from '../../global/js/hooks/usePreviousValue.js';
|
21
22
|
|
22
23
|
var _ErrorFilled, _InformationFilled;
|
23
|
-
var _excluded = ["apiKey", "apiKeyLabel", "apiKeyName", "body", "className", "closeButtonText", "copyButtonText", "copyErrorText", "copyIconDescription", "customSteps", "downloadBodyText", "downloadFileName", "downloadFileType", "downloadLinkText", "downloadLinkLabel", "editButtonText", "editSuccess", "editSuccessTitle", "editing", "error", "errorText", "generateButtonText", "generateSuccessBody", "generateSuccessTitle", "generateTitle", "hasAPIKeyVisibilityToggle", "hasDownloadLink", "hideAPIKeyLabel", "loading", "loadingText", "modalLabel", "nameHelperText", "nameLabel", "namePlaceholder", "nameRequired", "nextStepButtonText", "onClose", "onCopy", "onRequestEdit", "onRequestGenerate", "open", "portalTarget", "previousStepButtonText", "selectorPrimaryFocus", "showAPIKeyLabel"];
|
24
|
+
var _excluded = ["apiKey", "apiKeyLabel", "apiKeyName", "body", "className", "closeButtonText", "copyButtonText", "copyErrorText", "copyIconDescription", "customSteps", "downloadBodyText", "downloadFileName", "downloadFileType", "downloadLinkText", "downloadLinkLabel", "editButtonText", "editSuccess", "editSuccessTitle", "editSuccessMessage", "editing", "error", "errorText", "generateButtonText", "generateSuccessBody", "generateSuccessTitle", "generateSuccessMessage", "generateTitle", "hasAPIKeyVisibilityToggle", "hasDownloadLink", "hideAPIKeyLabel", "launcherButtonRef", "loading", "loadingText", "modalLabel", "nameHelperText", "nameLabel", "namePlaceholder", "nameRequired", "nextStepButtonText", "onClose", "onCopy", "onRequestEdit", "onRequestGenerate", "open", "portalTarget", "previousStepButtonText", "selectorPrimaryFocus", "showAPIKeyLabel", "helperText"];
|
24
25
|
var componentName = 'APIKeyModal';
|
25
26
|
|
26
27
|
// Default values for props
|
@@ -51,16 +52,19 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
51
52
|
editButtonText = _ref.editButtonText,
|
52
53
|
editSuccess = _ref.editSuccess,
|
53
54
|
editSuccessTitle = _ref.editSuccessTitle,
|
55
|
+
editSuccessMessage = _ref.editSuccessMessage,
|
54
56
|
editing = _ref.editing,
|
55
57
|
error = _ref.error,
|
56
58
|
errorText = _ref.errorText,
|
57
59
|
generateButtonText = _ref.generateButtonText,
|
58
60
|
generateSuccessBody = _ref.generateSuccessBody,
|
59
61
|
generateSuccessTitle = _ref.generateSuccessTitle,
|
62
|
+
generateSuccessMessage = _ref.generateSuccessMessage,
|
60
63
|
generateTitle = _ref.generateTitle,
|
61
64
|
hasAPIKeyVisibilityToggle = _ref.hasAPIKeyVisibilityToggle,
|
62
65
|
hasDownloadLink = _ref.hasDownloadLink,
|
63
66
|
hideAPIKeyLabel = _ref.hideAPIKeyLabel,
|
67
|
+
launcherButtonRef = _ref.launcherButtonRef,
|
64
68
|
loading = _ref.loading,
|
65
69
|
loadingText = _ref.loadingText,
|
66
70
|
modalLabel = _ref.modalLabel,
|
@@ -78,23 +82,28 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
78
82
|
previousStepButtonText = _ref.previousStepButtonText,
|
79
83
|
selectorPrimaryFocus = _ref.selectorPrimaryFocus,
|
80
84
|
showAPIKeyLabel = _ref.showAPIKeyLabel,
|
85
|
+
helperText = _ref.helperText,
|
81
86
|
rest = _objectWithoutProperties(_ref, _excluded);
|
82
87
|
var _useState = useState(null),
|
83
88
|
_useState2 = _slicedToArray(_useState, 2),
|
84
89
|
title = _useState2[0],
|
85
90
|
setTitle = _useState2[1];
|
86
|
-
var _useState3 = useState(
|
91
|
+
var _useState3 = useState(null),
|
87
92
|
_useState4 = _slicedToArray(_useState3, 2),
|
88
|
-
|
89
|
-
|
90
|
-
var _useState5 = useState(
|
93
|
+
successMessage = _useState4[0],
|
94
|
+
setSuccessMessage = _useState4[1];
|
95
|
+
var _useState5 = useState(false),
|
91
96
|
_useState6 = _slicedToArray(_useState5, 2),
|
92
|
-
|
93
|
-
|
94
|
-
var _useState7 = useState(
|
97
|
+
copyError = _useState6[0],
|
98
|
+
setCopyError = _useState6[1];
|
99
|
+
var _useState7 = useState(apiKeyName),
|
95
100
|
_useState8 = _slicedToArray(_useState7, 2),
|
96
|
-
|
97
|
-
|
101
|
+
name = _useState8[0],
|
102
|
+
setName = _useState8[1];
|
103
|
+
var _useState9 = useState(0),
|
104
|
+
_useState10 = _slicedToArray(_useState9, 2),
|
105
|
+
currentStep = _useState10[0],
|
106
|
+
setCurrentStep = _useState10[1];
|
98
107
|
var copyRef = useRef(undefined);
|
99
108
|
var apiKeyInputId = useRef(uuidv4());
|
100
109
|
var nameInputId = useRef(uuidv4());
|
@@ -114,33 +123,33 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
114
123
|
};
|
115
124
|
var blockClass = "".concat(pkg.prefix, "--apikey-modal");
|
116
125
|
var localRef = useRef(undefined);
|
126
|
+
var PasswordInputRef = useRef(null);
|
117
127
|
var modalRef = ref || localRef;
|
118
128
|
var _useFocus = useFocus(modalRef, selectorPrimaryFocus),
|
119
129
|
firstElement = _useFocus.firstElement,
|
120
130
|
keyDownListener = _useFocus.keyDownListener;
|
131
|
+
var prevOpen = usePreviousValue(open);
|
121
132
|
useEffect(function () {
|
122
133
|
if (copyRef.current && open && apiKeyLoaded) {
|
123
134
|
copyRef.current.focus();
|
124
135
|
}
|
136
|
+
if (PasswordInputRef !== null && PasswordInputRef !== void 0 && PasswordInputRef.current) {
|
137
|
+
PasswordInputRef === null || PasswordInputRef === void 0 || PasswordInputRef.current.setAttribute('readOnly', 'true');
|
138
|
+
}
|
125
139
|
}, [open, apiKeyLoaded]);
|
126
140
|
useEffect(function () {
|
127
141
|
if (open) {
|
128
142
|
// Focusing the first element or selectorPrimaryFocus element
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
return specifiedEl.focus();
|
135
|
-
}, 0);
|
136
|
-
return;
|
137
|
-
}
|
138
|
-
}
|
143
|
+
claimFocus(firstElement, modalRef, selectorPrimaryFocus);
|
144
|
+
}
|
145
|
+
}, [firstElement, modalRef, open, selectorPrimaryFocus]);
|
146
|
+
useEffect(function () {
|
147
|
+
if (prevOpen && !open && launcherButtonRef) {
|
139
148
|
setTimeout(function () {
|
140
|
-
|
149
|
+
launcherButtonRef.current.focus();
|
141
150
|
}, 0);
|
142
151
|
}
|
143
|
-
}, [
|
152
|
+
}, [launcherButtonRef, open, prevOpen]);
|
144
153
|
var isPrimaryButtonDisabled = function isPrimaryButtonDisabled() {
|
145
154
|
if (loading) {
|
146
155
|
return true;
|
@@ -174,16 +183,18 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
174
183
|
};
|
175
184
|
useEffect(function () {
|
176
185
|
if (editing && editSuccess) {
|
177
|
-
setTitle(
|
186
|
+
setTitle(generateTitle);
|
187
|
+
setSuccessMessage(editSuccessMessage !== null && editSuccessMessage !== void 0 ? editSuccessMessage : editSuccessTitle);
|
178
188
|
} else if (apiKeyLoaded) {
|
179
|
-
setTitle(
|
189
|
+
setTitle(generateTitle);
|
190
|
+
setSuccessMessage(generateSuccessMessage !== null && generateSuccessMessage !== void 0 ? generateSuccessMessage : generateSuccessTitle);
|
180
191
|
} else if (hasSteps) {
|
181
192
|
var _customSteps$currentS2;
|
182
193
|
setTitle((_customSteps$currentS2 = customSteps[currentStep]) === null || _customSteps$currentS2 === void 0 ? void 0 : _customSteps$currentS2.title);
|
183
194
|
} else {
|
184
195
|
setTitle(generateTitle);
|
185
196
|
}
|
186
|
-
}, [apiKeyLoaded, editing, editSuccess, editSuccessTitle, hasSteps, generateSuccessTitle, generateTitle, currentStep, customSteps]);
|
197
|
+
}, [apiKeyLoaded, loading, editing, editSuccess, editSuccessTitle, editSuccessMessage, hasSteps, generateSuccessTitle, generateSuccessMessage, generateTitle, currentStep, customSteps]);
|
187
198
|
var setNameHandler = function setNameHandler(evt) {
|
188
199
|
setName(evt.target.value);
|
189
200
|
};
|
@@ -281,7 +292,9 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
281
292
|
id: apiKeyInputId.current,
|
282
293
|
showPasswordLabel: showAPIKeyLabel,
|
283
294
|
hidePasswordLabel: hideAPIKeyLabel,
|
284
|
-
tooltipPosition: "left"
|
295
|
+
tooltipPosition: "left",
|
296
|
+
helperText: helperText,
|
297
|
+
ref: PasswordInputRef
|
285
298
|
}), !editing && apiKey && !hasAPIKeyVisibilityToggle && /*#__PURE__*/React__default.createElement(TextInput, {
|
286
299
|
value: apiKey,
|
287
300
|
labelText: apiKeyLabel,
|
@@ -309,7 +322,9 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
309
322
|
}, _ErrorFilled || (_ErrorFilled = /*#__PURE__*/React__default.createElement(ErrorFilled, {
|
310
323
|
size: 16
|
311
324
|
}))), /*#__PURE__*/React__default.createElement("p", {
|
312
|
-
className: "".concat(blockClass, "__messaging-text")
|
325
|
+
className: "".concat(blockClass, "__messaging-text"),
|
326
|
+
role: "alert",
|
327
|
+
"aria-live": "assertive"
|
313
328
|
}, copyError ? copyErrorText : errorText)), apiKeyLoaded && /*#__PURE__*/React__default.createElement("div", {
|
314
329
|
className: "".concat(blockClass, "__messaging")
|
315
330
|
}, _InformationFilled || (_InformationFilled = /*#__PURE__*/React__default.createElement(InformationFilled, {
|
@@ -322,8 +337,19 @@ var APIKeyModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
322
337
|
fileType: downloadFileType,
|
323
338
|
downloadLinkLabel: downloadLinkLabel
|
324
339
|
}) : /*#__PURE__*/React__default.createElement("div", {
|
325
|
-
className: "".concat(blockClass, "__messaging-text")
|
326
|
-
|
340
|
+
className: "".concat(blockClass, "__messaging-text"),
|
341
|
+
role: "alert",
|
342
|
+
"aria-live": "assertive"
|
343
|
+
}, generateSuccessBody)), (editSuccess || apiKeyLoaded && successMessage) && /*#__PURE__*/React__default.createElement("div", {
|
344
|
+
className: "".concat(blockClass, "__messaging")
|
345
|
+
}, /*#__PURE__*/React__default.createElement(CheckmarkFilled, {
|
346
|
+
size: 16,
|
347
|
+
className: "".concat(blockClass, "__checkmark-icon")
|
348
|
+
}), /*#__PURE__*/React__default.createElement("p", {
|
349
|
+
className: "".concat(blockClass, "__messaging-text"),
|
350
|
+
role: "alert",
|
351
|
+
"aria-live": "assertive"
|
352
|
+
}, successMessage)))), /*#__PURE__*/React__default.createElement(ModalFooter, {
|
327
353
|
className: "".concat(blockClass, "__footer")
|
328
354
|
}, /*#__PURE__*/React__default.createElement(Button, {
|
329
355
|
type: "button",
|
@@ -357,7 +383,19 @@ var downloadRequiredProps = function downloadRequiredProps(type) {
|
|
357
383
|
|
358
384
|
// Return a placeholder if not released and not enabled by feature flag
|
359
385
|
APIKeyModal = pkg.checkComponentEnabled(APIKeyModal, componentName);
|
360
|
-
|
386
|
+
var deprecatedProps = {
|
387
|
+
/**
|
388
|
+
* deprecated
|
389
|
+
* title for a successful edit
|
390
|
+
*/
|
391
|
+
editSuccessTitle: PropTypes.string,
|
392
|
+
/**
|
393
|
+
* deprecated
|
394
|
+
* title for a successful key generation
|
395
|
+
*/
|
396
|
+
generateSuccessTitle: PropTypes.string
|
397
|
+
};
|
398
|
+
APIKeyModal.propTypes = _objectSpread2({
|
361
399
|
/**
|
362
400
|
* the api key that's displayed to the user when a request to create is fulfilled.
|
363
401
|
*/
|
@@ -415,7 +453,7 @@ APIKeyModal.propTypes = {
|
|
415
453
|
/**
|
416
454
|
* the content that appears that indicates the key is downloadable
|
417
455
|
*/
|
418
|
-
downloadBodyText:
|
456
|
+
downloadBodyText: PropTypes.string,
|
419
457
|
/**
|
420
458
|
* designates the name of downloadable json file with the key. if not specified will default to 'apikey'
|
421
459
|
*/
|
@@ -443,7 +481,7 @@ APIKeyModal.propTypes = {
|
|
443
481
|
/**
|
444
482
|
* title for a successful edit
|
445
483
|
*/
|
446
|
-
|
484
|
+
editSuccessMessage: editRequiredProps(PropTypes.string),
|
447
485
|
/**
|
448
486
|
* designates if the modal is in the edit mode
|
449
487
|
*/
|
@@ -469,7 +507,7 @@ APIKeyModal.propTypes = {
|
|
469
507
|
/**
|
470
508
|
* title for a successful key generation
|
471
509
|
*/
|
472
|
-
|
510
|
+
generateSuccessMessage: PropTypes.string,
|
473
511
|
/**
|
474
512
|
* default title for the modal in generate key mode
|
475
513
|
*/
|
@@ -482,10 +520,19 @@ APIKeyModal.propTypes = {
|
|
482
520
|
* designates if user is able to download the api key
|
483
521
|
*/
|
484
522
|
hasDownloadLink: PropTypes.bool,
|
523
|
+
/**
|
524
|
+
* helper text for password input
|
525
|
+
*/
|
526
|
+
helperText: PropTypes.string,
|
485
527
|
/**
|
486
528
|
* label text that's displayed when hovering over visibility toggler to hide key
|
487
529
|
*/
|
488
530
|
hideAPIKeyLabel: PropTypes.string,
|
531
|
+
/**
|
532
|
+
* Provide a ref to return focus to once the tearsheet is closed.
|
533
|
+
*/
|
534
|
+
/**@ts-ignore */
|
535
|
+
launcherButtonRef: PropTypes.any,
|
489
536
|
/**
|
490
537
|
* designates if the modal is in a loading state via a request or some other in progress operation
|
491
538
|
*/
|
@@ -556,7 +603,7 @@ APIKeyModal.propTypes = {
|
|
556
603
|
* label text that's displayed when hovering over visibility toggler to show key
|
557
604
|
*/
|
558
605
|
showAPIKeyLabel: PropTypes.string
|
559
|
-
};
|
606
|
+
}, deprecatedProps);
|
560
607
|
APIKeyModal.displayName = componentName;
|
561
608
|
|
562
|
-
export { APIKeyModal };
|
609
|
+
export { APIKeyModal, deprecatedProps };
|
@@ -4,7 +4,7 @@
|
|
4
4
|
* This source code is licensed under the Apache-2.0 license found in the
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
6
6
|
*/
|
7
|
-
import { ReactNode } from 'react';
|
7
|
+
import { ReactNode, RefObject } from 'react';
|
8
8
|
interface APIKeyModalCommonProps {
|
9
9
|
/**
|
10
10
|
* the api key that's displayed to the user when a request to create is fulfilled.
|
@@ -73,9 +73,14 @@ interface APIKeyModalCommonProps {
|
|
73
73
|
*/
|
74
74
|
generateSuccessBody?: ReactNode;
|
75
75
|
/**
|
76
|
+
* * @deprecated use `generateSuccessMessage` instead
|
76
77
|
* title for a successful key generation
|
77
78
|
*/
|
78
79
|
generateSuccessTitle?: string;
|
80
|
+
/**
|
81
|
+
* success message for a successful key generation
|
82
|
+
*/
|
83
|
+
generateSuccessMessage?: string;
|
79
84
|
/**
|
80
85
|
* default title for the modal in generate key mode
|
81
86
|
*/
|
@@ -92,6 +97,10 @@ interface APIKeyModalCommonProps {
|
|
92
97
|
* label text that's displayed when hovering over visibility toggler to hide key
|
93
98
|
*/
|
94
99
|
hideAPIKeyLabel?: string;
|
100
|
+
/**
|
101
|
+
* Provide a ref to return focus to once the tearsheet is closed.
|
102
|
+
*/
|
103
|
+
launcherButtonRef?: RefObject<any>;
|
95
104
|
/**
|
96
105
|
* designates if the modal is in a loading state via a request or some other in progress operation
|
97
106
|
*/
|
@@ -154,6 +163,10 @@ interface APIKeyModalCommonProps {
|
|
154
163
|
* label text that's displayed when hovering over visibility toggler to show key
|
155
164
|
*/
|
156
165
|
showAPIKeyLabel?: string;
|
166
|
+
/**
|
167
|
+
* helper text for password input
|
168
|
+
*/
|
169
|
+
helperText?: string;
|
157
170
|
}
|
158
171
|
type CustomStepConditionalProps = {
|
159
172
|
/**
|
@@ -187,9 +200,14 @@ type EditingConditionalProps = {
|
|
187
200
|
*/
|
188
201
|
editSuccess: boolean;
|
189
202
|
/**
|
203
|
+
* * @deprecated use `editSuccessMessage` instead
|
190
204
|
* title for a successful edit
|
191
205
|
*/
|
192
|
-
editSuccessTitle
|
206
|
+
editSuccessTitle?: string;
|
207
|
+
/**
|
208
|
+
* success message for edit
|
209
|
+
*/
|
210
|
+
editSuccessMessage: string;
|
193
211
|
};
|
194
212
|
type HasDownloadLinkProps = {
|
195
213
|
/**
|
@@ -199,7 +217,7 @@ type HasDownloadLinkProps = {
|
|
199
217
|
/**
|
200
218
|
* the content that appears that indicates the key is downloadable
|
201
219
|
*/
|
202
|
-
downloadBodyText
|
220
|
+
downloadBodyText?: string;
|
203
221
|
/**
|
204
222
|
* designates the name of downloadable json file with the key. if not specified will default to 'apikey'
|
205
223
|
*/
|
@@ -11,7 +11,7 @@ import React__default, { useRef, useEffect } from 'react';
|
|
11
11
|
import PropTypes from '../../_virtual/index.js';
|
12
12
|
import cx from 'classnames';
|
13
13
|
import { getDevtoolsProps } from '../../global/js/utils/devtools.js';
|
14
|
-
import { useFocus } from '../../global/js/hooks/useFocus.js';
|
14
|
+
import { useFocus, claimFocus } from '../../global/js/hooks/useFocus.js';
|
15
15
|
import { pkg } from '../../settings.js';
|
16
16
|
import { usePortalTarget } from '../../global/js/hooks/usePortalTarget.js';
|
17
17
|
import uuidv4 from '../../global/js/utils/uuidv4.js';
|
@@ -62,12 +62,9 @@ var AboutModal = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
|
|
62
62
|
}, [bodyRef]);
|
63
63
|
useEffect(function () {
|
64
64
|
if (open) {
|
65
|
-
|
66
|
-
return firstElement === null || firstElement === void 0 ? void 0 : firstElement.focus();
|
67
|
-
}, 0);
|
65
|
+
claimFocus(firstElement, modalRef);
|
68
66
|
}
|
69
|
-
|
70
|
-
}, [open]);
|
67
|
+
}, [firstElement, modalRef, open]);
|
71
68
|
return renderPortalUse( /*#__PURE__*/React__default.createElement(unstable_FeatureFlags, {
|
72
69
|
enableExperimentalFocusWrapWithoutSentinels: true
|
73
70
|
}, /*#__PURE__*/React__default.createElement(ComposedModal, _extends({}, rest, {
|
@@ -10,7 +10,7 @@ import React__default, { useState, useRef, useEffect } from 'react';
|
|
10
10
|
import PropTypes from '../../_virtual/index.js';
|
11
11
|
import cx from 'classnames';
|
12
12
|
import { useResizeObserver } from '../../global/js/hooks/useResizeObserver.js';
|
13
|
-
import { usePrefix, Breadcrumb, BreadcrumbItem, OverflowMenu, Link, Tooltip,
|
13
|
+
import { usePrefix, Breadcrumb, BreadcrumbItem, OverflowMenu, Link, Tooltip, unstable_FeatureFlags, MenuItem } from '@carbon/react';
|
14
14
|
import { pkg } from '../../settings.js';
|
15
15
|
import { OverflowMenuHorizontal, ArrowLeft } from '@carbon/react/icons';
|
16
16
|
import uuidv4 from '../../global/js/utils/uuidv4.js';
|
@@ -61,12 +61,20 @@ var BreadcrumbWithOverflow = function BreadcrumbWithOverflow(_ref) {
|
|
61
61
|
// eslint-disable-next-line react/prop-types
|
62
62
|
var BreadcrumbOverflowMenu = function BreadcrumbOverflowMenu(_ref2) {
|
63
63
|
var overflowItems = _ref2.overflowItems;
|
64
|
+
var handleClick = function handleClick(evt, item) {
|
65
|
+
var _item$props, _item$props2, _item$props2$onClick;
|
66
|
+
if (item !== null && item !== void 0 && (_item$props = item.props) !== null && _item$props !== void 0 && _item$props.href) {
|
67
|
+
window.location.href = item.props.href;
|
68
|
+
}
|
69
|
+
item === null || item === void 0 || (_item$props2 = item.props) === null || _item$props2 === void 0 || (_item$props2$onClick = _item$props2.onClick) === null || _item$props2$onClick === void 0 || _item$props2$onClick.call(_item$props2, evt);
|
70
|
+
};
|
64
71
|
return /*#__PURE__*/React__default.createElement(BreadcrumbItem, {
|
65
72
|
key: "breadcrumb-overflow-".concat(internalId.current)
|
73
|
+
}, /*#__PURE__*/React__default.createElement(unstable_FeatureFlags, {
|
74
|
+
enableV12Overflowmenu: true
|
66
75
|
}, /*#__PURE__*/React__default.createElement(OverflowMenu, {
|
67
|
-
align: overflowTooltipAlign,
|
68
76
|
"aria-label": overflowAriaLabel,
|
69
|
-
|
77
|
+
label: overflowAriaLabel // also needs setting to avoid a11y "Accessible name does not match or contain the visible label text"
|
70
78
|
,
|
71
79
|
renderIcon: function renderIcon(props) {
|
72
80
|
return /*#__PURE__*/React__default.createElement(OverflowMenuHorizontal, _extends({
|
@@ -74,17 +82,18 @@ var BreadcrumbWithOverflow = function BreadcrumbWithOverflow(_ref) {
|
|
74
82
|
}, props));
|
75
83
|
},
|
76
84
|
className: "".concat(blockClass, "__overflow-menu"),
|
77
|
-
|
85
|
+
tooltipAlignment: overflowTooltipAlign
|
78
86
|
},
|
79
87
|
// eslint-disable-next-line react/prop-types
|
80
88
|
overflowItems.map(function (item, index) {
|
81
|
-
return /*#__PURE__*/React__default.createElement(
|
89
|
+
return /*#__PURE__*/React__default.createElement(MenuItem, {
|
82
90
|
key: "breadcrumb-overflow-menu-item-".concat(internalId.current, "-").concat(index),
|
83
|
-
|
84
|
-
|
85
|
-
|
91
|
+
onClick: function onClick(evt) {
|
92
|
+
return handleClick(evt, item);
|
93
|
+
},
|
94
|
+
label: item.props.children
|
86
95
|
});
|
87
|
-
})));
|
96
|
+
}))));
|
88
97
|
};
|
89
98
|
|
90
99
|
// create hidden sizing items
|
@@ -58,13 +58,13 @@ interface CardProp extends PropsWithChildren {
|
|
58
58
|
iconDescription?: string;
|
59
59
|
/**
|
60
60
|
* Clickable tiles only accept a boolean value of true and display a hollow slug.
|
61
|
-
* @deprecated please use the `
|
61
|
+
* @deprecated please use the `decorator` prop
|
62
62
|
*/
|
63
63
|
slug?: ReactNode | boolean;
|
64
64
|
/**
|
65
|
-
* Optional prop that
|
65
|
+
* Optional prop that allows you to pass any component.
|
66
66
|
*/
|
67
|
-
|
67
|
+
decorator?: ReactNode | boolean;
|
68
68
|
status?: 'complete' | 'incomplete';
|
69
69
|
title?: ReactNode;
|
70
70
|
titleSize?: 'default' | 'large';
|
@@ -16,7 +16,7 @@ import { CardFooter } from './CardFooter.js';
|
|
16
16
|
import { pkg } from '../../settings.js';
|
17
17
|
|
18
18
|
var _Incomplete, _CheckmarkOutline;
|
19
|
-
var _excluded = ["actionIcons", "actionsPlacement", "
|
19
|
+
var _excluded = ["actionIcons", "actionsPlacement", "decorator", "metadata", "children", "className", "clickZone", "description", "disabled", "footerActionIcon", "getStarted", "label", "media", "mediaPosition", "onClick", "onKeyDown", "onPrimaryButtonClick", "onSecondaryButtonClick", "overflowActions", "overflowAriaLabel", "pictogram", "primaryButtonDisabled", "primaryButtonHref", "primaryButtonIcon", "primaryButtonKind", "primaryButtonPlacement", "primaryButtonText", "productive", "secondaryButtonDisabled", "secondaryButtonHref", "secondaryButtonIcon", "secondaryButtonKind", "secondaryButtonPlacement", "secondaryButtonText", "slug", "status", "sequence", "title", "titleSize", "iconDescription"],
|
20
20
|
_excluded2 = ["id", "itemText"],
|
21
21
|
_excluded3 = ["id", "icon", "onClick", "iconDescription", "href"];
|
22
22
|
var componentName = 'Card';
|
@@ -25,7 +25,7 @@ var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
25
25
|
actionIcons = _ref$actionIcons === void 0 ? Object.freeze([]) : _ref$actionIcons,
|
26
26
|
_ref$actionsPlacement = _ref.actionsPlacement,
|
27
27
|
actionsPlacement = _ref$actionsPlacement === void 0 ? 'bottom' : _ref$actionsPlacement,
|
28
|
-
|
28
|
+
decorator = _ref.decorator,
|
29
29
|
_ref$metadata = _ref.metadata,
|
30
30
|
metadata = _ref$metadata === void 0 ? Object.freeze([]) : _ref$metadata,
|
31
31
|
children = _ref.children,
|
@@ -43,10 +43,10 @@ var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
43
43
|
onClick = _ref.onClick,
|
44
44
|
onKeyDown = _ref.onKeyDown,
|
45
45
|
onPrimaryButtonClick = _ref.onPrimaryButtonClick,
|
46
|
+
onSecondaryButtonClick = _ref.onSecondaryButtonClick,
|
46
47
|
_ref$overflowActions = _ref.overflowActions,
|
47
48
|
overflowActions = _ref$overflowActions === void 0 ? Object.freeze([]) : _ref$overflowActions,
|
48
49
|
overflowAriaLabel = _ref.overflowAriaLabel,
|
49
|
-
onSecondaryButtonClick = _ref.onSecondaryButtonClick,
|
50
50
|
Pictogram = _ref.pictogram,
|
51
51
|
primaryButtonDisabled = _ref.primaryButtonDisabled,
|
52
52
|
primaryButtonHref = _ref.primaryButtonHref,
|
@@ -105,8 +105,7 @@ var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
105
105
|
autoAlign: true,
|
106
106
|
menuAlignment: pos,
|
107
107
|
size: size,
|
108
|
-
|
109
|
-
label: iconDescription
|
108
|
+
label: overflowAriaLabel || iconDescription
|
110
109
|
}, overflowActions.map(function (_ref2) {
|
111
110
|
var id = _ref2.id,
|
112
111
|
itemText = _ref2.itemText,
|
@@ -168,10 +167,11 @@ var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
168
167
|
return icons;
|
169
168
|
};
|
170
169
|
var getCardProps = function getCardProps() {
|
170
|
+
var _decorator$type, _decorator$type2;
|
171
171
|
var clickable = hasClickEvent && !productive || hasClickEvent && productive && clickZone === 'one';
|
172
172
|
var cardProps = _objectSpread2(_objectSpread2({}, rest), {}, {
|
173
173
|
ref: ref,
|
174
|
-
className: cx(blockClass, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__disabled"), disabled), "".concat(blockClass, "__get-started"), getStarted), "".concat(blockClass, "__productive"), productive), "".concat(blockClass, "__clickable"), clickable), "".concat(blockClass, "__media-left"), mediaPosition === 'left'), "".concat(blockClass, "--has-slug"), !!slug), "".concat(blockClass, "--has-ai-label"), !!
|
174
|
+
className: cx(blockClass, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__disabled"), disabled), "".concat(blockClass, "__get-started"), getStarted), "".concat(blockClass, "__productive"), productive), "".concat(blockClass, "__clickable"), clickable), "".concat(blockClass, "__media-left"), mediaPosition === 'left'), "".concat(blockClass, "--has-slug"), !!slug), "".concat(blockClass, "--has-decorator"), !!decorator && ((_decorator$type = decorator['type']) === null || _decorator$type === void 0 ? void 0 : _decorator$type.displayName) !== 'AILabel'), "".concat(blockClass, "--has-ai-label"), !!decorator && ((_decorator$type2 = decorator['type']) === null || _decorator$type2 === void 0 ? void 0 : _decorator$type2.displayName) === 'AILabel'), className)
|
175
175
|
}, clickable && clickableProps);
|
176
176
|
return cardProps;
|
177
177
|
};
|
@@ -187,7 +187,7 @@ var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
187
187
|
var getHeaderProps = function getHeaderProps() {
|
188
188
|
return {
|
189
189
|
actions: actionsPlacement === 'top' ? getActions() : '',
|
190
|
-
|
190
|
+
decorator: decorator,
|
191
191
|
noActionIcons: getIcons().length > 0 && actionsPlacement === 'top' ? false : true,
|
192
192
|
actionsPlacement: actionsPlacement,
|
193
193
|
onPrimaryButtonClick: onPrimaryButtonClick,
|
@@ -271,13 +271,13 @@ Card.propTypes = {
|
|
271
271
|
href: PropTypes.string
|
272
272
|
})),
|
273
273
|
actionsPlacement: PropTypes.oneOf(['top', 'bottom']),
|
274
|
-
/**
|
275
|
-
* Optional prop that is intended for any scenario where something is being generated by AI to reinforce AI transparency, accountability, and explainability at the UI level.
|
276
|
-
*/
|
277
|
-
aiLabel: PropTypes.oneOfType([PropTypes.node, PropTypes.bool]),
|
278
274
|
children: PropTypes.node,
|
279
275
|
className: PropTypes.string,
|
280
276
|
clickZone: PropTypes.oneOf(['one', 'two', 'three']),
|
277
|
+
/**
|
278
|
+
* Optional prop that allows you to pass any component.
|
279
|
+
*/
|
280
|
+
decorator: PropTypes.oneOfType([PropTypes.node, PropTypes.bool]),
|
281
281
|
/**@ts-ignore */
|
282
282
|
description: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
|
283
283
|
disabled: PropTypes.bool,
|
@@ -326,7 +326,7 @@ Card.propTypes = {
|
|
326
326
|
/**
|
327
327
|
* **Experimental:** For all cases a `Slug` component can be provided.
|
328
328
|
* Clickable tiles only accept a boolean value of true and display a hollow slug.
|
329
|
-
* @deprecated please use the `
|
329
|
+
* @deprecated please use the `decorator` prop
|
330
330
|
*/
|
331
331
|
slug: PropTypes.oneOfType([PropTypes.node, PropTypes.bool]),
|
332
332
|
status: PropTypes.oneOf(['complete', 'incomplete']),
|
@@ -3,9 +3,9 @@ import PropTypes from 'prop-types';
|
|
3
3
|
interface CardHeaderProps {
|
4
4
|
actions?: ReactNode;
|
5
5
|
/**
|
6
|
-
* Optional prop that
|
6
|
+
* Optional prop that allows you to pass any component.
|
7
7
|
*/
|
8
|
-
|
8
|
+
decorator?: ReactNode | boolean;
|
9
9
|
description?: ReactNode;
|
10
10
|
hasActions?: boolean;
|
11
11
|
/**
|
@@ -29,21 +29,21 @@ interface CardHeaderProps {
|
|
29
29
|
/**
|
30
30
|
* **Experimental:** For all cases a `Slug` component can be provided.
|
31
31
|
* Clickable tiles only accept a boolean value of true and display a hollow slug.
|
32
|
-
* @deprecated please use the `
|
32
|
+
* @deprecated please use the `decorator` prop
|
33
33
|
*/
|
34
34
|
slug?: ReactNode;
|
35
35
|
title?: ReactNode;
|
36
36
|
titleSize?: 'default' | 'large';
|
37
37
|
}
|
38
38
|
export declare const CardHeader: {
|
39
|
-
({ actions,
|
39
|
+
({ actions, decorator, noActionIcons, onPrimaryButtonClick, onSecondaryButtonClick, primaryButtonIcon, primaryButtonPlacement, primaryButtonText, primaryButtonDisabled, description, hasActions, inClickableCard, label, secondaryButtonDisabled, secondaryButtonHref, secondaryButtonIcon, secondaryButtonPlacement, secondaryButtonText, slug, title, titleSize, }: CardHeaderProps): React.JSX.Element;
|
40
40
|
/**@ts-ignore */
|
41
41
|
propTypes: {
|
42
42
|
actions: PropTypes.Requireable<NonNullable<any[] | PropTypes.ReactNodeLike>>;
|
43
43
|
/**
|
44
|
-
* Optional prop that
|
44
|
+
* Optional prop that allows you to pass any component.
|
45
45
|
*/
|
46
|
-
|
46
|
+
decorator: PropTypes.Requireable<NonNullable<PropTypes.ReactNodeLike>>;
|
47
47
|
description: PropTypes.Requireable<NonNullable<object | PropTypes.ReactNodeLike>>;
|
48
48
|
hasActions: PropTypes.Requireable<boolean>;
|
49
49
|
/**
|
@@ -67,7 +67,7 @@ export declare const CardHeader: {
|
|
67
67
|
/**
|
68
68
|
* **Experimental:** For all cases a `Slug` component can be provided.
|
69
69
|
* Clickable tiles only accept a boolean value of true and display a hollow slug.
|
70
|
-
* @deprecated please use the `
|
70
|
+
* @deprecated please use the `decorator` prop
|
71
71
|
*/
|
72
72
|
slug: PropTypes.Requireable<NonNullable<PropTypes.ReactNodeLike>>;
|
73
73
|
title: PropTypes.Requireable<NonNullable<object | PropTypes.ReactNodeLike>>;
|