@mui/x-data-grid 8.15.0 → 8.16.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 +100 -0
- package/DataGrid/DataGrid.js +2 -0
- package/DataGrid/useDataGridComponent.js +1 -1
- package/esm/DataGrid/DataGrid.js +2 -0
- package/esm/DataGrid/useDataGridComponent.js +1 -1
- package/esm/hooks/features/editing/useGridCellEditable.d.ts +5 -0
- package/esm/hooks/features/editing/useGridCellEditable.js +9 -0
- package/esm/hooks/features/editing/useGridEditing.d.ts +2 -1
- package/esm/hooks/features/editing/useGridEditing.js +4 -4
- package/esm/hooks/features/focus/useGridFocus.js +4 -2
- package/esm/hooks/features/rowSelection/useGridRowSelection.js +3 -1
- package/esm/index.js +1 -1
- package/esm/internals/index.d.ts +2 -0
- package/esm/internals/index.js +1 -0
- package/esm/locales/esES.js +109 -120
- package/esm/models/configuration/gridCellEditableConfiguration.d.ts +19 -0
- package/esm/models/configuration/gridCellEditableConfiguration.js +1 -0
- package/esm/models/configuration/gridConfiguration.d.ts +2 -1
- package/hooks/features/editing/useGridCellEditable.d.ts +5 -0
- package/hooks/features/editing/useGridCellEditable.js +15 -0
- package/hooks/features/editing/useGridEditing.d.ts +2 -1
- package/hooks/features/editing/useGridEditing.js +4 -4
- package/hooks/features/focus/useGridFocus.js +4 -2
- package/hooks/features/rowSelection/useGridRowSelection.js +3 -1
- package/index.js +1 -1
- package/internals/index.d.ts +2 -0
- package/internals/index.js +8 -0
- package/locales/esES.js +109 -120
- package/models/configuration/gridCellEditableConfiguration.d.ts +19 -0
- package/models/configuration/gridCellEditableConfiguration.js +5 -0
- package/models/configuration/gridConfiguration.d.ts +2 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,106 @@
|
|
|
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.16.0
|
|
9
|
+
|
|
10
|
+
_Oct 29, 2025_
|
|
11
|
+
|
|
12
|
+
We'd like to extend a big thank you to the 14 contributors who made this release possible. Here are some highlights ✨:
|
|
13
|
+
|
|
14
|
+
- 🖌️ Add `brush` zoom interaction to charts
|
|
15
|
+
- 🔁 [Server-side update](https://mui.com/x/react-data-grid/server-side-data/#updating-server-side-data) in a grid with tree data/row grouping and aggregation will trigger re-fetch for all parent levels of that row to update aggregated values. See the [demo](https://mui.com/x/react-data-grid/server-side-data/aggregation/#usage-with-tree-data).
|
|
16
|
+
|
|
17
|
+
Special thanks go out to the community members for their valuable contributions:
|
|
18
|
+
@felix-wg, @frncesc, @sai6855
|
|
19
|
+
|
|
20
|
+
The following are all team members who have contributed to this release:
|
|
21
|
+
@alexfauquette, @arminmeh, @bernardobelchior, @brijeshb42, @flaviendelangle, @JCQuintas, @MBilalShafi, @mbrookes, @michelengelen, @noraleonte, @rita-codes
|
|
22
|
+
|
|
23
|
+
### Data Grid
|
|
24
|
+
|
|
25
|
+
#### `@mui/x-data-grid@8.16.0`
|
|
26
|
+
|
|
27
|
+
- [DataGrid] Ignore `Ctrl+A` key combination for the row selection in the community version (#20110) @felix-wg
|
|
28
|
+
- [DataGrid][l10n] Improve Spanish (es-ES) locale (#20134) @frncesc
|
|
29
|
+
|
|
30
|
+
#### `@mui/x-data-grid-pro@8.16.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
31
|
+
|
|
32
|
+
Same changes as in `@mui/x-data-grid@8.16.0`, plus:
|
|
33
|
+
|
|
34
|
+
- [DataGridPro] Add explicit return type to `getVisibleRowsLookup()` to fix the build with `tsc` (#20116) @arminmeh
|
|
35
|
+
- [DataGridPro] Retain the expansion state with expansion configuration props (#20126) @MBilalShafi
|
|
36
|
+
|
|
37
|
+
#### `@mui/x-data-grid-premium@8.16.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
38
|
+
|
|
39
|
+
Same changes as in `@mui/x-data-grid-pro@8.16.0`, plus:
|
|
40
|
+
|
|
41
|
+
- [DataGridPremium] Export and restore chart integration state (#20079) @arminmeh
|
|
42
|
+
- [DataGridPremium] Fix grouping column `valueFormatter()` crash (#20070) @sai6855
|
|
43
|
+
- [DataGridPremium] Refetch aggregation data after row update with server-side aggregation (#20039) @arminmeh
|
|
44
|
+
|
|
45
|
+
### Date and Time Pickers
|
|
46
|
+
|
|
47
|
+
#### `@mui/x-date-pickers@8.16.0`
|
|
48
|
+
|
|
49
|
+
- [pickers] Prevent blur event propagation on individual sections (#19825) @michelengelen
|
|
50
|
+
|
|
51
|
+
#### `@mui/x-date-pickers-pro@8.16.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
52
|
+
|
|
53
|
+
Same changes as in `@mui/x-date-pickers@8.16.0`.
|
|
54
|
+
|
|
55
|
+
### Charts
|
|
56
|
+
|
|
57
|
+
#### `@mui/x-charts@8.16.0`
|
|
58
|
+
|
|
59
|
+
- [charts] Allow tooltip to anchor items (#19954) @alexfauquette
|
|
60
|
+
- [charts] Fix behavior of grouped axis (#20118) @JCQuintas
|
|
61
|
+
- [charts] Move scale symlog inside scales (#20137) @JCQuintas
|
|
62
|
+
- [charts] Fix AreaChartConnectNulls demo height not correctly resizing (#20078) @sai6855
|
|
63
|
+
- [charts] Fix charts resizing overflow (#20080) @alexfauquette
|
|
64
|
+
- [charts] Fix tooltip not showing on first render (#20115) @bernardobelchior
|
|
65
|
+
- [charts] Handle `undefined` id and color in series (#20087) @bernardobelchior
|
|
66
|
+
- [charts] Remove `useMemo` from isZoomOn*Enabled and isPanOn*Enabled hooks (#20132) @Copilot
|
|
67
|
+
- [charts] Use static data for perf (#20072) @JCQuintas
|
|
68
|
+
- [charts] Move scale symlog inside scales (#20137) @JCQuintas
|
|
69
|
+
|
|
70
|
+
#### `@mui/x-charts-pro@8.16.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
71
|
+
|
|
72
|
+
Same changes as in `@mui/x-charts@8.16.0`, plus:
|
|
73
|
+
|
|
74
|
+
- [charts-pro] Add `brush` zoom interaction (#19899) @JCQuintas
|
|
75
|
+
- [charts-pro] Add sankey performance check (#20069) @JCQuintas
|
|
76
|
+
|
|
77
|
+
#### `@mui/x-charts-premium@8.16.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
78
|
+
|
|
79
|
+
Same changes as in `@mui/x-charts-pro@8.16.0`.
|
|
80
|
+
|
|
81
|
+
### Tree View
|
|
82
|
+
|
|
83
|
+
#### `@mui/x-tree-view@8.16.0`
|
|
84
|
+
|
|
85
|
+
Internal changes.
|
|
86
|
+
|
|
87
|
+
#### `@mui/x-tree-view-pro@8.16.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
88
|
+
|
|
89
|
+
Same changes as in `@mui/x-tree-view@8.16.0`.
|
|
90
|
+
|
|
91
|
+
### Codemod
|
|
92
|
+
|
|
93
|
+
#### `@mui/x-codemod@8.16.0`
|
|
94
|
+
|
|
95
|
+
Internal changes.
|
|
96
|
+
|
|
97
|
+
### Core
|
|
98
|
+
|
|
99
|
+
- [code-infra] Setup eslint compat plugin (#20105) @brijeshb42
|
|
100
|
+
- [code-infra] Improve store types (#20129) @JCQuintas
|
|
101
|
+
- [docs] Update the callout in `rows` prop documentation (#20127) @MBilalShafi
|
|
102
|
+
- [docs-infra] Refine changelog contributor acknowledgment messages (#20123) @mbrookes
|
|
103
|
+
|
|
104
|
+
### Miscellaneous
|
|
105
|
+
|
|
106
|
+
- [x-telemetry] Skip telemetry tests on browser mode (#20122) @bernardobelchior
|
|
107
|
+
|
|
8
108
|
## 8.15.0
|
|
9
109
|
|
|
10
110
|
_Oct 23, 2025_
|
package/DataGrid/DataGrid.js
CHANGED
|
@@ -16,6 +16,7 @@ var _useGridAriaAttributes = require("../hooks/utils/useGridAriaAttributes");
|
|
|
16
16
|
var _useGridRowAriaAttributes = require("../hooks/features/rows/useGridRowAriaAttributes");
|
|
17
17
|
var _useGridRowsOverridableMethods = require("../hooks/features/rows/useGridRowsOverridableMethods");
|
|
18
18
|
var _useGridParamsOverridableMethods = require("../hooks/features/rows/useGridParamsOverridableMethods");
|
|
19
|
+
var _useGridCellEditable = require("../hooks/features/editing/useGridCellEditable");
|
|
19
20
|
var _GridContextProvider = require("../context/GridContextProvider");
|
|
20
21
|
var _useDataGridComponent = require("./useDataGridComponent");
|
|
21
22
|
var _useDataGridProps = require("./useDataGridProps");
|
|
@@ -30,6 +31,7 @@ const configuration = {
|
|
|
30
31
|
useGridRowAriaAttributes: _useGridRowAriaAttributes.useGridRowAriaAttributes,
|
|
31
32
|
useGridRowsOverridableMethods: _useGridRowsOverridableMethods.useGridRowsOverridableMethods,
|
|
32
33
|
useGridParamsOverridableMethods: _useGridParamsOverridableMethods.useGridParamsOverridableMethods,
|
|
34
|
+
useIsCellEditable: _useGridCellEditable.useIsCellEditable,
|
|
33
35
|
useCellAggregationResult: () => null,
|
|
34
36
|
useFilterValueGetter: apiRef => apiRef.current.getRowValue
|
|
35
37
|
}
|
|
@@ -81,7 +81,7 @@ const useDataGridComponent = (apiRef, props, configuration) => {
|
|
|
81
81
|
(0, _useGridParamsApi.useGridParamsApi)(apiRef, props, configuration);
|
|
82
82
|
(0, _useGridColumnSpanning.useGridColumnSpanning)(apiRef);
|
|
83
83
|
(0, _useGridColumnGrouping.useGridColumnGrouping)(apiRef, props);
|
|
84
|
-
(0, _useGridEditing.useGridEditing)(apiRef, props);
|
|
84
|
+
(0, _useGridEditing.useGridEditing)(apiRef, props, configuration);
|
|
85
85
|
(0, _useGridFocus.useGridFocus)(apiRef, props);
|
|
86
86
|
(0, _useGridPreferencesPanel.useGridPreferencesPanel)(apiRef, props);
|
|
87
87
|
(0, _useGridFilter.useGridFilter)(apiRef, props, configuration);
|
package/esm/DataGrid/DataGrid.js
CHANGED
|
@@ -9,6 +9,7 @@ import { useGridAriaAttributes } from "../hooks/utils/useGridAriaAttributes.js";
|
|
|
9
9
|
import { useGridRowAriaAttributes } from "../hooks/features/rows/useGridRowAriaAttributes.js";
|
|
10
10
|
import { useGridRowsOverridableMethods } from "../hooks/features/rows/useGridRowsOverridableMethods.js";
|
|
11
11
|
import { useGridParamsOverridableMethods } from "../hooks/features/rows/useGridParamsOverridableMethods.js";
|
|
12
|
+
import { useIsCellEditable } from "../hooks/features/editing/useGridCellEditable.js";
|
|
12
13
|
import { GridContextProvider } from "../context/GridContextProvider.js";
|
|
13
14
|
import { useDataGridComponent } from "./useDataGridComponent.js";
|
|
14
15
|
import { useDataGridProps } from "./useDataGridProps.js";
|
|
@@ -23,6 +24,7 @@ const configuration = {
|
|
|
23
24
|
useGridRowAriaAttributes,
|
|
24
25
|
useGridRowsOverridableMethods,
|
|
25
26
|
useGridParamsOverridableMethods,
|
|
27
|
+
useIsCellEditable,
|
|
26
28
|
useCellAggregationResult: () => null,
|
|
27
29
|
useFilterValueGetter: apiRef => apiRef.current.getRowValue
|
|
28
30
|
}
|
|
@@ -75,7 +75,7 @@ export const useDataGridComponent = (apiRef, props, configuration) => {
|
|
|
75
75
|
useGridParamsApi(apiRef, props, configuration);
|
|
76
76
|
useGridColumnSpanning(apiRef);
|
|
77
77
|
useGridColumnGrouping(apiRef, props);
|
|
78
|
-
useGridEditing(apiRef, props);
|
|
78
|
+
useGridEditing(apiRef, props, configuration);
|
|
79
79
|
useGridFocus(apiRef, props);
|
|
80
80
|
useGridPreferencesPanel(apiRef, props);
|
|
81
81
|
useGridFilter(apiRef, props, configuration);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { isAutogeneratedRowNode } from "../rows/gridRowsUtils.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Default implementation of the cell editable condition hook
|
|
8
|
+
*/
|
|
9
|
+
export const useIsCellEditable = () => React.useCallback(params => !isAutogeneratedRowNode(params.rowNode), []);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { GridPrivateApiCommunity } from "../../../models/api/gridApiCommunity.js";
|
|
3
3
|
import { DataGridProcessedProps } from "../../../models/props/DataGridProps.js";
|
|
4
|
+
import { GridConfiguration } from "../../../models/configuration/gridConfiguration.js";
|
|
4
5
|
import { GridStateInitializer } from "../../utils/useGridInitializeState.js";
|
|
5
6
|
export declare const editingStateInitializer: GridStateInitializer;
|
|
6
|
-
export declare const useGridEditing: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "isCellEditable" | "editMode" | "processRowUpdate" | "dataSource" | "onDataSourceError"
|
|
7
|
+
export declare const useGridEditing: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "isCellEditable" | "editMode" | "processRowUpdate" | "dataSource" | "onDataSourceError">, configuration: GridConfiguration) => void;
|
|
@@ -7,19 +7,19 @@ import { useGridCellEditing } from "./useGridCellEditing.js";
|
|
|
7
7
|
import { GridCellModes, GridEditModes } from "../../../models/gridEditRowModel.js";
|
|
8
8
|
import { useGridRowEditing } from "./useGridRowEditing.js";
|
|
9
9
|
import { gridEditRowsStateSelector } from "./gridEditingSelectors.js";
|
|
10
|
-
import { isAutogeneratedRowNode } from "../rows/gridRowsUtils.js";
|
|
11
10
|
export const editingStateInitializer = state => _extends({}, state, {
|
|
12
11
|
editRows: {}
|
|
13
12
|
});
|
|
14
|
-
export const useGridEditing = (apiRef, props) => {
|
|
13
|
+
export const useGridEditing = (apiRef, props, configuration) => {
|
|
15
14
|
useGridCellEditing(apiRef, props);
|
|
16
15
|
useGridRowEditing(apiRef, props);
|
|
17
16
|
const debounceMap = React.useRef({});
|
|
18
17
|
const {
|
|
19
18
|
isCellEditable: isCellEditableProp
|
|
20
19
|
} = props;
|
|
20
|
+
const isCellEditableFn = configuration.hooks.useIsCellEditable(apiRef, props);
|
|
21
21
|
const isCellEditable = React.useCallback(params => {
|
|
22
|
-
if (
|
|
22
|
+
if (!isCellEditableFn(params)) {
|
|
23
23
|
return false;
|
|
24
24
|
}
|
|
25
25
|
if (!params.colDef.editable) {
|
|
@@ -32,7 +32,7 @@ export const useGridEditing = (apiRef, props) => {
|
|
|
32
32
|
return isCellEditableProp(params);
|
|
33
33
|
}
|
|
34
34
|
return true;
|
|
35
|
-
}, [isCellEditableProp]);
|
|
35
|
+
}, [isCellEditableProp, isCellEditableFn]);
|
|
36
36
|
const maybeDebounce = (id, field, debounceMs, callback) => {
|
|
37
37
|
if (!debounceMs) {
|
|
38
38
|
callback();
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import * as React from 'react';
|
|
5
|
+
import debounce from '@mui/utils/debounce';
|
|
5
6
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
6
7
|
import ownerDocument from '@mui/utils/ownerDocument';
|
|
7
8
|
import { gridClasses } from "../../../constants/gridClasses.js";
|
|
@@ -318,7 +319,7 @@ export const useGridFocus = (apiRef, props) => {
|
|
|
318
319
|
apiRef.current.setCellFocus(params.id, params.field);
|
|
319
320
|
}
|
|
320
321
|
}, [apiRef]);
|
|
321
|
-
const
|
|
322
|
+
const handleRowsSet = React.useCallback(() => {
|
|
322
323
|
const cell = gridFocusCellSelector(apiRef);
|
|
323
324
|
|
|
324
325
|
// If the focused cell is in a row which does not exist anymore,
|
|
@@ -349,6 +350,7 @@ export const useGridFocus = (apiRef, props) => {
|
|
|
349
350
|
}));
|
|
350
351
|
}
|
|
351
352
|
}, [apiRef, props.pagination, props.paginationMode]);
|
|
353
|
+
const debouncedHandleRowsSet = React.useMemo(() => debounce(handleRowsSet, 0), [handleRowsSet]);
|
|
352
354
|
const handlePaginationModelChange = useEventCallback(() => {
|
|
353
355
|
const currentFocusedCell = gridFocusCellSelector(apiRef);
|
|
354
356
|
if (!currentFocusedCell) {
|
|
@@ -403,6 +405,6 @@ export const useGridFocus = (apiRef, props) => {
|
|
|
403
405
|
useGridEvent(apiRef, 'cellModeChange', handleCellModeChange);
|
|
404
406
|
useGridEvent(apiRef, 'columnHeaderFocus', handleColumnHeaderFocus);
|
|
405
407
|
useGridEvent(apiRef, 'columnGroupHeaderFocus', handleColumnGroupHeaderFocus);
|
|
406
|
-
useGridEvent(apiRef, 'rowsSet',
|
|
408
|
+
useGridEvent(apiRef, 'rowsSet', debouncedHandleRowsSet);
|
|
407
409
|
useGridEvent(apiRef, 'paginationModelChange', handlePaginationModelChange);
|
|
408
410
|
};
|
|
@@ -506,7 +506,9 @@ export const useGridRowSelection = (apiRef, props) => {
|
|
|
506
506
|
}
|
|
507
507
|
if (String.fromCharCode(event.keyCode) === 'A' && (event.ctrlKey || event.metaKey)) {
|
|
508
508
|
event.preventDefault();
|
|
509
|
-
|
|
509
|
+
if (canHaveMultipleSelection) {
|
|
510
|
+
toggleAllRows(true);
|
|
511
|
+
}
|
|
510
512
|
}
|
|
511
513
|
}, [apiRef, canHaveMultipleSelection, handleSingleRowSelection, toggleAllRows]);
|
|
512
514
|
const syncControlledState = useEventCallback(() => {
|
package/esm/index.js
CHANGED
package/esm/internals/index.d.ts
CHANGED
|
@@ -56,6 +56,7 @@ export { useGridAriaAttributes } from "../hooks/utils/useGridAriaAttributes.js";
|
|
|
56
56
|
export { useGridRowAriaAttributes } from "../hooks/features/rows/useGridRowAriaAttributes.js";
|
|
57
57
|
export { useGridRowsOverridableMethods } from "../hooks/features/rows/useGridRowsOverridableMethods.js";
|
|
58
58
|
export { useGridParamsOverridableMethods } from "../hooks/features/rows/useGridParamsOverridableMethods.js";
|
|
59
|
+
export { useIsCellEditable } from "../hooks/features/editing/useGridCellEditable.js";
|
|
59
60
|
export { useGridRowsPreProcessors } from "../hooks/features/rows/useGridRowsPreProcessors.js";
|
|
60
61
|
export type { GridRowTreeCreationParams, GridRowTreeCreationValue, GridHydrateRowsValue, GridRowsPartialUpdates, GridRowsPartialUpdateAction, GridTreeDepths, GridPinnedRowsState } from "../hooks/features/rows/gridRowsInterfaces.js";
|
|
61
62
|
export { getTreeNodeDescendants, buildRootGroup } from "../hooks/features/rows/gridRowsUtils.js";
|
|
@@ -117,6 +118,7 @@ export type { Localization } from "../utils/getGridLocalization.js";
|
|
|
117
118
|
export * from "./demo/index.js";
|
|
118
119
|
export { GridSkeletonLoadingOverlayInner } from "../components/GridSkeletonLoadingOverlay.js";
|
|
119
120
|
export type { GridConfiguration } from "../models/configuration/gridConfiguration.js";
|
|
121
|
+
export type { CellEditableConditionFn } from "../models/configuration/gridCellEditableConfiguration.js";
|
|
120
122
|
export * from "../hooks/features/pivoting/index.js";
|
|
121
123
|
export { createSvgIcon } from "../material/icons/createSvgIcon.js";
|
|
122
124
|
export { useGridPanelContext } from "../components/panel/GridPanelContext.js";
|
package/esm/internals/index.js
CHANGED
|
@@ -45,6 +45,7 @@ export { useGridAriaAttributes } from "../hooks/utils/useGridAriaAttributes.js";
|
|
|
45
45
|
export { useGridRowAriaAttributes } from "../hooks/features/rows/useGridRowAriaAttributes.js";
|
|
46
46
|
export { useGridRowsOverridableMethods } from "../hooks/features/rows/useGridRowsOverridableMethods.js";
|
|
47
47
|
export { useGridParamsOverridableMethods } from "../hooks/features/rows/useGridParamsOverridableMethods.js";
|
|
48
|
+
export { useIsCellEditable } from "../hooks/features/editing/useGridCellEditable.js";
|
|
48
49
|
export { useGridRowsPreProcessors } from "../hooks/features/rows/useGridRowsPreProcessors.js";
|
|
49
50
|
export { getTreeNodeDescendants, buildRootGroup } from "../hooks/features/rows/gridRowsUtils.js";
|
|
50
51
|
export { useGridRowsMeta, rowsMetaStateInitializer } from "../hooks/features/rows/useGridRowsMeta.js";
|
package/esm/locales/esES.js
CHANGED
|
@@ -3,10 +3,9 @@ const esESGrid = {
|
|
|
3
3
|
// Root
|
|
4
4
|
noRowsLabel: 'Sin filas',
|
|
5
5
|
noResultsOverlayLabel: 'Resultados no encontrados',
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
noColumnsOverlayLabel: 'Ninguna columna',
|
|
7
|
+
noColumnsOverlayManageColumns: 'Gestionar columnas',
|
|
8
|
+
emptyPivotOverlayLabel: 'Añada campos a filas, columnas y valores para crear una tabla dinámica',
|
|
10
9
|
// Density selector toolbar button text
|
|
11
10
|
toolbarDensity: 'Densidad',
|
|
12
11
|
toolbarDensityLabel: 'Densidad',
|
|
@@ -33,14 +32,11 @@ const esESGrid = {
|
|
|
33
32
|
toolbarExportPrint: 'Imprimir',
|
|
34
33
|
toolbarExportExcel: 'Descargar como Excel',
|
|
35
34
|
// Toolbar pivot button
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
toolbarPivot: 'Tabla dinámica',
|
|
38
36
|
// Toolbar charts button
|
|
39
|
-
|
|
40
|
-
|
|
37
|
+
toolbarCharts: 'Gráficos',
|
|
41
38
|
// Toolbar AI Assistant button
|
|
42
|
-
|
|
43
|
-
|
|
39
|
+
toolbarAssistant: 'Asistente de IA',
|
|
44
40
|
// Columns management text
|
|
45
41
|
columnsManagementSearchTitle: 'Buscar',
|
|
46
42
|
columnsManagementNoColumns: 'Sin columnas',
|
|
@@ -102,15 +98,14 @@ const esESGrid = {
|
|
|
102
98
|
'headerFilterOperator>=': 'Es mayor o igual que',
|
|
103
99
|
'headerFilterOperator<': 'Es menor que',
|
|
104
100
|
'headerFilterOperator<=': 'Es menor o igual que',
|
|
105
|
-
|
|
106
|
-
|
|
101
|
+
headerFilterClear: 'Limpiar filtros',
|
|
107
102
|
// Filter values text
|
|
108
103
|
filterValueAny: 'cualquiera',
|
|
109
104
|
filterValueTrue: 'verdadero',
|
|
110
105
|
filterValueFalse: 'falso',
|
|
111
106
|
// Column menu text
|
|
112
107
|
columnMenuLabel: 'Menú',
|
|
113
|
-
|
|
108
|
+
columnMenuAriaLabel: columnName => `Menú de la columna ${columnName}`,
|
|
114
109
|
columnMenuShowColumns: 'Mostrar columnas',
|
|
115
110
|
columnMenuManageColumns: 'Administrar columnas',
|
|
116
111
|
columnMenuFilter: 'Filtro',
|
|
@@ -118,9 +113,8 @@ const esESGrid = {
|
|
|
118
113
|
columnMenuUnsort: 'Desordenar',
|
|
119
114
|
columnMenuSortAsc: 'Ordenar ASC',
|
|
120
115
|
columnMenuSortDesc: 'Ordenar DESC',
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
116
|
+
columnMenuManagePivot: 'Gestionar tabla dinámica',
|
|
117
|
+
columnMenuManageCharts: 'Gestionar gráficos',
|
|
124
118
|
// Column header text
|
|
125
119
|
columnHeaderFiltersTooltipActive: count => count > 1 ? `${count} filtros activos` : `${count} filtro activo`,
|
|
126
120
|
columnHeaderFiltersLabel: 'Mostrar filtros',
|
|
@@ -160,18 +154,18 @@ const esESGrid = {
|
|
|
160
154
|
collapseDetailPanel: 'Contraer',
|
|
161
155
|
// Pagination
|
|
162
156
|
paginationRowsPerPage: 'Filas por página:',
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
157
|
+
paginationDisplayedRows: ({
|
|
158
|
+
from,
|
|
159
|
+
to,
|
|
160
|
+
count,
|
|
161
|
+
estimated
|
|
162
|
+
}) => {
|
|
163
|
+
if (!estimated) {
|
|
164
|
+
return `${from}–${to} de ${count !== -1 ? count : `más de ${to}`}`;
|
|
165
|
+
}
|
|
166
|
+
const estimatedLabel = estimated && estimated > to ? `alrededor de ${estimated}` : `más de ${to}`;
|
|
167
|
+
return `${from}–${to} de ${count !== -1 ? count : estimatedLabel}`;
|
|
168
|
+
},
|
|
175
169
|
paginationItemAriaLabel: type => {
|
|
176
170
|
if (type === 'first') {
|
|
177
171
|
return 'Ir a la primera página';
|
|
@@ -189,114 +183,109 @@ const esESGrid = {
|
|
|
189
183
|
rowReorderingHeaderName: 'Reordenar filas',
|
|
190
184
|
// Aggregation
|
|
191
185
|
aggregationMenuItemHeader: 'Agregación',
|
|
192
|
-
|
|
186
|
+
aggregationFunctionLabelNone: 'ninguna',
|
|
193
187
|
aggregationFunctionLabelSum: 'suma',
|
|
194
188
|
aggregationFunctionLabelAvg: 'promedio',
|
|
195
189
|
aggregationFunctionLabelMin: 'mínimo',
|
|
196
190
|
aggregationFunctionLabelMax: 'máximo',
|
|
197
191
|
aggregationFunctionLabelSize: 'tamaño',
|
|
198
192
|
// Pivot panel
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
193
|
+
pivotToggleLabel: 'Tabla dinámica',
|
|
194
|
+
pivotRows: 'Filas',
|
|
195
|
+
pivotColumns: 'Columnas',
|
|
196
|
+
pivotValues: 'Valores',
|
|
197
|
+
pivotCloseButton: 'Cerrar la configuración de tabla dinámica',
|
|
198
|
+
pivotSearchButton: 'Campos de búsqueda',
|
|
199
|
+
pivotSearchControlPlaceholder: 'Campos de búsqueda',
|
|
200
|
+
pivotSearchControlLabel: 'Campos de búsqueda',
|
|
201
|
+
pivotSearchControlClear: 'Limpiar la búsqueda',
|
|
202
|
+
pivotNoFields: 'Ningún campo',
|
|
203
|
+
pivotMenuMoveUp: 'Mover arriba',
|
|
204
|
+
pivotMenuMoveDown: 'Mover abajo',
|
|
205
|
+
pivotMenuMoveToTop: 'Mover al inicio',
|
|
206
|
+
pivotMenuMoveToBottom: 'Mover al final',
|
|
207
|
+
pivotMenuRows: 'Filas',
|
|
208
|
+
pivotMenuColumns: 'Columnas',
|
|
209
|
+
pivotMenuValues: 'Valores',
|
|
210
|
+
pivotMenuOptions: 'Opciones de campo',
|
|
211
|
+
pivotMenuAddToRows: 'Añadir a filas',
|
|
212
|
+
pivotMenuAddToColumns: 'Añadir a columnas',
|
|
213
|
+
pivotMenuAddToValues: 'Añadir a valores',
|
|
214
|
+
pivotMenuRemove: 'Eliminar',
|
|
215
|
+
pivotDragToRows: 'Arrastrar aquí para crear filas',
|
|
216
|
+
pivotDragToColumns: 'Arrastrar aquí para crear columnas',
|
|
217
|
+
pivotDragToValues: 'Arrastrar aquí para crear valores',
|
|
218
|
+
pivotYearColumnHeaderName: '(Año)',
|
|
219
|
+
pivotQuarterColumnHeaderName: '(Trimestre)',
|
|
227
220
|
// Charts configuration panel
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
221
|
+
chartsNoCharts: 'No hay ningún gráfico disponible',
|
|
222
|
+
chartsChartNotSelected: 'Seleccionar un tipo de gráfico para configurar sus opciones',
|
|
223
|
+
chartsTabChart: 'Gráfico',
|
|
224
|
+
chartsTabFields: 'Campos',
|
|
225
|
+
chartsTabCustomize: 'Personalizar',
|
|
226
|
+
chartsCloseButton: 'Cerrar la configuración de gráficos',
|
|
227
|
+
chartsSyncButtonLabel: 'Sincronizar gráfico',
|
|
228
|
+
chartsSearchPlaceholder: 'Campos de búsqueda',
|
|
229
|
+
chartsSearchLabel: 'Campos de búsqueda',
|
|
230
|
+
chartsSearchClear: 'Limpiar búsqueda',
|
|
231
|
+
chartsNoFields: 'Ningún campo',
|
|
232
|
+
chartsFieldBlocked: 'Este campo no se puede añadir a ninguna sección',
|
|
233
|
+
chartsCategories: 'Categorías',
|
|
234
|
+
chartsSeries: 'Series',
|
|
235
|
+
chartsMenuAddToDimensions: dimensionLabel => `Añadir a ${dimensionLabel}`,
|
|
236
|
+
chartsMenuAddToValues: valuesLabel => `Añadir a ${valuesLabel}`,
|
|
237
|
+
chartsMenuMoveUp: 'Mover arriba',
|
|
238
|
+
chartsMenuMoveDown: 'Mover abajo',
|
|
239
|
+
chartsMenuMoveToTop: 'Mover al inicio',
|
|
240
|
+
chartsMenuMoveToBottom: 'Mover al final',
|
|
241
|
+
chartsMenuOptions: 'Opciones de campo',
|
|
242
|
+
chartsMenuRemove: 'Eliminar',
|
|
243
|
+
chartsDragToDimensions: dimensionLabel => `Arrastrar aquí para utilizar la columna como ${dimensionLabel}`,
|
|
244
|
+
chartsDragToValues: valuesLabel => `Arrastrar aquí para utilizar la columna como ${valuesLabel}`,
|
|
253
245
|
// AI Assistant panel
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
246
|
+
aiAssistantPanelTitle: 'Asistente de IA',
|
|
247
|
+
aiAssistantPanelClose: 'Cerrar el asistente de IA',
|
|
248
|
+
aiAssistantPanelNewConversation: 'Nueva conversación',
|
|
249
|
+
aiAssistantPanelConversationHistory: 'Historial de conversaciones',
|
|
250
|
+
aiAssistantPanelEmptyConversation: 'El historial de conversaciones está vacío',
|
|
251
|
+
aiAssistantSuggestions: 'Sugerencias',
|
|
261
252
|
// Prompt field
|
|
262
253
|
promptFieldLabel: 'Prompt',
|
|
263
254
|
promptFieldPlaceholder: 'Escribe un prompt…',
|
|
264
255
|
promptFieldPlaceholderWithRecording: 'Escriba o grabe un prompt…',
|
|
265
256
|
promptFieldPlaceholderListening: 'Esperando por un prompt…',
|
|
266
|
-
|
|
257
|
+
promptFieldSpeechRecognitionNotSupported: 'El reconocimiento de voz no está soportado en este navegador',
|
|
267
258
|
promptFieldSend: 'Enviar',
|
|
268
259
|
promptFieldRecord: 'Grabar',
|
|
269
|
-
promptFieldStopRecording: 'Parar de grabar'
|
|
270
|
-
|
|
260
|
+
promptFieldStopRecording: 'Parar de grabar',
|
|
271
261
|
// Prompt
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
262
|
+
promptRerun: 'Ejecutar de nuevo',
|
|
263
|
+
promptProcessing: 'Procesando…',
|
|
264
|
+
promptAppliedChanges: 'Se han aplicado los cambios',
|
|
276
265
|
// Prompt changes
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
266
|
+
promptChangeGroupDescription: column => `Agrupar por ${column}`,
|
|
267
|
+
promptChangeAggregationLabel: (column, aggregation) => `${column} (${aggregation})`,
|
|
268
|
+
promptChangeAggregationDescription: (column, aggregation) => `Agregar ${column} (${aggregation})`,
|
|
269
|
+
promptChangeFilterLabel: (column, operator, value) => {
|
|
270
|
+
if (operator === 'is any of') {
|
|
271
|
+
return `${column} es uno de: ${value}`;
|
|
272
|
+
}
|
|
273
|
+
return `${column} ${operator} ${value}`;
|
|
274
|
+
},
|
|
275
|
+
promptChangeFilterDescription: (column, operator, value) => {
|
|
276
|
+
if (operator === 'is any of') {
|
|
277
|
+
return `Filtrar por ${column} cuando sea uno de: ${value}`;
|
|
278
|
+
}
|
|
279
|
+
return `Filtrar por ${column} ${operator} ${value}`;
|
|
280
|
+
},
|
|
281
|
+
promptChangeSortDescription: (column, direction) => `Ordenar por ${column} (${direction})`,
|
|
282
|
+
promptChangePivotEnableLabel: 'Tabla dinámica',
|
|
283
|
+
promptChangePivotEnableDescription: 'Activar tabla dinámica',
|
|
284
|
+
promptChangePivotColumnsLabel: count => `Columnas (${count})`,
|
|
285
|
+
promptChangePivotColumnsDescription: (column, direction) => `${column}${direction ? ` (${direction})` : ''}`,
|
|
286
|
+
promptChangePivotRowsLabel: count => `Filas (${count})`,
|
|
287
|
+
promptChangePivotValuesLabel: count => `Valores (${count})`,
|
|
288
|
+
promptChangePivotValuesDescription: (column, aggregation) => `${column} (${aggregation})`,
|
|
289
|
+
promptChangeChartsLabel: (dimensionsCount, valuesCount) => `Dimensiones (${dimensionsCount}), Valores (${valuesCount})`
|
|
301
290
|
};
|
|
302
291
|
export const esES = getGridLocalization(esESGrid);
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { GridPrivateApiCommunity } from "../api/gridApiCommunity.js";
|
|
3
|
+
import { DataGridProcessedProps } from "../props/DataGridProps.js";
|
|
4
|
+
import { GridEditingApi } from "../api/gridEditingApi.js";
|
|
5
|
+
/**
|
|
6
|
+
* Get the cell editable condition function
|
|
7
|
+
* @param {Object} params The cell parameters
|
|
8
|
+
* @param {Object} params.rowNode The row node
|
|
9
|
+
* @param {Object} params.colDef The column definition
|
|
10
|
+
* @param {any} params.value The cell value
|
|
11
|
+
* @returns {boolean} Whether the cell is editable
|
|
12
|
+
*/
|
|
13
|
+
export type CellEditableConditionFn = (params: Parameters<GridEditingApi['isCellEditable']>[0]) => boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Cell editable configuration interface for internal hooks
|
|
16
|
+
*/
|
|
17
|
+
export interface GridCellEditableInternalHook<Api = GridPrivateApiCommunity, Props = DataGridProcessedProps> {
|
|
18
|
+
useIsCellEditable: (apiRef: RefObject<Api>, props: Props) => CellEditableConditionFn;
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridRowAriaAttributesInternalHook, GridRowsOverridableMethodsInternalHook } from "./gridRowConfiguration.js";
|
|
3
3
|
import type { GridAggregationInternalHooks } from "./gridAggregationConfiguration.js";
|
|
4
|
+
import type { GridCellEditableInternalHook } from "./gridCellEditableConfiguration.js";
|
|
4
5
|
import type { GridCSSVariablesInterface } from "../../constants/cssVariables.js";
|
|
5
6
|
import { DataGridProcessedProps } from "../props/DataGridProps.js";
|
|
6
7
|
import type { GridPrivateApiCommon } from "../api/gridApiCommon.js";
|
|
@@ -9,7 +10,7 @@ import type { GridParamsOverridableMethodsInternalHook } from "./gridParamsConfi
|
|
|
9
10
|
export interface GridAriaAttributesInternalHook {
|
|
10
11
|
useGridAriaAttributes: () => React.HTMLAttributes<HTMLElement>;
|
|
11
12
|
}
|
|
12
|
-
export interface GridInternalHook<Api, Props> extends GridAriaAttributesInternalHook, GridRowAriaAttributesInternalHook, GridAggregationInternalHooks<Api, Props>, GridRowsOverridableMethodsInternalHook<Api>, GridParamsOverridableMethodsInternalHook<Api> {
|
|
13
|
+
export interface GridInternalHook<Api, Props> extends GridAriaAttributesInternalHook, GridRowAriaAttributesInternalHook, GridCellEditableInternalHook<Api, Props>, GridAggregationInternalHooks<Api, Props>, GridRowsOverridableMethodsInternalHook<Api>, GridParamsOverridableMethodsInternalHook<Api> {
|
|
13
14
|
useCSSVariables: () => {
|
|
14
15
|
id: string;
|
|
15
16
|
variables: GridCSSVariablesInterface;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
'use client';
|
|
3
|
+
|
|
4
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.useIsCellEditable = void 0;
|
|
9
|
+
var React = _interopRequireWildcard(require("react"));
|
|
10
|
+
var _gridRowsUtils = require("../rows/gridRowsUtils");
|
|
11
|
+
/**
|
|
12
|
+
* Default implementation of the cell editable condition hook
|
|
13
|
+
*/
|
|
14
|
+
const useIsCellEditable = () => React.useCallback(params => !(0, _gridRowsUtils.isAutogeneratedRowNode)(params.rowNode), []);
|
|
15
|
+
exports.useIsCellEditable = useIsCellEditable;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { GridPrivateApiCommunity } from "../../../models/api/gridApiCommunity.js";
|
|
3
3
|
import { DataGridProcessedProps } from "../../../models/props/DataGridProps.js";
|
|
4
|
+
import { GridConfiguration } from "../../../models/configuration/gridConfiguration.js";
|
|
4
5
|
import { GridStateInitializer } from "../../utils/useGridInitializeState.js";
|
|
5
6
|
export declare const editingStateInitializer: GridStateInitializer;
|
|
6
|
-
export declare const useGridEditing: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "isCellEditable" | "editMode" | "processRowUpdate" | "dataSource" | "onDataSourceError"
|
|
7
|
+
export declare const useGridEditing: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "isCellEditable" | "editMode" | "processRowUpdate" | "dataSource" | "onDataSourceError">, configuration: GridConfiguration) => void;
|
|
@@ -14,20 +14,20 @@ var _useGridCellEditing = require("./useGridCellEditing");
|
|
|
14
14
|
var _gridEditRowModel = require("../../../models/gridEditRowModel");
|
|
15
15
|
var _useGridRowEditing = require("./useGridRowEditing");
|
|
16
16
|
var _gridEditingSelectors = require("./gridEditingSelectors");
|
|
17
|
-
var _gridRowsUtils = require("../rows/gridRowsUtils");
|
|
18
17
|
const editingStateInitializer = state => (0, _extends2.default)({}, state, {
|
|
19
18
|
editRows: {}
|
|
20
19
|
});
|
|
21
20
|
exports.editingStateInitializer = editingStateInitializer;
|
|
22
|
-
const useGridEditing = (apiRef, props) => {
|
|
21
|
+
const useGridEditing = (apiRef, props, configuration) => {
|
|
23
22
|
(0, _useGridCellEditing.useGridCellEditing)(apiRef, props);
|
|
24
23
|
(0, _useGridRowEditing.useGridRowEditing)(apiRef, props);
|
|
25
24
|
const debounceMap = React.useRef({});
|
|
26
25
|
const {
|
|
27
26
|
isCellEditable: isCellEditableProp
|
|
28
27
|
} = props;
|
|
28
|
+
const isCellEditableFn = configuration.hooks.useIsCellEditable(apiRef, props);
|
|
29
29
|
const isCellEditable = React.useCallback(params => {
|
|
30
|
-
if ((
|
|
30
|
+
if (!isCellEditableFn(params)) {
|
|
31
31
|
return false;
|
|
32
32
|
}
|
|
33
33
|
if (!params.colDef.editable) {
|
|
@@ -40,7 +40,7 @@ const useGridEditing = (apiRef, props) => {
|
|
|
40
40
|
return isCellEditableProp(params);
|
|
41
41
|
}
|
|
42
42
|
return true;
|
|
43
|
-
}, [isCellEditableProp]);
|
|
43
|
+
}, [isCellEditableProp, isCellEditableFn]);
|
|
44
44
|
const maybeDebounce = (id, field, debounceMs, callback) => {
|
|
45
45
|
if (!debounceMs) {
|
|
46
46
|
callback();
|
|
@@ -9,6 +9,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
9
9
|
exports.useGridFocus = exports.focusStateInitializer = void 0;
|
|
10
10
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
11
|
var React = _interopRequireWildcard(require("react"));
|
|
12
|
+
var _debounce = _interopRequireDefault(require("@mui/utils/debounce"));
|
|
12
13
|
var _useEventCallback = _interopRequireDefault(require("@mui/utils/useEventCallback"));
|
|
13
14
|
var _ownerDocument = _interopRequireDefault(require("@mui/utils/ownerDocument"));
|
|
14
15
|
var _gridClasses = require("../../../constants/gridClasses");
|
|
@@ -326,7 +327,7 @@ const useGridFocus = (apiRef, props) => {
|
|
|
326
327
|
apiRef.current.setCellFocus(params.id, params.field);
|
|
327
328
|
}
|
|
328
329
|
}, [apiRef]);
|
|
329
|
-
const
|
|
330
|
+
const handleRowsSet = React.useCallback(() => {
|
|
330
331
|
const cell = (0, _gridFocusStateSelector.gridFocusCellSelector)(apiRef);
|
|
331
332
|
|
|
332
333
|
// If the focused cell is in a row which does not exist anymore,
|
|
@@ -357,6 +358,7 @@ const useGridFocus = (apiRef, props) => {
|
|
|
357
358
|
}));
|
|
358
359
|
}
|
|
359
360
|
}, [apiRef, props.pagination, props.paginationMode]);
|
|
361
|
+
const debouncedHandleRowsSet = React.useMemo(() => (0, _debounce.default)(handleRowsSet, 0), [handleRowsSet]);
|
|
360
362
|
const handlePaginationModelChange = (0, _useEventCallback.default)(() => {
|
|
361
363
|
const currentFocusedCell = (0, _gridFocusStateSelector.gridFocusCellSelector)(apiRef);
|
|
362
364
|
if (!currentFocusedCell) {
|
|
@@ -411,7 +413,7 @@ const useGridFocus = (apiRef, props) => {
|
|
|
411
413
|
(0, _useGridEvent.useGridEvent)(apiRef, 'cellModeChange', handleCellModeChange);
|
|
412
414
|
(0, _useGridEvent.useGridEvent)(apiRef, 'columnHeaderFocus', handleColumnHeaderFocus);
|
|
413
415
|
(0, _useGridEvent.useGridEvent)(apiRef, 'columnGroupHeaderFocus', handleColumnGroupHeaderFocus);
|
|
414
|
-
(0, _useGridEvent.useGridEvent)(apiRef, 'rowsSet',
|
|
416
|
+
(0, _useGridEvent.useGridEvent)(apiRef, 'rowsSet', debouncedHandleRowsSet);
|
|
415
417
|
(0, _useGridEvent.useGridEvent)(apiRef, 'paginationModelChange', handlePaginationModelChange);
|
|
416
418
|
};
|
|
417
419
|
exports.useGridFocus = useGridFocus;
|
|
@@ -514,7 +514,9 @@ const useGridRowSelection = (apiRef, props) => {
|
|
|
514
514
|
}
|
|
515
515
|
if (String.fromCharCode(event.keyCode) === 'A' && (event.ctrlKey || event.metaKey)) {
|
|
516
516
|
event.preventDefault();
|
|
517
|
-
|
|
517
|
+
if (canHaveMultipleSelection) {
|
|
518
|
+
toggleAllRows(true);
|
|
519
|
+
}
|
|
518
520
|
}
|
|
519
521
|
}, [apiRef, canHaveMultipleSelection, handleSingleRowSelection, toggleAllRows]);
|
|
520
522
|
const syncControlledState = (0, _useEventCallback.default)(() => {
|
package/index.js
CHANGED
package/internals/index.d.ts
CHANGED
|
@@ -56,6 +56,7 @@ export { useGridAriaAttributes } from "../hooks/utils/useGridAriaAttributes.js";
|
|
|
56
56
|
export { useGridRowAriaAttributes } from "../hooks/features/rows/useGridRowAriaAttributes.js";
|
|
57
57
|
export { useGridRowsOverridableMethods } from "../hooks/features/rows/useGridRowsOverridableMethods.js";
|
|
58
58
|
export { useGridParamsOverridableMethods } from "../hooks/features/rows/useGridParamsOverridableMethods.js";
|
|
59
|
+
export { useIsCellEditable } from "../hooks/features/editing/useGridCellEditable.js";
|
|
59
60
|
export { useGridRowsPreProcessors } from "../hooks/features/rows/useGridRowsPreProcessors.js";
|
|
60
61
|
export type { GridRowTreeCreationParams, GridRowTreeCreationValue, GridHydrateRowsValue, GridRowsPartialUpdates, GridRowsPartialUpdateAction, GridTreeDepths, GridPinnedRowsState } from "../hooks/features/rows/gridRowsInterfaces.js";
|
|
61
62
|
export { getTreeNodeDescendants, buildRootGroup } from "../hooks/features/rows/gridRowsUtils.js";
|
|
@@ -117,6 +118,7 @@ export type { Localization } from "../utils/getGridLocalization.js";
|
|
|
117
118
|
export * from "./demo/index.js";
|
|
118
119
|
export { GridSkeletonLoadingOverlayInner } from "../components/GridSkeletonLoadingOverlay.js";
|
|
119
120
|
export type { GridConfiguration } from "../models/configuration/gridConfiguration.js";
|
|
121
|
+
export type { CellEditableConditionFn } from "../models/configuration/gridCellEditableConfiguration.js";
|
|
120
122
|
export * from "../hooks/features/pivoting/index.js";
|
|
121
123
|
export { createSvgIcon } from "../material/icons/createSvgIcon.js";
|
|
122
124
|
export { useGridPanelContext } from "../components/panel/GridPanelContext.js";
|
package/internals/index.js
CHANGED
|
@@ -66,6 +66,7 @@ var _exportNames = {
|
|
|
66
66
|
useGridRowAriaAttributes: true,
|
|
67
67
|
useGridRowsOverridableMethods: true,
|
|
68
68
|
useGridParamsOverridableMethods: true,
|
|
69
|
+
useIsCellEditable: true,
|
|
69
70
|
useGridRowsPreProcessors: true,
|
|
70
71
|
getTreeNodeDescendants: true,
|
|
71
72
|
buildRootGroup: true,
|
|
@@ -833,6 +834,12 @@ Object.defineProperty(exports, "useGridVisibleRows", {
|
|
|
833
834
|
return _useGridVisibleRows.useGridVisibleRows;
|
|
834
835
|
}
|
|
835
836
|
});
|
|
837
|
+
Object.defineProperty(exports, "useIsCellEditable", {
|
|
838
|
+
enumerable: true,
|
|
839
|
+
get: function () {
|
|
840
|
+
return _useGridCellEditable.useIsCellEditable;
|
|
841
|
+
}
|
|
842
|
+
});
|
|
836
843
|
Object.defineProperty(exports, "useTimeout", {
|
|
837
844
|
enumerable: true,
|
|
838
845
|
get: function () {
|
|
@@ -935,6 +942,7 @@ var _useGridAriaAttributes = require("../hooks/utils/useGridAriaAttributes");
|
|
|
935
942
|
var _useGridRowAriaAttributes = require("../hooks/features/rows/useGridRowAriaAttributes");
|
|
936
943
|
var _useGridRowsOverridableMethods = require("../hooks/features/rows/useGridRowsOverridableMethods");
|
|
937
944
|
var _useGridParamsOverridableMethods = require("../hooks/features/rows/useGridParamsOverridableMethods");
|
|
945
|
+
var _useGridCellEditable = require("../hooks/features/editing/useGridCellEditable");
|
|
938
946
|
var _useGridRowsPreProcessors = require("../hooks/features/rows/useGridRowsPreProcessors");
|
|
939
947
|
var _gridRowsUtils = require("../hooks/features/rows/gridRowsUtils");
|
|
940
948
|
var _useGridRowsMeta = require("../hooks/features/rows/useGridRowsMeta");
|
package/locales/esES.js
CHANGED
|
@@ -9,10 +9,9 @@ const esESGrid = {
|
|
|
9
9
|
// Root
|
|
10
10
|
noRowsLabel: 'Sin filas',
|
|
11
11
|
noResultsOverlayLabel: 'Resultados no encontrados',
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
noColumnsOverlayLabel: 'Ninguna columna',
|
|
13
|
+
noColumnsOverlayManageColumns: 'Gestionar columnas',
|
|
14
|
+
emptyPivotOverlayLabel: 'Añada campos a filas, columnas y valores para crear una tabla dinámica',
|
|
16
15
|
// Density selector toolbar button text
|
|
17
16
|
toolbarDensity: 'Densidad',
|
|
18
17
|
toolbarDensityLabel: 'Densidad',
|
|
@@ -39,14 +38,11 @@ const esESGrid = {
|
|
|
39
38
|
toolbarExportPrint: 'Imprimir',
|
|
40
39
|
toolbarExportExcel: 'Descargar como Excel',
|
|
41
40
|
// Toolbar pivot button
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
toolbarPivot: 'Tabla dinámica',
|
|
44
42
|
// Toolbar charts button
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
toolbarCharts: 'Gráficos',
|
|
47
44
|
// Toolbar AI Assistant button
|
|
48
|
-
|
|
49
|
-
|
|
45
|
+
toolbarAssistant: 'Asistente de IA',
|
|
50
46
|
// Columns management text
|
|
51
47
|
columnsManagementSearchTitle: 'Buscar',
|
|
52
48
|
columnsManagementNoColumns: 'Sin columnas',
|
|
@@ -108,15 +104,14 @@ const esESGrid = {
|
|
|
108
104
|
'headerFilterOperator>=': 'Es mayor o igual que',
|
|
109
105
|
'headerFilterOperator<': 'Es menor que',
|
|
110
106
|
'headerFilterOperator<=': 'Es menor o igual que',
|
|
111
|
-
|
|
112
|
-
|
|
107
|
+
headerFilterClear: 'Limpiar filtros',
|
|
113
108
|
// Filter values text
|
|
114
109
|
filterValueAny: 'cualquiera',
|
|
115
110
|
filterValueTrue: 'verdadero',
|
|
116
111
|
filterValueFalse: 'falso',
|
|
117
112
|
// Column menu text
|
|
118
113
|
columnMenuLabel: 'Menú',
|
|
119
|
-
|
|
114
|
+
columnMenuAriaLabel: columnName => `Menú de la columna ${columnName}`,
|
|
120
115
|
columnMenuShowColumns: 'Mostrar columnas',
|
|
121
116
|
columnMenuManageColumns: 'Administrar columnas',
|
|
122
117
|
columnMenuFilter: 'Filtro',
|
|
@@ -124,9 +119,8 @@ const esESGrid = {
|
|
|
124
119
|
columnMenuUnsort: 'Desordenar',
|
|
125
120
|
columnMenuSortAsc: 'Ordenar ASC',
|
|
126
121
|
columnMenuSortDesc: 'Ordenar DESC',
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
122
|
+
columnMenuManagePivot: 'Gestionar tabla dinámica',
|
|
123
|
+
columnMenuManageCharts: 'Gestionar gráficos',
|
|
130
124
|
// Column header text
|
|
131
125
|
columnHeaderFiltersTooltipActive: count => count > 1 ? `${count} filtros activos` : `${count} filtro activo`,
|
|
132
126
|
columnHeaderFiltersLabel: 'Mostrar filtros',
|
|
@@ -166,18 +160,18 @@ const esESGrid = {
|
|
|
166
160
|
collapseDetailPanel: 'Contraer',
|
|
167
161
|
// Pagination
|
|
168
162
|
paginationRowsPerPage: 'Filas por página:',
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
163
|
+
paginationDisplayedRows: ({
|
|
164
|
+
from,
|
|
165
|
+
to,
|
|
166
|
+
count,
|
|
167
|
+
estimated
|
|
168
|
+
}) => {
|
|
169
|
+
if (!estimated) {
|
|
170
|
+
return `${from}–${to} de ${count !== -1 ? count : `más de ${to}`}`;
|
|
171
|
+
}
|
|
172
|
+
const estimatedLabel = estimated && estimated > to ? `alrededor de ${estimated}` : `más de ${to}`;
|
|
173
|
+
return `${from}–${to} de ${count !== -1 ? count : estimatedLabel}`;
|
|
174
|
+
},
|
|
181
175
|
paginationItemAriaLabel: type => {
|
|
182
176
|
if (type === 'first') {
|
|
183
177
|
return 'Ir a la primera página';
|
|
@@ -195,114 +189,109 @@ const esESGrid = {
|
|
|
195
189
|
rowReorderingHeaderName: 'Reordenar filas',
|
|
196
190
|
// Aggregation
|
|
197
191
|
aggregationMenuItemHeader: 'Agregación',
|
|
198
|
-
|
|
192
|
+
aggregationFunctionLabelNone: 'ninguna',
|
|
199
193
|
aggregationFunctionLabelSum: 'suma',
|
|
200
194
|
aggregationFunctionLabelAvg: 'promedio',
|
|
201
195
|
aggregationFunctionLabelMin: 'mínimo',
|
|
202
196
|
aggregationFunctionLabelMax: 'máximo',
|
|
203
197
|
aggregationFunctionLabelSize: 'tamaño',
|
|
204
198
|
// Pivot panel
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
199
|
+
pivotToggleLabel: 'Tabla dinámica',
|
|
200
|
+
pivotRows: 'Filas',
|
|
201
|
+
pivotColumns: 'Columnas',
|
|
202
|
+
pivotValues: 'Valores',
|
|
203
|
+
pivotCloseButton: 'Cerrar la configuración de tabla dinámica',
|
|
204
|
+
pivotSearchButton: 'Campos de búsqueda',
|
|
205
|
+
pivotSearchControlPlaceholder: 'Campos de búsqueda',
|
|
206
|
+
pivotSearchControlLabel: 'Campos de búsqueda',
|
|
207
|
+
pivotSearchControlClear: 'Limpiar la búsqueda',
|
|
208
|
+
pivotNoFields: 'Ningún campo',
|
|
209
|
+
pivotMenuMoveUp: 'Mover arriba',
|
|
210
|
+
pivotMenuMoveDown: 'Mover abajo',
|
|
211
|
+
pivotMenuMoveToTop: 'Mover al inicio',
|
|
212
|
+
pivotMenuMoveToBottom: 'Mover al final',
|
|
213
|
+
pivotMenuRows: 'Filas',
|
|
214
|
+
pivotMenuColumns: 'Columnas',
|
|
215
|
+
pivotMenuValues: 'Valores',
|
|
216
|
+
pivotMenuOptions: 'Opciones de campo',
|
|
217
|
+
pivotMenuAddToRows: 'Añadir a filas',
|
|
218
|
+
pivotMenuAddToColumns: 'Añadir a columnas',
|
|
219
|
+
pivotMenuAddToValues: 'Añadir a valores',
|
|
220
|
+
pivotMenuRemove: 'Eliminar',
|
|
221
|
+
pivotDragToRows: 'Arrastrar aquí para crear filas',
|
|
222
|
+
pivotDragToColumns: 'Arrastrar aquí para crear columnas',
|
|
223
|
+
pivotDragToValues: 'Arrastrar aquí para crear valores',
|
|
224
|
+
pivotYearColumnHeaderName: '(Año)',
|
|
225
|
+
pivotQuarterColumnHeaderName: '(Trimestre)',
|
|
233
226
|
// Charts configuration panel
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
227
|
+
chartsNoCharts: 'No hay ningún gráfico disponible',
|
|
228
|
+
chartsChartNotSelected: 'Seleccionar un tipo de gráfico para configurar sus opciones',
|
|
229
|
+
chartsTabChart: 'Gráfico',
|
|
230
|
+
chartsTabFields: 'Campos',
|
|
231
|
+
chartsTabCustomize: 'Personalizar',
|
|
232
|
+
chartsCloseButton: 'Cerrar la configuración de gráficos',
|
|
233
|
+
chartsSyncButtonLabel: 'Sincronizar gráfico',
|
|
234
|
+
chartsSearchPlaceholder: 'Campos de búsqueda',
|
|
235
|
+
chartsSearchLabel: 'Campos de búsqueda',
|
|
236
|
+
chartsSearchClear: 'Limpiar búsqueda',
|
|
237
|
+
chartsNoFields: 'Ningún campo',
|
|
238
|
+
chartsFieldBlocked: 'Este campo no se puede añadir a ninguna sección',
|
|
239
|
+
chartsCategories: 'Categorías',
|
|
240
|
+
chartsSeries: 'Series',
|
|
241
|
+
chartsMenuAddToDimensions: dimensionLabel => `Añadir a ${dimensionLabel}`,
|
|
242
|
+
chartsMenuAddToValues: valuesLabel => `Añadir a ${valuesLabel}`,
|
|
243
|
+
chartsMenuMoveUp: 'Mover arriba',
|
|
244
|
+
chartsMenuMoveDown: 'Mover abajo',
|
|
245
|
+
chartsMenuMoveToTop: 'Mover al inicio',
|
|
246
|
+
chartsMenuMoveToBottom: 'Mover al final',
|
|
247
|
+
chartsMenuOptions: 'Opciones de campo',
|
|
248
|
+
chartsMenuRemove: 'Eliminar',
|
|
249
|
+
chartsDragToDimensions: dimensionLabel => `Arrastrar aquí para utilizar la columna como ${dimensionLabel}`,
|
|
250
|
+
chartsDragToValues: valuesLabel => `Arrastrar aquí para utilizar la columna como ${valuesLabel}`,
|
|
259
251
|
// AI Assistant panel
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
252
|
+
aiAssistantPanelTitle: 'Asistente de IA',
|
|
253
|
+
aiAssistantPanelClose: 'Cerrar el asistente de IA',
|
|
254
|
+
aiAssistantPanelNewConversation: 'Nueva conversación',
|
|
255
|
+
aiAssistantPanelConversationHistory: 'Historial de conversaciones',
|
|
256
|
+
aiAssistantPanelEmptyConversation: 'El historial de conversaciones está vacío',
|
|
257
|
+
aiAssistantSuggestions: 'Sugerencias',
|
|
267
258
|
// Prompt field
|
|
268
259
|
promptFieldLabel: 'Prompt',
|
|
269
260
|
promptFieldPlaceholder: 'Escribe un prompt…',
|
|
270
261
|
promptFieldPlaceholderWithRecording: 'Escriba o grabe un prompt…',
|
|
271
262
|
promptFieldPlaceholderListening: 'Esperando por un prompt…',
|
|
272
|
-
|
|
263
|
+
promptFieldSpeechRecognitionNotSupported: 'El reconocimiento de voz no está soportado en este navegador',
|
|
273
264
|
promptFieldSend: 'Enviar',
|
|
274
265
|
promptFieldRecord: 'Grabar',
|
|
275
|
-
promptFieldStopRecording: 'Parar de grabar'
|
|
276
|
-
|
|
266
|
+
promptFieldStopRecording: 'Parar de grabar',
|
|
277
267
|
// Prompt
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
268
|
+
promptRerun: 'Ejecutar de nuevo',
|
|
269
|
+
promptProcessing: 'Procesando…',
|
|
270
|
+
promptAppliedChanges: 'Se han aplicado los cambios',
|
|
282
271
|
// Prompt changes
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
272
|
+
promptChangeGroupDescription: column => `Agrupar por ${column}`,
|
|
273
|
+
promptChangeAggregationLabel: (column, aggregation) => `${column} (${aggregation})`,
|
|
274
|
+
promptChangeAggregationDescription: (column, aggregation) => `Agregar ${column} (${aggregation})`,
|
|
275
|
+
promptChangeFilterLabel: (column, operator, value) => {
|
|
276
|
+
if (operator === 'is any of') {
|
|
277
|
+
return `${column} es uno de: ${value}`;
|
|
278
|
+
}
|
|
279
|
+
return `${column} ${operator} ${value}`;
|
|
280
|
+
},
|
|
281
|
+
promptChangeFilterDescription: (column, operator, value) => {
|
|
282
|
+
if (operator === 'is any of') {
|
|
283
|
+
return `Filtrar por ${column} cuando sea uno de: ${value}`;
|
|
284
|
+
}
|
|
285
|
+
return `Filtrar por ${column} ${operator} ${value}`;
|
|
286
|
+
},
|
|
287
|
+
promptChangeSortDescription: (column, direction) => `Ordenar por ${column} (${direction})`,
|
|
288
|
+
promptChangePivotEnableLabel: 'Tabla dinámica',
|
|
289
|
+
promptChangePivotEnableDescription: 'Activar tabla dinámica',
|
|
290
|
+
promptChangePivotColumnsLabel: count => `Columnas (${count})`,
|
|
291
|
+
promptChangePivotColumnsDescription: (column, direction) => `${column}${direction ? ` (${direction})` : ''}`,
|
|
292
|
+
promptChangePivotRowsLabel: count => `Filas (${count})`,
|
|
293
|
+
promptChangePivotValuesLabel: count => `Valores (${count})`,
|
|
294
|
+
promptChangePivotValuesDescription: (column, aggregation) => `${column} (${aggregation})`,
|
|
295
|
+
promptChangeChartsLabel: (dimensionsCount, valuesCount) => `Dimensiones (${dimensionsCount}), Valores (${valuesCount})`
|
|
307
296
|
};
|
|
308
297
|
const esES = exports.esES = (0, _getGridLocalization.getGridLocalization)(esESGrid);
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { GridPrivateApiCommunity } from "../api/gridApiCommunity.js";
|
|
3
|
+
import { DataGridProcessedProps } from "../props/DataGridProps.js";
|
|
4
|
+
import { GridEditingApi } from "../api/gridEditingApi.js";
|
|
5
|
+
/**
|
|
6
|
+
* Get the cell editable condition function
|
|
7
|
+
* @param {Object} params The cell parameters
|
|
8
|
+
* @param {Object} params.rowNode The row node
|
|
9
|
+
* @param {Object} params.colDef The column definition
|
|
10
|
+
* @param {any} params.value The cell value
|
|
11
|
+
* @returns {boolean} Whether the cell is editable
|
|
12
|
+
*/
|
|
13
|
+
export type CellEditableConditionFn = (params: Parameters<GridEditingApi['isCellEditable']>[0]) => boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Cell editable configuration interface for internal hooks
|
|
16
|
+
*/
|
|
17
|
+
export interface GridCellEditableInternalHook<Api = GridPrivateApiCommunity, Props = DataGridProcessedProps> {
|
|
18
|
+
useIsCellEditable: (apiRef: RefObject<Api>, props: Props) => CellEditableConditionFn;
|
|
19
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridRowAriaAttributesInternalHook, GridRowsOverridableMethodsInternalHook } from "./gridRowConfiguration.js";
|
|
3
3
|
import type { GridAggregationInternalHooks } from "./gridAggregationConfiguration.js";
|
|
4
|
+
import type { GridCellEditableInternalHook } from "./gridCellEditableConfiguration.js";
|
|
4
5
|
import type { GridCSSVariablesInterface } from "../../constants/cssVariables.js";
|
|
5
6
|
import { DataGridProcessedProps } from "../props/DataGridProps.js";
|
|
6
7
|
import type { GridPrivateApiCommon } from "../api/gridApiCommon.js";
|
|
@@ -9,7 +10,7 @@ import type { GridParamsOverridableMethodsInternalHook } from "./gridParamsConfi
|
|
|
9
10
|
export interface GridAriaAttributesInternalHook {
|
|
10
11
|
useGridAriaAttributes: () => React.HTMLAttributes<HTMLElement>;
|
|
11
12
|
}
|
|
12
|
-
export interface GridInternalHook<Api, Props> extends GridAriaAttributesInternalHook, GridRowAriaAttributesInternalHook, GridAggregationInternalHooks<Api, Props>, GridRowsOverridableMethodsInternalHook<Api>, GridParamsOverridableMethodsInternalHook<Api> {
|
|
13
|
+
export interface GridInternalHook<Api, Props> extends GridAriaAttributesInternalHook, GridRowAriaAttributesInternalHook, GridCellEditableInternalHook<Api, Props>, GridAggregationInternalHooks<Api, Props>, GridRowsOverridableMethodsInternalHook<Api>, GridParamsOverridableMethodsInternalHook<Api> {
|
|
13
14
|
useCSSVariables: () => {
|
|
14
15
|
id: string;
|
|
15
16
|
variables: GridCSSVariablesInterface;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/x-data-grid",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.16.0",
|
|
4
4
|
"author": "MUI Team",
|
|
5
5
|
"description": "The Community plan edition of the MUI X Data Grid components.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -42,8 +42,8 @@
|
|
|
42
42
|
"clsx": "^2.1.1",
|
|
43
43
|
"prop-types": "^15.8.1",
|
|
44
44
|
"use-sync-external-store": "^1.6.0",
|
|
45
|
-
"@mui/x-internals": "8.
|
|
46
|
-
"@mui/x-virtualizer": "0.2.
|
|
45
|
+
"@mui/x-internals": "8.16.0",
|
|
46
|
+
"@mui/x-virtualizer": "0.2.6"
|
|
47
47
|
},
|
|
48
48
|
"peerDependencies": {
|
|
49
49
|
"@emotion/react": "^11.9.0",
|