@mui/x-charts 7.22.3 → 7.23.1
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 +160 -0
- package/ChartsTooltip/ChartsTooltipTable.js +1 -1
- package/PieChart/PieArc.js +11 -5
- package/PieChart/PieArcPlot.js +9 -13
- package/README.md +3 -3
- package/hooks/useInteractionItemProps.js +3 -1
- package/index.js +1 -1
- package/modern/ChartsTooltip/ChartsTooltipTable.js +1 -1
- package/modern/PieChart/PieArc.js +11 -5
- package/modern/PieChart/PieArcPlot.js +9 -13
- package/modern/hooks/useInteractionItemProps.js +3 -1
- package/modern/index.js +1 -1
- package/node/ChartsTooltip/ChartsTooltipTable.js +1 -1
- package/node/PieChart/PieArc.js +11 -5
- package/node/PieChart/PieArcPlot.js +9 -13
- package/node/hooks/useInteractionItemProps.js +3 -1
- package/node/index.js +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,166 @@
|
|
|
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.23.1
|
|
7
|
+
|
|
8
|
+
_Dec 5, 2024_
|
|
9
|
+
|
|
10
|
+
We'd like to offer a big thanks to the 7 contributors who made this release possible. Here are some highlights ✨:
|
|
11
|
+
|
|
12
|
+
- 🌍 Improve German locale on the Data Grid component
|
|
13
|
+
- 🐞 Bugfixes
|
|
14
|
+
|
|
15
|
+
Special thanks go out to the community contributors who have helped make this release possible:
|
|
16
|
+
@lhilgert9.
|
|
17
|
+
|
|
18
|
+
Following are all team members who have contributed to this release:
|
|
19
|
+
@arthurbalduini, @cherniavskii, @flaviendelangle, @JCQuintas, @LukasTy and @MBilalShafi.
|
|
20
|
+
|
|
21
|
+
<!--/ HIGHLIGHT_ABOVE_SEPARATOR /-->
|
|
22
|
+
|
|
23
|
+
### Data Grid
|
|
24
|
+
|
|
25
|
+
#### `@mui/x-data-grid@7.23.1`
|
|
26
|
+
|
|
27
|
+
- [DataGrid] Make column autosizing work with flex columns (#15712) @cherniavskii
|
|
28
|
+
- [l10n] Improve German (de-DE) locale (#15641) @lhilgert9
|
|
29
|
+
|
|
30
|
+
#### `@mui/x-data-grid-pro@7.23.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
31
|
+
|
|
32
|
+
Same changes as in `@mui/x-data-grid@7.23.1`, plus:
|
|
33
|
+
|
|
34
|
+
- [DataGridPro] Cleanup pinned rows on removal (#15702) @cherniavskii
|
|
35
|
+
|
|
36
|
+
#### `@mui/x-data-grid-premium@7.23.1` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
37
|
+
|
|
38
|
+
Same changes as in `@mui/x-data-grid-pro@7.23.1`.
|
|
39
|
+
|
|
40
|
+
### Date and Time Pickers
|
|
41
|
+
|
|
42
|
+
#### `@mui/x-date-pickers@7.23.1`
|
|
43
|
+
|
|
44
|
+
- [TimePicker] Prevent mouse events after `touchend` event (#15430) @arthurbalduini
|
|
45
|
+
|
|
46
|
+
#### `@mui/x-date-pickers-pro@7.23.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
47
|
+
|
|
48
|
+
Same changes as in `@mui/x-date-pickers@7.23.1`.
|
|
49
|
+
|
|
50
|
+
### Charts
|
|
51
|
+
|
|
52
|
+
#### `@mui/x-charts@7.23.1`
|
|
53
|
+
|
|
54
|
+
- [charts] Improve SVG `pattern` and `gradient` support (#15724) @JCQuintas
|
|
55
|
+
|
|
56
|
+
#### `@mui/x-charts-pro@7.23.1` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
57
|
+
|
|
58
|
+
Same changes as in `@mui/x-charts@7.23.1`.
|
|
59
|
+
|
|
60
|
+
### Docs
|
|
61
|
+
|
|
62
|
+
- [docs] Fix Pickers theme augmentation example (#15675) @LukasTy
|
|
63
|
+
- [docs] Remove duplicated warning (#15715) @cherniavskii
|
|
64
|
+
- [test] Force hover in headless Chrome (#15711) @cherniavskii
|
|
65
|
+
- [docs-infra] Bump `@mui/internal-markdown` to support nested demo imports (#15738) @alexfauquette
|
|
66
|
+
- [docs] Improve SEO titles for the Data Grid (#15695) @MBilalShafi
|
|
67
|
+
|
|
68
|
+
### Core
|
|
69
|
+
|
|
70
|
+
- [core] Add `@mui/x-tree-view-pro` to `releaseChangelog` (#15747) @flaviendelangle
|
|
71
|
+
|
|
72
|
+
## 7.23.0
|
|
73
|
+
|
|
74
|
+
_Nov 29, 2024_
|
|
75
|
+
|
|
76
|
+
We'd like to offer a big thanks to the 10 contributors who made this release possible. Here are some highlights ✨:
|
|
77
|
+
|
|
78
|
+
- ✨ Support for a new display mode on the Data Grid with the [List View feature](https://mui.com/x/react-data-grid/list-view/), offering an extremely flexible way to render datasets and enabling developers to adapt how data is displayed across different screen sizes.
|
|
79
|
+
|
|
80
|
+
https://github.com/user-attachments/assets/61286adc-03fc-4323-9739-8ca726fcc16c
|
|
81
|
+
|
|
82
|
+
- ⚛️ React 19 support
|
|
83
|
+
- 📚 Documentation improvements
|
|
84
|
+
- 🌍 Improve Spanish, Portuguese, Chinese locales on the Data Grid component.
|
|
85
|
+
- 🌍 Improve Dutch locale on the Date and Time Picker components.
|
|
86
|
+
- 🐞 Bugfixes
|
|
87
|
+
|
|
88
|
+
Special thanks go out to the community contributors who have helped make this release possible:
|
|
89
|
+
@dloeda, @headironc, @mathzdev, @nphmuller, @lhilgert9, @lauri865.
|
|
90
|
+
Following are all team members who have contributed to this release:
|
|
91
|
+
@oliviertassinari, @arminmeh, @KenanYusuf, @flaviendelangle, @MBilalShafi.
|
|
92
|
+
|
|
93
|
+
<!--/ HIGHLIGHT_ABOVE_SEPARATOR /-->
|
|
94
|
+
|
|
95
|
+
### Data Grid
|
|
96
|
+
|
|
97
|
+
#### `@mui/x-data-grid@v7.23.0`
|
|
98
|
+
|
|
99
|
+
- [DataGrid] React 19 support (#15557) @arminmeh
|
|
100
|
+
- [DataGrid] Change test dom check from `/jsdom/` to `/jsdom|HappyDOM/`. (#15642) @jedesroches
|
|
101
|
+
- [DataGrid] Fix last separator not being hidden when grid is scrollable (#15551) @KenanYusuf
|
|
102
|
+
- [DataGrid] Fix order of spread props on toolbar items (#15556) @KenanYusuf
|
|
103
|
+
- [DataGrid] Fix row-spanning in combination with column-pinning (#15460) @lhilgert9
|
|
104
|
+
- [DataGrid] Improve resize performance (#15592) @lauri865
|
|
105
|
+
- [DataGrid] Support column virtualization with dynamic row height (#15567) @cherniavskii
|
|
106
|
+
- [DataGrid] Improve `GridCell` performance (#15621) @lauri865
|
|
107
|
+
- [l10n] Improve Chinese (zh-CN) locale (#15570) @headironc
|
|
108
|
+
- [l10n] Improve Portuguese (pt-PT) locale (#15561) @mathzdev
|
|
109
|
+
|
|
110
|
+
#### `@mui/x-data-grid-pro@v7.23.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
111
|
+
|
|
112
|
+
Same changes as in `@mui/x-data-grid@v7.23.0`, plus:
|
|
113
|
+
|
|
114
|
+
- [DataGridPro] Fix header filtering with `boolean` column type (#15640) @k-rajat19
|
|
115
|
+
- [DataGridPro] Fix pagination state not updating if the data source response has no rows (#15643) @zinoroman
|
|
116
|
+
- [DataGridPro] Fix selection propagation issue on initialization (#15593) @MBilalShafi
|
|
117
|
+
|
|
118
|
+
#### `@mui/x-data-grid-premium@v7.23.0` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
119
|
+
|
|
120
|
+
Same changes as in `@mui/x-data-grid-pro@v7.23.0`.
|
|
121
|
+
|
|
122
|
+
### Date and Time Pickers
|
|
123
|
+
|
|
124
|
+
#### `@mui/x-date-pickers@v7.23.0`
|
|
125
|
+
|
|
126
|
+
- [pickers] React 19 support (#15557) @arminmeh
|
|
127
|
+
- [pickers] Fix DST issue with `America/Asuncion` timezone and `AdapterMoment` (#15653) @flaviendelangle
|
|
128
|
+
- [pickers] Use `props.referenceDate` timezone when `props.value` and `props.defaultValue` are not defined (#15544) @flaviendelangle
|
|
129
|
+
- [l10n] Improve Dutch (nl-NL) locale (#15564) @nphmuller
|
|
130
|
+
|
|
131
|
+
#### `@mui/x-date-pickers-pro@v7.23.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
132
|
+
|
|
133
|
+
Same changes as in `@mui/x-date-pickers@v7.23.0`.
|
|
134
|
+
|
|
135
|
+
### Charts
|
|
136
|
+
|
|
137
|
+
#### `@mui/x-charts@v7.23.0`
|
|
138
|
+
|
|
139
|
+
- [charts] React 19 support (#15557) @arminmeh
|
|
140
|
+
- [charts] Prevent invalid `releasePointerCapture` (#15609) @alexfauquette
|
|
141
|
+
|
|
142
|
+
#### `@mui/x-charts-pro@v7.23.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
143
|
+
|
|
144
|
+
Same changes as in `@mui/x-charts@v7.23.0`.
|
|
145
|
+
|
|
146
|
+
### Tree View
|
|
147
|
+
|
|
148
|
+
#### `@mui/x-tree-view@v7.23.0`
|
|
149
|
+
|
|
150
|
+
- [TreeView] React 19 support (#15557) @arminmeh
|
|
151
|
+
|
|
152
|
+
#### `@mui/x-tree-view-pro@7.23.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
153
|
+
|
|
154
|
+
Same changes as in `@mui/x-tree-view@7.23.0`.
|
|
155
|
+
|
|
156
|
+
### Docs
|
|
157
|
+
|
|
158
|
+
- [docs] Add data caching to lazy loaded detail panel demo (#15555) @cherniavskii
|
|
159
|
+
- [docs] Remove selectors section from list view docs (#15639) @KenanYusuf
|
|
160
|
+
- [docs] Add documentation for the list view feature (#15344) @KenanYusuf
|
|
161
|
+
|
|
162
|
+
### Core
|
|
163
|
+
|
|
164
|
+
- [core] Update @mui/monorepo (#15574) @oliviertassinari
|
|
165
|
+
|
|
6
166
|
## 7.22.3
|
|
7
167
|
|
|
8
168
|
_Nov 21, 2024_
|
|
@@ -96,7 +96,7 @@ export const ChartsTooltipMark = styled('div', {
|
|
|
96
96
|
height: theme.spacing(1),
|
|
97
97
|
borderRadius: '50%',
|
|
98
98
|
boxShadow: theme.shadows[1],
|
|
99
|
-
|
|
99
|
+
background: color,
|
|
100
100
|
borderColor: (theme.vars || theme).palette.background.paper,
|
|
101
101
|
border: `solid ${(theme.vars || theme).palette.background.paper} ${theme.spacing(0.25)}`,
|
|
102
102
|
boxSizing: 'content-box'
|
package/PieChart/PieArc.js
CHANGED
|
@@ -22,10 +22,11 @@ const useUtilityClasses = ownerState => {
|
|
|
22
22
|
classes,
|
|
23
23
|
id,
|
|
24
24
|
isFaded,
|
|
25
|
-
isHighlighted
|
|
25
|
+
isHighlighted,
|
|
26
|
+
dataIndex
|
|
26
27
|
} = ownerState;
|
|
27
28
|
const slots = {
|
|
28
|
-
root: ['root', `series-${id}`, isHighlighted && 'highlighted', isFaded && 'faded']
|
|
29
|
+
root: ['root', `series-${id}`, `data-index-${dataIndex}`, isHighlighted && 'highlighted', isFaded && 'faded']
|
|
29
30
|
};
|
|
30
31
|
return composeClasses(slots, getPieArcUtilityClass, classes);
|
|
31
32
|
};
|
|
@@ -36,9 +37,9 @@ const PieArcRoot = styled(animated.path, {
|
|
|
36
37
|
})(({
|
|
37
38
|
theme
|
|
38
39
|
}) => ({
|
|
40
|
+
// Got to move stroke to an element prop instead of style.
|
|
39
41
|
stroke: (theme.vars || theme).palette.background.paper,
|
|
40
|
-
|
|
41
|
-
strokeLinejoin: 'round'
|
|
42
|
+
transition: 'opacity 0.2s ease-in, fill 0.2s ease-in, filter 0.2s ease-in'
|
|
42
43
|
}));
|
|
43
44
|
function PieArc(props) {
|
|
44
45
|
const {
|
|
@@ -79,7 +80,12 @@ function PieArc(props) {
|
|
|
79
80
|
onClick: onClick,
|
|
80
81
|
cursor: onClick ? 'pointer' : 'unset',
|
|
81
82
|
ownerState: ownerState,
|
|
82
|
-
className: classes.root
|
|
83
|
+
className: classes.root,
|
|
84
|
+
fill: ownerState.color,
|
|
85
|
+
opacity: ownerState.isFaded ? 0.3 : 1,
|
|
86
|
+
filter: ownerState.isHighlighted ? 'brightness(120%)' : 'none',
|
|
87
|
+
strokeWidth: 1,
|
|
88
|
+
strokeLinejoin: "round"
|
|
83
89
|
}, other, getInteractionItemProps({
|
|
84
90
|
type: 'pie',
|
|
85
91
|
seriesId: id,
|
package/PieChart/PieArcPlot.js
CHANGED
|
@@ -2,8 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
5
|
-
const _excluded = ["slots", "slotProps", "innerRadius", "outerRadius", "cornerRadius", "paddingAngle", "id", "highlighted", "faded", "data", "onItemClick", "skipAnimation"]
|
|
6
|
-
_excluded2 = ["startAngle", "endAngle", "paddingAngle", "innerRadius", "arcLabelRadius", "outerRadius", "cornerRadius"];
|
|
5
|
+
const _excluded = ["slots", "slotProps", "innerRadius", "outerRadius", "cornerRadius", "paddingAngle", "id", "highlighted", "faded", "data", "onItemClick", "skipAnimation"];
|
|
7
6
|
import * as React from 'react';
|
|
8
7
|
import PropTypes from 'prop-types';
|
|
9
8
|
import { useTransition } from '@react-spring/web';
|
|
@@ -51,16 +50,14 @@ function PieArcPlot(props) {
|
|
|
51
50
|
}
|
|
52
51
|
const Arc = slots?.pieArc ?? PieArc;
|
|
53
52
|
return /*#__PURE__*/_jsx("g", _extends({}, other, {
|
|
54
|
-
children: transition((
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
} = _ref,
|
|
63
|
-
style = _objectWithoutPropertiesLoose(_ref, _excluded2);
|
|
53
|
+
children: transition(({
|
|
54
|
+
startAngle,
|
|
55
|
+
endAngle,
|
|
56
|
+
paddingAngle: pA,
|
|
57
|
+
innerRadius: iR,
|
|
58
|
+
outerRadius: oR,
|
|
59
|
+
cornerRadius: cR
|
|
60
|
+
}, item, _, index) => {
|
|
64
61
|
return /*#__PURE__*/_jsx(Arc, _extends({
|
|
65
62
|
startAngle: startAngle,
|
|
66
63
|
endAngle: endAngle,
|
|
@@ -68,7 +65,6 @@ function PieArcPlot(props) {
|
|
|
68
65
|
innerRadius: iR,
|
|
69
66
|
outerRadius: oR,
|
|
70
67
|
cornerRadius: cR,
|
|
71
|
-
style: style,
|
|
72
68
|
id: id,
|
|
73
69
|
color: item.color,
|
|
74
70
|
dataIndex: index,
|
package/README.md
CHANGED
|
@@ -15,9 +15,9 @@ This component has the following peer dependencies that you will need to install
|
|
|
15
15
|
|
|
16
16
|
```json
|
|
17
17
|
"peerDependencies": {
|
|
18
|
-
"@mui/material": "^5.15.14",
|
|
19
|
-
"react": "^17.0.0 || ^18.0.0",
|
|
20
|
-
"react-dom": "^17.0.0 || ^18.0.0"
|
|
18
|
+
"@mui/material": "^5.15.14 || ^6.0.0",
|
|
19
|
+
"react": "^17.0.0 || ^18.0.0 || ^19.0.0",
|
|
20
|
+
"react-dom": "^17.0.0 || ^18.0.0 || ^19.0.0"
|
|
21
21
|
},
|
|
22
22
|
```
|
|
23
23
|
|
|
@@ -31,7 +31,9 @@ export const useInteractionItemProps = skip => {
|
|
|
31
31
|
});
|
|
32
32
|
};
|
|
33
33
|
const onPointerLeave = event => {
|
|
34
|
-
event.currentTarget.
|
|
34
|
+
if (event.currentTarget.hasPointerCapture(event.pointerId)) {
|
|
35
|
+
event.currentTarget.releasePointerCapture(event.pointerId);
|
|
36
|
+
}
|
|
35
37
|
dispatchInteraction({
|
|
36
38
|
type: 'leaveItem',
|
|
37
39
|
data
|
package/index.js
CHANGED
|
@@ -96,7 +96,7 @@ export const ChartsTooltipMark = styled('div', {
|
|
|
96
96
|
height: theme.spacing(1),
|
|
97
97
|
borderRadius: '50%',
|
|
98
98
|
boxShadow: theme.shadows[1],
|
|
99
|
-
|
|
99
|
+
background: color,
|
|
100
100
|
borderColor: (theme.vars || theme).palette.background.paper,
|
|
101
101
|
border: `solid ${(theme.vars || theme).palette.background.paper} ${theme.spacing(0.25)}`,
|
|
102
102
|
boxSizing: 'content-box'
|
|
@@ -22,10 +22,11 @@ const useUtilityClasses = ownerState => {
|
|
|
22
22
|
classes,
|
|
23
23
|
id,
|
|
24
24
|
isFaded,
|
|
25
|
-
isHighlighted
|
|
25
|
+
isHighlighted,
|
|
26
|
+
dataIndex
|
|
26
27
|
} = ownerState;
|
|
27
28
|
const slots = {
|
|
28
|
-
root: ['root', `series-${id}`, isHighlighted && 'highlighted', isFaded && 'faded']
|
|
29
|
+
root: ['root', `series-${id}`, `data-index-${dataIndex}`, isHighlighted && 'highlighted', isFaded && 'faded']
|
|
29
30
|
};
|
|
30
31
|
return composeClasses(slots, getPieArcUtilityClass, classes);
|
|
31
32
|
};
|
|
@@ -36,9 +37,9 @@ const PieArcRoot = styled(animated.path, {
|
|
|
36
37
|
})(({
|
|
37
38
|
theme
|
|
38
39
|
}) => ({
|
|
40
|
+
// Got to move stroke to an element prop instead of style.
|
|
39
41
|
stroke: (theme.vars || theme).palette.background.paper,
|
|
40
|
-
|
|
41
|
-
strokeLinejoin: 'round'
|
|
42
|
+
transition: 'opacity 0.2s ease-in, fill 0.2s ease-in, filter 0.2s ease-in'
|
|
42
43
|
}));
|
|
43
44
|
function PieArc(props) {
|
|
44
45
|
const {
|
|
@@ -79,7 +80,12 @@ function PieArc(props) {
|
|
|
79
80
|
onClick: onClick,
|
|
80
81
|
cursor: onClick ? 'pointer' : 'unset',
|
|
81
82
|
ownerState: ownerState,
|
|
82
|
-
className: classes.root
|
|
83
|
+
className: classes.root,
|
|
84
|
+
fill: ownerState.color,
|
|
85
|
+
opacity: ownerState.isFaded ? 0.3 : 1,
|
|
86
|
+
filter: ownerState.isHighlighted ? 'brightness(120%)' : 'none',
|
|
87
|
+
strokeWidth: 1,
|
|
88
|
+
strokeLinejoin: "round"
|
|
83
89
|
}, other, getInteractionItemProps({
|
|
84
90
|
type: 'pie',
|
|
85
91
|
seriesId: id,
|
|
@@ -2,8 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
5
|
-
const _excluded = ["slots", "slotProps", "innerRadius", "outerRadius", "cornerRadius", "paddingAngle", "id", "highlighted", "faded", "data", "onItemClick", "skipAnimation"]
|
|
6
|
-
_excluded2 = ["startAngle", "endAngle", "paddingAngle", "innerRadius", "arcLabelRadius", "outerRadius", "cornerRadius"];
|
|
5
|
+
const _excluded = ["slots", "slotProps", "innerRadius", "outerRadius", "cornerRadius", "paddingAngle", "id", "highlighted", "faded", "data", "onItemClick", "skipAnimation"];
|
|
7
6
|
import * as React from 'react';
|
|
8
7
|
import PropTypes from 'prop-types';
|
|
9
8
|
import { useTransition } from '@react-spring/web';
|
|
@@ -51,16 +50,14 @@ function PieArcPlot(props) {
|
|
|
51
50
|
}
|
|
52
51
|
const Arc = slots?.pieArc ?? PieArc;
|
|
53
52
|
return /*#__PURE__*/_jsx("g", _extends({}, other, {
|
|
54
|
-
children: transition((
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
} = _ref,
|
|
63
|
-
style = _objectWithoutPropertiesLoose(_ref, _excluded2);
|
|
53
|
+
children: transition(({
|
|
54
|
+
startAngle,
|
|
55
|
+
endAngle,
|
|
56
|
+
paddingAngle: pA,
|
|
57
|
+
innerRadius: iR,
|
|
58
|
+
outerRadius: oR,
|
|
59
|
+
cornerRadius: cR
|
|
60
|
+
}, item, _, index) => {
|
|
64
61
|
return /*#__PURE__*/_jsx(Arc, _extends({
|
|
65
62
|
startAngle: startAngle,
|
|
66
63
|
endAngle: endAngle,
|
|
@@ -68,7 +65,6 @@ function PieArcPlot(props) {
|
|
|
68
65
|
innerRadius: iR,
|
|
69
66
|
outerRadius: oR,
|
|
70
67
|
cornerRadius: cR,
|
|
71
|
-
style: style,
|
|
72
68
|
id: id,
|
|
73
69
|
color: item.color,
|
|
74
70
|
dataIndex: index,
|
|
@@ -31,7 +31,9 @@ export const useInteractionItemProps = skip => {
|
|
|
31
31
|
});
|
|
32
32
|
};
|
|
33
33
|
const onPointerLeave = event => {
|
|
34
|
-
event.currentTarget.
|
|
34
|
+
if (event.currentTarget.hasPointerCapture(event.pointerId)) {
|
|
35
|
+
event.currentTarget.releasePointerCapture(event.pointerId);
|
|
36
|
+
}
|
|
35
37
|
dispatchInteraction({
|
|
36
38
|
type: 'leaveItem',
|
|
37
39
|
data
|
package/modern/index.js
CHANGED
|
@@ -101,7 +101,7 @@ const ChartsTooltipMark = exports.ChartsTooltipMark = (0, _styles.styled)('div',
|
|
|
101
101
|
height: theme.spacing(1),
|
|
102
102
|
borderRadius: '50%',
|
|
103
103
|
boxShadow: theme.shadows[1],
|
|
104
|
-
|
|
104
|
+
background: color,
|
|
105
105
|
borderColor: (theme.vars || theme).palette.background.paper,
|
|
106
106
|
border: `solid ${(theme.vars || theme).palette.background.paper} ${theme.spacing(0.25)}`,
|
|
107
107
|
boxSizing: 'content-box'
|
package/node/PieChart/PieArc.js
CHANGED
|
@@ -31,10 +31,11 @@ const useUtilityClasses = ownerState => {
|
|
|
31
31
|
classes,
|
|
32
32
|
id,
|
|
33
33
|
isFaded,
|
|
34
|
-
isHighlighted
|
|
34
|
+
isHighlighted,
|
|
35
|
+
dataIndex
|
|
35
36
|
} = ownerState;
|
|
36
37
|
const slots = {
|
|
37
|
-
root: ['root', `series-${id}`, isHighlighted && 'highlighted', isFaded && 'faded']
|
|
38
|
+
root: ['root', `series-${id}`, `data-index-${dataIndex}`, isHighlighted && 'highlighted', isFaded && 'faded']
|
|
38
39
|
};
|
|
39
40
|
return (0, _composeClasses.default)(slots, getPieArcUtilityClass, classes);
|
|
40
41
|
};
|
|
@@ -45,9 +46,9 @@ const PieArcRoot = (0, _styles.styled)(_web.animated.path, {
|
|
|
45
46
|
})(({
|
|
46
47
|
theme
|
|
47
48
|
}) => ({
|
|
49
|
+
// Got to move stroke to an element prop instead of style.
|
|
48
50
|
stroke: (theme.vars || theme).palette.background.paper,
|
|
49
|
-
|
|
50
|
-
strokeLinejoin: 'round'
|
|
51
|
+
transition: 'opacity 0.2s ease-in, fill 0.2s ease-in, filter 0.2s ease-in'
|
|
51
52
|
}));
|
|
52
53
|
function PieArc(props) {
|
|
53
54
|
const {
|
|
@@ -88,7 +89,12 @@ function PieArc(props) {
|
|
|
88
89
|
onClick: onClick,
|
|
89
90
|
cursor: onClick ? 'pointer' : 'unset',
|
|
90
91
|
ownerState: ownerState,
|
|
91
|
-
className: classes.root
|
|
92
|
+
className: classes.root,
|
|
93
|
+
fill: ownerState.color,
|
|
94
|
+
opacity: ownerState.isFaded ? 0.3 : 1,
|
|
95
|
+
filter: ownerState.isHighlighted ? 'brightness(120%)' : 'none',
|
|
96
|
+
strokeWidth: 1,
|
|
97
|
+
strokeLinejoin: "round"
|
|
92
98
|
}, other, getInteractionItemProps({
|
|
93
99
|
type: 'pie',
|
|
94
100
|
seriesId: id,
|
|
@@ -17,8 +17,7 @@ var _transition = require("./dataTransform/transition");
|
|
|
17
17
|
var _useTransformData = require("./dataTransform/useTransformData");
|
|
18
18
|
var _context = require("../context");
|
|
19
19
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
20
|
-
const _excluded = ["slots", "slotProps", "innerRadius", "outerRadius", "cornerRadius", "paddingAngle", "id", "highlighted", "faded", "data", "onItemClick", "skipAnimation"]
|
|
21
|
-
_excluded2 = ["startAngle", "endAngle", "paddingAngle", "innerRadius", "arcLabelRadius", "outerRadius", "cornerRadius"];
|
|
20
|
+
const _excluded = ["slots", "slotProps", "innerRadius", "outerRadius", "cornerRadius", "paddingAngle", "id", "highlighted", "faded", "data", "onItemClick", "skipAnimation"];
|
|
22
21
|
function PieArcPlot(props) {
|
|
23
22
|
const {
|
|
24
23
|
slots,
|
|
@@ -58,16 +57,14 @@ function PieArcPlot(props) {
|
|
|
58
57
|
}
|
|
59
58
|
const Arc = slots?.pieArc ?? _PieArc.PieArc;
|
|
60
59
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)("g", (0, _extends2.default)({}, other, {
|
|
61
|
-
children: transition((
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
} = _ref,
|
|
70
|
-
style = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded2);
|
|
60
|
+
children: transition(({
|
|
61
|
+
startAngle,
|
|
62
|
+
endAngle,
|
|
63
|
+
paddingAngle: pA,
|
|
64
|
+
innerRadius: iR,
|
|
65
|
+
outerRadius: oR,
|
|
66
|
+
cornerRadius: cR
|
|
67
|
+
}, item, _, index) => {
|
|
71
68
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Arc, (0, _extends2.default)({
|
|
72
69
|
startAngle: startAngle,
|
|
73
70
|
endAngle: endAngle,
|
|
@@ -75,7 +72,6 @@ function PieArcPlot(props) {
|
|
|
75
72
|
innerRadius: iR,
|
|
76
73
|
outerRadius: oR,
|
|
77
74
|
cornerRadius: cR,
|
|
78
|
-
style: style,
|
|
79
75
|
id: id,
|
|
80
76
|
color: item.color,
|
|
81
77
|
dataIndex: index,
|
|
@@ -37,7 +37,9 @@ const useInteractionItemProps = skip => {
|
|
|
37
37
|
});
|
|
38
38
|
};
|
|
39
39
|
const onPointerLeave = event => {
|
|
40
|
-
event.currentTarget.
|
|
40
|
+
if (event.currentTarget.hasPointerCapture(event.pointerId)) {
|
|
41
|
+
event.currentTarget.releasePointerCapture(event.pointerId);
|
|
42
|
+
}
|
|
41
43
|
dispatchInteraction({
|
|
42
44
|
type: 'leaveItem',
|
|
43
45
|
data
|
package/node/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/x-charts",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.23.1",
|
|
4
4
|
"description": "The community edition of the Charts components (MUI X).",
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"main": "./node/index.js",
|
|
@@ -36,15 +36,15 @@
|
|
|
36
36
|
"clsx": "^2.1.1",
|
|
37
37
|
"prop-types": "^15.8.1",
|
|
38
38
|
"@mui/x-charts-vendor": "7.20.0",
|
|
39
|
-
"@mui/x-internals": "7.
|
|
39
|
+
"@mui/x-internals": "7.23.0"
|
|
40
40
|
},
|
|
41
41
|
"peerDependencies": {
|
|
42
42
|
"@emotion/react": "^11.9.0",
|
|
43
43
|
"@emotion/styled": "^11.8.1",
|
|
44
44
|
"@mui/material": "^5.15.14 || ^6.0.0",
|
|
45
45
|
"@mui/system": "^5.15.14 || ^6.0.0",
|
|
46
|
-
"react": "^17.0.0 || ^18.0.0",
|
|
47
|
-
"react-dom": "^17.0.0 || ^18.0.0"
|
|
46
|
+
"react": "^17.0.0 || ^18.0.0 || ^19.0.0",
|
|
47
|
+
"react-dom": "^17.0.0 || ^18.0.0 || ^19.0.0"
|
|
48
48
|
},
|
|
49
49
|
"peerDependenciesMeta": {
|
|
50
50
|
"@emotion/react": {
|