@mui/x-charts 6.18.0 → 7.0.0-alpha.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/BarChart/BarChart.d.ts +15 -8
- package/BarChart/BarChart.js +41 -4
- package/BarChart/BarPlot.d.ts +2 -2
- package/CHANGELOG.md +212 -5
- package/ChartsAxis/ChartsAxis.d.ts +3 -3
- package/ChartsAxis/ChartsAxis.js +5 -5
- package/ChartsAxis/axisClasses.d.ts +2 -2
- package/ChartsLegend/ChartsLegend.d.ts +10 -6
- package/ChartsLegend/ChartsLegend.js +137 -2
- package/ChartsLegend/chartsLegendClasses.d.ts +1 -1
- package/ChartsLegend/chartsLegendClasses.js +2 -2
- package/ChartsReferenceLine/ChartsReferenceLine.d.ts +10 -0
- package/ChartsReferenceLine/ChartsReferenceLine.js +78 -0
- package/ChartsReferenceLine/ChartsXReferenceLine.d.ts +13 -0
- package/ChartsReferenceLine/ChartsXReferenceLine.js +112 -0
- package/ChartsReferenceLine/ChartsYReferenceLine.d.ts +13 -0
- package/ChartsReferenceLine/ChartsYReferenceLine.js +112 -0
- package/ChartsReferenceLine/chartsReferenceLineClasses.d.ts +15 -0
- package/ChartsReferenceLine/chartsReferenceLineClasses.js +14 -0
- package/ChartsReferenceLine/common.d.ts +41 -0
- package/ChartsReferenceLine/common.js +27 -0
- package/ChartsReferenceLine/index.d.ts +2 -0
- package/ChartsReferenceLine/index.js +27 -0
- package/ChartsReferenceLine/package.json +6 -0
- package/ChartsSurface.d.ts +11 -0
- package/ChartsTooltip/ChartsTooltip.d.ts +4 -4
- package/ChartsXAxis/ChartsXAxis.js +9 -5
- package/ChartsYAxis/ChartsYAxis.js +9 -5
- package/LineChart/AreaPlot.d.ts +2 -2
- package/LineChart/LineChart.d.ts +18 -11
- package/LineChart/LineChart.js +41 -4
- package/LineChart/LineHighlightPlot.d.ts +4 -4
- package/LineChart/LineHighlightPlot.js +1 -1
- package/LineChart/LinePlot.d.ts +2 -2
- package/LineChart/MarkPlot.d.ts +4 -4
- package/LineChart/MarkPlot.js +2 -1
- package/PieChart/PieArcLabelPlot.d.ts +4 -4
- package/PieChart/PieArcPlot.d.ts +4 -4
- package/PieChart/PieChart.d.ts +8 -8
- package/PieChart/PieChart.js +34 -4
- package/PieChart/PiePlot.d.ts +6 -6
- package/ResponsiveChartContainer/index.d.ts +13 -3
- package/ScatterChart/ScatterChart.d.ts +8 -8
- package/ScatterChart/ScatterChart.js +34 -4
- package/ScatterChart/ScatterPlot.d.ts +4 -4
- package/SparkLineChart/SparkLineChart.d.ts +10 -10
- package/SparkLineChart/SparkLineChart.js +22 -0
- package/context/CartesianContextProvider.d.ts +21 -1
- package/context/CartesianContextProvider.js +11 -0
- package/context/DrawingProvider.d.ts +18 -0
- package/context/DrawingProvider.js +6 -0
- package/context/HighlightProvider.d.ts +17 -0
- package/context/InteractionProvider.d.ts +6 -0
- package/context/SeriesContextProvider.d.ts +5 -0
- package/esm/BarChart/BarChart.js +41 -4
- package/esm/ChartsAxis/ChartsAxis.js +6 -5
- package/esm/ChartsLegend/ChartsLegend.js +140 -4
- package/esm/ChartsLegend/chartsLegendClasses.js +1 -1
- package/esm/ChartsReferenceLine/ChartsReferenceLine.js +70 -0
- package/esm/ChartsReferenceLine/ChartsXReferenceLine.js +105 -0
- package/esm/ChartsReferenceLine/ChartsYReferenceLine.js +105 -0
- package/esm/ChartsReferenceLine/chartsReferenceLineClasses.js +6 -0
- package/esm/ChartsReferenceLine/common.js +20 -0
- package/esm/ChartsReferenceLine/index.js +2 -0
- package/esm/ChartsXAxis/ChartsXAxis.js +10 -6
- package/esm/ChartsYAxis/ChartsYAxis.js +10 -6
- package/esm/LineChart/LineChart.js +41 -4
- package/esm/LineChart/LineHighlightPlot.js +1 -1
- package/esm/LineChart/MarkPlot.js +2 -1
- package/esm/PieChart/PieChart.js +34 -4
- package/esm/ScatterChart/ScatterChart.js +34 -4
- package/esm/SparkLineChart/SparkLineChart.js +22 -0
- package/esm/context/CartesianContextProvider.js +11 -0
- package/esm/context/DrawingProvider.js +6 -0
- package/esm/index.js +2 -0
- package/esm/internals/geometry.js +2 -2
- package/hooks/useScale.d.ts +2 -2
- package/index.d.ts +2 -0
- package/index.js +23 -1
- package/internals/components/ChartsText.d.ts +1 -1
- package/internals/geometry.d.ts +2 -2
- package/internals/geometry.js +2 -2
- package/internals/isBandScale.d.ts +3 -1
- package/internals/utils.d.ts +5 -0
- package/legacy/BarChart/BarChart.js +41 -4
- package/legacy/ChartsAxis/ChartsAxis.js +6 -5
- package/legacy/ChartsLegend/ChartsLegend.js +140 -4
- package/legacy/ChartsLegend/chartsLegendClasses.js +1 -1
- package/legacy/ChartsReferenceLine/ChartsReferenceLine.js +70 -0
- package/legacy/ChartsReferenceLine/ChartsXReferenceLine.js +105 -0
- package/legacy/ChartsReferenceLine/ChartsYReferenceLine.js +105 -0
- package/legacy/ChartsReferenceLine/chartsReferenceLineClasses.js +6 -0
- package/legacy/ChartsReferenceLine/common.js +20 -0
- package/legacy/ChartsReferenceLine/index.js +2 -0
- package/legacy/ChartsXAxis/ChartsXAxis.js +15 -12
- package/legacy/ChartsYAxis/ChartsYAxis.js +15 -12
- package/legacy/LineChart/LineChart.js +41 -4
- package/legacy/LineChart/LineHighlightPlot.js +1 -1
- package/legacy/LineChart/MarkPlot.js +2 -1
- package/legacy/PieChart/PieChart.js +34 -4
- package/legacy/ScatterChart/ScatterChart.js +34 -4
- package/legacy/SparkLineChart/SparkLineChart.js +22 -0
- package/legacy/context/CartesianContextProvider.js +11 -0
- package/legacy/context/DrawingProvider.js +6 -0
- package/legacy/index.js +3 -1
- package/legacy/internals/geometry.js +2 -2
- package/models/axis.d.ts +37 -17
- package/models/layout.d.ts +6 -0
- package/models/seriesType/common.d.ts +16 -0
- package/modern/BarChart/BarChart.js +41 -4
- package/modern/ChartsAxis/ChartsAxis.js +5 -5
- package/modern/ChartsLegend/ChartsLegend.js +140 -4
- package/modern/ChartsLegend/chartsLegendClasses.js +1 -1
- package/modern/ChartsReferenceLine/ChartsReferenceLine.js +70 -0
- package/modern/ChartsReferenceLine/ChartsXReferenceLine.js +104 -0
- package/modern/ChartsReferenceLine/ChartsYReferenceLine.js +104 -0
- package/modern/ChartsReferenceLine/chartsReferenceLineClasses.js +6 -0
- package/modern/ChartsReferenceLine/common.js +20 -0
- package/modern/ChartsReferenceLine/index.js +2 -0
- package/modern/ChartsXAxis/ChartsXAxis.js +9 -5
- package/modern/ChartsYAxis/ChartsYAxis.js +9 -5
- package/modern/LineChart/LineChart.js +41 -4
- package/modern/LineChart/LineHighlightPlot.js +1 -1
- package/modern/LineChart/MarkPlot.js +2 -1
- package/modern/PieChart/PieChart.js +34 -4
- package/modern/ScatterChart/ScatterChart.js +34 -4
- package/modern/SparkLineChart/SparkLineChart.js +22 -0
- package/modern/context/CartesianContextProvider.js +11 -0
- package/modern/context/DrawingProvider.js +6 -0
- package/modern/index.js +3 -1
- package/modern/internals/geometry.js +2 -2
- package/package.json +1 -1
package/BarChart/BarChart.d.ts
CHANGED
|
@@ -1,20 +1,27 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { BarPlotProps,
|
|
2
|
+
import { BarPlotProps, BarPlotSlotProps, BarPlotSlots } from './BarPlot';
|
|
3
3
|
import { ResponsiveChartContainerProps } from '../ResponsiveChartContainer';
|
|
4
4
|
import { ChartsAxisProps } from '../ChartsAxis';
|
|
5
5
|
import { BarSeriesType } from '../models/seriesType/bar';
|
|
6
6
|
import { MakeOptional } from '../models/helpers';
|
|
7
|
-
import { ChartsTooltipProps,
|
|
8
|
-
import { ChartsLegendProps,
|
|
7
|
+
import { ChartsTooltipProps, ChartsTooltipSlotProps, ChartsTooltipSlots } from '../ChartsTooltip';
|
|
8
|
+
import { ChartsLegendProps, ChartsLegendSlots, ChartsLegendSlotProps } from '../ChartsLegend';
|
|
9
9
|
import { ChartsAxisHighlightProps } from '../ChartsAxisHighlight';
|
|
10
|
-
import {
|
|
11
|
-
export interface
|
|
10
|
+
import { ChartsAxisSlots, ChartsAxisSlotProps } from '../models/axis';
|
|
11
|
+
export interface BarChartSlots extends ChartsAxisSlots, BarPlotSlots, ChartsLegendSlots, ChartsTooltipSlots {
|
|
12
12
|
}
|
|
13
|
-
export interface
|
|
13
|
+
export interface BarChartSlotProps extends ChartsAxisSlotProps, BarPlotSlotProps, ChartsLegendSlotProps, ChartsTooltipSlotProps {
|
|
14
14
|
}
|
|
15
15
|
export interface BarChartProps extends Omit<ResponsiveChartContainerProps, 'series'>, Omit<ChartsAxisProps, 'slots' | 'slotProps'>, Pick<BarPlotProps, 'skipAnimation'> {
|
|
16
16
|
series: MakeOptional<BarSeriesType, 'type'>[];
|
|
17
17
|
tooltip?: ChartsTooltipProps;
|
|
18
|
+
/**
|
|
19
|
+
* Object `{ x, y }` that defines how the charts highlight the mouse position along the x- and y-axes.
|
|
20
|
+
* The two properties accept the following values:
|
|
21
|
+
* - 'none': display nothing.
|
|
22
|
+
* - 'line': display a line at the current mouse position.
|
|
23
|
+
* - 'band': display a band at the current mouse position. Only available with band scale.
|
|
24
|
+
*/
|
|
18
25
|
axisHighlight?: ChartsAxisHighlightProps;
|
|
19
26
|
/**
|
|
20
27
|
* @deprecated Consider using `slotProps.legend` instead.
|
|
@@ -24,12 +31,12 @@ export interface BarChartProps extends Omit<ResponsiveChartContainerProps, 'seri
|
|
|
24
31
|
* Overridable component slots.
|
|
25
32
|
* @default {}
|
|
26
33
|
*/
|
|
27
|
-
slots?:
|
|
34
|
+
slots?: BarChartSlots;
|
|
28
35
|
/**
|
|
29
36
|
* The props used for each component slot.
|
|
30
37
|
* @default {}
|
|
31
38
|
*/
|
|
32
|
-
slotProps?:
|
|
39
|
+
slotProps?: BarChartSlotProps;
|
|
33
40
|
layout?: BarSeriesType['layout'];
|
|
34
41
|
}
|
|
35
42
|
/**
|
package/BarChart/BarChart.js
CHANGED
|
@@ -119,6 +119,13 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
119
119
|
// | These PropTypes are generated from the TypeScript type definitions |
|
|
120
120
|
// | To update them edit the TypeScript types and run "yarn proptypes" |
|
|
121
121
|
// ----------------------------------------------------------------------
|
|
122
|
+
/**
|
|
123
|
+
* Object `{ x, y }` that defines how the charts highlight the mouse position along the x- and y-axes.
|
|
124
|
+
* The two properties accept the following values:
|
|
125
|
+
* - 'none': display nothing.
|
|
126
|
+
* - 'line': display a line at the current mouse position.
|
|
127
|
+
* - 'band': display a band at the current mouse position. Only available with band scale.
|
|
128
|
+
*/
|
|
122
129
|
axisHighlight: _propTypes.default.shape({
|
|
123
130
|
x: _propTypes.default.oneOf(['band', 'line', 'none']),
|
|
124
131
|
y: _propTypes.default.oneOf(['band', 'line', 'none'])
|
|
@@ -129,7 +136,7 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
129
136
|
* @default xAxisIds[0] The id of the first provided axis
|
|
130
137
|
*/
|
|
131
138
|
bottomAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
132
|
-
axisId: _propTypes.default.string
|
|
139
|
+
axisId: _propTypes.default.string,
|
|
133
140
|
classes: _propTypes.default.object,
|
|
134
141
|
disableLine: _propTypes.default.bool,
|
|
135
142
|
disableTicks: _propTypes.default.bool,
|
|
@@ -156,9 +163,21 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
156
163
|
* Color palette used to colorize multiple series.
|
|
157
164
|
*/
|
|
158
165
|
colors: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.string), _propTypes.default.func]),
|
|
166
|
+
/**
|
|
167
|
+
* An array of objects that can be used to populate series and axes data using their `dataKey` property.
|
|
168
|
+
*/
|
|
159
169
|
dataset: _propTypes.default.arrayOf(_propTypes.default.object),
|
|
160
170
|
desc: _propTypes.default.string,
|
|
171
|
+
/**
|
|
172
|
+
* If `true`, the charts will not listen to the mouse move event.
|
|
173
|
+
* It might break interactive features, but will improve performance.
|
|
174
|
+
* @default false
|
|
175
|
+
*/
|
|
161
176
|
disableAxisListener: _propTypes.default.bool,
|
|
177
|
+
/**
|
|
178
|
+
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
179
|
+
* @default undefined
|
|
180
|
+
*/
|
|
162
181
|
height: _propTypes.default.number,
|
|
163
182
|
layout: _propTypes.default.oneOf(['horizontal', 'vertical']),
|
|
164
183
|
/**
|
|
@@ -167,7 +186,7 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
167
186
|
* @default yAxisIds[0] The id of the first provided axis
|
|
168
187
|
*/
|
|
169
188
|
leftAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
170
|
-
axisId: _propTypes.default.string
|
|
189
|
+
axisId: _propTypes.default.string,
|
|
171
190
|
classes: _propTypes.default.object,
|
|
172
191
|
disableLine: _propTypes.default.bool,
|
|
173
192
|
disableTicks: _propTypes.default.bool,
|
|
@@ -202,6 +221,12 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
202
221
|
slotProps: _propTypes.default.object,
|
|
203
222
|
slots: _propTypes.default.object
|
|
204
223
|
}),
|
|
224
|
+
/**
|
|
225
|
+
* The margin between the SVG and the drawing area.
|
|
226
|
+
* It's used for leaving some space for extra information such as the x- and y-axis or legend.
|
|
227
|
+
* Accepts an object with the optional properties: `top`, `bottom`, `left`, and `right`.
|
|
228
|
+
* @default object Depends on the charts type.
|
|
229
|
+
*/
|
|
205
230
|
margin: _propTypes.default.shape({
|
|
206
231
|
bottom: _propTypes.default.number,
|
|
207
232
|
left: _propTypes.default.number,
|
|
@@ -214,7 +239,7 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
214
239
|
* @default null
|
|
215
240
|
*/
|
|
216
241
|
rightAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
217
|
-
axisId: _propTypes.default.string
|
|
242
|
+
axisId: _propTypes.default.string,
|
|
218
243
|
classes: _propTypes.default.object,
|
|
219
244
|
disableLine: _propTypes.default.bool,
|
|
220
245
|
disableTicks: _propTypes.default.bool,
|
|
@@ -285,7 +310,7 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
285
310
|
* @default null
|
|
286
311
|
*/
|
|
287
312
|
topAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
288
|
-
axisId: _propTypes.default.string
|
|
313
|
+
axisId: _propTypes.default.string,
|
|
289
314
|
classes: _propTypes.default.object,
|
|
290
315
|
disableLine: _propTypes.default.bool,
|
|
291
316
|
disableTicks: _propTypes.default.bool,
|
|
@@ -312,7 +337,15 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
312
337
|
x: _propTypes.default.number,
|
|
313
338
|
y: _propTypes.default.number
|
|
314
339
|
}),
|
|
340
|
+
/**
|
|
341
|
+
* The width of the chart in px. If not defined, it takes the width of the parent element.
|
|
342
|
+
* @default undefined
|
|
343
|
+
*/
|
|
315
344
|
width: _propTypes.default.number,
|
|
345
|
+
/**
|
|
346
|
+
* The configuration of the x-axes.
|
|
347
|
+
* If not provided, a default axis config is used with id set to `DEFAULT_X_AXIS_KEY`.
|
|
348
|
+
*/
|
|
316
349
|
xAxis: _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
317
350
|
axisId: _propTypes.default.string,
|
|
318
351
|
classes: _propTypes.default.object,
|
|
@@ -343,6 +376,10 @@ process.env.NODE_ENV !== "production" ? BarChart.propTypes = {
|
|
|
343
376
|
tickSize: _propTypes.default.number,
|
|
344
377
|
valueFormatter: _propTypes.default.func
|
|
345
378
|
})),
|
|
379
|
+
/**
|
|
380
|
+
* The configuration of the y-axes.
|
|
381
|
+
* If not provided, a default axis config is used with id set to `DEFAULT_Y_AXIS_KEY`.
|
|
382
|
+
*/
|
|
346
383
|
yAxis: _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
347
384
|
axisId: _propTypes.default.string,
|
|
348
385
|
classes: _propTypes.default.object,
|
package/BarChart/BarPlot.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BarElementProps } from './BarElement';
|
|
3
|
-
export interface
|
|
3
|
+
export interface BarPlotSlots {
|
|
4
4
|
bar?: React.JSXElementConstructor<BarElementProps>;
|
|
5
5
|
}
|
|
6
|
-
export interface
|
|
6
|
+
export interface BarPlotSlotProps {
|
|
7
7
|
bar?: Partial<BarElementProps>;
|
|
8
8
|
}
|
|
9
9
|
export interface BarPlotProps extends Pick<BarElementProps, 'slots' | 'slotProps'> {
|
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,213 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## 7.0.0-alpha.0
|
|
7
|
+
|
|
8
|
+
_Nov 10, 2023_
|
|
9
|
+
|
|
10
|
+
We're thrilled to announce the first alpha release of our next major version, v7.
|
|
11
|
+
This release introduces a few breaking changes, paving the way for the upcoming features like Pivoting and DateTimeRangePicker.
|
|
12
|
+
|
|
13
|
+
A special shoutout to thank the 12 contributors who made this release possible. Here are some highlights ✨:
|
|
14
|
+
|
|
15
|
+
- 🚀 First v7 alpha release
|
|
16
|
+
- ✨ Fix aggregation label not showing when `renderHeader` is used (#10961) @cherniavskii
|
|
17
|
+
- 📘 Server side data source [early documentation](https://mui.com/x/react-data-grid/server-side-data/)
|
|
18
|
+
- 💫 New recipes added for the data grid
|
|
19
|
+
- 📈 `<ChartsReferenceLine />` component is now available
|
|
20
|
+
- 🌍 Add Basque (eu) locale, improve Czech (cs-CZ) and Spanish (es-ES) locales
|
|
21
|
+
- 🐞 Bugfixes
|
|
22
|
+
- 📚 Documentation improvements
|
|
23
|
+
|
|
24
|
+
### Data Grid
|
|
25
|
+
|
|
26
|
+
#### Breaking changes
|
|
27
|
+
|
|
28
|
+
- The deprecated `components` and `componentsProps` props have been removed. Use `slots` and `slotProps` instead. See [components section](/x/react-data-grid/components/) for more details.
|
|
29
|
+
- The print export will now only print the selected rows if there are any.
|
|
30
|
+
If there are no selected rows, it will print all rows. This makes the print export consistent with the other exports.
|
|
31
|
+
You can [customize the rows to export by using the `getRowsToExport` function](/x/react-data-grid/export/#customizing-the-rows-to-export).
|
|
32
|
+
- The `getApplyFilterFnV7` in `GridFilterOperator` was renamed to `getApplyFilterFn`.
|
|
33
|
+
If you use `getApplyFilterFnV7` directly - rename it to `getApplyFilterFn`.
|
|
34
|
+
- The signature of the function returned by `getApplyFilterFn` has changed for performance reasons:
|
|
35
|
+
|
|
36
|
+
```diff
|
|
37
|
+
const getApplyFilterFn: GetApplyFilterFn<any, unknown> = (filterItem) => {
|
|
38
|
+
if (!filterItem.value) {
|
|
39
|
+
return null;
|
|
40
|
+
}
|
|
41
|
+
const filterRegex = new RegExp(escapeRegExp(filterItem.value), 'i');
|
|
42
|
+
- return (cellParams) => {
|
|
43
|
+
- const { value } = cellParams;
|
|
44
|
+
+ return (value, row, colDef, apiRef) => {
|
|
45
|
+
return value != null ? filterRegex.test(String(value)) : false;
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
- The `getApplyQuickFilterFnV7` in `GridColDef` was renamed to `getApplyQuickFilterFn`.
|
|
51
|
+
If you use `getApplyQuickFilterFnV7` directly - rename it to `getApplyQuickFilterFn`.
|
|
52
|
+
- The signature of the function returned by `getApplyQuickFilterFn` has changed for performance reasons:
|
|
53
|
+
|
|
54
|
+
```diff
|
|
55
|
+
const getGridStringQuickFilterFn: GetApplyQuickFilterFn<any, unknown> = (value) => {
|
|
56
|
+
if (!value) {
|
|
57
|
+
return null;
|
|
58
|
+
}
|
|
59
|
+
const filterRegex = new RegExp(escapeRegExp(value), 'i');
|
|
60
|
+
- return (cellParams) => {
|
|
61
|
+
- const { formattedValue } = cellParams;
|
|
62
|
+
+ return (value, row, column, apiRef) => {
|
|
63
|
+
+ let formattedValue = apiRef.current.getRowFormattedValue(row, column);
|
|
64
|
+
return formattedValue != null ? filterRegex.test(formattedValue.toString()) : false;
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
#### `@mui/x-data-grid@7.0.0-alpha.0`
|
|
70
|
+
|
|
71
|
+
- [DataGrid] Fix for error thrown when removing skeleton rows, after sorting is applied (#10807) @benjaminbialy
|
|
72
|
+
- [DataGrid] Fix: `undefined` slot value (#10937) @romgrk
|
|
73
|
+
- [DataGrid] Print selected rows by default (#10846) @cherniavskii
|
|
74
|
+
- [DataGrid] Remove deprecated `components` and `componentsProps` (#10911) @MBilalShafi
|
|
75
|
+
- [DataGrid] Remove legacy filtering API (#10897) @cherniavskii
|
|
76
|
+
- [DataGrid] Fix keyboard navigation for actions cell with disabled buttons (#10882) @michelengelen
|
|
77
|
+
- [DataGrid] Added a recipe for using non-native select in filter panel (#10916) @michelengelen
|
|
78
|
+
- [DataGrid] Added a recipe to style cells without impacting the aggregation cells (#10913) @michelengelen
|
|
79
|
+
- [l10n] Improve Czech (cs-CZ) locale (#10949) @luborepka
|
|
80
|
+
|
|
81
|
+
#### `@mui/x-data-grid-pro@7.0.0-alpha.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
82
|
+
|
|
83
|
+
Same changes as in `@mui/x-data-grid@7.0.0-alpha.0`, plus:
|
|
84
|
+
|
|
85
|
+
- [DataGridPro] Autosize Columns - Fix headers being cut off (#10666) @gitstart
|
|
86
|
+
- [DataGridPro] Add data source interface and basic documentation (#10543) @MBilalShafi
|
|
87
|
+
|
|
88
|
+
#### `@mui/x-data-grid-premium@7.0.0-alpha.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
89
|
+
|
|
90
|
+
Same changes as in `@mui/x-data-grid-pro@7.0.0-alpha.0`, plus:
|
|
91
|
+
|
|
92
|
+
- [DataGridPremium] Render aggregation label when `renderHeader` is used (#10936) @cherniavskii
|
|
93
|
+
|
|
94
|
+
### Date Pickers
|
|
95
|
+
|
|
96
|
+
#### Breaking changes
|
|
97
|
+
|
|
98
|
+
- The deprecated `components` and `componentsProps` props have been removed. Use `slots` and `slotProps` instead.
|
|
99
|
+
|
|
100
|
+
#### `@mui/x-date-pickers@7.0.0-alpha.0`
|
|
101
|
+
|
|
102
|
+
- [pickers] Escape non tokens words (#10400) @alexfauquette
|
|
103
|
+
- [fields] Fix `MultiInputTimeRangeField` section selection (#10922) @noraleonte
|
|
104
|
+
- [pickers] Refine `referenceDate` behavior in views (#10863) @LukasTy
|
|
105
|
+
- [pickers] Remove `components` and `componentsProps` props (#10700) @alexfauquette
|
|
106
|
+
- [l10n] Add Basque (eu) locale and improve Spanish (es-ES) locale (#10819) @lajtomekadimon
|
|
107
|
+
- [pickers] Add short weekdays token (#10988) @alexfauquette
|
|
108
|
+
|
|
109
|
+
#### `@mui/x-date-pickers-pro@7.0.0-alpha.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
110
|
+
|
|
111
|
+
Same changes as in `@mui/x-date-pickers@7.0.0-alpha.0`.
|
|
112
|
+
|
|
113
|
+
### Charts / `@mui/x-charts@7.0.0-alpha.0`
|
|
114
|
+
|
|
115
|
+
#### Breaking changes
|
|
116
|
+
|
|
117
|
+
Types for `slots` and `slotProps` got renamed by removing the "Component" which is meaningless for charts.
|
|
118
|
+
Unless you imported those types, to create a wrapper, you should not be impacted by this breaking change.
|
|
119
|
+
|
|
120
|
+
Here is an example of the renaming for the `<ChartsTooltip />` component.
|
|
121
|
+
|
|
122
|
+
```diff
|
|
123
|
+
-ChartsTooltipSlotsComponent
|
|
124
|
+
+ChartsTooltipSlots
|
|
125
|
+
|
|
126
|
+
-ChartsTooltipSlotComponentProps
|
|
127
|
+
+ChartsTooltipSlotProps
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
- [charts] Add `<ChartsReferenceLine />` component (#10597) (#10946) @alexfauquette
|
|
131
|
+
- [charts] Improve properties JSDoc (#10931) (#10955) @alexfauquette
|
|
132
|
+
- [charts] Rename `slots` and `slotProps` types (#10875) @alexfauquette
|
|
133
|
+
|
|
134
|
+
### `@mui/x-codemod@7.0.0-alpha.0`
|
|
135
|
+
|
|
136
|
+
- [codemod] Add `v7.0.0/preset-safe` (#10973) @LukasTy
|
|
137
|
+
|
|
138
|
+
### Docs
|
|
139
|
+
|
|
140
|
+
- [docs] Add `@next` tag to the installation instructions (#10963) @MBilalShafi
|
|
141
|
+
- [docs] Document how to hide the legend (#10951) @alexfauquette
|
|
142
|
+
- [docs] Fix typo in the migration guide (#10972) @flaviendelangle
|
|
143
|
+
|
|
144
|
+
### Core
|
|
145
|
+
|
|
146
|
+
- [core] Adds migration docs for charts, pickers and tree view (#10926) @michelengelen
|
|
147
|
+
- [core] Bump monorepo (#10959) @LukasTy
|
|
148
|
+
- [core] Changed prettier branch value to next (#10917) @michelengelen
|
|
149
|
+
- [core] Fix GitHub title tag consistency @oliviertassinari
|
|
150
|
+
- [core] Fixed wrong package names in migration docs (#10953) @michelengelen
|
|
151
|
+
- [core] Merge `master` into `next` (#10929) @cherniavskii
|
|
152
|
+
- [core] Update release instructions as per v7 configuration (#10962) @MBilalShafi
|
|
153
|
+
- [license] Correctly throw errors (#10924) @oliviertassinari
|
|
154
|
+
|
|
155
|
+
## 6.18.1
|
|
156
|
+
|
|
157
|
+
_Nov 9, 2023_
|
|
158
|
+
|
|
159
|
+
We'd like to offer a big thanks to the 9 contributors who made this release possible. Here are some highlights ✨:
|
|
160
|
+
|
|
161
|
+
- ✨ Fix aggregation label not showing when `renderHeader` is used (#10961) @cherniavskii
|
|
162
|
+
- 📘 Server side data source [early documentation](https://mui.com/x/react-data-grid/server-side-data/) published
|
|
163
|
+
- 📈 `<ChartsReferenceLine />` component is now available
|
|
164
|
+
- 🐞 Bugfixes
|
|
165
|
+
- 📚 Documentation improvements
|
|
166
|
+
|
|
167
|
+
### Data Grid
|
|
168
|
+
|
|
169
|
+
#### `@mui/x-data-grid@6.18.1`
|
|
170
|
+
|
|
171
|
+
- [DataGrid] Fix cell value type in quick filtering v7 (#10884) @cherniavskii
|
|
172
|
+
- [DataGrid] Fix keyboard navigation for actions cell with disabled buttons (#10947) @michelengelen
|
|
173
|
+
- [DataGrid] Fix `undefined` slot values (#10934) @romgrk
|
|
174
|
+
|
|
175
|
+
#### `@mui/x-data-grid-pro@6.18.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
176
|
+
|
|
177
|
+
Same changes as in `@mui/x-data-grid@6.18.1`, plus:
|
|
178
|
+
|
|
179
|
+
- [DataGridPro] Add data source interface and basic documentation (#10543) @MBilalShafi
|
|
180
|
+
|
|
181
|
+
#### `@mui/x-data-grid-premium@6.18.1` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
182
|
+
|
|
183
|
+
Same changes as in `@mui/x-data-grid-pro@6.18.1`, plus:
|
|
184
|
+
|
|
185
|
+
- [DataGridPremium] Render aggregation label when `renderHeader` is used (#10961) @cherniavskii
|
|
186
|
+
|
|
187
|
+
### Date Pickers
|
|
188
|
+
|
|
189
|
+
#### `@mui/x-date-pickers@6.18.1`
|
|
190
|
+
|
|
191
|
+
- [fields] Fix multi input date time field section selection (#10915) @noraleonte
|
|
192
|
+
- [pickers] Always use up-to-date `defaultView` (#10889) @LukasTy
|
|
193
|
+
|
|
194
|
+
#### `@mui/x-date-pickers-pro@6.18.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
195
|
+
|
|
196
|
+
Same changes as in `@mui/x-date-pickers@6.18.1`.
|
|
197
|
+
|
|
198
|
+
### Charts / `@mui/x-charts@6.18.1`
|
|
199
|
+
|
|
200
|
+
- [charts] Add `<ChartsReferenceLine />` component (#10597) @wascou
|
|
201
|
+
- [charts] Improve properties JSDoc (#10931) @alexfauquette
|
|
202
|
+
|
|
203
|
+
### Docs
|
|
204
|
+
|
|
205
|
+
- [docs] Fix charts docs as stable (#10888) @alexfauquette
|
|
206
|
+
- [docs] Document how to hide the legend (#10954) @alexfauquette
|
|
207
|
+
|
|
208
|
+
### Core
|
|
209
|
+
|
|
210
|
+
- [core] Adds new alpha version to version select on the docs (#10944) @michelengelen
|
|
211
|
+
- [core] Fix GitHub title tag consistency @oliviertassinari
|
|
212
|
+
|
|
6
213
|
## 6.18.0
|
|
7
214
|
|
|
8
215
|
_Nov 3, 2023_
|
|
@@ -357,7 +564,7 @@ Same changes as in `@mui/x-date-pickers@6.16.1`, plus:
|
|
|
357
564
|
|
|
358
565
|
- [core] Fix casing consistency with legal and marketing content @oliviertassinari
|
|
359
566
|
- [core] Revert the link in the priority support ticket description (#10517) @michelengelen
|
|
360
|
-
- [
|
|
567
|
+
- [changelog] Polish image @oliviertassinari
|
|
361
568
|
|
|
362
569
|
## 6.16.0
|
|
363
570
|
|
|
@@ -1149,7 +1356,7 @@ Same changes as in `@mui/x-date-pickers@6.10.1`.
|
|
|
1149
1356
|
### Core
|
|
1150
1357
|
|
|
1151
1358
|
- [core] Add `validate` command (#9714) @romgrk
|
|
1152
|
-
- [
|
|
1359
|
+
- [changelog] Update generator to new format @oliviertassinari
|
|
1153
1360
|
|
|
1154
1361
|
## 6.10.0
|
|
1155
1362
|
|
|
@@ -1207,7 +1414,7 @@ Same changes as in `@mui/x-date-pickers@6.10.0`.
|
|
|
1207
1414
|
|
|
1208
1415
|
- [core] Disambiguate eslint plugin name @oliviertassinari
|
|
1209
1416
|
- [core] Update priority support issue template and prompt (#9574) @DanailH
|
|
1210
|
-
- [
|
|
1417
|
+
- [changelog] Clarify each plan (#9446) @oliviertassinari
|
|
1211
1418
|
- [license] Fix error terminology (#9614) @oliviertassinari
|
|
1212
1419
|
|
|
1213
1420
|
## 6.9.2
|
|
@@ -1356,8 +1563,8 @@ Same changes as in `@mui/x-date-pickers@6.9.1`.
|
|
|
1356
1563
|
- [core] Fix priority support prompt action (#9472) @DanailH
|
|
1357
1564
|
- [core] Update `uses` for priority support action (#9480) @DanailH
|
|
1358
1565
|
- [core] Bumb update monorepo (#9476) @alexfauquette
|
|
1359
|
-
- [
|
|
1360
|
-
- [
|
|
1566
|
+
- [changelog] Fix media quality (#9439) @oliviertassinari
|
|
1567
|
+
- [changelog] Remove height img attribute @oliviertassinari
|
|
1361
1568
|
- [test] Skip flaky row pinning tests in JSDOM (#9511) @cherniavskii
|
|
1362
1569
|
|
|
1363
1570
|
## 6.9.0
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { ChartsAxisSlotProps, ChartsAxisSlots, ChartsXAxisProps, ChartsYAxisProps } from '../models/axis';
|
|
3
3
|
export interface ChartsAxisProps {
|
|
4
4
|
/**
|
|
5
5
|
* Indicate which axis to display the top of the charts.
|
|
@@ -29,12 +29,12 @@ export interface ChartsAxisProps {
|
|
|
29
29
|
* Overridable component slots.
|
|
30
30
|
* @default {}
|
|
31
31
|
*/
|
|
32
|
-
slots?:
|
|
32
|
+
slots?: ChartsAxisSlots;
|
|
33
33
|
/**
|
|
34
34
|
* The props used for each component slot.
|
|
35
35
|
* @default {}
|
|
36
36
|
*/
|
|
37
|
-
slotProps?:
|
|
37
|
+
slotProps?: ChartsAxisSlotProps;
|
|
38
38
|
}
|
|
39
39
|
/**
|
|
40
40
|
* Demos:
|
package/ChartsAxis/ChartsAxis.js
CHANGED
|
@@ -19,7 +19,7 @@ const getAxisId = propsValue => {
|
|
|
19
19
|
return null;
|
|
20
20
|
}
|
|
21
21
|
if (typeof propsValue === 'object') {
|
|
22
|
-
return propsValue.axisId;
|
|
22
|
+
return propsValue.axisId ?? null;
|
|
23
23
|
}
|
|
24
24
|
return propsValue;
|
|
25
25
|
};
|
|
@@ -108,7 +108,7 @@ process.env.NODE_ENV !== "production" ? ChartsAxis.propTypes = {
|
|
|
108
108
|
* @default xAxisIds[0] The id of the first provided axis
|
|
109
109
|
*/
|
|
110
110
|
bottomAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
111
|
-
axisId: _propTypes.default.string
|
|
111
|
+
axisId: _propTypes.default.string,
|
|
112
112
|
classes: _propTypes.default.object,
|
|
113
113
|
disableLine: _propTypes.default.bool,
|
|
114
114
|
disableTicks: _propTypes.default.bool,
|
|
@@ -135,7 +135,7 @@ process.env.NODE_ENV !== "production" ? ChartsAxis.propTypes = {
|
|
|
135
135
|
* @default yAxisIds[0] The id of the first provided axis
|
|
136
136
|
*/
|
|
137
137
|
leftAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
138
|
-
axisId: _propTypes.default.string
|
|
138
|
+
axisId: _propTypes.default.string,
|
|
139
139
|
classes: _propTypes.default.object,
|
|
140
140
|
disableLine: _propTypes.default.bool,
|
|
141
141
|
disableTicks: _propTypes.default.bool,
|
|
@@ -162,7 +162,7 @@ process.env.NODE_ENV !== "production" ? ChartsAxis.propTypes = {
|
|
|
162
162
|
* @default null
|
|
163
163
|
*/
|
|
164
164
|
rightAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
165
|
-
axisId: _propTypes.default.string
|
|
165
|
+
axisId: _propTypes.default.string,
|
|
166
166
|
classes: _propTypes.default.object,
|
|
167
167
|
disableLine: _propTypes.default.bool,
|
|
168
168
|
disableTicks: _propTypes.default.bool,
|
|
@@ -199,7 +199,7 @@ process.env.NODE_ENV !== "production" ? ChartsAxis.propTypes = {
|
|
|
199
199
|
* @default null
|
|
200
200
|
*/
|
|
201
201
|
topAxis: _propTypes.default.oneOfType([_propTypes.default.shape({
|
|
202
|
-
axisId: _propTypes.default.string
|
|
202
|
+
axisId: _propTypes.default.string,
|
|
203
203
|
classes: _propTypes.default.object,
|
|
204
204
|
disableLine: _propTypes.default.bool,
|
|
205
205
|
disableTicks: _propTypes.default.bool,
|
|
@@ -11,9 +11,9 @@ export interface ChartsAxisClasses {
|
|
|
11
11
|
tickLabel: string;
|
|
12
12
|
/** Styles applied to the group containing the axis label. */
|
|
13
13
|
label: string;
|
|
14
|
-
/** Styles applied to x
|
|
14
|
+
/** Styles applied to x-axes. */
|
|
15
15
|
directionX: string;
|
|
16
|
-
/** Styles applied to y
|
|
16
|
+
/** Styles applied to y-axes. */
|
|
17
17
|
directionY: string;
|
|
18
18
|
/** Styles applied to the top axis. */
|
|
19
19
|
top: string;
|
|
@@ -8,10 +8,10 @@ import { DefaultizedProps } from '../models/helpers';
|
|
|
8
8
|
import { LegendParams } from '../models/seriesType/config';
|
|
9
9
|
import { ChartsTextStyle } from '../internals/components/ChartsText';
|
|
10
10
|
import { CardinalDirections } from '../models/layout';
|
|
11
|
-
export interface
|
|
11
|
+
export interface ChartsLegendSlots {
|
|
12
12
|
legend?: React.JSXElementConstructor<LegendRendererProps>;
|
|
13
13
|
}
|
|
14
|
-
export interface
|
|
14
|
+
export interface ChartsLegendSlotProps {
|
|
15
15
|
legend?: Partial<LegendRendererProps>;
|
|
16
16
|
}
|
|
17
17
|
export type ChartsLegendProps = {
|
|
@@ -22,6 +22,7 @@ export type ChartsLegendProps = {
|
|
|
22
22
|
classes?: Partial<ChartsLegendClasses>;
|
|
23
23
|
/**
|
|
24
24
|
* Set to true to hide the legend.
|
|
25
|
+
* @default false
|
|
25
26
|
*/
|
|
26
27
|
hidden?: boolean;
|
|
27
28
|
/**
|
|
@@ -33,12 +34,12 @@ export type ChartsLegendProps = {
|
|
|
33
34
|
* Overridable component slots.
|
|
34
35
|
* @default {}
|
|
35
36
|
*/
|
|
36
|
-
slots?:
|
|
37
|
+
slots?: ChartsLegendSlots;
|
|
37
38
|
/**
|
|
38
39
|
* The props used for each component slot.
|
|
39
40
|
* @default {}
|
|
40
41
|
*/
|
|
41
|
-
slotProps?:
|
|
42
|
+
slotProps?: ChartsLegendSlotProps;
|
|
42
43
|
};
|
|
43
44
|
type DefaultizedChartsLegendProps = DefaultizedProps<ChartsLegendProps, 'direction' | 'position'>;
|
|
44
45
|
export type ChartsLegendRootOwnerState = {
|
|
@@ -87,5 +88,8 @@ export interface LegendRendererProps extends Omit<DefaultizedChartsLegendProps,
|
|
|
87
88
|
*/
|
|
88
89
|
padding?: number | Partial<CardinalDirections<number>>;
|
|
89
90
|
}
|
|
90
|
-
|
|
91
|
-
|
|
91
|
+
declare function ChartsLegend(inProps: ChartsLegendProps): React.JSX.Element;
|
|
92
|
+
declare namespace ChartsLegend {
|
|
93
|
+
var propTypes: any;
|
|
94
|
+
}
|
|
95
|
+
export { ChartsLegend };
|