UNPKG

@mui/x-charts

Version:

The community edition of MUI X Charts components.

50 lines (48 loc) 1.88 kB
'use client'; import * as React from 'react'; import PropTypes from 'prop-types'; import composeClasses from '@mui/utils/composeClasses'; import { getRadialAxisHighlightUtilityClass } from "./chartsRadialAxisHighlightClasses.mjs"; import ChartsRotationAxisHighlight from "./ChartsRotationAxisHighlight.mjs"; import ChartsRadiusAxisHighlight from "./ChartsRadiusAxisHighlight.mjs"; import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime"; const useUtilityClasses = () => { const slots = { root: ['root'] }; return composeClasses(slots, getRadialAxisHighlightUtilityClass); }; /** * Demos: * * - [Radial Lines](https://mui.com/x/react-charts/radial-lines/) * * API: * * - [ChartsRadialAxisHighlight API](https://mui.com/x/api/charts/charts-radial-axis-highlight/) */ function ChartsRadialAxisHighlight(props) { const { rotation: rotationHighlight, radius: radiusHighlight } = props; const classes = useUtilityClasses(); return /*#__PURE__*/_jsxs(React.Fragment, { children: [rotationHighlight && rotationHighlight !== 'none' && /*#__PURE__*/_jsx(ChartsRotationAxisHighlight, { type: rotationHighlight, classes: classes }), radiusHighlight && radiusHighlight !== 'none' && /*#__PURE__*/_jsx(ChartsRadiusAxisHighlight, { type: radiusHighlight, classes: classes })] }); } process.env.NODE_ENV !== "production" ? ChartsRadialAxisHighlight.propTypes = { // ----------------------------- Warning -------------------------------- // | These PropTypes are generated from the TypeScript type definitions | // | To update them edit the TypeScript types and run "pnpm proptypes" | // ---------------------------------------------------------------------- radius: PropTypes.oneOf(['line', 'none']), rotation: PropTypes.oneOf(['band', 'line', 'none']) } : void 0; export { ChartsRadialAxisHighlight };