@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
|
@@ -19,8 +19,8 @@ var _SankeyNodeLabelPlot = require("./SankeyNodeLabelPlot");
|
|
|
19
19
|
var _SankeyLinkLabelPlot = require("./SankeyLinkLabelPlot");
|
|
20
20
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
21
21
|
const SankeyPlotRoot = (0, _styles.styled)('g', {
|
|
22
|
-
|
|
23
|
-
|
|
22
|
+
name: 'MuiSankeyPlot',
|
|
23
|
+
slot: 'Root'
|
|
24
24
|
})({});
|
|
25
25
|
|
|
26
26
|
/**
|
|
@@ -38,7 +38,7 @@ function SankeyPlot(props) {
|
|
|
38
38
|
const sankeySeries = (0, _useSankeySeries.useSankeySeries)()[0];
|
|
39
39
|
const layout = (0, _useSankeySeries.useSankeyLayout)();
|
|
40
40
|
if (!sankeySeries) {
|
|
41
|
-
throw new Error(process.env.NODE_ENV !== "production" ? `MUI X Charts: Sankey series context is missing. Ensure the SankeyPlot is used inside a properly configured
|
|
41
|
+
throw new Error(process.env.NODE_ENV !== "production" ? `MUI X Charts: Sankey series context is missing. Ensure the SankeyPlot is used inside a properly configured ChartsDataProviderPro.` : (0, _formatErrorMessage2.default)(46));
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
// Early return if no data or dimensions
|
|
@@ -12,8 +12,8 @@ import { SankeyNodeLabelPlot } from "./SankeyNodeLabelPlot.mjs";
|
|
|
12
12
|
import { SankeyLinkLabelPlot } from "./SankeyLinkLabelPlot.mjs";
|
|
13
13
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
14
|
const SankeyPlotRoot = styled('g', {
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
name: 'MuiSankeyPlot',
|
|
16
|
+
slot: 'Root'
|
|
17
17
|
})({});
|
|
18
18
|
|
|
19
19
|
/**
|
|
@@ -31,7 +31,7 @@ function SankeyPlot(props) {
|
|
|
31
31
|
const sankeySeries = useSankeySeries()[0];
|
|
32
32
|
const layout = useSankeyLayout();
|
|
33
33
|
if (!sankeySeries) {
|
|
34
|
-
throw new Error(process.env.NODE_ENV !== "production" ? `MUI X Charts: Sankey series context is missing. Ensure the SankeyPlot is used inside a properly configured
|
|
34
|
+
throw new Error(process.env.NODE_ENV !== "production" ? `MUI X Charts: Sankey series context is missing. Ensure the SankeyPlot is used inside a properly configured ChartsDataProviderPro.` : _formatErrorMessage(46));
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
// Early return if no data or dimensions
|
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.useUtilityClasses = void 0;
|
|
8
8
|
var _composeClasses = _interopRequireDefault(require("@mui/utils/composeClasses"));
|
|
9
|
-
var
|
|
9
|
+
var _internals = require("@mui/x-charts/internals");
|
|
10
10
|
const useUtilityClasses = props => {
|
|
11
11
|
const {
|
|
12
12
|
classes
|
|
@@ -22,6 +22,6 @@ const useUtilityClasses = props => {
|
|
|
22
22
|
labelCell: ['labelCell'],
|
|
23
23
|
valueCell: ['valueCell']
|
|
24
24
|
};
|
|
25
|
-
return (0, _composeClasses.default)(slots,
|
|
25
|
+
return (0, _composeClasses.default)(slots, _internals.getChartsTooltipUtilityClass, classes);
|
|
26
26
|
};
|
|
27
27
|
exports.useUtilityClasses = useUtilityClasses;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import composeClasses from '@mui/utils/composeClasses';
|
|
2
|
-
import { getChartsTooltipUtilityClass } from '@mui/x-charts/
|
|
2
|
+
import { getChartsTooltipUtilityClass } from '@mui/x-charts/internals';
|
|
3
3
|
export const useUtilityClasses = props => {
|
|
4
4
|
const {
|
|
5
5
|
classes
|
package/SankeyChart/index.d.mts
CHANGED
|
@@ -16,6 +16,7 @@ export * from "./sankey.types.mjs";
|
|
|
16
16
|
export * from "./sankeySlots.types.mjs";
|
|
17
17
|
export * from "./sankeyHighlightHooks.mjs";
|
|
18
18
|
export * from "../hooks/useSankeySeries.mjs";
|
|
19
|
-
export {
|
|
19
|
+
export { sankeyClasses } from "./sankeyClasses.mjs";
|
|
20
|
+
export type { SankeyClassKey, SankeyClasses } from "./sankeyClasses.mjs";
|
|
20
21
|
export { SankeyTooltip, SankeyTooltipContent } from "./SankeyTooltip/index.mjs";
|
|
21
22
|
export type { SankeyTooltipProps, SankeyTooltipClasses, SankeyTooltipContentClasses, SankeyTooltipSlots, SankeyTooltipSlotProps } from "./SankeyTooltip/index.mjs";
|
package/SankeyChart/index.d.ts
CHANGED
|
@@ -16,6 +16,7 @@ export * from "./sankey.types.js";
|
|
|
16
16
|
export * from "./sankeySlots.types.js";
|
|
17
17
|
export * from "./sankeyHighlightHooks.js";
|
|
18
18
|
export * from "../hooks/useSankeySeries.js";
|
|
19
|
-
export {
|
|
19
|
+
export { sankeyClasses } from "./sankeyClasses.js";
|
|
20
|
+
export type { SankeyClassKey, SankeyClasses } from "./sankeyClasses.js";
|
|
20
21
|
export { SankeyTooltip, SankeyTooltipContent } from "./SankeyTooltip/index.js";
|
|
21
22
|
export type { SankeyTooltipProps, SankeyTooltipClasses, SankeyTooltipContentClasses, SankeyTooltipSlots, SankeyTooltipSlotProps } from "./SankeyTooltip/index.js";
|
package/SankeyChart/index.js
CHANGED
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
var _exportNames = {
|
|
7
7
|
Unstable_SankeyChart: true,
|
|
8
8
|
SankeyChart: true,
|
|
9
|
-
|
|
9
|
+
sankeyClasses: true,
|
|
10
10
|
SankeyTooltip: true,
|
|
11
11
|
SankeyTooltipContent: true
|
|
12
12
|
};
|
|
@@ -29,10 +29,10 @@ Object.defineProperty(exports, "SankeyTooltipContent", {
|
|
|
29
29
|
}
|
|
30
30
|
});
|
|
31
31
|
exports.Unstable_SankeyChart = void 0;
|
|
32
|
-
Object.defineProperty(exports, "
|
|
32
|
+
Object.defineProperty(exports, "sankeyClasses", {
|
|
33
33
|
enumerable: true,
|
|
34
34
|
get: function () {
|
|
35
|
-
return _sankeyClasses.
|
|
35
|
+
return _sankeyClasses.sankeyClasses;
|
|
36
36
|
}
|
|
37
37
|
});
|
|
38
38
|
var _SankeyChart = require("./SankeyChart");
|
package/SankeyChart/index.mjs
CHANGED
|
@@ -17,5 +17,5 @@ export * from "./sankey.types.mjs";
|
|
|
17
17
|
export * from "./sankeySlots.types.mjs";
|
|
18
18
|
export * from "./sankeyHighlightHooks.mjs";
|
|
19
19
|
export * from "../hooks/useSankeySeries.mjs";
|
|
20
|
-
export {
|
|
20
|
+
export { sankeyClasses } from "./sankeyClasses.mjs";
|
|
21
21
|
export { SankeyTooltip, SankeyTooltipContent } from "./SankeyTooltip/index.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export interface
|
|
1
|
+
export interface SankeyClasses {
|
|
2
2
|
/** Styles applied to the root element. */
|
|
3
3
|
root: string;
|
|
4
4
|
/** Styles applied to the nodes container. */
|
|
@@ -9,9 +9,18 @@ export interface SankeyPlotClasses {
|
|
|
9
9
|
links: string;
|
|
10
10
|
/** Styles applied to the link label container. */
|
|
11
11
|
linkLabels: string;
|
|
12
|
+
/** Styles applied to an individual node element. */
|
|
13
|
+
node: string;
|
|
14
|
+
/** Styles applied to an individual link element. */
|
|
15
|
+
link: string;
|
|
16
|
+
/** Styles applied to an individual node label element. */
|
|
17
|
+
nodeLabel: string;
|
|
18
|
+
/** Styles applied to an individual link label element. */
|
|
19
|
+
linkLabel: string;
|
|
12
20
|
}
|
|
13
|
-
export
|
|
14
|
-
export declare
|
|
15
|
-
export declare const
|
|
16
|
-
|
|
17
|
-
|
|
21
|
+
export type SankeyClassKey = keyof SankeyClasses;
|
|
22
|
+
export declare function getSankeyUtilityClass(slot: string): string;
|
|
23
|
+
export declare const sankeyClasses: SankeyClasses;
|
|
24
|
+
export declare const useUtilityClasses: (options?: {
|
|
25
|
+
classes?: Partial<SankeyClasses>;
|
|
26
|
+
}) => Record<"nodes" | "links" | "node" | "link" | "root" | "nodeLabels" | "linkLabels" | "nodeLabel" | "linkLabel", string>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export interface
|
|
1
|
+
export interface SankeyClasses {
|
|
2
2
|
/** Styles applied to the root element. */
|
|
3
3
|
root: string;
|
|
4
4
|
/** Styles applied to the nodes container. */
|
|
@@ -9,9 +9,18 @@ export interface SankeyPlotClasses {
|
|
|
9
9
|
links: string;
|
|
10
10
|
/** Styles applied to the link label container. */
|
|
11
11
|
linkLabels: string;
|
|
12
|
+
/** Styles applied to an individual node element. */
|
|
13
|
+
node: string;
|
|
14
|
+
/** Styles applied to an individual link element. */
|
|
15
|
+
link: string;
|
|
16
|
+
/** Styles applied to an individual node label element. */
|
|
17
|
+
nodeLabel: string;
|
|
18
|
+
/** Styles applied to an individual link label element. */
|
|
19
|
+
linkLabel: string;
|
|
12
20
|
}
|
|
13
|
-
export
|
|
14
|
-
export declare
|
|
15
|
-
export declare const
|
|
16
|
-
|
|
17
|
-
|
|
21
|
+
export type SankeyClassKey = keyof SankeyClasses;
|
|
22
|
+
export declare function getSankeyUtilityClass(slot: string): string;
|
|
23
|
+
export declare const sankeyClasses: SankeyClasses;
|
|
24
|
+
export declare const useUtilityClasses: (options?: {
|
|
25
|
+
classes?: Partial<SankeyClasses>;
|
|
26
|
+
}) => Record<"nodes" | "links" | "node" | "link" | "root" | "nodeLabels" | "linkLabels" | "nodeLabel" | "linkLabel", string>;
|
|
@@ -4,26 +4,30 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.
|
|
8
|
-
exports.useUtilityClasses = exports.
|
|
7
|
+
exports.getSankeyUtilityClass = getSankeyUtilityClass;
|
|
8
|
+
exports.useUtilityClasses = exports.sankeyClasses = void 0;
|
|
9
9
|
var _composeClasses = _interopRequireDefault(require("@mui/utils/composeClasses"));
|
|
10
10
|
var _generateUtilityClass = _interopRequireDefault(require("@mui/utils/generateUtilityClass"));
|
|
11
11
|
var _generateUtilityClasses = _interopRequireDefault(require("@mui/utils/generateUtilityClasses"));
|
|
12
|
-
function
|
|
12
|
+
function getSankeyUtilityClass(slot) {
|
|
13
13
|
return (0, _generateUtilityClass.default)('MuiSankeyChart', slot);
|
|
14
14
|
}
|
|
15
|
-
const
|
|
16
|
-
const useUtilityClasses =
|
|
15
|
+
const sankeyClasses = exports.sankeyClasses = (0, _generateUtilityClasses.default)('MuiSankeyChart', ['root', 'nodes', 'nodeLabels', 'links', 'linkLabels', 'node', 'link', 'nodeLabel', 'linkLabel']);
|
|
16
|
+
const useUtilityClasses = options => {
|
|
17
17
|
const {
|
|
18
18
|
classes
|
|
19
|
-
} =
|
|
19
|
+
} = options ?? {};
|
|
20
20
|
const slots = {
|
|
21
21
|
root: ['root'],
|
|
22
22
|
nodes: ['nodes'],
|
|
23
23
|
nodeLabels: ['nodeLabels'],
|
|
24
24
|
links: ['links'],
|
|
25
|
-
linkLabels: ['linkLabels']
|
|
25
|
+
linkLabels: ['linkLabels'],
|
|
26
|
+
node: ['node'],
|
|
27
|
+
link: ['link'],
|
|
28
|
+
nodeLabel: ['nodeLabel'],
|
|
29
|
+
linkLabel: ['linkLabel']
|
|
26
30
|
};
|
|
27
|
-
return (0, _composeClasses.default)(slots,
|
|
31
|
+
return (0, _composeClasses.default)(slots, getSankeyUtilityClass, classes);
|
|
28
32
|
};
|
|
29
33
|
exports.useUtilityClasses = useUtilityClasses;
|
|
@@ -1,20 +1,24 @@
|
|
|
1
1
|
import composeClasses from '@mui/utils/composeClasses';
|
|
2
2
|
import generateUtilityClass from '@mui/utils/generateUtilityClass';
|
|
3
3
|
import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
|
|
4
|
-
export function
|
|
4
|
+
export function getSankeyUtilityClass(slot) {
|
|
5
5
|
return generateUtilityClass('MuiSankeyChart', slot);
|
|
6
6
|
}
|
|
7
|
-
export const
|
|
8
|
-
export const useUtilityClasses =
|
|
7
|
+
export const sankeyClasses = generateUtilityClasses('MuiSankeyChart', ['root', 'nodes', 'nodeLabels', 'links', 'linkLabels', 'node', 'link', 'nodeLabel', 'linkLabel']);
|
|
8
|
+
export const useUtilityClasses = options => {
|
|
9
9
|
const {
|
|
10
10
|
classes
|
|
11
|
-
} =
|
|
11
|
+
} = options ?? {};
|
|
12
12
|
const slots = {
|
|
13
13
|
root: ['root'],
|
|
14
14
|
nodes: ['nodes'],
|
|
15
15
|
nodeLabels: ['nodeLabels'],
|
|
16
16
|
links: ['links'],
|
|
17
|
-
linkLabels: ['linkLabels']
|
|
17
|
+
linkLabels: ['linkLabels'],
|
|
18
|
+
node: ['node'],
|
|
19
|
+
link: ['link'],
|
|
20
|
+
nodeLabel: ['nodeLabel'],
|
|
21
|
+
linkLabel: ['linkLabel']
|
|
18
22
|
};
|
|
19
|
-
return composeClasses(slots,
|
|
23
|
+
return composeClasses(slots, getSankeyUtilityClass, classes);
|
|
20
24
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { ChartsOverlayProps } from '@mui/x-charts/ChartsOverlay';
|
|
2
2
|
import type { ChartsWrapperProps } from '@mui/x-charts/ChartsWrapper';
|
|
3
3
|
import type { SankeyChartProps } from "./SankeyChart.mjs";
|
|
4
|
-
import type {
|
|
4
|
+
import type { ChartsContainerProProps } from "../ChartsContainerPro/index.mjs";
|
|
5
5
|
import { type SankeyChartPluginSignatures } from "./SankeyChart.plugins.mjs";
|
|
6
6
|
/**
|
|
7
7
|
* A helper function that extracts SankeyChartProps from the input props
|
|
@@ -11,7 +11,7 @@ import { type SankeyChartPluginSignatures } from "./SankeyChart.plugins.mjs";
|
|
|
11
11
|
* @returns An object with props for the children components of SankeyChart
|
|
12
12
|
*/
|
|
13
13
|
export declare const useSankeyChartProps: (props: SankeyChartProps) => {
|
|
14
|
-
|
|
14
|
+
chartsContainerProps: ChartsContainerProProps<"sankey", SankeyChartPluginSignatures>;
|
|
15
15
|
sankeyPlotProps: {
|
|
16
16
|
onNodeClick: ((event: React.MouseEvent<SVGElement, MouseEvent>, node: import("./sankey.types.mjs").SankeyNodeIdentifierWithData) => void) | undefined;
|
|
17
17
|
onLinkClick: ((event: React.MouseEvent<SVGElement, MouseEvent>, link: import("./sankey.types.mjs").SankeyLinkIdentifierWithData) => void) | undefined;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { ChartsOverlayProps } from '@mui/x-charts/ChartsOverlay';
|
|
2
2
|
import type { ChartsWrapperProps } from '@mui/x-charts/ChartsWrapper';
|
|
3
3
|
import type { SankeyChartProps } from "./SankeyChart.js";
|
|
4
|
-
import type {
|
|
4
|
+
import type { ChartsContainerProProps } from "../ChartsContainerPro/index.js";
|
|
5
5
|
import { type SankeyChartPluginSignatures } from "./SankeyChart.plugins.js";
|
|
6
6
|
/**
|
|
7
7
|
* A helper function that extracts SankeyChartProps from the input props
|
|
@@ -11,7 +11,7 @@ import { type SankeyChartPluginSignatures } from "./SankeyChart.plugins.js";
|
|
|
11
11
|
* @returns An object with props for the children components of SankeyChart
|
|
12
12
|
*/
|
|
13
13
|
export declare const useSankeyChartProps: (props: SankeyChartProps) => {
|
|
14
|
-
|
|
14
|
+
chartsContainerProps: ChartsContainerProProps<"sankey", SankeyChartPluginSignatures>;
|
|
15
15
|
sankeyPlotProps: {
|
|
16
16
|
onNodeClick: ((event: React.MouseEvent<SVGElement, MouseEvent>, node: import("./sankey.types.js").SankeyNodeIdentifierWithData) => void) | undefined;
|
|
17
17
|
onLinkClick: ((event: React.MouseEvent<SVGElement, MouseEvent>, link: import("./sankey.types.js").SankeyLinkIdentifierWithData) => void) | undefined;
|
|
@@ -39,7 +39,7 @@ const useSankeyChartProps = props => {
|
|
|
39
39
|
} = props,
|
|
40
40
|
other = (0, _objectWithoutPropertiesLoose2.default)(props, _excluded);
|
|
41
41
|
const margin = (0, _internals.defaultizeMargin)(marginProps, _constants.DEFAULT_MARGINS);
|
|
42
|
-
const
|
|
42
|
+
const chartsContainerProps = (0, _extends2.default)({}, other, {
|
|
43
43
|
series: [(0, _extends2.default)({
|
|
44
44
|
type: 'sankey'
|
|
45
45
|
}, series)],
|
|
@@ -68,7 +68,7 @@ const useSankeyChartProps = props => {
|
|
|
68
68
|
className
|
|
69
69
|
};
|
|
70
70
|
return {
|
|
71
|
-
|
|
71
|
+
chartsContainerProps,
|
|
72
72
|
sankeyPlotProps,
|
|
73
73
|
overlayProps,
|
|
74
74
|
chartsWrapperProps,
|
|
@@ -33,7 +33,7 @@ export const useSankeyChartProps = props => {
|
|
|
33
33
|
} = props,
|
|
34
34
|
other = _objectWithoutPropertiesLoose(props, _excluded);
|
|
35
35
|
const margin = defaultizeMargin(marginProps, DEFAULT_MARGINS);
|
|
36
|
-
const
|
|
36
|
+
const chartsContainerProps = _extends({}, other, {
|
|
37
37
|
series: [_extends({
|
|
38
38
|
type: 'sankey'
|
|
39
39
|
}, series)],
|
|
@@ -62,7 +62,7 @@ export const useSankeyChartProps = props => {
|
|
|
62
62
|
className
|
|
63
63
|
};
|
|
64
64
|
return {
|
|
65
|
-
|
|
65
|
+
chartsContainerProps,
|
|
66
66
|
sankeyPlotProps,
|
|
67
67
|
overlayProps,
|
|
68
68
|
chartsWrapperProps,
|
|
@@ -2,7 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { type ScatterChartProps, type ScatterChartSlotProps, type ScatterChartSlots } from '@mui/x-charts/ScatterChart';
|
|
3
3
|
import { type ChartsTooltipProps } from '@mui/x-charts/ChartsTooltip';
|
|
4
4
|
import { type ChartsSlotPropsPro, type ChartsSlotsPro } from "../internals/material/index.mjs";
|
|
5
|
-
import { type
|
|
5
|
+
import { type ChartsContainerProProps } from "../ChartsContainerPro/ChartsContainerPro.mjs";
|
|
6
6
|
import { type ScatterChartProPluginSignatures } from "./ScatterChartPro.plugins.mjs";
|
|
7
7
|
import { type ChartsToolbarProSlots, type ChartsToolbarProSlotProps } from "../ChartsToolbarPro/Toolbar.types.mjs";
|
|
8
8
|
export interface ScatterChartProSlots extends Omit<ScatterChartSlots, 'toolbar'>, ChartsToolbarProSlots, Partial<ChartsSlotsPro> {}
|
|
@@ -13,7 +13,7 @@ export interface ScatterChartProSlotProps extends Omit<ScatterChartSlotProps, 't
|
|
|
13
13
|
*/
|
|
14
14
|
tooltip?: Partial<ChartsTooltipProps<'item' | 'none'>>;
|
|
15
15
|
}
|
|
16
|
-
export interface ScatterChartProProps extends Omit<ScatterChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<
|
|
16
|
+
export interface ScatterChartProProps extends Omit<ScatterChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<ChartsContainerProProps<'scatter', ScatterChartProPluginSignatures>, 'series' | 'onItemClick' | 'slots' | 'slotProps' | 'highlightedAxis' | 'onHighlightedAxisChange'> {
|
|
17
17
|
/**
|
|
18
18
|
* Overridable component slots.
|
|
19
19
|
* @default {}
|
|
@@ -2,7 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { type ScatterChartProps, type ScatterChartSlotProps, type ScatterChartSlots } from '@mui/x-charts/ScatterChart';
|
|
3
3
|
import { type ChartsTooltipProps } from '@mui/x-charts/ChartsTooltip';
|
|
4
4
|
import { type ChartsSlotPropsPro, type ChartsSlotsPro } from "../internals/material/index.js";
|
|
5
|
-
import { type
|
|
5
|
+
import { type ChartsContainerProProps } from "../ChartsContainerPro/ChartsContainerPro.js";
|
|
6
6
|
import { type ScatterChartProPluginSignatures } from "./ScatterChartPro.plugins.js";
|
|
7
7
|
import { type ChartsToolbarProSlots, type ChartsToolbarProSlotProps } from "../ChartsToolbarPro/Toolbar.types.js";
|
|
8
8
|
export interface ScatterChartProSlots extends Omit<ScatterChartSlots, 'toolbar'>, ChartsToolbarProSlots, Partial<ChartsSlotsPro> {}
|
|
@@ -13,7 +13,7 @@ export interface ScatterChartProSlotProps extends Omit<ScatterChartSlotProps, 't
|
|
|
13
13
|
*/
|
|
14
14
|
tooltip?: Partial<ChartsTooltipProps<'item' | 'none'>>;
|
|
15
15
|
}
|
|
16
|
-
export interface ScatterChartProProps extends Omit<ScatterChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<
|
|
16
|
+
export interface ScatterChartProProps extends Omit<ScatterChartProps, 'apiRef' | 'slots' | 'slotProps' | 'plugins' | 'seriesConfig'>, Omit<ChartsContainerProProps<'scatter', ScatterChartProPluginSignatures>, 'series' | 'onItemClick' | 'slots' | 'slotProps' | 'highlightedAxis' | 'onHighlightedAxisChange'> {
|
|
17
17
|
/**
|
|
18
18
|
* Overridable component slots.
|
|
19
19
|
* @default {}
|