@mui/x-data-grid-premium 6.6.0 → 6.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,78 @@
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.0
7
+
8
+ _Jun 9, 2023_
9
+
10
+ We'd like to offer a big thanks to the 12 contributors who made this release possible. Here are some highlights ✨:
11
+
12
+ - 🎁 Improve the default `format` prop value on the pickers.
13
+
14
+ Here are a few examples:
15
+
16
+ ```tsx
17
+ <TimePicker views={['hours', 'minutes', 'seconds']} ampm />
18
+ // Format before v6.7.0: `hh:mm aa`
19
+ // Format after v6.7.0: `hh:mm:ss aa`
20
+
21
+ <DatePicker views={['year']} />
22
+ // Format before v6.7.0: `MM/DD/YYYY`
23
+ // Format after v6.7.0: `YYYY`
24
+
25
+ <DateTimePicker views={['day', 'hours', 'minutes']} ampm />
26
+ // Format before v6.7.0: `MM/DD/YYYY hh:mm aa`
27
+ // Format after v6.7.0: `DD hh:mm aa`
28
+ ```
29
+
30
+ - 🌍 Add Romanian (ro-RO) locale on the pickers
31
+ - 🌍 Improve German (de-DE) locale on the pickers
32
+ - 🌍 Improve Czech (cs-CZ), German (de-DE) and Turkish (tr-TR) locales on the data grid
33
+ - 🚀 Performance improvements
34
+ - 🐞 Bugfixes
35
+ - 📚 Documentation improvements
36
+
37
+ ### `@mui/x-data-grid@v6.7.0` / `@mui/x-data-grid-pro@v6.7.0` / `@mui/x-data-grid-premium@v6.7.0`
38
+
39
+ #### Changes
40
+
41
+ - [DataGrid] Allow overflowing grid root element (#9179) @cherniavskii
42
+ - [DataGrid] Fix module augmentation error when using `@mui/lab` (#9235) @cherniavskii
43
+ - [DataGrid] Fix row with ids matching `Object` prototype (#9265) @romgrk
44
+ - [DataGrid] Fix `sortModel` and `filterModel` resetting when columns change (#9239) @alexgonch
45
+ - [DataGrid] Improve grouping performance for large datasets (#9200) @romgrk
46
+ - [DataGrid] Increase threshold to trigger memory leak warning (#9263) @m4theushw
47
+ - [DataGrid] Update data grid migration guide to include updated type (#9272) @MBilalShafi
48
+ - [DataGridPro] Improve header filter menu visuals (#9181) @MBilalShafi
49
+ - [DataGridPremium] Remove last line break on clipboard paste (#9163) @cherniavskii
50
+ - [l10n] Improve Czech (cs-CZ) locale (#9266) @MartinSkarpa
51
+ - [l10n] Improve German (de-DE) locale (#9259) @ximex
52
+ - [l10n] Improve Turkish (tr-TR) locale (#9237) @MCErtan
53
+
54
+ ### `@mui/x-date-pickers@v6.7.0` / `@mui/x-date-pickers-pro@v6.7.0`
55
+
56
+ #### Changes
57
+
58
+ - [l10n] Add Romanian (ro-RO) locale (#9257) @ximex
59
+ - [l10n] Improve German (de-DE) locale (#9258) @ximex
60
+ - [pickers] Apply dynamic default format depending on views for all desktop and mobile pickers (#9126) @flaviendelangle
61
+ - [pickers] Update `DateRangePickerDay` props JSDoc (#9191) @stevus
62
+
63
+ ### Docs
64
+
65
+ - [docs] Fix missing props on the `GridFilterPanel` API page (#9180) @cherniavskii
66
+ - [docs] Fix overview page typo (#9230) @LukasTy
67
+ - [docs] Fix version redirect (#9273) @alexfauquette
68
+
69
+ ### Core
70
+
71
+ - [core] Temporarily remove the Argos upload on the regression testing (#9267) @flaviendelangle
72
+ - [charts] Add clip-path to avoid charts overflow (#9012) @alexfauquette
73
+ - [charts] Add style customization on bar (#8935) @alexfauquette
74
+ - [charts] Enforce axis `min`/`max` over the `nice()` method (#9189) @alexfauquette
75
+ - [charts] Improve axis label and ticks label alignements (#9190) @alexfauquette
76
+ - [charts] Simplify the switch between responsive and fix dimensions (#9151) @alexfauquette
77
+
6
78
  ## 6.6.0
7
79
 
8
80
  _Jun 1, 2023_
@@ -940,7 +940,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
940
940
  * The function is used to split the pasted text into rows and cells.
941
941
  * @param {string} text The text pasted from the clipboard.
942
942
  * @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
943
- * @default `(text) => text.split(/\r\n|\n|\r/).map((row) => row.split('\t'))`
943
+ * @default `(pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }`
944
944
  */
945
945
  unstable_splitClipboardPastedText: PropTypes.func
946
946
  } : void 0;
@@ -18,7 +18,12 @@ export const DATA_GRID_PREMIUM_PROPS_DEFAULT_VALUES = _extends({}, DATA_GRID_PRO
18
18
  aggregationRowsScope: 'filtered',
19
19
  getAggregationPosition: groupNode => groupNode.depth === -1 ? 'footer' : 'inline',
20
20
  disableClipboardPaste: false,
21
- unstable_splitClipboardPastedText: text => text.split(/\r\n|\n|\r/).map(row => row.split('\t'))
21
+ unstable_splitClipboardPastedText: pastedText => {
22
+ // Excel on Windows adds an empty line break at the end of the copied text.
23
+ // See https://github.com/mui/mui-x/issues/9103
24
+ const text = pastedText.replace(/\r?\n$/, '');
25
+ return text.split(/\r\n|\n|\r/).map(row => row.split('\t'));
26
+ }
22
27
  });
23
28
  const defaultSlots = uncapitalizeObjectKeys(DATA_GRID_PREMIUM_DEFAULT_SLOTS_COMPONENTS);
24
29
  export const useDataGridPremiumProps = inProps => {
@@ -92,12 +92,7 @@ export const addFooterRows = ({
92
92
  depth: groupNode ? groupNode.depth + 1 : 0,
93
93
  type: 'footer'
94
94
  };
95
- insertNodeInTree({
96
- previousTree: null,
97
- node: footerNode,
98
- tree: newGroupingParams.tree,
99
- treeDepths: newGroupingParams.treeDepths
100
- });
95
+ insertNodeInTree(footerNode, newGroupingParams.tree, newGroupingParams.treeDepths, null);
101
96
  }
102
97
  } else if (groupNode.footerId != null) {
103
98
  removeNodeFromTree({
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.6.0
2
+ * @mui/x-data-grid-premium v6.7.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -940,7 +940,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
940
940
  * The function is used to split the pasted text into rows and cells.
941
941
  * @param {string} text The text pasted from the clipboard.
942
942
  * @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
943
- * @default `(text) => text.split(/\r\n|\n|\r/).map((row) => row.split('\t'))`
943
+ * @default `(pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }`
944
944
  */
945
945
  unstable_splitClipboardPastedText: PropTypes.func
946
946
  } : void 0;
@@ -21,7 +21,10 @@ export var DATA_GRID_PREMIUM_PROPS_DEFAULT_VALUES = _extends({}, DATA_GRID_PRO_P
21
21
  return groupNode.depth === -1 ? 'footer' : 'inline';
22
22
  },
23
23
  disableClipboardPaste: false,
24
- unstable_splitClipboardPastedText: function unstable_splitClipboardPastedText(text) {
24
+ unstable_splitClipboardPastedText: function unstable_splitClipboardPastedText(pastedText) {
25
+ // Excel on Windows adds an empty line break at the end of the copied text.
26
+ // See https://github.com/mui/mui-x/issues/9103
27
+ var text = pastedText.replace(/\r?\n$/, '');
25
28
  return text.split(/\r\n|\n|\r/).map(function (row) {
26
29
  return row.split('\t');
27
30
  });
@@ -100,12 +100,7 @@ export var addFooterRows = function addFooterRows(_ref6) {
100
100
  depth: groupNode ? groupNode.depth + 1 : 0,
101
101
  type: 'footer'
102
102
  };
103
- insertNodeInTree({
104
- previousTree: null,
105
- node: footerNode,
106
- tree: newGroupingParams.tree,
107
- treeDepths: newGroupingParams.treeDepths
108
- });
103
+ insertNodeInTree(footerNode, newGroupingParams.tree, newGroupingParams.treeDepths, null);
109
104
  }
110
105
  } else if (groupNode.footerId != null) {
111
106
  removeNodeFromTree({
package/legacy/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.6.0
2
+ * @mui/x-data-grid-premium v6.7.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -1,6 +1,6 @@
1
1
  import { ponyfillGlobal } from '@mui/utils';
2
2
  export var getReleaseInfo = function getReleaseInfo() {
3
- var releaseInfo = "MTY4NTU3MDQwMDAwMA==";
3
+ var releaseInfo = "MTY4NjI2MTYwMDAwMA==";
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
@@ -93,7 +93,7 @@ export interface DataGridPremiumPropsWithDefaultValue extends DataGridProPropsWi
93
93
  * The function is used to split the pasted text into rows and cells.
94
94
  * @param {string} text The text pasted from the clipboard.
95
95
  * @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
96
- * @default `(text) => text.split(/\r\n|\n|\r/).map((row) => row.split('\t'))`
96
+ * @default `(pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }`
97
97
  */
98
98
  unstable_splitClipboardPastedText: (text: string) => string[][] | null;
99
99
  }
@@ -940,7 +940,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
940
940
  * The function is used to split the pasted text into rows and cells.
941
941
  * @param {string} text The text pasted from the clipboard.
942
942
  * @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
943
- * @default `(text) => text.split(/\r\n|\n|\r/).map((row) => row.split('\t'))`
943
+ * @default `(pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }`
944
944
  */
945
945
  unstable_splitClipboardPastedText: PropTypes.func
946
946
  } : void 0;
@@ -18,7 +18,12 @@ export const DATA_GRID_PREMIUM_PROPS_DEFAULT_VALUES = _extends({}, DATA_GRID_PRO
18
18
  aggregationRowsScope: 'filtered',
19
19
  getAggregationPosition: groupNode => groupNode.depth === -1 ? 'footer' : 'inline',
20
20
  disableClipboardPaste: false,
21
- unstable_splitClipboardPastedText: text => text.split(/\r\n|\n|\r/).map(row => row.split('\t'))
21
+ unstable_splitClipboardPastedText: pastedText => {
22
+ // Excel on Windows adds an empty line break at the end of the copied text.
23
+ // See https://github.com/mui/mui-x/issues/9103
24
+ const text = pastedText.replace(/\r?\n$/, '');
25
+ return text.split(/\r\n|\n|\r/).map(row => row.split('\t'));
26
+ }
22
27
  });
23
28
  const defaultSlots = uncapitalizeObjectKeys(DATA_GRID_PREMIUM_DEFAULT_SLOTS_COMPONENTS);
24
29
  export const useDataGridPremiumProps = inProps => {
@@ -92,12 +92,7 @@ export const addFooterRows = ({
92
92
  depth: groupNode ? groupNode.depth + 1 : 0,
93
93
  type: 'footer'
94
94
  };
95
- insertNodeInTree({
96
- previousTree: null,
97
- node: footerNode,
98
- tree: newGroupingParams.tree,
99
- treeDepths: newGroupingParams.treeDepths
100
- });
95
+ insertNodeInTree(footerNode, newGroupingParams.tree, newGroupingParams.treeDepths, null);
101
96
  }
102
97
  } else if (groupNode.footerId != null) {
103
98
  removeNodeFromTree({
package/modern/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.6.0
2
+ * @mui/x-data-grid-premium v6.7.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -1,6 +1,6 @@
1
1
  import { ponyfillGlobal } from '@mui/utils';
2
2
  export const getReleaseInfo = () => {
3
- const releaseInfo = "MTY4NTU3MDQwMDAwMA==";
3
+ const releaseInfo = "MTY4NjI2MTYwMDAwMA==";
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
@@ -949,7 +949,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
949
949
  * The function is used to split the pasted text into rows and cells.
950
950
  * @param {string} text The text pasted from the clipboard.
951
951
  * @returns {string[][] | null} A 2D array of strings. The first dimension is the rows, the second dimension is the columns.
952
- * @default `(text) => text.split(/\r\n|\n|\r/).map((row) => row.split('\t'))`
952
+ * @default `(pastedText) => { const text = pastedText.replace(/\r?\n$/, ''); return text.split(/\r\n|\n|\r/).map((row) => row.split('\t')); }`
953
953
  */
954
954
  unstable_splitClipboardPastedText: _propTypes.default.func
955
955
  } : void 0;
@@ -26,7 +26,12 @@ const DATA_GRID_PREMIUM_PROPS_DEFAULT_VALUES = (0, _extends2.default)({}, _xData
26
26
  aggregationRowsScope: 'filtered',
27
27
  getAggregationPosition: groupNode => groupNode.depth === -1 ? 'footer' : 'inline',
28
28
  disableClipboardPaste: false,
29
- unstable_splitClipboardPastedText: text => text.split(/\r\n|\n|\r/).map(row => row.split('\t'))
29
+ unstable_splitClipboardPastedText: pastedText => {
30
+ // Excel on Windows adds an empty line break at the end of the copied text.
31
+ // See https://github.com/mui/mui-x/issues/9103
32
+ const text = pastedText.replace(/\r?\n$/, '');
33
+ return text.split(/\r\n|\n|\r/).map(row => row.split('\t'));
34
+ }
30
35
  });
31
36
  exports.DATA_GRID_PREMIUM_PROPS_DEFAULT_VALUES = DATA_GRID_PREMIUM_PROPS_DEFAULT_VALUES;
32
37
  const defaultSlots = (0, _internals.uncapitalizeObjectKeys)(_dataGridPremiumDefaultSlotsComponents.DATA_GRID_PREMIUM_DEFAULT_SLOTS_COMPONENTS);
@@ -105,12 +105,7 @@ const addFooterRows = ({
105
105
  depth: groupNode ? groupNode.depth + 1 : 0,
106
106
  type: 'footer'
107
107
  };
108
- (0, _internals.insertNodeInTree)({
109
- previousTree: null,
110
- node: footerNode,
111
- tree: newGroupingParams.tree,
112
- treeDepths: newGroupingParams.treeDepths
113
- });
108
+ (0, _internals.insertNodeInTree)(footerNode, newGroupingParams.tree, newGroupingParams.treeDepths, null);
114
109
  }
115
110
  } else if (groupNode.footerId != null) {
116
111
  (0, _internals.removeNodeFromTree)({
package/node/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.6.0
2
+ * @mui/x-data-grid-premium v6.7.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -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 = "MTY4NTU3MDQwMDAwMA==";
9
+ const releaseInfo = "MTY4NjI2MTYwMDAwMA==";
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
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mui/x-data-grid-premium",
3
- "version": "6.6.0",
3
+ "version": "6.7.0",
4
4
  "description": "The Premium plan edition of the data grid component (MUI X).",
5
5
  "author": "MUI Team",
6
6
  "main": "./node/index.js",
@@ -33,8 +33,8 @@
33
33
  "dependencies": {
34
34
  "@babel/runtime": "^7.21.0",
35
35
  "@mui/utils": "^5.13.1",
36
- "@mui/x-data-grid": "6.6.0",
37
- "@mui/x-data-grid-pro": "6.6.0",
36
+ "@mui/x-data-grid": "6.7.0",
37
+ "@mui/x-data-grid-pro": "6.7.0",
38
38
  "@mui/x-license-pro": "6.6.0",
39
39
  "@types/format-util": "^1.0.2",
40
40
  "clsx": "^1.2.1",
@@ -2,7 +2,7 @@ import { GridClassKey } from '@mui/x-data-grid';
2
2
  export interface DataGridPremiumComponentNameToClassKey {
3
3
  MuiDataGrid: GridClassKey;
4
4
  }
5
- declare module '@mui/material/styles/overrides' {
5
+ declare module '@mui/material/styles' {
6
6
  interface ComponentNameToClassKey extends DataGridPremiumComponentNameToClassKey {
7
7
  }
8
8
  }
@@ -1,6 +1,6 @@
1
1
  import { ponyfillGlobal } from '@mui/utils';
2
2
  export const getReleaseInfo = () => {
3
- const releaseInfo = "MTY4NTU3MDQwMDAwMA==";
3
+ const releaseInfo = "MTY4NjI2MTYwMDAwMA==";
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