@mui/x-data-grid-premium 6.20.0 → 6.20.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 CHANGED
@@ -3,6 +3,79 @@
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.20.3
7
+
8
+ _Jun 28, 2024_
9
+
10
+ We'd like to offer a big thanks to the 2 contributors who made this release possible. Here are some highlights ✨:
11
+
12
+ - 🐞 Bugfixes
13
+
14
+ ### Data Grid
15
+
16
+ #### `@mui/x-data-grid@6.20.3`
17
+
18
+ - [DataGrid] Make `rowCount` part of the state (#12406) @MBilalShafi
19
+
20
+ #### `@mui/x-data-grid-pro@6.20.3` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
21
+
22
+ Same changes as in `@mui/x-data-grid@6.20.3`.
23
+
24
+ #### `@mui/x-data-grid-premium@6.20.3` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link 'Premium plan')
25
+
26
+ Same changes as in `@mui/x-data-grid-pro@6.20.3`.
27
+
28
+ ### Core
29
+
30
+ - [core] Update release readme with `pnpm` notice (#13577) @LukasTy
31
+
32
+ ## 6.20.2
33
+
34
+ _Jun 20, 2024_
35
+
36
+ We'd like to offer a big thanks to the 2 contributors who made this release possible. Here are some highlights ✨:
37
+
38
+ - 🐞 Bugfixes
39
+
40
+ ### Date Pickers
41
+
42
+ #### `@mui/x-date-pickers@6.20.2`
43
+
44
+ - [fields] Do not apply digit editing when pressing `Space` (#13516) @flaviendelangle
45
+ - [pickers] Fix controlled `view` behavior (#13559) @LukasTy
46
+
47
+ ## 6.20.1
48
+
49
+ _Jun 6, 2024_
50
+
51
+ We'd like to offer a big thanks to the 2 contributors who made this release possible. Here are some highlights ✨:
52
+
53
+ - 🐞 Bugfixes
54
+
55
+ ### Data Grid
56
+
57
+ #### `@mui/x-data-grid-premium@6.20.1` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link 'Premium plan')
58
+
59
+ - [DataGridPremium] Fix clipboard paste not working when cell loses focus (#12737) @cherniavskii
60
+
61
+ ### Date Pickers
62
+
63
+ #### `@mui/x-date-pickers@6.20.1`
64
+
65
+ - [pickers] Fix `AdapterDayjs` timezone behavior (#13373) @LukasTy
66
+
67
+ #### `@mui/x-data-grid-pro@6.20.1` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
68
+
69
+ Same changes as in `@mui/x-date-pickers-pro@7.20.1`.
70
+
71
+ ### Docs
72
+
73
+ - [docs] Fix Pickers FAQ callout (#13243) @LukasTy
74
+
75
+ ### Core
76
+
77
+ - [core] Stop publishing v6 under latest tag (#13269) @cherniavskii
78
+
6
79
  ## 6.20.0
7
80
 
8
81
  _May 24, 2024_
@@ -702,6 +702,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
702
702
  * @param {GridCallbackDetails} details Additional details for this callback.
703
703
  */
704
704
  onRowClick: PropTypes.func,
705
+ /**
706
+ * Callback fired when the row count has changed.
707
+ * @param {number} count Updated row count.
708
+ */
709
+ onRowCountChange: PropTypes.func,
705
710
  /**
706
711
  * Callback fired when a double click event comes from a row container element.
707
712
  * @param {GridRowParams} params With all properties from [[RowParams]].
@@ -161,7 +161,8 @@ function defaultPasteResolver({
161
161
  }) {
162
162
  const isSingleValuePasted = pastedData.length === 1 && pastedData[0].length === 1;
163
163
  const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
164
- if (cellSelectionModel && apiRef.current.unstable_getSelectedCellsAsArray().length > 1) {
164
+ const selectedCellsArray = apiRef.current.unstable_getSelectedCellsAsArray();
165
+ if (cellSelectionModel && selectedCellsArray.length > 1) {
165
166
  Object.keys(cellSelectionModel).forEach((rowId, rowIndex) => {
166
167
  const rowDataArr = pastedData[isSingleValuePasted ? 0 : rowIndex];
167
168
  const hasRowData = isSingleValuePasted ? true : rowDataArr !== undefined;
@@ -212,7 +213,10 @@ function defaultPasteResolver({
212
213
  });
213
214
  return;
214
215
  }
215
- const selectedCell = gridFocusCellSelector(apiRef);
216
+ let selectedCell = gridFocusCellSelector(apiRef);
217
+ if (!selectedCell && selectedCellsArray.length === 1) {
218
+ selectedCell = selectedCellsArray[0];
219
+ }
216
220
  if (!selectedCell) {
217
221
  return;
218
222
  }
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.20.0
2
+ * @mui/x-data-grid-premium v6.20.3
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -702,6 +702,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
702
702
  * @param {GridCallbackDetails} details Additional details for this callback.
703
703
  */
704
704
  onRowClick: PropTypes.func,
705
+ /**
706
+ * Callback fired when the row count has changed.
707
+ * @param {number} count Updated row count.
708
+ */
709
+ onRowCountChange: PropTypes.func,
705
710
  /**
706
711
  * Callback fired when a double click event comes from a row container element.
707
712
  * @param {GridRowParams} params With all properties from [[RowParams]].
@@ -206,7 +206,8 @@ function defaultPasteResolver(_ref3) {
206
206
  pagination = _ref3.pagination;
207
207
  var isSingleValuePasted = pastedData.length === 1 && pastedData[0].length === 1;
208
208
  var cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
209
- if (cellSelectionModel && apiRef.current.unstable_getSelectedCellsAsArray().length > 1) {
209
+ var selectedCellsArray = apiRef.current.unstable_getSelectedCellsAsArray();
210
+ if (cellSelectionModel && selectedCellsArray.length > 1) {
210
211
  Object.keys(cellSelectionModel).forEach(function (rowId, rowIndex) {
211
212
  var rowDataArr = pastedData[isSingleValuePasted ? 0 : rowIndex];
212
213
  var hasRowData = isSingleValuePasted ? true : rowDataArr !== undefined;
@@ -258,6 +259,9 @@ function defaultPasteResolver(_ref3) {
258
259
  return;
259
260
  }
260
261
  var selectedCell = gridFocusCellSelector(apiRef);
262
+ if (!selectedCell && selectedCellsArray.length === 1) {
263
+ selectedCell = selectedCellsArray[0];
264
+ }
261
265
  if (!selectedCell) {
262
266
  return;
263
267
  }
package/legacy/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.20.0
2
+ * @mui/x-data-grid-premium v6.20.3
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 = "MTcxNjUwMTYwMDAwMA==";
3
+ var releaseInfo = "MTcxOTUyOTIwMDAwMA==";
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
@@ -702,6 +702,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
702
702
  * @param {GridCallbackDetails} details Additional details for this callback.
703
703
  */
704
704
  onRowClick: PropTypes.func,
705
+ /**
706
+ * Callback fired when the row count has changed.
707
+ * @param {number} count Updated row count.
708
+ */
709
+ onRowCountChange: PropTypes.func,
705
710
  /**
706
711
  * Callback fired when a double click event comes from a row container element.
707
712
  * @param {GridRowParams} params With all properties from [[RowParams]].
@@ -160,7 +160,8 @@ function defaultPasteResolver({
160
160
  }) {
161
161
  const isSingleValuePasted = pastedData.length === 1 && pastedData[0].length === 1;
162
162
  const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
163
- if (cellSelectionModel && apiRef.current.unstable_getSelectedCellsAsArray().length > 1) {
163
+ const selectedCellsArray = apiRef.current.unstable_getSelectedCellsAsArray();
164
+ if (cellSelectionModel && selectedCellsArray.length > 1) {
164
165
  Object.keys(cellSelectionModel).forEach((rowId, rowIndex) => {
165
166
  const rowDataArr = pastedData[isSingleValuePasted ? 0 : rowIndex];
166
167
  const hasRowData = isSingleValuePasted ? true : rowDataArr !== undefined;
@@ -211,7 +212,10 @@ function defaultPasteResolver({
211
212
  });
212
213
  return;
213
214
  }
214
- const selectedCell = gridFocusCellSelector(apiRef);
215
+ let selectedCell = gridFocusCellSelector(apiRef);
216
+ if (!selectedCell && selectedCellsArray.length === 1) {
217
+ selectedCell = selectedCellsArray[0];
218
+ }
215
219
  if (!selectedCell) {
216
220
  return;
217
221
  }
package/modern/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.20.0
2
+ * @mui/x-data-grid-premium v6.20.3
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 = "MTcxNjUwMTYwMDAwMA==";
3
+ const releaseInfo = "MTcxOTUyOTIwMDAwMA==";
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
@@ -710,6 +710,11 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
710
710
  * @param {GridCallbackDetails} details Additional details for this callback.
711
711
  */
712
712
  onRowClick: _propTypes.default.func,
713
+ /**
714
+ * Callback fired when the row count has changed.
715
+ * @param {number} count Updated row count.
716
+ */
717
+ onRowCountChange: _propTypes.default.func,
713
718
  /**
714
719
  * Callback fired when a double click event comes from a row container element.
715
720
  * @param {GridRowParams} params With all properties from [[RowParams]].
@@ -169,7 +169,8 @@ function defaultPasteResolver({
169
169
  }) {
170
170
  const isSingleValuePasted = pastedData.length === 1 && pastedData[0].length === 1;
171
171
  const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
172
- if (cellSelectionModel && apiRef.current.unstable_getSelectedCellsAsArray().length > 1) {
172
+ const selectedCellsArray = apiRef.current.unstable_getSelectedCellsAsArray();
173
+ if (cellSelectionModel && selectedCellsArray.length > 1) {
173
174
  Object.keys(cellSelectionModel).forEach((rowId, rowIndex) => {
174
175
  const rowDataArr = pastedData[isSingleValuePasted ? 0 : rowIndex];
175
176
  const hasRowData = isSingleValuePasted ? true : rowDataArr !== undefined;
@@ -220,7 +221,10 @@ function defaultPasteResolver({
220
221
  });
221
222
  return;
222
223
  }
223
- const selectedCell = (0, _xDataGrid.gridFocusCellSelector)(apiRef);
224
+ let selectedCell = (0, _xDataGrid.gridFocusCellSelector)(apiRef);
225
+ if (!selectedCell && selectedCellsArray.length === 1) {
226
+ selectedCell = selectedCellsArray[0];
227
+ }
224
228
  if (!selectedCell) {
225
229
  return;
226
230
  }
package/node/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-premium v6.20.0
2
+ * @mui/x-data-grid-premium v6.20.3
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 = "MTcxNjUwMTYwMDAwMA==";
9
+ const releaseInfo = "MTcxOTUyOTIwMDAwMA==";
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.20.0",
3
+ "version": "6.20.3",
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.23.2",
35
35
  "@mui/utils": "^5.14.16",
36
- "@mui/x-data-grid": "6.20.0",
37
- "@mui/x-data-grid-pro": "6.20.0",
36
+ "@mui/x-data-grid": "6.20.3",
37
+ "@mui/x-data-grid-pro": "6.20.3",
38
38
  "@mui/x-license-pro": "6.10.2",
39
39
  "@types/format-util": "^1.0.3",
40
40
  "clsx": "^2.0.0",
@@ -1,6 +1,6 @@
1
1
  import { ponyfillGlobal } from '@mui/utils';
2
2
  export const getReleaseInfo = () => {
3
- const releaseInfo = "MTcxNjUwMTYwMDAwMA==";
3
+ const releaseInfo = "MTcxOTUyOTIwMDAwMA==";
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