@mui/x-data-grid 6.4.0 → 6.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +134 -2
- package/DataGrid/DataGrid.js +10 -3
- package/DataGrid/useDataGridProps.js +5 -12
- package/README.md +2 -2
- package/colDef/gridNumericOperators.js +0 -6
- package/components/GridColumnHeaders.js +4 -9
- package/components/GridHeader.d.ts +2 -2
- package/components/base/GridBody.d.ts +1 -1
- package/components/base/GridFooterPlaceholder.d.ts +2 -2
- package/components/base/GridOverlays.d.ts +2 -2
- package/components/cell/GridActionsCell.d.ts +3 -3
- package/components/cell/GridActionsCell.js +3 -3
- package/components/cell/GridBooleanCell.d.ts +1 -1
- package/components/cell/GridEditBooleanCell.d.ts +2 -2
- package/components/cell/GridEditDateCell.d.ts +2 -2
- package/components/cell/GridEditInputCell.d.ts +1 -1
- package/components/cell/GridEditInputCell.js +4 -1
- package/components/cell/GridEditSingleSelectCell.d.ts +3 -3
- package/components/cell/GridEditSingleSelectCell.js +5 -5
- package/components/cell/GridSkeletonCell.d.ts +1 -1
- package/components/columnHeaders/ColumnHeaderMenuIcon.d.ts +1 -1
- package/components/columnHeaders/ColumnHeaderMenuIcon.js +3 -3
- package/components/columnHeaders/GridColumnGroupHeader.d.ts +2 -2
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.js +13 -4
- package/components/columnHeaders/GridColumnHeaderItem.d.ts +2 -2
- package/components/columnHeaders/GridColumnHeaderSeparator.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderSortIcon.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderTitle.d.ts +1 -1
- package/components/containers/GridRoot.js +1 -3
- package/components/index.d.ts +0 -1
- package/components/index.js +1 -2
- package/components/menu/GridMenu.d.ts +1 -1
- package/components/menu/columnMenu/GridColumnHeaderMenu.d.ts +1 -1
- package/components/menu/columnMenu/menuItems/GridColumnMenuColumnsItem.d.ts +2 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuFilterItem.d.ts +2 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuHideItem.d.ts +2 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuManageItem.d.ts +2 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuSortItem.d.ts +2 -2
- package/components/panel/GridColumnsPanel.d.ts +2 -2
- package/components/panel/GridPanelContent.d.ts +1 -1
- package/components/panel/GridPanelFooter.d.ts +1 -1
- package/components/panel/GridPanelHeader.d.ts +1 -1
- package/components/panel/GridPreferencesPanel.js +3 -1
- package/components/panel/filterPanel/GridFilterInputBoolean.d.ts +15 -2
- package/components/panel/filterPanel/GridFilterInputBoolean.js +80 -36
- package/components/panel/filterPanel/GridFilterInputDate.d.ts +9 -2
- package/components/panel/filterPanel/GridFilterInputDate.js +27 -6
- package/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.d.ts +2 -2
- package/components/panel/filterPanel/GridFilterInputMultipleValue.d.ts +2 -2
- package/components/panel/filterPanel/GridFilterInputSingleSelect.d.ts +9 -2
- package/components/panel/filterPanel/GridFilterInputSingleSelect.js +56 -32
- package/components/panel/filterPanel/GridFilterInputValue.d.ts +11 -4
- package/components/panel/filterPanel/GridFilterInputValue.js +29 -6
- package/components/panel/filterPanel/GridFilterPanel.d.ts +2 -1
- package/components/panel/filterPanel/GridFilterPanel.js +1 -1
- package/components/panel/filterPanel/index.d.ts +3 -1
- package/components/panel/filterPanel/index.js +2 -1
- package/components/toolbar/GridToolbarColumnsButton.js +11 -6
- package/components/toolbar/GridToolbarDensitySelector.js +2 -2
- package/components/toolbar/GridToolbarExport.d.ts +2 -2
- package/components/toolbar/GridToolbarExportContainer.js +7 -7
- package/components/toolbar/GridToolbarFilterButton.js +11 -4
- package/components/toolbar/GridToolbarQuickFilter.d.ts +2 -2
- package/constants/localeTextConstants.js +26 -0
- package/context/GridContextProvider.d.ts +1 -1
- package/hooks/core/strategyProcessing/gridStrategyProcessingApi.d.ts +10 -2
- package/hooks/core/strategyProcessing/useGridStrategyProcessing.js +2 -1
- package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +10 -3
- package/hooks/features/columnHeaders/useGridColumnHeaders.js +4 -2
- package/hooks/features/dimensions/useGridDimensions.js +2 -2
- package/hooks/features/editing/useGridEditing.js +0 -3
- package/hooks/features/filter/gridFilterSelector.d.ts +2 -2
- package/hooks/features/filter/gridFilterSelector.js +2 -2
- package/hooks/features/filter/gridFilterState.d.ts +6 -6
- package/hooks/features/filter/gridFilterState.js +6 -0
- package/hooks/features/filter/useGridFilter.js +29 -9
- package/hooks/features/focus/gridFocusState.d.ts +2 -0
- package/hooks/features/focus/gridFocusStateSelector.d.ts +2 -0
- package/hooks/features/focus/gridFocusStateSelector.js +6 -0
- package/hooks/features/focus/useGridFocus.js +55 -9
- package/hooks/features/headerFiltering/gridHeaderFilteringSelectors.d.ts +4 -0
- package/hooks/features/headerFiltering/gridHeaderFilteringSelectors.js +5 -0
- package/hooks/features/headerFiltering/index.d.ts +1 -0
- package/hooks/features/headerFiltering/index.js +1 -0
- package/hooks/features/headerFiltering/useGridHeaderFiltering.d.ts +6 -0
- package/hooks/features/headerFiltering/useGridHeaderFiltering.js +91 -0
- package/hooks/features/index.d.ts +1 -0
- package/hooks/features/index.js +2 -1
- package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.d.ts +1 -1
- package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +113 -4
- package/hooks/features/preferencesPanel/gridPreferencePanelState.d.ts +2 -0
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.js +4 -2
- package/hooks/features/rows/useGridRows.js +16 -1
- package/hooks/features/rows/useGridRowsMeta.js +11 -12
- package/index.js +1 -1
- package/internals/index.d.ts +6 -1
- package/internals/index.js +4 -0
- package/internals/utils/index.d.ts +1 -0
- package/internals/utils/index.js +2 -1
- package/internals/utils/useProps.d.ts +8 -0
- package/internals/utils/useProps.js +33 -0
- package/legacy/DataGrid/DataGrid.js +10 -3
- package/legacy/DataGrid/useDataGridProps.js +8 -8
- package/legacy/colDef/gridNumericOperators.js +0 -6
- package/legacy/components/GridColumnHeaders.js +4 -9
- package/legacy/components/cell/GridActionsCell.js +3 -3
- package/legacy/components/cell/GridEditInputCell.js +4 -1
- package/legacy/components/cell/GridEditSingleSelectCell.js +5 -5
- package/legacy/components/columnHeaders/ColumnHeaderMenuIcon.js +3 -3
- package/legacy/components/columnHeaders/GridColumnHeaderFilterIconButton.js +13 -4
- package/legacy/components/containers/GridRoot.js +1 -3
- package/legacy/components/index.js +1 -2
- package/legacy/components/panel/GridPreferencesPanel.js +3 -1
- package/legacy/components/panel/filterPanel/GridFilterInputBoolean.js +79 -35
- package/legacy/components/panel/filterPanel/GridFilterInputDate.js +26 -5
- package/legacy/components/panel/filterPanel/GridFilterInputSingleSelect.js +55 -31
- package/legacy/components/panel/filterPanel/GridFilterInputValue.js +28 -5
- package/legacy/components/panel/filterPanel/GridFilterPanel.js +1 -1
- package/legacy/components/panel/filterPanel/index.js +2 -1
- package/legacy/components/toolbar/GridToolbarColumnsButton.js +11 -5
- package/legacy/components/toolbar/GridToolbarDensitySelector.js +2 -2
- package/legacy/components/toolbar/GridToolbarExportContainer.js +7 -7
- package/legacy/components/toolbar/GridToolbarFilterButton.js +11 -4
- package/legacy/constants/localeTextConstants.js +26 -0
- package/legacy/hooks/core/strategyProcessing/useGridStrategyProcessing.js +2 -1
- package/legacy/hooks/features/columnHeaders/useGridColumnHeaders.js +5 -5
- package/legacy/hooks/features/dimensions/useGridDimensions.js +2 -2
- package/legacy/hooks/features/editing/useGridEditing.js +0 -3
- package/legacy/hooks/features/filter/gridFilterSelector.js +4 -4
- package/legacy/hooks/features/filter/gridFilterState.js +6 -0
- package/legacy/hooks/features/filter/useGridFilter.js +29 -9
- package/legacy/hooks/features/focus/gridFocusStateSelector.js +10 -0
- package/legacy/hooks/features/focus/useGridFocus.js +58 -9
- package/legacy/hooks/features/headerFiltering/gridHeaderFilteringSelectors.js +11 -0
- package/legacy/hooks/features/headerFiltering/index.js +1 -0
- package/legacy/hooks/features/headerFiltering/useGridHeaderFiltering.js +93 -0
- package/legacy/hooks/features/index.js +2 -1
- package/legacy/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +113 -4
- package/legacy/hooks/features/preferencesPanel/useGridPreferencesPanel.js +4 -2
- package/legacy/hooks/features/rows/useGridRows.js +16 -1
- package/legacy/hooks/features/rows/useGridRowsMeta.js +12 -20
- package/legacy/index.js +1 -1
- package/legacy/internals/index.js +4 -0
- package/legacy/internals/utils/index.js +2 -1
- package/legacy/internals/utils/useProps.js +33 -0
- package/legacy/locales/arSD.js +28 -0
- package/legacy/locales/beBY.js +28 -0
- package/legacy/locales/bgBG.js +28 -0
- package/legacy/locales/csCZ.js +36 -8
- package/legacy/locales/daDK.js +28 -0
- package/legacy/locales/deDE.js +28 -0
- package/legacy/locales/elGR.js +27 -0
- package/legacy/locales/esES.js +28 -0
- package/legacy/locales/faIR.js +28 -0
- package/legacy/locales/fiFI.js +28 -0
- package/legacy/locales/frFR.js +26 -0
- package/legacy/locales/heIL.js +30 -2
- package/legacy/locales/huHU.js +28 -0
- package/legacy/locales/itIT.js +28 -0
- package/legacy/locales/jaJP.js +28 -0
- package/legacy/locales/koKR.js +28 -0
- package/legacy/locales/nbNO.js +28 -0
- package/legacy/locales/nlNL.js +26 -0
- package/legacy/locales/plPL.js +28 -0
- package/legacy/locales/ptBR.js +28 -0
- package/legacy/locales/roRO.js +28 -0
- package/legacy/locales/ruRU.js +28 -0
- package/legacy/locales/skSK.js +28 -0
- package/legacy/locales/svSE.js +28 -0
- package/legacy/locales/trTR.js +28 -0
- package/legacy/locales/ukUA.js +28 -0
- package/legacy/locales/urPK.js +28 -0
- package/legacy/locales/viVN.js +27 -0
- package/legacy/locales/zhCN.js +28 -0
- package/legacy/locales/zhTW.js +28 -0
- package/legacy/material/index.js +2 -0
- package/legacy/models/api/gridHeaderFilteringApi.js +1 -0
- package/legacy/models/gridFilterItem.js +1 -1
- package/legacy/models/gridHeaderFilteringModel.js +1 -0
- package/legacy/models/index.js +0 -1
- package/locales/arSD.js +28 -0
- package/locales/beBY.js +28 -0
- package/locales/bgBG.js +28 -0
- package/locales/csCZ.js +36 -8
- package/locales/daDK.js +28 -0
- package/locales/deDE.js +28 -0
- package/locales/elGR.js +27 -0
- package/locales/esES.js +28 -0
- package/locales/faIR.js +28 -0
- package/locales/fiFI.js +28 -0
- package/locales/frFR.js +26 -0
- package/locales/heIL.js +30 -2
- package/locales/huHU.js +28 -0
- package/locales/itIT.js +28 -0
- package/locales/jaJP.js +28 -0
- package/locales/koKR.js +28 -0
- package/locales/nbNO.js +28 -0
- package/locales/nlNL.js +26 -0
- package/locales/plPL.js +28 -0
- package/locales/ptBR.js +28 -0
- package/locales/roRO.js +28 -0
- package/locales/ruRU.js +28 -0
- package/locales/skSK.js +28 -0
- package/locales/svSE.js +28 -0
- package/locales/trTR.js +28 -0
- package/locales/ukUA.js +28 -0
- package/locales/urPK.js +28 -0
- package/locales/viVN.js +27 -0
- package/locales/zhCN.js +28 -0
- package/locales/zhTW.js +28 -0
- package/material/components/MUISelectOption.d.ts +2 -2
- package/material/index.d.ts +3 -66
- package/material/index.js +2 -0
- package/models/api/gridApiCommon.d.ts +3 -2
- package/models/api/gridCoreApi.d.ts +4 -0
- package/models/api/gridFilterApi.d.ts +3 -1
- package/models/api/gridFocusApi.d.ts +6 -0
- package/models/api/gridHeaderFilteringApi.d.ts +30 -0
- package/models/api/gridHeaderFilteringApi.js +1 -0
- package/models/api/gridLocaleTextApi.d.ts +25 -0
- package/models/api/gridPreferencesPanelApi.d.ts +3 -1
- package/models/events/gridEventLookup.d.ts +27 -1
- package/models/gridFilterItem.d.ts +1 -1
- package/models/gridFilterItem.js +1 -1
- package/models/gridFilterOperator.d.ts +5 -1
- package/models/gridHeaderFilteringModel.d.ts +5 -0
- package/models/gridHeaderFilteringModel.js +1 -0
- package/models/gridSlotsComponent.d.ts +16 -4
- package/models/gridStateCommunity.d.ts +4 -0
- package/models/index.d.ts +1 -1
- package/models/index.js +0 -1
- package/models/props/DataGridProps.d.ts +5 -0
- package/modern/DataGrid/DataGrid.js +10 -3
- package/modern/DataGrid/useDataGridProps.js +5 -12
- package/modern/colDef/gridNumericOperators.js +0 -6
- package/modern/components/GridColumnHeaders.js +4 -9
- package/modern/components/cell/GridActionsCell.js +3 -3
- package/modern/components/cell/GridEditInputCell.js +4 -1
- package/modern/components/cell/GridEditSingleSelectCell.js +5 -5
- package/modern/components/columnHeaders/ColumnHeaderMenuIcon.js +3 -3
- package/modern/components/columnHeaders/GridColumnHeaderFilterIconButton.js +13 -4
- package/modern/components/containers/GridRoot.js +1 -3
- package/modern/components/index.js +1 -2
- package/modern/components/panel/GridPreferencesPanel.js +3 -1
- package/modern/components/panel/filterPanel/GridFilterInputBoolean.js +80 -36
- package/modern/components/panel/filterPanel/GridFilterInputDate.js +27 -6
- package/modern/components/panel/filterPanel/GridFilterInputSingleSelect.js +56 -32
- package/modern/components/panel/filterPanel/GridFilterInputValue.js +29 -6
- package/modern/components/panel/filterPanel/GridFilterPanel.js +1 -1
- package/modern/components/panel/filterPanel/index.js +2 -1
- package/modern/components/toolbar/GridToolbarColumnsButton.js +11 -6
- package/modern/components/toolbar/GridToolbarDensitySelector.js +2 -2
- package/modern/components/toolbar/GridToolbarExportContainer.js +7 -7
- package/modern/components/toolbar/GridToolbarFilterButton.js +11 -4
- package/modern/constants/localeTextConstants.js +26 -0
- package/modern/hooks/core/strategyProcessing/useGridStrategyProcessing.js +2 -1
- package/modern/hooks/features/columnHeaders/useGridColumnHeaders.js +4 -2
- package/modern/hooks/features/dimensions/useGridDimensions.js +2 -2
- package/modern/hooks/features/editing/useGridEditing.js +0 -3
- package/modern/hooks/features/filter/gridFilterSelector.js +2 -2
- package/modern/hooks/features/filter/gridFilterState.js +6 -0
- package/modern/hooks/features/filter/useGridFilter.js +29 -9
- package/modern/hooks/features/focus/gridFocusStateSelector.js +6 -0
- package/modern/hooks/features/focus/useGridFocus.js +55 -9
- package/modern/hooks/features/headerFiltering/gridHeaderFilteringSelectors.js +5 -0
- package/modern/hooks/features/headerFiltering/index.js +1 -0
- package/modern/hooks/features/headerFiltering/useGridHeaderFiltering.js +90 -0
- package/modern/hooks/features/index.js +2 -1
- package/modern/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +113 -4
- package/modern/hooks/features/preferencesPanel/useGridPreferencesPanel.js +4 -2
- package/modern/hooks/features/rows/useGridRows.js +16 -1
- package/modern/hooks/features/rows/useGridRowsMeta.js +11 -12
- package/modern/index.js +1 -1
- package/modern/internals/index.js +4 -0
- package/modern/internals/utils/index.js +2 -1
- package/modern/internals/utils/useProps.js +32 -0
- package/modern/locales/arSD.js +28 -0
- package/modern/locales/beBY.js +28 -0
- package/modern/locales/bgBG.js +28 -0
- package/modern/locales/csCZ.js +36 -8
- package/modern/locales/daDK.js +28 -0
- package/modern/locales/deDE.js +28 -0
- package/modern/locales/elGR.js +27 -0
- package/modern/locales/esES.js +28 -0
- package/modern/locales/faIR.js +28 -0
- package/modern/locales/fiFI.js +28 -0
- package/modern/locales/frFR.js +26 -0
- package/modern/locales/heIL.js +30 -2
- package/modern/locales/huHU.js +28 -0
- package/modern/locales/itIT.js +28 -0
- package/modern/locales/jaJP.js +28 -0
- package/modern/locales/koKR.js +28 -0
- package/modern/locales/nbNO.js +28 -0
- package/modern/locales/nlNL.js +26 -0
- package/modern/locales/plPL.js +28 -0
- package/modern/locales/ptBR.js +28 -0
- package/modern/locales/roRO.js +28 -0
- package/modern/locales/ruRU.js +28 -0
- package/modern/locales/skSK.js +28 -0
- package/modern/locales/svSE.js +28 -0
- package/modern/locales/trTR.js +28 -0
- package/modern/locales/ukUA.js +28 -0
- package/modern/locales/urPK.js +28 -0
- package/modern/locales/viVN.js +27 -0
- package/modern/locales/zhCN.js +28 -0
- package/modern/locales/zhTW.js +28 -0
- package/modern/material/index.js +2 -0
- package/modern/models/api/gridHeaderFilteringApi.js +1 -0
- package/modern/models/gridFilterItem.js +1 -1
- package/modern/models/gridHeaderFilteringModel.js +1 -0
- package/modern/models/index.js +0 -1
- package/node/DataGrid/DataGrid.js +10 -3
- package/node/DataGrid/useDataGridProps.js +4 -11
- package/node/colDef/gridNumericOperators.js +0 -6
- package/node/components/GridColumnHeaders.js +3 -8
- package/node/components/cell/GridActionsCell.js +3 -3
- package/node/components/cell/GridEditInputCell.js +4 -1
- package/node/components/cell/GridEditSingleSelectCell.js +5 -5
- package/node/components/columnHeaders/ColumnHeaderMenuIcon.js +3 -3
- package/node/components/columnHeaders/GridColumnHeaderFilterIconButton.js +12 -3
- package/node/components/containers/GridRoot.js +1 -3
- package/node/components/index.js +0 -11
- package/node/components/panel/GridPreferencesPanel.js +3 -1
- package/node/components/panel/filterPanel/GridFilterInputBoolean.js +78 -35
- package/node/components/panel/filterPanel/GridFilterInputDate.js +27 -6
- package/node/components/panel/filterPanel/GridFilterInputSingleSelect.js +56 -32
- package/node/components/panel/filterPanel/GridFilterInputValue.js +29 -6
- package/node/components/panel/filterPanel/GridFilterPanel.js +2 -1
- package/node/components/panel/filterPanel/index.js +26 -8
- package/node/components/toolbar/GridToolbarColumnsButton.js +11 -6
- package/node/components/toolbar/GridToolbarDensitySelector.js +2 -2
- package/node/components/toolbar/GridToolbarExportContainer.js +7 -7
- package/node/components/toolbar/GridToolbarFilterButton.js +10 -3
- package/node/constants/localeTextConstants.js +26 -0
- package/node/hooks/core/strategyProcessing/useGridStrategyProcessing.js +2 -1
- package/node/hooks/features/columnHeaders/useGridColumnHeaders.js +4 -2
- package/node/hooks/features/dimensions/useGridDimensions.js +2 -2
- package/node/hooks/features/editing/useGridEditing.js +0 -3
- package/node/hooks/features/filter/gridFilterSelector.js +2 -2
- package/node/hooks/features/filter/gridFilterState.js +6 -0
- package/node/hooks/features/filter/useGridFilter.js +30 -10
- package/node/hooks/features/focus/gridFocusStateSelector.js +9 -1
- package/node/hooks/features/focus/useGridFocus.js +55 -9
- package/node/hooks/features/headerFiltering/gridHeaderFilteringSelectors.js +15 -0
- package/node/hooks/features/headerFiltering/index.js +16 -0
- package/node/hooks/features/headerFiltering/useGridHeaderFiltering.js +101 -0
- package/node/hooks/features/index.js +11 -0
- package/node/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +113 -4
- package/node/hooks/features/preferencesPanel/useGridPreferencesPanel.js +4 -2
- package/node/hooks/features/rows/useGridRows.js +16 -1
- package/node/hooks/features/rows/useGridRowsMeta.js +11 -12
- package/node/index.js +1 -1
- package/node/internals/index.js +46 -0
- package/node/internals/utils/index.js +11 -0
- package/node/internals/utils/useProps.js +41 -0
- package/node/locales/arSD.js +28 -0
- package/node/locales/beBY.js +28 -0
- package/node/locales/bgBG.js +28 -0
- package/node/locales/csCZ.js +36 -8
- package/node/locales/daDK.js +28 -0
- package/node/locales/deDE.js +28 -0
- package/node/locales/elGR.js +27 -0
- package/node/locales/esES.js +28 -0
- package/node/locales/faIR.js +28 -0
- package/node/locales/fiFI.js +28 -0
- package/node/locales/frFR.js +26 -0
- package/node/locales/heIL.js +30 -2
- package/node/locales/huHU.js +28 -0
- package/node/locales/itIT.js +28 -0
- package/node/locales/jaJP.js +28 -0
- package/node/locales/koKR.js +28 -0
- package/node/locales/nbNO.js +28 -0
- package/node/locales/nlNL.js +26 -0
- package/node/locales/plPL.js +28 -0
- package/node/locales/ptBR.js +28 -0
- package/node/locales/roRO.js +28 -0
- package/node/locales/ruRU.js +28 -0
- package/node/locales/skSK.js +28 -0
- package/node/locales/svSE.js +28 -0
- package/node/locales/trTR.js +28 -0
- package/node/locales/ukUA.js +28 -0
- package/node/locales/urPK.js +28 -0
- package/node/locales/viVN.js +27 -0
- package/node/locales/zhCN.js +28 -0
- package/node/locales/zhTW.js +28 -0
- package/node/material/index.js +2 -0
- package/node/models/api/gridHeaderFilteringApi.js +5 -0
- package/node/models/gridFilterItem.js +1 -1
- package/node/models/gridHeaderFilteringModel.js +5 -0
- package/node/models/index.js +0 -11
- package/package.json +4 -4
- package/components/GridScrollArea.d.ts +0 -10
- package/components/GridScrollArea.js +0 -117
- package/legacy/components/GridScrollArea.js +0 -119
- package/legacy/lib/createDetectElementResize/index.js +0 -145
- package/lib/createDetectElementResize/index.d.ts +0 -18
- package/lib/createDetectElementResize/index.js +0 -145
- package/lib/createDetectElementResize/types.d.ts +0 -9
- package/modern/components/GridScrollArea.js +0 -117
- package/modern/lib/createDetectElementResize/index.js +0 -145
- package/node/components/GridScrollArea.js +0 -126
- package/node/lib/createDetectElementResize/index.js +0 -151
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,138 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## 6.6.0
|
|
7
|
+
|
|
8
|
+
_Jun 1, 2023_
|
|
9
|
+
|
|
10
|
+
We'd like to offer a big thanks to the 15 contributors who made this release possible. Here are some highlights ✨:
|
|
11
|
+
|
|
12
|
+
- 🚀 New date time picking UI on [`DesktopDateTimePicker`](https://mui.com/x/react-date-pickers/date-time-picker/)
|
|
13
|
+
|
|
14
|
+
<img src="https://user-images.githubusercontent.com/4941090/242533399-2b106390-8158-4aba-9ca4-b621c6310977.gif" width="628" />
|
|
15
|
+
|
|
16
|
+
- 🚀 Performance improvements
|
|
17
|
+
- 🐞 Bugfixes
|
|
18
|
+
- 📚 Documentation improvements
|
|
19
|
+
- 🌍 Improve Dutch (nl-NL) and French (fr-FR) locales on the data grid
|
|
20
|
+
- 🌍 Add Vietnamese (vi-VN) locale on the pickers
|
|
21
|
+
|
|
22
|
+
### `@mui/x-data-grid@v6.6.0` / `@mui/x-data-grid-pro@v6.6.0` / `@mui/x-data-grid-premium@v6.6.0`
|
|
23
|
+
|
|
24
|
+
#### Changes
|
|
25
|
+
|
|
26
|
+
- [DataGrid] Support data attributes (#8845) @romgrk
|
|
27
|
+
- [DataGrid] Avoid allocations in `hydrateRowsMeta` (#9121) @romgrk
|
|
28
|
+
- [DataGrid] Fix filter input select accessibility (#9018) @Jul13nT
|
|
29
|
+
- [DataGrid] Fix accessibility issues in panels and toolbar buttons (#8862) @romgrk
|
|
30
|
+
- [DataGrid] Fix `onCellEditStop` not invoked (#8857) @romgrk
|
|
31
|
+
- [DataGridPro] Fix auto-scroll when reordering columns (#8856) @m4theushw
|
|
32
|
+
- [DataGridPro] Fix row ID type casting in detail panels lookup (#8976) @minchaej
|
|
33
|
+
- [DataGridPro] Emit `columnWidthChange` event on `touchEnd` of column resize (#8669) @MBilalShafi
|
|
34
|
+
- [DataGridPro] Do not apply filters on `rowExpansionChange` (#8671) @cherniavskii
|
|
35
|
+
- [DataGridPro] Prevent click event on sorting after a resize (#9117) @romgrk
|
|
36
|
+
- [DataGridPremium] Improve Excel export interface (#9128) @TiagoPortfolio
|
|
37
|
+
- [l10n] Improve Dutch (nl-NL) locale (#9043) @thedutchruben
|
|
38
|
+
- [l10n] Improve French (fr-FR) locale (#9109) @Jul13nT
|
|
39
|
+
|
|
40
|
+
### `@mui/x-date-pickers@v6.6.0` / `@mui/x-date-pickers-pro@v6.6.0`
|
|
41
|
+
|
|
42
|
+
#### Changes
|
|
43
|
+
|
|
44
|
+
- [fields] Allow to explicitly define the reference value and improve its default value (#9019) @flaviendelangle
|
|
45
|
+
- [l10n] Add Vietnamese (vi-VN) locale (#9099) @nhannt201
|
|
46
|
+
- [pickers] Add `DigitalClock` to `DesktopDateTimePicker` (#8946) @LukasTy
|
|
47
|
+
- [pickers] Add support for timezones on the adapters (#9068) @flaviendelangle
|
|
48
|
+
- [pickers] Fix `MonthCalendar` and `YearCalendar` disabled validation (#9149) @LukasTy
|
|
49
|
+
- [pickers] Fix bug when fields have a unique section (#9110) @alexfauquette
|
|
50
|
+
- [pickers] Fix focus jumping on Safari (#9072) @LukasTy
|
|
51
|
+
- [pickers] Use the locale start of the week in `getWeekArray` (#9176) @flaviendelangle
|
|
52
|
+
|
|
53
|
+
### Docs
|
|
54
|
+
|
|
55
|
+
- [docs] Add single input range picker demo (#9159) @LukasTy
|
|
56
|
+
- [docs] Align `DateCalendar` demo views with labels (#9152) @LukasTy
|
|
57
|
+
- [docs] Clarify the peer dependency with React (#9067) @oliviertassinari
|
|
58
|
+
- [docs] Fix Norwegian locale typo (#9168) @LukasTy
|
|
59
|
+
- [docs] Fix column menu item demo (#9071) @MBilalShafi
|
|
60
|
+
- [docs] Improve localization table progress bars (#9033) @noraleonte
|
|
61
|
+
- [docs] Smooth performance animation (#8986) @oliviertassinari
|
|
62
|
+
- [docs] Use responsive time and date time pickers and the views sections (#9127) @flaviendelangle
|
|
63
|
+
- [docs] Reduce layout shift in grid demo (#9132) @oliviertassinari
|
|
64
|
+
- [docs] Fix tree data children lazy-loading demo (#8840) @yaredtsy
|
|
65
|
+
- [docs] Improve filtering docs discoverability (#9074) @MBilalShafi
|
|
66
|
+
|
|
67
|
+
### Core
|
|
68
|
+
|
|
69
|
+
- [core] Allow string literals as keys in `localesText` (#9045) @MBilalShafi
|
|
70
|
+
- [core] Fix `randomInt` producing values exceeding `max` value (#9086) @cherniavskii
|
|
71
|
+
- [core] Fix flaky test on `dateWithTimezone` adapter test (#9129) @flaviendelangle
|
|
72
|
+
- [core] Lock `@types/node` on v18 (#9107) @LukasTy
|
|
73
|
+
- [core] Remove `cross-fetch` dependency (#9108) @LukasTy
|
|
74
|
+
- [core] Remove `createDetectElementResize()` replaced with `ResizeObserver` (#9015) @oliviertassinari
|
|
75
|
+
- [core] Upgrade monorepo (#9027) @m4theushw
|
|
76
|
+
- [core] Upgrade monorepo (#9106) @LukasTy
|
|
77
|
+
- [charts] Fix proptypes (#9125) @LukasTy
|
|
78
|
+
- [charts] Generate the charts proptypes (#9010) @alexfauquette
|
|
79
|
+
- [charts] Manage series stacking (#8888) @alexfauquette
|
|
80
|
+
- [license] List side effects in the license package (#9092) @cherniavskii
|
|
81
|
+
|
|
82
|
+
## v6.5.0
|
|
83
|
+
|
|
84
|
+
_May 19, 2023_
|
|
85
|
+
|
|
86
|
+
We'd like to offer a big thanks to the 10 contributors who made this release possible. Here are some highlights ✨:
|
|
87
|
+
|
|
88
|
+
- 💫 Introduce filtering on column headers for `DataGridPro` and `DataGridPremium`:
|
|
89
|
+
|
|
90
|
+
https://github.com/mui/mui-x/assets/12609561/c4c2bfec-59cf-4cab-932d-dc1983081de9
|
|
91
|
+
|
|
92
|
+
See [the documentation](https://mui.com/x/react-data-grid/filtering/#header-filters) for more information
|
|
93
|
+
|
|
94
|
+
- 🌍 Improve Hebrew (he-IL) and Czech (cs-CZ) locales
|
|
95
|
+
- 📝 Support for editing on pinned rows
|
|
96
|
+
- 🚀 Performance improvements
|
|
97
|
+
- 🐞 Bugfixes
|
|
98
|
+
- 📚 Documentation improvements
|
|
99
|
+
|
|
100
|
+
### `@mui/x-data-grid@6.5.0` / `@mui/x-data-grid-pro@6.5.0` / `@mui/x-data-grid-premium@6.5.0`
|
|
101
|
+
|
|
102
|
+
#### Changes
|
|
103
|
+
|
|
104
|
+
- [DataGrid] Fix grid size calculation when `.MuiDataGrid-main` has border (#8882) @cherniavskii
|
|
105
|
+
- [DataGridPro] Filtering on Column Header (#7760) @MBilalShafi
|
|
106
|
+
- [DataGridPro] Improve `treeData` and `rowGrouping` performance (#8990) @MBilalShafi
|
|
107
|
+
- [DataGridPro] Support pinned rows editing (#8921) @cherniavskii
|
|
108
|
+
- [l10n] Improve Hebrew (he-IL) locale (#8943) @Itzik-Tech
|
|
109
|
+
- [l10n] Improve Czech (cs-CZ) locale (#8829) @harastaivan
|
|
110
|
+
- [l10n] Improve Czech (cs-CZ) locale (#8956) @davidzemancz
|
|
111
|
+
|
|
112
|
+
### `@mui/x-date-pickers@6.5.0` / `@mui/x-date-pickers-pro@6.5.0`
|
|
113
|
+
|
|
114
|
+
#### Changes
|
|
115
|
+
|
|
116
|
+
- [fields] Select the first section instead of last when clicking right of content (#9005) @noraleonte
|
|
117
|
+
- [fields] Refactor prop drilling in fields (#8660) @flaviendelangle
|
|
118
|
+
- [pickers] Allow to render the months before `currentMonth` instead of the one after (#8592) @flaviendelangle
|
|
119
|
+
- [pickers] Fix view management when `openTo` or `views` is modified (#8997) @alexfauquette
|
|
120
|
+
- [l10n] Improve Czech (cs-CZ) locale (#8829) @harastaivan
|
|
121
|
+
|
|
122
|
+
### Docs
|
|
123
|
+
|
|
124
|
+
- [docs] Clarify what Controlled / Uncontrolled means (#8926) @flaviendelangle
|
|
125
|
+
- [docs] Fix docs using wrong service worker (#9030) @cherniavskii
|
|
126
|
+
- [docs] Remove prop-types from JS demos (#9008) @flaviendelangle
|
|
127
|
+
|
|
128
|
+
### Core
|
|
129
|
+
|
|
130
|
+
- [core] Add assertion about checkbox rerenders (#8974) @oliviertassinari
|
|
131
|
+
- [core] Allow selecting a section by type in field tests (#9009) @flaviendelangle
|
|
132
|
+
- [core] Fix `yarn.lock` (#8988) @flaviendelangle
|
|
133
|
+
- [core] Fix flacky adapter test (#8995) @flaviendelangle
|
|
134
|
+
- [charts] Clean the axis rendering (#8948) @alexfauquette
|
|
135
|
+
- [DataGrid] Memoize root props for better performance (#8942) @romgrk
|
|
136
|
+
- [test] Skip flaky unit tests in JSDOM (#8994) @cherniavskii
|
|
137
|
+
|
|
6
138
|
## v6.4.0
|
|
7
139
|
|
|
8
140
|
_May 12, 2023_
|
|
@@ -46,7 +178,7 @@ We'd like to offer a big thanks to the 12 contributors who made this release pos
|
|
|
46
178
|
|
|
47
179
|
### Docs
|
|
48
180
|
|
|
49
|
-
- [docs] Fix date pickers typo in the docs
|
|
181
|
+
- [docs] Fix date pickers typo in the docs (#8939) @richbustos
|
|
50
182
|
- [docs] Fix master detail demo (#8894) @m4theushw
|
|
51
183
|
- [docs] Fix typo in clipboard docs (#8971) @MBilalShafi
|
|
52
184
|
- [docs] Reduce list of dependencies in Codesandbox/Stackblitz demos (#8535) @cherniavskii
|
|
@@ -4384,7 +4516,7 @@ We'd like to offer a big thanks to the 15 contributors who made this release pos
|
|
|
4384
4516
|
|
|
4385
4517
|
- 👔 **Excel export**. You can find this new Premium feature at: https://mui.com/x/react-data-grid/export/#excel-export.
|
|
4386
4518
|
|
|
4387
|
-
- 🔎 **Quick filtering**. You can now add a quick filtering search bar to your grid. To do so, either pass `showQuickFilter` prop to the `<GridToolbar />` or use the `<GridToolbarQuickFilter />` component in your custom toolbar. More information about how to customize the filtering logic is in the [documentation](https://mui.com/x/react-data-grid/filtering
|
|
4519
|
+
- 🔎 **Quick filtering**. You can now add a quick filtering search bar to your grid. To do so, either pass `showQuickFilter` prop to the `<GridToolbar />` or use the `<GridToolbarQuickFilter />` component in your custom toolbar. More information about how to customize the filtering logic is in the [documentation](https://mui.com/x/react-data-grid/filtering/quick-filter/).
|
|
4388
4520
|
|
|
4389
4521
|
<img src="https://user-images.githubusercontent.com/13808724/167700105-5a5acc7c-5463-4871-8514-3d09e2f365ae.png" width="724">
|
|
4390
4522
|
|
package/DataGrid/DataGrid.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import PropTypes from 'prop-types';
|
|
3
4
|
import { chainPropTypes } from '@mui/utils';
|
|
@@ -14,15 +15,16 @@ const DataGridRaw = /*#__PURE__*/React.forwardRef(function DataGrid(inProps, ref
|
|
|
14
15
|
return /*#__PURE__*/_jsx(GridContextProvider, {
|
|
15
16
|
privateApiRef: privateApiRef,
|
|
16
17
|
props: props,
|
|
17
|
-
children: /*#__PURE__*/_jsxs(GridRoot, {
|
|
18
|
+
children: /*#__PURE__*/_jsxs(GridRoot, _extends({
|
|
18
19
|
className: props.className,
|
|
19
20
|
style: props.style,
|
|
20
21
|
sx: props.sx,
|
|
21
|
-
ref: ref
|
|
22
|
+
ref: ref
|
|
23
|
+
}, props.forwardedProps, {
|
|
22
24
|
children: [/*#__PURE__*/_jsx(GridHeader, {}), /*#__PURE__*/_jsx(GridBody, {
|
|
23
25
|
VirtualScrollerComponent: DataGridVirtualScroller
|
|
24
26
|
}), /*#__PURE__*/_jsx(GridFooterPlaceholder, {})]
|
|
25
|
-
})
|
|
27
|
+
}))
|
|
26
28
|
});
|
|
27
29
|
});
|
|
28
30
|
export const DataGrid = /*#__PURE__*/React.memo(DataGridRaw);
|
|
@@ -182,6 +184,11 @@ DataGridRaw.propTypes = {
|
|
|
182
184
|
quickFilterLogicOperator: PropTypes.oneOf(['and', 'or']),
|
|
183
185
|
quickFilterValues: PropTypes.array
|
|
184
186
|
}),
|
|
187
|
+
/**
|
|
188
|
+
* Forwarded props for the grid root element.
|
|
189
|
+
* @ignore - do not document.
|
|
190
|
+
*/
|
|
191
|
+
forwardedProps: PropTypes.object,
|
|
185
192
|
/**
|
|
186
193
|
* Function that applies CSS classes dynamically on cells.
|
|
187
194
|
* @param {GridCellParams} params With all properties from [[GridCellParams]].
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
|
-
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
-
const _excluded = ["components", "componentsProps"];
|
|
4
2
|
import * as React from 'react';
|
|
5
3
|
import { useThemeProps } from '@mui/material/styles';
|
|
6
4
|
import { GRID_DEFAULT_LOCALE_TEXT } from '../constants';
|
|
7
5
|
import { DATA_GRID_DEFAULT_SLOTS_COMPONENTS } from '../constants/defaultGridSlotsComponents';
|
|
8
6
|
import { GridEditModes } from '../models';
|
|
9
|
-
import { computeSlots, uncapitalizeObjectKeys } from '../internals/utils';
|
|
7
|
+
import { computeSlots, useProps, uncapitalizeObjectKeys } from '../internals/utils';
|
|
10
8
|
const DATA_GRID_FORCED_PROPS = {
|
|
11
9
|
disableMultipleColumnsFiltering: true,
|
|
12
10
|
disableMultipleColumnsSorting: true,
|
|
@@ -72,15 +70,10 @@ export const DATA_GRID_PROPS_DEFAULT_VALUES = {
|
|
|
72
70
|
};
|
|
73
71
|
const defaultSlots = uncapitalizeObjectKeys(DATA_GRID_DEFAULT_SLOTS_COMPONENTS);
|
|
74
72
|
export const useDataGridProps = inProps => {
|
|
75
|
-
const
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
{
|
|
80
|
-
components,
|
|
81
|
-
componentsProps
|
|
82
|
-
} = _useThemeProps,
|
|
83
|
-
themedProps = _objectWithoutPropertiesLoose(_useThemeProps, _excluded);
|
|
73
|
+
const [components, componentsProps, themedProps] = useProps(useThemeProps({
|
|
74
|
+
props: inProps,
|
|
75
|
+
name: 'MuiDataGrid'
|
|
76
|
+
}));
|
|
84
77
|
const localeText = React.useMemo(() => _extends({}, GRID_DEFAULT_LOCALE_TEXT, themedProps.localeText), [themedProps.localeText]);
|
|
85
78
|
const slots = React.useMemo(() => computeSlots({
|
|
86
79
|
defaultSlots,
|
package/README.md
CHANGED
|
@@ -21,8 +21,8 @@ This component has the following peer dependencies that you will need to install
|
|
|
21
21
|
"peerDependencies": {
|
|
22
22
|
"@mui/material": "^5.4.1",
|
|
23
23
|
"@mui/system": "^5.4.1",
|
|
24
|
-
"react": "^17.0.
|
|
25
|
-
"react-dom": "^17.0.
|
|
24
|
+
"react": "^17.0.0 || ^18.0.0",
|
|
25
|
+
"react-dom": "^17.0.0 || ^18.0.0"
|
|
26
26
|
},
|
|
27
27
|
```
|
|
28
28
|
|
|
@@ -17,7 +17,6 @@ export const getGridNumericQuickFilterFn = value => {
|
|
|
17
17
|
};
|
|
18
18
|
};
|
|
19
19
|
export const getGridNumericOperators = () => [{
|
|
20
|
-
label: '=',
|
|
21
20
|
value: '=',
|
|
22
21
|
getApplyFilterFn: filterItem => {
|
|
23
22
|
if (filterItem.value == null || Number.isNaN(filterItem.value)) {
|
|
@@ -34,7 +33,6 @@ export const getGridNumericOperators = () => [{
|
|
|
34
33
|
type: 'number'
|
|
35
34
|
}
|
|
36
35
|
}, {
|
|
37
|
-
label: '!=',
|
|
38
36
|
value: '!=',
|
|
39
37
|
getApplyFilterFn: filterItem => {
|
|
40
38
|
if (filterItem.value == null || Number.isNaN(filterItem.value)) {
|
|
@@ -51,7 +49,6 @@ export const getGridNumericOperators = () => [{
|
|
|
51
49
|
type: 'number'
|
|
52
50
|
}
|
|
53
51
|
}, {
|
|
54
|
-
label: '>',
|
|
55
52
|
value: '>',
|
|
56
53
|
getApplyFilterFn: filterItem => {
|
|
57
54
|
if (filterItem.value == null || Number.isNaN(filterItem.value)) {
|
|
@@ -71,7 +68,6 @@ export const getGridNumericOperators = () => [{
|
|
|
71
68
|
type: 'number'
|
|
72
69
|
}
|
|
73
70
|
}, {
|
|
74
|
-
label: '>=',
|
|
75
71
|
value: '>=',
|
|
76
72
|
getApplyFilterFn: filterItem => {
|
|
77
73
|
if (filterItem.value == null || Number.isNaN(filterItem.value)) {
|
|
@@ -91,7 +87,6 @@ export const getGridNumericOperators = () => [{
|
|
|
91
87
|
type: 'number'
|
|
92
88
|
}
|
|
93
89
|
}, {
|
|
94
|
-
label: '<',
|
|
95
90
|
value: '<',
|
|
96
91
|
getApplyFilterFn: filterItem => {
|
|
97
92
|
if (filterItem.value == null || Number.isNaN(filterItem.value)) {
|
|
@@ -111,7 +106,6 @@ export const getGridNumericOperators = () => [{
|
|
|
111
106
|
type: 'number'
|
|
112
107
|
}
|
|
113
108
|
}, {
|
|
114
|
-
label: '<=',
|
|
115
109
|
value: '<=',
|
|
116
110
|
getApplyFilterFn: filterItem => {
|
|
117
111
|
if (filterItem.value == null || Number.isNaN(filterItem.value)) {
|
|
@@ -4,11 +4,10 @@ const _excluded = ["innerRef", "className", "visibleColumns", "sortColumnLookup"
|
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import PropTypes from 'prop-types';
|
|
6
6
|
import { useGridColumnHeaders } from '../hooks/features/columnHeaders/useGridColumnHeaders';
|
|
7
|
-
import { GridScrollArea } from './GridScrollArea';
|
|
8
7
|
import { GridBaseColumnHeaders } from './columnHeaders/GridBaseColumnHeaders';
|
|
9
8
|
import { GridColumnHeadersInner } from './columnHeaders/GridColumnHeadersInner';
|
|
10
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
11
9
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
11
|
const GridColumnHeaders = /*#__PURE__*/React.forwardRef(function GridColumnsHeaders(props, ref) {
|
|
13
12
|
const {
|
|
14
13
|
innerRef,
|
|
@@ -51,18 +50,14 @@ const GridColumnHeaders = /*#__PURE__*/React.forwardRef(function GridColumnsHead
|
|
|
51
50
|
columnGroupsHeaderStructure,
|
|
52
51
|
hasOtherElementInTabSequence
|
|
53
52
|
});
|
|
54
|
-
return /*#__PURE__*/
|
|
53
|
+
return /*#__PURE__*/_jsx(GridBaseColumnHeaders, _extends({
|
|
55
54
|
ref: ref
|
|
56
55
|
}, getRootProps(other), {
|
|
57
|
-
children:
|
|
58
|
-
scrollDirection: "left"
|
|
59
|
-
}), /*#__PURE__*/_jsxs(GridColumnHeadersInner, _extends({
|
|
56
|
+
children: /*#__PURE__*/_jsxs(GridColumnHeadersInner, _extends({
|
|
60
57
|
isDragging: isDragging
|
|
61
58
|
}, getInnerProps(), {
|
|
62
59
|
children: [getColumnGroupHeaders(), getColumnHeaders()]
|
|
63
|
-
}))
|
|
64
|
-
scrollDirection: "right"
|
|
65
|
-
})]
|
|
60
|
+
}))
|
|
66
61
|
}));
|
|
67
62
|
});
|
|
68
63
|
process.env.NODE_ENV !== "production" ? GridColumnHeaders.propTypes = {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function GridHeader(): JSX.Element;
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export declare function GridHeader(): React.JSX.Element;
|
|
@@ -7,7 +7,7 @@ interface GridBodyProps {
|
|
|
7
7
|
disableVirtualization: boolean;
|
|
8
8
|
}>;
|
|
9
9
|
}
|
|
10
|
-
declare function GridBody(props: GridBodyProps): JSX.Element;
|
|
10
|
+
declare function GridBody(props: GridBodyProps): React.JSX.Element;
|
|
11
11
|
declare namespace GridBody {
|
|
12
12
|
var propTypes: any;
|
|
13
13
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function GridFooterPlaceholder(): JSX.Element | null;
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export declare function GridFooterPlaceholder(): React.JSX.Element | null;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function GridOverlays(): JSX.Element | null;
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export declare function GridOverlays(): React.JSX.Element | null;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
2
|
import { GridRenderCellParams } from '../../models/params/gridCellParams';
|
|
3
3
|
import { GridMenuProps } from '../menu/GridMenu';
|
|
4
4
|
interface GridActionsCellProps extends Omit<GridRenderCellParams, 'api'> {
|
|
5
5
|
api?: GridRenderCellParams['api'];
|
|
6
6
|
position?: GridMenuProps['position'];
|
|
7
7
|
}
|
|
8
|
-
declare function GridActionsCell(props: GridActionsCellProps): JSX.Element;
|
|
8
|
+
declare function GridActionsCell(props: GridActionsCellProps): React.JSX.Element;
|
|
9
9
|
declare namespace GridActionsCell {
|
|
10
10
|
var propTypes: any;
|
|
11
11
|
}
|
|
12
12
|
export { GridActionsCell };
|
|
13
|
-
export declare const renderActionsCell: (params: GridRenderCellParams) => JSX.Element;
|
|
13
|
+
export declare const renderActionsCell: (params: GridRenderCellParams) => React.JSX.Element;
|
|
@@ -152,9 +152,9 @@ function GridActionsCell(props) {
|
|
|
152
152
|
ref: buttonRef,
|
|
153
153
|
id: buttonId,
|
|
154
154
|
"aria-label": apiRef.current.getLocaleText('actionsCellMore'),
|
|
155
|
-
"aria-
|
|
156
|
-
"aria-expanded": open
|
|
157
|
-
"aria-
|
|
155
|
+
"aria-haspopup": "menu",
|
|
156
|
+
"aria-expanded": open,
|
|
157
|
+
"aria-controls": open ? menuId : undefined,
|
|
158
158
|
role: "menuitem",
|
|
159
159
|
size: "small",
|
|
160
160
|
onClick: showMenu,
|
|
@@ -4,7 +4,7 @@ import { GridRenderCellParams } from '../../models/params/gridCellParams';
|
|
|
4
4
|
import { GridColDef } from '../../models/colDef/gridColDef';
|
|
5
5
|
interface GridBooleanCellProps extends GridRenderCellParams, Omit<SvgIconProps, 'tabIndex' | 'id'> {
|
|
6
6
|
}
|
|
7
|
-
declare function GridBooleanCellRaw(props: GridBooleanCellProps): JSX.Element;
|
|
7
|
+
declare function GridBooleanCellRaw(props: GridBooleanCellProps): React.JSX.Element;
|
|
8
8
|
declare namespace GridBooleanCellRaw {
|
|
9
9
|
var propTypes: any;
|
|
10
10
|
}
|
|
@@ -9,9 +9,9 @@ export interface GridEditBooleanCellProps extends GridRenderEditCellParams, Omit
|
|
|
9
9
|
*/
|
|
10
10
|
onValueChange?: (event: React.ChangeEvent<HTMLInputElement>, newValue: boolean) => Promise<void> | void;
|
|
11
11
|
}
|
|
12
|
-
declare function GridEditBooleanCell(props: GridEditBooleanCellProps): JSX.Element;
|
|
12
|
+
declare function GridEditBooleanCell(props: GridEditBooleanCellProps): React.JSX.Element;
|
|
13
13
|
declare namespace GridEditBooleanCell {
|
|
14
14
|
var propTypes: any;
|
|
15
15
|
}
|
|
16
16
|
export { GridEditBooleanCell };
|
|
17
|
-
export declare const renderEditBooleanCell: (params: GridEditBooleanCellProps) => JSX.Element;
|
|
17
|
+
export declare const renderEditBooleanCell: (params: GridEditBooleanCellProps) => React.JSX.Element;
|
|
@@ -10,9 +10,9 @@ export interface GridEditDateCellProps extends GridRenderEditCellParams, Omit<In
|
|
|
10
10
|
*/
|
|
11
11
|
onValueChange?: (event: React.ChangeEvent<HTMLInputElement>, newValue: Date | null) => Promise<void> | void;
|
|
12
12
|
}
|
|
13
|
-
declare function GridEditDateCell(props: GridEditDateCellProps): JSX.Element;
|
|
13
|
+
declare function GridEditDateCell(props: GridEditDateCellProps): React.JSX.Element;
|
|
14
14
|
declare namespace GridEditDateCell {
|
|
15
15
|
var propTypes: any;
|
|
16
16
|
}
|
|
17
17
|
export { GridEditDateCell };
|
|
18
|
-
export declare const renderEditDateCell: (params: GridRenderEditCellParams) => JSX.Element;
|
|
18
|
+
export declare const renderEditDateCell: (params: GridRenderEditCellParams) => React.JSX.Element;
|
|
@@ -13,4 +13,4 @@ export interface GridEditInputCellProps extends GridRenderEditCellParams, Omit<I
|
|
|
13
13
|
}
|
|
14
14
|
declare const GridEditInputCell: React.ForwardRefExoticComponent<Omit<GridEditInputCellProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
15
15
|
export { GridEditInputCell };
|
|
16
|
-
export declare const renderEditInputCell: (params: GridEditInputCellProps) => JSX.Element;
|
|
16
|
+
export declare const renderEditInputCell: (params: GridEditInputCellProps) => React.JSX.Element;
|
|
@@ -88,7 +88,10 @@ const GridEditInputCell = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
88
88
|
type: colDef.type === 'number' ? colDef.type : 'text',
|
|
89
89
|
value: valueState != null ? valueState : '',
|
|
90
90
|
onChange: handleChange,
|
|
91
|
-
endAdornment: isProcessingProps ? /*#__PURE__*/_jsx(rootProps.slots.loadIcon, {
|
|
91
|
+
endAdornment: isProcessingProps ? /*#__PURE__*/_jsx(rootProps.slots.loadIcon, {
|
|
92
|
+
fontSize: "small",
|
|
93
|
+
color: "action"
|
|
94
|
+
}) : undefined
|
|
92
95
|
}, other));
|
|
93
96
|
});
|
|
94
97
|
process.env.NODE_ENV !== "production" ? GridEditInputCell.propTypes = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
2
|
import { SelectProps, SelectChangeEvent } from '@mui/material/Select';
|
|
3
3
|
import { GridRenderEditCellParams } from '../../models/params/gridCellParams';
|
|
4
4
|
import { GridSingleSelectColDef } from '../../models/colDef/gridColDef';
|
|
@@ -15,9 +15,9 @@ export interface GridEditSingleSelectCellProps extends GridRenderEditCellParams,
|
|
|
15
15
|
*/
|
|
16
16
|
initialOpen?: boolean;
|
|
17
17
|
}
|
|
18
|
-
declare function GridEditSingleSelectCell(props: GridEditSingleSelectCellProps): JSX.Element | null;
|
|
18
|
+
declare function GridEditSingleSelectCell(props: GridEditSingleSelectCellProps): React.JSX.Element | null;
|
|
19
19
|
declare namespace GridEditSingleSelectCell {
|
|
20
20
|
var propTypes: any;
|
|
21
21
|
}
|
|
22
22
|
export { GridEditSingleSelectCell };
|
|
23
|
-
export declare const renderEditSingleSelectCell: (params: GridEditSingleSelectCellProps) => JSX.Element;
|
|
23
|
+
export declare const renderEditSingleSelectCell: (params: GridEditSingleSelectCellProps) => React.JSX.Element;
|
|
@@ -5,6 +5,7 @@ const _excluded = ["id", "value", "formattedValue", "api", "field", "row", "rowN
|
|
|
5
5
|
import * as React from 'react';
|
|
6
6
|
import PropTypes from 'prop-types';
|
|
7
7
|
import { unstable_useEnhancedEffect as useEnhancedEffect } from '@mui/utils';
|
|
8
|
+
import { GridCellEditStopReasons } from '../../models/params/gridEditCellParams';
|
|
8
9
|
import { isEscapeKey } from '../../utils/keyboardUtils';
|
|
9
10
|
import { useGridRootProps } from '../../hooks/utils/useGridRootProps';
|
|
10
11
|
import { GridEditModes } from '../../models/gridEditRowModel';
|
|
@@ -90,11 +91,10 @@ function GridEditSingleSelectCell(props) {
|
|
|
90
91
|
return;
|
|
91
92
|
}
|
|
92
93
|
if (reason === 'backdropClick' || isEscapeKey(event.key)) {
|
|
93
|
-
apiRef.current.
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
});
|
|
94
|
+
const params = apiRef.current.getCellParams(id, field);
|
|
95
|
+
apiRef.current.publishEvent('cellEditStop', _extends({}, params, {
|
|
96
|
+
reason: isEscapeKey(event.key) ? GridCellEditStopReasons.escapeKeyDown : GridCellEditStopReasons.cellFocusOut
|
|
97
|
+
}));
|
|
98
98
|
}
|
|
99
99
|
};
|
|
100
100
|
const handleOpen = event => {
|
|
@@ -5,7 +5,7 @@ export interface GridSkeletonCellProps {
|
|
|
5
5
|
field: string;
|
|
6
6
|
align: string;
|
|
7
7
|
}
|
|
8
|
-
declare function GridSkeletonCell(props: React.HTMLAttributes<HTMLDivElement> & GridSkeletonCellProps): JSX.Element;
|
|
8
|
+
declare function GridSkeletonCell(props: React.HTMLAttributes<HTMLDivElement> & GridSkeletonCellProps): React.JSX.Element;
|
|
9
9
|
declare namespace GridSkeletonCell {
|
|
10
10
|
var propTypes: any;
|
|
11
11
|
}
|
|
@@ -7,4 +7,4 @@ export interface ColumnHeaderMenuIconProps {
|
|
|
7
7
|
open: boolean;
|
|
8
8
|
iconButtonRef: React.RefObject<HTMLButtonElement>;
|
|
9
9
|
}
|
|
10
|
-
export declare const ColumnHeaderMenuIcon: React.MemoExoticComponent<(props: ColumnHeaderMenuIconProps) => JSX.Element>;
|
|
10
|
+
export declare const ColumnHeaderMenuIcon: React.MemoExoticComponent<(props: ColumnHeaderMenuIconProps) => React.JSX.Element>;
|
|
@@ -49,9 +49,9 @@ export const ColumnHeaderMenuIcon = /*#__PURE__*/React.memo(props => {
|
|
|
49
49
|
"aria-label": apiRef.current.getLocaleText('columnMenuLabel'),
|
|
50
50
|
size: "small",
|
|
51
51
|
onClick: handleMenuIconClick,
|
|
52
|
-
"aria-
|
|
53
|
-
"aria-
|
|
54
|
-
"aria-controls": columnMenuId,
|
|
52
|
+
"aria-haspopup": "menu",
|
|
53
|
+
"aria-expanded": open,
|
|
54
|
+
"aria-controls": open ? columnMenuId : undefined,
|
|
55
55
|
id: columnMenuButtonId
|
|
56
56
|
}, (_rootProps$slotProps2 = rootProps.slotProps) == null ? void 0 : _rootProps$slotProps2.baseIconButton, {
|
|
57
57
|
children: /*#__PURE__*/_jsx(rootProps.slots.columnMenuIcon, {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
2
|
interface GridColumnGroupHeaderProps {
|
|
3
3
|
groupId: string | null;
|
|
4
4
|
width: number;
|
|
@@ -11,5 +11,5 @@ interface GridColumnGroupHeaderProps {
|
|
|
11
11
|
hasFocus?: boolean;
|
|
12
12
|
tabIndex: 0 | -1;
|
|
13
13
|
}
|
|
14
|
-
declare function GridColumnGroupHeader(props: GridColumnGroupHeaderProps): JSX.Element;
|
|
14
|
+
declare function GridColumnGroupHeader(props: GridColumnGroupHeaderProps): React.JSX.Element;
|
|
15
15
|
export { GridColumnGroupHeader };
|
|
@@ -5,7 +5,7 @@ export interface ColumnHeaderFilterIconButtonProps {
|
|
|
5
5
|
counter?: number;
|
|
6
6
|
onClick?: (params: GridColumnHeaderParams, event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
7
7
|
}
|
|
8
|
-
declare function GridColumnHeaderFilterIconButton(props: ColumnHeaderFilterIconButtonProps): JSX.Element | null;
|
|
8
|
+
declare function GridColumnHeaderFilterIconButton(props: ColumnHeaderFilterIconButtonProps): React.JSX.Element | null;
|
|
9
9
|
declare namespace GridColumnHeaderFilterIconButton {
|
|
10
10
|
var propTypes: any;
|
|
11
11
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import PropTypes from 'prop-types';
|
|
4
|
-
import { unstable_composeClasses as composeClasses } from '@mui/utils';
|
|
4
|
+
import { unstable_composeClasses as composeClasses, unstable_useId as useId } from '@mui/utils';
|
|
5
5
|
import Badge from '@mui/material/Badge';
|
|
6
|
+
import { useGridSelector } from '../../hooks';
|
|
6
7
|
import { gridPreferencePanelStateSelector } from '../../hooks/features/preferencesPanel/gridPreferencePanelSelector';
|
|
7
8
|
import { GridPreferencePanelsValue } from '../../hooks/features/preferencesPanel/gridPreferencePanelsValue';
|
|
8
9
|
import { useGridApiContext } from '../../hooks/utils/useGridApiContext';
|
|
@@ -33,6 +34,9 @@ function GridColumnHeaderFilterIconButton(props) {
|
|
|
33
34
|
classes: rootProps.classes
|
|
34
35
|
});
|
|
35
36
|
const classes = useUtilityClasses(ownerState);
|
|
37
|
+
const preferencePanel = useGridSelector(apiRef, gridPreferencePanelStateSelector);
|
|
38
|
+
const labelId = useId();
|
|
39
|
+
const panelId = useId();
|
|
36
40
|
const toggleFilter = React.useCallback(event => {
|
|
37
41
|
event.preventDefault();
|
|
38
42
|
event.stopPropagation();
|
|
@@ -43,21 +47,26 @@ function GridColumnHeaderFilterIconButton(props) {
|
|
|
43
47
|
if (open && openedPanelValue === GridPreferencePanelsValue.filters) {
|
|
44
48
|
apiRef.current.hideFilterPanel();
|
|
45
49
|
} else {
|
|
46
|
-
apiRef.current.showFilterPanel();
|
|
50
|
+
apiRef.current.showFilterPanel(undefined, panelId, labelId);
|
|
47
51
|
}
|
|
48
52
|
if (onClick) {
|
|
49
53
|
onClick(apiRef.current.getColumnHeaderParams(field), event);
|
|
50
54
|
}
|
|
51
|
-
}, [apiRef, field, onClick]);
|
|
55
|
+
}, [apiRef, field, onClick, panelId, labelId]);
|
|
52
56
|
if (!counter) {
|
|
53
57
|
return null;
|
|
54
58
|
}
|
|
59
|
+
const open = preferencePanel.open && preferencePanel.labelId === labelId;
|
|
55
60
|
const iconButton = /*#__PURE__*/_jsx(rootProps.slots.baseIconButton, _extends({
|
|
61
|
+
id: labelId,
|
|
56
62
|
onClick: toggleFilter,
|
|
57
63
|
color: "default",
|
|
58
64
|
"aria-label": apiRef.current.getLocaleText('columnHeaderFiltersLabel'),
|
|
59
65
|
size: "small",
|
|
60
|
-
tabIndex: -1
|
|
66
|
+
tabIndex: -1,
|
|
67
|
+
"aria-haspopup": "menu",
|
|
68
|
+
"aria-expanded": open,
|
|
69
|
+
"aria-controls": open ? panelId : undefined
|
|
61
70
|
}, (_rootProps$slotProps = rootProps.slotProps) == null ? void 0 : _rootProps$slotProps.baseIconButton, {
|
|
62
71
|
children: /*#__PURE__*/_jsx(rootProps.slots.columnFilteredIcon, {
|
|
63
72
|
className: classes.icon,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
2
|
import { GridStateColDef } from '../../models/colDef/gridColDef';
|
|
3
3
|
import { GridSortDirection } from '../../models/gridSortModel';
|
|
4
4
|
import { GridColumnHeaderSeparatorProps } from './GridColumnHeaderSeparator';
|
|
@@ -17,7 +17,7 @@ interface GridColumnHeaderItemProps {
|
|
|
17
17
|
disableReorder?: boolean;
|
|
18
18
|
separatorSide?: GridColumnHeaderSeparatorProps['side'];
|
|
19
19
|
}
|
|
20
|
-
declare function GridColumnHeaderItem(props: GridColumnHeaderItemProps): JSX.Element;
|
|
20
|
+
declare function GridColumnHeaderItem(props: GridColumnHeaderItemProps): React.JSX.Element;
|
|
21
21
|
declare namespace GridColumnHeaderItem {
|
|
22
22
|
var propTypes: any;
|
|
23
23
|
}
|
|
@@ -9,7 +9,7 @@ export interface GridColumnHeaderSeparatorProps extends React.HTMLAttributes<HTM
|
|
|
9
9
|
height: number;
|
|
10
10
|
side?: GridColumnHeaderSeparatorSides;
|
|
11
11
|
}
|
|
12
|
-
declare function GridColumnHeaderSeparatorRaw(props: GridColumnHeaderSeparatorProps): JSX.Element;
|
|
12
|
+
declare function GridColumnHeaderSeparatorRaw(props: GridColumnHeaderSeparatorProps): React.JSX.Element;
|
|
13
13
|
declare namespace GridColumnHeaderSeparatorRaw {
|
|
14
14
|
var propTypes: any;
|
|
15
15
|
}
|
|
@@ -5,7 +5,7 @@ export interface GridColumnHeaderSortIconProps {
|
|
|
5
5
|
index: number | undefined;
|
|
6
6
|
sortingOrder: GridSortDirection[];
|
|
7
7
|
}
|
|
8
|
-
declare function GridColumnHeaderSortIconRaw(props: GridColumnHeaderSortIconProps): JSX.Element | null;
|
|
8
|
+
declare function GridColumnHeaderSortIconRaw(props: GridColumnHeaderSortIconProps): React.JSX.Element | null;
|
|
9
9
|
declare namespace GridColumnHeaderSortIconRaw {
|
|
10
10
|
var propTypes: any;
|
|
11
11
|
}
|
|
@@ -4,7 +4,7 @@ export interface GridColumnHeaderTitleProps {
|
|
|
4
4
|
columnWidth: number;
|
|
5
5
|
description?: React.ReactNode;
|
|
6
6
|
}
|
|
7
|
-
declare function GridColumnHeaderTitle(props: GridColumnHeaderTitleProps): JSX.Element;
|
|
7
|
+
declare function GridColumnHeaderTitle(props: GridColumnHeaderTitleProps): React.JSX.Element;
|
|
8
8
|
declare namespace GridColumnHeaderTitle {
|
|
9
9
|
var propTypes: any;
|
|
10
10
|
}
|