UNPKG

reaviz

Version:

Data Visualization using React

117 lines (116 loc) 3.28 kB
import { FC, ReactElement } from 'react'; import { ChartInternalShallowDataShape } from '../../common/data'; import { ColorSchemeType } from '../../common/color'; import { RadialAreaProps, RadialArea } from './RadialArea'; import { RadialLine, RadialLineProps } from './RadialLine'; import { RadialInterpolationTypes } from '../../common/utils/interpolation'; import { RadialPointSeries, RadialPointSeriesProps } from './RadialPointSeries'; import { TooltipAreaProps, TooltipArea } from '../../common/Tooltip'; import { RadialValueMarker, RadialValueMarkerProps } from '../../common'; export type RadialPointSeriesType = 'standard' | 'grouped'; export interface RadialAreaSeriesProps { /** * Parsed data shape. Set internally by `RadialAreaChart`. */ data: ChartInternalShallowDataShape[]; /** * The type of the chart. * * @default 'standard' */ type?: RadialPointSeriesType; /** * Color scheme for the series. * * @default schemes.cybertron */ colorScheme: ColorSchemeType; /** * The outer radius for the chart center. */ outerRadius: number; /** * The inner radius for the chart center. */ innerRadius: number; /** * D3 scale for X Axis. Set internally by `RadialAreaChart`. */ xScale: any; /** * D3 scale for Y Axis. Set internally by `RadialAreaChart`. */ yScale: any; /** * Id set internally by `RadialAreaChart`. */ id: string; /** * interpolation set internally by `RadialAreaChart`. * * @default 'smooth' */ interpolation: RadialInterpolationTypes; /** * Whether to animate the enter/update/exit. * * @default true */ animated: boolean; /** * Height of the chart. Set internally by `RadialAreaChart`. */ height: number; /** * Width of the chart. Set internally by `RadialAreaChart`. */ width: number; /** * Area that is rendered. * * @default `<RadialArea />` */ area: ReactElement<RadialAreaProps, typeof RadialArea> | null; /** * Line that is rendered. * * @default `<RadialLine />` */ line: ReactElement<RadialLineProps, typeof RadialLine> | null; /** * Symbols used to show points. * * @default `<RadialPointSeries />` */ symbols: ReactElement<RadialPointSeriesProps, typeof RadialPointSeries> | null; /** * Tooltip for the chart area. * * @default `<TooltipArea />` */ tooltip: ReactElement<TooltipAreaProps, typeof TooltipArea>; /** * Start angle for the first value. * * @default 0 */ startAngle?: number; /** * End angle for the last value. * * @default 2 * Math.PI */ endAngle?: number; /** * Whether the curve should be closed. Set to true by deafult * * @default true */ isClosedCurve: boolean; /** * Value markers line for the chart. */ valueMarkers: ReactElement<RadialValueMarkerProps, typeof RadialValueMarker>[] | null; } export declare const RadialAreaSeries: FC<Partial<RadialAreaSeriesProps>>; export declare const RADIAL_AREA_SERIES_DEFAULT_PROPS: Partial<RadialAreaSeriesProps>;