@mui/x-charts-pro 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/BarChartPro/BarChartPro.d.mts +2 -2
- package/BarChartPro/BarChartPro.d.ts +2 -2
- package/BarChartPro/BarChartPro.js +38 -8
- package/BarChartPro/BarChartPro.mjs +38 -8
- package/CHANGELOG.md +123 -0
- package/ChartsContainerPro/ChartsContainerPro.js +2 -2
- package/ChartsContainerPro/ChartsContainerPro.mjs +2 -2
- package/ChartsContainerPro/useChartsContainerProProps.d.mts +2 -2
- package/ChartsContainerPro/useChartsContainerProProps.d.ts +2 -2
- package/ChartsContainerPro/useChartsContainerProProps.js +3 -3
- package/ChartsContainerPro/useChartsContainerProProps.mjs +3 -3
- package/ChartsDataProviderPro/ChartsDataProviderPro.js +2 -8
- package/ChartsDataProviderPro/ChartsDataProviderPro.mjs +2 -8
- package/ChartsToolbarPro/ChartsToolbarPro.js +1 -1
- package/ChartsToolbarPro/ChartsToolbarPro.mjs +2 -2
- package/ChartsToolbarPro/ChartsToolbarZoomInTrigger.js +1 -1
- package/ChartsToolbarPro/ChartsToolbarZoomInTrigger.mjs +2 -2
- package/ChartsToolbarPro/ChartsToolbarZoomOutTrigger.js +1 -1
- package/ChartsToolbarPro/ChartsToolbarZoomOutTrigger.mjs +2 -2
- package/ChartsToolbarPro/index.d.mts +2 -1
- package/ChartsToolbarPro/index.d.ts +2 -1
- package/ChartsToolbarPro/index.mjs +2 -1
- package/ChartsZoomSlider/internals/ChartsAxisZoomSliderActiveTrack.js +1 -1
- package/ChartsZoomSlider/internals/ChartsAxisZoomSliderActiveTrack.mjs +2 -2
- package/ChartsZoomSlider/internals/ChartsAxisZoomSliderTrack.js +1 -1
- package/ChartsZoomSlider/internals/ChartsAxisZoomSliderTrack.mjs +2 -2
- package/FunnelChart/FunnelChart.d.mts +2 -2
- package/FunnelChart/FunnelChart.d.ts +2 -2
- package/FunnelChart/FunnelChart.js +18 -6
- package/FunnelChart/FunnelChart.mjs +18 -6
- package/FunnelChart/FunnelPlot.js +8 -3
- package/FunnelChart/FunnelPlot.mjs +8 -3
- package/FunnelChart/FunnelSection.d.mts +3 -3
- package/FunnelChart/FunnelSection.d.ts +3 -3
- package/FunnelChart/FunnelSection.js +5 -5
- package/FunnelChart/FunnelSection.mjs +4 -4
- package/FunnelChart/FunnelSectionLabel.d.mts +9 -3
- package/FunnelChart/FunnelSectionLabel.d.ts +9 -3
- package/FunnelChart/FunnelSectionLabel.js +15 -6
- package/FunnelChart/FunnelSectionLabel.mjs +15 -6
- package/FunnelChart/funnelClasses.d.mts +29 -0
- package/FunnelChart/funnelClasses.d.ts +29 -0
- package/FunnelChart/funnelClasses.js +29 -0
- package/FunnelChart/funnelClasses.mjs +19 -0
- package/FunnelChart/index.d.mts +2 -2
- package/FunnelChart/index.d.ts +2 -2
- package/FunnelChart/index.js +4 -4
- package/FunnelChart/index.mjs +1 -1
- package/FunnelChart/seriesConfig/legend.js +0 -2
- package/FunnelChart/seriesConfig/legend.mjs +0 -2
- package/FunnelChart/useFunnelChartProps.d.mts +2 -2
- package/FunnelChart/useFunnelChartProps.d.ts +2 -2
- package/FunnelChart/useFunnelChartProps.js +2 -2
- package/FunnelChart/useFunnelChartProps.mjs +2 -2
- package/Heatmap/Heatmap.d.mts +2 -11
- package/Heatmap/Heatmap.d.ts +2 -11
- package/Heatmap/Heatmap.js +20 -15
- package/Heatmap/Heatmap.mjs +20 -15
- package/Heatmap/HeatmapCell.d.mts +33 -0
- package/Heatmap/HeatmapCell.d.ts +33 -0
- package/Heatmap/HeatmapCell.js +62 -0
- package/Heatmap/HeatmapCell.mjs +55 -0
- package/Heatmap/HeatmapItem.d.mts +1 -9
- package/Heatmap/HeatmapItem.d.ts +1 -9
- package/Heatmap/HeatmapItem.js +5 -22
- package/Heatmap/HeatmapItem.mjs +5 -22
- package/Heatmap/HeatmapSVGPlot.js +10 -3
- package/Heatmap/HeatmapSVGPlot.mjs +10 -3
- package/Heatmap/HeatmapTooltip/HeatmapTooltip.classes.js +2 -2
- package/Heatmap/HeatmapTooltip/HeatmapTooltip.classes.mjs +1 -1
- package/Heatmap/heatmapClasses.d.mts +6 -1
- package/Heatmap/heatmapClasses.d.ts +6 -1
- package/Heatmap/heatmapClasses.js +18 -3
- package/Heatmap/heatmapClasses.mjs +16 -2
- package/Heatmap/index.d.mts +4 -2
- package/Heatmap/index.d.ts +4 -2
- package/Heatmap/index.js +17 -13
- package/Heatmap/index.mjs +2 -1
- package/Heatmap/shouldRegisterPointerInteractionsGlobally.js +1 -1
- package/Heatmap/shouldRegisterPointerInteractionsGlobally.mjs +1 -1
- package/Heatmap/useHeatmapProps.d.mts +2 -2
- package/Heatmap/useHeatmapProps.d.ts +2 -2
- package/Heatmap/useHeatmapProps.js +2 -4
- package/Heatmap/useHeatmapProps.mjs +2 -4
- package/LineChartPro/LineChartPro.d.mts +2 -2
- package/LineChartPro/LineChartPro.d.ts +2 -2
- package/LineChartPro/LineChartPro.js +35 -11
- package/LineChartPro/LineChartPro.mjs +35 -11
- package/PieChartPro/PieChartPro.d.mts +2 -2
- package/PieChartPro/PieChartPro.d.ts +2 -2
- package/PieChartPro/PieChartPro.js +17 -5
- package/PieChartPro/PieChartPro.mjs +17 -5
- package/RadarChartPro/RadarChartPro.d.mts +1 -1
- package/RadarChartPro/RadarChartPro.d.ts +1 -1
- package/RadarChartPro/RadarChartPro.js +15 -0
- package/RadarChartPro/RadarChartPro.mjs +15 -0
- package/SankeyChart/SankeyChart.d.mts +2 -2
- package/SankeyChart/SankeyChart.d.ts +2 -2
- package/SankeyChart/SankeyChart.js +16 -10
- package/SankeyChart/SankeyChart.mjs +16 -10
- package/SankeyChart/SankeyDataProvider.d.mts +2 -2
- package/SankeyChart/SankeyDataProvider.d.ts +2 -2
- package/SankeyChart/SankeyDataProvider.js +2 -2
- package/SankeyChart/SankeyDataProvider.mjs +2 -2
- package/SankeyChart/SankeyLinkElement.js +3 -0
- package/SankeyChart/SankeyLinkElement.mjs +3 -0
- package/SankeyChart/SankeyLinkLabel.js +3 -0
- package/SankeyChart/SankeyLinkLabel.mjs +3 -0
- package/SankeyChart/SankeyLinkLabelPlot.d.mts +2 -2
- package/SankeyChart/SankeyLinkLabelPlot.d.ts +2 -2
- package/SankeyChart/SankeyLinkLabelPlot.js +1 -1
- package/SankeyChart/SankeyLinkLabelPlot.mjs +1 -1
- package/SankeyChart/SankeyLinkPlot.d.mts +2 -2
- package/SankeyChart/SankeyLinkPlot.d.ts +2 -2
- package/SankeyChart/SankeyLinkPlot.js +1 -1
- package/SankeyChart/SankeyLinkPlot.mjs +1 -1
- package/SankeyChart/SankeyNodeElement.d.mts +1 -1
- package/SankeyChart/SankeyNodeElement.d.ts +1 -1
- package/SankeyChart/SankeyNodeElement.js +16 -15
- package/SankeyChart/SankeyNodeElement.mjs +16 -15
- package/SankeyChart/SankeyNodeLabel.js +3 -0
- package/SankeyChart/SankeyNodeLabel.mjs +3 -0
- package/SankeyChart/SankeyNodeLabelPlot.d.mts +2 -2
- package/SankeyChart/SankeyNodeLabelPlot.d.ts +2 -2
- package/SankeyChart/SankeyNodeLabelPlot.js +1 -1
- package/SankeyChart/SankeyNodeLabelPlot.mjs +1 -1
- package/SankeyChart/SankeyNodePlot.d.mts +2 -2
- package/SankeyChart/SankeyNodePlot.d.ts +2 -2
- package/SankeyChart/SankeyNodePlot.js +1 -1
- package/SankeyChart/SankeyNodePlot.mjs +1 -1
- package/SankeyChart/SankeyPlot.d.mts +2 -2
- package/SankeyChart/SankeyPlot.d.ts +2 -2
- package/SankeyChart/SankeyPlot.js +3 -3
- package/SankeyChart/SankeyPlot.mjs +3 -3
- package/SankeyChart/SankeyTooltip/SankeyTooltip.classes.js +2 -2
- package/SankeyChart/SankeyTooltip/SankeyTooltip.classes.mjs +1 -1
- package/SankeyChart/index.d.mts +2 -1
- package/SankeyChart/index.d.ts +2 -1
- package/SankeyChart/index.js +3 -3
- package/SankeyChart/index.mjs +1 -1
- package/SankeyChart/sankeyClasses.d.mts +15 -6
- package/SankeyChart/sankeyClasses.d.ts +15 -6
- package/SankeyChart/sankeyClasses.js +12 -8
- package/SankeyChart/sankeyClasses.mjs +10 -6
- package/SankeyChart/useSankeyChartProps.d.mts +2 -2
- package/SankeyChart/useSankeyChartProps.d.ts +2 -2
- package/SankeyChart/useSankeyChartProps.js +2 -2
- package/SankeyChart/useSankeyChartProps.mjs +2 -2
- package/ScatterChartPro/ScatterChartPro.d.mts +2 -2
- package/ScatterChartPro/ScatterChartPro.d.ts +2 -2
- package/ScatterChartPro/ScatterChartPro.js +57 -15
- package/ScatterChartPro/ScatterChartPro.mjs +57 -15
- package/context/useChartProApiContext.d.mts +1 -1
- package/context/useChartProApiContext.d.ts +1 -1
- package/context/useChartProApiContext.js +1 -1
- package/context/useChartProApiContext.mjs +1 -1
- package/index.d.mts +0 -4
- package/index.d.ts +0 -4
- package/index.js +2 -34
- package/index.mjs +1 -4
- package/internals/index.d.mts +0 -1
- package/internals/index.d.ts +0 -1
- package/internals/index.js +0 -8
- package/internals/index.mjs +0 -1
- package/internals/plugins/useChartProExport/common.js +4 -8
- package/internals/plugins/useChartProExport/common.mjs +4 -8
- package/internals/plugins/useChartProZoom/ZoomInteractionConfig.types.d.mts +1 -1
- package/internals/plugins/useChartProZoom/ZoomInteractionConfig.types.d.ts +1 -1
- package/internals/plugins/useChartProZoom/gestureHooks/useZoomOnBrush.js +16 -1
- package/internals/plugins/useChartProZoom/gestureHooks/useZoomOnBrush.mjs +16 -1
- package/package.json +129 -185
- package/themeAugmentation/components.d.mts +19 -1
- package/themeAugmentation/components.d.ts +19 -1
- package/themeAugmentation/overrides.d.mts +5 -2
- package/themeAugmentation/overrides.d.ts +5 -2
- package/themeAugmentation/props.d.mts +8 -0
- package/themeAugmentation/props.d.ts +8 -0
- package/ChartContainer/index.d.mts +0 -1
- package/ChartContainer/index.d.ts +0 -1
- package/ChartContainer/index.js +0 -16
- package/ChartContainer/index.mjs +0 -2
- package/ChartContainerPro/ChartContainerPro.d.mts +0 -21
- package/ChartContainerPro/ChartContainerPro.d.ts +0 -21
- package/ChartContainerPro/ChartContainerPro.js +0 -24
- package/ChartContainerPro/ChartContainerPro.mjs +0 -20
- package/ChartContainerPro/index.d.mts +0 -9
- package/ChartContainerPro/index.d.ts +0 -9
- package/ChartContainerPro/index.js +0 -17
- package/ChartContainerPro/index.mjs +0 -6
- package/ChartContainerPro/useChartContainerProProps.d.mts +0 -12
- package/ChartContainerPro/useChartContainerProProps.d.ts +0 -12
- package/ChartContainerPro/useChartContainerProProps.js +0 -19
- package/ChartContainerPro/useChartContainerProProps.mjs +0 -14
- package/ChartDataProvider/index.d.mts +0 -1
- package/ChartDataProvider/index.d.ts +0 -1
- package/ChartDataProvider/index.js +0 -16
- package/ChartDataProvider/index.mjs +0 -2
- package/ChartDataProviderPro/ChartDataProviderPro.d.mts +0 -20
- package/ChartDataProviderPro/ChartDataProviderPro.d.ts +0 -20
- package/ChartDataProviderPro/ChartDataProviderPro.js +0 -30
- package/ChartDataProviderPro/ChartDataProviderPro.mjs +0 -21
- package/ChartDataProviderPro/index.d.mts +0 -2
- package/ChartDataProviderPro/index.d.ts +0 -2
- package/ChartDataProviderPro/index.js +0 -13
- package/ChartDataProviderPro/index.mjs +0 -2
- package/ChartDataProviderPro/useChartDataProviderProProps.d.mts +0 -10
- package/ChartDataProviderPro/useChartDataProviderProProps.d.ts +0 -10
- package/ChartDataProviderPro/useChartDataProviderProProps.js +0 -12
- package/ChartDataProviderPro/useChartDataProviderProProps.mjs +0 -8
- package/FunnelChart/funnelSectionClasses.d.mts +0 -30
- package/FunnelChart/funnelSectionClasses.d.ts +0 -30
- package/FunnelChart/funnelSectionClasses.js +0 -44
- package/FunnelChart/funnelSectionClasses.mjs +0 -35
- package/Heatmap/internals/HeatmapCell.d.mts +0 -21
- package/Heatmap/internals/HeatmapCell.d.ts +0 -21
- package/Heatmap/internals/HeatmapCell.js +0 -18
- package/Heatmap/internals/HeatmapCell.mjs +0 -12
- package/tests/constants.js +0 -7
- package/tests/constants.mjs +0 -1
|
@@ -20,8 +20,8 @@ import { ChartsWrapper } from '@mui/x-charts/ChartsWrapper';
|
|
|
20
20
|
import { ChartsBrushOverlay } from '@mui/x-charts/ChartsBrushOverlay';
|
|
21
21
|
import { ChartsZoomSlider } from "../ChartsZoomSlider/index.mjs";
|
|
22
22
|
import { ChartsToolbarPro } from "../ChartsToolbarPro/index.mjs";
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
23
|
+
import { useChartsContainerProProps } from "../ChartsContainerPro/useChartsContainerProProps.mjs";
|
|
24
|
+
import { ChartsDataProviderPro } from "../ChartsDataProviderPro/index.mjs";
|
|
25
25
|
import { LINE_CHART_PRO_PLUGINS } from "./LineChartPro.plugins.mjs";
|
|
26
26
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
27
27
|
/**
|
|
@@ -49,7 +49,7 @@ const LineChartPro = /*#__PURE__*/React.forwardRef(function LineChartPro(inProps
|
|
|
49
49
|
other = _objectWithoutPropertiesLoose(props, _excluded);
|
|
50
50
|
const {
|
|
51
51
|
chartsWrapperProps,
|
|
52
|
-
|
|
52
|
+
chartsContainerProps,
|
|
53
53
|
gridProps,
|
|
54
54
|
clipPathProps,
|
|
55
55
|
clipPathGroupProps,
|
|
@@ -64,9 +64,9 @@ const LineChartPro = /*#__PURE__*/React.forwardRef(function LineChartPro(inProps
|
|
|
64
64
|
children
|
|
65
65
|
} = useLineChartProps(other);
|
|
66
66
|
const {
|
|
67
|
-
|
|
67
|
+
chartsDataProviderProProps,
|
|
68
68
|
chartsSurfaceProps
|
|
69
|
-
} =
|
|
69
|
+
} = useChartsContainerProProps(_extends({}, chartsContainerProps, {
|
|
70
70
|
initialZoom,
|
|
71
71
|
zoomData,
|
|
72
72
|
onZoomChange,
|
|
@@ -75,7 +75,7 @@ const LineChartPro = /*#__PURE__*/React.forwardRef(function LineChartPro(inProps
|
|
|
75
75
|
}));
|
|
76
76
|
const Tooltip = props.slots?.tooltip ?? ChartsTooltip;
|
|
77
77
|
const Toolbar = props.slots?.toolbar ?? ChartsToolbarPro;
|
|
78
|
-
return /*#__PURE__*/_jsx(
|
|
78
|
+
return /*#__PURE__*/_jsx(ChartsDataProviderPro, _extends({}, chartsDataProviderProProps, {
|
|
79
79
|
children: /*#__PURE__*/_jsxs(ChartsWrapper, _extends({}, chartsWrapperProps, {
|
|
80
80
|
ref: ref,
|
|
81
81
|
children: [showToolbar ? /*#__PURE__*/_jsx(Toolbar, _extends({}, props.slotProps?.toolbar)) : null, !props.hideLegend && /*#__PURE__*/_jsx(ChartsLegend, _extends({}, legendProps)), /*#__PURE__*/_jsxs(ChartsSurface, _extends({}, chartsSurfaceProps, {
|
|
@@ -136,6 +136,10 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
136
136
|
* An array of objects that can be used to populate series and axes data using their `dataKey` property.
|
|
137
137
|
*/
|
|
138
138
|
dataset: PropTypes.arrayOf(PropTypes.object),
|
|
139
|
+
/**
|
|
140
|
+
* The description of the chart.
|
|
141
|
+
* Used to provide an accessible description for the chart.
|
|
142
|
+
*/
|
|
139
143
|
desc: PropTypes.string,
|
|
140
144
|
/**
|
|
141
145
|
* If `true`, the charts will not listen to the mouse move event.
|
|
@@ -154,9 +158,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
154
158
|
/**
|
|
155
159
|
* Options to enable features planned for the next major.
|
|
156
160
|
*/
|
|
157
|
-
experimentalFeatures: PropTypes.
|
|
158
|
-
preferStrictDomainInLineCharts: PropTypes.bool
|
|
159
|
-
}),
|
|
161
|
+
experimentalFeatures: PropTypes.object,
|
|
160
162
|
/**
|
|
161
163
|
* Option to display a cartesian grid in the background.
|
|
162
164
|
*/
|
|
@@ -371,6 +373,10 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
371
373
|
slots: PropTypes.object,
|
|
372
374
|
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
|
373
375
|
theme: PropTypes.oneOf(['dark', 'light']),
|
|
376
|
+
/**
|
|
377
|
+
* The title of the chart.
|
|
378
|
+
* Used to provide an accessible label for the chart.
|
|
379
|
+
*/
|
|
374
380
|
title: PropTypes.string,
|
|
375
381
|
/**
|
|
376
382
|
* The controlled axis tooltip.
|
|
@@ -406,6 +412,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
406
412
|
barGapRatio: PropTypes.number,
|
|
407
413
|
categoryGapRatio: PropTypes.number,
|
|
408
414
|
classes: PropTypes.object,
|
|
415
|
+
className: PropTypes.string,
|
|
409
416
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
410
417
|
colors: PropTypes.arrayOf(PropTypes.string).isRequired,
|
|
411
418
|
type: PropTypes.oneOf(['ordinal']).isRequired,
|
|
@@ -479,6 +486,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
479
486
|
}), PropTypes.shape({
|
|
480
487
|
axis: PropTypes.oneOf(['x']),
|
|
481
488
|
classes: PropTypes.object,
|
|
489
|
+
className: PropTypes.string,
|
|
482
490
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
483
491
|
colors: PropTypes.arrayOf(PropTypes.string).isRequired,
|
|
484
492
|
type: PropTypes.oneOf(['ordinal']).isRequired,
|
|
@@ -552,6 +560,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
552
560
|
}), PropTypes.shape({
|
|
553
561
|
axis: PropTypes.oneOf(['x']),
|
|
554
562
|
classes: PropTypes.object,
|
|
563
|
+
className: PropTypes.string,
|
|
555
564
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
556
565
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
557
566
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -612,6 +621,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
612
621
|
}), PropTypes.shape({
|
|
613
622
|
axis: PropTypes.oneOf(['x']),
|
|
614
623
|
classes: PropTypes.object,
|
|
624
|
+
className: PropTypes.string,
|
|
615
625
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
616
626
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
617
627
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -673,6 +683,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
673
683
|
}), PropTypes.shape({
|
|
674
684
|
axis: PropTypes.oneOf(['x']),
|
|
675
685
|
classes: PropTypes.object,
|
|
686
|
+
className: PropTypes.string,
|
|
676
687
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
677
688
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
678
689
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -733,6 +744,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
733
744
|
}), PropTypes.shape({
|
|
734
745
|
axis: PropTypes.oneOf(['x']),
|
|
735
746
|
classes: PropTypes.object,
|
|
747
|
+
className: PropTypes.string,
|
|
736
748
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
737
749
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
738
750
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -793,6 +805,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
793
805
|
}), PropTypes.shape({
|
|
794
806
|
axis: PropTypes.oneOf(['x']),
|
|
795
807
|
classes: PropTypes.object,
|
|
808
|
+
className: PropTypes.string,
|
|
796
809
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
797
810
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
798
811
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -857,6 +870,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
857
870
|
}), PropTypes.shape({
|
|
858
871
|
axis: PropTypes.oneOf(['x']),
|
|
859
872
|
classes: PropTypes.object,
|
|
873
|
+
className: PropTypes.string,
|
|
860
874
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
861
875
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
862
876
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -921,6 +935,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
921
935
|
}), PropTypes.shape({
|
|
922
936
|
axis: PropTypes.oneOf(['x']),
|
|
923
937
|
classes: PropTypes.object,
|
|
938
|
+
className: PropTypes.string,
|
|
924
939
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
925
940
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
926
941
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -989,6 +1004,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
989
1004
|
barGapRatio: PropTypes.number,
|
|
990
1005
|
categoryGapRatio: PropTypes.number,
|
|
991
1006
|
classes: PropTypes.object,
|
|
1007
|
+
className: PropTypes.string,
|
|
992
1008
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
993
1009
|
colors: PropTypes.arrayOf(PropTypes.string).isRequired,
|
|
994
1010
|
type: PropTypes.oneOf(['ordinal']).isRequired,
|
|
@@ -1061,6 +1077,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1061
1077
|
}), PropTypes.shape({
|
|
1062
1078
|
axis: PropTypes.oneOf(['y']),
|
|
1063
1079
|
classes: PropTypes.object,
|
|
1080
|
+
className: PropTypes.string,
|
|
1064
1081
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1065
1082
|
colors: PropTypes.arrayOf(PropTypes.string).isRequired,
|
|
1066
1083
|
type: PropTypes.oneOf(['ordinal']).isRequired,
|
|
@@ -1133,6 +1150,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1133
1150
|
}), PropTypes.shape({
|
|
1134
1151
|
axis: PropTypes.oneOf(['y']),
|
|
1135
1152
|
classes: PropTypes.object,
|
|
1153
|
+
className: PropTypes.string,
|
|
1136
1154
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1137
1155
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1138
1156
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1192,6 +1210,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1192
1210
|
}), PropTypes.shape({
|
|
1193
1211
|
axis: PropTypes.oneOf(['y']),
|
|
1194
1212
|
classes: PropTypes.object,
|
|
1213
|
+
className: PropTypes.string,
|
|
1195
1214
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1196
1215
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1197
1216
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1252,6 +1271,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1252
1271
|
}), PropTypes.shape({
|
|
1253
1272
|
axis: PropTypes.oneOf(['y']),
|
|
1254
1273
|
classes: PropTypes.object,
|
|
1274
|
+
className: PropTypes.string,
|
|
1255
1275
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1256
1276
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1257
1277
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1311,6 +1331,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1311
1331
|
}), PropTypes.shape({
|
|
1312
1332
|
axis: PropTypes.oneOf(['y']),
|
|
1313
1333
|
classes: PropTypes.object,
|
|
1334
|
+
className: PropTypes.string,
|
|
1314
1335
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1315
1336
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1316
1337
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1370,6 +1391,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1370
1391
|
}), PropTypes.shape({
|
|
1371
1392
|
axis: PropTypes.oneOf(['y']),
|
|
1372
1393
|
classes: PropTypes.object,
|
|
1394
|
+
className: PropTypes.string,
|
|
1373
1395
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1374
1396
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1375
1397
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1433,6 +1455,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1433
1455
|
}), PropTypes.shape({
|
|
1434
1456
|
axis: PropTypes.oneOf(['y']),
|
|
1435
1457
|
classes: PropTypes.object,
|
|
1458
|
+
className: PropTypes.string,
|
|
1436
1459
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1437
1460
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1438
1461
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1496,6 +1519,7 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1496
1519
|
}), PropTypes.shape({
|
|
1497
1520
|
axis: PropTypes.oneOf(['y']),
|
|
1498
1521
|
classes: PropTypes.object,
|
|
1522
|
+
className: PropTypes.string,
|
|
1499
1523
|
colorMap: PropTypes.oneOfType([PropTypes.shape({
|
|
1500
1524
|
color: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string.isRequired), PropTypes.func]).isRequired,
|
|
1501
1525
|
max: PropTypes.oneOfType([PropTypes.instanceOf(Date), PropTypes.number]),
|
|
@@ -1621,8 +1645,8 @@ process.env.NODE_ENV !== "production" ? LineChartPro.propTypes = {
|
|
|
1621
1645
|
requiredKeys: PropTypes.arrayOf(PropTypes.string),
|
|
1622
1646
|
type: PropTypes.oneOf(['doubleTapReset']).isRequired
|
|
1623
1647
|
}), PropTypes.shape({
|
|
1624
|
-
pointerMode: PropTypes.
|
|
1625
|
-
requiredKeys: PropTypes.
|
|
1648
|
+
pointerMode: PropTypes.oneOf(['mouse', 'touch']),
|
|
1649
|
+
requiredKeys: PropTypes.arrayOf(PropTypes.string),
|
|
1626
1650
|
type: PropTypes.oneOf(['brush']).isRequired
|
|
1627
1651
|
})]).isRequired)
|
|
1628
1652
|
})
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { type PieChartProps, type PieChartSlotProps, type PieChartSlots } from '@mui/x-charts/PieChart';
|
|
3
3
|
import { type ChartsSlotsPro, type ChartsSlotPropsPro } from "../internals/material/index.mjs";
|
|
4
|
-
import { type
|
|
4
|
+
import { type ChartsContainerProProps } from "../ChartsContainerPro/index.mjs";
|
|
5
5
|
import { type PieChartProPluginSignatures } from "./PieChartPro.plugins.mjs";
|
|
6
6
|
import { type ChartsToolbarProSlotProps, type ChartsToolbarProSlots } from "../ChartsToolbarPro/Toolbar.types.mjs";
|
|
7
7
|
export interface PieChartProSlots extends Omit<PieChartSlots, 'toolbar'>, ChartsToolbarProSlots, Partial<ChartsSlotsPro> {}
|
|
8
8
|
export interface PieChartProSlotProps extends Omit<PieChartSlotProps, 'toolbar'>, ChartsToolbarProSlotProps, Partial<ChartsSlotPropsPro> {}
|
|
9
|
-
export interface PieChartProProps extends Omit<PieChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<
|
|
9
|
+
export interface PieChartProProps extends Omit<PieChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<ChartsContainerProProps<'pie', PieChartProPluginSignatures>, 'series' | 'slots' | 'slotProps'> {
|
|
10
10
|
/**
|
|
11
11
|
* Overridable component slots.
|
|
12
12
|
* @default {}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { type PieChartProps, type PieChartSlotProps, type PieChartSlots } from '@mui/x-charts/PieChart';
|
|
3
3
|
import { type ChartsSlotsPro, type ChartsSlotPropsPro } from "../internals/material/index.js";
|
|
4
|
-
import { type
|
|
4
|
+
import { type ChartsContainerProProps } from "../ChartsContainerPro/index.js";
|
|
5
5
|
import { type PieChartProPluginSignatures } from "./PieChartPro.plugins.js";
|
|
6
6
|
import { type ChartsToolbarProSlotProps, type ChartsToolbarProSlots } from "../ChartsToolbarPro/Toolbar.types.js";
|
|
7
7
|
export interface PieChartProSlots extends Omit<PieChartSlots, 'toolbar'>, ChartsToolbarProSlots, Partial<ChartsSlotsPro> {}
|
|
8
8
|
export interface PieChartProSlotProps extends Omit<PieChartSlotProps, 'toolbar'>, ChartsToolbarProSlotProps, Partial<ChartsSlotPropsPro> {}
|
|
9
|
-
export interface PieChartProProps extends Omit<PieChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<
|
|
9
|
+
export interface PieChartProProps extends Omit<PieChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<ChartsContainerProProps<'pie', PieChartProPluginSignatures>, 'series' | 'slots' | 'slotProps'> {
|
|
10
10
|
/**
|
|
11
11
|
* Overridable component slots.
|
|
12
12
|
* @default {}
|
|
@@ -18,8 +18,8 @@ var _ChartsLegend = require("@mui/x-charts/ChartsLegend");
|
|
|
18
18
|
var _ChartsSurface = require("@mui/x-charts/ChartsSurface");
|
|
19
19
|
var _PieChart = require("@mui/x-charts/PieChart");
|
|
20
20
|
var _ChartsWrapper = require("@mui/x-charts/ChartsWrapper");
|
|
21
|
-
var
|
|
22
|
-
var
|
|
21
|
+
var _useChartsContainerProProps = require("../ChartsContainerPro/useChartsContainerProProps");
|
|
22
|
+
var _ChartsDataProviderPro = require("../ChartsDataProviderPro");
|
|
23
23
|
var _ChartsToolbarPro = require("../ChartsToolbarPro");
|
|
24
24
|
var _PieChartPro2 = require("./PieChartPro.plugins");
|
|
25
25
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
@@ -51,9 +51,9 @@ const PieChartPro = exports.PieChartPro = /*#__PURE__*/React.forwardRef(function
|
|
|
51
51
|
other = (0, _objectWithoutPropertiesLoose2.default)(props, _excluded);
|
|
52
52
|
const margin = (0, _internals.defaultizeMargin)(marginProps, _internals.DEFAULT_PIE_CHART_MARGIN);
|
|
53
53
|
const {
|
|
54
|
-
|
|
54
|
+
chartsDataProviderProProps,
|
|
55
55
|
chartsSurfaceProps
|
|
56
|
-
} = (0,
|
|
56
|
+
} = (0, _useChartsContainerProProps.useChartsContainerProProps)((0, _extends2.default)({}, other, {
|
|
57
57
|
series: series.map(s => (0, _extends2.default)({
|
|
58
58
|
type: 'pie'
|
|
59
59
|
}, s)),
|
|
@@ -69,7 +69,7 @@ const PieChartPro = exports.PieChartPro = /*#__PURE__*/React.forwardRef(function
|
|
|
69
69
|
}));
|
|
70
70
|
const Tooltip = slots?.tooltip ?? _ChartsTooltip.ChartsTooltip;
|
|
71
71
|
const Toolbar = slots?.toolbar ?? _ChartsToolbarPro.ChartsToolbarPro;
|
|
72
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(
|
|
72
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsDataProviderPro.ChartsDataProviderPro, (0, _extends2.default)({}, chartsDataProviderProProps, {
|
|
73
73
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsWrapper.ChartsWrapper, {
|
|
74
74
|
legendPosition: slotProps?.legend?.position,
|
|
75
75
|
legendDirection: slotProps?.legend?.direction ?? 'vertical',
|
|
@@ -119,11 +119,19 @@ process.env.NODE_ENV !== "production" ? PieChartPro.propTypes = {
|
|
|
119
119
|
* An array of objects that can be used to populate series and axes data using their `dataKey` property.
|
|
120
120
|
*/
|
|
121
121
|
dataset: _propTypes.default.arrayOf(_propTypes.default.object),
|
|
122
|
+
/**
|
|
123
|
+
* The description of the chart.
|
|
124
|
+
* Used to provide an accessible description for the chart.
|
|
125
|
+
*/
|
|
122
126
|
desc: _propTypes.default.string,
|
|
123
127
|
/**
|
|
124
128
|
* If `true`, disables keyboard navigation for the chart.
|
|
125
129
|
*/
|
|
126
130
|
disableKeyboardNavigation: _propTypes.default.bool,
|
|
131
|
+
/**
|
|
132
|
+
* Options to enable features planned for the next major.
|
|
133
|
+
*/
|
|
134
|
+
experimentalFeatures: _propTypes.default.object,
|
|
127
135
|
/**
|
|
128
136
|
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
129
137
|
*/
|
|
@@ -277,6 +285,10 @@ process.env.NODE_ENV !== "production" ? PieChartPro.propTypes = {
|
|
|
277
285
|
slots: _propTypes.default.object,
|
|
278
286
|
sx: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object, _propTypes.default.bool])), _propTypes.default.func, _propTypes.default.object]),
|
|
279
287
|
theme: _propTypes.default.oneOf(['dark', 'light']),
|
|
288
|
+
/**
|
|
289
|
+
* The title of the chart.
|
|
290
|
+
* Used to provide an accessible label for the chart.
|
|
291
|
+
*/
|
|
280
292
|
title: _propTypes.default.string,
|
|
281
293
|
/**
|
|
282
294
|
* The tooltip item.
|
|
@@ -11,8 +11,8 @@ import { ChartsLegend } from '@mui/x-charts/ChartsLegend';
|
|
|
11
11
|
import { ChartsSurface } from '@mui/x-charts/ChartsSurface';
|
|
12
12
|
import { PiePlot } from '@mui/x-charts/PieChart';
|
|
13
13
|
import { ChartsWrapper } from '@mui/x-charts/ChartsWrapper';
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
14
|
+
import { useChartsContainerProProps } from "../ChartsContainerPro/useChartsContainerProProps.mjs";
|
|
15
|
+
import { ChartsDataProviderPro } from "../ChartsDataProviderPro/index.mjs";
|
|
16
16
|
import { ChartsToolbarPro } from "../ChartsToolbarPro/index.mjs";
|
|
17
17
|
import { PIE_CHART_PRO_PLUGINS } from "./PieChartPro.plugins.mjs";
|
|
18
18
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -43,9 +43,9 @@ const PieChartPro = /*#__PURE__*/React.forwardRef(function PieChartPro(inProps,
|
|
|
43
43
|
other = _objectWithoutPropertiesLoose(props, _excluded);
|
|
44
44
|
const margin = defaultizeMargin(marginProps, DEFAULT_PIE_CHART_MARGIN);
|
|
45
45
|
const {
|
|
46
|
-
|
|
46
|
+
chartsDataProviderProProps,
|
|
47
47
|
chartsSurfaceProps
|
|
48
|
-
} =
|
|
48
|
+
} = useChartsContainerProProps(_extends({}, other, {
|
|
49
49
|
series: series.map(s => _extends({
|
|
50
50
|
type: 'pie'
|
|
51
51
|
}, s)),
|
|
@@ -61,7 +61,7 @@ const PieChartPro = /*#__PURE__*/React.forwardRef(function PieChartPro(inProps,
|
|
|
61
61
|
}));
|
|
62
62
|
const Tooltip = slots?.tooltip ?? ChartsTooltip;
|
|
63
63
|
const Toolbar = slots?.toolbar ?? ChartsToolbarPro;
|
|
64
|
-
return /*#__PURE__*/_jsx(
|
|
64
|
+
return /*#__PURE__*/_jsx(ChartsDataProviderPro, _extends({}, chartsDataProviderProProps, {
|
|
65
65
|
children: /*#__PURE__*/_jsxs(ChartsWrapper, {
|
|
66
66
|
legendPosition: slotProps?.legend?.position,
|
|
67
67
|
legendDirection: slotProps?.legend?.direction ?? 'vertical',
|
|
@@ -111,11 +111,19 @@ process.env.NODE_ENV !== "production" ? PieChartPro.propTypes = {
|
|
|
111
111
|
* An array of objects that can be used to populate series and axes data using their `dataKey` property.
|
|
112
112
|
*/
|
|
113
113
|
dataset: PropTypes.arrayOf(PropTypes.object),
|
|
114
|
+
/**
|
|
115
|
+
* The description of the chart.
|
|
116
|
+
* Used to provide an accessible description for the chart.
|
|
117
|
+
*/
|
|
114
118
|
desc: PropTypes.string,
|
|
115
119
|
/**
|
|
116
120
|
* If `true`, disables keyboard navigation for the chart.
|
|
117
121
|
*/
|
|
118
122
|
disableKeyboardNavigation: PropTypes.bool,
|
|
123
|
+
/**
|
|
124
|
+
* Options to enable features planned for the next major.
|
|
125
|
+
*/
|
|
126
|
+
experimentalFeatures: PropTypes.object,
|
|
119
127
|
/**
|
|
120
128
|
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
121
129
|
*/
|
|
@@ -269,6 +277,10 @@ process.env.NODE_ENV !== "production" ? PieChartPro.propTypes = {
|
|
|
269
277
|
slots: PropTypes.object,
|
|
270
278
|
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
|
271
279
|
theme: PropTypes.oneOf(['dark', 'light']),
|
|
280
|
+
/**
|
|
281
|
+
* The title of the chart.
|
|
282
|
+
* Used to provide an accessible label for the chart.
|
|
283
|
+
*/
|
|
272
284
|
title: PropTypes.string,
|
|
273
285
|
/**
|
|
274
286
|
* The tooltip item.
|
|
@@ -5,7 +5,7 @@ import { type ChartsToolbarProSlotProps, type ChartsToolbarProSlots } from "../C
|
|
|
5
5
|
import { type ChartsSlotPropsPro, type ChartsSlotsPro } from "../internals/material/index.mjs";
|
|
6
6
|
export interface RadarChartProSlots extends Omit<RadarChartSlots, 'toolbar'>, ChartsToolbarProSlots, Partial<ChartsSlotsPro> {}
|
|
7
7
|
export interface RadarChartProSlotProps extends Omit<RadarChartSlotProps, 'toolbar'>, ChartsToolbarProSlotProps, Partial<ChartsSlotPropsPro> {}
|
|
8
|
-
export interface RadarChartProProps extends Omit<RadarChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<RadarDataProviderProps<RadarChartProPluginSignatures>, 'slots' | 'slotProps'
|
|
8
|
+
export interface RadarChartProProps extends Omit<RadarChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<RadarDataProviderProps<RadarChartProPluginSignatures>, 'slots' | 'slotProps'> {
|
|
9
9
|
/**
|
|
10
10
|
* Overridable component slots.
|
|
11
11
|
* @default {}
|
|
@@ -5,7 +5,7 @@ import { type ChartsToolbarProSlotProps, type ChartsToolbarProSlots } from "../C
|
|
|
5
5
|
import { type ChartsSlotPropsPro, type ChartsSlotsPro } from "../internals/material/index.js";
|
|
6
6
|
export interface RadarChartProSlots extends Omit<RadarChartSlots, 'toolbar'>, ChartsToolbarProSlots, Partial<ChartsSlotsPro> {}
|
|
7
7
|
export interface RadarChartProSlotProps extends Omit<RadarChartSlotProps, 'toolbar'>, ChartsToolbarProSlotProps, Partial<ChartsSlotPropsPro> {}
|
|
8
|
-
export interface RadarChartProProps extends Omit<RadarChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<RadarDataProviderProps<RadarChartProPluginSignatures>, 'slots' | 'slotProps'
|
|
8
|
+
export interface RadarChartProProps extends Omit<RadarChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<RadarDataProviderProps<RadarChartProPluginSignatures>, 'slots' | 'slotProps'> {
|
|
9
9
|
/**
|
|
10
10
|
* Overridable component slots.
|
|
11
11
|
* @default {}
|
|
@@ -72,12 +72,19 @@ process.env.NODE_ENV !== "production" ? RadarChartPro.propTypes = {
|
|
|
72
72
|
exportAsPrint: _propTypes.default.func.isRequired
|
|
73
73
|
})
|
|
74
74
|
}),
|
|
75
|
+
/**
|
|
76
|
+
* A CSS class name applied to the root element.
|
|
77
|
+
*/
|
|
75
78
|
className: _propTypes.default.string,
|
|
76
79
|
/**
|
|
77
80
|
* Color palette used to colorize multiple series.
|
|
78
81
|
* @default rainbowSurgePalette
|
|
79
82
|
*/
|
|
80
83
|
colors: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.string), _propTypes.default.func]),
|
|
84
|
+
/**
|
|
85
|
+
* The description of the chart.
|
|
86
|
+
* Used to provide an accessible description for the chart.
|
|
87
|
+
*/
|
|
81
88
|
desc: _propTypes.default.string,
|
|
82
89
|
/**
|
|
83
90
|
* If `true`, the charts will not listen to the mouse move event.
|
|
@@ -94,6 +101,10 @@ process.env.NODE_ENV !== "production" ? RadarChartPro.propTypes = {
|
|
|
94
101
|
* @default 5
|
|
95
102
|
*/
|
|
96
103
|
divisions: _propTypes.default.number,
|
|
104
|
+
/**
|
|
105
|
+
* Options to enable features planned for the next major.
|
|
106
|
+
*/
|
|
107
|
+
experimentalFeatures: _propTypes.default.object,
|
|
97
108
|
/**
|
|
98
109
|
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
99
110
|
*/
|
|
@@ -293,6 +304,10 @@ process.env.NODE_ENV !== "production" ? RadarChartPro.propTypes = {
|
|
|
293
304
|
stripeColor: _propTypes.default.func,
|
|
294
305
|
sx: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object, _propTypes.default.bool])), _propTypes.default.func, _propTypes.default.object]),
|
|
295
306
|
theme: _propTypes.default.oneOf(['dark', 'light']),
|
|
307
|
+
/**
|
|
308
|
+
* The title of the chart.
|
|
309
|
+
* Used to provide an accessible label for the chart.
|
|
310
|
+
*/
|
|
296
311
|
title: _propTypes.default.string,
|
|
297
312
|
/**
|
|
298
313
|
* The tooltip item.
|
|
@@ -65,12 +65,19 @@ process.env.NODE_ENV !== "production" ? RadarChartPro.propTypes = {
|
|
|
65
65
|
exportAsPrint: PropTypes.func.isRequired
|
|
66
66
|
})
|
|
67
67
|
}),
|
|
68
|
+
/**
|
|
69
|
+
* A CSS class name applied to the root element.
|
|
70
|
+
*/
|
|
68
71
|
className: PropTypes.string,
|
|
69
72
|
/**
|
|
70
73
|
* Color palette used to colorize multiple series.
|
|
71
74
|
* @default rainbowSurgePalette
|
|
72
75
|
*/
|
|
73
76
|
colors: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string), PropTypes.func]),
|
|
77
|
+
/**
|
|
78
|
+
* The description of the chart.
|
|
79
|
+
* Used to provide an accessible description for the chart.
|
|
80
|
+
*/
|
|
74
81
|
desc: PropTypes.string,
|
|
75
82
|
/**
|
|
76
83
|
* If `true`, the charts will not listen to the mouse move event.
|
|
@@ -87,6 +94,10 @@ process.env.NODE_ENV !== "production" ? RadarChartPro.propTypes = {
|
|
|
87
94
|
* @default 5
|
|
88
95
|
*/
|
|
89
96
|
divisions: PropTypes.number,
|
|
97
|
+
/**
|
|
98
|
+
* Options to enable features planned for the next major.
|
|
99
|
+
*/
|
|
100
|
+
experimentalFeatures: PropTypes.object,
|
|
90
101
|
/**
|
|
91
102
|
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
92
103
|
*/
|
|
@@ -286,6 +297,10 @@ process.env.NODE_ENV !== "production" ? RadarChartPro.propTypes = {
|
|
|
286
297
|
stripeColor: PropTypes.func,
|
|
287
298
|
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
|
288
299
|
theme: PropTypes.oneOf(['dark', 'light']),
|
|
300
|
+
/**
|
|
301
|
+
* The title of the chart.
|
|
302
|
+
* Used to provide an accessible label for the chart.
|
|
303
|
+
*/
|
|
289
304
|
title: PropTypes.string,
|
|
290
305
|
/**
|
|
291
306
|
* The tooltip item.
|
|
@@ -4,10 +4,10 @@ import type { MakeOptional } from '@mui/x-internals/types';
|
|
|
4
4
|
import { type SankeyPlotProps } from "./SankeyPlot.mjs";
|
|
5
5
|
import type { SankeySeriesType } from "./sankey.types.mjs";
|
|
6
6
|
import type { SankeyChartSlotExtension } from "./sankeySlots.types.mjs";
|
|
7
|
-
import type {
|
|
7
|
+
import type { ChartsContainerProProps } from "../ChartsContainerPro/index.mjs";
|
|
8
8
|
import type { SankeyChartPluginSignatures } from "./SankeyChart.plugins.mjs";
|
|
9
9
|
export type SankeySeries = MakeOptional<SankeySeriesType, 'type'>;
|
|
10
|
-
export interface SankeyChartProps extends Omit<
|
|
10
|
+
export interface SankeyChartProps extends Omit<ChartsContainerProProps<'sankey', SankeyChartPluginSignatures>, 'plugins' | 'series' | 'slotProps' | 'slots' | 'dataset' | 'hideLegend' | 'skipAnimation'>, Omit<SankeyPlotProps, 'data'>, Omit<ChartsOverlayProps, 'slots' | 'slotProps'>, SankeyChartSlotExtension {
|
|
11
11
|
/**
|
|
12
12
|
* The series to display in the Sankey chart.
|
|
13
13
|
* A single object is expected.
|
|
@@ -4,10 +4,10 @@ import type { MakeOptional } from '@mui/x-internals/types';
|
|
|
4
4
|
import { type SankeyPlotProps } from "./SankeyPlot.js";
|
|
5
5
|
import type { SankeySeriesType } from "./sankey.types.js";
|
|
6
6
|
import type { SankeyChartSlotExtension } from "./sankeySlots.types.js";
|
|
7
|
-
import type {
|
|
7
|
+
import type { ChartsContainerProProps } from "../ChartsContainerPro/index.js";
|
|
8
8
|
import type { SankeyChartPluginSignatures } from "./SankeyChart.plugins.js";
|
|
9
9
|
export type SankeySeries = MakeOptional<SankeySeriesType, 'type'>;
|
|
10
|
-
export interface SankeyChartProps extends Omit<
|
|
10
|
+
export interface SankeyChartProps extends Omit<ChartsContainerProProps<'sankey', SankeyChartPluginSignatures>, 'plugins' | 'series' | 'slotProps' | 'slots' | 'dataset' | 'hideLegend' | 'skipAnimation'>, Omit<SankeyPlotProps, 'data'>, Omit<ChartsOverlayProps, 'slots' | 'slotProps'>, SankeyChartSlotExtension {
|
|
11
11
|
/**
|
|
12
12
|
* The series to display in the Sankey chart.
|
|
13
13
|
* A single object is expected.
|
|
@@ -15,7 +15,7 @@ var _styles = require("@mui/material/styles");
|
|
|
15
15
|
var _ChartsSurface = require("@mui/x-charts/ChartsSurface");
|
|
16
16
|
var _ChartsOverlay = require("@mui/x-charts/ChartsOverlay");
|
|
17
17
|
var _ChartsWrapper = require("@mui/x-charts/ChartsWrapper");
|
|
18
|
-
var
|
|
18
|
+
var _useChartsContainerProProps = require("../ChartsContainerPro/useChartsContainerProProps");
|
|
19
19
|
var _SankeyPlot = require("./SankeyPlot");
|
|
20
20
|
var _useSankeyChartProps = require("./useSankeyChartProps");
|
|
21
21
|
var _SankeyTooltip = require("./SankeyTooltip");
|
|
@@ -44,24 +44,24 @@ const SankeyChart = exports.SankeyChart = /*#__PURE__*/React.forwardRef(function
|
|
|
44
44
|
name: 'MuiSankeyChart'
|
|
45
45
|
});
|
|
46
46
|
const {
|
|
47
|
-
|
|
47
|
+
chartsContainerProps,
|
|
48
48
|
sankeyPlotProps,
|
|
49
49
|
overlayProps,
|
|
50
50
|
chartsWrapperProps,
|
|
51
51
|
children
|
|
52
52
|
} = (0, _useSankeyChartProps.useSankeyChartProps)(themedProps);
|
|
53
|
-
const
|
|
53
|
+
const _useChartsContainerPr = (0, _useChartsContainerProProps.useChartsContainerProProps)(chartsContainerProps),
|
|
54
54
|
{
|
|
55
|
-
|
|
55
|
+
chartsDataProviderProProps: {
|
|
56
56
|
series
|
|
57
57
|
},
|
|
58
58
|
chartsSurfaceProps
|
|
59
|
-
} =
|
|
60
|
-
|
|
59
|
+
} = _useChartsContainerPr,
|
|
60
|
+
chartsDataProviderProProps = (0, _objectWithoutPropertiesLoose2.default)(_useChartsContainerPr.chartsDataProviderProProps, _excluded);
|
|
61
61
|
const Tooltip = themedProps.slots?.tooltip ?? _SankeyTooltip.SankeyTooltip;
|
|
62
62
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_SankeyDataProvider.SankeyDataProvider, (0, _extends2.default)({
|
|
63
63
|
series: series
|
|
64
|
-
},
|
|
64
|
+
}, chartsDataProviderProProps, {
|
|
65
65
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsWrapper.ChartsWrapper, (0, _extends2.default)({}, chartsWrapperProps, {
|
|
66
66
|
ref: ref,
|
|
67
67
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsSurface.ChartsSurface, (0, _extends2.default)({}, chartsSurfaceProps, {
|
|
@@ -94,6 +94,10 @@ process.env.NODE_ENV !== "production" ? SankeyChart.propTypes = {
|
|
|
94
94
|
* @default rainbowSurgePalette
|
|
95
95
|
*/
|
|
96
96
|
colors: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.string), _propTypes.default.func]),
|
|
97
|
+
/**
|
|
98
|
+
* The description of the chart.
|
|
99
|
+
* Used to provide an accessible description for the chart.
|
|
100
|
+
*/
|
|
97
101
|
desc: _propTypes.default.string,
|
|
98
102
|
/**
|
|
99
103
|
* If `true`, disables keyboard navigation for the chart.
|
|
@@ -102,9 +106,7 @@ process.env.NODE_ENV !== "production" ? SankeyChart.propTypes = {
|
|
|
102
106
|
/**
|
|
103
107
|
* Options to enable features planned for the next major.
|
|
104
108
|
*/
|
|
105
|
-
experimentalFeatures: _propTypes.default.
|
|
106
|
-
preferStrictDomainInLineCharts: _propTypes.default.bool
|
|
107
|
-
}),
|
|
109
|
+
experimentalFeatures: _propTypes.default.object,
|
|
108
110
|
/**
|
|
109
111
|
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
110
112
|
*/
|
|
@@ -217,6 +219,10 @@ process.env.NODE_ENV !== "production" ? SankeyChart.propTypes = {
|
|
|
217
219
|
slots: _propTypes.default.object,
|
|
218
220
|
sx: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object, _propTypes.default.bool])), _propTypes.default.func, _propTypes.default.object]),
|
|
219
221
|
theme: _propTypes.default.oneOf(['dark', 'light']),
|
|
222
|
+
/**
|
|
223
|
+
* The title of the chart.
|
|
224
|
+
* Used to provide an accessible label for the chart.
|
|
225
|
+
*/
|
|
220
226
|
title: _propTypes.default.string,
|
|
221
227
|
/**
|
|
222
228
|
* The tooltip item.
|