reaviz
Version:
Data Visualization using React
44 lines (43 loc) • 1.03 kB
TypeScript
import { default as React, FC, ReactElement } from 'react';
import { ChartShallowDataShape } from '../common';
import { BarListSeriesProps } from './BarListSeries';
export interface BarListProps {
/**
* ID for the chart.
*/
id?: string;
/**
* CSS Classname for the element.
*/
className?: string;
/**
* Style for the element.
*/
style?: React.CSSProperties;
/**
* Data for the chart.
*
* @default []
*/
data: ChartShallowDataShape[];
/**
* Sort direction of the data.
*
* @default 'desc'
*/
sortDirection?: 'asc' | 'desc' | 'none';
/**
* Series to render.
*
* @default `<BarListSeries />`
*/
series?: ReactElement<BarListSeriesProps, typeof BarList>;
/**
* Whether the values are percentages or absolute values.
* In the latter case, the chart would be relative
*
* @default 'count'
*/
type?: 'percent' | 'count';
}
export declare const BarList: FC<BarListProps>;