react-pixi-plot
Version:
A React component rendering a zoomable and draggable PIXI.js scene. Intended to render 2d plots
53 lines (52 loc) • 1.56 kB
TypeScript
import React from 'react';
import { AnyScale } from './components/dom/Axes';
export interface PixiPlotProps {
/**
* A d3 scale that will be displayed along the left axis.
* You need to specify a renderer margin to allow room for this axis
*/
readonly leftAxisScale?: AnyScale;
/**
* The label for the left axis
*/
readonly leftLabel?: string;
/**
* A d3 scale that will be displayed along the right axis.
* You need to specify a renderer margin to allow room for this axis
*/
readonly rightAxisScale?: AnyScale;
/**
* The label for the right axis
*/
readonly rightLabel?: string;
/**
* A d3 scale that will be displayed along the top axis.
* You need to specify a renderer margin to allow room for this axis
*/
readonly topAxisScale?: AnyScale;
/**
* The label for the top axis
*/
readonly topLabel?: string;
/**
* A d3 scale that will be displayed along the bottom axis.
* You need to specify a renderer margin to allow room for this axis
*/
readonly bottomAxisScale?: AnyScale;
/**
* The label for the bottom axis
*/
readonly bottomLabel?: string;
readonly bottomTicksRotate?: number;
/**
* The margins around the renderer, where you can display axes for instance
*/
readonly rendererMargins?: {
left: number;
right: number;
top: number;
bottom: number;
};
}
declare const PixiPlot: React.SFC<PixiPlotProps>;
export default PixiPlot;