@mui/x-data-grid 8.0.0-alpha.0 → 8.0.0-alpha.10
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/CHANGELOG.md +2215 -119
- package/DataGrid/DataGrid.js +20 -38
- package/DataGrid/useDataGridComponent.d.ts +2 -1
- package/DataGrid/useDataGridComponent.js +1 -1
- package/DataGrid/useDataGridProps.js +3 -3
- package/README.md +3 -3
- package/colDef/gridDateOperators.d.ts +2 -1
- package/colDef/gridNumericOperators.d.ts +4 -1
- package/components/GridApiContext.js +2 -0
- package/components/GridColumnHeaders.d.ts +1 -1
- package/components/GridColumnHeaders.js +4 -4
- package/components/GridConfigurationContext.js +2 -0
- package/components/GridFooter.d.ts +2 -1
- package/components/GridFooter.js +4 -4
- package/components/GridHeaders.js +2 -2
- package/components/GridLoadingOverlay.d.ts +3 -3
- package/components/GridLoadingOverlay.js +14 -12
- package/components/GridNoResultsOverlay.d.ts +2 -1
- package/components/GridNoResultsOverlay.js +4 -4
- package/components/GridNoRowsOverlay.d.ts +2 -1
- package/components/GridNoRowsOverlay.js +4 -4
- package/components/GridPagination.d.ts +1 -1
- package/components/GridPagination.js +7 -4
- package/components/GridRow.d.ts +6 -11
- package/components/GridRow.js +55 -87
- package/components/GridRowCount.d.ts +1 -1
- package/components/GridRowCount.js +3 -2
- package/components/GridScrollArea.js +2 -0
- package/components/GridSelectedRowCount.d.ts +4 -1
- package/components/GridSelectedRowCount.js +3 -2
- package/components/GridSkeletonLoadingOverlay.d.ts +1 -1
- package/components/GridSkeletonLoadingOverlay.js +22 -21
- package/components/base/GridOverlays.d.ts +4 -3
- package/components/base/GridOverlays.js +2 -24
- package/components/base/index.d.ts +0 -1
- package/components/base/index.js +1 -2
- package/components/cell/GridActionsCell.js +8 -1
- package/components/cell/GridActionsCellItem.d.ts +17 -10
- package/components/cell/GridActionsCellItem.js +9 -8
- package/components/cell/GridCell.d.ts +19 -23
- package/components/cell/GridCell.js +52 -92
- package/components/cell/GridEditDateCell.js +1 -1
- package/components/cell/GridEditInputCell.d.ts +1 -1
- package/components/cell/GridEditInputCell.js +73 -4
- package/components/cell/GridEditSingleSelectCell.js +2 -2
- package/components/cell/GridSkeletonCell.js +1 -2
- package/components/columnHeaders/ColumnHeaderMenuIcon.d.ts +1 -1
- package/components/columnHeaders/GridBaseColumnHeaders.d.ts +1 -1
- package/components/columnHeaders/GridBaseColumnHeaders.js +4 -3
- package/components/columnHeaders/GridColumnGroupHeader.d.ts +5 -5
- package/components/columnHeaders/GridColumnGroupHeader.js +7 -10
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.d.ts +3 -3
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.js +20 -7
- package/components/columnHeaders/GridColumnHeaderItem.d.ts +5 -5
- package/components/columnHeaders/GridColumnHeaderItem.js +13 -12
- package/components/columnHeaders/GridColumnHeaderTitle.js +5 -3
- package/components/columnHeaders/GridGenericColumnHeaderItem.d.ts +1 -1
- package/components/columnHeaders/GridGenericColumnHeaderItem.js +3 -2
- package/components/columnHeaders/GridIconButtonContainer.d.ts +1 -1
- package/components/columnHeaders/GridIconButtonContainer.js +5 -3
- package/components/columnSelection/GridCellCheckboxRenderer.d.ts +2 -2
- package/components/columnSelection/GridCellCheckboxRenderer.js +11 -9
- package/components/columnSelection/GridHeaderCheckbox.d.ts +1 -1
- package/components/columnSelection/GridHeaderCheckbox.js +17 -9
- package/components/columnsManagement/GridColumnsManagement.d.ts +2 -0
- package/components/columnsManagement/GridColumnsManagement.js +81 -11
- package/components/containers/GridFooterContainer.d.ts +1 -1
- package/components/containers/GridFooterContainer.js +5 -3
- package/components/containers/GridOverlay.d.ts +1 -1
- package/components/containers/GridOverlay.js +5 -3
- package/components/containers/GridRoot.d.ts +2 -2
- package/components/containers/GridRoot.js +18 -8
- package/components/containers/GridRootStyles.js +160 -50
- package/components/containers/GridToolbarContainer.d.ts +1 -1
- package/components/containers/GridToolbarContainer.js +3 -2
- package/components/menu/columnMenu/GridColumnMenu.d.ts +2 -2
- package/components/menu/columnMenu/GridColumnMenu.js +5 -5
- package/components/menu/columnMenu/GridColumnMenuContainer.d.ts +1 -1
- package/components/menu/columnMenu/GridColumnMenuContainer.js +3 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuFilterItem.js +6 -11
- package/components/menu/columnMenu/menuItems/GridColumnMenuHideItem.js +6 -11
- package/components/menu/columnMenu/menuItems/GridColumnMenuManageItem.js +6 -11
- package/components/menu/columnMenu/menuItems/GridColumnMenuSortItem.js +13 -22
- package/components/panel/GridColumnsPanel.js +1 -2
- package/components/panel/GridPanel.d.ts +2 -2
- package/components/panel/GridPanel.js +5 -3
- package/components/panel/GridPanelContent.js +7 -3
- package/components/panel/GridPanelFooter.d.ts +1 -1
- package/components/panel/GridPanelFooter.js +4 -3
- package/components/panel/GridPanelWrapper.d.ts +1 -1
- package/components/panel/GridPanelWrapper.js +5 -3
- package/components/panel/filterPanel/GridFilterForm.d.ts +1 -1
- package/components/panel/filterPanel/GridFilterForm.js +22 -18
- package/components/panel/filterPanel/GridFilterInputBoolean.d.ts +4 -11
- package/components/panel/filterPanel/GridFilterInputBoolean.js +41 -31
- package/components/panel/filterPanel/GridFilterInputDate.d.ts +3 -9
- package/components/panel/filterPanel/GridFilterInputDate.js +50 -31
- package/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.d.ts +3 -3
- package/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +49 -24
- package/components/panel/filterPanel/GridFilterInputMultipleValue.d.ts +3 -3
- package/components/panel/filterPanel/GridFilterInputMultipleValue.js +55 -33
- package/components/panel/filterPanel/GridFilterInputSingleSelect.d.ts +3 -9
- package/components/panel/filterPanel/GridFilterInputSingleSelect.js +34 -25
- package/components/panel/filterPanel/GridFilterInputValue.d.ts +3 -9
- package/components/panel/filterPanel/GridFilterInputValue.js +63 -38
- package/components/panel/filterPanel/GridFilterPanel.d.ts +1 -1
- package/components/panel/filterPanel/GridFilterPanel.js +4 -4
- package/components/panel/filterPanel/index.d.ts +2 -2
- package/components/panel/filterPanel/index.js +1 -2
- package/components/toolbar/GridToolbar.d.ts +1 -1
- package/components/toolbar/GridToolbar.js +11 -5
- package/components/toolbar/GridToolbarColumnsButton.d.ts +1 -1
- package/components/toolbar/GridToolbarColumnsButton.js +12 -6
- package/components/toolbar/GridToolbarDensitySelector.d.ts +1 -1
- package/components/toolbar/GridToolbarDensitySelector.js +9 -11
- package/components/toolbar/GridToolbarExport.d.ts +1 -1
- package/components/toolbar/GridToolbarExport.js +2 -1
- package/components/toolbar/GridToolbarExportContainer.d.ts +1 -1
- package/components/toolbar/GridToolbarExportContainer.js +6 -6
- package/components/toolbar/GridToolbarFilterButton.d.ts +3 -1
- package/components/toolbar/GridToolbarFilterButton.js +20 -9
- package/components/toolbar/GridToolbarQuickFilter.d.ts +6 -2
- package/components/toolbar/GridToolbarQuickFilter.js +39 -31
- package/components/virtualization/GridMainContainer.d.ts +13 -1
- package/components/virtualization/GridMainContainer.js +14 -5
- package/components/virtualization/GridVirtualScrollbar.d.ts +5 -1
- package/components/virtualization/GridVirtualScrollbar.js +17 -17
- package/components/virtualization/GridVirtualScroller.js +27 -12
- package/components/virtualization/GridVirtualScrollerContent.d.ts +2 -0
- package/components/virtualization/GridVirtualScrollerContent.js +15 -6
- package/components/virtualization/GridVirtualScrollerRenderZone.d.ts +2 -0
- package/components/virtualization/GridVirtualScrollerRenderZone.js +5 -3
- package/constants/dataGridPropsDefaultValues.js +2 -4
- package/constants/gridClasses.d.ts +36 -12
- package/constants/gridClasses.js +1 -1
- package/constants/localeTextConstants.js +12 -0
- package/context/GridContextProvider.d.ts +2 -1
- package/context/GridRootPropsContext.js +2 -0
- package/hooks/core/pipeProcessing/gridPipeProcessingApi.d.ts +9 -2
- package/hooks/core/pipeProcessing/useGridPipeProcessing.d.ts +2 -2
- package/hooks/core/pipeProcessing/useGridRegisterPipeApplier.d.ts +2 -2
- package/hooks/core/pipeProcessing/useGridRegisterPipeApplier.js +1 -1
- package/hooks/core/pipeProcessing/useGridRegisterPipeProcessor.d.ts +2 -2
- package/hooks/core/pipeProcessing/useGridRegisterPipeProcessor.js +1 -1
- package/hooks/core/strategyProcessing/gridStrategyProcessingApi.d.ts +25 -9
- package/hooks/core/strategyProcessing/gridStrategyProcessingApi.js +5 -1
- package/hooks/core/strategyProcessing/useGridRegisterStrategyProcessor.d.ts +2 -2
- package/hooks/core/strategyProcessing/useGridStrategyProcessing.d.ts +5 -8
- package/hooks/core/strategyProcessing/useGridStrategyProcessing.js +7 -8
- package/hooks/core/useGridApiInitialization.d.ts +2 -2
- package/hooks/core/useGridApiInitialization.js +2 -2
- package/hooks/core/useGridInitialization.d.ts +2 -2
- package/hooks/core/useGridIsRtl.d.ts +2 -2
- package/hooks/core/useGridLocaleText.d.ts +2 -2
- package/hooks/core/useGridLoggerFactory.d.ts +2 -2
- package/hooks/core/useGridRefs.d.ts +2 -2
- package/hooks/core/useGridStateInitialization.d.ts +2 -2
- package/hooks/core/useGridStateInitialization.js +3 -3
- package/hooks/features/clipboard/useGridClipboard.d.ts +2 -2
- package/hooks/features/columnGrouping/gridColumnGroupsSelector.d.ts +4 -4
- package/hooks/features/columnGrouping/useGridColumnGrouping.d.ts +2 -2
- package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +5 -7
- package/hooks/features/columnHeaders/useGridColumnHeaders.js +34 -69
- package/hooks/features/columnMenu/useGridColumnMenu.d.ts +2 -2
- package/hooks/features/columnMenu/useGridColumnMenu.js +0 -2
- package/hooks/features/columnResize/columnResizeSelector.d.ts +1 -1
- package/hooks/features/columnResize/gridColumnResizeApi.d.ts +6 -0
- package/hooks/features/columnResize/gridColumnResizeApi.js +2 -1
- package/hooks/features/columnResize/useGridColumnResize.d.ts +2 -2
- package/hooks/features/columnResize/useGridColumnResize.js +17 -10
- package/hooks/features/columns/gridColumnsSelector.d.ts +12 -12
- package/hooks/features/columns/gridColumnsUtils.d.ts +4 -4
- package/hooks/features/columns/gridColumnsUtils.js +2 -1
- package/hooks/features/columns/useGridColumnSpanning.d.ts +2 -2
- package/hooks/features/columns/useGridColumns.d.ts +2 -2
- package/hooks/features/columns/useGridColumns.js +7 -3
- package/hooks/features/density/densitySelector.d.ts +1 -1
- package/hooks/features/density/useGridDensity.d.ts +2 -2
- package/hooks/features/dimensions/gridDimensionsApi.d.ts +0 -4
- package/hooks/features/dimensions/useGridDimensions.d.ts +2 -2
- package/hooks/features/dimensions/useGridDimensions.js +11 -32
- package/hooks/features/editing/gridEditingSelectors.d.ts +6 -0
- package/hooks/features/editing/gridEditingSelectors.js +7 -1
- package/hooks/features/editing/useGridCellEditing.d.ts +2 -2
- package/hooks/features/editing/useGridCellEditing.js +4 -4
- package/hooks/features/editing/useGridEditing.d.ts +2 -2
- package/hooks/features/editing/useGridRowEditing.d.ts +2 -2
- package/hooks/features/editing/useGridRowEditing.js +7 -8
- package/hooks/features/events/useGridEvents.d.ts +2 -2
- package/hooks/features/export/serializers/csvSerializer.d.ts +2 -1
- package/hooks/features/export/useGridCsvExport.d.ts +2 -2
- package/hooks/features/export/useGridPrintExport.d.ts +2 -2
- package/hooks/features/export/useGridPrintExport.js +1 -1
- package/hooks/features/export/utils.d.ts +2 -2
- package/hooks/features/filter/gridFilterSelector.d.ts +17 -17
- package/hooks/features/filter/gridFilterSelector.js +6 -1
- package/hooks/features/filter/gridFilterUtils.d.ts +7 -7
- package/hooks/features/filter/gridFilterUtils.js +3 -3
- package/hooks/features/filter/useGridFilter.d.ts +2 -2
- package/hooks/features/filter/useGridFilter.js +1 -1
- package/hooks/features/focus/gridFocusStateSelector.d.ts +8 -8
- package/hooks/features/focus/useGridFocus.d.ts +2 -2
- package/hooks/features/focus/useGridFocus.js +3 -2
- package/hooks/features/headerFiltering/gridHeaderFilteringSelectors.d.ts +3 -3
- package/hooks/features/headerFiltering/useGridHeaderFiltering.d.ts +2 -2
- package/hooks/features/index.d.ts +1 -0
- package/hooks/features/index.js +1 -0
- package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.d.ts +2 -2
- package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +24 -16
- package/hooks/features/keyboardNavigation/utils.d.ts +3 -4
- package/hooks/features/keyboardNavigation/utils.js +0 -5
- package/hooks/features/listView/gridListViewSelectors.d.ts +3 -1
- package/hooks/features/listView/gridListViewSelectors.js +3 -1
- package/hooks/features/listView/index.d.ts +1 -0
- package/hooks/features/listView/index.js +1 -0
- package/hooks/features/listView/useGridListView.d.ts +2 -2
- package/hooks/features/listView/useGridListView.js +2 -1
- package/hooks/features/overlays/useGridOverlays.d.ts +7 -4
- package/hooks/features/overlays/useGridOverlays.js +22 -2
- package/hooks/features/pagination/gridPaginationInterfaces.d.ts +3 -0
- package/hooks/features/pagination/gridPaginationSelector.d.ts +34 -9
- package/hooks/features/pagination/gridPaginationSelector.js +39 -1
- package/hooks/features/pagination/useGridPagination.d.ts +3 -3
- package/hooks/features/pagination/useGridPagination.js +5 -3
- package/hooks/features/pagination/useGridPaginationMeta.d.ts +2 -2
- package/hooks/features/pagination/useGridPaginationModel.d.ts +2 -2
- package/hooks/features/pagination/useGridPaginationModel.js +23 -1
- package/hooks/features/pagination/useGridRowCount.d.ts +2 -2
- package/hooks/features/preferencesPanel/gridPreferencePanelSelector.d.ts +1 -0
- package/hooks/features/preferencesPanel/gridPreferencePanelSelector.js +8 -1
- package/hooks/features/preferencesPanel/index.d.ts +1 -1
- package/hooks/features/preferencesPanel/index.js +1 -1
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.d.ts +2 -2
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.js +14 -38
- package/hooks/features/rowSelection/gridRowSelectionSelector.d.ts +3 -3
- package/hooks/features/rowSelection/useGridRowSelection.d.ts +2 -2
- package/hooks/features/rowSelection/useGridRowSelection.js +8 -16
- package/hooks/features/rowSelection/useGridRowSelectionPreProcessors.d.ts +2 -2
- package/hooks/features/rowSelection/utils.d.ts +4 -3
- package/hooks/features/rowSelection/utils.js +2 -2
- package/hooks/features/rows/gridRowSpanningSelectors.d.ts +3 -3
- package/hooks/features/rows/gridRowSpanningUtils.d.ts +2 -2
- package/hooks/features/rows/gridRowsInterfaces.d.ts +1 -8
- package/hooks/features/rows/gridRowsSelector.d.ts +23 -13
- package/hooks/features/rows/gridRowsSelector.js +1 -2
- package/hooks/features/rows/gridRowsUtils.d.ts +4 -4
- package/hooks/features/rows/gridRowsUtils.js +0 -9
- package/hooks/features/rows/index.d.ts +1 -1
- package/hooks/features/rows/index.js +1 -1
- package/hooks/features/rows/useGridParamsApi.d.ts +2 -2
- package/hooks/features/rows/useGridParamsApi.js +33 -14
- package/hooks/features/rows/useGridRowSpanning.d.ts +2 -2
- package/hooks/features/rows/useGridRowSpanning.js +97 -86
- package/hooks/features/rows/useGridRows.d.ts +2 -2
- package/hooks/features/rows/useGridRows.js +23 -27
- package/hooks/features/rows/useGridRowsMeta.d.ts +2 -2
- package/hooks/features/rows/useGridRowsMeta.js +3 -2
- package/hooks/features/rows/useGridRowsPreProcessors.d.ts +2 -2
- package/hooks/features/scroll/useGridScroll.d.ts +2 -2
- package/hooks/features/sorting/gridSortingSelector.d.ts +10 -5
- package/hooks/features/sorting/gridSortingSelector.js +11 -0
- package/hooks/features/sorting/gridSortingUtils.d.ts +3 -3
- package/hooks/features/sorting/gridSortingUtils.js +2 -2
- package/hooks/features/sorting/index.d.ts +2 -1
- package/hooks/features/sorting/index.js +1 -1
- package/hooks/features/sorting/useGridSorting.d.ts +2 -2
- package/hooks/features/sorting/useGridSorting.js +1 -1
- package/hooks/features/statePersistence/useGridStatePersistence.d.ts +2 -2
- package/hooks/features/virtualization/gridFocusedVirtualCellSelector.d.ts +6 -0
- package/hooks/features/virtualization/gridFocusedVirtualCellSelector.js +33 -0
- package/hooks/features/virtualization/gridVirtualizationSelectors.d.ts +5 -5
- package/hooks/features/virtualization/useGridVirtualScroller.d.ts +15 -6
- package/hooks/features/virtualization/useGridVirtualScroller.js +169 -94
- package/hooks/features/virtualization/useGridVirtualization.d.ts +2 -2
- package/hooks/utils/useGridApiContext.d.ts +2 -2
- package/hooks/utils/useGridApiEventHandler.d.ts +4 -4
- package/hooks/utils/useGridApiEventHandler.js +1 -1
- package/hooks/utils/useGridApiMethod.d.ts +2 -2
- package/hooks/utils/useGridApiRef.d.ts +2 -2
- package/hooks/utils/useGridApiRef.js +1 -1
- package/hooks/utils/useGridInitializeState.d.ts +3 -3
- package/hooks/utils/useGridLogger.d.ts +2 -2
- package/hooks/utils/useGridNativeEventListener.d.ts +2 -1
- package/hooks/utils/useGridPrivateApiContext.d.ts +2 -1
- package/hooks/utils/useGridSelector.d.ts +5 -7
- package/hooks/utils/useGridSelector.js +6 -44
- package/hooks/utils/useGridVisibleRows.d.ts +8 -6
- package/hooks/utils/useGridVisibleRows.js +5 -28
- package/index.js +1 -1
- package/internals/constants.d.ts +6 -0
- package/internals/constants.js +8 -1
- package/internals/index.d.ts +7 -4
- package/internals/index.js +5 -3
- package/internals/utils/attachPinnedStyle.d.ts +2 -0
- package/internals/utils/attachPinnedStyle.js +9 -0
- package/internals/utils/getPinnedCellOffset.d.ts +3 -3
- package/internals/utils/getPinnedCellOffset.js +6 -7
- package/internals/utils/index.d.ts +1 -1
- package/internals/utils/index.js +2 -2
- package/locales/arSD.js +14 -0
- package/locales/beBY.js +13 -0
- package/locales/bgBG.js +15 -0
- package/locales/csCZ.js +15 -0
- package/locales/daDK.js +15 -0
- package/locales/deDE.js +13 -0
- package/locales/elGR.js +14 -0
- package/locales/esES.js +17 -4
- package/locales/faIR.js +18 -4
- package/locales/fiFI.js +15 -0
- package/locales/frFR.js +15 -0
- package/locales/heIL.js +17 -4
- package/locales/hrHR.js +15 -0
- package/locales/huHU.js +15 -0
- package/locales/isIS.js +14 -0
- package/locales/itIT.js +15 -0
- package/locales/jaJP.js +15 -0
- package/locales/koKR.js +47 -37
- package/locales/nbNO.js +15 -0
- package/locales/nlNL.js +18 -4
- package/locales/nnNO.js +15 -0
- package/locales/plPL.js +15 -0
- package/locales/ptBR.js +13 -0
- package/locales/ptPT.js +13 -0
- package/locales/roRO.js +21 -9
- package/locales/ruRU.js +15 -0
- package/locales/skSK.js +14 -0
- package/locales/svSE.js +19 -5
- package/locales/trTR.js +15 -2
- package/locales/ukUA.js +14 -0
- package/locales/urPK.js +22 -9
- package/locales/viVN.js +15 -0
- package/locales/zhCN.js +17 -4
- package/locales/zhHK.js +14 -0
- package/locales/zhTW.js +14 -0
- package/material/index.js +58 -7
- package/models/api/gridApiCommon.d.ts +2 -2
- package/models/api/gridCoreApi.d.ts +7 -7
- package/models/api/gridDensityApi.d.ts +1 -1
- package/models/api/gridLocaleTextApi.d.ts +11 -0
- package/models/api/gridParamsApi.d.ts +29 -2
- package/models/api/gridStateApi.d.ts +1 -1
- package/models/api/index.d.ts +1 -1
- package/models/api/index.js +0 -1
- package/models/colDef/gridColDef.d.ts +38 -33
- package/models/controlStateItem.d.ts +2 -2
- package/models/events/gridEventLookup.d.ts +7 -1
- package/models/gridBaseSlots.d.ts +95 -0
- package/models/gridDataSource.d.ts +13 -13
- package/models/gridExport.d.ts +2 -2
- package/models/gridFilterInputComponent.d.ts +32 -0
- package/models/gridFilterOperator.d.ts +6 -4
- package/models/gridIconSlotsComponent.d.ts +5 -0
- package/models/gridSlotsComponent.d.ts +16 -1
- package/models/gridSlotsComponentsProps.d.ts +45 -9
- package/models/gridStateCommunity.d.ts +4 -0
- package/models/index.d.ts +1 -0
- package/models/props/DataGridProps.d.ts +12 -24
- package/modern/DataGrid/DataGrid.js +20 -38
- package/modern/DataGrid/useDataGridComponent.js +1 -1
- package/modern/DataGrid/useDataGridProps.js +3 -3
- package/modern/components/GridApiContext.js +2 -0
- package/modern/components/GridColumnHeaders.js +4 -4
- package/modern/components/GridConfigurationContext.js +2 -0
- package/modern/components/GridFooter.js +4 -4
- package/modern/components/GridHeaders.js +2 -2
- package/modern/components/GridLoadingOverlay.js +14 -12
- package/modern/components/GridNoResultsOverlay.js +4 -4
- package/modern/components/GridNoRowsOverlay.js +4 -4
- package/modern/components/GridPagination.js +7 -4
- package/modern/components/GridRow.js +55 -87
- package/modern/components/GridRowCount.js +3 -2
- package/modern/components/GridScrollArea.js +2 -0
- package/modern/components/GridSelectedRowCount.js +3 -2
- package/modern/components/GridSkeletonLoadingOverlay.js +22 -21
- package/modern/components/base/GridOverlays.js +2 -24
- package/modern/components/base/index.js +1 -2
- package/modern/components/cell/GridActionsCell.js +8 -1
- package/modern/components/cell/GridActionsCellItem.js +9 -8
- package/modern/components/cell/GridCell.js +52 -92
- package/modern/components/cell/GridEditDateCell.js +1 -1
- package/modern/components/cell/GridEditInputCell.js +73 -4
- package/modern/components/cell/GridEditSingleSelectCell.js +2 -2
- package/modern/components/cell/GridSkeletonCell.js +1 -2
- package/modern/components/columnHeaders/GridBaseColumnHeaders.js +4 -3
- package/modern/components/columnHeaders/GridColumnGroupHeader.js +7 -10
- package/modern/components/columnHeaders/GridColumnHeaderFilterIconButton.js +20 -7
- package/modern/components/columnHeaders/GridColumnHeaderItem.js +13 -12
- package/modern/components/columnHeaders/GridColumnHeaderTitle.js +5 -3
- package/modern/components/columnHeaders/GridGenericColumnHeaderItem.js +3 -2
- package/modern/components/columnHeaders/GridIconButtonContainer.js +5 -3
- package/modern/components/columnSelection/GridCellCheckboxRenderer.js +11 -9
- package/modern/components/columnSelection/GridHeaderCheckbox.js +17 -9
- package/modern/components/columnsManagement/GridColumnsManagement.js +81 -11
- package/modern/components/containers/GridFooterContainer.js +5 -3
- package/modern/components/containers/GridOverlay.js +5 -3
- package/modern/components/containers/GridRoot.js +18 -8
- package/modern/components/containers/GridRootStyles.js +160 -50
- package/modern/components/containers/GridToolbarContainer.js +3 -2
- package/modern/components/menu/columnMenu/GridColumnMenu.js +5 -5
- package/modern/components/menu/columnMenu/GridColumnMenuContainer.js +3 -2
- package/modern/components/menu/columnMenu/menuItems/GridColumnMenuFilterItem.js +6 -11
- package/modern/components/menu/columnMenu/menuItems/GridColumnMenuHideItem.js +6 -11
- package/modern/components/menu/columnMenu/menuItems/GridColumnMenuManageItem.js +6 -11
- package/modern/components/menu/columnMenu/menuItems/GridColumnMenuSortItem.js +13 -22
- package/modern/components/panel/GridColumnsPanel.js +1 -2
- package/modern/components/panel/GridPanel.js +5 -3
- package/modern/components/panel/GridPanelContent.js +7 -3
- package/modern/components/panel/GridPanelFooter.js +4 -3
- package/modern/components/panel/GridPanelWrapper.js +5 -3
- package/modern/components/panel/filterPanel/GridFilterForm.js +22 -18
- package/modern/components/panel/filterPanel/GridFilterInputBoolean.js +41 -31
- package/modern/components/panel/filterPanel/GridFilterInputDate.js +50 -31
- package/modern/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +49 -24
- package/modern/components/panel/filterPanel/GridFilterInputMultipleValue.js +55 -33
- package/modern/components/panel/filterPanel/GridFilterInputSingleSelect.js +34 -25
- package/modern/components/panel/filterPanel/GridFilterInputValue.js +63 -38
- package/modern/components/panel/filterPanel/GridFilterPanel.js +4 -4
- package/modern/components/panel/filterPanel/index.js +1 -2
- package/modern/components/toolbar/GridToolbar.js +11 -5
- package/modern/components/toolbar/GridToolbarColumnsButton.js +12 -6
- package/modern/components/toolbar/GridToolbarDensitySelector.js +9 -11
- package/modern/components/toolbar/GridToolbarExport.js +2 -1
- package/modern/components/toolbar/GridToolbarExportContainer.js +6 -6
- package/modern/components/toolbar/GridToolbarFilterButton.js +20 -9
- package/modern/components/toolbar/GridToolbarQuickFilter.js +39 -31
- package/modern/components/virtualization/GridMainContainer.js +14 -5
- package/modern/components/virtualization/GridVirtualScrollbar.js +17 -17
- package/modern/components/virtualization/GridVirtualScroller.js +27 -12
- package/modern/components/virtualization/GridVirtualScrollerContent.js +15 -6
- package/modern/components/virtualization/GridVirtualScrollerRenderZone.js +5 -3
- package/modern/constants/dataGridPropsDefaultValues.js +2 -4
- package/modern/constants/gridClasses.js +1 -1
- package/modern/constants/localeTextConstants.js +12 -0
- package/modern/context/GridRootPropsContext.js +2 -0
- package/modern/hooks/core/pipeProcessing/useGridRegisterPipeApplier.js +1 -1
- package/modern/hooks/core/pipeProcessing/useGridRegisterPipeProcessor.js +1 -1
- package/modern/hooks/core/strategyProcessing/gridStrategyProcessingApi.js +5 -1
- package/modern/hooks/core/strategyProcessing/useGridStrategyProcessing.js +7 -8
- package/modern/hooks/core/useGridApiInitialization.js +2 -2
- package/modern/hooks/core/useGridStateInitialization.js +3 -3
- package/modern/hooks/features/columnHeaders/useGridColumnHeaders.js +34 -69
- package/modern/hooks/features/columnMenu/useGridColumnMenu.js +0 -2
- package/modern/hooks/features/columnResize/gridColumnResizeApi.js +2 -1
- package/modern/hooks/features/columnResize/useGridColumnResize.js +17 -10
- package/modern/hooks/features/columns/gridColumnsUtils.js +2 -1
- package/modern/hooks/features/columns/useGridColumns.js +7 -3
- package/modern/hooks/features/dimensions/useGridDimensions.js +11 -32
- package/modern/hooks/features/editing/gridEditingSelectors.js +7 -1
- package/modern/hooks/features/editing/useGridCellEditing.js +4 -4
- package/modern/hooks/features/editing/useGridRowEditing.js +7 -8
- package/modern/hooks/features/export/useGridPrintExport.js +1 -1
- package/modern/hooks/features/filter/gridFilterSelector.js +6 -1
- package/modern/hooks/features/filter/gridFilterUtils.js +3 -3
- package/modern/hooks/features/filter/useGridFilter.js +1 -1
- package/modern/hooks/features/focus/useGridFocus.js +3 -2
- package/modern/hooks/features/index.js +1 -0
- package/modern/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +24 -16
- package/modern/hooks/features/keyboardNavigation/utils.js +0 -5
- package/modern/hooks/features/listView/gridListViewSelectors.js +3 -1
- package/modern/hooks/features/listView/index.js +1 -0
- package/modern/hooks/features/listView/useGridListView.js +2 -1
- package/modern/hooks/features/overlays/useGridOverlays.js +22 -2
- package/modern/hooks/features/pagination/gridPaginationSelector.js +39 -1
- package/modern/hooks/features/pagination/useGridPagination.js +5 -3
- package/modern/hooks/features/pagination/useGridPaginationModel.js +23 -1
- package/modern/hooks/features/preferencesPanel/gridPreferencePanelSelector.js +8 -1
- package/modern/hooks/features/preferencesPanel/index.js +1 -1
- package/modern/hooks/features/preferencesPanel/useGridPreferencesPanel.js +14 -38
- package/modern/hooks/features/rowSelection/useGridRowSelection.js +8 -16
- package/modern/hooks/features/rowSelection/utils.js +2 -2
- package/modern/hooks/features/rows/gridRowsSelector.js +1 -2
- package/modern/hooks/features/rows/gridRowsUtils.js +0 -9
- package/modern/hooks/features/rows/index.js +1 -1
- package/modern/hooks/features/rows/useGridParamsApi.js +33 -14
- package/modern/hooks/features/rows/useGridRowSpanning.js +97 -86
- package/modern/hooks/features/rows/useGridRows.js +23 -27
- package/modern/hooks/features/rows/useGridRowsMeta.js +3 -2
- package/modern/hooks/features/sorting/gridSortingSelector.js +11 -0
- package/modern/hooks/features/sorting/gridSortingUtils.js +2 -2
- package/modern/hooks/features/sorting/index.js +1 -1
- package/modern/hooks/features/sorting/useGridSorting.js +1 -1
- package/modern/hooks/features/virtualization/gridFocusedVirtualCellSelector.js +33 -0
- package/modern/hooks/features/virtualization/useGridVirtualScroller.js +169 -94
- package/modern/hooks/utils/useGridApiEventHandler.js +1 -1
- package/modern/hooks/utils/useGridApiRef.js +1 -1
- package/modern/hooks/utils/useGridSelector.js +6 -44
- package/modern/hooks/utils/useGridVisibleRows.js +5 -28
- package/modern/index.js +1 -1
- package/modern/internals/constants.js +8 -1
- package/modern/internals/index.js +5 -3
- package/modern/internals/utils/attachPinnedStyle.js +9 -0
- package/modern/internals/utils/getPinnedCellOffset.js +6 -7
- package/modern/internals/utils/index.js +2 -2
- package/modern/locales/arSD.js +14 -0
- package/modern/locales/beBY.js +13 -0
- package/modern/locales/bgBG.js +15 -0
- package/modern/locales/csCZ.js +15 -0
- package/modern/locales/daDK.js +15 -0
- package/modern/locales/deDE.js +13 -0
- package/modern/locales/elGR.js +14 -0
- package/modern/locales/esES.js +17 -4
- package/modern/locales/faIR.js +18 -4
- package/modern/locales/fiFI.js +15 -0
- package/modern/locales/frFR.js +15 -0
- package/modern/locales/heIL.js +17 -4
- package/modern/locales/hrHR.js +15 -0
- package/modern/locales/huHU.js +15 -0
- package/modern/locales/isIS.js +14 -0
- package/modern/locales/itIT.js +15 -0
- package/modern/locales/jaJP.js +15 -0
- package/modern/locales/koKR.js +47 -37
- package/modern/locales/nbNO.js +15 -0
- package/modern/locales/nlNL.js +18 -4
- package/modern/locales/nnNO.js +15 -0
- package/modern/locales/plPL.js +15 -0
- package/modern/locales/ptBR.js +13 -0
- package/modern/locales/ptPT.js +13 -0
- package/modern/locales/roRO.js +21 -9
- package/modern/locales/ruRU.js +15 -0
- package/modern/locales/skSK.js +14 -0
- package/modern/locales/svSE.js +19 -5
- package/modern/locales/trTR.js +15 -2
- package/modern/locales/ukUA.js +14 -0
- package/modern/locales/urPK.js +22 -9
- package/modern/locales/viVN.js +15 -0
- package/modern/locales/zhCN.js +17 -4
- package/modern/locales/zhHK.js +14 -0
- package/modern/locales/zhTW.js +14 -0
- package/modern/material/index.js +58 -7
- package/modern/models/api/index.js +0 -1
- package/modern/models/gridBaseSlots.js +1 -0
- package/modern/models/gridFilterInputComponent.js +1 -0
- package/modern/utils/assert.js +3 -0
- package/modern/utils/cellBorderUtils.js +5 -5
- package/modern/utils/createSelector.js +1 -120
- package/modern/utils/domUtils.js +7 -2
- package/modern/utils/isJSDOM.js +1 -0
- package/modern/utils/roundToDecimalPlaces.js +3 -0
- package/modern/utils/rtlFlipSide.js +22 -0
- package/modern/utils/utils.js +6 -1
- package/node/DataGrid/DataGrid.js +18 -36
- package/node/DataGrid/useDataGridComponent.js +1 -1
- package/node/DataGrid/useDataGridProps.js +2 -2
- package/node/components/GridApiContext.js +1 -0
- package/node/components/GridColumnHeaders.js +4 -4
- package/node/components/GridConfigurationContext.js +1 -0
- package/node/components/GridFooter.js +4 -4
- package/node/components/GridHeaders.js +2 -2
- package/node/components/GridLoadingOverlay.js +14 -12
- package/node/components/GridNoResultsOverlay.js +4 -4
- package/node/components/GridNoRowsOverlay.js +4 -4
- package/node/components/GridPagination.js +7 -4
- package/node/components/GridRow.js +51 -84
- package/node/components/GridRowCount.js +3 -2
- package/node/components/GridScrollArea.js +1 -0
- package/node/components/GridSelectedRowCount.js +3 -2
- package/node/components/GridSkeletonLoadingOverlay.js +21 -20
- package/node/components/base/GridOverlays.js +2 -24
- package/node/components/base/index.js +0 -11
- package/node/components/cell/GridActionsCell.js +8 -1
- package/node/components/cell/GridActionsCellItem.js +7 -8
- package/node/components/cell/GridCell.js +51 -91
- package/node/components/cell/GridEditDateCell.js +1 -1
- package/node/components/cell/GridEditInputCell.js +73 -4
- package/node/components/cell/GridEditSingleSelectCell.js +2 -2
- package/node/components/cell/GridSkeletonCell.js +1 -2
- package/node/components/columnHeaders/GridBaseColumnHeaders.js +4 -3
- package/node/components/columnHeaders/GridColumnGroupHeader.js +7 -10
- package/node/components/columnHeaders/GridColumnHeaderFilterIconButton.js +19 -6
- package/node/components/columnHeaders/GridColumnHeaderItem.js +13 -12
- package/node/components/columnHeaders/GridColumnHeaderTitle.js +5 -3
- package/node/components/columnHeaders/GridGenericColumnHeaderItem.js +3 -2
- package/node/components/columnHeaders/GridIconButtonContainer.js +5 -3
- package/node/components/columnSelection/GridCellCheckboxRenderer.js +10 -8
- package/node/components/columnSelection/GridHeaderCheckbox.js +17 -9
- package/node/components/columnsManagement/GridColumnsManagement.js +81 -11
- package/node/components/containers/GridFooterContainer.js +5 -3
- package/node/components/containers/GridOverlay.js +5 -3
- package/node/components/containers/GridRoot.js +17 -7
- package/node/components/containers/GridRootStyles.js +160 -50
- package/node/components/containers/GridToolbarContainer.js +3 -2
- package/node/components/menu/columnMenu/GridColumnMenu.js +5 -5
- package/node/components/menu/columnMenu/GridColumnMenuContainer.js +3 -2
- package/node/components/menu/columnMenu/menuItems/GridColumnMenuFilterItem.js +5 -10
- package/node/components/menu/columnMenu/menuItems/GridColumnMenuHideItem.js +5 -10
- package/node/components/menu/columnMenu/menuItems/GridColumnMenuManageItem.js +5 -10
- package/node/components/menu/columnMenu/menuItems/GridColumnMenuSortItem.js +13 -22
- package/node/components/panel/GridColumnsPanel.js +1 -2
- package/node/components/panel/GridPanel.js +5 -3
- package/node/components/panel/GridPanelContent.js +7 -3
- package/node/components/panel/GridPanelFooter.js +5 -4
- package/node/components/panel/GridPanelWrapper.js +5 -3
- package/node/components/panel/filterPanel/GridFilterForm.js +22 -18
- package/node/components/panel/filterPanel/GridFilterInputBoolean.js +42 -33
- package/node/components/panel/filterPanel/GridFilterInputDate.js +49 -30
- package/node/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +49 -24
- package/node/components/panel/filterPanel/GridFilterInputMultipleValue.js +55 -33
- package/node/components/panel/filterPanel/GridFilterInputSingleSelect.js +34 -25
- package/node/components/panel/filterPanel/GridFilterInputValue.js +62 -37
- package/node/components/panel/filterPanel/GridFilterPanel.js +4 -4
- package/node/components/panel/filterPanel/index.js +7 -23
- package/node/components/toolbar/GridToolbar.js +11 -5
- package/node/components/toolbar/GridToolbarColumnsButton.js +12 -6
- package/node/components/toolbar/GridToolbarDensitySelector.js +9 -11
- package/node/components/toolbar/GridToolbarExport.js +2 -1
- package/node/components/toolbar/GridToolbarExportContainer.js +6 -6
- package/node/components/toolbar/GridToolbarFilterButton.js +20 -9
- package/node/components/toolbar/GridToolbarQuickFilter.js +39 -31
- package/node/components/virtualization/GridMainContainer.js +14 -5
- package/node/components/virtualization/GridVirtualScrollbar.js +17 -17
- package/node/components/virtualization/GridVirtualScroller.js +27 -12
- package/node/components/virtualization/GridVirtualScrollerContent.js +15 -6
- package/node/components/virtualization/GridVirtualScrollerRenderZone.js +5 -3
- package/node/constants/dataGridPropsDefaultValues.js +2 -4
- package/node/constants/gridClasses.js +1 -1
- package/node/constants/localeTextConstants.js +12 -0
- package/node/context/GridRootPropsContext.js +1 -0
- package/node/hooks/core/pipeProcessing/useGridRegisterPipeApplier.js +1 -1
- package/node/hooks/core/pipeProcessing/useGridRegisterPipeProcessor.js +1 -1
- package/node/hooks/core/strategyProcessing/gridStrategyProcessingApi.js +7 -1
- package/node/hooks/core/strategyProcessing/useGridStrategyProcessing.js +7 -8
- package/node/hooks/core/useGridApiInitialization.js +2 -2
- package/node/hooks/core/useGridStateInitialization.js +3 -3
- package/node/hooks/features/columnHeaders/useGridColumnHeaders.js +32 -67
- package/node/hooks/features/columnMenu/useGridColumnMenu.js +0 -2
- package/node/hooks/features/columnResize/gridColumnResizeApi.js +2 -1
- package/node/hooks/features/columnResize/useGridColumnResize.js +17 -10
- package/node/hooks/features/columns/gridColumnsUtils.js +2 -1
- package/node/hooks/features/columns/useGridColumns.js +7 -3
- package/node/hooks/features/dimensions/useGridDimensions.js +12 -33
- package/node/hooks/features/editing/gridEditingSelectors.js +8 -2
- package/node/hooks/features/editing/useGridCellEditing.js +3 -3
- package/node/hooks/features/editing/useGridRowEditing.js +5 -6
- package/node/hooks/features/export/useGridPrintExport.js +1 -1
- package/node/hooks/features/filter/gridFilterSelector.js +6 -1
- package/node/hooks/features/filter/gridFilterUtils.js +3 -3
- package/node/hooks/features/filter/useGridFilter.js +1 -1
- package/node/hooks/features/focus/useGridFocus.js +3 -2
- package/node/hooks/features/index.js +11 -0
- package/node/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +24 -15
- package/node/hooks/features/keyboardNavigation/utils.js +0 -6
- package/node/hooks/features/listView/gridListViewSelectors.js +3 -1
- package/node/hooks/features/listView/index.js +16 -0
- package/node/hooks/features/listView/useGridListView.js +2 -1
- package/node/hooks/features/overlays/useGridOverlays.js +24 -2
- package/node/hooks/features/pagination/gridPaginationSelector.js +41 -3
- package/node/hooks/features/pagination/useGridPagination.js +5 -3
- package/node/hooks/features/pagination/useGridPaginationModel.js +23 -1
- package/node/hooks/features/preferencesPanel/gridPreferencePanelSelector.js +9 -2
- package/node/hooks/features/preferencesPanel/index.js +11 -10
- package/node/hooks/features/preferencesPanel/useGridPreferencesPanel.js +14 -38
- package/node/hooks/features/rowSelection/useGridRowSelection.js +7 -15
- package/node/hooks/features/rowSelection/utils.js +2 -2
- package/node/hooks/features/rows/gridRowsSelector.js +2 -3
- package/node/hooks/features/rows/gridRowsUtils.js +0 -9
- package/node/hooks/features/rows/index.js +0 -7
- package/node/hooks/features/rows/useGridParamsApi.js +33 -14
- package/node/hooks/features/rows/useGridRowSpanning.js +95 -84
- package/node/hooks/features/rows/useGridRows.js +21 -25
- package/node/hooks/features/rows/useGridRowsMeta.js +5 -4
- package/node/hooks/features/sorting/gridSortingSelector.js +12 -1
- package/node/hooks/features/sorting/gridSortingUtils.js +2 -2
- package/node/hooks/features/sorting/index.js +24 -16
- package/node/hooks/features/sorting/useGridSorting.js +1 -1
- package/node/hooks/features/virtualization/gridFocusedVirtualCellSelector.js +40 -0
- package/node/hooks/features/virtualization/useGridVirtualScroller.js +171 -96
- package/node/hooks/utils/useGridApiEventHandler.js +1 -1
- package/node/hooks/utils/useGridApiRef.js +1 -1
- package/node/hooks/utils/useGridSelector.js +8 -47
- package/node/hooks/utils/useGridVisibleRows.js +3 -28
- package/node/index.js +1 -1
- package/node/internals/constants.js +9 -2
- package/node/internals/index.js +36 -24
- package/node/internals/utils/attachPinnedStyle.js +15 -0
- package/node/internals/utils/getPinnedCellOffset.js +6 -7
- package/node/internals/utils/index.js +11 -11
- package/node/locales/arSD.js +14 -0
- package/node/locales/beBY.js +13 -0
- package/node/locales/bgBG.js +15 -0
- package/node/locales/csCZ.js +15 -0
- package/node/locales/daDK.js +15 -0
- package/node/locales/deDE.js +13 -0
- package/node/locales/elGR.js +14 -0
- package/node/locales/esES.js +17 -4
- package/node/locales/faIR.js +18 -4
- package/node/locales/fiFI.js +15 -0
- package/node/locales/frFR.js +15 -0
- package/node/locales/heIL.js +17 -4
- package/node/locales/hrHR.js +15 -0
- package/node/locales/huHU.js +15 -0
- package/node/locales/isIS.js +14 -0
- package/node/locales/itIT.js +15 -0
- package/node/locales/jaJP.js +15 -0
- package/node/locales/koKR.js +47 -37
- package/node/locales/nbNO.js +15 -0
- package/node/locales/nlNL.js +18 -4
- package/node/locales/nnNO.js +15 -0
- package/node/locales/plPL.js +15 -0
- package/node/locales/ptBR.js +13 -0
- package/node/locales/ptPT.js +13 -0
- package/node/locales/roRO.js +21 -9
- package/node/locales/ruRU.js +15 -0
- package/node/locales/skSK.js +14 -0
- package/node/locales/svSE.js +19 -5
- package/node/locales/trTR.js +15 -2
- package/node/locales/ukUA.js +14 -0
- package/node/locales/urPK.js +22 -9
- package/node/locales/viVN.js +15 -0
- package/node/locales/zhCN.js +17 -4
- package/node/locales/zhHK.js +14 -0
- package/node/locales/zhTW.js +14 -0
- package/node/material/index.js +59 -7
- package/node/models/api/index.js +0 -11
- package/node/models/gridFilterInputComponent.js +5 -0
- package/node/utils/assert.js +9 -0
- package/node/utils/cellBorderUtils.js +5 -5
- package/node/utils/createSelector.js +4 -125
- package/node/utils/domUtils.js +7 -2
- package/node/utils/isJSDOM.js +7 -0
- package/node/utils/roundToDecimalPlaces.js +9 -0
- package/node/utils/rtlFlipSide.js +29 -0
- package/node/utils/utils.js +8 -1
- package/package.json +5 -5
- package/themeAugmentation/overrides.d.ts +10 -5
- package/utils/assert.d.ts +2 -0
- package/utils/assert.js +3 -0
- package/utils/cellBorderUtils.d.ts +3 -3
- package/utils/cellBorderUtils.js +5 -5
- package/utils/createSelector.d.ts +7 -19
- package/utils/createSelector.js +1 -120
- package/utils/domUtils.js +7 -2
- package/utils/getPublicApiRef.d.ts +2 -1
- package/utils/isJSDOM.d.ts +1 -0
- package/utils/isJSDOM.js +1 -0
- package/utils/keyboardUtils.d.ts +1 -1
- package/utils/roundToDecimalPlaces.d.ts +1 -0
- package/utils/roundToDecimalPlaces.js +3 -0
- package/utils/rtlFlipSide.d.ts +2 -0
- package/utils/rtlFlipSide.js +22 -0
- package/utils/utils.d.ts +1 -0
- package/utils/utils.js +6 -1
- package/components/panel/filterPanel/GridFilterInputValueProps.d.ts +0 -11
- package/internals/utils/useProps.d.ts +0 -1
- package/internals/utils/useProps.js +0 -24
- package/joy/icons.d.ts +0 -32
- package/joy/icons.js +0 -431
- package/joy/index.d.ts +0 -2
- package/joy/index.js +0 -2
- package/joy/joySlots.d.ts +0 -3
- package/joy/joySlots.js +0 -384
- package/joy/package.json +0 -6
- package/modern/internals/utils/useProps.js +0 -24
- package/modern/joy/icons.js +0 -431
- package/modern/joy/index.js +0 -2
- package/modern/joy/joySlots.js +0 -384
- package/node/internals/utils/useProps.js +0 -30
- package/node/joy/icons.js +0 -439
- package/node/joy/index.js +0 -13
- package/node/joy/joySlots.js +0 -392
- /package/{components/panel/filterPanel/GridFilterInputValueProps.js → models/gridBaseSlots.js} +0 -0
- /package/{modern/components/panel/filterPanel/GridFilterInputValueProps.js → models/gridFilterInputComponent.js} +0 -0
- /package/node/{components/panel/filterPanel/GridFilterInputValueProps.js → models/gridBaseSlots.js} +0 -0
package/material/index.js
CHANGED
|
@@ -1,7 +1,16 @@
|
|
|
1
|
+
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
1
2
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
3
|
+
const _excluded = ["inert", "iconStart", "iconEnd", "children"],
|
|
4
|
+
_excluded2 = ["slotProps"];
|
|
5
|
+
import * as React from 'react';
|
|
2
6
|
import MUIBadge from '@mui/material/Badge';
|
|
3
7
|
import MUICheckbox from '@mui/material/Checkbox';
|
|
8
|
+
import MUIChip from '@mui/material/Chip';
|
|
9
|
+
import MUICircularProgress from '@mui/material/CircularProgress';
|
|
4
10
|
import MUIDivider from '@mui/material/Divider';
|
|
11
|
+
import MUILinearProgress from '@mui/material/LinearProgress';
|
|
12
|
+
import MUIListItemIcon from '@mui/material/ListItemIcon';
|
|
13
|
+
import MUIListItemText from '@mui/material/ListItemText';
|
|
5
14
|
import MUIMenuList from '@mui/material/MenuList';
|
|
6
15
|
import MUIMenuItem from '@mui/material/MenuItem';
|
|
7
16
|
import MUITextField from '@mui/material/TextField';
|
|
@@ -13,10 +22,11 @@ import MUIInputAdornment from '@mui/material/InputAdornment';
|
|
|
13
22
|
import MUITooltip from '@mui/material/Tooltip';
|
|
14
23
|
import MUIPopper from '@mui/material/Popper';
|
|
15
24
|
import MUIInputLabel from '@mui/material/InputLabel';
|
|
16
|
-
import
|
|
25
|
+
import MUISkeleton from '@mui/material/Skeleton';
|
|
17
26
|
import { GridColumnUnsortedIcon } from "./icons/GridColumnUnsortedIcon.js";
|
|
18
27
|
import { GridAddIcon, GridArrowDownwardIcon, GridArrowUpwardIcon, GridCheckIcon, GridCloseIcon, GridColumnIcon, GridDragIcon, GridExpandMoreIcon, GridFilterAltIcon, GridFilterListIcon, GridKeyboardArrowRight, GridMoreVertIcon, GridRemoveIcon, GridSaveAltIcon, GridSearchIcon, GridSeparatorIcon, GridTableRowsIcon, GridTripleDotsVerticalIcon, GridViewHeadlineIcon, GridViewStreamIcon, GridVisibilityOffIcon, GridViewColumnIcon, GridClearIcon, GridLoadIcon, GridDeleteForeverIcon } from "./icons/index.js";
|
|
19
28
|
import MUISelectOption from "./components/MUISelectOption.js";
|
|
29
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
20
30
|
const iconSlots = {
|
|
21
31
|
booleanCellTrueIcon: GridCheckIcon,
|
|
22
32
|
booleanCellFalseIcon: GridCloseIcon,
|
|
@@ -52,15 +62,18 @@ const iconSlots = {
|
|
|
52
62
|
loadIcon: GridLoadIcon,
|
|
53
63
|
filterPanelAddIcon: GridAddIcon,
|
|
54
64
|
filterPanelRemoveAllIcon: GridDeleteForeverIcon,
|
|
55
|
-
columnReorderIcon: GridDragIcon
|
|
65
|
+
columnReorderIcon: GridDragIcon,
|
|
66
|
+
menuItemCheckIcon: GridCheckIcon
|
|
56
67
|
};
|
|
57
|
-
const
|
|
68
|
+
const baseSlots = {
|
|
58
69
|
baseBadge: MUIBadge,
|
|
59
70
|
baseCheckbox: MUICheckbox,
|
|
71
|
+
baseCircularProgress: MUICircularProgress,
|
|
60
72
|
baseDivider: MUIDivider,
|
|
73
|
+
baseLinearProgress: MUILinearProgress,
|
|
61
74
|
baseMenuList: MUIMenuList,
|
|
62
|
-
baseMenuItem:
|
|
63
|
-
baseTextField:
|
|
75
|
+
baseMenuItem: BaseMenuItem,
|
|
76
|
+
baseTextField: BaseTextField,
|
|
64
77
|
baseFormControl: MUIFormControl,
|
|
65
78
|
baseSelect: MUISelect,
|
|
66
79
|
baseButton: MUIButton,
|
|
@@ -70,6 +83,44 @@ const materialSlots = _extends({}, iconSlots, {
|
|
|
70
83
|
basePopper: MUIPopper,
|
|
71
84
|
baseInputLabel: MUIInputLabel,
|
|
72
85
|
baseSelectOption: MUISelectOption,
|
|
86
|
+
baseSkeleton: MUISkeleton,
|
|
73
87
|
baseChip: MUIChip
|
|
74
|
-
}
|
|
75
|
-
|
|
88
|
+
};
|
|
89
|
+
const materialSlots = _extends({}, baseSlots, iconSlots);
|
|
90
|
+
export default materialSlots;
|
|
91
|
+
function BaseMenuItem(props) {
|
|
92
|
+
const {
|
|
93
|
+
inert,
|
|
94
|
+
iconStart,
|
|
95
|
+
iconEnd,
|
|
96
|
+
children
|
|
97
|
+
} = props,
|
|
98
|
+
other = _objectWithoutPropertiesLoose(props, _excluded);
|
|
99
|
+
if (inert) {
|
|
100
|
+
other.disableRipple = true;
|
|
101
|
+
}
|
|
102
|
+
return /*#__PURE__*/React.createElement(MUIMenuItem, other, [iconStart && /*#__PURE__*/_jsx(MUIListItemIcon, {
|
|
103
|
+
children: iconStart
|
|
104
|
+
}, "1"), /*#__PURE__*/_jsx(MUIListItemText, {
|
|
105
|
+
children: children
|
|
106
|
+
}, "2"), iconEnd && /*#__PURE__*/_jsx(MUIListItemIcon, {
|
|
107
|
+
children: iconEnd
|
|
108
|
+
}, "3")]);
|
|
109
|
+
}
|
|
110
|
+
function BaseTextField(props) {
|
|
111
|
+
// MaterialUI v5 doesn't support slotProps, until we drop v5 support we need to
|
|
112
|
+
// translate the pattern.
|
|
113
|
+
const {
|
|
114
|
+
slotProps
|
|
115
|
+
} = props,
|
|
116
|
+
rest = _objectWithoutPropertiesLoose(props, _excluded2);
|
|
117
|
+
return /*#__PURE__*/_jsx(MUITextField, _extends({
|
|
118
|
+
variant: "outlined"
|
|
119
|
+
}, rest, {
|
|
120
|
+
inputProps: slotProps?.htmlInput,
|
|
121
|
+
InputProps: slotProps?.input,
|
|
122
|
+
InputLabelProps: _extends({
|
|
123
|
+
shrink: true
|
|
124
|
+
}, slotProps?.inputLabel)
|
|
125
|
+
}));
|
|
126
|
+
}
|
|
@@ -7,7 +7,7 @@ import { GridEditingApi, GridEditingPrivateApi } from './gridEditingApi';
|
|
|
7
7
|
import type { GridFilterApi } from './gridFilterApi';
|
|
8
8
|
import { GridFocusApi, GridFocusPrivateApi } from './gridFocusApi';
|
|
9
9
|
import type { GridLocaleTextApi } from './gridLocaleTextApi';
|
|
10
|
-
import type { GridParamsApi } from './gridParamsApi';
|
|
10
|
+
import type { GridParamsApi, GridParamsPrivateApi } from './gridParamsApi';
|
|
11
11
|
import { GridPreferencesPanelApi } from './gridPreferencesPanelApi';
|
|
12
12
|
import { GridPrintExportApi } from './gridPrintExportApi';
|
|
13
13
|
import { GridRowApi, GridRowProPrivateApi } from './gridRowApi';
|
|
@@ -31,7 +31,7 @@ import type { DataGridProcessedProps } from '../props/DataGridProps';
|
|
|
31
31
|
import type { GridColumnResizeApi } from '../../hooks/features/columnResize';
|
|
32
32
|
export interface GridApiCommon<GridState extends GridStateCommunity = any, GridInitialState extends GridInitialStateCommunity = any> extends GridCoreApi, GridPipeProcessingApi, GridDensityApi, GridDimensionsApi, GridRowApi, GridRowsMetaApi, GridEditingApi, GridParamsApi, GridColumnApi, GridRowSelectionApi, GridSortApi, GridPaginationApi, GridCsvExportApi, GridFocusApi, GridFilterApi, GridColumnMenuApi, GridPreferencesPanelApi, GridPrintExportApi, GridVirtualizationApi, GridLocaleTextApi, GridScrollApi, GridColumnSpanningApi, GridStateApi<GridState>, GridStatePersistenceApi<GridInitialState>, GridColumnGroupingApi, GridHeaderFilteringApi, GridColumnResizeApi {
|
|
33
33
|
}
|
|
34
|
-
export interface GridPrivateOnlyApiCommon<Api extends GridApiCommon, PrivateApi extends GridPrivateApiCommon, Props extends DataGridProcessedProps> extends GridCorePrivateApi<Api, PrivateApi, Props>, GridStatePrivateApi<PrivateApi['state']>, GridPipeProcessingPrivateApi, GridStrategyProcessingApi, GridColumnSpanningPrivateApi, GridRowsMetaPrivateApi, GridDimensionsPrivateApi, GridEditingPrivateApi, GridLoggerApi, GridFocusPrivateApi, GridHeaderFilteringPrivateApi, GridVirtualizationPrivateApi, GridRowProPrivateApi {
|
|
34
|
+
export interface GridPrivateOnlyApiCommon<Api extends GridApiCommon, PrivateApi extends GridPrivateApiCommon, Props extends DataGridProcessedProps> extends GridCorePrivateApi<Api, PrivateApi, Props>, GridStatePrivateApi<PrivateApi['state']>, GridPipeProcessingPrivateApi, GridStrategyProcessingApi, GridColumnSpanningPrivateApi, GridRowsMetaPrivateApi, GridDimensionsPrivateApi, GridEditingPrivateApi, GridLoggerApi, GridFocusPrivateApi, GridHeaderFilteringPrivateApi, GridVirtualizationPrivateApi, GridRowProPrivateApi, GridParamsPrivateApi {
|
|
35
35
|
}
|
|
36
36
|
export interface GridPrivateApiCommon extends GridApiCommon, GridPrivateOnlyApiCommon<GridApiCommon, GridPrivateApiCommon, DataGridProcessedProps> {
|
|
37
37
|
}
|
|
@@ -13,7 +13,7 @@ export interface GridCoreApi {
|
|
|
13
13
|
* The React ref of the grid root container div element.
|
|
14
14
|
* @ignore - do not document.
|
|
15
15
|
*/
|
|
16
|
-
rootElementRef: React.RefObject<HTMLDivElement>;
|
|
16
|
+
rootElementRef: React.RefObject<HTMLDivElement | null>;
|
|
17
17
|
/**
|
|
18
18
|
* Registers a handler for an event.
|
|
19
19
|
* @param {string} event The name of the event.
|
|
@@ -59,27 +59,27 @@ export interface GridCorePrivateApi<GridPublicApi extends GridApiCommon, GridPri
|
|
|
59
59
|
/**
|
|
60
60
|
* The React ref of the grid main container div element.
|
|
61
61
|
*/
|
|
62
|
-
mainElementRef: React.RefObject<HTMLDivElement>;
|
|
62
|
+
mainElementRef: React.RefObject<HTMLDivElement | null>;
|
|
63
63
|
/**
|
|
64
64
|
* The React ref of the grid's virtual scroller container element.
|
|
65
65
|
*/
|
|
66
|
-
virtualScrollerRef: React.RefObject<HTMLDivElement>;
|
|
66
|
+
virtualScrollerRef: React.RefObject<HTMLDivElement | null>;
|
|
67
67
|
/**
|
|
68
68
|
* The React ref of the grid's vertical virtual scrollbar container element.
|
|
69
69
|
*/
|
|
70
|
-
virtualScrollbarVerticalRef: React.RefObject<HTMLDivElement>;
|
|
70
|
+
virtualScrollbarVerticalRef: React.RefObject<HTMLDivElement | null>;
|
|
71
71
|
/**
|
|
72
72
|
* The React ref of the grid's horizontal virtual scrollbar container element.
|
|
73
73
|
*/
|
|
74
|
-
virtualScrollbarHorizontalRef: React.RefObject<HTMLDivElement>;
|
|
74
|
+
virtualScrollbarHorizontalRef: React.RefObject<HTMLDivElement | null>;
|
|
75
75
|
/**
|
|
76
76
|
* The React ref of the grid column container virtualized div element.
|
|
77
77
|
*/
|
|
78
|
-
columnHeadersContainerRef: React.RefObject<HTMLDivElement>;
|
|
78
|
+
columnHeadersContainerRef: React.RefObject<HTMLDivElement | null>;
|
|
79
79
|
/**
|
|
80
80
|
* The React ref of the grid header filter row element.
|
|
81
81
|
*/
|
|
82
|
-
headerFiltersElementRef?: React.RefObject<HTMLDivElement>;
|
|
82
|
+
headerFiltersElementRef?: React.RefObject<HTMLDivElement | null>;
|
|
83
83
|
register: <V extends 'public' | 'private', T extends V extends 'public' ? Partial<GridPublicApi> : Partial<Omit<GridPrivateApi, keyof GridPublicApi>>>(visibility: V, methods: T) => void;
|
|
84
84
|
/**
|
|
85
85
|
* Returns the public API.
|
|
@@ -26,6 +26,15 @@ export interface GridLocaleText {
|
|
|
26
26
|
toolbarQuickFilterPlaceholder: string;
|
|
27
27
|
toolbarQuickFilterLabel: string;
|
|
28
28
|
toolbarQuickFilterDeleteIconLabel: string;
|
|
29
|
+
toolbarPromptControlPlaceholder: string;
|
|
30
|
+
toolbarPromptControlWithRecordingPlaceholder: string;
|
|
31
|
+
toolbarPromptControlRecordingPlaceholder: string;
|
|
32
|
+
toolbarPromptControlLabel: string;
|
|
33
|
+
toolbarPromptControlRecordButtonDefaultLabel: string;
|
|
34
|
+
toolbarPromptControlRecordButtonActiveLabel: string;
|
|
35
|
+
toolbarPromptControlSendActionLabel: string;
|
|
36
|
+
toolbarPromptControlSendActionAriaLabel: string;
|
|
37
|
+
toolbarPromptControlErrorMessage: string;
|
|
29
38
|
toolbarExport: React.ReactNode;
|
|
30
39
|
toolbarExportLabel: string;
|
|
31
40
|
toolbarExportCSV: React.ReactNode;
|
|
@@ -35,6 +44,7 @@ export interface GridLocaleText {
|
|
|
35
44
|
columnsManagementNoColumns: string;
|
|
36
45
|
columnsManagementShowHideAllText: string;
|
|
37
46
|
columnsManagementReset: string;
|
|
47
|
+
columnsManagementDeleteIconLabel: string;
|
|
38
48
|
filterPanelAddFilter: React.ReactNode;
|
|
39
49
|
filterPanelRemoveAll: React.ReactNode;
|
|
40
50
|
filterPanelDeleteIconLabel: string;
|
|
@@ -87,6 +97,7 @@ export interface GridLocaleText {
|
|
|
87
97
|
'headerFilterOperator>=': string;
|
|
88
98
|
'headerFilterOperator<': string;
|
|
89
99
|
'headerFilterOperator<=': string;
|
|
100
|
+
headerFilterClear: string;
|
|
90
101
|
filterValueAny: string;
|
|
91
102
|
filterValueTrue: string;
|
|
92
103
|
filterValueFalse: string;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { GridColDef } from '../colDef';
|
|
2
|
+
import { GridStateColDef } from '../colDef/gridColDef';
|
|
3
|
+
import { GridCellMode } from '../gridCell';
|
|
2
4
|
import { GridValidRowModel, GridRowId, GridTreeNode, GridRowModel } from '../gridRows';
|
|
3
5
|
import { GridCellParams } from '../params/gridCellParams';
|
|
4
6
|
import { GridColumnHeaderParams } from '../params/gridColumnHeaderParams';
|
|
@@ -33,10 +35,10 @@ export interface GridParamsApi {
|
|
|
33
35
|
*/
|
|
34
36
|
getRowFormattedValue: <V extends any = any>(row: GridRowModel, colDef: GridColDef) => V;
|
|
35
37
|
/**
|
|
36
|
-
* Gets the
|
|
38
|
+
* Gets the [[GridCellParams]] object that is passed as argument in events.
|
|
37
39
|
* @param {GridRowId} id The id of the row.
|
|
38
40
|
* @param {string} field The column field.
|
|
39
|
-
* @returns {
|
|
41
|
+
* @returns {GridCellParams} The cell params.
|
|
40
42
|
*/
|
|
41
43
|
getCellElement: (id: GridRowId, field: string) => HTMLDivElement | null;
|
|
42
44
|
/**
|
|
@@ -72,3 +74,28 @@ export interface GridParamsApi {
|
|
|
72
74
|
*/
|
|
73
75
|
getColumnHeaderParams: (field: string) => GridColumnHeaderParams;
|
|
74
76
|
}
|
|
77
|
+
export interface GridParamsPrivateApi {
|
|
78
|
+
/**
|
|
79
|
+
* @typedef {Object} CellParamsOverrides
|
|
80
|
+
* @property {GridCellMode} cellMode - The mode of the cell.
|
|
81
|
+
* @property {GridStateColDef} colDef - The column definition.
|
|
82
|
+
* @property {boolean} hasFocus - Indicates if the cell is in focus.
|
|
83
|
+
* @property {GridTreeNode} rowNode - The node of the row that the current cell belongs to.
|
|
84
|
+
* @property {0|-1} tabIndex - The tabIndex value.
|
|
85
|
+
*/
|
|
86
|
+
/**
|
|
87
|
+
* Used internally to render the cell based on existing row data provided by the GridRow.
|
|
88
|
+
* @param {GridRowId} id The id of the row.
|
|
89
|
+
* @param {string} field The column field.
|
|
90
|
+
* @param {GridValidRowModel} row The row model.
|
|
91
|
+
* @param {CellParamsOverrides} cellParams The cell params.
|
|
92
|
+
* @returns {GridCellParams} The cell params.
|
|
93
|
+
*/
|
|
94
|
+
getCellParamsForRow: <R extends GridValidRowModel = any, V = unknown, F = V, N extends GridTreeNode = GridTreeNode>(id: GridRowId, field: string, row: R, { cellMode, colDef, hasFocus, rowNode, tabIndex, }: {
|
|
95
|
+
cellMode: GridCellMode;
|
|
96
|
+
colDef: GridStateColDef;
|
|
97
|
+
hasFocus: boolean;
|
|
98
|
+
rowNode: N;
|
|
99
|
+
tabIndex: 0 | -1;
|
|
100
|
+
}) => GridCellParams<R, V, F, N>;
|
|
101
|
+
}
|
|
@@ -33,5 +33,5 @@ export interface GridStatePrivateApi<State extends GridStateCommunity> {
|
|
|
33
33
|
* Updates a control state that binds the model, the onChange prop, and the grid state together.
|
|
34
34
|
* @param {GridControlStateItem>} controlState The [[GridControlStateItem]] to be registered.
|
|
35
35
|
*/
|
|
36
|
-
registerControlState: <E extends keyof GridControlledStateEventLookup>(controlState: GridControlStateItem<State, E>) => void;
|
|
36
|
+
registerControlState: <E extends keyof GridControlledStateEventLookup, Args>(controlState: GridControlStateItem<State, Args, E>) => void;
|
|
37
37
|
}
|
package/models/api/index.d.ts
CHANGED
package/models/api/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
3
|
import { GridCellClassNamePropType } from '../gridCellClass';
|
|
3
4
|
import { GridColumnHeaderClassNamePropType } from '../gridColumnHeaderClass';
|
|
4
5
|
import type { GridFilterOperator } from '../gridFilterOperator';
|
|
@@ -24,55 +25,55 @@ export type ValueOptions = string | number | {
|
|
|
24
25
|
* Value that can be used as a key for grouping rows
|
|
25
26
|
*/
|
|
26
27
|
export type GridKeyValue = string | number | boolean;
|
|
27
|
-
export type GridApplyQuickFilter<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: V, row: R, column: GridColDef, apiRef:
|
|
28
|
-
export type GetApplyQuickFilterFn<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: any, colDef: GridStateColDef<R, V>, apiRef:
|
|
29
|
-
export type GridValueGetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
30
|
-
export type GridValueFormatter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
31
|
-
export type GridValueSetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
32
|
-
export type GridValueParser<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: F | undefined, row: R | undefined, column: GridColDef<R, V, F>, apiRef:
|
|
33
|
-
export type GridColSpanFn<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
28
|
+
export type GridApplyQuickFilter<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: V, row: R, column: GridColDef, apiRef: RefObject<GridApiCommunity>) => boolean;
|
|
29
|
+
export type GetApplyQuickFilterFn<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: any, colDef: GridStateColDef<R, V>, apiRef: RefObject<GridApiCommunity>) => null | GridApplyQuickFilter<R, V>;
|
|
30
|
+
export type GridValueGetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => V;
|
|
31
|
+
export type GridValueFormatter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => F;
|
|
32
|
+
export type GridValueSetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => R;
|
|
33
|
+
export type GridValueParser<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: F | undefined, row: R | undefined, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => V;
|
|
34
|
+
export type GridColSpanFn<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => number | undefined;
|
|
34
35
|
/**
|
|
35
36
|
* Column Definition base interface.
|
|
36
37
|
*/
|
|
37
38
|
export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> {
|
|
38
39
|
/**
|
|
39
|
-
* The
|
|
40
|
+
* The unique identifier of the column. Used to map with [[GridRowModel]] values.
|
|
40
41
|
*/
|
|
41
42
|
field: string;
|
|
42
43
|
/**
|
|
43
|
-
* The title
|
|
44
|
+
* The title displayed in the column header cell.
|
|
44
45
|
*/
|
|
45
46
|
headerName?: string;
|
|
46
47
|
/**
|
|
47
|
-
* The
|
|
48
|
+
* The tooltip text shown when the column header name is truncated.
|
|
48
49
|
*/
|
|
49
50
|
description?: string;
|
|
50
51
|
/**
|
|
51
|
-
*
|
|
52
|
+
* The width of the column in pixels.
|
|
52
53
|
* @default 100
|
|
53
54
|
*/
|
|
54
55
|
width?: number;
|
|
55
56
|
/**
|
|
56
|
-
*
|
|
57
|
+
* The flex grow factor of the column. Must be a positive number.
|
|
57
58
|
*/
|
|
58
59
|
flex?: number;
|
|
59
60
|
/**
|
|
60
|
-
*
|
|
61
|
+
* The minimum width of the column in pixels.
|
|
61
62
|
* @default 50
|
|
62
63
|
*/
|
|
63
64
|
minWidth?: number;
|
|
64
65
|
/**
|
|
65
|
-
*
|
|
66
|
+
* The maximum width of the column in pixels.
|
|
66
67
|
* @default Infinity
|
|
67
68
|
*/
|
|
68
69
|
maxWidth?: number;
|
|
69
70
|
/**
|
|
70
|
-
* If `false`, removes the
|
|
71
|
+
* If `false`, removes the option to hide this column.
|
|
71
72
|
* @default true
|
|
72
73
|
*/
|
|
73
74
|
hideable?: boolean;
|
|
74
75
|
/**
|
|
75
|
-
* If `
|
|
76
|
+
* If `false`, disables sorting for this column.
|
|
76
77
|
* @default true
|
|
77
78
|
*/
|
|
78
79
|
sortable?: boolean;
|
|
@@ -81,7 +82,7 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
81
82
|
*/
|
|
82
83
|
sortingOrder?: readonly GridSortDirection[];
|
|
83
84
|
/**
|
|
84
|
-
* If `
|
|
85
|
+
* If `false`, disables resizing for this column.
|
|
85
86
|
* @default true
|
|
86
87
|
*/
|
|
87
88
|
resizable?: boolean;
|
|
@@ -109,7 +110,7 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
109
110
|
*/
|
|
110
111
|
sortComparator?: GridComparatorFn<V>;
|
|
111
112
|
/**
|
|
112
|
-
*
|
|
113
|
+
* Provide an alternative comparator function for sorting.
|
|
113
114
|
* Takes precedence over `sortComparator`.
|
|
114
115
|
* @param {GridSortDirection} sortDirection The direction of the sort.
|
|
115
116
|
* @returns {GridComparatorFn<V>} The comparator function to use.
|
|
@@ -122,25 +123,25 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
122
123
|
*/
|
|
123
124
|
type?: GridColType;
|
|
124
125
|
/**
|
|
125
|
-
*
|
|
126
|
+
* Align cell content.
|
|
126
127
|
*/
|
|
127
128
|
align?: GridAlignment;
|
|
128
129
|
/**
|
|
129
|
-
* Function that
|
|
130
|
+
* Function that returns specific data to render in the cell instead of using the field value.
|
|
130
131
|
*/
|
|
131
132
|
valueGetter?: GridValueGetter<R, V, F>;
|
|
132
133
|
/**
|
|
133
|
-
* Function that
|
|
134
|
+
* Function that returns a specific value to be used in row spanning.
|
|
134
135
|
*/
|
|
135
136
|
rowSpanValueGetter?: GridValueGetter<R, V, F>;
|
|
136
137
|
/**
|
|
137
|
-
* Function that
|
|
138
|
-
*
|
|
138
|
+
* Function that customizes how the entered value is stored in the row.
|
|
139
|
+
* Only works with cell/row editing.
|
|
139
140
|
* @returns {R} The row with the updated field.
|
|
140
141
|
*/
|
|
141
142
|
valueSetter?: GridValueSetter<R, V, F>;
|
|
142
143
|
/**
|
|
143
|
-
*
|
|
144
|
+
* Formats the cell value before rendering.
|
|
144
145
|
*/
|
|
145
146
|
valueFormatter?: GridValueFormatter<R, V, F>;
|
|
146
147
|
/**
|
|
@@ -149,7 +150,7 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
149
150
|
*/
|
|
150
151
|
valueParser?: GridValueParser<R, V, F>;
|
|
151
152
|
/**
|
|
152
|
-
* Class name
|
|
153
|
+
* Class name added to cells in this column.
|
|
153
154
|
*/
|
|
154
155
|
cellClassName?: GridCellClassNamePropType<R, V>;
|
|
155
156
|
/**
|
|
@@ -159,38 +160,38 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
159
160
|
*/
|
|
160
161
|
display?: 'text' | 'flex';
|
|
161
162
|
/**
|
|
162
|
-
*
|
|
163
|
+
* Override the component rendered as cell for this column.
|
|
163
164
|
* @template R, V, F
|
|
164
165
|
* @param {GridRenderCellParams<R, V, F>} params Object containing parameters for the renderer.
|
|
165
166
|
* @returns {React.ReactNode} The element to be rendered.
|
|
166
167
|
*/
|
|
167
168
|
renderCell?: (params: GridRenderCellParams<R, V, F>) => React.ReactNode;
|
|
168
169
|
/**
|
|
169
|
-
*
|
|
170
|
+
* Override the component rendered in edit cell mode for this column.
|
|
170
171
|
* @param {GridRenderEditCellParams} params Object containing parameters for the renderer.
|
|
171
172
|
* @returns {React.ReactNode} The element to be rendered.
|
|
172
173
|
*/
|
|
173
174
|
renderEditCell?: (params: GridRenderEditCellParams<R, V, F>) => React.ReactNode;
|
|
174
175
|
/**
|
|
175
176
|
* Callback fired when the edit props of the cell changes.
|
|
176
|
-
*
|
|
177
|
+
* Processes the props before being saved into the state.
|
|
177
178
|
* @param {GridPreProcessEditCellProps} params Object containing parameters of the cell being edited.
|
|
178
179
|
* @returns {GridEditCellProps | Promise<GridEditCellProps>} The new edit cell props.
|
|
179
180
|
*/
|
|
180
181
|
preProcessEditCellProps?: (params: GridPreProcessEditCellProps) => GridEditCellProps | Promise<GridEditCellProps>;
|
|
181
182
|
/**
|
|
182
|
-
* Class name
|
|
183
|
+
* Class name added to the column header cell.
|
|
183
184
|
*/
|
|
184
185
|
headerClassName?: GridColumnHeaderClassNamePropType;
|
|
185
186
|
/**
|
|
186
|
-
*
|
|
187
|
+
* Override the component rendered in the column header cell.
|
|
187
188
|
* @template R, V, F
|
|
188
189
|
* @param {GridColumnHeaderParams<R, V, F>} params Object containing parameters for the renderer.
|
|
189
190
|
* @returns {React.ReactNode} The element to be rendered.
|
|
190
191
|
*/
|
|
191
192
|
renderHeader?: (params: GridColumnHeaderParams<R, V, F>) => React.ReactNode;
|
|
192
193
|
/**
|
|
193
|
-
*
|
|
194
|
+
* Align column header content.
|
|
194
195
|
*/
|
|
195
196
|
headerAlign?: GridAlignment;
|
|
196
197
|
/**
|
|
@@ -211,13 +212,13 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
211
212
|
/**
|
|
212
213
|
* Allows setting the filter operators for this column.
|
|
213
214
|
*/
|
|
214
|
-
filterOperators?: readonly GridFilterOperator<R, V, F>[];
|
|
215
|
+
filterOperators?: readonly GridFilterOperator<R, V, F, any>[];
|
|
215
216
|
/**
|
|
216
217
|
* The callback that generates a filtering function for a given quick filter value.
|
|
217
218
|
* This function can return `null` to skip filtering for this value and column.
|
|
218
219
|
* @param {any} value The value with which we want to filter the column.
|
|
219
220
|
* @param {GridStateColDef} colDef The column from which we want to filter the rows.
|
|
220
|
-
* @param {
|
|
221
|
+
* @param {RefObject<GridApiCommunity>} apiRef Deprecated: The API of the grid.
|
|
221
222
|
* @returns {null | GridApplyQuickFilter} The function to call to check if a row pass this filter value or not.
|
|
222
223
|
*/
|
|
223
224
|
getApplyQuickFilterFn?: GetApplyQuickFilterFn<R, V>;
|
|
@@ -236,6 +237,10 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
236
237
|
* @default 1
|
|
237
238
|
*/
|
|
238
239
|
colSpan?: number | GridColSpanFn<R, V, F>;
|
|
240
|
+
/**
|
|
241
|
+
* Example values that can be used by the grid to get more context about the column.
|
|
242
|
+
*/
|
|
243
|
+
unstable_examples?: V[];
|
|
239
244
|
}
|
|
240
245
|
/**
|
|
241
246
|
* Column Definition interface used for columns with the `actions` type.
|
|
@@ -2,10 +2,10 @@ import { GridCallbackDetails } from './api/gridCallbackDetails';
|
|
|
2
2
|
import type { GridEventLookup, GridControlledStateEventLookup } from './events';
|
|
3
3
|
import type { OutputSelector } from '../utils/createSelector';
|
|
4
4
|
import { GridStateCommunity } from './gridStateCommunity';
|
|
5
|
-
export interface GridControlStateItem<State extends GridStateCommunity, E extends keyof GridControlledStateEventLookup> {
|
|
5
|
+
export interface GridControlStateItem<State extends GridStateCommunity, Args, E extends keyof GridControlledStateEventLookup> {
|
|
6
6
|
stateId: string;
|
|
7
7
|
propModel?: GridEventLookup[E]['params'];
|
|
8
|
-
stateSelector: OutputSelector<State, GridControlledStateEventLookup[E]['params']> | ((state: State) => GridControlledStateEventLookup[E]['params']);
|
|
8
|
+
stateSelector: OutputSelector<State, Args, GridControlledStateEventLookup[E]['params']> | ((state: State) => GridControlledStateEventLookup[E]['params']);
|
|
9
9
|
propOnChange?: (model: GridControlledStateEventLookup[E]['params'], details: GridCallbackDetails) => void;
|
|
10
10
|
changeEvent: E;
|
|
11
11
|
}
|
|
@@ -399,6 +399,7 @@ export interface GridControlledStateEventLookup {
|
|
|
399
399
|
export interface GridControlledStateReasonLookup {
|
|
400
400
|
filter: 'upsertFilterItem' | 'upsertFilterItems' | 'deleteFilterItem' | 'changeLogicOperator' | 'restoreState' | 'removeAllFilterItems';
|
|
401
401
|
pagination: 'setPaginationModel' | 'stateRestorePreProcessing';
|
|
402
|
+
rows: 'addSkeletonRows';
|
|
402
403
|
}
|
|
403
404
|
export interface GridEventLookup extends GridRowEventLookup, GridColumnHeaderEventLookup, GridHeaderFilterEventLookup, GridColumnGroupHeaderEventLookup, GridCellEventLookup, GridControlledStateEventLookup {
|
|
404
405
|
/**
|
|
@@ -583,7 +584,12 @@ export interface GridEventLookup extends GridRowEventLookup, GridColumnHeaderEve
|
|
|
583
584
|
* Fired when the content size used by the `GridVirtualScroller` changes.
|
|
584
585
|
* @ignore - do not document.
|
|
585
586
|
*/
|
|
586
|
-
virtualScrollerContentSizeChange: {
|
|
587
|
+
virtualScrollerContentSizeChange: {
|
|
588
|
+
params: {
|
|
589
|
+
columnsTotalWidth: number;
|
|
590
|
+
contentHeight: number;
|
|
591
|
+
};
|
|
592
|
+
};
|
|
587
593
|
/**
|
|
588
594
|
* Fired when the content is scrolled by the mouse wheel.
|
|
589
595
|
* It's attached to the "mousewheel" event.
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
type Ref<T = HTMLElement> = React.RefCallback<T | null> | React.RefObject<T | null> | null;
|
|
2
|
+
export type BadgeProps = {
|
|
3
|
+
badgeContent?: React.ReactNode;
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
color?: 'primary' | 'default' | 'error';
|
|
6
|
+
invisible?: boolean;
|
|
7
|
+
overlap?: 'circular';
|
|
8
|
+
variant?: 'dot';
|
|
9
|
+
style?: React.CSSProperties;
|
|
10
|
+
};
|
|
11
|
+
export type ButtonProps = {
|
|
12
|
+
ref?: Ref;
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
className?: string;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
id?: string;
|
|
17
|
+
onClick?: React.MouseEventHandler<HTMLElement>;
|
|
18
|
+
onKeyDown?: React.KeyboardEventHandler<HTMLElement>;
|
|
19
|
+
role?: string;
|
|
20
|
+
size?: 'small' | 'medium' | 'large';
|
|
21
|
+
startIcon?: React.ReactNode;
|
|
22
|
+
style?: React.CSSProperties;
|
|
23
|
+
tabIndex?: number;
|
|
24
|
+
title?: string;
|
|
25
|
+
touchRippleRef?: any;
|
|
26
|
+
};
|
|
27
|
+
export type IconButtonProps = Omit<ButtonProps, 'startIcon'> & {
|
|
28
|
+
label?: string;
|
|
29
|
+
color?: 'default' | 'inherit' | 'primary';
|
|
30
|
+
edge?: 'start' | 'end' | false;
|
|
31
|
+
};
|
|
32
|
+
export type DividerProps = {};
|
|
33
|
+
export type MenuItemProps = {
|
|
34
|
+
autoFocus?: boolean;
|
|
35
|
+
children?: React.ReactNode;
|
|
36
|
+
/** For items that aren't interactive themselves (but may contain an interactive widget) */
|
|
37
|
+
inert?: boolean;
|
|
38
|
+
disabled?: boolean;
|
|
39
|
+
onClick?: React.MouseEventHandler<HTMLElement>;
|
|
40
|
+
iconStart?: React.ReactNode;
|
|
41
|
+
iconEnd?: React.ReactNode;
|
|
42
|
+
selected?: boolean;
|
|
43
|
+
value?: number | string | readonly string[];
|
|
44
|
+
style?: React.CSSProperties;
|
|
45
|
+
};
|
|
46
|
+
export type CircularProgressProps = {
|
|
47
|
+
/**
|
|
48
|
+
* Pixels or CSS value.
|
|
49
|
+
* @default 40
|
|
50
|
+
*/
|
|
51
|
+
size?: number | string;
|
|
52
|
+
/** @default 'primary' */
|
|
53
|
+
color?: 'inherit' | 'primary';
|
|
54
|
+
};
|
|
55
|
+
export type LinearProgressProps = {};
|
|
56
|
+
export type SkeletonProps = {
|
|
57
|
+
variant?: 'circular' | 'text';
|
|
58
|
+
width?: number | string;
|
|
59
|
+
height?: number | string;
|
|
60
|
+
};
|
|
61
|
+
export type TextFieldProps = {
|
|
62
|
+
autoComplete?: string;
|
|
63
|
+
className?: string;
|
|
64
|
+
color?: 'primary' | 'error';
|
|
65
|
+
disabled?: boolean;
|
|
66
|
+
error?: boolean;
|
|
67
|
+
fullWidth?: boolean;
|
|
68
|
+
helperText?: string | null;
|
|
69
|
+
id?: string;
|
|
70
|
+
inputRef?: React.Ref<HTMLInputElement>;
|
|
71
|
+
label?: React.ReactNode;
|
|
72
|
+
onChange?: React.ChangeEventHandler;
|
|
73
|
+
onKeyDown?: React.KeyboardEventHandler;
|
|
74
|
+
placeholder?: string;
|
|
75
|
+
size?: 'small' | 'medium';
|
|
76
|
+
slotProps?: {
|
|
77
|
+
input?: {
|
|
78
|
+
disabled?: boolean;
|
|
79
|
+
endAdornment?: React.ReactNode;
|
|
80
|
+
startAdornment?: React.ReactNode;
|
|
81
|
+
};
|
|
82
|
+
inputLabel?: {};
|
|
83
|
+
htmlInput?: React.InputHTMLAttributes<HTMLInputElement>;
|
|
84
|
+
};
|
|
85
|
+
style?: React.CSSProperties;
|
|
86
|
+
tabIndex?: number;
|
|
87
|
+
type?: React.HTMLInputTypeAttribute;
|
|
88
|
+
value?: string;
|
|
89
|
+
};
|
|
90
|
+
export type TooltipProps = {
|
|
91
|
+
children: React.ReactElement<any, any>;
|
|
92
|
+
enterDelay?: number;
|
|
93
|
+
title: React.ReactNode;
|
|
94
|
+
};
|
|
95
|
+
export {};
|