@mui/x-data-grid 8.13.1 → 8.14.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 +109 -1
- package/esm/hooks/features/columnGrouping/gridColumnGroupsUtils.d.ts +3 -2
- package/esm/hooks/features/columnGrouping/gridColumnGroupsUtils.js +34 -0
- package/esm/hooks/features/columnGrouping/useGridColumnGrouping.js +1 -34
- package/esm/hooks/features/dataSource/useGridDataSourceBase.js +7 -5
- package/esm/hooks/features/dataSource/utils.js +2 -4
- package/esm/hooks/features/rows/useGridRows.js +4 -4
- package/esm/index.js +1 -1
- package/esm/locales/ptBR.js +117 -128
- package/hooks/features/columnGrouping/gridColumnGroupsUtils.d.ts +3 -2
- package/hooks/features/columnGrouping/gridColumnGroupsUtils.js +37 -1
- package/hooks/features/columnGrouping/useGridColumnGrouping.js +3 -36
- package/hooks/features/dataSource/useGridDataSourceBase.js +7 -5
- package/hooks/features/dataSource/utils.js +2 -4
- package/hooks/features/rows/useGridRows.js +4 -4
- package/index.js +1 -1
- package/locales/ptBR.js +117 -128
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,114 @@
|
|
|
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.14.0
|
|
9
|
+
|
|
10
|
+
_Oct 9, 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
|
+
- 📊 The [Chart zoom now supports the `pressAndDrag` gesture](https://mui.com/x/react-charts/zoom-and-pan/#zoom-interactions-configuration). Pan by pressing and dragging.
|
|
15
|
+
- 🔄 [Server-side pivoting](https://mui.com/x/react-data-grid/server-side-data/pivoting/) support for the Data Grid
|
|
16
|
+
- 🐞 Bugfixes
|
|
17
|
+
- 📚 Documentation improvements
|
|
18
|
+
|
|
19
|
+
Special thanks go out to the community members for their valuable contributions:
|
|
20
|
+
@djpremier, @Utkarsh-0304
|
|
21
|
+
|
|
22
|
+
The following are all team members who have contributed to this release:
|
|
23
|
+
@alexfauquette, @bernardobelchior, @flaviendelangle, @hasdfa, @Janpot, @JCQuintas, @prakhargupta1, @rita-codes, @noraleonte, @brijeshb42, @arminmeh, @michelengelen
|
|
24
|
+
|
|
25
|
+
### Data Grid
|
|
26
|
+
|
|
27
|
+
#### `@mui/x-data-grid@8.14.0`
|
|
28
|
+
|
|
29
|
+
- [l10n] Improve Brazilian Portuguese (pt-BR) locale (#19658) @djpremier
|
|
30
|
+
|
|
31
|
+
#### `@mui/x-data-grid-pro@8.14.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
32
|
+
|
|
33
|
+
Same changes as in `@mui/x-data-grid@8.14.0`.
|
|
34
|
+
|
|
35
|
+
#### `@mui/x-data-grid-premium@8.14.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
36
|
+
|
|
37
|
+
Same changes as in `@mui/x-data-grid-pro@8.14.0`, plus:
|
|
38
|
+
|
|
39
|
+
- [DataGridPremium] Server-side pivoting (#19575) @arminmeh
|
|
40
|
+
|
|
41
|
+
### Date and Time Pickers
|
|
42
|
+
|
|
43
|
+
#### `@mui/x-date-pickers@8.14.0`
|
|
44
|
+
|
|
45
|
+
- [pickers] Fixed the extra element for the disabled date picker (#19387) @Utkarsh-0304
|
|
46
|
+
- [pickers] Fix input `autoCapitalize` value for Firefox compatibility (#19285) @michelengelen
|
|
47
|
+
- [l10n] Improve Brazilian Portuguese (pt-BR) locale (#19658) @djpremier
|
|
48
|
+
|
|
49
|
+
#### `@mui/x-date-pickers-pro@8.14.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
50
|
+
|
|
51
|
+
Same changes as in `@mui/x-date-pickers@8.14.0`.
|
|
52
|
+
|
|
53
|
+
### Charts
|
|
54
|
+
|
|
55
|
+
#### `@mui/x-charts@8.14.0`
|
|
56
|
+
|
|
57
|
+
- [charts] Add `pressAndDrag` pan gesture (#19779) @JCQuintas
|
|
58
|
+
- [charts] Allow `minPointers` and `maxPointers` to be configured by pointer type (#19794) @JCQuintas
|
|
59
|
+
- [charts] Correct scale domain types (#19844) @bernardobelchior
|
|
60
|
+
- [charts] Fix tooltip position when scrolling (#19857) @alexfauquette
|
|
61
|
+
- [charts] Link item highlight with keyboard navigation (#19768) @alexfauquette
|
|
62
|
+
- [charts] Refactor domain/scale selectors (#19832) @bernardobelchior
|
|
63
|
+
- [charts] Remove min/max from ordinal configuration (#19789) @alexfauquette
|
|
64
|
+
- [charts] Simplify axes filters selectors (#19833) @bernardobelchior
|
|
65
|
+
- [l10n] Improve Brazilian Portuguese (pt-BR) locale (#19658) @djpremier
|
|
66
|
+
|
|
67
|
+
#### `@mui/x-charts-pro@8.14.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
68
|
+
|
|
69
|
+
Same changes as in `@mui/x-charts@8.14.0`.
|
|
70
|
+
|
|
71
|
+
#### `@mui/x-charts-premium@8.14.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
72
|
+
|
|
73
|
+
Same changes as in `@mui/x-charts-pro@8.14.0`.
|
|
74
|
+
|
|
75
|
+
### Tree View
|
|
76
|
+
|
|
77
|
+
#### `@mui/x-tree-view@8.14.0`
|
|
78
|
+
|
|
79
|
+
- [tree view] Fix Tree View tooltip anchoring on overview page (#19806) @noraleonte
|
|
80
|
+
|
|
81
|
+
#### `@mui/x-tree-view-pro@8.14.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
82
|
+
|
|
83
|
+
Same changes as in `@mui/x-tree-view@8.14.0`.
|
|
84
|
+
|
|
85
|
+
### Codemod
|
|
86
|
+
|
|
87
|
+
#### `@mui/x-codemod@8.14.0`
|
|
88
|
+
|
|
89
|
+
Internal changes.
|
|
90
|
+
|
|
91
|
+
### Docs
|
|
92
|
+
|
|
93
|
+
- [docs] Add overview section for pie chart (#19672) @prakhargupta1
|
|
94
|
+
- [docs] Fix demo title knob keys (#19843) @JCQuintas
|
|
95
|
+
- [docs] Hide UI elements of unsupported features in the data source demos (#19849) @arminmeh
|
|
96
|
+
|
|
97
|
+
### Core
|
|
98
|
+
|
|
99
|
+
- [code-infra] Cleanup unused dependencies (#19788) @brijeshb42
|
|
100
|
+
- [code-infra] Fix pnpm-lock issue (#19861) @JCQuintas
|
|
101
|
+
- [code-infra] Improve publishing docs (#19404) @Janpot
|
|
102
|
+
- [code-infra] Remove tsconfig `baseUrl` (#19837) @Janpot
|
|
103
|
+
- [code-infra] Support custom npm dist tags during release (#19803) @Janpot
|
|
104
|
+
- [code-infra] Wait longer for print dialog (#19795) @JCQuintas
|
|
105
|
+
- [code-infra] Replace `lodash` with `es-toolkit` (#19853) @bernardobelchior
|
|
106
|
+
- [code-infra] Update release script PR checklist (#19785) @bernardobelchior
|
|
107
|
+
- [code-infra] Remove remaining usages of `lodash` (#19864) @bernardobelchior
|
|
108
|
+
- [docs-infra] Add `title` knob (#19792) @JCQuintas
|
|
109
|
+
- [docs-infra] Fix missing key in title knob (#19804) @JCQuintas
|
|
110
|
+
|
|
111
|
+
### Miscellaneous
|
|
112
|
+
|
|
113
|
+
- [x-telemetry] Fix transpile issues (#19761) @hasdfa
|
|
114
|
+
- [x-telemetry] Fix ref to deleted file (#19842) @JCQuintas
|
|
115
|
+
|
|
8
116
|
## 8.13.1
|
|
9
117
|
|
|
10
118
|
_Oct 1, 2025_
|
|
@@ -222,7 +330,7 @@ We'd like to extend a big thank you to the 15 contributors who made this release
|
|
|
222
330
|
|
|
223
331
|

|
|
224
332
|
|
|
225
|
-
|
|
333
|
+
👉 [🎥 Watch the full video](https://github.com/user-attachments/assets/28f1848e-dc85-4077-8756-a3e88afd4e54)
|
|
226
334
|
|
|
227
335
|
- ⌨️ Charts keyboard navigation
|
|
228
336
|
- ⚡️ Charts: Add new `renderer="svg-batch"` prop to Scatter charts that provides improved performance for large datasets
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { GridColumnGroupingModel, GridColumnGroup } from "../../../models/gridColumnGrouping.js";
|
|
1
|
+
import { GridColumnGroupingModel, GridColumnNode, GridColumnGroup } from "../../../models/gridColumnGrouping.js";
|
|
2
2
|
import { GridColDef } from "../../../models/colDef/index.js";
|
|
3
|
-
import { GridGroupingStructure } from "./gridColumnGroupsInterfaces.js";
|
|
3
|
+
import { GridColumnGroupLookup, GridGroupingStructure } from "./gridColumnGroupsInterfaces.js";
|
|
4
4
|
type UnwrappedGroupingModel = {
|
|
5
5
|
[key: GridColDef['field']]: GridColumnGroup['groupId'][];
|
|
6
6
|
};
|
|
7
|
+
export declare const createGroupLookup: (columnGroupingModel: GridColumnNode[]) => GridColumnGroupLookup;
|
|
7
8
|
/**
|
|
8
9
|
* This is a function that provide for each column the array of its parents.
|
|
9
10
|
* Parents are ordered from the root to the leaf.
|
|
@@ -1,4 +1,38 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
|
+
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
+
const _excluded = ["groupId", "children"];
|
|
1
4
|
import { isLeaf } from "../../../models/gridColumnGrouping.js";
|
|
5
|
+
export const createGroupLookup = columnGroupingModel => {
|
|
6
|
+
const groupLookup = {};
|
|
7
|
+
for (let i = 0; i < columnGroupingModel.length; i += 1) {
|
|
8
|
+
const node = columnGroupingModel[i];
|
|
9
|
+
if (isLeaf(node)) {
|
|
10
|
+
continue;
|
|
11
|
+
}
|
|
12
|
+
const {
|
|
13
|
+
groupId,
|
|
14
|
+
children
|
|
15
|
+
} = node,
|
|
16
|
+
other = _objectWithoutPropertiesLoose(node, _excluded);
|
|
17
|
+
if (!groupId) {
|
|
18
|
+
throw new Error('MUI X: An element of the columnGroupingModel does not have either `field` or `groupId`.');
|
|
19
|
+
}
|
|
20
|
+
if (process.env.NODE_ENV !== 'production' && !children) {
|
|
21
|
+
console.warn(`MUI X: group groupId=${groupId} has no children.`);
|
|
22
|
+
}
|
|
23
|
+
const groupParam = _extends({}, other, {
|
|
24
|
+
groupId
|
|
25
|
+
});
|
|
26
|
+
const subTreeLookup = createGroupLookup(children);
|
|
27
|
+
if (subTreeLookup[groupId] !== undefined || groupLookup[groupId] !== undefined) {
|
|
28
|
+
throw new Error(`MUI X: The groupId ${groupId} is used multiple times in the columnGroupingModel.`);
|
|
29
|
+
}
|
|
30
|
+
Object.assign(groupLookup, subTreeLookup);
|
|
31
|
+
groupLookup[groupId] = groupParam;
|
|
32
|
+
}
|
|
33
|
+
return groupLookup;
|
|
34
|
+
};
|
|
35
|
+
|
|
2
36
|
// This is the recurrence function that help writing `unwrapGroupingColumnModel()`
|
|
3
37
|
const recurrentUnwrapGroupingColumnModel = (columnGroupNode, parents, unwrappedGroupingModelToComplete) => {
|
|
4
38
|
if (isLeaf(columnGroupNode)) {
|
|
@@ -1,45 +1,12 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
|
-
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
5
|
-
const _excluded = ["groupId", "children"];
|
|
6
4
|
import * as React from 'react';
|
|
7
|
-
import { isLeaf } from "../../../models/gridColumnGrouping.js";
|
|
8
5
|
import { gridColumnGroupsLookupSelector, gridColumnGroupsUnwrappedModelSelector } from "./gridColumnGroupsSelector.js";
|
|
9
6
|
import { useGridApiMethod } from "../../utils/useGridApiMethod.js";
|
|
10
|
-
import { getColumnGroupsHeaderStructure, unwrapGroupingColumnModel } from "./gridColumnGroupsUtils.js";
|
|
7
|
+
import { createGroupLookup, getColumnGroupsHeaderStructure, unwrapGroupingColumnModel } from "./gridColumnGroupsUtils.js";
|
|
11
8
|
import { useGridEvent } from "../../utils/useGridEvent.js";
|
|
12
9
|
import { gridColumnFieldsSelector, gridVisibleColumnFieldsSelector } from "../columns/index.js";
|
|
13
|
-
const createGroupLookup = columnGroupingModel => {
|
|
14
|
-
const groupLookup = {};
|
|
15
|
-
for (let i = 0; i < columnGroupingModel.length; i += 1) {
|
|
16
|
-
const node = columnGroupingModel[i];
|
|
17
|
-
if (isLeaf(node)) {
|
|
18
|
-
continue;
|
|
19
|
-
}
|
|
20
|
-
const {
|
|
21
|
-
groupId,
|
|
22
|
-
children
|
|
23
|
-
} = node,
|
|
24
|
-
other = _objectWithoutPropertiesLoose(node, _excluded);
|
|
25
|
-
if (!groupId) {
|
|
26
|
-
throw new Error('MUI X: An element of the columnGroupingModel does not have either `field` or `groupId`.');
|
|
27
|
-
}
|
|
28
|
-
if (process.env.NODE_ENV !== 'production' && !children) {
|
|
29
|
-
console.warn(`MUI X: group groupId=${groupId} has no children.`);
|
|
30
|
-
}
|
|
31
|
-
const groupParam = _extends({}, other, {
|
|
32
|
-
groupId
|
|
33
|
-
});
|
|
34
|
-
const subTreeLookup = createGroupLookup(children);
|
|
35
|
-
if (subTreeLookup[groupId] !== undefined || groupLookup[groupId] !== undefined) {
|
|
36
|
-
throw new Error(`MUI X: The groupId ${groupId} is used multiple times in the columnGroupingModel.`);
|
|
37
|
-
}
|
|
38
|
-
Object.assign(groupLookup, subTreeLookup);
|
|
39
|
-
groupLookup[groupId] = groupParam;
|
|
40
|
-
}
|
|
41
|
-
return groupLookup;
|
|
42
|
-
};
|
|
43
10
|
export const columnGroupsStateInitializer = (state, props, apiRef) => {
|
|
44
11
|
apiRef.current.caches.columnGrouping = {
|
|
45
12
|
lastColumnGroupingModel: props.columnGroupingModel
|
|
@@ -32,7 +32,10 @@ export const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
32
32
|
const setStrategyAvailability = React.useCallback(() => {
|
|
33
33
|
apiRef.current.setStrategyAvailability(GridStrategyGroup.DataSource, DataSourceRowsUpdateStrategy.Default, props.dataSource ? () => true : () => false);
|
|
34
34
|
}, [apiRef, props.dataSource]);
|
|
35
|
-
const [
|
|
35
|
+
const [currentStrategy, setCurrentStrategy] = React.useState(apiRef.current.getActiveStrategy(GridStrategyGroup.DataSource));
|
|
36
|
+
const defaultRowsUpdateStrategyActive = React.useMemo(() => {
|
|
37
|
+
return currentStrategy === DataSourceRowsUpdateStrategy.Default;
|
|
38
|
+
}, [currentStrategy]);
|
|
36
39
|
const paginationModel = useGridSelector(apiRef, gridPaginationModelSelector);
|
|
37
40
|
const lastRequestId = React.useRef(0);
|
|
38
41
|
const onDataSourceErrorProp = props.onDataSourceError;
|
|
@@ -110,7 +113,7 @@ export const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
110
113
|
}
|
|
111
114
|
}, [cacheChunkManager, cache, apiRef, defaultRowsUpdateStrategyActive, props.dataSource?.getRows, onDataSourceErrorProp, options, props.signature]);
|
|
112
115
|
const handleStrategyActivityChange = React.useCallback(() => {
|
|
113
|
-
|
|
116
|
+
setCurrentStrategy(apiRef.current.getActiveStrategy(GridStrategyGroup.DataSource));
|
|
114
117
|
}, [apiRef]);
|
|
115
118
|
const handleDataUpdate = React.useCallback(params => {
|
|
116
119
|
if ('error' in params) {
|
|
@@ -183,8 +186,7 @@ export const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
183
186
|
React.useEffect(() => {
|
|
184
187
|
// Return early if the proper strategy isn't set yet
|
|
185
188
|
// Context: https://github.com/mui/mui-x/issues/19650
|
|
186
|
-
|
|
187
|
-
if (strategy !== DataSourceRowsUpdateStrategy.Default && strategy !== DataSourceRowsUpdateStrategy.LazyLoading) {
|
|
189
|
+
if (currentStrategy !== DataSourceRowsUpdateStrategy.Default && currentStrategy !== DataSourceRowsUpdateStrategy.LazyLoading) {
|
|
188
190
|
return undefined;
|
|
189
191
|
}
|
|
190
192
|
if (props.dataSource) {
|
|
@@ -195,7 +197,7 @@ export const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
195
197
|
// ignore the current request on unmount
|
|
196
198
|
lastRequestId.current += 1;
|
|
197
199
|
};
|
|
198
|
-
}, [apiRef, props.dataSource]);
|
|
200
|
+
}, [apiRef, props.dataSource, currentStrategy]);
|
|
199
201
|
return {
|
|
200
202
|
api: {
|
|
201
203
|
public: dataSourceApi
|
|
@@ -60,10 +60,8 @@ export class CacheChunkManager {
|
|
|
60
60
|
if (responses.length === 1) {
|
|
61
61
|
return responses[0];
|
|
62
62
|
}
|
|
63
|
-
return responses.reduce((acc, response) => ({
|
|
64
|
-
rows: [...acc.rows, ...response.rows]
|
|
65
|
-
rowCount: response.rowCount,
|
|
66
|
-
pageInfo: response.pageInfo
|
|
63
|
+
return responses.reduce((acc, response) => _extends({}, response, {
|
|
64
|
+
rows: [...acc.rows, ...response.rows]
|
|
67
65
|
}), {
|
|
68
66
|
rows: [],
|
|
69
67
|
rowCount: 0,
|
|
@@ -105,7 +105,7 @@ export const useGridRows = (apiRef, props, configuration) => {
|
|
|
105
105
|
*/
|
|
106
106
|
const setRows = React.useCallback(rows => {
|
|
107
107
|
logger.debug(`Updating all rows, new length ${rows.length}`);
|
|
108
|
-
if (gridPivotActiveSelector(apiRef)) {
|
|
108
|
+
if (!props.dataSource && gridPivotActiveSelector(apiRef)) {
|
|
109
109
|
apiRef.current.updateNonPivotRows(rows, false);
|
|
110
110
|
return;
|
|
111
111
|
}
|
|
@@ -121,12 +121,12 @@ export const useGridRows = (apiRef, props, configuration) => {
|
|
|
121
121
|
cache,
|
|
122
122
|
throttle: true
|
|
123
123
|
});
|
|
124
|
-
}, [logger, props.getRowId, props.loading, props.rowCount, throttledRowsChange, apiRef]);
|
|
124
|
+
}, [logger, props.getRowId, props.dataSource, props.loading, props.rowCount, throttledRowsChange, apiRef]);
|
|
125
125
|
const updateRows = React.useCallback(updates => {
|
|
126
126
|
if (props.signature === GridSignature.DataGrid && updates.length > 1) {
|
|
127
127
|
throw new Error(['MUI X: You cannot update several rows at once in `apiRef.current.updateRows` on the DataGrid.', 'You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature.'].join('\n'));
|
|
128
128
|
}
|
|
129
|
-
if (gridPivotActiveSelector(apiRef)) {
|
|
129
|
+
if (!props.dataSource && gridPivotActiveSelector(apiRef)) {
|
|
130
130
|
apiRef.current.updateNonPivotRows(updates);
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
@@ -140,7 +140,7 @@ export const useGridRows = (apiRef, props, configuration) => {
|
|
|
140
140
|
cache,
|
|
141
141
|
throttle: true
|
|
142
142
|
});
|
|
143
|
-
}, [props.signature, props.getRowId, throttledRowsChange, apiRef]);
|
|
143
|
+
}, [props.signature, props.dataSource, props.getRowId, throttledRowsChange, apiRef]);
|
|
144
144
|
const updateNestedRows = React.useCallback((updates, groupKeys) => {
|
|
145
145
|
const nonPinnedRowsUpdates = computeRowsUpdates(apiRef, updates, props.getRowId);
|
|
146
146
|
const cache = updateCacheWithNewRows({
|
package/esm/index.js
CHANGED
package/esm/locales/ptBR.js
CHANGED
|
@@ -3,10 +3,9 @@ const ptBRGrid = {
|
|
|
3
3
|
// Root
|
|
4
4
|
noRowsLabel: 'Nenhuma linha',
|
|
5
5
|
noResultsOverlayLabel: 'Nenhum resultado encontrado.',
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
noColumnsOverlayLabel: 'Nenhuma coluna',
|
|
7
|
+
noColumnsOverlayManageColumns: 'Gerenciar colunas',
|
|
8
|
+
emptyPivotOverlayLabel: 'Adicionar campos às linhas, colunas e valores para criar uma tabela dinâmica',
|
|
10
9
|
// Density selector toolbar button text
|
|
11
10
|
toolbarDensity: 'Densidade',
|
|
12
11
|
toolbarDensityLabel: 'Densidade',
|
|
@@ -21,7 +20,7 @@ const ptBRGrid = {
|
|
|
21
20
|
toolbarFiltersLabel: 'Exibir filtros',
|
|
22
21
|
toolbarFiltersTooltipHide: 'Ocultar filtros',
|
|
23
22
|
toolbarFiltersTooltipShow: 'Exibir filtros',
|
|
24
|
-
toolbarFiltersTooltipActive: count =>
|
|
23
|
+
toolbarFiltersTooltipActive: count => count !== 1 ? `${count} filtros ativos` : `${count} filtro ativo`,
|
|
25
24
|
// Quick filter toolbar field
|
|
26
25
|
toolbarQuickFilterPlaceholder: 'Procurar…',
|
|
27
26
|
toolbarQuickFilterLabel: 'Procurar',
|
|
@@ -33,14 +32,11 @@ const ptBRGrid = {
|
|
|
33
32
|
toolbarExportPrint: 'Imprimir',
|
|
34
33
|
toolbarExportExcel: 'Baixar como Excel',
|
|
35
34
|
// Toolbar pivot button
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
toolbarPivot: 'Pivotar',
|
|
38
36
|
// Toolbar charts button
|
|
39
|
-
|
|
40
|
-
|
|
37
|
+
toolbarCharts: 'Gráficos',
|
|
41
38
|
// Toolbar AI Assistant button
|
|
42
|
-
|
|
43
|
-
|
|
39
|
+
toolbarAssistant: 'Assistente de IA',
|
|
44
40
|
// Columns management text
|
|
45
41
|
columnsManagementSearchTitle: 'Buscar',
|
|
46
42
|
columnsManagementNoColumns: 'Nenhuma coluna',
|
|
@@ -102,28 +98,26 @@ const ptBRGrid = {
|
|
|
102
98
|
'headerFilterOperator>=': 'Maior que ou igual a',
|
|
103
99
|
'headerFilterOperator<': 'Menor que',
|
|
104
100
|
'headerFilterOperator<=': 'Menor que ou igual a',
|
|
105
|
-
|
|
106
|
-
|
|
101
|
+
headerFilterClear: 'Limpar filtro',
|
|
107
102
|
// Filter values text
|
|
108
103
|
filterValueAny: 'qualquer',
|
|
109
104
|
filterValueTrue: 'verdadeiro',
|
|
110
105
|
filterValueFalse: 'falso',
|
|
111
106
|
// Column menu text
|
|
112
107
|
columnMenuLabel: 'Menu',
|
|
113
|
-
|
|
108
|
+
columnMenuAriaLabel: columnName => `menu da coluna ${columnName}`,
|
|
114
109
|
columnMenuShowColumns: 'Exibir colunas',
|
|
115
110
|
columnMenuManageColumns: 'Gerir colunas',
|
|
116
111
|
columnMenuFilter: 'Filtrar',
|
|
117
|
-
columnMenuHideColumn: 'Ocultar',
|
|
112
|
+
columnMenuHideColumn: 'Ocultar coluna',
|
|
118
113
|
columnMenuUnsort: 'Desfazer ordenação',
|
|
119
114
|
columnMenuSortAsc: 'Ordenar do menor para o maior',
|
|
120
115
|
columnMenuSortDesc: 'Ordenar do maior para o menor',
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
116
|
+
columnMenuManagePivot: 'Gerenciar pivot',
|
|
117
|
+
columnMenuManageCharts: 'Gerenciar gráficos',
|
|
124
118
|
// Column header text
|
|
125
|
-
columnHeaderFiltersTooltipActive: count =>
|
|
126
|
-
columnHeaderFiltersLabel: 'Exibir
|
|
119
|
+
columnHeaderFiltersTooltipActive: count => count !== 1 ? `${count} filtros ativos` : `${count} filtro ativo`,
|
|
120
|
+
columnHeaderFiltersLabel: 'Exibir filtros',
|
|
127
121
|
columnHeaderSortIconLabel: 'Ordenar',
|
|
128
122
|
// Rows selected footer text
|
|
129
123
|
footerRowSelected: count => count !== 1 ? `${count.toLocaleString()} linhas selecionadas` : `${count.toLocaleString()} linha selecionada`,
|
|
@@ -132,9 +126,9 @@ const ptBRGrid = {
|
|
|
132
126
|
// Total visible row amount footer text
|
|
133
127
|
footerTotalVisibleRows: (visibleCount, totalCount) => `${visibleCount.toLocaleString()} de ${totalCount.toLocaleString()}`,
|
|
134
128
|
// Checkbox selection text
|
|
135
|
-
checkboxSelectionHeaderName: '
|
|
136
|
-
checkboxSelectionSelectAllRows: 'Selecionar todas linhas',
|
|
137
|
-
checkboxSelectionUnselectAllRows: 'Deselecionar todas linhas',
|
|
129
|
+
checkboxSelectionHeaderName: 'Caixa de seleção',
|
|
130
|
+
checkboxSelectionSelectAllRows: 'Selecionar todas as linhas',
|
|
131
|
+
checkboxSelectionUnselectAllRows: 'Deselecionar todas as linhas',
|
|
138
132
|
checkboxSelectionSelectRow: 'Selecionar linha',
|
|
139
133
|
checkboxSelectionUnselectRow: 'Deselecionar linha',
|
|
140
134
|
// Boolean cell text
|
|
@@ -149,7 +143,7 @@ const ptBRGrid = {
|
|
|
149
143
|
// Tree Data
|
|
150
144
|
treeDataGroupingHeaderName: 'Grupo',
|
|
151
145
|
treeDataExpand: 'mostrar filhos',
|
|
152
|
-
treeDataCollapse: '
|
|
146
|
+
treeDataCollapse: 'ocultar filhos',
|
|
153
147
|
// Grouping columns
|
|
154
148
|
groupingColumnHeaderName: 'Grupo',
|
|
155
149
|
groupColumn: name => `Agrupar por ${name}`,
|
|
@@ -157,21 +151,21 @@ const ptBRGrid = {
|
|
|
157
151
|
// Master/detail
|
|
158
152
|
detailPanelToggle: 'Painel de detalhes',
|
|
159
153
|
expandDetailPanel: 'Expandir',
|
|
160
|
-
collapseDetailPanel: '
|
|
154
|
+
collapseDetailPanel: 'Recolher',
|
|
161
155
|
// Pagination
|
|
162
156
|
paginationRowsPerPage: 'Linhas 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 : `mais de ${to}`}`;
|
|
165
|
+
}
|
|
166
|
+
const estimatedLabel = estimated && estimated > to ? `cerca de ${estimated}` : `mais 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 para a primeira página';
|
|
@@ -189,113 +183,108 @@ const ptBRGrid = {
|
|
|
189
183
|
rowReorderingHeaderName: 'Reorganizar linhas',
|
|
190
184
|
// Aggregation
|
|
191
185
|
aggregationMenuItemHeader: 'Agrupar',
|
|
192
|
-
|
|
186
|
+
aggregationFunctionLabelNone: 'nenhum',
|
|
193
187
|
aggregationFunctionLabelSum: 'soma',
|
|
194
188
|
aggregationFunctionLabelAvg: 'média',
|
|
195
189
|
aggregationFunctionLabelMin: 'mín',
|
|
196
190
|
aggregationFunctionLabelMax: 'máx',
|
|
197
191
|
aggregationFunctionLabelSize: 'tamanho',
|
|
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: 'Pivot',
|
|
194
|
+
pivotRows: 'Linhas',
|
|
195
|
+
pivotColumns: 'Colunas',
|
|
196
|
+
pivotValues: 'Valores',
|
|
197
|
+
pivotCloseButton: 'Fechar configurações de pivot',
|
|
198
|
+
pivotSearchButton: 'Pesquisar campos',
|
|
199
|
+
pivotSearchControlPlaceholder: 'Pesquisar campos',
|
|
200
|
+
pivotSearchControlLabel: 'Pesquisar campos',
|
|
201
|
+
pivotSearchControlClear: 'Limpar pesquisa',
|
|
202
|
+
pivotNoFields: 'Nenhum campo',
|
|
203
|
+
pivotMenuMoveUp: 'Mover para cima',
|
|
204
|
+
pivotMenuMoveDown: 'Mover para baixo',
|
|
205
|
+
pivotMenuMoveToTop: 'Mover para o topo',
|
|
206
|
+
pivotMenuMoveToBottom: 'Mover para a parte inferior',
|
|
207
|
+
pivotMenuRows: 'Linhas',
|
|
208
|
+
pivotMenuColumns: 'Colunas',
|
|
209
|
+
pivotMenuValues: 'Valores',
|
|
210
|
+
pivotMenuOptions: 'Opções de campo',
|
|
211
|
+
pivotMenuAddToRows: 'Adicionar às Linhas',
|
|
212
|
+
pivotMenuAddToColumns: 'Adicionar às Colunas',
|
|
213
|
+
pivotMenuAddToValues: 'Adicionar aos Valores',
|
|
214
|
+
pivotMenuRemove: 'Remover',
|
|
215
|
+
pivotDragToRows: 'Arraste aqui para criar linhas',
|
|
216
|
+
pivotDragToColumns: 'Arraste aqui para criar colunas',
|
|
217
|
+
pivotDragToValues: 'Arraste aqui para criar valores',
|
|
218
|
+
pivotYearColumnHeaderName: '(Ano)',
|
|
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: 'Não há gráficos disponíveis',
|
|
222
|
+
chartsChartNotSelected: 'Selecione um tipo de gráfico para configurar suas opções',
|
|
223
|
+
chartsTabChart: 'Gráfico',
|
|
224
|
+
chartsTabFields: 'Campos',
|
|
225
|
+
chartsTabCustomize: 'Personalizar',
|
|
226
|
+
chartsCloseButton: 'Fechar configuração de gráficos',
|
|
227
|
+
chartsSyncButtonLabel: 'Sincronizar gráfico',
|
|
228
|
+
chartsSearchPlaceholder: 'Pesquisar campos',
|
|
229
|
+
chartsSearchLabel: 'Pesquisar campos',
|
|
230
|
+
chartsSearchClear: 'Limpar pesquisa',
|
|
231
|
+
chartsNoFields: 'Nenhum campo',
|
|
232
|
+
chartsFieldBlocked: 'Este campo não pode ser adicionado a nenhuma seção',
|
|
233
|
+
chartsCategories: 'Categorias',
|
|
234
|
+
chartsSeries: 'Séries',
|
|
235
|
+
chartsMenuAddToDimensions: dimensionLabel => `Adicionar a ${dimensionLabel}`,
|
|
236
|
+
chartsMenuAddToValues: valuesLabel => `Adicionar a ${valuesLabel}`,
|
|
237
|
+
chartsMenuMoveUp: 'Mover para cima',
|
|
238
|
+
chartsMenuMoveDown: 'Mover para baixo',
|
|
239
|
+
chartsMenuMoveToTop: 'Mover para o topo',
|
|
240
|
+
chartsMenuMoveToBottom: 'Mover para a parte inferior',
|
|
241
|
+
chartsMenuOptions: 'Opções de campo',
|
|
242
|
+
chartsMenuRemove: 'Remover',
|
|
243
|
+
chartsDragToDimensions: dimensionLabel => `Arraste aqui para usar a coluna como ${dimensionLabel}`,
|
|
244
|
+
chartsDragToValues: valuesLabel => `Arraste aqui para usar a coluna como ${valuesLabel}`,
|
|
253
245
|
// AI Assistant panel
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
246
|
+
aiAssistantPanelTitle: 'Assistente de IA',
|
|
247
|
+
aiAssistantPanelClose: 'Fechar Assistente de IA',
|
|
248
|
+
aiAssistantPanelNewConversation: 'Nova conversa',
|
|
249
|
+
aiAssistantPanelConversationHistory: 'Histórico de conversas',
|
|
250
|
+
aiAssistantPanelEmptyConversation: 'Sem histórico de prompts',
|
|
251
|
+
aiAssistantSuggestions: 'Sugestões',
|
|
261
252
|
// Prompt field
|
|
262
253
|
promptFieldLabel: 'Prompt',
|
|
263
254
|
promptFieldPlaceholder: 'Digite um prompt…',
|
|
264
255
|
promptFieldPlaceholderWithRecording: 'Digite ou grave um prompt…',
|
|
265
256
|
promptFieldPlaceholderListening: 'Ouvindo o prompt…',
|
|
266
|
-
|
|
257
|
+
promptFieldSpeechRecognitionNotSupported: 'O reconhecimento de fala não é suportado neste navegador',
|
|
267
258
|
promptFieldSend: 'Enviar',
|
|
268
259
|
promptFieldRecord: 'Gravar',
|
|
269
|
-
promptFieldStopRecording: 'Parar gravação'
|
|
270
|
-
|
|
260
|
+
promptFieldStopRecording: 'Parar gravação',
|
|
271
261
|
// Prompt
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
262
|
+
promptRerun: 'Executar novamente',
|
|
263
|
+
promptProcessing: 'Processando…',
|
|
264
|
+
promptAppliedChanges: 'Alterações aplicadas',
|
|
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
|
-
|
|
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} é um destes: ${value}`;
|
|
272
|
+
}
|
|
273
|
+
return `${column} ${operator} ${value}`;
|
|
274
|
+
},
|
|
275
|
+
promptChangeFilterDescription: (column, operator, value) => {
|
|
276
|
+
if (operator === 'is any of') {
|
|
277
|
+
return `Filtrar onde ${column} é um destes: ${value}`;
|
|
278
|
+
}
|
|
279
|
+
return `Filtrar onde ${column} ${operator} ${value}`;
|
|
280
|
+
},
|
|
281
|
+
promptChangeSortDescription: (column, direction) => `Classificar por ${column} (${direction})`,
|
|
282
|
+
promptChangePivotEnableLabel: 'Pivotar',
|
|
283
|
+
promptChangePivotEnableDescription: 'Ativar pivotar',
|
|
284
|
+
promptChangePivotColumnsLabel: count => `Colunas (${count})`,
|
|
285
|
+
promptChangePivotColumnsDescription: (column, direction) => `${column}${direction ? ` (${direction})` : ''}`,
|
|
286
|
+
promptChangePivotRowsLabel: count => `Linhas (${count})`,
|
|
287
|
+
promptChangePivotValuesLabel: count => `Valores (${count})`,
|
|
288
|
+
promptChangePivotValuesDescription: (column, aggregation) => `${column} (${aggregation})`
|
|
300
289
|
};
|
|
301
290
|
export const ptBR = getGridLocalization(ptBRGrid);
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { GridColumnGroupingModel, GridColumnGroup } from "../../../models/gridColumnGrouping.js";
|
|
1
|
+
import { GridColumnGroupingModel, GridColumnNode, GridColumnGroup } from "../../../models/gridColumnGrouping.js";
|
|
2
2
|
import { GridColDef } from "../../../models/colDef/index.js";
|
|
3
|
-
import { GridGroupingStructure } from "./gridColumnGroupsInterfaces.js";
|
|
3
|
+
import { GridColumnGroupLookup, GridGroupingStructure } from "./gridColumnGroupsInterfaces.js";
|
|
4
4
|
type UnwrappedGroupingModel = {
|
|
5
5
|
[key: GridColDef['field']]: GridColumnGroup['groupId'][];
|
|
6
6
|
};
|
|
7
|
+
export declare const createGroupLookup: (columnGroupingModel: GridColumnNode[]) => GridColumnGroupLookup;
|
|
7
8
|
/**
|
|
8
9
|
* This is a function that provide for each column the array of its parents.
|
|
9
10
|
* Parents are ordered from the root to the leaf.
|
|
@@ -1,11 +1,47 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
3
4
|
Object.defineProperty(exports, "__esModule", {
|
|
4
5
|
value: true
|
|
5
6
|
});
|
|
6
|
-
exports.unwrapGroupingColumnModel = exports.getColumnGroupsHeaderStructure = void 0;
|
|
7
|
+
exports.unwrapGroupingColumnModel = exports.getColumnGroupsHeaderStructure = exports.createGroupLookup = void 0;
|
|
8
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
9
|
+
var _objectWithoutPropertiesLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutPropertiesLoose"));
|
|
7
10
|
var _gridColumnGrouping = require("../../../models/gridColumnGrouping");
|
|
11
|
+
const _excluded = ["groupId", "children"];
|
|
12
|
+
const createGroupLookup = columnGroupingModel => {
|
|
13
|
+
const groupLookup = {};
|
|
14
|
+
for (let i = 0; i < columnGroupingModel.length; i += 1) {
|
|
15
|
+
const node = columnGroupingModel[i];
|
|
16
|
+
if ((0, _gridColumnGrouping.isLeaf)(node)) {
|
|
17
|
+
continue;
|
|
18
|
+
}
|
|
19
|
+
const {
|
|
20
|
+
groupId,
|
|
21
|
+
children
|
|
22
|
+
} = node,
|
|
23
|
+
other = (0, _objectWithoutPropertiesLoose2.default)(node, _excluded);
|
|
24
|
+
if (!groupId) {
|
|
25
|
+
throw new Error('MUI X: An element of the columnGroupingModel does not have either `field` or `groupId`.');
|
|
26
|
+
}
|
|
27
|
+
if (process.env.NODE_ENV !== 'production' && !children) {
|
|
28
|
+
console.warn(`MUI X: group groupId=${groupId} has no children.`);
|
|
29
|
+
}
|
|
30
|
+
const groupParam = (0, _extends2.default)({}, other, {
|
|
31
|
+
groupId
|
|
32
|
+
});
|
|
33
|
+
const subTreeLookup = createGroupLookup(children);
|
|
34
|
+
if (subTreeLookup[groupId] !== undefined || groupLookup[groupId] !== undefined) {
|
|
35
|
+
throw new Error(`MUI X: The groupId ${groupId} is used multiple times in the columnGroupingModel.`);
|
|
36
|
+
}
|
|
37
|
+
Object.assign(groupLookup, subTreeLookup);
|
|
38
|
+
groupLookup[groupId] = groupParam;
|
|
39
|
+
}
|
|
40
|
+
return groupLookup;
|
|
41
|
+
};
|
|
42
|
+
|
|
8
43
|
// This is the recurrence function that help writing `unwrapGroupingColumnModel()`
|
|
44
|
+
exports.createGroupLookup = createGroupLookup;
|
|
9
45
|
const recurrentUnwrapGroupingColumnModel = (columnGroupNode, parents, unwrappedGroupingModelToComplete) => {
|
|
10
46
|
if ((0, _gridColumnGrouping.isLeaf)(columnGroupNode)) {
|
|
11
47
|
if (unwrappedGroupingModelToComplete[columnGroupNode.field] !== undefined) {
|
|
@@ -1,52 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
'use client';
|
|
3
3
|
|
|
4
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
5
4
|
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
5
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
6
6
|
Object.defineProperty(exports, "__esModule", {
|
|
7
7
|
value: true
|
|
8
8
|
});
|
|
9
9
|
exports.useGridColumnGrouping = exports.columnGroupsStateInitializer = void 0;
|
|
10
10
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
|
-
var _objectWithoutPropertiesLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutPropertiesLoose"));
|
|
12
11
|
var React = _interopRequireWildcard(require("react"));
|
|
13
|
-
var _gridColumnGrouping = require("../../../models/gridColumnGrouping");
|
|
14
12
|
var _gridColumnGroupsSelector = require("./gridColumnGroupsSelector");
|
|
15
13
|
var _useGridApiMethod = require("../../utils/useGridApiMethod");
|
|
16
14
|
var _gridColumnGroupsUtils = require("./gridColumnGroupsUtils");
|
|
17
15
|
var _useGridEvent = require("../../utils/useGridEvent");
|
|
18
16
|
var _columns = require("../columns");
|
|
19
|
-
const _excluded = ["groupId", "children"];
|
|
20
|
-
const createGroupLookup = columnGroupingModel => {
|
|
21
|
-
const groupLookup = {};
|
|
22
|
-
for (let i = 0; i < columnGroupingModel.length; i += 1) {
|
|
23
|
-
const node = columnGroupingModel[i];
|
|
24
|
-
if ((0, _gridColumnGrouping.isLeaf)(node)) {
|
|
25
|
-
continue;
|
|
26
|
-
}
|
|
27
|
-
const {
|
|
28
|
-
groupId,
|
|
29
|
-
children
|
|
30
|
-
} = node,
|
|
31
|
-
other = (0, _objectWithoutPropertiesLoose2.default)(node, _excluded);
|
|
32
|
-
if (!groupId) {
|
|
33
|
-
throw new Error('MUI X: An element of the columnGroupingModel does not have either `field` or `groupId`.');
|
|
34
|
-
}
|
|
35
|
-
if (process.env.NODE_ENV !== 'production' && !children) {
|
|
36
|
-
console.warn(`MUI X: group groupId=${groupId} has no children.`);
|
|
37
|
-
}
|
|
38
|
-
const groupParam = (0, _extends2.default)({}, other, {
|
|
39
|
-
groupId
|
|
40
|
-
});
|
|
41
|
-
const subTreeLookup = createGroupLookup(children);
|
|
42
|
-
if (subTreeLookup[groupId] !== undefined || groupLookup[groupId] !== undefined) {
|
|
43
|
-
throw new Error(`MUI X: The groupId ${groupId} is used multiple times in the columnGroupingModel.`);
|
|
44
|
-
}
|
|
45
|
-
Object.assign(groupLookup, subTreeLookup);
|
|
46
|
-
groupLookup[groupId] = groupParam;
|
|
47
|
-
}
|
|
48
|
-
return groupLookup;
|
|
49
|
-
};
|
|
50
17
|
const columnGroupsStateInitializer = (state, props, apiRef) => {
|
|
51
18
|
apiRef.current.caches.columnGrouping = {
|
|
52
19
|
lastColumnGroupingModel: props.columnGroupingModel
|
|
@@ -56,7 +23,7 @@ const columnGroupsStateInitializer = (state, props, apiRef) => {
|
|
|
56
23
|
}
|
|
57
24
|
const columnFields = (0, _columns.gridColumnFieldsSelector)(apiRef);
|
|
58
25
|
const visibleColumnFields = (0, _columns.gridVisibleColumnFieldsSelector)(apiRef);
|
|
59
|
-
const groupLookup = createGroupLookup(props.columnGroupingModel ?? []);
|
|
26
|
+
const groupLookup = (0, _gridColumnGroupsUtils.createGroupLookup)(props.columnGroupingModel ?? []);
|
|
60
27
|
const unwrappedGroupingModel = (0, _gridColumnGroupsUtils.unwrapGroupingColumnModel)(props.columnGroupingModel ?? []);
|
|
61
28
|
const columnGroupsHeaderStructure = (0, _gridColumnGroupsUtils.getColumnGroupsHeaderStructure)(columnFields, unwrappedGroupingModel, apiRef.current.state.pinnedColumns ?? {});
|
|
62
29
|
const maxDepth = visibleColumnFields.length === 0 ? 0 : Math.max(...visibleColumnFields.map(field => unwrappedGroupingModel[field]?.length ?? 0));
|
|
@@ -111,7 +78,7 @@ const useGridColumnGrouping = (apiRef, props) => {
|
|
|
111
78
|
const pinnedColumns = apiRef.current.getPinnedColumns?.() ?? {};
|
|
112
79
|
const columnFields = (0, _columns.gridColumnFieldsSelector)(apiRef);
|
|
113
80
|
const visibleColumnFields = (0, _columns.gridVisibleColumnFieldsSelector)(apiRef);
|
|
114
|
-
const groupLookup = createGroupLookup(columnGroupingModel ?? []);
|
|
81
|
+
const groupLookup = (0, _gridColumnGroupsUtils.createGroupLookup)(columnGroupingModel ?? []);
|
|
115
82
|
const unwrappedGroupingModel = (0, _gridColumnGroupsUtils.unwrapGroupingColumnModel)(columnGroupingModel ?? []);
|
|
116
83
|
const columnGroupsHeaderStructure = (0, _gridColumnGroupsUtils.getColumnGroupsHeaderStructure)(columnFields, unwrappedGroupingModel, pinnedColumns);
|
|
117
84
|
const maxDepth = visibleColumnFields.length === 0 ? 0 : Math.max(...visibleColumnFields.map(field => unwrappedGroupingModel[field]?.length ?? 0));
|
|
@@ -39,7 +39,10 @@ const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
39
39
|
const setStrategyAvailability = React.useCallback(() => {
|
|
40
40
|
apiRef.current.setStrategyAvailability(_strategyProcessing.GridStrategyGroup.DataSource, _utils2.DataSourceRowsUpdateStrategy.Default, props.dataSource ? () => true : () => false);
|
|
41
41
|
}, [apiRef, props.dataSource]);
|
|
42
|
-
const [
|
|
42
|
+
const [currentStrategy, setCurrentStrategy] = React.useState(apiRef.current.getActiveStrategy(_strategyProcessing.GridStrategyGroup.DataSource));
|
|
43
|
+
const defaultRowsUpdateStrategyActive = React.useMemo(() => {
|
|
44
|
+
return currentStrategy === _utils2.DataSourceRowsUpdateStrategy.Default;
|
|
45
|
+
}, [currentStrategy]);
|
|
43
46
|
const paginationModel = (0, _useGridSelector.useGridSelector)(apiRef, _gridPaginationSelector.gridPaginationModelSelector);
|
|
44
47
|
const lastRequestId = React.useRef(0);
|
|
45
48
|
const onDataSourceErrorProp = props.onDataSourceError;
|
|
@@ -117,7 +120,7 @@ const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
117
120
|
}
|
|
118
121
|
}, [cacheChunkManager, cache, apiRef, defaultRowsUpdateStrategyActive, props.dataSource?.getRows, onDataSourceErrorProp, options, props.signature]);
|
|
119
122
|
const handleStrategyActivityChange = React.useCallback(() => {
|
|
120
|
-
|
|
123
|
+
setCurrentStrategy(apiRef.current.getActiveStrategy(_strategyProcessing.GridStrategyGroup.DataSource));
|
|
121
124
|
}, [apiRef]);
|
|
122
125
|
const handleDataUpdate = React.useCallback(params => {
|
|
123
126
|
if ('error' in params) {
|
|
@@ -190,8 +193,7 @@ const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
190
193
|
React.useEffect(() => {
|
|
191
194
|
// Return early if the proper strategy isn't set yet
|
|
192
195
|
// Context: https://github.com/mui/mui-x/issues/19650
|
|
193
|
-
|
|
194
|
-
if (strategy !== _utils2.DataSourceRowsUpdateStrategy.Default && strategy !== _utils2.DataSourceRowsUpdateStrategy.LazyLoading) {
|
|
196
|
+
if (currentStrategy !== _utils2.DataSourceRowsUpdateStrategy.Default && currentStrategy !== _utils2.DataSourceRowsUpdateStrategy.LazyLoading) {
|
|
195
197
|
return undefined;
|
|
196
198
|
}
|
|
197
199
|
if (props.dataSource) {
|
|
@@ -202,7 +204,7 @@ const useGridDataSourceBase = (apiRef, props, options = {}) => {
|
|
|
202
204
|
// ignore the current request on unmount
|
|
203
205
|
lastRequestId.current += 1;
|
|
204
206
|
};
|
|
205
|
-
}, [apiRef, props.dataSource]);
|
|
207
|
+
}, [apiRef, props.dataSource, currentStrategy]);
|
|
206
208
|
return {
|
|
207
209
|
api: {
|
|
208
210
|
public: dataSourceApi
|
|
@@ -66,10 +66,8 @@ class CacheChunkManager {
|
|
|
66
66
|
if (responses.length === 1) {
|
|
67
67
|
return responses[0];
|
|
68
68
|
}
|
|
69
|
-
return responses.reduce((acc, response) => ({
|
|
70
|
-
rows: [...acc.rows, ...response.rows]
|
|
71
|
-
rowCount: response.rowCount,
|
|
72
|
-
pageInfo: response.pageInfo
|
|
69
|
+
return responses.reduce((acc, response) => (0, _extends2.default)({}, response, {
|
|
70
|
+
rows: [...acc.rows, ...response.rows]
|
|
73
71
|
}), {
|
|
74
72
|
rows: [],
|
|
75
73
|
rowCount: 0,
|
|
@@ -113,7 +113,7 @@ const useGridRows = (apiRef, props, configuration) => {
|
|
|
113
113
|
*/
|
|
114
114
|
const setRows = React.useCallback(rows => {
|
|
115
115
|
logger.debug(`Updating all rows, new length ${rows.length}`);
|
|
116
|
-
if ((0, _pivoting.gridPivotActiveSelector)(apiRef)) {
|
|
116
|
+
if (!props.dataSource && (0, _pivoting.gridPivotActiveSelector)(apiRef)) {
|
|
117
117
|
apiRef.current.updateNonPivotRows(rows, false);
|
|
118
118
|
return;
|
|
119
119
|
}
|
|
@@ -129,12 +129,12 @@ const useGridRows = (apiRef, props, configuration) => {
|
|
|
129
129
|
cache,
|
|
130
130
|
throttle: true
|
|
131
131
|
});
|
|
132
|
-
}, [logger, props.getRowId, props.loading, props.rowCount, throttledRowsChange, apiRef]);
|
|
132
|
+
}, [logger, props.getRowId, props.dataSource, props.loading, props.rowCount, throttledRowsChange, apiRef]);
|
|
133
133
|
const updateRows = React.useCallback(updates => {
|
|
134
134
|
if (props.signature === _signature.GridSignature.DataGrid && updates.length > 1) {
|
|
135
135
|
throw new Error(['MUI X: You cannot update several rows at once in `apiRef.current.updateRows` on the DataGrid.', 'You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature.'].join('\n'));
|
|
136
136
|
}
|
|
137
|
-
if ((0, _pivoting.gridPivotActiveSelector)(apiRef)) {
|
|
137
|
+
if (!props.dataSource && (0, _pivoting.gridPivotActiveSelector)(apiRef)) {
|
|
138
138
|
apiRef.current.updateNonPivotRows(updates);
|
|
139
139
|
return;
|
|
140
140
|
}
|
|
@@ -148,7 +148,7 @@ const useGridRows = (apiRef, props, configuration) => {
|
|
|
148
148
|
cache,
|
|
149
149
|
throttle: true
|
|
150
150
|
});
|
|
151
|
-
}, [props.signature, props.getRowId, throttledRowsChange, apiRef]);
|
|
151
|
+
}, [props.signature, props.dataSource, props.getRowId, throttledRowsChange, apiRef]);
|
|
152
152
|
const updateNestedRows = React.useCallback((updates, groupKeys) => {
|
|
153
153
|
const nonPinnedRowsUpdates = (0, _gridRowsUtils.computeRowsUpdates)(apiRef, updates, props.getRowId);
|
|
154
154
|
const cache = (0, _gridRowsUtils.updateCacheWithNewRows)({
|
package/index.js
CHANGED
package/locales/ptBR.js
CHANGED
|
@@ -9,10 +9,9 @@ const ptBRGrid = {
|
|
|
9
9
|
// Root
|
|
10
10
|
noRowsLabel: 'Nenhuma linha',
|
|
11
11
|
noResultsOverlayLabel: 'Nenhum resultado encontrado.',
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
noColumnsOverlayLabel: 'Nenhuma coluna',
|
|
13
|
+
noColumnsOverlayManageColumns: 'Gerenciar colunas',
|
|
14
|
+
emptyPivotOverlayLabel: 'Adicionar campos às linhas, colunas e valores para criar uma tabela dinâmica',
|
|
16
15
|
// Density selector toolbar button text
|
|
17
16
|
toolbarDensity: 'Densidade',
|
|
18
17
|
toolbarDensityLabel: 'Densidade',
|
|
@@ -27,7 +26,7 @@ const ptBRGrid = {
|
|
|
27
26
|
toolbarFiltersLabel: 'Exibir filtros',
|
|
28
27
|
toolbarFiltersTooltipHide: 'Ocultar filtros',
|
|
29
28
|
toolbarFiltersTooltipShow: 'Exibir filtros',
|
|
30
|
-
toolbarFiltersTooltipActive: count =>
|
|
29
|
+
toolbarFiltersTooltipActive: count => count !== 1 ? `${count} filtros ativos` : `${count} filtro ativo`,
|
|
31
30
|
// Quick filter toolbar field
|
|
32
31
|
toolbarQuickFilterPlaceholder: 'Procurar…',
|
|
33
32
|
toolbarQuickFilterLabel: 'Procurar',
|
|
@@ -39,14 +38,11 @@ const ptBRGrid = {
|
|
|
39
38
|
toolbarExportPrint: 'Imprimir',
|
|
40
39
|
toolbarExportExcel: 'Baixar como Excel',
|
|
41
40
|
// Toolbar pivot button
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
toolbarPivot: 'Pivotar',
|
|
44
42
|
// Toolbar charts button
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
toolbarCharts: 'Gráficos',
|
|
47
44
|
// Toolbar AI Assistant button
|
|
48
|
-
|
|
49
|
-
|
|
45
|
+
toolbarAssistant: 'Assistente de IA',
|
|
50
46
|
// Columns management text
|
|
51
47
|
columnsManagementSearchTitle: 'Buscar',
|
|
52
48
|
columnsManagementNoColumns: 'Nenhuma coluna',
|
|
@@ -108,28 +104,26 @@ const ptBRGrid = {
|
|
|
108
104
|
'headerFilterOperator>=': 'Maior que ou igual a',
|
|
109
105
|
'headerFilterOperator<': 'Menor que',
|
|
110
106
|
'headerFilterOperator<=': 'Menor que ou igual a',
|
|
111
|
-
|
|
112
|
-
|
|
107
|
+
headerFilterClear: 'Limpar filtro',
|
|
113
108
|
// Filter values text
|
|
114
109
|
filterValueAny: 'qualquer',
|
|
115
110
|
filterValueTrue: 'verdadeiro',
|
|
116
111
|
filterValueFalse: 'falso',
|
|
117
112
|
// Column menu text
|
|
118
113
|
columnMenuLabel: 'Menu',
|
|
119
|
-
|
|
114
|
+
columnMenuAriaLabel: columnName => `menu da coluna ${columnName}`,
|
|
120
115
|
columnMenuShowColumns: 'Exibir colunas',
|
|
121
116
|
columnMenuManageColumns: 'Gerir colunas',
|
|
122
117
|
columnMenuFilter: 'Filtrar',
|
|
123
|
-
columnMenuHideColumn: 'Ocultar',
|
|
118
|
+
columnMenuHideColumn: 'Ocultar coluna',
|
|
124
119
|
columnMenuUnsort: 'Desfazer ordenação',
|
|
125
120
|
columnMenuSortAsc: 'Ordenar do menor para o maior',
|
|
126
121
|
columnMenuSortDesc: 'Ordenar do maior para o menor',
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
122
|
+
columnMenuManagePivot: 'Gerenciar pivot',
|
|
123
|
+
columnMenuManageCharts: 'Gerenciar gráficos',
|
|
130
124
|
// Column header text
|
|
131
|
-
columnHeaderFiltersTooltipActive: count =>
|
|
132
|
-
columnHeaderFiltersLabel: 'Exibir
|
|
125
|
+
columnHeaderFiltersTooltipActive: count => count !== 1 ? `${count} filtros ativos` : `${count} filtro ativo`,
|
|
126
|
+
columnHeaderFiltersLabel: 'Exibir filtros',
|
|
133
127
|
columnHeaderSortIconLabel: 'Ordenar',
|
|
134
128
|
// Rows selected footer text
|
|
135
129
|
footerRowSelected: count => count !== 1 ? `${count.toLocaleString()} linhas selecionadas` : `${count.toLocaleString()} linha selecionada`,
|
|
@@ -138,9 +132,9 @@ const ptBRGrid = {
|
|
|
138
132
|
// Total visible row amount footer text
|
|
139
133
|
footerTotalVisibleRows: (visibleCount, totalCount) => `${visibleCount.toLocaleString()} de ${totalCount.toLocaleString()}`,
|
|
140
134
|
// Checkbox selection text
|
|
141
|
-
checkboxSelectionHeaderName: '
|
|
142
|
-
checkboxSelectionSelectAllRows: 'Selecionar todas linhas',
|
|
143
|
-
checkboxSelectionUnselectAllRows: 'Deselecionar todas linhas',
|
|
135
|
+
checkboxSelectionHeaderName: 'Caixa de seleção',
|
|
136
|
+
checkboxSelectionSelectAllRows: 'Selecionar todas as linhas',
|
|
137
|
+
checkboxSelectionUnselectAllRows: 'Deselecionar todas as linhas',
|
|
144
138
|
checkboxSelectionSelectRow: 'Selecionar linha',
|
|
145
139
|
checkboxSelectionUnselectRow: 'Deselecionar linha',
|
|
146
140
|
// Boolean cell text
|
|
@@ -155,7 +149,7 @@ const ptBRGrid = {
|
|
|
155
149
|
// Tree Data
|
|
156
150
|
treeDataGroupingHeaderName: 'Grupo',
|
|
157
151
|
treeDataExpand: 'mostrar filhos',
|
|
158
|
-
treeDataCollapse: '
|
|
152
|
+
treeDataCollapse: 'ocultar filhos',
|
|
159
153
|
// Grouping columns
|
|
160
154
|
groupingColumnHeaderName: 'Grupo',
|
|
161
155
|
groupColumn: name => `Agrupar por ${name}`,
|
|
@@ -163,21 +157,21 @@ const ptBRGrid = {
|
|
|
163
157
|
// Master/detail
|
|
164
158
|
detailPanelToggle: 'Painel de detalhes',
|
|
165
159
|
expandDetailPanel: 'Expandir',
|
|
166
|
-
collapseDetailPanel: '
|
|
160
|
+
collapseDetailPanel: 'Recolher',
|
|
167
161
|
// Pagination
|
|
168
162
|
paginationRowsPerPage: 'Linhas 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 : `mais de ${to}`}`;
|
|
171
|
+
}
|
|
172
|
+
const estimatedLabel = estimated && estimated > to ? `cerca de ${estimated}` : `mais 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 para a primeira página';
|
|
@@ -195,113 +189,108 @@ const ptBRGrid = {
|
|
|
195
189
|
rowReorderingHeaderName: 'Reorganizar linhas',
|
|
196
190
|
// Aggregation
|
|
197
191
|
aggregationMenuItemHeader: 'Agrupar',
|
|
198
|
-
|
|
192
|
+
aggregationFunctionLabelNone: 'nenhum',
|
|
199
193
|
aggregationFunctionLabelSum: 'soma',
|
|
200
194
|
aggregationFunctionLabelAvg: 'média',
|
|
201
195
|
aggregationFunctionLabelMin: 'mín',
|
|
202
196
|
aggregationFunctionLabelMax: 'máx',
|
|
203
197
|
aggregationFunctionLabelSize: 'tamanho',
|
|
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: 'Pivot',
|
|
200
|
+
pivotRows: 'Linhas',
|
|
201
|
+
pivotColumns: 'Colunas',
|
|
202
|
+
pivotValues: 'Valores',
|
|
203
|
+
pivotCloseButton: 'Fechar configurações de pivot',
|
|
204
|
+
pivotSearchButton: 'Pesquisar campos',
|
|
205
|
+
pivotSearchControlPlaceholder: 'Pesquisar campos',
|
|
206
|
+
pivotSearchControlLabel: 'Pesquisar campos',
|
|
207
|
+
pivotSearchControlClear: 'Limpar pesquisa',
|
|
208
|
+
pivotNoFields: 'Nenhum campo',
|
|
209
|
+
pivotMenuMoveUp: 'Mover para cima',
|
|
210
|
+
pivotMenuMoveDown: 'Mover para baixo',
|
|
211
|
+
pivotMenuMoveToTop: 'Mover para o topo',
|
|
212
|
+
pivotMenuMoveToBottom: 'Mover para a parte inferior',
|
|
213
|
+
pivotMenuRows: 'Linhas',
|
|
214
|
+
pivotMenuColumns: 'Colunas',
|
|
215
|
+
pivotMenuValues: 'Valores',
|
|
216
|
+
pivotMenuOptions: 'Opções de campo',
|
|
217
|
+
pivotMenuAddToRows: 'Adicionar às Linhas',
|
|
218
|
+
pivotMenuAddToColumns: 'Adicionar às Colunas',
|
|
219
|
+
pivotMenuAddToValues: 'Adicionar aos Valores',
|
|
220
|
+
pivotMenuRemove: 'Remover',
|
|
221
|
+
pivotDragToRows: 'Arraste aqui para criar linhas',
|
|
222
|
+
pivotDragToColumns: 'Arraste aqui para criar colunas',
|
|
223
|
+
pivotDragToValues: 'Arraste aqui para criar valores',
|
|
224
|
+
pivotYearColumnHeaderName: '(Ano)',
|
|
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: 'Não há gráficos disponíveis',
|
|
228
|
+
chartsChartNotSelected: 'Selecione um tipo de gráfico para configurar suas opções',
|
|
229
|
+
chartsTabChart: 'Gráfico',
|
|
230
|
+
chartsTabFields: 'Campos',
|
|
231
|
+
chartsTabCustomize: 'Personalizar',
|
|
232
|
+
chartsCloseButton: 'Fechar configuração de gráficos',
|
|
233
|
+
chartsSyncButtonLabel: 'Sincronizar gráfico',
|
|
234
|
+
chartsSearchPlaceholder: 'Pesquisar campos',
|
|
235
|
+
chartsSearchLabel: 'Pesquisar campos',
|
|
236
|
+
chartsSearchClear: 'Limpar pesquisa',
|
|
237
|
+
chartsNoFields: 'Nenhum campo',
|
|
238
|
+
chartsFieldBlocked: 'Este campo não pode ser adicionado a nenhuma seção',
|
|
239
|
+
chartsCategories: 'Categorias',
|
|
240
|
+
chartsSeries: 'Séries',
|
|
241
|
+
chartsMenuAddToDimensions: dimensionLabel => `Adicionar a ${dimensionLabel}`,
|
|
242
|
+
chartsMenuAddToValues: valuesLabel => `Adicionar a ${valuesLabel}`,
|
|
243
|
+
chartsMenuMoveUp: 'Mover para cima',
|
|
244
|
+
chartsMenuMoveDown: 'Mover para baixo',
|
|
245
|
+
chartsMenuMoveToTop: 'Mover para o topo',
|
|
246
|
+
chartsMenuMoveToBottom: 'Mover para a parte inferior',
|
|
247
|
+
chartsMenuOptions: 'Opções de campo',
|
|
248
|
+
chartsMenuRemove: 'Remover',
|
|
249
|
+
chartsDragToDimensions: dimensionLabel => `Arraste aqui para usar a coluna como ${dimensionLabel}`,
|
|
250
|
+
chartsDragToValues: valuesLabel => `Arraste aqui para usar a coluna como ${valuesLabel}`,
|
|
259
251
|
// AI Assistant panel
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
252
|
+
aiAssistantPanelTitle: 'Assistente de IA',
|
|
253
|
+
aiAssistantPanelClose: 'Fechar Assistente de IA',
|
|
254
|
+
aiAssistantPanelNewConversation: 'Nova conversa',
|
|
255
|
+
aiAssistantPanelConversationHistory: 'Histórico de conversas',
|
|
256
|
+
aiAssistantPanelEmptyConversation: 'Sem histórico de prompts',
|
|
257
|
+
aiAssistantSuggestions: 'Sugestões',
|
|
267
258
|
// Prompt field
|
|
268
259
|
promptFieldLabel: 'Prompt',
|
|
269
260
|
promptFieldPlaceholder: 'Digite um prompt…',
|
|
270
261
|
promptFieldPlaceholderWithRecording: 'Digite ou grave um prompt…',
|
|
271
262
|
promptFieldPlaceholderListening: 'Ouvindo o prompt…',
|
|
272
|
-
|
|
263
|
+
promptFieldSpeechRecognitionNotSupported: 'O reconhecimento de fala não é suportado neste navegador',
|
|
273
264
|
promptFieldSend: 'Enviar',
|
|
274
265
|
promptFieldRecord: 'Gravar',
|
|
275
|
-
promptFieldStopRecording: 'Parar gravação'
|
|
276
|
-
|
|
266
|
+
promptFieldStopRecording: 'Parar gravação',
|
|
277
267
|
// Prompt
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
268
|
+
promptRerun: 'Executar novamente',
|
|
269
|
+
promptProcessing: 'Processando…',
|
|
270
|
+
promptAppliedChanges: 'Alterações aplicadas',
|
|
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
|
-
|
|
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} é um destes: ${value}`;
|
|
278
|
+
}
|
|
279
|
+
return `${column} ${operator} ${value}`;
|
|
280
|
+
},
|
|
281
|
+
promptChangeFilterDescription: (column, operator, value) => {
|
|
282
|
+
if (operator === 'is any of') {
|
|
283
|
+
return `Filtrar onde ${column} é um destes: ${value}`;
|
|
284
|
+
}
|
|
285
|
+
return `Filtrar onde ${column} ${operator} ${value}`;
|
|
286
|
+
},
|
|
287
|
+
promptChangeSortDescription: (column, direction) => `Classificar por ${column} (${direction})`,
|
|
288
|
+
promptChangePivotEnableLabel: 'Pivotar',
|
|
289
|
+
promptChangePivotEnableDescription: 'Ativar pivotar',
|
|
290
|
+
promptChangePivotColumnsLabel: count => `Colunas (${count})`,
|
|
291
|
+
promptChangePivotColumnsDescription: (column, direction) => `${column}${direction ? ` (${direction})` : ''}`,
|
|
292
|
+
promptChangePivotRowsLabel: count => `Linhas (${count})`,
|
|
293
|
+
promptChangePivotValuesLabel: count => `Valores (${count})`,
|
|
294
|
+
promptChangePivotValuesDescription: (column, aggregation) => `${column} (${aggregation})`
|
|
306
295
|
};
|
|
307
296
|
const ptBR = exports.ptBR = (0, _getGridLocalization.getGridLocalization)(ptBRGrid);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/x-data-grid",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.14.0",
|
|
4
4
|
"author": "MUI Team",
|
|
5
5
|
"description": "The Community plan edition of the MUI X Data Grid components.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -38,12 +38,12 @@
|
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"@babel/runtime": "^7.28.4",
|
|
41
|
-
"@mui/utils": "^7.3.
|
|
41
|
+
"@mui/utils": "^7.3.3",
|
|
42
42
|
"clsx": "^2.1.1",
|
|
43
43
|
"prop-types": "^15.8.1",
|
|
44
|
-
"use-sync-external-store": "^1.
|
|
45
|
-
"@mui/x-internals": "8.
|
|
46
|
-
"@mui/x-virtualizer": "0.2.
|
|
44
|
+
"use-sync-external-store": "^1.6.0",
|
|
45
|
+
"@mui/x-internals": "8.14.0",
|
|
46
|
+
"@mui/x-virtualizer": "0.2.3"
|
|
47
47
|
},
|
|
48
48
|
"peerDependencies": {
|
|
49
49
|
"@emotion/react": "^11.9.0",
|