@mui/x-charts
Version:
The community edition of MUI X Charts components.
39 lines (38 loc) • 1.18 kB
JavaScript
'use client';
import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
const _excluded = ["children", "localeText", "plugins", "slots", "slotProps", "seriesConfig"];
import { useTheme, useThemeProps } from '@mui/material/styles';
import { RADIAL_PLUGINS } from "./ChartsRadialDataProvider.plugins.mjs";
const RADIAL_SERIES_CONFIG = {};
export const useChartsRadialDataProviderProps = inProps => {
// eslint-disable-next-line mui/material-ui-name-matches-component-name
const props = useThemeProps({
props: inProps,
name: 'MuiChartsRadialDataProvider'
});
const {
children,
localeText,
plugins = RADIAL_PLUGINS,
slots,
slotProps,
seriesConfig = RADIAL_SERIES_CONFIG
} = props,
other = _objectWithoutPropertiesLoose(props, _excluded);
const theme = useTheme();
const chartProviderProps = {
plugins: plugins,
pluginParams: _extends({
theme: theme.palette.mode,
seriesConfig
}, other)
};
return {
children,
localeText,
chartProviderProps,
slots,
slotProps
};
};