@mui/x-charts-premium 8.27.2 → 8.27.5
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/BarChartPremium/BarChartPremium.js +3 -3
- package/BarChartPremium/RangeBar/RangeBarPlot.js +1 -1
- package/CHANGELOG.md +154 -0
- package/ChartContainerPremium/ChartContainerPremium.d.ts +17 -31
- package/ChartContainerPremium/ChartContainerPremium.js +15 -43
- package/ChartContainerPremium/useChartContainerPremiumProps.d.ts +10 -9
- package/ChartContainerPremium/useChartContainerPremiumProps.js +10 -27
- package/ChartDataProviderPremium/ChartDataProviderPremium.d.ts +18 -44
- package/ChartDataProviderPremium/ChartDataProviderPremium.js +21 -143
- package/ChartDataProviderPremium/useChartDataProviderPremiumProps.d.ts +7 -7
- package/ChartDataProviderPremium/useChartDataProviderPremiumProps.js +5 -18
- package/ChartsContainer/index.d.ts +1 -0
- package/ChartsContainer/index.js +16 -0
- package/ChartsContainerPremium/ChartsContainerPremium.d.ts +37 -0
- package/ChartsContainerPremium/ChartsContainerPremium.js +52 -0
- package/ChartsContainerPremium/index.d.ts +2 -0
- package/ChartsContainerPremium/index.js +17 -0
- package/ChartsContainerPremium/useChartsContainerPremiumProps.d.ts +9 -0
- package/ChartsContainerPremium/useChartsContainerPremiumProps.js +33 -0
- package/ChartsContainerPro/index.d.ts +1 -0
- package/ChartsContainerPro/index.js +16 -0
- package/ChartsDataProvider/index.d.ts +1 -0
- package/ChartsDataProvider/index.js +16 -0
- package/ChartsDataProviderPremium/ChartsDataProviderPremium.d.ts +49 -0
- package/ChartsDataProviderPremium/ChartsDataProviderPremium.js +153 -0
- package/ChartsDataProviderPremium/index.d.ts +2 -0
- package/ChartsDataProviderPremium/index.js +13 -0
- package/ChartsDataProviderPremium/useChartsDataProviderPremiumProps.d.ts +10 -0
- package/ChartsDataProviderPremium/useChartsDataProviderPremiumProps.js +25 -0
- package/ChartsDataProviderPro/index.d.ts +1 -0
- package/ChartsDataProviderPro/index.js +16 -0
- package/ChartsZoomSlider/index.d.ts +1 -0
- package/ChartsZoomSlider/index.js +16 -0
- package/context/useChartPremiumApiContext.d.ts +1 -1
- package/context/useChartPremiumApiContext.js +1 -1
- package/esm/BarChartPremium/BarChartPremium.js +3 -3
- package/esm/BarChartPremium/RangeBar/RangeBarPlot.js +2 -2
- package/esm/ChartContainerPremium/ChartContainerPremium.d.ts +17 -31
- package/esm/ChartContainerPremium/ChartContainerPremium.js +16 -42
- package/esm/ChartContainerPremium/useChartContainerPremiumProps.d.ts +10 -9
- package/esm/ChartContainerPremium/useChartContainerPremiumProps.js +10 -25
- package/esm/ChartDataProviderPremium/ChartDataProviderPremium.d.ts +18 -44
- package/esm/ChartDataProviderPremium/ChartDataProviderPremium.js +17 -143
- package/esm/ChartDataProviderPremium/useChartDataProviderPremiumProps.d.ts +7 -7
- package/esm/ChartDataProviderPremium/useChartDataProviderPremiumProps.js +6 -17
- package/esm/ChartsContainer/index.d.ts +1 -0
- package/esm/ChartsContainer/index.js +2 -0
- package/esm/ChartsContainerPremium/ChartsContainerPremium.d.ts +37 -0
- package/esm/ChartsContainerPremium/ChartsContainerPremium.js +46 -0
- package/esm/ChartsContainerPremium/index.d.ts +2 -0
- package/esm/ChartsContainerPremium/index.js +2 -0
- package/esm/ChartsContainerPremium/useChartsContainerPremiumProps.d.ts +9 -0
- package/esm/ChartsContainerPremium/useChartsContainerPremiumProps.js +27 -0
- package/esm/ChartsContainerPro/index.d.ts +1 -0
- package/esm/ChartsContainerPro/index.js +2 -0
- package/esm/ChartsDataProvider/index.d.ts +1 -0
- package/esm/ChartsDataProvider/index.js +2 -0
- package/esm/ChartsDataProviderPremium/ChartsDataProviderPremium.d.ts +49 -0
- package/esm/ChartsDataProviderPremium/ChartsDataProviderPremium.js +148 -0
- package/esm/ChartsDataProviderPremium/index.d.ts +2 -0
- package/esm/ChartsDataProviderPremium/index.js +2 -0
- package/esm/ChartsDataProviderPremium/useChartsDataProviderPremiumProps.d.ts +10 -0
- package/esm/ChartsDataProviderPremium/useChartsDataProviderPremiumProps.js +19 -0
- package/esm/ChartsDataProviderPro/index.d.ts +1 -0
- package/esm/ChartsDataProviderPro/index.js +2 -0
- package/esm/ChartsZoomSlider/index.d.ts +1 -0
- package/esm/ChartsZoomSlider/index.js +2 -0
- package/esm/context/useChartPremiumApiContext.d.ts +1 -1
- package/esm/context/useChartPremiumApiContext.js +1 -1
- package/esm/index.d.ts +7 -0
- package/esm/index.js +7 -1
- package/index.d.ts +7 -0
- package/index.js +69 -1
- package/package.json +3 -3
- /package/{ChartZoomSlider → ChartsZoomSlider}/internals/previews/RangeBarPreviewPlot.d.ts +0 -0
- /package/{ChartZoomSlider → ChartsZoomSlider}/internals/previews/RangeBarPreviewPlot.js +0 -0
- /package/esm/{ChartZoomSlider → ChartsZoomSlider}/internals/previews/RangeBarPreviewPlot.d.ts +0 -0
- /package/esm/{ChartZoomSlider → ChartsZoomSlider}/internals/previews/RangeBarPreviewPlot.js +0 -0
|
@@ -1,35 +1,21 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { type ChartsSurfaceProps } from '@mui/x-charts/ChartsSurface';
|
|
3
1
|
import { type ChartAnyPluginSignature, type ChartSeriesType } from '@mui/x-charts/internals';
|
|
4
2
|
import { type AllPluginSignatures } from "../internals/plugins/allPlugins.js";
|
|
5
|
-
import { type
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
3
|
+
import { type ChartsContainerPremiumProps, type ChartsContainerPremiumSlotProps, type ChartsContainerPremiumSlots } from "../ChartsContainerPremium/index.js";
|
|
4
|
+
/**
|
|
5
|
+
* @deprecated Use `ChartsContainerPremiumSlots` instead. We added S to the charts prefix to align with other components.
|
|
6
|
+
*/
|
|
7
|
+
export type ChartContainerPremiumSlots = ChartsContainerPremiumSlots;
|
|
8
|
+
/**
|
|
9
|
+
* @deprecated Use `ChartsContainerPremiumSlotProps` instead. We added S to the charts prefix to align with other components.
|
|
10
|
+
*/
|
|
11
|
+
export type ChartContainerPremiumSlotProps = ChartsContainerPremiumSlotProps;
|
|
12
|
+
/**
|
|
13
|
+
* @deprecated Use `ChartsContainerPremiumProps` instead. We added S to the charts prefix to align with other components.
|
|
14
|
+
*/
|
|
15
|
+
export type ChartContainerPremiumProps<TSeries extends ChartSeriesType = ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[] = AllPluginSignatures<TSeries>> = ChartsContainerPremiumProps<TSeries, TSignatures>;
|
|
10
16
|
/**
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
* This is a combination of both the `ChartDataProviderPremium` and `ChartsSurface` components.
|
|
14
|
-
*
|
|
15
|
-
* Demos:
|
|
16
|
-
*
|
|
17
|
-
* - [Composition](https://mui.com/x/api/charts/composition/)
|
|
18
|
-
*
|
|
19
|
-
* API:
|
|
20
|
-
*
|
|
21
|
-
* - [ChartContainer API](https://mui.com/x/api/charts/chart-container/)
|
|
22
|
-
*
|
|
23
|
-
* @example
|
|
24
|
-
* ```jsx
|
|
25
|
-
* <ChartContainerPremium
|
|
26
|
-
* series={[{ label: "Label", type: "bar", data: [10, 20] }]}
|
|
27
|
-
* xAxis={[{ data: ["A", "B"], scaleType: "band", id: "x-axis" }]}
|
|
28
|
-
* >
|
|
29
|
-
* <BarPlot />
|
|
30
|
-
* <ChartsXAxis axisId="x-axis" />
|
|
31
|
-
* </ChartContainerPremium>
|
|
32
|
-
* ```
|
|
17
|
+
* @deprecated Use `ChartsContainerPremium` instead. We added S to the charts prefix to align with other components.
|
|
33
18
|
*/
|
|
34
|
-
declare const ChartContainerPremium:
|
|
35
|
-
|
|
19
|
+
export declare const ChartContainerPremium: <TSeries extends ChartSeriesType = keyof import("@mui/x-charts/internals").ChartsSeriesConfig, TSignatures extends readonly ChartAnyPluginSignature[] = AllPluginSignatures<TSeries>>(props: ChartsContainerPremiumProps<TSeries, TSignatures> & {
|
|
20
|
+
ref?: React.ForwardedRef<SVGSVGElement>;
|
|
21
|
+
}) => React.JSX.Element;
|
|
@@ -1,46 +1,20 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
import { ChartsContainerPremium } from "../ChartsContainerPremium/index.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated Use `ChartsContainerPremiumSlots` instead. We added S to the charts prefix to align with other components.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated Use `ChartsContainerPremiumSlotProps` instead. We added S to the charts prefix to align with other components.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* @deprecated Use `ChartsContainerPremiumProps` instead. We added S to the charts prefix to align with other components.
|
|
15
|
+
*/
|
|
16
|
+
|
|
9
17
|
/**
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* This is a combination of both the `ChartDataProviderPremium` and `ChartsSurface` components.
|
|
13
|
-
*
|
|
14
|
-
* Demos:
|
|
15
|
-
*
|
|
16
|
-
* - [Composition](https://mui.com/x/api/charts/composition/)
|
|
17
|
-
*
|
|
18
|
-
* API:
|
|
19
|
-
*
|
|
20
|
-
* - [ChartContainer API](https://mui.com/x/api/charts/chart-container/)
|
|
21
|
-
*
|
|
22
|
-
* @example
|
|
23
|
-
* ```jsx
|
|
24
|
-
* <ChartContainerPremium
|
|
25
|
-
* series={[{ label: "Label", type: "bar", data: [10, 20] }]}
|
|
26
|
-
* xAxis={[{ data: ["A", "B"], scaleType: "band", id: "x-axis" }]}
|
|
27
|
-
* >
|
|
28
|
-
* <BarPlot />
|
|
29
|
-
* <ChartsXAxis axisId="x-axis" />
|
|
30
|
-
* </ChartContainerPremium>
|
|
31
|
-
* ```
|
|
18
|
+
* @deprecated Use `ChartsContainerPremium` instead. We added S to the charts prefix to align with other components.
|
|
32
19
|
*/
|
|
33
|
-
const ChartContainerPremium =
|
|
34
|
-
const {
|
|
35
|
-
chartDataProviderPremiumProps,
|
|
36
|
-
children,
|
|
37
|
-
chartsSurfaceProps
|
|
38
|
-
} = useChartContainerPremiumProps(props, ref);
|
|
39
|
-
return /*#__PURE__*/_jsx(ChartDataProviderPremium, _extends({}, chartDataProviderPremiumProps, {
|
|
40
|
-
children: /*#__PURE__*/_jsx(ChartsSurface, _extends({}, chartsSurfaceProps, {
|
|
41
|
-
children: children
|
|
42
|
-
}))
|
|
43
|
-
}));
|
|
44
|
-
});
|
|
45
|
-
if (process.env.NODE_ENV !== "production") ChartContainerPremium.displayName = "ChartContainerPremium";
|
|
46
|
-
export { ChartContainerPremium };
|
|
20
|
+
export const ChartContainerPremium = ChartsContainerPremium;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
export type UseChartContainerPremiumPropsReturnValue<TSeries extends ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[]> =
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import { type ChartAnyPluginSignature, type ChartSeriesType } from '@mui/x-charts/internals';
|
|
2
|
+
import { useChartsContainerPremiumProps, type UseChartsContainerPremiumPropsReturnValue } from "../ChartsContainerPremium/useChartsContainerPremiumProps.js";
|
|
3
|
+
/**
|
|
4
|
+
* @deprecated Use `UseChartsContainerPremiumPropsReturnValue` instead.
|
|
5
|
+
*/
|
|
6
|
+
export type UseChartContainerPremiumPropsReturnValue<TSeries extends ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[]> = UseChartsContainerPremiumPropsReturnValue<TSeries, TSignatures>;
|
|
7
|
+
/**
|
|
8
|
+
* @deprecated Use `useChartsContainerPremiumProps` instead.
|
|
9
|
+
*/
|
|
10
|
+
export declare const useChartContainerPremiumProps: typeof useChartsContainerPremiumProps;
|
|
@@ -1,27 +1,12 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
baseProps = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
14
|
-
const {
|
|
15
|
-
chartDataProviderProProps,
|
|
16
|
-
chartsSurfaceProps,
|
|
17
|
-
children
|
|
18
|
-
} = useChartContainerProProps(baseProps, ref);
|
|
19
|
-
const chartDataProviderPremiumProps = _extends({}, chartDataProviderProProps, {
|
|
20
|
-
plugins: plugins ?? DEFAULT_PLUGINS
|
|
21
|
-
});
|
|
22
|
-
return {
|
|
23
|
-
chartDataProviderPremiumProps,
|
|
24
|
-
chartsSurfaceProps,
|
|
25
|
-
children
|
|
26
|
-
};
|
|
27
|
-
}
|
|
3
|
+
import { useChartsContainerPremiumProps } from "../ChartsContainerPremium/useChartsContainerPremiumProps.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated Use `UseChartsContainerPremiumPropsReturnValue` instead.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated Use `useChartsContainerPremiumProps` instead.
|
|
11
|
+
*/
|
|
12
|
+
export const useChartContainerPremiumProps = useChartsContainerPremiumProps;
|
|
@@ -1,47 +1,21 @@
|
|
|
1
|
-
import { type ChartSeriesType, type ChartAnyPluginSignature
|
|
2
|
-
import { type
|
|
3
|
-
import {
|
|
1
|
+
import { type ChartSeriesType, type ChartAnyPluginSignature } from '@mui/x-charts/internals';
|
|
2
|
+
import { ChartsDataProviderPremium, type ChartsDataProviderPremiumProps, type ChartsDataProviderPremiumSlots, type ChartsDataProviderPremiumSlotProps } from "../ChartsDataProviderPremium/index.js";
|
|
3
|
+
import { defaultSeriesConfigPremium } from "../ChartsDataProviderPremium/ChartsDataProviderPremium.js";
|
|
4
4
|
import { type AllPluginSignatures } from "../internals/plugins/allPlugins.js";
|
|
5
|
-
export
|
|
6
|
-
/**
|
|
7
|
-
* Slots to customize charts' components.
|
|
8
|
-
*/
|
|
9
|
-
slots?: Partial<ChartsSlotsPro>;
|
|
10
|
-
/**
|
|
11
|
-
* The props for the slots.
|
|
12
|
-
*/
|
|
13
|
-
slotProps?: Partial<ChartsSlotPropsPro>;
|
|
14
|
-
};
|
|
15
|
-
export declare const defaultSeriesConfigPremium: ChartSeriesConfig<'bar' | 'rangeBar' | 'scatter' | 'line' | 'pie'>;
|
|
5
|
+
export { defaultSeriesConfigPremium };
|
|
16
6
|
/**
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* Use this component if you have custom HTML components that need to access the chart data.
|
|
20
|
-
*
|
|
21
|
-
* Demos:
|
|
22
|
-
*
|
|
23
|
-
* - [Composition](https://mui.com/x/api/charts/composition/)
|
|
24
|
-
*
|
|
25
|
-
* API:
|
|
26
|
-
*
|
|
27
|
-
* - [ChartDataProviderPro API](https://mui.com/x/api/charts/chart-data-provider/)
|
|
28
|
-
*
|
|
29
|
-
* @example
|
|
30
|
-
* ```jsx
|
|
31
|
-
* <ChartDataProviderPro
|
|
32
|
-
* series={[{ label: "Label", type: "bar", data: [10, 20] }]}
|
|
33
|
-
* xAxis={[{ data: ["A", "B"], scaleType: "band", id: "x-axis" }]}
|
|
34
|
-
* >
|
|
35
|
-
* <ChartsSurface>
|
|
36
|
-
* <BarPlot />
|
|
37
|
-
* <ChartsXAxis axisId="x-axis" />
|
|
38
|
-
* </ChartsSurface>
|
|
39
|
-
* {'Custom Legend Component'}
|
|
40
|
-
* </ChartDataProviderPro>
|
|
41
|
-
* ```
|
|
7
|
+
* @deprecated Use `ChartsDataProviderPremiumSlots` instead. We added S to the charts prefix to align with other components.
|
|
42
8
|
*/
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
export
|
|
9
|
+
export type ChartDataProviderPremiumSlots = ChartsDataProviderPremiumSlots;
|
|
10
|
+
/**
|
|
11
|
+
* @deprecated Use `ChartsDataProviderPremiumSlotProps` instead. We added S to the charts prefix to align with other components.
|
|
12
|
+
*/
|
|
13
|
+
export type ChartDataProviderPremiumSlotProps = ChartsDataProviderPremiumSlotProps;
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated Use `ChartsDataProviderPremiumProps` instead. We added S to the charts prefix to align with other components.
|
|
16
|
+
*/
|
|
17
|
+
export type ChartDataProviderPremiumProps<TSeries extends ChartSeriesType = ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[] = AllPluginSignatures<TSeries>> = ChartsDataProviderPremiumProps<TSeries, TSignatures>;
|
|
18
|
+
/**
|
|
19
|
+
* @deprecated Use `ChartsDataProviderPremium` instead. We added S to the charts prefix to align with other components.
|
|
20
|
+
*/
|
|
21
|
+
export declare const ChartDataProviderPremium: typeof ChartsDataProviderPremium;
|
|
@@ -1,148 +1,22 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
|
|
6
|
-
import { ChartProvider, ChartsSlotsProvider } from '@mui/x-charts/internals';
|
|
7
|
-
import { ChartsLocalizationProvider } from '@mui/x-charts/ChartsLocalizationProvider';
|
|
8
|
-
import { defaultSlotsMaterial } from '@mui/x-charts-pro/internals';
|
|
9
|
-
import { useLicenseVerifier } from '@mui/x-license/useLicenseVerifier';
|
|
10
|
-
import { defaultSeriesConfigPro } from '@mui/x-charts-pro/internals';
|
|
11
|
-
import { rangeBarSeriesConfig } from "../BarChartPremium/RangeBar/seriesConfig/index.js";
|
|
12
|
-
import { DEFAULT_PLUGINS } from "../internals/plugins/allPlugins.js";
|
|
13
|
-
import { useChartDataProviderPremiumProps } from "./useChartDataProviderPremiumProps.js";
|
|
14
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
15
|
-
const releaseInfo = "MTc3MTU0NTYwMDAwMA==";
|
|
16
|
-
const packageIdentifier = 'x-charts-premium';
|
|
17
|
-
export const defaultSeriesConfigPremium = _extends({}, defaultSeriesConfigPro, {
|
|
18
|
-
rangeBar: rangeBarSeriesConfig
|
|
19
|
-
});
|
|
3
|
+
import { ChartsDataProviderPremium } from "../ChartsDataProviderPremium/index.js";
|
|
4
|
+
import { defaultSeriesConfigPremium } from "../ChartsDataProviderPremium/ChartsDataProviderPremium.js";
|
|
5
|
+
export { defaultSeriesConfigPremium };
|
|
20
6
|
|
|
21
7
|
/**
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
* Use this component if you have custom HTML components that need to access the chart data.
|
|
25
|
-
*
|
|
26
|
-
* Demos:
|
|
27
|
-
*
|
|
28
|
-
* - [Composition](https://mui.com/x/api/charts/composition/)
|
|
29
|
-
*
|
|
30
|
-
* API:
|
|
31
|
-
*
|
|
32
|
-
* - [ChartDataProviderPro API](https://mui.com/x/api/charts/chart-data-provider/)
|
|
33
|
-
*
|
|
34
|
-
* @example
|
|
35
|
-
* ```jsx
|
|
36
|
-
* <ChartDataProviderPro
|
|
37
|
-
* series={[{ label: "Label", type: "bar", data: [10, 20] }]}
|
|
38
|
-
* xAxis={[{ data: ["A", "B"], scaleType: "band", id: "x-axis" }]}
|
|
39
|
-
* >
|
|
40
|
-
* <ChartsSurface>
|
|
41
|
-
* <BarPlot />
|
|
42
|
-
* <ChartsXAxis axisId="x-axis" />
|
|
43
|
-
* </ChartsSurface>
|
|
44
|
-
* {'Custom Legend Component'}
|
|
45
|
-
* </ChartDataProviderPro>
|
|
46
|
-
* ```
|
|
8
|
+
* @deprecated Use `ChartsDataProviderPremiumSlots` instead. We added S to the charts prefix to align with other components.
|
|
47
9
|
*/
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
children: [/*#__PURE__*/_jsx(ChartsLocalizationProvider, {
|
|
62
|
-
localeText: localeText,
|
|
63
|
-
children: /*#__PURE__*/_jsx(ChartsSlotsProvider, {
|
|
64
|
-
slots: slots,
|
|
65
|
-
slotProps: slotProps,
|
|
66
|
-
defaultSlots: defaultSlotsMaterial,
|
|
67
|
-
children: children
|
|
68
|
-
})
|
|
69
|
-
}), /*#__PURE__*/_jsx(Watermark, {
|
|
70
|
-
packageName: packageIdentifier,
|
|
71
|
-
releaseInfo: releaseInfo
|
|
72
|
-
})]
|
|
73
|
-
}));
|
|
74
|
-
}
|
|
75
|
-
process.env.NODE_ENV !== "production" ? ChartDataProviderPremium.propTypes = {
|
|
76
|
-
// ----------------------------- Warning --------------------------------
|
|
77
|
-
// | These PropTypes are generated from the TypeScript type definitions |
|
|
78
|
-
// | To update them edit the TypeScript types and run "pnpm proptypes" |
|
|
79
|
-
// ----------------------------------------------------------------------
|
|
80
|
-
apiRef: PropTypes.shape({
|
|
81
|
-
current: PropTypes.any
|
|
82
|
-
}),
|
|
83
|
-
/**
|
|
84
|
-
* Color palette used to colorize multiple series.
|
|
85
|
-
* @default rainbowSurgePalette
|
|
86
|
-
*/
|
|
87
|
-
colors: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string), PropTypes.func]),
|
|
88
|
-
/**
|
|
89
|
-
* An array of objects that can be used to populate series and axes data using their `dataKey` property.
|
|
90
|
-
*/
|
|
91
|
-
dataset: PropTypes.arrayOf(PropTypes.object),
|
|
92
|
-
/**
|
|
93
|
-
* Options to enable features planned for the next major.
|
|
94
|
-
*/
|
|
95
|
-
experimentalFeatures: PropTypes.shape({
|
|
96
|
-
preferStrictDomainInLineCharts: PropTypes.bool
|
|
97
|
-
}),
|
|
98
|
-
/**
|
|
99
|
-
* The height of the chart in px. If not defined, it takes the height of the parent element.
|
|
100
|
-
*/
|
|
101
|
-
height: PropTypes.number,
|
|
102
|
-
/**
|
|
103
|
-
* This prop is used to help implement the accessibility logic.
|
|
104
|
-
* If you don't provide this prop. It falls back to a randomly generated id.
|
|
105
|
-
*/
|
|
106
|
-
id: PropTypes.string,
|
|
107
|
-
/**
|
|
108
|
-
* Localized text for chart components.
|
|
109
|
-
*/
|
|
110
|
-
localeText: PropTypes.object,
|
|
111
|
-
/**
|
|
112
|
-
* The margin between the SVG and the drawing area.
|
|
113
|
-
* It's used for leaving some space for extra information such as the x- and y-axis or legend.
|
|
114
|
-
*
|
|
115
|
-
* Accepts a `number` to be used on all sides or an object with the optional properties: `top`, `bottom`, `left`, and `right`.
|
|
116
|
-
*/
|
|
117
|
-
margin: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
|
|
118
|
-
bottom: PropTypes.number,
|
|
119
|
-
left: PropTypes.number,
|
|
120
|
-
right: PropTypes.number,
|
|
121
|
-
top: PropTypes.number
|
|
122
|
-
})]),
|
|
123
|
-
/**
|
|
124
|
-
* The array of series to display.
|
|
125
|
-
* Each type of series has its own specificity.
|
|
126
|
-
* Please refer to the appropriate docs page to learn more about it.
|
|
127
|
-
*/
|
|
128
|
-
series: PropTypes.arrayOf(PropTypes.object),
|
|
129
|
-
/**
|
|
130
|
-
* If `true`, animations are skipped.
|
|
131
|
-
* If unset or `false`, the animations respects the user's `prefers-reduced-motion` setting.
|
|
132
|
-
*/
|
|
133
|
-
skipAnimation: PropTypes.bool,
|
|
134
|
-
/**
|
|
135
|
-
* The props for the slots.
|
|
136
|
-
*/
|
|
137
|
-
slotProps: PropTypes.object,
|
|
138
|
-
/**
|
|
139
|
-
* Slots to customize charts' components.
|
|
140
|
-
*/
|
|
141
|
-
slots: PropTypes.object,
|
|
142
|
-
theme: PropTypes.oneOf(['dark', 'light']),
|
|
143
|
-
/**
|
|
144
|
-
* The width of the chart in px. If not defined, it takes the width of the parent element.
|
|
145
|
-
*/
|
|
146
|
-
width: PropTypes.number
|
|
147
|
-
} : void 0;
|
|
148
|
-
export { ChartDataProviderPremium };
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* @deprecated Use `ChartsDataProviderPremiumSlotProps` instead. We added S to the charts prefix to align with other components.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* @deprecated Use `ChartsDataProviderPremiumProps` instead. We added S to the charts prefix to align with other components.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @deprecated Use `ChartsDataProviderPremium` instead. We added S to the charts prefix to align with other components.
|
|
21
|
+
*/
|
|
22
|
+
export const ChartDataProviderPremium = ChartsDataProviderPremium;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export declare const useChartDataProviderPremiumProps: <TSeries extends ChartSeriesType =
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated Use `useChartsDataProviderPremiumProps` instead. We added S to the charts prefix to align with other components.
|
|
3
|
+
*/
|
|
4
|
+
export declare const useChartDataProviderPremiumProps: <TSeries extends import("@mui/x-charts/internals").ChartSeriesType = keyof import("@mui/x-charts/internals").ChartsSeriesConfig, TSignatures extends readonly import("@mui/x-charts/internals").ChartAnyPluginSignature[] = import("../internals/plugins/allPlugins.js").AllPluginSignatures<TSeries>>(props: import("../index.js").ChartsDataProviderPremiumProps<TSeries, TSignatures>) => {
|
|
5
5
|
children: import("react").ReactNode;
|
|
6
6
|
localeText: Partial<import("@mui/x-charts/locales").ChartsLocaleText> | undefined;
|
|
7
|
-
chartProviderProps: import("@mui/x-charts/internals").
|
|
8
|
-
slots: Partial<import("@mui/x-charts
|
|
9
|
-
slotProps: Partial<import("@mui/x-charts
|
|
7
|
+
chartProviderProps: import("@mui/x-charts/internals").ChartsProviderProps<TSeries, TSignatures>;
|
|
8
|
+
slots: Partial<import("@mui/x-charts").ChartsDataProviderSlots> | undefined;
|
|
9
|
+
slotProps: Partial<import("@mui/x-charts").ChartsDataProviderSlotProps> | undefined;
|
|
10
10
|
};
|
|
@@ -1,19 +1,8 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
slotProps,
|
|
10
|
-
children
|
|
11
|
-
} = useChartDataProviderProps(props);
|
|
12
|
-
return {
|
|
13
|
-
children,
|
|
14
|
-
localeText,
|
|
15
|
-
chartProviderProps,
|
|
16
|
-
slots,
|
|
17
|
-
slotProps
|
|
18
|
-
};
|
|
19
|
-
};
|
|
3
|
+
import { useChartsDataProviderPremiumProps } from "../ChartsDataProviderPremium/useChartsDataProviderPremiumProps.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated Use `useChartsDataProviderPremiumProps` instead. We added S to the charts prefix to align with other components.
|
|
7
|
+
*/
|
|
8
|
+
export const useChartDataProviderPremiumProps = useChartsDataProviderPremiumProps;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@mui/x-charts/ChartsContainer';
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { type ChartsSurfaceProps } from '@mui/x-charts/ChartsSurface';
|
|
3
|
+
import { type ChartAnyPluginSignature, type ChartSeriesType } from '@mui/x-charts/internals';
|
|
4
|
+
import { type AllPluginSignatures } from "../internals/plugins/allPlugins.js";
|
|
5
|
+
import { type ChartDataProviderPremiumProps } from "../ChartDataProviderPremium/index.js";
|
|
6
|
+
export interface ChartsContainerPremiumSlots {}
|
|
7
|
+
export interface ChartsContainerPremiumSlotProps {}
|
|
8
|
+
export type ChartsContainerPremiumProps<TSeries extends ChartSeriesType = ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[] = AllPluginSignatures<TSeries>> = ChartDataProviderPremiumProps<TSeries, TSignatures> & ChartsSurfaceProps;
|
|
9
|
+
type ChartsContainerPremiumComponent = <TSeries extends ChartSeriesType = ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[] = AllPluginSignatures<TSeries>>(props: ChartsContainerPremiumProps<TSeries, TSignatures> & {
|
|
10
|
+
ref?: React.ForwardedRef<SVGSVGElement>;
|
|
11
|
+
}) => React.JSX.Element;
|
|
12
|
+
/**
|
|
13
|
+
* It sets up the data providers as well as the `<svg>` for the chart.
|
|
14
|
+
*
|
|
15
|
+
* This is a combination of both the `ChartsDataProviderPremium` and `ChartsSurface` components.
|
|
16
|
+
*
|
|
17
|
+
* Demos:
|
|
18
|
+
*
|
|
19
|
+
* - [Composition](https://mui.com/x/api/charts/composition/)
|
|
20
|
+
*
|
|
21
|
+
* API:
|
|
22
|
+
*
|
|
23
|
+
* - [ChartsContainerPremium API](https://mui.com/x/api/charts/charts-container-premium/)
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* ```jsx
|
|
27
|
+
* <ChartsContainerPremium
|
|
28
|
+
* series={[{ label: "Label", type: "bar", data: [10, 20] }]}
|
|
29
|
+
* xAxis={[{ data: ["A", "B"], scaleType: "band", id: "x-axis" }]}
|
|
30
|
+
* >
|
|
31
|
+
* <BarPlot />
|
|
32
|
+
* <ChartsXAxis axisId="x-axis" />
|
|
33
|
+
* </ChartsContainerPremium>
|
|
34
|
+
* ```
|
|
35
|
+
*/
|
|
36
|
+
declare const ChartsContainerPremium: ChartsContainerPremiumComponent;
|
|
37
|
+
export { ChartsContainerPremium };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { ChartsSurface } from '@mui/x-charts/ChartsSurface';
|
|
6
|
+
import { ChartDataProviderPremium } from "../ChartDataProviderPremium/index.js";
|
|
7
|
+
import { useChartsContainerPremiumProps } from "./useChartsContainerPremiumProps.js";
|
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
|
+
/**
|
|
10
|
+
* It sets up the data providers as well as the `<svg>` for the chart.
|
|
11
|
+
*
|
|
12
|
+
* This is a combination of both the `ChartsDataProviderPremium` and `ChartsSurface` components.
|
|
13
|
+
*
|
|
14
|
+
* Demos:
|
|
15
|
+
*
|
|
16
|
+
* - [Composition](https://mui.com/x/api/charts/composition/)
|
|
17
|
+
*
|
|
18
|
+
* API:
|
|
19
|
+
*
|
|
20
|
+
* - [ChartsContainerPremium API](https://mui.com/x/api/charts/charts-container-premium/)
|
|
21
|
+
*
|
|
22
|
+
* @example
|
|
23
|
+
* ```jsx
|
|
24
|
+
* <ChartsContainerPremium
|
|
25
|
+
* series={[{ label: "Label", type: "bar", data: [10, 20] }]}
|
|
26
|
+
* xAxis={[{ data: ["A", "B"], scaleType: "band", id: "x-axis" }]}
|
|
27
|
+
* >
|
|
28
|
+
* <BarPlot />
|
|
29
|
+
* <ChartsXAxis axisId="x-axis" />
|
|
30
|
+
* </ChartsContainerPremium>
|
|
31
|
+
* ```
|
|
32
|
+
*/
|
|
33
|
+
const ChartsContainerPremium = /*#__PURE__*/React.forwardRef(function ChartsContainerPremium(props, ref) {
|
|
34
|
+
const {
|
|
35
|
+
chartDataProviderPremiumProps,
|
|
36
|
+
children,
|
|
37
|
+
chartsSurfaceProps
|
|
38
|
+
} = useChartsContainerPremiumProps(props, ref);
|
|
39
|
+
return /*#__PURE__*/_jsx(ChartDataProviderPremium, _extends({}, chartDataProviderPremiumProps, {
|
|
40
|
+
children: /*#__PURE__*/_jsx(ChartsSurface, _extends({}, chartsSurfaceProps, {
|
|
41
|
+
children: children
|
|
42
|
+
}))
|
|
43
|
+
}));
|
|
44
|
+
});
|
|
45
|
+
if (process.env.NODE_ENV !== "production") ChartsContainerPremium.displayName = "ChartsContainerPremium";
|
|
46
|
+
export { ChartsContainerPremium };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import { type ChartAnyPluginSignature, type ChartSeriesType, type UseChartsContainerPropsReturnValue } from '@mui/x-charts/internals';
|
|
3
|
+
import { type ChartDataProviderProps } from '@mui/x-charts/ChartDataProvider';
|
|
4
|
+
import { type AllPluginSignatures } from "../internals/plugins/allPlugins.js";
|
|
5
|
+
import type { ChartsContainerPremiumProps } from "./ChartsContainerPremium.js";
|
|
6
|
+
export type UseChartsContainerPremiumPropsReturnValue<TSeries extends ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[]> = Pick<UseChartsContainerPropsReturnValue<TSeries, TSignatures>, 'chartsSurfaceProps' | 'children'> & {
|
|
7
|
+
chartDataProviderPremiumProps: ChartDataProviderProps<TSeries, TSignatures>;
|
|
8
|
+
};
|
|
9
|
+
export declare function useChartsContainerPremiumProps<TSeries extends ChartSeriesType = ChartSeriesType, TSignatures extends readonly ChartAnyPluginSignature[] = AllPluginSignatures<TSeries>>(props: ChartsContainerPremiumProps<TSeries, TSignatures>, ref: React.Ref<SVGSVGElement>): UseChartsContainerPremiumPropsReturnValue<TSeries, TSignatures>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
|
+
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
5
|
+
const _excluded = ["initialZoom", "zoomData", "onZoomChange", "zoomInteractionConfig", "plugins", "apiRef"];
|
|
6
|
+
import { useChartsContainerProProps } from '@mui/x-charts-pro/internals';
|
|
7
|
+
import { DEFAULT_PLUGINS } from "../internals/plugins/allPlugins.js";
|
|
8
|
+
export function useChartsContainerPremiumProps(props, ref) {
|
|
9
|
+
const _ref = props,
|
|
10
|
+
{
|
|
11
|
+
plugins
|
|
12
|
+
} = _ref,
|
|
13
|
+
baseProps = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
14
|
+
const {
|
|
15
|
+
chartDataProviderProProps,
|
|
16
|
+
chartsSurfaceProps,
|
|
17
|
+
children
|
|
18
|
+
} = useChartsContainerProProps(baseProps, ref);
|
|
19
|
+
const chartDataProviderPremiumProps = _extends({}, chartDataProviderProProps, {
|
|
20
|
+
plugins: plugins ?? DEFAULT_PLUGINS
|
|
21
|
+
});
|
|
22
|
+
return {
|
|
23
|
+
chartDataProviderPremiumProps,
|
|
24
|
+
chartsSurfaceProps,
|
|
25
|
+
children
|
|
26
|
+
};
|
|
27
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@mui/x-charts-pro/ChartsContainerPro';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@mui/x-charts/ChartsDataProvider';
|