@mui/x-data-grid 5.12.3 → 5.14.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 +147 -1
- package/DataGrid/DataGrid.js +4 -4
- package/DataGrid/useDataGridComponent.js +1 -1
- package/colDef/gridActionsColDef.js +2 -0
- package/colDef/gridBooleanColDef.js +3 -1
- package/colDef/gridCheckboxSelectionColDef.js +2 -0
- package/colDef/gridDateOperators.d.ts +1 -1
- package/colDef/gridDateOperators.js +4 -2
- package/colDef/gridNumericOperators.js +4 -2
- package/colDef/gridStringColDef.d.ts +3 -0
- package/colDef/gridStringColDef.js +6 -0
- package/colDef/gridStringOperators.d.ts +1 -1
- package/colDef/gridStringOperators.js +15 -8
- package/components/GridRow.js +1 -1
- package/components/base/GridOverlays.js +4 -1
- package/components/cell/GridActionsCellItem.d.ts +2 -2
- package/components/cell/GridBooleanCell.d.ts +5 -2
- package/components/cell/GridBooleanCell.js +93 -2
- package/components/cell/GridEditDateCell.js +5 -1
- package/components/cell/index.d.ts +1 -0
- package/components/cell/index.js +1 -0
- package/components/columnSelection/GridCellCheckboxRenderer.js +7 -1
- package/components/containers/GridRootStyles.js +10 -0
- package/components/panel/GridPanel.d.ts +1 -1
- package/components/panel/filterPanel/GridFilterForm.js +11 -4
- package/components/panel/filterPanel/GridFilterInputBoolean.js +1 -1
- package/components/panel/filterPanel/GridFilterInputDate.js +4 -2
- package/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.d.ts +3 -8
- package/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +30 -14
- package/components/panel/filterPanel/GridFilterInputMultipleValue.d.ts +3 -7
- package/components/panel/filterPanel/GridFilterInputMultipleValue.js +32 -14
- package/components/panel/filterPanel/GridFilterInputSingleSelect.js +8 -2
- package/components/panel/filterPanel/GridFilterInputValue.js +4 -2
- package/components/panel/filterPanel/GridFilterInputValueProps.d.ts +6 -3
- package/components/panel/filterPanel/filterPanelUtils.d.ts +1 -1
- package/components/toolbar/GridToolbarColumnsButton.d.ts +1 -1
- package/components/toolbar/GridToolbarDensitySelector.d.ts +1 -1
- package/components/toolbar/GridToolbarExport.js +20 -10
- package/components/toolbar/GridToolbarExportContainer.d.ts +1 -1
- package/components/toolbar/GridToolbarFilterButton.d.ts +1 -1
- package/constants/gridClasses.d.ts +25 -1
- package/constants/gridClasses.js +1 -1
- package/constants/localeTextConstants.js +8 -1
- package/hooks/core/pipeProcessing/gridPipeProcessingApi.d.ts +2 -1
- package/hooks/features/columns/useGridColumnSpanning.js +9 -7
- package/hooks/features/columns/useGridColumns.d.ts +1 -1
- package/hooks/features/columns/useGridColumns.js +13 -6
- package/hooks/features/dimensions/useGridDimensions.js +28 -15
- package/hooks/features/editRows/useGridCellEditing.new.js +7 -1
- package/hooks/features/editRows/useGridCellEditing.old.js +6 -0
- package/hooks/features/editRows/useGridRowEditing.new.js +7 -1
- package/hooks/features/editRows/useGridRowEditing.old.js +6 -0
- package/hooks/features/export/utils.d.ts +1 -1
- package/hooks/features/export/utils.js +9 -2
- package/hooks/features/filter/gridFilterUtils.js +6 -0
- package/hooks/features/filter/useGridFilter.d.ts +1 -1
- package/hooks/features/filter/useGridFilter.js +30 -5
- package/hooks/features/pagination/useGridPage.js +4 -3
- package/hooks/features/pagination/useGridPageSize.js +4 -3
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.d.ts +1 -1
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.js +12 -4
- package/hooks/features/rows/gridRowsUtils.d.ts +1 -1
- package/hooks/features/rows/useGridRows.js +1 -1
- package/hooks/features/rows/useGridRowsPreProcessors.js +1 -1
- package/hooks/features/selection/useGridSelection.js +24 -10
- package/hooks/features/sorting/gridSortingUtils.d.ts +1 -0
- package/hooks/features/sorting/gridSortingUtils.js +10 -11
- package/hooks/features/sorting/useGridSorting.d.ts +1 -1
- package/hooks/features/sorting/useGridSorting.js +34 -6
- package/hooks/features/statePersistence/gridStatePersistenceInterface.d.ts +12 -1
- package/hooks/features/statePersistence/index.d.ts +1 -1
- package/hooks/features/statePersistence/useGridStatePersistence.js +2 -2
- package/hooks/features/virtualization/useGridVirtualScroller.js +17 -7
- package/hooks/utils/useGridApiContext.js +1 -1
- package/hooks/utils/useGridApiEventHandler.d.ts +2 -2
- package/hooks/utils/useGridNativeEventListener.d.ts +1 -1
- package/hooks/utils/useGridNativeEventListener.js +1 -1
- package/hooks/utils/useGridRootProps.js +1 -1
- package/index.js +1 -1
- package/internals/index.d.ts +2 -2
- package/internals/index.js +2 -2
- package/legacy/DataGrid/DataGrid.js +4 -4
- package/legacy/DataGrid/useDataGridComponent.js +1 -1
- package/legacy/colDef/gridActionsColDef.js +2 -0
- package/legacy/colDef/gridBooleanColDef.js +3 -1
- package/legacy/colDef/gridCheckboxSelectionColDef.js +2 -0
- package/legacy/colDef/gridDateOperators.js +4 -2
- package/legacy/colDef/gridNumericOperators.js +4 -2
- package/legacy/colDef/gridStringColDef.js +6 -0
- package/legacy/colDef/gridStringOperators.js +17 -7
- package/legacy/components/GridRow.js +1 -1
- package/legacy/components/base/GridOverlays.js +4 -1
- package/legacy/components/cell/GridBooleanCell.js +93 -2
- package/legacy/components/cell/GridEditDateCell.js +5 -1
- package/legacy/components/cell/index.js +1 -0
- package/legacy/components/columnSelection/GridCellCheckboxRenderer.js +6 -1
- package/legacy/components/containers/GridRootStyles.js +3 -3
- package/legacy/components/panel/filterPanel/GridFilterForm.js +9 -4
- package/legacy/components/panel/filterPanel/GridFilterInputBoolean.js +1 -1
- package/legacy/components/panel/filterPanel/GridFilterInputDate.js +4 -2
- package/legacy/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +22 -7
- package/legacy/components/panel/filterPanel/GridFilterInputMultipleValue.js +24 -7
- package/legacy/components/panel/filterPanel/GridFilterInputSingleSelect.js +8 -2
- package/legacy/components/panel/filterPanel/GridFilterInputValue.js +4 -2
- package/legacy/components/toolbar/GridToolbarExport.js +20 -10
- package/legacy/constants/gridClasses.js +1 -1
- package/legacy/constants/localeTextConstants.js +8 -1
- package/legacy/hooks/features/columns/useGridColumnSpanning.js +9 -7
- package/legacy/hooks/features/columns/useGridColumns.js +13 -8
- package/legacy/hooks/features/dimensions/useGridDimensions.js +27 -15
- package/legacy/hooks/features/editRows/useGridCellEditing.new.js +7 -1
- package/legacy/hooks/features/editRows/useGridCellEditing.old.js +16 -8
- package/legacy/hooks/features/editRows/useGridRowEditing.new.js +7 -1
- package/legacy/hooks/features/editRows/useGridRowEditing.old.js +22 -14
- package/legacy/hooks/features/export/utils.js +9 -2
- package/legacy/hooks/features/filter/gridFilterUtils.js +6 -0
- package/legacy/hooks/features/filter/useGridFilter.js +30 -5
- package/legacy/hooks/features/pagination/useGridPage.js +4 -3
- package/legacy/hooks/features/pagination/useGridPageSize.js +4 -3
- package/legacy/hooks/features/preferencesPanel/useGridPreferencesPanel.js +12 -4
- package/legacy/hooks/features/rows/useGridRows.js +1 -1
- package/legacy/hooks/features/rows/useGridRowsPreProcessors.js +1 -1
- package/legacy/hooks/features/selection/useGridSelection.js +26 -12
- package/legacy/hooks/features/sorting/gridSortingUtils.js +11 -12
- package/legacy/hooks/features/sorting/useGridSorting.js +34 -6
- package/legacy/hooks/features/statePersistence/useGridStatePersistence.js +2 -1
- package/legacy/hooks/features/virtualization/useGridVirtualScroller.js +22 -12
- package/legacy/hooks/utils/useGridApiContext.js +1 -1
- package/legacy/hooks/utils/useGridNativeEventListener.js +1 -1
- package/legacy/hooks/utils/useGridRootProps.js +1 -1
- package/legacy/index.js +1 -1
- package/legacy/internals/index.js +2 -2
- package/legacy/locales/arSD.js +7 -0
- package/legacy/locales/bgBG.js +7 -0
- package/legacy/locales/csCZ.js +7 -0
- package/legacy/locales/daDK.js +7 -0
- package/legacy/locales/deDE.js +12 -5
- package/legacy/locales/elGR.js +7 -0
- package/legacy/locales/esES.js +7 -0
- package/legacy/locales/faIR.js +7 -0
- package/legacy/locales/fiFI.js +7 -0
- package/legacy/locales/frFR.js +17 -10
- package/legacy/locales/heIL.js +8 -1
- package/legacy/locales/huHU.js +7 -0
- package/legacy/locales/index.js +4 -1
- package/legacy/locales/itIT.js +7 -0
- package/legacy/locales/jaJP.js +8 -1
- package/legacy/locales/koKR.js +7 -0
- package/legacy/locales/nbNO.js +8 -1
- package/legacy/locales/nlNL.js +21 -14
- package/legacy/locales/plPL.js +7 -0
- package/legacy/locales/ptBR.js +17 -10
- package/legacy/locales/roRO.js +135 -0
- package/legacy/locales/ruRU.js +7 -0
- package/legacy/locales/skSK.js +22 -15
- package/legacy/locales/svSE.js +8 -1
- package/legacy/locales/trTR.js +7 -0
- package/legacy/locales/ukUA.js +7 -0
- package/legacy/locales/viVN.js +7 -0
- package/legacy/locales/zhCN.js +7 -0
- package/legacy/locales/zhTW.js +135 -0
- package/legacy/models/events/gridEvents.js +1 -0
- package/legacy/utils/keyboardUtils.js +4 -3
- package/locales/arSD.js +7 -0
- package/locales/bgBG.js +7 -0
- package/locales/csCZ.js +7 -0
- package/locales/daDK.js +7 -0
- package/locales/deDE.js +12 -5
- package/locales/elGR.js +7 -0
- package/locales/esES.js +7 -0
- package/locales/faIR.js +7 -0
- package/locales/fiFI.js +7 -0
- package/locales/frFR.js +17 -10
- package/locales/heIL.js +8 -1
- package/locales/huHU.js +7 -0
- package/locales/index.d.ts +3 -0
- package/locales/index.js +4 -1
- package/locales/itIT.js +7 -0
- package/locales/jaJP.js +8 -1
- package/locales/koKR.js +7 -0
- package/locales/nbNO.js +8 -1
- package/locales/nlNL.js +21 -14
- package/locales/plPL.js +7 -0
- package/locales/ptBR.js +17 -10
- package/locales/roRO.d.ts +2 -0
- package/locales/roRO.js +123 -0
- package/locales/ruRU.js +7 -0
- package/locales/skSK.js +22 -15
- package/locales/svSE.js +8 -1
- package/locales/trTR.js +7 -0
- package/locales/ukUA.js +7 -0
- package/locales/viVN.js +7 -0
- package/locales/zhCN.js +7 -0
- package/locales/zhTW.d.ts +2 -0
- package/locales/zhTW.js +123 -0
- package/models/api/gridColumnSpanning.d.ts +2 -0
- package/models/api/gridLocaleTextApi.d.ts +8 -2
- package/models/api/gridSelectionApi.d.ts +6 -0
- package/models/events/gridEvents.d.ts +1 -0
- package/models/events/gridEvents.js +1 -0
- package/models/gridFilterOperator.d.ts +6 -0
- package/models/gridRows.d.ts +10 -1
- package/models/params/gridCellParams.d.ts +4 -4
- package/modern/DataGrid/DataGrid.js +4 -4
- package/modern/DataGrid/useDataGridComponent.js +1 -1
- package/modern/colDef/gridActionsColDef.js +2 -0
- package/modern/colDef/gridBooleanColDef.js +3 -1
- package/modern/colDef/gridCheckboxSelectionColDef.js +2 -0
- package/modern/colDef/gridDateOperators.js +4 -2
- package/modern/colDef/gridNumericOperators.js +4 -2
- package/modern/colDef/gridStringColDef.js +6 -0
- package/modern/colDef/gridStringOperators.js +15 -8
- package/modern/components/GridRow.js +1 -1
- package/modern/components/base/GridOverlays.js +4 -1
- package/modern/components/cell/GridBooleanCell.js +93 -2
- package/modern/components/cell/GridEditDateCell.js +5 -1
- package/modern/components/cell/index.js +1 -0
- package/modern/components/columnSelection/GridCellCheckboxRenderer.js +7 -1
- package/modern/components/containers/GridRootStyles.js +10 -0
- package/modern/components/panel/filterPanel/GridFilterForm.js +11 -4
- package/modern/components/panel/filterPanel/GridFilterInputBoolean.js +1 -1
- package/modern/components/panel/filterPanel/GridFilterInputDate.js +4 -2
- package/modern/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +20 -8
- package/modern/components/panel/filterPanel/GridFilterInputMultipleValue.js +22 -8
- package/modern/components/panel/filterPanel/GridFilterInputSingleSelect.js +8 -2
- package/modern/components/panel/filterPanel/GridFilterInputValue.js +4 -2
- package/modern/components/toolbar/GridToolbarExport.js +20 -10
- package/modern/constants/gridClasses.js +1 -1
- package/modern/constants/localeTextConstants.js +8 -1
- package/modern/hooks/features/columns/useGridColumnSpanning.js +9 -7
- package/modern/hooks/features/columns/useGridColumns.js +10 -5
- package/modern/hooks/features/dimensions/useGridDimensions.js +28 -15
- package/modern/hooks/features/editRows/useGridCellEditing.new.js +7 -1
- package/modern/hooks/features/editRows/useGridCellEditing.old.js +6 -0
- package/modern/hooks/features/editRows/useGridRowEditing.new.js +7 -1
- package/modern/hooks/features/editRows/useGridRowEditing.old.js +6 -0
- package/modern/hooks/features/export/utils.js +5 -2
- package/modern/hooks/features/filter/gridFilterUtils.js +6 -0
- package/modern/hooks/features/filter/useGridFilter.js +25 -4
- package/modern/hooks/features/pagination/useGridPage.js +4 -3
- package/modern/hooks/features/pagination/useGridPageSize.js +4 -3
- package/modern/hooks/features/preferencesPanel/useGridPreferencesPanel.js +8 -4
- package/modern/hooks/features/rows/useGridRows.js +1 -1
- package/modern/hooks/features/rows/useGridRowsPreProcessors.js +1 -1
- package/modern/hooks/features/selection/useGridSelection.js +22 -10
- package/modern/hooks/features/sorting/gridSortingUtils.js +10 -11
- package/modern/hooks/features/sorting/useGridSorting.js +30 -6
- package/modern/hooks/features/statePersistence/useGridStatePersistence.js +2 -2
- package/modern/hooks/features/virtualization/useGridVirtualScroller.js +13 -7
- package/modern/hooks/utils/useGridApiContext.js +1 -1
- package/modern/hooks/utils/useGridNativeEventListener.js +1 -1
- package/modern/hooks/utils/useGridRootProps.js +1 -1
- package/modern/index.js +1 -1
- package/modern/internals/index.js +2 -2
- package/modern/locales/arSD.js +7 -0
- package/modern/locales/bgBG.js +7 -0
- package/modern/locales/csCZ.js +7 -0
- package/modern/locales/daDK.js +7 -0
- package/modern/locales/deDE.js +12 -5
- package/modern/locales/elGR.js +7 -0
- package/modern/locales/esES.js +7 -0
- package/modern/locales/faIR.js +7 -0
- package/modern/locales/fiFI.js +7 -0
- package/modern/locales/frFR.js +17 -10
- package/modern/locales/heIL.js +8 -1
- package/modern/locales/huHU.js +7 -0
- package/modern/locales/index.js +4 -1
- package/modern/locales/itIT.js +7 -0
- package/modern/locales/jaJP.js +8 -1
- package/modern/locales/koKR.js +7 -0
- package/modern/locales/nbNO.js +8 -1
- package/modern/locales/nlNL.js +21 -14
- package/modern/locales/plPL.js +7 -0
- package/modern/locales/ptBR.js +17 -10
- package/modern/locales/roRO.js +123 -0
- package/modern/locales/ruRU.js +7 -0
- package/modern/locales/skSK.js +22 -15
- package/modern/locales/svSE.js +8 -1
- package/modern/locales/trTR.js +7 -0
- package/modern/locales/ukUA.js +7 -0
- package/modern/locales/viVN.js +7 -0
- package/modern/locales/zhCN.js +7 -0
- package/modern/locales/zhTW.js +123 -0
- package/modern/models/events/gridEvents.js +1 -0
- package/modern/utils/keyboardUtils.js +4 -3
- package/node/DataGrid/DataGrid.js +4 -4
- package/node/DataGrid/useDataGridComponent.js +1 -1
- package/node/colDef/gridActionsColDef.js +2 -0
- package/node/colDef/gridBooleanColDef.js +3 -1
- package/node/colDef/gridCheckboxSelectionColDef.js +2 -0
- package/node/colDef/gridDateOperators.js +4 -2
- package/node/colDef/gridNumericOperators.js +4 -2
- package/node/colDef/gridStringColDef.js +5 -0
- package/node/colDef/gridStringOperators.js +15 -8
- package/node/components/GridRow.js +1 -1
- package/node/components/base/GridOverlays.js +4 -1
- package/node/components/cell/GridBooleanCell.js +93 -2
- package/node/components/cell/GridEditDateCell.js +7 -1
- package/node/components/cell/index.js +13 -0
- package/node/components/columnSelection/GridCellCheckboxRenderer.js +7 -1
- package/node/components/containers/GridRootStyles.js +10 -0
- package/node/components/panel/filterPanel/GridFilterForm.js +9 -4
- package/node/components/panel/filterPanel/GridFilterInputBoolean.js +1 -1
- package/node/components/panel/filterPanel/GridFilterInputDate.js +4 -2
- package/node/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.js +31 -15
- package/node/components/panel/filterPanel/GridFilterInputMultipleValue.js +33 -15
- package/node/components/panel/filterPanel/GridFilterInputSingleSelect.js +8 -2
- package/node/components/panel/filterPanel/GridFilterInputValue.js +4 -2
- package/node/components/toolbar/GridToolbarExport.js +16 -10
- package/node/constants/gridClasses.js +1 -1
- package/node/constants/localeTextConstants.js +8 -1
- package/node/hooks/features/columns/useGridColumnSpanning.js +9 -7
- package/node/hooks/features/columns/useGridColumns.js +13 -6
- package/node/hooks/features/dimensions/useGridDimensions.js +28 -15
- package/node/hooks/features/editRows/useGridCellEditing.new.js +7 -1
- package/node/hooks/features/editRows/useGridCellEditing.old.js +6 -0
- package/node/hooks/features/editRows/useGridRowEditing.new.js +7 -1
- package/node/hooks/features/editRows/useGridRowEditing.old.js +6 -0
- package/node/hooks/features/export/utils.js +10 -2
- package/node/hooks/features/filter/gridFilterUtils.js +7 -0
- package/node/hooks/features/filter/useGridFilter.js +30 -5
- package/node/hooks/features/pagination/useGridPage.js +4 -3
- package/node/hooks/features/pagination/useGridPageSize.js +4 -3
- package/node/hooks/features/preferencesPanel/useGridPreferencesPanel.js +12 -4
- package/node/hooks/features/rows/useGridRows.js +1 -1
- package/node/hooks/features/rows/useGridRowsPreProcessors.js +1 -1
- package/node/hooks/features/selection/useGridSelection.js +24 -10
- package/node/hooks/features/sorting/gridSortingUtils.js +10 -11
- package/node/hooks/features/sorting/useGridSorting.js +34 -6
- package/node/hooks/features/statePersistence/useGridStatePersistence.js +2 -2
- package/node/hooks/features/virtualization/useGridVirtualScroller.js +17 -7
- package/node/hooks/utils/useGridApiContext.js +1 -1
- package/node/hooks/utils/useGridNativeEventListener.js +1 -1
- package/node/hooks/utils/useGridRootProps.js +1 -1
- package/node/index.js +1 -1
- package/node/internals/index.js +18 -0
- package/node/locales/arSD.js +7 -0
- package/node/locales/bgBG.js +7 -0
- package/node/locales/csCZ.js +7 -0
- package/node/locales/daDK.js +7 -0
- package/node/locales/deDE.js +12 -5
- package/node/locales/elGR.js +7 -0
- package/node/locales/esES.js +7 -0
- package/node/locales/faIR.js +7 -0
- package/node/locales/fiFI.js +7 -0
- package/node/locales/frFR.js +17 -10
- package/node/locales/heIL.js +8 -1
- package/node/locales/huHU.js +7 -0
- package/node/locales/index.js +39 -0
- package/node/locales/itIT.js +7 -0
- package/node/locales/jaJP.js +8 -1
- package/node/locales/koKR.js +7 -0
- package/node/locales/nbNO.js +8 -1
- package/node/locales/nlNL.js +21 -14
- package/node/locales/plPL.js +7 -0
- package/node/locales/ptBR.js +17 -10
- package/node/locales/roRO.js +133 -0
- package/node/locales/ruRU.js +7 -0
- package/node/locales/skSK.js +22 -15
- package/node/locales/svSE.js +8 -1
- package/node/locales/trTR.js +7 -0
- package/node/locales/ukUA.js +7 -0
- package/node/locales/viVN.js +7 -0
- package/node/locales/zhCN.js +7 -0
- package/node/locales/zhTW.js +133 -0
- package/node/models/events/gridEvents.js +1 -0
- package/node/utils/keyboardUtils.js +4 -3
- package/package.json +3 -3
- package/utils/getGridLocalization.d.ts +1 -1
- package/utils/keyboardUtils.js +4 -3
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { ButtonProps } from '@mui/material/Button';
|
|
3
|
-
export declare const GridToolbarExportContainer: React.ForwardRefExoticComponent<Pick<ButtonProps<"button", {}>, "hidden" | "color" | "size" | "translate" | "disabled" | "form" | "slot" | "title" | "children" | "key" | "action" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "href" | "name" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "type" | "value" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "sx" | keyof import("@mui/material/OverridableComponent").CommonProps | "variant" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "
|
|
3
|
+
export declare const GridToolbarExportContainer: React.ForwardRefExoticComponent<Pick<ButtonProps<"button", {}>, "hidden" | "color" | "size" | "translate" | "disabled" | "form" | "slot" | "title" | "children" | "key" | "action" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "href" | "name" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "type" | "value" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "sx" | keyof import("@mui/material/OverridableComponent").CommonProps | "variant" | "onFocusVisible" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "disableElevation" | "fullWidth" | "endIcon" | "startIcon"> & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -10,5 +10,5 @@ export interface GridToolbarFilterButtonProps extends Omit<TooltipProps, 'title'
|
|
|
10
10
|
button?: ButtonProps;
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
|
-
declare const GridToolbarFilterButton: React.ForwardRefExoticComponent<Pick<GridToolbarFilterButtonProps, "hidden" | "color" | "style" | "open" | "translate" | "slot" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onClose" | "sx" | "classes" | "components" | "
|
|
13
|
+
declare const GridToolbarFilterButton: React.ForwardRefExoticComponent<Pick<GridToolbarFilterButtonProps, "hidden" | "color" | "style" | "open" | "translate" | "slot" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onClose" | "sx" | "classes" | "components" | "placement" | "arrow" | "componentsProps" | "TransitionComponent" | "TransitionProps" | "onOpen" | "describeChild" | "disableFocusListener" | "disableHoverListener" | "disableInteractive" | "disableTouchListener" | "enterDelay" | "enterNextDelay" | "enterTouchDelay" | "followCursor" | "leaveDelay" | "leaveTouchDelay" | "PopperComponent" | "PopperProps"> & React.RefAttributes<HTMLButtonElement>>;
|
|
14
14
|
export { GridToolbarFilterButton };
|
|
@@ -1,8 +1,28 @@
|
|
|
1
1
|
export interface GridClasses {
|
|
2
2
|
/**
|
|
3
|
-
* Styles applied to the root element of the cell with type="actions"
|
|
3
|
+
* Styles applied to the root element of the cell with type="actions".
|
|
4
4
|
*/
|
|
5
5
|
actionsCell: string;
|
|
6
|
+
/**
|
|
7
|
+
* Styles applied to the root element of the column header when aggregated.
|
|
8
|
+
*/
|
|
9
|
+
aggregationColumnHeader: string;
|
|
10
|
+
/**
|
|
11
|
+
* Styles applied to the root element of the header when aggregation if `headerAlign="left"`.
|
|
12
|
+
*/
|
|
13
|
+
'aggregationColumnHeader--alignLeft': string;
|
|
14
|
+
/**
|
|
15
|
+
* Styles applied to the root element of the header when aggregation if `headerAlign="center"`.
|
|
16
|
+
*/
|
|
17
|
+
'aggregationColumnHeader--alignCenter': string;
|
|
18
|
+
/**
|
|
19
|
+
* Styles applied to the root element of the header when aggregation if `headerAlign="right"`.
|
|
20
|
+
*/
|
|
21
|
+
'aggregationColumnHeader--alignRight': string;
|
|
22
|
+
/**
|
|
23
|
+
* Styles applied to the aggregation label in the column header when aggregated.
|
|
24
|
+
*/
|
|
25
|
+
aggregationColumnHeaderLabel: string;
|
|
6
26
|
/**
|
|
7
27
|
* Styles applied to the root element if `autoHeight={true}`.
|
|
8
28
|
*/
|
|
@@ -175,6 +195,10 @@ export interface GridClasses {
|
|
|
175
195
|
* Styles applied to the detail panel toggle cell element if expanded.
|
|
176
196
|
*/
|
|
177
197
|
'detailPanelToggleCell--expanded': string;
|
|
198
|
+
/**
|
|
199
|
+
* Styles applied to the root element of the cell inside a footer row.
|
|
200
|
+
*/
|
|
201
|
+
footerCell: string;
|
|
178
202
|
/**
|
|
179
203
|
* Styles applied to the panel element.
|
|
180
204
|
*/
|
package/constants/gridClasses.js
CHANGED
|
@@ -2,4 +2,4 @@ import { generateUtilityClasses, generateUtilityClass } from '@mui/material';
|
|
|
2
2
|
export function getDataGridUtilityClass(slot) {
|
|
3
3
|
return generateUtilityClass('MuiDataGrid', slot);
|
|
4
4
|
}
|
|
5
|
-
export const gridClasses = generateUtilityClasses('MuiDataGrid', ['actionsCell', 'autoHeight', 'booleanCell', 'cell--editable', 'cell--editing', 'cell--textCenter', 'cell--textLeft', 'cell--textRight', 'cell--withRenderer', 'cell', 'cellContent', 'cellCheckbox', 'checkboxInput', 'columnHeader--alignCenter', 'columnHeader--alignLeft', 'columnHeader--alignRight', 'columnHeader--dragging', 'columnHeader--moving', 'columnHeader--numeric', 'columnHeader--sortable', 'columnHeader--sorted', 'columnHeader--filtered', 'columnHeader', 'columnHeaderCheckbox', 'columnHeaderDraggableContainer', 'columnHeaderDropZone', 'columnHeaderTitle', 'columnHeaderTitleContainer', 'columnHeaderTitleContainerContent', 'columnHeaders', 'columnHeadersInner', 'columnHeadersInner--scrollable', 'columnSeparator--resizable', 'columnSeparator--resizing', 'columnSeparator--sideLeft', 'columnSeparator--sideRight', 'columnSeparator', 'columnsPanel', 'columnsPanelRow', 'detailPanel', 'detailPanels', 'detailPanelToggleCell', 'detailPanelToggleCell--expanded', 'panel', 'panelHeader', 'panelWrapper', 'panelContent', 'panelFooter', 'paper', 'editBooleanCell', 'editInputCell', 'filterForm', 'filterFormDeleteIcon', 'filterFormLinkOperatorInput', 'filterFormColumnInput', 'filterFormOperatorInput', 'filterFormValueInput', 'filterIcon', 'footerContainer', 'iconButtonContainer', 'iconSeparator', 'main', 'menu', 'menuIcon', 'menuIconButton', 'menuOpen', 'menuList', 'overlay', 'root', 'root--densityStandard', 'root--densityComfortable', 'root--densityCompact', 'row', 'row--editable', 'row--editing', 'row--lastVisible', 'row--dragging', 'row--dynamicHeight', 'rowReorderCellPlaceholder', 'rowCount', 'rowReorderCellContainer', 'rowReorderCell', 'rowReorderCell--draggable', 'scrollArea--left', 'scrollArea--right', 'scrollArea', 'selectedRowCount', 'sortIcon', 'toolbarContainer', 'toolbarFilterList', 'virtualScroller', 'virtualScrollerContent', 'virtualScrollerContent--overflowed', 'virtualScrollerRenderZone', 'pinnedColumns', 'pinnedColumns--left', 'pinnedColumns--right', 'pinnedColumnHeaders', 'pinnedColumnHeaders--left', 'pinnedColumnHeaders--right', 'withBorder', 'treeDataGroupingCell', 'treeDataGroupingCellToggle', 'groupingCriteriaCell', 'groupingCriteriaCellToggle']);
|
|
5
|
+
export const gridClasses = generateUtilityClasses('MuiDataGrid', ['actionsCell', 'aggregationColumnHeader', 'aggregationColumnHeader--alignLeft', 'aggregationColumnHeader--alignCenter', 'aggregationColumnHeader--alignRight', 'autoHeight', 'booleanCell', 'cell--editable', 'cell--editing', 'cell--textCenter', 'cell--textLeft', 'cell--textRight', 'cell--withRenderer', 'cell', 'cellContent', 'cellCheckbox', 'checkboxInput', 'columnHeader--alignCenter', 'columnHeader--alignLeft', 'columnHeader--alignRight', 'columnHeader--dragging', 'columnHeader--moving', 'columnHeader--numeric', 'columnHeader--sortable', 'columnHeader--sorted', 'columnHeader--filtered', 'columnHeader', 'columnHeaderCheckbox', 'columnHeaderDraggableContainer', 'columnHeaderDropZone', 'columnHeaderTitle', 'columnHeaderTitleContainer', 'columnHeaderTitleContainerContent', 'columnHeaders', 'columnHeadersInner', 'columnHeadersInner--scrollable', 'columnSeparator--resizable', 'columnSeparator--resizing', 'columnSeparator--sideLeft', 'columnSeparator--sideRight', 'columnSeparator', 'columnsPanel', 'columnsPanelRow', 'detailPanel', 'detailPanels', 'detailPanelToggleCell', 'detailPanelToggleCell--expanded', 'footerCell', 'panel', 'panelHeader', 'panelWrapper', 'panelContent', 'panelFooter', 'paper', 'editBooleanCell', 'editInputCell', 'filterForm', 'filterFormDeleteIcon', 'filterFormLinkOperatorInput', 'filterFormColumnInput', 'filterFormOperatorInput', 'filterFormValueInput', 'filterIcon', 'footerContainer', 'iconButtonContainer', 'iconSeparator', 'main', 'menu', 'menuIcon', 'menuIconButton', 'menuOpen', 'menuList', 'overlay', 'root', 'root--densityStandard', 'root--densityComfortable', 'root--densityCompact', 'row', 'row--editable', 'row--editing', 'row--lastVisible', 'row--dragging', 'row--dynamicHeight', 'rowReorderCellPlaceholder', 'rowCount', 'rowReorderCellContainer', 'rowReorderCell', 'rowReorderCell--draggable', 'scrollArea--left', 'scrollArea--right', 'scrollArea', 'selectedRowCount', 'sortIcon', 'toolbarContainer', 'toolbarFilterList', 'virtualScroller', 'virtualScrollerContent', 'virtualScrollerContent--overflowed', 'virtualScrollerRenderZone', 'pinnedColumns', 'pinnedColumns--left', 'pinnedColumns--right', 'pinnedColumnHeaders', 'pinnedColumnHeaders--left', 'pinnedColumnHeaders--right', 'withBorder', 'treeDataGroupingCell', 'treeDataGroupingCellToggle', 'groupingCriteriaCell', 'groupingCriteriaCellToggle']);
|
|
@@ -111,5 +111,12 @@ export const GRID_DEFAULT_LOCALE_TEXT = {
|
|
|
111
111
|
// Used core components translation keys
|
|
112
112
|
MuiTablePagination: {},
|
|
113
113
|
// Row reordering text
|
|
114
|
-
rowReorderingHeaderName: 'Row reordering'
|
|
114
|
+
rowReorderingHeaderName: 'Row reordering',
|
|
115
|
+
// Aggregation
|
|
116
|
+
aggregationMenuItemHeader: 'Aggregation',
|
|
117
|
+
aggregationFunctionLabelSum: 'sum',
|
|
118
|
+
aggregationFunctionLabelAvg: 'avg',
|
|
119
|
+
aggregationFunctionLabelMin: 'min',
|
|
120
|
+
aggregationFunctionLabelMax: 'max',
|
|
121
|
+
aggregationFunctionLabelSize: 'size'
|
|
115
122
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { GridCellIndexCoordinates, GridScrollParams, GridColDef } from '../../../models';
|
|
3
3
|
import { GridInitialStateCommunity } from '../../../models/gridStateCommunity';
|
|
4
|
-
import { GridRestoreStatePreProcessingContext, GridRestoreStatePreProcessingValue } from '../../features/statePersistence/gridStatePersistenceInterface';
|
|
4
|
+
import { GridExportStateParams, GridRestoreStatePreProcessingContext, GridRestoreStatePreProcessingValue } from '../../features/statePersistence/gridStatePersistenceInterface';
|
|
5
5
|
import { GridHydrateColumnsValue } from '../../features/columns/gridColumnsInterfaces';
|
|
6
6
|
import { GridRowEntry } from '../../../models/gridRows';
|
|
7
7
|
import { GridHydrateRowsValue } from '../../features/rows/gridRowsState';
|
|
@@ -14,6 +14,7 @@ export interface GridPipeProcessingLookup {
|
|
|
14
14
|
};
|
|
15
15
|
exportState: {
|
|
16
16
|
value: GridInitialStateCommunity;
|
|
17
|
+
context: GridExportStateParams;
|
|
17
18
|
};
|
|
18
19
|
hydrateColumns: {
|
|
19
20
|
value: GridHydrateColumnsValue;
|
|
@@ -28,11 +28,11 @@ export const useGridColumnSpanning = apiRef => {
|
|
|
28
28
|
columnIndex,
|
|
29
29
|
rowId,
|
|
30
30
|
minFirstColumnIndex,
|
|
31
|
-
maxLastColumnIndex
|
|
31
|
+
maxLastColumnIndex,
|
|
32
|
+
columns
|
|
32
33
|
} = params;
|
|
33
|
-
const
|
|
34
|
-
const
|
|
35
|
-
const column = visibleColumns[columnIndex];
|
|
34
|
+
const columnsLength = columns.length;
|
|
35
|
+
const column = columns[columnIndex];
|
|
36
36
|
const colSpan = typeof column.colSpan === 'function' ? column.colSpan(apiRef.current.getCellParams(rowId, column.field)) : column.colSpan;
|
|
37
37
|
|
|
38
38
|
if (!colSpan || colSpan === 1) {
|
|
@@ -54,7 +54,7 @@ export const useGridColumnSpanning = apiRef => {
|
|
|
54
54
|
const nextColumnIndex = columnIndex + j; // Cells should be spanned only within their column section (left-pinned, right-pinned and unpinned).
|
|
55
55
|
|
|
56
56
|
if (nextColumnIndex >= minFirstColumnIndex && nextColumnIndex < maxLastColumnIndex) {
|
|
57
|
-
const nextColumn =
|
|
57
|
+
const nextColumn = columns[nextColumnIndex];
|
|
58
58
|
width += nextColumn.computedWidth;
|
|
59
59
|
setCellColSpanInfo(rowId, columnIndex + j, {
|
|
60
60
|
spannedByColSpan: true,
|
|
@@ -80,14 +80,16 @@ export const useGridColumnSpanning = apiRef => {
|
|
|
80
80
|
const calculateColSpan = React.useCallback(({
|
|
81
81
|
rowId,
|
|
82
82
|
minFirstColumn,
|
|
83
|
-
maxLastColumn
|
|
83
|
+
maxLastColumn,
|
|
84
|
+
columns
|
|
84
85
|
}) => {
|
|
85
86
|
for (let i = minFirstColumn; i < maxLastColumn; i += 1) {
|
|
86
87
|
const cellProps = calculateCellColSpan({
|
|
87
88
|
columnIndex: i,
|
|
88
89
|
rowId,
|
|
89
90
|
minFirstColumnIndex: minFirstColumn,
|
|
90
|
-
maxLastColumnIndex: maxLastColumn
|
|
91
|
+
maxLastColumnIndex: maxLastColumn,
|
|
92
|
+
columns
|
|
91
93
|
});
|
|
92
94
|
|
|
93
95
|
if (cellProps.colSpan > 1) {
|
|
@@ -8,4 +8,4 @@ export declare const columnsStateInitializer: GridStateInitializer<Pick<DataGrid
|
|
|
8
8
|
* @requires useGridDimensions (method, event) - can be after
|
|
9
9
|
* TODO: Impossible priority - useGridParamsApi also needs to be after useGridColumns
|
|
10
10
|
*/
|
|
11
|
-
export declare function useGridColumns(apiRef: React.MutableRefObject<GridApiCommunity>, props: Pick<DataGridProcessedProps, 'columns' | 'onColumnVisibilityChange' | 'columnVisibilityModel' | 'onColumnVisibilityModelChange' | 'columnTypes' | 'components' | 'componentsProps'>): void;
|
|
11
|
+
export declare function useGridColumns(apiRef: React.MutableRefObject<GridApiCommunity>, props: Pick<DataGridProcessedProps, 'initialState' | 'columns' | 'onColumnVisibilityChange' | 'columnVisibilityModel' | 'onColumnVisibilityModelChange' | 'columnTypes' | 'components' | 'componentsProps'>): void;
|
|
@@ -36,7 +36,7 @@ export const columnsStateInitializer = (state, props, apiRef) => {
|
|
|
36
36
|
*/
|
|
37
37
|
|
|
38
38
|
export function useGridColumns(apiRef, props) {
|
|
39
|
-
var _props$componentsProp2;
|
|
39
|
+
var _props$initialState5, _props$componentsProp2;
|
|
40
40
|
|
|
41
41
|
const logger = useGridLogger(apiRef, 'useGridColumns');
|
|
42
42
|
const columnTypes = React.useMemo(() => computeColumnTypes(props.columnTypes), [props.columnTypes]);
|
|
@@ -192,14 +192,21 @@ export function useGridColumns(apiRef, props) {
|
|
|
192
192
|
* PRE-PROCESSING
|
|
193
193
|
*/
|
|
194
194
|
|
|
195
|
-
const stateExportPreProcessing = React.useCallback(prevState => {
|
|
195
|
+
const stateExportPreProcessing = React.useCallback((prevState, context) => {
|
|
196
196
|
const columnsStateToExport = {};
|
|
197
197
|
|
|
198
198
|
if (apiRef.current.unstable_caches.columns.isUsingColumnVisibilityModel) {
|
|
199
|
-
|
|
200
|
-
const hasHiddenColumns = Object.values(columnVisibilityModelToExport).some(value => value === false);
|
|
199
|
+
var _props$initialState$c2, _props$initialState4, _props$initialState4$;
|
|
201
200
|
|
|
202
|
-
|
|
201
|
+
const columnVisibilityModelToExport = gridColumnVisibilityModelSelector(apiRef);
|
|
202
|
+
const shouldExportColumnVisibilityModel = // Always export if the `exportOnlyDirtyModels` property is activated
|
|
203
|
+
!context.exportOnlyDirtyModels || // Always export if the model is controlled
|
|
204
|
+
props.columnVisibilityModel != null || // Always export if the model has been initialized
|
|
205
|
+
// TODO v6 Do a nullish check instead to export even if the initial model equals "{}"
|
|
206
|
+
Object.keys((_props$initialState$c2 = (_props$initialState4 = props.initialState) == null ? void 0 : (_props$initialState4$ = _props$initialState4.columns) == null ? void 0 : _props$initialState4$.columnVisibilityModel) != null ? _props$initialState$c2 : {}).length > 0 || // Always export if the model is not empty
|
|
207
|
+
Object.keys(columnVisibilityModelToExport).length > 0;
|
|
208
|
+
|
|
209
|
+
if (shouldExportColumnVisibilityModel) {
|
|
203
210
|
columnsStateToExport.columnVisibilityModel = columnVisibilityModelToExport;
|
|
204
211
|
}
|
|
205
212
|
}
|
|
@@ -230,7 +237,7 @@ export function useGridColumns(apiRef, props) {
|
|
|
230
237
|
return _extends({}, prevState, {
|
|
231
238
|
columns: columnsStateToExport
|
|
232
239
|
});
|
|
233
|
-
}, [apiRef]);
|
|
240
|
+
}, [apiRef, props.columnVisibilityModel, (_props$initialState5 = props.initialState) == null ? void 0 : _props$initialState5.columns]);
|
|
234
241
|
const stateRestorePreProcessing = React.useCallback((params, context) => {
|
|
235
242
|
var _context$stateToResto;
|
|
236
243
|
|
|
@@ -71,21 +71,34 @@ export function useGridDimensions(apiRef, props) {
|
|
|
71
71
|
rootElement.removeChild(scrollDiv);
|
|
72
72
|
}
|
|
73
73
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
74
|
+
let viewportOuterSize;
|
|
75
|
+
let hasScrollX;
|
|
76
|
+
let hasScrollY;
|
|
77
|
+
|
|
78
|
+
if (props.autoHeight) {
|
|
79
|
+
hasScrollY = false;
|
|
80
|
+
hasScrollX = Math.round(columnsTotalWidth) > rootDimensionsRef.current.width;
|
|
81
|
+
viewportOuterSize = {
|
|
82
|
+
width: rootDimensionsRef.current.width,
|
|
83
|
+
height: rowsMeta.currentPageTotalHeight + (hasScrollX ? scrollBarSize : 0)
|
|
84
|
+
};
|
|
85
|
+
} else {
|
|
86
|
+
viewportOuterSize = {
|
|
87
|
+
width: rootDimensionsRef.current.width,
|
|
88
|
+
height: rootDimensionsRef.current.height - headerHeight
|
|
89
|
+
};
|
|
90
|
+
const scrollInformation = hasScroll({
|
|
91
|
+
content: {
|
|
92
|
+
width: Math.round(columnsTotalWidth),
|
|
93
|
+
height: rowsMeta.currentPageTotalHeight
|
|
94
|
+
},
|
|
95
|
+
container: viewportOuterSize,
|
|
96
|
+
scrollBarSize
|
|
97
|
+
});
|
|
98
|
+
hasScrollY = scrollInformation.hasScrollY;
|
|
99
|
+
hasScrollX = scrollInformation.hasScrollX;
|
|
100
|
+
}
|
|
101
|
+
|
|
89
102
|
const viewportInnerSize = {
|
|
90
103
|
width: viewportOuterSize.width - (hasScrollY ? scrollBarSize : 0),
|
|
91
104
|
height: viewportOuterSize.height - (hasScrollX ? scrollBarSize : 0)
|
|
@@ -70,6 +70,12 @@ export const useGridCellEditing = (apiRef, props) => {
|
|
|
70
70
|
}, [apiRef]);
|
|
71
71
|
const handleCellKeyDown = React.useCallback((params, event) => {
|
|
72
72
|
if (params.cellMode === GridCellModes.Edit) {
|
|
73
|
+
// Wait until IME is settled for Asian languages like Japanese and Chinese
|
|
74
|
+
// TODO: `event.which` is depricated but this is a temporary workaround
|
|
75
|
+
if (event.which === 229) {
|
|
76
|
+
return;
|
|
77
|
+
}
|
|
78
|
+
|
|
73
79
|
let reason;
|
|
74
80
|
|
|
75
81
|
if (event.key === 'Escape') {
|
|
@@ -92,7 +98,7 @@ export const useGridCellEditing = (apiRef, props) => {
|
|
|
92
98
|
let reason;
|
|
93
99
|
|
|
94
100
|
if (isPrintableKey(event.key)) {
|
|
95
|
-
if (event.
|
|
101
|
+
if (event.ctrlKey && event.key !== 'v' || event.metaKey && event.key !== 'v' || event.altKey) {
|
|
96
102
|
return;
|
|
97
103
|
}
|
|
98
104
|
|
|
@@ -179,6 +179,12 @@ export const useCellEditing = (apiRef, props) => {
|
|
|
179
179
|
};
|
|
180
180
|
useGridApiMethod(apiRef, cellEditingApi, 'EditRowApi');
|
|
181
181
|
const handleCellKeyDown = React.useCallback(async (params, event) => {
|
|
182
|
+
// Wait until IME is settled for Asian languages like Japanese and Chinese
|
|
183
|
+
// TODO: `event.which` is depricated but this is a temporary workaround
|
|
184
|
+
if (event.which === 229) {
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
|
|
182
188
|
const {
|
|
183
189
|
id,
|
|
184
190
|
field,
|
|
@@ -110,6 +110,12 @@ export const useGridRowEditing = (apiRef, props) => {
|
|
|
110
110
|
}, []);
|
|
111
111
|
const handleCellKeyDown = React.useCallback((params, event) => {
|
|
112
112
|
if (params.cellMode === GridRowModes.Edit) {
|
|
113
|
+
// Wait until IME is settled for Asian languages like Japanese and Chinese
|
|
114
|
+
// TODO: `event.which` is depricated but this is a temporary workaround
|
|
115
|
+
if (event.which === 229) {
|
|
116
|
+
return;
|
|
117
|
+
}
|
|
118
|
+
|
|
113
119
|
let reason;
|
|
114
120
|
|
|
115
121
|
if (event.key === 'Escape') {
|
|
@@ -148,7 +154,7 @@ export const useGridRowEditing = (apiRef, props) => {
|
|
|
148
154
|
let reason;
|
|
149
155
|
|
|
150
156
|
if (isPrintableKey(event.key)) {
|
|
151
|
-
if (event.
|
|
157
|
+
if (event.ctrlKey && event.key !== 'v' || event.metaKey && event.key !== 'v' || event.altKey) {
|
|
152
158
|
return;
|
|
153
159
|
}
|
|
154
160
|
|
|
@@ -176,6 +176,12 @@ export const useGridRowEditing = (apiRef, props) => {
|
|
|
176
176
|
};
|
|
177
177
|
useGridApiMethod(apiRef, rowEditingApi, 'EditRowApi');
|
|
178
178
|
const handleCellKeyDown = React.useCallback(async (params, event) => {
|
|
179
|
+
// Wait until IME is settled for Asian languages like Japanese and Chinese
|
|
180
|
+
// TODO: `event.which` is depricated but this is a temporary workaround
|
|
181
|
+
if (event.which === 229) {
|
|
182
|
+
return;
|
|
183
|
+
}
|
|
184
|
+
|
|
179
185
|
const {
|
|
180
186
|
cellMode,
|
|
181
187
|
isEditable
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
2
|
import { GridApiCommunity } from '../../../models/api/gridApiCommunity';
|
|
3
3
|
import { GridExportOptions, GridCsvGetRowsToExportParams } from '../../../models/gridExport';
|
|
4
4
|
import { GridStateColDef } from '../../../models/colDef/gridColDef';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { gridColumnDefinitionsSelector, gridVisibleColumnDefinitionsSelector } from '../columns';
|
|
2
2
|
import { gridFilteredSortedRowIdsSelector } from '../filter';
|
|
3
|
+
import { gridRowTreeSelector } from '../rows/gridRowsSelector';
|
|
3
4
|
export const getColumnsToExport = ({
|
|
4
5
|
apiRef,
|
|
5
6
|
options
|
|
@@ -17,11 +18,17 @@ export const defaultGetRowsToExport = ({
|
|
|
17
18
|
apiRef
|
|
18
19
|
}) => {
|
|
19
20
|
const filteredSortedRowIds = gridFilteredSortedRowIdsSelector(apiRef);
|
|
21
|
+
const rowTree = gridRowTreeSelector(apiRef);
|
|
20
22
|
const selectedRows = apiRef.current.getSelectedRows();
|
|
23
|
+
const bodyRows = filteredSortedRowIds.filter(id => {
|
|
24
|
+
var _rowTree$id$position;
|
|
25
|
+
|
|
26
|
+
return ((_rowTree$id$position = rowTree[id].position) != null ? _rowTree$id$position : 'body') === 'body';
|
|
27
|
+
});
|
|
21
28
|
|
|
22
29
|
if (selectedRows.size > 0) {
|
|
23
|
-
return
|
|
30
|
+
return bodyRows.filter(id => selectedRows.has(id));
|
|
24
31
|
}
|
|
25
32
|
|
|
26
|
-
return
|
|
33
|
+
return bodyRows;
|
|
27
34
|
};
|
|
@@ -2,6 +2,7 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
2
2
|
import { GridLinkOperator } from '../../../models';
|
|
3
3
|
import { buildWarning } from '../../../utils/warning';
|
|
4
4
|
import { gridColumnFieldsSelector, gridColumnLookupSelector } from '../columns';
|
|
5
|
+
import { gridRowTreeSelector } from '../rows/gridRowsSelector';
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Adds default values to the optional fields of a filter items.
|
|
@@ -80,6 +81,7 @@ export const buildAggregatedFilterItemsApplier = (filterModel, apiRef) => {
|
|
|
80
81
|
items,
|
|
81
82
|
linkOperator = GridLinkOperator.And
|
|
82
83
|
} = filterModel;
|
|
84
|
+
const tree = gridRowTreeSelector(apiRef);
|
|
83
85
|
|
|
84
86
|
const getFilterCallbackFromItem = filterItem => {
|
|
85
87
|
if (!filterItem.columnField || !filterItem.operatorValue) {
|
|
@@ -143,6 +145,10 @@ export const buildAggregatedFilterItemsApplier = (filterModel, apiRef) => {
|
|
|
143
145
|
}
|
|
144
146
|
|
|
145
147
|
return (rowId, shouldApplyFilter) => {
|
|
148
|
+
if (tree[rowId].position === 'footer') {
|
|
149
|
+
return true;
|
|
150
|
+
}
|
|
151
|
+
|
|
146
152
|
const filteredAppliers = shouldApplyFilter ? appliers.filter(applier => shouldApplyFilter(applier.item.columnField)) : appliers; // Return `false` as soon as we have a failing filter
|
|
147
153
|
|
|
148
154
|
if (linkOperator === GridLinkOperator.And) {
|
|
@@ -8,4 +8,4 @@ export declare const filterStateInitializer: GridStateInitializer<Pick<DataGridP
|
|
|
8
8
|
* @requires useGridParamsApi (method)
|
|
9
9
|
* @requires useGridRows (event)
|
|
10
10
|
*/
|
|
11
|
-
export declare const useGridFilter: (apiRef: React.MutableRefObject<GridApiCommunity>, props: Pick<DataGridProcessedProps, 'filterModel' | 'onFilterModelChange' | 'filterMode' | 'disableMultipleColumnsFiltering' | 'components' | 'componentsProps'>) => void;
|
|
11
|
+
export declare const useGridFilter: (apiRef: React.MutableRefObject<GridApiCommunity>, props: Pick<DataGridProcessedProps, 'initialState' | 'filterModel' | 'onFilterModelChange' | 'filterMode' | 'disableMultipleColumnsFiltering' | 'components' | 'componentsProps'>) => void;
|
|
@@ -34,7 +34,7 @@ export const filterStateInitializer = (state, props, apiRef) => {
|
|
|
34
34
|
*/
|
|
35
35
|
|
|
36
36
|
export const useGridFilter = (apiRef, props) => {
|
|
37
|
-
var _props$componentsProp2;
|
|
37
|
+
var _props$initialState3, _props$initialState3$, _props$componentsProp2;
|
|
38
38
|
|
|
39
39
|
const logger = useGridLogger(apiRef, 'useGridFilter');
|
|
40
40
|
apiRef.current.unstable_registerControlState({
|
|
@@ -113,7 +113,25 @@ export const useGridFilter = (apiRef, props) => {
|
|
|
113
113
|
|
|
114
114
|
if (targetColumnField) {
|
|
115
115
|
const filterModel = gridFilterModelSelector(apiRef);
|
|
116
|
-
const filterItemsWithValue = filterModel.items.filter(item =>
|
|
116
|
+
const filterItemsWithValue = filterModel.items.filter(item => {
|
|
117
|
+
var _column$filterOperato;
|
|
118
|
+
|
|
119
|
+
if (item.value !== undefined) {
|
|
120
|
+
return true;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
const column = apiRef.current.getColumn(item.columnField);
|
|
124
|
+
const filterOperator = (_column$filterOperato = column.filterOperators) == null ? void 0 : _column$filterOperato.find(operator => operator.value === item.operatorValue);
|
|
125
|
+
const requiresFilterValue = typeof (filterOperator == null ? void 0 : filterOperator.requiresFilterValue) === 'undefined' ? true : filterOperator == null ? void 0 : filterOperator.requiresFilterValue; // Operators like `isEmpty` don't have and don't require `item.value`.
|
|
126
|
+
// So we don't want to remove them from the filter model if `item.value === undefined`.
|
|
127
|
+
// See https://github.com/mui/mui-x/issues/5402
|
|
128
|
+
|
|
129
|
+
if (requiresFilterValue) {
|
|
130
|
+
return false;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
return true;
|
|
134
|
+
});
|
|
117
135
|
let newFilterItems;
|
|
118
136
|
const filterItemOnTarget = filterItemsWithValue.find(item => item.columnField === targetColumnField);
|
|
119
137
|
|
|
@@ -192,10 +210,17 @@ export const useGridFilter = (apiRef, props) => {
|
|
|
192
210
|
* PRE-PROCESSING
|
|
193
211
|
*/
|
|
194
212
|
|
|
195
|
-
const stateExportPreProcessing = React.useCallback(prevState => {
|
|
213
|
+
const stateExportPreProcessing = React.useCallback((prevState, context) => {
|
|
214
|
+
var _props$initialState2, _props$initialState2$;
|
|
215
|
+
|
|
196
216
|
const filterModelToExport = gridFilterModelSelector(apiRef);
|
|
217
|
+
const shouldExportFilterModel = // Always export if the `exportOnlyDirtyModels` property is activated
|
|
218
|
+
!context.exportOnlyDirtyModels || // Always export if the model is controlled
|
|
219
|
+
props.filterModel != null || // Always export if the model has been initialized
|
|
220
|
+
((_props$initialState2 = props.initialState) == null ? void 0 : (_props$initialState2$ = _props$initialState2.filter) == null ? void 0 : _props$initialState2$.filterModel) != null || // Export if the model is not equal to the default value
|
|
221
|
+
!isDeepEqual(filterModelToExport, getDefaultGridFilterModel());
|
|
197
222
|
|
|
198
|
-
if (
|
|
223
|
+
if (!shouldExportFilterModel) {
|
|
199
224
|
return prevState;
|
|
200
225
|
}
|
|
201
226
|
|
|
@@ -204,7 +229,7 @@ export const useGridFilter = (apiRef, props) => {
|
|
|
204
229
|
filterModel: filterModelToExport
|
|
205
230
|
}
|
|
206
231
|
});
|
|
207
|
-
}, [apiRef]);
|
|
232
|
+
}, [apiRef, props.filterModel, (_props$initialState3 = props.initialState) == null ? void 0 : (_props$initialState3$ = _props$initialState3.filter) == null ? void 0 : _props$initialState3$.filterModel]);
|
|
208
233
|
const stateRestorePreProcessing = React.useCallback((params, context) => {
|
|
209
234
|
var _context$stateToResto;
|
|
210
235
|
|
|
@@ -63,13 +63,14 @@ export const useGridPage = (apiRef, props) => {
|
|
|
63
63
|
* PRE-PROCESSING
|
|
64
64
|
*/
|
|
65
65
|
|
|
66
|
-
const stateExportPreProcessing = React.useCallback(prevState => {
|
|
66
|
+
const stateExportPreProcessing = React.useCallback((prevState, context) => {
|
|
67
67
|
var _props$initialState, _props$initialState$p;
|
|
68
68
|
|
|
69
69
|
const pageToExport = gridPageSelector(apiRef);
|
|
70
|
-
const shouldExportPage = // Always export if the
|
|
70
|
+
const shouldExportPage = // Always export if the `exportOnlyDirtyModels` property is activated
|
|
71
|
+
!context.exportOnlyDirtyModels || // Always export if the page is controlled
|
|
71
72
|
props.page != null || // Always export if the page has been initialized
|
|
72
|
-
((_props$initialState = props.initialState) == null ? void 0 : (_props$initialState$p = _props$initialState.pagination) == null ? void 0 : _props$initialState$p.page) != null || // Export if the page
|
|
73
|
+
((_props$initialState = props.initialState) == null ? void 0 : (_props$initialState$p = _props$initialState.pagination) == null ? void 0 : _props$initialState$p.page) != null || // Export if the page is not equal to the default value
|
|
73
74
|
pageToExport !== 0;
|
|
74
75
|
|
|
75
76
|
if (!shouldExportPage) {
|
|
@@ -49,13 +49,14 @@ export const useGridPageSize = (apiRef, props) => {
|
|
|
49
49
|
* PRE-PROCESSING
|
|
50
50
|
*/
|
|
51
51
|
|
|
52
|
-
const stateExportPreProcessing = React.useCallback(prevState => {
|
|
52
|
+
const stateExportPreProcessing = React.useCallback((prevState, context) => {
|
|
53
53
|
var _props$initialState, _props$initialState$p;
|
|
54
54
|
|
|
55
55
|
const pageSizeToExport = gridPageSizeSelector(apiRef);
|
|
56
|
-
const shouldExportPageSize = // Always export if the
|
|
56
|
+
const shouldExportPageSize = // Always export if the `exportOnlyDirtyModels` property is activated
|
|
57
|
+
!context.exportOnlyDirtyModels || // Always export if the page size is controlled
|
|
57
58
|
props.pageSize != null || // Always export if the page size has been initialized
|
|
58
|
-
((_props$initialState = props.initialState) == null ? void 0 : (_props$initialState$p = _props$initialState.pagination) == null ? void 0 : _props$initialState$p.pageSize) != null || // Export if the page size
|
|
59
|
+
((_props$initialState = props.initialState) == null ? void 0 : (_props$initialState$p = _props$initialState.pagination) == null ? void 0 : _props$initialState$p.pageSize) != null || // Export if the page size is not equal to the default value
|
|
59
60
|
pageSizeToExport !== defaultPageSize(props.autoPageSize);
|
|
60
61
|
|
|
61
62
|
if (!shouldExportPageSize) {
|
|
@@ -6,4 +6,4 @@ export declare const preferencePanelStateInitializer: GridStateInitializer<Pick<
|
|
|
6
6
|
/**
|
|
7
7
|
* TODO: Add a single `setPreferencePanel` method to avoid multiple `setState`
|
|
8
8
|
*/
|
|
9
|
-
export declare const useGridPreferencesPanel: (apiRef: React.MutableRefObject<GridApiCommunity>) => void;
|
|
9
|
+
export declare const useGridPreferencesPanel: (apiRef: React.MutableRefObject<GridApiCommunity>, props: Pick<DataGridProcessedProps, 'initialState'>) => void;
|
|
@@ -17,7 +17,9 @@ export const preferencePanelStateInitializer = (state, props) => {
|
|
|
17
17
|
* TODO: Add a single `setPreferencePanel` method to avoid multiple `setState`
|
|
18
18
|
*/
|
|
19
19
|
|
|
20
|
-
export const useGridPreferencesPanel = apiRef => {
|
|
20
|
+
export const useGridPreferencesPanel = (apiRef, props) => {
|
|
21
|
+
var _props$initialState3;
|
|
22
|
+
|
|
21
23
|
const logger = useGridLogger(apiRef, 'useGridPreferencesPanel');
|
|
22
24
|
const hideTimeout = React.useRef();
|
|
23
25
|
const immediateTimeout = React.useRef();
|
|
@@ -74,17 +76,23 @@ export const useGridPreferencesPanel = apiRef => {
|
|
|
74
76
|
* PRE-PROCESSING
|
|
75
77
|
*/
|
|
76
78
|
|
|
77
|
-
const stateExportPreProcessing = React.useCallback(prevState => {
|
|
79
|
+
const stateExportPreProcessing = React.useCallback((prevState, context) => {
|
|
80
|
+
var _props$initialState2;
|
|
81
|
+
|
|
78
82
|
const preferencePanelToExport = gridPreferencePanelStateSelector(apiRef.current.state);
|
|
83
|
+
const shouldExportPreferencePanel = // Always export if the `exportOnlyDirtyModels` property is activated
|
|
84
|
+
!context.exportOnlyDirtyModels || // Always export if the panel was initialized
|
|
85
|
+
((_props$initialState2 = props.initialState) == null ? void 0 : _props$initialState2.preferencePanel) != null || // Always export if the panel is opened
|
|
86
|
+
preferencePanelToExport.open;
|
|
79
87
|
|
|
80
|
-
if (!
|
|
88
|
+
if (!shouldExportPreferencePanel) {
|
|
81
89
|
return prevState;
|
|
82
90
|
}
|
|
83
91
|
|
|
84
92
|
return _extends({}, prevState, {
|
|
85
93
|
preferencePanel: preferencePanelToExport
|
|
86
94
|
});
|
|
87
|
-
}, [apiRef]);
|
|
95
|
+
}, [apiRef, (_props$initialState3 = props.initialState) == null ? void 0 : _props$initialState3.preferencePanel]);
|
|
88
96
|
const stateRestorePreProcessing = React.useCallback((params, context) => {
|
|
89
97
|
const preferencePanel = context.stateToRestore.preferencePanel;
|
|
90
98
|
|
|
@@ -10,7 +10,7 @@ import { GridRowsInternalCache, GridRowsState } from './gridRowsState';
|
|
|
10
10
|
* @param {string} detailErrorMessage A custom error message to display for invalid IDs
|
|
11
11
|
*/
|
|
12
12
|
export declare function checkGridRowIdIsValid(id: GridRowId, row: GridRowModel | Partial<GridRowModel>, detailErrorMessage?: string): void;
|
|
13
|
-
export declare const getRowIdFromRowModel: (rowModel: GridRowModel, getRowId?: GridRowIdGetter
|
|
13
|
+
export declare const getRowIdFromRowModel: (rowModel: GridRowModel, getRowId?: GridRowIdGetter, detailErrorMessage?: string) => GridRowId;
|
|
14
14
|
export declare const createRowsInternalCache: ({ rows, getRowId, loading, }: Pick<DataGridProcessedProps, 'rows' | 'getRowId' | 'loading'>) => GridRowsInternalCache;
|
|
15
15
|
export declare const getRowsStateFromCache: ({ apiRef, previousTree, rowCountProp, loadingProp, }: {
|
|
16
16
|
apiRef: React.MutableRefObject<GridApiCommunity>;
|