@mui/x-data-grid-premium 9.0.0-alpha.3 → 9.0.0-alpha.4
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 +123 -0
- package/DataGridPremium/DataGridPremium.js +2 -3
- package/DataGridPremium/DataGridPremium.mjs +2 -3
- package/components/GridPremiumToolbar.js +1 -1
- package/components/GridPremiumToolbar.mjs +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuChartsItem.js +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuChartsItem.mjs +1 -1
- package/hooks/features/aiAssistant/useGridAiAssistant.d.mts +1 -1
- package/hooks/features/aiAssistant/useGridAiAssistant.d.ts +1 -1
- package/hooks/features/aiAssistant/useGridAiAssistant.js +2 -3
- package/hooks/features/aiAssistant/useGridAiAssistant.mjs +2 -3
- package/hooks/features/chartsIntegration/useGridChartsIntegration.d.mts +2 -2
- package/hooks/features/chartsIntegration/useGridChartsIntegration.d.ts +2 -2
- package/hooks/features/chartsIntegration/useGridChartsIntegration.js +5 -5
- package/hooks/features/chartsIntegration/useGridChartsIntegration.mjs +5 -5
- package/index.js +1 -1
- package/index.mjs +1 -1
- package/models/dataGridPremiumProps.d.mts +1 -3
- package/models/dataGridPremiumProps.d.ts +1 -3
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,128 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 9.0.0-alpha.4
|
|
4
|
+
|
|
5
|
+
_Mar 19, 2026_
|
|
6
|
+
|
|
7
|
+
We'd like to extend a big thank you to the 12 contributors who made this release possible. Here are some highlights ✨:
|
|
8
|
+
|
|
9
|
+
- 🐞 Bugfixes and internal improvements
|
|
10
|
+
|
|
11
|
+
The following team members contributed to this release:
|
|
12
|
+
@aemartos, @alexfauquette, @bernardobelchior, @Janpot, @JCQuintas, @LukasTy, @mapache-salvaje, @michelengelen, @noraleonte, @rita-codes, @sai6855, @siriwatknp
|
|
13
|
+
|
|
14
|
+
### Data Grid
|
|
15
|
+
|
|
16
|
+
#### `@mui/x-data-grid@9.0.0-alpha.4`
|
|
17
|
+
|
|
18
|
+
- [DataGrid] Mark charts integration as stable (#21764) @JCQuintas
|
|
19
|
+
- [DataGrid] Move `elementOverrides` to constants and remove duplicates (#21618) @sai6855
|
|
20
|
+
- [DataGrid] Migrate from deprecated Material UI APIs (#21682) @siriwatknp
|
|
21
|
+
|
|
22
|
+
#### `@mui/x-data-grid-pro@9.0.0-alpha.4` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
23
|
+
|
|
24
|
+
Same changes as in `@mui/x-data-grid@9.0.0-alpha.4`.
|
|
25
|
+
|
|
26
|
+
#### `@mui/x-data-grid-premium@9.0.0-alpha.4` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
27
|
+
|
|
28
|
+
Same changes as in `@mui/x-data-grid-pro@9.0.0-alpha.4`.
|
|
29
|
+
|
|
30
|
+
### Date and Time Pickers
|
|
31
|
+
|
|
32
|
+
#### `@mui/x-date-pickers@9.0.0-alpha.4`
|
|
33
|
+
|
|
34
|
+
- [pickers] Avoid stealing focus on click away (#13434) @LukasTy
|
|
35
|
+
- [pickers] Promote `fieldRef` to stable and add `clearValue` method (#21655) @michelengelen
|
|
36
|
+
|
|
37
|
+
#### `@mui/x-date-pickers-pro@9.0.0-alpha.4` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
38
|
+
|
|
39
|
+
Same changes as in `@mui/x-date-pickers@9.0.0-alpha.4`.
|
|
40
|
+
|
|
41
|
+
### Charts
|
|
42
|
+
|
|
43
|
+
#### `@mui/x-charts@9.0.0-alpha.4`
|
|
44
|
+
|
|
45
|
+
- [charts] Add v9 chart series types and helper functions migration (#21009) @bernardobelchior
|
|
46
|
+
- [charts] Extract event listener to the layer container (#21751) @alexfauquette
|
|
47
|
+
- [charts] Fix WebGL print export canvas stretching (#21738) @JCQuintas
|
|
48
|
+
- [charts] Improve deprecation warnings (#21760) @alexfauquette
|
|
49
|
+
- [charts] Improve type safety in `identifierCleaner` (#21719) @bernardobelchior
|
|
50
|
+
- [charts] Make `preferStrictDomainInLineCharts` the default (#21744) @JCQuintas
|
|
51
|
+
- [charts] Move title and description to the layer container (#21757) @alexfauquette
|
|
52
|
+
- [charts] Refactor `FunnelChart` classes structure (#21652) @JCQuintas
|
|
53
|
+
- [charts] Refactor `Heatmap` classes structure (#21653) @JCQuintas
|
|
54
|
+
- [charts] Refactor `RadarChart` classes structure (#21650) @JCQuintas
|
|
55
|
+
- [charts] Refactor `SankeyChart` classes structure (#21654) @JCQuintas
|
|
56
|
+
- [charts] Refactor legend getters to use utility functions (#21628) @sai6855
|
|
57
|
+
- [charts] Remove deprecated `ChartContainer` and `ChartDataProvider` (#21777) @alexfauquette
|
|
58
|
+
- [charts] Remove deprecated `itemId` from `SeriesLegendItemContext` (#21788) @alexfauquette
|
|
59
|
+
- [charts] Remove deprecated `useMouseTracker()` (#21787) @alexfauquette
|
|
60
|
+
- [charts] Remove deprecated classes (#21775) @alexfauquette
|
|
61
|
+
- [charts] Remove deprecated props from PieArcLabel animation (#21789) @alexfauquette
|
|
62
|
+
- [charts] Remove get*UtilityClass from public exports (#21769) @JCQuintas
|
|
63
|
+
- [charts] Remove the deprecated `disableHover` property (#21785) @alexfauquette
|
|
64
|
+
- [charts] Remove the deprecated `message` prop (#21784) @alexfauquette
|
|
65
|
+
- [charts] Remove deprecated props about voronoi (#21796) @alexfauquette
|
|
66
|
+
- [charts] Remove deprecated pieArcClasses (#21795) @alexfauquette
|
|
67
|
+
- [charts] Rename `data-series-id` by `data-series` (#21761) @alexfauquette
|
|
68
|
+
- [charts] Rename `voronoiMaxRadius`/`disableVoronoi` to `hitAreaRadius`/`disableHitArea` (#21750) @bernardobelchior
|
|
69
|
+
- [charts] Update pt-PT locale (#21296) @bernardobelchior
|
|
70
|
+
- [charts] Use different shape per series by default (#21713) @alexfauquette
|
|
71
|
+
- [charts] Add className prop to Radar components (#21794) @JCQuintas
|
|
72
|
+
- [charts] Add className prop to shared chart components (#21792) @JCQuintas
|
|
73
|
+
- [charts] Add className prop to BarPlot (#21791) @JCQuintas
|
|
74
|
+
- [charts] Portal tooltip into ChartsLayerContainer (#21801) @JCQuintas
|
|
75
|
+
|
|
76
|
+
#### `@mui/x-charts-pro@9.0.0-alpha.4` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
77
|
+
|
|
78
|
+
Same changes as in `@mui/x-charts@9.0.0-alpha.4`, plus:
|
|
79
|
+
|
|
80
|
+
- [charts-pro] Allow `brush` interaction to accept `requiredKeys/pointerMode` (#21716) @JCQuintas
|
|
81
|
+
- [charts-pro] Remove deprecated `onAxisClick` for Heatmap (#21786) @alexfauquette
|
|
82
|
+
|
|
83
|
+
#### `@mui/x-charts-premium@9.0.0-alpha.4` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
84
|
+
|
|
85
|
+
Same changes as in `@mui/x-charts-pro@9.0.0-alpha.4`, plus:
|
|
86
|
+
|
|
87
|
+
- [charts-premium] Add candlestick chart (#21129) @bernardobelchior
|
|
88
|
+
|
|
89
|
+
### Tree View
|
|
90
|
+
|
|
91
|
+
#### `@mui/x-tree-view@9.0.0-alpha.4`
|
|
92
|
+
|
|
93
|
+
Internal changes.
|
|
94
|
+
|
|
95
|
+
#### `@mui/x-tree-view-pro@9.0.0-alpha.4` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
96
|
+
|
|
97
|
+
Same changes as in `@mui/x-tree-view@9.0.0-alpha.4`.
|
|
98
|
+
|
|
99
|
+
### Codemod
|
|
100
|
+
|
|
101
|
+
#### `@mui/x-codemod@9.0.0-alpha.4`
|
|
102
|
+
|
|
103
|
+
Internal changes.
|
|
104
|
+
|
|
105
|
+
### Docs
|
|
106
|
+
|
|
107
|
+
- [docs-infra] Exclude `ServerSideLazyLoadingRevalidation` from argos (#21734) @sai6855
|
|
108
|
+
- [docs] Update charts v9 migration guide to include premium package (#21743) @bernardobelchior
|
|
109
|
+
- [docs] Update v9 migration guides to install next tag (#21741) @bernardobelchior
|
|
110
|
+
- [docs] Revise the Pie chart docs (#21565) @mapache-salvaje
|
|
111
|
+
- [docs] Revise the Bar Chart docs (#21482) @mapache-salvaje
|
|
112
|
+
- [docs] Removed a `console.log` from an aggregation demo (#21698) @michelengelen
|
|
113
|
+
|
|
114
|
+
### Core
|
|
115
|
+
|
|
116
|
+
- [code-infra] Add pkg-pr-new as dev dependency (#21754) @Janpot
|
|
117
|
+
- [code-infra] Prevent `combiner` to have default parameters (#21707) @JCQuintas
|
|
118
|
+
- [code-infra] Remove CI coverage collection and upload to Codecov (#21671) @Janpot
|
|
119
|
+
- [internal] Remove @bernardobelchior from Charts CODEOWNERS (#21776) @Copilot
|
|
120
|
+
|
|
121
|
+
### Miscellaneous
|
|
122
|
+
|
|
123
|
+
- [x-license] Fix process.env.MUI_VERSION not being replaced during build (#21727) @aemartos
|
|
124
|
+
- [x-license] Add new watermark license status message (#21720) @aemartos
|
|
125
|
+
|
|
3
126
|
## 9.0.0-alpha.3
|
|
4
127
|
|
|
5
128
|
_Mar 12, 2026_
|
|
@@ -51,8 +51,8 @@ const configuration = {
|
|
|
51
51
|
}
|
|
52
52
|
};
|
|
53
53
|
const packageInfo = {
|
|
54
|
-
releaseDate: "
|
|
55
|
-
version:
|
|
54
|
+
releaseDate: "MTc3Mzk2NDgwMDAwMA==",
|
|
55
|
+
version: "9.0.0-alpha.4",
|
|
56
56
|
name: 'x-data-grid-premium'
|
|
57
57
|
};
|
|
58
58
|
const watermark = /*#__PURE__*/(0, _jsxRuntime.jsx)(_internals.Watermark, {
|
|
@@ -501,7 +501,6 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
501
501
|
* For each feature, if the flag is not explicitly set to `true`, then the feature is fully disabled, and neither property nor method calls will have any effect.
|
|
502
502
|
*/
|
|
503
503
|
experimentalFeatures: _propTypes.default.shape({
|
|
504
|
-
charts: _propTypes.default.bool,
|
|
505
504
|
warnIfFocusStateIsNotSynced: _propTypes.default.bool
|
|
506
505
|
}),
|
|
507
506
|
/**
|
|
@@ -44,8 +44,8 @@ const configuration = {
|
|
|
44
44
|
}
|
|
45
45
|
};
|
|
46
46
|
const packageInfo = {
|
|
47
|
-
releaseDate: "
|
|
48
|
-
version:
|
|
47
|
+
releaseDate: "MTc3Mzk2NDgwMDAwMA==",
|
|
48
|
+
version: "9.0.0-alpha.4",
|
|
49
49
|
name: 'x-data-grid-premium'
|
|
50
50
|
};
|
|
51
51
|
const watermark = /*#__PURE__*/_jsx(Watermark, {
|
|
@@ -494,7 +494,6 @@ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
|
|
|
494
494
|
* For each feature, if the flag is not explicitly set to `true`, then the feature is fully disabled, and neither property nor method calls will have any effect.
|
|
495
495
|
*/
|
|
496
496
|
experimentalFeatures: PropTypes.shape({
|
|
497
|
-
charts: PropTypes.bool,
|
|
498
497
|
warnIfFocusStateIsNotSynced: PropTypes.bool
|
|
499
498
|
}),
|
|
500
499
|
/**
|
|
@@ -86,7 +86,7 @@ function GridPremiumToolbar(props) {
|
|
|
86
86
|
})
|
|
87
87
|
}))
|
|
88
88
|
})
|
|
89
|
-
}), rootProps.
|
|
89
|
+
}), rootProps.chartsIntegration && /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsPanelTrigger.ChartsPanelTrigger, {
|
|
90
90
|
render: triggerProps => /*#__PURE__*/(0, _jsxRuntime.jsx)(rootProps.slots.baseTooltip, {
|
|
91
91
|
title: apiRef.current.getLocaleText('toolbarCharts'),
|
|
92
92
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_xDataGridPro.ToolbarButton, (0, _extends2.default)({}, triggerProps, {
|
|
@@ -78,7 +78,7 @@ export function GridPremiumToolbar(props) {
|
|
|
78
78
|
})
|
|
79
79
|
}))
|
|
80
80
|
})
|
|
81
|
-
}), rootProps.
|
|
81
|
+
}), rootProps.chartsIntegration && /*#__PURE__*/_jsx(ChartsPanelTrigger, {
|
|
82
82
|
render: triggerProps => /*#__PURE__*/_jsx(rootProps.slots.baseTooltip, {
|
|
83
83
|
title: apiRef.current.getLocaleText('toolbarCharts'),
|
|
84
84
|
children: /*#__PURE__*/_jsx(ToolbarButton, _extends({}, triggerProps, {
|
|
@@ -22,7 +22,7 @@ function GridColumnMenuChartsItem(props) {
|
|
|
22
22
|
onClick(event);
|
|
23
23
|
apiRef.current.setChartsPanelOpen(true);
|
|
24
24
|
};
|
|
25
|
-
if (!rootProps.
|
|
25
|
+
if (!rootProps.chartsIntegration) {
|
|
26
26
|
return null;
|
|
27
27
|
}
|
|
28
28
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(rootProps.slots.baseMenuItem, {
|
|
@@ -15,7 +15,7 @@ export function GridColumnMenuChartsItem(props) {
|
|
|
15
15
|
onClick(event);
|
|
16
16
|
apiRef.current.setChartsPanelOpen(true);
|
|
17
17
|
};
|
|
18
|
-
if (!rootProps.
|
|
18
|
+
if (!rootProps.chartsIntegration) {
|
|
19
19
|
return null;
|
|
20
20
|
}
|
|
21
21
|
return /*#__PURE__*/_jsx(rootProps.slots.baseMenuItem, {
|
|
@@ -3,4 +3,4 @@ import { type GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
export declare const aiAssistantStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'initialState' | 'aiAssistantConversations' | 'aiAssistant'>>;
|
|
6
|
-
export declare const useGridAiAssistant: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "aiAssistant" | "aiAssistantConversations" | "aiAssistantActiveConversationIndex" | "allowAiAssistantDataSampling" | "onAiAssistantConversationsChange" | "onAiAssistantActiveConversationIndexChange" | "onPrompt" | "slots" | "rowSelection" | "disableColumnFilter" | "disableRowGrouping" | "disableAggregation" | "disableColumnSorting" | "disablePivoting" | "chartsIntegration" | "
|
|
6
|
+
export declare const useGridAiAssistant: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "aiAssistant" | "aiAssistantConversations" | "aiAssistantActiveConversationIndex" | "allowAiAssistantDataSampling" | "onAiAssistantConversationsChange" | "onAiAssistantActiveConversationIndexChange" | "onPrompt" | "slots" | "rowSelection" | "disableColumnFilter" | "disableRowGrouping" | "disableAggregation" | "disableColumnSorting" | "disablePivoting" | "chartsIntegration" | "getPivotDerivedColumns">) => void;
|
|
@@ -3,4 +3,4 @@ import { type GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
export declare const aiAssistantStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'initialState' | 'aiAssistantConversations' | 'aiAssistant'>>;
|
|
6
|
-
export declare const useGridAiAssistant: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "aiAssistant" | "aiAssistantConversations" | "aiAssistantActiveConversationIndex" | "allowAiAssistantDataSampling" | "onAiAssistantConversationsChange" | "onAiAssistantActiveConversationIndexChange" | "onPrompt" | "slots" | "rowSelection" | "disableColumnFilter" | "disableRowGrouping" | "disableAggregation" | "disableColumnSorting" | "disablePivoting" | "chartsIntegration" | "
|
|
6
|
+
export declare const useGridAiAssistant: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "aiAssistant" | "aiAssistantConversations" | "aiAssistantActiveConversationIndex" | "allowAiAssistantDataSampling" | "onAiAssistantConversationsChange" | "onAiAssistantActiveConversationIndexChange" | "onPrompt" | "slots" | "rowSelection" | "disableColumnFilter" | "disableRowGrouping" | "disableAggregation" | "disableColumnSorting" | "disablePivoting" | "chartsIntegration" | "getPivotDerivedColumns">) => void;
|
|
@@ -47,7 +47,6 @@ const useGridAiAssistant = (apiRef, props) => {
|
|
|
47
47
|
disableColumnSorting,
|
|
48
48
|
disablePivoting,
|
|
49
49
|
chartsIntegration,
|
|
50
|
-
experimentalFeatures,
|
|
51
50
|
getPivotDerivedColumns
|
|
52
51
|
} = props;
|
|
53
52
|
const previousUnwrappedGroupingModel = React.useRef([]);
|
|
@@ -217,7 +216,7 @@ const useGridAiAssistant = (apiRef, props) => {
|
|
|
217
216
|
} else {
|
|
218
217
|
result.sorting = [];
|
|
219
218
|
}
|
|
220
|
-
if (
|
|
219
|
+
if (chartsIntegration && activeChartId && result.chart) {
|
|
221
220
|
if (appliedPivoting) {
|
|
222
221
|
const unsubscribe = apiRef.current.subscribeEvent('rowsSet', () => {
|
|
223
222
|
const unwrappedGroupingModel = Object.keys((0, _xDataGridPro.gridColumnGroupsUnwrappedModelSelector)(apiRef));
|
|
@@ -256,7 +255,7 @@ const useGridAiAssistant = (apiRef, props) => {
|
|
|
256
255
|
apiRef.current.setRowSelectionModel(rowSelectionModel);
|
|
257
256
|
const targetIndex = Number(columnsLookup[_xDataGridPro.GRID_CHECKBOX_SELECTION_FIELD] !== undefined) + Number(result.grouping.length);
|
|
258
257
|
interestColumns.reverse().forEach(c => apiRef.current.setColumnIndex(c, targetIndex));
|
|
259
|
-
}, [apiRef, updateChart, rowSelection, disableColumnFilter, disableRowGrouping, disableAggregation, disableColumnSorting, disablePivoting, columnsLookup, isAiAssistantAvailable, activeChartId, chartsIntegration
|
|
258
|
+
}, [apiRef, updateChart, rowSelection, disableColumnFilter, disableRowGrouping, disableAggregation, disableColumnSorting, disablePivoting, columnsLookup, isAiAssistantAvailable, activeChartId, chartsIntegration]);
|
|
260
259
|
const setActiveConversationId = React.useCallback(id => {
|
|
261
260
|
if (!isAiAssistantAvailable) {
|
|
262
261
|
return;
|
|
@@ -39,7 +39,6 @@ export const useGridAiAssistant = (apiRef, props) => {
|
|
|
39
39
|
disableColumnSorting,
|
|
40
40
|
disablePivoting,
|
|
41
41
|
chartsIntegration,
|
|
42
|
-
experimentalFeatures,
|
|
43
42
|
getPivotDerivedColumns
|
|
44
43
|
} = props;
|
|
45
44
|
const previousUnwrappedGroupingModel = React.useRef([]);
|
|
@@ -209,7 +208,7 @@ export const useGridAiAssistant = (apiRef, props) => {
|
|
|
209
208
|
} else {
|
|
210
209
|
result.sorting = [];
|
|
211
210
|
}
|
|
212
|
-
if (
|
|
211
|
+
if (chartsIntegration && activeChartId && result.chart) {
|
|
213
212
|
if (appliedPivoting) {
|
|
214
213
|
const unsubscribe = apiRef.current.subscribeEvent('rowsSet', () => {
|
|
215
214
|
const unwrappedGroupingModel = Object.keys(gridColumnGroupsUnwrappedModelSelector(apiRef));
|
|
@@ -248,7 +247,7 @@ export const useGridAiAssistant = (apiRef, props) => {
|
|
|
248
247
|
apiRef.current.setRowSelectionModel(rowSelectionModel);
|
|
249
248
|
const targetIndex = Number(columnsLookup[GRID_CHECKBOX_SELECTION_FIELD] !== undefined) + Number(result.grouping.length);
|
|
250
249
|
interestColumns.reverse().forEach(c => apiRef.current.setColumnIndex(c, targetIndex));
|
|
251
|
-
}, [apiRef, updateChart, rowSelection, disableColumnFilter, disableRowGrouping, disableAggregation, disableColumnSorting, disablePivoting, columnsLookup, isAiAssistantAvailable, activeChartId, chartsIntegration
|
|
250
|
+
}, [apiRef, updateChart, rowSelection, disableColumnFilter, disableRowGrouping, disableAggregation, disableColumnSorting, disablePivoting, columnsLookup, isAiAssistantAvailable, activeChartId, chartsIntegration]);
|
|
252
251
|
const setActiveConversationId = React.useCallback(id => {
|
|
253
252
|
if (!isAiAssistantAvailable) {
|
|
254
253
|
return;
|
|
@@ -4,5 +4,5 @@ import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPrem
|
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
5
|
import type { ChartState } from "../../../models/gridChartsIntegration.mjs";
|
|
6
6
|
export declare const EMPTY_CHART_INTEGRATION_CONTEXT_STATE: ChartState;
|
|
7
|
-
export declare const chartsIntegrationStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'chartsIntegration' | 'initialState' | 'activeChartId' | 'rowGroupingModel' | 'pivotModel'
|
|
8
|
-
export declare const useGridChartsIntegration: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "chartsIntegration" | "activeChartId" | "onActiveChartIdChange" | "initialState" | "slots" | "slotProps" | "aggregationFunctions" | "dataSource"
|
|
7
|
+
export declare const chartsIntegrationStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'chartsIntegration' | 'initialState' | 'activeChartId' | 'rowGroupingModel' | 'pivotModel'>, GridPrivateApiPremium>;
|
|
8
|
+
export declare const useGridChartsIntegration: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "chartsIntegration" | "activeChartId" | "onActiveChartIdChange" | "initialState" | "slots" | "slotProps" | "aggregationFunctions" | "dataSource">) => void;
|
|
@@ -4,5 +4,5 @@ import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPrem
|
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
5
|
import type { ChartState } from "../../../models/gridChartsIntegration.js";
|
|
6
6
|
export declare const EMPTY_CHART_INTEGRATION_CONTEXT_STATE: ChartState;
|
|
7
|
-
export declare const chartsIntegrationStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'chartsIntegration' | 'initialState' | 'activeChartId' | 'rowGroupingModel' | 'pivotModel'
|
|
8
|
-
export declare const useGridChartsIntegration: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "chartsIntegration" | "activeChartId" | "onActiveChartIdChange" | "initialState" | "slots" | "slotProps" | "aggregationFunctions" | "dataSource"
|
|
7
|
+
export declare const chartsIntegrationStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'chartsIntegration' | 'initialState' | 'activeChartId' | 'rowGroupingModel' | 'pivotModel'>, GridPrivateApiPremium>;
|
|
8
|
+
export declare const useGridChartsIntegration: (apiRef: RefObject<GridPrivateApiPremium>, props: Pick<DataGridPremiumProcessedProps, "chartsIntegration" | "activeChartId" | "onActiveChartIdChange" | "initialState" | "slots" | "slotProps" | "aggregationFunctions" | "dataSource">) => void;
|
|
@@ -34,7 +34,7 @@ const EMPTY_CHART_INTEGRATION_CONTEXT_STATE = exports.EMPTY_CHART_INTEGRATION_CO
|
|
|
34
34
|
configuration: {}
|
|
35
35
|
};
|
|
36
36
|
const chartsIntegrationStateInitializer = (state, props) => {
|
|
37
|
-
if (!props.chartsIntegration
|
|
37
|
+
if (!props.chartsIntegration) {
|
|
38
38
|
return (0, _extends2.default)({}, state, {
|
|
39
39
|
chartsIntegration: {
|
|
40
40
|
activeChartId: '',
|
|
@@ -68,7 +68,7 @@ const useGridChartsIntegration = (apiRef, props) => {
|
|
|
68
68
|
const visibleValues = React.useRef({});
|
|
69
69
|
const schema = React.useMemo(() => props.slotProps?.chartsPanel?.schema || {}, [props.slotProps?.chartsPanel?.schema]);
|
|
70
70
|
const context = (0, _useGridChartIntegration.useGridChartsIntegrationContext)(true);
|
|
71
|
-
const isChartsIntegrationAvailable = !!props.chartsIntegration && !!
|
|
71
|
+
const isChartsIntegrationAvailable = !!props.chartsIntegration && !!context;
|
|
72
72
|
const activeChartId = (0, _gridChartsIntegrationSelectors.gridChartsIntegrationActiveChartIdSelector)(apiRef);
|
|
73
73
|
const aggregationModel = (0, _gridAggregationSelectors.gridAggregationModelSelector)(apiRef);
|
|
74
74
|
const pivotActive = (0, _internals.gridPivotActiveSelector)(apiRef);
|
|
@@ -494,7 +494,7 @@ const useGridChartsIntegration = (apiRef, props) => {
|
|
|
494
494
|
getColumnName
|
|
495
495
|
}
|
|
496
496
|
}, 'private');
|
|
497
|
-
(0, _internals.useGridApiMethod)(apiRef, props.
|
|
497
|
+
(0, _internals.useGridApiMethod)(apiRef, props.chartsIntegration ? {
|
|
498
498
|
setChartsPanelOpen,
|
|
499
499
|
setActiveChartId,
|
|
500
500
|
setChartType,
|
|
@@ -508,7 +508,7 @@ const useGridChartsIntegration = (apiRef, props) => {
|
|
|
508
508
|
(0, _internals.useGridEvent)(apiRef, 'sortedRowsSet', (0, _internals.runIf)(isChartsIntegrationAvailable, () => debouncedHandleRowDataUpdate(syncedChartIds)));
|
|
509
509
|
(0, _internals.useGridEvent)(apiRef, 'aggregationLookupSet', (0, _internals.runIf)(isChartsIntegrationAvailable, () => debouncedHandleRowDataUpdate(syncedChartIds)));
|
|
510
510
|
const stateExportPreProcessing = React.useCallback((prevState, exportContext) => {
|
|
511
|
-
if (!props.chartsIntegration
|
|
511
|
+
if (!props.chartsIntegration) {
|
|
512
512
|
return prevState;
|
|
513
513
|
}
|
|
514
514
|
const currentActiveChartId = (0, _gridChartsIntegrationSelectors.gridChartsIntegrationActiveChartIdSelector)(apiRef);
|
|
@@ -539,7 +539,7 @@ const useGridChartsIntegration = (apiRef, props) => {
|
|
|
539
539
|
return (0, _extends2.default)({}, prevState, {
|
|
540
540
|
chartsIntegration: chartStateToExport
|
|
541
541
|
});
|
|
542
|
-
}, [apiRef, chartStateLookup, props.chartsIntegration, props.
|
|
542
|
+
}, [apiRef, chartStateLookup, props.chartsIntegration, props.initialState?.chartsIntegration]);
|
|
543
543
|
const stateRestorePreProcessing = React.useCallback((params, restoreContext) => {
|
|
544
544
|
const chartsRestoreState = restoreContext.stateToRestore.chartsIntegration;
|
|
545
545
|
if (!chartsRestoreState) {
|
|
@@ -27,7 +27,7 @@ export const EMPTY_CHART_INTEGRATION_CONTEXT_STATE = {
|
|
|
27
27
|
configuration: {}
|
|
28
28
|
};
|
|
29
29
|
export const chartsIntegrationStateInitializer = (state, props) => {
|
|
30
|
-
if (!props.chartsIntegration
|
|
30
|
+
if (!props.chartsIntegration) {
|
|
31
31
|
return _extends({}, state, {
|
|
32
32
|
chartsIntegration: {
|
|
33
33
|
activeChartId: '',
|
|
@@ -60,7 +60,7 @@ export const useGridChartsIntegration = (apiRef, props) => {
|
|
|
60
60
|
const visibleValues = React.useRef({});
|
|
61
61
|
const schema = React.useMemo(() => props.slotProps?.chartsPanel?.schema || {}, [props.slotProps?.chartsPanel?.schema]);
|
|
62
62
|
const context = useGridChartsIntegrationContext(true);
|
|
63
|
-
const isChartsIntegrationAvailable = !!props.chartsIntegration && !!
|
|
63
|
+
const isChartsIntegrationAvailable = !!props.chartsIntegration && !!context;
|
|
64
64
|
const activeChartId = gridChartsIntegrationActiveChartIdSelector(apiRef);
|
|
65
65
|
const aggregationModel = gridAggregationModelSelector(apiRef);
|
|
66
66
|
const pivotActive = gridPivotActiveSelector(apiRef);
|
|
@@ -486,7 +486,7 @@ export const useGridChartsIntegration = (apiRef, props) => {
|
|
|
486
486
|
getColumnName
|
|
487
487
|
}
|
|
488
488
|
}, 'private');
|
|
489
|
-
useGridApiMethod(apiRef, props.
|
|
489
|
+
useGridApiMethod(apiRef, props.chartsIntegration ? {
|
|
490
490
|
setChartsPanelOpen,
|
|
491
491
|
setActiveChartId,
|
|
492
492
|
setChartType,
|
|
@@ -500,7 +500,7 @@ export const useGridChartsIntegration = (apiRef, props) => {
|
|
|
500
500
|
useGridEvent(apiRef, 'sortedRowsSet', runIf(isChartsIntegrationAvailable, () => debouncedHandleRowDataUpdate(syncedChartIds)));
|
|
501
501
|
useGridEvent(apiRef, 'aggregationLookupSet', runIf(isChartsIntegrationAvailable, () => debouncedHandleRowDataUpdate(syncedChartIds)));
|
|
502
502
|
const stateExportPreProcessing = React.useCallback((prevState, exportContext) => {
|
|
503
|
-
if (!props.chartsIntegration
|
|
503
|
+
if (!props.chartsIntegration) {
|
|
504
504
|
return prevState;
|
|
505
505
|
}
|
|
506
506
|
const currentActiveChartId = gridChartsIntegrationActiveChartIdSelector(apiRef);
|
|
@@ -531,7 +531,7 @@ export const useGridChartsIntegration = (apiRef, props) => {
|
|
|
531
531
|
return _extends({}, prevState, {
|
|
532
532
|
chartsIntegration: chartStateToExport
|
|
533
533
|
});
|
|
534
|
-
}, [apiRef, chartStateLookup, props.chartsIntegration, props.
|
|
534
|
+
}, [apiRef, chartStateLookup, props.chartsIntegration, props.initialState?.chartsIntegration]);
|
|
535
535
|
const stateRestorePreProcessing = React.useCallback((params, restoreContext) => {
|
|
536
536
|
const chartsRestoreState = restoreContext.stateToRestore.chartsIntegration;
|
|
537
537
|
if (!chartsRestoreState) {
|
package/index.js
CHANGED
package/index.mjs
CHANGED
|
@@ -12,9 +12,7 @@ import type { GridPivotingColDefOverrides, PivotingColDefCallback, GridPivotMode
|
|
|
12
12
|
import type { GridDataSourcePremium as GridDataSource, GridGetRowsParamsPremium as GridGetRowsParams } from "../hooks/features/dataSource/models.mjs";
|
|
13
13
|
import type { Conversation, PromptResponse, PromptSuggestion } from "../hooks/features/aiAssistant/gridAiAssistantInterfaces.mjs";
|
|
14
14
|
import type { GridHistoryEventHandler } from "../hooks/features/history/gridHistoryInterfaces.mjs";
|
|
15
|
-
export interface GridExperimentalPremiumFeatures extends GridExperimentalProFeatures {
|
|
16
|
-
charts?: boolean;
|
|
17
|
-
}
|
|
15
|
+
export interface GridExperimentalPremiumFeatures extends GridExperimentalProFeatures {}
|
|
18
16
|
export interface DataGridPremiumPropsWithComplexDefaultValueBeforeProcessing extends Pick<DataGridPropsWithComplexDefaultValueBeforeProcessing, 'localeText'> {
|
|
19
17
|
/**
|
|
20
18
|
* Overridable components.
|
|
@@ -12,9 +12,7 @@ import type { GridPivotingColDefOverrides, PivotingColDefCallback, GridPivotMode
|
|
|
12
12
|
import type { GridDataSourcePremium as GridDataSource, GridGetRowsParamsPremium as GridGetRowsParams } from "../hooks/features/dataSource/models.js";
|
|
13
13
|
import type { Conversation, PromptResponse, PromptSuggestion } from "../hooks/features/aiAssistant/gridAiAssistantInterfaces.js";
|
|
14
14
|
import type { GridHistoryEventHandler } from "../hooks/features/history/gridHistoryInterfaces.js";
|
|
15
|
-
export interface GridExperimentalPremiumFeatures extends GridExperimentalProFeatures {
|
|
16
|
-
charts?: boolean;
|
|
17
|
-
}
|
|
15
|
+
export interface GridExperimentalPremiumFeatures extends GridExperimentalProFeatures {}
|
|
18
16
|
export interface DataGridPremiumPropsWithComplexDefaultValueBeforeProcessing extends Pick<DataGridPropsWithComplexDefaultValueBeforeProcessing, 'localeText'> {
|
|
19
17
|
/**
|
|
20
18
|
* Overridable components.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/x-data-grid-premium",
|
|
3
|
-
"version": "9.0.0-alpha.
|
|
3
|
+
"version": "9.0.0-alpha.4",
|
|
4
4
|
"author": "MUI Team",
|
|
5
5
|
"description": "The Premium plan edition of the MUI X Data Grid Components.",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -38,10 +38,10 @@
|
|
|
38
38
|
"@mui/x-internal-exceljs-fork": "4.4.4",
|
|
39
39
|
"clsx": "^2.1.1",
|
|
40
40
|
"prop-types": "^15.8.1",
|
|
41
|
-
"@mui/x-data-grid
|
|
42
|
-
"@mui/x-
|
|
43
|
-
"@mui/x-
|
|
44
|
-
"@mui/x-license": "9.0.0-alpha.
|
|
41
|
+
"@mui/x-data-grid": "9.0.0-alpha.4",
|
|
42
|
+
"@mui/x-data-grid-pro": "9.0.0-alpha.4",
|
|
43
|
+
"@mui/x-internals": "9.0.0-alpha.4",
|
|
44
|
+
"@mui/x-license": "9.0.0-alpha.4"
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"@emotion/react": "^11.9.0",
|