@carbon/ibm-products 2.61.0 → 2.62.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/css/index-full-carbon.css +170 -22
- 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 +170 -22
- 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 +170 -22
- 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 +170 -22
- 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 +4 -4
- package/es/components/APIKeyModal/APIKeyDownloader.js +2 -2
- package/es/components/APIKeyModal/APIKeyModal.js +16 -16
- package/es/components/AboutModal/AboutModal.js +1 -1
- package/es/components/ActionBar/ActionBar.js +5 -5
- package/es/components/ActionBar/ActionBarOverflowItems.js +3 -3
- package/es/components/ActionSet/ActionSet.js +5 -5
- package/es/components/AddSelect/AddSelect.js +5 -4
- package/es/components/AddSelect/AddSelectBody.js +12 -11
- package/es/components/AddSelect/AddSelectColumn.js +1 -1
- package/es/components/AddSelect/AddSelectFilter.js +1 -1
- package/es/components/AddSelect/AddSelectMetaPanel.js +3 -3
- package/es/components/AddSelect/AddSelectRow.js +21 -13
- package/es/components/AddSelect/AddSelectSidebar.js +14 -4
- package/es/components/AddSelect/AddSelectSort.js +5 -5
- package/es/components/AddSelect/add-select-utils.js +3 -3
- package/es/components/AddSelect/types/index.d.ts +1 -0
- package/es/components/BigNumbers/BigNumbers.js +11 -11
- package/es/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +4 -4
- package/es/components/ButtonSetWithOverflow/ButtonSetWithOverflow.js +4 -4
- package/es/components/Card/Card.js +14 -14
- package/es/components/Card/CardFooter.js +4 -4
- package/es/components/Card/CardHeader.js +2 -2
- package/es/components/Carousel/Carousel.js +16 -16
- package/es/components/Cascade/Cascade.js +2 -2
- package/es/components/Checklist/Checklist.js +11 -11
- package/es/components/Checklist/ChecklistChart.js +1 -1
- package/es/components/Checklist/ChecklistIcon.js +1 -1
- package/es/components/Coachmark/Coachmark.js +10 -10
- package/es/components/Coachmark/CoachmarkDragbar.js +5 -5
- package/es/components/Coachmark/CoachmarkHeader.js +4 -4
- package/es/components/Coachmark/CoachmarkOverlay.js +4 -4
- package/es/components/Coachmark/CoachmarkTagline.js +3 -3
- package/es/components/CoachmarkBeacon/CoachmarkBeacon.js +1 -1
- package/es/components/CoachmarkFixed/CoachmarkFixed.js +6 -6
- package/es/components/CoachmarkOverlayElements/CoachmarkOverlayElements.d.ts +0 -10
- package/es/components/CoachmarkOverlayElements/CoachmarkOverlayElements.js +16 -35
- package/es/components/CoachmarkStack/CoachmarkStack.d.ts +2 -13
- package/es/components/CoachmarkStack/CoachmarkStack.js +12 -22
- package/es/components/CoachmarkStack/CoachmarkStackHome.d.ts +0 -17
- package/es/components/CoachmarkStack/CoachmarkStackHome.js +6 -29
- package/es/components/ConditionBuilder/ConditionBlock/ConditionBlock.js +12 -12
- package/es/components/ConditionBuilder/ConditionBuilder.js +2 -2
- package/es/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.js +5 -5
- package/es/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.js +2 -2
- package/es/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.js +1 -1
- package/es/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.js +3 -3
- package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +19 -19
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.js +7 -7
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.js +2 -2
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.js +3 -3
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +6 -6
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOptionForValueField.js +6 -6
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.js +1 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.js +3 -3
- package/es/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.js +31 -31
- package/es/components/ConditionBuilder/utils/handleKeyboardEvents.js +15 -15
- package/es/components/ConditionBuilder/utils/useDataConfigs.js +1 -1
- package/es/components/ConditionBuilder/utils/useTranslations.js +2 -2
- package/es/components/ConditionBuilder/utils/util.js +13 -13
- package/es/components/CreateFullPage/CreateFullPage.js +3 -3
- package/es/components/CreateFullPage/CreateFullPageStep.js +9 -9
- package/es/components/CreateInfluencer/CreateInfluencer.js +8 -8
- package/es/components/CreateModal/CreateModal.js +1 -1
- package/es/components/CreateSidePanel/CreateSidePanel.js +1 -1
- package/es/components/CreateTearsheet/CreateTearsheet.js +4 -4
- package/es/components/CreateTearsheet/CreateTearsheetStep.js +16 -16
- package/es/components/CreateTearsheetNarrow/CreateTearsheetNarrow.js +1 -1
- package/es/components/DataSpreadsheet/DataSpreadsheet.js +52 -52
- package/es/components/DataSpreadsheet/DataSpreadsheetBody.js +36 -36
- package/es/components/DataSpreadsheet/DataSpreadsheetHeader.js +26 -26
- package/es/components/DataSpreadsheet/hooks/useMoveActiveCell.js +3 -3
- package/es/components/DataSpreadsheet/hooks/useMultipleKeyTracking.js +3 -3
- package/es/components/DataSpreadsheet/hooks/useResetSpreadsheetFocus.js +1 -1
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetEdit.js +16 -16
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseMove.js +5 -5
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.js +8 -8
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetOutsideClick.js +1 -1
- package/es/components/DataSpreadsheet/utils/checkActiveHeaderCell.js +3 -3
- package/es/components/DataSpreadsheet/utils/checkSelectedHeaderCell.js +5 -5
- package/es/components/DataSpreadsheet/utils/commonEventHandlers.js +3 -3
- package/es/components/DataSpreadsheet/utils/createActiveCellFn.js +10 -10
- package/es/components/DataSpreadsheet/utils/createCellSelectionArea.js +1 -1
- package/es/components/DataSpreadsheet/utils/getSpreadsheetWidth.js +1 -1
- package/es/components/DataSpreadsheet/utils/handleActiveCellInSelectionEnter.js +6 -6
- package/es/components/DataSpreadsheet/utils/handleActiveCellInSelectionTab.js +6 -6
- package/es/components/DataSpreadsheet/utils/handleCellDeletion.js +6 -6
- package/es/components/DataSpreadsheet/utils/handleEditSubmit.js +3 -3
- package/es/components/DataSpreadsheet/utils/handleHeaderCellSelection.js +10 -10
- package/es/components/DataSpreadsheet/utils/handleMultipleKeys.js +14 -14
- package/es/components/DataSpreadsheet/utils/moveColumnIndicatorLine.js +4 -4
- package/es/components/DataSpreadsheet/utils/removeCellSelections.js +1 -1
- package/es/components/Datagrid/Datagrid/Datagrid.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridBody.js +1 -1
- package/es/components/Datagrid/Datagrid/DatagridContent.js +14 -14
- package/es/components/Datagrid/Datagrid/DatagridEmptyBody.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridExpandedRow.js +3 -3
- package/es/components/Datagrid/Datagrid/DatagridHead.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridHeaderRow.js +23 -23
- package/es/components/Datagrid/Datagrid/DatagridRefBody.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridRow.js +19 -19
- package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +9 -9
- package/es/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +7 -7
- package/es/components/Datagrid/Datagrid/DatagridSimpleBody.js +1 -1
- package/es/components/Datagrid/Datagrid/DatagridToolbar.js +11 -11
- package/es/components/Datagrid/Datagrid/DatagridVirtualBody.js +18 -18
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +9 -9
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +15 -15
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.d.ts +1 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +59 -44
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/OverflowCheckboxes.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/constants.js +1 -5
- package/es/components/Datagrid/Datagrid/addons/Filtering/handleCheckboxChange.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +20 -20
- package/es/components/Datagrid/Datagrid/addons/Filtering/utils.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +35 -35
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/returnUpdatedActiveCell.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +6 -6
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleMultipleKeys.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +5 -5
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/stateReducer.js +4 -4
- package/es/components/Datagrid/useActionsColumn.js +2 -2
- package/es/components/Datagrid/useColumnRightAlign.js +3 -3
- package/es/components/Datagrid/useCustomizeColumns.js +1 -1
- package/es/components/Datagrid/useDatagrid.js +2 -2
- package/es/components/Datagrid/useDefaultStringRenderer.js +1 -1
- package/es/components/Datagrid/useDisableSelectRows.js +16 -16
- package/es/components/Datagrid/useExpandedRow.js +1 -1
- package/es/components/Datagrid/useFiltering.js +1 -1
- package/es/components/Datagrid/useFloatingScroll.js +2 -2
- package/es/components/Datagrid/useFocusRowExpander.js +4 -4
- package/es/components/Datagrid/useInfiniteScroll.js +1 -1
- package/es/components/Datagrid/useInitialColumnSort.js +1 -1
- package/es/components/Datagrid/useInlineEdit.js +4 -4
- package/es/components/Datagrid/useNestedRowExpander.js +6 -6
- package/es/components/Datagrid/useNestedRows.js +6 -6
- package/es/components/Datagrid/useOnRowClick.js +1 -1
- package/es/components/Datagrid/useRowExpander.js +4 -4
- package/es/components/Datagrid/useRowIsMouseOver.js +1 -1
- package/es/components/Datagrid/useRowRenderer.js +6 -6
- package/es/components/Datagrid/useSelectAllToggle.js +2 -2
- package/es/components/Datagrid/useSelectRows.js +5 -5
- package/es/components/Datagrid/useSortableColumns.js +11 -11
- package/es/components/Datagrid/useStickyColumn.js +8 -8
- package/es/components/DecoratorBase/DecoratorBase.js +8 -8
- package/es/components/DecoratorBase/DecoratorIcon.js +2 -2
- package/es/components/DelimitedList/DelimitedList.js +3 -3
- package/es/components/DescriptionList/DescriptionList.js +2 -2
- package/es/components/EditInPlace/EditInPlace.js +6 -6
- package/es/components/EditSidePanel/EditSidePanel.js +3 -3
- package/es/components/EditTearsheet/EditTearsheet.js +3 -3
- package/es/components/EditTearsheet/EditTearsheetForm.js +2 -2
- package/es/components/EmptyStates/EmptyState.js +5 -5
- package/es/components/EmptyStates/EmptyStateContent.js +2 -2
- package/es/components/EmptyStates/EmptyStateV2.js +2 -2
- package/es/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +3 -3
- package/es/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +3 -3
- package/es/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +3 -3
- package/es/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +3 -3
- package/es/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +3 -3
- package/es/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +3 -3
- package/es/components/ExportModal/ExportModal.js +7 -7
- package/es/components/FeatureFlags/index.js +1 -1
- package/es/components/FilterPanel/FilterPanelAccordion/FilterPanelAccordion.js +1 -1
- package/es/components/FilterPanel/FilterPanelAccordionItem/FilterPanelAccordionItem.js +2 -2
- package/es/components/FilterPanel/FilterPanelCheckboxWithOverflow/FilterPanelCheckboxWithOverflow.js +8 -8
- package/es/components/FilterPanel/FilterPanelSearch/FilterPanelSearch.js +1 -1
- package/es/components/FilterSummary/FilterSummary.js +18 -34
- package/es/components/FullPageError/FullPageError.js +1 -1
- package/es/components/Guidebanner/Guidebanner.js +8 -8
- package/es/components/Guidebanner/GuidebannerElementButton.js +1 -1
- package/es/components/ImportModal/ImportModal.js +2 -2
- package/es/components/InlineTip/InlineTip.d.ts +0 -14
- package/es/components/InlineTip/InlineTip.js +13 -35
- package/es/components/InlineTip/utils.js +1 -1
- package/es/components/InterstitialScreen/InterstitialScreen.d.ts +0 -26
- package/es/components/InterstitialScreen/InterstitialScreen.js +22 -56
- package/es/components/MultiAddSelect/MultiAddSelect.d.ts +4 -0
- package/es/components/MultiAddSelect/MultiAddSelect.js +2 -1
- package/es/components/Nav/Nav.js +3 -3
- package/es/components/Nav/NavItem.js +8 -9
- package/es/components/Nav/NavList.js +14 -15
- package/es/components/NonLinearReading/NonLinearReading.js +1 -1
- package/es/components/NotificationsPanel/NotificationsPanel.d.ts +53 -1
- package/es/components/NotificationsPanel/NotificationsPanel.js +89 -71
- package/es/components/OptionsTile/OptionsTile.js +4 -3
- package/es/components/PageHeader/PageHeader.js +19 -19
- package/es/components/PageHeader/PageHeaderTitle.js +1 -1
- package/es/components/PageHeader/PageHeaderUtils.js +1 -1
- package/es/components/ProductiveCard/ProductiveCard.js +1 -1
- package/es/components/RemoveModal/RemoveModal.js +2 -2
- package/es/components/Saving/Saving.js +4 -4
- package/es/components/ScrollGradient/ScrollGradient.js +6 -6
- package/es/components/SearchBar/SearchBar.js +6 -6
- package/es/components/SidePanel/SidePanel.js +45 -45
- package/es/components/SimpleHeader/SimpleHeader.js +4 -4
- package/es/components/StatusIcon/StatusIcon.js +1 -1
- package/es/components/StatusIndicator/StatusIndicator.js +2 -2
- package/es/components/StatusIndicator/StatusIndicatorStep.js +1 -1
- package/es/components/StringFormatter/StringFormatter.js +4 -4
- package/es/components/TagOverflow/TagOverflow.js +7 -7
- package/es/components/TagOverflow/TagOverflowModal.js +4 -4
- package/es/components/TagOverflow/TagOverflowPopover.js +13 -13
- package/es/components/TagSet/TagSet.js +15 -15
- package/es/components/TagSet/TagSetModal.js +6 -6
- package/es/components/TagSet/TagSetOverflow.js +3 -3
- package/es/components/Tearsheet/Tearsheet.js +2 -2
- package/es/components/Tearsheet/TearsheetNarrow.js +1 -1
- package/es/components/Tearsheet/TearsheetShell.js +6 -6
- package/es/components/Toolbar/Toolbar.js +6 -6
- package/es/components/Toolbar/ToolbarButton.js +4 -4
- package/es/components/TruncatedList/TruncatedList.js +8 -8
- package/es/components/UserAvatar/UserAvatar.js +4 -4
- package/es/components/UserProfileImage/UserProfileImage.js +2 -2
- package/es/components/WebTerminal/WebTerminal.js +8 -8
- package/es/global/js/hooks/useControllableState.js +1 -1
- package/es/global/js/hooks/useCreateComponentFocus.js +1 -1
- package/es/global/js/hooks/useCreateComponentStepChange.js +10 -10
- package/es/global/js/hooks/useFocus.js +19 -19
- package/es/global/js/hooks/useOverflowItems/index.d.ts +7 -0
- package/es/global/js/hooks/{useOverflowItems.js → useOverflowItems/useOverflowItems.js} +16 -16
- package/es/global/js/hooks/useOverflowString.js +6 -6
- package/es/global/js/hooks/usePresence.d.ts +23 -0
- package/es/global/js/hooks/usePresence.js +26 -6
- package/es/global/js/hooks/useResetCreateComponent.js +1 -1
- package/es/global/js/hooks/useResizeObserver.js +5 -5
- package/es/global/js/hooks/useRetrieveStepData.js +1 -1
- package/es/global/js/package-settings.js +4 -4
- package/es/global/js/utils/Wrap.js +2 -2
- package/es/global/js/utils/checkForOverflow.js +1 -1
- package/es/global/js/utils/debounce.d.ts +1 -1
- package/es/global/js/utils/debounce.js +2 -2
- package/es/global/js/utils/getSupportedLocale.d.ts +2 -0
- package/es/global/js/utils/getSupportedLocale.js +2 -0
- package/es/global/js/utils/lastIndexInArray.js +1 -1
- package/es/global/js/utils/props-helper.js +1 -1
- package/es/node_modules/@carbon/icon-helpers/es/index.js +2 -2
- package/es/node_modules/@carbon/icons-react/es/Icon.js +2 -2
- package/es/node_modules/@carbon/icons-react/es/generated/bucket-10.js +894 -863
- package/es/node_modules/@carbon/icons-react/es/generated/bucket-3.js +824 -823
- package/es/node_modules/prop-types/factoryWithTypeCheckers.js +1 -1
- package/es/settings.js +2 -2
- package/lib/_virtual/_rollupPluginBabelHelpers.js +4 -4
- package/lib/components/APIKeyModal/APIKeyDownloader.js +2 -2
- package/lib/components/APIKeyModal/APIKeyModal.js +16 -16
- package/lib/components/AboutModal/AboutModal.js +1 -1
- package/lib/components/ActionBar/ActionBar.js +5 -5
- package/lib/components/ActionBar/ActionBarOverflowItems.js +3 -3
- package/lib/components/ActionSet/ActionSet.js +5 -5
- package/lib/components/AddSelect/AddSelect.js +5 -4
- package/lib/components/AddSelect/AddSelectBody.js +12 -11
- package/lib/components/AddSelect/AddSelectColumn.js +1 -1
- package/lib/components/AddSelect/AddSelectFilter.js +1 -1
- package/lib/components/AddSelect/AddSelectMetaPanel.js +3 -3
- package/lib/components/AddSelect/AddSelectRow.js +20 -12
- package/lib/components/AddSelect/AddSelectSidebar.js +14 -4
- package/lib/components/AddSelect/AddSelectSort.js +5 -5
- package/lib/components/AddSelect/add-select-utils.js +3 -3
- package/lib/components/AddSelect/types/index.d.ts +1 -0
- package/lib/components/BigNumbers/BigNumbers.js +10 -10
- package/lib/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +4 -4
- package/lib/components/ButtonSetWithOverflow/ButtonSetWithOverflow.js +4 -4
- package/lib/components/Card/Card.js +14 -14
- package/lib/components/Card/CardFooter.js +4 -4
- package/lib/components/Card/CardHeader.js +2 -2
- package/lib/components/Carousel/Carousel.js +16 -16
- package/lib/components/Cascade/Cascade.js +2 -2
- package/lib/components/Checklist/Checklist.js +11 -11
- package/lib/components/Checklist/ChecklistChart.js +1 -1
- package/lib/components/Checklist/ChecklistIcon.js +1 -1
- package/lib/components/Coachmark/Coachmark.js +10 -10
- package/lib/components/Coachmark/CoachmarkDragbar.js +5 -5
- package/lib/components/Coachmark/CoachmarkHeader.js +4 -4
- package/lib/components/Coachmark/CoachmarkOverlay.js +4 -4
- package/lib/components/Coachmark/CoachmarkTagline.js +3 -3
- package/lib/components/CoachmarkBeacon/CoachmarkBeacon.js +1 -1
- package/lib/components/CoachmarkFixed/CoachmarkFixed.js +6 -6
- package/lib/components/CoachmarkOverlayElements/CoachmarkOverlayElements.d.ts +0 -10
- package/lib/components/CoachmarkOverlayElements/CoachmarkOverlayElements.js +16 -35
- package/lib/components/CoachmarkStack/CoachmarkStack.d.ts +2 -13
- package/lib/components/CoachmarkStack/CoachmarkStack.js +12 -22
- package/lib/components/CoachmarkStack/CoachmarkStackHome.d.ts +0 -17
- package/lib/components/CoachmarkStack/CoachmarkStackHome.js +6 -29
- package/lib/components/ConditionBuilder/ConditionBlock/ConditionBlock.js +12 -12
- package/lib/components/ConditionBuilder/ConditionBuilder.js +2 -2
- package/lib/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.js +5 -5
- package/lib/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.js +2 -2
- package/lib/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.js +1 -1
- package/lib/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.js +3 -3
- package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +19 -19
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.js +7 -7
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.js +2 -2
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.js +3 -3
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +6 -6
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOptionForValueField.js +6 -6
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.js +1 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.js +3 -3
- package/lib/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.js +31 -31
- package/lib/components/ConditionBuilder/utils/handleKeyboardEvents.js +15 -15
- package/lib/components/ConditionBuilder/utils/useDataConfigs.js +1 -1
- package/lib/components/ConditionBuilder/utils/useTranslations.js +2 -2
- package/lib/components/ConditionBuilder/utils/util.js +13 -13
- package/lib/components/CreateFullPage/CreateFullPage.js +3 -3
- package/lib/components/CreateFullPage/CreateFullPageStep.js +9 -9
- package/lib/components/CreateInfluencer/CreateInfluencer.js +8 -8
- package/lib/components/CreateModal/CreateModal.js +1 -1
- package/lib/components/CreateSidePanel/CreateSidePanel.js +1 -1
- package/lib/components/CreateTearsheet/CreateTearsheet.js +4 -4
- package/lib/components/CreateTearsheet/CreateTearsheetStep.js +16 -16
- package/lib/components/CreateTearsheetNarrow/CreateTearsheetNarrow.js +1 -1
- package/lib/components/DataSpreadsheet/DataSpreadsheet.js +52 -52
- package/lib/components/DataSpreadsheet/DataSpreadsheetBody.js +36 -36
- package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.js +26 -26
- package/lib/components/DataSpreadsheet/hooks/useMoveActiveCell.js +3 -3
- package/lib/components/DataSpreadsheet/hooks/useMultipleKeyTracking.js +3 -3
- package/lib/components/DataSpreadsheet/hooks/useResetSpreadsheetFocus.js +1 -1
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetEdit.js +16 -16
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseMove.js +5 -5
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.js +8 -8
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetOutsideClick.js +1 -1
- package/lib/components/DataSpreadsheet/utils/checkActiveHeaderCell.js +3 -3
- package/lib/components/DataSpreadsheet/utils/checkSelectedHeaderCell.js +5 -5
- package/lib/components/DataSpreadsheet/utils/commonEventHandlers.js +3 -3
- package/lib/components/DataSpreadsheet/utils/createActiveCellFn.js +10 -10
- package/lib/components/DataSpreadsheet/utils/createCellSelectionArea.js +1 -1
- package/lib/components/DataSpreadsheet/utils/getSpreadsheetWidth.js +1 -1
- package/lib/components/DataSpreadsheet/utils/handleActiveCellInSelectionEnter.js +6 -6
- package/lib/components/DataSpreadsheet/utils/handleActiveCellInSelectionTab.js +6 -6
- package/lib/components/DataSpreadsheet/utils/handleCellDeletion.js +6 -6
- package/lib/components/DataSpreadsheet/utils/handleEditSubmit.js +3 -3
- package/lib/components/DataSpreadsheet/utils/handleHeaderCellSelection.js +10 -10
- package/lib/components/DataSpreadsheet/utils/handleMultipleKeys.js +14 -14
- package/lib/components/DataSpreadsheet/utils/moveColumnIndicatorLine.js +4 -4
- package/lib/components/DataSpreadsheet/utils/removeCellSelections.js +1 -1
- package/lib/components/Datagrid/Datagrid/Datagrid.js +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridBody.js +1 -1
- package/lib/components/Datagrid/Datagrid/DatagridContent.js +14 -14
- package/lib/components/Datagrid/Datagrid/DatagridEmptyBody.js +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridExpandedRow.js +3 -3
- package/lib/components/Datagrid/Datagrid/DatagridHead.js +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridHeaderRow.js +23 -23
- package/lib/components/Datagrid/Datagrid/DatagridRefBody.js +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridRow.js +19 -19
- package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +9 -9
- package/lib/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +7 -7
- package/lib/components/Datagrid/Datagrid/DatagridSimpleBody.js +1 -1
- package/lib/components/Datagrid/Datagrid/DatagridToolbar.js +11 -11
- package/lib/components/Datagrid/Datagrid/DatagridVirtualBody.js +18 -18
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +9 -9
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +15 -15
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.d.ts +1 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +59 -44
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/OverflowCheckboxes.js +2 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/constants.js +0 -6
- package/lib/components/Datagrid/Datagrid/addons/Filtering/handleCheckboxChange.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +20 -20
- package/lib/components/Datagrid/Datagrid/addons/Filtering/utils.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +35 -35
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/returnUpdatedActiveCell.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +6 -6
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleMultipleKeys.js +2 -2
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +5 -5
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +1 -1
- package/lib/components/Datagrid/Datagrid/addons/stateReducer.js +4 -4
- package/lib/components/Datagrid/useActionsColumn.js +2 -2
- package/lib/components/Datagrid/useColumnRightAlign.js +3 -3
- package/lib/components/Datagrid/useCustomizeColumns.js +1 -1
- package/lib/components/Datagrid/useDatagrid.js +2 -2
- package/lib/components/Datagrid/useDefaultStringRenderer.js +1 -1
- package/lib/components/Datagrid/useDisableSelectRows.js +16 -16
- package/lib/components/Datagrid/useExpandedRow.js +1 -1
- package/lib/components/Datagrid/useFiltering.js +1 -1
- package/lib/components/Datagrid/useFloatingScroll.js +2 -2
- package/lib/components/Datagrid/useFocusRowExpander.js +4 -4
- package/lib/components/Datagrid/useInfiniteScroll.js +1 -1
- package/lib/components/Datagrid/useInitialColumnSort.js +1 -1
- package/lib/components/Datagrid/useInlineEdit.js +4 -4
- package/lib/components/Datagrid/useNestedRowExpander.js +6 -6
- package/lib/components/Datagrid/useNestedRows.js +6 -6
- package/lib/components/Datagrid/useOnRowClick.js +1 -1
- package/lib/components/Datagrid/useRowExpander.js +4 -4
- package/lib/components/Datagrid/useRowIsMouseOver.js +1 -1
- package/lib/components/Datagrid/useRowRenderer.js +6 -6
- package/lib/components/Datagrid/useSelectAllToggle.js +2 -2
- package/lib/components/Datagrid/useSelectRows.js +5 -5
- package/lib/components/Datagrid/useSortableColumns.js +11 -11
- package/lib/components/Datagrid/useStickyColumn.js +8 -8
- package/lib/components/DecoratorBase/DecoratorBase.js +8 -8
- package/lib/components/DecoratorBase/DecoratorIcon.js +2 -2
- package/lib/components/DelimitedList/DelimitedList.js +3 -3
- package/lib/components/DescriptionList/DescriptionList.js +2 -2
- package/lib/components/EditInPlace/EditInPlace.js +6 -6
- package/lib/components/EditSidePanel/EditSidePanel.js +3 -3
- package/lib/components/EditTearsheet/EditTearsheet.js +3 -3
- package/lib/components/EditTearsheet/EditTearsheetForm.js +2 -2
- package/lib/components/EmptyStates/EmptyState.js +5 -5
- package/lib/components/EmptyStates/EmptyStateContent.js +2 -2
- package/lib/components/EmptyStates/EmptyStateV2.js +2 -2
- package/lib/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +3 -3
- package/lib/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +3 -3
- package/lib/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +3 -3
- package/lib/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +3 -3
- package/lib/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +3 -3
- package/lib/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +3 -3
- package/lib/components/ExportModal/ExportModal.js +7 -7
- package/lib/components/FeatureFlags/index.js +1 -1
- package/lib/components/FilterPanel/FilterPanelAccordion/FilterPanelAccordion.js +1 -1
- package/lib/components/FilterPanel/FilterPanelAccordionItem/FilterPanelAccordionItem.js +2 -2
- package/lib/components/FilterPanel/FilterPanelCheckboxWithOverflow/FilterPanelCheckboxWithOverflow.js +8 -8
- package/lib/components/FilterPanel/FilterPanelSearch/FilterPanelSearch.js +1 -1
- package/lib/components/FilterSummary/FilterSummary.js +18 -34
- package/lib/components/FullPageError/FullPageError.js +1 -1
- package/lib/components/Guidebanner/Guidebanner.js +8 -8
- package/lib/components/Guidebanner/GuidebannerElementButton.js +1 -1
- package/lib/components/ImportModal/ImportModal.js +2 -2
- package/lib/components/InlineTip/InlineTip.d.ts +0 -14
- package/lib/components/InlineTip/InlineTip.js +13 -35
- package/lib/components/InlineTip/utils.js +1 -1
- package/lib/components/InterstitialScreen/InterstitialScreen.d.ts +0 -26
- package/lib/components/InterstitialScreen/InterstitialScreen.js +22 -56
- package/lib/components/MultiAddSelect/MultiAddSelect.d.ts +4 -0
- package/lib/components/MultiAddSelect/MultiAddSelect.js +2 -1
- package/lib/components/Nav/Nav.js +3 -3
- package/lib/components/Nav/NavItem.js +12 -13
- package/lib/components/Nav/NavList.js +18 -19
- package/lib/components/NonLinearReading/NonLinearReading.js +1 -1
- package/lib/components/NotificationsPanel/NotificationsPanel.d.ts +53 -1
- package/lib/components/NotificationsPanel/NotificationsPanel.js +89 -71
- package/lib/components/OptionsTile/OptionsTile.js +4 -3
- package/lib/components/PageHeader/PageHeader.js +19 -19
- package/lib/components/PageHeader/PageHeaderTitle.js +1 -1
- package/lib/components/PageHeader/PageHeaderUtils.js +1 -1
- package/lib/components/ProductiveCard/ProductiveCard.js +1 -1
- package/lib/components/RemoveModal/RemoveModal.js +2 -2
- package/lib/components/Saving/Saving.js +4 -4
- package/lib/components/ScrollGradient/ScrollGradient.js +6 -6
- package/lib/components/SearchBar/SearchBar.js +6 -6
- package/lib/components/SidePanel/SidePanel.js +45 -45
- package/lib/components/SimpleHeader/SimpleHeader.js +4 -4
- package/lib/components/StatusIcon/StatusIcon.js +1 -1
- package/lib/components/StatusIndicator/StatusIndicator.js +2 -2
- package/lib/components/StatusIndicator/StatusIndicatorStep.js +1 -1
- package/lib/components/StringFormatter/StringFormatter.js +4 -4
- package/lib/components/TagOverflow/TagOverflow.js +7 -7
- package/lib/components/TagOverflow/TagOverflowModal.js +4 -4
- package/lib/components/TagOverflow/TagOverflowPopover.js +13 -13
- package/lib/components/TagSet/TagSet.js +15 -15
- package/lib/components/TagSet/TagSetModal.js +6 -6
- package/lib/components/TagSet/TagSetOverflow.js +3 -3
- package/lib/components/Tearsheet/Tearsheet.js +2 -2
- package/lib/components/Tearsheet/TearsheetNarrow.js +1 -1
- package/lib/components/Tearsheet/TearsheetShell.js +6 -6
- package/lib/components/Toolbar/Toolbar.js +6 -6
- package/lib/components/Toolbar/ToolbarButton.js +4 -4
- package/lib/components/TruncatedList/TruncatedList.js +8 -8
- package/lib/components/UserAvatar/UserAvatar.js +4 -4
- package/lib/components/UserProfileImage/UserProfileImage.js +2 -2
- package/lib/components/WebTerminal/WebTerminal.js +8 -8
- package/lib/global/js/hooks/useControllableState.js +1 -1
- package/lib/global/js/hooks/useCreateComponentFocus.js +1 -1
- package/lib/global/js/hooks/useCreateComponentStepChange.js +10 -10
- package/lib/global/js/hooks/useFocus.js +19 -19
- package/lib/global/js/hooks/useOverflowItems/index.d.ts +7 -0
- package/lib/global/js/hooks/{useOverflowItems.js → useOverflowItems/useOverflowItems.js} +16 -16
- package/lib/global/js/hooks/useOverflowString.js +6 -6
- package/lib/global/js/hooks/usePresence.d.ts +23 -0
- package/lib/global/js/hooks/usePresence.js +26 -6
- package/lib/global/js/hooks/useResetCreateComponent.js +1 -1
- package/lib/global/js/hooks/useResizeObserver.js +5 -5
- package/lib/global/js/hooks/useRetrieveStepData.js +1 -1
- package/lib/global/js/package-settings.js +4 -4
- package/lib/global/js/utils/Wrap.js +2 -2
- package/lib/global/js/utils/checkForOverflow.js +1 -1
- package/lib/global/js/utils/debounce.d.ts +1 -1
- package/lib/global/js/utils/debounce.js +2 -2
- package/lib/global/js/utils/getSupportedLocale.d.ts +2 -0
- package/lib/global/js/utils/getSupportedLocale.js +2 -0
- package/lib/global/js/utils/lastIndexInArray.js +1 -1
- package/lib/global/js/utils/props-helper.js +1 -1
- package/lib/node_modules/@carbon/icon-helpers/es/index.js +2 -2
- package/lib/node_modules/@carbon/icons-react/es/Icon.js +2 -2
- package/lib/node_modules/@carbon/icons-react/es/generated/bucket-10.js +902 -871
- package/lib/node_modules/@carbon/icons-react/es/generated/bucket-3.js +824 -823
- package/lib/node_modules/prop-types/factoryWithTypeCheckers.js +1 -1
- package/lib/settings.js +2 -2
- package/package.json +19 -19
- package/scss/components/Datagrid/styles/addons/_FilterPanel.scss +100 -22
- package/scss/components/Datagrid/styles/addons/_animations.scss +56 -0
- package/scss/components/FilterSummary/_animations.scss +20 -0
- package/scss/components/FilterSummary/_filter-summary.scss +11 -0
- package/scss/components/FullPageError/_full-page-error.scss +4 -0
- package/scss/components/GetStartedCard/_get-started-card.scss +2 -2
- package/scss/components/NotificationsPanel/_notifications-panel.scss +35 -7
- package/scss/components/SidePanel/_side-panel.scss +4 -2
- package/scss/components/Tearsheet/_tearsheet.scss +6 -12
- package/telemetry.yml +9 -17
- package/es/components/Datagrid/Datagrid/addons/Filtering/motion/variants.d.ts +0 -60
- package/es/components/Datagrid/Datagrid/addons/Filtering/motion/variants.js +0 -80
- package/es/components/SteppedAnimatedMedia/SteppedAnimatedMedia.d.ts +0 -25
- package/es/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +0 -146
- package/es/components/SteppedAnimatedMedia/index.d.ts +0 -8
- package/es/global/js/utils/getBezierValues.d.ts +0 -1
- package/es/global/js/utils/getBezierValues.js +0 -28
- package/es/global/js/utils/motionConstants.d.ts +0 -23
- package/es/global/js/utils/motionConstants.js +0 -39
- package/lib/components/Datagrid/Datagrid/addons/Filtering/motion/variants.d.ts +0 -60
- package/lib/components/Datagrid/Datagrid/addons/Filtering/motion/variants.js +0 -84
- package/lib/components/SteppedAnimatedMedia/SteppedAnimatedMedia.d.ts +0 -25
- package/lib/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +0 -148
- package/lib/components/SteppedAnimatedMedia/index.d.ts +0 -8
- package/lib/global/js/utils/getBezierValues.d.ts +0 -1
- package/lib/global/js/utils/getBezierValues.js +0 -30
- package/lib/global/js/utils/motionConstants.d.ts +0 -23
- package/lib/global/js/utils/motionConstants.js +0 -42
- /package/es/global/js/hooks/{useOverflowItems.d.ts → useOverflowItems/useOverflowItems.d.ts} +0 -0
- /package/lib/global/js/hooks/{useOverflowItems.d.ts → useOverflowItems/useOverflowItems.d.ts} +0 -0
@@ -11,7 +11,7 @@ import { blockClass, HIERARCHICAL_VARIANT, focusThisItem, manageTabIndexAndFocus
|
|
11
11
|
var handleKeyDown = function handleKeyDown(evt, conditionBuilderRef, variant) {
|
12
12
|
var _activeElement$closes;
|
13
13
|
var activeElement = document.activeElement;
|
14
|
-
if (!((_activeElement$closes = activeElement.closest(".".concat(blockClass, "__popover"))) !== null && _activeElement$closes !==
|
14
|
+
if (!((_activeElement$closes = activeElement.closest(".".concat(blockClass, "__popover"))) !== null && _activeElement$closes !== void 0 && _activeElement$closes.querySelector('[role="dialog"]'))) {
|
15
15
|
handleKeyPressForMainContent(evt, conditionBuilderRef, variant);
|
16
16
|
}
|
17
17
|
};
|
@@ -19,7 +19,7 @@ var handleKeyDownForPopover = function handleKeyDownForPopover(evt, conditionBui
|
|
19
19
|
if (excludeKeyPress(evt)) {
|
20
20
|
return;
|
21
21
|
}
|
22
|
-
handleKeyPressForPopover(evt, popoverRef === null || popoverRef ===
|
22
|
+
handleKeyPressForPopover(evt, popoverRef === null || popoverRef === void 0 ? void 0 : popoverRef.current, conditionBuilderRef);
|
23
23
|
};
|
24
24
|
|
25
25
|
//skipping keyboard handling for date and time fields to get take carbon's
|
@@ -30,8 +30,8 @@ var handleKeyPressForPopover = function handleKeyPressForPopover(evt, parentCont
|
|
30
30
|
var _parentContainer$quer, _parentContainer$quer2, _evt$target$closest$q, _evt$target$closest;
|
31
31
|
var key = evt.key;
|
32
32
|
var isHoldingShiftKey = checkForHoldingKey(evt, 'shiftKey');
|
33
|
-
var isMultiSelect = (_parentContainer$quer = parentContainer.querySelector('ul')) === null || _parentContainer$quer ===
|
34
|
-
var isOptionInput = (_parentContainer$quer2 = parentContainer.querySelectorAll("[role=\"option\"]")) === null || _parentContainer$quer2 ===
|
33
|
+
var isMultiSelect = (_parentContainer$quer = parentContainer.querySelector('ul')) === null || _parentContainer$quer === void 0 ? void 0 : _parentContainer$quer.dataset.multiSelect;
|
34
|
+
var isOptionInput = (_parentContainer$quer2 = parentContainer.querySelectorAll("[role=\"option\"]")) === null || _parentContainer$quer2 === void 0 ? void 0 : _parentContainer$quer2.length;
|
35
35
|
var allItems = [];
|
36
36
|
if (key === 'Escape') {
|
37
37
|
//focus the corresponding field in which the popover is triggered from
|
@@ -47,7 +47,7 @@ var handleKeyPressForPopover = function handleKeyPressForPopover(evt, parentCont
|
|
47
47
|
traverseReverse(eachElem, index, allElements, null, null, conditionBuilderRef);
|
48
48
|
});
|
49
49
|
//scroll to top when we reach a the top of the list to make search box visible
|
50
|
-
if (Array.from((_evt$target$closest$q = (_evt$target$closest = evt.target.closest('ul')) === null || _evt$target$closest ===
|
50
|
+
if (Array.from((_evt$target$closest$q = (_evt$target$closest = evt.target.closest('ul')) === null || _evt$target$closest === void 0 ? void 0 : _evt$target$closest.querySelectorAll('li')) !== null && _evt$target$closest$q !== void 0 ? _evt$target$closest$q : []).indexOf(evt.target) === 1) {
|
51
51
|
parentContainer.querySelector(".".concat(blockClass, "__popover-content-wrapper")).scrollTop = 0;
|
52
52
|
}
|
53
53
|
break;
|
@@ -74,7 +74,7 @@ var handleKeyPressForPopover = function handleKeyPressForPopover(evt, parentCont
|
|
74
74
|
if (document.activeElement.type !== 'button') {
|
75
75
|
var _document$activeEleme;
|
76
76
|
//for button , enter key is click which already handled by framework, for other elements trigger click
|
77
|
-
(_document$activeEleme = document.activeElement) === null || _document$activeEleme ===
|
77
|
+
(_document$activeEleme = document.activeElement) === null || _document$activeEleme === void 0 || _document$activeEleme.click();
|
78
78
|
}
|
79
79
|
evt.preventDefault();
|
80
80
|
}
|
@@ -84,7 +84,7 @@ var handleKeyPressForPopover = function handleKeyPressForPopover(evt, parentCont
|
|
84
84
|
var _document$activeEleme2;
|
85
85
|
//for button , enter key is click which already handled by framework, else trigger click
|
86
86
|
focusThisField(evt, conditionBuilderRef);
|
87
|
-
(_document$activeEleme2 = document.activeElement) === null || _document$activeEleme2 ===
|
87
|
+
(_document$activeEleme2 = document.activeElement) === null || _document$activeEleme2 === void 0 || _document$activeEleme2.click();
|
88
88
|
}
|
89
89
|
break;
|
90
90
|
}
|
@@ -94,7 +94,7 @@ var handleKeyPressForPopover = function handleKeyPressForPopover(evt, parentCont
|
|
94
94
|
var _document$activeEleme3;
|
95
95
|
//for button , enter key is click which already handled by framework, else trigger click
|
96
96
|
focusThisField(evt, conditionBuilderRef);
|
97
|
-
(_document$activeEleme3 = document.activeElement) === null || _document$activeEleme3 ===
|
97
|
+
(_document$activeEleme3 = document.activeElement) === null || _document$activeEleme3 === void 0 || _document$activeEleme3.click();
|
98
98
|
}
|
99
99
|
}
|
100
100
|
}
|
@@ -106,7 +106,7 @@ var handleKeyPressForMainContent = function handleKeyPressForMainContent(evt, co
|
|
106
106
|
evt.preventDefault();
|
107
107
|
if (variant == HIERARCHICAL_VARIANT) {
|
108
108
|
var _evt$target$closest2;
|
109
|
-
var allCellsInRow = Array.from((_evt$target$closest2 = evt.target.closest('[role="row"]')) === null || _evt$target$closest2 ===
|
109
|
+
var allCellsInRow = Array.from((_evt$target$closest2 = evt.target.closest('[role="row"]')) === null || _evt$target$closest2 === void 0 ? void 0 : _evt$target$closest2.querySelectorAll('[role="gridcell"] button'));
|
110
110
|
if (allCellsInRow.length === 1) {
|
111
111
|
evt.target = evt.target.closest('[role="row"]');
|
112
112
|
handleRowNavigationHierarchical(evt, conditionBuilderRef, variant);
|
@@ -136,7 +136,7 @@ var handleKeyPressForMainContent = function handleKeyPressForMainContent(evt, co
|
|
136
136
|
var _evt$target$closest3;
|
137
137
|
//when any cell is focussed, arrow left will select the previous cell or current row
|
138
138
|
|
139
|
-
var _allCellsInRow = Array.from((_evt$target$closest3 = evt.target.closest('[role="row"]')) === null || _evt$target$closest3 ===
|
139
|
+
var _allCellsInRow = Array.from((_evt$target$closest3 = evt.target.closest('[role="row"]')) === null || _evt$target$closest3 === void 0 ? void 0 : _evt$target$closest3.querySelectorAll('[role="gridcell"] button'));
|
140
140
|
var _currentItemIndex = _allCellsInRow.indexOf(evt.target);
|
141
141
|
if (_currentItemIndex > 0) {
|
142
142
|
focusThisItem(_allCellsInRow[_currentItemIndex - 1], conditionBuilderRef);
|
@@ -160,16 +160,16 @@ var handleKeyPressForMainContent = function handleKeyPressForMainContent(evt, co
|
|
160
160
|
}
|
161
161
|
break;
|
162
162
|
case 'Enter':
|
163
|
-
if (((_document$activeEleme4 = document.activeElement) === null || _document$activeEleme4 ===
|
163
|
+
if (((_document$activeEleme4 = document.activeElement) === null || _document$activeEleme4 === void 0 || (_document$activeEleme4 = _document$activeEleme4.querySelectorAll("button")) === null || _document$activeEleme4 === void 0 ? void 0 : _document$activeEleme4.length) === 1) {
|
164
164
|
var _document$activeEleme5;
|
165
|
-
(_document$activeEleme5 = document.activeElement) === null || _document$activeEleme5 ===
|
165
|
+
(_document$activeEleme5 = document.activeElement) === null || _document$activeEleme5 === void 0 || (_document$activeEleme5 = _document$activeEleme5.querySelectorAll("button")[0]) === null || _document$activeEleme5 === void 0 || _document$activeEleme5.click();
|
166
166
|
}
|
167
167
|
break;
|
168
168
|
}
|
169
169
|
};
|
170
170
|
var getRows = function getRows(conditionBuilderRef) {
|
171
171
|
var _conditionBuilderRef$;
|
172
|
-
return Array.from((_conditionBuilderRef$ = conditionBuilderRef.current) === null || _conditionBuilderRef$ ===
|
172
|
+
return Array.from((_conditionBuilderRef$ = conditionBuilderRef.current) === null || _conditionBuilderRef$ === void 0 ? void 0 : _conditionBuilderRef$.querySelectorAll('[role="row"]'));
|
173
173
|
};
|
174
174
|
var getRowIndex = function getRowIndex(element, conditionBuilderRef) {
|
175
175
|
var rows = getRows(conditionBuilderRef);
|
@@ -218,8 +218,8 @@ var navigateToNextRowCell = function navigateToNextRowCell(evt, currentRowIndex,
|
|
218
218
|
}
|
219
219
|
var nextRow = rows[nextRowIndex];
|
220
220
|
var itemName = evt.target.dataset.name;
|
221
|
-
if (nextRow !== null && nextRow !==
|
222
|
-
manageTabIndexAndFocus(nextRow === null || nextRow ===
|
221
|
+
if (nextRow !== null && nextRow !== void 0 && nextRow.querySelector("[data-name=\"".concat(itemName, "\"]"))) {
|
222
|
+
manageTabIndexAndFocus(nextRow === null || nextRow === void 0 ? void 0 : nextRow.querySelector("[data-name=\"".concat(itemName, "\"]")), conditionBuilderRef);
|
223
223
|
} else if (variant === HIERARCHICAL_VARIANT) {
|
224
224
|
//when the next row is a if statement , then that row is focused. From any cell of last row of an group , arrow down select the next row (if)
|
225
225
|
manageTabIndexAndFocus(nextRow, conditionBuilderRef);
|
@@ -111,7 +111,7 @@ var useDataConfigs = function useDataConfigs() {
|
|
111
111
|
type: 'date'
|
112
112
|
}];
|
113
113
|
return {
|
114
|
-
statementConfig: statementConfigCustom !== null && statementConfigCustom !==
|
114
|
+
statementConfig: statementConfigCustom !== null && statementConfigCustom !== void 0 ? statementConfigCustom : statementConfigDefault,
|
115
115
|
connectorConfig: connectorConfig,
|
116
116
|
operatorConfig: operatorConfig
|
117
117
|
};
|
@@ -13,10 +13,10 @@ var useTranslations = function useTranslations(translationKeys, alterTranslation
|
|
13
13
|
var _useContext = useContext(ConditionBuilderContext),
|
14
14
|
translateWithId = _useContext.translateWithId;
|
15
15
|
return translationKeys.map(function (translationKey) {
|
16
|
-
if (alterTranslationKeyMap !== null && alterTranslationKeyMap !==
|
16
|
+
if (alterTranslationKeyMap !== null && alterTranslationKeyMap !== void 0 && alterTranslationKeyMap[translationKey]) {
|
17
17
|
translationKey = alterTranslationKeyMap[translationKey];
|
18
18
|
}
|
19
|
-
if (translateWithId !== null && translateWithId !==
|
19
|
+
if (translateWithId !== null && translateWithId !== void 0 && translateWithId(translationKey)) {
|
20
20
|
return translateWithId(translationKey);
|
21
21
|
} else if (translationsObject[translationKey]) {
|
22
22
|
return translationsObject[translationKey];
|
@@ -14,9 +14,9 @@ var focusThisField = function focusThisField(evt, conditionBuilderRef) {
|
|
14
14
|
if (evt) {
|
15
15
|
setTimeout(function () {
|
16
16
|
var _evt$target$closest, _evt$target$closest2, _evt$target$closest3;
|
17
|
-
manageTabIndexAndFocus((_evt$target$closest = evt.target.closest('[role="gridcell"]')) === null || _evt$target$closest ===
|
18
|
-
(_evt$target$closest2 = evt.target.closest('[role="gridcell"]')) === null || _evt$target$closest2 ===
|
19
|
-
(_evt$target$closest3 = evt.target.closest('[role="gridcell"]')) === null || _evt$target$closest3 ===
|
17
|
+
manageTabIndexAndFocus((_evt$target$closest = evt.target.closest('[role="gridcell"]')) === null || _evt$target$closest === void 0 ? void 0 : _evt$target$closest.querySelector('button'), conditionBuilderRef);
|
18
|
+
(_evt$target$closest2 = evt.target.closest('[role="gridcell"]')) === null || _evt$target$closest2 === void 0 || (_evt$target$closest2 = _evt$target$closest2.querySelector('button')) === null || _evt$target$closest2 === void 0 || _evt$target$closest2.click();
|
19
|
+
(_evt$target$closest3 = evt.target.closest('[role="gridcell"]')) === null || _evt$target$closest3 === void 0 || (_evt$target$closest3 = _evt$target$closest3.querySelector('button')) === null || _evt$target$closest3 === void 0 || _evt$target$closest3.focus();
|
20
20
|
}, 0);
|
21
21
|
}
|
22
22
|
};
|
@@ -55,13 +55,13 @@ var checkIsValid = function checkIsValid(item) {
|
|
55
55
|
};
|
56
56
|
var manageTabIndexAndFocus = function manageTabIndexAndFocus(currentElement, conditionBuilderRef) {
|
57
57
|
var _currentElement$close, _conditionBuilderRef$;
|
58
|
-
var contentContainer = (_currentElement$close = currentElement === null || currentElement ===
|
58
|
+
var contentContainer = (_currentElement$close = currentElement === null || currentElement === void 0 ? void 0 : currentElement.closest(".".concat(blockClass, "__content-container"))) !== null && _currentElement$close !== void 0 ? _currentElement$close : currentElement === null || currentElement === void 0 ? void 0 : currentElement.closest(".".concat(blockClass, "__actions-container"));
|
59
59
|
contentContainer && Array.from(contentContainer.querySelectorAll('[tabindex="0"]')).map(function (element) {
|
60
|
-
return element === null || element ===
|
60
|
+
return element === null || element === void 0 ? void 0 : element.setAttribute('tabindex', '-1');
|
61
61
|
});
|
62
|
-
currentElement === null || currentElement ===
|
63
|
-
(_conditionBuilderRef$ = conditionBuilderRef.current) === null || _conditionBuilderRef$ ===
|
64
|
-
currentElement === null || currentElement ===
|
62
|
+
currentElement === null || currentElement === void 0 || currentElement.setAttribute('tabindex', '0');
|
63
|
+
(_conditionBuilderRef$ = conditionBuilderRef.current) === null || _conditionBuilderRef$ === void 0 || (_conditionBuilderRef$ = _conditionBuilderRef$.querySelector(".".concat(blockClass, "__statement-button"))) === null || _conditionBuilderRef$ === void 0 || _conditionBuilderRef$.setAttribute('tabindex', '1');
|
64
|
+
currentElement === null || currentElement === void 0 || currentElement.focus();
|
65
65
|
};
|
66
66
|
var formatDate = function formatDate(date) {
|
67
67
|
var day = String(date.getDate()).padStart(2, '0');
|
@@ -70,7 +70,7 @@ var formatDate = function formatDate(date) {
|
|
70
70
|
return "".concat(day, "/").concat(month, "/").concat(year);
|
71
71
|
};
|
72
72
|
var getValue = function getValue(type, value, config) {
|
73
|
-
if (config !== null && config !==
|
73
|
+
if (config !== null && config !== void 0 && config.valueFormatter && ['date', 'custom'].includes(type)) {
|
74
74
|
return config.valueFormatter(value);
|
75
75
|
} else {
|
76
76
|
var formatters = {
|
@@ -97,8 +97,8 @@ var getValue = function getValue(type, value, config) {
|
|
97
97
|
},
|
98
98
|
date: function date(value) {
|
99
99
|
if (Array.isArray(value) && value.length > 1) {
|
100
|
-
var start = value !== null && value !==
|
101
|
-
var end = value !== null && value !==
|
100
|
+
var start = value !== null && value !== void 0 && value[0] && !isNaN(new Date(value[0])) ? formatDate(new Date(value[0])) : '';
|
101
|
+
var end = value !== null && value !== void 0 && value[1] && !isNaN(new Date(value[1])) ? formatDate(new Date(value[1])) : '';
|
102
102
|
return "".concat(start, " To ").concat(end);
|
103
103
|
} else if (Array.isArray(value) && !isNaN(new Date(value[0]))) {
|
104
104
|
return formatDate(new Date(value[0]));
|
@@ -117,8 +117,8 @@ var getValue = function getValue(type, value, config) {
|
|
117
117
|
//check if the operator is configured as multiSelect in the input configuration or operator is on of
|
118
118
|
var checkForMultiSelectOperator = function checkForMultiSelectOperator(condition, config) {
|
119
119
|
var _config$operators;
|
120
|
-
return (condition === null || condition ===
|
121
|
-
return (condition === null || condition ===
|
120
|
+
return (condition === null || condition === void 0 ? void 0 : condition.operator) === 'oneOf' || (config === null || config === void 0 || (_config$operators = config.operators) === null || _config$operators === void 0 ? void 0 : _config$operators.find(function (operator) {
|
121
|
+
return (condition === null || condition === void 0 ? void 0 : condition.operator) === operator.id && operator.isMultiSelect;
|
122
122
|
}));
|
123
123
|
};
|
124
124
|
//this will close the popover on escape key on search box
|
@@ -70,7 +70,7 @@ var CreateFullPage = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
|
|
70
70
|
title = _ref.title,
|
71
71
|
secondaryTitle = _ref.secondaryTitle,
|
72
72
|
_ref$breadcrumbOverfl = _ref.breadcrumbOverflowTooltipAlign,
|
73
|
-
breadcrumbOverflowTooltipAlign = _ref$breadcrumbOverfl ===
|
73
|
+
breadcrumbOverflowTooltipAlign = _ref$breadcrumbOverfl === void 0 ? 'right' : _ref$breadcrumbOverfl,
|
74
74
|
rest = _objectWithoutProperties(_ref, _excluded);
|
75
75
|
var _useState = useState([]),
|
76
76
|
_useState2 = _slicedToArray(_useState, 2),
|
@@ -126,7 +126,7 @@ var CreateFullPage = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
|
|
126
126
|
setLastIncludedStep = _useState24[1];
|
127
127
|
useEffect(function () {
|
128
128
|
var firstItem = stepData.findIndex(function (item) {
|
129
|
-
return item === null || item ===
|
129
|
+
return item === null || item === void 0 ? void 0 : item.shouldIncludeStep;
|
130
130
|
}) + 1;
|
131
131
|
var lastItem = lastIndexInArray(stepData, 'shouldIncludeStep', true);
|
132
132
|
if (firstItem !== firstIncludedStep) {
|
@@ -158,7 +158,7 @@ var CreateFullPage = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
|
|
158
158
|
stepData: stepData,
|
159
159
|
/**@ts-ignore */
|
160
160
|
initialStep: initialStep,
|
161
|
-
totalSteps: stepData === null || stepData ===
|
161
|
+
totalSteps: stepData === null || stepData === void 0 ? void 0 : stepData.length,
|
162
162
|
componentName: componentName
|
163
163
|
});
|
164
164
|
useCreateComponentStepChange({
|
@@ -36,7 +36,7 @@ var CreateFullPageStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
36
36
|
description = _ref.description,
|
37
37
|
disableSubmit = _ref.disableSubmit,
|
38
38
|
_ref$includeStep = _ref.includeStep,
|
39
|
-
includeStep = _ref$includeStep ===
|
39
|
+
includeStep = _ref$includeStep === void 0 ? defaults.includeStep : _ref$includeStep,
|
40
40
|
introStep = _ref.introStep,
|
41
41
|
invalid = _ref.invalid,
|
42
42
|
title = _ref.title,
|
@@ -54,7 +54,7 @@ var CreateFullPageStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
54
54
|
shouldIncludeStep = _useState2[0],
|
55
55
|
setShouldIncludeStep = _useState2[1];
|
56
56
|
var previousState = usePreviousValue({
|
57
|
-
currentStep: stepsContext === null || stepsContext ===
|
57
|
+
currentStep: stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep
|
58
58
|
});
|
59
59
|
useRetrieveStepData({
|
60
60
|
invalid: invalid,
|
@@ -69,10 +69,10 @@ var CreateFullPageStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
69
69
|
// This useEffect reports back the onMount value so that they can be used
|
70
70
|
// in the appropriate custom hooks.
|
71
71
|
useEffect(function () {
|
72
|
-
if (stepNumber === (stepsContext === null || stepsContext ===
|
73
|
-
stepsContext === null || stepsContext ===
|
72
|
+
if (stepNumber === (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep) && (previousState === null || previousState === void 0 ? void 0 : previousState.currentStep) !== (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)) {
|
73
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setOnMount(onMount);
|
74
74
|
}
|
75
|
-
}, [onMount, stepsContext, stepNumber, previousState === null || previousState ===
|
75
|
+
}, [onMount, stepsContext, stepNumber, previousState === null || previousState === void 0 ? void 0 : previousState.currentStep]);
|
76
76
|
useEffect(function () {
|
77
77
|
setShouldIncludeStep(includeStep);
|
78
78
|
}, [includeStep, stepsContext, title]);
|
@@ -80,10 +80,10 @@ var CreateFullPageStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
80
80
|
// Whenever we are the current step, supply our disableSubmit and onNext values to the
|
81
81
|
// steps container context so that it can manage the 'Next' button appropriately.
|
82
82
|
useEffect(function () {
|
83
|
-
if (stepNumber === (stepsContext === null || stepsContext ===
|
83
|
+
if (stepNumber === (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)) {
|
84
84
|
stepsContext.setIsDisabled(disableSubmit);
|
85
|
-
stepsContext === null || stepsContext ===
|
86
|
-
stepsContext === null || stepsContext ===
|
85
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setOnNext(onNext); // needs to be updated here otherwise there could be stale state values from only initially setting onNext
|
86
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setOnPrevious(onPrevious);
|
87
87
|
}
|
88
88
|
}, [stepsContext, stepNumber, disableSubmit, onNext, onPrevious]);
|
89
89
|
var span = {
|
@@ -109,7 +109,7 @@ var CreateFullPageStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
109
109
|
return null;
|
110
110
|
};
|
111
111
|
return stepsContext ? /*#__PURE__*/React__default.createElement("section", _extends({}, rest, {
|
112
|
-
className: cx(blockClass, className, _defineProperty(_defineProperty({}, "".concat(blockClass, "__step--hidden-step"), stepNumber !== (stepsContext === null || stepsContext ===
|
112
|
+
className: cx(blockClass, className, _defineProperty(_defineProperty({}, "".concat(blockClass, "__step--hidden-step"), stepNumber !== (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)), "".concat(blockClass, "__step--visible-step"), stepNumber === (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep))),
|
113
113
|
ref: ref
|
114
114
|
}), /*#__PURE__*/React__default.createElement(Grid, null, /*#__PURE__*/React__default.createElement(Column, span, /*#__PURE__*/React__default.createElement(Grid, null, /*#__PURE__*/React__default.createElement(Column, _extends({
|
115
115
|
className: "".concat(blockClass, "-title"),
|
@@ -27,7 +27,7 @@ var CreateInfluencer = function CreateInfluencer(_ref) {
|
|
27
27
|
var dynamicSteps = [];
|
28
28
|
array.forEach(function (item, index) {
|
29
29
|
var _array$index;
|
30
|
-
if (((_array$index = array[index]) === null || _array$index ===
|
30
|
+
if (((_array$index = array[index]) === null || _array$index === void 0 ? void 0 : _array$index[key]) === false && index <= currentStep - 1) {
|
31
31
|
dynamicSteps.push(item);
|
32
32
|
}
|
33
33
|
});
|
@@ -37,11 +37,11 @@ var CreateInfluencer = function CreateInfluencer(_ref) {
|
|
37
37
|
// renders the step progression components in the left influencer area
|
38
38
|
var renderProgressSteps = function renderProgressSteps() {
|
39
39
|
var _stepData$, _stepData$2;
|
40
|
-
var extractedSteps = stepData === null || stepData ===
|
41
|
-
return !(item !== null && item !==
|
40
|
+
var extractedSteps = stepData === null || stepData === void 0 ? void 0 : stepData.filter(function (item) {
|
41
|
+
return !(item !== null && item !== void 0 && item.introStep);
|
42
42
|
});
|
43
|
-
var progressSteps = extractedSteps === null || extractedSteps ===
|
44
|
-
return item === null || item ===
|
43
|
+
var progressSteps = extractedSteps === null || extractedSteps === void 0 ? void 0 : extractedSteps.filter(function (item) {
|
44
|
+
return item === null || item === void 0 ? void 0 : item.shouldIncludeStep;
|
45
45
|
});
|
46
46
|
|
47
47
|
// To get the ProgressIndicator's `currentIndex`, accounting for dynamic steps,
|
@@ -52,8 +52,8 @@ var CreateInfluencer = function CreateInfluencer(_ref) {
|
|
52
52
|
className: "".concat(blockClass, "__left-nav")
|
53
53
|
}, title && /*#__PURE__*/React__default.createElement("h3", {
|
54
54
|
className: "".concat(blockClass, "__title")
|
55
|
-
}, title), currentStep === 1 && (_stepData$ = stepData[0]) !== null && _stepData$ !==
|
56
|
-
currentIndex: (_stepData$2 = stepData[0]) !== null && _stepData$2 !==
|
55
|
+
}, title), currentStep === 1 && (_stepData$ = stepData[0]) !== null && _stepData$ !== void 0 && _stepData$.introStep ? null : /*#__PURE__*/React__default.createElement(ProgressIndicator, {
|
56
|
+
currentIndex: (_stepData$2 = stepData[0]) !== null && _stepData$2 !== void 0 && _stepData$2.introStep ? currentStep - totalDynamicSteps - 2 // minus 2 because we need to account for the intro step in addition to `currentIndex` being 0 index based and our steps being 1 index based
|
57
57
|
: currentStep - totalDynamicSteps - 1 // minus 1 because ProgressIndicator currentIndex prop is 0 index based, but our steps are 1 index based
|
58
58
|
,
|
59
59
|
spaceEqually: true,
|
@@ -62,7 +62,7 @@ var CreateInfluencer = function CreateInfluencer(_ref) {
|
|
62
62
|
onChange: onClickStep
|
63
63
|
}, progressSteps.map(function (step, stepIndex) {
|
64
64
|
return /*#__PURE__*/React__default.createElement(ProgressStep, {
|
65
|
-
label: step === null || step ===
|
65
|
+
label: step === null || step === void 0 ? void 0 : step.title,
|
66
66
|
key: stepIndex,
|
67
67
|
secondaryLabel: step.secondaryLabel || undefined,
|
68
68
|
invalid: step.invalid
|
@@ -59,7 +59,7 @@ var CreateModal = /*#__PURE__*/React__default.forwardRef(function (_ref2, ref) {
|
|
59
59
|
size: "sm",
|
60
60
|
preventCloseOnClickOutside: true,
|
61
61
|
onClose: function onClose() {
|
62
|
-
onRequestClose === null || onRequestClose ===
|
62
|
+
onRequestClose === null || onRequestClose === void 0 || onRequestClose();
|
63
63
|
return false;
|
64
64
|
}
|
65
65
|
}, getDevtoolsProps(componentName)), /*#__PURE__*/React__default.createElement(ModalHeader, {
|
@@ -47,7 +47,7 @@ var CreateSidePanel = /*#__PURE__*/React__default.forwardRef(function (_ref, ref
|
|
47
47
|
label: primaryButtonText,
|
48
48
|
onClick: function onClick(event) {
|
49
49
|
event.preventDefault();
|
50
|
-
onRequestSubmit === null || onRequestSubmit ===
|
50
|
+
onRequestSubmit === null || onRequestSubmit === void 0 || onRequestSubmit();
|
51
51
|
},
|
52
52
|
kind: 'primary',
|
53
53
|
disabled: disableSubmit,
|
@@ -46,7 +46,7 @@ var CreateTearsheet = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
46
46
|
description = _ref.description,
|
47
47
|
hasError = _ref.hasError,
|
48
48
|
_ref$influencerWidth = _ref.influencerWidth,
|
49
|
-
influencerWidth = _ref$influencerWidth ===
|
49
|
+
influencerWidth = _ref$influencerWidth === void 0 ? 'narrow' : _ref$influencerWidth,
|
50
50
|
initialStep = _ref.initialStep,
|
51
51
|
label = _ref.label,
|
52
52
|
nextButtonText = _ref.nextButtonText,
|
@@ -59,7 +59,7 @@ var CreateTearsheet = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
59
59
|
submitButtonText = _ref.submitButtonText,
|
60
60
|
title = _ref.title,
|
61
61
|
_ref$verticalPosition = _ref.verticalPosition,
|
62
|
-
verticalPosition = _ref$verticalPosition ===
|
62
|
+
verticalPosition = _ref$verticalPosition === void 0 ? 'normal' : _ref$verticalPosition,
|
63
63
|
rest = _objectWithoutProperties(_ref, _excluded);
|
64
64
|
var _useState = useState([]),
|
65
65
|
_useState2 = _slicedToArray(_useState, 2),
|
@@ -152,7 +152,7 @@ var CreateTearsheet = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
152
152
|
stepData: stepData,
|
153
153
|
/**@ts-ignore */
|
154
154
|
initialStep: initialStep,
|
155
|
-
totalSteps: stepData === null || stepData ===
|
155
|
+
totalSteps: stepData === null || stepData === void 0 ? void 0 : stepData.length,
|
156
156
|
componentName: componentName
|
157
157
|
});
|
158
158
|
useCreateComponentStepChange({
|
@@ -178,7 +178,7 @@ var CreateTearsheet = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
178
178
|
isSubmitting: isSubmitting,
|
179
179
|
componentBlockClass: blockClass,
|
180
180
|
experimentalSecondarySubmit: experimentalSecondarySubmit,
|
181
|
-
experimentalSecondarySubmitText: experimentalSecondarySubmit !== null && experimentalSecondarySubmit !==
|
181
|
+
experimentalSecondarySubmitText: experimentalSecondarySubmit !== null && experimentalSecondarySubmit !== void 0 && experimentalSecondarySubmit.labelText ? experimentalSecondarySubmit.labelText : experimentalSecondarySubmitText,
|
182
182
|
setCreateComponentActions: setCreateTearsheetActions
|
183
183
|
});
|
184
184
|
return /*#__PURE__*/React__default.createElement(TearsheetShell, _extends({}, getDevtoolsProps(componentName), rest, {
|
@@ -43,9 +43,9 @@ var CreateTearsheetStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
43
43
|
experimentalSecondarySubmit = _ref.experimentalSecondarySubmit,
|
44
44
|
fieldsetLegendText = _ref.fieldsetLegendText,
|
45
45
|
_ref$hasFieldset = _ref.hasFieldset,
|
46
|
-
hasFieldset = _ref$hasFieldset ===
|
46
|
+
hasFieldset = _ref$hasFieldset === void 0 ? defaults.hasFieldset : _ref$hasFieldset,
|
47
47
|
_ref$includeStep = _ref.includeStep,
|
48
|
-
includeStep = _ref$includeStep ===
|
48
|
+
includeStep = _ref$includeStep === void 0 ? defaults.includeStep : _ref$includeStep,
|
49
49
|
introStep = _ref.introStep,
|
50
50
|
invalid = _ref.invalid,
|
51
51
|
onMount = _ref.onMount,
|
@@ -65,7 +65,7 @@ var CreateTearsheetStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
65
65
|
shouldIncludeStep = _useState2[0],
|
66
66
|
setShouldIncludeStep = _useState2[1];
|
67
67
|
var previousState = usePreviousValue({
|
68
|
-
currentStep: stepsContext === null || stepsContext ===
|
68
|
+
currentStep: stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep
|
69
69
|
});
|
70
70
|
useRetrieveStepData({
|
71
71
|
stepsContext: stepsContext,
|
@@ -80,18 +80,18 @@ var CreateTearsheetStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
80
80
|
// This useEffect reports back the onMount value so that they can be used
|
81
81
|
// in the appropriate custom hooks.
|
82
82
|
useEffect(function () {
|
83
|
-
if (stepNumber === (stepsContext === null || stepsContext ===
|
84
|
-
stepsContext === null || stepsContext ===
|
85
|
-
stepsContext === null || stepsContext ===
|
83
|
+
if (stepNumber === (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep) && (previousState === null || previousState === void 0 ? void 0 : previousState.currentStep) !== (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)) {
|
84
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setOnMount(onMount);
|
85
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setExperimentalSecondarySubmit(experimentalSecondarySubmit);
|
86
86
|
}
|
87
|
-
}, [onMount, experimentalSecondarySubmit, stepsContext, stepNumber, previousState === null || previousState ===
|
87
|
+
}, [onMount, experimentalSecondarySubmit, stepsContext, stepNumber, previousState === null || previousState === void 0 ? void 0 : previousState.currentStep]);
|
88
88
|
|
89
89
|
// Used to take the `includeStep` prop and use it as a local state value
|
90
90
|
useEffect(function () {
|
91
91
|
setShouldIncludeStep(includeStep);
|
92
92
|
}, [includeStep, stepsContext, title]);
|
93
93
|
var setFocusChildrenTabIndex = function setFocusChildrenTabIndex(childInputs, value) {
|
94
|
-
if (childInputs !== null && childInputs !==
|
94
|
+
if (childInputs !== null && childInputs !== void 0 && childInputs.length) {
|
95
95
|
childInputs.forEach(function (child) {
|
96
96
|
child.tabIndex = value;
|
97
97
|
});
|
@@ -102,25 +102,25 @@ var CreateTearsheetStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
102
102
|
// steps container context so that it can manage the 'Next' button appropriately.
|
103
103
|
useEffect(function () {
|
104
104
|
var focusElementQuery = "button, input, select, textarea, a";
|
105
|
-
if (stepNumber !== (stepsContext === null || stepsContext ===
|
105
|
+
if (stepNumber !== (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)) {
|
106
106
|
// Specify tab-index -1 for focusable elements not contained
|
107
107
|
// in the current step so that the useFocus hook can exclude
|
108
108
|
// from the focus trap
|
109
|
-
var childInputs = stepRefValue === null || stepRefValue ===
|
109
|
+
var childInputs = stepRefValue === null || stepRefValue === void 0 ? void 0 : stepRefValue.querySelectorAll(focusElementQuery);
|
110
110
|
setFocusChildrenTabIndex(childInputs, -1);
|
111
111
|
}
|
112
|
-
if (stepNumber === (stepsContext === null || stepsContext ===
|
112
|
+
if (stepNumber === (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)) {
|
113
113
|
// Specify tab-index 0 for current step focusable elements
|
114
114
|
// for the useFocus hook to know which elements to include
|
115
115
|
// in focus trap
|
116
|
-
var _childInputs = stepRefValue === null || stepRefValue ===
|
116
|
+
var _childInputs = stepRefValue === null || stepRefValue === void 0 ? void 0 : stepRefValue.querySelectorAll(focusElementQuery);
|
117
117
|
setFocusChildrenTabIndex(_childInputs, 0);
|
118
118
|
stepsContext.setIsDisabled(!!disableSubmit);
|
119
|
-
stepsContext === null || stepsContext ===
|
120
|
-
stepsContext === null || stepsContext ===
|
119
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setOnNext(onNext); // needs to be updated here otherwise there could be stale state values from only initially setting onNext
|
120
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setOnPrevious(onPrevious);
|
121
121
|
|
122
122
|
//Handle props for experimentalSecondarySubmit button, depending on state change
|
123
|
-
stepsContext === null || stepsContext ===
|
123
|
+
stepsContext === null || stepsContext === void 0 || stepsContext.setExperimentalSecondarySubmit(experimentalSecondarySubmit);
|
124
124
|
}
|
125
125
|
}, [stepsContext, stepNumber, disableSubmit, onNext, onPrevious, stepRef, stepRefValue, experimentalSecondarySubmit]);
|
126
126
|
var renderDescription = function renderDescription() {
|
@@ -141,7 +141,7 @@ var CreateTearsheetStep = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
141
141
|
return stepsContext ? /*#__PURE__*/React__default.createElement("div", {
|
142
142
|
ref: stepRef
|
143
143
|
}, /*#__PURE__*/React__default.createElement(Grid, _extends({}, rest, {
|
144
|
-
className: cx(blockClass, className, _defineProperty(_defineProperty({}, "".concat(blockClass, "__step--hidden-step"), stepNumber !== (stepsContext === null || stepsContext ===
|
144
|
+
className: cx(blockClass, className, _defineProperty(_defineProperty({}, "".concat(blockClass, "__step--hidden-step"), stepNumber !== (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)), "".concat(blockClass, "__step--visible-step"), stepNumber === (stepsContext === null || stepsContext === void 0 ? void 0 : stepsContext.currentStep)))
|
145
145
|
}), /*#__PURE__*/React__default.createElement(Column, {
|
146
146
|
xlg: 12,
|
147
147
|
lg: 12,
|
@@ -64,7 +64,7 @@ var CreateTearsheetNarrow = /*#__PURE__*/React__default.forwardRef(function (_re
|
|
64
64
|
open: open,
|
65
65
|
ref: ref,
|
66
66
|
onClose: function onClose() {
|
67
|
-
onRequestClose === null || onRequestClose ===
|
67
|
+
onRequestClose === null || onRequestClose === void 0 || onRequestClose();
|
68
68
|
return false;
|
69
69
|
},
|
70
70
|
label: label,
|