@mui/x-data-grid-premium 6.19.4 → 6.19.6
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 +112 -10
- package/DataGridPremium/DataGridPremium.js +1 -1
- package/hooks/features/cellSelection/useGridCellSelection.js +6 -3
- package/index.js +1 -1
- package/legacy/DataGridPremium/DataGridPremium.js +1 -1
- package/legacy/hooks/features/cellSelection/useGridCellSelection.js +8 -3
- package/legacy/index.js +1 -1
- package/legacy/utils/releaseInfo.js +1 -1
- package/modern/DataGridPremium/DataGridPremium.js +1 -1
- package/modern/hooks/features/cellSelection/useGridCellSelection.js +6 -3
- package/modern/index.js +1 -1
- package/modern/utils/releaseInfo.js +1 -1
- package/node/DataGridPremium/DataGridPremium.js +1 -1
- package/node/hooks/features/cellSelection/useGridCellSelection.js +5 -2
- package/node/index.js +1 -1
- package/node/utils/releaseInfo.js +1 -1
- package/package.json +3 -3
- package/utils/releaseInfo.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,109 @@
|
|
|
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
|
+
## 6.19.6
|
|
7
|
+
|
|
8
|
+
_Mar 1, 2024_
|
|
9
|
+
|
|
10
|
+
We'd like to offer a big thanks to the 4 contributors who made this release possible. Here are some highlights ✨:
|
|
11
|
+
|
|
12
|
+
- 🌍 Improve Korean (ko-KR) and Chinese (zh-CN) locales on the Pickers
|
|
13
|
+
- 🐞 Bugfixes
|
|
14
|
+
- 📚 Documentation improvements
|
|
15
|
+
|
|
16
|
+
### Data Grid
|
|
17
|
+
|
|
18
|
+
#### `@mui/x-data-grid@6.19.6`
|
|
19
|
+
|
|
20
|
+
- [DataGrid] Fix error when existing rows are passed to `replaceRows` (@martijn-basesoft)
|
|
21
|
+
|
|
22
|
+
#### `@mui/x-data-grid-pro@6.19.6` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
23
|
+
|
|
24
|
+
Same changes as in `@mui/x-data-grid@6.19.6`.
|
|
25
|
+
|
|
26
|
+
#### `@mui/x-data-grid-premium@6.19.6` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
27
|
+
|
|
28
|
+
Same changes as in `@mui/x-data-grid-pro@6.19.6`, plus:
|
|
29
|
+
|
|
30
|
+
- [DataGridPremium] Make clipboard copy respect the sorting during cell selection (#12255) @MBilalShafi
|
|
31
|
+
|
|
32
|
+
### Date Pickers
|
|
33
|
+
|
|
34
|
+
#### `@mui/x-date-pickers@6.19.6`
|
|
35
|
+
|
|
36
|
+
- [l10n] Improve Chinese (zh-CN) locale (#12250) @headironc
|
|
37
|
+
- [l10n] Improve Korean (ko-KR) locale (#12186) @Luzi
|
|
38
|
+
|
|
39
|
+
#### `@mui/x-date-pickers-pro@6.19.6` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
40
|
+
|
|
41
|
+
Same changes as in `@mui/x-date-pickers@6.19.6`.
|
|
42
|
+
|
|
43
|
+
### Docs
|
|
44
|
+
|
|
45
|
+
- [docs] Update lazy loading demo to show skeleton rows during initial rows fetch (#12062) @cherniavskii
|
|
46
|
+
|
|
47
|
+
## 6.19.5
|
|
48
|
+
|
|
49
|
+
_Feb 23, 2024_
|
|
50
|
+
|
|
51
|
+
We'd like to offer a big thanks to the 6 contributors who made this release possible. Here are some highlights ✨:
|
|
52
|
+
|
|
53
|
+
- 🐞 Bugfixes
|
|
54
|
+
- 📚 Documentation improvements
|
|
55
|
+
|
|
56
|
+
### Data Grid
|
|
57
|
+
|
|
58
|
+
#### `@mui/x-data-grid@6.19.5`
|
|
59
|
+
|
|
60
|
+
- [DataGrid] Fix styling grid filter input single select (#12079) @FreakDroid
|
|
61
|
+
|
|
62
|
+
#### `@mui/x-data-grid-pro@6.19.5` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
63
|
+
|
|
64
|
+
Same changes as in `@mui/x-data-grid@6.19.5`.
|
|
65
|
+
|
|
66
|
+
#### `@mui/x-data-grid-premium@6.19.5` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
67
|
+
|
|
68
|
+
Same changes as in `@mui/x-data-grid-pro@6.19.5`.
|
|
69
|
+
|
|
70
|
+
### Date Pickers
|
|
71
|
+
|
|
72
|
+
#### `@mui/x-date-pickers@6.19.5`
|
|
73
|
+
|
|
74
|
+
- [pickers] Fix `referenceDate` day calendar focus (#12136) @LukasTy
|
|
75
|
+
- [pickers] Fix styling props propagation to `DateTimePickerTabs` (#12131) @LukasTy
|
|
76
|
+
|
|
77
|
+
#### `@mui/x-date-pickers-pro@6.19.5` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
78
|
+
|
|
79
|
+
Same changes as in `@mui/x-date-pickers@6.19.5`.
|
|
80
|
+
|
|
81
|
+
### Charts / `@mui/x-charts@6.19.5`
|
|
82
|
+
|
|
83
|
+
- [charts] Allow to skip animation on sparkline bar (#12160) @alexfauquette
|
|
84
|
+
|
|
85
|
+
### Docs
|
|
86
|
+
|
|
87
|
+
- [docs] Clarify Pickers 'Component composition' section (#12147) @LukasTy
|
|
88
|
+
- [docs] Fix 301 redirection to StackBlitz @oliviertassinari
|
|
89
|
+
- [docs] Fix 301 to Material UI @oliviertassinari
|
|
90
|
+
- [docs] Fix 301 to Material UI @oliviertassinari
|
|
91
|
+
- [docs] Fix 404 links to translation source @oliviertassinari
|
|
92
|
+
- [docs] Fix dead link to translations @oliviertassinari
|
|
93
|
+
- [docs] Fix the Treemap illustration (#12189) @danilo-leal
|
|
94
|
+
- [docs] Fix typo for `AdapterDateFnsV3` (#12037) @flaviendelangle
|
|
95
|
+
- [docs] Improve performance on Charts entry point @oliviertassinari
|
|
96
|
+
- [docs] Move Heatmap to pro (#12170) @alexfauquette
|
|
97
|
+
- [docs] Remove Charts installation next tag call-out (#12133) @LukasTy
|
|
98
|
+
- [docs] Removed `focused` prop from demo (#12126) @michelengelen
|
|
99
|
+
- [docs] Add missing Heatmap pro icon @oliviertassinari
|
|
100
|
+
- [docs] Add more illustrations to the Overview page (#12041) @danilo-leal
|
|
101
|
+
- [docs] Avoid use of shorthand (#12009) @oliviertassinari
|
|
102
|
+
|
|
103
|
+
### Core
|
|
104
|
+
|
|
105
|
+
- [core] Fix CI @oliviertassinari
|
|
106
|
+
- [core] Fix docs link check (#12137) @LukasTy
|
|
107
|
+
|
|
108
|
+
## 6.19.4
|
|
7
109
|
|
|
8
110
|
_Feb 9, 2024_
|
|
9
111
|
|
|
@@ -15,7 +117,7 @@ We'd like to offer a big thanks to the 10 contributors who made this release pos
|
|
|
15
117
|
|
|
16
118
|
### Data Grid
|
|
17
119
|
|
|
18
|
-
#### `@mui/x-data-grid@
|
|
120
|
+
#### `@mui/x-data-grid@6.19.4`
|
|
19
121
|
|
|
20
122
|
- [DataGrid] Add support for dialogs in menu actions (#11937) @cherniavskii
|
|
21
123
|
- [DataGrid] Allow passing readonly arrays to `pageSizeOptions` prop (#11992) @pcorpet
|
|
@@ -23,28 +125,28 @@ We'd like to offer a big thanks to the 10 contributors who made this release pos
|
|
|
23
125
|
- [DataGrid] Replace `eval` with `new Function` (#11962) @cherniavskii
|
|
24
126
|
- [l10n] Improve Danish (da-DK) locale (#11972) @ShahrazH
|
|
25
127
|
|
|
26
|
-
#### `@mui/x-data-grid-pro@
|
|
128
|
+
#### `@mui/x-data-grid-pro@6.19.4` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
27
129
|
|
|
28
|
-
Same changes as in `@mui/x-data-grid@
|
|
130
|
+
Same changes as in `@mui/x-data-grid@6.19.4`.
|
|
29
131
|
|
|
30
|
-
#### `@mui/x-data-grid-premium@
|
|
132
|
+
#### `@mui/x-data-grid-premium@6.19.4` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
31
133
|
|
|
32
|
-
Same changes as in `@mui/x-data-grid-pro@
|
|
134
|
+
Same changes as in `@mui/x-data-grid-pro@6.19.4`, plus:
|
|
33
135
|
|
|
34
136
|
- [DataGridPremium] Fix autosize grouping cell (#11990) @romgrk
|
|
35
137
|
- [DataGridPremium] Fix error after closing print export (#11889) @cherniavskii
|
|
36
138
|
|
|
37
139
|
### Date Pickers
|
|
38
140
|
|
|
39
|
-
#### `@mui/x-date-pickers@
|
|
141
|
+
#### `@mui/x-date-pickers@6.19.4`
|
|
40
142
|
|
|
41
143
|
- [pickers] Avoid relying on locale in Luxon `isWithinRange` method (#11940) @LukasTy
|
|
42
144
|
|
|
43
|
-
#### `@mui/x-date-pickers-pro@
|
|
145
|
+
#### `@mui/x-date-pickers-pro@6.19.4` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
44
146
|
|
|
45
|
-
Same changes as in `@mui/x-date-pickers@
|
|
147
|
+
Same changes as in `@mui/x-date-pickers@6.19.4`.
|
|
46
148
|
|
|
47
|
-
### Charts / `@mui/x-charts@
|
|
149
|
+
### Charts / `@mui/x-charts@6.19.4`
|
|
48
150
|
|
|
49
151
|
- [charts] Add `reverse` property to axes (#11959) @alexfauquette
|
|
50
152
|
- [charts] Allow series ids to be numbers (#11960) @alexfauquette
|
|
@@ -461,7 +461,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
461
461
|
loading: PropTypes.bool,
|
|
462
462
|
/**
|
|
463
463
|
* Set the locale text of the Data Grid.
|
|
464
|
-
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/
|
|
464
|
+
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/v6.19.4/packages/grid/x-data-grid/src/constants/localeTextConstants.ts) in the GitHub repository.
|
|
465
465
|
*/
|
|
466
466
|
localeText: PropTypes.object,
|
|
467
467
|
/**
|
|
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { ownerDocument, useEventCallback } from '@mui/material/utils';
|
|
4
4
|
import { isNavigationKey, serializeCellValue, useGridRegisterPipeProcessor, useGridVisibleRows } from '@mui/x-data-grid-pro/internals';
|
|
5
|
-
import { useGridApiEventHandler, useGridApiMethod, GRID_ACTIONS_COLUMN_TYPE, GRID_CHECKBOX_SELECTION_COL_DEF, GRID_DETAIL_PANEL_TOGGLE_FIELD, gridRowsDataRowIdToIdLookupSelector, gridClasses, gridFocusCellSelector, GRID_REORDER_COL_DEF } from '@mui/x-data-grid-pro';
|
|
5
|
+
import { useGridApiEventHandler, useGridApiMethod, GRID_ACTIONS_COLUMN_TYPE, GRID_CHECKBOX_SELECTION_COL_DEF, GRID_DETAIL_PANEL_TOGGLE_FIELD, gridRowsDataRowIdToIdLookupSelector, gridClasses, gridFocusCellSelector, GRID_REORDER_COL_DEF, useGridSelector, gridSortedRowIdsSelector } from '@mui/x-data-grid-pro';
|
|
6
6
|
import { gridCellSelectionStateSelector } from './gridCellSelectionSelector';
|
|
7
7
|
export const cellSelectionStateInitializer = (state, props) => {
|
|
8
8
|
var _props$unstable_cellS, _props$initialState;
|
|
@@ -22,6 +22,7 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
22
22
|
const lastMouseDownCell = React.useRef();
|
|
23
23
|
const mousePosition = React.useRef(null);
|
|
24
24
|
const autoScrollRAF = React.useRef();
|
|
25
|
+
const sortedRowIds = useGridSelector(apiRef, gridSortedRowIdsSelector);
|
|
25
26
|
const ignoreValueFormatterProp = props.unstable_ignoreValueFormatterDuringExport;
|
|
26
27
|
const ignoreValueFormatter = (typeof ignoreValueFormatterProp === 'object' ? ignoreValueFormatterProp == null ? void 0 : ignoreValueFormatterProp.clipboardExport : ignoreValueFormatterProp) || false;
|
|
27
28
|
const clipboardCopyCellDelimiter = props.clipboardCopyCellDelimiter;
|
|
@@ -445,7 +446,9 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
445
446
|
return value;
|
|
446
447
|
}
|
|
447
448
|
const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
|
|
448
|
-
const
|
|
449
|
+
const unsortedSelectedRowIds = Object.keys(cellSelectionModel);
|
|
450
|
+
const sortedSelectedRowIds = sortedRowIds.filter(id => unsortedSelectedRowIds.includes(`${id}`));
|
|
451
|
+
const copyData = sortedSelectedRowIds.reduce((acc, rowId) => {
|
|
449
452
|
const fieldsMap = cellSelectionModel[rowId];
|
|
450
453
|
const rowString = Object.keys(fieldsMap).reduce((acc2, field) => {
|
|
451
454
|
let cellData;
|
|
@@ -463,7 +466,7 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
463
466
|
return acc === '' ? rowString : [acc, rowString].join('\r\n');
|
|
464
467
|
}, '');
|
|
465
468
|
return copyData;
|
|
466
|
-
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter]);
|
|
469
|
+
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter, sortedRowIds]);
|
|
467
470
|
useGridRegisterPipeProcessor(apiRef, 'isCellSelected', checkIfCellIsSelected);
|
|
468
471
|
useGridRegisterPipeProcessor(apiRef, 'cellClassName', addClassesToCells);
|
|
469
472
|
useGridRegisterPipeProcessor(apiRef, 'canUpdateFocus', canUpdateFocus);
|
package/index.js
CHANGED
|
@@ -461,7 +461,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
461
461
|
loading: PropTypes.bool,
|
|
462
462
|
/**
|
|
463
463
|
* Set the locale text of the Data Grid.
|
|
464
|
-
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/
|
|
464
|
+
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/v6.19.4/packages/grid/x-data-grid/src/constants/localeTextConstants.ts) in the GitHub repository.
|
|
465
465
|
*/
|
|
466
466
|
localeText: PropTypes.object,
|
|
467
467
|
/**
|
|
@@ -6,7 +6,7 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
6
6
|
import * as React from 'react';
|
|
7
7
|
import { ownerDocument, useEventCallback } from '@mui/material/utils';
|
|
8
8
|
import { isNavigationKey, serializeCellValue, useGridRegisterPipeProcessor, useGridVisibleRows } from '@mui/x-data-grid-pro/internals';
|
|
9
|
-
import { useGridApiEventHandler, useGridApiMethod, GRID_ACTIONS_COLUMN_TYPE, GRID_CHECKBOX_SELECTION_COL_DEF, GRID_DETAIL_PANEL_TOGGLE_FIELD, gridRowsDataRowIdToIdLookupSelector, gridClasses, gridFocusCellSelector, GRID_REORDER_COL_DEF } from '@mui/x-data-grid-pro';
|
|
9
|
+
import { useGridApiEventHandler, useGridApiMethod, GRID_ACTIONS_COLUMN_TYPE, GRID_CHECKBOX_SELECTION_COL_DEF, GRID_DETAIL_PANEL_TOGGLE_FIELD, gridRowsDataRowIdToIdLookupSelector, gridClasses, gridFocusCellSelector, GRID_REORDER_COL_DEF, useGridSelector, gridSortedRowIdsSelector } from '@mui/x-data-grid-pro';
|
|
10
10
|
import { gridCellSelectionStateSelector } from './gridCellSelectionSelector';
|
|
11
11
|
export var cellSelectionStateInitializer = function cellSelectionStateInitializer(state, props) {
|
|
12
12
|
var _props$unstable_cellS, _props$initialState;
|
|
@@ -26,6 +26,7 @@ export var useGridCellSelection = function useGridCellSelection(apiRef, props) {
|
|
|
26
26
|
var lastMouseDownCell = React.useRef();
|
|
27
27
|
var mousePosition = React.useRef(null);
|
|
28
28
|
var autoScrollRAF = React.useRef();
|
|
29
|
+
var sortedRowIds = useGridSelector(apiRef, gridSortedRowIdsSelector);
|
|
29
30
|
var ignoreValueFormatterProp = props.unstable_ignoreValueFormatterDuringExport;
|
|
30
31
|
var ignoreValueFormatter = (_typeof(ignoreValueFormatterProp) === 'object' ? ignoreValueFormatterProp == null ? void 0 : ignoreValueFormatterProp.clipboardExport : ignoreValueFormatterProp) || false;
|
|
31
32
|
var clipboardCopyCellDelimiter = props.clipboardCopyCellDelimiter;
|
|
@@ -429,7 +430,11 @@ export var useGridCellSelection = function useGridCellSelection(apiRef, props) {
|
|
|
429
430
|
return value;
|
|
430
431
|
}
|
|
431
432
|
var cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
|
|
432
|
-
var
|
|
433
|
+
var unsortedSelectedRowIds = Object.keys(cellSelectionModel);
|
|
434
|
+
var sortedSelectedRowIds = sortedRowIds.filter(function (id) {
|
|
435
|
+
return unsortedSelectedRowIds.includes("".concat(id));
|
|
436
|
+
});
|
|
437
|
+
var copyData = sortedSelectedRowIds.reduce(function (acc, rowId) {
|
|
433
438
|
var fieldsMap = cellSelectionModel[rowId];
|
|
434
439
|
var rowString = Object.keys(fieldsMap).reduce(function (acc2, field) {
|
|
435
440
|
var cellData;
|
|
@@ -447,7 +452,7 @@ export var useGridCellSelection = function useGridCellSelection(apiRef, props) {
|
|
|
447
452
|
return acc === '' ? rowString : [acc, rowString].join('\r\n');
|
|
448
453
|
}, '');
|
|
449
454
|
return copyData;
|
|
450
|
-
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter]);
|
|
455
|
+
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter, sortedRowIds]);
|
|
451
456
|
useGridRegisterPipeProcessor(apiRef, 'isCellSelected', checkIfCellIsSelected);
|
|
452
457
|
useGridRegisterPipeProcessor(apiRef, 'cellClassName', addClassesToCells);
|
|
453
458
|
useGridRegisterPipeProcessor(apiRef, 'canUpdateFocus', canUpdateFocus);
|
package/legacy/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export var getReleaseInfo = function getReleaseInfo() {
|
|
3
|
-
var releaseInfo = "
|
|
3
|
+
var releaseInfo = "MTcwOTM1NTYwMDAwMA==";
|
|
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
|
|
@@ -461,7 +461,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
461
461
|
loading: PropTypes.bool,
|
|
462
462
|
/**
|
|
463
463
|
* Set the locale text of the Data Grid.
|
|
464
|
-
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/
|
|
464
|
+
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/v6.19.4/packages/grid/x-data-grid/src/constants/localeTextConstants.ts) in the GitHub repository.
|
|
465
465
|
*/
|
|
466
466
|
localeText: PropTypes.object,
|
|
467
467
|
/**
|
|
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { ownerDocument, useEventCallback } from '@mui/material/utils';
|
|
4
4
|
import { isNavigationKey, serializeCellValue, useGridRegisterPipeProcessor, useGridVisibleRows } from '@mui/x-data-grid-pro/internals';
|
|
5
|
-
import { useGridApiEventHandler, useGridApiMethod, GRID_ACTIONS_COLUMN_TYPE, GRID_CHECKBOX_SELECTION_COL_DEF, GRID_DETAIL_PANEL_TOGGLE_FIELD, gridRowsDataRowIdToIdLookupSelector, gridClasses, gridFocusCellSelector, GRID_REORDER_COL_DEF } from '@mui/x-data-grid-pro';
|
|
5
|
+
import { useGridApiEventHandler, useGridApiMethod, GRID_ACTIONS_COLUMN_TYPE, GRID_CHECKBOX_SELECTION_COL_DEF, GRID_DETAIL_PANEL_TOGGLE_FIELD, gridRowsDataRowIdToIdLookupSelector, gridClasses, gridFocusCellSelector, GRID_REORDER_COL_DEF, useGridSelector, gridSortedRowIdsSelector } from '@mui/x-data-grid-pro';
|
|
6
6
|
import { gridCellSelectionStateSelector } from './gridCellSelectionSelector';
|
|
7
7
|
export const cellSelectionStateInitializer = (state, props) => _extends({}, state, {
|
|
8
8
|
cellSelection: _extends({}, props.unstable_cellSelectionModel ?? props.initialState?.cellSelection)
|
|
@@ -19,6 +19,7 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
19
19
|
const lastMouseDownCell = React.useRef();
|
|
20
20
|
const mousePosition = React.useRef(null);
|
|
21
21
|
const autoScrollRAF = React.useRef();
|
|
22
|
+
const sortedRowIds = useGridSelector(apiRef, gridSortedRowIdsSelector);
|
|
22
23
|
const ignoreValueFormatterProp = props.unstable_ignoreValueFormatterDuringExport;
|
|
23
24
|
const ignoreValueFormatter = (typeof ignoreValueFormatterProp === 'object' ? ignoreValueFormatterProp?.clipboardExport : ignoreValueFormatterProp) || false;
|
|
24
25
|
const clipboardCopyCellDelimiter = props.clipboardCopyCellDelimiter;
|
|
@@ -436,7 +437,9 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
436
437
|
return value;
|
|
437
438
|
}
|
|
438
439
|
const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
|
|
439
|
-
const
|
|
440
|
+
const unsortedSelectedRowIds = Object.keys(cellSelectionModel);
|
|
441
|
+
const sortedSelectedRowIds = sortedRowIds.filter(id => unsortedSelectedRowIds.includes(`${id}`));
|
|
442
|
+
const copyData = sortedSelectedRowIds.reduce((acc, rowId) => {
|
|
440
443
|
const fieldsMap = cellSelectionModel[rowId];
|
|
441
444
|
const rowString = Object.keys(fieldsMap).reduce((acc2, field) => {
|
|
442
445
|
let cellData;
|
|
@@ -454,7 +457,7 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
454
457
|
return acc === '' ? rowString : [acc, rowString].join('\r\n');
|
|
455
458
|
}, '');
|
|
456
459
|
return copyData;
|
|
457
|
-
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter]);
|
|
460
|
+
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter, sortedRowIds]);
|
|
458
461
|
useGridRegisterPipeProcessor(apiRef, 'isCellSelected', checkIfCellIsSelected);
|
|
459
462
|
useGridRegisterPipeProcessor(apiRef, 'cellClassName', addClassesToCells);
|
|
460
463
|
useGridRegisterPipeProcessor(apiRef, 'canUpdateFocus', canUpdateFocus);
|
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 = "MTcwOTM1NTYwMDAwMA==";
|
|
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
|
|
@@ -469,7 +469,7 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
469
469
|
loading: _propTypes.default.bool,
|
|
470
470
|
/**
|
|
471
471
|
* Set the locale text of the Data Grid.
|
|
472
|
-
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/
|
|
472
|
+
* You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/v6.19.4/packages/grid/x-data-grid/src/constants/localeTextConstants.ts) in the GitHub repository.
|
|
473
473
|
*/
|
|
474
474
|
localeText: _propTypes.default.object,
|
|
475
475
|
/**
|
|
@@ -29,6 +29,7 @@ const useGridCellSelection = (apiRef, props) => {
|
|
|
29
29
|
const lastMouseDownCell = React.useRef();
|
|
30
30
|
const mousePosition = React.useRef(null);
|
|
31
31
|
const autoScrollRAF = React.useRef();
|
|
32
|
+
const sortedRowIds = (0, _xDataGridPro.useGridSelector)(apiRef, _xDataGridPro.gridSortedRowIdsSelector);
|
|
32
33
|
const ignoreValueFormatterProp = props.unstable_ignoreValueFormatterDuringExport;
|
|
33
34
|
const ignoreValueFormatter = (typeof ignoreValueFormatterProp === 'object' ? ignoreValueFormatterProp?.clipboardExport : ignoreValueFormatterProp) || false;
|
|
34
35
|
const clipboardCopyCellDelimiter = props.clipboardCopyCellDelimiter;
|
|
@@ -446,7 +447,9 @@ const useGridCellSelection = (apiRef, props) => {
|
|
|
446
447
|
return value;
|
|
447
448
|
}
|
|
448
449
|
const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel();
|
|
449
|
-
const
|
|
450
|
+
const unsortedSelectedRowIds = Object.keys(cellSelectionModel);
|
|
451
|
+
const sortedSelectedRowIds = sortedRowIds.filter(id => unsortedSelectedRowIds.includes(`${id}`));
|
|
452
|
+
const copyData = sortedSelectedRowIds.reduce((acc, rowId) => {
|
|
450
453
|
const fieldsMap = cellSelectionModel[rowId];
|
|
451
454
|
const rowString = Object.keys(fieldsMap).reduce((acc2, field) => {
|
|
452
455
|
let cellData;
|
|
@@ -464,7 +467,7 @@ const useGridCellSelection = (apiRef, props) => {
|
|
|
464
467
|
return acc === '' ? rowString : [acc, rowString].join('\r\n');
|
|
465
468
|
}, '');
|
|
466
469
|
return copyData;
|
|
467
|
-
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter]);
|
|
470
|
+
}, [apiRef, ignoreValueFormatter, clipboardCopyCellDelimiter, sortedRowIds]);
|
|
468
471
|
(0, _internals.useGridRegisterPipeProcessor)(apiRef, 'isCellSelected', checkIfCellIsSelected);
|
|
469
472
|
(0, _internals.useGridRegisterPipeProcessor)(apiRef, 'cellClassName', addClassesToCells);
|
|
470
473
|
(0, _internals.useGridRegisterPipeProcessor)(apiRef, 'canUpdateFocus', canUpdateFocus);
|
package/node/index.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 = "MTcwOTM1NTYwMDAwMA==";
|
|
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.19.
|
|
3
|
+
"version": "6.19.6",
|
|
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.19.
|
|
37
|
-
"@mui/x-data-grid-pro": "6.19.
|
|
36
|
+
"@mui/x-data-grid": "6.19.6",
|
|
37
|
+
"@mui/x-data-grid-pro": "6.19.6",
|
|
38
38
|
"@mui/x-license-pro": "6.10.2",
|
|
39
39
|
"@types/format-util": "^1.0.3",
|
|
40
40
|
"clsx": "^2.0.0",
|
package/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 = "MTcwOTM1NTYwMDAwMA==";
|
|
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
|