UNPKG

@mui/x-charts

Version:

The community edition of the charts components (MUI X).

61 lines (60 loc) 2.04 kB
import * as React from 'react'; import { SlotComponentProps } from '@mui/base/utils'; import { HighlightScope } from '../context/HighlightProvider'; export interface AreaElementClasses { /** Styles applied to the root element. */ root: string; /** Styles applied to the root element when higlighted. */ highlighted: string; /** Styles applied to the root element when faded. */ faded: string; } export type AreaElementClassKey = keyof AreaElementClasses; interface AreaElementOwnerState { id: string; color: string; isFaded: boolean; isHighlighted: boolean; classes?: Partial<AreaElementClasses>; } export declare function getAreaElementUtilityClass(slot: string): string; export declare const areaElementClasses: AreaElementClasses; export declare const AreaElementPath: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & { ownerState: AreaElementOwnerState; }, Pick<React.SVGProps<SVGPathElement>, keyof React.SVGProps<SVGPathElement>>, {}>; export type AreaElementProps = Omit<AreaElementOwnerState, 'isFaded' | 'isHighlighted'> & React.ComponentPropsWithoutRef<'path'> & { highlightScope?: Partial<HighlightScope>; /** * The props used for each component slot. * @default {} */ slotProps?: { area?: SlotComponentProps<'path', {}, AreaElementOwnerState>; }; /** * Overridable component slots. * @default {} */ slots?: { /** * The component that renders the root. * @default AreaElementPath */ area?: React.ElementType; }; }; /** * Demos: * * - [Lines](https://mui.com/x/react-charts/lines/) * - [Areas demonstration](https://mui.com/x/react-charts/areas-demo/) * * API: * * - [AreaElement API](https://mui.com/x/api/charts/area-element/) */ declare function AreaElement(props: AreaElementProps): React.JSX.Element; declare namespace AreaElement { var propTypes: any; } export { AreaElement };