@mui/x-data-grid-premium 7.0.0 → 7.1.1
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 +246 -4
- package/DataGridPremium/DataGridPremium.js +7 -2
- package/README.md +1 -1
- package/esm/DataGridPremium/DataGridPremium.js +7 -2
- package/esm/hooks/features/aggregation/gridAggregationFunctions.js +4 -4
- package/esm/hooks/features/aggregation/wrapColumnWithAggregation.js +1 -6
- package/esm/utils/releaseInfo.js +1 -1
- package/hooks/features/aggregation/gridAggregationFunctions.d.ts +5 -5
- package/hooks/features/aggregation/gridAggregationFunctions.js +4 -4
- package/hooks/features/aggregation/gridAggregationInterfaces.d.ts +5 -8
- package/hooks/features/aggregation/wrapColumnWithAggregation.js +1 -6
- package/index.js +1 -1
- package/models/dataGridPremiumProps.d.ts +4 -9
- package/modern/DataGridPremium/DataGridPremium.js +7 -2
- package/modern/hooks/features/aggregation/gridAggregationFunctions.js +4 -4
- package/modern/hooks/features/aggregation/wrapColumnWithAggregation.js +1 -6
- package/modern/index.js +1 -1
- package/modern/utils/releaseInfo.js +1 -1
- package/package.json +5 -5
- package/utils/releaseInfo.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,179 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
##
|
|
6
|
+
## 7.1.1
|
|
7
|
+
|
|
8
|
+
_Apr 5, 2024_
|
|
9
|
+
|
|
10
|
+
We'd like to offer a big thanks to the 19 contributors who made this release possible. Here are some highlights ✨:
|
|
11
|
+
|
|
12
|
+
- 🚀 Add `setItemExpansion` Tree View API method (#12595) @flaviendelangle
|
|
13
|
+
- 🌍 Improve Persian (fa-IR), Portuguese (pt-BR), and Spanish (es-ES) locale on the Data Grid
|
|
14
|
+
- 🌍 Improve Persian (fa-IR), Portuguese (pt-BR), and Ukrainian (uk-UA) locale on the Pickers
|
|
15
|
+
- 🐞 Bugfixes
|
|
16
|
+
- 📚 Documentation improvements
|
|
17
|
+
|
|
18
|
+
### Data Grid
|
|
19
|
+
|
|
20
|
+
#### `@mui/x-data-grid@7.1.1`
|
|
21
|
+
|
|
22
|
+
- [DataGrid] Allow higher packages' props to be used in MIT (#12365) @MBilalShafi
|
|
23
|
+
- [DataGrid] Fix RTL mode (#12583) @romgrk
|
|
24
|
+
- [DataGrid] Fix `ColDefChangesGridNoSnap` demo crash (#12663) @MBilalShafi
|
|
25
|
+
- [DataGrid] Fix server-side filter demo not working (#12662) @MBilalShafi
|
|
26
|
+
- [DataGrid] Log error if `rowCount` is used with client-side pagination (#12448) @michelengelen
|
|
27
|
+
- [DataGrid] Remove `GridFormatterParams` completely (#12660) @romgrk
|
|
28
|
+
- [DataGrid] Restore main slot (#12657) @romgrk
|
|
29
|
+
- [l10n] Improve Persian (fa-IR) locale (#12630) @amirhosseinzf
|
|
30
|
+
- [l10n] Improve Portuguese (pt-BR) locale (#12618) @hugoalkimim
|
|
31
|
+
- [l10n] Improve Spanish (es-ES) locale (#12606) @aitor40
|
|
32
|
+
|
|
33
|
+
#### `@mui/x-data-grid-pro@7.1.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
34
|
+
|
|
35
|
+
Same changes as in `@mui/x-data-grid@7.1.1`.
|
|
36
|
+
|
|
37
|
+
#### `@mui/x-data-grid-premium@7.1.1` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
38
|
+
|
|
39
|
+
Same changes as in `@mui/x-data-grid-pro@7.1.1`.
|
|
40
|
+
|
|
41
|
+
### Date and Time Pickers
|
|
42
|
+
|
|
43
|
+
#### `@mui/x-date-pickers@7.1.1`
|
|
44
|
+
|
|
45
|
+
- [fields] Fix `readOnly` behavior (#12609) @LukasTy
|
|
46
|
+
- [l10n] Improve Persian (fa-IR) locale (#12632) @misafari
|
|
47
|
+
- [l10n] Improve Portuguese (pt-BR) locale (#12613) @cnHealth
|
|
48
|
+
- [l10n] Improve Ukrainian (uk-UA) locale (#12627) @alexkobylansky
|
|
49
|
+
|
|
50
|
+
#### `@mui/x-date-pickers-pro@7.1.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
51
|
+
|
|
52
|
+
Same changes as in `@mui/x-date-pickers@7.1.1`, plus:
|
|
53
|
+
|
|
54
|
+
- [DateTimeRangePicker] Fix selection on same day (#12604) @LukasTy
|
|
55
|
+
|
|
56
|
+
### Charts
|
|
57
|
+
|
|
58
|
+
#### `@mui/x-charts@7.1.1`
|
|
59
|
+
|
|
60
|
+
- [charts] Fix `tickInterval` usage for y-axis (#12592) @alexfauquette
|
|
61
|
+
- [charts] Fix Scatter series highlight when `id` is a `number` (#12677) @JCQuintas
|
|
62
|
+
- [charts] Fix TS error when using `sx` property on `ChartsTooltip` (#12659) @JCQuintas
|
|
63
|
+
|
|
64
|
+
### Tree View
|
|
65
|
+
|
|
66
|
+
#### `@mui/x-tree-view@7.1.1`
|
|
67
|
+
|
|
68
|
+
- [TreeView] Add JSDoc to all `publicAPI` methods (#12649) @flaviendelangle
|
|
69
|
+
- [TreeView] Create `RichTreeViewPro` component (not released yet) (#12610) @flaviendelangle
|
|
70
|
+
- [TreeView] Create pro package (not released yet) (#12240) @flaviendelangle
|
|
71
|
+
- [TreeView] Fix typo in errors (#12623) @alissa-tung
|
|
72
|
+
- [TreeView] New API method: `setItemExpansion` (#12595) @flaviendelangle
|
|
73
|
+
|
|
74
|
+
### Docs
|
|
75
|
+
|
|
76
|
+
- [docs] Add a recipe for the `checkboxSelectionVisibleOnly` prop (#12646) @michelengelen
|
|
77
|
+
- [docs] Explain the use of `_action: 'delete'` in `processRowUpdate` (#12670) @michelengelen
|
|
78
|
+
- [docs] Fix formatting and typo on migration guide @oliviertassinari
|
|
79
|
+
- [docs] Fix formatting in changelog @oliviertassinari
|
|
80
|
+
- [docs] Fix grammar in TreeView migration doc (#12615) @joshkel
|
|
81
|
+
- [docs] Fix missing closing props in `PieShapeNoSnap` demo (#12636) @alp-ex
|
|
82
|
+
- [docs] Fix type arguments in Custom Field page (#12619) @Juneezee
|
|
83
|
+
- [docs] Fix typo in `getItemId` prop description (#12637) @flaviendelangle
|
|
84
|
+
- [docs] Make the Charts `margin` usage more visible (#12591) @alexfauquette
|
|
85
|
+
- [docs] Match IE 11 spacing with Material UI @oliviertassinari
|
|
86
|
+
- [docs] Move data grid interfaces to standard API page layout (#12016) @alexfauquette
|
|
87
|
+
- [docs] Remove ` around @default values (#12158) @alexfauquette
|
|
88
|
+
- [docs] Remove `day` from the default `dayOfWeekFormatter` function params (#12644) @LukasTy
|
|
89
|
+
- [docs] Use `TreeItem2` for icon expansion example on `RichTreeView` (#12563) @flaviendelangle
|
|
90
|
+
|
|
91
|
+
### Core
|
|
92
|
+
|
|
93
|
+
- [core] Add cherry-pick `master` to `v6` action (#12648) @LukasTy
|
|
94
|
+
- [core] Fix typo in `@mui/x-tree-view-pro/themeAugmentation` (#12674) @flaviendelangle
|
|
95
|
+
- [core] Introduce `describeTreeView` to run test on `SimpleTreeView` and `RichTreeView`, using `TreeItem` and `TreeItem2` + migrate expansion tests (#12428) @flaviendelangle
|
|
96
|
+
- [core] Limit `test-types` CI step allowed memory (#12651) @LukasTy
|
|
97
|
+
- [core] Remove explicit `express` package (#12602) @LukasTy
|
|
98
|
+
- [core] Update to new embedded translations in the docs package (#12232) @Janpot
|
|
99
|
+
- [core] Use PR labels to identify the package a `l10n` PR belongs to (#12639) @LukasTy
|
|
100
|
+
- [core] Use `describeTreeView` for selection tests (#12647) @flaviendelangle
|
|
101
|
+
- [docs-infra] Adjust the links to search for issues (#11995) @michelengelen
|
|
102
|
+
- [infra] Polish support survey experience (#12624) @oliviertassinari
|
|
103
|
+
- [support-infra] Replace author association with a permission check in survey action (#12068) @michelengelen
|
|
104
|
+
- [support-infra] Fix user permission check (#12669) @michelengelen
|
|
105
|
+
- [test] Fix Tree View test import (#12668) @LukasTy
|
|
106
|
+
|
|
107
|
+
## 7.1.0
|
|
108
|
+
|
|
109
|
+
_Mar 28, 2024_
|
|
110
|
+
|
|
111
|
+
We'd like to offer a big thanks to the 10 contributors who made this release possible. Here are some highlights ✨:
|
|
112
|
+
|
|
113
|
+
- 🚀 Add `resizeThrottleMs` prop (#12556) @romgrk
|
|
114
|
+
- 🌍 Improve Chinese (Hong Kong) (zh-HK) and Italian (it-IT) locale on the Pickers
|
|
115
|
+
- 🐞 Bugfixes
|
|
116
|
+
- 📚 Documentation improvements
|
|
117
|
+
|
|
118
|
+
### Data Grid
|
|
119
|
+
|
|
120
|
+
#### `@mui/x-data-grid@7.1.0`
|
|
121
|
+
|
|
122
|
+
- [DataGrid] Add `resizeThrottleMs` prop (#12556) @romgrk
|
|
123
|
+
- [DataGrid] Do not publish `rowEditStop` event if row has fields with errors (#11383) @cherniavskii
|
|
124
|
+
- [DataGrid] Fix bug in suspense (#12553) @romgrk
|
|
125
|
+
- [DataGrid] Fix missing class name in the `GridToolbarQuickFilter` component (#12484) @jhawkins11
|
|
126
|
+
|
|
127
|
+
#### `@mui/x-data-grid-pro@7.1.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
128
|
+
|
|
129
|
+
Same changes as in `@mui/x-data-grid@7.1.0`.
|
|
130
|
+
|
|
131
|
+
#### `@mui/x-data-grid-premium@7.1.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
132
|
+
|
|
133
|
+
Same changes as in `@mui/x-data-grid-pro@7.1.0`.
|
|
134
|
+
|
|
135
|
+
### Date and Time Pickers
|
|
136
|
+
|
|
137
|
+
#### `@mui/x-date-pickers@7.1.0`
|
|
138
|
+
|
|
139
|
+
- [fields] Fix placeholder override (#12589) @flaviendelangle
|
|
140
|
+
- [l10n] Improve Chinese (Hong Kong) (zh-HK) locale (#12547) @samchiu90
|
|
141
|
+
- [l10n] Improve Italian (it-IT) locale (#12549) @antomanc
|
|
142
|
+
- [pickers] Prepare compatibility with `@mui/zero-runtime` (stop using `ownerState` in `styled`) (#12003) @flaviendelangle
|
|
143
|
+
|
|
144
|
+
#### `@mui/x-date-pickers-pro@7.1.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
145
|
+
|
|
146
|
+
Same changes as in `@mui/x-date-pickers@7.1.0`, plus:
|
|
147
|
+
|
|
148
|
+
- [DateRangePicker] Fix selection behavior with single input field when `readOnly` (#12593) @LukasTy
|
|
149
|
+
|
|
150
|
+
### Charts
|
|
151
|
+
|
|
152
|
+
#### `@mui/x-charts@7.1.0`
|
|
153
|
+
|
|
154
|
+
- [charts] Fix tooltip causing crash on data change (#12571) @Rishi556
|
|
155
|
+
|
|
156
|
+
### Tree View
|
|
157
|
+
|
|
158
|
+
#### `@mui/x-tree-view@7.1.0`
|
|
159
|
+
|
|
160
|
+
- [TreeView] Do not use outdated version of the state to compute new label first char in `RichTreeView` (#12512) @flaviendelangle
|
|
161
|
+
|
|
162
|
+
### Docs
|
|
163
|
+
|
|
164
|
+
- [docs] Add example to add a second icon next to the field's opening button (#12524) @flaviendelangle
|
|
165
|
+
- [docs] Add missing note to Data Grid migration guide (#12557) @romgrk
|
|
166
|
+
- [docs] Fix Charts title for SEO (#12545) @oliviertassinari
|
|
167
|
+
- [docs] Fix small typo (#12558) @diogoparente
|
|
168
|
+
- [docs] Improve codemod related documentation (#12582) @MBilalShafi
|
|
169
|
+
- [docs] Reduce noise in migration docs side navigation (#12552) @cherniavskii
|
|
170
|
+
- [docs] Sync static images from core repository (#12525) @LukasTy
|
|
171
|
+
|
|
172
|
+
### Core
|
|
173
|
+
|
|
174
|
+
- [core] Fix `l10n` script on Windows (#12550) @LukasTy
|
|
175
|
+
- [core] Include `DateTimeRangePicker` tag in `releaseChangelog` (#12526) @LukasTy
|
|
176
|
+
- [core] Upgrade monorepo (#12536) @cherniavskii
|
|
177
|
+
|
|
178
|
+
## 7.0.0
|
|
7
179
|
|
|
8
180
|
_Mar 22, 2024_
|
|
9
181
|
|
|
@@ -459,13 +631,13 @@ We'd like to offer a big thanks to the 10 contributors who made this release pos
|
|
|
459
631
|
|
|
460
632
|
- 🎁 Introduce a new DOM structure for the field components that provides a better accessibility
|
|
461
633
|
- 🚀 Simplify Data Grid DOM structure for improved performance (#12013) @romgrk
|
|
462
|
-
- 🕥 The support for
|
|
634
|
+
- 🕥 The support for IE 11 has been removed (#12151) @flaviendelangle
|
|
463
635
|
- 🐞 Bugfixes
|
|
464
636
|
- 📚 Documentation improvements
|
|
465
637
|
|
|
466
638
|
### Breaking changes
|
|
467
639
|
|
|
468
|
-
- The support for
|
|
640
|
+
- The support for IE 11 has been removed from all MUI X packages. The `legacy` bundle that used to support old browsers like IE 11 is no longer included.
|
|
469
641
|
|
|
470
642
|
### Data Grid
|
|
471
643
|
|
|
@@ -570,7 +742,7 @@ These components are no longer exported from `@mui/x-charts`:
|
|
|
570
742
|
|
|
571
743
|
### Tree View / `@mui/x-tree-view@7.0.0-beta.4`
|
|
572
744
|
|
|
573
|
-
- [TreeView] Stop using custom `findIndex` to support
|
|
745
|
+
- [TreeView] Stop using custom `findIndex` to support IE 11 (#12129) @flaviendelangle
|
|
574
746
|
|
|
575
747
|
### Docs
|
|
576
748
|
|
|
@@ -2800,6 +2972,76 @@ Here is an example of the renaming for the `<ChartsTooltip />` component.
|
|
|
2800
2972
|
- [core] Update release instructions as per v7 configuration (#10962) @MBilalShafi
|
|
2801
2973
|
- [license] Correctly throw errors (#10924) @oliviertassinari
|
|
2802
2974
|
|
|
2975
|
+
## 6.19.9
|
|
2976
|
+
|
|
2977
|
+
_Apr 5, 2024_
|
|
2978
|
+
|
|
2979
|
+
We'd like to offer a big thanks to the 3 contributors who made this release possible. Here are some highlights ✨:
|
|
2980
|
+
|
|
2981
|
+
- 🐞 Bugfixes
|
|
2982
|
+
- 📚 Documentation improvements
|
|
2983
|
+
|
|
2984
|
+
### Data Grid
|
|
2985
|
+
|
|
2986
|
+
#### `@mui/x-data-grid@6.19.9`
|
|
2987
|
+
|
|
2988
|
+
- [DataGrid] Remove legacy editing API event: `rowEditCommit` (#12087) @MBilalShafi
|
|
2989
|
+
|
|
2990
|
+
#### `@mui/x-data-grid-pro@6.19.9` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
2991
|
+
|
|
2992
|
+
Same changes as in `@mui/x-data-grid@6.19.9`.
|
|
2993
|
+
|
|
2994
|
+
#### `@mui/x-data-grid-premium@6.19.9` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
2995
|
+
|
|
2996
|
+
Same changes as in `@mui/x-data-grid-pro@6.19.9`.
|
|
2997
|
+
|
|
2998
|
+
### Date Pickers
|
|
2999
|
+
|
|
3000
|
+
#### `@mui/x-date-pickers@6.19.9`
|
|
3001
|
+
|
|
3002
|
+
No changes.
|
|
3003
|
+
|
|
3004
|
+
#### `@mui/x-date-pickers-pro@6.19.9` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
3005
|
+
|
|
3006
|
+
- [DateRangePicker] Fix selection behavior with single input field when `readOnly` (#12605) @LukasTy
|
|
3007
|
+
|
|
3008
|
+
### Docs
|
|
3009
|
+
|
|
3010
|
+
- [docs] Add a recipe for the `checkboxSelectionVisibleOnly` prop (#12667) @michelengelen
|
|
3011
|
+
- [docs] Explain the use of `_action: 'delete'` in `processRowUpdate` (#12673) @michelengelen
|
|
3012
|
+
|
|
3013
|
+
### Core
|
|
3014
|
+
|
|
3015
|
+
- [core] Use Circle CI context (#12607) @cherniavskii
|
|
3016
|
+
|
|
3017
|
+
## 6.19.8
|
|
3018
|
+
|
|
3019
|
+
_Mar 20, 2024_
|
|
3020
|
+
|
|
3021
|
+
We'd like to offer a big thanks to the 3 contributors who made this release possible.
|
|
3022
|
+
|
|
3023
|
+
### Data Grid
|
|
3024
|
+
|
|
3025
|
+
#### `@mui/x-data-grid@6.19.8`
|
|
3026
|
+
|
|
3027
|
+
- [DataGrid] Fix `ElementType` usage (#12505) @cherniavskii
|
|
3028
|
+
- [DataGrid] Fix cell value formatting on copy (#12483) @sai6855
|
|
3029
|
+
- [DataGrid] Fix checkbox selection when filtering (#12485) @g1mishra
|
|
3030
|
+
|
|
3031
|
+
#### `@mui/x-data-grid-pro@6.19.8` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
3032
|
+
|
|
3033
|
+
Same changes as in `@mui/x-data-grid@6.19.8`.
|
|
3034
|
+
|
|
3035
|
+
#### `@mui/x-data-grid-premium@6.19.8` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
3036
|
+
|
|
3037
|
+
Same changes as in `@mui/x-data-grid-pro@6.19.8`, plus:
|
|
3038
|
+
|
|
3039
|
+
- [DataGridPremium] Add support for confirmation before clipboard paste (#12466) @cherniavskii
|
|
3040
|
+
|
|
3041
|
+
### Docs
|
|
3042
|
+
|
|
3043
|
+
- [docs] Update links to v7 (#12495) @cherniavskii
|
|
3044
|
+
|
|
2803
3045
|
## 6.19.7
|
|
2804
3046
|
|
|
2805
3047
|
_Mar 14, 2024_
|
|
@@ -327,7 +327,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
327
327
|
* Determines the position of an aggregated value.
|
|
328
328
|
* @param {GridGroupNode} groupNode The current group.
|
|
329
329
|
* @returns {GridAggregationPosition | null} Position of the aggregated value (if `null`, the group isn't aggregated).
|
|
330
|
-
* @default
|
|
330
|
+
* @default (groupNode) => groupNode == null ? 'footer' : 'inline'
|
|
331
331
|
*/
|
|
332
332
|
getAggregationPosition: _propTypes.default.func,
|
|
333
333
|
/**
|
|
@@ -845,6 +845,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
845
845
|
* @returns {Promise<R> | R} The final values to update the row.
|
|
846
846
|
*/
|
|
847
847
|
processRowUpdate: _propTypes.default.func,
|
|
848
|
+
/**
|
|
849
|
+
* The milliseconds throttle delay for resizing the grid.
|
|
850
|
+
* @default 60
|
|
851
|
+
*/
|
|
852
|
+
resizeThrottleMs: _propTypes.default.number,
|
|
848
853
|
/**
|
|
849
854
|
* Row region in pixels to render before/after the viewport
|
|
850
855
|
* @default 150
|
|
@@ -962,7 +967,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
962
967
|
* The function is used to split the pasted text into rows and cells.
|
|
963
968
|
* @param {string} text The text pasted from the clipboard.
|
|
964
969
|
* @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
|
|
965
|
-
* @default
|
|
970
|
+
* @default (pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }
|
|
966
971
|
*/
|
|
967
972
|
splitClipboardPastedText: _propTypes.default.func,
|
|
968
973
|
/**
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# MUI X Data Grid Premium
|
|
2
2
|
|
|
3
|
-
This package is the Premium plan edition of the
|
|
3
|
+
This package is the Premium plan edition of the Data Grid components.
|
|
4
4
|
It's part of [MUI X](https://mui.com/x/), an open-core extension of MUI Core, with advanced components.
|
|
5
5
|
|
|
6
6
|
## Installation
|
|
@@ -320,7 +320,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
320
320
|
* Determines the position of an aggregated value.
|
|
321
321
|
* @param {GridGroupNode} groupNode The current group.
|
|
322
322
|
* @returns {GridAggregationPosition | null} Position of the aggregated value (if `null`, the group isn't aggregated).
|
|
323
|
-
* @default
|
|
323
|
+
* @default (groupNode) => groupNode == null ? 'footer' : 'inline'
|
|
324
324
|
*/
|
|
325
325
|
getAggregationPosition: PropTypes.func,
|
|
326
326
|
/**
|
|
@@ -838,6 +838,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
838
838
|
* @returns {Promise<R> | R} The final values to update the row.
|
|
839
839
|
*/
|
|
840
840
|
processRowUpdate: PropTypes.func,
|
|
841
|
+
/**
|
|
842
|
+
* The milliseconds throttle delay for resizing the grid.
|
|
843
|
+
* @default 60
|
|
844
|
+
*/
|
|
845
|
+
resizeThrottleMs: PropTypes.number,
|
|
841
846
|
/**
|
|
842
847
|
* Row region in pixels to render before/after the viewport
|
|
843
848
|
* @default 150
|
|
@@ -955,7 +960,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
955
960
|
* The function is used to split the pasted text into rows and cells.
|
|
956
961
|
* @param {string} text The text pasted from the clipboard.
|
|
957
962
|
* @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
|
|
958
|
-
* @default
|
|
963
|
+
* @default (pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }
|
|
959
964
|
*/
|
|
960
965
|
splitClipboardPastedText: PropTypes.func,
|
|
961
966
|
/**
|
|
@@ -76,11 +76,11 @@ const sizeAgg = {
|
|
|
76
76
|
}) => {
|
|
77
77
|
return values.filter(value => typeof value !== 'undefined').length;
|
|
78
78
|
},
|
|
79
|
-
valueFormatter:
|
|
80
|
-
if (
|
|
81
|
-
return
|
|
79
|
+
valueFormatter: value => {
|
|
80
|
+
if (value == null || !isNumber(value)) {
|
|
81
|
+
return value;
|
|
82
82
|
}
|
|
83
|
-
return
|
|
83
|
+
return value.toLocaleString();
|
|
84
84
|
},
|
|
85
85
|
hasCellUnit: false
|
|
86
86
|
};
|
|
@@ -39,12 +39,7 @@ const getAggregationValueWrappedValueFormatter = ({
|
|
|
39
39
|
if (rowId != null) {
|
|
40
40
|
const cellAggregationResult = getCellAggregationResult(rowId, column.field);
|
|
41
41
|
if (cellAggregationResult != null) {
|
|
42
|
-
return aggregationRule.aggregationFunction.valueFormatter?.(
|
|
43
|
-
id: rowId,
|
|
44
|
-
field: column.field,
|
|
45
|
-
value,
|
|
46
|
-
api: apiRef.current
|
|
47
|
-
});
|
|
42
|
+
return aggregationRule.aggregationFunction.valueFormatter?.(value, row, column, apiRef);
|
|
48
43
|
}
|
|
49
44
|
}
|
|
50
45
|
if (valueFormatter) {
|
package/esm/utils/releaseInfo.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export const getReleaseInfo = () => {
|
|
3
|
-
const releaseInfo = "
|
|
3
|
+
const releaseInfo = "MTcxMjI2NDQwMDAwMA==";
|
|
4
4
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
5
|
// A simple hack to set the value in the test environment (has no build step).
|
|
6
6
|
// eslint-disable-next-line no-useless-concat
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { GridAggregationFunction } from './gridAggregationInterfaces';
|
|
2
2
|
export declare const GRID_AGGREGATION_FUNCTIONS: {
|
|
3
|
-
sum: GridAggregationFunction<unknown, number
|
|
4
|
-
avg: GridAggregationFunction<unknown, number
|
|
5
|
-
min: GridAggregationFunction<number | Date, number | Date
|
|
6
|
-
max: GridAggregationFunction<number | Date, number | Date
|
|
7
|
-
size: GridAggregationFunction<unknown, number
|
|
3
|
+
sum: GridAggregationFunction<unknown, number>;
|
|
4
|
+
avg: GridAggregationFunction<unknown, number>;
|
|
5
|
+
min: GridAggregationFunction<number | Date, number | Date>;
|
|
6
|
+
max: GridAggregationFunction<number | Date, number | Date>;
|
|
7
|
+
size: GridAggregationFunction<unknown, number>;
|
|
8
8
|
};
|
|
@@ -82,11 +82,11 @@ const sizeAgg = {
|
|
|
82
82
|
}) => {
|
|
83
83
|
return values.filter(value => typeof value !== 'undefined').length;
|
|
84
84
|
},
|
|
85
|
-
valueFormatter:
|
|
86
|
-
if (
|
|
87
|
-
return
|
|
85
|
+
valueFormatter: value => {
|
|
86
|
+
if (value == null || !(0, _internals.isNumber)(value)) {
|
|
87
|
+
return value;
|
|
88
88
|
}
|
|
89
|
-
return
|
|
89
|
+
return value.toLocaleString();
|
|
90
90
|
},
|
|
91
91
|
hasCellUnit: false
|
|
92
92
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { GridRowId, GridRowModel, GridColDef, GridValueFormatter } from '@mui/x-data-grid-pro';
|
|
2
2
|
export interface GridAggregationState {
|
|
3
3
|
model: GridAggregationModel;
|
|
4
4
|
lookup: GridAggregationLookup;
|
|
@@ -28,7 +28,7 @@ export interface GridAggregationGetCellValueParams {
|
|
|
28
28
|
* @demos
|
|
29
29
|
* - [Aggregation functions](/x/react-data-grid/aggregation/#aggregation-functions)
|
|
30
30
|
*/
|
|
31
|
-
export interface GridAggregationFunction<V = any, AV = V
|
|
31
|
+
export interface GridAggregationFunction<V = any, AV = V> {
|
|
32
32
|
/**
|
|
33
33
|
* Function that takes the current cell values and generates the aggregated value.
|
|
34
34
|
* @template V, AV
|
|
@@ -39,7 +39,7 @@ export interface GridAggregationFunction<V = any, AV = V, FAV = AV> {
|
|
|
39
39
|
/**
|
|
40
40
|
* Label of the aggregation function.
|
|
41
41
|
* Will be used to add a label on the footer of the grouping column when this aggregation function is the only one being used.
|
|
42
|
-
* @default
|
|
42
|
+
* @default apiRef.current.getLocaleText('aggregationFunctionLabel{capitalize(name)})
|
|
43
43
|
*/
|
|
44
44
|
label?: string;
|
|
45
45
|
/**
|
|
@@ -50,15 +50,12 @@ export interface GridAggregationFunction<V = any, AV = V, FAV = AV> {
|
|
|
50
50
|
/**
|
|
51
51
|
* Function that allows to apply a formatter to the aggregated value.
|
|
52
52
|
* If not defined, the grid will use the formatter of the column.
|
|
53
|
-
* @template AV, F
|
|
54
|
-
* @param {GridValueFormatterParams<AV>} params Object containing parameters for the formatter.
|
|
55
|
-
* @returns {F} The formatted value.
|
|
56
53
|
*/
|
|
57
|
-
valueFormatter?:
|
|
54
|
+
valueFormatter?: GridValueFormatter;
|
|
58
55
|
/**
|
|
59
56
|
* Indicates if the aggregated value have the same unit as the cells used to generate it.
|
|
60
57
|
* It can be used to apply a custom cell renderer only if the aggregated value has the same unit.
|
|
61
|
-
* @default
|
|
58
|
+
* @default true
|
|
62
59
|
*/
|
|
63
60
|
hasCellUnit?: boolean;
|
|
64
61
|
/**
|
|
@@ -48,12 +48,7 @@ const getAggregationValueWrappedValueFormatter = ({
|
|
|
48
48
|
if (rowId != null) {
|
|
49
49
|
const cellAggregationResult = getCellAggregationResult(rowId, column.field);
|
|
50
50
|
if (cellAggregationResult != null) {
|
|
51
|
-
return aggregationRule.aggregationFunction.valueFormatter?.(
|
|
52
|
-
id: rowId,
|
|
53
|
-
field: column.field,
|
|
54
|
-
value,
|
|
55
|
-
api: apiRef.current
|
|
56
|
-
});
|
|
51
|
+
return aggregationRule.aggregationFunction.valueFormatter?.(value, row, column, apiRef);
|
|
57
52
|
}
|
|
58
53
|
}
|
|
59
54
|
if (valueFormatter) {
|
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { GridCallbackDetails, GridValidRowModel, GridGroupNode, GridEventListener } from '@mui/x-data-grid-pro';
|
|
3
|
-
import { GridExperimentalProFeatures, DataGridProPropsWithDefaultValue, DataGridProPropsWithoutDefaultValue, DataGridPropsWithComplexDefaultValueAfterProcessing, DataGridPropsWithComplexDefaultValueBeforeProcessing } from '@mui/x-data-grid-pro/internals';
|
|
3
|
+
import { GridExperimentalProFeatures, DataGridProPropsWithDefaultValue, DataGridProPropsWithoutDefaultValue, DataGridPropsWithComplexDefaultValueAfterProcessing, DataGridPropsWithComplexDefaultValueBeforeProcessing, DataGridPremiumSharedPropsWithDefaultValue } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { GridRowGroupingModel } from '../hooks/features/rowGrouping';
|
|
5
5
|
import type { GridAggregationModel, GridAggregationFunction, GridAggregationPosition } from '../hooks/features/aggregation';
|
|
6
6
|
import { GridPremiumSlotsComponent } from './gridPremiumSlotsComponent';
|
|
@@ -34,12 +34,7 @@ export type DataGridPremiumForcedPropsKey = 'signature';
|
|
|
34
34
|
* None of the entry of this interface should be optional, they all have default values and `DataGridProps` already applies a `Partial<DataGridSimpleOptions>` for the public interface.
|
|
35
35
|
* The controlled model do not have a default value at the prop processing level, so they must be defined in `DataGridOtherProps`.
|
|
36
36
|
*/
|
|
37
|
-
export interface DataGridPremiumPropsWithDefaultValue<R extends GridValidRowModel = any> extends DataGridProPropsWithDefaultValue<R
|
|
38
|
-
/**
|
|
39
|
-
* If `true`, the cell selection mode is enabled.
|
|
40
|
-
* @default false
|
|
41
|
-
*/
|
|
42
|
-
cellSelection: boolean;
|
|
37
|
+
export interface DataGridPremiumPropsWithDefaultValue<R extends GridValidRowModel = any> extends DataGridProPropsWithDefaultValue<R>, DataGridPremiumSharedPropsWithDefaultValue {
|
|
43
38
|
/**
|
|
44
39
|
* If `true`, aggregation is disabled.
|
|
45
40
|
* @default false
|
|
@@ -72,7 +67,7 @@ export interface DataGridPremiumPropsWithDefaultValue<R extends GridValidRowMode
|
|
|
72
67
|
* Determines the position of an aggregated value.
|
|
73
68
|
* @param {GridGroupNode} groupNode The current group.
|
|
74
69
|
* @returns {GridAggregationPosition | null} Position of the aggregated value (if `null`, the group isn't aggregated).
|
|
75
|
-
* @default
|
|
70
|
+
* @default (groupNode) => groupNode == null ? 'footer' : 'inline'
|
|
76
71
|
*/
|
|
77
72
|
getAggregationPosition: (groupNode: GridGroupNode) => GridAggregationPosition | null;
|
|
78
73
|
/**
|
|
@@ -84,7 +79,7 @@ export interface DataGridPremiumPropsWithDefaultValue<R extends GridValidRowMode
|
|
|
84
79
|
* The function is used to split the pasted text into rows and cells.
|
|
85
80
|
* @param {string} text The text pasted from the clipboard.
|
|
86
81
|
* @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
|
|
87
|
-
* @default
|
|
82
|
+
* @default (pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }
|
|
88
83
|
*/
|
|
89
84
|
splitClipboardPastedText: (text: string) => string[][] | null;
|
|
90
85
|
}
|
|
@@ -320,7 +320,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
320
320
|
* Determines the position of an aggregated value.
|
|
321
321
|
* @param {GridGroupNode} groupNode The current group.
|
|
322
322
|
* @returns {GridAggregationPosition | null} Position of the aggregated value (if `null`, the group isn't aggregated).
|
|
323
|
-
* @default
|
|
323
|
+
* @default (groupNode) => groupNode == null ? 'footer' : 'inline'
|
|
324
324
|
*/
|
|
325
325
|
getAggregationPosition: PropTypes.func,
|
|
326
326
|
/**
|
|
@@ -838,6 +838,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
838
838
|
* @returns {Promise<R> | R} The final values to update the row.
|
|
839
839
|
*/
|
|
840
840
|
processRowUpdate: PropTypes.func,
|
|
841
|
+
/**
|
|
842
|
+
* The milliseconds throttle delay for resizing the grid.
|
|
843
|
+
* @default 60
|
|
844
|
+
*/
|
|
845
|
+
resizeThrottleMs: PropTypes.number,
|
|
841
846
|
/**
|
|
842
847
|
* Row region in pixels to render before/after the viewport
|
|
843
848
|
* @default 150
|
|
@@ -955,7 +960,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
955
960
|
* The function is used to split the pasted text into rows and cells.
|
|
956
961
|
* @param {string} text The text pasted from the clipboard.
|
|
957
962
|
* @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
|
|
958
|
-
* @default
|
|
963
|
+
* @default (pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }
|
|
959
964
|
*/
|
|
960
965
|
splitClipboardPastedText: PropTypes.func,
|
|
961
966
|
/**
|
|
@@ -76,11 +76,11 @@ const sizeAgg = {
|
|
|
76
76
|
}) => {
|
|
77
77
|
return values.filter(value => typeof value !== 'undefined').length;
|
|
78
78
|
},
|
|
79
|
-
valueFormatter:
|
|
80
|
-
if (
|
|
81
|
-
return
|
|
79
|
+
valueFormatter: value => {
|
|
80
|
+
if (value == null || !isNumber(value)) {
|
|
81
|
+
return value;
|
|
82
82
|
}
|
|
83
|
-
return
|
|
83
|
+
return value.toLocaleString();
|
|
84
84
|
},
|
|
85
85
|
hasCellUnit: false
|
|
86
86
|
};
|
|
@@ -39,12 +39,7 @@ const getAggregationValueWrappedValueFormatter = ({
|
|
|
39
39
|
if (rowId != null) {
|
|
40
40
|
const cellAggregationResult = getCellAggregationResult(rowId, column.field);
|
|
41
41
|
if (cellAggregationResult != null) {
|
|
42
|
-
return aggregationRule.aggregationFunction.valueFormatter?.(
|
|
43
|
-
id: rowId,
|
|
44
|
-
field: column.field,
|
|
45
|
-
value,
|
|
46
|
-
api: apiRef.current
|
|
47
|
-
});
|
|
42
|
+
return aggregationRule.aggregationFunction.valueFormatter?.(value, row, column, apiRef);
|
|
48
43
|
}
|
|
49
44
|
}
|
|
50
45
|
if (valueFormatter) {
|
package/modern/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export const getReleaseInfo = () => {
|
|
3
|
-
const releaseInfo = "
|
|
3
|
+
const releaseInfo = "MTcxMjI2NDQwMDAwMA==";
|
|
4
4
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
5
|
// A simple hack to set the value in the test environment (has no build step).
|
|
6
6
|
// eslint-disable-next-line no-useless-concat
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/x-data-grid-premium",
|
|
3
|
-
"version": "7.
|
|
4
|
-
"description": "The Premium plan edition of the
|
|
3
|
+
"version": "7.1.1",
|
|
4
|
+
"description": "The Premium plan edition of the Data Grid Components (MUI X).",
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"main": "./index.js",
|
|
7
7
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -35,9 +35,9 @@
|
|
|
35
35
|
"@babel/runtime": "^7.24.0",
|
|
36
36
|
"@mui/system": "^5.15.14",
|
|
37
37
|
"@mui/utils": "^5.15.14",
|
|
38
|
-
"@mui/x-data-grid": "7.
|
|
39
|
-
"@mui/x-data-grid-pro": "7.
|
|
40
|
-
"@mui/x-license": "7.
|
|
38
|
+
"@mui/x-data-grid": "7.1.1",
|
|
39
|
+
"@mui/x-data-grid-pro": "7.1.1",
|
|
40
|
+
"@mui/x-license": "7.1.1",
|
|
41
41
|
"@types/format-util": "^1.0.4",
|
|
42
42
|
"clsx": "^2.1.0",
|
|
43
43
|
"exceljs": "^4.4.0",
|
package/utils/releaseInfo.js
CHANGED
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.getReleaseInfo = void 0;
|
|
7
7
|
var _utils = require("@mui/utils");
|
|
8
8
|
const getReleaseInfo = () => {
|
|
9
|
-
const releaseInfo = "
|
|
9
|
+
const releaseInfo = "MTcxMjI2NDQwMDAwMA==";
|
|
10
10
|
if (process.env.NODE_ENV !== 'production') {
|
|
11
11
|
// A simple hack to set the value in the test environment (has no build step).
|
|
12
12
|
// eslint-disable-next-line no-useless-concat
|