@mui/x-charts
Version:
The community edition of MUI X Charts components.
35 lines • 1.25 kB
text/typescript
import * as React from 'react';
import { type SxProps, type Theme } from '@mui/material/styles';
import { type Direction } from "../ChartsLegend/index.mjs";
import { type Position } from "../models/index.mjs";
export interface ChartsWrapperProps extends React.HTMLAttributes<HTMLDivElement> {
/**
* The position of the legend.
* @default { horizontal: 'center', vertical: 'bottom' }
*/
legendPosition?: Position;
/**
* The direction of the legend.
* @default 'horizontal'
*/
legendDirection?: Direction;
/**
* If `true`, the legend is not rendered.
* @default false
*/
hideLegend?: boolean;
/**
* If `true`, the chart wrapper set `height: 100%`.
* @default `false` if the `height` prop is set. And `true` otherwise.
*/
extendVertically?: boolean;
children: React.ReactNode;
sx?: SxProps<Theme>;
}
export interface ChartsWrapperOwnerState extends Pick<ChartsWrapperProps, 'hideLegend' | 'legendDirection' | 'legendPosition'> {}
/**
* Wrapper for the charts components.
* Its main purpose is to position the HTML legend in the correct place.
*/
declare const ChartsWrapper: React.ForwardRefExoticComponent<ChartsWrapperProps & React.RefAttributes<HTMLDivElement>>;
export { ChartsWrapper };