@mui/x-data-grid-premium 8.0.0-beta.1 → 8.0.0-beta.3
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 +235 -0
- package/DataGridPremium/DataGridPremium.js +25 -17
- package/components/GridDataSourceGroupingCriteriaCell.js +2 -2
- package/components/export/ExportExcel.js +4 -129
- package/esm/DataGridPremium/DataGridPremium.js +25 -17
- package/esm/components/GridDataSourceGroupingCriteriaCell.js +2 -2
- package/esm/components/export/ExportExcel.js +4 -129
- package/esm/hooks/features/aggregation/gridAggregationUtils.js +2 -1
- package/esm/hooks/features/aggregation/useGridAggregation.js +4 -4
- package/esm/hooks/features/cellSelection/useGridCellSelection.js +6 -6
- package/esm/hooks/features/clipboard/useGridClipboardImport.js +4 -4
- package/esm/hooks/features/dataSource/useGridDataSourcePremium.js +1 -1
- package/esm/hooks/features/export/useGridExcelExport.js +2 -2
- package/esm/hooks/features/rowGrouping/useGridRowGrouping.js +5 -5
- package/esm/index.js +1 -1
- package/esm/utils/releaseInfo.js +1 -1
- package/hooks/features/aggregation/gridAggregationUtils.js +2 -1
- package/hooks/features/aggregation/useGridAggregation.js +3 -3
- package/hooks/features/cellSelection/useGridCellSelection.js +5 -5
- package/hooks/features/clipboard/useGridClipboardImport.js +3 -3
- package/hooks/features/dataSource/useGridDataSourcePremium.js +1 -1
- package/hooks/features/export/useGridExcelExport.js +1 -1
- package/hooks/features/rowGrouping/useGridRowGrouping.js +4 -4
- package/index.js +1 -1
- package/modern/DataGridPremium/DataGridPremium.js +25 -17
- package/modern/components/GridDataSourceGroupingCriteriaCell.js +2 -2
- package/modern/components/export/ExportExcel.js +4 -129
- package/modern/hooks/features/aggregation/gridAggregationUtils.js +2 -1
- package/modern/hooks/features/aggregation/useGridAggregation.js +4 -4
- package/modern/hooks/features/cellSelection/useGridCellSelection.js +6 -6
- package/modern/hooks/features/clipboard/useGridClipboardImport.js +4 -4
- package/modern/hooks/features/dataSource/useGridDataSourcePremium.js +1 -1
- package/modern/hooks/features/export/useGridExcelExport.js +2 -2
- package/modern/hooks/features/rowGrouping/useGridRowGrouping.js +5 -5
- package/modern/index.js +1 -1
- package/modern/utils/releaseInfo.js +1 -1
- package/package.json +9 -9
- package/tsconfig.build.tsbuildinfo +1 -1
- package/utils/releaseInfo.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,241 @@
|
|
|
5
5
|
All notable changes to this project will be documented in this file.
|
|
6
6
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
7
7
|
|
|
8
|
+
## 8.0.0-beta.3
|
|
9
|
+
|
|
10
|
+
_Apr 3, 2025_
|
|
11
|
+
|
|
12
|
+
We'd like to offer a big thanks to the 12 contributors who made this release possible. Here are some highlights ✨:
|
|
13
|
+
|
|
14
|
+
- 🚫 Removed `react-spring` as a dependency of `@mui/x-charts`
|
|
15
|
+
- 📦 Data Grid list view feature is now stable
|
|
16
|
+
- 💫 Support title in Data Grid
|
|
17
|
+
- 📚 Documentation improvements
|
|
18
|
+
- 🐞 Bugfixes
|
|
19
|
+
|
|
20
|
+
Team members who have contributed to this release:
|
|
21
|
+
@bernardobelchior, @cherniavskii, @flaviendelangle, @JCQuintas, @KenanYusuf, @LukasTy, @MBilalShafi, @michelengelen, @oliviertassinari, @noraleonte, @romgrk, @alexfauquette.
|
|
22
|
+
|
|
23
|
+
<!--/ HIGHLIGHT_ABOVE_SEPARATOR /-->
|
|
24
|
+
|
|
25
|
+
### Data Grid
|
|
26
|
+
|
|
27
|
+
#### Breaking changes
|
|
28
|
+
|
|
29
|
+
- The list view feature and its related props are now stable.
|
|
30
|
+
|
|
31
|
+
The `unstable_listColumn` prop has been renamed to `listViewColumn`.
|
|
32
|
+
|
|
33
|
+
The `GridListColDef` type has been renamed to `GridListViewColDef`.
|
|
34
|
+
|
|
35
|
+
```diff
|
|
36
|
+
-const listViewColDef: GridListColDef = {
|
|
37
|
+
+const listViewColDef: GridListViewColDef = {
|
|
38
|
+
field: 'listColumn',
|
|
39
|
+
renderCell: ListViewCell,
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
<DataGridPro
|
|
43
|
+
- unstable_listView
|
|
44
|
+
- unstable_listColumn={listViewColDef}
|
|
45
|
+
+ listView
|
|
46
|
+
+ listViewColumn={listViewColDef}
|
|
47
|
+
/>
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
- The `useGridApiEventHandler()` hook has been renamed to `useGridEvent()`.
|
|
51
|
+
- The `useGridApiOptionHandler()` hook has been renamed to `useGridEventPriority()`.
|
|
52
|
+
|
|
53
|
+
#### `@mui/x-data-grid@8.0.0-beta.3`
|
|
54
|
+
|
|
55
|
+
- [DataGrid] Fix "is any of" autocomplete rendering (#17226) @KenanYusuf
|
|
56
|
+
- [DataGrid] Rename `useGridApiEventHandler()` to `useGridEvent()` (#17159) @romgrk
|
|
57
|
+
- [DataGrid] Support adding a label to the grid (#17147) @KenanYusuf
|
|
58
|
+
- [DataGrid] Refactor: remove material typings (#17119) @romgrk
|
|
59
|
+
|
|
60
|
+
#### `@mui/x-data-grid-pro@8.0.0-beta.3` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
61
|
+
|
|
62
|
+
Same changes as in `@mui/x-data-grid@8.0.0-beta.3`, plus:
|
|
63
|
+
|
|
64
|
+
- [DataGridPro] Make list view feature stable (#17217) @KenanYusuf
|
|
65
|
+
- [DataGridPro] Always refetch lazy-loading rows (#16827) @MBilalShafi
|
|
66
|
+
|
|
67
|
+
#### `@mui/x-data-grid-premium@8.0.0-beta.3` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
68
|
+
|
|
69
|
+
Same changes as in `@mui/x-data-grid-pro@8.0.0-beta.3`.
|
|
70
|
+
|
|
71
|
+
### Date and Time Pickers
|
|
72
|
+
|
|
73
|
+
#### `@mui/x-date-pickers@8.0.0-beta.3`
|
|
74
|
+
|
|
75
|
+
- [pickers] Add new `nextOrAccept` action bar action (#17037) @flaviendelangle
|
|
76
|
+
- [pickers] Improve the Multi Section Digital Clock scrollbar thickness (#16774) @oliviertassinari
|
|
77
|
+
- [TimePicker] Align the Digital Clock scrollbar thickness (#17203) @LukasTy
|
|
78
|
+
|
|
79
|
+
#### `@mui/x-date-pickers-pro@8.0.0-beta.3` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
80
|
+
|
|
81
|
+
Same changes as in `@mui/x-date-pickers@8.0.0-beta.3`.
|
|
82
|
+
|
|
83
|
+
### Charts
|
|
84
|
+
|
|
85
|
+
#### Breaking changes
|
|
86
|
+
|
|
87
|
+
- Removed `react-spring` as a dependency of `@mui/x-charts`.
|
|
88
|
+
A consequence of this change is that the props of some slots have been changed because the `SpringValue` wrapper has been removed. The affected slots and props are:
|
|
89
|
+
|
|
90
|
+
- the type of the `x`, `y`, `width` and `height` props of the `bar` slot are now `number`;
|
|
91
|
+
- the type of `startAngle`, `endAngle`, `innerRadius`, `outerRadius`, `arcLabelRadius`, `cornerRadius` and `paddingAngle` props of `pieArc` and `pieArcLabel` slot are now `number`.
|
|
92
|
+
|
|
93
|
+
Additionally, the `pieArc` slot now receives a `skipAnimation` prop to configure whether animations should be enabled or disabled.
|
|
94
|
+
|
|
95
|
+
- Tick labels in the y-axis of cartesian charts will now have an ellipsis applied to prevent overflow.
|
|
96
|
+
If your tick labels are being clipped sooner than you would like, you can increase the y-axis size by increasing its width property.
|
|
97
|
+
|
|
98
|
+
- The tooltip DOM structure is modified to improve accessibility. If you relied on it to apply some style or run tests, you might be impacted by this modification.
|
|
99
|
+
- The axis tooltip displays a table per axis with the axis value in a caption.
|
|
100
|
+
- Cells containing the series label and the color mark got merged in a th cell.
|
|
101
|
+
|
|
102
|
+
#### `@mui/x-charts@8.0.0-beta.3`
|
|
103
|
+
|
|
104
|
+
- [charts] Adjust color palettes (#17209) @noraleonte
|
|
105
|
+
- [charts] Allow multiple axes in the tooltip (#17058) @alexfauquette
|
|
106
|
+
- [charts] Improve custom legend docs (#17231) @JCQuintas
|
|
107
|
+
- [charts] Fix crash when item shown in tooltip is unmounted (#17169) @bernardobelchior
|
|
108
|
+
- [charts] Migrate some animations from `react-spring` (#16961) @bernardobelchior
|
|
109
|
+
- [charts] Remove `react-spring` (#17123) @bernardobelchior
|
|
110
|
+
- [charts] Fix y-axis tick label overflow (#16846) @bernardobelchior
|
|
111
|
+
|
|
112
|
+
#### `@mui/x-charts-pro@8.0.0-beta.3` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
113
|
+
|
|
114
|
+
Same changes as in `@mui/x-charts@8.0.0-beta.3`.
|
|
115
|
+
|
|
116
|
+
### Tree View
|
|
117
|
+
|
|
118
|
+
#### `@mui/x-tree-view@8.0.0-beta.3`
|
|
119
|
+
|
|
120
|
+
Internal changes.
|
|
121
|
+
|
|
122
|
+
#### `@mui/x-tree-view-pro@8.0.0-beta.3` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
123
|
+
|
|
124
|
+
Same changes as in `@mui/x-tree-view@8.0.0-beta.3`.
|
|
125
|
+
|
|
126
|
+
### `@mui/x-codemod@8.0.0-beta.3`
|
|
127
|
+
|
|
128
|
+
- [codemod] Add `listView` prop rename codemod (#17220) @MBilalShafi
|
|
129
|
+
|
|
130
|
+
### Docs
|
|
131
|
+
|
|
132
|
+
- [docs] Add "Usage with Material UI v5/v6" guide (#17164) @cherniavskii
|
|
133
|
+
- [docs] Fix 301 link @oliviertassinari
|
|
134
|
+
- [docs] Fix redirection getting-started (#17200) @oliviertassinari
|
|
135
|
+
- [docs] Sync Stack Overflow docs with reality (#17198) @oliviertassinari
|
|
136
|
+
- [docs] Update Localization Provider JSDoc link (#17207) @LukasTy
|
|
137
|
+
|
|
138
|
+
### Core
|
|
139
|
+
|
|
140
|
+
- [core] Cleanup `@mui` dependency versions (#17160) @LukasTy
|
|
141
|
+
- [core] Sync scorecards.yml across codebase @oliviertassinari
|
|
142
|
+
- [core] Revert upgrade to React 19.1 (#17206) @bernardobelchior
|
|
143
|
+
- [code-infra] Fix `test:unit` warning (#17224) @JCQuintas
|
|
144
|
+
- [code-infra] Fix pickers failing test after clock=fake removal (#17202) @JCQuintas
|
|
145
|
+
- [code-infra] Remove clock=fake from `describeValidation` (#17150) @JCQuintas
|
|
146
|
+
- [code-infra] Remove clock=fake from `describeValue` (#17199) @JCQuintas
|
|
147
|
+
- [infra] Add write permission for actions in issue status label handler (#17161) @michelengelen
|
|
148
|
+
|
|
149
|
+
## 8.0.0-beta.2
|
|
150
|
+
|
|
151
|
+
_Mar 27, 2025_
|
|
152
|
+
|
|
153
|
+
We'd like to offer a big thanks to the 12 contributors who made this release possible. Here are some highlights ✨:
|
|
154
|
+
|
|
155
|
+
- 🔍 Update the Data Grid quick filter to be collapsed when not in use
|
|
156
|
+
- 🐞 Bugfixes
|
|
157
|
+
|
|
158
|
+
Special thanks go out to the community members for their valuable contributions:
|
|
159
|
+
@lhilgert9.
|
|
160
|
+
Following are all team members who have contributed to this release:
|
|
161
|
+
@alexfauquette, @arminmeh, @flaviendelangle, @hasdfa, @JCQuintas, @KenanYusuf, @LukasTy, @MBilalShafi, @michelengelen, @mnajdova, @romgrk.
|
|
162
|
+
|
|
163
|
+
<!--/ HIGHLIGHT_ABOVE_SEPARATOR /-->
|
|
164
|
+
|
|
165
|
+
### Data Grid
|
|
166
|
+
|
|
167
|
+
#### `@mui/x-data-grid@8.0.0-beta.2`
|
|
168
|
+
|
|
169
|
+
- [DataGrid] Fix error caused by trying to render rows that are not in the state anymore (#17057) @arminmeh
|
|
170
|
+
- [DataGrid] Refactor: remove more material (#16922) @romgrk
|
|
171
|
+
- [DataGrid] Update Quick Filter component to be expandable (#16862) @KenanYusuf
|
|
172
|
+
- [DataGrid] Fix crash when used with `@mui/styled-engine-sc` (#17154) @KenanYusuf
|
|
173
|
+
|
|
174
|
+
#### `@mui/x-data-grid-pro@8.0.0-beta.2` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
175
|
+
|
|
176
|
+
Same changes as in `@mui/x-data-grid@8.0.0-beta.2`, plus:
|
|
177
|
+
|
|
178
|
+
- [DataGridPro] Data source: Allow expanding groups with unknown children (#17144) @MBilalShafi
|
|
179
|
+
|
|
180
|
+
#### `@mui/x-data-grid-premium@8.0.0-beta.2` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
181
|
+
|
|
182
|
+
Same changes as in `@mui/x-data-grid-pro@8.0.0-beta.2`.
|
|
183
|
+
|
|
184
|
+
### Date and Time Pickers
|
|
185
|
+
|
|
186
|
+
#### `@mui/x-date-pickers@8.0.0-beta.2`
|
|
187
|
+
|
|
188
|
+
- [fields] Extract the props of each field slot into a standalone hook for easier re-use (#17114) @flaviendelangle
|
|
189
|
+
- [pickers] Fix visual regression in Date Range Calendar's day (#17148) @flaviendelangle
|
|
190
|
+
- [pickers] Remove all code duplication to apply default values to validation props (#17038) @flaviendelangle
|
|
191
|
+
|
|
192
|
+
#### `@mui/x-date-pickers-pro@8.0.0-beta.2` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
193
|
+
|
|
194
|
+
Same changes as in `@mui/x-date-pickers@8.0.0-beta.2`.
|
|
195
|
+
|
|
196
|
+
### Charts
|
|
197
|
+
|
|
198
|
+
#### `@mui/x-charts@8.0.0-beta.2`
|
|
199
|
+
|
|
200
|
+
- [charts] Memoize axes and series with default (#17156) @alexfauquette
|
|
201
|
+
- [charts] Add pie benchmark (#17115) @JCQuintas
|
|
202
|
+
- [charts] Fix CSS vars support for dark theme (#17106) @alexfauquette
|
|
203
|
+
- [charts] Fix radar hover (#17134) @alexfauquette
|
|
204
|
+
- [charts] Move axis interaction to selectors (#17039) @alexfauquette
|
|
205
|
+
- [charts] Fix Pie benchmark (#17125) @JCQuintas
|
|
206
|
+
|
|
207
|
+
#### `@mui/x-charts-pro@8.0.0-beta.2` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
208
|
+
|
|
209
|
+
Same changes as in `@mui/x-charts@8.0.0-beta.2`.
|
|
210
|
+
|
|
211
|
+
### Tree View
|
|
212
|
+
|
|
213
|
+
#### `@mui/x-tree-view@8.0.0-beta.2`
|
|
214
|
+
|
|
215
|
+
Internal changes.
|
|
216
|
+
|
|
217
|
+
#### `@mui/x-tree-view-pro@8.0.0-beta.2` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
218
|
+
|
|
219
|
+
Same changes as in `@mui/x-tree-view@8.0.0-beta.2`.
|
|
220
|
+
|
|
221
|
+
### `@mui/x-codemod@8.0.0-beta.1`
|
|
222
|
+
|
|
223
|
+
- [codemod] Add Data Grid codemods (#17121, #17124) @MBilalShafi
|
|
224
|
+
|
|
225
|
+
### Docs
|
|
226
|
+
|
|
227
|
+
- [docs] Fix example import for `ExportExcel` component (#17110) @KenanYusuf
|
|
228
|
+
|
|
229
|
+
### Core
|
|
230
|
+
|
|
231
|
+
- [code-infra] Remove `@mui/styles` dependency & patches (#17071) @mnajdova
|
|
232
|
+
- [code-infra] Add more tests to slow screenshot tests (#17075) @JCQuintas
|
|
233
|
+
- [code-infra] Fix pickers codecov (#17120) @JCQuintas
|
|
234
|
+
- [code-infra] Move `isDeepEqual` to @mui/x-internals (#17129) @JCQuintas
|
|
235
|
+
- [code-infra] Remove `test_regressions` step from React 18 pipeline (#17108) @LukasTy
|
|
236
|
+
- [code-infra] Update some data-grid tests for vitest (#17078, #17104, #17146) @JCQuintas
|
|
237
|
+
- [code-infra] Update some date-pickers tests for vitest (#17083) @JCQuintas
|
|
238
|
+
- [infra] Update `issue-status-label-handler.yml` @michelengelen
|
|
239
|
+
- [infra] Added reusable issue status label handler workflow (#17145) @michelengelen
|
|
240
|
+
- [infra] Switch to reusable 'stale issues/PRs' workflow (#17107) @michelengelen
|
|
241
|
+
- [telemetry] Improve request body size, update dependencies, and optimize SSR handling (#17008) @hasdfa
|
|
242
|
+
|
|
8
243
|
## 8.0.0-beta.1
|
|
9
244
|
|
|
10
245
|
_Mar 21, 2025_
|
|
@@ -86,11 +86,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
86
86
|
current: _propTypes.default.object
|
|
87
87
|
}),
|
|
88
88
|
/**
|
|
89
|
-
* The label of the Data Grid.
|
|
89
|
+
* The `aria-label` of the Data Grid.
|
|
90
90
|
*/
|
|
91
91
|
'aria-label': _propTypes.default.string,
|
|
92
92
|
/**
|
|
93
|
-
* The id of the element containing a label for the Data Grid.
|
|
93
|
+
* The `id` of the element containing a label for the Data Grid.
|
|
94
94
|
*/
|
|
95
95
|
'aria-labelledby': _propTypes.default.string,
|
|
96
96
|
/**
|
|
@@ -152,6 +152,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
152
152
|
* Override or extend the styles applied to the component.
|
|
153
153
|
*/
|
|
154
154
|
classes: _propTypes.default.object,
|
|
155
|
+
className: _propTypes.default.string,
|
|
155
156
|
/**
|
|
156
157
|
* The character used to separate cell values when copying to the clipboard.
|
|
157
158
|
* @default '\t'
|
|
@@ -514,6 +515,12 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
514
515
|
* @default false
|
|
515
516
|
*/
|
|
516
517
|
keepNonExistentRowsSelected: _propTypes.default.bool,
|
|
518
|
+
/**
|
|
519
|
+
* The label of the Data Grid.
|
|
520
|
+
* If the `showToolbar` prop is `true`, the label will be displayed in the toolbar and applied to the `aria-label` attribute of the grid.
|
|
521
|
+
* If the `showToolbar` prop is `false`, the label will not be visible but will be applied to the `aria-label` attribute of the grid.
|
|
522
|
+
*/
|
|
523
|
+
label: _propTypes.default.string,
|
|
517
524
|
/**
|
|
518
525
|
* Used together with `dataSource` to enable lazy loading.
|
|
519
526
|
* If enabled, the grid stops adding `paginationModel` to the data requests (`getRows`)
|
|
@@ -526,6 +533,21 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
526
533
|
* @default 500
|
|
527
534
|
*/
|
|
528
535
|
lazyLoadingRequestThrottleMs: _propTypes.default.number,
|
|
536
|
+
/**
|
|
537
|
+
* If `true`, displays the data in a list view.
|
|
538
|
+
* Use in combination with `listViewColumn`.
|
|
539
|
+
*/
|
|
540
|
+
listView: _propTypes.default.bool,
|
|
541
|
+
/**
|
|
542
|
+
* Definition of the column rendered when the `listView` prop is enabled.
|
|
543
|
+
*/
|
|
544
|
+
listViewColumn: _propTypes.default.shape({
|
|
545
|
+
align: _propTypes.default.oneOf(['center', 'left', 'right']),
|
|
546
|
+
cellClassName: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.string]),
|
|
547
|
+
display: _propTypes.default.oneOf(['flex', 'text']),
|
|
548
|
+
field: _propTypes.default.string.isRequired,
|
|
549
|
+
renderCell: _propTypes.default.func
|
|
550
|
+
}),
|
|
529
551
|
/**
|
|
530
552
|
* If `true`, a loading overlay is displayed.
|
|
531
553
|
* @default false
|
|
@@ -1077,6 +1099,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
1077
1099
|
* @default (pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }
|
|
1078
1100
|
*/
|
|
1079
1101
|
splitClipboardPastedText: _propTypes.default.func,
|
|
1102
|
+
style: _propTypes.default.object,
|
|
1080
1103
|
/**
|
|
1081
1104
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
1082
1105
|
*/
|
|
@@ -1092,21 +1115,6 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
1092
1115
|
* @default false
|
|
1093
1116
|
*/
|
|
1094
1117
|
treeData: _propTypes.default.bool,
|
|
1095
|
-
/**
|
|
1096
|
-
* Definition of the column rendered when the `unstable_listView` prop is enabled.
|
|
1097
|
-
*/
|
|
1098
|
-
unstable_listColumn: _propTypes.default.shape({
|
|
1099
|
-
align: _propTypes.default.oneOf(['center', 'left', 'right']),
|
|
1100
|
-
cellClassName: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.string]),
|
|
1101
|
-
display: _propTypes.default.oneOf(['flex', 'text']),
|
|
1102
|
-
field: _propTypes.default.string.isRequired,
|
|
1103
|
-
renderCell: _propTypes.default.func
|
|
1104
|
-
}),
|
|
1105
|
-
/**
|
|
1106
|
-
* If `true`, displays the data in a list view.
|
|
1107
|
-
* Use in combination with `unstable_listColumn`.
|
|
1108
|
-
*/
|
|
1109
|
-
unstable_listView: _propTypes.default.bool,
|
|
1110
1118
|
/**
|
|
1111
1119
|
* If `true`, the Data Grid enables column virtualization when `getRowHeight` is set to `() => 'auto'`.
|
|
1112
1120
|
* By default, column virtualization is disabled when dynamic row height is enabled to measure the row height correctly.
|
|
@@ -57,7 +57,7 @@ function GridGroupingCriteriaCellIcon(props) {
|
|
|
57
57
|
})
|
|
58
58
|
});
|
|
59
59
|
}
|
|
60
|
-
return descendantCount > 0 ? /*#__PURE__*/(0, _jsxRuntime.jsx)(rootProps.slots.baseIconButton, (0, _extends2.default)({
|
|
60
|
+
return descendantCount === -1 || descendantCount > 0 ? /*#__PURE__*/(0, _jsxRuntime.jsx)(rootProps.slots.baseIconButton, (0, _extends2.default)({
|
|
61
61
|
size: "small",
|
|
62
62
|
onClick: handleClick,
|
|
63
63
|
tabIndex: -1,
|
|
@@ -90,7 +90,7 @@ function GridDataSourceGroupingCriteriaCell(props) {
|
|
|
90
90
|
const classes = useUtilityClasses(rootProps);
|
|
91
91
|
let descendantCount = 0;
|
|
92
92
|
if (row) {
|
|
93
|
-
descendantCount =
|
|
93
|
+
descendantCount = rootProps.dataSource?.getChildrenCount?.(row) ?? 0;
|
|
94
94
|
}
|
|
95
95
|
let cellContent;
|
|
96
96
|
const colDef = apiRef.current.getColumn(rowNode.groupingField);
|
|
@@ -55,113 +55,9 @@ process.env.NODE_ENV !== "production" ? ExportExcel.propTypes = {
|
|
|
55
55
|
// | These PropTypes are generated from the TypeScript type definitions |
|
|
56
56
|
// | To update them edit the TypeScript types and run "pnpm proptypes" |
|
|
57
57
|
// ----------------------------------------------------------------------
|
|
58
|
-
/**
|
|
59
|
-
* A ref for imperative actions.
|
|
60
|
-
* It currently only supports `focusVisible()` action.
|
|
61
|
-
*/
|
|
62
|
-
action: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.shape({
|
|
63
|
-
current: _propTypes.default.shape({
|
|
64
|
-
focusVisible: _propTypes.default.func.isRequired
|
|
65
|
-
})
|
|
66
|
-
})]),
|
|
67
|
-
/**
|
|
68
|
-
* If `true`, the ripples are centered.
|
|
69
|
-
* They won't start at the cursor interaction position.
|
|
70
|
-
* @default false
|
|
71
|
-
*/
|
|
72
|
-
centerRipple: _propTypes.default.bool,
|
|
73
58
|
className: _propTypes.default.string,
|
|
74
|
-
/**
|
|
75
|
-
* The color of the component.
|
|
76
|
-
* It supports both default and custom theme colors, which can be added as shown in the
|
|
77
|
-
* [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).
|
|
78
|
-
* @default 'primary'
|
|
79
|
-
*/
|
|
80
|
-
color: _propTypes.default.oneOf(['error', 'info', 'inherit', 'primary', 'secondary', 'success', 'warning']),
|
|
81
|
-
component: _propTypes.default.elementType,
|
|
82
|
-
/**
|
|
83
|
-
* If `true`, the component is disabled.
|
|
84
|
-
*/
|
|
85
59
|
disabled: _propTypes.default.bool,
|
|
86
|
-
|
|
87
|
-
* If `true`, no elevation is used.
|
|
88
|
-
* @default false
|
|
89
|
-
*/
|
|
90
|
-
disableElevation: _propTypes.default.bool,
|
|
91
|
-
/**
|
|
92
|
-
* If `true`, the keyboard focus ripple is disabled.
|
|
93
|
-
* @default false
|
|
94
|
-
*/
|
|
95
|
-
disableFocusRipple: _propTypes.default.bool,
|
|
96
|
-
/**
|
|
97
|
-
* If `true`, the ripple effect is disabled.
|
|
98
|
-
*
|
|
99
|
-
* ⚠️ Without a ripple there is no styling for :focus-visible by default. Be sure
|
|
100
|
-
* to highlight the element by applying separate styles with the `.Mui-focusVisible` class.
|
|
101
|
-
* @default false
|
|
102
|
-
*/
|
|
103
|
-
disableRipple: _propTypes.default.bool,
|
|
104
|
-
/**
|
|
105
|
-
* If `true`, the touch ripple effect is disabled.
|
|
106
|
-
* @default false
|
|
107
|
-
*/
|
|
108
|
-
disableTouchRipple: _propTypes.default.bool,
|
|
109
|
-
/**
|
|
110
|
-
* Element placed after the children.
|
|
111
|
-
*/
|
|
112
|
-
endIcon: _propTypes.default.node,
|
|
113
|
-
/**
|
|
114
|
-
* If `true`, the base button will have a keyboard focus ripple.
|
|
115
|
-
* @default false
|
|
116
|
-
*/
|
|
117
|
-
focusRipple: _propTypes.default.bool,
|
|
118
|
-
/**
|
|
119
|
-
* This prop can help identify which element has keyboard focus.
|
|
120
|
-
* The class name will be applied when the element gains the focus through keyboard interaction.
|
|
121
|
-
* It's a polyfill for the [CSS :focus-visible selector](https://drafts.csswg.org/selectors-4/#the-focus-visible-pseudo).
|
|
122
|
-
* The rationale for using this feature [is explained here](https://github.com/WICG/focus-visible/blob/HEAD/explainer.md).
|
|
123
|
-
* A [polyfill can be used](https://github.com/WICG/focus-visible) to apply a `focus-visible` class to other components
|
|
124
|
-
* if needed.
|
|
125
|
-
*/
|
|
126
|
-
focusVisibleClassName: _propTypes.default.string,
|
|
127
|
-
/**
|
|
128
|
-
* If `true`, the button will take up the full width of its container.
|
|
129
|
-
* @default false
|
|
130
|
-
*/
|
|
131
|
-
fullWidth: _propTypes.default.bool,
|
|
132
|
-
/**
|
|
133
|
-
* The URL to link to when the button is clicked.
|
|
134
|
-
* If defined, an `a` element will be used as the root node.
|
|
135
|
-
*/
|
|
136
|
-
href: _propTypes.default.string,
|
|
137
|
-
/**
|
|
138
|
-
* The component used to render a link when the `href` prop is provided.
|
|
139
|
-
* @default 'a'
|
|
140
|
-
*/
|
|
141
|
-
LinkComponent: _propTypes.default.elementType,
|
|
142
|
-
/**
|
|
143
|
-
* If `true`, the loading indicator is visible and the button is disabled.
|
|
144
|
-
* If `true | false`, the loading wrapper is always rendered before the children to prevent [Google Translation Crash](https://github.com/mui/material-ui/issues/27853).
|
|
145
|
-
* @default null
|
|
146
|
-
*/
|
|
147
|
-
loading: _propTypes.default.bool,
|
|
148
|
-
/**
|
|
149
|
-
* Element placed before the children if the button is in loading state.
|
|
150
|
-
* The node should contain an element with `role="progressbar"` with an accessible name.
|
|
151
|
-
* By default, it renders a `CircularProgress` that is labeled by the button itself.
|
|
152
|
-
* @default <CircularProgress color="inherit" size={16} />
|
|
153
|
-
*/
|
|
154
|
-
loadingIndicator: _propTypes.default.node,
|
|
155
|
-
/**
|
|
156
|
-
* The loading indicator can be positioned on the start, end, or the center of the button.
|
|
157
|
-
* @default 'center'
|
|
158
|
-
*/
|
|
159
|
-
loadingPosition: _propTypes.default.oneOf(['center', 'end', 'start']),
|
|
160
|
-
/**
|
|
161
|
-
* Callback fired when the component is focused with a keyboard.
|
|
162
|
-
* We trigger a `onFocus` callback too.
|
|
163
|
-
*/
|
|
164
|
-
onFocusVisible: _propTypes.default.func,
|
|
60
|
+
id: _propTypes.default.string,
|
|
165
61
|
/**
|
|
166
62
|
* The options to apply on the Excel export.
|
|
167
63
|
* @demos
|
|
@@ -185,32 +81,11 @@ process.env.NODE_ENV !== "production" ? ExportExcel.propTypes = {
|
|
|
185
81
|
* A function to customize rendering of the component.
|
|
186
82
|
*/
|
|
187
83
|
render: _propTypes.default.oneOfType([_propTypes.default.element, _propTypes.default.func]),
|
|
188
|
-
|
|
189
|
-
* The size of the component.
|
|
190
|
-
* `small` is equivalent to the dense button styling.
|
|
191
|
-
*/
|
|
84
|
+
role: _propTypes.default.string,
|
|
192
85
|
size: _propTypes.default.oneOf(['large', 'medium', 'small']),
|
|
193
|
-
/**
|
|
194
|
-
* Element placed before the children.
|
|
195
|
-
*/
|
|
196
86
|
startIcon: _propTypes.default.node,
|
|
197
87
|
style: _propTypes.default.object,
|
|
198
|
-
/**
|
|
199
|
-
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
200
|
-
*/
|
|
201
|
-
sx: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object, _propTypes.default.bool])), _propTypes.default.func, _propTypes.default.object]),
|
|
202
88
|
tabIndex: _propTypes.default.number,
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
*/
|
|
206
|
-
TouchRippleProps: _propTypes.default.object,
|
|
207
|
-
/**
|
|
208
|
-
* A ref that points to the `TouchRipple` element.
|
|
209
|
-
*/
|
|
210
|
-
touchRippleRef: _propTypes.default.any,
|
|
211
|
-
/**
|
|
212
|
-
* The variant to use.
|
|
213
|
-
* @default 'text'
|
|
214
|
-
*/
|
|
215
|
-
variant: _propTypes.default.oneOf(['contained', 'outlined', 'text'])
|
|
89
|
+
title: _propTypes.default.string,
|
|
90
|
+
touchRippleRef: _propTypes.default.any
|
|
216
91
|
} : void 0;
|
|
@@ -79,11 +79,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
79
79
|
current: PropTypes.object
|
|
80
80
|
}),
|
|
81
81
|
/**
|
|
82
|
-
* The label of the Data Grid.
|
|
82
|
+
* The `aria-label` of the Data Grid.
|
|
83
83
|
*/
|
|
84
84
|
'aria-label': PropTypes.string,
|
|
85
85
|
/**
|
|
86
|
-
* The id of the element containing a label for the Data Grid.
|
|
86
|
+
* The `id` of the element containing a label for the Data Grid.
|
|
87
87
|
*/
|
|
88
88
|
'aria-labelledby': PropTypes.string,
|
|
89
89
|
/**
|
|
@@ -145,6 +145,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
145
145
|
* Override or extend the styles applied to the component.
|
|
146
146
|
*/
|
|
147
147
|
classes: PropTypes.object,
|
|
148
|
+
className: PropTypes.string,
|
|
148
149
|
/**
|
|
149
150
|
* The character used to separate cell values when copying to the clipboard.
|
|
150
151
|
* @default '\t'
|
|
@@ -507,6 +508,12 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
507
508
|
* @default false
|
|
508
509
|
*/
|
|
509
510
|
keepNonExistentRowsSelected: PropTypes.bool,
|
|
511
|
+
/**
|
|
512
|
+
* The label of the Data Grid.
|
|
513
|
+
* If the `showToolbar` prop is `true`, the label will be displayed in the toolbar and applied to the `aria-label` attribute of the grid.
|
|
514
|
+
* If the `showToolbar` prop is `false`, the label will not be visible but will be applied to the `aria-label` attribute of the grid.
|
|
515
|
+
*/
|
|
516
|
+
label: PropTypes.string,
|
|
510
517
|
/**
|
|
511
518
|
* Used together with `dataSource` to enable lazy loading.
|
|
512
519
|
* If enabled, the grid stops adding `paginationModel` to the data requests (`getRows`)
|
|
@@ -519,6 +526,21 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
519
526
|
* @default 500
|
|
520
527
|
*/
|
|
521
528
|
lazyLoadingRequestThrottleMs: PropTypes.number,
|
|
529
|
+
/**
|
|
530
|
+
* If `true`, displays the data in a list view.
|
|
531
|
+
* Use in combination with `listViewColumn`.
|
|
532
|
+
*/
|
|
533
|
+
listView: PropTypes.bool,
|
|
534
|
+
/**
|
|
535
|
+
* Definition of the column rendered when the `listView` prop is enabled.
|
|
536
|
+
*/
|
|
537
|
+
listViewColumn: PropTypes.shape({
|
|
538
|
+
align: PropTypes.oneOf(['center', 'left', 'right']),
|
|
539
|
+
cellClassName: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
|
|
540
|
+
display: PropTypes.oneOf(['flex', 'text']),
|
|
541
|
+
field: PropTypes.string.isRequired,
|
|
542
|
+
renderCell: PropTypes.func
|
|
543
|
+
}),
|
|
522
544
|
/**
|
|
523
545
|
* If `true`, a loading overlay is displayed.
|
|
524
546
|
* @default false
|
|
@@ -1070,6 +1092,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
1070
1092
|
* @default (pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }
|
|
1071
1093
|
*/
|
|
1072
1094
|
splitClipboardPastedText: PropTypes.func,
|
|
1095
|
+
style: PropTypes.object,
|
|
1073
1096
|
/**
|
|
1074
1097
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
1075
1098
|
*/
|
|
@@ -1085,21 +1108,6 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
1085
1108
|
* @default false
|
|
1086
1109
|
*/
|
|
1087
1110
|
treeData: PropTypes.bool,
|
|
1088
|
-
/**
|
|
1089
|
-
* Definition of the column rendered when the `unstable_listView` prop is enabled.
|
|
1090
|
-
*/
|
|
1091
|
-
unstable_listColumn: PropTypes.shape({
|
|
1092
|
-
align: PropTypes.oneOf(['center', 'left', 'right']),
|
|
1093
|
-
cellClassName: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
|
|
1094
|
-
display: PropTypes.oneOf(['flex', 'text']),
|
|
1095
|
-
field: PropTypes.string.isRequired,
|
|
1096
|
-
renderCell: PropTypes.func
|
|
1097
|
-
}),
|
|
1098
|
-
/**
|
|
1099
|
-
* If `true`, displays the data in a list view.
|
|
1100
|
-
* Use in combination with `unstable_listColumn`.
|
|
1101
|
-
*/
|
|
1102
|
-
unstable_listView: PropTypes.bool,
|
|
1103
1111
|
/**
|
|
1104
1112
|
* If `true`, the Data Grid enables column virtualization when `getRowHeight` is set to `() => 'auto'`.
|
|
1105
1113
|
* By default, column virtualization is disabled when dynamic row height is enabled to measure the row height correctly.
|
|
@@ -49,7 +49,7 @@ function GridGroupingCriteriaCellIcon(props) {
|
|
|
49
49
|
})
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
|
-
return descendantCount > 0 ? /*#__PURE__*/_jsx(rootProps.slots.baseIconButton, _extends({
|
|
52
|
+
return descendantCount === -1 || descendantCount > 0 ? /*#__PURE__*/_jsx(rootProps.slots.baseIconButton, _extends({
|
|
53
53
|
size: "small",
|
|
54
54
|
onClick: handleClick,
|
|
55
55
|
tabIndex: -1,
|
|
@@ -82,7 +82,7 @@ export function GridDataSourceGroupingCriteriaCell(props) {
|
|
|
82
82
|
const classes = useUtilityClasses(rootProps);
|
|
83
83
|
let descendantCount = 0;
|
|
84
84
|
if (row) {
|
|
85
|
-
descendantCount =
|
|
85
|
+
descendantCount = rootProps.dataSource?.getChildrenCount?.(row) ?? 0;
|
|
86
86
|
}
|
|
87
87
|
let cellContent;
|
|
88
88
|
const colDef = apiRef.current.getColumn(rowNode.groupingField);
|