@mui/x-data-grid 6.0.0-alpha.2 → 6.0.0-alpha.4
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 +493 -141
- package/DataGrid/DataGrid.js +14 -34
- package/DataGrid/useDataGridComponent.js +8 -14
- package/DataGrid/useDataGridProps.js +3 -3
- package/colDef/gridCheckboxSelectionColDef.js +1 -1
- package/colDef/gridNumericOperators.d.ts +1 -1
- package/colDef/gridSingleSelectOperators.d.ts +1 -1
- package/colDef/gridStringOperators.d.ts +1 -1
- package/components/GridFooter.js +1 -1
- package/components/GridRow.js +2 -2
- package/components/base/GridBody.js +2 -2
- package/components/cell/GridEditInputCell.js +3 -8
- package/components/cell/GridEditSingleSelectCell.js +6 -38
- package/components/columnHeaders/GridColumnGroupHeader.d.ts +2 -0
- package/components/columnHeaders/GridColumnGroupHeader.js +32 -5
- package/components/columnSelection/GridHeaderCheckbox.js +3 -3
- package/components/containers/GridRoot.js +4 -3
- package/components/panel/GridColumnsPanel.d.ts +2 -0
- package/components/panel/GridColumnsPanel.js +10 -4
- package/components/panel/filterPanel/GridFilterForm.d.ts +12 -0
- package/components/panel/filterPanel/GridFilterForm.js +29 -7
- package/components/panel/filterPanel/GridFilterPanel.d.ts +12 -0
- package/components/panel/filterPanel/GridFilterPanel.js +64 -19
- package/hooks/core/pipeProcessing/useGridRegisterPipeApplier.d.ts +1 -1
- package/hooks/core/pipeProcessing/useGridRegisterPipeProcessor.d.ts +1 -1
- package/hooks/core/strategyProcessing/useGridRegisterStrategyProcessor.d.ts +1 -1
- package/hooks/core/useGridInitialization.d.ts +1 -1
- package/hooks/core/useGridStateInitialization.d.ts +1 -1
- package/hooks/features/columnGrouping/gridColumnGroupsInterfaces.d.ts +10 -1
- package/hooks/features/columnGrouping/gridColumnGroupsSelector.d.ts +6 -0
- package/hooks/features/columnGrouping/gridColumnGroupsSelector.js +34 -1
- package/hooks/features/columnGrouping/gridColumnGroupsUtils.d.ts +15 -0
- package/hooks/features/columnGrouping/gridColumnGroupsUtils.js +89 -0
- package/hooks/features/columnGrouping/useGridColumnGrouping.d.ts +1 -15
- package/hooks/features/columnGrouping/useGridColumnGrouping.js +66 -66
- package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +1 -1
- package/hooks/features/columnHeaders/useGridColumnHeaders.js +60 -116
- package/hooks/features/density/densitySelector.d.ts +0 -2
- package/hooks/features/density/densitySelector.js +1 -3
- package/hooks/features/density/densityState.d.ts +0 -1
- package/hooks/features/density/useGridDensity.d.ts +1 -1
- package/hooks/features/density/useGridDensity.js +9 -45
- package/hooks/features/dimensions/useGridDimensions.js +3 -2
- package/hooks/features/{editRows/gridEditRowsSelector.d.ts → editing/gridEditingSelectors.d.ts} +0 -0
- package/hooks/features/{editRows/gridEditRowsSelector.js → editing/gridEditingSelectors.js} +0 -0
- package/hooks/features/editing/index.d.ts +1 -0
- package/hooks/features/editing/index.js +1 -0
- package/hooks/features/{editRows/useGridCellEditing.new.d.ts → editing/useGridCellEditing.d.ts} +0 -0
- package/hooks/features/{editRows/useGridCellEditing.new.js → editing/useGridCellEditing.js} +21 -6
- package/hooks/features/{editRows/useGridEditing.new.d.ts → editing/useGridEditing.d.ts} +0 -0
- package/hooks/features/{editRows/useGridEditing.new.js → editing/useGridEditing.js} +3 -3
- package/hooks/features/{editRows/useGridRowEditing.new.d.ts → editing/useGridRowEditing.d.ts} +0 -0
- package/hooks/features/{editRows/useGridRowEditing.new.js → editing/useGridRowEditing.js} +20 -6
- package/hooks/features/export/useGridPrintExport.js +2 -2
- package/hooks/features/focus/gridFocusState.d.ts +6 -0
- package/hooks/features/focus/gridFocusStateSelector.d.ts +2 -0
- package/hooks/features/focus/gridFocusStateSelector.js +6 -2
- package/hooks/features/focus/useGridFocus.js +69 -11
- package/hooks/features/index.d.ts +2 -2
- package/hooks/features/index.js +2 -2
- package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +135 -1
- package/hooks/features/{selection/gridSelectionSelector.d.ts → rowSelection/gridRowSelectionSelector.d.ts} +1 -1
- package/hooks/features/rowSelection/gridRowSelectionSelector.js +9 -0
- package/hooks/features/rowSelection/index.d.ts +1 -0
- package/hooks/features/rowSelection/index.js +1 -0
- package/hooks/features/rowSelection/useGridRowSelection.d.ts +12 -0
- package/hooks/features/{selection/useGridSelection.js → rowSelection/useGridRowSelection.js} +37 -37
- package/hooks/features/{selection/useGridSelectionPreProcessors.d.ts → rowSelection/useGridRowSelectionPreProcessors.d.ts} +1 -1
- package/hooks/features/{selection/useGridSelectionPreProcessors.js → rowSelection/useGridRowSelectionPreProcessors.js} +1 -1
- package/hooks/features/rows/gridRowsInterfaces.d.ts +4 -0
- package/hooks/features/rows/gridRowsUtils.d.ts +1 -1
- package/hooks/features/rows/gridRowsUtils.js +5 -2
- package/hooks/features/rows/useGridRows.js +23 -7
- package/hooks/features/virtualization/useGridVirtualScroller.d.ts +1 -1
- package/hooks/features/virtualization/useGridVirtualScroller.js +2 -2
- package/hooks/utils/useGridApi.d.ts +1 -1
- package/hooks/utils/useGridApiEventHandler.d.ts +2 -2
- package/hooks/utils/useGridApiRef.d.ts +1 -1
- package/hooks/utils/useGridInitializeState.d.ts +1 -1
- package/hooks/utils/useGridNativeEventListener.d.ts +1 -1
- package/hooks/utils/useGridSelector.d.ts +1 -1
- package/hooks/utils/useGridState.d.ts +1 -1
- package/hooks/utils/useGridVisibleRows.d.ts +2 -2
- package/index.js +1 -1
- package/internals/index.d.ts +3 -5
- package/internals/index.js +3 -5
- package/legacy/DataGrid/DataGrid.js +14 -34
- package/legacy/DataGrid/useDataGridComponent.js +8 -14
- package/legacy/DataGrid/useDataGridProps.js +3 -3
- package/legacy/colDef/gridCheckboxSelectionColDef.js +1 -1
- package/legacy/components/GridFooter.js +1 -1
- package/legacy/components/GridRow.js +2 -2
- package/legacy/components/base/GridBody.js +2 -2
- package/legacy/components/cell/GridEditInputCell.js +3 -8
- package/legacy/components/cell/GridEditSingleSelectCell.js +6 -52
- package/legacy/components/columnHeaders/GridColumnGroupHeader.js +46 -13
- package/legacy/components/columnSelection/GridHeaderCheckbox.js +3 -3
- package/legacy/components/containers/GridRoot.js +4 -3
- package/legacy/components/panel/GridColumnsPanel.js +10 -3
- package/legacy/components/panel/filterPanel/GridFilterForm.js +31 -7
- package/legacy/components/panel/filterPanel/GridFilterPanel.js +67 -18
- package/legacy/hooks/features/columnGrouping/gridColumnGroupsSelector.js +33 -1
- package/legacy/hooks/features/columnGrouping/gridColumnGroupsUtils.js +96 -0
- package/legacy/hooks/features/columnGrouping/useGridColumnGrouping.js +64 -64
- package/legacy/hooks/features/columnHeaders/useGridColumnHeaders.js +70 -122
- package/legacy/hooks/features/density/densitySelector.js +0 -6
- package/legacy/hooks/features/density/useGridDensity.js +6 -44
- package/legacy/hooks/features/dimensions/useGridDimensions.js +3 -2
- package/legacy/hooks/features/{editRows/gridEditRowsSelector.js → editing/gridEditingSelectors.js} +0 -0
- package/legacy/hooks/features/editing/index.js +1 -0
- package/legacy/hooks/features/{editRows/useGridCellEditing.new.js → editing/useGridCellEditing.js} +21 -6
- package/legacy/hooks/features/{editRows/useGridEditing.new.js → editing/useGridEditing.js} +3 -3
- package/legacy/hooks/features/{editRows/useGridRowEditing.new.js → editing/useGridRowEditing.js} +20 -6
- package/legacy/hooks/features/export/useGridPrintExport.js +2 -2
- package/legacy/hooks/features/focus/gridFocusStateSelector.js +8 -0
- package/legacy/hooks/features/focus/useGridFocus.js +72 -11
- package/legacy/hooks/features/index.js +2 -2
- package/legacy/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +129 -1
- package/legacy/hooks/features/rowSelection/gridRowSelectionSelector.js +19 -0
- package/legacy/hooks/features/rowSelection/index.js +1 -0
- package/legacy/hooks/features/{selection/useGridSelection.js → rowSelection/useGridRowSelection.js} +37 -37
- package/legacy/hooks/features/{selection/useGridSelectionPreProcessors.js → rowSelection/useGridRowSelectionPreProcessors.js} +1 -1
- package/legacy/hooks/features/rows/gridRowsUtils.js +5 -2
- package/legacy/hooks/features/rows/useGridRows.js +25 -7
- package/legacy/hooks/features/virtualization/useGridVirtualScroller.js +2 -2
- package/legacy/index.js +1 -1
- package/legacy/internals/index.js +3 -5
- package/legacy/locales/trTR.js +17 -17
- package/legacy/models/api/{gridSelectionApi.js → gridRowSelectionApi.js} +0 -0
- package/legacy/models/api/index.js +1 -1
- package/legacy/models/{gridSelectionModel.js → gridRowSelectionModel.js} +0 -0
- package/legacy/models/index.js +1 -1
- package/{models/api/gridSelectionApi.js → legacy/models/params/gridColumnGroupHeaderParams.js} +0 -0
- package/legacy/models/params/gridEditCellParams.js +0 -4
- package/legacy/models/params/index.js +1 -0
- package/locales/trTR.js +17 -17
- package/models/api/gridApiCommon.d.ts +3 -6
- package/models/api/gridApiCommunity.d.ts +1 -7
- package/models/api/gridEditingApi.d.ts +36 -121
- package/models/api/gridFocusApi.d.ts +13 -0
- package/models/api/{gridSelectionApi.d.ts → gridRowSelectionApi.d.ts} +2 -2
- package/models/{gridSelectionModel.js → api/gridRowSelectionApi.js} +0 -0
- package/models/api/index.d.ts +2 -2
- package/models/api/index.js +1 -1
- package/models/colDef/gridColDef.d.ts +0 -8
- package/models/events/gridEventLookup.d.ts +30 -19
- package/models/gridColumnGrouping.d.ts +1 -26
- package/models/gridRowSelectionModel.d.ts +3 -0
- package/{modern/models/api/gridSelectionApi.js → models/gridRowSelectionModel.js} +0 -0
- package/models/gridStateCommunity.d.ts +2 -2
- package/models/index.d.ts +1 -1
- package/models/index.js +1 -1
- package/models/params/gridColumnGroupHeaderParams.d.ts +30 -0
- package/{modern/models/gridSelectionModel.js → models/params/gridColumnGroupHeaderParams.js} +0 -0
- package/models/params/gridEditCellParams.d.ts +4 -17
- package/models/params/gridEditCellParams.js +0 -4
- package/models/params/gridRowParams.d.ts +4 -4
- package/models/params/index.d.ts +1 -0
- package/models/params/index.js +1 -0
- package/models/props/DataGridProps.d.ts +8 -32
- package/modern/DataGrid/DataGrid.js +14 -34
- package/modern/DataGrid/useDataGridComponent.js +8 -12
- package/modern/DataGrid/useDataGridProps.js +3 -3
- package/modern/colDef/gridCheckboxSelectionColDef.js +1 -1
- package/modern/components/GridFooter.js +1 -1
- package/modern/components/GridRow.js +2 -2
- package/modern/components/base/GridBody.js +2 -2
- package/modern/components/cell/GridEditInputCell.js +3 -4
- package/modern/components/cell/GridEditSingleSelectCell.js +6 -34
- package/modern/components/columnHeaders/GridColumnGroupHeader.js +32 -5
- package/modern/components/columnSelection/GridHeaderCheckbox.js +3 -3
- package/modern/components/containers/GridRoot.js +4 -3
- package/modern/components/panel/GridColumnsPanel.js +10 -4
- package/modern/components/panel/filterPanel/GridFilterForm.js +29 -7
- package/modern/components/panel/filterPanel/GridFilterPanel.js +62 -17
- package/modern/hooks/features/columnGrouping/gridColumnGroupsSelector.js +14 -1
- package/modern/hooks/features/columnGrouping/gridColumnGroupsUtils.js +83 -0
- package/modern/hooks/features/columnGrouping/useGridColumnGrouping.js +50 -62
- package/modern/hooks/features/columnHeaders/useGridColumnHeaders.js +58 -98
- package/modern/hooks/features/density/densitySelector.js +1 -3
- package/modern/hooks/features/density/useGridDensity.js +9 -37
- package/modern/hooks/features/dimensions/useGridDimensions.js +3 -2
- package/modern/hooks/features/{editRows/gridEditRowsSelector.js → editing/gridEditingSelectors.js} +0 -0
- package/modern/hooks/features/editing/index.js +1 -0
- package/modern/hooks/features/{editRows/useGridCellEditing.new.js → editing/useGridCellEditing.js} +21 -6
- package/modern/hooks/features/{editRows/useGridEditing.new.js → editing/useGridEditing.js} +3 -3
- package/modern/hooks/features/{editRows/useGridRowEditing.new.js → editing/useGridRowEditing.js} +20 -6
- package/modern/hooks/features/export/useGridPrintExport.js +2 -2
- package/modern/hooks/features/focus/gridFocusStateSelector.js +6 -2
- package/modern/hooks/features/focus/useGridFocus.js +69 -11
- package/modern/hooks/features/index.js +2 -2
- package/modern/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +135 -1
- package/modern/hooks/features/rowSelection/gridRowSelectionSelector.js +9 -0
- package/modern/hooks/features/rowSelection/index.js +1 -0
- package/modern/hooks/features/{selection/useGridSelection.js → rowSelection/useGridRowSelection.js} +37 -37
- package/modern/hooks/features/{selection/useGridSelectionPreProcessors.js → rowSelection/useGridRowSelectionPreProcessors.js} +1 -1
- package/modern/hooks/features/rows/gridRowsUtils.js +5 -2
- package/modern/hooks/features/rows/useGridRows.js +23 -7
- package/modern/hooks/features/virtualization/useGridVirtualScroller.js +2 -2
- package/modern/index.js +1 -1
- package/modern/internals/index.js +3 -5
- package/modern/locales/trTR.js +17 -17
- package/modern/models/api/gridRowSelectionApi.js +1 -0
- package/modern/models/api/index.js +1 -1
- package/modern/models/gridRowSelectionModel.js +1 -0
- package/modern/models/index.js +1 -1
- package/modern/models/params/gridColumnGroupHeaderParams.js +1 -0
- package/modern/models/params/gridEditCellParams.js +0 -4
- package/modern/models/params/index.js +1 -0
- package/node/DataGrid/DataGrid.js +14 -34
- package/node/DataGrid/useDataGridComponent.js +9 -17
- package/node/DataGrid/useDataGridProps.js +3 -3
- package/node/colDef/gridCheckboxSelectionColDef.js +2 -2
- package/node/components/GridFooter.js +2 -2
- package/node/components/GridRow.js +2 -2
- package/node/components/base/GridBody.js +2 -2
- package/node/components/cell/GridEditInputCell.js +3 -9
- package/node/components/cell/GridEditSingleSelectCell.js +6 -38
- package/node/components/columnHeaders/GridColumnGroupHeader.js +32 -5
- package/node/components/columnSelection/GridHeaderCheckbox.js +3 -3
- package/node/components/containers/GridRoot.js +4 -2
- package/node/components/panel/GridColumnsPanel.js +10 -4
- package/node/components/panel/filterPanel/GridFilterForm.js +30 -7
- package/node/components/panel/filterPanel/GridFilterPanel.js +63 -19
- package/node/hooks/features/columnGrouping/gridColumnGroupsSelector.js +40 -3
- package/node/hooks/features/columnGrouping/gridColumnGroupsUtils.js +102 -0
- package/node/hooks/features/columnGrouping/useGridColumnGrouping.js +68 -71
- package/node/hooks/features/columnHeaders/useGridColumnHeaders.js +57 -113
- package/node/hooks/features/density/densitySelector.js +2 -6
- package/node/hooks/features/density/useGridDensity.js +9 -48
- package/node/hooks/features/dimensions/useGridDimensions.js +3 -1
- package/node/hooks/features/{editRows/gridEditRowsSelector.js → editing/gridEditingSelectors.js} +0 -0
- package/node/hooks/features/{editRows → editing}/index.js +4 -4
- package/node/hooks/features/{editRows/useGridCellEditing.new.js → editing/useGridCellEditing.js} +28 -13
- package/node/hooks/features/{editRows/useGridEditing.new.js → editing/useGridEditing.js} +4 -4
- package/node/hooks/features/{editRows/useGridRowEditing.new.js → editing/useGridRowEditing.js} +28 -14
- package/node/hooks/features/export/useGridPrintExport.js +2 -2
- package/node/hooks/features/focus/gridFocusStateSelector.js +10 -4
- package/node/hooks/features/focus/useGridFocus.js +68 -10
- package/node/hooks/features/index.js +8 -8
- package/node/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +138 -1
- package/node/hooks/features/{selection/gridSelectionSelector.js → rowSelection/gridRowSelectionSelector.js} +6 -6
- package/node/hooks/features/rowSelection/index.js +18 -0
- package/node/hooks/features/{selection/useGridSelection.js → rowSelection/useGridRowSelection.js} +43 -43
- package/node/hooks/features/{selection/useGridSelectionPreProcessors.js → rowSelection/useGridRowSelectionPreProcessors.js} +3 -3
- package/node/hooks/features/rows/gridRowsUtils.js +5 -2
- package/node/hooks/features/rows/useGridRows.js +23 -7
- package/node/hooks/features/virtualization/useGridVirtualScroller.js +4 -4
- package/node/index.js +1 -1
- package/node/internals/index.js +23 -45
- package/node/locales/trTR.js +17 -17
- package/node/models/api/{gridSelectionApi.js → gridRowSelectionApi.js} +0 -0
- package/node/models/api/index.js +4 -4
- package/node/models/{gridSelectionModel.js → gridRowSelectionModel.js} +0 -0
- package/node/models/index.js +4 -4
- package/node/models/params/gridColumnGroupHeaderParams.js +5 -0
- package/node/models/params/gridEditCellParams.js +0 -3
- package/node/models/params/index.js +13 -0
- package/package.json +2 -2
- package/hooks/features/columnGrouping/useGridColumnGroupingPreProcessors.d.ts +0 -4
- package/hooks/features/columnGrouping/useGridColumnGroupingPreProcessors.js +0 -35
- package/hooks/features/editRows/index.d.ts +0 -1
- package/hooks/features/editRows/index.js +0 -1
- package/hooks/features/editRows/useGridCellEditing.old.d.ts +0 -4
- package/hooks/features/editRows/useGridCellEditing.old.js +0 -359
- package/hooks/features/editRows/useGridEditing.old.d.ts +0 -11
- package/hooks/features/editRows/useGridEditing.old.js +0 -167
- package/hooks/features/editRows/useGridRowEditing.old.d.ts +0 -4
- package/hooks/features/editRows/useGridRowEditing.old.js +0 -334
- package/hooks/features/selection/gridSelectionSelector.js +0 -9
- package/hooks/features/selection/index.d.ts +0 -1
- package/hooks/features/selection/index.js +0 -1
- package/hooks/features/selection/useGridSelection.d.ts +0 -12
- package/legacy/hooks/features/columnGrouping/useGridColumnGroupingPreProcessors.js +0 -35
- package/legacy/hooks/features/editRows/index.js +0 -1
- package/legacy/hooks/features/editRows/useGridCellEditing.old.js +0 -411
- package/legacy/hooks/features/editRows/useGridEditing.old.js +0 -184
- package/legacy/hooks/features/editRows/useGridRowEditing.old.js +0 -505
- package/legacy/hooks/features/selection/gridSelectionSelector.js +0 -19
- package/legacy/hooks/features/selection/index.js +0 -1
- package/models/gridSelectionModel.d.ts +0 -3
- package/modern/hooks/features/columnGrouping/useGridColumnGroupingPreProcessors.js +0 -29
- package/modern/hooks/features/editRows/index.js +0 -1
- package/modern/hooks/features/editRows/useGridCellEditing.old.js +0 -355
- package/modern/hooks/features/editRows/useGridEditing.old.js +0 -163
- package/modern/hooks/features/editRows/useGridRowEditing.old.js +0 -326
- package/modern/hooks/features/selection/gridSelectionSelector.js +0 -9
- package/modern/hooks/features/selection/index.js +0 -1
- package/node/hooks/features/columnGrouping/useGridColumnGroupingPreProcessors.js +0 -55
- package/node/hooks/features/editRows/useGridCellEditing.old.js +0 -380
- package/node/hooks/features/editRows/useGridEditing.old.js +0 -193
- package/node/hooks/features/editRows/useGridRowEditing.old.js +0 -358
- package/node/hooks/features/selection/index.js +0 -18
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,345 @@
|
|
|
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
|
+
## v6.0.0-alpha.4
|
|
7
|
+
|
|
8
|
+
_Oct 20, 2022_
|
|
9
|
+
|
|
10
|
+
We'd like to offer a big thanks to the 9 contributors who made this release possible. Here are some highlights ✨:
|
|
11
|
+
|
|
12
|
+
- 📝 Manage pickers' toolbar customization with slots
|
|
13
|
+
- 🐞 Bugfixes
|
|
14
|
+
- 🌍 Improve Turkish (tr-TR) locale on the data grid and pickers (#6542) @ramazansancar
|
|
15
|
+
|
|
16
|
+
### `@mui/x-data-grid@v6.0.0-alpha.4` / `@mui/x-data-grid-pro@v6.0.0-alpha.4` / `@mui/x-data-grid-premium@v6.0.0-alpha.4`
|
|
17
|
+
|
|
18
|
+
#### Breaking changes
|
|
19
|
+
|
|
20
|
+
- To avoid confusion with the props that will be added for the cell selection feature, some props related to row selection were renamed to have "row" in their name.
|
|
21
|
+
The renamed props are the following:
|
|
22
|
+
|
|
23
|
+
| Old name | New name |
|
|
24
|
+
|----------------------------|-------------------------------|
|
|
25
|
+
| `selectionModel` | `rowSelectionModel` |
|
|
26
|
+
| `onSelectionModelChange` | `onRowSelectionModelChange` |
|
|
27
|
+
| `disableSelectionOnClick` | `disableRowSelectionOnClick` |
|
|
28
|
+
| `disableMultipleSelection` | `disableMultipleRowSelection` |
|
|
29
|
+
|
|
30
|
+
- The `gridSelectionStateSelector` selector was renamed to `gridRowSelectionStateSelector`.
|
|
31
|
+
|
|
32
|
+
- The `selectionChange` event was renamed to `rowSelectionChange`.
|
|
33
|
+
|
|
34
|
+
#### Changes
|
|
35
|
+
|
|
36
|
+
- [DataGrid] Add `searchPredicate` prop to `GridColumnsPanel` component (#6557) @cherniavskii
|
|
37
|
+
- [DataGrid] Support keyboard navigation in column group header (#5947) @alexfauquette
|
|
38
|
+
- [DataGrid] Fix grid not updating state on `rowCount` prop change (#5982) @cherniavskii
|
|
39
|
+
- [DataGrid] Rename selection props (#6556) @m4theushw
|
|
40
|
+
- [l10n] Improve Turkish (tr-TR) locale on the data grid and pickers (#6542) @ramazansancar
|
|
41
|
+
|
|
42
|
+
### `@mui/x-date-pickers@v6.0.0-alpha.4` / `@mui/x-date-pickers-pro@v6.0.0-alpha.4`
|
|
43
|
+
|
|
44
|
+
#### Breaking changes
|
|
45
|
+
|
|
46
|
+
- The `ToolbarComponent` has been replaced by a `Toolbar` component slot.
|
|
47
|
+
You can find more information about this pattern in the [MUI Base documentation](https://mui.com/base/getting-started/usage/#shared-props):
|
|
48
|
+
|
|
49
|
+
```diff
|
|
50
|
+
// Same on all other pickers
|
|
51
|
+
<DatePicker
|
|
52
|
+
- ToolbarComponent: MyToolbar,
|
|
53
|
+
+ components={{ Toolbar: MyToolbar }}
|
|
54
|
+
/>
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
- The `toolbarPlaceholder` and `toolbarFormat` props have been moved to the `toolbar` components props slot:
|
|
58
|
+
|
|
59
|
+
```diff
|
|
60
|
+
// Same on all other pickers
|
|
61
|
+
<DatePicker
|
|
62
|
+
- toolbarPlaceholder="__"
|
|
63
|
+
- toolbarFormat="DD / MM / YYYY"
|
|
64
|
+
+ componentsProps={{
|
|
65
|
+
+ toolbar: {
|
|
66
|
+
+ toolbarPlaceholder: "__",
|
|
67
|
+
+ toolbarFormat: "DD / MM / YYYY",
|
|
68
|
+
+ }
|
|
69
|
+
+ }}
|
|
70
|
+
/>
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
- The `toolbarTitle` prop has been moved to the localization object:
|
|
74
|
+
|
|
75
|
+
```diff
|
|
76
|
+
// Same on all other pickers
|
|
77
|
+
<DatePicker
|
|
78
|
+
- toolbarTitle="Title"
|
|
79
|
+
+ localeText={{ toolbarTitle: "Title" }}
|
|
80
|
+
/>
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
- The toolbar related translation keys have been renamed to better fit their usage:
|
|
84
|
+
|
|
85
|
+
```diff
|
|
86
|
+
// Same on all other pickers
|
|
87
|
+
<DatePicker
|
|
88
|
+
localeText={{
|
|
89
|
+
- datePickerDefaultToolbarTitle: 'Date Picker',
|
|
90
|
+
+ datePickerToolbarTitle: 'Date Picker',
|
|
91
|
+
|
|
92
|
+
- timePickerDefaultToolbarTitle: 'Time Picker',
|
|
93
|
+
+ timePickerToolbarTitle: 'Time Picker',
|
|
94
|
+
|
|
95
|
+
- dateTimePickerDefaultToolbarTitle: 'Date Time Picker',
|
|
96
|
+
+ dateTimePickerToolbarTitle: 'Date Time Picker',
|
|
97
|
+
|
|
98
|
+
- dateRangePickerDefaultToolbarTitle: 'Date Range Picker',
|
|
99
|
+
+ dateRangePickerToolbarTitle: 'Date Range Picker',
|
|
100
|
+
}}
|
|
101
|
+
/>
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
- The `onChange` / `openView` props on the toolbar have been renamed `onViewChange` / `view`
|
|
105
|
+
|
|
106
|
+
#### Changes
|
|
107
|
+
|
|
108
|
+
- [fields] Add a `validationError` property to the `onChange` callback (#6539) @flaviendelangle
|
|
109
|
+
- [fields] Distinguish start and end input error on multi input fields (#6503) @flaviendelangle
|
|
110
|
+
- [pickers] Clean the `Tabs` component slot (#6543) @flaviendelangle
|
|
111
|
+
- [pickers] Fix localization of the placeholder (#6547) @alexfauquette
|
|
112
|
+
- [pickers] Fix TypeScript issues (#6322) @flaviendelangle
|
|
113
|
+
- [pickers] Improve error consistency between single and multiple range pickers (#6561) @alexfauquette
|
|
114
|
+
- [pickers] Refactor `@mui/material` imports to `@mui/utils` (#6443) @LukasTy
|
|
115
|
+
- [pickers] Replace toolbar's props by a component slot (#6445) @flaviendelangle
|
|
116
|
+
|
|
117
|
+
### Docs
|
|
118
|
+
|
|
119
|
+
- [docs] Enable inlined preview for disabled date picker (#6477) @oliviertassinari
|
|
120
|
+
- [docs] Fix 404 errors (#6541) @alexfauquette
|
|
121
|
+
- [docs] Fix broken links on field pages (#6501) @flaviendelangle
|
|
122
|
+
- [docs] Improve markdownlint (#6518) @oliviertassinari
|
|
123
|
+
|
|
124
|
+
### Core
|
|
125
|
+
|
|
126
|
+
- [core] Run CodeQL only on schedule @oliviertassinari
|
|
127
|
+
- [core] Fix trailing spaces and git diff format (#6523) @oliviertassinari
|
|
128
|
+
- [core] Harden GitHub Actions permissions (#6396) @step-security-bot
|
|
129
|
+
- [core] Improve the playground DX (#6514) @oliviertassinari
|
|
130
|
+
- [core] Link Netlify in the danger comment (#6513) @oliviertassinari
|
|
131
|
+
- [core] Organize tests for pickers slots (#6546) @flaviendelangle
|
|
132
|
+
- [core] Remove outdated `docsearch.js` dependency (#6242) @oliviertassinari
|
|
133
|
+
- [core] Upgrade monorepo (#6549) @cherniavskii
|
|
134
|
+
- [test] Add validation test on range pickers (#6504) @alexfauquette
|
|
135
|
+
- [test] Remove BrowserStack (#6263) @DanailH
|
|
136
|
+
|
|
137
|
+
## v6.0.0-alpha.3
|
|
138
|
+
|
|
139
|
+
_Oct 13, 2022_
|
|
140
|
+
|
|
141
|
+
We'd like to offer a big thanks to the 8 contributors who made this release possible. Here are some highlights ✨:
|
|
142
|
+
|
|
143
|
+
- ⌚️ New components to edit date and time with <kbd>keyboard</kbd>—without using any modal or dropdown UI.
|
|
144
|
+
Please check out our [documentation](https://next.mui.com/x/react-date-pickers/fields/) to discover those new components.
|
|
145
|
+
- [`DateField`](https://next.mui.com/x/react-date-pickers/date-field/) to edit date
|
|
146
|
+
- [`TimeField`](https://next.mui.com/x/react-date-pickers/time-field/) to edit time
|
|
147
|
+
- [`DateTimeField`](https://next.mui.com/x/react-date-pickers/date-time-field/) to edit date and time
|
|
148
|
+
- [`MultiInputDateRangeField` / `SingleInputDateRangeField`](https://next.mui.com/x/react-date-pickers/date-range-field/) to edit date range
|
|
149
|
+
- [`MultiInputTimeRangeField`](https://next.mui.com/x/react-date-pickers/time-range-field/) to edit time range with two inputs
|
|
150
|
+
- [`MultiInputDateTimeRangeField`](https://next.mui.com/x/react-date-pickers/date-time-range-field/) to edit date and time range with two inputs
|
|
151
|
+
|
|
152
|
+
⚠️ These components are unstable.
|
|
153
|
+
They might receive breaking changes on their props to have the best components possible by the time of the stable release.
|
|
154
|
+
|
|
155
|
+
- 📝 Allow to limit to one filter per column for `DataGridPro` and `DataGridPremium` (#6333) @MBilalShafi
|
|
156
|
+
- 📚 New [page describing the validation props on each picker](https://next.mui.com/x/react-date-pickers/validation/) (#6064) @flaviendelangle
|
|
157
|
+
- 📚 Documentation improvements
|
|
158
|
+
- 🐞 Bugfixes
|
|
159
|
+
|
|
160
|
+
### `@mui/x-data-grid@v6.0.0-alpha.3` / `@mui/x-data-grid-pro@v6.0.0-alpha.3` / `@mui/x-data-grid-premium@v6.0.0-alpha.3`
|
|
161
|
+
|
|
162
|
+
#### Breaking changes
|
|
163
|
+
|
|
164
|
+
- [DataGrid] Remove legacy editing API
|
|
165
|
+
|
|
166
|
+
The editing API that is enabled by default was replaced with a new API that contains better support for server-side persistence, validation and customization. This new editing feature was already available in v5 under the `newEditingApi` experimental flag. In v6, this flag can be removed.
|
|
167
|
+
|
|
168
|
+
```diff
|
|
169
|
+
<DataGrid
|
|
170
|
+
- experimentalFeatures={{ newEditingApi: true }}
|
|
171
|
+
/>
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
For users that didn't migrate to the new editing API in v5, additional work may be needed because the new API is not equivalent to the legacy API. Although, some migration steps are available to help in this task.
|
|
175
|
+
|
|
176
|
+
- The `editCellPropsChange` event was removed. If you still need it please file a new issue so we can propose an alternative.
|
|
177
|
+
- The `cellEditCommit` event was removed and the `processRowUpdate` prop can be used in place. More information, check the [docs](https://next.mui.com/x/react-data-grid/editing/#persistence) section about the topic.
|
|
178
|
+
- The `editRowsModel` and `onEditRowsModelChange` props were removed. The [`cellModesModel`](https://next.mui.com/x/react-data-grid/editing/#controlled-mode) or [`rowModesModel`](https://next.mui.com/x/react-data-grid/editing/#controlled-mode) props can be used to achieve the same goal.
|
|
179
|
+
- The following API methods were removed:
|
|
180
|
+
- Use `apiRef.current.stopCellEditMode` to replace `apiRef.current.commitCellChange`
|
|
181
|
+
- Use `apiRef.current.startCellEditMode` to replace `apiRef.current.setCellMode(id, field, 'edit')`
|
|
182
|
+
- Use `apiRef.current.stopRowEditMode` to replace `apiRef.current.commitRowChange`
|
|
183
|
+
- Use `apiRef.current.startRowMode` to replace `apiRef.current.setRowMode(id, 'edit')`
|
|
184
|
+
- Use the [`cellModesModel`](https://next.mui.com/x/react-data-grid/editing/#controlled-mode) or [`rowModesModel`](https://next.mui.com/x/react-data-grid/editing/#controlled-mode) props to replace `apiRef.current.setEditRowsModel`
|
|
185
|
+
|
|
186
|
+
#### Changes
|
|
187
|
+
|
|
188
|
+
- [DataGrid] Fix start edit mode with printable character in React 18 (#6257) @m4theushw
|
|
189
|
+
- [DataGrid] Remove legacy editing API (#6016) @m4theushw
|
|
190
|
+
- [DataGrid] Simplify `useGridApiContext` and `useGridApiRef` type overrides (#6423) @cherniavskii
|
|
191
|
+
- [DataGrid] Use generics instead of verbose state overrides (#6409) @cherniavskii
|
|
192
|
+
- [DataGridPro] Allow to limit to one filter per column (#6333) @MBilalShafi
|
|
193
|
+
|
|
194
|
+
### `@mui/x-date-pickers@v6.0.0-alpha.3` / `@mui/x-date-pickers-pro@v6.0.0-alpha.3`
|
|
195
|
+
|
|
196
|
+
#### Breaking changes
|
|
197
|
+
|
|
198
|
+
- All the props used by the mobile and desktop wrappers to override components or components' props have been replaced by component slots. You can find more information about this pattern in the [MUI Base documentation](https://mui.com/base/getting-started/usage/#shared-props).
|
|
199
|
+
|
|
200
|
+
Some of the names have also been prefixed by `desktop` when it was unclear that the behavior was only applied on the desktop version of the pickers (or the responsive version when used on a desktop).
|
|
201
|
+
|
|
202
|
+
The `DialogProps` prop has been replaced by a `dialog` component props slot on responsive and mobile pickers:
|
|
203
|
+
|
|
204
|
+
```diff
|
|
205
|
+
// Same on MobileDatePicker, DateTimePicker, MobileDateTimePicker,
|
|
206
|
+
// TimePicker, MobileTimePicker, DateRangePicker and MobileDateRangePicker.
|
|
207
|
+
<DatePicker
|
|
208
|
+
- DialogProps={{ backgroundColor: 'red' }}
|
|
209
|
+
+ componentsProps={{ dialog: { backgroundColor: 'red }}}
|
|
210
|
+
/>
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
The `PaperProps` prop has been replaced by a `desktopPaper` component props slot on all responsive and desktop pickers:
|
|
214
|
+
|
|
215
|
+
```diff
|
|
216
|
+
// Same on DesktopDatePicker, DateTimePicker, DesktopDateTimePicker,
|
|
217
|
+
// TimePicker, DesktopTimePicker, DateRangePicker and DesktopDateRangePicker.
|
|
218
|
+
<DatePicker
|
|
219
|
+
- PaperProps={{ backgroundColor: 'red' }}
|
|
220
|
+
+ componentsProps={{ desktopPaper: { backgroundColor: 'red }}}
|
|
221
|
+
/>
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
The `PopperProps` prop has been replaced by a `popper` component props slot on all responsive and desktop pickers:
|
|
225
|
+
|
|
226
|
+
```diff
|
|
227
|
+
// Same on DesktopDatePicker, DateTimePicker, DesktopDateTimePicker,
|
|
228
|
+
// TimePicker, DesktopTimePicker, DateRangePicker and DesktopDateRangePicker.
|
|
229
|
+
<DatePicker
|
|
230
|
+
- PopperProps={{ onClick: handleClick }}
|
|
231
|
+
+ componentsProps={{ popper: { onClick: handleClick }}}
|
|
232
|
+
/>
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
The `TransitionComponent` prop has been replaced by a `DesktopTransition` component slot on all responsive and desktop pickers:
|
|
236
|
+
|
|
237
|
+
```diff
|
|
238
|
+
// Same on DesktopDatePicker, DateTimePicker, DesktopDateTimePicker,
|
|
239
|
+
// TimePicker, DesktopTimePicker, DateRangePicker and DesktopDateRangePicker.
|
|
240
|
+
<DatePicker
|
|
241
|
+
- TransitionComponent={Fade}
|
|
242
|
+
+ components={{ DesktopTransition: Fade }}
|
|
243
|
+
/>
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
The `TrapFocusProps` prop has been replaced by a `desktopTrapFocus` component props slot on all responsive and desktop pickers:
|
|
247
|
+
|
|
248
|
+
```diff
|
|
249
|
+
// Same on DesktopDatePicker, DateTimePicker, DesktopDateTimePicker,
|
|
250
|
+
// TimePicker, DesktopTimePicker, DateRangePicker and DesktopDateRangePicker.
|
|
251
|
+
<DatePicker
|
|
252
|
+
- TrapFocusProps={{ isEnabled: () => false }}
|
|
253
|
+
+ componentsProps={{ desktopTrapFocus: { isEnabled: () => false }}}
|
|
254
|
+
/>
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
- The view components allowing to pick a date or parts of a date without an input have been renamed to better fit their usage:
|
|
258
|
+
|
|
259
|
+
```diff
|
|
260
|
+
-<CalendarPicker {...props} />
|
|
261
|
+
+<DateCalendar {...props} />
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
```diff
|
|
265
|
+
-<DayPicker {...props} />
|
|
266
|
+
+<DayCalendar {...props} />
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
```diff
|
|
270
|
+
-<CalendarPickerSkeleton {...props} />
|
|
271
|
+
+<DayCalendarSkeleton {...props} />
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
```diff
|
|
275
|
+
-<MonthPicker {...props} />
|
|
276
|
+
+<MonthCalendar {...props} />
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
```diff
|
|
280
|
+
-<YearPicker {...props} />
|
|
281
|
+
+<YearCalendar {...props} />
|
|
282
|
+
```
|
|
283
|
+
|
|
284
|
+
- Component names in the theme have changed as well:
|
|
285
|
+
|
|
286
|
+
```diff
|
|
287
|
+
-MuiCalendarPicker: {
|
|
288
|
+
+MuiDateCalendar: {
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
```diff
|
|
292
|
+
-MuiDayPicker: {
|
|
293
|
+
+MuiDayCalendar: {
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
```diff
|
|
297
|
+
-MuiCalendarPickerSkeleton: {
|
|
298
|
+
+MuiDayCalendarSkeleton: {
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
```diff
|
|
302
|
+
-MuiMonthPicker: {
|
|
303
|
+
+MuiMonthCalendar: {
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
```diff
|
|
307
|
+
-MuiYearPicker: {
|
|
308
|
+
+MuiYearCalendar: {
|
|
309
|
+
```
|
|
310
|
+
|
|
311
|
+
#### Changes
|
|
312
|
+
|
|
313
|
+
- [DatePicker] Allows to fix the number of week displayed (#6299) @alexfauquette
|
|
314
|
+
- [DateRangePicker] Fix calendar day outside of month layout shifting on hover (#6448) @alexfauquette
|
|
315
|
+
- [fields] New components: `MultiInputDateTimeRangePicker` and `MultiInputTimeRangePicker` (#6392) @alexfauquette
|
|
316
|
+
- [fields] Prepare the field exports for the public release (#6467) @flaviendelangle
|
|
317
|
+
- [fields] Support paste in single section (#6422) @alexfauquette
|
|
318
|
+
- [pickers] Add field placeholders to the locale (#6337) @flaviendelangle
|
|
319
|
+
- [pickers] Do not use `Partial` for `components` and `componentsProps` props (#6463) @flaviendelangle
|
|
320
|
+
- [pickers] New component: `DateRangeCalendar` (#6416) @flaviendelangle
|
|
321
|
+
- [pickers] Replace the `Picker` prefix in the view component by `Calendar` (eg: `MonthPicker` => `MonthCalendar`) (#6389) @flaviendelangle
|
|
322
|
+
- [pickers] Support pasting on fields (#6364) @flaviendelangle
|
|
323
|
+
- [pickers] Use slots in the mobile and desktop wrappers instead of `XXXComponent` and `XXXProps` (#6381) @flaviendelangle
|
|
324
|
+
|
|
325
|
+
### Docs
|
|
326
|
+
|
|
327
|
+
- [docs] Add migration to DataGrid v6 page (#6235) @m4theushw
|
|
328
|
+
- [docs] Create first publishable version of the field doc (#6323) @flaviendelangle
|
|
329
|
+
- [docs] Fix trailing spaces in the readme @oliviertassinari
|
|
330
|
+
- [docs] New page for the pickers: Validation (#6064) @flaviendelangle
|
|
331
|
+
- [docs] Organize migration pages (#6480) @flaviendelangle
|
|
332
|
+
|
|
333
|
+
### Core
|
|
334
|
+
|
|
335
|
+
- [core] Add CodeQL workflow (#6387) @DanailH
|
|
336
|
+
- [core] Add missing breaking change to the changelog (#6471) @flaviendelangle
|
|
337
|
+
- [core] Fix playground structure (#6466) @LukasTy
|
|
338
|
+
- [core] Fix tests for pasting on fields (#6465) @flaviendelangle
|
|
339
|
+
- [core] Remove absolute link (#6420) @flaviendelangle
|
|
340
|
+
- [core] Remove unused `react-text-mask` package (#6408) @LukasTy
|
|
341
|
+
- [core] Send explicit warning when dayjs locale is not found (#6424) @alexfauquette
|
|
342
|
+
- [core] Test validation on textfield and date views (#6265) @alexfauquette
|
|
343
|
+
- [test] Sync comment with monorepo @oliviertassinari
|
|
344
|
+
|
|
6
345
|
## v6.0.0-alpha.2
|
|
7
346
|
|
|
8
347
|
_Oct 7, 2022_
|
|
@@ -24,9 +363,9 @@ We'd like to offer a big thanks to the 10 contributors who made this release pos
|
|
|
24
363
|
You can now use the aggregation without the `experimentalFeatures.aggregation` flag enabled.
|
|
25
364
|
|
|
26
365
|
```diff
|
|
27
|
-
|
|
366
|
+
<DataGridPremium
|
|
28
367
|
- experimentalFeatures={{ aggregation: true }}
|
|
29
|
-
|
|
368
|
+
/>
|
|
30
369
|
```
|
|
31
370
|
|
|
32
371
|
The aggregation of the columns through the column menu is now enabled by default on `DataGridPremium`. You can set `disableAggregation={true}` to disable it.
|
|
@@ -48,11 +387,11 @@ We'd like to offer a big thanks to the 10 contributors who made this release pos
|
|
|
48
387
|
You can find more information about this pattern in the [MUI Base documentation](https://mui.com/base/getting-started/usage/#shared-props).
|
|
49
388
|
|
|
50
389
|
```diff
|
|
51
|
-
|
|
52
|
-
|
|
390
|
+
// Same for any other date, date time or date range picker.
|
|
391
|
+
<DatePicker
|
|
53
392
|
- renderDay={(_, dayProps) => <CustomDay {...dayProps} />}
|
|
54
393
|
+ components={{ Day: CustomDay }}
|
|
55
|
-
|
|
394
|
+
/>
|
|
56
395
|
```
|
|
57
396
|
|
|
58
397
|
#### Changes
|
|
@@ -114,7 +453,7 @@ We'd like to offer a big thanks to the 8 contributors who made this release poss
|
|
|
114
453
|
Here is an example of the old and new approach showing how to apply a custom value formatter in groups for the grouping column:
|
|
115
454
|
|
|
116
455
|
```diff
|
|
117
|
-
<DataGridPremium
|
|
456
|
+
<DataGridPremium
|
|
118
457
|
groupingColDef={() => ({
|
|
119
458
|
valueFormatter: (params) => {
|
|
120
459
|
if (params.id == null) {
|
|
@@ -155,9 +494,8 @@ We'd like to offer a big thanks to the 8 contributors who made this release poss
|
|
|
155
494
|
|
|
156
495
|
#### Breaking changes
|
|
157
496
|
|
|
158
|
-
-
|
|
497
|
+
- The `value` prop of the pickers now expects a parsed value.
|
|
159
498
|
|
|
160
|
-
The `value` prop of the pickers now expects a parsed value.
|
|
161
499
|
Until now, it was possible to provide any format that your date management library was able to parse.
|
|
162
500
|
For instance, you could pass `value={new Date()}` when using `AdapterDayjs`.
|
|
163
501
|
|
|
@@ -231,17 +569,17 @@ We'd like to offer a big thanks to the 12 contributors who made this release pos
|
|
|
231
569
|
- The deprecated `hide` column property has been removed in favor of the `columnVisibilityModel` prop and initial state.
|
|
232
570
|
|
|
233
571
|
```diff
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
-
|
|
238
|
-
|
|
572
|
+
<DataGrid
|
|
573
|
+
columns={[
|
|
574
|
+
field: 'id,
|
|
575
|
+
- hide: true,
|
|
576
|
+
]}
|
|
239
577
|
+ initialState={{
|
|
240
578
|
+ columns: {
|
|
241
579
|
+ columnVisibilityModel: { id: false },
|
|
242
|
-
+ }
|
|
580
|
+
+ },
|
|
243
581
|
+ }}
|
|
244
|
-
|
|
582
|
+
/>
|
|
245
583
|
```
|
|
246
584
|
|
|
247
585
|
You can find more information about this new API on our [documentation](https://next.mui.com/x/react-data-grid/column-visibility/).
|
|
@@ -249,8 +587,8 @@ We'd like to offer a big thanks to the 12 contributors who made this release pos
|
|
|
249
587
|
- The `GridEvents` enum is now a TypeScript type.
|
|
250
588
|
|
|
251
589
|
```diff
|
|
252
|
-
-
|
|
253
|
-
+
|
|
590
|
+
-apiRef.current.subscribeEvent(GridEvents.rowClick', handleRowClick);
|
|
591
|
+
+apiRef.current.subscribeEvent('rowClick', handleRowClick);
|
|
254
592
|
```
|
|
255
593
|
|
|
256
594
|
#### Changes
|
|
@@ -284,54 +622,65 @@ We'd like to offer a big thanks to the 12 contributors who made this release pos
|
|
|
284
622
|
For instance if you want to replace the `startText` / `endText`
|
|
285
623
|
|
|
286
624
|
```diff
|
|
287
|
-
|
|
625
|
+
<DateRangePicker
|
|
288
626
|
- startText="From"
|
|
289
627
|
- endText="To"
|
|
290
628
|
+ localeText={{
|
|
291
629
|
+ start: 'From',
|
|
292
630
|
+ end: 'To',
|
|
293
631
|
+ }}
|
|
294
|
-
|
|
632
|
+
/>
|
|
295
633
|
```
|
|
296
634
|
|
|
297
635
|
You can find more information about the new api, including how to set those translations on all your components at once in the [documentation](https://next.mui.com/x/react-date-pickers/localization/)
|
|
298
636
|
|
|
299
|
-
- The
|
|
637
|
+
- The deprecated `locale` prop of the `LocalizationProvider` component have been renamed `adapterLocale`:
|
|
300
638
|
|
|
301
639
|
```diff
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
-
|
|
305
|
-
+
|
|
640
|
+
<LocalizationProvider
|
|
641
|
+
dateAdapter={AdapterDayjs}
|
|
642
|
+
- locale="fr"
|
|
643
|
+
+ adapterLocale="fr"
|
|
644
|
+
>
|
|
645
|
+
{children}
|
|
646
|
+
</LocalizationProvider>
|
|
647
|
+
```
|
|
306
648
|
|
|
307
|
-
|
|
308
|
-
+ NextIconButton: CustomButton,
|
|
309
|
-
}}
|
|
649
|
+
- The component slots `LeftArrowButton` and `RightArrowButton` have been renamed `PreviousIconButton` and `NextIconButton` to better describe there usage:
|
|
310
650
|
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
651
|
+
```diff
|
|
652
|
+
<DatePicker
|
|
653
|
+
components={{
|
|
654
|
+
- LeftArrowButton: CustomButton,
|
|
655
|
+
+ PreviousIconButton: CustomButton,
|
|
314
656
|
|
|
315
|
-
-
|
|
316
|
-
+
|
|
317
|
-
|
|
318
|
-
|
|
657
|
+
- RightArrowButton: CustomButton,
|
|
658
|
+
+ NextIconButton: CustomButton,
|
|
659
|
+
}}
|
|
660
|
+
componentsProps={{
|
|
661
|
+
- leftArrowButton: {},
|
|
662
|
+
+ previousIconButton: {},
|
|
663
|
+
|
|
664
|
+
- rightArrowButton: {},
|
|
665
|
+
+ nextIconButton: {},
|
|
666
|
+
}}
|
|
667
|
+
/>
|
|
319
668
|
```
|
|
320
669
|
|
|
321
670
|
- The `date` prop has been renamed `value` on `MonthPicker` / `YearPicker`, `ClockPicker` and `CalendarPicker`.
|
|
322
671
|
|
|
323
672
|
```diff
|
|
324
|
-
|
|
325
|
-
|
|
673
|
+
-<MonthPicker date={dayjs()} onChange={handleMonthChange} />
|
|
674
|
+
+<MonthPicker value={dayjs()} onChange={handleMonthChange} />
|
|
326
675
|
|
|
327
|
-
|
|
328
|
-
|
|
676
|
+
-<YearPicker date={dayjs()} onChange={handleYearChange} />
|
|
677
|
+
+<YearPicker value={dayjs()} onChange={handleYearChange} />
|
|
329
678
|
|
|
330
|
-
|
|
331
|
-
|
|
679
|
+
-<ClockPicker date={dayjs()} onChange={handleTimeChange} />
|
|
680
|
+
+<ClockPicker value={dayjs()} onChange={handleTimeChange} />
|
|
332
681
|
|
|
333
|
-
|
|
334
|
-
|
|
682
|
+
-<CalendarPicker date={dayjs()} onChange={handleDateChange} />
|
|
683
|
+
+<CalendarPicker value={dayjs()} onChange={handleDateChange} />
|
|
335
684
|
```
|
|
336
685
|
|
|
337
686
|
#### Changes
|
|
@@ -1775,10 +2124,10 @@ We'd like to offer a big thanks to the 15 contributors who made this release pos
|
|
|
1775
2124
|
| `filterableGridColumnsSelector` | `gridFilterableColumnDefinitionsSelector` |
|
|
1776
2125
|
|
|
1777
2126
|
```diff
|
|
1778
|
-
-const { all, lookup, columnVisibilityModel } = gridColumnsSelector(apiRef)
|
|
1779
|
-
+const all = gridColumnFieldsSelector(apiRef)
|
|
1780
|
-
+const lookup = gridColumnLookupSelector(apiRef)
|
|
1781
|
-
+const columnVisibilityModel = gridColumnVisibilityModelSelector(apiRef)
|
|
2127
|
+
-const { all, lookup, columnVisibilityModel } = gridColumnsSelector(apiRef);
|
|
2128
|
+
+const all = gridColumnFieldsSelector(apiRef);
|
|
2129
|
+
+const lookup = gridColumnLookupSelector(apiRef);
|
|
2130
|
+
+const columnVisibilityModel = gridColumnVisibilityModelSelector(apiRef);
|
|
1782
2131
|
|
|
1783
2132
|
-const filterableFields = filterableGridColumnsIdsSelector(apiRef);
|
|
1784
2133
|
+const lookup = gridFilterableColumnLookupSelector(apiRef);
|
|
@@ -2496,8 +2845,8 @@ _Nov 23, 2021_
|
|
|
2496
2845
|
|
|
2497
2846
|
🎉 We are excited to introduce [MUI X v5.0.0](https://mui.com/blog/mui-x-v5/) 🎉!
|
|
2498
2847
|
|
|
2499
|
-
If you want to migrate the DataGrid or DataGridPro from v4 to v5, take a look at the [migration guide](https://mui.com/x/
|
|
2500
|
-
This version is fully compatible with `@mui/material@5.X` and can be used with `@material-ui/core@4.x` with some [additional steps](https://mui.com/x/
|
|
2848
|
+
If you want to migrate the DataGrid or DataGridPro from v4 to v5, take a look at the [migration guide](https://mui.com/x/migration/migration-data-grid-v4/).
|
|
2849
|
+
This version is fully compatible with `@mui/material@5.X` and can be used with `@material-ui/core@4.x` with some [additional steps](https://mui.com/x/migration/migration-data-grid-v4/#using-mui-x-v5-with-mui-core-v4).
|
|
2501
2850
|
|
|
2502
2851
|
A big thanks to the 7 contributors who made this release possible. Here are some highlights ✨:
|
|
2503
2852
|
|
|
@@ -2715,7 +3064,7 @@ A big thanks to the 7 contributors who made this release possible. Here are some
|
|
|
2715
3064
|
|
|
2716
3065
|
```diff
|
|
2717
3066
|
-visibleSortedGridRowsAsArraySelector: (state: GridState) => [GridRowId, GridRowData][];
|
|
2718
|
-
+gridVisibleSortedRowEntriesSelector: (state: GridState) => GridRowEntry[]
|
|
3067
|
+
+gridVisibleSortedRowEntriesSelector: (state: GridState) => GridRowEntry[];
|
|
2719
3068
|
```
|
|
2720
3069
|
|
|
2721
3070
|
- [DataGridPro] The `filterGridItemsCounterSelector` selector was removed. (#2942) @flaviendelangle
|
|
@@ -2815,15 +3164,15 @@ A big thanks to the 5 contributors who made this release possible. Here are some
|
|
|
2815
3164
|
To fully control the state, use the feature's model prop and change callback (e.g. `filterModel` and `onFilterModelChange`).
|
|
2816
3165
|
|
|
2817
3166
|
```diff
|
|
2818
|
-
|
|
3167
|
+
<DataGrid
|
|
2819
3168
|
- state={{
|
|
2820
3169
|
+ initialState={{
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
|
|
3170
|
+
preferencePanel: {
|
|
3171
|
+
open: true,
|
|
3172
|
+
openedPanelValue: GridPreferencePanelsValue.filters,
|
|
3173
|
+
},
|
|
3174
|
+
}}
|
|
3175
|
+
/>
|
|
2827
3176
|
```
|
|
2828
3177
|
|
|
2829
3178
|
- [DataGridPro] Remove the `onViewportRowsChange` prop and the `viewportRowsChange` event (#2673) @m4theushw
|
|
@@ -2926,12 +3275,12 @@ A big thanks to the 7 contributors who made this release possible. Here are some
|
|
|
2926
3275
|
For more information, check [this page](https://mui.com/x/react-data-grid/components/#row). Example:
|
|
2927
3276
|
|
|
2928
3277
|
```diff
|
|
2929
|
-
|
|
2930
|
-
|
|
3278
|
+
<DataGrid
|
|
3279
|
+
- onRowOver={handleRowOver}
|
|
2931
3280
|
+ componentsProps={{
|
|
2932
3281
|
+ row: { onMouseOver: handleRowOver },
|
|
2933
3282
|
+ }}
|
|
2934
|
-
|
|
3283
|
+
/>;
|
|
2935
3284
|
```
|
|
2936
3285
|
|
|
2937
3286
|
The `data-rowindex` and `data-rowselected` attributes were removed from the cell element. Equivalent attributes can be found in the row element.
|
|
@@ -2963,33 +3312,33 @@ A big thanks to the 7 contributors who made this release possible. Here are some
|
|
|
2963
3312
|
- [DataGrid] The CSS classes constants are not exported anymore. Use `gridClasses` instead. (#2788) @flaviendelangle
|
|
2964
3313
|
|
|
2965
3314
|
```diff
|
|
2966
|
-
-const columnHeaderClass = GRID_COLUMN_HEADER_CSS_CLASS
|
|
2967
|
-
+const columnHeaderClass = gridClasses.columnHeader
|
|
3315
|
+
-const columnHeaderClass = GRID_COLUMN_HEADER_CSS_CLASS;
|
|
3316
|
+
+const columnHeaderClass = gridClasses.columnHeader;
|
|
2968
3317
|
|
|
2969
|
-
-const rowClass = GRID_ROW_CSS_CLASS
|
|
2970
|
-
+const rowClass = gridClasses.row
|
|
3318
|
+
-const rowClass = GRID_ROW_CSS_CLASS;
|
|
3319
|
+
+const rowClass = gridClasses.row;
|
|
2971
3320
|
|
|
2972
|
-
-const cellClass = GRID_CELL_CSS_CLASS
|
|
2973
|
-
+const cellClass = gridClasses.cell
|
|
3321
|
+
-const cellClass = GRID_CELL_CSS_CLASS;
|
|
3322
|
+
+const cellClass = gridClasses.cell;
|
|
2974
3323
|
|
|
2975
|
-
-const columnSeparatorClass = GRID_COLUMN_HEADER_SEPARATOR_RESIZABLE_CSS_CLASS
|
|
2976
|
-
+const columnSeparatorClass = gridClasses['columnSeparator--resizable']
|
|
3324
|
+
-const columnSeparatorClass = GRID_COLUMN_HEADER_SEPARATOR_RESIZABLE_CSS_CLASS;
|
|
3325
|
+
+const columnSeparatorClass = gridClasses['columnSeparator--resizable'];
|
|
2977
3326
|
|
|
2978
|
-
-const columnHeaderTitleClass = GRID_COLUMN_HEADER_TITLE_CSS_CLASS
|
|
2979
|
-
+const columnHeaderTitleClass = gridClasses.columnHeaderTitle
|
|
3327
|
+
-const columnHeaderTitleClass = GRID_COLUMN_HEADER_TITLE_CSS_CLASS;
|
|
3328
|
+
+const columnHeaderTitleClass = gridClasses.columnHeaderTitle;
|
|
2980
3329
|
|
|
2981
|
-
-const columnHeaderDropZoneClass = GRID_COLUMN_HEADER_DROP_ZONE_CSS_CLASS
|
|
2982
|
-
+const columnHeaderDropZoneClass = gridClasses.columnHeaderDropZone
|
|
3330
|
+
-const columnHeaderDropZoneClass = GRID_COLUMN_HEADER_DROP_ZONE_CSS_CLASS;
|
|
3331
|
+
+const columnHeaderDropZoneClass = gridClasses.columnHeaderDropZone;
|
|
2983
3332
|
|
|
2984
|
-
-const columnHeaderDraggingClass = GRID_COLUMN_HEADER_DRAGGING_CSS_CLASS
|
|
2985
|
-
+const columnHeaderDraggingClass = gridClasses[
|
|
3333
|
+
-const columnHeaderDraggingClass = GRID_COLUMN_HEADER_DRAGGING_CSS_CLASS;
|
|
3334
|
+
+const columnHeaderDraggingClass = gridClasses['columnHeader--dragging'];
|
|
2986
3335
|
```
|
|
2987
3336
|
|
|
2988
3337
|
- [DataGrid] Rename `gridCheckboxSelectionColDef` to `GRID_CHECKBOX_SELECTION_COL_DEF` (#2793) @flaviendelangle
|
|
2989
3338
|
|
|
2990
3339
|
```diff
|
|
2991
|
-
-
|
|
2992
|
-
+
|
|
3340
|
+
-gridCheckboxSelectionColDef
|
|
3341
|
+
+GRID_CHECKBOX_SELECTION_COL_DEF
|
|
2993
3342
|
```
|
|
2994
3343
|
|
|
2995
3344
|
- [DataGrid] The constants referring to the column types were removed (#2791) @flaviendelangle
|
|
@@ -3157,7 +3506,7 @@ A big thanks to the 5 contributors who made this release possible. Here are some
|
|
|
3157
3506
|
-export type GridValueFormatterParams = Omit<GridRenderCellParams, 'formattedValue' | 'isEditable'>;
|
|
3158
3507
|
+export interface GridValueFormatterParams {
|
|
3159
3508
|
+ /**
|
|
3160
|
-
+ * The column field of the cell that triggered the event
|
|
3509
|
+
+ * The column field of the cell that triggered the event.
|
|
3161
3510
|
+ */
|
|
3162
3511
|
+ field: string;
|
|
3163
3512
|
+ /**
|
|
@@ -3243,7 +3592,7 @@ A big thanks to the 9 contributors who made this release possible. Here are some
|
|
|
3243
3592
|
|
|
3244
3593
|
```diff
|
|
3245
3594
|
-const state = apiRef.current.getState();
|
|
3246
|
-
+const state = apiRef.current.state
|
|
3595
|
+
+const state = apiRef.current.state;
|
|
3247
3596
|
```
|
|
3248
3597
|
|
|
3249
3598
|
- [DataGridPro] The third argument in `apiRef.current.selectRow` is now inverted to keep consistency with other selection APIs. (#2523) @flaviendelangle
|
|
@@ -3537,16 +3886,15 @@ Big thanks to the 6 contributors who made this release possible. Here are some h
|
|
|
3537
3886
|
- The `width` property of the columns is no longer updated with the actual width of of the column. Use the new `computedWidth` property in the callbacks instead.
|
|
3538
3887
|
|
|
3539
3888
|
```diff
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
]
|
|
3889
|
+
const columns: GridColDef = [{
|
|
3890
|
+
field: 'name',
|
|
3891
|
+
width: 100,
|
|
3892
|
+
renderCell: ({ value, colDef }) => {
|
|
3893
|
+
- console.log(colDef.width!);
|
|
3894
|
+
+ console.log(colDef.computedWidth);
|
|
3895
|
+
return value;
|
|
3896
|
+
},
|
|
3897
|
+
}];
|
|
3550
3898
|
```
|
|
3551
3899
|
|
|
3552
3900
|
#### Changes
|
|
@@ -3609,21 +3957,21 @@ Big thanks to the 8 contributors who made this release possible. Here are some h
|
|
|
3609
3957
|
- Change the controllable API signature:
|
|
3610
3958
|
|
|
3611
3959
|
```diff
|
|
3612
|
-
|
|
3960
|
+
// Signature
|
|
3613
3961
|
-onPageChange?: (params: GridPageChangeParams) => void;
|
|
3614
3962
|
+onPageChange?: (page: number) => void;
|
|
3615
3963
|
|
|
3616
|
-
|
|
3964
|
+
// Usage
|
|
3617
3965
|
-<DataGrid onPageChange={(params: GridPageChangeParams) => setPage(params.page)} />
|
|
3618
3966
|
+<DataGrid onPageChange={(page: number) => setPage(page)} />
|
|
3619
3967
|
```
|
|
3620
3968
|
|
|
3621
3969
|
```diff
|
|
3622
|
-
|
|
3970
|
+
// Signature
|
|
3623
3971
|
-onPageSizeChange?: (params: GridPageChangeParams) => void;
|
|
3624
3972
|
+onPageSizeChange?: (pageSize: number) => void;
|
|
3625
3973
|
|
|
3626
|
-
|
|
3974
|
+
// Usage
|
|
3627
3975
|
-<DataGrid onPageSizeChange={(params: GridPageChangeParams) => setPageSize(params.pageSize)} />
|
|
3628
3976
|
+<DataGrid onPageSizeChange={(pageSize: number) => setPageSize(pageSize)} />
|
|
3629
3977
|
```
|
|
@@ -3681,7 +4029,7 @@ Big thanks to the 11 contributors who made this release possible. Here are some
|
|
|
3681
4029
|
Remove public `apiRef.current.isColumnVisibleInWindow()` as it servers private use cases.
|
|
3682
4030
|
|
|
3683
4031
|
```diff
|
|
3684
|
-
-apiRef.current.isColumnVisibleInWindow()
|
|
4032
|
+
-apiRef.current.isColumnVisibleInWindow();
|
|
3685
4033
|
```
|
|
3686
4034
|
|
|
3687
4035
|
- [DataGrid] Remove stateId argument from GridApi getState method (#2141) @flaviendelangle
|
|
@@ -3728,7 +4076,7 @@ Big thanks to the 11 contributors who made this release possible. Here are some
|
|
|
3728
4076
|
|
|
3729
4077
|
```diff
|
|
3730
4078
|
+apiRef.current.setCellMode(1, 'name', 'edit');
|
|
3731
|
-
|
|
4079
|
+
apiRef.current.commitCellChange({ id: 1, field: 'name' });
|
|
3732
4080
|
```
|
|
3733
4081
|
|
|
3734
4082
|
- The `setCellValue` was removed from the API. Use `commitCellChange` or `updateRows` in place.
|
|
@@ -4519,31 +4867,33 @@ Big thanks to the 5 contributors who made this release possible. Here are some h
|
|
|
4519
4867
|
|
|
4520
4868
|
- Changes on `apiRef.current`.
|
|
4521
4869
|
|
|
4522
|
-
```diff
|
|
4523
|
-
-
|
|
4524
|
-
+
|
|
4525
|
-
|
|
4526
|
-
|
|
4527
|
-
|
|
4528
|
-
|
|
4529
|
-
|
|
4530
|
-
|
|
4531
|
-
|
|
4532
|
-
|
|
4533
|
-
|
|
4534
|
-
|
|
4535
|
-
|
|
4536
|
-
|
|
4537
|
-
|
|
4538
|
-
|
|
4539
|
-
|
|
4540
|
-
|
|
4541
|
-
|
|
4542
|
-
|
|
4543
|
-
|
|
4544
|
-
|
|
4545
|
-
|
|
4546
|
-
|
|
4870
|
+
```diff
|
|
4871
|
+
-getRowModels: () => GridRowModel[];
|
|
4872
|
+
+getRowModels: () => Map<GridRowId, GridRowModel>;
|
|
4873
|
+
|
|
4874
|
+
-getVisibleRowModels: () => GridRowModel[];
|
|
4875
|
+
+getVisibleRowModels: () => Map<GridRowId, GridRowModel>;
|
|
4876
|
+
|
|
4877
|
+
-getSelectedRows: () => GridRowModel[];
|
|
4878
|
+
+getSelectedRows: () => Map<GridRowId, GridRowModel>;
|
|
4879
|
+
```
|
|
4880
|
+
|
|
4881
|
+
- Changes on `GridFilterModelParams`.
|
|
4882
|
+
|
|
4883
|
+
```diff
|
|
4884
|
+
export interface GridFilterModelParams {
|
|
4885
|
+
/**
|
|
4886
|
+
* The full set of rows.
|
|
4887
|
+
*/
|
|
4888
|
+
- rows: GridRowModel[];
|
|
4889
|
+
+ rows: Map<GridRowId, GridRowModel>;
|
|
4890
|
+
/**
|
|
4891
|
+
* The set of currently visible rows.
|
|
4892
|
+
*/
|
|
4893
|
+
- visibleRows: GridRowModel[];
|
|
4894
|
+
+ visibleRows: Map<GridRowId, GridRowModel>;
|
|
4895
|
+
}
|
|
4896
|
+
```
|
|
4547
4897
|
|
|
4548
4898
|
- [DataGrid] Upgrade mininum supported version of React to 17.0.0 (#1410) @m4theushw
|
|
4549
4899
|
|
|
@@ -4761,11 +5111,12 @@ Big thanks to the 4 contributors who made this release possible. Here are some h
|
|
|
4761
5111
|
```diff
|
|
4762
5112
|
-columns[1] = { ...columns[1], sortDirection: 'asc' };
|
|
4763
5113
|
|
|
4764
|
-
|
|
4765
|
-
|
|
5114
|
+
return (
|
|
5115
|
+
<div>
|
|
4766
5116
|
- <DataGrid rows={rows} columns={columns} />
|
|
4767
5117
|
+ <DataGrid rows={rows} columns={columns} sortModel={[{ field: columns[1].field, sort: 'asc' }]} />
|
|
4768
|
-
|
|
5118
|
+
</div>
|
|
5119
|
+
);
|
|
4769
5120
|
```
|
|
4770
5121
|
|
|
4771
5122
|
- [DataGrid] Rename the `onSelectionChange` prop to `onSelectionModelChange` for consistency. (#986) @dtassone
|
|
@@ -4792,10 +5143,11 @@ Big thanks to the 4 contributors who made this release possible. Here are some h
|
|
|
4792
5143
|
-const [page, setPage] = React.useState(1);
|
|
4793
5144
|
+const [page, setPage] = React.useState(0);
|
|
4794
5145
|
|
|
4795
|
-
|
|
4796
|
-
|
|
4797
|
-
|
|
4798
|
-
|
|
5146
|
+
return (
|
|
5147
|
+
<div className="grid-container">
|
|
5148
|
+
<DataGrid rows={rows} columns={columns} page={page} />
|
|
5149
|
+
</div>
|
|
5150
|
+
);
|
|
4799
5151
|
```
|
|
4800
5152
|
|
|
4801
5153
|
#### Changes
|
|
@@ -4896,25 +5248,25 @@ Big thanks to the 5 contributors who made this release possible. Here are some h
|
|
|
4896
5248
|
- Capitalize the keys of the `components` prop. This change aims to bring consistency with the customization pattern of Material UI v5:
|
|
4897
5249
|
|
|
4898
5250
|
```diff
|
|
4899
|
-
|
|
4900
|
-
|
|
4901
|
-
-
|
|
4902
|
-
+
|
|
4903
|
-
|
|
4904
|
-
|
|
5251
|
+
<DataGrid
|
|
5252
|
+
components={{
|
|
5253
|
+
- noRowsOverlay: CustomNoRowsOverlay,
|
|
5254
|
+
+ NoRowOverlay: CustomNoRowsOverlay,
|
|
5255
|
+
}}
|
|
5256
|
+
/>
|
|
4905
5257
|
```
|
|
4906
5258
|
|
|
4907
5259
|
- Move all the icon components overrides in the `components` prop. And added the suffix 'Icon' on each icon component. This change aims to bring consistency with the customization pattern of Material UI v5:
|
|
4908
5260
|
|
|
4909
5261
|
```diff
|
|
4910
|
-
|
|
4911
|
-
-
|
|
4912
|
-
-
|
|
4913
|
-
-
|
|
4914
|
-
+
|
|
4915
|
-
+
|
|
4916
|
-
+
|
|
4917
|
-
|
|
5262
|
+
<DataGrid
|
|
5263
|
+
- icons: {{
|
|
5264
|
+
- ColumnSortedAscending: SortedAscending,
|
|
5265
|
+
- }},
|
|
5266
|
+
+ components={{
|
|
5267
|
+
+ ColumnSortedAscendingIcon: SortedAscending,
|
|
5268
|
+
+ }}
|
|
5269
|
+
/>
|
|
4918
5270
|
```
|
|
4919
5271
|
|
|
4920
5272
|
- Change the props provided to the component of the `components` prop. Expose the whole state instead of an arbitrary set of props:
|
|
@@ -4932,9 +5284,9 @@ Big thanks to the 5 contributors who made this release possible. Here are some h
|
|
|
4932
5284
|
+ page={state.pagination.page}
|
|
4933
5285
|
+ count={state.pagination.pageCount}
|
|
4934
5286
|
|
|
4935
|
-
|
|
5287
|
+
// ...
|
|
4936
5288
|
|
|
4937
|
-
|
|
5289
|
+
<DataGrid components={{ Pagination: CustomPagination }} />
|
|
4938
5290
|
```
|
|
4939
5291
|
|
|
4940
5292
|
#### Changes
|