react-pixi-plot
Version:
A React component rendering a zoomable and draggable PIXI.js scene. Intended to render 2d plots
28 lines (27 loc) • 793 B
TypeScript
import { ScaleContinuousNumeric, ScaleOrdinal, ScaleBand, ScalePoint } from 'd3-scale';
import { Component } from 'react';
export declare enum AxisOrientation {
TOP = "Top",
RIGHT = "Right",
BOTTOM = "Bottom",
LEFT = "Left"
}
interface Props {
orient: AxisOrientation;
transform?: string;
scale: ScaleContinuousNumeric<number, number> | ScaleBand<any> | ScaleOrdinal<any, number> | ScalePoint<any>;
tickValues?: number[] | string[];
numTicks?: number;
ticksRotate?: number;
}
export default class Axis extends Component<Props> {
static defaultProps: {
numTicks: number;
};
axisElement: SVGGElement | null;
componentDidMount(): void;
componentDidUpdate(): void;
renderAxis(): void;
render(): JSX.Element;
}
export {};