@carbon/ibm-products 1.73.0 → 1.73.2
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 +34 -53
- package/css/index-full-carbon.css.map +1 -1
- package/css/index-full-carbon.min.css +1 -14
- package/css/index-full-carbon.min.css.map +1 -1
- package/css/index-without-carbon-released-only.css +25 -40
- package/css/index-without-carbon-released-only.css.map +1 -1
- package/css/index-without-carbon-released-only.min.css +1 -12
- package/css/index-without-carbon-released-only.min.css.map +1 -1
- package/css/index-without-carbon.css +27 -47
- package/css/index-without-carbon.css.map +1 -1
- package/css/index-without-carbon.min.css +1 -14
- package/css/index-without-carbon.min.css.map +1 -1
- package/css/index.css +31 -51
- package/css/index.css.map +1 -1
- package/css/index.min.css +1 -14
- package/css/index.min.css.map +1 -1
- package/es/components/APIKeyModal/APIKeyDownloader.js +1 -1
- package/es/components/APIKeyModal/APIKeyModal.js +3 -3
- package/es/components/AboutModal/AboutModal.js +2 -2
- package/es/components/ActionBar/ActionBar.js +4 -4
- package/es/components/ActionBar/ActionBarItem.js +2 -2
- package/es/components/ActionSet/ActionSet.js +5 -6
- package/es/components/AddSelect/AddSelectBody.js +4 -4
- package/es/components/AddSelect/AddSelectColumn.js +5 -4
- package/es/components/AddSelect/AddSelectFilter.js +2 -2
- package/es/components/AddSelect/AddSelectList.js +2 -3
- package/es/components/AddSelect/AddSelectSidebar.js +1 -1
- package/es/components/AddSelect/add-select-utils.js +7 -6
- package/es/components/AddSelect/hooks/usePath.js +2 -2
- package/es/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +4 -5
- package/es/components/ButtonMenu/ButtonMenu.js +0 -1
- package/es/components/ButtonSetWithOverflow/ButtonSetWithOverflow.js +5 -5
- package/es/components/Card/Card.js +3 -4
- package/es/components/Card/CardHeader.js +1 -2
- package/es/components/Cascade/Cascade.js +2 -2
- package/es/components/Coachmark/Coachmark.js +1 -1
- package/es/components/CoachmarkBeacon/CoachmarkBeacon.js +2 -3
- package/es/components/CoachmarkFixed/CoachmarkFixed.js +1 -2
- package/es/components/CoachmarkStack/CoachmarkStackHome.js +1 -1
- package/es/components/ComboButton/ComboButton.js +2 -2
- package/es/components/CreateFullPage/CreateFullPageStep.js +3 -4
- package/es/components/CreateInfluencer/CreateInfluencer.js +0 -1
- package/es/components/CreateModal/CreateModal.js +1 -1
- package/es/components/CreateSidePanel/CreateSidePanel.js +2 -2
- package/es/components/CreateTearsheet/CreateTearsheetStep.js +3 -4
- package/es/components/CreateTearsheetNarrow/CreateTearsheetNarrow.js +1 -1
- package/es/components/DataSpreadsheet/DataSpreadsheet.js +3 -5
- package/es/components/DataSpreadsheet/DataSpreadsheetBody.js +7 -8
- package/es/components/DataSpreadsheet/DataSpreadsheetHeader.js +4 -5
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetEdit.js +2 -3
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseMove.js +5 -5
- package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.js +4 -4
- package/es/components/DataSpreadsheet/utils/checkSelectedHeaderCell.js +4 -4
- package/es/components/DataSpreadsheet/utils/createActiveCellFn.js +1 -2
- package/es/components/DataSpreadsheet/utils/createCellSelectionArea.js +0 -1
- package/es/components/DataSpreadsheet/utils/generateData.js +2 -2
- package/es/components/DataSpreadsheet/utils/handleActiveCellInSelectionEnter.js +2 -2
- package/es/components/DataSpreadsheet/utils/handleCellDeletion.js +4 -4
- package/es/components/DataSpreadsheet/utils/handleEditSubmit.js +2 -4
- package/es/components/DataSpreadsheet/utils/handleHeaderCellSelection.js +2 -2
- package/es/components/DataSpreadsheet/utils/handleMultipleKeys.js +2 -2
- package/es/components/DataSpreadsheet/utils/selectAllCells.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridContent.js +1 -2
- package/es/components/Datagrid/Datagrid/DatagridHeaderRow.js +4 -5
- package/es/components/Datagrid/Datagrid/DatagridRefBody.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridRow.js +15 -16
- package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridSimpleBody.js +2 -2
- package/es/components/Datagrid/Datagrid/DatagridVirtualBody.js +2 -3
- package/es/components/Datagrid/Datagrid/DraggableElement.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +1 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +3 -4
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +11 -11
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +2 -3
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +11 -11
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/returnUpdatedActiveCell.js +3 -3
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +5 -5
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleMultipleKeys.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +1 -1
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +0 -2
- package/es/components/Datagrid/Datagrid/addons/stateReducer.js +5 -5
- package/es/components/Datagrid/Datagrid.stories/common.js +5 -5
- package/es/components/Datagrid/useActionsColumn.js +3 -5
- package/es/components/Datagrid/useColumnCenterAlign.js +2 -2
- package/es/components/Datagrid/useColumnRightAlign.js +2 -2
- package/es/components/Datagrid/useCustomizeColumns.js +2 -2
- package/es/components/Datagrid/useDatagrid.js +2 -2
- package/es/components/Datagrid/useDefaultStringRenderer.js +2 -2
- package/es/components/Datagrid/useDisableSelectRows.js +4 -4
- package/es/components/Datagrid/useExpandedRow.js +2 -2
- package/es/components/Datagrid/useFiltering.js +7 -8
- package/es/components/Datagrid/useFloatingScroll.js +1 -1
- package/es/components/Datagrid/useInitialColumnSort.js +1 -1
- package/es/components/Datagrid/useInlineEdit.js +2 -2
- package/es/components/Datagrid/useNestedRowExpander.js +3 -4
- package/es/components/Datagrid/useNestedRows.js +1 -2
- package/es/components/Datagrid/useRowExpander.js +2 -2
- package/es/components/Datagrid/useRowIsMouseOver.js +2 -2
- package/es/components/Datagrid/useRowRenderer.js +3 -3
- package/es/components/Datagrid/useRowSize.js +2 -2
- package/es/components/Datagrid/useSelectRows.js +4 -5
- package/es/components/Datagrid/useSortableColumns.js +3 -4
- package/es/components/Datagrid/useStickyColumn.js +5 -7
- package/es/components/Datagrid/utils/DatagridPagination.js +0 -1
- package/es/components/Datagrid/utils/filterPropsForTesting.js +2 -3
- package/es/components/Datagrid/utils/makeData.js +5 -5
- package/es/components/EditInPlace/EditInPlace.js +2 -2
- package/es/components/EditSidePanel/EditSidePanel.js +2 -2
- package/es/components/EditTearsheet/EditTearsheetForm.js +1 -2
- package/es/components/EmptyStates/EmptyState.js +2 -2
- package/es/components/EmptyStates/EmptyStateContent.js +2 -2
- package/es/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +2 -2
- package/es/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +2 -2
- package/es/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +2 -2
- package/es/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +2 -2
- package/es/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +2 -2
- package/es/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +2 -2
- package/es/components/ExampleComponent/ExampleComponent.js +2 -2
- package/es/components/ExportModal/ExportModal.js +5 -5
- package/es/components/FilterSummary/FilterSummary.js +3 -3
- package/es/components/HTTPErrors/HTTPErrorContent.js +2 -2
- package/es/components/ImportModal/ImportModal.js +3 -3
- package/es/components/InlineEdit/InlineEdit.js +2 -2
- package/es/components/InlineEditV1/InlineEditV1.js +5 -4
- package/es/components/InlineEditV2/InlineEditV2.js +3 -4
- package/es/components/InlineTip/utils.js +6 -5
- package/es/components/InterstitialScreen/InterstitialScreen.js +4 -5
- package/es/components/InterstitialScreenViewModule/InterstitialScreenViewModule.js +0 -1
- package/es/components/NotificationsPanel/NotificationsPanel.js +2 -3
- package/es/components/PageHeader/PageHeader.js +11 -13
- package/es/components/PageHeader/PageHeaderUtils.js +2 -2
- package/es/components/ProductiveCard/ProductiveCard.js +2 -2
- package/es/components/RemoveModal/RemoveModal.js +2 -2
- package/es/components/Saving/Saving.js +6 -6
- package/es/components/SidePanel/SidePanel.js +17 -18
- package/es/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +2 -2
- package/es/components/TagSet/TagSet.js +4 -4
- package/es/components/TagSet/TagSetModal.js +5 -5
- package/es/components/TagSet/TagSetOverflow.js +1 -2
- package/es/components/Tearsheet/Tearsheet.js +2 -2
- package/es/components/Tearsheet/TearsheetNarrow.js +2 -2
- package/es/components/Tearsheet/TearsheetShell.js +10 -11
- package/es/components/WebTerminal/WebTerminal.js +3 -4
- package/es/global/js/hooks/useCreateComponentFocus.js +1 -1
- package/es/global/js/hooks/useCreateComponentStepChange.js +3 -3
- package/es/global/js/hooks/useFocus.js +4 -4
- package/es/global/js/hooks/useWindowResize.js +2 -2
- package/es/global/js/package-settings.js +2 -3
- package/es/global/js/utils/Wrap.js +3 -3
- package/es/global/js/utils/deepCloneObject.js +4 -3
- package/es/global/js/utils/getNodeTextContent.js +6 -5
- package/es/global/js/utils/motionConstants.js +0 -1
- package/es/global/js/utils/props-helper.js +3 -3
- package/es/global/js/utils/scrollableAncestor.js +3 -3
- package/es/global/js/utils/story-helper.js +1 -1
- package/es/global/js/utils/test-helper.js +1 -1
- package/es/global/js/utils/unwrap-if-fragment.js +6 -6
- package/lib/components/APIKeyModal/APIKeyDownloader.js +4 -5
- package/lib/components/APIKeyModal/APIKeyModal.js +12 -8
- package/lib/components/AboutModal/AboutModal.js +14 -6
- package/lib/components/ActionBar/ActionBar.js +16 -9
- package/lib/components/ActionBar/ActionBarItem.js +12 -5
- package/lib/components/ActionBar/ActionBarOverflowItems.js +3 -4
- package/lib/components/ActionSet/ActionSet.js +15 -8
- package/lib/components/ActionSet/actions.js +4 -7
- package/lib/components/AddSelect/AddSelect.js +9 -5
- package/lib/components/AddSelect/AddSelectBody.js +13 -9
- package/lib/components/AddSelect/AddSelectBreadcrumbs.js +1 -2
- package/lib/components/AddSelect/AddSelectColumn.js +12 -8
- package/lib/components/AddSelect/AddSelectFilter.js +10 -6
- package/lib/components/AddSelect/AddSelectList.js +3 -5
- package/lib/components/AddSelect/AddSelectMetaPanel.js +3 -4
- package/lib/components/AddSelect/AddSelectSidebar.js +8 -4
- package/lib/components/AddSelect/AddSelectSort.js +1 -2
- package/lib/components/AddSelect/add-select-utils.js +10 -14
- package/lib/components/AddSelect/hooks/useItemSort.js +2 -3
- package/lib/components/AddSelect/hooks/useParentSelect.js +1 -2
- package/lib/components/AddSelect/hooks/usePath.js +8 -4
- package/lib/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +16 -10
- package/lib/components/ButtonMenu/ButtonMenu.js +10 -3
- package/lib/components/ButtonMenu/ButtonMenuItem.js +1 -2
- package/lib/components/ButtonSetWithOverflow/ButtonSetWithOverflow.js +13 -9
- package/lib/components/Card/Card.js +12 -9
- package/lib/components/Card/CardFooter.js +1 -2
- package/lib/components/Card/CardHeader.js +2 -4
- package/lib/components/Carousel/Carousel.js +9 -4
- package/lib/components/Carousel/CarouselItem.js +8 -2
- package/lib/components/Cascade/Cascade.js +11 -7
- package/lib/components/Checklist/Checklist.js +19 -4
- package/lib/components/Checklist/ChecklistChart.js +15 -2
- package/lib/components/Checklist/ChecklistIcon.js +17 -2
- package/lib/components/Coachmark/Coachmark.js +10 -5
- package/lib/components/Coachmark/CoachmarkDragbar.js +11 -4
- package/lib/components/Coachmark/CoachmarkHeader.js +9 -2
- package/lib/components/Coachmark/CoachmarkOverlay.js +11 -4
- package/lib/components/Coachmark/CoachmarkTagline.js +9 -2
- package/lib/components/Coachmark/utils/constants.js +2 -3
- package/lib/components/Coachmark/utils/context.js +3 -5
- package/lib/components/Coachmark/utils/enums.js +4 -7
- package/lib/components/Coachmark/utils/hooks.js +2 -3
- package/lib/components/CoachmarkBeacon/CoachmarkBeacon.js +11 -5
- package/lib/components/CoachmarkButton/CoachmarkButton.js +9 -2
- package/lib/components/CoachmarkFixed/CoachmarkFixed.js +12 -6
- package/lib/components/CoachmarkOverlayElement/CoachmarkOverlayElement.js +9 -2
- package/lib/components/CoachmarkOverlayElements/CoachmarkOverlayElements.js +11 -4
- package/lib/components/CoachmarkStack/CoachmarkStack.js +9 -4
- package/lib/components/CoachmarkStack/CoachmarkStackHome.js +10 -5
- package/lib/components/ComboButton/ComboButton.js +11 -6
- package/lib/components/ComboButton/ComboButtonItem/index.js +1 -2
- package/lib/components/CreateFullPage/CreateFullPage.js +14 -8
- package/lib/components/CreateFullPage/CreateFullPageStep.js +12 -8
- package/lib/components/CreateInfluencer/CreateInfluencer.js +1 -3
- package/lib/components/CreateModal/CreateModal.js +10 -3
- package/lib/components/CreateSidePanel/CreateSidePanel.js +12 -4
- package/lib/components/CreateTearsheet/CreateTearsheet.js +11 -8
- package/lib/components/CreateTearsheet/CreateTearsheetDivider.js +9 -4
- package/lib/components/CreateTearsheet/CreateTearsheetStep.js +12 -8
- package/lib/components/CreateTearsheet/preview-components/MultiStepTearsheet.js +11 -5
- package/lib/components/CreateTearsheet/preview-components/MultiStepWithIntro.js +4 -5
- package/lib/components/CreateTearsheetNarrow/CreateTearsheetNarrow.js +10 -3
- package/lib/components/DataSpreadsheet/DataSpreadsheet.js +14 -9
- package/lib/components/DataSpreadsheet/DataSpreadsheetBody.js +15 -12
- package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.js +12 -9
- package/lib/components/DataSpreadsheet/hooks/useMoveActiveCell.js +2 -3
- package/lib/components/DataSpreadsheet/hooks/useMultipleKeyTracking.js +2 -3
- package/lib/components/DataSpreadsheet/hooks/useResetSpreadsheetFocus.js +2 -3
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetEdit.js +4 -6
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseMove.js +7 -8
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.js +11 -7
- package/lib/components/DataSpreadsheet/hooks/useSpreadsheetOutsideClick.js +2 -3
- package/lib/components/DataSpreadsheet/utils/checkActiveHeaderCell.js +2 -3
- package/lib/components/DataSpreadsheet/utils/checkSelectedHeaderCell.js +6 -7
- package/lib/components/DataSpreadsheet/utils/createActiveCellFn.js +3 -5
- package/lib/components/DataSpreadsheet/utils/createCellSelectionArea.js +2 -4
- package/lib/components/DataSpreadsheet/utils/generateData.js +4 -5
- package/lib/components/DataSpreadsheet/utils/getCellSize.js +2 -3
- package/lib/components/DataSpreadsheet/utils/getSelectionAreaPoints.js +2 -3
- package/lib/components/DataSpreadsheet/utils/getSpreadsheetWidth.js +2 -3
- package/lib/components/DataSpreadsheet/utils/handleActiveCellInSelectionEnter.js +9 -5
- package/lib/components/DataSpreadsheet/utils/handleActiveCellInSelectionTab.js +2 -3
- package/lib/components/DataSpreadsheet/utils/handleCellDeletion.js +6 -7
- package/lib/components/DataSpreadsheet/utils/handleEditSubmit.js +9 -7
- package/lib/components/DataSpreadsheet/utils/handleHeaderCellSelection.js +4 -5
- package/lib/components/DataSpreadsheet/utils/handleMultipleKeys.js +11 -9
- package/lib/components/DataSpreadsheet/utils/moveColumnIndicatorLine.js +2 -3
- package/lib/components/DataSpreadsheet/utils/removeCellSelections.js +2 -3
- package/lib/components/DataSpreadsheet/utils/selectAllCells.js +9 -5
- package/lib/components/Datagrid/Datagrid/Datagrid.js +7 -2
- package/lib/components/Datagrid/Datagrid/DatagridBody.js +1 -2
- package/lib/components/Datagrid/Datagrid/DatagridContent.js +4 -6
- package/lib/components/Datagrid/Datagrid/DatagridEmptyBody.js +1 -2
- package/lib/components/Datagrid/Datagrid/DatagridExpandedRow.js +1 -2
- package/lib/components/Datagrid/Datagrid/DatagridHead.js +1 -2
- package/lib/components/Datagrid/Datagrid/DatagridHeaderRow.js +12 -9
- package/lib/components/Datagrid/Datagrid/DatagridRefBody.js +9 -4
- package/lib/components/Datagrid/Datagrid/DatagridRow.js +21 -18
- package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +11 -6
- package/lib/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +9 -4
- package/lib/components/Datagrid/Datagrid/DatagridSimpleBody.js +9 -4
- package/lib/components/Datagrid/Datagrid/DatagridToolbar.js +9 -4
- package/lib/components/Datagrid/Datagrid/DatagridVirtualBody.js +10 -7
- package/lib/components/Datagrid/Datagrid/DraggableElement.js +2 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.js +3 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +9 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +3 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +10 -6
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +8 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +9 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/common.js +2 -3
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +4 -6
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +6 -8
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +12 -10
- package/lib/components/Datagrid/Datagrid/addons/Filtering/constants.js +15 -30
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilterContext.js +1 -2
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +19 -15
- 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/Filtering/motion/variants.js +4 -7
- package/lib/components/Datagrid/Datagrid/addons/Filtering/utils.js +2 -3
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +3 -5
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +19 -15
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js +11 -8
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/getCellIdAsObject.js +2 -3
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/returnUpdatedActiveCell.js +10 -6
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridFocus.js +2 -3
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +12 -8
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleMultipleKeys.js +3 -4
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +10 -5
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +3 -6
- package/lib/components/Datagrid/Datagrid/addons/stateReducer.js +16 -16
- package/lib/components/Datagrid/Datagrid.stories/CustomizeColumnStory.js +2 -3
- package/lib/components/Datagrid/Datagrid.stories/RowSizeDropdownStory.js +2 -3
- package/lib/components/Datagrid/Datagrid.stories/SelectAllWithToggleStory.js +2 -3
- package/lib/components/Datagrid/Datagrid.stories/common.js +9 -12
- package/lib/components/Datagrid/common-column-ids.js +1 -2
- package/lib/components/Datagrid/useActionsColumn.js +10 -7
- package/lib/components/Datagrid/useColumnCenterAlign.js +8 -4
- package/lib/components/Datagrid/useColumnOrder.js +1 -2
- package/lib/components/Datagrid/useColumnRightAlign.js +8 -4
- package/lib/components/Datagrid/useCustomizeColumns.js +10 -6
- package/lib/components/Datagrid/useDatagrid.js +9 -4
- package/lib/components/Datagrid/useDefaultStringRenderer.js +9 -4
- package/lib/components/Datagrid/useDisableSelectRows.js +5 -6
- package/lib/components/Datagrid/useEditableCell.js +1 -2
- package/lib/components/Datagrid/useExpandedRow.js +8 -4
- package/lib/components/Datagrid/useFiltering.js +13 -10
- package/lib/components/Datagrid/useFlexResize.js +1 -2
- package/lib/components/Datagrid/useFloatingScroll.js +2 -3
- package/lib/components/Datagrid/useFocusRowExpander.js +2 -3
- package/lib/components/Datagrid/useInfiniteScroll.js +1 -2
- package/lib/components/Datagrid/useInitialColumnSort.js +3 -4
- package/lib/components/Datagrid/useInlineEdit.js +5 -6
- package/lib/components/Datagrid/useNestedRowExpander.js +11 -8
- package/lib/components/Datagrid/useNestedRows.js +2 -4
- package/lib/components/Datagrid/useOnRowClick.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 +10 -6
- package/lib/components/Datagrid/useRowIsMouseOver.js +9 -4
- package/lib/components/Datagrid/useRowRenderer.js +4 -5
- package/lib/components/Datagrid/useRowSize.js +9 -4
- package/lib/components/Datagrid/useSelectAllToggle.js +3 -4
- package/lib/components/Datagrid/useSelectRows.js +12 -9
- package/lib/components/Datagrid/useSkeletonRows.js +1 -2
- package/lib/components/Datagrid/useSortableColumns.js +10 -8
- package/lib/components/Datagrid/useStickyColumn.js +11 -9
- package/lib/components/Datagrid/utils/DatagridActions.js +4 -5
- package/lib/components/Datagrid/utils/DatagridPagination.js +2 -4
- package/lib/components/Datagrid/utils/Wrapper.js +2 -3
- package/lib/components/Datagrid/utils/filterPropsForTesting.js +5 -8
- package/lib/components/Datagrid/utils/getArgTypes.js +2 -3
- package/lib/components/Datagrid/utils/getAutoSizedColumnWidth.js +2 -3
- package/lib/components/Datagrid/utils/getInlineEditColumns.js +3 -5
- package/lib/components/Datagrid/utils/handleFilterTagLabelText.js +2 -3
- package/lib/components/Datagrid/utils/makeData.js +13 -11
- package/lib/components/EditFullPage/EditFullPage.js +9 -2
- package/lib/components/EditInPlace/EditInPlace.js +11 -6
- package/lib/components/EditSidePanel/EditSidePanel.js +12 -4
- package/lib/components/EditTearsheet/EditTearsheet.js +11 -8
- package/lib/components/EditTearsheet/EditTearsheetForm.js +10 -6
- package/lib/components/EditTearsheet/preview-components/MultiFormEditTearsheet.js +4 -5
- package/lib/components/EditTearsheetNarrow/EditTearsheetNarrow.js +9 -2
- package/lib/components/EditUpdateCards/EditUpdateCards.js +9 -2
- package/lib/components/EmptyStates/EmptyState.js +12 -6
- package/lib/components/EmptyStates/EmptyStateContent.js +10 -4
- package/lib/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +11 -4
- package/lib/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +11 -4
- package/lib/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +11 -4
- package/lib/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +11 -4
- package/lib/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +11 -4
- package/lib/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +11 -4
- package/lib/components/EmptyStates/assets/ErrorIllustration.js +9 -2
- package/lib/components/EmptyStates/assets/NoDataIllustration.js +9 -2
- package/lib/components/EmptyStates/assets/NoTagsIllustration.js +9 -2
- package/lib/components/EmptyStates/assets/NotFoundIllustration.js +9 -2
- package/lib/components/EmptyStates/assets/NotificationsIllustration.js +9 -2
- package/lib/components/EmptyStates/assets/UnauthorizedIllustration.js +9 -2
- package/lib/components/ExampleComponent/ExampleComponent.js +14 -6
- package/lib/components/ExampleComponent/useExample.js +1 -2
- package/lib/components/ExportModal/ExportModal.js +14 -10
- package/lib/components/ExpressiveCard/ExpressiveCard.js +3 -4
- package/lib/components/FilterSummary/FilterSummary.js +12 -7
- package/lib/components/Guidebanner/Guidebanner.js +11 -4
- package/lib/components/Guidebanner/GuidebannerElement.js +9 -2
- package/lib/components/Guidebanner/GuidebannerElementButton.js +9 -2
- package/lib/components/Guidebanner/GuidebannerElementLink.js +9 -2
- package/lib/components/HTTPErrors/HTTPError403/HTTPError403.js +9 -2
- package/lib/components/HTTPErrors/HTTPError404/HTTPError404.js +9 -2
- package/lib/components/HTTPErrors/HTTPErrorContent.js +10 -4
- package/lib/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +9 -2
- package/lib/components/HTTPErrors/assets/HTTPErrorSvg403.js +1 -2
- package/lib/components/HTTPErrors/assets/HTTPErrorSvg404.js +1 -2
- package/lib/components/HTTPErrors/assets/HTTPErrorSvgOther.js +1 -2
- package/lib/components/ImportModal/ImportModal.js +12 -8
- package/lib/components/InlineEdit/InlineEdit.js +11 -6
- package/lib/components/InlineEditV1/InlineEditV1.js +18 -8
- package/lib/components/InlineEditV2/InlineEditV2.js +13 -10
- package/lib/components/InlineTip/InlineTip.js +11 -4
- package/lib/components/InlineTip/InlineTipButton.js +9 -2
- package/lib/components/InlineTip/InlineTipLink.js +9 -2
- package/lib/components/InlineTip/utils.js +5 -6
- package/lib/components/InterstitialScreen/InterstitialScreen.js +15 -9
- package/lib/components/InterstitialScreen/assets/index.js +4 -8
- package/lib/components/InterstitialScreenView/InterstitialScreenView.js +9 -2
- package/lib/components/InterstitialScreenViewModule/InterstitialScreenViewModule.js +9 -3
- package/lib/components/ModifiedTabs/ModifiedTabLabelNew.js +1 -2
- package/lib/components/ModifiedTabs/ModifiedTabLabelWithClose.js +1 -2
- package/lib/components/ModifiedTabs/ModifiedTabs.js +3 -4
- package/lib/components/MultiAddSelect/MultiAddSelect.js +3 -4
- package/lib/components/NonLinearReading/NonLinearReading.js +9 -4
- package/lib/components/NotificationsPanel/NotificationsPanel.js +14 -7
- package/lib/components/NotificationsPanel/NotificationsPanel_data.js +1 -2
- package/lib/components/NotificationsPanel/preview-components/UnreadNotificationBell.js +2 -3
- package/lib/components/NotificationsPanel/utils.js +1 -2
- package/lib/components/OptionsTile/OptionsTile.js +12 -4
- package/lib/components/PageHeader/PageHeader.js +21 -20
- package/lib/components/PageHeader/PageHeaderDemo.data.js +3 -4
- package/lib/components/PageHeader/PageHeaderTitle.js +2 -4
- package/lib/components/PageHeader/PageHeaderUtils.js +12 -11
- package/lib/components/ProductiveCard/ProductiveCard.js +11 -7
- package/lib/components/RemoveModal/RemoveModal.js +11 -7
- package/lib/components/Saving/Saving.js +15 -10
- package/lib/components/SidePanel/SidePanel.js +29 -22
- package/lib/components/SidePanel/constants.js +2 -3
- package/lib/components/SidePanel/motion/variants.js +3 -5
- package/lib/components/SingleAddSelect/SingleAddSelect.js +3 -4
- package/lib/components/StatusIcon/StatusIcon.js +7 -2
- package/lib/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +13 -6
- package/lib/components/SteppedAnimatedMedia/assets/index.js +3 -6
- package/lib/components/TagSet/TagSet.js +15 -13
- package/lib/components/TagSet/TagSetModal.js +14 -10
- package/lib/components/TagSet/TagSetOverflow.js +10 -7
- package/lib/components/Tearsheet/Tearsheet.js +13 -6
- package/lib/components/Tearsheet/TearsheetNarrow.js +13 -6
- package/lib/components/Tearsheet/TearsheetShell.js +26 -23
- package/lib/components/Toolbar/Toolbar.js +12 -10
- package/lib/components/Toolbar/ToolbarButton.js +10 -6
- package/lib/components/Toolbar/ToolbarGroup.js +9 -4
- package/lib/components/UserProfileImage/UserProfileImage.js +10 -2
- package/lib/components/WebTerminal/WebTerminal.js +15 -8
- package/lib/components/WebTerminal/WebTerminalContentWrapper.js +9 -2
- package/lib/components/WebTerminal/hooks/index.js +6 -9
- package/lib/components/WebTerminal/preview-components/Navigation.js +1 -2
- package/lib/components/WebTerminal/preview-components/documentationLinks.js +2 -3
- package/lib/components/_Canary/Canary.js +11 -2
- package/lib/global/js/hooks/useActiveElement.js +2 -3
- package/lib/global/js/hooks/useClickOutside.js +2 -3
- package/lib/global/js/hooks/useCreateComponentFocus.js +3 -4
- package/lib/global/js/hooks/useCreateComponentStepChange.js +5 -6
- package/lib/global/js/hooks/useFocus.js +6 -7
- package/lib/global/js/hooks/useIsomorphicEffect.js +1 -2
- package/lib/global/js/hooks/usePrefix.js +2 -3
- package/lib/global/js/hooks/usePreviousValue.js +2 -3
- package/lib/global/js/hooks/useResetCreateComponent.js +2 -3
- package/lib/global/js/hooks/useResizeObserver.js +2 -3
- package/lib/global/js/hooks/useRetrieveStepData.js +2 -3
- package/lib/global/js/hooks/useValidCreateStepCount.js +2 -3
- package/lib/global/js/hooks/useWindowResize.js +4 -5
- package/lib/global/js/package-settings.js +9 -6
- package/lib/global/js/utils/ClickListener.js +3 -4
- package/lib/global/js/utils/DisplayBox.js +1 -2
- package/lib/global/js/utils/Wrap.js +12 -5
- package/lib/global/js/utils/deepCloneObject.js +3 -4
- package/lib/global/js/utils/devtools.js +1 -2
- package/lib/global/js/utils/getBezierValues.js +2 -3
- package/lib/global/js/utils/getFocusableElements.js +2 -3
- package/lib/global/js/utils/getNodeTextContent.js +5 -6
- package/lib/global/js/utils/getNumberOfHiddenSteps.js +2 -3
- package/lib/global/js/utils/getScrollbarWidth.js +2 -3
- package/lib/global/js/utils/keyboardNavigation.js +4 -8
- package/lib/global/js/utils/lastIndexInArray.js +2 -3
- package/lib/global/js/utils/motionConstants.js +3 -5
- package/lib/global/js/utils/pconsole.js +8 -15
- package/lib/global/js/utils/props-helper.js +15 -17
- package/lib/global/js/utils/rangeWithCallback.js +2 -3
- package/lib/global/js/utils/scrollableAncestor.js +5 -6
- package/lib/global/js/utils/story-helper.js +7 -12
- package/lib/global/js/utils/test-helper.js +15 -28
- package/lib/global/js/utils/unwrap-if-fragment.js +7 -8
- package/lib/global/js/utils/uuidv4.js +1 -2
- package/lib/global/js/utils/wait.js +1 -2
- package/lib/global/js/utils/wrapFocus.js +1 -2
- package/lib/settings.js +2 -4
- package/package.json +4 -4
- package/scss/components/AboutModal/_about-modal.scss +1 -2
- package/scss/components/Coachmark/styles/_coachmark-tagline.scss +1 -4
- package/scss/components/Datagrid/styles/_datagrid.scss +1 -2
- package/scss/components/Datagrid/styles/_useStickyColumn.scss +1 -0
- package/scss/components/SidePanel/_side-panel.scss +1 -4
@@ -2,8 +2,8 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
3
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
4
4
|
var _excluded = ["children"];
|
5
|
-
function ownKeys(
|
6
|
-
function _objectSpread(
|
5
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
6
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
7
7
|
/**
|
8
8
|
* Copyright IBM Corp. 2020, 2023
|
9
9
|
*
|
@@ -30,7 +30,6 @@ var rowHeights = {
|
|
30
30
|
|
31
31
|
// eslint-disable-next-line react/prop-types
|
32
32
|
var DatagridRow = function DatagridRow(datagridState) {
|
33
|
-
var _cx;
|
34
33
|
var row = datagridState.row,
|
35
34
|
rowSize = datagridState.rowSize,
|
36
35
|
withNestedRows = datagridState.withNestedRows,
|
@@ -40,14 +39,14 @@ var DatagridRow = function DatagridRow(datagridState) {
|
|
40
39
|
withExpandedRows = datagridState.withExpandedRows,
|
41
40
|
withMouseHover = datagridState.withMouseHover,
|
42
41
|
setMouseOverRowIndex = datagridState.setMouseOverRowIndex;
|
43
|
-
var
|
42
|
+
var _getVisibleNestedRowCount = function getVisibleNestedRowCount(_ref) {
|
44
43
|
var isExpanded = _ref.isExpanded,
|
45
44
|
subRows = _ref.subRows;
|
46
45
|
var size = 0;
|
47
46
|
if (isExpanded && subRows) {
|
48
47
|
size += subRows.length;
|
49
48
|
subRows.forEach(function (child) {
|
50
|
-
size +=
|
49
|
+
size += _getVisibleNestedRowCount(child);
|
51
50
|
});
|
52
51
|
}
|
53
52
|
return size;
|
@@ -57,15 +56,15 @@ var DatagridRow = function DatagridRow(datagridState) {
|
|
57
56
|
if (!withNestedRows) {
|
58
57
|
return;
|
59
58
|
}
|
60
|
-
var subRowCount =
|
59
|
+
var subRowCount = _getVisibleNestedRowCount(row);
|
61
60
|
var totalNestedRowIndicatorHeight = px(subRowCount * rowHeights[rowSize]);
|
62
61
|
var hoverRow = event.target.closest(".".concat(blockClass, "__carbon-row-expanded"));
|
63
|
-
hoverRow === null || hoverRow === void 0
|
62
|
+
hoverRow === null || hoverRow === void 0 || hoverRow.classList.add("".concat(blockClass, "__carbon-row-expanded-hover-active"));
|
64
63
|
var rowExpanderButton = hoverRow === null || hoverRow === void 0 ? void 0 : hoverRow.querySelector(".".concat(blockClass, "__row-expander"));
|
65
64
|
var rowSizeValue = rowSize || 'lg';
|
66
|
-
hoverRow === null || hoverRow === void 0
|
67
|
-
hoverRow === null || hoverRow === void 0
|
68
|
-
hoverRow === null || hoverRow === void 0
|
65
|
+
hoverRow === null || hoverRow === void 0 || (_hoverRow$style = hoverRow.style) === null || _hoverRow$style === void 0 || _hoverRow$style.setProperty("--".concat(blockClass, "--indicator-height"), totalNestedRowIndicatorHeight);
|
66
|
+
hoverRow === null || hoverRow === void 0 || (_hoverRow$style2 = hoverRow.style) === null || _hoverRow$style2 === void 0 || _hoverRow$style2.setProperty("--".concat(blockClass, "--row-height"), px(rowHeights[rowSizeValue]));
|
67
|
+
hoverRow === null || hoverRow === void 0 || (_hoverRow$style3 = hoverRow.style) === null || _hoverRow$style3 === void 0 || _hoverRow$style3.setProperty("--".concat(blockClass, "--indicator-offset-amount"), px((rowExpanderButton === null || rowExpanderButton === void 0 ? void 0 : rowExpanderButton.offsetLeft) || 0));
|
69
68
|
};
|
70
69
|
var focusRemover = function focusRemover() {
|
71
70
|
var elements = document.querySelectorAll("#".concat(tableId, " .").concat(blockClass, "__carbon-row-expanded"));
|
@@ -77,7 +76,7 @@ var DatagridRow = function DatagridRow(datagridState) {
|
|
77
76
|
if (row.isExpanded) {
|
78
77
|
var _row$RowExpansionRend;
|
79
78
|
prepareRow(row);
|
80
|
-
return row === null || row === void 0
|
79
|
+
return row === null || row === void 0 || (_row$RowExpansionRend = row.RowExpansionRenderer) === null || _row$RowExpansionRend === void 0 ? void 0 : _row$RowExpansionRend.call(row, _objectSpread(_objectSpread({}, datagridState), {}, {
|
81
80
|
row: row
|
82
81
|
}));
|
83
82
|
}
|
@@ -88,7 +87,7 @@ var DatagridRow = function DatagridRow(datagridState) {
|
|
88
87
|
setMouseOverRowIndex(null);
|
89
88
|
}
|
90
89
|
var hoverRow = event.target.closest(".".concat(blockClass, "__carbon-row-expanded"));
|
91
|
-
hoverRow === null || hoverRow === void 0
|
90
|
+
hoverRow === null || hoverRow === void 0 || hoverRow.classList.remove("".concat(blockClass, "__carbon-row-expanded-hover-active"));
|
92
91
|
};
|
93
92
|
var handleOnKeyUp = function handleOnKeyUp(event) {
|
94
93
|
if (!withNestedRows) {
|
@@ -101,7 +100,7 @@ var DatagridRow = function DatagridRow(datagridState) {
|
|
101
100
|
};
|
102
101
|
var _row$getRowProps = row.getRowProps(),
|
103
102
|
className = _row$getRowProps.className;
|
104
|
-
var rowClassNames = cx("".concat(blockClass, "__carbon-row"), (
|
103
|
+
var rowClassNames = cx("".concat(blockClass, "__carbon-row"), _defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__carbon-row-expanded"), row.isExpanded), "".concat(blockClass, "__carbon-row-expandable"), row.canExpand), "".concat(carbon.prefix, "--data-table--selected"), row.isSelected));
|
105
104
|
var setAdditionalRowProps = function setAdditionalRowProps() {
|
106
105
|
if (withNestedRows || withExpandedRows) {
|
107
106
|
return {
|
@@ -123,21 +122,21 @@ var DatagridRow = function DatagridRow(datagridState) {
|
|
123
122
|
onBlur: focusRemover,
|
124
123
|
onKeyUp: handleOnKeyUp
|
125
124
|
}, setAdditionalRowProps()), row.cells.map(function (cell, index) {
|
126
|
-
var _cell$column
|
125
|
+
var _cell$column;
|
127
126
|
var cellProps = cell.getCellProps({
|
128
127
|
role: undefined
|
129
128
|
});
|
130
129
|
var children = cellProps.children,
|
131
130
|
restProps = _objectWithoutProperties(cellProps, _excluded);
|
132
131
|
var content = children || /*#__PURE__*/React.createElement(React.Fragment, null, !row.isSkeleton && cell.render('Cell'), row.isSkeleton && /*#__PURE__*/React.createElement(SkeletonText, null));
|
133
|
-
if ((cell === null || cell === void 0
|
132
|
+
if ((cell === null || cell === void 0 || (_cell$column = cell.column) === null || _cell$column === void 0 ? void 0 : _cell$column.id) === selectionColumnId) {
|
134
133
|
// directly render component without the wrapping TableCell
|
135
134
|
return cell.render('Cell', {
|
136
135
|
key: cell.column.id
|
137
136
|
});
|
138
137
|
}
|
139
138
|
return /*#__PURE__*/React.createElement(TableCell, _extends({
|
140
|
-
className: cx("".concat(blockClass, "__cell"), (
|
139
|
+
className: cx("".concat(blockClass, "__cell"), _defineProperty(_defineProperty({}, "".concat(blockClass, "__expandable-row-cell"), row.canExpand && index === 0), "".concat(blockClass, "__expandable-row-cell--is-expanded"), row.isExpanded && index === 0))
|
141
140
|
}, restProps, {
|
142
141
|
key: cell.column.id
|
143
142
|
}), content);
|
@@ -69,7 +69,7 @@ var SelectAll = function SelectAll(datagridState) {
|
|
69
69
|
indeterminate: true
|
70
70
|
});
|
71
71
|
toggleAllRowsSelected(false);
|
72
|
-
onAllRowSelect === null || onAllRowSelect === void 0
|
72
|
+
onAllRowSelect === null || onAllRowSelect === void 0 || onAllRowSelect(rows, event);
|
73
73
|
return onChange === null || onChange === void 0 ? void 0 : onChange({
|
74
74
|
target: {
|
75
75
|
checked: false
|
@@ -82,7 +82,7 @@ var SelectAll = function SelectAll(datagridState) {
|
|
82
82
|
getRowId: getRowId,
|
83
83
|
isChecked: event.target.checked
|
84
84
|
});
|
85
|
-
onAllRowSelect === null || onAllRowSelect === void 0
|
85
|
+
onAllRowSelect === null || onAllRowSelect === void 0 || onAllRowSelect(rows, event);
|
86
86
|
return onChange === null || onChange === void 0 ? void 0 : onChange(event);
|
87
87
|
};
|
88
88
|
return /*#__PURE__*/React.createElement("div", {
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
|
-
function ownKeys(
|
4
|
-
function _objectSpread(
|
3
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
4
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
5
5
|
/*
|
6
6
|
* Licensed Materials - Property of IBM
|
7
7
|
* 5724-Q36
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
|
-
function ownKeys(
|
4
|
-
function _objectSpread(
|
3
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
4
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
5
5
|
/**
|
6
6
|
* Copyright IBM Corp. 2020, 2023
|
7
7
|
*
|
@@ -57,7 +57,6 @@ var DatagridVirtualBody = function DatagridVirtualBody(datagridState) {
|
|
57
57
|
var spacerColumn = document.querySelector(".".concat(blockClass, "__head-wrap thead th:last-child"));
|
58
58
|
spacerColumn.style.width = px(32 + (virtualBody.offsetWidth - virtualBody.clientWidth)); // scrollbar width to header column to fix header alignment
|
59
59
|
};
|
60
|
-
|
61
60
|
useEffect(function () {
|
62
61
|
handleResize();
|
63
62
|
}, [handleResize]);
|
@@ -17,7 +17,6 @@ import { CSS } from '@dnd-kit/utilities';
|
|
17
17
|
import { useSortable } from '@dnd-kit/sortable';
|
18
18
|
var blockClass = "".concat(pkg.prefix, "--datagrid");
|
19
19
|
var DraggableElement = function DraggableElement(_ref) {
|
20
|
-
var _cx;
|
21
20
|
var id = _ref.id,
|
22
21
|
children = _ref.children,
|
23
22
|
classList = _ref.classList,
|
@@ -44,7 +43,7 @@ var DraggableElement = function DraggableElement(_ref) {
|
|
44
43
|
transition: transition
|
45
44
|
};
|
46
45
|
return /*#__PURE__*/React.createElement("li", _extends({
|
47
|
-
className: cx(classList, "".concat(blockClass, "__draggable-handleHolder"), (
|
46
|
+
className: cx(classList, "".concat(blockClass, "__draggable-handleHolder"), _defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__draggable-handleHolder--selected"), selected), "".concat(blockClass, "__draggable-handleHolder--sticky"), isSticky), "".concat(blockClass, "__draggable-handleHolder--dragging"), isDragging)),
|
48
47
|
id: id,
|
49
48
|
ref: setNodeRef,
|
50
49
|
style: style
|
package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
3
|
-
function ownKeys(
|
4
|
-
function _objectSpread(
|
3
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
4
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
5
5
|
/**
|
6
6
|
* Copyright IBM Corp. 2022, 2023
|
7
7
|
*
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
2
|
-
function ownKeys(
|
3
|
-
function _objectSpread(
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2023, 2023
|
6
6
|
*
|
@@ -28,7 +28,6 @@ var defaults = {
|
|
28
28
|
secondaryActionLabel: 'Cancel'
|
29
29
|
};
|
30
30
|
var FilterFlyout = function FilterFlyout(_ref) {
|
31
|
-
var _cx2;
|
32
31
|
var updateMethod = _ref.updateMethod,
|
33
32
|
_ref$flyoutIconDescri = _ref.flyoutIconDescription,
|
34
33
|
flyoutIconDescription = _ref$flyoutIconDescri === void 0 ? defaults.flyoutIconDescription : _ref$flyoutIconDescri,
|
@@ -216,7 +215,7 @@ var FilterFlyout = function FilterFlyout(_ref) {
|
|
216
215
|
disabled: data.length === 0
|
217
216
|
}), /*#__PURE__*/React.createElement("div", {
|
218
217
|
ref: flyoutInnerRef,
|
219
|
-
className: cx(componentClass, (
|
218
|
+
className: cx(componentClass, _defineProperty(_defineProperty(_defineProperty({}, "".concat(componentClass, "--open"), open), "".concat(componentClass, "--batch"), showActionSet), "".concat(componentClass, "--instant"), !showActionSet))
|
220
219
|
}, /*#__PURE__*/React.createElement("div", {
|
221
220
|
className: "".concat(componentClass, "__inner-container")
|
222
221
|
}, /*#__PURE__*/React.createElement("span", {
|
@@ -32,7 +32,6 @@ var defaults = {
|
|
32
32
|
searchPlaceholder: 'Find filters'
|
33
33
|
};
|
34
34
|
var FilterPanel = function FilterPanel(_ref) {
|
35
|
-
var _cx;
|
36
35
|
var _ref$title = _ref.title,
|
37
36
|
title = _ref$title === void 0 ? defaults.title : _ref$title,
|
38
37
|
_ref$closeIconDescrip = _ref.closeIconDescription,
|
@@ -175,7 +174,7 @@ var FilterPanel = function FilterPanel(_ref) {
|
|
175
174
|
}, [panelOpen, onPanelClose, onPanelOpen]);
|
176
175
|
useEffect(function setPanelMinimumHeight() {
|
177
176
|
var _filterPanelRef$curre;
|
178
|
-
(_filterPanelRef$curre = filterPanelRef.current) === null || _filterPanelRef$curre === void 0
|
177
|
+
(_filterPanelRef$curre = filterPanelRef.current) === null || _filterPanelRef$curre === void 0 || _filterPanelRef$curre.style.setProperty('--filter-panel-min-height', rem(filterPanelMinHeight));
|
179
178
|
}, [filterPanelMinHeight]);
|
180
179
|
useSubscribeToEventEmitter(CLEAR_FILTERS, reset);
|
181
180
|
var getScrollableContainerHeight = function getScrollableContainerHeight() {
|
@@ -183,13 +182,13 @@ var FilterPanel = function FilterPanel(_ref) {
|
|
183
182
|
var filterHeadingHeight = (_filterHeadingRef$cur = filterHeadingRef.current) === null || _filterHeadingRef$cur === void 0 ? void 0 : _filterHeadingRef$cur.getBoundingClientRect().height;
|
184
183
|
var filterSearchHeight = (_filterSearchRef$curr = filterSearchRef.current) === null || _filterSearchRef$curr === void 0 ? void 0 : _filterSearchRef$curr.getBoundingClientRect().height;
|
185
184
|
var actionSetHeight = (_actionSetRef$current = actionSetRef.current) === null || _actionSetRef$current === void 0 ? void 0 : _actionSetRef$current.getBoundingClientRect().height;
|
186
|
-
var height = panelOpen ? "calc(100vh - ".concat(filterHeadingHeight, "px - ").concat(
|
185
|
+
var height = panelOpen ? "calc(100vh - ".concat(filterHeadingHeight, "px - ").concat(/* istanbul ignore next */
|
187
186
|
showFilterSearch ? filterSearchHeight : 0, "px - ").concat(updateMethod === BATCH ? actionSetHeight : 0, "px)") : 0;
|
188
187
|
return height;
|
189
188
|
};
|
190
189
|
return /*#__PURE__*/React.createElement(motion.div, {
|
191
190
|
ref: filterPanelRef,
|
192
|
-
className: cx(componentClass, "".concat(componentClass, "__container"), (
|
191
|
+
className: cx(componentClass, "".concat(componentClass, "__container"), _defineProperty(_defineProperty(_defineProperty({}, "".concat(componentClass, "--open"), panelOpen), "".concat(componentClass, "--batch"), showActionSet), "".concat(componentClass, "--instant"), !showActionSet)),
|
193
192
|
initial: false,
|
194
193
|
animate: panelOpen ? 'visible' : 'hidden',
|
195
194
|
custom: shouldReduceMotion,
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
3
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
4
|
-
function ownKeys(
|
5
|
-
function _objectSpread(
|
4
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
5
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
6
6
|
/**
|
7
7
|
* Copyright IBM Corp. 2022, 2024
|
8
8
|
*
|
@@ -2,8 +2,8 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
3
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
4
4
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
5
|
-
function ownKeys(
|
6
|
-
function _objectSpread(
|
5
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
6
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
7
7
|
/**
|
8
8
|
* Copyright IBM Corp. 2023, 2024
|
9
9
|
*
|
@@ -209,7 +209,7 @@ var useFilters = function useFilters(_ref) {
|
|
209
209
|
value: value,
|
210
210
|
type: type
|
211
211
|
});
|
212
|
-
(_components$DatePicke = (_components$DatePicke2 = components.DatePicker).onChange) === null || _components$DatePicke === void 0
|
212
|
+
(_components$DatePicke = (_components$DatePicke2 = components.DatePicker).onChange) === null || _components$DatePicke === void 0 || _components$DatePicke.call(_components$DatePicke2, value);
|
213
213
|
},
|
214
214
|
value: filtersState[column].value,
|
215
215
|
datePickerType: "range",
|
@@ -239,7 +239,7 @@ var useFilters = function useFilters(_ref) {
|
|
239
239
|
value: event.target.value,
|
240
240
|
type: type
|
241
241
|
});
|
242
|
-
(_components$NumberInp = (_components$NumberInp2 = components.NumberInput).onChange) === null || _components$NumberInp === void 0
|
242
|
+
(_components$NumberInp = (_components$NumberInp2 = components.NumberInput).onChange) === null || _components$NumberInp === void 0 || _components$NumberInp.call(_components$NumberInp2, event);
|
243
243
|
},
|
244
244
|
value: filtersState[column].value,
|
245
245
|
light: isPanel
|
@@ -266,7 +266,7 @@ var useFilters = function useFilters(_ref) {
|
|
266
266
|
value: _toConsumableArray(filtersState[column].value),
|
267
267
|
type: type
|
268
268
|
});
|
269
|
-
(_option$onChange = option.onChange) === null || _option$onChange === void 0
|
269
|
+
(_option$onChange = option.onChange) === null || _option$onChange === void 0 || _option$onChange.call(option, isSelected);
|
270
270
|
},
|
271
271
|
checked: option.selected
|
272
272
|
}));
|
@@ -290,12 +290,12 @@ var useFilters = function useFilters(_ref) {
|
|
290
290
|
value: selected,
|
291
291
|
type: type
|
292
292
|
});
|
293
|
-
(_components$RadioButt2 = (_components$RadioButt3 = components.RadioButtonGroup).onChange) === null || _components$RadioButt2 === void 0
|
293
|
+
(_components$RadioButt2 = (_components$RadioButt3 = components.RadioButtonGroup).onChange) === null || _components$RadioButt2 === void 0 || _components$RadioButt2.call(_components$RadioButt3, selected);
|
294
294
|
}
|
295
295
|
}), /*#__PURE__*/React.createElement(RadioButton, _extends({
|
296
|
-
id: (_components$DefaultRa3 = components === null || components === void 0
|
297
|
-
labelText: (_components$DefaultRa5 = components === null || components === void 0
|
298
|
-
value: (_components$DefaultRa7 = components === null || components === void 0
|
296
|
+
id: (_components$DefaultRa3 = components === null || components === void 0 || (_components$DefaultRa4 = components.DefaultRadioButton) === null || _components$DefaultRa4 === void 0 ? void 0 : _components$DefaultRa4.id) !== null && _components$DefaultRa3 !== void 0 ? _components$DefaultRa3 : "any__".concat(name),
|
297
|
+
labelText: (_components$DefaultRa5 = components === null || components === void 0 || (_components$DefaultRa6 = components.DefaultRadioButton) === null || _components$DefaultRa6 === void 0 ? void 0 : _components$DefaultRa6.labelText) !== null && _components$DefaultRa5 !== void 0 ? _components$DefaultRa5 : 'Any',
|
298
|
+
value: (_components$DefaultRa7 = components === null || components === void 0 || (_components$DefaultRa8 = components.DefaultRadioButton) === null || _components$DefaultRa8 === void 0 ? void 0 : _components$DefaultRa8.value) !== null && _components$DefaultRa7 !== void 0 ? _components$DefaultRa7 : 'Any'
|
299
299
|
}, components.DefaultRadioButton)), components.RadioButton.map(function (radio) {
|
300
300
|
var _ref4, _radio$id;
|
301
301
|
return /*#__PURE__*/React.createElement(RadioButton, _extends({
|
@@ -320,7 +320,7 @@ var useFilters = function useFilters(_ref) {
|
|
320
320
|
value: selectedItem,
|
321
321
|
type: type
|
322
322
|
});
|
323
|
-
(_components$Dropdown$ = (_components$Dropdown = components.Dropdown).onChange) === null || _components$Dropdown$ === void 0
|
323
|
+
(_components$Dropdown$ = (_components$Dropdown = components.Dropdown).onChange) === null || _components$Dropdown$ === void 0 || _components$Dropdown$.call(_components$Dropdown, selectedItem);
|
324
324
|
},
|
325
325
|
light: isPanel
|
326
326
|
}));
|
@@ -384,7 +384,7 @@ var useFilters = function useFilters(_ref) {
|
|
384
384
|
value: _toConsumableArray(filtersState[column].value),
|
385
385
|
type: type
|
386
386
|
});
|
387
|
-
(_components$MultiSele = components.MultiSelect) === null || _components$MultiSele === void 0
|
387
|
+
(_components$MultiSele = components.MultiSelect) === null || _components$MultiSele === void 0 || (_components$MultiSele2 = _components$MultiSele.onChange) === null || _components$MultiSele2 === void 0 || _components$MultiSele2.call(_components$MultiSele, selectedItems);
|
388
388
|
}
|
389
389
|
}));
|
390
390
|
break;
|
package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js
CHANGED
@@ -12,7 +12,6 @@ import PropTypes from 'prop-types';
|
|
12
12
|
import { pkg } from '../../../../../../settings';
|
13
13
|
var blockClass = "".concat(pkg.prefix, "--datagrid");
|
14
14
|
export var InlineEditButton = function InlineEditButton(_ref) {
|
15
|
-
var _cx, _cx2;
|
16
15
|
var label = _ref.label,
|
17
16
|
Icon = _ref.renderIcon,
|
18
17
|
disabled = _ref.disabled,
|
@@ -23,7 +22,7 @@ export var InlineEditButton = function InlineEditButton(_ref) {
|
|
23
22
|
columnConfig = _ref.columnConfig,
|
24
23
|
type = _ref.type;
|
25
24
|
return /*#__PURE__*/React.createElement("div", {
|
26
|
-
className: cx("".concat(blockClass, "__inline-edit-button"), (
|
25
|
+
className: cx("".concat(blockClass, "__inline-edit-button"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__inline-edit-button--disabled"), disabled || nonEditCell), "".concat(blockClass, "__inline-edit-button--with-label-icon"), LabelIcon), "".concat(blockClass, "__inline-edit-button--non-edit"), nonEditCell), "".concat(blockClass, "__inline-edit-button--active"), isActiveCell), "".concat(blockClass, "__inline-edit-button--").concat(type), type === 'date' || type === 'selection')),
|
27
26
|
tabIndex: isActiveCell ? 0 : -1,
|
28
27
|
"data-disabled": disabled || nonEditCell,
|
29
28
|
"aria-disabled": disabled || nonEditCell,
|
@@ -32,7 +31,7 @@ export var InlineEditButton = function InlineEditButton(_ref) {
|
|
32
31
|
}, LabelIcon && /*#__PURE__*/React.createElement("div", {
|
33
32
|
className: "".concat(blockClass, "__label-icon")
|
34
33
|
}, /*#__PURE__*/React.createElement(LabelIcon, null)), label !== '' ? /*#__PURE__*/React.createElement("span", {
|
35
|
-
className: cx("".concat(blockClass, "__inline-edit-button-label"), (
|
34
|
+
className: cx("".concat(blockClass, "__inline-edit-button-label"), _defineProperty(_defineProperty({}, "".concat(blockClass, "__inline-edit-button-label-with-icon"), !nonEditCell), "".concat(blockClass, "__defaultStringRenderer--multiline"), columnConfig === null || columnConfig === void 0 ? void 0 : columnConfig.multiLineWrap))
|
36
35
|
}, label) : /*#__PURE__*/React.createElement("span", {
|
37
36
|
className: "".concat(blockClass, "__placeholder")
|
38
37
|
}, placeholder), !nonEditCell && Icon && /*#__PURE__*/React.createElement("div", {
|
@@ -2,8 +2,8 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _typeof from "@babel/runtime/helpers/typeof";
|
3
3
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
4
4
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
5
|
-
function ownKeys(
|
6
|
-
function _objectSpread(
|
5
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
6
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
7
7
|
/**
|
8
8
|
* Copyright IBM Corp. 2022, 2022
|
9
9
|
*
|
@@ -23,7 +23,7 @@ import { usePreviousValue } from '../../../../../../global/js/hooks';
|
|
23
23
|
import { prepareProps } from '../../../../../../global/js/utils/props-helper';
|
24
24
|
var blockClass = "".concat(pkg.prefix, "--datagrid");
|
25
25
|
export var InlineEditCell = function InlineEditCell(_ref) {
|
26
|
-
var _config$validator,
|
26
|
+
var _config$validator, _value$text;
|
27
27
|
var cell = _ref.cell,
|
28
28
|
config = _ref.config,
|
29
29
|
instance = _ref.instance,
|
@@ -109,11 +109,11 @@ export var InlineEditCell = function InlineEditCell(_ref) {
|
|
109
109
|
}, [activeCellId, cellId, nonEditCell, editId, cellValue, saveCellData]);
|
110
110
|
var openDropdown = function openDropdown(type) {
|
111
111
|
var _datePickerRef$curren;
|
112
|
-
var dropdownTrigger = type === 'selection' ? dropdownRef === null || dropdownRef === void 0 ? void 0 : dropdownRef.current : datePickerRef === null || datePickerRef === void 0
|
112
|
+
var dropdownTrigger = type === 'selection' ? dropdownRef === null || dropdownRef === void 0 ? void 0 : dropdownRef.current : datePickerRef === null || datePickerRef === void 0 || (_datePickerRef$curren = datePickerRef.current) === null || _datePickerRef$curren === void 0 ? void 0 : _datePickerRef$curren.inputField;
|
113
113
|
dropdownTrigger.click();
|
114
114
|
if (type === 'date') {
|
115
115
|
// datePickerRef.current.cal.calendarContainer.focus();
|
116
|
-
dropdownTrigger === null || dropdownTrigger === void 0
|
116
|
+
dropdownTrigger === null || dropdownTrigger === void 0 || dropdownTrigger.focus();
|
117
117
|
}
|
118
118
|
};
|
119
119
|
|
@@ -280,7 +280,7 @@ export var InlineEditCell = function InlineEditCell(_ref) {
|
|
280
280
|
});
|
281
281
|
setInEditMode(false);
|
282
282
|
sendFocusBackToGrid();
|
283
|
-
inputProps === null || inputProps === void 0
|
283
|
+
inputProps === null || inputProps === void 0 || (_inputProps$onChange = inputProps.onChange) === null || _inputProps$onChange === void 0 || _inputProps$onChange.call(inputProps, item.selectedItem);
|
284
284
|
},
|
285
285
|
downshiftProps: {
|
286
286
|
onStateChange: function onStateChange(downshiftState) {
|
@@ -318,9 +318,9 @@ export var InlineEditCell = function InlineEditCell(_ref) {
|
|
318
318
|
var renderDateCell = function renderDateCell() {
|
319
319
|
var _config$inputProps, _outerButtonElement$c;
|
320
320
|
var datePickerPreparedProps = prepareProps(config.inputProps, ['datePickerInputProps']);
|
321
|
-
var datePickerInputProps = config === null || config === void 0
|
321
|
+
var datePickerInputProps = config === null || config === void 0 || (_config$inputProps = config.inputProps) === null || _config$inputProps === void 0 ? void 0 : _config$inputProps.datePickerInputProps;
|
322
322
|
return /*#__PURE__*/React.createElement(DatePicker, _extends({}, datePickerPreparedProps, {
|
323
|
-
appendTo: outerButtonElement === null || outerButtonElement === void 0
|
323
|
+
appendTo: outerButtonElement === null || outerButtonElement === void 0 || (_outerButtonElement$c = outerButtonElement.current) === null || _outerButtonElement$c === void 0 ? void 0 : _outerButtonElement$c.parentElement,
|
324
324
|
ref: datePickerRef,
|
325
325
|
style: {
|
326
326
|
width: cell.column.totalWidth
|
@@ -330,7 +330,7 @@ export var InlineEditCell = function InlineEditCell(_ref) {
|
|
330
330
|
onChange: function onChange(newDate) {
|
331
331
|
var _datePickerPreparedPr;
|
332
332
|
var newDateObj = newDate[0];
|
333
|
-
datePickerPreparedProps === null || datePickerPreparedProps === void 0
|
333
|
+
datePickerPreparedProps === null || datePickerPreparedProps === void 0 || (_datePickerPreparedPr = datePickerPreparedProps.onChange) === null || _datePickerPreparedPr === void 0 || _datePickerPreparedPr.call(datePickerPreparedProps, newDateObj, cell);
|
334
334
|
var newCellId = getNewCellId('Enter');
|
335
335
|
saveCellData(newDateObj);
|
336
336
|
setCellValue(newDateObj);
|
@@ -359,7 +359,7 @@ export var InlineEditCell = function InlineEditCell(_ref) {
|
|
359
359
|
};
|
360
360
|
var buildDate = function buildDate(value) {
|
361
361
|
var _config$inputProps2;
|
362
|
-
var dateFormat = config === null || config === void 0
|
362
|
+
var dateFormat = config === null || config === void 0 || (_config$inputProps2 = config.inputProps) === null || _config$inputProps2 === void 0 ? void 0 : _config$inputProps2.dateFormat;
|
363
363
|
if (value instanceof Date) {
|
364
364
|
var maskedFullYear = value.getFullYear();
|
365
365
|
var maskedMonth = padTo2Digits(value.getMonth() + 1);
|
@@ -430,7 +430,7 @@ export var InlineEditCell = function InlineEditCell(_ref) {
|
|
430
430
|
"data-inline-type": type,
|
431
431
|
onClick: !nonEditCell ? handleInlineCellClick : addActiveState,
|
432
432
|
onKeyDown: !nonEditCell ? handleKeyDown : null,
|
433
|
-
className: cx("".concat(blockClass, "__inline-edit--outer-cell-button"), (
|
433
|
+
className: cx("".concat(blockClass, "__inline-edit--outer-cell-button"), _defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__inline-edit--outer-cell-button--").concat(rowSize), rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--lg"), !rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--invalid"), config === null || config === void 0 || (_config$validator = config.validator) === null || _config$validator === void 0 ? void 0 : _config$validator.call(config, cellValue)))
|
434
434
|
}, !inEditMode && /*#__PURE__*/React.createElement(InlineEditButton, {
|
435
435
|
isActiveCell: cellId === activeCellId,
|
436
436
|
renderIcon: setRenderIcon(),
|
package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
|
-
function ownKeys(
|
4
|
-
function _objectSpread(
|
3
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
4
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
5
5
|
/**
|
6
6
|
* Copyright IBM Corp. 2022, 2022
|
7
7
|
*
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
2
|
-
function ownKeys(
|
3
|
-
function _objectSpread(
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2022, 2022
|
6
6
|
*
|
@@ -26,7 +26,7 @@ export var returnUpdatedActiveCell = function returnUpdatedActiveCell(_ref) {
|
|
26
26
|
var newCellIdButton = document.querySelector("#".concat(instance.tableId, " .").concat(blockClass, "__table-with-inline-edit [data-cell-id=\"").concat(newActiveCellId, "\"] .").concat(blockClass, "__inline-edit-button"));
|
27
27
|
// Allows scrollable area to keep focused/active cell id visible
|
28
28
|
if (newCellIdButton) {
|
29
|
-
newCellIdButton === null || newCellIdButton === void 0
|
29
|
+
newCellIdButton === null || newCellIdButton === void 0 || newCellIdButton.focus();
|
30
30
|
}
|
31
31
|
return _objectSpread(_objectSpread({}, state), {}, {
|
32
32
|
activeCellId: newActiveCellId
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
2
|
-
function ownKeys(
|
3
|
-
function _objectSpread(
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2022, 2022
|
6
6
|
*
|
@@ -204,14 +204,14 @@ export var handleGridKeyPress = function handleGridKeyPress(_ref) {
|
|
204
204
|
if (focusedType === 'selection') {
|
205
205
|
setTimeout(function () {
|
206
206
|
var dropdownTrigger = focusedCell.querySelector('button');
|
207
|
-
dropdownTrigger === null || dropdownTrigger === void 0
|
207
|
+
dropdownTrigger === null || dropdownTrigger === void 0 || dropdownTrigger.click();
|
208
208
|
}, 1);
|
209
209
|
}
|
210
210
|
if (focusedType === 'date') {
|
211
211
|
setTimeout(function () {
|
212
212
|
var dateInputTrigger = focusedCell.querySelector('input');
|
213
|
-
dateInputTrigger === null || dateInputTrigger === void 0
|
214
|
-
dateInputTrigger === null || dateInputTrigger === void 0
|
213
|
+
dateInputTrigger === null || dateInputTrigger === void 0 || dateInputTrigger.click();
|
214
|
+
dateInputTrigger === null || dateInputTrigger === void 0 || dateInputTrigger.focus();
|
215
215
|
}, 1);
|
216
216
|
}
|
217
217
|
dispatch({
|
@@ -74,7 +74,7 @@ export var handleMultipleKeys = function handleMultipleKeys(_ref) {
|
|
74
74
|
});
|
75
75
|
if (indexOfTable && Number.isFinite(indexOfTable)) {
|
76
76
|
var _datagridFocusableEle;
|
77
|
-
(_datagridFocusableEle = datagridFocusableElements[indexOfTable]) === null || _datagridFocusableEle === void 0
|
77
|
+
(_datagridFocusableEle = datagridFocusableElements[indexOfTable]) === null || _datagridFocusableEle === void 0 || _datagridFocusableEle.focus();
|
78
78
|
}
|
79
79
|
}
|
80
80
|
};
|
@@ -32,7 +32,7 @@ var RowSizeDropdown = function RowSizeDropdown(_ref) {
|
|
32
32
|
if (isOpen) {
|
33
33
|
var radioGroupParentElement = radioGroupRef === null || radioGroupRef === void 0 ? void 0 : radioGroupRef.current;
|
34
34
|
var checkedRadioChild = radioGroupParentElement === null || radioGroupParentElement === void 0 ? void 0 : radioGroupParentElement.querySelector(".".concat(carbon.prefix, "--radio-button:checked"));
|
35
|
-
checkedRadioChild === null || checkedRadioChild === void 0
|
35
|
+
checkedRadioChild === null || checkedRadioChild === void 0 || checkedRadioChild.focus();
|
36
36
|
}
|
37
37
|
}, [isOpen]);
|
38
38
|
var onCloseHandler = function onCloseHandler() {
|
@@ -62,7 +62,6 @@ var getBackwardCompatibleRowSize = function getBackwardCompatibleRowSize(rowSize
|
|
62
62
|
compact: 'xs'
|
63
63
|
// md is a new value
|
64
64
|
};
|
65
|
-
|
66
65
|
return rowSizeMap[rowSize] || rowSize;
|
67
66
|
};
|
68
67
|
RowSizeRadioGroup.defaultProps = {
|
@@ -77,7 +76,6 @@ RowSizeRadioGroup.defaultProps = {
|
|
77
76
|
}, {
|
78
77
|
value: 'xs' // 24
|
79
78
|
}],
|
80
|
-
|
81
79
|
selectedOption: 'lg'
|
82
80
|
};
|
83
81
|
RowSizeRadioGroup.propTypes = {
|