UNPKG

fybdp-d3-kg

Version:

Knowledge Graph using React and D3.js

38 lines (37 loc) 1.56 kB
import { Component, ReactElement } from 'react'; import { ChartProps, ChartContainerChildProps } from '../common/containers/ChartContainer'; import { ChartNestedDataShape, ChartInternalNestedDataShape } from '../common/data'; import { LinearAxisProps, LinearAxis } from '../common/Axis'; import { HeatmapSeries, HeatmapSeriesProps } from './HeatmapSeries'; export interface HeatmapProps extends ChartProps { /** * Data the chart will receive to render. */ data: ChartNestedDataShape[]; /** * The series component that renders the cell components. */ series: ReactElement<HeatmapSeriesProps, typeof HeatmapSeries>; /** * The linear axis component for the Y Axis of the chart. */ yAxis: ReactElement<LinearAxisProps, typeof LinearAxis>; /** * The linear axis component for the X Axis of the chart. */ xAxis: ReactElement<LinearAxisProps, typeof LinearAxis>; /** * Any secondary axis components. Useful for multi-axis charts. */ secondaryAxis?: ReactElement<LinearAxisProps, typeof LinearAxis>[]; } export declare class Heatmap extends Component<HeatmapProps> { static defaultProps: Partial<HeatmapProps>; getScalesData(chartHeight: number, chartWidth: number): { yScale: import("d3-scale").ScaleBand<string>; xScale: import("d3-scale").ScaleBand<string>; data: ChartInternalNestedDataShape[]; }; renderChart(containerProps: ChartContainerChildProps): JSX.Element; render(): JSX.Element; }